import { h, render } from "https://esm.sh/preact@10"; import { useState } from "https://esm.sh/preact@10/hooks"; import { html } from "https://esm.sh/htm@3/preact"; const TESTIMONIALS = [ { name: "Sarah M.", category: "Sports Rehab Patient", initials: "SM", color: "#8ab4be", quote: "After my ACL tear I was terrified I'd never run again. The team here built a plan that had me back on the field in four months. Every session felt purposeful.", }, { name: "Leon N.", category: "Neurology Patient", initials: "LN", color: "#a3bfc8", quote: "Every new patient begins with a comprehensive diagnostic assessment. From there, they create a fully personalized treatment plan tailored to your goals -- whether that means returning to sport, recovering from surgery, or restoring function.", }, { name: "Diana K.", category: "Surgery Rehab Patient", initials: "DK", color: "#7aa3af", quote: "Six weeks post-hip replacement and I was walking without a cane -- weeks ahead of what my surgeon expected. The therapists here are genuinely invested in your outcome, not just checking boxes.", }, { name: "Marcus T.", category: "Sports Rehab Patient", initials: "MT", color: "#6b9dab", quote: "I came in with chronic shoulder pain that three other clinics couldn't resolve. Two months in, I'm lifting overhead for the first time in years. The diagnostic process here is legitimately different.", }, { name: "Rachel O.", category: "Surgery Rehab Patient", initials: "RO", color: "#93b8c3", quote: "The booking process is seamless and the staff remembers you. I never felt like just another patient. My recovery from rotator cuff surgery exceeded every milestone.", }, { name: "James P.", category: "Neurology Patient", initials: "JP", color: "#80aab5", quote: "After my stroke the neurological therapy program here gave me my independence back. The team combined manual therapy with targeted exercise in a way that made real, measurable progress every single week.", }, ]; const CARD_W = 270; const GAP = 20; function Testimonials() { const [index, setIndex] = useState(0); const prev = () => setIndex(function(i) { return Math.max(0, i - 1); }); const next = () => setIndex(function(i) { return Math.min(TESTIMONIALS.length - 1, i + 1); }); const leftEdge = "max(1.5rem, calc((100vw - 1248px) / 2 + 1.5rem))"; return html`

Testimonials

Don’t take our word for it.
Hear it from our patients!

${TESTIMONIALS.map((t, i) => html`
${t.initials}

${t.quote}

${t.name}

${t.category}

`)}
`; } class RptTestimonials extends HTMLElement { connectedCallback() { render(html`<${Testimonials} />`, this); } disconnectedCallback() { render(null, this); } } customElements.define("rpt-testimonials", RptTestimonials);