1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,482820,(e,t,n)=>{var r=e.r(333141);t.exports=function(e,t,n){var o=null==e?void 0:r(e,t);return void 0===o?n:o}},66397,(e,t,n)=>{var r=/^(?:0|[1-9]\d*)$/;t.exports=function(e,t){var n=typeof e;return!!(t=null==t?0x1fffffffffffff:t)&&("number"==n||"symbol"!=n&&r.test(e))&&e>-1&&e%1==0&&e<t}},556621,168331,e=>{"use strict";var t=e.i(247167);let n=(e,t)=>!t?.isRenderer||!t?.pathname||t?.pathname!=="/"||e?.endsWith(".svg")?e:e?`https://res.cloudinary.com/thechurchcov3production/image/fetch/f_auto/${e}`:e;e.s(["withCloudinary",0,n],168331),e.s(["mediaPath",0,(e,r="s3",o=null,i=null)=>{if(!e||"string"!=typeof e)return;if(/^https?:\/\//.test(e))return"image"===o?n(e,i):e;let a="https://media.thechurchcoassets.com";return("wasabi"===r&&(a=t.default.env.NEXT_PUBLIC_WASABI_DOMAIN),"image"===o)?n(`${a}/${e}`,i):`${a}/${e}`}],556621)},524251,(e,t,n)=>{var r=e.r(841920);t.exports=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}()},674548,(e,t,n)=>{var r=e.r(524251);t.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},4300,(e,t,n)=>{var r=e.r(674548),o=e.r(25172),i=Object.prototype.hasOwnProperty;t.exports=function(e,t,n){var a=e[t];i.call(e,t)&&o(a,n)&&(void 0!==n||t in e)||r(e,t,n)}},942173,(e,t,n)=>{var r=e.r(4300),o=e.r(186287),i=e.r(66397),a=e.r(12447),l=e.r(2054);t.exports=function(e,t,n,s){if(!a(e))return e;t=o(t,e);for(var u=-1,c=t.length,d=c-1,f=e;null!=f&&++u<c;){var m=l(t[u]),g=n;if("__proto__"===m||"constructor"===m||"prototype"===m)break;if(u!=d){var p=f[m];void 0===(g=s?s(p,m,f):void 0)&&(g=a(p)?p:i(t[u+1])?[]:{})}r(f,m,g),f=f[m]}return e}},348707,(e,t,n)=>{var r=e.r(942173);t.exports=function(e,t,n){return null==e?e:r(e,t,n)}},110333,e=>{"use strict";var t=e.i(843476),n=e.i(988842);e.s(["AdminImg",0,({image:e,align:r,style:o,"data-rich-width":i,...a})=>{let l=!!e?.width?.value,s=(()=>{let t={...l?{}:o,...a?.styles};if(l){let n=e?.width?.unit?e.width.unit:"px";t.width=`${e.width.value}${n}`}return t})();return l?(0,t.jsx)("div",{"data-image-wrap":!0,"data-rich-width":i,style:o,className:(0,n.classNames)("flex",r?({start:"justify-start!",center:"justify-center!",end:"justify-end!"})[r]:""),children:(0,t.jsx)("img",{...a,style:s})}):(0,t.jsx)("img",{...a,"data-rich-width":i,style:s})}])},18429,3705,e=>{"use strict";var t=e.i(843476),n=e.i(271645),r=e.i(488691);e.i(3303);var o=e.i(659549),i=e.i(462396);let a=({event:e,args:t,send_to:n})=>{if((0,i.hasConsentChoice)()&&!(0,i.hasConsent)("analytics"))return;let r={...t,send_to:n};(0,o.fireWhenReady)(()=>"function"==typeof window.gtag,()=>window.gtag("event",e,r))};e.s(["googleAnalyticsTrackEvent",0,a,"googleGrantConsent",0,(e="approve",t=null)=>{var n;let r,o=window.gtag;if(!o)return;let i="approve"===e;o("consent","update",(n="custom"===e&&t?t:{functional:i,analytics:i,performance:i,advertisement:i},{ad_storage:(r=e=>e?"granted":"denied")(n.advertisement),ad_user_data:r(n.advertisement),ad_personalization:r(n.advertisement),analytics_storage:r(n.analytics),functionality_storage:r(n.functional),personalization_storage:r(n.functional),security_storage:"granted"}))}],3705);let l=(0,n.createContext)({trackEvent:e=>console.log(e,"Fake Context")});e.s(["IntegrationsContext",0,l,"IntegrationsContextProvider",0,({children:e,me:r,network:s})=>{let u=(0,n.useCallback)((e,t)=>{a({event:e,args:t?.google?t.google:t,network:s,send_to:["globaltracking","customer"]}),(({event:e,args:t,network:n})=>{(!(0,i.hasConsentChoice)()||(0,i.hasConsent)("advertisement"))&&(0,o.fireWhenReady)(()=>!0===window.CHURCHFBPIXELENABLED&&"function"==typeof window.fbq,()=>window.fbq("trackCustom",e,t))})({event:e,args:t?.facebook?t.facebook:t,network:s}),(({event:e,args:t={},network:n})=>{(!(0,i.hasConsentChoice)()||(0,i.hasConsent)("advertisement"))&&(0,o.fireWhenReady)(()=>!0===window.CHURCHOPENAIPIXEL&&"function"==typeof window.oaiq,()=>window.oaiq("measure","custom",{type:"custom",...t},{custom_event_name:e}))})({event:e,args:t?.openai?t.openai:t,network:s})},[s]),c=(0,n.useMemo)(()=>({me:r,network:s,trackEvent:u}),[r,s,u]);return(0,t.jsx)(l.Provider,{"data-analytics-provider":!0,value:c,children:e})},"useIntegrationsContext",0,()=>{let e=(0,n.useContext)(l),t=(0,r.useGlobalContext)();return(0,n.useMemo)(()=>({session:t.session,network:t.network,brand:t.accountSettings?.brand,smarttext:t.smarttext,pathname:t.pathname,searchParams:t.searchParams,person:t.person,nativeAppVersion:t.nativeAppVersion,isRenderer:t.isRenderer,...e}),[t,e])}],18429)},175658,e=>{"use strict";var t=e.i(152480);let n=async(e,n,r,o)=>{try{let i=[];n?.page&&i.push(`page=${n?.page}`),n?.limit&&i.push(`limit=${n?.limit}`),n?.view&&n?.view!=="all"&&i.push(`view=${n?.view}`),n?.search&&i.push(`search=${n?.search}`),n?.args&&Object.keys(n?.args).map(e=>i.push(`${e}=${n?.args[e]}`));let a=i.join("&"),l=await (0,t.APIGet)(`${t.APIBase}${e}?${a}`,null,r||null,o.token);return await l.json()}catch(e){(0,t.APIErrorHandler)(e)}},r=async(e,n,r,o)=>{try{let i=await (0,t.APIPost)(`${t.APIBase}${e}`,n,r,o.token);return await i.json()}catch(e){(0,t.APIErrorHandler)(e)}},o=async(e,n,r=null,o,i={})=>{let a=Object.keys(i).map(e=>`${e}=${i[e]}`).join("&"),l=`${t.APIBase}${e}/insert?${a}`;try{let e=await (0,t.APIPost)(l,n,r,o.token);return await e.json()}catch(e){(0,t.APIErrorHandler)(e)}},i=async(e,n,r=null,o)=>{let i=`${t.APIBase}${e}/import`;n?.isV1Data===!0&&(i+="/v1");try{let e=await (0,t.APIPost)(i,n,r,o.token);return await e.json()}catch(e){(0,t.APIErrorHandler)(e)}},a=async(e,n,r,o,i)=>{try{let a=await (0,t.APIPut)(`${t.APIBase}${e}/${n}`,r,o,i.token);return await a.json()}catch(e){(0,t.APIErrorHandler)(e)}},l=async(e,n,r,o)=>{try{let i=await (0,t.APIGet)(`${t.APIBase}${e}/${n}`,null,r||null,o.token);return await i.json()}catch(e){(0,t.APIErrorHandler)(e)}},s=async(e,n,r=null,o)=>{try{let i=await (0,t.APIGet)(`${t.APIBase}${e}/slug/${n}`,null,r,o.token);if(404===i.status)return{status:i.status,message:i.statusText};return await i.json()}catch(e){(0,t.APIErrorHandler)(e)}},u=async(e,n,r,o)=>{try{let i=await (0,t.APIPost)(`${t.APIBase}${e}/${n}/duplicate`,{},r,o.token);return await i.json()}catch(e){(0,t.APIErrorHandler)(e)}},c=async(e,n,r,o)=>{try{let i=await (0,t.APIDelete)(`${t.APIBase}${e}/${n}`,r,o.token);return await i.json()}catch(e){(0,t.APIErrorHandler)(e)}},d=async(e,n,r=null,o)=>{try{let i=await (0,t.APIPost)(`${t.APIBase}${e}/${n}/restore`,{},r,o.token);return await i.json()}catch(e){(0,t.APIErrorHandler)(e)}},f=async(e,n,r=null,o)=>{try{let i=await (0,t.APIGet)(`${t.APIBase}${e}/${n}/revisions`,{},r,o.token);return await i.json()}catch(e){(0,t.APIErrorHandler)(e)}},m=async(e,n,r,o,i=null,a,l="terms")=>{try{let s=await (0,t.APIPost)(`${t.APIBase}${e}/tag/replace`,{modelType:r,modelId:o,[l]:n},i,a.token);return await s.json()}catch(e){(0,t.APIErrorHandler)(e)}},g=async(e,n,r,o,i=null,a,l="terms")=>{try{let s=await (0,t.APIPost)(`${t.APIBase}${e}/tag`,{modelType:r,modelId:o,[l]:n},i,a.token);return await s.json()}catch(e){(0,t.APIErrorHandler)(e)}},p=async(e,n,r,o)=>{try{let i=await (0,t.APIDelete)(`${t.APIBase}${e}/${n}/force`,r,o.token);return await i.json()}catch(e){(0,t.APIErrorHandler)(e)}};e.s(["addTags",0,g,"createModel",0,r,"deleteModel",0,c,"duplicateModel",0,u,"forceDeleteModel",0,p,"getModel",0,l,"getModelBySlug",0,s,"getRevisions",0,f,"importModel",0,i,"insertModel",0,o,"replaceTags",0,m,"restoreModel",0,d,"searchModels",0,n,"updateModel",0,a]
1)},484875,e=>{"use strict";var t=e.i(843476);e.s(["TCCSilasIcon",0,({className:e="",...n})=>(0,t.jsx)("svg",{viewBox:"0 0 657.53 210.46",xmlns:"http://www.w3.org/2000/svg",className:`inline align-[-0.035em] ${e}`,role:"img","aria-label":"Silas",height:"1em",...n,children:(0,t.jsxs)("g",{fill:"currentColor",children:[(0,t.jsx)("path",{d:"M657.53,37.11v.02c0,.41-.29.76-.69.85-13.81,3.04-24.67,13.92-27.7,27.73-.09.4-.44.69-.85.69h0c-.41,0-.76-.29-.85-.69-3.02-13.79-13.86-24.66-27.64-27.72-.4-.09-.68-.44-.68-.85v-.04c0-.41.29-.76.69-.85,13.73-3.05,24.54-13.85,27.61-27.57.09-.4.44-.68.84-.68h.07c.41,0,.76.29.85.69.14.64.3,1.27.48,1.89,3.43,12.2,13.06,21.81,25.28,25.21.14.04.28.08.43.12.11.03.22.06.34.09.38.1.76.19,1.15.27s.68.44.68.84Z"}),(0,t.jsx)("path",{d:"M67.66,210.46c-20.86,0-37.17-4.33-48.94-12.97C6.95,188.84.71,176.76,0,161.25h37.97c.71,4.64,3.52,8.79,8.42,12.44,4.9,3.66,12.26,5.48,22.06,5.48,7.49,0,13.68-1.29,18.58-3.88,4.9-2.58,7.35-6.28,7.35-11.09,0-4.28-1.92-7.71-5.75-10.3-3.84-2.58-10.47-4.32-19.92-5.21l-11.5-1.34c-17.65-1.78-30.88-6.64-39.71-14.58-8.82-7.93-13.24-18.22-13.24-30.88,0-10.34,2.58-18.99,7.76-25.94,5.17-6.96,12.34-12.21,21.53-15.78,9.18-3.56,19.65-5.35,31.42-5.35,18.89,0,34.13,4.15,45.73,12.43,11.58,8.29,17.65,20.28,18.18,35.97h-38.24c-.53-4.64-2.99-8.65-7.35-12.04-4.37-3.38-10.66-5.08-18.86-5.08-6.6,0-11.86,1.25-15.78,3.74-3.92,2.5-5.88,5.88-5.88,10.16s1.69,7.22,5.08,9.36c3.39,2.14,8.91,3.66,16.58,4.55l11.5,1.07c18,1.96,32,6.96,41.99,14.98,9.98,8.02,14.97,18.81,14.97,32.36,0,9.8-2.67,18.32-8.02,25.54-5.35,7.22-12.93,12.79-22.73,16.71-9.81,3.92-21.31,5.89-34.5,5.89Z"}),(0,t.jsx)("path",{d:"M147.88,90.93v-31.82h62.58v31.82h-62.58ZM184.25,44.66c-8.02,0-13.95-2.09-17.78-6.29-3.84-4.19-5.75-9.49-5.75-15.91s1.91-11.99,5.75-16.18c3.83-4.19,9.76-6.29,17.78-6.29s13.95,2.1,17.79,6.29c3.83,4.19,5.75,9.59,5.75,16.18s-1.92,11.72-5.75,15.91c-3.84,4.19-9.76,6.29-17.79,6.29ZM167.4,205.64V59.1h43.05v146.54h-43.05Z"}),(0,t.jsx)("path",{d:"M234.52,41.99V10.43h60.44v31.56h-60.44ZM251.9,205.64V10.43h43.06v195.21h-43.06Z"}),(0,t.jsx)("path",{d:"M375.98,209.39c-10.52,0-19.75-1.87-27.68-5.61-7.94-3.75-14.13-9.13-18.59-16.18-4.46-7.04-6.68-15.47-6.68-25.27,0-10.7,2.76-19.48,8.29-26.34,5.52-6.86,13.28-11.94,23.26-15.25,9.99-3.29,21.48-4.95,34.5-4.95h31.29v23.8h-31.55c-7.49,0-13.24,1.83-17.25,5.48-4.01,3.66-6.02,8.61-6.02,14.84,0,5.89,2,10.66,6.02,14.31,4.01,3.66,9.76,5.48,17.25,5.48,4.81,0,9.13-.84,12.97-2.54,3.83-1.69,6.99-4.59,9.49-8.69,2.49-4.1,3.92-9.8,4.28-17.11l10.16,10.7c-.9,10.16-3.34,18.72-7.35,25.67-4.01,6.96-9.54,12.3-16.58,16.05-7.05,3.74-15.65,5.61-25.81,5.61ZM422.78,205.64v-43.32h-7.22v-46.8c0-7.66-1.79-13.32-5.35-16.98-3.57-3.66-9.27-5.49-17.12-5.49-3.92,0-9.09.09-15.51.27-6.41.18-13.06.4-19.92.67-6.87.27-13.06.58-18.59.93v-36.1c4.28-.35,9.18-.71,14.71-1.07,5.52-.35,11.23-.62,17.12-.8,5.88-.17,11.41-.27,16.58-.27,14.97,0,27.58,2.14,37.84,6.42,10.25,4.28,18.05,10.74,23.4,19.39,5.35,8.65,8.02,19.75,8.02,33.29v89.85h-33.96Z"}),(0,t.jsx)("path",{d:"M548.73,210.46c-20.86,0-37.17-4.33-48.94-12.97-11.77-8.64-18.01-20.72-18.72-36.24h37.97c.71,4.64,3.52,8.79,8.42,12.44,4.9,3.66,12.26,5.48,22.06,5.48,7.49,0,13.68-1.29,18.58-3.88,4.9-2.58,7.36-6.28,7.36-11.09,0-4.28-1.92-7.71-5.75-10.3-3.84-2.58-10.48-4.32-19.92-5.21l-11.49-1.34c-17.65-1.78-30.89-6.64-39.71-14.58-8.82-7.93-13.24-18.22-13.24-30.88,0-10.34,2.58-18.99,7.76-25.94,5.17-6.96,12.34-12.21,21.53-15.78,9.18-3.56,19.65-5.35,31.42-5.35,18.89,0,34.14,4.15,45.73,12.43,11.59,8.29,17.65,20.28,18.19,35.97h-38.24c-.53-4.64-2.99-8.65-7.35-12.04-4.37-3.38-10.66-5.08-18.85-5.08-6.6,0-11.86,1.25-15.78,3.74-3.93,2.5-5.89,5.88-5.89,10.16s1.69,7.22,5.08,9.36c3.38,2.14,8.91,3.66,16.58,4.55l11.5,1.07c18,1.96,32,6.96,41.98,14.98,9.98,8.02,14.98,18.81,14.98,32.36,0,9.8-2.68,18.32-8.02,25.54-5.35,7.22-12.93,12.79-22.73,16.71-9.81,3.92-21.3,5.89-34.49,5.89Z"})]})}),"TCCSilasStarIcon",0,({variant:e="outlined",className:n="",strokeWidth:r=10,...o})=>(0,t.jsx)("svg",{viewBox:"0 0 156.43 156.39",xmlns:"http://www.w3.org/2000/svg",className:`inline silas-star silas-star--${e} ${n}`,"aria-hidden":"true",...o,children:(0,t.jsx)("path",{className:"silas-star-path",pathLength:"1",d:"M156.43,77.96v.04c0,1.09-.77,2.03-1.84,2.26-36.98,8.15-66.08,37.29-74.19,74.28-.23,1.07-1.17,1.84-2.26,1.84h0c-1.1,0-2.03-.77-2.26-1.84C67.78,117.6,38.75,88.49,1.83,80.3c-1.07-.24-1.83-1.17-1.83-2.26v-.11c0-1.09.77-2.03,1.83-2.26C38.61,67.5,67.57,38.58,75.79,1.83c.24-1.07,1.17-1.83,2.26-1.83h.18c1.09,0,2.03.77,2.26,1.84.38,1.71.81,3.4,1.28,5.07,9.19,32.68,34.98,58.41,67.71,67.51.38.11.76.21,1.15.31.3.08.59.16.9.24,1.02.26,2.04.5,3.08.73s1.81,1.18,1.81,2.26Z",fill:"currentColor",fillOpacity:+("filled"===e),stroke:"currentColor",strokeWidth:r,strokeOpacity:+("filled"!==e)})})])},399168,161901,e=>{"use strict";var t=e.i(843476),n=e.i(482820),r=e.i(348707),o=e.i(271645),i=e.i(110333),a=e.i(276495),l=e.i(18429),s=e.i(152480),u=e.i(175658);let c="/v1/media",d=async({page:e,limit:t,search:n,view:r,args:o},i,a)=>(0,u.searchModels)(c,{page:e,limit:t,search:n,view:r,args:o},i,a),f=async(e,t,n)=>(0,u.getModel)(c,e,t,n),m=async(e,t,n)=>(0,u.updateModel)(c,e,t,null,n),g=async(e,t)=>
1(0,u.duplicateModel)(c,e,null,t),p=async(e,t)=>(0,u.deleteModel)(c,e,null,t),h=async(e,t)=>(0,u.restoreModel)(c,e,null,t),v=async(e,t)=>(0,u.createModel)(c,e,null,t),y=async(e,t)=>(0,u.forceDeleteModel)(c,e,null,t),w=async(e,t,n)=>{try{let r=await (0,s.APIGet)(`${s.APIBase}${c}/${e}/usage`,null,t||null,n.token);return await r.json()}catch(e){(0,s.APIErrorHandler)(e)}},S="/v1/mediatag",b=async({page:e,limit:t,search:n,view:r,args:o},i,a)=>(0,u.searchModels)(S,{page:e,limit:t,search:n,view:r,args:o},i,a),x=async(e,t,n)=>(0,u.updateModel)(S,e,t,null,n),E=async(e,t)=>(0,u.deleteModel)(S,e,null,t),C=async(e,t)=>(0,u.restoreModel)(S,e,null,t),A=async(e,t)=>(0,u.createModel)(S,e,null,t),P=async(e,t,n,r)=>(0,u.replaceTags)(S,e,t,n,null,r),T=async(e,t,n,r)=>(0,u.addTags)(S,e,t,n,null,r),M="/v1/network/media",R=async({page:e,limit:t,search:n,view:r,args:o},i,a)=>(0,u.searchModels)(M,{page:e,limit:t,search:n,view:r,args:o},i,a),k=async(e,t,n)=>(0,u.updateModel)(M,e,t,null,n),I=async(e,t)=>(0,u.duplicateModel)(M,e,null,t),L=async(e,t)=>(0,u.deleteModel)(M,e,null,t),N=async(e,t)=>(0,u.restoreModel)(M,e,null,t),$=async(e,t)=>(0,u.createModel)(M,e,null,t),O=async(e,t)=>(0,u.forceDeleteModel)(M,e,null,t),j="/v1/network/mediatag",D=async({page:e,limit:t,search:n,view:r,args:o},i,a)=>(0,u.searchModels)(j,{page:e,limit:t,search:n,view:r,args:o},i,a),H=async(e,t,n)=>(0,u.updateModel)(j,e,t,null,n),B=async(e,t)=>(0,u.deleteModel)(j,e,null,t),F=async(e,t)=>(0,u.restoreModel)(j,e,null,t),_=async(e,t)=>(0,u.createModel)(j,e,null,t),U=async(e,t,n,r)=>(0,u.replaceTags)(j,e,t,n,null,r),W=async(e,t,n,r)=>(0,u.addTags)(j,e,t,n,null,r),G=async({id:e,network:t=!1,args:n={}},r,o)=>{let i=t?M:c,a=[];n&&Object.keys(n).map(e=>a.push(`${e}=${n[e]}`));let l=a.join("&");try{let t=await (0,s.APIGet)(`${s.APIBase}${i}/${e}?${l}`,null,r,o.token);return await t.json()}catch(e){return e}};e.s(["addMediaTags",0,T,"addNetworkMediaTags",0,W,"createMedia",0,v,"createMediaTag",0,A,"createNetworkMedia",0,$,"createNetworkMediaTag",0,_,"deleteMedia",0,p,"deleteMediaTag",0,E,"deleteNetworkMedia",0,L,"deleteNetworkMediaTag",0,B,"duplicateMedia",0,g,"duplicateNetworkMedia",0,I,"forceDeleteMedia",0,y,"forceDeleteNetworkMedia",0,O,"getMedia",0,f,"getMediaUsage",0,w,"loadMediaItem",0,G,"replaceMediaTags",0,P,"replaceNetworkMediaTags",0,U,"restoreMedia",0,h,"restoreMediaTag",0,C,"restoreNetworkMedia",0,N,"restoreNetworkMediaTag",0,F,"searchMedia",0,d,"searchMediaTags",0,b,"searchNetworkMedia",0,R,"searchNetworkMediaTags",0,D,"updateMedia",0,m,"updateMediaTag",0,x,"updateNetworkMedia",0,k,"updateNetworkMediaTag",0,H],161901);var V=e.i(168331),q=e.i(988842),z=e.i(556621),K=e.i(993675);e.i(484875);let Y=(e,t)=>{if(!e||!t)return"";let n=(e,t)=>0===t?e:n(t,e%t),r=n(e,t);return`${e/r} / ${t/r}`},J=async({name:e,type:t,url:n,network:r=!1,meta:o,downloadLocation:i},a)=>{try{let l=`${s.APIBase}/v1/${!0===r?"network/media":"media"}/import`,u=await (0,s.APIPost)(l,{url:n,name:e,type:t,...o&&{meta:o},...i&&{downloadLocation:i}},null,a.token);return await u.json()}catch(e){return e}},Z=({id:e,image:t,network:n,args:r={}})=>{let i=t?.meta?.crops?.[r?.process]?.path,l=i?(0,z.mediaPath)(t?.meta?.crops[r?.process]?.path,t?.meta?.storage):null,s=i?t:null,[u,c]=(0,o.useState)(s),[d,f]=(0,o.useState)(l),[m,g]=(0,o.useState)(!i),p=(0,a.usePublicSession)(),h="mediaassets",v=async e=>{if(!e)return;if(t&&t?.id===e&&r?.process&&t?.meta?.crops&&t?.meta?.crops[r.process]){f((0,z.mediaPath)(t?.meta?.crops[r.process]?.path,t?.meta?.storage)),g(!1),c(t);return}let o=`${e}`;r?.process&&(o=`${e}_${r.process}`),g(!0);let i=await (0,K.loadWithExpiry)(h);if(i){if(i[o]){f(i[o]),g(!1);return}}else i={};let a=p(),l=await G({id:e,network:n,args:r},null,a);if("success"===l.status){let e=l.data?.meta?.path;r?.process&&l.data?.meta?.crops&&l.data?.meta?.crops[r.process]&&(e=(0,z.mediaPath)(l.data?.meta?.crops[r.process]?.path,l.data?.meta?.storage)),f(e),c(l.data),g(!1),(i=await (0,K.loadWithExpiry)(h))||(i={}),i[o]=(0,z.mediaPath)(e,l.data?.meta?.storage),(0,K.storeWithExpiry)(h,i,5e3)}else g(!1)};(0,o.useEffect)(()=>
1{let n=u?(0,z.mediaPath)(u?.meta?.crops[r?.process]?.path,u?.meta?.storage):null;!i&&e||e!==t?.id||e!==u?.id||t?.id!==u?.id?v(e):n!==d&&(f(n),g(!0),setTimeout(()=>g(!1),500))},[e,t,r?.process]);let y=m?null:d;return{assetLoading:m,assetPath:y,assetSrc:y?(0,z.mediaPath)(y):null,activeMedia:u}},X=e=>{let o={width:"100%",height:"100%",objectFit:"cover",objectPosition:"center"};(0,n.default)(e,"crop.w")&&(0,r.default)(o,"maxWidth",`${e.crop.w}px`),(0,n.default)(e,"crop.h")&&(0,r.default)(o,"maxHeight",`${e.crop.h}px`);let i=Y((0,n.default)(e,"crop.w"),(0,n.default)(e,"crop.h"));i&&(0,r.default)(o,"aspectRatio",i);let a=e?.renderer!==!0?"optimizing":"";return(0,t.jsx)("div",{className:(0,q.classNames)(e?.className,"bg-gray-200 animate-pulse p-4 text-xs"),style:o,children:a})},Q=async e=>{try{let t=await fetch(`https://vimeo.com/api/oembed.json?url=${encodeURIComponent(e)}`);if(!t.ok)return console.error(`Error fetching Vimeo thumbnail: ${t.status} ${t.statusText}`),null;return(await t.json()).thumbnail_url}catch(t){return console.error(`Error fetching Vimeo thumbnail for URL "${e}":`,t),null}},ee=/^https:\/\/(www\.)?((youtu.be)|(youtube\.com))\//,et=async e=>ee.test(e)?`https://img.youtube.com/vi/${e.replace(ee,"")}/hqdefault.jpg`:e.includes("vimeo.com")?await Q(e):null;e.s(["ImageCroppingPresets",0,{thumbnail:{process:"thumbnail",w:400,h:400,q:90,f:"webp",u:!1,c:!1},largepreview:{process:"largepreview",w:2200,q:90,f:"webp",u:!0},postcard:{process:"postcard",w:545,h:310,q:90,f:"webp",u:!0,c:!1},featuredcard:{process:"featuredcard",w:365,h:310,q:90,f:"webp",u:!0,c:!1},banner:{process:"banner",w:1920,h:1080,q:90,f:"webp",u:!0,c:!1},social:{process:"social",w:1200,h:630,q:90,f:"webp",u:!0,c:!0},opengraph:{process:"opengraph",w:1200,h:630,q:90,f:"jpeg",u:!0,c:!0,forceExt:"jpg"},email:{process:"email",w:1200,q:85,f:"jpeg",u:!0,forceExt:"jpg"},landscape:{process:"landscape",w:1920,h:1080,q:90,f:"webp",u:!0,c:!1},mediumsquare:{process:"mediumsquare",w:800,h:800,q:90,f:"webp",u:!0,c:!1},largesquare:{process:"largesquare",w:1400,h:1400,q:90,f:"webp",u:!0,c:!1},xlarge:{process:"xlarge",w:2e3,q:90,f:"webp",u:!0},trust:{process:"trust",w:2700,q:90,f:"webp",u:!0},itunesrssjpg:{process:"itunesrssjpg",w:3e3,h:3e3,q:90,f:"jpeg",u:!0,c:!0,forceExt:"jpg"}},"MediaImage",0,({image:e,id:r,crop:a={},network:s=!1,onChange:u=!1,onLoadingChange:c,loading:d="lazy",renderer:f=!1,rootProps:m={},...g})=>{let p=e?.isNetwork?e.isNetwork:s,h=r;e?.id&&(h=e.id),!h&&Number.isInteger(e)&&(h=e);let{assetLoading:v,assetPath:y,assetSrc:w,activeMedia:S}=Z({id:h,image:e,network:p,args:a}),{isRenderer:b,pathname:x}=(0,l.useIntegrationsContext)();(0,o.useEffect)(()=>{S&&u&&JSON.stringify(S)!==JSON.stringify(e)&&u(S)},[S]),(0,o.useEffect)(()=>(c?.(v),()=>c?.(!1)),[v,c]);let E={...g};return(!E?.alt&&(0,n.default)(e,"meta.altText")&&(E.alt=e.meta.altText),v)?(0,t.jsx)(X,{renderer:f,crop:a,...E}):(0,t.jsx)(i.AdminImg,{...E,...m,src:(0,V.withCloudinary)(y,{isRenderer:b,pathname:x}),image:e,loading:d,"data-media-image":!0})},"MediaImageSkeleton",0,X,"convertBytesToPrettySize",0,e=>{if(0===e)return"0 Byte";let t=Math.floor(Math.log(e)/Math.log(1024));return`${Math.round(e/1024**t)} ${["Bytes","KB","MB","GB","TB"][t]}`},"generateImageAltText",0,(e,t="meta.featureImage",r="meta.featureImageAltText")=>{let o=(0,n.default)(e,r);if(o)return o;let i=(0,n.default)(e,t);return i&&i?.meta?.altText?i.meta.altText:e?.name?e.name:"Featured Image"},"getAdminUrlForModel",0,(e,t)=>{if(null==t||""===t)return"#";let n=String(t);switch(e){case"Page":return`/admin/website/pages/${n}`;case"Prayer":return`/admin/prayer/${n}`;case"BlogPost":return`/admin/blogging/post/${n}`;case"NoteOutline":return`/admin/notes/outline/${n}`;case"Group":return`/admin/groups/group/${n}`;case"Event":return`/admin/events/event/${n}`;case"Episode":return`/admin/resources/episodes/${n}`;case"Series":return`/admin/resources/series/${n}`;case"Form":return`/admin/forms/form/${n}`;case"Redirect":return`/admin/website/redirects/${n}`;default:return"#"}},"getAspectRatio",0,Y,"getAudioDuration",0,e=>e&&e.type.includes("audio")?new Promise((t,n)=>{let r=document.createElement("audio");r.src=URL.createObjectURL(e),r.addEventListener("loadedmetadata",()=>{let{duration:e}=r;r.remove(),t(e)}),r.addEventListener("error",()=>{r.remove(),n(Error("Failed to load audio metadata"))}),r.load()}):null,"getVideoThumbnail",0,et,"getVimeoThumbnail",0,Q,"importHostedMedia",0,J,"sanitizeAcceptedUploadFile",0,e=>{let t=e,o=/[+\s#?&%\\^`[\]{}<>|"'()]+/g,i=/[+\s#?&%\\^`[\]{}<>|"'()]/,a=e=>e?e.replace(/\s*-\s*/g,"-").replace(o,"-").replace(/-{2,}/g,"-"):"";return(i.test(e?.path)||i.test(e?.name))&&(t=new File([e],a(e?.name),{type:e.type,lastModified:e.lastModified}),(0,r.default)(t,"path",a(e.path)),(0,r.default)(t,"preview",(0,n.default)(e,"preview","")),(0,r.default)(t,"progress",(0,n.default)(e,"progress",0))),t},"useMediaAsset",0,Z],399168)},95187,(e,t,n)=>{"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={callServer:function(){return i.callServer},createServerReference:function(){return l.createServerReference},findSourceMapURL:function(){return a.findSourceMapURL}};for(var o in r)Object.defineProperty(n,o,{enumerable:!0,get:r[o]});let i=e.r(132120),a=e.r(92245),l=e.r(235326)},78435,e=>{"use strict";var t=e.i(95187);let n=(0,t.createServerReference)("702cf96290d443c295a42f150adc80e84048921258",t.callServer,void 0,t.findSourceMapURL,"revalidateAccountTag");e.s(["revalidateAccountTag",0,n])},26314,e=>{"use strict";let t="settings",n="redirects",r="domain",o="announcements",i="customfonts",a=[t,"integrations",r,o,n,i];e.s(["ANNOUNCEMENT_CACHE_TAG",0,o,"CUSTOM_FONTS_CACHE_TAG",0,i,"DOMAIN_CACHE_TAG",0,r,"REDIRECTS_CACHE_TAG",0,n,"
1SETTINGS_CACHE_TAG",0,t,"getAccountCacheTag",0,(e,t)=>t?a.includes(e)?`acc_${t}_${e}`:(console.error(`Invalid cache tag: ${e}`),null):(console.error("No Account Id provided"),null)])},489578,e=>{"use strict";e.s(["AdminUiContextProvider",()=>c,"useAdminUIContext",()=>s,"usePendingTask",()=>u]);var t=e.i(843476),n=e.i(618566),r=e.i(271645),o=e.i(370771),i=e.i(730059),a=e.i(993675);let l=(0,r.createContext)({account:null,toast:{},setToast:e=>{},pendingTasks:[],hasPendingWork:!1,beginPendingTask:(e,t)=>{},endPendingTask:e=>{},isAdminRoute:!1,user:null,colorScheme:"light",setColorScheme:()=>{},toggleColorScheme:()=>{},userPreferencesId:null,setUserPreferencesId:()=>{},preferenceMeta:null,setPreferenceMeta:()=>{},theme:null,customCSS:null,header:null,footer:null,getAccountSetting:async e=>null}),s=()=>{let e=(0,r.useContext)(l);if(!e)throw Error("AdminUIContext is missing context");return e},u=(e,{label:t}={})=>{let{beginPendingTask:n,endPendingTask:o}=s(),i=(0,r.useId)();(0,r.useEffect)(()=>{if(e){n(i,{label:t});let e=setTimeout(()=>o(i),2e4);return()=>{clearTimeout(e),o(i)}}o(i)},[e,i,t,n,o])},c=({account:e,user:s,app:u,networkRole:c,children:d,defaultLeftSideBarOverride:f=!0,defaultRightSideBarOverride:m=!1})=>{let[g,p]=(0,r.useState)({}),[h,v]=(0,r.useState)(null),[y,w]=(0,r.useState)(null),[S,b]=(0,r.useState)({}),x=(0,r.useCallback)((e,t={})=>{b(n=>({...n,[e]:{key:e,label:t.label||"Workingâ¦"}}))},[]),E=(0,r.useCallback)(e=>{b(t=>{if(!(e in t))return t;let{[e]:n,...r}=t;return r})},[]),C=(0,r.useMemo)(()=>Object.values(S),[S]),[A,P]=(0,r.useState)(null),[T,M]=(0,r.useState)(null),[R,k]=(0,r.useState)(null),[I,L]=(0,r.useState)(null),[N,$]=(0,r.useState)(null),[O,j]=(0,r.useState)(!(window.innerWidth<768)&&f),[D,H]=(0,r.useState)(!(window.innerWidth<768)&&m),{runGet:B}=(0,o.useGetAccountSettingByType)(),F=(0,n.usePathname)()?.startsWith("/admin")||!1,[_,U]=(0,r.useState)(()=>{try{let e=(0,i.getCookie)("colorScheme");return"dark"===e?"dark":"light"}catch{return"light"}}),W=e=>{j(e),(0,a.saveToLocalStorage)("userPlatformLeft",e)},G=e=>{H(e),(0,a.saveToLocalStorage)("userPlatformRight",e);try{window.sessionStorage.setItem("silas-panel-open",e?"1":"0")}catch{}};(0,r.useEffect)(()=>{if(!(window.innerWidth<768))try{"1"===window.sessionStorage.getItem("silas-panel-open")&&H(!0)}catch{}},[]),(0,r.useEffect)(()=>{s?.me?.userPreferences?.id&&v(s.me.userPreferences.id)},[s]),(0,r.useEffect)(()=>{s?.me?.userPreferences?.meta&&w(s.me.userPreferences.meta)},[s]),(0,r.useEffect)(()=>{let e=s?.me?.userPreferences?.meta?.colorScheme;if("dark"===e||"light"===e){U(e);try{(0,i.setCookie)("colorScheme",e,365)}catch(e){console.error("Failed to set color scheme cookie:",e)}}},[s]),(0,r.useEffect)(()=>{"dark"===_?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark");try{(0,i.setCookie)("colorScheme",_,365)}catch(e){console.error("Failed to set color scheme cookie:",e)}},[_]);let V=()=>{U(e=>"dark"===e?"light":"dark")},q=(0,r.useCallback)(async e=>{if("theme"===e&&A)return A;if("customcss"===e&&T)return T;if("header"===e&&R)return R;if("footer"===e&&I)return I;if("smarttext"===e&&N)return N;let t=await B(e);"theme"===e&&P(t),"customcss"===e&&M(t),"header"===e&&k(t),"footer"===e&&L(t),"smarttext"===e&&$(t)},[A,T,R,I,N,B]),z=(0,r.useMemo)(()=>({account:e,user:s,toast:g,setToast:p,pendingTasks:C,hasPendingWork:C.length>0,beginPendingTask:x,endPendingTask:E,isAdminRoute:F,colorScheme:_,setColorScheme:U,toggleColorScheme:V,userPreferencesId:h,setUserPreferencesId:v,preferenceMeta:y,setPreferenceMeta:w,getAccountSetting:q,theme:A,customCSS:T,header:R,footer:I,smartText:N,app:u,platformSideBarLeft:O,platformSideBarRight:D,togglePlatformSideBarLeft:W,togglePlatformSideBarRight:G,networkRole:c}),[e,s,g,C,x,E,F,_,h,y,T,A,R,I,u,q,O,D]);return(0,t.jsx)(l.Provider,{"data-admin-ui-provider":!0,value:z,children:d})}},229315,e=>{"use strict";function t(){return"u">typeof window}function n(e){return i(e)?(e.nodeName||"").toLowerCase():"#document"}function r(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function o(e){var t;return null==(t=(i(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function i(e){return!!t()&&(e instanceof Node||e instanceof r(e).Node)}function a(e){return!!t()&&(e instanceof Element||e instanceof r(e).Element)}function l(e){return!!t()&&(e instanceof HTMLElement||e instanceof r(e).HTMLElement)}function s(e){return!(!t()||"u"<typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof r(e).ShadowRoot)}let u=new Set(["inline","contents"]);function c(e){let{overflow:t,overflowX:n,overflowY:r,display:o}=b(e);
1return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!u.has(o)}let d=new Set(["table","td","th"]),f=[":popover-open",":modal"];function m(e){return f.some(t=>{try{return e.matches(t)}catch(e){return!1}})}let g=["transform","translate","scale","rotate","perspective"],p=["transform","translate","scale","rotate","perspective","filter"],h=["paint","layout","strict","content"];function v(e){let t=y(),n=a(e)?b(e):e;return g.some(e=>!!n[e]&&"none"!==n[e])||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||p.some(e=>(n.willChange||"").includes(e))||h.some(e=>(n.contain||"").includes(e))}function y(){return!("u"<typeof CSS)&&!!CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")}let w=new Set(["html","body","#document"]);function S(e){return w.has(n(e))}function b(e){return r(e).getComputedStyle(e)}function x(e){if("html"===n(e))return e;let t=e.assignedSlot||e.parentNode||s(e)&&e.host||o(e);return s(t)?t.host:t}function E(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}e.s(["getComputedStyle",0,b,"getContainingBlock",0,function(e){let t=x(e);for(;l(t)&&!S(t);){if(v(t))return t;if(m(t))break;t=x(t)}return null},"getDocumentElement",0,o,"getFrameElement",0,E,"getNodeName",0,n,"getNodeScroll",0,function(e){return a(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}},"getOverflowAncestors",0,function e(t,n,o){var i;void 0===n&&(n=[]),void 0===o&&(o=!0);let a=function e(t){let n=x(t);return S(n)?t.ownerDocument?t.ownerDocument.body:t.body:l(n)&&c(n)?n:e(n)}(t),s=a===(null==(i=t.ownerDocument)?void 0:i.body),u=r(a);if(s){let t=E(u);return n.concat(u,u.visualViewport||[],c(a)?a:[],t&&o?e(t):[])}return n.concat(a,e(a,[],o))},"getParentNode",0,x,"getWindow",0,r,"isContainingBlock",0,v,"isElement",0,a,"isHTMLElement",0,l,"isLastTraversableNode",0,S,"isOverflowElement",0,c,"isShadowRoot",0,s,"isTableElement",0,function(e){return d.has(n(e))},"isTopLayer",0,m,"isWebKit",0,y])},167173,e=>{"use strict";var t=e.i(229315);function n(){let e=navigator.userAgentData;return null!=e&&e.platform?e.platform:navigator.platform}function r(){let e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(e=>{let{brand:t,version:n}=e;return t+"/"+n}).join(" "):navigator.userAgent}function o(){let e=/android/i;return e.test(n())||e.test(r())}function i(e){return(0,t.isHTMLElement)(e)&&e.matches("input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])")}e.s(["activeElement",0,function(e){let t=e.activeElement;for(;(null==(n=t)||null==(n=n.shadowRoot)?void 0:n.activeElement)!=null;){var n;t=t.shadowRoot.activeElement}return t},"contains",0,function(e,n){if(!e||!n)return!1;let r=null==n.getRootNode?void 0:n.getRootNode();if(e.contains(n))return!0;if(r&&(0,t.isShadowRoot)(r)){let t=n;for(;t;){if(e===t)return!0;t=t.parentNode||t.host}}return!1},"getDocument",0,function(e){return(null==e?void 0:e.ownerDocument)||document},"getPlatform",0,n,"getTarget",0,function(e){return"composedPath"in e?e.composedPath()[0]:e.target},"getUserAgent",0,r,"isEventTargetWithin",0,function(e,t){return null!=t&&("composedPath"in e?e.composedPath().includes(t):null!=e.target&&t.contains(e.target))},"isMac",0,function(){return n().toLowerCase().startsWith("mac")&&!navigator.maxTouchPoints},"isMouseLikePointerType",0,function(e,t){let n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)},"isReactEvent",0,function(e){return"nativeEvent"in e},"isRootElement",0,function(e){return e.matches("html,body")},"isSafari",0,function(){return/apple/i.test(navigator.vendor)},"isTypeableCombobox",0,function(e){return!!e&&"combobox"===e.getAttribute("role")&&i(e)},"isTypeableElement",0,i,"isVirtualClick",0,function(e){return 0===e.mozInputSource&&!!e.isTrusted||(o()&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType)},"isVirtualPointerEvent",0,function(e){return!r().includes("jsdom/")&&(!o()&&0===e.width&&0===e.height||o()&&1===e.width&&1===e.height&&0===e.pressure&&0===e.detail&&"mouse"===e.pointerType||e.width<1&&e.height<1&&0===e.pressure&&0===e.detail&&"touch"===e.pointerType)},"stopEvent",0,function(e){e.preventDefault(),e.stopPropagation()}])},343084,e=>{"use strict";let t=["top","right","bottom","left"],n=t.reduce((e,t)=>
1e.concat(t,t+"-start",t+"-end"),[]),r=Math.min,o=Math.max,i=Math.round,a=Math.floor,l={left:"right",right:"left",bottom:"top",top:"bottom"},s={start:"end",end:"start"};function u(e){return e.split("-")[0]}function c(e){return e.split("-")[1]}function d(e){return"x"===e?"y":"x"}function f(e){return"y"===e?"height":"width"}let m=new Set(["top","bottom"]);function g(e){return m.has(u(e))?"y":"x"}function p(e){return d(g(e))}function h(e){return e.replace(/start|end/g,e=>s[e])}let v=["left","right"],y=["right","left"],w=["top","bottom"],S=["bottom","top"];function b(e){return e.replace(/left|right|bottom|top/g,e=>l[e])}e.s(["clamp",0,function(e,t,n){return o(e,r(t,n))},"createCoords",0,e=>({x:e,y:e}),"evaluate",0,function(e,t){return"function"==typeof e?e(t):e},"floor",0,a,"getAlignment",0,c,"getAlignmentAxis",0,p,"getAlignmentSides",0,function(e,t,n){void 0===n&&(n=!1);let r=c(e),o=p(e),i=f(o),a="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[i]>t.floating[i]&&(a=b(a)),[a,b(a)]},"getAxisLength",0,f,"getExpandedPlacements",0,function(e){let t=b(e);return[h(e),t,h(t)]},"getOppositeAlignmentPlacement",0,h,"getOppositeAxis",0,d,"getOppositeAxisPlacements",0,function(e,t,n,r){let o=c(e),i=function(e,t,n){switch(e){case"top":case"bottom":if(n)return t?y:v;return t?v:y;case"left":case"right":return t?w:S;default:return[]}}(u(e),"start"===n,r);return o&&(i=i.map(e=>e+"-"+o),t&&(i=i.concat(i.map(h)))),i},"getOppositePlacement",0,b,"getPaddingObject",0,function(e){return"number"!=typeof e?{top:0,right:0,bottom:0,left:0,...e}:{top:e,right:e,bottom:e,left:e}},"getSide",0,u,"getSideAxis",0,g,"max",0,o,"min",0,r,"placements",0,n,"rectToClientRect",0,function(e){let{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}},"round",0,i,"sides",0,t])},397126,e=>{"use strict";var t='input:not([inert]):not([inert] *),select:not([inert]):not([inert] *),textarea:not([inert]):not([inert] *),a[href]:not([inert]):not([inert] *),button:not([inert]):not([inert] *),[tabindex]:not(slot):not([inert]):not([inert] *),audio[controls]:not([inert]):not([inert] *),video[controls]:not([inert]):not([inert] *),[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *),details>summary:first-of-type:not([inert]):not([inert] *),details:not([inert]):not([inert] *)',n="u"<typeof Element,r=n?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,o=!n&&Element.prototype.getRootNode?function(e){var t;return null==e||null==(t=e.getRootNode)?void 0:t.call(e)}:function(e){return null==e?void 0:e.ownerDocument},i=function(e,t){void 0===t&&(t=!0);var n,r=null==e||null==(n=e.getAttribute)?void 0:n.call(e,"inert");return""===r||"true"===r||t&&e&&("function"==typeof e.closest?e.closest("[inert]"):i(e.parentNode))},a=function(e){var t,n=null==e||null==(t=e.getAttribute)?void 0:t.call(e,"contenteditable");return""===n||"true"===n},l=function(e,n,o){if(i(e))return[];var a=Array.prototype.slice.apply(e.querySelectorAll(t));return n&&r.call(e,t)&&a.unshift(e),a=a.filter(o)},s=function(e,n,o){for(var a=[],l=Array.from(e);l.length;){var u=l.shift();if(!i(u,!1))if("SLOT"===u.tagName){var c=u.assignedElements(),d=s(c.length?c:u.children,!0,o);o.flatten?a.push.apply(a,d):a.push({scopeParent:u,candidates:d})}else{r.call(u,t)&&o.filter(u)&&(n||!e.includes(u))&&a.push(u);var f=u.shadowRoot||"function"==typeof o.getShadowRoot&&o.getShadowRoot(u),m=!i(f,!1)&&(!o.shadowRootFilter||o.shadowRootFilter(u));if(f&&m){var g=s(!0===f?u.children:f.children,!0,o);o.flatten?a.push.apply(a,g):a.push({scopeParent:u,candidates:g})}else l.unshift.apply(l,u.children)}}return a},u=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},c=function(e){if(!e)throw Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||a(e))&&!u(e)?0:e.tabIndex},d=function(e,t){var n=c(e);return n<0&&t&&!u(e)?0:n},f=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},m=function(e){return"INPUT"===e.tagName},g=function(e,t){for(var n=0;n<e.length;n++)if(e[n].checked&&e[n].form===t)return e[n]},p=function(e){if(!e.name)return!0;var t,n=e.form||o(e),r=function(e){return n.querySelectorAll('input[type="radio"][name="'+e+'"]')};if("u">typeof window&&void 0!==window.CSS&&"function"==typeof window.CSS.escape)t=r(window.CSS.escape(e.name));else try{t=r(e.name)}
1catch(e){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",e.message),!1}var i=g(t,e.form);return!i||i===e},h=function(e){return m(e)&&"radio"===e.type&&!p(e)},v=function(e){var t,n,r,i,a,l,s,u=e&&o(e),c=null==(t=u)?void 0:t.host,d=!1;if(u&&u!==e)for(d=!!(null!=(n=c)&&null!=(r=n.ownerDocument)&&r.contains(c)||null!=e&&null!=(i=e.ownerDocument)&&i.contains(e));!d&&c;)d=!!(null!=(l=c=null==(a=u=o(c))?void 0:a.host)&&null!=(s=l.ownerDocument)&&s.contains(c));return d},y=function(e){var t=e.getBoundingClientRect(),n=t.width,r=t.height;return 0===n&&0===r},w=function(e,t){var n=t.displayCheck,i=t.getShadowRoot;if("full-native"===n&&"checkVisibility"in e)return!e.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});if("hidden"===getComputedStyle(e).visibility)return!0;var a=r.call(e,"details>summary:first-of-type")?e.parentElement:e;if(r.call(a,"details:not([open]) *"))return!0;if(n&&"full"!==n&&"full-native"!==n&&"legacy-full"!==n){if("non-zero-area"===n)return y(e)}else{if("function"==typeof i){for(var l=e;e;){var s=e.parentElement,u=o(e);if(s&&!s.shadowRoot&&!0===i(s))return y(e);e=e.assignedSlot?e.assignedSlot:s||u===e.ownerDocument?s:u.host}e=l}if(v(e))return!e.getClientRects().length;if("legacy-full"!==n)return!0}return!1},S=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if("FIELDSET"===t.tagName&&t.disabled){for(var n=0;n<t.children.length;n++){var o=t.children.item(n);if("LEGEND"===o.tagName)return!!r.call(t,"fieldset[disabled] *")||!o.contains(e)}return!0}t=t.parentElement}return!1},b=function(e,t){return!(t.disabled||m(t)&&"hidden"===t.type||w(t,e)||"DETAILS"===t.tagName&&Array.prototype.slice.apply(t.children).some(function(e){return"SUMMARY"===e.tagName})||S(t))},x=function(e,t){return!(h(t)||0>c(t))&&!!b(e,t)},E=function(e){var t=parseInt(e.getAttribute("tabindex"),10);return!!isNaN(t)||!!(t>=0)},C=function(e){var t=[],n=[];return e.forEach(function(e,r){var o=!!e.scopeParent,i=o?e.scopeParent:e,a=d(i,o),l=o?C(e.candidates):i;0===a?o?t.push.apply(t,l):t.push(i):n.push({documentOrder:r,tabIndex:a,item:e,isScope:o,content:l})}),n.sort(f).reduce(function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e},[]).concat(t)};e.s(["isTabbable",0,function(e,n){if(n=n||{},!e)throw Error("No node provided");return!1!==r.call(e,t)&&x(n,e)},"tabbable",0,function(e,t){return C((t=t||{}).getShadowRoot?s([e],t.includeContainer,{filter:x.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:E}):l(e,t.includeContainer,x.bind(null,t)))}])},101534,e=>{"use strict";var t=e.i(343084);function n(e,n,r){let o,{reference:i,floating:a}=e,l=(0,t.getSideAxis)(n),s=(0,t.getAlignmentAxis)(n),u=(0,t.getAxisLength)(s),c=(0,t.getSide)(n),d="y"===l,f=i.x+i.width/2-a.width/2,m=i.y+i.height/2-a.height/2,g=i[u]/2-a[u]/2;switch(c){case"top":o={x:f,y:i.y-a.height};break;case"bottom":o={x:f,y:i.y+i.height};break;case"right":o={x:i.x+i.width,y:m};break;case"left":o={x:i.x-a.width,y:m};break;default:o={x:i.x,y:i.y}}switch((0,t.getAlignment)(n)){case"start":o[s]-=g*(r&&d?-1:1);break;case"end":o[s]+=g*(r&&d?-1:1)}return o}async function r(e,n){var r;void 0===n&&(n={});let{x:o,y:i,platform:a,rects:l,elements:s,strategy:u}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:m=!1,padding:g=0}=(0,t.evaluate)(n,e),p=(0,t.getPaddingObject)(g),h=s[m?"floating"===f?"reference":"floating":f],v=(0,t.rectToClientRect)(await a.getClippingRect({element:null==(r=await (null==a.isElement?void 0:a.isElement(h)))||r?h:h.contextElement||await (null==a.getDocumentElement?void 0:a.getDocumentElement(s.floating)),boundary:c,rootBoundary:d,strategy:u})),y="floating"===f?{x:o,y:i,width:l.floating.width,height:l.floating.height}:l.reference,w=await (null==a.getOffsetParent?void 0:a.getOffsetParent(s.floating)),S=await (null==a.isElement?void 0:a.isElement(w))&&await (null==a.getScale?void 0:a.getScale(w))||{x:1,y:1},b=(0,t.rectToClientRect)(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:y,offsetParent:w,strategy:u}):y);
1return{top:(v.top-b.top+p.top)/S.y,bottom:(b.bottom-v.bottom+p.bottom)/S.y,left:(v.left-b.left+p.left)/S.x,right:(b.right-v.right+p.right)/S.x}}let o=async(e,t,o)=>{let{placement:i="bottom",strategy:a="absolute",middleware:l=[],platform:s}=o,u=l.filter(Boolean),c=await (null==s.isRTL?void 0:s.isRTL(t)),d=await s.getElementRects({reference:e,floating:t,strategy:a}),{x:f,y:m}=n(d,i,c),g=i,p={},h=0;for(let o=0;o<u.length;o++){var v;let{name:l,fn:y}=u[o],{x:w,y:S,data:b,reset:x}=await y({x:f,y:m,initialPlacement:i,placement:g,strategy:a,middlewareData:p,rects:d,platform:{...s,detectOverflow:null!=(v=s.detectOverflow)?v:r},elements:{reference:e,floating:t}});f=null!=w?w:f,m=null!=S?S:m,p={...p,[l]:{...p[l],...b}},x&&h<=50&&(h++,"object"==typeof x&&(x.placement&&(g=x.placement),x.rects&&(d=!0===x.rects?await s.getElementRects({reference:e,floating:t,strategy:a}):x.rects),{x:f,y:m}=n(d,g,c)),o=-1)}return{x:f,y:m,placement:g,strategy:a,middlewareData:p}};function i(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function a(e){return t.sides.some(t=>e[t]>=0)}function l(e){let n=(0,t.min)(...e.map(e=>e.left)),r=(0,t.min)(...e.map(e=>e.top));return{x:n,y:r,width:(0,t.max)(...e.map(e=>e.right))-n,height:(0,t.max)(...e.map(e=>e.bottom))-r}}let s=new Set(["left","top"]);async function u(e,n){let{placement:r,platform:o,elements:i}=e,a=await (null==o.isRTL?void 0:o.isRTL(i.floating)),l=(0,t.getSide)(r),u=(0,t.getAlignment)(r),c="y"===(0,t.getSideAxis)(r),d=s.has(l)?-1:1,f=a&&c?-1:1,m=(0,t.evaluate)(n,e),{mainAxis:g,crossAxis:p,alignmentAxis:h}="number"==typeof m?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return u&&"number"==typeof h&&(p="end"===u?-1*h:h),c?{x:p*f,y:g*d}:{x:g*d,y:p*f}}e.s(["arrow",0,e=>({name:"arrow",options:e,async fn(n){let{x:r,y:o,placement:i,rects:a,platform:l,elements:s,middlewareData:u}=n,{element:c,padding:d=0}=(0,t.evaluate)(e,n)||{};if(null==c)return{};let f=(0,t.getPaddingObject)(d),m={x:r,y:o},g=(0,t.getAlignmentAxis)(i),p=(0,t.getAxisLength)(g),h=await l.getDimensions(c),v="y"===g,y=v?"clientHeight":"clientWidth",w=a.reference[p]+a.reference[g]-m[g]-a.floating[p],S=m[g]-a.reference[g],b=await (null==l.getOffsetParent?void 0:l.getOffsetParent(c)),x=b?b[y]:0;x&&await (null==l.isElement?void 0:l.isElement(b))||(x=s.floating[y]||a.floating[p]);let E=x/2-h[p]/2-1,C=(0,t.min)(f[v?"top":"left"],E),A=(0,t.min)(f[v?"bottom":"right"],E),P=x-h[p]-A,T=x/2-h[p]/2+(w/2-S/2),M=(0,t.clamp)(C,T,P),R=!u.arrow&&null!=(0,t.getAlignment)(i)&&T!==M&&a.reference[p]/2-(T<C?C:A)-h[p]/2<0,k=R?T<C?T-C:T-P:0;return{[g]:m[g]+k,data:{[g]:M,centerOffset:T-M-k,...R&&{alignmentOffset:k}},reset:R}}}),"autoPlacement",0,function(e){return void 0===e&&(e={}),{name:"autoPlacement",options:e,async fn(n){var r,o,i,a;let{rects:l,middlewareData:s,placement:u,platform:c,elements:d}=n,{crossAxis:f=!1,alignment:m,allowedPlacements:g=t.placements,autoAlignment:p=!0,...h}=(0,t.evaluate)(e,n),v=void 0!==m||g===t.placements?((a=m||null)?[...g.filter(e=>(0,t.getAlignment)(e)===a),...g.filter(e=>(0,t.getAlignment)(e)!==a)]:g.filter(e=>(0,t.getSide)(e)===e)).filter(e=>!a||(0,t.getAlignment)(e)===a||!!p&&(0,t.getOppositeAlignmentPlacement)(e)!==e):g,y=await c.detectOverflow(n,h),w=(null==(r=s.autoPlacement)?void 0:r.index)||0,S=v[w];if(null==S)return{};let b=(0,t.getAlignmentSides)(S,l,await (null==c.isRTL?void 0:c.isRTL(d.floating)));if(u!==S)return{reset:{placement:v[0]}};let x=[y[(0,t.getSide)(S)],y[b[0]],y[b[1]]],E=[...(null==(o=s.autoPlacement)?void 0:o.overflows)||[],{placement:S,overflows:x}],C=v[w+1];if(C)return{data:{index:w+1,overflows:E},reset:{placement:C}};let A=E.map(e=>{let n=(0,t.getAlignment)(e.placement);return[e.placement,n&&f?e.overflows.slice(0,2).reduce((e,t)=>e+t,0):e.overflows[0],e.overflows]}).sort((e,t)=>e[1]-t[1]),P=(null==(i=A.filter(e=>e[2].slice(0,(0,t.getAlignment)(e[0])?2:3).every(e=>e<=0))[0])?void 0:i[0])||A[0][0];return P!==u?{data:{index:w+1,overflows:E},reset:{placement:P}}:{}}}},"computePosition",0,o,"detectOverflow",0,r,"flip",0,function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(n){var r,o,i,a,l;let{placement:s,middlewareData:u,rects:c,initialPlacement:d,platform:f,elements:m}=n,{mainAxis:g=!0,crossAxis:p=!0,fallbackPlacements:h,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:w=!0,...S}=(0,t.evaluate)(e,n);if(null!=(r=u.arrow)&&r.alignmentOffset)return{};let b=(0,t.getSide)(s),x=(0,t.getSideAxis)(d),E=(0,t.getSide)(d)===d,C=await (null==f.isRTL?void 0:f.isRTL(m.floating)),A=h||(E||!w?[(0,t.getOppositePlacement)(d)]:(0,t.getExpandedPlacements)(d)),P="none"!==y;!h&&P&&A.push(...(0,t.getOppositeAxisPlacements)(d,w,y,C));let T=[d,...A],M=await f.detectOverflow(n,S),R=[],k=(null==(o=u.flip)?void 0:o.overflows)||[];if(g&&R.push(M[b]),p){let e=(0,t.getAlignmentSides)(s,c,C);R.push(M[e[0]],M[e[1]])}if(k=[...k,{placement:s,overflows:R}],!R.every(e=>e<=0)){let e=((null==(i=u.flip)?void 0:i.index)||0)+1,n=T[e];
1if(n&&("alignment"!==p||x===(0,t.getSideAxis)(n)||k.every(e=>(0,t.getSideAxis)(e.placement)!==x||e.overflows[0]>0)))return{data:{index:e,overflows:k},reset:{placement:n}};let r=null==(a=k.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:a.placement;if(!r)switch(v){case"bestFit":{let e=null==(l=k.filter(e=>{if(P){let n=(0,t.getSideAxis)(e.placement);return n===x||"y"===n}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:l[0];e&&(r=e);break}case"initialPlacement":r=d}if(s!==r)return{reset:{placement:r}}}return{}}}},"hide",0,function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(n){let{rects:r,platform:o}=n,{strategy:l="referenceHidden",...s}=(0,t.evaluate)(e,n);switch(l){case"referenceHidden":{let e=i(await o.detectOverflow(n,{...s,elementContext:"reference"}),r.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:a(e)}}}case"escaped":{let e=i(await o.detectOverflow(n,{...s,altBoundary:!0}),r.floating);return{data:{escapedOffsets:e,escaped:a(e)}}}default:return{}}}}},"inline",0,function(e){return void 0===e&&(e={}),{name:"inline",options:e,async fn(n){let{placement:r,elements:o,rects:i,platform:a,strategy:s}=n,{padding:u=2,x:c,y:d}=(0,t.evaluate)(e,n),f=Array.from(await (null==a.getClientRects?void 0:a.getClientRects(o.reference))||[]),m=function(e){let n=e.slice().sort((e,t)=>e.y-t.y),r=[],o=null;for(let e=0;e<n.length;e++){let t=n[e];!o||t.y-o.y>o.height/2?r.push([t]):r[r.length-1].push(t),o=t}return r.map(e=>(0,t.rectToClientRect)(l(e)))}(f),g=(0,t.rectToClientRect)(l(f)),p=(0,t.getPaddingObject)(u),h=await a.getElementRects({reference:{getBoundingClientRect:function(){if(2===m.length&&m[0].left>m[1].right&&null!=c&&null!=d)return m.find(e=>c>e.left-p.left&&c<e.right+p.right&&d>e.top-p.top&&d<e.bottom+p.bottom)||g;if(m.length>=2){if("y"===(0,t.getSideAxis)(r)){let e=m[0],n=m[m.length-1],o="top"===(0,t.getSide)(r),i=e.top,a=n.bottom,l=o?e.left:n.left,s=o?e.right:n.right;return{top:i,bottom:a,left:l,right:s,width:s-l,height:a-i,x:l,y:i}}let e="left"===(0,t.getSide)(r),n=(0,t.max)(...m.map(e=>e.right)),o=(0,t.min)(...m.map(e=>e.left)),i=m.filter(t=>e?t.left===o:t.right===n),a=i[0].top,l=i[i.length-1].bottom;return{top:a,bottom:l,left:o,right:n,width:n-o,height:l-a,x:o,y:a}}return g}},floating:o.floating,strategy:s});return i.reference.x!==h.reference.x||i.reference.y!==h.reference.y||i.reference.width!==h.reference.width||i.reference.height!==h.reference.height?{reset:{rects:h}}:{}}}},"limitShift",0,function(e){return void 0===e&&(e={}),{options:e,fn(n){let{x:r,y:o,placement:i,rects:a,middlewareData:l}=n,{offset:u=0,mainAxis:c=!0,crossAxis:d=!0}=(0,t.evaluate)(e,n),f={x:r,y:o},m=(0,t.getSideAxis)(i),g=(0,t.getOppositeAxis)(m),p=f[g],h=f[m],v=(0,t.evaluate)(u,n),y="number"==typeof v?{mainAxis:v,crossAxis:0}:{mainAxis:0,crossAxis:0,...v};if(c){let e="y"===g?"height":"width",t=a.reference[g]-a.floating[e]+y.mainAxis,n=a.reference[g]+a.reference[e]-y.mainAxis;p<t?p=t:p>n&&(p=n)}if(d){var w,S;let e="y"===g?"width":"height",n=s.has((0,t.getSide)(i)),r=a.reference[m]-a.floating[e]+(n&&(null==(w=l.offset)?void 0:w[m])||0)+(n?0:y.crossAxis),o=a.reference[m]+a.reference[e]+(n?0:(null==(S=l.offset)?void 0:S[m])||0)-(n?y.crossAxis:0);h<r?h=r:h>o&&(h=o)}return{[g]:p,[m]:h}}}},"offset",0,function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;let{x:o,y:i,placement:a,middlewareData:l}=t,s=await u(t,e);return a===(null==(n=l.offset)?void 0:n.placement)&&null!=(r=l.arrow)&&r.alignmentOffset?{}:{x:o+s.x,y:i+s.y,data:{...s,placement:a}}}}},"shift",0,function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(n){let{x:r,y:o,placement:i,platform:a}=n,{mainAxis:l=!0,crossAxis:s=!1,limiter:u={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...c}=(0,t.evaluate)(e,n),d={x:r,y:o},f=await a.detectOverflow(n,c),m=(0,t.getSideAxis)((0,t.getSide)(i)),g=(0,t.getOppositeAxis)(m),p=d[g],h=d[m];if(l){let e="y"===g?"top":"left",n="y"===g?"bottom":"right",r=p+f[e],o=p-f[n];p=(0,t.clamp)(r,p,o)}if(s){let e="y"===m?"top":"left",n="y"===m?"bottom":"right",r=h+f[e],o=h-f[n];h=(0,t.clamp)(r,h,o)}let v=u.fn({...n,[g]:p,[m]:h});return{...v,data:{x:v.x-r,y:v.y-o,enabled:{[g]:l,[m]:s}}}}}},"size",0,function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(n){var r,o;let i,a,{placement:l,rects:s,platform:u,elements:c}=n,{apply:d=()=>{},...f}=(0,t.evaluate)(e,n),m=await u.detectOverflow(n,f),g=(0,t.getSide)(l),p=(0,t.getAlignment)(l),h="y"===(0,t.getSideAxis)(l),{width:v,height:y}=s.floating;"top"===g||"bottom"===g?(i=g,a=p===(await (null==u.isRTL?void 0:u.isRTL(c.floating))?"start":"end")?"left":"right"):(a=g,i="end"===p?"to
1p":"bottom");let w=y-m.top-m.bottom,S=v-m.left-m.right,b=(0,t.min)(y-m[i],w),x=(0,t.min)(v-m[a],S),E=!n.middlewareData.shift,C=b,A=x;if(null!=(r=n.middlewareData.shift)&&r.enabled.x&&(A=S),null!=(o=n.middlewareData.shift)&&o.enabled.y&&(C=w),E&&!p){let e=(0,t.max)(m.left,0),n=(0,t.max)(m.right,0),r=(0,t.max)(m.top,0),o=(0,t.max)(m.bottom,0);h?A=v-2*(0!==e||0!==n?e+n:(0,t.max)(m.left,m.right)):C=y-2*(0!==r||0!==o?r+o:(0,t.max)(m.top,m.bottom))}await d({...n,availableWidth:A,availableHeight:C});let P=await u.getDimensions(c.floating);return v!==P.width||y!==P.height?{reset:{rects:!0}}:{}}}}])},258950,953760,e=>{"use strict";var t=e.i(343084),n=e.i(101534),r=e.i(229315);function o(e){let n=(0,r.getComputedStyle)(e),o=parseFloat(n.width)||0,i=parseFloat(n.height)||0,a=(0,r.isHTMLElement)(e),l=a?e.offsetWidth:o,s=a?e.offsetHeight:i,u=(0,t.round)(o)!==l||(0,t.round)(i)!==s;return u&&(o=l,i=s),{width:o,height:i,$:u}}function i(e){return(0,r.isElement)(e)?e:e.contextElement}function a(e){let n=i(e);if(!(0,r.isHTMLElement)(n))return(0,t.createCoords)(1);let a=n.getBoundingClientRect(),{width:l,height:s,$:u}=o(n),c=(u?(0,t.round)(a.width):a.width)/l,d=(u?(0,t.round)(a.height):a.height)/s;return c&&Number.isFinite(c)||(c=1),d&&Number.isFinite(d)||(d=1),{x:c,y:d}}let l=(0,t.createCoords)(0);function s(e){let t=(0,r.getWindow)(e);return(0,r.isWebKit)()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:l}function u(e,n,o,l){var u;void 0===n&&(n=!1),void 0===o&&(o=!1);let c=e.getBoundingClientRect(),d=i(e),f=(0,t.createCoords)(1);n&&(l?(0,r.isElement)(l)&&(f=a(l)):f=a(e));let m=(void 0===(u=o)&&(u=!1),l&&(!u||l===(0,r.getWindow)(d))&&u)?s(d):(0,t.createCoords)(0),g=(c.left+m.x)/f.x,p=(c.top+m.y)/f.y,h=c.width/f.x,v=c.height/f.y;if(d){let e=(0,r.getWindow)(d),t=l&&(0,r.isElement)(l)?(0,r.getWindow)(l):l,n=e,o=(0,r.getFrameElement)(n);for(;o&&l&&t!==n;){let e=a(o),t=o.getBoundingClientRect(),i=(0,r.getComputedStyle)(o),l=t.left+(o.clientLeft+parseFloat(i.paddingLeft))*e.x,s=t.top+(o.clientTop+parseFloat(i.paddingTop))*e.y;g*=e.x,p*=e.y,h*=e.x,v*=e.y,g+=l,p+=s,n=(0,r.getWindow)(o),o=(0,r.getFrameElement)(n)}}return(0,t.rectToClientRect)({width:h,height:v,x:g,y:p})}function c(e,t){let n=(0,r.getNodeScroll)(e).scrollLeft;return t?t.left+n:u((0,r.getDocumentElement)(e)).left+n}function d(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-c(e,n),y:n.top+t.scrollTop}}let f=new Set(["absolute","fixed"]);function m(e,n,o){var i;let l;if("viewport"===n)l=function(e,t){let n=(0,r.getWindow)(e),o=(0,r.getDocumentElement)(e),i=n.visualViewport,a=o.clientWidth,l=o.clientHeight,s=0,u=0;if(i){a=i.width,l=i.height;let e=(0,r.isWebKit)();(!e||e&&"fixed"===t)&&(s=i.offsetLeft,u=i.offsetTop)}let d=c(o);if(d<=0){let e=o.ownerDocument,t=e.body,n=getComputedStyle(t),r="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(o.clientWidth-t.clientWidth-r);i<=25&&(a-=i)}else d<=25&&(a+=d);return{width:a,height:l,x:s,y:u}}(e,o);else if("document"===n){let n,o,a,s,u,d,f;i=(0,r.getDocumentElement)(e),n=(0,r.getDocumentElement)(i),o=(0,r.getNodeScroll)(i),a=i.ownerDocument.body,s=(0,t.max)(n.scrollWidth,n.clientWidth,a.scrollWidth,a.clientWidth),u=(0,t.max)(n.scrollHeight,n.clientHeight,a.scrollHeight,a.clientHeight),d=-o.scrollLeft+c(i),f=-o.scrollTop,"rtl"===(0,r.getComputedStyle)(a).direction&&(d+=(0,t.max)(n.clientWidth,a.clientWidth)-s),l={width:s,height:u,x:d,y:f}}else if((0,r.isElement)(n)){let e,i,s,c,d,f;i=(e=u(n,!0,"fixed"===o)).top+n.clientTop,s=e.left+n.clientLeft,c=(0,r.isHTMLElement)(n)?a(n):(0,t.createCoords)(1),d=n.clientWidth*c.x,f=n.clientHeight*c.y,l={width:d,height:f,x:s*c.x,y:i*c.y}}else{let t=s(e);l={x:n.x-t.x,y:n.y-t.y,width:n.width,height:n.height}}return(0,t.rectToClientRect)(l)}function g(e){return"static"===(0,r.getComputedStyle)(e).position}function p(e,t){if(!(0,r.isHTMLElement)(e)||"fixed"===(0,r.getComputedStyle)(e).position)return null;if(t)return t(e);let n=e.offsetParent;return(0,r.getDocumentElement)(e)===n&&(n=n.ownerDocument.body),n}function h(e,t){let n=(0,r.getWindow)(e);if((0,r.isTopLayer)(e))return n;if(!(0,r.isHTMLElement)(e)){let t=(0,r.getParentNode)(e);for(;t&&!(0,r.isLastTraversableNode)(t);){if((0,r.isElement)(t)&&!g(t))return t;t=(0,r.getParentNode)(t)}return n}let o=p(e,t);for(;o&&(0,r.isTableElement)(o)&&g(o);)o=p(o,t);return o&&(0,r.isLastTraversableNode)(o)&&g(o)&&!(0,r.isContainingBlock)(o)?n:o||(0,r.getContainingBlock)(e)||n}let v=async function(e){let n=this.getOffsetParent||h,o=this.getDimensions,i=await o(e.floating);return{reference:function(e,n,o){let i=(0,r.isHTMLElement)(n),a=(0,r.getDocumentElement)(n),l="fixed"===o,s=u(e,!0,l,n),f={scrollLeft:0,scrollTop:0},m=(0,t.createCoords)(0);if(i||!i&&!l)if(("body"!==(0,r.getNodeName)(n)||(0,r.isOverflowElement)(a))&&(f=(0,r.getNodeScroll)(n)),i){let e=u(n,!0,l,n);m.x=e.x+n.clientLeft,m.y=e.y+n.clientTop}else a&&(m.x=c(a));l&&!i&&a&&(m.x=c(a));let g=!a||i||l?(0,t.createCoords)(0):d(a,f);return{x:s.left+f.scrollLeft-m.x-g.x,y:s.top+f.scrollTop-m.y-g.y,width:s.width,height:s.height}}(e.reference,await n(e.floating),e.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}},y={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:n,rect:o,offsetParent:i,strategy:l}=e,s="fixed"===l,c=(0,r.getDocumentElement)(i),f=!!n&&(0,r.isTopLayer)(n.floating);if(i===c||f&&s)return o;let m={scrollLeft:0,scrollTop:0},g=(0,t.createCoords)(1),p=(0,t.createCoords)(0),h=(0,r.isHTMLElement)(i);if((h||!h&&!s)&&(("body"!==(0,r.getNodeName)(i)||(0,r.isOverflowElement)(c))&&(m=(0,r.getNodeScroll)(i)),(0,r.isHTMLElement)(i))
1){let e=u(i);g=a(i),p.x=e.x+i.clientLeft,p.y=e.y+i.clientTop}let v=!c||h||s?(0,t.createCoords)(0):d(c,m);return{width:o.width*g.x,height:o.height*g.y,x:o.x*g.x-m.scrollLeft*g.x+p.x+v.x,y:o.y*g.y-m.scrollTop*g.y+p.y+v.y}},getDocumentElement:r.getDocumentElement,getClippingRect:function(e){let{element:n,boundary:o,rootBoundary:i,strategy:a}=e,l=[..."clippingAncestors"===o?(0,r.isTopLayer)(n)?[]:function(e,t){let n=t.get(e);if(n)return n;let o=(0,r.getOverflowAncestors)(e,[],!1).filter(e=>(0,r.isElement)(e)&&"body"!==(0,r.getNodeName)(e)),i=null,a="fixed"===(0,r.getComputedStyle)(e).position,l=a?(0,r.getParentNode)(e):e;for(;(0,r.isElement)(l)&&!(0,r.isLastTraversableNode)(l);){let t=(0,r.getComputedStyle)(l),n=(0,r.isContainingBlock)(l);n||"fixed"!==t.position||(i=null),(a?!n&&!i:!n&&"static"===t.position&&!!i&&f.has(i.position)||(0,r.isOverflowElement)(l)&&!n&&function e(t,n){let o=(0,r.getParentNode)(t);return!(o===n||!(0,r.isElement)(o)||(0,r.isLastTraversableNode)(o))&&("fixed"===(0,r.getComputedStyle)(o).position||e(o,n))}(e,l))?o=o.filter(e=>e!==l):i=t,l=(0,r.getParentNode)(l)}return t.set(e,o),o}(n,this._c):[].concat(o),i],s=l[0],u=l.reduce((e,r)=>{let o=m(n,r,a);return e.top=(0,t.max)(o.top,e.top),e.right=(0,t.min)(o.right,e.right),e.bottom=(0,t.min)(o.bottom,e.bottom),e.left=(0,t.max)(o.left,e.left),e},m(n,s,a));return{width:u.right-u.left,height:u.bottom-u.top,x:u.left,y:u.top}},getOffsetParent:h,getElementRects:v,getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){let{width:t,height:n}=o(e);return{width:t,height:n}},getScale:a,isElement:r.isElement,isRTL:function(e){return"rtl"===(0,r.getComputedStyle)(e).direction}};function w(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}let S=n.detectOverflow,b=n.offset,x=n.autoPlacement,E=n.shift,C=n.flip,A=n.size,P=n.hide,T=n.arrow,M=n.inline,R=n.limitShift,k=(e,t,r)=>{let o=new Map,i={platform:y,...r},a={...i.platform,_c:o};return(0,n.computePosition)(e,t,{...i,platform:a})};e.s(["arrow",0,T,"autoPlacement",0,x,"autoUpdate",0,function(e,n,o,a){let l;void 0===a&&(a={});let{ancestorScroll:s=!0,ancestorResize:c=!0,elementResize:d="function"==typeof ResizeObserver,layoutShift:f="function"==typeof IntersectionObserver,animationFrame:m=!1}=a,g=i(e),p=s||c?[...g?(0,r.getOverflowAncestors)(g):[],...(0,r.getOverflowAncestors)(n)]:[];p.forEach(e=>{s&&e.addEventListener("scroll",o,{passive:!0}),c&&e.addEventListener("resize",o)});let h=g&&f?function(e,n){let o,i=null,a=(0,r.getDocumentElement)(e);function l(){var e;clearTimeout(o),null==(e=i)||e.disconnect(),i=null}return!function r(s,u){void 0===s&&(s=!1),void 0===u&&(u=1),l();let c=e.getBoundingClientRect(),{left:d,top:f,width:m,height:g}=c;if(s||n(),!m||!g)return;let p={rootMargin:-(0,t.floor)(f)+"px "+-(0,t.floor)(a.clientWidth-(d+m))+"px "+-(0,t.floor)(a.clientHeight-(f+g))+"px "+-(0,t.floor)(d)+"px",threshold:(0,t.max)(0,(0,t.min)(1,u))||1},h=!0;function v(t){let n=t[0].intersectionRatio;if(n!==u){if(!h)return r();n?r(!1,n):o=setTimeout(()=>{r(!1,1e-7)},1e3)}1!==n||w(c,e.getBoundingClientRect())||r(),h=!1}try{i=new IntersectionObserver(v,{...p,root:a.ownerDocument})}catch(e){i=new IntersectionObserver(v,p)}i.observe(e)}(!0),l}(g,o):null,v=-1,y=null;d&&(y=new ResizeObserver(e=>{let[t]=e;t&&t.target===g&&y&&(y.unobserve(n),cancelAnimationFrame(v),v=requestAnimationFrame(()=>{var e;null==(e=y)||e.observe(n)})),o()}),g&&!m&&y.observe(g),y.observe(n));let S=m?u(e):null;return m&&function t(){let n=u(e);S&&!w(S,n)&&o(),S=n,l=requestAnimationFrame(t)}(),o(),()=>{var e;p.forEach(e=>{s&&e.removeEventListener("scroll",o),c&&e.removeEventListener("resize",o)}),null==h||h(),null==(e=y)||e.disconnect(),y=null,m&&cancelAnimationFrame(l)}},"computePosition",0,k,"detectOverflow",0,S,"flip",0,C,"hide",0,P,"inline",0,M,"limitShift",0,R,"offset",0,b,"shift",0,E,"size",0,A],953760);var I=e.i(271645),L=e.i(174080),N="u">typeof document?I.useLayoutEffect:function(){};function $(e,t){let n,r,o;if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;
1if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if((n=e.length)!==t.length)return!1;for(r=n;0!=r--;)if(!$(e[r],t[r]))return!1;return!0}if((n=(o=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!({}).hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){let n=o[r];if(("_owner"!==n||!e.$$typeof)&&!$(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function O(e){return"u"<typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function j(e,t){let n=O(e);return Math.round(t*n)/n}function D(e){let t=I.useRef(e);return N(()=>{t.current=e}),t}e.s(["flip",0,(e,t)=>({...C(e),options:[e,t]}),"hide",0,(e,t)=>({...P(e),options:[e,t]}),"limitShift",0,(e,t)=>({...R(e),options:[e,t]}),"offset",0,(e,t)=>({...b(e),options:[e,t]}),"shift",0,(e,t)=>({...E(e),options:[e,t]}),"size",0,(e,t)=>({...A(e),options:[e,t]}),"useFloating",0,function(e){void 0===e&&(e={});let{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:a}={},transform:l=!0,whileElementsMounted:s,open:u}=e,[c,d]=I.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,m]=I.useState(r);$(f,r)||m(r);let[g,p]=I.useState(null),[h,v]=I.useState(null),y=I.useCallback(e=>{e!==x.current&&(x.current=e,p(e))},[]),w=I.useCallback(e=>{e!==E.current&&(E.current=e,v(e))},[]),S=i||g,b=a||h,x=I.useRef(null),E=I.useRef(null),C=I.useRef(c),A=null!=s,P=D(s),T=D(o),M=D(u),R=I.useCallback(()=>{if(!x.current||!E.current)return;let e={placement:t,strategy:n,middleware:f};T.current&&(e.platform=T.current),k(x.current,E.current,e).then(e=>{let t={...e,isPositioned:!1!==M.current};H.current&&!$(C.current,t)&&(C.current=t,L.flushSync(()=>{d(t)}))})},[f,t,n,T,M]);N(()=>{!1===u&&C.current.isPositioned&&(C.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[u]);let H=I.useRef(!1);N(()=>(H.current=!0,()=>{H.current=!1}),[]),N(()=>{if(S&&(x.current=S),b&&(E.current=b),S&&b){if(P.current)return P.current(S,b,R);R()}},[S,b,R,P,A]);let B=I.useMemo(()=>({reference:x,floating:E,setReference:y,setFloating:w}),[y,w]),F=I.useMemo(()=>({reference:S,floating:b}),[S,b]),_=I.useMemo(()=>{let e={position:n,left:0,top:0};if(!F.floating)return e;let t=j(F.floating,c.x),r=j(F.floating,c.y);return l?{...e,transform:"translate("+t+"px, "+r+"px)",...O(F.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}},[n,l,F.floating,c.x,c.y]);return I.useMemo(()=>({...c,update:R,refs:B,elements:F,floatingStyles:_}),[c,R,B,F,_])}],258950)},543489,e=>{"use strict";let t;var n=e.i(271645),r=e.i(167173),o=e.i(343084),i=e.i(229315),a=e.i(397126),l=e.i(174080),s=e.i(258950),u=e.i(953760);let c={...n},d=c.useInsertionEffect||(e=>e());function f(e){let t=n.useRef(()=>{});return d(()=>{t.current=e}),n.useCallback(function(){for(var e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return null==t.current?void 0:t.current(...n)},[])}var m="u">typeof document?n.useLayoutEffect:n.useEffect;function g(){return(g=Object.assign.bind()).apply(this,arguments)}let p=!1,h=0,v=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+h++,y=c.useId||function(){let[e,t]=n.useState(()=>p?v():void 0);return m(()=>{null==e&&t(v())},[]),n.useEffect(()=>{p=!0},[]),e},w=n.createContext(null),S=n.createContext(null),b=()=>{var e;return(null==(e=n.useContext(w))?void 0:e.id)||null};function x(e){return"data-floating-ui-"+e}function E(e){let t=(0,n.useRef)(e);return m(()=>{t.current=e}),t}let C=x("safe-polygon");function A(e,t,n){return n&&!(0,r.isMouseLikePointerType)(n)?0:"number"==typeof e?e:null==e?void 0:e[t]}function P(e,t){let n=e.filter(e=>{var n;return e.parentId===t&&(null==(n=e.context)?void 0:n.open)}),r=n;for(;r.length;)r=e.filter(e=>{var t;return null==(t=r)?void 0:t.some(t=>{var n;return e.parentId===t.id&&(null==(n=e.context)?void 0:n.open)})}),n=n.concat(r);return n}let T=()=>({getShadowRoot:!0,displayCheck:"function"==typeof ResizeObserver&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function M(e,t){let n=(0,a.tabbable)(e,T());"prev"===t&&n.reverse();let o=n.indexOf((0,r.activeElement)((0,r.getDocument)(e)));return n.slice(o+1)[0]}function R(e,t){let n=t||e.currentTarget,o=e.relatedTarget;return!o||!(0,r.contains)(n,o)}
1function k(e){e.querySelectorAll("[data-tabindex]").forEach(e=>{let t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")})}let I={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0};function L(e){"Tab"===e.key&&(e.target,clearTimeout(t))}let N=n.forwardRef(function(e,t){let[o,i]=n.useState();m(()=>((0,r.isSafari)()&&i("button"),document.addEventListener("keydown",L),()=>{document.removeEventListener("keydown",L)}),[]);let a={ref:t,tabIndex:0,role:o,"aria-hidden":!o||void 0,[x("focus-guard")]:"",style:I};return n.createElement("span",g({},e,a))}),$=n.createContext(null),O=x("portal"),j={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},D={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},H=e=>{var t,n;return{escapeKey:"boolean"==typeof e?e:null!=(t=null==e?void 0:e.escapeKey)&&t,outsidePress:"boolean"==typeof e?e:null==(n=null==e?void 0:e.outsidePress)||n}},B="active",F="selected";function _(e,t,n){let r=new Map,o="item"===n,i=e;if(o&&e){let{[B]:t,[F]:n,...r}=e;i=r}return{..."floating"===n&&{tabIndex:-1,"data-floating-ui-focusable":""},...i,...t.map(t=>{let r=t?t[n]:null;return"function"==typeof r?e?r(e):null:r}).concat(e).reduce((e,t)=>(t&&Object.entries(t).forEach(t=>{let[n,i]=t;if(!(o&&[B,F].includes(n)))if(0===n.indexOf("on")){if(r.has(n)||r.set(n,[]),"function"==typeof i){var a;null==(a=r.get(n))||a.push(i),e[n]=function(){for(var e,t=arguments.length,o=Array(t),i=0;i<t;i++)o[i]=arguments[i];return null==(e=r.get(n))?void 0:e.map(e=>e(...o)).find(e=>void 0!==e)}}}else e[n]=i}),e),{})}}let U=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function W(e,t){return{...e,rects:{...e.rects,floating:{...e.rects.floating,height:t}}}}e.s(["FloatingPortal",0,function(e){let{children:t,id:r,root:o,preserveTabOrder:s=!0}=e,u=function(e){void 0===e&&(e={});let{id:t,root:r}=e,o=y(),a=n.useContext($),[l,s]=n.useState(null),u=n.useRef(null);return m(()=>()=>{null==l||l.remove(),queueMicrotask(()=>{u.current=null})},[l]),m(()=>{if(!o||u.current)return;let e=t?document.getElementById(t):null;if(!e)return;let n=document.createElement("div");n.id=o,n.setAttribute(O,""),e.appendChild(n),u.current=n,s(n)},[t,o]),m(()=>{if(null===r||!o||u.current)return;let e=r||(null==a?void 0:a.portalNode);e&&!(0,i.isElement)(e)&&(e=e.current),e=e||document.body;let n=null;t&&((n=document.createElement("div")).id=t,e.appendChild(n));let l=document.createElement("div");l.id=o,l.setAttribute(O,""),(e=n||e).appendChild(l),u.current=l,s(l)},[t,r,o,a]),l}({id:r,root:o}),[c,d]=n.useState(null),f=n.useRef(null),g=n.useRef(null),p=n.useRef(null),h=n.useRef(null),v=null==c?void 0:c.modal,w=null==c?void 0:c.open,S=!!c&&!c.modal&&c.open&&s&&!!(o||u);return n.useEffect(()=>{if(u&&s&&!v)return u.addEventListener("focusin",e,!0),u.addEventListener("focusout",e,!0),()=>{u.removeEventListener("focusin",e,!0),u.removeEventListener("focusout",e,!0)};function e(e){u&&R(e)&&("focusin"===e.type?k:function(e){(0,a.tabbable)(e,T()).forEach(e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")})})(u)}},[u,s,v]),n.useEffect(()=>{!u||w||k(u)},[w,u]),n.createElement($.Provider,{value:n.useMemo(()=>({preserveTabOrder:s,beforeOutsideRef:f,afterOutsideRef:g,beforeInsideRef:p,afterInsideRef:h,portalNode:u,setFocusManagerState:d}),[s,u])},S&&u&&n.createElement(N,{"data-type":"outside",ref:f,onFocus:e=>{if(R(e,u)){var t;null==(t=p.current)||t.focus()}else{let e=M(document.body,"prev")||(null==c?void 0:c.refs.domReference.current);null==e||e.focus()}}}),S&&u&&n.createElement("span",{"aria-owns":u.id,style:I}),u&&l.createPortal(t,u),S&&u&&n.createElement(N,{"data-type":"outside",ref:g,onFocus:e=>{if(R(e,u)){var t;null==(t=h.current)||t.focus()}else{let t=M(document.body,"next")||(null==c?void 0:c.refs.domReference.current);null==t||t.focus(),(null==c?void 0:c.closeOnFocusOut)&&(null==c||c.onOpenChange(!1,e.nativeEvent,"focus-out"))}}}))},"inner",0,e=>({name:"inner",options:e,async fn(t){let{listRef:n,overflowRef:r,onFallbackChange:i,offset:a=0,index:c=0,minItemsVisible:d=4,referenceOverflowThreshold:f=0,scrollRef:m,...g}=(0,o.evaluate)(e,t),{rects:p,elements:{floating:h}}=t,v=n.current[c],y=(null==m?void 0:m.current)||h,w=h.clientTop||y.clientTop,S=0!==h.clientTop,b=0!==y.clientTop,x=h===y;if(!v)return{};let E={...t,...await (0,s.offset)(-v.offsetTop-h.clientTop-p.reference.height/2-v.offsetHeight/2-a).fn(t)},C=await (0,u.detectOverflow)(W(E,y.scrollHeight+w+h.clientTop),g),A=await (0,u.detectOverflow)(E,{...g,elementContext:"reference"}),P=(0,o.max)(0,C.top),T=E.y+P,M=(y.scrollHeight>y.clientHeight?e=>e:o.round)((0,o.max)(0,y.scrollHeight+(S&&x||b?2*w:0)-P-(0,o.max)(0,C.bottom)));if(y.style.maxHeight=M+"px",y.scrollTop=P,i){let e=y.offsetHeight<v.offsetHeight*(0,o.min)(d,n.current.length)-1||A.top>=-f||A.bottom>=-f;l.flushSync(()=>i(e))}return r&&(r.current=await (0,u.detectOverflow)(W({...E,y:T},y.offsetHeight+w+h.clientTop),g)),{y:T}}}),"useDismiss",0,function(e,t){void 0===t&&(t={});let{open:o,onOpenChange:a,elements:l,dataRef:s}=e,{enabled:u=!0,escapeKey:c=!0,outsidePress:d=!0,outsidePressEvent:m="pointerdown",referencePress:g=!1,referencePressEvent:p="pointerdown",ancestorScroll:h=!1,bubbles:v,capture:y}=t,w=n.useContext(S),b=f("function"==typeof d?d:()=>!1),E="function"==typeof d?b:d,C=n.useRef(!1),A=n.useRef(!1),{escapeKey:T,outsidePress:M}=H(v),{escapeKey:R,outsidePress:k}=H(y),I=n.useRef(!1),L=f(e=>{var t;if(!o||!u||!c||"Escape"!==e.key||I.current)return;let n=null==(t=s.current.floatingContext)?void 0:t.nodeId,i=w?P(w.nodesRef.current,n):[];if(!T&&(e.stopPropagation(),i.length>0)){let e=!0;if(i.forEach(t=>{var n;if(null!=(n=t.context)&&n.open&&!t.context.dataRef.current.__escapeKeyBubbles){e=!1;return}}),!e)return}a(!1,(0,r.isReactEvent)(e)?e.nativeEvent:e,"escape-key")}),N=f(e=>{var t;let n=()=>{var t;L(e),null==(t=(0,r.getTarget)(e))||t.removeEventListener("keydown",n)};null==(t=(0,r.getTarget)(e))||t.addEventListener("keydown",n)}),$=f(e=>{var t;let n=C.current;C.current=!1;let o=A.current;if(A.current=!1,"click"===m&&o||n||"function"==typeof E&&!E(e))return;let u=(0,r.getTarget)(e),c="["+x("inert")+"]",d=(0,r.getDocument)(l.floating).querySelectorAll(c),f=(0,i.isElement)(u)?u:null;for(;f&&!(0,i.isLastTraversableNode)(f);){let e=(0,i.getParentNode)(f);if((0,i.isLastTraversableNode)(e)||!(0,i.isElement)(e))break;f=e}if(d.length&&(0,i.isElement)(u)&&!(0,r.isRootElement)(u)&&!(0,r.contains)(u,l.floating)&&Array.from(d).every(e=>!(0,r.contains)(f,e)))return;if((0,i.isHTMLElement)(u)&&F){let t=u.clientWidth>0&&u.scrollWidth>u.clientWidth,n=u.clientHeight>0&&u.scrollHeight>u.clientHeight,r=n&&e.offsetX>u.clientWidth;if(n&&"rtl"===(0,i.getComputedStyle)(u).direction&&(r=e.offsetX<=u.offsetWidth-u.clientWidth),r||t&&e.offsetY>u.clientHeight)return}let g=null==(t=s.current.floatingContext)?void 0:t.nodeId,p=w&&P(w.nodesRef.current,g).some(t=>{var n;return(0,r.isEventTargetWithin)(e,null==(n=t.context)?void 0:n.elements.floating)});if((0,r.isEventTargetWithin)(e,l.floating)||(0,r.isEventTargetWithin)(e,l.domReference)||p)return;let h=w?P(w.nodesRef.current,g):[];if(h.length>0){let e=!0;
1if(h.forEach(t=>{var n;if(null!=(n=t.context)&&n.open&&!t.context.dataRef.current.__outsidePressBubbles){e=!1;return}}),!e)return}a(!1,e,"outside-press")}),O=f(e=>{var t;let n=()=>{var t;$(e),null==(t=(0,r.getTarget)(e))||t.removeEventListener(m,n)};null==(t=(0,r.getTarget)(e))||t.addEventListener(m,n)});n.useEffect(()=>{if(!o||!u)return;s.current.__escapeKeyBubbles=T,s.current.__outsidePressBubbles=M;let e=-1;function t(e){a(!1,e,"ancestor-scroll")}function n(){window.clearTimeout(e),I.current=!0}function d(){e=window.setTimeout(()=>{I.current=!1},5*!!(0,i.isWebKit)())}let f=(0,r.getDocument)(l.floating);c&&(f.addEventListener("keydown",R?N:L,R),f.addEventListener("compositionstart",n),f.addEventListener("compositionend",d)),E&&f.addEventListener(m,k?O:$,k);let g=[];return h&&((0,i.isElement)(l.domReference)&&(g=(0,i.getOverflowAncestors)(l.domReference)),(0,i.isElement)(l.floating)&&(g=g.concat((0,i.getOverflowAncestors)(l.floating))),!(0,i.isElement)(l.reference)&&l.reference&&l.reference.contextElement&&(g=g.concat((0,i.getOverflowAncestors)(l.reference.contextElement)))),(g=g.filter(e=>{var t;return e!==(null==(t=f.defaultView)?void 0:t.visualViewport)})).forEach(e=>{e.addEventListener("scroll",t,{passive:!0})}),()=>{c&&(f.removeEventListener("keydown",R?N:L,R),f.removeEventListener("compositionstart",n),f.removeEventListener("compositionend",d)),E&&f.removeEventListener(m,k?O:$,k),g.forEach(e=>{e.removeEventListener("scroll",t)}),window.clearTimeout(e)}},[s,l,c,E,m,o,a,h,u,T,M,L,R,N,$,k,O]),n.useEffect(()=>{C.current=!1},[E,m]);let B=n.useMemo(()=>({onKeyDown:L,[j[p]]:e=>{g&&a(!1,e.nativeEvent,"reference-press")}}),[L,a,g,p]),F=n.useMemo(()=>({onKeyDown:L,onMouseDown(){A.current=!0},onMouseUp(){A.current=!0},[D[m]]:()=>{C.current=!0}}),[L,m]);return n.useMemo(()=>u?{reference:B,floating:F}:{},[u,B,F])},"useFloating",0,function(e){void 0===e&&(e={});let{nodeId:t}=e,r=function(e){let{open:t=!1,onOpenChange:r,elements:o}=e,i=y(),a=n.useRef({}),[l]=n.useState(()=>{let e;return e=new Map,{emit(t,n){var r;null==(r=e.get(t))||r.forEach(e=>e(n))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var r;e.set(t,(null==(r=e.get(t))?void 0:r.filter(e=>e!==n))||[])}}}),s=null!=b(),[u,c]=n.useState(o.reference),d=f((e,t,n)=>{a.current.openEvent=e?t:void 0,l.emit("openchange",{open:e,event:t,reason:n,nested:s}),null==r||r(e,t,n)}),m=n.useMemo(()=>({setPositionReference:c}),[]),g=n.useMemo(()=>({reference:u||o.reference||null,floating:o.floating||null,domReference:o.reference}),[u,o.reference,o.floating]);return n.useMemo(()=>({dataRef:a,open:t,onOpenChange:d,elements:g,events:l,floatingId:i,refs:m}),[t,d,g,l,i,m])}({...e,elements:{reference:null,floating:null,...e.elements}}),o=e.rootContext||r,a=o.elements,[l,u]=n.useState(null),[c,d]=n.useState(null),g=(null==a?void 0:a.domReference)||l,p=n.useRef(null),h=n.useContext(S);m(()=>{g&&(p.current=g)},[g]);let v=(0,s.useFloating)({...e,elements:{...a,...c&&{reference:c}}}),w=n.useCallback(e=>{let t=(0,i.isElement)(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),contextElement:e}:e;d(t),v.refs.setReference(t)},[v.refs]),x=n.useCallback(e=>{((0,i.isElement)(e)||null===e)&&(p.current=e,u(e)),((0,i.isElement)(v.refs.reference.current)||null===v.refs.reference.current||null!==e&&!(0,i.isElement)(e))&&v.refs.setReference(e)},[v.refs]),E=n.useMemo(()=>({...v.refs,setReference:x,setPositionReference:w,domReference:p}),[v.refs,x,w]),C=n.useMemo(()=>({...v.elements,domReference:g}),[v.elements,g]),A=n.useMemo(()=>({...v,...o,refs:E,elements:C,nodeId:t}),[v,E,C,t,o]);return m(()=>{o.dataRef.current.floatingContext=A;let e=null==h?void 0:h.nodesRef.current.find(e=>e.id===t);e&&(e.context=A)}),n.useMemo(()=>({...v,context:A,refs:E,elements:C}),[v,E,C,A])},"useFocus",0,function(e,t){void 0===t&&(t={});let{open:o,onOpenChange:a,events:l,dataRef:s,elements:u}=e,{enabled:c=!0,visibleOnly:d=!0}=t,f=n.useRef(!1),m=n.useRef(),g=n.useRef(!0);n.useEffect(()=>{if(!c)return;let e=(0,i.getWindow)(u.domReference);function t(){!o&&(0,i.isHTMLElement)(u.domReference)&&u.domReference===(0,r.activeElement)((0,r.getDocument)(u.domReference))&&(f.current=!0)}function n(){g.current=!0}return e.addEventListener("blur",t),e.addEventListener("keydown",n,!0),()=>{e.removeEventListener("blur",t),e.removeEventListener("keydown",n,!0)}},[u.domReference,o,c]),n.useEffect(()=>{if(c)return l.on("openchange",e),()=>{l.off("openchange",e)};function e(e){let{reason:t}=e;("reference-press"===t||"escape-key"===t)&&(f.current=!0)}},[l,c]),n.useEffect(()=>()=>{clearTimeout(m.current)},[]);let p=n.useMemo(()=>({onPointerDown(e){(0,r.isVirtualPointerEvent)(e.nativeEvent)||(g.current=!1)},onMouseLeave(){f.current=!1},onFocus(e){if(f.current)return;let t=(0,r.getTarget)(e.nativeEvent);if(d&&(0,i.isElement)(t))try{if((0,r.isSafari)()&&(0,r.isMac)())throw Error();if(!t.matches(":focus-visible"))return}catch(e){if(!g.current&&!(0,r.isTypeableElement)(t))return}a(!0,e.nativeEvent,"focus")},onBlur(e){f.current=!1;let t=e.relatedTarget,n=e.nativeEvent,o=(0,i.isElement)(t)&&t.hasAttribute(x("focus-guard"))&&"outside"===t.getAttribute("data-type");m.current=window.setTimeout(()=>{var e;let i=(0,r.activeElement)(u.domReference?u.domReference.ownerDocument:document);!t&&i===u.domReference||(0,r.contains)(null==(e=s.current.floatingContext)?void 0:e.refs.floating.current,i)||(0,r.contains)(u.domReference,i)||o||a(!1,n,"focus")})}}),[s,u.domReference,a,d]);return n.useMemo(()=>c?{reference:p}:{},[c,p])},"useHover",0,function(e,t){void 0===t&&(t={});let{open:o,onOpenChange:a,dataRef:l,events:s,elements:u}=e,{enabled:c=!0,delay:d=0,handleClose:g=null,mouseOnly:p=!1,restMs:h=0,move:v=!0}=t,y=n.useContext(S),w=b(),x=E(g),P=E(d),T=E(o),M=n.useRef(),R=n.useRef(-1),k=n.useRef(),I=n.useRef(-1),L=n.useRef(!0),N=n.useRef(!1),$=n.useRef(()=>{}),O=n.useRef(!1),j=n.useCallback(()=>{var e;let t=null==(e=l.current.openEvent)?void 0:e.type;return(null==t?void 0:t.includes("mouse"))&&"mousedown"!==t},[l]);n.useEffect(()=>{if(c)return s.on("openchange",e),()=>{s.off("openchange",e)};function e(e){let{open:t}=e;t||(clearTimeout(R.current),clearTimeout(I.current),L.current=!0,O.current=!1)}},[c,s]),n.useEffect(()=>{if(!c||!x.current||!o)return;function e(e){j()&&a(!1,e,"hover")}let t=(0,r.getDocument)(u.floating).documentElement;return t.addEventListener("mouseleave",e),()=>{t.removeEventListener("mouseleave",e)}},[u.floating,o,a,c,x,j]);let D=n.useCallback(function(e,t,n){void 0===t&&(t=!0),void 0===n&&(n="hover");let r=A(P.current,"close",M.current);r&&!k.current?(clearTimeout(R.current),R.current=window.setTimeout(()=>
1a(!1,e,n),r)):t&&(clearTimeout(R.current),a(!1,e,n))},[P,a]),H=f(()=>{$.current(),k.current=void 0}),B=f(()=>{if(N.current){let e=(0,r.getDocument)(u.floating).body;e.style.pointerEvents="",e.removeAttribute(C),N.current=!1}}),F=f(()=>!!l.current.openEvent&&["click","mousedown"].includes(l.current.openEvent.type));n.useEffect(()=>{if(c&&(0,i.isElement)(u.domReference)){var e;let r=u.domReference;return o&&r.addEventListener("mouseleave",s),null==(e=u.floating)||e.addEventListener("mouseleave",s),v&&r.addEventListener("mousemove",t,{once:!0}),r.addEventListener("mouseenter",t),r.addEventListener("mouseleave",n),()=>{var e;o&&r.removeEventListener("mouseleave",s),null==(e=u.floating)||e.removeEventListener("mouseleave",s),v&&r.removeEventListener("mousemove",t),r.removeEventListener("mouseenter",t),r.removeEventListener("mouseleave",n)}}function t(e){if(clearTimeout(R.current),L.current=!1,p&&!(0,r.isMouseLikePointerType)(M.current)||h>0&&!A(P.current,"open"))return;let t=A(P.current,"open",M.current);t?R.current=window.setTimeout(()=>{T.current||a(!0,e,"hover")},t):o||a(!0,e,"hover")}function n(e){if(F())return;$.current();let t=(0,r.getDocument)(u.floating);if(clearTimeout(I.current),O.current=!1,x.current&&l.current.floatingContext){o||clearTimeout(R.current),k.current=x.current({...l.current.floatingContext,tree:y,x:e.clientX,y:e.clientY,onClose(){B(),H(),F()||D(e,!0,"safe-polygon")}});let n=k.current;t.addEventListener("mousemove",n),$.current=()=>{t.removeEventListener("mousemove",n)};return}"touch"===M.current&&(0,r.contains)(u.floating,e.relatedTarget)||D(e)}function s(e){F()||l.current.floatingContext&&(null==x.current||x.current({...l.current.floatingContext,tree:y,x:e.clientX,y:e.clientY,onClose(){B(),H(),F()||D(e)}})(e))}},[u,c,e,p,h,v,D,H,B,a,o,T,y,P,x,l,F]),m(()=>{var e,t;if(c&&o&&null!=(e=x.current)&&e.__options.blockPointerEvents&&j()){N.current=!0;let e=u.floating;if((0,i.isElement)(u.domReference)&&e){let n=(0,r.getDocument)(u.floating).body;n.setAttribute(C,"");let o=u.domReference,i=null==y||null==(t=y.nodesRef.current.find(e=>e.id===w))||null==(t=t.context)?void 0:t.elements.floating;return i&&(i.style.pointerEvents=""),n.style.pointerEvents="none",o.style.pointerEvents="auto",e.style.pointerEvents="auto",()=>{n.style.pointerEvents="",o.style.pointerEvents="",e.style.pointerEvents=""}}}},[c,o,w,u,y,x,j]),m(()=>{o||(M.current=void 0,O.current=!1,H(),B())},[o,H,B]),n.useEffect(()=>()=>{H(),clearTimeout(R.current),clearTimeout(I.current),B()},[c,u.domReference,H,B]);let _=n.useMemo(()=>{function e(e){M.current=e.pointerType}return{onPointerDown:e,onPointerEnter:e,onMouseMove(e){let{nativeEvent:t}=e;function n(){L.current||T.current||a(!0,t,"hover")}p&&!(0,r.isMouseLikePointerType)(M.current)||o||0===h||O.current&&e.movementX**2+e.movementY**2<2||(clearTimeout(I.current),"touch"===M.current?n():(O.current=!0,I.current=window.setTimeout(n,h)))}}},[p,a,o,T,h]),U=n.useMemo(()=>({onMouseEnter(){clearTimeout(R.current)},onMouseLeave(e){F()||D(e.nativeEvent,!1)}}),[D,F]);return n.useMemo(()=>c?{reference:_,floating:U}:{},[c,_,U])},"useInnerOffset",0,function(e,t){let{open:o,elements:i}
1=e,{enabled:a=!0,overflowRef:s,scrollRef:u,onChange:c}=t,d=f(c),m=n.useRef(!1),g=n.useRef(null),p=n.useRef(null);n.useEffect(()=>{if(!a)return;function e(e){if(e.ctrlKey||!t||null==s.current)return;let n=e.deltaY,o=s.current.top>=-.5,i=s.current.bottom>=-.5,a=t.scrollHeight-t.clientHeight,u=n<0?-1:1,c=n<0?"max":"min";!(t.scrollHeight<=t.clientHeight)&&(!o&&n>0||!i&&n<0?(e.preventDefault(),l.flushSync(()=>{d(e=>e+Math[c](n,a*u))})):/firefox/i.test((0,r.getUserAgent)())&&(t.scrollTop+=n))}let t=(null==u?void 0:u.current)||i.floating;if(o&&t)return t.addEventListener("wheel",e),requestAnimationFrame(()=>{g.current=t.scrollTop,null!=s.current&&(p.current={...s.current})}),()=>{g.current=null,p.current=null,t.removeEventListener("wheel",e)}},[a,o,i.floating,s,u,d]);let h=n.useMemo(()=>({onKeyDown(){m.current=!0},onWheel(){m.current=!1},onPointerMove(){m.current=!1},onScroll(){let e=(null==u?void 0:u.current)||i.floating;if(s.current&&e&&m.current){if(null!==g.current){let t=e.scrollTop-g.current;(s.current.bottom<-.5&&t<-1||s.current.top<-.5&&t>1)&&l.flushSync(()=>d(e=>e+t))}requestAnimationFrame(()=>{g.current=e.scrollTop})}}}),[i.floating,d,s,u]);return n.useMemo(()=>a?{floating:h}:{},[a,h])},"useInteractions",0,function(e){void 0===e&&(e=[]);let t=e.map(e=>null==e?void 0:e.reference),r=e.map(e=>null==e?void 0:e.floating),o=e.map(e=>null==e?void 0:e.item),i=n.useCallback(t=>_(t,e,"reference"),t),a=n.useCallback(t=>_(t,e,"floating"),r),l=n.useCallback(t=>_(t,e,"item"),o);return n.useMemo(()=>({getReferenceProps:i,getFloatingProps:a,getItemProps:l}),[i,a,l])},"useMergeRefs",0,function(e){return n.useMemo(()=>e.every(e=>null==e)?null:t=>{e.forEach(e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)})},e)},"useRole",0,function(e,t){var r;void 0===t&&(t={});let{open:o,floatingId:i}=e,{enabled:a=!0,role:l="dialog"}=t,s=null!=(r=U.get(l))?r:l,u=y(),c=null!=b(),d=n.useMemo(()=>"tooltip"===s||"label"===l?{["aria-"+("label"===l?"labelledby":"describedby")]:o?i:void 0}:{"aria-expanded":o?"true":"false","aria-haspopup":"alertdialog"===s?"dialog":s,"aria-controls":o?i:void 0,..."listbox"===s&&{role:"combobox"},..."menu"===s&&{id:u},..."menu"===s&&c&&{role:"menuitem"},..."select"===l&&{"aria-autocomplete":"none"},..."combobox"===l&&{"aria-autocomplete":"list"}},[s,i,c,o,u,l]),f=n.useMemo(()=>{let e={id:i,...s&&{role:s}};return"tooltip"===s||"label"===l?e:{...e,..."menu"===s&&{"aria-labelledby":u}}},[s,i,u,l]),m=n.useCallback(e=>{let{active:t,selected:n}=e,r={role:"option",...t&&{id:i+"-option"}};switch(l){case"select":return{...r,"aria-selected":t&&n};case"combobox":return{...r,...t&&{"aria-selected":!0}}}return{}},[i,l]);return n.useMemo(()=>a?{reference:d,floating:f,item:m}:{},[a,d,f,m])}])},787255,e=>{"use strict";var t=e.i(843476),n=e.i(271645),r=e.i(543489),o=e.i(953760),i=e.i(258950);e.s(["AdminToolTip",0,({children:e,content:a,placement:l="top",delay:s=0,offset:u=8,disabled:c=!1})=>{let[d,f]=(0,n.useState)(!1),{refs:m,floatingStyles:g,context:p}=(0,r.useFloating)({open:d,onOpenChange:f,placement:l,whileElementsMounted:o.autoUpdate,middleware:[(0,i.offset)(u),(0,i.flip)(),(0,i.shift)({padding:5})]}),h=(0,r.useHover)(p,{delay:"number"==typeof s?s:0,enabled:!c}),v=(0,r.useFocus)(p,{enabled:!c}),y=(0,r.useDismiss)(p),w=(0,r.useRole)(p,{role:"tooltip"}),{getReferenceProps:S,getFloatingProps:b}=(0,r.useInteractions)([h,v,y,w]),x=(0,n.isValidElement)(e)?(0,n.cloneElement)(e,S({ref:m.setReference})):(0,t.jsx)("span",{ref:m.setReference,...S(),children:e});return(0,t.jsxs)(t.Fragment,{children:[x,d&&a&&(0,t.jsx)(r.FloatingPortal,{children:(0,t.jsx)("div",{ref:m.setFloating,style:g,...b(),className:"z-9999 max-w-72 rounded-md bg-tcc-dark px-3 py-2 text-sm leading-snug text-left text-tcc-darktext shadow-lg",children:a})})]})}])},631926,(e,t,n)=>{var r=e.r(139088);t.exports=function(){return r.Date.now()}},748891,(e,t,n)=>{var r=/\s/;t.exports=function(e){for(var t=e.length;t--&&r.test(e.charAt(t)););return t}},830364,(e,t,n)=>{var r=e.r(748891),o=/^\s+/;t.exports=function(e){return e?e.slice(0,r(e)+1).replace(o,""):e}},773759,(e,t,n)=>{var r=e.r(830364),o=e.r(12447),i=e.r(361884),a=0/0,l=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,u=/^0o[0-7]+$/i,c=parseInt;t.exports=function(e){if("number"==typeof e)return e;if(i(e))return a;
1if(o(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=r(e);var n=s.test(e);return n||u.test(e)?c(e.slice(2),n?2:8):l.test(e)?a:+e}},374009,(e,t,n)=>{var r=e.r(12447),o=e.r(631926),i=e.r(773759),a=Math.max,l=Math.min;t.exports=function(e,t,n){var s,u,c,d,f,m,g=0,p=!1,h=!1,v=!0;if("function"!=typeof e)throw TypeError("Expected a function");function y(t){var n=s,r=u;return s=u=void 0,g=t,d=e.apply(r,n)}function w(e){var n=e-m,r=e-g;return void 0===m||n>=t||n<0||h&&r>=c}function S(){var e,n,r,i=o();if(w(i))return b(i);f=setTimeout(S,(e=i-m,n=i-g,r=t-e,h?l(r,c-n):r))}function b(e){return(f=void 0,v&&s)?y(e):(s=u=void 0,d)}function x(){var e,n=o(),r=w(n);if(s=arguments,u=this,m=n,r){if(void 0===f)return g=e=m,f=setTimeout(S,t),p?y(e):d;if(h)return clearTimeout(f),f=setTimeout(S,t),y(m)}return void 0===f&&(f=setTimeout(S,t)),d}return t=i(t)||0,r(n)&&(p=!!n.leading,c=(h="maxWait"in n)?a(i(n.maxWait)||0,t):c,v="trailing"in n?!!n.trailing:v),x.cancel=function(){void 0!==f&&clearTimeout(f),g=0,s=m=u=f=void 0},x.flush=function(){return void 0===f?d:b(o())},x}},224283,(e,t,n)=>{var r=e.r(374009),o=e.r(12447);t.exports=function(e,t,n){var i=!0,a=!0;if("function"!=typeof e)throw TypeError("Expected a function");return o(n)&&(i="leading"in n?!!n.leading:i,a="trailing"in n?!!n.trailing:a),r(e,t,{leading:i,maxWait:t,trailing:a})}},208509,532072,673849,e=>{"use strict";e.s(["AdminSaveModelContextButton",()=>M,"AdminSpinner",()=>T,"ModelContext",()=>x,"ModelContextContextProvider",()=>P,"maybeUseModelContext",()=>A,"useModelContext",()=>C],208509);var t=e.i(843476),n=e.i(761978),r=e.i(796440),o=e.i(787255),i=e.i(489578),a=e.i(271645);let l={page:"Page",blogpost:"Blog Post",event:"Event",episode:"Episode",contributor:"Contributor",series:"Series",channel:"Channel",campus:"Campus",noteoutline:"Note Outline",group:"Group",form:"Form",redirect:"Redirect",menu:"Menu"};function s(e){let t="string"==typeof e?.type?e.type.toLowerCase():null;return t&&t in l?t:null}e.s(["ACTIVE_ITEM_MODELS",0,l,"SITE_SETTING_MODELS",0,{header:"Site Header",footer:"Site Footer",seo:"Global SEO",metatags:"Meta Tags",brand:"Brand",customcss:"Custom CSS"},"activeItemModelFromRecord",0,s],532072);let u=new Map,c=new Set,d=null;function f(){let e=null;for(let t of u.values())e=t;return e}function m(){var e;let t,n=(t=f()?.current)?{model:t.model,label:l[t.model]??t.model,id:String(t.id),title:t.title,hasUnsavedChanges:!!t.hasUnsavedChanges}:null;
1if((e=d)!==n&&(!e||!n||e.model!==n.model||e.id!==n.id||e.title!==n.title||e.hasUnsavedChanges!==n.hasUnsavedChanges))for(let e of(d=n,c))e()}let g={register(e,t){u.set(e,t),m()},unregister(e){u.delete(e),m()},notify(){m()},getSnapshot:()=>f()?.current??null,subscribe:e=>(c.add(e),()=>c.delete(e))},p=()=>d,h=()=>null;e.s(["activeItemBridge",0,g,"useActiveItemBadge",0,function(){return(0,a.useSyncExternalStore)(g.subscribe,p,h)}],673849);var v=e.i(667408),y=e.i(482820),w=e.i(348707),S=e.i(224283),b=e.i(993675);let x=(0,a.createContext)(null),E=e=>{let t=(0,b.deepClone)(e);return"string"!=typeof t?.content&&(Array.isArray(t?.content)||Array.isArray(t?.content?.blocks))&&(0,w.default)(t,"content",(0,b.hydrateUniqueBlockIds)(t.content)),t},C=()=>{let e=(0,a.useContext)(x);if(!e)throw Error("ModelContext is missing context");return e},A=()=>(0,a.useContext)(x),P=({children:e,brand:n,activeItem:i,role:l,network:u=!1,onSave:c})=>{let{setNotice:d}=(0,v.useProxyContext)(),[f,m]=(0,a.useState)(!1),[p,h]=(0,a.useState)(),[C,A]=(0,a.useState)(!1),P=(0,a.useRef)(0),T=(0,a.useRef)(null),M=(0,a.useRef)(null),R=(0,a.useRef)(null),k=(0,a.useRef)({}),I=(0,a.useCallback)((e,t)=>{T.current=e,P.current=t,0===t&&(R.current=JSON.stringify((0,b.pruneEmpty)(e[0])))},[]),L=(0,a.useMemo)(()=>(0,S.default)((e,t)=>{I(e,t)},1e3),[I]),N=(0,a.useCallback)(e=>{let t=(0,b.indexPathsById)(e);return k.current=t,t},[]),$=(0,a.useCallback)((e,t)=>{let n=(0,y.default)(k.current,t),r=(0,y.default)(e,n);return r?.id!==t?N(e)[t]:n},[N]),O=(0,a.useCallback)((e,t)=>{"function"==typeof e?h(t=>{let n=e(JSON.parse(JSON.stringify(t)));if(JSON.stringify(t)!==JSON.stringify(n)){let e=T.current?[...T.current]:[];e.push(n),L(e,P.current+1),d("You have unsaved changes. Are you sure you want to leave?"),A(!0)}return R.current===JSON.stringify((0,b.pruneEmpty)(n))&&(d(null),A(!1)),n}):h(n=>{let r=JSON.parse(JSON.stringify(n));if(r[e]=t,JSON.stringify(n)!==JSON.stringify(r)){let e=T.current?[...T.current]:[];e.push(r),L(e,P.current+1),d("You have unsaved changes. Are you sure you want to leave?"),A(!0)}return R.current===JSON.stringify((0,b.pruneEmpty)(r))&&(d(null),A(!1)),r})},[L,d]),j=(0,a.useCallback)((e,t)=>{O(n=>{let r=$(n,e);if(!r)return n;let o=(0,b.deepClone)(n);return(0,w.default)(o,r,t),o})},[$,O]),D=(0,a.useCallback)((e,t)=>{O(n=>{let r=JSON.parse(JSON.stringify(n));return r?.meta||(r.meta={}),(0,w.default)(r.meta,e,t),r})},[O]),H=(0,a.useCallback)(()=>{i&&(h(E(i)),d(null),A(!1))},[i,d]),B=(0,a.useCallback)(e=>{h(E({...e.fields,id:e.modelId}))},[]),F=(0,a.useCallback)(()=>{let e=P.current-1;e<0||(h(T.current[e]),P.current=e,0===e&&(d(null),A(!1)))},[d]),_=(0,a.useCallback)(()=>{let e=P.current+1;e>=T.current?.length||(h(T.current[e]),P.current=e,d("You have unsaved changes. Are you sure you want to leave?"),A(!0))},[]),U=(0,a.useCallback)(()=>(0,t.jsxs)("div",{"data-version-control":!0,className:"flex space-x-2 mr-2",children:[P.current>0&&(0,t.jsx)(o.AdminToolTip,{content:"Undo",children:(0,t.jsx)("button",{type:"button","aria-label":"Undo change",onClick:F,className:"rounded-md p-2 group hover:cursor-pointer hover:bg-tcc-alt",children:(0,t.jsx)(r.TCCUndoIcon,{className:"h-4 w-4 text-tcc-basetext/50"})})}),P.current<T.current?.length-1?(0,t.jsx)(o.AdminToolTip,{content:"Redo",children:(0,t.jsx)("button",{type:"button","aria-label":"Redo change",onClick:_,className:" rounded-lg p-2 mr-1 inline-block group hover:cursor-pointer hover:bg-tcc-alt",children:(0,t.jsx)(r.TCCRedoIcon,{className:"h-4 w-4 text-tcc-basetext/50"})})}):(0,t.jsx)("button",{type:"button","aria-label":"Redo change",disabled:!0,tabIndex:-1,className:" rounded-lg p-2 mr-1 inline-block opacity-0 group",children:(0,t.jsx)(r.TCCRedoIcon,{className:"h-4 w-4 text-tcc-basetext/50"})})]}),[F,_]),W=(0,a.useCallback)(()=>{d(null),A(!1)},[d]),G=(0,a.useCallback)(e=>{M.current=e},[]),V=(0,a.useCallback)(()=>{let e=M.current||c;e&&e()},[c]);(0,b.useSaveDetector)(V),(0,b.useUndoRedoDetector)(F,_),(0,a.useEffect)(()=>{if(!i)return;let e=E(i);h(e),I([e],0),d(null),A(!1)},[i?.id]);let q=s(i),z=q&&p?.id!=null?`${q}:${i?.id}`:null,K=p?.name||p?.title||"Untitled",Y=(0,a.useRef)(null);Y.current=q?{model:q,id:String(i?.id??""),title:K,hasUnsavedChanges:C,getChanges:()=>p,setField:O}:null,(0,a.useEffect)(()=>
1{if(z)return g.register(z,Y),()=>g.unregister(z)},[z]),(0,a.useEffect)(()=>{z&&g.notify()},[z,K,C]),(0,a.useEffect)(()=>{f||m(!0)},[f]);let J=(0,a.useMemo)(()=>({changes:p,setChanges:h,setField:O,setMeta:D,revertChanges:H,activeItem:i,renderVersionControl:U,previewRevision:B,brand:n,network:u,onSaveSuccess:W,role:l,registerSaveHandler:G,setFieldItem:j,hasUnsavedChanges:C}),[p,h,O,D,H,i,U,B,n,u,W,l,G,j,C]);return(0,t.jsx)(x.Provider,{"data-model-provider":!0,value:J,children:f&&e})},T=()=>(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("svg",{className:"animate-spin -ml-1 mr-3 h-5 w-5 text-current",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[(0,t.jsx)("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),(0,t.jsx)("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]})}),M=({onClick:e,loading:r,children:l})=>{let[s,u]=(0,a.useState)(!1),{registerSaveHandler:c}=A()||{},{hasPendingWork:d,pendingTasks:f}=(0,i.useAdminUIContext)(),m=(0,a.useCallback)(()=>{d||e?.()},[d,e]);(0,a.useEffect)(()=>{!0===r?setTimeout(()=>u(!0),100):u(!1)},[r]),(0,a.useEffect)(()=>{c&&e&&c(m)},[c,e,m]);let g=(0,t.jsxs)(n.AdminButtonPrimary,{disabled:d,onClick:m,className:`flex ${d?"cursor-not-allowed":"hover:cursor-pointer"}`,children:[s&&r&&(0,t.jsx)(T,{}),(0,t.jsx)("span",{children:l})]});return d?(0,t.jsx)(o.AdminToolTip,{content:`Waiting for: ${f.map(e=>e.label).join(", ")}`,children:g}):g}},65781,e=>{"use strict";e.s(["useAddTags",()=>h,"useBulkUpdate",()=>y,"useCreate",()=>a,"useDelete",()=>f,"useDuplicate",()=>d,"useForceDelete",()=>v,"useGet",()=>c,"useImport",()=>l,"useReplaceTags",()=>p,"useRestore",()=>m,"useRevisions",()=>g,"useSearch",()=>u,"useUpdate",()=>s]);var t=e.i(489578),n=e.i(276495),r=e.i(730059),o=e.i(208509),i=e.i(271645);let a=e=>{let[t,o]=(0,i.useState)(!1),[a,l]=(0,i.useState)(null),[s,u]=(0,i.useState)(null),[c,d]=(0,i.useState)(null),f=(0,n.usePublicSession)();return{loading:t,runCreate:async(t,n="admin")=>{o(!0),u(null);let i="admin"===n?(0,r.getSessionCookie)():f(),a=await e(t,i);return a&&a?.status==="success"?(d("Your info has been updated."),o(!1)):(l(null),a?.message?u(a.message):a?.error&&u(a?.error),o(!1),d(null)),a},session:a,error:s,message:c}},l=e=>{let[t,n]=(0,i.useState)(!1),[o,a]=(0,i.useState)(null),[l,s]=(0,i.useState)(null),[u,c]=(0,i.useState)(null),[d,f]=(0,i.useState)(null);return{loading:t,runImport:async t=>{n(!0),s(null);let o=(0,r.getSessionCookie)(),i=await e(t,o);return i?.status==="success"?(c("Your info has be imported."),n(!1),f(i?.data)):(a(null),i?.message?s(i.message):i?.error&&s(i?.error),n(!1),c(null)),i},session:o,error:l,message:u,item:d}},s=(e,a={})=>{let[l,s]=(0,i.useState)(!1),[u,c]=(0,i.useState)(null),[d,f]=(0,i.useState)(null),{setToast:m}=(0,t.useAdminUIContext)(),{onSaveSuccess:g}=(0,o.useModelContext)(),p=(0,n.usePublicSession)(),[h,v]=(0,i.useState)(!1),[y,w]=(0,i.useState)(!1);return(0,i.useEffect)(()=>{!d||h&&(m({open:!0,variant:"success",title:"Update successful",description:d,autoClose:!0}),setTimeout(()=>v(!1),4e3))},[h]),(0,i.useEffect)(()=>{!u||y&&(m({open:!0,variant:"error",title:"Something went wrong",description:u,autoClose:!0}),setTimeout(()=>w(!1),4e3))},[y]),{loading:l,runUpdate:async(t,n,o="admin")=>{s(!0),c(null);let i="admin"===o?(0,r.getSessionCookie)():p(),l=await e(t,n,i);return l?.status==="success"?(f("Your info has been updated."),a?.hideToast||v(!0),s(!1),g()):(l?.message?c(l.message):l?.error&&c(l?.error),s(!1),f(null),a?.hideToast||w(!0)),l},error:u,message:d}},u=e=>{let[t,o]=(0,i.useState)(!1),[a,l]=(0,i.useState)(null),[s,u]=(0,i.useState)(null),[c,d]=(0,i.useState)(null),[f,m]=(0,i.useState)(0),[g,p]=(0,i.useState)([]),h=(0,n.usePublicSession)();return{loading:t,runSearch:(0,i.useCallback)(async({page:t,limit:n,search:i,view:a,args:s},c=null,f="admin")=>{o(!0),u(null);let g="admin"===f?(0,r.getSessionCookie)():h(),v=await e({page:t,limit:n,search:i,view:a,args:s},c,g);return v?(v?.status==="success"?(d("Your info has been updated."),o(!1),m(v?.data?.count),p(v?.data?.rows)):(l(null),v?.message?u(v.message):v?.error&&u(v?.error),o(!1),d(null)),v):void o(!1)},[e,h]),session:a,error:s,message:c,total:f,data:g}},c=e=>{let[t,o]=(0,i.useState)(!1),[a,l]=(0,i.useState)(null),[s,u]=(0,i.useState)(null),[c,d]=(0,i.useState)(null),[f,m]=(0,i.useState)(0),[g,p]=(0,i.useState)([]),h=(0,n.usePublicSession)();return{loading:t,runGet:(0,i.useCallback)(async(t,n=null,i="admin")=>{o(!0),u(null);let a="admin"===i?(0,r.getSessionCookie)():h(),s=await e(t,n,a);return s?(s?.status==="success"?(d("Found."),o(!1),p(s?.data)):(l(null),s?.message?u(s.message):s?.error&&u(s?.error),o(!1),d(null)),s):void o(!1)},[e,h]),session:a,error:s,message:c,total:f,data:g}},d=e=>{let[o,a]=(0,i.useState)(!1),[l,s]=(0,i.useState)(null),[u,c]=(0,i.useState)(null),{toast:d,setToast:f}=(0,t.useAdminUIContext)(),m=(0,n.usePublicSession)();return(0,i.useEffect)(()=>{u&&f({open:!0,variant:"success",title:"Duplicate successful",description:u,autoClose:!0})},[u]),(0,i.useEffect)(()=>{l&&f({open:!0,variant:"error",title:"Something went wrong",description:l,autoClose:!0})},[l]),{loading:o,runDuplicate:async(t,n="admin")=>{a(!0),s(null);let o="admin"===n?(0,r.getSessionCookie)():m(),i=await e(t,o);return i?.status==="success"?(c("Your info has been updated."),a(!1)):(i?.message?s(i.message):i?.error&&s(i?.error),a(!1),c(null)),i},error:l,message:u}},f=e=>{let[o,a]=(0,i.useState)(!1),[l,s]=(0,i.useState)(null),[u,c]=(0,i.useState)(null),{toast:d,setToast:f}=(0,t.useAdminUIContext)(),m=(0,n.usePublicSession)();return(0,i.useEffect)(()=>{u&&f({open:!0,variant:"success",title:"Delete successful",description:u,autoClose:!0})},[u]),(0,i.useEffect)(()=>{l&&f({open:!0,variant:"error",title:"Something went wrong",description:l,autoClose:!0})},[l]),{loading:o,runDelete:async(t,n="admin")=>{a(!0),s(null);let o="admin"===n?(0,r.getSessionCookie)():m(),i=await e(t,o);return i?.status==="success"?(c("Your info has been updated."),a(!1)):(i?.message?s(i.message):i?.error&&s(i?.error),a(!1),c(null)),i},error:l,message:u}},m=e=>{let[o,a]=(0,i.useState)(!1),[l,s]=(0,i.useState)(null),[u,c]=(0,i.useState)(null),{toast:d,setToast:f}=(0,t.useAdminUIContext)(),m=(0,n.usePublicSession)();return(0,i.useEffect)(()=>{u&&f({open:!0,variant:"success",title:"Restore successful",description:u,autoClose:!0})},[u]),(0,i.useEffect)(()=>{l&&f({open:!0,variant:"error",title:"Something went wrong",description:l,autoClose:!0})},[l]),{loading:o,runRestore:async(t,n="admin")=>{a(!0),s(null);let o="admin"===n?(0,r.getSessionCookie)():m(),i=await e(t,o);return i?.status==="success"?(c("Your info has been updated."),a(!1)):(i?.message?s(i.message):i?.error&&s(i?.error),a(!1),c(null)),i},error:l,message:u}},g=e=>{let[t,o]=(0,i.useState)(!1),[a,l]=(0,i.useState)(null),[s,u]=(0,i.useState)(null),[c,d]=(0,i.useState)(null),[f,m]=(0,i.useState)(0),[g,p]=(0,i.useState)([]),h=(0,n.usePublicSession)();return{loading:t,runGetRevisions:async(t,n="admin")=>{o(!0),u(null);let i="admin"===n?(0,r.getSessionCookie)():h(),a=await e(t,i);return a?.status==="success"?(d("Your info has been updated."),o(!1),m(a?.data?.count),p(a?.data?.rows)):(l(null),a?.message?u(a.message):a?.error&&u(a?.error),o(!1),d(null)),a},session:a,error:s,message:c,total:f,data:g}},p=e=>{let[t,n]=(0,i.useState)(!1),[o,a]=(0,i.useState)(null),[l,s]=(0,i.useState)(null),[u,c]=(0,i.useState)(null);return{loading:t,runReplace:async(t,o,i)=>{n(!0),s(null);let l=(0,r.getSessionCookie)(),u=await e(t,o,i,l);return u?.status==="success"?(c("Your info has been updated."),n(!1)):(a(null),u?.message?s(u.message):u?.error&&s(u?.error),n(!1),c(null)),u},session:o,error:l,message:u}},h=e=>{let[t,n]=(0,i.useState)(!1),[o,a]=(0,i.useState)(null),[l,s]=(0,i.useState)(null),[u,c]=(0,i.useState)(null);return{loading:t,runAddTags:async(t,o,i)=>{n(!0),s(null);let l=(0,r.getSessionCookie)(),u=await e(t,o,i,l);return u?.status==="success"?(c("Your info has been updated."),n(!1)):(a(null),u?.message?s(u.message):u?.error&&s(u?.error),n(!1),c(null)),u},session:o,error:l,message:u}},v=e=>{let[n,o]=(0,i.useState)(!1),[a,l]=(0,i.useState)(null),[s,u]=(0,i.useState)(null),{toast:c,setToast:d}=(0,t.useAdminUIContext)();return(0,i.useEffect)(()=>{s&&d({open:!0,variant:"success",title:"Deleted successfully",description:s,autoClose:!0})},[s]),(0,i.useEffect)(()=>{a&&d({open:!0,variant:"error",title:"Something went wrong",description:a,autoClose:!0})},[a]),{loading:n,runForceDelete:async t=>{o(!0),l(null);let n=(0,r.getSessionCookie)(),i=await e(t,n);return i?.status==="success"?(u("Your info has been updated."),o(!1)):(i?.message?l(i.message):i?.error&&l(i?.error),o(!1),u(null)),i},error:a,message:s}},y=e=>{let[t,o]=(0,i.useState)(!1),a=(0,n.usePublicSession)();return{loading:t,runUpdate:async(t,n,i="admin")=>{o(!0);let l="admin"===i?(0,r.getSessionCookie)():a(),s=await e(t,n,l);return o(!1),s}}}},370771,127528,e=>{"use strict";e.s(["useAccountSettingRevision",()=>P,"useCreateAccountSetting",()=>A,"useDeleteAccountSetting",()=>E,"useGetAccountSettingByType",()=>R,"useGetAccountSettings",()=>T,"useImportAccountSetting",()=>M,"useRestoreAccountSetting",()=>C,"useSearchAccountSettings",()=>b,"useUpdateAccountSetting",()=>x,"withRevalidateSettings",()=>k],370771);var t=e.i(276495),n=e.i(78435),r=e.i(26314),o=e.i(65781),i=e.i(152480),a=e.i(175658),l=e.i(271645);let s="/v1/accountsetting",u=async({page:e,limit:t,search:n,view:r,args:o},i,l)=>(0,a.searchModels)(s,{page:e,limit:t,search:n,view:r,args:o},i,l),c=async(e,t,n)=>(0,a.getModel)(s,e,t,n),d=async(e,t,n)=>(0,a.updateModel)(s,e,t,null,n),f=async(e,t)=>(0,a.duplicateModel)(s,e,null,t),m=async(e,t)=>(0,a.deleteModel)(s,e,null,t),g=async(e,t)=>(0,a.restoreModel)(s,e,null,t),p=async(e,t)=>(0,a.createModel)(s,e,null,t),h=(e,t)=>(0,a.getRevisions)(s,e,"no-store",t),v=async(e,t)=>(0,a.importModel)(s,e,null,t),y=(0,l.cache)(async(e,t,n=[])=>{try{let r={};n.length>0&&(r.tags=n,r.revalidate=900);let o=`[${e.join(",")}]`,a=await (0,i.APIGet)(`${i.APIBase}${s}/multiple?settingType=${o}`,null,null,t?.token,{next:r});return await a.json()}catch(e){return e}}),w=async(e,t,n)=>{try{let o=e.map(e=>`"${e}"`),i=n?[(0,r.getAccountCacheTag)(r.SETTINGS_CACHE_TAG,n)]:[],a=await y(o,t,i);if(a?.status!=="success")throw"Get Settings Failed";return a?.data?.rows?.reduce((e,t)=>
1({...e||{},[t.name]:t}),{})}catch(e){return(0,i.APIErrorHandler)(e),{}}},S=async(e,t,n=!1)=>{try{let r={settingType:`["${e}"]`};n&&(r.private=!0);let o=await u({page:0,limit:1,args:r},null,t);if(o&&o?.status==="success"&&o?.data?.count>0)return o?.data?.rows[0]}catch(e){(0,i.APIErrorHandler)(e)}};e.s(["createSetting",0,p,"deleteSetting",0,m,"duplicateSetting",0,f,"findMultipleSettings",0,w,"getSetting",0,c,"getSettingByType",0,S,"getSettingRevision",0,h,"importSetting",0,v,"restoreSetting",0,g,"searchSettings",0,u,"updateSetting",0,d],127528);let b=()=>(0,o.useSearch)(u),x=e=>(0,o.useUpdate)(d,e),E=()=>(0,o.useDelete)(m),C=()=>(0,o.useRestore)(g),A=()=>(0,o.useCreate)(p),P=()=>(0,o.useRevisions)(h),T=()=>(0,o.useGet)(c),M=()=>(0,o.useImport)(v),R=()=>{let[e,n]=(0,l.useState)(!1),[r,o]=(0,l.useState)(null),[i,a]=(0,l.useState)(null),[s,u]=(0,l.useState)(null),[c,d]=(0,l.useState)(0),[f,m]=(0,l.useState)({}),g=(0,t.usePublicSession)();return{loading:e,runGet:(0,l.useCallback)(async(e,t=null)=>{n(!0),a(null);let r=g(),i=await S(e,r);return i?.id?(u("Found."),n(!1),m(i)):(o(null),i?.message?a(i.message):i?.error&&a(i?.error),n(!1),u(null)),i},[g]),session:r,error:i,message:s,total:c,data:f}},k=async(e,t)=>{if(!t)return e;let[o]=await Promise.all([e,(0,n.revalidateAccountTag)(r.SETTINGS_CACHE_TAG,t)]);return o}},725502,e=>{"use strict";var t=e.i(482820);let n=(e,t)=>(parseFloat(parseFloat(t/100*e).toFixed(2))+parseFloat(.3)).toFixed(2);e.s(["GIVING_FEES_PERCENT",0,5,"calculateGivingFee",0,n,"getPaymentMethodBrandName",0,e=>{switch(e){case"visa":return"Visa";case"mastercard":return"Mastercard";case"discover":return"Discover";case"amex":return"American Express";case"unionpay":return"UnionPay";case"jcb":return"JCB";case"diners":return"Diners Club";default:return e}},"getTotalGift",0,(e,t,r)=>{if(!0!==r)return parseFloat(e).toFixed(2);let o=n(e,t),i=parseFloat(e);return(parseFloat(o)+parseFloat(i)).toFixed(2)},"isStripeConnected",0,e=>["chargesEnabled","payoutsEnabled","detailsSubmitted"].every(n=>!0===(0,t.default)(e,`StripeAccountSetting.content.[${n}]`))])},998783,412600,e=>{"use strict";var t=e.i(489578),n=e.i(152480);let r=async(e,t=null,r)=>{try{let o=await (0,n.APIPost)(`${n.APIBase}/v1/giving/connect/account`,e,t,r.token);return await o.json()}catch(e){(0,n.APIErrorHandler)(e)}},o=async(e,t=null,r)=>{try{let o=await (0,n.APIPost)(`${n.APIBase}/v1/giving/connect/accountlink`,e,t,r.token);return await o.json()}catch(e){(0,n.APIErrorHandler)(e)}},i=async(e,t=null,r)=>{try{let o=await (0,n.APIPost)("/api/giving/checkoutsession",e,t,r.token);return await o.json()}catch(e){(0,n.APIErrorHandler)(e)}},a=async(e,t=null,r)=>{try{let o=await (0,n.APIPost)("/api/giving/paymentintent",e,t,r.token);return await o.json()}catch(e){(0,n.APIErrorHandler)(e)}},l=async(e,t=null,r)=>{try{let o=await (0,n.APIPost)("/api/giving/setupintent",e,t,r.token);return await o.json()}catch(e){(0,n.APIErrorHandler)(e)}},s=async(e,t=null,r)=>{try{let o=await (0,n.APIPost)("/api/giving/subscription",e,t,r.token);return await o.json()}catch(e){(0,n.APIErrorHandler)(e)}},u=async(e,t,r=null,o)=>{try{let i=await (0,n.APIPut)(`${n.APIBase}/v1/giving/connect/member/subscription/${e}`,t,r,o.token);return await i.json()}catch(e){(0,n.APIErrorHandler)(e)}},c=async(e,t=null,r)=>{try{let o=await (0,n.APIGet)(`${n.APIBase}/v1/giving/connect/settings`,e,t,r.token);return await o.json()}catch(e){(0,n.APIErrorHandler)(e)}},d=async(e,t,r=null,o)=>{try{let i=await (0,n.APIPost)(`${n.APIBase}/v1/giving/connect/${e}/refund`,t,r,o.token);return await i.json()}catch(e){(0,n.APIErrorHandler)(e)}},f=async(e,t=null,r)=>{try{let o=await (0,n.APIPost)(`${n.APIBase}/v1/giving/connect/paymentmethods`,e,t,r.token);return await o.json()}catch(e){(0,n.APIErrorHandler)(e)}},m=async(e,t,r=null,o)=>{try{let i=await (0,n.APIPost)(`${n.APIBase}/v1/giving/connect/paymentmethods/${e}`,t,r,o.token);return await i.json()}catch(e){(0,n.APIErrorHandler)(e)}},g=async(e,t,r=null,o)=>{try{let i=await (0,n.APIPut)(`${n.APIBase}/v1/giving/connect/paymentmethods/${e}/attach`,t,r,o.token);return await i.json()}catch(e){(0,n.APIErrorHandler)(e)}},p=async(e,t,r=null,o)=>{try{let i=await (0,n.APIPut)(`${n.APIBase}/v1/giving/connect/paymentmethods/${e}/detach`,t,r,o.token);return await i.json()}catch(e){(0,n.APIErrorHandler)(e)}};e.s(["attachPaymentMethod",0,g,"createConnectedCheckoutSession",0,i,"createConnectedPaymentIntent",0,a,"createConnectedSetupIntent",0,l,"createConnectedStripeAccountLink",0,o,"createConnectedSubscription",0,s,"createNewConnectedStripeAccount",0,r,"detachPaymentMethod",0,p,"getConnectedPaymentMethod",0,m,"getConnectedPaymentMethods",0,f,"loadStripeConnectSettings",0,c,"refundConnectedPayment",0,d,"updateMemberConnectedSubscription",0,u,"validStripeConnectCountries",0,()=>
1({Australia:"AU",Austria:"AT",Belgium:"BE",Bulgaria:"BG",Canada:"CA",Cyprus:"CY","Czech Republic":"CZ",Denmark:"DK",Estonia:"EE",Finland:"FI",France:"FR",Germany:"DE",Greece:"GR","Hong Kong SAR China":"HK",Hungary:"HU",Ireland:"IE",Italy:"IT",Japan:"JP",Latvia:"LV",Lithuania:"LT",Luxembourg:"LU",Malta:"MT",Netherlands:"NL","New Zealand":"NZ",Norway:"NO",Poland:"PL",Portugal:"PT",Romania:"RO",Singapore:"SG",Slovakia:"SK",Slovenia:"SI",Spain:"ES",Sweden:"SE",Switzerland:"CH","United Kingdom":"GB","United States":"US"})],412600);var h=e.i(276495),v=e.i(730059),y=e.i(271645);e.s(["useAttachPaymentMethod",0,()=>{let[e,t]=(0,y.useState)(!1),[n,r]=(0,y.useState)(null),[o,i]=(0,y.useState)(null),[a,l]=(0,y.useState)(null),[s,u]=(0,y.useState)(null),c=(0,h.usePublicSession)();return{loading:e,runAttachPaymentMethod:async(e,n)=>{t(!0),i(null);let o=c(),a=await g(e,n,null,o);return a?.status==="success"?(l("Setup Intent Created"),t(!1),u(a?.data)):(r(null),a?.message?i(a.message):a?.error&&i(a?.error),t(!1),l(null)),a},session:n,error:o,message:a,result:s}},"useConnectedRefundPayment",0,()=>{let[e,t]=(0,y.useState)(!1),[n,r]=(0,y.useState)(null),[o,i]=(0,y.useState)(null),[a,l]=(0,y.useState)(null),[s,u]=(0,y.useState)(null);return{loading:e,runRefund:async(e,n)=>{t(!0),i(null);let o=(0,v.getSessionCookie)(),a=await d(e,n,null,o);return a?.status==="success"?(l("Payment Refunded"),t(!1),u(a?.data)):(r(null),a?.message?i(a.message):a?.error&&i(a?.error),t(!1),l(null)),a},session:n,error:o,message:a,result:s}},"useCreateConnectedPaymentIntent",0,()=>{let[e,t]=(0,y.useState)(!1),[n,r]=(0,y.useState)(null),[o,i]=(0,y.useState)(null),[l,s]=(0,y.useState)(null),[u,c]=(0,y.useState)(null),d=(0,h.usePublicSession)();return{loading:e,runCreatePaymentIntent:async e=>{t(!0),i(null);let n=d(),o=await a(e,null,n);return o?.status==="success"?(s("Payment Intent Created"),t(!1),c(o?.data)):(r(null),o?.message?i(o.message):o?.error&&i(o?.error),t(!1),s(null)),o},session:n,error:o,message:l,result:u}},"useCreateConnectedSetupIntent",0,()=>{let[e,t]=(0,y.useState)(!1),[n,r]=(0,y.useState)(null),[o,i]=(0,y.useState)(null),[a,s]=(0,y.useState)(null),[u,c]=(0,y.useState)(null),d=(0,h.usePublicSession)();return{loading:e,runCreateSetupIntent:async e=>{t(!0),i(null);let n=d(),o=await l(e,null,n);return o?.status==="success"?(s("Setup Intent Created"),t(!1),c(o?.data)):(r(null),o?.message?i(o.message):o?.error&&i(o?.error),t(!1),s(null)),o},session:n,error:o,message:a,result:u}},"useCreateConnectedStripeAccountLink",0,()=>{let[e,n]=(0,y.useState)(!1),[r,i]=(0,y.useState)(null),[a,l]=(0,y.useState)(null),[s,u]=(0,y.useState)(null),[c,d]=(0,y.useState)([]),{toast:f,setToast:m}=(0,t.useAdminUIContext)();return(0,y.useEffect)(()=>{s&&m({open:!0,variant:"success",title:"Connection successful",description:s,autoClose:!0})},[s]),(0,y.useEffect)(()=>{a&&m({open:!0,variant:"error",title:"Something went wrong",description:a,autoClose:!0})},[a]),{loading:e,run:async(e,t=null)=>{n(!0),l(null);let r=(0,v.getSessionCookie)(),a=await o(e,t,r);return a?.status==="success"?(u("Connection Successful"),n(!1),d(a?.data)):(i(null),a?.message?l(a.message):a?.error&&l(a?.error),n(!1),u(null)),a},session:r,error:a,message:s,data:c}},"useCreateConnectedSubscription",0,()=>{let[e,t]=(0,y.useState)(!1),[n,r]=(0,y.useState)(null),[o,i]=(0,y.useState)(null),[a,l]=(0,y.useState)(null),[u,c]=(0,y.useState)(null),d=(0,h.usePublicSession)();return{loading:e,runCreateSubscription:async e=>{t(!0),i(null);let n=d(),o=await s(e,null,n);return o?.status==="success"?(l("Subscription Created"),t(!1),c(o?.data)):(r(null),o?.message?i(o.message):o?.error&&i(o?.error),t(!1),l(null)),o},session:n,error:o,message:a,result:u}},"useCreateNewConnectedStripeAccount",0,()=>{let[e,n]=(0,y.useState)(!1),[o,i]=(0,y.useState)(null),[a,l]=(0,y.useState)(null),[s,u]=(0,y.useState)(null),[c,d]=(0,y.useState)([]),{toast:f,setToast:m}=(0,t.useAdminUIContext)();return(0,y.useEffect)(()=>{s&&m({open:!0,variant:"success",title:"Connection successful",description:s,autoClose:!0})},[s]),(0,y.useEffect)(()=>{a&&m({open:!0,variant:"error",title:"Something went wrong",description:a,autoClose:!0})},[a]),{loading:e,run:async(e,t=null)=>{n(!0),l(null);let o=(0,v.getSessionCookie)(),a=await r(e,t,o);return a?.status==="success"?(u("Connection Successful"),n(!1),d(a?.data)):(i(null),a?.message?l(a.message):a?.error&&l(a?.error),n(!1),u(null)),a},session:o,error:a,message:s,data:c}},"useGetConnectedPaymentMethod",0,()=>{let[e,t]=(0,y.useState)(!1),[n,r]=(0,y.useState)(null),[o,i]=(0,y.useState)(null),[a,l]=(0,y.useState)(null),[s,u]=(0,y.useState)(null),c=(0,h.usePublicSession)();return{loading:e,runLoadPaymentMethod:async(e,n)=>{t(!0),i(null);let o=c(),a=await m(e,n,null,o);return a?.status==="success"?(l("Payment methods Loaded"),t(!1),u(a?.data)):(r(null),a?.message?i(a.message):a?.error&&i(a?.error),t(!1),l(null)),a},session:n,error:o,message:a,result:s}},"useGetConnectedPaymentMethods",0,()=>{let[e,t]=(0,y.useState)(!1),[n,r]=(0,y.useState)(null),[o,i]=(0,y.useState)(null),[a,l]=(0,y.useState)(null),[s,u]=(0,y.useState)(null),c=(0,h.usePublicSession)();return{loading:e,runLoadPaymentMethods:async e=>{t(!0),i(null);let n=c(),o=await f(e,null,n);return o?.status==="success"?(l("Payment methods Loaded"),t(!1),u(o?.data)):(r(null),o?.message?i(o.message):o?.error&&i(o?.error),t(!1),l(null)),o},session:n,error:o,message:a,result:s}},"useLoadStripeConnectSettings",0,()=>{let[e,t]=(0,y.useState)(!1),[n,r]=(0,y.useState)(null),[o,i]=(0,y.useState)(null),[a,l]=(0,y.useState)(null),[s,u]=(0,y.useState)(null),d=(0,h.usePublicSession)();return{loading:e,runLoadStripeConnectSettings:async e=>{t(!0),i(null);let n=d(),o=await c(e,null,n);return o?.status==="success"?(l("Stripe Loaded"),t(!1),u(o?.data)):(r(null),o?.message?i(o.message):o?.error&&i(o?.error),t(!1),l(null)),o},session:n,error:o,message:a,result:s}}],998783)},307163,e=>{"use strict";var t=e.i(271645);let n=t.forwardRef(function({title:e,titleId:n,...r},o){return t.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:o,"aria-labelledby":n},r),e?t.createElement("title",{id:n},e):null,t.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15.75 19.5 8.25 12l7.5-7.5"}))});e.s(["ChevronLeftIcon",0,n],307163)},247103,e=>{"use strict";var t=e.i(271645);let n=t.forwardRef(function({title:e,titleId:n,...r},o){return t.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:o,"aria-labelledby":n},r),e?t.createElement("title",{id:n},e):null,t.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m8.25 4.5 7.5 7.5-7.5 7.5"}))});e.s(["ChevronRightIcon",0,n],247103)}]);
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.