@chaibuilder/sdk 3.1.12 → 3.1.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,365 @@
1
+ "use strict";var vd=Object.defineProperty;var Rd=(n,c,d)=>c in n?vd(n,c,{enumerable:!0,configurable:!0,writable:!0,value:d}):n[c]=d;var Vu=(n,c,d)=>Rd(n,typeof c!="symbol"?c+"":c,d);const jsxRuntime=require("react/jsx-runtime"),runtime=require("@chaibuilder/runtime"),lodashEs=require("lodash-es"),reactIcons=require("@radix-ui/react-icons"),React=require("react"),jotai=require("jotai"),utils=require("jotai/utils"),commonFunctions=require("./common-functions-BZmyleS1.cjs"),tooltip=require("./tooltip-CzZ7Fvt7.cjs"),clsx=require("clsx"),tailwindMerge=require("tailwind-merge"),TreeModel=require("tree-model"),applyBinding=require("./apply-binding-DCZAw7M-.cjs"),plugin=require("./plugin-BGIqPJSF.cjs"),utils$1=require("@rjsf/utils"),web=require("@react-hookz/web"),sonner=require("sonner"),reactI18next=require("react-i18next"),Fuse=require("fuse.js"),i18n=require("i18next"),require$$1=require("react-dom"),reactColorful=require("react-colorful"),Highlight=require("@tiptap/extension-highlight"),Link=require("@tiptap/extension-link"),Placeholder=require("@tiptap/extension-placeholder"),TextAlign=require("@tiptap/extension-text-align"),extensionTextStyle=require("@tiptap/extension-text-style"),Underline=require("@tiptap/extension-underline"),react=require("@tiptap/react"),StarterKit=require("@tiptap/starter-kit"),RjForm=require("@rjsf/core"),validator=require("@rjsf/validator-ajv8"),Autosuggest=require("react-autosuggest"),lodash=require("lodash"),reactArborist=require("react-arborist"),himalaya=require("himalaya"),tailwindAspectRatio=require("@tailwindcss/aspect-ratio"),tailwindForms=require("@tailwindcss/forms"),tailwindTypography=require("@tailwindcss/typography");require("tailwindcss-animate");require("@mhsdesign/jit-browser-tailwindcss");const twContainer=require("@tailwindcss/container-queries"),reactHotkeysHook=require("react-hotkeys-hook"),reactErrorBoundary=require("react-error-boundary"),getChaiBuilderTailwindConfig=require("./get-chai-builder-tailwind-config-C6MHaUM0.cjs"),framerMotion=require("framer-motion"),UndoManager=require("undo-manager"),dom=require("@floating-ui/dom"),reactDom=require("@floating-ui/react-dom"),reactWrapBalancer=require("react-wrap-balancer");function _interopNamespaceDefault(n){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const d in n)if(d!=="default"){const x=Object.getOwnPropertyDescriptor(n,d);Object.defineProperty(c,d,x.get?x:{enumerable:!0,get:()=>n[d]})}}return c.default=n,Object.freeze(c)}const React__namespace=_interopNamespaceDefault(React),ICON_CLASS="h-3 w-3 flex-shrink-0",TypeIcon=n=>{const c=runtime.useRegisteredChaiBlocks(),d=lodashEs.get(c,[n==null?void 0:n.type,"icon"]);return d?React.createElement(d,{className:ICON_CLASS}):jsxRuntime.jsx(reactIcons.SquareIcon,{className:ICON_CLASS})},readOnlyModeAtom=jotai.atom(!1);readOnlyModeAtom.debugLabel="readOnlyModeAtom";const networkModeAtom=jotai.atom("online");networkModeAtom.debugLabel="networkModeAtom";jotai.atom("");const editLayerNameAtom=jotai.atom(!1);editLayerNameAtom.debugLabel="editLayerNameAtom";const activeLanguageAtom=jotai.atom("");activeLanguageAtom.debugLabel="activeLanguageAtom";const primaryLanguageAtom=jotai.atom("");primaryLanguageAtom.debugLabel="primaryLanguageAtom";const canvasIframeAtom=jotai.atom(null);canvasIframeAtom.debugLabel="canvasIframeAtom";const activePanelAtom=jotai.atom("outline");activePanelAtom.debugLabel="activePanelAtom";const showPredefinedBlockCategoryAtom=jotai.atom("");showPredefinedBlockCategoryAtom.debugLabel="showPredefinedBlockCategoryAtom";const draggingFlagAtom=jotai.atom(!1);draggingFlagAtom.debugLabel="draggingFlagAtom";const treeRefAtom=jotai.atom(null);treeRefAtom.debugLabel="treeRefAtom";const canvasSettingsAtom=jotai.atom({});canvasSettingsAtom.debugLabel="canvasSettingsAtom";const aiAssistantActiveAtom=jotai.atom(!1);aiAssistantActiveAtom.debugLabel="aiAssistantActiveAtom";const codeEditorOpenAtom=jotai.atom(!1);codeEditorOpenAtom.debugLabel="codeEditorOpenAtom";const codeEditorHeightAtom=utils.atomWithStorage("codeEditorHeight",500);codeEditorHeightAtom.debugLabel="codeEditorHeightAtom";const xShowBlocksAtom=jotai.atom([]);xShowBlocksAtom.debugLabel="xShowBlocksAtom";const selectedLibraryAtom=utils.atomWithStorage("_selectedLibrary",null);selectedLibraryAtom.debugLabel="selectedLibraryAtom";const dataBindingActiveAtom=jotai.atom(!0);dataBindingActiveAtom.debugLabel="dataBindingActiveAtom";let lastHighlighted=null;const useBlockHighlight=()=>{const[n]=jotai.useAtom(canvasIframeAtom),c=React.useMemo(()=>{var b;return(n==null?void 0:n.contentDocument)||((b=n==null?void 0:n.contentWindow)==null?void 0:b.document)},[n]),d=React.useCallback(b=>{if(c)if(lastHighlighted&&lastHighlighted.removeAttribute("data-highlighted"),typeof b!="string")b.setAttribute("data-highlighted","true"),lastHighlighted=b;else if(typeof b=="string"){const y=c.querySelector(`[data-block-id="${b}"]`);y&&(y.setAttribute("data-highlighted","true"),lastHighlighted=y)}else lastHighlighted=null},[c]),x=React.useCallback(()=>{lastHighlighted&&(lastHighlighted.removeAttribute("data-highlighted"),lastHighlighted=null)},[]);return{highlightBlock:d,clearHighlight:x,lastHighlighted}};function duplicateBlocks(n,c,d){const x=lodashEs.filter(n,y=>y._parent===c),b=[];for(let y=0;y<x.length;y++)if(lodashEs.filter(n,{_parent:x[y]._id}).length>0){const R=commonFunctions.generateUUID();b.push({...x[y],oldId:x[y]._id,_id:R,_parent:d}),b.push(lodashEs.flatten(duplicateBlocks(n,x[y]._id,R)))}else b.push({...x[y],oldId:x[y]._id,_id:commonFunctions.generateUUID(),_parent:d});return lodashEs.flatten(b)}function convertToBlocksTree(n){const c={};n.forEach(x=>{c[x._id]={...x,children:[]}});const d=[];return n.forEach(x=>{if(x._parent){const b=c[x._parent];b&&b.children.push(c[x._id])}else d.push(c[x._id])}),d}const getDuplicatedBlocks=(n,c,d=null)=>{let x=lodashEs.find(n,{_id:c});x={...x,oldId:x._id,_id:commonFunctions.generateUUID()},d!==(x==null?void 0:x._parent)&&(x={...x,_parent:d});const b=[x];return lodashEs.filter(n,{_parent:c}).length>0&&b.push(lodashEs.flatten(duplicateBlocks(n,c,x._id))),lodashEs.flatten(b)},presentBlocksAtom=jotai.atom([]);presentBlocksAtom.debugLabel="presentBlocksAtom";const treeDSBlocks=jotai.atom(n=>{const c=n(presentBlocksAtom);return convertToBlocksTree([...c])});treeDSBlocks.debugLabel="treeDSBlocks";const pageBlocksAtomsAtom=utils.splitAtom(presentBlocksAtom);pageBlocksAtomsAtom.debugLabel="pageBlocksAtomsAtom";const builderActivePageAtom=jotai.atom("");builderActivePageAtom.debugLabel="builderActivePageAtom";const destinationDropIndexAtom=jotai.atom(-1);destinationDropIndexAtom.debugLabel="destinationDropIndexAtom";const buildingBlocksAtom=jotai.atom([]);buildingBlocksAtom.debugLabel="buildingBlocksAtom";const globalBlocksAtom=jotai.atom(n=>{const c=n(buildingBlocksAtom);return lodashEs.filter(c,d=>lodashEs.has(d,"blockId"))});globalBlocksAtom.debugLabel="globalBlocksAtom";const selectedBlockIdsAtom=jotai.atom([]);selectedBlockIdsAtom.debugLabel="selectedBlockIdsAtom";const selectedBlocksAtom=jotai.atom(n=>{const c=n(presentBlocksAtom),d=n(selectedBlockIdsAtom);return lodashEs.map(lodashEs.filter(c,({_id:x})=>lodashEs.includes(d,x)),x=>({...x}))});selectedBlocksAtom.debugLabel="selectedBlocksAtom";const selectedBlockAtom=jotai.atom(n=>{const c=n(selectedBlocksAtom);if(c.length===0)return null;if(c.length===1)return c[0]});selectedBlockAtom.debugLabel="selectedBlockAtom";const useSelectedBlock=()=>jotai.useAtomValue(selectedBlockAtom),getParentId=n=>lodashEs.get(n,"_parent",null),selectedBlocksParentsAtom=jotai.atom(n=>{const c=n(selectedBlocksAtom),d=lodashEs.map(c,getParentId);return lodashEs.filter(n(presentBlocksAtom),x=>lodashEs.includes(d,x._id))});selectedBlocksParentsAtom.debugLabel="selectedBlocksParentsAtom";const selectedBlockFlexChildAtom=jotai.atom(()=>!1);selectedBlockFlexChildAtom.debugLabel="selectedBlockFlexChildAtom";const selectedBlockGridChildAtom=jotai.atom(()=>!1);selectedBlockGridChildAtom.debugLabel="selectedBlockGridChildAtom";const styleStateAtom=jotai.atom("");styleStateAtom.debugLabel="styleStateAtom";const styleBreakpointAtom=utils.atomWithStorage("styleBreakpoint","xs");styleBreakpointAtom.debugLabel="styleBreakpointAtom";const useSelectedBlocksDisplayChild=()=>({flexChild:jotai.useAtomValue(selectedBlockFlexChildAtom),gridChild:jotai.useAtomValue(selectedBlockGridChildAtom)}),selectedBlockHierarchy=jotai.atom(n=>{const c=n(selectedBlockAtom),d=n(presentBlocksAtom);let x=c;const b=[c];do{const y=d.find(({_id:R})=>R===(x==null?void 0:x._parent));x=y,y&&b.push(y)}while(x!=null&&x._parent);return b}),useSelectedBlockHierarchy=()=>lodashEs.compact(jotai.useAtomValue(selectedBlockHierarchy)),useSelectedBlockIds=()=>{const[n,c]=jotai.useAtom(selectedBlockIdsAtom),d=React.useCallback(x=>{c(b=>lodashEs.includes(b,x)?lodashEs.without(b,x):[...b,x])},[c]);return[n,c,d]};function insertBlocksAtPosition(n,c,d,x){const b=[...c];let y=[...n];if(d){const A=n.find(L=>L._id===d);if(A&&A.content!==void 0&&A.content!==""&&!n.some(T=>T._parent===d)){const O={_id:commonFunctions.generateUUID(),_parent:d,_type:"Text",content:A.content};Object.keys(A).forEach(U=>{U.startsWith("content-")&&(O[U]=A[U])}),b.unshift(O),y=y.map(U=>{if(U._id===d){const M={...U,content:""};return Object.keys(M).forEach(D=>{D.startsWith("content-")&&(M[D]="")}),M}return U})}}let R=y.filter(A=>!A._parent);d&&(R=y.filter(A=>A._parent===d));const S=!isNaN(x)||x>-1?Math.min(x,R.length):R.length;let _=y.length;for(let A=0,L=0;A<y.length;A++)if(d!==void 0?y[A]._parent===d:!y[A]._parent){if(L===S){_=A;break}L++}return!d&&x!==void 0&&x>=R.length&&(_=y.length),[...y.slice(0,_),...b,...y.slice(_)]}function getBlocksTree(n){return convertToBlocksTree(n)}function flattenTree(n){let c=[];return n.walk(d=>(delete d.model.children,c.push(d.model),!0)),c}function findNodeById(n,c){return n.first(d=>d.model._id===c)||null}function moveNode(n,c,d,x){var A,L;const b=findNodeById(n,c),y=findNodeById(n,d);if(!b||!y)return!1;y.children||(y.model.children=[]);let R=(A=y==null?void 0:y.children)==null?void 0:A.findIndex(T=>T.model._id===c);b.drop(),R=Math.max(R,0);const _=(((L=b==null?void 0:b.model)==null?void 0:L._parent)||"root")===d&&R<=x?x-1:x;try{y.addChildAtIndex(b,_)}catch(T){return console.error("Error adding child to parent:",T),!1}return!0}function handleOldParentTextBlock(n,c){if(!c||!c._parent)return n;const d=c._parent,x=n.find(y=>y._id===d);if(!x)return n;const b=n.filter(y=>y._parent===d);if(b.length===2){const y=b.find(R=>R._id!==c._id);if(y&&y._type==="Text"&&"content"in x)return n.map(S=>{if(S._id===d){const _={...S,content:y.content};return Object.keys(y).forEach(A=>{A.startsWith("content-")&&(_[A]=y[A])}),_}return S}).filter(S=>S._id!==y._id)}return n}function handleNewParentTextBlock(n,c,d){if(!d||d==="root")return n;const x=n.find(b=>b._id===d);if(!x)return n;if(x.content!==void 0&&x.content!==""&&!n.some(y=>y._parent===d&&y._id!==c._id)){const R={_id:commonFunctions.generateUUID(),_parent:d,_type:"Text",content:x.content};Object.keys(x).forEach(A=>{A.startsWith("content-")&&(R[A]=x[A])});const S=n.map(A=>{if(A._id===d){const L={...A,content:""};return Object.keys(L).forEach(T=>{T.startsWith("content-")&&(L[T]="")}),L}return A}),_=S.findIndex(A=>A._id===c._id);return _!==-1?[...S.slice(0,_),R,...S.slice(_)]:[R,...S]}return n}function moveBlocksWithChildren(n,c,d,x){if(!c)return n;const b=n.find(A=>A._id===c);if(!b)return n;let y=handleOldParentTextBlock(n,b);const R=d||"root",_=new TreeModel().parse({_id:"root",children:getBlocksTree(y)});if(moveNode(_,c,R,x)){let A=flattenTree(_);const L=A.find(T=>T._id===c);return L&&(L._parent=R==="root"?null:R),A.shift(),d&&(A=handleNewParentTextBlock(A,b,d)),A}return y}const broadcastChannel=new BroadcastChannel("chaibuilder"),useBroadcastChannel=()=>{const n=useBuilderProp("pageId","chaibuilder_page");return{postMessage:web.useDebouncedCallback(d=>broadcastChannel.postMessage({...d,pageId:n}),[n],200)}},useUnmountBroadcastChannel=()=>{const[,n]=useBlocksStore(),c=useBuilderProp("pageId","chaibuilder_page"),{updateBlocksProps:d}=useBlocksStoreManager();React.useEffect(()=>(broadcastChannel.onmessageerror=x=>{console.log("error",x)},broadcastChannel.onmessage=x=>{x.data.type==="blocks-updated"&&x.data.pageId===c&&n(x.data.blocks),x.data.type==="blocks-props-updated"&&x.data.pageId===c&&d(x.data.blocks)},()=>{broadcastChannel.onmessage=null,broadcastChannel.onmessageerror=null}),[n,c])},removeNestedBlocks=(n,c)=>{let d=[...n],x=[];c.forEach(S=>{const _=d.find(T=>T._id===S);if(!_||!_._parent)return;const A=_._parent,L=d.filter(T=>T._parent===A);if(L.length===2){const T=L.find(O=>O._id!==S);if(T&&T._type==="Text"){const O=d.find(U=>U._id===A);O&&"content"in O&&(d=d.map(U=>{if(U._id===A){const M={...U,content:T.content};return Object.keys(T).forEach(D=>{D.startsWith("content-")&&(M[D]=T[D])}),M}return U}),x.push(T._id))}}});const b=[...c,...x],y=[],R=lodashEs.filter(d,S=>lodashEs.includes(b,S._id)||lodashEs.includes(b,S._parent)?(y.push(S._id),!1):!0);return lodashEs.isEmpty(y)?R:removeNestedBlocks(R,y)},useRemoveBlocks=()=>{const[n]=useBlocksStore(),[c,d]=useSelectedBlockIds(),{setNewBlocks:x}=useBlocksStoreUndoableActions(),{hasPermission:b}=usePermissions();return React.useCallback(y=>{var S;if(!b(PERMISSIONS.DELETE_BLOCK))return;const R=((S=lodashEs.find(n,{_id:y[0]}))==null?void 0:S._parent)||null;x(removeNestedBlocks(n,y)),setTimeout(()=>d(R?[R]:[]),200)},[n,d,c,b])},builderStore=jotai.getDefaultStore(),writeAtomValue=jotai.atom(null,(n,c,{id:d,props:x})=>{const b=n(pageBlocksAtomsAtom),y=lodashEs.find(b,R=>n(R)._id===d);return y?c(y,{...n(y),...x}):null}),useUpdateBlockAtom=()=>jotai.useSetAtom(writeAtomValue),useGetBlockAtom=n=>utils.useAtomCallback(React.useCallback((c,d,x)=>{const b=c(n);if(!b||!b.length)return console.warn("No blocks available in splitAtoms"),null;const y=lodashEs.find(b,R=>c(R)._id===(lodashEs.isString(x)?x:c(x)._id));return y||(console.warn(`Block with id ${x} not found`),null)},[n]),{store:builderStore}),useBlocksStoreManager=()=>{const[,n]=useBlocksStore(),{postMessage:c}=useBroadcastChannel(),d=useUpdateBlockAtom();return{setNewBlocks:x=>{n(x),c({type:"blocks-updated",blocks:x})},addBlocks:(x,b,y)=>{n(R=>{const S=insertBlocksAtPosition(R,x,b,y);return c({type:"blocks-updated",blocks:S}),S})},removeBlocks:x=>{n(b=>{const y=removeNestedBlocks(b,x);return c({type:"blocks-updated",blocks:y}),y})},moveBlocks:(x,b,y)=>{n(R=>{let S=[...R];for(let _=0;_<x.length;_++)S=moveBlocksWithChildren(S,x[_],b,y);return lodashEs.each(x,_=>{const A=lodashEs.find(S,L=>L._id===_);A&&d({id:_,props:{_parent:A._parent||null}})}),c({type:"blocks-updated",blocks:S}),S})},updateBlocksProps:x=>{x.forEach(b=>{const y=lodashEs.omit(b,"_id");d({id:b._id,props:y})}),c({type:"blocks-props-updated",blocks:x})}}},blockRepeaterDataAtom=jotai.atom({});blockRepeaterDataAtom.debugLabel="blockRepeaterDataAtom";const useBlockRepeaterDataAtom=()=>jotai.useAtom(blockRepeaterDataAtom),useAsyncProps=(n,c,d,x)=>{const[b,y]=React.useState({status:"idle",props:{},error:void 0}),R=useUpdateBlocksPropsRealtime(),S=useBuilderProp("getBlockAsyncProps",async U=>({})),_=jotai.useSetAtom(blockRepeaterDataAtom),A=JSON.stringify([n==null?void 0:n._id,...lodashEs.values(lodashEs.pick(n,d??[]))]),L=(n==null?void 0:n._type)==="Repeater"&&lodashEs.startsWith(n.repeaterItems,`{{${applyBinding.COLLECTION_PREFIX}`),T=(n==null?void 0:n._type)!=="Repeater"&&c==="live";return React.useEffect(()=>{if(c==="mock"){if(lodashEs.isFunction(x)){y(M=>({...M,status:"loading",props:{}}));const U=x({block:n});if(!utils$1.isObject(U))throw new Error("mockDataProvider should return an object");y(M=>({...M,status:"loaded",props:U}))}return}c==="live"&&(!L&&!T||(y(U=>({...U,status:"loading",props:{}})),S({block:n}).then((U={})=>{L?(_(M=>({...M,[n._id]:{status:"loaded",props:lodashEs.get(U,"items",[]),repeaterItems:n.repeaterItems}})),y(M=>({...M,status:"loaded",props:{totalItems:lodashEs.get(U,"totalItems")}})),R([n._id],{totalItems:lodashEs.get(U,"totalItems")})):y(M=>({...M,status:"loaded",props:utils$1.isObject(U)?U:{}}))}).catch(U=>{L?(_(M=>({...M,[n._id]:{status:"error",error:U,props:[]}})),y(M=>({...M,status:"error",error:U,props:{}}))):y(M=>({...M,status:"error",error:U,props:{}}))})))},[n==null?void 0:n._id,A,L,T,x,c]),{$loading:lodashEs.get(b,"status")==="loading",...n?lodashEs.get(b,"props",{}):{}}},chaiBuilderPropsAtom=jotai.atom(null);chaiBuilderPropsAtom.debugLabel="chaiBuilderPropsAtom";const chaiExternalDataAtom=jotai.atom({});chaiExternalDataAtom.debugLabel="chaiExternalDataAtom";const chaiRjsfFieldsAtom=jotai.atom({});chaiRjsfFieldsAtom.debugLabel="chaiRjsfFieldsAtom";const chaiRjsfWidgetsAtom=jotai.atom({});chaiRjsfWidgetsAtom.debugLabel="chaiRjsfWidgetsAtom";const chaiRjsfTemplatesAtom=jotai.atom({});chaiRjsfTemplatesAtom.debugLabel="chaiRjsfTemplatesAtom";const chaiPageExternalDataAtom=jotai.atom({});chaiPageExternalDataAtom.debugLabel="chaiPageExternalDataAtom";const usePageExternalData=()=>{const[n]=useBlockRepeaterDataAtom(),c=React.useMemo(()=>{const x={};return Object.entries(n).forEach(([b,y])=>{y.status==="loaded"&&(x[y.repeaterItems.replace("}}",`/${b}`).replace("{{","")]=y.props)}),x},[n]);return{...jotai.useAtomValue(chaiPageExternalDataAtom),...c}},useBuilderProp=(n,c=void 0)=>{const d=jotai.useAtomValue(chaiBuilderPropsAtom);return React.useMemo(()=>lodashEs.get(d,n,c),[d,n,c])},MODIFIERS=["hover","focus","focus-within","focus-visible","active","visited","target","first","last","only","odd","even","first-of-type","last-of-type","only-of-type","empty","disabled","checked","indeterminate","default","required","valid","invalid","in-range","out-of-range","placeholder-shown","autofill","read-only","open","before","after","first-letter","first-line","marker","selection","file","placeholder","hs-collapse-open","hs-accordion-active"],BRANDING_OPTIONS_DEFAULTS={bodyFont:"Inter",headingFont:"Inter",roundedCorners:5,primaryColor:"#570df8",secondaryColor:"#f002b8",bodyBgDarkColor:"#031022",bodyBgLightColor:"#fcfcfc",bodyTextDarkColor:"#ffffff",bodyTextLightColor:"#000000"},brandingOptionsAtom=jotai.atom(BRANDING_OPTIONS_DEFAULTS);jotai.atom(null);const useBrandingOptions=()=>{const[n,c]=jotai.useAtom(brandingOptionsAtom);return[lodashEs.isObject(n)?{...BRANDING_OPTIONS_DEFAULTS,...n}:BRANDING_OPTIONS_DEFAULTS,c]},currentPageAtom=jotai.atom(null),useCurrentPage=()=>({currentPage:jotai.useAtomValue(currentPageAtom)}),getBlockBuilderProps=lodashEs.memoize(n=>{const c=runtime.getRegisteredChaiBlock(n),d=lodashEs.get(c,"schema.properties",{});return lodashEs.compact(Object.keys(d).map(x=>lodashEs.get(d[x],"builderProp",!1)||lodashEs.get(d[x],"runtime",!1)?x:null))}),useGetPageData=()=>{const[n]=useBrandingOptions(),{currentPage:c}=useCurrentPage(),[d]=useBlocksStore();return React.useCallback(()=>{const x=lodashEs.map(d,b=>lodashEs.omit(b,getBlockBuilderProps(b._type)));return{currentPage:c,blocks:x}},[n,c,d])},usePermissions=()=>{const n=useBuilderProp("permissions",void 0);return{hasPermission:React.useCallback(d=>n?n.includes(d):!0,[n])}},getDefaultThemeValues=(n=plugin.defaultThemeOptions)=>{const c=plugin.defaultThemeValues;return n.fontFamily&&(c.fontFamily=Object.entries(n.fontFamily).reduce((d,[x,b])=>({...d,[x.replace("font-","")]:b}),c.fontFamily)),c.borderRadius=n.borderRadius,n.colors&&(c.colors=n.colors.reduce((d,x)=>(Object.entries(x.items).forEach(([b,y])=>{d[b]=y}),d),c.colors)),c},chaiThemeValuesAtom=jotai.atom({}),useTheme=()=>{const n=useThemeOptions(),c=React.useMemo(()=>getDefaultThemeValues(n),[n]),d=useBuilderProp("theme",{}),[x,b]=jotai.useAtom(chaiThemeValuesAtom);return[React.useMemo(()=>({...c,...!lodashEs.isEmpty(d)&&d,...!lodashEs.isEmpty(x)&&x}),[c,d,x]),b]},useThemeOptions=()=>{const n=useBuilderProp("themeOptions",d=>d);return React.useMemo(()=>n(plugin.defaultThemeOptions),[n])},rightPanelAtom=jotai.atom("block"),useRightPanel=()=>jotai.useAtom(rightPanelAtom),languageAtom=jotai.atom("");languageAtom.debugLabel="selectedLanguageAtom";const useLanguages=()=>{const n=useBuilderProp("languages",[]),c=useBuilderProp("fallbackLang","en"),[d,x]=jotai.useAtom(languageAtom),b=y=>{x(c===y?"":y)};return{languages:n==null?void 0:n.filter(y=>y!==c),fallbackLang:c,selectedLang:d,setSelectedLang:b}},isPageLoadedAtom=jotai.atom(!1),useIsPageLoaded=()=>jotai.useAtom(isPageLoadedAtom),builderSaveStateAtom=jotai.atom("SAVED");builderSaveStateAtom.debugLabel="builderSaveStateAtom";const checkMissingTranslations=(n,c)=>c?n.some(d=>{if(!(d!=null&&d._type)||d._type==="PartialBlock")return!1;try{const x=runtime.getRegisteredChaiBlock(d._type);return x?(lodashEs.has(x,"i18nProps")?x.i18nProps:[]).some(y=>{const R=`${y}-${c}`;return!d[R]||lodashEs.isEmpty(d[R])}):!1}catch(x){return console.warn(`Failed to get block definition for type: ${d._type}`,x),!1}}):!1,useSavePage=()=>{const[n,c]=jotai.useAtom(builderSaveStateAtom),d=useBuilderProp("onSave",async U=>{}),x=useBuilderProp("onSaveStateChange",lodashEs.noop),b=useGetPageData(),[y]=useTheme(),{hasPermission:R}=usePermissions(),{selectedLang:S,fallbackLang:_}=useLanguages(),[A]=useIsPageLoaded(),L=()=>{const U=b();return!S||S===_?!1:checkMissingTranslations(U.blocks||[],S)};return{savePage:web.useThrottledCallback(async(U=!1)=>{if(!R("save_page")||!A)return;c("SAVING"),x("SAVING");const M=b();return await d({autoSave:U,blocks:M.blocks,theme:y,needTranslations:L()}),setTimeout(()=>{c("SAVED"),x("SAVED")},100),!0},[b,c,y,d,x,A],3e3),savePageAsync:async()=>{if(!R("save_page")||!A)return;c("SAVING"),x("SAVING");const U=b();return await d({autoSave:!0,blocks:U.blocks,theme:y,needTranslations:L()}),setTimeout(()=>{c("SAVED"),x("SAVED")},100),!0},saveState:n,setSaveState:c,needTranslations:L}},undoManager=new UndoManager;undoManager.setLimit(50);const undoRedoStateAtom=jotai.atom({canUndo:!1,canRedo:!1}),useUndoManager=()=>{const[,n]=jotai.useAtom(builderSaveStateAtom),[c,d]=jotai.useAtom(undoRedoStateAtom),x=useBuilderProp("onSaveStateChange",lodashEs.noop),b=React.useCallback(()=>{const A={canUndo:undoManager.hasUndo(),canRedo:undoManager.hasRedo()};d(A),n("UNSAVED"),x("UNSAVED")},[d,n,x]);React.useEffect(()=>(undoManager.setCallback(b),()=>{undoManager.setCallback(lodashEs.noop)}),[b]);const y=React.useCallback(A=>{undoManager.add(A),b()},[b]),R=React.useCallback(()=>{undoManager.undo(),b()},[b]),S=React.useCallback(()=>{undoManager.redo(),b()},[b]),_=React.useCallback(()=>{undoManager.clear(),d({canUndo:!1,canRedo:!1})},[d]);return React.useMemo(()=>({add:y,undo:R,redo:S,hasUndo:()=>c.canUndo,hasRedo:()=>c.canRedo,clear:_}),[y,R,S,c.canUndo,c.canRedo,_])},useBlocksStore=()=>jotai.useAtom(presentBlocksAtom),useBlocksStoreUndoableActions=()=>{const{add:n}=useUndoManager(),[c]=useBlocksStore(),{setNewBlocks:d,addBlocks:x,removeBlocks:b,moveBlocks:y,updateBlocksProps:R}=useBlocksStoreManager();return{moveBlocks:(M,D,K)=>{const $=lodashEs.map(M,ae=>{const ye=c.find(he=>he._id===ae)._parent||null,q=c.filter(he=>ye?he._parent===ye:!he._parent).map(he=>he._id).indexOf(ae);return{_id:ae,oldParent:ye,oldPosition:q}}),ee=$.find(({_id:ae})=>ae===M[0]);ee&&ee.oldParent===D&&ee.oldPosition===K||(y(M,D,K),n({undo:()=>lodashEs.each($,({_id:ae,oldParent:Re,oldPosition:ye})=>{y([ae],Re,ye)}),redo:()=>y(M,D,K)}))},addBlocks:(M,D,K)=>{x(M,D,K),n({undo:()=>b(lodashEs.map(M,"_id")),redo:()=>x(M,D,K)})},removeBlocks:M=>{var ee;const D=(ee=lodashEs.first(M))==null?void 0:ee._parent,$=c.filter(ae=>D?ae._parent===D:!ae._parent).indexOf(lodashEs.first(M));b(lodashEs.map(M,"_id")),n({undo:()=>x(M,D,$),redo:()=>b(lodashEs.map(M,"_id"))})},updateBlocks:(M,D,K)=>{let $=[];if(K)$=lodashEs.map(M,ee=>({_id:ee,...K}));else{const ee=lodashEs.keys(D);$=lodashEs.map(M,ae=>{const Re=c.find(de=>de._id===ae),ye={_id:ae};return lodashEs.each(ee,de=>ye[de]=Re[de]),ye})}R(lodashEs.map(M,ee=>({_id:ee,...D}))),n({undo:()=>R($),redo:()=>R(lodashEs.map(M,ee=>({_id:ee,...D})))})},updateBlocksRuntime:(M,D)=>{R(lodashEs.map(M,K=>({_id:K,...D})))},setNewBlocks:M=>{d(M),n({undo:()=>d(c),redo:()=>d(M)})},updateMultipleBlocksProps:M=>{let D=[];D=lodashEs.map(M,K=>{const $=lodashEs.keys(K),ee=c.find(Re=>Re._id===K._id),ae={};return lodashEs.each($,Re=>ae[Re]=ee[Re]),ae}),R(M),n({undo:()=>R(D),redo:()=>R(M)})}}},canAcceptChildBlock=(n,c)=>{if(!n)return!0;const d=runtime.getRegisteredChaiBlock(n);return d&&lodashEs.has(d,"canAcceptBlock")?d.canAcceptBlock(c):!1},canAddChildBlock=n=>{const c=runtime.getRegisteredChaiBlock(n);return c?lodashEs.has(c,"canAcceptBlock"):!1},canBeNestedInside=(n,c)=>{const d=runtime.getRegisteredChaiBlock(c);return d&&lodashEs.has(d,"canBeNested")?d.canBeNested(n):!0},canDuplicateBlock=n=>{const c=runtime.getRegisteredChaiBlock(n);return c&&lodashEs.has(c,"canDuplicate")?c.canDuplicate():!0},canDeleteBlock=n=>{const c=runtime.getRegisteredChaiBlock(n);return c&&lodashEs.has(c,"canDelete")?c.canDelete():!0},canDropBlock=(n,{dragSource:c,dropTarget:d})=>{const x=lodashEs.get(c,"data._type",""),b=lodashEs.get(d,"data._type","");return canAcceptChildBlock(b,x)},useAddBlock=()=>{const[n]=useBlocksStore(),[,c]=useSelectedBlockIds(),{addBlocks:d}=useBlocksStoreUndoableActions(),x=React.useCallback((y,R,S)=>{var O;for(let U=0;U<y.length;U++){const{_id:M}=y[U];y[U]._id=commonFunctions.generateUUID();const D=lodashEs.filter(y,{_parent:M});for(let K=0;K<D.length;K++)D[K]._parent=y[U]._id}const _=lodashEs.first(y);let A,L;return R&&(A=lodashEs.find(n,{_id:R}),y[0]._parent=R,L=R),!(A?canAcceptChildBlock(A==null?void 0:A._type,_._type):!0)&&A&&(y[0]._parent=A._parent,L=A._parent),d(y,L,S),c([(O=lodashEs.first(y))==null?void 0:O._id]),lodashEs.first(y)},[d,n,c]);return{addCoreBlock:React.useCallback((y,R,S)=>{if(lodashEs.has(y,"blocks")){const D=y.blocks;return x(D,R,S)}const _=commonFunctions.generateUUID(),A=runtime.getDefaultBlockProps(y.type),L={_type:y.type,_id:_,...A,...lodashEs.has(y,"_name")&&{_name:y._name},...lodashEs.has(y,"partialBlockId")&&{partialBlockId:y.partialBlockId}};let T,O;return R&&(T=lodashEs.find(n,{_id:R}),L._parent=R,O=R),!canAcceptChildBlock(T==null?void 0:T._type,L._type)&&T&&(L._parent=T._parent,O=T._parent),d([L],O,S),c([L._id]),L},[d,x,n,c]),addPredefinedBlock:x}},STANDARD=[0,1,2,3,4,5,6,7,8,9,10,11,12,14,16,20,24,28,32,36,40,44,48,52,56,60,64,72,80,96],CLASS_VALUES={columns:[...lodashEs.range(1,13),"auto","3xs","2xs","xs","sm","md","lg","xl",...lodashEs.map(lodashEs.range(2,8),n=>`${n}xl`)],breakAfter:["auto","avoid","all","avoid-page","page","left","right","column"],breakInside:["auto","avoid","avoid-page","avoid-column"],display:["block","flex","grid","inline-block","inline","hidden"],objectFit:["contain","cover","fill","none","scale-down"],objectPosition:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],overflow:["auto","hidden","clip","visible","scroll"],overscroll:["auto","contain","none"],trbl:[0,"px","0.5",1,1.5,2,2.5,3,3.5,...lodashEs.range(4,13),14,16,20,24,28,32,36,40,44,48,52,56,60,64,72,80,96,"auto","1/2","1/3","2/3","1/4","2/4","3/4","full"],flexBasis:[...STANDARD,"auto","px","0.5","1.5","2.5","3.5","1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12","full"],padding:[...STANDARD,"px","0.5","1.5","2.5","3.5"],margin:["auto",...STANDARD,"px","0.5","1.5","2.5","3.5"],scale:[0,50,75,90,95,100,105,110,125,150],origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left"],blendEffect:["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],borderWidth:[0,2,4,8],borderRadius:["global","none","sm","md","lg","xl","2xl","3xl","full"],indent:[0,"px","0.5",1,1.5,2,2.5,3,3.5,...lodashEs.range(4,13),14,16,20,24,28,32,36,40,44,48,52,56,60,64,72,80,96],maxHeight:[0,"px","0.5",1,1.5,2,2.5,3,3.5,...lodashEs.range(4,13),14,16,20,24,28,32,36,40,44,48,52,56,60,64,72,80,96,"full","screen","min","max","fit"],space:[0,"px","0.5",1,1.5,2,2.5,3,3.5,...lodashEs.range(4,13),14,16,20,24,28,32,36,40,44,48,52,56,60,64,72,80,96,"px","reverse"],width:["0","px","0.5","1","1.5","2","2.5","3","3.5","4","5","6","7","8","9","10","11","12","14","16","20","24","28","32","36","40","44","48","52","56","60","64","72","80","96","auto","1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","1/12","2/12","3/12","4/12","5/12","6/12","7/12","8/12","9/12","10/12","11/12"],maxWidth:["0","none","xs","sm","md","lg","xl","2xl","3xl","4xl","5xl","6xl","7xl","full","min","max","fit","prose","screen-sm","screen-md","screen-lg","screen-xl","screen-2xl"],height:["0","px","0.5","1","1.5","2","2.5","3","3.5","4","5","6","7","8","9","10","11","12","14","16","20","24","28","32","36","40","44","48","52","56","60","64","72","80","96","auto","1/2","1/3","2/3","1/4","2/4","3/4","1/5","2/5","3/5","4/5","1/6","2/6","3/6","4/6","5/6","full","screen","min","max","fit"]},CLASSES_LIST={textColor:{classes:[],regExp:"text-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},aspectRatio:{classes:["aspect-auto","aspect-square","aspect-video"],regExp:"aspect-(auto|square|video)"},container:{classes:["container"],regExp:"container"},columns:{classes:lodashEs.map(CLASS_VALUES.columns,n=>`columns-${n}`),regExp:"columns-(auto|[0-9]xl|[0-9]xs|xs|sm|md|lg|xl|\\d+)"},breakAfter:{classes:lodashEs.map(CLASS_VALUES.breakAfter,n=>`break-after-${n}`),regExp:"break-after-\\S+"},breakBefore:{classes:lodashEs.map(CLASS_VALUES.breakAfter,n=>`break-before-${n}`),regExp:"break-before-\\S+"},breakInside:{classes:lodashEs.map(CLASS_VALUES.breakInside,n=>`break-inside-${n}`),regExp:"break-inside-\\S+"},boxDecoration:{classes:["box-decoration-clone","box-decoration-slice"],regExp:"box-decoration-\\S+"},boxSizing:{classes:["box-border","box-content"],regExp:"box-(border|content)"},flexDirection:{classes:["flex-row","flex-row-reverse","flex-col","flex-col-reverse"],regExp:"flex-(row|row-reverse|col|col-reverse)"},flexWrap:{classes:["flex-wrap","flex-wrap-reverse","flex-nowrap"],regExp:"flex-(wrap|wrap-reverse|nowrap)"},flexGrowShrink:{classes:["flex-1","flex-auto","flex-initial","flex-none"],regExp:"flex-1|flex-auto|flex-initial|flex-none"},gridColumns:{classes:lodashEs.map([...lodashEs.range(0,13),"none"],n=>`grid-cols-${n}`),regExp:"grid-cols-(\\d+|none)"},gridFlow:{classes:["grid-flow-row","grid-flow-col","grid-flow-row-dense","grid-flow-col-dense"],regExp:"grid-flow-(row|col|row-dense|col-dense)"},outlineStyle:{classes:lodashEs.map(["none","dashed","dotted","double","hidden"],n=>`outline-${n}`),regExp:"outline-(none|dashed|dotted|double|hidden)"},borderStyle:{classes:lodashEs.map(["solid","dashed","dotted","double","hidden","none"],n=>`border-${n}`),regExp:"border-(solid|dashed|dotted|double|hidden|none)"},overflow:{classes:lodashEs.map(CLASS_VALUES.overflow,n=>`overflow-${n}`),regExp:`overflow-(${CLASS_VALUES.overflow.join("|")})`},overflowX:{classes:lodashEs.map(CLASS_VALUES.overflow,n=>`overflow-x-${n}`),regExp:`overflow-x-(${CLASS_VALUES.overflow.join("|")})`},overflowY:{classes:lodashEs.map(CLASS_VALUES.overflow,n=>`overflow-y-${n}`),regExp:`overflow-y-(${CLASS_VALUES.overflow.join("|")})`},gridRows:{classes:lodashEs.map([1,2,3,4,5,6,"none"],n=>`grid-rows-${n}`),regExp:"grid-rows-(\\d|none)"},display:{classes:lodashEs.map(CLASS_VALUES.display,n=>n.toString()),regExp:`(${CLASS_VALUES.display.join("|")})`},float:{classes:["float-right","float-left","float-none"],regExp:"float-\\S+"},clear:{classes:["clear-right","clear-left","clear-none","clear-both"],regExp:"clear-\\S+"},isolation:{classes:["isolate","isolation-auto"],regExp:"isolate|isolation-auto"},objectFit:{classes:lodashEs.map(CLASS_VALUES.objectFit,n=>`object-${n}`),regExp:"object-(contain|cover|fill|none|scale-down)"},objectPosition:{classes:lodashEs.map(CLASS_VALUES.objectPosition,n=>`object-${n}`),regExp:`object-(${CLASS_VALUES.objectPosition.join("|")})`},overscroll:{classes:lodashEs.map(CLASS_VALUES.overscroll,n=>`overscroll-${n}`),regExp:`overscroll-(${CLASS_VALUES.overscroll.join("|")})`},overscrollX:{classes:lodashEs.map(CLASS_VALUES.overscroll,n=>`overscroll-x-${n}`),regExp:`overscroll-x-(${CLASS_VALUES.overscroll.join("|")})`},overscrollY:{classes:lodashEs.map(CLASS_VALUES.overscroll,n=>`overscroll-y-${n}`),regExp:`overscroll-y-(${CLASS_VALUES.overscroll.join("|")})`},inset:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`inset-${n}`),regExp:"-?inset-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},insetX:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`inset-x-${n}`),regExp:"-?inset-x-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},insetY:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`inset-y-${n}`),regExp:"-?inset-y-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},top:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`top-${n}`),regExp:"-?top-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},topX:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`top-x-${n}`),regExp:"-?top-x-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},topY:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`top-y-${n}`),regExp:"-?top-y-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},right:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`right-${n}`),regExp:"-?right-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},rightX:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`right-x-${n}`),regExp:"-?right-x-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},rightY:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`right-y-${n}`),regExp:"-?right-y-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},bottom:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`bottom-${n}`),regExp:"-?bottom-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},bottomX:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`bottom-x-${n}`),regExp:"-?bottom-x-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},bottomY:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`bottom-y-${n}`),regExp:"-?bottom-y-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},left:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`left-${n}`),regExp:"-?left-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},leftX:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`left-x-${n}`),regExp:"-?left-x-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},leftY:{classes:lodashEs.map(CLASS_VALUES.trbl,n=>`left-y-${n}`),regExp:"-?left-y-(px|\\d\\/\\d|\\d\\.\\d|\\d+|full|auto|\\[.*\\])"},visibility:{classes:["visible","invisible"],regExp:"invisible|visible"},zIndex:{classes:lodashEs.map(["0",10,20,30,40,50,"auto"],n=>`z-${n}`),regExp:"-?z-(\\d+|auto|\\[.*\\])"},flexBasis:{classes:lodashEs.map(CLASS_VALUES.flexBasis,n=>`basis-${n}`),regExp:"basis-(\\d+|\\S+)"},flexGrow:{classes:["grow","grow-0"],regExp:"grow(-0)?"},flexShrink:{classes:["shrink","shrink-0"],regExp:"shrink(-0)?"},gridColSpan:{classes:["col-auto",...lodashEs.map(lodashEs.range(1,13),n=>`col-span-${n}`),"col-span-full"],regExp:"col-(auto|span-(\\d+|full))"},gridColStart:{classes:[...lodashEs.map(lodashEs.range(1,14),n=>`col-start-${n}`),"col-start-auto"],regExp:"col-start-(\\d+|auto)"},gridColEnd:{classes:[...lodashEs.map(lodashEs.range(1,14),n=>`col-end-${n}`),"col-end-auto"],regExp:"col-end-(\\d+|auto)"},gridRowSpan:{classes:["row-auto",...lodashEs.map(lodashEs.range(1,7),n=>`row-span-${n}`),"row-span-full"],regExp:"row-(auto|span-(\\d+|full))"},gridRowStart:{classes:[...lodashEs.map(lodashEs.range(1,8),n=>`row-start-${n}`),"row-start-auto"],regExp:"row-start-(\\d+|auto)"},gridRowEnd:{classes:[...lodashEs.map(lodashEs.range(1,8),n=>`row-end-${n}`),"row-end-auto"],regExp:"row-end-(\\d+|auto)"},gridAutoColumns:{classes:["auto-cols-auto","auto-cols-min","auto-cols-max","auto-cols-fr"],regExp:"auto-cols-(auto|min|max|fr)"},gridAutoRows:{classes:["auto-rows-auto","auto-rows-min","auto-rows-max","auto-rows-fr"],regExp:"auto-rows-(auto|min|max|fr)"},gap:{classes:lodashEs.map(CLASS_VALUES.indent,n=>`gap-${n}`),regExp:"gap-(px|\\d.\\d|\\d|\\[.*\\])"},gapX:{classes:lodashEs.map(CLASS_VALUES.indent,n=>`gap-x-${n}`),regExp:"gap-x-(px|\\d.\\d|\\d|\\[.*\\])"},gapY:{classes:lodashEs.map(CLASS_VALUES.indent,n=>`gap-y-${n}`),regExp:"gap-y-(px|\\d.\\d|\\d|\\[.*\\])"},justifyContent:{classes:["justify-start","justify-end","justify-center","justify-between","justify-around","justify-evenly"],regExp:"justify-(start|end|center|between|around|evenly)"},justifyItems:{classes:["justify-items-start","justify-items-end","justify-items-center","justify-items-stretch"],regExp:"justify-items-(start|end|center|stretch)"},justifySelf:{classes:["justify-self-auto","justify-self-start","justify-self-end","justify-self-center","justify-self-stretch"],regExp:"justify-self-(auto|start|end|center|stretch)"},placeContent:{classes:["place-content-center","place-content-start","place-content-end","place-content-between","place-content-around","place-content-evenly","place-content-stretch"],regExp:"place-content-(center|start|end|between|around|evenly|stretch)"},placeItems:{classes:["place-items-start","place-items-end","place-items-center","place-items-stretch"],regExp:"place-items-(start|end|center|stretch)"},placeSelf:{classes:["place-self-auto","place-self-start","place-self-end","place-self-center","place-self-stretch"],regExp:"place-self-(auto|start|end|center|stretch)"},alignContent:{classes:["content-center","content-start","content-end","content-between","content-around","content-evenly"],regExp:"content-(center|start|end|between|around|evenly)"},alignItems:{classes:["items-start","items-end","items-center","items-baseline","items-stretch"],regExp:"items-(start|end|center|baseline|stretch)"},alignSelf:{classes:["self-auto","self-start","self-end","self-center","self-stretch","self-baseline"],regExp:"self-(auto|start|end|center|stretch|baseline)"},backgroundClip:{classes:["bg-clip-border","bg-clip-padding","bg-clip-content","bg-clip-text"],regExp:"bg-clip-(border|padding|content|text)"},dropShadow:{classes:lodashEs.map(["sm","md","lg","xl","2xl","none"],n=>`drop-shadow-${n}`),regExp:"drop-shadow-(sm|md|lg|xl|2xl|none)"},backdropBlur:{classes:lodashEs.map(["none","sm","md","lg","xl","2xl","3xl"],n=>`backdrop-blur-${n}`),regExp:"backdrop-blur-(none|sm|md|lg|xl|2xl|3xl)"},backdropBrightness:{classes:lodashEs.map([0,50,75,90,95,100,105,110,125,150,200],n=>`backdrop-brightness-${n}`),regExp:"backdrop-brightness-(\\d+)"},backdropContrast:{classes:lodashEs.map([0,50,75,100,125,150,200],n=>`backdrop-contrast-${n}`),regExp:"backdrop-contrast-(\\d+)"},backdropGrayScale:{classes:["backdrop-grayscale-0","backdrop-grayscale"],regExp:"backdrop-grayscale(-0)?"},backdropHueRotate:{classes:lodashEs.map([0,15,30,60,90,180],n=>`backdrop-hue-rotate-${n}`),regExp:"-?backdrop-hue-rotate-(\\d+)"},backdropInvert:{classes:["backdrop-invert-0","backdrop-invert"],regExp:"backdrop-invert(-0)?"},backdropOpacity:{classes:lodashEs.map([0,5,10,20,25,30,40,50,60,70,75,80,90,95,100],n=>`backdrop-opacity-${n}`),regExp:"backdrop-opacity-(\\d+)"},backdropSaturate:{classes:lodashEs.map([0,50,100,150,200],n=>`backdrop-saturate-${n}`),regExp:"backdrop-saturate-(\\d+)"},backdropSepia:{classes:["backdrop-sepia-0, backdrop-sepia"],regExp:"backdrop-sepia(-0)?"},backgroundOrigin:{classes:["bg-origin-border","bg-origin-padding","bg-origin-content"],regExp:"bg-origin-(border|padding|content)"},transformOrigin:{classes:lodashEs.map(CLASS_VALUES.origin,n=>`origin-${n}`),regExp:"origin-(\\d+|\\S+)"},padding:{classes:lodashEs.map(CLASS_VALUES.padding,n=>`p-${n}`),regExp:"p-(\\d+|\\S+|\\[.*\\])"},paddingX:{classes:lodashEs.map(CLASS_VALUES.padding,n=>`px-${n}`),regExp:"px-(\\d+|\\S+|\\[.*\\])"},paddingY:{classes:lodashEs.map(CLASS_VALUES.padding,n=>`py-${n}`),regExp:"py-(\\d+|\\S+|\\[.*\\])"},paddingTop:{classes:lodashEs.map(CLASS_VALUES.padding,n=>`pt-${n}`),regExp:"pt-(\\d+|\\S+|\\[.*\\])"},paddingRight:{classes:lodashEs.map(CLASS_VALUES.padding,n=>`pr-${n}`),regExp:"pr-(\\d+|\\S+|\\[.*\\])"},paddingBottom:{classes:lodashEs.map(CLASS_VALUES.padding,n=>`pb-${n}`),regExp:"pb-(\\d+|\\S+|\\[.*\\])"},paddingLeft:{classes:lodashEs.map(CLASS_VALUES.padding,n=>`pl-${n}`),regExp:"pl-(\\d+|\\S+|\\[.*\\])"},textDecorationStyle:{classes:["decoration-solid","decoration-double","decoration-dotted","decoration-dashed","decoration-wavy"],regExp:"decoration-(solid|double|dotted|dashed|wavy)"},textDecorationThickness:{classes:lodashEs.map(["auto","from-font","0",1,2,4,8],n=>`decoration-${n}`),regExp:"decoration-(auto|from-font|\\d+|\\S+)"},fromColor:{classes:[],regExp:"from-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},margin:{classes:lodashEs.map(CLASS_VALUES.margin,n=>`m-${n}`),regExp:"-?m-(\\d+|\\S+|\\[.*\\])"},marginX:{classes:lodashEs.map(CLASS_VALUES.margin,n=>`mx-${n}`),regExp:"-?mx-(\\d+|\\S+|\\[.*\\])"},marginY:{classes:lodashEs.map(CLASS_VALUES.margin,n=>`my-${n}`),regExp:"-?my-(\\d+|\\S+|\\[.*\\])"},marginTop:{classes:lodashEs.map(CLASS_VALUES.margin,n=>`mt-${n}`),regExp:"-?mt-(\\d+|\\S+|\\[.*\\])"},marginRight:{classes:lodashEs.map(CLASS_VALUES.margin,n=>`mr-${n}`),regExp:"-?mr-(\\d+|\\S+|\\[.*\\])"},marginBottom:{classes:lodashEs.map(CLASS_VALUES.margin,n=>`mb-${n}`),regExp:"-?mb-(\\d+|\\S+|\\[.*\\])"},marginLeft:{classes:lodashEs.map(CLASS_VALUES.margin,n=>`ml-${n}`),regExp:"-?ml-(\\d+|\\S+|\\[.*\\])"},spaceX:{classes:lodashEs.map(CLASS_VALUES.space,n=>`space-x-${n}`),regExp:"-?space-x-(\\d+|\\S+|\\[.*\\])"},spaceY:{classes:lodashEs.map(CLASS_VALUES.space,n=>`space-y-${n}`),regExp:"-?space-y-(\\d+|\\S+|\\[.*\\])"},boxShadow:{classes:lodashEs.map(["sm","md","lg","xl","2xl","inner","none"],n=>`shadow-${n}`),regExp:"shadow-(sm|md|lg|xl|2xl|inner|none)"},minWidth:{classes:["min-w-0","min-w-full","min-w-min","min-w-max","min-w-fit"],regExp:"min-w-(\\d+|\\S+|\\[.*\\])"},maxWidth:{classes:lodashEs.map(CLASS_VALUES.maxWidth,n=>`max-w-${n}`),regExp:"max-w-(\\d+|\\S+|\\[.*\\])"},width:{classes:lodashEs.map([...CLASS_VALUES.width,"full","screen","min","max","fit"],n=>`w-${n}`),regExp:"w-(\\d+.\\d+|\\d+|px|auto|full|screen|min|max|fit|\\[.*\\])$"},minHeight:{classes:["min-h-0","min-h-full","min-h-screen","min-h-min","min-h-max","min-h-fit"],regExp:"min-h-(\\d+|\\S+|\\[.*\\])"},maxHeight:{classes:lodashEs.map(CLASS_VALUES.maxHeight,n=>`max-h-${n}`),regExp:"max-h-(\\d+|\\S+|\\[.*\\])"},height:{classes:lodashEs.map(CLASS_VALUES.height,n=>`h-${n}`),regExp:"h-(\\d+.\\d+|\\d+|px|auto|full|screen|min|max|fit|\\[.*\\])"},fontFamily:{classes:["font-heading","font-body","font-sans","font-serif","font-mono"],regExp:"font-(heading|body|sans|serif|mono)"},textAlign:{classes:["text-left","text-center","text-right","text-justify"],regExp:"text-(left|center|right|justify)"},textOverflow:{classes:["truncate","text-ellipsis","text-clip"],regExp:"truncate|text-ellipsis|text-clip"},verticalAlign:{classes:["align-baseline","align-top","align-middle","align-bottom","align-text-top","align-text-bottom","align-sub","align-super"],regExp:"align-(baseline|top|middle|bottom|text-top|text-bottom|sub|super)"},fontSize:{classes:["text-xs","text-sm","text-base","text-lg","text-xl","text-2xl","text-3xl","text-4xl","text-5xl","text-6xl","text-7xl","text-8xl","text-9xl"],regExp:"text-(\\d+|\\S+|\\[.*\\])"},fontSmoothing:{classes:["antialiased","subpixel-antialiased"],regExp:"antialiased|subpixel-antialiased"},fontStyle:{classes:["italic","not-italic"],regExp:"not-italic|italic"},fontWeight:{classes:["font-thin","font-extralight","font-light","font-normal","font-medium","font-semibold","font-bold","font-extrabold","font-black"],regExp:"font-(thin|extralight|light|normal|medium|semibold|bold|extrabold|black)"},fontVariantNum:{classes:["normal-nums","ordinal","diagonal-fractions","stacked-fractions","tabular-nums","oldstyle-nums","proportional-nums","lining-nums","slashed-zero"],regExp:"normal-nums|ordinal|diagonal-fractions|stacked-fractions|tabular-nums|oldstyle-nums|proportional-nums|lining-nums|slashed-zero"},letterSpacing:{classes:["tracking-tighter","tracking-tight","tracking-normal","tracking-wide","tracking-wider","tracking-widest"],regExp:"-?tracking-(tighter|tight|normal|wide|wider|widest|\\[.*\\])"},lineHeight:{classes:["leading-none","leading-tight","leading-snug","leading-normal","leading-relaxed","leading-loose","leading-3","leading-4","leading-5","leading-6","leading-7","leading-8","leading-9","leading-10"],regExp:"leading-(none|tight|snug|normal|relaxed|loose|\\[.*\\]|\\d+)"},listStyleType:{classes:["list-none","list-disc","list-decimal"],regExp:"list-(none|disc|decimal)"},listStylePosition:{classes:["list-inside","list-outside"],regExp:"list-(inside|outside)"},textUnderlineOffset:{classes:["underline-offset-auto","underline-offset-0","underline-offset-1","underline-offset-2","underline-offset-4","underline-offset-8"],regExp:"underline-offset-(auto|\\d+|\\S+)"},textDecoration:{classes:["underline","overline","line-through","no-underline"],regExp:"underline|overline|line-through|no-underline"},textDecorationColor:{classes:[],regExp:"decoration-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},textTransform:{classes:["uppercase","lowercase","capitalize","normal-case"],regExp:"uppercase|lowercase|capitalize|normal-case"},textIndent:{classes:lodashEs.map(CLASS_VALUES.indent,n=>`indent-${n}`),regExp:"-?indent-(\\d+|\\S+)"},whitespace:{classes:["whitespace-normal","whitespace-nowrap","whitespace-pre","whitespace-pre-line","whitespace-pre-wrap"],regExp:"whitespace-(normal|nowrap|pre|pre-line|pre-wrap)"},wordBreak:{classes:["break-normal","break-words","break-all"],regExp:"break-(normal|words|all)"},content:{classes:["content-none"],regExp:"content-none"},backgroundAttachment:{classes:lodashEs.map(["fixed","local","scroll"],n=>`bg-${n}`),regExp:"bg-(fixed|local|scroll)"},backgroundColor:{classes:[],regExp:"bg-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},backgroundPosition:{classes:["bg-bottom","bg-center","bg-left","bg-left-bottom","bg-left-top","bg-right","bg-right-bottom","bg-right-top","bg-top"],regExp:"bg-(bottom|center|left|left-bottom|left-top|right|right-bottom|right-top|top)"},backgroundRepeat:{classes:["bg-repeat","bg-repeat-x","bg-repeat-y","bg-no-repeat","bg-repeat-round","bg-repeat-space"],regExp:"bg-(repeat|repeat-x|repeat-y|no-repeat|repeat-round|repeat-space)"},backgroundSize:{classes:["bg-auto","bg-cover","bg-contain"],regExp:"bg-(auto|cover|contain)"},backgroundGradient:{classes:["bg-gradient-none","bg-gradient-to-t","bg-gradient-to-tr","bg-gradient-to-r","bg-gradient-to-br","bg-gradient-to-b","bg-gradient-to-bl","bg-gradient-to-l","bg-gradient-to-tl"],regExp:"bg-gradient-(none|to-(t|tr|r|br|b|bl|l|tl))"},viaColor:{classes:[],regExp:"via-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},toColor:{classes:[],regExp:"to-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},position:{classes:["static","fixed","absolute","relative","sticky"],regExp:"(static|fixed|absolute|relative|sticky)"},borderRadiusTopLeft:{classes:["rounded-tl",...lodashEs.map(CLASS_VALUES.borderRadius,n=>`rounded-tl-${n}`)],regExp:"rounded-tl-?(\\d+|\\S+)?"},borderRadiusTopRight:{classes:["rounded-tr",...lodashEs.map(CLASS_VALUES.borderRadius,n=>`rounded-tr-${n}`)],regExp:"rounded-tr-?(\\d+|\\S+)?"},borderRadiusBottomRight:{classes:["rounded-br",...lodashEs.map(CLASS_VALUES.borderRadius,n=>`rounded-br-${n}`)],regExp:"rounded-br-?(\\d+|\\S+)?"},borderRadiusBottomLeft:{classes:["rounded-bl",...lodashEs.map(CLASS_VALUES.borderRadius,n=>`rounded-bl-${n}`)],regExp:"rounded-bl-?(\\d+|\\S+)?"},borderRadiusTop:{classes:["rounded-t",...lodashEs.map(CLASS_VALUES.borderRadius,n=>`rounded-t-${n}`)],regExp:"rounded-t-?(\\d+|\\S+)?"},borderRadiusRight:{classes:["rounded-r",...lodashEs.map(CLASS_VALUES.borderRadius,n=>`rounded-r-${n}`)],regExp:"rounded-r-?(\\d+|\\S+)?"},borderRadiusBottom:{classes:["rounded-b",...lodashEs.map(CLASS_VALUES.borderRadius,n=>`rounded-b-${n}`)],regExp:"rounded-b-?(\\d+|\\S+)?"},borderRadiusLeft:{classes:["rounded-l",...lodashEs.map(CLASS_VALUES.borderRadius,n=>`rounded-l-${n}`)],regExp:`(rounded-l-(${CLASS_VALUES.borderRadius.join("|")})|rounded-l$)`},borderRadius:{classes:["rounded",...lodashEs.map(CLASS_VALUES.borderRadius,n=>`rounded-${n}`)],regExp:`(rounded-(${CLASS_VALUES.borderRadius.join("|")}$)|rounded)`},borderX:{classes:["border-x",...lodashEs.map(CLASS_VALUES.borderWidth,n=>`border-x-${n}`)],regExp:"border-x-?(\\d+|\\S+|\\[.*\\])?"},borderY:{classes:["border-y",...lodashEs.map(CLASS_VALUES.borderWidth,n=>`border-y-${n}`)],regExp:"border-y-?(\\d+|\\S+|\\[.*\\])?"},borderTop:{classes:["border-t",...lodashEs.map(CLASS_VALUES.borderWidth,n=>`border-t-${n}`)],regExp:"border-t-?(\\d+|\\S+|\\[.*\\])?"},borderRight:{classes:["border-r",...lodashEs.map(CLASS_VALUES.borderWidth,n=>`border-r-${n}`)],regExp:"border-r-?(\\d+|\\S+|\\[.*\\])?"},borderBottom:{classes:["border-b",...lodashEs.map(CLASS_VALUES.borderWidth,n=>`border-b-${n}`)],regExp:"border-b-?(\\d+|\\S+|\\[.*\\])?"},borderLeft:{classes:["border-l",...lodashEs.map(CLASS_VALUES.borderWidth,n=>`border-l-${n}`)],regExp:"border-l-?(\\d+|\\S+|\\[.*\\])?"},borderColor:{classes:[],regExp:"^border-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\w+-\\d+|\\[#[0-9a-fA-F]+\\])$"},border:{classes:["border",...lodashEs.map(CLASS_VALUES.borderWidth,n=>`border-${n}`)],regExp:"^border(-\\d+|\\[\\d+px\\])?$"},order:{classes:lodashEs.map([...lodashEs.range(0,13),"first","last","none"],n=>`order-${n}`),regExp:"-?order-(\\d+|first|last|none)"},divideXWidth:{classes:lodashEs.map(["0",2,4,8],n=>`divide-x-${n}`),regExp:"divide-x-(\\d+|\\[.*\\])"},divideYWidth:{classes:lodashEs.map(["0",2,4,8],n=>`divide-y-${n}`),regExp:"divide-y-(\\d+|\\[.*\\])"},divideColor:{classes:[],regExp:"divide-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},divideStyle:{classes:lodashEs.map(["solid","dashed","dotted","double","none"],n=>`divide-${n}`),regExp:"divide-(solid|dashed|dotted|double|none)"},outlineWidth:{classes:lodashEs.map([0,1,2,4,8],n=>`outline-${n}`),regExp:"outline-(\\d+)"},outlineOffset:{classes:lodashEs.map([0,1,2,4,8],n=>`outline-offset-${n}`),regExp:"outline-offset-(\\d+)"},outlineColor:{classes:[],regExp:"outline-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},ringWidth:{classes:lodashEs.map([0,1,2,4,8,"inset"],n=>`ring-${n}`),regExp:"ring-(\\d+|inset)"},ringOffsetWidth:{classes:lodashEs.map([0,1,2,4,8],n=>`ring-offset-${n}`),regExp:"ring-offset-(\\d+)"},ringOffsetColor:{classes:[],regExp:"ring-offset-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},ringColor:{classes:[],regExp:"ring-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},boxShadowColor:{classes:[],regExp:"shadow-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},opacity:{classes:lodashEs.map([0,5,10,20,25,30,40,50,60,70,75,80,90,95,100],n=>`opacity-${n}`),regExp:"opacity-(\\d+|\\[.*\\])"},mixBlendMode:{classes:lodashEs.map(CLASS_VALUES.blendEffect,n=>`mix-blend-${n}`),regExp:"mix-blend-(\\d+|\\S+)"},bgBlendMode:{classes:lodashEs.map(CLASS_VALUES.blendEffect,n=>`bg-blend-${n}`),regExp:"bg-blend-(\\d+|\\S+)"},blur:{classes:lodashEs.map(["none","sm","md","lg","xl","2xl","3xl"],n=>`blur-${n}`),regExp:"blur-(none|sm|md|lg|xl|2xl|3xl)"},brightness:{classes:lodashEs.map([0,50,75,90,95,100,105,110,125,150,200],n=>`brightness-${n}`),regExp:"brightness-(\\d+)"},contrast:{classes:lodashEs.map([0,50,75,100,125,150,200],n=>`contrast-${n}`),regExp:"contrast-(\\d+)"},grayScale:{classes:["grayscale-0","grayscale"],regExp:"grayscale(-0)?"},hueRotate:{classes:lodashEs.map([0,15,30,60,90,180],n=>`hue-rotate-${n}`),regExp:"-?hue-rotate-(\\d+)"},invert:{classes:["invert-0","invert"],regExp:"invert(-0)?"},saturate:{classes:lodashEs.map([0,50,100,150,200],n=>`saturate-${n}`),regExp:"saturate-(\\d+)"},sepia:{classes:["sepia-0","sepia"],regExp:"sepia(-0)?"},transition:{classes:["transition-none","transition-all","transition-colors","transition-opacity","transition-shadow","transition-transform"],regExp:"transition-(none|all|colors|opacity|shadow|transform)"},duration:{classes:lodashEs.map([75,100,150,200,300,500,700,1e3],n=>`duration-${n}`),regExp:"duration-(\\d+|\\[.*\\])"},transitionEase:{classes:["ease-linear","ease-in","ease-out","ease-in-out"],regExp:"eas(e-linear|e-in|e-out|e-in-out)"},transitionDelay:{classes:lodashEs.map([75,100,150,200,300,500,700,1e3],n=>`delay-${n}`),regExp:"delay-(\\d+|\\[.*\\])"},animation:{classes:["animate-none","animate-spin","animate-ping"],regExp:"animate-(none|spin|ping)"},scaleX:{classes:lodashEs.map(CLASS_VALUES.scale,n=>`scale-x-${n}`),regExp:"-?scale-x-(\\d+|\\S+|\\[.*\\])"},scaleY:{classes:lodashEs.map(CLASS_VALUES.scale,n=>`scale-y-${n}`),regExp:"-?scale-y-(\\d+|\\S+|\\[.*\\])"},scale:{classes:lodashEs.map(CLASS_VALUES.scale,n=>`scale-${n}`),regExp:"-?scale-(\\d+|\\S+|\\[.*\\])"},rotate:{classes:lodashEs.map([0,1,2,3,6,12,45,90,180],n=>`rotate-${n}`),regExp:"-?rotate-(\\d+|\\S+|\\[.*\\])"},translateX:{classes:lodashEs.map([0,"px","0.5",1],n=>`translate-x-${n}`),regExp:"-?translate-x-(\\d+|\\S+|\\[.*\\])"},translateY:{classes:lodashEs.map([0,"px","0.5",1],n=>`translate-y-${n}`),regExp:"-?translate-y-(\\d+|\\S+|\\[.*\\])"},skewX:{classes:lodashEs.map([0,1,2,3,6,12],n=>`skew-x-${n}`),regExp:"-?skew-x-(\\d+|\\S+|\\[.*\\])"},skewY:{classes:lodashEs.map([0,1,2,3,6,12],n=>`skew-y-${n}`),regExp:"-?skew-y-(\\d+|\\S+|\\[.*\\])"},accentColor:{classes:[],regExp:"accent-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},appearance:{classes:["appearance-none"],regExp:"appearance-none"},cursor:{classes:["cursor-auto","cursor-default","cursor-pointer","cursor-wait","cursor-text","cursor-move","cursor-help","cursor-not-allowed"],regExp:"cursor-(auto|default|pointer|wait|text|move|help|not-allowed)"},caretColor:{classes:[],regExp:"caret-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},pointerEvents:{classes:["pointer-events-none","pointer-events-auto"],regExp:"pointer-events-(none|auto)"},userSelect:{classes:["select-none","select-text","select-all","select-auto"],regExp:"select-(none|text|all|auto)"},fill:{classes:[],regExp:"caret-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},stroke:{classes:[],regExp:"caret-(black|transparent|current|white|__THEME_COLORS_REGEXP__|\\S+-\\d+)"},strokeWidth:{classes:["stroke-0","stroke-1","stroke-2"],regExp:"stroke-(\\d+|\\[.*\\])"}},colorOptions={backgroundColor:"bg",textColor:"text",borderColor:"border",boxShadowColor:"shadow",outlineColor:"outline",divideColor:"divide",fromColor:"from",viaColor:"via",toColor:"to",ringColor:"ring",ringOffsetColor:"ring-offset"},soloColors=["current","inherit","transparent","black","white"],shadedColors=["slate","gray","zinc","neutral","stone","red","orange","amber","yellow","lime","green","emerald","teal","cyan","sky","blue","indigo","violet","purple","fuchsia","pink","rose"],shades=["50","100","200","300","400","500","600","700","800","900"],colorKeys=lodashEs.map(lodashEs.values(colorOptions),n=>n),ALL_COLORS=lodashEs.flattenDeep([...lodashEs.map(soloColors,n=>lodashEs.flatten(lodashEs.map(colorKeys,c=>`${c}-${n}`))),...lodashEs.map(shadedColors,n=>lodashEs.flattenDeep(lodashEs.map(colorKeys,c=>lodashEs.flattenDeep(lodashEs.map(shades,d=>`${c}-${n}-${d}`)))))]),ALL_TW_CLASSES=lodashEs.map(lodashEs.flattenDeep(lodashEs.values(CLASSES_LIST).map(n=>n.classes).concat(ALL_COLORS)),n=>({name:n})),useFuseSearch=()=>{const n=useThemeOptions(),c=React.useMemo(()=>{let d=[];if(n.colors){const x=lodashEs.flattenDeep(lodashEs.map(n.colors,({items:b})=>lodashEs.keys(b)));d=lodashEs.flattenDeep(lodashEs.map(x,b=>lodashEs.flatten(lodashEs.map(colorKeys,y=>`${y}-${b}`))))}return n.fontFamily&&(d=[...d,...lodashEs.map(lodashEs.keys(n.fontFamily),x=>`${x}`)]),lodashEs.map(d,x=>({name:x}))},[n]);return React.useMemo(()=>new Fuse([...ALL_TW_CLASSES,...c],{isCaseSensitive:!1,threshold:.2,minMatchCharLength:2,keys:["name"]}),[c])},useTailwindClassList=()=>{const n=useThemeOptions(),c=React.useMemo(()=>{if(n.colors){const b=lodashEs.flattenDeep(lodashEs.map(n.colors,({items:y})=>lodashEs.keys(y)));lodashEs.each(CLASSES_LIST,(y,R)=>{lodashEs.set(CLASSES_LIST,`${R}.regExp`,y.regExp.replace("__THEME_COLORS_REGEXP__",b.join("|")))})}return CLASSES_LIST},[n]),d=React.useCallback((b,y)=>{const R=lodashEs.get(c,`${b}.regExp`,"");return y.match(new RegExp(R))},[c]),x=React.useCallback((b,y=[])=>lodashEs.get(c,`${b}.classes`,y),[c]);return{match:d,getClasses:x}};function getMqForCls(n){if(lodashEs.isEmpty(n.trim()))return"";const c=n.match(/sm:|md:|lg:|xl:|2xl:/g);return lodashEs.get(c,0,"xs").replace(":","")}function getModForCls(n){const c=lodashEs.map(MODIFIERS,x=>`${x}:`).join("|"),d=new RegExp(c,"g");return lodashEs.get(d.exec(n.trim()),0,"").replace(":","")}function getPureClsName(n){return n.trim().split(":").pop()||""}const memoizedProps={};function getPropertyForClass(n){if(lodashEs.isEmpty(n))return"";if(memoizedProps[n])return memoizedProps[n];let c="";for(const d in CLASSES_LIST){const x=lodashEs.get(CLASSES_LIST,`${d}.regExp`,"");if(new RegExp(x,"g").test(n)){c=d,memoizedProps[n]=c;break}}return c}function constructClassObject(n){return lodashEs.isEmpty(n)?null:{dark:lodashEs.startsWith(n,"dark:"),mq:getMqForCls(n),mod:getModForCls(n),cls:getPureClsName(n),fullCls:n,property:getPropertyForClass(n)}}function generateFullClsName(n){let c="";return n.dark&&(c+="dark:"),n.mq.toLowerCase()!=="xs"&&(c+=`${n.mq}:`),n.mod&&(c+=`${n.mod}:`),c+=n.cls,c}function orderClassesByBreakpoint(n){n=n.replace(/\s+/g," ");const c=n.split(" ").map(constructClassObject),d=["xs","sm","md","lg","xl","2xl"];return c.sort((x,b)=>d.indexOf(x.mq)-d.indexOf(b.mq)).map(x=>x.fullCls).join(" ")}function removeDuplicateClasses(n){if(n=n.replace(/\s+/g," "),!n)return"";const c=["xs","sm","md","lg","xl","2xl"],d=n.split(" ").map(constructClassObject);let x=n;if(d.length===1)return d[0].fullCls;for(const b of d){const y=b.property,R=c.indexOf(b.mq);for(let S=R+1;S<c.length;S++){const _=c[S],A=d.find(L=>L.property===y&&L.mq===_);if(A&&A.cls===b.cls)x=x.replace(A.fullCls,"");else if(A&&A.cls!==b.cls)break}}return x.replace(/\s+/g," ").trim()}const selectedStylingBlocksAtom=jotai.atom([]);selectedStylingBlocksAtom.debugLabel="selectedStylingBlocksAtom";const useSelectedStylingBlocks=()=>jotai.useAtom(selectedStylingBlocksAtom),addClassesToBlocksAtom=jotai.atom(null,(n,c,{blockIds:d,newClasses:x})=>{const b=lodashEs.filter(n(pageBlocksAtomsAtom),R=>d.includes(n(R)._id)),y=lodashEs.first(n(selectedStylingBlocksAtom));return lodashEs.map(b,R=>{const S=n(R),_=lodashEs.get(S,y.prop,`${applyBinding.STYLES_KEY},`),{classes:A}=applyBinding.getSplitChaiClasses(_);return{ids:[S._id],props:{[y.prop]:`${applyBinding.STYLES_KEY},${orderClassesByBreakpoint(removeDuplicateClasses(tailwindMerge.twMerge(A,x)))}`}}})}),useAddClassesToBlocks=()=>{const n=jotai.useSetAtom(addClassesToBlocksAtom),{updateBlocks:c,updateBlocksRuntime:d}=useBlocksStoreUndoableActions();return React.useCallback((x,b,y=!1)=>{const R=n({blockIds:x,newClasses:b});if(!y){d(x,R[0].props);return}c(x,R[0].props)},[n,c,d])},LANGUAGES={ab:"Abkhazian",aa:"Afar",af:"Afrikaans",ak:"Akan",sq:"Albanian",am:"Amharic",ar:"Arabic",an:"Aragonese",hy:"Armenian",as:"Assamese",av:"Avaric",ae:"Avestan",ay:"Aymara",az:"Azerbaijani",bm:"Bambara",ba:"Bashkir",eu:"Basque",be:"Belarusian",bn:"Bengali",bh:"Bihari",bi:"Bislama",bs:"Bosnian",br:"Breton",bg:"Bulgarian",my:"Burmese",ca:"Catalan",ch:"Chamorro",ce:"Chechen",ny:"Chichewa",zh:"Chinese","zh-Hans":"Chinese (Simplified)","zh-Hant":"Chinese (Traditional)",cv:"Chuvash",kw:"Cornish",co:"Corsican",cr:"Cree",hr:"Croatian",cs:"Czech",da:"Danish",dv:"Maldivian",nl:"Dutch",dz:"Dzongkha",en:"English",eo:"Esperanto",et:"Estonian",ee:"Ewe",fo:"Faroese",fj:"Fijian",fi:"Finnish",fr:"French",ff:"Fula, Pular",gl:"Galician",gd:"Gaelic (Scottish)",gv:"Manx",ka:"Georgian",de:"German",el:"Greek",kl:"Kalaallisut",gn:"Guarani",gu:"Gujarati",ht:"Haitian Creole",ha:"Hausa",he:"Hebrew",hz:"Herero",hi:"Hindi",ho:"Hiri Motu",hu:"Hungarian",is:"Icelandic",io:"Ido",ig:"Igbo",id:"Indonesian",ia:"Interlingua",ie:"Interlingue",iu:"Inuktitut",ik:"Inupiak",ga:"Irish",it:"Italian",ja:"Japanese",jv:"Javanese",kn:"Kannada",kr:"Kanuri",ks:"Kashmiri",kk:"Kazakh",km:"Khmer",ki:"Kikuyu",rw:"Kinyarwanda",rn:"Kirundi",ky:"Kyrgyz",kv:"Komi",kg:"Kongo",ko:"Korean",ku:"Kurdish",kj:"Kwanyama",lo:"Lao",la:"Latin",lv:"Latvian",li:"Limburgish",ln:"Lingala",lt:"Lithuanian",lu:"Luga-Katanga",lg:"Luganda, Ganda",lb:"Luxembourgish",mk:"Macedonian",mg:"Malagasy",ms:"Malay",ml:"Malayalam",mt:"Maltese",mi:"Maori",mr:"Marathi",mh:"Marshallese",mo:"Moldavian",mn:"Mongolian",na:"Nauru",nv:"Navajo",ng:"Ndonga",nd:"Northern Ndebele",ne:"Nepali",no:"Norwegian",nb:"Norwegian bokmål",nn:"Norwegian nynorsk",ii:"Sichuan Yi",oc:"Occitan",oj:"Ojibwe",cu:"Old Church Slavonic",or:"Oriya",om:"Oromo",os:"Ossetian",pi:"Pāli",ps:"Pashto, Pushto",fa:"Persian (Farsi)",pl:"Polish",pt:"Portuguese",pa:"Punjabi (Eastern)",qu:"Quechua",rm:"Romansh",ro:"Romanian",ru:"Russian",se:"Sami",sm:"Samoan",sg:"Sango",sa:"Sanskrit",sr:"Serbian",sh:"Serbo-Croatian",st:"Sesotho",tn:"Setswana",sn:"Shona",sd:"Sindhi",si:"Sinhalese",ss:"Swati",sk:"Slovak",sl:"Slovenian",so:"Somali",nr:"Southern Ndebele",es:"Spanish",su:"Sundanese",sw:"Swahili (Kiswahili)",sv:"Swedish",tl:"Tagalog",ty:"Tahitian",tg:"Tajik",ta:"Tamil",tt:"Tatar",te:"Telugu",th:"Thai",bo:"Tibetan",ti:"Tigrinya",to:"Tonga",ts:"Tsonga",tr:"Turkish",tk:"Turkmen",tw:"Twi",ug:"Uyghur",uk:"Ukrainian",ur:"Urdu",uz:"Uzbek",ve:"Venda",vi:"Vietnamese",vo:"Volapük",wa:"Wallon",cy:"Welsh",wo:"Wolof",fy:"Western Frisian",xh:"Xhosa",yi:"Yiddish",yo:"Yoruba",za:"Zhuang, Chuang",zu:"Zulu"},updatePropsForLanguage=(n,c,d)=>{const x=runtime.getRegisteredChaiBlock(lodashEs.get(d,"_type"));if(!x)return n;const b={...n};return lodashEs.forEach(lodashEs.keys(n),y=>{if(lodashEs.includes(lodashEs.get(x,"i18nProps",[]),y)&&!lodashEs.isEmpty(c)){const R=`${y}-${c}`;lodashEs.set(b,R,n[y]),lodashEs.unset(b,y)}}),b},useUpdateBlocksProps=()=>{const{updateBlocks:n}=useBlocksStoreUndoableActions(),{selectedLang:c}=useLanguages(),d=useSelectedBlock();return React.useCallback((x,b,y)=>{const R=updatePropsForLanguage(b,c,d);n(x,R,y)},[c,d,n])},useUpdateMultipleBlocksProps=()=>{const{updateMultipleBlocksProps:n}=useBlocksStoreUndoableActions();return React.useCallback(c=>{n(c)},[n])},useFakeStreamEffect=()=>{const{updateBlocksRuntime:n}=useBlocksStoreUndoableActions();return React.useCallback(async(c,d,x=30)=>{const b=lodashEs.keys(lodashEs.omit(d,["_id"]));for(const y of b){const R=d[y];if(lodashEs.isString(R)){const S=lodashEs.chunk(R.split(""),12);let _="";n([c],{[y]:""});for(let A=0;A<S.length;A++)_+=S[A].join(""),n([c],{[y]:_}),await new Promise(L=>setTimeout(L,x))}}},[n])},useStreamMultipleBlocksProps=()=>{const{updateMultipleBlocksProps:n}=useBlocksStoreUndoableActions(),c=useFakeStreamEffect();return React.useCallback(async d=>{for(const x of d)await c(x._id,x);n(d)},[c,n])},useUpdateBlocksPropsRealtime=()=>{const{updateBlocksRuntime:n}=useBlocksStoreUndoableActions(),{selectedLang:c}=useLanguages(),d=useSelectedBlock();return React.useCallback((x,b)=>{const y=updatePropsForLanguage(b,c,d);n(x,y)},[c,d,n])};function getChildBlocks$1(n,c,d){d.push(lodashEs.find(n,{_id:c}));const x=lodashEs.filter(n,{_parent:c});for(const b of x)d.push(...getBlockWithChildren(b._id,n));return d}const getBlockWithChildren=(n,c)=>{let d=[];return d=lodashEs.flattenDeep([...d,...getChildBlocks$1(c,n,d)]),d},pickOnlyAIProps=(n,c,d)=>lodashEs.compact(n.map(x=>{const b=["_id","_type","_parent"],y=lodashEs.pick(x,b),R=runtime.getRegisteredChaiBlock(x._type),S={},_=lodashEs.get(R,"aiProps",[]);for(const A in x)if(!b.includes(A)&&_.includes(A)){const L=lodashEs.get(x,`${A}-${c}`,""),T=lodashEs.get(x,A,"");S[A]=lodashEs.isString(L)&&L.trim()||T,d&&(S[A]=T)}return lodashEs.isEmpty(S)?!1:(lodashEs.has(y,"_parent")&&lodashEs.isEmpty(y._parent)&&delete y._parent,{...y,...S})})),addLangToPrompt=(n,c,d)=>!c||d!=="content"?n:`${n}. Generate content in ${lodashEs.get(LANGUAGES,c,c)} language.`,askAiProcessingAtom=jotai.atom(!1),useAskAi=()=>{const[n,c]=jotai.useAtom(askAiProcessingAtom),[d,x]=React.useState(null),b=useBuilderProp("askAiCallBack",null),y=useStreamMultipleBlocksProps(),R=useUpdateMultipleBlocksProps(),[S]=useBlocksStore(),{selectedLang:_,fallbackLang:A}=useLanguages(),L=_.length?_:A,T=(O,U)=>{const M=lodashEs.cloneDeep(U.find(D=>D._id===O));for(const D in M){const K=M[D];if(typeof K=="string"&&lodashEs.startsWith(K,applyBinding.STYLES_KEY)){const{baseClasses:$,classes:ee}=applyBinding.getSplitChaiClasses(K);M[D]=lodashEs.compact(lodashEs.flattenDeep([$,ee])).join(" ")}else D!=="_id"&&delete M[D]}return M};return{askAi:React.useCallback(async(O,U,M,D)=>{if(b){c(!0),x(null);try{const K=_===A?"":_,$=M.toLowerCase().includes("translate the content"),ee=O==="content"?pickOnlyAIProps(lodashEs.cloneDeep(getBlockWithChildren(U,S)),_,$):[T(U,S)],ae=await b(O,addLangToPrompt(M,L,O),ee,K),{blocks:Re,error:ye}=ae;if(ye){x(ye);return}if(O==="styles"){const de=Re.map(q=>{for(const he in q)he!=="_id"&&(q[he]=`${applyBinding.STYLES_KEY},${q[he]}`);return q});R(de)}else y(Re);D&&D(ae)}catch(K){x(K)}finally{c(!1),D&&D()}}},[b,c,_,A,S,L,R,y]),loading:n,error:d}},partialBlocksStoreAtom=jotai.atom({}),partialBlocksLoadingStateAtom=jotai.atom({}),usePartialBlocksStore=()=>{const[n,c]=jotai.useAtom(partialBlocksStoreAtom),d=React.useCallback(b=>lodashEs.get(n,b,[]),[n]),x=React.useCallback(()=>c({}),[c]);return{getPartailBlocks:d,reset:x}},useWatchPartailBlocks=()=>{const[n]=useBlocksStore(),[c,d]=jotai.useAtom(partialBlocksStoreAtom),[x,b]=jotai.useAtom(partialBlocksLoadingStateAtom),y=useBuilderProp("getPartialBlockBlocks",async S=>[]),R=React.useMemo(()=>n.filter(S=>S._type==="PartialBlock"||S._type==="GlobalBlock").map(S=>lodashEs.get(S,"partialBlockId",lodashEs.get(S,"globalBlock",""))),[n]);React.useEffect(()=>{lodashEs.forEach(R,S=>{lodashEs.has(c,S)||lodashEs.get(x,`${S}.loading`,!1)||(b(_=>({..._,[S]:{loading:!0,error:null}})),y(S).then(_=>{d(A=>({...A,[S]:_})),b(A=>({...A,[S]:{loading:!1,error:null}}))}).catch(_=>{b(A=>({...A,[S]:{loading:!1,error:_.message}}))}))})},[y,c,x,d,b,R])},partialBlocksListAtom=jotai.atom({}),usePartialBlocksList=()=>{const[n,c]=React.useState(!1),[d,x]=React.useState(null),[b,y]=jotai.useAtom(partialBlocksListAtom),R=useBuilderProp("getPartialBlocks",async()=>[]),S=React.useCallback(async()=>{c(!0),x(null);try{const _=await R();y(_),c(!1)}catch(_){x(_ instanceof Error?_.message:"Failed to fetch partial blocks"),c(!1)}},[R,y]);return React.useEffect(()=>{S()},[]),{data:b,isLoading:n,refetch:S,error:d}},useBuilderReset=()=>{const{clear:n}=useUndoManager(),[,c]=useSelectedBlockIds(),{clearHighlight:d}=useBlockHighlight(),[,x]=useSelectedStylingBlocks(),[,b]=jotai.useAtom(aiAssistantActiveAtom),{reset:y}=usePartialBlocksStore(),{setSaveState:R}=useSavePage(),[,S]=useBlockRepeaterDataAtom();return()=>{S({}),c([]),x([]),d(),n(),b(!1),y(),R("SAVED")}},canvasZoomAtom=utils.atomWithStorage("canvasZoom",100),useCanvasZoom=()=>jotai.useAtom(canvasZoomAtom),codeEditorAtom=jotai.atom(null),useCodeEditor=()=>jotai.useAtom(codeEditorAtom),cutBlockIdsAtom=jotai.atom([]),useCutBlockIds=()=>{const[n,c]=jotai.useAtom(cutBlockIdsAtom),d=jotai.useSetAtom(copiedBlockIdsAtom),x=React.useCallback(b=>{c(b),d([])},[c,d]);return[n,x]},copiedBlockIdsAtom=jotai.atom([]),useCopyBlocks=()=>{const[n]=useBlocksStore(),[c,d]=jotai.useAtom(copiedBlockIdsAtom),x=jotai.useSetAtom(cutBlockIdsAtom),{getPartailBlocks:b}=usePartialBlocksStore(),y=useBuilderProp("flags.copyPaste",!0),R=React.useCallback(_=>_.some(A=>getDuplicatedBlocks(n,A,null).some(T=>T._type==="PartialBlock"||T._type==="GlobalBlock")),[n]),S=React.useCallback(async(_,A=!1)=>{try{if(lodashEs.isEmpty(_))return;d(_),x([]);const L={_chai_copied_blocks:_.flatMap(T=>{const O=getDuplicatedBlocks(n,T,null);if(!A)return O;let U=[];for(const M of O)if(M._type==="PartialBlock"||M._type==="GlobalBlock"){let D=b(M.partialBlockId);M._parent&&(D==null?void 0:D.length)>0&&(D=D.map(K=>(lodashEs.isEmpty(K._parent)&&lodashEs.set(K,"_parent",M._parent),K))),U=[...U,...D]}else U.push(M);return U})};if(!y)return;if(!navigator.clipboard){sonner.toast.error("Clipboard not available.");return}sonner.toast.promise(navigator.clipboard.writeText(JSON.stringify(L)),{success:"Blocks copied successfully",error:"Failed to copy blocks to clipboard"})}catch(L){sonner.toast.error("Failed to copy blocks to clipboard"),console.error("Failed to copy blocks to clipboard:",L)}},[d,x,n]);return[c,S,R]},useCopyToClipboard=()=>{const[n,c]=React.useState(null),d=useBuilderProp("flags.copyPaste",!0),x=React.useCallback(async b=>{if(!d)return console.warn("Clipboard feature is disabled"),!1;if(!(navigator!=null&&navigator.clipboard))return console.warn("Clipboard not supported"),!1;try{return await navigator.clipboard.writeText(b),c(b),!0}catch(y){return console.warn("Copy failed",y),c(null),!1}},[]);return[n,x]},darkModeAtom=utils.atomWithStorage("darkMode",!1),useDarkMode=()=>{const[n,c]=jotai.useAtom(darkModeAtom);return[n,c]},useDuplicateBlocks=()=>{const[n]=useBlocksStore(),[,c]=useSelectedBlockIds(),{addBlocks:d}=useBlocksStoreUndoableActions();return React.useCallback((x,b=null)=>{const y=[];lodashEs.each(x,R=>{const S=n.find(O=>O._id===R);b?b==="root"&&(b=null):b=S._parent;const L=lodashEs.filter(n,O=>lodashEs.isString(b)?O._parent===b:!O._parent).indexOf(S)+1,T=getDuplicatedBlocks(n,R,b);d(T,b,L),y.push(lodashEs.get(T,"0._id",""))}),c(y)},[n,c])},highlightBlockIdAtom=jotai.atom(""),useHighlightBlockId=()=>jotai.useAtom(highlightBlockIdAtom),libraryBlocksAtom=jotai.atom({}),useLibraryBlocks=n=>{const[c,d]=jotai.useAtom(libraryBlocksAtom),x=React.useMemo(()=>(n==null?void 0:n.getBlocksList)||(()=>[]),[n]),b=lodashEs.get(c,`${n==null?void 0:n.id}.blocks`,null),y=lodashEs.get(c,`${n==null?void 0:n.id}.loading`,"idle"),R=React.useRef("idle");React.useEffect(()=>{(async()=>{if(!(y==="complete"||R.current==="loading")){R.current="loading",d(_=>({..._,[n==null?void 0:n.id]:{loading:"loading",blocks:[]}}));try{const _=await x(n);R.current="idle",d(A=>({...A,[n==null?void 0:n.id]:{loading:"complete",blocks:_||[]}}))}catch{R.current="idle",d(A=>({...A,[n==null?void 0:n.id]:{loading:"complete",blocks:[]}}))}}})()},[n,b,y,R,d,x]);const S=React.useCallback(_=>{d(A=>({...A,[_]:{loading:"idle",blocks:[]}}))},[d]);return{data:b||[],isLoading:y==="loading",resetLibrary:S}},useCanPaste=()=>{const[n]=useBlocksStore();return(c,d)=>{var y;const x=((y=lodashEs.find(n,{_id:d}))==null?void 0:y._type)||null,b=lodashEs.first(c.map(R=>{var S;return(S=lodashEs.find(n,{_id:R}))==null?void 0:S._type}));return canAcceptChildBlock(x,b)}},useMoveCutBlocks=()=>{const n=jotai.useAtomValue(presentBlocksAtom),{moveBlocks:c}=useBlocksStoreUndoableActions();return React.useCallback((d,x)=>{const b=Array.isArray(x)?x[0]:x;if(x==="root"){const y=n==null?void 0:n.filter(R=>!R._parent);c(d,null,(y==null?void 0:y.length)||0)}else{const y=n==null?void 0:n.filter(R=>R._parent===b);c(d,b,(y==null?void 0:y.length)||0)}},[c,n])},usePasteBlocks=()=>{const[n,c]=useCutBlockIds(),d=useMoveCutBlocks(),{addPredefinedBlock:x}=useAddBlock(),b=useCanPaste();return{canPaste:React.useCallback(async R=>{if(n.length>0)return b(n,R);try{const S=await navigator.clipboard.readText();if(S){const _=JSON.parse(S);return lodashEs.has(_,"_chai_copied_blocks")}}catch{return!1}return!1},[b,n]),pasteBlocks:React.useCallback(async R=>{const S=Array.isArray(R)?R[0]:R;if(!(navigator!=null&&navigator.permissions)){sonner.toast.error("Cannot check clipboard permissions.");return}try{if((await navigator.permissions.query({name:"clipboard-read"})).state==="denied"){sonner.toast.error("Clipboard paste permission denied. Please allow clipboard access.");return}}catch{sonner.toast.error("Failed to check clipboard permissions. Please allow clipboard access.");return}if(!lodashEs.isEmpty(n)){d(n,R),c([]),await navigator.clipboard.writeText("");return}sonner.toast.promise(async()=>{const _=await navigator.clipboard.readText();if(_){const A=JSON.parse(_);if(lodashEs.has(A,"_chai_copied_blocks"))x(A._chai_copied_blocks,S==="root"?null:S);else throw new Error("Nothing to paste")}else throw new Error("Nothing to paste")},{success:()=>"Blocks pasted successfully",error:()=>"Nothing to paste"})},[n,d,c])}},previewModeAtom=jotai.atom(!1),usePreviewMode=()=>{const[n,c]=jotai.useAtom(previewModeAtom);return[n,c]},removeClassFromBlocksAtom=jotai.atom(null,(n,c,{blockIds:d,fullClasses:x})=>{const b=lodashEs.first(n(selectedStylingBlocksAtom)),y=lodashEs.filter(n(pageBlocksAtomsAtom),R=>d.includes(n(R)._id));return lodashEs.map(y,R=>{const S=n(R),_=x;let{classes:A,baseClasses:L}=applyBinding.getSplitChaiClasses(lodashEs.get(S,b.prop,`${applyBinding.STYLES_KEY},`));return lodashEs.each(_,T=>{const O=T.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),U=new RegExp(`(^|\\s)${O}(?=\\s|$)`,"g");A=A.replace(U," ").replace(/\s+/g," ").trim();const M=lodashEs.first(T.split(":"));lodashEs.includes(["2xl","xl","lg","md","sm"],M)&&_.push(T.split(":").pop().trim())}),lodashEs.each(_,T=>{const O=T.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),U=new RegExp(`(^|\\s)${O}(?=\\s|$)`,"g");L=L.replace(U," ").replace(/\s+/g," ").trim()}),{ids:[S._id],props:{[b.prop]:`${applyBinding.STYLES_KEY}${L},${A}`}}})}),removeAllClassesForBlock=n=>{const c=Object.keys(n).filter(x=>typeof n[x]=="string"&&n[x].startsWith(applyBinding.STYLES_KEY)),d={};return c.forEach(x=>{d[x]=`${applyBinding.STYLES_KEY},`}),{ids:[n._id],props:d}},useRemoveAllClassesForBlock=()=>{const{updateBlocks:n,updateBlocksRuntime:c}=useBlocksStoreUndoableActions();return React.useCallback((d,x=!1)=>{const{ids:b,props:y}=removeAllClassesForBlock(d);x?n(b,y):c(b,y)},[n,c])},useRemoveClassesFromBlocks=()=>{const{updateBlocks:n,updateBlocksRuntime:c}=useBlocksStoreUndoableActions(),d=jotai.useSetAtom(removeClassFromBlocksAtom);return React.useCallback((x,b,y=!1)=>{const R=d({blockIds:x,fullClasses:b});y?n(x,R[0].props):c(x,R[0].props)},[d])},useResetBlockStyles=()=>{const n=useSelectedBlock(),c=useUpdateBlocksProps(),d=React.useCallback(R=>runtime.getDefaultBlockProps(R)||{},[]),x=React.useCallback(R=>Object.keys(R).filter(S=>typeof R[S]=="string"&&R[S].startsWith("#styles:")),[]),b=React.useCallback(R=>{if(!n)return;const _=d(n._type)[R]??"#styles:,";c([n._id],{[R]:_})},[n,d,c]);return{resetAll:React.useCallback(()=>{if(!n)return;const R=x(n);if(R.length===0)return;const S=d(n._type),_=lodashEs.pick(S,R);c([n._id],_)},[n,x,d,c]),reset:b}},useStylingBreakpoint=()=>jotai.useAtom(styleBreakpointAtom),canvasWidthAtom=utils.atomWithStorage("canvasWidth",800),canvasDisplayWidthAtom=utils.atomWithStorage("canvasDisplayWidth",800),canvasBreakpointAtom=jotai.atom(n=>{const c=n(canvasWidthAtom);return commonFunctions.getBreakpointValue(c).toLowerCase()}),useScreenSizeWidth=()=>{const[n,c]=jotai.useAtom(canvasWidthAtom),d=jotai.useAtomValue(canvasBreakpointAtom),[x,b]=useStylingBreakpoint();return React.useEffect(()=>{x!=="xs"&&b(d)},[d,x,b]),[n,d,c]},useCanvasDisplayWidth=()=>{const[n,c]=jotai.useAtom(canvasDisplayWidthAtom);return[n,c]},selectedBlockAllClassesAtom=jotai.atom(n=>{const c=lodashEs.first(n(selectedStylingBlocksAtom)),d=n(selectedBlockAtom);if(!c||c.blockId!==lodashEs.get(d,"_id",null))return[];const x=lodashEs.get(d,c.prop,`${applyBinding.STYLES_KEY},`),{classes:b}=applyBinding.getSplitChaiClasses(x);return lodashEs.filter(lodashEs.map(b.trim().split(" "),constructClassObject),y=>!lodashEs.isNull(y))}),useSelectedBlockAllClasses=()=>jotai.useAtomValue(selectedBlockAllClassesAtom),MQ={xs:0,sm:1,md:2,lg:3,xl:4,"2xl":5},selectedBlockCurrentClassesAtom=jotai.atom(n=>{const c=n(canvasBreakpointAtom),d=n(styleStateAtom),x=n(darkModeAtom),b=getQueries(c);let y=lodashEs.filter(n(selectedBlockAllClassesAtom),{mod:d});return lodashEs.startsWith(d,"_")||(y=lodashEs.filter(y,R=>b.includes(R.mq))),y=y.sort((R,S)=>MQ[R.mq]-MQ[S.mq]),x||(y=lodashEs.filter(y,{dark:!1})),y}),getQueries=n=>{let c=[];switch(n){case"xs":c=["xs"];break;case"sm":c=["xs","sm"];break;case"md":c=["xs","sm","md"];break;case"lg":c=["xs","sm","md","lg"];break;case"xl":c=["xs","sm","md","lg","xl"];break;case"2xl":c=["xs","sm","md","lg","xl","2xl"];break;default:c=["xs"];break}return c},useSelectedBlockCurrentClasses=()=>jotai.useAtomValue(selectedBlockCurrentClassesAtom),selectedBreakpointsAtom=utils.atomWithStorage("selectedBreakpoints",["XS","MD","XL"]),useSelectedBreakpoints=()=>{const[n,c]=jotai.useAtom(selectedBreakpointsAtom);return[n,c]},useStylingState=()=>jotai.useAtom(styleStateAtom),wrapperBlockAtom=jotai.atom(n=>{var R;const c=n(presentBlocksAtom),d=n(selectedBlockIdsAtom),x=d.length===1?d[0]:null;if(!x)return null;const b=lodashEs.find(c,{_id:x});if(!b)return null;let y=b._parent;for(;y;){const S=lodashEs.find(c,{_id:y});if(!S)return null;if((R=runtime.getRegisteredChaiBlock(S._type))!=null&&R.wrapper)return S;y=S._parent}return null});wrapperBlockAtom.debugLabel="wrapperBlockAtom";const useWrapperBlock=()=>jotai.useAtomValue(wrapperBlockAtom),useCanvasIframe=()=>jotai.useAtom(canvasIframeAtom),ATTRIBUTES_TO_REMOVE=["data-block-index","data-drop","data-style-id","data-block-parent","data-style-prop","data-highlighted"],CORE_BLOCKS$1=["Box","Button","Checkbox","Divider","EmptyBox","Form","FormButton","Heading","Image","Input","Label","LineBreak","Link","List","ListItem","Paragraph","Radio","RichText","Select","Span","Text","TextArea","Video"],cleanNode=n=>n.type==="element"&&["script","style","link"].includes(n.tagName||"")||n.type==="comment"?null:n.type==="text"?n:n.type==="element"&&n.attributes&&n.attributes.find(c=>c.key==="id"&&c.value==="add-block-bottom")?null:(n.type==="element"&&n.attributes&&(n.attributes=n.attributes.filter(c=>!ATTRIBUTES_TO_REMOVE.includes(c.key))),n.children&&(n.children=n.children.map(cleanNode).filter(c=>c!==null)),n),transformNode=(n,c,d={})=>{var y;if(n.type!=="element"||!n.attributes)return n;n.tagName==="span"&&n.attributes.find(S=>S.key==="role"&&S.value==="link")&&(n.tagName="a",n.attributes=n.attributes.filter(S=>S.key!=="role"));const x=n.attributes.find(R=>R.key==="data-block-type"),b=n.attributes.find(R=>R.key==="data-block-id");if(x){const R=x.value;if(CORE_BLOCKS$1.includes(R)||(y=d==null?void 0:d.EXTRA_CORE_BLOCKS)!=null&&y.includes(R))n.attributes=n.attributes.filter(S=>S.key!=="data-block-type"),n.children&&(n.children=n.children.map(S=>transformNode(S,c,d)));else{const S=`chai-${lodashEs.kebabCase(R)}`;n.tagName=S,b?n.attributes=[{key:"id",value:b.value}]:n.attributes=[],n.attributes.push({key:"chai-type",value:R});const _=runtime.getRegisteredChaiBlock(R),A=c.find(L=>L._id===(b==null?void 0:b.value));if(A&&n.attributes.push(...Object.entries(A).filter(([L])=>!["_id","_type","_parent","_index","_name"].includes(L)).map(([L,T])=>({key:L,value:typeof T=="string"?T:JSON.stringify(T)}))),_&&(_!=null&&_.description)&&n.attributes.push({key:"about-this-component",value:_.description}),_){if(_.canMove){const L=typeof _.canMove=="function"?_.canMove():_.canMove;n.attributes.push({key:"can-move",value:String(L)})}if(_.canDelete){const L=typeof _.canDelete=="function"?_.canDelete():_.canDelete;n.attributes.push({key:"can-delete",value:String(L)})}}R==="Icon"&&(n.attributes=n.attributes.filter(L=>L.key!=="icon")),_&&_.canAcceptBlock?n.children&&(n.children=n.children.map(L=>transformNode(L,c,d))):n.children=[]}}else n.children&&(n.children=n.children.map(R=>transformNode(R,c,d)));return n.attributes=n.attributes.filter(R=>R.key!=="data-block-type"&&R.key!=="data-block-id"),n},useBlocksHtmlForAi=()=>{const n=useSelectedBlock(),[c]=useBlocksStore(),[d]=useCanvasIframe();return React.useCallback(x=>{var L,T;if(!d)return"";const b=n!=null&&n._id?`[data-block-id="${n._id}"]`:"#canvas",y=(T=(L=d.contentDocument)==null?void 0:L.querySelector(b))==null?void 0:T[b==="#canvas"?"innerHTML":"outerHTML"];if(!y)return"";const _=himalaya.parse(y).map(cleanNode).filter(O=>O!==null).map(O=>transformNode(O,c,x));let A=himalaya.stringify(_);return A=A.replace(/#styles:,/g,"#styles:"),A.replace(/\s+/g," ").trim()},[n,d])},handlei18N=(n,c)=>n.map(d=>{const x=runtime.getRegisteredChaiBlock(d._type);if(!x)return d;const b=x.i18nProps;if(!b)return d;const y=lodashEs.filter(c,{_type:d._type}),R=lodashEs.pick(d,b);return lodashEs.each(R,(S,_)=>{const A=lodashEs.find(y,L=>{var U;const T=typeof L[_]=="string"?(U=L[_])==null?void 0:U.trim().toLowerCase():JSON.stringify(L[_]),O=typeof S=="string"?S.trim().toLowerCase():JSON.stringify(S);return T===O});if(A){const L=lodashEs.filter(Object.keys(A),O=>lodashEs.startsWith(O,`${_}-`)),T=lodashEs.pick(A,L);d={...d,...T}}}),d}),useHtmlToBlocks=()=>{const[n]=useBlocksStore();return React.useCallback(c=>{const d=runtime.syncBlocksWithDefaults(applyBinding.getBlocksFromHTML(c)),x=applyBinding.mergeBlocksWithExisting(d,n);return handlei18N(x,n)},[n])},getAllDescendantBlocks=(n,c)=>{const d=n.filter(b=>b._parent===c),x=d.flatMap(b=>getAllDescendantBlocks(n,b._id));return[...d,...x]},getBlockWithNestedChildren=(n,c)=>{const d=c.find(b=>b._id===n);if(!d)return[];const x=getAllDescendantBlocks(c,n);return[d,...x]},useI18nBlocks=()=>{const n=useSelectedBlock(),[c]=useBlocksStore();return React.useCallback((d="")=>{const x=n!=null&&n._id?getBlockWithNestedChildren(n._id,c):c;return x?lodashEs.compact(x.map(b=>{const y=runtime.getRegisteredChaiBlock(b._type);if(!y)return null;const R=(y==null?void 0:y.i18nProps)??[];if(R.length===0)return null;const S=d==="ALL"?Object.keys(b).filter(A=>R.find(L=>A.startsWith(L))):R.map(A=>d?`${A}-${d}`:A),_=lodashEs.pick(b,["_id"]);return lodashEs.each(S,A=>{_[A]=lodashEs.get(b,A,lodashEs.get(b,A.replace(`-${d}`,"")))}),_})):[]},[n==null?void 0:n._id,c])},inlineEditingActiveAtom=jotai.atom("");inlineEditingActiveAtom.debugLabel="inlineEditingActiveAtom";const inlineEditingItemIndexAtom=jotai.atom(0);inlineEditingItemIndexAtom.debugLabel="inlineEditingItemIndexAtom";const useInlineEditing=()=>{const[n,c]=jotai.useAtom(inlineEditingActiveAtom),[d,x]=jotai.useAtom(inlineEditingItemIndexAtom);return{editingBlockId:n,editingItemIndex:d,setEditingBlockId:c,setEditingItemIndex:x}};class PubSub{constructor(){Vu(this,"subscribers",new Map)}subscribe(c,d){return this.subscribers.has(c)||this.subscribers.set(c,new Set),this.subscribers.get(c).add(d),()=>{const x=this.subscribers.get(c);x&&(x.delete(d),x.size===0&&this.subscribers.delete(c))}}publish(c,d){const x=this.subscribers.get(c);x&&x.forEach(b=>b(d))}}const pubsub=new PubSub;function usePubSub(n,c){React.useEffect(()=>{const d=pubsub.subscribe(n,c);return()=>d()},[n,c])}const getAllDescendantIds=(n,c)=>{const d=n.filter(y=>y._parent===c),x=d.map(y=>y._id),b=d.flatMap(y=>getAllDescendantIds(n,y._id));return[...x,...b]},replaceBlock=(n,c,d)=>{const x=lodashEs.find(n,{_id:c});if(!x)return n;const b=n.findIndex(T=>T._id===c),y=getAllDescendantIds(n,c),R=new Set([c,...y]),S=n.filter(T=>!R.has(T._id)),_=new Set(d.map(T=>T._id)),A=d.map(T=>!T._parent||!_.has(T._parent)?{...T,_parent:x._parent}:T);return[...S.slice(0,b),...A,...S.slice(b)]},useReplaceBlock=()=>{const[n]=useBlocksStore(),[,c]=useSelectedBlockIds(),{setNewBlocks:d}=useBlocksStoreUndoableActions(),{hasPermission:x}=usePermissions();return React.useCallback((b,y)=>{if(!x(PERMISSIONS.EDIT_BLOCK))return;const R=b?replaceBlock(n,b,y):y;d(R),y.length>0&&setTimeout(()=>c([y[0]._id]),200)},[n,c,d,x])},BREAKPOINTS$1=[{name:"xs",minWidth:0},{name:"sm",minWidth:640},{name:"md",minWidth:768},{name:"lg",minWidth:1024},{name:"xl",minWidth:1280},{name:"2xl",minWidth:1536}],getBreakpointForWidth=n=>{for(let c=BREAKPOINTS$1.length-1;c>=0;c-=1){const d=BREAKPOINTS$1[c];if(n>=d.minWidth)return d.name}return BREAKPOINTS$1[0].name},useCanvasWidth=()=>{const n=typeof window<"u"?window.innerWidth:BREAKPOINTS$1[0].minWidth,[c,d]=React.useState(n);React.useEffect(()=>{if(typeof window>"u")return;const b=()=>{d(window.innerWidth)};return window.addEventListener("resize",b),b(),()=>window.removeEventListener("resize",b)},[]);const x=React.useMemo(()=>getBreakpointForWidth(c),[c]);return[c,x]},useSelectedLibrary=()=>jotai.useAtom(selectedLibraryAtom),sidebarActivePanelAtom=jotai.atom("outline");sidebarActivePanelAtom.debugLabel="sidebarActivePanelAtom";const useSidebarActivePanel=()=>jotai.useAtom(sidebarActivePanelAtom),ScalePercent=()=>{const[n]=useCanvasZoom();return jsxRuntime.jsxs("div",{className:"flex w-12 cursor-not-allowed items-center justify-center gap-x-1 space-x-0 font-medium text-gray-400",children:[jsxRuntime.jsx(reactIcons.ZoomInIcon,{className:"h-3.5 w-3.5 flex-shrink-0"})," ",jsxRuntime.jsxs("div",{className:"text-xs leading-3",children:[lodashEs.round(n,0),"%"]})]})},Breadcrumb=()=>{const n=useSelectedBlockHierarchy(),[,c]=useSelectedBlockIds(),{highlightBlock:d}=useBlockHighlight();return jsxRuntime.jsxs("div",{className:"-mx-2 flex items-center justify-between border-t border-border bg-background px-2 py-1 text-xs text-muted-foreground",children:[jsxRuntime.jsxs("ol",{className:"flex items-center whitespace-nowrap",children:[jsxRuntime.jsxs("li",{className:"inline-flex items-center",children:[jsxRuntime.jsx(tooltip.Button,{onClick:()=>c([]),variant:"ghost",className:"h-fit p-1 text-xs font-normal",children:"Body"}),jsxRuntime.jsx(reactIcons.ChevronRightIcon,{className:"h-4 w-4 rtl:rotate-180"})]}),lodashEs.reverse(n).map((x,b)=>jsxRuntime.jsxs("li",{className:"inline-flex items-center",children:[jsxRuntime.jsxs(tooltip.Button,{onMouseEnter:()=>{d(x==null?void 0:x._id)},onClick:()=>c([x==null?void 0:x._id]),variant:"ghost",className:"h-fit gap-x-1 p-1 text-xs font-normal",children:[jsxRuntime.jsx(TypeIcon,{type:x==null?void 0:x._type}),x._name||x._type]}),b!==n.length-1&&jsxRuntime.jsx(reactIcons.ChevronRightIcon,{className:"h-4 w-4 rtl:rotate-180"})]},b))]}),jsxRuntime.jsx("div",{className:"mr-2 flex items-center",children:jsxRuntime.jsx(ScalePercent,{})})]})},CHAI_BUILDER_EVENTS={OPEN_ADD_BLOCK:"OPEN_ADD_BLOCK",CLOSE_ADD_BLOCK:"CLOSE_ADD_BLOCK",SHOW_BLOCK_SETTINGS:"SHOW_BLOCK_SETTINGS",GOTO_BLOCK_SETTINGS:"GOTO_BLOCK_SETTINGS",CLEAR_CANVAS_SELECTION:"CLEAR_CANVAS_SELECTION",CANVAS_BLOCK_SELECTED:"CANVAS_BLOCK_SELECTED",CANVAS_BLOCK_STYLE_SELECTED:"CANVAS_BLOCK_STYLE_SELECTED",OPEN_EXPORT_CODE:"OPEN_EXPORT_CODE"},AddBlockDropdown=({block:n,children:c})=>{const{t:d}=reactI18next.useTranslation(),[x]=useBlocksStore(),{hasPermission:b}=usePermissions(),y=lodashEs.get(n,"_id"),R=lodashEs.get(n,"_parent"),S=lodashEs.filter(x,T=>R?lodashEs.get(T,"_parent")===R:!lodashEs.get(T,"_parent")),_=canAddChildBlock(lodashEs.get(n,"_type","")),A=lodashEs.findIndex(S,{_id:y}),L=T=>{if(T==="CHILD")pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK,n);else{const O={_id:R||"",position:S==null?void 0:S.length};T==="BEFORE"?O.position=Math.max(A,0):T==="AFTER"&&(O.position=A+1),pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK,O)}};return b(PERMISSIONS.ADD_BLOCK)?jsxRuntime.jsxs(tooltip.DropdownMenu,{children:[jsxRuntime.jsx(tooltip.DropdownMenuTrigger,{children:c}),jsxRuntime.jsxs(tooltip.DropdownMenuContent,{className:"border border-blue-500 bg-primary text-white shadow-2xl",children:[_&&jsxRuntime.jsx(tooltip.DropdownMenuItem,{className:"cursor-pointer text-xs",onClick:()=>L("CHILD"),children:d("Add inside")}),jsxRuntime.jsx(tooltip.DropdownMenuItem,{className:"cursor-pointer text-xs",onClick:()=>L("BEFORE"),children:d("Add before")}),jsxRuntime.jsx(tooltip.DropdownMenuItem,{className:"cursor-pointer text-xs",onClick:()=>L("AFTER"),children:d("Add after")})]})]}):null},dragAndDropAtom=jotai.atom(null),dropIndicatorAtom=jotai.atom({isVisible:!1,isValid:!1,position:"inside",placeholderOrientation:"horizontal",isEmpty:!1,top:0,left:0,width:0,height:0});let isDragging=!1;const setIsDragging=n=>{isDragging=n};let lastDragHighlighted=null,floatingLabel=null;function createFloatingLabel(n,c){const d=n.getAttribute("data-block-name"),x=n.getAttribute("data-block-type"),b=d||x||"Container",y=c.createElement("div");return y.className="chai-drag-parent-label",y.textContent=b,y.className="absolute top-0 -left-0.5 -translate-x-0.5 -translate-y-full -mt-1 bg-green-500/95 text-white px-2 py-1 text-xs font-semibold font-sans leading-tight whitespace-nowrap shadow-lg z-[999999] pointer-events-none select-none",y}function removeFloatingLabel(){floatingLabel&&floatingLabel.parentNode&&(floatingLabel.parentNode.removeChild(floatingLabel),floatingLabel=null)}const useDragParentHighlight=()=>{const[n]=useCanvasIframe(),c=React.useMemo(()=>{var b;return(n==null?void 0:n.contentDocument)||((b=n==null?void 0:n.contentWindow)==null?void 0:b.document)},[n]),d=React.useCallback(b=>{if(!c)return;let y=null;if(!b){lastDragHighlighted&&(lastDragHighlighted.style.outline="",lastDragHighlighted.style.outlineOffset="",lastDragHighlighted.style.backgroundColor="",lastDragHighlighted.style.position="",lastDragHighlighted=null),removeFloatingLabel();return}typeof b!="string"?y=b:y=c.querySelector(`[data-block-id="${b}"]`),!(y===lastDragHighlighted&&floatingLabel&&floatingLabel.parentNode)&&(lastDragHighlighted&&lastDragHighlighted!==y&&(lastDragHighlighted.style.outline="",lastDragHighlighted.style.outlineOffset="",lastDragHighlighted.style.backgroundColor="",lastDragHighlighted.style.position=""),removeFloatingLabel(),y?(y.style.outline="2px dashed rgba(34, 197, 94, 1)",y.style.outlineOffset="2px",y.style.backgroundColor="rgba(34, 197, 94, 0.05)",window.getComputedStyle(y).position==="static"&&(y.style.position="relative"),floatingLabel=createFloatingLabel(y,c),y.appendChild(floatingLabel),lastDragHighlighted=y):lastDragHighlighted=null)},[c]),x=React.useCallback(()=>{lastDragHighlighted&&(lastDragHighlighted.style.outline="",lastDragHighlighted.style.outlineOffset="",lastDragHighlighted.style.backgroundColor="",window.getComputedStyle(lastDragHighlighted).position==="relative"&&lastDragHighlighted.style.position==="relative"&&(lastDragHighlighted.style.position=""),lastDragHighlighted=null),removeFloatingLabel()},[]);return{highlightParent:d,clearParentHighlight:x,lastDragHighlighted}},useBlockDragEnd=()=>{const[,n]=jotai.useAtom(dragAndDropAtom),[,c]=jotai.useAtom(dropIndicatorAtom),[d]=useCanvasIframe(),{clearParentHighlight:x}=useDragParentHighlight(),b=d==null?void 0:d.contentDocument;return React.useCallback(()=>{n(null),c({isVisible:!1,isValid:!1,position:"inside",placeholderOrientation:"horizontal",isEmpty:!1,top:0,left:0,width:0,height:0}),removeDropTargetAttributes$2(b),x(),b&&b.querySelectorAll("[data-dragging]").forEach(R=>{R.style.opacity="",R.removeAttribute("data-dragging")}),setIsDragging(!1)},[n,c,b,x])};function removeDropTargetAttributes$2(n){if(!n)return;n.querySelectorAll("[data-drop-target]").forEach(d=>d.removeAttribute("data-drop-target"))}function getOrientation(n,c=null){const d=window.getComputedStyle(n),x=c?window.getComputedStyle(c):null,b=d.display,y=x?x.display:null;if(b==="flex"||b==="inline-flex"){const R=d.flexDirection;return R==="column"||R==="column-reverse"?"vertical":"horizontal"}else if(b==="grid"){const R=d.gridAutoFlow,S=d.gridTemplateColumns;return R.includes("column")||S&&S!=="none"&&S!==""&&!S.includes("calc")&&S.split(" ").length<=1?"vertical":"horizontal"}else if(y==="inline-block"||y==="inline")return"horizontal";return"vertical"}const LEAF_BLOCK_TYPES$1=["Heading","Text","Image","Paragraph","Icon","Input","Radio","Checkbox","Select","CustomHTML","TextArea","Divider","Repeater","Video"];function isLeafBlock(n){try{return LEAF_BLOCK_TYPES$1.includes(n)}catch{return!1}}const ZONE_CONFIG={MIN_EDGE_ZONE:10,MAX_EDGE_ZONE:30,EDGE_ZONE_PERCENTAGE:.2,GAP_THRESHOLD:8,MIN_SIZE_FOR_EDGE_ZONES:50,PARENT_EDGE_PROXIMITY:20};function calculateEdgeZoneSize(n){try{if(n<ZONE_CONFIG.MIN_SIZE_FOR_EDGE_ZONES)return 0;const c=n*ZONE_CONFIG.EDGE_ZONE_PERCENTAGE;return Math.max(ZONE_CONFIG.MIN_EDGE_ZONE,Math.min(ZONE_CONFIG.MAX_EDGE_ZONE,c))}catch{return ZONE_CONFIG.MIN_EDGE_ZONE}}function getChildBlocks(n){try{const c=[],d=n.children;for(let x=0;x<d.length;x++){const b=d[x];b.hasAttribute("data-block-id")&&c.push(b)}return c}catch{return[]}}function hasChildBlocks(n){try{return getChildBlocks(n).length>0}catch{return!1}}function detectGapZone(n,c,d,x){try{const b=getChildBlocks(n);if(b.length<2)return null;const y=findClosestSiblingInRow(b,c,d,x);if(y){const R=getSiblingsInSameRow(b,y,x);R.sort((S,_)=>{const A=S.getBoundingClientRect(),L=_.getBoundingClientRect();return x==="vertical"?A.top-L.top:A.left-L.left});for(let S=0;S<R.length-1;S++){const _=R[S],A=R[S+1],L=_.getBoundingClientRect(),T=A.getBoundingClientRect();if(x==="vertical"){const O=L.bottom,U=T.top,M=U-O,D=d>=O&&d<=U,K=c>=Math.min(L.left,T.left)&&c<=Math.max(L.right,T.right);if(D&&K&&M>=ZONE_CONFIG.GAP_THRESHOLD)return{before:_,after:A}}else{const O=L.right,U=T.left,M=U-O,D=c>=O&&c<=U,K=d>=Math.min(L.top,T.top)&&d<=Math.max(L.bottom,T.bottom);if(D&&K&&M>=ZONE_CONFIG.GAP_THRESHOLD)return{before:_,after:A}}}}for(let R=0;R<b.length-1;R++){const S=b[R],_=b[R+1],A=S.getBoundingClientRect(),L=_.getBoundingClientRect();if(x==="vertical"){const T=A.bottom,O=L.top,U=O-T,M=d>=T&&d<=O,D=c>=Math.min(A.left,L.left)&&c<=Math.max(A.right,L.right);if(M&&D&&U>=ZONE_CONFIG.GAP_THRESHOLD)return{before:S,after:_}}else{const T=A.right,O=L.left,U=O-T,M=c>=T&&c<=O,D=d>=Math.min(A.top,L.top)&&d<=Math.max(A.bottom,L.bottom);if(M&&D&&U>=ZONE_CONFIG.GAP_THRESHOLD)return{before:S,after:_}}}return null}catch{return null}}function detectParentEdgeProximity(n,c,d,x){try{const b=n.getBoundingClientRect(),y=ZONE_CONFIG.PARENT_EDGE_PROXIMITY;if(x==="vertical"){if(d<=b.top+y)return"start";if(d>=b.bottom-y)return"end"}else{if(c<=b.left+y)return"start";if(c>=b.right-y)return"end"}return null}catch{return null}}function calculateElementZone(n,c,d,x,b){const y=n.getBoundingClientRect();if(b==="vertical"){const S=(d-y.top)/y.height,_=calculateEdgeZoneSize(y.height),A=_/y.height;return x?_>0&&S<A?{position:"before",confidence:1-S/A}:_>0&&S>1-A?{position:"after",confidence:(S-(1-A))/A}:{position:"inside",confidence:1-Math.abs(S-.5)*2}:S<.5?{position:"before",confidence:1-S*2}:{position:"after",confidence:(S-.5)*2}}else{const S=(c-y.left)/y.width,_=calculateEdgeZoneSize(y.width),A=_/y.width;return x?_>0&&S<A?{position:"before",confidence:1-S/A}:_>0&&S>1-A?{position:"after",confidence:(S-(1-A))/A}:{position:"inside",confidence:1-Math.abs(S-.5)*2}:S<.5?{position:"before",confidence:1-S*2}:{position:"after",confidence:(S-.5)*2}}}function detectDropZone(n,c,d,x,b){var ae,Re,ye,de;const y=n.getAttribute("data-block-id"),R=n.getAttribute("data-block-type")||"Box";if(!y)return null;let S=n.parentElement;for(;S&&!S.hasAttribute("data-block-id");)S=S.parentElement;const _=y==="canvas"?y:S==null?void 0:S.getAttribute("data-block-id"),A=S?getOrientation(S):"vertical",L=getOrientation(n),T=isLeafBlock(R),O=!T&&canAcceptChildBlock(R,x),U=((ae=b.defaultView)==null?void 0:ae.scrollY)||0,M=((Re=b.defaultView)==null?void 0:Re.scrollX)||0;if(y==="canvas"&&hasChildBlocks(n)){const q=getChildBlocks(n),he=q[q.length-1];if(he){const le=he.getBoundingClientRect(),xe=n.getBoundingClientRect(),Ee=window.getComputedStyle(n),je=parseFloat(Ee.paddingLeft)||0,ze=parseFloat(Ee.paddingRight)||0,We=xe.width-je-ze,Pe=xe.left+M+je;return{position:"after",placeholderOrientation:"horizontal",rect:{top:le.bottom+U,left:Pe,width:We,height:4},targetElement:he,targetBlockId:he.getAttribute("data-block-id"),targetParentId:"canvas",isEmpty:!1,confidence:1}}}if(O&&!T&&hasChildBlocks(n)){const q=detectGapZone(n,c,d,L);if(q){const he=q.before.getBoundingClientRect(),le=q.after.getBoundingClientRect(),xe=n.getBoundingClientRect(),Ee=window.getComputedStyle(n),je=parseFloat(Ee.paddingLeft)||0,ze=parseFloat(Ee.paddingRight)||0,We=getChildBlocks(n),Pe=getSiblingsInSameRow(We,q.before,L);let ue=0;if(Pe.forEach(Ae=>{const He=Ae.getBoundingClientRect();He.height>ue&&(ue=He.height)}),L==="vertical"){const Ae=xe.width-je-ze,He=xe.left+M+je;return{position:"after",placeholderOrientation:"horizontal",rect:{top:he.bottom+U,left:He,width:Ae,height:4},targetElement:q.before,targetBlockId:q.before.getAttribute("data-block-id"),targetParentId:y,isGapZone:!0,confidence:1}}else{const Ae=he.top+U,He=ue>0?ue:Math.max(he.height,le.height);return{position:"after",placeholderOrientation:"vertical",rect:{top:Ae,left:he.right+M,width:4,height:He},targetElement:q.before,targetBlockId:q.before.getAttribute("data-block-id"),targetParentId:y,isGapZone:!0,confidence:1}}}}if(S&&_){const q=detectParentEdgeProximity(S,c,d,A);if(q){const he=S.getBoundingClientRect(),le=window.getComputedStyle(S),xe=parseFloat(le.paddingLeft)||0,Ee=parseFloat(le.paddingRight)||0,je=parseFloat(le.paddingTop)||0,ze=parseFloat(le.paddingBottom)||0,We=((ye=b.defaultView)==null?void 0:ye.scrollY)||0,Pe=((de=b.defaultView)==null?void 0:de.scrollX)||0,ue=A==="vertical"?"horizontal":"vertical",Ae=getMaxSiblingDimensions(S);if(q==="start"){const He=getChildBlocks(S)[0];if(He){const kn=He.getBoundingClientRect();if(A==="vertical"){const Ie=he.width-xe-Ee,ie=he.left+Pe+xe;return{position:"before",placeholderOrientation:ue,rect:{top:kn.top+We-2,left:ie,width:Ie,height:4},targetElement:He,targetBlockId:He.getAttribute("data-block-id"),targetParentId:_,confidence:.9}}else{const Ie=he.top+We+je,ie=Ae.maxHeight>0?Ae.maxHeight:he.height-je-ze;return{position:"before",placeholderOrientation:ue,rect:{top:Ie,left:kn.left+Pe-2,width:4,height:ie},targetElement:He,targetBlockId:He.getAttribute("data-block-id"),targetParentId:_,confidence:.9}}}}else{const He=getChildBlocks(S),kn=He[He.length-1];if(kn){const Ie=kn.getBoundingClientRect();if(A==="vertical"){const ie=he.width-xe-Ee,ot=he.left+Pe+xe;return{position:"after",placeholderOrientation:ue,rect:{top:Ie.bottom+We-2,left:ot,width:ie,height:4},targetElement:kn,targetBlockId:kn.getAttribute("data-block-id"),targetParentId:_,confidence:.9}}else{const ie=he.top+We+je,ot=Ae.maxHeight>0?Ae.maxHeight:he.height-je-ze;return{position:"after",placeholderOrientation:ue,rect:{top:ie,left:Ie.right+Pe-2,width:4,height:ot},targetElement:kn,targetBlockId:kn.getAttribute("data-block-id"),targetParentId:_,confidence:.9}}}}}}let D=calculateElementZone(n,c,d,O,A);if(T&&D.position==="inside"){const q=n.getBoundingClientRect();A==="vertical"?D={position:(d-q.top)/q.height<.5?"before":"after",confidence:D.confidence}:D={position:(c-q.left)/q.width<.5?"before":"after",confidence:D.confidence}}let K;D.position==="inside"?K=L==="vertical"?"horizontal":"vertical":K=A==="vertical"?"horizontal":"vertical";const $=calculatePlaceholderRect(n,S,D.position,K,b),ee=D.position==="inside"?y:_;return{position:D.position,placeholderOrientation:K,rect:$,targetElement:n,targetBlockId:y,targetParentId:ee,isEmpty:D.position==="inside"&&!hasChildBlocks(n),confidence:D.confidence}}function findClosestSiblingInRow(n,c,d,x){if(n.length===0)return null;const b=n.filter(S=>{const _=S.getBoundingClientRect();return x==="vertical"?d>=_.top&&d<=_.bottom:c>=_.left&&c<=_.right});if(b.length===0){const S=new Map;n.forEach(L=>{const T=L.getBoundingClientRect(),O=Math.round(x==="vertical"?T.top:T.left);S.has(O)||S.set(O,[]),S.get(O).push(L)});let _=null,A=1/0;S.forEach((L,T)=>{const O=Math.abs(x==="vertical"?d-T:c-T);O<A&&(A=O,_=L)}),_&&_.length>0&&b.push(..._)}if(b.length===0)return null;let y=b[0],R=1/0;return b.forEach(S=>{const _=S.getBoundingClientRect(),A=_.left+_.width/2,L=_.top+_.height/2,T=Math.sqrt(Math.pow(c-A,2)+Math.pow(d-L,2));T<R&&(R=T,y=S)}),y}function getMaxSiblingDimensions(n){const c=getChildBlocks(n);if(c.length===0)return{maxWidth:0,maxHeight:0};let d=0,x=0;return c.forEach(b=>{const y=b.getBoundingClientRect();y.width>d&&(d=y.width),y.height>x&&(x=y.height)}),{maxWidth:d,maxHeight:x}}function getSiblingsInSameRow(n,c,d){const x=c.getBoundingClientRect(),b=5;return n.filter(y=>{const R=y.getBoundingClientRect();return d==="vertical"?Math.abs(R.top-x.top)<=b:Math.abs(R.left-x.left)<=b})}function calculatePlaceholderRect(n,c,d,x,b){var je,ze;const y=n.getBoundingClientRect(),R=window.getComputedStyle(n),S=((je=b.defaultView)==null?void 0:je.scrollY)||0,_=((ze=b.defaultView)==null?void 0:ze.scrollX)||0,A=parseFloat(R.marginTop)||0,L=parseFloat(R.marginBottom)||0,T=parseFloat(R.marginLeft)||0,O=parseFloat(R.marginRight)||0,U=parseFloat(R.paddingTop)||0,M=parseFloat(R.paddingBottom)||0,D=parseFloat(R.paddingLeft)||0,K=parseFloat(R.paddingRight)||0,$=c==null?void 0:c.getBoundingClientRect(),ee=c&&parseFloat(window.getComputedStyle(c).paddingLeft)||0,ae=c&&parseFloat(window.getComputedStyle(c).paddingRight)||0,Re=c&&parseFloat(window.getComputedStyle(c).paddingTop)||0,ye=c&&parseFloat(window.getComputedStyle(c).paddingBottom)||0,de=c?getMaxSiblingDimensions(c):{maxWidth:0,maxHeight:0},q=c?getOrientation(c):"vertical",he=c?getChildBlocks(c):[],le=getSiblingsInSameRow(he,n,q);let xe=0,Ee=0;if(le.forEach(We=>{const Pe=We.getBoundingClientRect();Pe.height>xe&&(xe=Pe.height),Pe.width>Ee&&(Ee=Pe.width)}),d==="before")if(x==="horizontal"){const We=$?$.width-ee-ae:y.width,Pe=$?$.left+_+ee:y.left+_;return{top:y.top+S-A-2,left:Pe,width:We,height:4}}else{const We=y.top+S,Pe=q==="horizontal"&&xe>0?xe:de.maxHeight>0?de.maxHeight:$?$.height-Re-ye:y.height;return{top:We,left:y.left+_-T-2,width:4,height:Pe}}else if(d==="after")if(x==="horizontal"){const We=$?$.width-ee-ae:y.width,Pe=$?$.left+_+ee:y.left+_;return{top:y.bottom+S+L-2,left:Pe,width:We,height:4}}else{const We=y.top+S,Pe=q==="horizontal"&&xe>0?xe:de.maxHeight>0?de.maxHeight:$?$.height-Re-ye:y.height;return{top:We,left:y.right+_+O-2,width:4,height:Pe}}else return hasChildBlocks(n)?getOrientation(n)==="vertical"?{top:y.bottom+S-M-2,left:y.left+_+D,width:y.width-D-K,height:4}:{top:y.top+S+U,left:y.right+_-K-2,width:4,height:y.height-U-M}:{top:y.top+S+U,left:y.left+_+D,width:y.width-D-K,height:Math.max(y.height-U-M,20)}}function isDescendantOf(n,c,d){if(!n||!c)return!1;if(n===c)return!0;const x=d.find(y=>y._id===n);if(!x)return!1;let b=x;for(;b._parent;){if(b._parent===c)return!0;const y=d.find(R=>R._id===b._parent);if(!y)break;b=y}return!1}function canDropWithoutCircularReference(n,c,d){return!n||!c?!0:!isDescendantOf(c,n,d)}function canDropAsSiblingWithoutCircularReference(n,c,d){if(!n)return!0;const x=d.find(y=>y._id===c);if(!x)return!0;const b=x._parent;return canDropWithoutCircularReference(n,b,d)}const LEAF_BLOCK_TYPES=["Heading","Text","Image","Paragraph","Icon","Input","Radio","Checkbox","Select","CustomHTML","TextArea","Divider","Repeater","Video"],useBlockDragOver=()=>{const[n]=jotai.useAtom(dragAndDropAtom),[c]=useCanvasIframe(),[,d]=jotai.useAtom(dropIndicatorAtom),{clearParentHighlight:x,highlightParent:b}=useDragParentHighlight(),[y]=useBlocksStore(),R=c==null?void 0:c.contentDocument,S=React.useCallback(lodashEs.throttle(_=>{if(!isDragging||!n)return;x();const A=getTargetDetail(_),{element:L,targetBlockId:T,targetParentId:O}=A;if(!L||!T)return;const U=n._id;if(U&&(T===U||isDescendantOf(T,U,y)))return;const M=n._type||n.type;if(!M)return;const D=_.clientX,K=_.clientY,$=detectDropZone(L,D,K,M,R);if(!$)return;const ee=L.getAttribute("data-block-type")||"Box";let ae=!1;const Re=LEAF_BLOCK_TYPES.includes(ee);if($.position==="inside"){if(Re||U&&!canDropWithoutCircularReference(U,T,y))return;ae=canAcceptChildBlock(ee,M)}else{let de=L.parentElement,q="Box";for(;de&&!de.hasAttribute("data-block-id");)de=de.parentElement;if(de&&(q=de.getAttribute("data-block-type")||"Box"),U&&!canDropAsSiblingWithoutCircularReference(U,T,y))return;ae=canAcceptChildBlock(q,M)}if(!ae)return;b($.targetParentId);const ye=$.targetParentId||O;d({isVisible:!0,isValid:!0,position:$.position,placeholderOrientation:$.placeholderOrientation,isEmpty:$.isEmpty,top:$.rect.top,left:$.rect.left,width:$.rect.width,height:$.rect.height,targetBlockId:$.targetBlockId,targetParentId:ye}),removeDropTargetAttributes$1(R),$.targetElement.setAttribute("data-drop-target","true")},300),[R,n,d,x,b,y]);return React.useCallback(_=>{_.preventDefault(),_.stopPropagation(),S(_)},[S])};function getTargetDetail(n){let c=n.target;for(;c&&!c.hasAttribute("data-block-id");)c=c.parentElement;if(!c)return{element:null,targetBlockId:null,targetBlockType:null,targetParentId:null,targetParentType:null,orientation:"vertical"};const d=c.getAttribute("data-block-id"),x=c.getAttribute("data-block-type")||"Box";let b=c.parentElement;for(;b&&!b.hasAttribute("data-block-id");)b=b.parentElement;const y=(b==null?void 0:b.getAttribute("data-block-id"))||null,R=(b==null?void 0:b.getAttribute("data-block-type"))||"Box",S=getOrientation(c);return{element:c,targetBlockId:d,targetBlockType:x,targetParentId:y,targetParentType:R,orientation:S}}function removeDropTargetAttributes$1(n){if(!n)return;n.querySelectorAll("[data-drop-target]").forEach(d=>d.removeAttribute("data-drop-target"))}var server_browser={},reactDomServerLegacy_browser_production={};/**
2
+ * @license React
3
+ * react-dom-server-legacy.browser.production.js
4
+ *
5
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
6
+ *
7
+ * This source code is licensed under the MIT license found in the
8
+ * LICENSE file in the root directory of this source tree.
9
+ */var hasRequiredReactDomServerLegacy_browser_production;function requireReactDomServerLegacy_browser_production(){if(hasRequiredReactDomServerLegacy_browser_production)return reactDomServerLegacy_browser_production;hasRequiredReactDomServerLegacy_browser_production=1;var n=React,c=require$$1;function d(u){var f="https://react.dev/errors/"+u;if(1<arguments.length){f+="?args[]="+encodeURIComponent(arguments[1]);for(var v=2;v<arguments.length;v++)f+="&args[]="+encodeURIComponent(arguments[v])}return"Minified React error #"+u+"; visit "+f+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var x=Symbol.for("react.transitional.element"),b=Symbol.for("react.portal"),y=Symbol.for("react.fragment"),R=Symbol.for("react.strict_mode"),S=Symbol.for("react.profiler"),_=Symbol.for("react.consumer"),A=Symbol.for("react.context"),L=Symbol.for("react.forward_ref"),T=Symbol.for("react.suspense"),O=Symbol.for("react.suspense_list"),U=Symbol.for("react.memo"),M=Symbol.for("react.lazy"),D=Symbol.for("react.scope"),K=Symbol.for("react.activity"),$=Symbol.for("react.legacy_hidden"),ee=Symbol.for("react.memo_cache_sentinel"),ae=Symbol.for("react.view_transition"),Re=Symbol.iterator;function ye(u){return u===null||typeof u!="object"?null:(u=Re&&u[Re]||u["@@iterator"],typeof u=="function"?u:null)}var de=Array.isArray;function q(u,f){var v=u.length&3,w=u.length-v,N=f;for(f=0;f<w;){var z=u.charCodeAt(f)&255|(u.charCodeAt(++f)&255)<<8|(u.charCodeAt(++f)&255)<<16|(u.charCodeAt(++f)&255)<<24;++f,z=3432918353*(z&65535)+((3432918353*(z>>>16)&65535)<<16)&4294967295,z=z<<15|z>>>17,z=461845907*(z&65535)+((461845907*(z>>>16)&65535)<<16)&4294967295,N^=z,N=N<<13|N>>>19,N=5*(N&65535)+((5*(N>>>16)&65535)<<16)&4294967295,N=(N&65535)+27492+(((N>>>16)+58964&65535)<<16)}switch(z=0,v){case 3:z^=(u.charCodeAt(f+2)&255)<<16;case 2:z^=(u.charCodeAt(f+1)&255)<<8;case 1:z^=u.charCodeAt(f)&255,z=3432918353*(z&65535)+((3432918353*(z>>>16)&65535)<<16)&4294967295,z=z<<15|z>>>17,N^=461845907*(z&65535)+((461845907*(z>>>16)&65535)<<16)&4294967295}return N^=u.length,N^=N>>>16,N=2246822507*(N&65535)+((2246822507*(N>>>16)&65535)<<16)&4294967295,N^=N>>>13,N=3266489909*(N&65535)+((3266489909*(N>>>16)&65535)<<16)&4294967295,(N^N>>>16)>>>0}var he=Object.assign,le=Object.prototype.hasOwnProperty,xe=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Ee={},je={};function ze(u){return le.call(je,u)?!0:le.call(Ee,u)?!1:xe.test(u)?je[u]=!0:(Ee[u]=!0,!1)}var We=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" ")),Pe=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),ue=/["'&<>]/;function Ae(u){if(typeof u=="boolean"||typeof u=="number"||typeof u=="bigint")return""+u;u=""+u;var f=ue.exec(u);if(f){var v="",w,N=0;for(w=f.index;w<u.length;w++){switch(u.charCodeAt(w)){case 34:f="&quot;";break;case 38:f="&amp;";break;case 39:f="&#x27;";break;case 60:f="&lt;";break;case 62:f="&gt;";break;default:continue}N!==w&&(v+=u.slice(N,w)),N=w+1,v+=f}u=N!==w?v+u.slice(N,w):v}return u}var He=/([A-Z])/g,kn=/^ms-/,Ie=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function ie(u){return Ie.test(""+u)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":u}var ot=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,wn=c.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,go={pending:!1,data:null,method:null,action:null},vt=wn.d;wn.d={f:vt.f,r:vt.r,D:Or,C:oo,L:As,m:Li,X:eu,S:mo,M:Ec};var Mo=[],Cn=null,Bi=/(<\/|<)(s)(cript)/gi;function $r(u,f,v,w){return""+f+(v==="s"?"\\u0073":"\\u0053")+w}function po(u,f,v,w,N){return{idPrefix:u===void 0?"":u,nextFormID:0,streamingFormat:0,bootstrapScriptContent:v,bootstrapScripts:w,bootstrapModules:N,instructions:0,hasBody:!1,hasHtml:!1,unknownResources:{},dnsResources:{},connectResources:{default:{},anonymous:{},credentials:{}},imageResources:{},styleResources:{},scriptResources:{},moduleUnknownResources:{},moduleScriptResources:{}}}function Sn(u,f,v,w){return{insertionMode:u,selectedValue:f,tagScope:v,viewTransition:w}}function Pi(u,f,v){var w=u.tagScope&-25;switch(f){case"noscript":return Sn(2,null,w|1,null);case"select":return Sn(2,v.value!=null?v.value:v.defaultValue,w,null);case"svg":return Sn(4,null,w,null);case"picture":return Sn(2,null,w|2,null);case"math":return Sn(5,null,w,null);case"foreignObject":return Sn(2,null,w,null);case"table":return Sn(6,null,w,null);case"thead":case"tbody":case"tfoot":return Sn(7,null,w,null);case"colgroup":return Sn(9,null,w,null);case"tr":return Sn(8,null,w,null);case"head":if(2>u.insertionMode)return Sn(3,null,w,null);break;case"html":if(u.insertionMode===0)return Sn(1,null,w,null)}return 6<=u.insertionMode||2>u.insertionMode?Sn(2,null,w,null):u.tagScope!==w?Sn(u.insertionMode,u.selectedValue,w,null):u}function et(u){return u===null?null:{update:u.update,enter:"none",exit:"none",share:u.update,name:u.autoName,autoName:u.autoName,nameIdx:0}}function Tn(u,f){return f.tagScope&32&&(u.instructions|=128),Sn(f.insertionMode,f.selectedValue,f.tagScope|12,et(f.viewTransition))}function _t(u,f){u=et(f.viewTransition);var v=f.tagScope|16;return u!==null&&u.share!=="none"&&(v|=64),Sn(f.insertionMode,f.selectedValue,v,u)}var Wn=new Map;function Es(u,f){if(typeof f!="object")throw Error(d(62));var v=!0,w;for(w in f)if(le.call(f,w)){var N=f[w];if(N!=null&&typeof N!="boolean"&&N!==""){if(w.indexOf("--")===0){var z=Ae(w);N=Ae((""+N).trim())}else z=Wn.get(w),z===void 0&&(z=Ae(w.replace(He,"-$1").toLowerCase().replace(kn,"-ms-")),Wn.set(w,z)),N=typeof N=="number"?N===0||We.has(w)?""+N:N+"px":Ae((""+N).trim());v?(v=!1,u.push(' style="',z,":",N)):u.push(";",z,":",N)}}v||u.push('"')}function Xl(u,f,v){v&&typeof v!="function"&&typeof v!="symbol"&&u.push(" ",f,'=""')}function Jn(u,f,v){typeof v!="function"&&typeof v!="symbol"&&typeof v!="boolean"&&u.push(" ",f,'="',Ae(v),'"')}var Do=Ae("javascript:throw new Error('React form unexpectedly submitted.')");function Mr(u,f){this.push('<input type="hidden"'),On(u),Jn(this,"name",f),Jn(this,"value",u),this.push("/>")}function On(u){if(typeof u!="string")throw Error(d(480))}function Dr(u,f){if(typeof f.$$FORM_ACTION=="function"){var v=u.nextFormID++;u=u.idPrefix+v;try{var w=f.$$FORM_ACTION(u);if(w){var N=w.data;N!=null&&N.forEach(On)}return w}catch(z){if(typeof z=="object"&&z!==null&&typeof z.then=="function")throw z}}return null}function _i(u,f,v,w,N,z,V,ge){var J=null;if(typeof w=="function"){var ce=Dr(f,w);ce!==null?(ge=ce.name,w=ce.action||"",N=ce.encType,z=ce.method,V=ce.target,J=ce.data):(u.push(" ","formAction",'="',Do,'"'),V=z=N=w=ge=null,Jc(f,v))}return ge!=null&&Rt(u,"name",ge),w!=null&&Rt(u,"formAction",w),N!=null&&Rt(u,"formEncType",N),z!=null&&Rt(u,"formMethod",z),V!=null&&Rt(u,"formTarget",V),J}function Rt(u,f,v){switch(f){case"className":Jn(u,"class",v);break;case"tabIndex":Jn(u,"tabindex",v);break;case"dir":case"role":case"viewBox":case"width":case"height":Jn(u,f,v);break;case"style":Es(u,v);break;case"src":case"href":if(v==="")break;case"action":case"formAction":if(v==null||typeof v=="function"||typeof v=="symbol"||typeof v=="boolean")break;v=ie(""+v),u.push(" ",f,'="',Ae(v),'"');break;case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"autoFocus":case"multiple":case"muted":Xl(u,f.toLowerCase(),v);break;case"xlinkHref":if(typeof v=="function"||typeof v=="symbol"||typeof v=="boolean")break;v=ie(""+v),u.push(" ","xlink:href",'="',Ae(v),'"');break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":typeof v!="function"&&typeof v!="symbol"&&u.push(" ",f,'="',Ae(v),'"');break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":v&&typeof v!="function"&&typeof v!="symbol"&&u.push(" ",f,'=""');break;case"capture":case"download":v===!0?u.push(" ",f,'=""'):v!==!1&&typeof v!="function"&&typeof v!="symbol"&&u.push(" ",f,'="',Ae(v),'"');break;case"cols":case"rows":case"size":case"span":typeof v!="function"&&typeof v!="symbol"&&!isNaN(v)&&1<=v&&u.push(" ",f,'="',Ae(v),'"');break;case"rowSpan":case"start":typeof v=="function"||typeof v=="symbol"||isNaN(v)||u.push(" ",f,'="',Ae(v),'"');break;case"xlinkActuate":Jn(u,"xlink:actuate",v);break;case"xlinkArcrole":Jn(u,"xlink:arcrole",v);break;case"xlinkRole":Jn(u,"xlink:role",v);break;case"xlinkShow":Jn(u,"xlink:show",v);break;case"xlinkTitle":Jn(u,"xlink:title",v);break;case"xlinkType":Jn(u,"xlink:type",v);break;case"xmlBase":Jn(u,"xml:base",v);break;case"xmlLang":Jn(u,"xml:lang",v);break;case"xmlSpace":Jn(u,"xml:space",v);break;default:if((!(2<f.length)||f[0]!=="o"&&f[0]!=="O"||f[1]!=="n"&&f[1]!=="N")&&(f=Pe.get(f)||f,ze(f))){switch(typeof v){case"function":case"symbol":return;case"boolean":var w=f.toLowerCase().slice(0,5);if(w!=="data-"&&w!=="aria-")return}u.push(" ",f,'="',Ae(v),'"')}}}function xo(u,f,v){if(f!=null){if(v!=null)throw Error(d(60));if(typeof f!="object"||!("__html"in f))throw Error(d(61));f=f.__html,f!=null&&u.push(""+f)}}function Vt(u){var f="";return n.Children.forEach(u,function(v){v!=null&&(f+=v)}),f}function Jc(u,f){if(!(u.instructions&16)){u.instructions|=16;var v=f.preamble,w=f.bootstrapChunks;(v.htmlChunks||v.headChunks)&&w.length===0?(w.push(f.startInlineScript),Ka(w,u),w.push(">",`addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error('React form unexpectedly submitted.')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});`,"<\/script>")):w.unshift(f.startInlineScript,">",`addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error('React form unexpectedly submitted.')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});`,"<\/script>")}}function vn(u,f){u.push(sn("link"));for(var v in f)if(le.call(f,v)){var w=f[v];if(w!=null)switch(v){case"children":case"dangerouslySetInnerHTML":throw Error(d(399,"link"));default:Rt(u,v,w)}}return u.push("/>"),null}var bc=/(<\/|<)(s)(tyle)/gi;function yc(u,f,v,w){return""+f+(v==="s"?"\\73 ":"\\53 ")+w}function kl(u,f,v){u.push(sn(v));for(var w in f)if(le.call(f,w)){var N=f[w];if(N!=null)switch(w){case"children":case"dangerouslySetInnerHTML":throw Error(d(399,v));default:Rt(u,w,N)}}return u.push("/>"),null}function vc(u,f){u.push(sn("title"));var v=null,w=null,N;for(N in f)if(le.call(f,N)){var z=f[N];if(z!=null)switch(N){case"children":v=z;break;case"dangerouslySetInnerHTML":w=z;break;default:Rt(u,N,z)}}return u.push(">"),f=Array.isArray(v)?2>v.length?v[0]:null:v,typeof f!="function"&&typeof f!="symbol"&&f!==null&&f!==void 0&&u.push(Ae(""+f)),xo(u,w,v),u.push(Cs("title")),null}function Ga(u,f){u.push(sn("script"));var v=null,w=null,N;for(N in f)if(le.call(f,N)){var z=f[N];if(z!=null)switch(N){case"children":v=z;break;case"dangerouslySetInnerHTML":w=z;break;default:Rt(u,N,z)}}return u.push(">"),xo(u,w,v),typeof v=="string"&&u.push((""+v).replace(Bi,$r)),u.push(Cs("script")),null}function ks(u,f,v){u.push(sn(v));var w=v=null,N;for(N in f)if(le.call(f,N)){var z=f[N];if(z!=null)switch(N){case"children":v=z;break;case"dangerouslySetInnerHTML":w=z;break;default:Rt(u,N,z)}}return u.push(">"),xo(u,w,v),v}function Zl(u,f,v){u.push(sn(v));var w=v=null,N;for(N in f)if(le.call(f,N)){var z=f[N];if(z!=null)switch(N){case"children":v=z;break;case"dangerouslySetInnerHTML":w=z;break;default:Rt(u,N,z)}}return u.push(">"),xo(u,w,v),typeof v=="string"?(u.push(Ae(v)),null):v}var ws=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,Va=new Map;function sn(u){var f=Va.get(u);if(f===void 0){if(!ws.test(u))throw Error(d(65,u));f="<"+u,Va.set(u,f)}return f}function Qt(u,f,v,w,N,z,V,ge,J){switch(f){case"div":case"span":case"svg":case"path":break;case"a":u.push(sn("a"));var ce=null,we=null,ve;for(ve in v)if(le.call(v,ve)){var Le=v[ve];if(Le!=null)switch(ve){case"children":ce=Le;break;case"dangerouslySetInnerHTML":we=Le;break;case"href":Le===""?Jn(u,"href",""):Rt(u,ve,Le);break;default:Rt(u,ve,Le)}}if(u.push(">"),xo(u,we,ce),typeof ce=="string"){u.push(Ae(ce));var Ge=null}else Ge=ce;return Ge;case"g":case"p":case"li":break;case"select":u.push(sn("select"));var at=null,Qe=null,Xe;for(Xe in v)if(le.call(v,Xe)){var tt=v[Xe];if(tt!=null)switch(Xe){case"children":at=tt;break;case"dangerouslySetInnerHTML":Qe=tt;break;case"defaultValue":case"value":break;default:Rt(u,Xe,tt)}}return u.push(">"),xo(u,Qe,at),at;case"option":var Je=ge.selectedValue;u.push(sn("option"));var tn=null,ct=null,mt=null,Bt=null,lt;for(lt in v)if(le.call(v,lt)){var un=v[lt];if(un!=null)switch(lt){case"children":tn=un;break;case"selected":mt=un;break;case"dangerouslySetInnerHTML":Bt=un;break;case"value":ct=un;default:Rt(u,lt,un)}}if(Je!=null){var Ct=ct!==null?""+ct:Vt(tn);if(de(Je)){for(var bo=0;bo<Je.length;bo++)if(""+Je[bo]===Ct){u.push(' selected=""');break}}else""+Je===Ct&&u.push(' selected=""')}else mt&&u.push(' selected=""');return u.push(">"),xo(u,Bt,tn),tn;case"textarea":u.push(sn("textarea"));var Nt=null,yt=null,St=null,nt;for(nt in v)if(le.call(v,nt)){var Tt=v[nt];if(Tt!=null)switch(nt){case"children":St=Tt;break;case"value":Nt=Tt;break;case"defaultValue":yt=Tt;break;case"dangerouslySetInnerHTML":throw Error(d(91));default:Rt(u,nt,Tt)}}if(Nt===null&&yt!==null&&(Nt=yt),u.push(">"),St!=null){if(Nt!=null)throw Error(d(92));if(de(St)){if(1<St.length)throw Error(d(93));Nt=""+St[0]}Nt=""+St}return typeof Nt=="string"&&Nt[0]===`
10
+ `&&u.push(`
11
+ `),Nt!==null&&u.push(Ae(""+Nt)),null;case"input":u.push(sn("input"));var Yn=null,dt=null,as=null,Fl=null,yo=null,vr=null,Rr=null,Er=null,ul=null,Ml;for(Ml in v)if(le.call(v,Ml)){var Un=v[Ml];if(Un!=null)switch(Ml){case"children":case"dangerouslySetInnerHTML":throw Error(d(399,"input"));case"name":Yn=Un;break;case"formAction":dt=Un;break;case"formEncType":as=Un;break;case"formMethod":Fl=Un;break;case"formTarget":yo=Un;break;case"defaultChecked":ul=Un;break;case"defaultValue":Rr=Un;break;case"checked":Er=Un;break;case"value":vr=Un;break;default:Rt(u,Ml,Un)}}var Hs=_i(u,w,N,dt,as,Fl,yo,Yn);return Er!==null?Xl(u,"checked",Er):ul!==null&&Xl(u,"checked",ul),vr!==null?Rt(u,"value",vr):Rr!==null&&Rt(u,"value",Rr),u.push("/>"),Hs!=null&&Hs.forEach(Mr,u),null;case"button":u.push(sn("button"));var Us=null,ci=null,Yi=null,ka=null,is=null,vo=null,ui=null,Ro;for(Ro in v)if(le.call(v,Ro)){var gr=v[Ro];if(gr!=null)switch(Ro){case"children":Us=gr;break;case"dangerouslySetInnerHTML":ci=gr;break;case"name":Yi=gr;break;case"formAction":ka=gr;break;case"formEncType":is=gr;break;case"formMethod":vo=gr;break;case"formTarget":ui=gr;break;default:Rt(u,Ro,gr)}}var Dl=_i(u,w,N,ka,is,vo,ui,Yi);if(u.push(">"),Dl!=null&&Dl.forEach(Mr,u),xo(u,ci,Us),typeof Us=="string"){u.push(Ae(Us));var di=null}else di=Us;return di;case"form":u.push(sn("form"));var Ol=null,Xi=null,Pn=null,hi=null,cs=null,wa=null,zs;for(zs in v)if(le.call(v,zs)){var Rn=v[zs];if(Rn!=null)switch(zs){case"children":Ol=Rn;break;case"dangerouslySetInnerHTML":Xi=Rn;break;case"action":Pn=Rn;break;case"encType":hi=Rn;break;case"method":cs=Rn;break;case"target":wa=Rn;break;default:Rt(u,zs,Rn)}}var pr=null,ut=null;if(typeof Pn=="function"){var jl=Dr(w,Pn);jl!==null?(Pn=jl.action||"",hi=jl.encType,cs=jl.method,wa=jl.target,pr=jl.data,ut=jl.name):(u.push(" ","action",'="',Do,'"'),wa=cs=hi=Pn=null,Jc(w,N))}if(Pn!=null&&Rt(u,"action",Pn),hi!=null&&Rt(u,"encType",hi),cs!=null&&Rt(u,"method",cs),wa!=null&&Rt(u,"target",wa),u.push(">"),ut!==null&&(u.push('<input type="hidden"'),Jn(u,"name",ut),u.push("/>"),pr!=null&&pr.forEach(Mr,u)),xo(u,Xi,Ol),typeof Ol=="string"){u.push(Ae(Ol));var Ca=null}else Ca=Ol;return Ca;case"menuitem":u.push(sn("menuitem"));for(var us in v)if(le.call(v,us)){var dn=v[us];if(dn!=null)switch(us){case"children":case"dangerouslySetInnerHTML":throw Error(d(400));default:Rt(u,us,dn)}}return u.push(">"),null;case"object":u.push(sn("object"));var Wo=null,ds=null,Ws;for(Ws in v)if(le.call(v,Ws)){var kr=v[Ws];if(kr!=null)switch(Ws){case"children":Wo=kr;break;case"dangerouslySetInnerHTML":ds=kr;break;case"data":var so=ie(""+kr);if(so==="")break;u.push(" ","data",'="',Ae(so),'"');break;default:Rt(u,Ws,kr)}}if(u.push(">"),xo(u,ds,Wo),typeof Wo=="string"){u.push(Ae(Wo));var Sa=null}else Sa=Wo;return Sa;case"title":var Eo=ge.tagScope&1,Nc=ge.tagScope&4;if(ge.insertionMode===4||Eo||v.itemProp!=null)var Gs=vc(u,v);else Nc?Gs=null:(vc(N.hoistableChunks,v),Gs=void 0);return Gs;case"link":var fi=ge.tagScope&1,Zi=ge.tagScope&4,Ki=v.rel,dl=v.href,Vs=v.precedence;if(ge.insertionMode===4||fi||v.itemProp!=null||typeof Ki!="string"||typeof dl!="string"||dl===""){vn(u,v);var Ys=null}else if(v.rel==="stylesheet")if(typeof Vs!="string"||v.disabled!=null||v.onLoad||v.onError)Ys=vn(u,v);else{var ko=N.styles.get(Vs),gi=w.styleResources.hasOwnProperty(dl)?w.styleResources[dl]:void 0;if(gi!==null){w.styleResources[dl]=null,ko||(ko={precedence:Ae(Vs),rules:[],hrefs:[],sheets:new Map},N.styles.set(Vs,ko));var pi={state:0,props:he({},v,{"data-precedence":v.precedence,precedence:null})};if(gi){gi.length===2&&Fi(pi.props,gi);var Lc=N.preloads.stylesheets.get(dl);Lc&&0<Lc.length?Lc.length=0:pi.state=1}ko.sheets.set(dl,pi),V&&V.stylesheets.add(pi)}else if(ko){var Fc=ko.sheets.get(dl);Fc&&V&&V.stylesheets.add(Fc)}J&&u.push("<!-- -->"),Ys=null}else v.onLoad||v.onError?Ys=vn(u,v):(J&&u.push("<!-- -->"),Ys=Zi?null:vn(N.hoistableChunks,v));return Ys;case"script":var Ji=ge.tagScope&1,Mc=v.async;if(typeof v.src!="string"||!v.src||!Mc||typeof Mc=="function"||typeof Mc=="symbol"||v.onLoad||v.onError||ge.insertionMode===4||Ji||v.itemProp!=null)var Dc=Ga(u,v);else{var _n=v.src;if(v.type==="module")var Qi=w.moduleScriptResources,xi=N.preloads.moduleScripts;else Qi=w.scriptResources,xi=N.preloads.scripts;var mi=Qi.hasOwnProperty(_n)?Qi[_n]:void 0;if(mi!==null){Qi[_n]=null;var qi=v;if(mi){mi.length===2&&(qi=he({},v),Fi(qi,mi));var Oc=xi.get(_n);Oc&&(Oc.length=0)}var $i=[];N.scripts.add($i),Ga($i,qi)}J&&u.push("<!-- -->"),Dc=null}return Dc;case"style":var ec=ge.tagScope&1,hs=v.precedence,wr=v.href,au=v.nonce;if(ge.insertionMode===4||ec||v.itemProp!=null||typeof hs!="string"||typeof wr!="string"||wr===""){u.push(sn("style"));var Xs=null,bi=null,Yr;for(Yr in v)if(le.call(v,Yr)){var Ta=v[Yr];if(Ta!=null)switch(Yr){case"children":Xs=Ta;break;case"dangerouslySetInnerHTML":bi=Ta;break;default:Rt(u,Yr,Ta)}}u.push(">");var fs=Array.isArray(Xs)?2>Xs.length?Xs[0]:null:Xs;typeof fs!="function"&&typeof fs!="symbol"&&fs!==null&&fs!==void 0&&u.push((""+fs).replace(bc,yc)),xo(u,bi,Xs),u.push(Cs("style"));var yi=null}else{var gs=N.styles.get(hs);if((w.styleResources.hasOwnProperty(wr)?w.styleResources[wr]:void 0)!==null){w.styleResources[wr]=null,gs||(gs={precedence:Ae(hs),rules:[],hrefs:[],sheets:new Map},N.styles.set(hs,gs));var iu=N.nonce.style;if(!iu||iu===au){gs.hrefs.push(Ae(wr));var cu=gs.rules,Xr=null,Aa=null,xr;for(xr in v)if(le.call(v,xr)){var ps=v[xr];if(ps!=null)switch(xr){case"children":Xr=ps;break;case"dangerouslySetInnerHTML":Aa=ps}}var Zs=Array.isArray(Xr)?2>Xr.length?Xr[0]:null:Xr;typeof Zs!="function"&&typeof Zs!="symbol"&&Zs!==null&&Zs!==void 0&&cu.push((""+Zs).replace(bc,yc)),xo(cu,Aa,Xr)}}gs&&V&&V.styles.add(gs),J&&u.push("<!-- -->"),yi=void 0}return yi;case"meta":var Cr=ge.tagScope&1,jc=ge.tagScope&4;if(ge.insertionMode===4||Cr||v.itemProp!=null)var uu=kl(u,v,"meta");else J&&u.push("<!-- -->"),uu=jc?null:typeof v.charSet=="string"?kl(N.charsetChunks,v,"meta"):v.name==="viewport"?kl(N.viewportChunks,v,"meta"):kl(N.hoistableChunks,v,"meta");return uu;case"listing":case"pre":u.push(sn(f));var Ia=null,i=null,h;for(h in v)if(le.call(v,h)){var m=v[h];if(m!=null)switch(h){case"children":Ia=m;break;case"dangerouslySetInnerHTML":i=m;break;default:Rt(u,h,m)}}if(u.push(">"),i!=null){if(Ia!=null)throw Error(d(60));if(typeof i!="object"||!("__html"in i))throw Error(d(61));var C=i.__html;C!=null&&(typeof C=="string"&&0<C.length&&C[0]===`
12
+ `?u.push(`
13
+ `,C):u.push(""+C))}return typeof Ia=="string"&&Ia[0]===`
14
+ `&&u.push(`
15
+ `),Ia;case"img":var P=ge.tagScope&3,H=v.src,W=v.srcSet;if(!(v.loading==="lazy"||!H&&!W||typeof H!="string"&&H!=null||typeof W!="string"&&W!=null||v.fetchPriority==="low"||P)&&(typeof H!="string"||H[4]!==":"||H[0]!=="d"&&H[0]!=="D"||H[1]!=="a"&&H[1]!=="A"||H[2]!=="t"&&H[2]!=="T"||H[3]!=="a"&&H[3]!=="A")&&(typeof W!="string"||W[4]!==":"||W[0]!=="d"&&W[0]!=="D"||W[1]!=="a"&&W[1]!=="A"||W[2]!=="t"&&W[2]!=="T"||W[3]!=="a"&&W[3]!=="A")){V!==null&&ge.tagScope&64&&(V.suspenseyImages=!0);var ne=typeof v.sizes=="string"?v.sizes:void 0,X=W?W+`
16
+ `+(ne||""):H,oe=N.preloads.images,fe=oe.get(X);if(fe)(v.fetchPriority==="high"||10>N.highImagePreloads.size)&&(oe.delete(X),N.highImagePreloads.add(fe));else if(!w.imageResources.hasOwnProperty(X)){w.imageResources[X]=Mo;var me=v.crossOrigin,De=typeof me=="string"?me==="use-credentials"?me:"":void 0,Me=N.headers,pt;Me&&0<Me.remainingCapacity&&typeof v.srcSet!="string"&&(v.fetchPriority==="high"||500>Me.highImagePreloads.length)&&(pt=qt(H,"image",{imageSrcSet:v.srcSet,imageSizes:v.sizes,crossOrigin:De,integrity:v.integrity,nonce:v.nonce,type:v.type,fetchPriority:v.fetchPriority,referrerPolicy:v.refererPolicy}),0<=(Me.remainingCapacity-=pt.length+2))?(N.resets.image[X]=Mo,Me.highImagePreloads&&(Me.highImagePreloads+=", "),Me.highImagePreloads+=pt):(fe=[],vn(fe,{rel:"preload",as:"image",href:W?void 0:H,imageSrcSet:W,imageSizes:ne,crossOrigin:De,integrity:v.integrity,type:v.type,fetchPriority:v.fetchPriority,referrerPolicy:v.referrerPolicy}),v.fetchPriority==="high"||10>N.highImagePreloads.size?N.highImagePreloads.add(fe):(N.bulkPreloads.add(fe),oe.set(X,fe)))}}return kl(u,v,"img");case"base":case"area":case"br":case"col":case"embed":case"hr":case"keygen":case"param":case"source":case"track":case"wbr":return kl(u,v,f);case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":break;case"head":if(2>ge.insertionMode){var qe=z||N.preamble;if(qe.headChunks)throw Error(d(545,"`<head>`"));z!==null&&u.push("<!--head-->"),qe.headChunks=[];var xt=ks(qe.headChunks,v,"head")}else xt=Zl(u,v,"head");return xt;case"body":if(2>ge.insertionMode){var hn=z||N.preamble;if(hn.bodyChunks)throw Error(d(545,"`<body>`"));z!==null&&u.push("<!--body-->"),hn.bodyChunks=[];var Kt=ks(hn.bodyChunks,v,"body")}else Kt=Zl(u,v,"body");return Kt;case"html":if(ge.insertionMode===0){var ao=z||N.preamble;if(ao.htmlChunks)throw Error(d(545,"`<html>`"));z!==null&&u.push("<!--html-->"),ao.htmlChunks=[""];var Qo=ks(ao.htmlChunks,v,"html")}else Qo=Zl(u,v,"html");return Qo;default:if(f.indexOf("-")!==-1){u.push(sn(f));var Sr=null,$e=null,wo;for(wo in v)if(le.call(v,wo)){var En=v[wo];if(En!=null){var Go=wo;switch(wo){case"children":Sr=En;break;case"dangerouslySetInnerHTML":$e=En;break;case"style":Es(u,En);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"className":Go="class";default:if(ze(wo)&&typeof En!="function"&&typeof En!="symbol"&&En!==!1){if(En===!0)En="";else if(typeof En=="object")continue;u.push(" ",Go,'="',Ae(En),'"')}}}}return u.push(">"),xo(u,$e,Sr),Sr}}return Zl(u,v,f)}var Ni=new Map;function Cs(u){var f=Ni.get(u);return f===void 0&&(f="</"+u+">",Ni.set(u,f)),f}function Qc(u,f){u=u.preamble,u.htmlChunks===null&&f.htmlChunks&&(u.htmlChunks=f.htmlChunks),u.headChunks===null&&f.headChunks&&(u.headChunks=f.headChunks),u.bodyChunks===null&&f.bodyChunks&&(u.bodyChunks=f.bodyChunks)}function Rc(u,f){f=f.bootstrapChunks;for(var v=0;v<f.length-1;v++)u.push(f[v]);return v<f.length?(v=f[v],f.length=0,u.push(v)):!0}function yr(u,f,v){if(u.push('<!--$?--><template id="'),v===null)throw Error(d(395));return u.push(f.boundaryPrefix),f=v.toString(16),u.push(f),u.push('"></template>')}function el(u,f,v,w){switch(v.insertionMode){case 0:case 1:case 3:case 2:return u.push('<div hidden id="'),u.push(f.segmentPrefix),f=w.toString(16),u.push(f),u.push('">');case 4:return u.push('<svg aria-hidden="true" style="display:none" id="'),u.push(f.segmentPrefix),f=w.toString(16),u.push(f),u.push('">');case 5:return u.push('<math aria-hidden="true" style="display:none" id="'),u.push(f.segmentPrefix),f=w.toString(16),u.push(f),u.push('">');case 6:return u.push('<table hidden id="'),u.push(f.segmentPrefix),f=w.toString(16),u.push(f),u.push('">');case 7:return u.push('<table hidden><tbody id="'),u.push(f.segmentPrefix),f=w.toString(16),u.push(f),u.push('">');case 8:return u.push('<table hidden><tr id="'),u.push(f.segmentPrefix),f=w.toString(16),u.push(f),u.push('">');case 9:return u.push('<table hidden><colgroup id="'),u.push(f.segmentPrefix),f=w.toString(16),u.push(f),u.push('">');default:throw Error(d(397))}}function qc(u,f){switch(f.insertionMode){case 0:case 1:case 3:case 2:return u.push("</div>");case 4:return u.push("</svg>");case 5:return u.push("</math>");case 6:return u.push("</table>");case 7:return u.push("</tbody></table>");case 8:return u.push("</tr></table>");case 9:return u.push("</colgroup></table>");default:throw Error(d(397))}}var Ss=/[<\u2028\u2029]/g;function mn(u){return JSON.stringify(u).replace(Ss,function(f){switch(f){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}var Kl=/[&><\u2028\u2029]/g;function Jl(u){return JSON.stringify(u).replace(Kl,function(f){switch(f){case"&":return"\\u0026";case">":return"\\u003e";case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSObjectForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}var Ts=!1,no=!0;function Ko(u){var f=u.rules,v=u.hrefs,w=0;if(v.length){for(this.push(Cn.startInlineStyle),this.push(' media="not all" data-precedence="'),this.push(u.precedence),this.push('" data-href="');w<v.length-1;w++)this.push(v[w]),this.push(" ");for(this.push(v[w]),this.push('">'),w=0;w<f.length;w++)this.push(f[w]);no=this.push("</style>"),Ts=!0,f.length=0,v.length=0}}function Ht(u){return u.state!==2?Ts=!0:!1}function Ya(u,f,v){return Ts=!1,no=!0,Cn=v,f.styles.forEach(Ko,u),Cn=null,f.stylesheets.forEach(Ht),Ts&&(v.stylesToHoist=!0),no}function ir(u){for(var f=0;f<u.length;f++)this.push(u[f]);u.length=0}var Et=[];function $c(u){vn(Et,u.props);for(var f=0;f<Et.length;f++)this.push(Et[f]);Et.length=0,u.state=2}function gt(u){var f=0<u.sheets.size;u.sheets.forEach($c,this),u.sheets.clear();var v=u.rules,w=u.hrefs;if(!f||w.length){if(this.push(Cn.startInlineStyle),this.push(' data-precedence="'),this.push(u.precedence),u=0,w.length){for(this.push('" data-href="');u<w.length-1;u++)this.push(w[u]),this.push(" ");this.push(w[u])}for(this.push('">'),u=0;u<v.length;u++)this.push(v[u]);this.push("</style>"),v.length=0,w.length=0}}function Xa(u){if(u.state===0){u.state=1;var f=u.props;for(vn(Et,{rel:"preload",as:"style",href:u.props.href,crossOrigin:f.crossOrigin,fetchPriority:f.fetchPriority,integrity:f.integrity,media:f.media,hrefLang:f.hrefLang,referrerPolicy:f.referrerPolicy}),u=0;u<Et.length;u++)this.push(Et[u]);Et.length=0}}function Za(u){u.sheets.forEach(Xa,this),u.sheets.clear()}function Ka(u,f){!(f.instructions&32)&&(f.instructions|=32,u.push(' id="',Ae("_"+f.idPrefix+"R_"),'"'))}function tl(u,f){u.push("[");var v="[";f.stylesheets.forEach(function(w){if(w.state!==2)if(w.state===3)u.push(v),w=Jl(""+w.props.href),u.push(w),u.push("]"),v=",[";else{u.push(v);var N=w.props["data-precedence"],z=w.props,V=ie(""+w.props.href);V=Jl(V),u.push(V),N=""+N,u.push(","),N=Jl(N),u.push(N);for(var ge in z)if(le.call(z,ge)&&(N=z[ge],N!=null))switch(ge){case"href":case"rel":case"precedence":case"data-precedence":break;case"children":case"dangerouslySetInnerHTML":throw Error(d(399,"link"));default:Ft(u,ge,N)}u.push("]"),v=",[",w.state=3}}),u.push("]")}function Ft(u,f,v){var w=f.toLowerCase();switch(typeof v){case"function":case"symbol":return}switch(f){case"innerHTML":case"dangerouslySetInnerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"style":case"ref":return;case"className":w="class",f=""+v;break;case"hidden":if(v===!1)return;f="";break;case"src":case"href":v=ie(v),f=""+v;break;default:if(2<f.length&&(f[0]==="o"||f[0]==="O")&&(f[1]==="n"||f[1]==="N")||!ze(f))return;f=""+v}u.push(","),w=Jl(w),u.push(w),u.push(","),w=Jl(f),u.push(w)}function kt(){return{styles:new Set,stylesheets:new Set,suspenseyImages:!1}}function Or(u){var f=Bn||null;if(f){var v=f.resumableState,w=f.renderState;if(typeof u=="string"&&u){if(!v.dnsResources.hasOwnProperty(u)){v.dnsResources[u]=null,v=w.headers;var N,z;(z=v&&0<v.remainingCapacity)&&(z=(N="<"+(""+u).replace(Mi,ua)+">; rel=dns-prefetch",0<=(v.remainingCapacity-=N.length+2))),z?(w.resets.dns[u]=null,v.preconnects&&(v.preconnects+=", "),v.preconnects+=N):(N=[],vn(N,{href:u,rel:"dns-prefetch"}),w.preconnects.add(N))}Ea(f)}}else vt.D(u)}function oo(u,f){var v=Bn||null;if(v){var w=v.resumableState,N=v.renderState;if(typeof u=="string"&&u){var z=f==="use-credentials"?"credentials":typeof f=="string"?"anonymous":"default";if(!w.connectResources[z].hasOwnProperty(u)){w.connectResources[z][u]=null,w=N.headers;var V,ge;if(ge=w&&0<w.remainingCapacity){if(ge="<"+(""+u).replace(Mi,ua)+">; rel=preconnect",typeof f=="string"){var J=(""+f).replace(cr,Is);ge+='; crossorigin="'+J+'"'}ge=(V=ge,0<=(w.remainingCapacity-=V.length+2))}ge?(N.resets.connect[z][u]=null,w.preconnects&&(w.preconnects+=", "),w.preconnects+=V):(z=[],vn(z,{rel:"preconnect",href:u,crossOrigin:f}),N.preconnects.add(z))}Ea(v)}}else vt.C(u,f)}function As(u,f,v){var w=Bn||null;if(w){var N=w.resumableState,z=w.renderState;if(f&&u){switch(f){case"image":if(v)var V=v.imageSrcSet,ge=v.imageSizes,J=v.fetchPriority;var ce=V?V+`
17
+ `+(ge||""):u;if(N.imageResources.hasOwnProperty(ce))return;N.imageResources[ce]=Mo,N=z.headers;var we;N&&0<N.remainingCapacity&&typeof V!="string"&&J==="high"&&(we=qt(u,f,v),0<=(N.remainingCapacity-=we.length+2))?(z.resets.image[ce]=Mo,N.highImagePreloads&&(N.highImagePreloads+=", "),N.highImagePreloads+=we):(N=[],vn(N,he({rel:"preload",href:V?void 0:u,as:f},v)),J==="high"?z.highImagePreloads.add(N):(z.bulkPreloads.add(N),z.preloads.images.set(ce,N)));break;case"style":if(N.styleResources.hasOwnProperty(u))return;V=[],vn(V,he({rel:"preload",href:u,as:f},v)),N.styleResources[u]=!v||typeof v.crossOrigin!="string"&&typeof v.integrity!="string"?Mo:[v.crossOrigin,v.integrity],z.preloads.stylesheets.set(u,V),z.bulkPreloads.add(V);break;case"script":if(N.scriptResources.hasOwnProperty(u))return;V=[],z.preloads.scripts.set(u,V),z.bulkPreloads.add(V),vn(V,he({rel:"preload",href:u,as:f},v)),N.scriptResources[u]=!v||typeof v.crossOrigin!="string"&&typeof v.integrity!="string"?Mo:[v.crossOrigin,v.integrity];break;default:if(N.unknownResources.hasOwnProperty(f)){if(V=N.unknownResources[f],V.hasOwnProperty(u))return}else V={},N.unknownResources[f]=V;if(V[u]=Mo,(N=z.headers)&&0<N.remainingCapacity&&f==="font"&&(ce=qt(u,f,v),0<=(N.remainingCapacity-=ce.length+2)))z.resets.font[u]=Mo,N.fontPreloads&&(N.fontPreloads+=", "),N.fontPreloads+=ce;else switch(N=[],u=he({rel:"preload",href:u,as:f},v),vn(N,u),f){case"font":z.fontPreloads.add(N);break;default:z.bulkPreloads.add(N)}}Ea(w)}}else vt.L(u,f,v)}function Li(u,f){var v=Bn||null;if(v){var w=v.resumableState,N=v.renderState;if(u){var z=f&&typeof f.as=="string"?f.as:"script";switch(z){case"script":if(w.moduleScriptResources.hasOwnProperty(u))return;z=[],w.moduleScriptResources[u]=!f||typeof f.crossOrigin!="string"&&typeof f.integrity!="string"?Mo:[f.crossOrigin,f.integrity],N.preloads.moduleScripts.set(u,z);break;default:if(w.moduleUnknownResources.hasOwnProperty(z)){var V=w.unknownResources[z];if(V.hasOwnProperty(u))return}else V={},w.moduleUnknownResources[z]=V;z=[],V[u]=Mo}vn(z,he({rel:"modulepreload",href:u},f)),N.bulkPreloads.add(z),Ea(v)}}else vt.m(u,f)}function mo(u,f,v){var w=Bn||null;if(w){var N=w.resumableState,z=w.renderState;if(u){f=f||"default";var V=z.styles.get(f),ge=N.styleResources.hasOwnProperty(u)?N.styleResources[u]:void 0;ge!==null&&(N.styleResources[u]=null,V||(V={precedence:Ae(f),rules:[],hrefs:[],sheets:new Map},z.styles.set(f,V)),f={state:0,props:he({rel:"stylesheet",href:u,"data-precedence":f},v)},ge&&(ge.length===2&&Fi(f.props,ge),(z=z.preloads.stylesheets.get(u))&&0<z.length?z.length=0:f.state=1),V.sheets.set(u,f),Ea(w))}}else vt.S(u,f,v)}function eu(u,f){var v=Bn||null;if(v){var w=v.resumableState,N=v.renderState;if(u){var z=w.scriptResources.hasOwnProperty(u)?w.scriptResources[u]:void 0;z!==null&&(w.scriptResources[u]=null,f=he({src:u,async:!0},f),z&&(z.length===2&&Fi(f,z),u=N.preloads.scripts.get(u))&&(u.length=0),u=[],N.scripts.add(u),Ga(u,f),Ea(v))}}else vt.X(u,f)}function Ec(u,f){var v=Bn||null;if(v){var w=v.resumableState,N=v.renderState;if(u){var z=w.moduleScriptResources.hasOwnProperty(u)?w.moduleScriptResources[u]:void 0;z!==null&&(w.moduleScriptResources[u]=null,f=he({src:u,type:"module",async:!0},f),z&&(z.length===2&&Fi(f,z),u=N.preloads.moduleScripts.get(u))&&(u.length=0),u=[],N.scripts.add(u),Ga(u,f),Ea(v))}}else vt.M(u,f)}function Fi(u,f){u.crossOrigin==null&&(u.crossOrigin=f[0]),u.integrity==null&&(u.integrity=f[1])}function qt(u,f,v){u=(""+u).replace(Mi,ua),f=(""+f).replace(cr,Is),f="<"+u+'>; rel=preload; as="'+f+'"';for(var w in v)le.call(v,w)&&(u=v[w],typeof u=="string"&&(f+="; "+w.toLowerCase()+'="'+(""+u).replace(cr,Is)+'"'));return f}var Mi=/[<>\r\n]/g;function ua(u){switch(u){case"<":return"%3C";case">":return"%3E";case`
18
+ `:return"%0A";case"\r":return"%0D";default:throw Error("escapeLinkHrefForHeaderContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}var cr=/["';,\r\n]/g;function Is(u){switch(u){case'"':return"%22";case"'":return"%27";case";":return"%3B";case",":return"%2C";case`
19
+ `:return"%0A";case"\r":return"%0D";default:throw Error("escapeStringForLinkHeaderQuotedParamValueContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}function tu(u){this.styles.add(u)}function nu(u){this.stylesheets.add(u)}function da(u,f){f.styles.forEach(tu,u),f.stylesheets.forEach(nu,u),f.suspenseyImages&&(u.suspenseyImages=!0)}function ha(u,f){var v=u.idPrefix,w=[],N=u.bootstrapScriptContent,z=u.bootstrapScripts,V=u.bootstrapModules;N!==void 0&&(w.push("<script"),Ka(w,u),w.push(">",(""+N).replace(Bi,$r),"<\/script>")),N=v+"P:";var ge=v+"S:";v+="B:";var J=new Set,ce=new Set,we=new Set,ve=new Map,Le=new Set,Ge=new Set,at=new Set,Qe={images:new Map,stylesheets:new Map,scripts:new Map,moduleScripts:new Map};if(z!==void 0)for(var Xe=0;Xe<z.length;Xe++){var tt=z[Xe],Je,tn=void 0,ct=void 0,mt={rel:"preload",as:"script",fetchPriority:"low",nonce:void 0};typeof tt=="string"?mt.href=Je=tt:(mt.href=Je=tt.src,mt.integrity=ct=typeof tt.integrity=="string"?tt.integrity:void 0,mt.crossOrigin=tn=typeof tt=="string"||tt.crossOrigin==null?void 0:tt.crossOrigin==="use-credentials"?"use-credentials":""),tt=u;var Bt=Je;tt.scriptResources[Bt]=null,tt.moduleScriptResources[Bt]=null,tt=[],vn(tt,mt),Le.add(tt),w.push('<script src="',Ae(Je),'"'),typeof ct=="string"&&w.push(' integrity="',Ae(ct),'"'),typeof tn=="string"&&w.push(' crossorigin="',Ae(tn),'"'),Ka(w,u),w.push(' async=""><\/script>')}if(V!==void 0)for(z=0;z<V.length;z++)mt=V[z],tn=Je=void 0,ct={rel:"modulepreload",fetchPriority:"low",nonce:void 0},typeof mt=="string"?ct.href=Xe=mt:(ct.href=Xe=mt.src,ct.integrity=tn=typeof mt.integrity=="string"?mt.integrity:void 0,ct.crossOrigin=Je=typeof mt=="string"||mt.crossOrigin==null?void 0:mt.crossOrigin==="use-credentials"?"use-credentials":""),mt=u,tt=Xe,mt.scriptResources[tt]=null,mt.moduleScriptResources[tt]=null,mt=[],vn(mt,ct),Le.add(mt),w.push('<script type="module" src="',Ae(Xe),'"'),typeof tn=="string"&&w.push(' integrity="',Ae(tn),'"'),typeof Je=="string"&&w.push(' crossorigin="',Ae(Je),'"'),Ka(w,u),w.push(' async=""><\/script>');return{placeholderPrefix:N,segmentPrefix:ge,boundaryPrefix:v,startInlineScript:"<script",startInlineStyle:"<style",preamble:{htmlChunks:null,headChunks:null,bodyChunks:null},externalRuntimeScript:null,bootstrapChunks:w,importMapChunks:[],onHeaders:void 0,headers:null,resets:{font:{},dns:{},connect:{default:{},anonymous:{},credentials:{}},image:{},style:{}},charsetChunks:[],viewportChunks:[],hoistableChunks:[],preconnects:J,fontPreloads:ce,highImagePreloads:we,styles:ve,bootstrapScripts:Le,scripts:Ge,bulkPreloads:at,preloads:Qe,nonce:{script:void 0,style:void 0},stylesToHoist:!1,generateStaticMarkup:f}}function nl(u,f,v,w){return v.generateStaticMarkup?(u.push(Ae(f)),!1):(f===""?u=w:(w&&u.push("<!-- -->"),u.push(Ae(f)),u=!0),u)}function ol(u,f,v,w){f.generateStaticMarkup||v&&w&&u.push("<!-- -->")}var Di=Function.prototype.bind,Ja=Symbol.for("react.client.reference");function Qa(u){if(u==null)return null;if(typeof u=="function")return u.$$typeof===Ja?null:u.displayName||u.name||null;if(typeof u=="string")return u;switch(u){case y:return"Fragment";case S:return"Profiler";case R:return"StrictMode";case T:return"Suspense";case O:return"SuspenseList";case K:return"Activity"}if(typeof u=="object")switch(u.$$typeof){case b:return"Portal";case A:return u.displayName||"Context";case _:return(u._context.displayName||"Context")+".Consumer";case L:var f=u.render;return u=u.displayName,u||(u=f.displayName||f.name||"",u=u!==""?"ForwardRef("+u+")":"ForwardRef"),u;case U:return f=u.displayName||null,f!==null?f:Qa(u.type)||"Memo";case M:f=u._payload,u=u._init;try{return Qa(u(f))}catch{}}return null}var jn={},fa=null;function qa(u,f){if(u!==f){u.context._currentValue2=u.parentValue,u=u.parent;var v=f.parent;if(u===null){if(v!==null)throw Error(d(401))}else{if(v===null)throw Error(d(401));qa(u,v)}f.context._currentValue2=f.value}}function Oi(u){u.context._currentValue2=u.parentValue,u=u.parent,u!==null&&Oi(u)}function rl(u){var f=u.parent;f!==null&&rl(f),u.context._currentValue2=u.value}function $a(u,f){if(u.context._currentValue2=u.parentValue,u=u.parent,u===null)throw Error(d(402));u.depth===f.depth?qa(u,f):$a(u,f)}function Oo(u,f){var v=f.parent;if(v===null)throw Error(d(402));u.depth===v.depth?qa(u,v):Oo(u,v),f.context._currentValue2=f.value}function jr(u){var f=fa;f!==u&&(f===null?rl(u):u===null?Oi(f):f.depth===u.depth?qa(f,u):f.depth>u.depth?$a(f,u):Oo(f,u),fa=u)}var kc={enqueueSetState:function(u,f){u=u._reactInternals,u.queue!==null&&u.queue.push(f)},enqueueReplaceState:function(u,f){u=u._reactInternals,u.replace=!0,u.queue=[f]},enqueueForceUpdate:function(){}},ei={id:1,overflow:""};function jo(u,f,v){var w=u.id;u=u.overflow;var N=32-ti(w)-1;w&=~(1<<N),v+=1;var z=32-ti(f)+N;if(30<z){var V=N-N%5;return z=(w&(1<<V)-1).toString(32),w>>=V,N-=V,{id:1<<32-ti(f)+N|v<<N|w,overflow:z+u}}return{id:1<<z|v<<N|w,overflow:u}}var ti=Math.clz32?Math.clz32:Ho,Ql=Math.log,ga=Math.LN2;function Ho(u){return u>>>=0,u===0?32:31-(Ql(u)/ga|0)|0}function Gn(){}var Xt=Error(d(460));function wc(u,f,v){switch(v=u[v],v===void 0?u.push(f):v!==f&&(f.then(Gn,Gn),f=v),f.status){case"fulfilled":return f.value;case"rejected":throw f.reason;default:switch(typeof f.status=="string"?f.then(Gn,Gn):(u=f,u.status="pending",u.then(function(w){if(f.status==="pending"){var N=f;N.status="fulfilled",N.value=w}},function(w){if(f.status==="pending"){var N=f;N.status="rejected",N.reason=w}})),f.status){case"fulfilled":return f.value;case"rejected":throw f.reason}throw wl=f,Xt}}var wl=null;function Hr(){if(wl===null)throw Error(d(459));var u=wl;return wl=null,u}function Cc(u,f){return u===f&&(u!==0||1/u===1/f)||u!==u&&f!==f}var Cl=typeof Object.is=="function"?Object.is:Cc,ll=null,pa=null,Sl=null,Tl=null,xa=null,rt=null,Ur=!1,An=!1,sl=0,Hn=0,ql=-1,Bs=0,al=null,Al=null,In=0;function Il(){if(ll===null)throw Error(d(321));return ll}function Bl(){if(0<In)throw Error(d(312));return{memoizedState:null,queue:null,next:null}}function Ps(){return rt===null?xa===null?(Ur=!1,xa=rt=Bl()):(Ur=!0,rt=xa):rt.next===null?(Ur=!1,rt=rt.next=Bl()):(Ur=!0,rt=rt.next),rt}function $l(){var u=al;return al=null,u}function _s(){Tl=Sl=pa=ll=null,An=!1,xa=null,In=0,rt=Al=null}function Uo(u,f){return typeof f=="function"?f(u):f}function Ns(u,f,v){if(ll=Il(),rt=Ps(),Ur){var w=rt.queue;if(f=w.dispatch,Al!==null&&(v=Al.get(w),v!==void 0)){Al.delete(w),w=rt.memoizedState;do w=u(w,v.action),v=v.next;while(v!==null);return rt.memoizedState=w,[w,f]}return[rt.memoizedState,f]}return u=u===Uo?typeof f=="function"?f():f:v!==void 0?v(f):f,rt.memoizedState=u,u=rt.queue={last:null,dispatch:null},u=u.dispatch=Sc.bind(null,ll,u),[rt.memoizedState,u]}function zr(u,f){if(ll=Il(),rt=Ps(),f=f===void 0?null:f,rt!==null){var v=rt.memoizedState;if(v!==null&&f!==null){var w=v[1];e:if(w===null)w=!1;else{for(var N=0;N<w.length&&N<f.length;N++)if(!Cl(f[N],w[N])){w=!1;break e}w=!0}if(w)return v[0]}}return u=u(),rt.memoizedState=[u,f],u}function Sc(u,f,v){if(25<=In)throw Error(d(301));if(u===ll)if(An=!0,u={action:v,next:null},Al===null&&(Al=new Map),v=Al.get(f),v===void 0)Al.set(f,u);else{for(f=v;f.next!==null;)f=f.next;f.next=u}}function Tc(){throw Error(d(440))}function Ac(){throw Error(d(394))}function ma(){throw Error(d(479))}function ba(u,f,v){Il();var w=Hn++,N=Sl;if(typeof u.$$FORM_ACTION=="function"){var z=null,V=Tl;N=N.formState;var ge=u.$$IS_SIGNATURE_EQUAL;if(N!==null&&typeof ge=="function"){var J=N[1];ge.call(u,N[2],N[3])&&(z=v!==void 0?"p"+v:"k"+q(JSON.stringify([V,null,w]),0),J===z&&(ql=w,f=N[0]))}var ce=u.bind(null,f);return u=function(ve){ce(ve)},typeof ce.$$FORM_ACTION=="function"&&(u.$$FORM_ACTION=function(ve){ve=ce.$$FORM_ACTION(ve),v!==void 0&&(v+="",ve.action=v);var Le=ve.data;return Le&&(z===null&&(z=v!==void 0?"p"+v:"k"+q(JSON.stringify([V,null,w]),0)),Le.append("$ACTION_KEY",z)),ve}),[f,u,!1]}var we=u.bind(null,f);return[f,function(ve){we(ve)},!1]}function ya(u){var f=Bs;return Bs+=1,al===null&&(al=[]),wc(al,u,f)}function Vn(){throw Error(d(393))}var ou={readContext:function(u){return u._currentValue2},use:function(u){if(u!==null&&typeof u=="object"){if(typeof u.then=="function")return ya(u);if(u.$$typeof===A)return u._currentValue2}throw Error(d(438,String(u)))},useContext:function(u){return Il(),u._currentValue2},useMemo:zr,useReducer:Ns,useRef:function(u){ll=Il(),rt=Ps();var f=rt.memoizedState;return f===null?(u={current:u},rt.memoizedState=u):f},useState:function(u){return Ns(Uo,u)},useInsertionEffect:Gn,useLayoutEffect:Gn,useCallback:function(u,f){return zr(function(){return u},f)},useImperativeHandle:Gn,useEffect:Gn,useDebugValue:Gn,useDeferredValue:function(u,f){return Il(),f!==void 0?f:u},useTransition:function(){return Il(),[!1,Ac]},useId:function(){var u=pa.treeContext,f=u.overflow;u=u.id,u=(u&~(1<<32-ti(u)-1)).toString(32)+f;var v=es;if(v===null)throw Error(d(404));return f=sl++,u="_"+v.idPrefix+"R_"+u,0<f&&(u+="H"+f.toString(32)),u+"_"},useSyncExternalStore:function(u,f,v){if(v===void 0)throw Error(d(407));return v()},useOptimistic:function(u){return Il(),[u,ma]},useActionState:ba,useFormState:ba,useHostTransitionStatus:function(){return Il(),go},useMemoCache:function(u){for(var f=Array(u),v=0;v<u;v++)f[v]=ee;return f},useCacheRefresh:function(){return Vn},useEffectEvent:function(){return Tc}},es=null,ni={getCacheForType:function(){throw Error(d(248))},cacheSignal:function(){throw Error(d(248))}},ji,Pl;function ts(u){if(ji===void 0)try{throw Error()}catch(v){var f=v.stack.trim().match(/\n( *(at )?)/);ji=f&&f[1]||"",Pl=-1<v.stack.indexOf(`
20
+ at`)?" (<anonymous>)":-1<v.stack.indexOf("@")?"@unknown:0:0":""}return`
21
+ `+ji+u+Pl}var va=!1;function Wr(u,f){if(!u||va)return"";va=!0;var v=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var w={DetermineComponentFrameRoot:function(){try{if(f){var ve=function(){throw Error()};if(Object.defineProperty(ve.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(ve,[])}catch(Ge){var Le=Ge}Reflect.construct(u,[],ve)}else{try{ve.call()}catch(Ge){Le=Ge}u.call(ve.prototype)}}else{try{throw Error()}catch(Ge){Le=Ge}(ve=u())&&typeof ve.catch=="function"&&ve.catch(function(){})}}catch(Ge){if(Ge&&Le&&typeof Ge.stack=="string")return[Ge.stack,Le.stack]}return[null,null]}};w.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var N=Object.getOwnPropertyDescriptor(w.DetermineComponentFrameRoot,"name");N&&N.configurable&&Object.defineProperty(w.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var z=w.DetermineComponentFrameRoot(),V=z[0],ge=z[1];if(V&&ge){var J=V.split(`
22
+ `),ce=ge.split(`
23
+ `);for(N=w=0;w<J.length&&!J[w].includes("DetermineComponentFrameRoot");)w++;for(;N<ce.length&&!ce[N].includes("DetermineComponentFrameRoot");)N++;if(w===J.length||N===ce.length)for(w=J.length-1,N=ce.length-1;1<=w&&0<=N&&J[w]!==ce[N];)N--;for(;1<=w&&0<=N;w--,N--)if(J[w]!==ce[N]){if(w!==1||N!==1)do if(w--,N--,0>N||J[w]!==ce[N]){var we=`
24
+ `+J[w].replace(" at new "," at ");return u.displayName&&we.includes("<anonymous>")&&(we=we.replace("<anonymous>",u.displayName)),we}while(1<=w&&0<=N);break}}}finally{va=!1,Error.prepareStackTrace=v}return(v=u?u.displayName||u.name:"")?ts(v):""}function ns(u){if(typeof u=="string")return ts(u);if(typeof u=="function")return u.prototype&&u.prototype.isReactComponent?Wr(u,!0):Wr(u,!1);if(typeof u=="object"&&u!==null){switch(u.$$typeof){case L:return Wr(u.render,!1);case U:return Wr(u.type,!1);case M:var f=u,v=f._payload;f=f._init;try{u=f(v)}catch{return ts("Lazy")}return ns(u)}if(typeof u.name=="string"){e:{v=u.name,f=u.env;var w=u.debugLocation;if(w!=null&&(u=Error.prepareStackTrace,Error.prepareStackTrace=void 0,w=w.stack,Error.prepareStackTrace=u,w.startsWith(`Error: react-stack-top-frame
25
+ `)&&(w=w.slice(29)),u=w.indexOf(`
26
+ `),u!==-1&&(w=w.slice(u+1)),u=w.indexOf("react_stack_bottom_frame"),u!==-1&&(u=w.lastIndexOf(`
27
+ `,u)),u=u!==-1?w=w.slice(0,u):"",w=u.lastIndexOf(`
28
+ `),u=w===-1?u:u.slice(w+1),u.indexOf(v)!==-1)){v=`
29
+ `+u;break e}v=ts(v+(f?" ["+f+"]":""))}return v}}switch(u){case O:return ts("SuspenseList");case T:return ts("Suspense")}return""}function os(u,f){return(500<f.byteSize||!1)&&f.contentPreamble===null}function Ic(u){if(typeof u=="object"&&u!==null&&typeof u.environmentName=="string"){var f=u.environmentName;u=[u].slice(0),typeof u[0]=="string"?u.splice(0,1,"[%s] "+u[0]," "+f+" "):u.splice(0,0,"[%s]"," "+f+" "),u.unshift(console),f=Di.apply(console.error,u),f()}else console.error(u);return null}function vu(u,f,v,w,N,z,V,ge,J,ce,we){var ve=new Set;this.destination=null,this.flushScheduled=!1,this.resumableState=u,this.renderState=f,this.rootFormatContext=v,this.progressiveChunkSize=w===void 0?12800:w,this.status=10,this.fatalError=null,this.pendingRootTasks=this.allPendingTasks=this.nextSegmentId=0,this.completedPreambleSegments=this.completedRootSegment=null,this.byteSize=0,this.abortableTasks=ve,this.pingedTasks=[],this.clientRenderedBoundaries=[],this.completedBoundaries=[],this.partialBoundaries=[],this.trackedPostpones=null,this.onError=N===void 0?Ic:N,this.onPostpone=ce===void 0?Gn:ce,this.onAllReady=z===void 0?Gn:z,this.onShellReady=V===void 0?Gn:V,this.onShellError=ge===void 0?Gn:ge,this.onFatalError=J===void 0?Gn:J,this.formState=we===void 0?null:we}function Ls(u,f,v,w,N,z,V,ge,J,ce,we,ve){return f=new vu(f,v,w,N,z,V,ge,J,ce,we,ve),v=ur(f,0,null,w,!1,!1),v.parentFlushed=!0,u=ri(f,null,u,-1,null,v,null,null,f.abortableTasks,null,w,null,ei,null,null),dr(u),f.pingedTasks.push(u),f}var Bn=null;function il(u,f){u.pingedTasks.push(f),u.pingedTasks.length===1&&(u.flushScheduled=u.destination!==null,lu(u))}function oi(u,f,v,w,N){return v={status:0,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,row:f,completedSegments:[],byteSize:0,fallbackAbortableTasks:v,errorDigest:null,contentState:kt(),fallbackState:kt(),contentPreamble:w,fallbackPreamble:N,trackedContentKeyPath:null,trackedFallbackNode:null},f!==null&&(f.pendingTasks++,w=f.boundaries,w!==null&&(u.allPendingTasks++,v.pendingTasks++,w.push(v)),u=f.inheritedHoistables,u!==null&&da(v.contentState,u)),v}function ri(u,f,v,w,N,z,V,ge,J,ce,we,ve,Le,Ge,at){u.allPendingTasks++,N===null?u.pendingRootTasks++:N.pendingTasks++,Ge!==null&&Ge.pendingTasks++;var Qe={replay:null,node:v,childIndex:w,ping:function(){return il(u,Qe)},blockedBoundary:N,blockedSegment:z,blockedPreamble:V,hoistableState:ge,abortSet:J,keyPath:ce,formatContext:we,context:ve,treeContext:Le,row:Ge,componentStack:at,thenableState:f};return J.add(Qe),Qe}function Hi(u,f,v,w,N,z,V,ge,J,ce,we,ve,Le,Ge){u.allPendingTasks++,z===null?u.pendingRootTasks++:z.pendingTasks++,Le!==null&&Le.pendingTasks++,v.pendingTasks++;var at={replay:v,node:w,childIndex:N,ping:function(){return il(u,at)},blockedBoundary:z,blockedSegment:null,blockedPreamble:null,hoistableState:V,abortSet:ge,keyPath:J,formatContext:ce,context:we,treeContext:ve,row:Le,componentStack:Ge,thenableState:f};return ge.add(at),at}function ur(u,f,v,w,N,z){return{status:0,parentFlushed:!1,id:-1,index:f,chunks:[],children:[],preambleChildren:[],parentFormatContext:w,boundary:v,lastPushedText:N,textEmbedded:z}}function dr(u){var f=u.node;if(typeof f=="object"&&f!==null)switch(f.$$typeof){case x:u.componentStack={parent:u.componentStack,type:f.type}}}function Jo(u){return u===null?null:{parent:u.parent,type:"Suspense Fallback"}}function hr(u){var f={};return u&&Object.defineProperty(f,"componentStack",{configurable:!0,enumerable:!0,get:function(){try{var v="",w=u;do v+=ns(w.type),w=w.parent;while(w);var N=v}catch(z){N=`
30
+ Error generating stack: `+z.message+`
31
+ `+z.stack}return Object.defineProperty(f,"componentStack",{value:N}),N}}),f}function Ut(u,f,v){if(u=u.onError,f=u(f,v),f==null||typeof f=="string")return f}function fr(u,f){var v=u.onShellError,w=u.onFatalError;v(f),w(f),u.destination!==null?(u.status=14,u.destination.destroy(f)):(u.status=13,u.fatalError=f)}function $t(u,f){Gr(u,f.next,f.hoistables)}function Gr(u,f,v){for(;f!==null;){v!==null&&(da(f.hoistables,v),f.inheritedHoistables=v);var w=f.boundaries;if(w!==null){f.boundaries=null;for(var N=0;N<w.length;N++){var z=w[N];v!==null&&da(z.contentState,v),Nl(u,z,null,null)}}if(f.pendingTasks--,0<f.pendingTasks)break;v=f.hoistables,f=f.next}}function Ui(u,f){var v=f.boundaries;if(v!==null&&f.pendingTasks===v.length){for(var w=!0,N=0;N<v.length;N++){var z=v[N];if(z.pendingTasks!==1||z.parentFlushed||os(u,z)){w=!1;break}}w&&Gr(u,f,f.hoistables)}}function zi(u){var f={pendingTasks:1,boundaries:null,hoistables:kt(),inheritedHoistables:null,together:!1,next:null};return u!==null&&0<u.pendingTasks&&(f.pendingTasks++,f.boundaries=[],u.next=f),f}function Wi(u,f,v,w,N){var z=f.keyPath,V=f.treeContext,ge=f.row;f.keyPath=v,v=w.length;var J=null;if(f.replay!==null){var ce=f.replay.slots;if(ce!==null&&typeof ce=="object")for(var we=0;we<v;we++){var ve=N!=="backwards"&&N!=="unstable_legacy-backwards"?we:v-1-we,Le=w[ve];f.row=J=zi(J),f.treeContext=jo(V,v,ve);var Ge=ce[ve];typeof Ge=="number"?(ai(u,f,Ge,Le,ve),delete ce[ve]):Qn(u,f,Le,ve),--J.pendingTasks===0&&$t(u,J)}else for(ce=0;ce<v;ce++)we=N!=="backwards"&&N!=="unstable_legacy-backwards"?ce:v-1-ce,ve=w[we],f.row=J=zi(J),f.treeContext=jo(V,v,we),Qn(u,f,ve,we),--J.pendingTasks===0&&$t(u,J)}else if(N!=="backwards"&&N!=="unstable_legacy-backwards")for(N=0;N<v;N++)ce=w[N],f.row=J=zi(J),f.treeContext=jo(V,v,N),Qn(u,f,ce,N),--J.pendingTasks===0&&$t(u,J);else{for(N=f.blockedSegment,ce=N.children.length,we=N.chunks.length,ve=v-1;0<=ve;ve--){Le=w[ve],f.row=J=zi(J),f.treeContext=jo(V,v,ve),Ge=ur(u,we,null,f.formatContext,ve===0?N.lastPushedText:!0,!0),N.children.splice(ce,0,Ge),f.blockedSegment=Ge;try{Qn(u,f,Le,ve),ol(Ge.chunks,u.renderState,Ge.lastPushedText,Ge.textEmbedded),Ge.status=1,--J.pendingTasks===0&&$t(u,J)}catch(at){throw Ge.status=u.status===12?3:4,at}}f.blockedSegment=N,N.lastPushedText=!1}ge!==null&&J!==null&&0<J.pendingTasks&&(ge.pendingTasks++,J.next=ge),f.treeContext=V,f.row=ge,f.keyPath=z}function li(u,f,v,w,N,z){var V=f.thenableState;for(f.thenableState=null,ll={},pa=f,Sl=u,Tl=v,Hn=sl=0,ql=-1,Bs=0,al=V,u=w(N,z);An;)An=!1,Hn=sl=0,ql=-1,Bs=0,In+=1,rt=null,u=w(N,z);return _s(),u}function _l(u,f,v,w,N,z,V){var ge=!1;if(z!==0&&u.formState!==null){var J=f.blockedSegment;if(J!==null){ge=!0,J=J.chunks;for(var ce=0;ce<z;ce++)ce===V?J.push("<!--F!-->"):J.push("<!--F-->")}}z=f.keyPath,f.keyPath=v,N?(v=f.treeContext,f.treeContext=jo(v,1,0),Qn(u,f,w,-1),f.treeContext=v):ge?Qn(u,f,w,-1):zo(u,f,w,-1),f.keyPath=z}function si(u,f,v,w,N,z){if(typeof w=="function")if(w.prototype&&w.prototype.isReactComponent){var V=N;if("ref"in N){V={};for(var ge in N)ge!=="ref"&&(V[ge]=N[ge])}var J=w.defaultProps;if(J){V===N&&(V=he({},V,N));for(var ce in J)V[ce]===void 0&&(V[ce]=J[ce])}N=V,V=jn,J=w.contextType,typeof J=="object"&&J!==null&&(V=J._currentValue2),V=new w(N,V);var we=V.state!==void 0?V.state:null;if(V.updater=kc,V.props=N,V.state=we,J={queue:[],replace:!1},V._reactInternals=J,z=w.contextType,V.context=typeof z=="object"&&z!==null?z._currentValue2:jn,z=w.getDerivedStateFromProps,typeof z=="function"&&(z=z(N,we),we=z==null?we:he({},we,z),V.state=we),typeof w.getDerivedStateFromProps!="function"&&typeof V.getSnapshotBeforeUpdate!="function"&&(typeof V.UNSAFE_componentWillMount=="function"||typeof V.componentWillMount=="function"))if(w=V.state,typeof V.componentWillMount=="function"&&V.componentWillMount(),typeof V.UNSAFE_componentWillMount=="function"&&V.UNSAFE_componentWillMount(),w!==V.state&&kc.enqueueReplaceState(V,V.state,null),J.queue!==null&&0<J.queue.length)if(w=J.queue,z=J.replace,J.queue=null,J.replace=!1,z&&w.length===1)V.state=w[0];else{for(J=z?w[0]:V.state,we=!0,z=z?1:0;z<w.length;z++)ce=w[z],ce=typeof ce=="function"?ce.call(V,J,N,void 0):ce,ce!=null&&(we?(we=!1,J=he({},J,ce)):he(J,ce));V.state=J}else J.queue=null;if(w=V.render(),u.status===12)throw null;N=f.keyPath,f.keyPath=v,zo(u,f,w,-1),f.keyPath=N}else{if(w=li(u,f,v,w,N,void 0),u.status===12)throw null;_l(u,f,v,w,sl!==0,Hn,ql)}else if(typeof w=="string")if(V=f.blockedSegment,V===null)V=N.children,J=f.formatContext,we=f.keyPath,f.formatContext=Pi(J,w,N),f.keyPath=v,Qn(u,f,V,-1),f.formatContext=J,f.keyPath=we;else{if(we=Qt(V.chunks,w,N,u.resumableState,u.renderState,f.blockedPreamble,f.hoistableState,f.formatContext,V.lastPushedText),V.lastPushedText=!1,J=f.formatContext,z=f.keyPath,f.keyPath=v,(f.formatContext=Pi(J,w,N)).insertionMode===3){v=ur(u,0,null,f.formatContext,!1,!1),V.preambleChildren.push(v),f.blockedSegment=v;try{v.status=6,Qn(u,f,we,-1),ol(v.chunks,u.renderState,v.lastPushedText,v.textEmbedded),v.status=1}finally{f.blockedSegment=V}}else Qn(u,f,we,-1);f.formatContext=J,f.keyPath=z;e:{switch(f=V.chunks,u=u.resumableState,w){case"title":case"style":case"script":case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break e;case"body":if(1>=J.insertionMode){u.hasBody=!0;break e}break;case"html":if(J.insertionMode===0){u.hasHtml=!0;break e}break;case"head":if(1>=J.insertionMode)break e}f.push(Cs(w))}V.lastPushedText=!1}else{switch(w){case $:case R:case S:case y:w=f.keyPath,f.keyPath=v,zo(u,f,N.children,-1),f.keyPath=w;return;case K:w=f.blockedSegment,w===null?N.mode!=="hidden"&&(w=f.keyPath,f.keyPath=v,Qn(u,f,N.children,-1),f.keyPath=w):N.mode!=="hidden"&&(u.renderState.generateStaticMarkup||w.chunks.push("<!--&-->"),w.lastPushedText=!1,V=f.keyPath,f.keyPath=v,Qn(u,f,N.children,-1),f.keyPath=V,u.renderState.generateStaticMarkup||w.chunks.push("<!--/&-->"),w.lastPushedText=!1);return;case O:e:{if(w=N.children,N=N.revealOrder,N==="forwards"||N==="backwards"||N==="unstable_legacy-backwards"){if(de(w)){Wi(u,f,v,w,N);break e}if((V=ye(w))&&(V=V.call(w))){if(J=V.next(),!J.done){do J=V.next();while(!J.done);Wi(u,f,v,w,N)}break e}}N==="together"?(N=f.keyPath,V=f.row,J=f.row=zi(null),J.boundaries=[],J.together=!0,f.keyPath=v,zo(u,f,w,-1),--J.pendingTasks===0&&$t(u,J),f.keyPath=N,f.row=V,V!==null&&0<J.pendingTasks&&(V.pendingTasks++,J.next=V)):(N=f.keyPath,f.keyPath=v,zo(u,f,w,-1),f.keyPath=N)}return;case ae:case D:throw Error(d(343));case T:e:if(f.replay!==null){w=f.keyPath,V=f.formatContext,J=f.row,f.keyPath=v,f.formatContext=_t(u.resumableState,V),f.row=null,v=N.children;try{Qn(u,f,v,-1)}finally{f.keyPath=w,f.formatContext=V,f.row=J}}else{w=f.keyPath,z=f.formatContext;var ve=f.row,Le=f.blockedBoundary;ce=f.blockedPreamble;var Ge=f.hoistableState;ge=f.blockedSegment;var at=N.fallback;N=N.children;var Qe=new Set,Xe=oi(u,f.row,Qe,null,null);u.trackedPostpones!==null&&(Xe.trackedContentKeyPath=v);var tt=ur(u,ge.chunks.length,Xe,f.formatContext,!1,!1);ge.children.push(tt),ge.lastPushedText=!1;var Je=ur(u,0,null,f.formatContext,!1,!1);if(Je.parentFlushed=!0,u.trackedPostpones!==null){V=f.componentStack,J=[v[0],"Suspense Fallback",v[2]],we=[J[1],J[2],[],null],u.trackedPostpones.workingMap.set(J,we),Xe.trackedFallbackNode=we,f.blockedSegment=tt,f.blockedPreamble=Xe.fallbackPreamble,f.keyPath=J,f.formatContext=Tn(u.resumableState,z),f.componentStack=Jo(V),tt.status=6;try{Qn(u,f,at,-1),ol(tt.chunks,u.renderState,tt.lastPushedText,tt.textEmbedded),tt.status=1}catch(tn){throw tt.status=u.status===12?3:4,tn}finally{f.blockedSegment=ge,f.blockedPreamble=ce,f.keyPath=w,f.formatContext=z}f=ri(u,null,N,-1,Xe,Je,Xe.contentPreamble,Xe.contentState,f.abortSet,v,_t(u.resumableState,f.formatContext),f.context,f.treeContext,null,V),dr(f),u.pingedTasks.push(f)}else{f.blockedBoundary=Xe,f.blockedPreamble=Xe.contentPreamble,f.hoistableState=Xe.contentState,f.blockedSegment=Je,f.keyPath=v,f.formatContext=_t(u.resumableState,z),f.row=null,Je.status=6;try{if(Qn(u,f,N,-1),ol(Je.chunks,u.renderState,Je.lastPushedText,Je.textEmbedded),Je.status=1,ro(Xe,Je),Xe.pendingTasks===0&&Xe.status===0){if(Xe.status=1,!os(u,Xe)){ve!==null&&--ve.pendingTasks===0&&$t(u,ve),u.pendingRootTasks===0&&f.blockedPreamble&&Os(u);break e}}else ve!==null&&ve.together&&Ui(u,ve)}catch(tn){Xe.status=4,u.status===12?(Je.status=3,V=u.fatalError):(Je.status=4,V=tn),J=hr(f.componentStack),we=Ut(u,V,J),Xe.errorDigest=we,Ms(u,Xe)}finally{f.blockedBoundary=Le,f.blockedPreamble=ce,f.hoistableState=Ge,f.blockedSegment=ge,f.keyPath=w,f.formatContext=z,f.row=ve}f=ri(u,null,at,-1,Le,tt,Xe.fallbackPreamble,Xe.fallbackState,Qe,[v[0],"Suspense Fallback",v[2]],Tn(u.resumableState,f.formatContext),f.context,f.treeContext,f.row,Jo(f.componentStack)),dr(f),u.pingedTasks.push(f)}}return}if(typeof w=="object"&&w!==null)switch(w.$$typeof){case L:if("ref"in N)for(at in V={},N)at!=="ref"&&(V[at]=N[at]);else V=N;w=li(u,f,v,w.render,V,z),_l(u,f,v,w,sl!==0,Hn,ql);return;case U:si(u,f,v,w.type,N,z);return;case A:if(J=N.children,V=f.keyPath,N=N.value,we=w._currentValue2,w._currentValue2=N,z=fa,fa=w={parent:z,depth:z===null?0:z.depth+1,context:w,parentValue:we,value:N},f.context=w,f.keyPath=v,zo(u,f,J,-1),u=fa,u===null)throw Error(d(403));u.context._currentValue2=u.parentValue,u=fa=u.parent,f.context=u,f.keyPath=V;return;case _:N=N.children,w=N(w._context._currentValue2),N=f.keyPath,f.keyPath=v,zo(u,f,w,-1),f.keyPath=N;return;case M:if(V=w._init,w=V(w._payload),u.status===12)throw null;si(u,f,v,w,N,z);return}throw Error(d(130,w==null?w:typeof w,""))}}function ai(u,f,v,w,N){var z=f.replay,V=f.blockedBoundary,ge=ur(u,0,null,f.formatContext,!1,!1);ge.id=v,ge.parentFlushed=!0;try{f.replay=null,f.blockedSegment=ge,Qn(u,f,w,N),ge.status=1,V===null?u.completedRootSegment=ge:(ro(V,ge),V.parentFlushed&&u.partialBoundaries.push(V))}finally{f.replay=z,f.blockedSegment=null}}function zo(u,f,v,w){f.replay!==null&&typeof f.replay.slots=="number"?ai(u,f,f.replay.slots,v,w):(f.node=v,f.childIndex=w,v=f.componentStack,dr(f),en(u,f),f.componentStack=v)}function en(u,f){var v=f.node,w=f.childIndex;if(v!==null){if(typeof v=="object"){switch(v.$$typeof){case x:var N=v.type,z=v.key,V=v.props;v=V.ref;var ge=v!==void 0?v:null,J=Qa(N),ce=z??(w===-1?0:w);if(z=[f.keyPath,J,ce],f.replay!==null)e:{var we=f.replay;for(w=we.nodes,v=0;v<w.length;v++){var ve=w[v];if(ce===ve[1]){if(ve.length===4){if(J!==null&&J!==ve[0])throw Error(d(490,ve[0],J));var Le=ve[2];J=ve[3],ce=f.node,f.replay={nodes:Le,slots:J,pendingTasks:1};try{if(si(u,f,z,N,V,ge),f.replay.pendingTasks===1&&0<f.replay.nodes.length)throw Error(d(488));f.replay.pendingTasks--}catch(Bt){if(typeof Bt=="object"&&Bt!==null&&(Bt===Xt||typeof Bt.then=="function"))throw f.node===ce?f.replay=we:w.splice(v,1),Bt;f.replay.pendingTasks--,V=hr(f.componentStack),z=u,u=f.blockedBoundary,N=Bt,V=Ut(z,N,V),Vr(z,u,Le,J,N,V)}f.replay=we}else{if(N!==T)throw Error(d(490,"Suspense",Qa(N)||"Unknown"));t:{we=void 0,N=ve[5],ge=ve[2],J=ve[3],ce=ve[4]===null?[]:ve[4][2],ve=ve[4]===null?null:ve[4][3];var Ge=f.keyPath,at=f.formatContext,Qe=f.row,Xe=f.replay,tt=f.blockedBoundary,Je=f.hoistableState,tn=V.children,ct=V.fallback,mt=new Set;V=oi(u,f.row,mt,null,null),V.parentFlushed=!0,V.rootSegmentID=N,f.blockedBoundary=V,f.hoistableState=V.contentState,f.keyPath=z,f.formatContext=_t(u.resumableState,at),f.row=null,f.replay={nodes:ge,slots:J,pendingTasks:1};try{if(Qn(u,f,tn,-1),f.replay.pendingTasks===1&&0<f.replay.nodes.length)throw Error(d(488));if(f.replay.pendingTasks--,V.pendingTasks===0&&V.status===0){V.status=1,u.completedBoundaries.push(V);break t}}catch(Bt){V.status=4,Le=hr(f.componentStack),we=Ut(u,Bt,Le),V.errorDigest=we,f.replay.pendingTasks--,u.clientRenderedBoundaries.push(V)}finally{f.blockedBoundary=tt,f.hoistableState=Je,f.replay=Xe,f.keyPath=Ge,f.formatContext=at,f.row=Qe}Le=Hi(u,null,{nodes:ce,slots:ve,pendingTasks:0},ct,-1,tt,V.fallbackState,mt,[z[0],"Suspense Fallback",z[2]],Tn(u.resumableState,f.formatContext),f.context,f.treeContext,f.row,Jo(f.componentStack)),dr(Le),u.pingedTasks.push(Le)}}w.splice(v,1);break e}}}else si(u,f,z,N,V,ge);return;case b:throw Error(d(257));case M:if(Le=v._init,v=Le(v._payload),u.status===12)throw null;zo(u,f,v,w);return}if(de(v)){wt(u,f,v,w);return}if((Le=ye(v))&&(Le=Le.call(v))){if(v=Le.next(),!v.done){V=[];do V.push(v.value),v=Le.next();while(!v.done);wt(u,f,V,w)}return}if(typeof v.then=="function")return f.thenableState=null,zo(u,f,ya(v),w);if(v.$$typeof===A)return zo(u,f,v._currentValue2,w);throw w=Object.prototype.toString.call(v),Error(d(31,w==="[object Object]"?"object with keys {"+Object.keys(v).join(", ")+"}":w))}typeof v=="string"?(w=f.blockedSegment,w!==null&&(w.lastPushedText=nl(w.chunks,v,u.renderState,w.lastPushedText))):(typeof v=="number"||typeof v=="bigint")&&(w=f.blockedSegment,w!==null&&(w.lastPushedText=nl(w.chunks,""+v,u.renderState,w.lastPushedText)))}}function wt(u,f,v,w){var N=f.keyPath;if(w!==-1&&(f.keyPath=[f.keyPath,"Fragment",w],f.replay!==null)){for(var z=f.replay,V=z.nodes,ge=0;ge<V.length;ge++){var J=V[ge];if(J[1]===w){w=J[2],J=J[3],f.replay={nodes:w,slots:J,pendingTasks:1};try{if(wt(u,f,v,-1),f.replay.pendingTasks===1&&0<f.replay.nodes.length)throw Error(d(488));f.replay.pendingTasks--}catch(ve){if(typeof ve=="object"&&ve!==null&&(ve===Xt||typeof ve.then=="function"))throw ve;f.replay.pendingTasks--,v=hr(f.componentStack);var ce=f.blockedBoundary,we=ve;v=Ut(u,we,v),Vr(u,ce,w,J,we,v)}f.replay=z,V.splice(ge,1);break}}f.keyPath=N;return}if(z=f.treeContext,V=v.length,f.replay!==null&&(ge=f.replay.slots,ge!==null&&typeof ge=="object")){for(w=0;w<V;w++)J=v[w],f.treeContext=jo(z,V,w),ce=ge[w],typeof ce=="number"?(ai(u,f,ce,J,w),delete ge[w]):Qn(u,f,J,w);f.treeContext=z,f.keyPath=N;return}for(ge=0;ge<V;ge++)w=v[ge],f.treeContext=jo(z,V,ge),Qn(u,f,w,ge);f.treeContext=z,f.keyPath=N}function rs(u,f,v){if(v.status=5,v.rootSegmentID=u.nextSegmentId++,u=v.trackedContentKeyPath,u===null)throw Error(d(486));var w=v.trackedFallbackNode,N=[],z=f.workingMap.get(u);return z===void 0?(v=[u[1],u[2],N,null,w,v.rootSegmentID],f.workingMap.set(u,v),an(v,u[0],f),v):(z[4]=w,z[5]=v.rootSegmentID,z)}function Fs(u,f,v,w){w.status=5;var N=v.keyPath,z=v.blockedBoundary;if(z===null)w.id=u.nextSegmentId++,f.rootSlots=w.id,u.completedRootSegment!==null&&(u.completedRootSegment.status=5);else{if(z!==null&&z.status===0){var V=rs(u,f,z);if(z.trackedContentKeyPath===N&&v.childIndex===-1){w.id===-1&&(w.id=w.parentFlushed?z.rootSegmentID:u.nextSegmentId++),V[3]=w.id;return}}if(w.id===-1&&(w.id=w.parentFlushed&&z!==null?z.rootSegmentID:u.nextSegmentId++),v.childIndex===-1)N===null?f.rootSlots=w.id:(v=f.workingMap.get(N),v===void 0?(v=[N[1],N[2],[],w.id],an(v,N[0],f)):v[3]=w.id);else{if(N===null){if(u=f.rootSlots,u===null)u=f.rootSlots={};else if(typeof u=="number")throw Error(d(491))}else if(z=f.workingMap,V=z.get(N),V===void 0)u={},V=[N[1],N[2],[],u],z.set(N,V),an(V,N[0],f);else if(u=V[3],u===null)u=V[3]={};else if(typeof u=="number")throw Error(d(491));u[v.childIndex]=w.id}}}function Ms(u,f){u=u.trackedPostpones,u!==null&&(f=f.trackedContentKeyPath,f!==null&&(f=u.workingMap.get(f),f!==void 0&&(f.length=4,f[2]=[],f[3]=null)))}function ls(u,f,v){return Hi(u,v,f.replay,f.node,f.childIndex,f.blockedBoundary,f.hoistableState,f.abortSet,f.keyPath,f.formatContext,f.context,f.treeContext,f.row,f.componentStack)}function Bc(u,f,v){var w=f.blockedSegment,N=ur(u,w.chunks.length,null,f.formatContext,w.lastPushedText,!0);return w.children.push(N),w.lastPushedText=!1,ri(u,v,f.node,f.childIndex,f.blockedBoundary,N,f.blockedPreamble,f.hoistableState,f.abortSet,f.keyPath,f.formatContext,f.context,f.treeContext,f.row,f.componentStack)}function Qn(u,f,v,w){var N=f.formatContext,z=f.context,V=f.keyPath,ge=f.treeContext,J=f.componentStack,ce=f.blockedSegment;if(ce===null){ce=f.replay;try{return zo(u,f,v,w)}catch(Le){if(_s(),v=Le===Xt?Hr():Le,u.status!==12&&typeof v=="object"&&v!==null){if(typeof v.then=="function"){w=Le===Xt?$l():null,u=ls(u,f,w).ping,v.then(u,u),f.formatContext=N,f.context=z,f.keyPath=V,f.treeContext=ge,f.componentStack=J,f.replay=ce,jr(z);return}if(v.message==="Maximum call stack size exceeded"){v=Le===Xt?$l():null,v=ls(u,f,v),u.pingedTasks.push(v),f.formatContext=N,f.context=z,f.keyPath=V,f.treeContext=ge,f.componentStack=J,f.replay=ce,jr(z);return}}}}else{var we=ce.children.length,ve=ce.chunks.length;try{return zo(u,f,v,w)}catch(Le){if(_s(),ce.children.length=we,ce.chunks.length=ve,v=Le===Xt?Hr():Le,u.status!==12&&typeof v=="object"&&v!==null){if(typeof v.then=="function"){ce=v,v=Le===Xt?$l():null,u=Bc(u,f,v).ping,ce.then(u,u),f.formatContext=N,f.context=z,f.keyPath=V,f.treeContext=ge,f.componentStack=J,jr(z);return}if(v.message==="Maximum call stack size exceeded"){ce=Le===Xt?$l():null,ce=Bc(u,f,ce),u.pingedTasks.push(ce),f.formatContext=N,f.context=z,f.keyPath=V,f.treeContext=ge,f.componentStack=J,jr(z);return}}}}throw f.formatContext=N,f.context=z,f.keyPath=V,f.treeContext=ge,jr(z),v}function Ru(u){var f=u.blockedBoundary,v=u.blockedSegment;v!==null&&(v.status=3,Nl(this,f,u.row,v))}function Vr(u,f,v,w,N,z){for(var V=0;V<v.length;V++){var ge=v[V];if(ge.length===4)Vr(u,f,ge[2],ge[3],N,z);else{ge=ge[5];var J=u,ce=z,we=oi(J,null,new Set,null,null);we.parentFlushed=!0,we.rootSegmentID=ge,we.status=4,we.errorDigest=ce,we.parentFlushed&&J.clientRenderedBoundaries.push(we)}}if(v.length=0,w!==null){if(f===null)throw Error(d(487));if(f.status!==4&&(f.status=4,f.errorDigest=z,f.parentFlushed&&u.clientRenderedBoundaries.push(f)),typeof w=="object")for(var ve in w)delete w[ve]}}function ru(u,f,v){var w=u.blockedBoundary,N=u.blockedSegment;if(N!==null){if(N.status===6)return;N.status=3}var z=hr(u.componentStack);if(w===null){if(f.status!==13&&f.status!==14){if(w=u.replay,w===null){f.trackedPostpones!==null&&N!==null?(w=f.trackedPostpones,Ut(f,v,z),Fs(f,w,u,N),Nl(f,null,u.row,N)):(Ut(f,v,z),fr(f,v));return}w.pendingTasks--,w.pendingTasks===0&&0<w.nodes.length&&(N=Ut(f,v,z),Vr(f,null,w.nodes,w.slots,v,N)),f.pendingRootTasks--,f.pendingRootTasks===0&&cl(f)}}else{var V=f.trackedPostpones;if(w.status!==4){if(V!==null&&N!==null)return Ut(f,v,z),Fs(f,V,u,N),w.fallbackAbortableTasks.forEach(function(ge){return ru(ge,f,v)}),w.fallbackAbortableTasks.clear(),Nl(f,w,u.row,N);w.status=4,N=Ut(f,v,z),w.status=4,w.errorDigest=N,Ms(f,w),w.parentFlushed&&f.clientRenderedBoundaries.push(w)}w.pendingTasks--,N=w.row,N!==null&&--N.pendingTasks===0&&$t(f,N),w.fallbackAbortableTasks.forEach(function(ge){return ru(ge,f,v)}),w.fallbackAbortableTasks.clear()}u=u.row,u!==null&&--u.pendingTasks===0&&$t(f,u),f.allPendingTasks--,f.allPendingTasks===0&&ii(f)}function Pc(u,f){try{var v=u.renderState,w=v.onHeaders;if(w){var N=v.headers;if(N){v.headers=null;var z=N.preconnects;if(N.fontPreloads&&(z&&(z+=", "),z+=N.fontPreloads),N.highImagePreloads&&(z&&(z+=", "),z+=N.highImagePreloads),!f){var V=v.styles.values(),ge=V.next();e:for(;0<N.remainingCapacity&&!ge.done;ge=V.next())for(var J=ge.value.sheets.values(),ce=J.next();0<N.remainingCapacity&&!ce.done;ce=J.next()){var we=ce.value,ve=we.props,Le=ve.href,Ge=we.props,at=qt(Ge.href,"style",{crossOrigin:Ge.crossOrigin,integrity:Ge.integrity,nonce:Ge.nonce,type:Ge.type,fetchPriority:Ge.fetchPriority,referrerPolicy:Ge.referrerPolicy,media:Ge.media});if(0<=(N.remainingCapacity-=at.length+2))v.resets.style[Le]=Mo,z&&(z+=", "),z+=at,v.resets.style[Le]=typeof ve.crossOrigin=="string"||typeof ve.integrity=="string"?[ve.crossOrigin,ve.integrity]:Mo;else break e}}w(z?{Link:z}:{})}}}catch(Qe){Ut(u,Qe,{})}}function cl(u){u.trackedPostpones===null&&Pc(u,!0),u.trackedPostpones===null&&Os(u),u.onShellError=Gn,u=u.onShellReady,u()}function ii(u){Pc(u,u.trackedPostpones===null?!0:u.completedRootSegment===null||u.completedRootSegment.status!==5),Os(u),u=u.onAllReady,u()}function ro(u,f){if(f.chunks.length===0&&f.children.length===1&&f.children[0].boundary===null&&f.children[0].id===-1){var v=f.children[0];v.id=f.id,v.parentFlushed=!0,v.status!==1&&v.status!==3&&v.status!==4||ro(u,v)}else u.completedSegments.push(f)}function Nl(u,f,v,w){if(v!==null&&(--v.pendingTasks===0?$t(u,v):v.together&&Ui(u,v)),u.allPendingTasks--,f===null){if(w!==null&&w.parentFlushed){if(u.completedRootSegment!==null)throw Error(d(389));u.completedRootSegment=w}u.pendingRootTasks--,u.pendingRootTasks===0&&cl(u)}else if(f.pendingTasks--,f.status!==4)if(f.pendingTasks===0){if(f.status===0&&(f.status=1),w!==null&&w.parentFlushed&&(w.status===1||w.status===3)&&ro(f,w),f.parentFlushed&&u.completedBoundaries.push(f),f.status===1)v=f.row,v!==null&&da(v.hoistables,f.contentState),os(u,f)||(f.fallbackAbortableTasks.forEach(Ru,u),f.fallbackAbortableTasks.clear(),v!==null&&--v.pendingTasks===0&&$t(u,v)),u.pendingRootTasks===0&&u.trackedPostpones===null&&f.contentPreamble!==null&&Os(u);else if(f.status===5&&(f=f.row,f!==null)){if(u.trackedPostpones!==null){v=u.trackedPostpones;var N=f.next;if(N!==null&&(w=N.boundaries,w!==null))for(N.boundaries=null,N=0;N<w.length;N++){var z=w[N];rs(u,v,z),Nl(u,z,null,null)}}--f.pendingTasks===0&&$t(u,f)}}else w===null||!w.parentFlushed||w.status!==1&&w.status!==3||(ro(f,w),f.completedSegments.length===1&&f.parentFlushed&&u.partialBoundaries.push(f)),f=f.row,f!==null&&f.together&&Ui(u,f);u.allPendingTasks===0&&ii(u)}function lu(u){if(u.status!==14&&u.status!==13){var f=fa,v=ot.H;ot.H=ou;var w=ot.A;ot.A=ni;var N=Bn;Bn=u;var z=es;es=u.resumableState;try{var V=u.pingedTasks,ge;for(ge=0;ge<V.length;ge++){var J=V[ge],ce=u,we=J.blockedSegment;if(we===null){var ve=ce;if(J.replay.pendingTasks!==0){jr(J.context);try{if(typeof J.replay.slots=="number"?ai(ve,J,J.replay.slots,J.node,J.childIndex):en(ve,J),J.replay.pendingTasks===1&&0<J.replay.nodes.length)throw Error(d(488));J.replay.pendingTasks--,J.abortSet.delete(J),Nl(ve,J.blockedBoundary,J.row,null)}catch(nt){_s();var Le=nt===Xt?Hr():nt;if(typeof Le=="object"&&Le!==null&&typeof Le.then=="function"){var Ge=J.ping;Le.then(Ge,Ge),J.thenableState=nt===Xt?$l():null}else{J.replay.pendingTasks--,J.abortSet.delete(J);var at=hr(J.componentStack);ce=void 0;var Qe=ve,Xe=J.blockedBoundary,tt=ve.status===12?ve.fatalError:Le,Je=J.replay.nodes,tn=J.replay.slots;ce=Ut(Qe,tt,at),Vr(Qe,Xe,Je,tn,tt,ce),ve.pendingRootTasks--,ve.pendingRootTasks===0&&cl(ve),ve.allPendingTasks--,ve.allPendingTasks===0&&ii(ve)}}finally{}}}else if(ve=void 0,Qe=we,Qe.status===0){Qe.status=6,jr(J.context);var ct=Qe.children.length,mt=Qe.chunks.length;try{en(ce,J),ol(Qe.chunks,ce.renderState,Qe.lastPushedText,Qe.textEmbedded),J.abortSet.delete(J),Qe.status=1,Nl(ce,J.blockedBoundary,J.row,Qe)}catch(nt){_s(),Qe.children.length=ct,Qe.chunks.length=mt;var Bt=nt===Xt?Hr():ce.status===12?ce.fatalError:nt;if(ce.status===12&&ce.trackedPostpones!==null){var lt=ce.trackedPostpones,un=hr(J.componentStack);J.abortSet.delete(J),Ut(ce,Bt,un),Fs(ce,lt,J,Qe),Nl(ce,J.blockedBoundary,J.row,Qe)}else if(typeof Bt=="object"&&Bt!==null&&typeof Bt.then=="function"){Qe.status=0,J.thenableState=nt===Xt?$l():null;var Ct=J.ping;Bt.then(Ct,Ct)}else{var bo=hr(J.componentStack);J.abortSet.delete(J),Qe.status=4;var Nt=J.blockedBoundary,yt=J.row;if(yt!==null&&--yt.pendingTasks===0&&$t(ce,yt),ce.allPendingTasks--,ve=Ut(ce,Bt,bo),Nt===null)fr(ce,Bt);else if(Nt.pendingTasks--,Nt.status!==4){Nt.status=4,Nt.errorDigest=ve,Ms(ce,Nt);var St=Nt.row;St!==null&&--St.pendingTasks===0&&$t(ce,St),Nt.parentFlushed&&ce.clientRenderedBoundaries.push(Nt),ce.pendingRootTasks===0&&ce.trackedPostpones===null&&Nt.contentPreamble!==null&&Os(ce)}ce.allPendingTasks===0&&ii(ce)}}finally{}}}V.splice(0,ge),u.destination!==null&&Vi(u,u.destination)}catch(nt){Ut(u,nt,{}),fr(u,nt)}finally{es=z,ot.H=v,ot.A=w,v===ou&&jr(f),Bn=N}}}function Ds(u,f,v){f.preambleChildren.length&&v.push(f.preambleChildren);for(var w=!1,N=0;N<f.children.length;N++)w=Gi(u,f.children[N],v)||w;return w}function Gi(u,f,v){var w=f.boundary;if(w===null)return Ds(u,f,v);var N=w.contentPreamble,z=w.fallbackPreamble;if(N===null||z===null)return!1;switch(w.status){case 1:if(Qc(u.renderState,N),u.byteSize+=w.byteSize,f=w.completedSegments[0],!f)throw Error(d(391));return Ds(u,f,v);case 5:if(u.trackedPostpones!==null)return!0;case 4:if(f.status===1)return Qc(u.renderState,z),Ds(u,f,v);default:return!0}}function Os(u){if(u.completedRootSegment&&u.completedPreambleSegments===null){var f=[],v=u.byteSize,w=Gi(u,u.completedRootSegment,f),N=u.renderState.preamble;w===!1||N.headChunks&&N.bodyChunks?u.completedPreambleSegments=f:u.byteSize=v}}function lo(u,f,v,w){switch(v.parentFlushed=!0,v.status){case 0:v.id=u.nextSegmentId++;case 5:return w=v.id,v.lastPushedText=!1,v.textEmbedded=!1,u=u.renderState,f.push('<template id="'),f.push(u.placeholderPrefix),u=w.toString(16),f.push(u),f.push('"></template>');case 1:v.status=2;var N=!0,z=v.chunks,V=0;v=v.children;for(var ge=0;ge<v.length;ge++){for(N=v[ge];V<N.index;V++)f.push(z[V]);N=ss(u,f,N,w)}for(;V<z.length-1;V++)f.push(z[V]);return V<z.length&&(N=f.push(z[V])),N;case 3:return!0;default:throw Error(d(390))}}var qn=0;function ss(u,f,v,w){var N=v.boundary;if(N===null)return lo(u,f,v,w);if(N.parentFlushed=!0,N.status===4){var z=N.row;return z!==null&&--z.pendingTasks===0&&$t(u,z),u.renderState.generateStaticMarkup||(N=N.errorDigest,f.push("<!--$!-->"),f.push("<template"),N&&(f.push(' data-dgst="'),N=Ae(N),f.push(N),f.push('"')),f.push("></template>")),lo(u,f,v,w),u=u.renderState.generateStaticMarkup?!0:f.push("<!--/$-->"),u}if(N.status!==1)return N.status===0&&(N.rootSegmentID=u.nextSegmentId++),0<N.completedSegments.length&&u.partialBoundaries.push(N),yr(f,u.renderState,N.rootSegmentID),w&&da(w,N.fallbackState),lo(u,f,v,w),f.push("<!--/$-->");if(!Ra&&os(u,N)&&qn+N.byteSize>u.progressiveChunkSize)return N.rootSegmentID=u.nextSegmentId++,u.completedBoundaries.push(N),yr(f,u.renderState,N.rootSegmentID),lo(u,f,v,w),f.push("<!--/$-->");if(qn+=N.byteSize,w&&da(w,N.contentState),v=N.row,v!==null&&os(u,N)&&--v.pendingTasks===0&&$t(u,v),u.renderState.generateStaticMarkup||f.push("<!--$-->"),v=N.completedSegments,v.length!==1)throw Error(d(391));return ss(u,f,v[0],w),u=u.renderState.generateStaticMarkup?!0:f.push("<!--/$-->"),u}function Zt(u,f,v,w){return el(f,u.renderState,v.parentFormatContext,v.id),ss(u,f,v,w),qc(f,v.parentFormatContext)}function Mt(u,f,v){qn=v.byteSize;for(var w=v.completedSegments,N=0;N<w.length;N++)js(u,f,v,w[N]);w.length=0,w=v.row,w!==null&&os(u,v)&&--w.pendingTasks===0&&$t(u,w),Ya(f,v.contentState,u.renderState),w=u.resumableState,u=u.renderState,N=v.rootSegmentID,v=v.contentState;var z=u.stylesToHoist;return u.stylesToHoist=!1,f.push(u.startInlineScript),f.push(">"),z?(!(w.instructions&4)&&(w.instructions|=4,f.push('$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};')),!(w.instructions&2)&&(w.instructions|=2,f.push(`$RB=[];$RV=function(a){$RT=performance.now();for(var b=0;b<a.length;b+=2){var c=a[b],e=a[b+1];null!==e.parentNode&&e.parentNode.removeChild(e);var f=c.parentNode;if(f){var g=c.previousSibling,h=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d||"/&"===d)if(0===h)break;else h--;else"$"!==d&&"$?"!==d&&"$~"!==d&&"$!"!==d&&"&"!==d||h++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;e.firstChild;)f.insertBefore(e.firstChild,c);g.data="$";g._reactRetry&&requestAnimationFrame(g._reactRetry)}}a.length=0};
32
+ $RC=function(a,b){if(b=document.getElementById(b))(a=document.getElementById(a))?(a.previousSibling.data="$~",$RB.push(a,b),2===$RB.length&&("number"!==typeof $RT?requestAnimationFrame($RV.bind(null,$RB)):(a=performance.now(),setTimeout($RV.bind(null,$RB),2300>a&&2E3<a?2300-a:$RT+300-a)))):b.parentNode.removeChild(b)};`)),w.instructions&8?f.push('$RR("'):(w.instructions|=8,f.push(`$RM=new Map;$RR=function(n,w,p){function u(q){this._p=null;q()}for(var r=new Map,t=document,h,b,e=t.querySelectorAll("link[data-precedence],style[data-precedence]"),v=[],k=0;b=e[k++];)"not all"===b.getAttribute("media")?v.push(b):("LINK"===b.tagName&&$RM.set(b.getAttribute("href"),b),r.set(b.dataset.precedence,h=b));e=0;b=[];var l,a;for(k=!0;;){if(k){var f=p[e++];if(!f){k=!1;e=0;continue}var c=!1,m=0;var d=f[m++];if(a=$RM.get(d)){var g=a._p;c=!0}else{a=t.createElement("link");a.href=d;a.rel=
33
+ "stylesheet";for(a.dataset.precedence=l=f[m++];g=f[m++];)a.setAttribute(g,f[m++]);g=a._p=new Promise(function(q,x){a.onload=u.bind(a,q);a.onerror=u.bind(a,x)});$RM.set(d,a)}d=a.getAttribute("media");!g||d&&!matchMedia(d).matches||b.push(g);if(c)continue}else{a=v[e++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=r.get(l)||h;c===h&&(h=a);r.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=t.head,c.insertBefore(a,c.firstChild))}if(p=document.getElementById(n))p.previousSibling.data=
34
+ "$~";Promise.all(b).then($RC.bind(null,n,w),$RX.bind(null,n,"CSS failed to load"))};$RR("`))):(!(w.instructions&2)&&(w.instructions|=2,f.push(`$RB=[];$RV=function(a){$RT=performance.now();for(var b=0;b<a.length;b+=2){var c=a[b],e=a[b+1];null!==e.parentNode&&e.parentNode.removeChild(e);var f=c.parentNode;if(f){var g=c.previousSibling,h=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d||"/&"===d)if(0===h)break;else h--;else"$"!==d&&"$?"!==d&&"$~"!==d&&"$!"!==d&&"&"!==d||h++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;e.firstChild;)f.insertBefore(e.firstChild,c);g.data="$";g._reactRetry&&requestAnimationFrame(g._reactRetry)}}a.length=0};
35
+ $RC=function(a,b){if(b=document.getElementById(b))(a=document.getElementById(a))?(a.previousSibling.data="$~",$RB.push(a,b),2===$RB.length&&("number"!==typeof $RT?requestAnimationFrame($RV.bind(null,$RB)):(a=performance.now(),setTimeout($RV.bind(null,$RB),2300>a&&2E3<a?2300-a:$RT+300-a)))):b.parentNode.removeChild(b)};`)),f.push('$RC("')),w=N.toString(16),f.push(u.boundaryPrefix),f.push(w),f.push('","'),f.push(u.segmentPrefix),f.push(w),z?(f.push('",'),tl(f,v)):f.push('"'),v=f.push(")<\/script>"),Rc(f,u)&&v}function js(u,f,v,w){if(w.status===2)return!0;var N=v.contentState,z=w.id;if(z===-1){if((w.id=v.rootSegmentID)===-1)throw Error(d(392));return Zt(u,f,w,N)}return z===v.rootSegmentID?Zt(u,f,w,N):(Zt(u,f,w,N),v=u.resumableState,u=u.renderState,f.push(u.startInlineScript),f.push(">"),v.instructions&1?f.push('$RS("'):(v.instructions|=1,f.push('$RS=function(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("')),f.push(u.segmentPrefix),z=z.toString(16),f.push(z),f.push('","'),f.push(u.placeholderPrefix),f.push(z),f=f.push('")<\/script>'),f)}var Ra=!1;function Vi(u,f){try{if(!(0<u.pendingRootTasks)){var v,w=u.completedRootSegment;if(w!==null){if(w.status===5)return;var N=u.completedPreambleSegments;if(N===null)return;qn=u.byteSize;var z=u.resumableState,V=u.renderState,ge=V.preamble,J=ge.htmlChunks,ce=ge.headChunks,we;if(J){for(we=0;we<J.length;we++)f.push(J[we]);if(ce)for(we=0;we<ce.length;we++)f.push(ce[we]);else{var ve=sn("head");f.push(ve),f.push(">")}}else if(ce)for(we=0;we<ce.length;we++)f.push(ce[we]);var Le=V.charsetChunks;for(we=0;we<Le.length;we++)f.push(Le[we]);Le.length=0,V.preconnects.forEach(ir,f),V.preconnects.clear();var Ge=V.viewportChunks;for(we=0;we<Ge.length;we++)f.push(Ge[we]);Ge.length=0,V.fontPreloads.forEach(ir,f),V.fontPreloads.clear(),V.highImagePreloads.forEach(ir,f),V.highImagePreloads.clear(),Cn=V,V.styles.forEach(gt,f),Cn=null;var at=V.importMapChunks;for(we=0;we<at.length;we++)f.push(at[we]);at.length=0,V.bootstrapScripts.forEach(ir,f),V.scripts.forEach(ir,f),V.scripts.clear(),V.bulkPreloads.forEach(ir,f),V.bulkPreloads.clear(),z.instructions|=32;var Qe=V.hoistableChunks;for(we=0;we<Qe.length;we++)f.push(Qe[we]);for(z=Qe.length=0;z<N.length;z++){var Xe=N[z];for(V=0;V<Xe.length;V++)ss(u,f,Xe[V],null)}var tt=u.renderState.preamble,Je=tt.headChunks;if(tt.htmlChunks||Je){var tn=Cs("head");f.push(tn)}var ct=tt.bodyChunks;if(ct)for(N=0;N<ct.length;N++)f.push(ct[N]);ss(u,f,w,null),u.completedRootSegment=null;var mt=u.renderState;if(u.allPendingTasks!==0||u.clientRenderedBoundaries.length!==0||u.completedBoundaries.length!==0||u.trackedPostpones!==null&&(u.trackedPostpones.rootNodes.length!==0||u.trackedPostpones.rootSlots!==null)){var Bt=u.resumableState;if(!(Bt.instructions&64)){if(Bt.instructions|=64,f.push(mt.startInlineScript),!(Bt.instructions&32)){Bt.instructions|=32;var lt="_"+Bt.idPrefix+"R_";f.push(' id="');var un=Ae(lt);f.push(un),f.push('"')}f.push(">"),f.push("requestAnimationFrame(function(){$RT=performance.now()});"),f.push("<\/script>")}}Rc(f,mt)}var Ct=u.renderState;w=0;var bo=Ct.viewportChunks;for(w=0;w<bo.length;w++)f.push(bo[w]);bo.length=0,Ct.preconnects.forEach(ir,f),Ct.preconnects.clear(),Ct.fontPreloads.forEach(ir,f),Ct.fontPreloads.clear(),Ct.highImagePreloads.forEach(ir,f),Ct.highImagePreloads.clear(),Ct.styles.forEach(Za,f),Ct.scripts.forEach(ir,f),Ct.scripts.clear(),Ct.bulkPreloads.forEach(ir,f),Ct.bulkPreloads.clear();var Nt=Ct.hoistableChunks;for(w=0;w<Nt.length;w++)f.push(Nt[w]);Nt.length=0;var yt=u.clientRenderedBoundaries;for(v=0;v<yt.length;v++){var St=yt[v];Ct=f;var nt=u.resumableState,Tt=u.renderState,Yn=St.rootSegmentID,dt=St.errorDigest;Ct.push(Tt.startInlineScript),Ct.push(">"),nt.instructions&4?Ct.push('$RX("'):(nt.instructions|=4,Ct.push('$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};;$RX("')),Ct.push(Tt.boundaryPrefix);var as=Yn.toString(16);if(Ct.push(as),Ct.push('"'),dt){Ct.push(",");var Fl=mn(dt||"");Ct.push(Fl)}var yo=Ct.push(")<\/script>");if(!yo){u.destination=null,v++,yt.splice(0,v);return}}yt.splice(0,v);var vr=u.completedBoundaries;for(v=0;v<vr.length;v++)if(!Mt(u,f,vr[v])){u.destination=null,v++,vr.splice(0,v);return}vr.splice(0,v),Ra=!0;var Rr=u.partialBoundaries;for(v=0;v<Rr.length;v++){var Er=Rr[v];e:{yt=u,St=f,qn=Er.byteSize;var ul=Er.completedSegments;for(yo=0;yo<ul.length;yo++)if(!js(yt,St,Er,ul[yo])){yo++,ul.splice(0,yo);var Ml=!1;break e}ul.splice(0,yo);var Un=Er.row;Un!==null&&Un.together&&Er.pendingTasks===1&&(Un.pendingTasks===1?Gr(yt,Un,Un.hoistables):Un.pendingTasks--),Ml=Ya(St,Er.contentState,yt.renderState)}if(!Ml){u.destination=null,v++,Rr.splice(0,v);return}}Rr.splice(0,v),Ra=!1;var Hs=u.completedBoundaries;for(v=0;v<Hs.length;v++)if(!Mt(u,f,Hs[v])){u.destination=null,v++,Hs.splice(0,v);return}Hs.splice(0,v)}}finally{Ra=!1,u.allPendingTasks===0&&u.clientRenderedBoundaries.length===0&&u.completedBoundaries.length===0&&(u.flushScheduled=!1,v=u.resumableState,v.hasBody&&(Rr=Cs("body"),f.push(Rr)),v.hasHtml&&(v=Cs("html"),f.push(v)),u.status=14,f.push(null),u.destination=null)}}function Ea(u){if(u.flushScheduled===!1&&u.pingedTasks.length===0&&u.destination!==null){u.flushScheduled=!0;var f=u.destination;f?Vi(u,f):u.flushScheduled=!1}}function _c(u,f){if(u.status===13)u.status=14,f.destroy(u.fatalError);else if(u.status!==14&&u.destination===null){u.destination=f;try{Vi(u,f)}catch(v){Ut(u,v,{}),fr(u,v)}}}function Eu(u,f){(u.status===11||u.status===10)&&(u.status=12);try{var v=u.abortableTasks;if(0<v.size){var w=f===void 0?Error(d(432)):typeof f=="object"&&f!==null&&typeof f.then=="function"?Error(d(530)):f;u.fatalError=w,v.forEach(function(N){return ru(N,u,w)}),v.clear()}u.destination!==null&&Vi(u,u.destination)}catch(N){Ut(u,N,{}),fr(u,N)}}function an(u,f,v){if(f===null)v.rootNodes.push(u);else{var w=v.workingMap,N=w.get(f);N===void 0&&(N=[f[1],f[2],[],null],w.set(f,N),an(N,f[0],v)),N[2].push(u)}}function Ll(){}function su(u,f,v,w){var N=!1,z=null,V="",ge=!1;if(f=po(f?f.identifierPrefix:void 0),u=Ls(u,f,ha(f,v),Sn(0,null,0,null),1/0,Ll,void 0,function(){ge=!0},void 0,void 0,void 0),u.flushScheduled=u.destination!==null,lu(u),u.status===10&&(u.status=11),u.trackedPostpones===null&&Pc(u,u.pendingRootTasks===0),Eu(u,w),_c(u,{push:function(J){return J!==null&&(V+=J),!0},destroy:function(J){N=!0,z=J}}),N&&z!==w)throw z;if(!ge)throw Error(d(426));return V}return reactDomServerLegacy_browser_production.renderToStaticMarkup=function(u,f){return su(u,f,!0,'The server used "renderToStaticMarkup" which does not support Suspense. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server')},reactDomServerLegacy_browser_production.renderToString=function(u,f){return su(u,f,!1,'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server')},reactDomServerLegacy_browser_production.version="19.2.0",reactDomServerLegacy_browser_production}var reactDomServer_browser_production={};/**
36
+ * @license React
37
+ * react-dom-server.browser.production.js
38
+ *
39
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
40
+ *
41
+ * This source code is licensed under the MIT license found in the
42
+ * LICENSE file in the root directory of this source tree.
43
+ */var hasRequiredReactDomServer_browser_production;function requireReactDomServer_browser_production(){if(hasRequiredReactDomServer_browser_production)return reactDomServer_browser_production;hasRequiredReactDomServer_browser_production=1;var n=React,c=require$$1;function d(i){var h="https://react.dev/errors/"+i;if(1<arguments.length){h+="?args[]="+encodeURIComponent(arguments[1]);for(var m=2;m<arguments.length;m++)h+="&args[]="+encodeURIComponent(arguments[m])}return"Minified React error #"+i+"; visit "+h+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var x=Symbol.for("react.transitional.element"),b=Symbol.for("react.portal"),y=Symbol.for("react.fragment"),R=Symbol.for("react.strict_mode"),S=Symbol.for("react.profiler"),_=Symbol.for("react.consumer"),A=Symbol.for("react.context"),L=Symbol.for("react.forward_ref"),T=Symbol.for("react.suspense"),O=Symbol.for("react.suspense_list"),U=Symbol.for("react.memo"),M=Symbol.for("react.lazy"),D=Symbol.for("react.scope"),K=Symbol.for("react.activity"),$=Symbol.for("react.legacy_hidden"),ee=Symbol.for("react.memo_cache_sentinel"),ae=Symbol.for("react.view_transition"),Re=Symbol.iterator;function ye(i){return i===null||typeof i!="object"?null:(i=Re&&i[Re]||i["@@iterator"],typeof i=="function"?i:null)}var de=Array.isArray;function q(i,h){var m=i.length&3,C=i.length-m,P=h;for(h=0;h<C;){var H=i.charCodeAt(h)&255|(i.charCodeAt(++h)&255)<<8|(i.charCodeAt(++h)&255)<<16|(i.charCodeAt(++h)&255)<<24;++h,H=3432918353*(H&65535)+((3432918353*(H>>>16)&65535)<<16)&4294967295,H=H<<15|H>>>17,H=461845907*(H&65535)+((461845907*(H>>>16)&65535)<<16)&4294967295,P^=H,P=P<<13|P>>>19,P=5*(P&65535)+((5*(P>>>16)&65535)<<16)&4294967295,P=(P&65535)+27492+(((P>>>16)+58964&65535)<<16)}switch(H=0,m){case 3:H^=(i.charCodeAt(h+2)&255)<<16;case 2:H^=(i.charCodeAt(h+1)&255)<<8;case 1:H^=i.charCodeAt(h)&255,H=3432918353*(H&65535)+((3432918353*(H>>>16)&65535)<<16)&4294967295,H=H<<15|H>>>17,P^=461845907*(H&65535)+((461845907*(H>>>16)&65535)<<16)&4294967295}return P^=i.length,P^=P>>>16,P=2246822507*(P&65535)+((2246822507*(P>>>16)&65535)<<16)&4294967295,P^=P>>>13,P=3266489909*(P&65535)+((3266489909*(P>>>16)&65535)<<16)&4294967295,(P^P>>>16)>>>0}var he=new MessageChannel,le=[];he.port1.onmessage=function(){var i=le.shift();i&&i()};function xe(i){le.push(i),he.port2.postMessage(null)}function Ee(i){setTimeout(function(){throw i})}var je=Promise,ze=typeof queueMicrotask=="function"?queueMicrotask:function(i){je.resolve(null).then(i).catch(Ee)},We=null,Pe=0;function ue(i,h){if(h.byteLength!==0)if(2048<h.byteLength)0<Pe&&(i.enqueue(new Uint8Array(We.buffer,0,Pe)),We=new Uint8Array(2048),Pe=0),i.enqueue(h);else{var m=We.length-Pe;m<h.byteLength&&(m===0?i.enqueue(We):(We.set(h.subarray(0,m),Pe),i.enqueue(We),h=h.subarray(m)),We=new Uint8Array(2048),Pe=0),We.set(h,Pe),Pe+=h.byteLength}}function Ae(i,h){return ue(i,h),!0}function He(i){We&&0<Pe&&(i.enqueue(new Uint8Array(We.buffer,0,Pe)),We=null,Pe=0)}var kn=new TextEncoder;function Ie(i){return kn.encode(i)}function ie(i){return kn.encode(i)}function ot(i){return i.byteLength}function wn(i,h){typeof i.error=="function"?i.error(h):i.close()}var go=Object.assign,vt=Object.prototype.hasOwnProperty,Mo=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Cn={},Bi={};function $r(i){return vt.call(Bi,i)?!0:vt.call(Cn,i)?!1:Mo.test(i)?Bi[i]=!0:(Cn[i]=!0,!1)}var po=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" ")),Sn=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Pi=/["'&<>]/;function et(i){if(typeof i=="boolean"||typeof i=="number"||typeof i=="bigint")return""+i;i=""+i;var h=Pi.exec(i);if(h){var m="",C,P=0;for(C=h.index;C<i.length;C++){switch(i.charCodeAt(C)){case 34:h="&quot;";break;case 38:h="&amp;";break;case 39:h="&#x27;";break;case 60:h="&lt;";break;case 62:h="&gt;";break;default:continue}P!==C&&(m+=i.slice(P,C)),P=C+1,m+=h}i=P!==C?m+i.slice(P,C):m}return i}var Tn=/([A-Z])/g,_t=/^ms-/,Wn=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Es(i){return Wn.test(""+i)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":i}var Xl=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Jn=c.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Do={pending:!1,data:null,method:null,action:null},Mr=Jn.d;Jn.d={f:Mr.f,r:Mr.r,D:ru,C:Pc,L:cl,m:ii,X:Nl,S:ro,M:lu};var On=[],Dr=null;ie('"></template>');var _i=ie("<script"),Rt=ie("<\/script>"),xo=ie('<script src="'),Vt=ie('<script type="module" src="'),Jc=ie(' nonce="'),vn=ie(' integrity="'),bc=ie(' crossorigin="'),yc=ie(' async=""><\/script>'),kl=ie("<style"),vc=/(<\/|<)(s)(cript)/gi;function Ga(i,h,m,C){return""+h+(m==="s"?"\\u0073":"\\u0053")+C}var ks=ie('<script type="importmap">'),Zl=ie("<\/script>");function ws(i,h,m,C,P,H){m=typeof h=="string"?h:h&&h.script;var W=m===void 0?_i:ie('<script nonce="'+et(m)+'"'),ne=typeof h=="string"?void 0:h&&h.style,X=ne===void 0?kl:ie('<style nonce="'+et(ne)+'"'),oe=i.idPrefix,fe=[],me=i.bootstrapScriptContent,De=i.bootstrapScripts,Me=i.bootstrapModules;if(me!==void 0&&(fe.push(W),rs(fe,i),fe.push(kt,Ie((""+me).replace(vc,Ga)),Rt)),me=[],C!==void 0&&(me.push(ks),me.push(Ie((""+JSON.stringify(C)).replace(vc,Ga))),me.push(Zl)),C=P?{preconnects:"",fontPreloads:"",highImagePreloads:"",remainingCapacity:2+(typeof H=="number"?H:2e3)}:null,P={placeholderPrefix:ie(oe+"P:"),segmentPrefix:ie(oe+"S:"),boundaryPrefix:ie(oe+"B:"),startInlineScript:W,startInlineStyle:X,preamble:sn(),externalRuntimeScript:null,bootstrapChunks:fe,importMapChunks:me,onHeaders:P,headers:C,resets:{font:{},dns:{},connect:{default:{},anonymous:{},credentials:{}},image:{},style:{}},charsetChunks:[],viewportChunks:[],hoistableChunks:[],preconnects:new Set,fontPreloads:new Set,highImagePreloads:new Set,styles:new Map,bootstrapScripts:new Set,scripts:new Set,bulkPreloads:new Set,preloads:{images:new Map,stylesheets:new Map,scripts:new Map,moduleScripts:new Map},nonce:{script:m,style:ne},hoistableState:null,stylesToHoist:!1},De!==void 0)for(C=0;C<De.length;C++)oe=De[C],ne=W=void 0,X={rel:"preload",as:"script",fetchPriority:"low",nonce:h},typeof oe=="string"?X.href=H=oe:(X.href=H=oe.src,X.integrity=ne=typeof oe.integrity=="string"?oe.integrity:void 0,X.crossOrigin=W=typeof oe=="string"||oe.crossOrigin==null?void 0:oe.crossOrigin==="use-credentials"?"use-credentials":""),oe=i,me=H,oe.scriptResources[me]=null,oe.moduleScriptResources[me]=null,oe=[],qt(oe,X),P.bootstrapScripts.add(oe),fe.push(xo,Ie(et(H)),Ht),m&&fe.push(Jc,Ie(et(m)),Ht),typeof ne=="string"&&fe.push(vn,Ie(et(ne)),Ht),typeof W=="string"&&fe.push(bc,Ie(et(W)),Ht),rs(fe,i),fe.push(yc);if(Me!==void 0)for(h=0;h<Me.length;h++)ne=Me[h],H=C=void 0,W={rel:"modulepreload",fetchPriority:"low",nonce:m},typeof ne=="string"?W.href=De=ne:(W.href=De=ne.src,W.integrity=H=typeof ne.integrity=="string"?ne.integrity:void 0,W.crossOrigin=C=typeof ne=="string"||ne.crossOrigin==null?void 0:ne.crossOrigin==="use-credentials"?"use-credentials":""),ne=i,X=De,ne.scriptResources[X]=null,ne.moduleScriptResources[X]=null,ne=[],qt(ne,W),P.bootstrapScripts.add(ne),fe.push(Vt,Ie(et(De)),Ht),m&&fe.push(Jc,Ie(et(m)),Ht),typeof H=="string"&&fe.push(vn,Ie(et(H)),Ht),typeof C=="string"&&fe.push(bc,Ie(et(C)),Ht),rs(fe,i),fe.push(yc);return P}function Va(i,h,m,C,P){return{idPrefix:i===void 0?"":i,nextFormID:0,streamingFormat:0,bootstrapScriptContent:m,bootstrapScripts:C,bootstrapModules:P,instructions:0,hasBody:!1,hasHtml:!1,unknownResources:{},dnsResources:{},connectResources:{default:{},anonymous:{},credentials:{}},imageResources:{},styleResources:{},scriptResources:{},moduleUnknownResources:{},moduleScriptResources:{}}}function sn(){return{htmlChunks:null,headChunks:null,bodyChunks:null}}function Qt(i,h,m,C){return{insertionMode:i,selectedValue:h,tagScope:m,viewTransition:C}}function Ni(i){return Qt(i==="http://www.w3.org/2000/svg"?4:i==="http://www.w3.org/1998/Math/MathML"?5:0,null,0,null)}function Cs(i,h,m){var C=i.tagScope&-25;switch(h){case"noscript":return Qt(2,null,C|1,null);case"select":return Qt(2,m.value!=null?m.value:m.defaultValue,C,null);case"svg":return Qt(4,null,C,null);case"picture":return Qt(2,null,C|2,null);case"math":return Qt(5,null,C,null);case"foreignObject":return Qt(2,null,C,null);case"table":return Qt(6,null,C,null);case"thead":case"tbody":case"tfoot":return Qt(7,null,C,null);case"colgroup":return Qt(9,null,C,null);case"tr":return Qt(8,null,C,null);case"head":if(2>i.insertionMode)return Qt(3,null,C,null);break;case"html":if(i.insertionMode===0)return Qt(1,null,C,null)}return 6<=i.insertionMode||2>i.insertionMode?Qt(2,null,C,null):i.tagScope!==C?Qt(i.insertionMode,i.selectedValue,C,null):i}function Qc(i){return i===null?null:{update:i.update,enter:"none",exit:"none",share:i.update,name:i.autoName,autoName:i.autoName,nameIdx:0}}function Rc(i,h){return h.tagScope&32&&(i.instructions|=128),Qt(h.insertionMode,h.selectedValue,h.tagScope|12,Qc(h.viewTransition))}function yr(i,h){i=Qc(h.viewTransition);var m=h.tagScope|16;return i!==null&&i.share!=="none"&&(m|=64),Qt(h.insertionMode,h.selectedValue,m,i)}var el=ie("<!-- -->");function qc(i,h,m,C){return h===""?C:(C&&i.push(el),i.push(Ie(et(h))),!0)}var Ss=new Map,mn=ie(' style="'),Kl=ie(":"),Jl=ie(";");function Ts(i,h){if(typeof h!="object")throw Error(d(62));var m=!0,C;for(C in h)if(vt.call(h,C)){var P=h[C];if(P!=null&&typeof P!="boolean"&&P!==""){if(C.indexOf("--")===0){var H=Ie(et(C));P=Ie(et((""+P).trim()))}else H=Ss.get(C),H===void 0&&(H=ie(et(C.replace(Tn,"-$1").toLowerCase().replace(_t,"-ms-"))),Ss.set(C,H)),P=typeof P=="number"?P===0||po.has(C)?Ie(""+P):Ie(P+"px"):Ie(et((""+P).trim()));m?(m=!1,i.push(mn,H,Kl,P)):i.push(Jl,H,Kl,P)}}m||i.push(Ht)}var no=ie(" "),Ko=ie('="'),Ht=ie('"'),Ya=ie('=""');function ir(i,h,m){m&&typeof m!="function"&&typeof m!="symbol"&&i.push(no,Ie(h),Ya)}function Et(i,h,m){typeof m!="function"&&typeof m!="symbol"&&typeof m!="boolean"&&i.push(no,Ie(h),Ko,Ie(et(m)),Ht)}var $c=ie(et("javascript:throw new Error('React form unexpectedly submitted.')")),gt=ie('<input type="hidden"');function Xa(i,h){this.push(gt),Za(i),Et(this,"name",h),Et(this,"value",i),this.push(Or)}function Za(i){if(typeof i!="string")throw Error(d(480))}function Ka(i,h){if(typeof h.$$FORM_ACTION=="function"){var m=i.nextFormID++;i=i.idPrefix+m;try{var C=h.$$FORM_ACTION(i);if(C){var P=C.data;P!=null&&P.forEach(Za)}return C}catch(H){if(typeof H=="object"&&H!==null&&typeof H.then=="function")throw H}}return null}function tl(i,h,m,C,P,H,W,ne){var X=null;if(typeof C=="function"){var oe=Ka(h,C);oe!==null?(ne=oe.name,C=oe.action||"",P=oe.encType,H=oe.method,W=oe.target,X=oe.data):(i.push(no,Ie("formAction"),Ko,$c,Ht),W=H=P=C=ne=null,eu(h,m))}return ne!=null&&Ft(i,"name",ne),C!=null&&Ft(i,"formAction",C),P!=null&&Ft(i,"formEncType",P),H!=null&&Ft(i,"formMethod",H),W!=null&&Ft(i,"formTarget",W),X}function Ft(i,h,m){switch(h){case"className":Et(i,"class",m);break;case"tabIndex":Et(i,"tabindex",m);break;case"dir":case"role":case"viewBox":case"width":case"height":Et(i,h,m);break;case"style":Ts(i,m);break;case"src":case"href":if(m==="")break;case"action":case"formAction":if(m==null||typeof m=="function"||typeof m=="symbol"||typeof m=="boolean")break;m=Es(""+m),i.push(no,Ie(h),Ko,Ie(et(m)),Ht);break;case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"autoFocus":case"multiple":case"muted":ir(i,h.toLowerCase(),m);break;case"xlinkHref":if(typeof m=="function"||typeof m=="symbol"||typeof m=="boolean")break;m=Es(""+m),i.push(no,Ie("xlink:href"),Ko,Ie(et(m)),Ht);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":typeof m!="function"&&typeof m!="symbol"&&i.push(no,Ie(h),Ko,Ie(et(m)),Ht);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":m&&typeof m!="function"&&typeof m!="symbol"&&i.push(no,Ie(h),Ya);break;case"capture":case"download":m===!0?i.push(no,Ie(h),Ya):m!==!1&&typeof m!="function"&&typeof m!="symbol"&&i.push(no,Ie(h),Ko,Ie(et(m)),Ht);break;case"cols":case"rows":case"size":case"span":typeof m!="function"&&typeof m!="symbol"&&!isNaN(m)&&1<=m&&i.push(no,Ie(h),Ko,Ie(et(m)),Ht);break;case"rowSpan":case"start":typeof m=="function"||typeof m=="symbol"||isNaN(m)||i.push(no,Ie(h),Ko,Ie(et(m)),Ht);break;case"xlinkActuate":Et(i,"xlink:actuate",m);break;case"xlinkArcrole":Et(i,"xlink:arcrole",m);break;case"xlinkRole":Et(i,"xlink:role",m);break;case"xlinkShow":Et(i,"xlink:show",m);break;case"xlinkTitle":Et(i,"xlink:title",m);break;case"xlinkType":Et(i,"xlink:type",m);break;case"xmlBase":Et(i,"xml:base",m);break;case"xmlLang":Et(i,"xml:lang",m);break;case"xmlSpace":Et(i,"xml:space",m);break;default:if((!(2<h.length)||h[0]!=="o"&&h[0]!=="O"||h[1]!=="n"&&h[1]!=="N")&&(h=Sn.get(h)||h,$r(h))){switch(typeof m){case"function":case"symbol":return;case"boolean":var C=h.toLowerCase().slice(0,5);if(C!=="data-"&&C!=="aria-")return}i.push(no,Ie(h),Ko,Ie(et(m)),Ht)}}}var kt=ie(">"),Or=ie("/>");function oo(i,h,m){if(h!=null){if(m!=null)throw Error(d(60));if(typeof h!="object"||!("__html"in h))throw Error(d(61));h=h.__html,h!=null&&i.push(Ie(""+h))}}function As(i){var h="";return n.Children.forEach(i,function(m){m!=null&&(h+=m)}),h}var Li=ie(' selected=""'),mo=ie(`addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error('React form unexpectedly submitted.')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});`);function eu(i,h){if(!(i.instructions&16)){i.instructions|=16;var m=h.preamble,C=h.bootstrapChunks;(m.htmlChunks||m.headChunks)&&C.length===0?(C.push(h.startInlineScript),rs(C,i),C.push(kt,mo,Rt)):C.unshift(h.startInlineScript,kt,mo,Rt)}}var Ec=ie("<!--F!-->"),Fi=ie("<!--F-->");function qt(i,h){i.push(jn("link"));for(var m in h)if(vt.call(h,m)){var C=h[m];if(C!=null)switch(m){case"children":case"dangerouslySetInnerHTML":throw Error(d(399,"link"));default:Ft(i,m,C)}}return i.push(Or),null}var Mi=/(<\/|<)(s)(tyle)/gi;function ua(i,h,m,C){return""+h+(m==="s"?"\\73 ":"\\53 ")+C}function cr(i,h,m){i.push(jn(m));for(var C in h)if(vt.call(h,C)){var P=h[C];if(P!=null)switch(C){case"children":case"dangerouslySetInnerHTML":throw Error(d(399,m));default:Ft(i,C,P)}}return i.push(Or),null}function Is(i,h){i.push(jn("title"));var m=null,C=null,P;for(P in h)if(vt.call(h,P)){var H=h[P];if(H!=null)switch(P){case"children":m=H;break;case"dangerouslySetInnerHTML":C=H;break;default:Ft(i,P,H)}}return i.push(kt),h=Array.isArray(m)?2>m.length?m[0]:null:m,typeof h!="function"&&typeof h!="symbol"&&h!==null&&h!==void 0&&i.push(Ie(et(""+h))),oo(i,C,m),i.push(rl("title")),null}var tu=ie("<!--head-->"),nu=ie("<!--body-->"),da=ie("<!--html-->");function ha(i,h){i.push(jn("script"));var m=null,C=null,P;for(P in h)if(vt.call(h,P)){var H=h[P];if(H!=null)switch(P){case"children":m=H;break;case"dangerouslySetInnerHTML":C=H;break;default:Ft(i,P,H)}}return i.push(kt),oo(i,C,m),typeof m=="string"&&i.push(Ie((""+m).replace(vc,Ga))),i.push(rl("script")),null}function nl(i,h,m){i.push(jn(m));var C=m=null,P;for(P in h)if(vt.call(h,P)){var H=h[P];if(H!=null)switch(P){case"children":m=H;break;case"dangerouslySetInnerHTML":C=H;break;default:Ft(i,P,H)}}return i.push(kt),oo(i,C,m),m}function ol(i,h,m){i.push(jn(m));var C=m=null,P;for(P in h)if(vt.call(h,P)){var H=h[P];if(H!=null)switch(P){case"children":m=H;break;case"dangerouslySetInnerHTML":C=H;break;default:Ft(i,P,H)}}return i.push(kt),oo(i,C,m),typeof m=="string"?(i.push(Ie(et(m))),null):m}var Di=ie(`
44
+ `),Ja=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,Qa=new Map;function jn(i){var h=Qa.get(i);if(h===void 0){if(!Ja.test(i))throw Error(d(65,i));h=ie("<"+i),Qa.set(i,h)}return h}var fa=ie("<!DOCTYPE html>");function qa(i,h,m,C,P,H,W,ne,X){switch(h){case"div":case"span":case"svg":case"path":break;case"a":i.push(jn("a"));var oe=null,fe=null,me;for(me in m)if(vt.call(m,me)){var De=m[me];if(De!=null)switch(me){case"children":oe=De;break;case"dangerouslySetInnerHTML":fe=De;break;case"href":De===""?Et(i,"href",""):Ft(i,me,De);break;default:Ft(i,me,De)}}if(i.push(kt),oo(i,fe,oe),typeof oe=="string"){i.push(Ie(et(oe)));var Me=null}else Me=oe;return Me;case"g":case"p":case"li":break;case"select":i.push(jn("select"));var pt=null,qe=null,xt;for(xt in m)if(vt.call(m,xt)){var hn=m[xt];if(hn!=null)switch(xt){case"children":pt=hn;break;case"dangerouslySetInnerHTML":qe=hn;break;case"defaultValue":case"value":break;default:Ft(i,xt,hn)}}return i.push(kt),oo(i,qe,pt),pt;case"option":var Kt=ne.selectedValue;i.push(jn("option"));var ao=null,Qo=null,Sr=null,$e=null,wo;for(wo in m)if(vt.call(m,wo)){var En=m[wo];if(En!=null)switch(wo){case"children":ao=En;break;case"selected":Sr=En;break;case"dangerouslySetInnerHTML":$e=En;break;case"value":Qo=En;default:Ft(i,wo,En)}}if(Kt!=null){var Go=Qo!==null?""+Qo:As(ao);if(de(Kt)){for(var Hl=0;Hl<Kt.length;Hl++)if(""+Kt[Hl]===Go){i.push(Li);break}}else""+Kt===Go&&i.push(Li)}else Sr&&i.push(Li);return i.push(kt),oo(i,$e,ao),ao;case"textarea":i.push(jn("textarea"));var fn=null,Ks=null,Tr=null,Co;for(Co in m)if(vt.call(m,Co)){var Zr=m[Co];if(Zr!=null)switch(Co){case"children":Tr=Zr;break;case"value":fn=Zr;break;case"defaultValue":Ks=Zr;break;case"dangerouslySetInnerHTML":throw Error(d(91));default:Ft(i,Co,Zr)}}if(fn===null&&Ks!==null&&(fn=Ks),i.push(kt),Tr!=null){if(fn!=null)throw Error(d(92));if(de(Tr)){if(1<Tr.length)throw Error(d(93));fn=""+Tr[0]}fn=""+Tr}return typeof fn=="string"&&fn[0]===`
45
+ `&&i.push(Di),fn!==null&&i.push(Ie(et(""+fn))),null;case"input":i.push(jn("input"));var So=null,Js=null,Ba=null,Vo=null,Pa=null,To=null,Qs=null,Hc=null,nn=null,_a;for(_a in m)if(vt.call(m,_a)){var Kr=m[_a];if(Kr!=null)switch(_a){case"children":case"dangerouslySetInnerHTML":throw Error(d(399,"input"));case"name":So=Kr;break;case"formAction":Js=Kr;break;case"formEncType":Ba=Kr;break;case"formMethod":Vo=Kr;break;case"formTarget":Pa=Kr;break;case"defaultChecked":nn=Kr;break;case"defaultValue":Qs=Kr;break;case"checked":Hc=Kr;break;case"value":To=Kr;break;default:Ft(i,_a,Kr)}}var tc=tl(i,C,P,Js,Ba,Vo,Pa,So);return Hc!==null?ir(i,"checked",Hc):nn!==null&&ir(i,"checked",nn),To!==null?Ft(i,"value",To):Qs!==null&&Ft(i,"value",Qs),i.push(Or),tc!=null&&tc.forEach(Xa,i),null;case"button":i.push(jn("button"));var qs=null,nc=null,oc=null,Na=null,xs=null,rc=null,hl=null,$s;for($s in m)if(vt.call(m,$s)){var ea=m[$s];if(ea!=null)switch($s){case"children":qs=ea;break;case"dangerouslySetInnerHTML":nc=ea;break;case"name":oc=ea;break;case"formAction":Na=ea;break;case"formEncType":xs=ea;break;case"formMethod":rc=ea;break;case"formTarget":hl=ea;break;default:Ft(i,$s,ea)}}var du=tl(i,C,P,Na,xs,rc,hl,oc);if(i.push(kt),du!=null&&du.forEach(Xa,i),oo(i,nc,qs),typeof qs=="string"){i.push(Ie(et(qs)));var Ar=null}else Ar=qs;return Ar;case"form":i.push(jn("form"));var hu=null,mr=null,ms=null,Ul=null,lc=null,sc=null,ac;for(ac in m)if(vt.call(m,ac)){var ta=m[ac];if(ta!=null)switch(ac){case"children":hu=ta;break;case"dangerouslySetInnerHTML":mr=ta;break;case"action":ms=ta;break;case"encType":Ul=ta;break;case"method":lc=ta;break;case"target":sc=ta;break;default:Ft(i,ac,ta)}}var fu=null,Uc=null;if(typeof ms=="function"){var La=Ka(C,ms);La!==null?(ms=La.action||"",Ul=La.encType,lc=La.method,sc=La.target,fu=La.data,Uc=La.name):(i.push(no,Ie("action"),Ko,$c,Ht),sc=lc=Ul=ms=null,eu(C,P))}if(ms!=null&&Ft(i,"action",ms),Ul!=null&&Ft(i,"encType",Ul),lc!=null&&Ft(i,"method",lc),sc!=null&&Ft(i,"target",sc),i.push(kt),Uc!==null&&(i.push(gt),Et(i,"name",Uc),i.push(Or),fu!=null&&fu.forEach(Xa,i)),oo(i,mr,hu),typeof hu=="string"){i.push(Ie(et(hu)));var gu=null}else gu=hu;return gu;case"menuitem":i.push(jn("menuitem"));for(var ic in m)if(vt.call(m,ic)){var ku=m[ic];if(ku!=null)switch(ic){case"children":case"dangerouslySetInnerHTML":throw Error(d(400));default:Ft(i,ic,ku)}}return i.push(kt),null;case"object":i.push(jn("object"));var zc=null,wu=null,cc;for(cc in m)if(vt.call(m,cc)){var Fa=m[cc];if(Fa!=null)switch(cc){case"children":zc=Fa;break;case"dangerouslySetInnerHTML":wu=Fa;break;case"data":var Bu=Es(""+Fa);if(Bu==="")break;i.push(no,Ie("data"),Ko,Ie(et(Bu)),Ht);break;default:Ft(i,cc,Fa)}}if(i.push(kt),oo(i,wu,zc),typeof zc=="string"){i.push(Ie(et(zc)));var Pu=null}else Pu=zc;return Pu;case"title":var fl=ne.tagScope&1,pu=ne.tagScope&4;if(ne.insertionMode===4||fl||m.itemProp!=null)var _u=Is(i,m);else pu?_u=null:(Is(P.hoistableChunks,m),_u=void 0);return _u;case"link":var $n=ne.tagScope&1,zl=ne.tagScope&4,Ao=m.rel,bs=m.href,Ir=m.precedence;if(ne.insertionMode===4||$n||m.itemProp!=null||typeof Ao!="string"||typeof bs!="string"||bs===""){qt(i,m);var Lt=null}else if(m.rel==="stylesheet")if(typeof Ir!="string"||m.disabled!=null||m.onLoad||m.onError)Lt=qt(i,m);else{var qo=P.styles.get(Ir),Wl=C.styleResources.hasOwnProperty(bs)?C.styleResources[bs]:void 0;if(Wl!==null){C.styleResources[bs]=null,qo||(qo={precedence:Ie(et(Ir)),rules:[],hrefs:[],sheets:new Map},P.styles.set(Ir,qo));var Nn={state:0,props:go({},m,{"data-precedence":m.precedence,precedence:null})};if(Wl){Wl.length===2&&Ds(Nn.props,Wl);var vi=P.preloads.stylesheets.get(bs);vi&&0<vi.length?vi.length=0:Nn.state=1}qo.sheets.set(bs,Nn),W&&W.stylesheets.add(Nn)}else if(qo){var uc=qo.sheets.get(bs);uc&&W&&W.stylesheets.add(uc)}X&&i.push(el),Lt=null}else m.onLoad||m.onError?Lt=qt(i,m):(X&&i.push(el),Lt=zl?null:qt(P.hoistableChunks,m));return Lt;case"script":var xu=ne.tagScope&1,Ma=m.async;if(typeof m.src!="string"||!m.src||!Ma||typeof Ma=="function"||typeof Ma=="symbol"||m.onLoad||m.onError||ne.insertionMode===4||xu||m.itemProp!=null)var na=ha(i,m);else{var Ri=m.src;if(m.type==="module")var Jr=C.moduleScriptResources,oa=P.preloads.moduleScripts;else Jr=C.scriptResources,oa=P.preloads.scripts;var Ei=Jr.hasOwnProperty(Ri)?Jr[Ri]:void 0;if(Ei!==null){Jr[Ri]=null;var r=m;if(Ei){Ei.length===2&&(r=go({},m),Ds(r,Ei));var a=oa.get(Ri);a&&(a.length=0)}var p=[];P.scripts.add(p),ha(p,r)}X&&i.push(el),na=null}return na;case"style":var k=ne.tagScope&1,B=m.precedence,j=m.href,Y=m.nonce;if(ne.insertionMode===4||k||m.itemProp!=null||typeof B!="string"||typeof j!="string"||j===""){i.push(jn("style"));var Q=null,ke=null,re;for(re in m)if(vt.call(m,re)){var be=m[re];if(be!=null)switch(re){case"children":Q=be;break;case"dangerouslySetInnerHTML":ke=be;break;default:Ft(i,re,be)}}i.push(kt);var Ne=Array.isArray(Q)?2>Q.length?Q[0]:null:Q;typeof Ne!="function"&&typeof Ne!="symbol"&&Ne!==null&&Ne!==void 0&&i.push(Ie((""+Ne).replace(Mi,ua))),oo(i,ke,Q),i.push(rl("style"));var Oe=null}else{var Fe=P.styles.get(B);if((C.styleResources.hasOwnProperty(j)?C.styleResources[j]:void 0)!==null){C.styleResources[j]=null,Fe||(Fe={precedence:Ie(et(B)),rules:[],hrefs:[],sheets:new Map},P.styles.set(B,Fe));var Se=P.nonce.style;if(!Se||Se===Y){Fe.hrefs.push(Ie(et(j)));var ht=Fe.rules,Yt=null,Ke=null,At;for(At in m)if(vt.call(m,At)){var io=m[At];if(io!=null)switch(At){case"children":Yt=io;break;case"dangerouslySetInnerHTML":Ke=io}}var co=Array.isArray(Yt)?2>Yt.length?Yt[0]:null:Yt;typeof co!="function"&&typeof co!="symbol"&&co!==null&&co!==void 0&&ht.push(Ie((""+co).replace(Mi,ua))),oo(ht,Ke,Yt)}}Fe&&W&&W.styles.add(Fe),X&&i.push(el),Oe=void 0}return Oe;case"meta":var Pt=ne.tagScope&1,Xn=ne.tagScope&4;if(ne.insertionMode===4||Pt||m.itemProp!=null)var gl=cr(i,m,"meta");else X&&i.push(el),gl=Xn?null:typeof m.charSet=="string"?cr(P.charsetChunks,m,"meta"):m.name==="viewport"?cr(P.viewportChunks,m,"meta"):cr(P.hoistableChunks,m,"meta");return gl;case"listing":case"pre":i.push(jn(h));var Yo=null,Ue=null,Dt;for(Dt in m)if(vt.call(m,Dt)){var Ot=m[Dt];if(Ot!=null)switch(Dt){case"children":Yo=Ot;break;case"dangerouslySetInnerHTML":Ue=Ot;break;default:Ft(i,Dt,Ot)}}if(i.push(kt),Ue!=null){if(Yo!=null)throw Error(d(60));if(typeof Ue!="object"||!("__html"in Ue))throw Error(d(61));var zt=Ue.__html;zt!=null&&(typeof zt=="string"&&0<zt.length&&zt[0]===`
46
+ `?i.push(Di,Ie(zt)):i.push(Ie(""+zt)))}return typeof Yo=="string"&&Yo[0]===`
47
+ `&&i.push(Di),Yo;case"img":var gn=ne.tagScope&3,bt=m.src,st=m.srcSet;if(!(m.loading==="lazy"||!bt&&!st||typeof bt!="string"&&bt!=null||typeof st!="string"&&st!=null||m.fetchPriority==="low"||gn)&&(typeof bt!="string"||bt[4]!==":"||bt[0]!=="d"&&bt[0]!=="D"||bt[1]!=="a"&&bt[1]!=="A"||bt[2]!=="t"&&bt[2]!=="T"||bt[3]!=="a"&&bt[3]!=="A")&&(typeof st!="string"||st[4]!==":"||st[0]!=="d"&&st[0]!=="D"||st[1]!=="a"&&st[1]!=="A"||st[2]!=="t"&&st[2]!=="T"||st[3]!=="a"&&st[3]!=="A")){W!==null&&ne.tagScope&64&&(W.suspenseyImages=!0);var Io=typeof m.sizes=="string"?m.sizes:void 0,jt=st?st+`
48
+ `+(Io||""):bt,uo=P.preloads.images,on=uo.get(jt);if(on)(m.fetchPriority==="high"||10>P.highImagePreloads.size)&&(uo.delete(jt),P.highImagePreloads.add(on));else if(!C.imageResources.hasOwnProperty(jt)){C.imageResources[jt]=On;var $o=m.crossOrigin,Da=typeof $o=="string"?$o==="use-credentials"?$o:"":void 0,er=P.headers,pl;er&&0<er.remainingCapacity&&typeof m.srcSet!="string"&&(m.fetchPriority==="high"||500>er.highImagePreloads.length)&&(pl=Gi(bt,"image",{imageSrcSet:m.srcSet,imageSizes:m.sizes,crossOrigin:Da,integrity:m.integrity,nonce:m.nonce,type:m.type,fetchPriority:m.fetchPriority,referrerPolicy:m.refererPolicy}),0<=(er.remainingCapacity-=pl.length+2))?(P.resets.image[jt]=On,er.highImagePreloads&&(er.highImagePreloads+=", "),er.highImagePreloads+=pl):(on=[],qt(on,{rel:"preload",as:"image",href:st?void 0:bt,imageSrcSet:st,imageSizes:Io,crossOrigin:Da,integrity:m.integrity,type:m.type,fetchPriority:m.fetchPriority,referrerPolicy:m.referrerPolicy}),m.fetchPriority==="high"||10>P.highImagePreloads.size?P.highImagePreloads.add(on):(P.bulkPreloads.add(on),uo.set(jt,on)))}}return cr(i,m,"img");case"base":case"area":case"br":case"col":case"embed":case"hr":case"keygen":case"param":case"source":case"track":case"wbr":return cr(i,m,h);case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":break;case"head":if(2>ne.insertionMode){var xl=H||P.preamble;if(xl.headChunks)throw Error(d(545,"`<head>`"));H!==null&&i.push(tu),xl.headChunks=[];var ml=nl(xl.headChunks,m,"head")}else ml=ol(i,m,"head");return ml;case"body":if(2>ne.insertionMode){var eo=H||P.preamble;if(eo.bodyChunks)throw Error(d(545,"`<body>`"));H!==null&&i.push(nu),eo.bodyChunks=[];var o=nl(eo.bodyChunks,m,"body")}else o=ol(i,m,"body");return o;case"html":if(ne.insertionMode===0){var l=H||P.preamble;if(l.htmlChunks)throw Error(d(545,"`<html>`"));H!==null&&i.push(da),l.htmlChunks=[fa];var g=nl(l.htmlChunks,m,"html")}else g=ol(i,m,"html");return g;default:if(h.indexOf("-")!==-1){i.push(jn(h));var E=null,I=null,F;for(F in m)if(vt.call(m,F)){var G=m[F];if(G!=null){var Z=F;switch(F){case"children":E=G;break;case"dangerouslySetInnerHTML":I=G;break;case"style":Ts(i,G);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"className":Z="class";default:if($r(F)&&typeof G!="function"&&typeof G!="symbol"&&G!==!1){if(G===!0)G="";else if(typeof G=="object")continue;i.push(no,Ie(Z),Ko,Ie(et(G)),Ht)}}}}return i.push(kt),oo(i,I,E),E}}return ol(i,m,h)}var Oi=new Map;function rl(i){var h=Oi.get(i);return h===void 0&&(h=ie("</"+i+">"),Oi.set(i,h)),h}function $a(i,h){i=i.preamble,i.htmlChunks===null&&h.htmlChunks&&(i.htmlChunks=h.htmlChunks),i.headChunks===null&&h.headChunks&&(i.headChunks=h.headChunks),i.bodyChunks===null&&h.bodyChunks&&(i.bodyChunks=h.bodyChunks)}function Oo(i,h){h=h.bootstrapChunks;for(var m=0;m<h.length-1;m++)ue(i,h[m]);return m<h.length?(m=h[m],h.length=0,Ae(i,m)):!0}var jr=ie("requestAnimationFrame(function(){$RT=performance.now()});"),kc=ie('<template id="'),ei=ie('"></template>'),jo=ie("<!--&-->"),ti=ie("<!--/&-->"),Ql=ie("<!--$-->"),ga=ie('<!--$?--><template id="'),Ho=ie('"></template>'),Gn=ie("<!--$!-->"),Xt=ie("<!--/$-->"),wc=ie("<template"),wl=ie('"'),Hr=ie(' data-dgst="');ie(' data-msg="'),ie(' data-stck="'),ie(' data-cstck="');var Cc=ie("></template>");function Cl(i,h,m){if(ue(i,ga),m===null)throw Error(d(395));return ue(i,h.boundaryPrefix),ue(i,Ie(m.toString(16))),Ae(i,Ho)}var ll=ie('<div hidden id="'),pa=ie('">'),Sl=ie("</div>"),Tl=ie('<svg aria-hidden="true" style="display:none" id="'),xa=ie('">'),rt=ie("</svg>"),Ur=ie('<math aria-hidden="true" style="display:none" id="'),An=ie('">'),sl=ie("</math>"),Hn=ie('<table hidden id="'),ql=ie('">'),Bs=ie("</table>"),al=ie('<table hidden><tbody id="'),Al=ie('">'),In=ie("</tbody></table>"),Il=ie('<table hidden><tr id="'),Bl=ie('">'),Ps=ie("</tr></table>"),$l=ie('<table hidden><colgroup id="'),_s=ie('">'),Uo=ie("</colgroup></table>");function Ns(i,h,m,C){switch(m.insertionMode){case 0:case 1:case 3:case 2:return ue(i,ll),ue(i,h.segmentPrefix),ue(i,Ie(C.toString(16))),Ae(i,pa);case 4:return ue(i,Tl),ue(i,h.segmentPrefix),ue(i,Ie(C.toString(16))),Ae(i,xa);case 5:return ue(i,Ur),ue(i,h.segmentPrefix),ue(i,Ie(C.toString(16))),Ae(i,An);case 6:return ue(i,Hn),ue(i,h.segmentPrefix),ue(i,Ie(C.toString(16))),Ae(i,ql);case 7:return ue(i,al),ue(i,h.segmentPrefix),ue(i,Ie(C.toString(16))),Ae(i,Al);case 8:return ue(i,Il),ue(i,h.segmentPrefix),ue(i,Ie(C.toString(16))),Ae(i,Bl);case 9:return ue(i,$l),ue(i,h.segmentPrefix),ue(i,Ie(C.toString(16))),Ae(i,_s);default:throw Error(d(397))}}function zr(i,h){switch(h.insertionMode){case 0:case 1:case 3:case 2:return Ae(i,Sl);case 4:return Ae(i,rt);case 5:return Ae(i,sl);case 6:return Ae(i,Bs);case 7:return Ae(i,In);case 8:return Ae(i,Ps);case 9:return Ae(i,Uo);default:throw Error(d(397))}}var Sc=ie('$RS=function(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("'),Tc=ie('$RS("'),Ac=ie('","'),ma=ie('")<\/script>');ie('<template data-rsi="" data-sid="'),ie('" data-pid="');var ba=ie(`$RB=[];$RV=function(a){$RT=performance.now();for(var b=0;b<a.length;b+=2){var c=a[b],e=a[b+1];null!==e.parentNode&&e.parentNode.removeChild(e);var f=c.parentNode;if(f){var g=c.previousSibling,h=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d||"/&"===d)if(0===h)break;else h--;else"$"!==d&&"$?"!==d&&"$~"!==d&&"$!"!==d&&"&"!==d||h++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;e.firstChild;)f.insertBefore(e.firstChild,c);g.data="$";g._reactRetry&&requestAnimationFrame(g._reactRetry)}}a.length=0};
49
+ $RC=function(a,b){if(b=document.getElementById(b))(a=document.getElementById(a))?(a.previousSibling.data="$~",$RB.push(a,b),2===$RB.length&&("number"!==typeof $RT?requestAnimationFrame($RV.bind(null,$RB)):(a=performance.now(),setTimeout($RV.bind(null,$RB),2300>a&&2E3<a?2300-a:$RT+300-a)))):b.parentNode.removeChild(b)};`);Ie(`$RV=function(A,g){function k(a,b){var e=a.getAttribute(b);e&&(b=a.style,l.push(a,b.viewTransitionName,b.viewTransitionClass),"auto"!==e&&(b.viewTransitionClass=e),(a=a.getAttribute("vt-name"))||(a="_T_"+K++ +"_"),b.viewTransitionName=a,B=!0)}var B=!1,K=0,l=[];try{var f=document.__reactViewTransition;if(f){f.finished.finally($RV.bind(null,g));return}var m=new Map;for(f=1;f<g.length;f+=2)for(var h=g[f].querySelectorAll("[vt-share]"),d=0;d<h.length;d++){var c=h[d];m.set(c.getAttribute("vt-name"),c)}var u=[];for(h=0;h<g.length;h+=2){var C=g[h],x=C.parentNode;if(x){var v=x.getBoundingClientRect();if(v.left||v.top||v.width||v.height){c=C;for(f=0;c;){if(8===c.nodeType){var r=c.data;if("/$"===r)if(0===f)break;else f--;else"$"!==r&&"$?"!==r&&"$~"!==r&&"$!"!==r||f++}else if(1===c.nodeType){d=c;var D=d.getAttribute("vt-name"),y=m.get(D);k(d,y?"vt-share":"vt-exit");y&&(k(y,"vt-share"),m.set(D,null));var E=d.querySelectorAll("[vt-share]");for(d=0;d<E.length;d++){var F=E[d],G=F.getAttribute("vt-name"),
50
+ H=m.get(G);H&&(k(F,"vt-share"),k(H,"vt-share"),m.set(G,null))}}c=c.nextSibling}for(var I=g[h+1],t=I.firstElementChild;t;)null!==m.get(t.getAttribute("vt-name"))&&k(t,"vt-enter"),t=t.nextElementSibling;c=x;do for(var n=c.firstElementChild;n;){var J=n.getAttribute("vt-update");J&&"none"!==J&&!l.includes(n)&&k(n,"vt-update");n=n.nextElementSibling}while((c=c.parentNode)&&1===c.nodeType&&"none"!==c.getAttribute("vt-update"));u.push.apply(u,I.querySelectorAll('img[src]:not([loading="lazy"])'))}}}if(B){var z=
51
+ document.__reactViewTransition=document.startViewTransition({update:function(){A(g);for(var a=[document.documentElement.clientHeight,document.fonts.ready],b={},e=0;e<u.length;b={g:b.g},e++)if(b.g=u[e],!b.g.complete){var p=b.g.getBoundingClientRect();0<p.bottom&&0<p.right&&p.top<window.innerHeight&&p.left<window.innerWidth&&(p=new Promise(function(w){return function(q){w.g.addEventListener("load",q);w.g.addEventListener("error",q)}}(b)),a.push(p))}return Promise.race([Promise.all(a),new Promise(function(w){var q=
52
+ performance.now();setTimeout(w,2300>q&&2E3<q?2300-q:500)})])},types:[]});z.ready.finally(function(){for(var a=l.length-3;0<=a;a-=3){var b=l[a],e=b.style;e.viewTransitionName=l[a+1];e.viewTransitionClass=l[a+1];""===b.getAttribute("style")&&b.removeAttribute("style")}});z.finished.finally(function(){document.__reactViewTransition===z&&(document.__reactViewTransition=null)});$RB=[];return}}catch(a){}A(g)}.bind(null,$RV);`);var ya=ie('$RC("'),Vn=ie(`$RM=new Map;$RR=function(n,w,p){function u(q){this._p=null;q()}for(var r=new Map,t=document,h,b,e=t.querySelectorAll("link[data-precedence],style[data-precedence]"),v=[],k=0;b=e[k++];)"not all"===b.getAttribute("media")?v.push(b):("LINK"===b.tagName&&$RM.set(b.getAttribute("href"),b),r.set(b.dataset.precedence,h=b));e=0;b=[];var l,a;for(k=!0;;){if(k){var f=p[e++];if(!f){k=!1;e=0;continue}var c=!1,m=0;var d=f[m++];if(a=$RM.get(d)){var g=a._p;c=!0}else{a=t.createElement("link");a.href=d;a.rel=
53
+ "stylesheet";for(a.dataset.precedence=l=f[m++];g=f[m++];)a.setAttribute(g,f[m++]);g=a._p=new Promise(function(q,x){a.onload=u.bind(a,q);a.onerror=u.bind(a,x)});$RM.set(d,a)}d=a.getAttribute("media");!g||d&&!matchMedia(d).matches||b.push(g);if(c)continue}else{a=v[e++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=r.get(l)||h;c===h&&(h=a);r.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=t.head,c.insertBefore(a,c.firstChild))}if(p=document.getElementById(n))p.previousSibling.data=
54
+ "$~";Promise.all(b).then($RC.bind(null,n,w),$RX.bind(null,n,"CSS failed to load"))};$RR("`),ou=ie('$RR("'),es=ie('","'),ni=ie('",'),ji=ie('"'),Pl=ie(")<\/script>");ie('<template data-rci="" data-bid="'),ie('<template data-rri="" data-bid="'),ie('" data-sid="'),ie('" data-sty="');var ts=ie('$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};'),va=ie('$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};;$RX("'),Wr=ie('$RX("'),ns=ie('"'),os=ie(","),Ic=ie(")<\/script>");ie('<template data-rxi="" data-bid="'),ie('" data-dgst="'),ie('" data-msg="'),ie('" data-stck="'),ie('" data-cstck="');var vu=/[<\u2028\u2029]/g;function Ls(i){return JSON.stringify(i).replace(vu,function(h){switch(h){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}var Bn=/[&><\u2028\u2029]/g;function il(i){return JSON.stringify(i).replace(Bn,function(h){switch(h){case"&":return"\\u0026";case">":return"\\u003e";case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSObjectForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}var oi=ie(' media="not all" data-precedence="'),ri=ie('" data-href="'),Hi=ie('">'),ur=ie("</style>"),dr=!1,Jo=!0;function hr(i){var h=i.rules,m=i.hrefs,C=0;if(m.length){for(ue(this,Dr.startInlineStyle),ue(this,oi),ue(this,i.precedence),ue(this,ri);C<m.length-1;C++)ue(this,m[C]),ue(this,li);for(ue(this,m[C]),ue(this,Hi),C=0;C<h.length;C++)ue(this,h[C]);Jo=Ae(this,ur),dr=!0,h.length=0,m.length=0}}function Ut(i){return i.state!==2?dr=!0:!1}function fr(i,h,m){return dr=!1,Jo=!0,Dr=m,h.styles.forEach(hr,i),Dr=null,h.stylesheets.forEach(Ut),dr&&(m.stylesToHoist=!0),Jo}function $t(i){for(var h=0;h<i.length;h++)ue(this,i[h]);i.length=0}var Gr=[];function Ui(i){qt(Gr,i.props);for(var h=0;h<Gr.length;h++)ue(this,Gr[h]);Gr.length=0,i.state=2}var zi=ie(' data-precedence="'),Wi=ie('" data-href="'),li=ie(" "),_l=ie('">'),si=ie("</style>");function ai(i){var h=0<i.sheets.size;i.sheets.forEach(Ui,this),i.sheets.clear();var m=i.rules,C=i.hrefs;if(!h||C.length){if(ue(this,Dr.startInlineStyle),ue(this,zi),ue(this,i.precedence),i=0,C.length){for(ue(this,Wi);i<C.length-1;i++)ue(this,C[i]),ue(this,li);ue(this,C[i])}for(ue(this,_l),i=0;i<m.length;i++)ue(this,m[i]);ue(this,si),m.length=0,C.length=0}}function zo(i){if(i.state===0){i.state=1;var h=i.props;for(qt(Gr,{rel:"preload",as:"style",href:i.props.href,crossOrigin:h.crossOrigin,fetchPriority:h.fetchPriority,integrity:h.integrity,media:h.media,hrefLang:h.hrefLang,referrerPolicy:h.referrerPolicy}),i=0;i<Gr.length;i++)ue(this,Gr[i]);Gr.length=0}}function en(i){i.sheets.forEach(zo,this),i.sheets.clear()}ie('<link rel="expect" href="#'),ie('" blocking="render"/>');var wt=ie(' id="');function rs(i,h){!(h.instructions&32)&&(h.instructions|=32,i.push(wt,Ie(et("_"+h.idPrefix+"R_")),Ht))}var Fs=ie("["),Ms=ie(",["),ls=ie(","),Bc=ie("]");function Qn(i,h){ue(i,Fs);var m=Fs;h.stylesheets.forEach(function(C){if(C.state!==2)if(C.state===3)ue(i,m),ue(i,Ie(il(""+C.props.href))),ue(i,Bc),m=Ms;else{ue(i,m);var P=C.props["data-precedence"],H=C.props,W=Es(""+C.props.href);ue(i,Ie(il(W))),P=""+P,ue(i,ls),ue(i,Ie(il(P)));for(var ne in H)if(vt.call(H,ne)&&(P=H[ne],P!=null))switch(ne){case"href":case"rel":case"precedence":case"data-precedence":break;case"children":case"dangerouslySetInnerHTML":throw Error(d(399,"link"));default:Ru(i,ne,P)}ue(i,Bc),m=Ms,C.state=3}}),ue(i,Bc)}function Ru(i,h,m){var C=h.toLowerCase();switch(typeof m){case"function":case"symbol":return}switch(h){case"innerHTML":case"dangerouslySetInnerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"style":case"ref":return;case"className":C="class",h=""+m;break;case"hidden":if(m===!1)return;h="";break;case"src":case"href":m=Es(m),h=""+m;break;default:if(2<h.length&&(h[0]==="o"||h[0]==="O")&&(h[1]==="n"||h[1]==="N")||!$r(h))return;h=""+m}ue(i,ls),ue(i,Ie(il(C))),ue(i,ls),ue(i,Ie(il(h)))}function Vr(){return{styles:new Set,stylesheets:new Set,suspenseyImages:!1}}function ru(i){var h=ut||null;if(h){var m=h.resumableState,C=h.renderState;if(typeof i=="string"&&i){if(!m.dnsResources.hasOwnProperty(i)){m.dnsResources[i]=null,m=C.headers;var P,H;(H=m&&0<m.remainingCapacity)&&(H=(P="<"+(""+i).replace(Os,lo)+">; rel=dns-prefetch",0<=(m.remainingCapacity-=P.length+2))),H?(C.resets.dns[i]=null,m.preconnects&&(m.preconnects+=", "),m.preconnects+=P):(P=[],qt(P,{href:i,rel:"dns-prefetch"}),C.preconnects.add(P))}ps(h)}}else Mr.D(i)}function Pc(i,h){var m=ut||null;if(m){var C=m.resumableState,P=m.renderState;if(typeof i=="string"&&i){var H=h==="use-credentials"?"credentials":typeof h=="string"?"anonymous":"default";if(!C.connectResources[H].hasOwnProperty(i)){C.connectResources[H][i]=null,C=P.headers;var W,ne;if(ne=C&&0<C.remainingCapacity){if(ne="<"+(""+i).replace(Os,lo)+">; rel=preconnect",typeof h=="string"){var X=(""+h).replace(qn,ss);ne+='; crossorigin="'+X+'"'}ne=(W=ne,0<=(C.remainingCapacity-=W.length+2))}ne?(P.resets.connect[H][i]=null,C.preconnects&&(C.preconnects+=", "),C.preconnects+=W):(H=[],qt(H,{rel:"preconnect",href:i,crossOrigin:h}),P.preconnects.add(H))}ps(m)}}else Mr.C(i,h)}function cl(i,h,m){var C=ut||null;if(C){var P=C.resumableState,H=C.renderState;if(h&&i){switch(h){case"image":if(m)var W=m.imageSrcSet,ne=m.imageSizes,X=m.fetchPriority;var oe=W?W+`
55
+ `+(ne||""):i;if(P.imageResources.hasOwnProperty(oe))return;P.imageResources[oe]=On,P=H.headers;var fe;P&&0<P.remainingCapacity&&typeof W!="string"&&X==="high"&&(fe=Gi(i,h,m),0<=(P.remainingCapacity-=fe.length+2))?(H.resets.image[oe]=On,P.highImagePreloads&&(P.highImagePreloads+=", "),P.highImagePreloads+=fe):(P=[],qt(P,go({rel:"preload",href:W?void 0:i,as:h},m)),X==="high"?H.highImagePreloads.add(P):(H.bulkPreloads.add(P),H.preloads.images.set(oe,P)));break;case"style":if(P.styleResources.hasOwnProperty(i))return;W=[],qt(W,go({rel:"preload",href:i,as:h},m)),P.styleResources[i]=!m||typeof m.crossOrigin!="string"&&typeof m.integrity!="string"?On:[m.crossOrigin,m.integrity],H.preloads.stylesheets.set(i,W),H.bulkPreloads.add(W);break;case"script":if(P.scriptResources.hasOwnProperty(i))return;W=[],H.preloads.scripts.set(i,W),H.bulkPreloads.add(W),qt(W,go({rel:"preload",href:i,as:h},m)),P.scriptResources[i]=!m||typeof m.crossOrigin!="string"&&typeof m.integrity!="string"?On:[m.crossOrigin,m.integrity];break;default:if(P.unknownResources.hasOwnProperty(h)){if(W=P.unknownResources[h],W.hasOwnProperty(i))return}else W={},P.unknownResources[h]=W;if(W[i]=On,(P=H.headers)&&0<P.remainingCapacity&&h==="font"&&(oe=Gi(i,h,m),0<=(P.remainingCapacity-=oe.length+2)))H.resets.font[i]=On,P.fontPreloads&&(P.fontPreloads+=", "),P.fontPreloads+=oe;else switch(P=[],i=go({rel:"preload",href:i,as:h},m),qt(P,i),h){case"font":H.fontPreloads.add(P);break;default:H.bulkPreloads.add(P)}}ps(C)}}else Mr.L(i,h,m)}function ii(i,h){var m=ut||null;if(m){var C=m.resumableState,P=m.renderState;if(i){var H=h&&typeof h.as=="string"?h.as:"script";switch(H){case"script":if(C.moduleScriptResources.hasOwnProperty(i))return;H=[],C.moduleScriptResources[i]=!h||typeof h.crossOrigin!="string"&&typeof h.integrity!="string"?On:[h.crossOrigin,h.integrity],P.preloads.moduleScripts.set(i,H);break;default:if(C.moduleUnknownResources.hasOwnProperty(H)){var W=C.unknownResources[H];if(W.hasOwnProperty(i))return}else W={},C.moduleUnknownResources[H]=W;H=[],W[i]=On}qt(H,go({rel:"modulepreload",href:i},h)),P.bulkPreloads.add(H),ps(m)}}else Mr.m(i,h)}function ro(i,h,m){var C=ut||null;if(C){var P=C.resumableState,H=C.renderState;if(i){h=h||"default";var W=H.styles.get(h),ne=P.styleResources.hasOwnProperty(i)?P.styleResources[i]:void 0;ne!==null&&(P.styleResources[i]=null,W||(W={precedence:Ie(et(h)),rules:[],hrefs:[],sheets:new Map},H.styles.set(h,W)),h={state:0,props:go({rel:"stylesheet",href:i,"data-precedence":h},m)},ne&&(ne.length===2&&Ds(h.props,ne),(H=H.preloads.stylesheets.get(i))&&0<H.length?H.length=0:h.state=1),W.sheets.set(i,h),ps(C))}}else Mr.S(i,h,m)}function Nl(i,h){var m=ut||null;if(m){var C=m.resumableState,P=m.renderState;if(i){var H=C.scriptResources.hasOwnProperty(i)?C.scriptResources[i]:void 0;H!==null&&(C.scriptResources[i]=null,h=go({src:i,async:!0},h),H&&(H.length===2&&Ds(h,H),i=P.preloads.scripts.get(i))&&(i.length=0),i=[],P.scripts.add(i),ha(i,h),ps(m))}}else Mr.X(i,h)}function lu(i,h){var m=ut||null;if(m){var C=m.resumableState,P=m.renderState;if(i){var H=C.moduleScriptResources.hasOwnProperty(i)?C.moduleScriptResources[i]:void 0;H!==null&&(C.moduleScriptResources[i]=null,h=go({src:i,type:"module",async:!0},h),H&&(H.length===2&&Ds(h,H),i=P.preloads.moduleScripts.get(i))&&(i.length=0),i=[],P.scripts.add(i),ha(i,h),ps(m))}}else Mr.M(i,h)}function Ds(i,h){i.crossOrigin==null&&(i.crossOrigin=h[0]),i.integrity==null&&(i.integrity=h[1])}function Gi(i,h,m){i=(""+i).replace(Os,lo),h=(""+h).replace(qn,ss),h="<"+i+'>; rel=preload; as="'+h+'"';for(var C in m)vt.call(m,C)&&(i=m[C],typeof i=="string"&&(h+="; "+C.toLowerCase()+'="'+(""+i).replace(qn,ss)+'"'));return h}var Os=/[<>\r\n]/g;function lo(i){switch(i){case"<":return"%3C";case">":return"%3E";case`
56
+ `:return"%0A";case"\r":return"%0D";default:throw Error("escapeLinkHrefForHeaderContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}var qn=/["';,\r\n]/g;function ss(i){switch(i){case'"':return"%22";case"'":return"%27";case";":return"%3B";case",":return"%2C";case`
57
+ `:return"%0A";case"\r":return"%0D";default:throw Error("escapeStringForLinkHeaderQuotedParamValueContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}function Zt(i){this.styles.add(i)}function Mt(i){this.stylesheets.add(i)}function js(i,h){h.styles.forEach(Zt,i),h.stylesheets.forEach(Mt,i),h.suspenseyImages&&(i.suspenseyImages=!0)}function Ra(i){return 0<i.stylesheets.size||i.suspenseyImages}var Vi=Function.prototype.bind,Ea=Symbol.for("react.client.reference");function _c(i){if(i==null)return null;if(typeof i=="function")return i.$$typeof===Ea?null:i.displayName||i.name||null;if(typeof i=="string")return i;switch(i){case y:return"Fragment";case S:return"Profiler";case R:return"StrictMode";case T:return"Suspense";case O:return"SuspenseList";case K:return"Activity"}if(typeof i=="object")switch(i.$$typeof){case b:return"Portal";case A:return i.displayName||"Context";case _:return(i._context.displayName||"Context")+".Consumer";case L:var h=i.render;return i=i.displayName,i||(i=h.displayName||h.name||"",i=i!==""?"ForwardRef("+i+")":"ForwardRef"),i;case U:return h=i.displayName||null,h!==null?h:_c(i.type)||"Memo";case M:h=i._payload,i=i._init;try{return _c(i(h))}catch{}}return null}var Eu={},an=null;function Ll(i,h){if(i!==h){i.context._currentValue=i.parentValue,i=i.parent;var m=h.parent;if(i===null){if(m!==null)throw Error(d(401))}else{if(m===null)throw Error(d(401));Ll(i,m)}h.context._currentValue=h.value}}function su(i){i.context._currentValue=i.parentValue,i=i.parent,i!==null&&su(i)}function u(i){var h=i.parent;h!==null&&u(h),i.context._currentValue=i.value}function f(i,h){if(i.context._currentValue=i.parentValue,i=i.parent,i===null)throw Error(d(402));i.depth===h.depth?Ll(i,h):f(i,h)}function v(i,h){var m=h.parent;if(m===null)throw Error(d(402));i.depth===m.depth?Ll(i,m):v(i,m),h.context._currentValue=h.value}function w(i){var h=an;h!==i&&(h===null?u(i):i===null?su(h):h.depth===i.depth?Ll(h,i):h.depth>i.depth?f(h,i):v(h,i),an=i)}var N={enqueueSetState:function(i,h){i=i._reactInternals,i.queue!==null&&i.queue.push(h)},enqueueReplaceState:function(i,h){i=i._reactInternals,i.replace=!0,i.queue=[h]},enqueueForceUpdate:function(){}},z={id:1,overflow:""};function V(i,h,m){var C=i.id;i=i.overflow;var P=32-ge(C)-1;C&=~(1<<P),m+=1;var H=32-ge(h)+P;if(30<H){var W=P-P%5;return H=(C&(1<<W)-1).toString(32),C>>=W,P-=W,{id:1<<32-ge(h)+P|m<<P|C,overflow:H+i}}return{id:1<<H|m<<P|C,overflow:i}}var ge=Math.clz32?Math.clz32:we,J=Math.log,ce=Math.LN2;function we(i){return i>>>=0,i===0?32:31-(J(i)/ce|0)|0}function ve(){}var Le=Error(d(460));function Ge(i,h,m){switch(m=i[m],m===void 0?i.push(h):m!==h&&(h.then(ve,ve),h=m),h.status){case"fulfilled":return h.value;case"rejected":throw h.reason;default:switch(typeof h.status=="string"?h.then(ve,ve):(i=h,i.status="pending",i.then(function(C){if(h.status==="pending"){var P=h;P.status="fulfilled",P.value=C}},function(C){if(h.status==="pending"){var P=h;P.status="rejected",P.reason=C}})),h.status){case"fulfilled":return h.value;case"rejected":throw h.reason}throw at=h,Le}}var at=null;function Qe(){if(at===null)throw Error(d(459));var i=at;return at=null,i}function Xe(i,h){return i===h&&(i!==0||1/i===1/h)||i!==i&&h!==h}var tt=typeof Object.is=="function"?Object.is:Xe,Je=null,tn=null,ct=null,mt=null,Bt=null,lt=null,un=!1,Ct=!1,bo=0,Nt=0,yt=-1,St=0,nt=null,Tt=null,Yn=0;function dt(){if(Je===null)throw Error(d(321));return Je}function as(){if(0<Yn)throw Error(d(312));return{memoizedState:null,queue:null,next:null}}function Fl(){return lt===null?Bt===null?(un=!1,Bt=lt=as()):(un=!0,lt=Bt):lt.next===null?(un=!1,lt=lt.next=as()):(un=!0,lt=lt.next),lt}function yo(){var i=nt;return nt=null,i}function vr(){mt=ct=tn=Je=null,Ct=!1,Bt=null,Yn=0,lt=Tt=null}function Rr(i,h){return typeof h=="function"?h(i):h}function Er(i,h,m){if(Je=dt(),lt=Fl(),un){var C=lt.queue;if(h=C.dispatch,Tt!==null&&(m=Tt.get(C),m!==void 0)){Tt.delete(C),C=lt.memoizedState;do C=i(C,m.action),m=m.next;while(m!==null);return lt.memoizedState=C,[C,h]}return[lt.memoizedState,h]}return i=i===Rr?typeof h=="function"?h():h:m!==void 0?m(h):h,lt.memoizedState=i,i=lt.queue={last:null,dispatch:null},i=i.dispatch=Ml.bind(null,Je,i),[lt.memoizedState,i]}function ul(i,h){if(Je=dt(),lt=Fl(),h=h===void 0?null:h,lt!==null){var m=lt.memoizedState;if(m!==null&&h!==null){var C=m[1];e:if(C===null)C=!1;else{for(var P=0;P<C.length&&P<h.length;P++)if(!tt(h[P],C[P])){C=!1;break e}C=!0}if(C)return m[0]}}return i=i(),lt.memoizedState=[i,h],i}function Ml(i,h,m){if(25<=Yn)throw Error(d(301));if(i===Je)if(Ct=!0,i={action:m,next:null},Tt===null&&(Tt=new Map),m=Tt.get(h),m===void 0)Tt.set(h,i);else{for(h=m;h.next!==null;)h=h.next;h.next=i}}function Un(){throw Error(d(440))}function Hs(){throw Error(d(394))}function Us(){throw Error(d(479))}function ci(i,h,m){dt();var C=Nt++,P=ct;if(typeof i.$$FORM_ACTION=="function"){var H=null,W=mt;P=P.formState;var ne=i.$$IS_SIGNATURE_EQUAL;if(P!==null&&typeof ne=="function"){var X=P[1];ne.call(i,P[2],P[3])&&(H=m!==void 0?"p"+m:"k"+q(JSON.stringify([W,null,C]),0),X===H&&(yt=C,h=P[0]))}var oe=i.bind(null,h);return i=function(me){oe(me)},typeof oe.$$FORM_ACTION=="function"&&(i.$$FORM_ACTION=function(me){me=oe.$$FORM_ACTION(me),m!==void 0&&(m+="",me.action=m);var De=me.data;return De&&(H===null&&(H=m!==void 0?"p"+m:"k"+q(JSON.stringify([W,null,C]),0)),De.append("$ACTION_KEY",H)),me}),[h,i,!1]}var fe=i.bind(null,h);return[h,function(me){fe(me)},!1]}function Yi(i){var h=St;return St+=1,nt===null&&(nt=[]),Ge(nt,i,h)}function ka(){throw Error(d(393))}var is={readContext:function(i){return i._currentValue},use:function(i){if(i!==null&&typeof i=="object"){if(typeof i.then=="function")return Yi(i);if(i.$$typeof===A)return i._currentValue}throw Error(d(438,String(i)))},useContext:function(i){return dt(),i._currentValue},useMemo:ul,useReducer:Er,useRef:function(i){Je=dt(),lt=Fl();var h=lt.memoizedState;return h===null?(i={current:i},lt.memoizedState=i):h},useState:function(i){return Er(Rr,i)},useInsertionEffect:ve,useLayoutEffect:ve,useCallback:function(i,h){return ul(function(){return i},h)},useImperativeHandle:ve,useEffect:ve,useDebugValue:ve,useDeferredValue:function(i,h){return dt(),h!==void 0?h:i},useTransition:function(){return dt(),[!1,Hs]},useId:function(){var i=tn.treeContext,h=i.overflow;i=i.id,i=(i&~(1<<32-ge(i)-1)).toString(32)+h;var m=vo;if(m===null)throw Error(d(404));return h=bo++,i="_"+m.idPrefix+"R_"+i,0<h&&(i+="H"+h.toString(32)),i+"_"},useSyncExternalStore:function(i,h,m){if(m===void 0)throw Error(d(407));return m()},useOptimistic:function(i){return dt(),[i,Us]},useActionState:ci,useFormState:ci,useHostTransitionStatus:function(){return dt(),Do},useMemoCache:function(i){for(var h=Array(i),m=0;m<i;m++)h[m]=ee;return h},useCacheRefresh:function(){return ka},useEffectEvent:function(){return Un}},vo=null,ui={getCacheForType:function(){throw Error(d(248))},cacheSignal:function(){throw Error(d(248))}},Ro,gr;function Dl(i){if(Ro===void 0)try{throw Error()}catch(m){var h=m.stack.trim().match(/\n( *(at )?)/);Ro=h&&h[1]||"",gr=-1<m.stack.indexOf(`
58
+ at`)?" (<anonymous>)":-1<m.stack.indexOf("@")?"@unknown:0:0":""}return`
59
+ `+Ro+i+gr}var di=!1;function Ol(i,h){if(!i||di)return"";di=!0;var m=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var C={DetermineComponentFrameRoot:function(){try{if(h){var me=function(){throw Error()};if(Object.defineProperty(me.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(me,[])}catch(Me){var De=Me}Reflect.construct(i,[],me)}else{try{me.call()}catch(Me){De=Me}i.call(me.prototype)}}else{try{throw Error()}catch(Me){De=Me}(me=i())&&typeof me.catch=="function"&&me.catch(function(){})}}catch(Me){if(Me&&De&&typeof Me.stack=="string")return[Me.stack,De.stack]}return[null,null]}};C.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var P=Object.getOwnPropertyDescriptor(C.DetermineComponentFrameRoot,"name");P&&P.configurable&&Object.defineProperty(C.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var H=C.DetermineComponentFrameRoot(),W=H[0],ne=H[1];if(W&&ne){var X=W.split(`
60
+ `),oe=ne.split(`
61
+ `);for(P=C=0;C<X.length&&!X[C].includes("DetermineComponentFrameRoot");)C++;for(;P<oe.length&&!oe[P].includes("DetermineComponentFrameRoot");)P++;if(C===X.length||P===oe.length)for(C=X.length-1,P=oe.length-1;1<=C&&0<=P&&X[C]!==oe[P];)P--;for(;1<=C&&0<=P;C--,P--)if(X[C]!==oe[P]){if(C!==1||P!==1)do if(C--,P--,0>P||X[C]!==oe[P]){var fe=`
62
+ `+X[C].replace(" at new "," at ");return i.displayName&&fe.includes("<anonymous>")&&(fe=fe.replace("<anonymous>",i.displayName)),fe}while(1<=C&&0<=P);break}}}finally{di=!1,Error.prepareStackTrace=m}return(m=i?i.displayName||i.name:"")?Dl(m):""}function Xi(i){if(typeof i=="string")return Dl(i);if(typeof i=="function")return i.prototype&&i.prototype.isReactComponent?Ol(i,!0):Ol(i,!1);if(typeof i=="object"&&i!==null){switch(i.$$typeof){case L:return Ol(i.render,!1);case U:return Ol(i.type,!1);case M:var h=i,m=h._payload;h=h._init;try{i=h(m)}catch{return Dl("Lazy")}return Xi(i)}if(typeof i.name=="string"){e:{m=i.name,h=i.env;var C=i.debugLocation;if(C!=null&&(i=Error.prepareStackTrace,Error.prepareStackTrace=void 0,C=C.stack,Error.prepareStackTrace=i,C.startsWith(`Error: react-stack-top-frame
63
+ `)&&(C=C.slice(29)),i=C.indexOf(`
64
+ `),i!==-1&&(C=C.slice(i+1)),i=C.indexOf("react_stack_bottom_frame"),i!==-1&&(i=C.lastIndexOf(`
65
+ `,i)),i=i!==-1?C=C.slice(0,i):"",C=i.lastIndexOf(`
66
+ `),i=C===-1?i:i.slice(C+1),i.indexOf(m)!==-1)){m=`
67
+ `+i;break e}m=Dl(m+(h?" ["+h+"]":""))}return m}}switch(i){case O:return Dl("SuspenseList");case T:return Dl("Suspense")}return""}function Pn(i,h){return(500<h.byteSize||Ra(h.contentState))&&h.contentPreamble===null}function hi(i){if(typeof i=="object"&&i!==null&&typeof i.environmentName=="string"){var h=i.environmentName;i=[i].slice(0),typeof i[0]=="string"?i.splice(0,1,"%c%s%c "+i[0],"background: #e6e6e6;background: light-dark(rgba(0,0,0,0.1), rgba(255,255,255,0.25));color: #000000;color: light-dark(#000000, #ffffff);border-radius: 2px"," "+h+" ",""):i.splice(0,0,"%c%s%c","background: #e6e6e6;background: light-dark(rgba(0,0,0,0.1), rgba(255,255,255,0.25));color: #000000;color: light-dark(#000000, #ffffff);border-radius: 2px"," "+h+" ",""),i.unshift(console),h=Vi.apply(console.error,i),h()}else console.error(i);return null}function cs(i,h,m,C,P,H,W,ne,X,oe,fe){var me=new Set;this.destination=null,this.flushScheduled=!1,this.resumableState=i,this.renderState=h,this.rootFormatContext=m,this.progressiveChunkSize=C===void 0?12800:C,this.status=10,this.fatalError=null,this.pendingRootTasks=this.allPendingTasks=this.nextSegmentId=0,this.completedPreambleSegments=this.completedRootSegment=null,this.byteSize=0,this.abortableTasks=me,this.pingedTasks=[],this.clientRenderedBoundaries=[],this.completedBoundaries=[],this.partialBoundaries=[],this.trackedPostpones=null,this.onError=P===void 0?hi:P,this.onPostpone=oe===void 0?ve:oe,this.onAllReady=H===void 0?ve:H,this.onShellReady=W===void 0?ve:W,this.onShellError=ne===void 0?ve:ne,this.onFatalError=X===void 0?ve:X,this.formState=fe===void 0?null:fe}function wa(i,h,m,C,P,H,W,ne,X,oe,fe,me){return h=new cs(h,m,C,P,H,W,ne,X,oe,fe,me),m=Wo(h,0,null,C,!1,!1),m.parentFlushed=!0,i=us(h,null,i,-1,null,m,null,null,h.abortableTasks,null,C,null,z,null,null),ds(i),h.pingedTasks.push(i),h}function zs(i,h,m,C,P,H,W,ne,X,oe,fe){return i=wa(i,h,m,C,P,H,W,ne,X,oe,fe,void 0),i.trackedPostpones={workingMap:new Map,rootNodes:[],rootSlots:null},i}function Rn(i,h,m,C,P,H,W,ne,X){return m=new cs(h.resumableState,m,h.rootFormatContext,h.progressiveChunkSize,C,P,H,W,ne,X,null),m.nextSegmentId=h.nextSegmentId,typeof h.replaySlots=="number"?(C=Wo(m,0,null,h.rootFormatContext,!1,!1),C.parentFlushed=!0,i=us(m,null,i,-1,null,C,null,null,m.abortableTasks,null,h.rootFormatContext,null,z,null,null),ds(i),m.pingedTasks.push(i),m):(i=dn(m,null,{nodes:h.replayNodes,slots:h.replaySlots,pendingTasks:0},i,-1,null,null,m.abortableTasks,null,h.rootFormatContext,null,z,null,null),ds(i),m.pingedTasks.push(i),m)}function pr(i,h,m,C,P,H,W,ne,X){return i=Rn(i,h,m,C,P,H,W,ne,X),i.trackedPostpones={workingMap:new Map,rootNodes:[],rootSlots:null},i}var ut=null;function jl(i,h){i.pingedTasks.push(h),i.pingedTasks.length===1&&(i.flushScheduled=i.destination!==null,i.trackedPostpones!==null||i.status===10?ze(function(){return au(i)}):xe(function(){return au(i)}))}function Ca(i,h,m,C,P){return m={status:0,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,row:h,completedSegments:[],byteSize:0,fallbackAbortableTasks:m,errorDigest:null,contentState:Vr(),fallbackState:Vr(),contentPreamble:C,fallbackPreamble:P,trackedContentKeyPath:null,trackedFallbackNode:null},h!==null&&(h.pendingTasks++,C=h.boundaries,C!==null&&(i.allPendingTasks++,m.pendingTasks++,C.push(m)),i=h.inheritedHoistables,i!==null&&js(m.contentState,i)),m}function us(i,h,m,C,P,H,W,ne,X,oe,fe,me,De,Me,pt){i.allPendingTasks++,P===null?i.pendingRootTasks++:P.pendingTasks++,Me!==null&&Me.pendingTasks++;var qe={replay:null,node:m,childIndex:C,ping:function(){return jl(i,qe)},blockedBoundary:P,blockedSegment:H,blockedPreamble:W,hoistableState:ne,abortSet:X,keyPath:oe,formatContext:fe,context:me,treeContext:De,row:Me,componentStack:pt,thenableState:h};return X.add(qe),qe}function dn(i,h,m,C,P,H,W,ne,X,oe,fe,me,De,Me){i.allPendingTasks++,H===null?i.pendingRootTasks++:H.pendingTasks++,De!==null&&De.pendingTasks++,m.pendingTasks++;var pt={replay:m,node:C,childIndex:P,ping:function(){return jl(i,pt)},blockedBoundary:H,blockedSegment:null,blockedPreamble:null,hoistableState:W,abortSet:ne,keyPath:X,formatContext:oe,context:fe,treeContext:me,row:De,componentStack:Me,thenableState:h};return ne.add(pt),pt}function Wo(i,h,m,C,P,H){return{status:0,parentFlushed:!1,id:-1,index:h,chunks:[],children:[],preambleChildren:[],parentFormatContext:C,boundary:m,lastPushedText:P,textEmbedded:H}}function ds(i){var h=i.node;if(typeof h=="object"&&h!==null)switch(h.$$typeof){case x:i.componentStack={parent:i.componentStack,type:h.type}}}function Ws(i){return i===null?null:{parent:i.parent,type:"Suspense Fallback"}}function kr(i){var h={};return i&&Object.defineProperty(h,"componentStack",{configurable:!0,enumerable:!0,get:function(){try{var m="",C=i;do m+=Xi(C.type),C=C.parent;while(C);var P=m}catch(H){P=`
68
+ Error generating stack: `+H.message+`
69
+ `+H.stack}return Object.defineProperty(h,"componentStack",{value:P}),P}}),h}function so(i,h,m){if(i=i.onError,h=i(h,m),h==null||typeof h=="string")return h}function Sa(i,h){var m=i.onShellError,C=i.onFatalError;m(h),C(h),i.destination!==null?(i.status=14,wn(i.destination,h)):(i.status=13,i.fatalError=h)}function Eo(i,h){Nc(i,h.next,h.hoistables)}function Nc(i,h,m){for(;h!==null;){m!==null&&(js(h.hoistables,m),h.inheritedHoistables=m);var C=h.boundaries;if(C!==null){h.boundaries=null;for(var P=0;P<C.length;P++){var H=C[P];m!==null&&js(H.contentState,m),wr(i,H,null,null)}}if(h.pendingTasks--,0<h.pendingTasks)break;m=h.hoistables,h=h.next}}function Gs(i,h){var m=h.boundaries;if(m!==null&&h.pendingTasks===m.length){for(var C=!0,P=0;P<m.length;P++){var H=m[P];if(H.pendingTasks!==1||H.parentFlushed||Pn(i,H)){C=!1;break}}C&&Nc(i,h,h.hoistables)}}function fi(i){var h={pendingTasks:1,boundaries:null,hoistables:Vr(),inheritedHoistables:null,together:!1,next:null};return i!==null&&0<i.pendingTasks&&(h.pendingTasks++,h.boundaries=[],i.next=h),h}function Zi(i,h,m,C,P){var H=h.keyPath,W=h.treeContext,ne=h.row;h.keyPath=m,m=C.length;var X=null;if(h.replay!==null){var oe=h.replay.slots;if(oe!==null&&typeof oe=="object")for(var fe=0;fe<m;fe++){var me=P!=="backwards"&&P!=="unstable_legacy-backwards"?fe:m-1-fe,De=C[me];h.row=X=fi(X),h.treeContext=V(W,m,me);var Me=oe[me];typeof Me=="number"?(Ys(i,h,Me,De,me),delete oe[me]):_n(i,h,De,me),--X.pendingTasks===0&&Eo(i,X)}else for(oe=0;oe<m;oe++)fe=P!=="backwards"&&P!=="unstable_legacy-backwards"?oe:m-1-oe,me=C[fe],h.row=X=fi(X),h.treeContext=V(W,m,fe),_n(i,h,me,fe),--X.pendingTasks===0&&Eo(i,X)}else if(P!=="backwards"&&P!=="unstable_legacy-backwards")for(P=0;P<m;P++)oe=C[P],h.row=X=fi(X),h.treeContext=V(W,m,P),_n(i,h,oe,P),--X.pendingTasks===0&&Eo(i,X);else{for(P=h.blockedSegment,oe=P.children.length,fe=P.chunks.length,me=m-1;0<=me;me--){De=C[me],h.row=X=fi(X),h.treeContext=V(W,m,me),Me=Wo(i,fe,null,h.formatContext,me===0?P.lastPushedText:!0,!0),P.children.splice(oe,0,Me),h.blockedSegment=Me;try{_n(i,h,De,me),Me.lastPushedText&&Me.textEmbedded&&Me.chunks.push(el),Me.status=1,hs(i,h.blockedBoundary,Me),--X.pendingTasks===0&&Eo(i,X)}catch(pt){throw Me.status=i.status===12?3:4,pt}}h.blockedSegment=P,P.lastPushedText=!1}ne!==null&&X!==null&&0<X.pendingTasks&&(ne.pendingTasks++,X.next=ne),h.treeContext=W,h.row=ne,h.keyPath=H}function Ki(i,h,m,C,P,H){var W=h.thenableState;for(h.thenableState=null,Je={},tn=h,ct=i,mt=m,Nt=bo=0,yt=-1,St=0,nt=W,i=C(P,H);Ct;)Ct=!1,Nt=bo=0,yt=-1,St=0,Yn+=1,lt=null,i=C(P,H);return vr(),i}function dl(i,h,m,C,P,H,W){var ne=!1;if(H!==0&&i.formState!==null){var X=h.blockedSegment;if(X!==null){ne=!0,X=X.chunks;for(var oe=0;oe<H;oe++)oe===W?X.push(Ec):X.push(Fi)}}H=h.keyPath,h.keyPath=m,P?(m=h.treeContext,h.treeContext=V(m,1,0),_n(i,h,C,-1),h.treeContext=m):ne?_n(i,h,C,-1):ko(i,h,C,-1),h.keyPath=H}function Vs(i,h,m,C,P,H){if(typeof C=="function")if(C.prototype&&C.prototype.isReactComponent){var W=P;if("ref"in P){W={};for(var ne in P)ne!=="ref"&&(W[ne]=P[ne])}var X=C.defaultProps;if(X){W===P&&(W=go({},W,P));for(var oe in X)W[oe]===void 0&&(W[oe]=X[oe])}P=W,W=Eu,X=C.contextType,typeof X=="object"&&X!==null&&(W=X._currentValue),W=new C(P,W);var fe=W.state!==void 0?W.state:null;if(W.updater=N,W.props=P,W.state=fe,X={queue:[],replace:!1},W._reactInternals=X,H=C.contextType,W.context=typeof H=="object"&&H!==null?H._currentValue:Eu,H=C.getDerivedStateFromProps,typeof H=="function"&&(H=H(P,fe),fe=H==null?fe:go({},fe,H),W.state=fe),typeof C.getDerivedStateFromProps!="function"&&typeof W.getSnapshotBeforeUpdate!="function"&&(typeof W.UNSAFE_componentWillMount=="function"||typeof W.componentWillMount=="function"))if(C=W.state,typeof W.componentWillMount=="function"&&W.componentWillMount(),typeof W.UNSAFE_componentWillMount=="function"&&W.UNSAFE_componentWillMount(),C!==W.state&&N.enqueueReplaceState(W,W.state,null),X.queue!==null&&0<X.queue.length)if(C=X.queue,H=X.replace,X.queue=null,X.replace=!1,H&&C.length===1)W.state=C[0];else{for(X=H?C[0]:W.state,fe=!0,H=H?1:0;H<C.length;H++)oe=C[H],oe=typeof oe=="function"?oe.call(W,X,P,void 0):oe,oe!=null&&(fe?(fe=!1,X=go({},X,oe)):go(X,oe));W.state=X}else X.queue=null;if(C=W.render(),i.status===12)throw null;P=h.keyPath,h.keyPath=m,ko(i,h,C,-1),h.keyPath=P}else{if(C=Ki(i,h,m,C,P,void 0),i.status===12)throw null;dl(i,h,m,C,bo!==0,Nt,yt)}else if(typeof C=="string")if(W=h.blockedSegment,W===null)W=P.children,X=h.formatContext,fe=h.keyPath,h.formatContext=Cs(X,C,P),h.keyPath=m,_n(i,h,W,-1),h.formatContext=X,h.keyPath=fe;else{if(fe=qa(W.chunks,C,P,i.resumableState,i.renderState,h.blockedPreamble,h.hoistableState,h.formatContext,W.lastPushedText),W.lastPushedText=!1,X=h.formatContext,H=h.keyPath,h.keyPath=m,(h.formatContext=Cs(X,C,P)).insertionMode===3){m=Wo(i,0,null,h.formatContext,!1,!1),W.preambleChildren.push(m),h.blockedSegment=m;try{m.status=6,_n(i,h,fe,-1),m.lastPushedText&&m.textEmbedded&&m.chunks.push(el),m.status=1,hs(i,h.blockedBoundary,m)}finally{h.blockedSegment=W}}else _n(i,h,fe,-1);h.formatContext=X,h.keyPath=H;e:{switch(h=W.chunks,i=i.resumableState,C){case"title":case"style":case"script":case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break e;case"body":if(1>=X.insertionMode){i.hasBody=!0;break e}break;case"html":if(X.insertionMode===0){i.hasHtml=!0;break e}break;case"head":if(1>=X.insertionMode)break e}h.push(rl(C))}W.lastPushedText=!1}else{switch(C){case $:case R:case S:case y:C=h.keyPath,h.keyPath=m,ko(i,h,P.children,-1),h.keyPath=C;return;case K:C=h.blockedSegment,C===null?P.mode!=="hidden"&&(C=h.keyPath,h.keyPath=m,_n(i,h,P.children,-1),h.keyPath=C):P.mode!=="hidden"&&(C.chunks.push(jo),C.lastPushedText=!1,W=h.keyPath,h.keyPath=m,_n(i,h,P.children,-1),h.keyPath=W,C.chunks.push(ti),C.lastPushedText=!1);return;case O:e:{if(C=P.children,P=P.revealOrder,P==="forwards"||P==="backwards"||P==="unstable_legacy-backwards"){if(de(C)){Zi(i,h,m,C,P);break e}if((W=ye(C))&&(W=W.call(C))){if(X=W.next(),!X.done){do X=W.next();while(!X.done);Zi(i,h,m,C,P)}break e}}P==="together"?(P=h.keyPath,W=h.row,X=h.row=fi(null),X.boundaries=[],X.together=!0,h.keyPath=m,ko(i,h,C,-1),--X.pendingTasks===0&&Eo(i,X),h.keyPath=P,h.row=W,W!==null&&0<X.pendingTasks&&(W.pendingTasks++,X.next=W)):(P=h.keyPath,h.keyPath=m,ko(i,h,C,-1),h.keyPath=P)}return;case ae:case D:throw Error(d(343));case T:e:if(h.replay!==null){C=h.keyPath,W=h.formatContext,X=h.row,h.keyPath=m,h.formatContext=yr(i.resumableState,W),h.row=null,m=P.children;try{_n(i,h,m,-1)}finally{h.keyPath=C,h.formatContext=W,h.row=X}}else{C=h.keyPath,H=h.formatContext;var me=h.row;oe=h.blockedBoundary,ne=h.blockedPreamble;var De=h.hoistableState,Me=h.blockedSegment,pt=P.fallback;P=P.children;var qe=new Set,xt=2>h.formatContext.insertionMode?Ca(i,h.row,qe,sn(),sn()):Ca(i,h.row,qe,null,null);i.trackedPostpones!==null&&(xt.trackedContentKeyPath=m);var hn=Wo(i,Me.chunks.length,xt,h.formatContext,!1,!1);Me.children.push(hn),Me.lastPushedText=!1;var Kt=Wo(i,0,null,h.formatContext,!1,!1);if(Kt.parentFlushed=!0,i.trackedPostpones!==null){W=h.componentStack,X=[m[0],"Suspense Fallback",m[2]],fe=[X[1],X[2],[],null],i.trackedPostpones.workingMap.set(X,fe),xt.trackedFallbackNode=fe,h.blockedSegment=hn,h.blockedPreamble=xt.fallbackPreamble,h.keyPath=X,h.formatContext=Rc(i.resumableState,H),h.componentStack=Ws(W),hn.status=6;try{_n(i,h,pt,-1),hn.lastPushedText&&hn.textEmbedded&&hn.chunks.push(el),hn.status=1,hs(i,oe,hn)}catch(ao){throw hn.status=i.status===12?3:4,ao}finally{h.blockedSegment=Me,h.blockedPreamble=ne,h.keyPath=C,h.formatContext=H}h=us(i,null,P,-1,xt,Kt,xt.contentPreamble,xt.contentState,h.abortSet,m,yr(i.resumableState,h.formatContext),h.context,h.treeContext,null,W),ds(h),i.pingedTasks.push(h)}else{h.blockedBoundary=xt,h.blockedPreamble=xt.contentPreamble,h.hoistableState=xt.contentState,h.blockedSegment=Kt,h.keyPath=m,h.formatContext=yr(i.resumableState,H),h.row=null,Kt.status=6;try{if(_n(i,h,P,-1),Kt.lastPushedText&&Kt.textEmbedded&&Kt.chunks.push(el),Kt.status=1,hs(i,xt,Kt),ec(xt,Kt),xt.pendingTasks===0&&xt.status===0){if(xt.status=1,!Pn(i,xt)){me!==null&&--me.pendingTasks===0&&Eo(i,me),i.pendingRootTasks===0&&h.blockedPreamble&&Yr(i);break e}}else me!==null&&me.together&&Gs(i,me)}catch(ao){xt.status=4,i.status===12?(Kt.status=3,W=i.fatalError):(Kt.status=4,W=ao),X=kr(h.componentStack),fe=so(i,W,X),xt.errorDigest=fe,Ji(i,xt)}finally{h.blockedBoundary=oe,h.blockedPreamble=ne,h.hoistableState=De,h.blockedSegment=Me,h.keyPath=C,h.formatContext=H,h.row=me}h=us(i,null,pt,-1,oe,hn,xt.fallbackPreamble,xt.fallbackState,qe,[m[0],"Suspense Fallback",m[2]],Rc(i.resumableState,h.formatContext),h.context,h.treeContext,h.row,Ws(h.componentStack)),ds(h),i.pingedTasks.push(h)}}return}if(typeof C=="object"&&C!==null)switch(C.$$typeof){case L:if("ref"in P)for(Me in W={},P)Me!=="ref"&&(W[Me]=P[Me]);else W=P;C=Ki(i,h,m,C.render,W,H),dl(i,h,m,C,bo!==0,Nt,yt);return;case U:Vs(i,h,m,C.type,P,H);return;case A:if(X=P.children,W=h.keyPath,P=P.value,fe=C._currentValue,C._currentValue=P,H=an,an=C={parent:H,depth:H===null?0:H.depth+1,context:C,parentValue:fe,value:P},h.context=C,h.keyPath=m,ko(i,h,X,-1),i=an,i===null)throw Error(d(403));i.context._currentValue=i.parentValue,i=an=i.parent,h.context=i,h.keyPath=W;return;case _:P=P.children,C=P(C._context._currentValue),P=h.keyPath,h.keyPath=m,ko(i,h,C,-1),h.keyPath=P;return;case M:if(W=C._init,C=W(C._payload),i.status===12)throw null;Vs(i,h,m,C,P,H);return}throw Error(d(130,C==null?C:typeof C,""))}}function Ys(i,h,m,C,P){var H=h.replay,W=h.blockedBoundary,ne=Wo(i,0,null,h.formatContext,!1,!1);ne.id=m,ne.parentFlushed=!0;try{h.replay=null,h.blockedSegment=ne,_n(i,h,C,P),ne.status=1,hs(i,W,ne),W===null?i.completedRootSegment=ne:(ec(W,ne),W.parentFlushed&&i.partialBoundaries.push(W))}finally{h.replay=H,h.blockedSegment=null}}function ko(i,h,m,C){h.replay!==null&&typeof h.replay.slots=="number"?Ys(i,h,h.replay.slots,m,C):(h.node=m,h.childIndex=C,m=h.componentStack,ds(h),gi(i,h),h.componentStack=m)}function gi(i,h){var m=h.node,C=h.childIndex;if(m!==null){if(typeof m=="object"){switch(m.$$typeof){case x:var P=m.type,H=m.key,W=m.props;m=W.ref;var ne=m!==void 0?m:null,X=_c(P),oe=H??(C===-1?0:C);if(H=[h.keyPath,X,oe],h.replay!==null)e:{var fe=h.replay;for(C=fe.nodes,m=0;m<C.length;m++){var me=C[m];if(oe===me[1]){if(me.length===4){if(X!==null&&X!==me[0])throw Error(d(490,me[0],X));var De=me[2];X=me[3],oe=h.node,h.replay={nodes:De,slots:X,pendingTasks:1};try{if(Vs(i,h,H,P,W,ne),h.replay.pendingTasks===1&&0<h.replay.nodes.length)throw Error(d(488));h.replay.pendingTasks--}catch($e){if(typeof $e=="object"&&$e!==null&&($e===Le||typeof $e.then=="function"))throw h.node===oe?h.replay=fe:C.splice(m,1),$e;h.replay.pendingTasks--,W=kr(h.componentStack),H=i,i=h.blockedBoundary,P=$e,W=so(H,P,W),xi(H,i,De,X,P,W)}h.replay=fe}else{if(P!==T)throw Error(d(490,"Suspense",_c(P)||"Unknown"));t:{fe=void 0,P=me[5],ne=me[2],X=me[3],oe=me[4]===null?[]:me[4][2],me=me[4]===null?null:me[4][3];var Me=h.keyPath,pt=h.formatContext,qe=h.row,xt=h.replay,hn=h.blockedBoundary,Kt=h.hoistableState,ao=W.children,Qo=W.fallback,Sr=new Set;W=2>h.formatContext.insertionMode?Ca(i,h.row,Sr,sn(),sn()):Ca(i,h.row,Sr,null,null),W.parentFlushed=!0,W.rootSegmentID=P,h.blockedBoundary=W,h.hoistableState=W.contentState,h.keyPath=H,h.formatContext=yr(i.resumableState,pt),h.row=null,h.replay={nodes:ne,slots:X,pendingTasks:1};try{if(_n(i,h,ao,-1),h.replay.pendingTasks===1&&0<h.replay.nodes.length)throw Error(d(488));if(h.replay.pendingTasks--,W.pendingTasks===0&&W.status===0){W.status=1,i.completedBoundaries.push(W);break t}}catch($e){W.status=4,De=kr(h.componentStack),fe=so(i,$e,De),W.errorDigest=fe,h.replay.pendingTasks--,i.clientRenderedBoundaries.push(W)}finally{h.blockedBoundary=hn,h.hoistableState=Kt,h.replay=xt,h.keyPath=Me,h.formatContext=pt,h.row=qe}De=dn(i,null,{nodes:oe,slots:me,pendingTasks:0},Qo,-1,hn,W.fallbackState,Sr,[H[0],"Suspense Fallback",H[2]],Rc(i.resumableState,h.formatContext),h.context,h.treeContext,h.row,Ws(h.componentStack)),ds(De),i.pingedTasks.push(De)}}C.splice(m,1);break e}}}else Vs(i,h,H,P,W,ne);return;case b:throw Error(d(257));case M:if(De=m._init,m=De(m._payload),i.status===12)throw null;ko(i,h,m,C);return}if(de(m)){pi(i,h,m,C);return}if((De=ye(m))&&(De=De.call(m))){if(m=De.next(),!m.done){W=[];do W.push(m.value),m=De.next();while(!m.done);pi(i,h,W,C)}return}if(typeof m.then=="function")return h.thenableState=null,ko(i,h,Yi(m),C);if(m.$$typeof===A)return ko(i,h,m._currentValue,C);throw C=Object.prototype.toString.call(m),Error(d(31,C==="[object Object]"?"object with keys {"+Object.keys(m).join(", ")+"}":C))}typeof m=="string"?(C=h.blockedSegment,C!==null&&(C.lastPushedText=qc(C.chunks,m,i.renderState,C.lastPushedText))):(typeof m=="number"||typeof m=="bigint")&&(C=h.blockedSegment,C!==null&&(C.lastPushedText=qc(C.chunks,""+m,i.renderState,C.lastPushedText)))}}function pi(i,h,m,C){var P=h.keyPath;if(C!==-1&&(h.keyPath=[h.keyPath,"Fragment",C],h.replay!==null)){for(var H=h.replay,W=H.nodes,ne=0;ne<W.length;ne++){var X=W[ne];if(X[1]===C){C=X[2],X=X[3],h.replay={nodes:C,slots:X,pendingTasks:1};try{if(pi(i,h,m,-1),h.replay.pendingTasks===1&&0<h.replay.nodes.length)throw Error(d(488));h.replay.pendingTasks--}catch(me){if(typeof me=="object"&&me!==null&&(me===Le||typeof me.then=="function"))throw me;h.replay.pendingTasks--,m=kr(h.componentStack);var oe=h.blockedBoundary,fe=me;m=so(i,fe,m),xi(i,oe,C,X,fe,m)}h.replay=H,W.splice(ne,1);break}}h.keyPath=P;return}if(H=h.treeContext,W=m.length,h.replay!==null&&(ne=h.replay.slots,ne!==null&&typeof ne=="object")){for(C=0;C<W;C++)X=m[C],h.treeContext=V(H,W,C),oe=ne[C],typeof oe=="number"?(Ys(i,h,oe,X,C),delete ne[C]):_n(i,h,X,C);h.treeContext=H,h.keyPath=P;return}for(ne=0;ne<W;ne++)C=m[ne],h.treeContext=V(H,W,ne),_n(i,h,C,ne);h.treeContext=H,h.keyPath=P}function Lc(i,h,m){if(m.status=5,m.rootSegmentID=i.nextSegmentId++,i=m.trackedContentKeyPath,i===null)throw Error(d(486));var C=m.trackedFallbackNode,P=[],H=h.workingMap.get(i);return H===void 0?(m=[i[1],i[2],P,null,C,m.rootSegmentID],h.workingMap.set(i,m),jc(m,i[0],h),m):(H[4]=C,H[5]=m.rootSegmentID,H)}function Fc(i,h,m,C){C.status=5;var P=m.keyPath,H=m.blockedBoundary;if(H===null)C.id=i.nextSegmentId++,h.rootSlots=C.id,i.completedRootSegment!==null&&(i.completedRootSegment.status=5);else{if(H!==null&&H.status===0){var W=Lc(i,h,H);if(H.trackedContentKeyPath===P&&m.childIndex===-1){C.id===-1&&(C.id=C.parentFlushed?H.rootSegmentID:i.nextSegmentId++),W[3]=C.id;return}}if(C.id===-1&&(C.id=C.parentFlushed&&H!==null?H.rootSegmentID:i.nextSegmentId++),m.childIndex===-1)P===null?h.rootSlots=C.id:(m=h.workingMap.get(P),m===void 0?(m=[P[1],P[2],[],C.id],jc(m,P[0],h)):m[3]=C.id);else{if(P===null){if(i=h.rootSlots,i===null)i=h.rootSlots={};else if(typeof i=="number")throw Error(d(491))}else if(H=h.workingMap,W=H.get(P),W===void 0)i={},W=[P[1],P[2],[],i],H.set(P,W),jc(W,P[0],h);else if(i=W[3],i===null)i=W[3]={};else if(typeof i=="number")throw Error(d(491));i[m.childIndex]=C.id}}}function Ji(i,h){i=i.trackedPostpones,i!==null&&(h=h.trackedContentKeyPath,h!==null&&(h=i.workingMap.get(h),h!==void 0&&(h.length=4,h[2]=[],h[3]=null)))}function Mc(i,h,m){return dn(i,m,h.replay,h.node,h.childIndex,h.blockedBoundary,h.hoistableState,h.abortSet,h.keyPath,h.formatContext,h.context,h.treeContext,h.row,h.componentStack)}function Dc(i,h,m){var C=h.blockedSegment,P=Wo(i,C.chunks.length,null,h.formatContext,C.lastPushedText,!0);return C.children.push(P),C.lastPushedText=!1,us(i,m,h.node,h.childIndex,h.blockedBoundary,P,h.blockedPreamble,h.hoistableState,h.abortSet,h.keyPath,h.formatContext,h.context,h.treeContext,h.row,h.componentStack)}function _n(i,h,m,C){var P=h.formatContext,H=h.context,W=h.keyPath,ne=h.treeContext,X=h.componentStack,oe=h.blockedSegment;if(oe===null){oe=h.replay;try{return ko(i,h,m,C)}catch(De){if(vr(),m=De===Le?Qe():De,i.status!==12&&typeof m=="object"&&m!==null){if(typeof m.then=="function"){C=De===Le?yo():null,i=Mc(i,h,C).ping,m.then(i,i),h.formatContext=P,h.context=H,h.keyPath=W,h.treeContext=ne,h.componentStack=X,h.replay=oe,w(H);return}if(m.message==="Maximum call stack size exceeded"){m=De===Le?yo():null,m=Mc(i,h,m),i.pingedTasks.push(m),h.formatContext=P,h.context=H,h.keyPath=W,h.treeContext=ne,h.componentStack=X,h.replay=oe,w(H);return}}}}else{var fe=oe.children.length,me=oe.chunks.length;try{return ko(i,h,m,C)}catch(De){if(vr(),oe.children.length=fe,oe.chunks.length=me,m=De===Le?Qe():De,i.status!==12&&typeof m=="object"&&m!==null){if(typeof m.then=="function"){oe=m,m=De===Le?yo():null,i=Dc(i,h,m).ping,oe.then(i,i),h.formatContext=P,h.context=H,h.keyPath=W,h.treeContext=ne,h.componentStack=X,w(H);return}if(m.message==="Maximum call stack size exceeded"){oe=De===Le?yo():null,oe=Dc(i,h,oe),i.pingedTasks.push(oe),h.formatContext=P,h.context=H,h.keyPath=W,h.treeContext=ne,h.componentStack=X,w(H);return}}}}throw h.formatContext=P,h.context=H,h.keyPath=W,h.treeContext=ne,w(H),m}function Qi(i){var h=i.blockedBoundary,m=i.blockedSegment;m!==null&&(m.status=3,wr(this,h,i.row,m))}function xi(i,h,m,C,P,H){for(var W=0;W<m.length;W++){var ne=m[W];if(ne.length===4)xi(i,h,ne[2],ne[3],P,H);else{ne=ne[5];var X=i,oe=H,fe=Ca(X,null,new Set,null,null);fe.parentFlushed=!0,fe.rootSegmentID=ne,fe.status=4,fe.errorDigest=oe,fe.parentFlushed&&X.clientRenderedBoundaries.push(fe)}}if(m.length=0,C!==null){if(h===null)throw Error(d(487));if(h.status!==4&&(h.status=4,h.errorDigest=H,h.parentFlushed&&i.clientRenderedBoundaries.push(h)),typeof C=="object")for(var me in C)delete C[me]}}function mi(i,h,m){var C=i.blockedBoundary,P=i.blockedSegment;if(P!==null){if(P.status===6)return;P.status=3}var H=kr(i.componentStack);if(C===null){if(h.status!==13&&h.status!==14){if(C=i.replay,C===null){h.trackedPostpones!==null&&P!==null?(C=h.trackedPostpones,so(h,m,H),Fc(h,C,i,P),wr(h,null,i.row,P)):(so(h,m,H),Sa(h,m));return}C.pendingTasks--,C.pendingTasks===0&&0<C.nodes.length&&(P=so(h,m,H),xi(h,null,C.nodes,C.slots,m,P)),h.pendingRootTasks--,h.pendingRootTasks===0&&Oc(h)}}else{var W=h.trackedPostpones;if(C.status!==4){if(W!==null&&P!==null)return so(h,m,H),Fc(h,W,i,P),C.fallbackAbortableTasks.forEach(function(ne){return mi(ne,h,m)}),C.fallbackAbortableTasks.clear(),wr(h,C,i.row,P);C.status=4,P=so(h,m,H),C.status=4,C.errorDigest=P,Ji(h,C),C.parentFlushed&&h.clientRenderedBoundaries.push(C)}C.pendingTasks--,P=C.row,P!==null&&--P.pendingTasks===0&&Eo(h,P),C.fallbackAbortableTasks.forEach(function(ne){return mi(ne,h,m)}),C.fallbackAbortableTasks.clear()}i=i.row,i!==null&&--i.pendingTasks===0&&Eo(h,i),h.allPendingTasks--,h.allPendingTasks===0&&$i(h)}function qi(i,h){try{var m=i.renderState,C=m.onHeaders;if(C){var P=m.headers;if(P){m.headers=null;var H=P.preconnects;if(P.fontPreloads&&(H&&(H+=", "),H+=P.fontPreloads),P.highImagePreloads&&(H&&(H+=", "),H+=P.highImagePreloads),!h){var W=m.styles.values(),ne=W.next();e:for(;0<P.remainingCapacity&&!ne.done;ne=W.next())for(var X=ne.value.sheets.values(),oe=X.next();0<P.remainingCapacity&&!oe.done;oe=X.next()){var fe=oe.value,me=fe.props,De=me.href,Me=fe.props,pt=Gi(Me.href,"style",{crossOrigin:Me.crossOrigin,integrity:Me.integrity,nonce:Me.nonce,type:Me.type,fetchPriority:Me.fetchPriority,referrerPolicy:Me.referrerPolicy,media:Me.media});if(0<=(P.remainingCapacity-=pt.length+2))m.resets.style[De]=On,H&&(H+=", "),H+=pt,m.resets.style[De]=typeof me.crossOrigin=="string"||typeof me.integrity=="string"?[me.crossOrigin,me.integrity]:On;else break e}}C(H?{Link:H}:{})}}}catch(qe){so(i,qe,{})}}function Oc(i){i.trackedPostpones===null&&qi(i,!0),i.trackedPostpones===null&&Yr(i),i.onShellError=ve,i=i.onShellReady,i()}function $i(i){qi(i,i.trackedPostpones===null?!0:i.completedRootSegment===null||i.completedRootSegment.status!==5),Yr(i),i=i.onAllReady,i()}function ec(i,h){if(h.chunks.length===0&&h.children.length===1&&h.children[0].boundary===null&&h.children[0].id===-1){var m=h.children[0];m.id=h.id,m.parentFlushed=!0,m.status!==1&&m.status!==3&&m.status!==4||ec(i,m)}else i.completedSegments.push(h)}function hs(i,h,m){if(ot!==null){m=m.chunks;for(var C=0,P=0;P<m.length;P++)C+=m[P].byteLength;h===null?i.byteSize+=C:h.byteSize+=C}}function wr(i,h,m,C){if(m!==null&&(--m.pendingTasks===0?Eo(i,m):m.together&&Gs(i,m)),i.allPendingTasks--,h===null){if(C!==null&&C.parentFlushed){if(i.completedRootSegment!==null)throw Error(d(389));i.completedRootSegment=C}i.pendingRootTasks--,i.pendingRootTasks===0&&Oc(i)}else if(h.pendingTasks--,h.status!==4)if(h.pendingTasks===0){if(h.status===0&&(h.status=1),C!==null&&C.parentFlushed&&(C.status===1||C.status===3)&&ec(h,C),h.parentFlushed&&i.completedBoundaries.push(h),h.status===1)m=h.row,m!==null&&js(m.hoistables,h.contentState),Pn(i,h)||(h.fallbackAbortableTasks.forEach(Qi,i),h.fallbackAbortableTasks.clear(),m!==null&&--m.pendingTasks===0&&Eo(i,m)),i.pendingRootTasks===0&&i.trackedPostpones===null&&h.contentPreamble!==null&&Yr(i);else if(h.status===5&&(h=h.row,h!==null)){if(i.trackedPostpones!==null){m=i.trackedPostpones;var P=h.next;if(P!==null&&(C=P.boundaries,C!==null))for(P.boundaries=null,P=0;P<C.length;P++){var H=C[P];Lc(i,m,H),wr(i,H,null,null)}}--h.pendingTasks===0&&Eo(i,h)}}else C===null||!C.parentFlushed||C.status!==1&&C.status!==3||(ec(h,C),h.completedSegments.length===1&&h.parentFlushed&&i.partialBoundaries.push(h)),h=h.row,h!==null&&h.together&&Gs(i,h);i.allPendingTasks===0&&$i(i)}function au(i){if(i.status!==14&&i.status!==13){var h=an,m=Xl.H;Xl.H=is;var C=Xl.A;Xl.A=ui;var P=ut;ut=i;var H=vo;vo=i.resumableState;try{var W=i.pingedTasks,ne;for(ne=0;ne<W.length;ne++){var X=W[ne],oe=i,fe=X.blockedSegment;if(fe===null){var me=oe;if(X.replay.pendingTasks!==0){w(X.context);try{if(typeof X.replay.slots=="number"?Ys(me,X,X.replay.slots,X.node,X.childIndex):gi(me,X),X.replay.pendingTasks===1&&0<X.replay.nodes.length)throw Error(d(488));X.replay.pendingTasks--,X.abortSet.delete(X),wr(me,X.blockedBoundary,X.row,null)}catch(Co){vr();var De=Co===Le?Qe():Co;if(typeof De=="object"&&De!==null&&typeof De.then=="function"){var Me=X.ping;De.then(Me,Me),X.thenableState=Co===Le?yo():null}else{X.replay.pendingTasks--,X.abortSet.delete(X);var pt=kr(X.componentStack);oe=void 0;var qe=me,xt=X.blockedBoundary,hn=me.status===12?me.fatalError:De,Kt=X.replay.nodes,ao=X.replay.slots;oe=so(qe,hn,pt),xi(qe,xt,Kt,ao,hn,oe),me.pendingRootTasks--,me.pendingRootTasks===0&&Oc(me),me.allPendingTasks--,me.allPendingTasks===0&&$i(me)}}finally{}}}else if(me=void 0,qe=fe,qe.status===0){qe.status=6,w(X.context);var Qo=qe.children.length,Sr=qe.chunks.length;try{gi(oe,X),qe.lastPushedText&&qe.textEmbedded&&qe.chunks.push(el),X.abortSet.delete(X),qe.status=1,hs(oe,X.blockedBoundary,qe),wr(oe,X.blockedBoundary,X.row,qe)}catch(Co){vr(),qe.children.length=Qo,qe.chunks.length=Sr;var $e=Co===Le?Qe():oe.status===12?oe.fatalError:Co;if(oe.status===12&&oe.trackedPostpones!==null){var wo=oe.trackedPostpones,En=kr(X.componentStack);X.abortSet.delete(X),so(oe,$e,En),Fc(oe,wo,X,qe),wr(oe,X.blockedBoundary,X.row,qe)}else if(typeof $e=="object"&&$e!==null&&typeof $e.then=="function"){qe.status=0,X.thenableState=Co===Le?yo():null;var Go=X.ping;$e.then(Go,Go)}else{var Hl=kr(X.componentStack);X.abortSet.delete(X),qe.status=4;var fn=X.blockedBoundary,Ks=X.row;if(Ks!==null&&--Ks.pendingTasks===0&&Eo(oe,Ks),oe.allPendingTasks--,me=so(oe,$e,Hl),fn===null)Sa(oe,$e);else if(fn.pendingTasks--,fn.status!==4){fn.status=4,fn.errorDigest=me,Ji(oe,fn);var Tr=fn.row;Tr!==null&&--Tr.pendingTasks===0&&Eo(oe,Tr),fn.parentFlushed&&oe.clientRenderedBoundaries.push(fn),oe.pendingRootTasks===0&&oe.trackedPostpones===null&&fn.contentPreamble!==null&&Yr(oe)}oe.allPendingTasks===0&&$i(oe)}}finally{}}}W.splice(0,ne),i.destination!==null&&Aa(i,i.destination)}catch(Co){so(i,Co,{}),Sa(i,Co)}finally{vo=H,Xl.H=m,Xl.A=C,m===is&&w(h),ut=P}}}function Xs(i,h,m){h.preambleChildren.length&&m.push(h.preambleChildren);for(var C=!1,P=0;P<h.children.length;P++)C=bi(i,h.children[P],m)||C;return C}function bi(i,h,m){var C=h.boundary;if(C===null)return Xs(i,h,m);var P=C.contentPreamble,H=C.fallbackPreamble;if(P===null||H===null)return!1;switch(C.status){case 1:if($a(i.renderState,P),i.byteSize+=C.byteSize,h=C.completedSegments[0],!h)throw Error(d(391));return Xs(i,h,m);case 5:if(i.trackedPostpones!==null)return!0;case 4:if(h.status===1)return $a(i.renderState,H),Xs(i,h,m);default:return!0}}function Yr(i){if(i.completedRootSegment&&i.completedPreambleSegments===null){var h=[],m=i.byteSize,C=bi(i,i.completedRootSegment,h),P=i.renderState.preamble;C===!1||P.headChunks&&P.bodyChunks?i.completedPreambleSegments=h:i.byteSize=m}}function Ta(i,h,m,C){switch(m.parentFlushed=!0,m.status){case 0:m.id=i.nextSegmentId++;case 5:return C=m.id,m.lastPushedText=!1,m.textEmbedded=!1,i=i.renderState,ue(h,kc),ue(h,i.placeholderPrefix),i=Ie(C.toString(16)),ue(h,i),Ae(h,ei);case 1:m.status=2;var P=!0,H=m.chunks,W=0;m=m.children;for(var ne=0;ne<m.length;ne++){for(P=m[ne];W<P.index;W++)ue(h,H[W]);P=yi(i,h,P,C)}for(;W<H.length-1;W++)ue(h,H[W]);return W<H.length&&(P=Ae(h,H[W])),P;case 3:return!0;default:throw Error(d(390))}}var fs=0;function yi(i,h,m,C){var P=m.boundary;if(P===null)return Ta(i,h,m,C);if(P.parentFlushed=!0,P.status===4){var H=P.row;H!==null&&--H.pendingTasks===0&&Eo(i,H),P=P.errorDigest,Ae(h,Gn),ue(h,wc),P&&(ue(h,Hr),ue(h,Ie(et(P))),ue(h,wl)),Ae(h,Cc),Ta(i,h,m,C)}else if(P.status!==1)P.status===0&&(P.rootSegmentID=i.nextSegmentId++),0<P.completedSegments.length&&i.partialBoundaries.push(P),Cl(h,i.renderState,P.rootSegmentID),C&&js(C,P.fallbackState),Ta(i,h,m,C);else if(!Xr&&Pn(i,P)&&(fs+P.byteSize>i.progressiveChunkSize||Ra(P.contentState)))P.rootSegmentID=i.nextSegmentId++,i.completedBoundaries.push(P),Cl(h,i.renderState,P.rootSegmentID),Ta(i,h,m,C);else{if(fs+=P.byteSize,C&&js(C,P.contentState),m=P.row,m!==null&&Pn(i,P)&&--m.pendingTasks===0&&Eo(i,m),Ae(h,Ql),m=P.completedSegments,m.length!==1)throw Error(d(391));yi(i,h,m[0],C)}return Ae(h,Xt)}function gs(i,h,m,C){return Ns(h,i.renderState,m.parentFormatContext,m.id),yi(i,h,m,C),zr(h,m.parentFormatContext)}function iu(i,h,m){fs=m.byteSize;for(var C=m.completedSegments,P=0;P<C.length;P++)cu(i,h,m,C[P]);C.length=0,C=m.row,C!==null&&Pn(i,m)&&--C.pendingTasks===0&&Eo(i,C),fr(h,m.contentState,i.renderState),C=i.resumableState,i=i.renderState,P=m.rootSegmentID,m=m.contentState;var H=i.stylesToHoist;return i.stylesToHoist=!1,ue(h,i.startInlineScript),ue(h,kt),H?(!(C.instructions&4)&&(C.instructions|=4,ue(h,ts)),!(C.instructions&2)&&(C.instructions|=2,ue(h,ba)),C.instructions&8?ue(h,ou):(C.instructions|=8,ue(h,Vn))):(!(C.instructions&2)&&(C.instructions|=2,ue(h,ba)),ue(h,ya)),C=Ie(P.toString(16)),ue(h,i.boundaryPrefix),ue(h,C),ue(h,es),ue(h,i.segmentPrefix),ue(h,C),H?(ue(h,ni),Qn(h,m)):ue(h,ji),m=Ae(h,Pl),Oo(h,i)&&m}function cu(i,h,m,C){if(C.status===2)return!0;var P=m.contentState,H=C.id;if(H===-1){if((C.id=m.rootSegmentID)===-1)throw Error(d(392));return gs(i,h,C,P)}return H===m.rootSegmentID?gs(i,h,C,P):(gs(i,h,C,P),m=i.resumableState,i=i.renderState,ue(h,i.startInlineScript),ue(h,kt),m.instructions&1?ue(h,Tc):(m.instructions|=1,ue(h,Sc)),ue(h,i.segmentPrefix),H=Ie(H.toString(16)),ue(h,H),ue(h,Ac),ue(h,i.placeholderPrefix),ue(h,H),h=Ae(h,ma),h)}var Xr=!1;function Aa(i,h){We=new Uint8Array(2048),Pe=0;try{if(!(0<i.pendingRootTasks)){var m,C=i.completedRootSegment;if(C!==null){if(C.status===5)return;var P=i.completedPreambleSegments;if(P===null)return;fs=i.byteSize;var H=i.resumableState,W=i.renderState,ne=W.preamble,X=ne.htmlChunks,oe=ne.headChunks,fe;if(X){for(fe=0;fe<X.length;fe++)ue(h,X[fe]);if(oe)for(fe=0;fe<oe.length;fe++)ue(h,oe[fe]);else ue(h,jn("head")),ue(h,kt)}else if(oe)for(fe=0;fe<oe.length;fe++)ue(h,oe[fe]);var me=W.charsetChunks;for(fe=0;fe<me.length;fe++)ue(h,me[fe]);me.length=0,W.preconnects.forEach($t,h),W.preconnects.clear();var De=W.viewportChunks;for(fe=0;fe<De.length;fe++)ue(h,De[fe]);De.length=0,W.fontPreloads.forEach($t,h),W.fontPreloads.clear(),W.highImagePreloads.forEach($t,h),W.highImagePreloads.clear(),Dr=W,W.styles.forEach(ai,h),Dr=null;var Me=W.importMapChunks;for(fe=0;fe<Me.length;fe++)ue(h,Me[fe]);Me.length=0,W.bootstrapScripts.forEach($t,h),W.scripts.forEach($t,h),W.scripts.clear(),W.bulkPreloads.forEach($t,h),W.bulkPreloads.clear(),X||oe||(H.instructions|=32);var pt=W.hoistableChunks;for(fe=0;fe<pt.length;fe++)ue(h,pt[fe]);for(H=pt.length=0;H<P.length;H++){var qe=P[H];for(W=0;W<qe.length;W++)yi(i,h,qe[W],null)}var xt=i.renderState.preamble,hn=xt.headChunks;(xt.htmlChunks||hn)&&ue(h,rl("head"));var Kt=xt.bodyChunks;if(Kt)for(P=0;P<Kt.length;P++)ue(h,Kt[P]);yi(i,h,C,null),i.completedRootSegment=null;var ao=i.renderState;if(i.allPendingTasks!==0||i.clientRenderedBoundaries.length!==0||i.completedBoundaries.length!==0||i.trackedPostpones!==null&&(i.trackedPostpones.rootNodes.length!==0||i.trackedPostpones.rootSlots!==null)){var Qo=i.resumableState;if(!(Qo.instructions&64)){if(Qo.instructions|=64,ue(h,ao.startInlineScript),!(Qo.instructions&32)){Qo.instructions|=32;var Sr="_"+Qo.idPrefix+"R_";ue(h,wt),ue(h,Ie(et(Sr))),ue(h,Ht)}ue(h,kt),ue(h,jr),Ae(h,Rt)}}Oo(h,ao)}var $e=i.renderState;C=0;var wo=$e.viewportChunks;for(C=0;C<wo.length;C++)ue(h,wo[C]);wo.length=0,$e.preconnects.forEach($t,h),$e.preconnects.clear(),$e.fontPreloads.forEach($t,h),$e.fontPreloads.clear(),$e.highImagePreloads.forEach($t,h),$e.highImagePreloads.clear(),$e.styles.forEach(en,h),$e.scripts.forEach($t,h),$e.scripts.clear(),$e.bulkPreloads.forEach($t,h),$e.bulkPreloads.clear();var En=$e.hoistableChunks;for(C=0;C<En.length;C++)ue(h,En[C]);En.length=0;var Go=i.clientRenderedBoundaries;for(m=0;m<Go.length;m++){var Hl=Go[m];$e=h;var fn=i.resumableState,Ks=i.renderState,Tr=Hl.rootSegmentID,Co=Hl.errorDigest;ue($e,Ks.startInlineScript),ue($e,kt),fn.instructions&4?ue($e,Wr):(fn.instructions|=4,ue($e,va)),ue($e,Ks.boundaryPrefix),ue($e,Ie(Tr.toString(16))),ue($e,ns),Co&&(ue($e,os),ue($e,Ie(Ls(Co||""))));var Zr=Ae($e,Ic);if(!Zr){i.destination=null,m++,Go.splice(0,m);return}}Go.splice(0,m);var So=i.completedBoundaries;for(m=0;m<So.length;m++)if(!iu(i,h,So[m])){i.destination=null,m++,So.splice(0,m);return}So.splice(0,m),He(h),We=new Uint8Array(2048),Pe=0,Xr=!0;var Js=i.partialBoundaries;for(m=0;m<Js.length;m++){var Ba=Js[m];e:{Go=i,Hl=h,fs=Ba.byteSize;var Vo=Ba.completedSegments;for(Zr=0;Zr<Vo.length;Zr++)if(!cu(Go,Hl,Ba,Vo[Zr])){Zr++,Vo.splice(0,Zr);var Pa=!1;break e}Vo.splice(0,Zr);var To=Ba.row;To!==null&&To.together&&Ba.pendingTasks===1&&(To.pendingTasks===1?Nc(Go,To,To.hoistables):To.pendingTasks--),Pa=fr(Hl,Ba.contentState,Go.renderState)}if(!Pa){i.destination=null,m++,Js.splice(0,m);return}}Js.splice(0,m),Xr=!1;var Qs=i.completedBoundaries;for(m=0;m<Qs.length;m++)if(!iu(i,h,Qs[m])){i.destination=null,m++,Qs.splice(0,m);return}Qs.splice(0,m)}}finally{Xr=!1,i.allPendingTasks===0&&i.clientRenderedBoundaries.length===0&&i.completedBoundaries.length===0?(i.flushScheduled=!1,m=i.resumableState,m.hasBody&&ue(h,rl("body")),m.hasHtml&&ue(h,rl("html")),He(h),i.status=14,h.close(),i.destination=null):He(h)}}function xr(i){i.flushScheduled=i.destination!==null,ze(function(){return au(i)}),xe(function(){i.status===10&&(i.status=11),i.trackedPostpones===null&&qi(i,i.pendingRootTasks===0)})}function ps(i){i.flushScheduled===!1&&i.pingedTasks.length===0&&i.destination!==null&&(i.flushScheduled=!0,xe(function(){var h=i.destination;h?Aa(i,h):i.flushScheduled=!1}))}function Zs(i,h){if(i.status===13)i.status=14,wn(h,i.fatalError);else if(i.status!==14&&i.destination===null){i.destination=h;try{Aa(i,h)}catch(m){so(i,m,{}),Sa(i,m)}}}function Cr(i,h){(i.status===11||i.status===10)&&(i.status=12);try{var m=i.abortableTasks;if(0<m.size){var C=h===void 0?Error(d(432)):typeof h=="object"&&h!==null&&typeof h.then=="function"?Error(d(530)):h;i.fatalError=C,m.forEach(function(P){return mi(P,i,C)}),m.clear()}i.destination!==null&&Aa(i,i.destination)}catch(P){so(i,P,{}),Sa(i,P)}}function jc(i,h,m){if(h===null)m.rootNodes.push(i);else{var C=m.workingMap,P=C.get(h);P===void 0&&(P=[h[1],h[2],[],null],C.set(h,P),jc(P,h[0],m)),P[2].push(i)}}function uu(i){var h=i.trackedPostpones;if(h===null||h.rootNodes.length===0&&h.rootSlots===null)return i.trackedPostpones=null;if(i.completedRootSegment===null||i.completedRootSegment.status!==5&&i.completedPreambleSegments!==null){var m=i.nextSegmentId,C=h.rootSlots,P=i.resumableState;P.bootstrapScriptContent=void 0,P.bootstrapScripts=void 0,P.bootstrapModules=void 0}else{m=0,C=-1,P=i.resumableState;var H=i.renderState;P.nextFormID=0,P.hasBody=!1,P.hasHtml=!1,P.unknownResources={font:H.resets.font},P.dnsResources=H.resets.dns,P.connectResources=H.resets.connect,P.imageResources=H.resets.image,P.styleResources=H.resets.style,P.scriptResources={},P.moduleUnknownResources={},P.moduleScriptResources={},P.instructions=0}return{nextSegmentId:m,rootFormatContext:i.rootFormatContext,progressiveChunkSize:i.progressiveChunkSize,resumableState:i.resumableState,replayNodes:h.rootNodes,replaySlots:C}}function Ia(){var i=n.version;if(i!=="19.2.0")throw Error(d(527,i,"19.2.0"))}return Ia(),Ia(),reactDomServer_browser_production.prerender=function(i,h){return new Promise(function(m,C){var P=h?h.onHeaders:void 0,H;P&&(H=function(fe){P(new Headers(fe))});var W=Va(h?h.identifierPrefix:void 0,h?h.unstable_externalRuntimeSrc:void 0,h?h.bootstrapScriptContent:void 0,h?h.bootstrapScripts:void 0,h?h.bootstrapModules:void 0),ne=zs(i,W,ws(W,void 0,h?h.unstable_externalRuntimeSrc:void 0,h?h.importMap:void 0,H,h?h.maxHeadersLength:void 0),Ni(h?h.namespaceURI:void 0),h?h.progressiveChunkSize:void 0,h?h.onError:void 0,function(){var fe=new ReadableStream({type:"bytes",pull:function(me){Zs(ne,me)},cancel:function(me){ne.destination=null,Cr(ne,me)}},{highWaterMark:0});fe={postponed:uu(ne),prelude:fe},m(fe)},void 0,void 0,C,h?h.onPostpone:void 0);if(h&&h.signal){var X=h.signal;if(X.aborted)Cr(ne,X.reason);else{var oe=function(){Cr(ne,X.reason),X.removeEventListener("abort",oe)};X.addEventListener("abort",oe)}}xr(ne)})},reactDomServer_browser_production.renderToReadableStream=function(i,h){return new Promise(function(m,C){var P,H,W=new Promise(function(Me,pt){H=Me,P=pt}),ne=h?h.onHeaders:void 0,X;ne&&(X=function(Me){ne(new Headers(Me))});var oe=Va(h?h.identifierPrefix:void 0,h?h.unstable_externalRuntimeSrc:void 0,h?h.bootstrapScriptContent:void 0,h?h.bootstrapScripts:void 0,h?h.bootstrapModules:void 0),fe=wa(i,oe,ws(oe,h?h.nonce:void 0,h?h.unstable_externalRuntimeSrc:void 0,h?h.importMap:void 0,X,h?h.maxHeadersLength:void 0),Ni(h?h.namespaceURI:void 0),h?h.progressiveChunkSize:void 0,h?h.onError:void 0,H,function(){var Me=new ReadableStream({type:"bytes",pull:function(pt){Zs(fe,pt)},cancel:function(pt){fe.destination=null,Cr(fe,pt)}},{highWaterMark:0});Me.allReady=W,m(Me)},function(Me){W.catch(function(){}),C(Me)},P,h?h.onPostpone:void 0,h?h.formState:void 0);if(h&&h.signal){var me=h.signal;if(me.aborted)Cr(fe,me.reason);else{var De=function(){Cr(fe,me.reason),me.removeEventListener("abort",De)};me.addEventListener("abort",De)}}xr(fe)})},reactDomServer_browser_production.resume=function(i,h,m){return new Promise(function(C,P){var H,W,ne=new Promise(function(me,De){W=me,H=De}),X=Rn(i,h,ws(h.resumableState,m?m.nonce:void 0,void 0,void 0,void 0,void 0),m?m.onError:void 0,W,function(){var me=new ReadableStream({type:"bytes",pull:function(De){Zs(X,De)},cancel:function(De){X.destination=null,Cr(X,De)}},{highWaterMark:0});me.allReady=ne,C(me)},function(me){ne.catch(function(){}),P(me)},H,m?m.onPostpone:void 0);if(m&&m.signal){var oe=m.signal;if(oe.aborted)Cr(X,oe.reason);else{var fe=function(){Cr(X,oe.reason),oe.removeEventListener("abort",fe)};oe.addEventListener("abort",fe)}}xr(X)})},reactDomServer_browser_production.resumeAndPrerender=function(i,h,m){return new Promise(function(C,P){var H=pr(i,h,ws(h.resumableState,void 0,void 0,void 0,void 0,void 0),m?m.onError:void 0,function(){var X=new ReadableStream({type:"bytes",pull:function(oe){Zs(H,oe)},cancel:function(oe){H.destination=null,Cr(H,oe)}},{highWaterMark:0});X={postponed:uu(H),prelude:X},C(X)},void 0,void 0,P,m?m.onPostpone:void 0);if(m&&m.signal){var W=m.signal;if(W.aborted)Cr(H,W.reason);else{var ne=function(){Cr(H,W.reason),W.removeEventListener("abort",ne)};W.addEventListener("abort",ne)}}xr(H)})},reactDomServer_browser_production.version="19.2.0",reactDomServer_browser_production}var reactDomServerLegacy_browser_development={};/**
70
+ * @license React
71
+ * react-dom-server-legacy.browser.development.js
72
+ *
73
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
74
+ *
75
+ * This source code is licensed under the MIT license found in the
76
+ * LICENSE file in the root directory of this source tree.
77
+ */var hasRequiredReactDomServerLegacy_browser_development;function requireReactDomServerLegacy_browser_development(){return hasRequiredReactDomServerLegacy_browser_development||(hasRequiredReactDomServerLegacy_browser_development=1,process.env.NODE_ENV!=="production"&&function(){function n(r,a,p,k){return""+a+(p==="s"?"\\73 ":"\\53 ")+k}function c(r,a,p,k){return""+a+(p==="s"?"\\u0073":"\\u0053")+k}function d(r){return r===null||typeof r!="object"?null:(r=li&&r[li]||r["@@iterator"],typeof r=="function"?r:null)}function x(r){return r=Object.prototype.toString.call(r),r.slice(8,r.length-1)}function b(r){var a=JSON.stringify(r);return'"'+r+'"'===a?r:a}function y(r){switch(typeof r){case"string":return JSON.stringify(10>=r.length?r:r.slice(0,10)+"...");case"object":return _l(r)?"[...]":r!==null&&r.$$typeof===zo?"client":(r=x(r),r==="Object"?"{...}":r);case"function":return r.$$typeof===zo?"client":(r=r.displayName||r.name)?"function "+r:"function";default:return String(r)}}function R(r){if(typeof r=="string")return r;switch(r){case Jo:return"Suspense";case hr:return"SuspenseList"}if(typeof r=="object")switch(r.$$typeof){case dr:return R(r.render);case Ut:return R(r.type);case fr:var a=r._payload;r=r._init;try{return R(r(a))}catch{}}return""}function S(r,a){var p=x(r);if(p!=="Object"&&p!=="Array")return p;var k=-1,B=0;if(_l(r))if(ai.has(r)){var j=ai.get(r);p="<"+R(j)+">";for(var Y=0;Y<r.length;Y++){var Q=r[Y];Q=typeof Q=="string"?Q:typeof Q=="object"&&Q!==null?"{"+S(Q)+"}":"{"+y(Q)+"}",""+Y===a?(k=p.length,B=Q.length,p+=Q):p=15>Q.length&&40>p.length+Q.length?p+Q:p+"{...}"}p+="</"+R(j)+">"}else{for(p="[",j=0;j<r.length;j++)0<j&&(p+=", "),Y=r[j],Y=typeof Y=="object"&&Y!==null?S(Y):y(Y),""+j===a?(k=p.length,B=Y.length,p+=Y):p=10>Y.length&&40>p.length+Y.length?p+Y:p+"...";p+="]"}else if(r.$$typeof===Ls)p="<"+R(r.type)+"/>";else{if(r.$$typeof===zo)return"client";if(si.has(r)){for(p=si.get(r),p="<"+(R(p)||"..."),j=Object.keys(r),Y=0;Y<j.length;Y++){p+=" ",Q=j[Y],p+=b(Q)+"=";var ke=r[Q],re=Q===a&&typeof ke=="object"&&ke!==null?S(ke):y(ke);typeof ke!="string"&&(re="{"+re+"}"),Q===a?(k=p.length,B=re.length,p+=re):p=10>re.length&&40>p.length+re.length?p+re:p+"..."}p+=">"}else{for(p="{",j=Object.keys(r),Y=0;Y<j.length;Y++)0<Y&&(p+=", "),Q=j[Y],p+=b(Q)+": ",ke=r[Q],ke=typeof ke=="object"&&ke!==null?S(ke):y(ke),Q===a?(k=p.length,B=ke.length,p+=ke):p=10>ke.length&&40>p.length+ke.length?p+ke:p+"...";p+="}"}}return a===void 0?p:-1<k&&0<B?(r=" ".repeat(k)+"^".repeat(B),`
78
+ `+p+`
79
+ `+r):`
80
+ `+p}function _(r,a){var p=r.length&3,k=r.length-p,B=a;for(a=0;a<k;){var j=r.charCodeAt(a)&255|(r.charCodeAt(++a)&255)<<8|(r.charCodeAt(++a)&255)<<16|(r.charCodeAt(++a)&255)<<24;++a,j=3432918353*(j&65535)+((3432918353*(j>>>16)&65535)<<16)&4294967295,j=j<<15|j>>>17,j=461845907*(j&65535)+((461845907*(j>>>16)&65535)<<16)&4294967295,B^=j,B=B<<13|B>>>19,B=5*(B&65535)+((5*(B>>>16)&65535)<<16)&4294967295,B=(B&65535)+27492+(((B>>>16)+58964&65535)<<16)}switch(j=0,p){case 3:j^=(r.charCodeAt(a+2)&255)<<16;case 2:j^=(r.charCodeAt(a+1)&255)<<8;case 1:j^=r.charCodeAt(a)&255,j=3432918353*(j&65535)+((3432918353*(j>>>16)&65535)<<16)&4294967295,j=j<<15|j>>>17,B^=461845907*(j&65535)+((461845907*(j>>>16)&65535)<<16)&4294967295}return B^=r.length,B^=B>>>16,B=2246822507*(B&65535)+((2246822507*(B>>>16)&65535)<<16)&4294967295,B^=B>>>13,B=3266489909*(B&65535)+((3266489909*(B>>>16)&65535)<<16)&4294967295,(B^B>>>16)>>>0}function A(r){return typeof Symbol=="function"&&Symbol.toStringTag&&r[Symbol.toStringTag]||r.constructor.name||"Object"}function L(r){try{return T(r),!1}catch{return!0}}function T(r){return""+r}function O(r,a){if(L(r))return console.error("The provided `%s` attribute is an unsupported type %s. This value must be coerced to a string before using it here.",a,A(r)),T(r)}function U(r,a){if(L(r))return console.error("The provided `%s` CSS property is an unsupported type %s. This value must be coerced to a string before using it here.",a,A(r)),T(r)}function M(r){if(L(r))return console.error("The provided HTML markup uses a value of unsupported type %s. This value must be coerced to a string before using it here.",A(r)),T(r)}function D(r){return wt.call(Ms,r)?!0:wt.call(Fs,r)?!1:rs.test(r)?Ms[r]=!0:(Fs[r]=!0,console.error("Invalid attribute name: `%s`",r),!1)}function K(r,a){Qn[a.type]||a.onChange||a.onInput||a.readOnly||a.disabled||a.value==null||console.error(r==="select"?"You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set `onChange`.":"You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`."),a.onChange||a.readOnly||a.disabled||a.checked==null||console.error("You provided a `checked` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultChecked`. Otherwise, set either `onChange` or `readOnly`.")}function $(r,a){if(wt.call(Vr,a)&&Vr[a])return!0;if(Pc.test(a)){if(r="aria-"+a.slice(4).toLowerCase(),r=Ru.hasOwnProperty(r)?r:null,r==null)return console.error("Invalid ARIA attribute `%s`. ARIA attributes follow the pattern aria-* and must be lowercase.",a),Vr[a]=!0;if(a!==r)return console.error("Invalid ARIA attribute `%s`. Did you mean `%s`?",a,r),Vr[a]=!0}if(ru.test(a)){if(r=a.toLowerCase(),r=Ru.hasOwnProperty(r)?r:null,r==null)return Vr[a]=!0,!1;a!==r&&(console.error("Unknown ARIA attribute `%s`. Did you mean `%s`?",a,r),Vr[a]=!0)}return!0}function ee(r,a){var p=[],k;for(k in a)$(r,k)||p.push(k);a=p.map(function(B){return"`"+B+"`"}).join(", "),p.length===1?console.error("Invalid aria prop %s on <%s> tag. For details, see https://react.dev/link/invalid-aria-props",a,r):1<p.length&&console.error("Invalid aria props %s on <%s> tag. For details, see https://react.dev/link/invalid-aria-props",a,r)}function ae(r,a,p,k){if(wt.call(ro,a)&&ro[a])return!0;var B=a.toLowerCase();if(B==="onfocusin"||B==="onfocusout")return console.error("React uses onFocus and onBlur instead of onFocusIn and onFocusOut. All React events are normalized to bubble, so onFocusIn and onFocusOut are not needed/supported by React."),ro[a]=!0;if(typeof p=="function"&&(r==="form"&&a==="action"||r==="input"&&a==="formAction"||r==="button"&&a==="formAction"))return!0;if(Nl.test(a))return lu.test(a)&&console.error("Invalid event handler property `%s`. React events use the camelCase naming convention, for example `onClick`.",a),ro[a]=!0;if(Ds.test(a)||Gi.test(a))return!0;if(B==="innerhtml")return console.error("Directly setting property `innerHTML` is not permitted. For more information, lookup documentation on `dangerouslySetInnerHTML`."),ro[a]=!0;if(B==="aria")return console.error("The `aria` attribute is reserved for future use in React. Pass individual `aria-` attributes instead."),ro[a]=!0;if(B==="is"&&p!==null&&p!==void 0&&typeof p!="string")return console.error("Received a `%s` for a string attribute `is`. If this is expected, cast the value to a string.",typeof p),ro[a]=!0;if(typeof p=="number"&&isNaN(p))return console.error("Received NaN for the `%s` attribute. If this is expected, cast the value to a string.",a),ro[a]=!0;if(ii.hasOwnProperty(B)){if(B=ii[B],B!==a)return console.error("Invalid DOM property `%s`. Did you mean `%s`?",a,B),ro[a]=!0}else if(a!==B)return console.error("React does not recognize the `%s` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `%s` instead. If you accidentally passed it from a parent component, remove it from the DOM element.",a,B),ro[a]=!0;switch(a){case"dangerouslySetInnerHTML":case"children":case"style":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":return!0;case"innerText":case"textContent":return!0}switch(typeof p){case"boolean":switch(a){case"autoFocus":case"checked":case"multiple":case"muted":case"selected":case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":case"capture":case"download":case"inert":return!0;default:return B=a.toLowerCase().slice(0,5),B==="data-"||B==="aria-"?!0:(p?console.error('Received `%s` for a non-boolean attribute `%s`.\n\nIf you want to write it to the DOM, pass a string instead: %s="%s" or %s={value.toString()}.',p,a,a,p,a):console.error('Received `%s` for a non-boolean attribute `%s`.\n\nIf you want to write it to the DOM, pass a string instead: %s="%s" or %s={value.toString()}.\n\nIf you used to conditionally omit it with %s={condition && value}, pass %s={condition ? value : undefined} instead.',p,a,a,p,a,a,a),ro[a]=!0)}case"function":case"symbol":return ro[a]=!0,!1;case"string":if(p==="false"||p==="true"){switch(a){case"checked":case"selected":case"multiple":case"muted":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":case"inert":break;default:return!0}console.error("Received the string `%s` for the boolean attribute `%s`. %s Did you mean %s={%s}?",p,a,p==="false"?"The browser will interpret it as a truthy value.":'Although this works, it will not work as expected if you pass the string "false".',a,p),ro[a]=!0}}return!0}function Re(r,a,p){var k=[],B;for(B in a)ae(r,B,a[B])||k.push(B);a=k.map(function(j){return"`"+j+"`"}).join(", "),k.length===1?console.error("Invalid value for prop %s on <%s> tag. Either remove it from the element, or pass a string or number value to keep it in the DOM. For details, see https://react.dev/link/attribute-behavior ",a,r):1<k.length&&console.error("Invalid values for props %s on <%s> tag. Either remove them from the element, or pass a string or number value to keep them in the DOM. For details, see https://react.dev/link/attribute-behavior ",a,r)}function ye(r){return r.replace(qn,function(a,p){return p.toUpperCase()})}function de(r){if(typeof r=="boolean"||typeof r=="number"||typeof r=="bigint")return""+r;M(r),r=""+r;var a=Vi.exec(r);if(a){var p="",k,B=0;for(k=a.index;k<r.length;k++){switch(r.charCodeAt(k)){case 34:a="&quot;";break;case 38:a="&amp;";break;case 39:a="&#x27;";break;case 60:a="&lt;";break;case 62:a="&gt;";break;default:continue}B!==k&&(p+=r.slice(B,k)),B=k+1,p+=a}r=B!==k?p+r.slice(B,k):p}return r}function q(r){return Eu.test(""+r)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":r}function he(r){return M(r),(""+r).replace(Le,c)}function le(r,a,p,k,B){return{idPrefix:r===void 0?"":r,nextFormID:0,streamingFormat:0,bootstrapScriptContent:p,bootstrapScripts:k,bootstrapModules:B,instructions:f,hasBody:!1,hasHtml:!1,unknownResources:{},dnsResources:{},connectResources:{default:{},anonymous:{},credentials:{}},imageResources:{},styleResources:{},scriptResources:{},moduleUnknownResources:{},moduleScriptResources:{}}}function xe(r,a,p,k){return{insertionMode:r,selectedValue:a,tagScope:p,viewTransition:k}}function Ee(r,a,p){var k=r.tagScope&-25;switch(a){case"noscript":return xe(Xe,null,k|1,null);case"select":return xe(Xe,p.value!=null?p.value:p.defaultValue,k,null);case"svg":return xe(Je,null,k,null);case"picture":return xe(Xe,null,k|2,null);case"math":return xe(tn,null,k,null);case"foreignObject":return xe(Xe,null,k,null);case"table":return xe(ct,null,k,null);case"thead":case"tbody":case"tfoot":return xe(mt,null,k,null);case"colgroup":return xe(lt,null,k,null);case"tr":return xe(Bt,null,k,null);case"head":if(r.insertionMode<Xe)return xe(tt,null,k,null);break;case"html":if(r.insertionMode===at)return xe(Qe,null,k,null)}return r.insertionMode>=ct||r.insertionMode<Xe?xe(Xe,null,k,null):r.tagScope!==k?xe(r.insertionMode,r.selectedValue,k,null):r}function je(r){return r===null?null:{update:r.update,enter:"none",exit:"none",share:r.update,name:r.autoName,autoName:r.autoName,nameIdx:0}}function ze(r,a){return a.tagScope&32&&(r.instructions|=128),xe(a.insertionMode,a.selectedValue,a.tagScope|12,je(a.viewTransition))}function We(r,a){r=je(a.viewTransition);var p=a.tagScope|16;return r!==null&&r.share!=="none"&&(p|=64),xe(a.insertionMode,a.selectedValue,p,r)}function Pe(r,a){if(typeof a!="object")throw Error("The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + 'em'}} when using JSX.");var p=!0,k;for(k in a)if(wt.call(a,k)){var B=a[k];if(B!=null&&typeof B!="boolean"&&B!==""){if(k.indexOf("--")===0){var j=de(k);U(B,k),B=de((""+B).trim())}else{j=k;var Y=B;if(-1<j.indexOf("-")){var Q=j;Zt.hasOwnProperty(Q)&&Zt[Q]||(Zt[Q]=!0,console.error("Unsupported style property %s. Did you mean %s?",Q,ye(Q.replace(lo,"ms-"))))}else if(Os.test(j))Q=j,Zt.hasOwnProperty(Q)&&Zt[Q]||(Zt[Q]=!0,console.error("Unsupported vendor-prefixed style property %s. Did you mean %s?",Q,Q.charAt(0).toUpperCase()+Q.slice(1)));else if(ss.test(Y)){Q=j;var ke=Y;Mt.hasOwnProperty(ke)&&Mt[ke]||(Mt[ke]=!0,console.error(`Style property values shouldn't contain a semicolon. Try "%s: %s" instead.`,Q,ke.replace(ss,"")))}typeof Y=="number"&&(isNaN(Y)?js||(js=!0,console.error("`NaN` is an invalid value for the `%s` css style property.",j)):isFinite(Y)||Ra||(Ra=!0,console.error("`Infinity` is an invalid value for the `%s` css style property.",j))),j=k,Y=un.get(j),Y!==void 0||(Y=de(j.replace(Ea,"-$1").toLowerCase().replace(_c,"-ms-")),un.set(j,Y)),j=Y,typeof B=="number"?B=B===0||ls.has(k)?""+B:B+"px":(U(B,k),B=de((""+B).trim()))}p?(p=!1,r.push(Ct,j,bo,B)):r.push(Nt,j,bo,B)}}p||r.push(nt)}function ue(r,a,p){p&&typeof p!="function"&&typeof p!="symbol"&&r.push(yt,a,Tt)}function Ae(r,a,p){typeof p!="function"&&typeof p!="symbol"&&typeof p!="boolean"&&r.push(yt,a,St,de(p),nt)}function He(r,a){this.push('<input type="hidden"'),kn(r),Ae(this,"name",a),Ae(this,"value",r),this.push(as)}function kn(r){if(typeof r!="string")throw Error("File/Blob fields are not yet supported in progressive forms. Will fallback to client hydration.")}function Ie(r,a){if(typeof a.$$FORM_ACTION=="function"){var p=r.nextFormID++;r=r.idPrefix+p;try{var k=a.$$FORM_ACTION(r);if(k){var B=k.data;B!=null&&B.forEach(kn)}return k}catch(j){if(typeof j=="object"&&j!==null&&typeof j.then=="function")throw j;console.error(`Failed to serialize an action for progressive enhancement:
81
+ %s`,j)}}return null}function ie(r,a,p,k,B,j,Y,Q){var ke=null;if(typeof k=="function"){Q===null||Hs||(Hs=!0,console.error('Cannot specify a "name" prop for a button that specifies a function as a formAction. React needs it to encode which action should be invoked. It will get overridden.')),B===null&&j===null||ci||(ci=!0,console.error("Cannot specify a formEncType or formMethod for a button that specifies a function as a formAction. React provides those automatically. They will get overridden.")),Y===null||Us||(Us=!0,console.error("Cannot specify a formTarget for a button that specifies a function as a formAction. The function will always be executed in the same window."));var re=Ie(a,k);re!==null?(Q=re.name,k=re.action||"",B=re.encType,j=re.method,Y=re.target,ke=re.data):(r.push(yt,"formAction",St,Yn,nt),Y=j=B=k=Q=null,Mo(a,p))}return Q!=null&&ot(r,"name",Q),k!=null&&ot(r,"formAction",k),B!=null&&ot(r,"formEncType",B),j!=null&&ot(r,"formMethod",j),Y!=null&&ot(r,"formTarget",Y),ke}function ot(r,a,p){switch(a){case"className":Ae(r,"class",p);break;case"tabIndex":Ae(r,"tabindex",p);break;case"dir":case"role":case"viewBox":case"width":case"height":Ae(r,a,p);break;case"style":Pe(r,p);break;case"src":case"href":if(p===""){console.error(a==="src"?'An empty string ("") was passed to the %s attribute. This may cause the browser to download the whole page again over the network. To fix this, either do not render the element at all or pass null to %s instead of an empty string.':'An empty string ("") was passed to the %s attribute. To fix this, either do not render the element at all or pass null to %s instead of an empty string.',a,a);break}case"action":case"formAction":if(p==null||typeof p=="function"||typeof p=="symbol"||typeof p=="boolean")break;O(p,a),p=q(""+p),r.push(yt,a,St,de(p),nt);break;case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"autoFocus":case"multiple":case"muted":ue(r,a.toLowerCase(),p);break;case"xlinkHref":if(typeof p=="function"||typeof p=="symbol"||typeof p=="boolean")break;O(p,a),p=q(""+p),r.push(yt,"xlink:href",St,de(p),nt);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":typeof p!="function"&&typeof p!="symbol"&&r.push(yt,a,St,de(p),nt);break;case"inert":p!==""||Ge[a]||(Ge[a]=!0,console.error("Received an empty string for a boolean attribute `%s`. This will treat the attribute as if it were false. Either pass `false` to silence this warning, or pass `true` if you used an empty string in earlier versions of React to indicate this attribute is true.",a));case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":p&&typeof p!="function"&&typeof p!="symbol"&&r.push(yt,a,Tt);break;case"capture":case"download":p===!0?r.push(yt,a,Tt):p!==!1&&typeof p!="function"&&typeof p!="symbol"&&r.push(yt,a,St,de(p),nt);break;case"cols":case"rows":case"size":case"span":typeof p!="function"&&typeof p!="symbol"&&!isNaN(p)&&1<=p&&r.push(yt,a,St,de(p),nt);break;case"rowSpan":case"start":typeof p=="function"||typeof p=="symbol"||isNaN(p)||r.push(yt,a,St,de(p),nt);break;case"xlinkActuate":Ae(r,"xlink:actuate",p);break;case"xlinkArcrole":Ae(r,"xlink:arcrole",p);break;case"xlinkRole":Ae(r,"xlink:role",p);break;case"xlinkShow":Ae(r,"xlink:show",p);break;case"xlinkTitle":Ae(r,"xlink:title",p);break;case"xlinkType":Ae(r,"xlink:type",p);break;case"xmlBase":Ae(r,"xml:base",p);break;case"xmlLang":Ae(r,"xml:lang",p);break;case"xmlSpace":Ae(r,"xml:space",p);break;default:if((!(2<a.length)||a[0]!=="o"&&a[0]!=="O"||a[1]!=="n"&&a[1]!=="N")&&(a=Bc.get(a)||a,D(a))){switch(typeof p){case"function":case"symbol":return;case"boolean":var k=a.toLowerCase().slice(0,5);if(k!=="data-"&&k!=="aria-")return}r.push(yt,a,St,de(p),nt)}}}function wn(r,a,p){if(a!=null){if(p!=null)throw Error("Can only set one of `children` or `props.dangerouslySetInnerHTML`.");if(typeof a!="object"||!("__html"in a))throw Error("`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://react.dev/link/dangerously-set-inner-html for more information.");a=a.__html,a!=null&&(M(a),r.push(""+a))}}function go(r,a){var p=r[a];p!=null&&(p=_l(p),r.multiple&&!p?console.error("The `%s` prop supplied to <select> must be an array if `multiple` is true.",a):!r.multiple&&p&&console.error("The `%s` prop supplied to <select> must be a scalar value if `multiple` is false.",a))}function vt(r){var a="";return Ic.Children.forEach(r,function(p){p!=null&&(a+=p,Er||typeof p=="string"||typeof p=="number"||typeof p=="bigint"||(Er=!0,console.error("Cannot infer the option value of complex children. Pass a `value` prop or use a plain string as children to <option>.")))}),a}function Mo(r,a){if((r.instructions&16)===f){r.instructions|=16;var p=a.preamble,k=a.bootstrapChunks;(p.htmlChunks||p.headChunks)&&k.length===0?(k.push(a.startInlineScript),kl(k,r),k.push(dt,Yi,ve)):k.unshift(a.startInlineScript,dt,Yi,ve)}}function Cn(r,a){r.push(Tn("link"));for(var p in a)if(wt.call(a,p)){var k=a[p];if(k!=null)switch(p){case"children":case"dangerouslySetInnerHTML":throw Error("link is a self-closing tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:ot(r,p,k)}}return r.push(as),null}function Bi(r){return M(r),(""+r).replace(ka,n)}function $r(r,a,p){r.push(Tn(p));for(var k in a)if(wt.call(a,k)){var B=a[k];if(B!=null)switch(k){case"children":case"dangerouslySetInnerHTML":throw Error(p+" is a self-closing tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:ot(r,k,B)}}return r.push(as),null}function po(r,a){r.push(Tn("title"));var p=null,k=null,B;for(B in a)if(wt.call(a,B)){var j=a[B];if(j!=null)switch(B){case"children":p=j;break;case"dangerouslySetInnerHTML":k=j;break;default:ot(r,B,j)}}return r.push(dt),a=Array.isArray(p)?2>p.length?p[0]:null:p,typeof a!="function"&&typeof a!="symbol"&&a!==null&&a!==void 0&&r.push(de(""+a)),wn(r,k,p),r.push(Wn("title")),null}function Sn(r,a){r.push(Tn("script"));var p=null,k=null,B;for(B in a)if(wt.call(a,B)){var j=a[B];if(j!=null)switch(B){case"children":p=j;break;case"dangerouslySetInnerHTML":k=j;break;default:ot(r,B,j)}}return r.push(dt),p!=null&&typeof p!="string"&&(a=typeof p=="number"?"a number for children":Array.isArray(p)?"an array for children":"something unexpected for children",console.error("A script element was rendered with %s. If script element has children it must be a single string. Consider using dangerouslySetInnerHTML or passing a plain string as children.",a)),wn(r,k,p),typeof p=="string"&&r.push(he(p)),r.push(Wn("script")),null}function Pi(r,a,p){r.push(Tn(p));var k=p=null,B;for(B in a)if(wt.call(a,B)){var j=a[B];if(j!=null)switch(B){case"children":p=j;break;case"dangerouslySetInnerHTML":k=j;break;default:ot(r,B,j)}}return r.push(dt),wn(r,k,p),p}function et(r,a,p){r.push(Tn(p));var k=p=null,B;for(B in a)if(wt.call(a,B)){var j=a[B];if(j!=null)switch(B){case"children":p=j;break;case"dangerouslySetInnerHTML":k=j;break;default:ot(r,B,j)}}return r.push(dt),wn(r,k,p),typeof p=="string"?(r.push(de(p)),null):p}function Tn(r){var a=ui.get(r);if(a===void 0){if(!vo.test(r))throw Error("Invalid tag: "+r);a="<"+r,ui.set(r,a)}return a}function _t(r,a,p,k,B,j,Y,Q,ke){ee(a,p),a!=="input"&&a!=="textarea"&&a!=="select"||p==null||p.value!==null||cl||(cl=!0,a==="select"&&p.multiple?console.error("`value` prop on `%s` should not be null. Consider using an empty array when `multiple` is set to `true` to clear the component or `undefined` for uncontrolled components.",a):console.error("`value` prop on `%s` should not be null. Consider using an empty string to clear the component or `undefined` for uncontrolled components.",a));e:if(a.indexOf("-")===-1)var re=!1;else switch(a){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":re=!1;break e;default:re=!0}switch(re||typeof p.is=="string"||Re(a,p),!p.suppressContentEditableWarning&&p.contentEditable&&p.children!=null&&console.error("A component is `contentEditable` and contains `children` managed by React. It is now your responsibility to guarantee that none of those nodes are unexpectedly modified or duplicated. This is probably not intentional."),Q.insertionMode!==Je&&Q.insertionMode!==tn&&a.indexOf("-")===-1&&a.toLowerCase()!==a&&console.error("<%s /> is using incorrect casing. Use PascalCase for React components, or lowercase for HTML elements.",a),a){case"div":case"span":case"svg":case"path":break;case"a":r.push(Tn("a"));var be=null,Ne=null,Oe;for(Oe in p)if(wt.call(p,Oe)){var Fe=p[Oe];if(Fe!=null)switch(Oe){case"children":be=Fe;break;case"dangerouslySetInnerHTML":Ne=Fe;break;case"href":Fe===""?Ae(r,"href",""):ot(r,Oe,Fe);break;default:ot(r,Oe,Fe)}}if(r.push(dt),wn(r,Ne,be),typeof be=="string"){r.push(de(be));var Se=null}else Se=be;return Se;case"g":case"p":case"li":break;case"select":K("select",p),go(p,"value"),go(p,"defaultValue"),p.value===void 0||p.defaultValue===void 0||vr||(console.error("Select elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled select element and remove one of these props. More info: https://react.dev/link/controlled-components"),vr=!0),r.push(Tn("select"));var ht=null,Yt=null,Ke;for(Ke in p)if(wt.call(p,Ke)){var At=p[Ke];if(At!=null)switch(Ke){case"children":ht=At;break;case"dangerouslySetInnerHTML":Yt=At;break;case"defaultValue":case"value":break;default:ot(r,Ke,At)}}return r.push(dt),wn(r,Yt,ht),ht;case"option":var io=Q.selectedValue;r.push(Tn("option"));var co=null,Pt=null,Xn=null,gl=null,Yo;for(Yo in p)if(wt.call(p,Yo)){var Ue=p[Yo];if(Ue!=null)switch(Yo){case"children":co=Ue;break;case"selected":Xn=Ue,Ml||(console.error("Use the `defaultValue` or `value` props on <select> instead of setting `selected` on <option>."),Ml=!0);break;case"dangerouslySetInnerHTML":gl=Ue;break;case"value":Pt=Ue;default:ot(r,Yo,Ue)}}if(io!=null){if(Pt!==null){O(Pt,"value");var Dt=""+Pt}else gl===null||ul||(ul=!0,console.error("Pass a `value` prop if you set dangerouslyInnerHTML so React knows which value should be selected.")),Dt=vt(co);if(_l(io)){for(var Ot=0;Ot<io.length;Ot++)if(O(io[Ot],"value"),""+io[Ot]===Dt){r.push(' selected=""');break}}else O(io,"select.value"),""+io===Dt&&r.push(' selected=""')}else Xn&&r.push(' selected=""');return r.push(dt),wn(r,gl,co),co;case"textarea":K("textarea",p),p.value===void 0||p.defaultValue===void 0||Rr||(console.error("Textarea elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled textarea and remove one of these props. More info: https://react.dev/link/controlled-components"),Rr=!0),r.push(Tn("textarea"));var zt=null,gn=null,bt=null,st;for(st in p)if(wt.call(p,st)){var Io=p[st];if(Io!=null)switch(st){case"children":bt=Io;break;case"value":zt=Io;break;case"defaultValue":gn=Io;break;case"dangerouslySetInnerHTML":throw Error("`dangerouslySetInnerHTML` does not make sense on <textarea>.");default:ot(r,st,Io)}}if(zt===null&&gn!==null&&(zt=gn),r.push(dt),bt!=null){if(console.error("Use the `defaultValue` or `value` props instead of setting children on <textarea>."),zt!=null)throw Error("If you supply `defaultValue` on a <textarea>, do not pass children.");if(_l(bt)){if(1<bt.length)throw Error("<textarea> can only have at most one child.");M(bt[0]),zt=""+bt[0]}M(bt),zt=""+bt}return typeof zt=="string"&&zt[0]===`
82
+ `&&r.push(is),zt!==null&&(O(zt,"value"),r.push(de(""+zt))),null;case"input":K("input",p),r.push(Tn("input"));var jt=null,uo=null,on=null,$o=null,Da=null,er=null,pl=null,xl=null,ml=null,eo;for(eo in p)if(wt.call(p,eo)){var o=p[eo];if(o!=null)switch(eo){case"children":case"dangerouslySetInnerHTML":throw Error("input is a self-closing tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");case"name":jt=o;break;case"formAction":uo=o;break;case"formEncType":on=o;break;case"formMethod":$o=o;break;case"formTarget":Da=o;break;case"defaultChecked":ml=o;break;case"defaultValue":pl=o;break;case"checked":xl=o;break;case"value":er=o;break;default:ot(r,eo,o)}}uo===null||p.type==="image"||p.type==="submit"||Un||(Un=!0,console.error('An input can only specify a formAction along with type="submit" or type="image".'));var l=ie(r,k,B,uo,on,$o,Da,jt);return xl===null||ml===null||yo||(console.error("%s contains an input of type %s with both checked and defaultChecked props. Input elements must be either controlled or uncontrolled (specify either the checked prop, or the defaultChecked prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://react.dev/link/controlled-components","A component",p.type),yo=!0),er===null||pl===null||Fl||(console.error("%s contains an input of type %s with both value and defaultValue props. Input elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://react.dev/link/controlled-components","A component",p.type),Fl=!0),xl!==null?ue(r,"checked",xl):ml!==null&&ue(r,"checked",ml),er!==null?ot(r,"value",er):pl!==null&&ot(r,"value",pl),r.push(as),l!=null&&l.forEach(He,r),null;case"button":r.push(Tn("button"));var g=null,E=null,I=null,F=null,G=null,Z=null,pe=null,te;for(te in p)if(wt.call(p,te)){var se=p[te];if(se!=null)switch(te){case"children":g=se;break;case"dangerouslySetInnerHTML":E=se;break;case"name":I=se;break;case"formAction":F=se;break;case"formEncType":G=se;break;case"formMethod":Z=se;break;case"formTarget":pe=se;break;default:ot(r,te,se)}}F===null||p.type==null||p.type==="submit"||Un||(Un=!0,console.error('A button can only specify a formAction along with type="submit" or no type.'));var Te=ie(r,k,B,F,G,Z,pe,I);if(r.push(dt),Te!=null&&Te.forEach(He,r),wn(r,E,g),typeof g=="string"){r.push(de(g));var _e=null}else _e=g;return _e;case"form":r.push(Tn("form"));var Be=null,Ce=null,Ze=null,Wt=null,Ye=null,ft=null,bn;for(bn in p)if(wt.call(p,bn)){var Ln=p[bn];if(Ln!=null)switch(bn){case"children":Be=Ln;break;case"dangerouslySetInnerHTML":Ce=Ln;break;case"action":Ze=Ln;break;case"encType":Wt=Ln;break;case"method":Ye=Ln;break;case"target":ft=Ln;break;default:ot(r,bn,Ln)}}var It=null,Ve=null;if(typeof Ze=="function"){Wt===null&&Ye===null||ci||(ci=!0,console.error("Cannot specify a encType or method for a form that specifies a function as the action. React provides those automatically. They will get overridden.")),ft===null||Us||(Us=!0,console.error("Cannot specify a target for a form that specifies a function as the action. The function will always be executed in the same window."));var Fn=Ie(k,Ze);Fn!==null?(Ze=Fn.action||"",Wt=Fn.encType,Ye=Fn.method,ft=Fn.target,It=Fn.data,Ve=Fn.name):(r.push(yt,"action",St,Yn,nt),ft=Ye=Wt=Ze=null,Mo(k,B))}if(Ze!=null&&ot(r,"action",Ze),Wt!=null&&ot(r,"encType",Wt),Ye!=null&&ot(r,"method",Ye),ft!=null&&ot(r,"target",ft),r.push(dt),Ve!==null&&(r.push('<input type="hidden"'),Ae(r,"name",Ve),r.push(as),It!=null&&It.forEach(He,r)),wn(r,Ce,Be),typeof Be=="string"){r.push(de(Be));var Bo=null}else Bo=Be;return Bo;case"menuitem":r.push(Tn("menuitem"));for(var Gt in p)if(wt.call(p,Gt)){var rn=p[Gt];if(rn!=null)switch(Gt){case"children":case"dangerouslySetInnerHTML":throw Error("menuitems cannot have `children` nor `dangerouslySetInnerHTML`.");default:ot(r,Gt,rn)}}return r.push(dt),null;case"object":r.push(Tn("object"));var tr=null,ho=null,Zn;for(Zn in p)if(wt.call(p,Zn)){var ln=p[Zn];if(ln!=null)switch(Zn){case"children":tr=ln;break;case"dangerouslySetInnerHTML":ho=ln;break;case"data":O(ln,"data");var zn=q(""+ln);if(zn===""){console.error('An empty string ("") was passed to the %s attribute. To fix this, either do not render the element at all or pass null to %s instead of an empty string.',Zn,Zn);break}r.push(yt,"data",St,de(zn),nt);break;default:ot(r,Zn,ln)}}if(r.push(dt),wn(r,ho,tr),typeof tr=="string"){r.push(de(tr));var nr=null}else nr=tr;return nr;case"title":var br=Q.tagScope&1,Kn=Q.tagScope&4;if(wt.call(p,"children")){var pn=p.children,Po=Array.isArray(pn)?2>pn.length?pn[0]:null:pn;Array.isArray(pn)&&1<pn.length?console.error("React expects the `children` prop of <title> tags to be a string, number, bigint, or object with a novel `toString` method but found an Array with length %s instead. Browsers treat all child Nodes of <title> tags as Text content and React expects to be able to convert `children` of <title> tags to a single string value which is why Arrays of length greater than 1 are not supported. When using JSX it can be common to combine text nodes and value nodes. For example: <title>hello {nameOfUser}</title>. While not immediately apparent, `children` in this case is an Array with length 2. If your `children` prop is using this form try rewriting it using a template string: <title>{`hello ${nameOfUser}`}</title>.",pn.length):typeof Po=="function"||typeof Po=="symbol"?console.error("React expect children of <title> tags to be a string, number, bigint, or object with a novel `toString` method but found %s instead. Browsers treat all child Nodes of <title> tags as Text content and React expects to be able to convert children of <title> tags to a single string value.",typeof Po=="function"?"a Function":"a Sybmol"):Po&&Po.toString==={}.toString&&(Po.$$typeof!=null?console.error("React expects the `children` prop of <title> tags to be a string, number, bigint, or object with a novel `toString` method but found an object that appears to be a React element which never implements a suitable `toString` method. Browsers treat all child Nodes of <title> tags as Text content and React expects to be able to convert children of <title> tags to a single string value which is why rendering React elements is not supported. If the `children` of <title> is a React Component try moving the <title> tag into that component. If the `children` of <title> is some HTML markup change it to be Text only to be valid HTML."):console.error("React expects the `children` prop of <title> tags to be a string, number, bigint, or object with a novel `toString` method but found an object that does not implement a suitable `toString` method. Browsers treat all child Nodes of <title> tags as Text content and React expects to be able to convert children of <title> tags to a single string value. Using the default `toString` method available on every object is almost certainly an error. Consider whether the `children` of this <title> is an object in error and change it to a string or number value if so. Otherwise implement a `toString` method that React can use to produce a valid <title>."))}if(Q.insertionMode===Je||br||p.itemProp!=null)var or=po(r,p);else Kn?or=null:(po(B.hoistableChunks,p),or=void 0);return or;case"link":var _o=Q.tagScope&1,Gl=Q.tagScope&4,rr=p.rel,Mn=p.href,Br=p.precedence;if(Q.insertionMode===Je||_o||p.itemProp!=null||typeof rr!="string"||typeof Mn!="string"||Mn===""){rr==="stylesheet"&&typeof p.precedence=="string"&&(typeof Mn=="string"&&Mn||console.error('React encountered a `<link rel="stylesheet" .../>` with a `precedence` prop and expected the `href` prop to be a non-empty string but ecountered %s instead. If your intent was to have React hoist and deduplciate this stylesheet using the `precedence` prop ensure there is a non-empty string `href` prop as well, otherwise remove the `precedence` prop.',Mn===null?"`null`":Mn===void 0?"`undefined`":Mn===""?"an empty string":'something with type "'+typeof Mn+'"')),Cn(r,p);var to=null}else if(p.rel==="stylesheet")if(typeof Br!="string"||p.disabled!=null||p.onLoad||p.onError){if(typeof Br=="string"){if(p.disabled!=null)console.error('React encountered a `<link rel="stylesheet" .../>` with a `precedence` prop and a `disabled` prop. The presence of the `disabled` prop indicates an intent to manage the stylesheet active state from your from your Component code and React will not hoist or deduplicate this stylesheet. If your intent was to have React hoist and deduplciate this stylesheet using the `precedence` prop remove the `disabled` prop, otherwise remove the `precedence` prop.');else if(p.onLoad||p.onError){var Wc=p.onLoad&&p.onError?"`onLoad` and `onError` props":p.onLoad?"`onLoad` prop":"`onError` prop";console.error('React encountered a `<link rel="stylesheet" .../>` with a `precedence` prop and %s. The presence of loading and error handlers indicates an intent to manage the stylesheet loading state from your from your Component code and React will not hoist or deduplicate this stylesheet. If your intent was to have React hoist and deduplciate this stylesheet using the `precedence` prop remove the %s, otherwise remove the `precedence` prop.',Wc,Wc)}}to=Cn(r,p)}else{var bl=B.styles.get(Br),yn=k.styleResources.hasOwnProperty(Mn)?k.styleResources[Mn]:void 0;if(yn!==J){k.styleResources[Mn]=J,bl||(bl={precedence:de(Br),rules:[],hrefs:[],sheets:new Map},B.styles.set(Br,bl));var Pr={state:P,props:en({},p,{"data-precedence":p.precedence,precedence:null})};if(yn){yn.length===2&&ws(Pr.props,yn);var Lo=B.preloads.stylesheets.get(Mn);Lo&&0<Lo.length?Lo.length=0:Pr.state=H}bl.sheets.set(Mn,Pr),Y&&Y.stylesheets.add(Pr)}else if(bl){var ki=bl.sheets.get(Mn);ki&&Y&&Y.stylesheets.add(ki)}ke&&r.push("<!-- -->"),to=null}else p.onLoad||p.onError?to=Cn(r,p):(ke&&r.push("<!-- -->"),to=Gl?null:Cn(B.hoistableChunks,p));return to;case"script":var Oa=Q.tagScope&1,Qr=p.async;if(typeof p.src!="string"||!p.src||!Qr||typeof Qr=="function"||typeof Qr=="symbol"||p.onLoad||p.onError||Q.insertionMode===Je||Oa||p.itemProp!=null)var ja=Sn(r,p);else{var lr=p.src;if(p.type==="module")var wi=k.moduleScriptResources,Gc=B.preloads.moduleScripts;else wi=k.scriptResources,Gc=B.preloads.scripts;var _r=wi.hasOwnProperty(lr)?wi[lr]:void 0;if(_r!==J){wi[lr]=J;var Ci=p;if(_r){_r.length===2&&(Ci=en({},p),ws(Ci,_r));var Fo=Gc.get(lr);Fo&&(Fo.length=0)}var Ha=[];B.scripts.add(Ha),Sn(Ha,Ci)}ke&&r.push("<!-- -->"),ja=null}return ja;case"style":var ra=Q.tagScope&1;if(wt.call(p,"children")){var ys=p.children,Nr=Array.isArray(ys)?2>ys.length?ys[0]:null:ys;(typeof Nr=="function"||typeof Nr=="symbol"||Array.isArray(Nr))&&console.error("React expect children of <style> tags to be a string, number, or object with a `toString` method but found %s instead. In browsers style Elements can only have `Text` Nodes as children.",typeof Nr=="function"?"a Function":typeof Nr=="symbol"?"a Sybmol":"an Array")}var Lr=p.precedence,yl=p.href,sr=p.nonce;if(Q.insertionMode===Je||ra||p.itemProp!=null||typeof Lr!="string"||typeof yl!="string"||yl===""){r.push(Tn("style"));var fo=null,vs=null,vl;for(vl in p)if(wt.call(p,vl)){var la=p[vl];if(la!=null)switch(vl){case"children":fo=la;break;case"dangerouslySetInnerHTML":vs=la;break;default:ot(r,vl,la)}}r.push(dt);var Vl=Array.isArray(fo)?2>fo.length?fo[0]:null:fo;typeof Vl!="function"&&typeof Vl!="symbol"&&Vl!==null&&Vl!==void 0&&r.push(Bi(Vl)),wn(r,vs,fo),r.push(Wn("style"));var mu=null}else{yl.includes(" ")&&console.error('React expected the `href` prop for a <style> tag opting into hoisting semantics using the `precedence` prop to not have any spaces but ecountered spaces instead. using spaces in this prop will cause hydration of this style to fail on the client. The href for the <style> where this ocurred is "%s".',yl);var Xo=B.styles.get(Lr),qr=k.styleResources.hasOwnProperty(yl)?k.styleResources[yl]:void 0;if(qr!==J){k.styleResources[yl]=J,qr&&console.error('React encountered a hoistable style tag for the same href as a preload: "%s". When using a style tag to inline styles you should not also preload it as a stylsheet.',yl),Xo||(Xo={precedence:de(Lr),rules:[],hrefs:[],sheets:new Map},B.styles.set(Lr,Xo));var Si=B.nonce.style;if(Si&&Si!==sr)console.error('React encountered a style tag with `precedence` "%s" and `nonce` "%s". When React manages style rules using `precedence` it will only include rules if the nonce matches the style nonce "%s" that was included with this render.',Lr,sr,Si);else{!Si&&sr&&console.error('React encountered a style tag with `precedence` "%s" and `nonce` "%s". When React manages style rules using `precedence` it will only include a nonce attributes if you also provide the same style nonce value as a render option.',Lr,sr),Xo.hrefs.push(de(yl));var dc=Xo.rules,hc=null,ju=null,sa;for(sa in p)if(wt.call(p,sa)){var Ua=p[sa];if(Ua!=null)switch(sa){case"children":hc=Ua;break;case"dangerouslySetInnerHTML":ju=Ua}}var aa=Array.isArray(hc)?2>hc.length?hc[0]:null:hc;typeof aa!="function"&&typeof aa!="symbol"&&aa!==null&&aa!==void 0&&dc.push(Bi(aa)),wn(dc,ju,hc)}}Xo&&Y&&Y.styles.add(Xo),ke&&r.push("<!-- -->"),mu=void 0}return mu;case"meta":var fc=Q.tagScope&1,Nu=Q.tagScope&4;if(Q.insertionMode===Je||fc||p.itemProp!=null)var Cu=$r(r,p,"meta");else ke&&r.push("<!-- -->"),Cu=Nu?null:typeof p.charSet=="string"?$r(B.charsetChunks,p,"meta"):p.name==="viewport"?$r(B.viewportChunks,p,"meta"):$r(B.hoistableChunks,p,"meta");return Cu;case"listing":case"pre":r.push(Tn(a));var Zo=null,Rl=null,ia;for(ia in p)if(wt.call(p,ia)){var Vc=p[ia];if(Vc!=null)switch(ia){case"children":Zo=Vc;break;case"dangerouslySetInnerHTML":Rl=Vc;break;default:ot(r,ia,Vc)}}if(r.push(dt),Rl!=null){if(Zo!=null)throw Error("Can only set one of `children` or `props.dangerouslySetInnerHTML`.");if(typeof Rl!="object"||!("__html"in Rl))throw Error("`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://react.dev/link/dangerously-set-inner-html for more information.");var Fr=Rl.__html;Fr!=null&&(typeof Fr=="string"&&0<Fr.length&&Fr[0]===`
83
+ `?r.push(is,Fr):(M(Fr),r.push(""+Fr)))}return typeof Zo=="string"&&Zo[0]===`
84
+ `&&r.push(is),Zo;case"img":var Dn=Q.tagScope&3,xn=p.src,Jt=p.srcSet;if(!(p.loading==="lazy"||!xn&&!Jt||typeof xn!="string"&&xn!=null||typeof Jt!="string"&&Jt!=null||p.fetchPriority==="low"||Dn)&&(typeof xn!="string"||xn[4]!==":"||xn[0]!=="d"&&xn[0]!=="D"||xn[1]!=="a"&&xn[1]!=="A"||xn[2]!=="t"&&xn[2]!=="T"||xn[3]!=="a"&&xn[3]!=="A")&&(typeof Jt!="string"||Jt[4]!==":"||Jt[0]!=="d"&&Jt[0]!=="D"||Jt[1]!=="a"&&Jt[1]!=="A"||Jt[2]!=="t"&&Jt[2]!=="T"||Jt[3]!=="a"&&Jt[3]!=="A")){Y!==null&&Q.tagScope&64&&(Y.suspenseyImages=!0);var Su=typeof p.sizes=="string"?p.sizes:void 0,za=Jt?Jt+`
85
+ `+(Su||""):xn,Yc=B.preloads.images,Wa=Yc.get(za);if(Wa)(p.fetchPriority==="high"||10>B.highImagePreloads.size)&&(Yc.delete(za),B.highImagePreloads.add(Wa));else if(!k.imageResources.hasOwnProperty(za)){k.imageResources[za]=ce;var Ti=p.crossOrigin,Xc=typeof Ti=="string"?Ti==="use-credentials"?Ti:"":void 0,Ai=B.headers,gc;Ai&&0<Ai.remainingCapacity&&typeof p.srcSet!="string"&&(p.fetchPriority==="high"||500>Ai.highImagePreloads.length)&&(gc=Va(xn,"image",{imageSrcSet:p.srcSet,imageSizes:p.sizes,crossOrigin:Xc,integrity:p.integrity,nonce:p.nonce,type:p.type,fetchPriority:p.fetchPriority,referrerPolicy:p.refererPolicy}),0<=(Ai.remainingCapacity-=gc.length+2))?(B.resets.image[za]=ce,Ai.highImagePreloads&&(Ai.highImagePreloads+=", "),Ai.highImagePreloads+=gc):(Wa=[],Cn(Wa,{rel:"preload",as:"image",href:Jt?void 0:xn,imageSrcSet:Jt,imageSizes:Su,crossOrigin:Xc,integrity:p.integrity,type:p.type,fetchPriority:p.fetchPriority,referrerPolicy:p.referrerPolicy}),p.fetchPriority==="high"||10>B.highImagePreloads.size?B.highImagePreloads.add(Wa):(B.bulkPreloads.add(Wa),Yc.set(za,Wa)))}}return $r(r,p,"img");case"base":case"area":case"br":case"col":case"embed":case"hr":case"keygen":case"param":case"source":case"track":case"wbr":return $r(r,p,a);case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":break;case"head":if(Q.insertionMode<Xe){var pc=j||B.preamble;if(pc.headChunks)throw Error("The `<head>` tag may only be rendered once.");j!==null&&r.push("<!--head-->"),pc.headChunks=[];var bu=Pi(pc.headChunks,p,"head")}else bu=et(r,p,"head");return bu;case"body":if(Q.insertionMode<Xe){var Tu=j||B.preamble;if(Tu.bodyChunks)throw Error("The `<body>` tag may only be rendered once.");j!==null&&r.push("<!--body-->"),Tu.bodyChunks=[];var Lu=Pi(Tu.bodyChunks,p,"body")}else Lu=et(r,p,"body");return Lu;case"html":if(Q.insertionMode===at){var Zc=j||B.preamble;if(Zc.htmlChunks)throw Error("The `<html>` tag may only be rendered once.");j!==null&&r.push("<!--html-->"),Zc.htmlChunks=[fe];var Kc=Pi(Zc.htmlChunks,p,"html")}else Kc=et(r,p,"html");return Kc;default:if(a.indexOf("-")!==-1){r.push(Tn(a));var Ii=null,ca=null,Rs;for(Rs in p)if(wt.call(p,Rs)){var ar=p[Rs];if(ar!=null){var xc=Rs;switch(Rs){case"children":Ii=ar;break;case"dangerouslySetInnerHTML":ca=ar;break;case"style":Pe(r,ar);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"className":xc="class";default:if(D(Rs)&&typeof ar!="function"&&typeof ar!="symbol"&&ar!==!1){if(ar===!0)ar="";else if(typeof ar=="object")continue;r.push(yt,xc,St,de(ar),nt)}}}}return r.push(dt),wn(r,ca,Ii),Ii}}return et(r,p,a)}function Wn(r){var a=Ro.get(r);return a===void 0&&(a="</"+r+">",Ro.set(r,a)),a}function Es(r,a){r=r.preamble,r.htmlChunks===null&&a.htmlChunks&&(r.htmlChunks=a.htmlChunks),r.headChunks===null&&a.headChunks&&(r.headChunks=a.headChunks),r.bodyChunks===null&&a.bodyChunks&&(r.bodyChunks=a.bodyChunks)}function Xl(r,a){a=a.bootstrapChunks;for(var p=0;p<a.length-1;p++)r.push(a[p]);return p<a.length?(p=a[p],a.length=0,r.push(p)):!0}function Jn(r,a,p){if(r.push(Xi),p===null)throw Error("An ID must have been assigned before we can complete the boundary.");return r.push(a.boundaryPrefix),a=p.toString(16),r.push(a),r.push(Pn)}function Do(r,a,p,k){switch(p.insertionMode){case at:case Qe:case tt:case Xe:return r.push(us),r.push(a.segmentPrefix),a=k.toString(16),r.push(a),r.push(dn);case Je:return r.push(ds),r.push(a.segmentPrefix),a=k.toString(16),r.push(a),r.push(Ws);case tn:return r.push(so),r.push(a.segmentPrefix),a=k.toString(16),r.push(a),r.push(Sa);case ct:return r.push(Nc),r.push(a.segmentPrefix),a=k.toString(16),r.push(a),r.push(Gs);case mt:return r.push(Zi),r.push(a.segmentPrefix),a=k.toString(16),r.push(a),r.push(Ki);case Bt:return r.push(Vs),r.push(a.segmentPrefix),a=k.toString(16),r.push(a),r.push(Ys);case lt:return r.push(gi),r.push(a.segmentPrefix),a=k.toString(16),r.push(a),r.push(pi);default:throw Error("Unknown insertion mode. This is a bug in React.")}}function Mr(r,a){switch(a.insertionMode){case at:case Qe:case tt:case Xe:return r.push(Wo);case Je:return r.push(kr);case tn:return r.push(Eo);case ct:return r.push(fi);case mt:return r.push(dl);case Bt:return r.push(ko);case lt:return r.push(Lc);default:throw Error("Unknown insertion mode. This is a bug in React.")}}function On(r){return JSON.stringify(r).replace(Ta,function(a){switch(a){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}function Dr(r){return JSON.stringify(r).replace(fs,function(a){switch(a){case"&":return"\\u0026";case">":return"\\u003e";case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSObjectForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}function _i(r){var a=r.rules,p=r.hrefs;0<a.length&&p.length===0&&console.error("React expected to have at least one href for an a hoistable style but found none. This is a bug in React.");var k=0;if(p.length){for(this.push(we.startInlineStyle),this.push(yi),this.push(r.precedence),this.push(gs);k<p.length-1;k++)this.push(p[k]),this.push(Cr);for(this.push(p[k]),this.push(iu),k=0;k<a.length;k++)this.push(a[k]);Aa=this.push(cu),Xr=!0,a.length=0,p.length=0}}function Rt(r){return r.state!==W?Xr=!0:!1}function xo(r,a,p){return Xr=!1,Aa=!0,we=p,a.styles.forEach(_i,r),we=null,a.stylesheets.forEach(Rt),Xr&&(p.stylesToHoist=!0),Aa}function Vt(r){for(var a=0;a<r.length;a++)this.push(r[a]);r.length=0}function Jc(r){Cn(xr,r.props);for(var a=0;a<xr.length;a++)this.push(xr[a]);xr.length=0,r.state=W}function vn(r){var a=0<r.sheets.size;r.sheets.forEach(Jc,this),r.sheets.clear();var p=r.rules,k=r.hrefs;if(!a||k.length){if(this.push(we.startInlineStyle),this.push(ps),this.push(r.precedence),r=0,k.length){for(this.push(Zs);r<k.length-1;r++)this.push(k[r]),this.push(Cr);this.push(k[r])}for(this.push(jc),r=0;r<p.length;r++)this.push(p[r]);this.push(uu),p.length=0,k.length=0}}function bc(r){if(r.state===P){r.state=H;var a=r.props;for(Cn(xr,{rel:"preload",as:"style",href:r.props.href,crossOrigin:a.crossOrigin,fetchPriority:a.fetchPriority,integrity:a.integrity,media:a.media,hrefLang:a.hrefLang,referrerPolicy:a.referrerPolicy}),r=0;r<xr.length;r++)this.push(xr[r]);xr.length=0}}function yc(r){r.sheets.forEach(bc,this),r.sheets.clear()}function kl(r,a){(a.instructions&V)===f&&(a.instructions|=V,r.push(Ia,de("_"+a.idPrefix+"R_"),nt))}function vc(r,a){r.push(i);var p=i;a.stylesheets.forEach(function(k){if(k.state!==W)if(k.state===ne)r.push(p),k=k.props.href,O(k,"href"),k=Dr(""+k),r.push(k),r.push(C),p=h;else{r.push(p);var B=k.props["data-precedence"],j=k.props,Y=q(""+k.props.href);Y=Dr(Y),r.push(Y),O(B,"precedence"),B=""+B,r.push(m),B=Dr(B),r.push(B);for(var Q in j)if(wt.call(j,Q)&&(B=j[Q],B!=null))switch(Q){case"href":case"rel":case"precedence":case"data-precedence":break;case"children":case"dangerouslySetInnerHTML":throw Error("link is a self-closing tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:Ga(r,Q,B)}r.push(C),p=h,k.state=ne}}),r.push(C)}function Ga(r,a,p){var k=a.toLowerCase();switch(typeof p){case"function":case"symbol":return}switch(a){case"innerHTML":case"dangerouslySetInnerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"style":case"ref":return;case"className":k="class",O(p,k),a=""+p;break;case"hidden":if(p===!1)return;a="";break;case"src":case"href":p=q(p),O(p,k),a=""+p;break;default:if(2<a.length&&(a[0]==="o"||a[0]==="O")&&(a[1]==="n"||a[1]==="N")||!D(a))return;O(p,k),a=""+p}r.push(m),k=Dr(k),r.push(k),r.push(m),k=Dr(a),r.push(k)}function ks(){return{styles:new Set,stylesheets:new Set,suspenseyImages:!1}}function Zl(r,a,p,k){(r.scriptResources.hasOwnProperty(p)||r.moduleScriptResources.hasOwnProperty(p))&&console.error('Internal React Error: React expected bootstrap script or module with src "%s" to not have been preloaded already. please file an issue',p),r.scriptResources[p]=J,r.moduleScriptResources[p]=J,r=[],Cn(r,k),a.bootstrapScripts.add(r)}function ws(r,a){r.crossOrigin==null&&(r.crossOrigin=a[0]),r.integrity==null&&(r.integrity=a[1])}function Va(r,a,p){r=sn(r),a=Ni(a,"as"),a="<"+r+'>; rel=preload; as="'+a+'"';for(var k in p)wt.call(p,k)&&(r=p[k],typeof r=="string"&&(a+="; "+k.toLowerCase()+'="'+Ni(r,k)+'"'));return a}function sn(r){return O(r,"href"),(""+r).replace(X,Qt)}function Qt(r){switch(r){case"<":return"%3C";case">":return"%3E";case`
86
+ `:return"%0A";case"\r":return"%0D";default:throw Error("escapeLinkHrefForHeaderContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}function Ni(r,a){return L(r)&&(console.error("The provided `%s` option is an unsupported type %s. This value must be coerced to a string before using it here.",a,A(r)),T(r)),(""+r).replace(oe,Cs)}function Cs(r){switch(r){case'"':return"%22";case"'":return"%27";case";":return"%3B";case",":return"%2C";case`
87
+ `:return"%0A";case"\r":return"%0D";default:throw Error("escapeStringForLinkHeaderQuotedParamValueContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}function Qc(r){this.styles.add(r)}function Rc(r){this.stylesheets.add(r)}function yr(r,a){a.styles.forEach(Qc,r),a.stylesheets.forEach(Rc,r),a.suspenseyImages&&(r.suspenseyImages=!0)}function el(r,a){var p=r.idPrefix,k=[],B=r.bootstrapScriptContent,j=r.bootstrapScripts,Y=r.bootstrapModules;if(B!==void 0&&(k.push("<script"),kl(k,r),k.push(dt,he(B),ve)),p={placeholderPrefix:p+"P:",segmentPrefix:p+"S:",boundaryPrefix:p+"B:",startInlineScript:"<script",startInlineStyle:"<style",preamble:{htmlChunks:null,headChunks:null,bodyChunks:null},externalRuntimeScript:null,bootstrapChunks:k,importMapChunks:[],onHeaders:void 0,headers:null,resets:{font:{},dns:{},connect:{default:{},anonymous:{},credentials:{}},image:{},style:{}},charsetChunks:[],viewportChunks:[],hoistableChunks:[],preconnects:new Set,fontPreloads:new Set,highImagePreloads:new Set,styles:new Map,bootstrapScripts:new Set,scripts:new Set,bulkPreloads:new Set,preloads:{images:new Map,stylesheets:new Map,scripts:new Map,moduleScripts:new Map},nonce:{script:void 0,style:void 0},hoistableState:null,stylesToHoist:!1},j!==void 0)for(B=0;B<j.length;B++){var Q=j[B],ke,re=void 0,be=void 0,Ne={rel:"preload",as:"script",fetchPriority:"low",nonce:void 0};typeof Q=="string"?Ne.href=ke=Q:(Ne.href=ke=Q.src,Ne.integrity=be=typeof Q.integrity=="string"?Q.integrity:void 0,Ne.crossOrigin=re=typeof Q=="string"||Q.crossOrigin==null?void 0:Q.crossOrigin==="use-credentials"?"use-credentials":""),Zl(r,p,ke,Ne),k.push('<script src="',de(ke),nt),typeof be=="string"&&k.push(' integrity="',de(be),nt),typeof re=="string"&&k.push(' crossorigin="',de(re),nt),kl(k,r),k.push(' async=""><\/script>')}if(Y!==void 0)for(j=0;j<Y.length;j++)B=Y[j],re=ke=void 0,be={rel:"modulepreload",fetchPriority:"low",nonce:void 0},typeof B=="string"?be.href=Q=B:(be.href=Q=B.src,be.integrity=re=typeof B.integrity=="string"?B.integrity:void 0,be.crossOrigin=ke=typeof B=="string"||B.crossOrigin==null?void 0:B.crossOrigin==="use-credentials"?"use-credentials":""),Zl(r,p,Q,be),k.push('<script type="module" src="',de(Q),nt),typeof re=="string"&&k.push(' integrity="',de(re),nt),typeof ke=="string"&&k.push(' crossorigin="',de(ke),nt),kl(k,r),k.push(' async=""><\/script>');return{placeholderPrefix:p.placeholderPrefix,segmentPrefix:p.segmentPrefix,boundaryPrefix:p.boundaryPrefix,startInlineScript:p.startInlineScript,startInlineStyle:p.startInlineStyle,preamble:p.preamble,externalRuntimeScript:p.externalRuntimeScript,bootstrapChunks:p.bootstrapChunks,importMapChunks:p.importMapChunks,onHeaders:p.onHeaders,headers:p.headers,resets:p.resets,charsetChunks:p.charsetChunks,viewportChunks:p.viewportChunks,hoistableChunks:p.hoistableChunks,preconnects:p.preconnects,fontPreloads:p.fontPreloads,highImagePreloads:p.highImagePreloads,styles:p.styles,bootstrapScripts:p.bootstrapScripts,scripts:p.scripts,bulkPreloads:p.bulkPreloads,preloads:p.preloads,nonce:p.nonce,stylesToHoist:p.stylesToHoist,generateStaticMarkup:a}}function qc(r,a,p,k){return p.generateStaticMarkup?(r.push(de(a)),!1):(a===""?r=k:(k&&r.push("<!-- -->"),r.push(de(a)),r=!0),r)}function Ss(r,a,p,k){a.generateStaticMarkup||p&&k&&r.push("<!-- -->")}function mn(r){if(r==null)return null;if(typeof r=="function")return r.$$typeof===De?null:r.displayName||r.name||null;if(typeof r=="string")return r;switch(r){case il:return"Fragment";case ri:return"Profiler";case oi:return"StrictMode";case Jo:return"Suspense";case hr:return"SuspenseList";case Gr:return"Activity"}if(typeof r=="object")switch(typeof r.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),r.$$typeof){case Bn:return"Portal";case ur:return r.displayName||"Context";case Hi:return(r._context.displayName||"Context")+".Consumer";case dr:var a=r.render;return r=r.displayName,r||(r=a.displayName||a.name||"",r=r!==""?"ForwardRef("+r+")":"ForwardRef"),r;case Ut:return a=r.displayName||null,a!==null?a:mn(r.type)||"Memo";case fr:a=r._payload,r=r._init;try{return mn(r(a))}catch{}}return null}function Kl(r,a){if(r!==a){r.context._currentValue2=r.parentValue,r=r.parent;var p=a.parent;if(r===null){if(p!==null)throw Error("The stacks must reach the root at the same time. This is a bug in React.")}else{if(p===null)throw Error("The stacks must reach the root at the same time. This is a bug in React.");Kl(r,p)}a.context._currentValue2=a.value}}function Jl(r){r.context._currentValue2=r.parentValue,r=r.parent,r!==null&&Jl(r)}function Ts(r){var a=r.parent;a!==null&&Ts(a),r.context._currentValue2=r.value}function no(r,a){if(r.context._currentValue2=r.parentValue,r=r.parent,r===null)throw Error("The depth must equal at least at zero before reaching the root. This is a bug in React.");r.depth===a.depth?Kl(r,a):no(r,a)}function Ko(r,a){var p=a.parent;if(p===null)throw Error("The depth must equal at least at zero before reaching the root. This is a bug in React.");r.depth===p.depth?Kl(r,p):Ko(r,p),a.context._currentValue2=a.value}function Ht(r){var a=qe;a!==r&&(a===null?Ts(r):r===null?Jl(a):a.depth===r.depth?Kl(a,r):a.depth>r.depth?no(a,r):Ko(a,r),qe=r)}function Ya(r){if(r!==null&&typeof r!="function"){var a=String(r);Hl.has(a)||(Hl.add(a),console.error("Expected the last optional `callback` argument to be a function. Instead received: %s.",r))}}function ir(r,a){r=(r=r.constructor)&&mn(r)||"ReactClass";var p=r+"."+a;xt[p]||(console.error(`Can only update a mounting component. This usually means you called %s() outside componentWillMount() on the server. This is a no-op.
88
+
89
+ Please check the code for the %s component.`,a,r),xt[p]=!0)}function Et(r,a,p){var k=r.id;r=r.overflow;var B=32-Tr(k)-1;k&=~(1<<B),p+=1;var j=32-Tr(a)+B;if(30<j){var Y=B-B%5;return j=(k&(1<<Y)-1).toString(32),k>>=Y,B-=Y,{id:1<<32-Tr(a)+B|p<<B|k,overflow:j+r}}return{id:1<<j|p<<B|k,overflow:r}}function $c(r){return r>>>=0,r===0?32:31-(Co(r)/Zr|0)|0}function gt(){}function Xa(r,a,p){switch(p=r[p],p===void 0?r.push(a):p!==a&&(a.then(gt,gt),a=p),a.status){case"fulfilled":return a.value;case"rejected":throw a.reason;default:switch(typeof a.status=="string"?a.then(gt,gt):(r=a,r.status="pending",r.then(function(k){if(a.status==="pending"){var B=a;B.status="fulfilled",B.value=k}},function(k){if(a.status==="pending"){var B=a;B.status="rejected",B.reason=k}})),a.status){case"fulfilled":return a.value;case"rejected":throw a.reason}throw Js=a,So}}function Za(){if(Js===null)throw Error("Expected a suspended thenable. This is a bug in React. Please file an issue.");var r=Js;return Js=null,r}function Ka(r,a){return r===a&&(r!==0||1/r===1/a)||r!==r&&a!==a}function tl(){if(Vo===null)throw Error(`Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
90
+ 1. You might have mismatching versions of React and the renderer (such as React DOM)
91
+ 2. You might be breaking the Rules of Hooks
92
+ 3. You might have more than one copy of React in the same app
93
+ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.`);return hl&&console.error("Do not call Hooks inside useEffect(...), useMemo(...), or other built-in Hooks. You can only call Hooks at the top level of your React function. For more information, see https://react.dev/link/rules-of-hooks"),Vo}function Ft(){if(0<rc)throw Error("Rendered more hooks than during the previous render");return{memoizedState:null,queue:null,next:null}}function kt(){return nn===null?Hc===null?(_a=!1,Hc=nn=Ft()):(_a=!0,nn=Hc):nn.next===null?(_a=!1,nn=nn.next=Ft()):(_a=!0,nn=nn.next),nn}function Or(){var r=Na;return Na=null,r}function oo(){hl=!1,Qs=To=Pa=Vo=null,Kr=!1,Hc=null,rc=0,nn=xs=null}function As(r){return hl&&console.error("Context can only be read while React is rendering. In classes, you can read it in the render method or getDerivedStateFromProps. In function components, you can read it directly in the function body, but not inside Hooks like useReducer() or useMemo()."),r._currentValue2}function Li(r,a){return typeof a=="function"?a(r):a}function mo(r,a,p){if(r!==Li&&($s="useReducer"),Vo=tl(),nn=kt(),_a){if(p=nn.queue,a=p.dispatch,xs!==null){var k=xs.get(p);if(k!==void 0){xs.delete(p),p=nn.memoizedState;do{var B=k.action;hl=!0,p=r(p,B),hl=!1,k=k.next}while(k!==null);return nn.memoizedState=p,[p,a]}}return[nn.memoizedState,a]}return hl=!0,r=r===Li?typeof a=="function"?a():a:p!==void 0?p(a):a,hl=!1,nn.memoizedState=r,r=nn.queue={last:null,dispatch:null},r=r.dispatch=Ec.bind(null,Vo,r),[nn.memoizedState,r]}function eu(r,a){if(Vo=tl(),nn=kt(),a=a===void 0?null:a,nn!==null){var p=nn.memoizedState;if(p!==null&&a!==null){e:{var k=p[1];if(k===null)console.error("%s received a final argument during this render, but not during the previous render. Even though the final argument is optional, its type cannot change between renders.",$s),k=!1;else{a.length!==k.length&&console.error(`The final argument passed to %s changed size between renders. The order and size of this array must remain constant.
94
+
95
+ Previous: %s
96
+ Incoming: %s`,$s,"["+a.join(", ")+"]","["+k.join(", ")+"]");for(var B=0;B<k.length&&B<a.length;B++)if(!Ba(a[B],k[B])){k=!1;break e}k=!0}}if(k)return p[0]}}return hl=!0,r=r(),hl=!1,nn.memoizedState=[r,a],r}function Ec(r,a,p){if(25<=rc)throw Error("Too many re-renders. React limits the number of renders to prevent an infinite loop.");if(r===Vo)if(Kr=!0,r={action:p,next:null},xs===null&&(xs=new Map),p=xs.get(a),p===void 0)xs.set(a,r);else{for(a=p;a.next!==null;)a=a.next;a.next=r}}function Fi(){throw Error("A function wrapped in useEffectEvent can't be called during rendering.")}function qt(){throw Error("startTransition cannot be called during server rendering.")}function Mi(){throw Error("Cannot update optimistic state while rendering.")}function ua(r,a,p){tl();var k=qs++,B=To;if(typeof r.$$FORM_ACTION=="function"){var j=null,Y=Qs;B=B.formState;var Q=r.$$IS_SIGNATURE_EQUAL;if(B!==null&&typeof Q=="function"){var ke=B[1];Q.call(r,B[2],B[3])&&(j=p!==void 0?"p"+p:"k"+_(JSON.stringify([Y,null,k]),0),ke===j&&(nc=k,a=B[0]))}var re=r.bind(null,a);return r=function(Ne){re(Ne)},typeof re.$$FORM_ACTION=="function"&&(r.$$FORM_ACTION=function(Ne){Ne=re.$$FORM_ACTION(Ne),p!==void 0&&(O(p,"target"),p+="",Ne.action=p);var Oe=Ne.data;return Oe&&(j===null&&(j=p!==void 0?"p"+p:"k"+_(JSON.stringify([Y,null,k]),0)),Oe.append("$ACTION_KEY",j)),Ne}),[a,r,!1]}var be=r.bind(null,a);return[a,function(Ne){be(Ne)},!1]}function cr(r){var a=oc;return oc+=1,Na===null&&(Na=[]),Xa(Na,r,a)}function Is(){throw Error("Cache cannot be refreshed during server rendering.")}function tu(){}function nu(){if(mr===0){ms=console.log,Ul=console.info,lc=console.warn,sc=console.error,ac=console.group,ta=console.groupCollapsed,fu=console.groupEnd;var r={configurable:!0,enumerable:!0,value:tu,writable:!0};Object.defineProperties(console,{info:r,log:r,warn:r,error:r,group:r,groupCollapsed:r,groupEnd:r})}mr++}function da(){if(mr--,mr===0){var r={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:en({},r,{value:ms}),info:en({},r,{value:Ul}),warn:en({},r,{value:lc}),error:en({},r,{value:sc}),group:en({},r,{value:ac}),groupCollapsed:en({},r,{value:ta}),groupEnd:en({},r,{value:fu})})}0>mr&&console.error("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}function ha(r){var a=Error.prepareStackTrace;if(Error.prepareStackTrace=void 0,r=r.stack,Error.prepareStackTrace=a,r.startsWith(`Error: react-stack-top-frame
97
+ `)&&(r=r.slice(29)),a=r.indexOf(`
98
+ `),a!==-1&&(r=r.slice(a+1)),a=r.indexOf("react_stack_bottom_frame"),a!==-1&&(a=r.lastIndexOf(`
99
+ `,a)),a!==-1)r=r.slice(0,a);else return"";return r}function nl(r){if(Uc===void 0)try{throw Error()}catch(p){var a=p.stack.trim().match(/\n( *(at )?)/);Uc=a&&a[1]||"",La=-1<p.stack.indexOf(`
100
+ at`)?" (<anonymous>)":-1<p.stack.indexOf("@")?"@unknown:0:0":""}return`
101
+ `+Uc+r+La}function ol(r,a){if(!r||gu)return"";var p=ic.get(r);if(p!==void 0)return p;gu=!0,p=Error.prepareStackTrace,Error.prepareStackTrace=void 0;var k=null;k=an.H,an.H=null,nu();try{var B={DetermineComponentFrameRoot:function(){try{if(a){var Oe=function(){throw Error()};if(Object.defineProperty(Oe.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Oe,[])}catch(Se){var Fe=Se}Reflect.construct(r,[],Oe)}else{try{Oe.call()}catch(Se){Fe=Se}r.call(Oe.prototype)}}else{try{throw Error()}catch(Se){Fe=Se}(Oe=r())&&typeof Oe.catch=="function"&&Oe.catch(function(){})}}catch(Se){if(Se&&Fe&&typeof Se.stack=="string")return[Se.stack,Fe.stack]}return[null,null]}};B.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var j=Object.getOwnPropertyDescriptor(B.DetermineComponentFrameRoot,"name");j&&j.configurable&&Object.defineProperty(B.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var Y=B.DetermineComponentFrameRoot(),Q=Y[0],ke=Y[1];if(Q&&ke){var re=Q.split(`
102
+ `),be=ke.split(`
103
+ `);for(Y=j=0;j<re.length&&!re[j].includes("DetermineComponentFrameRoot");)j++;for(;Y<be.length&&!be[Y].includes("DetermineComponentFrameRoot");)Y++;if(j===re.length||Y===be.length)for(j=re.length-1,Y=be.length-1;1<=j&&0<=Y&&re[j]!==be[Y];)Y--;for(;1<=j&&0<=Y;j--,Y--)if(re[j]!==be[Y]){if(j!==1||Y!==1)do if(j--,Y--,0>Y||re[j]!==be[Y]){var Ne=`
104
+ `+re[j].replace(" at new "," at ");return r.displayName&&Ne.includes("<anonymous>")&&(Ne=Ne.replace("<anonymous>",r.displayName)),typeof r=="function"&&ic.set(r,Ne),Ne}while(1<=j&&0<=Y);break}}}finally{gu=!1,an.H=k,da(),Error.prepareStackTrace=p}return re=(re=r?r.displayName||r.name:"")?nl(re):"",typeof r=="function"&&ic.set(r,re),re}function Di(r){if(typeof r=="string")return nl(r);if(typeof r=="function")return r.prototype&&r.prototype.isReactComponent?ol(r,!0):ol(r,!1);if(typeof r=="object"&&r!==null){switch(r.$$typeof){case dr:return ol(r.render,!1);case Ut:return ol(r.type,!1);case fr:var a=r,p=a._payload;a=a._init;try{r=a(p)}catch{return nl("Lazy")}return Di(r)}if(typeof r.name=="string"){e:{if(p=r.name,a=r.env,r=r.debugLocation,r!=null){r=ha(r);var k=r.lastIndexOf(`
105
+ `);if(r=k===-1?r:r.slice(k+1),r.indexOf(p)!==-1){p=`
106
+ `+r;break e}}p=nl(p+(a?" ["+a+"]":""))}return p}}switch(r){case hr:return nl("SuspenseList");case Jo:return nl("Suspense")}return""}function Ja(r,a){return(500<a.byteSize||!1)&&a.contentPreamble===null}function Qa(r){if(typeof r=="object"&&r!==null&&typeof r.environmentName=="string"){var a=r.environmentName;r=[r].slice(0),typeof r[0]=="string"?r.splice(0,1,"[%s] "+r[0]," "+a+" "):r.splice(0,0,"[%s]"," "+a+" "),r.unshift(console),a=me.apply(console.error,r),a()}else console.error(r);return null}function jn(r,a,p,k,B,j,Y,Q,ke,re,be){var Ne=new Set;this.destination=null,this.flushScheduled=!1,this.resumableState=r,this.renderState=a,this.rootFormatContext=p,this.progressiveChunkSize=k===void 0?12800:k,this.status=10,this.fatalError=null,this.pendingRootTasks=this.allPendingTasks=this.nextSegmentId=0,this.completedPreambleSegments=this.completedRootSegment=null,this.byteSize=0,this.abortableTasks=Ne,this.pingedTasks=[],this.clientRenderedBoundaries=[],this.completedBoundaries=[],this.partialBoundaries=[],this.trackedPostpones=null,this.onError=B===void 0?Qa:B,this.onPostpone=re===void 0?gt:re,this.onAllReady=j===void 0?gt:j,this.onShellReady=Y===void 0?gt:Y,this.onShellError=Q===void 0?gt:Q,this.onFatalError=ke===void 0?gt:ke,this.formState=be===void 0?null:be,this.didWarnForKey=null}function fa(r,a,p,k,B,j,Y,Q,ke,re,be,Ne){var Oe=pu();return 1e3<Oe-Pu&&(an.recentlyCreatedOwnerStacks=0,Pu=Oe),a=new jn(a,p,k,B,j,Y,Q,ke,re,be,Ne),p=Oo(a,0,null,k,!1,!1),p.parentFlushed=!0,r=rl(a,null,r,-1,null,p,null,null,a.abortableTasks,null,k,null,Ks,null,null,Me,null),jo(r),a.pingedTasks.push(r),a}function qa(r,a){r.pingedTasks.push(a),r.pingedTasks.length===1&&(r.flushScheduled=r.destination!==null,Sc(r))}function Oi(r,a,p,k,B){return p={status:zl,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,row:a,completedSegments:[],byteSize:0,fallbackAbortableTasks:p,errorDigest:null,contentState:ks(),fallbackState:ks(),contentPreamble:k,fallbackPreamble:B,trackedContentKeyPath:null,trackedFallbackNode:null,errorMessage:null,errorStack:null,errorComponentStack:null},a!==null&&(a.pendingTasks++,k=a.boundaries,k!==null&&(r.allPendingTasks++,p.pendingTasks++,k.push(p)),r=a.inheritedHoistables,r!==null&&yr(p.contentState,r)),p}function rl(r,a,p,k,B,j,Y,Q,ke,re,be,Ne,Oe,Fe,Se,ht,Yt){r.allPendingTasks++,B===null?r.pendingRootTasks++:B.pendingTasks++,Fe!==null&&Fe.pendingTasks++;var Ke={replay:null,node:p,childIndex:k,ping:function(){return qa(r,Ke)},blockedBoundary:B,blockedSegment:j,blockedPreamble:Y,hoistableState:Q,abortSet:ke,keyPath:re,formatContext:be,context:Ne,treeContext:Oe,row:Fe,componentStack:Se,thenableState:a};return Ke.debugTask=Yt,ke.add(Ke),Ke}function $a(r,a,p,k,B,j,Y,Q,ke,re,be,Ne,Oe,Fe,Se,ht){r.allPendingTasks++,j===null?r.pendingRootTasks++:j.pendingTasks++,Oe!==null&&Oe.pendingTasks++,p.pendingTasks++;var Yt={replay:p,node:k,childIndex:B,ping:function(){return qa(r,Yt)},blockedBoundary:j,blockedSegment:null,blockedPreamble:null,hoistableState:Y,abortSet:Q,keyPath:ke,formatContext:re,context:be,treeContext:Ne,row:Oe,componentStack:Fe,thenableState:a};return Yt.debugTask=ht,Q.add(Yt),Yt}function Oo(r,a,p,k,B,j){return{status:zl,parentFlushed:!1,id:-1,index:a,chunks:[],children:[],preambleChildren:[],parentFormatContext:k,boundary:p,lastPushedText:B,textEmbedded:j}}function jr(){if(Ar===null||Ar.componentStack===null)return"";var r=Ar.componentStack;try{var a="";if(typeof r.type=="string")a+=nl(r.type);else if(typeof r.type=="function"){if(!r.owner){var p=a,k=r.type,B=k?k.displayName||k.name:"",j=B?nl(B):"";a=p+j}}else r.owner||(a+=Di(r.type));for(;r;)p=null,r.debugStack!=null?p=ha(r.debugStack):(j=r,j.stack!=null&&(p=typeof j.stack!="string"?j.stack=ha(j.stack):j.stack)),(r=r.owner)&&p&&(a+=`
107
+ `+p);var Y=a}catch(Q){Y=`
108
+ Error generating stack: `+Q.message+`
109
+ `+Q.stack}return Y}function kc(r,a){if(a!=null)for(var p=a.length-1;0<=p;p--){var k=a[p];if(typeof k.name=="string"||typeof k.time=="number")break;if(k.awaited!=null){var B=k.debugStack==null?k.awaited:k;if(B.debugStack!==void 0){r.componentStack={parent:r.componentStack,type:k,owner:B.owner,stack:B.debugStack},r.debugTask=B.debugTask;break}}}}function ei(r,a){if(a!=null)for(var p=0;p<a.length;p++){var k=a[p];typeof k.name=="string"&&k.debugStack!==void 0&&(r.componentStack={parent:r.componentStack,type:k,owner:k.owner,stack:k.debugStack},r.debugTask=k.debugTask)}}function jo(r){var a=r.node;if(typeof a=="object"&&a!==null)switch(a.$$typeof){case Ls:var p=a.type,k=a._owner,B=a._debugStack;ei(r,a._debugInfo),r.debugTask=a._debugTask,r.componentStack={parent:r.componentStack,type:p,owner:k,stack:B};break;case fr:ei(r,a._debugInfo);break;default:typeof a.then=="function"&&ei(r,a._debugInfo)}}function ti(r){return r===null?null:{parent:r.parent,type:"Suspense Fallback",owner:r.owner,stack:r.stack}}function Ql(r){var a={};return r&&Object.defineProperty(a,"componentStack",{configurable:!0,enumerable:!0,get:function(){try{var p="",k=r;do p+=Di(k.type),k=k.parent;while(k);var B=p}catch(j){B=`
110
+ Error generating stack: `+j.message+`
111
+ `+j.stack}return Object.defineProperty(a,"componentStack",{value:B}),B}}),a}function ga(r,a,p,k,B){r.errorDigest=a,p instanceof Error?(a=String(p.message),p=String(p.stack)):(a=typeof p=="object"&&p!==null?S(p):String(p),p=null),B=B?`Switched to client rendering because the server rendering aborted due to:
112
+
113
+ `:`Switched to client rendering because the server rendering errored:
114
+
115
+ `,r.errorMessage=B+a,r.errorStack=p!==null?B+p:null,r.errorComponentStack=k.componentStack}function Ho(r,a,p,k){if(r=r.onError,a=k?k.run(r.bind(null,a,p)):r(a,p),a!=null&&typeof a!="string")console.error('onError returned something with a type other than "string". onError should return a string and may return null or undefined but must not return anything else. It received something of type "%s" instead',typeof a);else return a}function Gn(r,a,p,k){p=r.onShellError;var B=r.onFatalError;k?(k.run(p.bind(null,a)),k.run(B.bind(null,a))):(p(a),B(a)),r.destination!==null?(r.status=Wl,r.destination.destroy(a)):(r.status=13,r.fatalError=a)}function Xt(r,a){wc(r,a.next,a.hoistables)}function wc(r,a,p){for(;a!==null;){p!==null&&(yr(a.hoistables,p),a.inheritedHoistables=p);var k=a.boundaries;if(k!==null){a.boundaries=null;for(var B=0;B<k.length;B++){var j=k[B];p!==null&&yr(j.contentState,p),zr(r,j,null,null)}}if(a.pendingTasks--,0<a.pendingTasks)break;p=a.hoistables,a=a.next}}function wl(r,a){var p=a.boundaries;if(p!==null&&a.pendingTasks===p.length){for(var k=!0,B=0;B<p.length;B++){var j=p[B];if(j.pendingTasks!==1||j.parentFlushed||Ja(r,j)){k=!1;break}}k&&wc(r,a,a.hoistables)}}function Hr(r){var a={pendingTasks:1,boundaries:null,hoistables:ks(),inheritedHoistables:null,together:!1,next:null};return r!==null&&0<r.pendingTasks&&(a.pendingTasks++,a.boundaries=[],r.next=a),a}function Cc(r,a,p,k,B){var j=a.keyPath,Y=a.treeContext,Q=a.row,ke=a.componentStack,re=a.debugTask;ei(a,a.node.props.children._debugInfo),a.keyPath=p,p=k.length;var be=null;if(a.replay!==null){var Ne=a.replay.slots;if(Ne!==null&&typeof Ne=="object")for(var Oe=0;Oe<p;Oe++){var Fe=B!=="backwards"&&B!=="unstable_legacy-backwards"?Oe:p-1-Oe,Se=k[Fe];a.row=be=Hr(be),a.treeContext=Et(Y,p,Fe);var ht=Ne[Fe];typeof ht=="number"?(Sl(r,a,ht,Se,Fe),delete Ne[Fe]):In(r,a,Se,Fe),--be.pendingTasks===0&&Xt(r,be)}else for(Ne=0;Ne<p;Ne++)Oe=B!=="backwards"&&B!=="unstable_legacy-backwards"?Ne:p-1-Ne,Fe=k[Oe],An(r,a,Fe),a.row=be=Hr(be),a.treeContext=Et(Y,p,Oe),In(r,a,Fe,Oe),--be.pendingTasks===0&&Xt(r,be)}else if(B!=="backwards"&&B!=="unstable_legacy-backwards")for(B=0;B<p;B++)Ne=k[B],An(r,a,Ne),a.row=be=Hr(be),a.treeContext=Et(Y,p,B),In(r,a,Ne,B),--be.pendingTasks===0&&Xt(r,be);else{for(B=a.blockedSegment,Ne=B.children.length,Oe=B.chunks.length,Fe=p-1;0<=Fe;Fe--){Se=k[Fe],a.row=be=Hr(be),a.treeContext=Et(Y,p,Fe),ht=Oo(r,Oe,null,a.formatContext,Fe===0?B.lastPushedText:!0,!0),B.children.splice(Ne,0,ht),a.blockedSegment=ht,An(r,a,Se);try{In(r,a,Se,Fe),Ss(ht.chunks,r.renderState,ht.lastPushedText,ht.textEmbedded),ht.status=Ao,--be.pendingTasks===0&&Xt(r,be)}catch(Yt){throw ht.status=r.status===12?Ir:Lt,Yt}}a.blockedSegment=B,B.lastPushedText=!1}Q!==null&&be!==null&&0<be.pendingTasks&&(Q.pendingTasks++,be.next=Q),a.treeContext=Y,a.row=Q,a.keyPath=j,a.componentStack=ke,a.debugTask=re}function Cl(r,a,p,k,B,j){var Y=a.thenableState;for(a.thenableState=null,Vo={},Pa=a,To=r,Qs=p,hl=!1,qs=tc=0,nc=-1,oc=0,Na=Y,r=zc(k,B,j);Kr;)Kr=!1,qs=tc=0,nc=-1,oc=0,rc+=1,nn=null,r=k(B,j);return oo(),r}function ll(r,a,p,k,B,j,Y){var Q=!1;if(j!==0&&r.formState!==null){var ke=a.blockedSegment;if(ke!==null){Q=!0,ke=ke.chunks;for(var re=0;re<j;re++)re===Y?ke.push("<!--F!-->"):ke.push("<!--F-->")}}j=a.keyPath,a.keyPath=p,B?(p=a.treeContext,a.treeContext=Et(p,1,0),In(r,a,k,-1),a.treeContext=p):Q?In(r,a,k,-1):rt(r,a,k,-1),a.keyPath=j}function pa(r,a,p,k,B,j){if(typeof k=="function")if(k.prototype&&k.prototype.isReactComponent){var Y=B;if("ref"in B){Y={};for(var Q in B)Q!=="ref"&&(Y[Q]=B[Q])}var ke=k.defaultProps;if(ke){Y===B&&(Y=en({},Y,B));for(var re in ke)Y[re]===void 0&&(Y[re]=ke[re])}var be=Y,Ne=Me,Oe=k.contextType;if("contextType"in k&&Oe!==null&&(Oe===void 0||Oe.$$typeof!==ur)&&!Go.has(k)){Go.add(k);var Fe=Oe===void 0?" However, it is set to undefined. This can be caused by a typo or by mixing up named and default imports. This can also happen due to a circular dependency, so try moving the createContext() call to a separate file.":typeof Oe!="object"?" However, it is set to a "+typeof Oe+".":Oe.$$typeof===Hi?" Did you accidentally pass the Context.Consumer instead?":" However, it is set to an object with keys {"+Object.keys(Oe).join(", ")+"}.";console.error("%s defines an invalid contextType. contextType should point to the Context object returned by React.createContext().%s",mn(k)||"Component",Fe)}typeof Oe=="object"&&Oe!==null&&(Ne=Oe._currentValue2);var Se=new k(be,Ne);if(typeof k.getDerivedStateFromProps=="function"&&(Se.state===null||Se.state===void 0)){var ht=mn(k)||"Component";Kt.has(ht)||(Kt.add(ht),console.error("`%s` uses `getDerivedStateFromProps` but its initial state is %s. This is not recommended. Instead, define the initial state by assigning an object to `this.state` in the constructor of `%s`. This ensures that `getDerivedStateFromProps` arguments have a consistent shape.",ht,Se.state===null?"null":"undefined",ht))}if(typeof k.getDerivedStateFromProps=="function"||typeof Se.getSnapshotBeforeUpdate=="function"){var Yt=null,Ke=null,At=null;if(typeof Se.componentWillMount=="function"&&Se.componentWillMount.__suppressDeprecationWarning!==!0?Yt="componentWillMount":typeof Se.UNSAFE_componentWillMount=="function"&&(Yt="UNSAFE_componentWillMount"),typeof Se.componentWillReceiveProps=="function"&&Se.componentWillReceiveProps.__suppressDeprecationWarning!==!0?Ke="componentWillReceiveProps":typeof Se.UNSAFE_componentWillReceiveProps=="function"&&(Ke="UNSAFE_componentWillReceiveProps"),typeof Se.componentWillUpdate=="function"&&Se.componentWillUpdate.__suppressDeprecationWarning!==!0?At="componentWillUpdate":typeof Se.UNSAFE_componentWillUpdate=="function"&&(At="UNSAFE_componentWillUpdate"),Yt!==null||Ke!==null||At!==null){var io=mn(k)||"Component",co=typeof k.getDerivedStateFromProps=="function"?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";Qo.has(io)||(Qo.add(io),console.error(`Unsafe legacy lifecycles will not be called for components using new component APIs.
116
+
117
+ %s uses %s but also contains the following legacy lifecycles:%s%s%s
118
+
119
+ The above lifecycles should be removed. Learn more about this warning here:
120
+ https://react.dev/link/unsafe-component-lifecycles`,io,co,Yt!==null?`
121
+ `+Yt:"",Ke!==null?`
122
+ `+Ke:"",At!==null?`
123
+ `+At:""))}}var Pt=mn(k)||"Component";Se.render||(k.prototype&&typeof k.prototype.render=="function"?console.error("No `render` method found on the %s instance: did you accidentally return an object from the constructor?",Pt):console.error("No `render` method found on the %s instance: you may have forgotten to define `render`.",Pt)),!Se.getInitialState||Se.getInitialState.isReactClassApproved||Se.state||console.error("getInitialState was defined on %s, a plain JavaScript class. This is only supported for classes created using React.createClass. Did you mean to define a state property instead?",Pt),Se.getDefaultProps&&!Se.getDefaultProps.isReactClassApproved&&console.error("getDefaultProps was defined on %s, a plain JavaScript class. This is only supported for classes created using React.createClass. Use a static property to define defaultProps instead.",Pt),Se.contextType&&console.error("contextType was defined as an instance property on %s. Use a static property to define contextType instead.",Pt),k.childContextTypes&&!En.has(k)&&(En.add(k),console.error("%s uses the legacy childContextTypes API which was removed in React 19. Use React.createContext() instead. (https://react.dev/link/legacy-context)",Pt)),k.contextTypes&&!wo.has(k)&&(wo.add(k),console.error("%s uses the legacy contextTypes API which was removed in React 19. Use React.createContext() with static contextType instead. (https://react.dev/link/legacy-context)",Pt)),typeof Se.componentShouldUpdate=="function"&&console.error("%s has a method called componentShouldUpdate(). Did you mean shouldComponentUpdate()? The name is phrased as a question because the function is expected to return a value.",Pt),k.prototype&&k.prototype.isPureReactComponent&&typeof Se.shouldComponentUpdate<"u"&&console.error("%s has a method called shouldComponentUpdate(). shouldComponentUpdate should not be used when extending React.PureComponent. Please extend React.Component if shouldComponentUpdate is used.",mn(k)||"A pure component"),typeof Se.componentDidUnmount=="function"&&console.error("%s has a method called componentDidUnmount(). But there is no such lifecycle method. Did you mean componentWillUnmount()?",Pt),typeof Se.componentDidReceiveProps=="function"&&console.error("%s has a method called componentDidReceiveProps(). But there is no such lifecycle method. If you meant to update the state in response to changing props, use componentWillReceiveProps(). If you meant to fetch data or run side-effects or mutations after React has updated the UI, use componentDidUpdate().",Pt),typeof Se.componentWillRecieveProps=="function"&&console.error("%s has a method called componentWillRecieveProps(). Did you mean componentWillReceiveProps()?",Pt),typeof Se.UNSAFE_componentWillRecieveProps=="function"&&console.error("%s has a method called UNSAFE_componentWillRecieveProps(). Did you mean UNSAFE_componentWillReceiveProps()?",Pt);var Xn=Se.props!==be;Se.props!==void 0&&Xn&&console.error("When calling super() in `%s`, make sure to pass up the same props that your component's constructor was passed.",Pt),Se.defaultProps&&console.error("Setting defaultProps as an instance property on %s is not supported and will be ignored. Instead, define defaultProps as a static property on %s.",Pt,Pt),typeof Se.getSnapshotBeforeUpdate!="function"||typeof Se.componentDidUpdate=="function"||ao.has(k)||(ao.add(k),console.error("%s: getSnapshotBeforeUpdate() should be used with componentDidUpdate(). This component defines getSnapshotBeforeUpdate() only.",mn(k))),typeof Se.getDerivedStateFromProps=="function"&&console.error("%s: getDerivedStateFromProps() is defined as an instance method and will be ignored. Instead, declare it as a static method.",Pt),typeof Se.getDerivedStateFromError=="function"&&console.error("%s: getDerivedStateFromError() is defined as an instance method and will be ignored. Instead, declare it as a static method.",Pt),typeof k.getSnapshotBeforeUpdate=="function"&&console.error("%s: getSnapshotBeforeUpdate() is defined as a static method and will be ignored. Instead, declare it as an instance method.",Pt);var gl=Se.state;gl&&(typeof gl!="object"||_l(gl))&&console.error("%s.state: must be set to an object or null",Pt),typeof Se.getChildContext=="function"&&typeof k.childContextTypes!="object"&&console.error("%s.getChildContext(): childContextTypes must be defined in order to use getChildContext().",Pt);var Yo=Se.state!==void 0?Se.state:null;Se.updater=fn,Se.props=be,Se.state=Yo;var Ue={queue:[],replace:!1};Se._reactInternals=Ue;var Dt=k.contextType;if(Se.context=typeof Dt=="object"&&Dt!==null?Dt._currentValue2:Me,Se.state===be){var Ot=mn(k)||"Component";Sr.has(Ot)||(Sr.add(Ot),console.error("%s: It is not recommended to assign props directly to state because updates to props won't be reflected in state. In most cases, it is better to use props directly.",Ot))}var zt=k.getDerivedStateFromProps;if(typeof zt=="function"){var gn=zt(be,Yo);if(gn===void 0){var bt=mn(k)||"Component";$e.has(bt)||($e.add(bt),console.error("%s.getDerivedStateFromProps(): A valid state object (or null) must be returned. You have returned undefined.",bt))}var st=gn==null?Yo:en({},Yo,gn);Se.state=st}if(typeof k.getDerivedStateFromProps!="function"&&typeof Se.getSnapshotBeforeUpdate!="function"&&(typeof Se.UNSAFE_componentWillMount=="function"||typeof Se.componentWillMount=="function")){var Io=Se.state;if(typeof Se.componentWillMount=="function"){if(Se.componentWillMount.__suppressDeprecationWarning!==!0){var jt=mn(k)||"Unknown";hn[jt]||(console.warn(`componentWillMount has been renamed, and is not recommended for use. See https://react.dev/link/unsafe-component-lifecycles for details.
124
+
125
+ * Move code from componentWillMount to componentDidMount (preferred in most cases) or the constructor.
126
+
127
+ Please update the following components: %s`,jt),hn[jt]=!0)}Se.componentWillMount()}if(typeof Se.UNSAFE_componentWillMount=="function"&&Se.UNSAFE_componentWillMount(),Io!==Se.state&&(console.error("%s.componentWillMount(): Assigning directly to this.state is deprecated (except inside a component's constructor). Use setState instead.",mn(k)||"Component"),fn.enqueueReplaceState(Se,Se.state,null)),Ue.queue!==null&&0<Ue.queue.length){var uo=Ue.queue,on=Ue.replace;if(Ue.queue=null,Ue.replace=!1,on&&uo.length===1)Se.state=uo[0];else{for(var $o=on?uo[0]:Se.state,Da=!0,er=on?1:0;er<uo.length;er++){var pl=uo[er],xl=typeof pl=="function"?pl.call(Se,$o,be,void 0):pl;xl!=null&&(Da?(Da=!1,$o=en({},$o,xl)):en($o,xl))}Se.state=$o}}else Ue.queue=null}var ml=cc(Se);if(r.status===12)throw null;Se.props!==be&&(na||console.error("It looks like %s is reassigning its own `this.props` while rendering. This is not supported and can lead to confusing bugs.",mn(k)||"a component"),na=!0);var eo=a.keyPath;a.keyPath=p,rt(r,a,ml,-1),a.keyPath=eo}else{if(k.prototype&&typeof k.prototype.render=="function"){var o=mn(k)||"Unknown";vi[o]||(console.error("The <%s /> component appears to have a render method, but doesn't extend React.Component. This is likely to cause errors. Change %s to extend React.Component instead.",o,o),vi[o]=!0)}var l=Cl(r,a,p,k,B,void 0);if(r.status===12)throw null;var g=tc!==0,E=qs,I=nc;if(k.contextTypes){var F=mn(k)||"Unknown";uc[F]||(uc[F]=!0,console.error("%s uses the legacy contextTypes API which was removed in React 19. Use React.createContext() with React.useContext() instead. (https://react.dev/link/legacy-context)",F))}if(k&&k.childContextTypes&&console.error(`childContextTypes cannot be defined on a function component.
128
+ %s.childContextTypes = ...`,k.displayName||k.name||"Component"),typeof k.getDerivedStateFromProps=="function"){var G=mn(k)||"Unknown";Ma[G]||(console.error("%s: Function components do not support getDerivedStateFromProps.",G),Ma[G]=!0)}if(typeof k.contextType=="object"&&k.contextType!==null){var Z=mn(k)||"Unknown";xu[Z]||(console.error("%s: Function components do not support contextType.",Z),xu[Z]=!0)}ll(r,a,p,l,g,E,I)}else if(typeof k=="string"){var pe=a.blockedSegment;if(pe===null){var te=B.children,se=a.formatContext,Te=a.keyPath;a.formatContext=Ee(se,k,B),a.keyPath=p,In(r,a,te,-1),a.formatContext=se,a.keyPath=Te}else{var _e=_t(pe.chunks,k,B,r.resumableState,r.renderState,a.blockedPreamble,a.hoistableState,a.formatContext,pe.lastPushedText);pe.lastPushedText=!1;var Be=a.formatContext,Ce=a.keyPath;if(a.keyPath=p,(a.formatContext=Ee(Be,k,B)).insertionMode===tt){var Ze=Oo(r,0,null,a.formatContext,!1,!1);pe.preambleChildren.push(Ze),a.blockedSegment=Ze;try{Ze.status=6,In(r,a,_e,-1),Ss(Ze.chunks,r.renderState,Ze.lastPushedText,Ze.textEmbedded),Ze.status=Ao}finally{a.blockedSegment=pe}}else In(r,a,_e,-1);a.formatContext=Be,a.keyPath=Ce;e:{var Wt=pe.chunks,Ye=r.resumableState;switch(k){case"title":case"style":case"script":case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break e;case"body":if(Be.insertionMode<=Qe){Ye.hasBody=!0;break e}break;case"html":if(Be.insertionMode===at){Ye.hasHtml=!0;break e}break;case"head":if(Be.insertionMode<=Qe)break e}Wt.push(Wn(k))}pe.lastPushedText=!1}}else{switch(k){case Ui:case oi:case ri:case il:var ft=a.keyPath;a.keyPath=p,rt(r,a,B.children,-1),a.keyPath=ft;return;case Gr:var bn=a.blockedSegment;if(bn===null){if(B.mode!=="hidden"){var Ln=a.keyPath;a.keyPath=p,In(r,a,B.children,-1),a.keyPath=Ln}}else if(B.mode!=="hidden"){r.renderState.generateStaticMarkup||bn.chunks.push("<!--&-->"),bn.lastPushedText=!1;var It=a.keyPath;a.keyPath=p,In(r,a,B.children,-1),a.keyPath=It,r.renderState.generateStaticMarkup||bn.chunks.push("<!--/&-->"),bn.lastPushedText=!1}return;case hr:e:{var Ve=B.children,Fn=B.revealOrder;if(Fn==="forwards"||Fn==="backwards"||Fn==="unstable_legacy-backwards"){if(_l(Ve)){Cc(r,a,p,Ve,Fn);break e}var Bo=d(Ve);if(Bo){var Gt=Bo.call(Ve);if(Gt){xa(a,Ve,-1,Gt,Bo);var rn=Gt.next();if(!rn.done){var tr=[];do tr.push(rn.value),rn=Gt.next();while(!rn.done);Cc(r,a,p,Ve,Fn)}break e}}}if(Fn==="together"){var ho=a.keyPath,Zn=a.row,ln=a.row=Hr(null);ln.boundaries=[],ln.together=!0,a.keyPath=p,rt(r,a,Ve,-1),--ln.pendingTasks===0&&Xt(r,ln),a.keyPath=ho,a.row=Zn,Zn!==null&&0<ln.pendingTasks&&(Zn.pendingTasks++,ln.next=Zn)}else{var zn=a.keyPath;a.keyPath=p,rt(r,a,Ve,-1),a.keyPath=zn}}return;case Wi:case $t:throw Error("ReactDOMServer does not yet support scope components.");case Jo:e:if(a.replay!==null){var nr=a.keyPath,br=a.formatContext,Kn=a.row;a.keyPath=p,a.formatContext=We(r.resumableState,br),a.row=null;var pn=B.children;try{In(r,a,pn,-1)}finally{a.keyPath=nr,a.formatContext=br,a.row=Kn}}else{var Po=a.keyPath,or=a.formatContext,_o=a.row,Gl=a.blockedBoundary,rr=a.blockedPreamble,Mn=a.hoistableState,Br=a.blockedSegment,to=B.fallback,Wc=B.children,bl=new Set,yn=Oi(r,a.row,bl,null,null);r.trackedPostpones!==null&&(yn.trackedContentKeyPath=p);var Pr=Oo(r,Br.chunks.length,yn,a.formatContext,!1,!1);Br.children.push(Pr),Br.lastPushedText=!1;var Lo=Oo(r,0,null,a.formatContext,!1,!1);if(Lo.parentFlushed=!0,r.trackedPostpones!==null){var ki=a.componentStack,Oa=[p[0],"Suspense Fallback",p[2]],Qr=[Oa[1],Oa[2],[],null];r.trackedPostpones.workingMap.set(Oa,Qr),yn.trackedFallbackNode=Qr,a.blockedSegment=Pr,a.blockedPreamble=yn.fallbackPreamble,a.keyPath=Oa,a.formatContext=ze(r.resumableState,or),a.componentStack=ti(ki),Pr.status=6;try{In(r,a,to,-1),Ss(Pr.chunks,r.renderState,Pr.lastPushedText,Pr.textEmbedded),Pr.status=Ao}catch(dc){throw Pr.status=r.status===12?Ir:Lt,dc}finally{a.blockedSegment=Br,a.blockedPreamble=rr,a.keyPath=Po,a.formatContext=or}var ja=rl(r,null,Wc,-1,yn,Lo,yn.contentPreamble,yn.contentState,a.abortSet,p,We(r.resumableState,a.formatContext),a.context,a.treeContext,null,ki,Me,a.debugTask);jo(ja),r.pingedTasks.push(ja)}else{a.blockedBoundary=yn,a.blockedPreamble=yn.contentPreamble,a.hoistableState=yn.contentState,a.blockedSegment=Lo,a.keyPath=p,a.formatContext=We(r.resumableState,or),a.row=null,Lo.status=6;try{if(In(r,a,Wc,-1),Ss(Lo.chunks,r.renderState,Lo.lastPushedText,Lo.textEmbedded),Lo.status=Ao,Ns(yn,Lo),yn.pendingTasks===0&&yn.status===zl){if(yn.status=Ao,!Ja(r,yn)){_o!==null&&--_o.pendingTasks===0&&Xt(r,_o),r.pendingRootTasks===0&&a.blockedPreamble&&ma(r);break e}}else _o!==null&&_o.together&&wl(r,_o)}catch(dc){if(yn.status=$n,r.status===12){Lo.status=Ir;var lr=r.fatalError}else Lo.status=Lt,lr=dc;var wi=Ql(a.componentStack),Gc=Ho(r,lr,wi,a.debugTask);ga(yn,Gc,lr,wi,!1),Bs(r,yn)}finally{a.blockedBoundary=Gl,a.blockedPreamble=rr,a.hoistableState=Mn,a.blockedSegment=Br,a.keyPath=Po,a.formatContext=or,a.row=_o}var _r=rl(r,null,to,-1,Gl,Pr,yn.fallbackPreamble,yn.fallbackState,bl,[p[0],"Suspense Fallback",p[2]],ze(r.resumableState,a.formatContext),a.context,a.treeContext,a.row,ti(a.componentStack),Me,a.debugTask);jo(_r),r.pingedTasks.push(_r)}}return}if(typeof k=="object"&&k!==null)switch(k.$$typeof){case dr:if("ref"in B){var Ci={};for(var Fo in B)Fo!=="ref"&&(Ci[Fo]=B[Fo])}else Ci=B;var Ha=Cl(r,a,p,k.render,Ci,j);ll(r,a,p,Ha,tc!==0,qs,nc);return;case Ut:pa(r,a,p,k.type,B,j);return;case ur:var ra=B.value,ys=B.children,Nr=a.context,Lr=a.keyPath,yl=k._currentValue2;k._currentValue2=ra,k._currentRenderer2!==void 0&&k._currentRenderer2!==null&&k._currentRenderer2!==pt&&console.error("Detected multiple renderers concurrently rendering the same context provider. This is currently unsupported."),k._currentRenderer2=pt;var sr=qe,fo={parent:sr,depth:sr===null?0:sr.depth+1,context:k,parentValue:yl,value:ra};qe=fo,a.context=fo,a.keyPath=p,rt(r,a,ys,-1);var vs=qe;if(vs===null)throw Error("Tried to pop a Context at the root of the app. This is a bug in React.");vs.context!==k&&console.error("The parent context is not the expected context. This is probably a bug in React."),vs.context._currentValue2=vs.parentValue,k._currentRenderer2!==void 0&&k._currentRenderer2!==null&&k._currentRenderer2!==pt&&console.error("Detected multiple renderers concurrently rendering the same context provider. This is currently unsupported."),k._currentRenderer2=pt;var vl=qe=vs.parent;a.context=vl,a.keyPath=Lr,Nr!==a.context&&console.error("Popping the context provider did not return back to the original snapshot. This is a bug in React.");return;case Hi:var la=k._context,Vl=B.children;typeof Vl!="function"&&console.error("A context consumer was rendered with multiple children, or a child that isn't a function. A context consumer expects a single child that is a function. If you did pass a function, make sure there is no trailing or leading whitespace around it.");var mu=Vl(la._currentValue2),Xo=a.keyPath;a.keyPath=p,rt(r,a,mu,-1),a.keyPath=Xo;return;case fr:var qr=Bu(k);if(r.status===12)throw null;pa(r,a,p,qr,B,j);return}var Si="";throw(k===void 0||typeof k=="object"&&k!==null&&Object.keys(k).length===0)&&(Si+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports."),Error("Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: "+((k==null?k:typeof k)+"."+Si))}}function Sl(r,a,p,k,B){var j=a.replay,Y=a.blockedBoundary,Q=Oo(r,0,null,a.formatContext,!1,!1);Q.id=p,Q.parentFlushed=!0;try{a.replay=null,a.blockedSegment=Q,In(r,a,k,B),Q.status=Ao,Y===null?r.completedRootSegment=Q:(Ns(Y,Q),Y.parentFlushed&&r.partialBoundaries.push(Y))}finally{a.replay=j,a.blockedSegment=null}}function Tl(r,a,p,k,B,j,Y,Q,ke,re){j=re.nodes;for(var be=0;be<j.length;be++){var Ne=j[be];if(B===Ne[1]){if(Ne.length===4){if(k!==null&&k!==Ne[0])throw Error("Expected the resume to render <"+Ne[0]+"> in this slot but instead it rendered <"+k+">. The tree doesn't match so React will fallback to client rendering.");var Oe=Ne[2];k=Ne[3],B=a.node,a.replay={nodes:Oe,slots:k,pendingTasks:1};try{if(pa(r,a,p,Y,Q,ke),a.replay.pendingTasks===1&&0<a.replay.nodes.length)throw Error("Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering.");a.replay.pendingTasks--}catch(Xn){if(typeof Xn=="object"&&Xn!==null&&(Xn===So||typeof Xn.then=="function"))throw a.node===B?a.replay=re:j.splice(be,1),Xn;a.replay.pendingTasks--,Y=Ql(a.componentStack),Q=r,r=a.blockedBoundary,p=Xn,ke=k,k=Ho(Q,p,Y,a.debugTask),Bl(Q,r,Oe,ke,p,k,Y,!1)}a.replay=re}else{if(Y!==Jo)throw Error("Expected the resume to render <Suspense> in this slot but instead it rendered <"+(mn(Y)||"Unknown")+">. The tree doesn't match so React will fallback to client rendering.");e:{re=void 0,k=Ne[5],Y=Ne[2],ke=Ne[3],B=Ne[4]===null?[]:Ne[4][2],Ne=Ne[4]===null?null:Ne[4][3];var Fe=a.keyPath,Se=a.formatContext,ht=a.row,Yt=a.replay,Ke=a.blockedBoundary,At=a.hoistableState,io=Q.children,co=Q.fallback,Pt=new Set;Q=Oi(r,a.row,Pt,null,null),Q.parentFlushed=!0,Q.rootSegmentID=k,a.blockedBoundary=Q,a.hoistableState=Q.contentState,a.keyPath=p,a.formatContext=We(r.resumableState,Se),a.row=null,a.replay={nodes:Y,slots:ke,pendingTasks:1};try{if(In(r,a,io,-1),a.replay.pendingTasks===1&&0<a.replay.nodes.length)throw Error("Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering.");if(a.replay.pendingTasks--,Q.pendingTasks===0&&Q.status===zl){Q.status=Ao,r.completedBoundaries.push(Q);break e}}catch(Xn){Q.status=$n,Oe=Ql(a.componentStack),re=Ho(r,Xn,Oe,a.debugTask),ga(Q,re,Xn,Oe,!1),a.replay.pendingTasks--,r.clientRenderedBoundaries.push(Q)}finally{a.blockedBoundary=Ke,a.hoistableState=At,a.replay=Yt,a.keyPath=Fe,a.formatContext=Se,a.row=ht}Q=$a(r,null,{nodes:B,slots:Ne,pendingTasks:0},co,-1,Ke,Q.fallbackState,Pt,[p[0],"Suspense Fallback",p[2]],ze(r.resumableState,a.formatContext),a.context,a.treeContext,a.row,ti(a.componentStack),Me,a.debugTask),jo(Q),r.pingedTasks.push(Q)}}j.splice(be,1);break}}}function xa(r,a,p,k,B){k===a?(p!==-1||r.componentStack===null||typeof r.componentStack.type!="function"||Object.prototype.toString.call(r.componentStack.type)!=="[object GeneratorFunction]"||Object.prototype.toString.call(k)!=="[object Generator]")&&(Ri||console.error("Using Iterators as children is unsupported and will likely yield unexpected results because enumerating a generator mutates it. You may convert it to an array with `Array.from()` or the `[...spread]` operator before rendering. You can also use an Iterable that can iterate multiple times over the same items."),Ri=!0):a.entries!==B||Jr||(console.error("Using Maps as children is not supported. Use an array of keyed ReactElements instead."),Jr=!0)}function rt(r,a,p,k){a.replay!==null&&typeof a.replay.slots=="number"?Sl(r,a,a.replay.slots,p,k):(a.node=p,a.childIndex=k,p=a.componentStack,k=a.debugTask,jo(a),Ur(r,a),a.componentStack=p,a.debugTask=k)}function Ur(r,a){var p=a.node,k=a.childIndex;if(p!==null){if(typeof p=="object"){switch(p.$$typeof){case Ls:var B=p.type,j=p.key;p=p.props;var Y=p.ref;Y=Y!==void 0?Y:null;var Q=a.debugTask,ke=mn(B);j=j??(k===-1?0:k);var re=[a.keyPath,ke,j];a.replay!==null?Q?Q.run(Tl.bind(null,r,a,re,ke,j,k,B,p,Y,a.replay)):Tl(r,a,re,ke,j,k,B,p,Y,a.replay):Q?Q.run(pa.bind(null,r,a,re,B,p,Y)):pa(r,a,re,B,p,Y);return;case Bn:throw Error("Portals are not currently supported by the server renderer. Render them conditionally so that they only appear on the client render.");case fr:if(B=Bu(p),r.status===12)throw null;rt(r,a,B,k);return}if(_l(p)){sl(r,a,p,k);return}if((j=d(p))&&(B=j.call(p))){if(xa(a,p,k,B,j),p=B.next(),!p.done){j=[];do j.push(p.value),p=B.next();while(!p.done);sl(r,a,j,k)}return}if(typeof p.then=="function")return a.thenableState=null,rt(r,a,cr(p),k);if(p.$$typeof===ur)return rt(r,a,p._currentValue2,k);throw r=Object.prototype.toString.call(p),Error("Objects are not valid as a React child (found: "+(r==="[object Object]"?"object with keys {"+Object.keys(p).join(", ")+"}":r)+"). If you meant to render a collection of children, use an array instead.")}typeof p=="string"?(a=a.blockedSegment,a!==null&&(a.lastPushedText=qc(a.chunks,p,r.renderState,a.lastPushedText))):typeof p=="number"||typeof p=="bigint"?(a=a.blockedSegment,a!==null&&(a.lastPushedText=qc(a.chunks,""+p,r.renderState,a.lastPushedText))):(typeof p=="function"&&(r=p.displayName||p.name||"Component",console.error("Functions are not valid as a React child. This may happen if you return %s instead of <%s /> from render. Or maybe you meant to call this function rather than return it.",r,r)),typeof p=="symbol"&&console.error(`Symbols are not valid as a React child.
129
+ %s`,String(p)))}}function An(r,a,p){if(p!==null&&typeof p=="object"&&(p.$$typeof===Ls||p.$$typeof===Bn)&&p._store&&(!p._store.validated&&p.key==null||p._store.validated===2)){if(typeof p._store!="object")throw Error("React Component in warnForMissingKey should have a _store. This error is likely caused by a bug in React. Please file an issue.");p._store.validated=1;var k=r.didWarnForKey;if(k==null&&(k=r.didWarnForKey=new WeakSet),r=a.componentStack,r!==null&&!k.has(r)){k.add(r);var B=mn(p.type);k=p._owner;var j=r.owner;if(r="",j&&typeof j.type<"u"){var Y=mn(j.type);Y&&(r=`
130
+
131
+ Check the render method of \``+Y+"`.")}r||B&&(r=`
132
+
133
+ Check the top-level render call using <`+B+">."),B="",k!=null&&j!==k&&(j=null,typeof k.type<"u"?j=mn(k.type):typeof k.name=="string"&&(j=k.name),j&&(B=" It was passed a child from "+j+".")),k=a.componentStack,a.componentStack={parent:a.componentStack,type:p.type,owner:p._owner,stack:p._debugStack},console.error('Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',r,B),a.componentStack=k}}}function sl(r,a,p,k){var B=a.keyPath,j=a.componentStack,Y=a.debugTask;if(ei(a,a.node._debugInfo),k!==-1&&(a.keyPath=[a.keyPath,"Fragment",k],a.replay!==null)){for(var Q=a.replay,ke=Q.nodes,re=0;re<ke.length;re++){var be=ke[re];if(be[1]===k){k=be[2],be=be[3],a.replay={nodes:k,slots:be,pendingTasks:1};try{if(sl(r,a,p,-1),a.replay.pendingTasks===1&&0<a.replay.nodes.length)throw Error("Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering.");a.replay.pendingTasks--}catch(Se){if(typeof Se=="object"&&Se!==null&&(Se===So||typeof Se.then=="function"))throw Se;a.replay.pendingTasks--;var Ne=Ql(a.componentStack);p=a.blockedBoundary;var Oe=Se,Fe=be;be=Ho(r,Oe,Ne,a.debugTask),Bl(r,p,k,Fe,Oe,be,Ne,!1)}a.replay=Q,ke.splice(re,1);break}}a.keyPath=B,a.componentStack=j,a.debugTask=Y;return}if(Q=a.treeContext,ke=p.length,a.replay!==null&&(re=a.replay.slots,re!==null&&typeof re=="object")){for(k=0;k<ke;k++)be=p[k],a.treeContext=Et(Q,ke,k),Oe=re[k],typeof Oe=="number"?(Sl(r,a,Oe,be,k),delete re[k]):In(r,a,be,k);a.treeContext=Q,a.keyPath=B,a.componentStack=j,a.debugTask=Y;return}for(re=0;re<ke;re++)k=p[re],An(r,a,k),a.treeContext=Et(Q,ke,re),In(r,a,k,re);a.treeContext=Q,a.keyPath=B,a.componentStack=j,a.debugTask=Y}function Hn(r,a,p){if(p.status=qo,p.rootSegmentID=r.nextSegmentId++,r=p.trackedContentKeyPath,r===null)throw Error("It should not be possible to postpone at the root. This is a bug in React.");var k=p.trackedFallbackNode,B=[],j=a.workingMap.get(r);return j===void 0?(p=[r[1],r[2],B,null,k,p.rootSegmentID],a.workingMap.set(r,p),Wr(p,r[0],a),p):(j[4]=k,j[5]=p.rootSegmentID,j)}function ql(r,a,p,k){k.status=qo;var B=p.keyPath,j=p.blockedBoundary;if(j===null)k.id=r.nextSegmentId++,a.rootSlots=k.id,r.completedRootSegment!==null&&(r.completedRootSegment.status=qo);else{if(j!==null&&j.status===zl){var Y=Hn(r,a,j);if(j.trackedContentKeyPath===B&&p.childIndex===-1){k.id===-1&&(k.id=k.parentFlushed?j.rootSegmentID:r.nextSegmentId++),Y[3]=k.id;return}}if(k.id===-1&&(k.id=k.parentFlushed&&j!==null?j.rootSegmentID:r.nextSegmentId++),p.childIndex===-1)B===null?a.rootSlots=k.id:(p=a.workingMap.get(B),p===void 0?(p=[B[1],B[2],[],k.id],Wr(p,B[0],a)):p[3]=k.id);else{if(B===null){if(r=a.rootSlots,r===null)r=a.rootSlots={};else if(typeof r=="number")throw Error("It should not be possible to postpone both at the root of an element as well as a slot below. This is a bug in React.")}else if(j=a.workingMap,Y=j.get(B),Y===void 0)r={},Y=[B[1],B[2],[],r],j.set(B,Y),Wr(Y,B[0],a);else if(r=Y[3],r===null)r=Y[3]={};else if(typeof r=="number")throw Error("It should not be possible to postpone both at the root of an element as well as a slot below. This is a bug in React.");r[p.childIndex]=k.id}}}function Bs(r,a){r=r.trackedPostpones,r!==null&&(a=a.trackedContentKeyPath,a!==null&&(a=r.workingMap.get(a),a!==void 0&&(a.length=4,a[2]=[],a[3]=null)))}function al(r,a,p){return $a(r,p,a.replay,a.node,a.childIndex,a.blockedBoundary,a.hoistableState,a.abortSet,a.keyPath,a.formatContext,a.context,a.treeContext,a.row,a.componentStack,Me,a.debugTask)}function Al(r,a,p){var k=a.blockedSegment,B=Oo(r,k.chunks.length,null,a.formatContext,k.lastPushedText,!0);return k.children.push(B),k.lastPushedText=!1,rl(r,p,a.node,a.childIndex,a.blockedBoundary,B,a.blockedPreamble,a.hoistableState,a.abortSet,a.keyPath,a.formatContext,a.context,a.treeContext,a.row,a.componentStack,Me,a.debugTask)}function In(r,a,p,k){var B=a.formatContext,j=a.context,Y=a.keyPath,Q=a.treeContext,ke=a.componentStack,re=a.debugTask,be=a.blockedSegment;if(be===null){be=a.replay;try{return rt(r,a,p,k)}catch(Fe){if(oo(),p=Fe===So?Za():Fe,r.status!==12&&typeof p=="object"&&p!==null){if(typeof p.then=="function"){k=Fe===So?Or():null,r=al(r,a,k).ping,p.then(r,r),a.formatContext=B,a.context=j,a.keyPath=Y,a.treeContext=Q,a.componentStack=ke,a.replay=be,a.debugTask=re,Ht(j);return}if(p.message==="Maximum call stack size exceeded"){p=Fe===So?Or():null,p=al(r,a,p),r.pingedTasks.push(p),a.formatContext=B,a.context=j,a.keyPath=Y,a.treeContext=Q,a.componentStack=ke,a.replay=be,a.debugTask=re,Ht(j);return}}}}else{var Ne=be.children.length,Oe=be.chunks.length;try{return rt(r,a,p,k)}catch(Fe){if(oo(),be.children.length=Ne,be.chunks.length=Oe,p=Fe===So?Za():Fe,r.status!==12&&typeof p=="object"&&p!==null){if(typeof p.then=="function"){be=p,p=Fe===So?Or():null,r=Al(r,a,p).ping,be.then(r,r),a.formatContext=B,a.context=j,a.keyPath=Y,a.treeContext=Q,a.componentStack=ke,a.debugTask=re,Ht(j);return}if(p.message==="Maximum call stack size exceeded"){be=Fe===So?Or():null,be=Al(r,a,be),r.pingedTasks.push(be),a.formatContext=B,a.context=j,a.keyPath=Y,a.treeContext=Q,a.componentStack=ke,a.debugTask=re,Ht(j);return}}}}throw a.formatContext=B,a.context=j,a.keyPath=Y,a.treeContext=Q,Ht(j),p}function Il(r){var a=r.blockedBoundary,p=r.blockedSegment;p!==null&&(p.status=Ir,zr(this,a,r.row,p))}function Bl(r,a,p,k,B,j,Y,Q){for(var ke=0;ke<p.length;ke++){var re=p[ke];if(re.length===4)Bl(r,a,re[2],re[3],B,j,Y,Q);else{var be=r;re=re[5];var Ne=B,Oe=j,Fe=Y,Se=Q,ht=Oi(be,null,new Set,null,null);ht.parentFlushed=!0,ht.rootSegmentID=re,ht.status=$n,ga(ht,Oe,Ne,Fe,Se),ht.parentFlushed&&be.clientRenderedBoundaries.push(ht)}}if(p.length=0,k!==null){if(a===null)throw Error("We should not have any resumable nodes in the shell. This is a bug in React.");if(a.status!==$n&&(a.status=$n,ga(a,j,B,Y,Q),a.parentFlushed&&r.clientRenderedBoundaries.push(a)),typeof k=="object")for(var Yt in k)delete k[Yt]}}function Ps(r,a,p){var k=r.blockedBoundary,B=r.blockedSegment;if(B!==null){if(B.status===6)return;B.status=Ir}var j=Ql(r.componentStack),Y=r.node;if(Y!==null&&typeof Y=="object"&&kc(r,Y._debugInfo),k===null){if(a.status!==13&&a.status!==Wl){if(k=r.replay,k===null){a.trackedPostpones!==null&&B!==null?(k=a.trackedPostpones,Ho(a,p,j,r.debugTask),ql(a,k,r,B),zr(a,null,r.row,B)):(Ho(a,p,j,r.debugTask),Gn(a,p,j,r.debugTask));return}k.pendingTasks--,k.pendingTasks===0&&0<k.nodes.length&&(B=Ho(a,p,j,null),Bl(a,null,k.nodes,k.slots,p,B,j,!0)),a.pendingRootTasks--,a.pendingRootTasks===0&&_s(a)}}else{if(Y=a.trackedPostpones,k.status!==$n){if(Y!==null&&B!==null)return Ho(a,p,j,r.debugTask),ql(a,Y,r,B),k.fallbackAbortableTasks.forEach(function(Q){return Ps(Q,a,p)}),k.fallbackAbortableTasks.clear(),zr(a,k,r.row,B);k.status=$n,B=Ho(a,p,j,r.debugTask),k.status=$n,ga(k,B,p,j,!0),Bs(a,k),k.parentFlushed&&a.clientRenderedBoundaries.push(k)}k.pendingTasks--,j=k.row,j!==null&&--j.pendingTasks===0&&Xt(a,j),k.fallbackAbortableTasks.forEach(function(Q){return Ps(Q,a,p)}),k.fallbackAbortableTasks.clear()}r=r.row,r!==null&&--r.pendingTasks===0&&Xt(a,r),a.allPendingTasks--,a.allPendingTasks===0&&Uo(a)}function $l(r,a){try{var p=r.renderState,k=p.onHeaders;if(k){var B=p.headers;if(B){p.headers=null;var j=B.preconnects;if(B.fontPreloads&&(j&&(j+=", "),j+=B.fontPreloads),B.highImagePreloads&&(j&&(j+=", "),j+=B.highImagePreloads),!a){var Y=p.styles.values(),Q=Y.next();e:for(;0<B.remainingCapacity&&!Q.done;Q=Y.next())for(var ke=Q.value.sheets.values(),re=ke.next();0<B.remainingCapacity&&!re.done;re=ke.next()){var be=re.value,Ne=be.props,Oe=Ne.href,Fe=be.props,Se=Va(Fe.href,"style",{crossOrigin:Fe.crossOrigin,integrity:Fe.integrity,nonce:Fe.nonce,type:Fe.type,fetchPriority:Fe.fetchPriority,referrerPolicy:Fe.referrerPolicy,media:Fe.media});if(0<=(B.remainingCapacity-=Se.length+2))p.resets.style[Oe]=ce,j&&(j+=", "),j+=Se,p.resets.style[Oe]=typeof Ne.crossOrigin=="string"||typeof Ne.integrity=="string"?[Ne.crossOrigin,Ne.integrity]:ce;else break e}}k(j?{Link:j}:{})}}}catch(ht){Ho(r,ht,{},null)}}function _s(r){r.trackedPostpones===null&&$l(r,!0),r.trackedPostpones===null&&ma(r),r.onShellError=gt,r=r.onShellReady,r()}function Uo(r){$l(r,r.trackedPostpones===null?!0:r.completedRootSegment===null||r.completedRootSegment.status!==qo),ma(r),r=r.onAllReady,r()}function Ns(r,a){if(a.chunks.length===0&&a.children.length===1&&a.children[0].boundary===null&&a.children[0].id===-1){var p=a.children[0];p.id=a.id,p.parentFlushed=!0,p.status!==Ao&&p.status!==Ir&&p.status!==Lt||Ns(r,p)}else r.completedSegments.push(a)}function zr(r,a,p,k){if(p!==null&&(--p.pendingTasks===0?Xt(r,p):p.together&&wl(r,p)),r.allPendingTasks--,a===null){if(k!==null&&k.parentFlushed){if(r.completedRootSegment!==null)throw Error("There can only be one root segment. This is a bug in React.");r.completedRootSegment=k}r.pendingRootTasks--,r.pendingRootTasks===0&&_s(r)}else if(a.pendingTasks--,a.status!==$n)if(a.pendingTasks===0){if(a.status===zl&&(a.status=Ao),k!==null&&k.parentFlushed&&(k.status===Ao||k.status===Ir)&&Ns(a,k),a.parentFlushed&&r.completedBoundaries.push(a),a.status===Ao)p=a.row,p!==null&&yr(p.hoistables,a.contentState),Ja(r,a)||(a.fallbackAbortableTasks.forEach(Il,r),a.fallbackAbortableTasks.clear(),p!==null&&--p.pendingTasks===0&&Xt(r,p)),r.pendingRootTasks===0&&r.trackedPostpones===null&&a.contentPreamble!==null&&ma(r);else if(a.status===qo&&(a=a.row,a!==null)){if(r.trackedPostpones!==null){p=r.trackedPostpones;var B=a.next;if(B!==null&&(k=B.boundaries,k!==null))for(B.boundaries=null,B=0;B<k.length;B++){var j=k[B];Hn(r,p,j),zr(r,j,null,null)}}--a.pendingTasks===0&&Xt(r,a)}}else k===null||!k.parentFlushed||k.status!==Ao&&k.status!==Ir||(Ns(a,k),a.completedSegments.length===1&&a.parentFlushed&&r.partialBoundaries.push(a)),a=a.row,a!==null&&a.together&&wl(r,a);r.allPendingTasks===0&&Uo(r)}function Sc(r){if(r.status!==Wl&&r.status!==13){var a=qe,p=an.H;an.H=ea;var k=an.A;an.A=hu;var B=Nn;Nn=r;var j=an.getCurrentStack;an.getCurrentStack=jr;var Y=du;du=r.resumableState;try{var Q=r.pingedTasks,ke;for(ke=0;ke<Q.length;ke++){var re=r,be=Q[ke],Ne=be.blockedSegment;if(Ne===null){var Oe=void 0,Fe=re;if(re=be,re.replay.pendingTasks!==0){Ht(re.context),Oe=Ar,Ar=re;try{if(typeof re.replay.slots=="number"?Sl(Fe,re,re.replay.slots,re.node,re.childIndex):Ur(Fe,re),re.replay.pendingTasks===1&&0<re.replay.nodes.length)throw Error("Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering.");re.replay.pendingTasks--,re.abortSet.delete(re),zr(Fe,re.blockedBoundary,re.row,null)}catch(on){oo();var Se=on===So?Za():on;if(typeof Se=="object"&&Se!==null&&typeof Se.then=="function"){var ht=re.ping;Se.then(ht,ht),re.thenableState=on===So?Or():null}else{re.replay.pendingTasks--,re.abortSet.delete(re);var Yt=Ql(re.componentStack),Ke=void 0,At=Fe,io=re.blockedBoundary,co=Fe.status===12?Fe.fatalError:Se,Pt=Yt,Xn=re.replay.nodes,gl=re.replay.slots;Ke=Ho(At,co,Pt,re.debugTask),Bl(At,io,Xn,gl,co,Ke,Pt,!1),Fe.pendingRootTasks--,Fe.pendingRootTasks===0&&_s(Fe),Fe.allPendingTasks--,Fe.allPendingTasks===0&&Uo(Fe)}}finally{Ar=Oe}}}else if(Fe=Oe=void 0,Ke=be,At=Ne,At.status===zl){At.status=6,Ht(Ke.context),Fe=Ar,Ar=Ke;var Yo=At.children.length,Ue=At.chunks.length;try{Ur(re,Ke),Ss(At.chunks,re.renderState,At.lastPushedText,At.textEmbedded),Ke.abortSet.delete(Ke),At.status=Ao,zr(re,Ke.blockedBoundary,Ke.row,At)}catch(on){oo(),At.children.length=Yo,At.chunks.length=Ue;var Dt=on===So?Za():re.status===12?re.fatalError:on;if(re.status===12&&re.trackedPostpones!==null){var Ot=re.trackedPostpones,zt=Ql(Ke.componentStack);Ke.abortSet.delete(Ke),Ho(re,Dt,zt,Ke.debugTask),ql(re,Ot,Ke,At),zr(re,Ke.blockedBoundary,Ke.row,At)}else if(typeof Dt=="object"&&Dt!==null&&typeof Dt.then=="function"){At.status=zl,Ke.thenableState=on===So?Or():null;var gn=Ke.ping;Dt.then(gn,gn)}else{var bt=Ql(Ke.componentStack);Ke.abortSet.delete(Ke),At.status=Lt;var st=Ke.blockedBoundary,Io=Ke.row,jt=Ke.debugTask;if(Io!==null&&--Io.pendingTasks===0&&Xt(re,Io),re.allPendingTasks--,Oe=Ho(re,Dt,bt,jt),st===null)Gn(re,Dt,bt,jt);else if(st.pendingTasks--,st.status!==$n){st.status=$n,ga(st,Oe,Dt,bt,!1),Bs(re,st);var uo=st.row;uo!==null&&--uo.pendingTasks===0&&Xt(re,uo),st.parentFlushed&&re.clientRenderedBoundaries.push(st),re.pendingRootTasks===0&&re.trackedPostpones===null&&st.contentPreamble!==null&&ma(re)}re.allPendingTasks===0&&Uo(re)}}finally{Ar=Fe}}}Q.splice(0,ke),r.destination!==null&&ni(r,r.destination)}catch(on){Q={},Ho(r,on,Q,null),Gn(r,on,Q,null)}finally{du=Y,an.H=p,an.A=k,an.getCurrentStack=j,p===ea&&Ht(a),Nn=B}}}function Tc(r,a,p){a.preambleChildren.length&&p.push(a.preambleChildren);for(var k=!1,B=0;B<a.children.length;B++)k=Ac(r,a.children[B],p)||k;return k}function Ac(r,a,p){var k=a.boundary;if(k===null)return Tc(r,a,p);var B=k.contentPreamble,j=k.fallbackPreamble;if(B===null||j===null)return!1;switch(k.status){case Ao:if(Es(r.renderState,B),r.byteSize+=k.byteSize,a=k.completedSegments[0],!a)throw Error("A previously unvisited boundary must have exactly one root segment. This is a bug in React.");return Tc(r,a,p);case qo:if(r.trackedPostpones!==null)return!0;case $n:if(a.status===Ao)return Es(r.renderState,j),Tc(r,a,p);default:return!0}}function ma(r){if(r.completedRootSegment&&r.completedPreambleSegments===null){var a=[],p=r.byteSize,k=Ac(r,r.completedRootSegment,a),B=r.renderState.preamble;k===!1||B.headChunks&&B.bodyChunks?r.completedPreambleSegments=a:r.byteSize=p}}function ba(r,a,p,k){switch(p.parentFlushed=!0,p.status){case zl:p.id=r.nextSegmentId++;case qo:return k=p.id,p.lastPushedText=!1,p.textEmbedded=!1,r=r.renderState,a.push(Dl),a.push(r.placeholderPrefix),r=k.toString(16),a.push(r),a.push(di);case Ao:p.status=bs;var B=!0,j=p.chunks,Y=0;p=p.children;for(var Q=0;Q<p.length;Q++){for(B=p[Q];Y<B.index;Y++)a.push(j[Y]);B=ya(r,a,B,k)}for(;Y<j.length-1;Y++)a.push(j[Y]);return Y<j.length&&(B=a.push(j[Y])),B;case Ir:return!0;default:throw Error("Aborted, errored or already flushed boundaries should not be flushed again. This is a bug in React.")}}function ya(r,a,p,k){var B=p.boundary;if(B===null)return ba(r,a,p,k);if(B.parentFlushed=!0,B.status===$n){var j=B.row;if(j!==null&&--j.pendingTasks===0&&Xt(r,j),!r.renderState.generateStaticMarkup){var Y=B.errorDigest,Q=B.errorMessage;j=B.errorStack,B=B.errorComponentStack,a.push(hi),a.push(wa),Y&&(a.push(Rn),Y=de(Y),a.push(Y),a.push(zs)),Q&&(a.push(pr),Q=de(Q),a.push(Q),a.push(zs)),j&&(a.push(ut),j=de(j),a.push(j),a.push(zs)),B&&(a.push(jl),j=de(B),a.push(j),a.push(zs)),a.push(Ca)}return ba(r,a,p,k),r=r.renderState.generateStaticMarkup?!0:a.push(cs),r}if(B.status!==Ao)return B.status===zl&&(B.rootSegmentID=r.nextSegmentId++),0<B.completedSegments.length&&r.partialBoundaries.push(B),Jn(a,r.renderState,B.rootSegmentID),k&&yr(k,B.fallbackState),ba(r,a,p,k),a.push(cs);if(!Ei&&Ja(r,B)&&oa+B.byteSize>r.progressiveChunkSize)return B.rootSegmentID=r.nextSegmentId++,r.completedBoundaries.push(B),Jn(a,r.renderState,B.rootSegmentID),ba(r,a,p,k),a.push(cs);if(oa+=B.byteSize,k&&yr(k,B.contentState),p=B.row,p!==null&&Ja(r,B)&&--p.pendingTasks===0&&Xt(r,p),r.renderState.generateStaticMarkup||a.push(Ol),p=B.completedSegments,p.length!==1)throw Error("A previously unvisited boundary must have exactly one root segment. This is a bug in React.");return ya(r,a,p[0],k),r=r.renderState.generateStaticMarkup?!0:a.push(cs),r}function Vn(r,a,p,k){return Do(a,r.renderState,p.parentFormatContext,p.id),ya(r,a,p,k),Mr(a,p.parentFormatContext)}function ou(r,a,p){oa=p.byteSize;for(var k=p.completedSegments,B=0;B<k.length;B++)es(r,a,p,k[B]);k.length=0,k=p.row,k!==null&&Ja(r,p)&&--k.pendingTasks===0&&Xt(r,k),xo(a,p.contentState,r.renderState),k=r.resumableState,r=r.renderState,B=p.rootSegmentID,p=p.contentState;var j=r.stylesToHoist;return r.stylesToHoist=!1,a.push(r.startInlineScript),a.push(dt),j?((k.instructions&N)===f&&(k.instructions|=N,a.push(hs)),(k.instructions&w)===f&&(k.instructions|=w,a.push(_n)),(k.instructions&z)===f?(k.instructions|=z,a.push(xi)):a.push(mi)):((k.instructions&w)===f&&(k.instructions|=w,a.push(_n)),a.push(Qi)),k=B.toString(16),a.push(r.boundaryPrefix),a.push(k),a.push(qi),a.push(r.segmentPrefix),a.push(k),j?(a.push(Oc),vc(a,p)):a.push($i),p=a.push(ec),Xl(a,r)&&p}function es(r,a,p,k){if(k.status===bs)return!0;var B=p.contentState,j=k.id;if(j===-1){if((k.id=p.rootSegmentID)===-1)throw Error("A root segment ID must have been assigned by now. This is a bug in React.");return Vn(r,a,k,B)}return j===p.rootSegmentID?Vn(r,a,k,B):(Vn(r,a,k,B),p=r.resumableState,r=r.renderState,a.push(r.startInlineScript),a.push(dt),(p.instructions&v)===f?(p.instructions|=v,a.push(Fc)):a.push(Ji),a.push(r.segmentPrefix),j=j.toString(16),a.push(j),a.push(Mc),a.push(r.placeholderPrefix),a.push(j),a=a.push(Dc),a)}function ni(r,a){try{if(!(0<r.pendingRootTasks)){var p,k=r.completedRootSegment;if(k!==null){if(k.status===qo)return;var B=r.completedPreambleSegments;if(B===null)return;oa=r.byteSize;var j=r.resumableState,Y=r.renderState,Q=Y.preamble,ke=Q.htmlChunks,re=Q.headChunks,be;if(ke){for(be=0;be<ke.length;be++)a.push(ke[be]);if(re)for(be=0;be<re.length;be++)a.push(re[be]);else{var Ne=Tn("head");a.push(Ne),a.push(dt)}}else if(re)for(be=0;be<re.length;be++)a.push(re[be]);var Oe=Y.charsetChunks;for(be=0;be<Oe.length;be++)a.push(Oe[be]);Oe.length=0,Y.preconnects.forEach(Vt,a),Y.preconnects.clear();var Fe=Y.viewportChunks;for(be=0;be<Fe.length;be++)a.push(Fe[be]);Fe.length=0,Y.fontPreloads.forEach(Vt,a),Y.fontPreloads.clear(),Y.highImagePreloads.forEach(Vt,a),Y.highImagePreloads.clear(),we=Y,Y.styles.forEach(vn,a),we=null;var Se=Y.importMapChunks;for(be=0;be<Se.length;be++)a.push(Se[be]);Se.length=0,Y.bootstrapScripts.forEach(Vt,a),Y.scripts.forEach(Vt,a),Y.scripts.clear(),Y.bulkPreloads.forEach(Vt,a),Y.bulkPreloads.clear(),j.instructions|=V;var ht=Y.hoistableChunks;for(be=0;be<ht.length;be++)a.push(ht[be]);for(j=ht.length=0;j<B.length;j++){var Yt=B[j];for(Y=0;Y<Yt.length;Y++)ya(r,a,Yt[Y],null)}var Ke=r.renderState.preamble,At=Ke.headChunks;if(Ke.htmlChunks||At){var io=Wn("head");a.push(io)}var co=Ke.bodyChunks;if(co)for(B=0;B<co.length;B++)a.push(co[B]);ya(r,a,k,null),r.completedRootSegment=null;var Pt=r.renderState;if(r.allPendingTasks!==0||r.clientRenderedBoundaries.length!==0||r.completedBoundaries.length!==0||r.trackedPostpones!==null&&(r.trackedPostpones.rootNodes.length!==0||r.trackedPostpones.rootSlots!==null)){var Xn=r.resumableState;if((Xn.instructions&ge)===f){if(Xn.instructions|=ge,a.push(Pt.startInlineScript),(Xn.instructions&V)===f){Xn.instructions|=V;var gl="_"+Xn.idPrefix+"R_";a.push(Ia);var Yo=de(gl);a.push(Yo),a.push(nt)}a.push(dt),a.push(gr),a.push(ve)}}Xl(a,Pt)}var Ue=r.renderState;k=0;var Dt=Ue.viewportChunks;for(k=0;k<Dt.length;k++)a.push(Dt[k]);Dt.length=0,Ue.preconnects.forEach(Vt,a),Ue.preconnects.clear(),Ue.fontPreloads.forEach(Vt,a),Ue.fontPreloads.clear(),Ue.highImagePreloads.forEach(Vt,a),Ue.highImagePreloads.clear(),Ue.styles.forEach(yc,a),Ue.scripts.forEach(Vt,a),Ue.scripts.clear(),Ue.bulkPreloads.forEach(Vt,a),Ue.bulkPreloads.clear();var Ot=Ue.hoistableChunks;for(k=0;k<Ot.length;k++)a.push(Ot[k]);Ot.length=0;var zt=r.clientRenderedBoundaries;for(p=0;p<zt.length;p++){var gn=zt[p];Ue=a;var bt=r.resumableState,st=r.renderState,Io=gn.rootSegmentID,jt=gn.errorDigest,uo=gn.errorMessage,on=gn.errorStack,$o=gn.errorComponentStack;Ue.push(st.startInlineScript),Ue.push(dt),(bt.instructions&N)===f?(bt.instructions|=N,Ue.push(wr)):Ue.push(au),Ue.push(st.boundaryPrefix);var Da=Io.toString(16);if(Ue.push(Da),Ue.push(Xs),jt||uo||on||$o){Ue.push(bi);var er=On(jt||"");Ue.push(er)}if(uo||on||$o){Ue.push(bi);var pl=On(uo||"");Ue.push(pl)}if(on||$o){Ue.push(bi);var xl=On(on||"");Ue.push(xl)}if($o){Ue.push(bi);var ml=On($o);Ue.push(ml)}var eo=Ue.push(Yr);if(!eo){r.destination=null,p++,zt.splice(0,p);return}}zt.splice(0,p);var o=r.completedBoundaries;for(p=0;p<o.length;p++)if(!ou(r,a,o[p])){r.destination=null,p++,o.splice(0,p);return}o.splice(0,p),Ei=!0;var l=r.partialBoundaries;for(p=0;p<l.length;p++){e:{zt=r,gn=a;var g=l[p];oa=g.byteSize;var E=g.completedSegments;for(eo=0;eo<E.length;eo++)if(!es(zt,gn,g,E[eo])){eo++,E.splice(0,eo);var I=!1;break e}E.splice(0,eo);var F=g.row;F!==null&&F.together&&g.pendingTasks===1&&(F.pendingTasks===1?wc(zt,F,F.hoistables):F.pendingTasks--),I=xo(gn,g.contentState,zt.renderState)}if(!I){r.destination=null,p++,l.splice(0,p);return}}l.splice(0,p),Ei=!1;var G=r.completedBoundaries;for(p=0;p<G.length;p++)if(!ou(r,a,G[p])){r.destination=null,p++,G.splice(0,p);return}G.splice(0,p)}}finally{Ei=!1,r.allPendingTasks===0&&r.clientRenderedBoundaries.length===0&&r.completedBoundaries.length===0&&(r.flushScheduled=!1,p=r.resumableState,p.hasBody&&(l=Wn("body"),a.push(l)),p.hasHtml&&(p=Wn("html"),a.push(p)),r.abortableTasks.size!==0&&console.error("There was still abortable task at the root when we closed. This is a bug in React."),r.status=Wl,a.push(null),r.destination=null)}}function ji(r){r.flushScheduled=r.destination!==null,Sc(r),r.status===10&&(r.status=11),r.trackedPostpones===null&&$l(r,r.pendingRootTasks===0)}function Pl(r){if(r.flushScheduled===!1&&r.pingedTasks.length===0&&r.destination!==null){r.flushScheduled=!0;var a=r.destination;a?ni(r,a):r.flushScheduled=!1}}function ts(r,a){if(r.status===13)r.status=Wl,a.destroy(r.fatalError);else if(r.status!==Wl&&r.destination===null){r.destination=a;try{ni(r,a)}catch(p){a={},Ho(r,p,a,null),Gn(r,p,a,null)}}}function va(r,a){(r.status===11||r.status===10)&&(r.status=12);try{var p=r.abortableTasks;if(0<p.size){var k=a===void 0?Error("The render was aborted by the server without a reason."):typeof a=="object"&&a!==null&&typeof a.then=="function"?Error("The render was aborted by the server with a promise."):a;r.fatalError=k,p.forEach(function(B){var j=Ar,Y=an.getCurrentStack;Ar=B,an.getCurrentStack=jr;try{Ps(B,r,k)}finally{Ar=j,an.getCurrentStack=Y}}),p.clear()}r.destination!==null&&ni(r,r.destination)}catch(B){a={},Ho(r,B,a,null),Gn(r,B,a,null)}}function Wr(r,a,p){if(a===null)p.rootNodes.push(r);else{var k=p.workingMap,B=k.get(a);B===void 0&&(B=[a[1],a[2],[],null],k.set(a,B),Wr(B,a[0],p)),B[2].push(r)}}function ns(){}function os(r,a,p,k){var B=!1,j=null,Y="",Q=!1;if(a=le(a?a.identifierPrefix:void 0),r=fa(r,a,el(a,p),xe(at,null,0,null),1/0,ns,void 0,function(){Q=!0},void 0,void 0,void 0),ji(r),va(r,k),ts(r,{push:function(ke){return ke!==null&&(Y+=ke),!0},destroy:function(ke){B=!0,j=ke}}),B&&j!==k)throw j;if(!Q)throw Error("A component suspended while responding to synchronous input. This will cause the UI to be replaced with a loading indicator. To fix, updates that suspend should be wrapped with startTransition.");return Y}var Ic=React,vu=require$$1,Ls=Symbol.for("react.transitional.element"),Bn=Symbol.for("react.portal"),il=Symbol.for("react.fragment"),oi=Symbol.for("react.strict_mode"),ri=Symbol.for("react.profiler"),Hi=Symbol.for("react.consumer"),ur=Symbol.for("react.context"),dr=Symbol.for("react.forward_ref"),Jo=Symbol.for("react.suspense"),hr=Symbol.for("react.suspense_list"),Ut=Symbol.for("react.memo"),fr=Symbol.for("react.lazy"),$t=Symbol.for("react.scope"),Gr=Symbol.for("react.activity"),Ui=Symbol.for("react.legacy_hidden"),zi=Symbol.for("react.memo_cache_sentinel"),Wi=Symbol.for("react.view_transition"),li=Symbol.iterator,_l=Array.isArray,si=new WeakMap,ai=new WeakMap,zo=Symbol.for("react.client.reference"),en=Object.assign,wt=Object.prototype.hasOwnProperty,rs=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Fs={},Ms={},ls=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" ")),Bc=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Qn={button:!0,checkbox:!0,image:!0,hidden:!0,radio:!0,reset:!0,submit:!0},Ru={"aria-current":0,"aria-description":0,"aria-details":0,"aria-disabled":0,"aria-hidden":0,"aria-invalid":0,"aria-keyshortcuts":0,"aria-label":0,"aria-roledescription":0,"aria-autocomplete":0,"aria-checked":0,"aria-expanded":0,"aria-haspopup":0,"aria-level":0,"aria-modal":0,"aria-multiline":0,"aria-multiselectable":0,"aria-orientation":0,"aria-placeholder":0,"aria-pressed":0,"aria-readonly":0,"aria-required":0,"aria-selected":0,"aria-sort":0,"aria-valuemax":0,"aria-valuemin":0,"aria-valuenow":0,"aria-valuetext":0,"aria-atomic":0,"aria-busy":0,"aria-live":0,"aria-relevant":0,"aria-dropeffect":0,"aria-grabbed":0,"aria-activedescendant":0,"aria-colcount":0,"aria-colindex":0,"aria-colspan":0,"aria-controls":0,"aria-describedby":0,"aria-errormessage":0,"aria-flowto":0,"aria-labelledby":0,"aria-owns":0,"aria-posinset":0,"aria-rowcount":0,"aria-rowindex":0,"aria-rowspan":0,"aria-setsize":0,"aria-braillelabel":0,"aria-brailleroledescription":0,"aria-colindextext":0,"aria-rowindextext":0},Vr={},ru=RegExp("^(aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Pc=RegExp("^(aria)[A-Z][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),cl=!1,ii={accept:"accept",acceptcharset:"acceptCharset","accept-charset":"acceptCharset",accesskey:"accessKey",action:"action",allowfullscreen:"allowFullScreen",alt:"alt",as:"as",async:"async",autocapitalize:"autoCapitalize",autocomplete:"autoComplete",autocorrect:"autoCorrect",autofocus:"autoFocus",autoplay:"autoPlay",autosave:"autoSave",capture:"capture",cellpadding:"cellPadding",cellspacing:"cellSpacing",challenge:"challenge",charset:"charSet",checked:"checked",children:"children",cite:"cite",class:"className",classid:"classID",classname:"className",cols:"cols",colspan:"colSpan",content:"content",contenteditable:"contentEditable",contextmenu:"contextMenu",controls:"controls",controlslist:"controlsList",coords:"coords",crossorigin:"crossOrigin",dangerouslysetinnerhtml:"dangerouslySetInnerHTML",data:"data",datetime:"dateTime",default:"default",defaultchecked:"defaultChecked",defaultvalue:"defaultValue",defer:"defer",dir:"dir",disabled:"disabled",disablepictureinpicture:"disablePictureInPicture",disableremoteplayback:"disableRemotePlayback",download:"download",draggable:"draggable",enctype:"encType",enterkeyhint:"enterKeyHint",fetchpriority:"fetchPriority",for:"htmlFor",form:"form",formmethod:"formMethod",formaction:"formAction",formenctype:"formEncType",formnovalidate:"formNoValidate",formtarget:"formTarget",frameborder:"frameBorder",headers:"headers",height:"height",hidden:"hidden",high:"high",href:"href",hreflang:"hrefLang",htmlfor:"htmlFor",httpequiv:"httpEquiv","http-equiv":"httpEquiv",icon:"icon",id:"id",imagesizes:"imageSizes",imagesrcset:"imageSrcSet",inert:"inert",innerhtml:"innerHTML",inputmode:"inputMode",integrity:"integrity",is:"is",itemid:"itemID",itemprop:"itemProp",itemref:"itemRef",itemscope:"itemScope",itemtype:"itemType",keyparams:"keyParams",keytype:"keyType",kind:"kind",label:"label",lang:"lang",list:"list",loop:"loop",low:"low",manifest:"manifest",marginwidth:"marginWidth",marginheight:"marginHeight",max:"max",maxlength:"maxLength",media:"media",mediagroup:"mediaGroup",method:"method",min:"min",minlength:"minLength",multiple:"multiple",muted:"muted",name:"name",nomodule:"noModule",nonce:"nonce",novalidate:"noValidate",open:"open",optimum:"optimum",pattern:"pattern",placeholder:"placeholder",playsinline:"playsInline",poster:"poster",preload:"preload",profile:"profile",radiogroup:"radioGroup",readonly:"readOnly",referrerpolicy:"referrerPolicy",rel:"rel",required:"required",reversed:"reversed",role:"role",rows:"rows",rowspan:"rowSpan",sandbox:"sandbox",scope:"scope",scoped:"scoped",scrolling:"scrolling",seamless:"seamless",selected:"selected",shape:"shape",size:"size",sizes:"sizes",span:"span",spellcheck:"spellCheck",src:"src",srcdoc:"srcDoc",srclang:"srcLang",srcset:"srcSet",start:"start",step:"step",style:"style",summary:"summary",tabindex:"tabIndex",target:"target",title:"title",type:"type",usemap:"useMap",value:"value",width:"width",wmode:"wmode",wrap:"wrap",about:"about",accentheight:"accentHeight","accent-height":"accentHeight",accumulate:"accumulate",additive:"additive",alignmentbaseline:"alignmentBaseline","alignment-baseline":"alignmentBaseline",allowreorder:"allowReorder",alphabetic:"alphabetic",amplitude:"amplitude",arabicform:"arabicForm","arabic-form":"arabicForm",ascent:"ascent",attributename:"attributeName",attributetype:"attributeType",autoreverse:"autoReverse",azimuth:"azimuth",basefrequency:"baseFrequency",baselineshift:"baselineShift","baseline-shift":"baselineShift",baseprofile:"baseProfile",bbox:"bbox",begin:"begin",bias:"bias",by:"by",calcmode:"calcMode",capheight:"capHeight","cap-height":"capHeight",clip:"clip",clippath:"clipPath","clip-path":"clipPath",clippathunits:"clipPathUnits",cliprule:"clipRule","clip-rule":"clipRule",color:"color",colorinterpolation:"colorInterpolation","color-interpolation":"colorInterpolation",colorinterpolationfilters:"colorInterpolationFilters","color-interpolation-filters":"colorInterpolationFilters",colorprofile:"colorProfile","color-profile":"colorProfile",colorrendering:"colorRendering","color-rendering":"colorRendering",contentscripttype:"contentScriptType",contentstyletype:"contentStyleType",cursor:"cursor",cx:"cx",cy:"cy",d:"d",datatype:"datatype",decelerate:"decelerate",descent:"descent",diffuseconstant:"diffuseConstant",direction:"direction",display:"display",divisor:"divisor",dominantbaseline:"dominantBaseline","dominant-baseline":"dominantBaseline",dur:"dur",dx:"dx",dy:"dy",edgemode:"edgeMode",elevation:"elevation",enablebackground:"enableBackground","enable-background":"enableBackground",end:"end",exponent:"exponent",externalresourcesrequired:"externalResourcesRequired",fill:"fill",fillopacity:"fillOpacity","fill-opacity":"fillOpacity",fillrule:"fillRule","fill-rule":"fillRule",filter:"filter",filterres:"filterRes",filterunits:"filterUnits",floodopacity:"floodOpacity","flood-opacity":"floodOpacity",floodcolor:"floodColor","flood-color":"floodColor",focusable:"focusable",fontfamily:"fontFamily","font-family":"fontFamily",fontsize:"fontSize","font-size":"fontSize",fontsizeadjust:"fontSizeAdjust","font-size-adjust":"fontSizeAdjust",fontstretch:"fontStretch","font-stretch":"fontStretch",fontstyle:"fontStyle","font-style":"fontStyle",fontvariant:"fontVariant","font-variant":"fontVariant",fontweight:"fontWeight","font-weight":"fontWeight",format:"format",from:"from",fx:"fx",fy:"fy",g1:"g1",g2:"g2",glyphname:"glyphName","glyph-name":"glyphName",glyphorientationhorizontal:"glyphOrientationHorizontal","glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphorientationvertical:"glyphOrientationVertical","glyph-orientation-vertical":"glyphOrientationVertical",glyphref:"glyphRef",gradienttransform:"gradientTransform",gradientunits:"gradientUnits",hanging:"hanging",horizadvx:"horizAdvX","horiz-adv-x":"horizAdvX",horizoriginx:"horizOriginX","horiz-origin-x":"horizOriginX",ideographic:"ideographic",imagerendering:"imageRendering","image-rendering":"imageRendering",in2:"in2",in:"in",inlist:"inlist",intercept:"intercept",k1:"k1",k2:"k2",k3:"k3",k4:"k4",k:"k",kernelmatrix:"kernelMatrix",kernelunitlength:"kernelUnitLength",kerning:"kerning",keypoints:"keyPoints",keysplines:"keySplines",keytimes:"keyTimes",lengthadjust:"lengthAdjust",letterspacing:"letterSpacing","letter-spacing":"letterSpacing",lightingcolor:"lightingColor","lighting-color":"lightingColor",limitingconeangle:"limitingConeAngle",local:"local",markerend:"markerEnd","marker-end":"markerEnd",markerheight:"markerHeight",markermid:"markerMid","marker-mid":"markerMid",markerstart:"markerStart","marker-start":"markerStart",markerunits:"markerUnits",markerwidth:"markerWidth",mask:"mask",maskcontentunits:"maskContentUnits",maskunits:"maskUnits",mathematical:"mathematical",mode:"mode",numoctaves:"numOctaves",offset:"offset",opacity:"opacity",operator:"operator",order:"order",orient:"orient",orientation:"orientation",origin:"origin",overflow:"overflow",overlineposition:"overlinePosition","overline-position":"overlinePosition",overlinethickness:"overlineThickness","overline-thickness":"overlineThickness",paintorder:"paintOrder","paint-order":"paintOrder",panose1:"panose1","panose-1":"panose1",pathlength:"pathLength",patterncontentunits:"patternContentUnits",patterntransform:"patternTransform",patternunits:"patternUnits",pointerevents:"pointerEvents","pointer-events":"pointerEvents",points:"points",pointsatx:"pointsAtX",pointsaty:"pointsAtY",pointsatz:"pointsAtZ",popover:"popover",popovertarget:"popoverTarget",popovertargetaction:"popoverTargetAction",prefix:"prefix",preservealpha:"preserveAlpha",preserveaspectratio:"preserveAspectRatio",primitiveunits:"primitiveUnits",property:"property",r:"r",radius:"radius",refx:"refX",refy:"refY",renderingintent:"renderingIntent","rendering-intent":"renderingIntent",repeatcount:"repeatCount",repeatdur:"repeatDur",requiredextensions:"requiredExtensions",requiredfeatures:"requiredFeatures",resource:"resource",restart:"restart",result:"result",results:"results",rotate:"rotate",rx:"rx",ry:"ry",scale:"scale",security:"security",seed:"seed",shaperendering:"shapeRendering","shape-rendering":"shapeRendering",slope:"slope",spacing:"spacing",specularconstant:"specularConstant",specularexponent:"specularExponent",speed:"speed",spreadmethod:"spreadMethod",startoffset:"startOffset",stddeviation:"stdDeviation",stemh:"stemh",stemv:"stemv",stitchtiles:"stitchTiles",stopcolor:"stopColor","stop-color":"stopColor",stopopacity:"stopOpacity","stop-opacity":"stopOpacity",strikethroughposition:"strikethroughPosition","strikethrough-position":"strikethroughPosition",strikethroughthickness:"strikethroughThickness","strikethrough-thickness":"strikethroughThickness",string:"string",stroke:"stroke",strokedasharray:"strokeDasharray","stroke-dasharray":"strokeDasharray",strokedashoffset:"strokeDashoffset","stroke-dashoffset":"strokeDashoffset",strokelinecap:"strokeLinecap","stroke-linecap":"strokeLinecap",strokelinejoin:"strokeLinejoin","stroke-linejoin":"strokeLinejoin",strokemiterlimit:"strokeMiterlimit","stroke-miterlimit":"strokeMiterlimit",strokewidth:"strokeWidth","stroke-width":"strokeWidth",strokeopacity:"strokeOpacity","stroke-opacity":"strokeOpacity",suppresscontenteditablewarning:"suppressContentEditableWarning",suppresshydrationwarning:"suppressHydrationWarning",surfacescale:"surfaceScale",systemlanguage:"systemLanguage",tablevalues:"tableValues",targetx:"targetX",targety:"targetY",textanchor:"textAnchor","text-anchor":"textAnchor",textdecoration:"textDecoration","text-decoration":"textDecoration",textlength:"textLength",textrendering:"textRendering","text-rendering":"textRendering",to:"to",transform:"transform",transformorigin:"transformOrigin","transform-origin":"transformOrigin",typeof:"typeof",u1:"u1",u2:"u2",underlineposition:"underlinePosition","underline-position":"underlinePosition",underlinethickness:"underlineThickness","underline-thickness":"underlineThickness",unicode:"unicode",unicodebidi:"unicodeBidi","unicode-bidi":"unicodeBidi",unicoderange:"unicodeRange","unicode-range":"unicodeRange",unitsperem:"unitsPerEm","units-per-em":"unitsPerEm",unselectable:"unselectable",valphabetic:"vAlphabetic","v-alphabetic":"vAlphabetic",values:"values",vectoreffect:"vectorEffect","vector-effect":"vectorEffect",version:"version",vertadvy:"vertAdvY","vert-adv-y":"vertAdvY",vertoriginx:"vertOriginX","vert-origin-x":"vertOriginX",vertoriginy:"vertOriginY","vert-origin-y":"vertOriginY",vhanging:"vHanging","v-hanging":"vHanging",videographic:"vIdeographic","v-ideographic":"vIdeographic",viewbox:"viewBox",viewtarget:"viewTarget",visibility:"visibility",vmathematical:"vMathematical","v-mathematical":"vMathematical",vocab:"vocab",widths:"widths",wordspacing:"wordSpacing","word-spacing":"wordSpacing",writingmode:"writingMode","writing-mode":"writingMode",x1:"x1",x2:"x2",x:"x",xchannelselector:"xChannelSelector",xheight:"xHeight","x-height":"xHeight",xlinkactuate:"xlinkActuate","xlink:actuate":"xlinkActuate",xlinkarcrole:"xlinkArcrole","xlink:arcrole":"xlinkArcrole",xlinkhref:"xlinkHref","xlink:href":"xlinkHref",xlinkrole:"xlinkRole","xlink:role":"xlinkRole",xlinkshow:"xlinkShow","xlink:show":"xlinkShow",xlinktitle:"xlinkTitle","xlink:title":"xlinkTitle",xlinktype:"xlinkType","xlink:type":"xlinkType",xmlbase:"xmlBase","xml:base":"xmlBase",xmllang:"xmlLang","xml:lang":"xmlLang",xmlns:"xmlns","xml:space":"xmlSpace",xmlnsxlink:"xmlnsXlink","xmlns:xlink":"xmlnsXlink",xmlspace:"xmlSpace",y1:"y1",y2:"y2",y:"y",ychannelselector:"yChannelSelector",z:"z",zoomandpan:"zoomAndPan"},ro={},Nl=/^on./,lu=/^on[^A-Z]/,Ds=RegExp("^(aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Gi=RegExp("^(aria)[A-Z][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Os=/^(?:webkit|moz|o)[A-Z]/,lo=/^-ms-/,qn=/-(.)/g,ss=/;\s*$/,Zt={},Mt={},js=!1,Ra=!1,Vi=/["'&<>]/,Ea=/([A-Z])/g,_c=/^ms-/,Eu=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i,an=Ic.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Ll=vu.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,su=Object.freeze({pending:!1,data:null,method:null,action:null}),u=Ll.d;Ll.d={f:u.f,r:u.r,D:function(r){var a=Nn||null;if(a){var p=a.resumableState,k=a.renderState;if(typeof r=="string"&&r){if(!p.dnsResources.hasOwnProperty(r)){p.dnsResources[r]=J,p=k.headers;var B,j;(j=p&&0<p.remainingCapacity)&&(j=(B="<"+sn(r)+">; rel=dns-prefetch",0<=(p.remainingCapacity-=B.length+2))),j?(k.resets.dns[r]=J,p.preconnects&&(p.preconnects+=", "),p.preconnects+=B):(B=[],Cn(B,{href:r,rel:"dns-prefetch"}),k.preconnects.add(B))}Pl(a)}}else u.D(r)},C:function(r,a){var p=Nn||null;if(p){var k=p.resumableState,B=p.renderState;if(typeof r=="string"&&r){var j=a==="use-credentials"?"credentials":typeof a=="string"?"anonymous":"default";if(!k.connectResources[j].hasOwnProperty(r)){k.connectResources[j][r]=J,k=B.headers;var Y,Q;if(Q=k&&0<k.remainingCapacity){if(Q="<"+sn(r)+">; rel=preconnect",typeof a=="string"){var ke=Ni(a,"crossOrigin");Q+='; crossorigin="'+ke+'"'}Q=(Y=Q,0<=(k.remainingCapacity-=Y.length+2))}Q?(B.resets.connect[j][r]=J,k.preconnects&&(k.preconnects+=", "),k.preconnects+=Y):(j=[],Cn(j,{rel:"preconnect",href:r,crossOrigin:a}),B.preconnects.add(j))}Pl(p)}}else u.C(r,a)},L:function(r,a,p){var k=Nn||null;if(k){var B=k.resumableState,j=k.renderState;if(a&&r){switch(a){case"image":if(p)var Y=p.imageSrcSet,Q=p.imageSizes,ke=p.fetchPriority;var re=Y?Y+`
134
+ `+(Q||""):r;if(B.imageResources.hasOwnProperty(re))return;B.imageResources[re]=ce,B=j.headers;var be;B&&0<B.remainingCapacity&&typeof Y!="string"&&ke==="high"&&(be=Va(r,a,p),0<=(B.remainingCapacity-=be.length+2))?(j.resets.image[re]=ce,B.highImagePreloads&&(B.highImagePreloads+=", "),B.highImagePreloads+=be):(B=[],Cn(B,en({rel:"preload",href:Y?void 0:r,as:a},p)),ke==="high"?j.highImagePreloads.add(B):(j.bulkPreloads.add(B),j.preloads.images.set(re,B)));break;case"style":if(B.styleResources.hasOwnProperty(r))return;Y=[],Cn(Y,en({rel:"preload",href:r,as:a},p)),B.styleResources[r]=!p||typeof p.crossOrigin!="string"&&typeof p.integrity!="string"?ce:[p.crossOrigin,p.integrity],j.preloads.stylesheets.set(r,Y),j.bulkPreloads.add(Y);break;case"script":if(B.scriptResources.hasOwnProperty(r))return;Y=[],j.preloads.scripts.set(r,Y),j.bulkPreloads.add(Y),Cn(Y,en({rel:"preload",href:r,as:a},p)),B.scriptResources[r]=!p||typeof p.crossOrigin!="string"&&typeof p.integrity!="string"?ce:[p.crossOrigin,p.integrity];break;default:if(B.unknownResources.hasOwnProperty(a)){if(Y=B.unknownResources[a],Y.hasOwnProperty(r))return}else Y={},B.unknownResources[a]=Y;if(Y[r]=ce,(B=j.headers)&&0<B.remainingCapacity&&a==="font"&&(re=Va(r,a,p),0<=(B.remainingCapacity-=re.length+2)))j.resets.font[r]=ce,B.fontPreloads&&(B.fontPreloads+=", "),B.fontPreloads+=re;else switch(B=[],r=en({rel:"preload",href:r,as:a},p),Cn(B,r),a){case"font":j.fontPreloads.add(B);break;default:j.bulkPreloads.add(B)}}Pl(k)}}else u.L(r,a,p)},m:function(r,a){var p=Nn||null;if(p){var k=p.resumableState,B=p.renderState;if(r){var j=a&&typeof a.as=="string"?a.as:"script";switch(j){case"script":if(k.moduleScriptResources.hasOwnProperty(r))return;j=[],k.moduleScriptResources[r]=!a||typeof a.crossOrigin!="string"&&typeof a.integrity!="string"?ce:[a.crossOrigin,a.integrity],B.preloads.moduleScripts.set(r,j);break;default:if(k.moduleUnknownResources.hasOwnProperty(j)){var Y=k.unknownResources[j];if(Y.hasOwnProperty(r))return}else Y={},k.moduleUnknownResources[j]=Y;j=[],Y[r]=ce}Cn(j,en({rel:"modulepreload",href:r},a)),B.bulkPreloads.add(j),Pl(p)}}else u.m(r,a)},X:function(r,a){var p=Nn||null;if(p){var k=p.resumableState,B=p.renderState;if(r){var j=k.scriptResources.hasOwnProperty(r)?k.scriptResources[r]:void 0;j!==J&&(k.scriptResources[r]=J,a=en({src:r,async:!0},a),j&&(j.length===2&&ws(a,j),r=B.preloads.scripts.get(r))&&(r.length=0),r=[],B.scripts.add(r),Sn(r,a),Pl(p))}}else u.X(r,a)},S:function(r,a,p){var k=Nn||null;if(k){var B=k.resumableState,j=k.renderState;if(r){a=a||"default";var Y=j.styles.get(a),Q=B.styleResources.hasOwnProperty(r)?B.styleResources[r]:void 0;Q!==J&&(B.styleResources[r]=J,Y||(Y={precedence:de(a),rules:[],hrefs:[],sheets:new Map},j.styles.set(a,Y)),a={state:P,props:en({rel:"stylesheet",href:r,"data-precedence":a},p)},Q&&(Q.length===2&&ws(a.props,Q),(j=j.preloads.stylesheets.get(r))&&0<j.length?j.length=0:a.state=H),Y.sheets.set(r,a),Pl(k))}}else u.S(r,a,p)},M:function(r,a){var p=Nn||null;if(p){var k=p.resumableState,B=p.renderState;if(r){var j=k.moduleScriptResources.hasOwnProperty(r)?k.moduleScriptResources[r]:void 0;j!==J&&(k.moduleScriptResources[r]=J,a=en({src:r,type:"module",async:!0},a),j&&(j.length===2&&ws(a,j),r=B.preloads.moduleScripts.get(r))&&(r.length=0),r=[],B.scripts.add(r),Sn(r,a),Pl(p))}}else u.M(r,a)}};var f=0,v=1,w=2,N=4,z=8,V=32,ge=64,J=null,ce=[];Object.freeze(ce);var we=null,ve="<\/script>",Le=/(<\/|<)(s)(cript)/gi,Ge={},at=0,Qe=1,Xe=2,tt=3,Je=4,tn=5,ct=6,mt=7,Bt=8,lt=9,un=new Map,Ct=' style="',bo=":",Nt=";",yt=" ",St='="',nt='"',Tt='=""',Yn=de("javascript:throw new Error('React form unexpectedly submitted.')"),dt=">",as="/>",Fl=!1,yo=!1,vr=!1,Rr=!1,Er=!1,ul=!1,Ml=!1,Un=!1,Hs=!1,Us=!1,ci=!1,Yi=`addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error('React form unexpectedly submitted.')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});`,ka=/(<\/|<)(s)(tyle)/gi,is=`
135
+ `,vo=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,ui=new Map,Ro=new Map,gr="requestAnimationFrame(function(){$RT=performance.now()});",Dl='<template id="',di='"></template>',Ol="<!--$-->",Xi='<!--$?--><template id="',Pn='"></template>',hi="<!--$!-->",cs="<!--/$-->",wa="<template",zs='"',Rn=' data-dgst="',pr=' data-msg="',ut=' data-stck="',jl=' data-cstck="',Ca="></template>",us='<div hidden id="',dn='">',Wo="</div>",ds='<svg aria-hidden="true" style="display:none" id="',Ws='">',kr="</svg>",so='<math aria-hidden="true" style="display:none" id="',Sa='">',Eo="</math>",Nc='<table hidden id="',Gs='">',fi="</table>",Zi='<table hidden><tbody id="',Ki='">',dl="</tbody></table>",Vs='<table hidden><tr id="',Ys='">',ko="</tr></table>",gi='<table hidden><colgroup id="',pi='">',Lc="</colgroup></table>",Fc='$RS=function(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("',Ji='$RS("',Mc='","',Dc='")<\/script>',_n=`$RB=[];$RV=function(a){$RT=performance.now();for(var b=0;b<a.length;b+=2){var c=a[b],e=a[b+1];null!==e.parentNode&&e.parentNode.removeChild(e);var f=c.parentNode;if(f){var g=c.previousSibling,h=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d||"/&"===d)if(0===h)break;else h--;else"$"!==d&&"$?"!==d&&"$~"!==d&&"$!"!==d&&"&"!==d||h++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;e.firstChild;)f.insertBefore(e.firstChild,c);g.data="$";g._reactRetry&&requestAnimationFrame(g._reactRetry)}}a.length=0};
136
+ $RC=function(a,b){if(b=document.getElementById(b))(a=document.getElementById(a))?(a.previousSibling.data="$~",$RB.push(a,b),2===$RB.length&&("number"!==typeof $RT?requestAnimationFrame($RV.bind(null,$RB)):(a=performance.now(),setTimeout($RV.bind(null,$RB),2300>a&&2E3<a?2300-a:$RT+300-a)))):b.parentNode.removeChild(b)};`,Qi='$RC("',xi=`$RM=new Map;$RR=function(n,w,p){function u(q){this._p=null;q()}for(var r=new Map,t=document,h,b,e=t.querySelectorAll("link[data-precedence],style[data-precedence]"),v=[],k=0;b=e[k++];)"not all"===b.getAttribute("media")?v.push(b):("LINK"===b.tagName&&$RM.set(b.getAttribute("href"),b),r.set(b.dataset.precedence,h=b));e=0;b=[];var l,a;for(k=!0;;){if(k){var f=p[e++];if(!f){k=!1;e=0;continue}var c=!1,m=0;var d=f[m++];if(a=$RM.get(d)){var g=a._p;c=!0}else{a=t.createElement("link");a.href=d;a.rel=
137
+ "stylesheet";for(a.dataset.precedence=l=f[m++];g=f[m++];)a.setAttribute(g,f[m++]);g=a._p=new Promise(function(q,x){a.onload=u.bind(a,q);a.onerror=u.bind(a,x)});$RM.set(d,a)}d=a.getAttribute("media");!g||d&&!matchMedia(d).matches||b.push(g);if(c)continue}else{a=v[e++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=r.get(l)||h;c===h&&(h=a);r.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=t.head,c.insertBefore(a,c.firstChild))}if(p=document.getElementById(n))p.previousSibling.data=
138
+ "$~";Promise.all(b).then($RC.bind(null,n,w),$RX.bind(null,n,"CSS failed to load"))};$RR("`,mi='$RR("',qi='","',Oc='",',$i='"',ec=")<\/script>",hs='$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};',wr='$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};;$RX("',au='$RX("',Xs='"',bi=",",Yr=")<\/script>",Ta=/[<\u2028\u2029]/g,fs=/[&><\u2028\u2029]/g,yi=' media="not all" data-precedence="',gs='" data-href="',iu='">',cu="</style>",Xr=!1,Aa=!0,xr=[],ps=' data-precedence="',Zs='" data-href="',Cr=" ",jc='">',uu="</style>",Ia=' id="',i="[",h=",[",m=",",C="]",P=0,H=1,W=2,ne=3,X=/[<>\r\n]/g,oe=/["';,\r\n]/g,fe="",me=Function.prototype.bind,De=Symbol.for("react.client.reference"),Me={};Object.freeze(Me);var pt={},qe=null,xt={},hn={},Kt=new Set,ao=new Set,Qo=new Set,Sr=new Set,$e=new Set,wo=new Set,En=new Set,Go=new Set,Hl=new Set,fn={enqueueSetState:function(r,a,p){var k=r._reactInternals;k.queue===null?ir(r,"setState"):(k.queue.push(a),p!=null&&Ya(p))},enqueueReplaceState:function(r,a,p){r=r._reactInternals,r.replace=!0,r.queue=[a],p!=null&&Ya(p)},enqueueForceUpdate:function(r,a){r._reactInternals.queue===null?ir(r,"forceUpdate"):a!=null&&Ya(a)}},Ks={id:1,overflow:""},Tr=Math.clz32?Math.clz32:$c,Co=Math.log,Zr=Math.LN2,So=Error("Suspense Exception: This is not a real error! It's an implementation detail of `use` to interrupt the current render. You must either rethrow it immediately, or move the `use` call outside of the `try/catch` block. Capturing without rethrowing will lead to unexpected behavior.\n\nTo handle async errors, wrap your component in an error boundary, or call the promise's `.catch` method and pass the result to `use`."),Js=null,Ba=typeof Object.is=="function"?Object.is:Ka,Vo=null,Pa=null,To=null,Qs=null,Hc=null,nn=null,_a=!1,Kr=!1,tc=0,qs=0,nc=-1,oc=0,Na=null,xs=null,rc=0,hl=!1,$s,ea={readContext:As,use:function(r){if(r!==null&&typeof r=="object"){if(typeof r.then=="function")return cr(r);if(r.$$typeof===ur)return As(r)}throw Error("An unsupported type was passed to use(): "+String(r))},useContext:function(r){return $s="useContext",tl(),r._currentValue2},useMemo:eu,useReducer:mo,useRef:function(r){Vo=tl(),nn=kt();var a=nn.memoizedState;return a===null?(r={current:r},Object.seal(r),nn.memoizedState=r):a},useState:function(r){return $s="useState",mo(Li,r)},useInsertionEffect:gt,useLayoutEffect:gt,useCallback:function(r,a){return eu(function(){return r},a)},useImperativeHandle:gt,useEffect:gt,useDebugValue:gt,useDeferredValue:function(r,a){return tl(),a!==void 0?a:r},useTransition:function(){return tl(),[!1,qt]},useId:function(){var r=Pa.treeContext,a=r.overflow;r=r.id,r=(r&~(1<<32-Tr(r)-1)).toString(32)+a;var p=du;if(p===null)throw Error("Invalid hook call. Hooks can only be called inside of the body of a function component.");return a=tc++,r="_"+p.idPrefix+"R_"+r,0<a&&(r+="H"+a.toString(32)),r+"_"},useSyncExternalStore:function(r,a,p){if(p===void 0)throw Error("Missing getServerSnapshot, which is required for server-rendered content. Will revert to client rendering.");return p()},useOptimistic:function(r){return tl(),[r,Mi]},useActionState:ua,useFormState:ua,useHostTransitionStatus:function(){return tl(),su},useMemoCache:function(r){for(var a=Array(r),p=0;p<r;p++)a[p]=zi;return a},useCacheRefresh:function(){return Is},useEffectEvent:function(){return Fi}},du=null,Ar=null,hu={getCacheForType:function(){throw Error("Not implemented.")},cacheSignal:function(){throw Error("Not implemented.")},getOwner:function(){return Ar===null?null:Ar.componentStack}},mr=0,ms,Ul,lc,sc,ac,ta,fu;tu.__reactDisabledLog=!0;var Uc,La,gu=!1,ic=new(typeof WeakMap=="function"?WeakMap:Map),ku={react_stack_bottom_frame:function(r,a,p){return r(a,p)}},zc=ku.react_stack_bottom_frame.bind(ku),wu={react_stack_bottom_frame:function(r){return r.render()}},cc=wu.react_stack_bottom_frame.bind(wu),Fa={react_stack_bottom_frame:function(r){var a=r._init;return a(r._payload)}},Bu=Fa.react_stack_bottom_frame.bind(Fa),Pu=0;if(typeof performance=="object"&&typeof performance.now=="function")var fl=performance,pu=function(){return fl.now()};else{var _u=Date;pu=function(){return _u.now()}}var $n=4,zl=0,Ao=1,bs=2,Ir=3,Lt=4,qo=5,Wl=14,Nn=null,vi={},uc={},xu={},Ma={},na=!1,Ri=!1,Jr=!1,oa=0,Ei=!1;reactDomServerLegacy_browser_development.renderToStaticMarkup=function(r,a){return os(r,a,!0,'The server used "renderToStaticMarkup" which does not support Suspense. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server')},reactDomServerLegacy_browser_development.renderToString=function(r,a){return os(r,a,!1,'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server')},reactDomServerLegacy_browser_development.version="19.2.0"}()),reactDomServerLegacy_browser_development}var reactDomServer_browser_development={};/**
139
+ * @license React
140
+ * react-dom-server.browser.development.js
141
+ *
142
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
143
+ *
144
+ * This source code is licensed under the MIT license found in the
145
+ * LICENSE file in the root directory of this source tree.
146
+ */var hasRequiredReactDomServer_browser_development;function requireReactDomServer_browser_development(){return hasRequiredReactDomServer_browser_development||(hasRequiredReactDomServer_browser_development=1,process.env.NODE_ENV!=="production"&&function(){function n(o,l,g,E){return""+l+(g==="s"?"\\73 ":"\\53 ")+E}function c(o,l,g,E){return""+l+(g==="s"?"\\u0073":"\\u0053")+E}function d(o){return o===null||typeof o!="object"?null:(o=Pc&&o[Pc]||o["@@iterator"],typeof o=="function"?o:null)}function x(o){return o=Object.prototype.toString.call(o),o.slice(8,o.length-1)}function b(o){var l=JSON.stringify(o);return'"'+o+'"'===l?o:l}function y(o){switch(typeof o){case"string":return JSON.stringify(10>=o.length?o:o.slice(0,10)+"...");case"object":return cl(o)?"[...]":o!==null&&o.$$typeof===Nl?"client":(o=x(o),o==="Object"?"{...}":o);case"function":return o.$$typeof===Nl?"client":(o=o.displayName||o.name)?"function "+o:"function";default:return String(o)}}function R(o){if(typeof o=="string")return o;switch(o){case rs:return"Suspense";case Fs:return"SuspenseList"}if(typeof o=="object")switch(o.$$typeof){case wt:return R(o.render);case Ms:return R(o.type);case ls:var l=o._payload;o=o._init;try{return R(o(l))}catch{}}return""}function S(o,l){var g=x(o);if(g!=="Object"&&g!=="Array")return g;var E=-1,I=0;if(cl(o))if(ro.has(o)){var F=ro.get(o);g="<"+R(F)+">";for(var G=0;G<o.length;G++){var Z=o[G];Z=typeof Z=="string"?Z:typeof Z=="object"&&Z!==null?"{"+S(Z)+"}":"{"+y(Z)+"}",""+G===l?(E=g.length,I=Z.length,g+=Z):g=15>Z.length&&40>g.length+Z.length?g+Z:g+"{...}"}g+="</"+R(F)+">"}else{for(g="[",F=0;F<o.length;F++)0<F&&(g+=", "),G=o[F],G=typeof G=="object"&&G!==null?S(G):y(G),""+F===l?(E=g.length,I=G.length,g+=G):g=10>G.length&&40>g.length+G.length?g+G:g+"...";g+="]"}else if(o.$$typeof===Wi)g="<"+R(o.type)+"/>";else{if(o.$$typeof===Nl)return"client";if(ii.has(o)){for(g=ii.get(o),g="<"+(R(g)||"..."),F=Object.keys(o),G=0;G<F.length;G++){g+=" ",Z=F[G],g+=b(Z)+"=";var pe=o[Z],te=Z===l&&typeof pe=="object"&&pe!==null?S(pe):y(pe);typeof pe!="string"&&(te="{"+te+"}"),Z===l?(E=g.length,I=te.length,g+=te):g=10>te.length&&40>g.length+te.length?g+te:g+"..."}g+=">"}else{for(g="{",F=Object.keys(o),G=0;G<F.length;G++)0<G&&(g+=", "),Z=F[G],g+=b(Z)+": ",pe=o[Z],pe=typeof pe=="object"&&pe!==null?S(pe):y(pe),Z===l?(E=g.length,I=pe.length,g+=pe):g=10>pe.length&&40>g.length+pe.length?g+pe:g+"...";g+="}"}}return l===void 0?g:-1<E&&0<I?(o=" ".repeat(E)+"^".repeat(I),`
147
+ `+g+`
148
+ `+o):`
149
+ `+g}function _(o,l){var g=o.length&3,E=o.length-g,I=l;for(l=0;l<E;){var F=o.charCodeAt(l)&255|(o.charCodeAt(++l)&255)<<8|(o.charCodeAt(++l)&255)<<16|(o.charCodeAt(++l)&255)<<24;++l,F=3432918353*(F&65535)+((3432918353*(F>>>16)&65535)<<16)&4294967295,F=F<<15|F>>>17,F=461845907*(F&65535)+((461845907*(F>>>16)&65535)<<16)&4294967295,I^=F,I=I<<13|I>>>19,I=5*(I&65535)+((5*(I>>>16)&65535)<<16)&4294967295,I=(I&65535)+27492+(((I>>>16)+58964&65535)<<16)}switch(F=0,g){case 3:F^=(o.charCodeAt(l+2)&255)<<16;case 2:F^=(o.charCodeAt(l+1)&255)<<8;case 1:F^=o.charCodeAt(l)&255,F=3432918353*(F&65535)+((3432918353*(F>>>16)&65535)<<16)&4294967295,F=F<<15|F>>>17,I^=461845907*(F&65535)+((461845907*(F>>>16)&65535)<<16)&4294967295}return I^=o.length,I^=I>>>16,I=2246822507*(I&65535)+((2246822507*(I>>>16)&65535)<<16)&4294967295,I^=I>>>13,I=3266489909*(I&65535)+((3266489909*(I>>>16)&65535)<<16)&4294967295,(I^I>>>16)>>>0}function A(o){Ds.push(o),lu.port2.postMessage(null)}function L(o){setTimeout(function(){throw o})}function T(o,l){if(l.byteLength!==0)if(2048<l.byteLength)0<qn&&(o.enqueue(new Uint8Array(lo.buffer,0,qn)),lo=new Uint8Array(2048),qn=0),o.enqueue(l);else{var g=lo.length-qn;g<l.byteLength&&(g===0?o.enqueue(lo):(lo.set(l.subarray(0,g),qn),o.enqueue(lo),l=l.subarray(g)),lo=new Uint8Array(2048),qn=0),lo.set(l,qn),qn+=l.byteLength}}function O(o,l){return T(o,l),!0}function U(o){lo&&0<qn&&(o.enqueue(new Uint8Array(lo.buffer,0,qn)),lo=null,qn=0)}function M(o){return ss.encode(o)}function D(o){return o=ss.encode(o),2048<o.byteLength&&console.error("precomputed chunks must be smaller than the view size configured for this host. This is a bug in React."),o}function K(o){return o.byteLength}function $(o,l){typeof o.error=="function"?o.error(l):o.close()}function ee(o){return typeof Symbol=="function"&&Symbol.toStringTag&&o[Symbol.toStringTag]||o.constructor.name||"Object"}function ae(o){try{return Re(o),!1}catch{return!0}}function Re(o){return""+o}function ye(o,l){if(ae(o))return console.error("The provided `%s` attribute is an unsupported type %s. This value must be coerced to a string before using it here.",l,ee(o)),Re(o)}function de(o,l){if(ae(o))return console.error("The provided `%s` CSS property is an unsupported type %s. This value must be coerced to a string before using it here.",l,ee(o)),Re(o)}function q(o){if(ae(o))return console.error("The provided HTML markup uses a value of unsupported type %s. This value must be coerced to a string before using it here.",ee(o)),Re(o)}function he(o){return Mt.call(Vi,o)?!0:Mt.call(Ra,o)?!1:js.test(o)?Vi[o]=!0:(Ra[o]=!0,console.error("Invalid attribute name: `%s`",o),!1)}function le(o,l){Eu[l.type]||l.onChange||l.onInput||l.readOnly||l.disabled||l.value==null||console.error(o==="select"?"You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set `onChange`.":"You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`."),l.onChange||l.readOnly||l.disabled||l.checked==null||console.error("You provided a `checked` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultChecked`. Otherwise, set either `onChange` or `readOnly`.")}function xe(o,l){if(Mt.call(Ll,l)&&Ll[l])return!0;if(u.test(l)){if(o="aria-"+l.slice(4).toLowerCase(),o=an.hasOwnProperty(o)?o:null,o==null)return console.error("Invalid ARIA attribute `%s`. ARIA attributes follow the pattern aria-* and must be lowercase.",l),Ll[l]=!0;if(l!==o)return console.error("Invalid ARIA attribute `%s`. Did you mean `%s`?",l,o),Ll[l]=!0}if(su.test(l)){if(o=l.toLowerCase(),o=an.hasOwnProperty(o)?o:null,o==null)return Ll[l]=!0,!1;l!==o&&(console.error("Unknown ARIA attribute `%s`. Did you mean `%s`?",l,o),Ll[l]=!0)}return!0}function Ee(o,l){var g=[],E;for(E in l)xe(o,E)||g.push(E);l=g.map(function(I){return"`"+I+"`"}).join(", "),g.length===1?console.error("Invalid aria prop %s on <%s> tag. For details, see https://react.dev/link/invalid-aria-props",l,o):1<g.length&&console.error("Invalid aria props %s on <%s> tag. For details, see https://react.dev/link/invalid-aria-props",l,o)}function je(o,l,g,E){if(Mt.call(w,l)&&w[l])return!0;var I=l.toLowerCase();if(I==="onfocusin"||I==="onfocusout")return console.error("React uses onFocus and onBlur instead of onFocusIn and onFocusOut. All React events are normalized to bubble, so onFocusIn and onFocusOut are not needed/supported by React."),w[l]=!0;if(typeof g=="function"&&(o==="form"&&l==="action"||o==="input"&&l==="formAction"||o==="button"&&l==="formAction"))return!0;if(N.test(l))return z.test(l)&&console.error("Invalid event handler property `%s`. React events use the camelCase naming convention, for example `onClick`.",l),w[l]=!0;if(V.test(l)||ge.test(l))return!0;if(I==="innerhtml")return console.error("Directly setting property `innerHTML` is not permitted. For more information, lookup documentation on `dangerouslySetInnerHTML`."),w[l]=!0;if(I==="aria")return console.error("The `aria` attribute is reserved for future use in React. Pass individual `aria-` attributes instead."),w[l]=!0;if(I==="is"&&g!==null&&g!==void 0&&typeof g!="string")return console.error("Received a `%s` for a string attribute `is`. If this is expected, cast the value to a string.",typeof g),w[l]=!0;if(typeof g=="number"&&isNaN(g))return console.error("Received NaN for the `%s` attribute. If this is expected, cast the value to a string.",l),w[l]=!0;if(v.hasOwnProperty(I)){if(I=v[I],I!==l)return console.error("Invalid DOM property `%s`. Did you mean `%s`?",l,I),w[l]=!0}else if(l!==I)return console.error("React does not recognize the `%s` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `%s` instead. If you accidentally passed it from a parent component, remove it from the DOM element.",l,I),w[l]=!0;switch(l){case"dangerouslySetInnerHTML":case"children":case"style":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":return!0;case"innerText":case"textContent":return!0}switch(typeof g){case"boolean":switch(l){case"autoFocus":case"checked":case"multiple":case"muted":case"selected":case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":case"capture":case"download":case"inert":return!0;default:return I=l.toLowerCase().slice(0,5),I==="data-"||I==="aria-"?!0:(g?console.error('Received `%s` for a non-boolean attribute `%s`.\n\nIf you want to write it to the DOM, pass a string instead: %s="%s" or %s={value.toString()}.',g,l,l,g,l):console.error('Received `%s` for a non-boolean attribute `%s`.\n\nIf you want to write it to the DOM, pass a string instead: %s="%s" or %s={value.toString()}.\n\nIf you used to conditionally omit it with %s={condition && value}, pass %s={condition ? value : undefined} instead.',g,l,l,g,l,l,l),w[l]=!0)}case"function":case"symbol":return w[l]=!0,!1;case"string":if(g==="false"||g==="true"){switch(l){case"checked":case"selected":case"multiple":case"muted":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":case"inert":break;default:return!0}console.error("Received the string `%s` for the boolean attribute `%s`. %s Did you mean %s={%s}?",g,l,g==="false"?"The browser will interpret it as a truthy value.":'Although this works, it will not work as expected if you pass the string "false".',l,g),w[l]=!0}}return!0}function ze(o,l,g){var E=[],I;for(I in l)je(o,I,l[I])||E.push(I);l=E.map(function(F){return"`"+F+"`"}).join(", "),E.length===1?console.error("Invalid value for prop %s on <%s> tag. Either remove it from the element, or pass a string or number value to keep it in the DOM. For details, see https://react.dev/link/attribute-behavior ",l,o):1<E.length&&console.error("Invalid values for props %s on <%s> tag. Either remove them from the element, or pass a string or number value to keep them in the DOM. For details, see https://react.dev/link/attribute-behavior ",l,o)}function We(o){return o.replace(we,function(l,g){return g.toUpperCase()})}function Pe(o){if(typeof o=="boolean"||typeof o=="number"||typeof o=="bigint")return""+o;q(o),o=""+o;var l=Xe.exec(o);if(l){var g="",E,I=0;for(E=l.index;E<o.length;E++){switch(o.charCodeAt(E)){case 34:l="&quot;";break;case 38:l="&amp;";break;case 39:l="&#x27;";break;case 60:l="&lt;";break;case 62:l="&gt;";break;default:continue}I!==E&&(g+=o.slice(I,E)),I=E+1,g+=l}o=I!==E?g+o.slice(I,E):g}return o}function ue(o){return tn.test(""+o)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":o}function Ae(o){return q(o),(""+o).replace(Hs,c)}function He(o,l,g,E,I,F){g=typeof l=="string"?l:l&&l.script;var G=g===void 0?as:D('<script nonce="'+Pe(g)+'"'),Z=typeof l=="string"?void 0:l&&l.style,pe=Z===void 0?Un:D('<style nonce="'+Pe(Z)+'"'),te=o.idPrefix,se=[],Te=o.bootstrapScriptContent,_e=o.bootstrapScripts,Be=o.bootstrapModules;if(Te!==void 0&&(se.push(G),yr(se,o),se.push(dn,M(Ae(Te)),Fl)),Te=[],E!==void 0&&(Te.push(Us),Te.push(M(Ae(JSON.stringify(E)))),Te.push(ci)),I&&typeof F=="number"&&0>=F&&console.error("React expected a positive non-zero `maxHeadersLength` option but found %s instead. When using the `onHeaders` option you may supply an optional `maxHeadersLength` option as well however, when setting this value to zero or less no headers will be captured.",F===0?"zero":F),E=I?{preconnects:"",fontPreloads:"",highImagePreloads:"",remainingCapacity:2+(typeof F=="number"?F:2e3)}:null,I={placeholderPrefix:D(te+"P:"),segmentPrefix:D(te+"S:"),boundaryPrefix:D(te+"B:"),startInlineScript:G,startInlineStyle:pe,preamble:Ie(),externalRuntimeScript:null,bootstrapChunks:se,importMapChunks:Te,onHeaders:I,headers:E,resets:{font:{},dns:{},connect:{default:{},anonymous:{},credentials:{}},image:{},style:{}},charsetChunks:[],viewportChunks:[],hoistableChunks:[],preconnects:new Set,fontPreloads:new Set,highImagePreloads:new Set,styles:new Map,bootstrapScripts:new Set,scripts:new Set,bulkPreloads:new Set,preloads:{images:new Map,stylesheets:new Map,scripts:new Map,moduleScripts:new Map},nonce:{script:g,style:Z},hoistableState:null,stylesToHoist:!1},_e!==void 0)for(E=0;E<_e.length;E++)F=_e[E],pe=Z=void 0,te={rel:"preload",as:"script",fetchPriority:"low",nonce:l},typeof F=="string"?te.href=G=F:(te.href=G=F.src,te.integrity=pe=typeof F.integrity=="string"?F.integrity:void 0,te.crossOrigin=Z=typeof F=="string"||F.crossOrigin==null?void 0:F.crossOrigin==="use-credentials"?"use-credentials":""),mn(o,I,G,te),se.push(yo,M(Pe(G)),ut),g&&se.push(Rr,M(Pe(g)),ut),typeof pe=="string"&&se.push(Er,M(Pe(pe)),ut),typeof Z=="string"&&se.push(ul,M(Pe(Z)),ut),yr(se,o),se.push(Ml);if(Be!==void 0)for(l=0;l<Be.length;l++)_e=Be[l],G=F=void 0,Z={rel:"modulepreload",fetchPriority:"low",nonce:g},typeof _e=="string"?Z.href=E=_e:(Z.href=E=_e.src,Z.integrity=G=typeof _e.integrity=="string"?_e.integrity:void 0,Z.crossOrigin=F=typeof _e=="string"||_e.crossOrigin==null?void 0:_e.crossOrigin==="use-credentials"?"use-credentials":""),mn(o,I,E,Z),se.push(vr,M(Pe(E)),ut),g&&se.push(Rr,M(Pe(g)),ut),typeof G=="string"&&se.push(Er,M(Pe(G)),ut),typeof F=="string"&&se.push(ul,M(Pe(F)),ut),yr(se,o),se.push(Ml);return I}function kn(o,l,g,E,I){return{idPrefix:o===void 0?"":o,nextFormID:0,streamingFormat:0,bootstrapScriptContent:g,bootstrapScripts:E,bootstrapModules:I,instructions:un,hasBody:!1,hasHtml:!1,unknownResources:{},dnsResources:{},connectResources:{default:{},anonymous:{},credentials:{}},imageResources:{},styleResources:{},scriptResources:{},moduleUnknownResources:{},moduleScriptResources:{}}}function Ie(){return{htmlChunks:null,headChunks:null,bodyChunks:null}}function ie(o,l,g,E){return{insertionMode:o,selectedValue:l,tagScope:g,viewTransition:E}}function ot(o){return ie(o==="http://www.w3.org/2000/svg"?Ro:o==="http://www.w3.org/1998/Math/MathML"?gr:ka,null,0,null)}function wn(o,l,g){var E=o.tagScope&-25;switch(l){case"noscript":return ie(vo,null,E|1,null);case"select":return ie(vo,g.value!=null?g.value:g.defaultValue,E,null);case"svg":return ie(Ro,null,E,null);case"picture":return ie(vo,null,E|2,null);case"math":return ie(gr,null,E,null);case"foreignObject":return ie(vo,null,E,null);case"table":return ie(Dl,null,E,null);case"thead":case"tbody":case"tfoot":return ie(di,null,E,null);case"colgroup":return ie(Xi,null,E,null);case"tr":return ie(Ol,null,E,null);case"head":if(o.insertionMode<vo)return ie(ui,null,E,null);break;case"html":if(o.insertionMode===ka)return ie(is,null,E,null)}return o.insertionMode>=Dl||o.insertionMode<vo?ie(vo,null,E,null):o.tagScope!==E?ie(o.insertionMode,o.selectedValue,E,null):o}function go(o){return o===null?null:{update:o.update,enter:"none",exit:"none",share:o.update,name:o.autoName,autoName:o.autoName,nameIdx:0}}function vt(o,l){return l.tagScope&32&&(o.instructions|=128),ie(l.insertionMode,l.selectedValue,l.tagScope|12,go(l.viewTransition))}function Mo(o,l){o=go(l.viewTransition);var g=l.tagScope|16;return o!==null&&o.share!=="none"&&(g|=64),ie(l.insertionMode,l.selectedValue,g,o)}function Cn(o,l,g,E){return l===""?E:(E&&o.push(Pn),o.push(M(Pe(l))),!0)}function Bi(o,l){if(typeof l!="object")throw Error("The `style` prop expects a mapping from style properties to values, not a string. For example, style={{marginRight: spacing + 'em'}} when using JSX.");var g=!0,E;for(E in l)if(Mt.call(l,E)){var I=l[E];if(I!=null&&typeof I!="boolean"&&I!==""){if(E.indexOf("--")===0){var F=M(Pe(E));de(I,E),I=M(Pe((""+I).trim()))}else{F=E;var G=I;if(-1<F.indexOf("-")){var Z=F;Le.hasOwnProperty(Z)&&Le[Z]||(Le[Z]=!0,console.error("Unsupported style property %s. Did you mean %s?",Z,We(Z.replace(ce,"ms-"))))}else if(J.test(F))Z=F,Le.hasOwnProperty(Z)&&Le[Z]||(Le[Z]=!0,console.error("Unsupported vendor-prefixed style property %s. Did you mean %s?",Z,Z.charAt(0).toUpperCase()+Z.slice(1)));else if(ve.test(G)){Z=F;var pe=G;Ge.hasOwnProperty(pe)&&Ge[pe]||(Ge[pe]=!0,console.error(`Style property values shouldn't contain a semicolon. Try "%s: %s" instead.`,Z,pe.replace(ve,"")))}typeof G=="number"&&(isNaN(G)?at||(at=!0,console.error("`NaN` is an invalid value for the `%s` css style property.",F)):isFinite(G)||Qe||(Qe=!0,console.error("`Infinity` is an invalid value for the `%s` css style property.",F))),F=E,G=hi.get(F),G!==void 0||(G=D(Pe(F.replace(tt,"-$1").toLowerCase().replace(Je,"-ms-"))),hi.set(F,G)),F=G,typeof I=="number"?I=I===0||Ea.has(E)?M(""+I):M(I+"px"):(de(I,E),I=M(Pe((""+I).trim())))}g?(g=!1,o.push(cs,F,wa,I)):o.push(zs,F,wa,I)}}g||o.push(ut)}function $r(o,l,g){g&&typeof g!="function"&&typeof g!="symbol"&&o.push(Rn,M(l),jl)}function po(o,l,g){typeof g!="function"&&typeof g!="symbol"&&typeof g!="boolean"&&o.push(Rn,M(l),pr,M(Pe(g)),ut)}function Sn(o,l){this.push(us),Pi(o),po(this,"name",l),po(this,"value",o),this.push(Wo)}function Pi(o){if(typeof o!="string")throw Error("File/Blob fields are not yet supported in progressive forms. Will fallback to client hydration.")}function et(o,l){if(typeof l.$$FORM_ACTION=="function"){var g=o.nextFormID++;o=o.idPrefix+g;try{var E=l.$$FORM_ACTION(o);if(E){var I=E.data;I!=null&&I.forEach(Pi)}return E}catch(F){if(typeof F=="object"&&F!==null&&typeof F.then=="function")throw F;console.error(`Failed to serialize an action for progressive enhancement:
150
+ %s`,F)}}return null}function Tn(o,l,g,E,I,F,G,Z){var pe=null;if(typeof E=="function"){Z===null||fi||(fi=!0,console.error('Cannot specify a "name" prop for a button that specifies a function as a formAction. React needs it to encode which action should be invoked. It will get overridden.')),I===null&&F===null||Ki||(Ki=!0,console.error("Cannot specify a formEncType or formMethod for a button that specifies a function as a formAction. React provides those automatically. They will get overridden.")),G===null||Zi||(Zi=!0,console.error("Cannot specify a formTarget for a button that specifies a function as a formAction. The function will always be executed in the same window."));var te=et(l,E);te!==null?(Z=te.name,E=te.action||"",I=te.encType,F=te.method,G=te.target,pe=te.data):(o.push(Rn,M("formAction"),pr,Ca,ut),G=F=I=E=Z=null,Jn(l,g))}return Z!=null&&_t(o,"name",Z),E!=null&&_t(o,"formAction",E),I!=null&&_t(o,"formEncType",I),F!=null&&_t(o,"formMethod",F),G!=null&&_t(o,"formTarget",G),pe}function _t(o,l,g){switch(l){case"className":po(o,"class",g);break;case"tabIndex":po(o,"tabindex",g);break;case"dir":case"role":case"viewBox":case"width":case"height":po(o,l,g);break;case"style":Bi(o,g);break;case"src":case"href":if(g===""){console.error(l==="src"?'An empty string ("") was passed to the %s attribute. This may cause the browser to download the whole page again over the network. To fix this, either do not render the element at all or pass null to %s instead of an empty string.':'An empty string ("") was passed to the %s attribute. To fix this, either do not render the element at all or pass null to %s instead of an empty string.',l,l);break}case"action":case"formAction":if(g==null||typeof g=="function"||typeof g=="symbol"||typeof g=="boolean")break;ye(g,l),g=ue(""+g),o.push(Rn,M(l),pr,M(Pe(g)),ut);break;case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"autoFocus":case"multiple":case"muted":$r(o,l.toLowerCase(),g);break;case"xlinkHref":if(typeof g=="function"||typeof g=="symbol"||typeof g=="boolean")break;ye(g,l),g=ue(""+g),o.push(Rn,M("xlink:href"),pr,M(Pe(g)),ut);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":typeof g!="function"&&typeof g!="symbol"&&o.push(Rn,M(l),pr,M(Pe(g)),ut);break;case"inert":g!==""||Yi[l]||(Yi[l]=!0,console.error("Received an empty string for a boolean attribute `%s`. This will treat the attribute as if it were false. Either pass `false` to silence this warning, or pass `true` if you used an empty string in earlier versions of React to indicate this attribute is true.",l));case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":g&&typeof g!="function"&&typeof g!="symbol"&&o.push(Rn,M(l),jl);break;case"capture":case"download":g===!0?o.push(Rn,M(l),jl):g!==!1&&typeof g!="function"&&typeof g!="symbol"&&o.push(Rn,M(l),pr,M(Pe(g)),ut);break;case"cols":case"rows":case"size":case"span":typeof g!="function"&&typeof g!="symbol"&&!isNaN(g)&&1<=g&&o.push(Rn,M(l),pr,M(Pe(g)),ut);break;case"rowSpan":case"start":typeof g=="function"||typeof g=="symbol"||isNaN(g)||o.push(Rn,M(l),pr,M(Pe(g)),ut);break;case"xlinkActuate":po(o,"xlink:actuate",g);break;case"xlinkArcrole":po(o,"xlink:arcrole",g);break;case"xlinkRole":po(o,"xlink:role",g);break;case"xlinkShow":po(o,"xlink:show",g);break;case"xlinkTitle":po(o,"xlink:title",g);break;case"xlinkType":po(o,"xlink:type",g);break;case"xmlBase":po(o,"xml:base",g);break;case"xmlLang":po(o,"xml:lang",g);break;case"xmlSpace":po(o,"xml:space",g);break;default:if((!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=_c.get(l)||l,he(l))){switch(typeof g){case"function":case"symbol":return;case"boolean":var E=l.toLowerCase().slice(0,5);if(E!=="data-"&&E!=="aria-")return}o.push(Rn,M(l),pr,M(Pe(g)),ut)}}}function Wn(o,l,g){if(l!=null){if(g!=null)throw Error("Can only set one of `children` or `props.dangerouslySetInnerHTML`.");if(typeof l!="object"||!("__html"in l))throw Error("`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://react.dev/link/dangerously-set-inner-html for more information.");l=l.__html,l!=null&&(q(l),o.push(M(""+l)))}}function Es(o,l){var g=o[l];g!=null&&(g=cl(g),o.multiple&&!g?console.error("The `%s` prop supplied to <select> must be an array if `multiple` is true.",l):!o.multiple&&g&&console.error("The `%s` prop supplied to <select> must be a scalar value if `multiple` is false.",l))}function Xl(o){var l="";return Ui.Children.forEach(o,function(g){g!=null&&(l+=g,Sa||typeof g=="string"||typeof g=="number"||typeof g=="bigint"||(Sa=!0,console.error("Cannot infer the option value of complex children. Pass a `value` prop or use a plain string as children to <option>.")))}),l}function Jn(o,l){if((o.instructions&16)===un){o.instructions|=16;var g=l.preamble,E=l.bootstrapChunks;(g.htmlChunks||g.headChunks)&&E.length===0?(E.push(l.startInlineScript),yr(E,o),E.push(dn,Vs,Fl)):E.unshift(l.startInlineScript,dn,Vs,Fl)}}function Do(o,l){o.push(Vt("link"));for(var g in l)if(Mt.call(l,g)){var E=l[g];if(E!=null)switch(g){case"children":case"dangerouslySetInnerHTML":throw Error("link is a self-closing tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:_t(o,g,E)}}return o.push(Wo),null}function Mr(o){return q(o),(""+o).replace(gi,n)}function On(o,l,g){o.push(Vt(g));for(var E in l)if(Mt.call(l,E)){var I=l[E];if(I!=null)switch(E){case"children":case"dangerouslySetInnerHTML":throw Error(g+" is a self-closing tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:_t(o,E,I)}}return o.push(Wo),null}function Dr(o,l){o.push(Vt("title"));var g=null,E=null,I;for(I in l)if(Mt.call(l,I)){var F=l[I];if(F!=null)switch(I){case"children":g=F;break;case"dangerouslySetInnerHTML":E=F;break;default:_t(o,I,F)}}return o.push(dn),l=Array.isArray(g)?2>g.length?g[0]:null:g,typeof l!="function"&&typeof l!="symbol"&&l!==null&&l!==void 0&&o.push(M(Pe(""+l))),Wn(o,E,g),o.push(vn("title")),null}function _i(o,l){o.push(Vt("script"));var g=null,E=null,I;for(I in l)if(Mt.call(l,I)){var F=l[I];if(F!=null)switch(I){case"children":g=F;break;case"dangerouslySetInnerHTML":E=F;break;default:_t(o,I,F)}}return o.push(dn),g!=null&&typeof g!="string"&&(l=typeof g=="number"?"a number for children":Array.isArray(g)?"an array for children":"something unexpected for children",console.error("A script element was rendered with %s. If script element has children it must be a single string. Consider using dangerouslySetInnerHTML or passing a plain string as children.",l)),Wn(o,E,g),typeof g=="string"&&o.push(M(Ae(g))),o.push(vn("script")),null}function Rt(o,l,g){o.push(Vt(g));var E=g=null,I;for(I in l)if(Mt.call(l,I)){var F=l[I];if(F!=null)switch(I){case"children":g=F;break;case"dangerouslySetInnerHTML":E=F;break;default:_t(o,I,F)}}return o.push(dn),Wn(o,E,g),g}function xo(o,l,g){o.push(Vt(g));var E=g=null,I;for(I in l)if(Mt.call(l,I)){var F=l[I];if(F!=null)switch(I){case"children":g=F;break;case"dangerouslySetInnerHTML":E=F;break;default:_t(o,I,F)}}return o.push(dn),Wn(o,E,g),typeof g=="string"?(o.push(M(Pe(g))),null):g}function Vt(o){var l=Dc.get(o);if(l===void 0){if(!Mc.test(o))throw Error("Invalid tag: "+o);l=D("<"+o),Dc.set(o,l)}return l}function Jc(o,l,g,E,I,F,G,Z,pe){Ee(l,g),l!=="input"&&l!=="textarea"&&l!=="select"||g==null||g.value!==null||f||(f=!0,l==="select"&&g.multiple?console.error("`value` prop on `%s` should not be null. Consider using an empty array when `multiple` is set to `true` to clear the component or `undefined` for uncontrolled components.",l):console.error("`value` prop on `%s` should not be null. Consider using an empty string to clear the component or `undefined` for uncontrolled components.",l));e:if(l.indexOf("-")===-1)var te=!1;else switch(l){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":te=!1;break e;default:te=!0}switch(te||typeof g.is=="string"||ze(l,g),!g.suppressContentEditableWarning&&g.contentEditable&&g.children!=null&&console.error("A component is `contentEditable` and contains `children` managed by React. It is now your responsibility to guarantee that none of those nodes are unexpectedly modified or duplicated. This is probably not intentional."),Z.insertionMode!==Ro&&Z.insertionMode!==gr&&l.indexOf("-")===-1&&l.toLowerCase()!==l&&console.error("<%s /> is using incorrect casing. Use PascalCase for React components, or lowercase for HTML elements.",l),l){case"div":case"span":case"svg":case"path":break;case"a":o.push(Vt("a"));var se=null,Te=null,_e;for(_e in g)if(Mt.call(g,_e)){var Be=g[_e];if(Be!=null)switch(_e){case"children":se=Be;break;case"dangerouslySetInnerHTML":Te=Be;break;case"href":Be===""?po(o,"href",""):_t(o,_e,Be);break;default:_t(o,_e,Be)}}if(o.push(dn),Wn(o,Te,se),typeof se=="string"){o.push(M(Pe(se)));var Ce=null}else Ce=se;return Ce;case"g":case"p":case"li":break;case"select":le("select",g),Es(g,"value"),Es(g,"defaultValue"),g.value===void 0||g.defaultValue===void 0||kr||(console.error("Select elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled select element and remove one of these props. More info: https://react.dev/link/controlled-components"),kr=!0),o.push(Vt("select"));var Ze=null,Wt=null,Ye;for(Ye in g)if(Mt.call(g,Ye)){var ft=g[Ye];if(ft!=null)switch(Ye){case"children":Ze=ft;break;case"dangerouslySetInnerHTML":Wt=ft;break;case"defaultValue":case"value":break;default:_t(o,Ye,ft)}}return o.push(dn),Wn(o,Wt,Ze),Ze;case"option":var bn=Z.selectedValue;o.push(Vt("option"));var Ln=null,It=null,Ve=null,Fn=null,Bo;for(Bo in g)if(Mt.call(g,Bo)){var Gt=g[Bo];if(Gt!=null)switch(Bo){case"children":Ln=Gt;break;case"selected":Ve=Gt,Nc||(console.error("Use the `defaultValue` or `value` props on <select> instead of setting `selected` on <option>."),Nc=!0);break;case"dangerouslySetInnerHTML":Fn=Gt;break;case"value":It=Gt;default:_t(o,Bo,Gt)}}if(bn!=null){if(It!==null){ye(It,"value");var rn=""+It}else Fn===null||Eo||(Eo=!0,console.error("Pass a `value` prop if you set dangerouslyInnerHTML so React knows which value should be selected.")),rn=Xl(Ln);if(cl(bn)){for(var tr=0;tr<bn.length;tr++)if(ye(bn[tr],"value"),""+bn[tr]===rn){o.push(dl);break}}else ye(bn,"select.value"),""+bn===rn&&o.push(dl)}else Ve&&o.push(dl);return o.push(dn),Wn(o,Fn,Ln),Ln;case"textarea":le("textarea",g),g.value===void 0||g.defaultValue===void 0||so||(console.error("Textarea elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled textarea and remove one of these props. More info: https://react.dev/link/controlled-components"),so=!0),o.push(Vt("textarea"));var ho=null,Zn=null,ln=null,zn;for(zn in g)if(Mt.call(g,zn)){var nr=g[zn];if(nr!=null)switch(zn){case"children":ln=nr;break;case"value":ho=nr;break;case"defaultValue":Zn=nr;break;case"dangerouslySetInnerHTML":throw Error("`dangerouslySetInnerHTML` does not make sense on <textarea>.");default:_t(o,zn,nr)}}if(ho===null&&Zn!==null&&(ho=Zn),o.push(dn),ln!=null){if(console.error("Use the `defaultValue` or `value` props instead of setting children on <textarea>."),ho!=null)throw Error("If you supply `defaultValue` on a <textarea>, do not pass children.");if(cl(ln)){if(1<ln.length)throw Error("<textarea> can only have at most one child.");q(ln[0]),ho=""+ln[0]}q(ln),ho=""+ln}return typeof ho=="string"&&ho[0]===`
151
+ `&&o.push(Ji),ho!==null&&(ye(ho,"value"),o.push(M(Pe(""+ho)))),null;case"input":le("input",g),o.push(Vt("input"));var br=null,Kn=null,pn=null,Po=null,or=null,_o=null,Gl=null,rr=null,Mn=null,Br;for(Br in g)if(Mt.call(g,Br)){var to=g[Br];if(to!=null)switch(Br){case"children":case"dangerouslySetInnerHTML":throw Error("input is a self-closing tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");case"name":br=to;break;case"formAction":Kn=to;break;case"formEncType":pn=to;break;case"formMethod":Po=to;break;case"formTarget":or=to;break;case"defaultChecked":Mn=to;break;case"defaultValue":Gl=to;break;case"checked":rr=to;break;case"value":_o=to;break;default:_t(o,Br,to)}}Kn===null||g.type==="image"||g.type==="submit"||Gs||(Gs=!0,console.error('An input can only specify a formAction along with type="submit" or type="image".'));var Wc=Tn(o,E,I,Kn,pn,Po,or,br);return rr===null||Mn===null||Ws||(console.error("%s contains an input of type %s with both checked and defaultChecked props. Input elements must be either controlled or uncontrolled (specify either the checked prop, or the defaultChecked prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://react.dev/link/controlled-components","A component",g.type),Ws=!0),_o===null||Gl===null||ds||(console.error("%s contains an input of type %s with both value and defaultValue props. Input elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://react.dev/link/controlled-components","A component",g.type),ds=!0),rr!==null?$r(o,"checked",rr):Mn!==null&&$r(o,"checked",Mn),_o!==null?_t(o,"value",_o):Gl!==null&&_t(o,"value",Gl),o.push(Wo),Wc!=null&&Wc.forEach(Sn,o),null;case"button":o.push(Vt("button"));var bl=null,yn=null,Pr=null,Lo=null,ki=null,Oa=null,Qr=null,ja;for(ja in g)if(Mt.call(g,ja)){var lr=g[ja];if(lr!=null)switch(ja){case"children":bl=lr;break;case"dangerouslySetInnerHTML":yn=lr;break;case"name":Pr=lr;break;case"formAction":Lo=lr;break;case"formEncType":ki=lr;break;case"formMethod":Oa=lr;break;case"formTarget":Qr=lr;break;default:_t(o,ja,lr)}}Lo===null||g.type==null||g.type==="submit"||Gs||(Gs=!0,console.error('A button can only specify a formAction along with type="submit" or no type.'));var wi=Tn(o,E,I,Lo,ki,Oa,Qr,Pr);if(o.push(dn),wi!=null&&wi.forEach(Sn,o),Wn(o,yn,bl),typeof bl=="string"){o.push(M(Pe(bl)));var Gc=null}else Gc=bl;return Gc;case"form":o.push(Vt("form"));var _r=null,Ci=null,Fo=null,Ha=null,ra=null,ys=null,Nr;for(Nr in g)if(Mt.call(g,Nr)){var Lr=g[Nr];if(Lr!=null)switch(Nr){case"children":_r=Lr;break;case"dangerouslySetInnerHTML":Ci=Lr;break;case"action":Fo=Lr;break;case"encType":Ha=Lr;break;case"method":ra=Lr;break;case"target":ys=Lr;break;default:_t(o,Nr,Lr)}}var yl=null,sr=null;if(typeof Fo=="function"){Ha===null&&ra===null||Ki||(Ki=!0,console.error("Cannot specify a encType or method for a form that specifies a function as the action. React provides those automatically. They will get overridden.")),ys===null||Zi||(Zi=!0,console.error("Cannot specify a target for a form that specifies a function as the action. The function will always be executed in the same window."));var fo=et(E,Fo);fo!==null?(Fo=fo.action||"",Ha=fo.encType,ra=fo.method,ys=fo.target,yl=fo.data,sr=fo.name):(o.push(Rn,M("action"),pr,Ca,ut),ys=ra=Ha=Fo=null,Jn(E,I))}if(Fo!=null&&_t(o,"action",Fo),Ha!=null&&_t(o,"encType",Ha),ra!=null&&_t(o,"method",ra),ys!=null&&_t(o,"target",ys),o.push(dn),sr!==null&&(o.push(us),po(o,"name",sr),o.push(Wo),yl!=null&&yl.forEach(Sn,o)),Wn(o,Ci,_r),typeof _r=="string"){o.push(M(Pe(_r)));var vs=null}else vs=_r;return vs;case"menuitem":o.push(Vt("menuitem"));for(var vl in g)if(Mt.call(g,vl)){var la=g[vl];if(la!=null)switch(vl){case"children":case"dangerouslySetInnerHTML":throw Error("menuitems cannot have `children` nor `dangerouslySetInnerHTML`.");default:_t(o,vl,la)}}return o.push(dn),null;case"object":o.push(Vt("object"));var Vl=null,mu=null,Xo;for(Xo in g)if(Mt.call(g,Xo)){var qr=g[Xo];if(qr!=null)switch(Xo){case"children":Vl=qr;break;case"dangerouslySetInnerHTML":mu=qr;break;case"data":ye(qr,"data");var Si=ue(""+qr);if(Si===""){console.error('An empty string ("") was passed to the %s attribute. To fix this, either do not render the element at all or pass null to %s instead of an empty string.',Xo,Xo);break}o.push(Rn,M("data"),pr,M(Pe(Si)),ut);break;default:_t(o,Xo,qr)}}if(o.push(dn),Wn(o,mu,Vl),typeof Vl=="string"){o.push(M(Pe(Vl)));var dc=null}else dc=Vl;return dc;case"title":var hc=Z.tagScope&1,ju=Z.tagScope&4;if(Mt.call(g,"children")){var sa=g.children,Ua=Array.isArray(sa)?2>sa.length?sa[0]:null:sa;Array.isArray(sa)&&1<sa.length?console.error("React expects the `children` prop of <title> tags to be a string, number, bigint, or object with a novel `toString` method but found an Array with length %s instead. Browsers treat all child Nodes of <title> tags as Text content and React expects to be able to convert `children` of <title> tags to a single string value which is why Arrays of length greater than 1 are not supported. When using JSX it can be common to combine text nodes and value nodes. For example: <title>hello {nameOfUser}</title>. While not immediately apparent, `children` in this case is an Array with length 2. If your `children` prop is using this form try rewriting it using a template string: <title>{`hello ${nameOfUser}`}</title>.",sa.length):typeof Ua=="function"||typeof Ua=="symbol"?console.error("React expect children of <title> tags to be a string, number, bigint, or object with a novel `toString` method but found %s instead. Browsers treat all child Nodes of <title> tags as Text content and React expects to be able to convert children of <title> tags to a single string value.",typeof Ua=="function"?"a Function":"a Sybmol"):Ua&&Ua.toString==={}.toString&&(Ua.$$typeof!=null?console.error("React expects the `children` prop of <title> tags to be a string, number, bigint, or object with a novel `toString` method but found an object that appears to be a React element which never implements a suitable `toString` method. Browsers treat all child Nodes of <title> tags as Text content and React expects to be able to convert children of <title> tags to a single string value which is why rendering React elements is not supported. If the `children` of <title> is a React Component try moving the <title> tag into that component. If the `children` of <title> is some HTML markup change it to be Text only to be valid HTML."):console.error("React expects the `children` prop of <title> tags to be a string, number, bigint, or object with a novel `toString` method but found an object that does not implement a suitable `toString` method. Browsers treat all child Nodes of <title> tags as Text content and React expects to be able to convert children of <title> tags to a single string value. Using the default `toString` method available on every object is almost certainly an error. Consider whether the `children` of this <title> is an object in error and change it to a string or number value if so. Otherwise implement a `toString` method that React can use to produce a valid <title>."))}if(Z.insertionMode===Ro||hc||g.itemProp!=null)var aa=Dr(o,g);else ju?aa=null:(Dr(I.hoistableChunks,g),aa=void 0);return aa;case"link":var fc=Z.tagScope&1,Nu=Z.tagScope&4,Cu=g.rel,Zo=g.href,Rl=g.precedence;if(Z.insertionMode===Ro||fc||g.itemProp!=null||typeof Cu!="string"||typeof Zo!="string"||Zo===""){Cu==="stylesheet"&&typeof g.precedence=="string"&&(typeof Zo=="string"&&Zo||console.error('React encountered a `<link rel="stylesheet" .../>` with a `precedence` prop and expected the `href` prop to be a non-empty string but ecountered %s instead. If your intent was to have React hoist and deduplciate this stylesheet using the `precedence` prop ensure there is a non-empty string `href` prop as well, otherwise remove the `precedence` prop.',Zo===null?"`null`":Zo===void 0?"`undefined`":Zo===""?"an empty string":'something with type "'+typeof Zo+'"')),Do(o,g);var ia=null}else if(g.rel==="stylesheet")if(typeof Rl!="string"||g.disabled!=null||g.onLoad||g.onError){if(typeof Rl=="string"){if(g.disabled!=null)console.error('React encountered a `<link rel="stylesheet" .../>` with a `precedence` prop and a `disabled` prop. The presence of the `disabled` prop indicates an intent to manage the stylesheet active state from your from your Component code and React will not hoist or deduplicate this stylesheet. If your intent was to have React hoist and deduplciate this stylesheet using the `precedence` prop remove the `disabled` prop, otherwise remove the `precedence` prop.');else if(g.onLoad||g.onError){var Vc=g.onLoad&&g.onError?"`onLoad` and `onError` props":g.onLoad?"`onLoad` prop":"`onError` prop";console.error('React encountered a `<link rel="stylesheet" .../>` with a `precedence` prop and %s. The presence of loading and error handlers indicates an intent to manage the stylesheet loading state from your from your Component code and React will not hoist or deduplicate this stylesheet. If your intent was to have React hoist and deduplciate this stylesheet using the `precedence` prop remove the %s, otherwise remove the `precedence` prop.',Vc,Vc)}}ia=Do(o,g)}else{var Fr=I.styles.get(Rl),Dn=E.styleResources.hasOwnProperty(Zo)?E.styleResources[Zo]:void 0;if(Dn!==Tt){E.styleResources[Zo]=Tt,Fr||(Fr={precedence:M(Pe(Rl)),rules:[],hrefs:[],sheets:new Map},I.styles.set(Rl,Fr));var xn={state:xs,props:Zt({},g,{"data-precedence":g.precedence,precedence:null})};if(Dn){Dn.length===2&&Kl(xn.props,Dn);var Jt=I.preloads.stylesheets.get(Zo);Jt&&0<Jt.length?Jt.length=0:xn.state=rc}Fr.sheets.set(Zo,xn),G&&G.stylesheets.add(xn)}else if(Fr){var Su=Fr.sheets.get(Zo);Su&&G&&G.stylesheets.add(Su)}pe&&o.push(Pn),ia=null}else g.onLoad||g.onError?ia=Do(o,g):(pe&&o.push(Pn),ia=Nu?null:Do(I.hoistableChunks,g));return ia;case"script":var za=Z.tagScope&1,Yc=g.async;if(typeof g.src!="string"||!g.src||!Yc||typeof Yc=="function"||typeof Yc=="symbol"||g.onLoad||g.onError||Z.insertionMode===Ro||za||g.itemProp!=null)var Wa=_i(o,g);else{var Ti=g.src;if(g.type==="module")var Xc=E.moduleScriptResources,Ai=I.preloads.moduleScripts;else Xc=E.scriptResources,Ai=I.preloads.scripts;var gc=Xc.hasOwnProperty(Ti)?Xc[Ti]:void 0;if(gc!==Tt){Xc[Ti]=Tt;var pc=g;if(gc){gc.length===2&&(pc=Zt({},g),Kl(pc,gc));var bu=Ai.get(Ti);bu&&(bu.length=0)}var Tu=[];I.scripts.add(Tu),_i(Tu,pc)}pe&&o.push(Pn),Wa=null}return Wa;case"style":var Lu=Z.tagScope&1;if(Mt.call(g,"children")){var Zc=g.children,Kc=Array.isArray(Zc)?2>Zc.length?Zc[0]:null:Zc;(typeof Kc=="function"||typeof Kc=="symbol"||Array.isArray(Kc))&&console.error("React expect children of <style> tags to be a string, number, or object with a `toString` method but found %s instead. In browsers style Elements can only have `Text` Nodes as children.",typeof Kc=="function"?"a Function":typeof Kc=="symbol"?"a Sybmol":"an Array")}var Ii=g.precedence,ca=g.href,Rs=g.nonce;if(Z.insertionMode===Ro||Lu||g.itemProp!=null||typeof Ii!="string"||typeof ca!="string"||ca===""){o.push(Vt("style"));var ar=null,xc=null,Fu;for(Fu in g)if(Mt.call(g,Fu)){var Hu=g[Fu];if(Hu!=null)switch(Fu){case"children":ar=Hu;break;case"dangerouslySetInnerHTML":xc=Hu;break;default:_t(o,Fu,Hu)}}o.push(dn);var Au=Array.isArray(ar)?2>ar.length?ar[0]:null:ar;typeof Au!="function"&&typeof Au!="symbol"&&Au!==null&&Au!==void 0&&o.push(M(Mr(Au))),Wn(o,xc,ar),o.push(vn("style"));var Ju=null}else{ca.includes(" ")&&console.error('React expected the `href` prop for a <style> tag opting into hoisting semantics using the `precedence` prop to not have any spaces but ecountered spaces instead. using spaces in this prop will cause hydration of this style to fail on the client. The href for the <style> where this ocurred is "%s".',ca);var yu=I.styles.get(Ii),Qu=E.styleResources.hasOwnProperty(ca)?E.styleResources[ca]:void 0;if(Qu!==Tt){E.styleResources[ca]=Tt,Qu&&console.error('React encountered a hoistable style tag for the same href as a preload: "%s". When using a style tag to inline styles you should not also preload it as a stylsheet.',ca),yu||(yu={precedence:M(Pe(Ii)),rules:[],hrefs:[],sheets:new Map},I.styles.set(Ii,yu));var Mu=I.nonce.style;if(Mu&&Mu!==Rs)console.error('React encountered a style tag with `precedence` "%s" and `nonce` "%s". When React manages style rules using `precedence` it will only include rules if the nonce matches the style nonce "%s" that was included with this render.',Ii,Rs,Mu);else{!Mu&&Rs&&console.error('React encountered a style tag with `precedence` "%s" and `nonce` "%s". When React manages style rules using `precedence` it will only include a nonce attributes if you also provide the same style nonce value as a render option.',Ii,Rs),yu.hrefs.push(M(Pe(ca)));var Uu=yu.rules,zu=null,id=null,qu;for(qu in g)if(Mt.call(g,qu)){var ed=g[qu];if(ed!=null)switch(qu){case"children":zu=ed;break;case"dangerouslySetInnerHTML":id=ed}}var Yu=Array.isArray(zu)?2>zu.length?zu[0]:null:zu;typeof Yu!="function"&&typeof Yu!="symbol"&&Yu!==null&&Yu!==void 0&&Uu.push(M(Mr(Yu))),Wn(Uu,id,zu)}}yu&&G&&G.styles.add(yu),pe&&o.push(Pn),Ju=void 0}return Ju;case"meta":var md=Z.tagScope&1,bd=Z.tagScope&4;if(Z.insertionMode===Ro||md||g.itemProp!=null)var cd=On(o,g,"meta");else pe&&o.push(Pn),cd=bd?null:typeof g.charSet=="string"?On(I.charsetChunks,g,"meta"):g.name==="viewport"?On(I.viewportChunks,g,"meta"):On(I.hoistableChunks,g,"meta");return cd;case"listing":case"pre":o.push(Vt(l));var Xu=null,Zu=null,Ku;for(Ku in g)if(Mt.call(g,Ku)){var $u=g[Ku];if($u!=null)switch(Ku){case"children":Xu=$u;break;case"dangerouslySetInnerHTML":Zu=$u;break;default:_t(o,Ku,$u)}}if(o.push(dn),Zu!=null){if(Xu!=null)throw Error("Can only set one of `children` or `props.dangerouslySetInnerHTML`.");if(typeof Zu!="object"||!("__html"in Zu))throw Error("`props.dangerouslySetInnerHTML` must be in the form `{__html: ...}`. Please visit https://react.dev/link/dangerously-set-inner-html for more information.");var Iu=Zu.__html;Iu!=null&&(typeof Iu=="string"&&0<Iu.length&&Iu[0]===`
152
+ `?o.push(Ji,M(Iu)):(q(Iu),o.push(M(""+Iu))))}return typeof Xu=="string"&&Xu[0]===`
153
+ `&&o.push(Ji),Xu;case"img":var yd=Z.tagScope&3,Yl=g.src,El=g.srcSet;if(!(g.loading==="lazy"||!Yl&&!El||typeof Yl!="string"&&Yl!=null||typeof El!="string"&&El!=null||g.fetchPriority==="low"||yd)&&(typeof Yl!="string"||Yl[4]!==":"||Yl[0]!=="d"&&Yl[0]!=="D"||Yl[1]!=="a"&&Yl[1]!=="A"||Yl[2]!=="t"&&Yl[2]!=="T"||Yl[3]!=="a"&&Yl[3]!=="A")&&(typeof El!="string"||El[4]!==":"||El[0]!=="d"&&El[0]!=="D"||El[1]!=="a"&&El[1]!=="A"||El[2]!=="t"&&El[2]!=="T"||El[3]!=="a"&&El[3]!=="A")){G!==null&&Z.tagScope&64&&(G.suspenseyImages=!0);var ud=typeof g.sizes=="string"?g.sizes:void 0,Wu=El?El+`
154
+ `+(ud||""):Yl,td=I.preloads.images,Du=td.get(Wu);if(Du)(g.fetchPriority==="high"||10>I.highImagePreloads.size)&&(td.delete(Wu),I.highImagePreloads.add(Du));else if(!E.imageResources.hasOwnProperty(Wu)){E.imageResources[Wu]=Yn;var nd=g.crossOrigin,dd=typeof nd=="string"?nd==="use-credentials"?nd:"":void 0,Ou=I.headers,od;Ou&&0<Ou.remainingCapacity&&typeof g.srcSet!="string"&&(g.fetchPriority==="high"||500>Ou.highImagePreloads.length)&&(od=Jl(Yl,"image",{imageSrcSet:g.srcSet,imageSizes:g.sizes,crossOrigin:dd,integrity:g.integrity,nonce:g.nonce,type:g.type,fetchPriority:g.fetchPriority,referrerPolicy:g.refererPolicy}),0<=(Ou.remainingCapacity-=od.length+2))?(I.resets.image[Wu]=Yn,Ou.highImagePreloads&&(Ou.highImagePreloads+=", "),Ou.highImagePreloads+=od):(Du=[],Do(Du,{rel:"preload",as:"image",href:El?void 0:Yl,imageSrcSet:El,imageSizes:ud,crossOrigin:dd,integrity:g.integrity,type:g.type,fetchPriority:g.fetchPriority,referrerPolicy:g.referrerPolicy}),g.fetchPriority==="high"||10>I.highImagePreloads.size?I.highImagePreloads.add(Du):(I.bulkPreloads.add(Du),td.set(Wu,Du)))}}return On(o,g,"img");case"base":case"area":case"br":case"col":case"embed":case"hr":case"keygen":case"param":case"source":case"track":case"wbr":return On(o,g,l);case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":break;case"head":if(Z.insertionMode<vo){var rd=F||I.preamble;if(rd.headChunks)throw Error("The `<head>` tag may only be rendered once.");F!==null&&o.push(pi),rd.headChunks=[];var hd=Rt(rd.headChunks,g,"head")}else hd=xo(o,g,"head");return hd;case"body":if(Z.insertionMode<vo){var ld=F||I.preamble;if(ld.bodyChunks)throw Error("The `<body>` tag may only be rendered once.");F!==null&&o.push(Lc),ld.bodyChunks=[];var fd=Rt(ld.bodyChunks,g,"body")}else fd=xo(o,g,"body");return fd;case"html":if(Z.insertionMode===ka){var sd=F||I.preamble;if(sd.htmlChunks)throw Error("The `<html>` tag may only be rendered once.");F!==null&&o.push(Fc),sd.htmlChunks=[_n];var gd=Rt(sd.htmlChunks,g,"html")}else gd=xo(o,g,"html");return gd;default:if(l.indexOf("-")!==-1){o.push(Vt(l));var ad=null,pd=null,Gu;for(Gu in g)if(Mt.call(g,Gu)){var mc=g[Gu];if(mc!=null){var xd=Gu;switch(Gu){case"children":ad=mc;break;case"dangerouslySetInnerHTML":pd=mc;break;case"style":Bi(o,mc);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"ref":break;case"className":xd="class";default:if(he(Gu)&&typeof mc!="function"&&typeof mc!="symbol"&&mc!==!1){if(mc===!0)mc="";else if(typeof mc=="object")continue;o.push(Rn,M(xd),pr,M(Pe(mc)),ut)}}}}return o.push(dn),Wn(o,pd,ad),ad}}return xo(o,g,l)}function vn(o){var l=Qi.get(o);return l===void 0&&(l=D("</"+o+">"),Qi.set(o,l)),l}function bc(o,l){o=o.preamble,o.htmlChunks===null&&l.htmlChunks&&(o.htmlChunks=l.htmlChunks),o.headChunks===null&&l.headChunks&&(o.headChunks=l.headChunks),o.bodyChunks===null&&l.bodyChunks&&(o.bodyChunks=l.bodyChunks)}function yc(o,l){l=l.bootstrapChunks;for(var g=0;g<l.length-1;g++)T(o,l[g]);return g<l.length?(g=l[g],l.length=0,O(o,g)):!0}function kl(o,l,g){if(T(o,hs),g===null)throw Error("An ID must have been assigned before we can complete the boundary.");return T(o,l.boundaryPrefix),T(o,M(g.toString(16))),O(o,wr)}function vc(o,l,g,E){switch(g.insertionMode){case ka:case is:case ui:case vo:return T(o,cu),T(o,l.segmentPrefix),T(o,M(E.toString(16))),O(o,Xr);case Ro:return T(o,xr),T(o,l.segmentPrefix),T(o,M(E.toString(16))),O(o,ps);case gr:return T(o,Cr),T(o,l.segmentPrefix),T(o,M(E.toString(16))),O(o,jc);case Dl:return T(o,Ia),T(o,l.segmentPrefix),T(o,M(E.toString(16))),O(o,i);case di:return T(o,m),T(o,l.segmentPrefix),T(o,M(E.toString(16))),O(o,C);case Ol:return T(o,H),T(o,l.segmentPrefix),T(o,M(E.toString(16))),O(o,W);case Xi:return T(o,X),T(o,l.segmentPrefix),T(o,M(E.toString(16))),O(o,oe);default:throw Error("Unknown insertion mode. This is a bug in React.")}}function Ga(o,l){switch(l.insertionMode){case ka:case is:case ui:case vo:return O(o,Aa);case Ro:return O(o,Zs);case gr:return O(o,uu);case Dl:return O(o,h);case di:return O(o,P);case Ol:return O(o,ne);case Xi:return O(o,fe);default:throw Error("Unknown insertion mode. This is a bug in React.")}}function ks(o){return JSON.stringify(o).replace(Tr,function(l){switch(l){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}function Zl(o){return JSON.stringify(o).replace(Co,function(l){switch(l){case"&":return"\\u0026";case">":return"\\u003e";case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSObjectForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}})}function ws(o){var l=o.rules,g=o.hrefs;0<l.length&&g.length===0&&console.error("React expected to have at least one href for an a hoistable style but found none. This is a bug in React.");var E=0;if(g.length){for(T(this,dt.startInlineStyle),T(this,Zr),T(this,o.precedence),T(this,So);E<g.length-1;E++)T(this,g[E]),T(this,nn);for(T(this,g[E]),T(this,Js),E=0;E<l.length;E++)T(this,l[E]);Pa=O(this,Ba),Vo=!0,l.length=0,g.length=0}}function Va(o){return o.state!==hl?Vo=!0:!1}function sn(o,l,g){return Vo=!1,Pa=!0,dt=g,l.styles.forEach(ws,o),dt=null,l.stylesheets.forEach(Va),Vo&&(g.stylesToHoist=!0),Pa}function Qt(o){for(var l=0;l<o.length;l++)T(this,o[l]);o.length=0}function Ni(o){Do(To,o.props);for(var l=0;l<To.length;l++)T(this,To[l]);To.length=0,o.state=hl}function Cs(o){var l=0<o.sheets.size;o.sheets.forEach(Ni,this),o.sheets.clear();var g=o.rules,E=o.hrefs;if(!l||E.length){if(T(this,dt.startInlineStyle),T(this,Qs),T(this,o.precedence),o=0,E.length){for(T(this,Hc);o<E.length-1;o++)T(this,E[o]),T(this,nn);T(this,E[o])}for(T(this,_a),o=0;o<g.length;o++)T(this,g[o]);T(this,Kr),g.length=0,E.length=0}}function Qc(o){if(o.state===xs){o.state=rc;var l=o.props;for(Do(To,{rel:"preload",as:"style",href:o.props.href,crossOrigin:l.crossOrigin,fetchPriority:l.fetchPriority,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy}),o=0;o<To.length;o++)T(this,To[o]);To.length=0}}function Rc(o){o.sheets.forEach(Qc,this),o.sheets.clear()}function yr(o,l){(l.instructions&St)===un&&(l.instructions|=St,o.push(tc,M(Pe("_"+l.idPrefix+"R_")),ut))}function el(o,l){T(o,qs);var g=qs;l.stylesheets.forEach(function(E){if(E.state!==hl)if(E.state===$s)T(o,g),E=E.props.href,ye(E,"href"),T(o,M(Zl(""+E))),T(o,Na),g=nc;else{T(o,g);var I=E.props["data-precedence"],F=E.props,G=ue(""+E.props.href);T(o,M(Zl(G))),ye(I,"precedence"),I=""+I,T(o,oc),T(o,M(Zl(I)));for(var Z in F)if(Mt.call(F,Z)&&(I=F[Z],I!=null))switch(Z){case"href":case"rel":case"precedence":case"data-precedence":break;case"children":case"dangerouslySetInnerHTML":throw Error("link is a self-closing tag and must neither have `children` nor use `dangerouslySetInnerHTML`.");default:qc(o,Z,I)}T(o,Na),g=nc,E.state=$s}}),T(o,Na)}function qc(o,l,g){var E=l.toLowerCase();switch(typeof g){case"function":case"symbol":return}switch(l){case"innerHTML":case"dangerouslySetInnerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":case"style":case"ref":return;case"className":E="class",ye(g,E),l=""+g;break;case"hidden":if(g===!1)return;l="";break;case"src":case"href":g=ue(g),ye(g,E),l=""+g;break;default:if(2<l.length&&(l[0]==="o"||l[0]==="O")&&(l[1]==="n"||l[1]==="N")||!he(l))return;ye(g,E),l=""+g}T(o,oc),T(o,M(Zl(E))),T(o,oc),T(o,M(Zl(l)))}function Ss(){return{styles:new Set,stylesheets:new Set,suspenseyImages:!1}}function mn(o,l,g,E){(o.scriptResources.hasOwnProperty(g)||o.moduleScriptResources.hasOwnProperty(g))&&console.error('Internal React Error: React expected bootstrap script or module with src "%s" to not have been preloaded already. please file an issue',g),o.scriptResources[g]=Tt,o.moduleScriptResources[g]=Tt,o=[],Do(o,E),l.bootstrapScripts.add(o)}function Kl(o,l){o.crossOrigin==null&&(o.crossOrigin=l[0]),o.integrity==null&&(o.integrity=l[1])}function Jl(o,l,g){o=Ts(o),l=Ko(l,"as"),l="<"+o+'>; rel=preload; as="'+l+'"';for(var E in g)Mt.call(g,E)&&(o=g[E],typeof o=="string"&&(l+="; "+E.toLowerCase()+'="'+Ko(o,E)+'"'));return l}function Ts(o){return ye(o,"href"),(""+o).replace(ea,no)}function no(o){switch(o){case"<":return"%3C";case">":return"%3E";case`
155
+ `:return"%0A";case"\r":return"%0D";default:throw Error("escapeLinkHrefForHeaderContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}function Ko(o,l){return ae(o)&&(console.error("The provided `%s` option is an unsupported type %s. This value must be coerced to a string before using it here.",l,ee(o)),Re(o)),(""+o).replace(du,Ht)}function Ht(o){switch(o){case'"':return"%22";case"'":return"%27";case";":return"%3B";case",":return"%2C";case`
156
+ `:return"%0A";case"\r":return"%0D";default:throw Error("escapeStringForLinkHeaderQuotedParamValueContextReplacer encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}function Ya(o){this.styles.add(o)}function ir(o){this.stylesheets.add(o)}function Et(o,l){l.styles.forEach(Ya,o),l.stylesheets.forEach(ir,o),l.suspenseyImages&&(o.suspenseyImages=!0)}function $c(o){return 0<o.stylesheets.size||o.suspenseyImages}function gt(o){if(o==null)return null;if(typeof o=="function")return o.$$typeof===hu?null:o.displayName||o.name||null;if(typeof o=="string")return o;switch(o){case _l:return"Fragment";case ai:return"Profiler";case si:return"StrictMode";case rs:return"Suspense";case Fs:return"SuspenseList";case Qn:return"Activity"}if(typeof o=="object")switch(typeof o.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),o.$$typeof){case li:return"Portal";case en:return o.displayName||"Context";case zo:return(o._context.displayName||"Context")+".Consumer";case wt:var l=o.render;return o=o.displayName,o||(o=l.displayName||l.name||"",o=o!==""?"ForwardRef("+o+")":"ForwardRef"),o;case Ms:return l=o.displayName||null,l!==null?l:gt(o.type)||"Memo";case ls:l=o._payload,o=o._init;try{return gt(o(l))}catch{}}return null}function Xa(o,l){if(o!==l){o.context._currentValue=o.parentValue,o=o.parent;var g=l.parent;if(o===null){if(g!==null)throw Error("The stacks must reach the root at the same time. This is a bug in React.")}else{if(g===null)throw Error("The stacks must reach the root at the same time. This is a bug in React.");Xa(o,g)}l.context._currentValue=l.value}}function Za(o){o.context._currentValue=o.parentValue,o=o.parent,o!==null&&Za(o)}function Ka(o){var l=o.parent;l!==null&&Ka(l),o.context._currentValue=o.value}function tl(o,l){if(o.context._currentValue=o.parentValue,o=o.parent,o===null)throw Error("The depth must equal at least at zero before reaching the root. This is a bug in React.");o.depth===l.depth?Xa(o,l):tl(o,l)}function Ft(o,l){var g=l.parent;if(g===null)throw Error("The depth must equal at least at zero before reaching the root. This is a bug in React.");o.depth===g.depth?Xa(o,g):Ft(o,g),l.context._currentValue=l.value}function kt(o){var l=Ul;l!==o&&(l===null?Ka(o):o===null?Za(l):l.depth===o.depth?Xa(l,o):l.depth>o.depth?tl(l,o):Ft(l,o),Ul=o)}function Or(o){if(o!==null&&typeof o!="function"){var l=String(o);zc.has(l)||(zc.add(l),console.error("Expected the last optional `callback` argument to be a function. Instead received: %s.",o))}}function oo(o,l){o=(o=o.constructor)&&gt(o)||"ReactClass";var g=o+"."+l;lc[g]||(console.error(`Can only update a mounting component. This usually means you called %s() outside componentWillMount() on the server. This is a no-op.
157
+
158
+ Please check the code for the %s component.`,l,o),lc[g]=!0)}function As(o,l,g){var E=o.id;o=o.overflow;var I=32-Fa(E)-1;E&=~(1<<I),g+=1;var F=32-Fa(l)+I;if(30<F){var G=I-I%5;return F=(E&(1<<G)-1).toString(32),E>>=G,I-=G,{id:1<<32-Fa(l)+I|g<<I|E,overflow:F+o}}return{id:1<<F|g<<I|E,overflow:o}}function Li(o){return o>>>=0,o===0?32:31-(Bu(o)/Pu|0)|0}function mo(){}function eu(o,l,g){switch(g=o[g],g===void 0?o.push(l):g!==l&&(l.then(mo,mo),l=g),l.status){case"fulfilled":return l.value;case"rejected":throw l.reason;default:switch(typeof l.status=="string"?l.then(mo,mo):(o=l,o.status="pending",o.then(function(E){if(l.status==="pending"){var I=l;I.status="fulfilled",I.value=E}},function(E){if(l.status==="pending"){var I=l;I.status="rejected",I.reason=E}})),l.status){case"fulfilled":return l.value;case"rejected":throw l.reason}throw pu=l,fl}}function Ec(){if(pu===null)throw Error("Expected a suspended thenable. This is a bug in React. Please file an issue.");var o=pu;return pu=null,o}function Fi(o,l){return o===l&&(o!==0||1/o===1/l)||o!==o&&l!==l}function qt(){if($n===null)throw Error(`Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
159
+ 1. You might have mismatching versions of React and the renderer (such as React DOM)
160
+ 2. You might be breaking the Rules of Hooks
161
+ 3. You might have more than one copy of React in the same app
162
+ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.`);return Jr&&console.error("Do not call Hooks inside useEffect(...), useMemo(...), or other built-in Hooks. You can only call Hooks at the top level of your React function. For more information, see https://react.dev/link/rules-of-hooks"),$n}function Mi(){if(0<Ri)throw Error("Rendered more hooks than during the previous render");return{memoizedState:null,queue:null,next:null}}function ua(){return Lt===null?Ir===null?(qo=!1,Ir=Lt=Mi()):(qo=!0,Lt=Ir):Lt.next===null?(qo=!1,Lt=Lt.next=Mi()):(qo=!0,Lt=Lt.next),Lt}function cr(){var o=Ma;return Ma=null,o}function Is(){Jr=!1,bs=Ao=zl=$n=null,Wl=!1,Ir=null,Ri=0,Lt=na=null}function tu(o){return Jr&&console.error("Context can only be read while React is rendering. In classes, you can read it in the render method or getDerivedStateFromProps. In function components, you can read it directly in the function body, but not inside Hooks like useReducer() or useMemo()."),o._currentValue}function nu(o,l){return typeof l=="function"?l(o):l}function da(o,l,g){if(o!==nu&&(oa="useReducer"),$n=qt(),Lt=ua(),qo){if(g=Lt.queue,l=g.dispatch,na!==null){var E=na.get(g);if(E!==void 0){na.delete(g),g=Lt.memoizedState;do{var I=E.action;Jr=!0,g=o(g,I),Jr=!1,E=E.next}while(E!==null);return Lt.memoizedState=g,[g,l]}}return[Lt.memoizedState,l]}return Jr=!0,o=o===nu?typeof l=="function"?l():l:g!==void 0?g(l):l,Jr=!1,Lt.memoizedState=o,o=Lt.queue={last:null,dispatch:null},o=o.dispatch=nl.bind(null,$n,o),[Lt.memoizedState,o]}function ha(o,l){if($n=qt(),Lt=ua(),l=l===void 0?null:l,Lt!==null){var g=Lt.memoizedState;if(g!==null&&l!==null){e:{var E=g[1];if(E===null)console.error("%s received a final argument during this render, but not during the previous render. Even though the final argument is optional, its type cannot change between renders.",oa),E=!1;else{l.length!==E.length&&console.error(`The final argument passed to %s changed size between renders. The order and size of this array must remain constant.
163
+
164
+ Previous: %s
165
+ Incoming: %s`,oa,"["+l.join(", ")+"]","["+E.join(", ")+"]");for(var I=0;I<E.length&&I<l.length;I++)if(!_u(l[I],E[I])){E=!1;break e}E=!0}}if(E)return g[0]}}return Jr=!0,o=o(),Jr=!1,Lt.memoizedState=[o,l],o}function nl(o,l,g){if(25<=Ri)throw Error("Too many re-renders. React limits the number of renders to prevent an infinite loop.");if(o===$n)if(Wl=!0,o={action:g,next:null},na===null&&(na=new Map),g=na.get(l),g===void 0)na.set(l,o);else{for(l=g;l.next!==null;)l=l.next;l.next=o}}function ol(){throw Error("A function wrapped in useEffectEvent can't be called during rendering.")}function Di(){throw Error("startTransition cannot be called during server rendering.")}function Ja(){throw Error("Cannot update optimistic state while rendering.")}function Qa(o,l,g){qt();var E=vi++,I=Ao;if(typeof o.$$FORM_ACTION=="function"){var F=null,G=bs;I=I.formState;var Z=o.$$IS_SIGNATURE_EQUAL;if(I!==null&&typeof Z=="function"){var pe=I[1];Z.call(o,I[2],I[3])&&(F=g!==void 0?"p"+g:"k"+_(JSON.stringify([G,null,E]),0),pe===F&&(uc=E,l=I[0]))}var te=o.bind(null,l);return o=function(Te){te(Te)},typeof te.$$FORM_ACTION=="function"&&(o.$$FORM_ACTION=function(Te){Te=te.$$FORM_ACTION(Te),g!==void 0&&(ye(g,"target"),g+="",Te.action=g);var _e=Te.data;return _e&&(F===null&&(F=g!==void 0?"p"+g:"k"+_(JSON.stringify([G,null,E]),0)),_e.append("$ACTION_KEY",F)),Te}),[l,o,!1]}var se=o.bind(null,l);return[l,function(Te){se(Te)},!1]}function jn(o){var l=xu;return xu+=1,Ma===null&&(Ma=[]),eu(Ma,o,l)}function fa(){throw Error("Cache cannot be refreshed during server rendering.")}function qa(){}function Oi(){if(k===0){B=console.log,j=console.info,Y=console.warn,Q=console.error,ke=console.group,re=console.groupCollapsed,be=console.groupEnd;var o={configurable:!0,enumerable:!0,value:qa,writable:!0};Object.defineProperties(console,{info:o,log:o,warn:o,error:o,group:o,groupCollapsed:o,groupEnd:o})}k++}function rl(){if(k--,k===0){var o={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:Zt({},o,{value:B}),info:Zt({},o,{value:j}),warn:Zt({},o,{value:Y}),error:Zt({},o,{value:Q}),group:Zt({},o,{value:ke}),groupCollapsed:Zt({},o,{value:re}),groupEnd:Zt({},o,{value:be})})}0>k&&console.error("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}function $a(o){var l=Error.prepareStackTrace;if(Error.prepareStackTrace=void 0,o=o.stack,Error.prepareStackTrace=l,o.startsWith(`Error: react-stack-top-frame
166
+ `)&&(o=o.slice(29)),l=o.indexOf(`
167
+ `),l!==-1&&(o=o.slice(l+1)),l=o.indexOf("react_stack_bottom_frame"),l!==-1&&(l=o.lastIndexOf(`
168
+ `,l)),l!==-1)o=o.slice(0,l);else return"";return o}function Oo(o){if(Ne===void 0)try{throw Error()}catch(g){var l=g.stack.trim().match(/\n( *(at )?)/);Ne=l&&l[1]||"",Oe=-1<g.stack.indexOf(`
169
+ at`)?" (<anonymous>)":-1<g.stack.indexOf("@")?"@unknown:0:0":""}return`
170
+ `+Ne+o+Oe}function jr(o,l){if(!o||Fe)return"";var g=Se.get(o);if(g!==void 0)return g;Fe=!0,g=Error.prepareStackTrace,Error.prepareStackTrace=void 0;var E=null;E=ct.H,ct.H=null,Oi();try{var I={DetermineComponentFrameRoot:function(){try{if(l){var _e=function(){throw Error()};if(Object.defineProperty(_e.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(_e,[])}catch(Ce){var Be=Ce}Reflect.construct(o,[],_e)}else{try{_e.call()}catch(Ce){Be=Ce}o.call(_e.prototype)}}else{try{throw Error()}catch(Ce){Be=Ce}(_e=o())&&typeof _e.catch=="function"&&_e.catch(function(){})}}catch(Ce){if(Ce&&Be&&typeof Ce.stack=="string")return[Ce.stack,Be.stack]}return[null,null]}};I.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var F=Object.getOwnPropertyDescriptor(I.DetermineComponentFrameRoot,"name");F&&F.configurable&&Object.defineProperty(I.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var G=I.DetermineComponentFrameRoot(),Z=G[0],pe=G[1];if(Z&&pe){var te=Z.split(`
171
+ `),se=pe.split(`
172
+ `);for(G=F=0;F<te.length&&!te[F].includes("DetermineComponentFrameRoot");)F++;for(;G<se.length&&!se[G].includes("DetermineComponentFrameRoot");)G++;if(F===te.length||G===se.length)for(F=te.length-1,G=se.length-1;1<=F&&0<=G&&te[F]!==se[G];)G--;for(;1<=F&&0<=G;F--,G--)if(te[F]!==se[G]){if(F!==1||G!==1)do if(F--,G--,0>G||te[F]!==se[G]){var Te=`
173
+ `+te[F].replace(" at new "," at ");return o.displayName&&Te.includes("<anonymous>")&&(Te=Te.replace("<anonymous>",o.displayName)),typeof o=="function"&&Se.set(o,Te),Te}while(1<=F&&0<=G);break}}}finally{Fe=!1,ct.H=E,rl(),Error.prepareStackTrace=g}return te=(te=o?o.displayName||o.name:"")?Oo(te):"",typeof o=="function"&&Se.set(o,te),te}function kc(o){if(typeof o=="string")return Oo(o);if(typeof o=="function")return o.prototype&&o.prototype.isReactComponent?jr(o,!0):jr(o,!1);if(typeof o=="object"&&o!==null){switch(o.$$typeof){case wt:return jr(o.render,!1);case Ms:return jr(o.type,!1);case ls:var l=o,g=l._payload;l=l._init;try{o=l(g)}catch{return Oo("Lazy")}return kc(o)}if(typeof o.name=="string"){e:{if(g=o.name,l=o.env,o=o.debugLocation,o!=null){o=$a(o);var E=o.lastIndexOf(`
174
+ `);if(o=E===-1?o:o.slice(E+1),o.indexOf(g)!==-1){g=`
175
+ `+o;break e}}g=Oo(g+(l?" ["+l+"]":""))}return g}}switch(o){case Fs:return Oo("SuspenseList");case rs:return Oo("Suspense")}return""}function ei(){var o=gl();1e3<o-Pt&&(ct.recentlyCreatedOwnerStacks=0,Pt=o)}function jo(o,l){return(500<l.byteSize||$c(l.contentState))&&l.contentPreamble===null}function ti(o){if(typeof o=="object"&&o!==null&&typeof o.environmentName=="string"){var l=o.environmentName;o=[o].slice(0),typeof o[0]=="string"?o.splice(0,1,"%c%s%c "+o[0],"background: #e6e6e6;background: light-dark(rgba(0,0,0,0.1), rgba(255,255,255,0.25));color: #000000;color: light-dark(#000000, #ffffff);border-radius: 2px"," "+l+" ",""):o.splice(0,0,"%c%s%c","background: #e6e6e6;background: light-dark(rgba(0,0,0,0.1), rgba(255,255,255,0.25));color: #000000;color: light-dark(#000000, #ffffff);border-radius: 2px"," "+l+" ",""),o.unshift(console),l=Ar.apply(console.error,o),l()}else console.error(o);return null}function Ql(o,l,g,E,I,F,G,Z,pe,te,se){var Te=new Set;this.destination=null,this.flushScheduled=!1,this.resumableState=o,this.renderState=l,this.rootFormatContext=g,this.progressiveChunkSize=E===void 0?12800:E,this.status=10,this.fatalError=null,this.pendingRootTasks=this.allPendingTasks=this.nextSegmentId=0,this.completedPreambleSegments=this.completedRootSegment=null,this.byteSize=0,this.abortableTasks=Te,this.pingedTasks=[],this.clientRenderedBoundaries=[],this.completedBoundaries=[],this.partialBoundaries=[],this.trackedPostpones=null,this.onError=I===void 0?ti:I,this.onPostpone=te===void 0?mo:te,this.onAllReady=F===void 0?mo:F,this.onShellReady=G===void 0?mo:G,this.onShellError=Z===void 0?mo:Z,this.onFatalError=pe===void 0?mo:pe,this.formState=se===void 0?null:se,this.didWarnForKey=null}function ga(o,l,g,E,I,F,G,Z,pe,te,se,Te){return ei(),l=new Ql(l,g,E,I,F,G,Z,pe,te,se,Te),g=Cl(l,0,null,E,!1,!1),g.parentFlushed=!0,o=Hr(l,null,o,-1,null,g,null,null,l.abortableTasks,null,E,null,cc,null,null,mr,null),Tl(o),l.pingedTasks.push(o),l}function Ho(o,l,g,E,I,F,G,Z,pe,te,se){return o=ga(o,l,g,E,I,F,G,Z,pe,te,se,void 0),o.trackedPostpones={workingMap:new Map,rootNodes:[],rootSlots:null},o}function Gn(o,l,g,E,I,F,G,Z,pe){return ei(),g=new Ql(l.resumableState,g,l.rootFormatContext,l.progressiveChunkSize,E,I,F,G,Z,pe,null),g.nextSegmentId=l.nextSegmentId,typeof l.replaySlots=="number"?(E=Cl(g,0,null,l.rootFormatContext,!1,!1),E.parentFlushed=!0,o=Hr(g,null,o,-1,null,E,null,null,g.abortableTasks,null,l.rootFormatContext,null,cc,null,null,mr,null),Tl(o),g.pingedTasks.push(o),g):(o=Cc(g,null,{nodes:l.replayNodes,slots:l.replaySlots,pendingTasks:0},o,-1,null,null,g.abortableTasks,null,l.rootFormatContext,null,cc,null,null,mr,null),Tl(o),g.pingedTasks.push(o),g)}function Xt(o,l,g,E,I,F,G,Z,pe){return o=Gn(o,l,g,E,I,F,G,Z,pe),o.trackedPostpones={workingMap:new Map,rootNodes:[],rootSlots:null},o}function wc(o,l){o.pingedTasks.push(l),o.pingedTasks.length===1&&(o.flushScheduled=o.destination!==null,o.trackedPostpones!==null||o.status===10?Os(function(){return os(o)}):A(function(){return os(o)}))}function wl(o,l,g,E,I){return g={status:Dt,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,row:l,completedSegments:[],byteSize:0,fallbackAbortableTasks:g,errorDigest:null,contentState:Ss(),fallbackState:Ss(),contentPreamble:E,fallbackPreamble:I,trackedContentKeyPath:null,trackedFallbackNode:null,errorMessage:null,errorStack:null,errorComponentStack:null},l!==null&&(l.pendingTasks++,E=l.boundaries,E!==null&&(o.allPendingTasks++,g.pendingTasks++,E.push(g)),o=l.inheritedHoistables,o!==null&&Et(g.contentState,o)),g}function Hr(o,l,g,E,I,F,G,Z,pe,te,se,Te,_e,Be,Ce,Ze,Wt){o.allPendingTasks++,I===null?o.pendingRootTasks++:I.pendingTasks++,Be!==null&&Be.pendingTasks++;var Ye={replay:null,node:g,childIndex:E,ping:function(){return wc(o,Ye)},blockedBoundary:I,blockedSegment:F,blockedPreamble:G,hoistableState:Z,abortSet:pe,keyPath:te,formatContext:se,context:Te,treeContext:_e,row:Be,componentStack:Ce,thenableState:l};return Ye.debugTask=Wt,pe.add(Ye),Ye}function Cc(o,l,g,E,I,F,G,Z,pe,te,se,Te,_e,Be,Ce,Ze){o.allPendingTasks++,F===null?o.pendingRootTasks++:F.pendingTasks++,_e!==null&&_e.pendingTasks++,g.pendingTasks++;var Wt={replay:g,node:E,childIndex:I,ping:function(){return wc(o,Wt)},blockedBoundary:F,blockedSegment:null,blockedPreamble:null,hoistableState:G,abortSet:Z,keyPath:pe,formatContext:te,context:se,treeContext:Te,row:_e,componentStack:Be,thenableState:l};return Wt.debugTask=Ze,Z.add(Wt),Wt}function Cl(o,l,g,E,I,F){return{status:Dt,parentFlushed:!1,id:-1,index:l,chunks:[],children:[],preambleChildren:[],parentFormatContext:E,boundary:g,lastPushedText:I,textEmbedded:F}}function ll(){if(a===null||a.componentStack===null)return"";var o=a.componentStack;try{var l="";if(typeof o.type=="string")l+=Oo(o.type);else if(typeof o.type=="function"){if(!o.owner){var g=l,E=o.type,I=E?E.displayName||E.name:"",F=I?Oo(I):"";l=g+F}}else o.owner||(l+=kc(o.type));for(;o;)g=null,o.debugStack!=null?g=$a(o.debugStack):(F=o,F.stack!=null&&(g=typeof F.stack!="string"?F.stack=$a(F.stack):F.stack)),(o=o.owner)&&g&&(l+=`
176
+ `+g);var G=l}catch(Z){G=`
177
+ Error generating stack: `+Z.message+`
178
+ `+Z.stack}return G}function pa(o,l){if(l!=null)for(var g=l.length-1;0<=g;g--){var E=l[g];if(typeof E.name=="string"||typeof E.time=="number")break;if(E.awaited!=null){var I=E.debugStack==null?E.awaited:E;if(I.debugStack!==void 0){o.componentStack={parent:o.componentStack,type:E,owner:I.owner,stack:I.debugStack},o.debugTask=I.debugTask;break}}}}function Sl(o,l){if(l!=null)for(var g=0;g<l.length;g++){var E=l[g];typeof E.name=="string"&&E.debugStack!==void 0&&(o.componentStack={parent:o.componentStack,type:E,owner:E.owner,stack:E.debugStack},o.debugTask=E.debugTask)}}function Tl(o){var l=o.node;if(typeof l=="object"&&l!==null)switch(l.$$typeof){case Wi:var g=l.type,E=l._owner,I=l._debugStack;Sl(o,l._debugInfo),o.debugTask=l._debugTask,o.componentStack={parent:o.componentStack,type:g,owner:E,stack:I};break;case ls:Sl(o,l._debugInfo);break;default:typeof l.then=="function"&&Sl(o,l._debugInfo)}}function xa(o){return o===null?null:{parent:o.parent,type:"Suspense Fallback",owner:o.owner,stack:o.stack}}function rt(o){var l={};return o&&Object.defineProperty(l,"componentStack",{configurable:!0,enumerable:!0,get:function(){try{var g="",E=o;do g+=kc(E.type),E=E.parent;while(E);var I=g}catch(F){I=`
179
+ Error generating stack: `+F.message+`
180
+ `+F.stack}return Object.defineProperty(l,"componentStack",{value:I}),I}}),l}function Ur(o,l,g,E,I){o.errorDigest=l,g instanceof Error?(l=String(g.message),g=String(g.stack)):(l=typeof g=="object"&&g!==null?S(g):String(g),g=null),I=I?`Switched to client rendering because the server rendering aborted due to:
181
+
182
+ `:`Switched to client rendering because the server rendering errored:
183
+
184
+ `,o.errorMessage=I+l,o.errorStack=g!==null?I+g:null,o.errorComponentStack=E.componentStack}function An(o,l,g,E){if(o=o.onError,l=E?E.run(o.bind(null,l,g)):o(l,g),l!=null&&typeof l!="string")console.error('onError returned something with a type other than "string". onError should return a string and may return null or undefined but must not return anything else. It received something of type "%s" instead',typeof l);else return l}function sl(o,l,g,E){g=o.onShellError;var I=o.onFatalError;E?(E.run(g.bind(null,l)),E.run(I.bind(null,l))):(g(l),I(l)),o.destination!==null?(o.status=Io,$(o.destination,l)):(o.status=13,o.fatalError=l)}function Hn(o,l){ql(o,l.next,l.hoistables)}function ql(o,l,g){for(;l!==null;){g!==null&&(Et(l.hoistables,g),l.inheritedHoistables=g);var E=l.boundaries;if(E!==null){l.boundaries=null;for(var I=0;I<E.length;I++){var F=E[I];g!==null&&Et(F.contentState,g),ns(o,F,null,null)}}if(l.pendingTasks--,0<l.pendingTasks)break;g=l.hoistables,l=l.next}}function Bs(o,l){var g=l.boundaries;if(g!==null&&l.pendingTasks===g.length){for(var E=!0,I=0;I<g.length;I++){var F=g[I];if(F.pendingTasks!==1||F.parentFlushed||jo(o,F)){E=!1;break}}E&&ql(o,l,l.hoistables)}}function al(o){var l={pendingTasks:1,boundaries:null,hoistables:Ss(),inheritedHoistables:null,together:!1,next:null};return o!==null&&0<o.pendingTasks&&(l.pendingTasks++,l.boundaries=[],o.next=l),l}function Al(o,l,g,E,I){var F=l.keyPath,G=l.treeContext,Z=l.row,pe=l.componentStack,te=l.debugTask;Sl(l,l.node.props.children._debugInfo),l.keyPath=g,g=E.length;var se=null;if(l.replay!==null){var Te=l.replay.slots;if(Te!==null&&typeof Te=="object")for(var _e=0;_e<g;_e++){var Be=I!=="backwards"&&I!=="unstable_legacy-backwards"?_e:g-1-_e,Ce=E[Be];l.row=se=al(se),l.treeContext=As(G,g,Be);var Ze=Te[Be];typeof Ze=="number"?(Ps(o,l,Ze,Ce,Be),delete Te[Be]):Vn(o,l,Ce,Be),--se.pendingTasks===0&&Hn(o,se)}else for(Te=0;Te<g;Te++)_e=I!=="backwards"&&I!=="unstable_legacy-backwards"?Te:g-1-Te,Be=E[_e],zr(o,l,Be),l.row=se=al(se),l.treeContext=As(G,g,_e),Vn(o,l,Be,_e),--se.pendingTasks===0&&Hn(o,se)}else if(I!=="backwards"&&I!=="unstable_legacy-backwards")for(I=0;I<g;I++)Te=E[I],zr(o,l,Te),l.row=se=al(se),l.treeContext=As(G,g,I),Vn(o,l,Te,I),--se.pendingTasks===0&&Hn(o,se);else{for(I=l.blockedSegment,Te=I.children.length,_e=I.chunks.length,Be=g-1;0<=Be;Be--){Ce=E[Be],l.row=se=al(se),l.treeContext=As(G,g,Be),Ze=Cl(o,_e,null,l.formatContext,Be===0?I.lastPushedText:!0,!0),I.children.splice(Te,0,Ze),l.blockedSegment=Ze,zr(o,l,Ce);try{Vn(o,l,Ce,Be),Ze.lastPushedText&&Ze.textEmbedded&&Ze.chunks.push(Pn),Ze.status=Ot,Wr(o,l.blockedBoundary,Ze),--se.pendingTasks===0&&Hn(o,se)}catch(Wt){throw Ze.status=o.status===12?gn:bt,Wt}}l.blockedSegment=I,I.lastPushedText=!1}Z!==null&&se!==null&&0<se.pendingTasks&&(Z.pendingTasks++,se.next=Z),l.treeContext=G,l.row=Z,l.keyPath=F,l.componentStack=pe,l.debugTask=te}function In(o,l,g,E,I,F){var G=l.thenableState;for(l.thenableState=null,$n={},zl=l,Ao=o,bs=g,Jr=!1,vi=Nn=0,uc=-1,xu=0,Ma=G,o=Yt(E,I,F);Wl;)Wl=!1,vi=Nn=0,uc=-1,xu=0,Ri+=1,Lt=null,o=E(I,F);return Is(),o}function Il(o,l,g,E,I,F,G){var Z=!1;if(F!==0&&o.formState!==null){var pe=l.blockedSegment;if(pe!==null){Z=!0,pe=pe.chunks;for(var te=0;te<F;te++)te===G?pe.push(Ys):pe.push(ko)}}F=l.keyPath,l.keyPath=g,I?(g=l.treeContext,l.treeContext=As(g,1,0),Vn(o,l,E,-1),l.treeContext=g):Z?Vn(o,l,E,-1):Uo(o,l,E,-1),l.keyPath=F}function Bl(o,l,g,E,I,F){if(typeof E=="function")if(E.prototype&&E.prototype.isReactComponent){var G=I;if("ref"in I){G={};for(var Z in I)Z!=="ref"&&(G[Z]=I[Z])}var pe=E.defaultProps;if(pe){G===I&&(G=Zt({},G,I));for(var te in pe)G[te]===void 0&&(G[te]=pe[te])}var se=G,Te=mr,_e=E.contextType;if("contextType"in E&&_e!==null&&(_e===void 0||_e.$$typeof!==en)&&!ku.has(E)){ku.add(E);var Be=_e===void 0?" However, it is set to undefined. This can be caused by a typo or by mixing up named and default imports. This can also happen due to a circular dependency, so try moving the createContext() call to a separate file.":typeof _e!="object"?" However, it is set to a "+typeof _e+".":_e.$$typeof===zo?" Did you accidentally pass the Context.Consumer instead?":" However, it is set to an object with keys {"+Object.keys(_e).join(", ")+"}.";console.error("%s defines an invalid contextType. contextType should point to the Context object returned by React.createContext().%s",gt(E)||"Component",Be)}typeof _e=="object"&&_e!==null&&(Te=_e._currentValue);var Ce=new E(se,Te);if(typeof E.getDerivedStateFromProps=="function"&&(Ce.state===null||Ce.state===void 0)){var Ze=gt(E)||"Component";ac.has(Ze)||(ac.add(Ze),console.error("`%s` uses `getDerivedStateFromProps` but its initial state is %s. This is not recommended. Instead, define the initial state by assigning an object to `this.state` in the constructor of `%s`. This ensures that `getDerivedStateFromProps` arguments have a consistent shape.",Ze,Ce.state===null?"null":"undefined",Ze))}if(typeof E.getDerivedStateFromProps=="function"||typeof Ce.getSnapshotBeforeUpdate=="function"){var Wt=null,Ye=null,ft=null;if(typeof Ce.componentWillMount=="function"&&Ce.componentWillMount.__suppressDeprecationWarning!==!0?Wt="componentWillMount":typeof Ce.UNSAFE_componentWillMount=="function"&&(Wt="UNSAFE_componentWillMount"),typeof Ce.componentWillReceiveProps=="function"&&Ce.componentWillReceiveProps.__suppressDeprecationWarning!==!0?Ye="componentWillReceiveProps":typeof Ce.UNSAFE_componentWillReceiveProps=="function"&&(Ye="UNSAFE_componentWillReceiveProps"),typeof Ce.componentWillUpdate=="function"&&Ce.componentWillUpdate.__suppressDeprecationWarning!==!0?ft="componentWillUpdate":typeof Ce.UNSAFE_componentWillUpdate=="function"&&(ft="UNSAFE_componentWillUpdate"),Wt!==null||Ye!==null||ft!==null){var bn=gt(E)||"Component",Ln=typeof E.getDerivedStateFromProps=="function"?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";fu.has(bn)||(fu.add(bn),console.error(`Unsafe legacy lifecycles will not be called for components using new component APIs.
185
+
186
+ %s uses %s but also contains the following legacy lifecycles:%s%s%s
187
+
188
+ The above lifecycles should be removed. Learn more about this warning here:
189
+ https://react.dev/link/unsafe-component-lifecycles`,bn,Ln,Wt!==null?`
190
+ `+Wt:"",Ye!==null?`
191
+ `+Ye:"",ft!==null?`
192
+ `+ft:""))}}var It=gt(E)||"Component";Ce.render||(E.prototype&&typeof E.prototype.render=="function"?console.error("No `render` method found on the %s instance: did you accidentally return an object from the constructor?",It):console.error("No `render` method found on the %s instance: you may have forgotten to define `render`.",It)),!Ce.getInitialState||Ce.getInitialState.isReactClassApproved||Ce.state||console.error("getInitialState was defined on %s, a plain JavaScript class. This is only supported for classes created using React.createClass. Did you mean to define a state property instead?",It),Ce.getDefaultProps&&!Ce.getDefaultProps.isReactClassApproved&&console.error("getDefaultProps was defined on %s, a plain JavaScript class. This is only supported for classes created using React.createClass. Use a static property to define defaultProps instead.",It),Ce.contextType&&console.error("contextType was defined as an instance property on %s. Use a static property to define contextType instead.",It),E.childContextTypes&&!ic.has(E)&&(ic.add(E),console.error("%s uses the legacy childContextTypes API which was removed in React 19. Use React.createContext() instead. (https://react.dev/link/legacy-context)",It)),E.contextTypes&&!gu.has(E)&&(gu.add(E),console.error("%s uses the legacy contextTypes API which was removed in React 19. Use React.createContext() with static contextType instead. (https://react.dev/link/legacy-context)",It)),typeof Ce.componentShouldUpdate=="function"&&console.error("%s has a method called componentShouldUpdate(). Did you mean shouldComponentUpdate()? The name is phrased as a question because the function is expected to return a value.",It),E.prototype&&E.prototype.isPureReactComponent&&typeof Ce.shouldComponentUpdate<"u"&&console.error("%s has a method called shouldComponentUpdate(). shouldComponentUpdate should not be used when extending React.PureComponent. Please extend React.Component if shouldComponentUpdate is used.",gt(E)||"A pure component"),typeof Ce.componentDidUnmount=="function"&&console.error("%s has a method called componentDidUnmount(). But there is no such lifecycle method. Did you mean componentWillUnmount()?",It),typeof Ce.componentDidReceiveProps=="function"&&console.error("%s has a method called componentDidReceiveProps(). But there is no such lifecycle method. If you meant to update the state in response to changing props, use componentWillReceiveProps(). If you meant to fetch data or run side-effects or mutations after React has updated the UI, use componentDidUpdate().",It),typeof Ce.componentWillRecieveProps=="function"&&console.error("%s has a method called componentWillRecieveProps(). Did you mean componentWillReceiveProps()?",It),typeof Ce.UNSAFE_componentWillRecieveProps=="function"&&console.error("%s has a method called UNSAFE_componentWillRecieveProps(). Did you mean UNSAFE_componentWillReceiveProps()?",It);var Ve=Ce.props!==se;Ce.props!==void 0&&Ve&&console.error("When calling super() in `%s`, make sure to pass up the same props that your component's constructor was passed.",It),Ce.defaultProps&&console.error("Setting defaultProps as an instance property on %s is not supported and will be ignored. Instead, define defaultProps as a static property on %s.",It,It),typeof Ce.getSnapshotBeforeUpdate!="function"||typeof Ce.componentDidUpdate=="function"||ta.has(E)||(ta.add(E),console.error("%s: getSnapshotBeforeUpdate() should be used with componentDidUpdate(). This component defines getSnapshotBeforeUpdate() only.",gt(E))),typeof Ce.getDerivedStateFromProps=="function"&&console.error("%s: getDerivedStateFromProps() is defined as an instance method and will be ignored. Instead, declare it as a static method.",It),typeof Ce.getDerivedStateFromError=="function"&&console.error("%s: getDerivedStateFromError() is defined as an instance method and will be ignored. Instead, declare it as a static method.",It),typeof E.getSnapshotBeforeUpdate=="function"&&console.error("%s: getSnapshotBeforeUpdate() is defined as a static method and will be ignored. Instead, declare it as an instance method.",It);var Fn=Ce.state;Fn&&(typeof Fn!="object"||cl(Fn))&&console.error("%s.state: must be set to an object or null",It),typeof Ce.getChildContext=="function"&&typeof E.childContextTypes!="object"&&console.error("%s.getChildContext(): childContextTypes must be defined in order to use getChildContext().",It);var Bo=Ce.state!==void 0?Ce.state:null;Ce.updater=wu,Ce.props=se,Ce.state=Bo;var Gt={queue:[],replace:!1};Ce._reactInternals=Gt;var rn=E.contextType;if(Ce.context=typeof rn=="object"&&rn!==null?rn._currentValue:mr,Ce.state===se){var tr=gt(E)||"Component";Uc.has(tr)||(Uc.add(tr),console.error("%s: It is not recommended to assign props directly to state because updates to props won't be reflected in state. In most cases, it is better to use props directly.",tr))}var ho=E.getDerivedStateFromProps;if(typeof ho=="function"){var Zn=ho(se,Bo);if(Zn===void 0){var ln=gt(E)||"Component";La.has(ln)||(La.add(ln),console.error("%s.getDerivedStateFromProps(): A valid state object (or null) must be returned. You have returned undefined.",ln))}var zn=Zn==null?Bo:Zt({},Bo,Zn);Ce.state=zn}if(typeof E.getDerivedStateFromProps!="function"&&typeof Ce.getSnapshotBeforeUpdate!="function"&&(typeof Ce.UNSAFE_componentWillMount=="function"||typeof Ce.componentWillMount=="function")){var nr=Ce.state;if(typeof Ce.componentWillMount=="function"){if(Ce.componentWillMount.__suppressDeprecationWarning!==!0){var br=gt(E)||"Unknown";sc[br]||(console.warn(`componentWillMount has been renamed, and is not recommended for use. See https://react.dev/link/unsafe-component-lifecycles for details.
193
+
194
+ * Move code from componentWillMount to componentDidMount (preferred in most cases) or the constructor.
195
+
196
+ Please update the following components: %s`,br),sc[br]=!0)}Ce.componentWillMount()}if(typeof Ce.UNSAFE_componentWillMount=="function"&&Ce.UNSAFE_componentWillMount(),nr!==Ce.state&&(console.error("%s.componentWillMount(): Assigning directly to this.state is deprecated (except inside a component's constructor). Use setState instead.",gt(E)||"Component"),wu.enqueueReplaceState(Ce,Ce.state,null)),Gt.queue!==null&&0<Gt.queue.length){var Kn=Gt.queue,pn=Gt.replace;if(Gt.queue=null,Gt.replace=!1,pn&&Kn.length===1)Ce.state=Kn[0];else{for(var Po=pn?Kn[0]:Ce.state,or=!0,_o=pn?1:0;_o<Kn.length;_o++){var Gl=Kn[_o],rr=typeof Gl=="function"?Gl.call(Ce,Po,se,void 0):Gl;rr!=null&&(or?(or=!1,Po=Zt({},Po,rr)):Zt(Po,rr))}Ce.state=Po}}else Gt.queue=null}var Mn=At(Ce);if(o.status===12)throw null;Ce.props!==se&&(er||console.error("It looks like %s is reassigning its own `this.props` while rendering. This is not supported and can lead to confusing bugs.",gt(E)||"a component"),er=!0);var Br=l.keyPath;l.keyPath=g,Uo(o,l,Mn,-1),l.keyPath=Br}else{if(E.prototype&&typeof E.prototype.render=="function"){var to=gt(E)||"Unknown";uo[to]||(console.error("The <%s /> component appears to have a render method, but doesn't extend React.Component. This is likely to cause errors. Change %s to extend React.Component instead.",to,to),uo[to]=!0)}var Wc=In(o,l,g,E,I,void 0);if(o.status===12)throw null;var bl=Nn!==0,yn=vi,Pr=uc;if(E.contextTypes){var Lo=gt(E)||"Unknown";on[Lo]||(on[Lo]=!0,console.error("%s uses the legacy contextTypes API which was removed in React 19. Use React.createContext() with React.useContext() instead. (https://react.dev/link/legacy-context)",Lo))}if(E&&E.childContextTypes&&console.error(`childContextTypes cannot be defined on a function component.
197
+ %s.childContextTypes = ...`,E.displayName||E.name||"Component"),typeof E.getDerivedStateFromProps=="function"){var ki=gt(E)||"Unknown";Da[ki]||(console.error("%s: Function components do not support getDerivedStateFromProps.",ki),Da[ki]=!0)}if(typeof E.contextType=="object"&&E.contextType!==null){var Oa=gt(E)||"Unknown";$o[Oa]||(console.error("%s: Function components do not support contextType.",Oa),$o[Oa]=!0)}Il(o,l,g,Wc,bl,yn,Pr)}else if(typeof E=="string"){var Qr=l.blockedSegment;if(Qr===null){var ja=I.children,lr=l.formatContext,wi=l.keyPath;l.formatContext=wn(lr,E,I),l.keyPath=g,Vn(o,l,ja,-1),l.formatContext=lr,l.keyPath=wi}else{var Gc=Jc(Qr.chunks,E,I,o.resumableState,o.renderState,l.blockedPreamble,l.hoistableState,l.formatContext,Qr.lastPushedText);Qr.lastPushedText=!1;var _r=l.formatContext,Ci=l.keyPath;if(l.keyPath=g,(l.formatContext=wn(_r,E,I)).insertionMode===ui){var Fo=Cl(o,0,null,l.formatContext,!1,!1);Qr.preambleChildren.push(Fo),l.blockedSegment=Fo;try{Fo.status=6,Vn(o,l,Gc,-1),Fo.lastPushedText&&Fo.textEmbedded&&Fo.chunks.push(Pn),Fo.status=Ot,Wr(o,l.blockedBoundary,Fo)}finally{l.blockedSegment=Qr}}else Vn(o,l,Gc,-1);l.formatContext=_r,l.keyPath=Ci;e:{var Ha=Qr.chunks,ra=o.resumableState;switch(E){case"title":case"style":case"script":case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break e;case"body":if(_r.insertionMode<=is){ra.hasBody=!0;break e}break;case"html":if(_r.insertionMode===ka){ra.hasHtml=!0;break e}break;case"head":if(_r.insertionMode<=is)break e}Ha.push(vn(E))}Qr.lastPushedText=!1}}else{switch(E){case Ru:case si:case ai:case _l:var ys=l.keyPath;l.keyPath=g,Uo(o,l,I.children,-1),l.keyPath=ys;return;case Qn:var Nr=l.blockedSegment;if(Nr===null){if(I.mode!=="hidden"){var Lr=l.keyPath;l.keyPath=g,Vn(o,l,I.children,-1),l.keyPath=Lr}}else if(I.mode!=="hidden"){Nr.chunks.push(Oc),Nr.lastPushedText=!1;var yl=l.keyPath;l.keyPath=g,Vn(o,l,I.children,-1),l.keyPath=yl,Nr.chunks.push($i),Nr.lastPushedText=!1}return;case Fs:e:{var sr=I.children,fo=I.revealOrder;if(fo==="forwards"||fo==="backwards"||fo==="unstable_legacy-backwards"){if(cl(sr)){Al(o,l,g,sr,fo);break e}var vs=d(sr);if(vs){var vl=vs.call(sr);if(vl){_s(l,sr,-1,vl,vs);var la=vl.next();if(!la.done){var Vl=[];do Vl.push(la.value),la=vl.next();while(!la.done);Al(o,l,g,sr,fo)}break e}}}if(fo==="together"){var mu=l.keyPath,Xo=l.row,qr=l.row=al(null);qr.boundaries=[],qr.together=!0,l.keyPath=g,Uo(o,l,sr,-1),--qr.pendingTasks===0&&Hn(o,qr),l.keyPath=mu,l.row=Xo,Xo!==null&&0<qr.pendingTasks&&(Xo.pendingTasks++,qr.next=Xo)}else{var Si=l.keyPath;l.keyPath=g,Uo(o,l,sr,-1),l.keyPath=Si}}return;case ru:case Bc:throw Error("ReactDOMServer does not yet support scope components.");case rs:e:if(l.replay!==null){var dc=l.keyPath,hc=l.formatContext,ju=l.row;l.keyPath=g,l.formatContext=Mo(o.resumableState,hc),l.row=null;var sa=I.children;try{Vn(o,l,sa,-1)}finally{l.keyPath=dc,l.formatContext=hc,l.row=ju}}else{var Ua=l.keyPath,aa=l.formatContext,fc=l.row,Nu=l.blockedBoundary,Cu=l.blockedPreamble,Zo=l.hoistableState,Rl=l.blockedSegment,ia=I.fallback,Vc=I.children,Fr=new Set,Dn=l.formatContext.insertionMode<vo?wl(o,l.row,Fr,Ie(),Ie()):wl(o,l.row,Fr,null,null);o.trackedPostpones!==null&&(Dn.trackedContentKeyPath=g);var xn=Cl(o,Rl.chunks.length,Dn,l.formatContext,!1,!1);Rl.children.push(xn),Rl.lastPushedText=!1;var Jt=Cl(o,0,null,l.formatContext,!1,!1);if(Jt.parentFlushed=!0,o.trackedPostpones!==null){var Su=l.componentStack,za=[g[0],"Suspense Fallback",g[2]],Yc=[za[1],za[2],[],null];o.trackedPostpones.workingMap.set(za,Yc),Dn.trackedFallbackNode=Yc,l.blockedSegment=xn,l.blockedPreamble=Dn.fallbackPreamble,l.keyPath=za,l.formatContext=vt(o.resumableState,aa),l.componentStack=xa(Su),xn.status=6;try{Vn(o,l,ia,-1),xn.lastPushedText&&xn.textEmbedded&&xn.chunks.push(Pn),xn.status=Ot,Wr(o,Nu,xn)}catch(Uu){throw xn.status=o.status===12?gn:bt,Uu}finally{l.blockedSegment=Rl,l.blockedPreamble=Cu,l.keyPath=Ua,l.formatContext=aa}var Wa=Hr(o,null,Vc,-1,Dn,Jt,Dn.contentPreamble,Dn.contentState,l.abortSet,g,Mo(o.resumableState,l.formatContext),l.context,l.treeContext,null,Su,mr,l.debugTask);Tl(Wa),o.pingedTasks.push(Wa)}else{l.blockedBoundary=Dn,l.blockedPreamble=Dn.contentPreamble,l.hoistableState=Dn.contentState,l.blockedSegment=Jt,l.keyPath=g,l.formatContext=Mo(o.resumableState,aa),l.row=null,Jt.status=6;try{if(Vn(o,l,Vc,-1),Jt.lastPushedText&&Jt.textEmbedded&&Jt.chunks.push(Pn),Jt.status=Ot,Wr(o,Dn,Jt),va(Dn,Jt),Dn.pendingTasks===0&&Dn.status===Dt){if(Dn.status=Ot,!jo(o,Dn)){fc!==null&&--fc.pendingTasks===0&&Hn(o,fc),o.pendingRootTasks===0&&l.blockedPreamble&&Ls(o);break e}}else fc!==null&&fc.together&&Bs(o,fc)}catch(Uu){if(Dn.status=Ue,o.status===12){Jt.status=gn;var Ti=o.fatalError}else Jt.status=bt,Ti=Uu;var Xc=rt(l.componentStack),Ai=An(o,Ti,Xc,l.debugTask);Ur(Dn,Ai,Ti,Xc,!1),ma(o,Dn)}finally{l.blockedBoundary=Nu,l.blockedPreamble=Cu,l.hoistableState=Zo,l.blockedSegment=Rl,l.keyPath=Ua,l.formatContext=aa,l.row=fc}var gc=Hr(o,null,ia,-1,Nu,xn,Dn.fallbackPreamble,Dn.fallbackState,Fr,[g[0],"Suspense Fallback",g[2]],vt(o.resumableState,l.formatContext),l.context,l.treeContext,l.row,xa(l.componentStack),mr,l.debugTask);Tl(gc),o.pingedTasks.push(gc)}}return}if(typeof E=="object"&&E!==null)switch(E.$$typeof){case wt:if("ref"in I){var pc={};for(var bu in I)bu!=="ref"&&(pc[bu]=I[bu])}else pc=I;var Tu=In(o,l,g,E.render,pc,F);Il(o,l,g,Tu,Nn!==0,vi,uc);return;case Ms:Bl(o,l,g,E.type,I,F);return;case en:var Lu=I.value,Zc=I.children,Kc=l.context,Ii=l.keyPath,ca=E._currentValue;E._currentValue=Lu,E._currentRenderer!==void 0&&E._currentRenderer!==null&&E._currentRenderer!==ms&&console.error("Detected multiple renderers concurrently rendering the same context provider. This is currently unsupported."),E._currentRenderer=ms;var Rs=Ul,ar={parent:Rs,depth:Rs===null?0:Rs.depth+1,context:E,parentValue:ca,value:Lu};Ul=ar,l.context=ar,l.keyPath=g,Uo(o,l,Zc,-1);var xc=Ul;if(xc===null)throw Error("Tried to pop a Context at the root of the app. This is a bug in React.");xc.context!==E&&console.error("The parent context is not the expected context. This is probably a bug in React."),xc.context._currentValue=xc.parentValue,E._currentRenderer!==void 0&&E._currentRenderer!==null&&E._currentRenderer!==ms&&console.error("Detected multiple renderers concurrently rendering the same context provider. This is currently unsupported."),E._currentRenderer=ms;var Fu=Ul=xc.parent;l.context=Fu,l.keyPath=Ii,Kc!==l.context&&console.error("Popping the context provider did not return back to the original snapshot. This is a bug in React.");return;case zo:var Hu=E._context,Au=I.children;typeof Au!="function"&&console.error("A context consumer was rendered with multiple children, or a child that isn't a function. A context consumer expects a single child that is a function. If you did pass a function, make sure there is no trailing or leading whitespace around it.");var Ju=Au(Hu._currentValue),yu=l.keyPath;l.keyPath=g,Uo(o,l,Ju,-1),l.keyPath=yu;return;case ls:var Qu=co(E);if(o.status===12)throw null;Bl(o,l,g,Qu,I,F);return}var Mu="";throw(E===void 0||typeof E=="object"&&E!==null&&Object.keys(E).length===0)&&(Mu+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports."),Error("Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: "+((E==null?E:typeof E)+"."+Mu))}}function Ps(o,l,g,E,I){var F=l.replay,G=l.blockedBoundary,Z=Cl(o,0,null,l.formatContext,!1,!1);Z.id=g,Z.parentFlushed=!0;try{l.replay=null,l.blockedSegment=Z,Vn(o,l,E,I),Z.status=Ot,Wr(o,G,Z),G===null?o.completedRootSegment=Z:(va(G,Z),G.parentFlushed&&o.partialBoundaries.push(G))}finally{l.replay=F,l.blockedSegment=null}}function $l(o,l,g,E,I,F,G,Z,pe,te){F=te.nodes;for(var se=0;se<F.length;se++){var Te=F[se];if(I===Te[1]){if(Te.length===4){if(E!==null&&E!==Te[0])throw Error("Expected the resume to render <"+Te[0]+"> in this slot but instead it rendered <"+E+">. The tree doesn't match so React will fallback to client rendering.");var _e=Te[2];E=Te[3],I=l.node,l.replay={nodes:_e,slots:E,pendingTasks:1};try{if(Bl(o,l,g,G,Z,pe),l.replay.pendingTasks===1&&0<l.replay.nodes.length)throw Error("Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering.");l.replay.pendingTasks--}catch(Ve){if(typeof Ve=="object"&&Ve!==null&&(Ve===fl||typeof Ve.then=="function"))throw l.node===I?l.replay=te:F.splice(se,1),Ve;l.replay.pendingTasks--,G=rt(l.componentStack),Z=o,o=l.blockedBoundary,g=Ve,pe=E,E=An(Z,g,G,l.debugTask),es(Z,o,_e,pe,g,E,G,!1)}l.replay=te}else{if(G!==rs)throw Error("Expected the resume to render <Suspense> in this slot but instead it rendered <"+(gt(G)||"Unknown")+">. The tree doesn't match so React will fallback to client rendering.");e:{te=void 0,E=Te[5],G=Te[2],pe=Te[3],I=Te[4]===null?[]:Te[4][2],Te=Te[4]===null?null:Te[4][3];var Be=l.keyPath,Ce=l.formatContext,Ze=l.row,Wt=l.replay,Ye=l.blockedBoundary,ft=l.hoistableState,bn=Z.children,Ln=Z.fallback,It=new Set;Z=l.formatContext.insertionMode<vo?wl(o,l.row,It,Ie(),Ie()):wl(o,l.row,It,null,null),Z.parentFlushed=!0,Z.rootSegmentID=E,l.blockedBoundary=Z,l.hoistableState=Z.contentState,l.keyPath=g,l.formatContext=Mo(o.resumableState,Ce),l.row=null,l.replay={nodes:G,slots:pe,pendingTasks:1};try{if(Vn(o,l,bn,-1),l.replay.pendingTasks===1&&0<l.replay.nodes.length)throw Error("Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering.");if(l.replay.pendingTasks--,Z.pendingTasks===0&&Z.status===Dt){Z.status=Ot,o.completedBoundaries.push(Z);break e}}catch(Ve){Z.status=Ue,_e=rt(l.componentStack),te=An(o,Ve,_e,l.debugTask),Ur(Z,te,Ve,_e,!1),l.replay.pendingTasks--,o.clientRenderedBoundaries.push(Z)}finally{l.blockedBoundary=Ye,l.hoistableState=ft,l.replay=Wt,l.keyPath=Be,l.formatContext=Ce,l.row=Ze}Z=Cc(o,null,{nodes:I,slots:Te,pendingTasks:0},Ln,-1,Ye,Z.fallbackState,It,[g[0],"Suspense Fallback",g[2]],vt(o.resumableState,l.formatContext),l.context,l.treeContext,l.row,xa(l.componentStack),mr,l.debugTask),Tl(Z),o.pingedTasks.push(Z)}}F.splice(se,1);break}}}function _s(o,l,g,E,I){E===l?(g!==-1||o.componentStack===null||typeof o.componentStack.type!="function"||Object.prototype.toString.call(o.componentStack.type)!=="[object GeneratorFunction]"||Object.prototype.toString.call(E)!=="[object Generator]")&&(pl||console.error("Using Iterators as children is unsupported and will likely yield unexpected results because enumerating a generator mutates it. You may convert it to an array with `Array.from()` or the `[...spread]` operator before rendering. You can also use an Iterable that can iterate multiple times over the same items."),pl=!0):l.entries!==I||xl||(console.error("Using Maps as children is not supported. Use an array of keyed ReactElements instead."),xl=!0)}function Uo(o,l,g,E){l.replay!==null&&typeof l.replay.slots=="number"?Ps(o,l,l.replay.slots,g,E):(l.node=g,l.childIndex=E,g=l.componentStack,E=l.debugTask,Tl(l),Ns(o,l),l.componentStack=g,l.debugTask=E)}function Ns(o,l){var g=l.node,E=l.childIndex;if(g!==null){if(typeof g=="object"){switch(g.$$typeof){case Wi:var I=g.type,F=g.key;g=g.props;var G=g.ref;G=G!==void 0?G:null;var Z=l.debugTask,pe=gt(I);F=F??(E===-1?0:E);var te=[l.keyPath,pe,F];l.replay!==null?Z?Z.run($l.bind(null,o,l,te,pe,F,E,I,g,G,l.replay)):$l(o,l,te,pe,F,E,I,g,G,l.replay):Z?Z.run(Bl.bind(null,o,l,te,I,g,G)):Bl(o,l,te,I,g,G);return;case li:throw Error("Portals are not currently supported by the server renderer. Render them conditionally so that they only appear on the client render.");case ls:if(I=co(g),o.status===12)throw null;Uo(o,l,I,E);return}if(cl(g)){Sc(o,l,g,E);return}if((F=d(g))&&(I=F.call(g))){if(_s(l,g,E,I,F),g=I.next(),!g.done){F=[];do F.push(g.value),g=I.next();while(!g.done);Sc(o,l,F,E)}return}if(typeof g.then=="function")return l.thenableState=null,Uo(o,l,jn(g),E);if(g.$$typeof===en)return Uo(o,l,g._currentValue,E);throw o=Object.prototype.toString.call(g),Error("Objects are not valid as a React child (found: "+(o==="[object Object]"?"object with keys {"+Object.keys(g).join(", ")+"}":o)+"). If you meant to render a collection of children, use an array instead.")}typeof g=="string"?(l=l.blockedSegment,l!==null&&(l.lastPushedText=Cn(l.chunks,g,o.renderState,l.lastPushedText))):typeof g=="number"||typeof g=="bigint"?(l=l.blockedSegment,l!==null&&(l.lastPushedText=Cn(l.chunks,""+g,o.renderState,l.lastPushedText))):(typeof g=="function"&&(o=g.displayName||g.name||"Component",console.error("Functions are not valid as a React child. This may happen if you return %s instead of <%s /> from render. Or maybe you meant to call this function rather than return it.",o,o)),typeof g=="symbol"&&console.error(`Symbols are not valid as a React child.
198
+ %s`,String(g)))}}function zr(o,l,g){if(g!==null&&typeof g=="object"&&(g.$$typeof===Wi||g.$$typeof===li)&&g._store&&(!g._store.validated&&g.key==null||g._store.validated===2)){if(typeof g._store!="object")throw Error("React Component in warnForMissingKey should have a _store. This error is likely caused by a bug in React. Please file an issue.");g._store.validated=1;var E=o.didWarnForKey;if(E==null&&(E=o.didWarnForKey=new WeakSet),o=l.componentStack,o!==null&&!E.has(o)){E.add(o);var I=gt(g.type);E=g._owner;var F=o.owner;if(o="",F&&typeof F.type<"u"){var G=gt(F.type);G&&(o=`
199
+
200
+ Check the render method of \``+G+"`.")}o||I&&(o=`
201
+
202
+ Check the top-level render call using <`+I+">."),I="",E!=null&&F!==E&&(F=null,typeof E.type<"u"?F=gt(E.type):typeof E.name=="string"&&(F=E.name),F&&(I=" It was passed a child from "+F+".")),E=l.componentStack,l.componentStack={parent:l.componentStack,type:g.type,owner:g._owner,stack:g._debugStack},console.error('Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.',o,I),l.componentStack=E}}}function Sc(o,l,g,E){var I=l.keyPath,F=l.componentStack,G=l.debugTask;if(Sl(l,l.node._debugInfo),E!==-1&&(l.keyPath=[l.keyPath,"Fragment",E],l.replay!==null)){for(var Z=l.replay,pe=Z.nodes,te=0;te<pe.length;te++){var se=pe[te];if(se[1]===E){E=se[2],se=se[3],l.replay={nodes:E,slots:se,pendingTasks:1};try{if(Sc(o,l,g,-1),l.replay.pendingTasks===1&&0<l.replay.nodes.length)throw Error("Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering.");l.replay.pendingTasks--}catch(Ce){if(typeof Ce=="object"&&Ce!==null&&(Ce===fl||typeof Ce.then=="function"))throw Ce;l.replay.pendingTasks--;var Te=rt(l.componentStack);g=l.blockedBoundary;var _e=Ce,Be=se;se=An(o,_e,Te,l.debugTask),es(o,g,E,Be,_e,se,Te,!1)}l.replay=Z,pe.splice(te,1);break}}l.keyPath=I,l.componentStack=F,l.debugTask=G;return}if(Z=l.treeContext,pe=g.length,l.replay!==null&&(te=l.replay.slots,te!==null&&typeof te=="object")){for(E=0;E<pe;E++)se=g[E],l.treeContext=As(Z,pe,E),_e=te[E],typeof _e=="number"?(Ps(o,l,_e,se,E),delete te[E]):Vn(o,l,se,E);l.treeContext=Z,l.keyPath=I,l.componentStack=F,l.debugTask=G;return}for(te=0;te<pe;te++)E=g[te],zr(o,l,E),l.treeContext=As(Z,pe,te),Vn(o,l,E,te);l.treeContext=Z,l.keyPath=I,l.componentStack=F,l.debugTask=G}function Tc(o,l,g){if(g.status=st,g.rootSegmentID=o.nextSegmentId++,o=g.trackedContentKeyPath,o===null)throw Error("It should not be possible to postpone at the root. This is a bug in React.");var E=g.trackedFallbackNode,I=[],F=l.workingMap.get(o);return F===void 0?(g=[o[1],o[2],I,null,E,g.rootSegmentID],l.workingMap.set(o,g),fr(g,o[0],l),g):(F[4]=E,F[5]=g.rootSegmentID,F)}function Ac(o,l,g,E){E.status=st;var I=g.keyPath,F=g.blockedBoundary;if(F===null)E.id=o.nextSegmentId++,l.rootSlots=E.id,o.completedRootSegment!==null&&(o.completedRootSegment.status=st);else{if(F!==null&&F.status===Dt){var G=Tc(o,l,F);if(F.trackedContentKeyPath===I&&g.childIndex===-1){E.id===-1&&(E.id=E.parentFlushed?F.rootSegmentID:o.nextSegmentId++),G[3]=E.id;return}}if(E.id===-1&&(E.id=E.parentFlushed&&F!==null?F.rootSegmentID:o.nextSegmentId++),g.childIndex===-1)I===null?l.rootSlots=E.id:(g=l.workingMap.get(I),g===void 0?(g=[I[1],I[2],[],E.id],fr(g,I[0],l)):g[3]=E.id);else{if(I===null){if(o=l.rootSlots,o===null)o=l.rootSlots={};else if(typeof o=="number")throw Error("It should not be possible to postpone both at the root of an element as well as a slot below. This is a bug in React.")}else if(F=l.workingMap,G=F.get(I),G===void 0)o={},G=[I[1],I[2],[],o],F.set(I,G),fr(G,I[0],l);else if(o=G[3],o===null)o=G[3]={};else if(typeof o=="number")throw Error("It should not be possible to postpone both at the root of an element as well as a slot below. This is a bug in React.");o[g.childIndex]=E.id}}}function ma(o,l){o=o.trackedPostpones,o!==null&&(l=l.trackedContentKeyPath,l!==null&&(l=o.workingMap.get(l),l!==void 0&&(l.length=4,l[2]=[],l[3]=null)))}function ba(o,l,g){return Cc(o,g,l.replay,l.node,l.childIndex,l.blockedBoundary,l.hoistableState,l.abortSet,l.keyPath,l.formatContext,l.context,l.treeContext,l.row,l.componentStack,mr,l.debugTask)}function ya(o,l,g){var E=l.blockedSegment,I=Cl(o,E.chunks.length,null,l.formatContext,E.lastPushedText,!0);return E.children.push(I),E.lastPushedText=!1,Hr(o,g,l.node,l.childIndex,l.blockedBoundary,I,l.blockedPreamble,l.hoistableState,l.abortSet,l.keyPath,l.formatContext,l.context,l.treeContext,l.row,l.componentStack,mr,l.debugTask)}function Vn(o,l,g,E){var I=l.formatContext,F=l.context,G=l.keyPath,Z=l.treeContext,pe=l.componentStack,te=l.debugTask,se=l.blockedSegment;if(se===null){se=l.replay;try{return Uo(o,l,g,E)}catch(Be){if(Is(),g=Be===fl?Ec():Be,o.status!==12&&typeof g=="object"&&g!==null){if(typeof g.then=="function"){E=Be===fl?cr():null,o=ba(o,l,E).ping,g.then(o,o),l.formatContext=I,l.context=F,l.keyPath=G,l.treeContext=Z,l.componentStack=pe,l.replay=se,l.debugTask=te,kt(F);return}if(g.message==="Maximum call stack size exceeded"){g=Be===fl?cr():null,g=ba(o,l,g),o.pingedTasks.push(g),l.formatContext=I,l.context=F,l.keyPath=G,l.treeContext=Z,l.componentStack=pe,l.replay=se,l.debugTask=te,kt(F);return}}}}else{var Te=se.children.length,_e=se.chunks.length;try{return Uo(o,l,g,E)}catch(Be){if(Is(),se.children.length=Te,se.chunks.length=_e,g=Be===fl?Ec():Be,o.status!==12&&typeof g=="object"&&g!==null){if(typeof g.then=="function"){se=g,g=Be===fl?cr():null,o=ya(o,l,g).ping,se.then(o,o),l.formatContext=I,l.context=F,l.keyPath=G,l.treeContext=Z,l.componentStack=pe,l.debugTask=te,kt(F);return}if(g.message==="Maximum call stack size exceeded"){se=Be===fl?cr():null,se=ya(o,l,se),o.pingedTasks.push(se),l.formatContext=I,l.context=F,l.keyPath=G,l.treeContext=Z,l.componentStack=pe,l.debugTask=te,kt(F);return}}}}throw l.formatContext=I,l.context=F,l.keyPath=G,l.treeContext=Z,kt(F),g}function ou(o){var l=o.blockedBoundary,g=o.blockedSegment;g!==null&&(g.status=gn,ns(this,l,o.row,g))}function es(o,l,g,E,I,F,G,Z){for(var pe=0;pe<g.length;pe++){var te=g[pe];if(te.length===4)es(o,l,te[2],te[3],I,F,G,Z);else{var se=o;te=te[5];var Te=I,_e=F,Be=G,Ce=Z,Ze=wl(se,null,new Set,null,null);Ze.parentFlushed=!0,Ze.rootSegmentID=te,Ze.status=Ue,Ur(Ze,_e,Te,Be,Ce),Ze.parentFlushed&&se.clientRenderedBoundaries.push(Ze)}}if(g.length=0,E!==null){if(l===null)throw Error("We should not have any resumable nodes in the shell. This is a bug in React.");if(l.status!==Ue&&(l.status=Ue,Ur(l,F,I,G,Z),l.parentFlushed&&o.clientRenderedBoundaries.push(l)),typeof E=="object")for(var Wt in E)delete E[Wt]}}function ni(o,l,g){var E=o.blockedBoundary,I=o.blockedSegment;if(I!==null){if(I.status===6)return;I.status=gn}var F=rt(o.componentStack),G=o.node;if(G!==null&&typeof G=="object"&&pa(o,G._debugInfo),E===null){if(l.status!==13&&l.status!==Io){if(E=o.replay,E===null){l.trackedPostpones!==null&&I!==null?(E=l.trackedPostpones,An(l,g,F,o.debugTask),Ac(l,E,o,I),ns(l,null,o.row,I)):(An(l,g,F,o.debugTask),sl(l,g,F,o.debugTask));return}E.pendingTasks--,E.pendingTasks===0&&0<E.nodes.length&&(I=An(l,g,F,null),es(l,null,E.nodes,E.slots,g,I,F,!0)),l.pendingRootTasks--,l.pendingRootTasks===0&&Pl(l)}}else{if(G=l.trackedPostpones,E.status!==Ue){if(G!==null&&I!==null)return An(l,g,F,o.debugTask),Ac(l,G,o,I),E.fallbackAbortableTasks.forEach(function(Z){return ni(Z,l,g)}),E.fallbackAbortableTasks.clear(),ns(l,E,o.row,I);E.status=Ue,I=An(l,g,F,o.debugTask),E.status=Ue,Ur(E,I,g,F,!0),ma(l,E),E.parentFlushed&&l.clientRenderedBoundaries.push(E)}E.pendingTasks--,F=E.row,F!==null&&--F.pendingTasks===0&&Hn(l,F),E.fallbackAbortableTasks.forEach(function(Z){return ni(Z,l,g)}),E.fallbackAbortableTasks.clear()}o=o.row,o!==null&&--o.pendingTasks===0&&Hn(l,o),l.allPendingTasks--,l.allPendingTasks===0&&ts(l)}function ji(o,l){try{var g=o.renderState,E=g.onHeaders;if(E){var I=g.headers;if(I){g.headers=null;var F=I.preconnects;if(I.fontPreloads&&(F&&(F+=", "),F+=I.fontPreloads),I.highImagePreloads&&(F&&(F+=", "),F+=I.highImagePreloads),!l){var G=g.styles.values(),Z=G.next();e:for(;0<I.remainingCapacity&&!Z.done;Z=G.next())for(var pe=Z.value.sheets.values(),te=pe.next();0<I.remainingCapacity&&!te.done;te=pe.next()){var se=te.value,Te=se.props,_e=Te.href,Be=se.props,Ce=Jl(Be.href,"style",{crossOrigin:Be.crossOrigin,integrity:Be.integrity,nonce:Be.nonce,type:Be.type,fetchPriority:Be.fetchPriority,referrerPolicy:Be.referrerPolicy,media:Be.media});if(0<=(I.remainingCapacity-=Ce.length+2))g.resets.style[_e]=Yn,F&&(F+=", "),F+=Ce,g.resets.style[_e]=typeof Te.crossOrigin=="string"||typeof Te.integrity=="string"?[Te.crossOrigin,Te.integrity]:Yn;else break e}}E(F?{Link:F}:{})}}}catch(Ze){An(o,Ze,{},null)}}function Pl(o){o.trackedPostpones===null&&ji(o,!0),o.trackedPostpones===null&&Ls(o),o.onShellError=mo,o=o.onShellReady,o()}function ts(o){ji(o,o.trackedPostpones===null?!0:o.completedRootSegment===null||o.completedRootSegment.status!==st),Ls(o),o=o.onAllReady,o()}function va(o,l){if(l.chunks.length===0&&l.children.length===1&&l.children[0].boundary===null&&l.children[0].id===-1){var g=l.children[0];g.id=l.id,g.parentFlushed=!0,g.status!==Ot&&g.status!==gn&&g.status!==bt||va(o,g)}else o.completedSegments.push(l)}function Wr(o,l,g){if(K!==null){g=g.chunks;for(var E=0,I=0;I<g.length;I++)E+=g[I].byteLength;l===null?o.byteSize+=E:l.byteSize+=E}}function ns(o,l,g,E){if(g!==null&&(--g.pendingTasks===0?Hn(o,g):g.together&&Bs(o,g)),o.allPendingTasks--,l===null){if(E!==null&&E.parentFlushed){if(o.completedRootSegment!==null)throw Error("There can only be one root segment. This is a bug in React.");o.completedRootSegment=E}o.pendingRootTasks--,o.pendingRootTasks===0&&Pl(o)}else if(l.pendingTasks--,l.status!==Ue)if(l.pendingTasks===0){if(l.status===Dt&&(l.status=Ot),E!==null&&E.parentFlushed&&(E.status===Ot||E.status===gn)&&va(l,E),l.parentFlushed&&o.completedBoundaries.push(l),l.status===Ot)g=l.row,g!==null&&Et(g.hoistables,l.contentState),jo(o,l)||(l.fallbackAbortableTasks.forEach(ou,o),l.fallbackAbortableTasks.clear(),g!==null&&--g.pendingTasks===0&&Hn(o,g)),o.pendingRootTasks===0&&o.trackedPostpones===null&&l.contentPreamble!==null&&Ls(o);else if(l.status===st&&(l=l.row,l!==null)){if(o.trackedPostpones!==null){g=o.trackedPostpones;var I=l.next;if(I!==null&&(E=I.boundaries,E!==null))for(I.boundaries=null,I=0;I<E.length;I++){var F=E[I];Tc(o,g,F),ns(o,F,null,null)}}--l.pendingTasks===0&&Hn(o,l)}}else E===null||!E.parentFlushed||E.status!==Ot&&E.status!==gn||(va(l,E),l.completedSegments.length===1&&l.parentFlushed&&o.partialBoundaries.push(l)),l=l.row,l!==null&&l.together&&Bs(o,l);o.allPendingTasks===0&&ts(o)}function os(o){if(o.status!==Io&&o.status!==13){var l=Ul,g=ct.H;ct.H=Ei;var E=ct.A;ct.A=p;var I=jt;jt=o;var F=ct.getCurrentStack;ct.getCurrentStack=ll;var G=r;r=o.resumableState;try{var Z=o.pingedTasks,pe;for(pe=0;pe<Z.length;pe++){var te=o,se=Z[pe],Te=se.blockedSegment;if(Te===null){var _e=void 0,Be=te;if(te=se,te.replay.pendingTasks!==0){kt(te.context),_e=a,a=te;try{if(typeof te.replay.slots=="number"?Ps(Be,te,te.replay.slots,te.node,te.childIndex):Ns(Be,te),te.replay.pendingTasks===1&&0<te.replay.nodes.length)throw Error("Couldn't find all resumable slots by key/index during replaying. The tree doesn't match so React will fallback to client rendering.");te.replay.pendingTasks--,te.abortSet.delete(te),ns(Be,te.blockedBoundary,te.row,null)}catch(pn){Is();var Ce=pn===fl?Ec():pn;if(typeof Ce=="object"&&Ce!==null&&typeof Ce.then=="function"){var Ze=te.ping;Ce.then(Ze,Ze),te.thenableState=pn===fl?cr():null}else{te.replay.pendingTasks--,te.abortSet.delete(te);var Wt=rt(te.componentStack),Ye=void 0,ft=Be,bn=te.blockedBoundary,Ln=Be.status===12?Be.fatalError:Ce,It=Wt,Ve=te.replay.nodes,Fn=te.replay.slots;Ye=An(ft,Ln,It,te.debugTask),es(ft,bn,Ve,Fn,Ln,Ye,It,!1),Be.pendingRootTasks--,Be.pendingRootTasks===0&&Pl(Be),Be.allPendingTasks--,Be.allPendingTasks===0&&ts(Be)}}finally{a=_e}}}else if(Be=_e=void 0,Ye=se,ft=Te,ft.status===Dt){ft.status=6,kt(Ye.context),Be=a,a=Ye;var Bo=ft.children.length,Gt=ft.chunks.length;try{Ns(te,Ye),ft.lastPushedText&&ft.textEmbedded&&ft.chunks.push(Pn),Ye.abortSet.delete(Ye),ft.status=Ot,Wr(te,Ye.blockedBoundary,ft),ns(te,Ye.blockedBoundary,Ye.row,ft)}catch(pn){Is(),ft.children.length=Bo,ft.chunks.length=Gt;var rn=pn===fl?Ec():te.status===12?te.fatalError:pn;if(te.status===12&&te.trackedPostpones!==null){var tr=te.trackedPostpones,ho=rt(Ye.componentStack);Ye.abortSet.delete(Ye),An(te,rn,ho,Ye.debugTask),Ac(te,tr,Ye,ft),ns(te,Ye.blockedBoundary,Ye.row,ft)}else if(typeof rn=="object"&&rn!==null&&typeof rn.then=="function"){ft.status=Dt,Ye.thenableState=pn===fl?cr():null;var Zn=Ye.ping;rn.then(Zn,Zn)}else{var ln=rt(Ye.componentStack);Ye.abortSet.delete(Ye),ft.status=bt;var zn=Ye.blockedBoundary,nr=Ye.row,br=Ye.debugTask;if(nr!==null&&--nr.pendingTasks===0&&Hn(te,nr),te.allPendingTasks--,_e=An(te,rn,ln,br),zn===null)sl(te,rn,ln,br);else if(zn.pendingTasks--,zn.status!==Ue){zn.status=Ue,Ur(zn,_e,rn,ln,!1),ma(te,zn);var Kn=zn.row;Kn!==null&&--Kn.pendingTasks===0&&Hn(te,Kn),zn.parentFlushed&&te.clientRenderedBoundaries.push(zn),te.pendingRootTasks===0&&te.trackedPostpones===null&&zn.contentPreamble!==null&&Ls(te)}te.allPendingTasks===0&&ts(te)}}finally{a=Be}}}Z.splice(0,pe),o.destination!==null&&ur(o,o.destination)}catch(pn){Z={},An(o,pn,Z,null),sl(o,pn,Z,null)}finally{r=G,ct.H=g,ct.A=E,ct.getCurrentStack=F,g===Ei&&kt(l),jt=I}}}function Ic(o,l,g){l.preambleChildren.length&&g.push(l.preambleChildren);for(var E=!1,I=0;I<l.children.length;I++)E=vu(o,l.children[I],g)||E;return E}function vu(o,l,g){var E=l.boundary;if(E===null)return Ic(o,l,g);var I=E.contentPreamble,F=E.fallbackPreamble;if(I===null||F===null)return!1;switch(E.status){case Ot:if(bc(o.renderState,I),o.byteSize+=E.byteSize,l=E.completedSegments[0],!l)throw Error("A previously unvisited boundary must have exactly one root segment. This is a bug in React.");return Ic(o,l,g);case st:if(o.trackedPostpones!==null)return!0;case Ue:if(l.status===Ot)return bc(o.renderState,F),Ic(o,l,g);default:return!0}}function Ls(o){if(o.completedRootSegment&&o.completedPreambleSegments===null){var l=[],g=o.byteSize,E=vu(o,o.completedRootSegment,l),I=o.renderState.preamble;E===!1||I.headChunks&&I.bodyChunks?o.completedPreambleSegments=l:o.byteSize=g}}function Bn(o,l,g,E){switch(g.parentFlushed=!0,g.status){case Dt:g.id=o.nextSegmentId++;case st:return E=g.id,g.lastPushedText=!1,g.textEmbedded=!1,o=o.renderState,T(l,mi),T(l,o.placeholderPrefix),o=M(E.toString(16)),T(l,o),O(l,qi);case Ot:g.status=zt;var I=!0,F=g.chunks,G=0;g=g.children;for(var Z=0;Z<g.length;Z++){for(I=g[Z];G<I.index;G++)T(l,F[G]);I=il(o,l,I,E)}for(;G<F.length-1;G++)T(l,F[G]);return G<F.length&&(I=O(l,F[G])),I;case gn:return!0;default:throw Error("Aborted, errored or already flushed boundaries should not be flushed again. This is a bug in React.")}}function il(o,l,g,E){var I=g.boundary;if(I===null)return Bn(o,l,g,E);if(I.parentFlushed=!0,I.status===Ue){var F=I.row;F!==null&&--F.pendingTasks===0&&Hn(o,F),F=I.errorDigest;var G=I.errorMessage,Z=I.errorStack;I=I.errorComponentStack,O(l,au),T(l,bi),F&&(T(l,Ta),T(l,M(Pe(F))),T(l,Yr)),G&&(T(l,fs),T(l,M(Pe(G))),T(l,Yr)),Z&&(T(l,yi),T(l,M(Pe(Z))),T(l,Yr)),I&&(T(l,gs),T(l,M(Pe(I))),T(l,Yr)),O(l,iu),Bn(o,l,g,E)}else if(I.status!==Ot)I.status===Dt&&(I.rootSegmentID=o.nextSegmentId++),0<I.completedSegments.length&&o.partialBoundaries.push(I),kl(l,o.renderState,I.rootSegmentID),E&&Et(E,I.fallbackState),Bn(o,l,g,E);else if(!eo&&jo(o,I)&&(ml+I.byteSize>o.progressiveChunkSize||$c(I.contentState)))I.rootSegmentID=o.nextSegmentId++,o.completedBoundaries.push(I),kl(l,o.renderState,I.rootSegmentID),Bn(o,l,g,E);else{if(ml+=I.byteSize,E&&Et(E,I.contentState),g=I.row,g!==null&&jo(o,I)&&--g.pendingTasks===0&&Hn(o,g),O(l,ec),g=I.completedSegments,g.length!==1)throw Error("A previously unvisited boundary must have exactly one root segment. This is a bug in React.");il(o,l,g[0],E)}return O(l,Xs)}function oi(o,l,g,E){return vc(l,o.renderState,g.parentFormatContext,g.id),il(o,l,g,E),Ga(l,g.parentFormatContext)}function ri(o,l,g){ml=g.byteSize;for(var E=g.completedSegments,I=0;I<E.length;I++)Hi(o,l,g,E[I]);E.length=0,E=g.row,E!==null&&jo(o,g)&&--E.pendingTasks===0&&Hn(o,E),sn(l,g.contentState,o.renderState),E=o.resumableState,o=o.renderState,I=g.rootSegmentID,g=g.contentState;var F=o.stylesToHoist;return o.stylesToHoist=!1,T(l,o.startInlineScript),T(l,dn),F?((E.instructions&Nt)===un&&(E.instructions|=Nt,T(l,wo)),(E.instructions&bo)===un&&(E.instructions|=bo,T(l,qe)),(E.instructions&yt)===un?(E.instructions|=yt,T(l,hn)):T(l,Kt)):((E.instructions&bo)===un&&(E.instructions|=bo,T(l,qe)),T(l,xt)),E=M(I.toString(16)),T(l,o.boundaryPrefix),T(l,E),T(l,ao),T(l,o.segmentPrefix),T(l,E),F?(T(l,Qo),el(l,g)):T(l,Sr),g=O(l,$e),yc(l,o)&&g}function Hi(o,l,g,E){if(E.status===zt)return!0;var I=g.contentState,F=E.id;if(F===-1){if((E.id=g.rootSegmentID)===-1)throw Error("A root segment ID must have been assigned by now. This is a bug in React.");return oi(o,l,E,I)}return F===g.rootSegmentID?oi(o,l,E,I):(oi(o,l,E,I),g=o.resumableState,o=o.renderState,T(l,o.startInlineScript),T(l,dn),(g.instructions&Ct)===un?(g.instructions|=Ct,T(l,me)):T(l,De),T(l,o.segmentPrefix),F=M(F.toString(16)),T(l,F),T(l,Me),T(l,o.placeholderPrefix),T(l,F),l=O(l,pt),l)}function ur(o,l){lo=new Uint8Array(2048),qn=0;try{if(!(0<o.pendingRootTasks)){var g,E=o.completedRootSegment;if(E!==null){if(E.status===st)return;var I=o.completedPreambleSegments;if(I===null)return;ml=o.byteSize;var F=o.resumableState,G=o.renderState,Z=G.preamble,pe=Z.htmlChunks,te=Z.headChunks,se;if(pe){for(se=0;se<pe.length;se++)T(l,pe[se]);if(te)for(se=0;se<te.length;se++)T(l,te[se]);else T(l,Vt("head")),T(l,dn)}else if(te)for(se=0;se<te.length;se++)T(l,te[se]);var Te=G.charsetChunks;for(se=0;se<Te.length;se++)T(l,Te[se]);Te.length=0,G.preconnects.forEach(Qt,l),G.preconnects.clear();var _e=G.viewportChunks;for(se=0;se<_e.length;se++)T(l,_e[se]);_e.length=0,G.fontPreloads.forEach(Qt,l),G.fontPreloads.clear(),G.highImagePreloads.forEach(Qt,l),G.highImagePreloads.clear(),dt=G,G.styles.forEach(Cs,l),dt=null;var Be=G.importMapChunks;for(se=0;se<Be.length;se++)T(l,Be[se]);Be.length=0,G.bootstrapScripts.forEach(Qt,l),G.scripts.forEach(Qt,l),G.scripts.clear(),G.bulkPreloads.forEach(Qt,l),G.bulkPreloads.clear(),pe||te||(F.instructions|=St);var Ce=G.hoistableChunks;for(se=0;se<Ce.length;se++)T(l,Ce[se]);for(F=Ce.length=0;F<I.length;F++){var Ze=I[F];for(G=0;G<Ze.length;G++)il(o,l,Ze[G],null)}var Wt=o.renderState.preamble,Ye=Wt.headChunks;(Wt.htmlChunks||Ye)&&T(l,vn("head"));var ft=Wt.bodyChunks;if(ft)for(I=0;I<ft.length;I++)T(l,ft[I]);il(o,l,E,null),o.completedRootSegment=null;var bn=o.renderState;if(o.allPendingTasks!==0||o.clientRenderedBoundaries.length!==0||o.completedBoundaries.length!==0||o.trackedPostpones!==null&&(o.trackedPostpones.rootNodes.length!==0||o.trackedPostpones.rootSlots!==null)){var Ln=o.resumableState;if((Ln.instructions&nt)===un){if(Ln.instructions|=nt,T(l,bn.startInlineScript),(Ln.instructions&St)===un){Ln.instructions|=St;var It="_"+Ln.idPrefix+"R_";T(l,tc),T(l,M(Pe(It))),T(l,ut)}T(l,dn),T(l,xi),O(l,Fl)}}yc(l,bn)}var Ve=o.renderState;E=0;var Fn=Ve.viewportChunks;for(E=0;E<Fn.length;E++)T(l,Fn[E]);Fn.length=0,Ve.preconnects.forEach(Qt,l),Ve.preconnects.clear(),Ve.fontPreloads.forEach(Qt,l),Ve.fontPreloads.clear(),Ve.highImagePreloads.forEach(Qt,l),Ve.highImagePreloads.clear(),Ve.styles.forEach(Rc,l),Ve.scripts.forEach(Qt,l),Ve.scripts.clear(),Ve.bulkPreloads.forEach(Qt,l),Ve.bulkPreloads.clear();var Bo=Ve.hoistableChunks;for(E=0;E<Bo.length;E++)T(l,Bo[E]);Bo.length=0;var Gt=o.clientRenderedBoundaries;for(g=0;g<Gt.length;g++){var rn=Gt[g];Ve=l;var tr=o.resumableState,ho=o.renderState,Zn=rn.rootSegmentID,ln=rn.errorDigest,zn=rn.errorMessage,nr=rn.errorStack,br=rn.errorComponentStack;T(Ve,ho.startInlineScript),T(Ve,dn),(tr.instructions&Nt)===un?(tr.instructions|=Nt,T(Ve,En)):T(Ve,Go),T(Ve,ho.boundaryPrefix),T(Ve,M(Zn.toString(16))),T(Ve,Hl),(ln||zn||nr||br)&&(T(Ve,fn),T(Ve,M(ks(ln||"")))),(zn||nr||br)&&(T(Ve,fn),T(Ve,M(ks(zn||"")))),(nr||br)&&(T(Ve,fn),T(Ve,M(ks(nr||"")))),br&&(T(Ve,fn),T(Ve,M(ks(br))));var Kn=O(Ve,Ks);if(!Kn){o.destination=null,g++,Gt.splice(0,g);return}}Gt.splice(0,g);var pn=o.completedBoundaries;for(g=0;g<pn.length;g++)if(!ri(o,l,pn[g])){o.destination=null,g++,pn.splice(0,g);return}pn.splice(0,g),U(l),lo=new Uint8Array(2048),qn=0,eo=!0;var Po=o.partialBoundaries;for(g=0;g<Po.length;g++){e:{Gt=o,rn=l;var or=Po[g];ml=or.byteSize;var _o=or.completedSegments;for(Kn=0;Kn<_o.length;Kn++)if(!Hi(Gt,rn,or,_o[Kn])){Kn++,_o.splice(0,Kn);var Gl=!1;break e}_o.splice(0,Kn);var rr=or.row;rr!==null&&rr.together&&or.pendingTasks===1&&(rr.pendingTasks===1?ql(Gt,rr,rr.hoistables):rr.pendingTasks--),Gl=sn(rn,or.contentState,Gt.renderState)}if(!Gl){o.destination=null,g++,Po.splice(0,g);return}}Po.splice(0,g),eo=!1;var Mn=o.completedBoundaries;for(g=0;g<Mn.length;g++)if(!ri(o,l,Mn[g])){o.destination=null,g++,Mn.splice(0,g);return}Mn.splice(0,g)}}finally{eo=!1,o.allPendingTasks===0&&o.clientRenderedBoundaries.length===0&&o.completedBoundaries.length===0?(o.flushScheduled=!1,g=o.resumableState,g.hasBody&&T(l,vn("body")),g.hasHtml&&T(l,vn("html")),U(l),o.abortableTasks.size!==0&&console.error("There was still abortable task at the root when we closed. This is a bug in React."),o.status=Io,l.close(),o.destination=null):U(l)}}function dr(o){o.flushScheduled=o.destination!==null,Os(function(){return os(o)}),A(function(){o.status===10&&(o.status=11),o.trackedPostpones===null&&ji(o,o.pendingRootTasks===0)})}function Jo(o){o.flushScheduled===!1&&o.pingedTasks.length===0&&o.destination!==null&&(o.flushScheduled=!0,A(function(){var l=o.destination;l?ur(o,l):o.flushScheduled=!1}))}function hr(o,l){if(o.status===13)o.status=Io,$(l,o.fatalError);else if(o.status!==Io&&o.destination===null){o.destination=l;try{ur(o,l)}catch(g){l={},An(o,g,l,null),sl(o,g,l,null)}}}function Ut(o,l){(o.status===11||o.status===10)&&(o.status=12);try{var g=o.abortableTasks;if(0<g.size){var E=l===void 0?Error("The render was aborted by the server without a reason."):typeof l=="object"&&l!==null&&typeof l.then=="function"?Error("The render was aborted by the server with a promise."):l;o.fatalError=E,g.forEach(function(I){var F=a,G=ct.getCurrentStack;a=I,ct.getCurrentStack=ll;try{ni(I,o,E)}finally{a=F,ct.getCurrentStack=G}}),g.clear()}o.destination!==null&&ur(o,o.destination)}catch(I){l={},An(o,I,l,null),sl(o,I,l,null)}}function fr(o,l,g){if(l===null)g.rootNodes.push(o);else{var E=g.workingMap,I=E.get(l);I===void 0&&(I=[l[1],l[2],[],null],E.set(l,I),fr(I,l[0],g)),I[2].push(o)}}function $t(o){var l=o.trackedPostpones;if(l===null||l.rootNodes.length===0&&l.rootSlots===null)return o.trackedPostpones=null;if(o.completedRootSegment===null||o.completedRootSegment.status!==st&&o.completedPreambleSegments!==null){var g=o.nextSegmentId,E=l.rootSlots,I=o.resumableState;I.bootstrapScriptContent=void 0,I.bootstrapScripts=void 0,I.bootstrapModules=void 0}else{g=0,E=-1,I=o.resumableState;var F=o.renderState;I.nextFormID=0,I.hasBody=!1,I.hasHtml=!1,I.unknownResources={font:F.resets.font},I.dnsResources=F.resets.dns,I.connectResources=F.resets.connect,I.imageResources=F.resets.image,I.styleResources=F.resets.style,I.scriptResources={},I.moduleUnknownResources={},I.moduleScriptResources={},I.instructions=un}return{nextSegmentId:g,rootFormatContext:o.rootFormatContext,progressiveChunkSize:o.progressiveChunkSize,resumableState:o.resumableState,replayNodes:l.rootNodes,replaySlots:E}}function Gr(){var o=Ui.version;if(o!=="19.2.0")throw Error(`Incompatible React versions: The "react" and "react-dom" packages must have the exact same version. Instead got:
203
+ - react: `+(o+`
204
+ - react-dom: 19.2.0
205
+ Learn more: https://react.dev/warnings/version-mismatch`))}var Ui=React,zi=require$$1,Wi=Symbol.for("react.transitional.element"),li=Symbol.for("react.portal"),_l=Symbol.for("react.fragment"),si=Symbol.for("react.strict_mode"),ai=Symbol.for("react.profiler"),zo=Symbol.for("react.consumer"),en=Symbol.for("react.context"),wt=Symbol.for("react.forward_ref"),rs=Symbol.for("react.suspense"),Fs=Symbol.for("react.suspense_list"),Ms=Symbol.for("react.memo"),ls=Symbol.for("react.lazy"),Bc=Symbol.for("react.scope"),Qn=Symbol.for("react.activity"),Ru=Symbol.for("react.legacy_hidden"),Vr=Symbol.for("react.memo_cache_sentinel"),ru=Symbol.for("react.view_transition"),Pc=Symbol.iterator,cl=Array.isArray,ii=new WeakMap,ro=new WeakMap,Nl=Symbol.for("react.client.reference"),lu=new MessageChannel,Ds=[];lu.port1.onmessage=function(){var o=Ds.shift();o&&o()};var Gi=Promise,Os=typeof queueMicrotask=="function"?queueMicrotask:function(o){Gi.resolve(null).then(o).catch(L)},lo=null,qn=0,ss=new TextEncoder,Zt=Object.assign,Mt=Object.prototype.hasOwnProperty,js=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Ra={},Vi={},Ea=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" ")),_c=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Eu={button:!0,checkbox:!0,image:!0,hidden:!0,radio:!0,reset:!0,submit:!0},an={"aria-current":0,"aria-description":0,"aria-details":0,"aria-disabled":0,"aria-hidden":0,"aria-invalid":0,"aria-keyshortcuts":0,"aria-label":0,"aria-roledescription":0,"aria-autocomplete":0,"aria-checked":0,"aria-expanded":0,"aria-haspopup":0,"aria-level":0,"aria-modal":0,"aria-multiline":0,"aria-multiselectable":0,"aria-orientation":0,"aria-placeholder":0,"aria-pressed":0,"aria-readonly":0,"aria-required":0,"aria-selected":0,"aria-sort":0,"aria-valuemax":0,"aria-valuemin":0,"aria-valuenow":0,"aria-valuetext":0,"aria-atomic":0,"aria-busy":0,"aria-live":0,"aria-relevant":0,"aria-dropeffect":0,"aria-grabbed":0,"aria-activedescendant":0,"aria-colcount":0,"aria-colindex":0,"aria-colspan":0,"aria-controls":0,"aria-describedby":0,"aria-errormessage":0,"aria-flowto":0,"aria-labelledby":0,"aria-owns":0,"aria-posinset":0,"aria-rowcount":0,"aria-rowindex":0,"aria-rowspan":0,"aria-setsize":0,"aria-braillelabel":0,"aria-brailleroledescription":0,"aria-colindextext":0,"aria-rowindextext":0},Ll={},su=RegExp("^(aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),u=RegExp("^(aria)[A-Z][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),f=!1,v={accept:"accept",acceptcharset:"acceptCharset","accept-charset":"acceptCharset",accesskey:"accessKey",action:"action",allowfullscreen:"allowFullScreen",alt:"alt",as:"as",async:"async",autocapitalize:"autoCapitalize",autocomplete:"autoComplete",autocorrect:"autoCorrect",autofocus:"autoFocus",autoplay:"autoPlay",autosave:"autoSave",capture:"capture",cellpadding:"cellPadding",cellspacing:"cellSpacing",challenge:"challenge",charset:"charSet",checked:"checked",children:"children",cite:"cite",class:"className",classid:"classID",classname:"className",cols:"cols",colspan:"colSpan",content:"content",contenteditable:"contentEditable",contextmenu:"contextMenu",controls:"controls",controlslist:"controlsList",coords:"coords",crossorigin:"crossOrigin",dangerouslysetinnerhtml:"dangerouslySetInnerHTML",data:"data",datetime:"dateTime",default:"default",defaultchecked:"defaultChecked",defaultvalue:"defaultValue",defer:"defer",dir:"dir",disabled:"disabled",disablepictureinpicture:"disablePictureInPicture",disableremoteplayback:"disableRemotePlayback",download:"download",draggable:"draggable",enctype:"encType",enterkeyhint:"enterKeyHint",fetchpriority:"fetchPriority",for:"htmlFor",form:"form",formmethod:"formMethod",formaction:"formAction",formenctype:"formEncType",formnovalidate:"formNoValidate",formtarget:"formTarget",frameborder:"frameBorder",headers:"headers",height:"height",hidden:"hidden",high:"high",href:"href",hreflang:"hrefLang",htmlfor:"htmlFor",httpequiv:"httpEquiv","http-equiv":"httpEquiv",icon:"icon",id:"id",imagesizes:"imageSizes",imagesrcset:"imageSrcSet",inert:"inert",innerhtml:"innerHTML",inputmode:"inputMode",integrity:"integrity",is:"is",itemid:"itemID",itemprop:"itemProp",itemref:"itemRef",itemscope:"itemScope",itemtype:"itemType",keyparams:"keyParams",keytype:"keyType",kind:"kind",label:"label",lang:"lang",list:"list",loop:"loop",low:"low",manifest:"manifest",marginwidth:"marginWidth",marginheight:"marginHeight",max:"max",maxlength:"maxLength",media:"media",mediagroup:"mediaGroup",method:"method",min:"min",minlength:"minLength",multiple:"multiple",muted:"muted",name:"name",nomodule:"noModule",nonce:"nonce",novalidate:"noValidate",open:"open",optimum:"optimum",pattern:"pattern",placeholder:"placeholder",playsinline:"playsInline",poster:"poster",preload:"preload",profile:"profile",radiogroup:"radioGroup",readonly:"readOnly",referrerpolicy:"referrerPolicy",rel:"rel",required:"required",reversed:"reversed",role:"role",rows:"rows",rowspan:"rowSpan",sandbox:"sandbox",scope:"scope",scoped:"scoped",scrolling:"scrolling",seamless:"seamless",selected:"selected",shape:"shape",size:"size",sizes:"sizes",span:"span",spellcheck:"spellCheck",src:"src",srcdoc:"srcDoc",srclang:"srcLang",srcset:"srcSet",start:"start",step:"step",style:"style",summary:"summary",tabindex:"tabIndex",target:"target",title:"title",type:"type",usemap:"useMap",value:"value",width:"width",wmode:"wmode",wrap:"wrap",about:"about",accentheight:"accentHeight","accent-height":"accentHeight",accumulate:"accumulate",additive:"additive",alignmentbaseline:"alignmentBaseline","alignment-baseline":"alignmentBaseline",allowreorder:"allowReorder",alphabetic:"alphabetic",amplitude:"amplitude",arabicform:"arabicForm","arabic-form":"arabicForm",ascent:"ascent",attributename:"attributeName",attributetype:"attributeType",autoreverse:"autoReverse",azimuth:"azimuth",basefrequency:"baseFrequency",baselineshift:"baselineShift","baseline-shift":"baselineShift",baseprofile:"baseProfile",bbox:"bbox",begin:"begin",bias:"bias",by:"by",calcmode:"calcMode",capheight:"capHeight","cap-height":"capHeight",clip:"clip",clippath:"clipPath","clip-path":"clipPath",clippathunits:"clipPathUnits",cliprule:"clipRule","clip-rule":"clipRule",color:"color",colorinterpolation:"colorInterpolation","color-interpolation":"colorInterpolation",colorinterpolationfilters:"colorInterpolationFilters","color-interpolation-filters":"colorInterpolationFilters",colorprofile:"colorProfile","color-profile":"colorProfile",colorrendering:"colorRendering","color-rendering":"colorRendering",contentscripttype:"contentScriptType",contentstyletype:"contentStyleType",cursor:"cursor",cx:"cx",cy:"cy",d:"d",datatype:"datatype",decelerate:"decelerate",descent:"descent",diffuseconstant:"diffuseConstant",direction:"direction",display:"display",divisor:"divisor",dominantbaseline:"dominantBaseline","dominant-baseline":"dominantBaseline",dur:"dur",dx:"dx",dy:"dy",edgemode:"edgeMode",elevation:"elevation",enablebackground:"enableBackground","enable-background":"enableBackground",end:"end",exponent:"exponent",externalresourcesrequired:"externalResourcesRequired",fill:"fill",fillopacity:"fillOpacity","fill-opacity":"fillOpacity",fillrule:"fillRule","fill-rule":"fillRule",filter:"filter",filterres:"filterRes",filterunits:"filterUnits",floodopacity:"floodOpacity","flood-opacity":"floodOpacity",floodcolor:"floodColor","flood-color":"floodColor",focusable:"focusable",fontfamily:"fontFamily","font-family":"fontFamily",fontsize:"fontSize","font-size":"fontSize",fontsizeadjust:"fontSizeAdjust","font-size-adjust":"fontSizeAdjust",fontstretch:"fontStretch","font-stretch":"fontStretch",fontstyle:"fontStyle","font-style":"fontStyle",fontvariant:"fontVariant","font-variant":"fontVariant",fontweight:"fontWeight","font-weight":"fontWeight",format:"format",from:"from",fx:"fx",fy:"fy",g1:"g1",g2:"g2",glyphname:"glyphName","glyph-name":"glyphName",glyphorientationhorizontal:"glyphOrientationHorizontal","glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphorientationvertical:"glyphOrientationVertical","glyph-orientation-vertical":"glyphOrientationVertical",glyphref:"glyphRef",gradienttransform:"gradientTransform",gradientunits:"gradientUnits",hanging:"hanging",horizadvx:"horizAdvX","horiz-adv-x":"horizAdvX",horizoriginx:"horizOriginX","horiz-origin-x":"horizOriginX",ideographic:"ideographic",imagerendering:"imageRendering","image-rendering":"imageRendering",in2:"in2",in:"in",inlist:"inlist",intercept:"intercept",k1:"k1",k2:"k2",k3:"k3",k4:"k4",k:"k",kernelmatrix:"kernelMatrix",kernelunitlength:"kernelUnitLength",kerning:"kerning",keypoints:"keyPoints",keysplines:"keySplines",keytimes:"keyTimes",lengthadjust:"lengthAdjust",letterspacing:"letterSpacing","letter-spacing":"letterSpacing",lightingcolor:"lightingColor","lighting-color":"lightingColor",limitingconeangle:"limitingConeAngle",local:"local",markerend:"markerEnd","marker-end":"markerEnd",markerheight:"markerHeight",markermid:"markerMid","marker-mid":"markerMid",markerstart:"markerStart","marker-start":"markerStart",markerunits:"markerUnits",markerwidth:"markerWidth",mask:"mask",maskcontentunits:"maskContentUnits",maskunits:"maskUnits",mathematical:"mathematical",mode:"mode",numoctaves:"numOctaves",offset:"offset",opacity:"opacity",operator:"operator",order:"order",orient:"orient",orientation:"orientation",origin:"origin",overflow:"overflow",overlineposition:"overlinePosition","overline-position":"overlinePosition",overlinethickness:"overlineThickness","overline-thickness":"overlineThickness",paintorder:"paintOrder","paint-order":"paintOrder",panose1:"panose1","panose-1":"panose1",pathlength:"pathLength",patterncontentunits:"patternContentUnits",patterntransform:"patternTransform",patternunits:"patternUnits",pointerevents:"pointerEvents","pointer-events":"pointerEvents",points:"points",pointsatx:"pointsAtX",pointsaty:"pointsAtY",pointsatz:"pointsAtZ",popover:"popover",popovertarget:"popoverTarget",popovertargetaction:"popoverTargetAction",prefix:"prefix",preservealpha:"preserveAlpha",preserveaspectratio:"preserveAspectRatio",primitiveunits:"primitiveUnits",property:"property",r:"r",radius:"radius",refx:"refX",refy:"refY",renderingintent:"renderingIntent","rendering-intent":"renderingIntent",repeatcount:"repeatCount",repeatdur:"repeatDur",requiredextensions:"requiredExtensions",requiredfeatures:"requiredFeatures",resource:"resource",restart:"restart",result:"result",results:"results",rotate:"rotate",rx:"rx",ry:"ry",scale:"scale",security:"security",seed:"seed",shaperendering:"shapeRendering","shape-rendering":"shapeRendering",slope:"slope",spacing:"spacing",specularconstant:"specularConstant",specularexponent:"specularExponent",speed:"speed",spreadmethod:"spreadMethod",startoffset:"startOffset",stddeviation:"stdDeviation",stemh:"stemh",stemv:"stemv",stitchtiles:"stitchTiles",stopcolor:"stopColor","stop-color":"stopColor",stopopacity:"stopOpacity","stop-opacity":"stopOpacity",strikethroughposition:"strikethroughPosition","strikethrough-position":"strikethroughPosition",strikethroughthickness:"strikethroughThickness","strikethrough-thickness":"strikethroughThickness",string:"string",stroke:"stroke",strokedasharray:"strokeDasharray","stroke-dasharray":"strokeDasharray",strokedashoffset:"strokeDashoffset","stroke-dashoffset":"strokeDashoffset",strokelinecap:"strokeLinecap","stroke-linecap":"strokeLinecap",strokelinejoin:"strokeLinejoin","stroke-linejoin":"strokeLinejoin",strokemiterlimit:"strokeMiterlimit","stroke-miterlimit":"strokeMiterlimit",strokewidth:"strokeWidth","stroke-width":"strokeWidth",strokeopacity:"strokeOpacity","stroke-opacity":"strokeOpacity",suppresscontenteditablewarning:"suppressContentEditableWarning",suppresshydrationwarning:"suppressHydrationWarning",surfacescale:"surfaceScale",systemlanguage:"systemLanguage",tablevalues:"tableValues",targetx:"targetX",targety:"targetY",textanchor:"textAnchor","text-anchor":"textAnchor",textdecoration:"textDecoration","text-decoration":"textDecoration",textlength:"textLength",textrendering:"textRendering","text-rendering":"textRendering",to:"to",transform:"transform",transformorigin:"transformOrigin","transform-origin":"transformOrigin",typeof:"typeof",u1:"u1",u2:"u2",underlineposition:"underlinePosition","underline-position":"underlinePosition",underlinethickness:"underlineThickness","underline-thickness":"underlineThickness",unicode:"unicode",unicodebidi:"unicodeBidi","unicode-bidi":"unicodeBidi",unicoderange:"unicodeRange","unicode-range":"unicodeRange",unitsperem:"unitsPerEm","units-per-em":"unitsPerEm",unselectable:"unselectable",valphabetic:"vAlphabetic","v-alphabetic":"vAlphabetic",values:"values",vectoreffect:"vectorEffect","vector-effect":"vectorEffect",version:"version",vertadvy:"vertAdvY","vert-adv-y":"vertAdvY",vertoriginx:"vertOriginX","vert-origin-x":"vertOriginX",vertoriginy:"vertOriginY","vert-origin-y":"vertOriginY",vhanging:"vHanging","v-hanging":"vHanging",videographic:"vIdeographic","v-ideographic":"vIdeographic",viewbox:"viewBox",viewtarget:"viewTarget",visibility:"visibility",vmathematical:"vMathematical","v-mathematical":"vMathematical",vocab:"vocab",widths:"widths",wordspacing:"wordSpacing","word-spacing":"wordSpacing",writingmode:"writingMode","writing-mode":"writingMode",x1:"x1",x2:"x2",x:"x",xchannelselector:"xChannelSelector",xheight:"xHeight","x-height":"xHeight",xlinkactuate:"xlinkActuate","xlink:actuate":"xlinkActuate",xlinkarcrole:"xlinkArcrole","xlink:arcrole":"xlinkArcrole",xlinkhref:"xlinkHref","xlink:href":"xlinkHref",xlinkrole:"xlinkRole","xlink:role":"xlinkRole",xlinkshow:"xlinkShow","xlink:show":"xlinkShow",xlinktitle:"xlinkTitle","xlink:title":"xlinkTitle",xlinktype:"xlinkType","xlink:type":"xlinkType",xmlbase:"xmlBase","xml:base":"xmlBase",xmllang:"xmlLang","xml:lang":"xmlLang",xmlns:"xmlns","xml:space":"xmlSpace",xmlnsxlink:"xmlnsXlink","xmlns:xlink":"xmlnsXlink",xmlspace:"xmlSpace",y1:"y1",y2:"y2",y:"y",ychannelselector:"yChannelSelector",z:"z",zoomandpan:"zoomAndPan"},w={},N=/^on./,z=/^on[^A-Z]/,V=RegExp("^(aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),ge=RegExp("^(aria)[A-Z][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),J=/^(?:webkit|moz|o)[A-Z]/,ce=/^-ms-/,we=/-(.)/g,ve=/;\s*$/,Le={},Ge={},at=!1,Qe=!1,Xe=/["'&<>]/,tt=/([A-Z])/g,Je=/^ms-/,tn=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i,ct=Ui.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,mt=zi.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Bt=Object.freeze({pending:!1,data:null,method:null,action:null}),lt=mt.d;mt.d={f:lt.f,r:lt.r,D:function(o){var l=jt||null;if(l){var g=l.resumableState,E=l.renderState;if(typeof o=="string"&&o){if(!g.dnsResources.hasOwnProperty(o)){g.dnsResources[o]=Tt,g=E.headers;var I,F;(F=g&&0<g.remainingCapacity)&&(F=(I="<"+Ts(o)+">; rel=dns-prefetch",0<=(g.remainingCapacity-=I.length+2))),F?(E.resets.dns[o]=Tt,g.preconnects&&(g.preconnects+=", "),g.preconnects+=I):(I=[],Do(I,{href:o,rel:"dns-prefetch"}),E.preconnects.add(I))}Jo(l)}}else lt.D(o)},C:function(o,l){var g=jt||null;if(g){var E=g.resumableState,I=g.renderState;if(typeof o=="string"&&o){var F=l==="use-credentials"?"credentials":typeof l=="string"?"anonymous":"default";if(!E.connectResources[F].hasOwnProperty(o)){E.connectResources[F][o]=Tt,E=I.headers;var G,Z;if(Z=E&&0<E.remainingCapacity){if(Z="<"+Ts(o)+">; rel=preconnect",typeof l=="string"){var pe=Ko(l,"crossOrigin");Z+='; crossorigin="'+pe+'"'}Z=(G=Z,0<=(E.remainingCapacity-=G.length+2))}Z?(I.resets.connect[F][o]=Tt,E.preconnects&&(E.preconnects+=", "),E.preconnects+=G):(F=[],Do(F,{rel:"preconnect",href:o,crossOrigin:l}),I.preconnects.add(F))}Jo(g)}}else lt.C(o,l)},L:function(o,l,g){var E=jt||null;if(E){var I=E.resumableState,F=E.renderState;if(l&&o){switch(l){case"image":if(g)var G=g.imageSrcSet,Z=g.imageSizes,pe=g.fetchPriority;var te=G?G+`
206
+ `+(Z||""):o;if(I.imageResources.hasOwnProperty(te))return;I.imageResources[te]=Yn,I=F.headers;var se;I&&0<I.remainingCapacity&&typeof G!="string"&&pe==="high"&&(se=Jl(o,l,g),0<=(I.remainingCapacity-=se.length+2))?(F.resets.image[te]=Yn,I.highImagePreloads&&(I.highImagePreloads+=", "),I.highImagePreloads+=se):(I=[],Do(I,Zt({rel:"preload",href:G?void 0:o,as:l},g)),pe==="high"?F.highImagePreloads.add(I):(F.bulkPreloads.add(I),F.preloads.images.set(te,I)));break;case"style":if(I.styleResources.hasOwnProperty(o))return;G=[],Do(G,Zt({rel:"preload",href:o,as:l},g)),I.styleResources[o]=!g||typeof g.crossOrigin!="string"&&typeof g.integrity!="string"?Yn:[g.crossOrigin,g.integrity],F.preloads.stylesheets.set(o,G),F.bulkPreloads.add(G);break;case"script":if(I.scriptResources.hasOwnProperty(o))return;G=[],F.preloads.scripts.set(o,G),F.bulkPreloads.add(G),Do(G,Zt({rel:"preload",href:o,as:l},g)),I.scriptResources[o]=!g||typeof g.crossOrigin!="string"&&typeof g.integrity!="string"?Yn:[g.crossOrigin,g.integrity];break;default:if(I.unknownResources.hasOwnProperty(l)){if(G=I.unknownResources[l],G.hasOwnProperty(o))return}else G={},I.unknownResources[l]=G;if(G[o]=Yn,(I=F.headers)&&0<I.remainingCapacity&&l==="font"&&(te=Jl(o,l,g),0<=(I.remainingCapacity-=te.length+2)))F.resets.font[o]=Yn,I.fontPreloads&&(I.fontPreloads+=", "),I.fontPreloads+=te;else switch(I=[],o=Zt({rel:"preload",href:o,as:l},g),Do(I,o),l){case"font":F.fontPreloads.add(I);break;default:F.bulkPreloads.add(I)}}Jo(E)}}else lt.L(o,l,g)},m:function(o,l){var g=jt||null;if(g){var E=g.resumableState,I=g.renderState;if(o){var F=l&&typeof l.as=="string"?l.as:"script";switch(F){case"script":if(E.moduleScriptResources.hasOwnProperty(o))return;F=[],E.moduleScriptResources[o]=!l||typeof l.crossOrigin!="string"&&typeof l.integrity!="string"?Yn:[l.crossOrigin,l.integrity],I.preloads.moduleScripts.set(o,F);break;default:if(E.moduleUnknownResources.hasOwnProperty(F)){var G=E.unknownResources[F];if(G.hasOwnProperty(o))return}else G={},E.moduleUnknownResources[F]=G;F=[],G[o]=Yn}Do(F,Zt({rel:"modulepreload",href:o},l)),I.bulkPreloads.add(F),Jo(g)}}else lt.m(o,l)},X:function(o,l){var g=jt||null;if(g){var E=g.resumableState,I=g.renderState;if(o){var F=E.scriptResources.hasOwnProperty(o)?E.scriptResources[o]:void 0;F!==Tt&&(E.scriptResources[o]=Tt,l=Zt({src:o,async:!0},l),F&&(F.length===2&&Kl(l,F),o=I.preloads.scripts.get(o))&&(o.length=0),o=[],I.scripts.add(o),_i(o,l),Jo(g))}}else lt.X(o,l)},S:function(o,l,g){var E=jt||null;if(E){var I=E.resumableState,F=E.renderState;if(o){l=l||"default";var G=F.styles.get(l),Z=I.styleResources.hasOwnProperty(o)?I.styleResources[o]:void 0;Z!==Tt&&(I.styleResources[o]=Tt,G||(G={precedence:M(Pe(l)),rules:[],hrefs:[],sheets:new Map},F.styles.set(l,G)),l={state:xs,props:Zt({rel:"stylesheet",href:o,"data-precedence":l},g)},Z&&(Z.length===2&&Kl(l.props,Z),(F=F.preloads.stylesheets.get(o))&&0<F.length?F.length=0:l.state=rc),G.sheets.set(o,l),Jo(E))}}else lt.S(o,l,g)},M:function(o,l){var g=jt||null;if(g){var E=g.resumableState,I=g.renderState;if(o){var F=E.moduleScriptResources.hasOwnProperty(o)?E.moduleScriptResources[o]:void 0;F!==Tt&&(E.moduleScriptResources[o]=Tt,l=Zt({src:o,type:"module",async:!0},l),F&&(F.length===2&&Kl(l,F),o=I.preloads.moduleScripts.get(o))&&(o.length=0),o=[],I.scripts.add(o),_i(o,l),Jo(g))}}else lt.M(o,l)}};var un=0,Ct=1,bo=2,Nt=4,yt=8,St=32,nt=64,Tt=null,Yn=[];Object.freeze(Yn);var dt=null;D('"></template>');var as=D("<script"),Fl=D("<\/script>"),yo=D('<script src="'),vr=D('<script type="module" src="'),Rr=D(' nonce="'),Er=D(' integrity="'),ul=D(' crossorigin="'),Ml=D(' async=""><\/script>'),Un=D("<style"),Hs=/(<\/|<)(s)(cript)/gi,Us=D('<script type="importmap">'),ci=D("<\/script>"),Yi={},ka=0,is=1,vo=2,ui=3,Ro=4,gr=5,Dl=6,di=7,Ol=8,Xi=9,Pn=D("<!-- -->"),hi=new Map,cs=D(' style="'),wa=D(":"),zs=D(";"),Rn=D(" "),pr=D('="'),ut=D('"'),jl=D('=""'),Ca=D(Pe("javascript:throw new Error('React form unexpectedly submitted.')")),us=D('<input type="hidden"'),dn=D(">"),Wo=D("/>"),ds=!1,Ws=!1,kr=!1,so=!1,Sa=!1,Eo=!1,Nc=!1,Gs=!1,fi=!1,Zi=!1,Ki=!1,dl=D(' selected=""'),Vs=D(`addEventListener("submit",function(a){if(!a.defaultPrevented){var c=a.target,d=a.submitter,e=c.action,b=d;if(d){var f=d.getAttribute("formAction");null!=f&&(e=f,b=null)}"javascript:throw new Error('React form unexpectedly submitted.')"===e&&(a.preventDefault(),b?(a=document.createElement("input"),a.name=b.name,a.value=b.value,b.parentNode.insertBefore(a,b),b=new FormData(c),a.parentNode.removeChild(a)):b=new FormData(c),a=c.ownerDocument||c,(a.$$reactFormReplay=a.$$reactFormReplay||[]).push(c,d,b))}});`),Ys=D("<!--F!-->"),ko=D("<!--F-->"),gi=/(<\/|<)(s)(tyle)/gi,pi=D("<!--head-->"),Lc=D("<!--body-->"),Fc=D("<!--html-->"),Ji=D(`
207
+ `),Mc=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,Dc=new Map,_n=D("<!DOCTYPE html>"),Qi=new Map,xi=D("requestAnimationFrame(function(){$RT=performance.now()});"),mi=D('<template id="'),qi=D('"></template>'),Oc=D("<!--&-->"),$i=D("<!--/&-->"),ec=D("<!--$-->"),hs=D('<!--$?--><template id="'),wr=D('"></template>'),au=D("<!--$!-->"),Xs=D("<!--/$-->"),bi=D("<template"),Yr=D('"'),Ta=D(' data-dgst="'),fs=D(' data-msg="'),yi=D(' data-stck="'),gs=D(' data-cstck="'),iu=D("></template>"),cu=D('<div hidden id="'),Xr=D('">'),Aa=D("</div>"),xr=D('<svg aria-hidden="true" style="display:none" id="'),ps=D('">'),Zs=D("</svg>"),Cr=D('<math aria-hidden="true" style="display:none" id="'),jc=D('">'),uu=D("</math>"),Ia=D('<table hidden id="'),i=D('">'),h=D("</table>"),m=D('<table hidden><tbody id="'),C=D('">'),P=D("</tbody></table>"),H=D('<table hidden><tr id="'),W=D('">'),ne=D("</tr></table>"),X=D('<table hidden><colgroup id="'),oe=D('">'),fe=D("</colgroup></table>"),me=D('$RS=function(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("'),De=D('$RS("'),Me=D('","'),pt=D('")<\/script>');D('<template data-rsi="" data-sid="'),D('" data-pid="');var qe=D(`$RB=[];$RV=function(a){$RT=performance.now();for(var b=0;b<a.length;b+=2){var c=a[b],e=a[b+1];null!==e.parentNode&&e.parentNode.removeChild(e);var f=c.parentNode;if(f){var g=c.previousSibling,h=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d||"/&"===d)if(0===h)break;else h--;else"$"!==d&&"$?"!==d&&"$~"!==d&&"$!"!==d&&"&"!==d||h++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;e.firstChild;)f.insertBefore(e.firstChild,c);g.data="$";g._reactRetry&&requestAnimationFrame(g._reactRetry)}}a.length=0};
208
+ $RC=function(a,b){if(b=document.getElementById(b))(a=document.getElementById(a))?(a.previousSibling.data="$~",$RB.push(a,b),2===$RB.length&&("number"!==typeof $RT?requestAnimationFrame($RV.bind(null,$RB)):(a=performance.now(),setTimeout($RV.bind(null,$RB),2300>a&&2E3<a?2300-a:$RT+300-a)))):b.parentNode.removeChild(b)};`);M(`$RV=function(A,g){function k(a,b){var e=a.getAttribute(b);e&&(b=a.style,l.push(a,b.viewTransitionName,b.viewTransitionClass),"auto"!==e&&(b.viewTransitionClass=e),(a=a.getAttribute("vt-name"))||(a="_T_"+K++ +"_"),b.viewTransitionName=a,B=!0)}var B=!1,K=0,l=[];try{var f=document.__reactViewTransition;if(f){f.finished.finally($RV.bind(null,g));return}var m=new Map;for(f=1;f<g.length;f+=2)for(var h=g[f].querySelectorAll("[vt-share]"),d=0;d<h.length;d++){var c=h[d];m.set(c.getAttribute("vt-name"),c)}var u=[];for(h=0;h<g.length;h+=2){var C=g[h],x=C.parentNode;if(x){var v=x.getBoundingClientRect();if(v.left||v.top||v.width||v.height){c=C;for(f=0;c;){if(8===c.nodeType){var r=c.data;if("/$"===r)if(0===f)break;else f--;else"$"!==r&&"$?"!==r&&"$~"!==r&&"$!"!==r||f++}else if(1===c.nodeType){d=c;var D=d.getAttribute("vt-name"),y=m.get(D);k(d,y?"vt-share":"vt-exit");y&&(k(y,"vt-share"),m.set(D,null));var E=d.querySelectorAll("[vt-share]");for(d=0;d<E.length;d++){var F=E[d],G=F.getAttribute("vt-name"),
209
+ H=m.get(G);H&&(k(F,"vt-share"),k(H,"vt-share"),m.set(G,null))}}c=c.nextSibling}for(var I=g[h+1],t=I.firstElementChild;t;)null!==m.get(t.getAttribute("vt-name"))&&k(t,"vt-enter"),t=t.nextElementSibling;c=x;do for(var n=c.firstElementChild;n;){var J=n.getAttribute("vt-update");J&&"none"!==J&&!l.includes(n)&&k(n,"vt-update");n=n.nextElementSibling}while((c=c.parentNode)&&1===c.nodeType&&"none"!==c.getAttribute("vt-update"));u.push.apply(u,I.querySelectorAll('img[src]:not([loading="lazy"])'))}}}if(B){var z=
210
+ document.__reactViewTransition=document.startViewTransition({update:function(){A(g);for(var a=[document.documentElement.clientHeight,document.fonts.ready],b={},e=0;e<u.length;b={g:b.g},e++)if(b.g=u[e],!b.g.complete){var p=b.g.getBoundingClientRect();0<p.bottom&&0<p.right&&p.top<window.innerHeight&&p.left<window.innerWidth&&(p=new Promise(function(w){return function(q){w.g.addEventListener("load",q);w.g.addEventListener("error",q)}}(b)),a.push(p))}return Promise.race([Promise.all(a),new Promise(function(w){var q=
211
+ performance.now();setTimeout(w,2300>q&&2E3<q?2300-q:500)})])},types:[]});z.ready.finally(function(){for(var a=l.length-3;0<=a;a-=3){var b=l[a],e=b.style;e.viewTransitionName=l[a+1];e.viewTransitionClass=l[a+1];""===b.getAttribute("style")&&b.removeAttribute("style")}});z.finished.finally(function(){document.__reactViewTransition===z&&(document.__reactViewTransition=null)});$RB=[];return}}catch(a){}A(g)}.bind(null,$RV);`);var xt=D('$RC("'),hn=D(`$RM=new Map;$RR=function(n,w,p){function u(q){this._p=null;q()}for(var r=new Map,t=document,h,b,e=t.querySelectorAll("link[data-precedence],style[data-precedence]"),v=[],k=0;b=e[k++];)"not all"===b.getAttribute("media")?v.push(b):("LINK"===b.tagName&&$RM.set(b.getAttribute("href"),b),r.set(b.dataset.precedence,h=b));e=0;b=[];var l,a;for(k=!0;;){if(k){var f=p[e++];if(!f){k=!1;e=0;continue}var c=!1,m=0;var d=f[m++];if(a=$RM.get(d)){var g=a._p;c=!0}else{a=t.createElement("link");a.href=d;a.rel=
212
+ "stylesheet";for(a.dataset.precedence=l=f[m++];g=f[m++];)a.setAttribute(g,f[m++]);g=a._p=new Promise(function(q,x){a.onload=u.bind(a,q);a.onerror=u.bind(a,x)});$RM.set(d,a)}d=a.getAttribute("media");!g||d&&!matchMedia(d).matches||b.push(g);if(c)continue}else{a=v[e++];if(!a)break;l=a.getAttribute("data-precedence");a.removeAttribute("media")}c=r.get(l)||h;c===h&&(h=a);r.set(l,a);c?c.parentNode.insertBefore(a,c.nextSibling):(c=t.head,c.insertBefore(a,c.firstChild))}if(p=document.getElementById(n))p.previousSibling.data=
213
+ "$~";Promise.all(b).then($RC.bind(null,n,w),$RX.bind(null,n,"CSS failed to load"))};$RR("`),Kt=D('$RR("'),ao=D('","'),Qo=D('",'),Sr=D('"'),$e=D(")<\/script>");D('<template data-rci="" data-bid="'),D('<template data-rri="" data-bid="'),D('" data-sid="'),D('" data-sty="');var wo=D('$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};'),En=D('$RX=function(b,c,d,e,f){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),f&&(a.cstck=f),b._reactRetry&&b._reactRetry())};;$RX("'),Go=D('$RX("'),Hl=D('"'),fn=D(","),Ks=D(")<\/script>");D('<template data-rxi="" data-bid="'),D('" data-dgst="'),D('" data-msg="'),D('" data-stck="'),D('" data-cstck="');var Tr=/[<\u2028\u2029]/g,Co=/[&><\u2028\u2029]/g,Zr=D(' media="not all" data-precedence="'),So=D('" data-href="'),Js=D('">'),Ba=D("</style>"),Vo=!1,Pa=!0,To=[],Qs=D(' data-precedence="'),Hc=D('" data-href="'),nn=D(" "),_a=D('">'),Kr=D("</style>");D('<link rel="expect" href="#'),D('" blocking="render"/>');var tc=D(' id="'),qs=D("["),nc=D(",["),oc=D(","),Na=D("]"),xs=0,rc=1,hl=2,$s=3,ea=/[<>\r\n]/g,du=/["';,\r\n]/g,Ar=Function.prototype.bind,hu=Symbol.for("react.client.reference"),mr={};Object.freeze(mr);var ms={},Ul=null,lc={},sc={},ac=new Set,ta=new Set,fu=new Set,Uc=new Set,La=new Set,gu=new Set,ic=new Set,ku=new Set,zc=new Set,wu={enqueueSetState:function(o,l,g){var E=o._reactInternals;E.queue===null?oo(o,"setState"):(E.queue.push(l),g!=null&&Or(g))},enqueueReplaceState:function(o,l,g){o=o._reactInternals,o.replace=!0,o.queue=[l],g!=null&&Or(g)},enqueueForceUpdate:function(o,l){o._reactInternals.queue===null?oo(o,"forceUpdate"):l!=null&&Or(l)}},cc={id:1,overflow:""},Fa=Math.clz32?Math.clz32:Li,Bu=Math.log,Pu=Math.LN2,fl=Error("Suspense Exception: This is not a real error! It's an implementation detail of `use` to interrupt the current render. You must either rethrow it immediately, or move the `use` call outside of the `try/catch` block. Capturing without rethrowing will lead to unexpected behavior.\n\nTo handle async errors, wrap your component in an error boundary, or call the promise's `.catch` method and pass the result to `use`."),pu=null,_u=typeof Object.is=="function"?Object.is:Fi,$n=null,zl=null,Ao=null,bs=null,Ir=null,Lt=null,qo=!1,Wl=!1,Nn=0,vi=0,uc=-1,xu=0,Ma=null,na=null,Ri=0,Jr=!1,oa,Ei={readContext:tu,use:function(o){if(o!==null&&typeof o=="object"){if(typeof o.then=="function")return jn(o);if(o.$$typeof===en)return tu(o)}throw Error("An unsupported type was passed to use(): "+String(o))},useContext:function(o){return oa="useContext",qt(),o._currentValue},useMemo:ha,useReducer:da,useRef:function(o){$n=qt(),Lt=ua();var l=Lt.memoizedState;return l===null?(o={current:o},Object.seal(o),Lt.memoizedState=o):l},useState:function(o){return oa="useState",da(nu,o)},useInsertionEffect:mo,useLayoutEffect:mo,useCallback:function(o,l){return ha(function(){return o},l)},useImperativeHandle:mo,useEffect:mo,useDebugValue:mo,useDeferredValue:function(o,l){return qt(),l!==void 0?l:o},useTransition:function(){return qt(),[!1,Di]},useId:function(){var o=zl.treeContext,l=o.overflow;o=o.id,o=(o&~(1<<32-Fa(o)-1)).toString(32)+l;var g=r;if(g===null)throw Error("Invalid hook call. Hooks can only be called inside of the body of a function component.");return l=Nn++,o="_"+g.idPrefix+"R_"+o,0<l&&(o+="H"+l.toString(32)),o+"_"},useSyncExternalStore:function(o,l,g){if(g===void 0)throw Error("Missing getServerSnapshot, which is required for server-rendered content. Will revert to client rendering.");return g()},useOptimistic:function(o){return qt(),[o,Ja]},useActionState:Qa,useFormState:Qa,useHostTransitionStatus:function(){return qt(),Bt},useMemoCache:function(o){for(var l=Array(o),g=0;g<o;g++)l[g]=Vr;return l},useCacheRefresh:function(){return fa},useEffectEvent:function(){return ol}},r=null,a=null,p={getCacheForType:function(){throw Error("Not implemented.")},cacheSignal:function(){throw Error("Not implemented.")},getOwner:function(){return a===null?null:a.componentStack}},k=0,B,j,Y,Q,ke,re,be;qa.__reactDisabledLog=!0;var Ne,Oe,Fe=!1,Se=new(typeof WeakMap=="function"?WeakMap:Map),ht={react_stack_bottom_frame:function(o,l,g){return o(l,g)}},Yt=ht.react_stack_bottom_frame.bind(ht),Ke={react_stack_bottom_frame:function(o){return o.render()}},At=Ke.react_stack_bottom_frame.bind(Ke),io={react_stack_bottom_frame:function(o){var l=o._init;return l(o._payload)}},co=io.react_stack_bottom_frame.bind(io),Pt=0;if(typeof performance=="object"&&typeof performance.now=="function")var Xn=performance,gl=function(){return Xn.now()};else{var Yo=Date;gl=function(){return Yo.now()}}var Ue=4,Dt=0,Ot=1,zt=2,gn=3,bt=4,st=5,Io=14,jt=null,uo={},on={},$o={},Da={},er=!1,pl=!1,xl=!1,ml=0,eo=!1;Gr(),Gr(),reactDomServer_browser_development.prerender=function(o,l){return new Promise(function(g,E){var I=l?l.onHeaders:void 0,F;I&&(F=function(se){I(new Headers(se))});var G=kn(l?l.identifierPrefix:void 0,l?l.unstable_externalRuntimeSrc:void 0,l?l.bootstrapScriptContent:void 0,l?l.bootstrapScripts:void 0,l?l.bootstrapModules:void 0),Z=Ho(o,G,He(G,void 0,l?l.unstable_externalRuntimeSrc:void 0,l?l.importMap:void 0,F,l?l.maxHeadersLength:void 0),ot(l?l.namespaceURI:void 0),l?l.progressiveChunkSize:void 0,l?l.onError:void 0,function(){var se=new ReadableStream({type:"bytes",pull:function(Te){hr(Z,Te)},cancel:function(Te){Z.destination=null,Ut(Z,Te)}},{highWaterMark:0});se={postponed:$t(Z),prelude:se},g(se)},void 0,void 0,E,l?l.onPostpone:void 0);if(l&&l.signal){var pe=l.signal;if(pe.aborted)Ut(Z,pe.reason);else{var te=function(){Ut(Z,pe.reason),pe.removeEventListener("abort",te)};pe.addEventListener("abort",te)}}dr(Z)})},reactDomServer_browser_development.renderToReadableStream=function(o,l){return new Promise(function(g,E){var I,F,G=new Promise(function(Be,Ce){F=Be,I=Ce}),Z=l?l.onHeaders:void 0,pe;Z&&(pe=function(Be){Z(new Headers(Be))});var te=kn(l?l.identifierPrefix:void 0,l?l.unstable_externalRuntimeSrc:void 0,l?l.bootstrapScriptContent:void 0,l?l.bootstrapScripts:void 0,l?l.bootstrapModules:void 0),se=ga(o,te,He(te,l?l.nonce:void 0,l?l.unstable_externalRuntimeSrc:void 0,l?l.importMap:void 0,pe,l?l.maxHeadersLength:void 0),ot(l?l.namespaceURI:void 0),l?l.progressiveChunkSize:void 0,l?l.onError:void 0,F,function(){var Be=new ReadableStream({type:"bytes",pull:function(Ce){hr(se,Ce)},cancel:function(Ce){se.destination=null,Ut(se,Ce)}},{highWaterMark:0});Be.allReady=G,g(Be)},function(Be){G.catch(function(){}),E(Be)},I,l?l.onPostpone:void 0,l?l.formState:void 0);if(l&&l.signal){var Te=l.signal;if(Te.aborted)Ut(se,Te.reason);else{var _e=function(){Ut(se,Te.reason),Te.removeEventListener("abort",_e)};Te.addEventListener("abort",_e)}}dr(se)})},reactDomServer_browser_development.resume=function(o,l,g){return new Promise(function(E,I){var F,G,Z=new Promise(function(Te,_e){G=Te,F=_e}),pe=Gn(o,l,He(l.resumableState,g?g.nonce:void 0,void 0,void 0,void 0,void 0),g?g.onError:void 0,G,function(){var Te=new ReadableStream({type:"bytes",pull:function(_e){hr(pe,_e)},cancel:function(_e){pe.destination=null,Ut(pe,_e)}},{highWaterMark:0});Te.allReady=Z,E(Te)},function(Te){Z.catch(function(){}),I(Te)},F,g?g.onPostpone:void 0);if(g&&g.signal){var te=g.signal;if(te.aborted)Ut(pe,te.reason);else{var se=function(){Ut(pe,te.reason),te.removeEventListener("abort",se)};te.addEventListener("abort",se)}}dr(pe)})},reactDomServer_browser_development.resumeAndPrerender=function(o,l,g){return new Promise(function(E,I){var F=Xt(o,l,He(l.resumableState,void 0,void 0,void 0,void 0,void 0),g?g.onError:void 0,function(){var pe=new ReadableStream({type:"bytes",pull:function(te){hr(F,te)},cancel:function(te){F.destination=null,Ut(F,te)}},{highWaterMark:0});pe={postponed:$t(F),prelude:pe},E(pe)},void 0,void 0,I,g?g.onPostpone:void 0);if(g&&g.signal){var G=g.signal;if(G.aborted)Ut(F,G.reason);else{var Z=function(){Ut(F,G.reason),G.removeEventListener("abort",Z)};G.addEventListener("abort",Z)}}dr(F)})},reactDomServer_browser_development.version="19.2.0"}()),reactDomServer_browser_development}var hasRequiredServer_browser;function requireServer_browser(){if(hasRequiredServer_browser)return server_browser;hasRequiredServer_browser=1;var n,c;return process.env.NODE_ENV==="production"?(n=requireReactDomServerLegacy_browser_production(),c=requireReactDomServer_browser_production()):(n=requireReactDomServerLegacy_browser_development(),c=requireReactDomServer_browser_development()),server_browser.version=n.version,server_browser.renderToString=n.renderToString,server_browser.renderToStaticMarkup=n.renderToStaticMarkup,server_browser.renderToReadableStream=c.renderToReadableStream,server_browser.resume=c.resume,server_browser}var server_browserExports=requireServer_browser();const ReactDOMServer=plugin.getDefaultExportFromCjs(server_browserExports);function createCoreDragImage(n){const c=document.createElement("div");c.className="absolute -top-[1000px] -left-[1000px] px-2 py-1 bg-white/60 border border-blue-400/30 rounded shadow-md flex items-center gap-1.5 font-sans pointer-events-none z-[9999] scale-90";const d=document.createElement("div");d.className="w-3 h-3 flex items-center justify-center text-blue-600";let x=n.icon||reactIcons.BoxIcon;try{const y=React.createElement(x,{className:"w-3 h-3"}),R=ReactDOMServer.renderToStaticMarkup(y);d.innerHTML=R}catch{d.textContent=""}const b=document.createElement("span");return b.className="text-[10px] font-medium text-blue-600 whitespace-nowrap",b.textContent=n.label||n.type||n._name||n._type||"Block",c.appendChild(d),c.appendChild(b),document.body.appendChild(c),c}function cleanupDragImage(n){n&&n.parentNode&&n.parentNode.removeChild(n)}const useBlockDragStart=()=>{const[,n]=useSelectedBlockIds(),[,c]=useSelectedStylingBlocks(),{clearHighlight:d}=useBlockHighlight(),[,x]=jotai.useAtom(dragAndDropAtom),[,b]=jotai.useAtom(dropIndicatorAtom),y=React.useRef(null);return React.useCallback((R,S,_=!0)=>{var L;y.current&&(cleanupDragImage(y.current),y.current=null);const A=_?lodash.pick(S,["type","blocks"]):S;if(x(A),R.dataTransfer.setData("text/plain",JSON.stringify({block:A})),R.dataTransfer.effectAllowed="move",!_&&S._id){const T=(L=document.getElementById("canvas-iframe"))==null?void 0:L.contentDocument;if(T){const O=T.querySelector(`[data-block-id="${S._id}"]`);O&&(O.style.opacity="0.4",O.setAttribute("data-dragging","true"))}}if(S!=null&&S._type||S!=null&&S.type){const T=createCoreDragImage(S);y.current=T,R.dataTransfer.setDragImage(T,0,0),setTimeout(()=>{y.current&&(cleanupDragImage(y.current),y.current=null)},50)}n([]),d(),c([]),pubsub.publish(CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK),setIsDragging(!0),b({isVisible:!0,isValid:!0,position:"inside",placeholderOrientation:"horizontal",isEmpty:!0,top:0,left:0,width:0,height:0,targetBlockId:"canvas",targetParentId:null})},[n,d,x,b])},useBlockDrop=()=>{const[n,c]=jotai.useAtom(dragAndDropAtom),[d,x]=jotai.useAtom(dropIndicatorAtom),[b]=useBlocksStore(),[y]=useCanvasIframe(),{addCoreBlock:R}=useAddBlock(),{moveBlocks:S}=useBlocksStoreUndoableActions(),[,_]=useSelectedBlockIds(),[,A]=useSelectedStylingBlocks(),{clearHighlight:L}=useBlockHighlight(),{clearParentHighlight:T}=useDragParentHighlight(),O=y==null?void 0:y.contentDocument;return React.useCallback(U=>{if(U.preventDefault(),U.stopPropagation(),setIsDragging(!1),removeDropTargetAttributes(O),T(),x({isVisible:!1,isValid:!1,position:"inside",placeholderOrientation:"horizontal",isEmpty:!1,top:0,left:0,width:0,height:0}),setTimeout(()=>{T(),removeDropTargetAttributes(O),x({isVisible:!1,isValid:!1,position:"inside",placeholderOrientation:"horizontal",isEmpty:!1,top:0,left:0,width:0,height:0})},50),!n)return;if(!d.isValid||!d.targetBlockId){T();return}c(null);const M=d.targetBlockId,D=d.targetParentId;if(!M)return;const{parentId:K,index:$}=calculateInsertionIndex(b,M,D,d.position);if(n._id!==void 0)S([n._id],K===null?void 0:K,$),L(),A([]),_([n._id]);else{const ae=n._type||n.type,Re=n!=null&&n.blocks?lodash.isFunction(n==null?void 0:n.blocks)?runtime.syncBlocksWithDefaults(n==null?void 0:n.blocks()):n==null?void 0:n.blocks:null;R((Re==null?void 0:Re.length)>0?{blocks:[...Re]}:{type:ae},K,$)}},[n,d,b,O,R,S,c,x,T,L,_,A])};function calculateInsertionIndex(n,c,d,x){try{if(c==="canvas"||x==="inside"&&c==="canvas")return{parentId:null,index:lodash.filter(n,L=>!(L!=null&&L._parent)).length};if(x==="inside"){const A=lodash.filter(n,{_parent:c});return{parentId:c,index:A.length}}const b=!d||d==="canvas",y=b?void 0:d,R=lodash.filter(n,A=>b?!(A!=null&&A._parent):(A==null?void 0:A._parent)===y),S=R.findIndex(A=>A._id===c);if(S===-1)return{parentId:b?null:d,index:R.length};const _=x==="before"?S:S+1;return{parentId:b?null:d,index:_}}catch{return{parentId:null,index:lodash.filter(n,R=>!(R!=null&&R._parent)).length}}}function removeDropTargetAttributes(n){if(!n)return;n.querySelectorAll("[data-drop-target]").forEach(d=>d.removeAttribute("data-drop-target"))}const useDragAndDrop=()=>{const n=useBlockDragStart(),c=useBlockDragOver(),d=useBlockDrop(),x=useBlockDragEnd();return{onDragStart:n,onDragOver:c,onDrop:d,onDragEnd:x,isDragging}},useDropIndicator=()=>{const[n]=jotai.useAtom(dropIndicatorAtom);return n},useIsDragAndDropEnabled=()=>{const{dragAndDrop:n}=useBuilderProp("flags",{dragAndDrop:!1});return n};let doc,win;typeof document<"u"&&(doc=document);typeof window<"u"&&(win=window);const FrameContext=React.createContext({document:doc,window:win}),useFrame=()=>React.useContext(FrameContext),{Provider:FrameContextProvider,Consumer:FrameContextConsumer}=FrameContext,CONTROLS=[{ControlIcon:reactIcons.PinTopIcon,dir:"VERTICAL",key:"UP"},{ControlIcon:reactIcons.PinBottomIcon,dir:"VERTICAL",key:"DOWN"},{ControlIcon:reactIcons.PinLeftIcon,dir:"HORIZONTAL",key:"LEFT"},{ControlIcon:reactIcons.PinRightIcon,dir:"HORIZONTAL",key:"RIGHT"}],getParentBlockOrientation=(n,c,d)=>{try{if(!n||!d)return"VERTICAL";const x=`[data-block-id='${n}']`,b=d==null?void 0:d.querySelector(x);if(b){const y=d==null?void 0:d.querySelector(`[data-block-id='${c}']`);return getOrientation(b,y).toUpperCase()}return"VERTICAL"}catch{return"VERTICAL"}},isDisabledControl=(n,c,d)=>!!(n&&(d==="UP"||d==="LEFT")||c&&(d==="DOWN"||d==="RIGHT")),useBlockController=(n,c)=>{const[d]=useBlocksStore(),{document:x}=useFrame(),{moveBlocks:b}=useBlocksStoreUndoableActions(),y=lodashEs.get(n,"_id"),R=lodashEs.get(n,"_parent"),S=lodashEs.filter(d,M=>R?lodashEs.get(M,"_parent")===R:!lodashEs.get(M,"_parent")),_=(S==null?void 0:S.length)<=1,A=lodashEs.findIndex(S,{_id:y}),L=A<=0,T=A+1===(S==null?void 0:S.length),O=getParentBlockOrientation(R,y,x),U=React.useCallback(M=>{isDisabledControl(L,T,M)||_||(M==="UP"||M==="LEFT"?b([y],R||null,A-1):(M==="DOWN"||M==="RIGHT")&&b([y],R||null,A+2),c())},[L,T,_,A,y,R,c]);return reactHotkeysHook.useHotkeys("shift+up, shift+down, shift+left, shift+right",({key:M})=>{var D;U((D=M==null?void 0:M.replace("Arrow",""))==null?void 0:D.toUpperCase())},{document:x==null?void 0:x.contentDocument},[U]),{isOnlyChild:_,isFirstBlock:L,isLastBlock:T,moveBlock:U,orientation:O}},BlockController=({block:n,updateFloatingBar:c})=>{const{isOnlyChild:d,isFirstBlock:x,isLastBlock:b,moveBlock:y,orientation:R}=useBlockController(n,c);return d?null:jsxRuntime.jsx(jsxRuntime.Fragment,{children:CONTROLS.map(({ControlIcon:S,dir:_,key:A})=>R!==_||isDisabledControl(x,b,A)?null:jsxRuntime.jsx(S,{onClick:()=>y(A),className:"rounded p-px hover:bg-white hover:text-blue-500"},A))})},AiIcon=({className:n="h-full w-full",onClick:c=lodashEs.noop})=>jsxRuntime.jsx("svg",{className:n,viewBox:"0 0 256 256",fill:"currentColor",onClick:c,children:jsxRuntime.jsx("path",{d:"m198.39 128.986-52.16-19.216-19.216-52.16a16 16 0 0 0-30.028 0L77.77 109.77l-52.16 19.216a16 16 0 0 0 0 30.028l52.16 19.216 19.216 52.16a16 16 0 0 0 30.028 0l19.216-52.16 52.16-19.216a16 16 0 0 0 0-30.028m-57.69 34.23a15.97 15.97 0 0 0-9.483 9.483l-19.22 52.152-19.214-52.15a15.97 15.97 0 0 0-9.482-9.484l-52.152-19.22 52.15-19.214a15.97 15.97 0 0 0 9.484-9.482l19.22-52.152 19.214 52.15a15.97 15.97 0 0 0 9.482 9.484l52.152 19.22ZM144 40a8 8 0 0 1 8-8h16V16a8 8 0 0 1 16 0v16h16a8 8 0 0 1 0 16h-16v16a8 8 0 0 1-16 0V48h-16a8 8 0 0 1-8-8m104 48a8 8 0 0 1-8 8h-8v8a8 8 0 0 1-16 0v-8h-8a8 8 0 0 1 0-16h8v-8a8 8 0 0 1 16 0v8h8a8 8 0 0 1 8 8"})}),GotoSettingsIcon=({blockId:n,className:c})=>{const d=()=>{n&&pubsub.publish(CHAI_BUILDER_EVENTS.GOTO_BLOCK_SETTINGS,n)};return jsxRuntime.jsx(reactIcons.GearIcon,{className:c,onClick:d})};function getTargetedBlock(n){if(n.getAttribute("data-block-id")==="canvas")return null;if(n.getAttribute("data-block-id")||n.getAttribute("data-block-parent"))return n;const c=n.closest("[data-block-id]");return(c==null?void 0:c.getAttribute("data-block-id"))==="canvas"?null:c}const INLINE_EDITABLE_BLOCKS=["Heading","Paragraph","Text","Link","Span","Button"],isRichTextParent=n=>{var c;return(n==null?void 0:n.getAttribute("data-block-type"))==="RichText"||((c=n==null?void 0:n.parentElement)==null?void 0:c.getAttribute("data-block-type"))==="RichText"},isInlineEditable=(n,c)=>{if(isRichTextParent(n))return!0;const d=n==null?void 0:n.getAttribute("data-block-type");return d?INLINE_EDITABLE_BLOCKS.includes(d):!1},useHandleCanvasDblClick=()=>{const{editingBlockId:n,setEditingBlockId:c,setEditingItemIndex:d}=useInlineEditing();return React.useCallback(x=>{var S;if(x==null||x.preventDefault(),x==null||x.stopPropagation(),n)return;const b=getTargetedBlock(x.target);if(!isInlineEditable(b))return;const y=b.getAttribute("data-block-id");if(!y||!b)return;const R=b.closest('[data-block-type="Repeater"]');R?(S=R==null?void 0:R.childNodes)==null||S.forEach((_,A)=>{_.contains(b)&&d(A)}):d(-1),c(y)},[n,c,d])},useHandleCanvasClick=()=>{const{editingBlockId:n}=useInlineEditing(),{clearHighlight:c}=useBlockHighlight(),d=React.useRef(0);return React.useCallback(x=>{const b=new Date().getTime();if(n||(x.stopPropagation(),b-d.current<400))return;const R=getTargetedBlock(x.target);if(R!=null&&R.getAttribute("data-block-id")&&(R==null?void 0:R.getAttribute("data-block-id"))==="container"){pubsub.publish(CHAI_BUILDER_EVENTS.CLEAR_CANVAS_SELECTION);return}if(R!=null&&R.getAttribute("data-block-parent")){const S=R.getAttribute("data-style-prop"),_=R.getAttribute("data-style-id"),A=R.getAttribute("data-block-parent");pubsub.publish(CHAI_BUILDER_EVENTS.CANVAS_BLOCK_STYLE_SELECTED,{blockId:A,styleId:_,styleProp:S})}else if(R!=null&&R.getAttribute("data-block-id")){const S=R.getAttribute("data-block-id");pubsub.publish(CHAI_BUILDER_EVENTS.CANVAS_BLOCK_SELECTED,S==="canvas"?[]:[S])}c(),d.current=new Date().getTime()},[n])},useHandleMouseMove=()=>{const{editingBlockId:n}=useInlineEditing(),{highlightBlock:c}=useBlockHighlight();return web.useThrottledCallback(d=>{if(n)return;const x=getTargetedBlock(d.target);x&&c(x)},[n,c],100)},useHandleMouseLeave=()=>{const{clearHighlight:n}=useBlockHighlight();return React.useCallback(()=>n(),[n])},Canvas=({children:n})=>{const c=useHandleCanvasDblClick(),d=useHandleCanvasClick(),x=useHandleMouseMove(),b=useHandleMouseLeave();return jsxRuntime.jsx("div",{"data-block-id":"canvas",id:"canvas",onClick:d,onDoubleClick:c,onMouseMove:x,onMouseLeave:b,className:"relative h-full max-w-full p-px",children:n})},getElementByDataBlockId=(n,c)=>n.querySelector(`[data-block-id="${c}"]`),getElementByStyleId=(n,c)=>n.querySelector(`[data-style-id="${c}"]`),BlockSelectionHighlighter=()=>{const n=useSelectedBlock(),{document:c}=useFrame(),[d]=useSelectedStylingBlocks(),[x,b]=React.useState([]),[,y]=React.useState([]),{onDragStart:R,onDragEnd:S,isDragging:_}=useDragAndDrop(),[A,L]=React.useState(null),T=useIsDragAndDropEnabled(),O=(U,M=0)=>{const{top:D}=U.getBoundingClientRect();return D+M>=0&&D-M<=window.innerHeight};return React.useEffect(()=>{var U;if(n!=null&&n._id&&n.type!=="Multiple"&&c){const M=getElementByDataBlockId(c,n._id);M&&(O(M)||(U=c.defaultView)==null||U.scrollTo({top:M.offsetTop,behavior:"smooth"}),b([M]))}},[n==null?void 0:n._id,n==null?void 0:n.type,c]),React.useEffect(()=>{if(!lodashEs.isEmpty(d)&&c){const U=getElementByStyleId(c,lodashEs.first(d).id);y(U?[U]:[null])}else y([null])},[d,c]),jsxRuntime.jsx("div",{onDragEnd:()=>{L(null),S()},draggable:T&&!!n,onDragStart:U=>{L(x==null?void 0:x[0]),R(U,n,!1)},children:jsxRuntime.jsx(BlockFloatingSelector,{block:n,isDragging:_&&!!A,selectedBlockElement:x[0]||(_?A:null)})})},BlockFloatingSelector=({block:n,isDragging:c,selectedBlockElement:d})=>{const x=useRemoveBlocks(),b=useDuplicateBlocks(),[,y]=useSelectedBlockIds(),[,R]=useHighlightBlockId(),[,S]=useSelectedStylingBlocks(),{hasPermission:_}=usePermissions(),{editingBlockId:A}=useInlineEditing(),{document:L}=useFrame(),T=useIsDragAndDropEnabled(),O=useBuilderProp("flags.gotoSettings",!1),{floatingStyles:U,refs:M,update:D}=reactDom.useFloating({placement:"top-start",middleware:[reactDom.shift({boundary:L==null?void 0:L.body,limiter:dom.limitShift({offset:8,mainAxis:!0,crossAxis:!0})}),dom.flip({boundary:L==null?void 0:L.body,fallbackPlacements:["bottom-start","top-end","bottom-end","inside"]}),dom.size({boundary:L==null?void 0:L.body,apply({availableWidth:ae,availableHeight:Re,elements:ye}){Object.assign(ye.floating.style,{maxWidth:`${Math.max(200,ae)}px`,maxHeight:`${Math.max(100,Re)}px`})}})],elements:{reference:d}});web.useResizeObserver(d,()=>D(),d!==null),web.useResizeObserver(L==null?void 0:L.body,()=>D(),(L==null?void 0:L.body)!==null);const K=lodashEs.get(n,"_parent",null),$=lodashEs.isEmpty(lodashEs.get(n,"_name",""))?lodashEs.get(n,"_type",""):lodashEs.get(n,"_name","");React.useEffect(()=>{if(d){const ae=setTimeout(()=>D(),500);return()=>clearTimeout(ae)}else D()},[d]);const[,ee]=useSidebarActivePanel();return!c&&(!d||!n||A)?null:jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsx("div",{role:"button",tabIndex:0,ref:M.setFloating,style:U,onClick:ae=>{ae.stopPropagation(),ae.preventDefault()},onMouseEnter:ae=>{ae.stopPropagation(),R(null)},onKeyDown:ae=>ae.stopPropagation(),className:`isolate z-[999] flex h-6 items-center justify-between bg-blue-500 py-2 text-xs text-white ${c?"opacity-0":""}`,children:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("div",{className:"flex items-center",children:[T&&jsxRuntime.jsx(reactIcons.DragHandleDots2Icon,{className:"flex-shrink-0 cursor-grab rounded p-0.5 hover:bg-white/20 active:cursor-grabbing"}),K&&jsxRuntime.jsx(reactIcons.ArrowUpIcon,{className:"flex-shrink-0 rounded p-0.5 hover:bg-white/20",onClick:()=>{S([]),y([K])}})]}),jsxRuntime.jsx("div",{className:`w-full ${T?"cursor-grab active:cursor-grabbing":""}`,children:jsxRuntime.jsx("div",{className:"mr-10 w-full items-center space-x-1 px-1 leading-tight",children:$})}),jsxRuntime.jsxs("div",{className:"flex items-center gap-1 pl-1 pr-1.5",children:[_(PERMISSIONS.ADD_BLOCK)&&jsxRuntime.jsx(AiIcon,{className:"h-4 w-4 rounded hover:bg-white hover:text-blue-500",onClick:()=>ee("chai-chat-panel")}),O&&jsxRuntime.jsx(GotoSettingsIcon,{blockId:n==null?void 0:n._id,className:"h-4 w-4 rounded p-px hover:bg-white hover:text-blue-500"}),!T&&jsxRuntime.jsx(AddBlockDropdown,{block:n,children:jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-4 w-4 rounded p-px hover:bg-white hover:text-blue-500"})}),canDuplicateBlock(lodashEs.get(n,"_type",""))&&_(PERMISSIONS.ADD_BLOCK)?jsxRuntime.jsx(reactIcons.CopyIcon,{className:"h-4 w-4 rounded p-px hover:bg-white hover:text-blue-500",onClick:()=>b([n==null?void 0:n._id])}):null,canDeleteBlock(lodashEs.get(n,"_type",""))&&_(PERMISSIONS.DELETE_BLOCK)?jsxRuntime.jsx(reactIcons.TrashIcon,{className:"h-4 w-4 rounded p-px hover:bg-white hover:text-blue-500",onClick:()=>x([n==null?void 0:n._id])}):null,_(PERMISSIONS.MOVE_BLOCK)&&jsxRuntime.jsx(BlockController,{block:n,updateFloatingBar:D})]})]})})})},IframeInitialContent=`<!doctype html>
214
+ <html lang="en" dir="__HTML_DIR__" class="scroll-smooth h-full overflow-y-auto">
215
+ <head>
216
+ <meta charset="UTF-8">
217
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
218
+ <script src="https://cdn.tailwindcss.com/3.4.17?plugins=forms@0.5.9,typography@0.5.15,aspect-ratio@0.4.2"><\/script>
219
+ <style>
220
+ html { height: 100%; overflow:auto; }
221
+ body { height: 100%; }
222
+ .air-highlight{ outline: 1px solid #42a1fc !important; outline-offset: -1px;}
223
+ .air-highlight-multi{ outline: 1px solid #29e503 !important; outline-offset: -1px;}
224
+ body{ -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none;
225
+ -moz-user-select: none;-ms-user-select: none; user-select: none; }
226
+ html{
227
+ -ms-overflow-style: none; /* IE and Edge */
228
+ scrollbar-width: none; /* Firefox */
229
+ }
230
+ /** IMPORTANT: Make fields content editable in SAFARI */
231
+ [contenteditable] {-webkit-user-select: text;user-select: text;}
232
+
233
+ html::-webkit-scrollbar { width: 0 !important }
234
+ .aspect-auto{aspect-ratio: auto;}
235
+ .aspect-square{aspect-ratio: 1/1;}
236
+ .aspect-video{aspect-ratio: 16/9;}
237
+ .dragging [data-dnd="leaf"] { pointer-events: none; } .dragging [data-dnd="leaf"] * { pointer-events: none; }
238
+ .dragging [data-dnd="ignore"], .dragging [data-dnd="ignore"] * { pointer-events: none; }
239
+ a{ pointer-events: none !important; }
240
+ [contenteditable="true"], [contenteditable="true"] * { cursor: text !important; }
241
+ [contenteditable="true"] {
242
+ outline: none;
243
+ box-shadow: 0 0 0px 4px rgba(36, 150, 255, 0.2);
244
+ -webkit-user-select: text;
245
+ -moz-user-select: text;
246
+ user-select: text;
247
+ }
248
+ .frame-root .frame-content { height: 100%; }
249
+ [data-drop="yes"] { outline: 2px dashed orange !important; outline-offset: -2px }
250
+ [data-dnd="yes"] { pointer-events: auto !important}
251
+ [data-dnd="no"],[data-block-type="GlobalBlock"],[data-block-type="PartialBlock"] > * { pointer-events: none !important; }
252
+ [data-block-type="GlobalBlock"],[data-block-type="PartialBlock"] { position: relative !important; }
253
+ .partial-overlay { pointer-events: auto !important; }
254
+ [data-dnd-dragged="yes"] { opacity: 0.6; pointer-events: none; }
255
+ [data-dnd-dragged="no"] { opacity: 1; pointer-events: auto !important; }
256
+ [force-show] { display: block !important; }
257
+ [data-cut-block="yes"] { pointer-events: none !important; display: none !important; }
258
+ </style>
259
+ <style id="highlighted-block">
260
+ [data-highlighted]{
261
+ outline: 1px solid #42a1fc !important; outline-offset: -1px;
262
+ }
263
+ </style>
264
+ <style>
265
+ .react-colorful {
266
+ height: 120px !important;
267
+ width: 180px !important;
268
+ }
269
+ .react-colorful > div {
270
+ margin-bottom: 4px;
271
+ }
272
+ .react-colorful__saturation {
273
+ border-radius: 4px !important;
274
+ }
275
+ .react-colorful__hue,
276
+ .react-colorful__alpha {
277
+ height: 12px !important;
278
+ border-radius: 4px !important;
279
+ }
280
+ .react-colorful__pointer {
281
+ width: 16px !important;
282
+ height: 16px !important;
283
+ border: 1.5px solid #fff !important;
284
+ cursor: pointer !important;
285
+ z-index: 10002 !important;
286
+ }
287
+ </style>
288
+ <style type="text/tailwindcss">
289
+ @layer utilities {
290
+ .rte {
291
+ h1 {
292
+ @apply text-2xl;
293
+ }
294
+ h2 {
295
+ @apply text-xl;
296
+ }
297
+ h3 {
298
+ @apply text-lg;
299
+ }
300
+ h4 {
301
+ @apply text-base;
302
+ }
303
+ h5 {
304
+ @apply text-sm;
305
+ }
306
+ h6 {
307
+ @apply text-xs;
308
+ }
309
+ p {
310
+ &:empty {
311
+ @apply h-4;
312
+ }
313
+ }
314
+ ul {
315
+ @apply list-disc pl-6 text-base;
316
+ }
317
+ ol {
318
+ @apply list-decimal pl-6 text-base;
319
+ }
320
+ li > p {
321
+ @apply m-0;
322
+ }
323
+ blockquote {
324
+ @apply pl-4 text-base;
325
+ p {
326
+ @apply pl-4 text-base;
327
+ }
328
+ }
329
+ }
330
+ }
331
+ </style>
332
+ </head>
333
+ <body class="font-body antialiased h-full">
334
+ <div class="frame-root h-full"></div>
335
+ </body>
336
+ </html>`;class Content extends React.Component{componentDidMount(){this.props.contentDidMount()}componentDidUpdate(){this.props.contentDidUpdate()}render(){return React.Children.only(this.props.children)}}class Frame extends React.Component{constructor(d,x){super(d,x);Vu(this,"setRef",d=>{this.nodeRef.current=d;const{forwardedRef:x}=this.props;typeof x=="function"?x(d):x&&(x.current=d)});Vu(this,"handleLoad",()=>{clearInterval(this.loadCheck),this.state.iframeLoaded||this.setState({iframeLoaded:!0})});Vu(this,"loadCheck",()=>setInterval(()=>{this.handleLoad()},500));this._isMounted=!1,this.nodeRef=React.createRef(),this.state={iframeLoaded:!1}}componentDidMount(){this._isMounted=!0,this.getDoc()&&this.nodeRef.current.contentWindow.addEventListener("DOMContentLoaded",this.handleLoad)}componentWillUnmount(){this._isMounted=!1,this.nodeRef.current.removeEventListener("DOMContentLoaded",this.handleLoad)}getDoc(){return this.nodeRef.current?this.nodeRef.current.contentDocument:null}getMountTarget(){const d=this.getDoc();return this.props.mountTarget?d.querySelector(this.props.mountTarget):d.body.children[0]}renderFrameContents(){if(!this._isMounted)return null;const d=this.getDoc();if(!d)return null;const x=this.props.contentDidMount,b=this.props.contentDidUpdate,y=d.defaultView||d.parentView,R=jsxRuntime.jsx(Content,{contentDidMount:x,contentDidUpdate:b,children:jsxRuntime.jsx(FrameContextProvider,{value:{document:d,window:y},children:jsxRuntime.jsx("div",{className:"frame-content",children:this.props.children})})}),S=this.getMountTarget();return[require$$1.createPortal(this.props.head,this.getDoc().head),require$$1.createPortal(R,S)]}render(){const d={...this.props,srcDoc:this.props.initialContent,children:void 0};return delete d.head,delete d.initialContent,delete d.mountTarget,delete d.contentDidMount,delete d.contentDidUpdate,delete d.forwardedRef,jsxRuntime.jsx("iframe",{...d,ref:this.setRef,onLoad:this.handleLoad,children:this.state.iframeLoaded&&this.renderFrameContents()})}}Vu(Frame,"defaultProps",{style:{},head:null,children:void 0,mountTarget:void 0,contentDidMount:()=>{},contentDidUpdate:()=>{},initialContent:'<!DOCTYPE html><html><head></head><body><div class="frame-root"></div></body></html>'});const ChaiFrame=React.forwardRef((n,c)=>jsxRuntime.jsx(Frame,{...n,forwardedRef:c})),useKeyEventWatcher=n=>{const[c,d]=useSelectedBlockIds(),x=useSelectedBlock(),b=useRemoveBlocks(),y=useDuplicateBlocks(),{undo:R,redo:S}=useUndoManager(),[,_]=useCutBlockIds(),[,A]=useCopyBlocks(),{canPaste:L,pasteBlocks:T}=usePasteBlocks(),O=n?{document:n}:{};reactHotkeysHook.useHotkeys("ctrl+z,command+z",()=>R(),{},[R]),reactHotkeysHook.useHotkeys("ctrl+y,command+y",()=>S(),{},[S]),reactHotkeysHook.useHotkeys("ctrl+x,command+x",()=>_(c),{},[c,_]),reactHotkeysHook.useHotkeys("ctrl+c,command+c",()=>A(c),{...O,enabled:!lodashEs.isEmpty(c),preventDefault:!0},[c,A]),reactHotkeysHook.useHotkeys("ctrl+v,command+v",()=>{L(c[0])&&T(c)},{...O,enabled:!lodashEs.isEmpty(c),preventDefault:!0},[c,L,T]),reactHotkeysHook.useHotkeys("esc",()=>d([]),O,[d]),reactHotkeysHook.useHotkeys("ctrl+d,command+d",()=>y(c),{...O,enabled:!lodashEs.isEmpty(c),preventDefault:!0},[c,y]),reactHotkeysHook.useHotkeys("del, backspace",U=>{U.preventDefault(),canDeleteBlock(lodashEs.get(x,"_type",""))&&b(c)},O,[c,b])},KeyboardHandler=()=>{const{document:n}=useFrame();return useKeyEventWatcher(n),null},AddBlockAtBottom=()=>{const{t:n}=reactI18next.useTranslation(),{hasPermission:c}=usePermissions(),d=c(PERMISSIONS.ADD_BLOCK),x=useIsDragAndDropEnabled();return d?jsxRuntime.jsxs("div",{id:"add-block-bottom",className:"group relative w-full cursor-pointer py-2",children:[jsxRuntime.jsx("br",{}),!x&&jsxRuntime.jsx("div",{role:"button",onClick:()=>pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK),className:"block h-1 rounded bg-primary opacity-0 duration-200 group-hover:opacity-100",children:jsxRuntime.jsxs("div",{className:"absolute left-1/2 flex -translate-x-1/2 -translate-y-1/2 transform items-center gap-x-1 rounded-full bg-primary px-3 py-1 text-xs leading-tight text-white hover:bg-primary",children:[jsxRuntime.jsx(reactIcons.PlusIcon,{className:"size-2.5 stroke-[3]"})," ",n("Add block")]})}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{})]}):null},CssThemeVariables=({theme:n})=>{const c=React.useMemo(()=>plugin.getChaiThemeCssVariables(n),[n]);return jsxRuntime.jsx("style",{id:"chai-theme",children:c})},HeadTags=()=>{const[n]=useTheme(),c=useThemeOptions(),[d]=useDarkMode(),{document:x,window:b}=useFrame();return React.useEffect(()=>{d?x==null||x.documentElement.classList.add("dark"):x==null||x.documentElement.classList.remove("dark")},[d,x]),React.useEffect(()=>{!b||!b.tailwind||(b.tailwind.config={darkMode:"class",theme:{extend:{container:{center:!0,padding:"1rem",screens:{"2xl":"1400px"}},...plugin.getChaiThemeOptions(c)}},plugins:[tailwindTypography,tailwindForms,tailwindAspectRatio,twContainer,plugin.plugin(function({addBase:y,theme:R}){y({"h1,h2,h3,h4,h5,h6":{fontFamily:R("fontFamily.heading")},body:{fontFamily:R("fontFamily.body"),color:R("colors.foreground"),backgroundColor:R("colors.background")}})})]})},[n,c,b]),jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(CssThemeVariables,{theme:n}),jsxRuntime.jsx(Fonts,{}),jsxRuntime.jsx(SelectedBlocks,{}),jsxRuntime.jsx(SelectedStylingBlocks,{})]})},SelectedStylingBlocks=()=>{const[n]=useSelectedStylingBlocks(),[c]=useSelectedBlockIds(),d=React.useMemo(()=>`${lodashEs.map(n,({id:x})=>`[data-style-id="${x}"]`).join(",")}{
337
+ outline: 1px solid ${c.length>0?"#42a1fc":"#de8f09"} !important; outline-offset: -1px;
338
+ }`,[n,c]);return jsxRuntime.jsx("style",{id:"selected-styling-blocks",dangerouslySetInnerHTML:{__html:d}})},SelectedBlocks=()=>{const[n]=useSelectedBlockIds(),c=React.useMemo(()=>`${lodashEs.map(n,d=>`[data-block-id="${d}"]`).join(",")}{
339
+ outline: 1px solid #42a1fc !important; outline-offset: -1px;
340
+ }`,[n]);return jsxRuntime.jsx("style",{id:"selected-blocks",dangerouslySetInnerHTML:{__html:c}})},Fonts=()=>{const[n]=useTheme(),c=runtime.useRegisteredFonts(),d=React.useMemo(()=>{const{heading:y,body:R}={heading:lodashEs.get(n,"fontFamily.heading"),body:lodashEs.get(n,"fontFamily.body")};return c.filter(S=>S.family===y||S.family===R)},[n==null?void 0:n.fontFamily,c]),x=React.useMemo(()=>plugin.getThemeFontsUrls(lodashEs.filter(d,y=>lodashEs.has(y,"url"))),[d]),b=React.useMemo(()=>plugin.getThemeCustomFontFace(lodashEs.filter(d,y=>lodashEs.has(y,"src"))),[d]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[x.map((y,R)=>jsxRuntime.jsx("link",{rel:"stylesheet",href:y},`google-font-${R}`)),jsxRuntime.jsx("style",{id:"chai-custom-fonts",dangerouslySetInnerHTML:{__html:b}})]})},ResizableCanvasWrapper=({children:n,onMount:c,onResize:d})=>{const[,x]=useSelectedBlockIds(),[,b]=useSelectedStylingBlocks(),y=React.useRef(null),R=web.useDebouncedCallback(()=>{const{clientWidth:_}=y.current;d(_)},[y.current],100);web.useResizeObserver(y.current,R,y.current!==null),React.useEffect(()=>{const{clientWidth:_}=y.current;c(_)},[]);const S=React.useCallback(()=>{x([]),b([])},[x,b]);return jsxRuntime.jsx("div",{id:"main-content",onClick:S,className:"h-full w-full border-l-4 border-r-4 pb-0",ref:y,children:n})},useDirectBlockDrag=()=>{const[,n]=useSelectedBlockIds(),{onDragStart:c,onDragEnd:d}=useDragAndDrop(),[x]=useBlocksStore(),b=React.useRef(null),y=React.useCallback(_=>{var T;if(_.button!==0)return;const A=_.target;if(A.isContentEditable||A.tagName==="INPUT"||A.tagName==="TEXTAREA"||A.tagName==="SELECT"||A.tagName==="BUTTON"||A.tagName==="A")return;const L=(T=A.closest("[data-block-id]"))==null?void 0:T.getAttribute("data-block-id");L&&(n([L]),b.current=L)},[n]),R=React.useCallback(_=>{if(!b.current)return;const A=lodash.find(x,{_id:b.current});A&&c(_,A,!1)},[x,c]),S=React.useCallback(()=>{d(),b.current=null},[d]);return{onMouseDown:y,onDragStart:R,onDragEnd:S}},editorModeAtom=jotai.atom("edit"),useEditorMode=()=>{const[n,c]=jotai.useAtom(editorModeAtom);return{mode:n,setMode:c}},MayBeAsyncPropsWrapper=({children:n,block:c})=>{const d=React.useMemo(()=>runtime.getRegisteredChaiBlock(c._type),[c._type]),x=lodashEs.get(d,"dataProviderDependencies"),b=lodashEs.get(d,"dataProvider"),y=lodashEs.get(d,"dataProviderMode","mock"),R=useAsyncProps(c,y,x,b);return n(R)},ErrorFallback=()=>jsxRuntime.jsx("div",{className:"flex min-h-[100px] items-center justify-center bg-red-50 p-2 text-center text-red-500",children:"Something went wrong."}),useBlockRuntimeProps=()=>{const[n]=useBlocksStore();return React.useCallback((c,d)=>lodashEs.isEmpty(d)?{}:Object.entries(d).reduce((x,[b,y])=>{const R=[];let S=lodashEs.find(n,{_id:c});for(;S;)R.push(S),S=lodashEs.find(n,{_id:S._parent});const _=lodashEs.find(R,{_type:y.block});return _&&(x[b]=lodashEs.get(_,lodashEs.get(y,"prop"),null)),x},{}),[n])};function cn(...n){return tailwindMerge.twMerge(clsx.clsx(n))}const RteDropdownMenu=({editor:n,trigger:c,content:d,from:x,menuRef:b})=>{const{document:y}=useFrame(),[R,S]=React.useState({left:void 0,right:void 0,top:void 0,bottom:void 0}),[_,A]=React.useState(!1),L=React.useRef(null);if(React.useEffect(()=>{var $,ee;if(!_){S({left:void 0,right:void 0,top:void 0,bottom:void 0});return}const T=($=L.current)==null?void 0:$.getBoundingClientRect(),O=(ee=b.current)==null?void 0:ee.getBoundingClientRect();let U=T==null?void 0:T.left,M=(T==null?void 0:T.bottom)+4,D,K;(O==null?void 0:O.left)+(O==null?void 0:O.width)+50>=y.body.offsetWidth&&(U=void 0,D=y.body.offsetWidth-(T==null?void 0:T.right)),M+202>=y.body.clientHeight&&(M=null,K=y.body.clientHeight-(T==null?void 0:T.bottom)+(O==null?void 0:O.height)),S({left:U,top:M,right:D,bottom:K})},[_]),x==="canvas"){const T=()=>{A(!1),n&&(n==null||n.view.focus(),n==null||n.chain().focus().run())};return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{ref:L,onClick:()=>A(O=>!O),className:"cursor-pointer",children:c}),_&&(R.left!==void 0||R.top!==void 0||R.right!==void 0||R.bottom!==void 0)&&require$$1.createPortal(jsxRuntime.jsx("div",{id:"chaibuilder-rte-dropdown-menu-content",onClick:T,className:"fixed inset-0 left-0 top-0 z-[10001] h-full w-screen",children:jsxRuntime.jsx("div",{onClick:O=>O.stopPropagation(),className:"absolute rounded-md border border-gray-500 bg-white p-1.5 text-xs shadow-2xl",style:Object.assign({},{left:R.left,top:R.top,right:R.right,bottom:R.bottom}),children:typeof d=="function"?d(T):d})}),y.body,"chaibuilder-rte-dropdown-menu")]})}return jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsxs(tooltip.DropdownMenu,{open:_,onOpenChange:A,children:[jsxRuntime.jsx(tooltip.DropdownMenuTrigger,{className:"relative outline-none",asChild:!0,children:c}),jsxRuntime.jsx(tooltip.DropdownMenuContent,{className:"z-50 rounded-md border bg-white p-1 text-xs shadow-xl",children:_&&(typeof d=="function"?d(()=>A(!1)):d)})]})})};utils.atomWithStorage("chai-builder-blocks",[]);const lsThemeAtom=utils.atomWithStorage("chai-builder-theme",{});utils.atomWithStorage("chai-builder-ai-context","");const getActiveClasses$1=(n,c,d)=>{const x=d==="settings",b=typeof c=="boolean"?c:c.some(y=>n.isActive(y));return{"rounded p-1":!0,"hover:bg-blue-900 hover:text-blue-100":!b&&!x,"hover:bg-blue-100 hover:text-blue-900":!b&&x,"bg-blue-500 text-white":b&&x,"bg-white text-blue-500":b&&!x}},Commons=({themeColors:n,onClose:c,color:d,onChange:x,onRemove:b})=>jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:"flex w-[180px] flex-wrap gap-1 pb-2",children:(n==null?void 0:n.length)>0&&lodashEs.uniq(n).map(y=>{var R;return jsxRuntime.jsx("button",{className:cn("h-4 w-4 cursor-pointer rounded-full border border-gray-900 shadow duration-200 hover:scale-105 hover:shadow-xl",{"border-2":y===d}),style:{backgroundColor:y},onClick:()=>{x(y),c()},title:(R=y||"#000000")==null?void 0:R.toUpperCase()},y)})}),jsxRuntime.jsx(reactColorful.HexAlphaColorPicker,{color:d,onChange:x,style:{width:"200px",height:"200px"}}),jsxRuntime.jsxs("div",{className:"mt-1 flex items-center justify-between gap-1",children:[jsxRuntime.jsx(tooltip.Input,{type:"text",value:d||"#000000f2",onChange:y=>x(y.target.value,!0),className:"!h-5 !w-[105px] rounded-sm !p-0 text-center font-light uppercase text-gray-600 outline-none ring-0 focus:ring-0",placeholder:"#000000"}),jsxRuntime.jsxs("button",{className:"flex h-4 w-max cursor-pointer items-center gap-x-1 rounded-full bg-transparent px-1 text-red-600 shadow-none duration-200 hover:bg-red-100",onClick:()=>{b(),c()},title:"Remove",children:[jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-3 w-3"})," Remove"]})]})]}),ColorPickerContent=({textColor:n,highlightColor:c,onChangeTextColor:d,onChangeHighlightColor:x,onRemoveTextColor:b,onRemoveHighlightColor:y,onClose:R})=>{const[S]=useDarkMode(),[_]=jotai.useAtom(lsThemeAtom),A=(_==null?void 0:_.colors)||{},L=Object.values(A).map(U=>lodashEs.get(U,S?"1":"0")),[T,O]=React.useState("TEXT");return jsxRuntime.jsxs("div",{id:"rte-widget-color-picker",className:"px-1",children:[jsxRuntime.jsxs("div",{className:"mb-2 flex items-center justify-between rounded-md border bg-muted",children:[jsxRuntime.jsx("div",{className:`w-full cursor-pointer rounded p-0.5 text-center ${T==="TEXT"?"bg-blue-500 text-white":"hover:bg-blue-100 hover:text-blue-500"}`,onClick:()=>O("TEXT"),children:"Text Color"}),jsxRuntime.jsx("div",{className:`w-full cursor-pointer rounded p-0.5 text-center ${T==="HIGHLIGHT"?"bg-blue-500 text-white":"hover:bg-blue-100 hover:text-blue-500"}`,onClick:()=>O("HIGHLIGHT"),children:"Highlight Color"})]}),T==="TEXT"?jsxRuntime.jsx(Commons,{themeColors:L,onClose:R,onChange:d,color:n,onRemove:b}):jsxRuntime.jsx(Commons,{themeColors:L,onClose:R,onChange:x,color:c,onRemove:y})]})},RteColorPicker=({editor:n,from:c,menuRef:d})=>{var ee,ae;const x=(ee=n==null?void 0:n.getAttributes("textStyle"))==null?void 0:ee.color,b=(ae=n==null?void 0:n.getAttributes("highlight"))==null?void 0:ae.color,[y,R]=React.useState(x||"#000000F2"),[S,_]=React.useState(b||"#00000057"),[A,L]=web.useDebouncedState(y,150),[T,O]=web.useDebouncedState(S,150),U=(Re,ye)=>{ye?(R(Re),L(Re)):(n==null||n.chain().setColor(Re).run(),R(Re))},M=(Re,ye)=>{ye?(_(Re),O(Re)):(n==null||n.chain().setHighlight({color:Re}).run(),_(Re))},D=()=>{n==null||n.chain().unsetColor().run(),R("#000000F2")},K=()=>{n==null||n.chain().unsetHighlight().run()};React.useEffect(()=>{b&&_(b)},[b]),React.useEffect(()=>{T!=null&&T.includes("#")&&(T==null?void 0:T.length)>=3&&(n==null||n.chain().setHighlight({color:T}).run())},[T]),React.useEffect(()=>{A!=null&&A.includes("#")&&(A==null?void 0:A.length)>=3&&(n==null||n.chain().setColor(A).run())},[A]);const $=!!x;return jsxRuntime.jsx(RteDropdownMenu,{editor:n,from:c,menuRef:d,trigger:jsxRuntime.jsxs("div",{className:cn("relative flex items-center",getActiveClasses$1(n,$,c)),title:"Text Color",children:[jsxRuntime.jsx("div",{className:"h-4 w-4 rounded-full",style:{backgroundColor:x||(c==="canvas"?"#FFFFFF":"#000000")}}),jsxRuntime.jsx(reactIcons.CaretDownIcon,{className:"h-3 w-3 opacity-50"})]}),content:Re=>jsxRuntime.jsx(ColorPickerContent,{textColor:y,highlightColor:S,onChangeTextColor:U,onChangeHighlightColor:M,onRemoveTextColor:D,onRemoveHighlightColor:K,onClose:Re})})},getActiveClasses=(n,c,d)=>{const x=d==="settings",b=typeof c=="boolean"?c:c.some(y=>n.isActive(y));return{"rounded p-1":!0,"hover:bg-blue-900 hover:text-blue-100":!b&&!x,"hover:bg-blue-100 hover:text-blue-900":!b&&x,"bg-blue-500 text-white":b&&x,"bg-white text-blue-500":b&&!x}},RteMenubar=({editor:n,from:c="settings",onExpand:d})=>{const x=React.useRef(null);if(!n)return null;const b=()=>{const R=window.prompt("URL");R&&n.chain().focus().extendMarkRange("link").setLink({href:R}).run()},y=()=>{n.chain().focus().unsetLink().run()};return jsxRuntime.jsxs("div",{ref:x,id:"chai-rich-text-menu-bar",className:cn("mb-1 flex flex-wrap gap-0.5 rounded-t-md border-b border-border bg-gray-50 p-1",{"mb-0 rounded-md border-none bg-blue-500 text-white":c==="canvas"}),children:[jsxRuntime.jsx("button",{type:"button",onClick:()=>n.chain().focus().toggleBold().run(),className:cn("",getActiveClasses(n,["bold"],c)),title:"Bold",children:jsxRuntime.jsx(reactIcons.FontBoldIcon,{className:"h-4 w-4"})}),jsxRuntime.jsx("button",{type:"button",onClick:()=>n.chain().focus().toggleItalic().run(),className:cn("",getActiveClasses(n,["italic"],c)),title:"Italic",children:jsxRuntime.jsx(reactIcons.FontItalicIcon,{className:"h-4 w-4"})}),jsxRuntime.jsx("button",{type:"button",onClick:()=>n.chain().focus().toggleUnderline().run(),className:cn("",getActiveClasses(n,["underline"],c)),title:"Underline",children:jsxRuntime.jsx(reactIcons.UnderlineIcon,{className:"h-4 w-4"})}),jsxRuntime.jsx("button",{type:"button",onClick:()=>n.chain().focus().toggleStrike().run(),className:cn("",getActiveClasses(n,["strike"],c)),title:"Strike",children:jsxRuntime.jsx(reactIcons.StrikethroughIcon,{className:"h-4 w-4"})}),jsxRuntime.jsx("div",{className:"mx-1 h-5 w-px self-center bg-border"}),jsxRuntime.jsx(RteColorPicker,{editor:n,from:c,menuRef:x}),jsxRuntime.jsx("div",{className:"mx-1 h-5 w-px self-center bg-border"}),jsxRuntime.jsx(RteDropdownMenu,{editor:n,menuRef:x,from:c,trigger:jsxRuntime.jsxs("button",{type:"button",className:cn("flex items-center",getActiveClasses(n,["bulletList","orderedList"],c)),title:"Bullet List",children:[jsxRuntime.jsx(reactIcons.ListBulletIcon,{className:"h-4 w-4"}),jsxRuntime.jsx(reactIcons.CaretDownIcon,{className:"h-3 w-3 opacity-50"})]}),content:R=>jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("div",{onClick:()=>{n.chain().focus().toggleBulletList().run(),R()},className:cn("flex cursor-pointer items-center gap-x-1 outline-none hover:outline-none",getActiveClasses(n,["bulletList"],c)),children:[jsxRuntime.jsx(reactIcons.ListBulletIcon,{className:"h-4 w-4"})," Unordered List"]}),jsxRuntime.jsxs("div",{onClick:()=>{n.chain().focus().toggleOrderedList().run(),R()},className:cn("flex cursor-pointer items-center gap-x-1 outline-none hover:outline-none",getActiveClasses(n,["orderedList"],c)),children:[jsxRuntime.jsx(reactIcons.ValueIcon,{className:"h-4 w-4"}),"Ordered List"]})]})}),jsxRuntime.jsx(RteDropdownMenu,{editor:n,menuRef:x,from:c,trigger:jsxRuntime.jsxs("button",{type:"button",className:cn("flex items-center",getActiveClasses(n,n.isActive({textAlign:"center"})||n.isActive({textAlign:"right"}),c)),title:"Text Alignment",children:[n.isActive({textAlign:"center"})?jsxRuntime.jsx(reactIcons.TextAlignCenterIcon,{className:"h-4 w-4"}):n.isActive({textAlign:"right"})?jsxRuntime.jsx(reactIcons.TextAlignRightIcon,{className:"h-4 w-4"}):jsxRuntime.jsx(reactIcons.TextAlignLeftIcon,{className:"h-4 w-4"}),jsxRuntime.jsx(reactIcons.CaretDownIcon,{className:"h-3 w-3 opacity-50"})]}),content:R=>jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("div",{onClick:()=>{n.chain().focus().setTextAlign("left").run(),R()},className:cn("flex cursor-pointer items-center gap-x-1 outline-none hover:outline-none",getActiveClasses(n,n.isActive({textAlign:"left"}),c)),children:[jsxRuntime.jsx(reactIcons.TextAlignLeftIcon,{className:"h-4 w-4"})," Align Left"]}),jsxRuntime.jsxs("div",{onClick:()=>{n.chain().focus().setTextAlign("center").run(),R()},className:cn("flex cursor-pointer items-center gap-x-1 outline-none hover:outline-none",getActiveClasses(n,n.isActive({textAlign:"center"}),c)),children:[jsxRuntime.jsx(reactIcons.TextAlignCenterIcon,{className:"h-4 w-4"})," Align Center"]}),jsxRuntime.jsxs("div",{onClick:()=>{n.chain().focus().setTextAlign("right").run(),R()},className:cn("flex cursor-pointer items-center gap-x-1 outline-none hover:outline-none",getActiveClasses(n,n.isActive({textAlign:"right"}),c)),children:[jsxRuntime.jsx(reactIcons.TextAlignRightIcon,{className:"h-4 w-4"})," Align Right"]})]})}),n.isActive("link")?jsxRuntime.jsx("button",{type:"button",onClick:y,className:cn("",getActiveClasses(n,["link"],c)),title:"Remove Link",disabled:!n.isActive("link"),children:jsxRuntime.jsx(reactIcons.LinkBreak2Icon,{className:"h-3.5 w-3.5"})}):jsxRuntime.jsx("button",{type:"button",onClick:b,className:cn("",getActiveClasses(n,["link"],c)),title:"Add Link",children:jsxRuntime.jsx(reactIcons.Link2Icon,{className:"h-3.5 w-3.5"})}),d&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:"mx-1 h-5 w-px self-center bg-border"}),jsxRuntime.jsx("button",{type:"button",onClick:d,className:cn("",getActiveClasses(n,!1,c)),title:"Open in full screen mode",children:jsxRuntime.jsx(reactIcons.EnterFullScreenIcon,{className:"h-3.5 w-3.5"})})]})]})},useRTEditor=({blockId:n,value:c="",onUpdate:d=()=>{},onBlur:x=()=>{},placeholder:b="",from:y="settings",style:R={}})=>react.useEditor({extensions:[StarterKit,extensionTextStyle.TextStyle,extensionTextStyle.Color.configure({types:["textStyle"]}),Highlight.configure({multicolor:!0}),Link.configure({openOnClick:!1,HTMLAttributes:{class:"underline"}}),TextAlign.configure({types:["heading","paragraph"],alignments:["left","center","right"],defaultAlignment:"left"}),Underline,Placeholder.configure({placeholder:b||"Enter text here",emptyEditorClass:"cursor-text before:content-[attr(data-placeholder)] before:absolute before:opacity-50 before:pointer-events-none"})],content:c||"",onUpdate:d,onBlur:x,editorProps:{attributes:{...R?{style:R}:{},class:y!=="canvas"?"text-sm p-1 px-2 rte":"rte"}}},[n]);function getInitialTextAlign(n){let c=n;for(;c;){if(c.style&&c.style.textAlign)return c.style.textAlign;const d=window.getComputedStyle(c).textAlign;if(d&&d!=="start"&&d!=="initial"&&d!=="inherit")return d;c=c.parentElement}return null}const RichTextEditor=React.memo(({blockContent:n,editingElement:c,onClose:d,onChange:x,onEscape:b})=>{const{document:y}=useFrame(),R=useRTEditor({value:n,blockId:"active-inline-editing-element",placeholder:"Enter text here",onUpdate:({editor:A})=>x((A==null?void 0:A.getHTML())||""),onBlur:({editor:A,event:L})=>{const T=L==null?void 0:L.relatedTarget,O=y.querySelector(".ProseMirror"),U=y.querySelector(".tippy-box"),M=y.querySelector("#chai-rich-text-menu-bar"),D=O==null?void 0:O.contains(T),K=U==null?void 0:U.contains(T),$=M==null?void 0:M.contains(T),ee=window.document.getElementById("rte-widget-color-picker");if(!D&&!K&&!$&&!ee){const ae=(A==null?void 0:A.getHTML())||"";d(ae)}},from:"canvas"});React.useEffect(()=>{var L,T;const A=getInitialTextAlign(c);A&&((L=R==null?void 0:R.commands)==null||L.setTextAlign(A)),(T=R==null?void 0:R.commands)==null||T.focus(),R==null||R.emit("focus",{editor:R,event:new FocusEvent("focus"),transaction:[]})},[R]);const S=React.useMemo(()=>{var T;const A="max-w-none shadow-none outline outline-[2px] outline-green-500 [&_*]:shadow-none";if(!c)return A;const L=((T=c==null?void 0:c.className)==null?void 0:T.replace("sr-only",""))||"";return`${A} ${L}`},[c]),_=A=>{A.key==="Escape"&&b(A)};return R&&jsxRuntime.jsxs("div",{onKeyDown:_,onClick:A=>A.stopPropagation(),className:"relative",children:[jsxRuntime.jsx(react.BubbleMenu,{editor:R,shouldShow:()=>R&&(R==null?void 0:R.isFocused),tippyOptions:{duration:100,arrow:!0,hideOnClick:!1},className:"w-max",children:jsxRuntime.jsx(RteMenubar,{editor:R,from:"canvas"})}),jsxRuntime.jsx(react.EditorContent,{onKeyDown:_,value:n,editor:R,className:S})]})}),MemoizedEditor=React.memo(({editingElement:n,blockContent:c,onClose:d,editorRef:x,onChange:b,onEscape:y})=>{const{document:R,window:S}=useFrame();React.useEffect(()=>{if(x.current){x.current.innerHTML=c,x.current.focus();const O=R.createRange(),U=S.getSelection();O.selectNodeContents(x.current),O.collapse(!1),U==null||U.removeAllRanges(),U==null||U.addRange(O),x.current.focus()}else d()},[R,S]);const _=React.useMemo(()=>{var U;const O=((U=n==null?void 0:n.tagName)==null?void 0:U.toLowerCase())||"div";return O==="button"?"div":O},[n]),A=React.useCallback(O=>{(O.key==="Enter"||O.key==="Escape")&&y(O)},[y]),L=React.useCallback(()=>{d()},[d]),T=React.useMemo(()=>{var O;return{id:"active-inline-editing-element",contentEditable:!0,className:`${((O=n==null?void 0:n.className)==null?void 0:O.replace("sr-only",""))||""} outline outline-[2px] outline-green-500 shadow-none empty:before:content-[attr(data-placeholder)] empty:before:text-gray-400 empty:before:absolute empty:before:pointer-events-none empty:before:select-none empty:before:inset-0 empty:before:z-0 relative min-h-[1em]`,style:lodashEs.cloneDeep(n==null?void 0:n.style)||{},onInput:U=>{const M=U.target;M&&(M.innerText.trim()===""?(M.setAttribute("data-placeholder","Enter text here"),M.children.length>0&&M.children[0].remove()):U.target.removeAttribute("data-placeholder"),b(U.target.innerText))},onClick:U=>{U.stopPropagation(),U.preventDefault()}}},[n==null?void 0:n.className,n==null?void 0:n.style]);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:React.createElement(_,{ref:x,onBlur:L,onKeyDown:A,...T})})}),WithBlockTextEditor=React.memo(({block:n,children:c})=>{const d="content",{document:x}=useFrame(),{editingBlockId:b,editingItemIndex:y,setEditingBlockId:R,setEditingItemIndex:S}=useInlineEditing(),[_,A]=React.useState(null),L=React.useRef(null),{clearHighlight:T}=useBlockHighlight(),O=useUpdateBlocksProps(),{selectedLang:U}=useLanguages(),[,M]=useSelectedBlockIds(),D=React.useRef(null),K=b,{blockContent:$,blockType:ee}=React.useMemo(()=>{var Ee;const q=n._type;let he=n[d];const le=runtime.getRegisteredChaiBlock(n._type);return U&&((Ee=le==null?void 0:le.i18nProps)==null?void 0:Ee.includes(d))&&lodashEs.has(n,`${d}-${U}`)&&(he=lodashEs.get(n,`${d}-${U}`)),{blockContent:he,blockType:q}},[n,U]),ae=React.useCallback(q=>{var le;const he=q||((le=L.current)==null?void 0:le.innerText);O([K],{[d]:he}),A(null),R(null),S(-1),M([]),K&&setTimeout(()=>M([K]),100)},[K,O,R,M,U]),Re=web.useDebouncedCallback(q=>{O([K],{[d]:q})},[K,n,O,U],1e3),ye=React.useCallback(q=>{q.preventDefault(),K&&(D.current=K),ae(),setTimeout(()=>{const he=D.current;D.current=null,M([he])},100)},[M,K,U]);React.useEffect(()=>{var xe;if(!K)return;const q=`[data-block-id="${K}"]`,he=y>=0?`[data-block-index="${y}"]`:"",le=x.querySelector(`${q}${he}`);le&&((xe=le==null?void 0:le.classList)==null||xe.add("sr-only"),A(le))},[K,ee,x,y]);const de=React.useMemo(()=>_?(T(),["RichText","Paragraph"].includes(ee)?jsxRuntime.jsx(RichTextEditor,{blockContent:$,editingElement:_,onChange:Re,onClose:ae,onEscape:ye}):jsxRuntime.jsx(MemoizedEditor,{editorRef:L,blockContent:$,editingElement:_,onClose:ae,onChange:Re,onEscape:ye})):null,[_,K,ee,$,ae,U]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[de,c]})},(n,c)=>n.block._id===c.block._id&&n.block.content===c.block.content),RepeaterContext=React.createContext({index:-1,key:""}),CORE_BLOCKS=["Box","Repeater","GlobalBlock","PartialBlock","Heading","Text","RichText","Span","Image","Button","Paragraph","Link","Video","Audio","Icon","List","ListItem","CustomScript","CustomHTML"],BlockRenderer=({asyncProps:n,blockAtom:c,children:d})=>{const{editingBlockId:x,editingItemIndex:b}=useInlineEditing(),[y]=jotai.useAtom(c),R=React.useMemo(()=>runtime.getRegisteredChaiBlock(y._type),[y._type]),{selectedLang:S,fallbackLang:_}=useLanguages(),A=useBlockRuntimeProps(),L=usePageExternalData(),[T]=jotai.useAtom(dataBindingActiveAtom),O=lodashEs.get(R,"component",null),{index:U,key:M}=React.useContext(RepeaterContext),{mode:D}=useEditorMode(),K=useIsDragAndDropEnabled(),$=D==="edit",ee=useDirectBlockDrag(),ae=React.useMemo(()=>T?applyBinding.applyBindingToBlockProps(applyBinding.applyLanguage(y,S,R),L,{index:U,key:M}):applyBinding.applyLanguage(y,S,R),[y,S,R,L,T,U,M]),Re=React.useMemo(()=>applyBinding.getBlockTagAttributes(y),[y,applyBinding.getBlockTagAttributes]),ye=React.useMemo(()=>A(y._id,applyBinding.getBlockRuntimeProps(y._type)),[y._id,y._type,A,applyBinding.getBlockRuntimeProps]),de=React.useMemo(()=>{const je={"data-block-id":y._id,"data-block-type":y._type,"data-block-index":U};return $&&K?{...je,draggable:!0,onMouseDown:ee.onMouseDown,onDragStart:ee.onDragStart,onDragEnd:ee.onDragEnd}:je},[y._id,y._type,U,$,K,ee]),q=React.useMemo(()=>({blockProps:de,inBuilder:D==="edit",lang:S||_,...ae,...Re,...ye,...n}),[D,de,S,_,ae,Re,ye,n]),he=React.useMemo(()=>!CORE_BLOCKS.includes(y._type),[y._type]),le=React.useMemo(()=>lodashEs.get(y,"_show",!0),[y]);if(lodashEs.isNull(O)||!le)return null;let xe=jsxRuntime.jsx(React.Suspense,{children:React.createElement(O,{...q,children:d({_id:y._id,_type:y._type,...lodashEs.isArray(ae.repeaterItems)?{repeaterItems:applyBinding.applyLimit(ae.repeaterItems,y),$repeaterItemsKey:ae.$repeaterItemsKey}:{},...y.partialBlockId?{partialBlockId:y.partialBlockId}:"",...y.globalBlock?{partialBlockId:y.globalBlock}:""})})});const Ee=x===y._id&&(b===U||U<0)?jsxRuntime.jsx(WithBlockTextEditor,{block:y,children:xe}):xe;return he?jsxRuntime.jsx(reactErrorBoundary.ErrorBoundary,{fallbackRender:ErrorFallback,children:Ee}):Ee},PartialWrapper$1=({children:n,partialBlockId:c})=>{const d=useBuilderProp("gotoPage",lodashEs.noop),{saveState:x}=useSavePage(),{selectedLang:b,fallbackLang:y}=useLanguages(),R=React.useCallback(S=>{if(S.stopPropagation(),x!=="SAVED"){sonner.toast.error("You have unsaved changes. Please save the page first.");return}d({pageId:c,lang:b||y})},[x,d,c,b,y]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[n,jsxRuntime.jsx("div",{className:"partial-overlay group absolute inset-0 z-50",children:jsxRuntime.jsx("div",{onDoubleClick:R,className:"flex h-full w-full items-center justify-center bg-black/10 opacity-0 transition-opacity duration-300 ease-in-out group-hover:opacity-100 group-hover:backdrop-opacity-85",children:jsxRuntime.jsx("p",{className:"rounded-md bg-white px-2 py-1 text-xs",children:"Partial block. Double click to edit."})})})]})},PartialBlocksRenderer=({partialBlockId:n})=>{const{getPartailBlocks:c}=usePartialBlocksStore(),d=React.useMemo(()=>c(n),[c,n]),x=React.useMemo(()=>utils.splitAtom(jotai.atom(d)),[d]);return lodashEs.isEmpty(d)?null:jsxRuntime.jsx(PartialWrapper$1,{partialBlockId:n,children:jsxRuntime.jsx(BlocksRenderer,{splitAtoms:x,blocks:d,type:"PartialBlock"})})},BlocksRenderer=({blocks:n,parent:c=null,splitAtoms:d=void 0,type:x=""})=>{const b=useGetBlockAtom(d);let y=React.useMemo(()=>lodashEs.filter(n,S=>lodashEs.has(S,"_id")&&(lodashEs.isEmpty(c)?!S._parent:S._parent===c)),[n,c]);const R=React.useCallback(S=>lodashEs.filter(n,_=>_._parent===S).length>0,[n]);return R&&(x==="Heading"||x==="Paragraph"||x==="Link")&&(y=applyBinding.adjustSpacingInContentBlocks(y)),lodashEs.map(y,S=>{const _=b(S._id);return _?jsxRuntime.jsx(MayBeAsyncPropsWrapper,{block:S,children:A=>jsxRuntime.jsx(BlockRenderer,{blockAtom:_,asyncProps:A,children:({_id:L,_type:T,partialBlockId:O,repeaterItems:U,$repeaterItemsKey:M})=>T==="Repeater"?lodashEs.isArray(U)&&U.map((D,K)=>jsxRuntime.jsx(RepeaterContext.Provider,{value:{index:K,key:M},children:jsxRuntime.jsx(BlocksRenderer,{splitAtoms:d,blocks:n,parent:S._id,type:T})},`${L}-${K}`)):T==="GlobalBlock"||T==="PartialBlock"?jsxRuntime.jsx(jotai.Provider,{store:builderStore,children:jsxRuntime.jsx(PartialBlocksRenderer,{partialBlockId:O})}):R(L)?jsxRuntime.jsx(BlocksRenderer,{splitAtoms:d,blocks:n,parent:S._id,type:T}):null})},S._id):null})},PageBlocksRenderer=()=>{const[n]=useBlocksStore();return jsxRuntime.jsx(BlocksRenderer,{splitAtoms:pageBlocksAtomsAtom,blocks:n})},StaticBlocksRenderer=()=>{const[n]=useBlocksStore(),c=lodashEs.isEmpty(n)?null:jsxRuntime.jsx(PageBlocksRenderer,{});return jsxRuntime.jsx(jsxRuntime.Fragment,{children:c})},useCanvasScale=n=>{const[c]=useCanvasDisplayWidth(),[,d]=useCanvasZoom(),x=useBuilderProp("htmlDir","ltr"),[b,y]=React.useState({}),R=React.useCallback(()=>{const{width:S,height:_}=n;if(S<c){const A=parseFloat((S/c).toFixed(2).toString());let L={};const T=_*A,O=S*A;_&&(L={height:100+(_-T)/T*100+"%",width:100+(S-O)/O*100+"%"}),y({position:"relative",top:0,transform:`scale(${A})`,transformOrigin:x==="rtl"?"top right":"top left",...L,maxWidth:"none"}),d(A*100)}else y({}),d(100)},[c,n,x,d]);return React.useEffect(()=>{R()},[c,n,d,R]),b},CanvasEventsWatcher=()=>{const[,n]=useSelectedBlockIds(),[c,d]=useSelectedStylingBlocks(),{document:x}=useFrame(),{clearHighlight:b}=useBlockHighlight(),[y]=useSelectedBlockIds(),[R]=jotai.useAtom(treeRefAtom);return React.useEffect(()=>{setTimeout(()=>{if(!lodashEs.isEmpty(c))return;const S=getElementByDataBlockId(x,lodashEs.first(y));if(S){const _=S.getAttribute("data-style-prop");if(_){const A=S.getAttribute("data-style-id"),L=S.getAttribute("data-block-parent");d([{id:A,prop:_,blockId:L}])}}},100)},[x,y,d,c]),React.useEffect(()=>()=>b(),[b]),usePubSub(CHAI_BUILDER_EVENTS.CANVAS_BLOCK_SELECTED,S=>{S&&(!lodashEs.isEmpty(S)&&!lodashEs.includes(y,lodashEs.first(S))&&(R==null||R.closeAll()),n(S))}),usePubSub(CHAI_BUILDER_EVENTS.CANVAS_BLOCK_STYLE_SELECTED,S=>{if(!S)return;const{blockId:_,styleId:A,styleProp:L}=S;_&&(lodashEs.includes(y,_)||R==null||R.closeAll(),d([{id:A,prop:L,blockId:_}]),n([_]))}),usePubSub(CHAI_BUILDER_EVENTS.CLEAR_CANVAS_SELECTION,()=>{b(),n([]),d([])}),null},StaticCanvas=()=>{const[n]=useCanvasDisplayWidth(),[,c]=useHighlightBlockId(),d=React.useRef(null),x=React.useRef(null),[b,y]=React.useState({width:0,height:0}),R=useCanvasScale(b),[,S]=useCanvasIframe(),_=useBuilderProp("loading",!1),A=useBuilderProp("htmlDir","ltr"),{onDragOver:L,onDrop:T,onDragEnd:O}=useDragAndDrop(),U=useDropIndicator(),M=React.useCallback(K=>{y($=>({...$,width:K}))},[y]);React.useEffect(()=>{if(!x.current)return;const{clientWidth:K,clientHeight:$}=x.current;y({width:K,height:$})},[x,n]);const D=React.useMemo(()=>{let K=IframeInitialContent;return K=K.replace("__HTML_DIR__",A),K},[A]);return jsxRuntime.jsx(ResizableCanvasWrapper,{onMount:M,onResize:M,children:jsxRuntime.jsx("div",{onMouseLeave:()=>setTimeout(()=>c(""),300),className:"relative mx-auto h-full w-full overflow-hidden",onDragOver:L,onDrop:T,onDragEnd:O,ref:x,children:jsxRuntime.jsxs(ChaiFrame,{contentDidMount:()=>S(d.current),ref:d,id:"canvas-iframe",style:{...R,...lodashEs.isEmpty(R)?{width:`${n}px`}:{}},className:"relative mx-auto box-content h-full w-full max-w-full shadow-lg transition-all duration-300 ease-linear",initialContent:D,children:[jsxRuntime.jsx(KeyboardHandler,{}),jsxRuntime.jsx(BlockSelectionHighlighter,{}),jsxRuntime.jsx(HeadTags,{}),jsxRuntime.jsxs(reactWrapBalancer.Provider,{children:[jsxRuntime.jsxs(Canvas,{children:[_?jsxRuntime.jsx("div",{className:"h-full p-4",children:jsxRuntime.jsx(tooltip.Skeleton,{className:"h-full"})}):jsxRuntime.jsx(StaticBlocksRenderer,{}),jsxRuntime.jsx(AddBlockAtBottom,{})]}),jsxRuntime.jsx(CanvasEventsWatcher,{})]}),U.isVisible&&jsxRuntime.jsx("div",{id:"placeholder",className:`pointer-events-none absolute z-[99999] max-w-full transition-all duration-150 ${U.isEmpty?"bg-purple-500/10 outline-dashed outline-2 -outline-offset-2 outline-purple-500":"rounded-full bg-green-500"}`,style:{top:U.top,left:U.left,width:U.width,height:U.height}})]})})})},FallbackError=()=>{const{t:n}=reactI18next.useTranslation();return jsxRuntime.jsx("div",{className:"h-full w-full rounded-md bg-red-200 p-4 text-red-500",children:jsxRuntime.jsxs("div",{className:"flex h-full w-full flex-col items-center justify-center",children:[jsxRuntime.jsx("p",{className:"font-semibold",children:n("Oops! Something went wrong.")}),jsxRuntime.jsx("p",{children:n("Please try again.")})]})})},CodeEditor$1=React.lazy(()=>Promise.resolve().then(()=>require("./code-editor-BhsT9_jf.cjs"))),CanvasArea=()=>{const[n]=useCodeEditor(),c=useBuilderProp("onError",lodashEs.noop);return jsxRuntime.jsx("div",{className:"flex h-full max-h-full w-full flex-1 flex-col",children:jsxRuntime.jsxs("div",{className:"relative flex h-full max-h-full flex-col overflow-hidden bg-gray-100/40",children:[jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx(tooltip.Skeleton,{className:"h-full"}),children:jsxRuntime.jsx(reactErrorBoundary.ErrorBoundary,{fallback:jsxRuntime.jsx(FallbackError,{}),onError:c,children:jsxRuntime.jsx(StaticCanvas,{})})}),n?jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx(tooltip.Skeleton,{className:"h-full"}),children:jsxRuntime.jsx(CodeEditor$1,{})}):null,jsxRuntime.jsx(Breadcrumb,{})]})})},RJSF_EXTENSIONS={},registerBlockSettingWidget=(n,c)=>{RJSF_EXTENSIONS[n]={id:n,component:c,type:"widget"}},registerBlockSettingField=(n,c)=>{RJSF_EXTENSIONS[n]={id:n,component:c,type:"field"}},registerBlockSettingTemplate=(n,c)=>{RJSF_EXTENSIONS[n]={id:n,component:c,type:"template"}},useBlockSettingComponents=n=>Object.values(RJSF_EXTENSIONS).filter(c=>c.type===n).reduce((c,d)=>(c[d.id]=d.component,c),{}),IconPicker=React.lazy(()=>Promise.resolve().then(()=>require("./IconPicker-BWE43eMO.cjs")).then(n=>({default:n.IconPicker}))),sanitizeSvg=n=>{try{let c=n.replace(/<svg([^>]*)\sheight="[^"]*"([^>]*)>/gi,"<svg$1$2>").replace(/<svg([^>]*)\swidth="[^"]*"([^>]*)>/gi,"<svg$1$2>");return c=c.replace(/>\s+</g,"><"),c=c.replace(/\n/g,"").replace(/\s{2,}/g," "),c=c.replace(/\s+=/g,"=").replace(/=\s+/g,"="),c=c.replace(/<!--[\s\S]*?-->/g,""),c.trim()}catch{return n}},IconPickerField=({value:n,onChange:c,id:d})=>{const{t:x}=reactI18next.useTranslation(),[b,y]=React.useState(n||"");React.useEffect(()=>{y(n||"")},[n]);const R=S=>{y(S);const _=sanitizeSvg(S);c(_)};return jsxRuntime.jsxs("div",{className:"mt-1 flex flex-col gap-2",id:"icon-picker-field",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-x-2",children:[jsxRuntime.jsx("div",{className:"flex h-12 w-12 items-center justify-center overflow-hidden rounded-lg border bg-gray-50",children:b?jsxRuntime.jsx("div",{className:"h-6 w-6",dangerouslySetInnerHTML:{__html:b}}):jsxRuntime.jsx("span",{className:"text-xs text-gray-400",children:"SVG"})}),jsxRuntime.jsx("textarea",{id:d,autoCapitalize:"off",autoCorrect:"off",spellCheck:"false",value:b,onChange:S=>R(S.target.value),placeholder:x("SVG_code"),rows:2,className:"no-scrollbar w-full rounded-md border border-border bg-background px-3 py-1.5 text-xs shadow-sm transition-colors placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50"})]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx("div",{className:"text-xs text-muted-foreground",children:"Loading..."}),children:jsxRuntime.jsx(IconPicker,{onSelectIcon:R})}),jsxRuntime.jsx("p",{className:"text-xs text-muted-foreground",children:x("Paste SVG_code")})]})]})},DefaultMediaManager=({close:n,onSelect:c,mode:d="image"})=>{const[x,b]=React.useState(""),[y,R]=React.useState(!1),[S,_]=React.useState(!1),[A,L]=React.useState(null),T=async U=>{if(!U.trim()){_(!1),L("Please enter a URL");return}try{R(!0),L(null),_(!0),L(null)}catch{_(!1),L("Error validating URL")}finally{R(!1)}},{t:O}=reactI18next.useTranslation();return jsxRuntime.jsxs("div",{className:"flex w-96 flex-col gap-4 p-4",children:[jsxRuntime.jsx("h2",{className:"text-xl font-semibold",children:O(`${d.charAt(0).toUpperCase()+d.slice(1)} Manager`)}),A&&jsxRuntime.jsxs(tooltip.Alert,{variant:"destructive",children:[jsxRuntime.jsx(reactIcons.ExclamationTriangleIcon,{className:"h-4 w-4"}),jsxRuntime.jsx(tooltip.AlertDescription,{children:A})]}),jsxRuntime.jsxs("div",{className:"flex flex-col gap-4",children:[jsxRuntime.jsx(tooltip.Input,{placeholder:O(`Enter ${d} URL`),value:x,onChange:U=>b(U.target.value),onKeyUp:()=>T(x)}),jsxRuntime.jsxs("div",{className:"flex justify-end gap-2",children:[jsxRuntime.jsx(tooltip.Button,{variant:"outline",onClick:n,children:O("Cancel")}),jsxRuntime.jsx(tooltip.Button,{onClick:()=>c({id:"dam-id",url:x,width:600,height:400,description:"This is image description"}),disabled:!S||y,children:O("Insert")})]})]})]})},MEDIA_MANAGER={component:DefaultMediaManager},registerChaiMediaManager=n=>{MEDIA_MANAGER.component=n},useMediaManagerComponent=()=>React.useMemo(()=>MEDIA_MANAGER.component,[]),MediaManagerModal=({assetId:n,children:c,onSelect:d,mode:x="image"})=>{const[b,y]=React.useState(!1),R=useMediaManagerComponent(),S=(..._)=>{d.call(void 0,..._),y(!1)};return jsxRuntime.jsxs(tooltip.Dialog,{open:b,onOpenChange:_=>y(_),children:[jsxRuntime.jsx(tooltip.DialogTrigger,{asChild:!0,children:c}),jsxRuntime.jsxs(tooltip.DialogContent,{className:"flex max-h-[90vh] max-w-7xl border-border md:w-fit",children:[jsxRuntime.jsx(tooltip.DialogTitle,{className:"sr-only",children:"Media Manager"}),jsxRuntime.jsx("div",{className:"h-full w-full",children:R?jsxRuntime.jsx(R,{close:()=>y(!1),onSelect:S,mode:x,assetId:n}):null})]})]})};MediaManagerModal.displayName="MediaManagerModal";const PLACEHOLDER_IMAGE="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cmVjdCB3aWR0aD0iMTAwJSIgaGVpZ2h0PSIxMDAlIiBmaWxsPSIjZjNmNGY2Ii8+PHRleHQgeD0iNTAlIiB5PSI1MCUiIGZvbnQtZmFtaWx5PSJBcmlhbCwgc2Fucy1zZXJpZiIgZm9udC1zaXplPSIxNiIgZmlsbD0iI2Q1ZDdkYSIgdGV4dC1hbmNob3I9Im1pZGRsZSIgZHk9Ii4zZW0iPkltYWdlIFBsYWNlaG9sZGVyPC90ZXh0Pjwvc3ZnPg==",getFileName=n=>{var b;if(!n||lodashEs.startsWith(n,"data"))return"";const c=((b=n.split("/").pop())==null?void 0:b.split("?")[0])||"";return[".jpg",".jpeg",".png",".gif",".webp",".svg",".bmp",".ico",".avif"].some(y=>c.toLowerCase().endsWith(y))?c:""},ImagePickerField=({value:n,onChange:c,id:d,onBlur:x})=>{const{t:b}=reactI18next.useTranslation(),{selectedLang:y}=useLanguages(),R=useSelectedBlock(),S=useUpdateBlocksProps(),_=usePageExternalData(),A=d.split(".").pop()||"",L=y?`_${A}Id-${y}`:`_${A}Id`,T=lodashEs.isEmpty(y)&&(R==null?void 0:R._type)==="Image"&&lodashEs.has(R,"assetId"),O=lodashEs.get(R,L,T?R==null?void 0:R.assetId:""),U=React.useMemo(()=>{if(!n||!R||!/\{\{.*?\}\}/.test(n))return n;const ae={...R,[A]:n},Re=applyBinding.applyBindingToBlockProps(ae,_,{index:-1,key:""});return lodashEs.get(Re,A,n)},[n,R,_,A]),M=!!O||U!==PLACEHOLDER_IMAGE,D=ee=>{const ae=lodashEs.isArray(ee)?lodashEs.first(ee):ee;if(ae){c(ae==null?void 0:ae.url);const Re=ae==null?void 0:ae.width,ye=ae==null?void 0:ae.height,de=L.includes("mobile");if(R!=null&&R._id){const q={...Re&&{[de?"mobileWidth":"width"]:Re},...ye&&{[de?"mobileHeight":"height"]:ye},...ae.description&&{alt:ae.description}};if(lodashEs.set(q,L,ae.id),lodashEs.isEmpty(q))return;S([R._id],q)}}},K=React.useCallback(()=>{if(c(PLACEHOLDER_IMAGE),R!=null&&R._id){const ee={},ae=L.includes("mobile");lodashEs.set(ee,L,""),lodashEs.set(ee,ae?"mobileWidth":"width",""),lodashEs.set(ee,ae?"mobileHeight":"height",""),S([R._id],ee)}},[c,R==null?void 0:R._id,S,L]),$=getFileName(U);return jsxRuntime.jsxs("div",{className:"mt-1.5 flex items-start gap-x-3",children:[U?jsxRuntime.jsxs("div",{className:"group relative",children:[jsxRuntime.jsx("img",{src:U,className:"h-14 w-14 overflow-hidden rounded-md border border-border object-cover transition duration-200 "+(O&&O!==""?"cursor-pointer group-hover:blur-sm":""),alt:""}),M&&jsxRuntime.jsx("button",{type:"button",onClick:K,className:"absolute -right-2 -top-2 z-20 rounded-full bg-destructive p-1 text-destructive-foreground hover:bg-destructive/90",children:jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-3 w-3"})}),O&&O!==""&&jsxRuntime.jsx(MediaManagerModal,{onSelect:D,assetId:O,children:jsxRuntime.jsx("button",{type:"button",className:"absolute inset-0 z-10 flex cursor-pointer items-center justify-center bg-black/10 opacity-0 transition duration-200 group-hover:bg-black/30 group-hover:opacity-100",children:jsxRuntime.jsx(reactIcons.Pencil2Icon,{className:"h-4 w-4 text-white"})})})]}):jsxRuntime.jsx(MediaManagerModal,{onSelect:D,mode:"image",assetId:O,children:jsxRuntime.jsx("div",{className:"h-14 w-14 cursor-pointer rounded-md border border-border bg-[radial-gradient(#AAA,transparent_1px)] duration-300 [background-size:10px_10px]"})}),jsxRuntime.jsxs("div",{className:"flex w-3/5 flex-col",children:[jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("p",{className:"max-w-[250px] truncate pr-2 text-xs text-gray-400",children:$}),jsxRuntime.jsx(MediaManagerModal,{onSelect:D,assetId:"",children:jsxRuntime.jsx("small",{className:"h-6 mb-1 w-full cursor-pointer rounded-md bg-secondary px-1 py-1 text-center text-xs text-secondary-foreground hover:bg-secondary/80",children:!lodashEs.isEmpty(U)&&U!==PLACEHOLDER_IMAGE?b("Replace image"):b("Choose image")})}),jsxRuntime.jsx("div",{className:"text-center text-xs text-gray-400",children:"OR"})]}),jsxRuntime.jsx("input",{id:d,autoCapitalize:"off",autoCorrect:"off",spellCheck:"false",type:"url",className:"h-6 text-xs",placeholder:b("Enter image URL"),value:n===PLACEHOLDER_IMAGE?"":n,onBlur:({target:{value:ee}})=>x(d,ee),onChange:ee=>c(ee.target.value)})]})]})},PathDropdown=({data:n,onSelect:c,dataType:d})=>{const[x,b]=React.useState([]),[y,R]=React.useState(n),S=T=>Array.isArray(T)?"array":typeof T=="object"&&T!==null?"object":"value",_=React.useCallback(T=>{const O=U=>d==="value"?U==="value"||U==="object":d==="array"?U==="array":U===d;T.type==="object"?(b(U=>[...U,T.key]),R(T.value)):O(T.type)&&c([...x,T.key].join("."),d)},[x,c,d]),A=React.useCallback(()=>{if(x.length>0){const T=x.slice(0,-1);b(T),R(T.reduce((O,U)=>O[U],n))}},[x,n]),L=React.useMemo(()=>y?Object.entries(y).map(([T,O])=>({key:T,value:O,type:S(O)})).filter(T=>!lodashEs.startsWith(T.key,applyBinding.REPEATER_PREFIX)&&T.key.includes("/")?!1:d==="value"?T.type==="value"||T.type==="object":d==="array"?T.type==="array"||T.type==="object":d==="object"?T.type==="object":!0):[],[y,d]);return jsxRuntime.jsxs(tooltip.Command,{className:"fields-command",children:[jsxRuntime.jsx(tooltip.CommandInput,{className:"border-none",placeholder:"Search..."}),jsxRuntime.jsxs(tooltip.CommandList,{children:[jsxRuntime.jsx(tooltip.CommandEmpty,{children:i18n.t("No option found.")}),jsxRuntime.jsxs(tooltip.CommandGroup,{children:[x.length>0&&jsxRuntime.jsxs(tooltip.CommandItem,{onSelect:A,className:"flex items-center text-sm",children:[jsxRuntime.jsx(reactIcons.ChevronLeftIcon,{className:"mr-2 h-4 w-4"}),i18n.t("Back")]}),L.map(T=>jsxRuntime.jsxs(tooltip.CommandItem,{value:T.key,disabled:!1,onSelect:()=>_(T),className:"flex items-center justify-between",children:[jsxRuntime.jsxs("span",{className:"flex items-center gap-x-2",children:[lodashEs.startsWith(T.key,applyBinding.REPEATER_PREFIX)?jsxRuntime.jsx(reactIcons.LoopIcon,{}):lodashEs.startsWith(T.key,applyBinding.COLLECTION_PREFIX)?jsxRuntime.jsx(reactIcons.IdCardIcon,{}):null,lodashEs.startsWith(T.key,applyBinding.REPEATER_PREFIX)?i18n.t("Repeater Data"):lodashEs.startsWith(T.key,applyBinding.COLLECTION_PREFIX)?T.key.replace(applyBinding.COLLECTION_PREFIX,""):T.key]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[d==="object"&&T.type==="object"&&jsxRuntime.jsx(tooltip.Button,{size:"sm",variant:"ghost",className:"h-6 px-2 hover:bg-primary hover:text-primary-foreground",onClick:O=>{O.stopPropagation(),c([...x,T.key].join("."),d)},children:i18n.t("Select")}),T.type==="object"&&jsxRuntime.jsx("div",{className:"cursor-pointer rounded p-1 hover:bg-muted",children:jsxRuntime.jsx(reactIcons.ChevronRightIcon,{className:"h-4 w-4 opacity-50"})})]})]},T.key))]})]})]})};function NestedPathSelector({data:n,onSelect:c,dataType:d="value"}){const[x,b]=React.useState(!1),y=useBuilderProp("collections",[]),R=React.useMemo(()=>d==="array"?{...y.map(_=>_.id).reduce((_,A)=>({..._,[applyBinding.COLLECTION_PREFIX+A]:[]}),{}),...n}:n,[n,y,d]);return jsxRuntime.jsxs(tooltip.Popover,{open:x,onOpenChange:b,children:[jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx(tooltip.PopoverTrigger,{asChild:!0,children:jsxRuntime.jsx(tooltip.Button,{size:"sm",variant:"ghost",className:"h-5 rounded-sm px-1 py-0 text-[9px] text-muted-foreground",role:"combobox","aria-expanded":x,children:jsxRuntime.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24px",height:"24px",viewBox:"0 0 24 24",fill:"none",children:jsxRuntime.jsx("path",{d:"M9.5 5H9C7.89543 5 7 5.89543 7 7V9C7 10 6.4 12 4 12C5 12 7 12.6 7 15V17.0002C7 18.1048 7.89543 19 9 19H9.5M14.5 5H15C16.1046 5 17 5.89543 17 7V9C17 10 17.6 12 20 12C19 12 17 12.6 17 15V17.0002C17 18.1048 16.1046 19 15 19H14.5",stroke:"#000000",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2"})})})})}),jsxRuntime.jsx(tooltip.TooltipContent,{children:i18n.t("Add field")})]}),jsxRuntime.jsx(tooltip.PopoverContent,{className:"z-[1000]! relative mr-3 w-[300px] p-0",children:jsxRuntime.jsx(PathDropdown,{data:R,onSelect:(S,_)=>{c(S,_),b(!1)},dataType:d})})]})}const DataBindingSelector=({schema:n,onChange:c,id:d,formData:x})=>{const b=usePageExternalData(),y=useBuilderProp("flags.dataBinding",!0),R=useSelectedBlockHierarchy(),S=useSelectedBlock(),_=React.useMemo(()=>{if(R.length===1)return"";const T=R.find(M=>M._type==="Repeater"),U=lodashEs.get(T,"repeaterItems","").replace(/\{\{(.*)\}\}/g,"$1");return`${applyBinding.REPEATER_PREFIX}${lodashEs.startsWith(U,applyBinding.COLLECTION_PREFIX)?`${U}/${T._id}`:U}`},[R]),A=React.useMemo(()=>lodashEs.first(lodashEs.get(b,_.replace(applyBinding.REPEATER_PREFIX,""),[])),[_,b]),L=React.useCallback((T,O)=>{if(T=lodashEs.isEmpty(_)?T:T.replace(`${_}`,"$index"),O==="array"||O==="object"){c(`{{${T}}}`,{},d);return}const U=$=>/[.,!?;:]/.test($),M=($,ee,ae)=>{let Re="",ye="";const de=ee>0?$[ee-1]:"",q=ee<$.length?$[ee]:"";return ee>0&&(de==="."||!U(de)&&de!==" ")&&(Re=" "),ee<$.length&&!U(q)&&q!==" "&&(ye=" "),{text:Re+ae+ye,prefixLength:Re.length,suffixLength:ye.length}},D=document.getElementById(d);if(!D)return;const K=document.getElementById(`chai-rte-${d}`)||document.getElementById(`chai-rte-modal-${d}`);if(K&&(K.querySelector(".ProseMirror")||K.__chaiRTE)){const $=K.__chaiRTE;if($){const ee=`{{${T}}}`;$.commands.focus();const{from:ae,to:Re}=$.state.selection;if(ae!==Re)$.chain().deleteSelection().insertContent(ee).run();else{const{state:de}=$,q=de.selection.from,he=de.doc.textBetween(Math.max(0,q-1),q),le=de.doc.textBetween(q,Math.min(q+1,de.doc.content.size));let xe="";q>0&&he!==" "&&!U(he)&&(xe=" ");let Ee="";le&&le!==" "&&!U(le)&&(Ee=" "),$.chain().insertContent(xe+ee+Ee).run()}setTimeout(()=>c($.getHTML(),{},d),100);return}}else{const $=D,ee=$.selectionStart||0,ae=$.value||"",Re=$.selectionEnd||ee;if(Re>ee){const le=`{{${T}}}`,{text:xe}=M(ae,ee,le),Ee=ae.slice(0,ee)+xe+ae.slice(Re);c(Ee,{},d);return}const de=`{{${T}}}`,{text:q}=M(ae,ee,de),he=ae.slice(0,ee)+q+ae.slice(ee);c(he,{},d)}},[d,c,x,S==null?void 0:S._id,_]);return y?jsxRuntime.jsx(NestedPathSelector,{data:{...A&&{[_]:A},...b},onSelect:L,dataType:n.binding==="array"?"array":"value"}):null},PageTypeField=({href:n,pageTypes:c,onChange:d})=>{var he;const{t:x}=reactI18next.useTranslation(),b=useBuilderProp("searchPageTypeItems",(le,xe)=>[]),[y,R]=React.useState(!1),[S,_]=React.useState(!1),[A,L]=React.useState("page"),[T,O]=React.useState(""),[U,M]=React.useState([]),[D,K]=React.useState(-1),$=React.useRef(null),ee=(he=c==null?void 0:c.find(le=>le.key===A))==null?void 0:he.name;React.useEffect(()=>{if(O(""),M([]),K(-1),_(!1),!n||y||!lodashEs.startsWith(n,"pageType:"))return;const le=lodashEs.split(n,":"),xe=lodashEs.get(le,1,"page")||"page";L(xe),(async()=>{const Ee=await b(xe,[lodashEs.get(le,2,"page")]);Ee&&Array.isArray(Ee)&&O(lodashEs.get(Ee,[0,"name"],""))})()},[n]);const ae=web.useDebouncedCallback(async le=>{if(lodashEs.isEmpty(le))M([]);else{const xe=await b(A,le);M(xe)}R(!1),K(-1)},[A],300),Re=le=>{const xe=["pageType",A,le.id];xe[1]&&(d(xe.join(":")),O(le.name),_(!1),M([]),K(-1))},ye=le=>{switch(le.key){case"ArrowDown":le.preventDefault(),K(xe=>xe<U.length-1?xe+1:xe);break;case"ArrowUp":le.preventDefault(),K(xe=>xe>0?xe-1:xe);break;case"Enter":if(le.preventDefault(),U.length===0)return;D>=0&&Re(U[D]);break;case"Escape":le.preventDefault(),de();break}};React.useEffect(()=>{if(D>=0&&$.current){const le=$.current.children[D];le==null||le.scrollIntoView({block:"nearest"})}},[D]);const de=()=>{O(""),M([]),K(-1),_(!1),d("")},q=le=>{O(le),_(!lodashEs.isEmpty(le)),R(!0),ae(le)};return jsxRuntime.jsxs("div",{children:[jsxRuntime.jsx("select",{name:"pageType",value:A,onChange:le=>L(le.target.value),children:lodashEs.map(c,le=>jsxRuntime.jsx("option",{value:le.key,children:le.name},le.key))}),A&&jsxRuntime.jsxs("div",{className:"group relative mt-2 flex items-center",children:[jsxRuntime.jsx("input",{type:"text",value:T,onChange:le=>q(le.target.value),onKeyDown:ye,placeholder:x(`Search ${ee??""}`),className:"w-full rounded-md border border-gray-300 p-2 pr-16"}),jsxRuntime.jsx("div",{className:"absolute bottom-2 right-2 top-3 flex items-center gap-1.5",children:T&&jsxRuntime.jsx("button",{onClick:de,className:"text-gray-400 hover:text-gray-600",title:x("Clear search"),children:jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-4 w-4"})})})]}),(y||!lodashEs.isEmpty(U)||S&&lodashEs.isEmpty(U))&&jsxRuntime.jsx("div",{className:"absolute z-40 mt-2 max-h-40 w-full max-w-[250px] overflow-y-auto rounded-md border border-border bg-background shadow-lg",children:y?jsxRuntime.jsxs("div",{className:"space-y-1 p-2",children:[jsxRuntime.jsx("div",{className:"h-6 w-full animate-pulse rounded bg-gray-200"}),jsxRuntime.jsx("div",{className:"h-6 w-full animate-pulse rounded bg-gray-200"})]}):S&&lodashEs.isEmpty(U)?jsxRuntime.jsxs("div",{className:"flex items-center justify-center p-4 text-sm text-gray-500",children:[x("No results found for"),' "',T,'"']}):jsxRuntime.jsx("ul",{ref:$,children:lodashEs.map(U==null?void 0:U.slice(0,20),(le,xe)=>jsxRuntime.jsxs("li",{onClick:()=>Re(le),className:`cursor-pointer p-2 text-xs ${n!=null&&n.includes(le.id)?"bg-blue-200":xe===D?"bg-gray-100":"hover:bg-gray-100"}`,children:[le.name," ",le.slug&&jsxRuntime.jsxs("small",{className:"font-light text-gray-500",children:["( ",le.slug," )"]})]},le.id))})})]})},LinkField=({schema:n,formData:c,onChange:d,name:x})=>{const{t:b}=reactI18next.useTranslation(),{type:y="pageType",href:R="",target:S="self"}=c??{},_=useBuilderProp("pageTypes",[]),{selectedLang:A,fallbackLang:L,languages:T}=useLanguages(),O=React.useMemo(()=>lodashEs.isEmpty(T)?"":lodashEs.isEmpty(A)?L:A,[T,A,L]),U=React.useMemo(()=>lodashEs.get(LANGUAGES,O,O),[O]),M=y==="pageType"&&lodashEs.isEmpty(_)?"url":y;return jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("span",{className:"flex items-center justify-between gap-x-2 text-xs font-medium",children:[jsxRuntime.jsxs("span",{children:[(n==null?void 0:n.title)??"Link",jsxRuntime.jsx("span",{className:"pl-1 text-[9px] text-zinc-400",children:U})]}),jsxRuntime.jsx(DataBindingSelector,{schema:n,onChange:D=>{d({...c,href:D,...M==="pageType"?{type:"url"}:{}})},id:`root.${x}.href`,formData:c})]}),jsxRuntime.jsxs("div",{className:"flex flex-col gap-y-1.5",children:[jsxRuntime.jsx("select",{name:"type",value:y,onChange:D=>d({...c,type:D.target.value}),children:lodashEs.map([...lodashEs.isEmpty(_)?[]:[{const:"pageType",title:b("Goto Page")}],{const:"url",title:b("Open URL")},{const:"email",title:b("Compose Email")},{const:"telephone",title:b("Call Phone")},{const:"scroll",title:b("Scroll to element")}],D=>jsxRuntime.jsx("option",{value:D.const,children:D.title},D.const))}),M==="pageType"&&!lodashEs.isEmpty(_)?jsxRuntime.jsx(PageTypeField,{href:R,pageTypes:_,onChange:D=>d({...c,href:D})}):null,jsxRuntime.jsx("input",{id:`root.${x}.href`,autoCapitalize:"off",autoCorrect:"off",spellCheck:"false",name:"href",type:"text",className:M==="pageType"?"!hidden":"",value:R,onChange:D=>d({...c,href:D.target.value}),placeholder:b(y==="url"?"Enter URL":y==="scroll"?"#ElementID":"Enter details")}),M==="url"&&jsxRuntime.jsxs("div",{className:"flex items-center gap-x-2 text-muted-foreground",children:[jsxRuntime.jsx("input",{id:`root.${x}.target`,autoCapitalize:"off",autoCorrect:"off",spellCheck:"false",type:"checkbox",defaultChecked:S==="_blank",className:"!w-fit cursor-pointer rounded-md border border-border",onChange:()=>d({...c,target:S==="_blank"?"_self":"_blank"})}),jsxRuntime.jsx("span",{className:"pt-1 text-xs",children:b("Open in new tab")})]})]})]})},RowColField=()=>{const n=useSelectedBlock(),c=useWrapperBlock(),{addCoreBlock:d}=useAddBlock();if(!n&&!c)return null;const x=(n==null?void 0:n._type)==="Row"?n:c;return jsxRuntime.jsx("div",{className:"pt-1",children:jsxRuntime.jsxs("button",{type:"button",className:"duratiom-300 flex items-center gap-x-1 rounded border border-gray-400 bg-gray-100 px-4 py-1 text-[11px] font-medium leading-tight hover:bg-slate-200",onClick:()=>d({type:"Column",styles:"#styles:,"},x==null?void 0:x._id),children:[jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-4 w-4"})," Add Column"]})})},RTEModal=React.lazy(()=>Promise.resolve().then(()=>require("./rte-widget-modal-BaiE-vjR.cjs"))),RichTextEditorFieldComp=({blockId:n,id:c,placeholder:d,value:x,onChange:b,onBlur:y})=>{const R=React.useRef(null),[S,_]=React.useState(!1),A=useRTEditor({blockId:n,value:x,placeholder:d,onBlur:({editor:O})=>{const U=O==null?void 0:O.getHTML();y(c,U)},onUpdate:({editor:O})=>{const U=O==null?void 0:O.getHTML();b(U)}});React.useEffect(()=>{R.current&&A&&(R.current.__chaiRTE=A)},[n,A]);const L=()=>{_(!1)},T=jsxRuntime.jsxs("div",{id:`chai-rte-${c}`,ref:R,className:"mt-1 rounded-md border border-input",children:[jsxRuntime.jsx(RteMenubar,{editor:A,onExpand:()=>_(!0)}),jsxRuntime.jsx(react.EditorContent,{editor:A,id:c,placeholder:d,className:`overflow-auto ${S?"max-h-[500px] min-h-[400px]":"max-h-[200px] min-h-[100px]"}`},c)]});return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[S&&jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx("div",{children:"Loading..."}),children:jsxRuntime.jsx(RTEModal,{isOpen:S,onClose:L,editor:A,rteElement:T})}),S?jsxRuntime.jsx("div",{children:"Open in modal"}):jsxRuntime.jsx("div",{className:"relative",children:T})]})},RichTextEditorField=n=>{const{editingBlockId:c}=useInlineEditing(),[d,x]=React.useState(null),b=useSelectedBlock(),y=b==null?void 0:b._id;return React.useEffect(()=>{x(y)},[y]),d&&d!==c?jsxRuntime.jsx(RichTextEditorFieldComp,{...n,blockId:d},d):null},SliderField=({formData:n,onChange:c})=>{const[d]=useBlocksStore(),x=useSelectedBlock(),b=useWrapperBlock(),{addCoreBlock:y}=useAddBlock(),[,R]=useSelectedBlockIds();if(!x&&!b)return null;const S=(x==null?void 0:x._type)==="Slider"?x:b,_=lodashEs.find(d,{_parent:S==null?void 0:S._id,_type:"Slides"});if(!_)return null;const A=lodashEs.filter(d,{_parent:_==null?void 0:_._id,_type:"Slide"}),L=(n==null?void 0:n.currentSlide)||lodashEs.get(A,"0._id");React.useEffect(()=>{(x==null?void 0:x._type)==="Slide"&&(n==null?void 0:n.currentSlide)!==(x==null?void 0:x._id)&&c({...n,currentSlide:x==null?void 0:x._id})},[x]),React.useEffect(()=>{A!=null&&A.length&&!lodashEs.find(A,{_id:n==null?void 0:n.currentSlide})&&c({...n,currentSlide:lodashEs.get(A,"0._id")})},[n,A]);const T=()=>{const M=lodashEs.findIndex(A,{_id:L});if(M>-1){const D=(M+1)%A.length,K=lodashEs.get(A,[D,"_id"]);if(!K)return;c({...n,currentSlide:K}),R([K])}},O=()=>{const M=lodashEs.findIndex(A,{_id:L});if(M>-1){const D=(M-1+A.length)%A.length,K=lodashEs.get(A,[D,"_id"]);if(!K)return;c({...n,currentSlide:K}),R([K])}},U=()=>{const M=y({styles:"#styles:,h-full w-full min-w-full",type:"Slide"},_==null?void 0:_._id),D=M==null?void 0:M._id;D&&(c({...n,currentSlide:D}),R([D]))};return jsxRuntime.jsxs("div",{className:"space-y-1.5 px-2",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-x-2 pb-2 text-[12px]",children:[jsxRuntime.jsx("button",{onClick:O,className:"rounded bg-gray-200 p-1.5 hover:opacity-80",children:jsxRuntime.jsx(reactIcons.ChevronLeftIcon,{className:"h-3 w-3"})}),jsxRuntime.jsx("div",{className:"whitespace-nowrap text-center text-[10px] text-slate-500",children:L?jsxRuntime.jsxs("span",{className:"",children:[jsxRuntime.jsxs("b",{className:"text-[12px]",children:[" ",lodashEs.findIndex(A,{_id:L})+1]}),"/",A.length]}):"-"}),jsxRuntime.jsx("button",{onClick:T,className:"rounded bg-gray-200 p-1.5 hover:opacity-80",children:jsxRuntime.jsx(reactIcons.ChevronRightIcon,{className:"h-3 w-3"})}),jsxRuntime.jsxs("button",{onClick:U,className:"flex w-full items-center justify-center gap-x-1 rounded bg-gray-200 p-1.5 text-xs font-medium leading-tight hover:opacity-80",children:[jsxRuntime.jsx(reactIcons.PlusCircledIcon,{className:"h-3 w-3"}),"Add Slide"]})]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-x-2 leading-tight",children:[jsxRuntime.jsx("input",{type:"checkbox",checked:!!(n!=null&&n.showSlideButton),onChange:()=>c({...n,showSlideButton:!(n!=null&&n.showSlideButton)}),className:"cursor-pointer"}),jsxRuntime.jsx("label",{htmlFor:"autoplay",className:"mt-0.5 text-[12px]",children:"Show Slide Buttons"})]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-x-2 leading-tight",children:[jsxRuntime.jsx("input",{type:"checkbox",checked:!!(n!=null&&n.showSlideNavbar),onChange:()=>c({...n,showSlideNavbar:!(n!=null&&n.showSlideNavbar)}),className:"cursor-pointer"}),jsxRuntime.jsx("label",{htmlFor:"autoplay",className:"mt-0.5 text-[12px]",children:"Show Slide Navbar"})]}),jsxRuntime.jsx("div",{children:jsxRuntime.jsxs("div",{className:"flex flex-col",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-x-2 leading-tight",children:[jsxRuntime.jsx("input",{type:"checkbox",checked:!!(n!=null&&n.autoplay),onChange:()=>c({...n,autoplay:!(n!=null&&n.autoplay)}),className:"cursor-pointer"}),jsxRuntime.jsx("label",{htmlFor:"autoplay",className:"mt-0.5 text-[12px]",children:"Autoplay slides"})]}),(n==null?void 0:n.autoplay)&&jsxRuntime.jsxs("div",{className:"pt-0.5 leading-tight",children:[jsxRuntime.jsxs("label",{htmlFor:"interval",className:"whitespace-nowrap text-[9px]",children:["Autoplay Interval ",jsxRuntime.jsx("span",{className:"font-light opacity-80",children:"(in seconds)"})]}),jsxRuntime.jsx("input",{type:"number",id:"interval",name:"interval",placeholder:"0",value:n==null?void 0:n.autoplayInterval,className:"text-xs",pattern:"[0-9]*",onChange:M=>{let D=M.target.value;D.length&&(D=D.replace("-","")),c({...n,autoplayInterval:D})}})]})]})})]})},SourcesField=({formData:n,onChange:c})=>{const d=lodashEs.get(n,"srcsets",[])||[],x=(R,S)=>{const _=R.target.name,A=R.target.value;c({srcsets:lodashEs.map(d,(L,T)=>T===S?{...L,[_]:A}:L)})},b=()=>{c({srcsets:[...d,{}]})},y=R=>{c({srcsets:lodashEs.reject(d,(S,_)=>_===R)})};return jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("div",{className:"flex items-center justify-between pb-2",children:[jsxRuntime.jsx("label",{children:"Responsive Video (optional)"}),jsxRuntime.jsx("button",{type:"button",onClick:b,className:"flex items-center gap-x-1 rounded-md border border-blue-500 bg-blue-100 px-2 py-px text-xs text-blue-600 hover:opacity-80",children:jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-3 w-3"})})]}),jsxRuntime.jsx("div",{className:"space-y-2",children:d.length===0?jsxRuntime.jsx("div",{className:"rounded border border-dashed border-gray-200 p-2 text-xs italic text-gray-500",children:"Add additional sources to create responsive videos"}):lodashEs.map(d,(R,S)=>jsxRuntime.jsxs("div",{className:"group relative space-y-1.5 rounded border border-gray-200 px-2 pb-1.5",children:[jsxRuntime.jsx("button",{type:"button",onClick:()=>y(S),className:"absolute -right-px -top-0 -translate-y-1/2 rounded-full bg-red-100 p-1 opacity-0 hover:bg-red-200 group-hover:opacity-100",children:jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-2.5 w-2.5 text-red-500"})}),jsxRuntime.jsxs("div",{className:"flex items-center gap-x-2 rounded border",children:[jsxRuntime.jsx("label",{className:"flex !h-6 h-full w-1/4 items-center justify-center bg-gray-200 px-2 !text-[10px] !font-medium",children:"Width"}),jsxRuntime.jsx("input",{name:"width",placeholder:"Enter width (in px)",type:"number",value:lodashEs.get(R,"width"),onChange:_=>x(_,S),className:"!placeholder:text-gray-100 !mt-0 !rounded-none !border-0 !p-0 !text-xs"})]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-x-2 rounded border",children:[jsxRuntime.jsx("label",{className:"flex !h-6 h-full w-1/4 items-center justify-center bg-gray-200 px-2 !text-[10px] !font-medium",children:"URL"}),jsxRuntime.jsx("input",{name:"url",placeholder:"Enter url",className:"!mt-0 !rounded-none !border-0 !p-0 !text-xs !shadow-none",value:lodashEs.get(R,"url",""),onChange:_=>x(_,S)})]})]},S))})]})},CodeEditor=({id:n,placeholder:c})=>{const{t:d}=reactI18next.useTranslation(),[,x]=useCodeEditor(),b=useSelectedBlock();if(typeof window>"u")return null;const y=n.replace("root.",""),R=lodashEs.get(b,y,""),S=()=>{const _=b==null?void 0:b._id;x({blockId:_,blockProp:y,placeholder:c,initialCode:lodashEs.get(b,y,R)})};return jsxRuntime.jsxs("div",{className:"mt-2 flex flex-col gap-y-1",children:[jsxRuntime.jsx("button",{onClick:S,className:"w-[90%] max-w-full cursor-default truncate text-pretty rounded border border-border bg-background p-2 text-left text-[10px]",children:R.trim().length>0?R.substring(0,46):c||"Eg: <script>console.log('Hello, world!');<\/script>"}),jsxRuntime.jsx(tooltip.Button,{onClick:S,size:"sm",variant:"outline",className:"w-fit",children:d("Open code editor")})]})},CollectionFilterSortField=({id:n,value:c,onChange:d,onBlur:x})=>{const b=useBuilderProp("collections",[]),y=useSelectedBlock(),R=lodashEs.get(y,"repeaterItems","").replace(/\{\{(.*)\}\}/g,"$1").replace(applyBinding.COLLECTION_PREFIX,""),S=lodashEs.find(b,{id:R}),_=n==="root.filter"?"filters":"sorts",A=lodashEs.get(S,_,[]);return jsxRuntime.jsx("div",{children:jsxRuntime.jsxs("select",{value:c,onChange:L=>d(L.target.value),onBlur:L=>x(n,L.target.value),children:[jsxRuntime.jsx("option",{value:"",children:"Select"}),A.map(L=>jsxRuntime.jsx("option",{value:L.id,children:L.name},L.id))]})})},JSONFormFieldTemplate=n=>{const{id:c,classNames:d,label:x,children:b,errors:y,help:R,hidden:S,required:_,schema:A,formData:L,onChange:T}=n,{selectedLang:O,fallbackLang:U,languages:M}=useLanguages(),D=React.useMemo(()=>lodashEs.isEmpty(M)?"":lodashEs.isEmpty(O)?U:O,[M,O,U]),K=React.useMemo(()=>lodashEs.get(LANGUAGES,D,D),[D]),$=usePageExternalData(),ee=useSelectedBlock(),ae=runtime.useRegisteredChaiBlocks(),Re=React.useMemo(()=>lodashEs.get(ae,[ee==null?void 0:ee._type,"i18nProps"],[]),[ae,ee==null?void 0:ee._type]),[ye,de]=React.useState(null);if(S)return null;if(A.type==="boolean")return jsxRuntime.jsx("div",{className:d,children:b});const he=Re==null?void 0:Re.includes(c.replace("root.",""));if(A.type==="array"){const Ee=ye===c;return jsxRuntime.jsxs("div",{className:`${d} relative`,children:[A.title&&jsxRuntime.jsx("div",{className:"flex items-center justify-between gap-1",children:jsxRuntime.jsxs("label",{htmlFor:c,onClick:()=>de(Ee?null:c),className:"flex cursor-pointer items-center gap-x-1 py-1 leading-tight duration-200 hover:bg-slate-100",children:[Ee?jsxRuntime.jsx(reactIcons.ChevronDownIcon,{className:"h-3 w-3"}):jsxRuntime.jsx(reactIcons.ChevronRightIcon,{className:"h-3 w-3"}),jsxRuntime.jsx(reactIcons.ListBulletIcon,{className:"h-3 w-3"}),jsxRuntime.jsx("span",{className:"leading-tight",children:x})," ",jsxRuntime.jsx(tooltip.Badge,{className:"m-0 bg-gray-200 px-2 leading-tight text-gray-500 hover:bg-gray-200 hover:text-gray-500",children:jsxRuntime.jsx("span",{className:"text-[9px] font-medium text-slate-600",children:L==null?void 0:L.length})}),A.description&&jsxRuntime.jsx(tooltip.TooltipProvider,{children:jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx(reactIcons.InfoCircledIcon,{className:"h-3 w-3 text-muted-foreground/70",onClick:je=>je.stopPropagation(),onMouseDown:je=>je.stopPropagation()})}),jsxRuntime.jsx(tooltip.TooltipContent,{className:"max-w-xs",children:A.description})]})})]})}),(L==null?void 0:L.length)===0?jsxRuntime.jsx("div",{className:"h-0 overflow-hidden",children:b}):jsxRuntime.jsxs("div",{className:`${Ee?"pt-0.5":"h-0 overflow-hidden"}`,children:[b,y,R]})]})}const le=c.replace("root.",""),xe=Re.includes(le)&&!lodashEs.isEmpty(O)&&lodashEs.isEmpty(L);return jsxRuntime.jsxs("div",{className:d,children:[A.title&&jsxRuntime.jsxs("div",{className:"flex items-center justify-between",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsxs("label",{htmlFor:c,className:A.type==="object"?"pb-2":"",children:[x," ",he&&jsxRuntime.jsxs("small",{className:"text-[9px] text-zinc-400",children:[" ",K]}),_&&A.type!=="object"?" *":null]}),A.description&&jsxRuntime.jsx(tooltip.TooltipProvider,{children:jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx(reactIcons.InfoCircledIcon,{className:"h-3 w-3 text-muted-foreground/70"})}),jsxRuntime.jsx(tooltip.TooltipContent,{className:"max-w-xs",children:A.description})]})})]}),!A.enum&&!A.oneOf&&$&&jsxRuntime.jsxs("span",{className:"flex items-center space-x-1",children:[xe?jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",className:"lucide lucide-triangle-alert-icon lucide-triangle-alert h-3 w-3 text-orange-400",children:[jsxRuntime.jsx("path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3"}),jsxRuntime.jsx("path",{d:"M12 9v4"}),jsxRuntime.jsx("path",{d:"M12 17h.01"})]})}),jsxRuntime.jsxs(tooltip.TooltipContent,{className:"max-w-xs",children:["No translation provided. ",jsxRuntime.jsx("br",{}),"Using default language value."]})]}):null,jsxRuntime.jsx(DataBindingSelector,{schema:A,onChange:Ee=>{T(Ee,L,c)},id:c,formData:L})]})]}),b,y,R]})},RepeaterBindingWidget=({value:n,onChange:c})=>{var y;if(!n)return jsxRuntime.jsxs("div",{className:"mt-1 flex items-center gap-2 rounded-md border border-gray-200 bg-gray-50 px-2 py-1.5 text-xs text-gray-500 text-gray-600",children:[jsxRuntime.jsx(reactIcons.FileIcon,{className:"h-4 w-4"})," Choose a collection"]});const d=`{{${applyBinding.COLLECTION_PREFIX}`,x=n==null?void 0:n.startsWith(d);let b=n;return x&&(b=(y=n==null?void 0:n.replace(d,""))==null?void 0:y.replace("}}","")),jsxRuntime.jsx("div",{className:"mt-1 flex flex-col gap-1",children:jsxRuntime.jsxs("div",{className:"flex items-center justify-between gap-2 rounded-md border border-blue-200 bg-blue-50 px-2 py-1 text-xs text-blue-600",children:[jsxRuntime.jsxs("span",{className:"flex max-w-[200px] items-center gap-2",children:[" ",x?jsxRuntime.jsx(reactIcons.IdCardIcon,{className:"h-3 min-h-3 w-3 min-w-3"}):null,jsxRuntime.jsxs(tooltip.Tooltip,{delayDuration:500,children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx("span",{className:"cursor-default truncate",children:b})}),jsxRuntime.jsx(tooltip.TooltipContent,{side:"left",hidden:b.length<50,children:b})]})]}),jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx(tooltip.Button,{variant:"ghost",size:"icon",className:"h-5 w-5 rounded-full bg-gray-200 text-gray-900 hover:bg-gray-300",onClick:()=>c(""),children:jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-4 w-4"})})}),jsxRuntime.jsx(tooltip.TooltipContent,{side:"left",children:"Remove binding"})]})]})})},CustomAddButton=n=>jsxRuntime.jsx("button",{...n,className:"duration absolute right-2 top-2 cursor-pointer text-blue-400 hover:text-blue-500",children:jsxRuntime.jsxs("div",{className:"flex items-center gap-x-0.5 text-[11px] leading-tight",children:[jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-3 w-3"})," ",jsxRuntime.jsx("span",{children:"Add"})]})}),JSONForm=React.memo(({blockId:n,schema:c,uiSchema:d,formData:x,onChange:b})=>{const{selectedLang:y}=useLanguages(),R=useBlockSettingComponents("widget"),S=useBlockSettingComponents("field"),_=useBlockSettingComponents("template"),A=web.useThrottledCallback(async({formData:L},T)=>{lodashEs.get(L,T)===void 0&&lodashEs.set(L,T,""),b({formData:L},T)},[b,y],400);return jsxRuntime.jsx(RjForm,{widgets:{richtext:RichTextEditorField,icon:IconPickerField,image:ImagePickerField,code:CodeEditor,colCount:RowColField,collectionSelect:CollectionFilterSortField,repeaterBinding:RepeaterBindingWidget,...R},fields:{link:LinkField,slider:SliderField,sources:SourcesField,...S},templates:{FieldTemplate:JSONFormFieldTemplate,ButtonTemplates:{AddButton:CustomAddButton},..._},idSeparator:".",autoComplete:"off",omitExtraData:!1,liveOmit:!1,liveValidate:!1,validator,uiSchema:d,schema:c,formData:x,onChange:({formData:L},T)=>{if(!T||n!==(L==null?void 0:L._id))return;const O=lodashEs.take(T.split("."),2).join(".").replace("root.","");A({formData:L},O)}},y)}),formDataWithSelectedLang=(n,c,d)=>{const x=lodashEs.cloneDeep(n);return lodashEs.forEach(lodashEs.keys(n),b=>{lodashEs.includes(lodashEs.get(d,"i18nProps",[]),b)&&!lodashEs.isEmpty(c)&&(x[b]=lodashEs.get(n,`${b}-${c}`))}),x};function BlockSettings(){const{selectedLang:n}=useLanguages(),c=useSelectedBlock(),d=useUpdateBlocksPropsRealtime(),x=useUpdateBlocksProps(),b=runtime.getRegisteredChaiBlock(c==null?void 0:c._type),y=formDataWithSelectedLang(c,n,b),[R,S]=React.useState(y),[_,A]=React.useState(!1),L=useWrapperBlock(),T=runtime.getRegisteredChaiBlock(L==null?void 0:L._type),O=formDataWithSelectedLang(L,n,T),U=({formData:ye},de,q)=>{de&&(R==null?void 0:R._id)===c._id&&x([c._id],{[de]:lodashEs.get(ye,de)},q)},M=React.useCallback(lodashEs.debounce(({formData:ye},de,q)=>{U({formData:ye},de,q),S(ye)},1500),[c==null?void 0:c._id,n]),D=({formData:ye},de)=>{de&&(d([c._id],{[de]:lodashEs.get(ye,de)}),M({formData:ye},de,{[de]:lodashEs.get(R,de)}))},K=({formData:ye},de)=>{de&&(d([L._id],{[de]:lodashEs.get(ye,de)}),M({formData:ye},de,{[de]:lodashEs.get(R,de)}))},{schema:$,uiSchema:ee}=React.useMemo(()=>{const ye=c==null?void 0:c._type;if(!ye)return{schema:{},uiSchema:{}};try{const{schema:de,uiSchema:q}=runtime.getBlockFormSchemas(ye);if(ye==="Repeater"){const he=lodashEs.get(c,"repeaterItems","");lodashEs.startsWith(he,`{{${applyBinding.COLLECTION_PREFIX}`)?(lodashEs.set(q,"filter",{"ui:widget":"collectionSelect"}),lodashEs.set(q,"sort",{"ui:widget":"collectionSelect"})):(lodashEs.set(q,"filter",{"ui:widget":"hidden"}),lodashEs.set(q,"sort",{"ui:widget":"hidden"}))}return{schema:de,uiSchema:q}}catch{return{schema:{},uiSchema:{}}}},[c]),{wrapperSchema:ae,wrapperUiSchema:Re}=React.useMemo(()=>{if(!L||!(L!=null&&L._type))return{wrapperSchema:{},wrapperUiSchema:{}};const ye=L==null?void 0:L._type,{schema:de={},uiSchema:q={}}=runtime.getBlockFormSchemas(ye);return{wrapperSchema:de,wrapperUiSchema:q}},[L]);return jsxRuntime.jsxs("div",{className:"no-scrollbar overflow-x-hidden px-px",children:[!lodashEs.isEmpty(L)&&jsxRuntime.jsxs("div",{className:"mb-4 rounded border bg-zinc-100 px-1",children:[jsxRuntime.jsxs("div",{onClick:()=>A(ye=>!ye),className:"flex cursor-pointer items-center gap-x-1 py-2 text-xs font-medium leading-tight hover:bg-slate-100",children:[_?jsxRuntime.jsx(reactIcons.ChevronDownIcon,{className:"h-4 w-4 text-slate-400"}):jsxRuntime.jsx(reactIcons.ChevronRightIcon,{className:"h-4 w-4 text-slate-400"}),lodashEs.startCase(L._type)," settings"," ",L._name&&jsxRuntime.jsxs("span",{className:"text-[11px] font-light text-slate-400",children:["(",L._name,")"]})]}),jsxRuntime.jsx("div",{className:_?"h-auto":"invisible h-0",children:jsxRuntime.jsx(JSONForm,{blockId:L==null?void 0:L._id,onChange:K,formData:O,schema:ae,uiSchema:Re})})]}),lodashEs.isEmpty($)?null:jsxRuntime.jsx(JSONForm,{blockId:c==null?void 0:c._id,onChange:D,formData:y,schema:$,uiSchema:ee})]})}const BlockStylingProps=()=>{var U;const n=useSelectedBlock(),[c,d]=useSelectedStylingBlocks(),x=useRemoveClassesFromBlocks(),[b]=useSelectedBlockIds(),{t:y}=reactI18next.useTranslation();if(!n)return null;const R=Object.keys(n).filter(M=>typeof n[M]=="string"&&n[M].startsWith("#styles:")),{reset:S}=useResetBlockStyles(),_=!lodashEs.isEmpty(R)&&R.length>1,A=lodashEs.get(n,(U=c[0])==null?void 0:U.prop,""),{classes:L=""}=applyBinding.getSplitChaiClasses(A)||{},T=L?L.split(" ").filter(M=>!lodashEs.isEmpty(M)):[],O=M=>lodashEs.find(c,D=>D.prop===M);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:_&&jsxRuntime.jsxs("div",{className:"flex flex-wrap gap-1",children:[jsxRuntime.jsxs("label",{htmlFor:"block-styling-props",className:"py-1 text-xs",children:[y("Style element"),":"]}),jsxRuntime.jsx("div",{className:"flex flex-wrap gap-2",children:lodashEs.map(R,M=>jsxRuntime.jsxs(tooltip.Badge,{className:"flex cursor-pointer items-center gap-1 pr-1",variant:O(M)?"default":"secondary",onClick:()=>{d([{id:`${M}-${n._id}`,blockId:n._id,prop:M}])},children:[lodashEs.startCase(M),jsxRuntime.jsxs(tooltip.DropdownMenu,{children:[jsxRuntime.jsx(tooltip.DropdownMenuTrigger,{asChild:!0,children:jsxRuntime.jsx("button",{type:"button",className:"ml-1 rounded-sm p-0.5 hover:bg-blue-300 hover:text-blue-600",onClick:D=>D.stopPropagation(),children:jsxRuntime.jsx(reactIcons.DotsVerticalIcon,{className:"h-3 w-3"})})}),jsxRuntime.jsxs(tooltip.DropdownMenuContent,{side:"bottom",className:"border-border text-xs",children:[jsxRuntime.jsx(tooltip.DropdownMenuItem,{className:"text-xs",onClick:()=>{S(M)},children:y("Reset style")}),jsxRuntime.jsx(tooltip.DropdownMenuItem,{className:"text-xs",onClick:()=>{x(b,T,!0)},children:y("Clear styles")})]})]})]},M))}),jsxRuntime.jsx("div",{className:"my-2 h-[1px] w-full bg-border"})]})})},BlockSettingsContext=React.createContext({setDragData:()=>{}}),getUserInputValues=(n,c)=>{n=n.toLowerCase();let d=n.trim().replace(/ |\+/g,"");if((d==="auto"||d==="none")&&c.includes(d))return{value:"",unit:d};const x=c.length?new RegExp(c.join("|"),"g"):/XXXXXX/g;d=d.replace(x,"");const b=n.match(x),y=b&&b.length>1,R=!lodashEs.isEmpty(d)&&Number.isNaN(Number(d));return y||R?{error:"Invalid value"}:b&&(b[0]==="auto"||b[0]==="none")?{value:b[0],unit:""}:{value:d,unit:b?b[0]:""}},getTwClassValue=n=>{const c=n.startsWith("-")?"-":"",d=n.split("-").pop();if(["auto","none"].includes(d))return{value:"",unit:d};if(d==="px")return{value:"1",unit:"px"};if(d==="screen")return{value:"100",unit:n.indexOf("w-")!==-1?"vw":"vh"};if(d==="full")return{value:"100",unit:"%"};if(lodashEs.includes(n,"skew-"))return{value:`${c}${d}`,unit:"deg"};if(lodashEs.includes(n,"rotate-"))return{value:`${c}${d}`,unit:"deg"};if(lodashEs.includes(n,"opacity-"))return{value:`${d/100}`,unit:"-"};if(lodashEs.includes(n,"duration-")||lodashEs.includes(n,"delay-"))return{value:`${d}`,unit:"ms"};if(lodashEs.includes(n,"translate-")&&!d.includes("/"))return{value:`${c}${`${d/4}`}`,unit:"rem"};if(lodashEs.includes(n,"scale-"))return{value:`${c}${`${d/100}`}`,unit:"-"};if(lodashEs.startsWith(n,"border")){const x=n.match(/border-?(x|y|t|r|b|l)?\d+/g);if(x)return{value:x[0].split("-").pop(),unit:"px"};if(n.match(/border-?(x|y|t|r|b|l)?/g))return{value:"1",unit:"px"}}if(lodashEs.startsWith(n,"max-w-")){if(n==="max-w-screen-sm")return{value:"640",unit:"px"};if(n==="max-w-screen-md")return{value:"768",unit:"px"};if(n==="max-w-screen-lg")return{value:"1024",unit:"px"};if(n==="max-w-screen-xl")return{value:"1280",unit:"px"};if(n==="max-w-screen-2xl")return{value:"1536",unit:"px"};if(d==="xs")return{value:"320",unit:"px"};if(d==="sm")return{value:"384",unit:"px"};if(d==="md")return{value:"448",unit:"px"};if(d==="lg")return{value:"512",unit:"px"};if(d==="xl")return{value:"576",unit:"px"};if(d==="2xl")return{value:"672",unit:"px"};if(d==="3xl")return{value:"768",unit:"px"};if(d==="4xl")return{value:"896",unit:"px"};if(d==="5xl")return{value:"1024",unit:"px"};if(d==="6xl")return{value:"1152",unit:"px"};if(d==="7xl")return{value:"1280",unit:"px"};if(d==="prose")return{value:"65",unit:"ch"}}if(lodashEs.startsWith(n,"text-")){if(d==="xs")return{value:"12",unit:"px"};if(d==="sm")return{value:"14",unit:"px"};if(d==="base")return{value:"16",unit:"px"};if(d==="lg")return{value:"18",unit:"px"};if(d==="xl")return{value:"20",unit:"px"};if(d==="2xl")return{value:"24",unit:"px"};if(d==="3xl")return{value:"30",unit:"px"};if(d==="4xl")return{value:"36",unit:"px"};if(d==="5xl")return{value:"48",unit:"px"};if(d==="6xl")return{value:"60",unit:"px"};if(d==="7xl")return{value:"72",unit:"px"};if(d==="8xl")return{value:"96",unit:"px"};if(d==="9xl")return{value:"128",unit:"px"}}if(lodashEs.startsWith(n,"leading-")){if(d==="none")return{value:"1",unit:"-"};if(d==="tight")return{value:"1.25",unit:"-"};if(d==="snug")return{value:"1.375",unit:"-"};if(d==="normal")return{value:"1.5",unit:"-"};if(d==="relaxed")return{value:"1.625",unit:"-"};if(d==="loose")return{value:"2",unit:"-"}}if(lodashEs.startsWith(n,"tracking-")){if(d==="tighter")return{value:"-0.05",unit:"em"};if(d==="tight")return{value:"-0.025",unit:"em"};if(d==="normal")return{value:"0",unit:"em"};if(d==="wide")return{value:"0.025",unit:"em"};if(d==="wider")return{value:"0.05",unit:"em"};if(d==="widest")return{value:"0.1",unit:"em"}}if(["max","min","fit"].includes(d))return{value:n,unit:"class"};if(d.includes("/")){const[x,b]=lodashEs.map(d.split("/"),y=>parseInt(y,10));return{value:c+(x/b*100).toFixed(2).replace(".00",""),unit:"%"}}return lodashEs.isNumber(parseFloat(d))?{value:`${c+parseFloat(d)*4}`,unit:"px"}:{value:d,unit:"class"}},getClassValueAndUnit=n=>{if(lodashEs.isEmpty(n))return{value:"",unit:""};const c=n.match(/\[.*\]/g);if(c===null)return getValueAndUnitForTWClass(n);const d=lodashEs.get(c,"0","").replace(/\[|\]/g,""),x=n.startsWith("-")?"-":"",b=lodashEs.first(d.match(/\d+.\d+|\d+/g));return{value:`${x}${b}`,unit:d.replace(b,"")}},getValueAndUnitForTWClass=n=>lodashEs.isEmpty(n)?{value:"",unit:""}:getTwClassValue(n),DragStyleButton=({unit:n,currentValue:c,onDrag:d,onDragEnd:x,onDragStart:b,negative:y,cssProperty:R})=>{const{setDragData:S}=React.useContext(BlockSettingsContext);return jsxRuntime.jsx("button",{type:"button",onMouseDown:_=>{const A={onDrag:d,onDragEnd:x,dragging:!0,dragStartY:_.pageY,dragStartValue:`${c}`,dragUnit:n,negative:y,cssProperty:R};b(A),S(A)},color:void 0,className:"relative z-50 ml-1 hidden h-6 cursor-row-resize rounded bg-background/70 px-2 group-hover:inline",children:jsxRuntime.jsx(reactIcons.RowSpacingIcon,{})})},UnitSelection=({onSelect:n,current:c,units:d})=>jsxRuntime.jsx("div",{"data-theme":"light",className:"-m-[7px] -mx-[13px] flex w-9 flex-col",children:d.map(x=>jsxRuntime.jsx(tooltip.Button,{className:"h-max rounded-none px-1 py-1 text-right text-[11px] hover:bg-blue-400",color:c===x?"primary":void 0,size:"sm",onClick:b=>{b.stopPropagation(),n(x)},children:x},x))}),THROTTLE_TIME=50,AdvanceChoices=n=>{const[c,d]=React.useState(!1),[x,b]=React.useState(""),{currentClass:y,onChange:R,classPrefix:S,cssProperty:_,units:A,negative:L}=n,[T,O]=React.useState(_!=null&&_.toLowerCase().includes("width")?"%":A[0]),[U,M]=React.useState(!1),[D,K]=React.useState(""),[$,ee]=React.useState(!1),[ae,Re]=React.useState(!1);React.useEffect(()=>{const{value:le,unit:xe}=getClassValueAndUnit(y);if(xe===""){b(le),O(_!=null&&_.toLowerCase().includes("width")?"%":lodashEs.first(A));return}O(xe),b(xe==="class"||lodashEs.isEmpty(le)?"":le)},[y,_,A]);const ye=web.useThrottledCallback(le=>R(le),[R],THROTTLE_TIME),de=web.useThrottledCallback(le=>R(le,!1),[R],THROTTLE_TIME),q=React.useCallback((le=!1)=>{const xe=getUserInputValues(`${x}`,A);if(lodashEs.get(xe,"error",!1)){M(!0);return}const Ee=lodashEs.get(xe,"unit")!==""?lodashEs.get(xe,"unit"):T;if(Ee==="auto"||Ee==="none"){ye(`${S}${Ee}`);return}if(lodashEs.get(xe,"value")==="")return;const ze=`${lodashEs.get(xe,"value","").startsWith("-")?"-":""}${S}[${lodashEs.get(xe,"value","").replace("-","")}${Ee==="-"?"":Ee}]`;le?de(ze):ye(ze)},[ye,de,x,T,S,A]),he=React.useCallback(le=>{const xe=getUserInputValues(`${x}`,A);if(lodashEs.get(xe,"error",!1)){M(!0);return}if(le==="auto"||le==="none"){ye(`${S}${le}`);return}if(lodashEs.get(xe,"value")==="")return;const Ee=lodashEs.get(xe,"unit")!==""?lodashEs.get(xe,"unit"):le,ze=`${lodashEs.get(xe,"value","").startsWith("-")?"-":""}${S}[${lodashEs.get(xe,"value","").replace("-","")}${Ee==="-"?"":Ee}]`;ye(ze)},[ye,x,S,A]);return jsxRuntime.jsx("div",{className:"flex w-full flex-col",children:jsxRuntime.jsx("div",{className:"flex items-center justify-start",children:T==="class"?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("input",{className:"h-6 w-24 rounded border border-foreground/20 bg-background px-2 py-0.5 text-sm focus-visible:outline-0",readOnly:!0,value:y}),jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx("button",{type:"button",className:"invisible ml-3 mt-1 text-blue-600 group-hover:visible",children:jsxRuntime.jsx(reactIcons.InfoCircledIcon,{})})}),jsxRuntime.jsx(tooltip.TooltipContent,{children:"Current value is using a Tailwind preset class."})]})]}):jsxRuntime.jsxs("div",{className:`group relative flex items-center ${$?"z-auto":""}`,children:[jsxRuntime.jsxs("div",{className:"flex items-center rounded-md border border-border",children:[["none","auto"].indexOf(T)!==-1?null:jsxRuntime.jsx("input",{readOnly:T==="class",onKeyPress:le=>{le.key==="Enter"&&q()},onKeyDown:le=>{if(le.keyCode!==38&&le.keyCode!==40)return;le.preventDefault(),Re(!0);const xe=lodashEs.parseInt(le.target.value);let Ee=lodashEs.isNaN(xe)?0:xe;le.keyCode===38&&(Ee+=1),le.keyCode===40&&(Ee-=1);const je=`${Ee}`,We=`${je.startsWith("-")?"-":""}${S}[${je.replace("-","")}${T==="-"?"":T}]`;de(We)},onKeyUp:le=>{ae&&(le.preventDefault(),Re(!1))},onBlur:()=>q(),onChange:le=>{M(!1),b(le.target.value)},onClick:le=>{var xe;(xe=le==null?void 0:le.target)==null||xe.select(),d(!1)},value:$?D:x,className:"h-6 w-14 rounded rounded-r-none border border-transparent bg-background pl-2 text-sm focus-visible:outline-0".concat(" ",U?"border-red-500 text-red-500":"border-foreground/20")}),jsxRuntime.jsxs(tooltip.Tooltip,{open:c,delayDuration:100,children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsxs("button",{type:"button",onClick:()=>d(!c),className:"flex h-6 cursor-pointer items-center gap-x-1 rounded rounded-l-none bg-background p-px px-1 text-[11px] uppercase",children:[jsxRuntime.jsx("span",{className:`inline-block ${A.length===1?"px-2 font-semibold":""}`,children:T}),A.length>1?jsxRuntime.jsx(reactIcons.TriangleDownIcon,{}):null]})}),jsxRuntime.jsx(tooltip.TooltipContent,{className:"bg-background",children:jsxRuntime.jsx(UnitSelection,{units:A,current:T,onSelect:le=>{d(!1),O(le),he(le)}})})]})]}),["none","auto"].indexOf(T)!==-1||$?null:jsxRuntime.jsx(DragStyleButton,{onDragStart:()=>ee(!0),onDragEnd:le=>{if(K(()=>""),ee(!1),lodashEs.isEmpty(le))return;const xe=`${le}`,je=`${xe.startsWith("-")?"-":""}${S}[${xe.replace("-","")}${T==="-"?"":T}]`;ye(je)},onDrag:le=>{if(lodashEs.isEmpty(le))return;K(le);const xe=`${le}`,je=`${xe.startsWith("-")?"-":""}${S}[${xe.replace("-","")}${T==="-"?"":T}]`;de(je)},currentValue:x,unit:T,negative:L,cssProperty:_})]})})})},StyleContext=React.createContext({canReset:!1,canChange:!0}),BlockStyleProvider=({children:n,canReset:c=!1,canChange:d=!0})=>jsxRuntime.jsx(StyleContext.Provider,{value:{canReset:c,canChange:d},children:n}),DropDownChoices=({label:n,property:c,onChange:d})=>{const{getClasses:x}=useTailwindClassList(),b=x(c),y=useCurrentClassByProperty(c),R=React.useMemo(()=>lodashEs.get(y,"cls",""),[y]),{canChange:S}=React.useContext(StyleContext),_=/\[.*\]/g.test(R);return jsxRuntime.jsx("div",{className:n?"w-full rounded":"grow",children:_?jsxRuntime.jsxs("div",{className:"flex items-center",children:[jsxRuntime.jsx(tooltip.Input,{className:"w-[70%] rounded py-1",readOnly:!0,value:R}),jsxRuntime.jsxs(tooltip.Tooltip,{delayDuration:100,children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx("button",{type:"button",className:"invisible ml-3 mt-1 text-blue-600 group-hover:visible",children:jsxRuntime.jsx(reactIcons.InfoCircledIcon,{})})}),jsxRuntime.jsx(tooltip.TooltipContent,{children:"Current value is using a Tailwind arbitrary value."})]})]}):jsxRuntime.jsx(DropDown,{rounded:n,onChange:A=>d(A,c),selected:R,options:b,disabled:!S})})};function DropDown({selected:n,onChange:c,rounded:d=!1,options:x,disabled:b=!1}){const y=n.replace(/.*:/g,"").trim(),{undo:R,redo:S}=useUndoManager();return jsxRuntime.jsxs("select",{disabled:!x.length||b,className:`${d?"rounded-md border border-border":"border-0"} disable:bg-gray-500 h-full w-full truncate rounded bg-background px-2 py-1 text-xs outline-none disabled:cursor-not-allowed`,onChange:_=>c(_.target.value),onKeyDown:_=>{_.ctrlKey&&(_.key==="z"&&R(),_.key==="y"&&S())},value:y,children:[jsxRuntime.jsx("option",{className:"bg-transparent",value:""}),x.map((_,A)=>jsxRuntime.jsx("option",{className:"bg-transparent",value:_,children:_},`option-${A}`))]})}const COLOR_PROP={backgroundColor:"bg",textColor:"text",borderColor:"border",boxShadowColor:"shadow",outlineColor:"outline",divideColor:"divide",fromColor:"from",viaColor:"via",toColor:"to",ringColor:"ring",ringOffsetColor:"ring-offset"},ColorChoice=({property:n,onChange:c})=>{const d=useCurrentClassByProperty(n),x=React.useMemo(()=>lodashEs.get(d,"cls",""),[d]),{canChange:b}=React.useContext(StyleContext),[y,R]=React.useState([]),[S,_]=React.useState({color:"",shade:""}),A=x.split("-"),L=lodashEs.get(A,"1",""),T=lodashEs.get(A,"2",""),O=React.useCallback(D=>{["current","inherit","transparent","black","white"].includes(D)?(R([]),_({color:D})):(R(["50","100","200","300","400","500","600","700","800","900"]),_(K=>({...K,color:D,shade:K.shade?K.shade:"500"})))},[R,_]);React.useEffect(()=>{if(["current","inherit","transparent","black","white"].includes(L))return R([]);R(["50","100","200","300","400","500","600","700","800","900"])},[L]);const U=React.useCallback(D=>{_({color:L,shade:D})},[L]);React.useEffect(()=>{_({color:"",shade:""})},[d]);const{match:M}=useTailwindClassList();return React.useEffect(()=>{const K=`${lodashEs.get(COLOR_PROP,n,"")}-${S.color}${S.shade?`-${S.shade}`:""}`;M(n,K)&&c(K,n)},[M,S,c,n]),jsxRuntime.jsxs("div",{className:"flex flex-row divide-x divide-solid divide-border rounded-lg border border-transparent text-xs",children:[jsxRuntime.jsx("div",{className:"grow text-center",children:jsxRuntime.jsx(DropDown,{disabled:!b,rounded:!0,selected:L,onChange:O,options:["current","transparent","primary","secondary","black","white","slate","gray","zinc","neutral","stone","red","orange","amber","yellow","lime","green","emerald","teal","cyan","sky","blue","indigo","violet","purple","fuchsia","pink","rose"]})}),jsxRuntime.jsx("button",{type:"button",className:"grow text-center",children:jsxRuntime.jsx(DropDown,{rounded:!0,selected:T,disabled:!L||!b,onChange:U,options:y})})]})},EDITOR_ICONS={"not-italic":()=>jsxRuntime.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9 3H11V5H9V11H11V13H5V11H7V5H5V3H9Z",fill:"white"})}),visible:reactIcons.EyeOpenIcon,invisible:reactIcons.EyeClosedIcon,hidden:reactIcons.EyeClosedIcon,gap:reactIcons.BorderAllIcon,gapX:reactIcons.WidthIcon,gapY:reactIcons.HeightIcon,spaceX:reactIcons.WidthIcon,spaceY:reactIcons.HeightIcon,overscroll:reactIcons.BorderAllIcon,overscrollX:reactIcons.WidthIcon,overscrollY:reactIcons.HeightIcon,overflow:reactIcons.BorderAllIcon,overflowX:reactIcons.WidthIcon,overflowY:reactIcons.HeightIcon,top:reactIcons.ArrowUpIcon,right:reactIcons.ArrowRightIcon,bottom:reactIcons.ArrowDownIcon,left:reactIcons.ArrowLeftIcon,inset:reactIcons.BorderAllIcon,insetX:reactIcons.WidthIcon,insetY:reactIcons.HeightIcon,border:reactIcons.BorderAllIcon,borderX:reactIcons.WidthIcon,borderY:reactIcons.HeightIcon,borderTop:reactIcons.ArrowUpIcon,borderRight:reactIcons.ArrowRightIcon,borderBottom:reactIcons.ArrowDownIcon,borderLeft:reactIcons.ArrowLeftIcon,borderRadius:reactIcons.BorderAllIcon,borderRadiusX:reactIcons.WidthIcon,borderRadiusY:reactIcons.HeightIcon,borderRadiusTop:reactIcons.ArrowUpIcon,borderRadiusRight:reactIcons.ArrowRightIcon,borderRadiusBottom:reactIcons.ArrowDownIcon,borderRadiusLeft:reactIcons.ArrowLeftIcon,borderRadiusTopLeft:reactIcons.ArrowTopLeftIcon,borderRadiusTopRight:reactIcons.ArrowTopRightIcon,borderRadiusBottomRight:reactIcons.ArrowBottomRightIcon,borderRadiusBottomLeft:reactIcons.ArrowBottomLeftIcon,divideXWidth:reactIcons.WidthIcon,divideYWidth:reactIcons.HeightIcon,scale:reactIcons.BorderAllIcon,scaleX:reactIcons.WidthIcon,scaleY:reactIcons.HeightIcon,skewX:reactIcons.WidthIcon,skewY:reactIcons.HeightIcon,translateX:reactIcons.WidthIcon,translateY:reactIcons.HeightIcon,padding:reactIcons.BorderAllIcon,paddingX:reactIcons.WidthIcon,paddingY:reactIcons.HeightIcon,paddingTop:reactIcons.ArrowUpIcon,paddingRight:reactIcons.ArrowRightIcon,paddingBottom:reactIcons.ArrowDownIcon,paddingLeft:reactIcons.ArrowLeftIcon,margin:reactIcons.BorderAllIcon,marginX:reactIcons.WidthIcon,marginY:reactIcons.HeightIcon,marginTop:reactIcons.ArrowUpIcon,marginRight:reactIcons.ArrowRightIcon,marginBottom:reactIcons.ArrowDownIcon,marginLeft:reactIcons.ArrowLeftIcon,textLeft:reactIcons.AlignLeftIcon,textCenter:reactIcons.AlignCenterHorizontallyIcon,textRight:reactIcons.AlignRightIcon,textJustify:reactIcons.StretchHorizontallyIcon,italic:reactIcons.FontItalicIcon,underline:reactIcons.UnderlineIcon,overline:reactIcons.OverlineIcon,uppercase:reactIcons.LetterCaseUppercaseIcon,block:()=>jsxRuntime.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("path",{opacity:"0.6",fillRule:"evenodd",clipRule:"evenodd",d:"M2 2H14V14H2V2ZM1 1H15V15H1V1Z",fill:"currentColor"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M7 4H4V12H7V4ZM9 4H12V12H9V4Z",fill:"currentColor"})]}),"float-right":()=>jsxRuntime.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("path",{d:"M8 4H16V12H8V4Z",fill:"currentColor"}),jsxRuntime.jsx("path",{opacity:"0.6",fillRule:"evenodd",clipRule:"evenodd",d:"M0 4H6V6H0V4ZM0 7H6V9H0V7ZM4 10H0V12H4V10Z",fill:"currentColor"})]}),"float-left":()=>jsxRuntime.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("path",{d:"M0 4H8V12H0V4Z",fill:"currentColor"}),jsxRuntime.jsx("path",{opacity:"0.6",fillRule:"evenodd",clipRule:"evenodd",d:"M10 4H16V6H10V4ZM10 7H16V9H10V7ZM14 10H10V12H14V10Z",fill:"currentColor"})]}),"float-none":reactIcons.Cross2Icon,fixed:()=>jsxRuntime.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("path",{opacity:"0.6",fillRule:"evenodd",clipRule:"evenodd",d:"M15 2H14V4H13V5H14V6H15V2ZM10 5V4H9V2H1V8H2V5H10ZM7 4V3H5V4H7ZM4 4V3H2V4H4ZM1 13H7V14H1V13Z",fill:"currentColor"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M11 2H10V3H11V6H12V3H13V2H11ZM2 9H1V12H2V11H7V10H2V9ZM15 7H8V14H15V7Z",fill:"currentColor"})]}),absolute:()=>jsxRuntime.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("path",{opacity:"0.6",fillRule:"evenodd",clipRule:"evenodd",d:"M14 2H15V6H14V2ZM9 3V2H1V8H2V3H9ZM7 13H1V14H7V13Z",fill:"currentColor"}),jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M11 2H10V3H11V6H12V3H13V2H11ZM2 9H1V12H2V11H7V10H2V9ZM15 7H8V14H15V7Z",fill:"currentColor"})]}),relative:()=>jsxRuntime.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M11 2H9V3H11V6H12V3H14V2H11ZM2 8H1V13H2V11H7V10H2V8ZM15 7H8V14H15V7Z",fill:"currentColor"})}),sticky:()=>jsxRuntime.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[jsxRuntime.jsx("path",{d:"M12.9998 7C13.6558 7 14.2937 6.78498 14.8158 6.38787C15.338 5.99076 15.7156 5.43345 15.8908 4.80128C16.066 4.16912 16.0292 3.49694 15.7859 2.8877C15.5427 2.27846 15.1065 1.76573 14.5441 1.42804C13.9817 1.09034 13.3241 0.946293 12.672 1.01795C12.02 1.08961 11.4094 1.37303 10.9337 1.8248C10.4581 2.27658 10.1436 2.8718 10.0385 3.51932C9.93341 4.16685 10.0434 4.83097 10.3518 5.41L6.88176 8.88C6.80034 8.96122 6.73572 9.05769 6.69158 9.16388C6.64744 9.27008 6.62465 9.38393 6.62451 9.49894C6.62437 9.61395 6.64689 9.72785 6.69077 9.83416C6.73465 9.94046 6.79904 10.0371 6.88026 10.1185C6.96149 10.1999 7.05795 10.2645 7.16415 10.3087C7.27035 10.3528 7.3842 10.3756 7.4992 10.3758C7.61421 10.3759 7.72812 10.3534 7.83442 10.3095C7.94072 10.2656 8.03734 10.2012 8.11876 10.12L11.5888 6.648C12.0088 6.873 12.4888 7 12.9988 7H12.9998Z",fill:"currentColor"}),jsxRuntime.jsx("path",{opacity:"0.6",fillRule:"evenodd",clipRule:"evenodd",d:"M9.535 2H1V14H15V7.465C14.69 7.645 14.355 7.783 14 7.875V13H2V5H9.126C8.86504 3.98486 9.01223 2.90789 9.536 2H9.535ZM7 3V4H5V3H7ZM4 3V4H2V3H4Z",fill:"currentColor"})]}),static:reactIcons.Cross1Icon},IconChoices=({property:n,onChange:c})=>{const{getClasses:d}=useTailwindClassList(),x=d(n),{canChange:b}=React.useContext(StyleContext),y=useCurrentClassByProperty(n),R=React.useMemo(()=>lodashEs.get(y,"cls",""),[y]);return jsxRuntime.jsx("div",{className:"flex grow flex-wrap gap-1",children:lodashEs.map(x,S=>jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx("button",{type:"button",disabled:!b,onClick:()=>c(S,n),className:`cursor-pointer rounded border border-border p-1 disabled:cursor-not-allowed ${R===S?"bg-primary text-white":"disabled:bg-gray-600 disabled:text-gray-400"}`,children:React.createElement(lodashEs.get(EDITOR_ICONS,S,reactIcons.BoxIcon))})}),jsxRuntime.jsx(tooltip.TooltipContent,{children:lodashEs.startCase(lodashEs.toLower(S))})]}))})},RangeChoices=({property:n,onChange:c})=>{const{canReset:d,canChange:x}=React.useContext(StyleContext),b=useCurrentClassByProperty(n),y=React.useMemo(()=>lodashEs.get(b,"cls",""),[b]),{getClasses:R}=useTailwindClassList(),S=R(n,[""]),_=S.indexOf(y)>-1?S.indexOf(y):0,A=/\[.*\]/g.test(y);return jsxRuntime.jsx("div",{className:"flex flex-row divide-x divide-solid divide-border rounded border border-border text-xs",children:A?jsxRuntime.jsx("div",{className:"px-2 py-[5px]",children:y}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("button",{type:"button",className:"hover:bg-bg-gray-700 box-border w-2/12 rounded-bl rounded-tl bg-background px-1 text-center disabled:cursor-not-allowed disabled:bg-gray-600",disabled:!x&&(!d||_-1<0),onClick:()=>c(lodashEs.nth(S,_-1),n),children:jsxRuntime.jsx("span",{className:"flex items-center justify-center",children:jsxRuntime.jsx(reactIcons.MinusIcon,{className:!x&&(!d||_-1<0)?"text-gray-500":"text-black/60 dark:text-white/60"})})}),jsxRuntime.jsx("div",{className:"w-8/12 text-center",children:jsxRuntime.jsx(DropDownChoices,{label:!1,property:n,onChange:c})}),jsxRuntime.jsx("button",{type:"button",className:"hover:bg-bg-gray-700 w-2/12 rounded-br rounded-tr bg-background px-1 text-center disabled:cursor-not-allowed disabled:bg-gray-600",disabled:!x&&(!d||_+1>=S.length),onClick:()=>c(lodashEs.nth(S,_+1),n),children:jsxRuntime.jsx("span",{className:"flex items-center justify-center",children:jsxRuntime.jsx(reactIcons.PlusIcon,{className:!x&&(!d||_+1>=S.length)?"text-gray-500":"text-black/60 dark:text-white/60"})})})]})})},useCurrentClassByProperty=n=>{const c=useSelectedBlockCurrentClasses();return lodashEs.findLast(c,{property:n})},canChangeClass=(n,c)=>{const d={xs:0,sm:1,md:2,lg:3,xl:4,"2xl":5};return d[lodashEs.get(n,"mq","xs")]<=d[c]},CLASS_PREFIXES={width:"w-",height:"h-",minWidth:"min-w-",minHeight:"min-h-",maxWidth:"max-w-",maxHeight:"max-h-",zIndex:"z-",gap:"gap-",gapX:"gap-x-",gapY:"gap-y-",margin:"m-",marginX:"mx-",marginY:"my-",marginTop:"mt-",marginBottom:"mb-",marginLeft:"ml-",marginRight:"mr-",padding:"p-",paddingX:"px-",paddingY:"py-",paddingTop:"pt-",paddingBottom:"pb-",paddingLeft:"pl-",paddingRight:"pr-",spaceX:"space-x-",spaceY:"space-y-",border:"border-",borderTop:"border-t-",borderBottom:"border-b-",borderLeft:"border-l-",borderRight:"border-r-",borderX:"border-x-",borderY:"border-y-",borderRadius:"rounded-",borderRadiusTop:"rounded-t-",borderRadiusRight:"rounded-r-",borderRadiusBottom:"rounded-b-",borderRadiusLeft:"rounded-l-",borderRadiusTopLeft:"rounded-tl-",borderRadiusTopRight:"rounded-tr-",borderRadiusBottomRight:"rounded-br-",borderRadiusBottomLeft:"rounded-bl-",fontSize:"text-",lineHeight:"leading-",letterSpacing:"tracking-",textIndent:"indent-",rotate:"rotate-",duration:"duration-",transitionDelay:"delay-",scale:"scale-",scaleX:"scale-x-",scaleY:"scale-y-",translateX:"translate-x-",translateY:"translate-y-",skewX:"skew-x-",skewY:"skew-y-",top:"top-",bottom:"bottom-",left:"left-",right:"right-",inset:"inset-",insetX:"inset-x-",insetY:"inset-y-",opacity:"opacity-",flexBasis:"basis-"},BREAKPOINTS={xs:"",sm:"640px",md:"768px",lg:"1024px",xl:"1280px","2xl":"1536px"},getBreakpoint=n=>`${n.toUpperCase()} ${BREAKPOINTS[n]?`(${BREAKPOINTS[n]} & up)`:""}`,BlockStyle=n=>{const{t:c}=reactI18next.useTranslation(),{type:d="icons",label:x,property:b,onEmitChange:y=()=>{},units:R,negative:S=!1}=n,[_]=useDarkMode(),[A]=useStylingState(),[,L]=useScreenSizeWidth(),T=useCurrentClassByProperty(b),O=useAddClassesToBlocks(),U=useRemoveClassesFromBlocks(),[M]=useSelectedBlockIds(),D=React.useMemo(()=>lodashEs.get(T,"fullCls",""),[T]),K=React.useCallback((de,q=!0)=>{const he={dark:_,mq:L,mod:A,cls:de,property:b,fullCls:""};(_||A!=="")&&(he.mq="xs");const le=generateFullClsName(he);O(M,[le],q)},[M,_,L,A,b,O]),$=React.useCallback(()=>{U(M,[D],!0)},[M,D,U]),ee=React.useMemo(()=>canChangeClass(T,L),[T,L]);React.useEffect(()=>{y(ee,T)},[ee,y,T]);const[,,ae]=useScreenSizeWidth(),Re=React.useCallback(de=>{ae({xs:400,sm:640,md:800,lg:1024,xl:1420,"2xl":1920}[de])},[ae]),ye=lodashEs.get(T,"dark",null)===_&&lodashEs.get(T,"mod",null)===A&&lodashEs.get(T,"mq",null)===L;return jsxRuntime.jsx(BlockStyleProvider,{canChange:ee,canReset:T&&ye,children:jsxRuntime.jsxs("div",{className:"group flex flex-row items-center py-2 first:pt-0 last:pb-0",children:[jsxRuntime.jsx("div",{className:"relative w-[70px] truncate text-xs text-foreground",children:jsxRuntime.jsx("span",{className:`text-[11px] ${T&&!ye?"text-foreground":""}`,children:c(x)})}),jsxRuntime.jsxs("div",{className:"flex flex-row items-center",children:[jsxRuntime.jsxs("div",{className:"w-[150px]",children:[d==="arbitrary"?jsxRuntime.jsx(AdvanceChoices,{currentClass:lodashEs.get(T,"cls",""),classPrefix:lodashEs.get(CLASS_PREFIXES,b,""),units:R||[],onChange:K,negative:S,cssProperty:b}):null,d==="icons"&&jsxRuntime.jsx(IconChoices,{property:b,onChange:K}),d==="range"&&jsxRuntime.jsx(RangeChoices,{property:b,onChange:K}),d==="color"&&jsxRuntime.jsx(ColorChoice,{property:b,onChange:K}),d==="dropdown"&&jsxRuntime.jsx(DropDownChoices,{label:x,property:b,onChange:K})]}),jsxRuntime.jsx("div",{className:`w-[30px] cursor-pointer ${D?"visible":"invisible"}`,children:ye?jsxRuntime.jsx("button",{type:"button",onClick:()=>$(),title:"Reset",className:"flex px-1.5 text-xs",children:jsxRuntime.jsx(reactIcons.CrossCircledIcon,{className:"h-5 w-5 text-blue-500 hover:opacity-80"})}):ee&&T?jsxRuntime.jsxs(tooltip.Tooltip,{delayDuration:100,children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx("button",{type:"button",className:"invisible ml-3 mt-1 rounded-full bg-primary text-white group-hover:visible",children:jsxRuntime.jsx(reactIcons.InfoCircledIcon,{})})}),jsxRuntime.jsx(tooltip.TooltipContent,{children:jsxRuntime.jsx("div",{className:"text-right",children:jsxRuntime.jsxs("div",{children:["Current style is set at  ",jsxRuntime.jsxs("span",{className:"font-bold",children:[getBreakpoint(lodashEs.get(T,"mq")),_&&!T.dark?"(Light mode)":""]}),jsxRuntime.jsx("br",{}),jsxRuntime.jsxs("button",{type:"button",onClick:()=>Re(lodashEs.get(T,"mq")),className:"block w-full cursor-default text-right font-semibold text-blue-500",children:["Switch to ",lodashEs.get(T,"mq").toUpperCase()]})]})})})]}):null})]})]})})},basicUnits=["px","%","em","rem","ch","vh","vw"],MultipleChoices=({label:n,options:c,borderB:d=!1,borderT:x=!1,type:b="arbitrary",units:y=basicUnits,negative:R=!1})=>{const{t:S}=reactI18next.useTranslation(),[_,A]=React.useState(c[0].key),L=useSelectedBlockCurrentClasses(),T=React.useCallback(O=>lodashEs.map(L,"property").includes(O),[L]);return jsxRuntime.jsxs("div",{className:`mb-2 border-border py-2 first:pt-0 last:pb-0 ${d?"border-b":""} ${x?"border-t":""}`,children:[jsxRuntime.jsxs("div",{className:"flex flex-row text-xs",children:[n&&jsxRuntime.jsx("span",{className:"relative w-[70px] flex-none text-xs text-foreground",children:S(n)}),jsxRuntime.jsx("div",{className:"mb-3 flex grow flex-row flex-wrap gap-x-px",children:c.map(({label:O,key:U},M)=>jsxRuntime.jsx("div",{className:"first:rounded-l last:rounded-r",children:jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsxs("button",{type:"button",onClick:()=>A(U),className:`relative cursor-pointer rounded-full p-1 text-[8px] ${U===_?"bg-[#3E57F0] text-white":"text-gray-600 dark:text-gray-300"}`,children:[React.createElement("div",{className:T(U)?"-bottom-1.5 absolute bg-[#3E57F0] h-[2px] left-0 w-full":""}),React.createElement(lodashEs.get(EDITOR_ICONS,U,reactIcons.BoxIcon),{className:"text-inherit w-3 h-3"})]})}),jsxRuntime.jsx(tooltip.TooltipContent,{children:lodashEs.startCase(lodashEs.toLower(O))})]})},`option-${M}`))})]}),jsxRuntime.jsx("div",{className:"mt-0 flex items-center",children:jsxRuntime.jsx(BlockStyle,{type:b,units:[...y],label:"",property:_,negative:R})})]})},NestedOptions=({heading:n,items:c})=>{const{t:d}=reactI18next.useTranslation(),x=useSelectedBlockCurrentClasses(),b=React.useMemo(()=>{const y=_=>lodashEs.flatten(_.map(A=>A.styleType==="multiple"?lodashEs.map(A.options,"key"):A.property)),R=lodashEs.flatten(c.map(_=>_.styleType==="accordion"?y(_.items):_.styleType==="multiple"?lodashEs.map(_.options,"key"):_.property)),S=lodashEs.map(x,"property");return lodashEs.intersection(R,S).length>0},[x,c]);return jsxRuntime.jsxs("details",{children:[jsxRuntime.jsx("summary",{className:"my-px cursor-default rounded-md bg-gray-50 p-px px-2 text-[11px] text-foreground dark:bg-gray-800",children:jsxRuntime.jsxs("div",{className:"inline",children:[lodashEs.startCase(d(n.toLowerCase())),b?jsxRuntime.jsx("span",{className:`ml-1 mr-2 inline-block h-[8px] w-[8px] rounded-full ${b?"bg-primary":"bg-gray-300"}`}):null]})}),jsxRuntime.jsx("div",{className:"p-2",children:c.map(y=>y.styleType==="multiple"?jsxRuntime.jsx(MultipleChoices,{...y},y.label):jsxRuntime.jsx(BlockStyle,{...y},y.label))})]})},SectionContext=React.createContext({}),StylingGroup=({section:n,showAccordian:c})=>{const{t:d}=reactI18next.useTranslation(),x=useSelectedBlockCurrentClasses(),b=React.useCallback((R=[])=>{const S={};for(let A=0;A<x.length;A++)S[x[A].property]=x[A].cls;let _=!0;for(const A in R)if(!lodashEs.has(S,A)||S[A]!==R[A]){_=!1;break}return _},[x]),y=React.useMemo(()=>({}),[]);return jsxRuntime.jsx(SectionContext.Provider,{value:y,children:c?jsxRuntime.jsxs(tooltip.AccordionItem,{value:n.heading,className:"border-none",children:[jsxRuntime.jsx(tooltip.AccordionTrigger,{className:"border-slate-150 border-t py-2 text-xs",children:jsxRuntime.jsx("div",{className:"flex items-center py-2",children:jsxRuntime.jsx("div",{className:"flex items-center gap-x-2 text-xs font-medium",children:lodashEs.startCase(d(n.heading))})})}),jsxRuntime.jsx(tooltip.AccordionContent,{className:"py-2",children:n.items.map(R=>lodashEs.has(R,"component")?React.createElement(R.component,{key:R.label}):lodashEs.has(R,"styleType")?R.styleType==="multiple"?jsxRuntime.jsx(MultipleChoices,{...R},R.label+"multiple-choices"):R.styleType==="accordion"&&b(R==null?void 0:R.conditions)?jsxRuntime.jsx(NestedOptions,{...R},R.label+"nested-options"):null:jsxRuntime.jsx(BlockStyle,{...R},R.label+"block-style"))})]}):jsxRuntime.jsx("div",{className:"py-2",children:n.items.map((R,S)=>lodashEs.has(R,"component")?React.createElement(R.component,{key:R.label}):lodashEs.has(R,"styleType")?R.styleType==="multiple"?jsxRuntime.jsx(MultipleChoices,{...R},R.label+"multiple-choices"+S):R.styleType==="accordion"&&b(R==null?void 0:R.conditions)?jsxRuntime.jsx(NestedOptions,{...R},R.label+"nested-options"+S):null:jsxRuntime.jsx(BlockStyle,{...R},R.label+"block-style"+S))})})},TabletIcon=({landscape:n=!1,className:c=""})=>jsxRuntime.jsx("svg",{className:commonFunctions.cn("h-3 w-3",n?"rotate-90":"",c),stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 448 512",xmlns:"http://www.w3.org/2000/svg",children:jsxRuntime.jsx("path",{d:"M400 0H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V48c0-26.5-21.5-48-48-48zM224 480c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm176-108c0 6.6-5.4 12-12 12H60c-6.6 0-12-5.4-12-12V60c0-6.6 5.4-12 12-12h328c6.6 0 12 5.4 12 12v312z"})}),WEB_BREAKPOINTS=[{title:"Mobile (Base)",content:"Styles set here are applied to all screen unless edited at higher breakpoint",breakpoint:"xs",icon:jsxRuntime.jsx(reactIcons.MobileIcon,{className:"h-4 w-4"}),width:400},{title:"Mobile landscape (SM)",content:"Styles set here are applied at 640px and up unless edited at higher breakpoint",breakpoint:"sm",icon:jsxRuntime.jsx(reactIcons.MobileIcon,{className:"h-4 w-4 rotate-90"}),width:640},{title:"Tablet (MD)",content:"Styles set here are applied at 768px and up",breakpoint:"md",icon:jsxRuntime.jsx(TabletIcon,{}),width:800},{title:"Tablet Landscape (LG)",content:"Styles set here are applied at 1024px and up unless edited at higher breakpoint",breakpoint:"lg",icon:jsxRuntime.jsx(TabletIcon,{landscape:!0}),width:1024},{title:"Desktop (XL)",content:"Styles set here are applied at 1280px and up unless edited at higher breakpoint",breakpoint:"xl",icon:jsxRuntime.jsx(reactIcons.LaptopIcon,{className:"h-4 w-4"}),width:1420},{title:"Large Desktop (2XL)",content:"Styles set here are applied at 1536px and up",breakpoint:"2xl",icon:jsxRuntime.jsx(reactIcons.DesktopIcon,{className:"h-4 w-4"}),width:1920}],BreakpointCard=({canvas:n=!1,openDelay:c=400,tooltip:d=!0,title:x,content:b,currentBreakpoint:y,breakpoint:R,width:S,icon:_,onClick:A,buttonClass:L="",activeButtonClass:T=""})=>{const{t:O}=reactI18next.useTranslation();return d?jsxRuntime.jsxs(tooltip.HoverCard,{openDelay:c,children:[jsxRuntime.jsx(tooltip.HoverCardTrigger,{asChild:!0,children:jsxRuntime.jsx(tooltip.Button,{onClick:()=>A(S),size:"sm",className:commonFunctions.cn("h-7 w-7 rounded-md p-1",R===y?T:L),variant:R===y?"outline":"ghost",children:_})}),jsxRuntime.jsx(tooltip.HoverCardContent,{className:"w-fit max-w-52 border-border",children:jsxRuntime.jsx("div",{className:"flex justify-between space-x-4",children:jsxRuntime.jsxs("div",{className:"space-y-1",children:[jsxRuntime.jsx("h4",{className:"text-sm font-semibold",children:O(x)}),n&&jsxRuntime.jsx("p",{className:"text-xs",children:O(b)})]})})})]}):jsxRuntime.jsx(tooltip.Button,{onClick:()=>A(S),size:"sm",className:"h-7 w-7 rounded-md p-1",variant:R===y?"outline":"ghost",children:_})},Breakpoints$1=({openDelay:n=400,canvas:c=!1,tooltip:d=!0,buttonClass:x="",activeButtonClass:b=""})=>{const[y,,R]=useScreenSizeWidth(),[S,_]=useCanvasDisplayWidth(),[A,L]=useSelectedBreakpoints(),T=A,O=L,{t:U}=reactI18next.useTranslation(),M=useBuilderProp("breakpoints",WEB_BREAKPOINTS),D=ee=>{T.includes(ee)?T.length>2&&O(T.filter(ae=>ae!==ee)):O(ae=>[...ae,ee])},K=ee=>{c||R(ee),_(ee)},$=commonFunctions.getBreakpointValue(c?S:y).toLowerCase();return M.length<4?jsxRuntime.jsx("div",{className:"flex items-center rounded-md",children:lodashEs.map(M,ee=>React.createElement(BreakpointCard,{canvas:c,...ee,onClick:K,key:ee.breakpoint,currentBreakpoint:$}))}):jsxRuntime.jsxs("div",{className:"flex w-full items-center justify-between rounded-md",children:[jsxRuntime.jsx("div",{className:"flex items-center",children:lodashEs.map(M.filter(ee=>lodashEs.includes(T,lodashEs.toUpper(ee.breakpoint))),ee=>React.createElement(BreakpointCard,{canvas:c,openDelay:n,tooltip:d,...ee,onClick:K,key:ee.breakpoint,currentBreakpoint:$,buttonClass:x,activeButtonClass:b}))}),jsxRuntime.jsxs(tooltip.DropdownMenu,{children:[jsxRuntime.jsx(tooltip.DropdownMenuTrigger,{asChild:!0,children:jsxRuntime.jsx("span",{className:"cursor-pointer rounded-md p-1 hover:bg-background",children:jsxRuntime.jsx(reactIcons.ChevronDownIcon,{className:"scale-90 transform"})})}),jsxRuntime.jsxs(tooltip.DropdownMenuContent,{className:"w-56 border-border text-xs",children:[jsxRuntime.jsx(tooltip.DropdownMenuLabel,{children:U("Screen sizes")}),jsxRuntime.jsx(tooltip.DropdownMenuSeparator,{}),lodashEs.map(M,ee=>jsxRuntime.jsx(tooltip.DropdownMenuCheckboxItem,{disabled:ee.breakpoint==="xs",onCheckedChange:()=>D(lodashEs.toUpper(ee.breakpoint)),checked:lodashEs.includes(T,lodashEs.toUpper(ee.breakpoint)),onSelect:ae=>ae.preventDefault(),children:U(ee.title)},ee.breakpoint))]})]})]})};function BreakpointSelector(){const[,n]=useScreenSizeWidth(),c=React.useMemo(()=>{const d=WEB_BREAKPOINTS.find(x=>x.breakpoint===n);return d==null?void 0:d.content},[n,WEB_BREAKPOINTS]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("div",{className:"sticky top-0 z-10 flex items-center justify-start bg-muted px-2 py-1 shadow-sm",children:[jsxRuntime.jsx("p",{className:"text-xs text-muted-foreground",children:"Screen: "}),jsxRuntime.jsx(Breakpoints$1,{openDelay:1e3,tooltip:!1})]}),jsxRuntime.jsx("div",{className:"mb-2 flex items-center justify-between rounded-md rounded-t-none border border-border p-1",children:jsxRuntime.jsx("p",{className:"flex flex-1 items-center space-x-2 text-[10px] text-foreground",children:jsxRuntime.jsxs("span",{className:"text-xs text-foreground",children:[jsxRuntime.jsx("span",{className:"rounded-md bg-muted px-1 py-px text-xs font-bold uppercase text-muted-foreground",children:n==="xs"?"Base":n}),"  ",c]})})})]})}function ManualClasses(){var je;const n=React.useRef(null),[c,d]=React.useState(""),[x,b]=React.useState(-1),y=useFuseSearch(),{t:R}=reactI18next.useTranslation(),[S]=useSelectedStylingBlocks(),_=useSelectedBlock(),A=useAddClassesToBlocks(),L=useRemoveClassesFromBlocks(),[T]=useSelectedBlockIds(),[O,U]=React.useState(""),M=(je=lodashEs.first(S))==null?void 0:je.prop,{classes:D}=applyBinding.getSplitChaiClasses(lodashEs.get(_,M,"")),K=D.split(" ").filter(ze=>!lodashEs.isEmpty(ze)),$=useBuilderProp("flags.copyPaste",!0),ee=()=>{const ze=O.trim().toLowerCase().replace(/ +(?= )/g,"").split(" ");A(T,ze,!0),U("")},[ae,Re]=React.useState([]),ye=({value:ze})=>{const We=ze.trim().toLowerCase(),Pe=We.match(/.+:/g);let ue=[];if(Pe&&Pe.length>0){const[Ae]=Pe,He=We.replace(Ae,"");ue=y.search(He).map(Ie=>({...Ie,item:{...Ie.item,name:Ae+Ie.item.name}}))}else ue=y.search(We);return Re(lodashEs.map(ue,"item"))},de=()=>{Re([])},q=ze=>ze.name,he=ze=>jsxRuntime.jsx("div",{className:"rounded-md p-1",children:ze.name}),le=React.useMemo(()=>({ref:n,autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",spellCheck:!1,placeholder:R("Enter classes separated by space"),value:O,onFocus:ze=>{setTimeout(()=>{ze.target&&ze.target.select()},0)},onKeyDown:ze=>{ze.key==="Enter"&&O.trim()!==""&&ee()},onChange:(ze,{newValue:We})=>U(We),className:"w-full rounded-md text-xs px-2 hover:outline-0 bg-background border-border py-1"}),[O,R,n]),xe=ze=>{debugger;const We=c.trim().toLowerCase().replace(/ +(?= )/g,"").split(" ");L(T,[ze]),A(T,We,!0),d(""),b(-1)},Ee=()=>{if(navigator.clipboard===void 0){sonner.toast.error(R("Clipboard not supported"));return}navigator.clipboard.writeText(K.join(" ")),sonner.toast.success(R("Classes copied to clipboard"))};return jsxRuntime.jsxs("div",{className:"flex w-full flex-col gap-y-1.5 border-b border-border pb-4",children:[jsxRuntime.jsx("div",{className:"flex items-center justify-between gap-x-2",children:jsxRuntime.jsxs("div",{className:"flex items-center gap-x-2 text-muted-foreground",children:[jsxRuntime.jsx("span",{children:R("Classes")}),$&&jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx(reactIcons.CopyIcon,{onClick:Ee,className:"cursor-pointer"})}),jsxRuntime.jsx(tooltip.TooltipContent,{children:jsxRuntime.jsx("p",{children:R("Copy classes to clipboard")})})]})]})}),jsxRuntime.jsxs("div",{className:"relative flex items-center gap-x-3",children:[jsxRuntime.jsx("div",{className:"relative flex w-full items-center gap-x-3",children:jsxRuntime.jsx(Autosuggest,{suggestions:ae,onSuggestionsFetchRequested:ye,onSuggestionsClearRequested:de,getSuggestionValue:q,renderSuggestion:he,inputProps:le,containerProps:{className:"relative h-8 w-full gap-y-1 py-1 border-border text-xs"},theme:{suggestion:"bg-transparent",suggestionHighlighted:"!bg-gray-300 dark:!bg-gray-800 cursor-pointer",suggestionsContainerOpen:"absolute bg-background no-scrollbar z-50 max-h-[230px] overflow-y-auto w-full border border-border rounded-md"}})}),jsxRuntime.jsx(tooltip.Button,{variant:"outline",className:"h-6 border-border",onClick:ee,disabled:O.trim()==="",size:"sm",children:jsxRuntime.jsx(reactIcons.PlusIcon,{})})]}),jsxRuntime.jsx("div",{className:"flex w-full flex-wrap gap-2 overflow-x-hidden",children:K.map((ze,We)=>x===We?jsxRuntime.jsx("input",{ref:n,value:c,onChange:Pe=>d(Pe.target.value),onBlur:()=>{xe(ze)},onKeyDown:Pe=>{Pe.key==="Enter"&&xe(ze)},onFocus:Pe=>{setTimeout(()=>{Pe.target.select()},0)},className:"group relative flex max-w-[260px] cursor-default items-center gap-x-1 truncate break-words rounded border border-border bg-gray-200 p-px px-1.5 pr-2 text-[11px] text-gray-600 hover:border-gray-300 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-300"},ze):jsxRuntime.jsx("div",{className:"group relative flex max-w-[260px] items-center",children:jsxRuntime.jsxs("button",{onDoubleClick:()=>{U(ze),L(T,[ze]),setTimeout(()=>{n.current&&n.current.focus()},10)},className:"flex h-max cursor-default items-center gap-x-1 truncate break-words rounded bg-gray-200 py-px pl-0.5 pr-1 text-[11px] text-gray-600 dark:bg-gray-800 dark:text-gray-300",children:[jsxRuntime.jsxs("div",{className:"z-10 flex h-full w-max items-center justify-center",children:[jsxRuntime.jsx(reactIcons.Cross2Icon,{onClick:()=>L(T,[ze],!0),className:"hidden h-max w-3.5 cursor-pointer rounded bg-gray-100 p-0.5 text-red-500 hover:bg-gray-50 group-hover:block"}),jsxRuntime.jsxs("svg",{className:"h-3.5 w-3.5 group-hover:hidden",fill:"rgba(55, 65, 81, 0.4)",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",xmlSpace:"preserve",children:[jsxRuntime.jsx("g",{id:"SVGRepo_bgCarrier",strokeWidth:"0"}),jsxRuntime.jsx("g",{id:"SVGRepo_tracerCarrier",strokeLinecap:"round",strokeLinejoin:"round"}),jsxRuntime.jsx("g",{id:"SVGRepo_iconCarrier",children:jsxRuntime.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12 6.036c-2.667 0-4.333 1.325-5 3.976 1-1.325 2.167-1.822 3.5-1.491.761.189 1.305.738 1.906 1.345C13.387 10.855 14.522 12 17 12c2.667 0 4.333-1.325 5-3.976-1 1.325-2.166 1.822-3.5 1.491-.761-.189-1.305-.738-1.907-1.345-.98-.99-2.114-2.134-4.593-2.134zM7 12c-2.667 0-4.333 1.325-5 3.976 1-1.326 2.167-1.822 3.5-1.491.761.189 1.305.738 1.907 1.345.98.989 2.115 2.134 4.594 2.134 2.667 0 4.333-1.325 5-3.976-1 1.325-2.167 1.822-3.5 1.491-.761-.189-1.305-.738-1.906-1.345C10.613 13.145 9.478 12 7 12z"})})]})]}),jsxRuntime.jsx("div",{children:ze})]})},ze))})]})}const BASIC_UNITS=["px","%","em","rem","ch","vh","vw"],FLEX_CHILD_SECTION={heading:"flex.heading",items:[{type:"arbitrary",label:"flex.basis",units:BASIC_UNITS,property:"flexBasis"},{type:"range",label:"flex.order",property:"order"},{type:"dropdown",label:"flex.flex",property:"flexGrowShrink"},{type:"dropdown",label:"flex.grow",property:"flexGrow"},{type:"dropdown",label:"flex.shrink",property:"flexShrink"}]},GRID_CHILD_SECTION={heading:"grid.heading",items:[{type:"range",label:"grid.col_span",property:"gridColSpan"},{type:"range",label:"grid.col_start",property:"gridColStart"},{type:"range",label:"grid.col_end",property:"gridColEnd"},{type:"range",label:"grid.row_span",property:"gridRowSpan"},{type:"range",label:"grid.row_start",property:"gridRowStart"},{type:"range",label:"grid.row_end",property:"gridRowEnd"},{type:"range",label:"grid.order",property:"order"}]},SETTINGS_SECTIONS=[{heading:"Styles",items:[{component:ManualClasses},{component:BreakpointSelector},{type:"arbitrary",label:"layout.width",units:BASIC_UNITS.concat("auto"),property:"width"},{type:"arbitrary",label:"layout.height",units:BASIC_UNITS.concat("auto"),property:"height"},{styleType:"multiple",label:"layout.margin",negative:!0,units:[...BASIC_UNITS,"auto"],options:[{key:"margin",label:"layout.margin_all"},{key:"marginX",label:"layout.margin_lr"},{key:"marginY",label:"layout.margin_tb"},{key:"marginTop",label:"layout.margin_top"},{key:"marginRight",label:"layout.margin_right"},{key:"marginBottom",label:"layout.margin_bottom"},{key:"marginLeft",label:"layout.margin_left"}]},{styleType:"multiple",label:"layout.padding",options:[{key:"padding",label:"layout.padding_all"},{key:"paddingX",label:"layout.padding_lr"},{key:"paddingY",label:"layout.padding_tb"},{key:"paddingTop",label:"layout.padding_top"},{key:"paddingRight",label:"layout.padding_right"},{key:"paddingBottom",label:"layout.padding_bottom"},{key:"paddingLeft",label:"layout.padding_left"}]},{styleType:"accordion",heading:"Typography",items:[{type:"dropdown",property:"textAlign",label:"typography.align"},{type:"dropdown",property:"fontFamily",label:"typography.font"},{type:"arbitrary",property:"fontSize",label:"typography.size",units:BASIC_UNITS},{type:"arbitrary",property:"lineHeight",label:"typography.height",units:BASIC_UNITS.concat("-")},{type:"range",property:"fontWeight",label:"typography.weight"},{type:"color",property:"textColor",label:"typography.color"}]},{styleType:"accordion",heading:"Background",items:[{type:"color",label:"background.bgcolor",property:"backgroundColor"},{type:"dropdown",label:"background.attachment",property:"backgroundAttachment"},{type:"dropdown",label:"background.clipping",property:"backgroundClip"},{type:"dropdown",label:"background.origin",property:"backgroundOrigin"},{type:"dropdown",label:"background.position",property:"backgroundPosition"},{type:"dropdown",label:"background.repeat",property:"backgroundRepeat"},{type:"dropdown",label:"background.size",property:"backgroundSize"}]}]}];BASIC_UNITS.concat("auto"),BASIC_UNITS.concat("auto"),[...BASIC_UNITS],BASIC_UNITS.concat("auto"),BASIC_UNITS.concat("auto"),BASIC_UNITS.concat("auto"),BASIC_UNITS.concat("auto"),BASIC_UNITS.concat("-");const MAPPER={px:1,"%":1,em:100,rem:100,ch:1,vw:1,vh:1,"-":1,deg:1,ms:.1};function BlockStyling(){const{flexChild:n,gridChild:c}=useSelectedBlocksDisplayChild(),[d]=useSelectedStylingBlocks(),[x,b]=React.useState(""),[y,R]=React.useState({onDrag:A=>A,onDragEnd:A=>A,dragStartY:0,dragging:!1,dragStartValue:0,dragUnit:"",negative:!1,cssProperty:""}),S=web.useThrottledCallback(A=>{const L=!lodashEs.get(y,"negative",!1),T=lodashEs.get(y,"cssProperty","");let O=parseFloat(y.dragStartValue);O=isNaN(O)?0:O;let U=MAPPER[y.dragUnit];(lodashEs.startsWith(T,"scale")||T==="opacity")&&(U=10);let D=(y.dragStartY-A.pageY)/U+O;L&&D<0&&(D=0),T==="opacity"&&D>1&&(D=1),y.onDrag(`${D}`),b(`${D}`)},[y],50),_=React.useCallback(()=>{setTimeout(()=>y.onDragEnd(`${x}`),100),R({onDrag:A=>A,onDragEnd:A=>A,dragStartY:0,dragging:!1,dragStartValue:0,dragUnit:"",negative:!1,cssProperty:""})},[y,x,R]);return lodashEs.isEmpty(d)?null:jsxRuntime.jsxs(BlockSettingsContext.Provider,{value:{setDragData:R},children:[y.dragging?jsxRuntime.jsx("div",{onMouseMove:S,onMouseUp:()=>_(),className:"absolute inset-0 z-30 cursor-row-resize bg-gray-300/10"}):null,jsxRuntime.jsxs("div",{className:"flex flex-col",children:[jsxRuntime.jsx(BlockStylingProps,{}),jsxRuntime.jsxs(tooltip.Accordion,{defaultValue:["Styles"],type:"multiple",className:"w-full",children:[n&&jsxRuntime.jsx(StylingGroup,{section:FLEX_CHILD_SECTION,showAccordian:n||c}),c&&jsxRuntime.jsx(StylingGroup,{section:GRID_CHILD_SECTION,showAccordian:n||c}),SETTINGS_SECTIONS.map(A=>jsxRuntime.jsx(StylingGroup,{section:A,showAccordian:n||c},A.heading))]})]})]})}const CoreBlock=({block:n,disabled:c,parentId:d,position:x})=>{const{type:b,icon:y,label:R}=n,{addCoreBlock:S,addPredefinedBlock:_}=useAddBlock(),A=()=>{if(lodashEs.has(n,"blocks")){const M=lodashEs.isFunction(n.blocks)?n.blocks():n.blocks;_(runtime.syncBlocksWithDefaults(M),d||null,x)}else S(n,d||null,x);pubsub.publish(CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK)},L=useIsDragAndDropEnabled(),{t:T}=reactI18next.useTranslation(),{onDragStart:O,onDragEnd:U}=useDragAndDrop();return jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsxs("button",{disabled:c,onClick:A,type:"button",onDragStart:M=>O(M,{...n,label:R,icon:y}),onDragEnd:U,draggable:L,className:`${lodashEs.kebabCase(`chai-block-${b}`)} ${L?"cursor-grab active:cursor-grabbing":"cursor-pointer"} space-y-2 rounded-lg border border-border p-3 text-center hover:bg-slate-300/50 disabled:cursor-not-allowed disabled:bg-gray-100 disabled:text-gray-400 dark:border-gray-700 dark:text-white dark:hover:bg-slate-800/50 dark:disabled:bg-gray-900 dark:disabled:text-foreground ${c?"opacity-50":""}`,children:[React.createElement(y||reactIcons.BoxIcon,{className:"w-4 h-4 mx-auto"}),jsxRuntime.jsx("p",{className:"truncate text-xs",children:lodashEs.capitalize(T(R||b))})]})}),jsxRuntime.jsx(tooltip.TooltipContent,{children:jsxRuntime.jsx("p",{children:T(R||b)})})]})})},DefaultChaiBlocks=({parentId:n,position:c,gridCols:d="grid-cols-2",disableBlockGroupsSidebar:x=!1})=>{const b=runtime.useRegisteredChaiBlocks(),y=lodashEs.groupBy(b,"category"),R=lodashEs.uniq(lodashEs.map(y.core,"group"));return jsxRuntime.jsx(ChaiBuilderBlocks,{gridCols:d,parentId:n,position:c,groups:R,blocks:y.core,disableBlockGroupsSidebar:x})};let PRE_IMPORT_HTML_HOOK=async n=>n;const registerChaiPreImportHTMLHook=n=>{PRE_IMPORT_HTML_HOOK=n},getPreImportHTML=async n=>await PRE_IMPORT_HTML_HOOK(n),ImportHTML=({parentId:n,position:c,fromSidebar:d})=>{const{t:x}=reactI18next.useTranslation(),[b,y]=React.useState(""),{addPredefinedBlock:R}=useAddBlock(),[S,_]=React.useState(!1),A=async()=>{_(!0);const L=await getPreImportHTML(b),T=applyBinding.getBlocksFromHTML(L);R([...T],n,c),y(""),_(!1),pubsub.publish(CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK)};return jsxRuntime.jsxs(tooltip.Card,{className:`border-border/0 p-0 shadow-none ${d?"w-full":"max-w-full"}`,children:[jsxRuntime.jsx(tooltip.CardHeader,{className:d?"p-0":"p-3",children:jsxRuntime.jsx(tooltip.CardDescription,{className:d?"text-xs":"",children:x("Use HTML snippets from Tailwind CSS component libraries")})}),jsxRuntime.jsx(tooltip.CardContent,{className:`space-y-2 py-0 ${d?"p-0":"px-3"}`,children:jsxRuntime.jsxs("div",{className:"space-y-1",children:[jsxRuntime.jsx(tooltip.Label,{htmlFor:"current",className:"text-sm",children:x("Tailwind HTML snippet")}),jsxRuntime.jsx(tooltip.Textarea,{autoFocus:!0,tabIndex:1,ref:L=>L&&L.focus(),onChange:L=>y(L.target.value),rows:12,value:b,placeholder:x("Enter your code snippet here"),className:"resize-none overflow-x-auto whitespace-pre bg-background font-mono text-xs font-normal"})]})}),jsxRuntime.jsx(tooltip.CardFooter,{className:"flex flex-col justify-end p-3",children:jsxRuntime.jsx(tooltip.Button,{disabled:b.trim()===""||S,onClick:()=>A(),size:"sm",className:"w-fit",children:S?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(reactIcons.CircleIcon,{className:"mr-2 h-4 w-4 animate-spin"})," ",x("Importing...")]}):x("Import HTML")})})]})},ChaiSelect=({defaultValue:n="",onValueChange:c,options:d,placeholder:x="Select",className:b="",height:y=""})=>{const[R,S]=React.useState(n),_=A=>{const L=A.target.value;S(L),c(L)};return jsxRuntime.jsx("div",{className:commonFunctions.cn("relative inline-block w-full",b),children:jsxRuntime.jsxs("select",{className:commonFunctions.cn("mt-1 flex w-full rounded-md border border-border bg-background px-3 py-1 text-sm text-foreground shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50",y),value:R,onChange:_,children:[jsxRuntime.jsx("option",{value:"",disabled:!0,children:x}),d.map(A=>jsxRuntime.jsx("option",{value:A.value,children:A.label},A.value))]})})};function UILibrariesSelect({uiLibraries:n,library:c,setLibrary:d}){const{t:x}=reactI18next.useTranslation();return c?jsxRuntime.jsxs("div",{className:"h-12",children:[jsxRuntime.jsx("p",{className:"text-xs font-bold text-gray-500",children:x("Choose library")}),jsxRuntime.jsx(ChaiSelect,{className:"mb-1",options:n.map(b=>({value:b.id,label:b.name})),defaultValue:c,onValueChange:b=>d(b)})]}):null}let LIBRARIES_REGISTRY={};const registerChaiLibrary=(n,c)=>{LIBRARIES_REGISTRY[n]={...c,id:n}},useChaiLibraries=()=>lodashEs.values(LIBRARIES_REGISTRY),ChaiDraggableBlock=({block:n,html:c,blocks:d,children:x,onDragStart:b,onDragEnd:y,draggable:R,className:S=""})=>{const{onDragStart:_,onDragEnd:A}=useDragAndDrop(),L=useIsDragAndDropEnabled(),[,T]=useSelectedBlockIds(),{clearHighlight:O}=useBlockHighlight(),U=R!==void 0?R:L,M=async K=>{try{if(b){b(K);return}let $=null;if(c){const ee=typeof c=="function"?await c():c,ae=applyBinding.getBlocksFromHTML(ee);if(lodashEs.isEmpty(ae))return;$={type:"Box",blocks:ae,name:lodashEs.get(ae,"0._type","Block")}}else if(d){const ee=typeof d=="function"?await d():d;if(lodashEs.isEmpty(ee))return;$={type:"Box",blocks:ee,name:lodashEs.get(ee,"0._type","Block")}}else if(n){const ee=typeof n=="function"?await n():n;$=typeof ee=="object"?lodashEs.omit(ee,["component","icon"]):ee}if(!$)return;_(K,$,!0),setTimeout(()=>{T([]),O()},200)}catch($){console.error("Error in ChaiDraggableBlock drag start:",$)}},D=K=>{y?y(K):A()};return jsxRuntime.jsx("div",{draggable:U,onDragStart:M,onDragEnd:D,className:`${U?"cursor-grab active:cursor-grabbing":""} ${S}`.trim(),children:x})};function SearchInput({value:n,setValue:c}){const{t:d}=reactI18next.useTranslation();return jsxRuntime.jsx("div",{className:"flex py-2",children:jsxRuntime.jsxs("div",{className:"relative flex w-full max-w-md items-center rounded border px-2",children:[jsxRuntime.jsxs("div",{className:"flex w-full items-center gap-x-2",children:[jsxRuntime.jsx(reactIcons.MagnifyingGlassIcon,{className:"h-5 w-5 flex-shrink-0 stroke-[1px] text-muted-foreground"}),jsxRuntime.jsx(tooltip.Input,{placeholder:d("Search blocks..."),value:n,onChange:x=>c(x.target.value),className:"w-full flex-1 border-none p-0 leading-tight outline-none"})]}),n&&jsxRuntime.jsx("button",{onClick:()=>c(""),className:"absolute right-2.5 top-2.5 text-muted-foreground hover:text-foreground",children:jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-3.5 w-3.5"})})]})})}const BlockCard=({block:n,library:c,parentId:d=void 0,position:x=-1})=>{const[b,y]=React.useState(!1),R=React.useMemo(()=>(c==null?void 0:c.getBlock)||(()=>[]),[c]),{addCoreBlock:S,addPredefinedBlock:_}=useAddBlock(),A=lodashEs.get(n,"name",lodashEs.get(n,"label")),L=lodashEs.get(n,"description",""),{onDragStart:T,onDragEnd:O}=useDragAndDrop(),U=useIsDragAndDropEnabled(),M=React.useCallback(async K=>{if(K.stopPropagation(),lodashEs.has(n,"component")){S(n,d,x),pubsub.publish(CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK);return}y(!0);let $=await R({library:c,block:n});typeof $=="string"&&($=applyBinding.getBlocksFromHTML($)),lodashEs.isEmpty($)||_(runtime.syncBlocksWithDefaults($),d,x),pubsub.publish(CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK),setTimeout(()=>y(!1),1e3)},[S,_,n,R,c,d,x]),D=async K=>{if(!U)return;let $=await R({library:c,block:n});typeof $=="string"&&($=applyBinding.getBlocksFromHTML($)),T(K,{type:"Box",blocks:$,name:A},!0)};return jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx(ChaiDraggableBlock,{draggable:U,onDragStart:D,onDragEnd:O,children:jsxRuntime.jsxs("div",{onClick:b?()=>{}:M,className:clsx("relative mt-2 cursor-pointer overflow-hidden rounded-md border border-border duration-200 hover:border-blue-500 hover:shadow-xl"),children:[b&&jsxRuntime.jsxs("div",{className:"absolute flex h-full w-full items-center justify-center bg-black/70",children:[jsxRuntime.jsx(reactIcons.ReloadIcon,{className:"h-4 w-4 animate-spin text-white"}),jsxRuntime.jsx("span",{className:"pl-2 text-sm text-white",children:"Adding..."})]}),n.preview?jsxRuntime.jsx("img",{src:n.preview,className:`min-h-[45px] w-full rounded-md ${U?"cursor-grab active:cursor-grabbing":""}`,alt:A}):jsxRuntime.jsxs("div",{className:"flex h-fit w-full flex-col items-center justify-center gap-1 rounded-md border border-border p-6 py-10 text-center",children:[jsxRuntime.jsx("p",{className:"font-medium text-gray-800",children:A}),L&&jsxRuntime.jsx("p",{className:"text-sm text-gray-600",children:L})]})]})})}),jsxRuntime.jsx(tooltip.TooltipContent,{children:jsxRuntime.jsx("div",{className:"max-w-xs",children:jsxRuntime.jsx("p",{className:"font-medium",children:A})})})]})},UILibrarySection=({parentId:n,position:c,fromSidebar:d})=>{const[x,b]=useSelectedLibrary(),y=useChaiLibraries(),R=y.find(xe=>xe.id===x)||lodashEs.first(y),{data:S,isLoading:_,resetLibrary:A}=useLibraryBlocks(R),[L,T]=React.useState(""),[O,U]=React.useState([]),M=React.useRef(null);React.useEffect(()=>{S&&S.length>0&&(M.current=new Fuse(S,{keys:["name","label","description","group"],threshold:.4,ignoreLocation:!0}))},[S]),React.useEffect(()=>{if(!L.trim()||!M.current){U([]);return}const xe=M.current.search(L).map(Ee=>Ee.item);U(xe)},[L]);const D=L.trim()&&!lodashEs.isEmpty(O)?O:S,K=lodashEs.groupBy(D,"group"),[$,ee]=React.useState(null);React.useEffect(()=>{if(lodashEs.isEmpty(lodashEs.keys(K))){ee(null);return}if(!$||!K[$]){ee(lodashEs.first(lodashEs.keys(K)));return}},[K,$]);const ae=lodashEs.get(K,$,[]),Re=React.useRef(null),{t:ye}=reactI18next.useTranslation(),de=xe=>{Re.current&&(clearTimeout(Re.current),Re.current=null),Re.current=setTimeout(()=>{Re.current&&ee(xe)},400)},q=()=>{R!=null&&R.id&&A(R.id)};if(_)return jsxRuntime.jsxs("div",{className:"mt-4 grid h-full w-full grid-cols-12 gap-2",children:[jsxRuntime.jsx(tooltip.Skeleton,{className:"col-span-3 h-full"}),jsxRuntime.jsx(tooltip.Skeleton,{className:"col-span-9 h-full"})]});const he=lodashEs.filter(ae,(xe,Ee)=>Ee%2===0),le=lodashEs.filter(ae,(xe,Ee)=>Ee%2===1);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsxs("div",{className:"flex h-full max-h-full flex-col",children:[jsxRuntime.jsx(SearchInput,{value:L,setValue:T}),jsxRuntime.jsx("div",{className:"relative flex h-full max-h-full flex-1 overflow-hidden bg-background",children:jsxRuntime.jsxs("div",{className:`flex h-full flex-1 pt-2 ${d?"flex-col":""}`,children:[jsxRuntime.jsxs("div",{className:`flex h-full max-h-full min-w-60 flex-col gap-1 ${d?"pb-2":"w-60 max-w-60 px-1 pr-2"}`,children:[jsxRuntime.jsx(UILibrariesSelect,{library:R==null?void 0:R.id,setLibrary:b,uiLibraries:y}),jsxRuntime.jsxs("div",{className:"mt-2 flex h-full max-h-full w-full flex-1 flex-col",children:[jsxRuntime.jsx("span",{className:"text-xs font-bold text-gray-500",children:ye("Groups")}),!d&&jsxRuntime.jsx("hr",{className:"mt-1 border-border"}),jsxRuntime.jsx("div",{className:`no-scrollbar mt-2 h-full max-h-full flex-1 overflow-y-auto ${d?"":"pb-20"}`,children:lodashEs.isEmpty(K)?jsxRuntime.jsx("div",{className:"mt-4 flex flex-col items-center justify-center gap-3 p-4 text-center",children:L?jsxRuntime.jsx("p",{className:"text-sm",children:ye("No matching blocks found")}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("p",{className:"text-sm",children:ye("Failed to load the UI library. Try again")}),jsxRuntime.jsxs(tooltip.Button,{onClick:q,variant:"outline",size:"sm",className:"gap-2",children:[jsxRuntime.jsx(reactIcons.ReloadIcon,{className:"h-4 w-4"}),ye("Retry")]})]})}):d?jsxRuntime.jsxs(tooltip.Select,{value:$,onValueChange:ee,children:[jsxRuntime.jsx(tooltip.SelectTrigger,{className:"w-full",children:jsxRuntime.jsx(tooltip.SelectValue,{placeholder:ye("Select a group")})}),jsxRuntime.jsx(tooltip.SelectContent,{children:lodashEs.map(K,(xe,Ee)=>jsxRuntime.jsx(tooltip.SelectItem,{value:Ee,children:lodashEs.capitalize(ye(Ee.toLowerCase()))},Ee))})]}):lodashEs.map(K,(xe,Ee)=>jsxRuntime.jsxs("div",{onMouseEnter:()=>de(Ee),onMouseLeave:()=>clearTimeout(Re.current),role:"button",onClick:()=>ee(Ee),className:tooltip.cn("flex w-full cursor-pointer items-center justify-between rounded-md p-2 text-sm text-foreground transition-all ease-in-out hover:bg-gray-200 dark:hover:bg-gray-800",Ee===$?"bg-primary text-primary-foreground hover:bg-primary/80":""),children:[jsxRuntime.jsx("span",{children:lodashEs.capitalize(ye(Ee.toLowerCase()))}),jsxRuntime.jsx(reactIcons.CaretRightIcon,{className:"ml-2 h-5 w-5"})]},Ee))})]})]}),jsxRuntime.jsx("div",{className:`flex h-full max-h-full w-full flex-col border-border ${d?"":"border-l"}`,children:jsxRuntime.jsxs(tooltip.ScrollArea,{onMouseEnter:()=>Re.current?clearTimeout(Re.current):null,className:"z-10 flex h-full max-h-full w-full flex-col gap-2 transition-all ease-linear",children:[lodashEs.isEmpty(ae)&&!lodashEs.isEmpty(K)?jsxRuntime.jsx("div",{className:"flex h-full flex-col items-center justify-center p-6 text-center",children:jsxRuntime.jsx("p",{className:"text-sm",children:ye("No blocks found in this group")})}):jsxRuntime.jsxs("div",{className:`grid w-full gap-2 ${d?"grid-cols-1 pb-20":"grid-cols-2 px-2"}`,children:[jsxRuntime.jsx("div",{className:"flex flex-col gap-1",children:he.map((xe,Ee)=>jsxRuntime.jsx(BlockCard,{parentId:n,position:c,block:xe,library:R},`block-${Ee}`))}),jsxRuntime.jsx("div",{className:"flex flex-col gap-1",children:le.map((xe,Ee)=>jsxRuntime.jsx(BlockCard,{parentId:n,position:c,block:xe,library:R},`block-second-${Ee}`))})]}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{})]})})]})})]})})},UILibrariesPanel=({parentId:n,position:c,fromSidebar:d})=>jsxRuntime.jsx(UILibrarySection,{parentId:n,position:c,fromSidebar:d}),partialBlocksDataAtom=jotai.atom({blocks:[],groups:[],isLoading:!0,error:null}),hasInitializedPartialBlocksAtom=jotai.atom(!1),formatReadableName=n=>{if(!n)return"";let c=n.replace(/[-_]/g," ");return c=c.replace(/([a-z])([A-Z])/g,"$1 $2"),c.split(" ").map(d=>d.charAt(0).toUpperCase()+d.slice(1).toLowerCase()).join(" ")},PartialBlocks=({parentId:n,position:c,gridCols:d="grid-cols-2",disableBlockGroupsSidebar:x=!1})=>{const{data:b,isLoading:y,refetch:R,error:S}=usePartialBlocksList(),[_,A]=jotai.useAtom(partialBlocksDataAtom),[L,T]=jotai.useAtom(hasInitializedPartialBlocksAtom);React.useEffect(()=>{if(!L||Object.keys(_.blocks).length===0)if(S)A({blocks:[],groups:[],isLoading:!1,error:S}),T(!0);else if(!y&&Object.keys(b||{}).length>0){const U=Object.entries(b).map(([D,K])=>{const $=K,ee=$.type||"partial",ae=formatReadableName(ee);return{type:"PartialBlock",label:formatReadableName($.name||D),description:$.description||"",icon:reactIcons.FrameIcon,group:ae,category:"partial",partialBlockId:D,_name:$.name}}),M=lodashEs.uniq(lodashEs.map(U,"group"));A({blocks:U,groups:M,isLoading:!1,error:null}),T(!0)}else y?A(U=>({...U,isLoading:!0,error:null})):!y&&Object.keys(b||{}).length===0&&(A({blocks:[],groups:[],isLoading:!1,error:"No partial blocks available"}),T(!0))},[y,b,L,T,A,_.blocks,S]);const O=()=>{A(U=>({...U,isLoading:!0,error:null})),T(!1),R()};return _.isLoading?jsxRuntime.jsx("div",{className:"flex items-center justify-center p-8 text-center text-muted-foreground",children:"Loading partial blocks..."}):_.error||_.blocks.length===0?jsxRuntime.jsxs("div",{className:"flex flex-col items-center justify-center gap-4 p-8 text-center text-muted-foreground",children:[jsxRuntime.jsx("p",{children:_.error||"No partial blocks available"}),jsxRuntime.jsx("button",{onClick:O,className:"rounded-md bg-primary px-3 py-1 text-sm text-primary-foreground hover:bg-primary/90",children:"Refresh"})]}):jsxRuntime.jsx(ChaiBuilderBlocks,{gridCols:d,parentId:n,position:c,groups:_.groups,blocks:_.blocks,disableBlockGroupsSidebar:x})},ADD_BLOCK_TABS={},registerChaiAddBlockTab=(n,c)=>{lodashEs.has(ADD_BLOCK_TABS,n)&&console.warn(`Add block tab with id ${n} already registered`),lodashEs.set(ADD_BLOCK_TABS,n,{id:n,...c})},useChaiAddBlockTabs=()=>React.useMemo(()=>lodashEs.values(ADD_BLOCK_TABS),[]),CORE_GROUPS=["basic","typography","media","layout","form","advanced","other"],ChaiBuilderBlocks=({groups:n,blocks:c,parentId:d,position:x,gridCols:b="grid-cols-4",disableBlockGroupsSidebar:y})=>{var xe;const{t:R}=reactI18next.useTranslation(),[S]=useBlocksStore(),[_,A]=React.useState(""),L=React.useRef(null),[T]=jotai.useAtom(addBlockTabAtom),O=(xe=lodashEs.find(S,Ee=>Ee._id===d))==null?void 0:xe._type,[U,M]=React.useState("all"),[D,K]=React.useState(null),$=React.useRef(null);React.useEffect(()=>{const Ee=setTimeout(()=>{var je;(je=L.current)==null||je.focus()},0);return()=>clearTimeout(Ee)},[T]),React.useEffect(()=>{_&&(M("all"),K(null))},[_]),React.useEffect(()=>($.current=lodashEs.debounce(Ee=>{M(Ee)},500),()=>{$.current&&$.current.cancel()}),[]);const ee=React.useCallback(Ee=>{K(Ee),$.current&&$.current(Ee)},[]),ae=React.useCallback(()=>{K(null),$.current&&$.current.cancel()},[]),Re=React.useCallback(Ee=>{$.current&&$.current.cancel(),M(Ee),K(null)},[]),ye=React.useMemo(()=>_?lodashEs.values(c).filter(Ee=>{var je,ze;return(((je=Ee.label)==null?void 0:je.toLowerCase())+" "+((ze=Ee.type)==null?void 0:ze.toLowerCase())).includes(_.toLowerCase())}):c,[c,_]),de=React.useMemo(()=>_?n.filter(Ee=>lodashEs.reject(lodashEs.filter(lodashEs.values(ye),{group:Ee}),{hidden:!0}).length>0):n.filter(Ee=>lodashEs.reject(lodashEs.filter(lodashEs.values(c),{group:Ee}),{hidden:!0}).length>0),[c,ye,n,_]),q=React.useMemo(()=>lodashEs.sortBy(de,Ee=>CORE_GROUPS.indexOf(Ee)===-1?99:CORE_GROUPS.indexOf(Ee)),[de]),he=React.useMemo(()=>U==="all"?ye:lodashEs.filter(lodashEs.values(ye),{group:U}),[ye,U]),le=React.useMemo(()=>U==="all"?q:[U],[q,U]);return jsxRuntime.jsxs("div",{className:"mx-auto flex h-full w-full flex-col",children:[jsxRuntime.jsx(SearchInput,{value:_,setValue:A}),jsxRuntime.jsxs("div",{className:"sticky top-10 flex h-[calc(100%-48px)] overflow-hidden pt-2",children:[!y&&q.length>0&&jsxRuntime.jsx("div",{className:"w-1/4 min-w-[120px] border-r border-border",children:jsxRuntime.jsx(tooltip.ScrollArea,{className:"h-full",children:jsxRuntime.jsxs("div",{className:"space-y-1",children:[jsxRuntime.jsx("button",{onClick:()=>Re("all"),onMouseEnter:()=>ee("all"),onMouseLeave:ae,className:`w-full rounded-md px-2 py-1.5 text-left text-sm font-medium ${U==="all"||D==="all"?"bg-primary text-primary-foreground":"hover:bg-primary/50 hover:text-primary-foreground"}`,children:R("All")},"sidebar-all"),q.map(Ee=>jsxRuntime.jsx("button",{onClick:()=>Re(Ee),onMouseEnter:()=>ee(Ee),onMouseLeave:ae,className:`w-full rounded-md px-2 py-1.5 text-left text-sm ${U===Ee||D===Ee?"bg-primary text-primary-foreground":"hover:bg-primary/50 hover:text-primary-foreground"}`,children:lodashEs.capitalize(R(Ee.toLowerCase()))},`sidebar-${Ee}`))]})})}),jsxRuntime.jsx("div",{className:`h-full flex-1 overflow-hidden ${!y&&q.length>0?"w-3/4":"w-full"}`,children:jsxRuntime.jsx(tooltip.ScrollArea,{id:"add-blocks-scroll-area",className:"no-scrollbar h-full",children:de.length===0&&_?jsxRuntime.jsx("div",{className:"flex flex-col items-center justify-center p-8 text-center text-muted-foreground",children:jsxRuntime.jsxs("p",{children:[R("No blocks found matching"),' "',_,'"']})}):jsxRuntime.jsx("div",{className:`${y?"p-0":"p-4"} space-y-6`,children:le.map(Ee=>jsxRuntime.jsxs("div",{className:"space-y-3",children:[jsxRuntime.jsx("h3",{className:"px-1 text-sm font-medium",children:lodashEs.capitalize(R(Ee.toLowerCase()))}),jsxRuntime.jsx("div",{className:"grid gap-2 "+b,children:lodashEs.reject(U==="all"?lodashEs.filter(lodashEs.values(he),{group:Ee}):lodashEs.values(he),{hidden:!0}).map(je=>jsxRuntime.jsx(CoreBlock,{parentId:d,position:x,block:je,disabled:!canAcceptChildBlock(O,je.type)||!canBeNestedInside(O,je.type)},je.type))})]},Ee))})})})]})]})},addBlockTabAtom=utils.atomWithStorage("__add_block_tab","library"),AddBlocksPanel=({className:n,showHeading:c=!0,parentId:d=void 0,position:x=-1,fromSidebar:b=!1})=>{const{t:y}=reactI18next.useTranslation(),[R,S]=jotai.useAtom(addBlockTabAtom),[,_]=jotai.useAtom(showPredefinedBlockCategoryAtom),A=useBuilderProp("flags.importHtml",!0),{data:L}=usePartialBlocksList(),T=Object.keys(L||{}).length>0,{hasPermission:O}=usePermissions();React.useEffect(()=>{R==="partials"&&!T&&S("library")},[R,T,S]);const U=React.useCallback(()=>{pubsub.publish(CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK)},[]),M=useChaiAddBlockTabs(),D=A&&O(PERMISSIONS.IMPORT_HTML),$=useChaiLibraries().length>0;return React.useEffect(()=>{R==="library"&&!$&&S("core")},[R,$,S]),jsxRuntime.jsxs("div",{className:commonFunctions.cn("flex h-full w-full flex-col overflow-hidden",n),children:[c?jsxRuntime.jsxs("div",{className:"mb-2 flex flex-col justify-between rounded-md bg-background/30 p-1",children:[jsxRuntime.jsx("h1",{className:"flex flex-col items-baseline px-1 text-xl font-semibold xl:flex-col",children:y("Add block")}),jsxRuntime.jsx("span",{className:"p-0 text-xs font-light leading-3 opacity-80 xl:pl-1",children:y(R==="html"?"Enter or paste TailwindCSS HTML snippet":"Click to add block to page")})]}):null,jsxRuntime.jsxs(tooltip.Tabs,{onValueChange:ee=>{_(""),S(ee)},value:R,className:"flex h-full max-h-full flex-col overflow-hidden",children:[jsxRuntime.jsxs(tooltip.TabsList,{className:`flex items-center ${b?"h-max w-max justify-start p-1":"w-full"}`,children:[$&&jsxRuntime.jsx(tooltip.TabsTrigger,{value:"library",className:b?"h-5 px-2 text-xs":"",children:y("Library")}),jsxRuntime.jsx(tooltip.TabsTrigger,{value:"core",className:b?"h-5 px-2 text-xs":"",children:y("Blocks")}),T&&jsxRuntime.jsx(tooltip.TabsTrigger,{value:"partials",className:b?"h-5 px-2 text-xs":"",children:y("Partials")}),D?jsxRuntime.jsx(tooltip.TabsTrigger,{value:"html",className:b?"h-5 px-2 text-xs":"",children:y("Import")}):null,lodashEs.map(M,ee=>jsxRuntime.jsx(tooltip.TabsTrigger,{value:ee.id,className:b?"h-5 px-2 text-xs":"",children:React.createElement(ee.tab)},`tab-add-block-${ee.id}`))]}),jsxRuntime.jsx(tooltip.TabsContent,{value:"core",className:"h-full max-h-full flex-1 pb-20",children:jsxRuntime.jsx("div",{className:"h-full max-h-full overflow-hidden",children:jsxRuntime.jsx("div",{className:"h-full w-full",children:jsxRuntime.jsx(DefaultChaiBlocks,{gridCols:b?"grid-cols-2":"grid-cols-4",parentId:d,position:x,disableBlockGroupsSidebar:b})})})}),$&&jsxRuntime.jsx(tooltip.TabsContent,{value:"library",className:"h-full max-h-full flex-1 pb-20",children:jsxRuntime.jsx(UILibrariesPanel,{fromSidebar:b,parentId:d,position:x})}),T&&jsxRuntime.jsx(tooltip.TabsContent,{value:"partials",className:"h-full max-h-full flex-1 pb-20",children:jsxRuntime.jsx("div",{className:"h-full max-h-full overflow-hidden",children:jsxRuntime.jsx("div",{className:"h-full w-full",children:jsxRuntime.jsx(PartialBlocks,{gridCols:b?"grid-cols-2":"grid-cols-4",parentId:d,position:x,disableBlockGroupsSidebar:b})})})}),D?jsxRuntime.jsx(tooltip.TabsContent,{value:"html",className:"h-full max-h-full flex-1 pb-20 ",children:jsxRuntime.jsx(ImportHTML,{parentId:d,position:x,fromSidebar:b})}):null,lodashEs.map(M,ee=>jsxRuntime.jsx(tooltip.TabsContent,{value:ee.id,children:React.createElement(ee.tabContent,{close:U,parentId:d,position:x})},`panel-add-block-${ee.id}`))]})]})},placeholderStyle={display:"flex",alignItems:"center",zIndex:1},DefaultCursor=React.memo(function({top:c,left:d}){const x={position:"absolute",pointerEvents:"none",top:c+"px",left:d+"px",right:0};return jsxRuntime.jsx("div",{style:{...placeholderStyle,...x},children:jsxRuntime.jsx("div",{className:"h-0.5 flex-1 rounded-[1px] bg-green-500"})})}),Overlay=React.memo(function({children:c,isDragging:d}){return d?jsxRuntime.jsx("div",{className:"pointer-events-none fixed left-0 top-0 z-[100] h-full w-full",children:c}):null}),DefaultDragPreview=React.memo(({id:n,isDragging:c,mouse:d})=>{const[x]=useBlocksStore(),b=React.useMemo(()=>x.find(R=>R._id===n),[x,n]),y=React.useMemo(()=>({transform:`translate(${(d==null?void 0:d.x)-10}px, ${(d==null?void 0:d.y)-10}px)`}),[d]);return d?jsxRuntime.jsx("div",{children:jsxRuntime.jsx(Overlay,{isDragging:c,children:jsxRuntime.jsx("div",{className:"pointer-events-none absolute z-50 rounded border border-border bg-gray-100/80 font-semibold text-blue-600 shadow-md dark:border-gray-700 dark:bg-gray-800",style:y,children:jsxRuntime.jsxs("button",{type:"button",className:"flex !cursor-grab items-center p-0.5","aria-label":`Type: ${b==null?void 0:b._type}`,children:[jsxRuntime.jsx("div",{className:"-mt-0.5 h-3 w-3",children:jsxRuntime.jsx(TypeIcon,{type:b==null?void 0:b._type})}),jsxRuntime.jsx("div",{className:"ml-2 truncate text-[11px]",children:(b==null?void 0:b._name)||(b==null?void 0:b._type)})]})})})}):jsxRuntime.jsx("div",{className:"hidden"})}),defaultShortcuts=[{key:"ArrowDown",command:"selectNext"},{key:"ArrowUp",command:"selectPrev"},{key:"ArrowLeft",command:"selectParent",when:"isLeaf || isClosed"},{key:"ArrowLeft",command:"close",when:"isOpen"},{key:"ArrowRight",command:"open",when:"isClosed"},{key:"ArrowRight",command:"selectNext",when:"isOpen"},{key:"Home",command:"selectFirst"},{key:"End",command:"selectLast"}];function selectFirst(n){n.firstNode&&n.select(n.firstNode.id)}function selectLast(n){n.lastNode&&n.select(n.lastNode.id)}function selectNext(n){const c=n.selectedNodes[0].next||n.firstNode;n.select(c.id)}function selectPrev(n){const c=n.selectedNodes[0].prev||n.lastNode;n.select(c.id)}const selectParent=(n,c)=>{var x;const d=((x=n.selectedIds[0])==null?void 0:x.parent)||null;d&&c&&n.select(d.id)},open=(n,c)=>{const d=n.selectedNodes[0];d.isInternal&&c&&d.open()},close=(n,c)=>{const d=n.selectedNodes[0];d.isInternal&&c&&d.close()},ClearCanvas=({children:n})=>{const{t:c}=reactI18next.useTranslation(),{setNewBlocks:d}=useBlocksStoreUndoableActions(),[,x]=useSelectedBlockIds(),[,b]=useSelectedStylingBlocks(),y=React.useCallback(()=>{d([]),x([]),b([])},[d]);return jsxRuntime.jsx("div",{className:"flex items-center",children:jsxRuntime.jsxs(tooltip.AlertDialog,{children:[jsxRuntime.jsx(tooltip.AlertDialogTrigger,{asChild:!0,children:n||jsxRuntime.jsxs(tooltip.Button,{size:"sm",variant:"ghost",className:"flex items-center",children:[jsxRuntime.jsx(reactIcons.EraserIcon,{})," ",c("Clear")]})}),jsxRuntime.jsxs(tooltip.AlertDialogContent,{className:"border-border",children:[jsxRuntime.jsxs(tooltip.AlertDialogHeader,{children:[jsxRuntime.jsx(tooltip.AlertDialogTitle,{className:"text-foreground",children:c("Clear whole canvas?")}),jsxRuntime.jsx(tooltip.AlertDialogDescription,{children:c("Are you sure you want to clear the page?")})]}),jsxRuntime.jsxs(tooltip.AlertDialogFooter,{children:[jsxRuntime.jsx(tooltip.AlertDialogCancel,{className:"text-foreground",children:c("Cancel")}),jsxRuntime.jsx(tooltip.AlertDialogAction,{onClick:y,children:c("Yes")})]})]})]})})};let SAVE_TO_LIB_COMPONENT=null;const registerChaiSaveToLibrary=n=>{SAVE_TO_LIB_COMPONENT=n},useSaveToLibraryComponent=()=>React.useMemo(()=>SAVE_TO_LIB_COMPONENT,[]),saveToLibraryModalAtom=jotai.atom({isOpen:!1,blockId:null}),getBlocks=(n,c)=>{const d=lodashEs.filter(n,{_parent:c});if(d.length===0)return[];const x=[...d];return d.forEach(b=>{x.push(...getBlocks(n,b==null?void 0:b._id))}),x},SaveToLibraryModal=()=>{const[n,c]=jotai.useAtom(saveToLibraryModalAtom),{t:d}=reactI18next.useTranslation(),[x]=useBlocksStore(),b=()=>c({isOpen:!1,blockId:null}),y=useSaveToLibraryComponent(),R=React.useMemo(()=>{if(!n.blockId)return[];const S=lodashEs.find(x,{_id:n.blockId});return S==null||delete S._parent,[S,...getBlocks(x,S==null?void 0:S._id)]},[n.blockId,x]);return jsxRuntime.jsx(tooltip.Dialog,{open:n.isOpen,onOpenChange:S=>!S&&b(),children:jsxRuntime.jsxs(tooltip.DialogContent,{className:"p-4 sm:max-w-[450px]",children:[jsxRuntime.jsx(tooltip.DialogHeader,{className:"pb-2",children:jsxRuntime.jsx(tooltip.DialogTitle,{children:d("Save to Library")})}),y&&!lodashEs.isEmpty(n.blockId)&&jsxRuntime.jsx(y,{blockId:n.blockId,blocks:R,close:b})]})})},SaveToLibrary=()=>{const n=useSelectedBlock(),{t:c}=reactI18next.useTranslation(),[,d]=jotai.useAtom(saveToLibraryModalAtom),x=useSaveToLibraryComponent(),b=()=>{n&&d({isOpen:!0,blockId:n._id})};return x?jsxRuntime.jsxs(tooltip.DropdownMenuItem,{className:"flex items-center gap-x-4 text-xs",onClick:b,children:[jsxRuntime.jsx(reactIcons.CheckIcon,{className:"h-4 w-4"})," ",n!=null&&n._libBlockId?c("Update library block"):c("Save to library")]}):null},UnlinkLibraryBlock=()=>{const{t:n}=reactI18next.useTranslation(),c=useSelectedBlock(),d=useUpdateBlocksProps(),x=()=>{d([c._id],{_libBlockId:null})};return jsxRuntime.jsxs(tooltip.DropdownMenuItem,{onClick:x,className:"flex items-center gap-x-4 text-xs",children:[jsxRuntime.jsx(reactIcons.LinkBreak2Icon,{className:"h-4 w-4"})," ",n("Unlink from library")]})},ExportCode=()=>{const{t:n}=reactI18next.useTranslation(),[c]=useSelectedBlockIds();return useBuilderProp("flags.exportCode",!1)?jsxRuntime.jsxs(tooltip.DropdownMenuItem,{className:"flex items-center gap-x-4 text-xs",onClick:()=>pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_EXPORT_CODE,c),children:[jsxRuntime.jsx(reactIcons.DownloadIcon,{})," ",n("Export")]}):null},CopyPasteBlocks=()=>{const[n]=useBlocksStore(),[c]=useSelectedBlockIds(),{pasteBlocks:d}=usePasteBlocks(),[,x,b]=useCopyBlocks(),{t:y}=reactI18next.useTranslation(),R=useSelectedBlock(),S=useBuilderProp("flags.copyPaste",!0),_=React.useCallback(()=>{const A=c.map(L=>{const T=n.find(O=>O._id===L);return{id:L,data:T}});b(A.map(L=>L.id))?sonner.toast.warning("Partial blocks detected. Clone partial blocks?",{cancel:{label:y("No"),onClick:()=>{x(A.map(L=>L.id)),sonner.toast.dismiss()}},action:{label:y("Yes"),onClick:()=>{x(A.map(L=>L.id),!0),sonner.toast.dismiss()}},position:"top-center"}):x(A.map(L=>L.id))},[c,n,x,b]);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[S&&jsxRuntime.jsxs(tooltip.DropdownMenuItem,{disabled:!canDuplicateBlock(R==null?void 0:R._type),onClick:_,className:"flex items-center gap-x-4 text-xs",children:[jsxRuntime.jsx(reactIcons.CopyIcon,{})," ",y("Copy")]}),S&&jsxRuntime.jsxs(tooltip.DropdownMenuItem,{className:"flex items-center gap-x-4 text-xs",onClick:()=>{d(c)},children:[jsxRuntime.jsx(reactIcons.CardStackIcon,{})," ",y("Paste")]})]})},CutBlocks=()=>{const[n]=useSelectedBlockIds(),[,c]=useCutBlockIds(),{t:d}=reactI18next.useTranslation(),x=useBuilderProp("flags.copyPaste",!0);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:x&&jsxRuntime.jsxs(tooltip.DropdownMenuItem,{className:"flex items-center gap-x-4 text-xs",onClick:()=>c(n),children:[jsxRuntime.jsx(reactIcons.ScissorsIcon,{})," ",d("Cut")]})})},RemoveBlocks=()=>{const[n]=useSelectedBlockIds(),c=useRemoveBlocks(),d=useSelectedBlock(),{t:x}=reactI18next.useTranslation();return jsxRuntime.jsxs(tooltip.DropdownMenuItem,{disabled:!canDeleteBlock(d==null?void 0:d._type),className:"flex items-center gap-x-4 text-xs",onClick:()=>c(n),children:[jsxRuntime.jsx(reactIcons.TrashIcon,{})," ",x("Remove")]})},RenameBlock=({node:n})=>{const{t:c}=reactI18next.useTranslation();return jsxRuntime.jsxs(tooltip.DropdownMenuItem,{onClick:d=>{d.stopPropagation(),n.edit(),n.deselect()},className:"flex items-center gap-x-4 text-xs",children:[jsxRuntime.jsx(reactIcons.Pencil2Icon,{className:"h-4 w-4"})," ",c("Rename")]})},BlockContextMenuContent=({node:n})=>{const{t:c}=reactI18next.useTranslation(),[d]=useSelectedBlockIds(),x=useDuplicateBlocks(),b=useSelectedBlock(),{hasPermission:y}=usePermissions(),{librarySite:R}=useBuilderProp("flags",{librarySite:!1}),S=useIsDragAndDropEnabled(),_=React.useCallback(()=>{x(d)},[d,x]),A=React.useMemo(()=>lodashEs.has(b,"_libBlockId")&&!lodashEs.isEmpty(b._libBlockId),[b==null?void 0:b._libBlockId]);return n==="BODY"?jsxRuntime.jsx(tooltip.DropdownMenuContent,{side:"bottom",className:"border-border text-xs",children:y(PERMISSIONS.ADD_BLOCK)&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs(tooltip.DropdownMenuItem,{disabled:!1,className:"flex items-center gap-x-4 text-xs",onClick:()=>pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK,b),children:[jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-3.5 w-3.5"})," ",c("Add block")]}),jsxRuntime.jsx(ExportCode,{}),jsxRuntime.jsx(tooltip.DropdownMenuItem,{disabled:!1,onClick:L=>L.preventDefault(),className:"flex items-center gap-x-4 text-xs",children:jsxRuntime.jsx(ClearCanvas,{children:jsxRuntime.jsxs("div",{className:"flex items-center gap-x-4 text-xs",children:[jsxRuntime.jsx(reactIcons.EraserIcon,{})," ",c("Clear canvas")]})})})]})}):jsxRuntime.jsxs(tooltip.DropdownMenuContent,{side:"bottom",className:"border-border text-xs",children:[y(PERMISSIONS.ADD_BLOCK)&&jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[!S&&jsxRuntime.jsxs(tooltip.DropdownMenuItem,{disabled:!canAddChildBlock(b==null?void 0:b._type),className:"flex items-center gap-x-4 text-xs",onClick:()=>pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK,b),children:[jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-3.5 w-3.5"})," ",c("Add block")]}),jsxRuntime.jsxs(tooltip.DropdownMenuItem,{disabled:!canDuplicateBlock(b==null?void 0:b._type),className:"flex items-center gap-x-4 text-xs",onClick:_,children:[jsxRuntime.jsx(reactIcons.CardStackPlusIcon,{})," ",c("Duplicate")]})]}),jsxRuntime.jsx(RenameBlock,{node:n}),y(PERMISSIONS.MOVE_BLOCK)&&jsxRuntime.jsx(CutBlocks,{}),y(PERMISSIONS.ADD_BLOCK)&&jsxRuntime.jsx(CopyPasteBlocks,{}),A&&R&&jsxRuntime.jsx(UnlinkLibraryBlock,{}),y(PERMISSIONS.CREATE_LIBRARY_BLOCK)&&R&&jsxRuntime.jsx(SaveToLibrary,{}),jsxRuntime.jsx(ExportCode,{}),y(PERMISSIONS.DELETE_BLOCK)&&jsxRuntime.jsx(RemoveBlocks,{})]})},BlockMoreOptions=({children:n,id:c,node:d})=>{const[,x]=useSelectedBlockIds();return jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsxs(tooltip.DropdownMenu,{onOpenChange:b=>{b&&x([c])},children:[jsxRuntime.jsx(tooltip.DropdownMenuTrigger,{children:n}),jsxRuntime.jsx(BlockContextMenuContent,{node:d})]})})},PERMISSIONS={ADD_BLOCK:"add_block",DELETE_BLOCK:"delete_block",EDIT_BLOCK:"edit_block",MOVE_BLOCK:"move_block",EDIT_THEME:"edit_theme",SAVE_PAGE:"save_page",EDIT_STYLES:"edit_styles",IMPORT_HTML:"import_html",CREATE_LIBRARY_BLOCK:"create_library_block",CREATE_LIBRARY_GROUP:"create_library_group",EDIT_LIBRARY_BLOCK:"edit_library_block",DELETE_LIBRARY_BLOCK:"delete_library_block"};Object.values(PERMISSIONS);const Input=({node:n})=>{var c,d;return jsxRuntime.jsx("input",{autoFocus:!0,className:cn("ml-2 !h-4 w-full rounded-sm border border-border bg-background px-1 text-[11px] leading-tight outline-none",n.isSelected?"text-black dark:text-white":""),type:"text",defaultValue:((c=n.data)==null?void 0:c._name)||((d=n.data)==null?void 0:d._type),onFocus:x=>x.currentTarget.select(),onBlur:x=>n.submit(x.currentTarget.value),onKeyDown:x=>{x.key==="Enter"&&n.submit(x.currentTarget.value)}})},currentAddSelection=jotai.atom(null),getBlockDisplayName=n=>{var c;return n!=null&&n._name?n._name:(n==null?void 0:n._type)==="Box"&&(n!=null&&n.tag)&&(n==null?void 0:n.tag)!=="div"?lodashEs.startCase(n.tag):((c=n==null?void 0:n._type)==null?void 0:c.split("/").pop())||""},truncateText=(n,c)=>n.length>c?n.substring(0,c)+"...":n,Node$1=React.memo(({node:n,style:c,dragHandle:d})=>{var Ae;const{t:x}=reactI18next.useTranslation(),b=useUpdateBlocksProps(),[y]=jotai.useAtom(canvasIframeAtom),{hasPermission:R}=usePermissions();let S=null;const _=n.children.length>0,{highlightBlock:A,clearHighlight:L}=useBlockHighlight(),T=useIsDragAndDropEnabled(),{id:O,data:U,isSelected:M,willReceiveDrop:D,isDragging:K,isEditing:$,handleClick:ee}=n,ae=lodashEs.get(U,"_show",!0),Re=He=>{He.stopPropagation(),ae&&n.toggle()},ye=He=>{He.isInternal&&(S=He.isOpen,He.isOpen&&He.close())},de=He=>{He.isInternal&&S!==null&&(S?He.open():He.close(),S=null)},[q,he]=jotai.useAtom(currentAddSelection),le=()=>{var He;xe(),n.parent.isSelected||he((He=n==null?void 0:n.parent)==null?void 0:He.id)},xe=()=>{he(null)},Ee=He=>{xe(),He.stopPropagation(),!n.isOpen&&ae&&n.toggle(),ee(He)};React.useEffect(()=>{const He=setTimeout(()=>{D&&!n.isOpen&&!K&&ae&&n.toggle()},500);return()=>clearTimeout(He)},[D,n,K]);const je=(He,kn)=>{const Ie=y.contentDocument||y.contentWindow.document,ie=Ie.querySelector(`[data-block-id=${He}]`);ie&&ie.setAttribute("data-drop",kn);const ot=ie.getBoundingClientRect(),wn=y.getBoundingClientRect();ot.top>=wn.top&&ot.left>=wn.left&&ot.bottom<=wn.bottom&&ot.right<=wn.right||(Ie.documentElement.scrollTop=ie.offsetTop-wn.top)},ze=He=>{xe();const kn=lodashEs.get(n,"parent.id");kn!=="__REACT_ARBORIST_INTERNAL_ROOT__"?pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK,{_id:kn,position:He}):pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK,{position:He})};if(O===applyBinding.ROOT_TEMP_KEY)return jsxRuntime.jsxs("div",{className:"group relative mt-2 w-full cursor-pointer",children:[jsxRuntime.jsx("br",{}),R(PERMISSIONS.ADD_BLOCK)&&jsxRuntime.jsx("div",{role:"button",onClick:()=>ze(-1),className:"h-1 rounded bg-primary opacity-0 duration-200 group-hover:opacity-100",children:jsxRuntime.jsxs("div",{className:"absolute left-1/2 top-1/2 flex -translate-x-1/2 -translate-y-1/2 transform items-center gap-x-1 rounded-full bg-primary px-3 py-1 text-[9px] leading-tight text-white hover:bg-primary",children:[jsxRuntime.jsx(reactIcons.PlusIcon,{className:"w-2.4 h-2.5 stroke-[5] text-white"})," ",x("Add block")]})}),jsxRuntime.jsx("br",{})]});const{librarySite:We}=useBuilderProp("flags",{librarySite:!1}),Pe=React.useMemo(()=>We&&lodashEs.has(U,"_libBlockId")&&!lodashEs.isEmpty(U._libBlockId)&&(R(PERMISSIONS.CREATE_LIBRARY_BLOCK)||R(PERMISSIONS.EDIT_LIBRARY_BLOCK)),[U,R,We]),ue=React.useMemo(()=>(U==null?void 0:U._type)==="PartialBlock"||(U==null?void 0:U._type)==="GlobalBlock",[U]);return jsxRuntime.jsx("div",{className:"w-full",children:jsxRuntime.jsxs("div",{onMouseEnter:()=>A(O),onMouseLeave:()=>L(),onClick:Ee,style:c,"data-node-id":O,ref:d,onDragStart:()=>ye(n),onDragEnd:()=>de(n),onDragOver:He=>{He.preventDefault(),je(O,"yes")},onDragLeave:He=>{He.preventDefault(),je(O,"no")},onDrop:He=>{He.preventDefault(),je(O,"no")},children:[R(PERMISSIONS.ADD_BLOCK)&&!T&&(n==null?void 0:n.rowIndex)>0&&(n.parent.isOpen&&canAddChildBlock(lodashEs.get(n,"parent.data._type"))||((Ae=n==null?void 0:n.parent)==null?void 0:Ae.id)==="__REACT_ARBORIST_INTERNAL_ROOT__")&&jsxRuntime.jsx("div",{className:"group relative ml-5 h-full w-full cursor-pointer",children:jsxRuntime.jsx("div",{onClick:He=>{He.stopPropagation(),ze(n.childIndex)},onMouseEnter:le,onMouseLeave:xe,className:"absolute -top-0.5 h-0.5 w-[90%] rounded bg-primary/80 opacity-0 delay-200 duration-200 group-hover:opacity-100",children:jsxRuntime.jsx("div",{className:"absolute left-1/2 top-1/2 flex h-4 w-4 -translate-x-1/2 -translate-y-1/2 transform items-center justify-center rounded-full bg-primary/80 p-1 outline outline-2 outline-white hover:bg-primary/80",children:jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-2 w-2 stroke-[2] text-white"})})})}),jsxRuntime.jsxs("div",{className:cn("group flex w-full cursor-pointer items-center justify-between space-x-px !rounded p-1 py-0 outline-none",M?"bg-primary/20":"hover:bg-primary/10",D&&canAcceptChildBlock(U._type,"Icon")?"bg-green-200":"",(n==null?void 0:n.id)===q?"bg-primary/10":"",K&&"opacity-20",ae?"":"line-through opacity-50",Pe&&M&&"bg-primary/20 text-primary"),children:[jsxRuntime.jsxs("div",{className:"flex items-center",children:[jsxRuntime.jsx("div",{className:`flex h-4 w-4 rotate-0 transform cursor-pointer items-center justify-center transition-transform duration-100 ${n.isOpen?"rotate-90":""}`,children:_&&jsxRuntime.jsx("button",{onClick:Re,type:"button",children:jsxRuntime.jsx(reactIcons.ChevronRightIcon,{className:"h-3 w-3"})})}),jsxRuntime.jsxs("div",{className:cn("leading-1 flex items-center",Pe&&"text-orange-600/90",Pe&&M&&"text-orange-800",ue&&"text-purple-600/90",ue&&M&&"text-purple-800"),children:[jsxRuntime.jsx(TypeIcon,{type:U==null?void 0:U._type}),$?jsxRuntime.jsx(Input,{node:n}):jsxRuntime.jsx("div",{className:"ml-1.5 flex items-center gap-x-1 truncate text-[13px]",onDoubleClick:He=>{He.stopPropagation(),n.edit(),n.deselect()},children:jsxRuntime.jsx("span",{title:getBlockDisplayName(U).length>17?getBlockDisplayName(U):"",children:truncateText(getBlockDisplayName(U),17)})})]})]}),jsxRuntime.jsxs("div",{className:"invisible flex items-center space-x-1.5 pr-px group-hover:visible",children:[canAddChildBlock(U==null?void 0:U._type)&&ae&&R(PERMISSIONS.ADD_BLOCK)?jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{onClick:()=>pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK,{_id:O}),className:"cursor-pointer rounded bg-transparent p-px hover:bg-primary/10",asChild:!0,children:jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-4 w-4"})}),jsxRuntime.jsx(tooltip.TooltipContent,{className:"isolate z-[9999]",side:"bottom",children:x("Add block inside")})]}):null,jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{onClick:He=>{He.stopPropagation(),b([O],{_show:!ae}),n.isOpen&&n.toggle()},className:"cursor-pointer rounded bg-transparent p-0.5 hover:bg-primary/10",asChild:!0,children:ae?jsxRuntime.jsx(reactIcons.EyeClosedIcon,{className:"h-4 w-4"}):jsxRuntime.jsx(reactIcons.EyeOpenIcon,{className:"h-4 w-4"})}),jsxRuntime.jsx(tooltip.TooltipContent,{className:"isolate z-[9999] text-xs",side:"bottom",children:x(ae?"Hide the block from page":"Show the block on page")})]}),jsxRuntime.jsx(BlockMoreOptions,{node:n,id:O,children:jsxRuntime.jsx("div",{className:"cursor-pointer rounded bg-transparent p-px hover:bg-primary/10",children:jsxRuntime.jsx(reactIcons.DotsVerticalIcon,{className:"h-3 w-3"})})})]})]})]})})}),PasteAtRootContextMenu=({parentContext:n,setParentContext:c})=>{const{t:d}=reactI18next.useTranslation(),{canPaste:x,pasteBlocks:b}=usePasteBlocks(),y=useBuilderProp("flags.copyPaste",!0);return React.useEffect(()=>{x("root")||c(null)},[x("root")]),!n||!x("root")||!y?null:jsxRuntime.jsx("div",{className:"absolute inset-0",children:jsxRuntime.jsxs(tooltip.DropdownMenu,{open:!0,onOpenChange:()=>c(null),children:[jsxRuntime.jsx(tooltip.DropdownMenuTrigger,{className:"hidden"}),jsxRuntime.jsx(tooltip.DropdownMenuContent,{className:"absolute w-28 p-1 text-xs",style:{top:n.y,left:n.x},children:jsxRuntime.jsxs(tooltip.DropdownMenuItem,{className:"flex items-center gap-x-4 text-xs",onClick:()=>{b("root"),c(null)},children:[jsxRuntime.jsx(reactIcons.CardStackIcon,{})," ",d("Paste")]})})]})})},useCanMove=()=>{const[n]=useBlocksStore();return(c,d)=>{var y;const x=(y=lodashEs.find(n,{_id:d}))==null?void 0:y._type,b=lodashEs.first(c.map(R=>{var S;return(S=lodashEs.find(n,{_id:R}))==null?void 0:S._type}));return canAcceptChildBlock(x,b)}},ListTree=()=>{const[treeData]=jotai.useAtom(treeDSBlocks),[ids,setIds]=useSelectedBlockIds(),[cutBlocksIds]=useCutBlockIds(),updateBlockProps=useUpdateBlocksProps(),[,setStyleBlocks]=useSelectedStylingBlocks(),{moveBlocks}=useBlocksStoreUndoableActions(),canMove=useCanMove(),treeRef=React.useRef(null),[,setTreeRef]=jotai.useAtom(treeRefAtom),{t}=reactI18next.useTranslation(),[parentContext,setParentContext]=React.useState(null),clearSelection=()=>{setIds([]),setStyleBlocks([])},filteredTreeData=React.useMemo(()=>{const n=(d,x)=>d.filter(b=>!x.includes(b._id)).map(b=>({...b,children:b.children?n(b.children,x):[]}));return[...n(treeData,cutBlocksIds),{_type:applyBinding.ROOT_TEMP_KEY,_id:applyBinding.ROOT_TEMP_KEY,children:[]}]},[treeData,cutBlocksIds]),onRename=({id:n,name:c,node:d})=>{updateBlockProps([n],{_name:c},d.data._name)},onMove=({dragIds:n,parentId:c,index:d})=>{canMove(n,c)&&moveBlocks(n,c,d)},onSelect=n=>{if(n.length===0)return;const c=n[0]?n[0].id:"";setStyleBlocks([]),setIds([c])},onContextMenu=n=>{var x;n.preventDefault(),parentContext&&setParentContext(null);const c=n.target,d=c.getAttribute("data-node-id")||((x=c.closest("[data-node-id]"))==null?void 0:x.getAttribute("data-node-id"));d?(setStyleBlocks([]),setIds([d])):(setStyleBlocks([]),setIds([]),setParentContext({x:n.clientX,y:n.clientY}))},debouncedDisableDrop=web.useDebouncedCallback(({parentNode:n,dragNodes:c})=>{var d;return(n==null?void 0:n.data._type)===applyBinding.ROOT_TEMP_KEY||!canAcceptChildBlock(n==null?void 0:n.data._type,(d=c[0])==null?void 0:d.data._type)},[],300),handleKeyDown=e=>{if(!treeRef.current)return;const tree=treeRef.current,selectedNode=tree.selectedNodes[0];if(!selectedNode)return;setIds[selectedNode.id],setStyleBlocks([]);const isLeaf=!selectedNode.isInternal,isClosed=!selectedNode.isOpen,isOpen=selectedNode.isOpen,shortcut=defaultShortcuts.find(s=>s.key===e.key&&(!s.when||eval(s.when)));if(shortcut)switch(e.preventDefault(),shortcut.command){case"selectNext":selectNext(tree);break;case"selectPrev":selectPrev(tree);break;case"selectParent":selectParent(tree,isLeaf||isClosed);break;case"close":close(tree,isOpen);break;case"open":open(tree,isClosed);break;case"selectFirst":selectFirst(tree);break;case"selectLast":selectLast(tree);break}};React.useEffect(()=>{const n=()=>{treeRef.current&&setTreeRef(treeRef.current)};n();const c=new MutationObserver(n);return c.observe(document.body,{childList:!0,subtree:!0}),()=>c.disconnect()},[setTreeRef]);const{hasPermission}=usePermissions();return lodashEs.isEmpty(treeData)?jsxRuntime.jsx("div",{children:jsxRuntime.jsx("div",{className:"mt-10 flex h-full w-full items-center justify-center p-8",children:jsxRuntime.jsxs("div",{className:"flex flex-col items-center space-y-6 text-center",children:[jsxRuntime.jsx("div",{className:"rounded-full bg-muted p-6",children:jsxRuntime.jsx(reactIcons.StackIcon,{className:"h-12 w-12 text-muted-foreground"})}),jsxRuntime.jsxs("div",{className:"space-y-2",children:[jsxRuntime.jsx("h3",{className:"text-lg font-semibold text-foreground",children:t("This page is empty")}),jsxRuntime.jsx("p",{className:"max-w-sm text-sm text-muted-foreground",children:t("Get started by adding your first block to begin building your page")})]}),hasPermission(PERMISSIONS.ADD_BLOCK)&&jsxRuntime.jsxs(tooltip.Button,{onClick:()=>pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK),className:"bg-primary shadow-sm hover:bg-primary/90",size:"sm",children:[jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-4 w-4"}),t("Add Block")]})]})})}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx("div",{className:commonFunctions.cn("flex h-full select-none flex-col space-y-1"),onClick:()=>clearSelection(),children:jsxRuntime.jsxs("div",{id:"outline-view ",className:"no-scrollbar h-full overflow-y-auto text-sm",onKeyDown:n=>{treeRef.current.isEditing||handleKeyDown(n)},children:[jsxRuntime.jsxs("div",{className:"mb-2 flex items-center justify-end gap-x-1 pb-2 text-sm text-muted-foreground",children:[jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx(tooltip.Button,{className:"h-fit p-1",onClick:()=>{var n;return(n=treeRef==null?void 0:treeRef.current)==null?void 0:n.openAll()},variant:"ghost",size:"sm",children:jsxRuntime.jsx(reactIcons.DoubleArrowDownIcon,{className:"h-2 w-2"})})}),jsxRuntime.jsx(tooltip.TooltipContent,{className:"isolate z-[9999]",children:t("Expand all")})]}),jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:jsxRuntime.jsx(tooltip.Button,{className:"h-fit p-1",onClick:()=>{var n;return(n=treeRef==null?void 0:treeRef.current)==null?void 0:n.closeAll()},variant:"ghost",size:"sm",children:jsxRuntime.jsx(reactIcons.DoubleArrowUpIcon,{className:"h-2 w-2"})})}),jsxRuntime.jsx(tooltip.TooltipContent,{className:"isolate z-[9999]",children:t("Collapse all")})]})]}),jsxRuntime.jsx("div",{className:"group relative z-30 ml-5 w-full cursor-pointer",children:jsxRuntime.jsx("div",{onClick:()=>pubsub.publish(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK,{position:0}),className:"h-1 w-[90%] rounded bg-primary opacity-0 duration-200 group-hover:opacity-100",children:jsxRuntime.jsx("div",{className:"absolute left-[45%] top-1/2 flex h-4 w-4 -translate-x-1/2 -translate-y-1/2 transform items-center justify-center rounded-full bg-primary p-1 outline outline-2 outline-white hover:bg-primary",children:jsxRuntime.jsx(reactIcons.PlusIcon,{className:"h-3 w-3 stroke-[3] text-white"})})})}),jsxRuntime.jsx("div",{children:jsxRuntime.jsx("div",{role:"treeitem","aria-level":0,"aria-selected":!0,"aria-expanded":!1,onClick:()=>setIds([]),className:"flex h-full items-center border-b border-transparent",children:jsxRuntime.jsxs("div",{className:commonFunctions.cn("group flex w-full cursor-pointer items-center justify-between space-x-px !rounded p-1 py-0 outline-none",ids.length===0?"bg-primary/20":""),children:[jsxRuntime.jsxs("div",{className:"leading-1 flex items-center",children:[jsxRuntime.jsx(reactIcons.CardStackIcon,{className:"h-3 w-3 flex-shrink-0 rotate-180"}),jsxRuntime.jsx("div",{className:"ml-1.5 flex items-center gap-x-1 truncate text-[13px]",children:"Body"})]}),jsxRuntime.jsx(BlockMoreOptions,{node:"BODY",id:"BODY",children:jsxRuntime.jsx("div",{className:"hidden cursor-pointer rounded bg-transparent p-px hover:bg-primary/10 group-hover:block",children:jsxRuntime.jsx(reactIcons.DotsVerticalIcon,{className:"h-3 w-3"})})})]})})}),jsxRuntime.jsx(reactArborist.Tree,{ref:treeRef,height:window.innerHeight-160,className:"no-scrollbar !h-full max-w-full space-y-1 !overflow-y-auto !overflow-x-hidden",rowClassName:"flex items-center h-full border-b border-transparent",selection:ids[0]||"",onRename,openByDefault:!1,onMove,data:[...filteredTreeData],renderCursor:DefaultCursor,onSelect,childrenAccessor:n=>n.children,width:"100%",rowHeight:25,renderDragPreview:DefaultDragPreview,indent:10,onContextMenu,disableDrop:debouncedDisableDrop,idAccessor:"_id",children:Node$1})]})}),jsxRuntime.jsx(SaveToLibraryModal,{}),jsxRuntime.jsx(PasteAtRootContextMenu,{parentContext,setParentContext})]})},BorderRadiusInput=({value:n,onChange:c,disabled:d})=>{const[x,b]=React.useState(n),y=web.useThrottledCallback(c,[n],200,!0);return jsxRuntime.jsx(tooltip.Slider,{min:0,step:1,max:50,disabled:d,value:[Number(x.replace("px",""))],onValueChange:R=>{b(R[0].toString()+"px"),y(R[0].toString())},className:"flex-1 cursor-pointer"})},ColorPickerInput=({value:n,onChange:c})=>{const d=lodashEs.debounce(x=>c(x),200);return jsxRuntime.jsx("div",{className:"relative flex h-6 w-6 cursor-pointer rounded-lg border border-border",style:{backgroundColor:n},children:jsxRuntime.jsx("input",{type:"color",value:n.startsWith("#")?n:"#000000",onChange:x=>{const b=x.target.value;/^#[0-9A-F]{6}$/i.test(b)&&d(b)},className:"absolute inset-0 h-full w-full cursor-pointer rounded-lg border-0 opacity-0"})})},FontSelector=({label:n,value:c,onChange:d})=>{const x=runtime.useRegisteredFonts();return React.useEffect(()=>{x.some(b=>b.family===c)||d(x[0].family)},[c,d]),jsxRuntime.jsxs("div",{className:"space-y-0.5",children:[jsxRuntime.jsx(tooltip.Label,{className:"mb-1 block text-xs text-gray-600",children:lodashEs.startCase(n)}),jsxRuntime.jsxs(tooltip.Select,{value:c,onValueChange:d,children:[jsxRuntime.jsx(tooltip.SelectTrigger,{className:"h-8 w-full text-xs text-black",children:jsxRuntime.jsx(tooltip.SelectValue,{placeholder:"Select font"})}),jsxRuntime.jsx(tooltip.SelectContent,{children:x.map(b=>jsxRuntime.jsx(tooltip.SelectItem,{value:b.family,children:b.family},b.family))})]})]})},defaultShadcnPreset={fontFamily:{heading:"Poppins",body:"Poppins"},borderRadius:"6px",colors:{background:["#ffffff","#0a0a0a"],foreground:["#0a0a0a","#fafafa"],primary:["#171717","#e5e5e5"],"primary-foreground":["#fafafa","#171717"],secondary:["#f5f5f5","#262626"],"secondary-foreground":["#171717","#fafafa"],muted:["#f5f5f5","#262626"],"muted-foreground":["#737373","#a1a1a1"],accent:["#f5f5f5","#404040"],"accent-foreground":["#171717","#fafafa"],destructive:["#e7000b","#ff6467"],"destructive-foreground":["#ffffff","#fafafa"],border:["#e5e5e5","#282828"],input:["#e5e5e5","#343434"],ring:["#a1a1a1","#737373"],card:["#ffffff","#171717"],"card-foreground":["#0a0a0a","#fafafa"],popover:["#ffffff","#262626"],"popover-foreground":["#0a0a0a","#fafafa"]}},twitter={fontFamily:{heading:"Poppins",body:"Poppins"},borderRadius:"4px",colors:{background:["#ffffff","#000000"],foreground:["#0f1419","#e7e9ea"],primary:["#1e9df1","#1c9cf0"],"primary-foreground":["#ffffff","#ffffff"],secondary:["#0f1419","#f0f3f4"],"secondary-foreground":["#ffffff","#0f1419"],muted:["#e5e5e6","#181818"],"muted-foreground":["#0f1419","#72767a"],accent:["#e3ecf6","#061622"],"accent-foreground":["#1e9df1","#1c9cf0"],destructive:["#f4212e","#f4212e"],"destructive-foreground":["#ffffff","#ffffff"],border:["#e1eaef","#242628"],input:["#f7f9fa","#22303c"],ring:["#1da1f2","#1da1f2"],card:["#f7f8f8","#17181c"],"card-foreground":["#0f1419","#d9d9d9"],popover:["#ffffff","#000000"],"popover-foreground":["#0f1419","#e7e9ea"],sidebar:["#f7f8f8","#17181c"],"sidebar-foreground":["#0f1419","#d9d9d9"],"sidebar-primary":["#1e9df1","#1da1f2"],"sidebar-primary-foreground":["#ffffff","#ffffff"],"sidebar-accent":["#e3ecf6","#061622"],"sidebar-accent-foreground":["#1e9df1","#1c9cf0"],"sidebar-border":["#e1e8ed","#38444d"],"sidebar-ring":["#1da1f2","#1da1f2"]}},solarized={fontFamily:{heading:"Geist",body:"Geist"},borderRadius:"4px",colors:{background:["#fdf6e3","#002b36"],foreground:["#073642","#93a1a1"],primary:["#d33682","#d33682"],"primary-foreground":["#ffffff","#ffffff"],secondary:["#2aa198","#2aa198"],"secondary-foreground":["#ffffff","#ffffff"],muted:["#93a1a1","#586e75"],"muted-foreground":["#073642","#93a1a1"],accent:["#cb4b16","#cb4b16"],"accent-foreground":["#ffffff","#ffffff"],destructive:["#dc322f","#dc322f"],"destructive-foreground":["#ffffff","#ffffff"],border:["#839496","#586e75"],input:["#839496","#586e75"],ring:["#d33682","#d33682"],card:["#eee8d5","#073642"],"card-foreground":["#073642","#93a1a1"],popover:["#eee8d5","#073642"],"popover-foreground":["#073642","#93a1a1"]}},claude={fontFamily:{heading:"Poppins",body:"Poppins"},borderRadius:"6px",colors:{background:["#faf9f5","#262624"],foreground:["#3d3929","#c3c0b6"],primary:["#c96442","#d97757"],"primary-foreground":["#ffffff","#ffffff"],secondary:["#e9e6dc","#faf9f5"],"secondary-foreground":["#535146","#30302e"],muted:["#ede9de","#1b1b19"],"muted-foreground":["#83827d","#b7b5a9"],accent:["#e9e6dc","#1a1915"],"accent-foreground":["#28261b","#f5f4ee"],destructive:["#141413","#ef4444"],"destructive-foreground":["#ffffff","#ffffff"],border:["#dad9d4","#3e3e38"],input:["#b4b2a7","#52514a"],ring:["#c96442","#d97757"],card:["#faf9f5","#262624"],"card-foreground":["#141413","#faf9f5"],popover:["#ffffff","#30302e"],"popover-foreground":["#28261b","#e5e5e2"]}},supabase={fontFamily:{heading:"Inter",body:"Inter"},borderRadius:"6px",colors:{background:["#fff9f5","#2a2024"],foreground:["#3d3436","#f2e9e4"],primary:["#ff7e5f","#ff7e5f"],"primary-foreground":["#ffffff","#ffffff"],secondary:["#ffedea","#463a41"],"secondary-foreground":["#b35340","#f2e9e4"],muted:["#fff0eb","#392f35"],"muted-foreground":["#78716c","#d7c6bc"],accent:["#feb47b","#feb47b"],"accent-foreground":["#3d3436","#2a2024"],destructive:["#e63946","#e63946"],"destructive-foreground":["#ffffff","#ffffff"],border:["#ffe0d6","#463a41"],input:["#ffe0d6","#463a41"],ring:["#ff7e5f","#ff7e5f"],card:["#ffffff","#392f35"],"card-foreground":["#3d3436","#f2e9e4"],popover:["#ffffff","#392f35"],"popover-foreground":["#3d3436","#f2e9e4"]}},LazyCssImportModal=React.lazy(()=>Promise.resolve().then(()=>require("./css-import-modal-CrlmcFy4.cjs")).then(n=>({default:n.CssImportModal}))),PREV_THEME_KEY="chai-builder-previous-theme",DEFAULT_THEME_PRESET=[{shadcn_default:defaultShadcnPreset},{twitter_theme:twitter},{solarized_theme:solarized},{claude_theme:claude},{supabase_theme:supabase}],setPreviousTheme=n=>{if(!(typeof window>"u"))try{localStorage.setItem(PREV_THEME_KEY,JSON.stringify(n))}catch(c){console.warn("Failed to save previous theme to localStorage:",c)}},clearPreviousTheme=()=>{if(!(typeof window>"u"))try{localStorage.removeItem(PREV_THEME_KEY)}catch(n){console.warn("Failed to clear previous theme from localStorage:",n)}},ThemeConfigPanel=React__namespace.memo(({className:n=""})=>{const[c,d]=useDarkMode(),[x,b]=React__namespace.useState(""),[y,R]=React__namespace.useState(!1),S=useBuilderProp("themePresets",[]),_=useBuilderProp("themePanelComponent",null),{hasPermission:A}=usePermissions(),L=useBuilderProp("flags.importTheme",!0),T=useBuilderProp("flags.darkMode",!0);if(S){const q=S.map(he=>Object.keys(he)[0]);DEFAULT_THEME_PRESET.forEach(he=>{const le=Object.keys(he)[0];q.includes(le)||S.push(he)})}const[O,U]=useTheme(),M=useThemeOptions(),{t:D}=reactI18next.useTranslation(),K=React__namespace.useCallback(q=>{const he={...O};setPreviousTheme(he),U(q),sonner.toast.success("Theme updated",{action:{label:jsxRuntime.jsxs("span",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(reactIcons.ResetIcon,{className:"h-4 w-4"})," Undo"]}),onClick:()=>{U(he),clearPreviousTheme(),sonner.toast.dismiss()}},closeButton:!0,duration:15e3})},[O,U]),$=()=>{const q=S.find(he=>Object.keys(he)[0]===x);if(q){const he=Object.values(q)[0];he&&typeof he=="object"&&"fontFamily"in he&&"borderRadius"in he&&"colors"in he?(K(he),b("")):console.error("Invalid preset structure:",he)}else console.error("Preset not found:",x)},ee=q=>{K(q),b("")},ae=web.useDebouncedCallback((q,he)=>{U(()=>({...O,fontFamily:{...O.fontFamily,[q.replace(/font-/g,"")]:he}}))},[O],200),Re=React__namespace.useCallback(q=>{U(()=>({...O,borderRadius:`${q}px`}))},[O]),ye=web.useDebouncedCallback((q,he)=>{U(()=>{const le=lodashEs.get(O,`colors.${q}`);return c?lodashEs.set(le,1,he):lodashEs.set(le,0,he),{...O,colors:{...O.colors,[q]:le}}})},[O],200),de=q=>jsxRuntime.jsx("div",{className:"grid grid-cols-1",children:Object.entries(q.items).map(([he])=>{const le=lodashEs.get(O,`colors.${he}.${c?1:0}`);return le?jsxRuntime.jsxs("div",{className:"mt-1 flex items-center gap-x-2",children:[jsxRuntime.jsx(ColorPickerInput,{value:le,onChange:xe=>ye(he,xe)}),jsxRuntime.jsx(tooltip.Label,{className:"text-xs font-normal leading-tight",children:he.split(/(?=[A-Z])/).join(" ").replace(/-/g," ").split(" ").map(xe=>xe.charAt(0).toUpperCase()+xe.slice(1)).join(" ")+(!he.toLowerCase().includes("foreground")&&!he.toLowerCase().includes("border")&&!he.toLowerCase().includes("input")&&!he.toLowerCase().includes("ring")&&!he.toLowerCase().includes("background")?" Background":"")})]},he):null})});return A("edit_theme")?jsxRuntime.jsxs("div",{className:"relative w-full",children:[jsxRuntime.jsxs("div",{className:commonFunctions.cn("no-scrollbar h-full w-full overflow-y-auto",n),children:[S.length>0&&jsxRuntime.jsxs("div",{className:"mx-0 my-2 flex flex-col gap-1 py-2",children:[jsxRuntime.jsxs("div",{className:"flex w-full items-center justify-between",children:[jsxRuntime.jsx(tooltip.Label,{className:"text-sm",children:D("Presets")}),jsxRuntime.jsx("div",{className:"flex gap-2",children:L&&jsxRuntime.jsxs(tooltip.Button,{className:"px-1",variant:"link",size:"sm",onClick:()=>R(!0),children:[jsxRuntime.jsx(reactIcons.UploadIcon,{className:"h-4 w-4"}),D("Import theme")]})})]}),jsxRuntime.jsxs("div",{className:"flex items-center gap-2 px-0",children:[jsxRuntime.jsx("div",{className:"w-[70%]",children:jsxRuntime.jsxs(tooltip.Select,{value:x,onValueChange:b,children:[jsxRuntime.jsx(tooltip.SelectTrigger,{className:"h-9 w-full text-sm",children:jsxRuntime.jsx(tooltip.SelectValue,{placeholder:D("Select preset")})}),jsxRuntime.jsx(tooltip.SelectContent,{children:Array.isArray(S)&&S.map(q=>{const he=Object.keys(q)[0],le=he.replaceAll("_"," ");return jsxRuntime.jsx(tooltip.SelectItem,{value:he,children:lodashEs.capitalize(le)},he)})})]})}),jsxRuntime.jsx("div",{className:"w-[25%]",children:jsxRuntime.jsx(tooltip.Button,{className:"w-full text-sm",disabled:!x,onClick:$,children:D("Apply")})})]})]}),jsxRuntime.jsx(tooltip.Separator,{}),jsxRuntime.jsxs("div",{className:commonFunctions.cn("my-2 space-y-3",n),children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(reactIcons.TextIcon,{className:"h-3 w-3 text-gray-600"}),jsxRuntime.jsx("span",{className:"text-xs font-medium text-gray-700",children:D("Typography")})]}),(M==null?void 0:M.fontFamily)&&jsxRuntime.jsx("div",{className:"space-y-2",children:Object.entries(M.fontFamily).map(([q,he])=>jsxRuntime.jsx(FontSelector,{label:q,value:O.fontFamily[q.replace(/font-/g,"")]||he[Object.keys(he)[0]],onChange:le=>ae(q,le)},q))}),jsxRuntime.jsx(tooltip.Separator,{}),(M==null?void 0:M.borderRadius)&&jsxRuntime.jsxs("div",{className:"space-y-0.5",children:[jsxRuntime.jsxs("div",{className:"flex items-center justify-between",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(reactIcons.CornerTopRightIcon,{className:"h-3 w-3 text-gray-600"}),jsxRuntime.jsx("span",{className:"text-xs font-medium text-gray-700",children:D("Border Radius")})]}),jsxRuntime.jsx(tooltip.Badge,{variant:"secondary",className:"text-xs",children:O.borderRadius})]}),jsxRuntime.jsx("div",{className:"flex items-center gap-4 py-2",children:jsxRuntime.jsx(BorderRadiusInput,{value:O.borderRadius,onChange:Re})})]}),jsxRuntime.jsx(tooltip.Separator,{}),(M==null?void 0:M.colors)&&jsxRuntime.jsxs("div",{className:"space-y-3",children:[jsxRuntime.jsxs("div",{className:"flex items-center justify-between",children:[jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(reactIcons.MixerHorizontalIcon,{className:"h-3 w-3 text-gray-600"}),jsxRuntime.jsx("span",{className:"text-xs font-medium text-gray-700",children:D("Colors")})]}),T&&jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(reactIcons.SunIcon,{className:"h-4 w-4"}),jsxRuntime.jsx(tooltip.Switch,{checked:c,onCheckedChange:q=>d(q),"aria-label":"Toggle dark mode",className:"mx-1"}),jsxRuntime.jsx(reactIcons.MoonIcon,{className:"h-4 w-4"})]})]}),jsxRuntime.jsx("div",{className:"space-y-2",children:M.colors.map(q=>de(q))})]}),jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx("div",{children:D("Loading...")}),children:y&&L&&jsxRuntime.jsx(LazyCssImportModal,{open:y,onOpenChange:R,onImport:ee})})]}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{})]}),_&&jsxRuntime.jsx("div",{className:"absolute bottom-4 w-full",children:React__namespace.createElement(_)})]}):jsxRuntime.jsx("div",{className:"relative w-full",children:jsxRuntime.jsx("div",{className:commonFunctions.cn("no-scrollbar h-full w-full overflow-y-auto text-center",n),children:jsxRuntime.jsx("div",{className:"mt-10 h-full items-center justify-center gap-2 text-muted-foreground",children:jsxRuntime.jsx("p",{className:"text-sm",children:D("You don't have permission to edit the theme. Please contact your administrator to get access.")})})})})}),Core="Core",Import="Import",Breakpoints="Breakpoints",Clear="Clear",Cancel="Cancel",Yes="Yes",Preview="Preview",Settings="Settings",Styling="Style",SVG_code="Enter SVG code here",Remove="Remove",Choose="Choose",Cut="Cut",Copy="Copy",Paste="Paste",Delete="Delete",classes="classes",Theme="Theme",Outline="Outline",Copied="Copied",Stop="Stop",Edit="Edit",Tag="Tag",Value="Value",URL$1="URL",Images="Images",Library="Library",Blocks="Blocks",Basic="Basic",Media="Media",Advanced="Advanced",Form="Form",Groups="Groups",Accordions="Accordions",Buttons="Buttons",Layouts="Layouts",FAQ="FAQ",Hero="Hero",Features="Features",Footer="Footer",Navbar="Navbar",Icons="Icons",Testimonials="Testimonials",Blog="Blog",Saved="Saved",Unsaved="Unsaved",Randomize="Randomize",Classes="Classes",All="All",Undo="Undo",Redo="Redo",Duplicate="Duplicate",Close="Close",Selected="Selected",Select="Select",Attributes="Attributes",apply="apply",presets="presets",Orientation="Orientation",Color="Color",Upload="Upload",Apply="Apply",Back="Back",Insert="Insert",Rename="Rename",Partials="Partials",Happy="Happy",Sad="Sad",Retry="Retry",canvas_empty="Canvas is empty",Presets="Presets",No="No",Saving="Saving",theme_config={heading_font:"Heading Font",body_font:"Body Font",rounded_corner:"Rounded Corners",primary:"Primary",secondary:"Secondary",background:"Background",text_color:"Text Color",background_dark_mode:"Background (Dark Mode)",text_color_dark_mode:"Text Color (Dark Mode)"},web_blocks={box:"box",tag:"Tag",div:"div",level:"Level",header:"header",footer:"footer",section:"section",article:"article",aside:"aside",main:"main",nav:"navigation",figure:"figure",details:"details",summary:"summary",dialog:"dialog",strike:"strike",caption:"caption",legend:"legend",figcaption:"figure caption",mark:"mark",background_image:"Background Image",label:"Label",default:"default",icon_size:"Icon Size",icon_position:"Icon Position",start:"Start",end:"End",button:"Button",custom_html:"Custom HTML",html_code:"HTML Code",default_snippet:"The HTML snippet goes here...",placeholder:"Enter custom HTML code here",custom_script:"Custom Script",dark_mode:"Dark Mode",divider:"Divider",empty_box:"Empty Box",heading:"Heading",image:"Image",alt:"Alt",width:"Width",height:"Height",video:"Video",span:"Span",content:"Content",icon:"Icon",richtext:"Rich Text",list:"List",list_type:"List Type",listitem:"List Item",link:"Link",list_item:"List Item",none:"None",disc:"Disc",number:"Number",paragraph:"Paragraph",lightbox_link:"Lightbox Link",href:"Link",type:"Type",iframe:"iframe",inline:"inline",ajax:"ajax",autoplay:"Video autoplay",max_width:"Max Width",backdrop_color:"Background Color",gallery_name:"Gallery Name",slot:"Slot",empty_slot:"Empty Slot",text:"Text",video_url:"Video URL",controls:"Show Controls",loop:"Loop",muted:"Muted",checkbox:"Checkbox",required:"Required",checked:"Checked",submit_button:"Submit Button",form:"Form",submit_url:"Submit URL",error_message:"Error Message",success_message:"Success Message",input:"Input",value:"Value",show_label:"Show Label",field_name:"Field Name",radio:"Radio",multiple:"Multiple",options:"Options",select:"Select",multiple_choice:"Multiple Choice",textarea:"Textarea",rows:"Rows"},lngEn={"Add block":"Add Block","Add Block":"Add Block","Add blocks":"Add blocks","Add inside":"Add inside","Add before":"Add before","Add after":"Add after","Add block inside":"Add block inside","Add field":"Add field","Enter or paste TailwindCSS HTML snippet":"Enter or paste TailwindCSS HTML snippet","Click to add block to page":"Click to add block to page",Core,"Custom Blocks":"Custom Blocks","UI Library":"UI Library",Import,"Use HTML snippets from Tailwind CSS component libraries":"Use HTML snippets from Tailwind CSS component libraries","Tailwind HTML snippet":"Tailwind HTML snippet","Enter your code snippet here":"Enter your code snippet here","Import HTML":"Import HTML","Imported HTML Note":"NOTE: Imported html will be added to the currently selected block. If no block is selected, the html will be added to the page.","Dark Mode":"Dark Mode","This page has no blocks. Add a block by clicking the + button":"This page has no blocks. Add a block by clicking the + button","This page is empty":"This page is empty","Please select a block to edit settings or styles":"Please select a block to edit settings or styles","Please select a block to Ask AI":"Please select a block to ask AI","Please select a styling block":"Please select a styling block","Drop your block here":"Drop your block here","Use setting":"Use setting","Mobile (XS)":"Mobile (XS)","Styles set here are applied to all screen unless edited at higher breakpoint":"Styles set here are applied to all screen unless edited at higher breakpoint","Mobile landscape (SM)":"Mobile landscape (SM)","Styles set here are applied at 640px and up unless edited at higher breakpoint":"Styles set here are applied at 640px and up unless edited at higher breakpoint","Tablet (MD)":"Tablet (MD)","Styles set here are applied at 768px and up":"Styles set here are applied at 768px and up","Tablet Landscape (LG)":"Tablet Landscape (LG)","Styles set here are applied at 1024px and up unless edited at higher breakpoint":"Styles set here are applied at 1024px and up unless edited at higher breakpoint","Desktop (XL)":"Desktop (XL)","Styles set here are applied at 1280px and up unless edited at higher breakpoint":"Styles set here are applied at 1280px and up unless edited at higher breakpoint","Large Desktop (2XL)":"Large Desktop (2XL)","Styles set here are applied at 1536px and up":"Styles set here are applied at 1536px and up",Breakpoints,Clear,"Clear whole canvas?":"Clear whole canvas?","Are you sure you want to clear the whole canvas?":"Are you sure you want to clear the whole canvas?",Cancel,Yes,Preview,Settings,Styling,SVG_code,"Paste SVG_code":"Choose icon or paste SVG code","Enter Key":"Enter Key","Data Provider":"Data Provider","Remove Provider Confirmation":"Are you sure you want to remove <span class='text-blue-500'>{name}</span> provider?","Your data provider will be removed from this page and all added data binding will be not visible on blocks.":"Your data provider will be removed from this page and all added data binding will be not visible on blocks.",Remove,"You have no data providers registered. Please add a data provider to your project.":"You have no data providers registered. Please add a data provider to your project.","Learn more":"Learn more","Add data providers:":"Add data providers:","Select a provider":"Select a provider",Choose,"Page data providers:":"Page data providers:","View Data":"View Data","Mark as Global":"Mark as Global","Note: Global blocks are single instances. Editing global blocks will be reflected on all pages using these blocks.":"Note: Global blocks are single instances. Editing global blocks will be reflected on all pages using these blocks.","Global blocks are indicated with":"Global blocks are indicated with","Global blocks are available under 'Global' category":"Global blocks are available under 'Global' category","Enter global block name":"Enter global block name","Eg: Header, Footer":"Eg: Header, Footer","{length} blocks selected.":"{length} blocks selected.",Cut,Copy,Paste,Delete,"Clear Selection":"Clear Selection","This is dev mode. Visit":"This is dev mode. Visit","to see page preview":"to see page preview",classes,Theme,Outline,"Not supported":"Not supported","Please use Chrome, Firefox or Safari":"Please use Chrome, Firefox or Safari","Download Complete":"Download complete",Copied,"Enter Classes":"Enter classes separated by space","Ask AI":"Ask AI","Edit with AI":"Edit with AI","Generating... Please wait...":"Generating... Please wait...","Saving... Please wait...":"Saving... Please wait...","Deleting... Please wait...":"Deleting... Please wait...",Stop,"E.g.: This page is about an AI assistant app called Chai Studio. It allows users to create beautiful webpages and edit content with AI":"E.g.: This page is about an AI assistant app called Chai Studio. It allows users to create beautiful webpages and edit content with AI.","Ask AI to edit styles":"Ask AI to edit styles","Ask AI to edit content":"Ask AI to edit content","AI Context":"AI Context","Select Block for AI":"Select a block to edit with AI","Select Block to Edit":"Please select a block to edit",Edit,"Describe this page. E.g.: This page is about...":"Describe this page. E.g.: This page is about...",Tag,Value,"Background Image":"Background Image","Enter image URL":"Enter image URL","Enter URL":"Enter URL",URL:URL$1,"Replace image":"Replace image","Choose image":"Choose image",Images,Library,Blocks,Basic,Media,Advanced,Form,"Choose Icon or SVG":"Choose an icon or enter SVG",Groups,"UI Libraries":"UI Libraries",Accordions,Buttons,Layouts,"Choose Library":"Choose library","No Library Found":"No library found.",FAQ,Hero,Features,Footer,Navbar,Icons,Testimonials,Blog,"Remove context":"Remove context","Yes, Delete":"Yes, Delete","AI Context Updated":"AI Context Updated","You can now ask AI to edit your content.":"You can now ask AI to edit your content.",Saved,Unsaved,"Saving...":"Saving...","Improve writing":"Improve writing","Replace placeholder content":"Replace placeholder content","Discard current placeholder content and replace with meaningful relevant content.":"Discard current placeholder content and replace with meaningful relevant content.","Fix grammar":"Fix grammar","Fix grammar in all text elements. Ensuring the text is grammatically correct and free of errors.":"Fix grammar in all text elements. Ensuring the text is grammatically correct and free of errors.","Make longer":"Make longer","Make all text elements longer.":"Make all text elements longer.","Make shorter":"Make shorter","Make all text elements shorter.":"Make all text elements shorter.","Add emojis":"Add emojis","Add emojis to text elements if relevant.":"Add emojis to text elements if relevant.",Randomize,"Randomize all text elements.":"Randomize all text elements.","Edit Block":"Edit Block","AI Assistant":"AI Assistant","Theme Config":{"Heading Font":"Heading Font","Body Font":"Body Font","Rounded Corner":"Rounded Corners",Primary:"Primary",Secondary:"Secondary",Background:"Background","Text Color":"Text Color","Background Dark Mode":"Background (Dark Mode)","Text Color Dark Mode":"Text Color (Dark Mode)","Reset styles":"Reset styles"},"Copy classes to clipboard":"Copy classes to clipboard","Classes copied to clipboard":"Classes copied to clipboard",Classes,All,"Enter classes separated by space":"Enter classes separated by space","Show hidden blocks":"Show hidden blocks","Expand all":"Expand all","Collapse all":"Collapse all","Choose library":"Choose library","Close Preview":"Close Preview",Error:"Error","Failed to copy template":"Failed to copy template","Total tokens used":"Total tokens used","Updated AI Context":"Updated AI Context","You can now Ask AI to edit your content":"You can now Ask AI to edit your content","Tell about this page eg this page is about":"Tell about this page eg this page is about..","Delete Context":"Delete Context","Keyboard shortcuts":"Keyboard shortcuts",Undo,Redo,Duplicate,"Deselect blocks":"Deselect blocks","Delete block":"Delete block","Save page":"Save page","Scripts will be only executed in preview and live mode.":"Scripts will be only executed in preview and live mode.","HTML Code Editor |":"HTML Code Editor |",Close,"Coming soon":"Coming soon",Selected,Select,"Choose Builder Layout":"Choose Builder Layout","Single side panel":"Single side panel","Suitable for smaller screens. Bigger canvas size.":"Suitable for smaller screens. Bigger canvas size.","Dual side panel":"Dual side panel","Suitable for larger screens. Smaller canvas size.":"Suitable for larger screens. Smaller canvas size.","Dual side panel advanced":"Dual side panel advanced","Suitable for heavy styling & block editing. Setting are always visible.":"Suitable for heavy styling & block editing. Setting are always visible.","Block Settings":"Block Settings","Visibility settings":"Visibility settings","Show on canvas":"Show on canvas",Attributes,"Apply Presets":"Apply Presets",apply,presets,"Global presets":"Global presets",Orientation,Color,"Please select an image":"Please select an image","click to upload":"click to upload","SVG, PNG, JPG or GIF (Max. 2mb)":"SVG, PNG, JPG or GIF (Max. 2mb)","Uploading...":"Uploading...",Upload,"Something went wrong":"Something went wrong","Fetching...":"Fetching...","No images found":"No images found","It looks like you haven't uploaded any images yet. Start by clicking the upload button above.":"It looks like you haven't uploaded any images yet. Start by clicking the upload button above.","Open Code Editor":"Open Code Editor","Clear search":"Clear search","No results found for":"No results found for","Search {{pageTypeName}}":"Search {{pageTypeName}}","Goto Page":"Goto Page","Open URL":"Open URL","Compose Email":"Compose Email","Call Phone":"Call Phone","Scroll to element":"Scroll to element","#ElementID":"#ElementID","Enter details":"Enter details","Open in new tab":"Open in new tab",Apply,Back,Insert,Rename,"Unlink from library":"Unlink from library","Save to Library":"Save to Library","No blocks found in this group":"No blocks found in this group","No blocks found matching":"No blocks found matching","No matching blocks found":"No matching blocks found","Search blocks...":"Search blocks...",Partials,Happy,Sad,"Importing...":"Importing...","Failed to load the UI library. Try again":"Failed to load the UI library. Try again",Retry,"Oops! Something went wrong.":"Oops! Something went wrong.","Please try again.":"Please try again.","No option found.":"No option found.","Clipboard not supported":"Clipboard not supported","Are you sure you want to clear the page?":"Are you sure you want to clear the page?",canvas_empty,Presets,"Reset style":"Reset style","Reset styles":"Reset styles","Clear styles":"Clear styles","Open code editor":"Open code editor","Style element":"Style element","Repeater Data":"Repeater Data","Toggle Data Binding":"Toggle Data Binding",No,Saving,"Screen sizes":"Screen sizes","Theme Settings":"Theme Settings","Import CSS Theme":"Import CSS Theme","Import theme":"Import theme","Import Theme":"Import Theme","CSS Variables":"CSS Variables","You don't have permission to edit settings or styles":"You don't have permission to edit settings or styles","Please contact your administrator to get access":"Please contact your administrator to get access","flex.heading":"Flex Child","flex.basis":"Basis","flex.order":"Order","flex.flex":"Flex","flex.grow":"Grow","flex.shrink":"Shrink","grid.heading":"Grid Child","grid.col_span":"Col Span","grid.col_start":"Col Start","grid.col_end":"Col End","grid.row_span":"Row Span","grid.row_start":"Row Start","grid.row_end":"Row End","grid.order":"Order","layout.heading":"Layout","layout.width":"Width","layout.height":"Height","layout.margin":"Margin","layout.margin_all":"All","layout.margin_lr":"Left-Right","layout.margin_tb":"Top-Bottom","layout.margin_top":"Top","layout.margin_right":"Right","layout.margin_bottom":"Bottom","layout.margin_left":"Left","layout.padding":"Padding","layout.padding_all":"All","layout.padding_lr":"Left-Right","layout.padding_tb":"Top-Bottom","layout.padding_top":"Top","layout.padding_right":"Right","layout.padding_bottom":"Bottom","layout.padding_left":"Left","layout.space_bt":"Space Bt.","layout.space_lr":"Left-Right","layout.space_tb":"Top-Bottom","size.heading":"Size","size.min_width_height":"Min width & height","size.min_width":"Min Width","size.min_height":"Min Height","size.max_width_height":"Max width & height","size.max_width":"Max Width","size.max_height":"Max Height","size.object_options_aspect_ratio":"Object options & aspect ratio","size.aspect":"Aspect","size.fit":"Fit","size.position":"Position","display.heading":"Display","display.display":"Display","display.flex_options":"Flex options","display.flex_direction":"Direction","display.flex_wrap":"Wrap","display.justify_content":"Justify","display.align_content":"Content","display.align_items":"Items","display.gap":"Gap","display.gap_all":"All","display.gap_lr":"Left-Right","display.gap_tb":"Top-Bottom","display.grid_options":"Grid options","display.grid_columns":"Columns","display.grid_rows":"Rows","display.grid_auto_flow":"Auto Flow","display.grid_auto_cols":"Auto Cols","display.grid_auto_rows":"Auto Rows","display.visibility_opacity":"Visibility & Opacity","display.visibility":"Visibility","display.opacity":"Opacity","position.heading":"Position","position.position":"Position","position.options":"Position options","position.direction":"Direction","position.top":"Top","position.right":"Right","position.bottom":"Bottom","position.left":"Left","position.inset":"Inset","position.all":"All","position.lr":"Left Right","position.tb":"Top Bottom","position.z_index":"Z-Index","position.float_clear":"Float & Clear","position.float":"Float","position.clear":"Clear","position.overflow_overscroll":"Overflow & Overscroll","position.overflow":"Overflow","position.overscroll":"Overscroll","typography.heading":"Typography","typography.font":"Font","typography.size":"Size","typography.height":"Height","typography.weight":"Weight","typography.color":"Color","typography.alignments":"Alignments","typography.align":"Align","typography.valign":"V. Align","typography.spacing_decoration_more":"Spacing, decoration & more","typography.spacing":"Spacing","typography.decoration":"Decoration","typography.thickness":"Thickness","typography.transform":"Transform","typography.whitespace_breaks":"White space & breaks","typography.whitespace":"Whitespace","typography.wordbreak":"Wordbreak","background.heading":"Background","background.bgcolor":"Bg. Color","background.position_size_more":"Position, Size & more","background.attachment":"Attachment","background.clipping":"Clipping","background.origin":"Origin","background.position":"Position","background.repeat":"Repeat","background.size":"Size","background.gradient":"Gradient","background.gradient_colors":"Gradient colors","background.from_color":"From","background.via_color":"Via","background.to_color":"To","border.heading":"Border & Outline","border.width":"Width","border.all":"All","border.lr":"Left Right","border.tb":"Top bottom","border.top":"Top","border.right":"Right","border.bottom":"Bottom","border.left":"Left","border.corners":"Corners","border.top_left":"Top Left","border.top_right":"Top right","border.bottom_right":"Bottom right","border.bottom_left":"Bottom left","border.color":"Color","border.style":"Style","border.divide_options":"Divide options","border.divide_color":"Color","border.divide_style":"Style","border.outline_styling":"Outline styling","border.outline_width":"Width","border.outline_offset":"Offset","border.outline_style":"Style","border.ring_options":"Ring options","border.ring_width":"Width","border.ring_color":"Color","border.ring_offset_width":"Offset","border.ring_offset_color":"Off. color","effect.heading":"Effect & Animation","effect.shadow":"Shadow","effect.color":"Color","effect.cursor":"Cursor","effect.blend_cursor":"Blend & Cursor","effect.mix_blend":"Mix Blend","effect.bg_blend":"Bg. Blend","effect.transform":"Transform","effect.origin":"Origin","effect.scale":"Scale","effect.all":"All","effect.lr":"Left-Right","effect.tb":"Top-Bottom","effect.skew":"Skew","effect.translate":"Translate","effect.rotate":"Rotate","effect.animation":"Animation","effect.transition":"Transition","effect.easing":"Easing","effect.duration":"Duration","effect.delay":"Delay","classes.heading":"Classes",theme_config,web_blocks,"Export Code":"Export Code","Exporting {{count}} blocks":"Exporting {{count}} blocks","Exporting all blocks":"Exporting all blocks","Export code copied!":"Export code copied!","Failed to copy export code":"Failed to copy export code","Export code downloaded successfully!":"Export code downloaded successfully!","Failed to generate export HTML":"Failed to generate export HTML"};i18n.use(reactI18next.initReactI18next).init({resources:{en:{translation:lngEn}},lng:"en",fallbackLng:"en",interpolation:{escapeValue:!1}});function QuickPrompts({onClick:n}){const{loading:c}=useAskAi(),{t:d}=reactI18next.useTranslation(),{selectedLang:x,fallbackLang:b}=useLanguages(),R=[...[{name:d("Improve writing"),icon:reactIcons.Pencil2Icon,prompt:d("Improving writing in all text elements. Replacing placeholder content with meaningful relevant content.")},{name:d("Replace placeholder content"),icon:reactIcons.LoopIcon,prompt:d("Discard current placeholder content and replace with meaningful relevant content.")},{name:d("Fix grammar"),icon:reactIcons.CheckIcon,prompt:d("Fix grammar in all text elements. Ensuring the text is grammatically correct and free of errors.")},{name:d("Make longer"),icon:reactIcons.ArrowUpIcon,prompt:d("Make all text elements longer.")},{name:d("Make shorter"),icon:reactIcons.ArrowDownIcon,prompt:d("Make all text elements shorter.")},{name:d("Add emojis"),icon:reactIcons.FaceIcon,prompt:d("Add emojis to text elements if relevant.")},{name:d("Randomize"),icon:reactIcons.ShuffleIcon,prompt:d("Randomize all text elements.")}]];return x&&x!==b&&R.splice(0,0,{name:d("Translate to {{lang}}",{lang:lodashEs.get(LANGUAGES,x,x)}),icon:reactIcons.ChatBubbleIcon,prompt:d("Translate the content to {{lang}}. Maintain same tone, style and length.",{lang:lodashEs.get(LANGUAGES,x,x)})}),jsxRuntime.jsx("div",{className:c?"pointer-events-none opacity-50":"",children:jsxRuntime.jsx("ul",{className:"space-y-1",children:R.map(({name:S,icon:_,subMenus:A,prompt:L})=>A?jsxRuntime.jsxs(tooltip.Popover,{children:[jsxRuntime.jsx(tooltip.PopoverTrigger,{asChild:!0,children:jsxRuntime.jsxs("li",{className:"flex cursor-pointer items-center space-x-2 rounded p-1 pl-2 text-sm hover:bg-gray-100 dark:hover:bg-gray-800",children:[jsxRuntime.jsx(_,{className:"h-4 w-4"}),jsxRuntime.jsx("span",{children:S})]},S)}),jsxRuntime.jsx(tooltip.PopoverContent,{side:"right",children:jsxRuntime.jsx("ul",{children:jsxRuntime.jsx("li",{children:d("Happy")})})})]}):jsxRuntime.jsxs("li",{onClick:()=>n(L),className:"flex cursor-pointer items-center space-x-2 rounded p-1 text-xs hover:bg-primary/10 hover:text-primary dark:hover:bg-gray-800",children:[jsxRuntime.jsx(_,{className:"h-3.5 w-3.5"}),jsxRuntime.jsx("span",{children:d(S)})]},S))})})}const AIUserPrompt=({blockId:n})=>{const{t:c}=reactI18next.useTranslation(),{askAi:d,loading:x,error:b}=useAskAi(),[y,R]=React.useState(""),S=React.useRef(null),_=React.useRef(null),A=useSelectedBlock();React.useEffect(()=>{var T;(T=S.current)==null||T.focus()},[]);const L=()=>{b||R("")};return jsxRuntime.jsx("div",{className:"",children:n?jsxRuntime.jsxs("div",{className:"",children:[jsxRuntime.jsx("label",{className:"text-xs font-medium text-gray-500",children:"Selected block"}),A&&jsxRuntime.jsxs("div",{className:"flex items-center gap-x-1 rounded border border-primary/20 bg-primary/10 p-1.5 text-xs text-primary",children:[jsxRuntime.jsx(TypeIcon,{type:A._type})," ",jsxRuntime.jsx("p",{className:"truncate whitespace-nowrap leading-none",children:A._name||A._type})]}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("label",{className:"text-xs font-medium text-gray-500",children:"Quick actions"}),jsxRuntime.jsx("div",{className:"rounded border p-2 text-sm",children:jsxRuntime.jsx(QuickPrompts,{onClick:T=>{_.current&&clearTimeout(_.current),d("content",n,T,L)}})}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("label",{className:"text-xs font-medium text-gray-500",children:"Custom prompt"}),jsxRuntime.jsxs("div",{className:"rounded border p-2 text-xs focus-within:border-gray-300",children:[jsxRuntime.jsx(tooltip.Textarea,{ref:S,value:y,onChange:T=>R(T.target.value),placeholder:c("Ask AI to edit content"),className:"w-full resize-none border-none p-0 text-xs shadow-none outline-none",rows:3,onKeyDown:T=>{T.key==="Enter"&&(T.preventDefault(),_.current&&clearTimeout(_.current),d("content",n,y,L))}}),jsxRuntime.jsxs("div",{className:"flex items-center justify-end",children:[x&&jsxRuntime.jsx(tooltip.Button,{variant:"destructive",onClick:()=>stop(),className:"hidden h-4 w-4",size:"icon",children:jsxRuntime.jsx(reactIcons.StopIcon,{className:"h-4 w-4"})}),jsxRuntime.jsx(tooltip.Button,{onClick:()=>{_.current&&clearTimeout(_.current),d("content",n,y,L)},variant:"default",className:"h-7 w-7",disabled:x||y.trim().length<1,size:"icon",children:x?jsxRuntime.jsx(reactIcons.ReloadIcon,{className:"h-4 w-4 animate-spin"}):jsxRuntime.jsx(reactIcons.ArrowTopRightIcon,{className:"h-4 w-4"})})]})]}),jsxRuntime.jsx("div",{className:"max-w-full pt-2",children:b&&jsxRuntime.jsx("p",{className:"break-words rounded border border-red-500 bg-red-100 p-1 text-xs text-red-500",children:b.message})})]}):jsxRuntime.jsx("div",{className:"p-4 text-center",children:jsxRuntime.jsxs("div",{className:"space-y-4 rounded-xl p-4 text-muted-foreground",children:[jsxRuntime.jsx(AiIcon,{className:"mx-auto h-7 w-7 text-muted-foreground"}),jsxRuntime.jsx("h1",{children:c("Please select a block to Ask AI")})]})})})},AskAI=()=>{const[n]=useSelectedBlockIds();return jsxRuntime.jsx("div",{className:"no-scrollbar mt-2 flex-1 overflow-y-auto",children:jsxRuntime.jsx(AIUserPrompt,{blockId:lodashEs.first(n)})})};function DarkMode(){const[n,c]=useDarkMode();return jsxRuntime.jsxs("div",{className:"flex items-center",children:[n?jsxRuntime.jsx(reactIcons.MoonIcon,{className:"size-4 shrink-0"}):jsxRuntime.jsx(reactIcons.SunIcon,{className:"size-4 shrink-0"}),jsxRuntime.jsx(tooltip.Switch,{id:"dark-mode-switch",checked:n,onCheckedChange:()=>{c(!n)},className:`${n?"bg-violet-600":"bg-violet-300"} relative ml-2 inline-flex h-[20px] w-[32px] shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focus:outline-none focus-visible:ring-2 focus-visible:ring-white focus-visible:ring-opacity-75`,children:jsxRuntime.jsx("span",{"aria-hidden":"true",className:`${n?"translate-x-5":"translate-x-0"} pointer-events-none -mt-px inline-block h-[18px] w-[20px] transform rounded-full bg-white shadow-lg ring-0 transition duration-200 ease-in-out`})})]})}const UndoRedo=()=>{const{hasUndo:n,hasRedo:c,undo:d,redo:x}=useUndoManager();return jsxRuntime.jsxs("div",{className:"flex items-center",children:[jsxRuntime.jsx(tooltip.Button,{disabled:!n(),size:"sm",onClick:d,className:"rounded-full",variant:"ghost",children:jsxRuntime.jsx(reactIcons.ResetIcon,{})}),jsxRuntime.jsx(tooltip.Button,{disabled:!c(),onClick:x,size:"sm",className:"rounded-full",variant:"ghost",children:jsxRuntime.jsx(reactIcons.ResetIcon,{className:"rotate-180 scale-y-[-1] transform"})})]})},CanvasTopBar=()=>{const n=useBuilderProp("flags.darkMode",!0),c=useBuilderProp("flags.dataBinding",!0),[d,x]=jotai.useAtom(dataBindingActiveAtom),{t:b}=reactI18next.useTranslation(),y=n,R=c;return jsxRuntime.jsxs("div",{className:"flex h-10 items-center justify-between border-b border-border bg-background/70 px-2 shadow-xl",children:[jsxRuntime.jsx("div",{className:"flex h-full space-x-2",children:y?jsxRuntime.jsx(DarkMode,{}):null}),jsxRuntime.jsxs("div",{className:"flex h-full items-center space-x-2",children:[jsxRuntime.jsx(Breakpoints$1,{canvas:!0,openDelay:400}),jsxRuntime.jsx(tooltip.Separator,{orientation:"vertical"}),jsxRuntime.jsx(UndoRedo,{})]}),jsxRuntime.jsxs("div",{className:"flex h-full items-center",children:[R?jsxRuntime.jsxs(tooltip.DropdownMenu,{children:[jsxRuntime.jsx(tooltip.DropdownMenuTrigger,{asChild:!0,children:jsxRuntime.jsx(tooltip.Button,{size:"sm",variant:"ghost",className:"h-7 w-7 rounded-md p-1",children:jsxRuntime.jsx(reactIcons.DotsHorizontalIcon,{className:"h-4 w-4"})})}),jsxRuntime.jsx(tooltip.DropdownMenuContent,{className:"w-56 border-border text-xs",children:jsxRuntime.jsxs(tooltip.DropdownMenuItem,{className:"flex items-center gap-2",onSelect:S=>S.preventDefault(),children:[jsxRuntime.jsx(reactIcons.LightningBoltIcon,{className:"h-4 w-4 text-gray-500"}),jsxRuntime.jsx("span",{className:"flex-1",children:b("Data Binding")}),jsxRuntime.jsx(tooltip.Switch,{checked:d,onCheckedChange:()=>x(!d)})]})})]}):null,jsxRuntime.jsx(ClearCanvas,{})]})]})},AddBlocksDialog=()=>{const{t:n}=reactI18next.useTranslation(),[c,d]=React.useState(""),[x,b]=React.useState(-1),[y,R]=React.useState(!1),S=useIsDragAndDropEnabled(),[,_]=useSidebarActivePanel();return usePubSub(CHAI_BUILDER_EVENTS.OPEN_ADD_BLOCK,A=>{S?_("add-block"):(d(A?A._id:null),b(isNaN(A==null?void 0:A.position)?-1:A==null?void 0:A.position),R(!0))}),usePubSub(CHAI_BUILDER_EVENTS.CLOSE_ADD_BLOCK,()=>{d(""),b(-1),R(!1)}),jsxRuntime.jsx(tooltip.AlertDialog,{open:y,onOpenChange:()=>y?R(!1):"",children:jsxRuntime.jsxs(tooltip.AlertDialogContent,{className:"max-w-5xl overflow-hidden border-border",children:[jsxRuntime.jsxs(tooltip.AlertDialogHeader,{className:"flex flex-row items-center justify-between",children:[jsxRuntime.jsx(tooltip.AlertDialogTitle,{className:"text-foreground",children:n("Add blocks")}),jsxRuntime.jsx("button",{onClick:()=>R(!1),className:"text-gray-500 hover:text-gray-600 dark:text-gray-400 dark:hover:text-gray-300",children:jsxRuntime.jsx(reactIcons.Cross2Icon,{className:"h-6 w-6"})})]}),jsxRuntime.jsx("div",{className:"no-scrollbar h-[500px] max-h-full overflow-hidden",children:jsxRuntime.jsx(AddBlocksPanel,{parentId:c,position:x,showHeading:!1})})]})})},AttrsEditor=React.memo(function n({preloadedAttributes:c=[],onAttributesChange:d}){const[x,b]=React.useState([]),[y,R]=React.useState(""),[S,_]=React.useState(""),[A,L]=React.useState(null),[T,O]=React.useState(""),U=React.useRef(null),M=React.useRef(null),D=usePageExternalData(),{t:K}=reactI18next.useTranslation();React.useEffect(()=>{b(c)},[c]);const $=()=>{if(y.startsWith("@")){O("Attribute keys cannot start with '@'");return}if(y){const q=[...x,{key:y,value:S}];d(q),b(x),R(""),_(""),O("")}},ee=q=>{const he=x.filter((le,xe)=>xe!==q);d(he),b(he)},ae=q=>{L(q),R(x[q].key),_(x[q].value)},Re=()=>{if(y.startsWith("@")){O("Attribute keys cannot start with '@'");return}if(A!==null&&y){const q=[...x];q[A]={key:y,value:S},d(q),b(q),L(null),R(""),_(""),O("")}},ye=q=>{q.key==="Enter"&&!q.shiftKey&&(q.preventDefault(),A!==null?Re():$())},de=React.useCallback(q=>{const he=Ee=>/[.,!?;:]/.test(Ee),le=(Ee,je,ze)=>{let We="",Pe="";const ue=je>0?Ee[je-1]:"",Ae=je<Ee.length?Ee[je]:"";return je>0&&(ue==="."||!he(ue)&&ue!==" ")&&(We=" "),je<Ee.length&&!he(Ae)&&Ae!==" "&&(Pe=" "),{text:We+ze+Pe,prefixLength:We.length,suffixLength:Pe.length}},xe=M.current;if(xe){const Ee=xe.selectionStart||0,je=xe.value||"",ze=xe.selectionEnd||Ee;if(ze>Ee){const He=`{{${q}}}`,{text:kn}=le(je,Ee,He),Ie=je.slice(0,Ee)+kn+je.slice(ze);_(Ie);return}const Pe=`{{${q}}}`,{text:ue}=le(je,Ee,Pe),Ae=je.slice(0,Ee)+ue+je.slice(Ee);_(Ae)}},[]);return jsxRuntime.jsxs("div",{className:"flex max-h-full flex-1 flex-col",children:[jsxRuntime.jsxs("form",{onSubmit:q=>{q.preventDefault(),A!==null?Re():$()},className:"space-y-3",children:[jsxRuntime.jsxs("div",{className:"flex flex-col gap-y-1",children:[jsxRuntime.jsxs("div",{className:"w-full",children:[jsxRuntime.jsx(tooltip.Label,{htmlFor:"attrKey",className:"text-[11px] font-normal leading-tight text-slate-600",children:"Key"}),jsxRuntime.jsx(tooltip.Input,{autoCapitalize:"off",autoCorrect:"off",spellCheck:"false",id:"attrKey",ref:U,value:y,onChange:q=>R(q.target.value),placeholder:K("Enter Key"),className:"py-0 text-xs font-normal leading-tight placeholder:text-slate-400"})]}),jsxRuntime.jsxs("div",{className:"w-full",children:[jsxRuntime.jsxs("div",{className:"flex items-center justify-between",children:[jsxRuntime.jsx(tooltip.Label,{htmlFor:"attrValue",className:"text-[11px] font-normal text-slate-600",children:"Value"}),!lodashEs.isEmpty(D)&&jsxRuntime.jsx(NestedPathSelector,{data:D,onSelect:de})]}),jsxRuntime.jsx(tooltip.Textarea,{autoCapitalize:"off",autoCorrect:"off",spellCheck:"false",id:"attrValue",rows:2,ref:M,value:S,onChange:q=>_(q.target.value),onKeyDown:ye,placeholder:"Enter Value",className:"text-xs font-normal leading-tight placeholder:text-slate-400"})]})]}),jsxRuntime.jsx("div",{className:"flex justify-end",children:jsxRuntime.jsx(tooltip.Button,{type:"submit",disabled:!y.length,variant:"default",size:"sm",className:"h-8 w-24 text-xs",children:A!==null?"Save":"Add"})}),T&&jsxRuntime.jsx("p",{className:"text-xs text-red-500",children:T})]}),jsxRuntime.jsx("div",{className:"space-y-1 py-4",children:x.map((q,he)=>jsxRuntime.jsxs("div",{className:"flex items-center justify-between rounded border p-2 text-sm",children:[jsxRuntime.jsxs("div",{className:"flex flex-col text-xs leading-tight",children:[jsxRuntime.jsx("span",{className:"truncate text-[12px] font-light text-muted-foreground",children:q.key}),jsxRuntime.jsx("span",{className:"max-w-[200px] text-wrap font-normal",children:q.value.toString()})]}),jsxRuntime.jsxs("div",{className:"flex-shrink-0 text-slate-400",children:[jsxRuntime.jsx(tooltip.Button,{variant:"ghost",size:"icon",className:"h-6 w-6",onClick:()=>ae(he),children:jsxRuntime.jsx(reactIcons.Pencil2Icon,{className:"h-3 w-3"})}),jsxRuntime.jsx(tooltip.Button,{variant:"ghost",size:"icon",className:"h-6 w-6",onClick:()=>ee(he),children:jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-3 w-3"})})]})]},he))})]})}),BlockAttributesEditor=React__namespace.memo(()=>{const n=useSelectedBlock(),[c,d]=React.useState([]),[x]=useSelectedStylingBlocks(),b=useUpdateBlocksProps(),y=`${lodashEs.get(x,"0.prop")}_attrs`;React__namespace.useEffect(()=>{const S=lodashEs.map(lodashEs.get(n,y),(_,A)=>({key:A,value:_}));lodashEs.isEmpty(S)?d([]):d(S)},[lodashEs.get(n,y)]);const R=React__namespace.useCallback((S=[])=>{const _={};lodashEs.forEach(S,A=>{lodashEs.isEmpty(A.key)||lodashEs.set(_,A.key,A.value)}),b([lodashEs.get(n,"_id")],{[y]:_})},[n,b,y]);return jsxRuntime.jsx("div",{className:"flex-col gap-y-2",children:jsxRuntime.jsx("div",{className:"flex flex-col",children:jsxRuntime.jsx("div",{children:jsxRuntime.jsx(AttrsEditor,{preloadedAttributes:c,onAttributesChange:R})})})})}),NoopComponent=()=>null,ResetStylesButton=()=>{const{resetAll:n}=useResetBlockStyles(),c=useSelectedBlock(),[d]=useSelectedStylingBlocks(),x=useRemoveAllClassesForBlock(),{t:b}=reactI18next.useTranslation();return!c||lodashEs.isEmpty(d)?null:jsxRuntime.jsxs(tooltip.DropdownMenu,{children:[jsxRuntime.jsx(tooltip.DropdownMenuTrigger,{asChild:!0,children:jsxRuntime.jsx("div",{className:"inline-flex rounded-sm p-0.5 hover:bg-gray-300",onClick:y=>y.stopPropagation(),children:jsxRuntime.jsx(reactIcons.DotsVerticalIcon,{className:"h-3 w-3"})})}),jsxRuntime.jsxs(tooltip.DropdownMenuContent,{side:"bottom",className:"border-border text-xs",children:[jsxRuntime.jsxs(tooltip.DropdownMenuItem,{className:"flex items-center gap-1 text-xs",onClick:()=>{n()},children:[jsxRuntime.jsx(reactIcons.ResetIcon,{className:"h-3 w-3"}),b("Reset styles")]}),jsxRuntime.jsxs(tooltip.DropdownMenuItem,{className:"text-xs",onClick:()=>{c&&x(c,!0)},children:[jsxRuntime.jsx(reactIcons.Cross2Icon,{className:"h-3 w-3"}),b("Clear styles")]})]})]})};function BlockAttributesToggle(){const{t:n}=reactI18next.useTranslation(),[c,d]=React.useState(!0),[x]=useSelectedStylingBlocks();return lodashEs.isEmpty(x)?null:jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsxs("div",{onClick:()=>d(!c),className:"flex cursor-pointer items-center justify-between border-t border-border py-3 text-xs font-medium hover:underline",children:[jsxRuntime.jsx("span",{children:n("Attributes")}),jsxRuntime.jsx("span",{children:jsxRuntime.jsx(reactIcons.ChevronDownIcon,{className:"h-4 w-4 text-gray-500 "+(c?"rotate-180":"")})})]}),c&&jsxRuntime.jsx(BlockAttributesEditor,{})]})}const PartialWrapper=({partialBlockId:n})=>{const c=useBuilderProp("gotoPage",lodashEs.noop),{saveState:d}=useSavePage(),{selectedLang:x,fallbackLang:b}=useLanguages(),y=React.useCallback(R=>{if(R.stopPropagation(),d!=="SAVED"){sonner.toast.error("You have unsaved changes. Please save the page first.");return}c({pageId:n,lang:x||b})},[d,c,n,x,b]);return jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsx("div",{className:"hidden",children:jsxRuntime.jsx("div",{onDoubleClick:y,className:"h-full w-full items-center justify-center",children:jsxRuntime.jsx("p",{className:"rounded-md bg-white px-2 py-1 text-xs",children:"Partial block. Double click to edit."})})})})},SettingsPanel=()=>{const n=useSelectedBlock(),{t:c}=reactI18next.useTranslation(),d=useBuilderProp("onError",lodashEs.noop),{hasPermission:x}=usePermissions();let b=!x(PERMISSIONS.EDIT_BLOCK);const y=!x(PERMISSIONS.EDIT_STYLES);return n&&n._type==="PartialBlock"?jsxRuntime.jsx(PartialWrapper,{partialBlockId:n.partialBlockId}):lodashEs.isNull(n)?jsxRuntime.jsx("div",{className:"p-4 text-center",children:jsxRuntime.jsxs("div",{className:"space-y-4 rounded-xl p-4 text-muted-foreground",children:[jsxRuntime.jsx(reactIcons.MixerHorizontalIcon,{className:"mx-auto text-3xl"}),jsxRuntime.jsx("h1",{children:c("Please select a block to edit settings or styles")})]})}):b&&y?jsxRuntime.jsx("div",{className:"p-4 text-center",children:jsxRuntime.jsxs("div",{className:"space-y-4 rounded-xl p-4 text-muted-foreground",children:[jsxRuntime.jsx(reactIcons.MixerHorizontalIcon,{className:"mx-auto text-3xl"}),jsxRuntime.jsx("h1",{children:c("You don't have permission to edit settings or styles")}),jsxRuntime.jsx("p",{children:c("Please contact your administrator to get access")})]})}):y?jsxRuntime.jsx(reactErrorBoundary.ErrorBoundary,{fallback:jsxRuntime.jsx(FallbackError,{}),onError:d,children:jsxRuntime.jsxs("div",{className:"no-scrollbar h-full max-h-min w-full overflow-y-auto",children:[jsxRuntime.jsx(BlockSettings,{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{})]})}):b?jsxRuntime.jsx(reactErrorBoundary.ErrorBoundary,{fallback:jsxRuntime.jsx(FallbackError,{}),onError:d,children:jsxRuntime.jsxs("div",{className:"no-scrollbar h-full max-h-min w-full overflow-y-auto overflow-x-hidden",children:[jsxRuntime.jsx("div",{className:"flex w-full items-center justify-end",children:jsxRuntime.jsx(ResetStylesButton,{})}),jsxRuntime.jsx(BlockStyling,{}),jsxRuntime.jsx(BlockAttributesToggle,{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{})]})}):jsxRuntime.jsx(reactErrorBoundary.ErrorBoundary,{fallback:jsxRuntime.jsx(FallbackError,{}),onError:d,children:jsxRuntime.jsxs(tooltip.Tabs,{defaultValue:"settings",className:"flex flex-1 flex-col",children:[jsxRuntime.jsx("div",{className:"flex items-center justify-between",children:jsxRuntime.jsxs(tooltip.TabsList,{className:"grid h-auto w-full grid-cols-2 p-1 py-1",children:[jsxRuntime.jsx(tooltip.TabsTrigger,{value:"settings",className:"text-xs",children:c("Settings")}),jsxRuntime.jsx(tooltip.TabsTrigger,{value:"styles",className:"text-xs",children:jsxRuntime.jsxs("div",{className:"flex w-full items-center justify-between",children:[jsxRuntime.jsx("span",{className:"w-[90%] text-center",children:c("Styling")}),jsxRuntime.jsx("span",{className:"w-[10%]",children:jsxRuntime.jsx(ResetStylesButton,{})})]})})]})}),jsxRuntime.jsxs(tooltip.TabsContent,{value:"settings",className:"no-scrollbar h-full max-h-min overflow-y-auto",children:[jsxRuntime.jsx(BlockSettings,{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{})]}),jsxRuntime.jsxs(tooltip.TabsContent,{value:"styles",className:"no-scrollbar h-full max-h-min max-w-full overflow-y-auto overflow-x-hidden",children:[jsxRuntime.jsx(BlockStyling,{}),jsxRuntime.jsx(BlockAttributesToggle,{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{}),jsxRuntime.jsx("br",{})]})]})})},CHAI_BUILDER_PANELS={},registerChaiSidebarPanel=(n,c)=>{lodashEs.has(CHAI_BUILDER_PANELS,n)&&console.warn(`Panel ${n} already registered. Overriding...`),lodashEs.set(CHAI_BUILDER_PANELS,n,{id:n,...c})},useChaiSidebarPanels=n=>React.useMemo(()=>lodashEs.filter(lodashEs.values(CHAI_BUILDER_PANELS),c=>c.position===n),[n,CHAI_BUILDER_PANELS]),DefaultTopBar=()=>jsxRuntime.jsx("div",{}),TOP_BAR={component:DefaultTopBar},registerChaiTopBar=n=>{TOP_BAR.component=n},useTopBarComponent=()=>React.useMemo(()=>TOP_BAR.component,[]),DEFAULT_PANEL_WIDTH=280,OutlineButton=({isActive:n,show:c})=>jsxRuntime.jsx(tooltip.Button,{variant:n?"default":"ghost",size:"icon",onClick:c,children:jsxRuntime.jsx(reactIcons.StackIcon,{className:"h-5 w-5"})}),AddBlocksButton=({isActive:n,show:c})=>useIsDragAndDropEnabled()&&jsxRuntime.jsx(tooltip.Button,{variant:n?"default":"ghost",size:"icon",onClick:c,children:jsxRuntime.jsx(reactIcons.PlusCircledIcon,{className:"h-5 w-5"})}),AskAiButton=({isActive:n,show:c})=>jsxRuntime.jsx(tooltip.Button,{variant:n?"default":"ghost",size:"icon",onClick:c,children:jsxRuntime.jsx(AiIcon,{})});registerChaiSidebarPanel("add-block",{button:AddBlocksButton,label:"Add Blocks",position:"top",isInternal:!0,width:DEFAULT_PANEL_WIDTH,panel:()=>jsxRuntime.jsx(AddBlocksPanel,{showHeading:!1,fromSidebar:!0,parentId:void 0,position:-1})});registerChaiSidebarPanel("chai-chat-panel",{button:AskAiButton,label:"Ask AI",position:"top",isInternal:!0,width:DEFAULT_PANEL_WIDTH,panel:()=>jsxRuntime.jsx("div",{className:"",children:jsxRuntime.jsx(AskAI,{})})});registerChaiSidebarPanel("outline",{button:OutlineButton,label:"Outline",position:"top",isInternal:!0,width:DEFAULT_PANEL_WIDTH,panel:()=>jsxRuntime.jsx("div",{className:"-mt-8",children:jsxRuntime.jsx(ListTree,{})})});const RootLayout=()=>{const n=useTopBarComponent(),[c,d]=useSidebarActivePanel(),x=React.useRef("outline"),[b,y]=React.useState(DEFAULT_PANEL_WIDTH),[R,S]=useRightPanel(),_=useChaiSidebarPanels("top"),A=useChaiSidebarPanels("bottom"),L=lodashEs.reverse([...A??[]]),T=React.useCallback(q=>{q.preventDefault()},[]),O=React.useMemo(()=>[_].flat(),[_]),U=React.useCallback(q=>{console.log("handleMenuItemClick",q,c),d(c===q?null:q)},[c,d]),{t:M}=reactI18next.useTranslation(),D=React.useMemo(()=>[..._,...A],[_,A]),K=useBuilderProp("htmlDir","ltr"),$=lodashEs.find(D,{id:c})??lodashEs.first(D),ee=lodashEs.get($,"width",DEFAULT_PANEL_WIDTH);React.useEffect(()=>{if(c!==null){const q=lodashEs.find(D,{id:c});q&&lodashEs.get(q,"view","standard")==="standard"&&(x.current=c,y(lodashEs.get(q,"width",DEFAULT_PANEL_WIDTH)))}},[c,D]);const ae=React.useMemo(()=>{if(c===null)return 0;const q=lodashEs.find(D,{id:c});return lodashEs.get(q,"view","standard")==="standard"?ee:b},[c,ee,b,D]),Re=React.useCallback(()=>{d(x.current)},[d,c]),ye=React.useCallback(()=>{d("outline")},[d]);React.useEffect(()=>{c!==null&&!lodashEs.find(D,{id:c})&&d("outline")},[c,D]);const de=React.useCallback(q=>{U(q)},[U]);return jsxRuntime.jsx("div",{dir:K,className:"h-screen max-h-full w-screen overflow-x-hidden bg-background text-foreground",children:jsxRuntime.jsxs(tooltip.TooltipProvider,{children:[jsxRuntime.jsxs("div",{onContextMenu:T,className:"flex h-full max-h-full flex-col bg-background text-foreground",children:[jsxRuntime.jsx("div",{className:"flex h-[50px] w-screen items-center border-b border-border",children:jsxRuntime.jsx(React.Suspense,{children:jsxRuntime.jsx(n,{})})}),jsxRuntime.jsxs("main",{className:"relative flex h-[calc(100vh-56px)] max-w-full flex-1 flex-row",children:[jsxRuntime.jsxs("div",{id:"sidebar",className:"flex w-12 flex-col items-center justify-between border-r border-border py-2",children:[jsxRuntime.jsx("div",{className:"flex flex-col gap-y-1",children:O.map((q,he)=>jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:React.createElement(lodashEs.get(q,"button",NoopComponent),{position:"top",panelId:q.id,isActive:c===q.id,show:()=>de(q.id)})}),jsxRuntime.jsx(tooltip.TooltipContent,{side:"right",children:jsxRuntime.jsx("p",{children:M(q.label)})})]},"button-top-"+he))}),jsxRuntime.jsx("div",{className:"flex flex-col space-y-1"}),jsxRuntime.jsx("div",{className:"flex flex-col",children:L==null?void 0:L.map((q,he)=>jsxRuntime.jsxs(tooltip.Tooltip,{children:[jsxRuntime.jsx(tooltip.TooltipTrigger,{asChild:!0,children:React.createElement(lodashEs.get(q,"button",NoopComponent),{position:"bottom",panelId:q.id,isActive:c===q.id,show:()=>de(q.id)})}),jsxRuntime.jsx(tooltip.TooltipContent,{side:"right",children:jsxRuntime.jsx("p",{children:M(q.label)})})]},"button-bottom-"+he))})]}),jsxRuntime.jsx(framerMotion.motion.div,{id:"left-panel",className:"h-full max-h-full border-r border-border",initial:{width:ae},animate:{width:ae},transition:{duration:.3,ease:"easeInOut"},children:c!==null&&lodashEs.get($,"view","standard")==="standard"&&jsxRuntime.jsxs("div",{className:"no-scrollbar flex h-full flex-col overflow-hidden px-3 py-2",children:[jsxRuntime.jsx("div",{className:`absolute top-2 flex h-10 items-center space-x-1 py-2 text-base font-bold ${lodashEs.get($,"isInternal",!1)?"":"w-64"}`,children:jsxRuntime.jsx("span",{children:M(lodashEs.get($,"label",""))})}),jsxRuntime.jsx("div",{className:"no-scrollbar h-full max-h-full overflow-y-auto pt-10",children:jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx("div",{children:"Loading..."}),children:React.createElement(lodashEs.get($,"panel",NoopComponent),{})})})]})}),jsxRuntime.jsxs("div",{id:"canvas-container",className:"flex h-full max-h-full flex-1 flex-col bg-slate-800/20",children:[jsxRuntime.jsx(CanvasTopBar,{}),jsxRuntime.jsx(React.Suspense,{children:jsxRuntime.jsx(CanvasArea,{})})]}),jsxRuntime.jsx(framerMotion.motion.div,{id:"right-panel",className:"h-full max-h-full border-l border-border",initial:{width:c==="ai"?0:DEFAULT_PANEL_WIDTH},animate:{width:c==="ai"?0:DEFAULT_PANEL_WIDTH},transition:{duration:.3,ease:"easeInOut"},children:jsxRuntime.jsx("div",{className:"no-scrollbar overflow h-full max-h-full overflow-hidden",children:jsxRuntime.jsxs("div",{className:"flex h-full max-h-full flex-col overflow-hidden p-3",children:[jsxRuntime.jsx("h2",{className:"-mt-1 flex items-center space-x-1 text-base font-bold",children:jsxRuntime.jsx("div",{className:"flex grow items-center gap-2",children:jsxRuntime.jsx("div",{className:"flex w-full items-center justify-between gap-2",children:R==="ai"?jsxRuntime.jsx(jsxRuntime.Fragment,{children:jsxRuntime.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(reactIcons.LightningBoltIcon,{className:"rtl:ml-2"})," ",M("AI Assistant")]})}):R==="theme"?jsxRuntime.jsxs("div",{className:"flex w-full items-center justify-between gap-2",children:[jsxRuntime.jsxs("span",{className:"flex items-center gap-2",children:[jsxRuntime.jsx(reactIcons.MixerHorizontalIcon,{className:"h-4 w-4 text-gray-600"}),M("Theme Settings")]}),jsxRuntime.jsx(tooltip.Button,{onClick:()=>S("block"),variant:"ghost",size:"icon",className:"text-xs",children:jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-4 w-4 rtl:ml-2"})})]}):null})})}),jsxRuntime.jsx("div",{className:"flex h-full max-h-full w-full",children:jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx("div",{children:"Loading..."}),children:R==="ai"?jsxRuntime.jsx(AskAI,{}):R==="theme"?jsxRuntime.jsx(ThemeConfigPanel,{}):jsxRuntime.jsx(SettingsPanel,{})})})]})})})]})]}),jsxRuntime.jsx(AddBlocksDialog,{}),c!==null&&lodashEs.get($,"view")==="drawer"&&jsxRuntime.jsx(tooltip.Sheet,{open:!0,onOpenChange:()=>Re(),children:jsxRuntime.jsxs(tooltip.SheetContent,{side:"left",className:"flex flex-col gap-0 p-0 sm:max-w-full",style:{width:`${ee}px`},children:[jsxRuntime.jsx(tooltip.SheetHeader,{className:"border-b border-border px-2 py-2.5",children:jsxRuntime.jsxs(tooltip.SheetTitle,{className:"flex items-center gap-2",children:[jsxRuntime.jsx("span",{className:"inline-block",children:lodashEs.get($,"icon",null)}),jsxRuntime.jsx("span",{children:M(lodashEs.get($,"label",""))})]})}),jsxRuntime.jsx("div",{className:"h-full max-h-full overflow-y-auto p-4",children:jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx("div",{children:"Loading..."}),children:React.createElement(lodashEs.get($,"panel",NoopComponent),{close:ye})})})]})})," ",c!==null&&lodashEs.get($,"view")==="modal"&&jsxRuntime.jsx(tooltip.Dialog,{open:!0,onOpenChange:()=>Re(),children:jsxRuntime.jsxs(tooltip.DialogContent,{className:"gap-0 p-0",style:{maxWidth:`${ee}px`},children:[jsxRuntime.jsx(tooltip.DialogHeader,{className:"border-b border-border px-2 py-3.5",children:jsxRuntime.jsxs(tooltip.DialogTitle,{className:"flex items-center gap-2",children:[jsxRuntime.jsx("span",{className:"inline-block",children:lodashEs.get($,"icon",null)}),jsxRuntime.jsx("span",{children:M(lodashEs.get($,"label",""))})]})}),jsxRuntime.jsx("div",{className:"max-h-[70vh] overflow-y-auto p-4",children:jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx("div",{children:"Loading..."}),children:React.createElement(lodashEs.get($,"panel",NoopComponent),{close:ye})})})]})}),c!==null&&lodashEs.get($,"view")==="overlay"&&jsxRuntime.jsx(framerMotion.motion.div,{className:"absolute bottom-0 left-12 right-0 top-0 z-50",initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.3},children:jsxRuntime.jsx("div",{className:"h-full w-full",children:jsxRuntime.jsxs(framerMotion.motion.div,{className:"flex h-full w-full flex-col bg-background",initial:{y:-20,opacity:0},animate:{y:0,opacity:1},exit:{y:20,opacity:0},transition:{duration:.3,delay:.1},children:[jsxRuntime.jsxs("div",{className:"flex h-[50px] items-center justify-between border-b border-border p-4",children:[jsxRuntime.jsxs("div",{className:"-ml-2 flex items-center gap-2 text-lg font-bold",children:[jsxRuntime.jsx("span",{className:"rtl:ml-2 rtl:inline-block",children:lodashEs.get($,"icon",null)}),jsxRuntime.jsx("span",{children:M(lodashEs.get($,"label",""))})]}),jsxRuntime.jsx(tooltip.Button,{onClick:()=>Re(),variant:"ghost",size:"icon",className:"",children:jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-5 w-5"})})]}),jsxRuntime.jsx("div",{className:"flex-1 overflow-y-auto p-4",children:jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx("div",{children:"Loading..."}),children:React.createElement(lodashEs.get($,"panel",NoopComponent),{close:ye})})})]})})})]})})},PreviewScreen=()=>{const[n,c]=usePreviewMode(),{t:d}=reactI18next.useTranslation(),x=useBuilderProp("previewComponent",null);return n?jsxRuntime.jsxs("div",{className:commonFunctions.cn("fixed inset-0 z-[999] bg-background",n?"block":"hidden"),children:[jsxRuntime.jsxs(tooltip.Button,{size:"sm",className:"absolute right-0 top-0 m-4 space-x-2",onClick:()=>c(!1),children:[jsxRuntime.jsx(reactIcons.EyeClosedIcon,{}),jsxRuntime.jsx("span",{children:d("Close Preview")})]}),jsxRuntime.jsx("div",{children:x?jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx(tooltip.Skeleton,{className:"h-96 w-full"}),children:React.createElement(x)}):null})]}):null},CHAI_FEATURE_FLAGS={},registerChaiFeatureFlag=(n,c)=>{if(CHAI_FEATURE_FLAGS[n])throw new Error(`Flag ${n} already exists`);CHAI_FEATURE_FLAGS[n]={key:n,value:!1,...c}},registerChaiFeatureFlags=n=>{Object.entries(n).forEach(([c,d])=>{if(CHAI_FEATURE_FLAGS[c])throw new Error(`Flag ${c} already exists`);registerChaiFeatureFlag(c,d)})},useChaiFeatureFlags=()=>CHAI_FEATURE_FLAGS,featureFlagsAtom=utils.atomWithStorage("chai-feature-flags",[]),useChaiFeatureFlag=n=>{const[c]=jotai.useAtom(featureFlagsAtom);return c.includes(n)},useToggleChaiFeatureFlag=n=>{const[c,d]=jotai.useAtom(featureFlagsAtom);return()=>{c.includes(n)?d(c.filter(b=>b!==n)):d([...c,n])}},IfChaiFeatureFlag=({flagKey:n,children:c})=>useChaiFeatureFlag(n)?c:null,FeatureToggle=({featureKey:n,options:c})=>{const d=useToggleChaiFeatureFlag(n),x=useChaiFeatureFlag(n);return jsxRuntime.jsxs("div",{className:"flex items-center space-x-3 rounded-md p-2 transition-colors hover:bg-gray-50 dark:hover:bg-gray-800",children:[jsxRuntime.jsx(tooltip.Switch,{checked:x,onCheckedChange:d}),jsxRuntime.jsxs("div",{className:"flex-1",children:[jsxRuntime.jsx("p",{className:"text-sm font-medium text-gray-900 dark:text-gray-100",children:c.key}),c.description&&jsxRuntime.jsx("p",{className:"mt-0.5 text-xs text-gray-500 dark:text-gray-400",children:c.description})]})]})},showFeatureFlagAtom=utils.atomWithStorage("show-feature-flag",null),ChaiFeatureFlagsWidgetComponent=({close:n,position:c,updatePosition:d})=>{const x=useChaiFeatureFlags(),[b,y]=React.useState(""),[R,S]=React.useState(!1),[_,A]=React.useState({x:0,y:0}),L=React.useMemo(()=>{if(!b.trim())return x;const M=b.toLowerCase();return Object.fromEntries(Object.entries(x).filter(([D,K])=>{var $;return(D==null?void 0:D.toLowerCase().includes(M))||(($=K==null?void 0:K.description)==null?void 0:$.toLowerCase().includes(M))}))},[x,b]),T=M=>{S(!0),A({x:M.clientX-c.x,y:M.clientY-c.y})},O=M=>{if(!R)return;const D=M.clientX-_.x,K=M.clientY-_.y,$=M.currentTarget,ee=$.offsetWidth,ae=$.offsetHeight,Re=window.innerWidth-ee,ye=window.innerHeight-ae,de=Math.max(0,Math.min(D,Re)),q=Math.max(0,Math.min(K,ye));d(de,q)},U=()=>{S(!1)};return React.useEffect(()=>{const M=()=>{R&&S(!1)};return window.addEventListener("mouseup",M),()=>window.removeEventListener("mouseup",M)},[R]),!c||c.x<0||c.y<0?null:jsxRuntime.jsxs("div",{onMouseDown:T,onMouseMove:O,onMouseUp:U,className:"fixed z-[9999999] select-none rounded-md border border-gray-300 bg-white p-3 shadow-2xl",style:{left:c.x,top:c.y,cursor:R?"grabbing":"grab",userSelect:"none"},children:[jsxRuntime.jsxs("div",{className:"relative sticky top-0 rounded-t-lg bg-white",children:[jsxRuntime.jsxs("div",{className:"mb-3 flex items-center justify-between",children:[jsxRuntime.jsxs("div",{children:[jsxRuntime.jsxs("h3",{className:"flex items-center gap-x-2 text-base font-semibold text-gray-900 dark:text-gray-100",children:[jsxRuntime.jsx(reactIcons.DragHandleDots2Icon,{})," Feature Flags"]}),jsxRuntime.jsxs("p",{className:"text-xs text-gray-400 dark:text-gray-400",children:["Toggle experimental features (",jsxRuntime.jsx("span",{className:"font-mono",children:"Ctrl+Shift+1"})," to toggle)"]})]}),jsxRuntime.jsx(tooltip.Button,{variant:"ghost",size:"sm",onClick:n,className:"absolute -right-2 -top-2 p-1 text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200",children:jsxRuntime.jsx(reactIcons.Cross1Icon,{className:"h-4 w-4"})})]}),jsxRuntime.jsxs("div",{className:"relative",children:[jsxRuntime.jsx(reactIcons.MagnifyingGlassIcon,{className:"absolute left-2.5 top-2.5 h-4 w-4 text-gray-400"}),jsxRuntime.jsx(tooltip.Input,{type:"search",placeholder:"Search features...",className:"w-full pl-8",value:b,onChange:M=>y(M.target.value),autoFocus:!0})]})]}),jsxRuntime.jsx("div",{className:"max-h-96 overflow-y-auto py-2",children:Object.keys(L).length>0?jsxRuntime.jsx("div",{className:"space-y-1",children:Object.entries(L).map(([M,D])=>jsxRuntime.jsx(FeatureToggle,{featureKey:M,options:D},M))}):jsxRuntime.jsx("div",{className:"py-8 text-center",children:jsxRuntime.jsxs("p",{className:"text-sm text-gray-500 dark:text-gray-400",children:['No features found matching "',b,'"']})})})]})},ChaiFeatureFlagsWidget=()=>{const[n,c]=jotai.useAtom(showFeatureFlagAtom);return reactHotkeysHook.useHotkeys("ctrl+shift+1,command+shift+1",()=>c(d=>d?{...d,show:!d.show}:{x:0,y:0,show:!0}),{enableOnFormTags:!0}),n!=null&&n.show?jsxRuntime.jsx(ChaiFeatureFlagsWidgetComponent,{position:n,close:()=>c(d=>({...d,show:!1})),updatePosition:(d,x)=>c(b=>({...b,x:d,y:x}))}):null},setDebugLogs=n=>{},getParentNodeIds=(n,c)=>{const d=[];let x=lodashEs.find(n,{_id:c}),b=lodashEs.get(x,"_parent","");for(;lodashEs.isString(b)&&!lodashEs.isEmpty(b);)d.push(x==null?void 0:x._parent),x=lodashEs.find(n,{_id:b}),b=x==null?void 0:x._parent;return lodashEs.flatten(d)},expandedIdsAtom=jotai.atom([]),useExpandTree=()=>{const[n]=useSelectedBlockIds(),c=jotai.useAtomValue(presentBlocksAtom),[,d]=jotai.useAtom(expandedIdsAtom);React.useEffect(()=>{let x=[];const b=lodashEs.first(n);lodashEs.isString(b)&&(x=[b,...getParentNodeIds(c,b)]),d(x)},[n,c,d])},ScreenTooSmall=()=>jsxRuntime.jsx("section",{className:"fixed inset-0 z-50 flex h-screen w-screen items-center justify-center bg-white bg-[linear-gradient(to_right,#f3f4f6_1px,transparent_1px),linear-gradient(to_bottom,#f3f4f6_1px,transparent_1px)] bg-[size:10px_10px] py-12 sm:py-16 lg:py-20 xl:hidden",children:jsxRuntime.jsx("div",{className:"mx-auto max-w-7xl px-4 sm:px-6 lg:px-8",children:jsxRuntime.jsxs("div",{className:"mx-auto max-w-md space-y-6 text-center",children:[jsxRuntime.jsx("img",{src:"https://ucarecdn.com/fbfc3b05-cb73-4e99-92a2-3a367b7c36cd/",alt:"Chai Builder",className:"mx-auto h-20 w-20 rounded-full shadow-lg transition-transform duration-300 hover:scale-105"}),jsxRuntime.jsxs("div",{className:"space-y-4",children:[jsxRuntime.jsx("h2",{className:"text-5xl font-bold tracking-tight text-gray-900",children:"Screen too small"}),jsxRuntime.jsxs("p",{className:"mx-auto max-w-sm text-sm leading-7 text-gray-600",children:["Please view this page on greater than ",jsxRuntime.jsx("strong",{className:"font-medium",children:"1280px"})," screen width for the best experience."]})]}),jsxRuntime.jsx("div",{className:"pt-4",children:jsxRuntime.jsxs("div",{className:"inline-flex items-center rounded-full bg-gray-100 px-4 py-2 text-sm text-gray-700",children:[jsxRuntime.jsx("svg",{className:"mr-2 h-5 w-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntime.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z"})}),"Minimum width: 1280px"]})})]})})});function isSelfAtom(n,c){return n.unstable_is?n.unstable_is(c):c===n}function hasInitialValue(n){return"init"in n}function isActuallyWritableAtom(n){return!!n.write}function isAtomStateInitialized(n){return"v"in n||"e"in n}function returnAtomValue(n){if("e"in n)throw n.e;return n.v}const promiseStateMap=new WeakMap;function isPendingPromise(n){var c;return isPromiseLike$1(n)&&!!((c=promiseStateMap.get(n))!=null&&c[0])}function abortPromise(n){const c=promiseStateMap.get(n);c!=null&&c[0]&&(c[0]=!1,c[1].forEach(d=>d()))}function registerAbortHandler(n,c){let d=promiseStateMap.get(n);if(!d){d=[!0,new Set],promiseStateMap.set(n,d);const x=()=>{d[0]=!1};n.then(x,x)}d[1].add(c)}function isPromiseLike$1(n){return typeof(n==null?void 0:n.then)=="function"}function addPendingPromiseToDependency(n,c,d){if(!d.p.has(n)){d.p.add(n);const x=()=>d.p.delete(n);c.then(x,x)}}function getMountedOrPendingDependents(n,c,d){var x;const b=new Set;for(const y of((x=d.get(n))==null?void 0:x.t)||[])d.has(y)&&b.add(y);for(const y of c.p)b.add(y);return b}const atomRead=(n,c,...d)=>c.read(...d),atomWrite=(n,c,...d)=>c.write(...d),atomOnInit=(n,c)=>{var d;return(d=c.unstable_onInit)==null?void 0:d.call(c,n)},atomOnMount=(n,c,d)=>{var x;return(x=c.onMount)==null?void 0:x.call(c,d)},ensureAtomState=(n,c)=>{const d=getBuildingBlocks(n),x=d[0],b=d[9];let y=x.get(c);return y||(y={d:new Map,p:new Set,n:0},x.set(c,y),b==null||b(n,c)),y},flushCallbacks=n=>{const c=getBuildingBlocks(n),d=c[1],x=c[3],b=c[4],y=c[5],R=c[6],S=c[13],_=[],A=L=>{try{L()}catch(T){_.push(T)}};do{R.f&&A(R.f);const L=new Set,T=L.add.bind(L);x.forEach(O=>{var U;return(U=d.get(O))==null?void 0:U.l.forEach(T)}),x.clear(),y.forEach(T),y.clear(),b.forEach(T),b.clear(),L.forEach(A),x.size&&S(n)}while(x.size||y.size||b.size);if(_.length)throw new AggregateError(_)},recomputeInvalidatedAtoms=n=>{const c=getBuildingBlocks(n),d=c[1],x=c[2],b=c[3],y=c[11],R=c[14],S=c[17],_=[],A=new WeakSet,L=new WeakSet,T=Array.from(b);for(;T.length;){const O=T[T.length-1],U=y(n,O);if(L.has(O)){T.pop();continue}if(A.has(O)){x.get(O)===U.n&&_.push([O,U]),L.add(O),T.pop();continue}A.add(O);for(const M of getMountedOrPendingDependents(O,U,d))A.has(M)||T.push(M)}for(let O=_.length-1;O>=0;--O){const[U,M]=_[O];let D=!1;for(const K of M.d.keys())if(K!==U&&b.has(K)){D=!0;break}D&&(R(n,U),S(n,U)),x.delete(U)}},readAtomState=(n,c)=>{var d;const x=getBuildingBlocks(n),b=x[1],y=x[2],R=x[3],S=x[6],_=x[7],A=x[11],L=x[12],T=x[13],O=x[14],U=x[16],M=x[17],D=A(n,c);if(isAtomStateInitialized(D)&&(b.has(c)&&y.get(c)!==D.n||Array.from(D.d).every(([q,he])=>O(n,q).n===he)))return D;D.d.clear();let K=!0;function $(){b.has(c)&&(M(n,c),T(n),L(n))}function ee(q){var he;if(isSelfAtom(c,q)){const xe=A(n,q);if(!isAtomStateInitialized(xe))if(hasInitialValue(q))setAtomStateValueOrPromise(n,q,q.init);else throw new Error("no atom init");return returnAtomValue(xe)}const le=O(n,q);try{return returnAtomValue(le)}finally{D.d.set(q,le.n),isPendingPromise(D.v)&&addPendingPromiseToDependency(c,D.v,le),(he=b.get(q))==null||he.t.add(c),K||$()}}let ae,Re;const ye={get signal(){return ae||(ae=new AbortController),ae.signal},get setSelf(){return!Re&&isActuallyWritableAtom(c)&&(Re=(...q)=>{if(!K)try{return U(n,c,...q)}finally{T(n),L(n)}}),Re}},de=D.n;try{const q=_(n,c,ee,ye);return setAtomStateValueOrPromise(n,c,q),isPromiseLike$1(q)&&(registerAbortHandler(q,()=>ae==null?void 0:ae.abort()),q.then($,$)),D}catch(q){return delete D.v,D.e=q,++D.n,D}finally{K=!1,de!==D.n&&y.get(c)===de&&(y.set(c,D.n),R.add(c),(d=S.c)==null||d.call(S,c))}},invalidateDependents=(n,c)=>{const d=getBuildingBlocks(n),x=d[1],b=d[2],y=d[11],R=[c];for(;R.length;){const S=R.pop(),_=y(n,S);for(const A of getMountedOrPendingDependents(S,_,x)){const L=y(n,A);b.set(A,L.n),R.push(A)}}},writeAtomState=(n,c,...d)=>{const x=getBuildingBlocks(n),b=x[3],y=x[6],R=x[8],S=x[11],_=x[12],A=x[13],L=x[14],T=x[15],O=x[17];let U=!0;const M=K=>returnAtomValue(L(n,K)),D=(K,...$)=>{var ee;const ae=S(n,K);try{if(isSelfAtom(c,K)){if(!hasInitialValue(K))throw new Error("atom not writable");const Re=ae.n,ye=$[0];setAtomStateValueOrPromise(n,K,ye),O(n,K),Re!==ae.n&&(b.add(K),(ee=y.c)==null||ee.call(y,K),T(n,K));return}else return writeAtomState(n,K,...$)}finally{U||(A(n),_(n))}};try{return R(n,c,M,D,...d)}finally{U=!1}},mountDependencies=(n,c)=>{var d;const x=getBuildingBlocks(n),b=x[1],y=x[3],R=x[6],S=x[11],_=x[15],A=x[18],L=x[19],T=S(n,c),O=b.get(c);if(O&&!isPendingPromise(T.v)){for(const[U,M]of T.d)if(!O.d.has(U)){const D=S(n,U);A(n,U).t.add(c),O.d.add(U),M!==D.n&&(y.add(U),(d=R.c)==null||d.call(R,U),_(n,U))}for(const U of O.d||[])if(!T.d.has(U)){O.d.delete(U);const M=L(n,U);M==null||M.t.delete(c)}}},mountAtom=(n,c)=>{var d;const x=getBuildingBlocks(n),b=x[1],y=x[4],R=x[6],S=x[10],_=x[11],A=x[12],L=x[13],T=x[14],O=x[16],U=_(n,c);let M=b.get(c);if(!M){T(n,c);for(const D of U.d.keys())mountAtom(n,D).t.add(c);if(M={l:new Set,d:new Set(U.d.keys()),t:new Set},b.set(c,M),(d=R.m)==null||d.call(R,c),isActuallyWritableAtom(c)){const D=()=>{let K=!0;const $=(...ee)=>{try{return O(n,c,...ee)}finally{K||(L(n),A(n))}};try{const ee=S(n,c,$);ee&&(M.u=()=>{K=!0;try{ee()}finally{K=!1}})}finally{K=!1}};y.add(D)}}return M},unmountAtom=(n,c)=>{var d;const x=getBuildingBlocks(n),b=x[1],y=x[5],R=x[6],S=x[11],_=x[19],A=S(n,c);let L=b.get(c);if(L&&!L.l.size&&!Array.from(L.t).some(T=>{var O;return(O=b.get(T))==null?void 0:O.d.has(c)})){L.u&&y.add(L.u),L=void 0,b.delete(c),(d=R.u)==null||d.call(R,c);for(const T of A.d.keys()){const O=_(n,T);O==null||O.t.delete(c)}return}return L},setAtomStateValueOrPromise=(n,c,d)=>{const x=getBuildingBlocks(n)[11],b=x(n,c),y="v"in b,R=b.v;if(isPromiseLike$1(d))for(const S of b.d.keys())addPendingPromiseToDependency(c,d,x(n,S));b.v=d,delete b.e,(!y||!Object.is(R,b.v))&&(++b.n,isPromiseLike$1(R)&&abortPromise(R))},storeGet=(n,c)=>{const d=getBuildingBlocks(n)[14];return returnAtomValue(d(n,c))},storeSet=(n,c,...d)=>{const x=getBuildingBlocks(n),b=x[12],y=x[13],R=x[16];try{return R(n,c,...d)}finally{y(n),b(n)}},storeSub=(n,c,d)=>{const x=getBuildingBlocks(n),b=x[12],y=x[18],R=x[19],_=y(n,c).l;return _.add(d),b(n),()=>{_.delete(d),R(n,c),b(n)}},buildingBlockMap=new WeakMap;function getBuildingBlocks(n){return buildingBlockMap.get(n)}function buildStore(...n){const c={get(x){const b=getBuildingBlocks(c)[21];return b(c,x)},set(x,...b){const y=getBuildingBlocks(c)[22];return y(c,x,...b)},sub(x,b){const y=getBuildingBlocks(c)[23];return y(c,x,b)}},d=[new WeakMap,new WeakMap,new WeakMap,new Set,new Set,new Set,{},atomRead,atomWrite,atomOnInit,atomOnMount,ensureAtomState,flushCallbacks,recomputeInvalidatedAtoms,readAtomState,invalidateDependents,writeAtomState,mountDependencies,mountAtom,unmountAtom,setAtomStateValueOrPromise,storeGet,storeSet,storeSub].map((x,b)=>n[b]||x);return buildingBlockMap.set(c,Object.freeze(d)),c}function createStore(){return buildStore()}let defaultStore;function getDefaultStore(){return defaultStore||(defaultStore=createStore()),defaultStore}const StoreContext=React.createContext(void 0);function useStore(n){return React.useContext(StoreContext)||getDefaultStore()}const isPromiseLike=n=>typeof(n==null?void 0:n.then)=="function",attachPromiseStatus=n=>{n.status||(n.status="pending",n.then(c=>{n.status="fulfilled",n.value=c},c=>{n.status="rejected",n.reason=c}))},use=React.use||(n=>{if(n.status==="pending")throw n;if(n.status==="fulfilled")return n.value;throw n.status==="rejected"?n.reason:(attachPromiseStatus(n),n)}),continuablePromiseMap=new WeakMap,createContinuablePromise=(n,c)=>{let d=continuablePromiseMap.get(n);return d||(d=new Promise((x,b)=>{let y=n;const R=A=>L=>{y===A&&x(L)},S=A=>L=>{y===A&&b(L)},_=()=>{try{const A=c();isPromiseLike(A)?(continuablePromiseMap.set(A,d),y=A,A.then(R(A),S(A)),registerAbortHandler(A,_)):x(A)}catch(A){b(A)}};n.then(R(n),S(n)),registerAbortHandler(n,_)}),continuablePromiseMap.set(n,d)),d};function useAtomValue(n,c){const{delay:d,unstable_promiseStatus:x=!React.use}={},b=useStore(),[[y,R,S],_]=React.useReducer(L=>{const T=b.get(n);return Object.is(L[0],T)&&L[1]===b&&L[2]===n?L:[T,b,n]},void 0,()=>[b.get(n),b,n]);let A=y;if((R!==b||S!==n)&&(_(),A=b.get(n)),React.useEffect(()=>{const L=b.sub(n,()=>{if(x)try{const T=b.get(n);isPromiseLike(T)&&attachPromiseStatus(createContinuablePromise(T,()=>b.get(n)))}catch{}if(typeof d=="number"){setTimeout(_,d);return}_()});return _(),L},[b,n,d,x]),React.useDebugValue(A),isPromiseLike(A)){const L=createContinuablePromise(A,()=>b.get(n));return x&&attachPromiseStatus(L),use(L)}return A}function useSetAtom(n,c){const d=useStore();return React.useCallback((...b)=>d.set(n,...b),[d,n])}function useAtom(n,c){return[useAtomValue(n),useSetAtom(n)]}function convertAttributeName(n){const c={class:"className",for:"htmlFor",tabindex:"tabIndex",readonly:"readOnly",maxlength:"maxLength",minlength:"minLength",autocomplete:"autoComplete",autofocus:"autoFocus",autoplay:"autoPlay",formaction:"formAction",formenctype:"formEncType",formmethod:"formMethod",formnovalidate:"formNoValidate",formtarget:"formTarget",novalidate:"noValidate",crossorigin:"crossOrigin",datetime:"dateTime",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",allowfullscreen:"allowFullScreen"};if(c[n.toLowerCase()])return c[n.toLowerCase()];const d={"accent-height":"accentHeight","alignment-baseline":"alignmentBaseline","arabic-form":"arabicForm","baseline-shift":"baselineShift","cap-height":"capHeight","clip-path":"clipPath","clip-rule":"clipRule","color-interpolation":"colorInterpolation","color-interpolation-filters":"colorInterpolationFilters","color-profile":"colorProfile","color-rendering":"colorRendering","dominant-baseline":"dominantBaseline","enable-background":"enableBackground","fill-opacity":"fillOpacity","fill-rule":"fillRule","flood-color":"floodColor","flood-opacity":"floodOpacity","font-family":"fontFamily","font-size":"fontSize","font-size-adjust":"fontSizeAdjust","font-stretch":"fontStretch","font-style":"fontStyle","font-variant":"fontVariant","font-weight":"fontWeight","glyph-name":"glyphName","glyph-orientation-horizontal":"glyphOrientationHorizontal","glyph-orientation-vertical":"glyphOrientationVertical","horiz-adv-x":"horizAdvX","horiz-origin-x":"horizOriginX","image-rendering":"imageRendering","letter-spacing":"letterSpacing","lighting-color":"lightingColor","marker-end":"markerEnd","marker-mid":"markerMid","marker-start":"markerStart","overline-position":"overlinePosition","overline-thickness":"overlineThickness","paint-order":"paintOrder","panose-1":"panose1","pointer-events":"pointerEvents","rendering-intent":"renderingIntent","shape-rendering":"shapeRendering","stop-color":"stopColor","stop-opacity":"stopOpacity","strikethrough-position":"strikethroughPosition","strikethrough-thickness":"strikethroughThickness","stroke-dasharray":"strokeDasharray","stroke-dashoffset":"strokeDashoffset","stroke-linecap":"strokeLinecap","stroke-linejoin":"strokeLinejoin","stroke-miterlimit":"strokeMiterlimit","stroke-opacity":"strokeOpacity","stroke-width":"strokeWidth","text-anchor":"textAnchor","text-decoration":"textDecoration","text-rendering":"textRendering","underline-position":"underlinePosition","underline-thickness":"underlineThickness","unicode-bidi":"unicodeBidi","unicode-range":"unicodeRange","units-per-em":"unitsPerEm","v-alphabetic":"vAlphabetic","v-hanging":"vHanging","v-ideographic":"vIdeographic","v-mathematical":"vMathematical","vector-effect":"vectorEffect","vert-adv-y":"vertAdvY","vert-origin-x":"vertOriginX","vert-origin-y":"vertOriginY","word-spacing":"wordSpacing","writing-mode":"writingMode","x-height":"xHeight"};return d[n]?d[n]:n}function domToJsx(n,c=0){var A;if(Array.isArray(n)){if(n.length===0)return"";if(n.length===1)return domToJsx(n[0],c);const L=" ".repeat(c);let T=`${L}<>
341
+ `;for(const O of n)T+=domToJsx(O,c+1);return T+=`${L}</>
342
+ `,T}const d=" ".repeat(c);if(n.nodeType===Node.TEXT_NODE){const L=(A=n.textContent)==null?void 0:A.trim();return L?`${d}${L}
343
+ `:""}if(n.nodeType!==Node.ELEMENT_NODE)return"";const x=n.tagName.toLowerCase();if(["img","br","hr","input","meta","link","area","base","col","embed","source","track","wbr"].includes(x)){const L=[];for(const O of n.attributes)if(O.name.startsWith("on")&&O.name!=="on"){const U=O.name.toLowerCase().replace(/on(\w)/,(M,D)=>"on"+D.toUpperCase());L.push(`${U}={${O.value}}`)}else if(O.name==="style"&&O.value){const U=O.value.split(";").reduce((M,D)=>{const[K,$]=D.split(":").map(ee=>ee.trim());if(K&&$){const ee=K.replace(/-([a-z])/g,ae=>ae[1].toUpperCase());M[ee]=$.replace(/['"]/g,"")}return M},{});L.push(`style={${JSON.stringify(U)}}`)}else{const U=convertAttributeName(O.name);L.push(`${U}="${O.value}"`)}const T=L.length>0?` ${L.join(" ")}`:"";return`${d}<${x}${T} />
344
+ `}let y=`${d}<${x}`;const R=[];for(const L of n.attributes)if(L.name.startsWith("on")&&L.name!=="on"){const T=L.name.toLowerCase().replace(/on(\w)/,(O,U)=>"on"+U.toUpperCase());R.push(`${T}={${L.value}}`)}else if(L.name==="style"&&L.value){const T=L.value.split(";").reduce((O,U)=>{const[M,D]=U.split(":").map(K=>K.trim());if(M&&D){const K=M.replace(/-([a-z])/g,$=>$[1].toUpperCase());O[K]=D.replace(/['"]/g,"")}return O},{});R.push(`style={${JSON.stringify(T)}}`)}else{const T=convertAttributeName(L.name);R.push(`${T}="${L.value}"`)}R.length>0&&(y+=" "+R.join(" "));const S=Array.from(n.childNodes);if(!S.some(L=>{var T;return L.nodeType===Node.TEXT_NODE?(T=L.textContent)==null?void 0:T.trim():!0}))y+=` />
345
+ `;else{y+=`>
346
+ `;for(const L of S)y+=domToJsx(L,c+1);y+=`${d}</${x}>
347
+ `}return y}function formatHtml(n){if(!n)return"";let c="",d=0;const x=" ";return n=n.replace(/>\s+</g,"><").trim(),n.split(/(<\/?[^>]+>)/g).filter(y=>y.trim()).forEach(y=>{y.match(/^<\/\w/)?(d=Math.max(0,d-1),c+=x.repeat(d)+y+`
348
+ `):y.match(/\/>$/)?c+=x.repeat(d)+y+`
349
+ `:y.match(/^<\w[^>]*[^\/]>$/)?(c+=x.repeat(d)+y+`
350
+ `,d++):y.trim()&&(c+=x.repeat(d)+y.trim()+`
351
+ `)}),c.trim()}const CodeDisplay=React.lazy(()=>Promise.resolve().then(()=>require("./code-display-B1O2gN5f.cjs")));async function convertHtmlToJsx(n){try{const c=document.createElement("div");c.innerHTML=n;const d=Array.from(c.children);return{jsx:domToJsx(d.length===1?d[0]:d),html:c.innerHTML}}catch{return{html:n,jsx:n}}}const getExportedCoded=async({selectedBlock:n,html:c,isTypeScript:d=!1})=>{let x=(n==null?void 0:n._name)||(n==null?void 0:n._type)||"Component";x=lodashEs.camelCase(x).replace(/^./,A=>A.toUpperCase());const b=" ";let{jsx:y,html:R}=await convertHtmlToJsx(c);return y=y==null?void 0:y.split(`
352
+ `).join(`
353
+ ${b}${b}`),y=`${d?`import React from 'react';
354
+
355
+ `:""}export const ${x}${d?": React.FC":""} = () => {
356
+ ${b}return (
357
+ ${b}${b}${y==null?void 0:y.trimEnd()}
358
+ ${b})
359
+ }`,{jsx:y,html:formatHtml(R),componentName:x}},ExportCodeModalContent=({tab:n})=>{var $;const{t:c}=reactI18next.useTranslation(),[d,x]=React.useState({html:"",jsx:""}),b=useSelectedBlock(),y=useBlocksHtmlForAi(),[R,S]=React.useState(""),[_,A]=React.useState(!1),L=()=>{switch(n){case"js":return`${R}.jsx`;case"ts":return`${R}.tsx`;case"html":return`${R}.html`;case"tailwind":return"tailwind.config.js"}},T=()=>{switch(n){case"js":case"ts":return"javascript";case"html":return"HTML";case"tailwind":return"JSON"}},O=React.useCallback(async()=>{try{A(!1);let ee=y({EXTRA_CORE_BLOCKS:["Icon"]});const ae=n==="ts",{jsx:Re,html:ye,componentName:de}=await getExportedCoded({selectedBlock:b,html:ee,isTypeScript:ae});x({html:ye,jsx:Re}),S(de),A(!0)}catch{const ae="<div>Export failed. Close the modal and try again.</div>";x({html:ae,jsx:ae}),sonner.toast.error(c("Failed to generate export HTML"))}},[c,n,b,y]);React.useEffect(()=>{O()},[O,n]);const U=React.useCallback(async ee=>{try{navigator.clipboard.writeText(ee),sonner.toast.success(c("Export code copied!"))}catch{sonner.toast.error(c("Failed to copy export code"))}},[c]),M=ee=>{const ae=new Blob([ee],{type:"text/jsx"}),Re=URL.createObjectURL(ae),ye=document.createElement("a");ye.href=Re,ye.download=L(),document.body.appendChild(ye),ye.click(),URL.revokeObjectURL(Re),document.body.removeChild(ye),sonner.toast.success(c("Export code downloaded successfully!"))},D=jsxRuntime.jsxs("span",{children:["Download ",jsxRuntime.jsx("span",{className:"font-mono text-xs font-light text-gray-300",children:L()})]}),K=React.useMemo(()=>{const ee={extend:getChaiBuilderTailwindConfig.shadcnTheme()},ae=JSON.stringify(ee,null,2);return`{
360
+ // Your tailwind config ...
361
+
362
+ "theme": ${ae==null?void 0:ae.split(`
363
+ `).join(`
364
+ `)},
365
+ }`},[]);return(($=d==null?void 0:d.jsx)==null?void 0:$.length)>0&&_?jsxRuntime.jsx(CodeDisplay,{onCopy:U,code:n==="tailwind"?K:n==="html"?d.html:d.jsx,language:T(),downloadText:D,onDownload:M},n):jsxRuntime.jsx("div",{className:"flex h-[620px] w-full items-center justify-center p-4",children:"Generating code..."})},ExportCodeModal=()=>{const{t:n}=reactI18next.useTranslation(),[c,d]=React.useState(!1),{setMode:x}=useEditorMode(),[b,y]=React.useState("js"),R=React.useCallback(async()=>{y("js"),x("view"),d(!0)},[c]);usePubSub(CHAI_BUILDER_EVENTS.OPEN_EXPORT_CODE,R);const S=async()=>{x("edit"),await new Promise(_=>setTimeout(_,300)),d(!1)};return jsxRuntime.jsx(tooltip.Dialog,{open:c,onOpenChange:S,children:jsxRuntime.jsxs(tooltip.DialogContent,{className:"max-w-5xl overflow-hidden border-border",children:[jsxRuntime.jsxs(tooltip.DialogHeader,{className:"flex flex-row items-center justify-between",children:[jsxRuntime.jsx(tooltip.DialogTitle,{className:"text-foreground",children:n("Export Code")}),jsxRuntime.jsx(tooltip.Tabs,{defaultValue:"js",onValueChange:y,children:jsxRuntime.jsxs(tooltip.TabsList,{children:[jsxRuntime.jsx(tooltip.TabsTrigger,{value:"js",children:"Javascript"}),jsxRuntime.jsx(tooltip.TabsTrigger,{value:"ts",children:"Typescript"}),jsxRuntime.jsx(tooltip.TabsTrigger,{value:"html",children:"HTML"}),jsxRuntime.jsx(tooltip.TabsTrigger,{value:"tailwind",children:"Tailwind config"})]})}),jsxRuntime.jsx("div",{})]}),jsxRuntime.jsx("div",{className:"flex min-h-[400px] flex-col gap-4",children:c&&jsxRuntime.jsx(React.Suspense,{fallback:jsxRuntime.jsx("div",{className:"flex h-[400px] items-center justify-center text-muted-foreground",children:"Loading code editor..."}),children:jsxRuntime.jsx(reactErrorBoundary.ErrorBoundary,{fallback:jsxRuntime.jsx("div",{children:"Something went wrong"}),children:jsxRuntime.jsx(ExportCodeModalContent,{tab:b})})})})]})})},useAutoSave=()=>{const{savePage:n,saveState:c}=useSavePage(),d=useBuilderProp("autoSave",!0),x=useBuilderProp("autoSaveInterval",60);web.useIntervalEffect(()=>{d&&(c==="SAVED"||c==="SAVING"||n(!0))},d?x*1e3:void 0)},ChaiWatchers=n=>{const[,c]=useBlocksStore(),d=useBuilderReset(),[x]=useAtom(builderSaveStateAtom);useAtom(selectedLibraryAtom),useKeyEventWatcher(),useExpandTree(),useAutoSave(),useWatchPartailBlocks(),useUnmountBroadcastChannel();const{postMessage:b}=useBroadcastChannel(),[,y]=useAtom(isPageLoadedAtom);return React.useEffect(()=>{builderStore.set(chaiBuilderPropsAtom,lodashEs.omit(n,["blocks","translations","pageExternalData"]))},[n]),React.useEffect(()=>{builderStore.set(chaiPageExternalDataAtom,n.pageExternalData||{})},[n.pageExternalData]),React.useEffect(()=>{y(!1),setTimeout(()=>{const R=runtime.syncBlocksWithDefaults(n.blocks||[]);c(R),R&&R.length>0&&b({type:"blocks-updated",blocks:R}),d(),y(!0)},400)},[n.blocks]),React.useEffect(()=>{i18n.changeLanguage(n.locale||"en")},[n.locale]),React.useEffect(()=>{setDebugLogs(n.debugLogs)},[n.debugLogs]),React.useEffect(()=>{n.translations&&lodashEs.each(n.translations,(R,S)=>{i18n.addResourceBundle(S,"translation",R,!0,!0)})},[n.translations]),React.useEffect(()=>(x!=="SAVED"?window.onbeforeunload=()=>"":window.onbeforeunload=null,()=>{window.onbeforeunload=null}),[x]),null},ChaiBuilderComponent=n=>{const c=React.useMemo(()=>n.layout||RootLayout,[n.layout]),d=useBuilderProp("builderTheme",plugin.defaultThemeValues),x=useBuilderProp("flags.exportCode",!1);return jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(CssThemeVariables,{theme:d}),jsxRuntime.jsx(c,{}),x&&jsxRuntime.jsx(ExportCodeModal,{})]})},ChaiBuilderEditor=n=>{const c=n.onError||lodashEs.noop;return jsxRuntime.jsx("div",{className:"h-screen w-screen",children:jsxRuntime.jsxs(reactErrorBoundary.ErrorBoundary,{fallback:jsxRuntime.jsx(FallbackError,{}),onError:c,children:[jsxRuntime.jsx(ScreenTooSmall,{}),jsxRuntime.jsx(ChaiBuilderComponent,{...n}),jsxRuntime.jsx(ChaiWatchers,{...n}),jsxRuntime.jsx(PreviewScreen,{}),jsxRuntime.jsx(sonner.Toaster,{richColors:!0}),jsxRuntime.jsx(ChaiFeatureFlagsWidget,{})]})})};if(typeof window>"u")throw new Error("@chaibuilder/sdk is only supported in the browser. Avoid using it in the server side.");exports.AIUserPrompt=AIUserPrompt;exports.AddBlocksDialog=AddBlocksDialog;exports.AddBlocksPanel=AddBlocksPanel;exports.BlockAttributesEditor=BlockAttributesEditor;exports.BlockSettings=BlockSettings;exports.BlockStyling=BlockStyling;exports.Breakpoints=Breakpoints$1;exports.CanvasArea=CanvasArea;exports.ChaiBuilderEditor=ChaiBuilderEditor;exports.ChaiDraggableBlock=ChaiDraggableBlock;exports.DarkMode=DarkMode;exports.DefaultChaiBlocks=DefaultChaiBlocks;exports.ExportCodeModal=ExportCodeModal;exports.IfChaiFeatureFlag=IfChaiFeatureFlag;exports.ImportHTML=ImportHTML;exports.ListTree=ListTree;exports.NestedPathSelector=NestedPathSelector;exports.PERMISSIONS=PERMISSIONS;exports.ThemeConfigPanel=ThemeConfigPanel;exports.UILibrariesPanel=UILibrariesPanel;exports.UndoRedo=UndoRedo;exports.getClassValueAndUnit=getClassValueAndUnit;exports.registerBlockSettingField=registerBlockSettingField;exports.registerBlockSettingTemplate=registerBlockSettingTemplate;exports.registerBlockSettingWidget=registerBlockSettingWidget;exports.registerChaiAddBlockTab=registerChaiAddBlockTab;exports.registerChaiFeatureFlag=registerChaiFeatureFlag;exports.registerChaiFeatureFlags=registerChaiFeatureFlags;exports.registerChaiLibrary=registerChaiLibrary;exports.registerChaiMediaManager=registerChaiMediaManager;exports.registerChaiPreImportHTMLHook=registerChaiPreImportHTMLHook;exports.registerChaiSaveToLibrary=registerChaiSaveToLibrary;exports.registerChaiSidebarPanel=registerChaiSidebarPanel;exports.registerChaiTopBar=registerChaiTopBar;exports.useAddBlock=useAddBlock;exports.useAddClassesToBlocks=useAddClassesToBlocks;exports.useAskAi=useAskAi;exports.useBlockHighlight=useBlockHighlight;exports.useBlocksHtmlForAi=useBlocksHtmlForAi;exports.useBlocksStore=useBlocksStore;exports.useBlocksStoreUndoableActions=useBlocksStoreUndoableActions;exports.useBrandingOptions=useBrandingOptions;exports.useBuilderProp=useBuilderProp;exports.useBuilderReset=useBuilderReset;exports.useCanvasDisplayWidth=useCanvasDisplayWidth;exports.useCanvasWidth=useCanvasWidth;exports.useCanvasZoom=useCanvasZoom;exports.useChaiFeatureFlag=useChaiFeatureFlag;exports.useChaiFeatureFlags=useChaiFeatureFlags;exports.useCodeEditor=useCodeEditor;exports.useCopyBlocks=useCopyBlocks;exports.useCopyToClipboard=useCopyToClipboard;exports.useCurrentPage=useCurrentPage;exports.useCutBlockIds=useCutBlockIds;exports.useDarkMode=useDarkMode;exports.useDuplicateBlocks=useDuplicateBlocks;exports.useHighlightBlockId=useHighlightBlockId;exports.useHtmlToBlocks=useHtmlToBlocks;exports.useI18nBlocks=useI18nBlocks;exports.useInlineEditing=useInlineEditing;exports.useIsPageLoaded=useIsPageLoaded;exports.useLanguages=useLanguages;exports.useLibraryBlocks=useLibraryBlocks;exports.useMediaManagerComponent=useMediaManagerComponent;exports.usePageExternalData=usePageExternalData;exports.usePartialBlocksList=usePartialBlocksList;exports.usePartialBlocksStore=usePartialBlocksStore;exports.usePasteBlocks=usePasteBlocks;exports.usePermissions=usePermissions;exports.usePreviewMode=usePreviewMode;exports.usePubSub=usePubSub;exports.useRemoveAllClassesForBlock=useRemoveAllClassesForBlock;exports.useRemoveBlocks=useRemoveBlocks;exports.useRemoveClassesFromBlocks=useRemoveClassesFromBlocks;exports.useReplaceBlock=useReplaceBlock;exports.useResetBlockStyles=useResetBlockStyles;exports.useRightPanel=useRightPanel;exports.useSavePage=useSavePage;exports.useScreenSizeWidth=useScreenSizeWidth;exports.useSelectedBlock=useSelectedBlock;exports.useSelectedBlockAllClasses=useSelectedBlockAllClasses;exports.useSelectedBlockCurrentClasses=useSelectedBlockCurrentClasses;exports.useSelectedBlockIds=useSelectedBlockIds;exports.useSelectedBlocksDisplayChild=useSelectedBlocksDisplayChild;exports.useSelectedBreakpoints=useSelectedBreakpoints;exports.useSelectedLibrary=useSelectedLibrary;exports.useSelectedStylingBlocks=useSelectedStylingBlocks;exports.useSidebarActivePanel=useSidebarActivePanel;exports.useStreamMultipleBlocksProps=useStreamMultipleBlocksProps;exports.useStylingBreakpoint=useStylingBreakpoint;exports.useStylingState=useStylingState;exports.useTheme=useTheme;exports.useThemeOptions=useThemeOptions;exports.useToggleChaiFeatureFlag=useToggleChaiFeatureFlag;exports.useUndoManager=useUndoManager;exports.useUpdateBlocksProps=useUpdateBlocksProps;exports.useUpdateBlocksPropsRealtime=useUpdateBlocksPropsRealtime;exports.useWrapperBlock=useWrapperBlock;