PageSourceSearch

https://torahanytime.com/_next/static/chunks/app/(tati)/layout-4ba70a97ba19f3b5.js

js torahanytime.com collected 2026-10-01 10:35:51 UTC 48,886 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8770],{52367:function(e,t,n){Promise.resolve().then(n.bind(n,65934)),Promise.resolve().then(n.t.bind(n,88003,23)),Promise.resolve().then(n.bind(n,86827)),Promise.resolve().then(n.bind(n,67299)),Promise.resolve().then(n.bind(n,10775)),Promise.resolve().then(n.bind(n,84950)),Promise.resolve().then(n.bind(n,98284)),Promise.resolve().then(n.bind(n,45098)),Promise.resolve().then(n.bind(n,72183)),Promise.resolve().then(n.bind(n,65351)),Promise.resolve().then(n.t.bind(n,69268,23))},99376:function(e,t,n){"use strict";var i=n(35475);n.o(i,"notFound")&&n.d(t,{notFound:function(){return i.notFound}}),n.o(i,"useParams")&&n.d(t,{useParams:function(){return i.useParams}}),n.o(i,"usePathname")&&n.d(t,{usePathname:function(){return i.usePathname}}),n.o(i,"useRouter")&&n.d(t,{useRouter:function(){return i.useRouter}}),n.o(i,"useSearchParams")&&n.d(t,{useSearchParams:function(){return i.useSearchParams}}),n.o(i,"useSelectedLayoutSegments")&&n.d(t,{useSelectedLayoutSegments:function(){return i.useSelectedLayoutSegments}})},69003:function(e,t,n){"use strict";n.d(t,{P:function(){return a}});var i=n(57437),o=n(12421),s=n(90382),r=n(2265);const a=e=>{let{src:t,alt:n,width:a,height:l,fallbackSrc:c=o.D.images.GreyBox_png,className:u,isLectureImage:d,loading:h,unoptimized:p=!1,fill:f=!1,fillAspectClass:m="lg:aspect-[1/1]",onLoad:y}=e;t||(t=c);const x=!p&&a&&l&&!(e=>{const t=e.toLowerCase().split(/[?#]/)[0];return t.endsWith(".svg")||t.startsWith("data:image/svg+xml")})(t),g=x?(0,s.W)(t.startsWith("/")?"https://torahanytime.com".concat(t):t,{width:a,height:l}):t,[v,b]=(0,r.useState)(g);(0,r.useEffect)((()=>{b(g)}),[g]);const w=(u||"").split(" ").includes("static")?"":"absolute";return d?(0,i.jsx)("div",{className:"".concat(a?"w-[".concat(a,"px]"):"w-full"," overflow-hidden ").concat(d?"aspect-[16/9]":a?"aspect-[1/1] md:aspect-[16/9] lg:w-auto":"aspect-[16/9] lg:w-auto"),children:(0,i.jsx)("img",{src:v,alt:n,loading:h,className:"h-full w-full ".concat(w," ").concat(u||""),onLoad:y,onError:()=>{v!==c&&b(c)}})}):(0,i.jsx)("div",{className:"overflow-hidden ".concat(f&&!d?"relative ".concat(m):""),style:{width:(f?"100%":a)||"auto",height:(f?"100%":l)||"auto"},children:(0,i.jsx)("img",{src:v,alt:n,loading:h,className:"h-full w-full ".concat(w," ").concat(u||""),onLoad:y,onError:()=>{v!==c&&b(c)}})})}},95303:function(e,t,n){"use strict";n.r(t),n.d(t,{Modal:function(){return a}});var i=n(57437),o=n(9689),s=n(32768),r=n(91822);const a=e=>(0,i.jsxs)(o.Vq,{unmount:e.unmount,open:e.open,onClose:()=>{var t;null===(t=e.onClose)||void 0===t||t.call(e)},className:"fixed inset-0 z-[100] grid place-content-center backdrop-blur-[1px]",children:[(0,i.jsx)("div",{className:"fixed inset-0 bg-black opacity-10"}),(0,i.jsx)("div",{className:"relative z-10 m-2 max-w-[90vw] overflow-y-auto rounded-lg bg-white p-8 shadow-lg ".concat(e.showScrollbar?"max-md:scrollbar-hide":"scrollbar-hide"," ").concat(e.className),style:{width:"number"===typeof e.width?"".concat(e.width,"px"):"undefined"===typeof e.width?"320px":e.width},children:e.custom?e.children:(0,i.jsxs)(i.Fragment,{children:[!e.hideClose&&(0,i.jsx)("span",{className:"absolute right-6 ".concat((null===e||void 0===e?void 0:e.title)?"top-4":"top-2"),children:(0,i.jsx)(r.h,{"aria-label":"close",onClick:()=>{var t;return null===(t=e.onClose)||void 0===t?void 0:t.call(e)},children:(0,i.jsx)(s.IOM,{size:24,className:"text-grey-650"})})}),(0,i.jsx)("h4",{className:"text-subtitle-2 mb-2 text-grey-700",children:e.title}),(0,i.jsx)("div",{className:"text-button-sm leading-[24px] text-grey-650",children:e.children})]})})]})},10898:function(e,t,n){"use strict";n.d(t,{A:function(){return r}});var i=n(57437),o=n(2265),s=n(54887);const r=e=>{const[t,n]=(0,o.useState)(!1);return(0,o.useEffect)((()=>{n(!0)}),[]),t?s.createPortal((0,i.jsx)("div",{className:"overflow-hidden",children:(0,i.jsxs)("div",{"aria-hidden":!e.open,role:"alert",className:"fixed ".concat("top"==e.position?e.open?"top-2 [transition:opacity_1000ms_ease-out,top_500ms_ease-in]":"-top-[12%] opacity-0 [transition:opacity_500ms_ease-in,top_1000ms_ease-out]":e.open?"bottom-2 [transition:opacity_1000ms_ease-out,bottom_500ms_ease-in]":"-bottom-[12%] opacity-0 [transition:opacity_500ms_ease-in,bottom_1000ms_ease-out]","\n      text-body-2 left-[50%] flex w-[98vw] max-w-max\n      translate-x-[-50%] flex-row items-center gap-4 roun
1ded-md\n      bg-grey-800 p-4 text-grey-50 shadow-[0px_1px_2px_-1px_rgba(51,65,85,0.1),0px_1px_3px_rgba(51,65,85,0.1)]\n      "),children:[!!e.icon&&(0,i.jsx)("span",{className:"text-blue-400",children:e.icon}),e.message,e.button&&e.open&&(0,i.jsx)("button",{className:"pl-4 text-blue-400 ",onClick:e.button.action,children:e.button.text})]})}),document.body):(0,i.jsx)(i.Fragment,{})}},93507:function(e,t,n){"use strict";n.d(t,{y:function(){return l}});var i=n(57437),o=n(54916),s=n(52375),r=n(2265),a=n(32768);const l=e=>{let{labelClassName:t="bg-background-color",...n}=e;var s,a;const l=null!==(a=n.value)&&void 0!==a?a:n.defaultValue,u=void 0!==l&&null!==l&&""!==String(l),d=(0,r.useRef)(null),[h,p]=(0,r.useState)(u);(0,r.useEffect)((()=>{if(!d.current)return;const e=new MutationObserver((()=>{var e;const t=(null===(e=d.current)||void 0===e?void 0:e.value)||"";p(Boolean(t)),n.onChange(t)}));return e.observe(d.current,{attributes:!0,attributeFilter:["value"]}),()=>{e.disconnect()}}),[d.current,n.onChange]),(0,r.useEffect)((()=>{var e;p(u||Boolean(null===(e=d.current)||void 0===e?void 0:e.value))}),[u]);const f="\n    font-medium text-[14px] text-grey-500\n    peer-focus:text-primary-color-500 peer-disabled:text-grey-400\n    transition-transform ease-out\n    absolute left-4 top-1/2 -translate-y-1/2\n    peer-focus:-translate-y-8\n    peer-focus:text-[12px] peer-focus:z-[2]  peer-focus:h-[13px]\n    select-none\n    px-1\n    bg-grey-50\n    h-auto\n    ".concat(h||u||"date"===n.type||"datetime-local"===n.type?"-translate-y-8 z-[2] ".concat("yeshiva_anytime"===o.yM?"peer-focus:text-ya-blue":"peer-focus:text-primary-color-500"," text-[12px] h-[13px]"):"","\n    ").concat(n.invalid?"yeshiva_anytime"===o.yM?"peer-focus:text-ya-pink":"peer-focus:text-red-500 text-red-500":"","\n    ").concat(t,"\n  "),m=n.as||"input";var y,x;const g="input"===m?{label:n.label,rtl:n.rtl,invalid:(null===(s=n.invalid)||void 0===s?void 0:s.toString())||"false",value:null!==(x=null!==(y=n.value)&&void 0!==y?y:n.defaultValue)&&void 0!==x?x:""}:{};return"select"===n.as?(0,i.jsx)(c,{...n}):(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)("label",{className:"\n        relative block w-full\n        ".concat((n.helpText&&n.invalid,""),"\n        isolate\n        "),children:[(0,i.jsx)(m,{...g,ref:d,list:n.list?"input-list":void 0,id:n.id,placeholder:n.label?void 0:n.placeholder,type:n.type||"text",name:n.name,disabled:n.disabled,onChange:e=>{p(Boolean(e.target.value)),n.onChange(e.target.value)},onBlur:e=>{"date"!==n.type&&(p(Boolean(e.target.value)),n.onChange(e.target.value))},className:"\n          peer relative\n          z-[1]\n          h-12\n          w-full\n          rounded-md border border-grey-300 bg-transparent\n            px-4 outline outline-1\n          -outline-offset-1\n          disabled:cursor-not-allowed\n          disabled:border-grey-300\n          disabled:text-grey-400\n          ".concat(n.icon?"pr-10":"","\n          ").concat(n.invalid?"outline outline-2 -outline-offset-1 ".concat("yeshiva_anytime"===o.yM?"caret-ya-pink outline-ya-pink focus:caret-ya-pink focus:outline-ya-pink":"caret-red-500 outline-red-500 focus:caret-red-500 focus:outline-red-500"):"outline-1 outline-grey-300 focus:outline-2 ".concat("yeshiva_anytime"===o.yM?"caret-ya-blue outline-ya-blue focus:caret-ya-blue focus:outline-ya-blue":"focus:caret-primary-color-500 focus:outline-primary-color-500"),"\n          ").concat("textarea"===n.as?"h-[118px]":"","\n          ").concat(n.rtl?"text-left [direction:rtl]":"","\n          ").concat(n.className,"\n          ").concat("date"==n.type?"cursor-pointer":"","\n        ")}),n.label?(0,i.jsxs)("label",{className:"".concat(f),children:[n.label,n.required?(0,i.jsx)("span",{className:"text-red-500",children:"*"}):""]}):(0,i.jsx)(i.Fragment,{}),(0,i.jsx)("div",{className:"absolute right-4 top-1/2 z-10 -translate-y-1/2",children:n.icon}),n.invalid&&(0,i.jsx)("div",{className:"absolute ".concat("yeshiva_anytime"===o.yM?"text-ya-pink":"text-red-500"," p-1  text-left text-[12px] font-medium"),children:n.helpText})]})})},c=e=>(0,i.jsxs)("div",{children:[(0,i.jsx)(s.Ri,{value:e.value,onChange:e.onChange,children:t=>{let{open:n}=t;var r;return(0,i.jsxs)("div",{className:"text-body-1 relative",children:[(0,i.jsxs)(s.Y4,{className:"\n                text-body-2 flex\n                h-full\n                w-full\n                justify-between\n                whitespace-nowrap\n                rounded-md\n                p-3\n                text-[16px]\n                leading-[1.54rem]\n                text-grey-600\n                ".concat(e.invalid?"text-red-500  outline outline-2 -outline-offset-2 outline-red-500":n?"outline outline-2 -outline-offset-2 ".concat("yeshiva_anytime"===o.yM?"outline-ya-pink":"outline-primary-color-500"):"outline outline-1 -outline-offset-1 outline-grey-300 focus:outline-2 focus:-outline-offset-2 ".concat("yeshiva_anytime"===o.yM?"focus:outline-ya-pink":"focus:outline-primary-color-500"),"\n              "),children:[(0,i.jsx)("span",{className:"px-1",children:e.value||e.label+(e.required?"*":"")}),(0,i.jsx)(a.CgR,{size:18,className:"self-center ".concat(n?"rotate-180":""," transition-transform\n                ")})]}),(0,i.jsx)(s.O_,{className:"absolute top-full z-10 mt-2 w-full cursor-pointer rounded-md shadow-lg",children:null===(r=e.options)||void 0===r?void 0:r.map((e=>(0,i.jsx)(s.wt,{as:"div",className:e=>{let{focus:t,selected:n}=e;return"\n                  p-4\n                  ".concat(t||n?"yeshiva_anytime"===o.yM?"bg-primary-color-100 text-ya-pink":"bg-primary-color-50 text-primary-color-500":"bg-white","\n                  text-grey-800 first:rounded-t-md\n                  last:rounded-b-md\n                  ").concat("yeshiva_anytime"===o.yM?"hover:bg-primary-color-100 hover:text-ya-pink focus:bg-primary-color-100":"hover:bg-primary-color-50 hover:text-primary-color-500 focus:bg-primary-color-50","\n                  ")},value:e,children:e},e)))})]})}}
1),e.invalid&&(0,i.jsx)("div",{className:"-mt-[.5px] px-3 text-[12px] text-red-500",children:e.helpText})]})},91822:function(e,t,n){"use strict";n.d(t,{h:function(){return s}});var i=n(57437),o=n(54916);const s=e=>{const t=e.as||"button";return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(t,{onClick:()=>{var t;null===(t=e.onClick)||void 0===t||t.call(e)},className:"peer h-8 w-8 rounded-full lg:h-10 lg:w-10 ".concat("yeshiva_anytime"===o.yM?"hover:bg-grey-300/30 focus:bg-grey-300/30 active:bg-grey-300/30":"hover:bg-grey-100 focus:bg-grey-100 active:bg-grey-100"," grid place-content-center focus:outline-none ").concat(e.className),"aria-label":e["aria-label"]||"",children:e.children}),(0,i.jsx)("div",{className:"absolute -bottom-6 -left-2 hidden ".concat(e.title?"peer-hover:block peer-focus-visible:block":""," mt-1 w-max rounded-md bg-grey-500 px-2 py-[1px] text-[12px] text-white"),children:e.title})]})}},22011:function(e,t,n){"use strict";n.d(t,{h:function(){return s}});var i=n(57437),o=n(27648);const s=e=>{let{color:t="blue",...n}=e;var s="";return n.icon?(s+=" inline-flex gap-2 items-center","top"==n.iconPosition?s+=" flex-col":(s+="grey"==t?" px-3 py-[6px] rounded-md hover:bg-grey-100 focus:bg-grey-100":" px-2 py-[2px] rounded-full hover:bg-primary-color-100 focus:bg-primary-color-100","right"==n.iconPosition&&(s+=" flex-row-reverse"))):s+=" hover:underline focus:underline decoration-grey-300 underline-offset-2",(0,i.jsxs)(o.default,{href:n.href,download:n.download||!1,target:n.target,rel:"_blank"==n.target?"noreferrer":"",onClick:n.onClick,className:"text-subtitle-selected group inline-block cursor-pointer focus:outline-none\n      ".concat("grey"==t?"text-grey-800":"text-primary-color-500","\n      ").concat("sm"==n.size?"text-[12px]":"","\n      ").concat(s,"\n      ").concat(n.className,"\n      ").concat(n.disabled?" cursor-not-allowed opacity-[0.38]":""),children:[n.icon&&(0,i.jsx)("span",{className:"".concat("blue"==t?"text-[16px] text-grey-800":"text-xl text-grey-600"),children:n.icon}),n.children]})}},11769:function(e,t,n){"use strict";n.d(t,{q:function(){return r}});var i=n(27695),o=n(89134);n(2265);const s=(e,t)=>"function"===typeof t?t(e):t,r=(0,i.U)()((0,o.tJ)((e=>({lecture:void 0,isAllowPrerollAd:!0,currentPlaylistId:null,nextLectures:[],upNextContext:{name:"default",id:0,page:0},seriesId:void 0,seriesType:void 0,lectureStarted:!1,defaultPlayMode:"video",breadcrumbs:[],sidebarState:void 0,downloadList:[],allowSidebarOpen:!0,isTishaBavMode:!1,viewMode:"grid",lectureView:"grid",tawkMessengerRef:{current:null},isOnLecturePage:!1,isEmbeddedPlayer:!1,shouldRenderPlayerAsMini:!1,shouldShowPlayer:!1,overrideShowFemale:!1,setLecture:t=>e((e=>({lecture:s(e.lecture,t)}))),setIsAllowPrerollAd:t=>e((e=>({isAllowPrerollAd:s(e.isAllowPrerollAd,t)}))),setCurrentPlaylistId:t=>e((e=>({currentPlaylistId:s(e.currentPlaylistId,t)}))),setNextLectures:t=>e((e=>({nextLectures:s(e.nextLectures,t)}))),setUpNextContext:t=>e((e=>({upNextContext:s(e.upNextContext,t)}))),setSeriesId:t=>e((e=>({seriesId:s(e.seriesId,t)}))),setSeriesType:t=>e((e=>({seriesType:s(e.seriesType,t)}))),setLectureStarted:t=>e((e=>({lectureStarted:s(e.lectureStarted,t)}))),setDefaultPlayMode:t=>e((e=>({defaultPlayMode:s(e.defaultPlayMode,t)}))),setBreadcrumbs:t=>e((e=>({breadcrumbs:s(e.breadcrumbs,t)}))),setSidebarState:t=>e((e=>({sidebarState:s(e.sidebarState,t)}))),setDownloadList:t=>e((e=>({downloadList:s(e.downloadList,t)}))),setAllowSidebarOpen:t=>e((e=>({allowSidebarOpen:s(e.allowSidebarOpen,t)}))),setIsTishaBavMode:t=>e((e=>e.isTishaBavMode===t?e:{isTishaBavMode:t})),setViewMode:t=>e((e=>({viewMode:s(e.viewMode,t)}))),setLectureView:t=>e((e=>({lectureView:s(e.lectureView,t)}))),setDerivedState:t=>e((e=>({...e,...t})))})),{name:"default-content-type",partialize:e=>({defaultPlayMode:e.defaultPlayMode,viewMode:e.viewMode,lectureView:e.lectureView})}))},65351:function(e,t,n){"use strict";n.d(t,{TatiAppLayout:function(){return F}});var i=n(57437),o=n(2265),s=n(1298),r=n(56445),a=n(65934),l=n(99376),c=n(10898),u=n(3484);const d="tati-dollar-a-day-billing-email",h="dad-billing-email",p="info@torah
1anytime.com",f="TATi Dollar-a-Day access";function m(){sessionStorage.removeItem(d)}function y(e){const t=e.trim(),n=t.lastIndexOf("@");if(n<=0)return"****";const i=t.slice(0,n),o=i.length>4?i.slice(0,4):i.slice(0,1);return"".concat(o).concat(i.length>4?"****":"***").concat(t.slice(n))}function x(e){let{children:t}=e;const n=(0,l.usePathname)(),x=(0,l.useSearchParams)(),g=null===x||void 0===x?void 0:x.toString(),v=(0,u.t)((e=>e._hasHydrated)),b=(0,u.t)((e=>e.authToken)),w=(0,u.t)((e=>e.authStatus)),j=(0,u.t)((e=>e.user)),S=(0,u.t)((e=>e.setUser)),N=(0,u.t)((e=>e.logout)),k=(0,u.t)((e=>e.setSignInModalOpen)),[C,_]=(0,o.useState)(void 0),[O,P]=(0,o.useState)(null),[E,M]=(0,o.useState)(!1),[T,L]=(0,o.useState)(!1),[A,I]=(0,o.useState)(null),R=Boolean(j);(0,o.useEffect)((()=>{if(!v||"authenticated"!==w||!b||!R)return;let e=!1;return(0,s.bG)().then((t=>{var n;e||(200===t.status&&(null===(n=t.data)||void 0===n?void 0:n.id)?(S(t.data),I({authToken:b,status:"checked"})):I({authToken:b,status:"failed"}))})),()=>{e=!0}}),[w,b,v,S,R]),(0,o.useEffect)((()=>{const e=function(){const e=window.location.search.slice(1);if(!e)return null;let t;const n=e.split("&").filter((e=>{const n=e.indexOf("=");if((-1===n?e:e.slice(0,n))!==h)return!0;const i=-1===n?"":e.slice(n+1);return t=decodeURIComponent(i),!1}));if(void 0===t)return null;sessionStorage.setItem(d,t);const i="".concat(window.location.pathname).concat(n.length?"?".concat(n.join("&")):"").concat(window.location.hash);return window.history.replaceState(window.history.state,"",i),t}();if(null!==e)return _(e),void P(null);_((e=>void 0===e?sessionStorage.getItem(d):e))}),[n,g]),(0,o.useEffect)((()=>{null!=C&&!0===(null===j||void 0===j?void 0:j.is_dollar_a_day_subscriber)&&(m(),_(null))}),[C,null===j||void 0===j?void 0:j.is_dollar_a_day_subscriber]),(0,o.useEffect)((()=>{if(!T)return;const e=window.setTimeout((()=>L(!1)),5e3);return()=>window.clearTimeout(e)}),[T]);const D=v&&"authenticated"===w&&Boolean(j)&&!0!==(null===j||void 0===j?void 0:j.is_dollar_a_day_subscriber)&&null!=C,F=O&&null!=C&&j?function(e,t,n){const i=["Invited billing email: ".concat(e),"Authenticated TA account email: ".concat(t),"Failure category/code: ".concat(n)].join("\n");return"mailto:".concat(p,"?subject=").concat(encodeURIComponent(f),"&body=").concat(encodeURIComponent(i))}(C,j.email,O.code):"",U=(null===A||void 0===A?void 0:A.authToken)===b,z=v&&"authenticated"===w&&Boolean(b)&&!U,$=U&&"failed"===(null===A||void 0===A?void 0:A.status);return(0,i.jsxs)(i.Fragment,{children:[z?(0,i.jsx)("div",{className:"p-12 text-grey-500",children:"Checking access\u2026"}):$?(0,i.jsxs)("div",{className:"flex flex-col items-start gap-4 p-12 text-grey-600",children:[(0,i.jsx)("p",{role:"alert",children:"We couldn't verify your Dollar-a-Day access. Please try again."}),(0,i.jsx)("button",{type:"button",className:"rounded-md bg-primary-color-500 px-4 py-2 font-medium text-white hover:bg-primary-color-600",onClick:()=>window.location.reload(),children:"Try again"})]}):v&&"authenticated"===w&&j&&!0!==j.is_dollar_a_day_subscriber&&void 0===C?(0,i.jsx)("div",{className:"p-12 text-grey-500",children:"Checking access\u2026"}):D&&j&&void 0!==C?(0,i.jsx)("div",{className:"flex h-full items-center justify-center overflow-y-auto p-6",children:(0,i.jsxs)("section",{className:"w-full max-w-lg rounded-xl border border-grey-200 bg-white p-6 shadow-sm",children:[(0,i.jsx)("h1",{className:"text-2xl font-semibold text-grey-800",children:O?"We couldn\u2019t link this membership":"Link your Dollar-a-Day membership"}),O?(0,i.jsx)("p",{className:"mt-4 text-grey-650",role:"alert",children:O.message}):(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("p",{className:"mt-4 text-grey-650",children:"Confirm that this invitation belongs with your signed-in TorahAnytime account."}),(0,i.jsxs)("dl",{className:"mt-5 space-y-3 rounded-lg bg-grey-50 p-4 text-sm",children:[(0,i.jsxs)("div",{children:[(0,i.jsx)("dt",{className:"font-medium text-grey-700",children:"Invited billing email"}),(0,i.jsx)("dd",{className:"break-all text-grey-650",children:y(C)})]}),(0,i.jsxs)("div",{children:[(0,i.jsx)("dt",{className:"font-medium text-grey-700",children:"Signed-in TA account"}),(0,i.jsx)("dd",{className:"break-all text-grey-650",children:j.email})]})]})]}),(0,i.jsxs)("div",{className:"mt-6 flex flex-wrap gap-3",children:[!O&&(0,i.jsx)("button",{type:"button",disabled:E,className:"rounded-md bg-primary-color-500 px-4 py-2 font-medium text-white hover:bg-primary-color-600 disabled:opacity-50",onClick:async function(){if(null==C||!j)return;M(!0),P(null);const e=await(0,r.yP)("/dollar-a-day-subscriptions/claim",{billing_email:C}
1);if(e.error)return P({code:e.error.code||"request_failed",message:e.error.message||"We couldn't link the Dollar-a-Day membership for ".concat(y(C),". Please try again or contact support.")}),void M(!1);const t=Date.now()+1e4;for(;Date.now()<=t;){var n;const e=await(0,s.bG)();if(!0===(null===(n=e.data)||void 0===n?void 0:n.is_dollar_a_day_subscriber))return S(e.data),m(),_(null),M(!1),void L(!0);const i=t-Date.now();if(i<=0)break;await new Promise((e=>window.setTimeout(e,Math.min(1e3,i))))}P({code:"profile_refresh_failed",message:"Your membership was linked, but we couldn't refresh access for ".concat(y(C),". Please try again or contact support.")}),M(!1)},children:E?"Linking\u2026":"Link membership"}),(0,i.jsx)("button",{type:"button",disabled:E,className:"rounded-md border border-grey-300 px-4 py-2 font-medium text-grey-700 hover:bg-grey-50 disabled:opacity-50",onClick:async function(){M(!0);try{await(0,a.w7)({redirect:!1})}finally{await N(),M(!1),k(!0)}},children:"Switch account"}),O&&(0,i.jsx)("a",{href:F,className:"rounded-md border border-grey-300 px-4 py-2 font-medium text-primary-color-500 hover:bg-grey-50",children:"Email support"}),(0,i.jsx)("button",{type:"button",disabled:E,className:"px-3 py-2 font-medium text-grey-600 hover:text-grey-800 disabled:opacity-50",onClick:function(){m(),_(null),P(null)},children:"Dismiss"})]})]})}):t,(0,i.jsx)(c.A,{open:T,message:"Dollar-a-Day membership linked. TATi access is coming soon!"})]})}var g=n(54916),v=n(12421),b=n(39299),w=n(84772),j=n.n(w),S=n(27648),N=n(32768),k=n(85125),C=n(51315),_=n(61525),O=n(16129),P=n(69003);const E=[{href:"/",label:"Home",isActive:e=>"/"===e},{href:(0,b.dz)(v.V.recent.$url()),label:"Recent",isActive:e=>e===(0,b.dz)(v.V.recent.$url())},{href:(0,b.dz)(v.V.trending._page(1).$url()),label:"Trending",isActive:e=>e.startsWith("/trending/")},{href:(0,b.dz)(v.V.following.$url()),label:"Following",isActive:e=>e===(0,b.dz)(v.V.following.$url())}],M=e=>{let{sidebarOpen:t,sidebarCollapsed:n,onToggleSidebar:o}=e;var s;const r=null!==(s=(0,l.usePathname)())&&void 0!==s?s:"",a=(0,l.useSelectedLayoutSegments)(),c="tati"===(null===a||void 0===a?void 0:a[0])&&2===a.length,d=(0,u.t)((e=>e.authStatus)),h=(0,u.t)((e=>e.setSignInModalOpen)),p=(0,u.t)((e=>e.signInModalOpen));return(0,i.jsxs)("header",{className:"sticky top-0 z-50 w-full",children:[!c&&(0,i.jsxs)("div",{className:"flex h-16 w-full items-center gap-4 bg-[#FCFDFD] px-4 py-3 shadow-[0_1px_2px_rgba(51,65,85,0.08)] md:hidden",children:[(0,i.jsx)("button",{type:"button","aria-label":"Toggle sidebar","aria-controls":"tati-sidebar","aria-expanded":t,className:"flex h-6 w-6 shrink-0 items-center justify-center text-[#2E3A59]",onClick:o,children:(0,i.jsx)(N.lIk,{className:"h-6 w-6","aria-hidden":"true"})}),(0,i.jsx)("div",{className:"flex min-w-0 flex-1 justify-center",children:(0,i.jsx)(_.t,{className:"max-w-full"})}),(0,i.jsx)("div",{className:"h-6 w-6 shrink-0","aria-hidden":"true"})]}),(0,i.jsxs)("div",{className:"relative hidden h-[72px] w-full items-center justify-between gap-8 border-b border-grey-200 bg-white px-8 md:flex lg:gap-0",children:[(0,i.jsxs)("div",{className:"flex shrink-0 items-center gap-4 lg:hidden",children:[(0,i.jsx)("button",{type:"button","aria-label":"Toggle sidebar","aria-controls":"tati-sidebar","aria-expanded":t,className:"flex h-6 w-6 shrink-0 items-center justify-center text-[#2E3A59]",onClick:o,children:(0,i.jsx)(N.lIk,{className:"h-6 w-6","aria-hidden":"true"})}),(0,i.jsx)(S.default,{href:"/","aria-label":"TorahAnytime home",className:"flex shrink-0",children:(0,i.jsx)(P.P,{src:v.D.logos.Logo_svg,className:"static",width:49,height:40,alt:"TorahAnytime logo"})})]}),n&&(0,i.jsx)(S.default,{href:"/","aria-label":"TorahAnytime home",className:"absolute left-8 top-1/2 hidden shrink-0 -translate-y-1/2 lg:flex",children:(0,i.jsx)(P.P,{src:v.D.logos.Logo_svg,className:"static",width:49,height:40,alt:"TorahAnytime logo"})}),(0,i.jsx)("nav",{"aria-label":"Top Navigation",role:"navigation",className:"flex flex-1 items-center justify-center gap-4",children:E.map((e=>{const t=e.isActive(r);return(0,i.jsxs)(S.default,{href:e.href,className:j()("relative flex h-[46px] w-[82px] items-center justify-center text-center text-[14px] font-medium tracking-[0.5px] transition-colors",t?"text-primary-color-500":"text-grey-800"),children:[e.label,t&&(0,i.jsx)("span",{className:"absolute bottom-0 left-0 h-1 w-full rounded-t-full bg-primary-color-500"})]},e.label)}))}),(0,i.jsxs)("div",{className:"flex shrink-0 items-center gap-6",children:[(0,i.jsx)(k.T,{}),(0,i.jsx)(C.Button,{style:"secondary",isLink:!0,href:g.pO,className:"hidden lg:block",children:"Donate"}),"authenticated"===d?(0,i.jsx)(O.L,{}):(0,i.jsx)(C.Button,{onClick:()=>h(!p),className:"text-primary-color-500",children:"Sign in"})]})]})]})};var T=n(87310),L=n(29827),A=n(71632),I=n(46712);const R=/^\/tati(?:\/([^/?#]+))?/;const D=e=>{let{mobileOpen:t=!1,collapsed:n=!1,onMobileClose:s,onToggleCollapsed:r}=e;var a;const c=null!==(a=(0,l.usePathname)())&&void 0!==a?a:"",d=(0,l.useRouter)(),[h,p]=(0,o.useState)(!1),f=(0,L.useQueryClient)(),m=(0,u.t)((e=>e.authToken)),y=(0,u.t)((e=>{var t;return null===(t=e.user)||void 0===t?void 0:t.id})),x=(0,u.t)((e=>e.authStatus)),g=(0,u.t)((e=>{var t,n,i,o;return!0===(null===(n=e.user)||void 0===n||null===(t=n.role)||void 0===t?void 0:t.administrator)||!0===(null===(o=e.user)||void 0===o||null===(i=o.role)||void 0===i?void 0:i.tati_tester)})),b=function(e){const t=e.match(R);var n;return null!==(n=null===t||void 0===t?void 0:t[1])&&void 0!==n?n:null}(c),w=null===b,{data:k,isLoading:C}=(0,A.useQuery)({queryKey:T.TZ.tatiConversations(y||0),queryFn:()=>(0,I.Gl)(u.t.getState().authToken,{pageSize:50}
1),enabled:"authenticated"===x&&!!m&&!!y&&g});var _;const O=null!==(_=null===k||void 0===k?void 0:k.conversations)&&void 0!==_?_:[],E=n&&h,M=n&&!E,D=j()("inline-block overflow-hidden whitespace-nowrap transition-[max-width,opacity] duration-200 ease-out",M?"lg:max-w-0 lg:opacity-0":"max-w-[140px] opacity-100"),F="grid h-8 w-8 place-content-center rounded-full text-grey-700 hover:bg-grey-100 focus:bg-grey-100 active:bg-grey-100 focus:outline-none lg:h-10 lg:w-10";return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("button",{type:"button","aria-label":"Close sidebar",className:j()("fixed inset-0 z-[55] bg-black/20 transition-opacity lg:hidden",t?"opacity-100":"pointer-events-none opacity-0"),onClick:s}),(0,i.jsx)("div",{"aria-hidden":"true",className:j()("hidden h-screen shrink-0 transition-[width] duration-300 ease-out lg:block",n?"w-[72px]":"w-[225px]")}),(0,i.jsxs)("aside",{id:"tati-sidebar",className:j()("fixed left-0 top-0 z-[60] flex h-screen w-[225px] shrink-0 flex-col overflow-hidden border-r border-grey-200 bg-white px-3 py-6 transition-[transform,width] duration-300 ease-out lg:translate-x-0",t?"translate-x-0":"-translate-x-full",n?E?"lg:w-[225px]":"lg:w-[72px]":"lg:w-[225px]"),children:[(0,i.jsxs)("div",{className:"flex w-full flex-col gap-2",children:[(0,i.jsxs)("div",{className:j()("flex items-center gap-5 pl-2 pr-2 transition-all duration-300",M?"lg:justify-center lg:gap-0 lg:px-0":""),children:[(0,i.jsx)("button",{type:"button","aria-label":"Close sidebar","aria-controls":"tati-sidebar","aria-expanded":t,className:j()(F,"lg:hidden"),onClick:s,children:(0,i.jsx)(N.lIk,{className:"text-2xl text-grey-700"})}),(0,i.jsx)("button",{type:"button","aria-label":n?"Expand sidebar":"Collapse sidebar","aria-controls":"tati-sidebar","aria-expanded":!n,className:j()(F,"hidden lg:grid"),onClick:r,children:(0,i.jsx)(N.lIk,{className:"text-2xl text-grey-700"})}),(0,i.jsx)(S.default,{href:"/","aria-label":"Home",className:j()("shrink-0 overflow-hidden transition-[max-width,opacity] duration-200 ease-out",M?"lg:pointer-events-none lg:max-w-0 lg:opacity-0":"max-w-[97px] opacity-100"),children:(0,i.jsx)(P.P,{src:v.D.logos.Logo_svg,className:"static",width:49,height:40,alt:"TorahAnytime logo"})})]}),(0,i.jsx)("hr",{className:"border-t border-grey-200"})]}),(0,i.jsxs)("div",{className:"flex min-h-0 w-full flex-1 flex-col gap-2 overflow-y-auto overflow-x-hidden pt-6 scrollbar-hide",onMouseEnter:()=>p(!0),onMouseLeave:()=>p(!1),children:[(0,i.jsxs)("button",{type:"button",onClick:function(){d.push("/tati"),null===s||void 0===s||s()},className:function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return j()("flex h-10 w-full shrink-0 items-center gap-3 rounded-full px-4 py-2 text-left text-[14px] font-medium tracking-[0.5px] transition-all duration-300",M?"lg:justify-center lg:gap-0 lg:px-0":"",e?"bg-primary-color-50 text-primary-color-500 hover:bg-primary-color-100":"text-grey-700 hover:bg-grey-100")}(w),children:[(0,i.jsx)(N.uFR,{size:20,"aria-hidden":"true",className:"shrink-0"}),(0,i.jsx)("span",{className:D,children:"New Search"})]}),(0,i.jsxs)("button",{type:"button",disabled:!0,"aria-disabled":"true",title:"Coming soon",className:j()("flex h-10 w-full shrink-0 items-center gap-3 rounded-full px-4 py-2 text-left text-[14px] font-medium tracking-[0.5px] text-grey-700 opacity-60 transition-all duration-300",M?"lg:justify-center lg:gap-0 lg:px-0":""),children:[(0,i.jsx)(N.t7r,{size:20,"aria-hidden":"true",className:"shrink-0"}),(0,i.jsx)("span",{className:D,children:"Saved Searches"})]}),(0,i.jsxs)("div",{className:j()("flex shrink-0 flex-col overflow-hidden transition-[max-height,opacity] duration-300 ease-out",M?"lg:pointer-events-none lg:max-h-0 lg:opacity-0":"max-h-[2500px] opacity-100"),children:[(0,i.jsx)("div",{className:"px-4 pt-2 text-[12px] font-medium uppercase tracking-[0.5px] text-grey-500",children:"Recent Searches"}),(0,i.jsxs)("ul",{className:"mt-2 flex flex-col",children:[C&&(0,i.jsx)("li",{className:"px-4 py-2 text-[14px] text-grey-500",children:"Loading\u2026"}),!C&&0===O.length&&(0,i.jsx)("li",{className:"px-4 py-2 text-[14px] text-grey-500",children:"No searches yet."}),O.map((e=>{const t=e.title||e.query||"Untitled",n=e.id===b;return(0,i.jsx)("li",{className:"group",children:(0,i.jsxs)("div",{className:j()("flex h-10 items-center gap-3 rounded-full pl-4 pr-2",n?"bg-primary-color-50":"hover:bg-grey-100"),children:[(0,i.jsx)(N.uFR,{size:20,"aria-hidden":"true",className:n?"text-primary-color-500":"text-grey-700"}),(0,i.jsx)(S.default,{href:"/tati/".concat(e.id),title:t,onClick:s,className:j()("min-w-0 flex-1 truncate text-[14px] font-medium tracking-[0.5px]",n?"text-primary-color-500":"text-grey-700"),children:t}),(0,i.jsx)("button",{type:"button",onClick:()=>async function(e){m&&(await(0,I.SJ)(m,e),await f.invalidateQueries({queryKey:T.TZ.tatiConversations(y||0)}),e===b&&d.push("/tati"))}(e.id),"aria-label":"Delete conversation",className:"invisible flex h-6 w-6 shrink-0 items-center justify-center text-grey-400 hover:text-red-600 group-hover:visible",children:(0,i.jsx)(N.IOM,{size:16,"aria-hidden":"true"})})]})},e.id)}))]})]})]})]})]})};function F(e){let{children:t}=e;const[n,s]=(0,o.useState)(!1),[r,a]=(0,o.useState)(!1);return(0,i.jsxs)("div",{className:"isolate flex h-screen overflow-hidden",children:[(0,i.jsx)("a",{href:"#main-content",className:"sr-only z-50 rounded-md bg-primary-color-500 text-white focus:focus-visible:not-sr-only focu
1s:focus-visible:fixed focus:focus-visible:left-0 focus:focus-visible:top-0 focus:focus-visible:px-4 focus:focus-visible:py-2",children:"Skip to content"}),(0,i.jsx)(D,{mobileOpen:n,collapsed:r,onMobileClose:()=>s(!1),onToggleCollapsed:()=>a((e=>!e))}),(0,i.jsxs)("div",{className:"flex min-w-0 flex-1 flex-col",children:[(0,i.jsx)(M,{sidebarOpen:n,sidebarCollapsed:r,onToggleSidebar:()=>s((e=>!e))}),(0,i.jsx)("main",{id:"main-content",className:"min-h-0 flex-1 overflow-hidden bg-white lg:bg-grey-50",children:(0,i.jsx)(x,{children:t})})]})]})}},46712:function(e,t,n){"use strict";n.d(t,{Gl:function(){return a},Hx:function(){return o},SJ:function(){return l},Um:function(){return r},Ys:function(){return c},sn:function(){return u}});const i="https://tati-backend.torahanytime.com",o="".concat(i,"/api/website/chat");function s(e){return{Authorization:"Bearer ".concat(e),"Content-Type":"application/json"}}async function r(e,t,n){const o=await fetch("".concat(i,"/conversations/").concat(t),{headers:s(e),signal:n});if(404===o.status)return null;if(!o.ok)throw new Error("get_conversation_failed_".concat(o.status));return await o.json()}async function a(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;const o=new URL("".concat(i,"/conversations"));var r,a;o.searchParams.set("page",String(null!==(r=t.page)&&void 0!==r?r:1)),o.searchParams.set("pageSize",String(null!==(a=t.pageSize)&&void 0!==a?a:20)),t.search&&o.searchParams.set("search",t.search);const l=await fetch(o,{headers:s(e),signal:n});if(!l.ok)throw new Error("list_conversations_failed_".concat(l.status));return await l.json()}async function l(e,t){const n=await fetch("".concat(i,"/conversations/").concat(t),{method:"DELETE",headers:s(e)});if(!n.ok&&404!==n.status)throw new Error("delete_conversation_failed_".concat(n.status))}async function c(e,t,n){const o=await fetch("".concat(i,"/conversations/").concat(t,"/result-feedbacks"),{headers:s(e),signal:n});if(!o.ok)throw new Error("fetch_result_feedbacks_failed_".concat(o.status));return(await o.json()).resultFeedbacks}async function u(e,t){const n=await fetch("".concat(i,"/conversations/").concat(t.conversationId,"/result-feedbacks"),{method:"POST",headers:s(e),body:JSON.stringify({messageId:t.messageId,resultIndex:t.resultIndex,comment:t.comment})});if(!n.ok)throw new Error("save_result_feedback_failed_".concat(n.status));return await n.json()}},61815:function(e,t,n){"use strict";n.d(t,{_:function(){return i.Z},C7:function(){return o.Z},OH:function(){return s.Z}});n(16336);var i=n(51244),o=n(1917),s=n(71302);n(2265)},16336:function(e,t,n){"use strict";var i=n(2265);t.Z=(e,t)=>{const n=(0,i.useRef)(t);(0,i.useEffect)((()=>{n.current=t}),[t]),(0,i.useEffect)((()=>{const t=t=>{var i;const o=null===(i=document.activeElement)||void 0===i?void 0:i.tagName;"INPUT"!==o&&"TEXTAREA"!==o&&t.key===e&&n.current(t)};return document.addEventListener("keydown",t),()=>{document.removeEventListener("keydown",t)}}),[e])}},51244:function(e,t,n){"use strict";var i=n(2265);t.Z=function(e,t){const[n,o]=(0,i.useState)((()=>{try{const n=window.localStorage.getItem(e);return n?JSON.parse(n):t}catch(n){return console.error(n),t}}));return[n,t=>{try{const i=t instanceof Function?t(n):t;o(i),window.localStorage.setItem(e,JSON.stringify(i))}catch(i){console.error(i)}}]}},1917:function(e,t,n){"use strict";var i=n(2265);t.Z=function(){const[e,t]=(0,i.useState)(null);return(0,i.useEffect)((()=>{let n=window.pageYOffset;const i=()=>{const i=window.pageYOffset,o=i>n?"down":"up";o!==e&&(i-n>10||i-n<-10)&&t(o),n=i>0?i:0};return window.addEventListener("scroll",i),()=>{window.removeEventListener("scroll",i)}}),[e]),e}},71302:function(e,t,n){"use strict";var i=n(3484),o=n(11769),s=n(54916);t.Z=function(e){const t=(0,i.t)((e=>e.user)),n=(0,o.q)((e=>e.overrideShowFemale));return!e||(!!n||("jewish_anytime"===s.yM||!e.is_only_watchable_by_female&&!e.ladies||(null===t||void 0===t?void 0:t.is_female)||!1))}},77239:function(e,t,n){"use strict";n.d(t,{Z:function(){return r}});var i=n(2265);class o{constructor(){this.width=0,this.height=0,this.width=window.innerWidth,this.height=window.innerHeight}}const s=250;function r(){const e=i.useRef(),[t,n]=i.useState(new o);return i.useEffect((()=>{function t(){n(new o)}function i(){clearTimeout(e.current),e.current=setTimeout(t,s)}return window.addEventListener("resize",i),()=>{clearTimeout(e.current),window.removeEventListener("resize",i)}}),[]),t}},35219:function(e){e.exports={popUp:"PopUp_popUp__TfFb_",arrow:"PopUp_arrow__GctSc",popUpAlt:"PopUp_popUpAlt__eE0Tp"}}
1,2894:function(e,t,n){"use strict";n.d(t,{R:function(){return a},m:function(){return r}});var i=n(18238),o=n(7989),s=n(11255),r=class extends o.F{#e;#t;#n;#i;constructor(e){super(),this.#e=e.client,this.mutationId=e.mutationId,this.#n=e.mutationCache,this.#t=[],this.state=e.state||{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0},this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#t.includes(e)||(this.#t.push(e),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){this.#t=this.#t.filter((t=>t!==e)),this.scheduleGc(),this.#n.notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){this.#t.length||("pending"===this.state.status?this.scheduleGc():this.#n.remove(this))}continue(){return this.#i?.continue()??this.execute(this.state.variables)}async execute(e){const t=()=>{this.#o({type:"continue"})},n={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#i=(0,s.Mz)({fn:()=>this.options.mutationFn?this.options.mutationFn(e,n):Promise.reject(new Error("No mutationFn found")),onFail:(e,t)=>{this.#o({type:"failed",failureCount:e,error:t})},onPause:()=>{this.#o({type:"pause"})},onContinue:t,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#n.canRun(this)});const i="pending"===this.state.status,o=!this.#i.canStart();try{if(i)t();else{this.#o({type:"pending",variables:e,isPaused:o}),await(this.#n.config.onMutate?.(e,this,n));const t=await(this.options.onMutate?.(e,n));t!==this.state.context&&this.#o({type:"pending",context:t,variables:e,isPaused:o})}const s=await this.#i.start();return await(this.#n.config.onSuccess?.(s,e,this.state.context,this,n)),await(this.options.onSuccess?.(s,e,this.state.context,n)),await(this.#n.config.onSettled?.(s,null,this.state.variables,this.state.context,this,n)),await(this.options.onSettled?.(s,null,e,this.state.context,n)),this.#o({type:"success",data:s}),s}catch(r){try{throw await(this.#n.config.onError?.(r,e,this.state.context,this,n)),await(this.options.onError?.(r,e,this.state.context,n)),await(this.#n.config.onSettled?.(void 0,r,this.state.variables,this.state.context,this,n)),await(this.options.onSettled?.(void 0,r,e,this.state.context,n)),r}finally{this.#o({type:"error",error:r})}}finally{this.#n.runNext(this)}}#o(e){this.state=(t=>{switch(e.type){case"failed":return{...t,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...t,isPaused:!0};case"continue":return{...t,isPaused:!1};case"pending":return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}})(this.state),i.Vr.batch((()=>{this.#t.forEach((t=>{t.onMutationUpdate(e)})),this.#n.notify({mutation:this,type:"updated",action:e})}))}};function a(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}},21770:function(e,t,n){"use strict";n.d(t,{useMutation:function(){return u}});var i=n(2265),o=n(2894),s=n(18238),r=n(24112),a=n(45345),l=class extends r.l{#e;#s=void 0;#r;#a;constructor(e,t){super(),this.#e=e,this.setOptions(t),this.bindMethods(),this.#l()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){const t=this.options;this.options=this.#e.defaultMutationOptions(e),(0,a.VS)(this.options,t)||this.#e.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#r,observer:this}),t?.mutationKey&&this.options.mutationKey&&(0,a.Ym)(t.mutationKey)!==(0,a.Ym)(this.options.mutationKey)?this.reset():"pending"===this.#r?.state.status&&this.#r.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#r?.removeObserver(this)}onMutationUpdate(e){this.#l(),this.#c(e)}getCurrentResult(){return this.#s}reset(){this.#r?.removeObserver(this),this.#r=void 0,this.#l(),this.#c()}mutate(e,t){return this.#a=t,this.#r?.removeObserver(this),this.#r=this.#e.getMutationCache().build(this.#e,this.options),this.#r.addObserver(this),this.#r.execute(e)}#l(){const e=this.#r?.state??(0,o.R)();this.#s={...e,isPending:"pending"===e.status,isSuccess:"success"===e.status,isError:"error"===e.status,isIdle:"idle"===e.status,mutate:this.mutate,reset:this.reset}}#c(e){s.Vr.batch((()=>
1{if(this.#a&&this.hasListeners()){const t=this.#s.variables,n=this.#s.context,i={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};"success"===e?.type?(this.#a.onSuccess?.(e.data,t,n,i),this.#a.onSettled?.(e.data,null,t,n,i)):"error"===e?.type&&(this.#a.onError?.(e.error,t,n,i),this.#a.onSettled?.(void 0,e.error,t,n,i))}this.listeners.forEach((e=>{e(this.#s)}))}))}},c=n(29827);function u(e,t){const n=(0,c.useQueryClient)(t),[o]=i.useState((()=>new l(n,e)));i.useEffect((()=>{o.setOptions(e)}),[o,e]);const r=i.useSyncExternalStore(i.useCallback((e=>o.subscribe(s.Vr.batchCalls(e))),[o]),(()=>o.getCurrentResult()),(()=>o.getCurrentResult())),u=i.useCallback(((e,t)=>{o.mutate(e,t).catch(a.ZT)}),[o]);if(r.error&&(0,a.L3)(o.options.throwOnError,[r.error]))throw r.error;return{...r,mutate:u,mutateAsync:r.mutate}}},89087:function(e,t,n){"use strict";n.d(t,{fP:function(){return j}});var i=function(e,t){if("string"!==typeof e)throw new TypeError("argument str must be a string");var n={},i=(t||{}).decode||a,o=0;for(;o<e.length;){var s=e.indexOf("=",o);if(-1===s)break;var r=e.indexOf(";",o);if(-1===r)r=e.length;else if(r<s){o=e.lastIndexOf(";",s-1)+1;continue}var l=e.slice(o,s).trim();if(void 0===n[l]){var u=e.slice(s+1,r).trim();34===u.charCodeAt(0)&&(u=u.slice(1,-1)),n[l]=c(u,i)}o=r+1}return n},o=function(e,t,n){var i=n||{},o=i.encode||l;if("function"!==typeof o)throw new TypeError("option encode is invalid");if(!r.test(e))throw new TypeError("argument name is invalid");var a=o(t);if(a&&!r.test(a))throw new TypeError("argument val is invalid");var c=e+"="+a;if(null!=i.maxAge){var u=i.maxAge-0;if(isNaN(u)||!isFinite(u))throw new TypeError("option maxAge is invalid");c+="; Max-Age="+Math.floor(u)}if(i.domain){if(!r.test(i.domain))throw new TypeError("option domain is invalid");c+="; Domain="+i.domain}if(i.path){if(!r.test(i.path))throw new TypeError("option path is invalid");c+="; Path="+i.path}if(i.expires){var d=i.expires;if(!function(e){return"[object Date]"===s.call(e)||e instanceof Date}(d)||isNaN(d.valueOf()))throw new TypeError("option expires is invali
1d");c+="; Expires="+d.toUTCString()}i.httpOnly&&(c+="; HttpOnly");i.secure&&(c+="; Secure");i.partitioned&&(c+="; Partitioned");if(i.priority){switch("string"===typeof i.priority?i.priority.toLowerCase():i.priority){case"low":c+="; Priority=Low";break;case"medium":c+="; Priority=Medium";break;case"high":c+="; Priority=High";break;default:throw new TypeError("option priority is invalid")}}if(i.sameSite){switch("string"===typeof i.sameSite?i.sameSite.toLowerCase():i.sameSite){case!0:c+="; SameSite=Strict";break;case"lax":c+="; SameSite=Lax";break;case"strict":c+="; SameSite=Strict";break;case"none":c+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}}return c},s=Object.prototype.toString,r=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/;function a(e){return-1!==e.indexOf("%")?decodeURIComponent(e):e}function l(e){return encodeURIComponent(e)}function c(e,t){try{return t(e)}catch(n){return e}}function u(e,t={}){const n=function(e){if(e&&"j"===e[0]&&":"===e[1])return e.substr(2);return e}(e);if(!t.doNotParse)try{return JSON.parse(n)}catch(i){}return e}class d{constructor(e,t={}){this.changeListeners=[],this.HAS_DOCUMENT_COOKIE=!1,this.update=()=>{if(!this.HAS_DOCUMENT_COOKIE)return;const e=this.cookies;this.cookies=i(document.cookie),this._checkChanges(e)};const n="undefined"===typeof document?"":document.cookie;this.cookies=function(e){return"string"===typeof e?i(e):"object"===typeof e&&null!==e?e:{}}(e||n),this.defaultSetOptions=t,this.HAS_DOCUMENT_COOKIE=function(){const e="undefined"===typeof global?void 0:global.TEST_HAS_DOCUMENT_COOKIE;return"boolean"===typeof e?e:"object"===typeof document&&"string"===typeof document.cookie}()}_emitChange(e){for(let t=0;t<this.changeListeners.length;++t)this.changeListeners[t](e)}_checkChanges(e){new Set(Object.keys(e).concat(Object.keys(this.cookies))).forEach((t=>{e[t]!==this.cookies[t]&&this._emitChange({name:t,value:u(this.cookies[t])})}))}_startPolling(){this.pollingInterval=setInterval(this.update,300)}_stopPolling(){this.pollingInterval&&clearInterval(this.pollingInterval)}get(e,t={}){return t.doNotUpdate||this.update(),u(this.cookies[e],t)}getAll(e={}){e.doNotUpdate||this.update();const t={};for(let n in this.cookies)t[n]=u(this.cookies[n],e);return t}set(e,t,n){n=n?Object.assign(Object.assign({},this.defaultSetOptions),n):this.defaultSetOptions;const i="string"===typeof t?t:JSON.stringify(t);this.cookies=Object.assign(Object.assign({},this.cookies),{[e]:i}),this.HAS_DOCUMENT_COOKIE&&(document.cookie=o(e,i,n)),this._emitChange({name:e,value:t,options:n})}remove(e,t){const n=t=Object.assign(Object.assign(Object.assign({},this.defaultSetOptions),t),{expires:new Date(1970,1,1,0,0,1),maxAge:0});this.cookies=Object.assign({},this.cookies),delete this.cookies[e],this.HAS_DOCUMENT_COOKIE&&(document.cookie=o(e,"",n)),this._emitChange({name:e,value:void 0,options:t})}addChangeListener(e){this.changeListeners.push(e),this.HAS_DOCUMENT_COOKIE&&1===this.changeListeners.length&&("object"===typeof window&&"cookieStore"in window?window.cookieStore.addEventListener("change",this.update):this._startPolling())}removeChangeListener(e){const t=this.changeListeners.indexOf(e);t>=0&&this.changeListeners.splice(t,1),this.HAS_DOCUMENT_COOKIE&&0===this.changeListeners.length&&("object"===typeof window&&"cookieStore"in window?window.cookieStore.removeEventListener("change",this.update):this._stopPolling())}}var h=n(2265);const p=h.createContext(new d),{Provider:f,Consumer:m}=p;h.Component;"function"===typeof SuppressedError&&SuppressedError;var y,x={exports:{}},g={};x.exports=function(){if(y)return g;y=1;var e="function"===typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,i=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,s=e?Symbol.for("react.profiler"):60114,r=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,h=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,f=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,x=e?Symbol.for("react.fundamental"):60117,v=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function w(e){if("object"===typeof e&&null!==e){var h=e.$$typeof;switch(h){case t:switch(e=e.type){case l:case c:case i:case s:case o:case d:return e;default:switch(e=e&&e.$$typeof){case a:case u:case f:case p:case r:return e;default:return h}}case n:return h}}}function j(e){return w(e)===c}return g.AsyncMode=l,g.ConcurrentMode=c,g.ContextConsumer=a,g.ContextProvider=r,g.Element=t,g.ForwardRef=u,g.Fragment=i,g.Lazy=f,g.Memo=p,g.Portal=n,g.Profiler=s,g.StrictMode=o,g.Suspense=
1d,g.isAsyncMode=function(e){return j(e)||w(e)===l},g.isConcurrentMode=j,g.isContextConsumer=function(e){return w(e)===a},g.isContextProvider=function(e){return w(e)===r},g.isElement=function(e){return"object"===typeof e&&null!==e&&e.$$typeof===t},g.isForwardRef=function(e){return w(e)===u},g.isFragment=function(e){return w(e)===i},g.isLazy=function(e){return w(e)===f},g.isMemo=function(e){return w(e)===p},g.isPortal=function(e){return w(e)===n},g.isProfiler=function(e){return w(e)===s},g.isStrictMode=function(e){return w(e)===o},g.isSuspense=function(e){return w(e)===d},g.isValidElementType=function(e){return"string"===typeof e||"function"===typeof e||e===i||e===c||e===s||e===o||e===d||e===h||"object"===typeof e&&null!==e&&(e.$$typeof===f||e.$$typeof===p||e.$$typeof===r||e.$$typeof===a||e.$$typeof===u||e.$$typeof===x||e.$$typeof===v||e.$$typeof===b||e.$$typeof===m)},g.typeOf=w,g}();var v=x.exports,b={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},w={};w[v.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},w[v.Memo]=b;Object.defineProperty,Object.getOwnPropertyNames,Object.getOwnPropertySymbols,Object.getOwnPropertyDescriptor,Object.getPrototypeOf,Object.prototype;function j(e){const t=(0,h.useContext)(p);if(!t)throw new Error("Missing <CookiesProvider>");const[n,i]=(0,h.useState)((()=>t.getAll({doNotUpdate:!0})));"undefined"!==typeof window&&"undefined"!==typeof window.document&&"undefined"!==typeof window.document.createElement&&(0,h.useLayoutEffect)((()=>{function o(){const o=t.getAll({doNotUpdate:!0});(function(e,t,n){if(!e)return!0;for(let i of e)if(t[i]!==n[i])return!0;return!1})(e||null,o,n)&&i(o)}return t.addChangeListener(o),()=>{t.removeChangeListener(o)}}),[t,n]);const o=(0,h.useMemo)((()=>t.set.bind(t)),[t]),s=(0,h.useMemo)((()=>t.remove.bind(t)),[t]),r=(0,h.useMemo)((()=>t.update.bind(t)),[t]);return[n,o,s,r]}}},function(e){e.O(0,[1710,7825,1716,8998,5706,7142,4705,6716,6971,5406,4043,2972,3249,3188,7466,3524,9689,2953,2375,7865,1632,1698,534,7864,3182,2421,8090,8633,2674,3e3,2971,2117,1744],(function(){return t=52367,e(e.s=t);var t}));var t=e.O();_N_E=t}]);

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.