PageSourceSearch

https://gaiafamily.com/en-us/_next/static/chunks/app/partner-clini…?dpl=dpl_CJPurkrPeaL5jw4oF8DS75wyXHbC

js gaiafamily.com collected 2026-09-24 21:51:34 UTC 24,394 bytes, 1 lines download raw bytes

1try{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="31d33418-8218-4243-a36a-c4835445883d",e._sentryDebugIdIdentifier="sentry-dbid-31d33418-8218-4243-a36a-c4835445883d")}catch(e){}{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e._sentryModuleMetadata=e._sentryModuleMetadata||{},e._sentryModuleMetadata[new e.Error().stack]=Object.assign({},e._sentryModuleMetadata[new e.Error().stack],{"_sentryBundlerPluginAppKey:gaia-app":!0})}(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7588],{38665:(e,t,a)=>{"use strict";a.d(t,{D:()=>u});var s=a(95155),n=a(74468),l=a(14441),r=a(36962),i=a(49692),o=a(15239),c=a(52619),d=a.n(c);function u(e){let{sticky:t=!1,minimal:a=!1,back:c}=e;return(0,s.jsx)("header",{className:(0,i.cn)("relative z-40 flex w-full items-center bg-gaia-soft-white px-[var(--nav-padding-inline-mobile)]","min-h-[var(--nav-height-mobile)] nav:min-h-[var(--nav-height)]","nav:bg-gaia-cream nav:px-[var(--nav-padding-inline)]",t&&"sticky top-0"),role:"banner","data-nav-scale":!0,children:(0,s.jsxs)("div",{className:"mx-auto flex w-full max-w-[var(--nav-max-width)] items-center justify-between self-stretch",children:[(0,s.jsx)(d(),{href:"/",className:"shrink-0","aria-label":"Gaia home",children:(0,s.jsx)(o.default,{src:"/en-us/icons/logo.svg",alt:"Gaia",width:70,height:34,priority:!0,className:"h-auto w-[var(--nav-logo-width)]"})}),a?c&&(0,s.jsx)(r.i,{href:c.href,label:c.label,tone:"secondary"}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.DesktopNav,{}),(0,s.jsx)(l.MobileMenu,{})]})]})})}},53425:(e,t,a)=>{"use strict";a.r(t),a.d(t,{default:()=>z});var s=a(95155),n=a(79376),l=a(12115);function r(e){let{text:t}=e,[a,n]=(0,l.useState)(!1),[r,i]=(0,l.useState)(!1),o=(0,l.useRef)(null);return(0,l.useEffect)(()=>{let e=o.current;if(!e)return;let t=()=>i(e.scrollHeight>e.clientHeight);t();let a=new ResizeObserver(t);return a.observe(e),()=>a.disconnect()},[t]),(0,s.jsxs)("div",{className:"relative z-20",children:[(0,s.jsx)("p",{ref:o,className:"font-sans text-sm text-gaia-soft-black leading-[1.5] ".concat(a?"":"line-clamp-4"),children:t}),r&&(0,s.jsxs)("button",{type:"button",onClick:()=>n(e=>!e),className:"mt-1 font-sans text-sm font-medium text-gaia-soft-black flex items-center gap-1 hover:opacity-70 transition-opacity",children:[a?"Read less":"Read more",(0,s.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":"true",className:"transition-transform ".concat(a?"rotate-180":""),children:(0,s.jsx)("path",{d:"M2 4l4 4 4-4",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})]})]})}var i=a(26044),o=a(69147),c=a(60569),d=a(69379),u=a(46995),p=a(21873),h=a(52619),f=a.n(h),x=a(20063);let g=["IVF","Egg freezing","Genetic testing","Frozen embryo transfer"],m={postal_code:"postal_code",address:"origin_address",coords:"origin_coords",state:"state"};function b(e){let{clinic:t,origin:a,email:h,priority:b,section:v,fromSignUp:k,consultPriceUsd:w}=e,y=(0,x.useRouter)(),[j,N]=(0,l.useState)(!1),_=(0,n.K)(w),C=null!==_,S={clinic_id:t.id,clinic_name:t.site_name,section:v,consult_price_shown:C},L=[];a&&L.push("".concat(m[a.kind],"=").concat(encodeURIComponent(a.value))),h&&L.push("email=".concat(encodeURIComponent(h))),k&&L.push("from_sign_up=".concat(encodeURIComponent(k)));let E=L.join("&"),D=E?"/partner-clinics/".concat(t.id,"?").concat(E):"/partner-clinics/".concat(t.id),F="/partner-clinics/".concat(t.id,"?").concat([...L,"consult=true"].join("&")),A=!!k;async function R(){if(k&&!j){N(!0),(0,o.zL)("finder",S);try{await (0,i.L)(k,t.id)}catch(e){}y.push((0,u.p9)(k))}}return(0,s.jsxs)("article",{className:"group relative bg-white border border-border rounded-xl overflow-hidden w-full hover:border-gaia-soft-black transition-colors",children:[!A&&(0,s.jsx)(f(),{href:D,className:"absolute inset-0 z-10","aria-label":"View ".concat(t.site_name),onClick:()=>(0,o.ZQ)(o.rL.clinic_clicked,{...S,cta:"card"}),children:(0,s.jsxs)("span",{className:"sr-only",children:["View ",t.site_name]})}),(0,s.jsxs)("div",{className:"relative w-full h-[143px] lg:h-[245px] bg-gaia-soft-white-alt",children:[(0,s.jsx)(c.y,{src:t.image,alt:t.site_name,sizes:"(max-width: 1024px) 100vw, 900px",priority:b}),(0,s.jsx)("div",{className:"absolute top-3 right-3",children:(0,s.jsx)(d.a,{})})]}),(0,s.jsxs)("div",{className:"px-4 py-5 lg:px-6 lg:py-6 flex flex-col gap-4",children:[(0,s.jsx)("h2",{className:"font-sans font-medium text-[22px] lg:text-[28px] leading-[1.1] text-gaia-soft-black",children:t.site_name}),(0,s.jsx)("div",{className:"flex items-start gap-3 text-gaia-soft-black-700 text-sm",children:t.distance?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("div",{className:"flex items-center gap-1.5 shrink-0",children:[(0,s.jsx)(p.A,{className:"size-[15px] shrink-0","aria-hidden":"true"}),(0,s.jsxs)("span",{className:"whitespace-nowrap",children:[t.distance," away"]})]}),(0,s.jsx)("div",{className:"w-px self-stretch bg-border shrink-0"}),(0,s.jsx)("span",{children:t.formatted_address})]}):(0,s.jsxs)("div",{className:"flex items-start gap-1.5",children:[(0,s.jsx)(p.A,{className:"size-[15px] shrink-0 mt-0.5","aria-hidden":"true"}),(0,s.jsx)("span",{children:t.formatted_address})]})}),t.description&&(0,s.jsx)(r,{text:t.description}),(0,s.jsx)("hr",{className:"border-border"}),(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"font-mono text-[11px] uppercase tracking-[0.08em] text-gaia-soft-black mb-2",children:"Services:"}),(0,s.jsx)("div",{className:"flex flex-wrap gap-x-4 gap-y-1",children:g.map(e=>(0,s.jsxs)("span",{className:"flex items-center gap-1.5",children:[(0,s.jsx)("svg",{width:"13",height:"13",viewBox:"0 0 13 13",fill:"none",className:"shrink-0 text-gaia-service-teal","aria-hidden":"true",children:(0,s.jsx)("path",{d:"M10.5 3L4.5 9L1.5 6",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),(0,s.jsx)("span",{className:"font-sans text-sm text-gaia-soft-black",children:e})]},e))})]}),C&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("hr",{className:"border-border"}),(0,s.jsx)(n.n,{consultPriceUsd:_,variant:"row"})]}),(0,s.jsx)("hr",{className:"border-border"}),(0,s.jsx)("div",{className:"relative z-20 flex flex-col gap-2.5",children:A?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("button",{type:"button",onClick:R,disabled:j,className:"w-full text-center font-mono text-[11px] uppercase tracking-[0.08em] bg-gaia-soft-black text-white py-2.5 rounded-[3px] hover:bg-gaia-soft-black/90 transition-colors disabled:opacity-60 disabled:cursor-not-allowed",children:j?"Selecting…":"Select clinic"}),(0,s.jsx)(f(),{href:D,onClick:()=>(0,o.ZQ)(o.rL.clinic_clicked,{...S,cta:"learn_more"}),className:"w-full text-center font-mono text-[11px] uppercase tracking-[0.08em] border border-gaia-soft-black text-gaia-soft-black py-2.5 rounded-[3px] hover:bg-gaia-soft-black hover:text-white transition-colors",children:"Learn more"})]}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(f(),{href:F,onClick:()=>(0,o.ZQ)(o.rL.clinic_clicked,{...S,cta:"book_consult"}),className:"w-full text-center font-mono text-[11px] uppercase tracking-[0.08em] bg-gaia-soft-black text-white py-2.5 rounded-[3px] hover:bg-gaia-soft-black/90 transition-colors",children:"Get started"}),(0,s.jsx)(f(),{href:D,onClick:()=>(0,o.ZQ)(o.rL.clinic_clicked,{...S,cta:"learn_more"}),className:"w-full text-center font-mono text-[11px] uppercase tracking-[0.08em] border border-gaia-soft-black text-gaia-soft-black py-2.5 rounded-[3px] hover:bg-gaia-soft-black hover:text-white transition-colors",children:"Learn more"})]})})]})]})}var v=a(85602),k=a(49692),w=a(82999),y=a(86651),j=a(39068);let N=/^\d{5}$/;function _(e){let{value:t,onChange:a,onAddressSelect:n,onZipDetected:r,onStateSelect:i,onClinicSelect:o,onSearchFocus:c,clinics:d,placeholder:u="City, state, or clinic name",className:h}=e,[f,x]=(0,l.useState)(t),[g,m]=(0,l.useState)(!1),[b,_]=(0,l.useState)([]),[C,S]=(0,l.useState)(!1),[L,E]=(0,l.useState)(!1),[D,F]=(0,l.useState)(-1),[A,R]=(0,l.useState)(""),I=(0,l.useRef)(null),M=(0,l.useRef)(null),U=(0,l.useRef)(null),z=(0,l.useId)(),P=(0,l.useRef)(!1),{getToken:K,endSession:q}=(0,v.O)();(0,l.useEffect)(()=>{x(t)},[t]),(0,l.useEffect)(()=>{let e=setTimeout(()=>R(f),300);return()=>clearTimeout(e)},[f]),(0,l.useEffect)(()=>
1{if(!P.current)return;let e=A.trim();if(e.length<3||N.test(e))return void _([]);let t=new AbortController;return(async()=>{S(!0);try{let a=new URLSearchParams({input:e,sessiontoken:K()}),s=await fetch("/en-us/api/places/autocomplete?".concat(a.toString()),{signal:t.signal});if(!s.ok)throw Error("Failed to fetch suggestions");let n=await s.json();_(n.suggestions||[])}catch(e){if(e instanceof DOMException&&"AbortError"===e.name)return;_([])}finally{t.signal.aborted||S(!1)}})(),()=>t.abort()},[A,K]);let Z=f.trim().toLowerCase(),T=(0,l.useMemo)(()=>Z.length>=2?d.filter(e=>e.site_name.toLowerCase().includes(Z)):[],[d,Z]),O=(0,l.useMemo)(()=>{if(Z.length<2)return[];let e=[];for(let{value:t,label:a}of w.Ky)if((t.toLowerCase().startsWith(Z)||a.toLowerCase().startsWith(Z))&&(e.push({abbr:t,label:a}),e.length>=3))break;return e},[Z]),Q=T.length+O.length+b.length;(0,l.useEffect)(()=>{F(-1)},[b,Z]),(0,l.useEffect)(()=>{if(D>=0&&U.current){let e=U.current.querySelectorAll('[role="option"]')[D];e&&e.scrollIntoView({block:"nearest"})}},[D]),(0,l.useEffect)(()=>{let e=e=>{I.current&&!I.current.contains(e.target)&&(m(!1),F(-1))};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[]);let B=(0,l.useCallback)(async e=>{E(!0);try{let t=new URLSearchParams({placeId:e,sessiontoken:K()}),a=await fetch("/en-us/api/places/details?".concat(t.toString()));if(!a.ok)throw Error("Failed to fetch address details");let s=await a.json();return _([]),s.address}catch(e){return null}finally{q(),E(!1)}},[K,q]),W=(0,l.useCallback)(async e=>{let t=await B(e.placeId);if(t){let e=(t.formattedAddress||"").replace(/,\s*USA$/,"");x(e||t.addressLineOne),a(e||t.addressLineOne),n(t),m(!1)}},[B,a,n]),G=(0,l.useCallback)(e=>{m(!1),o(e)},[o]),V=(0,l.useCallback)(e=>{m(!1),null==i||i(e)},[i]),$=(0,l.useCallback)(e=>{P.current=!0;let t=e.target.value;x(t),a(t);let s=t.trim();if(N.test(s)){r(s),m(!1);return}s.length>=2?m(!0):m(!1)},[a,r]),H=(0,l.useCallback)(e=>{let t=f.trim();if("Enter"===e.key&&N.test(t)){e.preventDefault(),r(t),m(!1);return}if("Enter"===e.key&&D<0&&i){let a=(0,w.vl)(t);if(a&&w.Ky.some(e=>e.value===a)){e.preventDefault(),V(a);return}}if(!g||0===Q){"ArrowDown"===e.key&&Q>0&&(e.preventDefault(),m(!0),F(0));return}switch(e.key){case"ArrowDown":e.preventDefault(),F(e=>e<Q-1?e+1:0);break;case"ArrowUp":e.preventDefault(),F(e=>e>0?e-1:Q-1);break;case"Enter":if(e.preventDefault(),D>=0)if(D<T.length){let e=T[D];e&&G(e.id)}else if(D<T.length+O.length){let e=O[D-T.length];e&&V(e.abbr)}else{let e=b[D-T.length-O.length];e&&W(e)}break;case"Escape":e.preventDefault(),m(!1),F(-1);break;case"Tab":m(!1),F(-1)}},[g,Q,D,T,O,b,f,r,i,G,V,W]),J=(0,l.useCallback)(()=>{null==c||c();let e=f.trim();e.length>=2&&!N.test(e)&&m(!0)},[f,c]),X=C||L,Y=T.length>0||O.length>0||b.length>0,ee=g&&f.trim().length>=2&&!N.test(f.trim()),et=e=>"".concat(z,"-option-").concat(e);return(0,s.jsxs)("div",{ref:I,className:"relative",children:[(0,s.jsx)("input",{ref:M,type:"text",value:f,onChange:$,onFocus:J,onKeyDown:H,placeholder:u,autoComplete:"off",role:"combobox","aria-expanded":ee,"aria-controls":z,"aria-activedescendant":D>=0?et(D):void 0,"aria-haspopup":"listbox","data-hj-suppress":!0,className:(0,k.cn)("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground flex w-full min-w-0 p-4 rounded-3 border border-gaia-soft-black bg-transparent text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]",h)}),ee&&(0,s.jsx)("div",{className:"absolute top-full left-0 w-full z-50 mt-1 border border-gaia-soft-black rounded-3 bg-white shadow-lg overflow-hidden",children:(0,s.jsxs)("ul",{ref:U,id:z,role:"listbox",className:"max-h-[300px] overflow-y-auto",children:[T.length>0&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("li",{className:"px-3 pt-3 pb-1.5","aria-hidden":"true",children:(0,s.jsx)("span",{className:"font-mono text-[11px] uppercase tracking-[0.08em] text-gaia-soft-black-700",children:"Clinics"})}),T.map((e,t)=>(0,s.jsxs)("li",{id:et(t),role:"option","aria-selected":D===t,onClick:()=>G(e.id),onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&(t.preventDefault(),G(e.id))},onMouseEnter:()=>
1F(t),className:(0,k.cn)("flex items-center gap-2 px-3 py-3 cursor-pointer transition-colors",D===t?"bg-accent":"hover:bg-accent"),children:[(0,s.jsx)(y.A,{className:"size-4 shrink-0 text-gaia-soft-black-700","aria-hidden":"true"}),(0,s.jsx)("span",{className:"truncate",children:e.site_name})]},e.id))]}),O.length>0&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("li",{className:"px-3 pt-3 pb-1.5","aria-hidden":"true",children:(0,s.jsx)("span",{className:"font-mono text-[11px] uppercase tracking-[0.08em] text-gaia-soft-black-700",children:"Regions"})}),O.map((e,t)=>{let a=T.length+t;return(0,s.jsxs)("li",{id:et(a),role:"option","aria-selected":D===a,onClick:()=>V(e.abbr),onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&(t.preventDefault(),V(e.abbr))},onMouseEnter:()=>F(a),className:(0,k.cn)("flex items-center gap-2 px-3 py-3 cursor-pointer transition-colors",D===a?"bg-accent":"hover:bg-accent"),children:[(0,s.jsx)(j.A,{className:"size-4 shrink-0 text-gaia-soft-black-700","aria-hidden":"true"}),(0,s.jsxs)("span",{className:"truncate",children:[e.label," ",(0,s.jsxs)("span",{className:"text-gaia-soft-black-700",children:["(",e.abbr,")"]})]})]},e.abbr)})]}),b.length>0&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("li",{className:"px-3 pt-3 pb-1.5","aria-hidden":"true",children:(0,s.jsx)("span",{className:"font-mono text-[11px] uppercase tracking-[0.08em] text-gaia-soft-black-700",children:"Locations"})}),b.map((e,t)=>{let a=T.length+O.length+t;return(0,s.jsxs)("li",{id:et(a),role:"option","data-hj-suppress":!0,"aria-selected":D===a,onClick:()=>W(e),onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&(t.preventDefault(),W(e))},onMouseEnter:()=>F(a),className:(0,k.cn)("flex items-center gap-2 px-3 py-3 cursor-pointer transition-colors",D===a?"bg-accent":"hover:bg-accent"),children:[(0,s.jsx)(p.A,{className:"size-4 shrink-0 text-gaia-soft-black-700","aria-hidden":"true"}),(0,s.jsx)("span",{className:"truncate",children:e.text})]},e.placeId)})]}),X&&!Y&&(0,s.jsx)("li",{className:"text-muted-foreground text-sm px-3 py-4 text-center",children:"Loading..."}),!X&&!Y&&f.trim().length>=3&&(0,s.jsx)("li",{className:"text-muted-foreground px-3 py-4",children:"No matching clinics or addresses found"})]})})]})}var C=a(67830);function S(e){let{value:t,onChange:a,onAddressSelect:n,onZipDetected:l,onStateSelect:r,onClinicSelect:i,onSearchFocus:o,clinics:c,onLocate:d,isLocating:u}=e;return(0,s.jsx)("section",{className:"bg-gaia-soft-white py-8 lg:py-16",children:(0,s.jsxs)("div",{className:"max-w-[900px] mx-auto w-full px-6",children:[(0,s.jsx)("h1",{className:"font-title text-[40px] lg:text-[48px] leading-[0.95] tracking-[-1px] text-gaia-soft-black mb-4",children:"Find a Gaia partner clinic"}),(0,s.jsx)("p",{className:"font-sans text-[20px] leading-[1.4] text-gaia-soft-black-700 mb-8 max-w-[640px]",children:"We only partner with the top 15% of clinics nationwide, based on the most successful outcomes."}),(0,s.jsxs)("div",{className:"relative w-full",children:[(0,s.jsx)(_,{value:t,onChange:a,onAddressSelect:n,onZipDetected:l,onStateSelect:r,onClinicSelect:i,onSearchFocus:o,clinics:c,placeholder:"Zip code, city, or clinic name",className:"w-full bg-white rounded-[3px] pr-[60px] lg:pr-[220px] py-4 font-sans font-medium text-base text-gaia-soft-black placeholder:text-gaia-soft-black-500"}),(0,s.jsxs)("button",{type:"button",onClick:d,disabled:u,"aria-label":"Find my location",className:"absolute right-2 top-1/2 -translate-y-1/2 flex items-center gap-2 border border-gaia-soft-black rounded-full px-3 py-2 font-mono text-[13px] tracking-[0.08em] uppercase text-gaia-soft-black bg-white hover:bg-gaia-soft-black hover:text-white transition-colors disabled:opacity-50",children:[(0,s.jsx)(C.A,{className:"size-[18px] shrink-0","aria-hidden":"true"}),(0,s.jsx)("span",{className:"hidden lg:inline",children:u?"Locating...":"Find my location"})]})]})]})})}async function L(e){let t=new URL("/en-us/api/partner-clinics/consult-prices",window.location.origin);t.searchParams.set("uuid",e);let a=await fetch(t.toString());if(!a.ok)throw Error("fetchConsultPrices failed: ".concat(a.status));return await a.json()}var E=a(23019),D=a(71510),F=a(38665),A=a(22454);function R(e){switch(e.kind){case"postal_code":return["postal_code",e.value];case"address":return["origin_address",e.value];case"coords":return["origin_coords",e.value];case"state":return["state",e.value]}}async function I(e){let t=new URL("/en-us/api/partner-clinics",window.location.origin);if(e){let[a,s]=R(e);t.searchParams.set(a,s)}let a=await fetch(t.toString());if(!a.ok)throw Error("Failed to fetch clinics");return a.json()}function M(e){let t=e.get("origin_address");if(t)return{kind:"address",value:t};let a=e.get("origin_coords");if(a)return{kind:"coords",value:a};let s=e.get("postal_code");if(s)return{kind:"postal_code",value:s};let n=e.get("state");if(n)return{kind:"state",value:n}}function U(e){let t=e.toString().match(/(?:^|&)email=([^&]*)/);if(!(null==t?void 0:t[1]))return null;try{return decodeURIComponent(t[1])}catch(e){return null}}function z(){var e;let t=(0,x.useRouter)(),a=(0,x.useSearchParams)(),[n,r]=(0,l.useState)(()=>M(a)),[i,c]=(0,l.useState)(()=>{var e,t,s;return(e=M(a))?"address"===e.kind?e.value.replace(/,\s*USA$/,""):"postal_code"===e.kind?e.value:"state"===e.kind?null!=(s=null==(t=w.Ky.find(t=>t.value===e.value))?void 0:t.label)?s:e.value:"":""}),[d,p]=(0,l.useState)(null),[h]=(0,l.useState)(()=>(function(e){let t=e.get("from_sign_up");return t&&t.length>0?t:null})(a));(0,l.useEffect)(()=>{p(U(a))},[a]);let[f,g]=(0,l.useState)(!1),[m,v]=(0,l.useState)(!1),k=(0,l.useRef)(void 0!==n);(0,l.useEffect)(()=>
1{if((null==n?void 0:n.kind)!=="coords"||i)return;let[e,t]=n.value.split(",");e&&t&&fetch("/en-us/api/places/reverse-geocode?lat=".concat(e,"&lng=").concat(t)).then(e=>e.ok?e.json():null).then(e=>{(null==e?void 0:e.display)&&c(e.display)}).catch(()=>{})},[]),(0,l.useEffect)(()=>{let e=!1;return fetch("/en-us/api/geo").then(e=>e.ok?e.json():null).then(t=>{!e&&t&&(k.current||(c(t.display),t.coords?r({kind:"coords",value:t.coords}):r({kind:"postal_code",value:"10001"})))}).catch(()=>{}),()=>{e=!0}},[]);let y=n?"".concat(n.kind,":").concat(n.value):"none",{data:j,isLoading:N,isError:_}=(0,A.I)({queryKey:["partner-clinics",y],queryFn:()=>I(n)}),C=(0,l.useMemo)(E.gN,[]),{data:z}=(0,A.I)({queryKey:["partner-clinics-consult-prices",h],queryFn:()=>L(null!=h?h:""),enabled:!!h&&C,staleTime:36e5,retry:!1}),P=(0,l.useCallback)(()=>{navigator.geolocation&&(k.current=!0,g(!0),navigator.geolocation.getCurrentPosition(async e=>{let{latitude:t,longitude:a}=e.coords;try{let e=await fetch("/en-us/api/places/reverse-geocode?lat=".concat(t,"&lng=").concat(a));if(e.ok){let t=await e.json();t.display&&c(t.display)}}catch(e){}finally{r({kind:"coords",value:"".concat(t,",").concat(a)}),g(!1)}},()=>g(!1)))},[]),K=(0,l.useCallback)(e=>{""!==e.trim()&&(k.current=!0),c(e),r(void 0)},[]),q=(0,l.useCallback)(e=>{if(k.current=!0,c((e.formattedAddress||"").replace(/,\s*USA$/,"")||"".concat(e.city,", ").concat(e.state)),e.formattedAddress){r({kind:"address",value:e.formattedAddress});let t=[e.city,e.state].filter(Boolean).join(", ");(0,o.ZQ)(o.rL.search_submitted,{input_mode:"address",query:t})}},[]),Z=(0,l.useCallback)(e=>{k.current=!0,c(e),r({kind:"postal_code",value:e}),(0,o.ZQ)(o.rL.search_submitted,{input_mode:"zip",query:e})},[]),T=(0,l.useCallback)(e=>{var t,a;k.current=!0,c(null!=(a=null==(t=w.Ky.find(t=>t.value===e))?void 0:t.label)?a:e),r({kind:"state",value:e}),(0,o.ZQ)(o.rL.search_submitted,{input_mode:"state",query:e})},[]),O=(0,l.useCallback)(e=>{(0,o.ZQ)(o.rL.clinic_selected,{clinic_id:e});let s=new URL("/partner-clinics/".concat(e),window.location.origin);if(n){let[e,t]=R(n);s.searchParams.set(e,t)}let l=U(a);l&&s.searchParams.set("email",l),h&&s.searchParams.set("from_sign_up",h),t.push(s.pathname+s.search)},[n,t,h,a]),{data:Q}=(0,A.I)({queryKey:["all-clinic-names"],queryFn:()=>I(),staleTime:3e5,enabled:m,select:e=>e.message.data.map(e=>({id:e.id,site_name:e.site_name}))}),B=(0,l.useCallback)(()=>{v(!0)},[]),W=null!=(e=null==j?void 0:j.message.data)?e:[],[G,...V]=W;return(0,s.jsxs)("div",{className:"min-h-dvh bg-gaia-soft-white flex flex-col",children:[h?(0,s.jsx)(F.D,{sticky:!0,minimal:!0,back:{href:(0,u.p9)(h),label:"Back to plan"}}):(0,s.jsx)(F.D,{sticky:!0}),(0,s.jsxs)("main",{className:"flex-1",children:[(0,s.jsx)(S,{value:i,onChange:K,onAddressSelect:q,onZipDetected:Z,onStateSelect:T,onClinicSelect:O,onSearchFocus:B,clinics:null!=Q?Q:[],onLocate:P,isLocating:f}),(0,s.jsxs)("section",{className:"max-w-[900px] mx-auto w-full px-6 pt-4 pb-10",children:[(0,s.jsxs)("div",{className:"mb-10 bg-gaia-lilac p-4",style:{clipPath:"polygon(0 0, calc(100% - 35.5px) 0, 100% 19.3px, 100% 100%, 0 100%)"},children:[(0,s.jsx)("p",{className:"font-sans font-medium text-base text-gaia-soft-black-700 leading-tight",children:"Did you know?"}),(0,s.jsx)("svg",{width:"106",height:"5",viewBox:"0 0 106 5",fill:"none",className:"mt-0.5 mb-2",children:(0,s.jsx)("path",{d:"M1 3.5C14.2 3.37 77.6 2.75 105 2.5",strokeWidth:"3",strokeLinecap:"round",className:"stroke-gaia-pink"})}),(0,s.jsx)("p",{className:"font-sans text-base leading-[1.4] text-gaia-soft-black-700",children:"IVF and egg freezing treatments require clinic visits roughly every other day over a 2 week period."})]}),N&&(0,s.jsx)("div",{className:"flex flex-col gap-8",children:[1,2,3].map(e=>(0,s.jsxs)("div",{className:"w-full rounded-xl overflow-hidden border border-border bg-white animate-pulse",children:[(0,s.jsx)("div",{className:"h-[143px] lg:h-[245px] bg-gaia-soft-white-alt"}),(0,s.jsxs)("div",{className:"p-6 lg:px-10 lg:py-8 flex flex-col gap-4",children:[(0,s.jsx)("div",{className:"h-5 w-24 bg-gaia-lilac rounded"}),(0,s.jsx)("div",{className:"h-8 w-2/3 bg-gaia-lilac rounded"}),(0,s.jsx)("div",{className:"h-4 w-1/2 bg-gaia-lilac rounded"}),(0,s.jsx)("div",{className:"h-16 bg-gaia-lilac rounded"})]})]},e))}),_&&(0,s.jsx)("p",{className:"font-sans text-base text-gaia-soft-black-700 text-center py-12",children:"Something went wrong loading clinics. Please try again."}),!N&&!_&&0===W.length&&(0,s.jsx)("p",{className:"font-sans text-base text-gaia-soft-black-700 text-center py-12",children:"Sorry — we're not in your state yet. If you're open to remote monitoring, book with New Direction Fertility Centers or search for a nearby state you're willing to travel to."}),!N&&!_&&G&&(0,s.jsxs)("div",{className:"flex flex-col gap-10",children:[(0,s.jsx)("div",{className:"flex flex-col gap-4",children:(0,s.jsx)(b,{clinic:G,origin:n,email:d,priority:!0,section:"gaias_pick",fromSignUp:null!=h?h:void 0,consultPriceUsd:null==z?void 0:z.prices[G.id]})}),V.length>0&&(0,s.jsx)("div",{className:"flex flex-col gap-6",children:(0,s.jsx)("div",{className:"flex flex-col gap-8",children:V.map(e=>(0,s.jsx)(b,{clinic:e,origin:n,email:d,section:"more_options",fromSignUp:null!=h?h:void 0,consultPriceUsd:null==z?void 0:z.prices[e.id]},e.id))})})]})]})]}),(0,s.jsx)(D.Footer,{})]})}},81594:(e,t,a)=>{Promise.resolve().then(a.bind(a,53425))},85602:(e,t,a)=>{"use strict";a.d(t,{O:()=>n});var s=a(12115);function n(){let e=s.useRef(null);return{getToken:s.useCallback(()=>(e.current||(e.current=crypto.randomUUID()),e.current),[]),endSession:s.useCallback(()=>{e.current=null},[])}}}},e=>{e.O(0,[1356,4909,3421,5812,5252,5150,9692,7172,1800,4850,8441,8229,7956,7358],()=>e(e.s=81594)),_N_E=e.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.