1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/joggle-page-Dllnfu0Q.js","assets/react-vendor-6-uVh9lA.js","assets/query-vendor-B4HfZuV6.js","assets/assistant-CAEPWFgG.js","assets/ui-root-DBDUP2Wa.js","assets/ui-vendor-root-CmPLdN-9.js","assets/ui-vendor-CcmWsAw-.js","assets/icons-vendor-CNaJirIZ.js","assets/dismissSplash-Tq-TYzTE.js","assets/ui-primitives-lzo5gGe9.js","assets/form-vendor-DNXU13ZK.js","assets/LanguageSelector-BHJENCDZ.js","assets/useCustomerAuth-BYhQbELp.js","assets/CustomerSignedInBadge-BV_dchFH.js","assets/pubEventsQuery-CeSszJ5g.js","assets/stripe-vendor-ChCdcfWP.js","assets/pluginDefinitions-BAMmj5Wb.js","assets/signin-BDEh9pvb.js","assets/safeNextPath-HeTT_csq.js","assets/dashboard-minimal-D9jOHIt9.js","assets/sanitize-AZwDqXct.js","assets/businessSectors-CGMBI_XL.js","assets/isImageFile-CG2Sj1yp.js","assets/useMenuIndex-wr484eS0.js","assets/StripeConnectSettings-BzxXWw-I.js","assets/dnd-vendor-CyqPT-YX.js","assets/JgFeedback-TSriP_EC.js","assets/StaffPhoto-D9LPrbCX.js","assets/use-mobile-CPGA1m5a.js","assets/onboardingAnalytics-omIUksI-.js","assets/OwnerPageHeader-DUpDzrAP.js","assets/useSmartSetup-DjVxa8cI.js","assets/OwnersManager-Y6napnDi.js","assets/useIsPageVisible-CMHqsU9k.js","assets/PersonalDashboardRouter-BExFlPr_.js","assets/usePersonalAuth-CB5iHCO_.js","assets/usePersonalTier-BPzCzUvU.js","assets/personalTiers-DKw7Unyv.js","assets/DashboardHome-BDz7lhQy.js","assets/joggle-home-BuNXSvB-.js","assets/useGeoPricing-DlUxFGDX.js","assets/businessPlans-rqLBMiy5.js","assets/homepage-B_YnMwz1.js","assets/sites-workspace-CyPN7tNV.js","assets/recruitment-job-Car8403W.js","assets/cvMatchShared-BJ522LaY.js","assets/recruiter-cv-check-DmrYj_ZH.js","assets/business-pricing-CB2AL_hw.js","assets/owner-connect-Dn4JJYS4.js","assets/LocalizedLanding-DvU6B2mY.js","assets/usePageTranslation-b0C8N_VK.js","assets/ThemeToggle-Bb2aUugI.js","assets/LanguageLoadingOverlay-Cip4pQ8r.js","assets/proxy-C3Zmo0vs.js","assets/search-BFSkGqE5.js","assets/PublicBlocks-OIgMoBK1.js","assets/JgOverlay-CA2g45EY.js","assets/search-prev-25l1QpwQ.js","assets/InvestorsLanding-DWUfcB-7.js","assets/InvestorLayout-Dk6L9yM4.js","assets/InvestorSignIn-BXTHd-4O.js","assets/InvestorRegister-ClFKfMkz.js","assets/InvestorUpdates-DHI0XJzm.js","assets/InvestorProtectedLayout-D0v78p32.js","assets/InvestorMaterials-Doam2Pz3.js","assets/InvestorDeckPage-CixJ9nes.js","assets/deckSlides-CHMvlvWU.js","assets/InvestorAdmin-BJPN42SD.js","assets/AffiliatesLanding-DnjloXVu.js","assets/AffiliateLayout-BZ-DiJQw.js","assets/AffiliatesRegister-DJJojfFo.js","assets/AffiliatesDeckPage-BOWAqQmE.js","assets/username-tool-route-qcTKZzP1.js","assets/contribute-K-2AtDXm.js","assets/signage-player-B7aGjHF6.js","assets/signage-player-uOIHcZV8.css","assets/receptionist-app-Dw_HUyyU.js","assets/admin-wusXjwjI.js","assets/admin-personal-funnel-DPKrqm4z.js","assets/admin-onboarding-funnel-EJhdPa4h.js","assets/admin-help-content-B_vYhmnN.js","assets/admin-email-programme-CHwr3GcS.js","assets/admin-meet-Q2eb5GIB.js","assets/admin-sms-billing-CuKCdYug.js","assets/admin-community-ops-DWIWgKVg.js","assets/LineChart-DKVD2vbS.js","assets/CartesianGrid-lEPXj6No.js","assets/admin-community-queue-DUyVeRe7.js","assets/aime-OtV6Hj_Y.js","assets/document-intelligence-CS2SlTdn.js","assets/import-manager-DLm22sm-.js","assets/owner-design-system-D7IlDOg5.js","assets/joggle-home-ds-D0O0Ok5D.js","assets/public-contact-jl_X8qPI.js","assets/public-examples-BySiQig6.js","assets/public-how-it-works-BlTn4Tb_.js","assets/public-pricing-BEj021YL.js","assets/change-password-CYRciHmy.js","assets/pub-D6_tB6_b.js","assets/agents-Za8_U5eU.js","assets/lite-JIcvVWqx.js","assets/ai-discoverability-0pdg5oEW.js","assets/lite-register-D5I8kLow.js","assets/lite-success-B2f5_i6B.js","assets/claim-joggle-BGBluA3b.js","assets/claim-search-DGkLFJcL.js","assets/activate-search-C2mKBzji.js","assets/jain-CJrCKDqj.js","assets/waitlist-Nlo5IoNn.js","assets/reserve-BFcLxhHt.js","assets/AcceptStaffInvite-D9fyEzxa.js","assets/MyRota-DBrsWo7N.js","assets/AskRota-Hsa4rJZT.js","assets/RotaInvite-vqC_ZZuF.js","assets/business-assistant-3bozOcj8.js","assets/auth-CxXWv4es.js","assets/aurevoir-8WlHZapA.js","assets/forgot-password-rkpliEG9.js","assets/reset-password-BSGK7noo.js","assets/set-password-C6VAXoOu.js","assets/verify-email-B_HCLRcQ.js","assets/onboarding-BI4tSU3B.js","assets/accept-invite-xhrh_mEF.js","assets/subscribe-DTuXQMmL.js","assets/upgrade-CsnX-A0z.js","assets/go-pro-CxP0PkdM.js","assets/SectorLanding-3hPlKH4k.js","assets/BookingsManagement-BwbVBuIe.js","assets/BookingsSettings-OW1O1jcI.js","assets/BookingMethodPage-DE7Y83Z0.js","assets/FloorPlanEditor-Cdk1YJ1H.js","assets/meeting-type-settings-DsCzgGqj.js","assets/AIWriteButton-CJga8fkH.js","assets/calendar-connections-CkQswdr9.js","assets/provider-connections-CPeZksyj.js","assets/TicketCheckPage-D3Wku1TG.js","assets/EmailProviderChecker-C6jrns2r.js","assets/EmailClient-D7BEbqHD.js","assets/EmailDashboard-Bvs0IFHu.js","assets/ai-customer-support-for-small-business-Byhi6Prs.js","assets/seo-landing-CRY57h3R.js","assets/PublicPageLayout-C_ZtdJjI.js","assets/ai-chatbot-for-small-business-CyMbyGP1.js","assets/automated-customer-enquiries-D6y8YE7o.js","assets/ai-customer-service-assistant-DNZwVVQz.js","assets/capture-customer-enquiries-automatically-Bhob7g86.js","assets/ai-chatbot-for-pubs-DGaDLy_b.js","assets/ai-chatbot-for-restaurants-DB1wckIM.js","assets/ai-chatbot-for-cafes-Bu-iJjyv.js","assets/ai-chatbot-for-hotels-O2Zui2Y7.js","assets/ai-chatbot-for-gyms-D5RG9zZP.js","assets/ai-chatbot-for-hairdressers-iTAF-asw.js","assets/ai-chatbot-for-tourism-ZVWo9HWv.js","assets/never-miss-a-booking-request-tCdY7Wmu.js","assets/automated-booking-enquiries-DFTk8MEe.js","assets/case-study-we-three-loggerheads-DVeeUAzj.js","assets/how-a-pub-automated-customer-enquiries-BFso0B4N.js","assets/ai-chatbot-london-CfzeRvo-.js","assets/ai-chatbot-manchester-Cq_psSxH.js","assets/ai-chatbot-wales-DSAZBtra.js","assets/blog-index-CwgmPmgD.js","assets/articles-C3HJEzaZ.js","assets/blog-article-Drfq6dgw.js","assets/DiscoveryHubPage-DOVg4G5C.js","assets/FoundHub-CI76ON2-.js","assets/foundStyles-LUYHF-99.js","assets/FoundTrades-CvVOiQK2.js","assets/LaunchLayout-DhnhMMNd.js","assets/launch-tokens-CnLqAkJu.css","assets/PricingBand-CdIFXSWJ.js","assets/analytics-D-byUcvl.js","assets/FAQAccordion-BBUt9-_6.js","assets/FinalCtaBand-BXSCfUsD.js","assets/FoundHospitality-7fuPjA2O.js","assets/FoundLocal
1Services-BfO_1PAR.js","assets/FoundMold-Cm935YGh.js","assets/FoundPricing-mdECmRvw.js","assets/FoundHelp-ic5rn_vz.js","assets/FoundAbout-CKKxquWH.js","assets/FoundStart-Dfs3CBFc.js","assets/FoundWelcome-BFmQvOMp.js","assets/FoundHow-DGk4aSof.js","assets/FoundScore-BktRZc1K.js","assets/FoundScoreChecking-wlGWbJ4x.js","assets/FoundScoreReport-CTyeDQcs.js","assets/logout-D2KWlCVd.js","assets/terms-B6dlK2C2.js","assets/LegalPageLayout-BK95yGQz.js","assets/privacy-BD_C1ez-.js","assets/cookies-CxhH5sQg.js","assets/careers-C3NyVIlH.js","assets/shareholders-F7y0Mnuz.js","assets/not-found-BC9oWPCG.js","assets/unsubscribe-B2GMKv-c.js","assets/register-business-BifhEe3C.js","assets/public-personal-profile-DKdRC-ft.js","assets/formatBio-CiQ4ot4d.js","assets/personalDomain-BF9y5e_H.js","assets/gallerySlug-DFcJottg.js","assets/index-1ANBSlsM.js","assets/PublicMediaKit-pX3q3Bu6.js","assets/MoveFromLinktree-C5Ra_vGB.js","assets/GuestSpacePage-BsDZ_DSX.js","assets/public-personal-card-DCNzFnyu.js","assets/connect-claim-Cuo5zDmk.js","assets/Markdown-8vGE2z2f.js","assets/public-personal-event-Bn1l5J06.js","assets/personal-chat-interface-D19mivpC.js","assets/VoiceChatHandler-CF3naA86.js","assets/useVoiceEngine-Cs-CD1RM.js","assets/joggle-voice-jingle-DalZ7wsI.js","assets/PublicBlog-Cm0iobCC.js","assets/blogTheme-C7F1Cx8p.js","assets/PublicBlogPost-3hxTbzD1.js","assets/public-personal-gallery-Cg9mGPtv.js","assets/useDocumentFavicon-gvWkfQ4b.js","assets/MediaLightbox-lEzN9Cpw.js","assets/CollectionTiles-DcTKofqR.js","assets/public-personal-cv-BWhM3Z5t.js","assets/public-personal-cv-chapters-BHQhaltV.js","assets/public-personal-cv-threads-CqpozRHu.js","assets/public-personal-cv-cinematic-BR51_VXv.js","assets/public-personal-film-Bh6eCGM6.js","assets/FilmStage-Cz85wnWj.js","assets/start-CGhxQ7BS.js","assets/create-joggle-tGoPFLxE.js","assets/verify-plan-Bx_vdUA2.js","assets/activate-joggle-_wBURBoL.js","assets/register-step1-BZ08RZVL.js","assets/RegistrationProgress-DuYBCY9k.js","assets/register-step2-DK2fhfmv.js","assets/register-step3-C3LGeOtW.js","assets/register-step4-C9IoPKca.js","assets/register-business-find-D1AjXev4.js","assets/register-business-account-BEhlsP1F.js","assets/register-business-verify-BfdtU272.js","assets/register-business-reveal-BCCeYO1K.js","assets/public-booking-BAhIw4nf.js","assets/public-booking-reschedule-h-d2OwDh.js","assets/public-booking-cancel-IArRNAQ6.js","assets/personal-start-2QI6V6uP.js","assets/personal-signin-DLWcuLiC.js","assets/joggle-pro-home-DjYk4gvh.js","assets/personal-landing-new-C5r7Bsu7.js","assets/personal-landing-DAHYDN1P.js","assets/personal-onboarding-DpyNztz3.js","assets/personal-register-DzuneuOZ.js","assets/personal-pricing-SCYqdJfs.js","assets/personal-privacy-CyYyT1vx.js","assets/personal-terms-BIj2J3tU.js","assets/Feedback-9u_QQ1yu.js","assets/FeedbackList-D3dOTMX_.js","assets/FeedbackDetail-mfxvQCyz.js","assets/CustomerBookingPage-CaqsdkXh.js","assets/BookingWidgetRedirect-CHxbCzep.js","assets/DepositPaymentPage-DMR-OkHE.js","assets/CardGuaranteePage-wC2CHOcj.js","assets/room-booking-status-Cpt7EGHH.js","assets/ServiceJobStatus-h72qITml.js","assets/joggle-icon-dark-CHV-yxDL.js","assets/ServiceInvoicePayment-CGGm6sJI.js","assets/TradesBookingWizard-CRVIC8VW.js","assets/useTradesT-DN0nnP0J.js","assets/TradesMyBookings-8NDYN8TM.js","assets/TradesDashboardLayout-DgrzBQjb.js","assets/VoiceSettings-Cg7dNSum.js","assets/YogaDashboardLayout-BWQAYeil.js","assets/yogaDesignTokens-CuwRK6bL.js","assets/FoundDashboardLayout-DoWYFZF3.js","assets/YogaBookingWizard-C9lPbMGa.js","assets/YogaStudioPage-B4quUepg.js","assets/YogaMyClasses-1vjkEAVP.js","assets/joggle-jobs-landing-BpHRTGEX.js","assets/customer-signin-DGcTngqo.js","assets/customer-verify-CqpQxIyo.js","assets/magic-login-Ckvm054F.js","assets/my-messages-CHrQg9y5.js","assets/my-bookings-D7cmM3-g.js","assets/my-booking-detail-BLET2YrS.js","assets/my-booking-receipt-AZQSyeR9.js","assets/my-booking-proof-DOBH8BGk.js","assets/welcome-0-BPOWJIwY.js","assets/welcome-1-DJeqjZ9s.js","assets/welcome-2-D76Iykry.js","assets/welcome-3-Dp0tn813.js","assets/welcome-4-DZft9ANt.js","assets/welcome-5-NqKJsa-v.js","assets/welcome-7-e3CDv4k9.js","assets/app-Dn6DEtjd.css"])))=>i.map(i=>d[i]); 2import{r as l,c as Hn,j as e,R as $n,k as qn,m as Jn,E as Wn}from"./react-vendor-6-uVh9lA.js";import{Q as Kn,u as Xe,a as zn}from"./query-vendor-B4HfZuV6.js";import{u as Yn,T as Qn,b as Xn}from"./ui-root-DBDUP2Wa.js";import{V as Zn}from"./icons-vendor-CNaJirIZ.js";import"./ui-vendor-root-CmPLdN-9.js";import"./ui-vendor-CcmWsAw-.js";(function(){const n=document.createElement("link").relList;if(n&&n.supports&&n.supports("modulepreload"))return;for(const c of document.querySelectorAll('link[rel="modulepreload"]'))i(c);new MutationObserver(c=>{for(const u of c)if(u.type==="childList")for(const d of u.addedNodes)d.tagName==="LINK"&&d.rel==="modulepreload"&&i(d)}).observe(document,{childList:!0,subtree:!0});function s(c){const u={};return c.integrity&&(u.integrity=c.integrity),c.referrerPolicy&&(u.referrerPolicy=c.referrerPolicy),c.crossOrigin==="use-credentials"?u.credentials="include":c.crossOrigin==="anonymous"?u.credentials="omit":u.credentials="same-origin",u}function i(c){if(c.ep)return;c.ep=!0;const u=s(c);fetch(c.href,u)}})();const eo="modulepreload",to=function(t){return"/"+t},Rt={},r=function(n,s,i){let c=Promise.resolve();if(s&&s.length>0){document.getElementsByTagName("link");const d=document.querySelector("meta[property=csp-nonce]"),p=d?.nonce||d?.getAttribute("nonce");c=Promise.allSettled(s.map(m=>{if(m=to(m),m in Rt)return;Rt[m]=!0;const h=m.endsWith(".css"),g=h?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${m}"]${g}`))return;const E=document.createElement("link");if(E.rel=h?"stylesheet":eo,h||(E.as="script"),E.crossOrigin="",E.href=m,p&&E.setAttribute("nonce",p),document.head.appendChild(E),h)return new Promise((b,x)=>{E.addEventListener("load",b),E.addEventListener("error",()=>x(new Error(`Unable to preload CSS for ${m}`)))})}))}function u(d){const p=new Event("vite:preloadError",{cancelable:!0});if(p.payload=d,window.dispatchEvent(p),!p.defaultPrevented)throw d}return c.then(d=>{for(const p of d||[])p.status==="rejected"&&u(p.reason);return n().catch(u)})};function no(t,n){if(t instanceof RegExp)return{keys:!1,pattern:t};var s,i,c,u,d=[],p="",m=t.split("/");for(m[0]||m.shift();c=m.shift();)s=c[0],s==="*"?(d.push(s),p+=c[1]==="?"?"(?:/(.*))?":"/(.*)"):s===":"?(i=c.indexOf("?",1),u=c.indexOf(".",1),d.push(c.substring(1,~i?i:~u?u:c.length)),p+=~i&&!~u?"(?:/([^/]+?))?":"/([^/]+?)",~u&&(p+=(~i?"?":"")+"\\"+c.substring(u))):p+="/"+c;return{keys:d,pattern:new RegExp("^"+p+(n?"(?=$|/)":"/?$"),"i")}}var fn={exports:{}},_n={};/** 3 * @license React 4 * use-sync-external-store-shim.production.js 5 * 6 * Copyright (c) Meta Platforms, Inc. and affiliates. 7 * 8 * This source code is licensed under the MIT license found in the 9 * LICENSE file in the root directory of this source tree. 10 */var Se=l;function oo(t,n){return t===n&&(t!==0||1/t===1/n)||t!==t&&n!==n}var so=typeof Object.is=="function"?Object.is:oo,ro=Se.useState,ao=Se.useEffect,io=Se.useLayoutEffect,co=Se.useDebugValue;function lo(t,n){var s=n(),i=ro({inst:{value:s,getSnapshot:n}}),c=i[0].inst,u=i[1];return io(function(){c.value=s,c.getSnapshot=n,nt(c)&&u({inst:c})},[t,s,n]),ao(function(){return nt(c)&&u({inst:c}),t(function(){nt(c)&&u({inst:c})})},[t]),co(s),s}function nt(t){var n=t.getSnapshot;t=t.value;try{var s=n();return!so(t,s)}catch{return!0}}function uo(t,n){return n()}var mo=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?uo:lo;_n.useSyncExternalStore=Se.useSyncExternalStore!==void 0?Se.useSyncExternalStore:mo;fn.exports=_n;var po=fn.exports;const ho=Hn.useInsertionEffect,go=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",En=go?l.useLayoutEffect:l.useEffect,fo=ho||En,yt=t=>{const n=l.useRef([t,(...s)=>n[0](...s)]).current;return fo(()=>{n[0]=t}),n[1]},_o="popstate",wt="pushState",bt="replaceState",Eo="hashchange",It=[_o,wt,bt,Eo],vo=t=>{for(const n of It)addEventListener(n,t);return()=>{for(const n of It)removeEventListener(n,t)}},vn=(t,n)=>po.useSyncExternalStore(vo,t,n),yo=()=>location.search,wo=({ssrSearch:t=""}={})=>vn(yo,()=>t),Ot=()=>location.pathname,bo=({ssrPath:t}={})=>vn(Ot,t?()=>t:Ot),xo=(t,{replace:n=!1,state:s=null}={})=>history[n?bt:wt](s,"",t),To=(t={})=>[bo(t),xo],Dt=Symbol.for("wouter_v3");if(typeof history<"u"&&typeof window[Dt]>"u"){for(const t of[wt,bt]){const n=history[t];history[t]=function(){const s=n.apply(this,arguments),i=new Event(t);return i.arguments=arguments,dispatchEvent(i),s}}Object.defineProperty(window,Dt,{value:!0})}const Po=(t,n)=>n.toLowerCase().indexOf(t.toLowerCase())?"~"+n:n.slice(t.length)||"/",yn=(t="")=>t==="/"?"":t,jo=(t,n)=>t[0]==="~"?t.slice(1):yn(n)+t,ko=(t="",n)=>Po(gt(yn(t)),gt(n)),So=t=>t[0]==="?"?t.slice(1):t,gt=t=>{try{return decodeURI(t)}catch{return t}},Lo=t=>gt(So(t)),wn={hook:To,searchHook:wo,parser:no,base:"",ssrPath:void 0,ssrSearch:void 0,ssrContext:void 0,hrefs:t=>t},bn=l.createContext(wn),fe=()=>l.useContext(bn),xn={},Tn=l.createContext(xn),Ao=()=>l.useContext(Tn),He=t=>{const[n,s]=t.hook(t);return[ko(t.base,n),yt((i,c)=>s(jo(i,t.base),c))]},xt=()=>He(fe()),zi=()=>{const t=fe();return Lo(t.searchHook(t))},Tt=(t,n,s,i)=>{const{pattern:c,keys:u}=n instanceof RegExp?{keys:!1,pattern:n}:t(n||"*",i),d=c.exec(s)||[],[p,...m]=d;return p!==void 0?[!0,(()=>{const h=u!==!1?Object.fromEntries(u.map((E,b)=>[E,m[b]])):d.groups;let g={...m};return h&&Object.assign(g,h),g})(),...i?[p]:[]]:[!1,null]},Yi=t=>
10Tt(fe().parser,t,xt()[0]),Ro=({children:t,...n})=>{const s=fe(),i=n.hook?wn:s;let c=i;const[u,d]=n.ssrPath?.split("?")??[];d&&(n.ssrSearch=d,n.ssrPath=u),n.hrefs=n.hrefs??n.hook?.hrefs;let p=l.useRef({}),m=p.current,h=m;for(let g in i){const E=g==="base"?i[g]+(n[g]||""):n[g]||i[g];m===h&&E!==h[g]&&(p.current=h={...h}),h[g]=E,(E!==i[g]||E!==c[g])&&(c=h)}return l.createElement(bn.Provider,{value:c,children:t})},Ct=({children:t,component:n},s)=>n?l.createElement(n,{params:s}):typeof t=="function"?t(s):t,Io=t=>{let n=l.useRef(xn);const s=n.current;return n.current=Object.keys(t).length!==Object.keys(s).length||Object.entries(t).some(([i,c])=>c!==s[i])?t:s},o=({path:t,nest:n,match:s,...i})=>{const c=fe(),[u]=He(c),[d,p,m]=s??Tt(c.parser,t,u,n),h=Io({...Ao(),...p});if(!d)return null;const g=m?l.createElement(Ro,{base:m},Ct(i,h)):Ct(i,h);return l.createElement(Tn.Provider,{value:h,children:g})},Qi=l.forwardRef((t,n)=>{const s=fe(),[i,c]=He(s),{to:u="",href:d=u,onClick:p,asChild:m,children:h,className:g,replace:E,state:b,...x}=t,k=yt(A=>{A.ctrlKey||A.metaKey||A.altKey||A.shiftKey||A.button!==0||(p?.(A),A.defaultPrevented||(A.preventDefault(),c(d,t)))}),N=s.hrefs(d[0]==="~"?d.slice(1):s.base+d,s);return m&&l.isValidElement(h)?l.cloneElement(h,{onClick:k,href:N}):l.createElement("a",{...x,onClick:k,href:N,className:g?.call?g(i===d):g,children:h,ref:n})}),Pn=t=>Array.isArray(t)?t.flatMap(n=>Pn(n&&n.type===l.Fragment?n.props.children:n)):[t],Ke=({children:t,location:n})=>{const s=fe(),[i]=He(s);for(const c of Pn(t)){let u=0;if(l.isValidElement(c)&&(u=Tt(s.parser,c.props.path,n||i,c.props.nest))[0])return l.cloneElement(c,{match:u})}return null},Nt=t=>{const{to:n,href:s=n}=t,i=fe(),[,c]=He(i),u=yt(()=>c(n||s,t)),{ssrContext:d}=i;return En(()=>{u()},[]),d&&(d.redirectTo=n),null};async function jn(t){if(!t.ok){let n=await t.text()||t.statusText;try{const s=JSON.parse(n);(s?.message||s?.error)&&(n=s.message||s.error)}catch{}throw new Error(`${t.status}: ${n}`)}}class Oo{constructor(){this.token=null,this.fetchingToken=null}async getToken(){if(this.token)return this.token;if(this.fetchingToken)return this.fetchingToken;this.fetchingToken=this.fetchTokenFromServer();try{return this.token=await this.fetchingToken,this.token}finally{this.fetchingToken=null}}async fetchTokenFromServer(){const n=await fetch("/api/csrf-token",{credentials:"include"});if(!n.ok)throw new Error("Failed to fetch CSRF token");return(await n.json()).csrfToken}clearToken(){this.token=null}}const Le=new Oo;async function kn(t,n={},s=0){const{method:i="GET",headers:c={},...u}=n,d=new Headers(c);if(i!=="GET"&&i!=="HEAD"&&i!=="OPTIONS")try{const m=await Le.getToken();d.set("X-CSRF-Token",m)}catch(m){console.warn("Failed to get CSRF token:",m)}const p=await fetch(t,{method:i,headers:d,credentials:"include",...u});return p.status===403&&s===0?(Le.clearToken(),kn(t,n,1)):p}async function Pt(t,n="GET",s,i=0,c){const u={},d=c?.timeout??3e4;if(s&&!(s instanceof FormData)&&(u["Content-Type"]="application/json"),n!=="GET"&&n!=="HEAD"&&n!=="OPTIONS")try{const h=await Le.getToken();u["X-CSRF-Token"]=h}catch{}const p=new AbortController,m=setTimeout(()=>p.abort(),d);try{const h=await fetch(t,{method:n,headers:u,body:s instanceof FormData?s:s?JSON.stringify(s):void 0,credentials:"include",signal:c?.signal??p.signal});if(clearTimeout(m),h.status===403&&i===0)return Le.clearToken(),Pt(t,n,s,1,c);await jn(h);const g=await h.text();return g?JSON.parse(g):null}catch(h){throw clearTimeout(m),h instanceof Error&&h.name==="AbortError"?new Error(`Request timeout after ${d}ms`):h}}async function Sn(t,n,s,i){const c=i?.timeout??12e4;let u="";try{u=await Le.getToken()}catch{}return new Promise((d,p)=>{const m=new XMLHttpRequest;m.open("POST",t,!0),m.withCredentials=!0,m.timeout=c,u&&m.setRequestHeader("X-CSRF-Token",u),m.upload.onprogress=h=>{h.lengthComputable&&s&&s(Math.round(h.loaded/h.total*100))},m.onload=async()=>{if(m.status===403&&(i?.retryCount??0)===0){Le.clearToken();try{d(await Sn(t,n,s,{...i,retryCount:1}))}catch(g){p(g)}return}if(m.status>=200&&m.status<300){try{d(m.responseText?JSON.parse(m.responseText):null)}catch{d(null)}return}let h=`${m.status}: ${m.statusText}`;try{const g=JSON.parse(m.responseText);g?.error&&(h=g.error)}catch{m.responseText&&(h=m.responseText)}p(new Error(h))},m.onerror=()=>p(new Error("Upload failed â network error")),m.ontimeout=()=>p(new Error(`Upload timed out after ${c}ms`)),m.send(n)})}const jt=({on401:t})=>async({queryKey:n})=>{const s=n.join("/"),i=typeof window<"u"&&window.__jogglePreload||null;if(i&&i[s]){const u=i[s];delete i[s];try{const d=await u;if(d!=null)return d}catch{}}const c=await fetch(s,{credentials:"include"});return t==="returnNull"&&c.status===401?null:(await jn(c),await c.json())},kt=new Kn({defaultOptions:{queries:{queryFn:jt({on401:"throw"}),refetchInterval:!1,refetchOnWindowFocus:!1,staleTime:5*60*1e3,gcTime:10*60*1e3,retry:(t,n)=>n instanceof Error&&n.message.startsWith("4")?!1:t<2,retryDelay:t=>Math.min(1e3*2**t,1e4)},mutations:{retry:!1}}}),Do=Object.freeze(Object.defineProperty({__proto__:null,apiRequest:Pt,fetchWithCSRF:kn,getQueryFn:jt,queryClient:kt,uploadWithProgress:Sn},Symbol.toStringTag,{value:"Module"}));function Co(t=window.location.hostname){return t.toLowerCase().replace(/(^|\.)staging\.joggle\./,"$1joggle.")}function No(t=window.location.hostname){const n=Co(t);return n==="joggle.pro"||n==="www.joggle.pro"}const Vo=[()=>r(()=>import("./joggle-page-Dllnfu0Q.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16]))],Mo=[()=>r(()=>import("./signin-BDEh9pvb.js"),__vite__mapDeps([17,1,9,4,5,6,7,10,18,2]))],Bo=[()=>r(()=>import("./dashboard-minimal-D9jOHIt9.js").then(t=>t.d),__vite__mapDeps([19,1,20,4,5,6,7,14,2,9,10,21,22,23,24,25,26,27,28,29,30,31,32,33])),()=>r(()=>import("./PersonalDashboardRouter-BExFlPr_.js"),__vite__mapDeps([34,1,2,4,5,6,7,35,36,37,9,10])),()=>r(()=>import("./DashboardHome-BDz7lhQy.js"),__vite__mapDeps([38,1,22,2,35,36,37,4,5,6,7]))],Fo=/^\/(?:|about|blog|pricing|business-pricing|get-started|start|register|signup|lite|pub|pubs|restaurants|salons|trades|sectors|tools|found|go-pro|upgrade)(?:\/|$)/;let Vt=!1,Mt=!1;function Bt(t){const n=()=>{for(const s of t)s().catch(()=>{})};"requestIdleCallback"in window?window.requestIdleCallback(n,{timeout:5e3}):setTimeout(n,2500)}function Uo(){const t=navigator.connection;return!(t?.saveData||t?.effectiveType&&/(^|-)2g$/.test(t.effectiveType))}function Ln(t=!1){if(Uo()){if(!Vt){Vt=!0;const n=typeof location<"u"?location.pathname:"/";Bt(Fo.test(n)?Mo:Vo)}t&&!Mt&&(Mt=!0,Bt(Bo))}}function $e(){const{data:t,isLoading:n,isFetching:s,error:i,isStale:c}=Xe({queryKey:["/api/auth/user"],queryFn:jt({on401:"returnNull"}),retry:!1,refetchOnWindowFocus:!1,staleTime:3e5});return{user:t??null,isLoading:n,isFetching:s,isAuthenticated:!!t,isConfirmed:!n&&!s,error:i}}function Ft(t){if(!t||!/^\d+$/.test(t))return null;const n=Number(t);return Number.isSafeInteger(n)&&n>0?n:null}function Go(t){const{sites:n}=t;if(!n||n.length===0)return null;const s=i=>i!==null&&n.some(c=>c.id===i)?i:null;return t.killSwitch?s(t.primaryId??null)??n[0].id:s(t.override??null)??s(Ft(t.urlParam))??s(Ft(t.stored))??s(t.primaryId??null)??n[0].id}function Xi(t,n){if(!(!t||t.length===0))return t.find(s=>
10s.id===n)??t[0]}function ft(t){return`joggle.selectedAssistantId.${t??"anon"}`}const An=l.createContext(null);function Rn(){const t=l.useContext(An);if(!t)throw new Error("useSelectedAssistant must be used within SelectedAssistantProvider");return t}function Ho(t){try{return window.sessionStorage.getItem(t)}catch{return null}}function $o(t,n){try{window.sessionStorage.setItem(t,n)}catch{}}function qo(){try{return new URLSearchParams(window.location.search).get("assistant")}catch{return null}}function Jo(){try{return new URLSearchParams(window.location.search).get("sites")==="off"}catch{return!1}}function Wo(t){try{const n=new URL(window.location.href);if(n.searchParams.get("assistant")===String(t))return;n.searchParams.set("assistant",String(t)),window.history.replaceState({},"",n.toString())}catch{}}function Ko({children:t}){const{user:n}=$e(),s=n?.id??null,{data:i,isLoading:c}=Xe({queryKey:["/api/owner/sites"],enabled:!!n,staleTime:6e4}),[u,d]=l.useState(null),p=i?.sites,[m]=l.useState(qo),[h]=l.useState(Jo),g=l.useMemo(()=>Go({override:u,urlParam:m,stored:Ho(ft(s)),primaryId:i?.primaryAssistantId??null,sites:p,killSwitch:h}),[u,m,h,s,i?.primaryAssistantId,p]),E=l.useMemo(()=>p?.find(k=>k.id===g)??null,[p,g]);l.useEffect(()=>{g!==null&&s!==null&&($o(ft(s),String(g)),h||Wo(g))},[g,s,h]);const b=l.useCallback(k=>{p?.some(N=>N.id===k)&&d(k)},[p]),x=l.useMemo(()=>({sites:p??[],selectedId:g,selected:E,isMultiSite:(p?.length??0)>1,isLoading:c,selectSite:b}),[p,g,E,c,b]);return e.jsx(An.Provider,{value:x,children:t})}function Ze(t){return["/api/dashboard",t]}function St(t){return Pt(t===null?"/api/dashboard":`/api/dashboard?assistantId=${t}`)}function Zi(){const{selectedId:t}=Rn();return l.useMemo(()=>Ze(t),[t])}function ec(t,n=!0){return Xe({queryKey:Ze(t),enabled:n&&t!==null,queryFn:()=>St(t),retry:!1,staleTime:3e4})}function tc(){const{user:t}=$e(),{selectedId:n,isLoading:s}=Rn();return Xe({queryKey:Ze(n),enabled:!!t&&!s,queryFn:()=>St(n),retry:!1,staleTime:3e4})}function zo(t,n){let s=null;try{const i=new URLSearchParams(window.location.search).get("assistant");s=i?Number(i):n?Number(n):null}catch{s=n?Number(n):null}!s||Number.isNaN(s)||t.prefetchQuery({queryKey:Ze(s),queryFn:()=>St(s),staleTime:3e4}).catch(()=>{})}const Ut="jg.public.ds";function ot(){if(typeof window>"u")return!0;try{const t=new URLSearchParams(window.location.search).get("v");if(t==="ds"||t==="old"){const n=t==="ds";try{window.sessionStorage.setItem(Ut,String(n))}catch{}return n}}catch{}try{return window.sessionStorage.getItem(Ut)!=="false"}catch{return!0}}let Gt=!1;function Yo(){if(Gt||typeof window>"u")return;Gt=!0;const t=()=>window.dispatchEvent(new Event("eb:navigate"));["pushState","replaceState"].forEach(n=>{const s=history[n];history[n]=function(...i){const c=s.apply(this,i);return t(),c}}),window.addEventListener("popstate",t)}class Qo extends $n.Component{constructor(n){super(n),this.handleNavigate=()=>{this.state.hasError&&this.setState({hasError:!1,error:void 0})},this.handleReset=()=>{if(this.state.errorCount>=3){window.location.reload();return}this.setState({hasError:!1,error:void 0}),this.props.onReset?.()},this.state={hasError:!1,errorCount:0}}static getDerivedStateFromError(n){return{hasError:!0,error:n}}componentDidMount(){Yo(),window.addEventListener("eb:navigate",this.handleNavigate)}componentWillUnmount(){window.removeEventListener("eb:navigate",this.handleNavigate)}componentDidCatch(n,s){this.setState(u=>({errorCount:u.errorCount+1})),console.error("[ErrorBoundary]",n?.message,n,s?.componentStack);const i=`${n?.name||""} ${n?.message||""}`;if(/Failed to fetch dynamically imported module|Importing a module script failed|Loading (?:CSS )?chunk|ChunkLoadError|dynamically imported module|error loading dynamically imported module/i.test(i))try{const u="eb_chunk_reload_at",d=Number(sessionStorage.getItem(u)||0);Date.now()-d>15e3&&(sessionStorage.setItem(u,String(Date.now())),window.location.reload())}catch{}}render(){return this.state.hasError?this.props.fallback?this.props.fallback:e.jsx("div",{className:"min-h-screen flex items-center justify-center bg-gray-50 p-4",children:e.jsxs("div",{className:"text-center max-w-md",children:[e.jsx("div",{className:"w-16 h-16 mx-auto mb-4 bg-red-100 rounded-full flex items-center justify-center",children:e.jsx("svg",{className:"w-8 h-8 text-red-600",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-2.5L13.732 4c-.77-.833-1.964-.833-2.732 0L3.732 16.5c-.77.833.192 2.5 1.732 2.5z"})})}),e.jsx("h1",{className:"text-xl font-semibold text-gray-900 mb-2",children:"Something went wrong"}),e.jsx("p",{className:"text-gray-600 mb-4",children:"The app encountered an error. Please try again."}),this.state.error?.message&&e.jsx("p",{className:"text-xs text-gray-400 mb-4 break-words font-mono",children:this.state.error.message}),e.jsxs("div",{className:"flex gap-3 justify-center",children:[e.jsx("button",{onClick:this.handleReset,className:"px-4 py-2 bg-gray-200 text-gray-800 rounded-md hover:bg-gray-300 transition-colors",children:"Try Again"}),e.jsx("button",{onClick:()=>window.location.reload(),className:"px-4 py-2 bg-joggle-orange-500 text-white rounded-md hover:bg-joggle-orange-600 transition-colors",children:"Refresh Page"})]})]})}):this.props.children}}const Ht="/assets/joggle-icon-dark-CwUaBbFb.gif",Xo="/assets/joggle-icon-light-XcNdx_GR.gif",$t={dark:Ht,light:Xo,default:Ht};function Ue({variant:t="default",alt:n="Joggle",className:s,style:i,...c}){const[u,d]=l.useState(!1);return u?e.jsx("span",{className:s,style:{display:"inline-flex",alignItems:"center",justifyContent:"center",fontWeight:700,fontSize:"0.75em",background:"#f97316",color:"#fff",borderRadius:"0.375rem",...i},"aria-label":n,children:"J"}):e.jsx("img",{src:$t[t]||$t.default,alt:n,className:s,style:i,onError:()=>d(!0),...c})}function $({children:t}){const{user:n,isLoading:s,isConfirmed:i}=$e(),[,c]=xt(),[u,d]=l.useState(!1);return l.useEffect(()=>
10{i&&(d(!0),n?n.isAdmin||c("/dashboard"):c("/signin"))},[n,i,c]),s||!u?e.jsx("div",{className:"flex items-center justify-center min-h-screen bg-white",children:e.jsxs("div",{className:"flex flex-col items-center gap-3",children:[e.jsx(Ue,{className:"w-10 h-10"}),e.jsx("span",{className:"text-[15px] font-medium text-black",children:"I'm on it."})]})}):!n||!n.isAdmin?null:e.jsx(e.Fragment,{children:t})}const In=l.createContext(void 0),On="joggle-theme";function st(){return typeof window>"u"?"light":window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}function qt(){if(typeof window>"u")return null;try{const t=localStorage.getItem(On);if(t==="light"||t==="dark"||t==="system")return t}catch{}return null}function rt(t,n=!1){const s=document.documentElement;n&&s.classList.add("theme-transition"),s.classList.remove("light","dark"),s.classList.add(t),s.style.colorScheme=t,n&&setTimeout(()=>s.classList.remove("theme-transition"),300)}function Zo({children:t}){const[n,s]=l.useState(()=>qt()||"light"),[i,c]=l.useState(()=>{const p=qt();return p&&p!=="system"?p:p?st():"light"}),u=l.useCallback(p=>{s(p);try{localStorage.setItem(On,p)}catch{}const m=p==="system"?st():p;c(m),rt(m,!0)},[]),d=l.useCallback(()=>{u(i==="dark"?"light":"dark")},[i,u]);return l.useEffect(()=>{const p=n==="system"?st():n;c(p),rt(p)},[n]),l.useEffect(()=>{if(n!=="system")return;const p=window.matchMedia("(prefers-color-scheme: dark)"),m=h=>{const g=h.matches?"dark":"light";c(g),rt(g)};return p.addEventListener("change",m),()=>p.removeEventListener("change",m)},[n]),e.jsx(In.Provider,{value:{theme:n,resolvedTheme:i,setTheme:u,toggleTheme:d},children:t})}function nc(){const t=l.useContext(In);if(!t)throw new Error("useTheme must be used within a ThemeProvider");return t}const le=[{code:"en-GB",name:"English (UK)",englishName:"English (UK)",flag:"ð¬ð§"},{code:"en-US",name:"English (US)",englishName:"English (US)",flag:"ðºð¸"},{code:"es",name:"Español",englishName:"Spanish",flag:"ðªð¸"},{code:"fr",name:"Français",englishName:"French",flag:"ð«ð·"},{code:"de",name:"Deutsch",englishName:"German",flag:"ð©ðª"},{code:"it",name:"Italiano",englishName:"Italian",flag:"ð®ð¹"},{code:"pt",name:"Português",englishName:"Portuguese",flag:"ðµð¹"},{code:"ru",name:"Ð ÑÑÑкий",englishName:"Russian",flag:"ð·ðº"},{code:"uk",name:"УкÑаÑнÑÑка",englishName:"Ukrainian",flag:"ðºð¦"},{code:"zh-CN",name:"䏿 (ç®ä½)",englishName:"Chinese (Simplified)",flag:"ð¨ð³"},{code:"zh-TW",name:"䏿 (ç¹é«)",englishName:"Chinese (Traditional)",flag:"ð¹ð¼"},{code:"ja",name:"æ¥æ¬èª",englishName:"Japanese",flag:"ð¯ðµ"},{code:"ko",name:"íêµì´",englishName:"Korean",flag:"ð°ð·"},{code:"ar",name:"Ø§ÙØ¹Ø±Ø¨ÙØ©",englishName:"Arabic",flag:"ð¸ð¦"},{code:"hi",name:"हिनà¥à¤¦à¥",englishName:"Hindi",flag:"ð®ð³"},{code:"tr",name:"Türkçe",englishName:"Turkish",flag:"ð¹ð·"},{code:"pl",name:"Polski",englishName:"Polish",flag:"ðµð±"},{code:"nl",name:"Nederlands",englishName:"Dutch",flag:"ð³ð±"},{code:"sv",name:"Svenska",englishName:"Swedish",flag:"ð¸ðª"},{code:"da",name:"Dansk",englishName:"Danish",flag:"ð©ð°"},{code:"no",name:"Norsk",englishName:"Norwegian",flag:"ð³ð´"},{code:"fi",name:"Suomi",englishName:"Finnish",flag:"ð«ð®"},{code:"cs",name:"ÄeÅ¡tina",englishName:"Czech",flag:"ð¨ð¿"},{code:"hu",name:"Magyar",englishName:"Hungarian",flag:"ððº"},{code:"ro",name:"RomânÄ",englishName:"Romanian",flag:"ð·ð´"},{code:"bg",name:"ÐÑлгаÑÑки",englishName:"Bulgarian",flag:"ð§ð¬"},{code:"hr",name:"Hrvatski",englishName:"Croatian",flag:"ðð·"},{code:"sk",name:"SlovenÄina",englishName:"Slovak",flag:"ð¸ð°"},{code:"sl",name:"SlovenÅ¡Äina",englishName:"Slovenian",flag:"ð¸ð®"},{code:"et",name:"Eesti",englishName:"Estonian",flag:"ðªðª"},{code:"lv",name:"LatvieÅ¡u",englishName:"Latvian",flag:"ð±ð»"},{code:"lt",name:"Lietuvių",englishName:"Lithuanian",flag:"ð±ð¹"},{code:"th",name:"à¹à¸à¸¢",englishName:"Thai",flag:"ð¹ð"},{code:"vi",name:"Tiếng Viá»t",englishName:"Vietnamese",flag:"ð»ð³"},{code:"id",name:"Bahasa Indonesia",englishName:"Indonesian",flag:"ð®ð©"},{code:"ms",name:"Bahasa Melayu",englishName:"Malay",flag:"ð²ð¾"},{code:"tl",name:"Filipino",englishName:"Filipino",flag:"ðµð"},{code:"he",name:"×¢×ר×ת",englishName:"Hebrew",flag:"ð®ð±"},{code:"fa",name:"ÙØ§Ø±Ø³Û",englishName:"Persian",flag:"ð®ð·"},{code:"ur",name:"اردÙ",englishName:"Urdu",flag:"ðµð°"},{code:"bn",name:"বাà¦à¦²à¦¾",englishName:"Bengali",flag:"ð§ð©"},{code:"ta",name:"தமிழà¯",englishName:"Tamil",flag:"ð±ð°"},{code:"te",name:"à°¤à±à°²à±à°à±",englishName:"Telugu",flag:"ð®ð³"},{code:"ml",name:"മലയാളà´",englishName:"Malayalam",flag:"ð®ð³"},{code:"kn",name:"à²à²¨à³à²¨à²¡",englishName:"Kannada",flag:"ð®ð³"},{code:"gu",name:"àªà«àªàª°àª¾àª¤à«",englishName:"Gujarati",flag:"ð®ð³"},{code:"pa",name:"ਪੰà¨à¨¾à¨¬à©",englishName:"Punjabi",flag:"ð®ð³"},{code:"mr",name:"मराठà¥",englishName:"Marathi",flag:"ð®ð³"},{code:"ne",name:"नà¥à¤ªà¤¾à¤²à¥",englishName:"Nepali",flag:"ð³ðµ"}
10,{code:"si",name:"à·à·à¶à·à¶½",englishName:"Sinhala",flag:"ð±ð°"},{code:"my",name:"áá¼ááºáá¬",englishName:"Burmese",flag:"ð²ð²"},{code:"km",name:"ááááá",englishName:"Khmer",flag:"ð°ð"},{code:"lo",name:"ລາວ",englishName:"Lao",flag:"ð±ð¦"},{code:"ka",name:"á¥áá áá£áá",englishName:"Georgian",flag:"ð¬ðª"},{code:"hy",name:"ÕÕ¡ÕµÕ¥ÖÕ¥Õ¶",englishName:"Armenian",flag:"ð¦ð²"},{code:"az",name:"AzÉrbaycan",englishName:"Azerbaijani",flag:"ð¦ð¿"},{code:"kk",name:"ÒазаÒ",englishName:"Kazakh",flag:"ð°ð¿"},{code:"ky",name:"ÐÑÑгÑз",englishName:"Kyrgyz",flag:"ð°ð¬"},{code:"uz",name:"OÊ»zbek",englishName:"Uzbek",flag:"ðºð¿"},{code:"tg",name:"Тоҷикӣ",englishName:"Tajik",flag:"ð¹ð¯"},{code:"mn",name:"Ðонгол",englishName:"Mongolian",flag:"ð²ð³"},{code:"am",name:"á ááá",englishName:"Amharic",flag:"ðªð¹"},{code:"sw",name:"Kiswahili",englishName:"Swahili",flag:"ð°ðª"},{code:"zu",name:"isiZulu",englishName:"Zulu",flag:"ð¿ð¦"},{code:"af",name:"Afrikaans",englishName:"Afrikaans",flag:"ð¿ð¦"},{code:"is",name:"Ãslenska",englishName:"Icelandic",flag:"ð®ð¸"},{code:"mt",name:"Malti",englishName:"Maltese",flag:"ð²ð¹"},{code:"ga",name:"Gaeilge",englishName:"Irish",flag:"ð®ðª"},{code:"gv",name:"Gaelg",englishName:"Manx",flag:"ð®ð²"},{code:"cy",name:"Cymraeg",englishName:"Welsh",flag:"ð´ó §ó ¢ó ·ó ¬ó ³ó ¿"},{code:"eu",name:"Euskera",englishName:"Basque",flag:"ð´ó ¥ó ³ó °ó ¶ó ¿"},{code:"ca",name:"Català ",englishName:"Catalan",flag:"ð´ó ¥ó ³ó £ó ´ó ¿"}],Lt={chatPlaceholder:"Ask me anything...",sendMessage:"Send message",askAnything:"Ask me anything about our services!",tryAsking:"Try asking:",poweredBy:"Powered by",verifiedBy:"Verified",verifiedByDescription:"Joggle has confirmed this business's identity and ownership. This means you're chatting with the genuine assistant for this business â not an impersonator. You can share enquiries and information with confidence.",businessIntroPrefix:"Hi â I'm",businessIntroSuffix:".",helloGreeting:"Hello",viewInfo:"View Info",viewMenu:"View Menu",makeBooking:"Make a Booking",seeEvents:"See Events",viewRooms:"View Rooms",viewGallery:"View Gallery",signUpAction:"Sign Up",lostPropertyAction:"Lost Property",viewReviews:"View Reviews",contactUsAction:"Contact us",welcomeMessage:"",joggleSuggests:"Joggle suggests:",popularQuestions:"Popular questions:",showMore:"More",menuTitle:"Menu",eventsTitle:"Events",hoursTitle:"Opening Hours",infoTitle:"Information",contactTitle:"Contact",bookingTitle:"Booking",mailingListTitle:"Newsletter",joinNewsletter:"Join our Newsletter",lostPropertyTitle:"Lost Property",reviewsTitle:"Reviews",historyTitle:"History",bookTableTitle:"Book",galleryTitle:"Gallery",roomsTitle:"Rooms",drinksTitle:"Drinks",homeTitle:"Home",aboutTitle:"About",darkMode:"Dark Mode",lightMode:"Light Mode",chatLabel:"Chat",siteLabel:"Site",bookButton:"Book",menuButton:"Menu",infoButton:"Info",mailingListButton:"Newsletter",lostPropertyButton:"Lost Property",upcomingEventsTitle:"Upcoming Events",ourMe
10nuTitle:"Our Menu",moreInfoButton:"More Info",bookNowButton:"Book Now",loadingEvents:"Loading events...",filterByCategory:"Filter by Category",allEvents:"All Events",eventInformation:"Event Information",freeEntry:"Free entry",oneTime:"One-Time",containsLabel:"Allergens",noMenuItemsFound:"No menu items found",orderAtBarMessage:"Please order at the bar.",originalLanguageVersion:"Original language",partiallyTranslated:"Partially translated",translated:"Translated",startersCategory:"Starters",mainsCategory:"Main Courses",sidesCategory:"Sides",dessertsCategory:"Desserts",childrensCategory:"Children's Menu",beersCategory:"Beers & Ales",winesCategory:"Wines",spiritsCategory:"Spirits",softDrinksCategory:"Soft Drinks",hotDrinksCategory:"Hot Drinks",eventSingular:"Event",eventPlural:"Events",noEventsScheduled:"No Events Scheduled",pastEvent:"Past Event",eventDetails:"Event Details",aboutThisEvent:"About This Event",eventPhotos:"Event Photos",bookThis:"Book This",checkBackSoon:"Check back soon for upcoming events and special occasions!",eventInfoDescription:"Booking requirements and event details may change. For the most up-to-date information, please call us directly or check our social media pages.",illustrationDisclaimer:"Image for illustration purposes only.",bookingRequired:"Booking Required",spotsLeft:"spots left",showMenuSuggestion:"Show me the menu",showMenuAlt:"Show me your menu",veganOptionsSuggestion:"I'm vegan - what can I eat?",wineListSuggestion:"Show me wine list",openingHoursSuggestion:"What are your opening hours?",bookingsSuggestion:"How do I make a booking?",whatFoodSuggestion:"What food do you serve?",todaysSpecialsSuggestion:"Show me today's specials",alesOnTapSuggestion:"What ales are on tap?",nextQuizSuggestion:"When is the next quiz night?",communityEventsSuggestion:"Tell me about your community events",tonightSpecialSuggestion:"What's special about tonight?",loading:"Loading...",error:"Error",retry:"Retry",close:"Close",back:"Back",next:"Next",done:"Done",cancel:"Cancel",save:"Save",today:"Today",tomorrow:"Tomorrow",yesterday:"Yesterday",openNow:"Open Now",closedNow:"Closed Now",openClosesInHoursMins:"Open, closes in {hours} {hoursUnit}, {mins} {minsUnit}",openClosesInHours:"Open, closes in {hours} {hoursUnit}",openClosesInMins:"Open, closes in {mins} {minsUnit}",closedOpensInHoursMins:"Closed, opens in {hours} {hoursUnit}, {mins} {minsUnit}",closedOpensInHours:"Closed, opens in {hours} {hoursUnit}",closedOpensInMins:"Closed, opens in {mins} {minsUnit}",closedOpensTomorrow:"Closed, opens tomorrow",hour:"hour",hours:"hours",min:"min",mins:"mins",networkError:"Network connection error. Please try again.",notFound:"Content not found.",serverError:"Server error. Please try again later.",selectLanguage:"Select Language",currentLanguage:"Current language",searchLanguages:"Search languages...",scrollToSeeAll:"Scroll to see all",suggestions:"suggestions",useArrowsOrScroll:"Click arrows to see more suggestions",jumpToLatest:"Jump to latest",siteCall:"Call",siteGetDirections:"Get Directions",siteBookNow:"Book Now",siteHoursToday:"Hours Today",siteAddress:"Address",sitePhone:"Phone",siteFeaturedItems:"Featured Items",siteViewAll:"View All",siteOpen:"Open",siteClosed:"Closed",siteAskQuestion:"Ask a question...",siteServices:"Services",siteGallery:"Gallery",siteReviews:"Reviews",siteLocation:"Location",siteFAQs:"FAQs",siteContact:"Contact",siteHome:"Home",siteAbout:"About",siteMenu:"Menu",siteContactUs:"Contact Us",siteGetInTouch:"Get in Touch",siteFindUs:"Find Us",siteFrequentlyAsked:"Frequently Asked Questions",siteOurGallery:"Our Gallery",siteWhatPeopleSay:"What People Say",siteContactDetails:"Contact Details",siteOpeningHours:"Opening Hours",siteEvents:"Events",siteBookTable:"Book a Table",siteNewsletter:"Newsletter",siteLostProperty:"Lost Property",siteName:"Name",siteEmail:"Email",siteVisit:"Visit",siteHours:"Hours",siteOpenNow:"Open Now",siteClosedNow:"Closed",siteToday:"Today",siteClosesAt:"Closes at",siteOpensIn:"Opens in",siteCurrentTime:"Current time",siteViewFullHours:"View full hours",siteHideFullHours:"Hide full hours",siteOpenInMaps:"Open in Maps",siteFeatured:"Featured",siteViewFullMenu:"View full menu",siteVegan:"Vegan",siteVeggie:"Veggie",siteAllergens:"allergens",siteAllergen:"allergen",siteBookingRequestSent:"Booking Request Sent!",siteBookingThankYou:"Thank y
10ou for your booking request.",siteBookNowExternal:"Book Now",sitePartySize:"Party Size",sitePerson:"person",sitePeople:"people",siteLargerParty:"Larger party (11+)",siteDate:"Date",sitePreferredTime:"Preferred Time",siteSpecialRequests:"Special Requests",siteSpecialRequestsPlaceholder:"Any dietary requirements or special requests?",siteSubmitting:"Submitting...",siteRequestBooking:"Request Booking",siteNoUpcomingEvents:"No upcoming events. Check back soon!",siteBasedOnReviews:"Based on {count} reviews",siteViewOnGoogle:"View on Google",siteViewAllPhotos:"View all {count} photos",siteAll:"All",siteStayUpdated:"Stay Updated",siteYoureSubscribed:"You're subscribed!",siteYourEmail:"Your email",siteLostPropertyDesc:"Left something behind? Let us know and we'll help you find it.",sitePrivateHire:"Private Hire & Enquiries",sitePrivateHireDesc:"Planning an event? Get in touch about private bookings.",siteVerified:"Verified",siteNeedHelp:"Need help with this page?",siteContactSupport:"Contact Joggle Support",sitePrivacy:"Privacy",siteTerms:"Terms",siteCookies:"Cookies",sitePoweredBy:"Powered by Joggle",quickFind:"Quick Find",vegetarianFilter:"Vegetarian",veganFilter:"Vegan",glutenFreeFilter:"Gluten Free",mainMenu:"Main Menu",sundayMenu:"Sunday Menu",teamTitle:"Team",joggleSettings:"Joggle Settings",drinksMenuTitle:"Drinks Menu",orderAtBar:"Order at the bar",everythingElse:"Everything else",groupEatDrink:"Eat & drink",groupLookAround:"Look around",groupGetInTouch:"Get in touch",groupMore:"More",settingsTitle:"Settings",yourDetails:"Your details",nameLabel:"Name",yourNamePlaceholder:"Your name",preferredLanguage:"Preferred language",cookiesPrivacyTitle:"Cookies & privacy",cookieNecessary:"Necessary",cookieNecessaryDesc:"Always on â keeps the site working.",cookieAnalytics:"Analytics",cookieAnalyticsDesc:"Helps us understand what's useful.",cookieMarketing:"Marketing",cookieMarketingDesc:"Lets us measure campaigns.",cookiePersonalisation:"Personalisation",cookiePersonalisationDesc:"Remembers your name & language.",alwaysOn:"Always on",saveMyChoices:"Save my choices",clearChatDevice:"Clear this chat on this device",cookiePolicy:"Cookie Policy",privacyPolicy:"Privacy Policy",preferencesSaved:"Preferences saved",chatCleared:"Chat cleared",languageLabel:"Language",linksLabel:"Links",privateSecurePoweredBy:"Private & secure · Powered by Joggle",whatsOnLabel:"What's on",onlineNow:"Online now",barHoursLabel:"Bar",foodHoursLabel:"Food",updatesLabel:"Updates",clubsLabel:"Clubs",findUsLabel:"Find us",closedLabel:"Closed",closedOpensIn:"Closed · opens in {time}",lunchMenu:"Lunch Menu",glutenFreeMenu:"Gluten-Free Menu",christmasMenu:"Christmas Menu",brunchMenu:"Brunch Menu",sundayCategory:"Sunday",buffetCategory:"Buffet",otherCategory:"Other",loadingMenu:"Loading menuâ¦",loadingDrinks:"Loading drinksâ¦",loadingRooms:"Loading roomsâ¦",loadingReviews:"Loading reviewsâ¦",loadingPhotos:"Loading photosâ¦",noDrinksListed:"No drinks listed yet.",noRoomsListed:"No rooms listed yet.",noReviewsYet:"No reviews yet.",noPhotosYet:"No photos yet.",noEventsDiary:"Nothing in the diary just yet â ask Joggle to let you know.",noEventsFollow:"Nothing in the diary just yet â follow us and we'll let you know
10when something's coming up.",menuFilterEmpty:'Nothing matches those filters â try fewer, or ask Joggle "what can I eat?"',allergensLabel:"Allergens:",allLabel:"All",showMoreReviews:"Show more",reviewsCount:"{count} reviews",viaSource:"via {source}",soldOut:"Sold out",ticketsTag:"Tickets",ticketsLeft:"Only {count} left",getTickets:"Get tickets",ticketsNotOnSale:"Tickets aren't on sale yet â ask us for details.",addToCalendar:"Add to calendar",bookATable:"Book a table",bookThisRoom:"Book this room",followBusiness:"Follow {business}",newsletterIntro:"Get occasional updates about what's on, new dishes, offers and news from {business}. No account needed â unsubscribe any time.",whatHearAbout:"What would you like to hear about?",prefEventsLabel:"What's on & events",prefOffersLabel:"Offers & specials",prefNewsLabel:"News & updates",prefWeeklyLabel:"Weekly round-up",onTheList:"You're on the list ð",checkInboxConfirm:"Check your inbox to confirm your email â then you're all set.",signingYouUp:"Signing you upâ¦",keepMePosted:"Keep me posted",enterYourName:"Please enter your name.",enterValidEmail:"Please enter a valid email.",somethingWentWrong:"Something went wrong â please try again.",emailLabel:"Email",emailPlaceholder:"[email protected]",whatDidYouLose:"What did you lose?",lostItemPlaceholder:"Size, colour, brand, distinctive featuresâ¦",roughlyWhen:"Roughly when? (optional)",roughlyWhenPlaceholder:"e.g. last Friday evening",describeItemMore:"Please describe the item in a bit more detail.",sendingEllipsis:"Sendingâ¦",sendIt:"Send it",lostPropertyDone:"We'll have a look and get back to you.",messageLabel:"Message",messagePlaceholder:"How can we help?",sendMessageBtn:"Send message",aboutUsLabel:"About us",hoursLabel:"Hours",checkFormTitle:"Please check the form",checkFormDesc:"Name, a valid email, and a short message are needed.",messageSentTitle:"Message sent",messageSentDesc:"We'll get back to you soon.",couldntSendTitle:"Couldn't send",tryAgainDesc:"Please try again.",dietGlutenFree:"Gluten Free",dietGlutenFreeAvailable:"Gluten Free Available",dietVegetarian:"Vegetarian",dietVegetarianAvailable:"Vegetarian Available",dietVegan:"Vegan",dietVeganAvailable:"Vegan Available",dietDairyFree:"Dairy Free",dietDairyFreeAvailable:"Dairy Free Available",allergenCelery:"Celery",allergenGluten:"Gluten",allergenCrustaceans:"Crustaceans",allergenEggs:"Egg",allergenFish:"Fish",allergenLupin:"Lupin",allergenMilk:"Milk",allergenMolluscs:"Molluscs",allergenMustard:"Mustard",allergenNuts:"Nuts",allergenPeanuts:"Peanuts",allergenSesame:"Sesame",allergenSoya:"Soya",allergenSulphites:"Sulphites",bookingHowMany:"How many of you?",bookingWhichDay:"Which day?",bookingWhatTime:"What time?",bookingNearlyThere:"Nearly there.",bookingStepPeople:"People",bookingStepDate:"Date",bookingStepTime:"Time",bookingStepDetails:"Details",next30Days:"Next 30 days",noDatesThisMonth:"No dates available in this month.",checkingAvailability:"Checking availabilityâ¦",noAvailabilityDate:"No availability on this date.",tryAnotherDate:"Try another date",guestSingular:"guest",guestPlural:"guests",mobileLabel:"Mobile",anythingWeShouldKnow:"Anything we should know? (optional)",bookingNotesPlaceholder:"Allergies, high chair, occasionâ¦",bookingEllipsis:"Bookingâ¦",bookAndSecure:"Book & secure",bookMyTable:"Book my table",bookedTitle:"Booked.",bookedConfirmation:"We've sent a confirmation by email. Change of plan? Just ask Joggle to move or cancel it.",lovelyDone:"Lovely, done",discardBooking:"Discard this booking?",keepGoing:"Keep going",discardIt:"Discard it",enterValidPhone:"Please enter a valid phone number.",bookingFailed:"Sorry â we couldn't complete that booking. Please try another time.",depositPerPerson:"A £{amount} per-person deposit secures your table.",depositFlat:"A £{amount} deposit secures your table.",depositRequired:"A deposit is required to secure your table.",partyTooBig:"Please enter a whole number up to {max}. For larger parties, just ask us in the chat.",welcomeToBusiness:"Welcome to {business}",chooseCookies:"Choose which types of cookies you allow.",welcomeTellUs:"Tell us your name and email so Joggle can make things easier for you next time.",firstNamePlaceholder:"First name",optionalLabel:"(optional)",receiveUpdatesFrom:"I'd like to receive updates from {business}",noSpamNote:"We won't share your details and we won't spam you.",settingUpEllipsis:"Setting up...",continueLabel:"Continue",manageLabel:"Manage",privacyLabel:"Privacy",cookiesLabel:"Cookies",skipLabel:"Skip",intentAskAbout:"Ask about",intentBookings:"bookings",intentMenu:"menu",intentDrinks:"drinks",intentEvents:"events",intentOpeningHours:"opening hours",intentParking:"parking",intentWifi:"Wi-Fi",intentRooms:"rooms",intentFunctionRoom:"function room",intentFaqs:"FAQs",intentAskAnything:"Ask me anything about this businessâ¦"};function oc(t){if(!t||t==="en-GB")return"IMPORTANT: Use UK English spelling and phrasing throughout all responses. Examples: colour, favourite, organise, centre, licence (noun), programme, travelling, behaviour, catalogue, recognise, prioritise, analyse.";if(t==="en-US")return"IMPORTANT: Use US English spelling and phrasing throughout all responses. Examples: color, favorite, organize, center, license, program, traveling, behavior, catalog, recognize, prioritize, analyze.";const n=le.find(s=>
10s.code===t);return n?`IMPORTANT: Respond in ${n.name} (${n.englishName}). The user has selected this language as their preference. All responses, suggestions, and UI interactions should be in ${n.name}.`:""}function at(t){return["ar","he","fa","ur"].includes(t)?"rtl":"ltr"}function es(t){if(!t||t.length<2||t.length>5)return!1;const n=t.toLowerCase();return le.some(s=>{const i=s.code.split("-")[0].toLowerCase();return s.code.toLowerCase()===n||i===n})}function Jt(t){if(!t)return null;const n=t.toLowerCase();return le.find(i=>{const c=i.code.split("-")[0].toLowerCase();return i.code.toLowerCase()===n||c===n})?.code||null}function Dn(t){if(typeof window>"u")return"en-GB";const n=window.location.pathname.split("/").filter(Boolean);if(n.length>=2){const i=n[1];if(i&&es(i)){const c=Jt(i);if(c)return console.log("ð URL language detected:",i,"->",c),localStorage.setItem("joggle-language",c),c}}if(t?.assistantId!=null){const i=localStorage.getItem(`joggle-language-assistant-${t.assistantId}`);if(i&&le.find(c=>c.code===i))return i}const s=localStorage.getItem("joggle-language");if(s&&le.find(i=>i.code===s))return s;if(typeof navigator<"u"&&navigator.language){const i=Jt(navigator.language);if(i)return i}return t?.businessDefaultLanguage&&le.find(i=>i.code===t.businessDefaultLanguage)?t.businessDefaultLanguage:"en-GB"}function ts(t){typeof window<"u"&&localStorage.setItem("joggle-language",t)}let Ge={},Cn={},Qe={},ze=null;function _t(){return ze||(ze=r(()=>import("./i18n.dictionaries-D3kvyVWE.js"),[]).then(t=>{Ge=t.LANGUAGE_TRANSLATIONS,Cn=t.PRELOADED_FORM_TRANSLATIONS,Qe=t.LOADING_MESSAGES}).catch(()=>{ze=null})),ze}function Nn(t){return!t||t.toLowerCase().split("-")[0]==="en"}function ns(t,n="en-GB"){const s=Ge[n];if(s&&s[t]!==void 0)return s[t];const i=n.split("-")[0],c=Ge[i];return c&&c[t]!==void 0?c[t]:Lt[t]}function Vn(t,n){const s=Ge[n];if(s&&s[t]!==void 0)return s[t];const i=Ge[n.split("-")[0]];if(i&&i[t]!==void 0)return i[t]}const se={},Mn="joggle_ui_i18n_",os=600,ss=400;function Bn(t){if(!se[t]){se[t]={};try{if(typeof localStorage<"u"){const n=localStorage.getItem(Mn+t);n&&(se[t]=JSON.parse(n)||{})}}catch{}}return se[t]}const Wt={};function rs(t){typeof localStorage>"u"||(clearTimeout(Wt[t]),Wt[t]=setTimeout(()=>{try{const n=se[t]||{},i=Object.entries(n).filter(([c])=>c.length<=ss).slice(-os);localStorage.setItem(Mn+t,JSON.stringify(Object.fromEntries(i)))}catch{}},500))}const it=new Map;let Fe=[],Kt;async function as(t,n){try{const s=Array.from(new Set(t.map(p=>p.text))),i=await fetch("/api/translate-batch",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({items:s.map((p,m)=>({key:`ui_${m}`,content:p})),targetLanguage:n})});if(!i.ok)throw new Error(`UI translation failed: ${i.status}`);const c=await i.json(),u=new Map;s.forEach((p,m)=>{const h=c.translations[`ui_${m}`];h&&u.set(p,h)});const d=Bn(n);for(const[p,m]of u)d[p]=m;u.size&&rs(n),t.forEach(p=>{p.resolve(u.get(p.text)??p.text)}),window.dispatchEvent(new CustomEvent("translationBatchComplete",{detail:{targetLanguage:n,itemCount:t.length}}))}catch{t.forEach(i=>i.resolve(i.text)),window.dispatchEvent(new CustomEvent("translationBatchComplete",{detail:{targetLanguage:n,itemCount:t.length,error:!0}}))}}async function Et(t,n){if(n==="en-GB"||n==="en"||n==="en-US")return t;const s=Bn(n)[t];if(s)return s;const i=`${n}::${t}`,c=it.get(i);if(c)return c;const u=new Promise((d,p)=>{const m={text:t,targetLanguage:n,resolve:d,reject:p};Fe.push(m),clearTimeout(Kt),Kt=setTimeout(()=>{if(Fe.length>0){window.dispatchEvent(new CustomEvent("translationBatchStarted",{detail:{itemCount:Fe.length,targetLanguage:n}}));const h=new Map;Fe.forEach(g=>{h.has(g.targetLanguage)||h.set(g.targetLanguage,[]),h.get(g.targetLanguage).push(g)}),Fe=[],h.forEach((g,E)=>{as(g,E).finally(()=>{window.dispatchEvent(new CustomEvent("translationBatchComplete",{detail:{itemCount:g.length,targetLanguage:E}}))})})}},100)});return it.set(i,u),u.finally(()=>it.delete(i)).catch(()=>{}),u}async function is(t,n){const s={};return!n||n==="en"||n.startsWith("en-")||await Promise.all(t.map(async i=>{const c=Vn(i,n);if(c!==void 0){s[i]=c;return}try{s[i]=await Et(Lt[i],n)}catch{}})),s}async function sc(t,n){if(n==="en-GB"||n==="en")return t;const s=Cn[n];if(s){const c={};let u=!0;for(const[d,p]of Object.entries(t))s[p]?c[d]=s[p]:(c[d]=p,u=!1);if(u||Object.keys(c).length>=Object.keys(t).length*.8)return c}const i=`form_${Object.keys(t).join("_")}`;if(se[n]?.[i])return JSON.parse(se[n][i]);try{const c=Object.entries(t).map(([m,h])=>({key:m,content:h})),u=await fetch("/api/translate-batch",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({items:c,targetLanguage:n})});if(!u.ok)return console.warn("Form translation failed, using original labels"),t;const d=await u.json(),p={};return Object.entries(t).forEach(([m,h])=>{p[m]=d.translations[m]||h}),se[n]||(se[n]={}),se[n][i]=JSON.stringify(p),p}catch(c){return console.warn("Form translation error:",c),t}}const cs=["updatesLabel","whatsOnLabel","groupMore","everythingElse","onlineNow","openNow","closedLabel","today","bookButton","menuButton","drinksTitle","roomsTitle","galleryTitle","reviewsTitle","clubsLabel","aboutUsLabel","contactTitle","findUsLabel","linksLabel","bookATable","ourMe
10nuTitle","quickFind","loadingMenu","allergensLabel","barHoursLabel","foodHoursLabel"];function rc(){const[t,n]=l.useState(()=>Dn()),[s,i]=l.useState({}),[c,u]=l.useState(!1),[d,p]=l.useState(null),[m,h]=l.useState(null),g=l.useRef(null),E=l.useRef(!0),b=l.useRef(!0),x=l.useCallback(v=>{g.current&&clearTimeout(g.current),p(v),u(!0);let T=Qe[v];if(!T){const S=le.find(V=>V.code===v);T=`Joggle is getting ready to speak ${S?.name||S?.englishName||"this language"}...`}h(T),g.current=setTimeout(()=>{E.current&&(u(!1),p(null),h(null))},1500)},[]);l.useEffect(()=>{E.current=!0;const v=setTimeout(()=>{b.current=!1},500);return()=>{E.current=!1,clearTimeout(v),g.current&&clearTimeout(g.current)}},[]);const k=v=>{const T=Lt[v];if(t==="en-GB"||t==="en")return T;if(t==="en-US")return ns(v,"en-US");const S=Vn(v,t);return S!==void 0?S:s[v]?s[v]:(Et(T,t).then(J=>{i(V=>V[v]===J?V:{...V,[v]:J})}).catch(()=>{}),T)},N=l.useCallback(v=>{Nn(v)||_t(),v!=="en-GB"&&v!=="en"&&v!=="en-US"&&!b.current&&x(v),n(v),i({}),ts(v),document.documentElement.dir=at(v),window.dispatchEvent(new CustomEvent("languageChange",{detail:{languageCode:v}}))},[x]);l.useEffect(()=>{const v=T=>{const{languageCode:S}=T.detail;S!=="en-GB"&&S!=="en"&&S!=="en-US"&&x(S),n(S),i({}),document.documentElement.dir=at(S)};return window.addEventListener("languageChange",v),()=>{window.removeEventListener("languageChange",v)}},[x]),l.useEffect(()=>{const v=t;if(!v||v==="en"||v.startsWith("en-"))return;let T=!0;return is(cs,v).then(S=>{!T||!S||Object.keys(S).length===0||i(J=>({...J,...S}))}).catch(()=>{}),()=>{T=!1}},[t]);const A=async v=>{if(!v||t==="en-GB"||t==="en"||t==="en-US")return v;try{return await Et(v,t)}catch(T){return console.warn("Content translation error:",T),v}};return{t:k,currentLanguage:t,changeLanguage:N,direction:at(t),isTranslating:c,translatingLanguage:d,translatedLoadingMessage:m,translateContent:A,getLoadingMessage:us}}const ls="Joggle is just learning English â won't be long.";function us(t){return Qe[t]||Qe["en-GB"]||ls}function ds(){return typeof window>"u"?!1:window.isSecureContext||!1}const ms=4,ps=380*ms;function zt(t,n=ps){const s=t.trim();if(!s)return[];if(s.length<=n)return[s];const i=[];let c=s;for(;c.length>n;){const u=c.slice(0,n);let d=Math.max(u.lastIndexOf(". "),u.lastIndexOf("! "),u.lastIndexOf("? "),u.lastIndexOf(` 11`));d<n*.5&&(d=u.lastIndexOf(" ")),d<=0&&(d=n),i.push(c.slice(0,d+1).trim()),c=c.slice(d+1)}return c.trim()&&i.push(c.trim()),i}function Yt(t){return t.replace(/!\[([^\]]*)\]\([^)]*\)/g,"$1").replace(/\[([^\]]+)\]\([^)]*\)/g,"$1").replace(/```[\s\S]*?```/g," ").replace(/`([^`]+)`/g,"$1").replace(/(\*\*|__)(.*?)\1/g,"$2").replace(/(\*|_)(.*?)\1/g,"$2").replace(/^#{1,6}\s+/gm,"").replace(/^\s*[-*+]\s+/gm,"").replace(/^\s*>\s?/gm,"").replace(/\|/g," ").replace(/[ \t]{2,}/g," ").replace(/\n{3,}/g,` 12 13`).trim()}class Qt{constructor(n,s=1500){this.speaker=n,this.gapMs=s,this.rows=[],this.seq=0,this.rawText=""}append(n,s,i){this.rawText+=n;const c=this.rows[this.rows.length-1];if(c&&s-c.endMs<=this.gapMs)return c.text+=n,c.endMs=Math.max(c.endMs,i),{id:c.id,text:c.text,isNew:!1};const u={id:`${this.speaker}-${++this.seq}-${Date.now()}`,text:n,endMs:i};return this.rows.push(u),{id:u.id,text:u.text,isNew:!0}}textSince(n){if(!n)return this.rows.map(i=>i.text).join(" ").trim();const s=this.rows.findIndex(i=>i.id===n);return s<0?this.rows.map(i=>i.text).join(" ").trim():this.rows.slice(s+1).map(i=>i.text).join(" ").trim()}get lastRowId(){return this.rows.length?this.rows[this.rows.length-1].id:null}get cursor(){return this.rawText.length}textAfter(n){return this.rawText.slice(n).trim()}get fullText(){return this.rows.map(n=>n.text).join(" ").trim()}reset(){this.rows=[],this.rawText=""}}const hs=/^(?:yes|no|okay|ok|sure|right|great|absolutely|of course|thanks|thank you)[.!]?$/i;class Fn{constructor(){this.buffer=""}push(n){this.buffer+=n;const s=[];for(;;){let i=-1;for(let c=0;;){const u=this.findSentenceEnd(this.buffer,c);if(u<0)break;if(!hs.test(this.buffer.slice(0,u+1).trim())){i=u;break}c=u+1}if(i<0)break;s.push(this.buffer.slice(0,i+1).trim()),this.buffer=this.buffer.slice(i+1)}return s}flush(){const n=this.buffer.trim();return this.buffer="",n}findSentenceEnd(n,s=0){for(let i=s;i<n.length-1;i++){const c=n[i];if(c!=="."&&c!=="!"&&c!=="?"&&c!==` 14`)continue;if(c===` 15`)return i;const u=n[i+1];if(!(u!==" "&&u!==` 16`))return i}return-1}}async function ac(t,n,s={}){const{fetchWithCSRF:i}=await r(async()=>{const{fetchWithCSRF:g}=await Promise.resolve().then(()=>Do);return{fetchWithCSRF:g}},void 0),c=await i(`/api/chat/${t}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({message:n,sessionId:s.sessionId||void 0,languagePrompt:s.languagePrompt||"",voiceMode:!0}),signal:s.signal});if(!c.ok)throw new Error(`Chat pipeline returned ${c.status}`);if(!c.body)throw new Error("Chat pipeline returned no stream");const u=c.body.getReader(),d=new TextDecoder;let p="",m="";const h=s.onSentence?new Fn:null;for(;;){const{done:g,value:E}=await u.read();if(g)break;p+=d.decode(E,{stream:!0});const b=p.split(` 17`);p=b.pop()??"";for(const x of b){if(!x.startsWith("data:"))continue;
17const k=x.slice(5).trim();if(k)try{const N=JSON.parse(k);if(N.type==="chunk"&&typeof N.content=="string"&&(m+=N.content,h))for(const A of h.push(N.content))s.onSentence(A)}catch{}}}if(h){const g=h.flush();g&&s.onSentence(g)}return m.trim()}const gs=2500,fs=400,_s=8e3;function Es({assistantId:t,isActive:n,onClose:s,sessionEndpoint:i,onDelegate:c,onTranscriptRow:u,onConnected:d,micMuted:p=!1,currentLanguage:m="en-GB",jingleEndedPromise:h,initialHistory:g,contextUpdate:E,cancelSupersededDelegations:b=!1,onBusyChange:x,onAudioActivity:k,onMicMutedChange:N,onMicError:A}){const[v,T]=l.useState(!1),{toast:S}=Yn(),J=l.useRef(null),V=l.useRef(null),_e=l.useRef(null),W=l.useRef(null),Z=l.useRef(null),Ae=l.useRef(i.split("/").filter(Boolean).slice(-2,-1)[0]||"unknown"),ee=l.useRef(null),Ee=l.useRef(!1),K=l.useRef(null),Re=l.useRef(new Qt("user")),Ie=l.useRef(new Qt("assistant")),Pe=l.useRef(0),re=l.useRef(new Map),ue=l.useRef(!1),X=l.useRef(null),B=l.useRef(null),ve=l.useRef(null),Oe=l.useRef(null),R=l.useRef({micMuted:p,initialHistory:g,contextUpdate:E,onBusyChange:x,onAudioActivity:k,onMicMutedChange:N,onMicError:A,cancelSupersededDelegations:b});R.current={micMuted:p,initialHistory:g,contextUpdate:E,onBusyChange:x,onAudioActivity:k,onMicMutedChange:N,onMicError:A,cancelSupersededDelegations:b};const De=l.useRef(new Set),ae=l.useRef([]),Ce=l.useRef(new Map),ye=l.useRef(c),qe=l.useRef(u),z=l.useRef(s);l.useEffect(()=>{ye.current=c},[c]),l.useEffect(()=>{qe.current=u},[u]),l.useEffect(()=>{z.current=s},[s]),l.useEffect(()=>{je.current=d},[d]);const je=l.useRef(void 0),de=_=>{const w=V.current;return!w||w.readyState!=="open"?(console.warn("[live] dropped event, channel not open:",_.type),!1):(w.send(JSON.stringify(_)),!0)},we=(_,w)=>{const U=Yt(w);for(const[O,H]of zt(U).entries())de({type:"session.commentary.append",event_id:`commentary_${Date.now()}_${O}`,delegation_id:_,content:H})},ie=(_,w)=>{for(const[U,O]of zt(Yt(w)).entries())de({type:"session.thinking.append",event_id:`thinking_${Date.now()}_${U}`,delegation_id:_,content:O})},be=()=>{for(const _ of re.current.values())_.abort();re.current.clear(),R.current.onBusyChange?.(!1)},te=()=>{const _=R.current.contextUpdate;!_||_.id===Oe.current||V.current?.readyState!=="open"||(_.cancelPending&&be(),ie(null,_.text),Oe.current=_.id)},me=()=>{if(V.current?.readyState!=="open"||ue.current)return;B.current&&clearTimeout(B.current);const _=R.current.micMuted,w=`mic_${_?"mute":"unmute"}_${Date.now()}`;ve.current=w,de({type:_?"session.input_audio.mute":"session.input_audio.unmute",event_id:w}),B.current=setTimeout(()=>R.current.onMicError?.(),5e3)},Je=(_,w,U,O)=>{qe.current?.(_,w,U,O);const H=Ce.current.get(_)??ae.current.length;Ce.current.set(_,H),ae.current[H]=`${U?"Customer":"Assistant"}: ${w}`},Ne=async _=>{if(De.current.has(_))return;De.current.add(_);const w=Re.current,U=w.textAfter(Pe.current);if(Pe.current=w.cursor,!U.trim()){ie(_,"No request was captured. Ask the person to repeat it.");return}R.current.cancelSupersededDelegations&&be();const O=new AbortController;re.current.set(_,O),R.current.onBusyChange?.(!0);const H=()=>!O.signal.aborted&&!ue.current;let P=setTimeout(()=>{H()&&ie(_,"Still working on that request. Nothing has been changed or confirmed yet.")},gs);O.signal.addEventListener("abort",()=>{P&&(clearTimeout(P),P=null)},{once:!0});const q=ye.current;if(!q){P&&(clearTimeout(P),P=null),ie(_,"There is nothing to look up here. Continue from the conversation itself."),re.current.delete(_),R.current.onBusyChange?.(re.current.size>0);return}try{const C=await q({id:_,userText:U,fullUserText:w.fullText,signal:O.signal,speakNow:Ve=>{P&&(clearTimeout(P),P=null),H()&&we(_,Ve)}});P&&(clearTimeout(P),P=null),H()&&C.remember&&ie(_,C.remember),H()&&C.speak&&we(_,C.speak)}catch(C){if(P&&(clearTimeout(P),P=null),!H())return;console.error("[live] delegation failed:",C),we(_,"Sorry â I could not get that just now. Nothing has been changed. Please try again in a moment.")}finally{re.current.delete(_),R.current.onBusyChange?.(re.current.size>0)}},et=_=>{switch(_.type){case"session.started":{Z.current=_.session?.id||Z.current,console.log(`[live] session started: ${Z.current}`);break}case"session.input_transcript.delta":{const w=Re.current.append(_.delta||"",_.start_ms??0,_.end_ms??
170);Je(w.id,w.text,!0,w.isNew);break}case"session.output_transcript.delta":{const w=Ie.current.append(_.delta||"",_.start_ms??0,_.end_ms??0);Je(w.id,w.text,!1,w.isNew);break}case"session.delegation.created":{const w=_.delegation;if(w?.target&&w.target!=="client")break;w?.id&&Ne(w.id);break}case"session.closed":{Ee.current=!0,console.log("[live] session closed:",_.reason,"usage:",_.usage);const w=Number(_.usage?.seconds);Number.isFinite(w)&&w>0&&fetch("/api/live/usage",{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({seconds:w,surface:Ae.current,assistantId:t??null}),keepalive:!0}).catch(()=>{}),ne(),z.current?.();break}case"error":{console.error("[live] server error:",JSON.stringify(_).slice(0,500)),(_.error?.event_id===ve.current||_.client_event_id===ve.current)&&(B.current&&clearTimeout(B.current),R.current.onMicError?.());break}case"session.input_audio.muted":case"session.input_audio.unmuted":{if(_.client_event_id!==ve.current)break;B.current&&clearTimeout(B.current),B.current=null,R.current.onMicMutedChange?.(_.type==="session.input_audio.muted");break}case"session.commentary.appended":case"session.thinking.appended":case"session.instructions.appended":case"session.usage.updated":case"info":break;default:(String(_.type||"").startsWith("session.")||String(_.type||"").startsWith("response."))&&console.log("[live] event:",_.type)}},ne=()=>{if(be(),X.current?.(),X.current=null,B.current&&clearTimeout(B.current),K.current&&(clearTimeout(K.current),K.current=null),Z.current&&ee.current){const _=Math.floor((Date.now()-ee.current)/1e3),w=Z.current,U=ae.current.join(` 18`)||null;ee.current=null,fetch(`/api/voice/realtime/end-session/${encodeURIComponent(w)}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({duration:_,transcript:U}),keepalive:!0}).catch(()=>{})}V.current?.close(),V.current=null,J.current?.close(),J.current=null,_e.current?.getTracks().forEach(_=>_.stop()),_e.current=null,W.current&&(W.current.pause(),W.current.srcObject=null,W.current=null),Re.current.reset(),Ie.current.reset(),Pe.current=0,De.current=new Set,ae.current=[],Ce.current.clear(),Z.current=null,T(!1)},ce=()=>{if(ue.current=!0,be(),X.current?.(),X.current=null,B.current&&(clearTimeout(B.current),B.current=null),_e.current?.getTracks().forEach(_=>_.stop()),W.current?.pause(),Ee.current||!V.current||V.current.readyState!=="open"){ne();return}de({type:"session.close",event_id:`close_${Date.now()}`}),K.current=setTimeout(()=>{console.warn("[live] no session.closed within timeout â tearing down anyway"),ne()},_s)};return l.useEffect(()=>{me()},[p]),l.useEffect(()=>{te()},[E]),l.useEffect(()=>{if(!n){(J.current||V.current)&&ce();return}let _=!1;const w=new AbortController;return Ee.current=!1,ue.current=!1,(async()=>{try{if(!ds()){S({title:"Voice needs a secure connection",description:"Open this page over HTTPS to use voice.",variant:"destructive"}),z.current?.();return}if(!navigator.mediaDevices?.getUserMedia){S({title:"Microphone unavailable",description:"Allow microphone access to use voice.",variant:"destructive"}),z.current?.();return}const O=await navigator.mediaDevices.getUserMedia({audio:{echoCancellation:!0,noiseSuppression:!0,autoGainControl:!0}});if(_){O.getTracks().forEach(y=>y.stop());return}_e.current=O;let H=y=>{};if(R.current.onAudioActivity)try{const y=new AudioContext;y.resume().catch(()=>{});const j=y.createAnalyser(),I=y.createAnalyser();j.fftSize=I.fftSize=256;const M=y.createMediaStreamSource(O);M.connect(j);let L=null;H=he=>{L=y.createMediaStreamSource(he),L.connect(I)};const Y=new Float32Array(256);let D={input:0,output:0},F=0,G=0;const pe=he=>{he.getFloatTimeDomainData(Y);const ge=Math.sqrt(Y.reduce((xe,At)=>xe+At*At,0)/Y.length);return ge<.012?0:Math.min(1,ge*8)},Be=setInterval(()=>{const he=performance.now();let ge=R.current.micMuted?0:pe(j),xe=q.paused?0:pe(I);ge?F=he+200:!R.current.micMuted&&he<F&&(ge=D.input),xe?G=he+250:!q.paused&&he<G&&(xe=D.output),(Math.abs(ge-D.input)>.025||Math.abs(xe-D.output)>.025||ge===0!=(D.input===0)||xe===0!=(D.output===0))&&(D={input:ge,output:xe},R.current.onAudioActivity?.(D))},100);X.current=()=>{clearInterval(Be),M.disconnect(),L?.disconnect(),y.close().catch(()=>{})}}catch{}const P=new RTCPeerConnection;J.current=P;const q=new Audio;
18q.playsInline=!0,q.autoplay=!0,W.current=q,P.addEventListener("track",y=>{const j=new MediaStream([y.track]);q.srcObject=j,H(j),q.play().then(()=>T(!1)).catch(()=>T(!0))});for(const y of O.getAudioTracks())P.addTrack(y,O);const C=P.createDataChannel("oai-events");V.current=C;const Ve=new Promise(y=>{if(C.readyState==="open"){y(!0);return}const j=M=>()=>{clearTimeout(I),y(M)},I=setTimeout(()=>y(!1),15e3);C.addEventListener("open",j(!0),{once:!0}),C.addEventListener("error",j(!1),{once:!0}),C.addEventListener("close",j(!1),{once:!0})});C.addEventListener("open",()=>{me(),te(),je.current?.()},{once:!0}),C.addEventListener("message",({data:y})=>{try{et(JSON.parse(y))}catch(j){console.error("[live] bad event payload",j)}}),C.addEventListener("close",()=>{Ee.current||(console.warn("[live] data channel closed without final usage"),ne(),z.current?.())});const tt=await P.createOffer();await P.setLocalDescription(tt),await new Promise((y,j)=>{if(P.iceGatheringState==="complete"){y();return}let I=0,M=null;const L=()=>{M&&(clearTimeout(M),M=null),clearTimeout(Y),P.removeEventListener("icegatheringstatechange",F),P.removeEventListener("icecandidate",D),y()},Y=setTimeout(()=>{if(I>0){L();return}P.removeEventListener("icegatheringstatechange",F),P.removeEventListener("icecandidate",D),j(new Error("Timed out while gathering ICE candidates"))},1e4);function D(G){if(!G.candidate){L();return}I+=1,M||(M=setTimeout(L,fs))}function F(){P.iceGatheringState==="complete"&&L()}P.addEventListener("icecandidate",D),P.addEventListener("icegatheringstatechange",F),F()});const oe=P.localDescription?.sdp;if(_)return;if(!oe)throw new Error("Missing local SDP offer");const We=t?`${i}/${t}`:i,Me=await fetch(We,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({sdp:oe,language:m,history:R.current.initialHistory}),signal:w.signal});if(!Me.ok)throw new Error(`Session creation failed (${Me.status})`);const f=await Me.json();if(_||(Z.current=f.sessionId,ee.current=Date.now(),await P.setRemoteDescription({type:"answer",sdp:f.sdp}),h&&await h.catch(()=>{}),_))return;if(!await Ve)throw new Error("The voice channel did not open");if(_)return;f.greeting&&(de({type:"session.instructions.append",event_id:`greeting_${Date.now()}`,delegation_id:null,content:[`Greet the person now, in ${f.languageName}, without waiting for them to speak.`,`Say this and nothing more: "${f.greeting}"`,"Then stop and listen."].join(` 19`)}),de({type:"session.commentary.append",event_id:`greeting_begin_${Date.now()}`,delegation_id:null,content:"Begin the conversation now, following the instructions provided."}))}catch(O){if(_)return;console.error("[live] connection failed:",O),S({title:"Voice chat unavailable",description:O?.message||"Could not start the voice session.",variant:"destructive"}),ne(),z.current?.()}})(),()=>{_=!0,w.abort(),ce()}},[n,t,m,i]),!n||!v?null:e.jsxs("div",{onClick:()=>W.current?.play().then(()=>T(!1)).catch(()=>{}),className:"fixed top-4 left-1/2 -translate-x-1/2 z-[10001] flex items-center gap-2 px-4 py-3 bg-amber-500 text-white rounded-full shadow-lg cursor-pointer animate-pulse hover:bg-amber-600 transition-colors",role:"button","aria-label":"Tap to enable audio",children:[e.jsx(Zn,{className:"w-5 h-5"}),e.jsx("span",{className:"text-sm font-medium whitespace-nowrap",children:"Tap to hear audio"})]})}async function Xt(t,n,s={}){const i=new AbortController,c=()=>i.abort(s.signal?.reason);s.signal?.aborted?c():s.signal?.addEventListener("abort",c,{once:!0});let u,d=setTimeout(()=>i.abort(new Error("The answer took too long. Please try again.")),15e3);const p=()=>{clearTimeout(d),d=setTimeout(()=>i.abort(new Error("The connection stalled. Please try again.")),15e3)};try{const m=await fetch("/api/meet/chat",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({message:t,history:n,language:s.language||"en-GB"}),signal:i.signal});if(!m.ok||!m.body)throw new Error("Joggle could not answer just now. Please try again.");u=m.body.getReader();const h=new TextDecoder,g=s.onSentence?new Fn:null;let E="",b="",x=!1;const k=A=>{if(!A.startsWith("data:"))return;const v=A.slice(5).trim();if(!v)return;let T;
19try{T=JSON.parse(v)}catch{throw new Error("The answer was interrupted. Please try again.")}if(T.type==="error")throw new Error(T.message||"Joggle could not answer just now. Please try again.");if(T.type==="done"){x=!0;return}if(T.type==="chunk"&&typeof T.content=="string"&&(b+=T.content,s.onChunk?.(T.content),g))for(const S of g.push(T.content))s.onSentence(S)};for(;!x;){const{done:A,value:v}=await u.read();if(A){E+=h.decode(),E.trim()&&k(E);break}p(),E+=h.decode(v,{stream:!0});const T=E.split(` 20`);E=T.pop()??"";for(const S of T)if(k(S),x)break}if(!x||!b.trim())throw new Error("The answer was interrupted. Please try again.");const N=g?.flush();return N&&s.onSentence?.(N),b.trim()}catch(m){throw i.signal.aborted&&!s.signal?.aborted?i.signal.reason:m}finally{clearTimeout(d),s.signal?.removeEventListener("abort",c),await u?.cancel().catch(()=>{})}}function vs(t){if(!Array.isArray(t))return[];let n=12e3;return t.filter(s=>(s?.role==="user"||s?.role==="assistant")&&typeof s.content=="string"&&s.content.trim()).slice(-20).reverse().map(s=>{const i=s.content.trim().slice(0,Math.min(2e3,n));return n-=i.length,{role:s.role,content:i}}).filter(s=>s.content).reverse()}function ys(t,n){const s=t.at(-1);return s?.role==="user"&&s.content.trim()===n.trim()?t.slice(0,-1):t}function ct(t){return vs(t.filter(n=>!n.pending&&!n.error).map(n=>({role:n.role==="you"?"user":"assistant",content:n.text})))}function ws(){const[t,n]=l.useState(null),[s,i]=l.useState(!1),[c,u]=l.useState(!1),[d,p]=l.useState(0),[m,h]=l.useState(!1),[g,E]=l.useState(!1),[b,x]=l.useState(!1),[k,N]=l.useState([]),A=l.useRef([]),[v,T]=l.useState(""),[S,J]=l.useState(!1),[V,_e]=l.useState(null),W=l.useRef(null),[Z,Ae]=l.useState(""),[ee,Ee]=l.useState(!1),[K,Re]=l.useState(!1),[Ie,Pe]=l.useState(!1),[re,ue]=l.useState(!1),[X,B]=l.useState({input:0,output:0}),[ve,Oe]=l.useState(""),[R,De]=l.useState(()=>typeof window<"u"&&window.matchMedia("(prefers-color-scheme: dark)").matches),[ae,Ce]=l.useState("en-GB"),[ye,qe]=l.useState({id:0,language:"en-GB",history:[]}),z=l.useRef(0),je=l.useRef(!1),[de,we]=l.useState(),ie=l.useRef(null),be=l.useRef(null),te=l.useRef(null),me=l.useRef(!0),[Je,Ne]=l.useState(!1),et=l.useRef(0),ne=()=>`meet-${Date.now()}-${++et.current}`,ce=f=>{const y=f(A.current);A.current=y,N(y)};l.useEffect(()=>{let f=!0;const y=new AbortController;u(!1);const j=setTimeout(()=>y.abort(),1e4),I=d===0?window.__meetConfig:null;delete window.__meetConfig;const M=new Promise((L,Y)=>y.signal.addEventListener("abort",()=>Y(new Error("timeout")),{once:!0}));return Promise.race([I||fetch("/api/meet/config",{signal:y.signal}),M]).then(async L=>{if(!L)throw new Error("unavailable");if(L.status===404){f&&i(!0);return}if(!L.ok)throw new Error("unavailable");const Y=await L.json();f&&n(Y)}).catch(()=>{f&&u(!0)}).finally(()=>clearTimeout(j)),()=>{f=!1,clearTimeout(j),y.abort()}},[d]),l.useEffect(()=>()=>{W.current?.abort(),z.current+=1},[]),l.useEffect(()=>{ie.current&&(ie.current.inert=!b),b&&be.current?.focus({preventScroll:!0})},[b]),l.useEffect(()=>{b&&me.current&&te.current&&(te.current.scrollTop=te.current.scrollHeight)},[k,b]);const _=(f,y,j)=>{const I=y.trim();if(!I)return;const M=j?"you":"joggle";Oe(`${j?"You":"Joggle"}: ${I.slice(-240)}`),ce(L=>L.some(D=>D.id===f)?L.map(D=>D.id===f?{...D,text:I}:D):[...L,{id:f,role:M,text:I,rowId:f,at:Date.now()}])},w=async({userText:f,speakNow:y,signal:j})=>{let I=!1;try{return await Xt(f,ys(ct(A.current),f),{signal:j,language:ae,onSentence:M=>{const L=lt(M).trim();!L||j.aborted||(I=!0,y(L))}}),{}}catch{return j.aborted?{}:I?{remember:"The answer was interrupted. Do not add unsupported details; offer to try again if needed."}:{speak:"Sorry, I could not get an answer just then. Could you try again?"}}},U=()=>{z.current+=1,h(!1),E(!1),ue(!1),B({input:0,output:0})},O=(f=ae)=>{const y=++z.current;Ae(""),je.current=!1,E(!1),ue(!1),Pe(!1),B({input:0,output:0}),Oe(""),qe({id:y,language:f,history:ct(A.current)}),we(void 0),h(!0)},H=()=>{je.current=!0,E(!0)},P=()=>{const f=!je.current;U(),f&&(Ae("Voice could not connect. You can type instead, or try the microphone again."),x(!0))},q=async(f,y)=>{const j=f.trim();if(!j||W.current)return;const I=new AbortController;W.current=I,T(""),J(!0),x(!0),_e(null),me.current=!0,Ne(!1);const M=y?.history||ct(A.current),L=y?.replyId||ne();ce(y?F=>F.map(G=>
20G.id===L?{...G,text:"",error:void 0,pending:!0}:G):F=>[...F,{id:ne(),role:"you",text:j,at:Date.now()},{id:L,role:"joggle",text:"",at:Date.now(),pending:!0}]);const Y=z.current;m&&we({id:ne(),text:`The visitor typed: ${j}. The adviser is answering in the text panel. Follow this latest request and do not repeat the old answer.`,cancelPending:!0});let D="";try{await Xt(j,M,{signal:I.signal,language:ae,onChunk:F=>{D+=F;const G=lt(D);ce(pe=>pe.map(Be=>Be.id===L?{...Be,text:G}:Be))}}),ce(F=>F.map(G=>G.id===L?{...G,pending:!1}:G)),m&&Y===z.current&&we({id:ne(),text:`The visitor typed: ${j}. The adviser replied in the visible text panel: ${lt(D)}. Remember this context; do not repeat the answer unless asked.`})}catch(F){if(I.signal.aborted)return;ce(G=>G.map(pe=>pe.id===L?{...pe,pending:!1,error:F?.message||"The answer was interrupted. Please try again."}:pe)),_e({message:j,history:M,replyId:L})}finally{W.current===I&&(W.current=null,J(!1))}},C=m?g?X.output>0?"speaking":re?"thinking":"listening":"connecting":"idle",Ve=C==="connecting"?"Connectingâ¦":C==="speaking"?"Joggle is speakingâ¦":C==="thinking"?"Joggle is working on your answerâ¦":m?K?"Microphone muted â you can still type":"Listening â go ahead":"Tap to talk to Joggle",tt=ye.id,oe=()=>z.current===tt,We=Math.max(X.input,X.output),Me=t?.greeting||"Hi, I'm Joggle, an AI assistant for small businesses. I'm here to help you learn about Joggle â in the same way that, if you get a Joggle, yours can help you with your customers. What do you want to know?";return e.jsxs("main",{className:`meet-shell ${R?"meet-dark":""}`,children:[e.jsxs("header",{className:"meet-header",children:[e.jsxs("a",{className:"meet-brand",href:"/",children:[e.jsx(Ue,{variant:R?"light":"dark",className:"meet-brand-icon",alt:""}),e.jsx("span",{children:"Joggle"})]}),e.jsxs("nav",{className:"meet-header-actions","aria-label":"Page options",children:[e.jsx("label",{className:"meet-lang",children:e.jsx("select",{value:ae,onChange:f=>{Ce(f.target.value),m&&O(f.target.value)},"aria-label":"Language",children:le.map(f=>e.jsx("option",{value:f.code,children:f.code==="en-GB"?"English (UK)":f.code},f.code))})}),e.jsx("button",{type:"button",className:"meet-icon-button",onClick:()=>De(f=>!f),"aria-pressed":R,"aria-label":R?"Switch to light":"Switch to dark",children:R?"â":"â¾"}),e.jsx("a",{className:"meet-signin",href:"/signin",children:"Sign in"})]})]}),e.jsxs("div",{className:"meet-centre",children:[e.jsx("div",{className:`meet-mark meet-mark--${X.output>0?"speaking":X.input>0?"listening":"idle"}`,children:e.jsx(Ue,{variant:R?"light":"dark",className:"meet-icon",alt:""})}),e.jsx("h1",{className:"meet-name",children:"Meet Joggle."}),e.jsx("p",{className:"meet-greeting",children:s?"Meet Joggle is not available just now.":Me}),!s&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"meet-stage",children:[e.jsxs("button",{type:"button",className:`meet-button meet-button--${C}`,disabled:!t||m&&(!g||!Ie||ee!==K),onClick:()=>m?Ee(f=>!f):O(),"aria-label":m?ee?"Unmute microphone":"Mute microphone":"Talk to Joggle","aria-pressed":m,"data-testid":"button-meet-talk",children:[e.jsx("span",{className:"meet-button-halo","aria-hidden":"true"}),e.jsx(bs,{})]}),e.jsx("p",{className:"meet-status",role:"status",children:t?Ve:c?"Joggle could not load. Please try again.":"Getting Joggle readyâ¦"}),c&&e.jsx("button",{type:"button",className:"meet-opener",onClick:()=>p(f=>f+1),children:"Try again"}),e.jsx("div",{className:`meet-wave meet-wave--${C}`,"aria-hidden":"true",children:Array.from({length:9}).map((f,y)=>e.jsx("span",{style:{height:`${6+We*(24-Math.abs(4-y)*3)}px`,opacity:We>0?1:.35}},y))}),m&&e.jsxs(e.Fragment,{children:[e.jsx("p",{className:"meet-call-hint",children:"You can interrupt naturally. End stops the conversation."}),e.jsxs("div",{className:"meet-call-controls",children:[e.jsxs("button",{type:"button",className:`meet-round ${K?"is-on":""}`,disabled:!Ie||ee!==K,onClick:()=>Ee(f=>!f),"aria-pressed":K,children:[e.jsx("span",{"aria-hidden":"true",children:K?"ð":"ð"}),e.jsx("small",{children:ee!==K?"Updatingâ¦":K?"Unmute":"Mute"})]}),e.jsxs("button",{type:"button",className:"meet-round meet-round--end",onClick:U,children:[e.jsx("span",{"aria-hidden":"true",children:"â"}),e.jsx("small",{children:"End"})]})]}),ve&&e.jsx("p",{className:"meet-caption",children:ve})]}),e.jsx("button",{type:"button",className:"meet-type-instead",disabled:!t,onClick:()=>x(!0),children:"Type instead"})]}),e.jsxs("p",{className:"meet-demo-note",children:[e.jsx("span",{"aria-hidden":"true",children:"â"})," This is a demo. Nothing here changes any real business."]}),Z&&e.jsx("p",{className:"meet-quiet",role:"status",children:Z}),!m&&k.length===0&&t&&e.jsx("ul",{className:"meet-openers",children:t.openers.map(f=>e.jsx("li",{children:e.jsx("button",{type:"button",onClick:()=>void q(f),className:"meet-opener",disabled:S,children:f})},f))}),e.jsxs("div",{className:"meet-cta",children:[e.jsx("a",{className:"meet-cta-primary",href:"/signin",children:"Start free"}),e.jsx("a",{className:"meet-cta-secondary",href:"/pricing",children:"See pricing"})]})]})]}),e.jsxs("button",{type:"button",className:"meet-panel-toggle",onClick:()=>x(f=>!f),"aria-expanded":b,"aria-controls":"meet-panel","data-testid":"button-meet-panel",children:[b?"Hide transcript":"Show transcript",k.length>0&&!b&&e.jsx("span",{className:"meet-panel-count",children:k.length})]}),e.jsxs("aside",{ref:ie,id:"meet-panel",className:`meet-panel ${b?"is-open":""}`,"aria-hidden":!b,onKeyDown:f=>{f.key==="Escape"&&(x(!1),document.querySelector('[data-testid="button-meet-panel"]')?.focus())},children:[e.jsxs("header",{className:"meet-panel-head",children:[e.jsxs("div",{children:[e.jsx("strong",{children:"Conversation with Joggle"}),e.jsxs("span",{className:`meet-live ${g?"is-live":""}`,children:[e.jsx("i",{"aria-hidden":"true"}),m?g?"Voice connected":"Connecting voiceâ¦":"Text chat"]})]}),e.jsx("button",{type:"button",onClick:()=>x(!1),"aria-label":"Close transcript",children:"Ã"})]}),e.jsxs("div",{ref:te,className:"meet-transcript",onScroll:f=>{const y=f.currentTarget;me.current=y.scrollHeight-y.scrollTop-y.clientHeight<60,Ne(!me.current)},children:[k.length===0&&e.jsx("p",{className:"meet-quiet",children:"Ask anything about Joggle or tell me what you would like a hand with."}),k.map(f=>e.jsxs("div",{className:`meet-bubble-row meet-bubble-row--${f.role}`,children:[f.role==="joggle"&&e.jsx(Ue,{variant:R?"light":"dark",className:"meet-bubble-avatar",alt:""}),e.jsxs("div",{children:[e.jsxs("div",{className:"meet-bubble",children:[f.text||f.pending&&e.jsxs("span",{className:"meet-typing","aria-label":"Joggle is typing",children:[e.jsx("i",{}),e.jsx("i",{}),e.jsx("i",{})]}),f.error&&e.jsx("p",{className:"meet-error",role:"alert",children:f.error}),V?.replyId===f.id&&e.jsx("button",{type:"button",className:"meet-retry",disabled:S,onClick:()=>void q(V.message,V),children:"Try again"})]}),e.jsx("time",{className:"meet-bubble-time",children:new Date(f.at).toLocaleTimeString("en-GB",{hour:"2-digit",minute:"2-digit"})})]})]},f.id))]}),Je&&e.jsx("button",{type:"button",className:"meet-opener",onClick:()=>{me.current=!0,Ne(!1),te.current&&(te.current.scrollTop=te.current.scrollHeight)},children:"Back to latest"}),e.jsxs("form",{className:"meet-composer",onSubmit:f=>{f.preventDefault(),q(v)},children:[e.jsx("input",{ref:be,value:v,maxLength:2e3,onChange:f=>T(f.target.value),placeholder:"Type a message","aria-label":"Type a message to Joggle","data-testid":"input-meet-message",disabled:!t}),e.jsx("button",{type:"submit",disabled:!t||S||!v.trim(),children:"Send"})]}),t?.leadCapture&&e.jsx(xs,{turns:k})]}),m&&e.jsx(Es,{isActive:m,sessionEndpoint:"/api/live/meet/session",initialHistory:ye.history,contextUpdate:de,cancelSupersededDelegations:!0,onClose:()=>{oe()&&P()},onDelegate:w,onConnected:()=>{oe()&&H()},onTranscriptRow:(...f)=>{oe()&&_(f[0],f[1],f[2])},onBusyChange:f=>{oe()&&ue(f)},onAudioActivity:f=>{oe()&&B(f)},onMicMutedChange:f=>{oe()&&(Re(f),Pe(!0))},onMicError:()=>{oe()&&(U(),Ae("Voice stopped because the microphone setting could not be confirmed. You can type instead."))},micMuted:ee,currentLanguage:ye.language},ye.id)]})}function bs(){return e.jsxs("svg",{className:"meet-mic",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[e.jsx("rect",{x:"9",y:"2",width:"6",height:"11",rx:"3"}),e.jsx("path",{d:"M5 10.5a7 7 0 0 0 14 0"}),e.jsx("path",{d:"M12 17.5V21"})]})}function lt(t){return t.replace(/\*/g,"").replace(/__/g,"").replace(/^\s{0,3}#{1,6}\s+/gm,"").replace(/^\s{0,3}[-\u2022]\s+/gm,"")}function xs({turns:t}){const[n,s]=l.useState(""),[i,c]=l.useState(""),[u,d]=l.useState(!1),[p,m]=l.useState("idle"),[h,g]=l.useState("");return p==="done"?e.jsx("p",{className:"meet-lead-done",role:"status",children:"Thanks â someone will be in touch."}):e.jsxs("form",{className:"meet-lead",onSubmit:async E=>{E.preventDefault(),m("sending"),g("");try{const b=await fetch("/api/meet/lead",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:n,name:i,consent:u,transcript:t.map(x=>`${x.role==="you"?"Them":"Joggle"}: ${x.text}`).join(` 21`)})});if(!b.ok){const x=await b.json().catch(()=>({}));throw new Error(x.error||"Could not send that")}m("done")}catch(b){g(b.message||"Could not send that"),m("error")}},children:[e.jsx("strong",{children:"Want someone to follow up?"}),e.jsx("input",{type:"text",value:i,onChange:E=>c(E.target.value),placeholder:"Your name","aria-label":"Your name",autoComplete:"name"}),e.jsx("input",{type:"email",value:n,onChange:E=>s(E.target.value),placeholder:"Your email","aria-label":"Your email",autoComplete:"email",required:!0,"data-testid":"input-meet-email"}),e.jsxs("label",{className:"meet-consent",children:[e.jsx("input",{type:"checkbox",checked:u,onChange:E=>d(E.target.checked),required:!0}),e.jsx("span",{children:"You can email me about Joggle, and keep this conversation so you know
21what I asked about."})]}),h&&e.jsx("p",{className:"meet-error",role:"alert",children:h}),e.jsx("button",{type:"submit",disabled:p==="sending"||!n.trim()||!u,children:p==="sending"?"Sendingâ¦":"Send"})]})}const a=(t,n={})=>{const{preload:s=!1,retries:i=2}=n;return s&&typeof window<"u"&&setTimeout(()=>t().catch(()=>{}),100),l.lazy(()=>{const c=async(u=1)=>{try{return await t()}catch{if(u<i)return await new Promise(h=>setTimeout(h,u*1e3)),c(u+1);let p=null;try{p=sessionStorage.getItem("chunk_reload")}catch{}const m=Date.now();if(!p||m-parseInt(p)>1e4){console.warn("Chunk loading failed after retries, reloading page");try{sessionStorage.setItem("chunk_reload",String(m))}catch{}window.location.reload()}else console.warn("Chunk loading failed but skipping reload to prevent loop");return{default:()=>null}}};return c()})},Ts=a(()=>r(()=>import("./joggle-home-BuNXSvB-.js"),__vite__mapDeps([39,1,40,37,41,42,7,2,4,5,6]))),Zt=a(()=>r(()=>import("./sites-workspace-CyPN7tNV.js"),__vite__mapDeps([43,1,7]))),Ps=a(()=>r(()=>import("./recruitment-job-Car8403W.js"),__vite__mapDeps([44,1,45,7,2,4,5,6]))),js=a(()=>r(()=>import("./recruiter-cv-check-DmrYj_ZH.js"),__vite__mapDeps([46,1,45,7,2,4,5,6]))),ks=a(()=>r(()=>import("./business-pricing-CB2AL_hw.js"),__vite__mapDeps([47,1,40,37,41,7,2,4,5,6]))),Ss=a(()=>r(()=>import("./owner-connect-Dn4JJYS4.js"),__vite__mapDeps([48,1,7,2,4,5,6]))),Ls=a(()=>r(()=>import("./LocalizedLanding-DvU6B2mY.js"),__vite__mapDeps([49,1,11,7,50,40,37,51,9,4,5,6,10,2]))),As=l.lazy(()=>r(()=>import("./LanguageLoadingOverlay-Cip4pQ8r.js"),__vite__mapDeps([52,1,53,7,2,4,5,6])).then(t=>({default:t.LanguageLoadingOverlay}))),Rs=a(()=>r(()=>import("./signin-BDEh9pvb.js"),__vite__mapDeps([17,1,9,4,5,6,7,10,18,2]))),Is=a(()=>r(()=>import("./search-BFSkGqE5.js"),__vite__mapDeps([54,1,26,7,42,55,41,56,2,4,5,6]))),Os=a(()=>r(()=>import("./search-prev-25l1QpwQ.js"),__vite__mapDeps([57,1,9,4,5,6,7,10,2]))),Ds=a(()=>r(()=>import("./InvestorsLanding-DWUfcB-7.js"),__vite__mapDeps([58,1,9,4,5,6,7,10,59,2]))),Cs=a(()=>r(()=>import("./InvestorSignIn-BXTHd-4O.js"),__vite__mapDeps([60,1,9,4,5,6,7,10,59,2]))),Ns=a(()=>r(()=>import("./InvestorRegister-ClFKfMkz.js"),__vite__mapDeps([61,1,9,4,5,6,7,10,59,2]))),Vs=a(()=>r(()=>import("./InvestorUpdates-DHI0XJzm.js"),__vite__mapDeps([62,1,2,63,7,20,4,5,6]))),Ms=a(()=>r(()=>import("./InvestorMaterials-Doam2Pz3.js"),__vite__mapDeps([64,1,2,63,7,4,5,6]))),Bs=a(()=>r(()=>import("./InvestorDeckPage-CixJ9nes.js"),__vite__mapDeps([65,1,2,63,7,66,20,4,5,6]))),Fs=a(()=>r(()=>import("./InvestorAdmin-BJPN42SD.js"),__vite__mapDeps([67,1,2,9,4,5,6,7,10]))),Us=a(()=>r(()=>import("./AffiliatesLanding-DnjloXVu.js"),__vite__mapDeps([68,1,9,4,5,6,7,10,69,2]))),Gs=a(()=>r(()=>import("./AffiliatesRegister-DJJojfFo.js"),__vite__mapDeps([70,1,9,4,5,6,7,10,69,2]))),en=a(()=>r(()=>import("./AffiliatesDeckPage-BOWAqQmE.js"),__vite__mapDeps([71,1,2,66,7,4,5,6]))),Hs=a(()=>r(()=>import("./assistant-CAEPWFgG.js").then(t=>t.k),__vite__mapDeps([3,1,4,5,6,7,2,8,9,10,11,12,13,14,15]))),tn=a(()=>r(()=>import("./joggle-page-Dllnfu0Q.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16]))),$s=a(()=>r(()=>import("./username-tool-route-qcTKZzP1.js"),__vite__mapDeps([72,1,2,4,5,6,7]))),qs=a(()=>r(()=>import("./contribute-K-2AtDXm.js"),__vite__mapDeps([73,1,4,5,6,7,2]))),Js=a(()=>r(()=>import("./signage-player-B7aGjHF6.js"),__vite__mapDeps([74,1,7,2,4,5,6,75]))),Ws=a(()=>r(()=>import("./receptionist-app-Dw_HUyyU.js").then(t=>t.r),__vite__mapDeps([76,1,7]))),Ks=a(()=>r(()=>import("./admin-wusXjwjI.js"),__vite__mapDeps([77,1,2,9,4,5,6,7,10,31,20,21,16]))),zs=a(()=>r(()=>import("./admin-personal-funnel-DPKrqm4z.js"),__vite__mapDeps([78,1]))),Ys=a(()=>r(()=>import("./admin-onboarding-funnel-EJhdPa4h.js"),__vite__mapDeps([79,1]))),Qs=a(()=>r(()=>import("./admin-help-content-B_vYhmnN.js"),__vite__mapDeps([80,1]))),Xs=a(()=>r(()=>import("./admin-email-programme-CHwr3GcS.js"),__vite__mapDeps([81,1,2,4,5,6,7]))),Zs=a(()=>r(()=>import("./admin-meet-Q2eb5GIB.js"),__vite__mapDeps([82,1]))),er=a(()=>r(()=>import("./admin-sms-billing-CuKCdYug.js"),__vite__mapDeps([83,1,2,4,5,6,7]))),tr=a(()=>r(()=>import("./admin-community-ops-DWIWgKVg.js"),__vite__mapDeps([84,1,2,9,4,5,6,7,10,85,15,86]))),nr=a(()=>r(()=>import("./admin-community-queue-DUyVeRe7.js"),__vite__mapDeps([87,1,2,9,4,5,6,7,10]))),or=a(()=>r(()=>import("./aime-OtV6Hj_Y.js"),__vite__mapDeps([88,1,9,4,5,6,7,10,2,21]))),sr=a(()=>r(()=>import("./document-intelligence-CS2SlTdn.js"),__vite__mapDeps([89,1,9,4,5,6,7,10]))),rr=a(()=>r(()=>import("./import-manager-DLm22sm-.js"),__vite__mapDeps([90,1,2,4,5,6,7,9,10]))),ar=a(()=>r(()=>import("./dashboard-minimal-D9jOHIt9.js").then(t=>t.d),__vite__mapDeps([19,1,20,4,5,6,7,14,2,9,10,21,22,23,24,25,26,27,28,29,30,31,32,33]))),ir=a(()=>r(()=>import("./owner-design-system-D7IlDOg5.js"),__vite__mapDeps([91,1,56,26,7]))),cr=a(()=>r(()=>import("./joggle-home-ds-D0O0Ok5D.js"),__vite__mapDeps([92,1,55,42,41,56,26,7,2,4,5,6]))),lr=a(()=>r(()=>import("./public-contact-jl_X8qPI.js"),__vite__mapDeps([93,1,42,55,41,56,26,7,2,4,5,6]))),ur=a(()=>r(()=>import("./public-examples-BySiQig6.js"),__vite__mapDeps([94,1,42,55,41,56,26,7,2,4,5,6]))),dr=a(()=>r(()=>import("./public-how-it-works-BlTn4Tb_.js"),__vite__mapDeps([95,1,42,55,41,56,26,7,2,4,5,6]))),mr=a(()=>r(()=>import("./public-pricing-BEj021YL.js"),__vite__mapDeps([96,1,40,37,41,42,55,56,26,7,2,4,5,6]))),nn=a(()=>r(()=>import("./change-password-CYRciHmy.js"),__vite__mapDeps([97,1,9,4,5,6,7,10,2]))),pr=a(()=>r(()=>import("./pub-D6_tB6_b.js"),__vite__mapDeps([98,1,11,7,2,4,5,6]))),hr=a(()=>r(()=>import("./agents-Za8_U5eU.js"),__vite__mapDeps([99,1,11,7,2,4,5,6]))),gr=a(()=>r(()=>
21import("./lite-JIcvVWqx.js"),__vite__mapDeps([100,1,9,4,5,6,7,10,2]))),fr=a(()=>r(()=>import("./ai-discoverability-0pdg5oEW.js"),__vite__mapDeps([101,1,9,4,5,6,7,10,40,37,11,50,2]))),_r=a(()=>r(()=>import("./lite-register-D5I8kLow.js"),__vite__mapDeps([102,1,10,9,4,5,6,7,2]))),Er=a(()=>r(()=>import("./lite-success-B2f5_i6B.js"),__vite__mapDeps([103,1,9,4,5,6,7,10,2]))),vr=a(()=>r(()=>import("./claim-joggle-BGBluA3b.js"),__vite__mapDeps([104,1,9,4,5,6,7,10,2]))),yr=a(()=>r(()=>import("./claim-search-DGkLFJcL.js"),__vite__mapDeps([105,1,9,4,5,6,7,10,2]))),wr=a(()=>r(()=>import("./activate-search-C2mKBzji.js"),__vite__mapDeps([106,1,9,4,5,6,7,10,2]))),br=a(()=>r(()=>import("./jain-CJrCKDqj.js"),__vite__mapDeps([107,1,7,2,4,5,6]))),xr=a(()=>r(()=>import("./waitlist-Nlo5IoNn.js"),__vite__mapDeps([108,1,2,9,4,5,6,7,10]))),Tr=a(()=>r(()=>import("./reserve-BFcLxhHt.js"),__vite__mapDeps([109,1,2,9,4,5,6,7,10]))),Pr=a(()=>r(()=>import("./AcceptStaffInvite-D9fyEzxa.js"),__vite__mapDeps([110,1,9,4,5,6,7,10,2]))),jr=a(()=>r(()=>import("./MyRota-DBrsWo7N.js"),__vite__mapDeps([111,1,2,9,4,5,6,7,10,27,22,112]))),kr=a(()=>r(()=>import("./RotaInvite-vqC_ZZuF.js"),__vite__mapDeps([113,1,9,4,5,6,7,10,2]))),Sr=a(()=>r(()=>import("./business-assistant-3bozOcj8.js"),__vite__mapDeps([114,1,9,4,5,6,7,10,2]))),Lr=a(()=>r(()=>import("./auth-CxXWv4es.js"),__vite__mapDeps([115,1,9,4,5,6,7,10,2]))),Ar=a(()=>r(()=>import("./aurevoir-8WlHZapA.js"),__vite__mapDeps([116,1,2,4,5,6,7]))),Rr=a(()=>r(()=>import("./forgot-password-rkpliEG9.js"),__vite__mapDeps([117,1,9,4,5,6,7,10,2]))),Ir=a(()=>r(()=>import("./reset-password-BSGK7noo.js"),__vite__mapDeps([118,1,9,4,5,6,7,10,2]))),Or=a(()=>r(()=>import("./set-password-C6VAXoOu.js"),__vite__mapDeps([119,1,9,4,5,6,7,10,2]))),Dr=a(()=>r(()=>import("./verify-email-B_HCLRcQ.js"),__vite__mapDeps([120,1,9,4,5,6,7,10,2]))),Cr=a(()=>r(()=>import("./onboarding-BI4tSU3B.js"),__vite__mapDeps([121,1,9,4,5,6,7,10,2]))),Nr=a(()=>r(()=>import("./accept-invite-xhrh_mEF.js"),__vite__mapDeps([122,1,9,4,5,6,7,10,2]))),Vr=a(()=>r(()=>import("./subscribe-DTuXQMmL.js"),__vite__mapDeps([123,1,15,4,5,6,7,9,10,2]))),Mr=a(()=>r(()=>import("./upgrade-CsnX-A0z.js"),__vite__mapDeps([124,1,4,5,6,7,2,40,37,9,10]))),Br=a(()=>r(()=>import("./go-pro-CxP0PkdM.js"),__vite__mapDeps([125,1,4,5,6,7,40,37,2]))),Fr=a(()=>r(()=>import("./SectorLanding-3hPlKH4k.js"),__vite__mapDeps([126,1,9,4,5,6,7,10,2]))),Ur=a(()=>r(()=>import("./BookingsManagement-BwbVBuIe.js"),__vite__mapDeps([127,1,2,30,7,9,4,5,6,10,85,15,86,33]))),Gr=a(()=>r(()=>import("./BookingsSettings-OW1O1jcI.js"),__vite__mapDeps([128,1,22,2,9,4,5,6,7,10]))),Hr=a(()=>r(()=>import("./BookingMethodPage-DE7Y83Z0.js"),__vite__mapDeps([129,1,9,4,5,6,7,10,2]))),on=a(()=>r(()=>import("./FloorPlanEditor-Cdk1YJ1H.js"),__vite__mapDeps([130,1,2,9,4,5,6,7,10]))),$r=a(()=>r(()=>import("./meeting-type-settings-DsCzgGqj.js"),__vite__mapDeps([131,1,2,9,4,5,6,7,10,132]))),qr=a(()=>r(()=>import("./calendar-connections-CkQswdr9.js"),__vite__mapDeps([133,1,2,9,4,5,6,7,10]))),Jr=a(()=>r(()=>import("./provider-connections-CPeZksyj.js"),__vite__mapDeps([134,1,2,9,4,5,6,7,10]))),Wr=a(()=>r(()=>import("./TicketCheckPage-D3Wku1TG.js"),__vite__mapDeps([135,1,7,2,4,5,6]))),Kr=a(()=>r(()=>import("./EmailProviderChecker-C6jrns2r.js"),__vite__mapDeps([136,1,9,4,5,6,7,10]))),sn=a(()=>r(()=>import("./EmailClient-D7BEbqHD.js"),__vite__mapDeps([137,1,2,20,9,4,5,6,7,10])));a(()=>r(()=>import("./EmailDashboard-Bvs0IFHu.js"),__vite__mapDeps([138,1,9,4,5,6,7,10,2])));const zr=a(()=>r(()=>import("./ai-customer-support-for-small-business-Byhi6Prs.js"),__vite__mapDeps([139,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),Yr=a(()=>r(()=>import("./ai-chatbot-for-small-business-CyMbyGP1.js"),__vite__mapDeps([142,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),Qr=a(()=>r(()=>import("./automated-customer-enquiries-D6y8YE7o.js"),__vite__mapDeps([143,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),Xr=a(()=>r(()=>import("./ai-customer-service-assistant-DNZwVVQz.js"),__vite__mapDeps([144,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),Zr=a(()=>r(()=>import("./capture-customer-enquiries-automatically-Bhob7g86.js"),__vite__mapDeps([145,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),ea=a(()=>r(()=>import("./ai-chatbot-for-pubs-DGaDLy_b.js"),__vite__mapDeps([146,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),ta=a(()=>r(()=>import("./ai-chatbot-for-restaurants-DB1wckIM.js"),__vite__mapDeps([147,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),na=a(()=>r(()=>import("./ai-chatbot-for-cafes-Bu-iJjyv.js"),__vite__mapDeps([148,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),oa=a(()=>r(()=>import("./ai-chatbot-for-hotels-O2Zui2Y7.js"),__vite__mapDeps([149,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),sa=a(()=>r(()=>import("./ai-chatbot-for-gyms-D5RG9zZP.js"),__vite__mapDeps([150,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),ra=a(()=>r(()=>import("./ai-chatbot-for-hairdressers-iTAF-asw.js"),__vite__mapDeps([151,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),aa=a(()=>r(()=>import("./ai-chatbot-for-tourism-ZVWo9HWv.js"),__vite__mapDeps([152,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),ia=a(()=>r(()=>import("./never-miss-a-booking-request-tCdY7Wmu.js"),__vite__mapDeps([153,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),ca=a(()=>r(()=>import("./automated-booking-enquiries-DFTk8MEe.js"),__vite__mapDeps([154,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),la=a(()=>r(()=>import("./case-study-we-three-loggerheads-DVeeUAzj.js"),__vite__mapDeps([155,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),ua=a(()=>r(()=>
21import("./how-a-pub-automated-customer-enquiries-BFso0B4N.js"),__vite__mapDeps([156,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),da=a(()=>r(()=>import("./ai-chatbot-london-CfzeRvo-.js"),__vite__mapDeps([157,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),ma=a(()=>r(()=>import("./ai-chatbot-manchester-Cq_psSxH.js"),__vite__mapDeps([158,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),pa=a(()=>r(()=>import("./ai-chatbot-wales-DSAZBtra.js"),__vite__mapDeps([159,1,140,141,51,9,4,5,6,7,10,11,40,37,50,2]))),ha=a(()=>r(()=>import("./blog-index-CwgmPmgD.js"),__vite__mapDeps([160,1,161,141,51,9,4,5,6,7,10,11,50,2]))),ga=a(()=>r(()=>import("./blog-article-Drfq6dgw.js"),__vite__mapDeps([162,1,141,51,9,4,5,6,7,10,11,50,20,161,2]))),ut=a(()=>r(()=>import("./DiscoveryHubPage-DOVg4G5C.js"),__vite__mapDeps([163,1,51,9,4,5,6,7,10,2]))),fa=a(()=>r(()=>import("./FoundHub-CI76ON2-.js"),__vite__mapDeps([164,1,165]))),_a=a(()=>r(()=>import("./FoundTrades-CvVOiQK2.js"),__vite__mapDeps([166,1,167,51,9,4,5,6,7,10,168,169,170,171,172,2]))),Ea=a(()=>r(()=>import("./FoundHospitality-7fuPjA2O.js"),__vite__mapDeps([173,1,167,51,9,4,5,6,7,10,168,169,170,171,172,2]))),va=a(()=>r(()=>import("./FoundLocalServices-BfO_1PAR.js"),__vite__mapDeps([174,1,167,51,9,4,5,6,7,10,168,169,170,171,172,2]))),ya=a(()=>r(()=>import("./FoundMold-Cm935YGh.js"),__vite__mapDeps([175,1,165]))),wa=a(()=>r(()=>import("./FoundPricing-mdECmRvw.js"),__vite__mapDeps([176,1,167,51,9,4,5,6,7,10,168,171,172,2]))),ba=a(()=>r(()=>import("./FoundHelp-ic5rn_vz.js"),__vite__mapDeps([177,1,167,51,9,4,5,6,7,10,168,171,2]))),xa=a(()=>r(()=>import("./FoundAbout-CKKxquWH.js"),__vite__mapDeps([178,1,167,51,9,4,5,6,7,10,168,172,2]))),Ta=a(()=>r(()=>import("./FoundStart-Dfs3CBFc.js"),__vite__mapDeps([179,1,15,170,21,2,4,5,6,7,168]))),Pa=a(()=>r(()=>import("./FoundWelcome-BFmQvOMp.js"),__vite__mapDeps([180,1,2,4,5,6,7,168]))),ja=a(()=>r(()=>import("./FoundHow-DGk4aSof.js"),__vite__mapDeps([181,1,167,51,9,4,5,6,7,10,168,172,170,2]))),ka=a(()=>r(()=>import("./FoundScore-BktRZc1K.js"),__vite__mapDeps([182,1,165,2,4,5,6,7]))),Sa=a(()=>r(()=>import("./FoundScoreChecking-wlGWbJ4x.js"),__vite__mapDeps([183,1]))),La=a(()=>r(()=>import("./FoundScoreReport-CTyeDQcs.js"),__vite__mapDeps([184,1,2,4,5,6,7]))),Aa=a(()=>r(()=>import("./logout-D2KWlCVd.js"),__vite__mapDeps([185,1,9,4,5,6,7,10,2]))),Ra=a(()=>r(()=>import("./terms-B6dlK2C2.js"),__vite__mapDeps([186,1,187,141,51,9,4,5,6,7,10,11,2]))),Ia=a(()=>r(()=>import("./privacy-BD_C1ez-.js"),__vite__mapDeps([188,1,187,141,51,9,4,5,6,7,10,11,2]))),Oa=a(()=>r(()=>import("./cookies-CxhH5sQg.js"),__vite__mapDeps([189,1,187,141,51,9,4,5,6,7,10,11,2]))),Da=a(()=>r(()=>import("./careers-C3NyVIlH.js"),__vite__mapDeps([190,1,141,51,9,4,5,6,7,10,11,50,2]))),Ca=a(()=>r(()=>import("./shareholders-F7y0Mnuz.js"),__vite__mapDeps([191,1,9,4,5,6,7,10,2]))),Na=a(()=>r(()=>import("./not-found-BC9oWPCG.js"),__vite__mapDeps([192,1,9,4,5,6,7,10]))),Va=a(()=>r(()=>import("./unsubscribe-B2GMKv-c.js"),__vite__mapDeps([193,1,2,9,4,5,6,7,10])));a(()=>r(()=>import("./register-business-BifhEe3C.js"),__vite__mapDeps([194,1,2,4,5,6,7])));const Ma=a(()=>r(()=>import("./PersonalDashboardRouter-BExFlPr_.js"),__vite__mapDeps([34,1,2,4,5,6,7,35,36,37,9,10]))),dt=a(()=>r(()=>import("./public-personal-profile-DKdRC-ft.js"),__vite__mapDeps([195,1,2,8,4,5,6,7,28,196,197,15,198,199]))),Ba=a(()=>r(()=>import("./PublicMediaKit-pX3q3Bu6.js"),__vite__mapDeps([200,1,7,2,4,5,6]))),rn=a(()=>r(()=>import("./MoveFromLinktree-C5Ra_vGB.js"),__vite__mapDeps([201,1,7,2,4,5,6]))),an=a(()=>r(()=>import("./GuestSpacePage-BsDZ_DSX.js"),__vite__mapDeps([202,1,2,4,5,6,7]))),cn=a(()=>r(()=>import("./public-personal-card-DCNzFnyu.js"),__vite__mapDeps([203,1,197,7,2,4,5,6]))),Fa=a(()=>r(()=>import("./connect-claim-Cuo5zDmk.js"),__vite__mapDeps([204,1,35,2,205,7,4,5,6]))),Ua=a(()=>r(()=>import("./public-personal-event-Bn1l5J06.js"),__vite__mapDeps([206,1,197,207,208,4,5,6,7,2,209,210]))),ln=a(()=>r(()=>import("./PublicBlog-Cm0iobCC.js"),__vite__mapDeps([211,1,212,197,7,2,4,5,6]))),un=a(()=>r(()=>import("./PublicBlogPost-3hxTbzD1.js"),__vite__mapDeps([213,1,205,212,197,7,2,4,5,6]))),ke=a(()=>r(()=>import("./public-personal-gallery-Cg9mGPtv.js"),__vite__mapDeps([214,1,2,9,4,5,6,7,10,215,216,198,217]))),Ga=a(()=>r(()=>import("./public-personal-cv-BWhM3Z5t.js"),__vite__mapDeps([218,1,2,199,7,4,5,6]))),Ha=a(()=>r(()=>
21import("./public-personal-cv-chapters-BHQhaltV.js"),__vite__mapDeps([219,1,2,199,7,4,5,6]))),$a=a(()=>r(()=>import("./public-personal-cv-threads-CqpozRHu.js"),__vite__mapDeps([220,1,2,199,7,4,5,6]))),qa=a(()=>r(()=>import("./public-personal-cv-cinematic-BR51_VXv.js"),__vite__mapDeps([221,1,2,199,7,4,5,6]))),Ja=a(()=>r(()=>import("./public-personal-film-Bh6eCGM6.js"),__vite__mapDeps([222,1,2,223,7,10,4,5,6]))),Wa=a(()=>r(()=>import("./start-CGhxQ7BS.js"),__vite__mapDeps([224,1,9,4,5,6,7,10,2]))),Ka=a(()=>r(()=>import("./create-joggle-tGoPFLxE.js"),__vite__mapDeps([225,1,9,4,5,6,7,10,226,15,2]))),za=a(()=>r(()=>import("./activate-joggle-_wBURBoL.js"),__vite__mapDeps([227,1,9,4,5,6,7,10,226,15,2])));a(()=>r(()=>import("./register-step1-BZ08RZVL.js"),__vite__mapDeps([228,1,9,4,5,6,7,10,229,2])));a(()=>r(()=>import("./register-step2-DK2fhfmv.js"),__vite__mapDeps([230,1,9,4,5,6,7,10,229,2])));a(()=>r(()=>import("./register-step3-C3LGeOtW.js"),__vite__mapDeps([231,1,9,4,5,6,7,10,229,21,2])));a(()=>r(()=>import("./register-step4-C9IoPKca.js"),__vite__mapDeps([232,1,9,4,5,6,7,10,229,2])));const Te=a(()=>r(()=>import("./register-business-find-D1AjXev4.js"),__vite__mapDeps([233,1,9,4,5,6,7,10,229,21,29,2]))),Ya=a(()=>r(()=>import("./register-business-account-BEhlsP1F.js"),__vite__mapDeps([234,1,9,4,5,6,7,10,229,29,2]))),Qa=a(()=>r(()=>import("./register-business-verify-BfdtU272.js"),__vite__mapDeps([235,1,9,4,5,6,7,10,229,29,2]))),Xa=a(()=>r(()=>import("./register-business-reveal-BCCeYO1K.js"),__vite__mapDeps([236,1,9,4,5,6,7,10,29,2]))),Ye=a(()=>r(()=>import("./public-booking-BAhIw4nf.js"),__vite__mapDeps([237,1,197,2,9,4,5,6,7,10,215]))),Za=a(()=>r(()=>import("./public-booking-reschedule-h-d2OwDh.js"),__vite__mapDeps([238,1,7,2,4,5,6]))),ei=a(()=>r(()=>import("./public-booking-cancel-IArRNAQ6.js"),__vite__mapDeps([239,1,7,2,4,5,6]))),ti=a(()=>r(()=>import("./personal-start-2QI6V6uP.js"),__vite__mapDeps([240,1,22,4,5,6,7,40,37,199,2])));a(()=>r(()=>import("./personal-signin-DLWcuLiC.js"),__vite__mapDeps([241,1,9,4,5,6,7,10,35,2,18])));const dn=a(()=>r(()=>import("./joggle-pro-home-DjYk4gvh.js"),__vite__mapDeps([242,1]))),ni=a(()=>r(()=>import("./personal-landing-new-C5r7Bsu7.js"),__vite__mapDeps([243,1,40,37,2,4,5,6,7]))),oi=a(()=>r(()=>import("./personal-landing-DAHYDN1P.js"),__vite__mapDeps([244,1,2,4,5,6,7])));a(()=>r(()=>import("./personal-onboarding-DpyNztz3.js"),__vite__mapDeps([245,1,35,2,7,4,5,6])));const si=a(()=>r(()=>import("./personal-register-DzuneuOZ.js"),__vite__mapDeps([246,1,9,4,5,6,7,10,2]))),ri=a(()=>r(()=>import("./personal-pricing-SCYqdJfs.js"),__vite__mapDeps([247,1,9,4,5,6,7,10,40,37,35,2,36]))),ai=a(()=>r(()=>import("./personal-privacy-CyYyT1vx.js"),__vite__mapDeps([248,1,2,4,5,6,7]))),ii=a(()=>r(()=>import("./personal-terms-BIj2J3tU.js"),__vite__mapDeps([249,1,2,4,5,6,7]))),ci=a(()=>r(()=>import("./Feedback-9u_QQ1yu.js"),__vite__mapDeps([250,1,9,4,5,6,7,10,208,2,209,210]))),li=a(()=>r(()=>import("./FeedbackList-D3dOTMX_.js"),__vite__mapDeps([251,1,9,4,5,6,7,10,2]))),ui=a(()=>r(()=>import("./FeedbackDetail-mfxvQCyz.js"),__vite__mapDeps([252,1,9,4,5,6,7,10,2]))),di=a(()=>r(()=>import("./CustomerBookingPage-CaqsdkXh.js"),__vite__mapDeps([253,1,9,4,5,6,7,10,13,12,2]))),mi=a(()=>r(()=>import("./BookingWidgetRedirect-CHxbCzep.js"),__vite__mapDeps([254,1,2,4,5,6,7]))),pi=a(()=>r(()=>import("./DepositPaymentPage-DMR-OkHE.js"),__vite__mapDeps([255,1,15,9,4,5,6,7,10,13,12,2]))),hi=a(()=>r(()=>import("./CardGuaranteePage-wC2CHOcj.js"),__vite__mapDeps([256,1,15,9,4,5,6,7,10,2]))),gi=a(()=>r(()=>import("./room-booking-status-Cpt7EGHH.js"),__vite__mapDeps([257,1,9,4,5,6,7,10,2]))),fi=a(()=>r(()=>import("./ServiceJobStatus-h72qITml.js"),__vite__mapDeps([258,1,2,15,13,12,7,259,4,5,6]))),_i=a(()=>r(()=>import("./ServiceInvoicePayment-CGGm6sJI.js"),__vite__mapDeps([260,1,2,15,4,5,6,7]))),Ei=a(()=>r(()=>import("./TradesBookingWizard-CRVIC8VW.js"),__vite__mapDeps([261,1,2,262,15,259,13,12,7,4,5,6]))),vi=a(()=>r(()=>import("./TradesMyBookings-8NDYN8TM.js"),__vite__mapDeps([263,1,2,4,5,6,7]))),mn=a(()=>r(()=>import("./TradesDashboardLayout-DgrzBQjb.js").then(t=>t.e),__vite__mapDeps([264,1,2,9,4,5,6,7,10,265,32,33,25]))),pn=a(()=>r(()=>import("./YogaDashboardLayout-BWQAYeil.js").then(t=>t.Y),__vite__mapDeps([266,1,2,267,7]))),hn=a(()=>r(()=>import("./FoundDashboardLayout-DoWYFZF3.js"),__vite__mapDeps([268,1,2,4,5,6,7]))),yi=a(()=>r(()=>import("./YogaBookingWizard-C9lPbMGa.js"),__vite__mapDeps([269,1,22,15,267,7,2,4,5,6])));a(()=>r(()=>import("./YogaStudioPage-B4quUepg.js"),__vite__mapDeps([270,1,8,267,2,4,5,6,7])));const wi=a(()=>r(()=>import("./YogaMyClasses-1vjkEAVP.js"),__vite__mapDeps([271,1,267,7,2,4,5,6]))),bi=a(()=>r(()=>import("./joggle-jobs-landing-BpHRTGEX.js"),__vite__mapDeps([272,1,2,4,5,6,7]))),xi=a(()=>r(()=>import("./customer-signin-DGcTngqo.js"),__vite__mapDeps([273,1,9,4,5,6,7,10,12,2]))),Ti=a(()=>r(()=>import("./customer-verify-CqpQxIyo.js"),__vite__mapDeps([274,1,2,9,4,5,6,7,10]))),Pi=a(()=>r(()=>import("./magic-login-Ckvm054F.js"),__vite__mapDeps([275,1,2,9,4,5,6,7,10]))),gn=a(()=>r(()=>import("./my-messages-CHrQg9y5.js"),__vite__mapDeps([276,1,2,12,13,7,4,5,6]))),ji=a(()=>r(()=>import("./my-bookings-D7cmM3-g.js"),__vite__mapDeps([277,1,2,12,9,4,5,6,7,10,13]))),ki=a(()=>r(()=>import("./my-booking-detail-BLET2YrS.js"),__vite__mapDeps([278,1,2,12,9,4,5,6,7,10,13]))),Si=a(()=>r(()=>import("./my-booking-receipt-AZQSyeR9.js"),__vite__mapDeps([279,1,2,12,9,4,5,6,7,10]))),Li=a(()=>r(()=>import("./my-booking-proof-DOBH8BGk.js"),__vite__mapDeps([280,1,2,12,7,4,5,6]))),Ai=a(()=>r(()=>import("./welcome-0-BPOWJIwY.js"),__vite__mapDeps([281,1,9,4,5,6,7,10,2]))),Ri=a(()=>r(()=>import("./welcome-1-DJeqjZ9s.js"),__vite__mapDeps([282,1,9,4,5,6,7,10,2]))),Ii=a(()=>r(()=>import("./welcome-2-D76Iykry.js"),__vite__mapDeps([283,1,9,4,5,6,7,10,2]))),Oi=a(()=>r(()=>import("./welcome-3-Dp0tn813.js"),__vite__mapDeps([284,1,9,4,5,6,7,10,2]))),Di=a(()=>r(()=>import("./welcome-4-DZft9ANt.js"),__vite__mapDeps([285,1,9,4,5,6,7,10,2]))),Ci=a(()=>r(()=>import("./welcome-5-NqKJsa-v.js"),__vite__mapDeps([286,1,9,4,5,6,7,10,2]))),Ni=a(()=>r(()=>import("./welcome-7-e3CDv4k9.js"),__vite__mapDeps([287,1,9,4,5,6,7,10,2]))),Q=l.memo(()=>{const[t,n]=l.useState(!1);return l.useEffect(()=>{const s=setTimeout(()=>n(!0),250);return()=>clearTimeout(s)},[]),t?e.jsx("div",{className:"flex items-center justify-center min-h-screen bg-white dark:bg-gray-900",children:e.jsxs("div",{className:"flex flex-col items-center gap-3",children:[e.jsx(Ue,{className:"w-10 h-10"}),e.jsx("span",{className:"text-[15px] font-medium text-black dark:text-white",children:"I'm on it."})]})}):e.jsx("div",{className:"min-h-screen bg-white dark:bg-gray-900"})}),mt=()=>{const{user:t,isLoading:n,isFetching:s}=$e();return!t&&(n||s)?e.jsx(Q,{}):t?t.accountTypes?.includes("personal")&&!t.accountTypes?.includes("business")?(window.location.href="/me",null):t.foundVerified?(window.location.href="/dashboard/found",null):t.hasTradesPlugin?(window.location.href="/dashboard/trades",null):t.hasYogaPlugin?(window.location.href="/dashboard/yoga",null):e.jsx(Ko,{children:e.jsx(ar,{})}):(window.location.replace("/signin"),null)},pt=No(),Vi=window.__JOGGLE_PD__;function Mi(){const{user:t,isLoading:n}
21=$e(),[s]=xt(),i=l.useDeferredValue(s),c=s!==i,u=t?.id??null;return l.useEffect(()=>{if(!u)return;let d=null;try{d=window.sessionStorage.getItem(ft(u))}catch{}zo(kt,d),Ln(!0)},[u]),Vi?.slug?e.jsx(l.Suspense,{fallback:e.jsx(Q,{}),children:e.jsx("div",{className:"page-transition",children:e.jsxs(Ke,{children:[e.jsx(o,{path:"/blog/:postSlug",component:un}),e.jsx(o,{path:"/blog",component:ln}),e.jsx(o,{path:"/card",component:cn}),e.jsx(o,{path:"/booking/:meetingSlug",component:Ye}),e.jsx(o,{path:"/booking",component:Ye}),e.jsx(o,{path:"/",component:dt}),e.jsx(o,{component:dt})]})})}):t&&t.mustChangePassword&&!t.isBeingImpersonated?e.jsx(l.Suspense,{fallback:e.jsx(Q,{}),children:e.jsx("div",{className:"page-transition",children:e.jsxs(Ke,{children:[e.jsx(o,{path:"/change-password",component:nn}),e.jsx(o,{component:()=>e.jsx(nn,{})})]})})}):e.jsx(l.Suspense,{fallback:e.jsx(Q,{}),children:e.jsxs("div",{className:"page-transition",children:[c&&e.jsx("div",{className:"route-progress","aria-hidden":"true"}),e.jsxs(Ke,{location:i,children:[e.jsx(o,{path:"/logout",component:Aa}),e.jsx(o,{path:"/unsubscribe",component:Va}),e.jsx(o,{path:"/accept-invite",component:Nr}),e.jsx(o,{path:"/ticket/check/:token",component:Wr}),e.jsx(o,{path:"/",component:()=>n?e.jsx(Q,{}):pt?t?e.jsx(mt,{}):typeof window<"u"&&new URLSearchParams(window.location.search).get("v")==="old"?e.jsx(ni,{}):e.jsx(dn,{}):ot()?e.jsx(cr,{}):t?e.jsx(mt,{}):e.jsx(Ts,{})}),e.jsx(o,{path:"/signin",component:Rs}),e.jsx(o,{path:"/pricing",component:()=>ot()?e.jsx(mr,{}):e.jsx(ks,{})}),e.jsx(o,{path:"/contact",component:lr}),e.jsx(o,{path:"/examples",component:ur}),e.jsx(o,{path:"/how-it-works",component:dr}),e.jsx(o,{path:"/owner/connect",component:Ss}),e.jsx(o,{path:"/search",component:()=>ot()?e.jsx(Is,{}):e.jsx(Os,{})}),e.jsx(o,{path:"/demo/recruitment-job",component:Ps}),e.jsx(o,{path:"/demo/recruiter-cv-check",component:js}),e.jsx(o,{path:"/waitlist",component:xr}),pt&&e.jsx(o,{path:"/register",component:si}),!pt&&e.jsx(o,{path:"/register",component:Te}),e.jsx(o,{path:"/register/business",component:Te}),e.jsx(o,{path:"/register/business/find",component:Te}),e.jsx(o,{path:"/register/business/account",component:Ya}),e.jsx(o,{path:"/register/business/verify",component:Qa}),e.jsx(o,{path:"/register/business/reveal",component:Xa}),e.jsx(o,{path:"/register/business/step1",component:Te}),e.jsx(o,{path:"/register/business/step2",component:Te}),e.jsx(o,{path:"/register/business/step3",component:Te}),e.jsx(o,{path:"/register/business/step4",component:Te}),e.jsx(o,{path:"/welcome/0",component:Ai}),e.jsx(o,{path:"/welcome/1",component:Ri}),e.jsx(o,{path:"/welcome/2",component:Ii}),e.jsx(o,{path:"/welcome/3",component:Oi}),e.jsx(o,{path:"/welcome/4",component:Di}),e.jsx(o,{path:"/welcome/5",component:Ci}),e.jsx(o,{path:"/welcome/7",component:Ni}),e.jsx(o,{path:"/forgot-password",component:Rr}),e.jsx(o,{path:"/reset-password",component:Ir}),e.jsx(o,{path:"/set-password",component:Or}),e.jsx(o,{path:"/admin",component:()=>e.jsx($,{children:e.jsx(Ks,{})})}),e.jsx(o,{path:"/admin/personal-funnel",component:()=>e.jsx($,{children:e.jsx(zs,{})})}),e.jsx(o,{path:"/admin/onboarding-funnel",component:()=>e.jsx($,{children:e.jsx(Ys,{})})}),e.jsx(o,{path:"/admin/help-content",component:()=>e.jsx($,{children:e.jsx(Qs,{})})}),e.jsx(o,{path:"/admin/email-programme",component:()=>e.jsx($,{children:e.jsx(Xs,{})})}),e.jsx(o,{path:"/admin/meet",component:()=>e.jsx($,{children:e.jsx(Zs,{})})}),e.jsx(o,{path:"/admin/design-system",component:()=>e.jsx($,{children:e.jsx(ir,{})})}),e.jsx(o,{path:"/admin/sms-billing",component:()=>e.jsx($,{children:e.jsx(er,{})})}),e.jsx(o,{path:"/admin/community-ops",component:()=>e.jsx($,{children:e.jsx(tr,{})})}),e.jsx(o,{path:"/admin/community-queue",component:()=>e.jsx($,{children:e.jsx(nr,{})})}),e.jsx(o,{path:"/admin/investors",component:()=>e.jsx($,{children:e.jsx(Fs,{})})}),e.jsx(o,{path:"/investors",component:Ds}),e.jsx(o,{path:"/investors/sign-in",component:Cs}),e.jsx(o,{path:"/investors/register",component:Ns}),e.jsx(o,{path:"/investors/updates",component:Vs}),e.jsx(o,{path:"/investors/materials",component:Ms}),e.jsx(o,{path:"/investors/materials/deck/:slug",component:Bs}),e.jsx(o,{path:"/affiliates",component:Us}),e.jsx(o,{path:"/affiliates/register",component:Gs}),e.jsx(o,{path:"/affiliates/deck",component:en}),e.jsx(o,{path:"/affiliates/deck/:slug",component:en}),e.jsx(o,{path:"/aime",component:()=>e.jsx($,{children:e.jsx(or,{})})}),e.jsx(o,{path:"/admin/imports",component:()=>e.jsx($,{children:e.jsx(rr,{})})}),e.jsx(o,{path:"/aurevoir",component:Ar}),e.jsx(o,{path:"/auth",component:Lr}),e.jsx(o,{path:"/verify-email",component:Dr}),e.jsx(o,{path:"/start",component:Cr}),e.jsx(o,{path:"/get-started",component:Wa}),e.jsx(o,{path:"/create-joggle",component:Ka}),e.jsx(o,{path:"/activate",component:wr}),e.jsx(o,{path:"/activate-code",component:za}),e.jsx(o,{path:"/go-pro",component:Br}),e.jsx(o,{path:"/subscribe",component:Vr}),e.jsx(o,{path:"/dashboard/found",component:hn}),e.jsx(o,{path:"/dashboard/found/*",component:hn}),e.jsx(o,{path:"/dashboard/trades",component:mn}),e.jsx(o,{path:"/dashboard/trades/*",component:mn}),e.jsx(o,{path:"/dashboard/yoga",component:pn}),e.jsx(o,{path:"/dashboard/yoga/*",component:pn}),e.jsx(o,{path:"/dashboard/sites/:siteId",component:Zt}),e.jsx(o,{path:"/dashboard/sites",component:Zt}),e.jsx(o,{path:"/dashboard",component:mt}),e.jsx(o,{path:"/dashboard-new",component:()=>(window.location.replace("/dashboard"),null)}),e.jsx(o,{path:"/dashboard/personal",children:()=>(window.location.replace("/me"),null)}),e.jsx(o,{path:"/go",component:ti}
21),e.jsx(o,{path:"/personal/dashboard",children:()=>(window.location.replace("/me"),null)}),e.jsx(o,{path:"/personal",component:dn}),e.jsx(o,{path:"/personal/original",component:oi}),e.jsx(o,{path:"/personal/signin",children:()=>(window.location.replace("/signin"),null)}),e.jsx(o,{path:"/personal/register",children:()=>(window.location.replace("/go"),null)}),e.jsx(o,{path:"/personal/onboarding",children:()=>(window.location.replace("/go"),null)}),e.jsx(o,{path:"/personal/pricing",component:ri}),e.jsx(o,{path:"/move-from-linktree",component:rn}),e.jsx(o,{path:"/personal/import",component:rn}),e.jsx(o,{path:"/space/:token",component:an}),e.jsx(o,{path:"/spaces/join/:token",component:an}),e.jsx(o,{path:"/personal/privacy",component:ai}),e.jsx(o,{path:"/personal/terms",component:ii}),e.jsx(o,{path:"/feedback",component:ci}),e.jsx(o,{path:"/meet",component:ws}),e.jsx(o,{path:"/admin/feedback/:id",component:()=>e.jsx($,{children:e.jsx(ui,{})})}),e.jsx(o,{path:"/admin/feedback",component:()=>e.jsx($,{children:e.jsx(li,{})})}),e.jsx(o,{path:"/document-intelligence",component:sr}),e.jsx(o,{path:"/tools/email-provider",component:Kr}),e.jsx(o,{path:"/email",component:sn}
21),e.jsx(o,{path:"/email/inbox",component:sn}),e.jsx(o,{path:"/upgrade",component:Mr}),e.jsx(o,{path:"/ai-customer-support-for-small-business",component:zr}),e.jsx(o,{path:"/ai-chatbot-for-small-business",component:Yr}),e.jsx(o,{path:"/automated-customer-enquiries",component:Qr}),e.jsx(o,{path:"/ai-customer-service-assistant",component:Xr}),e.jsx(o,{path:"/capture-customer-enquiries-automatically",component:Zr}),e.jsx(o,{path:"/ai-chatbot-for-pubs",component:ea}),e.jsx(o,{path:"/ai-chatbot-for-restaurants",component:ta}),e.jsx(o,{path:"/ai-chatbot-for-cafes",component:na}),e.jsx(o,{path:"/ai-chatbot-for-hotels",component:oa}),e.jsx(o,{path:"/ai-chatbot-for-gyms",component:sa}),e.jsx(o,{path:"/ai-chatbot-for-hairdressers",component:ra}),e.jsx(o,{path:"/ai-chatbot-for-tourism",component:aa}),e.jsx(o,{path:"/never-miss-a-booking-request",component:ia}),e.jsx(o,{path:"/automated-booking-enquiries",component:ca}),e.jsx(o,{path:"/case-study-we-three-loggerheads",component:la}),e.jsx(o,{path:"/how-a-pub-automated-customer-enquiries",component:ua}),e.jsx(o,{path:"/ai-chatbot-london",component:da}),e.jsx(o,{path:"/ai-chatbot-manchester",component:ma}),e.jsx(o,{path:"/ai-chatbot-wales",component:pa}),e.jsx(o,{path:"/found",component:fa}),e.jsx(o,{path:"/found/trades",component:_a}),e.jsx(o,{path:"/found/hospitality",component:Ea}),e.jsx(o,{path:"/found/local-services",component:va}),e.jsx(o,{path:"/found/mold",component:ya}),e.jsx(o,{path:"/found/start",component:Ta}),e.jsx(o,{path:"/found/welcome",component:Pa}),e.jsx(o,{path:"/found/how",component:ja}),e.jsx(o,{path:"/found/pricing",component:wa}),e.jsx(o,{path:"/found/score",component:ka}),e.jsx(o,{path:"/found/score/checking",component:Sa}),e.jsx(o,{path:"/found/r/:reportId",component:La}),e.jsx(o,{path:"/help",component:ba}),e.jsx(o,{path:"/about",component:xa}),e.jsx(o,{path:"/blog",component:ha}),e.jsx(o,{path:"/blog/:slug",component:ga}),e.jsx(o,{path:"/terms",component:Ra}),e.jsx(o,{path:"/privacy",component:Ia}),e.jsx(o,{path:"/cookies",component:Oa}),e.jsx(o,{path:"/careers",component:Da}),e.jsx(o,{path:"/shareholders",component:Ca}),e.jsx(o,{path:"/pub",component:pr}),e.jsx(o,{path:"/agents",component:hr}),e.jsx(o,{path:"/lite",component:gr}),e.jsx(o,{path:"/aidiscoverability",component:fr}),e.jsx(o,{path:"/jain",component:br}),e.jsx(o,{path:"/lite/register",component:_r}),e.jsx(o,{path:"/lite/success",component:Er}),e.jsx(o,{path:"/reserve",component:Tr}),e.jsx(o,{path:"/claim",component:yr}),e.jsx(o,{path:"/claim/:slug",component:vr}),e.jsx(o,{path:"/pubs",component:ut}),e.jsx(o,{path:"/restaurants",component:ut}),e.jsx(o,{path:"/salons",component:ut}),e.jsx(o,{path:"/sectors/:slug",component:Fr}),e.jsx(o,{path:"/assistant/:type",component:Sr}),e.jsx(o,{path:"/assistant/:assistantId/meeting-types",component:$r}),e.jsx(o,{path:"/assistant/:assistantId/calendar-connections",component:qr}),e.jsx(o,{path:"/assistant/:assistantId/connections",component:Jr}),e.jsx(o,{path:"/bookings/:assistantId",component:Ur}),e.jsx(o,{path:"/bookings/:assistantId/settings",component:Gr}),e.jsx(o,{path:"/bookings/:assistantId/booking-method",component:Hr}),e.jsx(o,{path:"/bookings/:assistantId/floor-plan-editor",component:on}),e.jsx(o,{path:"/bookings/:assistantId/layouts/:layoutId/editor",component:on}),e.jsx(o,{path:"/staff-portal",children:()=>e.jsx(Nt,{to:"/my-rota"})}),e.jsx(o,{path:"/staff-invite",component:Pr}),e.jsx(o,{path:"/my-rota",component:jr}),e.jsx(o,{path:"/rota-invite",component:kr}),(()=>{const d=new Set,p=[];return le.forEach(m=>{const h=m.code.split("-")[0];d.has(h)||(d.add(h),p.push(e.jsx(o,{path:`/${h}`,component:Ls},h)))}),p})(),e.jsx(o,{path:"/receptionist",component:Ws}),e.jsx(o,{path:"/owner/home",component:()=>(window.location.replace("/dashboard"),null)}),e.jsx(o,{path:"/owner/bookings",component:()=>n?e.jsx(Q,{}):t?(window.location.href="/dashboard",null):(window.location.href="/signin",null)}),e.jsx(o,{path:"/owner/signs",component:()=>n?e.jsx(Q,{}):t?(window.location.href="/dashboard",null):(window.location.href="/signin",null)}),e.jsx(o,{path:"/owner/menu",component:()=>n?e.jsx(Q,{}):t?(window.location.href="/dashboard",null):(window.location.href="/signin",null)}),e.jsx(o,{path:"/:username/signage/:token",component:Js}),e.jsx(o,{path:"/:username/events/:eventSlug",component:Hs}),e.jsx(o,{path:"/signin/customer",component:xi}),e.jsx(o,{path:"/auth/verify-customer/:token",component:Ti}),e.jsx(o,{path:"/auth/magic-login/:token",component:Pi}
21),e.jsx(o,{path:"/personal-dashboard",children:()=>{const d=window.location.search;return window.location.replace(`/me${d}`),null}}),e.jsx(o,{path:"/me",nest:!0,children:()=>{if(n)return e.jsx(Q,{});if(!t)return window.location.href="/personal",e.jsx(Q,{});if(t.accountTypes?.includes("personal")){const d=t.onboardingProgress;return d&&!d.complete&&!t.personalSlug?(window.location.href="/go",null):e.jsx(l.Suspense,{fallback:e.jsx(Q,{}),children:e.jsx(Ma,{})})}return e.jsx(l.Suspense,{fallback:e.jsx(Q,{}),children:e.jsxs(Ke,{children:[e.jsx(o,{path:"/messages/:jobId",component:gn}),e.jsx(o,{path:"/messages",component:gn}),e.jsx(o,{path:"/bookings/:bookingId/receipt",component:Si}),e.jsx(o,{path:"/bookings/:bookingId/proof",component:Li}),e.jsx(o,{path:"/bookings/:bookingId",component:ki}),e.jsx(o,{path:"/bookings",component:ji})]})})}}),e.jsx(o,{path:"/trades",component:bi}),e.jsx(o,{path:"/connect/claim/:token",component:Fa}),e.jsx(o,{path:"/booking/reschedule/:token",component:Za}),e.jsx(o,{path:"/booking/cancel/:token",component:ei}),e.jsx(o,{path:"/booking/:bookingToken",component:di}),e.jsx(o,{path:"/deposit/:token",component:pi}),e.jsx(o,{path:"/card-guarantee/:token",component:hi}),e.jsx(o,{path:"/widget/:venueSlug",component:mi}),e.jsx(o,{path:"/booking/room/:reference",component:gi}),e.jsx(o,{path:"/:slug/job/:jobToken",component:fi}),e.jsx(o,{path:"/:slug/pay/:invoiceToken",component:_i}),e.jsx(o,{path:"/:slug/project/:projectId",component:dt}),e.jsx(o,{path:"/:slug/booking/:meetingSlug",component:Ye}),e.jsx(o,{path:"/:slug/booking",component:Ye}),e.jsx(o,{path:"/contribute/:token",component:qs}),e.jsx(o,{path:"/:slug/gallery/collection/:collectionSlug",component:ke}),e.jsx(o,{path:"/:slug/gallery/g/:galleryId",component:ke}),e.jsx(o,{path:"/:slug/gallery/:gallerySlug/:mediaType/:mediaId",component:ke}),e.jsx(o,{path:"/:slug/gallery/:mediaType/:mediaId",component:ke}),e.jsx(o,{path:"/:slug/gallery/:gallerySlug",component:ke}),e.jsx(o,{path:"/:slug/gallery",component:ke}),e.jsx(o,{path:"/:slug/cv/chapters",component:Ha}),e.jsx(o,{path:"/:slug/cv/threads",component:$a}),e.jsx(o,{path:"/:slug/cv/spotlight",component:qa}),e.jsx(o,{path:"/:slug/film",component:Ja}),e.jsx(o,{path:"/:slug/cv/cinematic",children:d=>e.jsx(Nt,{to:`/${d.slug}/cv/spotlight`,replace:!0})}),e.jsx(o,{path:"/:slug/cv",component:Ga}),e.jsx(o,{path:"/:slug/kit",component:Ba}),e.jsx(o,{path:"/:slug/card",component:cn}),e.jsx(o,{path:"/:slug/e/:eventSlug",component:Ua}),e.jsx(o,{path:"/:slug/blog/:postSlug",component:un}),e.jsx(o,{path:"/:slug/blog",component:ln}),e.jsx(o,{path:"/:slug/book",component:Ei}),e.jsx(o,{path:"/:slug/my-bookings",component:vi}
21),e.jsx(o,{path:"/:username/yoga/my-classes/:token",component:wi}),e.jsx(o,{path:"/:username/yoga-book",component:yi}),e.jsx(o,{path:"/:username/yoga",children:({params:d})=>(window.location.replace(`/${d.username}`),null)}),e.jsx(o,{path:"/:username/:tool",component:$s}),e.jsx(o,{path:"/:username/events/:eventSlug",component:tn}),e.jsx(o,{path:"/:username",component:tn}),e.jsx(o,{component:Na})]})]})})}function Bi(){const[t,n]=l.useState(!1),[s,i]=l.useState(""),[c,u]=l.useState(!1);return l.useEffect(()=>void 0,[]),l.useEffect(()=>{Ln()},[]),l.useEffect(()=>{let d,p=0,m=0;const h=x=>{const{languageCode:k}=x.detail;i(k),n(!0),u(!0),p=0,m=0,d&&clearTimeout(d)},g=x=>{m++,d&&clearTimeout(d)},E=x=>{p++,d&&clearTimeout(d),p>=m&&m>0?(console.log("â
All translation batches complete, closing overlay"),n(!1)):d=setTimeout(()=>{console.log("â° Translation timeout reached, closing overlay"),n(!1)},2e3)},b=()=>{d&&clearTimeout(d),d=setTimeout(()=>{m===0&&(console.log("â
No translation batches needed, closing overlay"),n(!1))},1e3)};return window.addEventListener("languageChangeStart",h),window.addEventListener("languageChange",b),window.addEventListener("translationBatchStarted",g),window.addEventListener("translationBatchComplete",E),()=>{d&&clearTimeout(d),window.removeEventListener("languageChangeStart",h),window.removeEventListener("languageChange",b),window.removeEventListener("translationBatchStarted",g),window.removeEventListener("translationBatchComplete",E)}},[]),e.jsx(Qo,{children:e.jsx(Zo,{children:e.jsx(zn,{client:kt,children:e.jsxs(Qn,{children:[e.jsx(Xn,{}),(t||c)&&e.jsx(l.Suspense,{fallback:null,children:e.jsx(As,{isVisible:t,targetLanguage:s})}),e.jsx(Mi,{})]})})})})}const vt="".replace(/\s+/g,"");vt&&qn({dsn:vt,environment:"production",tracesSampleRate:.1});const Un=window.requestIdleCallback||(t=>setTimeout(t,0));Un(()=>{r(()=>Promise.resolve({}),__vite__mapDeps([288])).catch(()=>{})},{timeout:2e3});const Fi=t=>{try{return sessionStorage.getItem(t)}catch{return null}},Ui=(t,n)=>{try{sessionStorage.setItem(t,n)}catch{}};window.addEventListener("vite:preloadError",t=>{const n=Fi("vite_preload_reload"),s=Date.now();if(n&&s-parseInt(n)<1e4){console.warn("Vite preload error detected but skipping reload to prevent loop"),t.preventDefault();return}console.log("Vite preload error detected - refreshing page for latest assets"),Ui("vite_preload_reload",String(s)),window.location.reload()});const Gi=vt?Wn:({children:t})=>e.jsx(e.Fragment,{children:t});function ht(){Jn(document.getElementById("root")).render(e.jsx(Gi,{fallback:e.jsx("div",{style:{padding:"2rem",textAlign:"center"},children:"Something went wrong. Please refresh the page."}),children:e.jsx(Bi,{})}))}let Gn=null;try{Gn=Dn()}catch{}Nn(Gn)?(ht(),Un(()=>{_t()},{timeout:4e3})):_t().then(ht,ht);export{o as A,ds as B,ac as C,sc as D,ec as E,Es as G,Ue as J,Qi as L,Nt as R,le as S,r as _,nc as a,rc as b,Pt as c,Xo as d,zi as e,kn as f,us as g,Yi as h,Ao as i,No as j,ns as k,Ht as l,oc as m,Dn as n,$e as o,jt as p,kt as q,Sn as r,ts as s,is as t,xt as u,Rn as v,tc as w,Zi as x,Xi as y,Ke as z};
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.