@egen-civitas/esm-app-shell 3.0.2 → 3.0.3

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.
@@ -17,4 +17,4 @@
17
17
  ${v}px !important;
18
18
  ${g}px !important;
19
19
  }
20
- `),()=>{s.current?.removeAttribute("data-motion-pop-id"),x.contains(b)&&x.removeChild(b)}},[t]),(0,v.jsx)(jS,{isPresent:t,childRef:s,sizeRef:l,pop:i,children:!1===i?e:g.cloneElement(e,{ref:c})})}let jO=({children:e,initial:t,isPresent:r,onExitComplete:n,custom:a,presenceAffectsLayout:i,mode:o,anchorX:s,anchorY:l,root:u})=>{let c=dS(jk),d=(0,g.useId)(),f=(0,g.useRef)(r),p=(0,g.useRef)(n);dR(()=>{f.current=r,p.current=n});let h=!0,m=(0,g.useMemo)(()=>(h=!1,{id:d,initial:t,isPresent:r,custom:a,onExitComplete:e=>{for(let t of(c.set(e,!0),c.values()))if(!t)return;n&&n()},register:e=>(c.set(e,!1),()=>{c.delete(e),f.current||c.size||p.current?.()})}),[r,c,n]);return i&&h&&(m={...m}),(0,g.useMemo)(()=>{c.forEach((e,t)=>c.set(t,!1))},[r]),g.useEffect(()=>{r||c.size||!n||n()},[r]),e=(0,v.jsx)(jj,{pop:"popLayout"===o,isPresent:r,anchorX:s,anchorY:l,root:u,children:e}),(0,v.jsx)(dw.Provider,{value:m,children:e})};function jk(){return new Map}let jE=e=>e.key||"";function jP(e){let t=[];return g.Children.forEach(e,e=>{(0,g.isValidElement)(e)&&t.push(e)}),t}let jA=({children:e,custom:t,initial:r=!0,onExitComplete:n,presenceAffectsLayout:a=!0,mode:i="sync",propagate:o=!1,anchorX:s="left",anchorY:l="top",root:u})=>{let[c,d]=pC(o),f=(0,g.useMemo)(()=>jP(e),[e]),p=o&&!c?[]:f.map(jE),h=(0,g.useRef)(!0),m=(0,g.useRef)(f),y=dS(()=>new Map),b=(0,g.useRef)(new Set),[x,w]=(0,g.useState)(f),[S,j]=(0,g.useState)(f);dR(()=>{h.current=!1,m.current=f;for(let e=0;e<S.length;e++){let t=jE(S[e]);p.includes(t)?(y.delete(t),b.current.delete(t)):!0!==y.get(t)&&y.set(t,!1)}},[S,p.length,p.join("-")]);let O=[];if(f!==x){let e=[...f];for(let t=0;t<S.length;t++){let r=S[t],n=jE(r);p.includes(n)||(e.splice(t,0,r),O.push(r))}return"wait"===i&&O.length&&(e=O),j(jP(e)),w(f),null}let{forceRender:k}=(0,g.useContext)(du);return(0,v.jsx)(v.Fragment,{children:S.map(e=>{let g=jE(e),x=(!o||!!c)&&(f===S||p.includes(g));return(0,v.jsx)(jO,{isPresent:x,initial:(!h.current||!!r)&&void 0,custom:t,presenceAffectsLayout:a,mode:i,root:u,onExitComplete:x?void 0:()=>{if(b.current.has(g)||!y.has(g))return;b.current.add(g),y.set(g,!0);let e=!0;y.forEach(t=>{t||(e=!1)}),e&&(k?.(),j(m.current),o&&d?.(),n&&n())},anchorX:s,anchorY:l,children:e},g)})})},jD={wrapper:"od7XT0veXj6mdEnncZFs+Q==",trigger:"_7A1e6-uGYRcfVQnfOx4geQ==",triggerIcon:"_8AaUzHzBvjhu4wIByBagPg==",triggerChevron:"NV6paA52ojWr+QJvS6VMUw==","triggerChevron--open":"tvyLx6UPztuSEo3wIE1oSQ==","triggerChevron--up":"SmGIbeFveBJB4FHlFhlbAA==",overlay:"_7fbyR1xFRRLItN8r0emD2w==",panel:"vzIn-j6yw5V0fmJWyVGXKg==",panelInner:"qTKkBfg7oksN9qrf7VLp1Q==",column:"C8xzSTaHxt8NM+8WglbIXQ==",columnSearch:"zHSJOF4qVG2jlPwAO+cLqQ==",columnSearchIcon:"_736VczNr3-sHL-FBa25KXw==",columnSearchInput:"_1VIyB+uqg5+6Y1G3Q+PnDw==",columnList:"wMozWE5hDKhxAGscGsLPSQ==",columnItem:"GJ+d+wAneJMJd8z-zKnedA==",columnItemIcon:"CDsY1qXafiUaITs4t-Xz8w==",columnItemLabel:"pQXzNkufWC-kTsP91lMc0g==",columnItemChevron:"VDhnJw1goYCbEvL0SzBpFA==",columnEmpty:"qDEruc7z1419lACB8Vawww=="};function jC(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var jT=function(e){var t,r=e.columnItems,n=e.columnIndex,a=e.activeItems,i=e.searchable,o=e.searchPlaceholder,s=e.onHover,l=e.onNavigate,u=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(""))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return jC(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return jC(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),c=u[0],d=u[1],f=(0,g.useMemo)(function(){if(!c.trim())return r;var e=c.trim().toLowerCase();return r.filter(function(t){return t.label.toLowerCase().includes(e)})},[r,c]);return(0,v.jsxs)(hz.div,{className:jD.column,initial:{opacity:0,width:0},animate:{opacity:1,width:"var(--cnd-column-width)"},exit:{opacity:0,width:0},transition:{duration:.2,ease:"easeOut"},children:[i&&(0,v.jsxs)("div",{className:jD.columnSearch,children:[(0,v.jsx)(o1,{className:jD.columnSearchIcon,size:14}),(0,v.jsx)("input",{type:"search",value:c,onChange:function(e){return d(e.target.value)},placeholder:o,className:jD.columnSearchInput,"aria-label":o})]}),(0,v.jsxs)("ul",{className:jD.columnList,role:"list",children:[f.map(function(e){var t,r=a[n]===e.id,i=!!(null==(t=e.children)?void 0:t.length),o=e.icon;return(0,v.jsx)("li",{children:(0,v.jsxs)("button",{type:"button",className:jD.columnItem,"data-active":r||void 0,onMouseEnter:function(){return s(e,n)},onFocus:function(){return s(e,n)},onClick:function(){!i&&e.path&&l(e.path)},children:[o&&(0,v.jsx)(o,{className:jD.columnItemIcon,size:16}),(0,v.jsx)("span",{className:jD.columnItemLabel,children:e.label}),i&&(0,v.jsx)(ow,{className:jD.columnItemChevron,size:14})]})},e.id)}),0===f.length&&(0,v.jsx)("li",{className:jD.columnEmpty,children:"—"})]})]})};function jN(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function jR(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function jM(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||j_(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function jI(e){return function(e){if(Array.isArray(e))return jN(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||j_(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function j_(e,t){if(e){if("string"==typeof e)return jN(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return jN(e,t)}}var jL=function(e){var t,r,n=e.items,a=e.triggerLabel,i=e.triggerIcon,o=e.direction,s=void 0===o?"down":o,l=e.searchable,u=void 0!==l&&l,c=e.searchPlaceholder,d=void 0===c?"Rechercher…":c,f=e.onNavigate,p=e.className,h=jM((0,g.useState)(!1),2),m=h[0],y=h[1],b=jM((0,g.useState)([n]),2),x=b[0],w=b[1],S=jM((0,g.useState)([]),2),j=S[0],k=S[1],E=jM((0,g.useState)(null),2),P=E[0],A=E[1],D=(0,g.useRef)(null);(0,g.useLayoutEffect)(function(){m||(w([n]),k([]))},[n,m]),(0,g.useLayoutEffect)(function(){if(m&&D.current){var e=D.current.getBoundingClientRect();A("up"===s?{left:e.left,bottom:window.innerHeight-e.top+8}:{left:e.left,top:e.bottom+8})}},[m,s]);var C=function(e,t){var r,n=jI(j);n[t]=e.id,(null==(r=e.children)?void 0:r.length)?w(jI(x.slice(0,t+1)).concat([e.children])):w(x.slice(0,t+1)),k(n)},T=function(e){y(!1),null==f||f(e)};return(0,v.jsxs)("div",{className:O()(jD.wrapper,p),children:[(0,v.jsxs)("button",{ref:D,type:"button",className:jD.trigger,onClick:function(){return y(function(e){return!e})},"aria-haspopup":"true","aria-expanded":m,children:[i&&(0,v.jsx)(i,{className:jD.triggerIcon,size:16}),(0,v.jsx)("span",{children:void 0===a?"Navigation":a}),(0,v.jsx)(ob,{className:O()(jD.triggerChevron,(jR(t={},jD["triggerChevron--open"],m),jR(t,jD["triggerChevron--up"],"up"===s),t)),size:14})]}),(0,v.jsx)(jA,{children:m&&P&&(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("div",{className:jD.overlay,onClick:function(){return y(!1)},"aria-hidden":"true"}),(0,v.jsx)(hz.div,{className:O()(jD.panel,jD["panel--".concat(s)]),style:(jR(r={left:P.left,top:P.top,bottom:P.bottom},"--cnd-panel-width","".concat(16*x.length,"rem")),jR(r,"--cnd-column-width","16rem"),r),initial:{opacity:0,y:"up"===s?10:-10,scale:.96},animate:{opacity:1,y:0,scale:1,width:"var(--cnd-panel-width)",transition:{opacity:{duration:.18},y:{duration:.28,type:"spring",stiffness:200,damping:20},scale:{duration:.18},width:{duration:.28,ease:"easeOut"}}},exit:{opacity:0,y:"up"===s?10:-10,scale:.96,transition:{duration:.18}},children:(0,v.jsx)("div",{className:jD.panelInner,children:(0,v.jsx)(jA,{mode:"sync",children:x.map(function(e,t){return(0,v.jsx)(jT,{columnItems:e,columnIndex:t,activeItems:j,searchable:u,searchPlaceholder:d,onHover:C,onNavigate:T},t)})})})})]})})]})},jF=(0,g.createContext)(null),jB=function(){var e=(0,g.useContext)(jF);if(!e)throw Error("Sheet compound components must be used within <Sheet>");return e};function jV(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var jz=function(e){var t,r=e.children,n=e.open,a=e.onOpenChange,i=e.defaultOpen,o=e.className,s=e.side,l=e.height,u=e.closeThreshold,c=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(null!=i&&i))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return jV(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return jV(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),d=c[0],f=c[1],p=void 0!==n,h=p?n:d,m=(0,g.useCallback)(function(e){null==a||a(e),p||f(e)},[a,p]);return(0,v.jsx)(jF.Provider,{value:{isOpen:h,onOpenChange:m,contentProps:{height:void 0===l?"55vh":l,className:void 0===o?"":o,closeThreshold:void 0===u?.3:u,side:void 0===s?"top":s}},children:r})};function jW(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var j$=function(e){var t,r=e.children,n=e.container,a=e.className,i=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return jW(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return jW(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),o=i[0],s=i[1];if((0,g.useEffect)(function(){s(!0)},[]),!o||"u"<typeof document)return null;var l=a?(0,v.jsx)("div",{className:a,children:r}):r;return(0,tZ.createPortal)(l,n||document.body)};let jU={triggerReset:"KchWk07qCyMztdOj8l6+nw==",container:"MW2IV8rXbcfJn9D6esV+-A==","container--closed":"ukmg3qKuvTIZgVpyD7X8AQ==",overlay:"zaRVZ17z7O8LzefxS5CxNw==",panel:"T5s7RxBCifLQWFgh1vOLDg==","panel--top":"PyeTpmsjKygAk2pCpe5NKQ==","panel--bottom":"+wv3nJKxJJhuz8K5j3YX7g==",body:"ePmeaHdSa+qf+ohZ4e4cpA==",scrollArea:"xSSRA7R71d88sDke9IOYhg==",handleRow:"IULYFP6QnLBTysbet5YXPQ==",handle:"_4QMSFXLduOJ5ZpOTm7K5ZQ==",header:"D7sRu9+Zla6rj0BHmTJqrQ==",title:"VNak3xly+5sZFSRmGcPHWQ==",description:"YFLey8nNGCmuU6P8ZlzzmA==",footer:"qeJpmxe-jqBAtL5CXcn3yg=="};function jH(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function jG(e){if(Array.isArray(e))return e}function jK(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function jq(e,t){if(e){if("string"==typeof e)return jH(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return jH(e,t)}}var jY=(0,g.forwardRef)(function(e,t){var r,n=jG(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||jq(r)||jK(),a=n[0],i=n.slice(1),o=a.className,s=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(a,["className"]),l=(jG(i)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),1!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(i)||jq(i,1)||jK())[0],u=jB(),c=u.isOpen,d=u.onOpenChange,f=(0,g.useCallback)(function(e){e.target===e.currentTarget&&d(!1)},[d]);return(0,v.jsx)(hz.div,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({ref:l,initial:{opacity:0},animate:{opacity:+!!c},transition:{duration:.2,ease:"easeOut"},onClick:f,className:O()(jU.overlay,o),style:{pointerEvents:c?"auto":"none"}},s))});function jX(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function jZ(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}jY.displayName="SheetOverlay";var jQ=function(e){var t=e.asChild,r=e.children,n=e.className,a=jB().onOpenChange,i=function(){return a(!0)};return t&&b().isValidElement(r)?b().cloneElement(r,jZ(jX({},r.props),{className:O()(r.props.className,n),onClick:function(e){var t,n;null==(t=(n=r.props).onClick)||t.call(n,e),i()}})):(0,v.jsx)("button",{onClick:i,type:"button",className:O()(jU.triggerReset,n),children:r})},jJ=function(e){var t=e.asChild,r=e.children,n=e.className,a=jB().onOpenChange,i=function(){return a(!1)};return t&&b().isValidElement(r)?b().cloneElement(r,jZ(jX({},r.props),{className:O()(r.props.className,n),onClick:function(e){var t,n;null==(t=(n=r.props).onClick)||t.call(n,e),i()}})):(0,v.jsx)("button",{onClick:i,type:"button",className:O()(jU.triggerReset,n),children:r})};function j0(e,t){[...t].reverse().forEach(r=>{let n=e.getVariant(r);n&&dV(e,n),e.variantChildren&&e.variantChildren.forEach(e=>{j0(e,t)})})}function j1(){let e=!1,t=new Set,r={subscribe:e=>(t.add(e),()=>void t.delete(e)),start(r,n){up(e,"controls.start() should only be called after a component has mounted. Consider calling within a useEffect hook.");let a=[];return t.forEach(e=>{a.push(f$(e,r,{transitionOverride:n}))}),Promise.all(a)},set:r=>(up(e,"controls.set() should only be called after a component has mounted. Consider calling within a useEffect hook."),t.forEach(e=>{var t,n;t=e,Array.isArray(n=r)?j0(t,n):"string"==typeof n?j0(t,[n]):dV(t,n)})),stop(){t.forEach(e=>{e.values.forEach(e=>e.stop())})},mount:()=>(e=!0,()=>{e=!1,r.stop()})};return r}let j2=function(){let e=dS(j1);return dR(e.mount,[]),e};function j3(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var j4=function(e){var t,r=e.children,n=e.className,a=jB(),i=a.isOpen,o=a.onOpenChange,s=a.contentProps,l=s.height,u=s.closeThreshold,c=s.side,d=j2(),f=(0,g.useRef)(null),p=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(0))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return j3(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return j3(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),h=p[0],m=p[1],y="top"===c?-1:1,b=(0,g.useCallback)(function(){return o(!1)},[o]),x=(0,g.useCallback)(function(){if("u"<typeof window)return 400;var e,t=window.innerHeight,r=window.innerWidth;return e=r<=640?.6*t:r<=1024?.55*t:.5*t,l.includes("vh")?e=parseInt(l,10)/100*t:l.includes("px")&&(e=parseInt(l,10)),Math.min(e,.8*t)},[l]);(0,g.useEffect)(function(){var e=function(){return m(x())};return e(),window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}},[x]),(0,g.useEffect)(function(){return i?(document.body.style.overflow="hidden",d.start({y:0,transition:{type:"spring",stiffness:400,damping:40,mass:.8}})):(document.body.style.overflow="",d.start({y:y*(h+50),transition:{type:"tween",ease:[.25,.46,.45,.94],duration:.3}})),function(){document.body.style.overflow=""}},[i,d,h,y]),(0,g.useEffect)(function(){var e=function(e){"Escape"===e.key&&i&&b()};return i&&document.addEventListener("keydown",e),function(){return document.removeEventListener("keydown",e)}},[i,b]);var w=(0,g.useCallback)(function(e,t){var r=y*t.offset.y>h*u,n=y*t.velocity.y>800;r||n?b():d.start({y:0,transition:{type:"spring",stiffness:500,damping:40}})},[d,b,u,h,y]),S=(0,g.useCallback)(function(e){e.target===f.current&&b()},[b]);if(0===h)return null;var j="top"===c?{top:-h,bottom:0}:{top:0,bottom:h};return(0,v.jsx)(j$,{children:(0,v.jsxs)("div",{className:O()(jU.container,!i&&jU["container--closed"]),children:[(0,v.jsx)(hz.div,{ref:f,initial:{opacity:0},animate:{opacity:+!!i},transition:{duration:.2,ease:"easeOut"},onClick:S,className:jU.overlay,style:{pointerEvents:i?"auto":"none"}}),(0,v.jsxs)(hz.div,{drag:"y",dragConstraints:j,dragElastic:"top"===c?{top:.1,bottom:0}:{top:0,bottom:.1},dragMomentum:!1,onDragEnd:w,animate:d,initial:{y:y*(h+50)},className:O()(jU.panel,jU["panel--".concat(c)],void 0===n?"":n),style:{height:h},children:["bottom"===c&&(0,v.jsx)("div",{className:jU.handleRow,children:(0,v.jsx)("div",{className:jU.handle})}),(0,v.jsx)("div",{className:jU.body,children:(0,v.jsx)("div",{className:jU.scrollArea,children:r})}),"top"===c&&(0,v.jsx)("div",{className:jU.handleRow,children:(0,v.jsx)("div",{className:jU.handle})})]})]})})},j5=function(e){var t=e.children,r=e.className;return(0,v.jsx)("div",{className:O()(jU.header,r),children:t})},j6=function(e){var t=e.children,r=e.className;return(0,v.jsx)("h3",{className:O()(jU.title,r),children:t})},j8=function(e){var t=e.children,r=e.className;return(0,v.jsx)("p",{className:O()(jU.description,r),children:t})},j9=function(e){var t=e.children,r=e.className;return(0,v.jsx)("div",{className:O()(jU.footer,r),children:t})},j7=jz;function Oe(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ot(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Or(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Oe(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Oe(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var On=function(e){var t=e.items,r=e.title,n=e.hint,a=void 0===n?"Glisser une carte vers le bas pour fermer":n,i=e.open,o=e.defaultOpen,s=e.onOpenChange,l=e.className,u=e.style,c=e.itemWidth,d=void 0===c?"14rem":c,f=e.itemHeight,p=void 0===f?"18rem":f,h=e.accentColor,m=Or((0,g.useState)(void 0!==o&&o),2),y=m[0],b=m[1],x=Or((0,g.useState)(!1),2),w=x[0],S=x[1],j=void 0!==i,k=j?i:y,E=function(e){null==s||s(e),j||b(e)},P=function(e,t){t.offset.y>100&&k&&(E(!1),S(!1))},A=(t.length-1)/2,D=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){Ot(e,t,r[t])})}return e}({},h?Ot({},"--fg-accent",h):void 0,u);return(0,v.jsx)("div",{className:O()("qUNaF87CyIQP-ewg0aT3gA==",l),style:D,children:(0,v.jsxs)("div",{className:"M-aEx-DAQtTyHwhMH64yGQ==",children:[(0,v.jsxs)("div",{className:"vxflXdvIBCrWhSbimzCWVQ==",children:[(0,v.jsxs)(hz.div,{className:"_6KkQsq8ts3ToOwYYDhfiMg==",animate:{opacity:+!k,scale:k?.9:1},children:[(0,v.jsx)("div",{className:"JmUVXLvcsCJoSXOSTZPN0A=="}),(0,v.jsx)("div",{className:"kOJbodcwrAswUmyC3DBjYA=="}),(0,v.jsx)("div",{className:"IL7xokwIcPXhZTStqhO09Q=="})]}),(0,v.jsx)("div",{className:"BkkLFMz1ckgbUpHR7DMWdA==",children:t.map(function(e,t){var r=t-A,n=1-.03*Math.abs(r);return(0,v.jsx)(hz.div,{drag:k,dragSnapToOrigin:!0,onDragEnd:P,className:O()("M84i--+bZPAx6uTscNbshA==",Ot({},"_3Zkd8QL+ngGj6mOBrfZEVQ==",k)),style:{width:d,height:p},animate:k?{y:-130,x:130*r,rotate:0,scale:1.05,zIndex:50}:{y:w?-10*r-40:-5*r,x:w?30*r:3*r,rotate:w?8*r:3*r,scale:n,zIndex:t+10},whileHover:k?{scale:1.1,zIndex:100}:void 0,whileDrag:k?{scale:1.05+.1,rotate:5,zIndex:150}:void 0,transition:{type:"spring",stiffness:350,damping:30},children:e.content},e.id)})}),(0,v.jsx)(hz.div,{className:"KBOODSF6+mKrIZESAVYrHg==",animate:{opacity:+!k,rotateX:w?-25:0,y:10*!!w,pointerEvents:k?"none":"auto"},onMouseEnter:function(){return S(!0)},onMouseLeave:function(){return S(!1)},onClick:function(){return E(!0)},children:(0,v.jsxs)("div",{className:"jw8fEvLvOius9zY16PK1hw==",children:[(0,v.jsx)("div",{className:"_9rOs7yRUMhW4QkMdrFqD0g=="}),(0,v.jsx)("div",{className:"_5i0EfM-8AE4OYYo2X2uwPA==",children:(0,v.jsx)("span",{className:"ZKSbpqexNyEpFvhZmwoLlQ==",children:void 0===r?"Dossier":r})})]})})]}),a&&(0,v.jsx)(hz.div,{animate:{opacity:+!!k,y:50*!k},className:"MzfhFqg3a0YwUbs3yGfdSQ==",children:a})]})})};function Oa(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Oi(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Oo(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Oa(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Oa(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Os(e){var t=e.items,r=e.className,n=e.style,a=Oo((0,g.useState)(null),2),i=a[0],o=a[1],s=Oo((0,g.useState)(null),2),l=s[0],u=s[1],c=function(e){u(i),o(e)},d=function(){u(i),o(null)};return(0,g.useEffect)(function(){if(i){var e=function(e){"Escape"===e.key&&d()};return window.addEventListener("keydown",e),function(){return window.removeEventListener("keydown",e)}}},[i]),(0,v.jsxs)("div",{className:O()("eA4BZJ4wlOaTHsiyz+antA==",r),style:n,children:[t.map(function(e){var t,r=(null==i?void 0:i.id)===e.id,n=!r&&(null==l?void 0:l.id)===e.id;return(0,v.jsx)("div",{className:e.className,children:(0,v.jsxs)(hz.div,{role:"button",tabIndex:0,"aria-pressed":r,onClick:function(){return c(e)},onKeyDown:function(t){("Enter"===t.key||" "===t.key)&&(t.preventDefault(),c(e))},className:O()(e.className,"cGA76nZGe5CnhWCCmTVGgQ==",(Oi(t={},"kptslMbsy8+vxJd8WIJrcg==",r),Oi(t,"NX+iOobXbUb-lQbAFNkL9Q==",!r),Oi(t,"gvMWGRV+aGwP5KrSi0geAQ==",n),t)),layoutId:"layout-grid-card-".concat(e.id),children:[r&&(0,v.jsx)(Ou,{item:i}),(0,v.jsx)(Ol,{item:e})]})},e.id)}),(0,v.jsx)(hz.div,{onClick:d,className:O()("V6jx9Z+WVL9MDdGPvJkaYA==",Oi({},"LbohBri+vFNoSWrMQc-qGQ==",!!(null==i?void 0:i.id))),animate:{opacity:+(null!=i&&!!i.id)},"aria-hidden":"true"})]})}function Ol(e){var t=e.item;return(0,v.jsx)(hz.img,{layoutId:"layout-grid-image-".concat(t.id),src:t.thumbnail,height:500,width:500,className:"U5gcULxDx+o6CMn4mOO-KA==",alt:"thumbnail"})}function Ou(e){var t=e.item;return(0,v.jsxs)("div",{className:"_0xZoWQ+67f8d9Ibrj2XGsA==",children:[(0,v.jsx)(hz.div,{initial:{opacity:0},animate:{opacity:.6},className:"_2uAL2ek35ay46kkDXaGh0g=="}),(0,v.jsx)(hz.div,{layoutId:"layout-grid-content-".concat(null==t?void 0:t.id),initial:{opacity:0,y:100},animate:{opacity:1,y:0},exit:{opacity:0,y:100},transition:{duration:.3,ease:"easeInOut"},className:"wsyzOu+s8n1iJlwVW0VMfA==",children:null==t?void 0:t.content})]})}let Oc="n6G8E1SbEEUsI3OWq+fUJw==",Od="A6XS7R+rH6Du2oTHAV9w1Q==",Of="QOgWcRICSDEnRCObIKMk1w==",Op="x1LP9u0NvE8GsXncVS6mxw==",Oh="Z2SR8P5h1ozswEBKF7Sb8Q==",Om="yTTHKbpGK3OMci1Nvf0BUQ==",Oy="p02avqg7uiwLf9Az9XbgGQ==",Ov="_9qLPpBBum4PfGB1uo7FCCQ==",Og="Zu4+XDmJUwKPLUmX+qsvAw==",Ob="i+x5CkYTvPGY-ug4QQFcdA==",Ox="AVPYYK3-6yQVldiVTCgQOQ==";var Ow=function(){return(0,v.jsx)("div",{className:"nhWkRlOlypB5yuvCy8EzwA==","aria-hidden":"true",children:Array.from({length:8},function(e,t){return(0,v.jsx)("div",{className:"wy+8JDS8iByYKvw08QdPOA=="},t)})})};function OS(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Oj(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function OO(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return OS(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return OS(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Ok=function(e){var t=e.title,r=e.coverImageUrl,n=e.category,a=e.itemCountLabel,i=e.meta,o=e.items,s=e.relatedEntity,l=e.onItemOptionsClick,u=e.className,c=e.style,d=OO((0,g.useState)(!1),2),f=d[0],p=d[1],h=OO((0,g.useState)(null),2),m=h[0],y=h[1],b=OO((0,g.useState)(null),2),x=b[0],w=b[1],S=OO((0,g.useState)(0),2),j=S[0],k=S[1],E=OO((0,g.useState)("translateY(0px)"),2),P=E[0],A=E[1],D=(0,g.useRef)(null),C=(0,g.useRef)(new Map),T=null!==m,N=f||T;(0,g.useEffect)(function(){if(null!==m){var e=function(){var e=C.current.get(m);e&&D.current&&k(e.getBoundingClientRect().top-D.current.offsetTop-2)};return e(),window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}}},[m]);var R=function(e){if(e.detail){var t=C.current.get(e.id);if(t&&D.current){var r=window.innerHeight-t.getBoundingClientRect().bottom+D.current.offsetTop-390;A("translateY(".concat(r,"px)"))}y(e.id),w(e)}};return(0,v.jsx)("div",{className:O()("xDbMR0gHWNpFj1Yoy68ZGA==",u),style:c,children:(0,v.jsx)("div",{className:"HavojgA3auWWriIv10hJ2w==",children:(0,v.jsxs)("div",{ref:D,className:O()("kmTNzVGOWEu5+aYeO+dJWg==",Oj({},"_8KuCFVRGG3hewrJk8eI8Ww==",N)),children:[(0,v.jsxs)("div",{className:"CJOSG6kKQMw-ivRwEJKw2g==",children:[(0,v.jsxs)("div",{className:Oc,children:[(0,v.jsx)("img",{className:Od,src:r,alt:""}),(0,v.jsx)("img",{className:O()(Od,Of),src:r,alt:"","aria-hidden":"true"})]}),(0,v.jsxs)("div",{className:"CULGeLqVu22C6sNwl7MlvA==",children:[(0,v.jsxs)("div",{className:"+F4KQqfbTnxcK27YlTU8Pw==",children:[(0,v.jsx)("h1",{className:Op,children:t}),(0,v.jsxs)("div",{className:"RzWO2Tf5Wsgu3xcy+EZH6w==",children:[n&&(0,v.jsx)("p",{className:Oh,children:n}),n&&a&&(0,v.jsx)("div",{className:Oy}),a&&(0,v.jsx)("p",{className:Oh,children:a}),a&&i&&(0,v.jsx)("div",{className:Oy}),i&&(0,v.jsx)("p",{className:Oh,children:i})]})]}),(0,v.jsx)("div",{className:"gVkvp0xTMjRND78EK-fmTg==",children:o.map(function(e){var t;return(0,v.jsxs)("div",{ref:(t=e.id,function(e){e?C.current.set(t,e):C.current.delete(t)}),className:Ov,onClick:function(){return R(e)},children:[(0,v.jsx)("p",{className:Om,children:e.title}),(0,v.jsxs)("div",{className:Og,children:[(0,v.jsx)("button",{type:"button",className:Ob,onClick:function(t){t.stopPropagation(),null==l||l(e)},"aria-label":"Options",children:(0,v.jsx)(oU,{size:20})}),e.meta&&(0,v.jsx)("p",{className:Oh,children:e.meta})]})]},e.id)})})]})]}),x&&(0,v.jsxs)("div",{className:O()("kR1yWXyQMcy-pc19Y1uCSg==",Oj({},"vGP3YGBeJwp273dxvca0mQ==",T)),style:{top:"".concat(j,"px"),transform:P},children:[(0,v.jsxs)("div",{className:Ov,children:[(0,v.jsx)("p",{className:Om,children:x.title}),(0,v.jsxs)("div",{className:Og,children:[(0,v.jsx)("button",{type:"button",className:Ob,onClick:function(){A("translateY(0px)"),y(null)},"aria-label":"Fermer",children:(0,v.jsx)(oa,{size:20,className:Ox})}),x.meta&&(0,v.jsx)("p",{className:Oh,children:x.meta})]})]}),(0,v.jsxs)("div",{className:"e6e-vgnHyLmMi5IFc63TGQ==",children:[x.credits&&(0,v.jsx)("div",{className:"CYjBwulWUDNbXjPGa+ouVw==",children:x.credits}),x.detail]}),(0,v.jsx)(Ow,{})]}),s&&(0,v.jsxs)("div",{className:"v-ulCXKHBflMTQlBMUxvMg==",style:{display:f?"flex":T?"none":void 0},children:[(0,v.jsx)("button",{type:"button",className:"_5npqIb7V1BrT1vIyp9ipBQ==",onClick:function(){return p(function(e){return!e})},"aria-label":f?"Fermer":"Voir les d\xe9tails",children:(0,v.jsx)(oa,{size:24,className:O()(Oj({},Ox,f))})}),(0,v.jsxs)("div",{className:"s8sEwmEJjuL2Pbcv4ehUYg==",children:[(0,v.jsxs)("div",{className:Oc,children:[(0,v.jsx)("h1",{className:Op,children:s.name}),(0,v.jsx)("img",{className:Od,src:s.photoUrl,alt:""}),(0,v.jsx)("img",{className:O()(Od,Of),src:s.photoUrl,alt:"","aria-hidden":"true"})]}),(0,v.jsxs)("div",{className:"oxZqOgOCkDHiFck7NvKY1g==",children:[(0,v.jsxs)("div",{className:"hi7d14X0gK3yPHbnYDMz7g==",children:[(0,v.jsxs)("div",{className:"ABgmK32LF+ngIsTFH+yrdw==",children:[s.category&&(0,v.jsx)("p",{className:O()(Oh,"DSINo9JINz-VX0HYc7rrNg=="),children:s.category}),s.category&&s.itemCountLabel&&(0,v.jsx)("div",{className:Oy}),s.itemCountLabel&&(0,v.jsx)("p",{className:Oh,children:s.itemCountLabel})]}),s.statLabel&&(0,v.jsx)("p",{className:Oh,children:s.statLabel})]}),s.description&&(0,v.jsx)("p",{className:Om,children:s.description})]})]}),(0,v.jsx)(Ow,{}),(0,v.jsx)("div",{className:"p4U4LPnGs8pTf99LZiEFEg=="})]})]})})})};function OE(e){var t=e.moduleName,r=e.meta;return r.titleKey?(0,V.t)(t,r.titleKey,r.title):r.title}function OP(e,t){var r=(0,x.useAssignedExtensions)(h1.As[e]),n=jl();return(0,g.useMemo)(function(){return r.map(function(e,t){return{extension:e,index:t}}).filter(function(e){var t=e.extension;return(0,h1.oW)(t.meta)}).filter(function(r){var n,a=r.extension;return!t||"bottom"!==e||(null!=(n=a.meta.rail)?n:"left")===t}).filter(function(t){var r=t.extension;return"right"===e||!0===r.meta.global||n.has(r.moduleName)}).sort(function(e,t){var r,n;return(null!=(r=e.extension.meta.order)?r:e.index)-(null!=(n=t.extension.meta.order)?n:t.index)||e.index-t.index}).map(function(t){var r=t.extension;return{id:r.name,moduleName:r.moduleName,meta:r.meta,compartment:"bottom"===e?null:(0,h1.lN)(r.meta)}})},[r,n,e,t])}var OA=(0,ya.A)("BookOpen",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]]),OD=(0,ya.A)("Bell",[["path",{d:"M10.268 21a2 2 0 0 0 3.464 0",key:"vwvbt9"}],["path",{d:"M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326",key:"11g9vi"}]]),OC=(0,ya.A)("Bot",[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]]),OT=(0,ya.A)("Building2",[["path",{d:"M6 22V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v18Z",key:"1b4qmf"}],["path",{d:"M6 12H4a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2",key:"i71pzd"}],["path",{d:"M18 9h2a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-2",key:"10jefs"}],["path",{d:"M10 6h4",key:"1itunk"}],["path",{d:"M10 10h4",key:"tcdvrf"}],["path",{d:"M10 14h4",key:"kelpxr"}],["path",{d:"M10 18h4",key:"1ulq68"}]]),ON=(0,ya.A)("CalendarDays",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}],["path",{d:"M8 14h.01",key:"6423bh"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M16 14h.01",key:"1gbofw"}],["path",{d:"M8 18h.01",key:"lrp35t"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M16 18h.01",key:"kzsmim"}]]),OR=(0,ya.A)("CircleHelp",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),OM=(0,ya.A)("Folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]),OI=(0,ya.A)("FolderTree",[["path",{d:"M20 10a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1h-2.5a1 1 0 0 1-.8-.4l-.9-1.2A1 1 0 0 0 15 3h-2a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z",key:"hod4my"}],["path",{d:"M20 21a1 1 0 0 0 1-1v-3a1 1 0 0 0-1-1h-2.9a1 1 0 0 1-.88-.55l-.42-.85a1 1 0 0 0-.92-.6H13a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z",key:"w4yl2u"}],["path",{d:"M3 5a2 2 0 0 0 2 2h3",key:"f2jnh7"}],["path",{d:"M3 3v13a2 2 0 0 0 2 2h3",key:"k8epm1"}]]),O_=(0,ya.A)("House",[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-5.999a2 2 0 0 1 2.582 0l7 5.999A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"1d0kgt"}]]),OL=r(8032),OF=(0,ya.A)("LayoutGrid",[["rect",{width:"7",height:"7",x:"3",y:"3",rx:"1",key:"1g98yp"}],["rect",{width:"7",height:"7",x:"14",y:"3",rx:"1",key:"6d4xhi"}],["rect",{width:"7",height:"7",x:"14",y:"14",rx:"1",key:"nxv5o0"}],["rect",{width:"7",height:"7",x:"3",y:"14",rx:"1",key:"1bb6yr"}]]),OB=(0,ya.A)("ListTree",[["path",{d:"M21 12h-8",key:"1bmf0i"}],["path",{d:"M21 6H8",key:"1pqkrb"}],["path",{d:"M21 18h-8",key:"1tm79t"}],["path",{d:"M3 6v4c0 1.1.9 2 2 2h3",key:"1ywdgy"}],["path",{d:"M3 10v6c0 1.1.9 2 2 2h3",key:"2wc746"}]]),OV=(0,ya.A)("MapPin",[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]),Oz=(0,ya.A)("Megaphone",[["path",{d:"m3 11 18-5v12L3 14v-3z",key:"n962bs"}],["path",{d:"M11.6 16.8a3 3 0 1 1-5.8-1.6",key:"1yl0tm"}]]),OW=(0,ya.A)("Newspaper",[["path",{d:"M4 22h16a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2H8a2 2 0 0 0-2 2v16a2 2 0 0 1-2 2Zm0 0a2 2 0 0 1-2-2v-9c0-1.1.9-2 2-2h2",key:"7pis2x"}],["path",{d:"M18 14h-8",key:"sponae"}],["path",{d:"M15 18h-5",key:"95g1m2"}],["path",{d:"M10 6h8v4h-8V6Z",key:"smlsk5"}]]),O$=(0,ya.A)("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]),OU=(0,ya.A)("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]),OH=(0,ya.A)("Terminal",[["polyline",{points:"4 17 10 11 4 5",key:"akl6gq"}],["line",{x1:"12",x2:"20",y1:"19",y2:"19",key:"q2wloq"}]]),OG=(0,ya.A)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]),OK=(0,ya.A)("Calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]]),Oq=(0,ya.A)("CalendarCheck",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}],["path",{d:"m9 16 2 2 4-4",key:"19s6y9"}]]),OY=(0,ya.A)("Compass",[["path",{d:"m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z",key:"9ktpf1"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]),OX=(0,ya.A)("Contact",[["path",{d:"M16 2v2",key:"scm5qe"}],["path",{d:"M7 22v-2a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v2",key:"1waht3"}],["path",{d:"M8 2v2",key:"pbkmx"}],["circle",{cx:"12",cy:"11",r:"3",key:"itu57m"}],["rect",{x:"3",y:"4",width:"18",height:"18",rx:"2",key:"12vinp"}]]),OZ=(0,ya.A)("FileCheck",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"m9 15 2 2 4-4",key:"1grp1n"}]]),OQ=(0,ya.A)("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]),OJ=(0,ya.A)("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]),O0=(0,ya.A)("Layers",[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]]),O1=(0,ya.A)("Radio",[["path",{d:"M4.9 19.1C1 15.2 1 8.8 4.9 4.9",key:"1vaf9d"}],["path",{d:"M7.8 16.2c-2.3-2.3-2.3-6.1 0-8.5",key:"u1ii0m"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["path",{d:"M16.2 7.8c2.3 2.3 2.3 6.1 0 8.5",key:"1j5fej"}],["path",{d:"M19.1 4.9C23 8.8 23 15.1 19.1 19",key:"10b0cb"}]]),O2=(0,ya.A)("Star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]),O3=(0,ya.A)("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]),O4={BookOpen:OA,Bell:OD,Bot:OC,Building2:OT,CalendarDays:ON,CircleHelp:OR,Folder:OM,FolderTree:OI,House:O_,Info:OL.A,LayoutGrid:OF,ListTree:OB,MapPin:OV,Megaphone:Oz,Newspaper:OW,Search:O$,Settings:OU,Terminal:OH,Users:OG,Calendar:OK,CalendarCheck:Oq,Compass:OY,Contact:OX,FileCheck:OZ,FileText:OQ,Globe:OJ,Layers:O0,Radio:O1,Star:O2,Zap:O3};function O5(e){return e?O4[e]:void 0}function O6(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function O8(e){return function(e){if(Array.isArray(e))return O6(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e){if(e){if("string"==typeof e)return O6(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return O6(e,void 0)}}(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var O9="__default__",O7={height:60,minHeight:25,maxHeight:100},ke=function(e){return Math.round(100*e)/100};function kt(e){var t=e.reduce(function(e,t){return e+t.minHeight},0),r=e.reduce(function(e,t){return e+t.maxHeight},0),n=t>100?100/t:1;return{mins:e.map(function(e){return e.minHeight*n}),maxs:e.map(function(e){return r<100?100:Math.max(e.maxHeight,e.minHeight*n)})}}function kr(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(0===e.length)return[];if(1===e.length)return[100];var n=kt(e),a=n.mins,i=n.maxs,o=e.map(function(e){var t=r[e.key];return"number"==typeof t&&Number.isFinite(t)&&t>0}),s=e.reduce(function(e,t,r){return e+(o[r]?0:t.height)},0),l=e.reduce(function(e,t,n){return e+(o[n]?r[t.key]:0)},0),u=100-s;if(l>0&&u>0)t=e.map(function(e,t){return o[t]?r[e.key]*u/l:e.height});else{var c=e.map(function(e,t){return o[t]?r[e.key]:e.height}),d=c.reduce(function(e,t){return e+t},0);t=c.map(function(e){return 100*e/d})}for(var f=e.map(function(){}),p=0;p<=e.length&&"break"!==function(){var r=f.reduce(function(e,t){return e+(null!=t?t:0)},0),n=e.map(function(e,t){return t}).filter(function(e){return void 0===f[e]});if(0===n.length)return"break";var o=n.reduce(function(e,r){return e+t[r]},0),s=o>0?(100-r)/o:0,l=new Map(n.map(function(e){return[e,o>0?t[e]*s:(100-r)/n.length]})),u=0,c=!0,d=!1,p=void 0;try{for(var h,m=n[Symbol.iterator]();!(c=(h=m.next()).done);c=!0){var y=h.value,v=l.get(y);u+=Math.min(i[y],Math.max(a[y],v))-v}}catch(e){d=!0,p=e}finally{try{c||null==m.return||m.return()}finally{if(d)throw p}}var g=n.filter(function(e){return l.get(e)<a[e]-1e-6}),b=n.filter(function(e){return l.get(e)>i[e]+1e-6});if(0===g.length&&0===b.length){var x=!0,w=!1,S=void 0;try{for(var j,O=n[Symbol.iterator]();!(x=(j=O.next()).done);x=!0){var k=j.value;f[k]=l.get(k)}}catch(e){w=!0,S=e}finally{try{x||null==O.return||O.return()}finally{if(w)throw S}}return"break"}var E=u>1e-6?g:u<-1e-6?b:O8(g).concat(O8(b)),P=!0,A=!1,D=void 0;try{for(var C,T=(E.length>0?E:O8(g).concat(O8(b)))[Symbol.iterator]();!(P=(C=T.next()).done);P=!0){var N=C.value;f[N]=Math.min(i[N],Math.max(a[N],l.get(N)))}}catch(e){A=!0,D=e}finally{try{P||null==T.return||T.return()}finally{if(A)throw D}}}();p+=1);var h=e.map(function(e,r){var n;return null!=(n=f[r])?n:t[r]}).map(ke),m=ke(100-h.reduce(function(e,t){return e+t},0));if(0!==m){var y=0;h.forEach(function(e,t){e>h[y]&&(y=t)}),h[y]=ke(h[y]+m)}return h}function kn(e,t,r,n){var a=O8(e);if(r<0||r>=e.length-1||!Number.isFinite(n)||0===n)return a;var i=kt(t),o=i.mins,s=i.maxs,l=Array.from({length:r+1},function(e,t){return r-t}),u=Array.from({length:e.length-r-1},function(e,t){return r+1+t}),c=n>0?l:u,d=n>0?u:l,f=Math.min(Math.abs(n),c.reduce(function(e,t){return e+Math.max(0,s[t]-a[t])},0),d.reduce(function(e,t){return e+Math.max(0,a[t]-o[t])},0));if(f<=0)return a;var p=f,h=!0,m=!1,y=void 0;try{for(var v,g=c[Symbol.iterator]();!(h=(v=g.next()).done);h=!0){var b=v.value,x=Math.min(p,Math.max(0,s[b]-a[b]));if(a[b]+=x,(p-=x)<=1e-6)break}}catch(e){m=!0,y=e}finally{try{h||null==g.return||g.return()}finally{if(m)throw y}}var w=f,S=!0,j=!1,O=void 0;try{for(var k,E=d[Symbol.iterator]();!(S=(k=E.next()).done);S=!0){var P=k.value,A=Math.min(w,Math.max(0,a[P]-o[P]));if(a[P]-=A,(w-=A)<=1e-6)break}}catch(e){j=!0,O=e}finally{try{S||null==E.return||E.return()}finally{if(j)throw O}}return a.map(ke)}function ka(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function ki(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ko(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){ki(e,t,r[t])})}return e}function ks(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function kl(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||ku(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ku(e,t){if(e){if("string"==typeof e)return ka(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ka(e,t)}}var kc="egen-workbench-layout",kd=["left","bottom","right"],kf={left:280,right:320,bottom:240},kp={left:{min:200,max:640},right:{min:220,max:640},bottom:{min:120,max:720}},kh=["left","right"];function km(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O9;return"".concat(e,":").concat(t)}function ky(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{width:window.innerWidth,height:window.innerHeight},n=kp[e],a=n.min,i=n.max,o=Math.floor(("bottom"===e?.7*r.height:.5*r.width)||i),s=Math.max(a,Math.min(i,o));return Number.isFinite(t)?Math.round(Math.min(s,Math.max(a,t))):kf[e]}var kv=(0,h0.getGlobalStore)("workbench",function(){var e={sizes:ko({},kf),active:{left:null,right:null,bottom:null},compartments:{left:[],right:[]},heights:{}};try{var t=window.localStorage.getItem(kc);if(!t)return e;var r=JSON.parse(t),n=!0,a=!1,i=void 0;try{for(var o,s,l=kd[Symbol.iterator]();!(n=(s=l.next()).done);n=!0){var u,c,d=s.value,f=null==r||null==(u=r.sizes)?void 0:u[d];"number"==typeof f&&(e.sizes[d]=ky(d,f));var p=null==r||null==(c=r.active)?void 0:c[d];"string"==typeof p&&p.length>0&&(e.active[d]=p)}}catch(e){a=!0,i=e}finally{try{n||null==l.return||l.return()}finally{if(a)throw i}}var h=!0,m=!1,y=void 0;try{for(var v,g=kh[Symbol.iterator]();!(h=(v=g.next()).done);h=!0)!function(){var t,n=v.value,a=null==r||null==(t=r.compartments)?void 0:t[n];Array.isArray(a)&&(e.compartments[n]=a.filter(function(e,t){return"string"==typeof e&&e.length>0&&a.indexOf(e)===t}))}()}catch(e){m=!0,y=e}finally{try{h||null==g.return||g.return()}finally{if(m)throw y}}var b=!0,x=!1,w=void 0;try{for(var S,j=Object.entries(null!=(o=null==r?void 0:r.heights)?o:{})[Symbol.iterator]();!(b=(S=j.next()).done);b=!0){var O=kl(S.value,2),k=O[0],E=O[1];"number"==typeof E&&Number.isFinite(E)&&E>0&&E<=100&&(e.heights[k]=E)}}catch(e){x=!0,w=e}finally{try{b||null==j.return||j.return()}finally{if(x)throw w}}}catch(e){}return e}());kv.subscribe(function(e){try{window.localStorage.setItem(kc,JSON.stringify(e))}catch(e){}});var kg=function(e){return"left"===e||"right"===e};function kb(e){var t,r,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:kv.getState();return kg(e)&&null!=(t=null==(r=n.compartments)?void 0:r[e])?t:[]}function kx(e,t){if(!kg(e))return!1;try{var r=(0,h1.zx)(h1.As[e]).find(function(e){return e.name===t});return!!((null==r?void 0:r.meta)&&(0,h1.lN)(r.meta))}catch(e){return!1}}function kw(e,t){var r=kv.getState(),n=kb(e,r);n.includes(t)||kv.setState({compartments:ks(ko({},kO(),r.compartments),ki({},e,((function(e){if(Array.isArray(e))return ka(e)})(n)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(n)||ku(n)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([t])))})}function kS(e,t){var r=kv.getState(),n=kb(e,r);n.includes(t)&&kv.setState({compartments:ks(ko({},kO(),r.compartments),ki({},e,n.filter(function(e){return e!==t})))})}function kj(e,t){kb(e).includes(t)?kS(e,t):kw(e,t)}function kO(){return{left:[],right:[]}}function kk(e){var t,r=null!=(t=kv.getState().heights)?t:{};Object.entries(e).some(function(e){var t,n=kl(e,2),a=n[0],i=n[1];return Math.abs((null!=(t=r[a])?t:-1)-i)>.005})&&kv.setState({heights:ko({},r,e)})}function kE(e,t){if(kg(e)&&kx(e,t))return kj(e,t);var r=kv.getState().active;kv.setState({active:ks(ko({},r),ki({},e,r[e]===t?null:t))})}function kP(e,t){if(kg(e)&&kx(e,t))return kw(e,t);var r=kv.getState().active;r[e]!==t&&kv.setState({active:ks(ko({},r),ki({},e,t))})}function kA(e,t){var r=kv.getState();if(void 0!==t)return kg(e)&&kb(e,r).includes(t)?kS(e,t):void(r.active[e]===t&&kv.setState({active:ks(ko({},r.active),ki({},e,null))}));var n={};null!==r.active[e]&&(n.active=ks(ko({},r.active),ki({},e,null))),kg(e)&&kb(e,r).length>0&&(n.compartments=ks(ko({},kO(),r.compartments),ki({},e,[]))),Object.keys(n).length>0&&kv.setState(n)}function kD(e,t){var r=kv.getState().sizes,n=ky(e,t);r[e]!==n&&kv.setState({sizes:ks(ko({},r),ki({},e,n))})}function kC(e){kD(e,kf[e])}function kT(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function kN(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){kT(e,t,r[t])})}return e}var kR=(0,h0.getGlobalStore)("workbench-badges",{});function kM(e,t){var r,n,a=kR.getState();if(null==t||0===t||""===t){if(!(e in a))return;var i=kN({},a);delete i[e],kR.setState(i,!0);return}a[e]!==t&&kR.setState((r=kN({},a),n=null!=(n=kT({},e,t))?n:{},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))}function kI(e){return"number"==typeof e&&e>99?"99+":String(e)}let k_={rail:"qvz4aebX8qzfpVVMX6GW6Q==",railGroup:"P-xSK2ViNYrDfA549xovUw==",railSpacer:"yTluC88GKEaJN6D30M7pcA==",railIconMask:"OSxwK8smjsbkkpM9o+2NpA==",railBadge:"NgNYiAFQkrHYVJlXdFWBrw==",railButton:"HEdDR6YvG6RHfTPB5Yz0dA==",zone:"M2aeN9RqSdMKswCesWvs3Q==",compartment:"_49bE69E+4ICdrziyfNrkfA==","zone-left":"uk8RPM-up2A6b308shlQVA==","zone-right":"wWBsxyvamj6G--WUWLOkmQ==","zone-bottom":"ikvYl1ZGiITQC49T41KRyw==",compartmentGap:"pbIpeL1wxaG7IXsuyiQC8Q==",compartmentSplitter:"vX7HFTTPaZMj9PcYFt8iTw==",zoneHeader:"qrZbgloqkaOqKIsp77YScw==",zoneTitle:"+zT247J+DTnYGCJZtUKzrg==",zoneHeaderTools:"Jwd1DZ+AWNbC7RhA-J6eaA==",zoneClose:"+tZxiCZXeSDT53vt0lHOjQ==",zoneBody:"_1l3-F08RXMtn+D6J1yel5Q==",zoneSlot:"_1V5iYwK3aeERgDP7z4s-1w==",splitter:"_99ElxRI4lish2QNz++axSg==","splitter-left":"syr0QGi6BxPYDpnZAnrpGw==","splitter-right":"pGZQ7kMa98WrRUqWv6a1nQ==","splitter-bottom":"cst09ukUHpZYypz45awQDw==",cornerSplitter:"_6+KYstjwPB62arLn1eZfew==","cornerSplitter-left":"adI8Xh87aknu1jI247Fp9g==","cornerSplitter-right":"_6mB4WYkDihd2OrUjK-gLpg=="};function kL(e){var t=e.anchor,r=e.label,n=OP(t,e.rail),a=(0,x.useStore)(kv),i=a.active[t],o=kb(t,a);return 0===n.length?null:(0,v.jsx)("div",{role:"group","aria-label":r,"data-anchor":t,className:"".concat(k_.railGroup," egen-anim-stagger egen-anim-stagger--fade"),children:n.map(function(e){return(0,v.jsx)(kF,{tool:e,active:e.compartment?o.includes(e.id):e.id===i,onClick:function(){return e.compartment?kj(t,e.id):kE(t,e.id)}},e.id)})})}function kF(e){var t=e.tool,r=e.active,n=e.onClick,a=OE(t),i=O5(t.meta.icon),o=(0,h1.e4)(t.meta.iconUrl)?t.meta.iconUrl:void 0,s=(0,x.useStore)(kR)[t.id];return(0,v.jsxs)("button",{type:"button",className:k_.railButton,"aria-pressed":r,"aria-label":a,title:a,"data-active":r,onClick:n,children:[o?(0,v.jsx)("span",{"aria-hidden":"true",className:k_.railIconMask,style:{"--egen-rail-icon":'url("'.concat(o.replace(/"/g,"%22"),'")')}}):i?(0,v.jsx)(i,{size:18,"aria-hidden":"true"}):(0,v.jsx)("span",{"aria-hidden":"true",children:a.charAt(0).toUpperCase()}),void 0!==s&&(0,v.jsx)("span",{className:k_.railBadge,"data-testid":"workbench-badge-".concat(t.id),children:kI(s)})]})}function kB(){return(0,v.jsxs)("nav",{"aria-label":"Outils de l'application","data-testid":"workbench-rail-left",className:k_.rail,children:[(0,v.jsx)(kL,{anchor:"left",label:"Panneau lat\xe9ral"}),(0,v.jsx)("span",{className:k_.railSpacer}),(0,v.jsx)(kL,{anchor:"bottom",rail:"left",label:"Panneau inf\xe9rieur"})]})}function kV(){return(0,v.jsxs)("nav",{"aria-label":"Outils globaux","data-testid":"workbench-rail-right",className:k_.rail,children:[(0,v.jsx)(kL,{anchor:"right",label:"Panneau droit"}),(0,v.jsx)("span",{className:k_.railSpacer}),(0,v.jsx)(kL,{anchor:"bottom",rail:"right",label:"Panneau inf\xe9rieur"})]})}var kz=r(822);function kW(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var k$="data-workbench-resizing";function kU(e){var t=e.anchor,r=e.label,n=(0,x.useStore)(kv).sizes[t],a=(0,g.useRef)(null),i="bottom"!==t,o=function(e){var t,r;a.current&&(a.current=null,null==(t=(r=e.currentTarget).releasePointerCapture)||t.call(r,e.pointerId),document.documentElement.removeAttribute(k$))};return(0,v.jsx)("div",{role:"separator",tabIndex:0,"aria-label":r,"aria-orientation":i?"vertical":"horizontal","aria-valuenow":n,"aria-valuemin":ky(t,0),"aria-valuemax":ky(t,Number.MAX_SAFE_INTEGER),"data-anchor":t,className:"".concat(k_.splitter," ").concat(k_["splitter-".concat(t)]),onPointerDown:function(e){if(0===e.button){var r,n,i,o,s=null!=(r=null==(n=e.currentTarget.parentElement)?void 0:n.parentElement)?r:e.currentTarget.parentElement;if(s){var l=s.getBoundingClientRect(),u="left"===t?l.left:"right"===t?l.right:l.bottom,c="left"===t?l.right:"right"===t?l.left:l.top;a.current={edge:u,grab:("bottom"===t?e.clientY:e.clientX)-c},null==(i=(o=e.currentTarget).setPointerCapture)||i.call(o,e.pointerId),document.documentElement.setAttribute(k$,t),e.preventDefault()}}},onPointerMove:function(e){if(a.current){var r,n,i,o;kD(t,(r=e.clientX,n=e.clientY,i=a.current.edge,o=a.current.grab,"left"===t?r-o-i:"right"===t?i-(r-o):i-(n-o)))}},onPointerUp:o,onPointerCancel:o,onDoubleClick:function(){return kC(t)},onKeyDown:function(e){var r="left"===t?"ArrowRight":"right"===t?"ArrowLeft":"ArrowUp",n="left"===t?"ArrowLeft":"right"===t?"ArrowRight":"ArrowDown";if(e.key===r)kD(t,kv.getState().sizes[t]+16);else if(e.key===n)kD(t,kv.getState().sizes[t]-16);else if("Home"===e.key)kD(t,0);else{if("End"!==e.key)return;kD(t,Number.MAX_SAFE_INTEGER)}e.preventDefault()}})}function kH(e){var t=e.side,r=e.label,n=(0,g.useRef)(null),a="corner-".concat(t),i=function(e){var t,r;n.current&&(n.current=null,null==(t=(r=e.currentTarget).releasePointerCapture)||t.call(r,e.pointerId),document.documentElement.removeAttribute(k$))};return(0,v.jsx)("div",{"aria-hidden":"true",title:r,"data-corner":t,className:"".concat(k_.cornerSplitter," ").concat(k_["cornerSplitter-".concat(t)]),onPointerDown:function(e){if(0===e.button){var r,i,o=kv.getState().sizes;n.current={x:e.clientX,y:e.clientY,side:o[t],bottom:o.bottom},null==(r=(i=e.currentTarget).setPointerCapture)||r.call(i,e.pointerId),document.documentElement.setAttribute(k$,a),e.preventDefault()}},onPointerMove:function(e){var r=n.current;if(r){var a=e.clientX-r.x;kD(t,r.side+("left"===t?a:-a)),kD("bottom",r.bottom-(e.clientY-r.y))}},onPointerUp:i,onPointerCancel:i,onDoubleClick:function(){kC(t),kC("bottom")}})}var kG=function(e,t){return Object.fromEntries(e.map(function(e,r){return[e.key,t[r]]}))};function kK(e){var t=e.anchor,r=e.index,n=e.items,a=e.heights,i=e.label,o=(0,g.useRef)(null),s=function(e){var t,r;o.current&&(o.current=null,null==(t=(r=e.currentTarget).releasePointerCapture)||t.call(r,e.pointerId),document.documentElement.removeAttribute(k$))};return(0,v.jsx)("div",{role:"separator",tabIndex:0,"aria-label":i,"aria-orientation":"horizontal","aria-valuenow":Math.round(a[r]),"aria-valuemin":0,"aria-valuemax":100,"data-compartment-splitter":r,className:k_.compartmentSplitter,onPointerDown:function(e){if(0===e.button){var r,i,s=e.currentTarget.parentElement;if(s){var l=e.currentTarget.getBoundingClientRect().height,u=s.getBoundingClientRect().height-l*(n.length-1);u>0&&(o.current={y:e.clientY,heights:function(e){if(Array.isArray(e))return kW(e)}(a)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(a)||function(e){if(e){if("string"==typeof e)return kW(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return kW(e,void 0)}}(a)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),perPixel:100/u},null==(r=(i=e.currentTarget).setPointerCapture)||r.call(i,e.pointerId),document.documentElement.setAttribute(k$,"compartment-".concat(t)),e.preventDefault())}}},onPointerMove:function(e){var t=o.current;if(t){var a=(e.clientY-t.y)*t.perPixel;kk(kG(n,kn(t.heights,n,r,a)))}},onPointerUp:s,onPointerCancel:s,onDoubleClick:function(){return kk(kG(n,kr(n,{})))},onKeyDown:function(e){("ArrowUp"===e.key||"ArrowDown"===e.key)&&(kk(kG(n,kn(a,n,r,"ArrowDown"===e.key?5:-5))),e.preventDefault())}})}function kq(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var kY="data-tool-window-container",kX="data-tool-window-header";function kZ(e){var t,r=e.children,n=(0,g.useRef)(null),a=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(void 0))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return kq(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return kq(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=a[0],o=a[1];return(0,g.useLayoutEffect)(function(){var e,t,r=null==(t=n.current)?void 0:t.closest("[".concat(kY,"], aside[data-anchor]"));o(null!=(e=null==r?void 0:r.querySelector("[".concat(kX,"]")))?e:null)},[]),(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("span",{ref:n,hidden:!0}),void 0===i?null:null===i?r:(0,tZ.createPortal)(r,i)]})}function kQ(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function kJ(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function k0(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){kJ(e,t,r[t])})}return e}var k1={moduleName:"@egen-civitas/esm-styleguide",featureName:"workbench"},k2={left:"--egen-zone-left-width",right:"--egen-zone-right-width",bottom:"--egen-zone-bottom-height"},k3={left:"egen-anim-slide-in-from-left",right:"egen-anim-slide-in-from-right",bottom:"egen-anim-slide-in-from-bottom"},k4={left:"egen-anim-slide-out-to-left",right:"egen-anim-slide-out-to-right",bottom:"egen-anim-slide-out-to-bottom"};function k5(e){var t,r=e.anchor,n=OP(r),a=(0,x.useStore)(kv),i=a.active,o=a.sizes,s=i[r],l=o[r],u="bottom"===r?null:r,c=[],d=n.find(function(e){return!e.compartment&&e.id===s});if(d&&c.push({tool:d,item:k0({key:km(null!=u?u:"left")},O7)}),u){var f=!0,p=!1,h=void 0;try{for(var m,y,b=kb(u,a)[Symbol.iterator]();!(f=(y=b.next()).done);f=!0)!function(){var e=y.value,t=n.find(function(t){return t.id===e&&t.compartment});(null==t?void 0:t.compartment)&&c.push({tool:t,item:k0({key:km(u,e)},t.compartment)})}()}catch(e){p=!0,h=e}finally{try{f||null==b.return||b.return()}finally{if(p)throw h}}}var w=c.length>0,S=(0,g.useRef)([]),j=(0,g.useRef)(!1),O=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)("open"))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return kQ(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return kQ(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),k=O[0],E=O[1];w&&(S.current=c);var P=w?c:"closing"===k?S.current:[],A=P.length>0;(0,g.useLayoutEffect)(function(){if(w!==j.current){j.current=w,E(w?"opening":"closing");var e=window.setTimeout(function(){w||(S.current=[]),E("open")},300);return function(){return window.clearTimeout(e)}}},[w]),(0,g.useEffect)(function(){document.documentElement.style.setProperty(k2[r],w?"".concat(l,"px"):"0px")},[r,w,l]),(0,g.useEffect)(function(){return function(){document.documentElement.style.removeProperty(k2[r])}},[r]);var D=P.map(function(e){return e.item}),C=kr(D,null!=(m=a.heights)?m:{}),T=D.map(function(e,t){return"".concat(e.key,"=").concat(C[t])}).join("|");(0,g.useEffect)(function(){w&&!(D.length<2)&&kk(Object.fromEntries(D.map(function(e,t){return[e.key,C[t]]})))},[w,T]);var N=P[0]?OE(P[0].tool):"",R="closing"===k?k4[r]:"opening"===k?k3[r]:"",M="closing"!==k;return(0,v.jsx)("aside",{"data-testid":"workbench-zone-".concat(r),"data-anchor":r,"data-open":w,"data-phase":k,"data-compartments":P.length,"aria-label":N||void 0,hidden:!A,style:{"--egen-zone-inner-size":"".concat(l,"px")},className:"".concat(k_.zone," ").concat(k_["zone-".concat(r)]," ").concat(R),children:A&&(0,v.jsxs)(v.Fragment,{children:[P.map(function(e,t){var n=e.tool,a=e.item;return(0,v.jsxs)(g.Fragment,{children:[t>0&&M&&u&&(0,v.jsx)(kK,{anchor:u,index:t-1,items:D,heights:C,label:"Redimensionner ".concat(OE(P[t-1].tool)," et ").concat(OE(n))}),t>0&&!(M&&u)&&(0,v.jsx)("span",{"aria-hidden":"true",className:k_.compartmentGap}),(0,v.jsx)(k6,{anchor:r,tool:n,height:C[t],own:a.key!==km(null!=u?u:"left"),single:1===P.length})]},a.key)}),"closing"!==k&&(0,v.jsx)(kU,{anchor:r,label:"Redimensionner ".concat(N)}),"bottom"===r&&"closing"!==k&&null!==i.left&&(0,v.jsx)(kH,{side:"left",label:"Redimensionner la zone gauche et la zone basse"}),"bottom"===r&&"closing"!==k&&null!==i.right&&(0,v.jsx)(kH,{side:"right",label:"Redimensionner la zone droite et la zone basse"})]})})}function k6(e){var t,r=e.anchor,n=e.tool,a=e.height,i=e.own,o=e.single,s=OE(n),l=(0,g.useCallback)(function(e){return e.filter(function(e){return e.name===n.id})},[n.id]);return(0,v.jsxs)("section",(kJ(t={"data-testid":"workbench-compartment-".concat(r,"-").concat(i?n.id:O9),"data-compartment":i?"own":"default","data-height":Math.round(100*a)/100},kY,""),kJ(t,"style",o?void 0:{flex:"".concat(a," 1 0%")}),kJ(t,"className",k_.compartment),kJ(t,"children",[(0,v.jsxs)("header",{className:k_.zoneHeader,children:[(0,v.jsx)("h2",{className:k_.zoneTitle,children:s}),(0,v.jsx)("div",kJ({className:k_.zoneHeaderTools},kX,"")),(0,v.jsx)("button",{type:"button",className:k_.zoneClose,"aria-label":"Fermer ".concat(s),title:"Fermer ".concat(s),onClick:function(){return kA(r,n.id)},children:(0,v.jsx)(kz.A,{size:14,"aria-hidden":"true"})})]}),(0,v.jsx)("div",{className:"".concat(k_.zoneBody," egen-anim-fade-in"),children:(0,v.jsx)(x.ComponentContext.Provider,{value:k1,children:(0,v.jsx)(x.ExtensionSlot,{name:h1.As[r],select:l,className:k_.zoneSlot})})},n.id)]),t))}var k8={moduleName:"@egen-civitas/esm-styleguide",featureName:"workbench",strictMode:!1},k9=(0,x.egenComponentDecorator)(k8)(kB),k7=(0,x.egenComponentDecorator)(k8)(kV),Ee=(0,x.egenComponentDecorator)(k8)(k5);function Et(e){var t=e.railLeft,r=e.railRight,n=e.zoneLeft,a=e.zoneRight,i=e.zoneBottom;t&&(0,mP.createRoot)(t).render((0,v.jsx)(k9,{})),r&&(0,mP.createRoot)(r).render((0,v.jsx)(k7,{})),n&&(0,mP.createRoot)(n).render((0,v.jsx)(Ee,{anchor:"left"})),a&&(0,mP.createRoot)(a).render((0,v.jsx)(Ee,{anchor:"right"})),i&&(0,mP.createRoot)(i).render((0,v.jsx)(Ee,{anchor:"bottom"}))}function Er(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function En(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||Ei(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ea(e){return function(e){if(Array.isArray(e))return Er(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Ei(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ei(e,t){if(e){if("string"==typeof e)return Er(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Er(e,t)}}var Eo=function(e,t,r){return t?(0,V.t)(e,t,r):r};function Es(){var e=window.getEgenSpaBase().replace(/\/$/,""),t=window.location.pathname;return(t.startsWith(e)?t.slice(e.length):t).replace(/^\/+|\/+$/g,"")}function El(e){var t,r,n,a=e.section,i=(0,x.useAssignedExtensions)(h1.yS),o=(r=(t=En((0,g.useState)(Es),2))[0],n=t[1],(0,g.useEffect)(function(){var e=function(){return n(Es())};return window.addEventListener("single-spa:routing-event",e),window.addEventListener("popstate",e),e(),function(){window.removeEventListener("single-spa:routing-event",e),window.removeEventListener("popstate",e)}},[]),r),s=En((0,g.useState)(null),2),l=s[0],u=s[1],c=(0,g.useMemo)(function(){var e=new Map,t=!0,r=!1,n=void 0;try{for(var o,s=i[Symbol.iterator]();!(t=(o=s.next()).done);t=!0){var l=o.value;if((0,h1.DK)(l.meta)&&l.meta.section===a){var u=l.meta,c=null!=(f=u.group)?f:"",d=e.get(c);if(!d){var f,p,h=u.group?null!=(p=u.groupLabel)?p:u.group:void 0;d={key:c,label:h?Eo(l.moduleName,u.groupLabelKey,h):void 0,entries:[]},e.set(c,d)}d.entries.push({name:l.name,moduleName:l.moduleName,meta:u})}}}catch(e){r=!0,n=e}finally{try{t||null==s.return||s.return()}finally{if(r)throw n}}return Ea(e.values())},[i,a]),d=(0,g.useMemo)(function(){var e,t,r=c.flatMap(function(e){return e.entries}).filter(function(e){var t;return o===(t=e.meta.route)||o.startsWith("".concat(t,"/"))});if(0===r.length)return null;var n=(e=Math).max.apply(e,Ea(r.map(function(e){return e.meta.route.length}))),a=r.filter(function(e){return e.meta.route.length===n});return(null!=(t=a.find(function(e){return e.name===l}))?t:a[0]).name},[c,o,l]);return 0===c.length?null:(0,v.jsx)("nav",{className:"qLEdjoMnou12cJG2pcNl2g==","data-testid":"section-nav-".concat(a),children:c.map(function(e){return(0,v.jsxs)("div",{className:"Yyc847xcFssyhuatTQ7xiA==",role:"group","aria-label":e.label,children:[e.label&&(0,v.jsx)("h3",{className:"fqz9L1RbM505xmJMtsj0ug==",children:e.label}),(0,v.jsx)("ul",{className:"bxiFBKtONQbQt9kFcd6ZZA==",children:e.entries.map(function(e){var t=O5(e.meta.icon),r=Eo(e.moduleName,e.meta.labelKey,e.meta.label),n=e.meta.description?Eo(e.moduleName,e.meta.descriptionKey,e.meta.description):void 0;return(0,v.jsx)("li",{children:(0,v.jsxs)("button",{type:"button",className:"mQhizWw06oV9hY+VNVfIhw==","data-active":e.name===d,"aria-current":e.name===d?"page":void 0,title:n,onClick:function(){u(e.name),(0,y8.oo)({to:"${egenSpaBase}/".concat(e.meta.route)})},children:[t&&(0,v.jsx)(t,{size:16,"aria-hidden":"true",className:"K3jvNMlqmar7YFU-LrIMVA=="}),(0,v.jsx)("span",{className:"jukYKqSJ+u0ARW+Th96NRw==",children:r})]})},e.name)})})]},e.key)})})}var Eu={fade:{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}},scale:{initial:{opacity:0,scale:.94},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.96}},zoom:{initial:{opacity:0,scale:.6},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.6}},"slide-up":{initial:{opacity:0,y:48},animate:{opacity:1,y:0},exit:{opacity:0,y:24}},"slide-down":{initial:{opacity:0,y:-48},animate:{opacity:1,y:0},exit:{opacity:0,y:-24}},"slide-left":{initial:{opacity:0,x:48},animate:{opacity:1,x:0},exit:{opacity:0,x:24}},"slide-right":{initial:{opacity:0,x:-48},animate:{opacity:1,x:0},exit:{opacity:0,x:-24}},warp:{initial:{opacity:0,rotateX:-5,skewY:-1.5,scaleY:2,scaleX:.4,y:100},animate:{opacity:1,rotateX:0,skewY:0,scaleY:1,scaleX:1,y:0,transition:{duration:.35,ease:[.59,0,.35,1],y:{type:"spring",visualDuration:.7,bounce:.2}}},exit:{opacity:0,rotateX:-5,skewY:-1.5,scaleY:2,scaleX:.4,y:100,transition:{duration:.35,ease:[.59,0,.35,1]}}},none:{initial:{},animate:{},exit:{}}},Ec={warp:{transformPerspective:1e3,originX:.5,originY:0}};function Ed(){cE.current||cA();let[e]=(0,g.useState)(ck.current);return e}let Ef={triggerWrap:"obUOkmXvVgfdGywRlKafuQ==",root:"RGEtM+3JT-yTrSFA8YESww==",overlay:"_6MXfQidMjLnx27vgPw-9Sg==",warpGlow:"kd2FxTe0qj-EPlsuLvJA-A==",warpWave:"eYhosSxSrqkohY0gP1+l0g==",warpWaveTint:"v7v+84i9dK1RijFpwYzIYQ==",warpBlob:"TW8N0JWIkX2rNgyo078MpA==",warpBlobA:"_41ZLsf4sYJA24kAYHV4t9Q==",warpBlobB:"yBeNfkSKBCQ7aUPSLla25A==",centerLayer:"RUVI+vdIGx4IlAly1zskzg==",panel:"iLjC58ABoO85I1ObBvOilQ==",closeButton:"QJ7H9rD2013pVurP-n31bw==",dockBubble:"JgOy0alMLvPtoW+dnVnh9Q==","dockBubble--left":"_0TgTNggNd+BZEC9BP4NglQ==","dockBubble--right":"oaILkyqA-30uHGcpYEfM7Q=="};var Ep=function(e){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({opacity:.9,transition:{duration:.5,scale:{duration:15,repeat:1/0,repeatType:"loop",ease:"easeInOut",delay:.35}}},e?{}:{scale:[1,.7,1]})},Eh=function(){var e=Ed();return(0,v.jsxs)("div",{className:Ef.warpGlow,"aria-hidden":"true",children:[(0,v.jsx)(hz.div,{className:Ef.warpWave,initial:{scale:0,opacity:1},animate:{scale:e?1:10,opacity:.2,transition:{duration:.5,opacity:{duration:.5,ease:"easeInOut"}}},exit:{scale:0,opacity:1,transition:{duration:.25}}}),(0,v.jsx)(hz.div,{className:"".concat(Ef.warpBlob," ").concat(Ef.warpBlobA),initial:{opacity:0},animate:Ep(e),exit:{opacity:0,transition:{duration:.25}}}),(0,v.jsx)(hz.div,{className:"".concat(Ef.warpBlob," ").concat(Ef.warpBlobB),initial:{opacity:0},animate:Ep(e),exit:{opacity:0,transition:{duration:.25}}})]})};function Em(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ey(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ev(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){Ey(e,t,r[t])})}return e}function Eg(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Em(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Em(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Eb=function(e,t){return"u"<typeof window?e:Math.min(Math.max(e,8+t/2),window.innerHeight-8-t/2)},Ex=function(e){return(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"&&null!==e},Ew=function(e){var t,r,n,a,i,o,s,l,u,c=e.open,d=e.defaultOpen,f=e.onOpenChange,p=e.trigger,h=e.children,m=e.showCloseButton,y=e.renderCloseButton,b=e.cardVariant,x=e.cardProps,w=e.draggable,S=void 0!==w&&w,j=e.dockable,k=void 0!==j&&j,E=e.dockIcon,P=e.dockEdgeThreshold,A=void 0===P?80:P,D=e.dockUndockDistance,C=void 0===D?120:D,T=e.dockSize,N=void 0===T?56:T,R=e.closeOnOverlayClick,M=e.closeOnEscape,I=void 0===M||M,L=e.showOverlay,B=e.lockScroll,V=void 0===B||B,z=e.animation,W=void 0===z?"scale":z,$=e.overlayAnimation,U=e.overlayEffect,H=e.warpColor,G=e.className,K=e.style,q=e.overlayClassName,Y=Eg((0,g.useState)(void 0!==d&&d),2),X=Y[0],Z=Y[1],Q=Eg((0,g.useState)(!1),2),J=Q[0],ee=Q[1],et=Eg((0,g.useState)(null),2),er=et[0],en=et[1],ea=(0,g.useRef)(null),ei=(0,g.useId)(),eo=void 0!==c,es=eo?c:X,el=(0,g.useCallback)(function(e){null==f||f(e),eo||Z(e)},[f,eo]),eu=(0,g.useCallback)(function(){return el(!1)},[el]);(0,g.useEffect)(function(){return ee(!0)},[]),(0,g.useEffect)(function(){es&&en(null)},[es]);var ec=(0,g.useCallback)(function(){if(k&&ea.current&&"u">typeof window){var e=ea.current.getBoundingClientRect(),t=e.left+e.width/2,r=e.top+e.height/2;if(er)return void(Math.abs(t-("left"===er.side?0:window.innerWidth))>C?en(null):en({side:er.side,y:Eb(r,N)}));t<=A?en({side:"left",y:Eb(r,N)}):t>=window.innerWidth-A&&en({side:"right",y:Eb(r,N)})}},[k,er,A,C,N]);(0,g.useEffect)(function(){if(es&&V)return document.body.style.overflow="hidden",function(){document.body.style.overflow=""}},[es,V]),(0,g.useEffect)(function(){if(es&&I){var e=function(e){"Escape"===e.key&&eu()};return document.addEventListener("keydown",e),function(){return document.removeEventListener("keydown",e)}}},[es,I,eu]);var ed=Ex(W)?W:{preset:W},ef=null!=(n=ed.variants)?n:Eu[null!=(a=ed.preset)?a:"scale"],ep={duration:null!=(i=ed.duration)?i:.25,ease:null!=(o=ed.ease)?o:[.16,1,.3,1]},eh=ed.variants?void 0:null!=(s=ed.preset)?s:"scale",em=eh?Ec[eh]:void 0,ey=null!=U?U:"warp"===eh?"warp":"none",ev={duration:null!=(l=null==$?void 0:$.duration)?l:.2,ease:null!=(u=null==$?void 0:$.ease)?u:"easeOut"},eg=(0,v.jsx)(jA,{children:es&&(0,v.jsxs)("div",{className:Ef.root,children:[(void 0===L||L)&&!er&&(0,v.jsx)(hz.div,{className:O()(Ef.overlay,q),style:"warp"===ey?{"--card-modal-warp-color":null!=H?H:"var(--colors-error-500)"}:void 0,initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:ev,onClick:void 0===R||R?eu:void 0,"aria-hidden":"true",children:"warp"===ey&&(0,v.jsx)(Eh,{})}),er?(0,v.jsx)(hz.div,{ref:ea,className:O()(Ef.dockBubble,Ef["dockBubble--".concat(er.side)]),style:Ey({top:er.y,width:N,height:N},er.side,-(N/2)),drag:!0,dragMomentum:!1,dragElastic:.2,onDragEnd:ec,initial:{scale:.3,opacity:0},animate:{scale:1,opacity:1},exit:{scale:.3,opacity:0},transition:{type:"spring",stiffness:420,damping:32},whileDrag:{cursor:"grabbing"},role:"button",tabIndex:0,"aria-label":"D\xe9ployer le modal",onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&en(null)},children:null!=E?E:(0,v.jsx)(oV,{size:20})}):(0,v.jsx)("div",{className:Ef.centerLayer,children:(0,v.jsx)(hz.div,{ref:ea,role:"dialog","aria-modal":"true","aria-labelledby":(null==x?void 0:x.title)?ei:void 0,className:O()(Ef.panel,G),style:Ev({},em,K),variants:ef,initial:"initial",animate:"animate",exit:"exit",transition:ep,drag:S,dragMomentum:!1,dragElastic:.12,onDragEnd:k?ec:void 0,whileDrag:S?{cursor:"grabbing"}:void 0,children:(0,v.jsxs)(F,(t=Ev({variant:void 0===b?"default":b},x),r=r={children:[(void 0===m||m)&&(y?y(eu):(0,v.jsx)("button",{type:"button",className:Ef.closeButton,onClick:eu,"aria-label":"Fermer",children:(0,v.jsx)(oj,{size:18})})),h]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))})})]})});return(0,v.jsxs)(v.Fragment,{children:[p&&(0,v.jsx)("span",{className:Ef.triggerWrap,onClick:function(){return el(!0)},children:p}),J&&(0,tZ.createPortal)(eg,document.body)]})},ES=(0,g.createContext)(null);function Ej(){var e=(0,g.useContext)(ES);if(!e)throw Error("Select compound components must be used within <Select>");return e}function EO(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ek(e){var t,r=e.children,n=e.options,a=e.selectedOptionId,i=e.onOptionChange,o=e.open,s=e.onOpenChange,l=e.getOptionId,u=void 0===l?function(e){return e.id}:l,c=e.getOptionName,d=void 0===c?function(e){return e.name}:c,f=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return EO(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return EO(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),p=f[0],h=f[1],m=(0,g.useRef)(null),y=void 0!==o,b=y?o:p,x=(0,g.useCallback)(function(e){null==s||s(e),y||h(e)},[s,y]),w=(0,g.useMemo)(function(){var e;return a&&null!=(e=n.find(function(e){return u(e)===a}))?e:n[0]},[n,a,u]),S=(0,g.useCallback)(function(e){null==i||i(e),x(!1)},[i,x]);return(0,v.jsx)(ES.Provider,{value:{open:b,setOpen:x,selectedOption:w,options:n,onOptionSelect:S,getOptionId:u,getOptionName:d,triggerRef:m},children:r})}function EE(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var EP=function(e){var t,r=e.src,n=e.name,a=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return EE(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return EE(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=a[0],o=a[1];return r&&!i?(0,v.jsx)("img",{className:"SfeZipJ-EbaokHctW8FEUA==",src:r,alt:"",onError:function(){return o(!0)}}):(0,v.jsx)("span",{className:"JfvCvEXqGY3pQYoOoULjmg==","aria-hidden":"true",children:n.charAt(0).toUpperCase()})};function EA(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var ED=function(e){var t,r,n=e.className,a=e.renderTrigger,i=e.showAvatar,o=e.placeholder,s=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className","renderTrigger","showAvatar","placeholder"]),l=Ej(),u=l.open,c=l.setOpen,d=l.selectedOption,f=l.getOptionName,p=l.triggerRef;return(0,v.jsxs)("button",(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){EA(e,t,r[t])})}return e}({ref:p,type:"button","data-state":u?"open":"closed",className:O()("_8A7vObqyrHkzJZX3MyKCvg==",n),"aria-haspopup":"listbox","aria-expanded":u,onClick:function(){return c(!u)}},s),r=r={children:[a?a(d,u):(0,v.jsx)("span",{className:"eSzDXRtGcW-YSjmCT0-Ddw==",children:d?(0,v.jsxs)(v.Fragment,{children:[(void 0===i||i)&&(0,v.jsx)(EP,{src:d.logo,name:f(d)}),(0,v.jsx)("span",{className:"daPOVgYo-UqRJt-fl64xnA==",children:f(d)})]}):(0,v.jsx)("span",{className:"_9rM-qQ-coahjdQZK8YeKAA==",children:void 0===o?"S\xe9lectionner…":o})}),(0,v.jsx)(ob,{className:O()("IkujjwnflhrCxIL04AEPig==",EA({},"_2LDeSM6tUlPbxNaRHK05Iw==",u)),size:16})]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))};function EC(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function ET(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function EN(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return EC(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return EC(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var ER=function(e){var t=e.className,r=e.style,n=e.renderOption,a=e.title,i=void 0===a?"Options":a,o=e.searchable,s=e.searchPlaceholder,l=void 0===s?"Rechercher…":s,u=e.onSearch,c=e.emptyMessage,d=e.showAvatar,f=void 0===d||d,p=e.children,h=Ej(),m=h.open,y=h.setOpen,b=h.options,x=h.selectedOption,w=h.onOptionSelect,S=h.getOptionId,j=h.getOptionName,k=h.triggerRef,E=EN((0,g.useState)(""),2),P=E[0],A=E[1],D=EN((0,g.useState)(null),2),C=D[0],T=D[1],N=(0,g.useRef)(null);(0,g.useLayoutEffect)(function(){if(m&&k.current){var e=k.current.getBoundingClientRect();T({top:e.bottom+8,left:e.left,width:e.width})}},[m,k]),(0,g.useLayoutEffect)(function(){if(m){var e=function(e){var t,r,n=e.target;(null==(t=N.current)?void 0:t.contains(n))||(null==(r=k.current)?void 0:r.contains(n))||y(!1)},t=function(e){"Escape"===e.key&&y(!1)};return document.addEventListener("mousedown",e),document.addEventListener("keydown",t),function(){document.removeEventListener("mousedown",e),document.removeEventListener("keydown",t)}}},[m,y,k]),(0,g.useLayoutEffect)(function(){null==u||u(P)},[P,u]);var R=(0,g.useMemo)(function(){if(!P.trim())return b;var e=P.trim().toLowerCase();return b.filter(function(t){return j(t).toLowerCase().includes(e)})},[b,P,j]);return(0,v.jsx)(jA,{children:m&&C&&(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("div",{className:"_55fm5zZQNsrBHYAZbXmNvg==",onClick:function(){return y(!1)},"aria-hidden":"true"}),(0,v.jsxs)(hz.div,{ref:N,role:"listbox",className:O()("_8533SRCjw0RGEuTOYGY4FA==",t),style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){ET(e,t,r[t])})}return e}({top:C.top,left:C.left,minWidth:C.width},r),initial:{opacity:0,y:-6,scale:.98},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:-6,scale:.98,transition:{duration:.15}},transition:{duration:.18,ease:"easeOut"},children:[i&&(0,v.jsx)("div",{className:"hvqzvUcvwgWeDSSzp+zRfQ==",children:(0,v.jsx)("p",{className:"WuMZ5aFHDUDGitQ16DWxkQ==",children:i})}),void 0!==o&&o&&(0,v.jsxs)("div",{className:"El+2XqUZnMl2EdCFZiCqZg==",children:[(0,v.jsx)(o1,{className:"G0ZQ7JjU-IctRcuJd8GAMA==",size:14}),(0,v.jsx)("input",{type:"search",value:P,onChange:function(e){return A(e.target.value)},placeholder:l,className:"jQTabWEMQ1lzIpV-psr-Iw==","aria-label":l})]}),(0,v.jsx)("div",{className:"RP3TMqBbVREsRmefNgXF3A==",children:0===R.length?(0,v.jsx)("div",{className:"ytySk7Z-uqE+Cd9nnCNIzQ==",children:void 0===c?"Aucun r\xe9sultat.":c}):R.map(function(e){var t=!!(x&&S(x)===S(e));return(0,v.jsx)("button",{type:"button",role:"option","aria-selected":t,className:O()("B1tJItorhHLvItWNBDbDTg==",ET({},"_3ytcFRMy9adpn2Lj3bv0pA==",t)),onClick:function(){return w(e)},children:n?n(e,t):(0,v.jsxs)("span",{className:"SVev5Gq0Bwn3qsCJanJGhg==",children:[f&&(0,v.jsx)(EP,{src:e.logo,name:j(e)}),(0,v.jsxs)("span",{className:"tv64rRuAO4duYiHknZebcQ==",children:[(0,v.jsx)("span",{className:"_2a5Da3T58kUDerdneCN30g==",children:j(e)}),"string"==typeof e.plan&&(0,v.jsx)("span",{className:"lcrpGqGFBDjmEWV5DeMRCw==",children:e.plan})]}),t&&(0,v.jsx)(og,{className:"v2g0jDDAFYSc-NvgPQzIuw==",size:16})]})},S(e))})}),p&&(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("div",{className:"jiBHwsnN8h16vEbCOHfFyQ=="}),(0,v.jsx)("div",{className:"xQ7Xx8vG4UYoZ5L2n4s7aw==",children:p})]})]})]})})};let EM="-ATlOUGNcp7GZJPUeq8rFQ==";function EI(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function E_(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||EL(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function EL(e,t){if(e){if("string"==typeof e)return EI(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return EI(e,t)}}function EF(e){var t=e.options,r=e.defaultActiveIndex,n=e.onChange,a=e.title,i=e.subtitle,o=e.className,s=e.style,l=E_((0,g.useState)(void 0===r?0:r),2),u=l[0],c=l[1],d=E_((0,g.useState)([]),2),f=d[0],p=d[1],h=function(e){e!==u&&(c(e),null==n||n(e))};return(0,g.useEffect)(function(){var e=[];return t.forEach(function(t,r){var n=setTimeout(function(){p(function(e){return((function(e){if(Array.isArray(e))return EI(e)})(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||EL(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([r])})},180*r);e.push(n)}),function(){e.forEach(function(e){return clearTimeout(e)})}},[]),(0,v.jsxs)("div",{className:O()("wlcxPFWjrVtumBSV-e-CDA==",o),style:s,children:[(a||i)&&(0,v.jsxs)("div",{className:"bj+Iqs7YlC4rnGPeWHvfDA==",children:[a&&(0,v.jsx)("h1",{className:O()("BxZYvA8NGXlbyIbv2WeY+g==",EM,"hlPOKNY1Iajw1xOcwAeSBA=="),children:a}),i&&(0,v.jsx)("p",{className:O()("feAT6ZKoC5a3dcOZdCuiXQ==",EM,"bhPpy9KSGVluihqPVuUiTw=="),children:i})]}),(0,v.jsx)("div",{className:"YjKVOFGPUd8QRnTyYbHlEQ=="}),(0,v.jsx)("div",{className:"yxtd7MYVN9PUttKi+ACMTA==",children:t.map(function(e,t){var r=u===t,n=f.includes(t);return(0,v.jsxs)("div",{role:"button",tabIndex:0,"aria-pressed":r,"aria-label":e.title,className:"KXRbSNJdVXlt4FjqmIyEqA==",style:{backgroundImage:"url('".concat(e.image,"')"),backgroundSize:r?"auto 100%":"auto 120%",opacity:+!!n,transform:n?"translateX(0)":"translateX(-60px)",borderColor:r?"var(--colors-on-primary)":"var(--colors-neutral-800)",boxShadow:r?"0 20px 60px color-mix(in srgb, var(--colors-neutral-950) 50%, transparent)":"0 10px 30px color-mix(in srgb, var(--colors-neutral-950) 30%, transparent)",flex:r?"7 1 0%":"1 1 0%",zIndex:r?10:1},onClick:function(){return h(t)},onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&(e.preventDefault(),h(t))},children:[(0,v.jsx)("div",{className:"tWfgJW24bLfSOAIrfBdeBw==",style:{bottom:r?"0":"-40px",boxShadow:r?"inset 0 -120px 120px -120px var(--colors-neutral-950), inset 0 -120px 120px -80px var(--colors-neutral-950)":"inset 0 -120px 0px -120px var(--colors-neutral-950), inset 0 -120px 0px -80px var(--colors-neutral-950)"}}),(0,v.jsxs)("div",{className:"_29Y7xxDXDwKDDxpgJdNRmw==",children:[(0,v.jsx)("div",{className:"NLN-jvKhi89LBjqeRG23bA==",children:e.icon}),(0,v.jsxs)("div",{className:"rUd70NVRl13hfW708rVyBw==",children:[(0,v.jsx)("div",{className:"C7SafuQjFwOk8hTZ+e5smA==",style:{opacity:+!!r,transform:r?"translateX(0)":"translateX(25px)"},children:e.title}),(0,v.jsx)("div",{className:"eJ6SOWnBp59Zc89zmo61Zw==",style:{opacity:+!!r,transform:r?"translateX(0)":"translateX(25px)"},children:e.description})]})]})]},t)})})]})}function EB(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function EV(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var Ez=function(e){return EB({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:24,height:24,fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":!0,focusable:!1},e)},EW=function(e){return(0,v.jsx)("svg",EV(EB({},Ez(e)),{children:(0,v.jsx)("path",{d:"m6 9 6 6 6-6"})}))},E$=function(e){return(0,v.jsx)("svg",EV(EB({},Ez(e)),{children:(0,v.jsx)("path",{d:"M20 6 9 17l-5-5"})}))},EU=function(e){return(0,v.jsxs)("svg",EV(EB({},Ez(e)),{children:[(0,v.jsx)("path",{d:"m7 15 5 5 5-5"}),(0,v.jsx)("path",{d:"m7 9 5-5 5 5"})]}))},EH=function(e){return(0,v.jsxs)("svg",EV(EB({},Ez(e)),{children:[(0,v.jsx)("circle",{cx:"11",cy:"11",r:"8"}),(0,v.jsx)("path",{d:"m21 21-4.3-4.3"})]}))},EG=function(e){return(0,v.jsxs)("svg",EV(EB({},Ez(e)),{children:[(0,v.jsx)("path",{d:"M18 6 6 18"}),(0,v.jsx)("path",{d:"m6 6 12 12"})]}))},EK=function(e){return(0,v.jsx)("svg",EV(EB({},Ez(e)),{children:(0,v.jsx)("path",{d:"M21 12a9 9 0 1 1-6.219-8.56"})}))};function Eq(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function EY(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Eq(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Eq(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var EX={type:"spring",duration:.5,bounce:.22},EZ="flex w-full items-center justify-between gap-2 px-3.5 py-2.5 text-sm",EQ={hidden:{opacity:0,y:-6,filter:"blur(3px)"},show:{opacity:1,y:0,filter:"blur(0px)"}},EJ=(0,g.createContext)(null);function E0(e){var t=(0,g.useContext)(EJ);if(!t)throw Error("".concat(e," must be used within <MorphSelect>"));return t}function E1(e){var t,r=e.value,n=e.defaultValue,a=e.onValueChange,i=e.open,o=e.defaultOpen,s=e.onOpenChange,l=e.disabled,u=void 0!==l&&l,c=e.transition,d=void 0===c?EX:c,f=e.radius,p=void 0===f?12:f,h=e.stagger,m=void 0===h?.035:h,y=e.staggerDelay,b=void 0===y?.08:y,x=e.className,S=e.children,j=null!=(t=Ed())&&t,O=(0,g.useId)(),k=(0,g.useRef)(null),E=EY((0,g.useState)(void 0!==o&&o),2),P=E[0],A=E[1],D=void 0!==i,C=D?i:P,T=(0,g.useCallback)(function(e){D||A(e),null==s||s(e)},[D,s]),N=EY((0,g.useState)(n),2),R=N[0],M=N[1],I=EY((0,g.useState)(new Map),2),L=I[0],F=I[1],B=EY((0,g.useState)("Select"),2),V=B[0],z=B[1],W=void 0!==r,$=W?r:R,U=(0,g.useCallback)(function(e){W||M(e),null==a||a(e),T(!1)},[W,a,T]),H=(0,g.useCallback)(function(e,t){F(function(r){var n,a,i=new Map(r);return i.set(e,{label:t,count:(null!=(n=null==(a=r.get(e))?void 0:a.count)?n:0)+1}),i})},[]),G=(0,g.useCallback)(function(e){F(function(t){var r=t.get(e);if(!r)return t;var n=new Map(t);return r.count<=1?n.delete(e):n.set(e,{label:r.label,count:r.count-1}),n})},[]);(0,g.useEffect)(function(){if(C){var e=function(e){return"Escape"===e.key&&T(!1)},t=function(e){k.current&&!k.current.contains(e.target)&&T(!1)};return window.addEventListener("keydown",e),window.addEventListener("pointerdown",t),function(){window.removeEventListener("keydown",e),window.removeEventListener("pointerdown",t)}}},[C,T]);var K=(0,g.useMemo)(function(){return{value:$,open:C,setOpen:T,select:U,register:H,unregister:G,labelFor:function(e){var t;return void 0===e||null==(t=L.get(e))?void 0:t.label},placeholder:V,setPlaceholder:z,reduce:j,layoutId:"".concat(O,"-surface"),triggerId:"".concat(O,"-trigger"),listId:"".concat(O,"-list"),disabled:u,transition:d,radius:p,stagger:m,staggerDelay:b}},[$,C,T,U,H,G,L,V,j,O,u,d,p,m,b]);return(0,v.jsx)(EJ.Provider,{value:K,children:(0,v.jsx)("div",{ref:k,className:(0,w.cn)("relative",x),children:S})})}function E2(e){var t,r=e.placeholder,n=e.className,a=E0("MorphSelectValue");(0,g.useEffect)(function(){r&&a.setPlaceholder(r)},[r,a.setPlaceholder]);var i=a.labelFor(a.value);return(0,v.jsx)("span",{className:(0,w.cn)(i?"text-foreground":"text-muted-foreground",n),children:null!=(t=null!=i?i:r)?t:"Select"})}function E3(e){var t,r,n=e.className,a=e.icon,i=e.children,o=E0("MorphSelectTrigger"),s=null!=a?a:(0,v.jsx)(EW,{className:"h-4 w-4"});return(0,v.jsxs)(v.Fragment,{children:[(0,v.jsxs)("div",(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"aria-hidden":!0},{inert:""}),r=r={className:(0,w.cn)(EZ,"invisible rounded-xl border border-border"),children:[i,s]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t)),(0,v.jsx)(jA,{initial:!1,mode:"popLayout",children:o.open?null:(0,v.jsxs)(hz.button,{layoutId:o.layoutId,type:"button",id:o.triggerId,disabled:o.disabled,"aria-haspopup":"listbox","aria-expanded":o.open,"aria-controls":o.listId,onClick:function(){return o.setOpen(!0)},transition:o.reduce?{duration:0}:o.transition,style:{borderRadius:o.radius},className:(0,w.cn)(EZ,"absolute inset-x-0 top-0 z-10 border border-border bg-background text-foreground outline-none transition-colors","hover:border-input focus-visible:ring-2 focus-visible:ring-foreground/20","disabled:pointer-events-none disabled:opacity-50",n),children:[(0,v.jsx)(hz.span,{layout:"position",className:"min-w-0 truncate",children:i}),(0,v.jsx)(hz.span,{layout:"position",className:"text-muted-foreground",children:s})]},"trigger")})]})}function E4(e){var t=e.className,r=e.headerClassName,n=e.listClassName,a=e.icon,i=e.children,o=E0("MorphSelectContent"),s=o.labelFor(o.value),l=(0,g.useMemo)(function(){return{hidden:{},show:{transition:{staggerChildren:o.stagger,delayChildren:o.staggerDelay}}}},[o.stagger,o.staggerDelay]);return(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("div",{className:"hidden",children:i}),(0,v.jsx)(jA,{initial:!1,mode:"popLayout",children:o.open?(0,v.jsxs)(hz.div,{layoutId:o.layoutId,id:o.listId,role:"listbox","aria-labelledby":o.triggerId,transition:o.reduce?{duration:0}:o.transition,style:{borderRadius:o.radius},className:(0,w.cn)("absolute inset-x-0 top-0 z-30 overflow-hidden border border-border bg-background shadow-lg",t),children:[(0,v.jsxs)(hz.button,{type:"button",layout:"position","aria-expanded":!0,onClick:function(){return o.setOpen(!1)},className:(0,w.cn)(EZ,"outline-none",r),children:[(0,v.jsx)("span",{className:(0,w.cn)("min-w-0 truncate",s?"text-foreground":"text-muted-foreground"),children:null!=s?s:o.placeholder}),(0,v.jsx)(hz.span,{animate:{rotate:180},transition:o.reduce?{duration:0}:o.transition,className:"text-muted-foreground",children:null!=a?a:(0,v.jsx)(EW,{className:"h-4 w-4"})})]}),(0,v.jsx)("div",{className:"h-px bg-border"}),(0,v.jsx)(hz.ul,{initial:"hidden",animate:"show",variants:o.reduce?void 0:l,className:(0,w.cn)("p-1",n),children:i})]},"panel"):null})]})}function E5(e){var t=e.value,r=e.disabled,n=e.label,a=e.indicator,i=e.className,o=e.children,s=E0("MorphSelectItem"),l=s.value===t,u=null!=n?n:"string"==typeof o?o:t;return(0,g.useLayoutEffect)(function(){return s.register(t,u),function(){return s.unregister(t)}},[s.register,s.unregister,t,u]),(0,v.jsx)(hz.li,{variants:s.reduce?void 0:EQ,children:(0,v.jsxs)("button",{type:"button",role:"option","aria-selected":l,disabled:void 0!==r&&r,onClick:function(){return s.select(t)},className:(0,w.cn)("flex w-full items-center justify-between gap-2 rounded-lg px-2.5 py-1.5 text-left text-sm outline-none transition-colors",l?"bg-muted text-foreground":"text-muted-foreground hover:bg-muted hover:text-foreground focus-visible:bg-muted","disabled:pointer-events-none disabled:opacity-50",i),children:[o,l?null!=a?a:(0,v.jsx)(E$,{className:"h-3.5 w-3.5 shrink-0"}):null]})})}function E6(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function E8(e){if(Array.isArray(e))return e}function E9(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function E7(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function Pe(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Pt(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function Pr(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function Pn(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function Pa(e,t){return E8(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||Po(e,t)||Pe()}function Pi(e){return E8(e)||E7(e)||Po(e)||Pe()}function Po(e,t){if(e){if("string"==typeof e)return E6(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return E6(e,t)}}var Ps=function(e){var t=e.state;return(0,v.jsx)("svg",{viewBox:"0 0 24 24",className:"w-5 h-5 text-muted-foreground transition-colors group-hover:text-foreground pointer-events-none",children:(0,v.jsx)("path",{d:"x"===t?"M 6 18 L 18 6 M 18 18 L 6 6":"up"===t?"M 6 15 L 12 9 M 18 15 L 12 9":"M 6 9 L 12 15 M 18 9 L 12 15",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",fill:"none",style:{transition:"d 0.4s cubic-bezier(0.4, 0, 0.2, 1)"}})})},Pl=function(e){var t=e.className;return(0,v.jsx)("svg",{viewBox:"0 0 24 24",className:(0,w.cn)("w-4 h-4",t),fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",children:(0,v.jsx)("polyline",{points:"20 6 9 17 4 12"})})},Pu=function(e){var t=e.className;return(0,v.jsxs)("svg",{viewBox:"0 0 24 24",className:(0,w.cn)("w-4 h-4",t),fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,v.jsx)("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),(0,v.jsx)("line",{x1:"5",y1:"12",x2:"19",y2:"12"})]})},Pc=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=Pa(g.useState(!1),2),r=t[0],n=t[1],a=g.useRef(null),i=g.useRef(null),o=g.useRef(null),s=function(t){if(!e&&a.current&&i.current){n(!0),null==(r=o.current)||r.cancel();var r,s=a.current.getBoundingClientRect(),l=Math.max(s.width,s.height),u=Math.max(.35*l,75),c=Math.floor(.2*l),d=Math.sqrt(Math.pow(s.width,2)+Math.pow(s.height,2)),f=Math.min(Math.max(400,1.5*d),1e3),p={x:(s.width-c)/2,y:(s.height-c)/2},h=p;t&&"clientX"in t&&(h={x:t.clientX-s.left-c/2,y:t.clientY-s.top-c/2}),i.current.style.width="".concat(c,"px"),i.current.style.height="".concat(c,"px"),o.current=i.current.animate([{transform:"translate(".concat(h.x,"px, ").concat(h.y,"px) scale(1)")},{transform:"translate(".concat(p.x,"px, ").concat(p.y,"px) scale(").concat((d+10+u)/c,")")}],{duration:f,easing:"cubic-bezier(0.2, 0, 0, 1)",fill:"forwards"})}},l=function(){var e;return(e=function(){var e;return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(t){switch(t.label){case 0:if(!((e=o.current)&&"number"==typeof e.currentTime&&e.currentTime<300))return[3,2];return[4,new Promise(function(t){return setTimeout(t,300-e.currentTime)})];case 1:t.sent(),t.label=2;case 2:return n(!1),[2]}})},function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){E9(i,n,a,o,s,"next",e)}function s(e){E9(i,n,a,o,s,"throw",e)}o(void 0)})})()};return{surfaceRef:a,rippleRef:i,pressed:r,events:{onPointerDown:function(e){0===e.button&&s(e)},onPointerUp:l,onPointerLeave:l,onPointerCancel:l}}},Pd=g.forwardRef(function(e,t){var r=e.pressed,n=e.rippleRef;return(0,v.jsxs)("div",{ref:t,className:"absolute inset-0 overflow-hidden rounded-[inherit] pointer-events-none z-0",children:[(0,v.jsx)("div",{className:"absolute inset-0 bg-current opacity-0 transition-opacity duration-200 group-hover/m3item:opacity-[0.08] group-data-[active=true]:opacity-[0.08]"}),(0,v.jsx)("div",{ref:n,className:"absolute rounded-full opacity-0 bg-current",style:{background:"radial-gradient(closest-side, currentColor max(calc(100% - 70px), 65%), transparent 100%)",transition:"opacity 375ms linear",opacity:r?"0.12":"0",transitionDuration:r?"100ms":"375ms"}})]})});Pd.displayName="RippleLayer";var Pf=g.forwardRef(function(e,t){var r=Pi([e,t]),n=r[0],a=r.slice(1),i=n.children,o=n.className,s=n.viewportRef,l=Pn(n,["children","className","viewportRef"]),u=Pa(a,1)[0],c=g.useRef(null),d=s||c,f=g.useRef(null),p=g.useRef(null),h=Pa(g.useState(0),2),m=h[0],y=h[1],b=Pa(g.useState(0),2),x=b[0],S=b[1],j=Pa(g.useState(!1),2),O=j[0],k=j[1],E=g.useRef({startY:0,startScrollTop:0}),P=g.useCallback(function(){if(d.current){var e=d.current,t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;if(f.current&&(f.current.style.opacity=t>0?"1":"0"),p.current&&(p.current.style.opacity=Math.ceil(t+n)>=r-1?"0":"1"),r>n){var a=Math.max(n/r*n,30);y(a),S((n-a)/(r-n)*t)}else y(0)}},[d]);return g.useEffect(function(){var e=d.current;if(e){P();var t=new ResizeObserver(function(){return P()});t.observe(e),e.firstElementChild&&t.observe(e.firstElementChild);var r=new MutationObserver(function(){return P()});return r.observe(e,{childList:!0,subtree:!0,characterData:!0}),function(){t.disconnect(),r.disconnect()}}},[P,d]),g.useEffect(function(){if(O){var e=function(e){if(d.current){var t=e.clientY-E.current.startY,r=d.current,n=r.scrollHeight,a=r.clientHeight,i=Math.max(a/n*a,30);d.current.scrollTop=E.current.startScrollTop+(n-a)/(a-i)*t}},t=function(){k(!1),document.body.style.userSelect=""};return window.addEventListener("pointermove",e),window.addEventListener("pointerup",t),function(){window.removeEventListener("pointermove",e),window.removeEventListener("pointerup",t)}}},[O,d]),(0,v.jsxs)("div",Pr(Pt({ref:u,"data-dragging":O,className:(0,w.cn)("relative overflow-hidden group/scroll",o)},l),{children:[(0,v.jsx)("div",{ref:f,className:"absolute top-0 left-0 right-0 h-6 bg-gradient-to-b from-card to-transparent pointer-events-none z-20 transition-opacity duration-300 opacity-0"}),(0,v.jsx)("div",{ref:d,onScroll:P,style:{maxHeight:"inherit"},className:"w-full overflow-y-auto m3-hide-scroll rounded-[inherit]",children:i}),(0,v.jsx)("div",{ref:p,className:"absolute bottom-0 left-0 right-0 h-6 bg-gradient-to-t from-card to-transparent pointer-events-none z-20 transition-opacity duration-300 opacity-0"}),m>0&&(0,v.jsx)("div",{className:(0,w.cn)("absolute inset-y-0 right-0 z-50 flex items-start justify-end py-0.5 px-0.5 w-4 transition-opacity duration-300 cursor-default","opacity-0 pointer-events-none","group-hover/scroll:opacity-100 group-hover/scroll:pointer-events-auto","group-data-[dragging=true]/scroll:opacity-100 group-data-[dragging=true]/scroll:pointer-events-auto"),children:(0,v.jsx)("div",{className:(0,w.cn)("bg-border rounded-full transition-all duration-200 cursor-default touch-none shadow-sm","w-1 hover:w-1.5 hover:bg-muted-foreground","group-data-[dragging=true]/scroll:w-1.5 group-data-[dragging=true]/scroll:bg-muted-foreground"),style:{height:m,transform:"translateY(".concat(x,"px)")},onPointerDown:function(e){var t;e.preventDefault(),e.stopPropagation(),k(!0),E.current={startY:e.clientY,startScrollTop:(null==(t=d.current)?void 0:t.scrollTop)||0},document.body.style.userSelect="none"}})})]}))});Pf.displayName="CustomFloatingScrollArea";var Pp=function(){return(0,v.jsx)("style",{dangerouslySetInnerHTML:{__html:'\n @keyframes m3-auto-item-cinematic { \n 0% { opacity: 0; transform: translateY(8px) scale(0.98); filter: blur(4px); } \n 100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); } \n }\n \n @keyframes m3-chip-enter { \n 0% { opacity: 0; transform: scale(0.8) translate3d(8px, 0, 0); } \n 100% { opacity: 1; transform: scale(1) translate3d(0, 0, 0); } \n }\n\n .m3-chip-animate {\n animation: m3-chip-enter 200ms cubic-bezier(0.2, 0.8, 0.2, 1) forwards;\n }\n \n .m3-auto-container[data-state="open"] .m3-auto-item { \n opacity: 0; \n animation: m3-auto-item-cinematic 350ms cubic-bezier(0.1, 0.8, 0.2, 1) forwards; \n }\n\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(1) { animation-delay: 50ms; }\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(2) { animation-delay: 100ms; }\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(3) { animation-delay: 150ms; }\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(4) { animation-delay: 200ms; }\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(n+5) { animation-delay: 250ms; }\n\n .m3-hide-scroll {\n scrollbar-width: none;\n -ms-overflow-style: none;\n }\n .m3-hide-scroll::-webkit-scrollbar {\n display: none;\n }\n '}})},Ph=g.forwardRef(function(e,t){var r=Pi([e,t]),n=r[0],a=r.slice(1),i=n.className,o=n.children,s=n.isActive,l=n.isSelected,u=n.onSelectAction,c=Pn(n,["className","children","isActive","isSelected","onSelectAction"]),d=Pa(a,1)[0],f=Pc(),p=f.surfaceRef,h=f.rippleRef,m=f.pressed,y=f.events;return(0,v.jsxs)("li",Pr(Pt({ref:function(e){p.current=e,"function"==typeof d?d(e):d&&(d.current=e)},role:"option","aria-selected":l,"data-active":s,className:(0,w.cn)("m3-auto-item group/m3item relative flex items-center p-3 px-4 cursor-pointer text-sm outline-none transition-colors overflow-hidden",s&&"bg-secondary/50 text-secondary-foreground",i),onMouseDown:function(e){e.preventDefault()},onClick:function(){setTimeout(function(){return u()},150)}},y,c),{children:[(0,v.jsx)(Pd,{rippleRef:h,pressed:m}),(0,v.jsx)("span",{className:"relative z-10 flex w-full items-center pointer-events-none",children:o})]}))});function Pm(e){var t=e.items,r=e.placeholder,n=e.emptyMessage,a=e.value,i=e.onValueChange,o=e.disabled,s=e.isCreatable,l=e.onCreate,u=e.className,c=e.onInputChange,d=e.loading,f=e.filterFn,p=e.debounceInterval,h=void 0===p?0:p,m=e.name,y=e.id,b=e.required,x=e["aria-label"],S=e["aria-labelledby"],j=e.maxOptions,O=e.minOptions,k=e.classNames,E=e.labels,P=e.renderItem,A=e.maxListHeight,D=void 0===A?260:A,C=e.chipMaxWidth,T=void 0===C?120:C,N=e.style,R=Array.isArray(a),M=null!=(eE=null==E?void 0:E.empty)?eE:void 0===n?"No results found.":n,I=null!=(eP=null==E?void 0:E.loading)?eP:"Loading results...",L=null!=(eA=null==E?void 0:E.clear)?eA:"Clear",F=null!=(eD=null==E?void 0:E.toggle)?eD:"Toggle options",B=null!=(eC=null==E?void 0:E.create)?eC:function(e){return'Create "'.concat(e,'"')},V=g.useId(),z=y?"".concat(y,"-listbox"):"".concat(V,"-listbox"),W=function(e){return"".concat(z,"-option-").concat(e)},$=Pa(g.useState(function(){if(a){var e;return Array.isArray(a)?"":(null==(e=t.find(function(e){return e.value===a}))?void 0:e.label)||""}return""}),2),U=$[0],H=$[1],G=Pa(g.useState(U),2),K=G[0],q=G[1],Y=Pa(g.useState(!1),2),X=Y[0],Z=Y[1],Q=Pa(g.useState("closed"),2),J=Q[0],ee=Q[1],et=Pa(g.useState(-1),2),er=et[0],en=et[1],ea=g.useRef("mouse"),ei=Pa(g.useState("bottom"),2),eo=ei[0],es=ei[1],el=Pa(g.useState(D),2),eu=el[0],ec=el[1],ed=g.useRef(null),ef=g.useRef(null),ep=g.useRef(null),eh=g.useRef(null),em=g.useRef(null),ey=g.useRef(null),ev=g.useRef(null),eg=g.useRef(null),eb=g.useRef(null),ex=Pa(g.useState(a),2),ew=ex[0],eS=ex[1],ej=Pa(g.useState(t),2),eO=ej[0],ek=ej[1];if(a!==ew||t!==eO)if(eS(a),ek(t),R)a&&0!==a.length||(H(""),q(""));else if(a){var eE,eP,eA,eD,eC,eT,eN=(null==(eT=t.find(function(e){return e.value===a}))?void 0:eT.label)||"";H(eN),q(eN)}else H(""),q("");var eR=Pc(o),eM=eR.surfaceRef,eI=eR.rippleRef,e_=eR.pressed,eL=eR.events,eF=Pc(o),eB=eF.surfaceRef,eV=eF.rippleRef,ez=eF.pressed,eW=eF.events,e$=g.useMemo(function(){return!1===f||null===f?t:f?t.filter(function(e){return f(e,K)}):K?t.filter(function(e){return e.label.toLowerCase().includes(K.toLowerCase())}):t},[t,K,f]),eU=Pa(g.useState(e$),2),eH=eU[0],eG=eU[1];g.useEffect(function(){"open"===J&&eG(e$)},[e$,J]);var eK=g.useCallback(function(){if(ef.current){var e=ef.current.getBoundingClientRect(),t=window.innerHeight-e.bottom,r=e.top,n=t<280&&r>t?"top":"bottom";es(n),ec(Math.max(100,Math.min(D,("bottom"===n?t:r)-16)))}},[D]);g.useEffect(function(){var e=ef.current;if(e){var t=new ResizeObserver(function(){eK()});return t.observe(e),e.parentElement&&t.observe(e.parentElement),window.addEventListener("resize",eK),function(){t.disconnect(),window.removeEventListener("resize",eK)}}},[eK]),g.useEffect(function(){if(X)return window.addEventListener("scroll",eK,{capture:!0,passive:!0}),function(){window.removeEventListener("scroll",eK,!0)}},[X,eK]);var eq=g.useCallback(function(e){H(e),eb.current&&clearTimeout(eb.current),h&&h>0?eb.current=setTimeout(function(){q(e),c&&c(e)},h):(q(e),c&&c(e))},[h,c]),eY=g.useCallback(function(e){if(Z(!0),ee("open"),eg.current&&clearTimeout(eg.current),"number"==typeof e)en(e);else{var t=e$.findIndex(function(e){return e.value===a});en(t>=0?t:-1)}},[e$,a]),eX=g.useCallback(function(){if(Z(!1),ee("closing"),en(-1),R)H(""),q("");else if(a){var e,r=(null==(e=t.find(function(e){return e.value===a}))?void 0:e.label)||"";H(r),q(r)}else H(""),q("");eg.current&&clearTimeout(eg.current),eg.current=setTimeout(function(){ee(function(e){return"closing"===e?"closed":e})},300)},[a,t,R]);g.useEffect(function(){return function(){eg.current&&clearTimeout(eg.current),eb.current&&clearTimeout(eb.current)}},[]),g.useEffect(function(){var e=function(e){ef.current&&!ef.current.contains(e.target)&&X&&eX()};return document.addEventListener("mousedown",e),function(){return document.removeEventListener("mousedown",e)}},[X,eX]),g.useEffect(function(){if(er>=0&&ep.current&&"keyboard"===ea.current){var e=ep.current.children[er];e&&e.scrollIntoView({block:"nearest"})}},[er]);var eZ=g.useCallback(function(){var e=em.current;if(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;ey.current&&(ey.current.style.opacity=t>1?"1":"0"),ev.current&&(ev.current.style.opacity=Math.ceil(t+n)>=r-1?"0":"1")}},[]),eQ=g.useRef(0);g.useEffect(function(){if(R){var e=em.current;if(e){var t=(null==a?void 0:a.length)||0;t>eQ.current&&requestAnimationFrame(function(){e.scrollLeft=e.scrollWidth}),eQ.current=t}}},[a,R]),g.useEffect(function(){var e,t,r=em.current;if(r){var n=!1,a=function(a){n=!0,e=a.pageX-r.offsetLeft,t=r.scrollLeft,document.body.style.userSelect="none"},i=function(){n&&(n=!1,document.body.style.userSelect="")},o=function(a){if(n){a.preventDefault();var i=(a.pageX-r.offsetLeft-e)*1.5;r.scrollLeft=t-i}},s=function(e){0!==e.deltaY&&(e.preventDefault(),r.scrollLeft+=e.deltaY)};r.addEventListener("mousedown",a),r.addEventListener("mouseleave",i),r.addEventListener("mouseup",i),r.addEventListener("mousemove",o),r.addEventListener("wheel",s,{passive:!1}),eZ(),r.addEventListener("scroll",eZ);var l=new ResizeObserver(function(){return eZ()});return l.observe(r),function(){r.removeEventListener("mousedown",a),r.removeEventListener("mouseleave",i),r.removeEventListener("mouseup",i),r.removeEventListener("mousemove",o),r.removeEventListener("wheel",s),r.removeEventListener("scroll",eZ),l.disconnect(),document.body.style.userSelect=""}}},[X,a,eZ]);var eJ=void 0!==s&&s&&U.length>0&&!t.some(function(e){return e.label.toLowerCase()===U.toLowerCase()}),e0=function(e){var r;if(R){var n,o,s=a||[];if(s.includes(e)){if("number"==typeof O&&s.length<=O){null==(n=ed.current)||n.focus();return}var l=s.filter(function(t){return t!==e});i&&i(l)}else{if("number"==typeof j&&s.length>=j){null==(o=ed.current)||o.focus();return}var u=((function(e){if(Array.isArray(e))return E6(e)})(s)||E7(s)||Po(s)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e]);i&&i(u)}H(""),q(""),c&&c("")}else{if(a===e)H(""),q(""),i&&i("");else{var d,f=(null==(d=t.find(function(t){return t.value===e}))?void 0:d.label)||"";H(f),q(f),i&&i(e)}eX()}null==(r=ed.current)||r.focus()},e1=function(){var e;l&&U&&l(U),R||eX(),null==(e=ed.current)||e.focus()},e2=U.length>0?"x":X?"up":"down",e3="closing"===J?eH:e$,e4=R&&(a||[]).length>0,e5=g.useCallback(function(e){if(!R)return!1;var t=a||[];return!t.includes(e)&&"number"==typeof j&&!!(t.length>=j)},[R,a,j]),e6=X||"closing"===J;return(0,v.jsxs)("div",{ref:ef,style:N,className:(0,w.cn)("relative w-full transition-all duration-300 ease-[cubic-bezier(0.2,0.8,0.2,1)]",e4?"h-[5.25rem]":"h-11",u,null==k?void 0:k.root),children:[(0,v.jsx)(Pp,{}),m&&(R?(a||[]).length>0?(a||[]).map(function(e){return(0,v.jsx)("input",{type:"hidden",name:m,value:e},e)}):(0,v.jsx)("input",{type:"hidden",name:m,value:"",required:b}):(0,v.jsx)("input",{type:"hidden",name:m,value:a||"",required:b})),(0,v.jsxs)("div",{"data-state":J,className:(0,w.cn)("m3-auto-container absolute inset-x-0 flex bg-card overflow-hidden transition-all duration-300 ease-[cubic-bezier(0.2,0.8,0.2,1)]","top"===eo?"bottom-0 flex-col-reverse":"top-0 flex-col",e6?"z-50 rounded-[1.25rem] border border-border shadow-[0px_16px_32px_rgba(0,0,0,0.14)]":"z-10 rounded-xl border border-input/60 shadow-sm hover:border-input h-full",null==k?void 0:k.container),children:[(0,v.jsxs)("div",{className:(0,w.cn)("relative flex items-center w-full h-11 flex-shrink-0 pl-4 pr-1.5 z-30",null==k?void 0:k.inputRow),children:[(0,v.jsx)("input",{ref:ed,id:y,role:"combobox","aria-expanded":X,"aria-autocomplete":"list","aria-controls":z,"aria-activedescendant":er>=0?W(er):void 0,"aria-label":x,"aria-labelledby":S,value:U,onChange:function(e){var t=e.target.value;eq(t);var r=t.length>0?0:-1;X?en(r):eY(r),ea.current="keyboard"},onFocus:function(){return eY()},onKeyDown:function(e){var t=e$.length+ +!!eJ;if("Tab"===e.key){X&&eX();return}if(!X&&("ArrowDown"===e.key||"ArrowUp"===e.key)){e.preventDefault(),eY();return}if(0!==t)switch(e.key){case"ArrowDown":e.preventDefault(),ea.current="keyboard",en(function(e){return(e+1)%t});break;case"ArrowUp":e.preventDefault(),ea.current="keyboard",en(function(e){return(e-1+t)%t});break;case"Home":e.preventDefault(),ea.current="keyboard",en(0);break;case"End":e.preventDefault(),ea.current="keyboard",en(t-1);break;case"Enter":if(e.preventDefault(),er>=0)if(er<e$.length){var r=e$[er],n=R&&a||[],i=n.includes(r.value);R&&!i&&"number"==typeof j&&n.length>=j||e0(r.value)}else eJ&&e1();break;case"Escape":eX()}},disabled:o,placeholder:r||"Select an option...",autoComplete:"off",className:(0,w.cn)("flex-1 h-full bg-transparent outline-none text-sm placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",null==k?void 0:k.input)}),(0,v.jsxs)("button",Pr(Pt({ref:eM,type:"button",tabIndex:-1,className:(0,w.cn)("p-1.5 rounded-full z-20 hover:bg-muted/50 transition-all relative overflow-hidden h-8 w-8 flex items-center justify-center flex-shrink-0",null==k?void 0:k.toggleButton),onClick:function(e){var t;e.preventDefault(),null==(t=ed.current)||t.focus(),U.length>0?(eq(""),!R&&i&&i(""),X||eY(-1)):X?eX():eY()},disabled:o,"aria-label":F},eL),{children:[(0,v.jsx)(Pd,{rippleRef:eI,pressed:e_}),(0,v.jsx)("span",{className:"relative z-10 flex items-center justify-center pointer-events-none",children:(0,v.jsx)(Ps,{state:e2})})]}))]}),R&&(a||[]).length>0&&(0,v.jsxs)("div",{className:(0,w.cn)("relative flex items-center justify-between h-10 overflow-hidden flex-shrink-0 border-border/40","top"===eo?"border-b":"border-t",null==k?void 0:k.chipsRow),children:[(0,v.jsx)("div",{ref:ey,className:"absolute left-0 top-0 bottom-0 w-8 bg-gradient-to-r from-card to-transparent pointer-events-none z-20 transition-opacity duration-150 opacity-0"}),(0,v.jsx)("div",{ref:em,className:"flex items-center gap-1.5 overflow-x-auto m3-hide-scroll flex-1 min-w-0 h-full py-0.5 pl-4 pr-12 select-none cursor-default",children:(a||[]).map(function(e){var r=t.find(function(t){return t.value===e});return r?(0,v.jsxs)("button",{type:"button",className:(0,w.cn)("m3-chip-animate group/chip relative flex items-center h-6 px-3 bg-secondary text-secondary-foreground text-xs font-medium rounded-full flex-shrink-0 transition-all duration-300 ease-[cubic-bezier(0.2,0.8,0.2,1)] overflow-hidden cursor-default select-none",null==k?void 0:k.chip),onClick:function(){var t,r=a||[];if("number"!=typeof O||!(r.length<=O)){var n=r.filter(function(t){return t!==e});i&&i(n),null==(t=ed.current)||t.focus()}},children:[(0,v.jsx)("span",{className:"truncate",style:{maxWidth:T},children:r.label}),(0,v.jsx)("div",{className:"absolute inset-y-0 right-0 w-8 flex items-center justify-end pr-2 bg-gradient-to-l from-secondary via-secondary/90 to-transparent opacity-0 translate-x-2 group-hover/chip:opacity-100 group-hover/chip:translate-x-0 transition-all duration-150 pointer-events-none",children:(0,v.jsxs)("svg",{viewBox:"0 0 24 24",className:"w-3 h-3 stroke-current text-muted-foreground",fill:"none",strokeWidth:"3.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,v.jsx)("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),(0,v.jsx)("line",{x1:"6",y1:"6",x2:"18",y2:"18"})]})})]},e):null})}),(0,v.jsx)("div",{ref:ev,className:"absolute right-[60px] top-0 bottom-0 w-12 bg-gradient-to-l from-card to-transparent pointer-events-none z-20 transition-opacity duration-150 opacity-0"}),(!O||0===O)&&(0,v.jsxs)("button",Pr(Pt({ref:eB,type:"button",onClick:function(){var e;i&&i([]),null==(e=ed.current)||e.focus()},className:(0,w.cn)("px-3 h-8 rounded-full text-[10px] font-bold uppercase tracking-wider text-muted-foreground hover:bg-muted/50 transition-all relative overflow-hidden flex-shrink-0 flex items-center justify-center mr-1.5 cursor-default z-30",null==k?void 0:k.clearButton)},eW),{children:[(0,v.jsx)(Pd,{rippleRef:eV,pressed:ez}),(0,v.jsx)("span",{className:"relative",children:L})]}))]}),(0,v.jsx)("div",{className:(0,w.cn)("grid transition-[grid-template-rows,opacity] duration-300 ease-[cubic-bezier(0.2,0.8,0.2,1)] relative z-10",X?"grid-rows-[1fr] opacity-100":"grid-rows-[0fr] opacity-0"),onMouseDown:function(e){e.preventDefault()},children:(0,v.jsx)("div",{className:"overflow-hidden",children:"closed"!==J&&(0,v.jsx)("div",{className:"flex flex-col w-full",children:(0,v.jsx)(Pf,{viewportRef:eh,style:{maxHeight:"".concat(eu,"px")},className:"w-full",children:(0,v.jsx)("ul",{ref:ep,id:z,role:"listbox","aria-multiselectable":R,className:(0,w.cn)("w-full text-popover-foreground outline-none pb-2 pt-1",null==k?void 0:k.list),children:void 0!==d&&d?(0,v.jsxs)("li",{className:(0,w.cn)("m3-auto-item p-6 flex flex-col items-center justify-center gap-2 text-xs text-muted-foreground",null==k?void 0:k.loadingState),children:[(0,v.jsxs)("svg",{className:"animate-spin h-5 w-5 text-primary",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[(0,v.jsx)("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"3.5"}),(0,v.jsx)("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]}),(0,v.jsx)("span",{className:"font-medium tracking-wide",children:I})]}):0!==e3.length||eJ?(0,v.jsxs)(v.Fragment,{children:[e3.map(function(e,t){var r=e5(e.value),n=R?!!(null==a?void 0:a.includes(e.value)):a===e.value,i=er===t;return(0,v.jsxs)(Ph,{id:W(t),isActive:i,isSelected:n,onSelectAction:function(){r||e0(e.value)},onMouseMove:function(e){(0!==e.movementX||0!==e.movementY)&&(ea.current="mouse",er!==t&&en(t))},className:(0,w.cn)(r&&"opacity-40 cursor-not-allowed pointer-events-none",null==k?void 0:k.item),children:[n&&(0,v.jsx)(Pl,{className:"mr-3 flex-shrink-0 text-primary"}),P?P(e,{isActive:i,isSelected:n,isDisabled:r}):(0,v.jsxs)("div",{className:"flex flex-col w-full",children:[(0,v.jsx)("span",{className:"whitespace-normal break-words font-medium",children:e.label}),(e.description||e.tag)&&(0,v.jsxs)("div",{className:"flex justify-between items-center text-[11px] font-medium text-muted-foreground/70 w-full mt-0.5 gap-4",children:[(0,v.jsx)("span",{className:"truncate uppercase tracking-wider",children:e.description}),(0,v.jsx)("span",{className:"truncate",children:e.tag})]})]})]},e.value)}),eJ&&(0,v.jsxs)(Ph,{id:W(e$.length),isActive:er===e$.length,isSelected:!1,onSelectAction:e1,onMouseMove:function(e){(0!==e.movementX||0!==e.movementY)&&(ea.current="mouse",er!==e$.length&&en(e$.length))},className:(0,w.cn)("text-primary/90 font-medium border-t border-border/40",null==k?void 0:k.item),children:[(0,v.jsx)(Pu,{className:"mr-3 flex-shrink-0"}),(0,v.jsx)("span",{children:B(U)})]})]}):(0,v.jsx)("li",{className:(0,w.cn)("m3-auto-item p-4 px-4 text-sm text-center text-muted-foreground",null==k?void 0:k.emptyState),children:M})})})})})})]})]})}function Py(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Pv(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||Pb(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Pg(e){return function(e){if(Array.isArray(e))return Py(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Pb(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Pb(e,t){if(e){if("string"==typeof e)return Py(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Py(e,t)}}Ph.displayName="M3AutocompleteItem";var Px=function(e,t){var r,n=t.trim().toLowerCase();return!n||[e.label,e.value,e.description].concat(Pg(null!=(r=e.keywords)?r:[])).filter(Boolean).some(function(e){return String(e).toLowerCase().includes(n)})};function Pw(e){var t,r,n=e.items,a=e.value,i=e.defaultValue,o=e.onValueChange,s=e.open,l=e.defaultOpen,u=e.onOpenChange,c=e.disabled,d=e.placeholder,f=e.searchPlaceholder,p=e.emptyMessage,h=e.searchable,m=e.allowDeselect,y=void 0===m||m,b=e.closeOnSelect,x=void 0===b||b,S=e.filterFn,j=e.onSearchChange,O=e.side,k=void 0===O?"auto":O,E=e.align,P=void 0===E?"center":E,A=e.sideOffset,D=void 0===A?4:A,C=e.renderItem,T=e.renderValue,N=e.triggerIcon,R=e.checkIcon,M=e.name,I=e.id,L=e["aria-label"],F=e.classNames,B=e.className,V=e.style,z=g.useId(),W="".concat(z,"-listbox"),$=function(e){return"".concat(z,"-option-").concat(e)},U=void 0!==a,H=Pv(g.useState(void 0===i?"":i),2),G=H[0],K=H[1],q=U?a:G,Y=void 0!==s,X=Pv(g.useState(void 0!==l&&l),2),Z=X[0],Q=X[1],J=Y?s:Z,ee=g.useCallback(function(e){Y||Q(e),null==u||u(e)},[Y,u]),et=Pv(g.useState(""),2),er=et[0],en=et[1],ea=Pv(g.useState(0),2),ei=ea[0],eo=ea[1],es=Pv(g.useState("bottom"),2),el=es[0],eu=es[1],ec=g.useRef("mouse"),ed=g.useRef(null),ef=g.useRef(null),ep=g.useRef(null),eh=g.useRef(null),em=g.useMemo(function(){return n.find(function(e){return e.value===q})},[n,q]),ey=g.useMemo(function(){if(!1===S)return n;var e=null!=S?S:Px;return n.filter(function(t){return e(t,er)})},[n,er,S]),ev=g.useCallback(function(e){var t,r=y&&e===q?"":e;U||K(r),null==o||o(r),x&&(ee(!1),null==(t=ef.current)||t.focus())},[y,q,U,o,x,ee]);g.useEffect(function(){if(!J)return void en("");var e=ey.findIndex(function(e){return e.value===q&&!e.disabled});eo(e>=0?e:Math.max(0,ey.findIndex(function(e){return!e.disabled})));var t=requestAnimationFrame(function(){var e;return null==(e=ep.current)?void 0:e.focus()});return function(){return cancelAnimationFrame(t)}},[J]),g.useLayoutEffect(function(){if(J&&ed.current){if("auto"!==k)return void eu(k);var e=ed.current.getBoundingClientRect(),t=window.innerHeight-e.bottom,r=e.top;eu(t<340&&r>t?"top":"bottom")}},[J,k]),g.useEffect(function(){if(J){var e=function(e){ed.current&&!ed.current.contains(e.target)&&ee(!1)};return document.addEventListener("mousedown",e),function(){return document.removeEventListener("mousedown",e)}}},[J,ee]),g.useEffect(function(){J&&eo(Math.max(0,ey.findIndex(function(e){return!e.disabled})))},[er]),g.useEffect(function(){var e,t;J&&"keyboard"===ec.current&&(null==(t=eh.current)||null==(e=t.querySelector('[data-index="'.concat(ei,'"]')))||e.scrollIntoView({block:"nearest"}))},[ei,J]);var eg=function(e,t){var r=ey.length;if(0===r)return -1;for(var n=t,a=0;a<r;a++)if(!ey[n=(n+e+r)%r].disabled)return n;return t},eb=(0,w.cn)("bottom"===el?"top-full":"bottom-full","start"===P&&"left-0","center"===P&&"left-1/2","end"===P&&"right-0"),ex=(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},"bottom"===el?{marginTop:D}:{marginBottom:D}),r=r={"--egen-combobox-to":"center"===P?"translateX(-50%)":"translateX(0)","--egen-combobox-from-bottom":"".concat("center"===P?"translateX(-50%) ":"","translateY(-8px)"),"--egen-combobox-from-top":"".concat("center"===P?"translateX(-50%) ":"","translateY(8px)"),transform:"center"===P?"translateX(-50%)":"none"},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t),ew=[];ey.forEach(function(e,t){var r=ew[ew.length-1];r&&r.heading===e.group?r.entries.push({item:e,index:t}):ew.push({heading:e.group,entries:[{item:e,index:t}]})});var eS=function(e){var t=e.item,r=e.index,n=q===t.value,a=ei===r;return(0,v.jsxs)("div",{id:$(r),role:"option","data-index":r,"data-selected":a,"data-disabled":t.disabled?"true":void 0,"aria-selected":n,"aria-disabled":t.disabled||void 0,onMouseMove:function(){t.disabled||(ec.current="mouse",ei!==r&&eo(r))},onClick:function(){return!t.disabled&&ev(t.value)},className:(0,w.cn)("relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none","data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50","data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground","[&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",null==F?void 0:F.item),children:[C?C(t,{isActive:a,isSelected:n}):(0,v.jsxs)(v.Fragment,{children:[t.icon,t.description?(0,v.jsxs)("span",{className:"flex min-w-0 flex-col",children:[(0,v.jsx)("span",{className:"truncate",children:t.label}),(0,v.jsx)("span",{className:"truncate text-xs text-muted-foreground",children:t.description})]}):t.label]}),R&&n?(0,v.jsx)("span",{className:(0,w.cn)("ml-auto",null==F?void 0:F.itemCheck),children:R}):(0,v.jsx)(E$,{className:(0,w.cn)("ml-auto",n?"opacity-100":"opacity-0",null==F?void 0:F.itemCheck)})]},t.value)};return(0,v.jsxs)("div",{ref:ed,style:V,className:(0,w.cn)("relative w-full max-w-xs",B,null==F?void 0:F.root),children:[(0,v.jsx)("style",{dangerouslySetInnerHTML:{__html:'\n@keyframes egen-combobox-in-bottom { from { opacity: 0; transform: var(--egen-combobox-from-bottom) scale(0.95); } to { opacity: 1; transform: var(--egen-combobox-to) scale(1); } }\n@keyframes egen-combobox-in-top { from { opacity: 0; transform: var(--egen-combobox-from-top) scale(0.95); } to { opacity: 1; transform: var(--egen-combobox-to) scale(1); } }\n.egen-combobox-content[data-side="bottom"] { animation: egen-combobox-in-bottom 150ms cubic-bezier(0.16, 1, 0.3, 1); }\n.egen-combobox-content[data-side="top"] { animation: egen-combobox-in-top 150ms cubic-bezier(0.16, 1, 0.3, 1); }\n@media (prefers-reduced-motion: reduce) { .egen-combobox-content { animation: none !important; } }\n'}}),M?(0,v.jsx)("input",{type:"hidden",name:M,value:q}):null,(0,v.jsxs)("button",{ref:ef,id:I,type:"button",role:"combobox","aria-expanded":J,"aria-haspopup":"listbox","aria-controls":J?W:void 0,"aria-label":L,disabled:void 0!==c&&c,onClick:function(){return ee(!J)},onKeyDown:function(e){J||"ArrowDown"!==e.key&&"ArrowUp"!==e.key||(e.preventDefault(),ee(!0))},className:(0,w.cn)("inline-flex h-9 w-full shrink-0 items-center justify-between gap-2 rounded-md border border-border bg-background px-4 py-2 text-sm font-medium whitespace-nowrap text-foreground shadow-xs transition-all outline-none","hover:bg-accent hover:text-accent-foreground","focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50","disabled:pointer-events-none disabled:opacity-50",null==F?void 0:F.trigger),children:[(0,v.jsx)("span",{className:"min-w-0 truncate",children:T?T(em):em?em.label:void 0===d?"Select...":d}),null!=N?N:(0,v.jsx)(EU,{className:"size-4 shrink-0 opacity-50"})]}),J?(0,v.jsx)("div",{"data-side":el,"data-state":"open",style:ex,className:(0,w.cn)("egen-combobox-content absolute z-50 w-72 rounded-md border border-border bg-popover p-0 text-popover-foreground shadow-md outline-hidden",eb,null==F?void 0:F.content),onKeyDown:function(e){if("Escape"===e.key){var t;e.preventDefault(),ee(!1),null==(t=ef.current)||t.focus();return}if("Tab"===e.key)return void ee(!1);if(0!==ey.length)switch(e.key){case"ArrowDown":e.preventDefault(),ec.current="keyboard",eo(function(e){return eg(1,e)});break;case"ArrowUp":e.preventDefault(),ec.current="keyboard",eo(function(e){return eg(-1,e)});break;case"Home":e.preventDefault(),ec.current="keyboard",eo(Math.max(0,ey.findIndex(function(e){return!e.disabled})));break;case"End":e.preventDefault(),ec.current="keyboard";var r=Pg(ey).reverse().findIndex(function(e){return!e.disabled});eo(r>=0?ey.length-1-r:0);break;case"Enter":e.preventDefault();var n=ey[ei];n&&!n.disabled&&ev(n.value)}},children:(0,v.jsxs)("div",{className:"flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",children:[void 0===h||h?(0,v.jsxs)("div",{className:(0,w.cn)("flex h-9 items-center gap-2 border-b border-border px-3",null==F?void 0:F.searchWrapper),children:[(0,v.jsx)(EH,{className:(0,w.cn)("size-4 shrink-0 opacity-50",null==F?void 0:F.searchIcon)}),(0,v.jsx)("input",{ref:ep,type:"text",role:"searchbox",autoComplete:"off",spellCheck:!1,"aria-controls":W,"aria-activedescendant":ey.length?$(ei):void 0,placeholder:void 0===f?"Search...":f,value:er,onChange:function(e){en(e.target.value),ec.current="keyboard",null==j||j(e.target.value)},className:(0,w.cn)("flex h-9 w-full rounded-md bg-transparent py-3 text-sm outline-hidden placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",null==F?void 0:F.searchInput)})]}):(0,v.jsx)("input",{ref:ep,readOnly:!0,"aria-label":L,"aria-controls":W,"aria-activedescendant":ey.length?$(ei):void 0,className:"sr-only"}),(0,v.jsx)("div",{ref:eh,id:W,role:"listbox",className:(0,w.cn)("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",null==F?void 0:F.list),children:0===ey.length?(0,v.jsx)("div",{className:(0,w.cn)("py-6 text-center text-sm",null==F?void 0:F.empty),children:void 0===p?"No results found.":p}):ew.map(function(e,t){var r;return(0,v.jsxs)("div",{role:"group","aria-label":e.heading,className:(0,w.cn)("overflow-hidden p-1 text-foreground",null==F?void 0:F.group),children:[e.heading?(0,v.jsx)("div",{className:(0,w.cn)("px-2 py-1.5 text-xs font-medium text-muted-foreground",null==F?void 0:F.groupHeading),children:e.heading}):null,e.entries.map(eS)]},"".concat(null!=(r=e.heading)?r:"_","-").concat(t))})})]})}):null]})}function PS(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Pj(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function PO(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function Pk(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function PE(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||PA(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function PP(e){return function(e){if(Array.isArray(e))return Pj(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||PA(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function PA(e,t){if(e){if("string"==typeof e)return Pj(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Pj(e,t)}}var PD=function(e){return void 0===e||""===e?[]:Array.isArray(e)?e:[e]},PC=function(e){var t;return Array.isArray(e)?{items:e,hasMore:!1}:{items:null!=(t=e.items)?t:[],hasMore:!!e.hasMore}},PT=function(e){return"number"==typeof e?"".concat(e,"px"):e};function PN(e){var t,r,n,a,i,o,s,l,u,c,d=e.fetcher,f=e.getOptionValue,p=e.getOptionLabel,h=e.renderOption,m=e.getDisplayValue,y=e.getOptionGroup,b=e.getOptionDisabled,x=e.preload,S=void 0!==x&&x,j=e.filterFn,O=e.debounceMs,k=e.minQueryLength,E=void 0===k?0:k,P=e.fetchOnOpen,A=e.cacheResults,D=void 0===A||A,C=e.reloadKey,T=e.initialOptions,N=e.resolveOption,R=e.open,M=e.defaultOpen,I=e.onOpenChange,L=e.disabled,F=void 0!==L&&L,B=e.name,V=e.id,z=e["aria-label"],W=e.label,$=e.placeholder,U=void 0===$?"Select...":$,H=e.searchPlaceholder,G=e.noResultsMessage,K=e.minQueryMessage,q=e.loadingMessage,Y=e.retryLabel,X=e.clearLabel,Z=e.removeLabel,Q=void 0===Z?function(e){return"Remove ".concat(e)}:Z,J=e.errorMessage,ee=void 0===J?"Failed to fetch options":J,et=e.loadMoreErrorLabel,er=e.searchable,en=e.clearable,ea=void 0===en||en,ei=e.showClearButton,eo=e.closeOnSelect,es=e.width,el=e.contentWidth,eu=void 0===el?"trigger":el,ec=e.side,ed=void 0===ec?"auto":ec,ef=e.align,ep=void 0===ef?"start":ef,eh=e.sideOffset,em=void 0===eh?4:eh,ey=e.maxListHeight,ev=void 0===ey?300:ey,eg=e.loadingSkeleton,eb=e.loadingIndicator,ex=e.notFound,ew=e.renderError,eS=e.header,ej=e.footer,eO=e.triggerIcon,ek=e.checkIcon,eE=e.controllerRef,eP=e.classNames,eA=e.className,eD=e.triggerClassName,eC=e.style,eT=!0===e.multiple,eN=!0===e.multiple?e.maxSelected:void 0,eR=!0===e.multiple&&null!=(u=e.maxVisibleTags)?u:3,eM=!0===e.multiple?e.renderTag:void 0,eI=null!=eo?eo:!eT,e_=g.useId(),eL="".concat(e_,"-listbox"),eF=function(e){return"".concat(e_,"-option-").concat(e)},eB=g.useCallback(function(e){return p?p(e):f(e)},[p,f]),eV=void 0!==e.value,ez=PE(g.useState(function(){return PD(e.defaultValue)}),2),eW=ez[0],e$=ez[1],eU=eV?PD(e.value):eW,eH=void 0!==R,eG=PE(g.useState(void 0!==M&&M),2),eK=eG[0],eq=eG[1],eY=eH?R:eK,eX=g.useCallback(function(e){eH||eq(e),null==I||I(e)},[eH,I]),eZ=g.useRef(new Map),eQ=g.useRef(new Set),eJ=PE(g.useReducer(function(e){return e+1},0),2)[1];g.useMemo(function(){null==T||T.forEach(function(e){return eZ.current.set(f(e),e)})},[T]);var e0=g.useRef(N);e0.current=N;var e1=eU.join("\0");g.useEffect(function(){var e=e0.current;if(e){var t=!1;return eU.forEach(function(r){eZ.current.has(r)||eQ.current.has(r)||(eQ.current.add(r),Promise.resolve(e(r)).then(function(e){t||void 0===e||(eZ.current.set(r,e),eJ())}).catch(function(){}))}),function(){t=!0}}},[e1]);var e2=PE(g.useState(""),2),e3=e2[0],e4=e2[1],e5=(t=S?"":e3,r=S?0:void 0===O?300:O,i=(a=function(e){if(Array.isArray(e))return e}(n=g.useState(t))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(n)||function(e){if(e){if("string"==typeof e)return PS(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return PS(e,2)}}(n)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0],o=a[1],g.useEffect(function(){if(!(r<=0)){var e=setTimeout(function(){return o(t)},r);return function(){return clearTimeout(e)}}},[t,r]),r<=0?t:i),e6=e5.trim(),e8=!S&&e6.length>0&&e6.length<E,e9=PE(g.useState([]),2),e7=e9[0],te=e9[1],tt=PE(g.useState("idle"),2),tr=tt[0],tn=tt[1],ta=PE(g.useState(null),2),ti=ta[0],to=ta[1],ts=PE(g.useState(!1),2),tl=ts[0],tu=ts[1],tc=PE(g.useState(!1),2),td=tc[0],tf=tc[1],tp=PE(g.useState(!1),2),th=tp[0],tm=tp[1],ty=PE(g.useState(0),2),tv=ty[0],tg=ty[1],tb=g.useRef(d);tb.current=d;var tx=g.useRef(f);tx.current=f;var tw=g.useRef(new Map),tS=g.useRef(0),tj=g.useRef(0),tO=g.useRef(null),tk=(eY||!(void 0===P||P))&&!e8,tE="".concat(null!=C?C:"","\0").concat(tv,"\0").concat(""===e6?"":e5),tP=g.useCallback(function(e){e.forEach(function(e){return eZ.current.set(tx.current(e),e)})},[]);g.useEffect(function(){if(tk){var e,t=D?tw.current.get(tE):void 0;if(t){te(t.items),tu(t.hasMore),tm(!1),tj.current=t.page,to(null),tn("ready");return}null==(e=tO.current)||e.abort();var r=new AbortController,n=++tS.current;return tn("loading"),to(null),tm(!1),Promise.resolve().then(function(){return tb.current(""===e6?"":e5,{signal:r.signal,page:0})}).then(function(e){if(!r.signal.aborted&&n===tS.current){var t=PC(e);tP(t.items),D&&tw.current.set(tE,{items:t.items,hasMore:t.hasMore,page:0}),tj.current=0,te(t.items),tu(t.hasMore),tn("ready"),eJ()}}).catch(function(e){if(!r.signal.aborted&&n===tS.current){var t;to((null!=(t=Error)&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t)&&e.message?e.message:ee),tn("error")}}),function(){return r.abort()}}},[tk,tE,D]);var tA=g.useCallback(function(){tw.current.delete(tE),tg(function(e){return e+1})},[tE]),tD=g.useCallback(function(){var e;return(e=function(){var e,t,r,n,a;return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(i){switch(i.label){case 0:if("ready"!==tr||!tl||td)return[2];e=tS.current,t=tj.current+1,tO.current=r=new AbortController,tf(!0),tm(!1),i.label=1;case 1:return i.trys.push([1,3,4,5]),[4,tb.current(""===e6?"":e5,{signal:r.signal,page:t})];case 2:if(n=i.sent(),r.signal.aborted||e!==tS.current)return[2];return tP((a=PC(n)).items),te(function(e){var r=new Set(e.map(function(e){return tx.current(e)})),n=PP(e).concat(PP(a.items.filter(function(e){return!r.has(tx.current(e))})));return D&&tw.current.set(tE,{items:n,hasMore:a.hasMore,page:t}),n}),tj.current=t,tu(a.hasMore),[3,5];case 3:return i.sent(),r.signal.aborted||e!==tS.current||tm(!0),[3,5];case 4:return tO.current===r&&(tO.current=null,tf(!1)),[7];case 5:return[2]}})},function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){PO(i,n,a,o,s,"next",e)}function s(e){PO(i,n,a,o,s,"throw",e)}o(void 0)})})()},[tr,tl,td,e6,e5,tP,D,tE]);g.useEffect(function(){return function(){var e;tS.current+=1,null==(e=tO.current)||e.abort()}},[]);var tC=g.useMemo(function(){return!1===j?null:j||(S?function(e,t){var r=t.trim().toLowerCase();return!r||eB(e).toLowerCase().includes(r)}:null)},[j,S,eB]),tT=g.useMemo(function(){return tC&&e3?e7.filter(function(e){return tC(e,e3)}):e7},[e7,tC,e3]),tN=eU.map(function(e){return eZ.current.get(e)}),tR=eT&&void 0!==eN&&eU.length>=eN,tM=function(e){return!!(null==b?void 0:b(e))||tR&&!eU.includes(f(e))},tI=function(t){var r,n,a;eV||e$(t),!0===e.multiple?null==(r=e.onChange)||r.call(e,t,t.map(function(e){return eZ.current.get(e)}).filter(function(e){return void 0!==e})):null==(a=e.onChange)||a.call(e,null!=(n=t[0])?n:"",void 0!==t[0]?eZ.current.get(t[0]):void 0)},t_=g.useRef(null),tL=g.useRef(null),tF=g.useRef(null),tB=g.useRef(null),tV=g.useRef(null),tz=function(e){var t,r=f(e);if(eZ.current.set(r,e),eT){var n=eU.includes(r);if(!n&&tR)return;tI(n?eU.filter(function(e){return e!==r}):PP(eU).concat([r]))}else tI(ea&&eU[0]===r?[]:[r]);eI&&(eX(!1),null==(t=t_.current)||t.focus())},tW=function(e){return tI(eU.filter(function(t){return t!==e}))},t$=function(){return tI([])};g.useImperativeHandle(eE,function(){return{open:function(){return!F&&eX(!0)},close:function(){return eX(!1)},focus:function(){var e;return null==(e=t_.current)?void 0:e.focus()},clear:t$,refresh:function(){tw.current.clear(),tg(function(e){return e+1})}}},[F,eX,eU,eV]);var tU=PE(g.useState(0),2),tH=tU[0],tG=tU[1],tK=PE(g.useState("bottom"),2),tq=tK[0],tY=tK[1],tX=g.useRef("mouse"),tZ=function(){return Math.max(0,tT.findIndex(function(e){return!tM(e)}))};g.useEffect(function(){if(!eY)return void e4("");var e=requestAnimationFrame(function(){var e;return null==(e=tF.current)?void 0:e.focus()});return function(){return cancelAnimationFrame(e)}},[eY]),g.useEffect(function(){if(eY){var e=eT||void 0===eU[0]?-1:tT.findIndex(function(e){return f(e)===eU[0]&&!tM(e)});tG(e>=0?e:tZ())}},[eY,e3,tr]),g.useLayoutEffect(function(){if(eY&&tL.current){if("auto"!==ed)return void tY(ed);var e=tL.current.getBoundingClientRect(),t=window.innerHeight-e.bottom,r=e.top;tY(t<Math.min(ev,300)+48&&r>t?"top":"bottom")}},[eY,ed,ev]),g.useEffect(function(){if(eY){var e=function(e){tL.current&&!tL.current.contains(e.target)&&eX(!1)};return document.addEventListener("mousedown",e),function(){return document.removeEventListener("mousedown",e)}}},[eY,eX]),g.useEffect(function(){var e,t,r;eY&&"keyboard"===tX.current&&(null==(r=tB.current)||null==(t=r.querySelector('[data-index="'.concat(tH,'"]')))||null==(e=t.scrollIntoView)||e.call(t,{block:"nearest"}))},[tH,eY]),g.useEffect(function(){if(!(!eY||!tl||"ready"!==tr||th||"u"<typeof IntersectionObserver)){var e=tV.current;if(e){var t=new IntersectionObserver(function(e){e.some(function(e){return e.isIntersecting})&&tD()},{root:tB.current,rootMargin:"48px"});return t.observe(e),function(){return t.disconnect()}}}},[eY,tl,tr,th,tD,tT.length]);var tQ=function(e,t){var r=tT.length;if(0===r)return -1;for(var n=t,a=0;a<r;a++)if(!tM(tT[n=(n+e+r)%r]))return n;return t},tJ=(0,w.cn)("bottom"===tq?"top-full":"bottom-full","start"===ep&&"left-0","center"===ep&&"left-1/2","end"===ep&&"right-0"),t0=(s=Pk({width:"trigger"===eu?"100%":PT(eu)},"bottom"===tq?{marginTop:em}:{marginBottom:em}),l=l={"--egen-async-select-to":"center"===ep?"translateX(-50%)":"translateX(0)","--egen-async-select-from-bottom":"".concat("center"===ep?"translateX(-50%) ":"","translateY(-8px)"),"--egen-async-select-from-top":"".concat("center"===ep?"translateX(-50%) ":"","translateY(8px)"),transform:"center"===ep?"translateX(-50%)":"none"},Object.getOwnPropertyDescriptors?Object.defineProperties(s,Object.getOwnPropertyDescriptors(l)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(l)).forEach(function(e){Object.defineProperty(s,e,Object.getOwnPropertyDescriptor(l,e))}),s),t1=[];tT.forEach(function(e,t){var r=null==y?void 0:y(e),n=t1[t1.length-1];n&&n.heading===r?n.entries.push({item:e,index:t}):t1.push({heading:r,entries:[{item:e,index:t}]})});var t2=function(e){var t=e.item,r=e.index,n=f(t),a=eU.includes(n),i=tH===r,o=tM(t);return(0,v.jsxs)("div",{id:eF(r),role:"option","data-index":r,"data-selected":i,"data-disabled":o?"true":void 0,"aria-selected":a,"aria-disabled":o||void 0,onMouseMove:function(){o||(tX.current="mouse",tH!==r&&tG(r))},onClick:function(){return!o&&tz(t)},className:(0,w.cn)("relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none","data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50","data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground","[&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",null==eP?void 0:eP.item),children:[h?h(t,{isActive:i,isSelected:a,isDisabled:o}):eB(t),ek&&a?(0,v.jsx)("span",{className:(0,w.cn)("ml-auto",null==eP?void 0:eP.itemCheck),children:ek}):(0,v.jsx)(E$,{className:(0,w.cn)("ml-auto size-3",a?"opacity-100":"opacity-0",null==eP?void 0:eP.itemCheck)})]},n)},t3=function(e,t){return void 0!==t?eB(t):e},t4=eU.length>0,t5=null!=H?H:"Search ".concat(W.toLowerCase(),"..."),t6=null!=G?G:"No ".concat(W.toLowerCase()," found."),t8="loading"===tr;return(0,v.jsxs)("div",{ref:tL,style:Pk({width:PT(void 0===es?"200px":es)},eC),className:(0,w.cn)("relative",eA,null==eP?void 0:eP.root),children:[(0,v.jsx)("style",{dangerouslySetInnerHTML:{__html:'\n@keyframes egen-async-select-in-bottom { from { opacity: 0; transform: var(--egen-async-select-from-bottom) scale(0.95); } to { opacity: 1; transform: var(--egen-async-select-to) scale(1); } }\n@keyframes egen-async-select-in-top { from { opacity: 0; transform: var(--egen-async-select-from-top) scale(0.95); } to { opacity: 1; transform: var(--egen-async-select-to) scale(1); } }\n.egen-async-select-content[data-side="bottom"] { animation: egen-async-select-in-bottom 150ms cubic-bezier(0.16, 1, 0.3, 1); }\n.egen-async-select-content[data-side="top"] { animation: egen-async-select-in-top 150ms cubic-bezier(0.16, 1, 0.3, 1); }\n@media (prefers-reduced-motion: reduce) { .egen-async-select-content { animation: none !important; } }\n'}}),B?eT?eU.map(function(e){return(0,v.jsx)("input",{type:"hidden",name:B,value:e},e)}):(0,v.jsx)("input",{type:"hidden",name:B,value:null!=(c=eU[0])?c:""}):null,(0,v.jsx)("span",{role:"status","aria-live":"polite",className:"sr-only",children:t8?void 0===q?"Loading...":q:""}),(0,v.jsxs)("div",{ref:t_,id:V,role:"combobox",tabIndex:F?-1:0,"aria-expanded":eY,"aria-haspopup":"listbox","aria-controls":eY?eL:void 0,"aria-label":null!=z?z:W,"aria-disabled":F||void 0,"aria-busy":t8||void 0,"data-disabled":F?"true":void 0,"data-state":eY?"open":"closed",onClick:function(){return!F&&eX(!eY)},onKeyDown:function(e){!F&&(eY||"ArrowDown"!==e.key&&"ArrowUp"!==e.key&&"Enter"!==e.key&&" "!==e.key?!eY&&eT&&"Backspace"===e.key&&t4&&tW(eU[eU.length-1]):(e.preventDefault(),eX(!0)))},className:(0,w.cn)("flex min-h-9 w-full shrink-0 cursor-pointer items-center justify-between gap-2 rounded-md border border-border bg-background px-3 py-1.5 text-sm font-medium text-foreground shadow-xs transition-all outline-none","hover:bg-accent hover:text-accent-foreground","focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50","data-[disabled=true]:pointer-events-none data-[disabled=true]:cursor-not-allowed data-[disabled=true]:opacity-50",eD,null==eP?void 0:eP.trigger),children:[(0,v.jsx)("span",{className:(0,w.cn)("flex min-w-0 flex-1 items-center",null==eP?void 0:eP.triggerValue),children:function(){if(!t4)return(0,v.jsx)("span",{className:(0,w.cn)("truncate text-muted-foreground",null==eP?void 0:eP.placeholder),children:U});if(!eT){var e=tN[0];return(0,v.jsx)("span",{className:"min-w-0 truncate",children:void 0!==e?m?m(e):eB(e):eU[0]})}var t=eU.slice(0,Math.max(0,eR)),r=eU.slice(t.length);return(0,v.jsxs)("span",{className:"flex min-w-0 flex-wrap items-center gap-1",children:[t.map(function(e){var t=eZ.current.get(e),r=t3(e,t);return(0,v.jsxs)("span",{className:(0,w.cn)("inline-flex max-w-full items-center gap-1 rounded-sm bg-muted px-1.5 py-0.5 text-xs font-medium text-foreground",null==eP?void 0:eP.tag),children:[(0,v.jsx)("span",{className:"truncate",children:eM?eM(t,e):r}),F?null:(0,v.jsx)("button",{type:"button",tabIndex:-1,"aria-label":Q(r),onMouseDown:function(e){return e.preventDefault()},onClick:function(t){t.stopPropagation(),tW(e)},className:(0,w.cn)("rounded-sm opacity-60 outline-none transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-ring/50",null==eP?void 0:eP.tagRemove),children:(0,v.jsx)(EG,{className:"size-3"})})]},e)}),r.length>0?(0,v.jsxs)("span",{title:r.map(function(e){return t3(e,eZ.current.get(e))}).join(", "),className:(0,w.cn)("rounded-sm bg-muted px-1.5 py-0.5 text-xs font-medium text-muted-foreground",null==eP?void 0:eP.tag),children:["+",r.length]}):null]})}()}),void 0!==ei&&ei&&t4&&!F?(0,v.jsx)("button",{type:"button",tabIndex:-1,"aria-label":void 0===X?"Clear":X,onMouseDown:function(e){return e.preventDefault()},onClick:function(e){e.stopPropagation(),t$()},className:(0,w.cn)("shrink-0 rounded-sm opacity-50 outline-none transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-ring/50",null==eP?void 0:eP.clearButton),children:(0,v.jsx)(EG,{className:"size-4"})}):null,null!=eO?eO:(0,v.jsx)(EU,{className:(0,w.cn)("size-3 shrink-0 opacity-50",null==eP?void 0:eP.triggerIcon)})]}),eY?(0,v.jsx)("div",{"data-side":tq,"data-state":"open",style:t0,className:(0,w.cn)("egen-async-select-content absolute z-50 rounded-md border border-border bg-popover p-0 text-popover-foreground shadow-md outline-hidden",tJ,null==eP?void 0:eP.content),onKeyDown:function(e){if("Escape"===e.key){var t;e.preventDefault(),eX(!1),null==(t=t_.current)||t.focus();return}if("Tab"===e.key)return void eX(!1);if("Backspace"===e.key&&eT&&""===e3&&eU.length>0)return void tW(eU[eU.length-1]);if(0!==tT.length)switch(e.key){case"ArrowDown":e.preventDefault(),tX.current="keyboard",tG(function(e){return tQ(1,e)});break;case"ArrowUp":e.preventDefault(),tX.current="keyboard",tG(function(e){return tQ(-1,e)});break;case"Home":e.preventDefault(),tX.current="keyboard",tG(tZ());break;case"End":e.preventDefault(),tX.current="keyboard";var r=PP(tT).reverse().findIndex(function(e){return!tM(e)});tG(r>=0?tT.length-1-r:0);break;case"Enter":e.preventDefault();var n=tT[tH];n&&!tM(n)&&tz(n)}},children:(0,v.jsxs)("div",{className:"flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",children:[eS?(0,v.jsx)("div",{className:null==eP?void 0:eP.header,children:eS}):null,void 0===er||er?(0,v.jsxs)("div",{className:(0,w.cn)("relative flex h-9 items-center gap-2 border-b border-border px-3",null==eP?void 0:eP.searchWrapper),children:[(0,v.jsx)(EH,{className:(0,w.cn)("size-4 shrink-0 opacity-50",null==eP?void 0:eP.searchIcon)}),(0,v.jsx)("input",{ref:tF,type:"text",role:"searchbox",autoComplete:"off",spellCheck:!1,"aria-controls":eL,"aria-activedescendant":tT.length?eF(tH):void 0,placeholder:t5,value:e3,onChange:function(e){e4(e.target.value),tX.current="keyboard"},className:(0,w.cn)("flex h-9 w-full rounded-md bg-transparent py-3 text-sm outline-hidden placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",null==eP?void 0:eP.searchInput)}),t8&&tT.length>0?(0,v.jsx)("span",{className:(0,w.cn)("flex shrink-0 items-center text-muted-foreground",null==eP?void 0:eP.searchSpinner),"aria-hidden":!0,children:null!=eb?eb:(0,v.jsx)(EK,{className:"size-4 animate-spin"})}):null]}):(0,v.jsx)("input",{ref:tF,readOnly:!0,"aria-label":null!=z?z:W,"aria-controls":eL,"aria-activedescendant":tT.length?eF(tH):void 0,className:"sr-only"}),(0,v.jsxs)("div",{ref:tB,id:eL,role:"listbox","aria-multiselectable":eT||void 0,"aria-busy":t8||void 0,style:{maxHeight:ev},className:(0,w.cn)("scroll-py-1 overflow-x-hidden overflow-y-auto",null==eP?void 0:eP.list),children:[e8?(0,v.jsx)("div",{className:(0,w.cn)("py-6 text-center text-sm text-muted-foreground",null==eP?void 0:eP.hint),children:null!=K?K:"Type at least ".concat(E," characters to search.")}):"error"===tr?ew?ew(null!=ti?ti:ee,tA):(0,v.jsxs)("div",{role:"alert",className:(0,w.cn)("flex flex-col items-center gap-2 p-4 text-center text-sm text-destructive",null==eP?void 0:eP.error),children:[(0,v.jsx)("span",{children:null!=ti?ti:ee}),(0,v.jsx)("button",{type:"button",onClick:tA,className:"rounded-md border border-border px-2 py-1 text-xs font-medium text-foreground outline-none hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring/50",children:void 0===Y?"Retry":Y})]}):(t8||"idle"===tr)&&0===tT.length?null!=eg?eg:(0,v.jsx)("div",{className:(0,w.cn)("p-1",null==eP?void 0:eP.skeleton),"aria-hidden":!0,children:[1,2,3].map(function(e){return(0,v.jsxs)("div",{className:"flex items-center gap-2 rounded-sm px-2 py-1.5",children:[(0,v.jsx)("div",{className:"size-6 animate-pulse rounded-full bg-muted"}),(0,v.jsxs)("div",{className:"flex flex-1 flex-col gap-1",children:[(0,v.jsx)("div",{className:"h-4 w-24 animate-pulse rounded bg-muted"}),(0,v.jsx)("div",{className:"h-3 w-16 animate-pulse rounded bg-muted"})]})]},e)})}):0===tT.length?null!=ex?ex:(0,v.jsx)("div",{className:(0,w.cn)("py-6 text-center text-sm",null==eP?void 0:eP.empty),children:t6}):t1.map(function(e,t){var r;return(0,v.jsxs)("div",{role:"group","aria-label":e.heading,className:(0,w.cn)("overflow-hidden p-1 text-foreground",null==eP?void 0:eP.group),children:[e.heading?(0,v.jsx)("div",{className:(0,w.cn)("px-2 py-1.5 text-xs font-medium text-muted-foreground",null==eP?void 0:eP.groupHeading),children:e.heading}):null,e.entries.map(t2)]},"".concat(null!=(r=e.heading)?r:"_","-").concat(t))}),tl&&"ready"===tr?(0,v.jsx)("div",{ref:tV,className:(0,w.cn)("flex items-center justify-center p-2 text-xs text-muted-foreground",null==eP?void 0:eP.loadMore),children:th?(0,v.jsx)("button",{type:"button",onClick:function(){tD()},className:"rounded-md px-2 py-1 text-destructive outline-none hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring/50",children:void 0===et?"Failed to load more. Retry":et}):td?null!=eb?eb:(0,v.jsx)(EK,{className:"size-4 animate-spin"}):null}):null]}),ej?(0,v.jsx)("div",{className:null==eP?void 0:eP.footer,children:ej}):null]})}):null]})}function PR(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function PM(e,t){if(e){if("string"==typeof e)return PR(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return PR(e,t)}}var PI=function(e){var t,r=e.images,n=e.cardWidth,a=void 0===n?256:n,i=e.cardHeight,o=void 0===i?352:i,s=e.className,l=e.style,u=e.getAlt,c=e.onSwipe,d=(0,g.useRef)(null),f=(0,g.useRef)(!1),p=(0,g.useRef)(0),h=(0,g.useRef)(0),m=(0,g.useRef)(null),y=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(function(){return Array.from({length:r.length},function(e,t){return t})}))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||PM(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),b=y[0],x=y[1];(0,g.useEffect)(function(){x(Array.from({length:r.length},function(e,t){return t}))},[r.length]);var w=(0,g.useCallback)(function(e,t){var r,n,a=null==(n=getComputedStyle(t||document.documentElement))||null==(r=n.getPropertyValue(e))?void 0:r.trim();return a?a.endsWith("ms")?parseFloat(a):a.endsWith("s")?1e3*parseFloat(a):parseFloat(a)||0:0},[]),S=(0,g.useCallback)(function(){return d.current?Array.from(d.current.querySelectorAll("[data-image-swiper-card]")):[]},[]),j=(0,g.useCallback)(function(){return S()[0]||null},[S]),k=(0,g.useCallback)(function(){S().forEach(function(e,t){e.style.setProperty("--i",(t+1).toString()),e.style.setProperty("--swipe-x","0px"),e.style.setProperty("--swipe-rotate","0deg"),e.style.opacity="1"})},[S]),E=(0,g.useCallback)(function(e){var t=j();t&&(t.style.setProperty("--swipe-x","".concat(e,"px")),t.style.setProperty("--swipe-rotate","".concat(.2*e,"deg")),t.style.opacity=(1-.75*Math.min(Math.abs(e)/100,1)).toString())},[j]),P=(0,g.useCallback)(function(e){if(!f.current){f.current=!0,p.current=e,h.current=e;var t=j();t&&(t.style.transition="none")}},[j]),A=(0,g.useCallback)(function(){if(f.current){m.current&&(cancelAnimationFrame(m.current),m.current=null);var e=h.current-p.current,t=w("--card-swap-duration",d.current),r=j();if(r)if(r.style.transition="transform ".concat(t,"ms ease, opacity ").concat(t,"ms ease"),Math.abs(e)>50){var n=Math.sign(e);r.style.setProperty("--swipe-x","".concat(300*n,"px")),r.style.setProperty("--swipe-rotate","".concat(20*n,"deg")),setTimeout(function(){j()===r&&r.style.setProperty("--swipe-rotate","".concat(-(20*n),"deg"))},.5*t),setTimeout(function(){x(function(e){var t;return 0===e.length?[]:(null==c||c(e[0],n>0?"right":"left"),((function(e){if(Array.isArray(e))return PR(e)})(t=e.slice(1))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||PM(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e[0]]))})},t)}else E(0);f.current=!1,p.current=0,h.current=0}},[w,j,E,c]),D=(0,g.useCallback)(function(e){f.current&&(m.current&&cancelAnimationFrame(m.current),m.current=requestAnimationFrame(function(){h.current=e;var t=h.current-p.current;E(t),Math.abs(t)>50&&A()}))},[E,A]);return(0,g.useEffect)(function(){var e=d.current;if(e){var t=function(e){return P(e.clientX)},r=function(e){return D(e.clientX)},n=function(){return A()};return e.addEventListener("pointerdown",t),e.addEventListener("pointermove",r),e.addEventListener("pointerup",n),function(){e.removeEventListener("pointerdown",t),e.removeEventListener("pointermove",r),e.removeEventListener("pointerup",n),m.current&&cancelAnimationFrame(m.current)}}},[P,D,A]),(0,g.useEffect)(function(){k()},[b,k]),(0,v.jsx)("section",{ref:d,className:O()("oiNYOqAWLBChaYRaGPIQgg==",s),style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({width:a+32,height:o+32,"--card-perspective":"700px","--card-z-offset":"12px","--card-y-offset":"7px","--card-max-z-index":r.length.toString(),"--card-swap-duration":"0.3s"},l),children:b.map(function(e,t){return(0,v.jsx)("article",{"data-image-swiper-card":!0,className:"laGBYFIn9rzvzoUcL9r5sg==",style:{"--i":(t+1).toString(),zIndex:r.length-t,width:a,height:o},children:(0,v.jsx)("img",{src:r[e],alt:u?u(e):"Image ".concat(e+1),className:"_989KfEmfVaUsIl2Vply+DA==",draggable:!1})},"".concat(r[e],"-").concat(e))})})},P_=/[achlmqstvz]|(-?\d*\.?\d*(?:e[\-+]?\d+)?)[0-9]/ig,PL=/(?:(-)?\d*\.?\d*(?:e[\-+]?\d+)?)[0-9]/ig,PF=/[\+\-]?\d*\.?\d+e[\+\-]?\d+/ig,PB=/(^[#\.][a-z]|[a-y][a-z])/i,PV=Math.PI/180,Pz=180/Math.PI,PW=Math.sin,P$=Math.cos,PU=Math.abs,PH=Math.sqrt,PG=Math.atan2,PK=function(e){return"string"==typeof e},Pq=function(e){return"number"==typeof e},PY={},PX={},PZ=function(e){return Math.round((e+1e8)%1*1e5)/1e5||(e<0?0:1)},PQ=function(e){return Math.round(1e5*e)/1e5||0},PJ=function(e){return Math.round(1e10*e)/1e10||0},P0=function(e){return e.closed=.001>Math.abs(e[0]-e[e.length-2])&&.001>Math.abs(e[1]-e[e.length-1])},P1=function(e,t,r,n){var a=e[t],i=1===n?6:An(a,r,n);if((i||!n)&&i+r+2<a.length)return e.splice(t,0,a.slice(0,r+i+2)),a.splice(0,r+i),1},P2=function(e,t,r){var n=e.length,a=~~(r*n);if(e[a]>t){for(;--a&&e[a]>t;);a<0&&(a=0)}else for(;e[++a]<t&&a<n;);return a<n?a:n-1},P3=function(e,t){var r=e.length;for(t||e.reverse();r--;)e[r].reversed||function(e){var t,r=0;for(e.reverse();r<e.length;r+=2)t=e[r],e[r]=e[r+1],e[r+1]=t;e.reversed=!e.reversed}(e[r])},P4=function(e,t){return t.totalLength=e.totalLength,e.samples?(t.samples=e.samples.slice(0),t.lookup=e.lookup.slice(0),t.minLength=e.minLength,t.resolution=e.resolution):e.totalPoints&&(t.totalPoints=e.totalPoints),t},P5=function(e,t){var r=e.length,n=e[r-1]||[],a=n.length;r&&t[0]===n[a-2]&&t[1]===n[a-1]&&(t=n.concat(t.slice(2)),r--),e[r]=t};function P6(e){var t,r=(e=PK(e)&&PB.test(e)&&document.querySelector(e)||e).getAttribute?e:0;return r&&(e=e.getAttribute("d"))?(r._gsPath||(r._gsPath={}),(t=r._gsPath[e])&&!t._dirty?t:r._gsPath[e]=As(e)):e?PK(e)?As(e):Pq(e[0])?[e]:e:console.warn("Expecting a <path> element or an SVG path data string")}var P8=function(e,t){var r,n=document.createElementNS("http://www.w3.org/2000/svg","path"),a=[].slice.call(e.attributes),i=a.length;for(t=","+t+",";--i>-1;)r=a[i].nodeName.toLowerCase(),0>t.indexOf(","+r+",")&&n.setAttributeNS(null,r,a[i].nodeValue);return n},P9={rect:"rx,ry,x,y,width,height",circle:"r,cx,cy",ellipse:"rx,ry,cx,cy",line:"x1,x2,y1,y2"},P7=function(e,t){for(var r=t?t.split(","):[],n={},a=r.length;--a>-1;)n[r[a]]=+e.getAttribute(r[a])||0;return n};function Ae(e,t,r){var n,a=e[t],i=e[t+2],o=e[t+4];return a+=(i-a)*r,i+=(o-i)*r,a+=(i-a)*r,n=i+(o+(e[t+6]-o)*r-i)*r-a,a=e[t+1],i=e[t+3],o=e[t+5],a+=(i-a)*r,i+=(o-i)*r,a+=(i-a)*r,PQ(PG(i+(o+(e[t+7]-o)*r-i)*r-a,n)*Pz)}function At(e,t,r){var n=Math.max(0,~~(PU((r=void 0===r?1:PJ(r)||0)-(t=PJ(t)||0))-1e-8)),a=function(e){for(var t=[],r=0;r<e.length;r++)t[r]=P4(e[r],e[r].slice(0));return P4(e,t)}(e);if(t>r&&(t=1-t,r=1-r,P3(a),a.totalLength=0),t<0||r<0){var i=Math.abs(~~Math.min(t,r))+1;t+=i,r+=i}a.totalLength||Ar(a);var o,s,l,u,c,d,f,p,h=r>1,m=Aa(a,t,PY,!0),y=Aa(a,r,PX),v=y.segment,g=m.segment,b=y.segIndex,x=m.segIndex,w=y.i,S=m.i,j=x===b,O=w===S&&j;if(h||n){for(o=b<x||j&&w<S||O&&y.t<m.t,P1(a,x,S,m.t)&&(x++,!o&&(b++,O?(y.t=(y.t-m.t)/(1-m.t),w=0):j&&(w-=S))),1e-5>Math.abs(1-(r-t))?b=x-1:!y.t&&b?b--:P1(a,b,w,y.t)&&o&&x++,1===m.t&&(x=(x+1)%a.length),c=[],f=1+(d=a.length)*n,p=x,f+=(d-x+b)%d,u=0;u<f;u++)P5(c,a[p++%d]);a=c}else if(l=1===y.t?6:An(v,w,y.t),t!==r)for(s=An(g,S,O?m.t/y.t:m.t),j&&(l+=s),v.splice(w+l+2),(s||S)&&g.splice(0,S+s),u=a.length;u--;)(u<x||u>b)&&a.splice(u,1);else v.angle=Ae(v,w+l,0),w+=l,m=v[w],y=v[w+1],v.length=v.totalLength=0,v.totalPoints=a.totalPoints=8,v.push(m,y,m,y,m,y,m,y);return a.totalLength=0,a}function Ar(e,t){var r,n,a;for(a=r=n=0;a<e.length;a++)e[a].resolution=~~t||12,r+=function(e,t){t=t||0,e.samples||(e.samples=[],e.lookup=[]);var r,n,a,i,o,s,l,u,c,d,f,p,h,m,y,v,g,b=~~e.resolution||12,x=1/b,w=e.length,S=e[t],j=e[t+1],O=t?t/6*b:0,k=e.samples,E=e.lookup,P=(t?e.minLength:1e8)||1e8,A=k[O+(void 0)*b-1],D=t?k[O-1]:0;for(k.length=E.length=0,n=t+2;n<w;n+=6){if(a=e[n+4]-S,i=e[n+2]-S,o=e[n]-S,u=e[n+5]-j,c=e[n+3]-j,d=e[n+1]-j,s=l=f=p=0,.01>PU(a)&&.01>PU(u)&&PU(o)+PU(d)<.01)e.length>8&&(e.splice(n,6),n-=6,w-=6);else for(r=1;r<=b;r++)h=1-(m=x*r),s=l-(l=(m*m*a+3*h*(m*i+h*o))*m),(v=PH((f=p-(p=(m*m*u+3*h*(m*c+h*d))*m))*f+s*s))<P&&(P=v),D+=v,k[O++]=D;S+=a,j+=u}if(A)for(A-=D;O<k.length;O++)k[O]+=A;if(k.length&&P){if(e.totalLength=g=k[k.length-1]||0,e.minLength=P,g/P<9999)for(r=0,v=y=0;r<g;r+=P)E[v++]=k[y]<r?++y:y}else e.totalLength=k[0]=0;return t?D-k[t/2-1]:D}(e[a]),n+=e[a].length;return e.totalPoints=n,e.totalLength=r,e}function An(e,t,r){if(r<=0||r>=1)return 0;var n=e[t],a=e[t+1],i=e[t+2],o=e[t+3],s=e[t+4],l=e[t+5],u=e[t+6],c=e[t+7],d=n+(i-n)*r,f=i+(s-i)*r,p=a+(o-a)*r,h=o+(l-o)*r,m=d+(f-d)*r,y=p+(h-p)*r,v=s+(u-s)*r,g=l+(c-l)*r;return f+=(v-f)*r,h+=(g-h)*r,e.splice(t+2,4,PQ(d),PQ(p),PQ(m),PQ(y),PQ(m+(f-m)*r),PQ(y+(h-y)*r),PQ(f),PQ(h),PQ(v),PQ(g)),e.samples&&e.samples.splice(t/6*e.resolution|0,0,0,0,0,0,0,0),6}function Aa(e,t,r,n){r=r||{},e.totalLength||Ar(e),(t<0||t>1)&&(t=PZ(t));var a,i,o,s,l,u,c,d=0,f=e[0];if(t)if(1===t)c=1,d=e.length-1,u=(f=e[d]).length-8;else{if(e.length>1){for(o=e.totalLength*t,l=u=0;(l+=e[u++].totalLength)<o;)d=u;t=(o-(s=l-(f=e[d]).totalLength))/(l-s)||0}a=f.samples,i=f.resolution,o=f.totalLength*t,s=(u=f.lookup.length?f.lookup[~~(o/f.minLength)]||0:P2(a,o,t))?a[u-1]:0,(l=a[u])<o&&(s=l,l=a[++u]),c=1/i*((o-s)/(l-s)+u%i),u=6*~~(u/i),n&&1===c&&(u+6<f.length?(u+=6,c=0):d+1<e.length&&(u=c=0,f=e[++d]))}else c=u=d=0,f=e[0];return r.t=c,r.i=u,r.path=e,r.segment=f,r.segIndex=d,r}function Ai(e,t,r,n){var a,i,o,s,l,u,c,d,f,p=e[0],h=n||{};if((t<0||t>1)&&(t=PZ(t)),p.lookup||Ar(e),e.length>1){for(o=e.totalLength*t,l=u=0;(l+=e[u++].totalLength)<o;)p=e[u];t=(o-(s=l-p.totalLength))/(l-s)||0}return a=p.samples,i=p.resolution,o=p.totalLength*t,s=(u=p.lookup.length?p.lookup[t<1?~~(o/p.minLength):p.lookup.length-1]||0:P2(a,o,t))?a[u-1]:0,(l=a[u])<o&&(s=l,l=a[++u]),f=1-(c=1/i*((o-s)/(l-s)+u%i)||0),d=p[u=6*~~(u/i)],h.x=PQ((c*c*(p[u+6]-d)+3*f*(c*(p[u+4]-d)+f*(p[u+2]-d)))*c+d),h.y=PQ((c*c*(p[u+7]-(d=p[u+1]))+3*f*(c*(p[u+5]-d)+f*(p[u+3]-d)))*c+d),r&&(h.angle=p.totalLength?Ae(p,u,c>=1?1-1e-9:c||1e-9):p.angle||0),h}function Ao(e,t,r,n,a,i,o){for(var s,l,u,c,d,f=e.length;--f>-1;)for(u=0,l=(s=e[f]).length;u<l;u+=2)c=s[u],d=s[u+1],s[u]=c*t+d*n+i,s[u+1]=c*r+d*a+o;return e._dirty=1,e}function As(e){var t,r,n,a,i,o,s,l,u,c,d,f,p,h,m,y=(e+"").replace(PF,function(e){var t=+e;return t<1e-4&&t>-1e-4?0:t}).match(P_)||[],v=[],g=0,b=0,x=2/3,w=y.length,S=0,j="ERROR: malformed path: "+e,O=function(e,t,r,n){c=(r-e)/3,d=(n-t)/3,s.push(e+c,t+d,r-c,n-d,r,n)};if(!e||!isNaN(y[0])||isNaN(y[1]))return console.log(j),v;for(t=0;t<w;t++)if(p=i,isNaN(y[t])?o=(i=y[t].toUpperCase())!==y[t]:t--,n=+y[t+1],a=+y[t+2],o&&(n+=g,a+=b),t||(l=n,u=a),"M"===i)s&&(s.length<8?v.length-=1:S+=s.length,P0(s)),g=l=n,b=u=a,s=[n,a],v.push(s),t+=2,i="L";else if("C"===i)s||(s=[0,0]),o||(g=b=0),s.push(n,a,g+ +y[t+3],b+ +y[t+4],g+=+y[t+5],b+=+y[t+6]),t+=6;else if("S"===i)c=g,d=b,("C"===p||"S"===p)&&(c+=g-s[s.length-4],d+=b-s[s.length-3]),o||(g=b=0),s.push(c,d,n,a,g+=+y[t+3],b+=+y[t+4]),t+=4;else if("Q"===i)c=g+(n-g)*x,d=b+(a-b)*x,o||(g=b=0),g+=+y[t+3],b+=+y[t+4],s.push(c,d,g+(n-g)*x,b+(a-b)*x,g,b),t+=4;else if("T"===i)c=g-s[s.length-4],d=b-s[s.length-3],s.push(g+c,b+d,n+(g+1.5*c-n)*x,a+(b+1.5*d-a)*x,g=n,b=a),t+=2;else if("H"===i)O(g,b,g=n,b),t+=1;else if("V"===i)O(g,b,g,b=n+(o?b-g:0)),t+=1;else if("L"===i||"Z"===i)"Z"===i&&(n=l,a=u,s.closed=!0),("L"===i||PU(g-n)>.5||PU(b-a)>.5)&&(O(g,b,n,a),"L"===i&&(t+=2)),g=n,b=a;else if("A"===i){if(h=y[t+4],m=y[t+5],c=y[t+6],d=y[t+7],r=7,h.length>1&&(h.length<3?(d=c,c=m,r--):(d=m,c=h.substr(2),r-=2),m=h.charAt(1),h=h.charAt(0)),f=function(e,t,r,n,a,i,o,s,l){if(e!==s||t!==l){r=PU(r),n=PU(n);var u=a%360*PV,c=P$(u),d=PW(u),f=Math.PI,p=2*f,h=(e-s)/2,m=(t-l)/2,y=c*h+d*m,v=-d*h+c*m,g=y*y,b=v*v,x=g/(r*r)+b/(n*n);x>1&&(r=PH(x)*r,n=PH(x)*n);var w=r*r,S=n*n,j=(w*S-w*b-S*g)/(w*b+S*g);j<0&&(j=0);var O=(i===o?-1:1)*PH(j),k=r*v/n*O,E=-(n*y/r*O),P=(e+s)/2+(c*k-d*E),A=(t+l)/2+(d*k+c*E),D=(y-k)/r,C=(v-E)/n,T=(-y-k)/r,N=(-v-E)/n,R=D*D+C*C,M=(C<0?-1:1)*Math.acos(D/PH(R)),I=(D*N-C*T<0?-1:1)*Math.acos((D*T+C*N)/PH(R*(T*T+N*N)));isNaN(I)&&(I=f),!o&&I>0?I-=p:o&&I<0&&(I+=p),M%=p;var L,F=Math.ceil(PU(I%=p)/(p/4)),B=[],V=I/F,z=4/3*PW(V/2)/(1+P$(V/2)),W=c*r,$=d*r,U=-(d*n),H=c*n;for(L=0;L<F;L++)y=P$(a=M+L*V),v=PW(a),D=P$(a+=V),C=PW(a),B.push(y-z*v,v+z*y,D+z*C,C-z*D,D,C);for(L=0;L<B.length;L+=2)y=B[L],v=B[L+1],B[L]=y*W+v*U+P,B[L+1]=y*$+v*H+A;return B[L-2]=s,B[L-1]=l,B}}(g,b,+y[t+1],+y[t+2],+y[t+3],+h,+m,(o?g:0)+ +c,(o?b:0)+ +d),t+=r,f)for(r=0;r<f.length;r++)s.push(f[r]);g=s[s.length-2],b=s[s.length-1]}else console.log(j);return(t=s.length)<6?(v.pop(),t=0):P0(s),v.totalPoints=S+t,v}function Al(e,t){1e-4>PU(e[0]-e[2])&&1e-4>PU(e[1]-e[3])&&(e=e.slice(2));var r,n,a,i,o,s,l,u,c,d,f,p,h,m,y,v=e.length-2,g=+e[0],b=+e[1],x=+e[2],w=+e[3],S=[g,b,g,b],j=x-g,O=w-b,k=e.nonSmooth||[],E=.001>Math.abs(e[v]-g)&&.001>Math.abs(e[v+1]-b);if(!v)return[g,b,g,b,g,b,g,b];for(E&&(e.push(x,w),x=g,w=b,g=e[v-2],b=e[v-1],e.unshift(g,b),v+=4,k=[0,0].concat(k)),t=t||0===t?+t:1,a=2;a<v;a+=2)if(r=g,n=b,g=x,b=w,x=+e[a+2],w=+e[a+3],g!==x||b!==w){if(i=j,o=O,j=x-g,O=w-b,k[a]){S.push(g-(g-r)/4,b-(b-n)/4,g,b,g+(x-g)/4,b+(w-b)/4);continue}s=PH(i*i+o*o),l=PH(j*j+O*O),u=PH(Math.pow(j/l+i/s,2)+Math.pow(O/l+o/s,2)),c=(s+l)*t*.25/u,d=g-(g-r)*(s?c/s:0),f=g+(x-g)*(l?c/l:0),p=g-(d+((f-d)*(3*s/(s+l)+.5)/4||0)),h=b-(b-n)*(s?c/s:0),m=b+(w-b)*(l?c/l:0),y=b-(h+((m-h)*(3*s/(s+l)+.5)/4||0)),S.push(PQ(d+p),PQ(h+y),PQ(g),PQ(b),PQ(f+p),PQ(m+y))}return g!==x||b!==w||S.length<4?S.push(PQ(x),PQ(w),PQ(x),PQ(w)):S.length-=2,2===S.length?S.push(g,b,g,b,g,b):E&&(S.splice(0,6),S.length-=6),S.closed=E,S}function Au(e){Pq(e[0])&&(e=[e]);var t,r,n,a,i="",o=e.length;for(r=0;r<o;r++){for(i+="M"+PQ((a=e[r])[0])+","+PQ(a[1])+" C",t=a.length,n=2;n<t;n++)i+=PQ(a[n++])+","+PQ(a[n++])+" "+PQ(a[n++])+","+PQ(a[n++])+" "+PQ(a[n++])+","+PQ(a[n])+" ";a.closed&&(i+="z")}return i}var Ac,Ad,Af,Ap,Ah,Am,Ay,Av,Ag,Ab,Ax,Aw="transform",AS=Aw+"Origin",Aj=function(e){var t=e.ownerDocument||e;for(!(Aw in e.style)&&("msTransform"in e.style)&&(AS=(Aw="msTransform")+"Origin");t.parentNode&&(t=t.parentNode););if(Ap=window,Ag=new AR,t){Af=t,Ah=t.documentElement,Am=t.body,(Ab=Af.createElementNS("http://www.w3.org/2000/svg","g")).style.transform="none";var r=t.createElement("div"),n=t.createElement("div"),a=t&&(t.body||t.firstElementChild);a&&a.appendChild&&(a.appendChild(r),r.appendChild(n),r.style.position="static",r.style.transform="translate3d(0,0,1px)",Ax=n.offsetParent!==r,a.removeChild(r))}return t},AO=function(e){for(var t,r;e&&e!==Am;)(r=e._gsap)&&r.uncache&&r.get(e,"x"),r&&!r.scaleX&&!r.scaleY&&r.renderTransform&&(r.scaleX=r.scaleY=1e-4,r.renderTransform(1,r),t?t.push(r):t=[r]),e=e.parentNode;return t},Ak=[],AE=[],AP=function(e){return e.ownerSVGElement||("svg"===(e.tagName+"").toLowerCase()?e:null)},AA=function e(t,r){if(t.parentNode&&(Af||Aj(t))){var n=AP(t),a=n?n.getAttribute("xmlns")||"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",i=n?r?"rect":"g":"div",o=100*(2===r),s=100*(3===r),l={position:"absolute",display:"block",pointerEvents:"none",margin:"0",padding:"0"},u=Af.createElementNS?Af.createElementNS(a.replace(/^https/,"http"),i):Af.createElement(i);return r&&(n?(Av||(Av=e(t)),u.setAttribute("width",.01),u.setAttribute("height",.01),u.setAttribute("transform","translate("+o+","+s+")"),u.setAttribute("fill","transparent"),Av.appendChild(u)):(Ay||Object.assign((Ay=e(t)).style,l),Object.assign(u.style,l,{width:"0.1px",height:"0.1px",top:s+"px",left:o+"px"}),Ay.appendChild(u))),u}throw"Need document and parent."},AD=function(e){for(var t=new AR,r=0;r<e.numberOfItems;r++)t.multiply(e.getItem(r).matrix);return t},AC=function(e){var t,r=e.getCTM();return r||(t=e.style[Aw],e.style[Aw]="none",e.appendChild(Ab),r=Ab.getCTM(),e.removeChild(Ab),t?e.style[Aw]=t:e.style.removeProperty(Aw.replace(/([A-Z])/g,"-$1").toLowerCase())),r||Ag.clone()},AT=function(e,t){var r,n,a,i,o,s,l=AP(e),u=e===l,c=l?Ak:AE,d=e.parentNode,f=d&&!l&&d.shadowRoot&&d.shadowRoot.appendChild?d.shadowRoot:d;if(e===Ap)return e;if(c.length||c.push(AA(e,1),AA(e,2),AA(e,3)),r=l?Av:Ay,l)u?(i=-(a=AC(e)).e/a.a,o=-a.f/a.d,n=Ag):e.getBBox?(a=e.getBBox(),i=(n=(n=e.transform?e.transform.baseVal:{}).numberOfItems?n.numberOfItems>1?AD(n):n.getItem(0).matrix:Ag).a*a.x+n.c*a.y,o=n.b*a.x+n.d*a.y):(n=new AR,i=o=0),t&&"g"===e.tagName.toLowerCase()&&(i=o=0),(u||!e.getBoundingClientRect().width?l:d).appendChild(r),r.setAttribute("transform","matrix("+n.a+","+n.b+","+n.c+","+n.d+","+(n.e+i)+","+(n.f+o)+")");else{if(i=o=0,Ax)for(n=e.offsetParent,a=e;a&&(a=a.parentNode)&&a!==n&&a.parentNode;)(Ap.getComputedStyle(a)[Aw]+"").length>4&&(i=a.offsetLeft,o=a.offsetTop,a=0);if("absolute"!==(s=Ap.getComputedStyle(e)).position&&"fixed"!==s.position)for(n=e.offsetParent;d&&d!==n;)i+=d.scrollLeft||0,o+=d.scrollTop||0,d=d.parentNode;(a=r.style).top=e.offsetTop-o+"px",a.left=e.offsetLeft-i+"px",a[Aw]=s[Aw],a[AS]=s[AS],a.position="fixed"===s.position?"fixed":"absolute",f.appendChild(r)}return r},AN=function(e,t,r,n,a,i,o){return e.a=t,e.b=r,e.c=n,e.d=a,e.e=i,e.f=o,e},AR=function(){function e(e,t,r,n,a,i){void 0===e&&(e=1),void 0===t&&(t=0),void 0===r&&(r=0),void 0===n&&(n=1),void 0===a&&(a=0),void 0===i&&(i=0),AN(this,e,t,r,n,a,i)}var t=e.prototype;return t.inverse=function(){var e=this.a,t=this.b,r=this.c,n=this.d,a=this.e,i=this.f,o=e*n-t*r||1e-10;return AN(this,n/o,-t/o,-r/o,e/o,(r*i-n*a)/o,-(e*i-t*a)/o)},t.multiply=function(e){var t=this.a,r=this.b,n=this.c,a=this.d,i=this.e,o=this.f,s=e.a,l=e.c,u=e.b,c=e.d,d=e.e,f=e.f;return AN(this,s*t+u*n,s*r+u*a,l*t+c*n,l*r+c*a,i+d*t+f*n,o+d*r+f*a)},t.clone=function(){return new e(this.a,this.b,this.c,this.d,this.e,this.f)},t.equals=function(e){var t=this.a,r=this.b,n=this.c,a=this.d,i=this.e,o=this.f;return t===e.a&&r===e.b&&n===e.c&&a===e.d&&i===e.e&&o===e.f},t.apply=function(e,t){void 0===t&&(t={});var r=e.x,n=e.y,a=this.a,i=this.b,o=this.c,s=this.d,l=this.e,u=this.f;return t.x=r*a+n*o+l||0,t.y=r*i+n*s+u||0,t},e}();function AM(e,t,r,n){if(!e||!e.parentNode||(Af||Aj(e)).documentElement===e)return new AR;var a=AO(e),i=AP(e)?Ak:AE,o=AT(e,r),s=i[0].getBoundingClientRect(),l=i[1].getBoundingClientRect(),u=i[2].getBoundingClientRect(),c=o.parentNode,d=!n&&function e(t){return"fixed"===Ap.getComputedStyle(t).position||((t=t.parentNode)&&1===t.nodeType?e(t):void 0)}(e),f=new AR((l.left-s.left)/100,(l.top-s.top)/100,(u.left-s.left)/100,(u.top-s.top)/100,s.left+(d?0:Ap.pageXOffset||Af.scrollLeft||Ah.scrollLeft||Am.scrollLeft||0),s.top+(d?0:Ap.pageYOffset||Af.scrollTop||Ah.scrollTop||Am.scrollTop||0));if(c.removeChild(o),a)for(s=a.length;s--;)(l=a[s]).scaleX=l.scaleY=0,l.renderTransform(1,l);return t?f.inverse():f}var AI,A_,AL,AF,AB,AV,Az="x,translateX,left,marginLeft,xPercent".split(","),AW="y,translateY,top,marginTop,yPercent".split(","),A$=Math.PI/180,AU=function(e,t,r,n){for(var a=t.length,i=2===n?0:n,o=0;o<a;o++)e[i]=parseFloat(t[o][r]),2===n&&(e[i+1]=0),i+=2;return e},AH=function(e,t,r){return parseFloat(e._gsap.get(e,t,r||"px"))||0},AG=function(e){var t,r=e[0],n=e[1];for(t=2;t<e.length;t+=2)r=e[t]+=r,n=e[t+1]+=n},AK=function(e,t,r,n,a,i,o,s,l){return"cubic"===o.type?t=[t]:(!1!==o.fromCurrent&&t.unshift(AH(r,n,s),a?AH(r,a,l):0),o.relative&&AG(t),t=[(a?Al:function(e,t){void 0===t&&(t=1);for(var r=e[0],n=0,a=[r,0],i=2;i<e.length;i+=2)a.push(r,n,e[i],n=(e[i]-r)*t/2,r=e[i],-n);return a})(t,o.curviness)]),t=i(AQ(t,r,o)),AJ(e,r,n,t,"x",s),a&&AJ(e,r,a,t,"y",l),Ar(t,o.resolution||(0===o.curviness?20:12))},Aq=function(e){return e},AY=/[-+\.]*\d+\.?(?:e-|e\+)?\d*/g,AX=function(e,t,r){var n,a=AM(e),i=0,o=0;return"svg"===(e.tagName+"").toLowerCase()?(n=e.viewBox.baseVal).width||(n={width:+e.getAttribute("width"),height:+e.getAttribute("height")}):n=t&&e.getBBox&&e.getBBox(),t&&"auto"!==t&&(i=t.push?t[0]*(n?n.width:e.offsetWidth||0):t.x,o=t.push?t[1]*(n?n.height:e.offsetHeight||0):t.y),r.apply(i||o?a.apply({x:i,y:o}):{x:a.e,y:a.f})},AZ=function(e,t,r,n){var a,i=AM(e.parentNode,!0,!0),o=i.clone().multiply(AM(t)),s=AX(e,r,i),l=AX(t,n,i),u=l.x,c=l.y;return o.e=o.f=0,"auto"===n&&t.getTotalLength&&"path"===t.tagName.toLowerCase()&&(a=t.getAttribute("d").match(AY)||[],u+=(a=o.apply({x:+a[0],y:+a[1]})).x,c+=a.y),a&&(u-=(a=o.apply(t.getBBox())).x,c-=a.y),o.e=u-s.x,o.f=c-s.y,o},AQ=function(e,t,r){var n,a,i,o=r.align,s=r.matrix,l=r.offsetX,u=r.offsetY,c=r.alignOrigin,d=e[0][0],f=e[0][1],p=AH(t,"x"),h=AH(t,"y");return e&&e.length?(o&&("self"===o||(n=AF(o)[0]||t)===t?Ao(e,1,0,0,1,p-d,h-f):(c&&!1!==c[2]?AI.set(t,{transformOrigin:100*c[0]+"% "+100*c[1]+"%"}):c=[-(AH(t,"xPercent")/100),-(AH(t,"yPercent")/100)],i=(a=AZ(t,n,c,"auto")).apply({x:d,y:f}),Ao(e,a.a,a.b,a.c,a.d,p+a.e-(i.x-a.e),h+a.f-(i.y-a.f)))),s?Ao(e,s.a,s.b,s.c,s.d,s.e,s.f):(l||u)&&Ao(e,1,0,0,1,l||0,u||0),e):P6("M0,0L0,0")},AJ=function(e,t,r,n,a,i){var o=t._gsap,s=o.harness,l=s&&s.aliases&&s.aliases[r],u=l&&0>l.indexOf(",")?l:r,c=e._pt=new A_(e._pt,t,u,0,0,Aq,0,o.set(t,u,e));c.u=AL(o.get(t,u,i))||0,c.path=n,c.pp=a,e._props.push(u)},A0={version:"3.15.0",name:"motionPath",register:function(e,t,r){AL=(AI=e).utils.getUnit,AF=AI.utils.toArray,AB=AI.core.getStyleSaver,AV=AI.core.reverting||function(){},A_=r},init:function(e,t,r){if(!AI)return console.warn("Please gsap.registerPlugin(MotionPathPlugin)"),!1;(void 0===t?"undefined":(n=t)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)=="object"&&!t.style&&t.path||(t={path:t});var n,a,i,o,s,l=[],u=t,c=u.path,d=u.autoRotate,f=u.unitX,p=u.unitY,h=u.x,m=u.y,y=c[0],v=(a=t.start,i="end"in t?t.end:1,function(e){return a||1!==i?At(e,a,i):e});if(this.rawPaths=l,this.target=e,this.tween=r,this.styles=AB&&AB(e,"transform"),(this.rotate=d||0===d)&&(this.rOffset=parseFloat(d)||0,this.radians=!!t.useRadians,this.rProp=t.rotation||"rotation",this.rSet=e._gsap.set(e,this.rProp,this),this.ru=AL(e._gsap.get(e,this.rProp))||0),!Array.isArray(c)||"closed"in c||"number"==typeof y)Ar(o=v(AQ(P6(t.path),e,t)),t.resolution),l.push(o),AJ(this,e,t.x||"x",o,"x",t.unitX||"px"),AJ(this,e,t.y||"y",o,"y",t.unitY||"px");else{for(s in y)!h&&~Az.indexOf(s)?h=s:!m&&~AW.indexOf(s)&&(m=s);for(s in h&&m?l.push(AK(this,AU(AU([],c,h,0),c,m,1),e,h,m,v,t,f||AL(c[0][h]),p||AL(c[0][m]))):h=m=0,y)s!==h&&s!==m&&l.push(AK(this,AU([],c,s,2),e,s,0,v,t,AL(c[0][s])))}r.vars.immediateRender&&this.render(r.progress(),this)},render:function(e,t){var r=t.rawPaths,n=r.length,a=t._pt;if(t.tween._time||!AV()){for(e>1?e=1:e<0&&(e=0);n--;)Ai(r[n],e,!n&&t.rotate,r[n]);for(;a;)a.set(a.t,a.p,a.path[a.pp]+a.u,a.d,e),a=a._next;t.rotate&&t.rSet(t.target,t.rProp,r[0].angle*(t.radians?A$:1)+t.rOffset+t.ru,t,e)}else t.styles.revert()},getLength:function(e){return Ar(P6(e)).totalLength},sliceRawPath:At,getRawPath:P6,pointsToSegment:Al,stringToRawPath:As,rawPathToString:Au,transformRawPath:Ao,getGlobalMatrix:AM,getPositionOnPath:Ai,cacheRawPathMeasurements:Ar,convertToPath:function(e,t){return AF(e).map(function(e){var r,n,a,i,o,s,l,u,c,d,f,p,h,m,y,v,g,b,x,w,S,j,O,k;return r=!1!==t,"path"!==(k=e.tagName.toLowerCase())&&e.getBBox?(l=P8(e,"x,y,width,height,cx,cy,rx,ry,r,x1,x2,y1,y2,points"),O=P7(e,P9[k]),"rect"===k?(o=O.rx,s=O.ry||o,a=O.x,i=O.y,f=O.width-2*o,p=O.height-2*s,o||s?(h=a+.44771525016900005*o,v=(y=(m=a+o)+f)+.552284749831*o,g=y+o,b=i+.44771525016900005*s,S=(w=(x=i+s)+p)+.552284749831*s,j=w+s,n="M"+g+","+x+" V"+w+" C"+[g,S,v,j,y,j,y-(y-m)/3,j,m+(y-m)/3,j,m,j,h,j,a,S,a,w,a,w-(w-x)/3,a,x+(w-x)/3,a,x,a,b,h,i,m,i,m+(y-m)/3,i,y-(y-m)/3,i,y,i,v,i,g,b,g,x].join(",")+"z"):n="M"+(a+f)+","+i+" v"+p+" h"+-f+" v"+-p+" h"+f+"z"):"circle"===k||"ellipse"===k?("circle"===k?c=.552284749831*(o=s=O.r):(o=O.rx,c=.552284749831*(s=O.ry)),a=O.cx,i=O.cy,u=.552284749831*o,n="M"+(a+o)+","+i+" C"+[a+o,i+c,a+u,i+s,a,i+s,a-u,i+s,a-o,i+c,a-o,i,a-o,i-c,a-u,i-s,a,i-s,a+u,i-s,a+o,i-c,a+o,i].join(",")+"z"):"line"===k?n="M"+O.x1+","+O.y1+" L"+O.x2+","+O.y2:("polyline"===k||"polygon"===k)&&(n="M"+(a=(d=(e.getAttribute("points")+"").match(PL)||[]).shift())+","+(i=d.shift())+" L"+d.join(","),"polygon"===k&&(n+=","+a+","+i+"z")),l.setAttribute("d",Au(l._gsRawPath=As(n))),r&&e.parentNode&&(e.parentNode.insertBefore(l,e),e.parentNode.removeChild(e)),l):e})},convertCoordinates:function(e,t,r){var n=AM(t,!0,!0).multiply(AM(e));return r?n.apply(r):n},getAlignMatrix:AZ,getRelativePosition:function(e,t,r,n){var a=AZ(e,t,r,n);return{x:a.e,y:a.f}},arrayToRawPath:function(e,t){var r=AU(AU([],e,(t=t||{}).x||"x",0),e,t.y||"y",1);return t.relative&&AG(r),["cubic"===t.type?r:Al(r,t.curviness)]}};(AI||"u">typeof window&&(AI=window.gsap)&&AI.registerPlugin&&AI)&&AI.registerPlugin(A0);let A1="BmtgkZgEaC8g-ZmaExrxmg==",A2="SZBHUVTi1OdMa9FJsKKrRg==",A3="XIbh11NxmkvKZ3BNSMMXew==";function A4(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function A5(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function A6(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}jn.registerPlugin(A0);var A8=function(e){var t,r=e.url,n=e.title,a=e.open,i=e.inPlace,o=e.id,s=e.onInPlace,l=e.total,u=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!0))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return A4(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return A4(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),c=u[0],d=u[1],f=(0,g.useRef)(null),p={transformOrigin:"center center"},h=function(){return{cx:200-(24*l-10)/2+24*o,cy:370,r:7}},m=function(){return{cx:200,cy:200,r:49}};return(0,g.useEffect)(function(){if(d(!1),f.current){var e=.4*!c,t=.2*!c,r=c?0:e+t;a?jn.timeline().set(f.current,A5({},p,h())).to(f.current,A6(A5({},p,m()),{duration:t,ease:"power3.inOut"})).to(f.current,A6(A5({},p,{cx:-4700,cy:200,r:4900}),{duration:e,ease:"power4.in",onComplete:function(){return s(o)}})):jn.timeline({overwrite:!0}).set(f.current,A5({},p,{cx:5100,cy:200,r:4900})).to(f.current,A6(A5({},p,m()),{delay:r,duration:e,ease:"power4.out"})).to(f.current,A6(A5({},p),{motionPath:{path:[{cx:200-(24*l-10)/2+24*o,cy:200,r:14},h()],curviness:1},duration:c?.01:1,ease:"bounce.out"}))}},[a]),(0,v.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0 0 ".concat(400," ").concat(400),preserveAspectRatio:"xMidYMid slice",className:A1,children:[(0,v.jsxs)("defs",{children:[(0,v.jsx)("clipPath",{id:"".concat(o,"_circleClip"),children:(0,v.jsx)("circle",{cx:0,cy:0,r:7,ref:f})}),(0,v.jsx)("clipPath",{id:"".concat(o,"_squareClip"),children:(0,v.jsx)("rect",{width:400,height:400})})]}),(0,v.jsx)("g",{clipPath:"url(#".concat(o).concat(i?"_squareClip":"_circleClip",")"),children:(0,v.jsx)("image",{width:400,height:400,href:r,className:A2,children:(0,v.jsx)("title",{children:n})})})]})},A9=function(e){var t=e.images,r=e.onSelect,n=function(e){return 200-(24*t.length-10)/2+24*e},a=function(){return 370};return(0,v.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0 0 ".concat(400," ").concat(400),preserveAspectRatio:"xMidYMid slice",className:A1,children:t.map(function(e,t){return(0,v.jsxs)("g",{className:"YLzG837WOFupR4o+Ib5MuQ==",children:[(0,v.jsx)("defs",{children:(0,v.jsx)("clipPath",{id:"tab_".concat(t,"_clip"),children:(0,v.jsx)("circle",{cx:n(t),cy:a(),r:7})})}),(0,v.jsx)("image",{x:n(t)-7,y:a()-7,width:14,height:14,href:e.url,clipPath:"url(#tab_".concat(t,"_clip)"),className:A2,preserveAspectRatio:"xMidYMid slice"}),(0,v.jsx)("circle",{onClick:function(){return r(t)},className:"rmr0X-o5feXHGYrEpgQDvw==",strokeWidth:2,cx:n(t),cy:a(),r:9,children:(0,v.jsx)("title",{children:e.title})})]},e.url)})})};function A7(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function De(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return A7(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return A7(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Dt=function(e){var t=e.images,r=e.autoplay,n=void 0===r||r,a=e.autoplayInterval,i=void 0===a?4500:a,o=e.className,s=e.style,l=De((0,g.useState)(0),2),u=l[0],c=l[1],d=De((0,g.useState)(0),2),f=d[0],p=d[1],h=De((0,g.useState)(!1),2),m=h[0],y=h[1],b=(0,g.useRef)(null),x=function(e){return p(e)},w=(0,g.useCallback)(function(){c(function(e){var r=e+1;return r>=t.length&&(r=0),r})},[t.length]),S=(0,g.useCallback)(function(){c(function(e){var r=e-1;return r<0&&(r=t.length-1),r})},[t.length]);return(0,g.useEffect)(function(){return y(!0)},[u]),(0,g.useEffect)(function(){return y(!1)},[f]),(0,g.useEffect)(function(){if(n)return b.current&&clearInterval(b.current),b.current=window.setInterval(w,i),function(){b.current&&clearInterval(b.current)}},[u,n,i,w]),(0,v.jsxs)("div",{className:O()("U-tXxoLDDyr5OI9DOeLkzg==",o),style:s,children:[(0,v.jsxs)("div",{className:"ExNnhb4iBLd2PJd4vdjc4w==",children:[t.map(function(e,r){return(0,v.jsx)("div",{className:"zDs53KpFEsOlgcDu6xCjgw==",style:{zIndex:f===r?r:t.length+1},children:(0,v.jsx)(A8,{total:t.length,id:r,url:e.url,title:e.title,open:u===r,inPlace:f===r,onInPlace:x})},e.url)}),(0,v.jsx)("div",{className:"_5Hv7dRjmf3CkVFgfdeV0HQ==",children:(0,v.jsx)(A9,{images:t,onSelect:function(e){m||c(e)}})})]}),(0,v.jsx)("button",{type:"button",className:O()(A3,"PAulbSkkA9jxQi1R6BQ75A=="),onClick:S,disabled:m,"aria-label":"Image pr\xe9c\xe9dente",children:(0,v.jsx)(ox,{size:28})}),(0,v.jsx)("button",{type:"button",className:O()(A3,"aIKGaIx0zEpUN2opqQJjfg=="),onClick:w,disabled:m,"aria-label":"Image suivante",children:(0,v.jsx)(ow,{size:28})})]})};function Dr(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Dn(e){var t=e.handleShuffle,r=e.testimonial,n=e.position,a=e.id,i=e.author,o=e.avatarUrl,s=e.cardWidth,l=e.cardHeight,u=e.className,c=e.style,d=(0,g.useRef)(0),f="front"===n;return(0,v.jsxs)(hz.div,{style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){Dr(e,t,r[t])})}return e}({zIndex:"front"===n?2:+("middle"===n),width:void 0===s?350:s,height:void 0===l?450:l},c),animate:{rotate:"front"===n?"-6deg":"middle"===n?"0deg":"6deg",x:"front"===n?"0%":"middle"===n?"33%":"66%"},drag:!0,dragElastic:.35,dragListener:f,dragConstraints:{top:0,left:0,right:0,bottom:0},onDragStart:function(e){d.current=e.clientX},onDragEnd:function(e){var r=e.clientX;d.current-r>150&&t(),d.current=0},transition:{duration:.35},className:O()("MY7YZNf47I5RSHhV26w6Ag==",Dr({},"_2Eid4z+wvtEzluRmyU9KfQ==",f),u),children:[(0,v.jsx)("img",{src:null!=o?o:"https://i.pravatar.cc/128?img=".concat(a),alt:"Avatar of ".concat(i),className:"N7o2pWg-TdybJuikJXI0AQ==",draggable:!1}),(0,v.jsxs)("span",{className:"-+76DfLbDI0klJgz4+oBig==",children:['"',r,'"']}),(0,v.jsx)("span",{className:"h8hsmFiRL4Cc37zAjzK3jQ==",children:i})]})}function Da(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Di(e){if(Array.isArray(e))return e}function Do(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function Ds(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Dl(e,t){if(e){if("string"==typeof e)return Da(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Da(e,t)}}function Du(e){var t,r=e.testimonials,n=e.cardWidth,a=void 0===n?350:n,i=e.cardHeight,o=void 0===i?450:i,s=e.className,l=e.style,u=e.onShuffle,c=Di(t=(0,g.useState)(function(){return r.map(function(e,t){return t})}))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||Dl(t,2)||Ds(),d=c[0],f=c[1];(0,g.useEffect)(function(){f(r.map(function(e,t){return t}))},[r]);var p=(0,g.useCallback)(function(){f(function(e){if(0===e.length)return e;var t,n=Di(e)||Do(e)||Dl(e)||Ds(),a=n[0],i=n.slice(1);return null==u||u(null==(t=r[a])?void 0:t.id),((function(e){if(Array.isArray(e))return Da(e)})(i)||Do(i)||Dl(i)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([a])})},[u,r]);return(0,v.jsx)("div",{className:O()("FsSes4zAoxSyWmsIs2kmJQ==",s),style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({width:a,height:o},l),children:d.map(function(e,t){var n=r[e];return n?(0,v.jsx)(Dn,{id:n.id,testimonial:n.testimonial,author:n.author,avatarUrl:n.avatarUrl,position:0===t?"front":1===t?"middle":"back",handleShuffle:p,cardWidth:a,cardHeight:o},n.id):null})})}var Dc=(0,g.createContext)(null),Dd=function(){var e=(0,g.useContext)(Dc);if(!e)throw Error("Carousel compound components must be used within <Carousel>");return e};function Df(e){return"[object Object]"===Object.prototype.toString.call(e)||Array.isArray(e)}function Dp(e,t){var r=Object.keys(e),n=Object.keys(t);return r.length===n.length&&JSON.stringify(Object.keys(e.breakpoints||{}))===JSON.stringify(Object.keys(t.breakpoints||{}))&&r.every(function(r){var n=e[r],a=t[r];return"function"==typeof n?"".concat(n)==="".concat(a):Df(n)&&Df(a)?Dp(n,a):n===a})}function Dh(e){return e.concat().sort(function(e,t){return e.name>t.name?1:-1}).map(function(e){return e.options})}function Dm(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Dy(e){return"number"==typeof e}function Dv(e){return"string"==typeof e}function Dg(e){return"boolean"==typeof e}function Db(e){return"[object Object]"===Object.prototype.toString.call(e)}function Dx(e){return Math.abs(e)}function Dw(e){return Math.sign(e)}function DS(e){return DE(e).map(Number)}function Dj(e){return e[DO(e)]}function DO(e){return Math.max(0,e.length-1)}function Dk(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return Array.from(Array(e),function(e,r){return t+r})}function DE(e){return Object.keys(e)}function DP(e,t){var r;return void 0!==t.MouseEvent&&(null!=(r=t.MouseEvent)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](e):e instanceof r)}function DA(){var e=[],t={add:function(r,n,a){var i,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{passive:!0};return"addEventListener"in r?(r.addEventListener(n,a,o),i=function(){return r.removeEventListener(n,a,o)}):(r.addListener(a),i=function(){return r.removeListener(a)}),e.push(i),t},clear:function(){e=e.filter(function(e){return e()})}};return t}function DD(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=Dx(e-t);function n(r){return r<e||r>t}return{length:r,max:t,min:e,constrain:function(r){return n(r)?r<e?e:t:r},reachedAny:n,reachedMax:function(e){return e>t},reachedMin:function(t){return t<e},removeOffset:function(e){return r?e-r*Math.ceil((e-t)/r):e}}}function DC(e){var t=e;function r(e){return Dy(e)?e:e.get()}return{get:function(){return t},set:function(e){t=r(e)},add:function(e){t+=r(e)},subtract:function(e){t-=r(e)}}}function DT(e,t){var r="x"===e.scroll?function(e){return"translate3d(".concat(e,"px,0px,0px)")}:function(e){return"translate3d(0px,".concat(e,"px,0px)")},n=t.style,a=null,i=!1;return{clear:function(){!i&&(n.transform="",t.getAttribute("style")||t.removeAttribute("style"))},to:function(t){if(!i){var o=Math.round(100*e.direction(t))/100;o!==a&&(n.transform=r(o),a=o)}},toggleActive:function(e){i=!e}}}var DN={align:"center",axis:"x",container:null,slides:null,containScroll:"trimSnaps",direction:"ltr",slidesToScroll:1,inViewThreshold:0,breakpoints:{},dragFree:!1,dragThreshold:10,loop:!1,skipSnaps:!1,duration:25,startIndex:0,active:!0,watchDrag:!0,watchResize:!0,watchSlides:!0,watchFocus:!0};function DR(e,t,r){var n,a,i,o,s,l,u,c,d=e.ownerDocument,f=d.defaultView,p=function(e){function t(e,t){return function e(t,r){return[t,r].reduce(function(t,r){return DE(r).forEach(function(n){var a=t[n],i=r[n],o=Db(a)&&Db(i);t[n]=o?e(a,i):i}),t},{})}(e,t||{})}return{mergeOptions:t,optionsAtMedia:function(r){var n=r.breakpoints||{},a=DE(n).filter(function(t){return e.matchMedia(t).matches}).map(function(e){return n[e]}).reduce(function(e,r){return t(e,r)},{});return t(r,a)},optionsMediaQueries:function(t){return t.map(function(e){return DE(e.breakpoints||{})}).reduce(function(e,t){return e.concat(t)},[]).map(e.matchMedia)}}}(f),h=(o=[],{init:function(e,t){return(o=t.filter(function(e){var t=e.options;return!1!==p.optionsAtMedia(t).active})).forEach(function(t){return t.init(e,p)}),t.reduce(function(e,t){var r,n;return Object.assign(e,(r={},n=t.name,n in r?Object.defineProperty(r,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[n]=t,r))},{})},destroy:function(){o=o.filter(function(e){return e.destroy()})}}),m=DA(),y=(a={},i={init:function(e){n=e},emit:function(e){return(a[e]||[]).forEach(function(t){return t(n,e)}),i},off:function(e,t){return a[e]=(a[e]||[]).filter(function(e){return e!==t}),i},on:function(e,t){return a[e]=(a[e]||[]).concat([t]),i},clear:function(){a={}}}),v=p.mergeOptions,g=p.optionsAtMedia,b=p.optionsMediaQueries,x=y.on,w=y.off,S=y.emit,j=!1,O=v(DN,DR.globalOptions),k=v(O),E=[];function P(t,r){var n,a,i,o;!j&&(k=g(O=v(O,t)),E=r||E,n=k.container,a=k.slides,u=(Dv(n)?e.querySelector(n):n)||e.children[0],i=Dv(a)?u.querySelectorAll(a):a,c=[].slice.call(i||u.children),s=function t(r){var n=function(e,t,r,n,a,i,o){var s,l,u,c,d,f,p,h,m,y,v,g,b,x,w,S,j,O,k,E,P,A,D,C,T,N,R,M,I,L,F,B,V,z,W,$,U,H,G,K,q,Y,X,Z,Q=i.align,J=i.axis,ee=i.direction,et=i.startIndex,er=i.loop,en=i.duration,ea=i.dragFree,ei=i.dragThreshold,eo=i.inViewThreshold,es=i.slidesToScroll,el=i.skipSnaps,eu=i.containScroll,ec=i.watchResize,ed=i.watchSlides,ef=i.watchDrag,ep=i.watchFocus,eh={measure:function(e){var t=e.offsetTop,r=e.offsetLeft,n=e.offsetWidth,a=e.offsetHeight;return{top:t,right:r+n,bottom:t+a,left:r,width:n,height:a}}},em=eh.measure(t),ey=r.map(eh.measure),ev=(d="rtl"===ee,p=(f="y"===J)||!d?1:-1,h=f?"top":d?"right":"left",m=f?"bottom":d?"left":"right",{scroll:f?"y":"x",cross:f?"x":"y",startEdge:h,endEdge:m,measureSize:function(e){var t=e.height,r=e.width;return f?t:r},direction:function(e){return e*p}}),eg=ev.measureSize(em),eb={measure:function(e){return e/100*eg}},ex=(s=Q,l=eg,u={start:function(){return 0},center:function(e){return(l-e)/2},end:function(e){return l-e}},{measure:function(e,t){return Dv(s)?u[s](e):s(l,e,t)}}),ew=!er&&!!eu,eS=er||!!eu,ej=(y=ev.measureSize,v=ev.startEdge,g=ev.endEdge,b=ey[0]&&eS,x=function(){if(!b)return 0;var e=ey[0];return Dx(em[v]-e[v])}(),w=b?parseFloat(a.getComputedStyle(Dj(r)).getPropertyValue("margin-".concat(g))):0,S=ey.map(y),j=ey.map(function(e,t,r){var n=t===DO(r);return t?n?S[t]+w:r[t+1][v]-e[v]:S[t]+x}).map(Dx),{slideSizes:S,slideSizesWithGaps:j,startGap:x,endGap:w}),eO=ej.slideSizes,ek=ej.slideSizesWithGaps,eE=ej.startGap,eP=ej.endGap,eA=(O=ev.startEdge,k=ev.endEdge,E=ev.direction,P=Dy(es),{groupSlides:function(e){return P?DS(e).filter(function(e){return e%es==0}).map(function(t){return e.slice(t,t+es)}):e.length?DS(e).reduce(function(t,r,n){var a=Dj(t)||0,i=r===DO(e),o=em[O]-ey[a][O],s=em[O]-ey[r][k],l=er||0!==a?0:E(eE),u=Dx(s-(!er&&i?E(eP):0)-(o+l));return n&&u>eg+2&&t.push(r),i&&t.push(e.length),t},[]).map(function(t,r,n){var a=Math.max(n[r-1]||0);return e.slice(a,t)}):[]}}),eD=(A=ev.startEdge,D=ev.endEdge,T=(C=eA.groupSlides)(ey).map(function(e){return Dj(e)[D]-e[0][A]}).map(Dx).map(ex.measure),R=C(N=ey.map(function(e){return em[A]-e[A]}).map(function(e){return-Dx(e)})).map(function(e){return e[0]}).map(function(e,t){return e+T[t]}),{snaps:N,snapsAligned:R}),eC=eD.snaps,eT=eD.snapsAligned,eN=-Dj(eC)+Dj(ek),eR=function(e,t,r,n){var a,i,o=DD(-t+e,0),s=r.map(function(e,t){var n=o.min,a=o.max,i=o.constrain(e),s=t===DO(r);return t?s||function(e,t){return 1>=Dx(e-t)}(n,i)?n:function(e,t){return 1>=Dx(e-t)}(a,i)?a:i:a}).map(function(e){return parseFloat(e.toFixed(3))}),l=(a=s[0],i=Dj(s),DD(s.lastIndexOf(a),s.indexOf(i)+1));return{snapsContained:function(){if(t<=e+2)return[o.max];if("keepSnaps"===n)return s;var r=l.min,a=l.max;return s.slice(r,a)}(),scrollContainLimit:l}}(eg,eN,eT,eu),eM=eR.snapsContained,eI=eR.scrollContainLimit,e_=ew?eM:eT,eL=(M=e_[0],{limit:DD(er?M-eN:Dj(e_),M)}).limit,eF=function e(t,r,n){var a=DD(0,t).constrain,i=t+1,o=s(r);function s(e){return n?Dx((i+e)%i):a(e)}function l(){return e(t,o,n)}var u={get:function(){return o},set:function(e){return o=s(e),u},add:function(e){return l().set(o+e)},clone:l};return u}(DO(e_),et,er),eB=eF.clone(),eV=DS(r),ez=function(e){var t=e.dragHandler,r=e.scrollBody,n=e.scrollBounds;e.options.loop||n.constrain(t.pointerDown()),r.seek()},eW=function(e,t){var r=e.scrollBody,n=e.translate,a=e.location,i=e.offsetLocation,o=e.previousLocation,s=e.scrollLooper,l=e.slideLooper,u=e.dragHandler,c=e.animation,d=e.eventHandler,f=e.scrollBounds,p=e.options.loop,h=r.settled(),m=!f.shouldConstrain(),y=p?h:h&&m,v=y&&!u.pointerDown();v&&c.stop();var g=a.get()*t+o.get()*(1-t);i.set(g),p&&(s.loop(r.direction()),l.loop()),n.to(i.get()),v&&d.emit("settle"),y||d.emit("scroll")},e$=function(e,t,r,n){var a=DA(),i=1e3/60,o=null,s=0,l=0;function u(e){if(l){o||(o=e,r(),r());var a=e-o;for(o=e,s+=a;s>=i;)r(),s-=i;n(s/i),l&&(l=t.requestAnimationFrame(u))}}function c(){t.cancelAnimationFrame(l),o=null,s=0,l=0}return{init:function(){a.add(e,"visibilitychange",function(){e.hidden&&(o=null,s=0)})},destroy:function(){c(),a.clear()},start:function(){l||(l=t.requestAnimationFrame(u))},stop:c,update:r,render:n}}(n,a,function(){return ez(e3)},function(e){return eW(e3,e)}),eU=e_[eF.get()],eH=DC(eU),eG=DC(eU),eK=DC(eU),eq=DC(eU),eY=function(e,t,r,n,a){var i=0,o=0,s=a,l=.68,u=e.get(),c=0;function d(e){return s=e,p}function f(e){return l=e,p}var p={direction:function(){return o},duration:function(){return s},velocity:function(){return i},seek:function(){var t=n.get()-e.get(),a=0;return s?(r.set(e),i+=t/s,i*=l,u+=i,e.add(i),a=u-c):(i=0,r.set(n),e.set(n),a=t),o=Dw(a),c=u,p},settled:function(){return .001>Dx(n.get()-t.get())},useBaseFriction:function(){return f(.68)},useBaseDuration:function(){return d(a)},useFriction:f,useDuration:d};return p}(eH,eK,eG,eq,en),eX=function(e,t,r,n,a){var i=n.reachedAny,o=n.removeOffset,s=n.constrain;function l(e){return e.concat().sort(function(e,t){return Dx(e)-Dx(t)})[0]}function u(t,n){var a=[t,t+r,t-r];if(!e)return t;if(!n)return l(a);var i=a.filter(function(e){return Dw(e)===n});return i.length?l(i):Dj(a)-r}return{byDistance:function(r,n){var l,c=a.get()+r,d=(l=e?o(c):s(c),{index:t.map(function(e,t){return{diff:u(e-l,0),index:t}}).sort(function(e,t){return Dx(e.diff)-Dx(t.diff)})[0].index,distance:l}),f=d.index,p=d.distance,h=!e&&i(c);if(!n||h)return{index:f,distance:r};var m=r+u(t[f]-p,0);return{index:f,distance:m}},byIndex:function(e,r){var n=u(t[e]-a.get(),r);return{index:e,distance:n}},shortcut:u}}(er,e_,eN,eL,eq),eZ=function(e,t,r,n,a,i,o){function s(a){var s=a.distance,l=a.index!==t.get();i.add(s),s&&(n.duration()?e.start():(e.update(),e.render(1),e.update())),l&&(r.set(t.get()),t.set(a.index),o.emit("select"))}return{distance:function(e,t){s(a.byDistance(e,t))},index:function(e,r){var n=t.clone().set(e);s(a.byIndex(n.get(),r))}}}(e$,eF,eB,eY,eX,eq,o),eQ=(I=eL.max,L=eL.length,{get:function(e){return L?-((e-I)/L):0}}),eJ=DA(),e0=(B={},V=null,z=null,W=!1,{init:function(){F=new IntersectionObserver(function(e){W||(e.forEach(function(e){B[r.indexOf(e.target)]=e}),V=null,z=null,o.emit("slidesInView"))},{root:t.parentElement,threshold:eo}),r.forEach(function(e){return F.observe(e)})},destroy:function(){F&&F.disconnect(),W=!0},get:function(){var e=!(arguments.length>0)||void 0===arguments[0]||arguments[0];if(e&&V)return V;if(!e&&z)return z;var t=DE(B).reduce(function(t,r){var n=parseInt(r),a=B[n].isIntersecting;return(e&&a||!e&&!a)&&t.push(n),t},[]);return e&&(V=t),e||(z=t),t}}),e1=($=eA.groupSlides,U=eI.min,H=eI.max,{slideRegistry:(c=$(eV),1===e_.length?[eV]:ew&&"keepSnaps"!==eu?c.slice(U,H).map(function(e,t,r){var n=t===DO(r);return t?n?Dk(DO(eV)-Dj(r)[0]+1,Dj(r)[0]):e:Dk(Dj(r[0])+1)}):c)}).slideRegistry,e2=function(e,t,r,n,a,i,o,s){var l={passive:!0,capture:!0},u=0;function c(e){"Tab"===e.code&&(u=new Date().getTime())}return{init:function(d){s&&(i.add(document,"keydown",c,!1),t.forEach(function(t,c){i.add(t,"focus",function(t){(Dg(s)||s(d,t))&&function(t){if(!(new Date().getTime()-u>10)){o.emit("slideFocusStart"),e.scrollLeft=0;var i=r.findIndex(function(e){return e.includes(t)});Dy(i)&&(a.useDuration(0),n.index(i,0),o.emit("slideFocus"))}}(c)},l)}))}}}(e,r,e1,eZ,eY,eJ,o,ep),e3={ownerDocument:n,ownerWindow:a,eventHandler:o,containerRect:em,slideRects:ey,animation:e$,axis:ev,dragHandler:function(e,t,r,n,a,i,o,s,l,u,c,d,f,p,h,m,y,v){var g=e.cross,b=e.direction,x=["INPUT","SELECT","TEXTAREA"],w={passive:!1},S=DA(),j=DA(),O=DD(50,225).constrain(p.measure(20)),k={mouse:300,touch:400},E={mouse:500,touch:600},P=h?43:25,A=!1,D=0,C=0,T=!1,N=!1,R=!1,M=!1;function I(e){if(!DP(e,n)&&e.touches.length>=2)return L(e);var t=i.readPoint(e),r=i.readPoint(e,g),o=Dx(t-D),l=Dx(r-C);if(!N&&!M&&(!e.cancelable||!(N=o>l)))return L(e);var c=i.pointerMove(e);o>m&&(R=!0),u.useFriction(.3).useDuration(.75),s.start(),a.add(b(c)),e.preventDefault()}function L(e){var t,r,n,a=c.byDistance(0,!1).index!==d.get(),o=i.pointerUp(e)*(h?E:k)[M?"mouse":"touch"],s=(t=b(o),r=d.add(-1*Dw(t)),n=c.byDistance(t,!h).distance,h||Dx(t)<O?n:y&&a?.5*n:c.byIndex(r.get(),0).distance),p=function(e,t){if(0===e||0===t||Dx(e)<=Dx(t))return 0;var r,n,a=(r=Dx(e),n=Dx(t),Dx(r-n));return Dx(a/e)}(o,s);N=!1,T=!1,j.clear(),u.useDuration(P-10*p).useFriction(.68+p/50),l.distance(s,!h),M=!1,f.emit("pointerUp")}function F(e){R&&(e.stopPropagation(),e.preventDefault(),R=!1)}return{init:function(e){v&&S.add(t,"dragstart",function(e){return e.preventDefault()},w).add(t,"touchmove",function(){},w).add(t,"touchend",function(){}).add(t,"touchstart",s).add(t,"mousedown",s).add(t,"touchcancel",L).add(t,"contextmenu",L).add(t,"click",F,!0);function s(s){var l,c,d,p;(Dg(v)||v(e,s))&&(M=p=DP(l=s,n),R=h&&p&&!l.buttons&&A,A=Dx(a.get()-o.get())>=2,(!p||0===l.button)&&(c=l.target.nodeName||"",x.includes(c)||(T=!0,i.pointerDown(l),u.useFriction(0).useDuration(0),a.set(o),d=M?r:t,j.add(d,"touchmove",I,w).add(d,"touchend",L).add(d,"mousemove",I,w).add(d,"mouseup",L),D=i.readPoint(l),C=i.readPoint(l,g),f.emit("pointerDown"))))}},destroy:function(){S.clear(),j.clear()},pointerDown:function(){return T}}}(ev,e,n,a,eq,function(e,t){var r,n;function a(e){return e.timeStamp}function i(r,n){var a=n||e.scroll;return(DP(r,t)?r:r.touches[0])["client".concat("x"===a?"X":"Y")]}return{pointerDown:function(e){return r=e,n=e,i(e)},pointerMove:function(e){var t=i(e)-i(n),o=a(e)-a(r)>170;return n=e,o&&(r=e),t},pointerUp:function(e){if(!r||!n)return 0;var t=i(n)-i(r),o=a(e)-a(r),s=a(e)-a(n)>170,l=t/o;return o&&!s&&Dx(l)>.1?l:0},readPoint:i}}(ev,a),eH,e$,eZ,eY,eX,eF,o,eb,ea,ei,el,ef),eventStore:eJ,percentOfView:eb,index:eF,indexPrevious:eB,limit:eL,location:eH,offsetLocation:eK,previousLocation:eG,options:i,resizeHandler:function(e,t,r,n,a,i,o){var s,l,u=[e].concat(n),c=[],d=!1;function f(e){return a.measureSize(o.measure(e))}return{init:function(a){i&&(l=f(e),c=n.map(f),s=new ResizeObserver(function(r){(Dg(i)||i(a,r))&&function(r){var i=!0,o=!1,s=void 0;try{for(var u,p=r[Symbol.iterator]();!(i=(u=p.next()).done);i=!0){var h=u.value;if(d)return;var m=h.target===e,y=n.indexOf(h.target),v=m?l:c[y],g=f(m?e:n[y]);if(Dx(g-v)>=.5){a.reInit(),t.emit("resize");break}}}catch(e){o=!0,s=e}finally{try{i||null==p.return||p.return()}finally{if(o)throw s}}}(r)}),r.requestAnimationFrame(function(){u.forEach(function(e){return s.observe(e)})}))},destroy:function(){d=!0,s&&s.disconnect()}}}(t,o,a,r,ev,ec,eh),scrollBody:eY,scrollBounds:function(e,t,r,n,a){var i=a.measure(10),o=a.measure(50),s=DD(.1,.99),l=!1;function u(){return!l&&!!e.reachedAny(r.get())&&!!e.reachedAny(t.get())}return{shouldConstrain:u,constrain:function(a){if(u()){var l=e.reachedMin(t.get())?"min":"max",c=Dx(e[l]-t.get()),d=r.get()-t.get(),f=s.constrain(c/o);r.subtract(d*f),!a&&Dx(d)<i&&(r.set(e.constrain(r.get())),n.useDuration(25).useBaseFriction())}},toggleActive:function(e){l=!e}}}(eL,eK,eq,eY,eb),scrollLooper:(G=[eH,eK,eG,eq],q=(K=DD(eL.min+.1,eL.max+.1)).reachedMin,Y=K.reachedMax,{loop:function(e){if(1===e?Y(eK.get()):-1===e&&q(eK.get())){var t=-1*e*eN;G.forEach(function(e){return e.add(t)})}}}),scrollProgress:eQ,scrollSnapList:e_.map(eQ.get),scrollSnaps:e_,scrollTarget:eX,scrollTo:eZ,slideLooper:function(e,t,r,n,a,i,o,s,l){var u=DS(a),c=DS(a).reverse(),d=h(p(c,o[0]),r,!1).concat(h(p(u,t-o[0]-1),-r,!0));function f(e,t){return e.reduce(function(e,t){return e-a[t]},t)}function p(e,t){return e.reduce(function(e,r){return f(e,t)>0?e.concat([r]):e},[])}function h(a,o,u){var c=i.map(function(e,r){return{start:e-n[r]+.5+o,end:e+t-.5+o}});return a.map(function(t){var n=u?0:-r,a=u?r:0,i=c[t][u?"end":"start"];return{index:t,loopPoint:i,slideLocation:DC(-1),translate:DT(e,l[t]),target:function(){return s.get()>i?n:a}}})}return{canLoop:function(){return d.every(function(e){var r=e.index;return .1>=f(u.filter(function(e){return e!==r}),t)})},clear:function(){d.forEach(function(e){return e.translate.clear()})},loop:function(){d.forEach(function(e){var t=e.target,r=e.translate,n=e.slideLocation,a=t();a!==n.get()&&(r.to(a),n.set(a))})},loopPoints:d}}(ev,eg,eN,eO,ek,eC,e_,eK,r),slideFocus:e2,slidesHandler:(Z=!1,{init:function(e){ed&&(X=new MutationObserver(function(t){!Z&&(Dg(ed)||ed(e,t))&&function(t){var r=!0,n=!1,a=void 0;try{for(var i,s=t[Symbol.iterator]();!(r=(i=s.next()).done);r=!0){var l=i.value;if("childList"===l.type){e.reInit(),o.emit("slidesChanged");break}}}catch(e){n=!0,a=e}finally{try{r||null==s.return||s.return()}finally{if(n)throw a}}}(t)})).observe(t,{childList:!0})},destroy:function(){X&&X.disconnect(),Z=!0}}),slidesInView:e0,slideIndexes:eV,slideRegistry:e1,slidesToScroll:eA,target:eq,translate:DT(ev,t)};return e3}(e,u,c,d,f,r,y);return r.loop&&!n.slideLooper.canLoop()?t(Object.assign({},r,{loop:!1})):n}(k),b([O].concat(function(e){if(Array.isArray(e))return Dm(e)}(o=E.map(function(e){return e.options}))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(o)||function(e){if(e){if("string"==typeof e)return Dm(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Dm(e,void 0)}}(o)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())).forEach(function(e){return m.add(e,"change",A)}),k.active&&(s.translate.to(s.location.get()),s.animation.init(),s.slidesInView.init(),s.slideFocus.init(N),s.eventHandler.init(N),s.resizeHandler.init(N),s.slidesHandler.init(N),s.options.loop&&s.slideLooper.loop(),u.offsetParent&&c.length&&s.dragHandler.init(N),l=h.init(N,E)))}function A(e,t){var r=T();D(),P(v({startIndex:r},e),t),y.emit("reInit")}function D(){s.dragHandler.destroy(),s.eventStore.clear(),s.translate.clear(),s.slideLooper.clear(),s.resizeHandler.destroy(),s.slidesHandler.destroy(),s.slidesInView.destroy(),s.animation.destroy(),h.destroy(),m.clear()}function C(e,t,r){k.active&&!j&&(s.scrollBody.useBaseFriction().useDuration(!0===t?0:k.duration),s.scrollTo.index(e,r||0))}function T(){return s.index.get()}var N={canScrollNext:function(){return s.index.add(1).get()!==T()},canScrollPrev:function(){return s.index.add(-1).get()!==T()},containerNode:function(){return u},internalEngine:function(){return s},destroy:function(){j||(j=!0,m.clear(),D(),y.emit("destroy"),y.clear())},off:w,on:x,emit:S,plugins:function(){return l},previousScrollSnap:function(){return s.indexPrevious.get()},reInit:A,rootNode:function(){return e},scrollNext:function(e){C(s.index.add(1).get(),e,-1)},scrollPrev:function(e){C(s.index.add(-1).get(),e,1)},scrollProgress:function(){return s.scrollProgress.get(s.offsetLocation.get())},scrollSnapList:function(){return s.scrollSnapList},scrollTo:C,selectedScrollSnap:T,slideNodes:function(){return c},slidesInView:function(){return s.slidesInView.get()},slidesNotInView:function(){return s.slidesInView.get(!1)}};return P(t,r),setTimeout(function(){return y.emit("init")},0),N}function DM(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function DI(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return DM(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return DM(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function D_(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=(0,g.useRef)(e),n=(0,g.useRef)(t),a=DI((0,g.useState)(),2),i=a[0],o=a[1],s=DI((0,g.useState)(),2),l=s[0],u=s[1],c=(0,g.useCallback)(function(){i&&i.reInit(r.current,n.current)},[i]);return(0,g.useEffect)(function(){Dp(r.current,e)||(r.current=e,c())},[e,c]),(0,g.useEffect)(function(){!function(e,t){if(e.length!==t.length)return!1;var r=Dh(e),n=Dh(t);return r.every(function(e,t){return Dp(e,n[t])})}(n.current,t)&&(n.current=t,c())},[t,c]),(0,g.useEffect)(function(){if("u">typeof window&&window.document&&window.document.createElement&&l){DR.globalOptions=D_.globalOptions;var e=DR(l,r.current,n.current);return o(e),function(){return e.destroy()}}o(void 0)},[l,o]),[u,i]}DR.globalOptions=void 0,D_.globalOptions=void 0;let DL={root:"U5e-lVeOV3aIYgNBY3CvXA==",viewport:"hbkmtr9NY5nS0b6sekJBqg==","viewport--x":"_8JvxYg-UqoVn3brqjKyvFQ==","viewport--y":"P5LNM+fGTcgmqv-M4-1hRw==",container:"Q0dxJjntBDyAdjQVlkdqrg==","container--x":"TGKn-LXAgM3-0Licuc8L4A==","container--y":"A7zaK7w9OGucgZen2RLdWg==",slide:"UWf6nD6UXLs3JqN72IP+mQ==","slide--x":"fFHnS24UCF9k8JOqfNCsqA==","slide--y":"bHvcZzVuc3QI8dfb+oh97g==",thumbsViewport:"koJHE5dWVzTOIKbYQy2q7w==",thumbsContainer:"p8w-6uNOJVMKH+Ur8uJ4tg==","thumbsContainer--x":"Au0B9jnCnsAkOZfuWEvK1A==","thumbsContainer--y":"G6B3FuzXWoGnha6EVtyPEA==",thumb:"VfsjLHXaM0hbukRdL-v3kg==","thumb--active":"fLfMTaEbv8cMyS0-ZVobiA==",thumbImage:"AL26JFHTg0-E-BXdkLhdjA==",dots:"+CDjHobF2k1kpYO7CpiPKw==",dot:"d7ri6n1PqgEw0cvheR6P-g==","dot--active":"rekho7j513oArbBYPNsHCw=="};function DF(e){var t=e.children,r=e.className,n=Dd(),a=n.axis,i=n.mainViewportRef;return(0,v.jsx)("div",{ref:i,className:O()(DL.viewport,DL["viewport--".concat(a)],r),children:(0,v.jsx)("div",{className:O()(DL.container,DL["container--".concat(a)]),children:t})})}function DB(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function DV(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return DB(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return DB(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Dz(e){var t,r,n,a=e.children,i=e.options,o=e.plugins,s=e.dir,l=void 0===s?"ltr":s,u=e.className,c=e.style,d=null!=(n=null==i?void 0:i.axis)?n:"x",f=DV(D_((t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},i),r=r={direction:l},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t),o),2),p=f[0],h=f[1],m=DV(D_({axis:d,direction:l,containScroll:"keepSnaps",dragFree:!0}),2),y=m[0],x=m[1],w=DV((0,g.useState)(0),2),S=w[0],j=w[1],k=(0,g.useMemo)(function(){return function(e){var t=b().Children.toArray(e),r=!0,n=!1,a=void 0;try{for(var i,o=t[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s=i.value;if(b().isValidElement(s)&&s.type===DF){var l=s.props;return b().Children.toArray(l.children).filter(b().isValidElement).map(function(e){return e.props.thumbnailSrc})}}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}return[]}(a)},[a]),E=(0,g.useCallback)(function(e){null==h||h.scrollTo(e)},[h]),P=(0,g.useCallback)(function(){if(h){var e=h.selectedScrollSnap();j(e),null==x||x.scrollTo(e)}},[h,x]);return(0,g.useEffect)(function(){if(h)return P(),h.on("select",P).on("reInit",P),function(){h.off("select",P).off("reInit",P)}},[h,P]),(0,v.jsx)(Dc.Provider,{value:{axis:d,mainViewportRef:p,mainApi:h,thumbsViewportRef:y,thumbsApi:x,selectedIndex:S,scrollTo:E,thumbnails:k},children:(0,v.jsx)("div",{className:O()(DL.root,u),style:c,children:a})})}function DW(e){var t=e.children,r=e.className,n=Dd().axis;return(0,v.jsx)("div",{className:O()(DL.slide,DL["slide--".concat(n)],r),children:t})}function D$(e){var t=e.className,r=e.thumbsSliderClassName,n=Dd(),a=n.axis,i=n.thumbsViewportRef,o=n.thumbnails,s=n.selectedIndex,l=n.scrollTo;return 0===o.length?null:(0,v.jsx)("div",{ref:i,className:O()(DL.thumbsViewport,t),children:(0,v.jsx)("div",{className:O()(DL.thumbsContainer,DL["thumbsContainer--".concat(a)]),children:o.map(function(e,t){var n,a,i=t===s;return(0,v.jsx)("button",{type:"button",onClick:function(){return l(t)},className:O()(DL.thumb,(n={},a=DL["thumb--active"],a in n?Object.defineProperty(n,a,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[a]=i,n),i&&r),"aria-label":"Aller \xe0 l'\xe9l\xe9ment ".concat(t+1),"aria-current":i,children:e&&(0,v.jsx)("img",{src:e,alt:"",className:DL.thumbImage})},t)})})})}function DU(e){var t=e.className,r=e.dotClassName,n=Dd(),a=n.thumbnails,i=n.selectedIndex,o=n.scrollTo;return 0===a.length?null:(0,v.jsx)("div",{className:O()(DL.dots,t),children:a.map(function(e,t){var n,a,s;return(0,v.jsx)("button",{type:"button",onClick:function(){return o(t)},className:O()(DL.dot,(n={},a=DL["dot--active"],s=t===i,a in n?Object.defineProperty(n,a,{value:s,enumerable:!0,configurable:!0,writable:!0}):n[a]=s,n),r),"aria-label":"Aller \xe0 l'\xe9l\xe9ment ".concat(t+1),"aria-current":t===i},t)})})}function DH(e){var t=e.id,r=e.as,n=e.variant,a=void 0===n?"transparent":n,i=e.title,o=e.titleAs,s=e.description,l=e.actions,u=e.ariaLabel,c=e.bare,d=e.className,f=e.children,p=!!(i||s||l);return(0,v.jsxs)(void 0===r?"section":r,{id:t,"aria-label":u,className:["UmIprimi5rDlNw2L9yDmFQ==","panel"===a?"+B1ojNNxuYjq0VnPjP+Ekg==":"Ox7Wrjz8+j2BU7Di1Y8ELg==",void 0!==c&&c&&"panel"===a?"o-Q1RvbOEWlyFqMbRSrIoA==":"",null!=d?d:""].filter(Boolean).join(" "),children:[p&&(0,v.jsxs)("div",{className:"LrLQVHznKTKpP+sixgbcxw==",children:[(0,v.jsxs)("div",{className:"BvPyQkfXGhbXV5zz8kzPnQ==",children:[i&&(0,v.jsx)(void 0===o?"h2":o,{className:"_4RbpFTdRUk7YImbA17B5sA==",children:i}),s&&(0,v.jsx)("p",{className:"egOy0zRIXPnh18Es9FRT4Q==",children:s})]}),l&&(0,v.jsx)("div",{className:"Mx43sOmbyth8AWcB+68ebA==",children:l})]}),(0,v.jsx)("div",{className:"TGtAbo3aZ-O1gVq2zjgN5g==",children:f})]})}var DG={collapse:"Replier la section",expand:"D\xe9plier la section"},DK=(0,g.createContext)({tone:"onDark",density:"comfortable",classNames:{},labels:DG,headerLayout:"split",footerLayout:"between",divider:!0,footerDivider:!0,collapsible:!1,collapsed:!1,toggle:function(){}});function Dq(){return(0,g.useContext)(DK)}var DY={sm:{text:"h-7 px-2.5 text-xs",icon:"size-7"},md:{text:"h-8 px-3 text-[13px]",icon:"size-8"}};function DX(e){var t=e.children,r=e.icon,n=e.label,a=e.active,i=void 0!==a&&a,o=e.variant,s=void 0===o?"ghost":o,l=e.size,u=void 0===l?"md":l,c=e.href,d=e.target,f=e.rel,p=e.disabled,h=e.type,m=e.onClick,y=e.className,g=!t,b=(0,w.cn)("inline-flex shrink-0 cursor-pointer select-none items-center justify-center gap-1.5 whitespace-nowrap rounded-md","font-medium leading-none no-underline outline-none transition-colors duration-150","focus-visible:ring-2 focus-visible:ring-(--section-accent,#34d399)/70","aria-disabled:pointer-events-none aria-disabled:opacity-40 disabled:pointer-events-none disabled:opacity-40",g?(0,w.cn)(DY[u].icon,"p-0"):DY[u].text,"solid"===s?"border-0 bg-(--section-accent,#10b981) text-white hover:brightness-110":"outline"===s?(0,w.cn)("border border-solid border-(--section-line,rgba(255,255,255,0.12))",i?"bg-(--section-fg,#fff)/12 text-(--section-fg,#fff)":"bg-transparent text-(--section-muted,rgba(255,255,255,0.65)) hover:bg-(--section-fg,#fff)/8 hover:text-(--section-fg,#fff)"):(0,w.cn)("border-0",i?"bg-(--section-fg,#fff)/12 text-(--section-fg,#fff)":"bg-transparent text-(--section-muted,rgba(255,255,255,0.65)) hover:bg-(--section-fg,#fff)/8 hover:text-(--section-fg,#fff)"),y),x=(0,v.jsxs)(v.Fragment,{children:[r,t]});return c?(0,v.jsx)("a",{href:c,target:d,rel:null!=f?f:"_blank"===d?"noreferrer noopener":void 0,title:n,"aria-label":g?n:void 0,"aria-current":i||void 0,"aria-disabled":p||void 0,onClick:m,className:b,children:x}):(0,v.jsx)("button",{type:void 0===h?"button":h,title:n,"aria-label":g?n:void 0,"aria-pressed":i||void 0,disabled:p,onClick:m,className:b,children:x})}var DZ={none:"gap-0",xs:"gap-2",sm:"gap-3",md:"gap-5",lg:"gap-8",xl:"gap-10"},DQ={base:1,md:2,lg:3},DJ=["base","sm","md","lg","xl","2xl"];function D0(e){var t=e.as,r=e.columns,n=void 0===r?DQ:r,a=e.minItemWidth,i=e.gap,o=e.className,s=e.children,l={};if(a)l["--sg-min"]=a;else{var u="number"==typeof n?{base:n}:n,c=!0,d=!1,f=void 0;try{for(var p,h=DJ[Symbol.iterator]();!(c=(p=h.next()).done);c=!0){var m=p.value,y=u[m];"number"==typeof y&&y>0&&(l["--sg-".concat(m)]=String(Math.floor(y)))}}catch(e){d=!0,f=e}finally{try{c||null==h.return||h.return()}finally{if(d)throw f}}}return(0,v.jsx)(void 0===t?"div":t,{"data-section-part":"grid",style:l,className:(0,w.cn)("grid min-w-0",DZ[void 0===i?"md":i],a?"grid-cols-[repeat(auto-fill,minmax(min(100%,var(--sg-min)),1fr))]":(0,w.cn)("grid-cols-[repeat(var(--sg-base,1),minmax(0,1fr))]","sm:grid-cols-[repeat(var(--sg-sm,var(--sg-base,1)),minmax(0,1fr))]","md:grid-cols-[repeat(var(--sg-md,var(--sg-sm,var(--sg-base,1))),minmax(0,1fr))]","lg:grid-cols-[repeat(var(--sg-lg,var(--sg-md,var(--sg-sm,var(--sg-base,1)))),minmax(0,1fr))]","xl:grid-cols-[repeat(var(--sg-xl,var(--sg-lg,var(--sg-md,var(--sg-sm,var(--sg-base,1))))),minmax(0,1fr))]","2xl:grid-cols-[repeat(var(--sg-2xl,var(--sg-xl,var(--sg-lg,var(--sg-md,var(--sg-sm,var(--sg-base,1)))))),minmax(0,1fr))]"),o),children:s})}function D1(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function D2(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return D1(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return D1(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var D3={position:"--section-header-position",top:"--section-sticky-top",zIndex:"--section-sticky-z"};function D4(e){var t=e.sticky,r=e.offset,n=e.zIndex,a={};return void 0!==t&&(a[D3.position]=t?"sticky":"static"),void 0!==r&&(a[D3.top]=r),void 0!==n&&(a[D3.zIndex]=n),a}var D5=(c={},d=D3.position,f="static",d in c?Object.defineProperty(c,d,{value:f,enumerable:!0,configurable:!0,writable:!0}):c[d]=f,c);function D6(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function D8(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function D9(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var D7={compact:"pb-2",comfortable:"pb-3",spacious:"pb-4"},Ce={compact:"pt-3",comfortable:"pt-4",spacious:"pt-6"},Ct={compact:"mt-3",comfortable:"mt-4",spacious:"mt-6"},Cr={compact:"pt-2",comfortable:"pt-3",spacious:"pt-4"},Cn={sm:"text-base font-medium leading-snug",md:"text-xl font-light leading-tight sm:text-2xl",lg:"text-2xl font-light leading-tight sm:text-3xl"},Ca={split:"flex-wrap items-center justify-between",stacked:"flex-col items-start",centered:"flex-col items-center text-center"},Ci={split:"ml-auto justify-end",stacked:"justify-start",centered:"justify-center"},Co={between:"justify-between",start:"justify-start",center:"justify-center",end:"justify-end"};function Cs(e){var t=e.className,r=Dq().classNames;return(0,v.jsx)("div",{role:"presentation","aria-hidden":"true","data-section-part":"divider",className:(0,w.cn)("h-px w-full shrink-0 bg-(--section-line,rgba(255,255,255,0.12))",r.divider,t)})}function Cl(){var e=Dq(),t=e.collapsed,r=e.toggle,n=e.labels,a=e.bodyId,i=t?n.expand:n.collapse;return(0,v.jsx)("button",{type:"button",onClick:r,title:i,"aria-label":i,"aria-expanded":!t,"aria-controls":a,className:(0,w.cn)("inline-flex size-8 shrink-0 cursor-pointer items-center justify-center rounded-md border-0 p-0","bg-transparent text-(--section-muted,rgba(255,255,255,0.65)) outline-none transition-colors duration-150","hover:bg-(--section-fg,#fff)/10 hover:text-(--section-fg,#fff)","focus-visible:ring-2 focus-visible:ring-(--section-accent,#34d399)/70"),children:(0,v.jsx)("svg",{viewBox:"0 0 16 16",width:"16",height:"16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",className:(0,w.cn)("transition-transform duration-300 motion-reduce:transition-none",!t&&"rotate-180"),children:(0,v.jsx)("path",{d:"M4 6l4 4 4-4"})})})}function Cu(e){var t,r,n,a,i,o,s,l,u=e.title,c=e.titleAs,d=e.titleSize,f=e.icon,p=e.description,h=e.count,m=e.actions,y=e.children,b=e.layout,x=e.divider,S=e.className,j=Dq(),O=j.classNames,k=j.density,E=j.collapsible,P=null!=b?b:j.headerLayout,A=null!=x?x:j.divider,D=(0,g.useRef)(null),C=(t=j.stickyKey,r=(0,g.useRef)(null),a=(n=D2((0,g.useState)(!1),2))[0],i=n[1],s=(o=D2((0,g.useState)(!1),2))[0],l=o[1],(0,g.useEffect)(function(){var e=D.current;i(!!e&&"sticky"===getComputedStyle(e).position)},[D,t]),(0,g.useEffect)(function(){var e=D.current,t=r.current;if(!a||!e||!t||"u"<typeof IntersectionObserver)return void l(!1);var n=parseFloat(getComputedStyle(e).top)||0,i=new IntersectionObserver(function(e){return l(!D2(e,1)[0].isIntersecting)},{rootMargin:"-".concat(n,"px 0px 0px 0px"),threshold:0});return i.observe(t),function(){return i.disconnect()}},[D,a]),{isSticky:a,stuck:s,sentinelRef:r}),T=C.isSticky,N=C.stuck,R=C.sentinelRef,M=null!=h&&""!==h,I=null!=m&&!1!==m;return(0,v.jsxs)(v.Fragment,{children:[T?(0,v.jsx)("div",{ref:R,"aria-hidden":"true","data-section-part":"sticky-sentinel",className:"pointer-events-none -mb-px h-px w-full shrink-0"}):null,(0,v.jsxs)("div",{ref:D,"data-section-part":"header","data-stuck":T?String(N):void 0,className:(0,w.cn)("flex flex-col","[position:var(--section-header-position,static)] top-(--section-sticky-top,0px) z-(--section-sticky-z,10)","transition-[background-color,box-shadow] duration-200 motion-reduce:transition-none","data-[stuck=true]:bg-(--section-sticky-bg,rgb(8_12_20/0.72)) data-[stuck=true]:backdrop-blur-xl","data-[stuck=true]:shadow-[0_8px_24px_-12px_rgb(0_0_0/0.45)]",O.header,S),children:[(0,v.jsxs)("div",{className:(0,w.cn)("flex gap-x-4 gap-y-2",Ca[P],D7[k]),children:[null!=y?(0,v.jsx)("div",{className:"min-w-0 flex-1",children:y}):(0,v.jsxs)("div",{className:(0,w.cn)("flex min-w-0 flex-col gap-1","split"===P&&"flex-1 basis-48",O.heading),children:[(0,v.jsxs)("div",{className:(0,w.cn)("flex min-w-0 items-center gap-2.5","centered"===P&&"justify-center"),children:[f?(0,v.jsx)("span",{className:(0,w.cn)("inline-flex shrink-0 items-center justify-center text-(--section-accent,#34d399)",O.leading),children:f}):null,u?(0,v.jsx)(void 0===c?"h2":c,{id:j.headingId,className:(0,w.cn)("m-0 min-w-0 text-balance tracking-tight text-(--section-fg,#fff)",Cn[void 0===d?"md":d],O.title),children:u}):null,M?(0,v.jsx)("span",{className:(0,w.cn)("inline-flex h-5 min-w-5 shrink-0 items-center justify-center rounded-full px-1.5","bg-(--section-fg,#fff)/10 text-[11px] font-medium leading-none text-(--section-muted,rgba(255,255,255,0.65))",O.count),children:h}):null]}),p?(0,v.jsx)("p",{className:(0,w.cn)("m-0 max-w-3xl text-sm leading-relaxed text-(--section-muted,rgba(255,255,255,0.65))",O.description),children:p}):null]}),I||E?(0,v.jsxs)("div",{className:(0,w.cn)("flex flex-wrap items-center gap-1.5",Ci[P],null!=y&&"split"===P&&"shrink-0",O.actions),children:[m,E?(0,v.jsx)(Cl,{}):null]}):null]}),A?(0,v.jsx)(Cs,{}):null]})]})}function Cc(e){var t,r=e.children,n=e.flush,a=e.maxHeight,i=e.className,o=Dq(),s=o.classNames,l=o.density,u=o.collapsible,c=o.collapsed,d=o.bodyId,f=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(c))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return D6(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return D6(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),p=f[0],h=f[1],m=(0,g.useRef)(!0);(0,g.useEffect)(function(){if(m.current){m.current=!1;return}h(!0);var e=setTimeout(function(){return h(c)},320);return function(){return clearTimeout(e)}},[c]);var y=(0,v.jsx)("div",{"data-section-part":"body",className:(0,w.cn)("min-w-0",!(void 0!==n&&n)&&Ce[l],a&&"overflow-y-auto overscroll-contain",s.body,i),style:a?D9(D8({},D5),{maxHeight:a}):D5,children:r});return u?(0,v.jsx)("div",D9(D8({id:d,"aria-hidden":c||void 0},c?{inert:""}:{}),{className:(0,w.cn)("grid transition-[grid-template-rows] duration-300 ease-out motion-reduce:transition-none",c?"grid-rows-[0fr]":"grid-rows-[1fr]"),children:(0,v.jsx)("div",{className:(0,w.cn)("min-h-0",p&&"overflow-hidden"),children:y})})):(0,v.jsx)("div",{id:d,children:y})}function Cd(e){var t=e.children,r=e.actions,n=e.layout,a=e.divider,i=e.className,o=Dq(),s=o.classNames,l=o.density,u=o.collapsible,c=o.collapsed,d=null!=n?n:o.footerLayout,f=null!=a?a:o.footerDivider,p=null!=t&&!1!==t,h=null!=r&&!1!==r;return u&&c?null:(0,v.jsxs)("div",{"data-section-part":"footer",className:(0,w.cn)("flex flex-col",Ct[l],s.footer,i),children:[f?(0,v.jsx)(Cs,{}):null,(0,v.jsxs)("div",{className:(0,w.cn)("flex flex-wrap items-center gap-x-4 gap-y-2 text-xs text-(--section-muted,rgba(255,255,255,0.65))",Cr[l],Co[d]),children:[p?(0,v.jsx)("div",{className:(0,w.cn)("min-w-0",s.footerStart),children:t}):null,h?(0,v.jsx)("div",{className:(0,w.cn)("flex flex-wrap items-center gap-1.5","between"===d&&"ml-auto",s.footerEnd),children:r}):null]})]})}function Cf(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var Cp={plain:"",glass:"rounded-2xl p-5 backdrop-blur-xl ring-1 ring-inset ring-(--section-line,rgba(255,255,255,0.12))"},Ch={onDark:"bg-black/40",onLight:"bg-white/70"},Cm=new Set([Cu,Cc,Cd]);function Cy(e){return null!=e&&!1!==e&&""!==e}var Cv=Object.assign(function(e){var t,r=e.id,n=e.as,a=e.ariaLabel,i=e.variant,o=void 0===i?"plain":i,s=e.tone,l=void 0===s?"onDark":s,u=e.density,c=void 0===u?"comfortable":u,d=e.title,f=e.titleAs,p=e.titleSize,h=e.icon,m=e.description,y=e.count,b=e.actions,x=e.header,S=e.headerLayout,j=void 0===S?"split":S,O=e.divider,k=void 0===O||O,E=e.stickyHeader,P=e.stickyOffset,A=e.stickyZIndex,D=e.footer,C=e.footerActions,T=e.footerLayout,N=void 0===T?"between":T,R=e.footerDivider,M=void 0===R||R,I=e.bodyMaxHeight,L=e.bodyFlush,F=e.collapsible,B=void 0!==F&&F,V=e.collapsed,z=e.defaultCollapsed,W=e.onCollapsedChange,$=e.labels,U=e.className,H=e.classNames,G=void 0===H?{}:H,K=e.children,q=(0,g.useId)(),Y="".concat(q,"-title"),X="".concat(q,"-body"),Z=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(void 0!==z&&z))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return Cf(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Cf(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),Q=Z[0],J=Z[1],ee=B&&(null!=V?V:Q),et=(0,g.useCallback)(function(){var e=!ee;void 0===V&&J(e),null==W||W(e)},[ee,V,W]),er=Cy(d),en=(0,g.useMemo)(function(){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},DG,$)},[$]),ea=(0,g.useMemo)(function(){return{tone:l,density:c,classNames:G,labels:en,headerLayout:j,footerLayout:N,divider:k,footerDivider:M,collapsible:B,collapsed:ee,toggle:et,headingId:er?Y:void 0,bodyId:X,stickyKey:"".concat(E,"|").concat(P,"|").concat(A)}},[l,c,G,en,j,N,k,M,B,ee,et,er,Y,X,E,P,A]),ei=er||Cy(m)||Cy(b)||Cy(h)||Cy(x)||null!=y&&""!==y||B,eo=Cy(D)||Cy(C),es=Cy(K),el=g.Children.toArray(K).some(function(e){return(0,g.isValidElement)(e)&&Cm.has(e.type)});return(0,v.jsx)(DK.Provider,{value:ea,children:(0,v.jsxs)(void 0===n?"section":n,{id:r,"aria-label":a,"aria-labelledby":!a&&er?Y:void 0,"data-section-variant":o,style:D4({sticky:E,offset:P,zIndex:A}),className:(0,w.cn)("relative flex w-full min-w-0 flex-col text-(--section-fg,#fff)","onLight"===l&&"[--section-fg:#0f172a] [--section-muted:rgba(15,23,42,0.62)] [--section-line:rgba(15,23,42,0.14)] [--section-sticky-bg:rgb(255_255_255/0.82)]",Cp[o],"glass"===o&&Ch[l],U,G.root),children:[ei?(0,v.jsx)(Cu,{title:d,titleAs:f,titleSize:p,icon:h,description:m,count:y,actions:b,children:x}):null,es?el?K:(0,v.jsx)(Cc,{flush:L,maxHeight:I,children:K}):null,eo?(0,v.jsx)(Cd,{actions:C,children:D}):null]})})},{Header:Cu,Body:Cc,Footer:Cd,Divider:Cs,Action:DX,Grid:D0});function Cg(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}var Cb={none:"gap-0",sm:"gap-4",md:"gap-6",lg:"gap-10",xl:"gap-14"};function Cx(e){var t=e.name,r=e.state,n=e.select,a=e.stickyHeaders,i=e.stickyOffset,o=e.stickyZIndex,s=e.gap,l=e.renderItem,u=e.className,c=e.itemClassName,d=e.style,f=Cg({},D4({sticky:void 0===a||a,offset:void 0===i?"0px":i,zIndex:void 0===o?10:o}),d),p=(0,w.cn)("flex w-full min-w-0 flex-col",Cb[void 0===s?"lg":s],u);return(0,v.jsx)(x.ExtensionSlot,{name:t,select:n,"data-section-slot":t,className:p,style:f,children:function(e){var t=(0,v.jsx)(x.Extension,{state:r}),n={name:e.name,moduleName:e.moduleName,meta:Cg({},e.meta)};return(0,v.jsx)("div",{"data-section-slot-item":e.name,className:(0,w.cn)("min-w-0",c),children:l?l(t,n):t})}})}var Cw=(0,w.cn)("group relative flex min-w-0 flex-col rounded-2xl border border-white/10 bg-slate-900/45 p-4","text-slate-100 shadow-lg backdrop-blur-sm outline-none transition-all duration-300","hover:-translate-y-1 hover:border-teal-400/50 hover:bg-slate-900/75 hover:shadow-2xl","has-[:focus-visible]:ring-2 has-[:focus-visible]:ring-emerald-400");function CS(e){var t,r,n=e.as,a=e.className,i=e.children,o=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["as","className","children"]);return(0,v.jsx)(void 0===n?"div":n,(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-section-card":"",className:(0,w.cn)(Cw,a)},o),r=r={children:i},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))}function Cj(e){var t=e.onClick,r=e.className,n=e.children;return(0,v.jsx)("button",{type:"button",onClick:t,className:(0,w.cn)("block w-full cursor-pointer border-0 bg-transparent p-0 outline-none [color:inherit] [font:inherit] [text-align:inherit]","after:absolute after:inset-0 after:content-['']",r),children:n})}function CO(e){var t,r=e.tile,n=e.size,a=e.onSelect,i=e.className;return(0,v.jsxs)(hz.div,{whileHover:{scale:"large"===n?1.008:1.012},transition:{duration:.2},onClick:function(){return a(r)},role:"button",tabIndex:0,onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&(e.preventDefault(),a(r))},className:["ymvpF0jEa4IAfeIzmv6kDw==","large"===n?"K3WBVZtf0LrRj41QEma6fw==":"Jpm1koqsICGHnsFyzd3FHQ==",null!=i?i:""].join(" "),children:[(0,v.jsx)("img",{src:r.imageUrl,alt:r.title,className:"KeItYJ0V+t2aIAuL4MC2sg==",referrerPolicy:"no-referrer"}),(0,v.jsx)("div",{className:"F77f0L-A-DykD55SIxIydA=="}),(0,v.jsx)("div",{className:"Nneo7LfASPowiNGutwpZMw==",children:"large"===n?(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("h3",{className:"Z9u0n0R5Gm8ZhupMR8DziQ==",children:r.title}),(0,v.jsx)("span",{className:"_6EhjfpYvyP3bc6qYPrmcQA==",children:null!=(t=r.linkText)?t:"En savoir plus →"})]}):(0,v.jsx)("h4",{className:"BqcB8kB602p8kCOqH3FsDA==",children:r.title})})]})}function Ck(e){var t=e.mainTile,r=e.secondaryTiles,n=e.onSelectTile;return(0,v.jsxs)("div",{className:"tmGbjV2pLbfHuOPqhf-Huw==",children:[(0,v.jsx)(CO,{tile:t,size:"large",onSelect:n}),r.slice(0,4).map(function(e){return(0,v.jsx)(CO,{tile:e,size:"medium",onSelect:n},e.id)})]})}function CE(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function CP(e){if(Array.isArray(e))return e}function CA(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function CD(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function CC(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function CT(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function CN(e,t){return CP(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||CM(e,t)||CA()}function CR(e){return CP(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||CM(e)||CA()}function CM(e,t){if(e){if("string"==typeof e)return CE(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return CE(e,t)}}var CI=(0,g.forwardRef)(function(e,t){var r=e.left,n=e.center,a=e.right,i=e.secondary,o=e.children,s=e.sticky,l=void 0===s||s,u=e.stickyOffset,c=e.variant,d=e.ariaLabel,f=e.className,p=e.wrapperClassName;return(0,v.jsxs)("div",{className:(0,w.cn)("flex flex-col w-full z-(--z-index-sticky,200)",l&&"sticky",p),style:l?{top:void 0===u?"var(--own-offline-banner-height, 0px)":u}:void 0,children:[(0,v.jsxs)("header",{ref:t,role:"banner","aria-label":void 0===d?"Navigation principale":d,className:(0,w.cn)("relative flex w-full items-center justify-between gap-2 px-3 sm:px-4 select-none","h-(--layout-header-height,48px) border-b","border-b-(--panel-header-border,rgba(255,255,255,0.08))","text-(--colors-surface-foreground,#f4f4f4)","glass"===(void 0===c?"glass":c)?"bg-(--panel-header-background,rgba(11,25,44,0.72)) backdrop-blur-xl shadow-(--panel-header-box-shadow,0_1px_12px_rgba(0,0,0,0.25))":"bg-(--colors-surface-card,#0b192c) shadow-(--panel-header-box-shadow,none)",f),children:[(0,v.jsx)("div",{className:"flex min-w-0 shrink-0 items-center gap-2",children:r}),n?(0,v.jsx)("div",{className:"flex min-w-0 flex-1 items-center justify-center gap-2 px-2",children:n}):null,(0,v.jsx)("div",{className:"flex shrink-0 items-center gap-1",children:a}),o]}),i?(0,v.jsx)("div",{className:"w-full",children:i}):null]})}),C_=(0,g.forwardRef)(function(e,t){var r=CR([e,t]),n=r[0],a=r.slice(1),i=n.icon,o=n.label,s=n.badge,l=n.active,u=void 0!==l&&l,c=n.className,d=n.type,f=CT(n,["icon","label","badge","active","className","type"]),p=CN(a,1)[0],h=null!=s&&""!==s&&0!==s;return(0,v.jsxs)("button",CC(CD({ref:p,type:void 0===d?"button":d,title:o,"aria-label":o,"aria-pressed":u||void 0,className:(0,w.cn)("relative inline-flex h-9 min-w-9 cursor-pointer items-center justify-center rounded-md border-0 p-0","bg-transparent text-inherit transition-colors duration-150 outline-none","hover:bg-white/10 focus-visible:ring-2 focus-visible:ring-primary-400",u&&"bg-primary-500/25 text-primary-200",c)},f),{children:[i,h?(0,v.jsx)("span",{className:"absolute -right-0.5 -top-0.5 flex h-4 min-w-4 items-center justify-center rounded-full bg-error-500 px-1 text-[10px] font-bold leading-none text-white",children:s}):null]}))});function CL(e){var t=e.className;return(0,v.jsx)("div",{"aria-hidden":"true",className:(0,w.cn)("mx-1 h-5 w-px bg-white/15",t)})}var CF=(0,g.forwardRef)(function(e,t){var r=CR([e,t]),n=r[0],a=r.slice(1),i=n.src,o=n.name,s=n.active,l=n.className,u=n.type,c=CT(n,["src","name","active","className","type"]),d=CN(a,1)[0],f=o.split(/\s+/).filter(Boolean).slice(0,2).map(function(e){var t;return null==(t=e[0])?void 0:t.toUpperCase()}).join("");return(0,v.jsx)("button",CC(CD({ref:d,type:void 0===u?"button":u,title:o,"aria-label":o,className:(0,w.cn)("relative inline-flex h-8 w-8 cursor-pointer items-center justify-center overflow-hidden rounded-full p-0","border border-primary-400/50 bg-primary-900/40 text-xs font-bold text-white outline-none","transition-transform duration-150 hover:scale-105 focus-visible:ring-2 focus-visible:ring-primary-400",void 0!==s&&s&&"ring-2 ring-primary-400",l)},c),{children:i?(0,v.jsx)("img",{src:i,alt:"",className:"h-full w-full object-cover"}):f}))});function CB(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function CV(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||Cz(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Cz(e,t){if(e){if("string"==typeof e)return CB(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return CB(e,t)}}function CW(e){var t=e.sites,r=e.onSelect,n=e.height,a=e.className,i=(0,g.useRef)(0),o=function(e){return e.map(function(e){return{site:e,key:i.current++}})},s=CV((0,g.useState)(function(){return o(t)}),2),l=s[0],u=s[1],c=CV((0,g.useState)(350),2),d=c[0],f=c[1],p=(0,g.useRef)(!1),h=(0,g.useRef)(0),m=(0,g.useRef)(0);(0,g.useEffect)(function(){return u(o(t))},[t]),(0,g.useEffect)(function(){var e=function(){return f(window.matchMedia("(min-width: 640px)").matches?350:280)};return e(),window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}},[]);var y=function(e){return u(function(t){if(t.length<2)return t;for(var r=function(e){if(Array.isArray(e))return CB(e)}(t)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||Cz(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),n=0;n<Math.abs(e);n++){var a=e>0?r.shift():r.pop();if(!a)break;var o=function(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}(function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},a),{key:i.current++});e>0?r.push(o):r.unshift(o)}return r})},b=function(){var e=m.current-h.current;Math.abs(e)>=45&&y(e<0?1:-1),setTimeout(function(){p.current=!1},50)},x="flex h-12 w-12 sm:h-14 sm:w-14 items-center justify-center border-2 border-white/20 bg-slate-950/80 text-slate-100 transition-colors hover:bg-teal-500 hover:text-slate-950 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-teal-400";return(0,v.jsxs)("div",{onPointerDown:function(e){h.current=m.current=e.clientX,p.current=!1},onPointerMove:function(e){m.current=e.clientX,Math.abs(m.current-h.current)>10&&(p.current=!0)},onPointerUp:b,onPointerCancel:b,className:(0,w.cn)("relative w-full overflow-hidden cursor-grab active:cursor-grabbing touch-pan-y select-none",a),style:{height:void 0===n?500:n},children:[l.map(function(e,t){var n=e.site,a=e.key,i=l.length%2?t-(l.length+1)/2:t-l.length/2,o=0===i;return(0,v.jsxs)("div",{role:"button",tabIndex:o?0:-1,"aria-label":n.name,onKeyDown:function(e){return"Enter"===e.key&&o&&(null==r?void 0:r(n))},onClick:function(){p.current||(o?null==r||r(n):y(i))},className:(0,w.cn)("absolute left-1/2 top-1/2 cursor-pointer border-2 p-7 sm:p-8 transition-all duration-500 ease-in-out",o?"z-10 bg-teal-500 text-slate-950 border-teal-300":"z-0 bg-slate-900/70 text-slate-100 border-white/15 hover:border-teal-400/60"),style:{width:d,height:d,clipPath:"polygon(50px 0%, calc(100% - 50px) 0%, 100% 50px, 100% 100%, calc(100% - 50px) 100%, 50px 100%, 0 100%, 0 0)",transform:"translate(-50%, -50%) translateX(".concat(d/1.5*i,"px) translateY(").concat(o?-30:i%2?20:-10,"px) rotate(").concat(o?0:i%2?2.5:-2.5,"deg)"),boxShadow:o?"0 8px 0 4px rgba(255,255,255,0.14)":"none"},children:[n.imageUrl&&(0,v.jsx)("img",{src:n.imageUrl,alt:"",className:"mb-3 sm:mb-4 h-12 w-10 sm:h-14 sm:w-12 bg-slate-800 object-cover object-top rounded-xs shadow-sm"}),(0,v.jsxs)("h3",{className:"text-sm sm:text-base md:text-lg font-medium leading-snug line-clamp-4",children:[n.name," — ",n.description]}),(0,v.jsxs)("p",{className:(0,w.cn)("absolute bottom-6 sm:bottom-8 left-7 sm:left-8 right-7 sm:right-8 text-xs sm:text-sm italic truncate",o?"text-slate-950/80":"text-slate-400"),children:[n.shortName," • ",n.head," (",n.memberCount," membres, ",n.appCount," apps)"]})]},a)}),(0,v.jsxs)("div",{className:"absolute bottom-3 sm:bottom-4 left-1/2 flex -translate-x-1/2 gap-2 z-20",children:[(0,v.jsx)("button",{type:"button",onClick:function(){return y(-1)},className:x,"aria-label":"Site pr\xe9c\xe9dent",children:(0,v.jsx)(yi,{className:"w-6 h-6"})}),(0,v.jsx)("button",{type:"button",onClick:function(){return y(1)},className:x,"aria-label":"Site suivant",children:(0,v.jsx)(yo,{className:"w-6 h-6"})})]})]})}var C$=(0,ya.A)("SlidersHorizontal",[["line",{x1:"21",x2:"14",y1:"4",y2:"4",key:"obuewd"}],["line",{x1:"10",x2:"3",y1:"4",y2:"4",key:"1q6298"}],["line",{x1:"21",x2:"12",y1:"12",y2:"12",key:"1iu8h1"}],["line",{x1:"8",x2:"3",y1:"12",y2:"12",key:"ntss68"}],["line",{x1:"21",x2:"16",y1:"20",y2:"20",key:"14d8ph"}],["line",{x1:"12",x2:"3",y1:"20",y2:"20",key:"m0wm8r"}],["line",{x1:"14",x2:"14",y1:"2",y2:"6",key:"14e1ph"}],["line",{x1:"8",x2:"8",y1:"10",y2:"14",key:"1i6ji0"}],["line",{x1:"16",x2:"16",y1:"18",y2:"22",key:"1lctlv"}]]),CU=(0,ya.A)("RotateCcw",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]]);function CH(e){var t=e.value,r=e.onChange,n=e.placeholder,a=void 0===n?"Rechercher…":n,i=e.activeFilterCount,o=void 0===i?0:i,s=e.filterPanel,l=e.filtersOpen,u=void 0!==l&&l,c=e.onFiltersOpenChange,d=e.onReset,f=e.className,p=(0,g.useRef)(null),h=!!s&&(u||o>0),m="p-1.5 rounded-lg border border-white/10 text-slate-400 transition-colors cursor-pointer";return(0,v.jsxs)("div",{className:(0,w.cn)("relative rounded-2xl border border-white/15 backdrop-blur-sm shadow-lg overflow-hidden transition-all","focus-within:border-teal-400/80 focus-within:ring-2 focus-within:ring-teal-400/20",f),children:[(0,v.jsxs)("div",{className:"flex items-center px-4 py-2.5 sm:py-3 gap-3",children:[(0,v.jsx)("div",{className:"w-8 h-8 rounded-xl border border-white/10 flex items-center justify-center text-teal-300 shrink-0",children:(0,v.jsx)(O$,{className:"w-4 h-4"})}),(0,v.jsx)("input",{ref:p,type:"text",value:t,onChange:function(e){return r(e.target.value)},placeholder:a,"aria-label":a,className:"flex-1 min-w-0 bg-transparent border-none text-white placeholder-slate-400 text-xs sm:text-sm font-medium focus:outline-none truncate"}),(0,v.jsxs)("div",{className:"flex items-center gap-2 shrink-0",children:[t&&(0,v.jsx)("button",{type:"button",title:"Effacer la recherche",onClick:function(){var e;r(""),null==(e=p.current)||e.focus()},className:(0,w.cn)(m,"hover:bg-white/10 hover:text-white"),children:(0,v.jsx)(kz.A,{className:"w-3.5 h-3.5"})}),s&&(0,v.jsxs)("button",{type:"button",title:"Filtres avanc\xe9s","aria-expanded":h,onClick:function(){return null==c?void 0:c(!u)},className:(0,w.cn)("flex items-center gap-1.5 px-3 py-1.5 rounded-xl border text-xs font-semibold transition-all cursor-pointer",h?"bg-teal-500 text-slate-950 border-teal-400 shadow-sm":"text-slate-300 hover:text-white hover:bg-white/10 border-white/15"),children:[(0,v.jsx)(C$,{className:"w-3.5 h-3.5"}),(0,v.jsx)("span",{className:"hidden sm:inline",children:"Filtres"}),o>0&&(0,v.jsx)("span",{className:"min-w-[1.1rem] rounded-full bg-slate-950 px-1 text-center text-[10px] font-black leading-[1.1rem] text-teal-300",children:o})]}),d&&(t||o>0)&&(0,v.jsx)("button",{type:"button",title:"R\xe9initialiser",onClick:d,className:(0,w.cn)(m,"hover:bg-rose-500/20 hover:text-rose-300"),children:(0,v.jsx)(CU,{className:"w-3.5 h-3.5"})})]})]}),h&&(0,v.jsx)("div",{className:"dark w-full px-4 pb-3 pt-2 border-t border-white/10",children:s})]})}function CG(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function CK(e){var t,r=e.activeTab,n=e.onTabChange,a=e.tabs,i=e.sidebarHeader,o=e.sidebarFooter,s=e.mainHeader,l=e.children,u=e.className,c=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(function(){return"u"<typeof window||window.innerWidth>=768}))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return CG(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return CG(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),d=c[0],f=c[1],p=(0,g.useRef)(null);return(0,g.useEffect)(function(){var e=function(){return f(window.innerWidth>=768)};return window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}},[]),(0,v.jsx)("div",{className:(0,w.cn)("w-full h-[calc(100vh-120px)] my-2 sm:my-3 text-slate-100 overflow-hidden px-3 sm:px-6 lg:px-8 flex flex-col",u),children:(0,v.jsxs)("div",{className:"max-w-7xl w-full mx-auto flex-1 min-h-0 flex flex-col md:flex-row items-stretch gap-4 md:gap-8 overflow-hidden",children:[(0,v.jsxs)("aside",{className:"w-full md:w-[20%] shrink-0 min-w-0 flex flex-col justify-start md:justify-center space-y-2 md:space-y-4",children:[i,(0,v.jsx)("div",{ref:p,role:"tablist","aria-orientation":d?"vertical":"horizontal",onKeyDown:function(e){var t,i,o,s=a.filter(function(e){return!e.disabled}),l=s.findIndex(function(e){return e.id===r});e.key===(d?"ArrowDown":"ArrowRight")?o=s[(l+1)%s.length]:e.key===(d?"ArrowUp":"ArrowLeft")?o=s[(l-1+s.length)%s.length]:"Home"===e.key?o=s[0]:"End"===e.key&&(o=s[s.length-1]),o&&(e.preventDefault(),n(o.id),null==(i=p.current)||null==(t=i.querySelector('[data-tab="'.concat(o.id,'"]')))||t.focus())},className:"w-full flex md:flex-col items-center md:items-stretch gap-2 overflow-x-auto touch-pan-x scroll-smooth select-none py-1",children:a.map(function(e){var t=e.id===r;return(0,v.jsxs)("button",{type:"button",role:"tab","data-tab":e.id,"aria-selected":t,tabIndex:t?0:-1,disabled:e.disabled,onClick:function(){return n(e.id)},className:(0,w.cn)("shrink-0 flex items-center gap-2 text-left px-3.5 py-2 text-xs sm:text-sm md:text-base font-medium whitespace-nowrap cursor-pointer transition-all border-0 border-l-2",t?"border-teal-400 text-teal-300 bg-white/5":"border-transparent text-slate-400 hover:text-white",e.disabled&&"opacity-40 cursor-not-allowed"),children:[e.icon&&(0,v.jsx)("span",{className:"shrink-0",children:e.icon}),(0,v.jsx)("span",{children:e.label}),e.badge&&(0,v.jsx)("span",{className:"ml-auto shrink-0",children:e.badge})]},e.id)})}),o]}),(0,v.jsxs)("main",{role:"tabpanel",className:"w-full md:w-[80%] h-full flex-1 min-h-0 flex flex-col overflow-y-auto",children:[s,(0,v.jsx)("div",{className:"flex-1 min-h-0 flex flex-col",children:l})]})]})})}function Cq(e){var t=e.icon,r=e.title,n=e.description,a=e.actions,i=e.className;return(0,v.jsxs)("div",{className:(0,w.cn)("flex flex-col sm:flex-row sm:items-center justify-between gap-3 p-3 rounded-xl bg-slate-900/60 border border-white/10 backdrop-blur-md shrink-0",i),children:[(0,v.jsxs)("div",{className:"min-w-0",children:[(0,v.jsxs)("div",{className:"flex items-center gap-2",children:[t,(0,v.jsx)("h2",{className:"text-sm sm:text-base font-bold text-white truncate",children:r})]}),n&&(0,v.jsx)("p",{className:"text-xs text-slate-400 mt-0.5",children:n})]}),a&&(0,v.jsx)("div",{className:"shrink-0 self-start sm:self-auto",children:a})]})}var CY=(0,ya.A)("ExternalLink",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);function CX(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function CZ(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||CQ(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function CQ(e,t){if(e){if("string"==typeof e)return CX(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return CX(e,t)}}function CJ(e){var t=e.applications,r=e.onOpen,n=e.title,a=e.description,i=e.allLabel,o=void 0===i?"Tous":i,s=e.className,l=CZ((0,g.useState)(""),2),u=l[0],c=l[1],d=CZ((0,g.useState)(o),2),f=d[0],p=d[1],h=(0,g.useMemo)(function(){var e;return[o].concat(function(e){if(Array.isArray(e))return CX(e)}(e=Array.from(new Set(t.map(function(e){return e.category}))))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||CQ(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())},[t,o]),m=(0,g.useMemo)(function(){var e=u.trim().toLowerCase();return t.filter(function(t){return(f===o||t.category===f)&&(!e||t.name.toLowerCase().includes(e)||t.description.toLowerCase().includes(e))})},[t,u,f,o]);return(0,v.jsxs)("div",{className:(0,w.cn)("space-y-6",s),children:[(0,v.jsxs)("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4 pb-4 border-b border-white/10",children:[(0,v.jsxs)("div",{children:[(0,v.jsx)("h2",{className:"text-xl font-bold text-white",children:void 0===n?"Applications & Outils M\xe9tier":n}),(0,v.jsx)("p",{className:"text-xs text-slate-300 mt-1",children:void 0===a?"S\xe9lectionnez une application pour y acc\xe9der directement.":a})]}),(0,v.jsxs)("div",{className:"relative w-full sm:w-64",children:[(0,v.jsx)(O$,{className:"w-4 h-4 text-slate-400 absolute left-3 top-2.5"}),(0,v.jsx)("input",{type:"text",value:u,onChange:function(e){return c(e.target.value)},placeholder:"Rechercher un outil...","aria-label":"Rechercher un outil",className:"w-full bg-slate-900/80 text-white placeholder-slate-400 text-xs pl-9 pr-3 py-2 rounded-lg border border-white/10 focus:outline-hidden focus:border-teal-400/50"})]})]}),(0,v.jsx)("div",{className:"flex flex-wrap gap-3 text-xs font-medium",children:h.map(function(e){return(0,v.jsx)("button",{type:"button",onClick:function(){return p(e)},className:(0,w.cn)("transition-colors cursor-pointer",f===e?"text-teal-300 font-bold border-b-2 border-teal-400 pb-0.5":"text-slate-400 hover:text-white"),children:e},e)})}),(0,v.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:m.map(function(e){var t,n=e.icon;return(0,v.jsxs)("button",{type:"button",onClick:function(){return r(e)},className:"group text-left p-4 rounded-xl bg-slate-900/60 border border-white/10 hover:border-teal-400/40 hover:bg-slate-800/80 transition-all cursor-pointer flex flex-col justify-between space-y-3",children:[(0,v.jsxs)("div",{className:"space-y-2",children:[(0,v.jsxs)("div",{className:"flex items-center justify-between",children:[(0,v.jsx)("div",{className:(0,w.cn)("p-2 rounded-lg bg-gradient-to-br text-white shadow-xs",null!=(t=e.gradient)?t:"from-teal-500 to-emerald-600"),children:(0,v.jsx)(n,{className:"w-5 h-5"})}),(0,v.jsx)("span",{className:"text-[10px] font-semibold text-slate-400",children:e.status})]}),(0,v.jsxs)("div",{children:[(0,v.jsxs)("h3",{className:"text-sm font-bold text-white group-hover:text-teal-300 transition-colors flex items-center justify-between",children:[(0,v.jsx)("span",{children:e.name}),(0,v.jsx)(CY,{className:"w-3.5 h-3.5 opacity-0 group-hover:opacity-100 transition-opacity text-teal-300"})]}),(0,v.jsx)("p",{className:"text-[11px] text-teal-400/80 font-medium mt-0.5",children:e.category})]}),(0,v.jsx)("p",{className:"text-xs text-slate-300 line-clamp-2 leading-relaxed",children:e.description})]}),(0,v.jsxs)("div",{className:"pt-2 border-t border-white/5 flex items-center justify-between text-[11px] text-slate-400 group-hover:text-slate-200",children:[(0,v.jsx)("span",{children:"Acc\xe9der \xe0 l'application"}),(0,v.jsx)("span",{className:"text-teal-400 font-semibold group-hover:translate-x-1 transition-transform",children:"→"})]})]},e.id)})})]})}var C0=(0,ya.A)("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]),C1={teal:{card:"from-teal-900/50 to-slate-900 border-teal-500/30 hover:border-teal-400",text:"text-teal-300",icon:"text-teal-400"},cyan:{card:"from-cyan-900/50 to-slate-900 border-cyan-500/30 hover:border-cyan-400",text:"text-cyan-300",icon:"text-cyan-400"}};function C2(e){var t=e.resources,r=e.shortcuts,n=void 0===r?[]:r,a=e.onShortcut,i=e.onDownload,o=e.primaryAction,s=e.title,l=e.description,u=e.className;return(0,v.jsxs)("div",{className:(0,w.cn)("space-y-6",u),children:[(0,v.jsxs)("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4 pb-4 border-b border-white/10",children:[(0,v.jsxs)("div",{children:[(0,v.jsx)("h2",{className:"text-xl font-bold text-white",children:void 0===s?"Ressources Documentaires & GED":s}),(0,v.jsx)("p",{className:"text-xs text-slate-300 mt-1",children:void 0===l?"Guides, formulaires administratifs et acc\xe8s direct \xe0 la Gestion \xc9lectronique des Documents.":l})]}),o]}),n.length>0&&(0,v.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:n.map(function(e){var t,r=C1[null!=(t=e.tone)?t:"teal"],n=e.icon;return(0,v.jsxs)("button",{type:"button",onClick:function(){return null==a?void 0:a(e)},className:(0,w.cn)("text-left p-4 rounded-xl bg-gradient-to-r border transition-all cursor-pointer flex items-center justify-between",r.card),children:[(0,v.jsxs)("span",{className:"space-y-1",children:[(0,v.jsx)("span",{className:(0,w.cn)("block text-[10px] font-bold uppercase tracking-wider",r.text),children:e.eyebrow}),(0,v.jsx)("span",{className:"block text-sm font-bold text-white",children:e.title}),(0,v.jsx)("span",{className:"block text-xs text-slate-300",children:e.description})]}),(0,v.jsx)(n,{className:(0,w.cn)("w-8 h-8 shrink-0 ml-2",r.icon)})]},e.id)})}),(0,v.jsxs)("div",{className:"space-y-3",children:[(0,v.jsx)("h3",{className:"text-xs font-bold uppercase tracking-wider text-slate-400",children:"Documents r\xe9cents & proc\xe9dures officielles"}),(0,v.jsx)("ul",{className:"space-y-2",children:t.map(function(e){return(0,v.jsxs)("li",{className:"p-3 rounded-lg bg-slate-900/60 border border-white/10 hover:border-teal-400/40 flex items-center justify-between transition-colors",children:[(0,v.jsxs)("div",{className:"flex items-center gap-3 min-w-0",children:[(0,v.jsx)("div",{className:"p-2 rounded-lg bg-white/5 text-teal-300 shrink-0",children:(0,v.jsx)(OQ,{className:"w-4 h-4"})}),(0,v.jsxs)("div",{className:"min-w-0",children:[(0,v.jsx)("h4",{className:"text-xs font-bold text-white truncate",children:e.title}),(0,v.jsxs)("p",{className:"flex flex-wrap items-center gap-1.5 sm:gap-3 text-[10px] text-slate-400 mt-0.5",children:[(0,v.jsx)("span",{className:"text-teal-400 font-semibold",children:e.category}),(0,v.jsx)("span",{children:"•"}),(0,v.jsx)("span",{children:e.type}),(0,v.jsx)("span",{children:"•"}),(0,v.jsx)("span",{children:e.size}),(0,v.jsx)("span",{children:"•"}),(0,v.jsxs)("span",{children:["Mis \xe0 jour le ",e.updated]})]})]})]}),i&&(0,v.jsx)("button",{type:"button",title:"T\xe9l\xe9charger","aria-label":"T\xe9l\xe9charger ".concat(e.title),onClick:function(){return i(e)},className:"p-2 rounded-lg hover:bg-white/10 text-slate-300 hover:text-white transition-colors cursor-pointer shrink-0 ml-2",children:(0,v.jsx)(C0,{className:"w-4 h-4"})})]},e.id)})})]})]})}var C3=(0,ya.A)("List",[["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 18h.01",key:"1tta3j"}],["path",{d:"M3 6h.01",key:"1rqtza"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 18h13",key:"1lx6n3"}],["path",{d:"M8 6h13",key:"ik3vkj"}]]);function C4(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function C5(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return C4(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return C4(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var C6="ABCDEFGHIJKLMNOPQRSTUVWXYZ".split("");function C8(e){var t=e.member,r=e.size;return t.avatar?(0,v.jsx)("img",{src:t.avatar,alt:"",className:(0,w.cn)("rounded-full object-cover border border-white/20 shrink-0",r)}):(0,v.jsx)("span",{className:(0,w.cn)("rounded-full bg-teal-600/40 border border-white/20 flex items-center justify-center font-bold text-teal-100 shrink-0",r),children:t.name.slice(0,1).toUpperCase()})}function C9(e){var t=e.siteName,r=e.members,n=e.teams,a=void 0===n?[]:n,i=e.onSelect,o=e.className,s=C5((0,g.useState)(""),2),l=s[0],u=s[1],c=C5((0,g.useState)("all"),2),d=c[0],f=c[1],p=C5((0,g.useState)(""),2),h=p[0],m=p[1],y=C5((0,g.useState)("grid"),2),b=y[0],x=y[1],S=(0,g.useMemo)(function(){return new Set(r.map(function(e){return e.name.slice(0,1).toUpperCase()}))},[r]),j=(0,g.useMemo)(function(){var e=l.trim().toLowerCase();return r.filter(function(t){return("all"===d||t.teamId===d)&&(!h||t.name.toUpperCase().startsWith(h))&&(!e||[t.name,t.role,t.email,t.phone].some(function(t){return null==t?void 0:t.toLowerCase().includes(e)}))}).sort(function(e,t){return e.name.localeCompare(t.name,"fr")})},[r,l,d,h]),O=function(e){return(0,w.cn)("px-3 py-1 rounded-full border text-xs font-medium whitespace-nowrap transition-colors cursor-pointer",e?"bg-teal-500 text-slate-950 border-teal-400 font-bold":"border-white/15 text-slate-300 hover:text-white hover:bg-white/10")};return(0,v.jsxs)("div",{className:(0,w.cn)("flex-1 min-h-0 flex flex-col gap-3 text-slate-100",o),children:[(0,v.jsx)(Cq,{icon:(0,v.jsx)(OG,{className:"w-4 h-4 text-teal-400"}),title:"Membres & \xc9quipes — ".concat(t),description:"".concat(j.length," membre").concat(j.length>1?"s":""," affich\xe9").concat(j.length>1?"s":""," sur ").concat(r.length),actions:(0,v.jsx)("div",{className:"flex items-center gap-1 bg-white/5 p-1 rounded-lg border border-white/10",children:["grid","list"].map(function(e){return(0,v.jsx)("button",{type:"button","aria-pressed":b===e,"aria-label":"grid"===e?"Vue grille":"Vue liste",onClick:function(){return x(e)},className:(0,w.cn)("p-1.5 rounded-md cursor-pointer",b===e?"bg-teal-500 text-slate-950":"text-slate-300 hover:text-white"),children:"grid"===e?(0,v.jsx)(OF,{className:"w-4 h-4"}):(0,v.jsx)(C3,{className:"w-4 h-4"})},e)})})}),(0,v.jsxs)("div",{className:"relative",children:[(0,v.jsx)(O$,{className:"w-4 h-4 text-slate-400 absolute left-3 top-2.5"}),(0,v.jsx)("input",{type:"text",value:l,onChange:function(e){return u(e.target.value)},placeholder:"Rechercher par nom, fonction, e-mail ou t\xe9l\xe9phone...","aria-label":"Rechercher un membre",className:"w-full bg-slate-900/80 text-white placeholder-slate-400 text-xs pl-9 pr-3 py-2 rounded-lg border border-white/10 focus:outline-hidden focus:border-teal-400/50"})]}),a.length>0&&(0,v.jsxs)("div",{className:"flex gap-2 overflow-x-auto pb-1",children:[(0,v.jsx)("button",{type:"button",className:O("all"===d),onClick:function(){return f("all")},children:"Toutes les \xe9quipes"}),a.map(function(e){return(0,v.jsx)("button",{type:"button",className:O(d===e.id),onClick:function(){return f(e.id)},children:e.name},e.id)})]}),(0,v.jsxs)("div",{className:"flex gap-1 overflow-x-auto text-[11px]","aria-label":"Filtre alphab\xe9tique",children:[(0,v.jsx)("button",{type:"button",className:O(!h),onClick:function(){return m("")},children:"Tous"}),C6.map(function(e){return(0,v.jsx)("button",{type:"button",disabled:!S.has(e),onClick:function(){return m(h===e?"":e)},className:(0,w.cn)(O(h===e),"px-2 disabled:opacity-30 disabled:cursor-not-allowed"),children:e},e)})]}),(0,v.jsx)("div",{className:"flex-1 min-h-0 overflow-y-auto pr-1",children:0===j.length?(0,v.jsx)("p",{className:"text-center py-12 text-slate-400 text-xs",children:"Aucun membre ne correspond \xe0 votre recherche."}):"grid"===b?(0,v.jsx)("ul",{className:"grid grid-cols-1 sm:grid-cols-2 xl:grid-cols-3 gap-3",children:j.map(function(e){return(0,v.jsx)("li",{children:(0,v.jsxs)("button",{type:"button",onClick:function(){return null==i?void 0:i(e)},className:"w-full text-left p-4 rounded-xl bg-slate-900/60 border border-white/10 hover:border-teal-400/40 hover:bg-slate-800/80 transition-all cursor-pointer flex items-center gap-3",children:[(0,v.jsx)(C8,{member:e,size:"w-12 h-12 text-base"}),(0,v.jsxs)("span",{className:"min-w-0",children:[(0,v.jsx)("span",{className:"block text-sm font-bold text-white truncate",children:e.name}),(0,v.jsx)("span",{className:"block text-[11px] text-teal-400/80 truncate",children:e.role}),e.email&&(0,v.jsx)("span",{className:"block text-[11px] text-slate-400 truncate",children:e.email})]})]})},e.id)})}):(0,v.jsx)("ul",{className:"divide-y divide-white/10 rounded-xl border border-white/10 bg-slate-900/60",children:j.map(function(e){return(0,v.jsx)("li",{children:(0,v.jsxs)("button",{type:"button",onClick:function(){return null==i?void 0:i(e)},className:"w-full text-left px-3 py-2 hover:bg-white/5 transition-colors cursor-pointer flex items-center gap-3",children:[(0,v.jsx)(C8,{member:e,size:"w-8 h-8 text-xs"}),(0,v.jsx)("span",{className:"flex-1 min-w-0 text-xs font-semibold text-white truncate",children:e.name}),(0,v.jsx)("span",{className:"hidden sm:block text-[11px] text-teal-400/80 truncate max-w-[40%]",children:e.role}),e.email&&(0,v.jsx)("span",{className:"hidden lg:block text-[11px] text-slate-400 truncate max-w-[30%]",children:e.email})]})},e.id)})})})]})}var C7=(0,ya.A)("SquareCheckBig",[["path",{d:"M21 10.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.5",key:"1uzm8b"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]),Te=(0,ya.A)("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]),Tt=r(3601),Tr=(0,ya.A)("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]),Tn=(0,ya.A)("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);function Ta(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ti(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function To(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function Ts(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Ta(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Ta(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Tl=[{id:"all",label:"Toutes"},{id:"todo",label:"\xc0 faire"},{id:"in_progress",label:"En cours"},{id:"done",label:"Termin\xe9es"}],Tu={haute:{label:"Priorit\xe9 Haute",cls:"bg-rose-500/20 text-rose-300 border-rose-500/30"},moyenne:{label:"Priorit\xe9 Moyenne",cls:"bg-amber-500/20 text-amber-300 border-amber-500/30"},basse:{label:"Priorit\xe9 Normale",cls:"bg-emerald-500/20 text-emerald-300 border-emerald-500/30"}},Tc="w-full px-3 py-1.5 rounded-lg bg-black/40 border border-white/15 text-xs text-white placeholder-slate-500 focus:outline-none focus:border-teal-400";function Td(e){var t=e.siteName,r=e.tasks,n=e.onToggleStatus,a=e.onCreate,i=e.className,o=Ts((0,g.useState)("all"),2),s=o[0],l=o[1],u=Ts((0,g.useState)(""),2),c=u[0],d=u[1],f=Ts((0,g.useState)(!1),2),p=f[0],h=f[1],m=Ts((0,g.useState)({title:"",description:"",priority:"moyenne",dueDate:""}),2),y=m[0],b=m[1],x=(0,g.useMemo)(function(){return{all:r.length,todo:r.filter(function(e){return"todo"===e.status}).length,in_progress:r.filter(function(e){return"in_progress"===e.status}).length,done:r.filter(function(e){return"done"===e.status}).length}},[r]),S=(0,g.useMemo)(function(){var e=c.trim().toLowerCase();return r.filter(function(t){return("all"===s||t.status===s)&&(!e||t.title.toLowerCase().includes(e)||t.description.toLowerCase().includes(e))})},[r,s,c]);return(0,v.jsxs)("div",{className:(0,w.cn)("flex-1 min-h-0 flex flex-col gap-3 text-slate-100",i),children:[(0,v.jsx)(Cq,{icon:(0,v.jsx)(C7,{className:"w-4 h-4 text-teal-400"}),title:"Mes t\xe2ches — ".concat(t),description:"Suivi des livrables, validations documentaires et actions assign\xe9es dans cet espace.",actions:(0,v.jsxs)("button",{type:"button",onClick:function(){return h(!0)},className:"px-3 py-1.5 rounded-lg bg-teal-500 hover:bg-teal-400 text-slate-950 font-bold text-xs flex items-center gap-1.5 shadow-md transition-all active:scale-95 cursor-pointer",children:[(0,v.jsx)(Te,{className:"w-4 h-4"}),(0,v.jsx)("span",{children:"Nouvelle t\xe2che"})]})}),(0,v.jsxs)("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-2",children:[(0,v.jsx)("div",{className:"flex items-center gap-1 bg-white/5 p-1 rounded-xl border border-white/10 text-xs overflow-x-auto",children:Tl.map(function(e){return(0,v.jsxs)("button",{type:"button",onClick:function(){return l(e.id)},className:(0,w.cn)("px-3 py-1 rounded-lg font-medium whitespace-nowrap transition-colors cursor-pointer",s===e.id?"bg-teal-500 text-slate-950 font-bold":"text-slate-300 hover:text-white"),children:[e.label," (",x[e.id],")"]},e.id)})}),(0,v.jsxs)("div",{className:"relative w-full sm:w-64",children:[(0,v.jsx)(O$,{className:"w-3.5 h-3.5 absolute left-3 top-1/2 -translate-y-1/2 text-slate-400"}),(0,v.jsx)("input",{type:"text",value:c,onChange:function(e){return d(e.target.value)},placeholder:"Rechercher une t\xe2che...","aria-label":"Rechercher une t\xe2che",className:"w-full pl-8 pr-3 py-1 rounded-lg bg-slate-900/60 border border-white/10 text-xs text-white placeholder-slate-400 focus:outline-none focus:border-teal-400/80"})]})]}),(0,v.jsx)("div",{className:"flex-1 min-h-0 overflow-y-auto space-y-2 pr-1",children:0===S.length?(0,v.jsxs)("div",{className:"text-center py-12 text-slate-400 text-xs",children:[(0,v.jsx)(Tt.A,{className:"w-8 h-8 mx-auto mb-2 text-slate-500"}),"Aucune t\xe2che ne correspond \xe0 vos filtres."]}):S.map(function(e){return(0,v.jsxs)("div",{className:(0,w.cn)("p-3 rounded-xl border transition-all flex flex-col sm:flex-row items-start sm:items-center justify-between gap-3","done"===e.status?"bg-slate-950/40 border-white/5 opacity-70":"bg-slate-900/60 border-white/10 hover:border-teal-400/40"),children:[(0,v.jsxs)("div",{className:"flex items-start gap-3 flex-1 min-w-0",children:[(0,v.jsxs)("button",{type:"button",onClick:function(){return n(e)},title:"Changer le statut","aria-label":"Changer le statut de ".concat(e.title),className:(0,w.cn)("mt-0.5 w-5 h-5 rounded-md border flex items-center justify-center transition-colors cursor-pointer shrink-0","done"===e.status?"bg-emerald-500 border-emerald-400 text-slate-950":"in_progress"===e.status?"bg-amber-500/20 border-amber-400 text-amber-300":"border-white/20 hover:border-teal-400"),children:["done"===e.status&&(0,v.jsx)(Tr,{className:"w-3.5 h-3.5"}),"in_progress"===e.status&&(0,v.jsx)("span",{className:"w-2 h-2 rounded-full bg-amber-400"})]}),(0,v.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,v.jsx)("h4",{className:(0,w.cn)("text-xs sm:text-sm font-semibold text-white","done"===e.status&&"line-through text-slate-400"),children:e.title}),(0,v.jsx)("p",{className:"text-[11px] text-slate-400 mt-0.5 line-clamp-2",children:e.description}),(0,v.jsxs)("div",{className:"flex flex-wrap items-center gap-2 mt-2 text-[10px]",children:[(0,v.jsxs)("span",{className:"flex items-center gap-1 text-slate-400",children:[(0,v.jsx)(OK,{className:"w-3 h-3"}),e.dueDate]}),(0,v.jsx)("span",{className:"text-white/20",children:"•"}),(0,v.jsxs)("span",{className:"flex items-center gap-1 text-slate-400",children:[(0,v.jsx)(Tn,{className:"w-3 h-3 text-teal-400"}),"Assign\xe9 \xe0 : ",(0,v.jsx)("strong",{className:"text-slate-200",children:e.assignedTo})]}),e.tags.map(function(e){return(0,v.jsx)("span",{className:"px-1.5 rounded bg-white/5 border border-white/10 text-slate-300",children:e},e)})]})]})]}),(0,v.jsxs)("div",{className:"flex sm:flex-col items-center sm:items-end justify-between w-full sm:w-auto gap-1 shrink-0",children:[(0,v.jsx)("span",{className:(0,w.cn)("px-2 py-0.5 rounded-full text-[10px] font-bold uppercase border",Tu[e.priority].cls),children:Tu[e.priority].label}),(0,v.jsx)("span",{className:(0,w.cn)("text-[10px] font-semibold","done"===e.status?"text-emerald-400":"in_progress"===e.status?"text-amber-400":"text-slate-400"),children:"done"===e.status?"✓ Termin\xe9e":"in_progress"===e.status?"● En cours":"○ \xc0 faire"})]})]},e.id)})}),p&&(0,v.jsx)("div",{role:"dialog","aria-modal":"true","aria-label":"Nouvelle t\xe2che",className:"fixed inset-0 z-50 flex items-center justify-center p-4 bg-black/60 backdrop-blur-sm",onKeyDown:function(e){return"Escape"===e.key&&h(!1)},children:(0,v.jsxs)("div",{className:"w-full max-w-md rounded-2xl bg-slate-900 border border-white/20 p-5 shadow-2xl",children:[(0,v.jsxs)("div",{className:"flex items-center justify-between pb-3 border-b border-white/10",children:[(0,v.jsxs)("h3",{className:"font-bold text-sm text-white flex items-center gap-2",children:[(0,v.jsx)(C7,{className:"w-4 h-4 text-teal-400"}),"Nouvelle t\xe2che pour ",t]}),(0,v.jsx)("button",{type:"button","aria-label":"Fermer",onClick:function(){return h(!1)},className:"text-slate-400 hover:text-white cursor-pointer",children:(0,v.jsx)(kz.A,{className:"w-4 h-4"})})]}),(0,v.jsxs)("form",{onSubmit:function(e){e.preventDefault(),y.title.trim()&&(a(To(Ti({},y),{title:y.title.trim(),description:y.description.trim()})),b({title:"",description:"",priority:"moyenne",dueDate:""}),h(!1))},className:"space-y-3 mt-4",children:[(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Titre de la t\xe2che"}),(0,v.jsx)("input",{autoFocus:!0,required:!0,className:Tc,value:y.title,onChange:function(e){return b(To(Ti({},y),{title:e.target.value}))}})]}),(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Description / Consignes"}),(0,v.jsx)("textarea",{rows:3,className:(0,w.cn)(Tc,"resize-none"),value:y.description,onChange:function(e){return b(To(Ti({},y),{description:e.target.value}))}})]}),(0,v.jsxs)("div",{className:"grid grid-cols-2 gap-3",children:[(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Priorit\xe9"}),(0,v.jsxs)("select",{className:Tc,value:y.priority,onChange:function(e){return b(To(Ti({},y),{priority:e.target.value}))},children:[(0,v.jsx)("option",{value:"haute",children:"Haute"}),(0,v.jsx)("option",{value:"moyenne",children:"Moyenne"}),(0,v.jsx)("option",{value:"basse",children:"Basse"})]})]}),(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"\xc9ch\xe9ance"}),(0,v.jsx)("input",{className:Tc,value:y.dueDate,onChange:function(e){return b(To(Ti({},y),{dueDate:e.target.value}))}})]})]}),(0,v.jsxs)("div",{className:"flex items-center justify-end gap-2 pt-3 border-t border-white/10",children:[(0,v.jsx)("button",{type:"button",onClick:function(){return h(!1)},className:"px-3 py-1.5 rounded-lg text-xs text-slate-300 hover:text-white cursor-pointer",children:"Annuler"}),(0,v.jsx)("button",{type:"submit",className:"px-4 py-1.5 rounded-lg bg-teal-500 hover:bg-teal-400 text-slate-950 font-bold text-xs shadow-md active:scale-95 cursor-pointer",children:"Cr\xe9er la t\xe2che"})]})]})]})})]})}var Tf=(0,ya.A)("Activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]),Tp=(0,ya.A)("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);function Th(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Tm(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function Ty(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Th(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Th(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Tv=[{id:"all",label:"Tous les \xe9v\xe9nements"},{id:"upload",label:"T\xe9l\xe9versements & GED"},{id:"validate",label:"Validations & Scellements"},{id:"member_join",label:"Habilitations & Membres"},{id:"security",label:"S\xe9curit\xe9 & Audit"}],Tg={upload:{cls:"bg-sky-500",glyph:"↑"},validate:{cls:"bg-emerald-500",glyph:"✓"},member_join:{cls:"bg-amber-500",glyph:"+"},security:{cls:"bg-indigo-500",glyph:"!"},edit:{cls:"bg-teal-500",glyph:"✎"}};function Tb(e){var t=e.siteName,r=e.activities,n=e.onRefresh,a=e.className,i=Ty((0,g.useState)("all"),2),o=i[0],s=i[1],l=Ty((0,g.useState)(!1),2),u=l[0],c=l[1],d=(0,g.useMemo)(function(){return r.filter(function(e){return"all"===o||e.action===o})},[r,o]);return(0,v.jsxs)("div",{className:(0,w.cn)("flex-1 min-h-0 flex flex-col gap-3 text-slate-100",a),children:[(0,v.jsx)(Cq,{icon:(0,v.jsx)(Tf,{className:"w-4 h-4 text-sky-400"}),title:"Activit\xe9 & Journal d'Audit — ".concat(t),description:"Tra\xe7abilit\xe9 en temps r\xe9el des versements, consultations, modifications et habilitations du site.",actions:n&&(0,v.jsxs)("button",{type:"button",disabled:u,onClick:function(){var e;return(e=function(){return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(e){switch(e.label){case 0:c(!0),e.label=1;case 1:return e.trys.push([1,,3,4]),[4,null==n?void 0:n()];case 2:return e.sent(),[3,4];case 3:return c(!1),[7];case 4:return[2]}})},function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){Tm(i,n,a,o,s,"next",e)}function s(e){Tm(i,n,a,o,s,"throw",e)}o(void 0)})})()},className:"px-3 py-1.5 rounded-lg bg-white/5 hover:bg-white/10 border border-white/10 text-slate-200 text-xs flex items-center gap-1.5 transition-colors cursor-pointer disabled:opacity-60",children:[(0,v.jsx)(Tp,{className:(0,w.cn)("w-3.5 h-3.5",u&&"animate-spin text-teal-400")}),(0,v.jsx)("span",{children:"Actualiser le flux"})]})}),(0,v.jsx)("div",{className:"flex items-center gap-1 bg-white/5 p-1 rounded-xl border border-white/10 text-xs overflow-x-auto",children:Tv.map(function(e){return(0,v.jsxs)("button",{type:"button",onClick:function(){return s(e.id)},className:(0,w.cn)("px-3 py-1 rounded-lg font-medium whitespace-nowrap transition-colors cursor-pointer",o===e.id?"bg-sky-500 text-slate-950 font-bold":"text-slate-300 hover:text-white"),children:[e.label,"all"===e.id&&" (".concat(r.length,")")]},e.id)})}),(0,v.jsx)("ul",{className:"flex-1 min-h-0 overflow-y-auto space-y-2 pr-1",children:d.map(function(e){return(0,v.jsxs)("li",{className:"p-3 rounded-xl bg-slate-900/60 border border-white/10 hover:border-sky-400/40 transition-all flex items-start gap-3",children:[(0,v.jsxs)("div",{className:"relative shrink-0",children:[e.userAvatar?(0,v.jsx)("img",{src:e.userAvatar,alt:"",className:"w-8 h-8 rounded-full object-cover border border-white/20"}):(0,v.jsx)("span",{className:"w-8 h-8 rounded-full bg-slate-700 border border-white/20 flex items-center justify-center text-[11px] font-bold",children:e.userName.slice(0,1)}),(0,v.jsx)("span",{"aria-hidden":"true",className:(0,w.cn)("absolute -bottom-1 -right-1 w-4 h-4 rounded-full flex items-center justify-center text-[9px] font-bold text-white border border-slate-950",Tg[e.action].cls),children:Tg[e.action].glyph})]}),(0,v.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,v.jsxs)("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-1",children:[(0,v.jsxs)("p",{className:"text-xs text-white",children:[(0,v.jsx)("strong",{className:"font-semibold text-sky-300",children:e.userName}),(0,v.jsxs)("span",{className:"text-slate-400",children:[" (",e.userRole,") "]}),(0,v.jsx)("span",{className:"text-slate-300",children:e.actionLabel})]}),(0,v.jsx)("span",{className:"text-[10px] text-slate-400 shrink-0 font-mono",children:e.timeAgo})]}),(0,v.jsxs)("div",{className:"mt-1.5 flex items-center gap-2 p-2 rounded-lg bg-black/30 border border-white/5",children:[(0,v.jsx)(OQ,{className:"w-3.5 h-3.5 text-sky-400 shrink-0"}),(0,v.jsx)("span",{className:"text-xs font-semibold text-white truncate",children:e.targetTitle}),(0,v.jsx)("span",{className:"ml-auto text-[9px] px-1.5 rounded bg-white/10 text-slate-300 shrink-0",children:e.targetType})]})]})]},e.id)})})]})}var Tx=(0,ya.A)("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]),Tw=(0,ya.A)("SlidersVertical",[["line",{x1:"4",x2:"4",y1:"21",y2:"14",key:"1p332r"}],["line",{x1:"4",x2:"4",y1:"10",y2:"3",key:"gb41h5"}],["line",{x1:"12",x2:"12",y1:"21",y2:"12",key:"hf2csr"}],["line",{x1:"12",x2:"12",y1:"8",y2:"3",key:"1kfi7u"}],["line",{x1:"20",x2:"20",y1:"21",y2:"16",key:"1lhrwl"}],["line",{x1:"20",x2:"20",y1:"12",y2:"3",key:"16vvfq"}],["line",{x1:"2",x2:"6",y1:"14",y2:"14",key:"1uebub"}],["line",{x1:"10",x2:"14",y1:"8",y2:"8",key:"1yglbp"}],["line",{x1:"18",x2:"22",y1:"16",y2:"16",key:"1jxqpz"}]]),TS=(0,ya.A)("Shield",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]),Tj=(0,ya.A)("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]]),TO=(0,ya.A)("Save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);function Tk(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function TE(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function TP(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Tk(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Tk(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var TA=[{id:"PUBLIC",label:"Public",hint:"Accessible \xe0 tous les collaborateurs de l'organisation.",icon:OJ},{id:"MODERATED",label:"Mod\xe9r\xe9",hint:"Adh\xe9sion soumise \xe0 l'approbation du gestionnaire du site.",icon:OG},{id:"PRIVATE",label:"Priv\xe9",hint:"Strictement r\xe9serv\xe9 aux membres invit\xe9s manuellement.",icon:Tx}],TD="p-4 rounded-xl bg-slate-900/60 border border-white/10 space-y-3",TC="text-xs font-bold text-teal-300 uppercase tracking-wider flex items-center gap-2",TT="w-full px-3 py-1.5 rounded-lg bg-black/40 border border-white/15 text-xs text-white focus:outline-none focus:border-teal-400";function TN(e){var t=e.label,r=e.hint,n=e.checked,a=e.onChange;return(0,v.jsxs)("label",{className:"flex items-center justify-between gap-3 cursor-pointer",children:[(0,v.jsxs)("span",{children:[(0,v.jsx)("span",{className:"block text-xs font-semibold text-white",children:t}),r&&(0,v.jsx)("span",{className:"block text-[11px] text-slate-400",children:r})]}),(0,v.jsx)("input",{type:"checkbox",checked:n,onChange:function(e){return a(e.target.checked)},className:"w-4 h-4 accent-teal-500 cursor-pointer shrink-0"})]})}function TR(e){var t=e.siteName,r=e.siteUuid,n=e.initialValue,a=e.storage,i=e.onSave,o=e.className,s=TP((0,g.useState)(n),2),l=s[0],u=s[1],c=TP((0,g.useState)(!1),2),d=c[0],f=c[1],p=function(e){return u(function(t){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},t,e)})};return(0,v.jsxs)("div",{className:(0,w.cn)("flex-1 min-h-0 flex flex-col gap-4 text-slate-100 overflow-y-auto pr-1",o),children:[(0,v.jsx)(Cq,{icon:(0,v.jsx)(OU,{className:"w-4 h-4 text-teal-400"}),title:"Param\xe8tres du Site — ".concat(t),description:"Administration de l'espace collaboratif, visibilit\xe9, quotas et politique de s\xe9curit\xe9.",actions:d&&(0,v.jsxs)("span",{role:"status",className:"flex items-center gap-1.5 px-3 py-1 rounded-lg bg-emerald-500/20 border border-emerald-500/30 text-emerald-300 text-xs font-semibold",children:[(0,v.jsx)(Tt.A,{className:"w-4 h-4 text-emerald-400"}),"Param\xe8tres enregistr\xe9s"]})}),(0,v.jsxs)("form",{onSubmit:function(e){var t;return(t=function(){return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(t){switch(t.label){case 0:return e.preventDefault(),[4,i(l)];case 1:return t.sent(),f(!0),setTimeout(function(){return f(!1)},3e3),[2]}})},function(){var e=this,r=arguments;return new Promise(function(n,a){var i=t.apply(e,r);function o(e){TE(i,n,a,o,s,"next",e)}function s(e){TE(i,n,a,o,s,"throw",e)}o(void 0)})})()},className:"space-y-4",children:[(0,v.jsxs)("section",{className:TD,children:[(0,v.jsxs)("h3",{className:TC,children:[(0,v.jsx)(Tw,{className:"w-3.5 h-3.5"}),"Informations g\xe9n\xe9rales"]}),(0,v.jsxs)("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Nom public du site"}),(0,v.jsx)("input",{className:TT,value:l.title,onChange:function(e){return p({title:e.target.value})}})]}),(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Identifiant unique (UUID)"}),(0,v.jsx)("input",{readOnly:!0,className:(0,w.cn)(TT,"bg-black/60 border-white/10 text-slate-400 font-mono"),value:r})]})]}),(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Description & mission du site"}),(0,v.jsx)("textarea",{rows:2,className:(0,w.cn)(TT,"resize-none"),value:l.description,onChange:function(e){return p({description:e.target.value})}})]})]}),(0,v.jsxs)("section",{className:TD,children:[(0,v.jsxs)("h3",{className:TC,children:[(0,v.jsx)(TS,{className:"w-3.5 h-3.5"}),"Visibilit\xe9 & acc\xe8s"]}),(0,v.jsx)("div",{role:"radiogroup","aria-label":"Visibilit\xe9",className:"grid grid-cols-1 sm:grid-cols-3 gap-2.5",children:TA.map(function(e){var t=e.id,r=e.label,n=e.hint,a=e.icon;return(0,v.jsxs)("button",{type:"button",role:"radio","aria-checked":l.visibility===t,onClick:function(){return p({visibility:t})},className:(0,w.cn)("p-3 rounded-xl border text-left transition-all cursor-pointer",l.visibility===t?"bg-teal-500/15 border-teal-400 text-white shadow-md":"bg-black/30 border-white/10 text-slate-400 hover:text-white"),children:[(0,v.jsxs)("span",{className:"flex items-center gap-2 mb-1",children:[(0,v.jsx)(a,{className:"w-4 h-4 text-teal-400"}),(0,v.jsx)("span",{className:"font-bold text-xs",children:r})]}),(0,v.jsx)("span",{className:"block text-[11px] text-slate-400",children:n})]},t)})}),(0,v.jsx)(TN,{label:"Autoriser les collaborateurs \xe0 inviter des tiers",hint:"Les collaborateurs r\xe9guliers peuvent proposer de nouveaux membres.",checked:l.allowMemberInvites,onChange:function(e){return p({allowMemberInvites:e})}})]}),(0,v.jsxs)("section",{className:TD,children:[(0,v.jsxs)("h3",{className:TC,children:[(0,v.jsx)(Tj,{className:"w-3.5 h-3.5"}),"Stockage & notifications"]}),a&&(0,v.jsxs)("div",{className:"space-y-1",children:[(0,v.jsxs)("div",{className:"flex justify-between text-xs text-slate-300",children:[(0,v.jsxs)("span",{children:["Espace utilis\xe9 : ",(0,v.jsx)("strong",{children:a.usedLabel})]}),(0,v.jsxs)("span",{children:["Quota allou\xe9 : ",(0,v.jsx)("strong",{children:a.quotaLabel})]})]}),(0,v.jsx)("div",{className:"w-full h-2 rounded-full bg-black/40 overflow-hidden border border-white/10",children:(0,v.jsx)("div",{className:"h-full bg-teal-400 rounded-full",style:{width:"".concat(Math.min(100,Math.max(0,a.percent)),"%")}})})]}),(0,v.jsxs)("div",{className:"pt-2 space-y-2 border-t border-white/10",children:[(0,v.jsx)(TN,{label:"Notifier lors du t\xe9l\xe9versement d'un nouveau document",checked:l.notifyOnUpload,onChange:function(e){return p({notifyOnUpload:e})}}),(0,v.jsx)(TN,{label:"Alerter lors de la validation officielle d'un bordereau",checked:l.notifyOnValidation,onChange:function(e){return p({notifyOnValidation:e})}})]})]}),(0,v.jsx)("div",{className:"flex justify-end pt-2",children:(0,v.jsxs)("button",{type:"submit",className:"px-5 py-2 rounded-xl bg-teal-500 hover:bg-teal-400 text-slate-950 font-bold text-xs flex items-center gap-2 shadow-lg transition-all active:scale-95 cursor-pointer",children:[(0,v.jsx)(TO,{className:"w-4 h-4"}),"Enregistrer les param\xe8tres du site"]})})]})]})}function TM(e){var t=e.title,r=e.subtitle,n=e.avatar,a=e.following,i=e.onToggleFollow,o=e.actions,s=e.className;return(0,v.jsx)("div",{className:(0,w.cn)("w-full bg-teal-700 border-b border-teal-500/30 text-white px-3 sm:px-6 py-2 shadow-xs",s),children:(0,v.jsxs)("div",{className:"max-w-7xl mx-auto flex items-center justify-between gap-2",children:[(0,v.jsxs)("div",{className:"flex items-center gap-2 min-w-0",children:[n&&(0,v.jsx)("div",{className:"w-8 h-8 bg-slate-900/50 border border-teal-300/40 flex items-center justify-center shrink-0",children:n}),(0,v.jsxs)("div",{className:"flex flex-col -space-y-0.5 min-w-0",children:[(0,v.jsx)("h1",{className:"text-sm sm:text-base font-bold tracking-tight leading-tight truncate",children:t}),r&&(0,v.jsx)("p",{className:"text-teal-100/80 text-[10px] sm:text-[11px] leading-none truncate",children:r})]})]}),(0,v.jsxs)("div",{className:"flex items-center gap-2 shrink-0",children:[i&&(0,v.jsxs)("button",{type:"button","aria-pressed":a,onClick:i,className:"flex items-center gap-1.5 px-2.5 py-1 border border-white/30 hover:bg-white/10 text-xs font-semibold transition-colors cursor-pointer",children:[(0,v.jsx)(O2,{className:(0,w.cn)("w-3.5 h-3.5",a&&"fill-amber-300 text-amber-300")}),(0,v.jsx)("span",{className:"hidden sm:inline",children:a?"Suivi":"Suivre"})]}),o]})]})})}var TI={conversation:{id:"conversation",number:"1",name:"Mode Conversation",shortName:"Conversation",tagline:"Comprendre & R\xe9pondre",badgeLabel:"Conv",emoji:"\uD83D\uDCAC",iconName:"MessageSquare",color:{text:"text-sky-400",bg:"bg-sky-500/10",border:"border-sky-500/30",ring:"ring-sky-500/40",badgeBg:"bg-sky-500",badgeText:"text-slate-950",glow:"shadow-sky-500/25",accent:"#38bdf8"},principle:"L'agent comprend et r\xe9pond.",bullets:["Questions & r\xe9ponses","Explications & clarifications","Discussion en langage naturel","Conseil informationnel"],example:"\xab Qu'est-ce que cette fonctionnalit\xe9 ? \xbb"},recherche:{id:"recherche",number:"2",name:"Mode Recherche / Analyse",shortName:"Recherche",tagline:"Chercher, R\xe9cup\xe9rer & Interpr\xe9ter",badgeLabel:"Rech",emoji:"\uD83D\uDD0E",iconName:"Search",color:{text:"text-amber-400",bg:"bg-amber-500/10",border:"border-amber-500/30",ring:"ring-amber-500/40",badgeBg:"bg-amber-400",badgeText:"text-slate-950",glow:"shadow-amber-500/25",accent:"#fbbf24"},principle:"L'agent cherche, r\xe9cup\xe8re et interpr\xe8te de l'information.",bullets:["Recherche dans la base de connaissances","Consultation & extraction documentaire","Analyse et croisement de donn\xe9es","Comparaison & synth\xe8se structur\xe9e"],example:"\xab Trouve les documents concernant ce projet et r\xe9sume-les. \xbb"},action:{id:"action",number:"3",name:"Mode Action",shortName:"Action",tagline:"Agir sur le Syst\xe8me via Outils",badgeLabel:"Act",emoji:"⚙️",iconName:"Zap",color:{text:"text-emerald-400",bg:"bg-emerald-500/10",border:"border-emerald-500/30",ring:"ring-emerald-500/40",badgeBg:"bg-emerald-400",badgeText:"text-slate-950",glow:"shadow-emerald-500/25",accent:"#34d399"},principle:"L'agent agit sur le syst\xe8me \xe0 travers des outils (diff\xe9rence cl\xe9 avec un simple chatbot).",bullets:["Cr\xe9er, modifier, supprimer des contenus","Publier & programmer des diffusions","Appeler des API & int\xe9grations","D\xe9clencher des workflows & automatisations"],example:"\xab Cr\xe9e cette actualit\xe9 et programme sa publication demain. \xbb"},autonome:{id:"autonome",number:"4",name:"Mode Autonome",shortName:"Autonome",tagline:"Orchestration Multi-\xe9tapes vers un Objectif",badgeLabel:"Auto",emoji:"\uD83E\uDD16",iconName:"Cpu",color:{text:"text-purple-400",bg:"bg-purple-500/10",border:"border-purple-500/30",ring:"ring-purple-500/40",badgeBg:"bg-purple-400",badgeText:"text-slate-950",glow:"shadow-purple-500/25",accent:"#c084fc"},principle:"L'agent re\xe7oit un objectif et d\xe9termine lui-m\xeame les \xe9tapes n\xe9cessaires sans guidage pas-\xe0-pas.",bullets:["Planification intelligente de l’objectif","Recherche & analyse autonome","Cr\xe9ation & ex\xe9cution des actions requises","V\xe9rification & production du r\xe9sultat final"],example:"\xab Pr\xe9pare toute la communication de notre \xe9v\xe9nement. \xbb",schema:["Objectif","Planification","Recherche","Analyse","Cr\xe9ation","Actions","V\xe9rification","R\xe9sultat"]}},T_="egen_assistant_mode";function TL(){if("u"<typeof window)return"conversation";try{var e=localStorage.getItem(T_);if(e&&TI[e])return e}catch(e){}return"conversation"}function TF(e){if("u">typeof window)try{localStorage.setItem(T_,e)}catch(e){}}function TB(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function TV(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function Tz(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function TW(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return TB(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return TB(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var T$=["#7C6AF7","#7DD3C7","#E8B4D4"],TU=["#3DBA2E","#F2E62F"],TH="\n#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\n\nuniform vec2 u_resolution;\nuniform float u_time;\nuniform float u_speed;\nuniform mat3 u_rot;\nuniform float u_blink;\nuniform float u_mode;\nuniform float u_ears;\nuniform vec3 u_body;\nuniform vec3 u_eye;\nuniform vec3 u_c1;\nuniform vec3 u_c2;\nuniform vec3 u_c3;\nuniform vec3 u_ear1;\nuniform vec3 u_ear2;\n\n// ---- Camera ---------------------------------------------------------------\nconst float CAM_DIST = 6.0;\nconst float HALF_VIEW = ".concat("1.3761",";\n\n// ---- Head (local space, +z = face) ----------------------------------------\nconst vec3 HEAD_R = vec3(1.0, 0.74, 0.86);\n\n// ---- Face (decals projected on the head surface) --------------------------\nconst float EYE_X = 0.455;\nconst float EYE_Y = 0.075;\nconst float EYE_RX = 0.118;\nconst float EYE_RY = 0.128;\nconst float LINE_HALF = 0.021;\n\n// ---- Ear-cups (headphones) -------------------------------------------------\nconst vec3 EAR_C = vec3(1.02, -0.10, 0.02);\nconst float EAR_R = 0.385;\nconst float EAR_HT = 0.072;\nconst float EAR_ROUND = 0.045;\nconst float RECESS_R = 0.335;\nconst float RECESS_D = 0.020;\nconst float RING_R = 0.272;\nconst float RING_T = 0.034;\nconst float RING_X = 0.062;\n// cos / sin of the toe-in (cup faces slightly forward)\nconst float EC = 0.9287;\nconst float ES = 0.3709;\n\nfloat hash(vec2 p) {\n return fract(sin(dot(p, vec2(127.1, 311.7))) * 43758.5453123);\n}\n\nfloat noise(vec2 p) {\n vec2 i = floor(p);\n vec2 f = fract(p);\n float a = hash(i);\n float b = hash(i + vec2(1.0, 0.0));\n float c = hash(i + vec2(0.0, 1.0));\n float d = hash(i + vec2(1.0, 1.0));\n vec2 u = f * f * (3.0 - 2.0 * f);\n return mix(a, b, u.x) + (c - a) * u.y * (1.0 - u.x) + (d - b) * u.x * u.y;\n}\n\nfloat fbm(vec2 p) {\n float v = 0.0;\n float a = 0.5;\n mat2 m = mat2(1.6, 1.2, -1.2, 1.6);\n for (int i = 0; i < 5; i++) {\n v += a * noise(p);\n p = m * p;\n a *= 0.5;\n }\n return v;\n}\n\nvec3 wash(vec3 n, float t) {\n vec2 q = n.xy * 2.2 + n.z * 0.85;\n vec2 w1 = vec2(\n fbm(q * 1.4 + vec2(t * 0.22, t * 0.18)),\n fbm(q * 1.4 + vec2(-t * 0.16, t * 0.24) + 4.1)\n );\n q += (w1 - 0.5) * 0.72;\n float f = fbm(q * 2.1 + vec2(0.0, t * 0.12));\n float g = fbm(q * 4.6 - vec2(t * 0.2, 0.0));\n vec3 col = mix(u_c1, u_c2, smoothstep(0.28, 0.72, f));\n return mix(col, u_c3, pow(smoothstep(0.42, 0.9, g), 1.4));\n}\n\nfloat smin(float a, float b, float k) {\n float h = max(k - abs(a - b), 0.0) / k;\n return min(a, b) - h * h * k * 0.25;\n}\n\nfloat smax(float a, float b, float k) {\n return -smin(-a, -b, k);\n}\n\nfloat sdEllipsoid(vec3 p, vec3 r) {\n float k0 = length(p / r);\n float k1 = length(p / (r * r));\n return k0 * (k0 - 1.0) / max(k1, 1e-4);\n}\n\n// Ear frame: x = cup axis (outward, toed-in), (y, z) = radial plane. Mirrored.\nvec3 earFrame(vec3 p) {\n vec3 q = vec3(abs(p.x), p.y, p.z) - EAR_C;\n return vec3(EC * q.x + ES * q.z, q.y, -ES * q.x + EC * q.z);\n}\n\nfloat sdCup(vec3 e) {\n float rr = EAR_ROUND;\n float rad = length(e.yz);\n vec2 w = vec2(rad - EAR_R + rr, abs(e.x) - EAR_HT + rr);\n float d = min(max(w.x, w.y), 0.0) + length(max(w, 0.0)) - rr;\n // shallow recess in the outer face: the rim stays proud around it\n float rec = max(rad - RECESS_R, (EAR_HT - RECESS_D) - e.x);\n return smax(d, -rec, 0.012);\n}\n\nfloat sdRing(vec3 e) {\n vec2 t = vec2(length(e.yz) - RING_R, e.x - RING_X);\n return length(t) - RING_T;\n}\n\n// x = distance to the whole shape, y = distance to the neon ring\nvec2 map(vec3 p) {\n float d = sdEllipsoid(p, HEAD_R);\n float dr = 1e3;\n if (u_ears > 0.5) {\n vec3 e = earFrame(p);\n d = smin(d, sdCup(e), 0.045);\n dr = sdRing(e);\n d = min(d, dr);\n }\n return vec2(d, dr);\n}\n\nvec3 calcNormal(vec3 p) {\n const vec2 k = vec2(1.0, -1.0);\n const float h = 0.0016;\n return normalize(\n k.xyy * map(p + k.xyy * h).x +\n k.yyx * map(p + k.yyx * h).x +\n k.yxy * map(p + k.yxy * h).x +\n k.xxx * map(p + k.xxx * h).x\n );\n}\n\nfloat calcAO(vec3 p, vec3 n) {\n float occ = 0.0;\n float s = 1.0;\n for (int i = 1; i <= 4; i++) {\n float h = 0.045 * float(i);\n occ += (h - map(p + n * h).x) * s;\n s *= 0.72;\n }\n return clamp(1.0 - 2.4 * occ, 0.0, 1.0);\n}\n\nfloat softShadow(vec3 ro, vec3 rd) {\n float res = 1.0;\n float t = 0.05;\n for (int i = 0; i < 22; i++) {\n float h = map(ro + rd * t).x;\n res = min(res, 9.0 * h / t);\n t += clamp(h, 0.02, 0.22);\n if (res < 0.002 || t > 2.6) break;\n }\n return clamp(res, 0.0, 1.0);\n}\n\nvoid main() {\n vec2 uv = (gl_FragCoord.xy / u_resolution.xy) * 2.0 - 1.0;\n float aspect = u_resolution.x / max(u_resolution.y, 1.0);\n uv.x *= aspect;\n\n float kView = HALF_VIEW / CAM_DIST;\n float pixAng = 2.0 * kView / max(u_resolution.y, 1.0);\n\n vec3 rdW = normalize(vec3(uv * kView, -1.0));\n vec3 roW = vec3(0.0, 0.0, CAM_DIST);\n // world -> head space (u_rot is head -> world; v * M == transpose(M) * v)\n vec3 ro = roW * u_rot;\n vec3 rd = rdW * u_rot;\n\n // bounding sphere\n float bnd = 1.55;\n float b = dot(ro, rd);\n float c = dot(ro, ro) - bnd * bnd;\n float disc = b * b - c;\n if (disc < 0.0) {\n gl_FragColor = vec4(0.0);\n return;\n }\n float sq = sqrt(disc);\n float tEnd = -b + sq;\n float t = max(-b - sq, 0.0);\n\n float minD = 1e3;\n float tMin = t;\n float glow = 0.0;\n bool hit = false;\n vec2 m = vec2(1e3);\n\n for (int i = 0; i < 80; i++) {\n vec3 p = ro + rd * t;\n m = map(p);\n float eps = max(0.0007, 0.35 * t * pixAng);\n if (m.x < eps) {\n hit = true;\n break;\n }\n if (m.x < minD) {\n minD = m.x;\n tMin = t;\n }\n float stp = m.x * 0.85;\n glow += exp(-m.y * m.y * 150.0) * stp;\n t += stp;\n if (t > tEnd) break;\n }\n\n vec3 glowCol = mix(u_ear1, u_ear2, 0.5);\n float ga = (u_ears > 0.5) ? (1.0 - exp(-glow * 3.0)) * 0.8 : 0.0;\n\n float cov = 0.0;\n vec3 col = vec3(0.0);\n\n if (hit) {\n cov = 1.0;\n vec3 pl = ro + rd * t;\n vec3 nl = calcNormal(pl);\n vec3 nW = normalize(u_rot * nl);\n vec3 v = -rdW;\n\n // lights are fixed in the world: turning the head re-shades it\n vec3 keyW = normalize(vec3(-0.5, 0.72, 0.78));\n vec3 fillW = normalize(vec3(0.85, 0.05, 0.45));\n vec3 keyL = keyW * u_rot;\n float sh = softShadow(pl + nl * 0.012, keyL);\n float ao = calcAO(pl, nl);\n\n float ndl = dot(nW, keyW);\n float wrap = clamp((ndl + 0.35) / 1.35, 0.0, 1.0);\n float fill = clamp((dot(nW, fillW) + 0.3) / 1.3, 0.0, 1.0);\n float sky = nW.y * 0.5 + 0.5;\n vec3 amb = mix(vec3(0.60, 0.61, 0.64), vec3(0.80, 0.81, 0.84), sky);\n vec3 lightSum = amb * ao\n + vec3(1.0, 0.975, 0.94) * 0.62 * wrap * mix(0.55, 1.0, sh) * (0.55 + 0.45 * ao)\n + vec3(0.82, 0.86, 1.0) * 0.12 * fill * ao;\n\n vec3 hv = normalize(keyW + v);\n float ndh = max(dot(nW, hv), 0.0);\n float specK = (pow(ndh, 64.0) * 0.55 + pow(ndh, 14.0) * 0.10) * sh;\n float ndv = max(dot(nW, v), 0.0);\n float fres = 0.04 + 0.96 * pow(1.0 - ndv, 5.0);\n vec3 refl = reflect(-v, nW);\n vec3 env = mix(vec3(0.30, 0.31, 0.34), vec3(0.96, 0.97, 0.99), smoothstep(-0.25, 0.95, refl.y));\n\n float px = t * pixAng;\n vec3 body = (u_mode > 0.5) ? wash(nl, u_time * u_speed) : u_body;\n\n // ---- ear materials ------------------------------------------------------\n float plate = 0.0;\n float ringMask = 0.0;\n vec3 ringCol = vec3(0.0);\n float spill = 0.0;\n if (u_ears > 0.5) {\n vec3 e = earFrame(pl);\n float rad = length(e.yz);\n float outward = smoothstep(0.02, 0.05, e.x);\n plate = (1.0 - smoothstep(RECESS_R - 0.006 - px, RECESS_R + 0.004 + px, rad)) * outward;\n float dRing = sdRing(e);\n ringMask = 1.0 - smoothstep(0.0, 0.01 + px, dRing);\n float ang = atan(e.z, e.y);\n float gradT = 0.5 + 0.5 * sin(ang + (pl.x > 0.0 ? 0.6 : 2.5));\n vec3 neon = mix(u_ear1, u_ear2, gradT);\n float core = exp(-pow(dRing / RING_T + 1.0, 2.0) * 1.1);\n ringCol = mix(neon, vec3(1.0), 0.40 * core) * (1.05 + 0.08 * sin(u_time * 1.7));\n spill = exp(-max(dRing, 0.0) * 14.0) * outward;\n }\n vec3 plateCol = mix(vec3(0.16, 0.17, 0.20), u_body * 0.22 + vec3(0.07), 0.5);\n body = mix(body, plateCol, plate);\n\n // ---- face decals: eyes + connecting line --------------------------------\n float onFace = smoothstep(0.18, 0.42, pl.z);\n float lid = mix(1.0, 0.10, u_blink);\n float aa = max(px * 1.1, 0.0035);\n vec2 pe = pl.xy - vec2(0.0, EYE_Y);\n vec2 dl = vec2(abs(pe.x) - EYE_X, pe.y) / vec2(EYE_RX, EYE_RY * lid);\n float eyeM = 1.0 - smoothstep(1.0 - aa / EYE_RX, 1.0 + aa / EYE_RX, length(dl));\n float lw = max(LINE_HALF, 0.6 * px);\n float lineM =\n (1.0 - smoothstep(lw - aa, lw + aa, abs(pe.y))) *\n (1.0 - smoothstep(EYE_X - aa, EYE_X + aa, abs(pe.x)));\n float face = clamp(max(eyeM, lineM), 0.0, 1.0) * onFace;\n\n // ---- shade ----------------------------------------------------------------\n vec3 lit = body * lightSum;\n lit += vec3(1.0) * specK * (1.0 - plate * 0.6);\n lit = mix(lit, env * mix(vec3(1.0), body, 0.35), fres * 0.42);\n\n vec3 eyeLit = u_eye * (0.84 + 0.16 * wrap) + vec3(1.0) * specK * 0.42 + env * fres * 0.16;\n col = mix(lit, eyeLit, face);\n\n // neon spills light on the cup face and on the head next to it\n col += mix(u_ear1, u_ear2, 0.5) * spill * 0.34 * (1.0 - face);\n // the ring itself emits: no lighting\n col = mix(col, ringCol, ringMask);\n } else if (minD < 1e2) {\n // anti-aliased silhouette: how close did the ray pass to the surface?\n float r = minD / max(tMin * pixAng, 1e-5);\n cov = 1.0 - smoothstep(0.0, 1.15, r);\n // soft rim colour for the faded edge: reuse the body tone\n vec3 body = (u_mode > 0.5) ? wash(normalize(ro + rd * tMin), u_time * u_speed) : u_body;\n col = body * 0.9;\n }\n\n // neon halo behind / around the ring\n vec3 premul = col * cov + glowCol * ga * (1.0 - cov);\n float a = cov + ga * (1.0 - cov);\n gl_FragColor = vec4(clamp(premul / max(a, 1e-4), 0.0, 1.0), clamp(a, 0.0, 1.0));\n}\n");function TG(){return"u">typeof process&&(null==process.env?void 0:"production")!=="production"}function TK(e){var t=e.replace("#","").trim(),r=Number.parseInt(3===t.length?t.split("").map(function(e){return e+e}).join(""):t.padEnd(6,"0").slice(0,6),16);return Number.isNaN(r)?[.96,.96,.96]:[(r>>16&255)/255,(r>>8&255)/255,(255&r)/255]}function Tq(e,t,r){var n=e.createShader(t);return n?(e.shaderSource(n,r),e.compileShader(n),e.getShaderParameter(n,e.COMPILE_STATUS))?n:(TG()&&console.warn("LiveOrb: shader failed to compile\n",e.getShaderInfoLog(n)),e.deleteShader(n),null):null}function TY(e,t,r,n,a){var i,o,s,l,u="#F4F4F5",c="#09090B",d=0,f=T$,p=TU;return"black"===e?(u="#18181B",c="#F4F4F5"):"webgl"===e?(u=null!=(i=(f=n&&n.length>0?n:T$)[1])?i:T$[1],c="#0C0C10",d=1,p=[null!=(o=f[0])?o:T$[0],null!=(s=f[2])?s:T$[2]]):"custom"===e&&(u=null!=t?t:"#7C5CFF",c=null!=r?r:"#FAFAFA"),a&&a.length>0&&(p=[a[0],null!=(l=a[1])?l:a[0]]),{body:u,eye:c,mode:d,palette:f,ear:p}}function TX(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=TV({variant:"white",interactive:!0,blink:!0,ears:!0},r),a={x:0,y:.06,vx:0,vy:0},i={x:0,y:.06},o=!1,s=e.getContext("webgl",{alpha:!0,antialias:!1,depth:!1,stencil:!1,premultipliedAlpha:!1,powerPreference:"high-performance"});if(!s)return null;var l=Tq(s,s.VERTEX_SHADER,"\nattribute vec2 a_position;\nvoid main() {\n gl_Position = vec4(a_position, 0.0, 1.0);\n}\n"),u=Tq(s,s.FRAGMENT_SHADER,TH);if(!l||!u)return null;var c=s.createProgram();if(!c)return null;if(s.attachShader(c,l),s.attachShader(c,u),s.linkProgram(c),!s.getProgramParameter(c,s.LINK_STATUS))return TG()&&console.warn("LiveOrb: program failed to link\n",s.getProgramInfoLog(c)),null;s.useProgram(c),null==(t=n.onHasGl)||t.call(n,!0);var d=s.createBuffer();s.bindBuffer(s.ARRAY_BUFFER,d),s.bufferData(s.ARRAY_BUFFER,new Float32Array([-1,-1,1,-1,-1,1,-1,1,1,-1,1,1]),s.STATIC_DRAW);var f=s.getAttribLocation(c,"a_position");s.enableVertexAttribArray(f),s.vertexAttribPointer(f,2,s.FLOAT,!1,0,0);var p=function(e){return s.getUniformLocation(c,e)},h=p("u_resolution"),m=p("u_time"),y=p("u_speed"),v=p("u_rot"),g=p("u_blink"),b=p("u_mode"),x=p("u_ears"),w=p("u_body"),S=p("u_eye"),j=p("u_c1"),O=p("u_c2"),k=p("u_c3"),E=p("u_ear1"),P=p("u_ear2");s.disable(s.BLEND);var A=0,D=!0,C=!0,T=performance.now(),N=T,R=T+1800+2400*Math.random(),M=-1e4,I=function(){var t=e.parentElement;if(t){var r=Math.min(window.devicePixelRatio||1,2),n=t.clientWidth,a=t.clientHeight;n<=0||a<=0||(e.width=Math.max(1,Math.floor(n*r)),e.height=Math.max(1,Math.floor(a*r)),e.style.width="".concat(n,"px"),e.style.height="".concat(a,"px"),s.viewport(0,0,e.width,e.height))}};I();var L=new ResizeObserver(I);e.parentElement&&L.observe(e.parentElement);var F="u">typeof IntersectionObserver?new IntersectionObserver(function(e){var t=TW(e,1)[0];C=!t||t.isIntersecting}):null;null==F||F.observe(e);var B=window.matchMedia("(prefers-reduced-motion: reduce)"),V=function(){o=B.matches};V(),B.addEventListener("change",V);var z=function(t){if(n.interactive){var r=e.parentElement;if(r){var a=r.getBoundingClientRect();if(!(a.width<=0)&&!(a.height<=0)){var o=3*Math.max(a.width,a.height)+120,s=t.clientX-(a.left+a.width/2),l=a.top+a.height/2-t.clientY;i.x=Math.tanh(s/o*2.2),i.y=Math.tanh(l/o*2.2)}}}},W=function(e){null===e.relatedTarget&&(i.x=0,i.y=.06)};window.addEventListener("pointermove",z,{passive:!0}),document.addEventListener("mouseout",W);var $=function(e){var t;e.preventDefault(),D=!1,cancelAnimationFrame(A),null==(t=n.onHasGl)||t.call(n,!1)};e.addEventListener("webglcontextlost",$);var U=function(t){if(D){A=requestAnimationFrame(U);var r,l,u=Math.min(.05,Math.max(.001,(t-N)/1e3));if(N=t,C&&!document.hidden){var c,d,f,p,I,L,F,B,V,z=TY(n.variant,n.color,n.eyeColor,n.colors,n.earColors),W=(t-T)/1e3,$=n.interactive?i.x:0,H=n.interactive?i.y:.06;a.vx+=(($-a.x)*130-17*a.vx)*u,a.vy+=((H-a.y)*130-17*a.vy)*u,a.x+=a.vx*u,a.y+=a.vy*u;var G=+!o,K=Math.max(-1,Math.min(1,a.x))+.03*Math.sin(.9*W)*G,q=Math.max(-1,Math.min(1,a.y))+.022*Math.sin(.67*W+1.3)*G;!o&&n.blink&&t>=R&&(M=t,R=t+2200+3800*Math.random());var Y=(t-M)/1e3,X=0;!o&&n.blink&&(Y<.055?X=Y/.055:Y<.1?X=1:Y<.18&&(X=1-(Y-.1)/.08));var Z=TK(z.body),Q=TK(z.eye),J=[0,1,2].map(function(e){var t;return TK(null!=(t=z.palette[e%z.palette.length])?t:T$[e])}),ee=TK(null!=(r=z.ear[0])?r:TU[0]),et=TK(null!=(l=z.ear[1])?l:TU[1]);s.clearColor(0,0,0,0),s.clear(s.COLOR_BUFFER_BIT),s.uniform2f(h,e.width,e.height),s.uniform1f(m,o?0:W),s.uniform1f(y,.55*!o),s.uniformMatrix3fv(v,!1,(c=.62*K,d=-(.4*q),f=-(.09*K),p=Math.cos(c),I=Math.sin(c),L=Math.cos(d),F=Math.sin(d),new Float32Array([p*(B=Math.cos(f))+I*F*(V=Math.sin(f)),L*V,-I*B+p*F*V,-p*V+I*F*B,L*B,I*V+p*F*B,I*L,-F,p*L]))),s.uniform1f(g,X),s.uniform1f(b,z.mode),s.uniform1f(x,+!!n.ears),s.uniform3f(w,Z[0],Z[1],Z[2]),s.uniform3f(S,Q[0],Q[1],Q[2]),s.uniform3f(j,J[0][0],J[0][1],J[0][2]),s.uniform3f(O,J[1][0],J[1][1],J[1][2]),s.uniform3f(k,J[2][0],J[2][1],J[2][2]),s.uniform3f(E,ee[0],ee[1],ee[2]),s.uniform3f(P,et[0],et[1],et[2]),s.drawArrays(s.TRIANGLES,0,6)}}};return A=requestAnimationFrame(U),{setOptions:function(e){n=TV({},n,e)},destroy:function(){var t;D=!1,cancelAnimationFrame(A),L.disconnect(),null==F||F.disconnect(),B.removeEventListener("change",V),window.removeEventListener("pointermove",z),document.removeEventListener("mouseout",W),e.removeEventListener("webglcontextlost",$),null==(t=n.onHasGl)||t.call(n,!1),s.deleteProgram(c),s.deleteShader(l),s.deleteShader(u),s.deleteBuffer(d)}}}function TZ(e){var t=e.resolved,r=e.ears,n=e.interactive,a=(0,g.useRef)(null),i=(0,g.useRef)(null);(0,g.useEffect)(function(){if(n){var e=a.current,t=i.current,r=null==e?void 0:e.parentElement;if(e&&r){var o=function(n){var a=r.getBoundingClientRect();if(!(a.width<=0)&&!(a.height<=0)){var i=3*Math.max(a.width,a.height)+120,o=Math.tanh((n.clientX-(a.left+a.width/2))/i*2.2),s=Math.tanh((a.top+a.height/2-n.clientY)/i*2.2);e.style.transform="translate(".concat((5.5*o).toFixed(2),"%, ").concat((-(3.4*s)).toFixed(2),"%)"),t&&(t.style.transform="translate(".concat((-(1.8*o)).toFixed(2),"%, ").concat((-(1.2*s)).toFixed(2),"%)"))}};return window.addEventListener("pointermove",o,{passive:!0}),function(){return window.removeEventListener("pointermove",o)}}}},[n]);var o=TW(t.ear,2),s=o[0],l=o[1],u="transform 140ms ease-out",c={position:"absolute"},d=Tz(TV({},c),{backgroundColor:t.eye,width:"8.3%",height:"9%",top:"42.9%",borderRadius:"50%"});return(0,v.jsxs)("div",{"data-part":"zoom","aria-hidden":!0,style:Tz(TV({},c),{inset:0,transform:"scale(".concat(1.09,")")}),children:[r?(0,v.jsx)("div",{ref:i,"data-part":"ears","aria-hidden":!0,style:Tz(TV({},c),{inset:0,transition:u}),children:[0,1].map(function(e){return(0,v.jsx)("span",{"data-part":"ear",style:Tz(TV({},c),{borderRadius:"50%",left:0===e?"9%":"79%",top:"37%",width:"12%",height:"30%",background:"linear-gradient(".concat(0===e?135:225,"deg, ").concat(s,", ").concat(l,")"),boxShadow:"0 0 6px ".concat(l,"66, inset 0 0 0 2px #0000001f")}),children:(0,v.jsx)("span",{style:Tz(TV({},c),{borderRadius:"50%",inset:"16% 22%",background:"radial-gradient(circle at 40% 30%, #3b3e45, #15171b)"})})},e)})}):null,(0,v.jsx)("div",{"aria-hidden":!0,"data-part":"head",style:Tz(TV(Tz(TV({},c),{overflow:"hidden",left:"15%",top:"24%",width:"70%",height:"52%",borderRadius:"50%"}),function(e){if(1===e.mode){var t,r,n,a=null!=(t=e.palette[0])?t:T$[0],i=null!=(r=e.palette[1])?r:T$[1],o=null!=(n=e.palette[2])?n:T$[2];return{backgroundImage:"linear-gradient(135deg, ".concat(a,", ").concat(i,", ").concat(o,")")}}return{backgroundColor:e.body}}(t)),{boxShadow:"inset -6px -8px 14px #0000002e, inset 5px 6px 12px #ffffff66"})}),(0,v.jsxs)("div",{ref:a,"aria-hidden":!0,"data-part":"face",style:Tz(TV({},c),{inset:0,transition:u}),children:[(0,v.jsx)("span",{"data-part":"eye",style:Tz(TV({},d),{left:"29.9%"})}),(0,v.jsx)("span",{"data-part":"eye",style:Tz(TV({},d),{left:"61.8%"})}),(0,v.jsx)("span",{"data-part":"line",style:Tz(TV({},c),{backgroundColor:t.eye,left:"34%",width:"32%",height:"1.6%",top:"46.6%",borderRadius:"999px"})})]})]})}function TQ(e){var t=e.className,r=e.size,n=void 0===r?280:r,a=e.label,i=e.variant,o=void 0===i?"white":i,s=e.color,l=e.eyeColor,u=e.colors,c=e.interactive,d=void 0===c||c,f=e.blink,p=void 0===f||f,h=e.ears,m=void 0===h||h,y=e.earColors,b=(0,g.useRef)(null),x=(0,g.useRef)(null),S=TW((0,g.useState)(!1),2),j=S[0],O=S[1];(0,g.useEffect)(function(){var e=b.current;if(e)return x.current=TX(e,{variant:o,color:s,eyeColor:l,colors:u,interactive:d,blink:p,ears:m,earColors:y,onHasGl:O}),function(){var e;null==(e=x.current)||e.destroy(),x.current=null}},[]),(0,g.useEffect)(function(){var e;null==(e=x.current)||e.setOptions({variant:o,color:s,eyeColor:l,colors:u,interactive:d,blink:p,ears:m,earColors:y,onHasGl:O})},[o,s,l,u,d,p,m,y]);var k=TY(o,s,l,u,y);return(0,v.jsxs)("div",{"data-slot":"live-orb",role:"img","aria-label":void 0===a?"Assistant avatar":a,className:(0,w.cn)("relative shrink-0",t),style:{position:"relative",width:n,height:n},children:[j?null:(0,v.jsx)(TZ,{resolved:k,ears:m,interactive:d}),(0,v.jsx)("canvas",{ref:b,className:"absolute inset-0 size-full"})]})}function TJ(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function T0(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function T1(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){T0(i,n,a,o,s,"next",e)}function s(e){T0(i,n,a,o,s,"throw",e)}o(void 0)})}}function T2(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||T3(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function T3(e,t){if(e){if("string"==typeof e)return TJ(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return TJ(e,t)}}function T4(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}function T5(e){var t=e.text,r=T2((0,g.useState)("auto"),2),n=r[0],a=r[1],i=(0,g.useRef)(null);return(0,g.useEffect)(function(){i.current&&a(i.current.offsetWidth)},[t]),(0,v.jsxs)("span",{className:"relative inline-flex items-center justify-center overflow-hidden transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",style:{width:n},children:[(0,v.jsx)("span",{ref:i,className:"invisible whitespace-nowrap px-1",children:t}),(0,v.jsx)("span",{className:"absolute inset-0 flex items-center justify-center whitespace-nowrap animate-in fade-in zoom-in-95 duration-300",children:t},t)]})}function T6(e){var t=e.model,r=e.className,n={"Composer 2.5":"https://cdn.21st.dev/assets/mirror/7d/7dc00bc09f225fcda46cbc9c6b669c69c025a231877d6c17baa6a003f04f02b2.svg","Gemini 3.5 Flash":"https://cdn.21st.dev/assets/mirror/cd/cda2df6631d5fa227de3fa04ed78cf354f910ba92a9f086e7455655c10ad9d09.svg","GPT 5.5":"https://cdn.21st.dev/assets/mirror/b9/b93fa7942be639a1dae60194ff12141145d7d9fd59581582d6ff23335755f19c.svg","Opus 4.8":"https://cdn.21st.dev/assets/mirror/5d/5de1221c77cc91e748066fd642ad0eee1c1fa65328814f5178166f901e599709.svg","GLM 5.2":"https://cdn.21st.dev/assets/mirror/b2/b2a6c0ff63efd8a555edf8a174ea6fcfeca120ac1595a2d461ca11d3ae89276c.svg"};return(0,v.jsx)("img",{src:n[t]||n["GPT 5.5"],alt:t,className:(0,w.cn)("object-contain",{"GPT 5.5":"dark:invert"}[t],r)})}function T8(){return(0,v.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:(0,v.jsx)("path",{d:"M7 12V2M7 2L2.5 6.5M7 2L11.5 6.5",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"})})}function T9(){return(0,v.jsxs)("svg",{width:"13",height:"13",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:[(0,v.jsx)("rect",{x:"5",y:"1",width:"4",height:"7",rx:"2",stroke:"currentColor",strokeWidth:"1.5"}),(0,v.jsx)("path",{d:"M2.75 6.5V7a4.25 4.25 0 0 0 8.5 0v-.5M7 11.25V13",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]})}function T7(){return(0,v.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:(0,v.jsx)("rect",{x:"3.5",y:"3.5",width:"7",height:"7",rx:"1.5",fill:"currentColor"})})}function Ne(){return(0,v.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:(0,v.jsx)("path",{d:"M7 2.5V11.5M2.5 7H11.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}function Nt(){return(0,v.jsx)("svg",{width:"9",height:"9",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:(0,v.jsx)("path",{d:"M2.5 2.5L11.5 11.5M11.5 2.5L2.5 11.5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})})}function Nr(e){var t=e.level;return(0,v.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:[(0,v.jsx)("rect",{x:"1.5",y:"8",width:"2.5",height:"4.5",rx:"1",fill:"currentColor",className:"transition-opacity duration-300",opacity:1}),(0,v.jsx)("rect",{x:"5.75",y:"5",width:"2.5",height:"7.5",rx:"1",fill:"currentColor",className:"transition-opacity duration-300",opacity:"Medium"===t||"Max Effort"===t?1:.3}),(0,v.jsx)("rect",{x:"10",y:"2",width:"2.5",height:"10.5",rx:"1",fill:"currentColor",className:"transition-opacity duration-300",opacity:"Max Effort"===t?1:.3})]})}function Nn(e){var t=e.attachment,r=e.index,n=e.onRemove,a=e.onOpen,i=e.registerRef,o=T2((0,g.useState)(!1),2),s=o[0],l=o[1],u=(0,g.useRef)(null);return(0,v.jsxs)("button",{ref:function(e){u.current=e,i(t.id,e)},type:"button",onMouseDown:function(e){return e.preventDefault()},onMouseEnter:function(){return l(!0)},onMouseLeave:function(){return l(!1)},onClick:function(e){e.stopPropagation(),u.current&&a(t,u.current.getBoundingClientRect())},style:{animationDelay:"".concat(35*r,"ms"),animationFillMode:"backwards"},className:(0,w.cn)("group relative size-12 shrink-0 overflow-hidden rounded-xl border border-border bg-muted outline-none","transition-transform duration-200 ease-[cubic-bezier(0.175,0.885,0.32,1.275)] hover:scale-[1.04] active:scale-[0.96]","animate-in fade-in slide-in-from-top-3 zoom-in-90 duration-400"),"aria-label":"Open preview of ".concat(t.name),children:[(0,v.jsx)("img",{src:t.url,alt:t.name,className:"size-full object-cover",draggable:!1}),(0,v.jsx)("span",{className:(0,w.cn)("absolute inset-0 flex items-start justify-end bg-black/0 transition-colors duration-200",s&&"bg-black/25"),children:(0,v.jsx)("span",{role:"button",tabIndex:-1,onMouseDown:function(e){e.preventDefault(),e.stopPropagation()},onClick:function(e){e.stopPropagation(),n(t.id)},className:(0,w.cn)("m-1 flex size-4 items-center justify-center rounded-full bg-background/90 text-foreground/70 shadow-sm transition-all duration-200 ease-[cubic-bezier(0.175,0.885,0.32,1.275)] hover:bg-background hover:text-foreground hover:scale-110",s?"opacity-100 scale-100":"opacity-0 scale-50 pointer-events-none"),"aria-label":"Remove ".concat(t.name),children:(0,v.jsx)(Nt,{})})})]})}function Na(e){var t=e.attachment,r=e.originRect,n=e.onClose,a=T2((0,g.useState)("opening"),2),i=a[0],o=a[1],s=T2((0,g.useState)(null),2),l=s[0],u=s[1],c=(0,g.useRef)(null);(0,g.useEffect)(function(){var e=Math.min(.86*window.innerWidth,560),r=Math.min(.78*window.innerHeight,720),n=t.width||800,a=t.height||600,i=Math.min(e/n,r/a,1.6),s=n*i,l=a*i;u({top:(window.innerHeight-l)/2,left:(window.innerWidth-s)/2,width:s,height:l,radius:20});var c=requestAnimationFrame(function(){return o("open")});return function(){return cancelAnimationFrame(c)}},[t]);var d=(0,g.useCallback)(function(){return o("closing")},[]);(0,g.useEffect)(function(){var e=function(e){"Escape"===e.key&&d()};return document.addEventListener("keydown",e),function(){return document.removeEventListener("keydown",e)}},[d]);var f="open"===i,p="closing"===i,h=f&&l?l:{top:r.top,left:r.left,width:r.width,height:r.height,radius:12},m=p?"ease-out":"cubic-bezier(0.175, 0.885, 0.32, 1.275)",y=p?"0.3s":"0.45s",b="top ".concat(y," ").concat(m,", left ").concat(y," ").concat(m,", width ").concat(y," ").concat(m,", height ").concat(y," ").concat(m,", border-radius ").concat(y," ").concat(m);return(0,v.jsxs)("div",{className:"fixed inset-0 z-[100]",onClick:d,role:"dialog","aria-modal":"true",children:[(0,v.jsx)("div",{className:"absolute inset-0 bg-background/70 backdrop-blur-md transition-opacity duration-400",style:{opacity:+!!f}}),(0,v.jsx)("div",{style:{position:"fixed",top:h.top,left:h.left,width:h.width,height:h.height,borderRadius:h.radius,transition:b,overflow:"hidden",boxShadow:f?"0 24px 60px -12px rgb(0 0 0 / 0.35)":"0 0px 0px 0px rgb(0 0 0 / 0)"},className:"bg-muted",onTransitionEnd:function(){"closing"===i&&n()},onClick:function(e){return e.stopPropagation()},children:(0,v.jsx)("img",{ref:c,src:t.url,alt:t.name,className:"size-full object-cover",draggable:!1})}),(0,v.jsx)("button",{type:"button",onClick:d,style:{opacity:+!!f,transform:f?"scale(1)":"scale(0.7)"},className:(0,w.cn)("fixed right-4 top-4 flex size-9 items-center justify-center rounded-full bg-card/90 text-foreground/70 shadow-md backdrop-blur-sm","transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)] hover:bg-card hover:text-foreground",!f&&"pointer-events-none"),children:(0,v.jsx)("span",{className:"scale-150",children:(0,v.jsx)(Nt,{})})})]})}var Ni=g.forwardRef(function(e,t){var r=e.onSubmit,n=e.placeholder,a=void 0===n?"Ask anything":n,i=e.className,o=e.models,s=void 0===o?["GPT 5.5","Opus 4.8","Gemini 3.5 Flash","Composer 2.5","GLM 5.2"]:o,l=e.efforts,u=void 0===l?["Low","Medium","Max Effort"]:l,c=e.defaultValue,d=e.value,f=e.onChange,p=e.maxAttachments,h=void 0===p?6:p,m=T2((0,g.useState)(!1),2),y=m[0],b=m[1],x=T2((0,g.useState)(!1),2),S=x[0],j=x[1],O=T2((0,g.useState)(void 0===c?"":c),2),k=O[0],E=O[1],P=T2((0,g.useState)(s[0]),2),A=P[0],D=P[1],C=T2((0,g.useState)(1),2),T=C[0],N=C[1],R=T2((0,g.useState)(!1),2),M=R[0],I=R[1],L=T2((0,g.useState)([]),2),F=L[0],B=L[1],V=T2((0,g.useState)(null),2),z=V[0],W=V[1],$=T2((0,g.useState)(!1),2),U=$[0],H=$[1],G=T2((0,g.useState)([,,,,,].fill(0)),2),K=G[0],q=G[1],Y=(0,g.useRef)(void 0!==d?d:k),X=(0,g.useRef)(null),Z=(0,g.useRef)(null),Q=(0,g.useRef)(null),J=(0,g.useRef)(null),ee=(0,g.useRef)(null),et=(0,g.useRef)(null),er=T2((0,g.useState)({opacity:0,transform:"translateY(0px) scale(0.95)",transition:"none"}),2),en=er[0],ea=er[1],ei=T2((0,g.useState)(116),2),eo=ei[0],es=ei[1],el=T2((0,g.useState)(68),2),eu=el[0],ec=el[1],ed=T2((0,g.useState)(!1),2),ef=ed[0],ep=ed[1],eh=void 0!==d,em=eh?d:k,ey=""!==em.trim()||F.length>0,ev=F.length>0,eg=(0,g.useRef)(null),eb=(0,g.useRef)(null),ex=(0,g.useRef)(null),ew=(0,g.useRef)(null),eS=(0,g.useRef)(null),ej=(0,g.useRef)(new Map);(0,g.useEffect)(function(){Y.current=em},[em]);var eO=function(){var e=eg.current;if(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;ex.current&&(ex.current.style.opacity=Math.min(t/20,1).toString()),ew.current&&(ew.current.style.opacity=Math.min(Math.max(r-n-t-16,0)/10,1).toString())}},ek=(0,g.useCallback)(function(e){j(!0),eh||E(e),null==f||f(e)},[eh,f]),eE=(0,g.useCallback)(function(){J.current&&(J.current.stop(),J.current=null),Q.current&&(cancelAnimationFrame(Q.current),Q.current=null),X.current&&(X.current.getTracks().forEach(function(e){return e.stop()}),X.current=null),Z.current&&(Z.current.close(),Z.current=null),ee.current&&(window.clearInterval(ee.current),ee.current=null),et.current&&(window.clearInterval(et.current),et.current=null),H(!1),q([,,,,,].fill(0))},[]),eP=(0,g.useCallback)(function(){return T1(function(){var e,t,r,n,a,i,o,s;function l(){var e="Can you build a high fidelity Framer Motion layout animation for a dark mode dashboard?".split(" "),t=0,r=Y.current;et.current=window.setInterval(function(){t<e.length?(ek(r=(r?r+" ":"")+e[t]),t++):eE()},300)}return T4(this,function(u){switch(u.label){case 0:j(!1),b(!0),e=null,u.label=1;case 1:if(u.trys.push([1,4,,5]),!(navigator.mediaDevices&&navigator.mediaDevices.getUserMedia))return[3,3];return[4,navigator.mediaDevices.getUserMedia({audio:!0})];case 2:e=u.sent(),u.label=3;case 3:return[3,5];case 4:return u.sent(),console.warn("Microphone access denied or unavailable. Falling back to simulated voice mode for demo."),[3,5];case 5:return H(!0),e?(X.current=e,Z.current=t=new(window.AudioContext||window.webkitAudioContext),(r=t.createAnalyser()).fftSize=64,t.createMediaStreamSource(e).connect(r),n=new Uint8Array(r.frequencyBinCount),(a=function(){r.getByteFrequencyData(n);for(var e=[,,,,,].fill(0),t=Math.floor(n.length/5),i=0;i<5;i++){for(var o=0,s=0;s<t;s++)o+=n[i*t+s];e[i]=o/t/255}q(e),Q.current=requestAnimationFrame(a)})(),(i=window.SpeechRecognition||window.webkitSpeechRecognition)?((o=new i).continuous=!0,o.interimResults=!0,s=Y.current,o.onresult=function(e){for(var t="",r="",n=e.resultIndex;n<e.results.length;++n)e.results[n].isFinal?r+=e.results[n][0].transcript:t+=e.results[n][0].transcript;r&&(s+=(s?" ":"")+r),ek((s+(t?" "+t:"")).trim())},o.onerror=function(e){console.error("Speech recognition error",e),eE()},o.onend=function(){eE()},J.current=o,o.start()):(console.warn("Speech Recognition API not supported in this browser. Using simulated text."),l())):(ee.current=window.setInterval(function(){q(Array.from({length:5},function(){return .8*Math.random()+.1}))},100),l()),[2]}})})()},[ek,eE]);(0,g.useEffect)(function(){U&&eg.current&&(eg.current.scrollTop=eg.current.scrollHeight)},[em,U]),(0,g.useEffect)(function(){return function(){eE(),F.forEach(function(e){return URL.revokeObjectURL(e.url)})}},[eE,F]),(0,g.useEffect)(function(){(""!==em.trim()||ev)&&!y&&(j(!1),b(!0))},[em,y,ev]),(0,g.useEffect)(function(){if(y&&!U){var e=setTimeout(function(){if(eg.current){eg.current.focus();var e=eg.current.value.length;eg.current.setSelectionRange(e,e)}},50);return function(){return clearTimeout(e)}}},[y,U]),(0,g.useEffect)(function(){if(eg.current){var e=eg.current,t=e.style.height;e.style.transition="none",e.style.height="0px";var r=e.scrollHeight;e.style.height=t,e.offsetHeight,e.style.transition="";var n=Math.max(68,Math.min(r,160));e.style.height="".concat(n,"px"),ec(n),ep(r>160),setTimeout(eO,0)}},[em,y]),(0,g.useEffect)(function(){es(Math.max(116,eu+48)),setTimeout(eO,0)},[eu]),(0,g.useEffect)(function(){if(M){var e=function(e){eb.current&&!eb.current.contains(e.target)&&I(!1)};return document.addEventListener("mousedown",e),function(){return document.removeEventListener("mousedown",e)}}},[M]);var eA=function(){(""!==em.trim()||ev)&&(j(!1),null==r||r(em,{model:A,effort:u[T],attachments:F.map(function(e){return e.file})}),ek(""),F.forEach(function(e){return URL.revokeObjectURL(e.url)}),B([]),b(!1),I(!1))},eD=function(e,t,r,n){var a="".concat(e.name,"-").concat(e.lastModified,"-").concat(Math.random().toString(36).slice(2,8));B(function(i){return((function(e){if(Array.isArray(e))return TJ(e)})(i)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(i)||T3(i)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([{id:a,file:e,url:t,name:e.name,width:r,height:n}])})},eC=function(e){j(!0),B(function(t){var r=t.find(function(t){return t.id===e});return r&&URL.revokeObjectURL(r.url),t.filter(function(t){return t.id!==e})}),ej.current.delete(e)},eT=ey&&!U,eN=!ey&&!U;return(0,v.jsxs)(v.Fragment,{children:[(0,v.jsxs)("div",{ref:function(e){"function"==typeof t?t(e):t&&(t.current=e),eb.current=e},onBlur:function(e){!(eb.current&&eb.current.contains(e.relatedTarget))&&(""!==em.trim()||ev||U||(j(!1),b(!1),I(!1)))},className:(0,w.cn)("relative flex flex-col w-full",i),style:{maxWidth:"100%",transition:S?"max-width 0.15s ease-out":"max-width 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"},children:[(0,v.jsx)("input",{ref:eS,type:"file",accept:"image/*",multiple:!0,onChange:function(e){return T1(function(){var t,r,n,a,i,o,s,l,u,c;return T4(this,function(d){if(!(t=e.target.files)||(r=Array.from(t).filter(function(e){return e.type.startsWith("image/")}),e.target.value="",0===r.length))return[2];n=Math.max(0,h-F.length),a=r.slice(0,n),y?j(!0):(j(!1),b(!0)),i=!0,o=!1,s=void 0;try{for(l=function(){var e=c.value,t=URL.createObjectURL(e),r=new Image;r.onload=function(){return eD(e,t,r.naturalWidth,r.naturalHeight)},r.onerror=function(){return eD(e,t,800,600)},r.src=t},u=a[Symbol.iterator]();!(i=(c=u.next()).done);i=!0)l()}catch(e){o=!0,s=e}finally{try{i||null==u.return||u.return()}finally{if(o)throw s}}return[2]})})()},className:"hidden",tabIndex:-1,"aria-hidden":"true"}),(0,v.jsx)("div",{"aria-hidden":!ev,style:{height:ev&&y?68:0,transition:S?"height 0.15s ease-out":"height 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"},className:"w-full relative z-0 overflow-hidden",children:(0,v.jsx)("div",{style:{position:"absolute",bottom:-8,left:20,right:20,height:68,transform:ev&&y?"translateY(0)":"translateY(100%)",opacity:ev&&y?1:0,transition:S?"transform 0.15s ease-out, opacity 0.15s ease-out":"transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease-out"},className:"border border-border border-b-0 bg-muted rounded-t-2xl px-2 pt-2 pb-1 flex items-start gap-2 overflow-x-auto prompt-scrollbar",children:F.map(function(e,t){return(0,v.jsx)(Nn,{attachment:e,index:t,onRemove:eC,onOpen:function(e,t){return W({attachment:e,rect:t})},registerRef:function(e,t){return ej.current.set(e,t)}},e.id)})})}),(0,v.jsxs)("div",{onMouseDown:function(e){var t,r=e.target===eg.current;!y||r||U||(e.preventDefault(),null==(t=eg.current)||t.focus())},style:{borderRadius:24,height:y?eo:48,transition:S?"max-width 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), height 0.15s ease-out":"max-width 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), height 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)",overflow:y?"visible":"hidden"},className:(0,w.cn)("relative w-full border border-border bg-card shadow-sm focus-within:border-ring/40 focus-within:ring-1 focus-within:ring-ring/20 hover:border-border/80 z-10",y?"cursor-text":"cursor-default"),children:[(0,v.jsx)("style",{dangerouslySetInnerHTML:{__html:"\n .prompt-scrollbar::-webkit-scrollbar { width: 4px; height: 4px; background: transparent; }\n .prompt-scrollbar::-webkit-scrollbar-track { background: transparent; }\n .prompt-scrollbar::-webkit-scrollbar-thumb { background: transparent; border-radius: 4px; }\n .prompt-scrollbar:hover::-webkit-scrollbar-thumb { background: hsl(var(--muted-foreground) / 0.3); }\n "}}),(0,v.jsx)("textarea",{ref:eg,value:em,onChange:function(e){return ek(e.target.value)},onScroll:eO,onKeyDown:function(e){"Enter"!==e.key||e.shiftKey||(e.preventDefault(),eA()),"Escape"!==e.key||""!==em.trim()||ev||(j(!1),b(!1),I(!1))},placeholder:a,"aria-label":"Prompt",disabled:U,style:{transition:S?"height 0.15s ease-out":"opacity 0.3s ease-out, transform 0.3s ease-out, height 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"},className:(0,w.cn)("prompt-scrollbar absolute top-0 inset-x-0 z-[1] w-full resize-none bg-transparent pl-4 pr-12 py-3.5 text-sm leading-[22px] text-foreground outline-none placeholder:font-medium placeholder:text-muted-foreground/80 cursor-text",y?"opacity-100 scale-100 translate-y-0":"opacity-0 scale-95 -translate-y-1 pointer-events-none",ef?"overflow-y-auto":"overflow-y-hidden",U&&"pointer-events-none")}),(0,v.jsx)("div",{ref:ex,className:"absolute left-4 right-12 top-0 z-[2] h-8 bg-gradient-to-b from-card via-card/90 to-transparent pointer-events-none"}),(0,v.jsx)("div",{ref:ew,className:"absolute left-4 right-12 z-[2] h-8 bg-gradient-to-t from-card via-card/90 to-transparent pointer-events-none",style:{opacity:0,top:"".concat(eu-32,"px"),transition:S?"top 0.15s ease-out":"top 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"}}),(0,v.jsx)("button",{type:"button",onClick:function(){j(!1),b(!0)},style:{transition:S?"none":"all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"},className:(0,w.cn)("absolute inset-x-0 top-0 z-[1] cursor-text pl-4 pr-12 py-[15px] text-left text-sm font-medium leading-[17px] text-muted-foreground/80 outline-none truncate",y?"opacity-0 scale-105 translate-y-1 pointer-events-none":"opacity-100 scale-100 translate-y-0"),"aria-label":"Open prompt input",children:a}),(0,v.jsxs)("div",{className:(0,w.cn)("absolute bottom-2 left-3 right-12 z-[10] flex items-center gap-0 transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",y&&!U?"opacity-100 blur-0 translate-y-0 pointer-events-auto":"opacity-0 blur-sm translate-y-2 pointer-events-none"),children:[(0,v.jsxs)("div",{className:"relative",children:[(0,v.jsxs)("button",{type:"button",onMouseDown:function(e){return e.preventDefault()},onClick:function(e){e.stopPropagation(),I(function(e){return!e})},className:(0,w.cn)("group flex items-center gap-1 rounded-full px-2 py-1 text-foreground/50 transition-all duration-200 outline-none hover:bg-accent/60 hover:text-foreground cursor-default",M?"bg-accent/60 text-foreground":""),"aria-label":"Select model. Current: ".concat(A),children:[(0,v.jsx)(T6,{model:A,className:"size-3.5 opacity-70 group-hover:opacity-100 transition-opacity"}),(0,v.jsx)("span",{className:"text-xs font-semibold select-none transition-colors",children:(0,v.jsx)(T5,{text:A})})]}),(0,v.jsx)("div",{style:{transformOrigin:"bottom left"},onMouseLeave:function(){ea(function(e){var t,r;return t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},e),r=r={opacity:0,transform:e.transform.replace("scale(1)","scale(0.95)"),transition:"opacity 0.2s ease-in, transform 0.2s ease-out"},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t})},className:(0,w.cn)("absolute bottom-full left-0 mb-2.5 z-50 w-44 rounded-2xl border border-border bg-card/95 p-1 shadow-xl backdrop-blur-md flex flex-col gap-0.5 transition-all duration-400 cursor-default",M?"opacity-100 scale-100 translate-y-0 pointer-events-auto ease-[cubic-bezier(0.34,1.56,0.64,1)]":"opacity-0 scale-95 translate-y-3 pointer-events-none ease-[cubic-bezier(0.175,0.885,0.32,1.275)]"),children:(0,v.jsxs)("div",{className:"relative flex flex-col gap-0.5",children:[(0,v.jsx)("div",{style:en,className:"absolute left-0 right-0 top-0 h-8 -z-10 rounded-xl bg-accent pointer-events-none"}),s.map(function(e,t){return(0,v.jsx)("button",{type:"button",onMouseDown:function(e){return e.preventDefault()},onMouseEnter:function(){ea(function(e){return{opacity:1,transform:"translateY(".concat(34*t,"px) scale(1)"),transition:0===e.opacity?"opacity 0.15s ease-out":"transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.15s ease"}})},onClick:function(t){t.stopPropagation(),D(e),I(!1)},className:"group relative flex h-8 w-full items-center justify-between rounded-xl px-2.5 py-1.5 text-left text-xs font-medium text-foreground/80 outline-none active:scale-[0.98] cursor-default",children:(0,v.jsxs)("span",{className:"flex items-center gap-2",children:[(0,v.jsx)(T6,{model:e,className:"size-3.5 opacity-85 group-hover:opacity-100 transition-opacity"}),e]})},e)})]})})]}),(0,v.jsxs)("button",{type:"button",onMouseDown:function(e){return e.preventDefault()},onClick:function(e){e.stopPropagation(),N(function(e){return(e+1)%u.length})},className:"group flex items-center gap-1 rounded-full px-2 py-1 text-foreground/50 transition-all duration-200 hover:bg-accent/60 hover:text-foreground outline-none cursor-default",children:[(0,v.jsx)(Nr,{level:u[T]}),(0,v.jsx)("span",{className:"text-xs font-semibold select-none transition-colors",children:(0,v.jsx)(T5,{text:u[T]})})]}),(0,v.jsx)("button",{type:"button",onMouseDown:function(e){return e.preventDefault()},onClick:function(e){var t;e.stopPropagation(),null==(t=eS.current)||t.click()},disabled:F.length>=h,className:"ml-auto flex size-7 items-center justify-center rounded-full text-foreground/50 transition-all duration-200 hover:bg-accent/60 hover:text-foreground outline-none cursor-default disabled:opacity-40 disabled:pointer-events-none",children:(0,v.jsx)(Ne,{})})]}),(0,v.jsx)("div",{className:(0,w.cn)("absolute right-12 bottom-2 z-[10] flex h-8 items-center justify-end gap-[3px] transition-all duration-400 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",U?"w-16 opacity-100 translate-x-0":"w-0 opacity-0 translate-x-4 pointer-events-none"),children:K.map(function(e,t){return(0,v.jsx)("div",{className:"w-1 rounded-full bg-primary transition-[height] duration-75 ease-out",style:{height:"".concat(Math.max(4,24*e),"px")}},t)})}),(0,v.jsx)("button",{type:"button",onMouseDown:function(e){e.preventDefault(),e.stopPropagation()},onClick:function(e){e.preventDefault(),U?eE():ey?eA():eP()},"aria-label":eT?"Send prompt":U?"Stop recording":"Use voice input",style:{borderRadius:9999},className:"absolute right-2 bottom-2 z-[10] flex h-8 w-8 items-center justify-center bg-primary text-primary-foreground transition-all duration-300 hover:opacity-90 outline-none focus-visible:ring-2 focus-visible:ring-ring cursor-default",children:(0,v.jsxs)("span",{className:"relative flex h-full w-full items-center justify-center",children:[(0,v.jsx)("span",{className:(0,w.cn)("absolute inset-0 flex items-center justify-center transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",eT?"opacity-100 scale-100 rotate-0 blur-none":"opacity-0 scale-50 rotate-45 blur-[1px] pointer-events-none"),children:(0,v.jsx)(T8,{})}),(0,v.jsx)("span",{className:(0,w.cn)("absolute inset-0 flex items-center justify-center transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",eN?"opacity-100 scale-100 rotate-0 blur-none":"opacity-0 scale-50 -rotate-45 blur-[1px] pointer-events-none"),children:(0,v.jsx)(T9,{})}),(0,v.jsx)("span",{className:(0,w.cn)("absolute inset-0 flex items-center justify-center transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",U?"opacity-100 scale-100 rotate-0 blur-none":"opacity-0 scale-50 rotate-45 blur-[1px] pointer-events-none"),children:(0,v.jsx)(T7,{})})]})})]})]}),z&&(0,v.jsx)(Na,{attachment:z.attachment,originRect:z.rect,onClose:function(){return W(null)}})]})});Ni.displayName="PromptInput";var No=r(3766);function Ns(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var Nl=(0,g.lazy)(function(){return r.e("1808").then(r.bind(r,339))}),Nu=new Set;function Nc(e){if(!("u"<typeof document||(0,No.$)()||Nu.has(e))){Nu.add(e);var t=document.createElement("link");t.rel="preload",t.as="fetch",t.crossOrigin="anonymous",t.href=e,document.head.appendChild(t)}}function Nd(e){var t,r=e.scene,n=e.className,a=void 0===n?"w-full h-full":n,i=e.onLoad,o=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return Ns(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Ns(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),s=o[0],l=o[1];return(0,No.$)()?(0,v.jsx)("div",{className:"relative ".concat(a," overflow-hidden"),"data-egen-3d":"unavailable","data-testid":"spline-unavailable","aria-hidden":"true"}):(0,v.jsxs)("div",{className:"relative ".concat(a," overflow-hidden"),children:[!s&&(0,v.jsxs)("div",{className:"absolute inset-0 z-10 flex flex-col items-center justify-center bg-[#030708] text-teal-400 gap-3 transition-opacity duration-300",children:[(0,v.jsx)("div",{className:"w-10 h-10 border-2 border-teal-400 border-t-transparent rounded-full animate-spin"}),(0,v.jsx)("span",{className:"text-xs font-mono tracking-widest text-teal-300/80 uppercase animate-pulse",children:"Initialisation Robot 3D..."})]}),(0,v.jsx)("div",{className:"w-full h-full transition-opacity duration-500 ".concat(s?"opacity-100":"opacity-0"),children:(0,v.jsx)(g.Suspense,{fallback:null,children:(0,v.jsx)(Nl,{scene:r,className:"w-full h-full",onLoad:function(e){l(!0),i&&i(e)}})})})]})}var Nf={mode:"dark",hue:0,saturation:1,brightness:1},Np={title:"Recursive Erosion particle sphere background",source:"<!DOCTYPE html>\n<html lang=\"fr\">\n<head>\n <meta charset=\"UTF-8\">\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n <title>Recursive Erosion Particle Sphere</title>\n <style>\n * { margin: 0; padding: 0; box-sizing: border-box; }\n html, body {\n width: 100%;\n height: 100%;\n overflow: hidden;\n background: #0a0908;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n #stage {\n position: absolute;\n inset: 0;\n width: 100%;\n height: 100%;\n display: block;\n }\n </style>\n <script src=\"https://cdnjs.cloudflare.com/ajax/libs/three.js/r128/three.min.js\"><\/script>\n</head>\n<body>\n <canvas id=\"stage\"></canvas>\n\n <script>\n (function() {\n var canvas = document.getElementById('stage');\n var width = window.innerWidth;\n var height = window.innerHeight;\n\n // Ensure canvas has dimension\n canvas.width = width;\n canvas.height = height;\n\n // Mouse tracking\n var mouseX = 0, mouseY = 0;\n var targetRotX = 0, targetRotY = 0;\n window.addEventListener('mousemove', function(e) {\n mouseX = (e.clientX / window.innerWidth) * 2 - 1;\n mouseY = -(e.clientY / window.innerHeight) * 2 + 1;\n });\n\n // Simple 3D noise approximation\n function snoise(x, y, z) {\n return Math.sin(x * 1.7 + y * 2.3) * Math.cos(y * 1.5 + z * 2.1) * Math.sin(z * 1.9 + x * 0.9);\n }\n\n // Check if THREE is loaded\n if (typeof THREE !== 'undefined') {\n initThree();\n } else {\n // In case external CDN fails, fallback to standalone canvas 2D rendering\n initCanvasFallback();\n }\n\n function initThree() {\n var scene = new THREE.Scene();\n var camera = new THREE.PerspectiveCamera(50, width / height, 0.1, 1000);\n camera.position.z = 240;\n\n var renderer = new THREE.WebGLRenderer({\n canvas: canvas,\n antialias: true,\n alpha: true,\n powerPreference: \"high-performance\"\n });\n renderer.setSize(width, height);\n renderer.setPixelRatio(Math.min(window.devicePixelRatio || 1, 2));\n\n // Create 7,000 points on Fibonacci sphere\n var particleCount = 7000;\n var geometry = new THREE.BufferGeometry();\n var positions = new Float32Array(particleCount * 3);\n var basePositions = new Float32Array(particleCount * 3);\n var colors = new Float32Array(particleCount * 3);\n var sizes = new Float32Array(particleCount);\n\n var sphereRadius = 82;\n var goldenRatio = (1 + Math.sqrt(5)) / 2;\n\n for (var i = 0; i < particleCount; i++) {\n var y = 1 - (i / (particleCount - 1)) * 2;\n var radiusAtY = Math.sqrt(Math.max(0, 1 - y * y));\n var theta = 2 * Math.PI * i / goldenRatio;\n\n var x = Math.cos(theta) * radiusAtY;\n var z = Math.sin(theta) * radiusAtY;\n\n var bx = x * sphereRadius;\n var by = y * sphereRadius;\n var bz = z * sphereRadius;\n\n basePositions[i * 3] = bx;\n basePositions[i * 3 + 1] = by;\n basePositions[i * 3 + 2] = bz;\n\n positions[i * 3] = bx;\n positions[i * 3 + 1] = by;\n positions[i * 3 + 2] = bz;\n\n // Warm orange / amber / golden palette with organic gradient\n var ratio = (y + 1) * 0.5;\n var r = 1.0;\n var g = 0.38 + ratio * 0.28 + Math.random() * 0.12;\n var b = 0.05 + ratio * 0.08;\n\n colors[i * 3] = r;\n colors[i * 3 + 1] = g;\n colors[i * 3 + 2] = b;\n\n sizes[i] = 1.2 + Math.random() * 2.0;\n }\n\n geometry.setAttribute('position', new THREE.BufferAttribute(positions, 3));\n geometry.setAttribute('color', new THREE.BufferAttribute(colors, 3));\n\n // Circular glow particle texture\n var circleCanvas = document.createElement('canvas');\n circleCanvas.width = 64;\n circleCanvas.height = 64;\n var ctx = circleCanvas.getContext('2d');\n var grad = ctx.createRadialGradient(32, 32, 0, 32, 32, 32);\n grad.addColorStop(0, 'rgba(255, 255, 255, 1)');\n grad.addColorStop(0.2, 'rgba(255, 160, 60, 0.9)');\n grad.addColorStop(0.5, 'rgba(255, 90, 20, 0.4)');\n grad.addColorStop(1, 'rgba(255, 60, 0, 0)');\n ctx.fillStyle = grad;\n ctx.fillRect(0, 0, 64, 64);\n\n var pTexture = new THREE.CanvasTexture(circleCanvas);\n\n var material = new THREE.PointsMaterial({\n size: 3.2,\n vertexColors: true,\n map: pTexture,\n transparent: true,\n blending: THREE.AdditiveBlending,\n depthWrite: false,\n opacity: 0.92\n });\n\n var points = new THREE.Points(geometry, material);\n scene.add(points);\n\n // 8 jagged lightning arcs that strike across the sphere\n var arcGroup = new THREE.Group();\n var arcLines = [];\n var ARC_COUNT = 8;\n var ARC_SEGMENTS = 20;\n\n for (var a = 0; a < ARC_COUNT; a++) {\n var arcGeo = new THREE.BufferGeometry();\n var arcPos = new Float32Array(ARC_SEGMENTS * 3);\n arcGeo.setAttribute('position', new THREE.BufferAttribute(arcPos, 3));\n\n var arcMat = new THREE.LineBasicMaterial({\n color: new THREE.Color(1.0, 0.72 + Math.random() * 0.25, 0.3),\n transparent: true,\n opacity: 0.75,\n blending: THREE.AdditiveBlending,\n linewidth: 1.5\n });\n\n var line = new THREE.Line(arcGeo, arcMat);\n arcLines.push({ line: line, geo: arcGeo, phase: Math.random() * Math.PI * 2, speed: 0.8 + Math.random() * 0.6 });\n arcGroup.add(line);\n }\n scene.add(arcGroup);\n\n // Inner glowing core\n var coreGeo = new THREE.SphereGeometry(sphereRadius * 0.3, 16, 16);\n var coreMat = new THREE.MeshBasicMaterial({\n color: 0xff5500,\n transparent: true,\n opacity: 0.08,\n blending: THREE.AdditiveBlending,\n wireframe: true\n });\n var coreMesh = new THREE.Mesh(coreGeo, coreMat);\n scene.add(coreMesh);\n\n var clock = new THREE.Clock();\n\n function animate() {\n requestAnimationFrame(animate);\n var time = clock.getElapsedTime();\n\n // 4-second erosion breathing loop\n var loopCycle = (time % 4.0) / 4.0; // 0 to 1\n var erosionPulse = Math.sin(loopCycle * Math.PI * 2);\n\n var posAttr = geometry.attributes.position;\n var posArray = posAttr.array;\n\n for (var i = 0; i < particleCount; i++) {\n var i3 = i * 3;\n var bx = basePositions[i3];\n var by = basePositions[i3 + 1];\n var bz = basePositions[i3 + 2];\n\n // 3D noise for recursive erosion crumpling & hole creation\n var nVal = snoise(bx * 0.025 + time * 0.4, by * 0.025 + time * 0.3, bz * 0.025);\n var isHole = nVal > (0.42 - erosionPulse * 0.25);\n\n var displace = isHole ? (1.0 + (nVal - 0.3) * 0.65) : (1.0 + nVal * 0.12 * erosionPulse);\n posArray[i3] = bx * displace;\n posArray[i3 + 1] = by * displace;\n posArray[i3 + 2] = bz * displace;\n }\n posAttr.needsUpdate = true;\n\n // Lightning arcs updates\n for (var a = 0; a < ARC_COUNT; a++) {\n var arcObj = arcLines[a];\n var aGeo = arcObj.geo;\n var aPos = aGeo.attributes.position.array;\n\n var tPhase = time * arcObj.speed + arcObj.phase;\n var p1Idx = Math.floor(Math.abs(Math.sin(tPhase * 0.7) * (particleCount - 1)));\n var p2Idx = Math.floor(Math.abs(Math.cos(tPhase * 0.5) * (particleCount - 1)));\n\n var x1 = posArray[p1Idx * 3], y1 = posArray[p1Idx * 3 + 1], z1 = posArray[p1Idx * 3 + 2];\n var x2 = posArray[p2Idx * 3], y2 = posArray[p2Idx * 3 + 1], z2 = posArray[p2Idx * 3 + 2];\n\n for (var s = 0; s < ARC_SEGMENTS; s++) {\n var tSeg = s / (ARC_SEGMENTS - 1);\n var sx = x1 + (x2 - x1) * tSeg;\n var sy = y1 + (y2 - y1) * tSeg;\n var sz = z1 + (z2 - z1) * tSeg;\n\n // Jagged lightning noise displacement\n if (s > 0 && s < ARC_SEGMENTS - 1) {\n var jitter = Math.sin(tSeg * Math.PI) * 7.5;\n sx += (Math.random() - 0.5) * jitter;\n sy += (Math.random() - 0.5) * jitter;\n sz += (Math.random() - 0.5) * jitter;\n }\n\n aPos[s * 3] = sx;\n aPos[s * 3 + 1] = sy;\n aPos[s * 3 + 2] = sz;\n }\n aGeo.attributes.position.needsUpdate = true;\n arcObj.line.material.opacity = 0.3 + Math.random() * 0.65;\n }\n\n // Smooth rotation & interactive mouse tilt\n targetRotX = mouseY * 0.45;\n targetRotY = mouseX * 0.55;\n\n points.rotation.y += 0.0035;\n points.rotation.x += (targetRotX - points.rotation.x) * 0.05;\n points.rotation.z += (targetRotY * 0.2 - points.rotation.z) * 0.05;\n\n arcGroup.rotation.copy(points.rotation);\n coreMesh.rotation.copy(points.rotation);\n\n renderer.render(scene, camera);\n }\n\n animate();\n\n window.addEventListener('resize', function() {\n width = window.innerWidth;\n height = window.innerHeight;\n camera.aspect = width / height;\n camera.updateProjectionMatrix();\n renderer.setSize(width, height);\n });\n }\n\n function initCanvasFallback() {\n var ctx = canvas.getContext('2d');\n var particles = [];\n var count = 3000;\n for (var i = 0; i < count; i++) {\n var y = 1 - (i / (count - 1)) * 2;\n var rAtY = Math.sqrt(Math.max(0, 1 - y * y));\n var theta = 2 * Math.PI * i / 1.6180339887;\n particles.push({\n x: Math.cos(theta) * rAtY,\n y: y,\n z: Math.sin(theta) * rAtY,\n baseRadius: 180\n });\n }\n\n var angleX = 0, angleY = 0;\n function renderLoop() {\n requestAnimationFrame(renderLoop);\n ctx.fillStyle = '#0a0908';\n ctx.fillRect(0, 0, width, height);\n\n var cx = width / 2;\n var cy = height / 2;\n\n angleY += 0.005;\n angleX = mouseY * 0.3;\n\n for (var i = 0; i < count; i += 2) {\n var p = particles[i];\n var cosY = Math.cos(angleY), sinY = Math.sin(angleY);\n var cosX = Math.cos(angleX), sinX = Math.sin(angleX);\n\n var x1 = p.x * cosY - p.z * sinY;\n var z1 = p.z * cosY + p.x * sinY;\n\n var y2 = p.y * cosX - z1 * sinX;\n var z2 = z1 * cosX + p.y * sinX;\n\n var scale = 400 / (400 + z2 * p.baseRadius);\n var px = cx + x1 * p.baseRadius * scale;\n var py = cy + y2 * p.baseRadius * scale;\n\n var alpha = Math.max(0.1, Math.min(1, (z2 + 1.2) * 0.45));\n ctx.fillStyle = 'rgba(255, 140, 40, ' + alpha + ')';\n ctx.beginPath();\n ctx.arc(px, py, Math.max(1, 2.0 * scale), 0, Math.PI * 2);\n ctx.fill();\n }\n }\n renderLoop();\n\n window.addEventListener('resize', function() {\n width = window.innerWidth;\n height = window.innerHeight;\n canvas.width = width;\n canvas.height = height;\n });\n }\n })();\n <\/script>\n</body>\n</html>",background:"#0a0908",theme:{lightBackground:"#f4f3f1",darkBackground:"#0a0908"},targets:[{selector:"#stage",role:"background"}],hiddenTargets:["#badge",".sr"]};function Nh(e,t,r){return Math.min(r,Math.max(t,e))}function Nm(e,t){var r,n;return null!=(r=null==(n=e.theme)?void 0:n["".concat(t,"Background")])?r:e.background}function Ny(e){var t=e.mode,r=void 0===t?Nf.mode:t,n=e.hue,a=void 0===n?Nf.hue:n,i=e.saturation,o=void 0===i?Nf.saturation:i,s=e.brightness,l=void 0===s?Nf.brightness:s,u=e.className,c=e.style,d="light"===r?"light":"dark",f=Nm(Np,d),p=(0,g.useMemo)(function(){var e,t,r,n,a,i,o,s;return t=Nm(Np,d),r=Np.source,n=JSON.stringify(Np.targets).replace(/</g,"\\u003c"),a=JSON.stringify(null!=(e=Np.hiddenTargets)?e:[]).replace(/</g,"\\u003c"),i=JSON.stringify(d),o="<style data-threeui-focus>\nhtml, body { width: 100% !important; height: 100% !important; min-height: 0 !important; margin: 0 !important; padding: 0 !important; overflow: hidden !important; background: ".concat(t," !important; color-scheme: ").concat(d,' !important; }\nbody { position: relative !important; display: flex !important; align-items: center !important; justify-content: center !important; }\nbody > * { visibility: hidden !important; }\nbody[data-threeui-ready] > [data-threeui-role] { visibility: visible !important; }\n[data-threeui-residual] { display: none !important; }\n[data-threeui-hidden] { display: none !important; }\n[data-threeui-role="background"] { position: fixed !important; inset: 0 !important; width: 100% !important; height: 100% !important; max-width: none !important; max-height: none !important; z-index: 0 !important; opacity: 1 !important; pointer-events: none !important; }\n[data-threeui-role="button"] { position: relative !important; z-index: 2 !important; opacity: 1 !important; flex: none !important; }\n[data-threeui-role="visual"] { position: relative !important; z-index: 1 !important; width: min(100%, 1040px) !important; max-width: 1040px !important; max-height: 100% !important; margin: auto !important; padding: 24px !important; overflow: auto !important; opacity: 1 !important; filter: none !important; }\n</style>'),s="<script data-threeui-focus>\n(function () {\n document.documentElement.dataset.sfMode = ".concat(i,";\n var isolated = false;\n function isolate() {\n if (isolated) return;\n var specs = ").concat(n,";\n var hiddenSelectors = ").concat(a,";\n var roots = [];\n hiddenSelectors.forEach(function (selector) {\n document.querySelectorAll(selector).forEach(function (element) {\n element.setAttribute('data-threeui-hidden', '');\n element.setAttribute('aria-hidden', 'true');\n if ('inert' in element) element.inert = true;\n });\n });\n specs.forEach(function (spec) {\n var element = document.querySelector(spec.selector);\n if (!element) return;\n element.setAttribute('data-threeui-role', spec.role);\n if (!roots.some(function (root) { return root.contains(element); })) roots.push(element);\n });\n if (!roots.length) return;\n isolated = true;\n roots.forEach(function (root) {\n var placeholderLink = root.matches('a[href=\"#\"]') ? root : root.querySelector('a[href=\"#\"]');\n if (placeholderLink) placeholderLink.addEventListener('click', function (event) { event.preventDefault(); });\n document.body.appendChild(root);\n });\n Array.from(document.body.children).forEach(function (element) {\n if (roots.indexOf(element) !== -1) return;\n element.setAttribute('data-threeui-residual', '');\n element.setAttribute('aria-hidden', 'true');\n if ('inert' in element) element.inert = true;\n });\n document.body.setAttribute('data-threeui-ready', '');\n requestAnimationFrame(function () { window.dispatchEvent(new Event('resize')); });\n }\n function scheduleIsolation() { setTimeout(isolate, 100); }\n if (document.readyState === 'loading') document.addEventListener('DOMContentLoaded', scheduleIsolation, { once: true });\n else scheduleIsolation();\n window.addEventListener('load', isolate, { once: true });\n})();\n<\/script>"),r.replace(/<\/head>/i,"".concat(o,"</head>")).replace(/<\/body>/i,"".concat(s,"</body>"))},[d]),h=Nh(a,-180,180),m=Nh(o,0,2),y=Nh(l,.35,1.65),b=0===h&&1===m&&1===y?void 0:"hue-rotate(".concat(h,"deg) saturate(").concat(m,") brightness(").concat(y,")");return(0,v.jsx)("iframe",{className:u,"data-mode":d,title:Np.title,srcDoc:p,sandbox:"allow-scripts",loading:"eager",style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({display:"block",width:"100%",height:"100%",border:0,background:f,filter:b},c)})}function Nv(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ng(e){if(Array.isArray(e))return e}function Nb(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Nx(e,t){if(e){if("string"==typeof e)return Nv(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Nv(e,t)}}var Nw=(0,g.forwardRef)(function(e,t){var r,n,a,i=Ng(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||Nx(r)||Nb(),o=i[0],s=i.slice(1),l=o.children,u=o.optionsComponent,c=o.header,d=o.footer,f=o.align,p=o.width,h=o.className,m=void 0===h?"":h,y=o.contentClassName,g=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(o,["children","optionsComponent","header","footer","align","width","className","contentClassName"]),b=(Ng(s)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),1!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(s)||Nx(s,1)||Nb())[0],x=m.includes("fixed")||m.includes("absolute");return(0,v.jsx)("div",(n=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({ref:b,className:"".concat(x?"":"absolute top-full mt-2"," z-[9999] text-xs text-slate-100 select-none overflow-hidden\n bg-slate-950/90 backdrop-blur-3xl rounded-2xl border border-white/20\n shadow-[0_16px_48px_0_rgba(0,0,0,0.65)]\n before:absolute before:inset-0 before:rounded-2xl before:bg-gradient-to-b before:from-white/[0.12] before:to-transparent before:pointer-events-none\n animate-in fade-in zoom-in-95 duration-150\n ").concat({right:"right-0",left:"left-0",center:"left-1/2 -translate-x-1/2",none:""}[void 0===f?"right":f],"\n ").concat(p||"","\n ").concat(m,"\n ")},g),a=a={children:(0,v.jsxs)("div",{className:"relative z-10 p-1.5 ".concat(void 0===y?"":y),children:[c&&(0,v.jsx)("div",{className:"pb-1.5 mb-1.5 border-b border-white/10 px-2 pt-1",children:c}),u||l,d&&(0,v.jsx)("div",{className:"pt-1.5 mt-1.5 border-t border-white/10 px-2 pb-1",children:d})]})},Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(a)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(a)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(a,e))}),n))});Nw.displayName="WaterGlassModal";function NS(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Nj=new(function(){var e;function t(){var e=this;if(!(this instanceof t))throw TypeError("Cannot call a class as a function");NS(this,"ctx",null),NS(this,"isMuted",!1),NS(this,"volume",.5),NS(this,"lastPlayTimes",{}),NS(this,"noiseBuffer",null);try{var r=localStorage.getItem("egen_xbox_sound_muted");null!==r&&(this.isMuted="true"===r);var n=localStorage.getItem("egen_xbox_sound_volume");null!==n&&(this.volume=parseFloat(n)||.5)}catch(e){}if("u">typeof window){var a=function(){e.initContext(),window.removeEventListener("pointerdown",a),window.removeEventListener("keydown",a)};window.addEventListener("pointerdown",a,{passive:!0}),window.addEventListener("keydown",a,{passive:!0})}}return e=[{key:"initContext",value:function(){if(!this.ctx&&"u">typeof window){var e=window.AudioContext||window.webkitAudioContext;e&&(this.ctx=new e,this.generateNoiseBuffer())}return this.ctx&&"suspended"===this.ctx.state&&this.ctx.resume().catch(function(){}),this.ctx}},{key:"generateNoiseBuffer",value:function(){if(this.ctx){for(var e=.5*this.ctx.sampleRate,t=this.ctx.createBuffer(2,e,this.ctx.sampleRate),r=0;r<2;r++)for(var n=t.getChannelData(r),a=0;a<e;a++)n[a]=2*Math.random()-1;this.noiseBuffer=t}}},{key:"getIsMuted",value:function(){return this.isMuted}},{key:"setMuted",value:function(e){this.isMuted=e;try{localStorage.setItem("egen_xbox_sound_muted",String(e))}catch(e){}}},{key:"toggleMute",value:function(){return this.setMuted(!this.isMuted),this.isMuted||this.play("select"),this.isMuted}},{key:"getVolume",value:function(){return this.volume}},{key:"setVolume",value:function(e){this.volume=Math.max(0,Math.min(1,e));try{localStorage.setItem("egen_xbox_sound_volume",String(this.volume))}catch(e){}}},{key:"play",value:function(e){if(!this.isMuted){var t=performance.now();if(!this.lastPlayTimes[e]||!(t-this.lastPlayTimes[e]<({hover:40,scroll:40,boundary:160,select:60,back:60,modalOpen:100,folderOpen:120,notification:180,achievement:250,toastSuccess:120,toastInfo:120,toastWarning:120,toastError:120,toggle:60})[e])){this.lastPlayTimes[e]=t;var r=this.initContext();if(r)try{switch(e){case"hover":this.playHover(r);break;case"select":this.playSelect(r);break;case"back":this.playBack(r);break;case"modalOpen":this.playModalOpen(r);break;case"folderOpen":this.playFolderOpen(r);break;case"scroll":this.playScroll(r);break;case"boundary":this.playBoundary(r);break;case"notification":this.playNotification(r);break;case"achievement":this.playAchievement(r);break;case"toastSuccess":this.playToastSuccess(r);break;case"toastInfo":this.playToastInfo(r);break;case"toastWarning":this.playToastWarning(r);break;case"toastError":this.playToastError(r);break;case"toggle":this.playToggle(r)}}catch(e){console.warn("Xbox Audio error:",e)}}}}},{key:"playHover",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain(),a=e.createBiquadFilter();r.type="sine",r.frequency.setValueAtTime(2200,t),r.frequency.exponentialRampToValueAtTime(1400,t+.025),a.type="bandpass",a.frequency.setValueAtTime(1800,t),a.Q.setValueAtTime(3,t);var i=.12*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(i,t+.002),n.gain.exponentialRampToValueAtTime(1e-4,t+.025),r.connect(a),a.connect(n),n.connect(e.destination),r.start(t),r.stop(t+.03)}},{key:"playSelect",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain();r.type="sine",r.frequency.setValueAtTime(920,t),r.frequency.exponentialRampToValueAtTime(1480,t+.035),r.frequency.exponentialRampToValueAtTime(1100,t+.07);var a=.28*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(a,t+.003),n.gain.exponentialRampToValueAtTime(.001,t+.07),r.connect(n),n.connect(e.destination);var i=e.createOscillator(),o=e.createGain();i.type="triangle",i.frequency.setValueAtTime(460,t),i.frequency.exponentialRampToValueAtTime(320,t+.05);var s=.15*this.volume;o.gain.setValueAtTime(0,t),o.gain.linearRampToValueAtTime(s,t+.004),o.gain.exponentialRampToValueAtTime(.001,t+.05),i.connect(o),o.connect(e.destination),r.start(t),i.start(t),r.stop(t+.08),i.stop(t+.06)}},{key:"playBack",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain();r.type="triangle",r.frequency.setValueAtTime(750,t),r.frequency.exponentialRampToValueAtTime(260,t+.015);var a=.16*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(a,t+.002),n.gain.exponentialRampToValueAtTime(1e-4,t+.018),r.connect(n),n.connect(e.destination),r.start(t),r.stop(t+.02);var i=e.createOscillator(),o=e.createGain(),s=e.createBiquadFilter();i.type="sine",i.frequency.setValueAtTime(540,t),i.frequency.exponentialRampToValueAtTime(210,t+.085),s.type="lowpass",s.frequency.setValueAtTime(1200,t),s.frequency.exponentialRampToValueAtTime(360,t+.09),s.Q.setValueAtTime(1.8,t);var l=.28*this.volume;o.gain.setValueAtTime(0,t),o.gain.linearRampToValueAtTime(l,t+.004),o.gain.exponentialRampToValueAtTime(1e-4,t+.095),i.connect(s),s.connect(o),o.connect(e.destination);var u=e.createOscillator(),c=e.createGain();u.type="sine",u.frequency.setValueAtTime(230,t),u.frequency.exponentialRampToValueAtTime(95,t+.095);var d=.18*this.volume;c.gain.setValueAtTime(0,t),c.gain.linearRampToValueAtTime(d,t+.005),c.gain.exponentialRampToValueAtTime(1e-4,t+.1),u.connect(c),c.connect(e.destination),i.start(t),u.start(t),i.stop(t+.1),u.stop(t+.11)}},{key:"playModalOpen",value:function(e){var t=this,r=e.currentTime,n=e.createBiquadFilter();if(n.type="lowpass",n.frequency.setValueAtTime(1100,r),n.Q.setValueAtTime(.7,r),n.connect(e.destination),this.noiseBuffer){var a=e.createBufferSource();a.buffer=this.noiseBuffer;var i=e.createBiquadFilter();i.type="bandpass",i.frequency.setValueAtTime(450,r),i.frequency.exponentialRampToValueAtTime(700,r+.1),i.Q.setValueAtTime(1.2,r);var o=e.createGain(),s=.045*this.volume;o.gain.setValueAtTime(0,r),o.gain.linearRampToValueAtTime(s,r+.03),o.gain.exponentialRampToValueAtTime(1e-4,r+.18),a.connect(i),i.connect(o),o.connect(n),a.start(r),a.stop(r+.19)}[{freqStart:370,freqEnd:392,startOffset:0,dur:.22,vol:.14},{freqStart:554,freqEnd:587.33,startOffset:.022,dur:.24,vol:.12},{freqStart:740,freqEnd:783.99,startOffset:.045,dur:.2,vol:.08}].forEach(function(a){var i=e.createOscillator(),o=e.createGain();i.type="sine";var s=r+a.startOffset;i.frequency.setValueAtTime(a.freqStart,s),i.frequency.exponentialRampToValueAtTime(a.freqEnd,s+.06);var l=t.volume*a.vol;o.gain.setValueAtTime(0,s),o.gain.linearRampToValueAtTime(l,s+.022),o.gain.exponentialRampToValueAtTime(1e-4,s+a.dur),i.connect(o),o.connect(n),i.start(s),i.stop(s+a.dur+.01)})}},{key:"playFolderOpen",value:function(e){var t=this,r=e.currentTime;if(this.noiseBuffer){var n=e.createBufferSource();n.buffer=this.noiseBuffer;var a=e.createBiquadFilter();a.type="bandpass",a.frequency.setValueAtTime(350,r),a.frequency.exponentialRampToValueAtTime(2400,r+.12),a.frequency.exponentialRampToValueAtTime(600,r+.28),a.Q.setValueAtTime(3.5,r);var i=e.createGain(),o=.2*this.volume;i.gain.setValueAtTime(0,r),i.gain.linearRampToValueAtTime(o,r+.08),i.gain.exponentialRampToValueAtTime(1e-4,r+.28),n.connect(a),a.connect(i),i.connect(e.destination),n.start(r),n.stop(r+.3)}[659.25,987.77,1318.5].forEach(function(n,a){var i=e.createOscillator(),o=e.createGain();i.type="sine",i.frequency.setValueAtTime(.85*n,r),i.frequency.exponentialRampToValueAtTime(n,r+.09);var s=.12*t.volume/(a+1);o.gain.setValueAtTime(0,r),o.gain.linearRampToValueAtTime(s,r+.04),o.gain.exponentialRampToValueAtTime(1e-4,r+.35),i.connect(o),o.connect(e.destination),i.start(r),i.stop(r+.36)})}},{key:"playScroll",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain(),a=e.createBiquadFilter();r.type="triangle",r.frequency.setValueAtTime(1400,t),r.frequency.exponentialRampToValueAtTime(800,t+.018),a.type="bandpass",a.frequency.setValueAtTime(1200,t),a.Q.setValueAtTime(2,t);var i=.16*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(i,t+.002),n.gain.exponentialRampToValueAtTime(1e-4,t+.018),r.connect(a),a.connect(n),n.connect(e.destination),r.start(t),r.stop(t+.02)}},{key:"playBoundary",value:function(e){var t=e.currentTime,r=e.createBiquadFilter();r.type="lowpass",r.frequency.setValueAtTime(450,t),r.frequency.exponentialRampToValueAtTime(180,t+.06),r.Q.setValueAtTime(1.2,t),r.connect(e.destination);var n=e.createOscillator(),a=e.createGain();n.type="sine",n.frequency.setValueAtTime(210,t),n.frequency.exponentialRampToValueAtTime(85,t+.055);var i=.17*this.volume;a.gain.setValueAtTime(0,t),a.gain.linearRampToValueAtTime(i,t+.003),a.gain.exponentialRampToValueAtTime(1e-4,t+.065),n.connect(a),a.connect(r),n.start(t),n.stop(t+.07);var o=e.createOscillator(),s=e.createGain();o.type="triangle",o.frequency.setValueAtTime(110,t),o.frequency.exponentialRampToValueAtTime(55,t+.045);var l=.11*this.volume;s.gain.setValueAtTime(0,t),s.gain.linearRampToValueAtTime(l,t+.002),s.gain.exponentialRampToValueAtTime(1e-4,t+.05),o.connect(s),s.connect(r),o.start(t),o.stop(t+.055)}},{key:"playNotification",value:function(e){var t=this,r=e.currentTime;[{f:880,start:0,dur:.22,vol:.25},{f:1320,start:.08,dur:.35,vol:.3}].forEach(function(n){var a=e.createOscillator(),i=e.createGain();a.type="sine",a.frequency.setValueAtTime(n.f,r+n.start);var o=t.volume*n.vol;i.gain.setValueAtTime(0,r+n.start),i.gain.linearRampToValueAtTime(o,r+n.start+.01),i.gain.exponentialRampToValueAtTime(1e-4,r+n.start+n.dur),a.connect(i),i.connect(e.destination),a.start(r+n.start),a.stop(r+n.start+n.dur)})}},{key:"playAchievement",value:function(e){var t=this,r=e.currentTime;[{freq:739.99,time:0,dur:.15},{freq:1108.73,time:.08,dur:.55}].forEach(function(n){var a=e.createOscillator(),i=e.createGain();a.type="sine",a.frequency.setValueAtTime(n.freq,r+n.time);var o=.3*t.volume;i.gain.setValueAtTime(0,r+n.time),i.gain.linearRampToValueAtTime(o,r+n.time+.01),i.gain.exponentialRampToValueAtTime(1e-4,r+n.time+n.dur),a.connect(i),i.connect(e.destination),a.start(r+n.time),a.stop(r+n.time+n.dur)}),[1479.98,1864.66,2217.46,2959.96].forEach(function(n,a){var i=e.createOscillator(),o=e.createGain();i.type="sine",i.frequency.setValueAtTime(n,r+.12);var s=.22*t.volume/(a+1);o.gain.setValueAtTime(0,r+.12),o.gain.linearRampToValueAtTime(s,r+.14),o.gain.exponentialRampToValueAtTime(1e-4,r+.85),i.connect(o),o.connect(e.destination),i.start(r+.12),i.stop(r+.9)})}},{key:"playToastSuccess",value:function(e){var t=this,r=e.currentTime;[{f:739.99,delay:0,dur:.2,vol:.24},{f:932.33,delay:.04,dur:.22,vol:.26},{f:1108.73,delay:.08,dur:.42,vol:.3}].forEach(function(n){var a=e.createOscillator(),i=e.createGain();a.type="sine";var o=r+n.delay;a.frequency.setValueAtTime(n.f,o);var s=t.volume*n.vol;i.gain.setValueAtTime(0,o),i.gain.linearRampToValueAtTime(s,o+.008),i.gain.exponentialRampToValueAtTime(1e-4,o+n.dur),a.connect(i),i.connect(e.destination),a.start(o),a.stop(o+n.dur+.02)})}},{key:"playToastInfo",value:function(e){var t=this,r=e.currentTime;[{f:880,delay:0,dur:.22,vol:.24},{f:1318.5,delay:.045,dur:.3,vol:.26},{f:440,delay:0,dur:.15,vol:.12}].forEach(function(n){var a=e.createOscillator(),i=e.createGain();a.type="sine";var o=r+n.delay;a.frequency.setValueAtTime(n.f,o);var s=t.volume*n.vol;i.gain.setValueAtTime(0,o),i.gain.linearRampToValueAtTime(s,o+.006),i.gain.exponentialRampToValueAtTime(1e-4,o+n.dur),a.connect(i),i.connect(e.destination),a.start(o),a.stop(o+n.dur+.02)})}},{key:"playToastWarning",value:function(e){var t=this,r=e.currentTime;[{f:554.37,delay:0,dur:.06,vol:.25},{f:466.16,delay:.075,dur:.12,vol:.26}].forEach(function(n){var a=e.createOscillator(),i=e.createGain(),o=e.createBiquadFilter();a.type="triangle",o.type="bandpass",o.frequency.setValueAtTime(900,r+n.delay),o.Q.setValueAtTime(2.2,r+n.delay);var s=r+n.delay;a.frequency.setValueAtTime(n.f,s);var l=t.volume*n.vol;i.gain.setValueAtTime(0,s),i.gain.linearRampToValueAtTime(l,s+.005),i.gain.exponentialRampToValueAtTime(1e-4,s+n.dur),a.connect(o),o.connect(i),i.connect(e.destination),a.start(s),a.stop(s+n.dur+.01)})}},{key:"playToastError",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain(),a=e.createBiquadFilter();r.type="sawtooth",r.frequency.setValueAtTime(392,t),r.frequency.exponentialRampToValueAtTime(220,t+.12),a.type="lowpass",a.frequency.setValueAtTime(650,t),a.frequency.exponentialRampToValueAtTime(200,t+.12),a.Q.setValueAtTime(2,t);var i=.24*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(i,t+.005),n.gain.exponentialRampToValueAtTime(1e-4,t+.13),r.connect(a),a.connect(n),n.connect(e.destination);var o=e.createOscillator(),s=e.createGain();o.type="sine",o.frequency.setValueAtTime(140,t),o.frequency.exponentialRampToValueAtTime(60,t+.15),s.gain.setValueAtTime(0,t),s.gain.linearRampToValueAtTime(.18*this.volume,t+.005),s.gain.exponentialRampToValueAtTime(1e-4,t+.15),o.connect(s),s.connect(e.destination),r.start(t),o.start(t),r.stop(t+.14),o.stop(t+.16)}},{key:"playToggle",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain();r.type="triangle",r.frequency.setValueAtTime(1100,t),r.frequency.exponentialRampToValueAtTime(1600,t+.02);var a=.18*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(a,t+.002),n.gain.exponentialRampToValueAtTime(1e-4,t+.03),r.connect(n),n.connect(e.destination),r.start(t),r.stop(t+.035)}}],function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,e),t}());function NO(e){Nj.play(e)}function Nk(){return Nj.getIsMuted()}function NE(){return Nj.toggleMute()}var NP=(0,g.lazy)(function(){return Promise.all([r.e("6880"),r.e("4646")]).then(r.bind(r,9477)).then(function(e){return{default:e.RobotStage}})});function NA(){Promise.all([r.e("6880"),r.e("4646")]).then(r.bind(r,9477))}function ND(e){return(0,v.jsx)(g.Suspense,{fallback:(0,v.jsx)("div",{role:"status","aria-label":"Chargement du robot",style:{width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center"},children:(0,v.jsx)("div",{className:"w-10 h-10 border-2 border-teal-400 border-t-transparent rounded-full animate-spin"})}),children:(0,v.jsx)(NP,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},e))})}var NC=r(2707),NT=r(9881);function NN(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function NR(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function NM(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){NR(e,t,r[t])})}return e}function NI(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function N_(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||NF(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function NL(e){return function(e){if(Array.isArray(e))return NN(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||NF(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function NF(e,t){if(e){if("string"==typeof e)return NN(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return NN(e,t)}}var NB={type:"spring",stiffness:560,damping:34,mass:.7};function NV(e,t){return e.find(function(e){return e.id===t})}function Nz(e,t){return null==e?void 0:e.operators.find(function(e){return e.value===t})}function NW(e){var t,r,n=e.anchorKey,a=e.label,i=e.onClose,o=e.children,s=g.useRef(null),l=Ed(),u=N_(g.useState(null),2),c=u[0],d=u[1],f=N_(g.useState(!1),2),p=f[0],h=f[1],m=N_(g.useState(null),2),y=m[0],b=m[1];g.useLayoutEffect(function(){var e=document.querySelector('[data-fb-anchor="'.concat(n,'"]'));d(e),h(!!(null==e?void 0:e.closest(".dark")))},[n]);var x=g.useRef(n);return x.current=n,g.useEffect(function(){return function(){var e;null==(e=document.querySelector('[data-fb-anchor="'.concat(x.current,'"]')))||e.focus()}},[]),g.useLayoutEffect(function(){if(c){var e=function(){var e=s.current;if(e){var t=c.getBoundingClientRect(),r=e.offsetWidth,n=e.offsetHeight,a=t.left,i=t.bottom+6;a=Math.max(8,a=Math.min(a,window.innerWidth-r-8)),i+n>window.innerHeight-8&&(i=t.top-6-n),b({top:i,left:a})}};return e(),window.addEventListener("resize",e),window.addEventListener("scroll",e,!0),function(){window.removeEventListener("resize",e),window.removeEventListener("scroll",e,!0)}}},[c]),g.useEffect(function(){var e=function(e){!s.current||s.current.contains(e.target)||c&&c.contains(e.target)||i()},t=function(e){"Escape"===e.key&&(e.stopPropagation(),i())};return document.addEventListener("pointerdown",e,!0),document.addEventListener("keydown",t,!0),function(){document.removeEventListener("pointerdown",e,!0),document.removeEventListener("keydown",t,!0)}},[c,i]),(0,tZ.createPortal)((0,v.jsx)("div",{className:p?"dark":"",style:{display:"contents"},children:(0,v.jsx)(hz.div,{ref:s,role:"dialog","aria-label":a,initial:!l&&{opacity:0,y:-3,scale:.985},animate:{opacity:1,y:0,scale:1},transition:{duration:.12,ease:[.2,.8,.2,1]},style:{position:"fixed",top:null!=(t=null==y?void 0:y.top)?t:-9999,left:null!=(r=null==y?void 0:y.left)?r:-9999,zIndex:60},className:"min-w-[13rem] max-w-[18rem] overflow-hidden rounded-lg border border-[var(--fb-border)] bg-[var(--fb-bg-surface)] shadow-[0_10px_30px_-8px_rgba(0,0,0,0.25)]",children:o})}),document.body)}function N$(e){var t=e.items,r=e.multi,n=e.loading,a=e.error,i=e.searchable,o=e.placeholder,s=e.onQuery,l=e.onPick,u=e.onRetry,c=e.ariaLabel,d=N_(g.useState(""),2),f=d[0],p=d[1],h=N_(g.useState(0),2),m=h[0],y=h[1],b=g.useId(),x=g.useRef(null),w=g.useRef(null),S=g.useMemo(function(){if(s)return t;var e=f.trim().toLowerCase();return e?t.filter(function(t){return t.label.toLowerCase().includes(e)}):t},[t,f,s]);g.useEffect(function(){var e=requestAnimationFrame(function(){var e;return null==(e=x.current)?void 0:e.focus()});return function(){return cancelAnimationFrame(e)}},[]),g.useEffect(function(){y(function(e){return Math.min(e,Math.max(0,S.length-1))})},[S.length]),g.useEffect(function(){var e,t=null==(e=w.current)?void 0:e.querySelector('[data-idx="'.concat(m,'"]'));null==t||t.scrollIntoView({block:"nearest"})},[m]);var j=function(e){var t=S[e];t&&l(t.value)},O=function(e){"ArrowDown"===e.key?(e.preventDefault(),y(function(e){return Math.min(e+1,S.length-1)})):"ArrowUp"===e.key?(e.preventDefault(),y(function(e){return Math.max(e-1,0)})):"Home"===e.key?(e.preventDefault(),y(0)):"End"===e.key?(e.preventDefault(),y(S.length-1)):"Enter"===e.key&&(e.preventDefault(),j(m))};return(0,v.jsxs)("div",{children:[(void 0===i||i)&&(0,v.jsx)("div",{className:"border-b border-[var(--fb-border)] p-1.5",children:(0,v.jsx)("input",{ref:x,role:"combobox","aria-expanded":"true","aria-controls":b,"aria-activedescendant":S[m]?"".concat(b,"-").concat(m):void 0,"aria-label":c,value:f,onChange:function(e){p(e.target.value),null==s||s(e.target.value)},onKeyDown:O,placeholder:void 0===o?"Rechercher…":o,className:"w-full bg-transparent px-1.5 py-1 text-[13px] text-[var(--fb-fg)] outline-none placeholder:text-[var(--fb-fg-subtle)]",autoComplete:"off",spellCheck:!1})}),(0,v.jsxs)("ul",{ref:w,id:b,role:"listbox","aria-multiselectable":r||void 0,"aria-label":c,className:"max-h-60 overflow-y-auto p-1",onKeyDown:O,tabIndex:-1,children:[n&&(0,v.jsxs)("li",{className:"flex items-center gap-2 px-2 py-3 text-[13px] text-[var(--fb-fg-muted)]",children:[(0,v.jsx)(NX,{})," Chargement des options…"]}),a&&!n&&(0,v.jsxs)("li",{className:"px-2 py-2.5 text-[13px]",children:[(0,v.jsx)("p",{className:"text-[var(--fb-fg-muted)]",children:"Impossible de charger les options."}),(0,v.jsx)("button",{type:"button",onClick:u,className:"mt-1 rounded-md px-1.5 py-0.5 text-[13px] font-medium text-[var(--fb-fg)] underline decoration-[var(--fb-fg-subtle)] underline-offset-2 hover:decoration-[var(--fb-fg)] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--fb-accent)]/60",children:"R\xe9essayer"})]}),!n&&!a&&0===S.length&&(0,v.jsx)("li",{className:"px-2 py-3 text-[13px] text-[var(--fb-fg-muted)]",children:"Aucun r\xe9sultat"}),!n&&!a&&S.map(function(e,t){var n=t===m;return(0,v.jsxs)("li",{id:"".concat(b,"-").concat(t),"data-idx":t,role:"option","aria-selected":r?!!e.selected:n,onMouseEnter:function(){return y(t)},onClick:function(){return l(e.value)},className:["flex cursor-pointer items-center gap-2 rounded-md px-2 py-1.5 text-[13px] text-[var(--fb-fg)]",n?"bg-[var(--fb-bg-active)]":"bg-transparent"].join(" "),children:[r&&(0,v.jsx)("span",{"aria-hidden":!0,className:["flex h-3.5 w-3.5 shrink-0 items-center justify-center rounded-[4px] border transition-colors",e.selected?"border-[var(--fb-border-strong)] bg-[var(--fb-border-strong)] text-[var(--fb-fg-on-accent)]":"border-[var(--fb-border)]"].join(" "),children:e.selected&&(0,v.jsx)(NY,{})}),e.glyph&&(0,v.jsx)("span",{className:"shrink-0","aria-hidden":!0,children:e.glyph}),(0,v.jsx)("span",{className:"truncate",children:e.label}),!r&&e.selected&&(0,v.jsx)("span",{className:"ml-auto text-[var(--fb-fg-muted)]",children:(0,v.jsx)(NY,{})})]},e.value)})]})]})}function NU(e){var t=e.inputType,r=e.arity,n=e.values,a=e.onCommit,i=e.ariaLabel,o=e.rangeLabels,s=void 0===o?["Min","Max"]:o,l=e.placeholder,u=g.useRef(null);g.useEffect(function(){var e=requestAnimationFrame(function(){var e;return null==(e=u.current)?void 0:e.focus()});return function(){return cancelAnimationFrame(e)}},[]);var c="w-full rounded-md border border-[var(--fb-border)] bg-transparent px-2 py-1.5 text-[13px] text-[var(--fb-fg)] outline-none focus-visible:ring-2 focus-visible:ring-[var(--fb-accent)]/60";if(2===r){var d=N_(n,2),f=d[0],p=void 0===f?"":f,h=d[1],m=void 0===h?"":h;return(0,v.jsxs)("div",{className:"flex items-start gap-2 p-2",children:[(0,v.jsxs)("label",{className:"flex flex-1 flex-col gap-1",children:[(0,v.jsx)("span",{className:"text-[11px] text-[var(--fb-fg-muted)]",children:s[0]}),(0,v.jsx)("input",{ref:u,type:t,value:p,"aria-label":"".concat(i," — ").concat(s[0]),onChange:function(e){return a([e.target.value,m])},className:c})]}),(0,v.jsxs)("label",{className:"flex flex-1 flex-col gap-1",children:[(0,v.jsx)("span",{className:"text-[11px] text-[var(--fb-fg-muted)]",children:s[1]}),(0,v.jsx)("input",{type:t,value:m,"aria-label":"".concat(i," — ").concat(s[1]),onChange:function(e){return a([p,e.target.value])},className:c})]})]})}var y=N_(n,1)[0];return(0,v.jsx)("div",{className:"p-2",children:(0,v.jsx)("input",{ref:u,type:t,value:void 0===y?"":y,placeholder:l,"aria-label":i,onChange:function(e){return a([e.target.value])},onKeyDown:function(e){"Enter"===e.key&&e.currentTarget.blur()},className:c})})}function NH(e){var t=e.role,r=e.children,n=e.onOpen,a=e.registerRef,i=e.tabIndex,o=e.ariaLabel,s=e.anchorKey,l=e.onFocus,u=e.muted,c=e.active,d=e.flash,f=e.disabled;return(0,v.jsx)("button",{type:"button",ref:a,tabIndex:i,"aria-label":o,"aria-haspopup":"listbox","aria-expanded":c,"aria-disabled":f||void 0,"data-fb-anchor":s,onFocus:l,onClick:n,"data-flash":d?"":void 0,className:["relative flex items-center gap-1 whitespace-nowrap px-2 py-[4px] text-[13px] leading-[1.35] transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-[var(--fb-accent)]/70",f?"cursor-default":"active:scale-[0.98]",u?"text-[var(--fb-fg-muted)]":"text-[var(--fb-fg)]",c?"bg-[var(--fb-bg-active)]":f?"":"hover:bg-[var(--fb-bg-hover)]","field"===t?"rounded-l-md font-medium":"","data-[flash]:animate-[fb-flash_620ms_ease-out]"].join(" "),children:r})}function NG(e){var t,r,n=e.fields,a=e.value,i=e.onChange,o=e.addLabel,s=void 0===o?"Filtre":o,l=e.emptyLabel,u=void 0===l?"Ajouter un filtre":l,c=e.clearLabel,d=e.allowDuplicateFields,f=void 0!==d&&d,p=e.disabled,h=e.className,m=e["aria-label"],y=Ed(),b=N_(g.useState(null),2),x=b[0],w=b[1],S=N_(g.useState(null),2),j=S[0],O=S[1],k=g.useRef([]),E=N_(g.useState(0),2),P=E[0],A=E[1],D=N_(g.useState({}),2),C=D[0],T=D[1],N=[];a.forEach(function(e){N.push({filterId:e.id,kind:"field"}),N.push({filterId:e.id,kind:"operator"}),N.push({filterId:e.id,kind:"value"}),N.push({filterId:e.id,kind:"remove"})}),N.push({kind:"add"}),g.useEffect(function(){P>N.length-1&&A(N.length-1)},[N.length,P]);var R=function(e){var t,r=Math.max(0,Math.min(e,N.length-1));A(r),null==(t=k.current[r])||t.focus()},M=function(e){var t,r,o=NV(n,e);if(o){var s=o.operators[0],l={id:"u">typeof crypto&&"randomUUID"in crypto?crypto.randomUUID():"f_".concat(Math.random().toString(36).slice(2,9)),field:e,operator:null!=(t=null==s?void 0:s.value)?t:"is",values:[]};i(NL(a).concat([l])),w((null!=(r=null==s?void 0:s.arity)?r:1)===0?null:{kind:"value",filterId:l.id})}},I=function(e,t){var r,o=NV(n,t),s=null==o?void 0:o.operators[0];i(a.map(function(r){var n;return r.id===e?NI(NM({},r),{field:t,operator:null!=(n=null==s?void 0:s.value)?n:r.operator,values:[]}):r})),w((null!=(r=null==s?void 0:s.arity)?r:1)===0?null:{kind:"value",filterId:e})},L=function(e,t){var r,o,s=a.find(function(t){return t.id===e}),l=Nz(NV(n,null!=(r=null==s?void 0:s.field)?r:""),t),u=null!=(o=null==l?void 0:l.arity)?o:1;i(a.map(function(r){if(r.id!==e)return r;var n=0===u?[]:(null==l?void 0:l.multi)?r.values:r.values.slice(0,u);return NI(NM({},r),{operator:t,values:n})})),w(0===u?null:{kind:"value",filterId:e})},F=function(e,t,r){i(a.map(function(n){if(n.id!==e)return n;if(!r)return NI(NM({},n),{values:[t]});var a=n.values.includes(t);return NI(NM({},n),{values:a?n.values.filter(function(e){return e!==t}):NL(n.values).concat([t])})})),O(e),window.setTimeout(function(){return O(function(t){return t===e?null:t})},640),r||w(null)},B=function(e,t){i(a.map(function(r){return r.id===e?NI(NM({},r),{values:t}):r}))},V=function(e,t){i(a.filter(function(t){return t.id!==e})),w(null);var r=Math.max(0,(null!=t?t:P)-1);requestAnimationFrame(function(){return R(r)})},z=g.useCallback(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";e.loadOptions&&(T(function(t){var r,n;return NI(NM({},t),NR({},e.id,{loading:!0,error:!1,options:null!=(r=null==(n=t[e.id])?void 0:n.options)?r:[]}))}),e.loadOptions(t).then(function(t){return T(function(r){return NI(NM({},r),NR({},e.id,{loading:!1,error:!1,options:t}))})}).catch(function(){return T(function(t){return NI(NM({},t),NR({},e.id,{loading:!1,error:!0,options:[]}))})}))},[]);g.useEffect(function(){if(x&&"value"===x.kind){var e,t,r=a.find(function(e){return e.id===x.filterId}),i=NV(n,null!=(e=null==r?void 0:r.field)?e:"");(null==i?void 0:i.loadOptions)&&!(null==(t=C[i.id])?void 0:t.options.length)&&z(i)}},[x]);var W=0,$=function(){var e=W++;return{idx:e,register:function(t){return k.current[e]=t},tabIndex:e===P?0:-1,onFocus:function(){return A(e)}}},U=x?"add"===x.kind?"add":"".concat(x.filterId,":").concat(x.kind):null,H=function(){if(!x)return"";if("add"===x.kind)return u;if("field"===x.kind)return"Modifier le champ du filtre";if("operator"===x.kind)return"Choisir un op\xe9rateur";var e,t=a.find(function(e){return e.id===x.filterId}),r=NV(n,null!=(e=null==t?void 0:t.field)?e:"");return r?"Valeur pour ".concat(r.label):"Valeur du filtre"}(),G=a.length>1;return(0,v.jsxs)("div",{role:"toolbar","aria-label":void 0===m?"Filtres":m,"aria-orientation":"horizontal","aria-disabled":p||void 0,onKeyDown:function(e){if(!x){var t=N.length-1;if("ArrowRight"===e.key)e.preventDefault(),R(P>=t?0:P+1);else if("ArrowLeft"===e.key)e.preventDefault(),R(P<=0?t:P-1);else if("Home"===e.key)e.preventDefault(),R(0);else if("End"===e.key)e.preventDefault(),R(t);else if("Backspace"===e.key||"Delete"===e.key){var r=N[P];(null==r?void 0:r.filterId)&&(e.preventDefault(),V(r.filterId,P))}}},className:["flex flex-wrap items-center gap-1.5",p?"pointer-events-none opacity-50":"",null!=h?h:""].join(" "),children:[(0,v.jsx)("style",{children:"\n:root {\n --fb-fg: #18181b;\n --fb-fg-muted: #71717a;\n --fb-fg-subtle: #a1a1aa;\n --fb-fg-on-accent: #ffffff;\n --fb-bg-surface: #ffffff;\n --fb-bg-chip: rgba(24, 24, 27, 0.04);\n --fb-bg-hover: rgba(24, 24, 27, 0.06);\n --fb-bg-active: rgba(24, 24, 27, 0.08);\n --fb-border: rgba(24, 24, 27, 0.09);\n --fb-border-strong: #18181b;\n --fb-accent: #3b82f6;\n --fb-accent-rgb: 59 130 246;\n}\n.dark {\n --fb-fg: #f4f4f5;\n --fb-fg-muted: #a1a1aa;\n --fb-fg-subtle: #71717a;\n --fb-fg-on-accent: #18181b;\n --fb-bg-surface: #18181b;\n --fb-bg-chip: rgba(255, 255, 255, 0.05);\n --fb-bg-hover: rgba(255, 255, 255, 0.08);\n --fb-bg-active: rgba(255, 255, 255, 0.12);\n --fb-border: rgba(255, 255, 255, 0.08);\n --fb-border-strong: #f4f4f5;\n --fb-accent: #60a5fa;\n --fb-accent-rgb: 96 165 250;\n}\n@keyframes fb-flash {\n 0% { background-color: rgb(var(--fb-accent-rgb) / 0.18); }\n 100% { background-color: transparent; }\n}\n@media (prefers-reduced-motion: reduce) {\n @keyframes fb-flash {\n 0%, 100% { background-color: transparent; }\n }\n}\n"}),(0,v.jsx)(jA,{initial:!1,mode:"popLayout",children:a.map(function(e){var t,r,a,i,o,s,l,u,c,d=NV(n,e.field),f=Nz(d,e.operator),p=null!=(t=null==f?void 0:f.arity)?t:1,h=null!=(r=null==d?void 0:d.type)?r:"select",m=0===p?{text:"—",empty:!1,glyphs:[]}:"select"===h?function(e,t){if(!t.length)return{text:"Choisir…",empty:!0,glyphs:[]};var r=function(t){return null==e?void 0:e.find(function(e){return e.value===t})},n=function(e){var t,n;return null!=(t=null==(n=r(e))?void 0:n.label)?t:e},a=t.map(function(e){var t;return null==(t=r(e))?void 0:t.glyph}).filter(Boolean).slice(0,3);return 1===t.length?{text:n(t[0]),empty:!1,glyphs:a}:t.length<=3?{text:t.map(n).join(", "),empty:!1,glyphs:a}:{text:"".concat(n(t[0])," +").concat(t.length-1),empty:!1,glyphs:a}}((null==d?void 0:d.loadOptions)?null==(c=C[d.id])?void 0:c.options:null==d?void 0:d.options,e.values):function(e,t,r){if(0===t)return{text:"—",empty:!1,glyphs:[]};if(!r.some(function(e){return""!==e&&null!=e}))return{text:"Choisir une valeur…",empty:!0,glyphs:[]};var n,a,i,o=function(t){if(!t)return"…";if("date"!==e)return t;var r=new Date(t);return Number.isNaN(r.getTime())?t:r.toLocaleDateString()};return 2===t?{text:"".concat(o(null!=(a=r[0])?a:"")," – ").concat(o(null!=(i=r[1])?i:"")),empty:!1,glyphs:[]}:{text:o(null!=(n=r[0])?n:""),empty:!1,glyphs:[]}}(h,p,e.values),g=$(),b=$(),S=$(),O=$(),k=j===e.id;return(0,v.jsxs)(hz.div,{layout:!y,initial:!y&&{opacity:0,scale:.9},animate:{opacity:1,scale:1},exit:y?{opacity:0}:{opacity:0,scale:.9},transition:NB,className:"group flex items-stretch overflow-hidden rounded-md border border-[var(--fb-border)] bg-[var(--fb-bg-chip)]",children:[(0,v.jsxs)(NH,{role:"field",registerRef:g.register,tabIndex:g.tabIndex,onFocus:g.onFocus,anchorKey:"".concat(e.id,":field"),active:(null==x?void 0:x.kind)==="field"&&x.filterId===e.id,ariaLabel:"Champ : ".concat(null!=(a=null==d?void 0:d.label)?a:e.field,". Modifier le champ."),onOpen:function(){return w({kind:"field",filterId:e.id})},children:[(null==d?void 0:d.icon)&&(0,v.jsx)("span",{className:"text-[var(--fb-fg-muted)]","aria-hidden":!0,children:d.icon}),null!=(i=null==d?void 0:d.label)?i:e.field]}),(0,v.jsx)("span",{"aria-hidden":!0,className:"w-px self-stretch bg-[var(--fb-border)]"}),(0,v.jsx)(NH,{role:"operator",registerRef:b.register,tabIndex:b.tabIndex,onFocus:b.onFocus,anchorKey:"".concat(e.id,":operator"),muted:!0,active:(null==x?void 0:x.kind)==="operator"&&x.filterId===e.id,ariaLabel:"Op\xe9rateur : ".concat(null!=(o=null==f?void 0:f.label)?o:e.operator,". Modifier l'op\xe9rateur."),onOpen:function(){return w({kind:"operator",filterId:e.id})},children:null!=(s=null==f?void 0:f.label)?s:e.operator}),(0,v.jsx)("span",{"aria-hidden":!0,className:"w-px self-stretch bg-[var(--fb-border)]"}),(0,v.jsxs)(NH,{role:"value",registerRef:S.register,tabIndex:S.tabIndex,onFocus:S.onFocus,anchorKey:"".concat(e.id,":value"),muted:m.empty||0===p,disabled:0===p,active:(null==x?void 0:x.kind)==="value"&&x.filterId===e.id,flash:k,ariaLabel:0===p?"Valeur : aucune valeur requise pour l'op\xe9rateur ".concat(null!=(l=null==f?void 0:f.label)?l:e.operator,"."):"Valeur : ".concat(m.empty?"aucune s\xe9lectionn\xe9e":m.text,". Modifier la valeur."),onOpen:function(){0!==p&&w({kind:"value",filterId:e.id})},children:[!m.empty&&m.glyphs.length>0&&(0,v.jsx)("span",{className:"flex shrink-0 items-center gap-0.5","aria-hidden":!0,children:m.glyphs.map(function(e,t){return(0,v.jsx)("span",{className:"flex items-center",children:e},t)})}),(0,v.jsx)("span",{className:"max-w-[12rem] truncate font-medium text-[var(--fb-fg)]",children:m.empty?(0,v.jsx)("span",{className:"font-normal text-[var(--fb-fg-subtle)]",children:m.text}):m.text})]}),(0,v.jsx)("button",{type:"button",ref:O.register,tabIndex:O.tabIndex,onFocus:O.onFocus,onClick:function(){return V(e.id,O.idx)},"aria-label":"Supprimer le filtre ".concat(null!=(u=null==d?void 0:d.label)?u:e.field),className:"flex items-center px-1.5 text-[var(--fb-fg-subtle)] transition-colors hover:bg-[var(--fb-bg-hover)] hover:text-[var(--fb-fg)] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-[var(--fb-accent)]/70 active:scale-[0.98]",children:(0,v.jsx)(Nq,{})})]},e.id)})}),(t=$(),r=0===a.length,(0,v.jsxs)("button",{type:"button",ref:t.register,tabIndex:t.tabIndex,onFocus:t.onFocus,"data-fb-anchor":"add","aria-label":r?u:s,"aria-haspopup":"listbox","aria-expanded":(null==x?void 0:x.kind)==="add",onClick:function(){return w({kind:"add"})},className:"flex items-center gap-1 rounded-md border border-dashed border-[var(--fb-border)] px-2 py-[6px] text-[13px] font-medium leading-none text-[var(--fb-fg-muted)] transition-colors hover:border-[var(--fb-border-strong)]/40 hover:bg-[var(--fb-bg-hover)] hover:text-[var(--fb-fg)] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--fb-accent)]/70 active:scale-[0.98]",children:[(0,v.jsx)(NK,{}),r?u:s]})),G&&(0,v.jsx)("button",{type:"button",onClick:function(){i([]),w(null),requestAnimationFrame(function(){return R(0)})},className:"ml-0.5 rounded-md px-2 py-[6px] text-[13px] leading-none text-[var(--fb-fg-muted)] transition-colors hover:bg-[var(--fb-bg-hover)] hover:text-[var(--fb-fg)] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--fb-accent)]/70",children:void 0===c?"R\xe9initialiser":c}),x&&U&&(0,v.jsx)(NW,{anchorKey:U,label:H,onClose:function(){return w(null)},children:function(){if(!x)return null;if("add"===x.kind||"field"===x.kind){var e,t,r,i,o,s="field"===x.kind?x.filterId:null,l=new Set(a.filter(function(e){return e.id!==s}).map(function(e){return e.field})),u=n.filter(function(e){return f||!l.has(e.id)}).map(function(e){return{value:e.id,label:e.label,glyph:e.icon}});return(0,v.jsx)(N$,{ariaLabel:H,items:u,multi:!1,onPick:function(e){return"add"===x.kind?M(e):I(x.filterId,e)}},null!=U?U:void 0)}var c=a.find(function(e){return e.id===x.filterId}),d=NV(n,null!=(e=null==c?void 0:c.field)?e:"");if(!c||!d)return null;if("operator"===x.kind){var p=d.operators.map(function(e){return{value:e.value,label:e.label,selected:e.value===c.operator}});return(0,v.jsx)(N$,{ariaLabel:H,items:p,multi:!1,searchable:p.length>6,onPick:function(e){return L(c.id,e)}},null!=U?U:void 0)}var h=Nz(d,c.operator),m=null!=(t=null==h?void 0:h.arity)?t:1;if(0===m)return null;var y=null!=(r=d.type)?r:"select";if("text"===y||"number"===y||"date"===y)return(0,v.jsx)(NU,{inputType:y,arity:m,values:c.values,onCommit:function(e){return B(c.id,e)},ariaLabel:H,rangeLabels:"date"===y?["Du","Au"]:["Min","Max"],placeholder:"text"===y?"Rechercher…":void 0},null!=U?U:void 0);var g=!!(null==h?void 0:h.multi),b=d.loadOptions?C[d.id]:void 0,w=(d.loadOptions?null!=(i=null==b?void 0:b.options)?i:[]:null!=(o=d.options)?o:[]).map(function(e){return{value:e.value,label:e.label,glyph:e.glyph,selected:c.values.includes(e.value)}});return(0,v.jsx)(N$,{ariaLabel:H,items:w,multi:g,loading:null==b?void 0:b.loading,error:null==b?void 0:b.error,onQuery:d.loadOptions?function(e){return z(d,e)}:void 0,onRetry:function(){return z(d)},onPick:function(e){return F(c.id,e,g)}},null!=U?U:void 0)}()})]})}function NK(){return(0,v.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":!0,children:(0,v.jsx)("path",{d:"M6 2.5v7M2.5 6h7",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}function Nq(){return(0,v.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":!0,children:(0,v.jsx)("path",{d:"M3 3l6 6M9 3l-6 6",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}function NY(){return(0,v.jsx)("svg",{width:"11",height:"11",viewBox:"0 0 12 12",fill:"none","aria-hidden":!0,children:(0,v.jsx)("path",{d:"M2.5 6.2l2.2 2.3L9.5 3.7",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round",strokeLinejoin:"round"})})}function NX(){return(0,v.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":!0,className:"animate-spin",children:[(0,v.jsx)("circle",{cx:"7",cy:"7",r:"5.5",stroke:"currentColor",strokeOpacity:"0.2",strokeWidth:"1.5"}),(0,v.jsx)("path",{d:"M12.5 7A5.5 5.5 0 0 0 7 1.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]})}let NZ=NG;var NQ={text:[{value:"contains",label:"contient"},{value:"not_contains",label:"ne contient pas"},{value:"equals",label:"est exactement"},{value:"starts_with",label:"commence par"},{value:"is_empty",label:"est vide",arity:0},{value:"is_not_empty",label:"n'est pas vide",arity:0}],number:[{value:"eq",label:"="},{value:"neq",label:"≠"},{value:"gt",label:">"},{value:"gte",label:"≥"},{value:"lt",label:"<"},{value:"lte",label:"≤"},{value:"between",label:"entre",arity:2}],date:[{value:"on",label:"le"},{value:"before",label:"avant le"},{value:"after",label:"apr\xe8s le"},{value:"between",label:"entre",arity:2}],boolean:[{value:"is",label:"est"}],select:[{value:"is",label:"est"},{value:"is_not",label:"n'est pas"},{value:"is_any_of",label:"est l'un de",multi:!0}]},NJ=[{value:"true",label:"Oui"},{value:"false",label:"Non"}];function N0(e,t){var r=function(e){var r,n;return null!=(r=null==(n=t.find(function(t){return t.field===e}))?void 0:n.values)?r:[]};return e.fields.filter(function(e){return!e.dependsOn||r(e.dependsOn).length>0}).map(function(e){if("boolean"===e.type)return{id:e.id,label:e.label,icon:e.icon,type:"select",operators:null!=(a=e.operators)?a:NQ.boolean,options:null!=(i=e.options)?i:NJ};var t,n,a,i,o=null!=(t=e.operators)?t:NQ[e.type];if("select"!==e.type)return{id:e.id,label:e.label,icon:e.icon,type:e.type,operators:o};var s=e.dependsOn?r(e.dependsOn):[];return e.optionsByParent?{id:e.id,label:e.label,icon:e.icon,type:"select",operators:o,options:s.flatMap(function(t){var r,n;return null!=(r=null==(n=e.optionsByParent)?void 0:n[t])?r:[]})}:e.loadOptions?{id:e.id,label:e.label,icon:e.icon,type:"select",operators:o,loadOptions:function(t){return e.loadOptions(t,{parentValues:s})}}:{id:e.id,label:e.label,icon:e.icon,type:"select",operators:o,options:null!=(n=e.options)?n:[]}})}function N1(e,t){for(var r=t,n=0;n<e.fields.length&&"break"!==function(){var t=!1,n=r.filter(function(n){var a=e.fields.find(function(e){return e.id===n.field});if(!(null==a?void 0:a.dependsOn))return!0;var i=r.find(function(e){return e.field===a.dependsOn}),o=!!i&&i.values.length>0;return o||(t=!0),o});if(r=n.map(function(r){var a,i=e.fields.find(function(e){return e.id===r.field});if(!(null==i?void 0:i.dependsOn)||!i.optionsByParent)return r;var o=n.find(function(e){return e.field===i.dependsOn}),s=new Set((null!=(a=null==o?void 0:o.values)?a:[]).flatMap(function(e){var t,r,n;return null!=(t=null==(n=i.optionsByParent)||null==(r=n[e])?void 0:r.map(function(e){return e.value}))?t:[]})),l=r.values.filter(function(e){return s.has(e)});return l.length!==r.values.length&&(t=!0),l.length===r.values.length?r:NI(NM({},r),{values:l})}),!t)return"break"}();n++);return r}function N2(e,t,r){return{fields:g.useMemo(function(){return N0(e,t)},[e,t]),onChange:g.useCallback(function(t){return r(N1(e,t))},[e,r])}}function N3(e,t,r,n){var a=function(e){return null==e?"":String(e)};switch(t){case"is_empty":return""===a(r);case"is_not_empty":return""!==a(r);case"contains":return a(r).toLowerCase().includes(a(n[0]).toLowerCase());case"not_contains":return!a(r).toLowerCase().includes(a(n[0]).toLowerCase());case"starts_with":return a(r).toLowerCase().startsWith(a(n[0]).toLowerCase());case"equals":return a(r).toLowerCase()===a(n[0]).toLowerCase();case"is":return a(r)===n[0];case"is_not":return a(r)!==n[0];case"is_any_of":return n.includes(a(r));case"eq":return Number(r)===Number(n[0]);case"neq":return Number(r)!==Number(n[0]);case"gt":return Number(r)>Number(n[0]);case"gte":return Number(r)>=Number(n[0]);case"lt":return Number(r)<Number(n[0]);case"lte":return Number(r)<=Number(n[0]);case"between":var i=N_(n,2),o=i[0],s=i[1];if("date"===e){var l=new Date(a(r)).getTime(),u=!o||l>=new Date(o).getTime(),c=!s||l<=new Date(s).getTime();return u&&c}var d=Number(r),f=void 0===o||""===o||d>=Number(o),p=void 0===s||""===s||d<=Number(s);return f&&p;case"on":return a(r).slice(0,10)===a(n[0]).slice(0,10);case"before":return new Date(a(r)).getTime()<new Date(n[0]).getTime();case"after":return new Date(a(r)).getTime()>new Date(n[0]).getTime();default:return!0}}function N4(e,t,r,n){return Array.isArray(r)?r.some(function(r){return N3(e,t,r,n)}):N3(e,t,r,n)}function N5(e,t){return"is_empty"===e||"is_not_empty"===e||t.some(function(e){return""!==e&&void 0!==e})}function N6(e,t,r,n){return t.every(function(t){if(!N5(t.operator,t.values))return!0;var a=r.fields.find(function(e){return e.id===t.field}),i=null==a?void 0:a.type;return N4("boolean"===i||void 0===i?"select":i,t.operator,n(e,t.field),t.values)})}var N8=["\xe9lections","corruption","budget","diplomatie","sant\xe9","\xe9ducation","climat","s\xe9curit\xe9"],N9={fields:[{id:"status",label:"Statut",type:"select",options:[{value:"draft",label:"Brouillon"},{value:"published",label:"Publi\xe9"},{value:"archived",label:"Archiv\xe9"}]},{id:"category",label:"Cat\xe9gorie",type:"select",options:[{value:"politique",label:"Politique"},{value:"sport",label:"Sport"},{value:"economie",label:"\xc9conomie"},{value:"culture",label:"Culture"}]},{id:"subcategory",label:"Sous-cat\xe9gorie",type:"select",dependsOn:"category",optionsByParent:{politique:[{value:"national",label:"National"},{value:"international",label:"International"},{value:"institutions",label:"Institutions"}],sport:[{value:"football",label:"Football"},{value:"basketball",label:"Basketball"},{value:"athletisme",label:"Athl\xe9tisme"}],economie:[{value:"marches",label:"March\xe9s"},{value:"entreprises",label:"Entreprises"},{value:"emploi",label:"Emploi"}],culture:[{value:"musique",label:"Musique"},{value:"cinema",label:"Cin\xe9ma"},{value:"litterature",label:"Litt\xe9rature"}]}},{id:"tags",label:"Tags",type:"select",loadOptions:function(e){return new Promise(function(t){window.setTimeout(function(){var r=e.trim().toLowerCase();t(N8.filter(function(e){return e.toLowerCase().includes(r)}).map(function(e){return{value:e,label:e}}))},350)})}},{id:"title",label:"Titre",type:"text"},{id:"views",label:"Vues",type:"number"},{id:"publishedAt",label:"Date de publication",type:"date"},{id:"featured",label:"\xc0 la une",type:"boolean"}]},N7=[{id:"1",title:"Le budget 2027 d\xe9voil\xe9 \xe0 l'Assembl\xe9e",status:"published",category:"politique",subcategory:"national",tags:["budget","\xe9lections"],views:4300,publishedAt:"2026-09-02",featured:!0},{id:"2",title:"Sommet r\xe9gional sur le climat \xe0 Libreville",status:"published",category:"politique",subcategory:"international",tags:["climat","diplomatie"],views:2100,publishedAt:"2026-08-20",featured:!1},{id:"3",title:"Les Panth\xe8res qualifi\xe9es pour la CAN",status:"published",category:"sport",subcategory:"football",tags:["football"],views:9800,publishedAt:"2026-09-10",featured:!0},{id:"4",title:"R\xe9forme du syst\xe8me \xe9ducatif : ce qui change",status:"draft",category:"politique",subcategory:"institutions",tags:["\xe9ducation"],views:120,publishedAt:"2026-09-15",featured:!1},{id:"5",title:"Les march\xe9s locaux r\xe9sistent \xe0 l'inflation",status:"published",category:"economie",subcategory:"marches",tags:["budget"],views:1560,publishedAt:"2026-07-30",featured:!1},{id:"6",title:"Festival de musique urbaine \xe0 Port-Gentil",status:"published",category:"culture",subcategory:"musique",tags:[],views:870,publishedAt:"2026-09-05",featured:!1},{id:"7",title:"Nouvelle campagne de sensibilisation lanc\xe9e",status:"published",category:"politique",subcategory:"national",tags:["sant\xe9"],views:3400,publishedAt:"2026-06-18",featured:!1},{id:"8",title:"Championnat national de basketball : bilan",status:"archived",category:"sport",subcategory:"basketball",tags:[],views:640,publishedAt:"2026-05-02",featured:!1}];function Re(e,t){switch(t){case"status":return e.status;case"category":return e.category;case"subcategory":return e.subcategory;case"tags":return e.tags;case"title":return e.title;case"views":return e.views;case"publishedAt":return e.publishedAt;case"featured":return e.featured;default:return}}var Rt={contains:"icontains",not_contains:"icontains",equals:"iexact",starts_with:"istartswith",is_empty:"isnull",is_not_empty:"isnull",eq:"exact",neq:"exact",gt:"gt",gte:"gte",lt:"lt",lte:"lte",on:"exact",before:"lt",after:"gt",is:"exact",is_not:"exact",is_any_of:"in"};function Rr(){var e=N_(g.useState([]),2),t=e[0],r=N2(N9,t,e[1]),n=r.fields,a=r.onChange,i=g.useMemo(function(){return N7.filter(function(e){return N6(e,t,N9,Re)})},[t]),o=g.useMemo(function(){return function(e){var t=new URLSearchParams,r=!0,n=!1,a=void 0;try{for(var i,o=e[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s,l,u=i.value;if(N5(u.operator,u.values)){if("between"===u.operator){var c=N_(u.values,2),d=c[0],f=c[1];d&&t.append("".concat(u.field,"__gte"),d),f&&t.append("".concat(u.field,"__lte"),f);continue}if("is_empty"===u.operator){t.append("".concat(u.field,"__isnull"),"true");continue}if("is_not_empty"===u.operator){t.append("".concat(u.field,"__isnull"),"false");continue}var p=null!=(s=Rt[u.operator])?s:"exact",h="is_any_of"===u.operator?u.values.join(","):null!=(l=u.values[0])?l:"";t.append("".concat(u.field,"__").concat(p),h)}}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}return t.toString()}(t)},[t]);return(0,v.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,v.jsx)(NG,{fields:n,value:t,onChange:a,"aria-label":"Filtrer les articles"}),(0,v.jsxs)("ul",{className:"flex flex-col gap-2",children:[i.map(function(e){return(0,v.jsxs)("li",{className:"rounded-md border border-[var(--fb-border)] px-3 py-2 text-[13px] text-[var(--fb-fg)]",children:[(0,v.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,v.jsx)("span",{className:"font-medium",children:e.title}),e.featured&&(0,v.jsx)("span",{className:"text-[var(--fb-fg-muted)]",children:"★ \xe0 la une"})]}),(0,v.jsxs)("div",{className:"mt-0.5 text-[12px] text-[var(--fb-fg-muted)]",children:[e.category," / ",e.subcategory," \xb7 ",e.views," vues \xb7 ",new Date(e.publishedAt).toLocaleDateString()]})]},e.id)}),0===i.length&&(0,v.jsx)("li",{className:"rounded-md border border-dashed border-[var(--fb-border)] px-3 py-4 text-center text-[13px] text-[var(--fb-fg-muted)]",children:"Aucun article ne correspond \xe0 ces filtres."})]}),(0,v.jsxs)("details",{className:"text-[12px] text-[var(--fb-fg-muted)]",children:[(0,v.jsx)("summary",{className:"cursor-pointer select-none",children:"Voir l'\xe9tat brut (\xe0 des fins p\xe9dagogiques)"}),(0,v.jsx)("p",{className:"mt-2",children:"\xc9tat `filters` produit par <FilterBar> :"}),(0,v.jsx)("pre",{className:"mt-1 overflow-x-auto rounded-md bg-[var(--fb-bg-chip)] p-2",children:JSON.stringify(t,null,2)}),(0,v.jsx)("p",{className:"mt-2",children:"Query string \xe9quivalente (convention django-filter) :"}),(0,v.jsxs)("pre",{className:"mt-1 overflow-x-auto rounded-md bg-[var(--fb-bg-chip)] p-2",children:["?",o||"(aucun filtre actif)"]})]})]})}var Rn=(0,ya.A)("Image",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]]),Ra=(0,ya.A)("Video",[["path",{d:"m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",key:"ftymec"}],["rect",{x:"2",y:"6",width:"14",height:"12",rx:"2",key:"158x01"}]]),Ri=(0,ya.A)("Music",[["path",{d:"M9 18V5l12-2v13",key:"1jmyc2"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["circle",{cx:"18",cy:"16",r:"3",key:"1hluhg"}]]),Ro=(0,ya.A)("Archive",[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]]),Rs=(0,ya.A)("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),Rl=(0,ya.A)("Grid3x3",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}],["path",{d:"M3 15h18",key:"5xshup"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"M15 3v18",key:"14nvp0"}]]);function Ru(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Rc(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Ru(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Ru(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Rd(e){var t,r=e.currentCategory,n=e.onSelectCategory,a=e.sortOption,i=e.onSelectSort,o=e.viewMode,s=e.onToggleViewMode,l=e.typeFilter,u=e.onSelectTypeFilter,c=Rc((0,g.useState)(!1),2),d=c[0],f=c[1],p=Rc((0,g.useState)(!1),2),h=p[0],m=p[1],y=[{id:"all",label:"Tout",icon:(0,v.jsx)(OF,{className:"w-3.5 h-3.5"})},{id:"documents",label:"Documents",icon:(0,v.jsx)(OQ,{className:"w-3.5 h-3.5"})},{id:"images",label:"Images",icon:(0,v.jsx)(Rn,{className:"w-3.5 h-3.5"})},{id:"videos",label:"Vid\xe9os",icon:(0,v.jsx)(Ra,{className:"w-3.5 h-3.5"})},{id:"music",label:"Musique",icon:(0,v.jsx)(Ri,{className:"w-3.5 h-3.5"})},{id:"archives",label:"Archives",icon:(0,v.jsx)(Ro,{className:"w-3.5 h-3.5"})}],b=[{id:"recent",label:"Plus r\xe9cents"},{id:"oldest",label:"Plus anciens"},{id:"name_asc",label:"Nom A → Z"},{id:"name_desc",label:"Nom Z → A"},{id:"items_count",label:"Nombre d’\xe9l\xe9ments"}],x=(null==(t=b.find(function(e){return e.id===a}))?void 0:t.label)||"Plus r\xe9cents";return(0,v.jsxs)("div",{className:"w-full flex flex-col sm:flex-row items-stretch sm:items-center justify-between gap-2.5 py-1 relative z-20",children:[(0,v.jsx)("div",{className:"flex items-center gap-1.5 overflow-x-auto pb-1 sm:pb-0 scrollbar-none w-full sm:w-auto",children:y.map(function(e){var t=r===e.id;return(0,v.jsxs)("button",{onClick:function(){return n(e.id)},className:"flex items-center gap-1 px-2.5 py-1 rounded-lg text-[10px] sm:text-xs font-semibold whitespace-nowrap transition-all duration-200 cursor-pointer ".concat(t?"bg-emerald-500/25 text-white border border-emerald-400/80 shadow-[0_0_12px_rgba(16,185,129,0.3)] drop-shadow-[0_1px_2px_rgba(0,0,0,0.8)]":"bg-transparent text-white/70 hover:text-white hover:bg-white/5 border border-white/10 hover:border-white/20 drop-shadow-[0_1px_1px_rgba(0,0,0,0.8)]"),children:[(0,v.jsx)("span",{className:t?"text-emerald-400":"text-white/60",children:e.icon}),(0,v.jsx)("span",{children:e.label})]},e.id)})}),(0,v.jsxs)("div",{className:"flex items-center justify-between sm:justify-end gap-1.5 sm:gap-2 w-full sm:w-auto mt-0.5 sm:mt-0",children:[(0,v.jsxs)("div",{className:"relative flex-1 sm:flex-none",children:[(0,v.jsxs)("button",{onClick:function(){f(!d),m(!1)},className:"w-full sm:w-auto flex items-center justify-between sm:justify-start gap-1 px-2.5 py-1 rounded-lg text-[10px] sm:text-xs font-semibold bg-black/30 hover:bg-white/5 border border-white/10 hover:border-white/20 text-white/90 transition-colors cursor-pointer",children:[(0,v.jsxs)("div",{className:"flex items-center gap-1",children:[(0,v.jsx)("span",{className:"text-white/40 hidden xs:inline",children:"Tri :"}),(0,v.jsx)("span",{className:"text-white font-semibold truncate max-w-[70px] sm:max-w-none",children:x})]}),(0,v.jsx)(Rs,{className:"w-3 h-3 text-white/50 shrink-0"})]}),d&&(0,v.jsx)("div",{className:"absolute right-0 mt-2 w-44 py-1 rounded-lg bg-[#040d10]/95 border border-white/15 shadow-[0_10px_30px_rgba(0,0,0,0.9)] backdrop-blur-xl z-50 animate-in fade-in zoom-in-95 duration-150",children:b.map(function(e){return(0,v.jsx)("button",{onClick:function(){i(e.id),f(!1)},className:"w-full text-left px-3 py-1.5 text-[10px] sm:text-xs transition-colors cursor-pointer ".concat(a===e.id?"bg-emerald-500/20 text-emerald-300 font-bold":"text-white/75 hover:bg-white/[0.08] hover:text-white"),children:e.label},e.id)})})]}),(0,v.jsxs)("div",{className:"relative flex-1 sm:flex-none",children:[(0,v.jsxs)("button",{onClick:function(){m(!h),f(!1)},className:"w-full sm:w-auto flex items-center justify-between sm:justify-start gap-1 px-2.5 py-1 rounded-lg text-[10px] sm:text-xs font-semibold bg-black/30 hover:bg-white/5 border border-white/10 hover:border-white/20 text-white/90 transition-colors cursor-pointer",children:[(0,v.jsxs)("div",{className:"flex items-center gap-1",children:[(0,v.jsx)("span",{className:"text-white/40 hidden xs:inline",children:"Type :"}),(0,v.jsx)("span",{className:"text-white font-semibold truncate max-w-[60px] sm:max-w-none",children:l})]}),(0,v.jsx)(Rs,{className:"w-3 h-3 text-white/50 shrink-0"})]}),h&&(0,v.jsx)("div",{className:"absolute right-0 mt-2 w-36 py-1 rounded-lg bg-[#040d10]/95 border border-white/15 shadow-[0_10px_30px_rgba(0,0,0,0.9)] backdrop-blur-xl z-50 animate-in fade-in zoom-in-95 duration-150",children:["Tous","Dossiers","Documents","Images","Vid\xe9os","Archives"].map(function(e){return(0,v.jsx)("button",{onClick:function(){u(e),m(!1)},className:"w-full text-left px-3 py-1.5 text-[10px] sm:text-xs transition-colors cursor-pointer ".concat(l===e?"bg-emerald-500/20 text-emerald-300 font-bold":"text-white/75 hover:bg-white/[0.08] hover:text-white"),children:e},e)})})]}),(0,v.jsxs)("div",{className:"flex items-center p-0.5 rounded-lg bg-black/20 border border-white/10 shrink-0",children:[(0,v.jsx)("button",{onClick:function(){return s("grid")},className:"p-1 rounded-md transition-all cursor-pointer ".concat("grid"===o?"bg-emerald-500/20 text-emerald-400":"text-white/40 hover:text-white/70"),title:"Vue Grille",children:(0,v.jsx)(Rl,{className:"w-3.5 h-3.5"})}),(0,v.jsx)("button",{onClick:function(){return s("list")},className:"p-1 rounded-md transition-all cursor-pointer ".concat("list"===o?"bg-emerald-500/20 text-emerald-400":"text-white/40 hover:text-white/70"),title:"Vue Liste",children:(0,v.jsx)(C3,{className:"w-3.5 h-3.5"})})]})]})]})}},8969(e,t,r){"use strict";r.d(t,{cn:()=>ey});var n=r(7064);let a=(e=new Map,t=null,r)=>({nextPart:e,validators:t,classGroupId:r}),i=[],o=(e,t,r)=>{if(0==e.length-t)return r.classGroupId;let n=e[t],a=r.nextPart.get(n);if(a){let r=o(e,t+1,a);if(r)return r}let i=r.validators;if(null===i)return;let s=0===t?e.join("-"):e.slice(t).join("-"),l=i.length;for(let e=0;e<l;e++){let t=i[e];if(t.validator(s))return t.classGroupId}},s=(e,t)=>{let r=a();for(let n in e)l(e[n],r,n,t);return r},l=(e,t,r,n)=>{let a=e.length;for(let i=0;i<a;i++)u(e[i],t,r,n)},u=(e,t,r,n)=>{"string"==typeof e?c(e,t,r):"function"==typeof e?d(e,t,r,n):f(e,t,r,n)},c=(e,t,r)=>{(""===e?t:p(t,e)).classGroupId=r},d=(e,t,r,n)=>{h(e)?l(e(n),t,r,n):(null===t.validators&&(t.validators=[]),t.validators.push({classGroupId:r,validator:e}))},f=(e,t,r,n)=>{let a=Object.entries(e),i=a.length;for(let e=0;e<i;e++){let[i,o]=a[e];l(o,p(t,i),r,n)}},p=(e,t)=>{let r=e,n=t.split("-"),i=n.length;for(let e=0;e<i;e++){let t=n[e],i=r.nextPart.get(t);i||(i=a(),r.nextPart.set(t,i)),r=i}return r},h=e=>"isThemeGetter"in e&&!0===e.isThemeGetter,m=[],y=(e,t,r,n,a)=>({modifiers:e,hasImportantModifier:t,baseClassName:r,maybePostfixModifierPosition:n,isExternal:a}),v=/\s+/,g=e=>{let t;if("string"==typeof e)return e;let r="";for(let n=0;n<e.length;n++)e[n]&&(t=g(e[n]))&&(r&&(r+=" "),r+=t);return r},b=[],x=e=>{let t=t=>t[e]||b;return t.isThemeGetter=!0,t.themeKey=e,t},w=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,S=/^\((?:(\w[\w-]*):)?(.+)\)$/i,j=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,O=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,k=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,E=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix|color|light-dark)\(.+\)$/,P=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,A=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,D=e=>j.test(e),C=e=>!!e&&!Number.isNaN(Number(e)),T=e=>!!e&&Number.isInteger(Number(e)),N=e=>e.endsWith("%")&&C(e.slice(0,-1)),R=e=>O.test(e),M=()=>!0,I=e=>k.test(e)&&!E.test(e),L=()=>!1,F=e=>P.test(e),B=e=>A.test(e),V=e=>!$(e)&&!Z(e),z=e=>e.startsWith("@container")&&("/"===e[10]&&void 0!==e[11]||"s"===e[11]&&void 0!==e[16]&&e.startsWith("-size/",10)||"n"===e[11]&&void 0!==e[18]&&e.startsWith("-normal/",10)),W=e=>ei(e,eu,L),$=e=>w.test(e),U=e=>ei(e,ec,I),H=e=>ei(e,ed,C),G=e=>ei(e,ep,M),K=e=>ei(e,ef,L),q=e=>ei(e,es,L),Y=e=>ei(e,el,B),X=e=>ei(e,eh,F),Z=e=>S.test(e),Q=e=>eo(e,ec),J=e=>eo(e,ef),ee=e=>eo(e,es),et=e=>eo(e,eu),er=e=>eo(e,el),en=e=>eo(e,eh,!0),ea=e=>eo(e,ep,!0),ei=(e,t,r)=>{let n=w.exec(e);return!!n&&(n[1]?t(n[1]):r(n[2]))},eo=(e,t,r=!1)=>{let n=S.exec(e);return!!n&&(n[1]?t(n[1]):r)},es=e=>"position"===e||"percentage"===e,el=e=>"image"===e||"url"===e,eu=e=>"length"===e||"size"===e||"bg-size"===e,ec=e=>"length"===e,ed=e=>"number"===e,ef=e=>"family-name"===e,ep=e=>"number"===e||"weight"===e,eh=e=>"shadow"===e,em=((e,...t)=>{let r,n,a,l,u=e=>{let t=n(e);if(t)return t;let i=((e,t)=>{let{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:a,sortModifiers:i,postfixLookupClassGroupIds:o}=t,s=[],l=e.trim().split(v),u="";for(let e=l.length-1;e>=0;e-=1){let t,c=l[e],{isExternal:d,modifiers:f,hasImportantModifier:p,baseClassName:h,maybePostfixModifierPosition:m}=r(c);if(d){u=c+(u.length>0?" "+u:u);continue}let y=!!m;if(y){let e=(t=n(h.substring(0,m)))&&o[t]?n(h):void 0;e&&e!==t&&(t=e,y=!1)}else t=n(h);if(!t){if(!y||!(t=n(h))){u=c+(u.length>0?" "+u:u);continue}y=!1}let v=0===f.length?"":1===f.length?f[0]:i(f).join(":"),g=p?v+"!":v,b=g+t;if(s.indexOf(b)>-1)continue;s.push(b);let x=a(t,y);for(let e=0;e<x.length;++e){let t=x[e];s.push(g+t)}u=c+(u.length>0?" "+u:u)}return u})(e,r);return a(e,i),i};return l=c=>{var d;let f;return n=(r={cache:(e=>{if(e<1)return{get:()=>void 0,set:()=>{}};let t=0,r=Object.create(null),n=Object.create(null),a=(a,i)=>{r[a]=i,++t>e&&(t=0,n=r,r=Object.create(null))};return{get(e){let t=r[e];return void 0!==t?t:void 0!==(t=n[e])?(a(e,t),t):void 0},set(e,t){e in r?r[e]=t:a(e,t)}}})((d=t.reduce((e,t)=>t(e),e())).cacheSize),parseClassName:(e=>{let{prefix:t,experimentalParseClassName:r}=e,n=e=>{let t,r=[],n=0,a=0,i=0,o=e.length;for(let s=0;s<o;s++){let o=e[s];if(0===n&&0===a){if(":"===o){r.push(e.slice(i,s)),i=s+1;continue}if("/"===o){t=s;continue}}"["===o?n++:"]"===o?n--:"("===o?a++:")"===o&&a--}let s=0===r.length?e:e.slice(i),l=s,u=!1;return s.endsWith("!")?(l=s.slice(0,-1),u=!0):s.startsWith("!")&&(l=s.slice(1),u=!0),y(r,u,l,t&&t>i?t-i:void 0)};if(t){let e=t+":",r=n;n=t=>t.startsWith(e)?r(t.slice(e.length)):y(m,!1,t,void 0,!0)}if(r){let e=n;n=t=>r({className:t,parseClassName:e})}return n})(d),sortModifiers:(f=new Map,d.orderSensitiveModifiers.forEach((e,t)=>{f.set(e,1e6+t)}),e=>{let t=[],r=[];for(let n=0;n<e.length;n++){let a=e[n],i="["===a[0],o=f.has(a);i||o?(r.length>0&&(r.sort(),t.push(...r),r=[]),t.push(a)):r.push(a)}return r.length>0&&(r.sort(),t.push(...r)),t}),postfixLookupClassGroupIds:(e=>{let t=Object.create(null),r=e.postfixLookupClassGroups;if(r)for(let e=0;e<r.length;e++)t[r[e]]=!0;return t})(d),...(e=>{let t=(e=>{let{theme:t,classGroups:r}=e;return s(r,t)})(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:e=>{if(e.startsWith("[")&&e.endsWith("]")){var r;let t,n,a;return -1===(r=e).slice(1,-1).indexOf(":")?void 0:(n=(t=r.slice(1,-1)).indexOf(":"),(a=t.slice(0,n))?"arbitrary.."+a:void 0)}let n=e.split("-"),a=+(""===n[0]&&n.length>1);return o(n,a,t)},getConflictingClassGroupIds:(e,t)=>{if(t){let t=n[e],a=r[e];if(t){if(a){let e=Array(a.length+t.length);for(let t=0;t<a.length;t++)e[t]=a[t];for(let r=0;r<t.length;r++)e[a.length+r]=t[r];return e}return t}return a||i}return r[e]||i}}})(d)}).cache.get,a=r.cache.set,l=u,u(c)},(...e)=>l(((...e)=>{let t,r,n=0,a="";for(;n<e.length;)(t=e[n++])&&(r=g(t))&&(a&&(a+=" "),a+=r);return a})(...e))})(()=>{let e=x("color"),t=x("font"),r=x("text"),n=x("font-weight"),a=x("tracking"),i=x("leading"),o=x("breakpoint"),s=x("container"),l=x("spacing"),u=x("radius"),c=x("shadow"),d=x("inset-shadow"),f=x("text-shadow"),p=x("drop-shadow"),h=x("blur"),m=x("perspective"),y=x("aspect"),v=x("ease"),g=x("animate"),b=()=>["auto","avoid","all","avoid-page","page","left","right","column"],w=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],S=()=>[...w(),Z,$],j=()=>["auto","hidden","clip","visible","scroll"],O=()=>["auto","contain","none"],k=()=>[Z,$,l],E=()=>[D,"full","auto",...k()],P=()=>[T,"none","subgrid",Z,$],A=()=>["auto",{span:["full",T,Z,$]},T,Z,$],I=()=>[T,"auto",Z,$],L=()=>["auto","min","max","fr",Z,$],F=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],B=()=>["start","end","center","stretch","center-safe","end-safe"],ei=()=>["auto",...k()],eo=()=>[D,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...k()],es=()=>[s,D,"screen","full","dvw","lvw","svw","min","max","fit",...k()],el=()=>[D,"screen","full","lh","dvh","lvh","svh","min","max","fit",...k()],eu=()=>[e,Z,$],ec=()=>[...w(),ee,q,{position:[Z,$]}],ed=()=>["no-repeat",{repeat:["","x","y","space","round"]}],ef=()=>["auto","cover","contain",et,W,{size:[Z,$]}],ep=()=>[N,Q,U],eh=()=>["","none","full",u,Z,$],em=()=>["",C,Q,U],ey=()=>["solid","dashed","dotted","double"],ev=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],eg=()=>[C,N,ee,q],eb=()=>["","none",h,Z,$],ex=()=>["none",C,Z,$],ew=()=>["none",C,Z,$],eS=()=>[C,Z,$],ej=()=>[D,"full",...k()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[R],breakpoint:[R],color:[M],container:[R],"drop-shadow":[R],ease:["in","out","in-out"],font:[V],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[R],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[R],shadow:[R],spacing:["px",C],text:[R],"text-shadow":[R],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",D,$,Z,y]}],container:["container"],"container-type":[{"@container":["","normal","size",Z,$]}],"container-named":[z],columns:[{columns:[C,"auto",$,Z,s]}],"break-after":[{"break-after":b()}],"break-before":[{"break-before":b()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:S()}],overflow:[{overflow:j()}],"overflow-x":[{"overflow-x":j()}],"overflow-y":[{"overflow-y":j()}],overscroll:[{overscroll:O()}],"overscroll-x":[{"overscroll-x":O()}],"overscroll-y":[{"overscroll-y":O()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:E()}],"inset-x":[{"inset-x":E()}],"inset-y":[{"inset-y":E()}],start:[{"inset-s":E(),start:E()}],end:[{"inset-e":E(),end:E()}],"inset-bs":[{"inset-bs":E()}],"inset-be":[{"inset-be":E()}],top:[{top:E()}],right:[{right:E()}],bottom:[{bottom:E()}],left:[{left:E()}],visibility:["visible","invisible","collapse"],z:[{z:[T,"auto",Z,$]}],basis:[{basis:[D,"full","auto",s,...k()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[C,D,"auto","initial","none",$]}],grow:[{grow:["",C,Z,$]}],shrink:[{shrink:["",C,Z,$]}],order:[{order:[T,"first","last","none",Z,$]}],"grid-cols":[{"grid-cols":P()}],"col-start-end":[{col:A()}],"col-start":[{"col-start":I()}],"col-end":[{"col-end":I()}],"grid-rows":[{"grid-rows":P()}],"row-start-end":[{row:A()}],"row-start":[{"row-start":I()}],"row-end":[{"row-end":I()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":L()}],"auto-rows":[{"auto-rows":L()}],gap:[{gap:k()}],"gap-x":[{"gap-x":k()}],"gap-y":[{"gap-y":k()}],"justify-content":[{justify:[...F(),"normal"]}],"justify-items":[{"justify-items":[...B(),"normal"]}],"justify-self":[{"justify-self":["auto",...B()]}],"align-content":[{content:["normal",...F()]}],"align-items":[{items:[...B(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...B(),{baseline:["","last"]}]}],"place-content":[{"place-content":F()}],"place-items":[{"place-items":[...B(),"baseline"]}],"place-self":[{"place-self":["auto",...B()]}],p:[{p:k()}],px:[{px:k()}],py:[{py:k()}],ps:[{ps:k()}],pe:[{pe:k()}],pbs:[{pbs:k()}],pbe:[{pbe:k()}],pt:[{pt:k()}],pr:[{pr:k()}],pb:[{pb:k()}],pl:[{pl:k()}],m:[{m:ei()}],mx:[{mx:ei()}],my:[{my:ei()}],ms:[{ms:ei()}],me:[{me:ei()}],mbs:[{mbs:ei()}],mbe:[{mbe:ei()}],mt:[{mt:ei()}],mr:[{mr:ei()}],mb:[{mb:ei()}],ml:[{ml:ei()}],"space-x":[{"space-x":k()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":k()}],"space-y-reverse":["space-y-reverse"],size:[{size:eo()}],"inline-size":[{inline:["auto",...es()]}],"min-inline-size":[{"min-inline":["auto",...es()]}],"max-inline-size":[{"max-inline":["none",...es()]}],"block-size":[{block:["auto",...el()]}],"min-block-size":[{"min-block":["auto",...el()]}],"max-block-size":[{"max-block":["none",...el()]}],w:[{w:[s,"screen",...eo()]}],"min-w":[{"min-w":[s,"screen","none",...eo()]}],"max-w":[{"max-w":[s,"screen","none","prose",{screen:[o]},...eo()]}],h:[{h:["screen","lh",...eo()]}],"min-h":[{"min-h":["screen","lh","none",...eo()]}],"max-h":[{"max-h":["screen","lh","none",...eo()]}],"font-size":[{text:["base",r,Q,U]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[n,ea,G]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",N,$]}],"font-family":[{font:[J,K,t]}],"font-features":[{"font-features":[$]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[a,Z,$]}],"line-clamp":[{"line-clamp":[C,"none",Z,H]}],leading:[{leading:["none",i,...k()]}],"list-image":[{"list-image":["none",Z,$]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",Z,$]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:eu()}],"text-color":[{text:eu()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ey(),"wavy"]}],"text-decoration-thickness":[{decoration:[C,"from-font","auto",Z,U]}],"text-decoration-color":[{decoration:eu()}],"underline-offset":[{"underline-offset":[C,"auto",Z,$]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:k()}],"tab-size":[{tab:[T,Z,$]}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Z,$]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Z,$]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:ec()}],"bg-repeat":[{bg:ed()}],"bg-size":[{bg:ef()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},T,Z,$],radial:["",Z,$],conic:["",T,Z,$]},er,Y]}],"bg-color":[{bg:eu()}],"gradient-from-pos":[{from:ep()}],"gradient-via-pos":[{via:ep()}],"gradient-to-pos":[{to:ep()}],"gradient-from":[{from:eu()}],"gradient-via":[{via:eu()}],"gradient-to":[{to:eu()}],rounded:[{rounded:eh()}],"rounded-s":[{"rounded-s":eh()}],"rounded-e":[{"rounded-e":eh()}],"rounded-t":[{"rounded-t":eh()}],"rounded-r":[{"rounded-r":eh()}],"rounded-b":[{"rounded-b":eh()}],"rounded-l":[{"rounded-l":eh()}],"rounded-ss":[{"rounded-ss":eh()}],"rounded-se":[{"rounded-se":eh()}],"rounded-ee":[{"rounded-ee":eh()}],"rounded-es":[{"rounded-es":eh()}],"rounded-tl":[{"rounded-tl":eh()}],"rounded-tr":[{"rounded-tr":eh()}],"rounded-br":[{"rounded-br":eh()}],"rounded-bl":[{"rounded-bl":eh()}],"border-w":[{border:em()}],"border-w-x":[{"border-x":em()}],"border-w-y":[{"border-y":em()}],"border-w-s":[{"border-s":em()}],"border-w-e":[{"border-e":em()}],"border-w-bs":[{"border-bs":em()}],"border-w-be":[{"border-be":em()}],"border-w-t":[{"border-t":em()}],"border-w-r":[{"border-r":em()}],"border-w-b":[{"border-b":em()}],"border-w-l":[{"border-l":em()}],"divide-x":[{"divide-x":em()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":em()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ey(),"hidden","none"]}],"divide-style":[{divide:[...ey(),"hidden","none"]}],"border-color":[{border:eu()}],"border-color-x":[{"border-x":eu()}],"border-color-y":[{"border-y":eu()}],"border-color-s":[{"border-s":eu()}],"border-color-e":[{"border-e":eu()}],"border-color-bs":[{"border-bs":eu()}],"border-color-be":[{"border-be":eu()}],"border-color-t":[{"border-t":eu()}],"border-color-r":[{"border-r":eu()}],"border-color-b":[{"border-b":eu()}],"border-color-l":[{"border-l":eu()}],"divide-color":[{divide:eu()}],"outline-style":[{outline:[...ey(),"none","hidden"]}],"outline-offset":[{"outline-offset":[C,Z,$]}],"outline-w":[{outline:["",C,Q,U]}],"outline-color":[{outline:eu()}],shadow:[{shadow:["","inner","none",c,en,X]}],"shadow-color":[{shadow:eu()}],"inset-shadow":[{"inset-shadow":["none",d,en,X]}],"inset-shadow-color":[{"inset-shadow":eu()}],"ring-w":[{ring:em()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:eu()}],"ring-offset-w":[{"ring-offset":[C,U]}],"ring-offset-color":[{"ring-offset":eu()}],"inset-ring-w":[{"inset-ring":em()}],"inset-ring-color":[{"inset-ring":eu()}],"text-shadow":[{"text-shadow":["none",f,en,X]}],"text-shadow-color":[{"text-shadow":eu()}],opacity:[{opacity:[C,Z,$]}],"mix-blend":[{"mix-blend":[...ev(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":ev()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[C]}],"mask-image-linear-from-pos":[{"mask-linear-from":eg()}],"mask-image-linear-to-pos":[{"mask-linear-to":eg()}],"mask-image-linear-from-color":[{"mask-linear-from":eu()}],"mask-image-linear-to-color":[{"mask-linear-to":eu()}],"mask-image-t-from-pos":[{"mask-t-from":eg()}],"mask-image-t-to-pos":[{"mask-t-to":eg()}],"mask-image-t-from-color":[{"mask-t-from":eu()}],"mask-image-t-to-color":[{"mask-t-to":eu()}],"mask-image-r-from-pos":[{"mask-r-from":eg()}],"mask-image-r-to-pos":[{"mask-r-to":eg()}],"mask-image-r-from-color":[{"mask-r-from":eu()}],"mask-image-r-to-color":[{"mask-r-to":eu()}],"mask-image-b-from-pos":[{"mask-b-from":eg()}],"mask-image-b-to-pos":[{"mask-b-to":eg()}],"mask-image-b-from-color":[{"mask-b-from":eu()}],"mask-image-b-to-color":[{"mask-b-to":eu()}],"mask-image-l-from-pos":[{"mask-l-from":eg()}],"mask-image-l-to-pos":[{"mask-l-to":eg()}],"mask-image-l-from-color":[{"mask-l-from":eu()}],"mask-image-l-to-color":[{"mask-l-to":eu()}],"mask-image-x-from-pos":[{"mask-x-from":eg()}],"mask-image-x-to-pos":[{"mask-x-to":eg()}],"mask-image-x-from-color":[{"mask-x-from":eu()}],"mask-image-x-to-color":[{"mask-x-to":eu()}],"mask-image-y-from-pos":[{"mask-y-from":eg()}],"mask-image-y-to-pos":[{"mask-y-to":eg()}],"mask-image-y-from-color":[{"mask-y-from":eu()}],"mask-image-y-to-color":[{"mask-y-to":eu()}],"mask-image-radial":[{"mask-radial":[Z,$]}],"mask-image-radial-from-pos":[{"mask-radial-from":eg()}],"mask-image-radial-to-pos":[{"mask-radial-to":eg()}],"mask-image-radial-from-color":[{"mask-radial-from":eu()}],"mask-image-radial-to-color":[{"mask-radial-to":eu()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":w()}],"mask-image-conic-pos":[{"mask-conic":[C]}],"mask-image-conic-from-pos":[{"mask-conic-from":eg()}],"mask-image-conic-to-pos":[{"mask-conic-to":eg()}],"mask-image-conic-from-color":[{"mask-conic-from":eu()}],"mask-image-conic-to-color":[{"mask-conic-to":eu()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:ec()}],"mask-repeat":[{mask:ed()}],"mask-size":[{mask:ef()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",Z,$]}],filter:[{filter:["","none",Z,$]}],blur:[{blur:eb()}],brightness:[{brightness:[C,Z,$]}],contrast:[{contrast:[C,Z,$]}],"drop-shadow":[{"drop-shadow":["","none",p,en,X]}],"drop-shadow-color":[{"drop-shadow":eu()}],grayscale:[{grayscale:["",C,Z,$]}],"hue-rotate":[{"hue-rotate":[C,Z,$]}],invert:[{invert:["",C,Z,$]}],saturate:[{saturate:[C,Z,$]}],sepia:[{sepia:["",C,Z,$]}],"backdrop-filter":[{"backdrop-filter":["","none",Z,$]}],"backdrop-blur":[{"backdrop-blur":eb()}],"backdrop-brightness":[{"backdrop-brightness":[C,Z,$]}],"backdrop-contrast":[{"backdrop-contrast":[C,Z,$]}],"backdrop-grayscale":[{"backdrop-grayscale":["",C,Z,$]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[C,Z,$]}],"backdrop-invert":[{"backdrop-invert":["",C,Z,$]}],"backdrop-opacity":[{"backdrop-opacity":[C,Z,$]}],"backdrop-saturate":[{"backdrop-saturate":[C,Z,$]}],"backdrop-sepia":[{"backdrop-sepia":["",C,Z,$]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":k()}],"border-spacing-x":[{"border-spacing-x":k()}],"border-spacing-y":[{"border-spacing-y":k()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",Z,$]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[C,"initial",Z,$]}],ease:[{ease:["linear","initial",v,Z,$]}],delay:[{delay:[C,Z,$]}],animate:[{animate:["none",g,Z,$]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[m,Z,$]}],"perspective-origin":[{"perspective-origin":S()}],rotate:[{rotate:ex()}],"rotate-x":[{"rotate-x":ex()}],"rotate-y":[{"rotate-y":ex()}],"rotate-z":[{"rotate-z":ex()}],scale:[{scale:ew()}],"scale-x":[{"scale-x":ew()}],"scale-y":[{"scale-y":ew()}],"scale-z":[{"scale-z":ew()}],"scale-3d":["scale-3d"],skew:[{skew:eS()}],"skew-x":[{"skew-x":eS()}],"skew-y":[{"skew-y":eS()}],transform:[{transform:[Z,$,"","none","gpu","cpu"]}],"transform-origin":[{origin:S()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:ej()}],"translate-x":[{"translate-x":ej()}],"translate-y":[{"translate-y":ej()}],"translate-z":[{"translate-z":ej()}],"translate-none":["translate-none"],zoom:[{zoom:[T,Z,$]}],accent:[{accent:eu()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:eu()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Z,$]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scrollbar-thumb-color":[{"scrollbar-thumb":eu()}],"scrollbar-track-color":[{"scrollbar-track":eu()}],"scrollbar-gutter":[{"scrollbar-gutter":["auto","stable","both"]}],"scrollbar-w":[{scrollbar:["auto","thin","none"]}],"scroll-m":[{"scroll-m":k()}],"scroll-mx":[{"scroll-mx":k()}],"scroll-my":[{"scroll-my":k()}],"scroll-ms":[{"scroll-ms":k()}],"scroll-me":[{"scroll-me":k()}],"scroll-mbs":[{"scroll-mbs":k()}],"scroll-mbe":[{"scroll-mbe":k()}],"scroll-mt":[{"scroll-mt":k()}],"scroll-mr":[{"scroll-mr":k()}],"scroll-mb":[{"scroll-mb":k()}],"scroll-ml":[{"scroll-ml":k()}],"scroll-p":[{"scroll-p":k()}],"scroll-px":[{"scroll-px":k()}],"scroll-py":[{"scroll-py":k()}],"scroll-ps":[{"scroll-ps":k()}],"scroll-pe":[{"scroll-pe":k()}],"scroll-pbs":[{"scroll-pbs":k()}],"scroll-pbe":[{"scroll-pbe":k()}],"scroll-pt":[{"scroll-pt":k()}],"scroll-pr":[{"scroll-pr":k()}],"scroll-pb":[{"scroll-pb":k()}],"scroll-pl":[{"scroll-pl":k()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Z,$]}],fill:[{fill:["none",...eu()]}],"stroke-w":[{stroke:[C,Q,U,H]}],stroke:[{stroke:["none",...eu()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{"container-named":["container-type"],overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["start","end","right","left"],"inset-y":["inset-bs","inset-be","top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["ps","pe","pr","pl"],py:["pbs","pbe","pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["ms","me","mr","ml"],my:["mbs","mbe","mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-s","border-w-e","border-w-r","border-w-l"],"border-w-y":["border-w-bs","border-w-be","border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-s","border-color-e","border-color-r","border-color-l"],"border-color-y":["border-color-bs","border-color-be","border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-ms","scroll-me","scroll-mr","scroll-ml"],"scroll-my":["scroll-mbs","scroll-mbe","scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-ps","scroll-pe","scroll-pr","scroll-pl"],"scroll-py":["scroll-pbs","scroll-pbe","scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},postfixLookupClassGroups:["container-type"],orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}});function ey(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return em((0,n.$)(t))}},5572(e,t,r){"use strict";let n;r.d(t,{jJ:()=>ia,cw:()=>a4,FA:()=>nx,rr:()=>a0,lG:()=>aK,ul:()=>ii,jl:()=>a5,L3:()=>aJ,Wd:()=>nb,Ad:()=>ie,Ex:()=>nf,$n:()=>U,Es:()=>aQ,Cf:()=>aX,rQ:()=>a3,K0:()=>nc,ci:()=>io,tD:()=>is,Ou:()=>ng,c7:()=>aZ});var a,i,o,s,l,u,c,d,f=r(2883),p=r(8783),h=r(7064);let m=e=>"boolean"==typeof e?`${e}`:0===e?"0":e,y=h.$,v=(e,t)=>r=>{var n;if((null==t?void 0:t.variants)==null)return y(e,null==r?void 0:r.class,null==r?void 0:r.className);let{variants:a,defaultVariants:i}=t,o=Object.keys(a).map(e=>{let t=null==r?void 0:r[e],n=null==i?void 0:i[e];if(null===t)return null;let o=m(t)||m(n);return a[e][o]}),s=r&&Object.entries(r).reduce((e,t)=>{let[r,n]=t;return void 0===n||(e[r]=n),e},{});return y(e,o,null==t||null==(n=t.compoundVariants)?void 0:n.reduce((e,t)=>{let{class:r,className:n,...a}=t;return Object.entries(a).every(e=>{let[t,r]=e;return Array.isArray(r)?r.includes({...i,...s}[t]):({...i,...s})[t]===r})?[...e,r,n]:e},[]),null==r?void 0:r.class,null==r?void 0:r.className)};var g=r(8969),b=Object.defineProperty,x=(e,t)=>b(e,"name",{value:t,configurable:!0});function w(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function S(...e){return t=>{let r=!1,n=e.map(e=>{let n=w(e,t);return r||"function"!=typeof n||(r=!0),n});if(r)return()=>{for(let t=0;t<n.length;t++){let r=n[t];"function"==typeof r?r():w(e[t],null)}}}}function j(...e){return p.useCallback(S(...e),e)}x(w,"setRef"),x(S,"composeRefs"),x(j,"useComposedRefs");var O=Object.defineProperty,k=(e,t)=>O(e,"name",{value:t,configurable:!0});function E(e){let t=p.forwardRef((t,r)=>{let{children:n,...a}=t,i=null,o=!1,s=[];n=F(n),p.Children.forEach(n,e=>{if(R(e)){o=!0;let t="child"in e.props?e.props.child:e.props.children;for(;I(t)&&"function"==typeof W;)t=W(t._payload);i=C(e,t),s.push(i?.props?.children)}else s.push(e)}),i?i=p.cloneElement(i,void 0,s):!o&&1===p.Children.count(n)&&p.isValidElement(n)&&(i=n);let l=i?N(i):void 0,u=j(r,l);if(!i){if(n||0===n)throw Error(o?z(e):V(e));return n}let c=T(a,i.props??{});return i.type!==p.Fragment&&(c.ref=r?u:l),p.cloneElement(i,c)});return t.displayName=`${e}.Slot`,t}k(E,"createSlot");var P=E("Slot"),A=Symbol.for("radix.slottable");function D(e){let t=k(e=>"child"in e?e.children(e.child):e.children,"Slottable");return t.displayName=`${e}.Slottable`,t.__radixId=A,t}k(D,"createSlottable");var C=k((e,t)=>"child"in e.props?p.isValidElement(t)?p.cloneElement(t,void 0,e.props.children(t.props.children)):null:p.isValidElement(t)?t:null,"getSlottableElementFromSlottable");function T(e,t){let r={...t};for(let n in t){let a=e[n],i=t[n];/^on[A-Z]/.test(n)?a&&i?r[n]=(...e)=>{let t=i(...e);return a(...e),t}:a&&(r[n]=a):"style"===n?r[n]={...a,...i}:"className"===n?r[n]=[a,i].filter(Boolean).join(" "):"aria-describedby"===n&&(r[n]=B(i,a))}return{...e,...r}}function N(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(r=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}function R(e){return p.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===A}k(T,"mergeProps"),k(N,"getElementRef"),k(R,"isSlottable");var M=Symbol.for("react.lazy");function I(e){return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===M&&"_payload"in e&&L(e._payload)}function L(e){return"object"==typeof e&&null!==e&&"then"in e}function F(e){let t=e;for(;I(t)&&"function"==typeof W;)t=W(t._payload);return t}function B(...e){let t=new Set;for(let r of e)if("string"==typeof r)for(let e of String(r).trim().split(/\s+/))e&&t.add(e);return t.size>0?Array.from(t).join(" "):void 0}k(I,"isLazyComponent"),k(L,"isPromiseLike"),k(F,"useUnwrappedLazy"),k(B,"concatAriaDescribedby");var V=k(e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,"createSlotError"),z=k(e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,"createSlottableError"),W=p[" use ".trim().toString()],$=v("inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",xs:"h-6 gap-1 rounded-md px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3",sm:"h-8 gap-1.5 rounded-md px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9","icon-xs":"size-6 rounded-md [&_svg:not([class*='size-'])]:size-3","icon-sm":"size-8","icon-lg":"size-10"}},defaultVariants:{variant:"default",size:"default"}});function U(e){var t=e.className,r=e.variant,n=void 0===r?"default":r,a=e.size,i=void 0===a?"default":a,o=e.asChild,s=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className","variant","size","asChild"]);return(0,f.jsx)(void 0!==o&&o?P:"button",function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-slot":"button","data-variant":n,"data-size":i,className:(0,g.cn)($({variant:n,size:i,className:t}))},s))}var H=Object.defineProperty,G=(e,t)=>H(e,"name",{value:t,configurable:!0}),K=!!("u">typeof window&&window.document&&window.document.createElement);function q(e,t,{checkForDefaultPrevented:r=!0}={}){return G(function(n){if(e?.(n),!1===r||!n||!n.defaultPrevented)return t?.(n)},"handleEvent")}function Y(e){if(!K)throw Error("Cannot access document outside of the DOM");return e?.ownerDocument??document}function X(e){return"IFRAME"===e.tagName}G(q,"composeEventHandlers"),G(function(e){if(!K)throw Error("Cannot access window outside of the DOM");return e?.ownerDocument?.defaultView??window},"getOwnerWindow"),G(Y,"getOwnerDocument"),G(function e(t,r=!1){let{activeElement:n}=Y(t);if(!n?.nodeName)return null;if(X(n)&&n.contentDocument)return e(n.contentDocument.body,r);if(r){let e=n.getAttribute("aria-activedescendant");if(e){let t=Y(n).getElementById(e);if(t)return t}}return n},"getActiveElement"),G(X,"isFrame");var Z=Object.defineProperty,Q=(e,t)=>Z(e,"name",{value:t,configurable:!0});function J(e,t=[]){let r=[];function n(t,n){let a=p.createContext(n);a.displayName=t+"Context";let i=r.length;r=[...r,n];let o=Q(t=>{let{scope:r,children:n,...o}=t,s=r?.[e]?.[i]||a,l=p.useMemo(()=>o,Object.values(o));return(0,f.jsx)(s.Provider,{value:l,children:n})},"Provider");function s(r,o,l={}){let{optional:u=!1}=l,c=o?.[e]?.[i]||a,d=p.useContext(c);if(d)return d;if(void 0!==n)return n;if(!u)throw Error(`\`${r}\` must be used within \`${t}\``)}return o.displayName=t+"Provider",Q(s,"useContext"),[o,s]}Q(n,"createContext");let a=Q(()=>{let t=r.map(e=>p.createContext(e));return Q(function(r){let n=r?.[e]||t;return p.useMemo(()=>({[`__scope${e}`]:{...r,[e]:n}}),[r,n])},"useScope")},"createScope");return a.scopeName=e,[n,ee(a,...t)]}function ee(...e){let t=e[0];if(1===e.length)return t;let r=Q(()=>{let r=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return Q(function(e){let n=r.reduce((t,{useScope:r,scopeName:n})=>{let a=r(e)[`__scope${n}`];return{...t,...a}},{});return p.useMemo(()=>({[`__scope${t.scopeName}`]:n}),[n])},"useComposedScopes")},"createScope");return r.scopeName=t.scopeName,r}Q(function(e,t){let r=p.createContext(t);r.displayName=e+"Context";let n=Q(e=>{let{children:t,...n}=e,a=p.useMemo(()=>n,Object.values(n));return(0,f.jsx)(r.Provider,{value:a,children:t})},"Provider");function a(n,i={}){let{optional:o=!1}=i,s=p.useContext(r);if(s)return s;if(void 0!==t)return t;if(!o)throw Error(`\`${n}\` must be used within \`${e}\``)}return n.displayName=e+"Provider",Q(a,"useContext"),[n,a]},"createContext"),Q(J,"createContextScope"),Q(ee,"composeContextScopes");var et=r(803),er=Object.defineProperty,en=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,t)=>{let r=E(`Primitive.${t}`),n=p.forwardRef((e,n)=>{let{asChild:a,...i}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,f.jsx)(a?r:t,{...i,ref:n})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function ea(e,t){e&&et.flushSync(()=>e.dispatchEvent(t))}er(ea,"name",{value:"dispatchDiscreteCustomEvent",configurable:!0});var ei=globalThis?.document?p.useLayoutEffect:()=>{},eo=Object.defineProperty,es=p[" useInsertionEffect ".trim().toString()];function el(e){let t=p.useRef(e);return"function"==typeof es?es(()=>{t.current=e}):ei(()=>{t.current=e}),p.useMemo(()=>(...e)=>t.current?.(...e),[])}eo(el,"name",{value:"useCallbackRef",configurable:!0});var eu=Object.defineProperty,ec=(e,t)=>eu(e,"name",{value:t,configurable:!0}),ed="dismissableLayer.update",ef=p.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),ep=p.forwardRef(ec(function(e,t){let{disableOutsidePointerEvents:r=!1,deferPointerDownOutside:n=!1,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:s,onDismiss:l,...u}=e,d=p.useContext(ef),[h,m]=p.useState(null),y=h?.ownerDocument??globalThis?.document,[,v]=p.useState({}),g=j(t,m),b=Array.from(d.layers),[x]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),w=x?b.indexOf(x):-1,S=h?b.indexOf(h):-1,O=d.layersWithOutsidePointerEventsDisabled.size>0,k=S>=w,E=p.useRef(!1),P=ey(e=>{i?.(e),s?.(e),e.defaultPrevented||l?.()},{ownerDocument:y,deferPointerDownOutside:n,isDeferredPointerDownOutsideRef:E,dismissableSurfaces:d.dismissableSurfaces,shouldHandlePointerDownOutside:p.useCallback(e=>{if(!(e instanceof Node))return!1;let t=[...d.branches].some(t=>t.contains(e));return k&&!t},[d.branches,k])}),A=ev(e=>{if(n&&E.current)return;let t=e.target;![...d.branches].some(e=>e.contains(t))&&(o?.(e),s?.(e),e.defaultPrevented||l?.())},y),D=!!h&&S===b.length-1,C=el(e=>{"Escape"===e.key&&(a?.(e),!e.defaultPrevented&&l&&(e.preventDefault(),l()))});return p.useEffect(()=>{if(D)return y.addEventListener("keydown",C,{capture:!0}),()=>y.removeEventListener("keydown",C,{capture:!0})},[y,D,C]),p.useEffect(()=>{if(h)return r&&(0===d.layersWithOutsidePointerEventsDisabled.size&&(c=y.body.style.pointerEvents,y.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(h)),d.layers.add(h),eg(),()=>{r&&(d.layersWithOutsidePointerEventsDisabled.delete(h),0===d.layersWithOutsidePointerEventsDisabled.size&&(y.body.style.pointerEvents=c))}},[h,y,r,d]),p.useEffect(()=>()=>{h&&(d.layers.delete(h),d.layersWithOutsidePointerEventsDisabled.delete(h),eg())},[h,d]),p.useEffect(()=>{let e=ec(()=>v({}),"handleUpdate");return document.addEventListener(ed,e),()=>document.removeEventListener(ed,e)},[]),(0,f.jsx)(en.div,{...u,ref:g,style:{pointerEvents:O?k?"auto":"none":void 0,...e.style},onFocusCapture:q(e.onFocusCapture,A.onFocusCapture),onBlurCapture:q(e.onBlurCapture,A.onBlurCapture),onPointerDownCapture:q(e.onPointerDownCapture,P.onPointerDownCapture)})},"DismissableLayer"));function eh(){let e=p.useContext(ef),[t,r]=p.useState(null);return p.useEffect(()=>{if(t)return e.dismissableSurfaces.add(t),()=>{e.dismissableSurfaces.delete(t)}},[t,e.dismissableSurfaces]),r}ec(eh,"useDismissableLayerSurface");var em=ec(()=>!0,"IS_TRUE");function ey(e,t){let{ownerDocument:r=globalThis?.document,deferPointerDownOutside:n=!1,isDeferredPointerDownOutsideRef:a,dismissableSurfaces:i,shouldHandlePointerDownOutside:o=em}=t,s=el(e),l=p.useRef(!1),u=p.useRef(!1),c=p.useRef(new Map),d=p.useRef(()=>{});return p.useEffect(()=>{function e(){u.current=!1,a.current=!1,c.current.clear()}function t(){return Array.from(c.current.values()).some(Boolean)}function f(e){if(!u.current)return;let t=e.target;t instanceof Node&&[...i].some(e=>e.contains(t))||c.current.set(e.type,!0),"click"===e.type&&window.setTimeout(()=>{u.current&&d.current()},0)}function p(e){u.current&&c.current.set(e.type,!1)}ec(e,"resetOutsideInteraction"),ec(t,"isOutsideInteractionIntercepted"),ec(f,"handleInteractionCapture"),ec(p,"handleInteractionBubble");let h=ec(i=>{if(i.target&&!l.current){let f=function(){r.removeEventListener("click",d.current);let n=t();e(),n||eb("dismissableLayer.pointerDownOutside",s,p,{discrete:!0})};if(ec(f,"handleAndDispatchPointerDownOutsideEvent"),!o(i.target)){r.removeEventListener("click",d.current),e(),l.current=!1;return}let p={originalEvent:i};u.current=!0,a.current=n&&0===i.button,c.current.clear(),n&&0===i.button?(r.removeEventListener("click",d.current),d.current=f,r.addEventListener("click",d.current,{once:!0})):f()}else r.removeEventListener("click",d.current),e();l.current=!1},"handlePointerDown"),m=["pointerup","mousedown","mouseup","touchstart","touchend","click"];for(let e of m)r.addEventListener(e,f,!0),r.addEventListener(e,p);let y=window.setTimeout(()=>{r.addEventListener("pointerdown",h)},0);return()=>{for(let e of(window.clearTimeout(y),r.removeEventListener("pointerdown",h),r.removeEventListener("click",d.current),m))r.removeEventListener(e,f,!0),r.removeEventListener(e,p)}},[r,s,n,a,i,o]),{onPointerDownCapture:ec(()=>l.current=!0,"onPointerDownCapture")}}function ev(e,t=globalThis?.document){let r=el(e),n=p.useRef(!1);return p.useEffect(()=>{let e=ec(e=>{e.target&&!n.current&&eb("dismissableLayer.focusOutside",r,{originalEvent:e},{discrete:!1})},"handleFocus");return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)},[t,r]),{onFocusCapture:ec(()=>n.current=!0,"onFocusCapture"),onBlurCapture:ec(()=>n.current=!1,"onBlurCapture")}}function eg(){let e=new CustomEvent(ed);document.dispatchEvent(e)}function eb(e,t,r,{discrete:n}){let a=r.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&a.addEventListener(e,t,{once:!0}),n?ea(a,i):a.dispatchEvent(i)}ec(ey,"usePointerDownOutside"),ec(ev,"useFocusOutside"),ec(eg,"dispatchUpdate"),ec(eb,"handleAndDispatchCustomEvent");var ex=Object.defineProperty,ew=(e,t)=>ex(e,"name",{value:t,configurable:!0}),eS="focusScope.autoFocusOnMount",ej="focusScope.autoFocusOnUnmount",eO={bubbles:!1,cancelable:!0},ek=p.forwardRef(ew(function(e,t){let{loop:r=!1,trapped:n=!1,branches:a,onMountAutoFocus:i,onUnmountAutoFocus:o,...s}=e,[l,u]=p.useState(null),c=el(i),d=el(o),h=p.useRef(null),m=j(t,u),y=p.useRef(a);p.useEffect(()=>{y.current=a});let v=p.useCallback(e=>!!e&&(!!l?.contains(e)||!!y.current?.some(t=>t.contains(e))),[l]),g=p.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;p.useEffect(()=>{if(n){let e=function(e){if(g.paused||!l)return;let t=e.target;v(t)?h.current=t:e_(h.current,{select:!0})},t=function(e){if(g.paused||!l)return;let t=e.relatedTarget;null!==t&&(v(t)||e_(h.current,{select:!0}))},r=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&e_(l)};ew(e,"handleFocusIn"),ew(t,"handleFocusOut"),ew(r,"handleMutations"),document.addEventListener("focusin",e),document.addEventListener("focusout",t);let n=new MutationObserver(r);return l&&n.observe(l,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),n.disconnect()}}},[n,l,g.paused,v]),p.useEffect(()=>{if(l){eL.add(g);let e=document.activeElement;if(!l.contains(e)){let t=new CustomEvent(eS,eO);l.addEventListener(eS,c),l.dispatchEvent(t),t.defaultPrevented||(eC(eV(eN(l)),{select:!0}),document.activeElement===e&&e_(l))}return()=>{l.removeEventListener(eS,c);let t=l.ownerDocument,r=CustomEvent;setTimeout(()=>{let n=new r(ej,eO);l.addEventListener(ej,d),l.dispatchEvent(n),n.defaultPrevented||e_(e??t.body,{select:!0}),l.removeEventListener(ej,d),eL.remove(g)},0)}}},[l,c,d,g]);let b=p.useCallback(e=>{if(!r&&!n||g.paused)return;let t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,a=document.activeElement;if(t&&a){let t=e.currentTarget,[n,i]=eT(t);n&&i?e.shiftKey||a!==i?e.shiftKey&&a===n&&(e.preventDefault(),r&&e_(i,{select:!0})):(e.preventDefault(),r&&e_(n,{select:!0})):a===t&&e.preventDefault()}},[r,n,g.paused]);return(0,f.jsx)(en.div,{tabIndex:-1,...s,ref:m,onKeyDown:b})},"FocusScope")),eE=p.createContext(null);function eP({registry:e,children:t}){return e?(0,f.jsx)(eE.Provider,{value:e,children:t}):t}function eA(){let[e,t]=p.useState([]);return{nodes:e,registry:p.useMemo(()=>({add:ew(e=>t(t=>t.includes(e)?t:[...t,e]),"add"),remove:ew(e=>t(t=>t.filter(t=>t!==e)),"remove")}),[])}}function eD(e){let t=p.useContext(eE);p.useEffect(()=>{if(e&&t)return t.add(e),()=>t.remove(e)},[e,t])}function eC(e,{select:t=!1}={}){let r=document.activeElement;for(let n of e)if(e_(n,{select:t}),document.activeElement!==r)return}function eT(e){let t=eN(e);return[eR(t,e),eR(t.reverse(),e)]}function eN(e){let t=[],r=e.ownerDocument.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:ew(e=>{let t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP},"acceptNode")});for(;r.nextNode();)t.push(r.currentNode);return t}function eR(e,t){let r="function"==typeof t.checkVisibility&&t.checkVisibility({checkVisibilityCSS:!0});for(let n of e)if(!(r?!n.checkVisibility({checkVisibilityCSS:!0}):eM(n,{upTo:t})))return n}function eM(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e&&(void 0===t||e!==t);){if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function eI(e){return"INPUT"===e.tagName&&"function"==typeof e.select}function e_(e,{select:t=!1}={}){if(e&&e.focus){let r=(e.ownerDocument??document).activeElement;e.focus({preventScroll:!0}),e!==r&&eI(e)&&t&&e.select()}}ew(eP,"FocusScopeBranchProvider"),ew(eA,"useFocusScopeBranchRegistry"),ew(eD,"useFocusScopeBranch"),ew(eC,"focusFirst"),ew(eT,"getTabbableEdges"),ew(eN,"getTabbableCandidates"),ew(eR,"findVisible"),ew(eM,"isHidden"),ew(eI,"isSelectableInput"),ew(e_,"focus");var eL=eF();function eF(){let e=[];return{add(t){let r=e[0];t!==r&&r?.pause(),(e=eB(e,t)).unshift(t)},remove(t){e=eB(e,t),e[0]?.resume()}}}function eB(e,t){let r=[...e],n=r.indexOf(t);return -1!==n&&r.splice(n,1),r}function eV(e){return e.filter(e=>"A"!==e.tagName)}ew(eF,"createFocusScopesStack"),ew(eB,"arrayRemove"),ew(eV,"removeLinks");var ez=Object.defineProperty,eW=p[" useId ".trim().toString()]||(()=>void 0),e$=0;function eU(e){let[t,r]=p.useState(eW());return ei(()=>{e||r(e=>e??String(e$++))},[e]),e||(t?`radix-${t}`:"")}ez(eU,"name",{value:"useId",configurable:!0});let eH=["top","right","bottom","left"],eG=Math.min,eK=Math.max,eq=Math.round,eY=Math.floor,eX=e=>({x:e,y:e}),eZ={left:"right",right:"left",bottom:"top",top:"bottom"};function eQ(e,t){return"function"==typeof e?e(t):e}function eJ(e){return e.split("-")[0]}function e0(e){return e.split("-")[1]}function e1(e){return"x"===e?"y":"x"}function e2(e){return"y"===e?"height":"width"}function e3(e){let t=e[0];return"t"===t||"b"===t?"y":"x"}function e4(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}let e5=["left","right"],e6=["right","left"],e8=["top","bottom"],e9=["bottom","top"];function e7(e){let t=eJ(e);return eZ[t]+e.slice(t.length)}function te(e){var t,r,n,a;return"number"!=typeof e?{top:null!=(t=e.top)?t:0,right:null!=(r=e.right)?r:0,bottom:null!=(n=e.bottom)?n:0,left:null!=(a=e.left)?a:0}:{top:e,right:e,bottom:e,left:e}}function tt(e){let{x:t,y:r,width:n,height:a}=e;return{width:n,height:a,top:r,left:t,right:t+n,bottom:r+a,x:t,y:r}}function tr(e,t,r){let n,{reference:a,floating:i}=e,o=e3(t),s=e1(e3(t)),l=e2(s),u=eJ(t),c=a.x+a.width/2-i.width/2,d=a.y+a.height/2-i.height/2,f=a[l]/2-i[l]/2;switch(u){case"top":n={x:c,y:a.y-i.height};break;case"bottom":n={x:c,y:a.y+a.height};break;case"right":n={x:a.x+a.width,y:d};break;case"left":n={x:a.x-i.width,y:d};break;default:n={x:a.x,y:a.y}}let p=e0(t);return p&&(n[s]+=f*("end"===p?1:-1)*(r&&"y"===o?-1:1)),n}async function tn(e,t){var r;void 0===t&&(t={});let{x:n,y:a,platform:i,rects:o,elements:s,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=eQ(t,e),h=te(p),m=s[f?"floating"===d?"reference":"floating":d],y=tt(await i.getClippingRect({element:null==(r=await (null==i.isElement?void 0:i.isElement(m)))||r?m:m.contextElement||await (null==i.getDocumentElement?void 0:i.getDocumentElement(s.floating)),boundary:u,rootBoundary:c,strategy:l})),v="floating"===d?{x:n,y:a,width:o.floating.width,height:o.floating.height}:o.reference,g=await (null==i.getOffsetParent?void 0:i.getOffsetParent(s.floating)),b=await (null==i.isElement?void 0:i.isElement(g))&&await (null==i.getScale?void 0:i.getScale(g))||{x:1,y:1},x=tt(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:v,offsetParent:g,strategy:l}):v);return{top:(y.top-x.top+h.top)/b.y,bottom:(x.bottom-y.bottom+h.bottom)/b.y,left:(y.left-x.left+h.left)/b.x,right:(x.right-y.right+h.right)/b.x}}let ta=async(e,t,r)=>{let{placement:n="bottom",strategy:a="absolute",middleware:i=[],platform:o}=r,s=o.detectOverflow?o:{...o,detectOverflow:tn},l=await (null==o.isRTL?void 0:o.isRTL(t)),u=await o.getElementRects({reference:e,floating:t,strategy:a}),{x:c,y:d}=tr(u,n,l),f=n,p=0,h={};for(let r=0;r<i.length;r++){let m=i[r];if(!m)continue;let{name:y,fn:v}=m,{x:g,y:b,data:x,reset:w}=await v({x:c,y:d,initialPlacement:n,placement:f,strategy:a,middlewareData:h,rects:u,platform:s,elements:{reference:e,floating:t}});c=null!=g?g:c,d=null!=b?b:d,h[y]={...h[y],...x},w&&p<50&&(p++,"object"==typeof w&&(w.placement&&(f=w.placement),w.rects&&(u=!0===w.rects?await o.getElementRects({reference:e,floating:t,strategy:a}):w.rects),{x:c,y:d}=tr(u,f,l)),r=-1)}return{x:c,y:d,placement:f,strategy:a,middlewareData:h}};function ti(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function to(e){return eH.some(t=>e[t]>=0)}let ts=new Set(["left","top"]);async function tl(e,t){let{placement:r,platform:n,elements:a}=e,i=await (null==n.isRTL?void 0:n.isRTL(a.floating)),o=eJ(r),s=e0(r),l="y"===e3(r),u=ts.has(o)?-1:1,c=i&&l?-1:1,d=eQ(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:h}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof h&&(p="end"===s?-1*h:h),l?{x:p*c,y:f*u}:{x:f*u,y:p*c}}function tu(){return"u">typeof window}function tc(e){return tp(e)?(e.nodeName||"").toLowerCase():"#document"}function td(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function tf(e){var t;return null==(t=(tp(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function tp(e){return!!tu()&&(e instanceof Node||e instanceof td(e).Node)}function th(e){return!!tu()&&(e instanceof Element||e instanceof td(e).Element)}function tm(e){return!!tu()&&(e instanceof HTMLElement||e instanceof td(e).HTMLElement)}function ty(e){return!(!tu()||"u"<typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof td(e).ShadowRoot)}function tv(e){let{overflow:t,overflowX:r,overflowY:n,display:a}=tk(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&"inline"!==a&&"contents"!==a}function tg(e){try{if(e.matches(":popover-open"))return!0}catch(e){}try{return e.matches(":modal")}catch(e){return!1}}let tb=/transform|translate|scale|rotate|perspective|filter/,tx=/paint|layout|strict|content/,tw=e=>!!e&&"none"!==e;function tS(e){let t=th(e)?tk(e):e;return tw(t.transform)||tw(t.translate)||tw(t.scale)||tw(t.rotate)||tw(t.perspective)||!tj()&&(tw(t.backdropFilter)||tw(t.filter))||tb.test(t.willChange||"")||tx.test(t.contain||"")}function tj(){return null==n&&(n="u">typeof CSS&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),n}function tO(e){return/^(html|body|#document)$/.test(tc(e))}function tk(e){return td(e).getComputedStyle(e)}function tE(e){return th(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function tP(e){if("html"===tc(e))return e;let t=e.assignedSlot||e.parentNode||ty(e)&&e.host||tf(e);return ty(t)?t.host:t}function tA(e,t,r){var n;void 0===t&&(t=[]),void 0===r&&(r=!0);let a=function e(t){let r=tP(t);return tO(r)?(t.ownerDocument||t).body:tm(r)&&tv(r)?r:e(r)}(e),i=a===(null==(n=e.ownerDocument)?void 0:n.body),o=td(a);if(!i)return t.concat(a,tA(a,[],r));{let e=tD(o);return t.concat(o,o.visualViewport||[],tv(a)?a:[],e&&r?tA(e):[])}}function tD(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function tC(e){let t=tk(e),r=parseFloat(t.width)||0,n=parseFloat(t.height)||0,a=tm(e),i=a?e.offsetWidth:r,o=a?e.offsetHeight:n,s=eq(r)!==i||eq(n)!==o;return s&&(r=i,n=o),{width:r,height:n,$:s}}function tT(e){return th(e)?e:e.contextElement}function tN(e){let t=tT(e);if(!tm(t))return eX(1);let r=t.getBoundingClientRect(),{width:n,height:a,$:i}=tC(t),o=(i?eq(r.width):r.width)/n,s=(i?eq(r.height):r.height)/a;return o&&Number.isFinite(o)||(o=1),s&&Number.isFinite(s)||(s=1),{x:o,y:s}}let tR=eX(0);function tM(e){let t=td(e);return tj()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:tR}function tI(e,t,r,n){var a;void 0===t&&(t=!1),void 0===r&&(r=!1);let i=e.getBoundingClientRect(),o=tT(e),s=eX(1);t&&(n?th(n)&&(s=tN(n)):s=tN(e));let l=(void 0===(a=r)&&(a=!1),n&&a&&n===td(o))?tM(o):eX(0),u=(i.left+l.x)/s.x,c=(i.top+l.y)/s.y,d=i.width/s.x,f=i.height/s.y;if(o&&n){let e=td(o),t=th(n)?td(n):n,r=e,a=tD(r);for(;a&&t!==r;){let e=tN(a),t=a.getBoundingClientRect(),n=tk(a),i=t.left+(a.clientLeft+parseFloat(n.paddingLeft))*e.x,o=t.top+(a.clientTop+parseFloat(n.paddingTop))*e.y;u*=e.x,c*=e.y,d*=e.x,f*=e.y,u+=i,c+=o,a=tD(r=td(a))}}return tt({width:d,height:f,x:u,y:c})}function t_(e,t){let r=tE(e).scrollLeft;return t?t.left+r:tI(tf(e)).left+r}function tL(e,t){let r=e.getBoundingClientRect();return{x:r.left+t.scrollLeft-t_(e,r),y:r.top+t.scrollTop}}function tF(e,t,r){var n;let a;if("viewport"===t||"layoutViewport"===t)a=function(e,t,r){void 0===r&&(r="viewport");let n="layoutViewport"===r,a=td(e),i=tf(e),o=a.visualViewport,s=i.clientWidth,l=i.clientHeight,u=0,c=0;if(o){let e=!tj()||"fixed"===t;n?e||(u=-o.offsetLeft,c=-o.offsetTop):(s=o.width,l=o.height,e&&(u=o.offsetLeft,c=o.offsetTop))}if(0>=t_(i)){let e=i.ownerDocument,t=e.body,r=getComputedStyle(t),n="CSS1Compat"===e.compatMode&&parseFloat(r.marginLeft)+parseFloat(r.marginRight)||0,a=Math.abs(i.clientWidth-t.clientWidth-n),o="stable both-edges"===getComputedStyle(i).scrollbarGutter?a/2:a;o<=25&&(s-=o)}return{width:s,height:l,x:u,y:c}}(e,r,t);else if("document"===t){let t,r,i,o,s,l;t=tE(n=tf(e)),r=n.ownerDocument.body,i=eK(n.scrollWidth,n.clientWidth,r.scrollWidth,r.clientWidth),o=eK(n.scrollHeight,n.clientHeight,r.scrollHeight,r.clientHeight),s=-t.scrollLeft+t_(n),l=-t.scrollTop,"rtl"===tk(r).direction&&(s+=eK(n.clientWidth,r.clientWidth)-i),a={width:i,height:o,x:s,y:l}}else if(th(t)){let e,n,i,o,s,l;n=(e=tI(t,!0,"fixed"===r)).top+t.clientTop,i=e.left+t.clientLeft,o=tN(t),s=t.clientWidth*o.x,l=t.clientHeight*o.y,a={width:s,height:l,x:i*o.x,y:n*o.y}}else{let r=tM(e);a={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return tt(a)}function tB(e){return"static"===tk(e).position}function tV(e,t){if(!tm(e)||"fixed"===tk(e).position)return null;if(t)return t(e);let r=e.offsetParent;return tf(e)===r&&(r=r.ownerDocument.body),r}function tz(e,t){var r;let n=td(e);if(tg(e))return n;if(!tm(e)){let t=tP(e);for(;t&&!tO(t);){if(th(t)&&!tB(t))return t;t=tP(t)}return n}let a=tV(e,t);for(;a&&(r=a,/^(table|td|th)$/.test(tc(r)))&&tB(a);)a=tV(a,t);return a&&tO(a)&&tB(a)&&!tS(a)?n:a||function(e){let t=tP(e);for(;tm(t)&&!tO(t);){if(tS(t))return t;if(tg(t))break;t=tP(t)}return null}(e)||n}let tW=async function(e){let t=this.getOffsetParent||tz,r=this.getDimensions,n=await r(e.floating);return{reference:function(e,t,r){let n=tm(t),a=tf(t),i="fixed"===r,o=tI(e,!0,i,t),s={scrollLeft:0,scrollTop:0},l=eX(0);if((n||!i)&&(("body"!==tc(t)||tv(a))&&(s=tE(t)),n)){let e=tI(t,!0,i,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}!n&&a&&(l.x=t_(a));let u=!a||n||i?eX(0):tL(a,s);return{x:o.left+s.scrollLeft-l.x-u.x,y:o.top+s.scrollTop-l.y-u.y,width:o.width,height:o.height}}(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}},t$={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:r,offsetParent:n,strategy:a}=e,i="fixed"===a,o=tf(n),s=!!t&&tg(t.floating);if(n===o||s&&i)return r;let l={scrollLeft:0,scrollTop:0},u=eX(1),c=eX(0),d=tm(n);if((d||!i)&&(("body"!==tc(n)||tv(o))&&(l=tE(n)),d)){let e=tI(n);u=tN(n),c.x=e.x+n.clientLeft,c.y=e.y+n.clientTop}let f=!o||d||i?eX(0):tL(o,l);return{width:r.width*u.x,height:r.height*u.y,x:r.x*u.x-l.scrollLeft*u.x+c.x+f.x,y:r.y*u.y-l.scrollTop*u.y+c.y+f.y}},getDocumentElement:tf,getClippingRect:function(e){let{element:t,boundary:r,rootBoundary:n,strategy:a}=e,i=[..."clippingAncestors"===r?tg(t)?[]:function(e,t){let r=t.get(e);if(r)return r;let n=tA(e,[],!1).filter(e=>th(e)&&"body"!==tc(e)),a=null,i="fixed"===tk(e).position,o=i?tP(e):e;for(;th(o)&&!tO(o);){let e=tk(o),t=tS(o),r=a?a.position:i?"fixed":"";t||"fixed"!==r&&("absolute"!==r||"static"!==e.position)?a=e:n=n.filter(e=>e!==o),o=tP(o)}return t.set(e,n),n}(t,this._c):[].concat(r),n],o=tF(t,i[0],a),s=o.top,l=o.right,u=o.bottom,c=o.left;for(let e=1;e<i.length;e++){let r=tF(t,i[e],a);s=eK(r.top,s),l=eG(r.right,l),u=eG(r.bottom,u),c=eK(r.left,c)}return{width:l-c,height:u-s,x:c,y:s}},getOffsetParent:tz,getElementRects:tW,getClientRects:function(e){return e.getClientRects?Array.from(e.getClientRects()):[]},getDimensions:function(e){let{width:t,height:r}=tC(e);return{width:t,height:r}},getScale:tN,isElement:th,isRTL:function(e){return"rtl"===tk(e).direction}};function tU(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}let tH=e=>({name:"arrow",options:e,async fn(t){let{x:r,y:n,placement:a,rects:i,platform:o,elements:s,middlewareData:l}=t,{element:u,padding:c=0}=eQ(e,t)||{};if(null==u)return{};let d=te(c),f={x:r,y:n},p=e1(e3(a)),h=e2(p),m=await o.getDimensions(u),y="y"===p,v=y?"clientHeight":"clientWidth",g=i.reference[h]+i.reference[p]-f[p]-i.floating[h],b=f[p]-i.reference[p],x=await (null==o.getOffsetParent?void 0:o.getOffsetParent(u)),w=x?x[v]:0;w&&await (null==o.isElement?void 0:o.isElement(x))||(w=s.floating[v]||i.floating[h]);let S=w/2-m[h]/2-1,j=eG(d[y?"top":"left"],S),O=eG(d[y?"bottom":"right"],S),k=w-m[h]-O,E=w/2-m[h]/2+(g/2-b/2),P=eK(j,eG(E,k)),A=!l.arrow&&null!=e0(a)&&E!==P&&i.reference[h]/2-(E<j?j:O)-m[h]/2<0,D=A?E<j?E-j:E-k:0;return{[p]:f[p]+D,data:{[p]:P,centerOffset:E-P-D,...A&&{alignmentOffset:D}},reset:A}}});var tG="u">typeof document?p.useLayoutEffect:function(){};function tK(e,t){let r,n,a;if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if((r=e.length)!==t.length)return!1;for(n=r;0!=n--;)if(!tK(e[n],t[n]))return!1;return!0}if((r=(a=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(n=r;0!=n--;)if(!({}).hasOwnProperty.call(t,a[n]))return!1;for(n=r;0!=n--;){let r=a[n];if(("_owner"!==r||!e.$$typeof)&&!tK(e[r],t[r]))return!1}return!0}return e!=e&&t!=t}function tq(e){return"u"<typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function tY(e,t){let r=tq(e);return Math.round(t*r)/r}function tX(e){let t=p.useRef(e);return tG(()=>{t.current=e}),t}var tZ=Object.defineProperty,tQ=p.forwardRef(tZ(function(e,t){let{children:r,width:n=10,height:a=5,...i}=e;return(0,f.jsx)(en.svg,{...i,ref:t,width:n,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:(0,f.jsx)("polygon",{points:"0,0 30,0 15,10"})})},"name",{value:"Arrow",configurable:!0}));function tJ(e){let[t,r]=p.useState(void 0);return ei(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});let t=0,n=new ResizeObserver(n=>{if(!Array.isArray(n)||!n.length)return;let a=n[0];window.cancelAnimationFrame(t),t=window.requestAnimationFrame(()=>{let t,n;if("borderBoxSize"in a){let e=a.borderBoxSize,r=Array.isArray(e)?e[0]:e;t=r.inlineSize,n=r.blockSize}else t=e.offsetWidth,n=e.offsetHeight;r({width:t,height:n})})});return n.observe(e,{box:"border-box"}),()=>{window.cancelAnimationFrame(t),n.unobserve(e)}}r(void 0)},[e]),t}(0,Object.defineProperty)(tJ,"name",{value:"useSize",configurable:!0});var t0=Object.defineProperty,t1=(e,t)=>t0(e,"name",{value:t,configurable:!0}),t2="partial",t3="Popper",[t4,t5]=J(t3),[t6,t8]=t4(t3),t9=t1(e=>{let{__scopePopper:t,children:r}=e,[n,a]=p.useState(null),[i,o]=p.useState(void 0);return(0,f.jsx)(t6,{scope:t,anchor:n,onAnchorChange:a,placementState:i,setPlacementState:o,children:r})},"Popper"),t7=p.forwardRef(t1(function(e,t){let{__scopePopper:r,virtualRef:n,...a}=e,i=t8("PopperAnchor",r),o=p.useRef(null),s=i.onAnchorChange,l=j(t,p.useCallback(e=>{o.current=e,e&&s(e)},[s])),u=p.useRef(null);p.useEffect(()=>{if(!n)return;let e=u.current;u.current=n.current,e!==u.current&&s(u.current)});let c=i.placementState&&rl(i.placementState),d=c?.[0],h=c?.[1];return n?null:(0,f.jsx)(en.div,{"data-radix-popper-side":d,"data-radix-popper-align":h,...a,ref:l})},"PopperAnchor")),re="PopperContent",[rt,rr]=t4(re),rn=p.forwardRef(t1(function(e,t){var r,n,a,i,o,s,l,u,c,d,h,m,y,v,g,b,x,w,S,O,k;let E,P,A,D,C,T,{__scopePopper:N,side:R="bottom",sideOffset:M=0,align:I="center",alignOffset:L=0,arrowPadding:F=0,avoidCollisions:B=!0,collisionBoundary:V=[],collisionPadding:z=0,sticky:W=t2,hideWhenDetached:$=!1,updatePositionStrategy:U="optimized",onPlaced:H,...G}=e,K=t8(re,N),[q,Y]=p.useState(null),X=j(t,Y),[Z,Q]=p.useState(null),J=tJ(Z),ee=J?.width??0,er=J?.height??0,ea="number"==typeof z?z:{top:0,right:0,bottom:0,left:0,...z},eo=Array.isArray(V)?V:[V],es=eo.length>0,eu={padding:ea,boundary:eo.filter(ro),altBoundary:es},{refs:ec,floatingStyles:ed,placement:ef,isPositioned:ep,middlewareData:eh}=function(e){void 0===e&&(e={});let{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:a,elements:{reference:i,floating:o}={},transform:s=!0,whileElementsMounted:l,open:u}=e,[c,d]=p.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[f,h]=p.useState(n);tK(f,n)||h(n);let[m,y]=p.useState(null),[v,g]=p.useState(null),b=p.useCallback(e=>{e!==j.current&&(j.current=e,y(e))},[]),x=p.useCallback(e=>{e!==O.current&&(O.current=e,g(e))},[]),w=i||m,S=o||v,j=p.useRef(null),O=p.useRef(null),k=p.useRef(c),E=null!=l,P=tX(l),A=tX(a),D=tX(u),C=p.useCallback(()=>{var e,n;let a,i,o;if(!j.current||!O.current)return;let s={placement:t,strategy:r,middleware:f};A.current&&(s.platform=A.current),(e=j.current,n=O.current,a=new Map,i=null!=s?s:{},o={...t$,...i.platform,_c:a},ta(e,n,{...i,platform:o})).then(e=>{let t={...e,isPositioned:!1!==D.current};T.current&&!tK(k.current,t)&&(k.current=t,et.flushSync(()=>{d(t)}))})},[f,t,r,A,D]);tG(()=>{!1===u&&k.current.isPositioned&&(k.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[u]);let T=p.useRef(!1);tG(()=>(T.current=!0,()=>{T.current=!1}),[]),tG(()=>{if(w&&(j.current=w),S&&(O.current=S),w&&S){if(P.current)return P.current(w,S,C);C()}},[w,S,C,P,E]);let N=p.useMemo(()=>({reference:j,floating:O,setReference:b,setFloating:x}),[b,x]),R=p.useMemo(()=>({reference:w,floating:S}),[w,S]),M=p.useMemo(()=>{let e={position:r,left:0,top:0};if(!R.floating)return e;let t=tY(R.floating,c.x),n=tY(R.floating,c.y);return s?{...e,transform:"translate("+t+"px, "+n+"px)",...tq(R.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:t,top:n}},[r,s,R.floating,c.x,c.y]);return p.useMemo(()=>({...c,update:C,refs:N,elements:R,floatingStyles:M}),[c,C,N,R,M])}({strategy:"fixed",placement:R+("center"!==I?"-"+I:""),whileElementsMounted:t1((...e)=>(function(e,t,r,n){let a;void 0===n&&(n={});let{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:s="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:u=!1}=n,c=tT(e),d=i||o?[...c?tA(c):[],...t?tA(t):[]]:[];d.forEach(e=>{i&&e.addEventListener("scroll",r),o&&e.addEventListener("resize",r)});let f=c&&l?function(e,t,r){let n,a=null,i=tf(e);function o(){var e;clearTimeout(n),null==(e=a)||e.disconnect(),a=null}function s(r,l){void 0===r&&(r=!1),void 0===l&&(l=1),o();let u=e.getBoundingClientRect(),{left:c,top:d,width:f,height:p}=u;if(r||t(),!f||!p)return;let h={rootMargin:-eY(d)+"px "+-eY(i.clientWidth-(c+f))+"px "+-eY(i.clientHeight-(d+p))+"px "+-eY(c)+"px",threshold:eK(0,eG(1,l))||1},m=!0;function y(t){let r=t[0].intersectionRatio;if(!tU(u,e.getBoundingClientRect()))return s();if(r!==l){if(!m)return s();r?s(!1,r):n=setTimeout(()=>{s(!1,1e-7)},1e3)}m=!1}try{a=new IntersectionObserver(y,{...h,root:i.ownerDocument})}catch(e){a=new IntersectionObserver(y,h)}a.observe(e)}let l=td(e),u=()=>s(r);return l.addEventListener("resize",u),s(!0),()=>{l.removeEventListener("resize",u),o()}}(c,r,o):null,p=-1,h=null;s&&(h=new ResizeObserver(e=>{let[n]=e;n&&n.target===c&&h&&t&&(h.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var e;null==(e=h)||e.observe(t)})),r()}),c&&!u&&h.observe(c),t&&h.observe(t));let m=u?tI(e):null;return u&&function t(){let n=tI(e);m&&!tU(m,n)&&r(),m=n,a=requestAnimationFrame(t)}(),r(),()=>{var e;d.forEach(e=>{i&&e.removeEventListener("scroll",r),o&&e.removeEventListener("resize",r)}),null==f||f(),null==(e=h)||e.disconnect(),h=null,u&&cancelAnimationFrame(a)}})(...e,{animationFrame:"always"===U}),"whileElementsMounted"),elements:{reference:K.anchor},middleware:[{name:(E={name:"offset",options:a=r={mainAxis:M+er,alignmentAxis:L},async fn(e){var t,r;let{x:n,y:i,placement:o,middlewareData:s}=e,l=await tl(e,a);return o===(null==(t=s.offset)?void 0:t.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:n+l.x,y:i+l.y,data:{...l,placement:o}}}}).name,fn:E.fn,options:[r,n]},B&&{name:(P={name:"shift",options:c=l={mainAxis:!0,crossAxis:!1,...W===t2?{limiter:{fn:(void 0===(s=i)&&(s={}),{options:s,fn(e){var t,r,n,a;let{x:i,y:o,placement:l,rects:u,middlewareData:c}=e,{offset:d=0,mainAxis:f=!0,crossAxis:p=!0}=eQ(s,e),h={x:i,y:o},m=e3(l),y=e1(m),v=h[y],g=h[m],b=eQ(d,e),x="number"==typeof b?{mainAxis:b,crossAxis:0}:{mainAxis:null!=(t=b.mainAxis)?t:0,crossAxis:null!=(r=b.crossAxis)?r:0};if(f){let e="y"===y?"height":"width",t=u.reference[y]-u.floating[e]+x.mainAxis,r=u.reference[y]+u.reference[e]-x.mainAxis;v<t?v=t:v>r&&(v=r)}if(p){let e="y"===y?"width":"height",t=ts.has(eJ(l)),r=u.reference[m]-u.floating[e]+(t&&(null==(n=c.offset)?void 0:n[m])||0)+(t?0:x.crossAxis),i=u.reference[m]+u.reference[e]+(t?0:(null==(a=c.offset)?void 0:a[m])||0)-(t?x.crossAxis:0);g<r?g=r:g>i&&(g=i)}return{[y]:v,[m]:g}}}).fn,options:[i,o]}}:{},...eu},async fn(e){let{x:t,y:r,placement:n,platform:a}=e,{mainAxis:i=!0,crossAxis:o=!1,limiter:s={fn:e=>{let{x:t,y:r}=e;return{x:t,y:r}}},...l}=eQ(c,e),u={x:t,y:r},d=await a.detectOverflow(e,l),f=e3(n),p=e1(f),h=u[p],m=u[f],y=(e,t)=>eK(t+d["y"===e?"top":"left"],eG(t,t-d["y"===e?"bottom":"right"]));i&&(h=y(p,h)),o&&(m=y(f,m));let v=s.fn({...e,[p]:h,[f]:m});return{...v,data:{x:v.x-t,y:v.y-r,enabled:{[p]:i,[f]:o}}}}}).name,fn:P.fn,options:[l,u]},B&&{name:(A={name:"flip",options:m=d={...eu},async fn(e){var t,r,n,a,i,o,s,l;let u,c,d,{placement:f,middlewareData:p,rects:h,initialPlacement:y,platform:v,elements:g}=e,{mainAxis:b=!0,crossAxis:x=!0,fallbackPlacements:w,fallbackStrategy:S="bestFit",fallbackAxisSideDirection:j="none",flipAlignment:O=!0,...k}=eQ(m,e);if(null!=(t=p.arrow)&&t.alignmentOffset)return{};let E=eJ(f),P=e3(y),A=eJ(y)===y,D=await (null==v.isRTL?void 0:v.isRTL(g.floating)),C=w||(A||!O?[e7(y)]:(u=e7(y),[e4(y),u,e4(u)])),T="none"!==j;!w&&T&&C.push(...(c=e0(y),d=function(e,t,r){switch(e){case"top":case"bottom":if(r)return t?e6:e5;return t?e5:e6;case"left":case"right":return t?e8:e9;default:return[]}}(eJ(y),"start"===j,D),c&&(d=d.map(e=>e+"-"+c),O&&(d=d.concat(d.map(e4)))),d));let N=[y,...C],R=await v.detectOverflow(e,k),M=[],I=(null==(r=p.flip)?void 0:r.overflows)||[];if(b&&M.push(R[E]),x){let e,t,r,n,a=(o=f,s=h,void 0===(l=D)&&(l=!1),e=e0(o),r=e2(t=e1(e3(o))),n="x"===t?e===(l?"end":"start")?"right":"left":"start"===e?"bottom":"top",s.reference[r]>s.floating[r]&&(n=e7(n)),[n,e7(n)]);M.push(R[a[0]],R[a[1]])}if(I=[...I,{placement:f,overflows:M}],!M.every(e=>e<=0)){let e=((null==(n=p.flip)?void 0:n.index)||0)+1,t=N[e];if(t&&("alignment"!==x||P===e3(t)||I.every(e=>e3(e.placement)!==P||e.overflows[0]>0)))return{data:{index:e,overflows:I},reset:{placement:t}};let r=null==(a=I.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:a.placement;if(!r)switch(S){case"bestFit":{let e=null==(i=I.filter(e=>{if(T){let t=e3(e.placement);return t===P||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:i[0];e&&(r=e);break}case"initialPlacement":r=y}if(f!==r)return{reset:{placement:r}}}return{}}}).name,fn:A.fn,options:[d,h]},{name:(D={name:"size",options:g=y={...eu,apply:t1(({elements:e,rects:t,availableWidth:r,availableHeight:n})=>{let{width:a,height:i}=t.reference,o=e.floating.style;o.setProperty("--radix-popper-available-width",`${r}px`),o.setProperty("--radix-popper-available-height",`${n}px`),o.setProperty("--radix-popper-anchor-width",`${a}px`),o.setProperty("--radix-popper-anchor-height",`${i}px`)},"apply")},async fn(e){let t,r,{placement:n,rects:a,platform:i,elements:o}=e,{apply:s=()=>{},...l}=eQ(g,e),u=await i.detectOverflow(e,l),c=eJ(n),d=e0(n),f="y"===e3(n),{width:p,height:h}=a.floating;"top"===c||"bottom"===c?(t=c,r=d===(await (null==i.isRTL?void 0:i.isRTL(o.floating))?"start":"end")?"left":"right"):(r=c,t="end"===d?"top":"bottom");let m=h-u.top-u.bottom,y=p-u.left-u.right,v=eG(h-u[t],m),b=eG(p-u[r],y),x=e.middlewareData.shift,w=!x,S=v,j=b;null!=x&&x.enabled.x&&(j=y),null!=x&&x.enabled.y&&(S=m),w&&!d&&(f?j=p-2*eK(u.left,u.right):S=h-2*eK(u.top,u.bottom)),await s({...e,availableWidth:j,availableHeight:S});let O=await i.getDimensions(o.floating);return p!==O.width||h!==O.height?{reset:{rects:!0}}:{}}}).name,fn:D.fn,options:[y,v]},Z&&{name:(C={name:"arrow",options:w=b={element:Z,padding:F},fn(e){let{element:t,padding:r}="function"==typeof w?w(e):w;return t&&({}).hasOwnProperty.call(t,"current")?null!=t.current?tH({element:t.current,padding:r}).fn(e):{}:t?tH({element:t,padding:r}).fn(e):{}}}).name,fn:C.fn,options:[b,x]},rs({arrowWidth:ee,arrowHeight:er}),$&&{name:(T={name:"hide",options:k=S=es?{strategy:"referenceHidden",...eu}:{strategy:"referenceHidden",padding:eu.padding,altBoundary:eu.altBoundary},async fn(e){let{rects:t,platform:r}=e,{strategy:n="referenceHidden",...a}=eQ(k,e);switch(n){case"referenceHidden":{let n=ti(await r.detectOverflow(e,{...a,elementContext:"reference"}),t.reference);return{data:{referenceHiddenOffsets:n,referenceHidden:to(n)}}}case"escaped":{let n=ti(await r.detectOverflow(e,{...a,altBoundary:!0}),t.floating);return{data:{escapedOffsets:n,escaped:to(n)}}}default:return{}}}}).name,fn:T.fn,options:[S,O]}]}),em=K.setPlacementState;ei(()=>(em(ef),()=>{em(void 0)}),[ef,em]);let[ey,ev]=rl(ef),eg=el(H);ei(()=>{ep&&eg?.()},[ep,eg]);let eb=eh.arrow?.x,ex=eh.arrow?.y,ew=eh.arrow?.centerOffset!==0,[eS,ej]=p.useState();return ei(()=>{q&&ej(window.getComputedStyle(q).zIndex)},[q]),(0,f.jsx)("div",{ref:ec.setFloating,"data-radix-popper-content-wrapper":"",style:{...ed,transform:ep?ed.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:eS,"--radix-popper-transform-origin":[eh.transformOrigin?.x,eh.transformOrigin?.y].join(" "),...eh.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:(0,f.jsx)(rt,{scope:N,placedSide:ey,placedAlign:ev,onArrowChange:Q,arrowX:eb,arrowY:ex,shouldHideArrow:ew,children:(0,f.jsx)(en.div,{"data-side":ey,"data-align":ev,...G,ref:X,style:{...G.style,animation:ep?G.style?.animation:"none"}})})})},"PopperContent")),ra={top:"bottom",right:"left",bottom:"top",left:"right"},ri=p.forwardRef(t1(function(e,t){let{__scopePopper:r,...n}=e,a=rr("PopperArrow",r),i=ra[a.placedSide];return(0,f.jsx)("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:(0,f.jsx)(tQ,{...n,ref:t,style:{...n.style,display:"block"}})})},"PopperArrow"));function ro(e){return null!==e}t1(ro,"isNotNull");var rs=t1(e=>({name:"transformOrigin",options:e,fn(t){let{placement:r,rects:n,middlewareData:a}=t,i=a.arrow?.centerOffset!==0,o=i?0:e.arrowWidth,s=i?0:e.arrowHeight,[l,u]=rl(r),c={start:"0%",center:"50%",end:"100%"}[u],d=(a.arrow?.x??0)+o/2,f=(a.arrow?.y??0)+s/2,p="",h="";return"bottom"===l?(p=i?c:`${d}px`,h=`${-s}px`):"top"===l?(p=i?c:`${d}px`,h=`${n.floating.height+s}px`):"right"===l?(p=`${-s}px`,h=i?c:`${f}px`):"left"===l&&(p=`${n.floating.width+s}px`,h=i?c:`${f}px`),{data:{x:p,y:h}}}}),"transformOrigin");function rl(e){let[t,r="center"]=e.split("-");return[t,r]}t1(rl,"getSideAndAlignFromPlacement");var ru=Object.defineProperty,rc=p.forwardRef(ru(function(e,t){let{container:r,...n}=e,[a,i]=p.useState(!1);ei(()=>i(!0),[]);let o=r||a&&globalThis?.document?.body;return o?et.createPortal((0,f.jsx)(en.div,{...n,ref:t}),o):null},"name",{value:"Portal",configurable:!0})),rd=Object.defineProperty,rf=(e,t)=>rd(e,"name",{value:t,configurable:!0});function rp(e,t){return p.useReducer((e,r)=>t[e][r]??e,e)}rf(rp,"useStateMachine");var rh=rf(e=>{let{present:t,children:r}=e,n=rm(t),a="function"==typeof r?r({present:n.isPresent}):p.Children.only(r),i=rv(n.ref,rb(a));return"function"==typeof r||n.isPresent?p.cloneElement(a,{ref:i}):null},"Presence");function rm(e){let[t,r]=p.useState(),n=p.useRef(null),a=p.useRef(e),i=p.useRef("none"),o=p.useRef(void 0),[s,l]=rp(e?"mounted":"unmounted",{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return p.useEffect(()=>{"mounted"===s?(i.current=o.current??rg(n.current),o.current=void 0):i.current="none"},[s]),ei(()=>{let t=n.current,r=a.current;if(r!==e){let n=i.current,s=rg(t);e?(o.current=s,l("MOUNT")):"none"===s||t?.display==="none"?l("UNMOUNT"):r&&n!==s?l("ANIMATION_OUT"):l("UNMOUNT"),a.current=e}},[e,l]),ei(()=>{if(t){let e,r=t.ownerDocument.defaultView??window,o=rf(i=>{let o=rg(n.current).includes(CSS.escape(i.animationName));if(i.target===t&&o&&(l("ANIMATION_END"),!a.current)){let n=t.style.animationFillMode;t.style.animationFillMode="forwards",e=r.setTimeout(()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=n)})}},"handleAnimationEnd"),s=rf(e=>{e.target===t&&(i.current=rg(n.current))},"handleAnimationStart");return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",o),t.addEventListener("animationend",o),()=>{r.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",o),t.removeEventListener("animationend",o)}}l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:p.useCallback(e=>{if(e){let t=getComputedStyle(e);n.current=t,o.current=rg(t)}else n.current=null;r(e)},[])}}function ry(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function rv(...e){let t=p.useRef(e);return t.current=e,p.useCallback(e=>{let r=t.current,n=!1,a=r.map(t=>{let r=ry(t,e);return n||"function"!=typeof r||(n=!0),r});if(n)return()=>{for(let e=0;e<a.length;e++){let t=a[e];"function"==typeof t?t():ry(r[e],null)}}},[])}function rg(e){return e?.animationName||"none"}function rb(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(r=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}rf(rm,"usePresence"),rf(ry,"setRef"),rf(rv,"useStableComposedRefs"),rf(rg,"getAnimationName"),rf(rb,"getElementRef");var rx=Object.defineProperty,rw=p[" useEffectEvent ".trim().toString()],rS=p[" useInsertionEffect ".trim().toString()];function rj(e){if("function"==typeof rw)return rw(e);let t=p.useRef(()=>{throw Error("Cannot call an event handler while rendering.")});return"function"==typeof rS?rS(()=>{t.current=e}):ei(()=>{t.current=e}),p.useMemo(()=>(...e)=>t.current?.(...e),[])}rx(rj,"name",{value:"useEffectEvent",configurable:!0});var rO=Object.defineProperty,rk=(e,t)=>rO(e,"name",{value:t,configurable:!0}),rE=p[" useInsertionEffect ".trim().toString()]||ei;function rP({prop:e,defaultProp:t,onChange:r=rk(()=>{},"onChange"),caller:n}){let[a,i,o]=rA({defaultProp:t,onChange:r}),s=void 0!==e,l=s?e:a;return[l,p.useCallback(t=>{if(s){let r=rD(t)?t(e):t;r!==e&&o.current?.(r)}else i(t)},[s,e,i,o])]}function rA({defaultProp:e,onChange:t}){let[r,n]=p.useState(e),a=p.useRef(r),i=p.useRef(t);return rE(()=>{i.current=t},[t]),p.useEffect(()=>{a.current!==r&&(i.current?.(r),a.current=r)},[r,a]),[r,n,i]}function rD(e){return"function"==typeof e}rk(rP,"useControllableState"),rk(rA,"useUncontrolledState"),rk(rD,"isFunction");var rC=Symbol("RADIX:SYNC_STATE");rk(function(e,t,r,n){let{prop:a,defaultProp:i,onChange:o,caller:s}=t,l=void 0!==a,u=rj(o),c=[{...r,state:i}];n&&c.push(n);let[d,f]=p.useReducer((t,r)=>{if(r.type===rC)return{...t,state:r.state};let n=e(t,r);return l&&!Object.is(n.state,t.state)&&u(n.state),n},...c),h=d.state,m=p.useRef(h);p.useEffect(()=>{m.current!==h&&(m.current=h,l||u(h))},[h,m,l]);let y=p.useMemo(()=>void 0!==a?{...d,state:a}:d,[d,a]);return p.useEffect(()=>{l&&!Object.is(a,d.state)&&f({type:rC,state:a})},[a,d.state,l]),[y,f]},"useControllableStateReducer");var rT=Object.defineProperty,rN=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),rR=p.forwardRef(rT(function(e,t){return(0,f.jsx)(en.span,{...e,ref:t,style:{...rN,...e.style}})},"name",{value:"VisuallyHidden",configurable:!0})),rM=Object.defineProperty,rI=(e,t)=>rM(e,"name",{value:t,configurable:!0}),[r_,rL]=J("Tooltip",[t5]),rF=t5(),rB="tooltip.open",[rV,rz]=r_("TooltipProvider"),rW=rI(e=>{let{__scopeTooltip:t,delayDuration:r=700,skipDelayDuration:n=300,disableHoverableContent:a=!1,children:i}=e,o=p.useRef(!0),s=p.useRef(!1),l=p.useRef(0);return p.useEffect(()=>{let e=l.current;return()=>window.clearTimeout(e)},[]),(0,f.jsx)(rV,{scope:t,isOpenDelayedRef:o,delayDuration:r,onOpen:p.useCallback(()=>{n<=0||(window.clearTimeout(l.current),o.current=!1)},[n]),onClose:p.useCallback(()=>{n<=0||(window.clearTimeout(l.current),l.current=window.setTimeout(()=>o.current=!0,n))},[n]),isPointerInTransitRef:s,onPointerInTransitChange:p.useCallback(e=>{s.current=e},[]),disableHoverableContent:a,children:i})},"TooltipProvider"),r$="Tooltip",[rU,rH]=r_(r$),rG=rI(e=>{let{__scopeTooltip:t,children:r,open:n,defaultOpen:a,onOpenChange:i,disableHoverableContent:o,delayDuration:s}=e,l=rz(r$,e.__scopeTooltip),u=rF(t),[c,d]=p.useState(null),[h,m]=p.useState(void 0),y=eU(),v=p.useRef(0),g=o??l.disableHoverableContent,b=s??l.delayDuration,x=p.useRef(!1),[w,S]=rP({prop:n,defaultProp:a??!1,onChange:rI(e=>{e?(l.onOpen(),document.dispatchEvent(new CustomEvent(rB))):l.onClose(),i?.(e)},"onChange"),caller:r$}),j=p.useMemo(()=>w?x.current?"delayed-open":"instant-open":"closed",[w]),O=p.useCallback(()=>{window.clearTimeout(v.current),v.current=0,x.current=!1,S(!0)},[S]),k=p.useCallback(()=>{window.clearTimeout(v.current),v.current=0,S(!1)},[S]),E=p.useCallback(()=>{window.clearTimeout(v.current),v.current=window.setTimeout(()=>{x.current=!0,S(!0),v.current=0},b)},[b,S]);return p.useEffect(()=>()=>{v.current&&(window.clearTimeout(v.current),v.current=0)},[]),(0,f.jsx)(t9,{...u,children:(0,f.jsx)(rU,{scope:t,contentId:h??y,setContentId:m,open:w,stateAttribute:j,trigger:c,onTriggerChange:d,onTriggerEnter:p.useCallback(()=>{l.isOpenDelayedRef.current?E():O()},[l.isOpenDelayedRef,E,O]),onTriggerLeave:p.useCallback(()=>{g?k():(window.clearTimeout(v.current),v.current=0)},[k,g]),onOpen:O,onClose:k,disableHoverableContent:g,children:r})})},"Tooltip"),rK="TooltipTrigger",rq=p.forwardRef(rI(function(e,t){let{__scopeTooltip:r,"aria-describedby":n,...a}=e,i=rH(rK,r),o=rz(rK,r),s=rF(r),l=j(t,p.useRef(null),i.onTriggerChange),u=p.useRef(!1),c=p.useRef(!1),d=p.useCallback(()=>u.current=!1,[]);return p.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),(0,f.jsx)(t7,{asChild:!0,...s,children:(0,f.jsx)(en.button,{"aria-describedby":i.open?nt(n,i.contentId):n,"data-state":i.stateAttribute,...a,ref:l,onPointerMove:q(e.onPointerMove,e=>{"touch"!==e.pointerType&&(c.current||o.isPointerInTransitRef.current||(i.onTriggerEnter(),c.current=!0))}),onPointerLeave:q(e.onPointerLeave,()=>{i.onTriggerLeave(),c.current=!1}),onPointerDown:q(e.onPointerDown,()=>{i.open&&i.onClose(),u.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:q(e.onFocus,()=>{u.current||i.onOpen()}),onBlur:q(e.onBlur,i.onClose),onClick:q(e.onClick,i.onClose)})})},"TooltipTrigger")),rY="TooltipPortal",[rX,rZ]=r_(rY,{forceMount:void 0}),rQ=rI(e=>{let{__scopeTooltip:t,forceMount:r,children:n,container:a}=e,i=rH(rY,t);return(0,f.jsx)(rX,{scope:t,forceMount:r,children:(0,f.jsx)(rh,{present:r||i.open,children:(0,f.jsx)(rc,{asChild:!0,container:a,children:n})})})},"TooltipPortal"),rJ="TooltipContent",r0=p.forwardRef(rI(function(e,t){let r=rZ(rJ,e.__scopeTooltip),{forceMount:n=r.forceMount,side:a="top",...i}=e,o=rH(rJ,e.__scopeTooltip);return(0,f.jsx)(rh,{present:n||o.open,children:o.disableHoverableContent?(0,f.jsx)(r3,{side:a,...i,ref:t}):(0,f.jsx)(r1,{side:a,...i,ref:t})})},"TooltipContent")),r1=p.forwardRef(rI(function(e,t){let r=rH(rJ,e.__scopeTooltip),n=rz(rJ,e.__scopeTooltip),a=p.useRef(null),i=j(t,a),[o,s]=p.useState(null),{trigger:l,onClose:u}=r,c=a.current,{onPointerInTransitChange:d}=n,h=p.useCallback(()=>{s(null),d(!1)},[d]),m=p.useCallback((e,t)=>{let r=e.currentTarget,n={x:e.clientX,y:e.clientY},a=r5(n,r.getBoundingClientRect());s(r7([...r6(n,a),...r8(t.getBoundingClientRect())])),d(!0)},[d]);return p.useEffect(()=>()=>h(),[h]),p.useEffect(()=>{if(l&&c){let e=rI(e=>m(e,c),"handleTriggerLeave"),t=rI(e=>m(e,l),"handleContentLeave");return l.addEventListener("pointerleave",e),c.addEventListener("pointerleave",t),()=>{l.removeEventListener("pointerleave",e),c.removeEventListener("pointerleave",t)}}},[l,c,m,h]),p.useEffect(()=>{if(o){let e=rI(e=>{let t=e.target,r={x:e.clientX,y:e.clientY},n=l?.contains(t)||c?.contains(t),a=!r9(r,o);n?h():a&&(h(),u())},"handleTrackPointerGrace");return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}},[l,c,o,u,h]),(0,f.jsx)(r3,{...e,ref:i})},"TooltipContentHoverable")),r2=D("TooltipContent"),r3=p.forwardRef(rI(function(e,t){let{__scopeTooltip:r,children:n,"aria-label":a,id:i,onEscapeKeyDown:o,onPointerDownOutside:s,...l}=e,u=rH(rJ,r),c=rF(r),{onClose:d}=u,[h,m]=p.useState(null),y=j(t,m);eD(h),p.useEffect(()=>(document.addEventListener(rB,d),()=>document.removeEventListener(rB,d)),[d]),p.useEffect(()=>{if(u.trigger){let e=rI(e=>{e.target instanceof Node&&e.target.contains(u.trigger)&&d()},"handleScroll");return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}},[u.trigger,d]);let{setContentId:v}=u;return ei(()=>(v(i),()=>{v(void 0)}),[i,v]),(0,f.jsx)(ep,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:e=>e.preventDefault(),onDismiss:d,children:(0,f.jsxs)(rn,{"data-state":u.stateAttribute,role:a?void 0:"tooltip",id:a?void 0:u.contentId,...c,...l,ref:y,style:{...l.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[(0,f.jsx)(r2,{children:n}),a?(0,f.jsx)(rR,{id:u.contentId,role:"tooltip",children:a}):null]})})},"TooltipContentImpl")),r4=p.forwardRef(rI(function(e,t){let{__scopeTooltip:r,...n}=e,a=rF(r);return(0,f.jsx)(ri,{...a,...n,ref:t})},"TooltipArrow"));function r5(e,t){let r=Math.abs(t.top-e.y),n=Math.abs(t.bottom-e.y),a=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(r,n,a,i)){case i:return"left";case a:return"right";case r:return"top";case n:return"bottom";default:throw Error("unreachable")}}function r6(e,t,r=5){let n=[];switch(t){case"top":n.push({x:e.x-r,y:e.y+r},{x:e.x+r,y:e.y+r});break;case"bottom":n.push({x:e.x-r,y:e.y-r},{x:e.x+r,y:e.y-r});break;case"left":n.push({x:e.x+r,y:e.y-r},{x:e.x+r,y:e.y+r});break;case"right":n.push({x:e.x-r,y:e.y-r},{x:e.x-r,y:e.y+r})}return n}function r8(e){let{top:t,right:r,bottom:n,left:a}=e;return[{x:a,y:t},{x:r,y:t},{x:r,y:n},{x:a,y:n}]}function r9(e,t){let{x:r,y:n}=e,a=!1;for(let e=0,i=t.length-1;e<t.length;i=e++){let o=t[e],s=t[i],l=o.x,u=o.y,c=s.x,d=s.y;u>n!=d>n&&r<(c-l)*(n-u)/(d-u)+l&&(a=!a)}return a}function r7(e){let t=e.slice();return t.sort((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:1*!!(e.y>t.y)),ne(t)}function ne(e){if(e.length<=1)return e.slice();let t=[];for(let r=0;r<e.length;r++){let n=e[r];for(;t.length>=2;){let e=t[t.length-1],r=t[t.length-2];if((e.x-r.x)*(n.y-r.y)>=(e.y-r.y)*(n.x-r.x))t.pop();else break}t.push(n)}t.pop();let r=[];for(let t=e.length-1;t>=0;t--){let n=e[t];for(;r.length>=2;){let e=r[r.length-1],t=r[r.length-2];if((e.x-t.x)*(n.y-t.y)>=(e.y-t.y)*(n.x-t.x))r.pop();else break}r.push(n)}return(r.pop(),1===t.length&&1===r.length&&t[0].x===r[0].x&&t[0].y===r[0].y)?t:t.concat(r)}function nt(...e){let t=new Set;for(let r of e)if("string"==typeof r)for(let e of String(r).trim().split(/\s+/))e&&t.add(e);return t.size>0?Array.from(t).join(" "):void 0}function nr(){return(nr=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e}).apply(this,arguments)}function nn(e){if(null==e)throw TypeError("Cannot destructure "+e);return e}function na(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function ni(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function no(e){var t=e.delayDuration,r=ni(e,["delayDuration"]);return(0,f.jsx)(rW,na({"data-slot":"tooltip-provider",delayDuration:void 0===t?0:t},r))}function ns(e){nn(e);var t=nr({},e);return(0,f.jsx)(rG,na({"data-slot":"tooltip"},t))}function nl(e){nn(e);var t=nr({},e);return(0,f.jsx)(rq,na({"data-slot":"tooltip-trigger"},t))}function nu(e){var t,r,n=e.className,a=e.sideOffset,i=e.children,o=ni(e,["className","sideOffset","children"]);return(0,f.jsx)(rQ,{children:(0,f.jsxs)(r0,(t=na({"data-slot":"tooltip-content",sideOffset:void 0===a?0:a,className:(0,g.cn)("z-50 w-fit origin-(--radix-tooltip-content-transform-origin) animate-in rounded-md bg-foreground px-3 py-1.5 text-xs text-balance text-background fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",n)},o),r=r={children:[i,(0,f.jsx)(r4,{className:"z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground"})]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))})}function nc(e){var t,r,n=e.icon,a=e.label,i=e.size,o=e.variant,s=e.tooltipSide,l=e.noTooltip,u=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["icon","label","size","variant","tooltipSide","noTooltip"]),c=(0,f.jsx)(U,(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({type:"button",variant:void 0===o?"ghost":o,size:void 0===i?"icon":i,"aria-label":a},u),r=r={children:n},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t));return void 0!==l&&l?c:(0,f.jsx)(no,{children:(0,f.jsxs)(ns,{children:[(0,f.jsx)(nl,{asChild:!0,children:c}),(0,f.jsx)(nu,{side:void 0===s?"top":s,children:a})]})})}rI(r5,"getExitSideFromRect"),rI(r6,"getPaddedExitPoints"),rI(r8,"getPointsFromRect"),rI(r9,"isPointInPolygon"),rI(r7,"getHull"),rI(ne,"getHullPresorted"),rI(nt,"concatAriaDescribedby");var nd=v("inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-full border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3",{variants:{variant:{default:"bg-primary text-primary-foreground [a&]:hover:bg-primary/90",secondary:"bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",destructive:"bg-destructive text-white focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40 [a&]:hover:bg-destructive/90",outline:"border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",ghost:"[a&]:hover:bg-accent [a&]:hover:text-accent-foreground",link:"text-primary underline-offset-4 [a&]:hover:underline"}},defaultVariants:{variant:"default"}});function nf(e){var t=e.className,r=e.variant,n=void 0===r?"default":r,a=e.asChild,i=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className","variant","asChild"]);return(0,f.jsx)(void 0!==a&&a?P:"span",function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-slot":"badge","data-variant":n,className:(0,g.cn)(nd({variant:n}),t)},i))}var np=r(4347),nh=(0,np.A)("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);function nm(e){var t=e.className,r=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className"]);return(0,f.jsx)(nh,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({role:"status","aria-label":"Loading",className:(0,g.cn)("size-4 animate-spin",t)},r))}var ny=r(3601),nv=(0,np.A)("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);function ng(e){var t,r,n=e.status,a=void 0===n?"active":n,i=e.description,o=e.className,s=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["status","description","className"]);return"inactive"===a?null:(0,f.jsxs)("div",(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-slot":"inline-loading","data-status":a,role:"status","aria-live":"polite",className:(0,g.cn)("inline-flex items-center gap-2 text-sm text-muted-foreground",o)},s),r=r={children:["active"===a&&(0,f.jsx)(nm,{"aria-label":void 0,role:"presentation"}),"finished"===a&&(0,f.jsx)(ny.A,{className:"size-4 text-emerald-500","aria-hidden":"true"}),"error"===a&&(0,f.jsx)(nv,{className:"size-4 text-destructive","aria-hidden":"true"}),i?(0,f.jsx)("span",{children:i}):null]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))}function nb(e){var t=e.className,r=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className"]);return(0,f.jsx)("div",function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-slot":"layer",className:(0,g.cn)("bg-card text-card-foreground",t)},r))}function nx(e){var t=e.className,r=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className"]);return(0,f.jsx)("div",function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-slot":"tile",className:(0,g.cn)("flex flex-col gap-6 rounded-xl border bg-card py-6 text-card-foreground shadow-sm",t)},r))}function nw(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function nS(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}var nj=v("relative grid w-full grid-cols-[0_1fr] items-start gap-y-0.5 rounded-lg border px-4 py-3 text-sm has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] has-[>svg]:gap-x-3 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 [&>svg]:text-current",info:"border-l-4 border-l-primary bg-card text-card-foreground [&>svg]:text-primary",success:"border-l-4 border-l-emerald-500 bg-card text-card-foreground [&>svg]:text-emerald-500",warning:"border-l-4 border-l-amber-500 bg-card text-card-foreground [&>svg]:text-amber-500",error:"border-l-4 border-l-destructive bg-card text-card-foreground [&>svg]:text-destructive"}},defaultVariants:{variant:"default"}});function nO(e){var t=e.className,r=e.variant,n=nS(e,["className","variant"]);return(0,f.jsx)("div",nw({"data-slot":"alert",role:"alert",className:(0,g.cn)(nj({variant:r}),t)},n))}function nk(e){var t=e.className,r=nS(e,["className"]);return(0,f.jsx)("div",nw({"data-slot":"alert-title",className:(0,g.cn)("col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",t)},r))}function nE(e){var t=e.className,r=nS(e,["className"]);return(0,f.jsx)("div",nw({"data-slot":"alert-description",className:(0,g.cn)("col-start-2 grid justify-items-start gap-1 text-sm text-muted-foreground [&_p]:leading-relaxed",t)},r))}var nP=r(822),nA=Object.defineProperty,nD=(e,t)=>nA(e,"name",{value:t,configurable:!0}),nC=0,nT=null;function nN(){p.useEffect(()=>{nT||(nT={start:nR(),end:nR()});let{start:e,end:t}=nT;return document.body.firstElementChild!==e&&document.body.insertAdjacentElement("afterbegin",e),document.body.lastElementChild!==t&&document.body.insertAdjacentElement("beforeend",t),nC++,()=>{1===nC&&(nT?.start.remove(),nT?.end.remove(),nT=null),nC=Math.max(0,nC-1)}},[])}function nR(){let e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}nD(function(e){return nN(),e.children},"FocusGuards"),nD(nN,"useFocusGuards"),nD(nR,"createFocusGuard");var nM=r(5823),nI="right-scroll-bar-position",n_="width-before-scroll-bar";function nL(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var nF="u">typeof window?p.useLayoutEffect:p.useEffect,nB=new WeakMap,nV=(void 0===a&&(a={}),(void 0===i&&(i=function(e){return e}),o=[],s=!1,l={read:function(){if(s)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return o.length?o[o.length-1]:null},useMedium:function(e){var t=i(e,s);return o.push(t),function(){o=o.filter(function(e){return e!==t})}},assignSyncMedium:function(e){for(s=!0;o.length;){var t=o;o=[],t.forEach(e)}o={push:function(t){return e(t)},filter:function(){return o}}},assignMedium:function(e){s=!0;var t=[];if(o.length){var r=o;o=[],r.forEach(e),t=o}var n=function(){var r=t;t=[],r.forEach(e)},a=function(){return Promise.resolve().then(n)};a(),o={push:function(e){t.push(e),a()},filter:function(e){return t=t.filter(e),o}}}}).options=(0,nM.Cl)({async:!0,ssr:!1},a),l),nz=function(){},nW=p.forwardRef(function(e,t){var r,n,a,i,o=p.useRef(null),s=p.useState({onScrollCapture:nz,onWheelCapture:nz,onTouchMoveCapture:nz}),l=s[0],u=s[1],c=e.forwardProps,d=e.children,f=e.className,h=e.removeScrollBar,m=e.enabled,y=e.shards,v=e.sideCar,g=e.noRelative,b=e.noIsolation,x=e.inert,w=e.allowPinchZoom,S=e.as,j=e.gapMode,O=(0,nM.Tt)(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),k=(r=[o,t],n=function(e){return r.forEach(function(t){return nL(t,e)})},(a=(0,p.useState)(function(){return{value:null,callback:n,facade:{get current(){return a.value},set current(value){var e=a.value;e!==value&&(a.value=value,a.callback(value,e))}}}})[0]).callback=n,i=a.facade,nF(function(){var e=nB.get(i);if(e){var t=new Set(e),n=new Set(r),a=i.current;t.forEach(function(e){n.has(e)||nL(e,null)}),n.forEach(function(e){t.has(e)||nL(e,a)})}nB.set(i,r)},[r]),i),E=(0,nM.Cl)((0,nM.Cl)({},O),l);return p.createElement(p.Fragment,null,m&&p.createElement(v,{sideCar:nV,removeScrollBar:h,shards:y,noRelative:g,noIsolation:b,inert:x,setCallbacks:u,allowPinchZoom:!!w,lockRef:o,gapMode:j}),c?p.cloneElement(p.Children.only(d),(0,nM.Cl)((0,nM.Cl)({},E),{ref:k})):p.createElement(void 0===S?"div":S,(0,nM.Cl)({},E,{className:f,ref:k}),d))});nW.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},nW.classNames={fullWidth:n_,zeroRight:nI};var n$=function(e){var t=e.sideCar,r=(0,nM.Tt)(e,["sideCar"]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw Error("Sidecar medium not found");return p.createElement(n,(0,nM.Cl)({},r))};n$.isSideCarExport=!0;var nU=function(){var e=0,t=null;return{add:function(n){if(0==e&&(t=function(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=d||r.nc;return t&&e.setAttribute("nonce",t),e}())){var a,i;(a=t).styleSheet?a.styleSheet.cssText=n:a.appendChild(document.createTextNode(n)),i=t,(document.head||document.getElementsByTagName("head")[0]).appendChild(i)}e++},remove:function(){--e||!t||(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},nH=function(){var e=nU();return function(t,r){p.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},nG=function(){var e=nH();return function(t){return e(t.styles,t.dynamic),null}},nK={left:0,top:0,right:0,gap:0},nq=function(e){return parseInt(e||"",10)||0},nY=function(e){var t=window.getComputedStyle(document.body),r=t["padding"===e?"paddingLeft":"marginLeft"],n=t["padding"===e?"paddingTop":"marginTop"],a=t["padding"===e?"paddingRight":"marginRight"];return[nq(r),nq(n),nq(a)]},nX=function(e){if(void 0===e&&(e="margin"),"u"<typeof window)return nK;var t=nY(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},nZ=nG(),nQ="data-scroll-locked",nJ=function(e,t,r,n){var a=e.left,i=e.top,o=e.right,s=e.gap;return void 0===r&&(r="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(n,";\n padding-right: ").concat(s,"px ").concat(n,";\n }\n body[").concat(nQ,"] {\n overflow: hidden ").concat(n,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(n,";"),"margin"===r&&"\n padding-left: ".concat(a,"px;\n padding-top: ").concat(i,"px;\n padding-right: ").concat(o,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(s,"px ").concat(n,";\n "),"padding"===r&&"padding-right: ".concat(s,"px ").concat(n,";")].filter(Boolean).join(""),"\n }\n \n .").concat(nI," {\n right: ").concat(s,"px ").concat(n,";\n }\n \n .").concat(n_," {\n margin-right: ").concat(s,"px ").concat(n,";\n }\n \n .").concat(nI," .").concat(nI," {\n right: 0 ").concat(n,";\n }\n \n .").concat(n_," .").concat(n_," {\n margin-right: 0 ").concat(n,";\n }\n \n body[").concat(nQ,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(s,"px;\n }\n")},n0=function(){var e=parseInt(document.body.getAttribute(nQ)||"0",10);return isFinite(e)?e:0},n1=function(){p.useEffect(function(){return document.body.setAttribute(nQ,(n0()+1).toString()),function(){var e=n0()-1;e<=0?document.body.removeAttribute(nQ):document.body.setAttribute(nQ,e.toString())}},[])},n2=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,a=void 0===n?"margin":n;n1();var i=p.useMemo(function(){return nX(a)},[a]);return p.createElement(nZ,{styles:nJ(i,!t,a,r?"":"!important")})},n3=!1;if("u">typeof window)try{var n4=Object.defineProperty({},"passive",{get:function(){return n3=!0,!0}});window.addEventListener("test",n4,n4),window.removeEventListener("test",n4,n4)}catch(e){n3=!1}var n5=!!n3&&{passive:!1};function n6(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}var n8=function(e,t){if(!n6(e,Element))return!1;var r=window.getComputedStyle(e);return"hidden"!==r[t]&&(r.overflowY!==r.overflowX||"TEXTAREA"===e.tagName||"visible"!==r[t])},n9=function(e,t){var r=t.ownerDocument,n=t;do{if("u">typeof ShadowRoot&&n6(n,ShadowRoot)&&(n=n.host),n7(e,n)){var a=ae(e,n);if(a[1]>a[2])return!0}n=n.parentNode}while(n&&n!==r.body);return!1},n7=function(e,t){return"v"===e?n8(t,"overflowY"):n8(t,"overflowX")},ae=function(e,t){return"v"===e?[t.scrollTop,t.scrollHeight,t.clientHeight]:[t.scrollLeft,t.scrollWidth,t.clientWidth]},at=function(e,t,r,n,a){var i,o=(i=window.getComputedStyle(t).direction,"h"===e&&"rtl"===i?-1:1),s=o*n,l=r.target,u=t.contains(l),c=!1,d=s>0,f=0,p=0;do{if(!l)break;var h=ae(e,l),m=h[0],y=h[1]-h[2]-o*m;(m||y)&&n7(e,l)&&(f+=y,p+=m);var v=l.parentNode;l=v&&v.nodeType===Node.DOCUMENT_FRAGMENT_NODE?v.host:v}while(!u&&l!==document.body||u&&(t.contains(l)||t===l));return d&&(a&&1>Math.abs(f)||!a&&s>f)?c=!0:!d&&(a&&1>Math.abs(p)||!a&&-s>p)&&(c=!0),c},ar=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},an=function(e){return[e.deltaX,e.deltaY]},aa=function(e){return e&&"current"in e?e.current:e},ai=0,ao=[];let as=(u=function(e){var t=p.useRef([]),r=p.useRef([0,0]),n=p.useRef(),a=p.useState(ai++)[0],i=p.useState(nG)[0],o=p.useRef(e);p.useEffect(function(){o.current=e},[e]),p.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(a));var t=(0,nM.fX)([e.lockRef.current],(e.shards||[]).map(aa),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add("allow-interactivity-".concat(a))}),function(){document.body.classList.remove("block-interactivity-".concat(a)),t.forEach(function(e){return e.classList.remove("allow-interactivity-".concat(a))})}}},[e.inert,e.lockRef.current,e.shards]);var s=p.useCallback(function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!o.current.allowPinchZoom;var a,i=ar(e),s=r.current,l="deltaX"in e?e.deltaX:s[0]-i[0],u="deltaY"in e?e.deltaY:s[1]-i[1],c=e.target,d=Math.abs(l)>Math.abs(u)?"h":"v";if("touches"in e&&"h"===d&&"range"===c.type)return!1;var f=window.getSelection(),p=f&&f.anchorNode;if(p&&(p===c||p.contains(c)))return!1;var h=n9(d,c);if(!h)return!0;if(h?a=d:(a="v"===d?"h":"v",h=n9(d,c)),!h)return!1;if(!n.current&&"changedTouches"in e&&(l||u)&&(n.current=a),!a)return!0;var m=n.current||a;return at(m,t,e,"h"===m?l:u,!0)},[]),l=p.useCallback(function(e){if(ao.length&&ao[ao.length-1]===i){var r="deltaY"in e?an(e):ar(e),n=t.current.filter(function(t){var n;return t.name===e.type&&(t.target===e.target||e.target===t.shadowParent)&&(n=t.delta,n[0]===r[0]&&n[1]===r[1])})[0];if(n&&n.should){e.cancelable&&e.preventDefault();return}if(!n){var a=(o.current.shards||[]).map(aa).filter(Boolean).filter(function(t){return t.contains(e.target)});(a.length>0?s(e,a[0]):!o.current.noIsolation)&&e.cancelable&&e.preventDefault()}}},[]),u=p.useCallback(function(e,r,n,a){var i={name:e,delta:r,target:n,should:a,shadowParent:function(e){for(var t,r,n=null;null!==e;)t=e,(null!=(r=ShadowRoot)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](t):t instanceof r)&&(n=e.host,e=e.host),e=e.parentNode;return n}(n)};t.current.push(i),setTimeout(function(){t.current=t.current.filter(function(e){return e!==i})},1)},[]),c=p.useCallback(function(e){r.current=ar(e),n.current=void 0},[]),d=p.useCallback(function(t){u(t.type,an(t),t.target,s(t,e.lockRef.current))},[]),f=p.useCallback(function(t){u(t.type,ar(t),t.target,s(t,e.lockRef.current))},[]);p.useEffect(function(){return ao.push(i),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener("wheel",l,n5),document.addEventListener("touchmove",l,n5),document.addEventListener("touchstart",c,n5),function(){ao=ao.filter(function(e){return e!==i}),document.removeEventListener("wheel",l,n5),document.removeEventListener("touchmove",l,n5),document.removeEventListener("touchstart",c,n5)}},[]);var h=e.removeScrollBar,m=e.inert;return p.createElement(p.Fragment,null,m?p.createElement(i,{styles:"\n .block-interactivity-".concat(a," {pointer-events: none;}\n .allow-interactivity-").concat(a," {pointer-events: all;}\n")}):null,h?p.createElement(n2,{noRelative:e.noRelative,gapMode:e.gapMode}):null)},nV.useMedium(u),n$);var al=p.forwardRef(function(e,t){return p.createElement(nW,(0,nM.Cl)({},e,{ref:t,sideCar:as}))});al.classNames=nW.classNames;var au=new WeakMap,ac=new WeakMap,ad={},af=0,ap=function(e){return e&&(e.host||ap(e.parentNode))},ah=function(e,t,r,n){var a=(Array.isArray(e)?e:[e]).map(function(e){if(t.contains(e))return e;var r=ap(e);return r&&t.contains(r)?r:(console.error("aria-hidden",e,"in not contained inside",t,". Doing nothing"),null)}).filter(function(e){return!!e});ad[r]||(ad[r]=new WeakMap);var i=ad[r],o=[],s=new Set,l=new Set(a),u=function(e){!e||s.has(e)||(s.add(e),u(e.parentNode))};a.forEach(u);var c=function(e){!e||l.has(e)||Array.prototype.forEach.call(e.children,function(e){if(s.has(e))c(e);else try{var t=e.getAttribute(n),a=null!==t&&"false"!==t,l=(au.get(e)||0)+1,u=(i.get(e)||0)+1;au.set(e,l),i.set(e,u),o.push(e),1===l&&a&&ac.set(e,!0),1===u&&e.setAttribute(r,"true"),a||e.setAttribute(n,"true")}catch(t){console.error("aria-hidden: cannot operate on ",e,t)}})};return c(t),s.clear(),af++,function(){o.forEach(function(e){var t=au.get(e)-1,a=i.get(e)-1;au.set(e,t),i.set(e,a),t||(ac.has(e)||e.removeAttribute(n),ac.delete(e)),a||e.removeAttribute(r)}),--af||(au=new WeakMap,au=new WeakMap,ac=new WeakMap,ad={})}},am=function(e,t,r){void 0===r&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),a=t||("u"<typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body);return a?(n.push.apply(n,Array.from(a.querySelectorAll("[aria-live], script"))),ah(n,a,r,"aria-hidden")):function(){return null}},ay=Object.defineProperty,av=(e,t)=>ay(e,"name",{value:t,configurable:!0}),ag="Dialog",[ab,ax]=J(ag),[aw,aS]=ab(ag),aj=av(e=>{let{__scopeDialog:t,children:r,open:n,defaultOpen:a,onOpenChange:i,modal:o=!0}=e,s=p.useRef(null),l=p.useRef(null),{nodes:u,registry:c}=eA(),[d,h]=rP({prop:n,defaultProp:a??!1,onChange:i,caller:ag}),[m,y]=p.useState(0),[v,g]=p.useState(0);return(0,f.jsx)(aw,{scope:t,triggerRef:s,contentRef:l,contentId:eU(),titleId:eU(),descriptionId:eU(),titlePresent:m>0,descriptionPresent:v>0,setTitleCount:y,setDescriptionCount:g,open:d,onOpenChange:h,onOpenToggle:p.useCallback(()=>h(e=>!e),[h]),modal:o,branchNodes:u,branchRegistry:c,children:r})},"Dialog"),aO="DialogPortal",[ak,aE]=ab(aO,{forceMount:void 0}),aP=av(e=>{let{__scopeDialog:t,forceMount:r,children:n,container:a}=e,i=aS(aO,t);return(0,f.jsx)(ak,{scope:t,forceMount:r,children:p.Children.map(n,e=>(0,f.jsx)(rh,{present:r||i.open,children:(0,f.jsx)(rc,{asChild:!0,container:a,children:e})}))})},"DialogPortal"),aA="DialogOverlay",aD=p.forwardRef(av(function(e,t){let r=aE(aA,e.__scopeDialog),{forceMount:n=r.forceMount,...a}=e,i=aS(aA,e.__scopeDialog);return i.modal?(0,f.jsx)(rh,{present:n||i.open,children:(0,f.jsx)(aT,{...a,ref:t})}):null},"DialogOverlay")),aC=E("DialogOverlay.RemoveScroll"),aT=p.forwardRef(av(function(e,t){let{__scopeDialog:r,...n}=e,a=aS(aA,r),i=j(t,eh());return(0,f.jsx)(al,{as:aC,allowPinchZoom:!0,shards:p.useMemo(()=>[a.contentRef,...a.branchNodes.map(e=>({current:e}))],[a.contentRef,a.branchNodes]),children:(0,f.jsx)(en.div,{"data-state":az(a.open),...n,ref:i,style:{pointerEvents:"auto",...n.style}})})},"DialogOverlayImpl")),aN="DialogContent",aR=p.forwardRef(av(function(e,t){let r=aE(aN,e.__scopeDialog),{forceMount:n=r.forceMount,...a}=e,i=aS(aN,e.__scopeDialog);return(0,f.jsx)(rh,{present:n||i.open,children:i.modal?(0,f.jsx)(aM,{...a,ref:t}):(0,f.jsx)(aI,{...a,ref:t})})},"DialogContent")),aM=p.forwardRef(av(function(e,t){let r=aS(aN,e.__scopeDialog),n=p.useRef(null),a=j(t,r.contentRef,n);return p.useEffect(()=>{let e=n.current;if(e)return am(e)},[]),(0,f.jsx)(a_,{...e,ref:a,trapFocus:r.open,disableOutsidePointerEvents:r.open,onCloseAutoFocus:q(e.onCloseAutoFocus,e=>{e.preventDefault(),r.triggerRef.current?.focus()}),onPointerDownOutside:q(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,r=0===t.button&&!0===t.ctrlKey;(2===t.button||r)&&e.preventDefault()}),onFocusOutside:q(e.onFocusOutside,e=>e.preventDefault())})},"DialogContentModal")),aI=p.forwardRef(av(function(e,t){let r=aS(aN,e.__scopeDialog),n=p.useRef(!1),a=p.useRef(!1);return(0,f.jsx)(a_,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(n.current||r.triggerRef.current?.focus(),t.preventDefault()),n.current=!1,a.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(n.current=!0,"pointerdown"===t.detail.originalEvent.type&&(a.current=!0));let i=t.target;r.triggerRef.current?.contains(i)&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&a.current&&t.preventDefault()}})},"DialogContentNonModal")),a_=p.forwardRef(av(function(e,t){let{__scopeDialog:r,trapFocus:n,onOpenAutoFocus:a,onCloseAutoFocus:i,"aria-describedby":o,children:s,...l}=e,u=aS(aN,r);return nN(),(0,f.jsx)(eP,{registry:u.branchRegistry,children:(0,f.jsx)(ek,{asChild:!0,loop:!0,trapped:n,branches:u.branchNodes,onMountAutoFocus:a,onUnmountAutoFocus:i,children:(0,f.jsx)(ep,{role:"dialog",id:u.contentId,"aria-labelledby":u.titlePresent?u.titleId:void 0,"aria-describedby":u.descriptionPresent?aV(o,u.descriptionId):o,"data-state":az(u.open),...l,ref:t,deferPointerDownOutside:!0,onDismiss:()=>u.onOpenChange(!1),children:s})})})},"DialogContentImpl")),aL=p.forwardRef(av(function(e,t){let{__scopeDialog:r,...n}=e,a=aS("DialogTitle",r),{setTitleCount:i}=a;return ei(()=>(i(e=>e+1),()=>i(e=>e-1)),[i]),(0,f.jsx)(en.h2,{id:a.titleId,...n,ref:t})},"DialogTitle")),aF=p.forwardRef(av(function(e,t){let{__scopeDialog:r,...n}=e,a=aS("DialogDescription",r),{setDescriptionCount:i}=a;return ei(()=>(i(e=>e+1),()=>i(e=>e-1)),[i]),(0,f.jsx)(en.p,{id:a.descriptionId,...n,ref:t})},"DialogDescription")),aB=p.forwardRef(av(function(e,t){let{__scopeDialog:r,...n}=e,a=aS("DialogClose",r);return(0,f.jsx)(en.button,{type:"button",...n,ref:t,onClick:q(e.onClick,()=>a.onOpenChange(!1))})},"DialogClose"));function aV(...e){let t=new Set;for(let r of e)if("string"==typeof r)for(let e of String(r).trim().split(/\s+/))e&&t.add(e);return t.size>0?Array.from(t).join(" "):void 0}function az(e){return e?"open":"closed"}function aW(){return(aW=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e}).apply(this,arguments)}function a$(e){if(null==e)throw TypeError("Cannot destructure "+e);return e}function aU(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function aH(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function aG(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function aK(e){a$(e);var t=aW({},e);return(0,f.jsx)(aj,aU({"data-slot":"dialog"},t))}function aq(e){a$(e);var t=aW({},e);return(0,f.jsx)(aP,aU({"data-slot":"dialog-portal"},t))}function aY(e){var t=e.className,r=aG(e,["className"]);return(0,f.jsx)(aD,aU({"data-slot":"dialog-overlay",className:(0,g.cn)("fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0",t)},r))}function aX(e){var t=e.className,r=e.children,n=e.showCloseButton,a=aG(e,["className","children","showCloseButton"]);return(0,f.jsxs)(aq,{"data-slot":"dialog-portal",children:[(0,f.jsx)(aY,{}),(0,f.jsxs)(aR,aH(aU({"data-slot":"dialog-content",className:(0,g.cn)("fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border bg-background p-6 shadow-lg duration-200 outline-none data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 sm:max-w-lg",t)},a),{children:[r,(void 0===n||n)&&(0,f.jsxs)(aB,{"data-slot":"dialog-close",className:"absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:ring-2 focus:ring-ring focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",children:[(0,f.jsx)(nP.A,{}),(0,f.jsx)("span",{className:"sr-only",children:"Close"})]})]}))]})}function aZ(e){var t=e.className,r=aG(e,["className"]);return(0,f.jsx)("div",aU({"data-slot":"dialog-header",className:(0,g.cn)("flex flex-col gap-2 text-center sm:text-left",t)},r))}function aQ(e){var t=e.className,r=e.showCloseButton,n=e.children,a=aG(e,["className","showCloseButton","children"]);return(0,f.jsxs)("div",aH(aU({"data-slot":"dialog-footer",className:(0,g.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",t)},a),{children:[n,void 0!==r&&r&&(0,f.jsx)(aB,{asChild:!0,children:(0,f.jsx)(U,{variant:"outline",children:"Close"})})]}))}function aJ(e){var t=e.className,r=aG(e,["className"]);return(0,f.jsx)(aL,aU({"data-slot":"dialog-title",className:(0,g.cn)("text-lg leading-none font-semibold",t)},r))}function a0(e){var t=e.className,r=aG(e,["className"]);return(0,f.jsx)(aF,aU({"data-slot":"dialog-description",className:(0,g.cn)("text-sm text-muted-foreground",t)},r))}function a1(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function a2(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function a3(e){var t,r,n=e.title,a=e.label,i=e.onClose,o=e.closeLabel,s=void 0===o?"Close":o,l=e.className,u=e.children,c=a2(e,["title","label","onClose","closeLabel","className","children"]);return(0,f.jsxs)("div",(t=a1({"data-slot":"modal-header",className:(0,g.cn)("relative flex shrink-0 flex-col gap-1 border-b px-6 py-4 pr-14 text-left",l)},c),r=r={children:[a?(0,f.jsx)("p",{className:"text-xs text-muted-foreground",children:a}):null,n?(0,f.jsx)("h2",{className:"text-lg leading-snug font-semibold",children:n}):null,u,i?(0,f.jsx)("button",{type:"button",onClick:i,"aria-label":s,title:s,className:"absolute top-3 right-3 inline-flex size-8 items-center justify-center rounded-md text-muted-foreground outline-none hover:bg-accent hover:text-accent-foreground focus-visible:ring-[3px] focus-visible:ring-ring/50",children:(0,f.jsx)(nP.A,{className:"size-4","aria-hidden":"true"})}):null]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))}function a4(e){var t=e.className,r=a2(e,["className"]);return(0,f.jsx)("div",a1({"data-slot":"modal-body",className:(0,g.cn)("min-h-0 flex-1 overflow-y-auto px-6 py-4",t)},r))}function a5(e){var t=e.className,r=a2(e,["className"]);return(0,f.jsx)("div",a1({"data-slot":"modal-footer",className:(0,g.cn)("flex shrink-0 flex-wrap items-center justify-end gap-2 border-t px-6 py-4",t)},r))}av(aV,"concatAriaDescribedby"),av(az,"getState"),v("group/tabs-list inline-flex w-fit items-center justify-center rounded-lg p-[3px] text-muted-foreground group-data-[orientation=horizontal]/tabs:h-9 group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col data-[variant=line]:rounded-none",{variants:{variant:{default:"bg-muted",line:"gap-1 bg-transparent"}},defaultVariants:{variant:"default"}});var a6=r(8032),a8=(0,np.A)("TriangleAlert",[["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",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),a9=(0,np.A)("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]),a7={info:a6.A,success:ny.A,warning:a8,error:a9};function ie(e){var t,r,n=e.kind,a=e.title,i=e.subtitle,o=e.actionLabel,s=e.onAction,l=e.onClose,u=e.closeLabel,c=void 0===u?"Close":u,d=e.statusLabel,h=e.className,m=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["kind","title","subtitle","actionLabel","onAction","onClose","closeLabel","statusLabel","className"]),y="error"===n?"error":"success"===n?"success":"warning"===n||"warning-alt"===n?"warning":"info",v=p.useId(),b=!!(o||l),x=a7[y];return(0,f.jsxs)(nO,(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({variant:y,"data-kind":y,role:b?"alertdialog":"alert","aria-labelledby":a?v:void 0,"aria-label":a?void 0:d,className:(0,g.cn)("grid-cols-[auto_1fr_auto] items-center gap-x-3",h)},m),r=r={children:[(0,f.jsx)(x,{"aria-hidden":"true"}),(0,f.jsxs)("div",{className:"col-start-2 min-w-0",children:[a?(0,f.jsx)(nk,{id:v,children:a}):null,i?(0,f.jsx)(nE,{children:i}):null]}),(0,f.jsxs)("div",{className:"col-start-3 flex items-center gap-1",children:[o?(0,f.jsx)(U,{type:"button",variant:"ghost",size:"sm",onClick:s,children:o}):null,l?(0,f.jsx)(U,{type:"button",variant:"ghost",size:"icon-sm",onClick:l,"aria-label":c,title:c,children:(0,f.jsx)(nP.A,{"aria-hidden":"true"})}):null]})]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))}function it(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function ir(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function ia(e){var t=e.className,r=ir(e,["className"]);return(0,f.jsx)("header",it({"data-slot":"app-header",className:(0,g.cn)("relative flex h-12 items-center bg-card text-foreground",t)},r))}function ii(e){var t=e.className,r=ir(e,["className"]);return(0,f.jsx)("span",it({"data-slot":"app-header-name",className:(0,g.cn)("flex h-12 items-center truncate px-4 text-sm font-semibold",t)},r))}function io(e){var t=e.className,r=ir(e,["className"]);return(0,f.jsx)("div",it({"data-slot":"app-header-bar",className:(0,g.cn)("flex h-full items-center",t)},r))}function is(e){var t=e.className,r=e.type,n=e["aria-label"],a=e.title,i=ir(e,["className","type","aria-label","title"]);return(0,f.jsx)("button",it({"data-slot":"app-header-action",type:void 0===r?"button":r,"aria-label":n,title:null!=a?a:n,className:(0,g.cn)("inline-flex size-12 shrink-0 cursor-pointer items-center justify-center border-0 bg-transparent text-current outline-none transition-colors hover:bg-accent hover:text-accent-foreground focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-inset [&_svg]:size-4",t)},i))}},9663(e){function t(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}!function(){"use strict";var r={}.hasOwnProperty;function n(){for(var e="",i=0;i<arguments.length;i++){var o=arguments[i];o&&(e=a(e,function(e){if("string"==typeof e||"number"==typeof e)return e;if((void 0===e?"undefined":t(e))!=="object")return"";if(Array.isArray(e))return n.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var i="";for(var o in e)r.call(e,o)&&e[o]&&(i=a(i,o));return i}(o)))}return e}function a(e,t){return t?e?e+" "+t:e+t:e}e.exports?(n.default=n,e.exports=n):"function"==typeof define&&"object"===t(define.amd)&&define.amd?define("classnames",[],function(){return n}):window.classNames=n}()},5923(e,t,r){"use strict";r.d(t,{Ip:()=>f,_l:()=>d,gX:()=>c,ng:()=>u});var n=r(2974),a=r(240),i=r(2298),o=r(345),s=r(9405);function l(e){let t,r="object"==typeof e[0]?e.shift():new(0,o.FG);if("string"==typeof e[0])t=e.shift();else{let e=r.getEras();t=e[e.length-1]}return[r,t,e.shift(),e.shift(),e.shift()]}class u{#t;constructor(...e){let[t,r,a,i,o]=l(e);this.calendar=t,this.era=r,this.year=a,this.month=i,this.day=o,(0,n.AU)(this)}copy(){return this.era?new u(this.calendar,this.era,this.year,this.month,this.day):new u(this.calendar,this.year,this.month,this.day)}add(e){return(0,n.WQ)(this,e)}subtract(e){return(0,n.Re)(this,e)}set(e){return(0,n.hZ)(this,e)}cycle(e,t,r){return(0,n.xy)(this,e,t,r)}toDate(e){return(0,s.ay)(this,e)}toString(){return(0,i.$T)(this)}compare(e){return(0,a.SE)(this,e)}}class c{#t;constructor(e=0,t=0,r=0,a=0){this.hour=e,this.minute=t,this.second=r,this.millisecond=a,(0,n.Rb)(this)}copy(){return new c(this.hour,this.minute,this.second,this.millisecond)}add(e){return(0,n.tY)(this,e)}subtract(e){return(0,n.YP)(this,e)}set(e){return(0,n.ib)(this,e)}cycle(e,t,r){return(0,n.gt)(this,e,t,r)}toString(){return(0,i.ot)(this)}compare(e){return(0,a.Nu)(this,e)}}class d{#t;constructor(...e){let[t,r,a,i,o]=l(e);this.calendar=t,this.era=r,this.year=a,this.month=i,this.day=o,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,(0,n.AU)(this)}copy(){return this.era?new d(this.calendar,this.era,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond):new d(this.calendar,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond)}add(e){return(0,n.WQ)(this,e)}subtract(e){return(0,n.Re)(this,e)}set(e){return(0,n.hZ)((0,n.ib)(this,e),e)}cycle(e,t,r){switch(e){case"era":case"year":case"month":case"day":return(0,n.xy)(this,e,t,r);default:return(0,n.gt)(this,e,t,r)}}toDate(e,t){return(0,s.ay)(this,e,t)}toString(){return(0,i.qk)(this)}compare(e){let t=(0,a.SE)(this,e);return 0===t?(0,a.Nu)(this,(0,s.tR)(e)):t}}class f{#t;constructor(...e){let[t,r,a,i,o]=l(e),s=e.shift(),u=e.shift();this.calendar=t,this.era=r,this.year=a,this.month=i,this.day=o,this.timeZone=s,this.offset=u,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,(0,n.AU)(this)}copy(){return this.era?new f(this.calendar,this.era,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond):new f(this.calendar,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond)}add(e){return(0,n.E0)(this,e)}subtract(e){return(0,n.d_)(this,e)}set(e,t){return(0,n.D8)(this,e,t)}cycle(e,t,r){return(0,n.XH)(this,e,t,r)}toDate(){return(0,s.cd)(this)}toString(){return(0,i.e6)(this)}toAbsoluteString(){return this.toDate().toISOString()}compare(e){return this.toDate().getTime()-(0,s.uB)(e,this.timeZone).toDate().getTime()}}},345(e,t,r){"use strict";r.d(t,{FG:()=>c,LA:()=>s,U_:()=>o,f5:()=>l,rG:()=>i});var n=r(5923),a=r(5504);function i(e,t,r,n){let a=(t=s(e,t))-1,i=-2;return r<=2?i=0:o(t)&&(i=-1),1721425+365*a+Math.floor(a/4)-Math.floor(a/100)+Math.floor(a/400)+Math.floor((367*r-362)/12+i+n)}function o(e){return e%4==0&&(e%100!=0||e%400==0)}function s(e,t){return"BC"===e?1-t:t}function l(e){let t="AD";return e<=0&&(t="BC",e=1-e),[t,e]}let u={standard:[31,28,31,30,31,30,31,31,30,31,30,31],leapyear:[31,29,31,30,31,30,31,31,30,31,30,31]};class c{fromJulianDay(e){let t=e-1721426,r=Math.floor(t/146097),s=(0,a.z)(t,146097),u=Math.floor(s/36524),c=(0,a.z)(s,36524),d=Math.floor(c/1461),f=Math.floor((0,a.z)(c,1461)/365),[p,h]=l(400*r+100*u+4*d+f+ +(4!==u&&4!==f)),m=e-i(p,h,1,1),y=2;e<i(p,h,3,1)?y=0:o(h)&&(y=1);let v=Math.floor(((m+y)*12+373)/367),g=e-i(p,h,v,1)+1;return new(0,n.ng)(p,h,v,g)}toJulianDay(e){return i(e.era,e.year,e.month,e.day)}getDaysInMonth(e){return u[o(e.year)?"leapyear":"standard"][e.month-1]}getMonthsInYear(e){return 12}getDaysInYear(e){return o(e.year)?366:365}getMaximumMonthsInYear(){return 12}getMaximumDaysInMonth(){return 31}getYearsInEra(e){return 9999}getEras(){return["BC","AD"]}isInverseEra(e){return"BC"===e.era}balanceDate(e){e.year<=0&&(e.era="BC"===e.era?"AD":"BC",e.year=1-e.year)}constructor(){this.identifier="gregory"}}},9405(e,t,r){"use strict";r.d(t,{Ou:()=>w,Tr:()=>f,Yd:()=>h,ay:()=>p,cd:()=>b,gw:()=>m,oU:()=>s,tR:()=>y,uB:()=>g,yP:()=>v});var n=r(5923),a=r(2974),i=r(345),o=r(240);function s(e){return e=v(e,new(0,i.FG)),l((0,i.LA)(e.era,e.year),e.month,e.day,e.hour,e.minute,e.second,e.millisecond)}function l(e,t,r,n,a,i,o){let s=new Date;return s.setUTCHours(n,a,i,o),s.setUTCFullYear(e,t-1,r),s.getTime()}function u(e,t){if("UTC"===t)return 0;if(e>0&&t===(0,o.Xj)()&&!(0,o.rS)())return -6e4*new Date(e).getTimezoneOffset();let{year:r,month:n,day:a,hour:i,minute:s,second:u}=d(e,t);return l(r,n,a,i,s,u,0)-1e3*Math.floor(e/1e3)}let c=new Map;function d(e,t){let r=c.get(t);r||(r=new Intl.DateTimeFormat("en-US",{timeZone:t,hour12:!1,era:"short",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),c.set(t,r));let n=r.formatToParts(new Date(e)),a={};for(let e of n)"literal"!==e.type&&(a[e.type]=e.value);return{year:"BC"===a.era||"B"===a.era?-a.year+1:+a.year,month:+a.month,day:+a.day,hour:"24"===a.hour?0:+a.hour,minute:+a.minute,second:+a.second}}function f(e,t,r="compatible"){var n,a,l;let c=y(e);if("UTC"===t)return s(c);if(t===(0,o.Xj)()&&"compatible"===r&&!(0,o.rS)()){c=v(c,new(0,i.FG));let e=new Date,t=(0,i.LA)(c.era,c.year);return e.setFullYear(t,c.month-1,c.day),e.setHours(c.hour,c.minute,c.second,c.millisecond),e.getTime()}let p=s(c),h=u(p-864e5,t),m=u(p+864e5,t),g=(n=c,((a=p-h)==(l=p-m)?[a]:[a,l]).filter(e=>{var r;let a;return r=n,a=d(e,t),r.year===a.year&&r.month===a.month&&r.day===a.day&&r.hour===a.hour&&r.minute===a.minute&&r.second===a.second}));if(1===g.length)return g[0];if(g.length>1)switch(r){case"compatible":case"earlier":return g[0];case"later":return g[g.length-1];case"reject":throw RangeError("Multiple possible absolute times found")}switch(r){case"earlier":return Math.min(p-h,p-m);case"compatible":case"later":return Math.max(p-h,p-m);case"reject":throw RangeError("No such absolute time found")}}function p(e,t,r="compatible"){return new Date(f(e,t,r))}function h(e,t){let r=u(e,t),a=new Date(e+r),i=a.getUTCFullYear(),o=a.getUTCMonth()+1,s=a.getUTCDate(),l=a.getUTCHours(),c=a.getUTCMinutes(),d=a.getUTCSeconds(),f=a.getUTCMilliseconds();return new(0,n.Ip)(i<1?"BC":"AD",i<1?-i+1:i,o,s,t,r,l,c,d,f)}function m(e){return new(0,n.ng)(e.calendar,e.era,e.year,e.month,e.day)}function y(e,t){let r=0,a=0,i=0,o=0;if("timeZone"in e)({hour:r,minute:a,second:i,millisecond:o}=e);else if("hour"in e&&!t)return e;return t&&({hour:r,minute:a,second:i,millisecond:o}=t),new(0,n._l)(e.calendar,e.era,e.year,e.month,e.day,r,a,i,o)}function v(e,t){if((0,o.Jg)(e.calendar,t))return e;let r=t.fromJulianDay(e.calendar.toJulianDay(e)),n=e.copy();return n.calendar=t,n.era=r.era,n.year=r.year,n.month=r.month,n.day=r.day,(0,a.AU)(n),n}function g(e,t,r){return e instanceof n.Ip?e.timeZone===t?e:x(e,t):h(f(e,t,r),t)}function b(e){return new Date(s(e)-e.offset)}function x(e,t){return v(h(s(e)-e.offset,t),e.calendar)}function w(e){return x(e,(0,o.Xj)())}},227(e,t,r){"use strict";let n,a;r.d(t,{d:()=>X});var i=r(5923),o=r(345);class s extends o.FG{fromJulianDay(e){let t=super.fromJulianDay(e),r=(0,o.LA)(t.era,t.year);return new(0,i.ng)(this,r- -543,t.month,t.day)}toJulianDay(e){return super.toJulianDay(l(e))}getEras(){return["BE"]}getDaysInMonth(e){return super.getDaysInMonth(l(e))}balanceDate(){}constructor(...e){super(...e),this.identifier="buddhist"}}function l(e){let[t,r]=(0,o.f5)(e.year+-543);return new(0,i.ng)(t,r,e.month,e.day)}function u(e,t,r,n){return e+365*t+Math.floor(t/4)+30*(r-1)+n-1}function c(e,t){let r=Math.floor(4*(t-e)/1461);t>=u(e,r+1,1,1)&&r++;let n=1+Math.floor((t-u(e,r,1,1))/30),a=t+1-u(e,r,n,1);return[r,n,a]}function d(e){return Math.floor(e%4/3)}function f(e,t){return t%13!=0?30:d(e)+5}class p{fromJulianDay(e){let[t,r,n]=c(1723856,e),a="AM";return t<=0&&(a="AA",t+=5500),new(0,i.ng)(this,a,t,r,n)}toJulianDay(e){let t=e.year;return"AA"===e.era&&(t-=5500),u(1723856,t,e.month,e.day)}getDaysInMonth(e){return f(e.year,e.month)}getMonthsInYear(){return 13}getDaysInYear(e){return 365+d(e.year)}getMaximumMonthsInYear(){return 13}getMaximumDaysInMonth(){return 30}getYearsInEra(e){return"AA"===e.era?9999:9991}getEras(){return["AA","AM"]}constructor(){this.identifier="ethiopic"}}class h extends p{fromJulianDay(e){let[t,r,n]=c(1723856,e);return t+=5500,new(0,i.ng)(this,"AA",t,r,n)}getEras(){return["AA"]}getYearsInEra(){return 9999}constructor(...e){super(...e),this.identifier="ethioaa"}}class m extends p{fromJulianDay(e){let[t,r,n]=c(1824665,e),a="CE";return t<=0&&(a="BCE",t=1-t),new(0,i.ng)(this,a,t,r,n)}toJulianDay(e){let t=e.year;return"BCE"===e.era&&(t=1-t),u(1824665,t,e.month,e.day)}getDaysInMonth(e){let t=e.year;return"BCE"===e.era&&(t=1-t),f(t,e.month)}isInverseEra(e){return"BCE"===e.era}balanceDate(e){e.year<=0&&(e.era="BCE"===e.era?"CE":"BCE",e.year=1-e.year)}getEras(){return["BCE","CE"]}getYearsInEra(e){return"BCE"===e.era?9999:9715}constructor(...e){super(...e),this.identifier="coptic"}}var y=r(5504);let v=765433;function g(e){return 7>(0,y.z)(7*e+1,19)}function b(e){let t=Math.floor((235*e-234)/19),r=29*t+Math.floor((12084+13753*t)/25920);return 3>(0,y.z)(3*(r+1),7)&&(r+=1),r}function x(e){let t,r;return b(e)+(t=b(e-1),r=b(e),b(e+1)-r==356?2:+(r-t==382))}function w(e){return x(e+1)-x(e)}function S(e,t){if(t>=6&&!g(e)&&t++,4===t||7===t||9===t||11===t||13===t)return 29;let r=function(e){let t=w(e);switch(t>380&&(t-=30),t){case 353:return 0;case 354:return 1;case 355:return 2}}(e);return 2===t?2===r?30:29:3===t?0===r?29:30:6===t?30*!!g(e):30}class j{fromJulianDay(e){let t=e-347997,r=Math.floor((25920*t/v*19+234)/235)+1,n=x(r),a=Math.floor(t-n);for(;a<1;)a=Math.floor(t-(n=x(--r)));let o=1,s=0;for(;s<a;)s+=S(r,o),o++;let l=a-(s-=S(r,--o));return new(0,i.ng)(this,r,o,l)}toJulianDay(e){let t=x(e.year);for(let r=1;r<e.month;r++)t+=S(e.year,r);return t+e.day+347997}getDaysInMonth(e){return S(e.year,e.month)}getMonthsInYear(e){return g(e.year)?13:12}getDaysInYear(e){return w(e.year)}getMaximumMonthsInYear(){return 13}getMaximumDaysInMonth(){return 30}getYearsInEra(){return 9999}getEras(){return["AM"]}balanceYearMonth(e,t){t.year!==e.year&&(g(t.year)&&!g(e.year)&&t.month>6?e.month--:!g(t.year)&&g(e.year)&&t.month>6&&e.month++)}constructor(){this.identifier="hebrew"}}class O extends o.FG{fromJulianDay(e){let t,r,n,a=super.fromJulianDay(e),s=a.year-78,l=e-(0,o.rG)(a.era,a.year,1,1);if(l<80?(s--,l+=(t=(0,o.U_)(a.year-1)?31:30)+155+90+10):(t=(0,o.U_)(a.year)?31:30,l-=80),l<t)r=1,n=l+1;else{let e=l-t;e<155?(r=Math.floor(e/31)+2,n=e%31+1):(e-=155,r=Math.floor(e/30)+7,n=e%30+1)}return new(0,i.ng)(this,s,r,n)}toJulianDay(e){let t,r,n=e.year+78,[a,i]=(0,o.f5)(n);return((0,o.U_)(i)?(t=31,r=(0,o.rG)(a,i,3,21)):(t=30,r=(0,o.rG)(a,i,3,22)),1===e.month)?r+e.day-1:(r+=t+31*Math.min(e.month-2,5),e.month>=8&&(r+=(e.month-7)*30),r+=e.day-1)}getDaysInMonth(e){return 1===e.month&&(0,o.U_)(e.year+78)||e.month>=2&&e.month<=6?31:30}getYearsInEra(){return 9919}getEras(){return["saka"]}balanceDate(){}constructor(...e){super(...e),this.identifier="indian"}}function k(e,t,r,n){return n+Math.ceil(29.5*(r-1))+(t-1)*354+Math.floor((3+11*t)/30)+e-1}function E(e,t,r){let n=Math.floor((30*(r-t)+10646)/10631),a=Math.min(12,Math.ceil((r-(29+k(t,n,1,1)))/29.5)+1),o=r-k(t,n,a,1)+1;return new(0,i.ng)(e,n,a,o)}function P(e){return(14+11*e)%30<11}class A{fromJulianDay(e){return E(this,1948440,e)}toJulianDay(e){return k(1948440,e.year,e.month,e.day)}getDaysInMonth(e){let t=29+e.month%2;return 12===e.month&&P(e.year)&&t++,t}getMonthsInYear(){return 12}getDaysInYear(e){return P(e.year)?355:354}getMaximumMonthsInYear(){return 12}getMaximumDaysInMonth(){return 30}getYearsInEra(){return 9665}getEras(){return["AH"]}constructor(){this.identifier="islamic-civil"}}class D extends A{fromJulianDay(e){return E(this,1948439,e)}toJulianDay(e){return k(1948439,e.year,e.month,e.day)}constructor(...e){super(...e),this.identifier="islamic-tbla"}}function C(e){return 460322+a[e-1300]}function T(e,t){return(n[e-1300]&1<<11-(t-1))==0?29:30}function N(e,t){let r=C(e);for(let n=1;n<t;n++)r+=T(e,n);return r}function R(e){return a[e+1-1300]-a[e-1300]}class M extends A{constructor(){if(super(),this.identifier="islamic-umalqura",n||(n=new Uint16Array(Uint8Array.from(atob("qgpUDckO1AbqBmwDrQpVBakGkgepC9QF2gpcBS0NlQZKB1QLagutBa4ETwoXBYsGpQbVCtYCWwmdBE0KJg2VDawFtgm6AlsKKwWVCsoG6Qr0AnYJtgJWCcoKpAvSC9kF3AJtCU0FpQpSC6ULtAW2CVcFlwJLBaMGUgdlC2oFqworBZUMSg2lDcoF1gpXCasESwmlClILagt1BXYCtwhbBFUFqQW0BdoJ3QRuAjYJqgpUDbIN1QXaAlsJqwRVCkkLZAtxC7QFtQpVCiUNkg7JDtQG6QprCasEkwpJDaQNsg25CroEWworBZUKKgtVC1wFvQQ9Ah0JlQpKC1oLbQW2AjsJmwRVBqkGVAdqC2wFrQpVBSkLkgupC9QF2gpaBasKlQVJB2QHqgu1BbYCVgpNDiULUgtqC60FrgIvCZcESwalBqwG1gpdBZ0ETQoWDZUNqgW1BdoCWwmtBJUFygbkBuoK9QS2AlYJqgpUC9IL2QXqAm0JrQSVCkoLpQuyBbUJ1gSXCkcFkwZJB1ULagVrCisFiwpGDaMNygXWCtsEawJLCaUKUgtpC3UFdgG3CFsCKwVlBbQF2gntBG0BtgimClINqQ3UBdoKWwmrBFMGKQdiB6kLsgW1ClUFJQuSDckO0gbpCmsFqwRVCikNVA2qDbUJugQ7CpsETQqqCtUK2gJdCV4ELgqaDFUNsga5BroEXQotBZUKUguoC7QLuQXaAloJSgukDdEO6AZqC20FNQWVBkoNqA3UDdoGWwWdAisGFQtKC5ULqgWuCi4JjwwnBZUGqgbWCl0FnQI="),e=>e.charCodeAt(0)).buffer)),!a){a=new Uint32Array(301);let e=0;for(let t=1300;t<=1600;t++){a[t-1300]=e;for(let r=1;r<=12;r++)e+=T(t,r)}}}fromJulianDay(e){let t=e-1948440,r=C(1300),n=C(1600);if(t<r||t>n)return super.fromJulianDay(e);{let e=1299,r=1,n=1;for(;n>0;){n=t-C(++e)+1;let a=R(e);if(n===a){r=12;break}if(n<a){let t=T(e,r);for(r=1;n>t;)n-=t,t=T(e,++r);break}}return new(0,i.ng)(this,e,r,t-N(e,r)+1)}}toJulianDay(e){return e.year<1300||e.year>1600?super.toJulianDay(e):1948440+N(e.year,e.month)+(e.day-1)}getDaysInMonth(e){return e.year<1300||e.year>1600?super.getDaysInMonth(e):T(e.year,e.month)}getDaysInYear(e){return e.year<1300||e.year>1600?super.getDaysInYear(e):R(e.year)}}let I=[[1868,9,8],[1912,7,30],[1926,12,25],[1989,1,8],[2019,5,1]],L=[[1912,7,29],[1926,12,24],[1989,1,7],[2019,4,30]],F=[1867,1911,1925,1988,2018],B=["meiji","taisho","showa","heisei","reiwa"];function V(e){let t=I.findIndex(([t,r,n])=>!!(e.year<t)||e.year===t&&!!(e.month<r)||e.year===t&&e.month===r&&!!(e.day<n));return -1===t?I.length-1:0===t?0:t-1}function z(e){let t=F[B.indexOf(e.era)];if(!t)throw Error("Unknown era: "+e.era);return new(0,i.ng)(e.year+t,e.month,e.day)}class W extends o.FG{fromJulianDay(e){let t=super.fromJulianDay(e),r=V(t);return new(0,i.ng)(this,B[r],t.year-F[r],t.month,t.day)}toJulianDay(e){return super.toJulianDay(z(e))}balanceDate(e){let t=z(e),r=V(t);B[r]!==e.era&&(e.era=B[r],e.year=t.year-F[r]),this.constrainDate(e)}constrainDate(e){let t=B.indexOf(e.era),r=L[t];if(null!=r){let[n,a,i]=r,o=n-F[t];e.year=Math.max(1,Math.min(o,e.year)),e.year===o&&(e.month=Math.min(a,e.month),e.month===a&&(e.day=Math.min(i,e.day)))}if(1===e.year&&t>=0){let[,r,n]=I[t];e.month=Math.max(r,e.month),e.month===r&&(e.day=Math.max(n,e.day))}}getEras(){return B}getYearsInEra(e){let t=B.indexOf(e.era),r=I[t],n=I[t+1];if(null==n)return 9999-r[0]+1;let a=n[0]-r[0];return(e.month<n[1]||e.month===n[1]&&e.day<n[2])&&a++,a}getDaysInMonth(e){return super.getDaysInMonth(z(e))}getMinimumMonthInYear(e){let t=$(e);return t?t[1]:1}getMinimumDayInMonth(e){let t=$(e);return t&&e.month===t[1]?t[2]:1}constructor(...e){super(...e),this.identifier="japanese"}}function $(e){if(1===e.year)return I[B.indexOf(e.era)]}let U=[0,31,62,93,124,155,186,216,246,276,306,336];class H{fromJulianDay(e){let t=e-1948320,r=1+Math.floor((33*t+3)/12053),n=t-(365*(r-1)+Math.floor((8*r+21)/33)),a=n<216?Math.floor(n/31):Math.floor((n-6)/30),o=n-U[a]+1;return new(0,i.ng)(this,r,a+1,o)}toJulianDay(e){let t=1948319+365*(e.year-1)+Math.floor((8*e.year+21)/33);return t+=U[e.month-1],t+=e.day}getMonthsInYear(){return 12}getDaysInMonth(e){return e.month<=6?31:e.month<=11||8>(0,y.z)(25*e.year+11,33)?30:29}getMaximumMonthsInYear(){return 12}getMaximumDaysInMonth(){return 31}getEras(){return["AP"]}getYearsInEra(){return 9377}constructor(){this.identifier="persian"}}function G(e){return"minguo"===e.era?e.year+1911:1-e.year+1911}function K(e){let t=e-1911;return t>0?["minguo",t]:["before_minguo",1-t]}class q extends o.FG{fromJulianDay(e){let t=super.fromJulianDay(e),[r,n]=K((0,o.LA)(t.era,t.year));return new(0,i.ng)(this,r,n,t.month,t.day)}toJulianDay(e){return super.toJulianDay(Y(e))}getEras(){return["before_minguo","minguo"]}balanceDate(e){let[t,r]=K(G(e));e.era=t,e.year=r}isInverseEra(e){return"before_minguo"===e.era}getDaysInMonth(e){return super.getDaysInMonth(Y(e))}getYearsInEra(e){return"before_minguo"===e.era?9999:8088}constructor(...e){super(...e),this.identifier="roc"}}function Y(e){let[t,r]=(0,o.f5)(G(e));return new(0,i.ng)(t,r,e.month,e.day)}function X(e){switch(e){case"buddhist":return new s;case"ethiopic":return new p;case"ethioaa":return new h;case"coptic":return new m;case"hebrew":return new j;case"indian":return new O;case"islamic-civil":return new A;case"islamic-tbla":return new D;case"islamic-umalqura":return new M;case"japanese":return new W;case"persian":return new H;case"roc":return new q;default:return new(0,o.FG)}}},2974(e,t,r){"use strict";r.d(t,{AU:()=>u,D8:()=>k,E0:()=>S,Rb:()=>h,Re:()=>d,WQ:()=>i,XH:()=>O,YP:()=>g,d_:()=>j,gt:()=>x,hZ:()=>f,ib:()=>p,tY:()=>v,xy:()=>b});var n=r(9405),a=r(345);function i(e,t){let r=e.copy(),n="hour"in r?y(r,t):0;o(r,t.years||0),r.calendar.balanceYearMonth&&r.calendar.balanceYearMonth(r,e),r.month+=t.months||0,s(r),l(r),r.day+=7*(t.weeks||0),r.day+=t.days||0,r.day+=n,function(e){for(;e.day<1;)e.month--,s(e),e.day+=e.calendar.getDaysInMonth(e);for(;e.day>e.calendar.getDaysInMonth(e);)e.day-=e.calendar.getDaysInMonth(e),e.month++,s(e)}(r),r.calendar.balanceDate&&r.calendar.balanceDate(r),r.year<1&&(r.year=1,r.month=1,r.day=1);let a=r.calendar.getYearsInEra(r);if(r.year>a){let e=r.calendar.isInverseEra?.(r);r.year=a,r.month=e?1:r.calendar.getMonthsInYear(r),r.day=e?1:r.calendar.getDaysInMonth(r)}r.month<1&&(r.month=1,r.day=1);let i=r.calendar.getMonthsInYear(r);return r.month>i&&(r.month=i,r.day=r.calendar.getDaysInMonth(r)),r.day=Math.max(1,Math.min(r.calendar.getDaysInMonth(r),r.day)),r}function o(e,t){e.calendar.isInverseEra?.(e)&&(t=-t),e.year+=t}function s(e){for(;e.month<1;)o(e,-1),e.month+=e.calendar.getMonthsInYear(e);let t=0;for(;e.month>(t=e.calendar.getMonthsInYear(e));)e.month-=t,o(e,1)}function l(e){e.month=Math.max(1,Math.min(e.calendar.getMonthsInYear(e),e.month)),e.day=Math.max(1,Math.min(e.calendar.getDaysInMonth(e),e.day))}function u(e){e.calendar.constrainDate&&e.calendar.constrainDate(e),e.year=Math.max(1,Math.min(e.calendar.getYearsInEra(e),e.year)),l(e)}function c(e){let t={};for(let r in e)"number"==typeof e[r]&&(t[r]=-e[r]);return t}function d(e,t){return i(e,c(t))}function f(e,t){let r=e.copy();return null!=t.era&&(r.era=t.era),null!=t.year&&(r.year=t.year),null!=t.month&&(r.month=t.month),null!=t.day&&(r.day=t.day),u(r),r}function p(e,t){let r=e.copy();return null!=t.hour&&(r.hour=t.hour),null!=t.minute&&(r.minute=t.minute),null!=t.second&&(r.second=t.second),null!=t.millisecond&&(r.millisecond=t.millisecond),h(r),r}function h(e){e.millisecond=Math.max(0,Math.min(e.millisecond,999)),e.second=Math.max(0,Math.min(e.second,59)),e.minute=Math.max(0,Math.min(e.minute,59)),e.hour=Math.max(0,Math.min(e.hour,23))}function m(e,t){let r=e%t;return r<0&&(r+=t),r}function y(e,t){let r;return e.hour+=t.hours||0,e.minute+=t.minutes||0,e.second+=t.seconds||0,e.millisecond+=t.milliseconds||0,e.second+=Math.floor(e.millisecond/1e3),e.millisecond=m(e.millisecond,1e3),e.minute+=Math.floor(e.second/60),e.second=m(e.second,60),e.hour+=Math.floor(e.minute/60),e.minute=m(e.minute,60),r=Math.floor(e.hour/24),e.hour=m(e.hour,24),r}function v(e,t){let r=e.copy();return y(r,t),r}function g(e,t){return v(e,c(t))}function b(e,t,r,n){let a=e.copy();switch(t){case"era":{let t=e.calendar.getEras(),i=t.indexOf(e.era);if(i<0)throw Error("Invalid era: "+e.era);i=w(i,r,0,t.length-1,n?.round),a.era=t[i],u(a);break}case"year":a.calendar.isInverseEra?.(a)&&(r=-r),a.year=w(e.year,r,-1/0,9999,n?.round),a.year===-1/0&&(a.year=1),a.calendar.balanceYearMonth&&a.calendar.balanceYearMonth(a,e);break;case"month":a.month=w(e.month,r,1,e.calendar.getMonthsInYear(e),n?.round);break;case"day":a.day=w(e.day,r,1,e.calendar.getDaysInMonth(e),n?.round);break;default:throw Error("Unsupported field "+t)}return e.calendar.balanceDate&&e.calendar.balanceDate(a),u(a),a}function x(e,t,r,n){let a=e.copy();switch(t){case"hour":{let t=e.hour,i=0,o=23;if(n?.hourCycle===12){let e=t>=12;i=12*!!e,o=e?23:11}a.hour=w(t,r,i,o,n?.round);break}case"minute":a.minute=w(e.minute,r,0,59,n?.round);break;case"second":a.second=w(e.second,r,0,59,n?.round);break;case"millisecond":a.millisecond=w(e.millisecond,r,0,999,n?.round);break;default:throw Error("Unsupported field "+t)}return a}function w(e,t,r,n,a=!1){if(a){(e+=Math.sign(t))<r&&(e=n);let a=Math.abs(t);(e=t>0?Math.ceil(e/a)*a:Math.floor(e/a)*a)>n&&(e=r)}else(e+=t)<r?e=n-(r-e-1):e>n&&(e=r+(e-n-1));return e}function S(e,t){let r;if(null!=t.years&&0!==t.years||null!=t.months&&0!==t.months||null!=t.weeks&&0!==t.weeks||null!=t.days&&0!==t.days){let a=i((0,n.tR)(e),{years:t.years,months:t.months,weeks:t.weeks,days:t.days});r=(0,n.Tr)(a,e.timeZone)}else r=(0,n.oU)(e)-e.offset;r+=t.milliseconds||0,r+=1e3*(t.seconds||0),r+=6e4*(t.minutes||0),r+=36e5*(t.hours||0);let a=(0,n.Yd)(r,e.timeZone);return(0,n.yP)(a,e.calendar)}function j(e,t){return S(e,c(t))}function O(e,t,r,i){switch(t){case"hour":{let t=0,o=23;if(i?.hourCycle===12){let r=e.hour>=12;t=12*!!r,o=r?23:11}let s=(0,n.tR)(e),l=(0,n.yP)(p(s,{hour:t}),new(0,a.FG)),u=[(0,n.Tr)(l,e.timeZone,"earlier"),(0,n.Tr)(l,e.timeZone,"later")].filter(t=>(0,n.Yd)(t,e.timeZone).day===l.day)[0],c=(0,n.yP)(p(s,{hour:o}),new(0,a.FG)),d=[(0,n.Tr)(c,e.timeZone,"earlier"),(0,n.Tr)(c,e.timeZone,"later")].filter(t=>(0,n.Yd)(t,e.timeZone).day===c.day).pop(),f=(0,n.oU)(e)-e.offset,h=Math.floor(f/36e5),m=f%36e5;return f=36e5*w(h,r,Math.floor(u/36e5),Math.floor(d/36e5),i?.round)+m,(0,n.yP)((0,n.Yd)(f,e.timeZone),e.calendar)}case"minute":case"second":case"millisecond":return x(e,t,r,i);case"era":case"year":case"month":case"day":{let a=b((0,n.tR)(e),t,r,i),o=(0,n.Tr)(a,e.timeZone);return(0,n.yP)((0,n.Yd)(o,e.timeZone),e.calendar)}default:throw Error("Unsupported field "+t)}}function k(e,t,r){let a=(0,n.tR)(e),i=p(f(a,t),t);if(0===i.compare(a))return e;let o=(0,n.Tr)(i,e.timeZone,r);return(0,n.yP)((0,n.Yd)(o,e.timeZone),e.calendar)}},240(e,t,r){"use strict";r.d(t,{p9:()=>w,$I:()=>O,RZ:()=>P,tB:()=>f,rS:()=>b,kq:()=>j,Jg:()=>l,Py:()=>A,tF:()=>o,Xj:()=>g,Nu:()=>m,SJ:()=>d,SE:()=>h,ro:()=>i,D:()=>S,ZI:()=>D,Ec:()=>p,cK:()=>u,NV:()=>s,wH:()=>x});var n=r(9405);let a={"001":1,AD:1,AE:6,AF:6,AI:1,AL:1,AM:1,AN:1,AR:1,AT:1,AU:1,AX:1,AZ:1,BA:1,BE:1,BG:1,BH:6,BM:1,BN:1,BY:1,CH:1,CL:1,CM:1,CN:1,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DZ:6,EC:1,EE:1,EG:6,ES:1,FI:1,FJ:1,FO:1,FR:1,GB:1,GE:1,GF:1,GP:1,GR:1,HR:1,HU:1,IE:1,IQ:6,IR:6,IS:1,IT:1,JO:6,KG:1,KW:6,KZ:1,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MK:1,MN:1,MQ:1,MV:5,MY:1,NL:1,NO:1,NZ:1,OM:6,PL:1,QA:6,RE:1,RO:1,RS:1,RU:1,SD:6,SE:1,SI:1,SK:1,SM:1,SY:6,TJ:1,TM:1,TR:1,UA:1,UY:1,UZ:1,VA:1,VN:1,XK:1};function i(e,t){return t=(0,n.yP)(t,e.calendar),e.era===t.era&&e.year===t.year&&e.month===t.month&&e.day===t.day}function o(e,t){return t=(0,n.yP)(t,e.calendar),e=x(e),t=x(t),e.era===t.era&&e.year===t.year&&e.month===t.month}function s(e,t){return l(e.calendar,t.calendar)&&i(e,t)}function l(e,t){return e.isEqual?.(t)??t.isEqual?.(e)??e.identifier===t.identifier}function u(e,t){return i(e,p(t))}let c={sun:0,mon:1,tue:2,wed:3,thu:4,fri:5,sat:6};function d(e,t,r){let n=Math.ceil(e.calendar.toJulianDay(e)+1-(r?c[r]:function(e){let t=E.get(e);if(!t){if(Intl.Locale){let r=new Intl.Locale(e);if("getWeekInfo"in r&&(t=r.getWeekInfo()))return E.set(e,t),t.firstDay}let r=function(e){if(Intl.Locale){let t=k.get(e);return!t&&(t=new Intl.Locale(e).maximize().region)&&k.set(e,t),t}let t=e.split("-")[1];return"u"===t?void 0:t}(e);if(e.includes("-fw-")){let r=e.split("-fw-")[1].split("-")[0];t="mon"===r?{firstDay:1}:"tue"===r?{firstDay:2}:"wed"===r?{firstDay:3}:"thu"===r?{firstDay:4}:"fri"===r?{firstDay:5}:"sat"===r?{firstDay:6}:{firstDay:0}}else t=e.includes("-ca-iso8601")?{firstDay:1}:{firstDay:r&&a[r]||0};E.set(e,t)}return t.firstDay}(t)))%7;return n<0&&(n+=7),n}function f(e){return(0,n.Yd)(Date.now(),e)}function p(e){return(0,n.gw)(f(e))}function h(e,t){return e.calendar.toJulianDay(e)-t.calendar.toJulianDay(t)}function m(e,t){return y(e)-y(t)}function y(e){return 36e5*e.hour+6e4*e.minute+1e3*e.second+e.millisecond}let v=null;function g(){return null==v&&(v=new Intl.DateTimeFormat().resolvedOptions().timeZone),v}function b(){return!1}function x(e){return e.subtract({days:e.day-1})}function w(e){return e.add({days:e.calendar.getDaysInMonth(e)-e.day})}function S(e){return x(e.subtract({months:e.month-1}))}function j(e,t,r){let n=d(e,t,r);return e.subtract({days:n})}function O(e,t,r){return j(e,t,r).add({days:6})}let k=new Map,E=new Map;function P(e,t,r){let n=e.calendar.getDaysInMonth(e);return Math.ceil((d(x(e),t,r)+n)/7)}function A(e,t){return e&&t?0>=e.compare(t)?e:t:e||t}function D(e,t){return e&&t?e.compare(t)>=0?e:t:e||t}},2298(e,t,r){"use strict";r.d(t,{$T:()=>p,DP:()=>c,_U:()=>u,e6:()=>m,ot:()=>f,qk:()=>h});var n=r(5923),a=r(9405),i=r(345);let o=/^([+-]\d{6}|\d{4})-(\d{2})-(\d{2})$/,s=/^([+-]\d{6}|\d{4})-(\d{2})-(\d{2})(?:T(\d{2}))?(?::(\d{2}))?(?::(\d{2}))?(\.\d+)?$/,l=/^([+-]\d{6}|\d{4})-(\d{2})-(\d{2})(?:T(\d{2}))?(?::(\d{2}))?(?::(\d{2}))?(\.\d+)?(?:(?:([+-]\d{2})(?::?(\d{2}))?)|Z)$/;function u(e){let t=e.match(o);if(!t){if(l.test(e))throw Error(`Invalid ISO 8601 date string: ${e}. Use parseAbsolute() instead.`);throw Error("Invalid ISO 8601 date string: "+e)}let r=new(0,n.ng)(d(t[1],0,9999),d(t[2],1,12),1);return r.day=d(t[3],1,r.calendar.getDaysInMonth(r)),r}function c(e){let t=e.match(s);if(!t){if(l.test(e))throw Error(`Invalid ISO 8601 date time string: ${e}. Use parseAbsolute() instead.`);throw Error("Invalid ISO 8601 date time string: "+e)}let r=d(t[1],-9999,9999),a=new(0,n._l)(r<1?"BC":"AD",r<1?-r+1:r,d(t[2],1,12),1,t[4]?d(t[4],0,23):0,t[5]?d(t[5],0,59):0,t[6]?d(t[6],0,59):0,t[7]?1e3*d(t[7],0,1/0):0);return a.day=d(t[3],0,a.calendar.getDaysInMonth(a)),a}function d(e,t,r){let n=Number(e);if(n<t||n>r)throw RangeError(`Value out of range: ${t} <= ${n} <= ${r}`);return n}function f(e){return`${String(e.hour).padStart(2,"0")}:${String(e.minute).padStart(2,"0")}:${String(e.second).padStart(2,"0")}${e.millisecond?String(e.millisecond/1e3).slice(1):""}`}function p(e){let t,r=(0,a.yP)(e,new(0,i.FG));return t="BC"===r.era?1===r.year?"0000":"-"+String(Math.abs(1-r.year)).padStart(6,"00"):String(r.year).padStart(4,"0"),`${t}-${String(r.month).padStart(2,"0")}-${String(r.day).padStart(2,"0")}`}function h(e){return`${p(e)}T${f(e)}`}function m(e){var t;let r,n,a,i,o;return`${h(e)}${r=0>Math.sign(t=e.offset)?"-":"+",n=Math.floor((t=Math.abs(t))/36e5),a=Math.floor(t%36e5/6e4),i=Math.floor(t%36e5%6e4/1e3),o=`${r}${String(n).padStart(2,"0")}:${String(a).padStart(2,"0")}`,0!==i&&(o+=`:${String(i).padStart(2,"0")}`),o}[${e.timeZone}]`}},5504(e,t,r){"use strict";function n(e,t){return e-t*Math.floor(e/t)}r.d(t,{z:()=>n})},7064(e,t,r){"use strict";function n(){for(var e,t,r=0,n="",a=arguments.length;r<a;r++)(e=arguments[r])&&(t=function e(t){var r,n,a="";if("string"==typeof t||"number"==typeof t)a+=t;else if("object"==typeof t)if(Array.isArray(t)){var i=t.length;for(r=0;r<i;r++)t[r]&&(n=e(t[r]))&&(a&&(a+=" "),a+=n)}else for(n in t)t[n]&&(a&&(a+=" "),a+=n);return a}(e))&&(n&&(n+=" "),n+=t);return n}r.d(t,{$:()=>n,A:()=>a});let a=n},1400(e,t,r){"use strict";r.d(t,{A:()=>o});for(var n=new Uint8Array(16),a=[],i=0;i<256;++i)a.push((i+256).toString(16).slice(1));let o=function(e,t,r){return t||e||!crypto.randomUUID?function(e,t,r){var i,o,s,l=null!=(i=null!=(o=(e=e||{}).random)?o:null==(s=e.rng)?void 0:s.call(e))?i:crypto.getRandomValues(n);if(l.length<16)throw Error("Random bytes length must be >= 16");if(l[6]=15&l[6]|64,l[8]=63&l[8]|128,t){if((r=r||0)<0||r+16>t.length)throw RangeError("UUID byte range ".concat(r,":").concat(r+15," is out of buffer bounds"));for(var u=0;u<16;++u)t[r+u]=l[u];return t}return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(a[e[t+0]]+a[e[t+1]]+a[e[t+2]]+a[e[t+3]]+"-"+a[e[t+4]]+a[e[t+5]]+"-"+a[e[t+6]]+a[e[t+7]]+"-"+a[e[t+8]]+a[e[t+9]]+"-"+a[e[t+10]]+a[e[t+11]]+a[e[t+12]]+a[e[t+13]]+a[e[t+14]]+a[e[t+15]]).toLowerCase()}(l)}(e,t,r):crypto.randomUUID()}},99(e,t,r){"use strict";r.d(t,{Ln:()=>p,Yv:()=>c,rL:()=>d,zC:()=>f});var n=r(9726),a=r(5565),i=r(8048);function o(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function s(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function s(e){o(i,n,a,s,l,"next",e)}function l(e){o(i,n,a,s,l,"throw",e)}s(void 0)})}}function l(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function u(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}function c(e){return e.replace(/[\/\-@]/g,"_")}function d(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"./start",n=arguments.length>2?arguments[2]:void 0;return s(function(){var a,i,o,s,d,p,h;return u(this,function(u){switch(u.label){case 0:return a=(null==n?void 0:n.maxLoadingTime)&&!(n.maxLoadingTime<=0)?n.maxLoadingTime:6e5,i=void 0,[4,Promise.race([f(e,null==n?void 0:n.importMap),new Promise(function(t,r){i=setTimeout(function(){var t;r(Error("Could not resolve requested script, ".concat(e,", within ").concat((t=a)<1e3?"".concat(t," milliseconds"):t<6e4?"".concat(Math.floor(t/1e3)," seconds"):t<36e5?"".concat(Math.floor(t/6e4)," minutes"):t<864e5?"".concat(Math.floor(t/36e5)," hours"):"".concat(Math.floor(t/864e5)," days"),".")))},a)})])];case 1:var m;if(u.sent(),i&&clearTimeout(i),o=c(e),!((void 0===(m=s=window[o])?"undefined":l(m))==="object"&&null!==m&&"init"in m&&"function"==typeof m.init&&"get"in m&&"function"==typeof m.get))throw console.error(d="The global variable ".concat(o," does not refer to a federated module")),Error(d);return s.init(r.S.default),[4,s.get(t)];case 2:if((void 0===(p=u.sent()())?"undefined":l(p))!=="object"||null===p)throw console.error(h="Container for ".concat(e," did not return an ESM module as expected")),Error(h);return[2,p]}})})()}function f(e,t){return s(function(){var r,o,s,l,d,f,m;return u(this,function(u){switch(u.label){case 0:if("string"!=typeof e||0===e.trim().length)throw console.error("Attempted to call importDynamic() without supplying a package to load"),Error("Attempted to call importDynamic() without supplying a package to load");if(r=c(e),window[r])return[3,7];if(null==t)return[3,1];return s=t,[3,3];case 1:return[4,p()];case 2:s=u.sent(),u.label=3;case 3:if(!(o=s).imports.hasOwnProperty(e))throw console.error(l="Could not find the package ".concat(e," defined in the current importmap")),Error(l);(d=o.imports[e]).startsWith("./")&&(d=window.spaBase+d.substring(1)),f=e in(0,i.uT)().imports,u.label=4;case 4:return u.trys.push([4,6,,7]),[4,new Promise(function(e,t){!function(e,t,r){var n,a,i,o=document.head.querySelector('script[src="'.concat(e,'"]')),s=window[h];if(s||(s=window[h]=new Set([])),o)s.has(e)?(i=function(){n&&o.removeEventListener("load",n),a&&o.removeEventListener("error",a)},n=function(){i(),t(null)},a=function(e){i(),r(e.message)},o.addEventListener("load",n),o.addEventListener("error",a)):(console.warn("Script at ".concat(e," already loaded. Not loading it again.")),t(null));else{s.add(e);var l,u,c,d=document.createElement("script");d.src=e,d.type="text/javascript",d.async=!0;var f=setTimeout(function(){console.error("The script at ".concat(e," did not load within 5 seconds. This may indicate an issue with the imports in the script's entry-point file or with the script's bundler configuration."))},5e3);c=function(){clearTimeout(f),s.delete(e),l&&d.removeEventListener("load",l),u&&d.removeEventListener("error",u)},l=function(){c(),t(null)},u=function(t){c();var n,a="Failed to load script from ".concat(e);console.error(a,t),r(null!=(n=t.message)?n:a)},d.addEventListener("load",l),d.addEventListener("error",u),document.head.appendChild(d)}}(d,e,t)})];case 5:return[2,u.sent()];case 6:return m=u.sent(),f&&(0,n.Vt)({kind:"error",title:(0,a.V)("scriptLoadingFailed","Error: Script failed to load"),description:(0,a.V)("scriptLoadingError","Failed to load overridden script from {{- url}}. Please check that the bundled script is available at the expected URL. Click the button below to reset all import map overrides.",{url:d}),actionButtonLabel:(0,a.V)("resetOverrides","Reset overrides"),onActionButtonClick:function(){(0,i.w_)(),window.location.reload()}}),[2,Promise.reject(m)];case 7:return[2,Promise.resolve()]}})})()}function p(){return s(function(){return u(this,function(e){return[2,(0,i.F$)()]})})()}var h=Symbol("__egen_script_loading")},8048(e,t,r){"use strict";r.d(t,{BX:()=>O,E:()=>S,F$:()=>m,SM:()=>E,fd:()=>w,o5:()=>v,q1:()=>x,tK:()=>y,uT:()=>g,w_:()=>j,xI:()=>b});var n=r(3766);function a(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function i(e){return function(){var t=this,r=arguments;return new Promise(function(n,i){var o=e.apply(t,r);function s(e){a(o,n,i,s,l,"next",e)}function l(e){a(o,n,i,s,l,"throw",e)}s(void 0)})}}function o(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var s="import-map-override:",l="import-map-overrides-disabled",u="import-map-overrides:change",c=!1,d=null;function f(){return i(function(){var e,t,r,n,a,i,s;return o(this,function(o){switch(o.label){case 0:e=document.querySelectorAll('script[type="systemjs-importmap"]'),t=[],r=0,o.label=1;case 1:if(!(r<e.length))return[3,9];n=e[r],o.label=2;case 2:if(o.trys.push([2,7,,8]),!n.src)return[3,5];return[4,fetch(n.src)];case 3:return a=o.sent(),i=t.push,[4,a.json()];case 4:return i.apply(t,[o.sent()]),[3,6];case 5:n.textContent&&t.push(JSON.parse(n.textContent)),o.label=6;case 6:return[3,8];case 7:return s=o.sent(),console.warn("[import-maps] Failed to parse import map from script tag at index ".concat(r),s),[3,8];case 8:return r++,[3,1];case 9:return[2,p(t)]}})})()}function p(e){var t={imports:{}},r=!0,n=!1,a=void 0;try{for(var i,o=e[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s=i.value;(null==s?void 0:s.imports)&&Object.assign(t.imports,s.imports)}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}return t}function h(){var e={};try{for(var t=b(),r=0;r<localStorage.length;r++){var n=localStorage.key(r);if(null==n?void 0:n.startsWith(s)){var a=n.slice(s.length);if(!t.includes(a)){var i=localStorage.getItem(n);i&&(e[a]=i)}}}}catch(e){console.warn("[import-maps] Failed to read import-map overrides from localStorage",e)}return{imports:e}}function m(){return i(function(){var e;return o(this,function(t){switch(t.label){case 0:return[4,f()];case 1:if(e=t.sent(),!c)return[2,e];return[2,p([e,null!=d?d:h()])]}})})()}function y(){return i(function(){return o(this,function(e){return[2,f()]})})()}function v(){return i(function(){return o(this,function(e){switch(e.label){case 0:if(!c)return[2,f()];return[4,f()];case 1:return[2,p([e.sent(),h()])]}})})()}function g(e){if(!c)return{imports:{}};if(e){for(var t={},r=0;r<localStorage.length;r++){var n=localStorage.key(r);if(null==n?void 0:n.startsWith(s)){var a=localStorage.getItem(n);a&&(t[n.slice(s.length)]=a)}}return{imports:t}}return h()}function b(){if(!c)return[];try{var e=localStorage.getItem(l);if(e){var t=JSON.parse(e);if(Array.isArray(t))return t}}catch(e){}return[]}function x(e){return!!c&&b().includes(e)}function w(e,t){if(!c)return void console.warn("[Security] Import map overrides are disabled in production mode.");try{localStorage.setItem(s+e,t),window.dispatchEvent(new CustomEvent(u))}catch(e){console.warn("[import-maps] Failed to write import-map override to localStorage",e)}}function S(e){if(!c)return void console.warn("[Security] Import map overrides are disabled in production mode.");try{localStorage.removeItem(s+e);var t=b().filter(function(t){return t!==e});t.length>0?localStorage.setItem(l,JSON.stringify(t)):localStorage.removeItem(l),window.dispatchEvent(new CustomEvent(u))}catch(e){console.warn("[import-maps] Failed to update import-map overrides in localStorage",e)}}function j(){if(!c)return void console.warn("[Security] Import map overrides are disabled in production mode.");try{for(var e=[],t=0;t<localStorage.length;t++){var r=localStorage.key(t);(null==r?void 0:r.startsWith(s))&&e.push(r)}e.forEach(function(e){return localStorage.removeItem(e)}),localStorage.removeItem(l),window.dispatchEvent(new CustomEvent(u))}catch(e){console.warn("[import-maps] Failed to clear import-map overrides from localStorage",e)}}function O(e){if(!c)return void console.warn("[Security] Import map overrides are disabled in production mode.");try{var t=b().filter(function(t){return t!==e});t.length>0?localStorage.setItem(l,JSON.stringify(t)):localStorage.removeItem(l),window.dispatchEvent(new CustomEvent(u))}catch(e){console.warn("[import-maps] Failed to update import-map overrides in localStorage",e)}}var k=!1;function E(){!k&&(k=!0,(c="development"===window.spaEnv&&!(0,n.$)())&&(d=h()))}},101(e,t,r){"use strict";r.d(t,{xI:()=>a.xI,E:()=>a.E,eH:()=>j,SM:()=>a.SM,zU:()=>g,BX:()=>a.BX,w_:()=>a.w_,Y6:()=>b,Yv:()=>n.Yv,tK:()=>a.tK,Ln:()=>n.Ln,FM:()=>v,o5:()=>a.o5,fd:()=>a.fd,Tx:()=>w,KI:()=>S,rL:()=>n.rL,WY:()=>x,F$:()=>a.F$,zC:()=>n.zC,_m:()=>k,q1:()=>a.q1,uT:()=>a.uT});var n=r(99),a=r(8048),i=r(2235),o=r(3766);function s(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function l(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){s(i,n,a,o,l,"next",e)}function l(e){s(i,n,a,o,l,"throw",e)}o(void 0)})}}function u(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var c="egen-routes:",d="egen-routes:change",f=!1,p=null;function h(){return l(function(){var e,t,r,n,a,o;return u(this,function(s){switch(s.label){case 0:e=document.querySelectorAll("script[type='egen-routes']"),t=[],r=0,s.label=1;case 1:if(!(r<e.length))return[3,9];n=e[r],s.label=2;case 2:if(s.trys.push([2,7,,8]),a=void 0,!n.src)return[3,5];return[4,fetch(n.src)];case 3:return[4,s.sent().json()];case 4:return a=s.sent(),[3,6];case 5:n.textContent&&(a=JSON.parse(n.textContent)),s.label=6;case 6:return a&&(0,i.S)(a)&&t.push(a),[3,8];case 7:return o=s.sent(),console.warn("[route-maps] Failed to parse routes from script tag at index ".concat(r),o),[3,8];case 8:return r++,[3,1];case 9:return[2,m(t)]}})})()}function m(e){var t={},r=!0,n=!1,a=void 0;try{for(var i,o=e[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s=i.value;s&&(void 0===s?"undefined":s&&"u">typeof Symbol&&s.constructor===Symbol?"symbol":typeof s)=="object"&&Object.assign(t,s)}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}return t}function y(){return l(function(){var e,t,r,n,a,o,s,d,f,p,h,m;return u(this,function(y){switch(y.label){case 0:e={},y.label=1;case 1:for(y.trys.push([1,3,,4]),t=[],r=0;r<localStorage.length;r++)(null==(n=localStorage.key(r))?void 0:n.startsWith(c))&&(a=localStorage.getItem(n))&&t.push({moduleName:n.slice(c.length),raw:a});return[4,Promise.allSettled(t.map(function(e){var t=e.moduleName,r=e.raw;return l(function(){var e,n;return u(this,function(a){switch(a.label){case 0:if(e=JSON.parse(r),(0,i.j)(e))return[2,{moduleName:t,routes:e}];if(!("string"==typeof e&&e.startsWith("http")))return[3,3];return[4,fetch(e)];case 1:return[4,a.sent().json()];case 2:if(n=a.sent(),(0,i.j)(n))return[2,{moduleName:t,routes:n}];throw Error("".concat(e," did not resolve to a valid EgenAppRoutes object"));case 3:throw Error("Override for ".concat(t," is neither a valid routes object nor a URL"))}})})()}))];case 2:o=y.sent(),s=!0,d=!1,f=void 0;try{for(p=o[Symbol.iterator]();!(s=(h=p.next()).done);s=!0)m=h.value,"fulfilled"===m.status?e[m.value.moduleName]=m.value.routes:console.warn("[route-maps] Failed to load route override",m.reason)}catch(e){d=!0,f=e}finally{try{s||null==p.return||p.return()}finally{if(d)throw f}}return[3,4];case 3:return console.warn("[route-maps] Failed to read route overrides from localStorage",y.sent()),[3,4];case 4:return[2,e]}})})()}function v(){return l(function(){var e,t;return u(this,function(r){switch(r.label){case 0:return[4,h()];case 1:if(e=r.sent(),!f)return[2,e];if(null==p)return[3,2];return t=p,[3,4];case 2:return[4,y()];case 3:t=r.sent(),r.label=4;case 4:return[2,m([e,t])]}})})()}function g(){return l(function(){return u(this,function(e){return[2,h()]})})()}function b(){return l(function(){var e;return u(this,function(t){switch(t.label){case 0:if(!f)return[2,h()];return[4,h()];case 1:return e=[t.sent()],[4,y()];case 2:return[2,m.apply(void 0,[e.concat([t.sent()])])]}})})()}function x(){if(!f)return{};var e={};try{for(var t=0;t<localStorage.length;t++){var r=localStorage.key(t);if(null==r?void 0:r.startsWith(c)){var n=localStorage.getItem(r);n&&(e[r.slice(c.length)]=n)}}}catch(e){console.warn("[route-maps] Failed to read route overrides from localStorage",e)}return e}function w(e,t){if(!f)return void console.warn("[Security] Route overrides are disabled outside development mode.");try{if("string"==typeof t)if(t.startsWith("http"))localStorage.setItem(c+e,JSON.stringify(t));else{var r,n=JSON.parse(t);if(!(0,i.j)(n))return void console.error("The supplied routes for ".concat(e," is not a valid EgenAppRoutes object"),t);localStorage.setItem(c+e,JSON.stringify(n))}else if(r=URL,null!=r&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](t):t instanceof r)localStorage.setItem(c+e,JSON.stringify(t.toString()));else{if(!(0,i.j)(t))return void console.error("Override for ".concat(e," is not in a valid format. Expected either a Javascript Object, a JSON string of a Javascript object, or a URL"),t);localStorage.setItem(c+e,JSON.stringify(t))}window.dispatchEvent(new CustomEvent(d))}catch(e){console.warn("[route-maps] Failed to write route override to localStorage",e)}}function S(e){if(!f)return void console.warn("[Security] Route overrides are disabled outside development mode.");try{localStorage.removeItem(c+e),window.dispatchEvent(new CustomEvent(d))}catch(e){console.warn("[route-maps] Failed to remove route override from localStorage",e)}}function j(){if(!f)return void console.warn("[Security] Route overrides are disabled outside development mode.");try{for(var e=[],t=0;t<localStorage.length;t++){var r=localStorage.key(t);(null==r?void 0:r.startsWith(c))&&e.push(r)}e.forEach(function(e){return localStorage.removeItem(e)}),window.dispatchEvent(new CustomEvent(d))}catch(e){console.warn("[route-maps] Failed to clear route overrides from localStorage",e)}}var O=null;function k(){return O||(O=(f="development"===window.spaEnv&&!(0,o.$)())?y().then(function(e){p=e}):Promise.resolve())}},8507(e,t,r){"use strict";r.d(t,{J:()=>i,N:()=>a});var n=r(9726);function a(e){var t=o(e);setTimeout(function(){throw t})}function i(){var e=Error();return function(t){var r=o(t);r.stack+="\nAsync stacktrace:\n".concat(e.stack),a(t)}}function o(e){var t,r;if(null!=(r=Error)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](e):e instanceof r)return e;if(null===e)return Error("'null' was thrown as an error");if((void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"){try{t="Object thrown as error: ".concat(JSON.stringify(e))}catch(r){t="Object thrown as error with the following properties: ".concat(Object.keys(e))}return Error(t)}if(void 0===e)return Error("'undefined' was thrown as an error");return Error(e.toString())}window.onerror=function(e){return console.error("Unexpected error: ",e),(0,n.Vt)({description:null!=e?e:"Oops! An unexpected error occurred.",kind:"error",title:"Error"}),!1},window.onunhandledrejection=function(e){var t;console.error("Unhandled rejection: ",e.reason),(0,n.Vt)({description:null!=(t=e.reason)?t:"Oops! An unhandled promise rejection occurred.",kind:"error",title:"Error"})}},9360(e,t,r){"use strict";r.d(t,{dX:()=>n.dX,wE:()=>n.wE,_3:()=>n._3,uN:()=>n.uN,$F:()=>n.$F,Gz:()=>n.Gz,eb:()=>n.eb,Sj:()=>n.Sj,mv:()=>n.mv,yp:()=>l,PQ:()=>n.PQ});var n=r(6014),a=r(4356),i=r(4693);function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function s(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function l(e){if("string"!=typeof e&&((void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)!="object"||!e||!("type"in e)))throw"Unknown expression type ".concat(e,". Expressions must either be a string or pre-compiled string.");var t,r={globals:s({},i.f),isLocalExpression:!1,variables:new Set};return u("string"==typeof e?(0,a.A)(e):e,r),function(e){if(Array.isArray(e))return o(e)}(t=r.variables)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||function(e){if(e){if("string"==typeof e)return o(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return o(e,void 0)}}(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){switch(e.type){case"UnaryExpression":return r=e,n=t,u(r.argument,n);case"BinaryExpression":return a=e,i=t,[u(a.left,i),u(a.right,i)].filter(Boolean);case"ConditionalExpression":return o=e,l=t,[u(o.consequent,l),u(o.test,l),u(o.alternate,l)].filter(Boolean);case"CallExpression":return d=e,f=t,h=u(d.callee,f),null==(p=d.arguments)||p.map(c(f)),h;case"ArrowFunctionExpression":return function(e,t){var r=s({},t);r.isLocalExpression=!0;var n=null!=(d=null==(p=e.params)?void 0:p.map(c(r)))?d:[],a=null!=(f=u(e.body,r))?f:[];if(a&&Array.isArray(a)){var i=!0,o=!1,l=void 0;try{for(var d,f,p,h,m=a[Symbol.iterator]();!(i=(h=m.next()).done);i=!0){var y=h.value;n.includes(y)||t.variables.add(y)}}catch(e){o=!0,l=e}finally{try{i||null==m.return||m.return()}finally{if(o)throw l}}}}(e,t);case"MemberExpression":return m=e,y=t,u(m.object,y),void((v=s({},y)).isLocalExpression=!0,u(m.property,v));case"ArrayExpression":return g=e,b=t,void(null==(x=g.elements)||x.map(c(b)));case"SequenceExpression":return w=e,S=t,void(null==(j=w.expressions)||j.map(c(S)));case"NewExpression":return O=e,k=t,void(null==(E=O.arguments)||E.map(c(k)));case"Literal":case"TemplateElement":return;case"Identifier":var r,n,a,i,o,l,d,f,p,h,m,y,v,g,b,x,w,S,j,O,k,E,P,A,D,C,T=e,N=t;if(!(T.name in N.globals))if(N.isLocalExpression)return T.name;else N.variables.add(T.name);return;case"TemplateLiteral":return P=e,A=t,void(null==(D=P.expressions)||D.map(c(A)),null==(C=P.quasis)||C.map(c(A)));default:throw"Expression evaluator does not support expression of type '".concat(e.type,"'")}}function c(e){return function(t){return null===t?null:u(t,e)}}},8162(e,t,r){"use strict";r.r(t),r.d(t,{ASSISTANT_MODES:()=>b.wJ8,ActionMenu:()=>b.WyE,ActionMenuButton:()=>b.EDM,ActionMenuButton2:()=>b.Wjo,ActionableNotificationComponent:()=>b.drd,ActivityIcon:()=>b.npY,AddIcon:()=>b.REV,AnimatedHomeBackground:()=>b.BpM,ArrowDownIcon:()=>b.ZLN,ArrowLeftIcon:()=>b.A60,ArrowRightIcon:()=>b.flY,ArrowUpIcon:()=>b.Kpk,AssistantRobotScene:()=>b.JvV,AsyncSelect:()=>b.DWK,AttachmentIcon:()=>b.PtA,Autocomplete:()=>b.jT8,Breakpoint:()=>b.EA,CalendarHeatMapIcon:()=>b.mmM,CalendarIcon:()=>b.CTc,CardHeader:()=>b.aRn,CardModal:()=>b.oVc,CardModalWarpGlow:()=>b.F$l,CaretDownIcon:()=>b.bDP,CaretLeftIcon:()=>b.eCO,CaretRightIcon:()=>b.JJd,CaretUpIcon:()=>b.SwV,Carousel:()=>b.FNf,CarouselContext:()=>b.Ycj,CascadingNavDropdown:()=>b._PX,ChartAverageIcon:()=>b.ZHE,ChartLineIcon:()=>b.SCH,CheckmarkFilledIcon:()=>b.FtQ,CheckmarkOutlineIcon:()=>b.pm$,ChevronDownIcon:()=>b.D3D,ChevronLeftIcon:()=>b.YJP,ChevronRightIcon:()=>b.vKP,ChevronUpIcon:()=>b.Mtm,CircularGallery:()=>b.GF9,ClassificationTags:()=>b.QpY,CloseFilledIcon:()=>b.oCk,CloseIcon:()=>b.USm,CloseOutlineIcon:()=>b.Wdn,ColumnWithSearch:()=>b.Fny,Combobox:()=>b.G3_,CompartmentSplitter:()=>b.i_j,ContentSection:()=>b.Fe_,CornerSplitter:()=>b.rGP,CustomOverflowMenu:()=>b.TQT,CustomOverflowMenuItem:()=>b.cxd,DEFAULT_BOOLEAN_OPTIONS:()=>b.ofx,DEFAULT_COMPARTMENT_HEIGHTS:()=>c.eh,DEFAULT_COMPARTMENT_ID:()=>b.hpF,DEFAULT_COMPARTMENT_LIMITS:()=>b.oSs,DEFAULT_OPERATORS:()=>b.whL,DEFAULT_STAGGERED_MENU_AREA:()=>c.fP,DEFAULT_ZONE_SIZES:()=>b.AnT,DecoratedCard:()=>b.mqB,DefaultPageBackground:()=>b.NOx,DocumentAttachmentIcon:()=>b.Ce6,DocumentIcon:()=>b.pyG,DocumentToolbar:()=>b.PAB,DownloadIcon:()=>b.s3U,DynamicField:()=>b.koC,EditIcon:()=>b.qUP,EgenDatePicker:()=>b.O_s,EgenDateRangePicker:()=>b.tKr,EmptyCard:()=>b.slS,EmptyCardIllustration:()=>b.Ua6,EntityDetailBrowser:()=>b.NIm,ErrorCard:()=>b.JrA,ErrorState:()=>b.W5n,EventScheduleIcon:()=>b.XaH,EventsIcon:()=>b.Jc,FilterBar:()=>b.Qnn,FilterBarDefault:()=>b.vNL,FilterBarDemo:()=>b.RJr,FolderGallery:()=>b.fNA,GESTURE_NAMES:()=>b.rGw,GlobalPageBackground:()=>b.Nqf,GradientBlur:()=>b.wtE,GradientWave:()=>b.GcC,GroupAccessIcon:()=>b.Pyy,GroupIcon:()=>b.nFg,HeroMosaic:()=>b.LdX,HeroTileCard:()=>b.b6Z,HomePictogram:()=>b.KKH,Icon:()=>b.Int,ImageSwiper:()=>b.QeH,InformationFilledIcon:()=>b._e_,InformationIcon:()=>b.uQc,InformationSquareIcon:()=>b.ZrL,InteractiveSelector:()=>b.wmT,InventoryManagementIcon:()=>b.vFG,LayoutGrid:()=>b.D6i,LeftRail:()=>b.IHy,LiquidGlassCard:()=>b.lok,ListCheckedIcon:()=>b.Rt$,LiveOrb:()=>b.AFR,Loader:()=>b.aHM,LocationIcon:()=>b.BT6,MORPH_SELECT_DEFAULT_TRANSITION:()=>b.AOq,MaximizeIcon:()=>b._Xm,MaybeIcon:()=>b.oy0,MaybePictogram:()=>b.bmf,MenuToggleButton:()=>b.qLc,MessageQueueIcon:()=>b.uFu,MoneyIcon:()=>b.yBj,MorphSelect:()=>b.NGl,MorphSelectContent:()=>b.EiO,MorphSelectItem:()=>b.iRo,MorphSelectTrigger:()=>b.PK0,MorphSelectValue:()=>b.qXl,MovementIcon:()=>b.lyJ,NAV_ALL_WORKSPACES:()=>c.Xr,Notification:()=>b.Eg0,OverflowMenuHorizontalIcon:()=>b.rv3,OverflowMenuVerticalIcon:()=>b.Rnm,PageBackground:()=>b.Kz$,PageBackgroundProvider:()=>b.z0Y,PageHeader:()=>b.zYs,PageHeaderContent:()=>b.gpz,Pagination:()=>b.dKS,PasswordIcon:()=>b.BGy,PaymentsDeskPictogram:()=>b.dNG,PedestrianFamilyIcon:()=>b.PPo,PenIcon:()=>b.rZj,Pictogram:()=>b.bF1,PrinterIcon:()=>b.wwY,ProgramsIcon:()=>b.lq$,PromptInput:()=>b.Plc,RECURSIVE_EROSION_DEFAULTS:()=>b.Km0,RecursiveErosionBackground:()=>b.OoY,RenewIcon:()=>b.JTN,ReportIcon:()=>b.cQD,ResetIcon:()=>b.NAP,ResponsiveWrapper:()=>b.KFv,RightRail:()=>b.Bic,RobotController:()=>b.LMw,SECTION_CARD_CLASS:()=>b.YpM,SHELL_RAIL_BOTTOM_SLOT:()=>c.R6,SHELL_RAIL_LEFT_SLOT:()=>c.p$,SHELL_RAIL_RIGHT_SLOT:()=>c.SW,SIDE_ANCHORS:()=>b.RPL,STAGGERED_MENU_AREAS:()=>c.SK,STAGGERED_MENU_SLOT:()=>c.y$,STICKY_VARS:()=>b.Ddn,SaveIcon:()=>b.LPu,SearchIcon:()=>b.WIv,Section:()=>b.wn6,SectionAction:()=>b.SnF,SectionBody:()=>b.iq0,SectionCard:()=>b.ivh,SectionCardTitleButton:()=>b.Q5Y,SectionDivider:()=>b.nBS,SectionFooter:()=>b.lFh,SectionGrid:()=>b.KGd,SectionHeader:()=>b.X3I,SectionNavPanel:()=>b.frg,SectionSlot:()=>b.y0l,Select:()=>b.l6P,SelectContent:()=>b.gCo,SelectContext:()=>b.CW5,SelectTrigger:()=>b.bqE,ServiceQueuesPictogram:()=>b.Y21,SettingsIcon:()=>b.Zes,Sheet:()=>b.cjw,SheetClose:()=>b.kNS,SheetContent:()=>b.hae,SheetContext:()=>b.P8U,SheetDescription:()=>b.Qsg,SheetFooter:()=>b.XWC,SheetHeader:()=>b.Fm9,SheetOverlay:()=>b.YP7,SheetPortal:()=>b.yde,SheetRoot:()=>b.KId,SheetTitle:()=>b.qpM,SheetTrigger:()=>b.CGR,ShoppingCartAddItemIcon:()=>b.Uve,ShoppingCartArrowDownIcon:()=>b.Lfm,ShoppingCartIcon:()=>b.aJF,SiteActivityPanel:()=>b.Xac,SiteApplicationsPanel:()=>b.pyx,SiteBanner:()=>b.cBB,SiteCarousel:()=>b.aiS,SiteMembersPanel:()=>b.tyG,SitePanelHeader:()=>b.Xhy,SiteResourcesPanel:()=>b.Nvq,SiteSearchBar:()=>b.ttj,SiteSettingsPanel:()=>b.rmb,SiteTabbedLayout:()=>b.eFc,SiteTasksPanel:()=>b.SLu,Slider:()=>b.Apm,SliderContainer:()=>b.Jbi,SliderDotButton:()=>b.vY7,Snackbar:()=>b.qb_,SplineScene:()=>b.C44,Splitter:()=>b.O3W,StaggeredMenuPanel:()=>b._kB,StickyNoteAddIcon:()=>b.OC$,StockManagementPictogram:()=>b.q__,SwitcherIcon:()=>b.RFy,TOOL_WINDOW_CONTAINER_ATTRIBUTE:()=>b.ZLW,TOOL_WINDOW_HEADER_ATTRIBUTE:()=>b.lHJ,TOOL_WINDOW_SLOTS:()=>c.As,TOPBAR_NAV_SLOT:()=>c.yS,TOPBAR_SLOT:()=>c.sO,TableBatchActions:()=>b.GGC,TableIcon:()=>b.KbA,TableOfContentsIcon:()=>b.pYV,TestimonialCard:()=>b._f_,TestimonialCardStack:()=>b.uDL,ThumbsSlider:()=>b.BM2,TimeIcon:()=>b.b1c,Toast:()=>b.y8,ToolWindowHeader:()=>b.ICb,ToolWindowZone:()=>b.p4K,ToolsIcon:()=>b.dwU,TopBar:()=>b.Vsm,TopBarAvatar:()=>b.mIk,TopBarDivider:()=>b.AA7,TopBarIconButton:()=>b.gFP,TransferPictogram:()=>b.SKX,TranslateIcon:()=>b.SwB,TrashCanIcon:()=>b.EJV,TreeViewAltIcon:()=>b.MO4,UserAvatarIcon:()=>b.yDT,UserFollowIcon:()=>b.osL,UserIcon:()=>b.nys,ViewIcon:()=>b.tCQ,ViewOffIcon:()=>b.Oi_,WORKBENCH_ICONS:()=>b.BDu,WORKBENCH_STORAGE_KEY:()=>b.gHx,WarningIcon:()=>b.id,WaterGlassModal:()=>b.BIq,WorkSessionMode:()=>s.TG,WorkSessionStatus:()=>s.qd,Workspace2:()=>b.ozP,WorkspaceContainer:()=>b.XvC,WorkspaceNotification:()=>b.tMf,ZONE_ANCHORS:()=>b.c0o,activateOfflineCapability:()=>h.nr,addImportMapOverride:()=>o.fd,addRouteMapOverride:()=>o.Tx,attach:()=>c.K0,attachmentUrl:()=>s.Zu,beginEditSynchronizationItem:()=>h.FO,buildFilterFields:()=>b.mOW,canAccessStorage:()=>w._g,canBeginEditSynchronizationItemsOfType:()=>h.xN,canCloseWorkspaceWithoutPrompting:()=>b.SvQ,cancelPrompt:()=>b.zlb,cardModalAnimationPresets:()=>b.QsE,cardModalPresetStyles:()=>b.Zqu,changeWorkspaceContext:()=>b.JKc,checkStatus:()=>c.dO,checkStatusFor:()=>c.Ef,clampZoneSize:()=>b.foY,cleanCascadingFilters:()=>b._Jn,cleanupObsoleteFeatureFlags:()=>d.D3,clearHistory:()=>p.g4,closeAllWorkspaces:()=>b.G_3,closeCompartment:()=>b.lA$,closeToolWindow:()=>b.T7Q,closeWorkspace:()=>b.MJ8,closeWorkspaceGroup2:()=>b.biy,cn:()=>b.cn,compartmentKey:()=>b.aXL,compile:()=>u.wE,convertToLocaleCalendar:()=>w.d4,createAttachment:()=>s.cD,createErrorHandler:()=>l.J,createLiveOrb:()=>b.Ogf,defaultValidation:()=>b.n$t,defaultWorkSessionCustomRepresentation:()=>s.pJ,deleteAttachmentPermanently:()=>s.SY,deleteSynchronizationItem:()=>h.lY,detach:()=>c.Yo,detachAll:()=>c.No,dispatchActionableNotificationShown:()=>f.LQ,dispatchConnectivityChanged:()=>f.Yt,dispatchNotificationShown:()=>f.FI,dispatchPrecacheStaticDependencies:()=>f.pc,dispatchSnackbarShown:()=>f.$3,dispatchToastShown:()=>f.Vt,duration:()=>w.p0,egenOfflineCachingStrategyHttpHeaderName:()=>h.T$,egenOfflineResponseBodyHttpHeaderName:()=>h.Q1,egenOfflineResponseStatusHttpHeaderName:()=>h.Gt,enableImportMapOverride:()=>o.BX,esmStyleGuideSchema:()=>b.uQD,evaluate:()=>u._3,evaluateAsBoolean:()=>u.eb,evaluateAsBooleanAsync:()=>u.Gz,evaluateAsNumber:()=>u.dX,evaluateAsNumberAsync:()=>u.$F,evaluateAsType:()=>u.Sj,evaluateAsTypeAsync:()=>u.uN,evaluateAsync:()=>u.mv,evaluateFilter:()=>b.Ws0,extractVariableNames:()=>u.yp,featureFlagsStore:()=>d.jX,filterBreadcrumbs:()=>p.D_,finishRegisteringAllApps:()=>v.yw,fireEgenEvent:()=>s.g8,fitCompartmentHeights:()=>b.gz6,formatDate:()=>w.Yq,formatDatetime:()=>w.Rt,formatDuration:()=>w.a3,formatDurationBetween:()=>w.g2,formatPartialDate:()=>w.LW,formatTime:()=>w.fU,formatToolWindowBadge:()=>b.pd,generateOfflineUuid:()=>h.sA,getActiveModuleNames:()=>b.pJo,getAssignedExtensions:()=>c.zx,getAttachmentByUuid:()=>s.KU,getAttachments:()=>s.Bv,getBreadcrumbs:()=>p.lz,getBreadcrumbsFor:()=>p.qh,getCoreTranslation:()=>x.V,getCurrentImportMap:()=>o.Ln,getCurrentOfflineMode:()=>h.wJ,getCurrentPageMap:()=>o.F$,getCurrentRouteMap:()=>o.FM,getDefaultCalendar:()=>w.a7,getDefaultsFromConfigSchema:()=>w.kd,getDynamicOfflineDataEntries:()=>h.FE,getDynamicOfflineDataEntriesFor:()=>h.WA,getDynamicOfflineDataHandlers:()=>h.qb,getEgenServiceWorker:()=>h.b1,getEgenTarget:()=>f.tM,getExtensionInternalStore:()=>c.a9,getExtensionNameFromId:()=>c.ES,getExtensionRegistration:()=>c.Tj,getExtensionRegistrationFrom:()=>c.xg,getExtensionStore:()=>c.zF,getFeatureFlag:()=>d.jj,getFullSynchronizationItems:()=>h.C$,getFullSynchronizationItemsFor:()=>h.xc,getGroupByWindowName:()=>c.o1,getHistory:()=>p.JK,getImportMapDefaultMap:()=>o.tK,getImportMapDisabledOverrides:()=>o.xI,getImportMapNextPageMap:()=>o.o5,getImportMapOverrideMap:()=>o.uT,getLocale:()=>w.JK,getLocations:()=>s.Vs,getModalRegistration:()=>c.Fg,getNavBehavior:()=>c.Yw,getOfflineDb:()=>h.e,getOfflineEntityDataStore:()=>h.sm,getOfflineSynchronizationStore:()=>h.LM,getOpenCompartments:()=>b.u7L,getOpenedWindowIndexByWorkspace:()=>c.YX,getPromptBeforeClosingFcn:()=>b.OeE,getRegisteredWorkspace2Names:()=>b.uBm,getRouteMapDefaultMap:()=>o.zU,getRouteMapNextPageMap:()=>o.Y6,getRouteMapOverrideMap:()=>o.WY,getSavedAssistantMode:()=>b.T7$,getStaggeredMenuEntryProblems:()=>c.uu,getStartedWorkSession:()=>s.rm,getSynchronizationItem:()=>h.Gp,getSynchronizationItems:()=>h.pb,getSynchronizationItemsFor:()=>h.Io,getToolWindowCompartment:()=>c.lN,getToolWindowMetaProblems:()=>c.Sk,getWindowByWorkspaceName:()=>c.Ml,getWorkSessionStore:()=>s.r_,getWorkSessionTypes:()=>s.Ty,getWorkSessionsForEntity:()=>s.ly,getWorkspaceGroupRegistration:()=>c.Q_,getWorkspaceGroupStore:()=>b.e_T,getWorkspaceRegistration:()=>c.Xb,getWorkspaceStore:()=>b.XzH,goBackInHistory:()=>p.tA,hasCapability:()=>f.p0,hasOwnCompartment:()=>b.XWY,iconIds:()=>b.kE8,importDynamic:()=>o.rL,integrateBreakpoints:()=>b.WMK,interpolateString:()=>p.zl,interpolateUrl:()=>p.JG,isEgenAppRoutes:()=>f.j0,isEgenDateStrict:()=>w.pf,isEgenDateToday:()=>w.L8,isEgenRoutes:()=>f.Ss,isFilterReady:()=>b.iVR,isImportMapOverrideDisabled:()=>o.q1,isNativeTarget:()=>f.$6,isNavEntryInWorkspace:()=>c.oE,isNavEntryMeta:()=>c.DK,isOfflineUuid:()=>h.bO,isOnline:()=>w.sc,isSafeToolWindowIconUrl:()=>c.e4,isStaggeredMenuArea:()=>c.ND,isStaggeredMenuEntryMeta:()=>c.Te,isToolWindowMeta:()=>c.oW,isToolWindowSlot:()=>c.rq,isVersionSatisfied:()=>w.rX,isXboxAudioMuted:()=>b.lgu,jsep:()=>u.PQ,launchWorkspace:()=>b.TC2,launchWorkspace2:()=>b.pTx,launchWorkspaceGroup:()=>b.aN0,launchWorkspaceGroup2:()=>b.GYk,loadLifeCycles:()=>v.oB,loaderMarkup:()=>b.ilK,matchLocale:()=>w.w7,matchesFilters:()=>b.lu9,messageEgenServiceWorker:()=>h.Oc,navBehaviorStore:()=>c.rf,navigate:()=>p.oo,navigateAndLaunchWorkspace:()=>b.Fmw,offlineUuidPrefix:()=>h.jU,openCompartment:()=>b.$Kb,openToolWindow:()=>b.xlj,parseDate:()=>w._U,parseDateInput:()=>w.qE,pictogramIds:()=>b.vJW,playPageEnter:()=>b.m9A,playXboxSound:()=>b.x4I,preloadAssistantRobot:()=>b.mjw,preloadImport:()=>o.zC,preloadSplineScene:()=>b.Pfj,promptBeforeClosing:()=>b.F3N,promptForClosingWorkspaces:()=>b.hLN,putDynamicOfflineData:()=>h.yD,putDynamicOfflineDataFor:()=>h.ff,queueSynchronizationItem:()=>h.Zr,queueSynchronizationItemFor:()=>h.Iq,registerApp:()=>v.FZ,registerBreadcrumb:()=>p.vf,registerBreadcrumbs:()=>p.MY,registerDefaultCalendar:()=>w.XE,registerEgenServiceWorker:()=>h.QP,registerExtension:()=>c.VK,registerExtensionSlot:()=>c.FY,registerFeatureFlag:()=>d.uA,registerModal:()=>c.Ju,registerNavBehavior:()=>c.ZJ,registerOfflineEntityHandler:()=>h.Wo,registerStaggeredMenuEntry:()=>c.BR,registerToolWindow:()=>c.QS,registerWorkspace:()=>c.pm,registerWorkspaceGroup:()=>c.io,registerWorkspaceGroups2:()=>c.rD,registerWorkspaceWindows2:()=>c.Qb,registerWorkspaces2:()=>c.Uh,removeDynamicOfflineData:()=>h.NU,removeDynamicOfflineDataFor:()=>h.wn,removeImportMapOverride:()=>o.E,removeRouteMapOverride:()=>o.KI,renderActionableNotifications:()=>b.zfR,renderExtension:()=>c.wG,renderInlineNotifications:()=>b.CU$,renderLoadingSpinner:()=>b.uWG,renderPageBackground:()=>b.uTG,renderSnackbars:()=>b.ZLm,renderToasts:()=>b.f1b,renderWorkbench:()=>b.OFC,renderWorkspaceWindowsAndMenu:()=>b.jCr,reportError:()=>l.N,reset:()=>c.cL,resetImportMapOverrides:()=>o.w_,resetRouteMapOverrides:()=>o.eH,resetWorkspaceStore:()=>b._1W,resetZoneSize:()=>b.zkr,resizeCompartmentBoundary:()=>b.No8,resolveStaggeredMenuEntries:()=>c.wR,resolveWorkbenchIcon:()=>b.zLd,retry:()=>w.L5,runSynchronization:()=>h.AO,saveAssistantMode:()=>b.Pe5,saveWorkSession:()=>s.XM,setCapabilityResolver:()=>f.Zv,setCompartmentHeights:()=>b.lbO,setCurrentOfflineMode:()=>h.Og,setCurrentWorkSession:()=>s.R5,setFeatureFlag:()=>d.B4,setToolWindowBadge:()=>b.a8E,setZoneSize:()=>b.uge,setupDynamicOfflineDataHandler:()=>h.iD,setupHistory:()=>p.Wh,setupImportMapOverrides:()=>o.SM,setupModals:()=>b.EPe,setupOfflineSync:()=>h.cy,setupPageTransitions:()=>b.d1P,setupRouteMapOverrides:()=>o._m,shallowEqual:()=>w.bN,showActionableNotification:()=>b.ZyP,showModal:()=>b.toY,showNotification:()=>b.Dsh,showPageLoader:()=>b.EDr,showSnackbar:()=>b.tdF,showToast:()=>b.P0c,showWorkspacePrompts:()=>b.ctS,slugify:()=>o.Yv,staggeredMenuEntryTitle:()=>b.kxh,stickyStyleVars:()=>b.paI,subscribeActionableNotificationShown:()=>f.bK,subscribeConnectivity:()=>f.sT,subscribeConnectivityChanged:()=>f.gj,subscribeEgenEvent:()=>s.mI,subscribeNotificationShown:()=>f.bJ,subscribePrecacheStaticDependencies:()=>f.ff,subscribeSnackbarShown:()=>f.ls,subscribeToFeatureFlag:()=>d.sM,subscribeToastShown:()=>f.dX,syncAllDynamicOfflineData:()=>h.Td,syncDynamicOfflineData:()=>h.u1,syncOfflineEntityData:()=>h.Oj,toDateObjectStrict:()=>w.kQ,toEgenIsoString:()=>w.L3,toLocationObject:()=>s.E$,toWorkSessionTypeObject:()=>s.iS,toggleCompartment:()=>b.pdq,toggleToolWindow:()=>b.Hwc,toggleXboxAudio:()=>b.MiD,toolWindowTitle:()=>b.tp2,translateFrom:()=>x.t,tryRegisterExtension:()=>v.Y1,updateExtensionSlotState:()=>c.ap,updateInternalExtensionStore:()=>c.DQ,updateWorkSession:()=>s.bS,updateWorkspaceWindowState:()=>b._RD,useActiveAppModules:()=>b.Y26,useCarouselContext:()=>b.RGi,useCustomOverflowMenu:()=>b.ckU,useFilterSchema:()=>b.d4y,usePageBackground:()=>b.DYW,usePageLoading:()=>b.v99,useSelectContext:()=>b.hPu,useSheetContext:()=>b.sCq,useStaggeredMenuEntries:()=>b.NNe,useToolWindows:()=>b.ncA,useWorkspace2Context:()=>b.WO_,useWorkspace2Store:()=>b.AkA,useWorkspaces:()=>b.CH0,validateBuildManifest:()=>f.q0,workbenchBadgeStore:()=>b.UcB,workbenchStore:()=>b.Tqd,workspace2Store:()=>c.J_,workspace2StoreActions:()=>b.cJy,workspaceStore:()=>b.x9q,xboxAudio:()=>b.o81});var n=r(70),a={};for(let e in n)"default"!==e&&(a[e]=()=>n[e]);r.d(t,a);var i=r(3645),a={};for(let e in i)"default"!==e&&(a[e]=()=>i[e]);r.d(t,a);var o=r(101),s=r(3400),l=r(8507),u=r(9360),c=r(7267),d=r(5794),f=r(8840),p=r(7774),h=r(6563),m=r(4592),a={};for(let e in m)0>["registerBreadcrumbs","getImportMapOverrideMap","evaluateAsNumber","TOOL_WINDOW_SLOTS","importDynamic","registerNavBehavior","evaluateAsTypeAsync","getGroupByWindowName","WorkSessionMode","TOPBAR_SLOT","getToolWindowMetaProblems","updateInternalExtensionStore","compile","removeRouteMapOverride","checkStatus","getWorkSessionStore","goBackInHistory","getDynamicOfflineDataHandlers","dispatchConnectivityChanged","setCurrentOfflineMode","dispatchActionableNotificationShown","resetRouteMapOverrides","saveWorkSession","getModalRegistration","queueSynchronizationItem","setCapabilityResolver","getRouteMapNextPageMap","getBreadcrumbsFor","isToolWindowSlot","setupRouteMapOverrides","getEgenTarget","getWorkspaceGroupRegistration","hasCapability","registerWorkspace","registerEgenServiceWorker","DEFAULT_STAGGERED_MENU_AREA","attach","updateWorkSession","reset","validateBuildManifest","beginEditSynchronizationItem","offlineUuidPrefix","SHELL_RAIL_RIGHT_SLOT","getEgenServiceWorker","STAGGERED_MENU_SLOT","deleteAttachmentPermanently","setFeatureFlag","subscribeConnectivity","attachmentUrl","interpolateString","defaultWorkSessionCustomRepresentation","resolveStaggeredMenuEntries","detach","getToolWindowCompartment","canBeginEditSynchronizationItemsOfType","preloadImport","STAGGERED_MENU_AREAS","getCurrentImportMap","registerWorkspaceWindows2","toLocationObject","activateOfflineCapability","egenOfflineResponseBodyHttpHeaderName","getOpenedWindowIndexByWorkspace","renderExtension","evaluateAsBooleanAsync","getFeatureFlag","checkStatusFor","updateExtensionSlotState","getLocations","isEgenAppRoutes","clearHistory","dispatchSnackbarShown","NAV_ALL_WORKSPACES","egenOfflineResponseStatusHttpHeaderName","getOfflineDb","getSynchronizationItem","getHistory","getCurrentRouteMap","toWorkSessionTypeObject","subscribeSnackbarShown","getImportMapDisabledOverrides","getRouteMapDefaultMap","syncAllDynamicOfflineData","messageEgenServiceWorker","getDynamicOfflineDataEntriesFor","evaluateAsType","isOfflineUuid","registerWorkspaceGroups2","evaluateAsync","getBreadcrumbs","putDynamicOfflineDataFor","removeImportMapOverride","evaluateAsNumberAsync","getImportMapDefaultMap","extractVariableNames","removeDynamicOfflineData","getStaggeredMenuEntryProblems","subscribePrecacheStaticDependencies","getOfflineSynchronizationStore","getExtensionNameFromId","getNavBehavior","cleanupObsoleteFeatureFlags","dispatchPrecacheStaticDependencies","deleteSynchronizationItem","subscribeNotificationShown","putDynamicOfflineData","registerBreadcrumb","subscribeActionableNotificationShown","TOPBAR_NAV_SLOT","subscribeEgenEvent","subscribeToFeatureFlag","getCurrentOfflineMode","enableImportMapOverride","isEgenRoutes","createAttachment","registerOfflineEntityHandler","getStartedWorkSession","addImportMapOverride","subscribeConnectivityChanged","getWorkSessionTypes","interpolateUrl","setupHistory","getOfflineEntityDataStore","getCurrentPageMap","registerStaggeredMenuEntry","subscribeToastShown","detachAll","generateOfflineUuid","queueSynchronizationItemFor","isNavEntryInWorkspace","setupDynamicOfflineDataHandler","filterBreadcrumbs","dispatchNotificationShown","egenOfflineCachingStrategyHttpHeaderName","getAssignedExtensions","getSynchronizationItems","syncDynamicOfflineData","createErrorHandler","SHELL_RAIL_LEFT_SLOT","registerFeatureFlag","getWorkspaceRegistration","getAttachmentByUuid","isImportMapOverrideDisabled","DEFAULT_COMPARTMENT_HEIGHTS","getExtensionRegistration","registerExtension","getExtensionInternalStore","dispatchToastShown","getImportMapNextPageMap","evaluateAsBoolean","addRouteMapOverride","getAttachments","isSafeToolWindowIconUrl","workspace2Store","getFullSynchronizationItems","getFullSynchronizationItemsFor","getSynchronizationItemsFor","runSynchronization","setupOfflineSync","default","isStaggeredMenuEntryMeta","featureFlagsStore","navBehaviorStore","removeDynamicOfflineDataFor","jsep","resetImportMapOverrides","getRouteMapOverrideMap","isStaggeredMenuArea","registerWorkspaceGroup","slugify","reportError","registerToolWindow","getExtensionStore","registerWorkspaces2","fireEgenEvent","setupImportMapOverrides","setCurrentWorkSession","getWorkSessionsForEntity","registerExtensionSlot","registerModal","evaluate","getWindowByWorkspaceName","isNavEntryMeta","getDynamicOfflineDataEntries","WorkSessionStatus","syncOfflineEntityData","getExtensionRegistrationFrom","isToolWindowMeta","SHELL_RAIL_BOTTOM_SLOT","isNativeTarget","navigate"].indexOf(e)&&(a[e]=()=>m[e]);r.d(t,a);var y=r(7388),a={};for(let e in y)0>["registerBreadcrumbs","getImportMapOverrideMap","evaluateAsNumber","TOOL_WINDOW_SLOTS","importDynamic","registerNavBehavior","evaluateAsTypeAsync","getGroupByWindowName","WorkSessionMode","TOPBAR_SLOT","getToolWindowMetaProblems","updateInternalExtensionStore","compile","removeRouteMapOverride","checkStatus","getWorkSessionStore","goBackInHistory","getDynamicOfflineDataHandlers","dispatchConnectivityChanged","setCurrentOfflineMode","dispatchActionableNotificationShown","resetRouteMapOverrides","saveWorkSession","getModalRegistration","queueSynchronizationItem","setCapabilityResolver","getRouteMapNextPageMap","getBreadcrumbsFor","isToolWindowSlot","setupRouteMapOverrides","getEgenTarget","getWorkspaceGroupRegistration","hasCapability","registerWorkspace","registerEgenServiceWorker","DEFAULT_STAGGERED_MENU_AREA","attach","updateWorkSession","reset","validateBuildManifest","beginEditSynchronizationItem","offlineUuidPrefix","SHELL_RAIL_RIGHT_SLOT","getEgenServiceWorker","STAGGERED_MENU_SLOT","deleteAttachmentPermanently","setFeatureFlag","subscribeConnectivity","attachmentUrl","interpolateString","defaultWorkSessionCustomRepresentation","resolveStaggeredMenuEntries","detach","getToolWindowCompartment","canBeginEditSynchronizationItemsOfType","preloadImport","STAGGERED_MENU_AREAS","getCurrentImportMap","registerWorkspaceWindows2","toLocationObject","activateOfflineCapability","egenOfflineResponseBodyHttpHeaderName","getOpenedWindowIndexByWorkspace","renderExtension","evaluateAsBooleanAsync","getFeatureFlag","checkStatusFor","updateExtensionSlotState","getLocations","isEgenAppRoutes","clearHistory","dispatchSnackbarShown","NAV_ALL_WORKSPACES","egenOfflineResponseStatusHttpHeaderName","getOfflineDb","getSynchronizationItem","getHistory","getCurrentRouteMap","toWorkSessionTypeObject","subscribeSnackbarShown","getImportMapDisabledOverrides","getRouteMapDefaultMap","syncAllDynamicOfflineData","messageEgenServiceWorker","getDynamicOfflineDataEntriesFor","evaluateAsType","isOfflineUuid","registerWorkspaceGroups2","evaluateAsync","getBreadcrumbs","putDynamicOfflineDataFor","removeImportMapOverride","evaluateAsNumberAsync","getImportMapDefaultMap","extractVariableNames","removeDynamicOfflineData","getStaggeredMenuEntryProblems","subscribePrecacheStaticDependencies","getOfflineSynchronizationStore","getExtensionNameFromId","getNavBehavior","cleanupObsoleteFeatureFlags","dispatchPrecacheStaticDependencies","deleteSynchronizationItem","subscribeNotificationShown","putDynamicOfflineData","registerBreadcrumb","subscribeActionableNotificationShown","TOPBAR_NAV_SLOT","subscribeEgenEvent","subscribeToFeatureFlag","getCurrentOfflineMode","enableImportMapOverride","isEgenRoutes","createAttachment","registerOfflineEntityHandler","getStartedWorkSession","addImportMapOverride","subscribeConnectivityChanged","getWorkSessionTypes","interpolateUrl","setupHistory","getOfflineEntityDataStore","getCurrentPageMap","registerStaggeredMenuEntry","subscribeToastShown","detachAll","generateOfflineUuid","queueSynchronizationItemFor","isNavEntryInWorkspace","setupDynamicOfflineDataHandler","filterBreadcrumbs","dispatchNotificationShown","egenOfflineCachingStrategyHttpHeaderName","getAssignedExtensions","getSynchronizationItems","syncDynamicOfflineData","createErrorHandler","SHELL_RAIL_LEFT_SLOT","registerFeatureFlag","getWorkspaceRegistration","getAttachmentByUuid","isImportMapOverrideDisabled","DEFAULT_COMPARTMENT_HEIGHTS","getExtensionRegistration","registerExtension","getExtensionInternalStore","dispatchToastShown","getImportMapNextPageMap","evaluateAsBoolean","addRouteMapOverride","getAttachments","isSafeToolWindowIconUrl","workspace2Store","getFullSynchronizationItems","getFullSynchronizationItemsFor","getSynchronizationItemsFor","runSynchronization","setupOfflineSync","default","isStaggeredMenuEntryMeta","featureFlagsStore","navBehaviorStore","removeDynamicOfflineDataFor","jsep","resetImportMapOverrides","getRouteMapOverrideMap","isStaggeredMenuArea","registerWorkspaceGroup","slugify","reportError","registerToolWindow","getExtensionStore","registerWorkspaces2","fireEgenEvent","setupImportMapOverrides","setCurrentWorkSession","getWorkSessionsForEntity","registerExtensionSlot","registerModal","evaluate","getWindowByWorkspaceName","isNavEntryMeta","getDynamicOfflineDataEntries","WorkSessionStatus","syncOfflineEntityData","getExtensionRegistrationFrom","isToolWindowMeta","SHELL_RAIL_BOTTOM_SLOT","isNativeTarget","navigate"].indexOf(e)&&(a[e]=()=>y[e]);r.d(t,a);var v=r(7230),g=r(1442),a={};for(let e in g)0>["navigate","getImportMapOverrideMap","evaluateAsNumber","TOOL_WINDOW_SLOTS","importDynamic","registerNavBehavior","finishRegisteringAllApps","registerBreadcrumbs","evaluateAsTypeAsync","tryRegisterExtension","WorkSessionMode","TOPBAR_SLOT","getToolWindowMetaProblems","updateInternalExtensionStore","compile","removeRouteMapOverride","checkStatus","getWorkSessionStore","goBackInHistory","getDynamicOfflineDataHandlers","dispatchConnectivityChanged","setCurrentOfflineMode","dispatchActionableNotificationShown","resetRouteMapOverrides","saveWorkSession","getModalRegistration","queueSynchronizationItem","getGroupByWindowName","setCapabilityResolver","getRouteMapNextPageMap","getBreadcrumbsFor","isToolWindowSlot","setupRouteMapOverrides","getEgenTarget","getWorkspaceGroupRegistration","hasCapability","registerWorkspace","registerEgenServiceWorker","DEFAULT_STAGGERED_MENU_AREA","attach","updateWorkSession","reset","validateBuildManifest","beginEditSynchronizationItem","offlineUuidPrefix","SHELL_RAIL_RIGHT_SLOT","getEgenServiceWorker","STAGGERED_MENU_SLOT","deleteAttachmentPermanently","setFeatureFlag","subscribeConnectivity","attachmentUrl","interpolateString","defaultWorkSessionCustomRepresentation","resolveStaggeredMenuEntries","detach","getToolWindowCompartment","canBeginEditSynchronizationItemsOfType","preloadImport","STAGGERED_MENU_AREAS","getCurrentImportMap","registerWorkspaceWindows2","toLocationObject","activateOfflineCapability","egenOfflineResponseBodyHttpHeaderName","getOpenedWindowIndexByWorkspace","renderExtension","evaluateAsBooleanAsync","getFeatureFlag","checkStatusFor","updateExtensionSlotState","getLocations","isEgenAppRoutes","clearHistory","dispatchSnackbarShown","NAV_ALL_WORKSPACES","egenOfflineResponseStatusHttpHeaderName","getOfflineDb","getSynchronizationItem","getHistory","getCurrentRouteMap","toWorkSessionTypeObject","subscribeSnackbarShown","getImportMapDisabledOverrides","getRouteMapDefaultMap","syncAllDynamicOfflineData","messageEgenServiceWorker","getDynamicOfflineDataEntriesFor","evaluateAsType","isOfflineUuid","registerWorkspaceGroups2","evaluateAsync","getBreadcrumbs","putDynamicOfflineDataFor","removeImportMapOverride","evaluateAsNumberAsync","getImportMapDefaultMap","extractVariableNames","putDynamicOfflineData","removeDynamicOfflineData","getStaggeredMenuEntryProblems","subscribePrecacheStaticDependencies","getOfflineSynchronizationStore","getExtensionNameFromId","getNavBehavior","dispatchPrecacheStaticDependencies","deleteSynchronizationItem","cleanupObsoleteFeatureFlags","subscribeNotificationShown","registerBreadcrumb","subscribeActionableNotificationShown","TOPBAR_NAV_SLOT","subscribeEgenEvent","subscribeToFeatureFlag","getCurrentOfflineMode","enableImportMapOverride","isEgenRoutes","createAttachment","registerOfflineEntityHandler","getStartedWorkSession","addImportMapOverride","subscribeConnectivityChanged","getWorkSessionTypes","interpolateUrl","setupHistory","getOfflineEntityDataStore","getCurrentPageMap","registerStaggeredMenuEntry","subscribeToastShown","detachAll","generateOfflineUuid","queueSynchronizationItemFor","isNavEntryInWorkspace","registerApp","setupDynamicOfflineDataHandler","filterBreadcrumbs","dispatchNotificationShown","egenOfflineCachingStrategyHttpHeaderName","getAssignedExtensions","getSynchronizationItems","syncDynamicOfflineData","createErrorHandler","SHELL_RAIL_LEFT_SLOT","registerFeatureFlag","getWorkspaceRegistration","getAttachmentByUuid","isImportMapOverrideDisabled","DEFAULT_COMPARTMENT_HEIGHTS","getExtensionRegistration","registerExtension","getExtensionInternalStore","dispatchToastShown","getImportMapNextPageMap","evaluateAsBoolean","addRouteMapOverride","getAttachments","isSafeToolWindowIconUrl","workspace2Store","getFullSynchronizationItems","getFullSynchronizationItemsFor","getSynchronizationItemsFor","runSynchronization","setupOfflineSync","default","isStaggeredMenuEntryMeta","featureFlagsStore","navBehaviorStore","removeDynamicOfflineDataFor","jsep","resetImportMapOverrides","getRouteMapOverrideMap","isStaggeredMenuArea","registerWorkspaceGroup","slugify","reportError","registerToolWindow","getExtensionStore","registerWorkspaces2","fireEgenEvent","setupImportMapOverrides","setCurrentWorkSession","getWorkSessionsForEntity","registerExtensionSlot","registerModal","evaluate","getWindowByWorkspaceName","loadLifeCycles","getDynamicOfflineDataEntries","isNavEntryMeta","syncOfflineEntityData","WorkSessionStatus","getExtensionRegistrationFrom","isToolWindowMeta","isNativeTarget","SHELL_RAIL_BOTTOM_SLOT"].indexOf(e)&&(a[e]=()=>g[e]);r.d(t,a);var b=r(597),x=r(5565),w=r(4834)},1221(e,t,r){"use strict";r.d(t,{Z:()=>a,p:()=>i});var n=null;function a(e){n=e}function i(e){return!!n&&n(e)}},8840(e,t,r){"use strict";r.d(t,{Vt:()=>n.Vt,tM:()=>i.t,q0:()=>c,j0:()=>a.j,ff:()=>n.ff,ls:()=>n.ls,LQ:()=>n.LQ,sT:()=>n.sT,FI:()=>n.FI,Ss:()=>a.S,dX:()=>n.dX,$3:()=>n.$3,pc:()=>n.pc,bK:()=>n.bK,gj:()=>n.gj,Zv:()=>o.Z,bJ:()=>n.bJ,p0:()=>o.p,Yt:()=>n.Yt,$6:()=>i.$});var n=r(9726),a=r(2235),i=r(3766),o=r(1221),s=/^\d+\.\d+\.\d+(?:-[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?(?:\+[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/,l=/^sha(?:256|384|512)-[A-Za-z0-9+/]+={0,2}$/;function u(e){return(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"&&null!==e&&!Array.isArray(e)}function c(e){var t=[];if(!u(e))return{valid:!1,errors:["le manifeste doit \xeatre un objet"]};var r=e.shellVersion,n=e.frameworkVersion,a=e.protocolVersion,i=e.apps;"string"==typeof r&&s.test(r)||t.push("shellVersion doit \xeatre une version semver (ex. 2.10.0)"),"string"==typeof n&&s.test(n)||t.push("frameworkVersion doit \xeatre une version semver (ex. 4.0.0)"),("number"!=typeof a||!Number.isInteger(a)||a<1)&&t.push("protocolVersion doit \xeatre un entier ≥ 1");var o=[];if(Array.isArray(i)){var c=new Set;i.forEach(function(e,r){var n="apps[".concat(r,"]");if(!u(e))return void t.push("".concat(n," doit \xeatre un objet"));var a=e.name,i=e.version,d=e.integrity;"string"!=typeof a||0===a.length?t.push("".concat(n,".name doit \xeatre une cha\xeene non vide")):c.has(a)?t.push("".concat(n,'.name "').concat(a,'" est en double')):c.add(a),"string"==typeof i&&s.test(i)||t.push("".concat(n,".version doit \xeatre une version semver exacte")),"string"==typeof d&&l.test(d)||t.push("".concat(n,".integrity doit \xeatre une empreinte SRI (sha256-…, sha384-… ou sha512-…)")),"string"==typeof a&&"string"==typeof i&&"string"==typeof d&&o.push({name:a,version:i,integrity:d})})}else t.push("apps doit \xeatre un tableau");return t.length>0?{valid:!1,errors:t}:{valid:!0,manifest:{shellVersion:r,frameworkVersion:n,protocolVersion:a,apps:o}}}},2235(e,t,r){"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function a(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function i(e){return!!e&&(void 0===e?"undefined":a(e))==="object"&&!(Object.hasOwn(e,"pages")&&(!e.pages||!Array.isArray(e.pages))||Object.hasOwn(e,"extensions")&&(!e.extensions||!Array.isArray(e.extensions))||Object.hasOwn(e,"workspaces")&&(!e.workspaces||!Array.isArray(e.workspaces))||Object.hasOwn(e,"modals")&&(!e.modals||!Array.isArray(e.modals)))}function o(e){return!!e&&(void 0===e?"undefined":a(e))==="object"&&Object.entries(e).every(function(e){var t=function(e){if(Array.isArray(e))return e}(e)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(e)||function(e){if(e){if("string"==typeof e)return n(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return n(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],a=t[1];return"string"==typeof r&&i(a)})}r.d(t,{S:()=>o,j:()=>i})},6563(e,t,r){"use strict";let n;r.d(t,{nr:()=>C,xN:()=>np,u1:()=>nI,FO:()=>nh,Q1:()=>g,FE:()=>nA,sA:()=>nb,LM:()=>nn,ff:()=>nT,wn:()=>nR,Oj:()=>nz,lY:()=>nm,Zr:()=>ns,cy:()=>ny,WA:()=>nD,T$:()=>x,Gp:()=>nf,jU:()=>ng,Og:()=>D,iD:()=>nP,C$:()=>nd,qb:()=>nE,Iq:()=>no,NU:()=>nN,yD:()=>nC,Wo:()=>nV,sm:()=>nB,Io:()=>nl,wJ:()=>A,Oc:()=>S,e:()=>r4,xc:()=>nu,pb:()=>nc,bO:()=>nx,b1:()=>v,AO:()=>na,Td:()=>nM,QP:()=>y,Gt:()=>b});try{self["workbox:window:6.5.4"]&&_()}catch(e){}function a(e,t){return new Promise(function(r){var n=new MessageChannel;n.port1.onmessage=function(e){r(e.data)},e.postMessage(t,[n.port2])})}function i(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}try{self["workbox:core:6.5.4"]&&_()}catch(e){}var s=function(){var e=this;this.promise=new Promise(function(t,r){e.resolve=t,e.reject=r})};function l(e,t){var r=location.href;return new URL(e,r).href===new URL(t,r).href}var u=function(e,t){this.type=e,Object.assign(this,t)};function c(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}function d(){}var f={type:"SKIP_WAITING"};function p(e,t){if(!t)return e&&e.then?e.then(d):Promise.resolve()}var h=function(e){function t(t,r){var n,a;return void 0===r&&(r={}),(n=e.call(this)||this).nn={},n.tn=0,n.rn=new s,n.en=new s,n.on=new s,n.un=0,n.an=new Set,n.cn=function(){var e=n.fn,t=e.installing;n.tn>0||!l(t.scriptURL,n.sn.toString())||performance.now()>n.un+6e4?(n.vn=t,e.removeEventListener("updatefound",n.cn)):(n.hn=t,n.an.add(t),n.rn.resolve(t)),++n.tn,t.addEventListener("statechange",n.ln)},n.ln=function(e){var t=n.fn,r=e.target,a=r.state,i=r===n.vn,o={sw:r,isExternal:i,originalEvent:e};!i&&n.mn&&(o.isUpdate=!0),n.dispatchEvent(new u(a,o)),"installed"===a?n.wn=self.setTimeout(function(){"installed"===a&&t.waiting===r&&n.dispatchEvent(new u("waiting",o))},200):"activating"===a&&(clearTimeout(n.wn),i||n.en.resolve(r))},n.dn=function(e){var t=n.hn,r=t!==navigator.serviceWorker.controller;n.dispatchEvent(new u("controlling",{isExternal:r,originalEvent:e,sw:t,isUpdate:n.mn})),r||n.on.resolve(t)},a=function(e){var t=e.data,r=e.ports,a=e.source;return c(n.getSW(),function(){n.an.has(a)&&n.dispatchEvent(new u("message",{data:t,originalEvent:e,ports:r,sw:a}))})},n.gn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];try{return Promise.resolve(a.apply(this,e))}catch(e){return Promise.reject(e)}},n.sn=t,n.nn=r,navigator.serviceWorker.addEventListener("message",n.gn),n}t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e;var r,n,o=t.prototype;return o.register=function(e){var t=(void 0===e?{}:e).immediate,r=void 0!==t&&t;try{var n,a,i,o=this;return n=function(){if(!r&&"complete"!==document.readyState)return p(new Promise(function(e){return window.addEventListener("load",e)}))},a=function(){return o.mn=!!navigator.serviceWorker.controller,o.yn=o.pn(),c(o.bn(),function(e){o.fn=e,o.yn&&(o.hn=o.yn,o.en.resolve(o.yn),o.on.resolve(o.yn),o.yn.addEventListener("statechange",o.ln,{once:!0}));var t=o.fn.waiting;return t&&l(t.scriptURL,o.sn.toString())&&(o.hn=t,Promise.resolve().then(function(){o.dispatchEvent(new u("waiting",{sw:t,wasWaitingBeforeRegister:!0}))}).then(function(){})),o.hn&&(o.rn.resolve(o.hn),o.an.add(o.hn)),o.fn.addEventListener("updatefound",o.cn),navigator.serviceWorker.addEventListener("controllerchange",o.dn),o.fn})},(i=n())&&i.then?i.then(a):a(i)}catch(e){return Promise.reject(e)}},o.update=function(){try{return this.fn?p(this.fn.update()):void 0}catch(e){return Promise.reject(e)}},o.getSW=function(){return void 0!==this.hn?Promise.resolve(this.hn):this.rn.promise},o.messageSW=function(e){try{return c(this.getSW(),function(t){return a(t,e)})}catch(e){return Promise.reject(e)}},o.messageSkipWaiting=function(){this.fn&&this.fn.waiting&&a(this.fn.waiting,f)},o.pn=function(){var e=navigator.serviceWorker.controller;return e&&l(e.scriptURL,this.sn.toString())?e:void 0},o.bn=function(){try{var e=this;return function(e,t){try{var r=e()}catch(e){return t(e)}return r&&r.then?r.then(void 0,t):r}(function(){return c(navigator.serviceWorker.register(e.sn,e.nn),function(t){return e.un=performance.now(),t})},function(e){throw e})}catch(e){return Promise.reject(e)}},r=[{key:"active",get:function(){return this.en.promise}},{key:"controlling",get:function(){return this.on.promise}}],i(t.prototype,r),n&&i(t,n),t}(function(){function e(){this.Pn=new Map}var t=e.prototype;return t.addEventListener=function(e,t){this.Sn(e).add(t)},t.removeEventListener=function(e,t){this.Sn(e).delete(t)},t.dispatchEvent=function(e){e.target=this;for(var t,r=function(e){var t;if("u"<typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(t=function(e){if(e){if("string"==typeof e)return o(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?o(e,void 0):void 0}}(e))){t&&(e=t);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(t=e[Symbol.iterator]()).next.bind(t)}(this.Sn(e.type));!(t=r()).done;)(0,t.value)(e)},t.Sn=function(e){return this.Pn.has(e)||this.Pn.set(e,new Set),this.Pn.get(e)},e}()),m=void 0;function y(e,t){if(void 0!==m)return console.warn("The application's Service Worker has already been registered. The new service worker at ".concat(e," will not be registered.")),m;if(!("serviceWorker"in navigator))throw Error("Registering the Service Worker is not possible due to missing browser capabilities.");var r=new h(e,t);return m=r.register().then(function(){return r.controlling.then(function(){return r})})}function v(){return null!=m?m:Promise.resolve(void 0)}var g="x-egen-offline-response-body",b="x-egen-offline-response-status",x="x-egen-offline-caching-strategy";function w(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function S(e){var t;return(t=function(){var t,r;return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(n){switch(n.label){case 0:return[4,v()];case 1:if(!(t=n.sent()))return[3,3];return[4,t.messageSW(e)];case 2:return r=n.sent(),[3,4];case 3:r={success:!1,result:void 0,error:"No service worker has been registered. This is typically the case when the application has been built without offline-related features."},n.label=4;case 4:return[2,r]}})},function(){var e=this,r=arguments;return new Promise(function(n,a){var i=t.apply(e,r);function o(e){w(i,n,a,o,s,"next",e)}function s(e){w(i,n,a,o,s,"throw",e)}o(void 0)})})()}function j(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function O(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){j(i,n,a,o,s,"next",e)}function s(e){j(i,n,a,o,s,"throw",e)}o(void 0)})}}function k(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var E="egen3:offline-mode",P="unavailable";function A(){return{current:P,notAvailable:"unavailable"===P,active:"on"===P}}function D(e){"unavailable"!==P&&"unavailable"!==e&&(localStorage.setItem(E,"on"===e?"active":"disabled"),P=e)}function C(){return O(function(){return k(this,function(e){switch(e.label){case 0:return[4,O(function(){var e,t;return k(this,function(r){switch(r.label){case 0:return[4,O(function(){return k(this,function(e){return[2,new Promise(function(e){var t=indexedDB.open("test");t.onerror=function(){return e(!0)},t.onsuccess=function(){return e(!1)}})]})})()];case 1:if(t=r.sent())return[3,3];return[4,O(function(){return k(this,function(e){return[2,!window.indexedDB]})})()];case 2:t=r.sent(),r.label=3;case 3:if(e=t)return[3,5];return[4,O(function(){var e;return k(this,function(t){e=window.sessionStorage;try{e.setItem("someKeyHere","test"),e.removeItem("someKeyHere")}catch(t){if(t.code===DOMException.QUOTA_EXCEEDED_ERR&&0===e.length)return[2,!0]}return[2,!1]})})()];case 4:e=r.sent(),r.label=5;case 5:return[2,e]}})})()];case 1:return e.sent()||(P="active"===localStorage.getItem(E)?"on":"off"),navigator.onLine,[2]}})})()}let T="u">typeof globalThis?globalThis:"u">typeof self?self:"u">typeof window?window:global,N=Object.keys,R=Array.isArray;function M(e,t){return"object"!=typeof t||N(t).forEach(function(r){e[r]=t[r]}),e}"u"<typeof Promise||T.Promise||(T.Promise=Promise);let I=Object.getPrototypeOf,L={}.hasOwnProperty;function F(e,t){return L.call(e,t)}function B(e,t){"function"==typeof t&&(t=t(I(e))),("u"<typeof Reflect?N:Reflect.ownKeys)(t).forEach(r=>{z(e,r,t[r])})}let V=Object.defineProperty;function z(e,t,r,n){V(e,t,M(r&&F(r,"get")&&"function"==typeof r.get?{get:r.get,set:r.set,configurable:!0}:{value:r,configurable:!0,writable:!0},n))}function W(e){return{from:function(t){return e.prototype=Object.create(t.prototype),z(e.prototype,"constructor",e),{extend:B.bind(null,e.prototype)}}}}let $=Object.getOwnPropertyDescriptor;function U(e,t){let r;return $(e,t)||(r=I(e))&&U(r,t)}let H=[].slice;function G(e,t,r){return H.call(e,t,r)}function K(e,t){return t(e)}function q(e){if(!e)throw Error("Assertion Failed")}function Y(e){T.setImmediate?setImmediate(e):setTimeout(e,0)}function X(e,t){return e.reduce((e,r,n)=>{var a=t(r,n);return a&&(e[a[0]]=a[1]),e},{})}function Z(e,t){if("string"==typeof t&&F(e,t))return e[t];if(!t)return e;if("string"!=typeof t){for(var r=[],n=0,a=t.length;n<a;++n){var i=Z(e,t[n]);r.push(i)}return r}var o=t.indexOf(".");if(-1!==o){var s=e[t.substr(0,o)];return null==s?void 0:Z(s,t.substr(o+1))}}function Q(e,t,r){if(e&&void 0!==t&&(!("isFrozen"in Object)||!Object.isFrozen(e)))if("string"!=typeof t&&"length"in t){q("string"!=typeof r&&"length"in r);for(var n=0,a=t.length;n<a;++n)Q(e,t[n],r[n])}else{var i=t.indexOf(".");if(-1!==i){var o=t.substr(0,i),s=t.substr(i+1);if(""===s)void 0===r?R(e)&&!isNaN(parseInt(o))?e.splice(o,1):delete e[o]:e[o]=r;else{var l=e[o];l&&F(e,o)||(l=e[o]={}),Q(l,s,r)}}else void 0===r?R(e)&&!isNaN(parseInt(t))?e.splice(t,1):delete e[t]:e[t]=r}}function J(e){var t={};for(var r in e)F(e,r)&&(t[r]=e[r]);return t}let ee=[].concat;function et(e){return ee.apply([],e)}let er="BigUint64Array,BigInt64Array,Array,Boolean,String,Date,RegExp,Blob,File,FileList,FileSystemFileHandle,FileSystemDirectoryHandle,ArrayBuffer,DataView,Uint8ClampedArray,ImageBitmap,ImageData,Map,Set,CryptoKey".split(",").concat(et([8,16,32,64].map(e=>["Int","Uint","Float"].map(t=>t+e+"Array")))).filter(e=>T[e]),en=er.map(e=>T[e]);X(er,e=>[e,!0]);let ea=null;function ei(e){ea="u">typeof WeakMap&&new WeakMap;let t=function e(t){if(!t||"object"!=typeof t)return t;let r=ea&&ea.get(t);if(r)return r;if(R(t)){r=[],ea&&ea.set(t,r);for(var n=0,a=t.length;n<a;++n)r.push(e(t[n]))}else if(en.indexOf(t.constructor)>=0)r=t;else{let n=I(t);for(var i in r=n===Object.prototype?{}:Object.create(n),ea&&ea.set(t,r),t)F(t,i)&&(r[i]=e(t[i]))}return r}(e);return ea=null,t}let{toString:eo}={};function es(e){return eo.call(e).slice(8,-1)}let el="u">typeof Symbol?Symbol.iterator:"@@iterator",eu="symbol"==typeof el?function(e){var t;return null!=e&&(t=e[el])&&t.apply(e)}:function(){return null},ec={};function ed(e){var t,r,n,a;if(1==arguments.length){if(R(e))return e.slice();if(this===ec&&"string"==typeof e)return[e];if(a=eu(e)){for(r=[];!(n=a.next()).done;)r.push(n.value);return r}if(null==e)return[e];if("number"==typeof(t=e.length)){for(r=Array(t);t--;)r[t]=e[t];return r}return[e]}for(t=arguments.length,r=Array(t);t--;)r[t]=arguments[t];return r}let ef="u">typeof Symbol?e=>"AsyncFunction"===e[Symbol.toStringTag]:()=>!1;var ep="u">typeof location&&/^(http|https):\/\/(localhost|127\.0\.0\.1)/.test(location.href),eh=()=>!0;let em=!Error("").stack;function ey(){if(em)try{throw ey.arguments,Error()}catch(e){return e}return Error()}function ev(e,t){var r=e.stack;return r?(t=t||0,0===r.indexOf(e.name)&&(t+=(e.name+e.message).split("\n").length),r.split("\n").slice(t).filter(eh).map(e=>"\n"+e).join("")):""}var eg=["Unknown","Constraint","Data","TransactionInactive","ReadOnly","Version","NotFound","InvalidState","InvalidAccess","Abort","Timeout","QuotaExceeded","Syntax","DataClone"],eb=["Modify","Bulk","OpenFailed","VersionChange","Schema","Upgrade","InvalidTable","MissingAPI","NoSuchDatabase","InvalidArgument","SubTransaction","Unsupported","Internal","DatabaseClosed","PrematureCommit","ForeignAwait"].concat(eg),ex={VersionChanged:"Database version changed by other database connection",DatabaseClosed:"Database has been closed",Abort:"Transaction aborted",TransactionInactive:"Transaction has already completed or failed",MissingAPI:"IndexedDB API missing. Please visit https://tinyurl.com/y2uuvskb"};function ew(e,t){this._e=ey(),this.name=e,this.message=t}function eS(e,t){return e+". Errors: "+Object.keys(t).map(e=>t[e].toString()).filter((e,t,r)=>r.indexOf(e)===t).join("\n")}function ej(e,t,r,n){this._e=ey(),this.failures=t,this.failedKeys=n,this.successCount=r,this.message=eS(e,t)}function eO(e,t){this._e=ey(),this.name="BulkError",this.failures=Object.keys(t).map(e=>t[e]),this.failuresByPos=t,this.message=eS(e,t)}W(ew).from(Error).extend({stack:{get:function(){return this._stack||(this._stack=this.name+": "+this.message+ev(this._e,2))}},toString:function(){return this.name+": "+this.message}}),W(ej).from(ew),W(eO).from(ew);var ek=eb.reduce((e,t)=>(e[t]=t+"Error",e),{}),eE=eb.reduce((e,t)=>{var r=t+"Error";function n(e,n){this._e=ey(),this.name=r,e?"string"==typeof e?(this.message=`${e}${n?"\n "+n:""}`,this.inner=n||null):"object"==typeof e&&(this.message=`${e.name} ${e.message}`,this.inner=e):(this.message=ex[t]||r,this.inner=null)}return W(n).from(ew),e[t]=n,e},{});eE.Syntax=SyntaxError,eE.Type=TypeError,eE.Range=RangeError;var eP=eg.reduce((e,t)=>(e[t+"Error"]=eE[t],e),{}),eA=eb.reduce((e,t)=>(-1===["Syntax","Type","Range"].indexOf(t)&&(e[t+"Error"]=eE[t]),e),{});function eD(){}function eC(e){return e}function eT(e,t){return null==e||e===eC?t:function(r){return t(e(r))}}function eN(e,t){return function(){e.apply(this,arguments),t.apply(this,arguments)}}function eR(e,t){return e===eD?t:function(){var r=e.apply(this,arguments);void 0!==r&&(arguments[0]=r);var n=this.onsuccess,a=this.onerror;this.onsuccess=null,this.onerror=null;var i=t.apply(this,arguments);return n&&(this.onsuccess=this.onsuccess?eN(n,this.onsuccess):n),a&&(this.onerror=this.onerror?eN(a,this.onerror):a),void 0!==i?i:r}}function eM(e,t){return e===eD?t:function(){e.apply(this,arguments);var r=this.onsuccess,n=this.onerror;this.onsuccess=this.onerror=null,t.apply(this,arguments),r&&(this.onsuccess=this.onsuccess?eN(r,this.onsuccess):r),n&&(this.onerror=this.onerror?eN(n,this.onerror):n)}}function eI(e,t){return e===eD?t:function(r){var n=e.apply(this,arguments);M(r,n);var a=this.onsuccess,i=this.onerror;this.onsuccess=null,this.onerror=null;var o=t.apply(this,arguments);return a&&(this.onsuccess=this.onsuccess?eN(a,this.onsuccess):a),i&&(this.onerror=this.onerror?eN(i,this.onerror):i),void 0===n?void 0===o?void 0:o:M(n,o)}}function e_(e,t){return e===eD?t:function(){return!1!==t.apply(this,arguments)&&e.apply(this,arguments)}}function eL(e,t){return e===eD?t:function(){var r=e.apply(this,arguments);if(r&&"function"==typeof r.then){for(var n=this,a=arguments.length,i=Array(a);a--;)i[a]=arguments[a];return r.then(function(){return t.apply(n,i)})}return t.apply(this,arguments)}}eA.ModifyError=ej,eA.DexieError=ew,eA.BulkError=eO;var eF={};let[eB,eV,ez]="u"<typeof Promise?[]:(()=>{let e=Promise.resolve();if("u"<typeof crypto||!crypto.subtle)return[e,I(e),e];let t=crypto.subtle.digest("SHA-512",new Uint8Array([0]));return[t,I(t),e]})(),eW=eV&&eV.then,e$=eB&&eB.constructor,eU=!!ez;var eH=!1,eG=ez?()=>{ez.then(tn)}:T.setImmediate?setImmediate.bind(null,tn):T.MutationObserver?()=>{var e=document.createElement("div");new MutationObserver(()=>{tn(),e=null}).observe(e,{attributes:!0}),e.setAttribute("i","1")}:()=>{setTimeout(tn,0)},eK=function(e,t){e2.push([e,t]),eY&&(eG(),eY=!1)},eq=!0,eY=!0,eX=[],eZ=[],eQ=null,eJ=eC,e0={id:"global",global:!0,ref:0,unhandleds:[],onunhandled:tP,pgp:!1,env:{},finalize:function(){this.unhandleds.forEach(e=>{try{tP(e[0],e[1])}catch(e){}})}},e1=e0,e2=[],e3=0,e4=[];function e5(e){if("object"!=typeof this)throw TypeError("Promises must be constructed via new");this._listeners=[],this.onuncatched=eD,this._lib=!1;var t=this._PSD=e1;if(ep&&(this._stackHolder=ey(),this._prev=null,this._numPrev=0),"function"!=typeof e){if(e!==eF)throw TypeError("Not a function");return this._state=arguments[1],this._value=arguments[2],void(!1===this._state&&e9(this,this._value))}this._state=null,this._value=null,++t.ref,function e(t,r){try{r(r=>{if(null===t._state){if(r===t)throw TypeError("A promise cannot be resolved with itself.");var n=t._lib&&ta();r&&"function"==typeof r.then?e(t,(e,t)=>{r instanceof e5?r._then(e,t):r.then(e,t)}):(t._state=!0,t._value=r,e7(t)),n&&ti()}},e9.bind(null,t))}catch(e){e9(t,e)}}(this,e)}let e6={get:function(){var e=e1,t=tp;function r(r,n){var a=!e.global&&(e!==e1||t!==tp);let i=a&&!tv();var o=new e5((t,o)=>{te(this,new e8(tO(r,e,a,i),tO(n,e,a,i),t,o,e))});return ep&&tr(o,this),o}return r.prototype=eF,r},set:function(e){z(this,"then",e&&e.prototype===eF?e6:{get:function(){return e},set:e6.set})}};function e8(e,t,r,n,a){this.onFulfilled="function"==typeof e?e:null,this.onRejected="function"==typeof t?t:null,this.resolve=r,this.reject=n,this.psd=a}function e9(e,t){if(eZ.push(t),null===e._state){var r=e._lib&&ta();t=eJ(t),e._state=!1,e._value=t,ep&&null!==t&&"object"==typeof t&&!t._promise&&function(e){try{e.apply(null,void 0)}catch(e){}}(()=>{var r=U(t,"stack");t._promise=e,z(t,"stack",{get:()=>eH?r&&(r.get?r.get.apply(t):r.value):e.stack})}),eX.some(t=>t._value===e._value)||eX.push(e),e7(e),r&&ti()}}function e7(e){var t=e._listeners;e._listeners=[];for(var r=0,n=t.length;r<n;++r)te(e,t[r]);var a=e._PSD;--a.ref||a.finalize(),0===e3&&(++e3,eK(()=>{0==--e3&&to()},[]))}function te(e,t){if(null!==e._state){var r=e._state?t.onFulfilled:t.onRejected;if(null===r)return(e._state?t.resolve:t.reject)(e._value);++t.psd.ref,++e3,eK(tt,[r,e,t])}else e._listeners.push(t)}function tt(e,t,r){try{eQ=t;var n,a=t._value;t._state?n=e(a):(eZ.length&&(eZ=[]),n=e(a),-1===eZ.indexOf(a)&&function(e){for(var t=eX.length;t;)if(eX[--t]._value===e._value)return void eX.splice(t,1)}(t)),r.resolve(n)}catch(e){r.reject(e)}finally{eQ=null,0==--e3&&to(),--r.psd.ref||r.psd.finalize()}}function tr(e,t){var r=t?t._numPrev+1:0;r<100&&(e._prev=t,e._numPrev=r)}function tn(){ta()&&ti()}function ta(){var e=eq;return eq=!1,eY=!1,e}function ti(){var e,t,r;do for(;e2.length>0;)for(e=e2,e2=[],r=e.length,t=0;t<r;++t){var n=e[t];n[0].apply(null,n[1])}while(e2.length>0);eq=!0,eY=!0}function to(){var e=eX;eX=[],e.forEach(e=>{e._PSD.onunhandled.call(null,e._value,e)});for(var t=e4.slice(0),r=t.length;r;)t[--r]()}function ts(e){return new e5(eF,!1,e)}function tl(e,t){var r=e1;return function(){var n=ta(),a=e1;try{return tw(r,!0),e.apply(this,arguments)}catch(e){t&&t(e)}finally{tw(a,!1),n&&ti()}}}B(e5.prototype,{then:e6,_then:function(e,t){te(this,new e8(null,null,e,t,e1))},catch:function(e){if(1==arguments.length)return this.then(null,e);var t=arguments[0],r=arguments[1];return"function"==typeof t?this.then(null,e=>e instanceof t?r(e):ts(e)):this.then(null,e=>e&&e.name===t?r(e):ts(e))},finally:function(e){return this.then(t=>(e(),t),t=>(e(),ts(t)))},stack:{get:function(){if(this._stack)return this._stack;try{eH=!0;var e=(function e(t,r,n){if(r.length===n)return r;var a="";if(!1===t._state){var i,o,s=t._value;null!=s?(i=s.name||"Error",o=s.message||s,a=ev(s,0)):(i=s,o=""),r.push(i+(o?": "+o:"")+a)}return ep&&((a=ev(t._stackHolder,2))&&-1===r.indexOf(a)&&r.push(a),t._prev&&e(t._prev,r,n)),r})(this,[],20).join("\nFrom previous: ");return null!==this._state&&(this._stack=e),e}finally{eH=!1}}},timeout:function(e,t){return e<1/0?new e5((r,n)=>{var a=setTimeout(()=>n(new eE.Timeout(t)),e);this.then(r,n).finally(clearTimeout.bind(null,a))}):this}}),"u">typeof Symbol&&Symbol.toStringTag&&z(e5.prototype,Symbol.toStringTag,"Dexie.Promise"),e0.env=tS(),B(e5,{all:function(){var e=ed.apply(null,arguments).map(tg);return new e5(function(t,r){0===e.length&&t([]);var n=e.length;e.forEach((a,i)=>e5.resolve(a).then(r=>{e[i]=r,--n||t(e)},r))})},resolve:e=>{if(e instanceof e5)return e;if(e&&"function"==typeof e.then)return new e5((t,r)=>{e.then(t,r)});var t=new e5(eF,!0,e);return tr(t,eQ),t},reject:ts,race:function(){var e=ed.apply(null,arguments).map(tg);return new e5((t,r)=>{e.map(e=>e5.resolve(e).then(t,r))})},PSD:{get:()=>e1,set:e=>e1=e},totalEchoes:{get:()=>tp},newPSD:tm,usePSD:tj,scheduler:{get:()=>eK,set:e=>{eK=e}},rejectionMapper:{get:()=>eJ,set:e=>{eJ=e}},follow:(e,t)=>new e5((r,n)=>tm((t,r)=>{var n=e1;n.unhandleds=[],n.onunhandled=r,n.finalize=eN(function(){var e;e=()=>{0===this.unhandleds.length?t():r(this.unhandleds[0])},e4.push(function t(){e(),e4.splice(e4.indexOf(t),1)}),++e3,eK(()=>{0==--e3&&to()},[])},n.finalize),e()},t,r,n))}),e$&&(e$.allSettled&&z(e5,"allSettled",function(){let e=ed.apply(null,arguments).map(tg);return new e5(t=>{0===e.length&&t([]);let r=e.length,n=Array(r);e.forEach((e,a)=>e5.resolve(e).then(e=>n[a]={status:"fulfilled",value:e},e=>n[a]={status:"rejected",reason:e}).then(()=>--r||t(n)))})}),e$.any&&"u">typeof AggregateError&&z(e5,"any",function(){let e=ed.apply(null,arguments).map(tg);return new e5((t,r)=>{0===e.length&&r(AggregateError([]));let n=e.length,a=Array(n);e.forEach((e,i)=>e5.resolve(e).then(e=>t(e),e=>{a[i]=e,--n||r(AggregateError(a))}))})}));let tu={awaits:0,echoes:0,id:0};var tc=0,td=[],tf=0,tp=0,th=0;function tm(e,t,r,n){var a=e1,i=Object.create(a);i.parent=a,i.ref=0,i.global=!1,i.id=++th;var o=e0.env;i.env=eU?{Promise:e5,PromiseProp:{value:e5,configurable:!0,writable:!0},all:e5.all,race:e5.race,allSettled:e5.allSettled,any:e5.any,resolve:e5.resolve,reject:e5.reject,nthen:tk(o.nthen,i),gthen:tk(o.gthen,i)}:{},t&&M(i,t),++a.ref,i.finalize=function(){--this.parent.ref||this.parent.finalize()};var s=tj(i,e,r,n);return 0===i.ref&&i.finalize(),s}function ty(){return tu.id||(tu.id=++tc),++tu.awaits,tu.echoes+=100,tu.id}function tv(){return!!tu.awaits&&(0==--tu.awaits&&(tu.id=0),tu.echoes=100*tu.awaits,!0)}function tg(e){return tu.echoes&&e&&e.constructor===e$?(ty(),e.then(e=>(tv(),e),e=>(tv(),tA(e)))):e}function tb(e){++tp,tu.echoes&&0!=--tu.echoes||(tu.echoes=tu.id=0),td.push(e1),tw(e,!0)}function tx(){var e=td[td.length-1];td.pop(),tw(e,!1)}function tw(e,t){var r,n=e1;if((t?!tu.echoes||tf++&&e===e1:!tf||--tf&&e===e1)||(r=t?tb.bind(null,e):tx,eW.call(eB,r)),e!==e1&&(e1=e,n===e0&&(e0.env=tS()),eU)){var a=e0.env.Promise,i=e.env;eV.then=i.nthen,a.prototype.then=i.gthen,(n.global||e.global)&&(Object.defineProperty(T,"Promise",i.PromiseProp),a.all=i.all,a.race=i.race,a.resolve=i.resolve,a.reject=i.reject,i.allSettled&&(a.allSettled=i.allSettled),i.any&&(a.any=i.any))}}function tS(){var e=T.Promise;return eU?{Promise:e,PromiseProp:Object.getOwnPropertyDescriptor(T,"Promise"),all:e.all,race:e.race,allSettled:e.allSettled,any:e.any,resolve:e.resolve,reject:e.reject,nthen:eV.then,gthen:e.prototype.then}:{}}function tj(e,t,r,n,a){var i=e1;try{return tw(e,!0),t(r,n,a)}finally{tw(i,!1)}}function tO(e,t,r,n){return"function"!=typeof e?e:function(){var a,i=e1;r&&ty(),tw(t,!0);try{return e.apply(this,arguments)}finally{tw(i,!1),n&&(a=tv,eW.call(eB,a))}}}function tk(e,t){return function(r,n){return e.call(this,tO(r,t),tO(n,t))}}-1===(""+eW).indexOf("[native code]")&&(ty=tv=eD);let tE="unhandledrejection";function tP(e,t){var r;try{r=t.onuncatched(e)}catch(e){}if(!1!==r)try{var n,a={promise:t,reason:e};if(T.document&&document.createEvent?((n=document.createEvent("Event")).initEvent(tE,!0,!0),M(n,a)):T.CustomEvent&&M(n=new CustomEvent(tE,{detail:a}),a),n&&T.dispatchEvent&&(dispatchEvent(n),!T.PromiseRejectionEvent&&T.onunhandledrejection))try{T.onunhandledrejection(n)}catch(e){}ep&&n&&!n.defaultPrevented&&console.warn(`Unhandled rejection: ${e.stack||e}`)}catch(e){}}var tA=e5.reject;let tD="3.2.7",tC=String.fromCharCode(65535),tT=-1/0,tN="Invalid key provided. Keys must be of type string, number, Date or Array<string | number | Date>.",tR="String expected.",tM=[],tI="u">typeof navigator&&/(MSIE|Trident|Edge)/.test(navigator.userAgent),t_=e=>!/(dexie\.js|dexie\.min\.js)/.test(e),tL="__dbnames",tF="readonly",tB="readwrite";function tV(e,t){return e?t?function(){return e.apply(this,arguments)&&t.apply(this,arguments)}:e:t}let tz={type:3,lower:-1/0,lowerOpen:!1,upper:[[]],upperOpen:!1};function tW(e){return"string"!=typeof e||/\./.test(e)?e=>e:t=>(void 0===t[e]&&e in t&&delete(t=ei(t))[e],t)}class t${_trans(e,t,r){let n=this._tx||e1.trans,a=this.name;function i(e,r,n){if(!n.schema[a])throw new eE.NotFound("Table "+a+" not part of transaction");return t(n.idbtrans,n)}let o=ta();try{return n&&n.db===this.db?n===e1.trans?n._promise(e,i,r):tm(()=>n._promise(e,i,r),{trans:n,transless:e1.transless||e1}):function e(t,r,n,a){if(t.idbdb&&(t._state.openComplete||e1.letThrough||t._vip)){var i=t._createTransaction(r,n,t._dbSchema);try{i.create(),t._state.PR1398_maxLoop=3}catch(i){return i.name===ek.InvalidState&&t.isOpen()&&--t._state.PR1398_maxLoop>0?(console.warn("Dexie: Need to reopen db"),t._close(),t.open().then(()=>e(t,r,n,a))):tA(i)}return i._promise(r,(e,t)=>tm(()=>(e1.trans=i,a(e,t,i)))).then(e=>i._completion.then(()=>e))}if(t._state.openComplete)return tA(new eE.DatabaseClosed(t._state.dbOpenError));if(!t._state.isBeingOpened){if(!t._options.autoOpen)return tA(new eE.DatabaseClosed);t.open().catch(eD)}return t._state.dbReadyPromise.then(()=>e(t,r,n,a))}(this.db,e,[this.name],i)}finally{o&&ti()}}get(e,t){return e&&e.constructor===Object?this.where(e).first(t):this._trans("readonly",t=>this.core.get({trans:t,key:e}).then(e=>this.hook.reading.fire(e))).then(t)}where(e){if("string"==typeof e)return new this.db.WhereClause(this,e);if(R(e))return new this.db.WhereClause(this,`[${e.join("+")}]`);let t=N(e);if(1===t.length)return this.where(t[0]).equals(e[t[0]]);let r=this.schema.indexes.concat(this.schema.primKey).filter(e=>{if(e.compound&&t.every(t=>e.keyPath.indexOf(t)>=0)){for(let r=0;r<t.length;++r)if(-1===t.indexOf(e.keyPath[r]))return!1;return!0}return!1}).sort((e,t)=>e.keyPath.length-t.keyPath.length)[0];if(r&&this.db._maxKey!==tC){let n=r.keyPath.slice(0,t.length);return this.where(n).equals(n.map(t=>e[t]))}!r&&ep&&console.warn(`The query ${JSON.stringify(e)} on ${this.name} would benefit of a compound index [${t.join("+")}]`);let{idxByName:n}=this.schema,a=this.db._deps.indexedDB;function i(e,t){try{return 0===a.cmp(e,t)}catch(e){return!1}}let[o,s]=t.reduce(([t,r],a)=>{let o=n[a],s=e[a];return[t||o,t||!o?tV(r,o&&o.multi?e=>{let t=Z(e,a);return R(t)&&t.some(e=>i(s,e))}:e=>i(s,Z(e,a))):r]},[null,null]);return o?this.where(o.name).equals(e[o.keyPath]).filter(s):r?this.filter(s):this.where(t).equals("")}filter(e){return this.toCollection().and(e)}count(e){return this.toCollection().count(e)}offset(e){return this.toCollection().offset(e)}limit(e){return this.toCollection().limit(e)}each(e){return this.toCollection().each(e)}toArray(e){return this.toCollection().toArray(e)}toCollection(){return new this.db.Collection(new this.db.WhereClause(this))}orderBy(e){return new this.db.Collection(new this.db.WhereClause(this,R(e)?`[${e.join("+")}]`:e))}reverse(){return this.toCollection().reverse()}mapToClass(e){this.schema.mappedClass=e;let t=t=>{if(!t)return t;let r=Object.create(e.prototype);for(var n in t)if(F(t,n))try{r[n]=t[n]}catch(e){}return r};return this.schema.readHook&&this.hook.reading.unsubscribe(this.schema.readHook),this.schema.readHook=t,this.hook("reading",t),e}defineClass(){return this.mapToClass(function(e){M(this,e)})}add(e,t){let{auto:r,keyPath:n}=this.schema.primKey,a=e;return n&&r&&(a=tW(n)(e)),this._trans("readwrite",e=>this.core.mutate({trans:e,type:"add",keys:null!=t?[t]:null,values:[a]})).then(e=>e.numFailures?e5.reject(e.failures[0]):e.lastResult).then(t=>{if(n)try{Q(e,n,t)}catch(e){}return t})}update(e,t){if("object"!=typeof e||R(e))return this.where(":id").equals(e).modify(t);{let r=Z(e,this.schema.primKey.keyPath);if(void 0===r)return tA(new eE.InvalidArgument("Given object does not contain its primary key"));try{"function"!=typeof t?N(t).forEach(r=>{Q(e,r,t[r])}):t(e,{value:e,primKey:r})}catch(e){}return this.where(":id").equals(r).modify(t)}}put(e,t){let{auto:r,keyPath:n}=this.schema.primKey,a=e;return n&&r&&(a=tW(n)(e)),this._trans("readwrite",e=>this.core.mutate({trans:e,type:"put",values:[a],keys:null!=t?[t]:null})).then(e=>e.numFailures?e5.reject(e.failures[0]):e.lastResult).then(t=>{if(n)try{Q(e,n,t)}catch(e){}return t})}delete(e){return this._trans("readwrite",t=>this.core.mutate({trans:t,type:"delete",keys:[e]})).then(e=>e.numFailures?e5.reject(e.failures[0]):void 0)}clear(){return this._trans("readwrite",e=>this.core.mutate({trans:e,type:"deleteRange",range:tz})).then(e=>e.numFailures?e5.reject(e.failures[0]):void 0)}bulkGet(e){return this._trans("readonly",t=>this.core.getMany({keys:e,trans:t}).then(e=>e.map(e=>this.hook.reading.fire(e))))}bulkAdd(e,t,r){let n=Array.isArray(t)?t:void 0,a=(r=r||(n?void 0:t))?r.allKeys:void 0;return this._trans("readwrite",t=>{let{auto:r,keyPath:i}=this.schema.primKey;if(i&&n)throw new eE.InvalidArgument("bulkAdd(): keys argument invalid on tables with inbound keys");if(n&&n.length!==e.length)throw new eE.InvalidArgument("Arguments objects and keys must have the same length");let o=e.length,s=i&&r?e.map(tW(i)):e;return this.core.mutate({trans:t,type:"add",keys:n,values:s,wantResults:a}).then(({numFailures:e,results:t,lastResult:r,failures:n})=>{if(0===e)return a?t:r;throw new eO(`${this.name}.bulkAdd(): ${e} of ${o} operations failed`,n)})})}bulkPut(e,t,r){let n=Array.isArray(t)?t:void 0,a=(r=r||(n?void 0:t))?r.allKeys:void 0;return this._trans("readwrite",t=>{let{auto:r,keyPath:i}=this.schema.primKey;if(i&&n)throw new eE.InvalidArgument("bulkPut(): keys argument invalid on tables with inbound keys");if(n&&n.length!==e.length)throw new eE.InvalidArgument("Arguments objects and keys must have the same length");let o=e.length,s=i&&r?e.map(tW(i)):e;return this.core.mutate({trans:t,type:"put",keys:n,values:s,wantResults:a}).then(({numFailures:e,results:t,lastResult:r,failures:n})=>{if(0===e)return a?t:r;throw new eO(`${this.name}.bulkPut(): ${e} of ${o} operations failed`,n)})})}bulkDelete(e){let t=e.length;return this._trans("readwrite",t=>this.core.mutate({trans:t,type:"delete",keys:e})).then(({numFailures:e,lastResult:r,failures:n})=>{if(0===e)return r;throw new eO(`${this.name}.bulkDelete(): ${e} of ${t} operations failed`,n)})}}function tU(e){var t={},r=function(r,n){if(n){for(var a=arguments.length,i=Array(a-1);--a;)i[a-1]=arguments[a];return t[r].subscribe.apply(null,i),e}if("string"==typeof r)return t[r]};r.addEventType=i;for(var n=1,a=arguments.length;n<a;++n)i(arguments[n]);return r;function i(e,n,a){if("object"!=typeof e){n||(n=e_),a||(a=eD);var o={subscribers:[],fire:a,subscribe:function(e){-1===o.subscribers.indexOf(e)&&(o.subscribers.push(e),o.fire=n(o.fire,e))},unsubscribe:function(e){o.subscribers=o.subscribers.filter(function(t){return t!==e}),o.fire=o.subscribers.reduce(n,a)}};return t[e]=r[e]=o,o}N(e).forEach(function(t){var r=e[t];if(R(r))i(t,e[t][0],e[t][1]);else{if("asap"!==r)throw new eE.InvalidArgument("Invalid event config");var n=i(t,eC,function(){for(var e=arguments.length,t=Array(e);e--;)t[e]=arguments[e];n.subscribers.forEach(function(e){Y(function(){e.apply(null,t)})})})}})}}function tH(e,t){return W(t).from({prototype:e}),t}function tG(e,t){return!(e.filter||e.algorithm||e.or)&&(t?e.justLimit:!e.replayFilter)}function tK(e,t){e.filter=tV(e.filter,t)}function tq(e,t,r){var n=e.replayFilter;e.replayFilter=n?()=>tV(n(),t()):t,e.justLimit=r&&!n}function tY(e,t){if(e.isPrimKey)return t.primaryKey;let r=t.getIndexByKeyPath(e.index);if(!r)throw new eE.Schema("KeyPath "+e.index+" on object store "+t.name+" is not indexed");return r}function tX(e,t,r){let n=tY(e,t.schema);return t.openCursor({trans:r,values:!e.keysOnly,reverse:"prev"===e.dir,unique:!!e.unique,query:{index:n,range:e.range}})}function tZ(e,t,r,n){let a=e.replayFilter?tV(e.filter,e.replayFilter()):e.filter;if(e.or){let i={},o=(e,r,n)=>{if(!a||a(r,n,e=>r.stop(e),e=>r.fail(e))){var o=r.primaryKey,s=""+o;"[object ArrayBuffer]"===s&&(s=""+new Uint8Array(o)),F(i,s)||(i[s]=!0,t(e,r,n))}};return Promise.all([e.or._iterate(o,r),tQ(tX(e,n,r),e.algorithm,o,!e.keysOnly&&e.valueMapper)])}return tQ(tX(e,n,r),tV(e.algorithm,a),t,!e.keysOnly&&e.valueMapper)}function tQ(e,t,r,n){var a=tl(n?(e,t,a)=>r(n(e),t,a):r);return e.then(e=>{if(e)return e.start(()=>{var r=()=>e.continue();t&&!t(e,e=>r=e,t=>{e.stop(t),r=eD},t=>{e.fail(t),r=eD})||a(e.value,e,e=>r=e),r()})})}function tJ(e,t){try{let r=t0(e),n=t0(t);if(r!==n)return"Array"===r?1:"Array"===n?-1:"binary"===r?1:"binary"===n?-1:"string"===r?1:"string"===n?-1:"Date"===r?1:"Date"!==n?NaN:-1;switch(r){case"number":case"Date":case"string":return e>t?1:e<t?-1:0;case"binary":return function(e,t){let r=e.length,n=t.length,a=r<n?r:n;for(let r=0;r<a;++r)if(e[r]!==t[r])return e[r]<t[r]?-1:1;return r===n?0:r<n?-1:1}(t1(e),t1(t));case"Array":return function(e,t){let r=e.length,n=t.length,a=r<n?r:n;for(let r=0;r<a;++r){let n=tJ(e[r],t[r]);if(0!==n)return n}return r===n?0:r<n?-1:1}(e,t)}}catch(e){}return NaN}function t0(e){let t=typeof e;if("object"!==t)return t;if(ArrayBuffer.isView(e))return"binary";let r=es(e);return"ArrayBuffer"===r?"binary":r}function t1(e){return e instanceof Uint8Array?e:ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e)}class t2{_read(e,t){var r=this._ctx;return r.error?r.table._trans(null,tA.bind(null,r.error)):r.table._trans("readonly",e).then(t)}_write(e){var t=this._ctx;return t.error?t.table._trans(null,tA.bind(null,t.error)):t.table._trans("readwrite",e,"locked")}_addAlgorithm(e){var t=this._ctx;t.algorithm=tV(t.algorithm,e)}_iterate(e,t){return tZ(this._ctx,e,t,this._ctx.table.core)}clone(e){var t=Object.create(this.constructor.prototype),r=Object.create(this._ctx);return e&&M(r,e),t._ctx=r,t}raw(){return this._ctx.valueMapper=null,this}each(e){var t=this._ctx;return this._read(r=>tZ(t,e,r,t.table.core))}count(e){return this._read(e=>{let t=this._ctx,r=t.table.core;if(tG(t,!0))return r.count({trans:e,query:{index:tY(t,r.schema),range:t.range}}).then(e=>Math.min(e,t.limit));var n=0;return tZ(t,()=>(++n,!1),e,r).then(()=>n)}).then(e)}sortBy(e,t){let r=e.split(".").reverse(),n=r[0],a=r.length-1;function i(e,t){return t?i(e[r[t]],t-1):e[n]}var o="next"===this._ctx.dir?1:-1;function s(e,t){var r=i(e,a),n=i(t,a);return r<n?-o:r>n?o:0}return this.toArray(function(e){return e.sort(s)}).then(t)}toArray(e){return this._read(e=>{var t=this._ctx;if("next"===t.dir&&tG(t,!0)&&t.limit>0){let{valueMapper:r}=t,n=tY(t,t.table.core.schema);return t.table.core.query({trans:e,limit:t.limit,values:!0,query:{index:n,range:t.range}}).then(({result:e})=>r?e.map(r):e)}{let r=[];return tZ(t,e=>r.push(e),e,t.table.core).then(()=>r)}},e)}offset(e){var t=this._ctx;return e<=0||(t.offset+=e,tG(t)?tq(t,()=>{var t=e;return(e,r)=>0===t||(1===t?--t:r(()=>{e.advance(t),t=0}),!1)}):tq(t,()=>{var t=e;return()=>--t<0})),this}limit(e){return this._ctx.limit=Math.min(this._ctx.limit,e),tq(this._ctx,()=>{var t=e;return function(e,r,n){return--t<=0&&r(n),t>=0}},!0),this}until(e,t){return tK(this._ctx,function(r,n,a){return!e(r.value)||(n(a),t)}),this}first(e){return this.limit(1).toArray(function(e){return e[0]}).then(e)}last(e){return this.reverse().first(e)}filter(e){var t;return tK(this._ctx,function(t){return e(t.value)}),(t=this._ctx).isMatch=tV(t.isMatch,e),this}and(e){return this.filter(e)}or(e){return new this.db.WhereClause(this._ctx.table,e,this)}reverse(){return this._ctx.dir="prev"===this._ctx.dir?"next":"prev",this._ondirectionchange&&this._ondirectionchange(this._ctx.dir),this}desc(){return this.reverse()}eachKey(e){var t=this._ctx;return t.keysOnly=!t.isMatch,this.each(function(t,r){e(r.key,r)})}eachUniqueKey(e){return this._ctx.unique="unique",this.eachKey(e)}eachPrimaryKey(e){var t=this._ctx;return t.keysOnly=!t.isMatch,this.each(function(t,r){e(r.primaryKey,r)})}keys(e){var t=this._ctx;t.keysOnly=!t.isMatch;var r=[];return this.each(function(e,t){r.push(t.key)}).then(function(){return r}).then(e)}primaryKeys(e){var t=this._ctx;if("next"===t.dir&&tG(t,!0)&&t.limit>0)return this._read(e=>{var r=tY(t,t.table.core.schema);return t.table.core.query({trans:e,values:!1,limit:t.limit,query:{index:r,range:t.range}})}).then(({result:e})=>e).then(e);t.keysOnly=!t.isMatch;var r=[];return this.each(function(e,t){r.push(t.primaryKey)}).then(function(){return r}).then(e)}uniqueKeys(e){return this._ctx.unique="unique",this.keys(e)}firstKey(e){return this.limit(1).keys(function(e){return e[0]}).then(e)}lastKey(e){return this.reverse().firstKey(e)}distinct(){var e=this._ctx,t=e.index&&e.table.schema.idxByName[e.index];if(!t||!t.multi)return this;var r={};return tK(this._ctx,function(e){var t=e.primaryKey.toString(),n=F(r,t);return r[t]=!0,!n}),this}modify(e){var t=this._ctx;return this._write(r=>{var n;if("function"==typeof e)n=e;else{var a=N(e),i=a.length;n=function(t){for(var r=!1,n=0;n<i;++n){var o=a[n],s=e[o];Z(t,o)!==s&&(Q(t,o,s),r=!0)}return r}}let o=t.table.core,{outbound:s,extractKey:l}=o.schema.primaryKey,u=this.db._options.modifyChunkSize||200,c=[],d=0,f=[],p=(e,t)=>{let{failures:r,numFailures:n}=t;for(let t of(d+=e-n,N(r)))c.push(r[t])};return this.clone().primaryKeys().then(a=>{let i=c=>{let d=Math.min(u,a.length-c);return o.getMany({trans:r,keys:a.slice(c,c+d),cache:"immutable"}).then(f=>{let h=[],m=[],y=s?[]:null,v=[];for(let e=0;e<d;++e){let t=f[e],r={value:ei(t),primKey:a[c+e]};!1!==n.call(r,r.value,r)&&(null==r.value?v.push(a[c+e]):s||0===tJ(l(t),l(r.value))?(m.push(r.value),s&&y.push(a[c+e])):(v.push(a[c+e]),h.push(r.value)))}let g=tG(t)&&t.limit===1/0&&("function"!=typeof e||e===t3)&&{index:t.index,range:t.range};return Promise.resolve(h.length>0&&o.mutate({trans:r,type:"add",values:h}).then(e=>{for(let t in e.failures)v.splice(parseInt(t),1);p(h.length,e)})).then(()=>(m.length>0||g&&"object"==typeof e)&&o.mutate({trans:r,type:"put",keys:y,values:m,criteria:g,changeSpec:"function"!=typeof e&&e}).then(e=>p(m.length,e))).then(()=>(v.length>0||g&&e===t3)&&o.mutate({trans:r,type:"delete",keys:v,criteria:g}).then(e=>p(v.length,e))).then(()=>a.length>c+d&&i(c+u))})};return i(0).then(()=>{if(c.length>0)throw new ej("Error modifying one or more objects",c,d,f);return a.length})})})}delete(){var e=this._ctx,t=e.range;return tG(e)&&(e.isPrimKey&&!tI||3===t.type)?this._write(r=>{let{primaryKey:n}=e.table.core.schema;return e.table.core.count({trans:r,query:{index:n,range:t}}).then(n=>e.table.core.mutate({trans:r,type:"deleteRange",range:t}).then(({failures:e,lastResult:t,results:r,numFailures:a})=>{if(a)throw new ej("Could not delete some values",Object.keys(e).map(t=>e[t]),n-a);return n-a}))}):this.modify(t3)}}let t3=(e,t)=>t.value=null;function t4(e,t){return e<t?-1:+(e!==t)}function t5(e,t){return e>t?-1:+(e!==t)}function t6(e,t,r){var n=e instanceof rt?new e.Collection(e):e;return n._ctx.error=r?new r(t):TypeError(t),n}function t8(e){return new e.Collection(e,()=>re("")).limit(0)}function t9(e,t,r,n){var a,i,o,s,l,u,c,d=r.length;if(!r.every(e=>"string"==typeof e))return t6(e,tR);function f(e){a="next"===e?e=>e.toUpperCase():e=>e.toLowerCase(),i="next"===e?e=>e.toLowerCase():e=>e.toUpperCase(),o="next"===e?t4:t5;var t=r.map(function(e){return{lower:i(e),upper:a(e)}}).sort(function(e,t){return o(e.lower,t.lower)});s=t.map(function(e){return e.upper}),l=t.map(function(e){return e.lower}),u=e,c="next"===e?"":n}f("next");var p=new e.Collection(e,()=>t7(s[0],l[d-1]+n));p._ondirectionchange=function(e){f(e)};var h=0;return p._addAlgorithm(function(e,r,n){var a=e.key;if("string"!=typeof a)return!1;var f=i(a);if(t(f,l,h))return!0;for(var p=null,m=h;m<d;++m){var y=function(e,t,r,n,a,i){for(var o=Math.min(e.length,n.length),s=-1,l=0;l<o;++l){var u=t[l];if(u!==n[l])return 0>a(e[l],r[l])?e.substr(0,l)+r[l]+r.substr(l+1):0>a(e[l],n[l])?e.substr(0,l)+n[l]+r.substr(l+1):s>=0?e.substr(0,s)+t[s]+r.substr(s+1):null;0>a(e[l],u)&&(s=l)}return o<n.length&&"next"===i?e+r.substr(e.length):o<e.length&&"prev"===i?e.substr(0,r.length):s<0?null:e.substr(0,s)+n[s]+r.substr(s+1)}(a,f,s[m],l[m],o,u);null===y&&null===p?h=m+1:(null===p||o(p,y)>0)&&(p=y)}return r(null!==p?function(){e.continue(p+c)}:n),!1}),p}function t7(e,t,r,n){return{type:2,lower:e,upper:t,lowerOpen:r,upperOpen:n}}function re(e){return{type:1,lower:e,upper:e}}class rt{get Collection(){return this._ctx.table.db.Collection}between(e,t,r,n){r=!1!==r,n=!0===n;try{return this._cmp(e,t)>0||0===this._cmp(e,t)&&(r||n)&&(!r||!n)?t8(this):new this.Collection(this,()=>t7(e,t,!r,!n))}catch(e){return t6(this,tN)}}equals(e){return null==e?t6(this,tN):new this.Collection(this,()=>re(e))}above(e){return null==e?t6(this,tN):new this.Collection(this,()=>t7(e,void 0,!0))}aboveOrEqual(e){return null==e?t6(this,tN):new this.Collection(this,()=>t7(e,void 0,!1))}below(e){return null==e?t6(this,tN):new this.Collection(this,()=>t7(void 0,e,!1,!0))}belowOrEqual(e){return null==e?t6(this,tN):new this.Collection(this,()=>t7(void 0,e))}startsWith(e){return"string"!=typeof e?t6(this,tR):this.between(e,e+tC,!0,!0)}startsWithIgnoreCase(e){return""===e?this.startsWith(e):t9(this,(e,t)=>0===e.indexOf(t[0]),[e],tC)}equalsIgnoreCase(e){return t9(this,(e,t)=>e===t[0],[e],"")}anyOfIgnoreCase(){var e=ed.apply(ec,arguments);return 0===e.length?t8(this):t9(this,(e,t)=>-1!==t.indexOf(e),e,"")}startsWithAnyOfIgnoreCase(){var e=ed.apply(ec,arguments);return 0===e.length?t8(this):t9(this,(e,t)=>t.some(t=>0===e.indexOf(t)),e,tC)}anyOf(){let e=ed.apply(ec,arguments),t=this._cmp;try{e.sort(t)}catch(e){return t6(this,tN)}if(0===e.length)return t8(this);let r=new this.Collection(this,()=>t7(e[0],e[e.length-1]));r._ondirectionchange=r=>{t="next"===r?this._ascending:this._descending,e.sort(t)};let n=0;return r._addAlgorithm((r,a,i)=>{let o=r.key;for(;t(o,e[n])>0;)if(++n===e.length)return a(i),!1;return 0===t(o,e[n])||(a(()=>{r.continue(e[n])}),!1)}),r}notEqual(e){return this.inAnyRange([[tT,e],[e,this.db._maxKey]],{includeLowers:!1,includeUppers:!1})}noneOf(){let e=ed.apply(ec,arguments);if(0===e.length)return new this.Collection(this);try{e.sort(this._ascending)}catch(e){return t6(this,tN)}let t=e.reduce((e,t)=>e?e.concat([[e[e.length-1][1],t]]):[[tT,t]],null);return t.push([e[e.length-1],this.db._maxKey]),this.inAnyRange(t,{includeLowers:!1,includeUppers:!1})}inAnyRange(e,t){let r=this._cmp,n=this._ascending,a=this._descending,i=this._min,o=this._max;if(0===e.length)return t8(this);if(!e.every(e=>void 0!==e[0]&&void 0!==e[1]&&0>=n(e[0],e[1])))return t6(this,"First argument to inAnyRange() must be an Array of two-value Arrays [lower,upper] where upper must not be lower than lower",eE.InvalidArgument);let s=!t||!1!==t.includeLowers,l=t&&!0===t.includeUppers,u,c=n;function d(e,t){return c(e[0],t[0])}try{(u=e.reduce(function(e,t){let n=0,a=e.length;for(;n<a;++n){let a=e[n];if(0>r(t[0],a[1])&&r(t[1],a[0])>0){a[0]=i(a[0],t[0]),a[1]=o(a[1],t[1]);break}}return n===a&&e.push(t),e},[])).sort(d)}catch(e){return t6(this,tN)}let f=0,p=l?e=>n(e,u[f][1])>0:e=>n(e,u[f][1])>=0,h=s?e=>a(e,u[f][0])>0:e=>a(e,u[f][0])>=0,m=p,y=new this.Collection(this,()=>t7(u[0][0],u[u.length-1][1],!s,!l));return y._ondirectionchange=e=>{"next"===e?(m=p,c=n):(m=h,c=a),u.sort(d)},y._addAlgorithm((e,t,r)=>{for(var a=e.key;m(a);)if(++f===u.length)return t(r),!1;return!!(!p(a)&&!h(a))||(0===this._cmp(a,u[f][1])||0===this._cmp(a,u[f][0])||t(()=>{c===n?e.continue(u[f][0]):e.continue(u[f][1])}),!1)}),y}startsWithAnyOf(){let e=ed.apply(ec,arguments);return e.every(e=>"string"==typeof e)?0===e.length?t8(this):this.inAnyRange(e.map(e=>[e,e+tC])):t6(this,"startsWithAnyOf() only works with strings")}}function rr(e){return tl(function(t){return rn(t),e(t.target.error),!1})}function rn(e){e.stopPropagation&&e.stopPropagation(),e.preventDefault&&e.preventDefault()}let ra="storagemutated",ri="x-storagemutated-1",ro=tU(null,ra);class rs{_lock(){return q(!e1.global),++this._reculock,1!==this._reculock||e1.global||(e1.lockOwnerFor=this),this}_unlock(){if(q(!e1.global),0==--this._reculock)for(e1.global||(e1.lockOwnerFor=null);this._blockedFuncs.length>0&&!this._locked();){var e=this._blockedFuncs.shift();try{tj(e[1],e[0])}catch(e){}}return this}_locked(){return this._reculock&&e1.lockOwnerFor!==this}create(e){if(!this.mode)return this;let t=this.db.idbdb,r=this.db._state.dbOpenError;if(q(!this.idbtrans),!e&&!t)switch(r&&r.name){case"DatabaseClosedError":throw new eE.DatabaseClosed(r);case"MissingAPIError":throw new eE.MissingAPI(r.message,r);default:throw new eE.OpenFailed(r)}if(!this.active)throw new eE.TransactionInactive;return q(null===this._completion._state),(e=this.idbtrans=e||(this.db.core?this.db.core.transaction(this.storeNames,this.mode,{durability:this.chromeTransactionDurability}):t.transaction(this.storeNames,this.mode,{durability:this.chromeTransactionDurability}))).onerror=tl(t=>{rn(t),this._reject(e.error)}),e.onabort=tl(t=>{rn(t),this.active&&this._reject(new eE.Abort(e.error)),this.active=!1,this.on("abort").fire(t)}),e.oncomplete=tl(()=>{this.active=!1,this._resolve(),"mutatedParts"in e&&ro.storagemutated.fire(e.mutatedParts)}),this}_promise(e,t,r){if("readwrite"===e&&"readwrite"!==this.mode)return tA(new eE.ReadOnly("Transaction is readonly"));if(!this.active)return tA(new eE.TransactionInactive);if(this._locked())return new e5((n,a)=>{this._blockedFuncs.push([()=>{this._promise(e,t,r).then(n,a)},e1])});if(r)return tm(()=>{var e=new e5((e,r)=>{this._lock();let n=t(e,r,this);n&&n.then&&n.then(e,r)});return e.finally(()=>this._unlock()),e._lib=!0,e});var n=new e5((e,r)=>{var n=t(e,r,this);n&&n.then&&n.then(e,r)});return n._lib=!0,n}_root(){return this.parent?this.parent._root():this}waitFor(e){var t=this._root();let r=e5.resolve(e);if(t._waitingFor)t._waitingFor=t._waitingFor.then(()=>r);else{t._waitingFor=r,t._waitingQueue=[];var n=t.idbtrans.objectStore(t.storeNames[0]);!function e(){for(++t._spinCount;t._waitingQueue.length;)t._waitingQueue.shift()();t._waitingFor&&(n.get(-1/0).onsuccess=e)}()}var a=t._waitingFor;return new e5((e,n)=>{r.then(r=>t._waitingQueue.push(tl(e.bind(null,r))),e=>t._waitingQueue.push(tl(n.bind(null,e)))).finally(()=>{t._waitingFor===a&&(t._waitingFor=null)})})}abort(){this.active&&(this.active=!1,this.idbtrans&&this.idbtrans.abort(),this._reject(new eE.Abort))}table(e){let t=this._memoizedTables||(this._memoizedTables={});if(F(t,e))return t[e];let r=this.schema[e];if(!r)throw new eE.NotFound("Table "+e+" not part of transaction");let n=new this.db.Table(e,r,this);return n.core=this.db.core.table(e),t[e]=n,n}}function rl(e,t,r,n,a,i,o){return{name:e,keyPath:t,unique:r,multi:n,auto:a,compound:i,src:(r&&!o?"&":"")+(n?"*":"")+(a?"++":"")+ru(t)}}function ru(e){return"string"==typeof e?e:e?"["+[].join.call(e,"+")+"]":""}function rc(e,t,r){return{name:e,primKey:t,indexes:r,mappedClass:null,idxByName:X(r,e=>[e.name,e])}}let rd=e=>{try{return e.only([[]]),rd=()=>[[]],[[]]}catch(e){return rd=()=>tC,tC}};function rf(e){return null==e?()=>{}:"string"==typeof e?1===e.split(".").length?t=>t[e]:t=>Z(t,e):t=>Z(t,e)}function rp(e){return[].slice.call(e)}let rh=0;function rm(e){return null==e?":id":"string"==typeof e?e:`[${e.join("+")}]`}function ry({_novip:e},t){let r=t.db,n=function(e,t,{IDBKeyRange:r,indexedDB:n},a){var i;return{dbcore:(i=function(e,t,r){let n;function a(e){if(3===e.type)return null;if(4===e.type)throw Error("Cannot convert never type to IDBKeyRange");let{lower:r,upper:n,lowerOpen:a,upperOpen:i}=e;return void 0===r?void 0===n?null:t.upperBound(n,!!i):void 0===n?t.lowerBound(r,!!a):t.bound(r,n,!!a,!!i)}let{schema:i,hasGetAll:o}=(n=rp(e.objectStoreNames),{schema:{name:e.name,tables:n.map(e=>r.objectStore(e)).map(e=>{let{keyPath:t,autoIncrement:r}=e,n=R(t),a=null==t,i={},o={name:e.name,primaryKey:{name:null,isPrimaryKey:!0,outbound:a,compound:n,keyPath:t,autoIncrement:r,unique:!0,extractKey:rf(t)},indexes:rp(e.indexNames).map(t=>e.index(t)).map(e=>{let{name:t,unique:r,multiEntry:n,keyPath:a}=e,o={name:t,compound:R(a),keyPath:a,unique:r,multiEntry:n,extractKey:rf(a)};return i[rm(a)]=o,o}),getIndexByKeyPath:e=>i[rm(e)]};return i[":id"]=o.primaryKey,null!=t&&(i[rm(t)]=o.primaryKey),o})},hasGetAll:n.length>0&&"getAll"in r.objectStore(n[0])&&!("u">typeof navigator&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604)}),s=i.tables.map(e=>{let t;return{name:t=e.name,schema:e,mutate:function({trans:e,type:r,keys:n,values:i,range:o}){return new Promise((s,l)=>{let u;s=tl(s);let c=e.objectStore(t),d=null==c.keyPath,f="put"===r||"add"===r;if(!f&&"delete"!==r&&"deleteRange"!==r)throw Error("Invalid operation type: "+r);let{length:p}=n||i||{length:1};if(n&&i&&n.length!==i.length)throw Error("Given keys array must have same length as given values array.");if(0===p)return s({numFailures:0,failures:{},results:[],lastResult:void 0});let h=[],m=[],y=0,v=e=>{++y,rn(e)};if("deleteRange"===r){if(4===o.type)return s({numFailures:y,failures:m,results:[],lastResult:void 0});3===o.type?h.push(u=c.clear()):h.push(u=c.delete(a(o)))}else{let[e,t]=f?d?[i,n]:[i,null]:[n,null];if(f)for(let n=0;n<p;++n)h.push(u=t&&void 0!==t[n]?c[r](e[n],t[n]):c[r](e[n])),u.onerror=v;else for(let t=0;t<p;++t)h.push(u=c[r](e[t])),u.onerror=v}let g=e=>{let t=e.target.result;h.forEach((e,t)=>null!=e.error&&(m[t]=e.error)),s({numFailures:y,failures:m,results:"delete"===r?n:h.map(e=>e.result),lastResult:t})};u.onerror=e=>{v(e),g(e)},u.onsuccess=g})},getMany:({trans:e,keys:r})=>new Promise((n,a)=>{n=tl(n);let i=e.objectStore(t),o=r.length,s=Array(o),l,u=0,c=0,d=e=>{let t=e.target;s[t._pos]=t.result,++c===u&&n(s)},f=rr(a);for(let e=0;e<o;++e)null!=r[e]&&((l=i.get(r[e]))._pos=e,l.onsuccess=d,l.onerror=f,++u);0===u&&n(s)}),get:({trans:e,key:r})=>new Promise((n,a)=>{n=tl(n);let i=e.objectStore(t).get(r);i.onsuccess=e=>n(e.target.result),i.onerror=rr(a)}),query:e=>new Promise((r,n)=>{r=tl(r);let{trans:i,values:s,limit:l,query:u}=e,c=l===1/0?void 0:l,{index:d,range:f}=u,p=i.objectStore(t),h=d.isPrimaryKey?p:p.index(d.name),m=a(f);if(0===l)return r({result:[]});if(o){let e=s?h.getAll(m,c):h.getAllKeys(m,c);e.onsuccess=e=>r({result:e.target.result}),e.onerror=rr(n)}else{let e=0,t=!s&&"openKeyCursor"in h?h.openKeyCursor(m):h.openCursor(m),a=[];t.onsuccess=n=>{let i=t.result;return i?(a.push(s?i.value:i.primaryKey),++e===l?r({result:a}):void i.continue()):r({result:a})},t.onerror=rr(n)}}),openCursor:function({trans:e,values:r,query:n,reverse:i,unique:o}){return new Promise((s,l)=>{s=tl(s);let{index:u,range:c}=n,d=e.objectStore(t),f=u.isPrimaryKey?d:d.index(u.name),p=i?o?"prevunique":"prev":o?"nextunique":"next",h=!r&&"openKeyCursor"in f?f.openKeyCursor(a(c),p):f.openCursor(a(c),p);h.onerror=rr(l),h.onsuccess=tl(t=>{let r=h.result;if(!r)return void s(null);r.___id=++rh,r.done=!1;let n=r.continue.bind(r),a=r.continuePrimaryKey;a&&(a=a.bind(r));let i=r.advance.bind(r),o=()=>{throw Error("Cursor not stopped")};r.trans=e,r.stop=r.continue=r.continuePrimaryKey=r.advance=()=>{throw Error("Cursor not started")},r.fail=tl(l),r.next=function(){let e=1;return this.start(()=>e--?this.continue():this.stop()).then(()=>this)},r.start=e=>{let t=new Promise((e,t)=>{e=tl(e),h.onerror=rr(t),r.fail=t,r.stop=t=>{r.stop=r.continue=r.continuePrimaryKey=r.advance=o,e(t)}}),s=()=>{if(h.result)try{e()}catch(e){r.fail(e)}else r.done=!0,r.start=()=>{throw Error("Cursor behind last entry")},r.stop()};return h.onsuccess=tl(e=>{h.onsuccess=s,s()}),r.continue=n,r.continuePrimaryKey=a,r.advance=i,s(),t},s(r)},l)})},count({query:e,trans:r}){let{index:n,range:i}=e;return new Promise((e,o)=>{let s=r.objectStore(t),l=n.isPrimaryKey?s:s.index(n.name),u=a(i),c=u?l.count(u):l.count();c.onsuccess=tl(t=>e(t.target.result)),c.onerror=rr(o)})}}}),l={};return s.forEach(e=>l[e.name]=e),{stack:"dbcore",transaction:e.transaction.bind(e),table(e){if(!l[e])throw Error(`Table '${e}' not found`);return l[e]},MIN_KEY:-1/0,MAX_KEY:rd(t),schema:i}}(t,r,a),e.dbcore.reduce((e,{create:t})=>({...e,...t(e)}),i))}}(e._middlewares,r,e._deps,t);e.core=n.dbcore,e.tables.forEach(t=>{let r=t.name;e.core.schema.tables.some(e=>e.name===r)&&(t.core=e.core.table(r),e[r]instanceof e.Table&&(e[r].core=t.core))})}function rv({_novip:e},t,r,n){r.forEach(r=>{let a=n[r];t.forEach(t=>{let n=U(t,r);(!n||"value"in n&&void 0===n.value)&&(t===e.Transaction.prototype||t instanceof e.Transaction?z(t,r,{get(){return this.table(r)},set(e){V(this,r,{value:e,writable:!0,configurable:!0,enumerable:!0})}}):t[r]=new e.Table(r,a))})})}function rg({_novip:e},t){t.forEach(t=>{for(let r in t)t[r]instanceof e.Table&&delete t[r]})}function rb(e,t){return e._cfg.version-t._cfg.version}function rx(e,t){let r,n={del:[],add:[],change:[]};for(r in e)t[r]||n.del.push(r);for(r in t){let a=e[r],i=t[r];if(a){let e={name:r,def:i,recreate:!1,del:[],add:[],change:[]};if(""+(a.primKey.keyPath||"")==""+(i.primKey.keyPath||"")&&(a.primKey.auto===i.primKey.auto||tI)){let t,r=a.idxByName,o=i.idxByName;for(t in r)o[t]||e.del.push(t);for(t in o){let n=r[t],a=o[t];n?n.src!==a.src&&e.change.push(a):e.add.push(a)}(e.del.length>0||e.add.length>0||e.change.length>0)&&n.change.push(e)}else e.recreate=!0,n.change.push(e)}else n.add.push([r,i])}return n}function rw(e,t,r,n){let a=e.db.createObjectStore(t,r.keyPath?{keyPath:r.keyPath,autoIncrement:r.auto}:{autoIncrement:r.auto});return n.forEach(e=>rS(a,e)),a}function rS(e,t){e.createIndex(t.name,t.keyPath,{unique:t.unique,multiEntry:t.multi})}function rj(e,t,r){let n={};return G(t.objectStoreNames,0).forEach(e=>{let t=r.objectStore(e),a=t.keyPath,i=rl(ru(a),a||"",!1,!1,!!t.autoIncrement,a&&"string"!=typeof a,!0),o=[];for(let e=0;e<t.indexNames.length;++e){let r=t.index(t.indexNames[e]);a=r.keyPath;var s=rl(r.name,a,!!r.unique,!!r.multiEntry,!1,a&&"string"!=typeof a,!1);o.push(s)}n[e]=rc(e,i,o)}),n}function rO({_novip:e},t,r){let n=r.db.objectStoreNames;for(let a=0;a<n.length;++a){let i=n[a],o=r.objectStore(i);e._hasGetAll="getAll"in o;for(let e=0;e<o.indexNames.length;++e){let r=o.indexNames[e],n=o.index(r).keyPath,a="string"==typeof n?n:"["+G(n).join("+")+"]";if(t[i]){let e=t[i].idxByName[a];e&&(e.name=r,delete t[i].idxByName[a],t[i].idxByName[r]=e)}}}"u">typeof navigator&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&T.WorkerGlobalScope&&T instanceof T.WorkerGlobalScope&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604&&(e._hasGetAll=!1)}class rk{_parseStoresSpec(e,t){N(e).forEach(r=>{if(null!==e[r]){var n=e[r].split(",").map((e,t)=>{let r=(e=e.trim()).replace(/([&*]|\+\+)/g,""),n=/^\[/.test(r)?r.match(/^\[(.*)\]$/)[1].split("+"):r;return rl(r,n||null,/\&/.test(e),/\*/.test(e),/\+\+/.test(e),R(n),0===t)}),a=n.shift();if(a.multi)throw new eE.Schema("Primary key cannot be multi-valued");n.forEach(e=>{if(e.auto)throw new eE.Schema("Only primary key can be marked as autoIncrement (++)");if(!e.keyPath)throw new eE.Schema("Index must have a name and cannot be an empty string")}),t[r]=rc(r,a,n)}})}stores(e){let t=this.db;this._cfg.storesSource=this._cfg.storesSource?M(this._cfg.storesSource,e):e;let r=t._versions,n={},a={};return r.forEach(e=>{M(n,e._cfg.storesSource),a=e._cfg.dbschema={},e._parseStoresSpec(n,a)}),t._dbSchema=a,rg(t,[t._allTables,t,t.Transaction.prototype]),rv(t,[t._allTables,t,t.Transaction.prototype,this._cfg.tables],N(a),a),t._storeNames=N(a),this}upgrade(e){return this._cfg.contentUpgrade=eL(this._cfg.contentUpgrade||eD,e),this}}function rE(e,t){let r=e._dbNamesDB;return r||(r=e._dbNamesDB=new rH(tL,{addons:[],indexedDB:e,IDBKeyRange:t})).version(1).stores({dbnames:"name"}),r.table("dbnames")}function rP(e){return e&&"function"==typeof e.databases}function rA(e){return tm(function(){return e1.letThrough=!0,e()})}function rD(e){var t=t=>e.next(t),r=a(t),n=a(t=>e.throw(t));function a(e){return t=>{var a=e(t),i=a.value;return a.done?i:i&&"function"==typeof i.then?i.then(r,n):R(i)?Promise.all(i).then(r,n):r(i)}}return a(t)()}function rC(e,t,r){var n=arguments.length;if(n<2)throw new eE.InvalidArgument("Too few arguments");for(var a=Array(n-1);--n;)a[n-1]=arguments[n];return r=a.pop(),[e,et(a),r]}function rT(e,t,r){let n=R(e)?e.slice():[e];for(let e=0;e<r;++e)n.push(t);return n}let rN={stack:"dbcore",name:"VirtualIndexMiddleware",level:1,create:function(e){return{...e,table(t){let r=e.table(t),{schema:n}=r,a={},i=[];function o(e,t,r){let n=rm(e),s=a[n]=a[n]||[],l=null==e?0:"string"==typeof e?1:e.length,u=t>0,c={...r,isVirtual:u,keyTail:t,keyLength:l,extractKey:rf(e),unique:!u&&r.unique};return s.push(c),c.isPrimaryKey||i.push(c),l>1&&o(2===l?e[0]:e.slice(0,l-1),t+1,r),s.sort((e,t)=>e.keyTail-t.keyTail),c}let s=o(n.primaryKey.keyPath,0,n.primaryKey);for(let e of(a[":id"]=[s],n.indexes))o(e.keyPath,0,e);function l(t){var r,n;let a=t.query.index;return a.isVirtual?{...t,query:{index:a,range:(r=t.query.range,n=a.keyTail,{type:1===r.type?2:r.type,lower:rT(r.lower,r.lowerOpen?e.MAX_KEY:e.MIN_KEY,n),lowerOpen:!0,upper:rT(r.upper,r.upperOpen?e.MIN_KEY:e.MAX_KEY,n),upperOpen:!0})}}:t}return{...r,schema:{...n,primaryKey:s,indexes:i,getIndexByKeyPath:function(e){let t=a[rm(e)];return t&&t[0]}},count:e=>r.count(l(e)),query:e=>r.query(l(e)),openCursor(t){let{keyTail:n,isVirtual:a,keyLength:i}=t.query.index;return a?r.openCursor(l(t)).then(r=>r&&Object.create(r,{continue:{value:function(a){null!=a?r.continue(rT(a,t.reverse?e.MAX_KEY:e.MIN_KEY,n)):t.unique?r.continue(r.key.slice(0,i).concat(t.reverse?e.MIN_KEY:e.MAX_KEY,n)):r.continue()}},continuePrimaryKey:{value(t,a){r.continuePrimaryKey(rT(t,e.MAX_KEY,n),a)}},primaryKey:{get:()=>r.primaryKey},key:{get(){let e=r.key;return 1===i?e[0]:e.slice(0,i)}},value:{get:()=>r.value}})):r.openCursor(t)}}}}}};function rR(e,t,r,n){return r=r||{},n=n||"",N(e).forEach(a=>{if(F(t,a)){var i=e[a],o=t[a];if("object"==typeof i&&"object"==typeof o&&i&&o){let e=es(i);e!==es(o)?r[n+a]=t[a]:"Object"===e?rR(i,o,r,n+a+"."):i!==o&&(r[n+a]=t[a])}else i!==o&&(r[n+a]=t[a])}else r[n+a]=void 0}),N(t).forEach(a=>{F(e,a)||(r[n+a]=t[a])}),r}let rM={stack:"dbcore",name:"HooksMiddleware",level:2,create:e=>({...e,table(t){let r=e.table(t),{primaryKey:n}=r.schema;return{...r,mutate(e){let a=e1.trans,{deleting:i,creating:o,updating:s}=a.table(t).hook;switch(e.type){case"add":if(o.fire===eD)break;return a._promise("readwrite",()=>l(e),!0);case"put":if(o.fire===eD&&s.fire===eD)break;return a._promise("readwrite",()=>l(e),!0);case"delete":if(i.fire===eD)break;return a._promise("readwrite",()=>l(e),!0);case"deleteRange":if(i.fire===eD)break;return a._promise("readwrite",()=>(function e(t,a,i){return r.query({trans:t,values:!1,query:{index:n,range:a},limit:i}).then(({result:r})=>l({type:"delete",keys:r,trans:t}).then(n=>n.numFailures>0?Promise.reject(n.failures[0]):r.length<i?{failures:[],numFailures:0,lastResult:void 0}:e(t,{...a,lower:r[r.length-1],lowerOpen:!0},i)))})(e.trans,e.range,1e4),!0)}return r.mutate(e);function l(e){var t,a;let l=e1.trans,u=e.keys||("delete"===(t=e).type?t.keys:t.keys||t.values.map(n.extractKey));if(!u)throw Error("Keys missing");return"delete"!==(e="add"===e.type||"put"===e.type?{...e,keys:u}:{...e}).type&&(e.values=[...e.values]),e.keys&&(e.keys=[...e.keys]),("add"===(a=e).type?Promise.resolve([]):r.getMany({trans:a.trans,keys:u,cache:"immutable"})).then(t=>{let a=u.map((r,a)=>{let u=t[a],c={onerror:null,onsuccess:null};if("delete"===e.type)i.fire.call(c,r,u,l);else if("add"===e.type||void 0===u){let t=o.fire.call(c,r,e.values[a],l);null==r&&null!=t&&(r=t,e.keys[a]=r,n.outbound||Q(e.values[a],n.keyPath,r))}else{let t=rR(u,e.values[a]),n=s.fire.call(c,t,r,u,l);if(n){let t=e.values[a];Object.keys(n).forEach(e=>{F(t,e)?t[e]=n[e]:Q(t,e,n[e])})}}return c});return r.mutate(e).then(({failures:r,results:n,numFailures:i,lastResult:o})=>{for(let i=0;i<u.length;++i){let o=n?n[i]:u[i],s=a[i];null==o?s.onerror&&s.onerror(r[i]):s.onsuccess&&s.onsuccess("put"===e.type&&t[i]?e.values[i]:o)}return{failures:r,results:n,numFailures:i,lastResult:o}}).catch(e=>(a.forEach(t=>t.onerror&&t.onerror(e)),Promise.reject(e)))})}}}}})};function rI(e,t,r){try{if(!t||t.keys.length<e.length)return null;let n=[];for(let a=0,i=0;a<t.keys.length&&i<e.length;++a)0===tJ(t.keys[a],e[i])&&(n.push(r?ei(t.values[a]):t.values[a]),++i);return n.length===e.length?n:null}catch(e){return null}}let r_={stack:"dbcore",level:-1,create:e=>({table:t=>{let r=e.table(t);return{...r,getMany:e=>{if(!e.cache)return r.getMany(e);let t=rI(e.keys,e.trans._cache,"clone"===e.cache);return t?e5.resolve(t):r.getMany(e).then(t=>(e.trans._cache={keys:e.keys,values:"clone"===e.cache?ei(t):t},t))},mutate:e=>("add"!==e.type&&(e.trans._cache=null),r.mutate(e))}}})};function rL(e){return!("from"in e)}let rF=function(e,t){if(!this){let t=new rF;return e&&"d"in e&&M(t,e),t}M(this,arguments.length?{d:1,from:e,to:arguments.length>1?t:e}:{d:0})};function rB(e,t,r){let n=tJ(t,r);if(isNaN(n))return;if(n>0)throw RangeError();if(rL(e))return M(e,{from:t,to:r,d:1});let a=e.l,i=e.r;if(0>tJ(r,e.from))return a?rB(a,t,r):e.l={from:t,to:r,d:1,l:null,r:null},rW(e);if(tJ(t,e.to)>0)return i?rB(i,t,r):e.r={from:t,to:r,d:1,l:null,r:null},rW(e);0>tJ(t,e.from)&&(e.from=t,e.l=null,e.d=i?i.d+1:1),tJ(r,e.to)>0&&(e.to=r,e.r=null,e.d=e.l?e.l.d+1:1);let o=!e.r;a&&!e.l&&rV(e,a),i&&o&&rV(e,i)}function rV(e,t){rL(t)||function e(t,{from:r,to:n,l:a,r:i}){rB(t,r,n),a&&e(t,a),i&&e(t,i)}(e,t)}function rz(e){let t=rL(e)?null:{s:0,n:e};return{next(e){let r=arguments.length>0;for(;t;)switch(t.s){case 0:if(t.s=1,r)for(;t.n.l&&0>tJ(e,t.n.from);)t={up:t,n:t.n.l,s:1};else for(;t.n.l;)t={up:t,n:t.n.l,s:1};case 1:if(t.s=2,!r||0>=tJ(e,t.n.to))return{value:t.n,done:!1};case 2:if(t.n.r){t.s=3,t={up:t,n:t.n.r,s:0};continue}case 3:t=t.up}return{done:!0}}}}function rW(e){var t,r;let n=((null==(t=e.r)?void 0:t.d)||0)-((null==(r=e.l)?void 0:r.d)||0),a=n>1?"r":n<-1?"l":"";if(a){let t="r"===a?"l":"r",r={...e},n=e[a];e.from=n.from,e.to=n.to,e[a]=n[a],r[a]=n[t],e[t]=r,r.d=r$(r)}e.d=r$(e)}function r$({r:e,l:t}){return(e?t?Math.max(e.d,t.d):e.d:t?t.d:0)+1}B(rF.prototype,{add(e){return rV(this,e),this},addKey(e){return rB(this,e,e),this},addKeys(e){return e.forEach(e=>rB(this,e,e)),this},[el](){return rz(this)}});let rU={stack:"dbcore",level:0,create:e=>{let t=e.schema.name,r=new rF(e.MIN_KEY,e.MAX_KEY);return{...e,table:n=>{let a=e.table(n),{schema:i}=a,{primaryKey:o}=i,{extractKey:s,outbound:l}=o,u={...a,mutate:e=>{let o=e.trans,s=o.mutatedParts||(o.mutatedParts={}),l=e=>{let r=`idb://${t}/${n}/${e}`;return s[r]||(s[r]=new rF)},u=l(""),c=l(":dels"),{type:d}=e,[f,p]="deleteRange"===e.type?[e.range]:"delete"===e.type?[e.keys]:e.values.length<50?[[],e.values]:[],h=e.trans._cache;return a.mutate(e).then(e=>{if(R(f)){"delete"!==d&&(f=e.results),u.addKeys(f);let t=rI(f,h);t||"add"===d||c.addKeys(f),(t||p)&&i.indexes.forEach(function(e){let r=l(e.name||"");function n(t){return null!=t?e.extractKey(t):null}let a=t=>e.multiEntry&&R(t)?t.forEach(e=>r.addKey(e)):r.addKey(t);(t||p).forEach((e,r)=>{let i=t&&n(t[r]),o=p&&n(p[r]);0!==tJ(i,o)&&(null!=i&&a(i),null!=o&&a(o))})})}else if(f){let e={from:f.lower,to:f.upper};c.add(e),u.add(e)}else u.add(r),c.add(r),i.indexes.forEach(e=>l(e.name).add(r));return e})}},c=({query:{index:t,range:r}})=>{var n,a;return[t,new rF(null!=(n=r.lower)?n:e.MIN_KEY,null!=(a=r.upper)?a:e.MAX_KEY)]},d={get:e=>[o,new rF(e.key)],getMany:e=>[o,(new rF).addKeys(e.keys)],count:c,query:c,openCursor:c};return N(d).forEach(e=>{u[e]=function(i){let{subscr:o}=e1;if(o){let u=e=>{let r=`idb://${t}/${n}/${e}`;return o[r]||(o[r]=new rF)},c=u(""),f=u(":dels"),[p,h]=d[e](i);if(u(p.name||"").add(h),!p.isPrimaryKey){if("count"!==e){let t="query"===e&&l&&i.values&&a.query({...i,values:!1});return a[e].apply(this,arguments).then(r=>{if("query"===e){if(l&&i.values)return t.then(({result:e})=>(c.addKeys(e),r));let e=i.values?r.result.map(s):r.result;i.values?c.addKeys(e):f.addKeys(e)}else if("openCursor"===e){let e=i.values;return r&&Object.create(r,{key:{get:()=>(f.addKey(r.primaryKey),r.key)},primaryKey:{get(){let e=r.primaryKey;return f.addKey(e),e}},value:{get:()=>(e&&c.addKey(r.primaryKey),r.value)}})}return r})}f.add(r)}}return a[e].apply(this,arguments)}}),u}}}};class rH{constructor(e,t){var r;this._middlewares={},this.verno=0;const n=rH.dependencies;this._options=t={addons:rH.addons,autoOpen:!0,indexedDB:n.indexedDB,IDBKeyRange:n.IDBKeyRange,...t},this._deps={indexedDB:t.indexedDB,IDBKeyRange:t.IDBKeyRange};const{addons:a}=t;this._dbSchema={},this._versions=[],this._storeNames=[],this._allTables={},this.idbdb=null,this._novip=this;const i={dbOpenError:null,isBeingOpened:!1,onReadyBeingFired:null,openComplete:!1,dbReadyResolve:eD,dbReadyPromise:null,cancelOpen:eD,openCanceller:null,autoSchema:!0,PR1398_maxLoop:3};i.dbReadyPromise=new e5(e=>{i.dbReadyResolve=e}),i.openCanceller=new e5((e,t)=>{i.cancelOpen=t}),this._state=i,this.name=e,this.on=tU(this,"populate","blocked","versionchange","close",{ready:[eL,eD]}),this.on.ready.subscribe=K(this.on.ready.subscribe,e=>(t,r)=>{rH.vip(()=>{let n=this._state;if(n.openComplete)n.dbOpenError||e5.resolve().then(t),r&&e(t);else if(n.onReadyBeingFired)n.onReadyBeingFired.push(t),r&&e(t);else{e(t);let n=this;r||e(function e(){n.on.ready.unsubscribe(t),n.on.ready.unsubscribe(e)})}})}),this.Collection=(r=this,tH(t2.prototype,function(e,t){this.db=r;let n=tz,a=null;if(t)try{n=t()}catch(e){a=e}let i=e._ctx,o=i.table,s=o.hook.reading.fire;this._ctx={table:o,index:i.index,isPrimKey:!i.index||o.schema.primKey.keyPath&&i.index===o.schema.primKey.name,range:n,keysOnly:!1,dir:"next",unique:"",algorithm:null,filter:null,replayFilter:null,justLimit:!0,isMatch:null,offset:0,limit:1/0,error:a,or:i.or,valueMapper:s!==eC?s:null}})),this.Table=function(e){return tH(t$.prototype,function(t,r,n){this.db=e,this._tx=n,this.name=t,this.schema=r,this.hook=e._allTables[t]?e._allTables[t].hook:tU(null,{creating:[eR,eD],reading:[eT,eC],updating:[eI,eD],deleting:[eM,eD]})})}(this),this.Transaction=function(e){return tH(rs.prototype,function(t,r,n,a,i){this.db=e,this.mode=t,this.storeNames=r,this.schema=n,this.chromeTransactionDurability=a,this.idbtrans=null,this.on=tU(this,"complete","error","abort"),this.parent=i||null,this.active=!0,this._reculock=0,this._blockedFuncs=[],this._resolve=null,this._reject=null,this._waitingFor=null,this._waitingQueue=null,this._spinCount=0,this._completion=new e5((e,t)=>{this._resolve=e,this._reject=t}),this._completion.then(()=>{this.active=!1,this.on.complete.fire()},e=>{var t=this.active;return this.active=!1,this.on.error.fire(e),this.parent?this.parent._reject(e):t&&this.idbtrans&&this.idbtrans.abort(),tA(e)})})}(this),this.Version=function(e){return tH(rk.prototype,function(t){this.db=e,this._cfg={version:t,storesSource:null,dbschema:{},tables:{},contentUpgrade:null}})}(this),this.WhereClause=function(e){return tH(rt.prototype,function(t,r,n){this.db=e,this._ctx={table:t,index:":id"===r?null:r,or:n};let a=e._deps.indexedDB;if(!a)throw new eE.MissingAPI;this._cmp=this._ascending=a.cmp.bind(a),this._descending=(e,t)=>a.cmp(t,e),this._max=(e,t)=>a.cmp(e,t)>0?e:t,this._min=(e,t)=>0>a.cmp(e,t)?e:t,this._IDBKeyRange=e._deps.IDBKeyRange})}(this),this.on("versionchange",e=>{e.newVersion>0?console.warn(`Another connection wants to upgrade database '${this.name}'. Closing db now to resume the upgrade.`):console.warn(`Another connection wants to delete database '${this.name}'. Closing db now to resume the delete request.`),this.close()}),this.on("blocked",e=>{!e.newVersion||e.newVersion<e.oldVersion?console.warn(`Dexie.delete('${this.name}') was blocked`):console.warn(`Upgrade '${this.name}' blocked by other connection holding version ${e.oldVersion/10}`)}),this._maxKey=rd(t.IDBKeyRange),this._createTransaction=(e,t,r,n)=>new this.Transaction(e,t,r,this._options.chromeTransactionDurability,n),this._fireOnBlocked=e=>{this.on("blocked").fire(e),tM.filter(e=>e.name===this.name&&e!==this&&!e._state.vcFired).map(t=>t.on("versionchange").fire(e))},this.use(rN),this.use(rM),this.use(rU),this.use(r_),this.vip=Object.create(this,{_vip:{value:!0}}),a.forEach(e=>e(this))}version(e){if(isNaN(e)||e<.1)throw new eE.Type("Given version is not a positive number");if(e=Math.round(10*e)/10,this.idbdb||this._state.isBeingOpened)throw new eE.Schema("Cannot add version when database is open");this.verno=Math.max(this.verno,e);let t=this._versions;var r=t.filter(t=>t._cfg.version===e)[0];return r||(r=new this.Version(e),t.push(r),t.sort(rb),r.stores({}),this._state.autoSchema=!1,r)}_whenReady(e){return this.idbdb&&(this._state.openComplete||e1.letThrough||this._vip)?e():new e5((e,t)=>{if(this._state.openComplete)return t(new eE.DatabaseClosed(this._state.dbOpenError));if(!this._state.isBeingOpened){if(!this._options.autoOpen)return void t(new eE.DatabaseClosed);this.open().catch(eD)}this._state.dbReadyPromise.then(e,t)}).then(e)}use({stack:e,create:t,level:r,name:n}){n&&this.unuse({stack:e,name:n});let a=this._middlewares[e]||(this._middlewares[e]=[]);return a.push({stack:e,create:t,level:null==r?10:r,name:n}),a.sort((e,t)=>e.level-t.level),this}unuse({stack:e,name:t,create:r}){return e&&this._middlewares[e]&&(this._middlewares[e]=this._middlewares[e].filter(e=>r?e.create!==r:!!t&&e.name!==t)),this}open(){return function(e){var t;let r=e._state,{indexedDB:n}=e._deps;if(r.isBeingOpened||e.idbdb)return r.dbReadyPromise.then(()=>r.dbOpenError?tA(r.dbOpenError):e);ep&&(r.openCanceller._stackHolder=ey()),r.isBeingOpened=!0,r.dbOpenError=null,r.openComplete=!1;let a=r.openCanceller;function i(){if(r.openCanceller!==a)throw new eE.DatabaseClosed("db.open() was cancelled")}let o=r.dbReadyResolve,s=null,l=!1,u=()=>new e5((t,a)=>{if(i(),!n)throw new eE.MissingAPI;let o=e.name,u=r.autoSchema?n.open(o):n.open(o,Math.round(10*e.verno));if(!u)throw new eE.MissingAPI;u.onerror=rr(a),u.onblocked=tl(e._fireOnBlocked),u.onupgradeneeded=tl(t=>{if(s=u.transaction,r.autoSchema&&!e._options.allowEmptyDB){u.onerror=rn,s.abort(),u.result.close();let e=n.deleteDatabase(o);e.onsuccess=e.onerror=tl(()=>{a(new eE.NoSuchDatabase(`Database ${o} doesnt exist`))})}else{let r,n,o,f;s.onerror=rr(a);var i,c,d=t.oldVersion>0x4000000000000000?0:t.oldVersion;l=d<1,e._novip.idbdb=u.result,i=d/10,c=s,r=e._dbSchema,(n=e._createTransaction("readwrite",e._storeNames,r)).create(c),n._completion.catch(a),o=n._reject.bind(n),f=e1.transless||e1,tm(()=>{e1.trans=n,e1.transless=f,0===i?(N(r).forEach(e=>{rw(c,e,r[e].primKey,r[e].indexes)}),ry(e,c),e5.follow(()=>e.on.populate.fire(n)).catch(o)):(function({_novip:e},t,r,n){let a=[],i=e._versions,o=e._dbSchema=rj(e,e.idbdb,n),s=!1;return i.filter(e=>e._cfg.version>=t).forEach(i=>{a.push(()=>{let a=o,l=i._cfg.dbschema;rO(e,a,n),rO(e,l,n),o=e._dbSchema=l;let u=rx(a,l);u.add.forEach(e=>{rw(n,e[0],e[1].primKey,e[1].indexes)}),u.change.forEach(e=>{if(e.recreate)throw new eE.Upgrade("Not yet support for changing primary key");{let t=n.objectStore(e.name);e.add.forEach(e=>rS(t,e)),e.change.forEach(e=>{t.deleteIndex(e.name),rS(t,e)}),e.del.forEach(e=>t.deleteIndex(e))}});let c=i._cfg.contentUpgrade;if(c&&i._cfg.version>t){let t;ry(e,n),r._memoizedTables={},s=!0;let i=J(l);u.del.forEach(e=>{i[e]=a[e]}),rg(e,[e.Transaction.prototype]),rv(e,[e.Transaction.prototype],N(i),i),r.schema=i;let o=ef(c);o&&ty();let d=e5.follow(()=>{if((t=c(r))&&o){var e=tv.bind(null,null);t.then(e,e)}});return t&&"function"==typeof t.then?e5.resolve(t):d.then(()=>t)}}),a.push(t=>{var n;s&&tI||(n=i._cfg.dbschema,[].slice.call(t.db.objectStoreNames).forEach(e=>null==n[e]&&t.db.deleteObjectStore(e))),rg(e,[e.Transaction.prototype]),rv(e,[e.Transaction.prototype],e._storeNames,e._dbSchema),r.schema=e._dbSchema})}),(function e(){return a.length?e5.resolve(a.shift()(r.idbtrans)).then(e):e5.resolve()})().then(()=>{var e;N(e=o).forEach(t=>{n.db.objectStoreNames.contains(t)||rw(n,t,e[t].primKey,e[t].indexes)})})})(e,i,n,c).catch(o)})}},a),u.onsuccess=tl(()=>{s=null;let n=e._novip.idbdb=u.result,a=G(n.objectStoreNames);if(a.length>0)try{let t,i=n.transaction(1===a.length?a[0]:a,"readonly");r.autoSchema?function({_novip:e},t,r){e.verno=t.version/10;let n=e._dbSchema=rj(0,t,r);e._storeNames=G(t.objectStoreNames,0),rv(e,[e._allTables],N(n),n)}(e,n,i):(rO(e,e._dbSchema,i),((t=rx(rj(0,e.idbdb,i),e._dbSchema)).add.length||t.change.some(e=>e.add.length||e.change.length))&&console.warn("Dexie SchemaDiff: Schema was extended without increasing the number passed to db.version(). Some queries may fail.")),ry(e,i)}catch(e){}tM.push(e),n.onversionchange=tl(t=>{r.vcFired=!0,e.on("versionchange").fire(t)}),n.onclose=tl(t=>{e.on("close").fire(t)}),l&&function({indexedDB:e,IDBKeyRange:t},r){rP(e)||r===tL||rE(e,t).put({name:r}).catch(eD)}(e._deps,o),t()},a)}).catch(e=>e&&"UnknownError"===e.name&&r.PR1398_maxLoop>0?(r.PR1398_maxLoop--,console.warn("Dexie: Workaround for Chrome UnknownError on open()"),u()):e5.reject(e));return e5.race([a,("u"<typeof navigator?e5.resolve():!navigator.userAgentData&&/Safari\//.test(navigator.userAgent)&&!/Chrom(e|ium)\//.test(navigator.userAgent)&&indexedDB.databases?new Promise(function(e){var r=function(){return indexedDB.databases().finally(e)};t=setInterval(r,100),r()}).finally(function(){return clearInterval(t)}):Promise.resolve()).then(u)]).then(()=>(i(),r.onReadyBeingFired=[],e5.resolve(rA(()=>e.on.ready.fire(e.vip))).then(function t(){if(r.onReadyBeingFired.length>0){let n=r.onReadyBeingFired.reduce(eL,eD);return r.onReadyBeingFired=[],e5.resolve(rA(()=>n(e.vip))).then(t)}}))).finally(()=>{r.onReadyBeingFired=null,r.isBeingOpened=!1}).then(()=>e).catch(t=>{r.dbOpenError=t;try{s&&s.abort()}catch(e){}return a===r.openCanceller&&e._close(),tA(t)}).finally(()=>{r.openComplete=!0,o()})}(this)}_close(){let e=this._state,t=tM.indexOf(this);if(t>=0&&tM.splice(t,1),this.idbdb){try{this.idbdb.close()}catch(e){}this._novip.idbdb=null}e.dbReadyPromise=new e5(t=>{e.dbReadyResolve=t}),e.openCanceller=new e5((t,r)=>{e.cancelOpen=r})}close(){this._close();let e=this._state;this._options.autoOpen=!1,e.dbOpenError=new eE.DatabaseClosed,e.isBeingOpened&&e.cancelOpen(e.dbOpenError)}delete(){let e=arguments.length>0,t=this._state;return new e5((r,n)=>{let a=()=>{this.close();var e=this._deps.indexedDB.deleteDatabase(this.name);e.onsuccess=tl(()=>{!function({indexedDB:e,IDBKeyRange:t},r){rP(e)||r===tL||rE(e,t).delete(r).catch(eD)}(this._deps,this.name),r()}),e.onerror=rr(n),e.onblocked=this._fireOnBlocked};if(e)throw new eE.InvalidArgument("Arguments not allowed in db.delete()");t.isBeingOpened?t.dbReadyPromise.then(a):a()})}backendDB(){return this.idbdb}isOpen(){return null!==this.idbdb}hasBeenClosed(){let e=this._state.dbOpenError;return e&&"DatabaseClosed"===e.name}hasFailed(){return null!==this._state.dbOpenError}dynamicallyOpened(){return this._state.autoSchema}get tables(){return N(this._allTables).map(e=>this._allTables[e])}transaction(){let e=rC.apply(this,arguments);return this._transaction.apply(this,e)}_transaction(e,t,r){let n,a,i=e1.trans;i&&i.db===this&&-1===e.indexOf("!")||(i=null);let o=-1!==e.indexOf("?");e=e.replace("!","").replace("?","");try{if(a=t.map(e=>{var t=e instanceof this.Table?e.name:e;if("string"!=typeof t)throw TypeError("Invalid table argument to Dexie.transaction(). Only Table or String are allowed");return t}),"r"==e||e===tF)n=tF;else{if("rw"!=e&&e!=tB)throw new eE.InvalidArgument("Invalid transaction mode: "+e);n=tB}if(i){if(i.mode===tF&&n===tB){if(!o)throw new eE.SubTransaction("Cannot enter a sub-transaction with READWRITE mode when parent transaction is READONLY");i=null}i&&a.forEach(e=>{if(i&&-1===i.storeNames.indexOf(e)){if(!o)throw new eE.SubTransaction("Table "+e+" not included in parent transaction.");i=null}}),o&&i&&!i.active&&(i=null)}}catch(e){return i?i._promise(null,(t,r)=>{r(e)}):tA(e)}let s=(function e(t,r,n,a,i){return e5.resolve().then(()=>{let o,s=e1.transless||e1,l=t._createTransaction(r,n,t._dbSchema,a);if(a)l.idbtrans=a.idbtrans;else try{l.create(),t._state.PR1398_maxLoop=3}catch(a){return a.name===ek.InvalidState&&t.isOpen()&&--t._state.PR1398_maxLoop>0?(console.warn("Dexie: Need to reopen db"),t._close(),t.open().then(()=>e(t,r,n,null,i))):tA(a)}let u=ef(i);u&&ty();let c=e5.follow(()=>{if(o=i.call(l,l))if(u){var e=tv.bind(null,null);o.then(e,e)}else"function"==typeof o.next&&"function"==typeof o.throw&&(o=rD(o))},{trans:l,transless:s});return(o&&"function"==typeof o.then?e5.resolve(o).then(e=>l.active?e:tA(new eE.PrematureCommit("Transaction committed too early. See http://bit.ly/2kdckMn"))):c.then(()=>o)).then(e=>(a&&l._resolve(),l._completion.then(()=>e))).catch(e=>(l._reject(e),tA(e)))})}).bind(null,this,n,a,i,r);return i?i._promise(n,s,"lock"):e1.trans?tj(e1.transless,()=>this._whenReady(s)):this._whenReady(s)}table(e){if(!F(this._allTables,e))throw new eE.InvalidTable(`Table ${e} does not exist`);return this._allTables[e]}}let rG="u">typeof Symbol&&"observable"in Symbol?Symbol.observable:"@@observable";class rK{constructor(e){this._subscribe=e}subscribe(e,t,r){return this._subscribe(e&&"function"!=typeof e?e:{next:e,error:t,complete:r})}[rG](){return this}}function rq(e,t){return N(t).forEach(r=>{rV(e[r]||(e[r]=new rF),t[r])}),e}try{n={indexedDB:T.indexedDB||T.mozIndexedDB||T.webkitIndexedDB||T.msIndexedDB,IDBKeyRange:T.IDBKeyRange||T.webkitIDBKeyRange}}catch(e){n={indexedDB:null,IDBKeyRange:null}}function rY(e){let t=rX;try{rX=!0,ro.storagemutated.fire(e)}finally{rX=t}}B(rH,{...eA,delete:e=>new rH(e,{addons:[]}).delete(),exists:e=>new rH(e,{addons:[]}).open().then(e=>(e.close(),!0)).catch("NoSuchDatabaseError",()=>!1),getDatabaseNames(e){try{return(function({indexedDB:e,IDBKeyRange:t}){return rP(e)?Promise.resolve(e.databases()).then(e=>e.map(e=>e.name).filter(e=>e!==tL)):rE(e,t).toCollection().primaryKeys()})(rH.dependencies).then(e)}catch(e){return tA(new eE.MissingAPI)}},defineClass:()=>function(e){M(this,e)},ignoreTransaction:e=>e1.trans?tj(e1.transless,e):e(),vip:rA,async:function(e){return function(){try{var t=rD(e.apply(this,arguments));return t&&"function"==typeof t.then?t:e5.resolve(t)}catch(e){return tA(e)}}},spawn:function(e,t,r){try{var n=rD(e.apply(r,t||[]));return n&&"function"==typeof n.then?n:e5.resolve(n)}catch(e){return tA(e)}},currentTransaction:{get:()=>e1.trans||null},waitFor:function(e,t){let r=e5.resolve("function"==typeof e?rH.ignoreTransaction(e):e).timeout(t||6e4);return e1.trans?e1.trans.waitFor(r):r},Promise:e5,debug:{get:()=>ep,set:e=>{ep=e,eh="dexie"===e?()=>!0:t_}},derive:W,extend:M,props:B,override:K,Events:tU,on:ro,liveQuery:function(e){let t,r=!1,n=new rK(n=>{let a=ef(e),i=!1,o={},s={},l={get closed(){return i},unsubscribe:()=>{i=!0,ro.storagemutated.unsubscribe(f)}};n.start&&n.start(l);let u=!1,c=!1;function d(){return N(s).some(e=>o[e]&&function(e,t){let r=rz(t),n=r.next();if(n.done)return!1;let a=n.value,i=rz(e),o=i.next(a.from),s=o.value;for(;!n.done&&!o.done;){if(0>=tJ(s.from,a.to)&&tJ(s.to,a.from)>=0)return!0;0>tJ(a.from,s.from)?a=(n=r.next(s.from)).value:s=(o=i.next(a.from)).value}return!1}(o[e],s[e]))}let f=e=>{rq(o,e),d()&&p()},p=()=>{let h,m;if(u||i)return;o={};let y={},v=(a&&ty(),h=()=>tm(e,{subscr:y,trans:null}),m=e1.trans?tj(e1.transless,h):h(),a&&m.then(tv,tv),m);c||(ro(ra,f),c=!0),u=!0,Promise.resolve(v).then(e=>{r=!0,t=e,u=!1,i||(d()?p():(o={},s=y,n.next&&n.next(e)))},e=>{u=!1,r=!1,n.error&&n.error(e),l.unsubscribe()})};return p(),l});return n.hasValue=()=>r,n.getValue=()=>t,n},extendObservabilitySet:rq,getByKeyPath:Z,setByKeyPath:Q,delByKeyPath:function(e,t){"string"==typeof t?Q(e,t,void 0):"length"in t&&[].map.call(t,function(t){Q(e,t,void 0)})},shallowClone:J,deepClone:ei,getObjectDiff:rR,cmp:tJ,asap:Y,minKey:tT,addons:[],connections:tM,errnames:ek,dependencies:n,semVer:tD,version:tD.split(".").map(e=>parseInt(e)).reduce((e,t,r)=>e+t/Math.pow(10,2*r))}),rH.maxKey=rd(rH.dependencies.IDBKeyRange),"u">typeof dispatchEvent&&"u">typeof addEventListener&&(ro(ra,e=>{if(!rX){let t;tI?(t=document.createEvent("CustomEvent")).initCustomEvent(ri,!0,!0,e):t=new CustomEvent(ri,{detail:e}),rX=!0,dispatchEvent(t),rX=!1}}),addEventListener(ri,({detail:e})=>{rX||rY(e)}));let rX=!1;if("u">typeof BroadcastChannel){let e=new BroadcastChannel(ri);"function"==typeof e.unref&&e.unref(),ro(ra,t=>{rX||e.postMessage(t)}),e.onmessage=e=>{e.data&&rY(e.data)}}else if("u">typeof self&&"u">typeof navigator){ro(ra,e=>{try{rX||("u">typeof localStorage&&localStorage.setItem(ri,JSON.stringify({trig:Math.random(),changedParts:e})),"object"==typeof self.clients&&[...self.clients.matchAll({includeUncontrolled:!0})].forEach(t=>t.postMessage({type:ri,changedParts:e})))}catch(e){}}),"u">typeof addEventListener&&addEventListener("storage",e=>{if(e.key===ri){let t=JSON.parse(e.newValue);t&&rY(t.changedParts)}});let e=self.document&&navigator.serviceWorker;e&&e.addEventListener("message",function({data:e}){e&&e.type===ri&&rY(e.changedParts)})}e5.rejectionMapper=function(e,t){if(!e||e instanceof ew||e instanceof TypeError||e instanceof SyntaxError||!e.name||!eP[e.name])return e;var r=new eP[e.name](t||e.message,e);return"stack"in e&&z(r,"stack",{get:function(){return this.inner.stack}}),r},eh=t_;var rZ=r(70),rQ=r(1442);function rJ(e){return(rJ=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function r0(e,t){return(r0=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function r1(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(r1=function(){return!!e})()}function r2(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var r3=function(e){if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function t(){var e,r,n;if(!(this instanceof t))throw TypeError("Cannot call a class as a function");return n=["EsmOffline"],r=rJ(r=t),r2(e=function(e,t){var r;if(t&&("object"==((r=t)&&"u">typeof Symbol&&r.constructor===Symbol?"symbol":typeof r)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,r1()?Reflect.construct(r,n||[],rJ(this).constructor):r.apply(this,n)),"syncQueue",void 0),r2(e,"dynamicOfflineData",void 0),e.version(4).stores({syncQueue:"++id,userId,type,[userId+type]",dynamicOfflineData:"++id,type,identifier,*users,&[type+identifier]"}),e.syncQueue=e.table("syncQueue"),e.dynamicOfflineData=e.table("dynamicOfflineData"),e}return t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&r0(t,e),t}(rH);function r4(){return new r3}function r5(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function r6(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function r8(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){r6(i,n,a,o,s,"next",e)}function s(e){r6(i,n,a,o,s,"throw",e)}o(void 0)})}}function r9(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return r5(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return r5(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r7(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var ne=new r3,nt={},nr=(0,rQ.createGlobalStore)("offline-synchronization",{});function nn(){return nr}function na(){return r8(function(){var e,t,r,n,a,i,o,s,l,u,c,d,f;return r7(this,function(p){switch(p.label){case 0:if(nr.getState().synchronization)return[2];return[4,ne.syncQueue.count()];case 1:e=p.sent(),t={},n=(r=Object.entries(nt)).length,a={},i=new AbortController,o=function(){var e,t,r=nr.getState().synchronization;nr.setState({synchronization:(e=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},r),t=t={pendingCount:r.pendingCount-1},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e)})},p.label=2;case 2:p.trys.push([2,,10,11]),nr.setState({synchronization:{totalCount:e,pendingCount:e,abortController:i}}),s=0,p.label=3;case 3:if(!(s<n&&r.length>0))return[3,8];l=r.length,p.label=4;case 4:if(!l--)return[3,7];if(c=(u=r9(r[l],2))[0],!(f=(d=u[1]).dependsOn.map(function(e){return t[e]})).every(Boolean))return[3,6];return a[c]={},[4,Promise.all(f)];case 5:p.sent(),t[c]=function(e,t,r,n){return r8(function(e,t,r,n){var a,i,o,s,l,u,c,d,f,p,h,m,y,v,g,b,x;return r7(this,function(w){switch(w.label){case 0:return a=e.type,i=e.dependsOn,o=e.process,s=[],l=[],[4,ni()];case 1:return u=w.sent(),[4,ne.syncQueue.where({type:a,userId:u}).each(function(e,t){s.push([t.primaryKey,e.content,e.descriptor]),l.push(e.content)})];case 2:w.sent(),c=0,w.label=3;case 3:if(!(c<s.length))return[3,11];f=(d=r9(s[c],3))[0],p=d[1],m=(h=d[2]).id,v=void 0===(y=h.dependencies)?[]:y,w.label=4;case 4:return w.trys.push([4,7,9,10]),[4,o(p,{abort:r,index:c,items:l,userId:u,dependencies:v.map(function(e){var r=e.id,n=e.type;return i.includes(n)?t[n][r]:void 0})})];case 5:return g=w.sent(),void 0!==m&&(t[a][m]=g),[4,ne.syncQueue.delete(f)];case 6:case 8:return w.sent(),[3,10];case 7:var S,j;return S=b=w.sent(),x=(null!=(j=Error)&&"u">typeof Symbol&&j[Symbol.hasInstance]?!!j[Symbol.hasInstance](S):S instanceof j)?b:{name:"UnknownError",message:String(b)},[4,ne.syncQueue.update(f,{lastError:{name:x.name,message:x.message}})];case 9:return n(),[7];case 10:return c++,[3,3];case 11:return[2]}})}).apply(this,arguments)}(d,a,i,o),r.splice(l,1),p.label=6;case 6:return[3,4];case 7:return s++,[3,3];case 8:return[4,Promise.allSettled(Object.values(t))];case 9:return p.sent(),[3,11];case 10:return nr.setState({synchronization:void 0}),[7];case 11:return[2]}})})()}function ni(){return r8(function(){var e;return r7(this,function(t){switch(t.label){case 0:return[4,(0,rZ.getLoggedInUser)()];case 1:return[2,(null==(e=t.sent())?void 0:e.uuid)||"*"]}})})()}function no(e,t,r,n){return r8(function(){var a;return r7(this,function(i){switch(i.label){case 0:if(void 0===(a=n&&n.id))return[3,2];return[4,ne.syncQueue.where({type:t,userId:e}).filter(function(e){return(null==e?void 0:e.descriptor.id)===a}).delete().catch(rH.errnames.DatabaseClosed)];case 1:i.sent(),i.label=2;case 2:return[4,ne.syncQueue.add({type:t,content:r,userId:e,descriptor:n||{},createdOn:new Date}).catch(rH.errnames.DatabaseClosed,function(){return -1})];case 3:return[2,i.sent()]}})})()}function ns(e,t,r){return r8(function(){return r7(this,function(n){switch(n.label){case 0:return[4,ni()];case 1:return[4,no(n.sent(),e,t,r)];case 2:return[2,n.sent()]}})})()}function nl(e,t){return r8(function(){return r7(this,function(r){switch(r.label){case 0:return[4,nu(e,t)];case 1:return[2,r.sent().map(function(e){return e.content})]}})})()}function nu(e,t){return r8(function(){var r;return r7(this,function(n){switch(n.label){case 0:return r=t?{type:t,userId:e}:{userId:e},[4,ne.syncQueue.where(r).toArray().catch(rH.errnames.DatabaseClosed,function(){return[]})];case 1:return[2,n.sent()]}})})()}function nc(e){return r8(function(){return r7(this,function(t){switch(t.label){case 0:return[4,ni()];case 1:return[4,nl(t.sent(),e)];case 2:return[2,t.sent()]}})})()}function nd(e){return r8(function(){return r7(this,function(t){switch(t.label){case 0:return[4,ni()];case 1:return[4,nu(t.sent(),e)];case 2:return[2,t.sent()]}})})()}function nf(e){return r8(function(){return r7(this,function(t){switch(t.label){case 0:return[4,ne.syncQueue.get(e).catch(rH.errnames.DatabaseClosed,function(){})];case 1:return[2,t.sent()]}})})()}function np(e){var t;return!!(null==(t=nt[e])?void 0:t.options.onBeginEditSyncItem)}function nh(e){return r8(function(){var t,r,n;return r7(this,function(a){switch(a.label){case 0:return[4,nf(e)];case 1:if(!(r=a.sent()))throw Error("No sync item with the ID ".concat(e," exists."));if(!(n=null==(t=nt[r.type])?void 0:t.options.onBeginEditSyncItem))throw Error("A sync item with the ID ".concat(e,' exists, but the associated handler (if one exists) doesn\'t support editing the item. You can avoid this error by either verifying that sync items of this type can be edited via the "canEditSynchronizationItemsOfType(type: string)" function or alternatively ensure that the synchronizaton handler for sync items of type "').concat(r.type,'" supports editing items.'));return n(r),[2]}})})()}function nm(e){return r8(function(){return r7(this,function(t){switch(t.label){case 0:return[4,ne.syncQueue.delete(e).catch(rH.errnames.DatabaseClosed)];case 1:return t.sent(),[2]}})})()}function ny(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};nt[e]={type:e,dependsOn:t,process:r,options:n}}var nv=r(1400),ng="OFFLINE+";function nb(){return ng+(0,nv.A)()}function nx(e){return e.startsWith(ng)}function nw(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function nS(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function nj(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){nS(i,n,a,o,s,"next",e)}function s(e){nS(i,n,a,o,s,"throw",e)}o(void 0)})}}function nO(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var nk={};function nE(){return Object.values(nk)}function nP(e){nk[e.id]&&console.warn('[setupDynamicOfflineDataHandler] Another second handler with the ID "'.concat(e.id,'" was registered. This handler will override the previous one. This could be unintended as the previous handler might run different flows than the newly registered one. If this is the case, ensure that you are setting up the handlers with different IDs.')),nk[e.id]=e}function nA(e){return nj(function(){return nO(this,function(t){switch(t.label){case 0:return[4,n_()];case 1:return[4,nD(t.sent(),e)];case 2:return[2,t.sent()]}})})()}function nD(e,t){return nj(function(){var r;return nO(this,function(n){switch(n.label){case 0:return r=t?{type:t,users:e}:{users:e},[4,new r3().dynamicOfflineData.where(r).toArray().catch(rH.errnames.DatabaseClosed,function(){return[]})];case 1:return[2,n.sent()]}})})()}function nC(e,t){return nj(function(){return nO(this,function(r){switch(r.label){case 0:return[4,n_()];case 1:return[4,nT(r.sent(),e,t)];case 2:return[2,r.sent()]}})})()}function nT(e,t,r){return nj(function(){var n,a;return nO(this,function(i){switch(i.label){case 0:return[4,(n=new r3).dynamicOfflineData.get({type:t,identifier:r}).catch(rH.errnames.DatabaseClosed,function(){})];case 1:if(a=i.sent())return[3,3];return[4,n.dynamicOfflineData.add({users:[e],type:t,identifier:r}).catch(rH.errnames.DatabaseClosed)];case 2:return i.sent(),[3,5];case 3:var o;if(a.users.includes(e))return[3,5];return[4,n.dynamicOfflineData.update(a.id,{users:((function(e){if(Array.isArray(e))return nw(e)})(o=a.users)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(o)||function(e){if(e){if("string"==typeof e)return nw(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return nw(e,void 0)}}(o)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e])}).catch(rH.errnames.DatabaseClosed)];case 4:i.sent(),i.label=5;case 5:return[2]}})})()}function nN(e,t){return nj(function(){return nO(this,function(r){switch(r.label){case 0:return[4,n_()];case 1:return[4,nR(r.sent(),e,t)];case 2:return[2,r.sent()]}})})()}function nR(e,t,r){return nj(function(){var n,a;return nO(this,function(i){switch(i.label){case 0:return[4,(n=new r3).dynamicOfflineData.get({type:t,identifier:r,users:e}).catch(rH.errnames.DatabaseClosed,function(){})];case 1:if(!(a=i.sent()))return[3,5];if(!(a.users.length>1))return[3,3];return[4,n.dynamicOfflineData.update(a.id,{users:a.users.filter(function(t){return t!==e})}).catch(rH.errnames.DatabaseClosed)];case 2:return i.sent(),[3,5];case 3:return[4,n.dynamicOfflineData.delete(a.id).catch(rH.errnames.DatabaseClosed)];case 4:i.sent(),i.label=5;case 5:return[2]}})})()}function nM(e,t){return nj(function(){return nO(this,function(r){switch(r.label){case 0:return[4,nA(e)];case 1:return[4,Promise.all(r.sent().map(function(e){return nj(function(){return nO(this,function(r){return[2,nI(e.type,e.identifier,t)]})})()}))];case 2:return r.sent(),[2]}})})()}function nI(e,t,r){return nj(function(){var n,a,i,o,s,l,u,c,d;return nO(this,function(f){switch(f.label){case 0:return[4,nC(e,t)];case 1:return f.sent(),n=new r3,[4,n_()];case 2:return a=f.sent(),[4,n.dynamicOfflineData.get({type:e,identifier:t}).catch(rH.errnames.DatabaseClosed,function(){})];case 3:if(i=f.sent(),o=nE().filter(function(t){return t.type===e}),!i)return[2];return[4,Promise.all(o.map(function(e){return nj(function(){var n,a,i;return nO(this,function(o){try{return e.sync(t,r),[2,{id:e.id,error:void 0}]}catch(t){return i=null!=(n=null==(a=t.message)?void 0:a.toString())?n:t.toString(),[2,{id:e.id,error:i}]}})})()}))];case 4:if(l=(s=f.sent()).filter(function(e){return!e.error}).map(function(e){return e.id}),u=s.filter(function(e){return e.error}).map(function(e){return e.id}),c=s.filter(function(e){return e.error}).map(function(e){return{handlerId:e.id,message:e.error}}),d={syncedOn:new Date,syncedBy:a,succeededHandlers:l,erroredHandlers:u,errors:c},!i.id)return[3,6];return[4,n.dynamicOfflineData.update(i.id,{syncState:d}).catch(rH.errnames.DatabaseClosed)];case 5:f.sent(),f.label=6;case 6:return[2]}})})()}function n_(){return nj(function(){var e;return nO(this,function(t){switch(t.label){case 0:return[4,(0,rZ.getLoggedInUser)()];case 1:if(!(e=t.sent().uuid))throw Error("Using the dynamic offline data API requires a logged in user.");return[2,e]}})})()}function nL(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}var nF=(0,rQ.createGlobalStore)("offline-entities",{offlineEntityDataSyncState:{},handlers:{}});function nB(){return nW(),nF}function nV(e,t){nW(),nP({type:"entity",displayName:t.displayName,id:e,isSynced:function(){return Promise.resolve(!0)},sync:function(e,r){return t.onOfflineEntityAdded({entityUuid:e,signal:null!=r?r:new AbortController().signal})}})}function nz(e){var t;return(t=function(){return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(t){switch(t.label){case 0:return nW(),[4,nI("entity",e)];case 1:return t.sent(),[2]}})},function(){var e=this,r=arguments;return new Promise(function(n,a){var i=t.apply(e,r);function o(e){nL(i,n,a,o,s,"next",e)}function s(e){nL(i,n,a,o,s,"throw",e)}o(void 0)})})()}function nW(){console.warn("The offline entity API has been deprecated and will be removed in a future release. To prevent future crashes, the functions remain available for the moment, but any invocations should be migrated ASAP.")}},7230(e,t,r){"use strict";r.d(t,{yw:()=>v,Y1:()=>f,FZ:()=>y,oB:()=>d.o});var n=r(9250),a=r(3645),i=r(5794),o=r(3766),s=r(1221),l=r(9120);function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var c=r(7267),d=r(8148);function f(e,t){var r=t.name;if(!r)return void console.error("An extension definition in ".concat(e,' is missing an name and thus cannot be\nregistered. To fix this, ensure that you define the "name" field inside the\nextension definition.'),t);t.slots&&t.slot&&console.warn("The extension ".concat(r," from ").concat(e," declares both a 'slots' property and\na 'slot' property. Only the 'slots' property will be honored."));var n=t.slots?t.slots:t.slot?[t.slot]:[];if(!t.component)return void console.error("The extension ".concat(r," from ").concat(e," is missing a 'component' entry and thus cannot be registered.\nTo fix this, ensure that you define a 'component' field inside the extension definition."),t);if(n.some(c.rq)){var a=(0,c.Sk)(t.meta);a.length>0&&console.warn("L'extension ".concat(r," de ").concat(e," est sur un slot de rail du shell mais ne s'affichera pas : ").concat(a.join(" ; "),"."))}(0,c.VK)({name:r,load:function(){return(0,d.o)(e,t.component)},meta:t.meta||{},order:t.order,moduleName:e,privileges:t.privileges,online:null==(l=t.online)||l,offline:null!=(u=t.offline)&&u,featureFlag:t.featureFlag,displayExpression:t.displayExpression});var i=!0,o=!1,s=void 0;try{for(var l,u,f,p=n[Symbol.iterator]();!(i=(f=p.next()).done);i=!0){var h=f.value;(0,c.K0)(h,r)}}catch(e){o=!0,s=e}finally{try{i||null==p.return||p.return()}finally{if(o)throw s}}}function p(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function h(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}var m=[];function y(e,t){if(e&&t&&(void 0===t?"undefined":h(t))==="object"){var r,n,y,v,g,b,x,w,S,j=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){try{return"5.0.0"}catch(e){return}}(),r=e.platforms,n=e.requiredCapabilities,a=e.frameworkRange;if(Array.isArray(r)&&r.length>0){var i=(0,o.t)();if(!r.includes(i))return{reason:"platform",target:i,platforms:function(e){if(Array.isArray(e))return u(e)}(r)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||function(e){if(e){if("string"==typeof e)return u(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return u(e,void 0)}}(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}}if("string"==typeof a&&a.length>0&&t&&!(0,l.r)(a,t))return{reason:"framework",required:a,current:t};if(Array.isArray(n)&&n.length>0){var c=n.filter(function(e){return!(0,s.p)(e)});if(c.length>0)return{reason:"capability",missing:c}}return null}(t);if(j)return void console.warn("[egen] L'application ".concat(e," n'est pas enregistr\xe9e dans cet environnement."),p({app:e},j));(0,a.registerModuleWithConfigSystem)(e);var O=null!=(r=t.extensions)?r:[],k=null!=(n=t.modals)?n:[],E=null!=(y=t.workspaces)?y:[],P=null!=(v=t.workspaceGroups)?v:[],A=null!=(g=t.featureFlags)?g:[],D=null!=(b=t.workspaceGroups2)?b:[],C=null!=(x=t.workspaceWindows2)?x:[],T=null!=(w=t.workspaces2)?w:[];null==(S=t.pages)||S.forEach(function(t){if(t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"component")&&(Object.hasOwn(t,"route")||Object.hasOwn(t,"routeRegex")||Object.hasOwn(t,"routes"))){var r,n;m.push((r=p({},t),n=n={appName:e},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))}else console.warn("A page for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),O.forEach(function(t){t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"name")&&Object.hasOwn(t,"component")?f(e,t):console.warn("An extension for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),k.forEach(function(t){if(t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"name")&&Object.hasOwn(t,"component")){var r;(r=t.name)?t.component?(0,c.Ju)({name:r,moduleName:e,load:function(){return(0,d.o)(e,t.component)}}):console.error("The modal ".concat(r," from ").concat(e," is missing a 'component' entry and thus cannot be registered.\nTo fix this, ensure that you define a 'component' field inside the modal definition."),t):console.error("A modal definition in ".concat(e,' is missing an name and thus cannot be\nregistered. To fix this, ensure that you define the "name" field inside the\nmodal definition.'),t)}else console.warn("A modal for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),E.forEach(function(t){t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"name")&&Object.hasOwn(t,"component")?function(e,t){var r=t.name;if(!r)return console.error("A workspace definition in ".concat(e,' is missing a name and thus cannot be registered.\nTo fix this, ensure that you define the "name" field inside the workspace definition.'),t);var n=t.title;if(!n)return console.error("A workspace definition in ".concat(e,' is missing a title and thus cannot be registered.\nTo fix this, ensure that you define the "title" field inside the workspace definition.'),t);if(!t.component)return console.error("The workspace ".concat(r," from ").concat(e," is missing a 'component' entry and thus cannot be registered.\nTo fix this, ensure that you define a 'component' field inside the workspace definition."),t);(0,c.pm)({name:r,title:n,component:t.component,moduleName:e,type:t.type,canHide:t.canHide,canMaximize:t.canMaximize,width:t.width,preferredWindowSize:t.preferredWindowSize,groups:t.groups,load:function(){return(0,d.o)(e,t.component)}});var a=!0,i=!1,o=void 0;try{for(var s,l=(t.groups||[])[Symbol.iterator]();!(a=(s=l.next()).done);a=!0){var u=s.value;(0,c.io)({name:u,members:[r]})}}catch(e){i=!0,o=e}finally{try{a||null==l.return||l.return()}finally{if(i)throw o}}}(e,t):console.warn("A workspace for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),P.forEach(function(t){if(t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"name")){var r,n;(n=t.name)?(0,c.io)({name:n,members:null!=(r=t.members)?r:[]}):console.error("A workspace group definition in ".concat(e,' is missing a name and thus cannot be registered.\nTo fix this, ensure that you define the "name" field inside the workspace definition.'),t)}else console.warn("A workspace group for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),(0,c.rD)(e,D),function(e,t){(0,c.Qb)(e,t);var r=!0,n=!1,a=void 0;try{for(var i,o=t[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s=i.value;if(s.icon){var l={name:s.name,component:s.icon,slot:s.group,order:s.order};f(e,l)}}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}}(e,C),(0,c.Uh)(e,T),A.forEach(function(t){if(t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"flagName"))t.flagName?t.label?t.description?(0,i.uA)(t.flagName,t.label,t.description):console.error("A feature flag definition in ".concat(e,' is missing a description and thus cannot be registered.\nTo fix this, ensure that you define the "description" field inside the feature flag definition.'),t):console.error("A feature flag definition in ".concat(e,' is missing a description and thus cannot be registered.\nTo fix this, ensure that you define the "label" field inside the feature flag definition.'),t):console.error("A feature flag definition in ".concat(e,' is missing a name and thus cannot be registered.\nTo fix this, ensure that you define the "name" field inside the feature flag definition.'),t);else console.warn("A feature flag for ".concat(e," could not be registered as it does not appear to have the required properties"),t)})}}function v(){m.sort(function(e,t){return e.appName.localeCompare(t.appName,"en")});var e=new Map,t=!0,r=!1,a=void 0;try{for(var o,s=m[Symbol.iterator]();!(t=(o=s.next()).done);t=!0){var l,u=o.value;e.has(u.appName)?e.set(u.appName,e.get(u.appName)+1):e.set(u.appName,0);var c=e.get(u.appName),f="".concat(u.appName,"-page-").concat(c),p=null!=(l=u.containerDomId)?l:"egen-apps-container",h=document.getElementById(p),y="single-spa-application:".concat(f);if(h){var v=document.createElement("div");v.id=y,null==h||h.appendChild(v)}else throw Error("".concat(u.appName," ").concat(u.component,' cannot be mounted to "').concat(p,'"; DOM element does not exist.'));!function(e,t){var r,a,o,s,l=void 0!==t.route?t.route:void 0!==t.routeRegex&&new RegExp(t.routeRegex);if(!1===l)return console.warn('A registered page definition is missing a route and thus cannot be registered.\nTo fix this, ensure that you define the "route" (or alternatively the "routeRegex") field inside the extension definition.',e);if(!t.component)return console.warn('A registered page definition is missing a component and thus cannot be registered.\nTo fix this, ensure that you define the "component" field inside the page definition.',e);var u=(r=function e(t){if(Array.isArray(t)){var r,a=t.map(e);return function(e){return a.some(function(t){return t(e)})}}return"string"==typeof t?(0,n.pathToActiveWhen)(window.getEgenSpaBase()+t):(null!=(r=RegExp)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](t):t instanceof r)?function(e){return t.test(e.pathname.replace(window.getEgenSpaBase(),""))}:function(){return t}}(l),a=t.online,o=t.offline,s=t.featureFlag,window.offlineEnabled?function(e){return!!(navigator.onLine&&(null==a||a)||!navigator.onLine&&null!=o&&o)&&(!s||!!(0,i.jj)(s))&&r(e)}:r);(0,n.registerApplication)(e,function(){return(0,d.o)(t.appName,t.component)},u)}(f,u)}}catch(e){r=!0,a=e}finally{try{t||null==s.return||s.return()}finally{if(r)throw a}}}},8148(e,t,r){"use strict";r.d(t,{o:()=>u});var n=r(99),a=r(3645);function i(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function o(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var o=e.apply(t,r);function s(e){i(o,n,a,s,l,"next",e)}function l(e){i(o,n,a,s,l,"throw",e)}s(void 0)})}}function s(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var l=new Map;function u(e,t){return o(function(){var r,i,u,d,f;return s(this,function(p){switch(p.label){case 0:return u=(i=(r=t.indexOf("#"))>=0)?t.substring(0,r):e,d=i?t.substring(r+1):t,[4,(0,n.rL)(u)];case 1:if((f=p.sent())&&Object.hasOwn(f,d)&&"function"==typeof f[d]){var h,m;return[2,(h=u,m=f,o(function(){var e,t;return s(this,function(r){switch(r.label){case 0:if(h in l)return[3,5];if(null==m)return[3,1];return t=m,[3,3];case 1:return[4,(0,n.rL)(h)];case 2:t=r.sent(),r.label=3;case 3:return e=t,[4,l[h]=new Promise(function(t,r){if(Object.hasOwn(e,"startupApp")){var n=e.startupApp;if("function"==typeof n)return Promise.resolve(n()).then(function(){(0,a.registerModuleLoad)(h),t(null)}).catch(r)}(0,a.registerModuleLoad)(h),t(null)})];case 4:return r.sent(),[3,7];case 5:return[4,l[h]];case 6:r.sent(),r.label=7;case 7:return[2]}})})()).then(function(){return f[d]()})]}return f?f&&Object.hasOwn(f,d)?console.warn("The export ".concat(t,", defined in ").concat(e,"'s routes.json, is not a function")):console.warn("".concat(u,' does not define a component called "').concat(d,'", referenced in ').concat(e,"'s routes.json. This cannot be loaded.")):console.warn("Unknown app ".concat(u," for ").concat(t," defined in ").concat(e,"'s routes.json")),[2,c]}})})()}var c={bootstrap:function(){return Promise.resolve()},mount:function(){return Promise.resolve()},unmount:function(){return Promise.resolve()}}},3903(e,t,r){"use strict";r.d(t,{g2:()=>ev,Rt:()=>es,XE:()=>ee,a3:()=>eu,LW:()=>en,a7:()=>et,L8:()=>q,Yq:()=>ea,L3:()=>X,fU:()=>eo,_U:()=>Z,d4:()=>el,p0:()=>em,kQ:()=>Y,qE:()=>ec,pf:()=>K});var n,a=r(9405),i=r(227);if("u">typeof navigator){let e=navigator;n=Array.isArray(e.languages)?e.languages[0]:e.language}else if("u">typeof process){let e=process.env;n=e.LC_ALL||e.LC_MESSAGES||e.LANG||e.LANGUAGE}var o=function(e){e=(e=e.replace(/_/g,"-")).replace(/[.:][\w-]*$/,"");try{return new Intl.Locale(e).baseName}catch{return"en-US"}}(n||"en-US"),s=class extends Date{invalid=null;isValid(){return!Number.isNaN(this.valueOf())}},l={};for(let e=0;e<100;e++)l[(e<=9?"0":"")+e]=e+(e>51?1900:2e3);var u={arab:1632,arabext:1776,bali:6992,beng:2534,deva:2406,fullwide:65296,gujr:2790,khmr:6112,knda:3302,laoo:3792,limb:6470,mlym:3430,mong:6160,mymr:4160,orya:2918,tamldec:3046,telu:3174,thai:3664,tibt:3872},c="[1234567890一二三四五六七八九〇\\d]",d={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,"0":0,"1":1,"2":2,"3":3,"4":4,"5":5,"6":6,"7":7,"8":8,"9":9,〇:0,一:1,二:2,三:3,四:4,五:5,六:6,七:7,八:8,九:9},f={},p={"Eastern Daylight Time":-240,"Eastern Standard Time":-300,"Central Daylight Time":-300,"Central Standard Time":-360,"Mountain Daylight Time":-360,"Mountain Standard Time":-420,"Pacific Daylight Time":-420,"Pacific Standard Time":-480,"Coordinated Universal Time":0,ACDT:630,ACST:570,ACT:480,ADT:-180,AEDT:660,AEST:600,AFT:270,AKDT:-480,AKST:-540,AMST:-180,AMT:-240,ART:-180,AST:180,AWDT:540,AWST:480,AZOST:-60,AZT:240,BDT:360,BIOT:360,BIT:-720,BOT:-240,BRST:-120,BRT:-180,BTT:360,CAT:120,CCT:390,CDT:-300,CEDT:120,CEST:120,CET:60,CHADT:825,CHAST:765,CHOT:480,ChST:600,CHUT:600,CIST:-480,CIT:480,CKT:-600,CLST:-180,CLT:-240,COST:-240,COT:-300,CST:-360,CT:480,CVT:-60,CXT:420,DAVT:420,DDUT:600,DFT:60,EASST:-300,EAST:-360,EAT:180,ECT:-300,EDT:-240,EEDT:180,EEST:180,EET:120,EGST:0,EGT:-60,EIT:540,EST:-300,FET:180,FJT:720,FKST:-180,FKT:-240,FNT:-120,GALT:-360,GAMT:-540,GET:240,GFT:-180,GILT:720,GIT:-540,GMT:0,GST:-120,GYT:-240,HADT:-540,HAEC:120,HAST:-600,HKT:480,HMT:300,HOVT:420,HST:-600,IBST:0,ICT:420,IDT:180,IOT:180,IRDT:270,IRKT:480,IRST:210,IST:120,JST:540,KGT:360,KOST:660,KRAT:420,KST:540,LHST:630,LINT:840,MAGT:720,MART:-510,MAWT:300,MDT:-360,MET:60,MEST:120,MHT:720,MIST:660,MIT:-510,MMT:390,MSK:180,MST:-420,MUT:240,MVT:300,MYT:480,NCT:660,NDT:-90,NFT:660,NPT:345,NST:-150,NT:-150,NUT:-660,NZDT:780,NZST:720,OMST:360,ORAT:300,PDT:-420,PET:-300,PETT:720,PGT:600,PHOT:780,PKT:300,PMDT:-120,PMST:-180,PONT:660,PST:-480,PYST:-180,PYT:-240,RET:240,ROTT:-180,SAKT:660,SAMT:240,SAST:120,SBT:660,SCT:240,SGT:480,SLST:330,SRET:660,SRT:-180,SST:480,SYOT:180,TAHT:-600,THA:420,TFT:300,TJT:300,TKT:780,TLT:540,TMT:300,TOT:780,TVT:720,UCT:0,ULAT:480,USZ1:120,UTC:0,UYST:-120,UYT:-180,UZT:300,VET:-240,VLAT:600,VOLT:240,VOST:360,VUT:660,WAKT:720,WAST:120,WAT:60,WEDT:60,WEST:60,WET:0,WIT:420,WST:480,YAKT:540,YEKT:300},h={zone:p,year:l,meridiem:{am:0,pm:12,"a.m.":0,"p.m.":12},month:{january:1,jan:1,february:2,feb:2,march:3,mar:3,april:4,apr:4,may:5,june:6,jun:6,july:7,jul:7,august:8,aug:8,september:9,sep:9,october:10,oct:10,november:11,nov:11,december:12,dec:12},dayname:{sunday:0,sun:0,monday:1,mon:1,tuesday:2,tue:2,wednesday:3,wed:3,thursday:4,thu:4,friday:5,fri:5,saturday:6,sat:6},digit:{}},m={MONTHNAME:"january|february|march|april|may|june|july|august|september|october|november|december|jan\\.?|feb\\.?|mar\\.?|apr\\.?|may\\.?|jun\\.?|jul\\.?|aug\\.?|sep\\.?|oct\\.?|nov\\.?|dec\\.?",DAYNAME:"sunday|monday|tuesday|wednesday|thursday|friday|saturday|sun\\.?|mon\\.?|tue\\.?|wed\\.?|thu\\.?|fri\\.?|sat\\.?",ZONE:`\\(?(?:${Object.keys(p).join("|")})\\)?`,MERIDIEM:"am|pm|a.m.|p.m.",ORDINAL:"st|nd|rd|th|\\.",YEAR:"\\d{4}|\\d{2}",YEAR2:"\\d{2}",YEAR4:"\\d{4}",YEAR6:"-\\d{6}|\\+?\\d{5,6}",MONTH:"1[0-2]|0?[1-9]",MONTH2:"1[0-2]|0[1-9]",DAY:"3[01]|[12]\\d|0?[1-9]",DAY2:"3[01]|[12]\\d|0[1-9]",OFFSET:"(?:GMT)?[\xb1−+-](?:[01]\\d[0-5]\\d|[01]\\d:[0-5]\\d|[01]?\\d)",H24:"[01]\\d|2[0-3]",H12:"0?[1-9]|1[012]",MIN:"[0-5]\\d",SEC:"[0-5]\\d|60",MS:"\\d{9}|\\d{6}|\\d{1,3}",GAP:"[\\s/.,-]{1,}"},y={...m,YEAR:"*{4}|*{2}",YEAR4:"*{4}",YEAR6:"-*{6}|\\+?*{5,6}",MONTH:"*{1,2}",MONTH2:"*{2}",DAY:"*{1,2}",DAY2:"*{2}",OFFSET:"(?:GMT)?[\xb1−+-](?:*{4}|*{2}:*{2}|*{1,2})",H24:"*{2}",H12:"*{1,2}",MIN:"*{2}",SEC:"*{2}",MS:"*{9}|*{6}|*{3}"},v={},g=class e{locale;lookups;vars;numberingSystem;baseName;dateOptions;static factory(t=o){let r=t.toLowerCase(),n=v[r];if(n)return n;let a=new e(t);return v[r]=a,a}constructor(e=o){this.locale=e,this.lookups={...h},this.vars={...m};const t=new Intl.NumberFormat(this.locale);this.numberingSystem=t.resolvedOptions().numberingSystem,this.dateOptions=new Intl.DateTimeFormat(this.locale).resolvedOptions(),this.baseName=new Intl.Locale(this.locale).baseName,this.build()}toInt(e){return"number"==typeof e?e:"string"==typeof e?this.stringToInt(e):void 0}stringToInt(e){if("latn"===this.numberingSystem&&!this.baseName.startsWith("zh")){let t=parseInt(e,10);if(!Number.isNaN(t))return t}let t="";for(let r=0;r<e.length;r++)t+=String(this.lookups.digit[e[r]]);return parseInt(t,10)}millisecondToInt(e){if("number"==typeof e)return e;if("string"!=typeof e)return;let t=e.slice(0,3);return 1===t.length?100*this.stringToInt(t):2===t.length?10*this.stringToInt(t):this.stringToInt(t)}monthNameToInt(e){if("string"!=typeof e)return;let t=e.toLocaleLowerCase(this.locale).replace(/\.$/,"");return this.lookups.month[t]||12}h12ToInt(e,t){if("string"!=typeof e)return;let r=this.lookups.meridiem[t?.toLowerCase()]||0,n=this.stringToInt(e);return n<12&&12===r&&(n+=12),12===n&&0===r&&(n=0),n}zoneToOffset(e){if("string"==typeof e)return e=e.replace(/[^a-z\s]/gi,""),this.lookups.zone[e]}offsetToMinutes(e){if("string"!=typeof e)return;let t=e.match(/^(?:GMT)?([±−+-])(..?):?(..)?$/);if(t){let[,e,r,n]=t;return("-"===e||"−"===e?-1:1)*(60*this.stringToInt(r)+(n?this.stringToInt(n):0))}return 0}build(){"latn"===this.dateOptions.numberingSystem?this.lookups.digit=d:this.buildNumbers(),!/^en/i.test(this.locale)&&(this.buildMonthNames(),this.buildDaynames(),/zh/i.test(this.locale)||this.buildMeridiems())}buildNumbers(){let{group:e,lookup:t}=function(e){let t=f[e];if(t)return t;if("fullwide"===e||"hanidec"===e)return{group:c,lookup:{...d}};let r=u[e];if(!r)return{group:"\\d",lookup:{...d}};let n=String.fromCharCode(r),a=String.fromCharCode(r+9),i={};for(let e=0;e<10;e++)i[String.fromCharCode(r+e)]=e;return f[e]={group:`[${n}-${a}]`,lookup:i},f[e]}(this.numberingSystem);for(let r in this.lookups.digit=t,y)Object.hasOwn(y,r)&&(this.vars[r]=y[r].replace(/\*/g,e))}buildMonthNames(){let e={},t={};if(/^fi/i.test(this.locale))"tammi|helmi|maalis|huhti|touko|kes\xe4|hein\xe4|elo|syys|loka|marras|joulu".split("|").forEach((r,n)=>{["","k","kuu","kuuta"].forEach((a,i)=>{e[r+a+(i<2?"\\.?":"")]=!0,t[r+a]=n+1})});else{let r=[],n=e=>"month"===e.type;for(let e=0;e<12;e++)r.push(new Date(2017,e,1));for(let a of["full","long","medium"]){let i=Intl.DateTimeFormat(this.locale,{dateStyle:a});for(let o=0;o<12;o++){let s=i.formatToParts(r[o]).find(n);if(!s)continue;let l=s.value.toLocaleLowerCase(this.locale);/^\d+$/.test(l)||(/^ko/i.test(this.locale)&&(l+="월"),"medium"===a?(l=l.replace(/\.$/,""),e[`${l}\\.?`]=!0):e[l]=!0,t[l]=o+1)}}let a=Intl.DateTimeFormat(this.locale,{month:"short"});for(let i=0;i<12;i++){let o=a.formatToParts(r[i]).find(n);if(!o)continue;let s=o.value.toLocaleLowerCase(this.locale);s=s.replace(/\.$/,""),e[`${s}\\.?`]=!0,t[s]=i+1}}this.vars.MONTHNAME=Object.keys(e).join("|"),this.lookups.month=t}buildDaynames(){let e=[],t=e=>"weekday"===e.type;for(let t=0;t<7;t++)e.push(new Date(2017,0,t+1));let r=[],n={};for(let a of["long","short"]){let i=Intl.DateTimeFormat(this.locale,{weekday:a});for(let o=0;o<7;o++){let s=i.formatToParts(e[o]).find(t);if(!s)continue;let l=s.value.toLocaleLowerCase(this.locale);"short"===a?(l=l.replace(/\.$/,""),r.push(`${l}\\.?`)):r.push(l),n[l]=o}}this.vars.DAYNAME=r.join("|"),this.lookups.dayname=n}buildMeridiems(){let e=[new Date(2017,0,1),new Date(2017,0,1,23,0,0)],t=e=>"dayPeriod"===e.type,r=[],n={},a=Intl.DateTimeFormat(this.locale,{timeStyle:"long"});for(let i=0;i<2;i++){let o=a.formatToParts(e[i]).find(t);if(!o)return;let s=o.value.toLocaleLowerCase(this.locale);r.push(s),n[s]=12*i}this.vars.MERIDIEM=r.join("|"),this.lookups.meridiem=n}compile(e){return RegExp(e.replace(/_([A-Z0-9]+)_/g,(e,t)=>{if(!this.vars[t])throw Error(`Template string contains invalid variable _${t}_`);return this.vars[t]}),"i")}},b=["ee-TG","en-AS","en-CA","en-FM","en-GH","en-GU","en-KE","en-KY","en-MH","en-MP","en-US","en-VI","en-WS","jp-JP","sm-AS","sm-SM"],x={y:"year",M:"month",d:"day",w:"week",h:"hour",m:"minute",s:"second",ms:"millisecond"},w=()=>new Date;function S(e){return function(t){let r={};for(let n=0,a=e.length;n<a;n++){let a=e[n];a&&(r[a]=t[n])}return r}}var j=class{doneChecker;fallback;patterns;formatter;constructor({doneChecker:e,fallback:t,patterns:r,formatter:n}){this.doneChecker=e,this.fallback=t,this.patterns=r,this.formatter=n}attempt(e){if("string"!=typeof e)return this.fallback(e);let t=e.trim(),r={},n=!1;for(let e of this.patterns){let a=t.match(e.regex);if(!a)continue;n=!0;let i=e.handler(a);if(i){for(let[e,t]of Object.entries(i))e in r||void 0===t||(r[e]=t);let e=a.index??0;if(t=(t=t.slice(0,e)+t.slice(e+a[0].length+1)).trim(),this.doneChecker(r,t))break}}return n?this.formatter(r):this.fallback(e)}},O=["year","month","day","hour","minute","second","millisecond","offset"],k={};function E(e,t){return""===t||/^\s+$/.test(t)||"year"in e&&("month"in e||"monthname"in e)&&"day"in e&&"hour"in e&&"minute"in e&&"second"in e&&"millisecond"in e&&("zone"in e||"offset"in e)}var P=[[/([^\d.]+)(\d{1,2})\.(\d{2})\.(\d{2})(\D|$)/,"$1$2:$3:$4$5"],[/([^\d.]+)(\d{1,2})\.(\d{2})(\D|$)/,"$1$2:$3$4"]],A={ar:[[/ /g," "]],bn:[[/,/g,""]],zh:[[/早上\s*([\d:]+)/,"$1am"],[/凌晨\s*([\d:]+)/,"$1am"],[/上午\s*([\d:]+)/,"$1am"],[/下午\s*([\d:]+)/,"$1pm"],[/晚上\s*([\d:]+)/,"$1pm"]],he:[[/ב/gi,""]],de:[[/ um /g," "]],pt:[[/\sde /gi," "]],es:[[/\sde /gi," "]],da:[[/\sden /gi," "],...P],ru:[[/ г\./g,""]],th:[[/\s*นาฬิกา\s*/i,":"],[/\s*นาที\s*/i,":"],[/\s*วินาที\s*/i," "]],ko:[[/\s*시\s*/,":"],[/\s*분\s*/,":"],[/\s*초\s*/,""],[/(오전|오후)\s*([\d:]+)/,"$2$1"],[/(\d{4})\. (\d{1,2})\. (\d{1,2})\./,"$1-$2-$3"]],fi:P,id:P,fr:[[/(\d{2}) h /,"$1:"],[/(\d{2}) min /,"$1:"],[/(\d{2}) s /,"$1"]]};function D(e,t=o){let r=function(e){var t,r;let n,a,i=k[e];if(i)return i;let o=g.factory(e),s=new j({doneChecker:E,fallback:(t=e,function(e){let r=String(e).slice(0,50);return""===r&&(r="(empty string)"),{invalid:`Unable to parse "${r}" with locale "${t}"`}}),patterns:(n=[{name:"timestampWithOffset",regex:o.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? ?(_OFFSET_|Z)?$"),handler:S(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"timestampWithZone",regex:o.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))?\\s*(_ZONE_)$"),handler:S(["","year","month","day","hour","minute","second","millisecond","zone"])},{name:"timestampWithOffsetAndZone",regex:o.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? (_OFFSET_|Z)\\s*(_ZONE_)$"),handler:S(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"chinese",regex:o.compile(`^(${c}{2,4})\\s*\u5E74\\s*(${c}{1,2})\\s*\u6708\\s*(${c}{1,2})\\s*\u65E5$`),handler:S(["","year","month","day"])},{name:"korean",regex:o.compile("^(_YEAR_)년\\s*(_MONTH_)월\\s*(_DAY_)일$"),handler:S(["","year","month","day"])},{name:"twitter",regex:/^(?:sun|mon|tue|wed|thu|fri|sat) (jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec) (\d{2}) (\d{2}):(\d{2}):(\d{2}) ([+-]\d{4}) (\d{4})$/i,handler:S(["","monthname","day","hour","minute","second","offset","year"])},{name:"today",regex:/\b(now|today|tomorrow|yesterday)\b/i,handler:e=>{let t=w(),r=e[0].toLowerCase(),n={now:0,today:0,tomorrow:864e5,yesterday:-864e5}[r]??0;0!==n&&t.setTime(t.getTime()+n);let a={year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()};return"now"===r?{...a,hour:t.getHours(),minute:t.getMinutes(),second:t.getSeconds(),millisecond:t.getMilliseconds()}:a}},{name:"ago",regex:/^(\+|-|in|) ?([\d.]+) ?(years?|months?|weeks?|days?|hours?|minutes?|seconds?|milliseconds?|ms|s|m|h|w|d|M|y)( ago)?$/i,handler:([,e,t,r,n])=>{let a,i=parseFloat(t);"week"===(a=r.length<=2?x[r]:(a=r.replace(/s$/,"")).toLowerCase())&&(a="day",i*=7),("-"===e||n)&&(i*=-1);let o=w();return"millisecond"===a?o.setUTCMilliseconds(o.getUTCMilliseconds()+i):"second"===a?o.setUTCSeconds(o.getUTCSeconds()+i):"minute"===a?o.setUTCMinutes(o.getUTCMinutes()+i):"hour"===a?o.setUTCHours(o.getUTCHours()+i):"day"===a?o.setUTCDate(o.getUTCDate()+i):"month"===a?o.setUTCMonth(o.getUTCMonth()+i):"year"===a&&o.setUTCFullYear(o.getUTCFullYear()+i),{year:o.getUTCFullYear(),month:o.getUTCMonth()+1,day:o.getUTCDate(),hour:o.getUTCHours(),minute:o.getUTCMinutes(),second:o.getUTCSeconds(),millisecond:o.getUTCMilliseconds()}}},{name:"atSeconds",regex:/^@(\d+)$/,handler:e=>{let t=new Date(1e3*parseInt(e[1],10));return{year:t.getUTCFullYear(),month:t.getUTCMonth()+1,day:t.getUTCDate(),hour:t.getUTCHours(),minute:t.getUTCMinutes(),second:t.getUTCSeconds()}}},{name:"microsoftJson",regex:/^\/Date\((\d+)([+-]\d{4})?\)\/$/,handler:e=>{let t=new Date(parseInt(e[1],10));return{year:t.getUTCFullYear(),month:t.getUTCMonth()+1,day:t.getUTCDate(),hour:t.getUTCHours(),minute:t.getUTCMinutes(),second:t.getUTCSeconds(),millisecond:t.getUTCMilliseconds(),offset:e[2]}}},{name:"full24",regex:o.compile("(?:^|[\\sT])(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?(Z)?$"),handler:S(["","hour","minute","second","millisecond","zone"])},{name:"zone24",regex:o.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?[\\s\\[(]*(_ZONE_)?[\\s\\])]*$"),handler:S(["","hour","minute","second","millisecond","zone"])},{name:"hms12WithOffset",regex:o.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)\\s*(_OFFSET_)"),handler:S(["","hour","minute","second","meridiem","offset"])},{name:"hms12",regex:o.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)"),handler:S(["","hour","minute","second","meridiem"])},{name:"hms24",regex:o.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?"),handler:S(["","hour","minute","second","millisecond"])},{name:"hm12",regex:o.compile("(_H12_):(_MIN_)\\s*(_MERIDIEM_)"),handler:S(["","hour","minute","meridiem"])},{name:"hm24",regex:o.compile("(_H24_):(_MIN_)"),handler:S(["","hour","minute"])},{name:"h12",regex:o.compile("(_H12_)\\s*(_MERIDIEM_)"),handler:S(["","hour","meridiem"])},{name:"8digit",regex:/^((?:19|20)\d{2})(\d{2})(\d{2})$/,handler:S(["","year","month","day"])},{name:"yearMonthnameDay",regex:o.compile("(_YEAR4_)[\\s.-]+(_MONTHNAME_)[\\s,.-]+(_DAY_)(_ORDINAL_)?"),handler:S(["","year","monthname","day"])},{name:"dayMonthnameYear",regex:o.compile("(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)[\\s,.-]+(_YEAR_)"),handler:S(["","day","","monthname","year"])},{name:"monthnameDayYear",regex:o.compile("(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?[\\s,.-]+(_YEAR_)"),handler:S(["","monthname","day","","year"])},{name:"dayMonthname",regex:o.compile("\\b(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)\\b"),handler:S(["","day","","monthname"])},{name:"monthnameDay",regex:o.compile("\\b(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?\\b"),handler:S(["","monthname","day"])},{name:"hmsNoMeridiem",regex:o.compile("\\b(_H12_|_H24_):(_MIN_):(_SEC_)\\b"),handler:S(["","hour","minute","second"])},{name:"hmNoMeridiem",regex:o.compile("\\b(_H12_|_H24_):(_MIN_)\\b"),handler:S(["","hour","minute"])},{name:"ymd",regex:o.compile("(_YEAR4_)([./-])(_MONTH_)\\2+(_DAY_)"),handler:S(["","year","","month","day"])},{name:"mdy",regex:o.compile("(_MONTH_)([/-])(_DAY_)\\2(_YEAR_)"),handler:S(["","month","","day","year"])},{name:"dmy",regex:o.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)[./\\s-]+(_YEAR_)"),handler:S(["","day","month","year"])},{name:"yearLoose",regex:o.compile("_YEAR4_"),handler:S(["year"])},{name:"dayMonthnameLoose",regex:o.compile("(_DAY_)[\\s.]*(_MONTHNAME_)"),handler:S(["","day","monthname"])},{name:"monthnameDayLoose",regex:o.compile("(_MONTHNAME_)[\\s.]*(_DAY_)"),handler:S(["","monthname","day"])},{name:"monthname",regex:o.compile("_MONTHNAME_"),handler:S(["monthname"])},{name:"year4",regex:o.compile("_YEAR4_"),handler:S(["year"])},{name:"md",regex:o.compile("(_MONTH_)[/-](_DAY_)"),handler:S(["","month","day"])},{name:"dm",regex:o.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)"),handler:S(["","day","month"])},{name:"day",regex:o.compile("_DAY_"),handler:S(["day"])},{name:"year2",regex:o.compile("_YEAR2_"),handler:S(["year"])},{name:"onlyZone",regex:o.compile("_ZONE_"),handler:S(["zone"])},{name:"onlyOffset",regex:o.compile("_OFFSET_"),handler:S(["offset"])}],a=o.baseName.slice(0,5),b.includes(a)?n:n.filter(e=>!["mdy","md"].includes(e.name))),formatter:(r=o,function(e){let t={};for(let[n,a]of Object.entries(e))if("monthname"===n){if(a){let e=r.monthNameToInt(a);void 0!==e&&(t.month=e)}}else if("hour"===n&&e.meridiem){let n=r.h12ToInt(a,e.meridiem);void 0!==n&&(t.hour=n)}else if("zone"===n){if(a){let e=r.zoneToOffset(a);void 0!==e&&(t.offset=e)}}else if("offset"===n){let e=r.offsetToMinutes(a);void 0!==e&&(t.offset=e)}else if("millisecond"===n){let e=r.millisecondToInt(a);"number"==typeof e&&(t.millisecond=e)}else if(O.includes(n)){let e=r.toInt(a);"number"==typeof e&&(t[n]=e)}return void 0!==t.year&&t.year<100&&(t.year=l[String(e.year)]),t.year&&"buddhist"===r.dateOptions.calendar&&(t.year-=543),t})});return k[e]=s,s}(t),n=function(e,t){let r=A[t.slice(0,2).toLowerCase()];if(!r)return e;for(let[t,n]of r)e=e.replace(t,n);return e}(e,t);return r.attempt(n)}function C(e){e.month&&e.day&&void 0===e.year&&(e.year=new Date().getFullYear()),60===e.second&&(e.second=59);let t=new s(e.year??NaN,(e.month??NaN)-1,e.day,e.hour||0,e.minute||0,e.second||0,e.millisecond||0);return"number"==typeof e.offset?new s(t.valueOf()-60*e.offset*1e3):t}function T(e,t=o){let r=D(e,t),n=r.invalid?new s(NaN):C(r);return n.isValid()||(n.invalid=`Unable to parse date "${e}"`),n}function N(e,t=o){return e instanceof Date?new s(e.valueOf()):"number"==typeof e?new s(e):T(e,t)}Date.fromString=s.fromString=T,Date.fromAny=s.fromAny=N,"u">typeof window&&(window.anyDateParser={fromString:T,fromAny:N,fromObject:C,attempt:D});var R=r(5350),M=r.n(R),I=r(648),L=r(6871),F=r(2147);let B=function(e){return null==e};var V=r(313),z=r(4232);function W(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function $(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function U(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){$(e,t,r[t])})}return e}function H(e,t){var r=function(e,t){if(!t.has(e))throw TypeError("attempted to get private field on non-instance");return t.get(e)}(e,t);return r.get?r.get.call(e):r.value}M().extend(I),M().extend(F),M().extend(L);var G="YYYY-MM-DDTHH:mm:ss.SSSZZ";function K(e){return null!=e&&28===e.trim().length&&"T"===(e=e.trim())[10]&&":"===e[13]&&":"===e[16]&&"."===e[19]&&("+"===e[23]||"-"===e[23])&&M()(e,G).isValid()}function q(e){return M()(e).isToday()}function Y(e){return K(e)?M()(e,G).toDate():null}function X(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=M()(e);return t&&(r=r.utc()),r.format(G)}function Z(e){return M()(e).toDate()}var Q=new WeakMap,J=new(function(){var e;function t(){if(!(this instanceof t))throw TypeError("Cannot call a class as a function");var e=this,r=Q,n={writable:!0,value:new Map};if(r.has(e))throw TypeError("Cannot initialize the same private elements twice on an object");r.set(e,n)}return e=[{key:"register",value:function(e,t){H(this,Q).set(e,t)}},{key:"getCalendar",value:function(e){if(e){if(e.calendar)return e.calendar;if(e.region){var t="".concat(e.language,"-").concat(e.region);if(H(this,Q).has(t))return H(this,Q).get(t)}if(e.language&&H(this,Q).has(e.language))return H(this,Q).get(e.language);var r=new Intl.DateTimeFormat(e.toString()).resolvedOptions().calendar;return H(this,Q).set("".concat(e.language).concat(e.region?"-".concat(e.region):""),r),r}}}],function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,e),t}());function ee(e,t){J.register(e,t)}function et(e){var t,r=null!=e?e:(0,z.J)();return J.getCalendar((null!=(t=Intl.Locale)&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](r):r instanceof t)?r:new Intl.Locale(r))}var er={mode:"standard",time:"for today",day:!0,month:!0,year:!0,noToday:!1};function en(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=D(e,(0,z.J)());if(r.invalid)return console.warn("Could not parse invalid date '".concat(e,"'")),null;!B(r.day)&&B(r.month)&&(r=Object.assign({},(0,V.A)(r,"day"),{month:r.day})),r.month&&(r.month-=1),r.day&&(r=Object.assign({},(0,V.A)(r,"day"),{date:r.day}));var n=M()().set(r).toDate();return B(r.year)&&(t.year=!1),B(r.month)&&(t.month=!1),B(r.date)&&(t.day=!1),ea(n,t)}function ea(e,t){var r,n,a=null!=(r=null==t?void 0:t.locale)?r:(0,z.J)(),i=new Intl.Locale(a),o=U({},er,{noToday:"am"===i.language},t),s=o.calendar,l=o.mode,u=o.time,c=o.day,d=o.month,f=o.year,p=o.noToday,h=o.numberingSystem,m={calendar:null!=s?s:et(i),year:f?"numeric":void 0,month:d?"short":void 0,day:c?"2-digit":void 0,numberingSystem:h},y=M()(e).isToday();if(y&&!p)n=(n=new Intl.RelativeTimeFormat(a,{numeric:"auto"}).format(0,"day"))[0].toLocaleUpperCase(a)+n.slice(1);else{"en"===i.language&&(a="en-GB");var v=new Intl.DateTimeFormat(a,m).formatToParts(e);("en"===i.language||"am"===i.language)&&"standard"==l&&f&&c&&(v=v.map(ei("-"))),"wide"==l&&(v=v.map(ei(" — "))),"ethiopic"===m.calendar&&(v=v.filter(function(e,t,r){return"era"!==e.type&&("literal"!==e.type||!(t<r.length-1)||"era"!==r[t+1].type)})),n=v.map(function(e){return e.value}).join("")}return(!0===u||y&&"for today"===u)&&(n+=", ".concat(eo(e))),n}var ei=function(e){return function(t,r,n){return"literal"!==t.type||" "!==t.value||r<n.length-1&&"era"===n[r+1].type?t:{type:"literal",value:e}}};function eo(e){return e.toLocaleTimeString((0,z.J)(),{hour:"2-digit",minute:"2-digit"})}function es(e,t){var r,n;return ea(e,(r=U({},t),n=n={time:!0},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))}function el(e,t){var r=et("string"==typeof t?new Intl.Locale(t):t);return r?(0,a.yP)(e,(0,i.d)(r)):e}function eu(e,t){return new Intl.DurationFormat((0,z.J)(),t).format(e)}function ec(e,t){if(null==e)return null;if("string"==typeof e){var r=D(e,(0,z.J)());return r.invalid?(console.warn("Could not interpret '".concat(e,"' as a date")),null):(r.day&&!r.month&&(r=U({},(0,V.A)(r,"day"),{month:r.day})),r.month&&(r.month-=1),r.day&&(r=U({},(0,V.A)(r,"day"),{date:r.day})),M()(t).set(r))}return M()(e)}var ed=["years","months","days","hours","minutes","seconds"],ef={second:"seconds",minute:"minutes",hour:"hours",day:"days",month:"months",year:"years"};function ep(e){var t;return null!=(t=ef[e])?t:e}var eh={seconds:45,minutes:45,hours:22,days:26,months:11,years:1/0};function em(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:M()(),n=arguments.length>2?arguments[2]:void 0,a=M()(r),i=ec(e,a);if(null==i)return null;if("string"==typeof n){var o=ep(n);return $({},o,a.diff(i,o))}var s=null!=n?n:{},l=s.thresholds,u=s.largestUnit,c=s.smallestUnit;if(void 0!==u||void 0!==c){var d,f=c?ep(c):void 0;return d="auto"===u||void 0===u?function(e,t,r){for(var n=ed.indexOf(r),a=0;a<ed.length;a++){var i=ed[a];if(t.diff(e,i)>0)return a<=n?i:r}return r}(i,a,null!=f?f:"seconds"):ep(u),function(e,t,r,n){var a=ed.indexOf(r),i=ed.indexOf(n),o=ed.slice(a,i+1),s={},l=e,u=!0,c=!1,d=void 0;try{for(var f,p=o[Symbol.iterator]();!(u=(f=p.next()).done);u=!0){var h=f.value,m=t.diff(l,h);s[h]=m,l=l.add(m,h)}}catch(e){c=!0,d=e}finally{try{u||null==p.return||p.return()}finally{if(c)throw d}}return s}(i,a,d,null!=f?f:d)}var p=(t=function(e){var t=U({},eh);if(e){var r=!0,n=!1,a=void 0;try{for(var i,o=Object.entries(e)[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s,l=(s=i.value,function(e){if(Array.isArray(e))return e}(s)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(s)||function(e){if(e){if("string"==typeof e)return W(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return W(e,2)}}(s)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),u=l[0],c=l[1];void 0!==c&&(t[ep(u)]=c)}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}}return t}(l),a.diff(i,"seconds")<t.seconds?"seconds":a.diff(i,"minutes")<t.minutes?"minutes":a.diff(i,"hours")<t.hours?"hours":a.diff(i,"days")<t.days?"days":a.diff(i,"months")<t.months?"months":"years");return $({},p,a.diff(i,p))}var ey={style:"short",localeMatcher:"lookup"};function ev(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:M()(),r=arguments.length>2?arguments[2]:void 0,n=em(e,t,r);return null==n?null:eu(n,(void 0===r?"undefined":r&&"u">typeof Symbol&&r.constructor===Symbol?"symbol":typeof r)=="object"&&r.formatOptions?U({},ey,r.formatOptions):ey)}},4232(e,t,r){"use strict";function n(){var e=window.i18next.language;return"ht"===(e=e.replaceAll("_","-"))&&(e="fr-HT"),e}r.d(t,{J:()=>n})},4834(e,t,r){"use strict";r.d(t,{g2:()=>n.g2,kd:()=>function e(t){var r={},n=!0,a=!1,i=void 0;try{for(var o,s=Object.keys(t)[Symbol.iterator]();!(n=(o=s.next()).done);n=!0){var l=o.value;if(c(t[l])&&t[l].hasOwnProperty("_default"))r[l]=t[l]._default;else{if(l.startsWith("_"))continue;c(t[l])?r[l]=e(t[l]):r[l]=t[l]}}}catch(e){a=!0,i=e}finally{try{n||null==s.return||s.return()}finally{if(a)throw i}}return r},JK:()=>a.J,Rt:()=>n.Rt,_g:()=>u,a3:()=>n.a3,LW:()=>n.LW,XE:()=>n.XE,L5:()=>m,bN:()=>l.b,a7:()=>n.a7,sc:()=>i.s,rX:()=>d.r,L8:()=>n.L8,Yq:()=>n.Yq,w7:()=>s,L3:()=>n.L3,fU:()=>n.fU,_U:()=>n._U,d4:()=>n.d4,p0:()=>n.p0,kQ:()=>n.kQ,qE:()=>n.qE,pf:()=>n.pf});var n=r(3903),a=r(4232),i=r(2316);function o(e){if("string"==typeof e&&0!==e.trim().length){var t=e.replaceAll("_","-");try{return new Intl.Locale(t).toString()}catch(e){return}}}function s(e,t,r){if(null==e)return r;var n=o(e);if(!n)return console.warn("matchLocale: invalid requested locale tag: ".concat(JSON.stringify(e))),r;var a=[],i=!0,s=!1,l=void 0;try{for(var u,c=t[Symbol.iterator]();!(i=(u=c.next()).done);i=!0){var d=u.value,f=o(d);if(!f){console.warn("matchLocale: skipping invalid available locale tag: ".concat(JSON.stringify(d)));continue}a.push({canonical:f,original:d})}}catch(e){s=!0,l=e}finally{try{i||null==c.return||c.return()}finally{if(s)throw l}}for(var p=n;p;){var h=function(){var e=a.find(function(e){return e.canonical===p});if(e)return{v:e.original};var t=p+"-",r=a.find(function(e){return e.canonical.startsWith(t)});if(r)return{v:r.original};if("ht"===p)return p="fr-HT","continue";var n=p.lastIndexOf("-");if(-1===n)return"break";var i=(p=p.slice(0,n)).lastIndexOf("-");-1!==i&&p.length-i==2&&(p=p.slice(0,i))}();if("object"==(h&&"u">typeof Symbol&&h.constructor===Symbol?"symbol":typeof h))return h.v;if("break"===h)break}return r}var l=r(8254);function u(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.localStorage;try{return e.getItem("test"),!0}catch(e){return!1}}function c(e){return!!e&&e.constructor===Object}var d=r(9120);function f(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function p(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){f(i,n,a,o,s,"next",e)}function s(e){f(i,n,a,o,s,"throw",e)}o(void 0)})}}function h(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}function m(e){return p(function(e){var t,r,n,a,i,o,s,l=arguments;return h(this,function(u){switch(u.label){case 0:r=(t=l.length>1&&void 0!==l[1]?l[1]:{}).shouldRetry,n=t.getDelay,a=t.onError,r=null!=r?r:function(e){return e<=5},n=null!=n?n:function(e){return function(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return t*Math.pow(2,r?e+1:e)}(e,1e3)},i=0,o=void 0,u.label=1;case 1:var c;return u.trys.push([1,4,,5]),[4,(c=n(i),p(function(){return h(this,function(e){return c<=0?[2]:[2,new Promise(function(e){return setTimeout(e,c)})]})})())];case 2:return u.sent(),[4,e()];case 3:return[2,u.sent()];case 4:return s=u.sent(),null==a||a(s,i),o=s,[3,5];case 5:if(r(i++))return[3,1];u.label=6;case 6:throw o}})}).apply(this,arguments)}},9120(e,t,r){"use strict";r.d(t,{r:()=>o});var n=r(8164);function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function i(e){var t,r=function(e){if(Array.isArray(e))return e}(t=e.split("."))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),3!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return a(e,3);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return a(e,3)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),n=r[0],i=r[1],o=r[2];return"".concat(n,".").concat(i,".").concat(o)}function o(e,t){var r=function(e){var t=e.indexOf("-");if(t>=0){var r=i(e.slice(0,t)),n=e.slice(t+1);return"".concat(r,"-").concat(n)}return i(e)}(t);return n.satisfies(r,e,{includePrerelease:!0})}}}]);
20
+ `),()=>{s.current?.removeAttribute("data-motion-pop-id"),x.contains(b)&&x.removeChild(b)}},[t]),(0,v.jsx)(jS,{isPresent:t,childRef:s,sizeRef:l,pop:i,children:!1===i?e:g.cloneElement(e,{ref:c})})}let jO=({children:e,initial:t,isPresent:r,onExitComplete:n,custom:a,presenceAffectsLayout:i,mode:o,anchorX:s,anchorY:l,root:u})=>{let c=dS(jk),d=(0,g.useId)(),f=(0,g.useRef)(r),p=(0,g.useRef)(n);dR(()=>{f.current=r,p.current=n});let h=!0,m=(0,g.useMemo)(()=>(h=!1,{id:d,initial:t,isPresent:r,custom:a,onExitComplete:e=>{for(let t of(c.set(e,!0),c.values()))if(!t)return;n&&n()},register:e=>(c.set(e,!1),()=>{c.delete(e),f.current||c.size||p.current?.()})}),[r,c,n]);return i&&h&&(m={...m}),(0,g.useMemo)(()=>{c.forEach((e,t)=>c.set(t,!1))},[r]),g.useEffect(()=>{r||c.size||!n||n()},[r]),e=(0,v.jsx)(jj,{pop:"popLayout"===o,isPresent:r,anchorX:s,anchorY:l,root:u,children:e}),(0,v.jsx)(dw.Provider,{value:m,children:e})};function jk(){return new Map}let jE=e=>e.key||"";function jP(e){let t=[];return g.Children.forEach(e,e=>{(0,g.isValidElement)(e)&&t.push(e)}),t}let jA=({children:e,custom:t,initial:r=!0,onExitComplete:n,presenceAffectsLayout:a=!0,mode:i="sync",propagate:o=!1,anchorX:s="left",anchorY:l="top",root:u})=>{let[c,d]=pC(o),f=(0,g.useMemo)(()=>jP(e),[e]),p=o&&!c?[]:f.map(jE),h=(0,g.useRef)(!0),m=(0,g.useRef)(f),y=dS(()=>new Map),b=(0,g.useRef)(new Set),[x,w]=(0,g.useState)(f),[S,j]=(0,g.useState)(f);dR(()=>{h.current=!1,m.current=f;for(let e=0;e<S.length;e++){let t=jE(S[e]);p.includes(t)?(y.delete(t),b.current.delete(t)):!0!==y.get(t)&&y.set(t,!1)}},[S,p.length,p.join("-")]);let O=[];if(f!==x){let e=[...f];for(let t=0;t<S.length;t++){let r=S[t],n=jE(r);p.includes(n)||(e.splice(t,0,r),O.push(r))}return"wait"===i&&O.length&&(e=O),j(jP(e)),w(f),null}let{forceRender:k}=(0,g.useContext)(du);return(0,v.jsx)(v.Fragment,{children:S.map(e=>{let g=jE(e),x=(!o||!!c)&&(f===S||p.includes(g));return(0,v.jsx)(jO,{isPresent:x,initial:(!h.current||!!r)&&void 0,custom:t,presenceAffectsLayout:a,mode:i,root:u,onExitComplete:x?void 0:()=>{if(b.current.has(g)||!y.has(g))return;b.current.add(g),y.set(g,!0);let e=!0;y.forEach(t=>{t||(e=!1)}),e&&(k?.(),j(m.current),o&&d?.(),n&&n())},anchorX:s,anchorY:l,children:e},g)})})},jD={wrapper:"od7XT0veXj6mdEnncZFs+Q==",trigger:"_7A1e6-uGYRcfVQnfOx4geQ==",triggerIcon:"_8AaUzHzBvjhu4wIByBagPg==",triggerChevron:"NV6paA52ojWr+QJvS6VMUw==","triggerChevron--open":"tvyLx6UPztuSEo3wIE1oSQ==","triggerChevron--up":"SmGIbeFveBJB4FHlFhlbAA==",overlay:"_7fbyR1xFRRLItN8r0emD2w==",panel:"vzIn-j6yw5V0fmJWyVGXKg==",panelInner:"qTKkBfg7oksN9qrf7VLp1Q==",column:"C8xzSTaHxt8NM+8WglbIXQ==",columnSearch:"zHSJOF4qVG2jlPwAO+cLqQ==",columnSearchIcon:"_736VczNr3-sHL-FBa25KXw==",columnSearchInput:"_1VIyB+uqg5+6Y1G3Q+PnDw==",columnList:"wMozWE5hDKhxAGscGsLPSQ==",columnItem:"GJ+d+wAneJMJd8z-zKnedA==",columnItemIcon:"CDsY1qXafiUaITs4t-Xz8w==",columnItemLabel:"pQXzNkufWC-kTsP91lMc0g==",columnItemChevron:"VDhnJw1goYCbEvL0SzBpFA==",columnEmpty:"qDEruc7z1419lACB8Vawww=="};function jC(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var jT=function(e){var t,r=e.columnItems,n=e.columnIndex,a=e.activeItems,i=e.searchable,o=e.searchPlaceholder,s=e.onHover,l=e.onNavigate,u=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(""))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return jC(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return jC(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),c=u[0],d=u[1],f=(0,g.useMemo)(function(){if(!c.trim())return r;var e=c.trim().toLowerCase();return r.filter(function(t){return t.label.toLowerCase().includes(e)})},[r,c]);return(0,v.jsxs)(hz.div,{className:jD.column,initial:{opacity:0,width:0},animate:{opacity:1,width:"var(--cnd-column-width)"},exit:{opacity:0,width:0},transition:{duration:.2,ease:"easeOut"},children:[i&&(0,v.jsxs)("div",{className:jD.columnSearch,children:[(0,v.jsx)(o1,{className:jD.columnSearchIcon,size:14}),(0,v.jsx)("input",{type:"search",value:c,onChange:function(e){return d(e.target.value)},placeholder:o,className:jD.columnSearchInput,"aria-label":o})]}),(0,v.jsxs)("ul",{className:jD.columnList,role:"list",children:[f.map(function(e){var t,r=a[n]===e.id,i=!!(null==(t=e.children)?void 0:t.length),o=e.icon;return(0,v.jsx)("li",{children:(0,v.jsxs)("button",{type:"button",className:jD.columnItem,"data-active":r||void 0,onMouseEnter:function(){return s(e,n)},onFocus:function(){return s(e,n)},onClick:function(){!i&&e.path&&l(e.path)},children:[o&&(0,v.jsx)(o,{className:jD.columnItemIcon,size:16}),(0,v.jsx)("span",{className:jD.columnItemLabel,children:e.label}),i&&(0,v.jsx)(ow,{className:jD.columnItemChevron,size:14})]})},e.id)}),0===f.length&&(0,v.jsx)("li",{className:jD.columnEmpty,children:"—"})]})]})};function jN(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function jR(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function jM(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||j_(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function jI(e){return function(e){if(Array.isArray(e))return jN(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||j_(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function j_(e,t){if(e){if("string"==typeof e)return jN(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return jN(e,t)}}var jL=function(e){var t,r,n=e.items,a=e.triggerLabel,i=e.triggerIcon,o=e.direction,s=void 0===o?"down":o,l=e.searchable,u=void 0!==l&&l,c=e.searchPlaceholder,d=void 0===c?"Rechercher…":c,f=e.onNavigate,p=e.className,h=jM((0,g.useState)(!1),2),m=h[0],y=h[1],b=jM((0,g.useState)([n]),2),x=b[0],w=b[1],S=jM((0,g.useState)([]),2),j=S[0],k=S[1],E=jM((0,g.useState)(null),2),P=E[0],A=E[1],D=(0,g.useRef)(null);(0,g.useLayoutEffect)(function(){m||(w([n]),k([]))},[n,m]),(0,g.useLayoutEffect)(function(){if(m&&D.current){var e=D.current.getBoundingClientRect();A("up"===s?{left:e.left,bottom:window.innerHeight-e.top+8}:{left:e.left,top:e.bottom+8})}},[m,s]);var C=function(e,t){var r,n=jI(j);n[t]=e.id,(null==(r=e.children)?void 0:r.length)?w(jI(x.slice(0,t+1)).concat([e.children])):w(x.slice(0,t+1)),k(n)},T=function(e){y(!1),null==f||f(e)};return(0,v.jsxs)("div",{className:O()(jD.wrapper,p),children:[(0,v.jsxs)("button",{ref:D,type:"button",className:jD.trigger,onClick:function(){return y(function(e){return!e})},"aria-haspopup":"true","aria-expanded":m,children:[i&&(0,v.jsx)(i,{className:jD.triggerIcon,size:16}),(0,v.jsx)("span",{children:void 0===a?"Navigation":a}),(0,v.jsx)(ob,{className:O()(jD.triggerChevron,(jR(t={},jD["triggerChevron--open"],m),jR(t,jD["triggerChevron--up"],"up"===s),t)),size:14})]}),(0,v.jsx)(jA,{children:m&&P&&(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("div",{className:jD.overlay,onClick:function(){return y(!1)},"aria-hidden":"true"}),(0,v.jsx)(hz.div,{className:O()(jD.panel,jD["panel--".concat(s)]),style:(jR(r={left:P.left,top:P.top,bottom:P.bottom},"--cnd-panel-width","".concat(16*x.length,"rem")),jR(r,"--cnd-column-width","16rem"),r),initial:{opacity:0,y:"up"===s?10:-10,scale:.96},animate:{opacity:1,y:0,scale:1,width:"var(--cnd-panel-width)",transition:{opacity:{duration:.18},y:{duration:.28,type:"spring",stiffness:200,damping:20},scale:{duration:.18},width:{duration:.28,ease:"easeOut"}}},exit:{opacity:0,y:"up"===s?10:-10,scale:.96,transition:{duration:.18}},children:(0,v.jsx)("div",{className:jD.panelInner,children:(0,v.jsx)(jA,{mode:"sync",children:x.map(function(e,t){return(0,v.jsx)(jT,{columnItems:e,columnIndex:t,activeItems:j,searchable:u,searchPlaceholder:d,onHover:C,onNavigate:T},t)})})})})]})})]})},jF=(0,g.createContext)(null),jB=function(){var e=(0,g.useContext)(jF);if(!e)throw Error("Sheet compound components must be used within <Sheet>");return e};function jV(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var jz=function(e){var t,r=e.children,n=e.open,a=e.onOpenChange,i=e.defaultOpen,o=e.className,s=e.side,l=e.height,u=e.closeThreshold,c=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(null!=i&&i))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return jV(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return jV(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),d=c[0],f=c[1],p=void 0!==n,h=p?n:d,m=(0,g.useCallback)(function(e){null==a||a(e),p||f(e)},[a,p]);return(0,v.jsx)(jF.Provider,{value:{isOpen:h,onOpenChange:m,contentProps:{height:void 0===l?"55vh":l,className:void 0===o?"":o,closeThreshold:void 0===u?.3:u,side:void 0===s?"top":s}},children:r})};function jW(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var j$=function(e){var t,r=e.children,n=e.container,a=e.className,i=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return jW(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return jW(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),o=i[0],s=i[1];if((0,g.useEffect)(function(){s(!0)},[]),!o||"u"<typeof document)return null;var l=a?(0,v.jsx)("div",{className:a,children:r}):r;return(0,tZ.createPortal)(l,n||document.body)};let jU={triggerReset:"KchWk07qCyMztdOj8l6+nw==",container:"MW2IV8rXbcfJn9D6esV+-A==","container--closed":"ukmg3qKuvTIZgVpyD7X8AQ==",overlay:"zaRVZ17z7O8LzefxS5CxNw==",panel:"T5s7RxBCifLQWFgh1vOLDg==","panel--top":"PyeTpmsjKygAk2pCpe5NKQ==","panel--bottom":"+wv3nJKxJJhuz8K5j3YX7g==",body:"ePmeaHdSa+qf+ohZ4e4cpA==",scrollArea:"xSSRA7R71d88sDke9IOYhg==",handleRow:"IULYFP6QnLBTysbet5YXPQ==",handle:"_4QMSFXLduOJ5ZpOTm7K5ZQ==",header:"D7sRu9+Zla6rj0BHmTJqrQ==",title:"VNak3xly+5sZFSRmGcPHWQ==",description:"YFLey8nNGCmuU6P8ZlzzmA==",footer:"qeJpmxe-jqBAtL5CXcn3yg=="};function jH(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function jG(e){if(Array.isArray(e))return e}function jK(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function jq(e,t){if(e){if("string"==typeof e)return jH(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return jH(e,t)}}var jY=(0,g.forwardRef)(function(e,t){var r,n=jG(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||jq(r)||jK(),a=n[0],i=n.slice(1),o=a.className,s=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(a,["className"]),l=(jG(i)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),1!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(i)||jq(i,1)||jK())[0],u=jB(),c=u.isOpen,d=u.onOpenChange,f=(0,g.useCallback)(function(e){e.target===e.currentTarget&&d(!1)},[d]);return(0,v.jsx)(hz.div,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({ref:l,initial:{opacity:0},animate:{opacity:+!!c},transition:{duration:.2,ease:"easeOut"},onClick:f,className:O()(jU.overlay,o),style:{pointerEvents:c?"auto":"none"}},s))});function jX(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function jZ(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}jY.displayName="SheetOverlay";var jQ=function(e){var t=e.asChild,r=e.children,n=e.className,a=jB().onOpenChange,i=function(){return a(!0)};return t&&b().isValidElement(r)?b().cloneElement(r,jZ(jX({},r.props),{className:O()(r.props.className,n),onClick:function(e){var t,n;null==(t=(n=r.props).onClick)||t.call(n,e),i()}})):(0,v.jsx)("button",{onClick:i,type:"button",className:O()(jU.triggerReset,n),children:r})},jJ=function(e){var t=e.asChild,r=e.children,n=e.className,a=jB().onOpenChange,i=function(){return a(!1)};return t&&b().isValidElement(r)?b().cloneElement(r,jZ(jX({},r.props),{className:O()(r.props.className,n),onClick:function(e){var t,n;null==(t=(n=r.props).onClick)||t.call(n,e),i()}})):(0,v.jsx)("button",{onClick:i,type:"button",className:O()(jU.triggerReset,n),children:r})};function j0(e,t){[...t].reverse().forEach(r=>{let n=e.getVariant(r);n&&dV(e,n),e.variantChildren&&e.variantChildren.forEach(e=>{j0(e,t)})})}function j1(){let e=!1,t=new Set,r={subscribe:e=>(t.add(e),()=>void t.delete(e)),start(r,n){up(e,"controls.start() should only be called after a component has mounted. Consider calling within a useEffect hook.");let a=[];return t.forEach(e=>{a.push(f$(e,r,{transitionOverride:n}))}),Promise.all(a)},set:r=>(up(e,"controls.set() should only be called after a component has mounted. Consider calling within a useEffect hook."),t.forEach(e=>{var t,n;t=e,Array.isArray(n=r)?j0(t,n):"string"==typeof n?j0(t,[n]):dV(t,n)})),stop(){t.forEach(e=>{e.values.forEach(e=>e.stop())})},mount:()=>(e=!0,()=>{e=!1,r.stop()})};return r}let j2=function(){let e=dS(j1);return dR(e.mount,[]),e};function j3(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var j4=function(e){var t,r=e.children,n=e.className,a=jB(),i=a.isOpen,o=a.onOpenChange,s=a.contentProps,l=s.height,u=s.closeThreshold,c=s.side,d=j2(),f=(0,g.useRef)(null),p=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(0))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return j3(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return j3(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),h=p[0],m=p[1],y="top"===c?-1:1,b=(0,g.useCallback)(function(){return o(!1)},[o]),x=(0,g.useCallback)(function(){if("u"<typeof window)return 400;var e,t=window.innerHeight,r=window.innerWidth;return e=r<=640?.6*t:r<=1024?.55*t:.5*t,l.includes("vh")?e=parseInt(l,10)/100*t:l.includes("px")&&(e=parseInt(l,10)),Math.min(e,.8*t)},[l]);(0,g.useEffect)(function(){var e=function(){return m(x())};return e(),window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}},[x]),(0,g.useEffect)(function(){return i?(document.body.style.overflow="hidden",d.start({y:0,transition:{type:"spring",stiffness:400,damping:40,mass:.8}})):(document.body.style.overflow="",d.start({y:y*(h+50),transition:{type:"tween",ease:[.25,.46,.45,.94],duration:.3}})),function(){document.body.style.overflow=""}},[i,d,h,y]),(0,g.useEffect)(function(){var e=function(e){"Escape"===e.key&&i&&b()};return i&&document.addEventListener("keydown",e),function(){return document.removeEventListener("keydown",e)}},[i,b]);var w=(0,g.useCallback)(function(e,t){var r=y*t.offset.y>h*u,n=y*t.velocity.y>800;r||n?b():d.start({y:0,transition:{type:"spring",stiffness:500,damping:40}})},[d,b,u,h,y]),S=(0,g.useCallback)(function(e){e.target===f.current&&b()},[b]);if(0===h)return null;var j="top"===c?{top:-h,bottom:0}:{top:0,bottom:h};return(0,v.jsx)(j$,{children:(0,v.jsxs)("div",{className:O()(jU.container,!i&&jU["container--closed"]),children:[(0,v.jsx)(hz.div,{ref:f,initial:{opacity:0},animate:{opacity:+!!i},transition:{duration:.2,ease:"easeOut"},onClick:S,className:jU.overlay,style:{pointerEvents:i?"auto":"none"}}),(0,v.jsxs)(hz.div,{drag:"y",dragConstraints:j,dragElastic:"top"===c?{top:.1,bottom:0}:{top:0,bottom:.1},dragMomentum:!1,onDragEnd:w,animate:d,initial:{y:y*(h+50)},className:O()(jU.panel,jU["panel--".concat(c)],void 0===n?"":n),style:{height:h},children:["bottom"===c&&(0,v.jsx)("div",{className:jU.handleRow,children:(0,v.jsx)("div",{className:jU.handle})}),(0,v.jsx)("div",{className:jU.body,children:(0,v.jsx)("div",{className:jU.scrollArea,children:r})}),"top"===c&&(0,v.jsx)("div",{className:jU.handleRow,children:(0,v.jsx)("div",{className:jU.handle})})]})]})})},j5=function(e){var t=e.children,r=e.className;return(0,v.jsx)("div",{className:O()(jU.header,r),children:t})},j6=function(e){var t=e.children,r=e.className;return(0,v.jsx)("h3",{className:O()(jU.title,r),children:t})},j8=function(e){var t=e.children,r=e.className;return(0,v.jsx)("p",{className:O()(jU.description,r),children:t})},j9=function(e){var t=e.children,r=e.className;return(0,v.jsx)("div",{className:O()(jU.footer,r),children:t})},j7=jz;function Oe(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ot(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Or(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Oe(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Oe(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var On=function(e){var t=e.items,r=e.title,n=e.hint,a=void 0===n?"Glisser une carte vers le bas pour fermer":n,i=e.open,o=e.defaultOpen,s=e.onOpenChange,l=e.className,u=e.style,c=e.itemWidth,d=void 0===c?"14rem":c,f=e.itemHeight,p=void 0===f?"18rem":f,h=e.accentColor,m=Or((0,g.useState)(void 0!==o&&o),2),y=m[0],b=m[1],x=Or((0,g.useState)(!1),2),w=x[0],S=x[1],j=void 0!==i,k=j?i:y,E=function(e){null==s||s(e),j||b(e)},P=function(e,t){t.offset.y>100&&k&&(E(!1),S(!1))},A=(t.length-1)/2,D=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){Ot(e,t,r[t])})}return e}({},h?Ot({},"--fg-accent",h):void 0,u);return(0,v.jsx)("div",{className:O()("qUNaF87CyIQP-ewg0aT3gA==",l),style:D,children:(0,v.jsxs)("div",{className:"M-aEx-DAQtTyHwhMH64yGQ==",children:[(0,v.jsxs)("div",{className:"vxflXdvIBCrWhSbimzCWVQ==",children:[(0,v.jsxs)(hz.div,{className:"_6KkQsq8ts3ToOwYYDhfiMg==",animate:{opacity:+!k,scale:k?.9:1},children:[(0,v.jsx)("div",{className:"JmUVXLvcsCJoSXOSTZPN0A=="}),(0,v.jsx)("div",{className:"kOJbodcwrAswUmyC3DBjYA=="}),(0,v.jsx)("div",{className:"IL7xokwIcPXhZTStqhO09Q=="})]}),(0,v.jsx)("div",{className:"BkkLFMz1ckgbUpHR7DMWdA==",children:t.map(function(e,t){var r=t-A,n=1-.03*Math.abs(r);return(0,v.jsx)(hz.div,{drag:k,dragSnapToOrigin:!0,onDragEnd:P,className:O()("M84i--+bZPAx6uTscNbshA==",Ot({},"_3Zkd8QL+ngGj6mOBrfZEVQ==",k)),style:{width:d,height:p},animate:k?{y:-130,x:130*r,rotate:0,scale:1.05,zIndex:50}:{y:w?-10*r-40:-5*r,x:w?30*r:3*r,rotate:w?8*r:3*r,scale:n,zIndex:t+10},whileHover:k?{scale:1.1,zIndex:100}:void 0,whileDrag:k?{scale:1.05+.1,rotate:5,zIndex:150}:void 0,transition:{type:"spring",stiffness:350,damping:30},children:e.content},e.id)})}),(0,v.jsx)(hz.div,{className:"KBOODSF6+mKrIZESAVYrHg==",animate:{opacity:+!k,rotateX:w?-25:0,y:10*!!w,pointerEvents:k?"none":"auto"},onMouseEnter:function(){return S(!0)},onMouseLeave:function(){return S(!1)},onClick:function(){return E(!0)},children:(0,v.jsxs)("div",{className:"jw8fEvLvOius9zY16PK1hw==",children:[(0,v.jsx)("div",{className:"_9rOs7yRUMhW4QkMdrFqD0g=="}),(0,v.jsx)("div",{className:"_5i0EfM-8AE4OYYo2X2uwPA==",children:(0,v.jsx)("span",{className:"ZKSbpqexNyEpFvhZmwoLlQ==",children:void 0===r?"Dossier":r})})]})})]}),a&&(0,v.jsx)(hz.div,{animate:{opacity:+!!k,y:50*!k},className:"MzfhFqg3a0YwUbs3yGfdSQ==",children:a})]})})};function Oa(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Oi(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Oo(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Oa(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Oa(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Os(e){var t=e.items,r=e.className,n=e.style,a=Oo((0,g.useState)(null),2),i=a[0],o=a[1],s=Oo((0,g.useState)(null),2),l=s[0],u=s[1],c=function(e){u(i),o(e)},d=function(){u(i),o(null)};return(0,g.useEffect)(function(){if(i){var e=function(e){"Escape"===e.key&&d()};return window.addEventListener("keydown",e),function(){return window.removeEventListener("keydown",e)}}},[i]),(0,v.jsxs)("div",{className:O()("eA4BZJ4wlOaTHsiyz+antA==",r),style:n,children:[t.map(function(e){var t,r=(null==i?void 0:i.id)===e.id,n=!r&&(null==l?void 0:l.id)===e.id;return(0,v.jsx)("div",{className:e.className,children:(0,v.jsxs)(hz.div,{role:"button",tabIndex:0,"aria-pressed":r,onClick:function(){return c(e)},onKeyDown:function(t){("Enter"===t.key||" "===t.key)&&(t.preventDefault(),c(e))},className:O()(e.className,"cGA76nZGe5CnhWCCmTVGgQ==",(Oi(t={},"kptslMbsy8+vxJd8WIJrcg==",r),Oi(t,"NX+iOobXbUb-lQbAFNkL9Q==",!r),Oi(t,"gvMWGRV+aGwP5KrSi0geAQ==",n),t)),layoutId:"layout-grid-card-".concat(e.id),children:[r&&(0,v.jsx)(Ou,{item:i}),(0,v.jsx)(Ol,{item:e})]})},e.id)}),(0,v.jsx)(hz.div,{onClick:d,className:O()("V6jx9Z+WVL9MDdGPvJkaYA==",Oi({},"LbohBri+vFNoSWrMQc-qGQ==",!!(null==i?void 0:i.id))),animate:{opacity:+(null!=i&&!!i.id)},"aria-hidden":"true"})]})}function Ol(e){var t=e.item;return(0,v.jsx)(hz.img,{layoutId:"layout-grid-image-".concat(t.id),src:t.thumbnail,height:500,width:500,className:"U5gcULxDx+o6CMn4mOO-KA==",alt:"thumbnail"})}function Ou(e){var t=e.item;return(0,v.jsxs)("div",{className:"_0xZoWQ+67f8d9Ibrj2XGsA==",children:[(0,v.jsx)(hz.div,{initial:{opacity:0},animate:{opacity:.6},className:"_2uAL2ek35ay46kkDXaGh0g=="}),(0,v.jsx)(hz.div,{layoutId:"layout-grid-content-".concat(null==t?void 0:t.id),initial:{opacity:0,y:100},animate:{opacity:1,y:0},exit:{opacity:0,y:100},transition:{duration:.3,ease:"easeInOut"},className:"wsyzOu+s8n1iJlwVW0VMfA==",children:null==t?void 0:t.content})]})}let Oc="n6G8E1SbEEUsI3OWq+fUJw==",Od="A6XS7R+rH6Du2oTHAV9w1Q==",Of="QOgWcRICSDEnRCObIKMk1w==",Op="x1LP9u0NvE8GsXncVS6mxw==",Oh="Z2SR8P5h1ozswEBKF7Sb8Q==",Om="yTTHKbpGK3OMci1Nvf0BUQ==",Oy="p02avqg7uiwLf9Az9XbgGQ==",Ov="_9qLPpBBum4PfGB1uo7FCCQ==",Og="Zu4+XDmJUwKPLUmX+qsvAw==",Ob="i+x5CkYTvPGY-ug4QQFcdA==",Ox="AVPYYK3-6yQVldiVTCgQOQ==";var Ow=function(){return(0,v.jsx)("div",{className:"nhWkRlOlypB5yuvCy8EzwA==","aria-hidden":"true",children:Array.from({length:8},function(e,t){return(0,v.jsx)("div",{className:"wy+8JDS8iByYKvw08QdPOA=="},t)})})};function OS(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Oj(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function OO(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return OS(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return OS(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Ok=function(e){var t=e.title,r=e.coverImageUrl,n=e.category,a=e.itemCountLabel,i=e.meta,o=e.items,s=e.relatedEntity,l=e.onItemOptionsClick,u=e.className,c=e.style,d=OO((0,g.useState)(!1),2),f=d[0],p=d[1],h=OO((0,g.useState)(null),2),m=h[0],y=h[1],b=OO((0,g.useState)(null),2),x=b[0],w=b[1],S=OO((0,g.useState)(0),2),j=S[0],k=S[1],E=OO((0,g.useState)("translateY(0px)"),2),P=E[0],A=E[1],D=(0,g.useRef)(null),C=(0,g.useRef)(new Map),T=null!==m,N=f||T;(0,g.useEffect)(function(){if(null!==m){var e=function(){var e=C.current.get(m);e&&D.current&&k(e.getBoundingClientRect().top-D.current.offsetTop-2)};return e(),window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}}},[m]);var R=function(e){if(e.detail){var t=C.current.get(e.id);if(t&&D.current){var r=window.innerHeight-t.getBoundingClientRect().bottom+D.current.offsetTop-390;A("translateY(".concat(r,"px)"))}y(e.id),w(e)}};return(0,v.jsx)("div",{className:O()("xDbMR0gHWNpFj1Yoy68ZGA==",u),style:c,children:(0,v.jsx)("div",{className:"HavojgA3auWWriIv10hJ2w==",children:(0,v.jsxs)("div",{ref:D,className:O()("kmTNzVGOWEu5+aYeO+dJWg==",Oj({},"_8KuCFVRGG3hewrJk8eI8Ww==",N)),children:[(0,v.jsxs)("div",{className:"CJOSG6kKQMw-ivRwEJKw2g==",children:[(0,v.jsxs)("div",{className:Oc,children:[(0,v.jsx)("img",{className:Od,src:r,alt:""}),(0,v.jsx)("img",{className:O()(Od,Of),src:r,alt:"","aria-hidden":"true"})]}),(0,v.jsxs)("div",{className:"CULGeLqVu22C6sNwl7MlvA==",children:[(0,v.jsxs)("div",{className:"+F4KQqfbTnxcK27YlTU8Pw==",children:[(0,v.jsx)("h1",{className:Op,children:t}),(0,v.jsxs)("div",{className:"RzWO2Tf5Wsgu3xcy+EZH6w==",children:[n&&(0,v.jsx)("p",{className:Oh,children:n}),n&&a&&(0,v.jsx)("div",{className:Oy}),a&&(0,v.jsx)("p",{className:Oh,children:a}),a&&i&&(0,v.jsx)("div",{className:Oy}),i&&(0,v.jsx)("p",{className:Oh,children:i})]})]}),(0,v.jsx)("div",{className:"gVkvp0xTMjRND78EK-fmTg==",children:o.map(function(e){var t;return(0,v.jsxs)("div",{ref:(t=e.id,function(e){e?C.current.set(t,e):C.current.delete(t)}),className:Ov,onClick:function(){return R(e)},children:[(0,v.jsx)("p",{className:Om,children:e.title}),(0,v.jsxs)("div",{className:Og,children:[(0,v.jsx)("button",{type:"button",className:Ob,onClick:function(t){t.stopPropagation(),null==l||l(e)},"aria-label":"Options",children:(0,v.jsx)(oU,{size:20})}),e.meta&&(0,v.jsx)("p",{className:Oh,children:e.meta})]})]},e.id)})})]})]}),x&&(0,v.jsxs)("div",{className:O()("kR1yWXyQMcy-pc19Y1uCSg==",Oj({},"vGP3YGBeJwp273dxvca0mQ==",T)),style:{top:"".concat(j,"px"),transform:P},children:[(0,v.jsxs)("div",{className:Ov,children:[(0,v.jsx)("p",{className:Om,children:x.title}),(0,v.jsxs)("div",{className:Og,children:[(0,v.jsx)("button",{type:"button",className:Ob,onClick:function(){A("translateY(0px)"),y(null)},"aria-label":"Fermer",children:(0,v.jsx)(oa,{size:20,className:Ox})}),x.meta&&(0,v.jsx)("p",{className:Oh,children:x.meta})]})]}),(0,v.jsxs)("div",{className:"e6e-vgnHyLmMi5IFc63TGQ==",children:[x.credits&&(0,v.jsx)("div",{className:"CYjBwulWUDNbXjPGa+ouVw==",children:x.credits}),x.detail]}),(0,v.jsx)(Ow,{})]}),s&&(0,v.jsxs)("div",{className:"v-ulCXKHBflMTQlBMUxvMg==",style:{display:f?"flex":T?"none":void 0},children:[(0,v.jsx)("button",{type:"button",className:"_5npqIb7V1BrT1vIyp9ipBQ==",onClick:function(){return p(function(e){return!e})},"aria-label":f?"Fermer":"Voir les d\xe9tails",children:(0,v.jsx)(oa,{size:24,className:O()(Oj({},Ox,f))})}),(0,v.jsxs)("div",{className:"s8sEwmEJjuL2Pbcv4ehUYg==",children:[(0,v.jsxs)("div",{className:Oc,children:[(0,v.jsx)("h1",{className:Op,children:s.name}),(0,v.jsx)("img",{className:Od,src:s.photoUrl,alt:""}),(0,v.jsx)("img",{className:O()(Od,Of),src:s.photoUrl,alt:"","aria-hidden":"true"})]}),(0,v.jsxs)("div",{className:"oxZqOgOCkDHiFck7NvKY1g==",children:[(0,v.jsxs)("div",{className:"hi7d14X0gK3yPHbnYDMz7g==",children:[(0,v.jsxs)("div",{className:"ABgmK32LF+ngIsTFH+yrdw==",children:[s.category&&(0,v.jsx)("p",{className:O()(Oh,"DSINo9JINz-VX0HYc7rrNg=="),children:s.category}),s.category&&s.itemCountLabel&&(0,v.jsx)("div",{className:Oy}),s.itemCountLabel&&(0,v.jsx)("p",{className:Oh,children:s.itemCountLabel})]}),s.statLabel&&(0,v.jsx)("p",{className:Oh,children:s.statLabel})]}),s.description&&(0,v.jsx)("p",{className:Om,children:s.description})]})]}),(0,v.jsx)(Ow,{}),(0,v.jsx)("div",{className:"p4U4LPnGs8pTf99LZiEFEg=="})]})]})})})};function OE(e){var t=e.moduleName,r=e.meta;return r.titleKey?(0,V.t)(t,r.titleKey,r.title):r.title}function OP(e,t){var r=(0,x.useAssignedExtensions)(h1.As[e]),n=jl();return(0,g.useMemo)(function(){return r.map(function(e,t){return{extension:e,index:t}}).filter(function(e){var t=e.extension;return(0,h1.oW)(t.meta)}).filter(function(r){var n,a=r.extension;return!t||"bottom"!==e||(null!=(n=a.meta.rail)?n:"left")===t}).filter(function(t){var r=t.extension;return"right"===e||!0===r.meta.global||n.has(r.moduleName)}).sort(function(e,t){var r,n;return(null!=(r=e.extension.meta.order)?r:e.index)-(null!=(n=t.extension.meta.order)?n:t.index)||e.index-t.index}).map(function(t){var r=t.extension;return{id:r.name,moduleName:r.moduleName,meta:r.meta,compartment:"bottom"===e?null:(0,h1.lN)(r.meta)}})},[r,n,e,t])}var OA=(0,ya.A)("BookOpen",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]]),OD=(0,ya.A)("Bell",[["path",{d:"M10.268 21a2 2 0 0 0 3.464 0",key:"vwvbt9"}],["path",{d:"M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326",key:"11g9vi"}]]),OC=(0,ya.A)("Bot",[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]]),OT=(0,ya.A)("Building2",[["path",{d:"M6 22V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v18Z",key:"1b4qmf"}],["path",{d:"M6 12H4a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2",key:"i71pzd"}],["path",{d:"M18 9h2a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-2",key:"10jefs"}],["path",{d:"M10 6h4",key:"1itunk"}],["path",{d:"M10 10h4",key:"tcdvrf"}],["path",{d:"M10 14h4",key:"kelpxr"}],["path",{d:"M10 18h4",key:"1ulq68"}]]),ON=(0,ya.A)("CalendarDays",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}],["path",{d:"M8 14h.01",key:"6423bh"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M16 14h.01",key:"1gbofw"}],["path",{d:"M8 18h.01",key:"lrp35t"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M16 18h.01",key:"kzsmim"}]]),OR=(0,ya.A)("CircleHelp",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),OM=(0,ya.A)("Folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]),OI=(0,ya.A)("FolderTree",[["path",{d:"M20 10a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1h-2.5a1 1 0 0 1-.8-.4l-.9-1.2A1 1 0 0 0 15 3h-2a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z",key:"hod4my"}],["path",{d:"M20 21a1 1 0 0 0 1-1v-3a1 1 0 0 0-1-1h-2.9a1 1 0 0 1-.88-.55l-.42-.85a1 1 0 0 0-.92-.6H13a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z",key:"w4yl2u"}],["path",{d:"M3 5a2 2 0 0 0 2 2h3",key:"f2jnh7"}],["path",{d:"M3 3v13a2 2 0 0 0 2 2h3",key:"k8epm1"}]]),O_=(0,ya.A)("House",[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-5.999a2 2 0 0 1 2.582 0l7 5.999A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"1d0kgt"}]]),OL=r(8032),OF=(0,ya.A)("LayoutGrid",[["rect",{width:"7",height:"7",x:"3",y:"3",rx:"1",key:"1g98yp"}],["rect",{width:"7",height:"7",x:"14",y:"3",rx:"1",key:"6d4xhi"}],["rect",{width:"7",height:"7",x:"14",y:"14",rx:"1",key:"nxv5o0"}],["rect",{width:"7",height:"7",x:"3",y:"14",rx:"1",key:"1bb6yr"}]]),OB=(0,ya.A)("ListTree",[["path",{d:"M21 12h-8",key:"1bmf0i"}],["path",{d:"M21 6H8",key:"1pqkrb"}],["path",{d:"M21 18h-8",key:"1tm79t"}],["path",{d:"M3 6v4c0 1.1.9 2 2 2h3",key:"1ywdgy"}],["path",{d:"M3 10v6c0 1.1.9 2 2 2h3",key:"2wc746"}]]),OV=(0,ya.A)("MapPin",[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]),Oz=(0,ya.A)("Megaphone",[["path",{d:"m3 11 18-5v12L3 14v-3z",key:"n962bs"}],["path",{d:"M11.6 16.8a3 3 0 1 1-5.8-1.6",key:"1yl0tm"}]]),OW=(0,ya.A)("Newspaper",[["path",{d:"M4 22h16a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2H8a2 2 0 0 0-2 2v16a2 2 0 0 1-2 2Zm0 0a2 2 0 0 1-2-2v-9c0-1.1.9-2 2-2h2",key:"7pis2x"}],["path",{d:"M18 14h-8",key:"sponae"}],["path",{d:"M15 18h-5",key:"95g1m2"}],["path",{d:"M10 6h8v4h-8V6Z",key:"smlsk5"}]]),O$=(0,ya.A)("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]),OU=(0,ya.A)("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]),OH=(0,ya.A)("Terminal",[["polyline",{points:"4 17 10 11 4 5",key:"akl6gq"}],["line",{x1:"12",x2:"20",y1:"19",y2:"19",key:"q2wloq"}]]),OG=(0,ya.A)("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]),OK=(0,ya.A)("Calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]]),Oq=(0,ya.A)("CalendarCheck",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}],["path",{d:"m9 16 2 2 4-4",key:"19s6y9"}]]),OY=(0,ya.A)("Compass",[["path",{d:"m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z",key:"9ktpf1"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]),OX=(0,ya.A)("Contact",[["path",{d:"M16 2v2",key:"scm5qe"}],["path",{d:"M7 22v-2a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v2",key:"1waht3"}],["path",{d:"M8 2v2",key:"pbkmx"}],["circle",{cx:"12",cy:"11",r:"3",key:"itu57m"}],["rect",{x:"3",y:"4",width:"18",height:"18",rx:"2",key:"12vinp"}]]),OZ=(0,ya.A)("FileCheck",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"m9 15 2 2 4-4",key:"1grp1n"}]]),OQ=(0,ya.A)("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]),OJ=(0,ya.A)("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]),O0=(0,ya.A)("Layers",[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]]),O1=(0,ya.A)("Radio",[["path",{d:"M4.9 19.1C1 15.2 1 8.8 4.9 4.9",key:"1vaf9d"}],["path",{d:"M7.8 16.2c-2.3-2.3-2.3-6.1 0-8.5",key:"u1ii0m"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["path",{d:"M16.2 7.8c2.3 2.3 2.3 6.1 0 8.5",key:"1j5fej"}],["path",{d:"M19.1 4.9C23 8.8 23 15.1 19.1 19",key:"10b0cb"}]]),O2=(0,ya.A)("Star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]),O3=(0,ya.A)("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]),O4={BookOpen:OA,Bell:OD,Bot:OC,Building2:OT,CalendarDays:ON,CircleHelp:OR,Folder:OM,FolderTree:OI,House:O_,Info:OL.A,LayoutGrid:OF,ListTree:OB,MapPin:OV,Megaphone:Oz,Newspaper:OW,Search:O$,Settings:OU,Terminal:OH,Users:OG,Calendar:OK,CalendarCheck:Oq,Compass:OY,Contact:OX,FileCheck:OZ,FileText:OQ,Globe:OJ,Layers:O0,Radio:O1,Star:O2,Zap:O3};function O5(e){return e?O4[e]:void 0}function O6(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function O8(e){return function(e){if(Array.isArray(e))return O6(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e){if(e){if("string"==typeof e)return O6(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return O6(e,void 0)}}(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var O9="__default__",O7={height:60,minHeight:25,maxHeight:100},ke=function(e){return Math.round(100*e)/100};function kt(e){var t=e.reduce(function(e,t){return e+t.minHeight},0),r=e.reduce(function(e,t){return e+t.maxHeight},0),n=t>100?100/t:1;return{mins:e.map(function(e){return e.minHeight*n}),maxs:e.map(function(e){return r<100?100:Math.max(e.maxHeight,e.minHeight*n)})}}function kr(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(0===e.length)return[];if(1===e.length)return[100];var n=kt(e),a=n.mins,i=n.maxs,o=e.map(function(e){var t=r[e.key];return"number"==typeof t&&Number.isFinite(t)&&t>0}),s=e.reduce(function(e,t,r){return e+(o[r]?0:t.height)},0),l=e.reduce(function(e,t,n){return e+(o[n]?r[t.key]:0)},0),u=100-s;if(l>0&&u>0)t=e.map(function(e,t){return o[t]?r[e.key]*u/l:e.height});else{var c=e.map(function(e,t){return o[t]?r[e.key]:e.height}),d=c.reduce(function(e,t){return e+t},0);t=c.map(function(e){return 100*e/d})}for(var f=e.map(function(){}),p=0;p<=e.length&&"break"!==function(){var r=f.reduce(function(e,t){return e+(null!=t?t:0)},0),n=e.map(function(e,t){return t}).filter(function(e){return void 0===f[e]});if(0===n.length)return"break";var o=n.reduce(function(e,r){return e+t[r]},0),s=o>0?(100-r)/o:0,l=new Map(n.map(function(e){return[e,o>0?t[e]*s:(100-r)/n.length]})),u=0,c=!0,d=!1,p=void 0;try{for(var h,m=n[Symbol.iterator]();!(c=(h=m.next()).done);c=!0){var y=h.value,v=l.get(y);u+=Math.min(i[y],Math.max(a[y],v))-v}}catch(e){d=!0,p=e}finally{try{c||null==m.return||m.return()}finally{if(d)throw p}}var g=n.filter(function(e){return l.get(e)<a[e]-1e-6}),b=n.filter(function(e){return l.get(e)>i[e]+1e-6});if(0===g.length&&0===b.length){var x=!0,w=!1,S=void 0;try{for(var j,O=n[Symbol.iterator]();!(x=(j=O.next()).done);x=!0){var k=j.value;f[k]=l.get(k)}}catch(e){w=!0,S=e}finally{try{x||null==O.return||O.return()}finally{if(w)throw S}}return"break"}var E=u>1e-6?g:u<-1e-6?b:O8(g).concat(O8(b)),P=!0,A=!1,D=void 0;try{for(var C,T=(E.length>0?E:O8(g).concat(O8(b)))[Symbol.iterator]();!(P=(C=T.next()).done);P=!0){var N=C.value;f[N]=Math.min(i[N],Math.max(a[N],l.get(N)))}}catch(e){A=!0,D=e}finally{try{P||null==T.return||T.return()}finally{if(A)throw D}}}();p+=1);var h=e.map(function(e,r){var n;return null!=(n=f[r])?n:t[r]}).map(ke),m=ke(100-h.reduce(function(e,t){return e+t},0));if(0!==m){var y=0;h.forEach(function(e,t){e>h[y]&&(y=t)}),h[y]=ke(h[y]+m)}return h}function kn(e,t,r,n){var a=O8(e);if(r<0||r>=e.length-1||!Number.isFinite(n)||0===n)return a;var i=kt(t),o=i.mins,s=i.maxs,l=Array.from({length:r+1},function(e,t){return r-t}),u=Array.from({length:e.length-r-1},function(e,t){return r+1+t}),c=n>0?l:u,d=n>0?u:l,f=Math.min(Math.abs(n),c.reduce(function(e,t){return e+Math.max(0,s[t]-a[t])},0),d.reduce(function(e,t){return e+Math.max(0,a[t]-o[t])},0));if(f<=0)return a;var p=f,h=!0,m=!1,y=void 0;try{for(var v,g=c[Symbol.iterator]();!(h=(v=g.next()).done);h=!0){var b=v.value,x=Math.min(p,Math.max(0,s[b]-a[b]));if(a[b]+=x,(p-=x)<=1e-6)break}}catch(e){m=!0,y=e}finally{try{h||null==g.return||g.return()}finally{if(m)throw y}}var w=f,S=!0,j=!1,O=void 0;try{for(var k,E=d[Symbol.iterator]();!(S=(k=E.next()).done);S=!0){var P=k.value,A=Math.min(w,Math.max(0,a[P]-o[P]));if(a[P]-=A,(w-=A)<=1e-6)break}}catch(e){j=!0,O=e}finally{try{S||null==E.return||E.return()}finally{if(j)throw O}}return a.map(ke)}function ka(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function ki(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ko(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){ki(e,t,r[t])})}return e}function ks(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function kl(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||ku(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ku(e,t){if(e){if("string"==typeof e)return ka(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ka(e,t)}}var kc="egen-workbench-layout",kd=["left","bottom","right"],kf={left:280,right:320,bottom:240},kp={left:{min:200,max:640},right:{min:220,max:640},bottom:{min:120,max:720}},kh=["left","right"];function km(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O9;return"".concat(e,":").concat(t)}function ky(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{width:window.innerWidth,height:window.innerHeight},n=kp[e],a=n.min,i=n.max,o=Math.floor(("bottom"===e?.7*r.height:.5*r.width)||i),s=Math.max(a,Math.min(i,o));return Number.isFinite(t)?Math.round(Math.min(s,Math.max(a,t))):kf[e]}var kv=(0,h0.getGlobalStore)("workbench",function(){var e={sizes:ko({},kf),active:{left:null,right:null,bottom:null},compartments:{left:[],right:[]},heights:{}};try{var t=window.localStorage.getItem(kc);if(!t)return e;var r=JSON.parse(t),n=!0,a=!1,i=void 0;try{for(var o,s,l=kd[Symbol.iterator]();!(n=(s=l.next()).done);n=!0){var u,c,d=s.value,f=null==r||null==(u=r.sizes)?void 0:u[d];"number"==typeof f&&(e.sizes[d]=ky(d,f));var p=null==r||null==(c=r.active)?void 0:c[d];"string"==typeof p&&p.length>0&&(e.active[d]=p)}}catch(e){a=!0,i=e}finally{try{n||null==l.return||l.return()}finally{if(a)throw i}}var h=!0,m=!1,y=void 0;try{for(var v,g=kh[Symbol.iterator]();!(h=(v=g.next()).done);h=!0)!function(){var t,n=v.value,a=null==r||null==(t=r.compartments)?void 0:t[n];Array.isArray(a)&&(e.compartments[n]=a.filter(function(e,t){return"string"==typeof e&&e.length>0&&a.indexOf(e)===t}))}()}catch(e){m=!0,y=e}finally{try{h||null==g.return||g.return()}finally{if(m)throw y}}var b=!0,x=!1,w=void 0;try{for(var S,j=Object.entries(null!=(o=null==r?void 0:r.heights)?o:{})[Symbol.iterator]();!(b=(S=j.next()).done);b=!0){var O=kl(S.value,2),k=O[0],E=O[1];"number"==typeof E&&Number.isFinite(E)&&E>0&&E<=100&&(e.heights[k]=E)}}catch(e){x=!0,w=e}finally{try{b||null==j.return||j.return()}finally{if(x)throw w}}}catch(e){}return e}());kv.subscribe(function(e){try{window.localStorage.setItem(kc,JSON.stringify(e))}catch(e){}});var kg=function(e){return"left"===e||"right"===e};function kb(e){var t,r,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:kv.getState();return kg(e)&&null!=(t=null==(r=n.compartments)?void 0:r[e])?t:[]}function kx(e,t){if(!kg(e))return!1;try{var r=(0,h1.zx)(h1.As[e]).find(function(e){return e.name===t});return!!((null==r?void 0:r.meta)&&(0,h1.lN)(r.meta))}catch(e){return!1}}function kw(e,t){var r=kv.getState(),n=kb(e,r);n.includes(t)||kv.setState({compartments:ks(ko({},kO(),r.compartments),ki({},e,((function(e){if(Array.isArray(e))return ka(e)})(n)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(n)||ku(n)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([t])))})}function kS(e,t){var r=kv.getState(),n=kb(e,r);n.includes(t)&&kv.setState({compartments:ks(ko({},kO(),r.compartments),ki({},e,n.filter(function(e){return e!==t})))})}function kj(e,t){kb(e).includes(t)?kS(e,t):kw(e,t)}function kO(){return{left:[],right:[]}}function kk(e){var t,r=null!=(t=kv.getState().heights)?t:{};Object.entries(e).some(function(e){var t,n=kl(e,2),a=n[0],i=n[1];return Math.abs((null!=(t=r[a])?t:-1)-i)>.005})&&kv.setState({heights:ko({},r,e)})}function kE(e,t){if(kg(e)&&kx(e,t))return kj(e,t);var r=kv.getState().active;kv.setState({active:ks(ko({},r),ki({},e,r[e]===t?null:t))})}function kP(e,t){if(kg(e)&&kx(e,t))return kw(e,t);var r=kv.getState().active;r[e]!==t&&kv.setState({active:ks(ko({},r),ki({},e,t))})}function kA(e,t){var r=kv.getState();if(void 0!==t)return kg(e)&&kb(e,r).includes(t)?kS(e,t):void(r.active[e]===t&&kv.setState({active:ks(ko({},r.active),ki({},e,null))}));var n={};null!==r.active[e]&&(n.active=ks(ko({},r.active),ki({},e,null))),kg(e)&&kb(e,r).length>0&&(n.compartments=ks(ko({},kO(),r.compartments),ki({},e,[]))),Object.keys(n).length>0&&kv.setState(n)}function kD(e,t){var r=kv.getState().sizes,n=ky(e,t);r[e]!==n&&kv.setState({sizes:ks(ko({},r),ki({},e,n))})}function kC(e){kD(e,kf[e])}function kT(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function kN(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){kT(e,t,r[t])})}return e}var kR=(0,h0.getGlobalStore)("workbench-badges",{});function kM(e,t){var r,n,a=kR.getState();if(null==t||0===t||""===t){if(!(e in a))return;var i=kN({},a);delete i[e],kR.setState(i,!0);return}a[e]!==t&&kR.setState((r=kN({},a),n=null!=(n=kT({},e,t))?n:{},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))}function kI(e){return"number"==typeof e&&e>99?"99+":String(e)}let k_={rail:"qvz4aebX8qzfpVVMX6GW6Q==",railGroup:"P-xSK2ViNYrDfA549xovUw==",railSpacer:"yTluC88GKEaJN6D30M7pcA==",railIconMask:"OSxwK8smjsbkkpM9o+2NpA==",railBadge:"NgNYiAFQkrHYVJlXdFWBrw==",railButton:"HEdDR6YvG6RHfTPB5Yz0dA==",zone:"M2aeN9RqSdMKswCesWvs3Q==",compartment:"_49bE69E+4ICdrziyfNrkfA==","zone-left":"uk8RPM-up2A6b308shlQVA==","zone-right":"wWBsxyvamj6G--WUWLOkmQ==","zone-bottom":"ikvYl1ZGiITQC49T41KRyw==",compartmentGap:"pbIpeL1wxaG7IXsuyiQC8Q==",compartmentSplitter:"vX7HFTTPaZMj9PcYFt8iTw==",zoneHeader:"qrZbgloqkaOqKIsp77YScw==",zoneTitle:"+zT247J+DTnYGCJZtUKzrg==",zoneHeaderTools:"Jwd1DZ+AWNbC7RhA-J6eaA==",zoneClose:"+tZxiCZXeSDT53vt0lHOjQ==",zoneBody:"_1l3-F08RXMtn+D6J1yel5Q==",zoneSlot:"_1V5iYwK3aeERgDP7z4s-1w==",splitter:"_99ElxRI4lish2QNz++axSg==","splitter-left":"syr0QGi6BxPYDpnZAnrpGw==","splitter-right":"pGZQ7kMa98WrRUqWv6a1nQ==","splitter-bottom":"cst09ukUHpZYypz45awQDw==",cornerSplitter:"_6+KYstjwPB62arLn1eZfew==","cornerSplitter-left":"adI8Xh87aknu1jI247Fp9g==","cornerSplitter-right":"_6mB4WYkDihd2OrUjK-gLpg=="};function kL(e){var t=e.anchor,r=e.label,n=OP(t,e.rail),a=(0,x.useStore)(kv),i=a.active[t],o=kb(t,a);return 0===n.length?null:(0,v.jsx)("div",{role:"group","aria-label":r,"data-anchor":t,className:"".concat(k_.railGroup," egen-anim-stagger egen-anim-stagger--fade"),children:n.map(function(e){return(0,v.jsx)(kF,{tool:e,active:e.compartment?o.includes(e.id):e.id===i,onClick:function(){return e.compartment?kj(t,e.id):kE(t,e.id)}},e.id)})})}function kF(e){var t=e.tool,r=e.active,n=e.onClick,a=OE(t),i=O5(t.meta.icon),o=(0,h1.e4)(t.meta.iconUrl)?t.meta.iconUrl:void 0,s=(0,x.useStore)(kR)[t.id];return(0,v.jsxs)("button",{type:"button",className:k_.railButton,"aria-pressed":r,"aria-label":a,title:a,"data-active":r,onClick:n,children:[o?(0,v.jsx)("span",{"aria-hidden":"true",className:k_.railIconMask,style:{"--egen-rail-icon":'url("'.concat(o.replace(/"/g,"%22"),'")')}}):i?(0,v.jsx)(i,{size:18,"aria-hidden":"true"}):(0,v.jsx)("span",{"aria-hidden":"true",children:a.charAt(0).toUpperCase()}),void 0!==s&&(0,v.jsx)("span",{className:k_.railBadge,"data-testid":"workbench-badge-".concat(t.id),children:kI(s)})]})}function kB(){return(0,v.jsxs)("nav",{"aria-label":"Outils de l'application","data-testid":"workbench-rail-left",className:k_.rail,children:[(0,v.jsx)(kL,{anchor:"left",label:"Panneau lat\xe9ral"}),(0,v.jsx)("span",{className:k_.railSpacer}),(0,v.jsx)(kL,{anchor:"bottom",rail:"left",label:"Panneau inf\xe9rieur"})]})}function kV(){return(0,v.jsxs)("nav",{"aria-label":"Outils globaux","data-testid":"workbench-rail-right",className:k_.rail,children:[(0,v.jsx)(kL,{anchor:"right",label:"Panneau droit"}),(0,v.jsx)("span",{className:k_.railSpacer}),(0,v.jsx)(kL,{anchor:"bottom",rail:"right",label:"Panneau inf\xe9rieur"})]})}var kz=r(822);function kW(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var k$="data-workbench-resizing";function kU(e){var t=e.anchor,r=e.label,n=(0,x.useStore)(kv).sizes[t],a=(0,g.useRef)(null),i="bottom"!==t,o=function(e){var t,r;a.current&&(a.current=null,null==(t=(r=e.currentTarget).releasePointerCapture)||t.call(r,e.pointerId),document.documentElement.removeAttribute(k$))};return(0,v.jsx)("div",{role:"separator",tabIndex:0,"aria-label":r,"aria-orientation":i?"vertical":"horizontal","aria-valuenow":n,"aria-valuemin":ky(t,0),"aria-valuemax":ky(t,Number.MAX_SAFE_INTEGER),"data-anchor":t,className:"".concat(k_.splitter," ").concat(k_["splitter-".concat(t)]),onPointerDown:function(e){if(0===e.button){var r,n,i,o,s=null!=(r=null==(n=e.currentTarget.parentElement)?void 0:n.parentElement)?r:e.currentTarget.parentElement;if(s){var l=s.getBoundingClientRect(),u="left"===t?l.left:"right"===t?l.right:l.bottom,c="left"===t?l.right:"right"===t?l.left:l.top;a.current={edge:u,grab:("bottom"===t?e.clientY:e.clientX)-c},null==(i=(o=e.currentTarget).setPointerCapture)||i.call(o,e.pointerId),document.documentElement.setAttribute(k$,t),e.preventDefault()}}},onPointerMove:function(e){if(a.current){var r,n,i,o;kD(t,(r=e.clientX,n=e.clientY,i=a.current.edge,o=a.current.grab,"left"===t?r-o-i:"right"===t?i-(r-o):i-(n-o)))}},onPointerUp:o,onPointerCancel:o,onDoubleClick:function(){return kC(t)},onKeyDown:function(e){var r="left"===t?"ArrowRight":"right"===t?"ArrowLeft":"ArrowUp",n="left"===t?"ArrowLeft":"right"===t?"ArrowRight":"ArrowDown";if(e.key===r)kD(t,kv.getState().sizes[t]+16);else if(e.key===n)kD(t,kv.getState().sizes[t]-16);else if("Home"===e.key)kD(t,0);else{if("End"!==e.key)return;kD(t,Number.MAX_SAFE_INTEGER)}e.preventDefault()}})}function kH(e){var t=e.side,r=e.label,n=(0,g.useRef)(null),a="corner-".concat(t),i=function(e){var t,r;n.current&&(n.current=null,null==(t=(r=e.currentTarget).releasePointerCapture)||t.call(r,e.pointerId),document.documentElement.removeAttribute(k$))};return(0,v.jsx)("div",{"aria-hidden":"true",title:r,"data-corner":t,className:"".concat(k_.cornerSplitter," ").concat(k_["cornerSplitter-".concat(t)]),onPointerDown:function(e){if(0===e.button){var r,i,o=kv.getState().sizes;n.current={x:e.clientX,y:e.clientY,side:o[t],bottom:o.bottom},null==(r=(i=e.currentTarget).setPointerCapture)||r.call(i,e.pointerId),document.documentElement.setAttribute(k$,a),e.preventDefault()}},onPointerMove:function(e){var r=n.current;if(r){var a=e.clientX-r.x;kD(t,r.side+("left"===t?a:-a)),kD("bottom",r.bottom-(e.clientY-r.y))}},onPointerUp:i,onPointerCancel:i,onDoubleClick:function(){kC(t),kC("bottom")}})}var kG=function(e,t){return Object.fromEntries(e.map(function(e,r){return[e.key,t[r]]}))};function kK(e){var t=e.anchor,r=e.index,n=e.items,a=e.heights,i=e.label,o=(0,g.useRef)(null),s=function(e){var t,r;o.current&&(o.current=null,null==(t=(r=e.currentTarget).releasePointerCapture)||t.call(r,e.pointerId),document.documentElement.removeAttribute(k$))};return(0,v.jsx)("div",{role:"separator",tabIndex:0,"aria-label":i,"aria-orientation":"horizontal","aria-valuenow":Math.round(a[r]),"aria-valuemin":0,"aria-valuemax":100,"data-compartment-splitter":r,className:k_.compartmentSplitter,onPointerDown:function(e){if(0===e.button){var r,i,s=e.currentTarget.parentElement;if(s){var l=e.currentTarget.getBoundingClientRect().height,u=s.getBoundingClientRect().height-l*(n.length-1);u>0&&(o.current={y:e.clientY,heights:function(e){if(Array.isArray(e))return kW(e)}(a)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(a)||function(e){if(e){if("string"==typeof e)return kW(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return kW(e,void 0)}}(a)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),perPixel:100/u},null==(r=(i=e.currentTarget).setPointerCapture)||r.call(i,e.pointerId),document.documentElement.setAttribute(k$,"compartment-".concat(t)),e.preventDefault())}}},onPointerMove:function(e){var t=o.current;if(t){var a=(e.clientY-t.y)*t.perPixel;kk(kG(n,kn(t.heights,n,r,a)))}},onPointerUp:s,onPointerCancel:s,onDoubleClick:function(){return kk(kG(n,kr(n,{})))},onKeyDown:function(e){("ArrowUp"===e.key||"ArrowDown"===e.key)&&(kk(kG(n,kn(a,n,r,"ArrowDown"===e.key?5:-5))),e.preventDefault())}})}function kq(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var kY="data-tool-window-container",kX="data-tool-window-header";function kZ(e){var t,r=e.children,n=(0,g.useRef)(null),a=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(void 0))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return kq(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return kq(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=a[0],o=a[1];return(0,g.useLayoutEffect)(function(){var e,t,r=null==(t=n.current)?void 0:t.closest("[".concat(kY,"], aside[data-anchor]"));o(null!=(e=null==r?void 0:r.querySelector("[".concat(kX,"]")))?e:null)},[]),(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("span",{ref:n,hidden:!0}),void 0===i?null:null===i?r:(0,tZ.createPortal)(r,i)]})}function kQ(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function kJ(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function k0(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){kJ(e,t,r[t])})}return e}var k1={moduleName:"@egen-civitas/esm-styleguide",featureName:"workbench"},k2={left:"--egen-zone-left-width",right:"--egen-zone-right-width",bottom:"--egen-zone-bottom-height"},k3={left:"egen-anim-slide-in-from-left",right:"egen-anim-slide-in-from-right",bottom:"egen-anim-slide-in-from-bottom"},k4={left:"egen-anim-slide-out-to-left",right:"egen-anim-slide-out-to-right",bottom:"egen-anim-slide-out-to-bottom"};function k5(e){var t,r=e.anchor,n=OP(r),a=(0,x.useStore)(kv),i=a.active,o=a.sizes,s=i[r],l=o[r],u="bottom"===r?null:r,c=[],d=n.find(function(e){return!e.compartment&&e.id===s});if(d&&c.push({tool:d,item:k0({key:km(null!=u?u:"left")},O7)}),u){var f=!0,p=!1,h=void 0;try{for(var m,y,b=kb(u,a)[Symbol.iterator]();!(f=(y=b.next()).done);f=!0)!function(){var e=y.value,t=n.find(function(t){return t.id===e&&t.compartment});(null==t?void 0:t.compartment)&&c.push({tool:t,item:k0({key:km(u,e)},t.compartment)})}()}catch(e){p=!0,h=e}finally{try{f||null==b.return||b.return()}finally{if(p)throw h}}}var w=c.length>0,S=(0,g.useRef)([]),j=(0,g.useRef)(!1),O=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)("open"))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return kQ(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return kQ(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),k=O[0],E=O[1];w&&(S.current=c);var P=w?c:"closing"===k?S.current:[],A=P.length>0;(0,g.useLayoutEffect)(function(){if(w!==j.current){j.current=w,E(w?"opening":"closing");var e=window.setTimeout(function(){w||(S.current=[]),E("open")},300);return function(){return window.clearTimeout(e)}}},[w]),(0,g.useEffect)(function(){document.documentElement.style.setProperty(k2[r],w?"".concat(l,"px"):"0px")},[r,w,l]),(0,g.useEffect)(function(){return function(){document.documentElement.style.removeProperty(k2[r])}},[r]);var D=P.map(function(e){return e.item}),C=kr(D,null!=(m=a.heights)?m:{}),T=D.map(function(e,t){return"".concat(e.key,"=").concat(C[t])}).join("|");(0,g.useEffect)(function(){w&&!(D.length<2)&&kk(Object.fromEntries(D.map(function(e,t){return[e.key,C[t]]})))},[w,T]);var N=P[0]?OE(P[0].tool):"",R="closing"===k?k4[r]:"opening"===k?k3[r]:"",M="closing"!==k;return(0,v.jsx)("aside",{"data-testid":"workbench-zone-".concat(r),"data-anchor":r,"data-open":w,"data-phase":k,"data-compartments":P.length,"aria-label":N||void 0,hidden:!A,style:{"--egen-zone-inner-size":"".concat(l,"px")},className:"".concat(k_.zone," ").concat(k_["zone-".concat(r)]," ").concat(R),children:A&&(0,v.jsxs)(v.Fragment,{children:[P.map(function(e,t){var n=e.tool,a=e.item;return(0,v.jsxs)(g.Fragment,{children:[t>0&&M&&u&&(0,v.jsx)(kK,{anchor:u,index:t-1,items:D,heights:C,label:"Redimensionner ".concat(OE(P[t-1].tool)," et ").concat(OE(n))}),t>0&&!(M&&u)&&(0,v.jsx)("span",{"aria-hidden":"true",className:k_.compartmentGap}),(0,v.jsx)(k6,{anchor:r,tool:n,height:C[t],own:a.key!==km(null!=u?u:"left"),single:1===P.length})]},a.key)}),"closing"!==k&&(0,v.jsx)(kU,{anchor:r,label:"Redimensionner ".concat(N)}),"bottom"===r&&"closing"!==k&&null!==i.left&&(0,v.jsx)(kH,{side:"left",label:"Redimensionner la zone gauche et la zone basse"}),"bottom"===r&&"closing"!==k&&null!==i.right&&(0,v.jsx)(kH,{side:"right",label:"Redimensionner la zone droite et la zone basse"})]})})}function k6(e){var t,r=e.anchor,n=e.tool,a=e.height,i=e.own,o=e.single,s=OE(n),l=(0,g.useCallback)(function(e){return e.filter(function(e){return e.name===n.id})},[n.id]);return(0,v.jsxs)("section",(kJ(t={"data-testid":"workbench-compartment-".concat(r,"-").concat(i?n.id:O9),"data-compartment":i?"own":"default","data-height":Math.round(100*a)/100},kY,""),kJ(t,"style",o?void 0:{flex:"".concat(a," 1 0%")}),kJ(t,"className",k_.compartment),kJ(t,"children",[(0,v.jsxs)("header",{className:k_.zoneHeader,children:[(0,v.jsx)("h2",{className:k_.zoneTitle,children:s}),(0,v.jsx)("div",kJ({className:k_.zoneHeaderTools},kX,"")),(0,v.jsx)("button",{type:"button",className:k_.zoneClose,"aria-label":"Fermer ".concat(s),title:"Fermer ".concat(s),onClick:function(){return kA(r,n.id)},children:(0,v.jsx)(kz.A,{size:14,"aria-hidden":"true"})})]}),(0,v.jsx)("div",{className:"".concat(k_.zoneBody," egen-anim-fade-in"),children:(0,v.jsx)(x.ComponentContext.Provider,{value:k1,children:(0,v.jsx)(x.ExtensionSlot,{name:h1.As[r],select:l,className:k_.zoneSlot})})},n.id)]),t))}var k8={moduleName:"@egen-civitas/esm-styleguide",featureName:"workbench",strictMode:!1},k9=(0,x.egenComponentDecorator)(k8)(kB),k7=(0,x.egenComponentDecorator)(k8)(kV),Ee=(0,x.egenComponentDecorator)(k8)(k5);function Et(e){var t=e.railLeft,r=e.railRight,n=e.zoneLeft,a=e.zoneRight,i=e.zoneBottom;t&&(0,mP.createRoot)(t).render((0,v.jsx)(k9,{})),r&&(0,mP.createRoot)(r).render((0,v.jsx)(k7,{})),n&&(0,mP.createRoot)(n).render((0,v.jsx)(Ee,{anchor:"left"})),a&&(0,mP.createRoot)(a).render((0,v.jsx)(Ee,{anchor:"right"})),i&&(0,mP.createRoot)(i).render((0,v.jsx)(Ee,{anchor:"bottom"}))}function Er(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function En(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||Ei(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ea(e){return function(e){if(Array.isArray(e))return Er(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Ei(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ei(e,t){if(e){if("string"==typeof e)return Er(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Er(e,t)}}var Eo=function(e,t,r){return t?(0,V.t)(e,t,r):r};function Es(){var e=window.getEgenSpaBase().replace(/\/$/,""),t=window.location.pathname;return(t.startsWith(e)?t.slice(e.length):t).replace(/^\/+|\/+$/g,"")}function El(e){var t,r,n,a=e.section,i=(0,x.useAssignedExtensions)(h1.yS),o=(r=(t=En((0,g.useState)(Es),2))[0],n=t[1],(0,g.useEffect)(function(){var e=function(){return n(Es())};return window.addEventListener("single-spa:routing-event",e),window.addEventListener("popstate",e),e(),function(){window.removeEventListener("single-spa:routing-event",e),window.removeEventListener("popstate",e)}},[]),r),s=En((0,g.useState)(null),2),l=s[0],u=s[1],c=(0,g.useMemo)(function(){var e=new Map,t=!0,r=!1,n=void 0;try{for(var o,s=i[Symbol.iterator]();!(t=(o=s.next()).done);t=!0){var l=o.value;if((0,h1.DK)(l.meta)&&l.meta.section===a){var u=l.meta,c=null!=(f=u.group)?f:"",d=e.get(c);if(!d){var f,p,h=u.group?null!=(p=u.groupLabel)?p:u.group:void 0;d={key:c,label:h?Eo(l.moduleName,u.groupLabelKey,h):void 0,entries:[]},e.set(c,d)}d.entries.push({name:l.name,moduleName:l.moduleName,meta:u})}}}catch(e){r=!0,n=e}finally{try{t||null==s.return||s.return()}finally{if(r)throw n}}return Ea(e.values())},[i,a]),d=(0,g.useMemo)(function(){var e,t,r=c.flatMap(function(e){return e.entries}).filter(function(e){var t;return o===(t=e.meta.route)||o.startsWith("".concat(t,"/"))});if(0===r.length)return null;var n=(e=Math).max.apply(e,Ea(r.map(function(e){return e.meta.route.length}))),a=r.filter(function(e){return e.meta.route.length===n});return(null!=(t=a.find(function(e){return e.name===l}))?t:a[0]).name},[c,o,l]);return 0===c.length?null:(0,v.jsx)("nav",{className:"qLEdjoMnou12cJG2pcNl2g==","data-testid":"section-nav-".concat(a),children:c.map(function(e){return(0,v.jsxs)("div",{className:"Yyc847xcFssyhuatTQ7xiA==",role:"group","aria-label":e.label,children:[e.label&&(0,v.jsx)("h3",{className:"fqz9L1RbM505xmJMtsj0ug==",children:e.label}),(0,v.jsx)("ul",{className:"bxiFBKtONQbQt9kFcd6ZZA==",children:e.entries.map(function(e){var t=O5(e.meta.icon),r=Eo(e.moduleName,e.meta.labelKey,e.meta.label),n=e.meta.description?Eo(e.moduleName,e.meta.descriptionKey,e.meta.description):void 0;return(0,v.jsx)("li",{children:(0,v.jsxs)("button",{type:"button",className:"mQhizWw06oV9hY+VNVfIhw==","data-active":e.name===d,"aria-current":e.name===d?"page":void 0,title:n,onClick:function(){u(e.name),(0,y8.oo)({to:"${egenSpaBase}/".concat(e.meta.route)})},children:[t&&(0,v.jsx)(t,{size:16,"aria-hidden":"true",className:"K3jvNMlqmar7YFU-LrIMVA=="}),(0,v.jsx)("span",{className:"jukYKqSJ+u0ARW+Th96NRw==",children:r})]})},e.name)})})]},e.key)})})}var Eu={fade:{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}},scale:{initial:{opacity:0,scale:.94},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.96}},zoom:{initial:{opacity:0,scale:.6},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.6}},"slide-up":{initial:{opacity:0,y:48},animate:{opacity:1,y:0},exit:{opacity:0,y:24}},"slide-down":{initial:{opacity:0,y:-48},animate:{opacity:1,y:0},exit:{opacity:0,y:-24}},"slide-left":{initial:{opacity:0,x:48},animate:{opacity:1,x:0},exit:{opacity:0,x:24}},"slide-right":{initial:{opacity:0,x:-48},animate:{opacity:1,x:0},exit:{opacity:0,x:-24}},warp:{initial:{opacity:0,rotateX:-5,skewY:-1.5,scaleY:2,scaleX:.4,y:100},animate:{opacity:1,rotateX:0,skewY:0,scaleY:1,scaleX:1,y:0,transition:{duration:.35,ease:[.59,0,.35,1],y:{type:"spring",visualDuration:.7,bounce:.2}}},exit:{opacity:0,rotateX:-5,skewY:-1.5,scaleY:2,scaleX:.4,y:100,transition:{duration:.35,ease:[.59,0,.35,1]}}},none:{initial:{},animate:{},exit:{}}},Ec={warp:{transformPerspective:1e3,originX:.5,originY:0}};function Ed(){cE.current||cA();let[e]=(0,g.useState)(ck.current);return e}let Ef={triggerWrap:"obUOkmXvVgfdGywRlKafuQ==",root:"RGEtM+3JT-yTrSFA8YESww==",overlay:"_6MXfQidMjLnx27vgPw-9Sg==",warpGlow:"kd2FxTe0qj-EPlsuLvJA-A==",warpWave:"eYhosSxSrqkohY0gP1+l0g==",warpWaveTint:"v7v+84i9dK1RijFpwYzIYQ==",warpBlob:"TW8N0JWIkX2rNgyo078MpA==",warpBlobA:"_41ZLsf4sYJA24kAYHV4t9Q==",warpBlobB:"yBeNfkSKBCQ7aUPSLla25A==",centerLayer:"RUVI+vdIGx4IlAly1zskzg==",panel:"iLjC58ABoO85I1ObBvOilQ==",closeButton:"QJ7H9rD2013pVurP-n31bw==",dockBubble:"JgOy0alMLvPtoW+dnVnh9Q==","dockBubble--left":"_0TgTNggNd+BZEC9BP4NglQ==","dockBubble--right":"oaILkyqA-30uHGcpYEfM7Q=="};var Ep=function(e){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({opacity:.9,transition:{duration:.5,scale:{duration:15,repeat:1/0,repeatType:"loop",ease:"easeInOut",delay:.35}}},e?{}:{scale:[1,.7,1]})},Eh=function(){var e=Ed();return(0,v.jsxs)("div",{className:Ef.warpGlow,"aria-hidden":"true",children:[(0,v.jsx)(hz.div,{className:Ef.warpWave,initial:{scale:0,opacity:1},animate:{scale:e?1:10,opacity:.2,transition:{duration:.5,opacity:{duration:.5,ease:"easeInOut"}}},exit:{scale:0,opacity:1,transition:{duration:.25}}}),(0,v.jsx)(hz.div,{className:"".concat(Ef.warpBlob," ").concat(Ef.warpBlobA),initial:{opacity:0},animate:Ep(e),exit:{opacity:0,transition:{duration:.25}}}),(0,v.jsx)(hz.div,{className:"".concat(Ef.warpBlob," ").concat(Ef.warpBlobB),initial:{opacity:0},animate:Ep(e),exit:{opacity:0,transition:{duration:.25}}})]})};function Em(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ey(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ev(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){Ey(e,t,r[t])})}return e}function Eg(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Em(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Em(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Eb=function(e,t){return"u"<typeof window?e:Math.min(Math.max(e,8+t/2),window.innerHeight-8-t/2)},Ex=function(e){return(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"&&null!==e},Ew=function(e){var t,r,n,a,i,o,s,l,u,c=e.open,d=e.defaultOpen,f=e.onOpenChange,p=e.trigger,h=e.children,m=e.showCloseButton,y=e.renderCloseButton,b=e.cardVariant,x=e.cardProps,w=e.draggable,S=void 0!==w&&w,j=e.dockable,k=void 0!==j&&j,E=e.dockIcon,P=e.dockEdgeThreshold,A=void 0===P?80:P,D=e.dockUndockDistance,C=void 0===D?120:D,T=e.dockSize,N=void 0===T?56:T,R=e.closeOnOverlayClick,M=e.closeOnEscape,I=void 0===M||M,L=e.showOverlay,B=e.lockScroll,V=void 0===B||B,z=e.animation,W=void 0===z?"scale":z,$=e.overlayAnimation,U=e.overlayEffect,H=e.warpColor,G=e.className,K=e.style,q=e.overlayClassName,Y=Eg((0,g.useState)(void 0!==d&&d),2),X=Y[0],Z=Y[1],Q=Eg((0,g.useState)(!1),2),J=Q[0],ee=Q[1],et=Eg((0,g.useState)(null),2),er=et[0],en=et[1],ea=(0,g.useRef)(null),ei=(0,g.useId)(),eo=void 0!==c,es=eo?c:X,el=(0,g.useCallback)(function(e){null==f||f(e),eo||Z(e)},[f,eo]),eu=(0,g.useCallback)(function(){return el(!1)},[el]);(0,g.useEffect)(function(){return ee(!0)},[]),(0,g.useEffect)(function(){es&&en(null)},[es]);var ec=(0,g.useCallback)(function(){if(k&&ea.current&&"u">typeof window){var e=ea.current.getBoundingClientRect(),t=e.left+e.width/2,r=e.top+e.height/2;if(er)return void(Math.abs(t-("left"===er.side?0:window.innerWidth))>C?en(null):en({side:er.side,y:Eb(r,N)}));t<=A?en({side:"left",y:Eb(r,N)}):t>=window.innerWidth-A&&en({side:"right",y:Eb(r,N)})}},[k,er,A,C,N]);(0,g.useEffect)(function(){if(es&&V)return document.body.style.overflow="hidden",function(){document.body.style.overflow=""}},[es,V]),(0,g.useEffect)(function(){if(es&&I){var e=function(e){"Escape"===e.key&&eu()};return document.addEventListener("keydown",e),function(){return document.removeEventListener("keydown",e)}}},[es,I,eu]);var ed=Ex(W)?W:{preset:W},ef=null!=(n=ed.variants)?n:Eu[null!=(a=ed.preset)?a:"scale"],ep={duration:null!=(i=ed.duration)?i:.25,ease:null!=(o=ed.ease)?o:[.16,1,.3,1]},eh=ed.variants?void 0:null!=(s=ed.preset)?s:"scale",em=eh?Ec[eh]:void 0,ey=null!=U?U:"warp"===eh?"warp":"none",ev={duration:null!=(l=null==$?void 0:$.duration)?l:.2,ease:null!=(u=null==$?void 0:$.ease)?u:"easeOut"},eg=(0,v.jsx)(jA,{children:es&&(0,v.jsxs)("div",{className:Ef.root,children:[(void 0===L||L)&&!er&&(0,v.jsx)(hz.div,{className:O()(Ef.overlay,q),style:"warp"===ey?{"--card-modal-warp-color":null!=H?H:"var(--colors-error-500)"}:void 0,initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:ev,onClick:void 0===R||R?eu:void 0,"aria-hidden":"true",children:"warp"===ey&&(0,v.jsx)(Eh,{})}),er?(0,v.jsx)(hz.div,{ref:ea,className:O()(Ef.dockBubble,Ef["dockBubble--".concat(er.side)]),style:Ey({top:er.y,width:N,height:N},er.side,-(N/2)),drag:!0,dragMomentum:!1,dragElastic:.2,onDragEnd:ec,initial:{scale:.3,opacity:0},animate:{scale:1,opacity:1},exit:{scale:.3,opacity:0},transition:{type:"spring",stiffness:420,damping:32},whileDrag:{cursor:"grabbing"},role:"button",tabIndex:0,"aria-label":"D\xe9ployer le modal",onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&en(null)},children:null!=E?E:(0,v.jsx)(oV,{size:20})}):(0,v.jsx)("div",{className:Ef.centerLayer,children:(0,v.jsx)(hz.div,{ref:ea,role:"dialog","aria-modal":"true","aria-labelledby":(null==x?void 0:x.title)?ei:void 0,className:O()(Ef.panel,G),style:Ev({},em,K),variants:ef,initial:"initial",animate:"animate",exit:"exit",transition:ep,drag:S,dragMomentum:!1,dragElastic:.12,onDragEnd:k?ec:void 0,whileDrag:S?{cursor:"grabbing"}:void 0,children:(0,v.jsxs)(F,(t=Ev({variant:void 0===b?"default":b},x),r=r={children:[(void 0===m||m)&&(y?y(eu):(0,v.jsx)("button",{type:"button",className:Ef.closeButton,onClick:eu,"aria-label":"Fermer",children:(0,v.jsx)(oj,{size:18})})),h]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))})})]})});return(0,v.jsxs)(v.Fragment,{children:[p&&(0,v.jsx)("span",{className:Ef.triggerWrap,onClick:function(){return el(!0)},children:p}),J&&(0,tZ.createPortal)(eg,document.body)]})},ES=(0,g.createContext)(null);function Ej(){var e=(0,g.useContext)(ES);if(!e)throw Error("Select compound components must be used within <Select>");return e}function EO(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ek(e){var t,r=e.children,n=e.options,a=e.selectedOptionId,i=e.onOptionChange,o=e.open,s=e.onOpenChange,l=e.getOptionId,u=void 0===l?function(e){return e.id}:l,c=e.getOptionName,d=void 0===c?function(e){return e.name}:c,f=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return EO(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return EO(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),p=f[0],h=f[1],m=(0,g.useRef)(null),y=void 0!==o,b=y?o:p,x=(0,g.useCallback)(function(e){null==s||s(e),y||h(e)},[s,y]),w=(0,g.useMemo)(function(){var e;return a&&null!=(e=n.find(function(e){return u(e)===a}))?e:n[0]},[n,a,u]),S=(0,g.useCallback)(function(e){null==i||i(e),x(!1)},[i,x]);return(0,v.jsx)(ES.Provider,{value:{open:b,setOpen:x,selectedOption:w,options:n,onOptionSelect:S,getOptionId:u,getOptionName:d,triggerRef:m},children:r})}function EE(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var EP=function(e){var t,r=e.src,n=e.name,a=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return EE(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return EE(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),i=a[0],o=a[1];return r&&!i?(0,v.jsx)("img",{className:"SfeZipJ-EbaokHctW8FEUA==",src:r,alt:"",onError:function(){return o(!0)}}):(0,v.jsx)("span",{className:"JfvCvEXqGY3pQYoOoULjmg==","aria-hidden":"true",children:n.charAt(0).toUpperCase()})};function EA(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var ED=function(e){var t,r,n=e.className,a=e.renderTrigger,i=e.showAvatar,o=e.placeholder,s=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className","renderTrigger","showAvatar","placeholder"]),l=Ej(),u=l.open,c=l.setOpen,d=l.selectedOption,f=l.getOptionName,p=l.triggerRef;return(0,v.jsxs)("button",(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){EA(e,t,r[t])})}return e}({ref:p,type:"button","data-state":u?"open":"closed",className:O()("_8A7vObqyrHkzJZX3MyKCvg==",n),"aria-haspopup":"listbox","aria-expanded":u,onClick:function(){return c(!u)}},s),r=r={children:[a?a(d,u):(0,v.jsx)("span",{className:"eSzDXRtGcW-YSjmCT0-Ddw==",children:d?(0,v.jsxs)(v.Fragment,{children:[(void 0===i||i)&&(0,v.jsx)(EP,{src:d.logo,name:f(d)}),(0,v.jsx)("span",{className:"daPOVgYo-UqRJt-fl64xnA==",children:f(d)})]}):(0,v.jsx)("span",{className:"_9rM-qQ-coahjdQZK8YeKAA==",children:void 0===o?"S\xe9lectionner…":o})}),(0,v.jsx)(ob,{className:O()("IkujjwnflhrCxIL04AEPig==",EA({},"_2LDeSM6tUlPbxNaRHK05Iw==",u)),size:16})]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))};function EC(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function ET(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function EN(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return EC(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return EC(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var ER=function(e){var t=e.className,r=e.style,n=e.renderOption,a=e.title,i=void 0===a?"Options":a,o=e.searchable,s=e.searchPlaceholder,l=void 0===s?"Rechercher…":s,u=e.onSearch,c=e.emptyMessage,d=e.showAvatar,f=void 0===d||d,p=e.children,h=Ej(),m=h.open,y=h.setOpen,b=h.options,x=h.selectedOption,w=h.onOptionSelect,S=h.getOptionId,j=h.getOptionName,k=h.triggerRef,E=EN((0,g.useState)(""),2),P=E[0],A=E[1],D=EN((0,g.useState)(null),2),C=D[0],T=D[1],N=(0,g.useRef)(null);(0,g.useLayoutEffect)(function(){if(m&&k.current){var e=k.current.getBoundingClientRect();T({top:e.bottom+8,left:e.left,width:e.width})}},[m,k]),(0,g.useLayoutEffect)(function(){if(m){var e=function(e){var t,r,n=e.target;(null==(t=N.current)?void 0:t.contains(n))||(null==(r=k.current)?void 0:r.contains(n))||y(!1)},t=function(e){"Escape"===e.key&&y(!1)};return document.addEventListener("mousedown",e),document.addEventListener("keydown",t),function(){document.removeEventListener("mousedown",e),document.removeEventListener("keydown",t)}}},[m,y,k]),(0,g.useLayoutEffect)(function(){null==u||u(P)},[P,u]);var R=(0,g.useMemo)(function(){if(!P.trim())return b;var e=P.trim().toLowerCase();return b.filter(function(t){return j(t).toLowerCase().includes(e)})},[b,P,j]);return(0,v.jsx)(jA,{children:m&&C&&(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("div",{className:"_55fm5zZQNsrBHYAZbXmNvg==",onClick:function(){return y(!1)},"aria-hidden":"true"}),(0,v.jsxs)(hz.div,{ref:N,role:"listbox",className:O()("_8533SRCjw0RGEuTOYGY4FA==",t),style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){ET(e,t,r[t])})}return e}({top:C.top,left:C.left,minWidth:C.width},r),initial:{opacity:0,y:-6,scale:.98},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:-6,scale:.98,transition:{duration:.15}},transition:{duration:.18,ease:"easeOut"},children:[i&&(0,v.jsx)("div",{className:"hvqzvUcvwgWeDSSzp+zRfQ==",children:(0,v.jsx)("p",{className:"WuMZ5aFHDUDGitQ16DWxkQ==",children:i})}),void 0!==o&&o&&(0,v.jsxs)("div",{className:"El+2XqUZnMl2EdCFZiCqZg==",children:[(0,v.jsx)(o1,{className:"G0ZQ7JjU-IctRcuJd8GAMA==",size:14}),(0,v.jsx)("input",{type:"search",value:P,onChange:function(e){return A(e.target.value)},placeholder:l,className:"jQTabWEMQ1lzIpV-psr-Iw==","aria-label":l})]}),(0,v.jsx)("div",{className:"RP3TMqBbVREsRmefNgXF3A==",children:0===R.length?(0,v.jsx)("div",{className:"ytySk7Z-uqE+Cd9nnCNIzQ==",children:void 0===c?"Aucun r\xe9sultat.":c}):R.map(function(e){var t=!!(x&&S(x)===S(e));return(0,v.jsx)("button",{type:"button",role:"option","aria-selected":t,className:O()("B1tJItorhHLvItWNBDbDTg==",ET({},"_3ytcFRMy9adpn2Lj3bv0pA==",t)),onClick:function(){return w(e)},children:n?n(e,t):(0,v.jsxs)("span",{className:"SVev5Gq0Bwn3qsCJanJGhg==",children:[f&&(0,v.jsx)(EP,{src:e.logo,name:j(e)}),(0,v.jsxs)("span",{className:"tv64rRuAO4duYiHknZebcQ==",children:[(0,v.jsx)("span",{className:"_2a5Da3T58kUDerdneCN30g==",children:j(e)}),"string"==typeof e.plan&&(0,v.jsx)("span",{className:"lcrpGqGFBDjmEWV5DeMRCw==",children:e.plan})]}),t&&(0,v.jsx)(og,{className:"v2g0jDDAFYSc-NvgPQzIuw==",size:16})]})},S(e))})}),p&&(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("div",{className:"jiBHwsnN8h16vEbCOHfFyQ=="}),(0,v.jsx)("div",{className:"xQ7Xx8vG4UYoZ5L2n4s7aw==",children:p})]})]})]})})};let EM="-ATlOUGNcp7GZJPUeq8rFQ==";function EI(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function E_(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||EL(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function EL(e,t){if(e){if("string"==typeof e)return EI(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return EI(e,t)}}function EF(e){var t=e.options,r=e.defaultActiveIndex,n=e.onChange,a=e.title,i=e.subtitle,o=e.className,s=e.style,l=E_((0,g.useState)(void 0===r?0:r),2),u=l[0],c=l[1],d=E_((0,g.useState)([]),2),f=d[0],p=d[1],h=function(e){e!==u&&(c(e),null==n||n(e))};return(0,g.useEffect)(function(){var e=[];return t.forEach(function(t,r){var n=setTimeout(function(){p(function(e){return((function(e){if(Array.isArray(e))return EI(e)})(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||EL(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([r])})},180*r);e.push(n)}),function(){e.forEach(function(e){return clearTimeout(e)})}},[]),(0,v.jsxs)("div",{className:O()("wlcxPFWjrVtumBSV-e-CDA==",o),style:s,children:[(a||i)&&(0,v.jsxs)("div",{className:"bj+Iqs7YlC4rnGPeWHvfDA==",children:[a&&(0,v.jsx)("h1",{className:O()("BxZYvA8NGXlbyIbv2WeY+g==",EM,"hlPOKNY1Iajw1xOcwAeSBA=="),children:a}),i&&(0,v.jsx)("p",{className:O()("feAT6ZKoC5a3dcOZdCuiXQ==",EM,"bhPpy9KSGVluihqPVuUiTw=="),children:i})]}),(0,v.jsx)("div",{className:"YjKVOFGPUd8QRnTyYbHlEQ=="}),(0,v.jsx)("div",{className:"yxtd7MYVN9PUttKi+ACMTA==",children:t.map(function(e,t){var r=u===t,n=f.includes(t);return(0,v.jsxs)("div",{role:"button",tabIndex:0,"aria-pressed":r,"aria-label":e.title,className:"KXRbSNJdVXlt4FjqmIyEqA==",style:{backgroundImage:"url('".concat(e.image,"')"),backgroundSize:r?"auto 100%":"auto 120%",opacity:+!!n,transform:n?"translateX(0)":"translateX(-60px)",borderColor:r?"var(--colors-on-primary)":"var(--colors-neutral-800)",boxShadow:r?"0 20px 60px color-mix(in srgb, var(--colors-neutral-950) 50%, transparent)":"0 10px 30px color-mix(in srgb, var(--colors-neutral-950) 30%, transparent)",flex:r?"7 1 0%":"1 1 0%",zIndex:r?10:1},onClick:function(){return h(t)},onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&(e.preventDefault(),h(t))},children:[(0,v.jsx)("div",{className:"tWfgJW24bLfSOAIrfBdeBw==",style:{bottom:r?"0":"-40px",boxShadow:r?"inset 0 -120px 120px -120px var(--colors-neutral-950), inset 0 -120px 120px -80px var(--colors-neutral-950)":"inset 0 -120px 0px -120px var(--colors-neutral-950), inset 0 -120px 0px -80px var(--colors-neutral-950)"}}),(0,v.jsxs)("div",{className:"_29Y7xxDXDwKDDxpgJdNRmw==",children:[(0,v.jsx)("div",{className:"NLN-jvKhi89LBjqeRG23bA==",children:e.icon}),(0,v.jsxs)("div",{className:"rUd70NVRl13hfW708rVyBw==",children:[(0,v.jsx)("div",{className:"C7SafuQjFwOk8hTZ+e5smA==",style:{opacity:+!!r,transform:r?"translateX(0)":"translateX(25px)"},children:e.title}),(0,v.jsx)("div",{className:"eJ6SOWnBp59Zc89zmo61Zw==",style:{opacity:+!!r,transform:r?"translateX(0)":"translateX(25px)"},children:e.description})]})]})]},t)})})]})}function EB(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function EV(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var Ez=function(e){return EB({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:24,height:24,fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":!0,focusable:!1},e)},EW=function(e){return(0,v.jsx)("svg",EV(EB({},Ez(e)),{children:(0,v.jsx)("path",{d:"m6 9 6 6 6-6"})}))},E$=function(e){return(0,v.jsx)("svg",EV(EB({},Ez(e)),{children:(0,v.jsx)("path",{d:"M20 6 9 17l-5-5"})}))},EU=function(e){return(0,v.jsxs)("svg",EV(EB({},Ez(e)),{children:[(0,v.jsx)("path",{d:"m7 15 5 5 5-5"}),(0,v.jsx)("path",{d:"m7 9 5-5 5 5"})]}))},EH=function(e){return(0,v.jsxs)("svg",EV(EB({},Ez(e)),{children:[(0,v.jsx)("circle",{cx:"11",cy:"11",r:"8"}),(0,v.jsx)("path",{d:"m21 21-4.3-4.3"})]}))},EG=function(e){return(0,v.jsxs)("svg",EV(EB({},Ez(e)),{children:[(0,v.jsx)("path",{d:"M18 6 6 18"}),(0,v.jsx)("path",{d:"m6 6 12 12"})]}))},EK=function(e){return(0,v.jsx)("svg",EV(EB({},Ez(e)),{children:(0,v.jsx)("path",{d:"M21 12a9 9 0 1 1-6.219-8.56"})}))};function Eq(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function EY(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Eq(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Eq(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var EX={type:"spring",duration:.5,bounce:.22},EZ="flex w-full items-center justify-between gap-2 px-3.5 py-2.5 text-sm",EQ={hidden:{opacity:0,y:-6,filter:"blur(3px)"},show:{opacity:1,y:0,filter:"blur(0px)"}},EJ=(0,g.createContext)(null);function E0(e){var t=(0,g.useContext)(EJ);if(!t)throw Error("".concat(e," must be used within <MorphSelect>"));return t}function E1(e){var t,r=e.value,n=e.defaultValue,a=e.onValueChange,i=e.open,o=e.defaultOpen,s=e.onOpenChange,l=e.disabled,u=void 0!==l&&l,c=e.transition,d=void 0===c?EX:c,f=e.radius,p=void 0===f?12:f,h=e.stagger,m=void 0===h?.035:h,y=e.staggerDelay,b=void 0===y?.08:y,x=e.className,S=e.children,j=null!=(t=Ed())&&t,O=(0,g.useId)(),k=(0,g.useRef)(null),E=EY((0,g.useState)(void 0!==o&&o),2),P=E[0],A=E[1],D=void 0!==i,C=D?i:P,T=(0,g.useCallback)(function(e){D||A(e),null==s||s(e)},[D,s]),N=EY((0,g.useState)(n),2),R=N[0],M=N[1],I=EY((0,g.useState)(new Map),2),L=I[0],F=I[1],B=EY((0,g.useState)("Select"),2),V=B[0],z=B[1],W=void 0!==r,$=W?r:R,U=(0,g.useCallback)(function(e){W||M(e),null==a||a(e),T(!1)},[W,a,T]),H=(0,g.useCallback)(function(e,t){F(function(r){var n,a,i=new Map(r);return i.set(e,{label:t,count:(null!=(n=null==(a=r.get(e))?void 0:a.count)?n:0)+1}),i})},[]),G=(0,g.useCallback)(function(e){F(function(t){var r=t.get(e);if(!r)return t;var n=new Map(t);return r.count<=1?n.delete(e):n.set(e,{label:r.label,count:r.count-1}),n})},[]);(0,g.useEffect)(function(){if(C){var e=function(e){return"Escape"===e.key&&T(!1)},t=function(e){k.current&&!k.current.contains(e.target)&&T(!1)};return window.addEventListener("keydown",e),window.addEventListener("pointerdown",t),function(){window.removeEventListener("keydown",e),window.removeEventListener("pointerdown",t)}}},[C,T]);var K=(0,g.useMemo)(function(){return{value:$,open:C,setOpen:T,select:U,register:H,unregister:G,labelFor:function(e){var t;return void 0===e||null==(t=L.get(e))?void 0:t.label},placeholder:V,setPlaceholder:z,reduce:j,layoutId:"".concat(O,"-surface"),triggerId:"".concat(O,"-trigger"),listId:"".concat(O,"-list"),disabled:u,transition:d,radius:p,stagger:m,staggerDelay:b}},[$,C,T,U,H,G,L,V,j,O,u,d,p,m,b]);return(0,v.jsx)(EJ.Provider,{value:K,children:(0,v.jsx)("div",{ref:k,className:(0,w.cn)("relative",x),children:S})})}function E2(e){var t,r=e.placeholder,n=e.className,a=E0("MorphSelectValue");(0,g.useEffect)(function(){r&&a.setPlaceholder(r)},[r,a.setPlaceholder]);var i=a.labelFor(a.value);return(0,v.jsx)("span",{className:(0,w.cn)(i?"text-foreground":"text-muted-foreground",n),children:null!=(t=null!=i?i:r)?t:"Select"})}function E3(e){var t,r,n=e.className,a=e.icon,i=e.children,o=E0("MorphSelectTrigger"),s=null!=a?a:(0,v.jsx)(EW,{className:"h-4 w-4"});return(0,v.jsxs)(v.Fragment,{children:[(0,v.jsxs)("div",(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"aria-hidden":!0},{inert:""}),r=r={className:(0,w.cn)(EZ,"invisible rounded-xl border border-border"),children:[i,s]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t)),(0,v.jsx)(jA,{initial:!1,mode:"popLayout",children:o.open?null:(0,v.jsxs)(hz.button,{layoutId:o.layoutId,type:"button",id:o.triggerId,disabled:o.disabled,"aria-haspopup":"listbox","aria-expanded":o.open,"aria-controls":o.listId,onClick:function(){return o.setOpen(!0)},transition:o.reduce?{duration:0}:o.transition,style:{borderRadius:o.radius},className:(0,w.cn)(EZ,"absolute inset-x-0 top-0 z-10 border border-border bg-background text-foreground outline-none transition-colors","hover:border-input focus-visible:ring-2 focus-visible:ring-foreground/20","disabled:pointer-events-none disabled:opacity-50",n),children:[(0,v.jsx)(hz.span,{layout:"position",className:"min-w-0 truncate",children:i}),(0,v.jsx)(hz.span,{layout:"position",className:"text-muted-foreground",children:s})]},"trigger")})]})}function E4(e){var t=e.className,r=e.headerClassName,n=e.listClassName,a=e.icon,i=e.children,o=E0("MorphSelectContent"),s=o.labelFor(o.value),l=(0,g.useMemo)(function(){return{hidden:{},show:{transition:{staggerChildren:o.stagger,delayChildren:o.staggerDelay}}}},[o.stagger,o.staggerDelay]);return(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("div",{className:"hidden",children:i}),(0,v.jsx)(jA,{initial:!1,mode:"popLayout",children:o.open?(0,v.jsxs)(hz.div,{layoutId:o.layoutId,id:o.listId,role:"listbox","aria-labelledby":o.triggerId,transition:o.reduce?{duration:0}:o.transition,style:{borderRadius:o.radius},className:(0,w.cn)("absolute inset-x-0 top-0 z-30 overflow-hidden border border-border bg-background shadow-lg",t),children:[(0,v.jsxs)(hz.button,{type:"button",layout:"position","aria-expanded":!0,onClick:function(){return o.setOpen(!1)},className:(0,w.cn)(EZ,"outline-none",r),children:[(0,v.jsx)("span",{className:(0,w.cn)("min-w-0 truncate",s?"text-foreground":"text-muted-foreground"),children:null!=s?s:o.placeholder}),(0,v.jsx)(hz.span,{animate:{rotate:180},transition:o.reduce?{duration:0}:o.transition,className:"text-muted-foreground",children:null!=a?a:(0,v.jsx)(EW,{className:"h-4 w-4"})})]}),(0,v.jsx)("div",{className:"h-px bg-border"}),(0,v.jsx)(hz.ul,{initial:"hidden",animate:"show",variants:o.reduce?void 0:l,className:(0,w.cn)("p-1",n),children:i})]},"panel"):null})]})}function E5(e){var t=e.value,r=e.disabled,n=e.label,a=e.indicator,i=e.className,o=e.children,s=E0("MorphSelectItem"),l=s.value===t,u=null!=n?n:"string"==typeof o?o:t;return(0,g.useLayoutEffect)(function(){return s.register(t,u),function(){return s.unregister(t)}},[s.register,s.unregister,t,u]),(0,v.jsx)(hz.li,{variants:s.reduce?void 0:EQ,children:(0,v.jsxs)("button",{type:"button",role:"option","aria-selected":l,disabled:void 0!==r&&r,onClick:function(){return s.select(t)},className:(0,w.cn)("flex w-full items-center justify-between gap-2 rounded-lg px-2.5 py-1.5 text-left text-sm outline-none transition-colors",l?"bg-muted text-foreground":"text-muted-foreground hover:bg-muted hover:text-foreground focus-visible:bg-muted","disabled:pointer-events-none disabled:opacity-50",i),children:[o,l?null!=a?a:(0,v.jsx)(E$,{className:"h-3.5 w-3.5 shrink-0"}):null]})})}function E6(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function E8(e){if(Array.isArray(e))return e}function E9(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function E7(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function Pe(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Pt(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function Pr(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function Pn(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function Pa(e,t){return E8(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||Po(e,t)||Pe()}function Pi(e){return E8(e)||E7(e)||Po(e)||Pe()}function Po(e,t){if(e){if("string"==typeof e)return E6(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return E6(e,t)}}var Ps=function(e){var t=e.state;return(0,v.jsx)("svg",{viewBox:"0 0 24 24",className:"w-5 h-5 text-muted-foreground transition-colors group-hover:text-foreground pointer-events-none",children:(0,v.jsx)("path",{d:"x"===t?"M 6 18 L 18 6 M 18 18 L 6 6":"up"===t?"M 6 15 L 12 9 M 18 15 L 12 9":"M 6 9 L 12 15 M 18 9 L 12 15",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",fill:"none",style:{transition:"d 0.4s cubic-bezier(0.4, 0, 0.2, 1)"}})})},Pl=function(e){var t=e.className;return(0,v.jsx)("svg",{viewBox:"0 0 24 24",className:(0,w.cn)("w-4 h-4",t),fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",children:(0,v.jsx)("polyline",{points:"20 6 9 17 4 12"})})},Pu=function(e){var t=e.className;return(0,v.jsxs)("svg",{viewBox:"0 0 24 24",className:(0,w.cn)("w-4 h-4",t),fill:"none",stroke:"currentColor",strokeWidth:"2.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,v.jsx)("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),(0,v.jsx)("line",{x1:"5",y1:"12",x2:"19",y2:"12"})]})},Pc=function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=Pa(g.useState(!1),2),r=t[0],n=t[1],a=g.useRef(null),i=g.useRef(null),o=g.useRef(null),s=function(t){if(!e&&a.current&&i.current){n(!0),null==(r=o.current)||r.cancel();var r,s=a.current.getBoundingClientRect(),l=Math.max(s.width,s.height),u=Math.max(.35*l,75),c=Math.floor(.2*l),d=Math.sqrt(Math.pow(s.width,2)+Math.pow(s.height,2)),f=Math.min(Math.max(400,1.5*d),1e3),p={x:(s.width-c)/2,y:(s.height-c)/2},h=p;t&&"clientX"in t&&(h={x:t.clientX-s.left-c/2,y:t.clientY-s.top-c/2}),i.current.style.width="".concat(c,"px"),i.current.style.height="".concat(c,"px"),o.current=i.current.animate([{transform:"translate(".concat(h.x,"px, ").concat(h.y,"px) scale(1)")},{transform:"translate(".concat(p.x,"px, ").concat(p.y,"px) scale(").concat((d+10+u)/c,")")}],{duration:f,easing:"cubic-bezier(0.2, 0, 0, 1)",fill:"forwards"})}},l=function(){var e;return(e=function(){var e;return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(t){switch(t.label){case 0:if(!((e=o.current)&&"number"==typeof e.currentTime&&e.currentTime<300))return[3,2];return[4,new Promise(function(t){return setTimeout(t,300-e.currentTime)})];case 1:t.sent(),t.label=2;case 2:return n(!1),[2]}})},function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){E9(i,n,a,o,s,"next",e)}function s(e){E9(i,n,a,o,s,"throw",e)}o(void 0)})})()};return{surfaceRef:a,rippleRef:i,pressed:r,events:{onPointerDown:function(e){0===e.button&&s(e)},onPointerUp:l,onPointerLeave:l,onPointerCancel:l}}},Pd=g.forwardRef(function(e,t){var r=e.pressed,n=e.rippleRef;return(0,v.jsxs)("div",{ref:t,className:"absolute inset-0 overflow-hidden rounded-[inherit] pointer-events-none z-0",children:[(0,v.jsx)("div",{className:"absolute inset-0 bg-current opacity-0 transition-opacity duration-200 group-hover/m3item:opacity-[0.08] group-data-[active=true]:opacity-[0.08]"}),(0,v.jsx)("div",{ref:n,className:"absolute rounded-full opacity-0 bg-current",style:{background:"radial-gradient(closest-side, currentColor max(calc(100% - 70px), 65%), transparent 100%)",transition:"opacity 375ms linear",opacity:r?"0.12":"0",transitionDuration:r?"100ms":"375ms"}})]})});Pd.displayName="RippleLayer";var Pf=g.forwardRef(function(e,t){var r=Pi([e,t]),n=r[0],a=r.slice(1),i=n.children,o=n.className,s=n.viewportRef,l=Pn(n,["children","className","viewportRef"]),u=Pa(a,1)[0],c=g.useRef(null),d=s||c,f=g.useRef(null),p=g.useRef(null),h=Pa(g.useState(0),2),m=h[0],y=h[1],b=Pa(g.useState(0),2),x=b[0],S=b[1],j=Pa(g.useState(!1),2),O=j[0],k=j[1],E=g.useRef({startY:0,startScrollTop:0}),P=g.useCallback(function(){if(d.current){var e=d.current,t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;if(f.current&&(f.current.style.opacity=t>0?"1":"0"),p.current&&(p.current.style.opacity=Math.ceil(t+n)>=r-1?"0":"1"),r>n){var a=Math.max(n/r*n,30);y(a),S((n-a)/(r-n)*t)}else y(0)}},[d]);return g.useEffect(function(){var e=d.current;if(e){P();var t=new ResizeObserver(function(){return P()});t.observe(e),e.firstElementChild&&t.observe(e.firstElementChild);var r=new MutationObserver(function(){return P()});return r.observe(e,{childList:!0,subtree:!0,characterData:!0}),function(){t.disconnect(),r.disconnect()}}},[P,d]),g.useEffect(function(){if(O){var e=function(e){if(d.current){var t=e.clientY-E.current.startY,r=d.current,n=r.scrollHeight,a=r.clientHeight,i=Math.max(a/n*a,30);d.current.scrollTop=E.current.startScrollTop+(n-a)/(a-i)*t}},t=function(){k(!1),document.body.style.userSelect=""};return window.addEventListener("pointermove",e),window.addEventListener("pointerup",t),function(){window.removeEventListener("pointermove",e),window.removeEventListener("pointerup",t)}}},[O,d]),(0,v.jsxs)("div",Pr(Pt({ref:u,"data-dragging":O,className:(0,w.cn)("relative overflow-hidden group/scroll",o)},l),{children:[(0,v.jsx)("div",{ref:f,className:"absolute top-0 left-0 right-0 h-6 bg-gradient-to-b from-card to-transparent pointer-events-none z-20 transition-opacity duration-300 opacity-0"}),(0,v.jsx)("div",{ref:d,onScroll:P,style:{maxHeight:"inherit"},className:"w-full overflow-y-auto m3-hide-scroll rounded-[inherit]",children:i}),(0,v.jsx)("div",{ref:p,className:"absolute bottom-0 left-0 right-0 h-6 bg-gradient-to-t from-card to-transparent pointer-events-none z-20 transition-opacity duration-300 opacity-0"}),m>0&&(0,v.jsx)("div",{className:(0,w.cn)("absolute inset-y-0 right-0 z-50 flex items-start justify-end py-0.5 px-0.5 w-4 transition-opacity duration-300 cursor-default","opacity-0 pointer-events-none","group-hover/scroll:opacity-100 group-hover/scroll:pointer-events-auto","group-data-[dragging=true]/scroll:opacity-100 group-data-[dragging=true]/scroll:pointer-events-auto"),children:(0,v.jsx)("div",{className:(0,w.cn)("bg-border rounded-full transition-all duration-200 cursor-default touch-none shadow-sm","w-1 hover:w-1.5 hover:bg-muted-foreground","group-data-[dragging=true]/scroll:w-1.5 group-data-[dragging=true]/scroll:bg-muted-foreground"),style:{height:m,transform:"translateY(".concat(x,"px)")},onPointerDown:function(e){var t;e.preventDefault(),e.stopPropagation(),k(!0),E.current={startY:e.clientY,startScrollTop:(null==(t=d.current)?void 0:t.scrollTop)||0},document.body.style.userSelect="none"}})})]}))});Pf.displayName="CustomFloatingScrollArea";var Pp=function(){return(0,v.jsx)("style",{dangerouslySetInnerHTML:{__html:'\n @keyframes m3-auto-item-cinematic { \n 0% { opacity: 0; transform: translateY(8px) scale(0.98); filter: blur(4px); } \n 100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); } \n }\n \n @keyframes m3-chip-enter { \n 0% { opacity: 0; transform: scale(0.8) translate3d(8px, 0, 0); } \n 100% { opacity: 1; transform: scale(1) translate3d(0, 0, 0); } \n }\n\n .m3-chip-animate {\n animation: m3-chip-enter 200ms cubic-bezier(0.2, 0.8, 0.2, 1) forwards;\n }\n \n .m3-auto-container[data-state="open"] .m3-auto-item { \n opacity: 0; \n animation: m3-auto-item-cinematic 350ms cubic-bezier(0.1, 0.8, 0.2, 1) forwards; \n }\n\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(1) { animation-delay: 50ms; }\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(2) { animation-delay: 100ms; }\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(3) { animation-delay: 150ms; }\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(4) { animation-delay: 200ms; }\n .m3-auto-container[data-state="open"] .m3-auto-item:nth-child(n+5) { animation-delay: 250ms; }\n\n .m3-hide-scroll {\n scrollbar-width: none;\n -ms-overflow-style: none;\n }\n .m3-hide-scroll::-webkit-scrollbar {\n display: none;\n }\n '}})},Ph=g.forwardRef(function(e,t){var r=Pi([e,t]),n=r[0],a=r.slice(1),i=n.className,o=n.children,s=n.isActive,l=n.isSelected,u=n.onSelectAction,c=Pn(n,["className","children","isActive","isSelected","onSelectAction"]),d=Pa(a,1)[0],f=Pc(),p=f.surfaceRef,h=f.rippleRef,m=f.pressed,y=f.events;return(0,v.jsxs)("li",Pr(Pt({ref:function(e){p.current=e,"function"==typeof d?d(e):d&&(d.current=e)},role:"option","aria-selected":l,"data-active":s,className:(0,w.cn)("m3-auto-item group/m3item relative flex items-center p-3 px-4 cursor-pointer text-sm outline-none transition-colors overflow-hidden",s&&"bg-secondary/50 text-secondary-foreground",i),onMouseDown:function(e){e.preventDefault()},onClick:function(){setTimeout(function(){return u()},150)}},y,c),{children:[(0,v.jsx)(Pd,{rippleRef:h,pressed:m}),(0,v.jsx)("span",{className:"relative z-10 flex w-full items-center pointer-events-none",children:o})]}))});function Pm(e){var t=e.items,r=e.placeholder,n=e.emptyMessage,a=e.value,i=e.onValueChange,o=e.disabled,s=e.isCreatable,l=e.onCreate,u=e.className,c=e.onInputChange,d=e.loading,f=e.filterFn,p=e.debounceInterval,h=void 0===p?0:p,m=e.name,y=e.id,b=e.required,x=e["aria-label"],S=e["aria-labelledby"],j=e.maxOptions,O=e.minOptions,k=e.classNames,E=e.labels,P=e.renderItem,A=e.maxListHeight,D=void 0===A?260:A,C=e.chipMaxWidth,T=void 0===C?120:C,N=e.style,R=Array.isArray(a),M=null!=(eE=null==E?void 0:E.empty)?eE:void 0===n?"No results found.":n,I=null!=(eP=null==E?void 0:E.loading)?eP:"Loading results...",L=null!=(eA=null==E?void 0:E.clear)?eA:"Clear",F=null!=(eD=null==E?void 0:E.toggle)?eD:"Toggle options",B=null!=(eC=null==E?void 0:E.create)?eC:function(e){return'Create "'.concat(e,'"')},V=g.useId(),z=y?"".concat(y,"-listbox"):"".concat(V,"-listbox"),W=function(e){return"".concat(z,"-option-").concat(e)},$=Pa(g.useState(function(){if(a){var e;return Array.isArray(a)?"":(null==(e=t.find(function(e){return e.value===a}))?void 0:e.label)||""}return""}),2),U=$[0],H=$[1],G=Pa(g.useState(U),2),K=G[0],q=G[1],Y=Pa(g.useState(!1),2),X=Y[0],Z=Y[1],Q=Pa(g.useState("closed"),2),J=Q[0],ee=Q[1],et=Pa(g.useState(-1),2),er=et[0],en=et[1],ea=g.useRef("mouse"),ei=Pa(g.useState("bottom"),2),eo=ei[0],es=ei[1],el=Pa(g.useState(D),2),eu=el[0],ec=el[1],ed=g.useRef(null),ef=g.useRef(null),ep=g.useRef(null),eh=g.useRef(null),em=g.useRef(null),ey=g.useRef(null),ev=g.useRef(null),eg=g.useRef(null),eb=g.useRef(null),ex=Pa(g.useState(a),2),ew=ex[0],eS=ex[1],ej=Pa(g.useState(t),2),eO=ej[0],ek=ej[1];if(a!==ew||t!==eO)if(eS(a),ek(t),R)a&&0!==a.length||(H(""),q(""));else if(a){var eE,eP,eA,eD,eC,eT,eN=(null==(eT=t.find(function(e){return e.value===a}))?void 0:eT.label)||"";H(eN),q(eN)}else H(""),q("");var eR=Pc(o),eM=eR.surfaceRef,eI=eR.rippleRef,e_=eR.pressed,eL=eR.events,eF=Pc(o),eB=eF.surfaceRef,eV=eF.rippleRef,ez=eF.pressed,eW=eF.events,e$=g.useMemo(function(){return!1===f||null===f?t:f?t.filter(function(e){return f(e,K)}):K?t.filter(function(e){return e.label.toLowerCase().includes(K.toLowerCase())}):t},[t,K,f]),eU=Pa(g.useState(e$),2),eH=eU[0],eG=eU[1];g.useEffect(function(){"open"===J&&eG(e$)},[e$,J]);var eK=g.useCallback(function(){if(ef.current){var e=ef.current.getBoundingClientRect(),t=window.innerHeight-e.bottom,r=e.top,n=t<280&&r>t?"top":"bottom";es(n),ec(Math.max(100,Math.min(D,("bottom"===n?t:r)-16)))}},[D]);g.useEffect(function(){var e=ef.current;if(e){var t=new ResizeObserver(function(){eK()});return t.observe(e),e.parentElement&&t.observe(e.parentElement),window.addEventListener("resize",eK),function(){t.disconnect(),window.removeEventListener("resize",eK)}}},[eK]),g.useEffect(function(){if(X)return window.addEventListener("scroll",eK,{capture:!0,passive:!0}),function(){window.removeEventListener("scroll",eK,!0)}},[X,eK]);var eq=g.useCallback(function(e){H(e),eb.current&&clearTimeout(eb.current),h&&h>0?eb.current=setTimeout(function(){q(e),c&&c(e)},h):(q(e),c&&c(e))},[h,c]),eY=g.useCallback(function(e){if(Z(!0),ee("open"),eg.current&&clearTimeout(eg.current),"number"==typeof e)en(e);else{var t=e$.findIndex(function(e){return e.value===a});en(t>=0?t:-1)}},[e$,a]),eX=g.useCallback(function(){if(Z(!1),ee("closing"),en(-1),R)H(""),q("");else if(a){var e,r=(null==(e=t.find(function(e){return e.value===a}))?void 0:e.label)||"";H(r),q(r)}else H(""),q("");eg.current&&clearTimeout(eg.current),eg.current=setTimeout(function(){ee(function(e){return"closing"===e?"closed":e})},300)},[a,t,R]);g.useEffect(function(){return function(){eg.current&&clearTimeout(eg.current),eb.current&&clearTimeout(eb.current)}},[]),g.useEffect(function(){var e=function(e){ef.current&&!ef.current.contains(e.target)&&X&&eX()};return document.addEventListener("mousedown",e),function(){return document.removeEventListener("mousedown",e)}},[X,eX]),g.useEffect(function(){if(er>=0&&ep.current&&"keyboard"===ea.current){var e=ep.current.children[er];e&&e.scrollIntoView({block:"nearest"})}},[er]);var eZ=g.useCallback(function(){var e=em.current;if(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;ey.current&&(ey.current.style.opacity=t>1?"1":"0"),ev.current&&(ev.current.style.opacity=Math.ceil(t+n)>=r-1?"0":"1")}},[]),eQ=g.useRef(0);g.useEffect(function(){if(R){var e=em.current;if(e){var t=(null==a?void 0:a.length)||0;t>eQ.current&&requestAnimationFrame(function(){e.scrollLeft=e.scrollWidth}),eQ.current=t}}},[a,R]),g.useEffect(function(){var e,t,r=em.current;if(r){var n=!1,a=function(a){n=!0,e=a.pageX-r.offsetLeft,t=r.scrollLeft,document.body.style.userSelect="none"},i=function(){n&&(n=!1,document.body.style.userSelect="")},o=function(a){if(n){a.preventDefault();var i=(a.pageX-r.offsetLeft-e)*1.5;r.scrollLeft=t-i}},s=function(e){0!==e.deltaY&&(e.preventDefault(),r.scrollLeft+=e.deltaY)};r.addEventListener("mousedown",a),r.addEventListener("mouseleave",i),r.addEventListener("mouseup",i),r.addEventListener("mousemove",o),r.addEventListener("wheel",s,{passive:!1}),eZ(),r.addEventListener("scroll",eZ);var l=new ResizeObserver(function(){return eZ()});return l.observe(r),function(){r.removeEventListener("mousedown",a),r.removeEventListener("mouseleave",i),r.removeEventListener("mouseup",i),r.removeEventListener("mousemove",o),r.removeEventListener("wheel",s),r.removeEventListener("scroll",eZ),l.disconnect(),document.body.style.userSelect=""}}},[X,a,eZ]);var eJ=void 0!==s&&s&&U.length>0&&!t.some(function(e){return e.label.toLowerCase()===U.toLowerCase()}),e0=function(e){var r;if(R){var n,o,s=a||[];if(s.includes(e)){if("number"==typeof O&&s.length<=O){null==(n=ed.current)||n.focus();return}var l=s.filter(function(t){return t!==e});i&&i(l)}else{if("number"==typeof j&&s.length>=j){null==(o=ed.current)||o.focus();return}var u=((function(e){if(Array.isArray(e))return E6(e)})(s)||E7(s)||Po(s)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e]);i&&i(u)}H(""),q(""),c&&c("")}else{if(a===e)H(""),q(""),i&&i("");else{var d,f=(null==(d=t.find(function(t){return t.value===e}))?void 0:d.label)||"";H(f),q(f),i&&i(e)}eX()}null==(r=ed.current)||r.focus()},e1=function(){var e;l&&U&&l(U),R||eX(),null==(e=ed.current)||e.focus()},e2=U.length>0?"x":X?"up":"down",e3="closing"===J?eH:e$,e4=R&&(a||[]).length>0,e5=g.useCallback(function(e){if(!R)return!1;var t=a||[];return!t.includes(e)&&"number"==typeof j&&!!(t.length>=j)},[R,a,j]),e6=X||"closing"===J;return(0,v.jsxs)("div",{ref:ef,style:N,className:(0,w.cn)("relative w-full transition-all duration-300 ease-[cubic-bezier(0.2,0.8,0.2,1)]",e4?"h-[5.25rem]":"h-11",u,null==k?void 0:k.root),children:[(0,v.jsx)(Pp,{}),m&&(R?(a||[]).length>0?(a||[]).map(function(e){return(0,v.jsx)("input",{type:"hidden",name:m,value:e},e)}):(0,v.jsx)("input",{type:"hidden",name:m,value:"",required:b}):(0,v.jsx)("input",{type:"hidden",name:m,value:a||"",required:b})),(0,v.jsxs)("div",{"data-state":J,className:(0,w.cn)("m3-auto-container absolute inset-x-0 flex bg-card overflow-hidden transition-all duration-300 ease-[cubic-bezier(0.2,0.8,0.2,1)]","top"===eo?"bottom-0 flex-col-reverse":"top-0 flex-col",e6?"z-50 rounded-[1.25rem] border border-border shadow-[0px_16px_32px_rgba(0,0,0,0.14)]":"z-10 rounded-xl border border-input/60 shadow-sm hover:border-input h-full",null==k?void 0:k.container),children:[(0,v.jsxs)("div",{className:(0,w.cn)("relative flex items-center w-full h-11 flex-shrink-0 pl-4 pr-1.5 z-30",null==k?void 0:k.inputRow),children:[(0,v.jsx)("input",{ref:ed,id:y,role:"combobox","aria-expanded":X,"aria-autocomplete":"list","aria-controls":z,"aria-activedescendant":er>=0?W(er):void 0,"aria-label":x,"aria-labelledby":S,value:U,onChange:function(e){var t=e.target.value;eq(t);var r=t.length>0?0:-1;X?en(r):eY(r),ea.current="keyboard"},onFocus:function(){return eY()},onKeyDown:function(e){var t=e$.length+ +!!eJ;if("Tab"===e.key){X&&eX();return}if(!X&&("ArrowDown"===e.key||"ArrowUp"===e.key)){e.preventDefault(),eY();return}if(0!==t)switch(e.key){case"ArrowDown":e.preventDefault(),ea.current="keyboard",en(function(e){return(e+1)%t});break;case"ArrowUp":e.preventDefault(),ea.current="keyboard",en(function(e){return(e-1+t)%t});break;case"Home":e.preventDefault(),ea.current="keyboard",en(0);break;case"End":e.preventDefault(),ea.current="keyboard",en(t-1);break;case"Enter":if(e.preventDefault(),er>=0)if(er<e$.length){var r=e$[er],n=R&&a||[],i=n.includes(r.value);R&&!i&&"number"==typeof j&&n.length>=j||e0(r.value)}else eJ&&e1();break;case"Escape":eX()}},disabled:o,placeholder:r||"Select an option...",autoComplete:"off",className:(0,w.cn)("flex-1 h-full bg-transparent outline-none text-sm placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",null==k?void 0:k.input)}),(0,v.jsxs)("button",Pr(Pt({ref:eM,type:"button",tabIndex:-1,className:(0,w.cn)("p-1.5 rounded-full z-20 hover:bg-muted/50 transition-all relative overflow-hidden h-8 w-8 flex items-center justify-center flex-shrink-0",null==k?void 0:k.toggleButton),onClick:function(e){var t;e.preventDefault(),null==(t=ed.current)||t.focus(),U.length>0?(eq(""),!R&&i&&i(""),X||eY(-1)):X?eX():eY()},disabled:o,"aria-label":F},eL),{children:[(0,v.jsx)(Pd,{rippleRef:eI,pressed:e_}),(0,v.jsx)("span",{className:"relative z-10 flex items-center justify-center pointer-events-none",children:(0,v.jsx)(Ps,{state:e2})})]}))]}),R&&(a||[]).length>0&&(0,v.jsxs)("div",{className:(0,w.cn)("relative flex items-center justify-between h-10 overflow-hidden flex-shrink-0 border-border/40","top"===eo?"border-b":"border-t",null==k?void 0:k.chipsRow),children:[(0,v.jsx)("div",{ref:ey,className:"absolute left-0 top-0 bottom-0 w-8 bg-gradient-to-r from-card to-transparent pointer-events-none z-20 transition-opacity duration-150 opacity-0"}),(0,v.jsx)("div",{ref:em,className:"flex items-center gap-1.5 overflow-x-auto m3-hide-scroll flex-1 min-w-0 h-full py-0.5 pl-4 pr-12 select-none cursor-default",children:(a||[]).map(function(e){var r=t.find(function(t){return t.value===e});return r?(0,v.jsxs)("button",{type:"button",className:(0,w.cn)("m3-chip-animate group/chip relative flex items-center h-6 px-3 bg-secondary text-secondary-foreground text-xs font-medium rounded-full flex-shrink-0 transition-all duration-300 ease-[cubic-bezier(0.2,0.8,0.2,1)] overflow-hidden cursor-default select-none",null==k?void 0:k.chip),onClick:function(){var t,r=a||[];if("number"!=typeof O||!(r.length<=O)){var n=r.filter(function(t){return t!==e});i&&i(n),null==(t=ed.current)||t.focus()}},children:[(0,v.jsx)("span",{className:"truncate",style:{maxWidth:T},children:r.label}),(0,v.jsx)("div",{className:"absolute inset-y-0 right-0 w-8 flex items-center justify-end pr-2 bg-gradient-to-l from-secondary via-secondary/90 to-transparent opacity-0 translate-x-2 group-hover/chip:opacity-100 group-hover/chip:translate-x-0 transition-all duration-150 pointer-events-none",children:(0,v.jsxs)("svg",{viewBox:"0 0 24 24",className:"w-3 h-3 stroke-current text-muted-foreground",fill:"none",strokeWidth:"3.5",strokeLinecap:"round",strokeLinejoin:"round",children:[(0,v.jsx)("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),(0,v.jsx)("line",{x1:"6",y1:"6",x2:"18",y2:"18"})]})})]},e):null})}),(0,v.jsx)("div",{ref:ev,className:"absolute right-[60px] top-0 bottom-0 w-12 bg-gradient-to-l from-card to-transparent pointer-events-none z-20 transition-opacity duration-150 opacity-0"}),(!O||0===O)&&(0,v.jsxs)("button",Pr(Pt({ref:eB,type:"button",onClick:function(){var e;i&&i([]),null==(e=ed.current)||e.focus()},className:(0,w.cn)("px-3 h-8 rounded-full text-[10px] font-bold uppercase tracking-wider text-muted-foreground hover:bg-muted/50 transition-all relative overflow-hidden flex-shrink-0 flex items-center justify-center mr-1.5 cursor-default z-30",null==k?void 0:k.clearButton)},eW),{children:[(0,v.jsx)(Pd,{rippleRef:eV,pressed:ez}),(0,v.jsx)("span",{className:"relative",children:L})]}))]}),(0,v.jsx)("div",{className:(0,w.cn)("grid transition-[grid-template-rows,opacity] duration-300 ease-[cubic-bezier(0.2,0.8,0.2,1)] relative z-10",X?"grid-rows-[1fr] opacity-100":"grid-rows-[0fr] opacity-0"),onMouseDown:function(e){e.preventDefault()},children:(0,v.jsx)("div",{className:"overflow-hidden",children:"closed"!==J&&(0,v.jsx)("div",{className:"flex flex-col w-full",children:(0,v.jsx)(Pf,{viewportRef:eh,style:{maxHeight:"".concat(eu,"px")},className:"w-full",children:(0,v.jsx)("ul",{ref:ep,id:z,role:"listbox","aria-multiselectable":R,className:(0,w.cn)("w-full text-popover-foreground outline-none pb-2 pt-1",null==k?void 0:k.list),children:void 0!==d&&d?(0,v.jsxs)("li",{className:(0,w.cn)("m3-auto-item p-6 flex flex-col items-center justify-center gap-2 text-xs text-muted-foreground",null==k?void 0:k.loadingState),children:[(0,v.jsxs)("svg",{className:"animate-spin h-5 w-5 text-primary",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",children:[(0,v.jsx)("circle",{className:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"3.5"}),(0,v.jsx)("path",{className:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"})]}),(0,v.jsx)("span",{className:"font-medium tracking-wide",children:I})]}):0!==e3.length||eJ?(0,v.jsxs)(v.Fragment,{children:[e3.map(function(e,t){var r=e5(e.value),n=R?!!(null==a?void 0:a.includes(e.value)):a===e.value,i=er===t;return(0,v.jsxs)(Ph,{id:W(t),isActive:i,isSelected:n,onSelectAction:function(){r||e0(e.value)},onMouseMove:function(e){(0!==e.movementX||0!==e.movementY)&&(ea.current="mouse",er!==t&&en(t))},className:(0,w.cn)(r&&"opacity-40 cursor-not-allowed pointer-events-none",null==k?void 0:k.item),children:[n&&(0,v.jsx)(Pl,{className:"mr-3 flex-shrink-0 text-primary"}),P?P(e,{isActive:i,isSelected:n,isDisabled:r}):(0,v.jsxs)("div",{className:"flex flex-col w-full",children:[(0,v.jsx)("span",{className:"whitespace-normal break-words font-medium",children:e.label}),(e.description||e.tag)&&(0,v.jsxs)("div",{className:"flex justify-between items-center text-[11px] font-medium text-muted-foreground/70 w-full mt-0.5 gap-4",children:[(0,v.jsx)("span",{className:"truncate uppercase tracking-wider",children:e.description}),(0,v.jsx)("span",{className:"truncate",children:e.tag})]})]})]},e.value)}),eJ&&(0,v.jsxs)(Ph,{id:W(e$.length),isActive:er===e$.length,isSelected:!1,onSelectAction:e1,onMouseMove:function(e){(0!==e.movementX||0!==e.movementY)&&(ea.current="mouse",er!==e$.length&&en(e$.length))},className:(0,w.cn)("text-primary/90 font-medium border-t border-border/40",null==k?void 0:k.item),children:[(0,v.jsx)(Pu,{className:"mr-3 flex-shrink-0"}),(0,v.jsx)("span",{children:B(U)})]})]}):(0,v.jsx)("li",{className:(0,w.cn)("m3-auto-item p-4 px-4 text-sm text-center text-muted-foreground",null==k?void 0:k.emptyState),children:M})})})})})})]})]})}function Py(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Pv(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||Pb(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Pg(e){return function(e){if(Array.isArray(e))return Py(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Pb(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Pb(e,t){if(e){if("string"==typeof e)return Py(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Py(e,t)}}Ph.displayName="M3AutocompleteItem";var Px=function(e,t){var r,n=t.trim().toLowerCase();return!n||[e.label,e.value,e.description].concat(Pg(null!=(r=e.keywords)?r:[])).filter(Boolean).some(function(e){return String(e).toLowerCase().includes(n)})};function Pw(e){var t,r,n=e.items,a=e.value,i=e.defaultValue,o=e.onValueChange,s=e.open,l=e.defaultOpen,u=e.onOpenChange,c=e.disabled,d=e.placeholder,f=e.searchPlaceholder,p=e.emptyMessage,h=e.searchable,m=e.allowDeselect,y=void 0===m||m,b=e.closeOnSelect,x=void 0===b||b,S=e.filterFn,j=e.onSearchChange,O=e.side,k=void 0===O?"auto":O,E=e.align,P=void 0===E?"center":E,A=e.sideOffset,D=void 0===A?4:A,C=e.renderItem,T=e.renderValue,N=e.triggerIcon,R=e.checkIcon,M=e.name,I=e.id,L=e["aria-label"],F=e.classNames,B=e.className,V=e.style,z=g.useId(),W="".concat(z,"-listbox"),$=function(e){return"".concat(z,"-option-").concat(e)},U=void 0!==a,H=Pv(g.useState(void 0===i?"":i),2),G=H[0],K=H[1],q=U?a:G,Y=void 0!==s,X=Pv(g.useState(void 0!==l&&l),2),Z=X[0],Q=X[1],J=Y?s:Z,ee=g.useCallback(function(e){Y||Q(e),null==u||u(e)},[Y,u]),et=Pv(g.useState(""),2),er=et[0],en=et[1],ea=Pv(g.useState(0),2),ei=ea[0],eo=ea[1],es=Pv(g.useState("bottom"),2),el=es[0],eu=es[1],ec=g.useRef("mouse"),ed=g.useRef(null),ef=g.useRef(null),ep=g.useRef(null),eh=g.useRef(null),em=g.useMemo(function(){return n.find(function(e){return e.value===q})},[n,q]),ey=g.useMemo(function(){if(!1===S)return n;var e=null!=S?S:Px;return n.filter(function(t){return e(t,er)})},[n,er,S]),ev=g.useCallback(function(e){var t,r=y&&e===q?"":e;U||K(r),null==o||o(r),x&&(ee(!1),null==(t=ef.current)||t.focus())},[y,q,U,o,x,ee]);g.useEffect(function(){if(!J)return void en("");var e=ey.findIndex(function(e){return e.value===q&&!e.disabled});eo(e>=0?e:Math.max(0,ey.findIndex(function(e){return!e.disabled})));var t=requestAnimationFrame(function(){var e;return null==(e=ep.current)?void 0:e.focus()});return function(){return cancelAnimationFrame(t)}},[J]),g.useLayoutEffect(function(){if(J&&ed.current){if("auto"!==k)return void eu(k);var e=ed.current.getBoundingClientRect(),t=window.innerHeight-e.bottom,r=e.top;eu(t<340&&r>t?"top":"bottom")}},[J,k]),g.useEffect(function(){if(J){var e=function(e){ed.current&&!ed.current.contains(e.target)&&ee(!1)};return document.addEventListener("mousedown",e),function(){return document.removeEventListener("mousedown",e)}}},[J,ee]),g.useEffect(function(){J&&eo(Math.max(0,ey.findIndex(function(e){return!e.disabled})))},[er]),g.useEffect(function(){var e,t;J&&"keyboard"===ec.current&&(null==(t=eh.current)||null==(e=t.querySelector('[data-index="'.concat(ei,'"]')))||e.scrollIntoView({block:"nearest"}))},[ei,J]);var eg=function(e,t){var r=ey.length;if(0===r)return -1;for(var n=t,a=0;a<r;a++)if(!ey[n=(n+e+r)%r].disabled)return n;return t},eb=(0,w.cn)("bottom"===el?"top-full":"bottom-full","start"===P&&"left-0","center"===P&&"left-1/2","end"===P&&"right-0"),ex=(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},"bottom"===el?{marginTop:D}:{marginBottom:D}),r=r={"--egen-combobox-to":"center"===P?"translateX(-50%)":"translateX(0)","--egen-combobox-from-bottom":"".concat("center"===P?"translateX(-50%) ":"","translateY(-8px)"),"--egen-combobox-from-top":"".concat("center"===P?"translateX(-50%) ":"","translateY(8px)"),transform:"center"===P?"translateX(-50%)":"none"},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t),ew=[];ey.forEach(function(e,t){var r=ew[ew.length-1];r&&r.heading===e.group?r.entries.push({item:e,index:t}):ew.push({heading:e.group,entries:[{item:e,index:t}]})});var eS=function(e){var t=e.item,r=e.index,n=q===t.value,a=ei===r;return(0,v.jsxs)("div",{id:$(r),role:"option","data-index":r,"data-selected":a,"data-disabled":t.disabled?"true":void 0,"aria-selected":n,"aria-disabled":t.disabled||void 0,onMouseMove:function(){t.disabled||(ec.current="mouse",ei!==r&&eo(r))},onClick:function(){return!t.disabled&&ev(t.value)},className:(0,w.cn)("relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none","data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50","data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground","[&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",null==F?void 0:F.item),children:[C?C(t,{isActive:a,isSelected:n}):(0,v.jsxs)(v.Fragment,{children:[t.icon,t.description?(0,v.jsxs)("span",{className:"flex min-w-0 flex-col",children:[(0,v.jsx)("span",{className:"truncate",children:t.label}),(0,v.jsx)("span",{className:"truncate text-xs text-muted-foreground",children:t.description})]}):t.label]}),R&&n?(0,v.jsx)("span",{className:(0,w.cn)("ml-auto",null==F?void 0:F.itemCheck),children:R}):(0,v.jsx)(E$,{className:(0,w.cn)("ml-auto",n?"opacity-100":"opacity-0",null==F?void 0:F.itemCheck)})]},t.value)};return(0,v.jsxs)("div",{ref:ed,style:V,className:(0,w.cn)("relative w-full max-w-xs",B,null==F?void 0:F.root),children:[(0,v.jsx)("style",{dangerouslySetInnerHTML:{__html:'\n@keyframes egen-combobox-in-bottom { from { opacity: 0; transform: var(--egen-combobox-from-bottom) scale(0.95); } to { opacity: 1; transform: var(--egen-combobox-to) scale(1); } }\n@keyframes egen-combobox-in-top { from { opacity: 0; transform: var(--egen-combobox-from-top) scale(0.95); } to { opacity: 1; transform: var(--egen-combobox-to) scale(1); } }\n.egen-combobox-content[data-side="bottom"] { animation: egen-combobox-in-bottom 150ms cubic-bezier(0.16, 1, 0.3, 1); }\n.egen-combobox-content[data-side="top"] { animation: egen-combobox-in-top 150ms cubic-bezier(0.16, 1, 0.3, 1); }\n@media (prefers-reduced-motion: reduce) { .egen-combobox-content { animation: none !important; } }\n'}}),M?(0,v.jsx)("input",{type:"hidden",name:M,value:q}):null,(0,v.jsxs)("button",{ref:ef,id:I,type:"button",role:"combobox","aria-expanded":J,"aria-haspopup":"listbox","aria-controls":J?W:void 0,"aria-label":L,disabled:void 0!==c&&c,onClick:function(){return ee(!J)},onKeyDown:function(e){J||"ArrowDown"!==e.key&&"ArrowUp"!==e.key||(e.preventDefault(),ee(!0))},className:(0,w.cn)("inline-flex h-9 w-full shrink-0 items-center justify-between gap-2 rounded-md border border-border bg-background px-4 py-2 text-sm font-medium whitespace-nowrap text-foreground shadow-xs transition-all outline-none","hover:bg-accent hover:text-accent-foreground","focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50","disabled:pointer-events-none disabled:opacity-50",null==F?void 0:F.trigger),children:[(0,v.jsx)("span",{className:"min-w-0 truncate",children:T?T(em):em?em.label:void 0===d?"Select...":d}),null!=N?N:(0,v.jsx)(EU,{className:"size-4 shrink-0 opacity-50"})]}),J?(0,v.jsx)("div",{"data-side":el,"data-state":"open",style:ex,className:(0,w.cn)("egen-combobox-content absolute z-50 w-72 rounded-md border border-border bg-popover p-0 text-popover-foreground shadow-md outline-hidden",eb,null==F?void 0:F.content),onKeyDown:function(e){if("Escape"===e.key){var t;e.preventDefault(),ee(!1),null==(t=ef.current)||t.focus();return}if("Tab"===e.key)return void ee(!1);if(0!==ey.length)switch(e.key){case"ArrowDown":e.preventDefault(),ec.current="keyboard",eo(function(e){return eg(1,e)});break;case"ArrowUp":e.preventDefault(),ec.current="keyboard",eo(function(e){return eg(-1,e)});break;case"Home":e.preventDefault(),ec.current="keyboard",eo(Math.max(0,ey.findIndex(function(e){return!e.disabled})));break;case"End":e.preventDefault(),ec.current="keyboard";var r=Pg(ey).reverse().findIndex(function(e){return!e.disabled});eo(r>=0?ey.length-1-r:0);break;case"Enter":e.preventDefault();var n=ey[ei];n&&!n.disabled&&ev(n.value)}},children:(0,v.jsxs)("div",{className:"flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",children:[void 0===h||h?(0,v.jsxs)("div",{className:(0,w.cn)("flex h-9 items-center gap-2 border-b border-border px-3",null==F?void 0:F.searchWrapper),children:[(0,v.jsx)(EH,{className:(0,w.cn)("size-4 shrink-0 opacity-50",null==F?void 0:F.searchIcon)}),(0,v.jsx)("input",{ref:ep,type:"text",role:"searchbox",autoComplete:"off",spellCheck:!1,"aria-controls":W,"aria-activedescendant":ey.length?$(ei):void 0,placeholder:void 0===f?"Search...":f,value:er,onChange:function(e){en(e.target.value),ec.current="keyboard",null==j||j(e.target.value)},className:(0,w.cn)("flex h-9 w-full rounded-md bg-transparent py-3 text-sm outline-hidden placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",null==F?void 0:F.searchInput)})]}):(0,v.jsx)("input",{ref:ep,readOnly:!0,"aria-label":L,"aria-controls":W,"aria-activedescendant":ey.length?$(ei):void 0,className:"sr-only"}),(0,v.jsx)("div",{ref:eh,id:W,role:"listbox",className:(0,w.cn)("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",null==F?void 0:F.list),children:0===ey.length?(0,v.jsx)("div",{className:(0,w.cn)("py-6 text-center text-sm",null==F?void 0:F.empty),children:void 0===p?"No results found.":p}):ew.map(function(e,t){var r;return(0,v.jsxs)("div",{role:"group","aria-label":e.heading,className:(0,w.cn)("overflow-hidden p-1 text-foreground",null==F?void 0:F.group),children:[e.heading?(0,v.jsx)("div",{className:(0,w.cn)("px-2 py-1.5 text-xs font-medium text-muted-foreground",null==F?void 0:F.groupHeading),children:e.heading}):null,e.entries.map(eS)]},"".concat(null!=(r=e.heading)?r:"_","-").concat(t))})})]})}):null]})}function PS(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Pj(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function PO(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function Pk(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function PE(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||PA(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function PP(e){return function(e){if(Array.isArray(e))return Pj(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||PA(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function PA(e,t){if(e){if("string"==typeof e)return Pj(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Pj(e,t)}}var PD=function(e){return void 0===e||""===e?[]:Array.isArray(e)?e:[e]},PC=function(e){var t;return Array.isArray(e)?{items:e,hasMore:!1}:{items:null!=(t=e.items)?t:[],hasMore:!!e.hasMore}},PT=function(e){return"number"==typeof e?"".concat(e,"px"):e};function PN(e){var t,r,n,a,i,o,s,l,u,c,d=e.fetcher,f=e.getOptionValue,p=e.getOptionLabel,h=e.renderOption,m=e.getDisplayValue,y=e.getOptionGroup,b=e.getOptionDisabled,x=e.preload,S=void 0!==x&&x,j=e.filterFn,O=e.debounceMs,k=e.minQueryLength,E=void 0===k?0:k,P=e.fetchOnOpen,A=e.cacheResults,D=void 0===A||A,C=e.reloadKey,T=e.initialOptions,N=e.resolveOption,R=e.open,M=e.defaultOpen,I=e.onOpenChange,L=e.disabled,F=void 0!==L&&L,B=e.name,V=e.id,z=e["aria-label"],W=e.label,$=e.placeholder,U=void 0===$?"Select...":$,H=e.searchPlaceholder,G=e.noResultsMessage,K=e.minQueryMessage,q=e.loadingMessage,Y=e.retryLabel,X=e.clearLabel,Z=e.removeLabel,Q=void 0===Z?function(e){return"Remove ".concat(e)}:Z,J=e.errorMessage,ee=void 0===J?"Failed to fetch options":J,et=e.loadMoreErrorLabel,er=e.searchable,en=e.clearable,ea=void 0===en||en,ei=e.showClearButton,eo=e.closeOnSelect,es=e.width,el=e.contentWidth,eu=void 0===el?"trigger":el,ec=e.side,ed=void 0===ec?"auto":ec,ef=e.align,ep=void 0===ef?"start":ef,eh=e.sideOffset,em=void 0===eh?4:eh,ey=e.maxListHeight,ev=void 0===ey?300:ey,eg=e.loadingSkeleton,eb=e.loadingIndicator,ex=e.notFound,ew=e.renderError,eS=e.header,ej=e.footer,eO=e.triggerIcon,ek=e.checkIcon,eE=e.controllerRef,eP=e.classNames,eA=e.className,eD=e.triggerClassName,eC=e.style,eT=!0===e.multiple,eN=!0===e.multiple?e.maxSelected:void 0,eR=!0===e.multiple&&null!=(u=e.maxVisibleTags)?u:3,eM=!0===e.multiple?e.renderTag:void 0,eI=null!=eo?eo:!eT,e_=g.useId(),eL="".concat(e_,"-listbox"),eF=function(e){return"".concat(e_,"-option-").concat(e)},eB=g.useCallback(function(e){return p?p(e):f(e)},[p,f]),eV=void 0!==e.value,ez=PE(g.useState(function(){return PD(e.defaultValue)}),2),eW=ez[0],e$=ez[1],eU=eV?PD(e.value):eW,eH=void 0!==R,eG=PE(g.useState(void 0!==M&&M),2),eK=eG[0],eq=eG[1],eY=eH?R:eK,eX=g.useCallback(function(e){eH||eq(e),null==I||I(e)},[eH,I]),eZ=g.useRef(new Map),eQ=g.useRef(new Set),eJ=PE(g.useReducer(function(e){return e+1},0),2)[1];g.useMemo(function(){null==T||T.forEach(function(e){return eZ.current.set(f(e),e)})},[T]);var e0=g.useRef(N);e0.current=N;var e1=eU.join("\0");g.useEffect(function(){var e=e0.current;if(e){var t=!1;return eU.forEach(function(r){eZ.current.has(r)||eQ.current.has(r)||(eQ.current.add(r),Promise.resolve(e(r)).then(function(e){t||void 0===e||(eZ.current.set(r,e),eJ())}).catch(function(){}))}),function(){t=!0}}},[e1]);var e2=PE(g.useState(""),2),e3=e2[0],e4=e2[1],e5=(t=S?"":e3,r=S?0:void 0===O?300:O,i=(a=function(e){if(Array.isArray(e))return e}(n=g.useState(t))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(n)||function(e){if(e){if("string"==typeof e)return PS(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return PS(e,2)}}(n)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())[0],o=a[1],g.useEffect(function(){if(!(r<=0)){var e=setTimeout(function(){return o(t)},r);return function(){return clearTimeout(e)}}},[t,r]),r<=0?t:i),e6=e5.trim(),e8=!S&&e6.length>0&&e6.length<E,e9=PE(g.useState([]),2),e7=e9[0],te=e9[1],tt=PE(g.useState("idle"),2),tr=tt[0],tn=tt[1],ta=PE(g.useState(null),2),ti=ta[0],to=ta[1],ts=PE(g.useState(!1),2),tl=ts[0],tu=ts[1],tc=PE(g.useState(!1),2),td=tc[0],tf=tc[1],tp=PE(g.useState(!1),2),th=tp[0],tm=tp[1],ty=PE(g.useState(0),2),tv=ty[0],tg=ty[1],tb=g.useRef(d);tb.current=d;var tx=g.useRef(f);tx.current=f;var tw=g.useRef(new Map),tS=g.useRef(0),tj=g.useRef(0),tO=g.useRef(null),tk=(eY||!(void 0===P||P))&&!e8,tE="".concat(null!=C?C:"","\0").concat(tv,"\0").concat(""===e6?"":e5),tP=g.useCallback(function(e){e.forEach(function(e){return eZ.current.set(tx.current(e),e)})},[]);g.useEffect(function(){if(tk){var e,t=D?tw.current.get(tE):void 0;if(t){te(t.items),tu(t.hasMore),tm(!1),tj.current=t.page,to(null),tn("ready");return}null==(e=tO.current)||e.abort();var r=new AbortController,n=++tS.current;return tn("loading"),to(null),tm(!1),Promise.resolve().then(function(){return tb.current(""===e6?"":e5,{signal:r.signal,page:0})}).then(function(e){if(!r.signal.aborted&&n===tS.current){var t=PC(e);tP(t.items),D&&tw.current.set(tE,{items:t.items,hasMore:t.hasMore,page:0}),tj.current=0,te(t.items),tu(t.hasMore),tn("ready"),eJ()}}).catch(function(e){if(!r.signal.aborted&&n===tS.current){var t;to((null!=(t=Error)&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t)&&e.message?e.message:ee),tn("error")}}),function(){return r.abort()}}},[tk,tE,D]);var tA=g.useCallback(function(){tw.current.delete(tE),tg(function(e){return e+1})},[tE]),tD=g.useCallback(function(){var e;return(e=function(){var e,t,r,n,a;return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(i){switch(i.label){case 0:if("ready"!==tr||!tl||td)return[2];e=tS.current,t=tj.current+1,tO.current=r=new AbortController,tf(!0),tm(!1),i.label=1;case 1:return i.trys.push([1,3,4,5]),[4,tb.current(""===e6?"":e5,{signal:r.signal,page:t})];case 2:if(n=i.sent(),r.signal.aborted||e!==tS.current)return[2];return tP((a=PC(n)).items),te(function(e){var r=new Set(e.map(function(e){return tx.current(e)})),n=PP(e).concat(PP(a.items.filter(function(e){return!r.has(tx.current(e))})));return D&&tw.current.set(tE,{items:n,hasMore:a.hasMore,page:t}),n}),tj.current=t,tu(a.hasMore),[3,5];case 3:return i.sent(),r.signal.aborted||e!==tS.current||tm(!0),[3,5];case 4:return tO.current===r&&(tO.current=null,tf(!1)),[7];case 5:return[2]}})},function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){PO(i,n,a,o,s,"next",e)}function s(e){PO(i,n,a,o,s,"throw",e)}o(void 0)})})()},[tr,tl,td,e6,e5,tP,D,tE]);g.useEffect(function(){return function(){var e;tS.current+=1,null==(e=tO.current)||e.abort()}},[]);var tC=g.useMemo(function(){return!1===j?null:j||(S?function(e,t){var r=t.trim().toLowerCase();return!r||eB(e).toLowerCase().includes(r)}:null)},[j,S,eB]),tT=g.useMemo(function(){return tC&&e3?e7.filter(function(e){return tC(e,e3)}):e7},[e7,tC,e3]),tN=eU.map(function(e){return eZ.current.get(e)}),tR=eT&&void 0!==eN&&eU.length>=eN,tM=function(e){return!!(null==b?void 0:b(e))||tR&&!eU.includes(f(e))},tI=function(t){var r,n,a;eV||e$(t),!0===e.multiple?null==(r=e.onChange)||r.call(e,t,t.map(function(e){return eZ.current.get(e)}).filter(function(e){return void 0!==e})):null==(a=e.onChange)||a.call(e,null!=(n=t[0])?n:"",void 0!==t[0]?eZ.current.get(t[0]):void 0)},t_=g.useRef(null),tL=g.useRef(null),tF=g.useRef(null),tB=g.useRef(null),tV=g.useRef(null),tz=function(e){var t,r=f(e);if(eZ.current.set(r,e),eT){var n=eU.includes(r);if(!n&&tR)return;tI(n?eU.filter(function(e){return e!==r}):PP(eU).concat([r]))}else tI(ea&&eU[0]===r?[]:[r]);eI&&(eX(!1),null==(t=t_.current)||t.focus())},tW=function(e){return tI(eU.filter(function(t){return t!==e}))},t$=function(){return tI([])};g.useImperativeHandle(eE,function(){return{open:function(){return!F&&eX(!0)},close:function(){return eX(!1)},focus:function(){var e;return null==(e=t_.current)?void 0:e.focus()},clear:t$,refresh:function(){tw.current.clear(),tg(function(e){return e+1})}}},[F,eX,eU,eV]);var tU=PE(g.useState(0),2),tH=tU[0],tG=tU[1],tK=PE(g.useState("bottom"),2),tq=tK[0],tY=tK[1],tX=g.useRef("mouse"),tZ=function(){return Math.max(0,tT.findIndex(function(e){return!tM(e)}))};g.useEffect(function(){if(!eY)return void e4("");var e=requestAnimationFrame(function(){var e;return null==(e=tF.current)?void 0:e.focus()});return function(){return cancelAnimationFrame(e)}},[eY]),g.useEffect(function(){if(eY){var e=eT||void 0===eU[0]?-1:tT.findIndex(function(e){return f(e)===eU[0]&&!tM(e)});tG(e>=0?e:tZ())}},[eY,e3,tr]),g.useLayoutEffect(function(){if(eY&&tL.current){if("auto"!==ed)return void tY(ed);var e=tL.current.getBoundingClientRect(),t=window.innerHeight-e.bottom,r=e.top;tY(t<Math.min(ev,300)+48&&r>t?"top":"bottom")}},[eY,ed,ev]),g.useEffect(function(){if(eY){var e=function(e){tL.current&&!tL.current.contains(e.target)&&eX(!1)};return document.addEventListener("mousedown",e),function(){return document.removeEventListener("mousedown",e)}}},[eY,eX]),g.useEffect(function(){var e,t,r;eY&&"keyboard"===tX.current&&(null==(r=tB.current)||null==(t=r.querySelector('[data-index="'.concat(tH,'"]')))||null==(e=t.scrollIntoView)||e.call(t,{block:"nearest"}))},[tH,eY]),g.useEffect(function(){if(!(!eY||!tl||"ready"!==tr||th||"u"<typeof IntersectionObserver)){var e=tV.current;if(e){var t=new IntersectionObserver(function(e){e.some(function(e){return e.isIntersecting})&&tD()},{root:tB.current,rootMargin:"48px"});return t.observe(e),function(){return t.disconnect()}}}},[eY,tl,tr,th,tD,tT.length]);var tQ=function(e,t){var r=tT.length;if(0===r)return -1;for(var n=t,a=0;a<r;a++)if(!tM(tT[n=(n+e+r)%r]))return n;return t},tJ=(0,w.cn)("bottom"===tq?"top-full":"bottom-full","start"===ep&&"left-0","center"===ep&&"left-1/2","end"===ep&&"right-0"),t0=(s=Pk({width:"trigger"===eu?"100%":PT(eu)},"bottom"===tq?{marginTop:em}:{marginBottom:em}),l=l={"--egen-async-select-to":"center"===ep?"translateX(-50%)":"translateX(0)","--egen-async-select-from-bottom":"".concat("center"===ep?"translateX(-50%) ":"","translateY(-8px)"),"--egen-async-select-from-top":"".concat("center"===ep?"translateX(-50%) ":"","translateY(8px)"),transform:"center"===ep?"translateX(-50%)":"none"},Object.getOwnPropertyDescriptors?Object.defineProperties(s,Object.getOwnPropertyDescriptors(l)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(l)).forEach(function(e){Object.defineProperty(s,e,Object.getOwnPropertyDescriptor(l,e))}),s),t1=[];tT.forEach(function(e,t){var r=null==y?void 0:y(e),n=t1[t1.length-1];n&&n.heading===r?n.entries.push({item:e,index:t}):t1.push({heading:r,entries:[{item:e,index:t}]})});var t2=function(e){var t=e.item,r=e.index,n=f(t),a=eU.includes(n),i=tH===r,o=tM(t);return(0,v.jsxs)("div",{id:eF(r),role:"option","data-index":r,"data-selected":i,"data-disabled":o?"true":void 0,"aria-selected":a,"aria-disabled":o||void 0,onMouseMove:function(){o||(tX.current="mouse",tH!==r&&tG(r))},onClick:function(){return!o&&tz(t)},className:(0,w.cn)("relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none","data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50","data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground","[&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",null==eP?void 0:eP.item),children:[h?h(t,{isActive:i,isSelected:a,isDisabled:o}):eB(t),ek&&a?(0,v.jsx)("span",{className:(0,w.cn)("ml-auto",null==eP?void 0:eP.itemCheck),children:ek}):(0,v.jsx)(E$,{className:(0,w.cn)("ml-auto size-3",a?"opacity-100":"opacity-0",null==eP?void 0:eP.itemCheck)})]},n)},t3=function(e,t){return void 0!==t?eB(t):e},t4=eU.length>0,t5=null!=H?H:"Search ".concat(W.toLowerCase(),"..."),t6=null!=G?G:"No ".concat(W.toLowerCase()," found."),t8="loading"===tr;return(0,v.jsxs)("div",{ref:tL,style:Pk({width:PT(void 0===es?"200px":es)},eC),className:(0,w.cn)("relative",eA,null==eP?void 0:eP.root),children:[(0,v.jsx)("style",{dangerouslySetInnerHTML:{__html:'\n@keyframes egen-async-select-in-bottom { from { opacity: 0; transform: var(--egen-async-select-from-bottom) scale(0.95); } to { opacity: 1; transform: var(--egen-async-select-to) scale(1); } }\n@keyframes egen-async-select-in-top { from { opacity: 0; transform: var(--egen-async-select-from-top) scale(0.95); } to { opacity: 1; transform: var(--egen-async-select-to) scale(1); } }\n.egen-async-select-content[data-side="bottom"] { animation: egen-async-select-in-bottom 150ms cubic-bezier(0.16, 1, 0.3, 1); }\n.egen-async-select-content[data-side="top"] { animation: egen-async-select-in-top 150ms cubic-bezier(0.16, 1, 0.3, 1); }\n@media (prefers-reduced-motion: reduce) { .egen-async-select-content { animation: none !important; } }\n'}}),B?eT?eU.map(function(e){return(0,v.jsx)("input",{type:"hidden",name:B,value:e},e)}):(0,v.jsx)("input",{type:"hidden",name:B,value:null!=(c=eU[0])?c:""}):null,(0,v.jsx)("span",{role:"status","aria-live":"polite",className:"sr-only",children:t8?void 0===q?"Loading...":q:""}),(0,v.jsxs)("div",{ref:t_,id:V,role:"combobox",tabIndex:F?-1:0,"aria-expanded":eY,"aria-haspopup":"listbox","aria-controls":eY?eL:void 0,"aria-label":null!=z?z:W,"aria-disabled":F||void 0,"aria-busy":t8||void 0,"data-disabled":F?"true":void 0,"data-state":eY?"open":"closed",onClick:function(){return!F&&eX(!eY)},onKeyDown:function(e){!F&&(eY||"ArrowDown"!==e.key&&"ArrowUp"!==e.key&&"Enter"!==e.key&&" "!==e.key?!eY&&eT&&"Backspace"===e.key&&t4&&tW(eU[eU.length-1]):(e.preventDefault(),eX(!0)))},className:(0,w.cn)("flex min-h-9 w-full shrink-0 cursor-pointer items-center justify-between gap-2 rounded-md border border-border bg-background px-3 py-1.5 text-sm font-medium text-foreground shadow-xs transition-all outline-none","hover:bg-accent hover:text-accent-foreground","focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50","data-[disabled=true]:pointer-events-none data-[disabled=true]:cursor-not-allowed data-[disabled=true]:opacity-50",eD,null==eP?void 0:eP.trigger),children:[(0,v.jsx)("span",{className:(0,w.cn)("flex min-w-0 flex-1 items-center",null==eP?void 0:eP.triggerValue),children:function(){if(!t4)return(0,v.jsx)("span",{className:(0,w.cn)("truncate text-muted-foreground",null==eP?void 0:eP.placeholder),children:U});if(!eT){var e=tN[0];return(0,v.jsx)("span",{className:"min-w-0 truncate",children:void 0!==e?m?m(e):eB(e):eU[0]})}var t=eU.slice(0,Math.max(0,eR)),r=eU.slice(t.length);return(0,v.jsxs)("span",{className:"flex min-w-0 flex-wrap items-center gap-1",children:[t.map(function(e){var t=eZ.current.get(e),r=t3(e,t);return(0,v.jsxs)("span",{className:(0,w.cn)("inline-flex max-w-full items-center gap-1 rounded-sm bg-muted px-1.5 py-0.5 text-xs font-medium text-foreground",null==eP?void 0:eP.tag),children:[(0,v.jsx)("span",{className:"truncate",children:eM?eM(t,e):r}),F?null:(0,v.jsx)("button",{type:"button",tabIndex:-1,"aria-label":Q(r),onMouseDown:function(e){return e.preventDefault()},onClick:function(t){t.stopPropagation(),tW(e)},className:(0,w.cn)("rounded-sm opacity-60 outline-none transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-ring/50",null==eP?void 0:eP.tagRemove),children:(0,v.jsx)(EG,{className:"size-3"})})]},e)}),r.length>0?(0,v.jsxs)("span",{title:r.map(function(e){return t3(e,eZ.current.get(e))}).join(", "),className:(0,w.cn)("rounded-sm bg-muted px-1.5 py-0.5 text-xs font-medium text-muted-foreground",null==eP?void 0:eP.tag),children:["+",r.length]}):null]})}()}),void 0!==ei&&ei&&t4&&!F?(0,v.jsx)("button",{type:"button",tabIndex:-1,"aria-label":void 0===X?"Clear":X,onMouseDown:function(e){return e.preventDefault()},onClick:function(e){e.stopPropagation(),t$()},className:(0,w.cn)("shrink-0 rounded-sm opacity-50 outline-none transition-opacity hover:opacity-100 focus-visible:ring-2 focus-visible:ring-ring/50",null==eP?void 0:eP.clearButton),children:(0,v.jsx)(EG,{className:"size-4"})}):null,null!=eO?eO:(0,v.jsx)(EU,{className:(0,w.cn)("size-3 shrink-0 opacity-50",null==eP?void 0:eP.triggerIcon)})]}),eY?(0,v.jsx)("div",{"data-side":tq,"data-state":"open",style:t0,className:(0,w.cn)("egen-async-select-content absolute z-50 rounded-md border border-border bg-popover p-0 text-popover-foreground shadow-md outline-hidden",tJ,null==eP?void 0:eP.content),onKeyDown:function(e){if("Escape"===e.key){var t;e.preventDefault(),eX(!1),null==(t=t_.current)||t.focus();return}if("Tab"===e.key)return void eX(!1);if("Backspace"===e.key&&eT&&""===e3&&eU.length>0)return void tW(eU[eU.length-1]);if(0!==tT.length)switch(e.key){case"ArrowDown":e.preventDefault(),tX.current="keyboard",tG(function(e){return tQ(1,e)});break;case"ArrowUp":e.preventDefault(),tX.current="keyboard",tG(function(e){return tQ(-1,e)});break;case"Home":e.preventDefault(),tX.current="keyboard",tG(tZ());break;case"End":e.preventDefault(),tX.current="keyboard";var r=PP(tT).reverse().findIndex(function(e){return!tM(e)});tG(r>=0?tT.length-1-r:0);break;case"Enter":e.preventDefault();var n=tT[tH];n&&!tM(n)&&tz(n)}},children:(0,v.jsxs)("div",{className:"flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",children:[eS?(0,v.jsx)("div",{className:null==eP?void 0:eP.header,children:eS}):null,void 0===er||er?(0,v.jsxs)("div",{className:(0,w.cn)("relative flex h-9 items-center gap-2 border-b border-border px-3",null==eP?void 0:eP.searchWrapper),children:[(0,v.jsx)(EH,{className:(0,w.cn)("size-4 shrink-0 opacity-50",null==eP?void 0:eP.searchIcon)}),(0,v.jsx)("input",{ref:tF,type:"text",role:"searchbox",autoComplete:"off",spellCheck:!1,"aria-controls":eL,"aria-activedescendant":tT.length?eF(tH):void 0,placeholder:t5,value:e3,onChange:function(e){e4(e.target.value),tX.current="keyboard"},className:(0,w.cn)("flex h-9 w-full rounded-md bg-transparent py-3 text-sm outline-hidden placeholder:text-muted-foreground disabled:cursor-not-allowed disabled:opacity-50",null==eP?void 0:eP.searchInput)}),t8&&tT.length>0?(0,v.jsx)("span",{className:(0,w.cn)("flex shrink-0 items-center text-muted-foreground",null==eP?void 0:eP.searchSpinner),"aria-hidden":!0,children:null!=eb?eb:(0,v.jsx)(EK,{className:"size-4 animate-spin"})}):null]}):(0,v.jsx)("input",{ref:tF,readOnly:!0,"aria-label":null!=z?z:W,"aria-controls":eL,"aria-activedescendant":tT.length?eF(tH):void 0,className:"sr-only"}),(0,v.jsxs)("div",{ref:tB,id:eL,role:"listbox","aria-multiselectable":eT||void 0,"aria-busy":t8||void 0,style:{maxHeight:ev},className:(0,w.cn)("scroll-py-1 overflow-x-hidden overflow-y-auto",null==eP?void 0:eP.list),children:[e8?(0,v.jsx)("div",{className:(0,w.cn)("py-6 text-center text-sm text-muted-foreground",null==eP?void 0:eP.hint),children:null!=K?K:"Type at least ".concat(E," characters to search.")}):"error"===tr?ew?ew(null!=ti?ti:ee,tA):(0,v.jsxs)("div",{role:"alert",className:(0,w.cn)("flex flex-col items-center gap-2 p-4 text-center text-sm text-destructive",null==eP?void 0:eP.error),children:[(0,v.jsx)("span",{children:null!=ti?ti:ee}),(0,v.jsx)("button",{type:"button",onClick:tA,className:"rounded-md border border-border px-2 py-1 text-xs font-medium text-foreground outline-none hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring/50",children:void 0===Y?"Retry":Y})]}):(t8||"idle"===tr)&&0===tT.length?null!=eg?eg:(0,v.jsx)("div",{className:(0,w.cn)("p-1",null==eP?void 0:eP.skeleton),"aria-hidden":!0,children:[1,2,3].map(function(e){return(0,v.jsxs)("div",{className:"flex items-center gap-2 rounded-sm px-2 py-1.5",children:[(0,v.jsx)("div",{className:"size-6 animate-pulse rounded-full bg-muted"}),(0,v.jsxs)("div",{className:"flex flex-1 flex-col gap-1",children:[(0,v.jsx)("div",{className:"h-4 w-24 animate-pulse rounded bg-muted"}),(0,v.jsx)("div",{className:"h-3 w-16 animate-pulse rounded bg-muted"})]})]},e)})}):0===tT.length?null!=ex?ex:(0,v.jsx)("div",{className:(0,w.cn)("py-6 text-center text-sm",null==eP?void 0:eP.empty),children:t6}):t1.map(function(e,t){var r;return(0,v.jsxs)("div",{role:"group","aria-label":e.heading,className:(0,w.cn)("overflow-hidden p-1 text-foreground",null==eP?void 0:eP.group),children:[e.heading?(0,v.jsx)("div",{className:(0,w.cn)("px-2 py-1.5 text-xs font-medium text-muted-foreground",null==eP?void 0:eP.groupHeading),children:e.heading}):null,e.entries.map(t2)]},"".concat(null!=(r=e.heading)?r:"_","-").concat(t))}),tl&&"ready"===tr?(0,v.jsx)("div",{ref:tV,className:(0,w.cn)("flex items-center justify-center p-2 text-xs text-muted-foreground",null==eP?void 0:eP.loadMore),children:th?(0,v.jsx)("button",{type:"button",onClick:function(){tD()},className:"rounded-md px-2 py-1 text-destructive outline-none hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring/50",children:void 0===et?"Failed to load more. Retry":et}):td?null!=eb?eb:(0,v.jsx)(EK,{className:"size-4 animate-spin"}):null}):null]}),ej?(0,v.jsx)("div",{className:null==eP?void 0:eP.footer,children:ej}):null]})}):null]})}function PR(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function PM(e,t){if(e){if("string"==typeof e)return PR(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return PR(e,t)}}var PI=function(e){var t,r=e.images,n=e.cardWidth,a=void 0===n?256:n,i=e.cardHeight,o=void 0===i?352:i,s=e.className,l=e.style,u=e.getAlt,c=e.onSwipe,d=(0,g.useRef)(null),f=(0,g.useRef)(!1),p=(0,g.useRef)(0),h=(0,g.useRef)(0),m=(0,g.useRef)(null),y=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(function(){return Array.from({length:r.length},function(e,t){return t})}))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||PM(t,2)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),b=y[0],x=y[1];(0,g.useEffect)(function(){x(Array.from({length:r.length},function(e,t){return t}))},[r.length]);var w=(0,g.useCallback)(function(e,t){var r,n,a=null==(n=getComputedStyle(t||document.documentElement))||null==(r=n.getPropertyValue(e))?void 0:r.trim();return a?a.endsWith("ms")?parseFloat(a):a.endsWith("s")?1e3*parseFloat(a):parseFloat(a)||0:0},[]),S=(0,g.useCallback)(function(){return d.current?Array.from(d.current.querySelectorAll("[data-image-swiper-card]")):[]},[]),j=(0,g.useCallback)(function(){return S()[0]||null},[S]),k=(0,g.useCallback)(function(){S().forEach(function(e,t){e.style.setProperty("--i",(t+1).toString()),e.style.setProperty("--swipe-x","0px"),e.style.setProperty("--swipe-rotate","0deg"),e.style.opacity="1"})},[S]),E=(0,g.useCallback)(function(e){var t=j();t&&(t.style.setProperty("--swipe-x","".concat(e,"px")),t.style.setProperty("--swipe-rotate","".concat(.2*e,"deg")),t.style.opacity=(1-.75*Math.min(Math.abs(e)/100,1)).toString())},[j]),P=(0,g.useCallback)(function(e){if(!f.current){f.current=!0,p.current=e,h.current=e;var t=j();t&&(t.style.transition="none")}},[j]),A=(0,g.useCallback)(function(){if(f.current){m.current&&(cancelAnimationFrame(m.current),m.current=null);var e=h.current-p.current,t=w("--card-swap-duration",d.current),r=j();if(r)if(r.style.transition="transform ".concat(t,"ms ease, opacity ").concat(t,"ms ease"),Math.abs(e)>50){var n=Math.sign(e);r.style.setProperty("--swipe-x","".concat(300*n,"px")),r.style.setProperty("--swipe-rotate","".concat(20*n,"deg")),setTimeout(function(){j()===r&&r.style.setProperty("--swipe-rotate","".concat(-(20*n),"deg"))},.5*t),setTimeout(function(){x(function(e){var t;return 0===e.length?[]:(null==c||c(e[0],n>0?"right":"left"),((function(e){if(Array.isArray(e))return PR(e)})(t=e.slice(1))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||PM(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e[0]]))})},t)}else E(0);f.current=!1,p.current=0,h.current=0}},[w,j,E,c]),D=(0,g.useCallback)(function(e){f.current&&(m.current&&cancelAnimationFrame(m.current),m.current=requestAnimationFrame(function(){h.current=e;var t=h.current-p.current;E(t),Math.abs(t)>50&&A()}))},[E,A]);return(0,g.useEffect)(function(){var e=d.current;if(e){var t=function(e){return P(e.clientX)},r=function(e){return D(e.clientX)},n=function(){return A()};return e.addEventListener("pointerdown",t),e.addEventListener("pointermove",r),e.addEventListener("pointerup",n),function(){e.removeEventListener("pointerdown",t),e.removeEventListener("pointermove",r),e.removeEventListener("pointerup",n),m.current&&cancelAnimationFrame(m.current)}}},[P,D,A]),(0,g.useEffect)(function(){k()},[b,k]),(0,v.jsx)("section",{ref:d,className:O()("oiNYOqAWLBChaYRaGPIQgg==",s),style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({width:a+32,height:o+32,"--card-perspective":"700px","--card-z-offset":"12px","--card-y-offset":"7px","--card-max-z-index":r.length.toString(),"--card-swap-duration":"0.3s"},l),children:b.map(function(e,t){return(0,v.jsx)("article",{"data-image-swiper-card":!0,className:"laGBYFIn9rzvzoUcL9r5sg==",style:{"--i":(t+1).toString(),zIndex:r.length-t,width:a,height:o},children:(0,v.jsx)("img",{src:r[e],alt:u?u(e):"Image ".concat(e+1),className:"_989KfEmfVaUsIl2Vply+DA==",draggable:!1})},"".concat(r[e],"-").concat(e))})})},P_=/[achlmqstvz]|(-?\d*\.?\d*(?:e[\-+]?\d+)?)[0-9]/ig,PL=/(?:(-)?\d*\.?\d*(?:e[\-+]?\d+)?)[0-9]/ig,PF=/[\+\-]?\d*\.?\d+e[\+\-]?\d+/ig,PB=/(^[#\.][a-z]|[a-y][a-z])/i,PV=Math.PI/180,Pz=180/Math.PI,PW=Math.sin,P$=Math.cos,PU=Math.abs,PH=Math.sqrt,PG=Math.atan2,PK=function(e){return"string"==typeof e},Pq=function(e){return"number"==typeof e},PY={},PX={},PZ=function(e){return Math.round((e+1e8)%1*1e5)/1e5||(e<0?0:1)},PQ=function(e){return Math.round(1e5*e)/1e5||0},PJ=function(e){return Math.round(1e10*e)/1e10||0},P0=function(e){return e.closed=.001>Math.abs(e[0]-e[e.length-2])&&.001>Math.abs(e[1]-e[e.length-1])},P1=function(e,t,r,n){var a=e[t],i=1===n?6:An(a,r,n);if((i||!n)&&i+r+2<a.length)return e.splice(t,0,a.slice(0,r+i+2)),a.splice(0,r+i),1},P2=function(e,t,r){var n=e.length,a=~~(r*n);if(e[a]>t){for(;--a&&e[a]>t;);a<0&&(a=0)}else for(;e[++a]<t&&a<n;);return a<n?a:n-1},P3=function(e,t){var r=e.length;for(t||e.reverse();r--;)e[r].reversed||function(e){var t,r=0;for(e.reverse();r<e.length;r+=2)t=e[r],e[r]=e[r+1],e[r+1]=t;e.reversed=!e.reversed}(e[r])},P4=function(e,t){return t.totalLength=e.totalLength,e.samples?(t.samples=e.samples.slice(0),t.lookup=e.lookup.slice(0),t.minLength=e.minLength,t.resolution=e.resolution):e.totalPoints&&(t.totalPoints=e.totalPoints),t},P5=function(e,t){var r=e.length,n=e[r-1]||[],a=n.length;r&&t[0]===n[a-2]&&t[1]===n[a-1]&&(t=n.concat(t.slice(2)),r--),e[r]=t};function P6(e){var t,r=(e=PK(e)&&PB.test(e)&&document.querySelector(e)||e).getAttribute?e:0;return r&&(e=e.getAttribute("d"))?(r._gsPath||(r._gsPath={}),(t=r._gsPath[e])&&!t._dirty?t:r._gsPath[e]=As(e)):e?PK(e)?As(e):Pq(e[0])?[e]:e:console.warn("Expecting a <path> element or an SVG path data string")}var P8=function(e,t){var r,n=document.createElementNS("http://www.w3.org/2000/svg","path"),a=[].slice.call(e.attributes),i=a.length;for(t=","+t+",";--i>-1;)r=a[i].nodeName.toLowerCase(),0>t.indexOf(","+r+",")&&n.setAttributeNS(null,r,a[i].nodeValue);return n},P9={rect:"rx,ry,x,y,width,height",circle:"r,cx,cy",ellipse:"rx,ry,cx,cy",line:"x1,x2,y1,y2"},P7=function(e,t){for(var r=t?t.split(","):[],n={},a=r.length;--a>-1;)n[r[a]]=+e.getAttribute(r[a])||0;return n};function Ae(e,t,r){var n,a=e[t],i=e[t+2],o=e[t+4];return a+=(i-a)*r,i+=(o-i)*r,a+=(i-a)*r,n=i+(o+(e[t+6]-o)*r-i)*r-a,a=e[t+1],i=e[t+3],o=e[t+5],a+=(i-a)*r,i+=(o-i)*r,a+=(i-a)*r,PQ(PG(i+(o+(e[t+7]-o)*r-i)*r-a,n)*Pz)}function At(e,t,r){var n=Math.max(0,~~(PU((r=void 0===r?1:PJ(r)||0)-(t=PJ(t)||0))-1e-8)),a=function(e){for(var t=[],r=0;r<e.length;r++)t[r]=P4(e[r],e[r].slice(0));return P4(e,t)}(e);if(t>r&&(t=1-t,r=1-r,P3(a),a.totalLength=0),t<0||r<0){var i=Math.abs(~~Math.min(t,r))+1;t+=i,r+=i}a.totalLength||Ar(a);var o,s,l,u,c,d,f,p,h=r>1,m=Aa(a,t,PY,!0),y=Aa(a,r,PX),v=y.segment,g=m.segment,b=y.segIndex,x=m.segIndex,w=y.i,S=m.i,j=x===b,O=w===S&&j;if(h||n){for(o=b<x||j&&w<S||O&&y.t<m.t,P1(a,x,S,m.t)&&(x++,!o&&(b++,O?(y.t=(y.t-m.t)/(1-m.t),w=0):j&&(w-=S))),1e-5>Math.abs(1-(r-t))?b=x-1:!y.t&&b?b--:P1(a,b,w,y.t)&&o&&x++,1===m.t&&(x=(x+1)%a.length),c=[],f=1+(d=a.length)*n,p=x,f+=(d-x+b)%d,u=0;u<f;u++)P5(c,a[p++%d]);a=c}else if(l=1===y.t?6:An(v,w,y.t),t!==r)for(s=An(g,S,O?m.t/y.t:m.t),j&&(l+=s),v.splice(w+l+2),(s||S)&&g.splice(0,S+s),u=a.length;u--;)(u<x||u>b)&&a.splice(u,1);else v.angle=Ae(v,w+l,0),w+=l,m=v[w],y=v[w+1],v.length=v.totalLength=0,v.totalPoints=a.totalPoints=8,v.push(m,y,m,y,m,y,m,y);return a.totalLength=0,a}function Ar(e,t){var r,n,a;for(a=r=n=0;a<e.length;a++)e[a].resolution=~~t||12,r+=function(e,t){t=t||0,e.samples||(e.samples=[],e.lookup=[]);var r,n,a,i,o,s,l,u,c,d,f,p,h,m,y,v,g,b=~~e.resolution||12,x=1/b,w=e.length,S=e[t],j=e[t+1],O=t?t/6*b:0,k=e.samples,E=e.lookup,P=(t?e.minLength:1e8)||1e8,A=k[O+(void 0)*b-1],D=t?k[O-1]:0;for(k.length=E.length=0,n=t+2;n<w;n+=6){if(a=e[n+4]-S,i=e[n+2]-S,o=e[n]-S,u=e[n+5]-j,c=e[n+3]-j,d=e[n+1]-j,s=l=f=p=0,.01>PU(a)&&.01>PU(u)&&PU(o)+PU(d)<.01)e.length>8&&(e.splice(n,6),n-=6,w-=6);else for(r=1;r<=b;r++)h=1-(m=x*r),s=l-(l=(m*m*a+3*h*(m*i+h*o))*m),(v=PH((f=p-(p=(m*m*u+3*h*(m*c+h*d))*m))*f+s*s))<P&&(P=v),D+=v,k[O++]=D;S+=a,j+=u}if(A)for(A-=D;O<k.length;O++)k[O]+=A;if(k.length&&P){if(e.totalLength=g=k[k.length-1]||0,e.minLength=P,g/P<9999)for(r=0,v=y=0;r<g;r+=P)E[v++]=k[y]<r?++y:y}else e.totalLength=k[0]=0;return t?D-k[t/2-1]:D}(e[a]),n+=e[a].length;return e.totalPoints=n,e.totalLength=r,e}function An(e,t,r){if(r<=0||r>=1)return 0;var n=e[t],a=e[t+1],i=e[t+2],o=e[t+3],s=e[t+4],l=e[t+5],u=e[t+6],c=e[t+7],d=n+(i-n)*r,f=i+(s-i)*r,p=a+(o-a)*r,h=o+(l-o)*r,m=d+(f-d)*r,y=p+(h-p)*r,v=s+(u-s)*r,g=l+(c-l)*r;return f+=(v-f)*r,h+=(g-h)*r,e.splice(t+2,4,PQ(d),PQ(p),PQ(m),PQ(y),PQ(m+(f-m)*r),PQ(y+(h-y)*r),PQ(f),PQ(h),PQ(v),PQ(g)),e.samples&&e.samples.splice(t/6*e.resolution|0,0,0,0,0,0,0,0),6}function Aa(e,t,r,n){r=r||{},e.totalLength||Ar(e),(t<0||t>1)&&(t=PZ(t));var a,i,o,s,l,u,c,d=0,f=e[0];if(t)if(1===t)c=1,d=e.length-1,u=(f=e[d]).length-8;else{if(e.length>1){for(o=e.totalLength*t,l=u=0;(l+=e[u++].totalLength)<o;)d=u;t=(o-(s=l-(f=e[d]).totalLength))/(l-s)||0}a=f.samples,i=f.resolution,o=f.totalLength*t,s=(u=f.lookup.length?f.lookup[~~(o/f.minLength)]||0:P2(a,o,t))?a[u-1]:0,(l=a[u])<o&&(s=l,l=a[++u]),c=1/i*((o-s)/(l-s)+u%i),u=6*~~(u/i),n&&1===c&&(u+6<f.length?(u+=6,c=0):d+1<e.length&&(u=c=0,f=e[++d]))}else c=u=d=0,f=e[0];return r.t=c,r.i=u,r.path=e,r.segment=f,r.segIndex=d,r}function Ai(e,t,r,n){var a,i,o,s,l,u,c,d,f,p=e[0],h=n||{};if((t<0||t>1)&&(t=PZ(t)),p.lookup||Ar(e),e.length>1){for(o=e.totalLength*t,l=u=0;(l+=e[u++].totalLength)<o;)p=e[u];t=(o-(s=l-p.totalLength))/(l-s)||0}return a=p.samples,i=p.resolution,o=p.totalLength*t,s=(u=p.lookup.length?p.lookup[t<1?~~(o/p.minLength):p.lookup.length-1]||0:P2(a,o,t))?a[u-1]:0,(l=a[u])<o&&(s=l,l=a[++u]),f=1-(c=1/i*((o-s)/(l-s)+u%i)||0),d=p[u=6*~~(u/i)],h.x=PQ((c*c*(p[u+6]-d)+3*f*(c*(p[u+4]-d)+f*(p[u+2]-d)))*c+d),h.y=PQ((c*c*(p[u+7]-(d=p[u+1]))+3*f*(c*(p[u+5]-d)+f*(p[u+3]-d)))*c+d),r&&(h.angle=p.totalLength?Ae(p,u,c>=1?1-1e-9:c||1e-9):p.angle||0),h}function Ao(e,t,r,n,a,i,o){for(var s,l,u,c,d,f=e.length;--f>-1;)for(u=0,l=(s=e[f]).length;u<l;u+=2)c=s[u],d=s[u+1],s[u]=c*t+d*n+i,s[u+1]=c*r+d*a+o;return e._dirty=1,e}function As(e){var t,r,n,a,i,o,s,l,u,c,d,f,p,h,m,y=(e+"").replace(PF,function(e){var t=+e;return t<1e-4&&t>-1e-4?0:t}).match(P_)||[],v=[],g=0,b=0,x=2/3,w=y.length,S=0,j="ERROR: malformed path: "+e,O=function(e,t,r,n){c=(r-e)/3,d=(n-t)/3,s.push(e+c,t+d,r-c,n-d,r,n)};if(!e||!isNaN(y[0])||isNaN(y[1]))return console.log(j),v;for(t=0;t<w;t++)if(p=i,isNaN(y[t])?o=(i=y[t].toUpperCase())!==y[t]:t--,n=+y[t+1],a=+y[t+2],o&&(n+=g,a+=b),t||(l=n,u=a),"M"===i)s&&(s.length<8?v.length-=1:S+=s.length,P0(s)),g=l=n,b=u=a,s=[n,a],v.push(s),t+=2,i="L";else if("C"===i)s||(s=[0,0]),o||(g=b=0),s.push(n,a,g+ +y[t+3],b+ +y[t+4],g+=+y[t+5],b+=+y[t+6]),t+=6;else if("S"===i)c=g,d=b,("C"===p||"S"===p)&&(c+=g-s[s.length-4],d+=b-s[s.length-3]),o||(g=b=0),s.push(c,d,n,a,g+=+y[t+3],b+=+y[t+4]),t+=4;else if("Q"===i)c=g+(n-g)*x,d=b+(a-b)*x,o||(g=b=0),g+=+y[t+3],b+=+y[t+4],s.push(c,d,g+(n-g)*x,b+(a-b)*x,g,b),t+=4;else if("T"===i)c=g-s[s.length-4],d=b-s[s.length-3],s.push(g+c,b+d,n+(g+1.5*c-n)*x,a+(b+1.5*d-a)*x,g=n,b=a),t+=2;else if("H"===i)O(g,b,g=n,b),t+=1;else if("V"===i)O(g,b,g,b=n+(o?b-g:0)),t+=1;else if("L"===i||"Z"===i)"Z"===i&&(n=l,a=u,s.closed=!0),("L"===i||PU(g-n)>.5||PU(b-a)>.5)&&(O(g,b,n,a),"L"===i&&(t+=2)),g=n,b=a;else if("A"===i){if(h=y[t+4],m=y[t+5],c=y[t+6],d=y[t+7],r=7,h.length>1&&(h.length<3?(d=c,c=m,r--):(d=m,c=h.substr(2),r-=2),m=h.charAt(1),h=h.charAt(0)),f=function(e,t,r,n,a,i,o,s,l){if(e!==s||t!==l){r=PU(r),n=PU(n);var u=a%360*PV,c=P$(u),d=PW(u),f=Math.PI,p=2*f,h=(e-s)/2,m=(t-l)/2,y=c*h+d*m,v=-d*h+c*m,g=y*y,b=v*v,x=g/(r*r)+b/(n*n);x>1&&(r=PH(x)*r,n=PH(x)*n);var w=r*r,S=n*n,j=(w*S-w*b-S*g)/(w*b+S*g);j<0&&(j=0);var O=(i===o?-1:1)*PH(j),k=r*v/n*O,E=-(n*y/r*O),P=(e+s)/2+(c*k-d*E),A=(t+l)/2+(d*k+c*E),D=(y-k)/r,C=(v-E)/n,T=(-y-k)/r,N=(-v-E)/n,R=D*D+C*C,M=(C<0?-1:1)*Math.acos(D/PH(R)),I=(D*N-C*T<0?-1:1)*Math.acos((D*T+C*N)/PH(R*(T*T+N*N)));isNaN(I)&&(I=f),!o&&I>0?I-=p:o&&I<0&&(I+=p),M%=p;var L,F=Math.ceil(PU(I%=p)/(p/4)),B=[],V=I/F,z=4/3*PW(V/2)/(1+P$(V/2)),W=c*r,$=d*r,U=-(d*n),H=c*n;for(L=0;L<F;L++)y=P$(a=M+L*V),v=PW(a),D=P$(a+=V),C=PW(a),B.push(y-z*v,v+z*y,D+z*C,C-z*D,D,C);for(L=0;L<B.length;L+=2)y=B[L],v=B[L+1],B[L]=y*W+v*U+P,B[L+1]=y*$+v*H+A;return B[L-2]=s,B[L-1]=l,B}}(g,b,+y[t+1],+y[t+2],+y[t+3],+h,+m,(o?g:0)+ +c,(o?b:0)+ +d),t+=r,f)for(r=0;r<f.length;r++)s.push(f[r]);g=s[s.length-2],b=s[s.length-1]}else console.log(j);return(t=s.length)<6?(v.pop(),t=0):P0(s),v.totalPoints=S+t,v}function Al(e,t){1e-4>PU(e[0]-e[2])&&1e-4>PU(e[1]-e[3])&&(e=e.slice(2));var r,n,a,i,o,s,l,u,c,d,f,p,h,m,y,v=e.length-2,g=+e[0],b=+e[1],x=+e[2],w=+e[3],S=[g,b,g,b],j=x-g,O=w-b,k=e.nonSmooth||[],E=.001>Math.abs(e[v]-g)&&.001>Math.abs(e[v+1]-b);if(!v)return[g,b,g,b,g,b,g,b];for(E&&(e.push(x,w),x=g,w=b,g=e[v-2],b=e[v-1],e.unshift(g,b),v+=4,k=[0,0].concat(k)),t=t||0===t?+t:1,a=2;a<v;a+=2)if(r=g,n=b,g=x,b=w,x=+e[a+2],w=+e[a+3],g!==x||b!==w){if(i=j,o=O,j=x-g,O=w-b,k[a]){S.push(g-(g-r)/4,b-(b-n)/4,g,b,g+(x-g)/4,b+(w-b)/4);continue}s=PH(i*i+o*o),l=PH(j*j+O*O),u=PH(Math.pow(j/l+i/s,2)+Math.pow(O/l+o/s,2)),c=(s+l)*t*.25/u,d=g-(g-r)*(s?c/s:0),f=g+(x-g)*(l?c/l:0),p=g-(d+((f-d)*(3*s/(s+l)+.5)/4||0)),h=b-(b-n)*(s?c/s:0),m=b+(w-b)*(l?c/l:0),y=b-(h+((m-h)*(3*s/(s+l)+.5)/4||0)),S.push(PQ(d+p),PQ(h+y),PQ(g),PQ(b),PQ(f+p),PQ(m+y))}return g!==x||b!==w||S.length<4?S.push(PQ(x),PQ(w),PQ(x),PQ(w)):S.length-=2,2===S.length?S.push(g,b,g,b,g,b):E&&(S.splice(0,6),S.length-=6),S.closed=E,S}function Au(e){Pq(e[0])&&(e=[e]);var t,r,n,a,i="",o=e.length;for(r=0;r<o;r++){for(i+="M"+PQ((a=e[r])[0])+","+PQ(a[1])+" C",t=a.length,n=2;n<t;n++)i+=PQ(a[n++])+","+PQ(a[n++])+" "+PQ(a[n++])+","+PQ(a[n++])+" "+PQ(a[n++])+","+PQ(a[n])+" ";a.closed&&(i+="z")}return i}var Ac,Ad,Af,Ap,Ah,Am,Ay,Av,Ag,Ab,Ax,Aw="transform",AS=Aw+"Origin",Aj=function(e){var t=e.ownerDocument||e;for(!(Aw in e.style)&&("msTransform"in e.style)&&(AS=(Aw="msTransform")+"Origin");t.parentNode&&(t=t.parentNode););if(Ap=window,Ag=new AR,t){Af=t,Ah=t.documentElement,Am=t.body,(Ab=Af.createElementNS("http://www.w3.org/2000/svg","g")).style.transform="none";var r=t.createElement("div"),n=t.createElement("div"),a=t&&(t.body||t.firstElementChild);a&&a.appendChild&&(a.appendChild(r),r.appendChild(n),r.style.position="static",r.style.transform="translate3d(0,0,1px)",Ax=n.offsetParent!==r,a.removeChild(r))}return t},AO=function(e){for(var t,r;e&&e!==Am;)(r=e._gsap)&&r.uncache&&r.get(e,"x"),r&&!r.scaleX&&!r.scaleY&&r.renderTransform&&(r.scaleX=r.scaleY=1e-4,r.renderTransform(1,r),t?t.push(r):t=[r]),e=e.parentNode;return t},Ak=[],AE=[],AP=function(e){return e.ownerSVGElement||("svg"===(e.tagName+"").toLowerCase()?e:null)},AA=function e(t,r){if(t.parentNode&&(Af||Aj(t))){var n=AP(t),a=n?n.getAttribute("xmlns")||"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",i=n?r?"rect":"g":"div",o=100*(2===r),s=100*(3===r),l={position:"absolute",display:"block",pointerEvents:"none",margin:"0",padding:"0"},u=Af.createElementNS?Af.createElementNS(a.replace(/^https/,"http"),i):Af.createElement(i);return r&&(n?(Av||(Av=e(t)),u.setAttribute("width",.01),u.setAttribute("height",.01),u.setAttribute("transform","translate("+o+","+s+")"),u.setAttribute("fill","transparent"),Av.appendChild(u)):(Ay||Object.assign((Ay=e(t)).style,l),Object.assign(u.style,l,{width:"0.1px",height:"0.1px",top:s+"px",left:o+"px"}),Ay.appendChild(u))),u}throw"Need document and parent."},AD=function(e){for(var t=new AR,r=0;r<e.numberOfItems;r++)t.multiply(e.getItem(r).matrix);return t},AC=function(e){var t,r=e.getCTM();return r||(t=e.style[Aw],e.style[Aw]="none",e.appendChild(Ab),r=Ab.getCTM(),e.removeChild(Ab),t?e.style[Aw]=t:e.style.removeProperty(Aw.replace(/([A-Z])/g,"-$1").toLowerCase())),r||Ag.clone()},AT=function(e,t){var r,n,a,i,o,s,l=AP(e),u=e===l,c=l?Ak:AE,d=e.parentNode,f=d&&!l&&d.shadowRoot&&d.shadowRoot.appendChild?d.shadowRoot:d;if(e===Ap)return e;if(c.length||c.push(AA(e,1),AA(e,2),AA(e,3)),r=l?Av:Ay,l)u?(i=-(a=AC(e)).e/a.a,o=-a.f/a.d,n=Ag):e.getBBox?(a=e.getBBox(),i=(n=(n=e.transform?e.transform.baseVal:{}).numberOfItems?n.numberOfItems>1?AD(n):n.getItem(0).matrix:Ag).a*a.x+n.c*a.y,o=n.b*a.x+n.d*a.y):(n=new AR,i=o=0),t&&"g"===e.tagName.toLowerCase()&&(i=o=0),(u||!e.getBoundingClientRect().width?l:d).appendChild(r),r.setAttribute("transform","matrix("+n.a+","+n.b+","+n.c+","+n.d+","+(n.e+i)+","+(n.f+o)+")");else{if(i=o=0,Ax)for(n=e.offsetParent,a=e;a&&(a=a.parentNode)&&a!==n&&a.parentNode;)(Ap.getComputedStyle(a)[Aw]+"").length>4&&(i=a.offsetLeft,o=a.offsetTop,a=0);if("absolute"!==(s=Ap.getComputedStyle(e)).position&&"fixed"!==s.position)for(n=e.offsetParent;d&&d!==n;)i+=d.scrollLeft||0,o+=d.scrollTop||0,d=d.parentNode;(a=r.style).top=e.offsetTop-o+"px",a.left=e.offsetLeft-i+"px",a[Aw]=s[Aw],a[AS]=s[AS],a.position="fixed"===s.position?"fixed":"absolute",f.appendChild(r)}return r},AN=function(e,t,r,n,a,i,o){return e.a=t,e.b=r,e.c=n,e.d=a,e.e=i,e.f=o,e},AR=function(){function e(e,t,r,n,a,i){void 0===e&&(e=1),void 0===t&&(t=0),void 0===r&&(r=0),void 0===n&&(n=1),void 0===a&&(a=0),void 0===i&&(i=0),AN(this,e,t,r,n,a,i)}var t=e.prototype;return t.inverse=function(){var e=this.a,t=this.b,r=this.c,n=this.d,a=this.e,i=this.f,o=e*n-t*r||1e-10;return AN(this,n/o,-t/o,-r/o,e/o,(r*i-n*a)/o,-(e*i-t*a)/o)},t.multiply=function(e){var t=this.a,r=this.b,n=this.c,a=this.d,i=this.e,o=this.f,s=e.a,l=e.c,u=e.b,c=e.d,d=e.e,f=e.f;return AN(this,s*t+u*n,s*r+u*a,l*t+c*n,l*r+c*a,i+d*t+f*n,o+d*r+f*a)},t.clone=function(){return new e(this.a,this.b,this.c,this.d,this.e,this.f)},t.equals=function(e){var t=this.a,r=this.b,n=this.c,a=this.d,i=this.e,o=this.f;return t===e.a&&r===e.b&&n===e.c&&a===e.d&&i===e.e&&o===e.f},t.apply=function(e,t){void 0===t&&(t={});var r=e.x,n=e.y,a=this.a,i=this.b,o=this.c,s=this.d,l=this.e,u=this.f;return t.x=r*a+n*o+l||0,t.y=r*i+n*s+u||0,t},e}();function AM(e,t,r,n){if(!e||!e.parentNode||(Af||Aj(e)).documentElement===e)return new AR;var a=AO(e),i=AP(e)?Ak:AE,o=AT(e,r),s=i[0].getBoundingClientRect(),l=i[1].getBoundingClientRect(),u=i[2].getBoundingClientRect(),c=o.parentNode,d=!n&&function e(t){return"fixed"===Ap.getComputedStyle(t).position||((t=t.parentNode)&&1===t.nodeType?e(t):void 0)}(e),f=new AR((l.left-s.left)/100,(l.top-s.top)/100,(u.left-s.left)/100,(u.top-s.top)/100,s.left+(d?0:Ap.pageXOffset||Af.scrollLeft||Ah.scrollLeft||Am.scrollLeft||0),s.top+(d?0:Ap.pageYOffset||Af.scrollTop||Ah.scrollTop||Am.scrollTop||0));if(c.removeChild(o),a)for(s=a.length;s--;)(l=a[s]).scaleX=l.scaleY=0,l.renderTransform(1,l);return t?f.inverse():f}var AI,A_,AL,AF,AB,AV,Az="x,translateX,left,marginLeft,xPercent".split(","),AW="y,translateY,top,marginTop,yPercent".split(","),A$=Math.PI/180,AU=function(e,t,r,n){for(var a=t.length,i=2===n?0:n,o=0;o<a;o++)e[i]=parseFloat(t[o][r]),2===n&&(e[i+1]=0),i+=2;return e},AH=function(e,t,r){return parseFloat(e._gsap.get(e,t,r||"px"))||0},AG=function(e){var t,r=e[0],n=e[1];for(t=2;t<e.length;t+=2)r=e[t]+=r,n=e[t+1]+=n},AK=function(e,t,r,n,a,i,o,s,l){return"cubic"===o.type?t=[t]:(!1!==o.fromCurrent&&t.unshift(AH(r,n,s),a?AH(r,a,l):0),o.relative&&AG(t),t=[(a?Al:function(e,t){void 0===t&&(t=1);for(var r=e[0],n=0,a=[r,0],i=2;i<e.length;i+=2)a.push(r,n,e[i],n=(e[i]-r)*t/2,r=e[i],-n);return a})(t,o.curviness)]),t=i(AQ(t,r,o)),AJ(e,r,n,t,"x",s),a&&AJ(e,r,a,t,"y",l),Ar(t,o.resolution||(0===o.curviness?20:12))},Aq=function(e){return e},AY=/[-+\.]*\d+\.?(?:e-|e\+)?\d*/g,AX=function(e,t,r){var n,a=AM(e),i=0,o=0;return"svg"===(e.tagName+"").toLowerCase()?(n=e.viewBox.baseVal).width||(n={width:+e.getAttribute("width"),height:+e.getAttribute("height")}):n=t&&e.getBBox&&e.getBBox(),t&&"auto"!==t&&(i=t.push?t[0]*(n?n.width:e.offsetWidth||0):t.x,o=t.push?t[1]*(n?n.height:e.offsetHeight||0):t.y),r.apply(i||o?a.apply({x:i,y:o}):{x:a.e,y:a.f})},AZ=function(e,t,r,n){var a,i=AM(e.parentNode,!0,!0),o=i.clone().multiply(AM(t)),s=AX(e,r,i),l=AX(t,n,i),u=l.x,c=l.y;return o.e=o.f=0,"auto"===n&&t.getTotalLength&&"path"===t.tagName.toLowerCase()&&(a=t.getAttribute("d").match(AY)||[],u+=(a=o.apply({x:+a[0],y:+a[1]})).x,c+=a.y),a&&(u-=(a=o.apply(t.getBBox())).x,c-=a.y),o.e=u-s.x,o.f=c-s.y,o},AQ=function(e,t,r){var n,a,i,o=r.align,s=r.matrix,l=r.offsetX,u=r.offsetY,c=r.alignOrigin,d=e[0][0],f=e[0][1],p=AH(t,"x"),h=AH(t,"y");return e&&e.length?(o&&("self"===o||(n=AF(o)[0]||t)===t?Ao(e,1,0,0,1,p-d,h-f):(c&&!1!==c[2]?AI.set(t,{transformOrigin:100*c[0]+"% "+100*c[1]+"%"}):c=[-(AH(t,"xPercent")/100),-(AH(t,"yPercent")/100)],i=(a=AZ(t,n,c,"auto")).apply({x:d,y:f}),Ao(e,a.a,a.b,a.c,a.d,p+a.e-(i.x-a.e),h+a.f-(i.y-a.f)))),s?Ao(e,s.a,s.b,s.c,s.d,s.e,s.f):(l||u)&&Ao(e,1,0,0,1,l||0,u||0),e):P6("M0,0L0,0")},AJ=function(e,t,r,n,a,i){var o=t._gsap,s=o.harness,l=s&&s.aliases&&s.aliases[r],u=l&&0>l.indexOf(",")?l:r,c=e._pt=new A_(e._pt,t,u,0,0,Aq,0,o.set(t,u,e));c.u=AL(o.get(t,u,i))||0,c.path=n,c.pp=a,e._props.push(u)},A0={version:"3.15.0",name:"motionPath",register:function(e,t,r){AL=(AI=e).utils.getUnit,AF=AI.utils.toArray,AB=AI.core.getStyleSaver,AV=AI.core.reverting||function(){},A_=r},init:function(e,t,r){if(!AI)return console.warn("Please gsap.registerPlugin(MotionPathPlugin)"),!1;(void 0===t?"undefined":(n=t)&&"u">typeof Symbol&&n.constructor===Symbol?"symbol":typeof n)=="object"&&!t.style&&t.path||(t={path:t});var n,a,i,o,s,l=[],u=t,c=u.path,d=u.autoRotate,f=u.unitX,p=u.unitY,h=u.x,m=u.y,y=c[0],v=(a=t.start,i="end"in t?t.end:1,function(e){return a||1!==i?At(e,a,i):e});if(this.rawPaths=l,this.target=e,this.tween=r,this.styles=AB&&AB(e,"transform"),(this.rotate=d||0===d)&&(this.rOffset=parseFloat(d)||0,this.radians=!!t.useRadians,this.rProp=t.rotation||"rotation",this.rSet=e._gsap.set(e,this.rProp,this),this.ru=AL(e._gsap.get(e,this.rProp))||0),!Array.isArray(c)||"closed"in c||"number"==typeof y)Ar(o=v(AQ(P6(t.path),e,t)),t.resolution),l.push(o),AJ(this,e,t.x||"x",o,"x",t.unitX||"px"),AJ(this,e,t.y||"y",o,"y",t.unitY||"px");else{for(s in y)!h&&~Az.indexOf(s)?h=s:!m&&~AW.indexOf(s)&&(m=s);for(s in h&&m?l.push(AK(this,AU(AU([],c,h,0),c,m,1),e,h,m,v,t,f||AL(c[0][h]),p||AL(c[0][m]))):h=m=0,y)s!==h&&s!==m&&l.push(AK(this,AU([],c,s,2),e,s,0,v,t,AL(c[0][s])))}r.vars.immediateRender&&this.render(r.progress(),this)},render:function(e,t){var r=t.rawPaths,n=r.length,a=t._pt;if(t.tween._time||!AV()){for(e>1?e=1:e<0&&(e=0);n--;)Ai(r[n],e,!n&&t.rotate,r[n]);for(;a;)a.set(a.t,a.p,a.path[a.pp]+a.u,a.d,e),a=a._next;t.rotate&&t.rSet(t.target,t.rProp,r[0].angle*(t.radians?A$:1)+t.rOffset+t.ru,t,e)}else t.styles.revert()},getLength:function(e){return Ar(P6(e)).totalLength},sliceRawPath:At,getRawPath:P6,pointsToSegment:Al,stringToRawPath:As,rawPathToString:Au,transformRawPath:Ao,getGlobalMatrix:AM,getPositionOnPath:Ai,cacheRawPathMeasurements:Ar,convertToPath:function(e,t){return AF(e).map(function(e){var r,n,a,i,o,s,l,u,c,d,f,p,h,m,y,v,g,b,x,w,S,j,O,k;return r=!1!==t,"path"!==(k=e.tagName.toLowerCase())&&e.getBBox?(l=P8(e,"x,y,width,height,cx,cy,rx,ry,r,x1,x2,y1,y2,points"),O=P7(e,P9[k]),"rect"===k?(o=O.rx,s=O.ry||o,a=O.x,i=O.y,f=O.width-2*o,p=O.height-2*s,o||s?(h=a+.44771525016900005*o,v=(y=(m=a+o)+f)+.552284749831*o,g=y+o,b=i+.44771525016900005*s,S=(w=(x=i+s)+p)+.552284749831*s,j=w+s,n="M"+g+","+x+" V"+w+" C"+[g,S,v,j,y,j,y-(y-m)/3,j,m+(y-m)/3,j,m,j,h,j,a,S,a,w,a,w-(w-x)/3,a,x+(w-x)/3,a,x,a,b,h,i,m,i,m+(y-m)/3,i,y-(y-m)/3,i,y,i,v,i,g,b,g,x].join(",")+"z"):n="M"+(a+f)+","+i+" v"+p+" h"+-f+" v"+-p+" h"+f+"z"):"circle"===k||"ellipse"===k?("circle"===k?c=.552284749831*(o=s=O.r):(o=O.rx,c=.552284749831*(s=O.ry)),a=O.cx,i=O.cy,u=.552284749831*o,n="M"+(a+o)+","+i+" C"+[a+o,i+c,a+u,i+s,a,i+s,a-u,i+s,a-o,i+c,a-o,i,a-o,i-c,a-u,i-s,a,i-s,a+u,i-s,a+o,i-c,a+o,i].join(",")+"z"):"line"===k?n="M"+O.x1+","+O.y1+" L"+O.x2+","+O.y2:("polyline"===k||"polygon"===k)&&(n="M"+(a=(d=(e.getAttribute("points")+"").match(PL)||[]).shift())+","+(i=d.shift())+" L"+d.join(","),"polygon"===k&&(n+=","+a+","+i+"z")),l.setAttribute("d",Au(l._gsRawPath=As(n))),r&&e.parentNode&&(e.parentNode.insertBefore(l,e),e.parentNode.removeChild(e)),l):e})},convertCoordinates:function(e,t,r){var n=AM(t,!0,!0).multiply(AM(e));return r?n.apply(r):n},getAlignMatrix:AZ,getRelativePosition:function(e,t,r,n){var a=AZ(e,t,r,n);return{x:a.e,y:a.f}},arrayToRawPath:function(e,t){var r=AU(AU([],e,(t=t||{}).x||"x",0),e,t.y||"y",1);return t.relative&&AG(r),["cubic"===t.type?r:Al(r,t.curviness)]}};(AI||"u">typeof window&&(AI=window.gsap)&&AI.registerPlugin&&AI)&&AI.registerPlugin(A0);let A1="BmtgkZgEaC8g-ZmaExrxmg==",A2="SZBHUVTi1OdMa9FJsKKrRg==",A3="XIbh11NxmkvKZ3BNSMMXew==";function A4(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function A5(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function A6(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}jn.registerPlugin(A0);var A8=function(e){var t,r=e.url,n=e.title,a=e.open,i=e.inPlace,o=e.id,s=e.onInPlace,l=e.total,u=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!0))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return A4(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return A4(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),c=u[0],d=u[1],f=(0,g.useRef)(null),p={transformOrigin:"center center"},h=function(){return{cx:200-(24*l-10)/2+24*o,cy:370,r:7}},m=function(){return{cx:200,cy:200,r:49}};return(0,g.useEffect)(function(){if(d(!1),f.current){var e=.4*!c,t=.2*!c,r=c?0:e+t;a?jn.timeline().set(f.current,A5({},p,h())).to(f.current,A6(A5({},p,m()),{duration:t,ease:"power3.inOut"})).to(f.current,A6(A5({},p,{cx:-4700,cy:200,r:4900}),{duration:e,ease:"power4.in",onComplete:function(){return s(o)}})):jn.timeline({overwrite:!0}).set(f.current,A5({},p,{cx:5100,cy:200,r:4900})).to(f.current,A6(A5({},p,m()),{delay:r,duration:e,ease:"power4.out"})).to(f.current,A6(A5({},p),{motionPath:{path:[{cx:200-(24*l-10)/2+24*o,cy:200,r:14},h()],curviness:1},duration:c?.01:1,ease:"bounce.out"}))}},[a]),(0,v.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0 0 ".concat(400," ").concat(400),preserveAspectRatio:"xMidYMid slice",className:A1,children:[(0,v.jsxs)("defs",{children:[(0,v.jsx)("clipPath",{id:"".concat(o,"_circleClip"),children:(0,v.jsx)("circle",{cx:0,cy:0,r:7,ref:f})}),(0,v.jsx)("clipPath",{id:"".concat(o,"_squareClip"),children:(0,v.jsx)("rect",{width:400,height:400})})]}),(0,v.jsx)("g",{clipPath:"url(#".concat(o).concat(i?"_squareClip":"_circleClip",")"),children:(0,v.jsx)("image",{width:400,height:400,href:r,className:A2,children:(0,v.jsx)("title",{children:n})})})]})},A9=function(e){var t=e.images,r=e.onSelect,n=function(e){return 200-(24*t.length-10)/2+24*e},a=function(){return 370};return(0,v.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0 0 ".concat(400," ").concat(400),preserveAspectRatio:"xMidYMid slice",className:A1,children:t.map(function(e,t){return(0,v.jsxs)("g",{className:"YLzG837WOFupR4o+Ib5MuQ==",children:[(0,v.jsx)("defs",{children:(0,v.jsx)("clipPath",{id:"tab_".concat(t,"_clip"),children:(0,v.jsx)("circle",{cx:n(t),cy:a(),r:7})})}),(0,v.jsx)("image",{x:n(t)-7,y:a()-7,width:14,height:14,href:e.url,clipPath:"url(#tab_".concat(t,"_clip)"),className:A2,preserveAspectRatio:"xMidYMid slice"}),(0,v.jsx)("circle",{onClick:function(){return r(t)},className:"rmr0X-o5feXHGYrEpgQDvw==",strokeWidth:2,cx:n(t),cy:a(),r:9,children:(0,v.jsx)("title",{children:e.title})})]},e.url)})})};function A7(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function De(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return A7(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return A7(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Dt=function(e){var t=e.images,r=e.autoplay,n=void 0===r||r,a=e.autoplayInterval,i=void 0===a?4500:a,o=e.className,s=e.style,l=De((0,g.useState)(0),2),u=l[0],c=l[1],d=De((0,g.useState)(0),2),f=d[0],p=d[1],h=De((0,g.useState)(!1),2),m=h[0],y=h[1],b=(0,g.useRef)(null),x=function(e){return p(e)},w=(0,g.useCallback)(function(){c(function(e){var r=e+1;return r>=t.length&&(r=0),r})},[t.length]),S=(0,g.useCallback)(function(){c(function(e){var r=e-1;return r<0&&(r=t.length-1),r})},[t.length]);return(0,g.useEffect)(function(){return y(!0)},[u]),(0,g.useEffect)(function(){return y(!1)},[f]),(0,g.useEffect)(function(){if(n)return b.current&&clearInterval(b.current),b.current=window.setInterval(w,i),function(){b.current&&clearInterval(b.current)}},[u,n,i,w]),(0,v.jsxs)("div",{className:O()("U-tXxoLDDyr5OI9DOeLkzg==",o),style:s,children:[(0,v.jsxs)("div",{className:"ExNnhb4iBLd2PJd4vdjc4w==",children:[t.map(function(e,r){return(0,v.jsx)("div",{className:"zDs53KpFEsOlgcDu6xCjgw==",style:{zIndex:f===r?r:t.length+1},children:(0,v.jsx)(A8,{total:t.length,id:r,url:e.url,title:e.title,open:u===r,inPlace:f===r,onInPlace:x})},e.url)}),(0,v.jsx)("div",{className:"_5Hv7dRjmf3CkVFgfdeV0HQ==",children:(0,v.jsx)(A9,{images:t,onSelect:function(e){m||c(e)}})})]}),(0,v.jsx)("button",{type:"button",className:O()(A3,"PAulbSkkA9jxQi1R6BQ75A=="),onClick:S,disabled:m,"aria-label":"Image pr\xe9c\xe9dente",children:(0,v.jsx)(ox,{size:28})}),(0,v.jsx)("button",{type:"button",className:O()(A3,"aIKGaIx0zEpUN2opqQJjfg=="),onClick:w,disabled:m,"aria-label":"Image suivante",children:(0,v.jsx)(ow,{size:28})})]})};function Dr(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Dn(e){var t=e.handleShuffle,r=e.testimonial,n=e.position,a=e.id,i=e.author,o=e.avatarUrl,s=e.cardWidth,l=e.cardHeight,u=e.className,c=e.style,d=(0,g.useRef)(0),f="front"===n;return(0,v.jsxs)(hz.div,{style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){Dr(e,t,r[t])})}return e}({zIndex:"front"===n?2:+("middle"===n),width:void 0===s?350:s,height:void 0===l?450:l},c),animate:{rotate:"front"===n?"-6deg":"middle"===n?"0deg":"6deg",x:"front"===n?"0%":"middle"===n?"33%":"66%"},drag:!0,dragElastic:.35,dragListener:f,dragConstraints:{top:0,left:0,right:0,bottom:0},onDragStart:function(e){d.current=e.clientX},onDragEnd:function(e){var r=e.clientX;d.current-r>150&&t(),d.current=0},transition:{duration:.35},className:O()("MY7YZNf47I5RSHhV26w6Ag==",Dr({},"_2Eid4z+wvtEzluRmyU9KfQ==",f),u),children:[(0,v.jsx)("img",{src:null!=o?o:"https://i.pravatar.cc/128?img=".concat(a),alt:"Avatar of ".concat(i),className:"N7o2pWg-TdybJuikJXI0AQ==",draggable:!1}),(0,v.jsxs)("span",{className:"-+76DfLbDI0klJgz4+oBig==",children:['"',r,'"']}),(0,v.jsx)("span",{className:"h8hsmFiRL4Cc37zAjzK3jQ==",children:i})]})}function Da(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Di(e){if(Array.isArray(e))return e}function Do(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function Ds(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Dl(e,t){if(e){if("string"==typeof e)return Da(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Da(e,t)}}function Du(e){var t,r=e.testimonials,n=e.cardWidth,a=void 0===n?350:n,i=e.cardHeight,o=void 0===i?450:i,s=e.className,l=e.style,u=e.onShuffle,c=Di(t=(0,g.useState)(function(){return r.map(function(e,t){return t})}))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||Dl(t,2)||Ds(),d=c[0],f=c[1];(0,g.useEffect)(function(){f(r.map(function(e,t){return t}))},[r]);var p=(0,g.useCallback)(function(){f(function(e){if(0===e.length)return e;var t,n=Di(e)||Do(e)||Dl(e)||Ds(),a=n[0],i=n.slice(1);return null==u||u(null==(t=r[a])?void 0:t.id),((function(e){if(Array.isArray(e))return Da(e)})(i)||Do(i)||Dl(i)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([a])})},[u,r]);return(0,v.jsx)("div",{className:O()("FsSes4zAoxSyWmsIs2kmJQ==",s),style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({width:a,height:o},l),children:d.map(function(e,t){var n=r[e];return n?(0,v.jsx)(Dn,{id:n.id,testimonial:n.testimonial,author:n.author,avatarUrl:n.avatarUrl,position:0===t?"front":1===t?"middle":"back",handleShuffle:p,cardWidth:a,cardHeight:o},n.id):null})})}var Dc=(0,g.createContext)(null),Dd=function(){var e=(0,g.useContext)(Dc);if(!e)throw Error("Carousel compound components must be used within <Carousel>");return e};function Df(e){return"[object Object]"===Object.prototype.toString.call(e)||Array.isArray(e)}function Dp(e,t){var r=Object.keys(e),n=Object.keys(t);return r.length===n.length&&JSON.stringify(Object.keys(e.breakpoints||{}))===JSON.stringify(Object.keys(t.breakpoints||{}))&&r.every(function(r){var n=e[r],a=t[r];return"function"==typeof n?"".concat(n)==="".concat(a):Df(n)&&Df(a)?Dp(n,a):n===a})}function Dh(e){return e.concat().sort(function(e,t){return e.name>t.name?1:-1}).map(function(e){return e.options})}function Dm(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Dy(e){return"number"==typeof e}function Dv(e){return"string"==typeof e}function Dg(e){return"boolean"==typeof e}function Db(e){return"[object Object]"===Object.prototype.toString.call(e)}function Dx(e){return Math.abs(e)}function Dw(e){return Math.sign(e)}function DS(e){return DE(e).map(Number)}function Dj(e){return e[DO(e)]}function DO(e){return Math.max(0,e.length-1)}function Dk(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return Array.from(Array(e),function(e,r){return t+r})}function DE(e){return Object.keys(e)}function DP(e,t){var r;return void 0!==t.MouseEvent&&(null!=(r=t.MouseEvent)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](e):e instanceof r)}function DA(){var e=[],t={add:function(r,n,a){var i,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{passive:!0};return"addEventListener"in r?(r.addEventListener(n,a,o),i=function(){return r.removeEventListener(n,a,o)}):(r.addListener(a),i=function(){return r.removeListener(a)}),e.push(i),t},clear:function(){e=e.filter(function(e){return e()})}};return t}function DD(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=Dx(e-t);function n(r){return r<e||r>t}return{length:r,max:t,min:e,constrain:function(r){return n(r)?r<e?e:t:r},reachedAny:n,reachedMax:function(e){return e>t},reachedMin:function(t){return t<e},removeOffset:function(e){return r?e-r*Math.ceil((e-t)/r):e}}}function DC(e){var t=e;function r(e){return Dy(e)?e:e.get()}return{get:function(){return t},set:function(e){t=r(e)},add:function(e){t+=r(e)},subtract:function(e){t-=r(e)}}}function DT(e,t){var r="x"===e.scroll?function(e){return"translate3d(".concat(e,"px,0px,0px)")}:function(e){return"translate3d(0px,".concat(e,"px,0px)")},n=t.style,a=null,i=!1;return{clear:function(){!i&&(n.transform="",t.getAttribute("style")||t.removeAttribute("style"))},to:function(t){if(!i){var o=Math.round(100*e.direction(t))/100;o!==a&&(n.transform=r(o),a=o)}},toggleActive:function(e){i=!e}}}var DN={align:"center",axis:"x",container:null,slides:null,containScroll:"trimSnaps",direction:"ltr",slidesToScroll:1,inViewThreshold:0,breakpoints:{},dragFree:!1,dragThreshold:10,loop:!1,skipSnaps:!1,duration:25,startIndex:0,active:!0,watchDrag:!0,watchResize:!0,watchSlides:!0,watchFocus:!0};function DR(e,t,r){var n,a,i,o,s,l,u,c,d=e.ownerDocument,f=d.defaultView,p=function(e){function t(e,t){return function e(t,r){return[t,r].reduce(function(t,r){return DE(r).forEach(function(n){var a=t[n],i=r[n],o=Db(a)&&Db(i);t[n]=o?e(a,i):i}),t},{})}(e,t||{})}return{mergeOptions:t,optionsAtMedia:function(r){var n=r.breakpoints||{},a=DE(n).filter(function(t){return e.matchMedia(t).matches}).map(function(e){return n[e]}).reduce(function(e,r){return t(e,r)},{});return t(r,a)},optionsMediaQueries:function(t){return t.map(function(e){return DE(e.breakpoints||{})}).reduce(function(e,t){return e.concat(t)},[]).map(e.matchMedia)}}}(f),h=(o=[],{init:function(e,t){return(o=t.filter(function(e){var t=e.options;return!1!==p.optionsAtMedia(t).active})).forEach(function(t){return t.init(e,p)}),t.reduce(function(e,t){var r,n;return Object.assign(e,(r={},n=t.name,n in r?Object.defineProperty(r,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[n]=t,r))},{})},destroy:function(){o=o.filter(function(e){return e.destroy()})}}),m=DA(),y=(a={},i={init:function(e){n=e},emit:function(e){return(a[e]||[]).forEach(function(t){return t(n,e)}),i},off:function(e,t){return a[e]=(a[e]||[]).filter(function(e){return e!==t}),i},on:function(e,t){return a[e]=(a[e]||[]).concat([t]),i},clear:function(){a={}}}),v=p.mergeOptions,g=p.optionsAtMedia,b=p.optionsMediaQueries,x=y.on,w=y.off,S=y.emit,j=!1,O=v(DN,DR.globalOptions),k=v(O),E=[];function P(t,r){var n,a,i,o;!j&&(k=g(O=v(O,t)),E=r||E,n=k.container,a=k.slides,u=(Dv(n)?e.querySelector(n):n)||e.children[0],i=Dv(a)?u.querySelectorAll(a):a,c=[].slice.call(i||u.children),s=function t(r){var n=function(e,t,r,n,a,i,o){var s,l,u,c,d,f,p,h,m,y,v,g,b,x,w,S,j,O,k,E,P,A,D,C,T,N,R,M,I,L,F,B,V,z,W,$,U,H,G,K,q,Y,X,Z,Q=i.align,J=i.axis,ee=i.direction,et=i.startIndex,er=i.loop,en=i.duration,ea=i.dragFree,ei=i.dragThreshold,eo=i.inViewThreshold,es=i.slidesToScroll,el=i.skipSnaps,eu=i.containScroll,ec=i.watchResize,ed=i.watchSlides,ef=i.watchDrag,ep=i.watchFocus,eh={measure:function(e){var t=e.offsetTop,r=e.offsetLeft,n=e.offsetWidth,a=e.offsetHeight;return{top:t,right:r+n,bottom:t+a,left:r,width:n,height:a}}},em=eh.measure(t),ey=r.map(eh.measure),ev=(d="rtl"===ee,p=(f="y"===J)||!d?1:-1,h=f?"top":d?"right":"left",m=f?"bottom":d?"left":"right",{scroll:f?"y":"x",cross:f?"x":"y",startEdge:h,endEdge:m,measureSize:function(e){var t=e.height,r=e.width;return f?t:r},direction:function(e){return e*p}}),eg=ev.measureSize(em),eb={measure:function(e){return e/100*eg}},ex=(s=Q,l=eg,u={start:function(){return 0},center:function(e){return(l-e)/2},end:function(e){return l-e}},{measure:function(e,t){return Dv(s)?u[s](e):s(l,e,t)}}),ew=!er&&!!eu,eS=er||!!eu,ej=(y=ev.measureSize,v=ev.startEdge,g=ev.endEdge,b=ey[0]&&eS,x=function(){if(!b)return 0;var e=ey[0];return Dx(em[v]-e[v])}(),w=b?parseFloat(a.getComputedStyle(Dj(r)).getPropertyValue("margin-".concat(g))):0,S=ey.map(y),j=ey.map(function(e,t,r){var n=t===DO(r);return t?n?S[t]+w:r[t+1][v]-e[v]:S[t]+x}).map(Dx),{slideSizes:S,slideSizesWithGaps:j,startGap:x,endGap:w}),eO=ej.slideSizes,ek=ej.slideSizesWithGaps,eE=ej.startGap,eP=ej.endGap,eA=(O=ev.startEdge,k=ev.endEdge,E=ev.direction,P=Dy(es),{groupSlides:function(e){return P?DS(e).filter(function(e){return e%es==0}).map(function(t){return e.slice(t,t+es)}):e.length?DS(e).reduce(function(t,r,n){var a=Dj(t)||0,i=r===DO(e),o=em[O]-ey[a][O],s=em[O]-ey[r][k],l=er||0!==a?0:E(eE),u=Dx(s-(!er&&i?E(eP):0)-(o+l));return n&&u>eg+2&&t.push(r),i&&t.push(e.length),t},[]).map(function(t,r,n){var a=Math.max(n[r-1]||0);return e.slice(a,t)}):[]}}),eD=(A=ev.startEdge,D=ev.endEdge,T=(C=eA.groupSlides)(ey).map(function(e){return Dj(e)[D]-e[0][A]}).map(Dx).map(ex.measure),R=C(N=ey.map(function(e){return em[A]-e[A]}).map(function(e){return-Dx(e)})).map(function(e){return e[0]}).map(function(e,t){return e+T[t]}),{snaps:N,snapsAligned:R}),eC=eD.snaps,eT=eD.snapsAligned,eN=-Dj(eC)+Dj(ek),eR=function(e,t,r,n){var a,i,o=DD(-t+e,0),s=r.map(function(e,t){var n=o.min,a=o.max,i=o.constrain(e),s=t===DO(r);return t?s||function(e,t){return 1>=Dx(e-t)}(n,i)?n:function(e,t){return 1>=Dx(e-t)}(a,i)?a:i:a}).map(function(e){return parseFloat(e.toFixed(3))}),l=(a=s[0],i=Dj(s),DD(s.lastIndexOf(a),s.indexOf(i)+1));return{snapsContained:function(){if(t<=e+2)return[o.max];if("keepSnaps"===n)return s;var r=l.min,a=l.max;return s.slice(r,a)}(),scrollContainLimit:l}}(eg,eN,eT,eu),eM=eR.snapsContained,eI=eR.scrollContainLimit,e_=ew?eM:eT,eL=(M=e_[0],{limit:DD(er?M-eN:Dj(e_),M)}).limit,eF=function e(t,r,n){var a=DD(0,t).constrain,i=t+1,o=s(r);function s(e){return n?Dx((i+e)%i):a(e)}function l(){return e(t,o,n)}var u={get:function(){return o},set:function(e){return o=s(e),u},add:function(e){return l().set(o+e)},clone:l};return u}(DO(e_),et,er),eB=eF.clone(),eV=DS(r),ez=function(e){var t=e.dragHandler,r=e.scrollBody,n=e.scrollBounds;e.options.loop||n.constrain(t.pointerDown()),r.seek()},eW=function(e,t){var r=e.scrollBody,n=e.translate,a=e.location,i=e.offsetLocation,o=e.previousLocation,s=e.scrollLooper,l=e.slideLooper,u=e.dragHandler,c=e.animation,d=e.eventHandler,f=e.scrollBounds,p=e.options.loop,h=r.settled(),m=!f.shouldConstrain(),y=p?h:h&&m,v=y&&!u.pointerDown();v&&c.stop();var g=a.get()*t+o.get()*(1-t);i.set(g),p&&(s.loop(r.direction()),l.loop()),n.to(i.get()),v&&d.emit("settle"),y||d.emit("scroll")},e$=function(e,t,r,n){var a=DA(),i=1e3/60,o=null,s=0,l=0;function u(e){if(l){o||(o=e,r(),r());var a=e-o;for(o=e,s+=a;s>=i;)r(),s-=i;n(s/i),l&&(l=t.requestAnimationFrame(u))}}function c(){t.cancelAnimationFrame(l),o=null,s=0,l=0}return{init:function(){a.add(e,"visibilitychange",function(){e.hidden&&(o=null,s=0)})},destroy:function(){c(),a.clear()},start:function(){l||(l=t.requestAnimationFrame(u))},stop:c,update:r,render:n}}(n,a,function(){return ez(e3)},function(e){return eW(e3,e)}),eU=e_[eF.get()],eH=DC(eU),eG=DC(eU),eK=DC(eU),eq=DC(eU),eY=function(e,t,r,n,a){var i=0,o=0,s=a,l=.68,u=e.get(),c=0;function d(e){return s=e,p}function f(e){return l=e,p}var p={direction:function(){return o},duration:function(){return s},velocity:function(){return i},seek:function(){var t=n.get()-e.get(),a=0;return s?(r.set(e),i+=t/s,i*=l,u+=i,e.add(i),a=u-c):(i=0,r.set(n),e.set(n),a=t),o=Dw(a),c=u,p},settled:function(){return .001>Dx(n.get()-t.get())},useBaseFriction:function(){return f(.68)},useBaseDuration:function(){return d(a)},useFriction:f,useDuration:d};return p}(eH,eK,eG,eq,en),eX=function(e,t,r,n,a){var i=n.reachedAny,o=n.removeOffset,s=n.constrain;function l(e){return e.concat().sort(function(e,t){return Dx(e)-Dx(t)})[0]}function u(t,n){var a=[t,t+r,t-r];if(!e)return t;if(!n)return l(a);var i=a.filter(function(e){return Dw(e)===n});return i.length?l(i):Dj(a)-r}return{byDistance:function(r,n){var l,c=a.get()+r,d=(l=e?o(c):s(c),{index:t.map(function(e,t){return{diff:u(e-l,0),index:t}}).sort(function(e,t){return Dx(e.diff)-Dx(t.diff)})[0].index,distance:l}),f=d.index,p=d.distance,h=!e&&i(c);if(!n||h)return{index:f,distance:r};var m=r+u(t[f]-p,0);return{index:f,distance:m}},byIndex:function(e,r){var n=u(t[e]-a.get(),r);return{index:e,distance:n}},shortcut:u}}(er,e_,eN,eL,eq),eZ=function(e,t,r,n,a,i,o){function s(a){var s=a.distance,l=a.index!==t.get();i.add(s),s&&(n.duration()?e.start():(e.update(),e.render(1),e.update())),l&&(r.set(t.get()),t.set(a.index),o.emit("select"))}return{distance:function(e,t){s(a.byDistance(e,t))},index:function(e,r){var n=t.clone().set(e);s(a.byIndex(n.get(),r))}}}(e$,eF,eB,eY,eX,eq,o),eQ=(I=eL.max,L=eL.length,{get:function(e){return L?-((e-I)/L):0}}),eJ=DA(),e0=(B={},V=null,z=null,W=!1,{init:function(){F=new IntersectionObserver(function(e){W||(e.forEach(function(e){B[r.indexOf(e.target)]=e}),V=null,z=null,o.emit("slidesInView"))},{root:t.parentElement,threshold:eo}),r.forEach(function(e){return F.observe(e)})},destroy:function(){F&&F.disconnect(),W=!0},get:function(){var e=!(arguments.length>0)||void 0===arguments[0]||arguments[0];if(e&&V)return V;if(!e&&z)return z;var t=DE(B).reduce(function(t,r){var n=parseInt(r),a=B[n].isIntersecting;return(e&&a||!e&&!a)&&t.push(n),t},[]);return e&&(V=t),e||(z=t),t}}),e1=($=eA.groupSlides,U=eI.min,H=eI.max,{slideRegistry:(c=$(eV),1===e_.length?[eV]:ew&&"keepSnaps"!==eu?c.slice(U,H).map(function(e,t,r){var n=t===DO(r);return t?n?Dk(DO(eV)-Dj(r)[0]+1,Dj(r)[0]):e:Dk(Dj(r[0])+1)}):c)}).slideRegistry,e2=function(e,t,r,n,a,i,o,s){var l={passive:!0,capture:!0},u=0;function c(e){"Tab"===e.code&&(u=new Date().getTime())}return{init:function(d){s&&(i.add(document,"keydown",c,!1),t.forEach(function(t,c){i.add(t,"focus",function(t){(Dg(s)||s(d,t))&&function(t){if(!(new Date().getTime()-u>10)){o.emit("slideFocusStart"),e.scrollLeft=0;var i=r.findIndex(function(e){return e.includes(t)});Dy(i)&&(a.useDuration(0),n.index(i,0),o.emit("slideFocus"))}}(c)},l)}))}}}(e,r,e1,eZ,eY,eJ,o,ep),e3={ownerDocument:n,ownerWindow:a,eventHandler:o,containerRect:em,slideRects:ey,animation:e$,axis:ev,dragHandler:function(e,t,r,n,a,i,o,s,l,u,c,d,f,p,h,m,y,v){var g=e.cross,b=e.direction,x=["INPUT","SELECT","TEXTAREA"],w={passive:!1},S=DA(),j=DA(),O=DD(50,225).constrain(p.measure(20)),k={mouse:300,touch:400},E={mouse:500,touch:600},P=h?43:25,A=!1,D=0,C=0,T=!1,N=!1,R=!1,M=!1;function I(e){if(!DP(e,n)&&e.touches.length>=2)return L(e);var t=i.readPoint(e),r=i.readPoint(e,g),o=Dx(t-D),l=Dx(r-C);if(!N&&!M&&(!e.cancelable||!(N=o>l)))return L(e);var c=i.pointerMove(e);o>m&&(R=!0),u.useFriction(.3).useDuration(.75),s.start(),a.add(b(c)),e.preventDefault()}function L(e){var t,r,n,a=c.byDistance(0,!1).index!==d.get(),o=i.pointerUp(e)*(h?E:k)[M?"mouse":"touch"],s=(t=b(o),r=d.add(-1*Dw(t)),n=c.byDistance(t,!h).distance,h||Dx(t)<O?n:y&&a?.5*n:c.byIndex(r.get(),0).distance),p=function(e,t){if(0===e||0===t||Dx(e)<=Dx(t))return 0;var r,n,a=(r=Dx(e),n=Dx(t),Dx(r-n));return Dx(a/e)}(o,s);N=!1,T=!1,j.clear(),u.useDuration(P-10*p).useFriction(.68+p/50),l.distance(s,!h),M=!1,f.emit("pointerUp")}function F(e){R&&(e.stopPropagation(),e.preventDefault(),R=!1)}return{init:function(e){v&&S.add(t,"dragstart",function(e){return e.preventDefault()},w).add(t,"touchmove",function(){},w).add(t,"touchend",function(){}).add(t,"touchstart",s).add(t,"mousedown",s).add(t,"touchcancel",L).add(t,"contextmenu",L).add(t,"click",F,!0);function s(s){var l,c,d,p;(Dg(v)||v(e,s))&&(M=p=DP(l=s,n),R=h&&p&&!l.buttons&&A,A=Dx(a.get()-o.get())>=2,(!p||0===l.button)&&(c=l.target.nodeName||"",x.includes(c)||(T=!0,i.pointerDown(l),u.useFriction(0).useDuration(0),a.set(o),d=M?r:t,j.add(d,"touchmove",I,w).add(d,"touchend",L).add(d,"mousemove",I,w).add(d,"mouseup",L),D=i.readPoint(l),C=i.readPoint(l,g),f.emit("pointerDown"))))}},destroy:function(){S.clear(),j.clear()},pointerDown:function(){return T}}}(ev,e,n,a,eq,function(e,t){var r,n;function a(e){return e.timeStamp}function i(r,n){var a=n||e.scroll;return(DP(r,t)?r:r.touches[0])["client".concat("x"===a?"X":"Y")]}return{pointerDown:function(e){return r=e,n=e,i(e)},pointerMove:function(e){var t=i(e)-i(n),o=a(e)-a(r)>170;return n=e,o&&(r=e),t},pointerUp:function(e){if(!r||!n)return 0;var t=i(n)-i(r),o=a(e)-a(r),s=a(e)-a(n)>170,l=t/o;return o&&!s&&Dx(l)>.1?l:0},readPoint:i}}(ev,a),eH,e$,eZ,eY,eX,eF,o,eb,ea,ei,el,ef),eventStore:eJ,percentOfView:eb,index:eF,indexPrevious:eB,limit:eL,location:eH,offsetLocation:eK,previousLocation:eG,options:i,resizeHandler:function(e,t,r,n,a,i,o){var s,l,u=[e].concat(n),c=[],d=!1;function f(e){return a.measureSize(o.measure(e))}return{init:function(a){i&&(l=f(e),c=n.map(f),s=new ResizeObserver(function(r){(Dg(i)||i(a,r))&&function(r){var i=!0,o=!1,s=void 0;try{for(var u,p=r[Symbol.iterator]();!(i=(u=p.next()).done);i=!0){var h=u.value;if(d)return;var m=h.target===e,y=n.indexOf(h.target),v=m?l:c[y],g=f(m?e:n[y]);if(Dx(g-v)>=.5){a.reInit(),t.emit("resize");break}}}catch(e){o=!0,s=e}finally{try{i||null==p.return||p.return()}finally{if(o)throw s}}}(r)}),r.requestAnimationFrame(function(){u.forEach(function(e){return s.observe(e)})}))},destroy:function(){d=!0,s&&s.disconnect()}}}(t,o,a,r,ev,ec,eh),scrollBody:eY,scrollBounds:function(e,t,r,n,a){var i=a.measure(10),o=a.measure(50),s=DD(.1,.99),l=!1;function u(){return!l&&!!e.reachedAny(r.get())&&!!e.reachedAny(t.get())}return{shouldConstrain:u,constrain:function(a){if(u()){var l=e.reachedMin(t.get())?"min":"max",c=Dx(e[l]-t.get()),d=r.get()-t.get(),f=s.constrain(c/o);r.subtract(d*f),!a&&Dx(d)<i&&(r.set(e.constrain(r.get())),n.useDuration(25).useBaseFriction())}},toggleActive:function(e){l=!e}}}(eL,eK,eq,eY,eb),scrollLooper:(G=[eH,eK,eG,eq],q=(K=DD(eL.min+.1,eL.max+.1)).reachedMin,Y=K.reachedMax,{loop:function(e){if(1===e?Y(eK.get()):-1===e&&q(eK.get())){var t=-1*e*eN;G.forEach(function(e){return e.add(t)})}}}),scrollProgress:eQ,scrollSnapList:e_.map(eQ.get),scrollSnaps:e_,scrollTarget:eX,scrollTo:eZ,slideLooper:function(e,t,r,n,a,i,o,s,l){var u=DS(a),c=DS(a).reverse(),d=h(p(c,o[0]),r,!1).concat(h(p(u,t-o[0]-1),-r,!0));function f(e,t){return e.reduce(function(e,t){return e-a[t]},t)}function p(e,t){return e.reduce(function(e,r){return f(e,t)>0?e.concat([r]):e},[])}function h(a,o,u){var c=i.map(function(e,r){return{start:e-n[r]+.5+o,end:e+t-.5+o}});return a.map(function(t){var n=u?0:-r,a=u?r:0,i=c[t][u?"end":"start"];return{index:t,loopPoint:i,slideLocation:DC(-1),translate:DT(e,l[t]),target:function(){return s.get()>i?n:a}}})}return{canLoop:function(){return d.every(function(e){var r=e.index;return .1>=f(u.filter(function(e){return e!==r}),t)})},clear:function(){d.forEach(function(e){return e.translate.clear()})},loop:function(){d.forEach(function(e){var t=e.target,r=e.translate,n=e.slideLocation,a=t();a!==n.get()&&(r.to(a),n.set(a))})},loopPoints:d}}(ev,eg,eN,eO,ek,eC,e_,eK,r),slideFocus:e2,slidesHandler:(Z=!1,{init:function(e){ed&&(X=new MutationObserver(function(t){!Z&&(Dg(ed)||ed(e,t))&&function(t){var r=!0,n=!1,a=void 0;try{for(var i,s=t[Symbol.iterator]();!(r=(i=s.next()).done);r=!0){var l=i.value;if("childList"===l.type){e.reInit(),o.emit("slidesChanged");break}}}catch(e){n=!0,a=e}finally{try{r||null==s.return||s.return()}finally{if(n)throw a}}}(t)})).observe(t,{childList:!0})},destroy:function(){X&&X.disconnect(),Z=!0}}),slidesInView:e0,slideIndexes:eV,slideRegistry:e1,slidesToScroll:eA,target:eq,translate:DT(ev,t)};return e3}(e,u,c,d,f,r,y);return r.loop&&!n.slideLooper.canLoop()?t(Object.assign({},r,{loop:!1})):n}(k),b([O].concat(function(e){if(Array.isArray(e))return Dm(e)}(o=E.map(function(e){return e.options}))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(o)||function(e){if(e){if("string"==typeof e)return Dm(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Dm(e,void 0)}}(o)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())).forEach(function(e){return m.add(e,"change",A)}),k.active&&(s.translate.to(s.location.get()),s.animation.init(),s.slidesInView.init(),s.slideFocus.init(N),s.eventHandler.init(N),s.resizeHandler.init(N),s.slidesHandler.init(N),s.options.loop&&s.slideLooper.loop(),u.offsetParent&&c.length&&s.dragHandler.init(N),l=h.init(N,E)))}function A(e,t){var r=T();D(),P(v({startIndex:r},e),t),y.emit("reInit")}function D(){s.dragHandler.destroy(),s.eventStore.clear(),s.translate.clear(),s.slideLooper.clear(),s.resizeHandler.destroy(),s.slidesHandler.destroy(),s.slidesInView.destroy(),s.animation.destroy(),h.destroy(),m.clear()}function C(e,t,r){k.active&&!j&&(s.scrollBody.useBaseFriction().useDuration(!0===t?0:k.duration),s.scrollTo.index(e,r||0))}function T(){return s.index.get()}var N={canScrollNext:function(){return s.index.add(1).get()!==T()},canScrollPrev:function(){return s.index.add(-1).get()!==T()},containerNode:function(){return u},internalEngine:function(){return s},destroy:function(){j||(j=!0,m.clear(),D(),y.emit("destroy"),y.clear())},off:w,on:x,emit:S,plugins:function(){return l},previousScrollSnap:function(){return s.indexPrevious.get()},reInit:A,rootNode:function(){return e},scrollNext:function(e){C(s.index.add(1).get(),e,-1)},scrollPrev:function(e){C(s.index.add(-1).get(),e,1)},scrollProgress:function(){return s.scrollProgress.get(s.offsetLocation.get())},scrollSnapList:function(){return s.scrollSnapList},scrollTo:C,selectedScrollSnap:T,slideNodes:function(){return c},slidesInView:function(){return s.slidesInView.get()},slidesNotInView:function(){return s.slidesInView.get(!1)}};return P(t,r),setTimeout(function(){return y.emit("init")},0),N}function DM(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function DI(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return DM(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return DM(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function D_(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=(0,g.useRef)(e),n=(0,g.useRef)(t),a=DI((0,g.useState)(),2),i=a[0],o=a[1],s=DI((0,g.useState)(),2),l=s[0],u=s[1],c=(0,g.useCallback)(function(){i&&i.reInit(r.current,n.current)},[i]);return(0,g.useEffect)(function(){Dp(r.current,e)||(r.current=e,c())},[e,c]),(0,g.useEffect)(function(){!function(e,t){if(e.length!==t.length)return!1;var r=Dh(e),n=Dh(t);return r.every(function(e,t){return Dp(e,n[t])})}(n.current,t)&&(n.current=t,c())},[t,c]),(0,g.useEffect)(function(){if("u">typeof window&&window.document&&window.document.createElement&&l){DR.globalOptions=D_.globalOptions;var e=DR(l,r.current,n.current);return o(e),function(){return e.destroy()}}o(void 0)},[l,o]),[u,i]}DR.globalOptions=void 0,D_.globalOptions=void 0;let DL={root:"U5e-lVeOV3aIYgNBY3CvXA==",viewport:"hbkmtr9NY5nS0b6sekJBqg==","viewport--x":"_8JvxYg-UqoVn3brqjKyvFQ==","viewport--y":"P5LNM+fGTcgmqv-M4-1hRw==",container:"Q0dxJjntBDyAdjQVlkdqrg==","container--x":"TGKn-LXAgM3-0Licuc8L4A==","container--y":"A7zaK7w9OGucgZen2RLdWg==",slide:"UWf6nD6UXLs3JqN72IP+mQ==","slide--x":"fFHnS24UCF9k8JOqfNCsqA==","slide--y":"bHvcZzVuc3QI8dfb+oh97g==",thumbsViewport:"koJHE5dWVzTOIKbYQy2q7w==",thumbsContainer:"p8w-6uNOJVMKH+Ur8uJ4tg==","thumbsContainer--x":"Au0B9jnCnsAkOZfuWEvK1A==","thumbsContainer--y":"G6B3FuzXWoGnha6EVtyPEA==",thumb:"VfsjLHXaM0hbukRdL-v3kg==","thumb--active":"fLfMTaEbv8cMyS0-ZVobiA==",thumbImage:"AL26JFHTg0-E-BXdkLhdjA==",dots:"+CDjHobF2k1kpYO7CpiPKw==",dot:"d7ri6n1PqgEw0cvheR6P-g==","dot--active":"rekho7j513oArbBYPNsHCw=="};function DF(e){var t=e.children,r=e.className,n=Dd(),a=n.axis,i=n.mainViewportRef;return(0,v.jsx)("div",{ref:i,className:O()(DL.viewport,DL["viewport--".concat(a)],r),children:(0,v.jsx)("div",{className:O()(DL.container,DL["container--".concat(a)]),children:t})})}function DB(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function DV(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return DB(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return DB(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Dz(e){var t,r,n,a=e.children,i=e.options,o=e.plugins,s=e.dir,l=void 0===s?"ltr":s,u=e.className,c=e.style,d=null!=(n=null==i?void 0:i.axis)?n:"x",f=DV(D_((t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},i),r=r={direction:l},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t),o),2),p=f[0],h=f[1],m=DV(D_({axis:d,direction:l,containScroll:"keepSnaps",dragFree:!0}),2),y=m[0],x=m[1],w=DV((0,g.useState)(0),2),S=w[0],j=w[1],k=(0,g.useMemo)(function(){return function(e){var t=b().Children.toArray(e),r=!0,n=!1,a=void 0;try{for(var i,o=t[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s=i.value;if(b().isValidElement(s)&&s.type===DF){var l=s.props;return b().Children.toArray(l.children).filter(b().isValidElement).map(function(e){return e.props.thumbnailSrc})}}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}return[]}(a)},[a]),E=(0,g.useCallback)(function(e){null==h||h.scrollTo(e)},[h]),P=(0,g.useCallback)(function(){if(h){var e=h.selectedScrollSnap();j(e),null==x||x.scrollTo(e)}},[h,x]);return(0,g.useEffect)(function(){if(h)return P(),h.on("select",P).on("reInit",P),function(){h.off("select",P).off("reInit",P)}},[h,P]),(0,v.jsx)(Dc.Provider,{value:{axis:d,mainViewportRef:p,mainApi:h,thumbsViewportRef:y,thumbsApi:x,selectedIndex:S,scrollTo:E,thumbnails:k},children:(0,v.jsx)("div",{className:O()(DL.root,u),style:c,children:a})})}function DW(e){var t=e.children,r=e.className,n=Dd().axis;return(0,v.jsx)("div",{className:O()(DL.slide,DL["slide--".concat(n)],r),children:t})}function D$(e){var t=e.className,r=e.thumbsSliderClassName,n=Dd(),a=n.axis,i=n.thumbsViewportRef,o=n.thumbnails,s=n.selectedIndex,l=n.scrollTo;return 0===o.length?null:(0,v.jsx)("div",{ref:i,className:O()(DL.thumbsViewport,t),children:(0,v.jsx)("div",{className:O()(DL.thumbsContainer,DL["thumbsContainer--".concat(a)]),children:o.map(function(e,t){var n,a,i=t===s;return(0,v.jsx)("button",{type:"button",onClick:function(){return l(t)},className:O()(DL.thumb,(n={},a=DL["thumb--active"],a in n?Object.defineProperty(n,a,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[a]=i,n),i&&r),"aria-label":"Aller \xe0 l'\xe9l\xe9ment ".concat(t+1),"aria-current":i,children:e&&(0,v.jsx)("img",{src:e,alt:"",className:DL.thumbImage})},t)})})})}function DU(e){var t=e.className,r=e.dotClassName,n=Dd(),a=n.thumbnails,i=n.selectedIndex,o=n.scrollTo;return 0===a.length?null:(0,v.jsx)("div",{className:O()(DL.dots,t),children:a.map(function(e,t){var n,a,s;return(0,v.jsx)("button",{type:"button",onClick:function(){return o(t)},className:O()(DL.dot,(n={},a=DL["dot--active"],s=t===i,a in n?Object.defineProperty(n,a,{value:s,enumerable:!0,configurable:!0,writable:!0}):n[a]=s,n),r),"aria-label":"Aller \xe0 l'\xe9l\xe9ment ".concat(t+1),"aria-current":t===i},t)})})}function DH(e){var t=e.id,r=e.as,n=e.variant,a=void 0===n?"transparent":n,i=e.title,o=e.titleAs,s=e.description,l=e.actions,u=e.ariaLabel,c=e.bare,d=e.className,f=e.children,p=!!(i||s||l);return(0,v.jsxs)(void 0===r?"section":r,{id:t,"aria-label":u,className:["UmIprimi5rDlNw2L9yDmFQ==","panel"===a?"+B1ojNNxuYjq0VnPjP+Ekg==":"Ox7Wrjz8+j2BU7Di1Y8ELg==",void 0!==c&&c&&"panel"===a?"o-Q1RvbOEWlyFqMbRSrIoA==":"",null!=d?d:""].filter(Boolean).join(" "),children:[p&&(0,v.jsxs)("div",{className:"LrLQVHznKTKpP+sixgbcxw==",children:[(0,v.jsxs)("div",{className:"BvPyQkfXGhbXV5zz8kzPnQ==",children:[i&&(0,v.jsx)(void 0===o?"h2":o,{className:"_4RbpFTdRUk7YImbA17B5sA==",children:i}),s&&(0,v.jsx)("p",{className:"egOy0zRIXPnh18Es9FRT4Q==",children:s})]}),l&&(0,v.jsx)("div",{className:"Mx43sOmbyth8AWcB+68ebA==",children:l})]}),(0,v.jsx)("div",{className:"TGtAbo3aZ-O1gVq2zjgN5g==",children:f})]})}var DG={collapse:"Replier la section",expand:"D\xe9plier la section"},DK=(0,g.createContext)({tone:"onDark",density:"comfortable",classNames:{},labels:DG,headerLayout:"split",footerLayout:"between",divider:!0,footerDivider:!0,collapsible:!1,collapsed:!1,toggle:function(){}});function Dq(){return(0,g.useContext)(DK)}var DY={sm:{text:"h-7 px-2.5 text-xs",icon:"size-7"},md:{text:"h-8 px-3 text-[13px]",icon:"size-8"}};function DX(e){var t=e.children,r=e.icon,n=e.label,a=e.active,i=void 0!==a&&a,o=e.variant,s=void 0===o?"ghost":o,l=e.size,u=void 0===l?"md":l,c=e.href,d=e.target,f=e.rel,p=e.disabled,h=e.type,m=e.onClick,y=e.className,g=!t,b=(0,w.cn)("inline-flex shrink-0 cursor-pointer select-none items-center justify-center gap-1.5 whitespace-nowrap rounded-md","font-medium leading-none no-underline outline-none transition-colors duration-150","focus-visible:ring-2 focus-visible:ring-(--section-accent,#34d399)/70","aria-disabled:pointer-events-none aria-disabled:opacity-40 disabled:pointer-events-none disabled:opacity-40",g?(0,w.cn)(DY[u].icon,"p-0"):DY[u].text,"solid"===s?"border-0 bg-(--section-accent,#10b981) text-white hover:brightness-110":"outline"===s?(0,w.cn)("border border-solid border-(--section-line,rgba(255,255,255,0.12))",i?"bg-(--section-fg,#fff)/12 text-(--section-fg,#fff)":"bg-transparent text-(--section-muted,rgba(255,255,255,0.65)) hover:bg-(--section-fg,#fff)/8 hover:text-(--section-fg,#fff)"):(0,w.cn)("border-0",i?"bg-(--section-fg,#fff)/12 text-(--section-fg,#fff)":"bg-transparent text-(--section-muted,rgba(255,255,255,0.65)) hover:bg-(--section-fg,#fff)/8 hover:text-(--section-fg,#fff)"),y),x=(0,v.jsxs)(v.Fragment,{children:[r,t]});return c?(0,v.jsx)("a",{href:c,target:d,rel:null!=f?f:"_blank"===d?"noreferrer noopener":void 0,title:n,"aria-label":g?n:void 0,"aria-current":i||void 0,"aria-disabled":p||void 0,onClick:m,className:b,children:x}):(0,v.jsx)("button",{type:void 0===h?"button":h,title:n,"aria-label":g?n:void 0,"aria-pressed":i||void 0,disabled:p,onClick:m,className:b,children:x})}var DZ={none:"gap-0",xs:"gap-2",sm:"gap-3",md:"gap-5",lg:"gap-8",xl:"gap-10"},DQ={base:1,md:2,lg:3},DJ=["base","sm","md","lg","xl","2xl"];function D0(e){var t=e.as,r=e.columns,n=void 0===r?DQ:r,a=e.minItemWidth,i=e.gap,o=e.className,s=e.children,l={};if(a)l["--sg-min"]=a;else{var u="number"==typeof n?{base:n}:n,c=!0,d=!1,f=void 0;try{for(var p,h=DJ[Symbol.iterator]();!(c=(p=h.next()).done);c=!0){var m=p.value,y=u[m];"number"==typeof y&&y>0&&(l["--sg-".concat(m)]=String(Math.floor(y)))}}catch(e){d=!0,f=e}finally{try{c||null==h.return||h.return()}finally{if(d)throw f}}}return(0,v.jsx)(void 0===t?"div":t,{"data-section-part":"grid",style:l,className:(0,w.cn)("grid min-w-0",DZ[void 0===i?"md":i],a?"grid-cols-[repeat(auto-fill,minmax(min(100%,var(--sg-min)),1fr))]":(0,w.cn)("grid-cols-[repeat(var(--sg-base,1),minmax(0,1fr))]","sm:grid-cols-[repeat(var(--sg-sm,var(--sg-base,1)),minmax(0,1fr))]","md:grid-cols-[repeat(var(--sg-md,var(--sg-sm,var(--sg-base,1))),minmax(0,1fr))]","lg:grid-cols-[repeat(var(--sg-lg,var(--sg-md,var(--sg-sm,var(--sg-base,1)))),minmax(0,1fr))]","xl:grid-cols-[repeat(var(--sg-xl,var(--sg-lg,var(--sg-md,var(--sg-sm,var(--sg-base,1))))),minmax(0,1fr))]","2xl:grid-cols-[repeat(var(--sg-2xl,var(--sg-xl,var(--sg-lg,var(--sg-md,var(--sg-sm,var(--sg-base,1)))))),minmax(0,1fr))]"),o),children:s})}function D1(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function D2(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return D1(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return D1(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var D3={position:"--section-header-position",top:"--section-sticky-top",zIndex:"--section-sticky-z"};function D4(e){var t=e.sticky,r=e.offset,n=e.zIndex,a={};return void 0!==t&&(a[D3.position]=t?"sticky":"static"),void 0!==r&&(a[D3.top]=r),void 0!==n&&(a[D3.zIndex]=n),a}var D5=(c={},d=D3.position,f="static",d in c?Object.defineProperty(c,d,{value:f,enumerable:!0,configurable:!0,writable:!0}):c[d]=f,c);function D6(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function D8(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function D9(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}var D7={compact:"pb-2",comfortable:"pb-3",spacious:"pb-4"},Ce={compact:"pt-3",comfortable:"pt-4",spacious:"pt-6"},Ct={compact:"mt-3",comfortable:"mt-4",spacious:"mt-6"},Cr={compact:"pt-2",comfortable:"pt-3",spacious:"pt-4"},Cn={sm:"text-base font-medium leading-snug",md:"text-xl font-light leading-tight sm:text-2xl",lg:"text-2xl font-light leading-tight sm:text-3xl"},Ca={split:"flex-wrap items-center justify-between",stacked:"flex-col items-start",centered:"flex-col items-center text-center"},Ci={split:"ml-auto justify-end",stacked:"justify-start",centered:"justify-center"},Co={between:"justify-between",start:"justify-start",center:"justify-center",end:"justify-end"};function Cs(e){var t=e.className,r=Dq().classNames;return(0,v.jsx)("div",{role:"presentation","aria-hidden":"true","data-section-part":"divider",className:(0,w.cn)("h-px w-full shrink-0 bg-(--section-line,rgba(255,255,255,0.12))",r.divider,t)})}function Cl(){var e=Dq(),t=e.collapsed,r=e.toggle,n=e.labels,a=e.bodyId,i=t?n.expand:n.collapse;return(0,v.jsx)("button",{type:"button",onClick:r,title:i,"aria-label":i,"aria-expanded":!t,"aria-controls":a,className:(0,w.cn)("inline-flex size-8 shrink-0 cursor-pointer items-center justify-center rounded-md border-0 p-0","bg-transparent text-(--section-muted,rgba(255,255,255,0.65)) outline-none transition-colors duration-150","hover:bg-(--section-fg,#fff)/10 hover:text-(--section-fg,#fff)","focus-visible:ring-2 focus-visible:ring-(--section-accent,#34d399)/70"),children:(0,v.jsx)("svg",{viewBox:"0 0 16 16",width:"16",height:"16",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",className:(0,w.cn)("transition-transform duration-300 motion-reduce:transition-none",!t&&"rotate-180"),children:(0,v.jsx)("path",{d:"M4 6l4 4 4-4"})})})}function Cu(e){var t,r,n,a,i,o,s,l,u=e.title,c=e.titleAs,d=e.titleSize,f=e.icon,p=e.description,h=e.count,m=e.actions,y=e.children,b=e.layout,x=e.divider,S=e.className,j=Dq(),O=j.classNames,k=j.density,E=j.collapsible,P=null!=b?b:j.headerLayout,A=null!=x?x:j.divider,D=(0,g.useRef)(null),C=(t=j.stickyKey,r=(0,g.useRef)(null),a=(n=D2((0,g.useState)(!1),2))[0],i=n[1],s=(o=D2((0,g.useState)(!1),2))[0],l=o[1],(0,g.useEffect)(function(){var e=D.current;i(!!e&&"sticky"===getComputedStyle(e).position)},[D,t]),(0,g.useEffect)(function(){var e=D.current,t=r.current;if(!a||!e||!t||"u"<typeof IntersectionObserver)return void l(!1);var n=parseFloat(getComputedStyle(e).top)||0,i=new IntersectionObserver(function(e){return l(!D2(e,1)[0].isIntersecting)},{rootMargin:"-".concat(n,"px 0px 0px 0px"),threshold:0});return i.observe(t),function(){return i.disconnect()}},[D,a]),{isSticky:a,stuck:s,sentinelRef:r}),T=C.isSticky,N=C.stuck,R=C.sentinelRef,M=null!=h&&""!==h,I=null!=m&&!1!==m;return(0,v.jsxs)(v.Fragment,{children:[T?(0,v.jsx)("div",{ref:R,"aria-hidden":"true","data-section-part":"sticky-sentinel",className:"pointer-events-none -mb-px h-px w-full shrink-0"}):null,(0,v.jsxs)("div",{ref:D,"data-section-part":"header","data-stuck":T?String(N):void 0,className:(0,w.cn)("flex flex-col","[position:var(--section-header-position,static)] top-(--section-sticky-top,0px) z-(--section-sticky-z,10)","transition-[background-color,box-shadow] duration-200 motion-reduce:transition-none","data-[stuck=true]:bg-(--section-sticky-bg,rgb(8_12_20/0.72)) data-[stuck=true]:backdrop-blur-xl","data-[stuck=true]:shadow-[0_8px_24px_-12px_rgb(0_0_0/0.45)]",O.header,S),children:[(0,v.jsxs)("div",{className:(0,w.cn)("flex gap-x-4 gap-y-2",Ca[P],D7[k]),children:[null!=y?(0,v.jsx)("div",{className:"min-w-0 flex-1",children:y}):(0,v.jsxs)("div",{className:(0,w.cn)("flex min-w-0 flex-col gap-1","split"===P&&"flex-1 basis-48",O.heading),children:[(0,v.jsxs)("div",{className:(0,w.cn)("flex min-w-0 items-center gap-2.5","centered"===P&&"justify-center"),children:[f?(0,v.jsx)("span",{className:(0,w.cn)("inline-flex shrink-0 items-center justify-center text-(--section-accent,#34d399)",O.leading),children:f}):null,u?(0,v.jsx)(void 0===c?"h2":c,{id:j.headingId,className:(0,w.cn)("m-0 min-w-0 text-balance tracking-tight text-(--section-fg,#fff)",Cn[void 0===d?"md":d],O.title),children:u}):null,M?(0,v.jsx)("span",{className:(0,w.cn)("inline-flex h-5 min-w-5 shrink-0 items-center justify-center rounded-full px-1.5","bg-(--section-fg,#fff)/10 text-[11px] font-medium leading-none text-(--section-muted,rgba(255,255,255,0.65))",O.count),children:h}):null]}),p?(0,v.jsx)("p",{className:(0,w.cn)("m-0 max-w-3xl text-sm leading-relaxed text-(--section-muted,rgba(255,255,255,0.65))",O.description),children:p}):null]}),I||E?(0,v.jsxs)("div",{className:(0,w.cn)("flex flex-wrap items-center gap-1.5",Ci[P],null!=y&&"split"===P&&"shrink-0",O.actions),children:[m,E?(0,v.jsx)(Cl,{}):null]}):null]}),A?(0,v.jsx)(Cs,{}):null]})]})}function Cc(e){var t,r=e.children,n=e.flush,a=e.maxHeight,i=e.className,o=Dq(),s=o.classNames,l=o.density,u=o.collapsible,c=o.collapsed,d=o.bodyId,f=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(c))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return D6(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return D6(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),p=f[0],h=f[1],m=(0,g.useRef)(!0);(0,g.useEffect)(function(){if(m.current){m.current=!1;return}h(!0);var e=setTimeout(function(){return h(c)},320);return function(){return clearTimeout(e)}},[c]);var y=(0,v.jsx)("div",{"data-section-part":"body",className:(0,w.cn)("min-w-0",!(void 0!==n&&n)&&Ce[l],a&&"overflow-y-auto overscroll-contain",s.body,i),style:a?D9(D8({},D5),{maxHeight:a}):D5,children:r});return u?(0,v.jsx)("div",D9(D8({id:d,"aria-hidden":c||void 0},c?{inert:""}:{}),{className:(0,w.cn)("grid transition-[grid-template-rows] duration-300 ease-out motion-reduce:transition-none",c?"grid-rows-[0fr]":"grid-rows-[1fr]"),children:(0,v.jsx)("div",{className:(0,w.cn)("min-h-0",p&&"overflow-hidden"),children:y})})):(0,v.jsx)("div",{id:d,children:y})}function Cd(e){var t=e.children,r=e.actions,n=e.layout,a=e.divider,i=e.className,o=Dq(),s=o.classNames,l=o.density,u=o.collapsible,c=o.collapsed,d=null!=n?n:o.footerLayout,f=null!=a?a:o.footerDivider,p=null!=t&&!1!==t,h=null!=r&&!1!==r;return u&&c?null:(0,v.jsxs)("div",{"data-section-part":"footer",className:(0,w.cn)("flex flex-col",Ct[l],s.footer,i),children:[f?(0,v.jsx)(Cs,{}):null,(0,v.jsxs)("div",{className:(0,w.cn)("flex flex-wrap items-center gap-x-4 gap-y-2 text-xs text-(--section-muted,rgba(255,255,255,0.65))",Cr[l],Co[d]),children:[p?(0,v.jsx)("div",{className:(0,w.cn)("min-w-0",s.footerStart),children:t}):null,h?(0,v.jsx)("div",{className:(0,w.cn)("flex flex-wrap items-center gap-1.5","between"===d&&"ml-auto",s.footerEnd),children:r}):null]})]})}function Cf(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var Cp={plain:"",glass:"rounded-2xl p-5 backdrop-blur-xl ring-1 ring-inset ring-(--section-line,rgba(255,255,255,0.12))"},Ch={onDark:"bg-black/40",onLight:"bg-white/70"},Cm=new Set([Cu,Cc,Cd]);function Cy(e){return null!=e&&!1!==e&&""!==e}var Cv=Object.assign(function(e){var t,r=e.id,n=e.as,a=e.ariaLabel,i=e.variant,o=void 0===i?"plain":i,s=e.tone,l=void 0===s?"onDark":s,u=e.density,c=void 0===u?"comfortable":u,d=e.title,f=e.titleAs,p=e.titleSize,h=e.icon,m=e.description,y=e.count,b=e.actions,x=e.header,S=e.headerLayout,j=void 0===S?"split":S,O=e.divider,k=void 0===O||O,E=e.stickyHeader,P=e.stickyOffset,A=e.stickyZIndex,D=e.footer,C=e.footerActions,T=e.footerLayout,N=void 0===T?"between":T,R=e.footerDivider,M=void 0===R||R,I=e.bodyMaxHeight,L=e.bodyFlush,F=e.collapsible,B=void 0!==F&&F,V=e.collapsed,z=e.defaultCollapsed,W=e.onCollapsedChange,$=e.labels,U=e.className,H=e.classNames,G=void 0===H?{}:H,K=e.children,q=(0,g.useId)(),Y="".concat(q,"-title"),X="".concat(q,"-body"),Z=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(void 0!==z&&z))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return Cf(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Cf(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),Q=Z[0],J=Z[1],ee=B&&(null!=V?V:Q),et=(0,g.useCallback)(function(){var e=!ee;void 0===V&&J(e),null==W||W(e)},[ee,V,W]),er=Cy(d),en=(0,g.useMemo)(function(){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},DG,$)},[$]),ea=(0,g.useMemo)(function(){return{tone:l,density:c,classNames:G,labels:en,headerLayout:j,footerLayout:N,divider:k,footerDivider:M,collapsible:B,collapsed:ee,toggle:et,headingId:er?Y:void 0,bodyId:X,stickyKey:"".concat(E,"|").concat(P,"|").concat(A)}},[l,c,G,en,j,N,k,M,B,ee,et,er,Y,X,E,P,A]),ei=er||Cy(m)||Cy(b)||Cy(h)||Cy(x)||null!=y&&""!==y||B,eo=Cy(D)||Cy(C),es=Cy(K),el=g.Children.toArray(K).some(function(e){return(0,g.isValidElement)(e)&&Cm.has(e.type)});return(0,v.jsx)(DK.Provider,{value:ea,children:(0,v.jsxs)(void 0===n?"section":n,{id:r,"aria-label":a,"aria-labelledby":!a&&er?Y:void 0,"data-section-variant":o,style:D4({sticky:E,offset:P,zIndex:A}),className:(0,w.cn)("relative flex w-full min-w-0 flex-col text-(--section-fg,#fff)","onLight"===l&&"[--section-fg:#0f172a] [--section-muted:rgba(15,23,42,0.62)] [--section-line:rgba(15,23,42,0.14)] [--section-sticky-bg:rgb(255_255_255/0.82)]",Cp[o],"glass"===o&&Ch[l],U,G.root),children:[ei?(0,v.jsx)(Cu,{title:d,titleAs:f,titleSize:p,icon:h,description:m,count:y,actions:b,children:x}):null,es?el?K:(0,v.jsx)(Cc,{flush:L,maxHeight:I,children:K}):null,eo?(0,v.jsx)(Cd,{actions:C,children:D}):null]})})},{Header:Cu,Body:Cc,Footer:Cd,Divider:Cs,Action:DX,Grid:D0});function Cg(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}var Cb={none:"gap-0",sm:"gap-4",md:"gap-6",lg:"gap-10",xl:"gap-14"};function Cx(e){var t=e.name,r=e.state,n=e.select,a=e.stickyHeaders,i=e.stickyOffset,o=e.stickyZIndex,s=e.gap,l=e.renderItem,u=e.className,c=e.itemClassName,d=e.style,f=Cg({},D4({sticky:void 0===a||a,offset:void 0===i?"0px":i,zIndex:void 0===o?10:o}),d),p=(0,w.cn)("flex w-full min-w-0 flex-col",Cb[void 0===s?"lg":s],u);return(0,v.jsx)(x.ExtensionSlot,{name:t,select:n,"data-section-slot":t,className:p,style:f,children:function(e){var t=(0,v.jsx)(x.Extension,{state:r}),n={name:e.name,moduleName:e.moduleName,meta:Cg({},e.meta)};return(0,v.jsx)("div",{"data-section-slot-item":e.name,className:(0,w.cn)("min-w-0",c),children:l?l(t,n):t})}})}var Cw=(0,w.cn)("group relative flex min-w-0 flex-col rounded-2xl border border-white/10 bg-slate-900/45 p-4","text-slate-100 shadow-lg backdrop-blur-sm outline-none transition-all duration-300","hover:-translate-y-1 hover:border-teal-400/50 hover:bg-slate-900/75 hover:shadow-2xl","has-[:focus-visible]:ring-2 has-[:focus-visible]:ring-emerald-400");function CS(e){var t,r,n=e.as,a=e.className,i=e.children,o=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["as","className","children"]);return(0,v.jsx)(void 0===n?"div":n,(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-section-card":"",className:(0,w.cn)(Cw,a)},o),r=r={children:i},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))}function Cj(e){var t=e.onClick,r=e.className,n=e.children;return(0,v.jsx)("button",{type:"button",onClick:t,className:(0,w.cn)("block w-full cursor-pointer border-0 bg-transparent p-0 outline-none [color:inherit] [font:inherit] [text-align:inherit]","after:absolute after:inset-0 after:content-['']",r),children:n})}function CO(e){var t,r=e.tile,n=e.size,a=e.onSelect,i=e.className;return(0,v.jsxs)(hz.div,{whileHover:{scale:"large"===n?1.008:1.012},transition:{duration:.2},onClick:function(){return a(r)},role:"button",tabIndex:0,onKeyDown:function(e){("Enter"===e.key||" "===e.key)&&(e.preventDefault(),a(r))},className:["ymvpF0jEa4IAfeIzmv6kDw==","large"===n?"K3WBVZtf0LrRj41QEma6fw==":"Jpm1koqsICGHnsFyzd3FHQ==",null!=i?i:""].join(" "),children:[(0,v.jsx)("img",{src:r.imageUrl,alt:r.title,className:"KeItYJ0V+t2aIAuL4MC2sg==",referrerPolicy:"no-referrer"}),(0,v.jsx)("div",{className:"F77f0L-A-DykD55SIxIydA=="}),(0,v.jsx)("div",{className:"Nneo7LfASPowiNGutwpZMw==",children:"large"===n?(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)("h3",{className:"Z9u0n0R5Gm8ZhupMR8DziQ==",children:r.title}),(0,v.jsx)("span",{className:"_6EhjfpYvyP3bc6qYPrmcQA==",children:null!=(t=r.linkText)?t:"En savoir plus →"})]}):(0,v.jsx)("h4",{className:"BqcB8kB602p8kCOqH3FsDA==",children:r.title})})]})}function Ck(e){var t=e.mainTile,r=e.secondaryTiles,n=e.onSelectTile;return(0,v.jsxs)("div",{className:"tmGbjV2pLbfHuOPqhf-Huw==",children:[(0,v.jsx)(CO,{tile:t,size:"large",onSelect:n}),r.slice(0,4).map(function(e){return(0,v.jsx)(CO,{tile:e,size:"medium",onSelect:n},e.id)})]})}function CE(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function CP(e){if(Array.isArray(e))return e}function CA(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function CD(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function CC(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function CT(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function CN(e,t){return CP(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||CM(e,t)||CA()}function CR(e){return CP(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||CM(e)||CA()}function CM(e,t){if(e){if("string"==typeof e)return CE(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return CE(e,t)}}var CI=(0,g.forwardRef)(function(e,t){var r=e.left,n=e.center,a=e.right,i=e.secondary,o=e.children,s=e.sticky,l=void 0===s||s,u=e.stickyOffset,c=e.variant,d=e.ariaLabel,f=e.className,p=e.wrapperClassName;return(0,v.jsxs)("div",{className:(0,w.cn)("flex flex-col w-full z-(--z-index-sticky,200)",l&&"sticky",p),style:l?{top:void 0===u?"var(--own-offline-banner-height, 0px)":u}:void 0,children:[(0,v.jsxs)("header",{ref:t,role:"banner","aria-label":void 0===d?"Navigation principale":d,className:(0,w.cn)("relative flex w-full items-center justify-between gap-2 px-3 sm:px-4 select-none","h-(--layout-header-height,48px) border-b","border-b-(--panel-header-border,rgba(255,255,255,0.08))","text-(--colors-surface-foreground,#f4f4f4)","glass"===(void 0===c?"glass":c)?"bg-(--panel-header-background,rgba(11,25,44,0.72)) backdrop-blur-xl shadow-(--panel-header-box-shadow,0_1px_12px_rgba(0,0,0,0.25))":"bg-(--colors-surface-card,#0b192c) shadow-(--panel-header-box-shadow,none)",f),children:[(0,v.jsx)("div",{className:"flex min-w-0 shrink-0 items-center gap-2",children:r}),n?(0,v.jsx)("div",{className:"flex min-w-0 flex-1 items-center justify-center gap-2 px-2",children:n}):null,(0,v.jsx)("div",{className:"flex shrink-0 items-center gap-1",children:a}),o]}),i?(0,v.jsx)("div",{className:"w-full",children:i}):null]})}),C_=(0,g.forwardRef)(function(e,t){var r=CR([e,t]),n=r[0],a=r.slice(1),i=n.icon,o=n.label,s=n.badge,l=n.active,u=void 0!==l&&l,c=n.className,d=n.type,f=CT(n,["icon","label","badge","active","className","type"]),p=CN(a,1)[0],h=null!=s&&""!==s&&0!==s;return(0,v.jsxs)("button",CC(CD({ref:p,type:void 0===d?"button":d,title:o,"aria-label":o,"aria-pressed":u||void 0,className:(0,w.cn)("relative inline-flex h-9 min-w-9 cursor-pointer items-center justify-center rounded-md border-0 p-0","bg-transparent text-inherit transition-colors duration-150 outline-none","hover:bg-white/10 focus-visible:ring-2 focus-visible:ring-primary-400",u&&"bg-primary-500/25 text-primary-200",c)},f),{children:[i,h?(0,v.jsx)("span",{className:"absolute -right-0.5 -top-0.5 flex h-4 min-w-4 items-center justify-center rounded-full bg-error-500 px-1 text-[10px] font-bold leading-none text-white",children:s}):null]}))});function CL(e){var t=e.className;return(0,v.jsx)("div",{"aria-hidden":"true",className:(0,w.cn)("mx-1 h-5 w-px bg-white/15",t)})}var CF=(0,g.forwardRef)(function(e,t){var r=CR([e,t]),n=r[0],a=r.slice(1),i=n.src,o=n.name,s=n.active,l=n.className,u=n.type,c=CT(n,["src","name","active","className","type"]),d=CN(a,1)[0],f=o.split(/\s+/).filter(Boolean).slice(0,2).map(function(e){var t;return null==(t=e[0])?void 0:t.toUpperCase()}).join("");return(0,v.jsx)("button",CC(CD({ref:d,type:void 0===u?"button":u,title:o,"aria-label":o,className:(0,w.cn)("relative inline-flex h-8 w-8 cursor-pointer items-center justify-center overflow-hidden rounded-full p-0","border border-primary-400/50 bg-primary-900/40 text-xs font-bold text-white outline-none","transition-transform duration-150 hover:scale-105 focus-visible:ring-2 focus-visible:ring-primary-400",void 0!==s&&s&&"ring-2 ring-primary-400",l)},c),{children:i?(0,v.jsx)("img",{src:i,alt:"",className:"h-full w-full object-cover"}):f}))});function CB(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function CV(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||Cz(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Cz(e,t){if(e){if("string"==typeof e)return CB(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return CB(e,t)}}function CW(e){var t=e.sites,r=e.onSelect,n=e.height,a=e.className,i=(0,g.useRef)(0),o=function(e){return e.map(function(e){return{site:e,key:i.current++}})},s=CV((0,g.useState)(function(){return o(t)}),2),l=s[0],u=s[1],c=CV((0,g.useState)(350),2),d=c[0],f=c[1],p=(0,g.useRef)(!1),h=(0,g.useRef)(0),m=(0,g.useRef)(0);(0,g.useEffect)(function(){return u(o(t))},[t]),(0,g.useEffect)(function(){var e=function(){return f(window.matchMedia("(min-width: 640px)").matches?350:280)};return e(),window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}},[]);var y=function(e){return u(function(t){if(t.length<2)return t;for(var r=function(e){if(Array.isArray(e))return CB(e)}(t)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||Cz(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),n=0;n<Math.abs(e);n++){var a=e>0?r.shift():r.pop();if(!a)break;var o=function(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}(function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},a),{key:i.current++});e>0?r.push(o):r.unshift(o)}return r})},b=function(){var e=m.current-h.current;Math.abs(e)>=45&&y(e<0?1:-1),setTimeout(function(){p.current=!1},50)},x="flex h-12 w-12 sm:h-14 sm:w-14 items-center justify-center border-2 border-white/20 bg-slate-950/80 text-slate-100 transition-colors hover:bg-teal-500 hover:text-slate-950 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-teal-400";return(0,v.jsxs)("div",{onPointerDown:function(e){h.current=m.current=e.clientX,p.current=!1},onPointerMove:function(e){m.current=e.clientX,Math.abs(m.current-h.current)>10&&(p.current=!0)},onPointerUp:b,onPointerCancel:b,className:(0,w.cn)("relative w-full overflow-hidden cursor-grab active:cursor-grabbing touch-pan-y select-none",a),style:{height:void 0===n?500:n},children:[l.map(function(e,t){var n=e.site,a=e.key,i=l.length%2?t-(l.length+1)/2:t-l.length/2,o=0===i;return(0,v.jsxs)("div",{role:"button",tabIndex:o?0:-1,"aria-label":n.name,onKeyDown:function(e){return"Enter"===e.key&&o&&(null==r?void 0:r(n))},onClick:function(){p.current||(o?null==r||r(n):y(i))},className:(0,w.cn)("absolute left-1/2 top-1/2 cursor-pointer border-2 p-7 sm:p-8 transition-all duration-500 ease-in-out",o?"z-10 bg-teal-500 text-slate-950 border-teal-300":"z-0 bg-slate-900/70 text-slate-100 border-white/15 hover:border-teal-400/60"),style:{width:d,height:d,clipPath:"polygon(50px 0%, calc(100% - 50px) 0%, 100% 50px, 100% 100%, calc(100% - 50px) 100%, 50px 100%, 0 100%, 0 0)",transform:"translate(-50%, -50%) translateX(".concat(d/1.5*i,"px) translateY(").concat(o?-30:i%2?20:-10,"px) rotate(").concat(o?0:i%2?2.5:-2.5,"deg)"),boxShadow:o?"0 8px 0 4px rgba(255,255,255,0.14)":"none"},children:[n.imageUrl&&(0,v.jsx)("img",{src:n.imageUrl,alt:"",className:"mb-3 sm:mb-4 h-12 w-10 sm:h-14 sm:w-12 bg-slate-800 object-cover object-top rounded-xs shadow-sm"}),(0,v.jsxs)("h3",{className:"text-sm sm:text-base md:text-lg font-medium leading-snug line-clamp-4",children:[n.name," — ",n.description]}),(0,v.jsxs)("p",{className:(0,w.cn)("absolute bottom-6 sm:bottom-8 left-7 sm:left-8 right-7 sm:right-8 text-xs sm:text-sm italic truncate",o?"text-slate-950/80":"text-slate-400"),children:[n.shortName," • ",n.head," (",n.memberCount," membres, ",n.appCount," apps)"]})]},a)}),(0,v.jsxs)("div",{className:"absolute bottom-3 sm:bottom-4 left-1/2 flex -translate-x-1/2 gap-2 z-20",children:[(0,v.jsx)("button",{type:"button",onClick:function(){return y(-1)},className:x,"aria-label":"Site pr\xe9c\xe9dent",children:(0,v.jsx)(yi,{className:"w-6 h-6"})}),(0,v.jsx)("button",{type:"button",onClick:function(){return y(1)},className:x,"aria-label":"Site suivant",children:(0,v.jsx)(yo,{className:"w-6 h-6"})})]})]})}var C$=(0,ya.A)("SlidersHorizontal",[["line",{x1:"21",x2:"14",y1:"4",y2:"4",key:"obuewd"}],["line",{x1:"10",x2:"3",y1:"4",y2:"4",key:"1q6298"}],["line",{x1:"21",x2:"12",y1:"12",y2:"12",key:"1iu8h1"}],["line",{x1:"8",x2:"3",y1:"12",y2:"12",key:"ntss68"}],["line",{x1:"21",x2:"16",y1:"20",y2:"20",key:"14d8ph"}],["line",{x1:"12",x2:"3",y1:"20",y2:"20",key:"m0wm8r"}],["line",{x1:"14",x2:"14",y1:"2",y2:"6",key:"14e1ph"}],["line",{x1:"8",x2:"8",y1:"10",y2:"14",key:"1i6ji0"}],["line",{x1:"16",x2:"16",y1:"18",y2:"22",key:"1lctlv"}]]),CU=(0,ya.A)("RotateCcw",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]]);function CH(e){var t=e.value,r=e.onChange,n=e.placeholder,a=void 0===n?"Rechercher…":n,i=e.activeFilterCount,o=void 0===i?0:i,s=e.filterPanel,l=e.filtersOpen,u=void 0!==l&&l,c=e.onFiltersOpenChange,d=e.onReset,f=e.className,p=(0,g.useRef)(null),h=!!s&&(u||o>0),m="p-1.5 rounded-lg border border-white/10 text-slate-400 transition-colors cursor-pointer";return(0,v.jsxs)("div",{className:(0,w.cn)("relative rounded-2xl border border-white/15 backdrop-blur-sm shadow-lg overflow-hidden transition-all","focus-within:border-teal-400/80 focus-within:ring-2 focus-within:ring-teal-400/20",f),children:[(0,v.jsxs)("div",{className:"flex items-center px-4 py-2.5 sm:py-3 gap-3",children:[(0,v.jsx)("div",{className:"w-8 h-8 rounded-xl border border-white/10 flex items-center justify-center text-teal-300 shrink-0",children:(0,v.jsx)(O$,{className:"w-4 h-4"})}),(0,v.jsx)("input",{ref:p,type:"text",value:t,onChange:function(e){return r(e.target.value)},placeholder:a,"aria-label":a,className:"flex-1 min-w-0 bg-transparent border-none text-white placeholder-slate-400 text-xs sm:text-sm font-medium focus:outline-none truncate"}),(0,v.jsxs)("div",{className:"flex items-center gap-2 shrink-0",children:[t&&(0,v.jsx)("button",{type:"button",title:"Effacer la recherche",onClick:function(){var e;r(""),null==(e=p.current)||e.focus()},className:(0,w.cn)(m,"hover:bg-white/10 hover:text-white"),children:(0,v.jsx)(kz.A,{className:"w-3.5 h-3.5"})}),s&&(0,v.jsxs)("button",{type:"button",title:"Filtres avanc\xe9s","aria-expanded":h,onClick:function(){return null==c?void 0:c(!u)},className:(0,w.cn)("flex items-center gap-1.5 px-3 py-1.5 rounded-xl border text-xs font-semibold transition-all cursor-pointer",h?"bg-teal-500 text-slate-950 border-teal-400 shadow-sm":"text-slate-300 hover:text-white hover:bg-white/10 border-white/15"),children:[(0,v.jsx)(C$,{className:"w-3.5 h-3.5"}),(0,v.jsx)("span",{className:"hidden sm:inline",children:"Filtres"}),o>0&&(0,v.jsx)("span",{className:"min-w-[1.1rem] rounded-full bg-slate-950 px-1 text-center text-[10px] font-black leading-[1.1rem] text-teal-300",children:o})]}),d&&(t||o>0)&&(0,v.jsx)("button",{type:"button",title:"R\xe9initialiser",onClick:d,className:(0,w.cn)(m,"hover:bg-rose-500/20 hover:text-rose-300"),children:(0,v.jsx)(CU,{className:"w-3.5 h-3.5"})})]})]}),h&&(0,v.jsx)("div",{className:"dark w-full px-4 pb-3 pt-2 border-t border-white/10",children:s})]})}function CG(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function CK(e){var t,r=e.activeTab,n=e.onTabChange,a=e.tabs,i=e.sidebarHeader,o=e.sidebarFooter,s=e.mainHeader,l=e.children,u=e.className,c=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(function(){return"u"<typeof window||window.innerWidth>=768}))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return CG(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return CG(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),d=c[0],f=c[1],p=(0,g.useRef)(null);return(0,g.useEffect)(function(){var e=function(){return f(window.innerWidth>=768)};return window.addEventListener("resize",e),function(){return window.removeEventListener("resize",e)}},[]),(0,v.jsx)("div",{className:(0,w.cn)("w-full h-[calc(100vh-120px)] my-2 sm:my-3 text-slate-100 overflow-hidden px-3 sm:px-6 lg:px-8 flex flex-col",u),children:(0,v.jsxs)("div",{className:"max-w-7xl w-full mx-auto flex-1 min-h-0 flex flex-col md:flex-row items-stretch gap-4 md:gap-8 overflow-hidden",children:[(0,v.jsxs)("aside",{className:"w-full md:w-[20%] shrink-0 min-w-0 flex flex-col justify-start md:justify-center space-y-2 md:space-y-4",children:[i,(0,v.jsx)("div",{ref:p,role:"tablist","aria-orientation":d?"vertical":"horizontal",onKeyDown:function(e){var t,i,o,s=a.filter(function(e){return!e.disabled}),l=s.findIndex(function(e){return e.id===r});e.key===(d?"ArrowDown":"ArrowRight")?o=s[(l+1)%s.length]:e.key===(d?"ArrowUp":"ArrowLeft")?o=s[(l-1+s.length)%s.length]:"Home"===e.key?o=s[0]:"End"===e.key&&(o=s[s.length-1]),o&&(e.preventDefault(),n(o.id),null==(i=p.current)||null==(t=i.querySelector('[data-tab="'.concat(o.id,'"]')))||t.focus())},className:"w-full flex md:flex-col items-center md:items-stretch gap-2 overflow-x-auto touch-pan-x scroll-smooth select-none py-1",children:a.map(function(e){var t=e.id===r;return(0,v.jsxs)("button",{type:"button",role:"tab","data-tab":e.id,"aria-selected":t,tabIndex:t?0:-1,disabled:e.disabled,onClick:function(){return n(e.id)},className:(0,w.cn)("shrink-0 flex items-center gap-2 text-left px-3.5 py-2 text-xs sm:text-sm md:text-base font-medium whitespace-nowrap cursor-pointer transition-all border-0 border-l-2",t?"border-teal-400 text-teal-300 bg-white/5":"border-transparent text-slate-400 hover:text-white",e.disabled&&"opacity-40 cursor-not-allowed"),children:[e.icon&&(0,v.jsx)("span",{className:"shrink-0",children:e.icon}),(0,v.jsx)("span",{children:e.label}),e.badge&&(0,v.jsx)("span",{className:"ml-auto shrink-0",children:e.badge})]},e.id)})}),o]}),(0,v.jsxs)("main",{role:"tabpanel",className:"w-full md:w-[80%] h-full flex-1 min-h-0 flex flex-col overflow-y-auto",children:[s,(0,v.jsx)("div",{className:"flex-1 min-h-0 flex flex-col",children:l})]})]})})}function Cq(e){var t=e.icon,r=e.title,n=e.description,a=e.actions,i=e.className;return(0,v.jsxs)("div",{className:(0,w.cn)("flex flex-col sm:flex-row sm:items-center justify-between gap-3 p-3 rounded-xl bg-slate-900/60 border border-white/10 backdrop-blur-md shrink-0",i),children:[(0,v.jsxs)("div",{className:"min-w-0",children:[(0,v.jsxs)("div",{className:"flex items-center gap-2",children:[t,(0,v.jsx)("h2",{className:"text-sm sm:text-base font-bold text-white truncate",children:r})]}),n&&(0,v.jsx)("p",{className:"text-xs text-slate-400 mt-0.5",children:n})]}),a&&(0,v.jsx)("div",{className:"shrink-0 self-start sm:self-auto",children:a})]})}var CY=(0,ya.A)("ExternalLink",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);function CX(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function CZ(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||CQ(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function CQ(e,t){if(e){if("string"==typeof e)return CX(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return CX(e,t)}}function CJ(e){var t=e.applications,r=e.onOpen,n=e.title,a=e.description,i=e.allLabel,o=void 0===i?"Tous":i,s=e.className,l=CZ((0,g.useState)(""),2),u=l[0],c=l[1],d=CZ((0,g.useState)(o),2),f=d[0],p=d[1],h=(0,g.useMemo)(function(){var e;return[o].concat(function(e){if(Array.isArray(e))return CX(e)}(e=Array.from(new Set(t.map(function(e){return e.category}))))||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||CQ(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())},[t,o]),m=(0,g.useMemo)(function(){var e=u.trim().toLowerCase();return t.filter(function(t){return(f===o||t.category===f)&&(!e||t.name.toLowerCase().includes(e)||t.description.toLowerCase().includes(e))})},[t,u,f,o]);return(0,v.jsxs)("div",{className:(0,w.cn)("space-y-6",s),children:[(0,v.jsxs)("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4 pb-4 border-b border-white/10",children:[(0,v.jsxs)("div",{children:[(0,v.jsx)("h2",{className:"text-xl font-bold text-white",children:void 0===n?"Applications & Outils M\xe9tier":n}),(0,v.jsx)("p",{className:"text-xs text-slate-300 mt-1",children:void 0===a?"S\xe9lectionnez une application pour y acc\xe9der directement.":a})]}),(0,v.jsxs)("div",{className:"relative w-full sm:w-64",children:[(0,v.jsx)(O$,{className:"w-4 h-4 text-slate-400 absolute left-3 top-2.5"}),(0,v.jsx)("input",{type:"text",value:u,onChange:function(e){return c(e.target.value)},placeholder:"Rechercher un outil...","aria-label":"Rechercher un outil",className:"w-full bg-slate-900/80 text-white placeholder-slate-400 text-xs pl-9 pr-3 py-2 rounded-lg border border-white/10 focus:outline-hidden focus:border-teal-400/50"})]})]}),(0,v.jsx)("div",{className:"flex flex-wrap gap-3 text-xs font-medium",children:h.map(function(e){return(0,v.jsx)("button",{type:"button",onClick:function(){return p(e)},className:(0,w.cn)("transition-colors cursor-pointer",f===e?"text-teal-300 font-bold border-b-2 border-teal-400 pb-0.5":"text-slate-400 hover:text-white"),children:e},e)})}),(0,v.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4",children:m.map(function(e){var t,n=e.icon;return(0,v.jsxs)("button",{type:"button",onClick:function(){return r(e)},className:"group text-left p-4 rounded-xl bg-slate-900/60 border border-white/10 hover:border-teal-400/40 hover:bg-slate-800/80 transition-all cursor-pointer flex flex-col justify-between space-y-3",children:[(0,v.jsxs)("div",{className:"space-y-2",children:[(0,v.jsxs)("div",{className:"flex items-center justify-between",children:[(0,v.jsx)("div",{className:(0,w.cn)("p-2 rounded-lg bg-gradient-to-br text-white shadow-xs",null!=(t=e.gradient)?t:"from-teal-500 to-emerald-600"),children:(0,v.jsx)(n,{className:"w-5 h-5"})}),(0,v.jsx)("span",{className:"text-[10px] font-semibold text-slate-400",children:e.status})]}),(0,v.jsxs)("div",{children:[(0,v.jsxs)("h3",{className:"text-sm font-bold text-white group-hover:text-teal-300 transition-colors flex items-center justify-between",children:[(0,v.jsx)("span",{children:e.name}),(0,v.jsx)(CY,{className:"w-3.5 h-3.5 opacity-0 group-hover:opacity-100 transition-opacity text-teal-300"})]}),(0,v.jsx)("p",{className:"text-[11px] text-teal-400/80 font-medium mt-0.5",children:e.category})]}),(0,v.jsx)("p",{className:"text-xs text-slate-300 line-clamp-2 leading-relaxed",children:e.description})]}),(0,v.jsxs)("div",{className:"pt-2 border-t border-white/5 flex items-center justify-between text-[11px] text-slate-400 group-hover:text-slate-200",children:[(0,v.jsx)("span",{children:"Acc\xe9der \xe0 l'application"}),(0,v.jsx)("span",{className:"text-teal-400 font-semibold group-hover:translate-x-1 transition-transform",children:"→"})]})]},e.id)})})]})}var C0=(0,ya.A)("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]),C1={teal:{card:"from-teal-900/50 to-slate-900 border-teal-500/30 hover:border-teal-400",text:"text-teal-300",icon:"text-teal-400"},cyan:{card:"from-cyan-900/50 to-slate-900 border-cyan-500/30 hover:border-cyan-400",text:"text-cyan-300",icon:"text-cyan-400"}};function C2(e){var t=e.resources,r=e.shortcuts,n=void 0===r?[]:r,a=e.onShortcut,i=e.onDownload,o=e.primaryAction,s=e.title,l=e.description,u=e.className;return(0,v.jsxs)("div",{className:(0,w.cn)("space-y-6",u),children:[(0,v.jsxs)("div",{className:"flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4 pb-4 border-b border-white/10",children:[(0,v.jsxs)("div",{children:[(0,v.jsx)("h2",{className:"text-xl font-bold text-white",children:void 0===s?"Ressources Documentaires & GED":s}),(0,v.jsx)("p",{className:"text-xs text-slate-300 mt-1",children:void 0===l?"Guides, formulaires administratifs et acc\xe8s direct \xe0 la Gestion \xc9lectronique des Documents.":l})]}),o]}),n.length>0&&(0,v.jsx)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:n.map(function(e){var t,r=C1[null!=(t=e.tone)?t:"teal"],n=e.icon;return(0,v.jsxs)("button",{type:"button",onClick:function(){return null==a?void 0:a(e)},className:(0,w.cn)("text-left p-4 rounded-xl bg-gradient-to-r border transition-all cursor-pointer flex items-center justify-between",r.card),children:[(0,v.jsxs)("span",{className:"space-y-1",children:[(0,v.jsx)("span",{className:(0,w.cn)("block text-[10px] font-bold uppercase tracking-wider",r.text),children:e.eyebrow}),(0,v.jsx)("span",{className:"block text-sm font-bold text-white",children:e.title}),(0,v.jsx)("span",{className:"block text-xs text-slate-300",children:e.description})]}),(0,v.jsx)(n,{className:(0,w.cn)("w-8 h-8 shrink-0 ml-2",r.icon)})]},e.id)})}),(0,v.jsxs)("div",{className:"space-y-3",children:[(0,v.jsx)("h3",{className:"text-xs font-bold uppercase tracking-wider text-slate-400",children:"Documents r\xe9cents & proc\xe9dures officielles"}),(0,v.jsx)("ul",{className:"space-y-2",children:t.map(function(e){return(0,v.jsxs)("li",{className:"p-3 rounded-lg bg-slate-900/60 border border-white/10 hover:border-teal-400/40 flex items-center justify-between transition-colors",children:[(0,v.jsxs)("div",{className:"flex items-center gap-3 min-w-0",children:[(0,v.jsx)("div",{className:"p-2 rounded-lg bg-white/5 text-teal-300 shrink-0",children:(0,v.jsx)(OQ,{className:"w-4 h-4"})}),(0,v.jsxs)("div",{className:"min-w-0",children:[(0,v.jsx)("h4",{className:"text-xs font-bold text-white truncate",children:e.title}),(0,v.jsxs)("p",{className:"flex flex-wrap items-center gap-1.5 sm:gap-3 text-[10px] text-slate-400 mt-0.5",children:[(0,v.jsx)("span",{className:"text-teal-400 font-semibold",children:e.category}),(0,v.jsx)("span",{children:"•"}),(0,v.jsx)("span",{children:e.type}),(0,v.jsx)("span",{children:"•"}),(0,v.jsx)("span",{children:e.size}),(0,v.jsx)("span",{children:"•"}),(0,v.jsxs)("span",{children:["Mis \xe0 jour le ",e.updated]})]})]})]}),i&&(0,v.jsx)("button",{type:"button",title:"T\xe9l\xe9charger","aria-label":"T\xe9l\xe9charger ".concat(e.title),onClick:function(){return i(e)},className:"p-2 rounded-lg hover:bg-white/10 text-slate-300 hover:text-white transition-colors cursor-pointer shrink-0 ml-2",children:(0,v.jsx)(C0,{className:"w-4 h-4"})})]},e.id)})})]})]})}var C3=(0,ya.A)("List",[["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 18h.01",key:"1tta3j"}],["path",{d:"M3 6h.01",key:"1rqtza"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 18h13",key:"1lx6n3"}],["path",{d:"M8 6h13",key:"ik3vkj"}]]);function C4(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function C5(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return C4(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return C4(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var C6="ABCDEFGHIJKLMNOPQRSTUVWXYZ".split("");function C8(e){var t=e.member,r=e.size;return t.avatar?(0,v.jsx)("img",{src:t.avatar,alt:"",className:(0,w.cn)("rounded-full object-cover border border-white/20 shrink-0",r)}):(0,v.jsx)("span",{className:(0,w.cn)("rounded-full bg-teal-600/40 border border-white/20 flex items-center justify-center font-bold text-teal-100 shrink-0",r),children:t.name.slice(0,1).toUpperCase()})}function C9(e){var t=e.siteName,r=e.members,n=e.teams,a=void 0===n?[]:n,i=e.onSelect,o=e.className,s=C5((0,g.useState)(""),2),l=s[0],u=s[1],c=C5((0,g.useState)("all"),2),d=c[0],f=c[1],p=C5((0,g.useState)(""),2),h=p[0],m=p[1],y=C5((0,g.useState)("grid"),2),b=y[0],x=y[1],S=(0,g.useMemo)(function(){return new Set(r.map(function(e){return e.name.slice(0,1).toUpperCase()}))},[r]),j=(0,g.useMemo)(function(){var e=l.trim().toLowerCase();return r.filter(function(t){return("all"===d||t.teamId===d)&&(!h||t.name.toUpperCase().startsWith(h))&&(!e||[t.name,t.role,t.email,t.phone].some(function(t){return null==t?void 0:t.toLowerCase().includes(e)}))}).sort(function(e,t){return e.name.localeCompare(t.name,"fr")})},[r,l,d,h]),O=function(e){return(0,w.cn)("px-3 py-1 rounded-full border text-xs font-medium whitespace-nowrap transition-colors cursor-pointer",e?"bg-teal-500 text-slate-950 border-teal-400 font-bold":"border-white/15 text-slate-300 hover:text-white hover:bg-white/10")};return(0,v.jsxs)("div",{className:(0,w.cn)("flex-1 min-h-0 flex flex-col gap-3 text-slate-100",o),children:[(0,v.jsx)(Cq,{icon:(0,v.jsx)(OG,{className:"w-4 h-4 text-teal-400"}),title:"Membres & \xc9quipes — ".concat(t),description:"".concat(j.length," membre").concat(j.length>1?"s":""," affich\xe9").concat(j.length>1?"s":""," sur ").concat(r.length),actions:(0,v.jsx)("div",{className:"flex items-center gap-1 bg-white/5 p-1 rounded-lg border border-white/10",children:["grid","list"].map(function(e){return(0,v.jsx)("button",{type:"button","aria-pressed":b===e,"aria-label":"grid"===e?"Vue grille":"Vue liste",onClick:function(){return x(e)},className:(0,w.cn)("p-1.5 rounded-md cursor-pointer",b===e?"bg-teal-500 text-slate-950":"text-slate-300 hover:text-white"),children:"grid"===e?(0,v.jsx)(OF,{className:"w-4 h-4"}):(0,v.jsx)(C3,{className:"w-4 h-4"})},e)})})}),(0,v.jsxs)("div",{className:"relative",children:[(0,v.jsx)(O$,{className:"w-4 h-4 text-slate-400 absolute left-3 top-2.5"}),(0,v.jsx)("input",{type:"text",value:l,onChange:function(e){return u(e.target.value)},placeholder:"Rechercher par nom, fonction, e-mail ou t\xe9l\xe9phone...","aria-label":"Rechercher un membre",className:"w-full bg-slate-900/80 text-white placeholder-slate-400 text-xs pl-9 pr-3 py-2 rounded-lg border border-white/10 focus:outline-hidden focus:border-teal-400/50"})]}),a.length>0&&(0,v.jsxs)("div",{className:"flex gap-2 overflow-x-auto pb-1",children:[(0,v.jsx)("button",{type:"button",className:O("all"===d),onClick:function(){return f("all")},children:"Toutes les \xe9quipes"}),a.map(function(e){return(0,v.jsx)("button",{type:"button",className:O(d===e.id),onClick:function(){return f(e.id)},children:e.name},e.id)})]}),(0,v.jsxs)("div",{className:"flex gap-1 overflow-x-auto text-[11px]","aria-label":"Filtre alphab\xe9tique",children:[(0,v.jsx)("button",{type:"button",className:O(!h),onClick:function(){return m("")},children:"Tous"}),C6.map(function(e){return(0,v.jsx)("button",{type:"button",disabled:!S.has(e),onClick:function(){return m(h===e?"":e)},className:(0,w.cn)(O(h===e),"px-2 disabled:opacity-30 disabled:cursor-not-allowed"),children:e},e)})]}),(0,v.jsx)("div",{className:"flex-1 min-h-0 overflow-y-auto pr-1",children:0===j.length?(0,v.jsx)("p",{className:"text-center py-12 text-slate-400 text-xs",children:"Aucun membre ne correspond \xe0 votre recherche."}):"grid"===b?(0,v.jsx)("ul",{className:"grid grid-cols-1 sm:grid-cols-2 xl:grid-cols-3 gap-3",children:j.map(function(e){return(0,v.jsx)("li",{children:(0,v.jsxs)("button",{type:"button",onClick:function(){return null==i?void 0:i(e)},className:"w-full text-left p-4 rounded-xl bg-slate-900/60 border border-white/10 hover:border-teal-400/40 hover:bg-slate-800/80 transition-all cursor-pointer flex items-center gap-3",children:[(0,v.jsx)(C8,{member:e,size:"w-12 h-12 text-base"}),(0,v.jsxs)("span",{className:"min-w-0",children:[(0,v.jsx)("span",{className:"block text-sm font-bold text-white truncate",children:e.name}),(0,v.jsx)("span",{className:"block text-[11px] text-teal-400/80 truncate",children:e.role}),e.email&&(0,v.jsx)("span",{className:"block text-[11px] text-slate-400 truncate",children:e.email})]})]})},e.id)})}):(0,v.jsx)("ul",{className:"divide-y divide-white/10 rounded-xl border border-white/10 bg-slate-900/60",children:j.map(function(e){return(0,v.jsx)("li",{children:(0,v.jsxs)("button",{type:"button",onClick:function(){return null==i?void 0:i(e)},className:"w-full text-left px-3 py-2 hover:bg-white/5 transition-colors cursor-pointer flex items-center gap-3",children:[(0,v.jsx)(C8,{member:e,size:"w-8 h-8 text-xs"}),(0,v.jsx)("span",{className:"flex-1 min-w-0 text-xs font-semibold text-white truncate",children:e.name}),(0,v.jsx)("span",{className:"hidden sm:block text-[11px] text-teal-400/80 truncate max-w-[40%]",children:e.role}),e.email&&(0,v.jsx)("span",{className:"hidden lg:block text-[11px] text-slate-400 truncate max-w-[30%]",children:e.email})]})},e.id)})})})]})}var C7=(0,ya.A)("SquareCheckBig",[["path",{d:"M21 10.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.5",key:"1uzm8b"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]),Te=(0,ya.A)("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]),Tt=r(3601),Tr=(0,ya.A)("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]),Tn=(0,ya.A)("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);function Ta(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ti(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function To(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function Ts(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Ta(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Ta(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Tl=[{id:"all",label:"Toutes"},{id:"todo",label:"\xc0 faire"},{id:"in_progress",label:"En cours"},{id:"done",label:"Termin\xe9es"}],Tu={haute:{label:"Priorit\xe9 Haute",cls:"bg-rose-500/20 text-rose-300 border-rose-500/30"},moyenne:{label:"Priorit\xe9 Moyenne",cls:"bg-amber-500/20 text-amber-300 border-amber-500/30"},basse:{label:"Priorit\xe9 Normale",cls:"bg-emerald-500/20 text-emerald-300 border-emerald-500/30"}},Tc="w-full px-3 py-1.5 rounded-lg bg-black/40 border border-white/15 text-xs text-white placeholder-slate-500 focus:outline-none focus:border-teal-400";function Td(e){var t=e.siteName,r=e.tasks,n=e.onToggleStatus,a=e.onCreate,i=e.className,o=Ts((0,g.useState)("all"),2),s=o[0],l=o[1],u=Ts((0,g.useState)(""),2),c=u[0],d=u[1],f=Ts((0,g.useState)(!1),2),p=f[0],h=f[1],m=Ts((0,g.useState)({title:"",description:"",priority:"moyenne",dueDate:""}),2),y=m[0],b=m[1],x=(0,g.useMemo)(function(){return{all:r.length,todo:r.filter(function(e){return"todo"===e.status}).length,in_progress:r.filter(function(e){return"in_progress"===e.status}).length,done:r.filter(function(e){return"done"===e.status}).length}},[r]),S=(0,g.useMemo)(function(){var e=c.trim().toLowerCase();return r.filter(function(t){return("all"===s||t.status===s)&&(!e||t.title.toLowerCase().includes(e)||t.description.toLowerCase().includes(e))})},[r,s,c]);return(0,v.jsxs)("div",{className:(0,w.cn)("flex-1 min-h-0 flex flex-col gap-3 text-slate-100",i),children:[(0,v.jsx)(Cq,{icon:(0,v.jsx)(C7,{className:"w-4 h-4 text-teal-400"}),title:"Mes t\xe2ches — ".concat(t),description:"Suivi des livrables, validations documentaires et actions assign\xe9es dans cet espace.",actions:(0,v.jsxs)("button",{type:"button",onClick:function(){return h(!0)},className:"px-3 py-1.5 rounded-lg bg-teal-500 hover:bg-teal-400 text-slate-950 font-bold text-xs flex items-center gap-1.5 shadow-md transition-all active:scale-95 cursor-pointer",children:[(0,v.jsx)(Te,{className:"w-4 h-4"}),(0,v.jsx)("span",{children:"Nouvelle t\xe2che"})]})}),(0,v.jsxs)("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-2",children:[(0,v.jsx)("div",{className:"flex items-center gap-1 bg-white/5 p-1 rounded-xl border border-white/10 text-xs overflow-x-auto",children:Tl.map(function(e){return(0,v.jsxs)("button",{type:"button",onClick:function(){return l(e.id)},className:(0,w.cn)("px-3 py-1 rounded-lg font-medium whitespace-nowrap transition-colors cursor-pointer",s===e.id?"bg-teal-500 text-slate-950 font-bold":"text-slate-300 hover:text-white"),children:[e.label," (",x[e.id],")"]},e.id)})}),(0,v.jsxs)("div",{className:"relative w-full sm:w-64",children:[(0,v.jsx)(O$,{className:"w-3.5 h-3.5 absolute left-3 top-1/2 -translate-y-1/2 text-slate-400"}),(0,v.jsx)("input",{type:"text",value:c,onChange:function(e){return d(e.target.value)},placeholder:"Rechercher une t\xe2che...","aria-label":"Rechercher une t\xe2che",className:"w-full pl-8 pr-3 py-1 rounded-lg bg-slate-900/60 border border-white/10 text-xs text-white placeholder-slate-400 focus:outline-none focus:border-teal-400/80"})]})]}),(0,v.jsx)("div",{className:"flex-1 min-h-0 overflow-y-auto space-y-2 pr-1",children:0===S.length?(0,v.jsxs)("div",{className:"text-center py-12 text-slate-400 text-xs",children:[(0,v.jsx)(Tt.A,{className:"w-8 h-8 mx-auto mb-2 text-slate-500"}),"Aucune t\xe2che ne correspond \xe0 vos filtres."]}):S.map(function(e){return(0,v.jsxs)("div",{className:(0,w.cn)("p-3 rounded-xl border transition-all flex flex-col sm:flex-row items-start sm:items-center justify-between gap-3","done"===e.status?"bg-slate-950/40 border-white/5 opacity-70":"bg-slate-900/60 border-white/10 hover:border-teal-400/40"),children:[(0,v.jsxs)("div",{className:"flex items-start gap-3 flex-1 min-w-0",children:[(0,v.jsxs)("button",{type:"button",onClick:function(){return n(e)},title:"Changer le statut","aria-label":"Changer le statut de ".concat(e.title),className:(0,w.cn)("mt-0.5 w-5 h-5 rounded-md border flex items-center justify-center transition-colors cursor-pointer shrink-0","done"===e.status?"bg-emerald-500 border-emerald-400 text-slate-950":"in_progress"===e.status?"bg-amber-500/20 border-amber-400 text-amber-300":"border-white/20 hover:border-teal-400"),children:["done"===e.status&&(0,v.jsx)(Tr,{className:"w-3.5 h-3.5"}),"in_progress"===e.status&&(0,v.jsx)("span",{className:"w-2 h-2 rounded-full bg-amber-400"})]}),(0,v.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,v.jsx)("h4",{className:(0,w.cn)("text-xs sm:text-sm font-semibold text-white","done"===e.status&&"line-through text-slate-400"),children:e.title}),(0,v.jsx)("p",{className:"text-[11px] text-slate-400 mt-0.5 line-clamp-2",children:e.description}),(0,v.jsxs)("div",{className:"flex flex-wrap items-center gap-2 mt-2 text-[10px]",children:[(0,v.jsxs)("span",{className:"flex items-center gap-1 text-slate-400",children:[(0,v.jsx)(OK,{className:"w-3 h-3"}),e.dueDate]}),(0,v.jsx)("span",{className:"text-white/20",children:"•"}),(0,v.jsxs)("span",{className:"flex items-center gap-1 text-slate-400",children:[(0,v.jsx)(Tn,{className:"w-3 h-3 text-teal-400"}),"Assign\xe9 \xe0 : ",(0,v.jsx)("strong",{className:"text-slate-200",children:e.assignedTo})]}),e.tags.map(function(e){return(0,v.jsx)("span",{className:"px-1.5 rounded bg-white/5 border border-white/10 text-slate-300",children:e},e)})]})]})]}),(0,v.jsxs)("div",{className:"flex sm:flex-col items-center sm:items-end justify-between w-full sm:w-auto gap-1 shrink-0",children:[(0,v.jsx)("span",{className:(0,w.cn)("px-2 py-0.5 rounded-full text-[10px] font-bold uppercase border",Tu[e.priority].cls),children:Tu[e.priority].label}),(0,v.jsx)("span",{className:(0,w.cn)("text-[10px] font-semibold","done"===e.status?"text-emerald-400":"in_progress"===e.status?"text-amber-400":"text-slate-400"),children:"done"===e.status?"✓ Termin\xe9e":"in_progress"===e.status?"● En cours":"○ \xc0 faire"})]})]},e.id)})}),p&&(0,v.jsx)("div",{role:"dialog","aria-modal":"true","aria-label":"Nouvelle t\xe2che",className:"fixed inset-0 z-50 flex items-center justify-center p-4 bg-black/60 backdrop-blur-sm",onKeyDown:function(e){return"Escape"===e.key&&h(!1)},children:(0,v.jsxs)("div",{className:"w-full max-w-md rounded-2xl bg-slate-900 border border-white/20 p-5 shadow-2xl",children:[(0,v.jsxs)("div",{className:"flex items-center justify-between pb-3 border-b border-white/10",children:[(0,v.jsxs)("h3",{className:"font-bold text-sm text-white flex items-center gap-2",children:[(0,v.jsx)(C7,{className:"w-4 h-4 text-teal-400"}),"Nouvelle t\xe2che pour ",t]}),(0,v.jsx)("button",{type:"button","aria-label":"Fermer",onClick:function(){return h(!1)},className:"text-slate-400 hover:text-white cursor-pointer",children:(0,v.jsx)(kz.A,{className:"w-4 h-4"})})]}),(0,v.jsxs)("form",{onSubmit:function(e){e.preventDefault(),y.title.trim()&&(a(To(Ti({},y),{title:y.title.trim(),description:y.description.trim()})),b({title:"",description:"",priority:"moyenne",dueDate:""}),h(!1))},className:"space-y-3 mt-4",children:[(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Titre de la t\xe2che"}),(0,v.jsx)("input",{autoFocus:!0,required:!0,className:Tc,value:y.title,onChange:function(e){return b(To(Ti({},y),{title:e.target.value}))}})]}),(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Description / Consignes"}),(0,v.jsx)("textarea",{rows:3,className:(0,w.cn)(Tc,"resize-none"),value:y.description,onChange:function(e){return b(To(Ti({},y),{description:e.target.value}))}})]}),(0,v.jsxs)("div",{className:"grid grid-cols-2 gap-3",children:[(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Priorit\xe9"}),(0,v.jsxs)("select",{className:Tc,value:y.priority,onChange:function(e){return b(To(Ti({},y),{priority:e.target.value}))},children:[(0,v.jsx)("option",{value:"haute",children:"Haute"}),(0,v.jsx)("option",{value:"moyenne",children:"Moyenne"}),(0,v.jsx)("option",{value:"basse",children:"Basse"})]})]}),(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"\xc9ch\xe9ance"}),(0,v.jsx)("input",{className:Tc,value:y.dueDate,onChange:function(e){return b(To(Ti({},y),{dueDate:e.target.value}))}})]})]}),(0,v.jsxs)("div",{className:"flex items-center justify-end gap-2 pt-3 border-t border-white/10",children:[(0,v.jsx)("button",{type:"button",onClick:function(){return h(!1)},className:"px-3 py-1.5 rounded-lg text-xs text-slate-300 hover:text-white cursor-pointer",children:"Annuler"}),(0,v.jsx)("button",{type:"submit",className:"px-4 py-1.5 rounded-lg bg-teal-500 hover:bg-teal-400 text-slate-950 font-bold text-xs shadow-md active:scale-95 cursor-pointer",children:"Cr\xe9er la t\xe2che"})]})]})]})})]})}var Tf=(0,ya.A)("Activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]),Tp=(0,ya.A)("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]]);function Th(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Tm(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function Ty(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Th(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Th(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Tv=[{id:"all",label:"Tous les \xe9v\xe9nements"},{id:"upload",label:"T\xe9l\xe9versements & GED"},{id:"validate",label:"Validations & Scellements"},{id:"member_join",label:"Habilitations & Membres"},{id:"security",label:"S\xe9curit\xe9 & Audit"}],Tg={upload:{cls:"bg-sky-500",glyph:"↑"},validate:{cls:"bg-emerald-500",glyph:"✓"},member_join:{cls:"bg-amber-500",glyph:"+"},security:{cls:"bg-indigo-500",glyph:"!"},edit:{cls:"bg-teal-500",glyph:"✎"}};function Tb(e){var t=e.siteName,r=e.activities,n=e.onRefresh,a=e.className,i=Ty((0,g.useState)("all"),2),o=i[0],s=i[1],l=Ty((0,g.useState)(!1),2),u=l[0],c=l[1],d=(0,g.useMemo)(function(){return r.filter(function(e){return"all"===o||e.action===o})},[r,o]);return(0,v.jsxs)("div",{className:(0,w.cn)("flex-1 min-h-0 flex flex-col gap-3 text-slate-100",a),children:[(0,v.jsx)(Cq,{icon:(0,v.jsx)(Tf,{className:"w-4 h-4 text-sky-400"}),title:"Activit\xe9 & Journal d'Audit — ".concat(t),description:"Tra\xe7abilit\xe9 en temps r\xe9el des versements, consultations, modifications et habilitations du site.",actions:n&&(0,v.jsxs)("button",{type:"button",disabled:u,onClick:function(){var e;return(e=function(){return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(e){switch(e.label){case 0:c(!0),e.label=1;case 1:return e.trys.push([1,,3,4]),[4,null==n?void 0:n()];case 2:return e.sent(),[3,4];case 3:return c(!1),[7];case 4:return[2]}})},function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){Tm(i,n,a,o,s,"next",e)}function s(e){Tm(i,n,a,o,s,"throw",e)}o(void 0)})})()},className:"px-3 py-1.5 rounded-lg bg-white/5 hover:bg-white/10 border border-white/10 text-slate-200 text-xs flex items-center gap-1.5 transition-colors cursor-pointer disabled:opacity-60",children:[(0,v.jsx)(Tp,{className:(0,w.cn)("w-3.5 h-3.5",u&&"animate-spin text-teal-400")}),(0,v.jsx)("span",{children:"Actualiser le flux"})]})}),(0,v.jsx)("div",{className:"flex items-center gap-1 bg-white/5 p-1 rounded-xl border border-white/10 text-xs overflow-x-auto",children:Tv.map(function(e){return(0,v.jsxs)("button",{type:"button",onClick:function(){return s(e.id)},className:(0,w.cn)("px-3 py-1 rounded-lg font-medium whitespace-nowrap transition-colors cursor-pointer",o===e.id?"bg-sky-500 text-slate-950 font-bold":"text-slate-300 hover:text-white"),children:[e.label,"all"===e.id&&" (".concat(r.length,")")]},e.id)})}),(0,v.jsx)("ul",{className:"flex-1 min-h-0 overflow-y-auto space-y-2 pr-1",children:d.map(function(e){return(0,v.jsxs)("li",{className:"p-3 rounded-xl bg-slate-900/60 border border-white/10 hover:border-sky-400/40 transition-all flex items-start gap-3",children:[(0,v.jsxs)("div",{className:"relative shrink-0",children:[e.userAvatar?(0,v.jsx)("img",{src:e.userAvatar,alt:"",className:"w-8 h-8 rounded-full object-cover border border-white/20"}):(0,v.jsx)("span",{className:"w-8 h-8 rounded-full bg-slate-700 border border-white/20 flex items-center justify-center text-[11px] font-bold",children:e.userName.slice(0,1)}),(0,v.jsx)("span",{"aria-hidden":"true",className:(0,w.cn)("absolute -bottom-1 -right-1 w-4 h-4 rounded-full flex items-center justify-center text-[9px] font-bold text-white border border-slate-950",Tg[e.action].cls),children:Tg[e.action].glyph})]}),(0,v.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,v.jsxs)("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-1",children:[(0,v.jsxs)("p",{className:"text-xs text-white",children:[(0,v.jsx)("strong",{className:"font-semibold text-sky-300",children:e.userName}),(0,v.jsxs)("span",{className:"text-slate-400",children:[" (",e.userRole,") "]}),(0,v.jsx)("span",{className:"text-slate-300",children:e.actionLabel})]}),(0,v.jsx)("span",{className:"text-[10px] text-slate-400 shrink-0 font-mono",children:e.timeAgo})]}),(0,v.jsxs)("div",{className:"mt-1.5 flex items-center gap-2 p-2 rounded-lg bg-black/30 border border-white/5",children:[(0,v.jsx)(OQ,{className:"w-3.5 h-3.5 text-sky-400 shrink-0"}),(0,v.jsx)("span",{className:"text-xs font-semibold text-white truncate",children:e.targetTitle}),(0,v.jsx)("span",{className:"ml-auto text-[9px] px-1.5 rounded bg-white/10 text-slate-300 shrink-0",children:e.targetType})]})]})]},e.id)})})]})}var Tx=(0,ya.A)("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]),Tw=(0,ya.A)("SlidersVertical",[["line",{x1:"4",x2:"4",y1:"21",y2:"14",key:"1p332r"}],["line",{x1:"4",x2:"4",y1:"10",y2:"3",key:"gb41h5"}],["line",{x1:"12",x2:"12",y1:"21",y2:"12",key:"hf2csr"}],["line",{x1:"12",x2:"12",y1:"8",y2:"3",key:"1kfi7u"}],["line",{x1:"20",x2:"20",y1:"21",y2:"16",key:"1lhrwl"}],["line",{x1:"20",x2:"20",y1:"12",y2:"3",key:"16vvfq"}],["line",{x1:"2",x2:"6",y1:"14",y2:"14",key:"1uebub"}],["line",{x1:"10",x2:"14",y1:"8",y2:"8",key:"1yglbp"}],["line",{x1:"18",x2:"22",y1:"16",y2:"16",key:"1jxqpz"}]]),TS=(0,ya.A)("Shield",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]),Tj=(0,ya.A)("HardDrive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]]),TO=(0,ya.A)("Save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]]);function Tk(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function TE(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function TP(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Tk(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Tk(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var TA=[{id:"PUBLIC",label:"Public",hint:"Accessible \xe0 tous les collaborateurs de l'organisation.",icon:OJ},{id:"MODERATED",label:"Mod\xe9r\xe9",hint:"Adh\xe9sion soumise \xe0 l'approbation du gestionnaire du site.",icon:OG},{id:"PRIVATE",label:"Priv\xe9",hint:"Strictement r\xe9serv\xe9 aux membres invit\xe9s manuellement.",icon:Tx}],TD="p-4 rounded-xl bg-slate-900/60 border border-white/10 space-y-3",TC="text-xs font-bold text-teal-300 uppercase tracking-wider flex items-center gap-2",TT="w-full px-3 py-1.5 rounded-lg bg-black/40 border border-white/15 text-xs text-white focus:outline-none focus:border-teal-400";function TN(e){var t=e.label,r=e.hint,n=e.checked,a=e.onChange;return(0,v.jsxs)("label",{className:"flex items-center justify-between gap-3 cursor-pointer",children:[(0,v.jsxs)("span",{children:[(0,v.jsx)("span",{className:"block text-xs font-semibold text-white",children:t}),r&&(0,v.jsx)("span",{className:"block text-[11px] text-slate-400",children:r})]}),(0,v.jsx)("input",{type:"checkbox",checked:n,onChange:function(e){return a(e.target.checked)},className:"w-4 h-4 accent-teal-500 cursor-pointer shrink-0"})]})}function TR(e){var t=e.siteName,r=e.siteUuid,n=e.initialValue,a=e.storage,i=e.onSave,o=e.className,s=TP((0,g.useState)(n),2),l=s[0],u=s[1],c=TP((0,g.useState)(!1),2),d=c[0],f=c[1],p=function(e){return u(function(t){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},t,e)})};return(0,v.jsxs)("div",{className:(0,w.cn)("flex-1 min-h-0 flex flex-col gap-4 text-slate-100 overflow-y-auto pr-1",o),children:[(0,v.jsx)(Cq,{icon:(0,v.jsx)(OU,{className:"w-4 h-4 text-teal-400"}),title:"Param\xe8tres du Site — ".concat(t),description:"Administration de l'espace collaboratif, visibilit\xe9, quotas et politique de s\xe9curit\xe9.",actions:d&&(0,v.jsxs)("span",{role:"status",className:"flex items-center gap-1.5 px-3 py-1 rounded-lg bg-emerald-500/20 border border-emerald-500/30 text-emerald-300 text-xs font-semibold",children:[(0,v.jsx)(Tt.A,{className:"w-4 h-4 text-emerald-400"}),"Param\xe8tres enregistr\xe9s"]})}),(0,v.jsxs)("form",{onSubmit:function(e){var t;return(t=function(){return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(t){switch(t.label){case 0:return e.preventDefault(),[4,i(l)];case 1:return t.sent(),f(!0),setTimeout(function(){return f(!1)},3e3),[2]}})},function(){var e=this,r=arguments;return new Promise(function(n,a){var i=t.apply(e,r);function o(e){TE(i,n,a,o,s,"next",e)}function s(e){TE(i,n,a,o,s,"throw",e)}o(void 0)})})()},className:"space-y-4",children:[(0,v.jsxs)("section",{className:TD,children:[(0,v.jsxs)("h3",{className:TC,children:[(0,v.jsx)(Tw,{className:"w-3.5 h-3.5"}),"Informations g\xe9n\xe9rales"]}),(0,v.jsxs)("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-3",children:[(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Nom public du site"}),(0,v.jsx)("input",{className:TT,value:l.title,onChange:function(e){return p({title:e.target.value})}})]}),(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Identifiant unique (UUID)"}),(0,v.jsx)("input",{readOnly:!0,className:(0,w.cn)(TT,"bg-black/60 border-white/10 text-slate-400 font-mono"),value:r})]})]}),(0,v.jsxs)("label",{className:"block text-xs font-semibold text-slate-300",children:[(0,v.jsx)("span",{className:"block mb-1",children:"Description & mission du site"}),(0,v.jsx)("textarea",{rows:2,className:(0,w.cn)(TT,"resize-none"),value:l.description,onChange:function(e){return p({description:e.target.value})}})]})]}),(0,v.jsxs)("section",{className:TD,children:[(0,v.jsxs)("h3",{className:TC,children:[(0,v.jsx)(TS,{className:"w-3.5 h-3.5"}),"Visibilit\xe9 & acc\xe8s"]}),(0,v.jsx)("div",{role:"radiogroup","aria-label":"Visibilit\xe9",className:"grid grid-cols-1 sm:grid-cols-3 gap-2.5",children:TA.map(function(e){var t=e.id,r=e.label,n=e.hint,a=e.icon;return(0,v.jsxs)("button",{type:"button",role:"radio","aria-checked":l.visibility===t,onClick:function(){return p({visibility:t})},className:(0,w.cn)("p-3 rounded-xl border text-left transition-all cursor-pointer",l.visibility===t?"bg-teal-500/15 border-teal-400 text-white shadow-md":"bg-black/30 border-white/10 text-slate-400 hover:text-white"),children:[(0,v.jsxs)("span",{className:"flex items-center gap-2 mb-1",children:[(0,v.jsx)(a,{className:"w-4 h-4 text-teal-400"}),(0,v.jsx)("span",{className:"font-bold text-xs",children:r})]}),(0,v.jsx)("span",{className:"block text-[11px] text-slate-400",children:n})]},t)})}),(0,v.jsx)(TN,{label:"Autoriser les collaborateurs \xe0 inviter des tiers",hint:"Les collaborateurs r\xe9guliers peuvent proposer de nouveaux membres.",checked:l.allowMemberInvites,onChange:function(e){return p({allowMemberInvites:e})}})]}),(0,v.jsxs)("section",{className:TD,children:[(0,v.jsxs)("h3",{className:TC,children:[(0,v.jsx)(Tj,{className:"w-3.5 h-3.5"}),"Stockage & notifications"]}),a&&(0,v.jsxs)("div",{className:"space-y-1",children:[(0,v.jsxs)("div",{className:"flex justify-between text-xs text-slate-300",children:[(0,v.jsxs)("span",{children:["Espace utilis\xe9 : ",(0,v.jsx)("strong",{children:a.usedLabel})]}),(0,v.jsxs)("span",{children:["Quota allou\xe9 : ",(0,v.jsx)("strong",{children:a.quotaLabel})]})]}),(0,v.jsx)("div",{className:"w-full h-2 rounded-full bg-black/40 overflow-hidden border border-white/10",children:(0,v.jsx)("div",{className:"h-full bg-teal-400 rounded-full",style:{width:"".concat(Math.min(100,Math.max(0,a.percent)),"%")}})})]}),(0,v.jsxs)("div",{className:"pt-2 space-y-2 border-t border-white/10",children:[(0,v.jsx)(TN,{label:"Notifier lors du t\xe9l\xe9versement d'un nouveau document",checked:l.notifyOnUpload,onChange:function(e){return p({notifyOnUpload:e})}}),(0,v.jsx)(TN,{label:"Alerter lors de la validation officielle d'un bordereau",checked:l.notifyOnValidation,onChange:function(e){return p({notifyOnValidation:e})}})]})]}),(0,v.jsx)("div",{className:"flex justify-end pt-2",children:(0,v.jsxs)("button",{type:"submit",className:"px-5 py-2 rounded-xl bg-teal-500 hover:bg-teal-400 text-slate-950 font-bold text-xs flex items-center gap-2 shadow-lg transition-all active:scale-95 cursor-pointer",children:[(0,v.jsx)(TO,{className:"w-4 h-4"}),"Enregistrer les param\xe8tres du site"]})})]})]})}function TM(e){var t=e.title,r=e.subtitle,n=e.avatar,a=e.following,i=e.onToggleFollow,o=e.actions,s=e.className;return(0,v.jsx)("div",{className:(0,w.cn)("w-full bg-teal-700 border-b border-teal-500/30 text-white px-3 sm:px-6 py-2 shadow-xs",s),children:(0,v.jsxs)("div",{className:"max-w-7xl mx-auto flex items-center justify-between gap-2",children:[(0,v.jsxs)("div",{className:"flex items-center gap-2 min-w-0",children:[n&&(0,v.jsx)("div",{className:"w-8 h-8 bg-slate-900/50 border border-teal-300/40 flex items-center justify-center shrink-0",children:n}),(0,v.jsxs)("div",{className:"flex flex-col -space-y-0.5 min-w-0",children:[(0,v.jsx)("h1",{className:"text-sm sm:text-base font-bold tracking-tight leading-tight truncate",children:t}),r&&(0,v.jsx)("p",{className:"text-teal-100/80 text-[10px] sm:text-[11px] leading-none truncate",children:r})]})]}),(0,v.jsxs)("div",{className:"flex items-center gap-2 shrink-0",children:[i&&(0,v.jsxs)("button",{type:"button","aria-pressed":a,onClick:i,className:"flex items-center gap-1.5 px-2.5 py-1 border border-white/30 hover:bg-white/10 text-xs font-semibold transition-colors cursor-pointer",children:[(0,v.jsx)(O2,{className:(0,w.cn)("w-3.5 h-3.5",a&&"fill-amber-300 text-amber-300")}),(0,v.jsx)("span",{className:"hidden sm:inline",children:a?"Suivi":"Suivre"})]}),o]})]})})}var TI={conversation:{id:"conversation",number:"1",name:"Mode Conversation",shortName:"Conversation",tagline:"Comprendre & R\xe9pondre",badgeLabel:"Conv",emoji:"\uD83D\uDCAC",iconName:"MessageSquare",color:{text:"text-sky-400",bg:"bg-sky-500/10",border:"border-sky-500/30",ring:"ring-sky-500/40",badgeBg:"bg-sky-500",badgeText:"text-slate-950",glow:"shadow-sky-500/25",accent:"#38bdf8"},principle:"L'agent comprend et r\xe9pond.",bullets:["Questions & r\xe9ponses","Explications & clarifications","Discussion en langage naturel","Conseil informationnel"],example:"\xab Qu'est-ce que cette fonctionnalit\xe9 ? \xbb"},recherche:{id:"recherche",number:"2",name:"Mode Recherche / Analyse",shortName:"Recherche",tagline:"Chercher, R\xe9cup\xe9rer & Interpr\xe9ter",badgeLabel:"Rech",emoji:"\uD83D\uDD0E",iconName:"Search",color:{text:"text-amber-400",bg:"bg-amber-500/10",border:"border-amber-500/30",ring:"ring-amber-500/40",badgeBg:"bg-amber-400",badgeText:"text-slate-950",glow:"shadow-amber-500/25",accent:"#fbbf24"},principle:"L'agent cherche, r\xe9cup\xe8re et interpr\xe8te de l'information.",bullets:["Recherche dans la base de connaissances","Consultation & extraction documentaire","Analyse et croisement de donn\xe9es","Comparaison & synth\xe8se structur\xe9e"],example:"\xab Trouve les documents concernant ce projet et r\xe9sume-les. \xbb"},action:{id:"action",number:"3",name:"Mode Action",shortName:"Action",tagline:"Agir sur le Syst\xe8me via Outils",badgeLabel:"Act",emoji:"⚙️",iconName:"Zap",color:{text:"text-emerald-400",bg:"bg-emerald-500/10",border:"border-emerald-500/30",ring:"ring-emerald-500/40",badgeBg:"bg-emerald-400",badgeText:"text-slate-950",glow:"shadow-emerald-500/25",accent:"#34d399"},principle:"L'agent agit sur le syst\xe8me \xe0 travers des outils (diff\xe9rence cl\xe9 avec un simple chatbot).",bullets:["Cr\xe9er, modifier, supprimer des contenus","Publier & programmer des diffusions","Appeler des API & int\xe9grations","D\xe9clencher des workflows & automatisations"],example:"\xab Cr\xe9e cette actualit\xe9 et programme sa publication demain. \xbb"},autonome:{id:"autonome",number:"4",name:"Mode Autonome",shortName:"Autonome",tagline:"Orchestration Multi-\xe9tapes vers un Objectif",badgeLabel:"Auto",emoji:"\uD83E\uDD16",iconName:"Cpu",color:{text:"text-purple-400",bg:"bg-purple-500/10",border:"border-purple-500/30",ring:"ring-purple-500/40",badgeBg:"bg-purple-400",badgeText:"text-slate-950",glow:"shadow-purple-500/25",accent:"#c084fc"},principle:"L'agent re\xe7oit un objectif et d\xe9termine lui-m\xeame les \xe9tapes n\xe9cessaires sans guidage pas-\xe0-pas.",bullets:["Planification intelligente de l’objectif","Recherche & analyse autonome","Cr\xe9ation & ex\xe9cution des actions requises","V\xe9rification & production du r\xe9sultat final"],example:"\xab Pr\xe9pare toute la communication de notre \xe9v\xe9nement. \xbb",schema:["Objectif","Planification","Recherche","Analyse","Cr\xe9ation","Actions","V\xe9rification","R\xe9sultat"]}},T_="egen_assistant_mode";function TL(){if("u"<typeof window)return"conversation";try{var e=localStorage.getItem(T_);if(e&&TI[e])return e}catch(e){}return"conversation"}function TF(e){if("u">typeof window)try{localStorage.setItem(T_,e)}catch(e){}}function TB(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function TV(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function Tz(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function TW(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return TB(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return TB(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var T$=["#7C6AF7","#7DD3C7","#E8B4D4"],TU=["#3DBA2E","#F2E62F"],TH="\n#ifdef GL_FRAGMENT_PRECISION_HIGH\nprecision highp float;\n#else\nprecision mediump float;\n#endif\n\nuniform vec2 u_resolution;\nuniform float u_time;\nuniform float u_speed;\nuniform mat3 u_rot;\nuniform float u_blink;\nuniform float u_mode;\nuniform float u_ears;\nuniform vec3 u_body;\nuniform vec3 u_eye;\nuniform vec3 u_c1;\nuniform vec3 u_c2;\nuniform vec3 u_c3;\nuniform vec3 u_ear1;\nuniform vec3 u_ear2;\n\n// ---- Camera ---------------------------------------------------------------\nconst float CAM_DIST = 6.0;\nconst float HALF_VIEW = ".concat("1.3761",";\n\n// ---- Head (local space, +z = face) ----------------------------------------\nconst vec3 HEAD_R = vec3(1.0, 0.74, 0.86);\n\n// ---- Face (decals projected on the head surface) --------------------------\nconst float EYE_X = 0.455;\nconst float EYE_Y = 0.075;\nconst float EYE_RX = 0.118;\nconst float EYE_RY = 0.128;\nconst float LINE_HALF = 0.021;\n\n// ---- Ear-cups (headphones) -------------------------------------------------\nconst vec3 EAR_C = vec3(1.02, -0.10, 0.02);\nconst float EAR_R = 0.385;\nconst float EAR_HT = 0.072;\nconst float EAR_ROUND = 0.045;\nconst float RECESS_R = 0.335;\nconst float RECESS_D = 0.020;\nconst float RING_R = 0.272;\nconst float RING_T = 0.034;\nconst float RING_X = 0.062;\n// cos / sin of the toe-in (cup faces slightly forward)\nconst float EC = 0.9287;\nconst float ES = 0.3709;\n\nfloat hash(vec2 p) {\n return fract(sin(dot(p, vec2(127.1, 311.7))) * 43758.5453123);\n}\n\nfloat noise(vec2 p) {\n vec2 i = floor(p);\n vec2 f = fract(p);\n float a = hash(i);\n float b = hash(i + vec2(1.0, 0.0));\n float c = hash(i + vec2(0.0, 1.0));\n float d = hash(i + vec2(1.0, 1.0));\n vec2 u = f * f * (3.0 - 2.0 * f);\n return mix(a, b, u.x) + (c - a) * u.y * (1.0 - u.x) + (d - b) * u.x * u.y;\n}\n\nfloat fbm(vec2 p) {\n float v = 0.0;\n float a = 0.5;\n mat2 m = mat2(1.6, 1.2, -1.2, 1.6);\n for (int i = 0; i < 5; i++) {\n v += a * noise(p);\n p = m * p;\n a *= 0.5;\n }\n return v;\n}\n\nvec3 wash(vec3 n, float t) {\n vec2 q = n.xy * 2.2 + n.z * 0.85;\n vec2 w1 = vec2(\n fbm(q * 1.4 + vec2(t * 0.22, t * 0.18)),\n fbm(q * 1.4 + vec2(-t * 0.16, t * 0.24) + 4.1)\n );\n q += (w1 - 0.5) * 0.72;\n float f = fbm(q * 2.1 + vec2(0.0, t * 0.12));\n float g = fbm(q * 4.6 - vec2(t * 0.2, 0.0));\n vec3 col = mix(u_c1, u_c2, smoothstep(0.28, 0.72, f));\n return mix(col, u_c3, pow(smoothstep(0.42, 0.9, g), 1.4));\n}\n\nfloat smin(float a, float b, float k) {\n float h = max(k - abs(a - b), 0.0) / k;\n return min(a, b) - h * h * k * 0.25;\n}\n\nfloat smax(float a, float b, float k) {\n return -smin(-a, -b, k);\n}\n\nfloat sdEllipsoid(vec3 p, vec3 r) {\n float k0 = length(p / r);\n float k1 = length(p / (r * r));\n return k0 * (k0 - 1.0) / max(k1, 1e-4);\n}\n\n// Ear frame: x = cup axis (outward, toed-in), (y, z) = radial plane. Mirrored.\nvec3 earFrame(vec3 p) {\n vec3 q = vec3(abs(p.x), p.y, p.z) - EAR_C;\n return vec3(EC * q.x + ES * q.z, q.y, -ES * q.x + EC * q.z);\n}\n\nfloat sdCup(vec3 e) {\n float rr = EAR_ROUND;\n float rad = length(e.yz);\n vec2 w = vec2(rad - EAR_R + rr, abs(e.x) - EAR_HT + rr);\n float d = min(max(w.x, w.y), 0.0) + length(max(w, 0.0)) - rr;\n // shallow recess in the outer face: the rim stays proud around it\n float rec = max(rad - RECESS_R, (EAR_HT - RECESS_D) - e.x);\n return smax(d, -rec, 0.012);\n}\n\nfloat sdRing(vec3 e) {\n vec2 t = vec2(length(e.yz) - RING_R, e.x - RING_X);\n return length(t) - RING_T;\n}\n\n// x = distance to the whole shape, y = distance to the neon ring\nvec2 map(vec3 p) {\n float d = sdEllipsoid(p, HEAD_R);\n float dr = 1e3;\n if (u_ears > 0.5) {\n vec3 e = earFrame(p);\n d = smin(d, sdCup(e), 0.045);\n dr = sdRing(e);\n d = min(d, dr);\n }\n return vec2(d, dr);\n}\n\nvec3 calcNormal(vec3 p) {\n const vec2 k = vec2(1.0, -1.0);\n const float h = 0.0016;\n return normalize(\n k.xyy * map(p + k.xyy * h).x +\n k.yyx * map(p + k.yyx * h).x +\n k.yxy * map(p + k.yxy * h).x +\n k.xxx * map(p + k.xxx * h).x\n );\n}\n\nfloat calcAO(vec3 p, vec3 n) {\n float occ = 0.0;\n float s = 1.0;\n for (int i = 1; i <= 4; i++) {\n float h = 0.045 * float(i);\n occ += (h - map(p + n * h).x) * s;\n s *= 0.72;\n }\n return clamp(1.0 - 2.4 * occ, 0.0, 1.0);\n}\n\nfloat softShadow(vec3 ro, vec3 rd) {\n float res = 1.0;\n float t = 0.05;\n for (int i = 0; i < 22; i++) {\n float h = map(ro + rd * t).x;\n res = min(res, 9.0 * h / t);\n t += clamp(h, 0.02, 0.22);\n if (res < 0.002 || t > 2.6) break;\n }\n return clamp(res, 0.0, 1.0);\n}\n\nvoid main() {\n vec2 uv = (gl_FragCoord.xy / u_resolution.xy) * 2.0 - 1.0;\n float aspect = u_resolution.x / max(u_resolution.y, 1.0);\n uv.x *= aspect;\n\n float kView = HALF_VIEW / CAM_DIST;\n float pixAng = 2.0 * kView / max(u_resolution.y, 1.0);\n\n vec3 rdW = normalize(vec3(uv * kView, -1.0));\n vec3 roW = vec3(0.0, 0.0, CAM_DIST);\n // world -> head space (u_rot is head -> world; v * M == transpose(M) * v)\n vec3 ro = roW * u_rot;\n vec3 rd = rdW * u_rot;\n\n // bounding sphere\n float bnd = 1.55;\n float b = dot(ro, rd);\n float c = dot(ro, ro) - bnd * bnd;\n float disc = b * b - c;\n if (disc < 0.0) {\n gl_FragColor = vec4(0.0);\n return;\n }\n float sq = sqrt(disc);\n float tEnd = -b + sq;\n float t = max(-b - sq, 0.0);\n\n float minD = 1e3;\n float tMin = t;\n float glow = 0.0;\n bool hit = false;\n vec2 m = vec2(1e3);\n\n for (int i = 0; i < 80; i++) {\n vec3 p = ro + rd * t;\n m = map(p);\n float eps = max(0.0007, 0.35 * t * pixAng);\n if (m.x < eps) {\n hit = true;\n break;\n }\n if (m.x < minD) {\n minD = m.x;\n tMin = t;\n }\n float stp = m.x * 0.85;\n glow += exp(-m.y * m.y * 150.0) * stp;\n t += stp;\n if (t > tEnd) break;\n }\n\n vec3 glowCol = mix(u_ear1, u_ear2, 0.5);\n float ga = (u_ears > 0.5) ? (1.0 - exp(-glow * 3.0)) * 0.8 : 0.0;\n\n float cov = 0.0;\n vec3 col = vec3(0.0);\n\n if (hit) {\n cov = 1.0;\n vec3 pl = ro + rd * t;\n vec3 nl = calcNormal(pl);\n vec3 nW = normalize(u_rot * nl);\n vec3 v = -rdW;\n\n // lights are fixed in the world: turning the head re-shades it\n vec3 keyW = normalize(vec3(-0.5, 0.72, 0.78));\n vec3 fillW = normalize(vec3(0.85, 0.05, 0.45));\n vec3 keyL = keyW * u_rot;\n float sh = softShadow(pl + nl * 0.012, keyL);\n float ao = calcAO(pl, nl);\n\n float ndl = dot(nW, keyW);\n float wrap = clamp((ndl + 0.35) / 1.35, 0.0, 1.0);\n float fill = clamp((dot(nW, fillW) + 0.3) / 1.3, 0.0, 1.0);\n float sky = nW.y * 0.5 + 0.5;\n vec3 amb = mix(vec3(0.60, 0.61, 0.64), vec3(0.80, 0.81, 0.84), sky);\n vec3 lightSum = amb * ao\n + vec3(1.0, 0.975, 0.94) * 0.62 * wrap * mix(0.55, 1.0, sh) * (0.55 + 0.45 * ao)\n + vec3(0.82, 0.86, 1.0) * 0.12 * fill * ao;\n\n vec3 hv = normalize(keyW + v);\n float ndh = max(dot(nW, hv), 0.0);\n float specK = (pow(ndh, 64.0) * 0.55 + pow(ndh, 14.0) * 0.10) * sh;\n float ndv = max(dot(nW, v), 0.0);\n float fres = 0.04 + 0.96 * pow(1.0 - ndv, 5.0);\n vec3 refl = reflect(-v, nW);\n vec3 env = mix(vec3(0.30, 0.31, 0.34), vec3(0.96, 0.97, 0.99), smoothstep(-0.25, 0.95, refl.y));\n\n float px = t * pixAng;\n vec3 body = (u_mode > 0.5) ? wash(nl, u_time * u_speed) : u_body;\n\n // ---- ear materials ------------------------------------------------------\n float plate = 0.0;\n float ringMask = 0.0;\n vec3 ringCol = vec3(0.0);\n float spill = 0.0;\n if (u_ears > 0.5) {\n vec3 e = earFrame(pl);\n float rad = length(e.yz);\n float outward = smoothstep(0.02, 0.05, e.x);\n plate = (1.0 - smoothstep(RECESS_R - 0.006 - px, RECESS_R + 0.004 + px, rad)) * outward;\n float dRing = sdRing(e);\n ringMask = 1.0 - smoothstep(0.0, 0.01 + px, dRing);\n float ang = atan(e.z, e.y);\n float gradT = 0.5 + 0.5 * sin(ang + (pl.x > 0.0 ? 0.6 : 2.5));\n vec3 neon = mix(u_ear1, u_ear2, gradT);\n float core = exp(-pow(dRing / RING_T + 1.0, 2.0) * 1.1);\n ringCol = mix(neon, vec3(1.0), 0.40 * core) * (1.05 + 0.08 * sin(u_time * 1.7));\n spill = exp(-max(dRing, 0.0) * 14.0) * outward;\n }\n vec3 plateCol = mix(vec3(0.16, 0.17, 0.20), u_body * 0.22 + vec3(0.07), 0.5);\n body = mix(body, plateCol, plate);\n\n // ---- face decals: eyes + connecting line --------------------------------\n float onFace = smoothstep(0.18, 0.42, pl.z);\n float lid = mix(1.0, 0.10, u_blink);\n float aa = max(px * 1.1, 0.0035);\n vec2 pe = pl.xy - vec2(0.0, EYE_Y);\n vec2 dl = vec2(abs(pe.x) - EYE_X, pe.y) / vec2(EYE_RX, EYE_RY * lid);\n float eyeM = 1.0 - smoothstep(1.0 - aa / EYE_RX, 1.0 + aa / EYE_RX, length(dl));\n float lw = max(LINE_HALF, 0.6 * px);\n float lineM =\n (1.0 - smoothstep(lw - aa, lw + aa, abs(pe.y))) *\n (1.0 - smoothstep(EYE_X - aa, EYE_X + aa, abs(pe.x)));\n float face = clamp(max(eyeM, lineM), 0.0, 1.0) * onFace;\n\n // ---- shade ----------------------------------------------------------------\n vec3 lit = body * lightSum;\n lit += vec3(1.0) * specK * (1.0 - plate * 0.6);\n lit = mix(lit, env * mix(vec3(1.0), body, 0.35), fres * 0.42);\n\n vec3 eyeLit = u_eye * (0.84 + 0.16 * wrap) + vec3(1.0) * specK * 0.42 + env * fres * 0.16;\n col = mix(lit, eyeLit, face);\n\n // neon spills light on the cup face and on the head next to it\n col += mix(u_ear1, u_ear2, 0.5) * spill * 0.34 * (1.0 - face);\n // the ring itself emits: no lighting\n col = mix(col, ringCol, ringMask);\n } else if (minD < 1e2) {\n // anti-aliased silhouette: how close did the ray pass to the surface?\n float r = minD / max(tMin * pixAng, 1e-5);\n cov = 1.0 - smoothstep(0.0, 1.15, r);\n // soft rim colour for the faded edge: reuse the body tone\n vec3 body = (u_mode > 0.5) ? wash(normalize(ro + rd * tMin), u_time * u_speed) : u_body;\n col = body * 0.9;\n }\n\n // neon halo behind / around the ring\n vec3 premul = col * cov + glowCol * ga * (1.0 - cov);\n float a = cov + ga * (1.0 - cov);\n gl_FragColor = vec4(clamp(premul / max(a, 1e-4), 0.0, 1.0), clamp(a, 0.0, 1.0));\n}\n");function TG(){return"u">typeof process&&(null==process.env?void 0:"production")!=="production"}function TK(e){var t=e.replace("#","").trim(),r=Number.parseInt(3===t.length?t.split("").map(function(e){return e+e}).join(""):t.padEnd(6,"0").slice(0,6),16);return Number.isNaN(r)?[.96,.96,.96]:[(r>>16&255)/255,(r>>8&255)/255,(255&r)/255]}function Tq(e,t,r){var n=e.createShader(t);return n?(e.shaderSource(n,r),e.compileShader(n),e.getShaderParameter(n,e.COMPILE_STATUS))?n:(TG()&&console.warn("LiveOrb: shader failed to compile\n",e.getShaderInfoLog(n)),e.deleteShader(n),null):null}function TY(e,t,r,n,a){var i,o,s,l,u="#F4F4F5",c="#09090B",d=0,f=T$,p=TU;return"black"===e?(u="#18181B",c="#F4F4F5"):"webgl"===e?(u=null!=(i=(f=n&&n.length>0?n:T$)[1])?i:T$[1],c="#0C0C10",d=1,p=[null!=(o=f[0])?o:T$[0],null!=(s=f[2])?s:T$[2]]):"custom"===e&&(u=null!=t?t:"#7C5CFF",c=null!=r?r:"#FAFAFA"),a&&a.length>0&&(p=[a[0],null!=(l=a[1])?l:a[0]]),{body:u,eye:c,mode:d,palette:f,ear:p}}function TX(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=TV({variant:"white",interactive:!0,blink:!0,ears:!0},r),a={x:0,y:.06,vx:0,vy:0},i={x:0,y:.06},o=!1,s=e.getContext("webgl",{alpha:!0,antialias:!1,depth:!1,stencil:!1,premultipliedAlpha:!1,powerPreference:"high-performance"});if(!s)return null;var l=Tq(s,s.VERTEX_SHADER,"\nattribute vec2 a_position;\nvoid main() {\n gl_Position = vec4(a_position, 0.0, 1.0);\n}\n"),u=Tq(s,s.FRAGMENT_SHADER,TH);if(!l||!u)return null;var c=s.createProgram();if(!c)return null;if(s.attachShader(c,l),s.attachShader(c,u),s.linkProgram(c),!s.getProgramParameter(c,s.LINK_STATUS))return TG()&&console.warn("LiveOrb: program failed to link\n",s.getProgramInfoLog(c)),null;s.useProgram(c),null==(t=n.onHasGl)||t.call(n,!0);var d=s.createBuffer();s.bindBuffer(s.ARRAY_BUFFER,d),s.bufferData(s.ARRAY_BUFFER,new Float32Array([-1,-1,1,-1,-1,1,-1,1,1,-1,1,1]),s.STATIC_DRAW);var f=s.getAttribLocation(c,"a_position");s.enableVertexAttribArray(f),s.vertexAttribPointer(f,2,s.FLOAT,!1,0,0);var p=function(e){return s.getUniformLocation(c,e)},h=p("u_resolution"),m=p("u_time"),y=p("u_speed"),v=p("u_rot"),g=p("u_blink"),b=p("u_mode"),x=p("u_ears"),w=p("u_body"),S=p("u_eye"),j=p("u_c1"),O=p("u_c2"),k=p("u_c3"),E=p("u_ear1"),P=p("u_ear2");s.disable(s.BLEND);var A=0,D=!0,C=!0,T=performance.now(),N=T,R=T+1800+2400*Math.random(),M=-1e4,I=function(){var t=e.parentElement;if(t){var r=Math.min(window.devicePixelRatio||1,2),n=t.clientWidth,a=t.clientHeight;n<=0||a<=0||(e.width=Math.max(1,Math.floor(n*r)),e.height=Math.max(1,Math.floor(a*r)),e.style.width="".concat(n,"px"),e.style.height="".concat(a,"px"),s.viewport(0,0,e.width,e.height))}};I();var L=new ResizeObserver(I);e.parentElement&&L.observe(e.parentElement);var F="u">typeof IntersectionObserver?new IntersectionObserver(function(e){var t=TW(e,1)[0];C=!t||t.isIntersecting}):null;null==F||F.observe(e);var B=window.matchMedia("(prefers-reduced-motion: reduce)"),V=function(){o=B.matches};V(),B.addEventListener("change",V);var z=function(t){if(n.interactive){var r=e.parentElement;if(r){var a=r.getBoundingClientRect();if(!(a.width<=0)&&!(a.height<=0)){var o=3*Math.max(a.width,a.height)+120,s=t.clientX-(a.left+a.width/2),l=a.top+a.height/2-t.clientY;i.x=Math.tanh(s/o*2.2),i.y=Math.tanh(l/o*2.2)}}}},W=function(e){null===e.relatedTarget&&(i.x=0,i.y=.06)};window.addEventListener("pointermove",z,{passive:!0}),document.addEventListener("mouseout",W);var $=function(e){var t;e.preventDefault(),D=!1,cancelAnimationFrame(A),null==(t=n.onHasGl)||t.call(n,!1)};e.addEventListener("webglcontextlost",$);var U=function(t){if(D){A=requestAnimationFrame(U);var r,l,u=Math.min(.05,Math.max(.001,(t-N)/1e3));if(N=t,C&&!document.hidden){var c,d,f,p,I,L,F,B,V,z=TY(n.variant,n.color,n.eyeColor,n.colors,n.earColors),W=(t-T)/1e3,$=n.interactive?i.x:0,H=n.interactive?i.y:.06;a.vx+=(($-a.x)*130-17*a.vx)*u,a.vy+=((H-a.y)*130-17*a.vy)*u,a.x+=a.vx*u,a.y+=a.vy*u;var G=+!o,K=Math.max(-1,Math.min(1,a.x))+.03*Math.sin(.9*W)*G,q=Math.max(-1,Math.min(1,a.y))+.022*Math.sin(.67*W+1.3)*G;!o&&n.blink&&t>=R&&(M=t,R=t+2200+3800*Math.random());var Y=(t-M)/1e3,X=0;!o&&n.blink&&(Y<.055?X=Y/.055:Y<.1?X=1:Y<.18&&(X=1-(Y-.1)/.08));var Z=TK(z.body),Q=TK(z.eye),J=[0,1,2].map(function(e){var t;return TK(null!=(t=z.palette[e%z.palette.length])?t:T$[e])}),ee=TK(null!=(r=z.ear[0])?r:TU[0]),et=TK(null!=(l=z.ear[1])?l:TU[1]);s.clearColor(0,0,0,0),s.clear(s.COLOR_BUFFER_BIT),s.uniform2f(h,e.width,e.height),s.uniform1f(m,o?0:W),s.uniform1f(y,.55*!o),s.uniformMatrix3fv(v,!1,(c=.62*K,d=-(.4*q),f=-(.09*K),p=Math.cos(c),I=Math.sin(c),L=Math.cos(d),F=Math.sin(d),new Float32Array([p*(B=Math.cos(f))+I*F*(V=Math.sin(f)),L*V,-I*B+p*F*V,-p*V+I*F*B,L*B,I*V+p*F*B,I*L,-F,p*L]))),s.uniform1f(g,X),s.uniform1f(b,z.mode),s.uniform1f(x,+!!n.ears),s.uniform3f(w,Z[0],Z[1],Z[2]),s.uniform3f(S,Q[0],Q[1],Q[2]),s.uniform3f(j,J[0][0],J[0][1],J[0][2]),s.uniform3f(O,J[1][0],J[1][1],J[1][2]),s.uniform3f(k,J[2][0],J[2][1],J[2][2]),s.uniform3f(E,ee[0],ee[1],ee[2]),s.uniform3f(P,et[0],et[1],et[2]),s.drawArrays(s.TRIANGLES,0,6)}}};return A=requestAnimationFrame(U),{setOptions:function(e){n=TV({},n,e)},destroy:function(){var t;D=!1,cancelAnimationFrame(A),L.disconnect(),null==F||F.disconnect(),B.removeEventListener("change",V),window.removeEventListener("pointermove",z),document.removeEventListener("mouseout",W),e.removeEventListener("webglcontextlost",$),null==(t=n.onHasGl)||t.call(n,!1),s.deleteProgram(c),s.deleteShader(l),s.deleteShader(u),s.deleteBuffer(d)}}}function TZ(e){var t=e.resolved,r=e.ears,n=e.interactive,a=(0,g.useRef)(null),i=(0,g.useRef)(null);(0,g.useEffect)(function(){if(n){var e=a.current,t=i.current,r=null==e?void 0:e.parentElement;if(e&&r){var o=function(n){var a=r.getBoundingClientRect();if(!(a.width<=0)&&!(a.height<=0)){var i=3*Math.max(a.width,a.height)+120,o=Math.tanh((n.clientX-(a.left+a.width/2))/i*2.2),s=Math.tanh((a.top+a.height/2-n.clientY)/i*2.2);e.style.transform="translate(".concat((5.5*o).toFixed(2),"%, ").concat((-(3.4*s)).toFixed(2),"%)"),t&&(t.style.transform="translate(".concat((-(1.8*o)).toFixed(2),"%, ").concat((-(1.2*s)).toFixed(2),"%)"))}};return window.addEventListener("pointermove",o,{passive:!0}),function(){return window.removeEventListener("pointermove",o)}}}},[n]);var o=TW(t.ear,2),s=o[0],l=o[1],u="transform 140ms ease-out",c={position:"absolute"},d=Tz(TV({},c),{backgroundColor:t.eye,width:"8.3%",height:"9%",top:"42.9%",borderRadius:"50%"});return(0,v.jsxs)("div",{"data-part":"zoom","aria-hidden":!0,style:Tz(TV({},c),{inset:0,transform:"scale(".concat(1.09,")")}),children:[r?(0,v.jsx)("div",{ref:i,"data-part":"ears","aria-hidden":!0,style:Tz(TV({},c),{inset:0,transition:u}),children:[0,1].map(function(e){return(0,v.jsx)("span",{"data-part":"ear",style:Tz(TV({},c),{borderRadius:"50%",left:0===e?"9%":"79%",top:"37%",width:"12%",height:"30%",background:"linear-gradient(".concat(0===e?135:225,"deg, ").concat(s,", ").concat(l,")"),boxShadow:"0 0 6px ".concat(l,"66, inset 0 0 0 2px #0000001f")}),children:(0,v.jsx)("span",{style:Tz(TV({},c),{borderRadius:"50%",inset:"16% 22%",background:"radial-gradient(circle at 40% 30%, #3b3e45, #15171b)"})})},e)})}):null,(0,v.jsx)("div",{"aria-hidden":!0,"data-part":"head",style:Tz(TV(Tz(TV({},c),{overflow:"hidden",left:"15%",top:"24%",width:"70%",height:"52%",borderRadius:"50%"}),function(e){if(1===e.mode){var t,r,n,a=null!=(t=e.palette[0])?t:T$[0],i=null!=(r=e.palette[1])?r:T$[1],o=null!=(n=e.palette[2])?n:T$[2];return{backgroundImage:"linear-gradient(135deg, ".concat(a,", ").concat(i,", ").concat(o,")")}}return{backgroundColor:e.body}}(t)),{boxShadow:"inset -6px -8px 14px #0000002e, inset 5px 6px 12px #ffffff66"})}),(0,v.jsxs)("div",{ref:a,"aria-hidden":!0,"data-part":"face",style:Tz(TV({},c),{inset:0,transition:u}),children:[(0,v.jsx)("span",{"data-part":"eye",style:Tz(TV({},d),{left:"29.9%"})}),(0,v.jsx)("span",{"data-part":"eye",style:Tz(TV({},d),{left:"61.8%"})}),(0,v.jsx)("span",{"data-part":"line",style:Tz(TV({},c),{backgroundColor:t.eye,left:"34%",width:"32%",height:"1.6%",top:"46.6%",borderRadius:"999px"})})]})]})}function TQ(e){var t=e.className,r=e.size,n=void 0===r?280:r,a=e.label,i=e.variant,o=void 0===i?"white":i,s=e.color,l=e.eyeColor,u=e.colors,c=e.interactive,d=void 0===c||c,f=e.blink,p=void 0===f||f,h=e.ears,m=void 0===h||h,y=e.earColors,b=(0,g.useRef)(null),x=(0,g.useRef)(null),S=TW((0,g.useState)(!1),2),j=S[0],O=S[1];(0,g.useEffect)(function(){var e=b.current;if(e)return x.current=TX(e,{variant:o,color:s,eyeColor:l,colors:u,interactive:d,blink:p,ears:m,earColors:y,onHasGl:O}),function(){var e;null==(e=x.current)||e.destroy(),x.current=null}},[]),(0,g.useEffect)(function(){var e;null==(e=x.current)||e.setOptions({variant:o,color:s,eyeColor:l,colors:u,interactive:d,blink:p,ears:m,earColors:y,onHasGl:O})},[o,s,l,u,d,p,m,y]);var k=TY(o,s,l,u,y);return(0,v.jsxs)("div",{"data-slot":"live-orb",role:"img","aria-label":void 0===a?"Assistant avatar":a,className:(0,w.cn)("relative shrink-0",t),style:{position:"relative",width:n,height:n},children:[j?null:(0,v.jsx)(TZ,{resolved:k,ears:m,interactive:d}),(0,v.jsx)("canvas",{ref:b,className:"absolute inset-0 size-full"})]})}function TJ(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function T0(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function T1(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){T0(i,n,a,o,s,"next",e)}function s(e){T0(i,n,a,o,s,"throw",e)}o(void 0)})}}function T2(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||T3(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function T3(e,t){if(e){if("string"==typeof e)return TJ(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return TJ(e,t)}}function T4(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}function T5(e){var t=e.text,r=T2((0,g.useState)("auto"),2),n=r[0],a=r[1],i=(0,g.useRef)(null);return(0,g.useEffect)(function(){i.current&&a(i.current.offsetWidth)},[t]),(0,v.jsxs)("span",{className:"relative inline-flex items-center justify-center overflow-hidden transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",style:{width:n},children:[(0,v.jsx)("span",{ref:i,className:"invisible whitespace-nowrap px-1",children:t}),(0,v.jsx)("span",{className:"absolute inset-0 flex items-center justify-center whitespace-nowrap animate-in fade-in zoom-in-95 duration-300",children:t},t)]})}function T6(e){var t=e.model,r=e.className,n={"Composer 2.5":"https://cdn.21st.dev/assets/mirror/7d/7dc00bc09f225fcda46cbc9c6b669c69c025a231877d6c17baa6a003f04f02b2.svg","Gemini 3.5 Flash":"https://cdn.21st.dev/assets/mirror/cd/cda2df6631d5fa227de3fa04ed78cf354f910ba92a9f086e7455655c10ad9d09.svg","GPT 5.5":"https://cdn.21st.dev/assets/mirror/b9/b93fa7942be639a1dae60194ff12141145d7d9fd59581582d6ff23335755f19c.svg","Opus 4.8":"https://cdn.21st.dev/assets/mirror/5d/5de1221c77cc91e748066fd642ad0eee1c1fa65328814f5178166f901e599709.svg","GLM 5.2":"https://cdn.21st.dev/assets/mirror/b2/b2a6c0ff63efd8a555edf8a174ea6fcfeca120ac1595a2d461ca11d3ae89276c.svg"};return(0,v.jsx)("img",{src:n[t]||n["GPT 5.5"],alt:t,className:(0,w.cn)("object-contain",{"GPT 5.5":"dark:invert"}[t],r)})}function T8(){return(0,v.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:(0,v.jsx)("path",{d:"M7 12V2M7 2L2.5 6.5M7 2L11.5 6.5",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"})})}function T9(){return(0,v.jsxs)("svg",{width:"13",height:"13",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:[(0,v.jsx)("rect",{x:"5",y:"1",width:"4",height:"7",rx:"2",stroke:"currentColor",strokeWidth:"1.5"}),(0,v.jsx)("path",{d:"M2.75 6.5V7a4.25 4.25 0 0 0 8.5 0v-.5M7 11.25V13",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]})}function T7(){return(0,v.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:(0,v.jsx)("rect",{x:"3.5",y:"3.5",width:"7",height:"7",rx:"1.5",fill:"currentColor"})})}function Ne(){return(0,v.jsx)("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:(0,v.jsx)("path",{d:"M7 2.5V11.5M2.5 7H11.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}function Nt(){return(0,v.jsx)("svg",{width:"9",height:"9",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:(0,v.jsx)("path",{d:"M2.5 2.5L11.5 11.5M11.5 2.5L2.5 11.5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})})}function Nr(e){var t=e.level;return(0,v.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":"true",children:[(0,v.jsx)("rect",{x:"1.5",y:"8",width:"2.5",height:"4.5",rx:"1",fill:"currentColor",className:"transition-opacity duration-300",opacity:1}),(0,v.jsx)("rect",{x:"5.75",y:"5",width:"2.5",height:"7.5",rx:"1",fill:"currentColor",className:"transition-opacity duration-300",opacity:"Medium"===t||"Max Effort"===t?1:.3}),(0,v.jsx)("rect",{x:"10",y:"2",width:"2.5",height:"10.5",rx:"1",fill:"currentColor",className:"transition-opacity duration-300",opacity:"Max Effort"===t?1:.3})]})}function Nn(e){var t=e.attachment,r=e.index,n=e.onRemove,a=e.onOpen,i=e.registerRef,o=T2((0,g.useState)(!1),2),s=o[0],l=o[1],u=(0,g.useRef)(null);return(0,v.jsxs)("button",{ref:function(e){u.current=e,i(t.id,e)},type:"button",onMouseDown:function(e){return e.preventDefault()},onMouseEnter:function(){return l(!0)},onMouseLeave:function(){return l(!1)},onClick:function(e){e.stopPropagation(),u.current&&a(t,u.current.getBoundingClientRect())},style:{animationDelay:"".concat(35*r,"ms"),animationFillMode:"backwards"},className:(0,w.cn)("group relative size-12 shrink-0 overflow-hidden rounded-xl border border-border bg-muted outline-none","transition-transform duration-200 ease-[cubic-bezier(0.175,0.885,0.32,1.275)] hover:scale-[1.04] active:scale-[0.96]","animate-in fade-in slide-in-from-top-3 zoom-in-90 duration-400"),"aria-label":"Open preview of ".concat(t.name),children:[(0,v.jsx)("img",{src:t.url,alt:t.name,className:"size-full object-cover",draggable:!1}),(0,v.jsx)("span",{className:(0,w.cn)("absolute inset-0 flex items-start justify-end bg-black/0 transition-colors duration-200",s&&"bg-black/25"),children:(0,v.jsx)("span",{role:"button",tabIndex:-1,onMouseDown:function(e){e.preventDefault(),e.stopPropagation()},onClick:function(e){e.stopPropagation(),n(t.id)},className:(0,w.cn)("m-1 flex size-4 items-center justify-center rounded-full bg-background/90 text-foreground/70 shadow-sm transition-all duration-200 ease-[cubic-bezier(0.175,0.885,0.32,1.275)] hover:bg-background hover:text-foreground hover:scale-110",s?"opacity-100 scale-100":"opacity-0 scale-50 pointer-events-none"),"aria-label":"Remove ".concat(t.name),children:(0,v.jsx)(Nt,{})})})]})}function Na(e){var t=e.attachment,r=e.originRect,n=e.onClose,a=T2((0,g.useState)("opening"),2),i=a[0],o=a[1],s=T2((0,g.useState)(null),2),l=s[0],u=s[1],c=(0,g.useRef)(null);(0,g.useEffect)(function(){var e=Math.min(.86*window.innerWidth,560),r=Math.min(.78*window.innerHeight,720),n=t.width||800,a=t.height||600,i=Math.min(e/n,r/a,1.6),s=n*i,l=a*i;u({top:(window.innerHeight-l)/2,left:(window.innerWidth-s)/2,width:s,height:l,radius:20});var c=requestAnimationFrame(function(){return o("open")});return function(){return cancelAnimationFrame(c)}},[t]);var d=(0,g.useCallback)(function(){return o("closing")},[]);(0,g.useEffect)(function(){var e=function(e){"Escape"===e.key&&d()};return document.addEventListener("keydown",e),function(){return document.removeEventListener("keydown",e)}},[d]);var f="open"===i,p="closing"===i,h=f&&l?l:{top:r.top,left:r.left,width:r.width,height:r.height,radius:12},m=p?"ease-out":"cubic-bezier(0.175, 0.885, 0.32, 1.275)",y=p?"0.3s":"0.45s",b="top ".concat(y," ").concat(m,", left ").concat(y," ").concat(m,", width ").concat(y," ").concat(m,", height ").concat(y," ").concat(m,", border-radius ").concat(y," ").concat(m);return(0,v.jsxs)("div",{className:"fixed inset-0 z-[100]",onClick:d,role:"dialog","aria-modal":"true",children:[(0,v.jsx)("div",{className:"absolute inset-0 bg-background/70 backdrop-blur-md transition-opacity duration-400",style:{opacity:+!!f}}),(0,v.jsx)("div",{style:{position:"fixed",top:h.top,left:h.left,width:h.width,height:h.height,borderRadius:h.radius,transition:b,overflow:"hidden",boxShadow:f?"0 24px 60px -12px rgb(0 0 0 / 0.35)":"0 0px 0px 0px rgb(0 0 0 / 0)"},className:"bg-muted",onTransitionEnd:function(){"closing"===i&&n()},onClick:function(e){return e.stopPropagation()},children:(0,v.jsx)("img",{ref:c,src:t.url,alt:t.name,className:"size-full object-cover",draggable:!1})}),(0,v.jsx)("button",{type:"button",onClick:d,style:{opacity:+!!f,transform:f?"scale(1)":"scale(0.7)"},className:(0,w.cn)("fixed right-4 top-4 flex size-9 items-center justify-center rounded-full bg-card/90 text-foreground/70 shadow-md backdrop-blur-sm","transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)] hover:bg-card hover:text-foreground",!f&&"pointer-events-none"),children:(0,v.jsx)("span",{className:"scale-150",children:(0,v.jsx)(Nt,{})})})]})}var Ni=g.forwardRef(function(e,t){var r=e.onSubmit,n=e.placeholder,a=void 0===n?"Ask anything":n,i=e.className,o=e.models,s=void 0===o?["GPT 5.5","Opus 4.8","Gemini 3.5 Flash","Composer 2.5","GLM 5.2"]:o,l=e.efforts,u=void 0===l?["Low","Medium","Max Effort"]:l,c=e.defaultValue,d=e.value,f=e.onChange,p=e.maxAttachments,h=void 0===p?6:p,m=T2((0,g.useState)(!1),2),y=m[0],b=m[1],x=T2((0,g.useState)(!1),2),S=x[0],j=x[1],O=T2((0,g.useState)(void 0===c?"":c),2),k=O[0],E=O[1],P=T2((0,g.useState)(s[0]),2),A=P[0],D=P[1],C=T2((0,g.useState)(1),2),T=C[0],N=C[1],R=T2((0,g.useState)(!1),2),M=R[0],I=R[1],L=T2((0,g.useState)([]),2),F=L[0],B=L[1],V=T2((0,g.useState)(null),2),z=V[0],W=V[1],$=T2((0,g.useState)(!1),2),U=$[0],H=$[1],G=T2((0,g.useState)([,,,,,].fill(0)),2),K=G[0],q=G[1],Y=(0,g.useRef)(void 0!==d?d:k),X=(0,g.useRef)(null),Z=(0,g.useRef)(null),Q=(0,g.useRef)(null),J=(0,g.useRef)(null),ee=(0,g.useRef)(null),et=(0,g.useRef)(null),er=T2((0,g.useState)({opacity:0,transform:"translateY(0px) scale(0.95)",transition:"none"}),2),en=er[0],ea=er[1],ei=T2((0,g.useState)(116),2),eo=ei[0],es=ei[1],el=T2((0,g.useState)(68),2),eu=el[0],ec=el[1],ed=T2((0,g.useState)(!1),2),ef=ed[0],ep=ed[1],eh=void 0!==d,em=eh?d:k,ey=""!==em.trim()||F.length>0,ev=F.length>0,eg=(0,g.useRef)(null),eb=(0,g.useRef)(null),ex=(0,g.useRef)(null),ew=(0,g.useRef)(null),eS=(0,g.useRef)(null),ej=(0,g.useRef)(new Map);(0,g.useEffect)(function(){Y.current=em},[em]);var eO=function(){var e=eg.current;if(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;ex.current&&(ex.current.style.opacity=Math.min(t/20,1).toString()),ew.current&&(ew.current.style.opacity=Math.min(Math.max(r-n-t-16,0)/10,1).toString())}},ek=(0,g.useCallback)(function(e){j(!0),eh||E(e),null==f||f(e)},[eh,f]),eE=(0,g.useCallback)(function(){J.current&&(J.current.stop(),J.current=null),Q.current&&(cancelAnimationFrame(Q.current),Q.current=null),X.current&&(X.current.getTracks().forEach(function(e){return e.stop()}),X.current=null),Z.current&&(Z.current.close(),Z.current=null),ee.current&&(window.clearInterval(ee.current),ee.current=null),et.current&&(window.clearInterval(et.current),et.current=null),H(!1),q([,,,,,].fill(0))},[]),eP=(0,g.useCallback)(function(){return T1(function(){var e,t,r,n,a,i,o,s;function l(){var e="Can you build a high fidelity Framer Motion layout animation for a dark mode dashboard?".split(" "),t=0,r=Y.current;et.current=window.setInterval(function(){t<e.length?(ek(r=(r?r+" ":"")+e[t]),t++):eE()},300)}return T4(this,function(u){switch(u.label){case 0:j(!1),b(!0),e=null,u.label=1;case 1:if(u.trys.push([1,4,,5]),!(navigator.mediaDevices&&navigator.mediaDevices.getUserMedia))return[3,3];return[4,navigator.mediaDevices.getUserMedia({audio:!0})];case 2:e=u.sent(),u.label=3;case 3:return[3,5];case 4:return u.sent(),console.warn("Microphone access denied or unavailable. Falling back to simulated voice mode for demo."),[3,5];case 5:return H(!0),e?(X.current=e,Z.current=t=new(window.AudioContext||window.webkitAudioContext),(r=t.createAnalyser()).fftSize=64,t.createMediaStreamSource(e).connect(r),n=new Uint8Array(r.frequencyBinCount),(a=function(){r.getByteFrequencyData(n);for(var e=[,,,,,].fill(0),t=Math.floor(n.length/5),i=0;i<5;i++){for(var o=0,s=0;s<t;s++)o+=n[i*t+s];e[i]=o/t/255}q(e),Q.current=requestAnimationFrame(a)})(),(i=window.SpeechRecognition||window.webkitSpeechRecognition)?((o=new i).continuous=!0,o.interimResults=!0,s=Y.current,o.onresult=function(e){for(var t="",r="",n=e.resultIndex;n<e.results.length;++n)e.results[n].isFinal?r+=e.results[n][0].transcript:t+=e.results[n][0].transcript;r&&(s+=(s?" ":"")+r),ek((s+(t?" "+t:"")).trim())},o.onerror=function(e){console.error("Speech recognition error",e),eE()},o.onend=function(){eE()},J.current=o,o.start()):(console.warn("Speech Recognition API not supported in this browser. Using simulated text."),l())):(ee.current=window.setInterval(function(){q(Array.from({length:5},function(){return .8*Math.random()+.1}))},100),l()),[2]}})})()},[ek,eE]);(0,g.useEffect)(function(){U&&eg.current&&(eg.current.scrollTop=eg.current.scrollHeight)},[em,U]),(0,g.useEffect)(function(){return function(){eE(),F.forEach(function(e){return URL.revokeObjectURL(e.url)})}},[eE,F]),(0,g.useEffect)(function(){(""!==em.trim()||ev)&&!y&&(j(!1),b(!0))},[em,y,ev]),(0,g.useEffect)(function(){if(y&&!U){var e=setTimeout(function(){if(eg.current){eg.current.focus();var e=eg.current.value.length;eg.current.setSelectionRange(e,e)}},50);return function(){return clearTimeout(e)}}},[y,U]),(0,g.useEffect)(function(){if(eg.current){var e=eg.current,t=e.style.height;e.style.transition="none",e.style.height="0px";var r=e.scrollHeight;e.style.height=t,e.offsetHeight,e.style.transition="";var n=Math.max(68,Math.min(r,160));e.style.height="".concat(n,"px"),ec(n),ep(r>160),setTimeout(eO,0)}},[em,y]),(0,g.useEffect)(function(){es(Math.max(116,eu+48)),setTimeout(eO,0)},[eu]),(0,g.useEffect)(function(){if(M){var e=function(e){eb.current&&!eb.current.contains(e.target)&&I(!1)};return document.addEventListener("mousedown",e),function(){return document.removeEventListener("mousedown",e)}}},[M]);var eA=function(){(""!==em.trim()||ev)&&(j(!1),null==r||r(em,{model:A,effort:u[T],attachments:F.map(function(e){return e.file})}),ek(""),F.forEach(function(e){return URL.revokeObjectURL(e.url)}),B([]),b(!1),I(!1))},eD=function(e,t,r,n){var a="".concat(e.name,"-").concat(e.lastModified,"-").concat(Math.random().toString(36).slice(2,8));B(function(i){return((function(e){if(Array.isArray(e))return TJ(e)})(i)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(i)||T3(i)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([{id:a,file:e,url:t,name:e.name,width:r,height:n}])})},eC=function(e){j(!0),B(function(t){var r=t.find(function(t){return t.id===e});return r&&URL.revokeObjectURL(r.url),t.filter(function(t){return t.id!==e})}),ej.current.delete(e)},eT=ey&&!U,eN=!ey&&!U;return(0,v.jsxs)(v.Fragment,{children:[(0,v.jsxs)("div",{ref:function(e){"function"==typeof t?t(e):t&&(t.current=e),eb.current=e},onBlur:function(e){!(eb.current&&eb.current.contains(e.relatedTarget))&&(""!==em.trim()||ev||U||(j(!1),b(!1),I(!1)))},className:(0,w.cn)("relative flex flex-col w-full",i),style:{maxWidth:"100%",transition:S?"max-width 0.15s ease-out":"max-width 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"},children:[(0,v.jsx)("input",{ref:eS,type:"file",accept:"image/*",multiple:!0,onChange:function(e){return T1(function(){var t,r,n,a,i,o,s,l,u,c;return T4(this,function(d){if(!(t=e.target.files)||(r=Array.from(t).filter(function(e){return e.type.startsWith("image/")}),e.target.value="",0===r.length))return[2];n=Math.max(0,h-F.length),a=r.slice(0,n),y?j(!0):(j(!1),b(!0)),i=!0,o=!1,s=void 0;try{for(l=function(){var e=c.value,t=URL.createObjectURL(e),r=new Image;r.onload=function(){return eD(e,t,r.naturalWidth,r.naturalHeight)},r.onerror=function(){return eD(e,t,800,600)},r.src=t},u=a[Symbol.iterator]();!(i=(c=u.next()).done);i=!0)l()}catch(e){o=!0,s=e}finally{try{i||null==u.return||u.return()}finally{if(o)throw s}}return[2]})})()},className:"hidden",tabIndex:-1,"aria-hidden":"true"}),(0,v.jsx)("div",{"aria-hidden":!ev,style:{height:ev&&y?68:0,transition:S?"height 0.15s ease-out":"height 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"},className:"w-full relative z-0 overflow-hidden",children:(0,v.jsx)("div",{style:{position:"absolute",bottom:-8,left:20,right:20,height:68,transform:ev&&y?"translateY(0)":"translateY(100%)",opacity:ev&&y?1:0,transition:S?"transform 0.15s ease-out, opacity 0.15s ease-out":"transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease-out"},className:"border border-border border-b-0 bg-muted rounded-t-2xl px-2 pt-2 pb-1 flex items-start gap-2 overflow-x-auto prompt-scrollbar",children:F.map(function(e,t){return(0,v.jsx)(Nn,{attachment:e,index:t,onRemove:eC,onOpen:function(e,t){return W({attachment:e,rect:t})},registerRef:function(e,t){return ej.current.set(e,t)}},e.id)})})}),(0,v.jsxs)("div",{onMouseDown:function(e){var t,r=e.target===eg.current;!y||r||U||(e.preventDefault(),null==(t=eg.current)||t.focus())},style:{borderRadius:24,height:y?eo:48,transition:S?"max-width 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), height 0.15s ease-out":"max-width 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), height 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)",overflow:y?"visible":"hidden"},className:(0,w.cn)("relative w-full border border-border bg-card shadow-sm focus-within:border-ring/40 focus-within:ring-1 focus-within:ring-ring/20 hover:border-border/80 z-10",y?"cursor-text":"cursor-default"),children:[(0,v.jsx)("style",{dangerouslySetInnerHTML:{__html:"\n .prompt-scrollbar::-webkit-scrollbar { width: 4px; height: 4px; background: transparent; }\n .prompt-scrollbar::-webkit-scrollbar-track { background: transparent; }\n .prompt-scrollbar::-webkit-scrollbar-thumb { background: transparent; border-radius: 4px; }\n .prompt-scrollbar:hover::-webkit-scrollbar-thumb { background: hsl(var(--muted-foreground) / 0.3); }\n "}}),(0,v.jsx)("textarea",{ref:eg,value:em,onChange:function(e){return ek(e.target.value)},onScroll:eO,onKeyDown:function(e){"Enter"!==e.key||e.shiftKey||(e.preventDefault(),eA()),"Escape"!==e.key||""!==em.trim()||ev||(j(!1),b(!1),I(!1))},placeholder:a,"aria-label":"Prompt",disabled:U,style:{transition:S?"height 0.15s ease-out":"opacity 0.3s ease-out, transform 0.3s ease-out, height 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"},className:(0,w.cn)("prompt-scrollbar absolute top-0 inset-x-0 z-[1] w-full resize-none bg-transparent pl-4 pr-12 py-3.5 text-sm leading-[22px] text-foreground outline-none placeholder:font-medium placeholder:text-muted-foreground/80 cursor-text",y?"opacity-100 scale-100 translate-y-0":"opacity-0 scale-95 -translate-y-1 pointer-events-none",ef?"overflow-y-auto":"overflow-y-hidden",U&&"pointer-events-none")}),(0,v.jsx)("div",{ref:ex,className:"absolute left-4 right-12 top-0 z-[2] h-8 bg-gradient-to-b from-card via-card/90 to-transparent pointer-events-none"}),(0,v.jsx)("div",{ref:ew,className:"absolute left-4 right-12 z-[2] h-8 bg-gradient-to-t from-card via-card/90 to-transparent pointer-events-none",style:{opacity:0,top:"".concat(eu-32,"px"),transition:S?"top 0.15s ease-out":"top 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"}}),(0,v.jsx)("button",{type:"button",onClick:function(){j(!1),b(!0)},style:{transition:S?"none":"all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275)"},className:(0,w.cn)("absolute inset-x-0 top-0 z-[1] cursor-text pl-4 pr-12 py-[15px] text-left text-sm font-medium leading-[17px] text-muted-foreground/80 outline-none truncate",y?"opacity-0 scale-105 translate-y-1 pointer-events-none":"opacity-100 scale-100 translate-y-0"),"aria-label":"Open prompt input",children:a}),(0,v.jsxs)("div",{className:(0,w.cn)("absolute bottom-2 left-3 right-12 z-[10] flex items-center gap-0 transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",y&&!U?"opacity-100 blur-0 translate-y-0 pointer-events-auto":"opacity-0 blur-sm translate-y-2 pointer-events-none"),children:[(0,v.jsxs)("div",{className:"relative",children:[(0,v.jsxs)("button",{type:"button",onMouseDown:function(e){return e.preventDefault()},onClick:function(e){e.stopPropagation(),I(function(e){return!e})},className:(0,w.cn)("group flex items-center gap-1 rounded-full px-2 py-1 text-foreground/50 transition-all duration-200 outline-none hover:bg-accent/60 hover:text-foreground cursor-default",M?"bg-accent/60 text-foreground":""),"aria-label":"Select model. Current: ".concat(A),children:[(0,v.jsx)(T6,{model:A,className:"size-3.5 opacity-70 group-hover:opacity-100 transition-opacity"}),(0,v.jsx)("span",{className:"text-xs font-semibold select-none transition-colors",children:(0,v.jsx)(T5,{text:A})})]}),(0,v.jsx)("div",{style:{transformOrigin:"bottom left"},onMouseLeave:function(){ea(function(e){var t,r;return t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},e),r=r={opacity:0,transform:e.transform.replace("scale(1)","scale(0.95)"),transition:"opacity 0.2s ease-in, transform 0.2s ease-out"},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t})},className:(0,w.cn)("absolute bottom-full left-0 mb-2.5 z-50 w-44 rounded-2xl border border-border bg-card/95 p-1 shadow-xl backdrop-blur-md flex flex-col gap-0.5 transition-all duration-400 cursor-default",M?"opacity-100 scale-100 translate-y-0 pointer-events-auto ease-[cubic-bezier(0.34,1.56,0.64,1)]":"opacity-0 scale-95 translate-y-3 pointer-events-none ease-[cubic-bezier(0.175,0.885,0.32,1.275)]"),children:(0,v.jsxs)("div",{className:"relative flex flex-col gap-0.5",children:[(0,v.jsx)("div",{style:en,className:"absolute left-0 right-0 top-0 h-8 -z-10 rounded-xl bg-accent pointer-events-none"}),s.map(function(e,t){return(0,v.jsx)("button",{type:"button",onMouseDown:function(e){return e.preventDefault()},onMouseEnter:function(){ea(function(e){return{opacity:1,transform:"translateY(".concat(34*t,"px) scale(1)"),transition:0===e.opacity?"opacity 0.15s ease-out":"transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.15s ease"}})},onClick:function(t){t.stopPropagation(),D(e),I(!1)},className:"group relative flex h-8 w-full items-center justify-between rounded-xl px-2.5 py-1.5 text-left text-xs font-medium text-foreground/80 outline-none active:scale-[0.98] cursor-default",children:(0,v.jsxs)("span",{className:"flex items-center gap-2",children:[(0,v.jsx)(T6,{model:e,className:"size-3.5 opacity-85 group-hover:opacity-100 transition-opacity"}),e]})},e)})]})})]}),(0,v.jsxs)("button",{type:"button",onMouseDown:function(e){return e.preventDefault()},onClick:function(e){e.stopPropagation(),N(function(e){return(e+1)%u.length})},className:"group flex items-center gap-1 rounded-full px-2 py-1 text-foreground/50 transition-all duration-200 hover:bg-accent/60 hover:text-foreground outline-none cursor-default",children:[(0,v.jsx)(Nr,{level:u[T]}),(0,v.jsx)("span",{className:"text-xs font-semibold select-none transition-colors",children:(0,v.jsx)(T5,{text:u[T]})})]}),(0,v.jsx)("button",{type:"button",onMouseDown:function(e){return e.preventDefault()},onClick:function(e){var t;e.stopPropagation(),null==(t=eS.current)||t.click()},disabled:F.length>=h,className:"ml-auto flex size-7 items-center justify-center rounded-full text-foreground/50 transition-all duration-200 hover:bg-accent/60 hover:text-foreground outline-none cursor-default disabled:opacity-40 disabled:pointer-events-none",children:(0,v.jsx)(Ne,{})})]}),(0,v.jsx)("div",{className:(0,w.cn)("absolute right-12 bottom-2 z-[10] flex h-8 items-center justify-end gap-[3px] transition-all duration-400 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",U?"w-16 opacity-100 translate-x-0":"w-0 opacity-0 translate-x-4 pointer-events-none"),children:K.map(function(e,t){return(0,v.jsx)("div",{className:"w-1 rounded-full bg-primary transition-[height] duration-75 ease-out",style:{height:"".concat(Math.max(4,24*e),"px")}},t)})}),(0,v.jsx)("button",{type:"button",onMouseDown:function(e){e.preventDefault(),e.stopPropagation()},onClick:function(e){e.preventDefault(),U?eE():ey?eA():eP()},"aria-label":eT?"Send prompt":U?"Stop recording":"Use voice input",style:{borderRadius:9999},className:"absolute right-2 bottom-2 z-[10] flex h-8 w-8 items-center justify-center bg-primary text-primary-foreground transition-all duration-300 hover:opacity-90 outline-none focus-visible:ring-2 focus-visible:ring-ring cursor-default",children:(0,v.jsxs)("span",{className:"relative flex h-full w-full items-center justify-center",children:[(0,v.jsx)("span",{className:(0,w.cn)("absolute inset-0 flex items-center justify-center transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",eT?"opacity-100 scale-100 rotate-0 blur-none":"opacity-0 scale-50 rotate-45 blur-[1px] pointer-events-none"),children:(0,v.jsx)(T8,{})}),(0,v.jsx)("span",{className:(0,w.cn)("absolute inset-0 flex items-center justify-center transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",eN?"opacity-100 scale-100 rotate-0 blur-none":"opacity-0 scale-50 -rotate-45 blur-[1px] pointer-events-none"),children:(0,v.jsx)(T9,{})}),(0,v.jsx)("span",{className:(0,w.cn)("absolute inset-0 flex items-center justify-center transition-all duration-300 ease-[cubic-bezier(0.175,0.885,0.32,1.275)]",U?"opacity-100 scale-100 rotate-0 blur-none":"opacity-0 scale-50 rotate-45 blur-[1px] pointer-events-none"),children:(0,v.jsx)(T7,{})})]})})]})]}),z&&(0,v.jsx)(Na,{attachment:z.attachment,originRect:z.rect,onClose:function(){return W(null)}})]})});Ni.displayName="PromptInput";var No=r(3766);function Ns(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var Nl=(0,g.lazy)(function(){return r.e("1808").then(r.bind(r,339))}),Nu=new Set;function Nc(e){if(!("u"<typeof document||(0,No.$)()||Nu.has(e))){Nu.add(e);var t=document.createElement("link");t.rel="preload",t.as="fetch",t.crossOrigin="anonymous",t.href=e,document.head.appendChild(t)}}function Nd(e){var t,r=e.scene,n=e.className,a=void 0===n?"w-full h-full":n,i=e.onLoad,o=function(e){if(Array.isArray(e))return e}(t=(0,g.useState)(!1))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return Ns(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return Ns(e,2)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),s=o[0],l=o[1];return(0,No.$)()?(0,v.jsx)("div",{className:"relative ".concat(a," overflow-hidden"),"data-egen-3d":"unavailable","data-testid":"spline-unavailable","aria-hidden":"true"}):(0,v.jsxs)("div",{className:"relative ".concat(a," overflow-hidden"),children:[!s&&(0,v.jsxs)("div",{className:"absolute inset-0 z-10 flex flex-col items-center justify-center bg-[#030708] text-teal-400 gap-3 transition-opacity duration-300",children:[(0,v.jsx)("div",{className:"w-10 h-10 border-2 border-teal-400 border-t-transparent rounded-full animate-spin"}),(0,v.jsx)("span",{className:"text-xs font-mono tracking-widest text-teal-300/80 uppercase animate-pulse",children:"Initialisation Robot 3D..."})]}),(0,v.jsx)("div",{className:"w-full h-full transition-opacity duration-500 ".concat(s?"opacity-100":"opacity-0"),children:(0,v.jsx)(g.Suspense,{fallback:null,children:(0,v.jsx)(Nl,{scene:r,className:"w-full h-full",onLoad:function(e){l(!0),i&&i(e)}})})})]})}var Nf={mode:"dark",hue:0,saturation:1,brightness:1},Np={title:"Recursive Erosion particle sphere background",source:"<!DOCTYPE html>\n<html lang=\"fr\">\n<head>\n <meta charset=\"UTF-8\">\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n <title>Recursive Erosion Particle Sphere</title>\n <style>\n * { margin: 0; padding: 0; box-sizing: border-box; }\n html, body {\n width: 100%;\n height: 100%;\n overflow: hidden;\n background: #0a0908;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n #stage {\n position: absolute;\n inset: 0;\n width: 100%;\n height: 100%;\n display: block;\n }\n </style>\n <script src=\"https://cdnjs.cloudflare.com/ajax/libs/three.js/r128/three.min.js\"><\/script>\n</head>\n<body>\n <canvas id=\"stage\"></canvas>\n\n <script>\n (function() {\n var canvas = document.getElementById('stage');\n var width = window.innerWidth;\n var height = window.innerHeight;\n\n // Ensure canvas has dimension\n canvas.width = width;\n canvas.height = height;\n\n // Mouse tracking\n var mouseX = 0, mouseY = 0;\n var targetRotX = 0, targetRotY = 0;\n window.addEventListener('mousemove', function(e) {\n mouseX = (e.clientX / window.innerWidth) * 2 - 1;\n mouseY = -(e.clientY / window.innerHeight) * 2 + 1;\n });\n\n // Simple 3D noise approximation\n function snoise(x, y, z) {\n return Math.sin(x * 1.7 + y * 2.3) * Math.cos(y * 1.5 + z * 2.1) * Math.sin(z * 1.9 + x * 0.9);\n }\n\n // Check if THREE is loaded\n if (typeof THREE !== 'undefined') {\n initThree();\n } else {\n // In case external CDN fails, fallback to standalone canvas 2D rendering\n initCanvasFallback();\n }\n\n function initThree() {\n var scene = new THREE.Scene();\n var camera = new THREE.PerspectiveCamera(50, width / height, 0.1, 1000);\n camera.position.z = 240;\n\n var renderer = new THREE.WebGLRenderer({\n canvas: canvas,\n antialias: true,\n alpha: true,\n powerPreference: \"high-performance\"\n });\n renderer.setSize(width, height);\n renderer.setPixelRatio(Math.min(window.devicePixelRatio || 1, 2));\n\n // Create 7,000 points on Fibonacci sphere\n var particleCount = 7000;\n var geometry = new THREE.BufferGeometry();\n var positions = new Float32Array(particleCount * 3);\n var basePositions = new Float32Array(particleCount * 3);\n var colors = new Float32Array(particleCount * 3);\n var sizes = new Float32Array(particleCount);\n\n var sphereRadius = 82;\n var goldenRatio = (1 + Math.sqrt(5)) / 2;\n\n for (var i = 0; i < particleCount; i++) {\n var y = 1 - (i / (particleCount - 1)) * 2;\n var radiusAtY = Math.sqrt(Math.max(0, 1 - y * y));\n var theta = 2 * Math.PI * i / goldenRatio;\n\n var x = Math.cos(theta) * radiusAtY;\n var z = Math.sin(theta) * radiusAtY;\n\n var bx = x * sphereRadius;\n var by = y * sphereRadius;\n var bz = z * sphereRadius;\n\n basePositions[i * 3] = bx;\n basePositions[i * 3 + 1] = by;\n basePositions[i * 3 + 2] = bz;\n\n positions[i * 3] = bx;\n positions[i * 3 + 1] = by;\n positions[i * 3 + 2] = bz;\n\n // Warm orange / amber / golden palette with organic gradient\n var ratio = (y + 1) * 0.5;\n var r = 1.0;\n var g = 0.38 + ratio * 0.28 + Math.random() * 0.12;\n var b = 0.05 + ratio * 0.08;\n\n colors[i * 3] = r;\n colors[i * 3 + 1] = g;\n colors[i * 3 + 2] = b;\n\n sizes[i] = 1.2 + Math.random() * 2.0;\n }\n\n geometry.setAttribute('position', new THREE.BufferAttribute(positions, 3));\n geometry.setAttribute('color', new THREE.BufferAttribute(colors, 3));\n\n // Circular glow particle texture\n var circleCanvas = document.createElement('canvas');\n circleCanvas.width = 64;\n circleCanvas.height = 64;\n var ctx = circleCanvas.getContext('2d');\n var grad = ctx.createRadialGradient(32, 32, 0, 32, 32, 32);\n grad.addColorStop(0, 'rgba(255, 255, 255, 1)');\n grad.addColorStop(0.2, 'rgba(255, 160, 60, 0.9)');\n grad.addColorStop(0.5, 'rgba(255, 90, 20, 0.4)');\n grad.addColorStop(1, 'rgba(255, 60, 0, 0)');\n ctx.fillStyle = grad;\n ctx.fillRect(0, 0, 64, 64);\n\n var pTexture = new THREE.CanvasTexture(circleCanvas);\n\n var material = new THREE.PointsMaterial({\n size: 3.2,\n vertexColors: true,\n map: pTexture,\n transparent: true,\n blending: THREE.AdditiveBlending,\n depthWrite: false,\n opacity: 0.92\n });\n\n var points = new THREE.Points(geometry, material);\n scene.add(points);\n\n // 8 jagged lightning arcs that strike across the sphere\n var arcGroup = new THREE.Group();\n var arcLines = [];\n var ARC_COUNT = 8;\n var ARC_SEGMENTS = 20;\n\n for (var a = 0; a < ARC_COUNT; a++) {\n var arcGeo = new THREE.BufferGeometry();\n var arcPos = new Float32Array(ARC_SEGMENTS * 3);\n arcGeo.setAttribute('position', new THREE.BufferAttribute(arcPos, 3));\n\n var arcMat = new THREE.LineBasicMaterial({\n color: new THREE.Color(1.0, 0.72 + Math.random() * 0.25, 0.3),\n transparent: true,\n opacity: 0.75,\n blending: THREE.AdditiveBlending,\n linewidth: 1.5\n });\n\n var line = new THREE.Line(arcGeo, arcMat);\n arcLines.push({ line: line, geo: arcGeo, phase: Math.random() * Math.PI * 2, speed: 0.8 + Math.random() * 0.6 });\n arcGroup.add(line);\n }\n scene.add(arcGroup);\n\n // Inner glowing core\n var coreGeo = new THREE.SphereGeometry(sphereRadius * 0.3, 16, 16);\n var coreMat = new THREE.MeshBasicMaterial({\n color: 0xff5500,\n transparent: true,\n opacity: 0.08,\n blending: THREE.AdditiveBlending,\n wireframe: true\n });\n var coreMesh = new THREE.Mesh(coreGeo, coreMat);\n scene.add(coreMesh);\n\n var clock = new THREE.Clock();\n\n function animate() {\n requestAnimationFrame(animate);\n var time = clock.getElapsedTime();\n\n // 4-second erosion breathing loop\n var loopCycle = (time % 4.0) / 4.0; // 0 to 1\n var erosionPulse = Math.sin(loopCycle * Math.PI * 2);\n\n var posAttr = geometry.attributes.position;\n var posArray = posAttr.array;\n\n for (var i = 0; i < particleCount; i++) {\n var i3 = i * 3;\n var bx = basePositions[i3];\n var by = basePositions[i3 + 1];\n var bz = basePositions[i3 + 2];\n\n // 3D noise for recursive erosion crumpling & hole creation\n var nVal = snoise(bx * 0.025 + time * 0.4, by * 0.025 + time * 0.3, bz * 0.025);\n var isHole = nVal > (0.42 - erosionPulse * 0.25);\n\n var displace = isHole ? (1.0 + (nVal - 0.3) * 0.65) : (1.0 + nVal * 0.12 * erosionPulse);\n posArray[i3] = bx * displace;\n posArray[i3 + 1] = by * displace;\n posArray[i3 + 2] = bz * displace;\n }\n posAttr.needsUpdate = true;\n\n // Lightning arcs updates\n for (var a = 0; a < ARC_COUNT; a++) {\n var arcObj = arcLines[a];\n var aGeo = arcObj.geo;\n var aPos = aGeo.attributes.position.array;\n\n var tPhase = time * arcObj.speed + arcObj.phase;\n var p1Idx = Math.floor(Math.abs(Math.sin(tPhase * 0.7) * (particleCount - 1)));\n var p2Idx = Math.floor(Math.abs(Math.cos(tPhase * 0.5) * (particleCount - 1)));\n\n var x1 = posArray[p1Idx * 3], y1 = posArray[p1Idx * 3 + 1], z1 = posArray[p1Idx * 3 + 2];\n var x2 = posArray[p2Idx * 3], y2 = posArray[p2Idx * 3 + 1], z2 = posArray[p2Idx * 3 + 2];\n\n for (var s = 0; s < ARC_SEGMENTS; s++) {\n var tSeg = s / (ARC_SEGMENTS - 1);\n var sx = x1 + (x2 - x1) * tSeg;\n var sy = y1 + (y2 - y1) * tSeg;\n var sz = z1 + (z2 - z1) * tSeg;\n\n // Jagged lightning noise displacement\n if (s > 0 && s < ARC_SEGMENTS - 1) {\n var jitter = Math.sin(tSeg * Math.PI) * 7.5;\n sx += (Math.random() - 0.5) * jitter;\n sy += (Math.random() - 0.5) * jitter;\n sz += (Math.random() - 0.5) * jitter;\n }\n\n aPos[s * 3] = sx;\n aPos[s * 3 + 1] = sy;\n aPos[s * 3 + 2] = sz;\n }\n aGeo.attributes.position.needsUpdate = true;\n arcObj.line.material.opacity = 0.3 + Math.random() * 0.65;\n }\n\n // Smooth rotation & interactive mouse tilt\n targetRotX = mouseY * 0.45;\n targetRotY = mouseX * 0.55;\n\n points.rotation.y += 0.0035;\n points.rotation.x += (targetRotX - points.rotation.x) * 0.05;\n points.rotation.z += (targetRotY * 0.2 - points.rotation.z) * 0.05;\n\n arcGroup.rotation.copy(points.rotation);\n coreMesh.rotation.copy(points.rotation);\n\n renderer.render(scene, camera);\n }\n\n animate();\n\n window.addEventListener('resize', function() {\n width = window.innerWidth;\n height = window.innerHeight;\n camera.aspect = width / height;\n camera.updateProjectionMatrix();\n renderer.setSize(width, height);\n });\n }\n\n function initCanvasFallback() {\n var ctx = canvas.getContext('2d');\n var particles = [];\n var count = 3000;\n for (var i = 0; i < count; i++) {\n var y = 1 - (i / (count - 1)) * 2;\n var rAtY = Math.sqrt(Math.max(0, 1 - y * y));\n var theta = 2 * Math.PI * i / 1.6180339887;\n particles.push({\n x: Math.cos(theta) * rAtY,\n y: y,\n z: Math.sin(theta) * rAtY,\n baseRadius: 180\n });\n }\n\n var angleX = 0, angleY = 0;\n function renderLoop() {\n requestAnimationFrame(renderLoop);\n ctx.fillStyle = '#0a0908';\n ctx.fillRect(0, 0, width, height);\n\n var cx = width / 2;\n var cy = height / 2;\n\n angleY += 0.005;\n angleX = mouseY * 0.3;\n\n for (var i = 0; i < count; i += 2) {\n var p = particles[i];\n var cosY = Math.cos(angleY), sinY = Math.sin(angleY);\n var cosX = Math.cos(angleX), sinX = Math.sin(angleX);\n\n var x1 = p.x * cosY - p.z * sinY;\n var z1 = p.z * cosY + p.x * sinY;\n\n var y2 = p.y * cosX - z1 * sinX;\n var z2 = z1 * cosX + p.y * sinX;\n\n var scale = 400 / (400 + z2 * p.baseRadius);\n var px = cx + x1 * p.baseRadius * scale;\n var py = cy + y2 * p.baseRadius * scale;\n\n var alpha = Math.max(0.1, Math.min(1, (z2 + 1.2) * 0.45));\n ctx.fillStyle = 'rgba(255, 140, 40, ' + alpha + ')';\n ctx.beginPath();\n ctx.arc(px, py, Math.max(1, 2.0 * scale), 0, Math.PI * 2);\n ctx.fill();\n }\n }\n renderLoop();\n\n window.addEventListener('resize', function() {\n width = window.innerWidth;\n height = window.innerHeight;\n canvas.width = width;\n canvas.height = height;\n });\n }\n })();\n <\/script>\n</body>\n</html>",background:"#0a0908",theme:{lightBackground:"#f4f3f1",darkBackground:"#0a0908"},targets:[{selector:"#stage",role:"background"}],hiddenTargets:["#badge",".sr"]};function Nh(e,t,r){return Math.min(r,Math.max(t,e))}function Nm(e,t){var r,n;return null!=(r=null==(n=e.theme)?void 0:n["".concat(t,"Background")])?r:e.background}function Ny(e){var t=e.mode,r=void 0===t?Nf.mode:t,n=e.hue,a=void 0===n?Nf.hue:n,i=e.saturation,o=void 0===i?Nf.saturation:i,s=e.brightness,l=void 0===s?Nf.brightness:s,u=e.className,c=e.style,d="light"===r?"light":"dark",f=Nm(Np,d),p=(0,g.useMemo)(function(){var e,t,r,n,a,i,o,s;return t=Nm(Np,d),r=Np.source,n=JSON.stringify(Np.targets).replace(/</g,"\\u003c"),a=JSON.stringify(null!=(e=Np.hiddenTargets)?e:[]).replace(/</g,"\\u003c"),i=JSON.stringify(d),o="<style data-threeui-focus>\nhtml, body { width: 100% !important; height: 100% !important; min-height: 0 !important; margin: 0 !important; padding: 0 !important; overflow: hidden !important; background: ".concat(t," !important; color-scheme: ").concat(d,' !important; }\nbody { position: relative !important; display: flex !important; align-items: center !important; justify-content: center !important; }\nbody > * { visibility: hidden !important; }\nbody[data-threeui-ready] > [data-threeui-role] { visibility: visible !important; }\n[data-threeui-residual] { display: none !important; }\n[data-threeui-hidden] { display: none !important; }\n[data-threeui-role="background"] { position: fixed !important; inset: 0 !important; width: 100% !important; height: 100% !important; max-width: none !important; max-height: none !important; z-index: 0 !important; opacity: 1 !important; pointer-events: none !important; }\n[data-threeui-role="button"] { position: relative !important; z-index: 2 !important; opacity: 1 !important; flex: none !important; }\n[data-threeui-role="visual"] { position: relative !important; z-index: 1 !important; width: min(100%, 1040px) !important; max-width: 1040px !important; max-height: 100% !important; margin: auto !important; padding: 24px !important; overflow: auto !important; opacity: 1 !important; filter: none !important; }\n</style>'),s="<script data-threeui-focus>\n(function () {\n document.documentElement.dataset.sfMode = ".concat(i,";\n var isolated = false;\n function isolate() {\n if (isolated) return;\n var specs = ").concat(n,";\n var hiddenSelectors = ").concat(a,";\n var roots = [];\n hiddenSelectors.forEach(function (selector) {\n document.querySelectorAll(selector).forEach(function (element) {\n element.setAttribute('data-threeui-hidden', '');\n element.setAttribute('aria-hidden', 'true');\n if ('inert' in element) element.inert = true;\n });\n });\n specs.forEach(function (spec) {\n var element = document.querySelector(spec.selector);\n if (!element) return;\n element.setAttribute('data-threeui-role', spec.role);\n if (!roots.some(function (root) { return root.contains(element); })) roots.push(element);\n });\n if (!roots.length) return;\n isolated = true;\n roots.forEach(function (root) {\n var placeholderLink = root.matches('a[href=\"#\"]') ? root : root.querySelector('a[href=\"#\"]');\n if (placeholderLink) placeholderLink.addEventListener('click', function (event) { event.preventDefault(); });\n document.body.appendChild(root);\n });\n Array.from(document.body.children).forEach(function (element) {\n if (roots.indexOf(element) !== -1) return;\n element.setAttribute('data-threeui-residual', '');\n element.setAttribute('aria-hidden', 'true');\n if ('inert' in element) element.inert = true;\n });\n document.body.setAttribute('data-threeui-ready', '');\n requestAnimationFrame(function () { window.dispatchEvent(new Event('resize')); });\n }\n function scheduleIsolation() { setTimeout(isolate, 100); }\n if (document.readyState === 'loading') document.addEventListener('DOMContentLoaded', scheduleIsolation, { once: true });\n else scheduleIsolation();\n window.addEventListener('load', isolate, { once: true });\n})();\n<\/script>"),r.replace(/<\/head>/i,"".concat(o,"</head>")).replace(/<\/body>/i,"".concat(s,"</body>"))},[d]),h=Nh(a,-180,180),m=Nh(o,0,2),y=Nh(l,.35,1.65),b=0===h&&1===m&&1===y?void 0:"hue-rotate(".concat(h,"deg) saturate(").concat(m,") brightness(").concat(y,")");return(0,v.jsx)("iframe",{className:u,"data-mode":d,title:Np.title,srcDoc:p,sandbox:"allow-scripts",loading:"eager",style:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({display:"block",width:"100%",height:"100%",border:0,background:f,filter:b},c)})}function Nv(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Ng(e){if(Array.isArray(e))return e}function Nb(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Nx(e,t){if(e){if("string"==typeof e)return Nv(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Nv(e,t)}}var Nw=(0,g.forwardRef)(function(e,t){var r,n,a,i=Ng(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||Nx(r)||Nb(),o=i[0],s=i.slice(1),l=o.children,u=o.optionsComponent,c=o.header,d=o.footer,f=o.align,p=o.width,h=o.className,m=void 0===h?"":h,y=o.contentClassName,g=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(o,["children","optionsComponent","header","footer","align","width","className","contentClassName"]),b=(Ng(s)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),1!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(s)||Nx(s,1)||Nb())[0],x=m.includes("fixed")||m.includes("absolute");return(0,v.jsx)("div",(n=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({ref:b,className:"".concat(x?"":"absolute top-full mt-2"," z-[9999] text-xs text-slate-100 select-none overflow-hidden\n bg-slate-950/90 backdrop-blur-3xl rounded-2xl border border-white/20\n shadow-[0_16px_48px_0_rgba(0,0,0,0.65)]\n before:absolute before:inset-0 before:rounded-2xl before:bg-gradient-to-b before:from-white/[0.12] before:to-transparent before:pointer-events-none\n animate-in fade-in zoom-in-95 duration-150\n ").concat({right:"right-0",left:"left-0",center:"left-1/2 -translate-x-1/2",none:""}[void 0===f?"right":f],"\n ").concat(p||"","\n ").concat(m,"\n ")},g),a=a={children:(0,v.jsxs)("div",{className:"relative z-10 p-1.5 ".concat(void 0===y?"":y),children:[c&&(0,v.jsx)("div",{className:"pb-1.5 mb-1.5 border-b border-white/10 px-2 pt-1",children:c}),u||l,d&&(0,v.jsx)("div",{className:"pt-1.5 mt-1.5 border-t border-white/10 px-2 pb-1",children:d})]})},Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(a)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(a)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(a,e))}),n))});Nw.displayName="WaterGlassModal";function NS(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var Nj=new(function(){var e;function t(){var e=this;if(!(this instanceof t))throw TypeError("Cannot call a class as a function");NS(this,"ctx",null),NS(this,"isMuted",!1),NS(this,"volume",.5),NS(this,"lastPlayTimes",{}),NS(this,"noiseBuffer",null);try{var r=localStorage.getItem("egen_xbox_sound_muted");null!==r&&(this.isMuted="true"===r);var n=localStorage.getItem("egen_xbox_sound_volume");null!==n&&(this.volume=parseFloat(n)||.5)}catch(e){}if("u">typeof window){var a=function(){e.initContext(),window.removeEventListener("pointerdown",a),window.removeEventListener("keydown",a)};window.addEventListener("pointerdown",a,{passive:!0}),window.addEventListener("keydown",a,{passive:!0})}}return e=[{key:"initContext",value:function(){if(!this.ctx&&"u">typeof window){var e=window.AudioContext||window.webkitAudioContext;e&&(this.ctx=new e,this.generateNoiseBuffer())}return this.ctx&&"suspended"===this.ctx.state&&this.ctx.resume().catch(function(){}),this.ctx}},{key:"generateNoiseBuffer",value:function(){if(this.ctx){for(var e=.5*this.ctx.sampleRate,t=this.ctx.createBuffer(2,e,this.ctx.sampleRate),r=0;r<2;r++)for(var n=t.getChannelData(r),a=0;a<e;a++)n[a]=2*Math.random()-1;this.noiseBuffer=t}}},{key:"getIsMuted",value:function(){return this.isMuted}},{key:"setMuted",value:function(e){this.isMuted=e;try{localStorage.setItem("egen_xbox_sound_muted",String(e))}catch(e){}}},{key:"toggleMute",value:function(){return this.setMuted(!this.isMuted),this.isMuted||this.play("select"),this.isMuted}},{key:"getVolume",value:function(){return this.volume}},{key:"setVolume",value:function(e){this.volume=Math.max(0,Math.min(1,e));try{localStorage.setItem("egen_xbox_sound_volume",String(this.volume))}catch(e){}}},{key:"play",value:function(e){if(!this.isMuted){var t=performance.now();if(!this.lastPlayTimes[e]||!(t-this.lastPlayTimes[e]<({hover:40,scroll:40,boundary:160,select:60,back:60,modalOpen:100,folderOpen:120,notification:180,achievement:250,toastSuccess:120,toastInfo:120,toastWarning:120,toastError:120,toggle:60})[e])){this.lastPlayTimes[e]=t;var r=this.initContext();if(r)try{switch(e){case"hover":this.playHover(r);break;case"select":this.playSelect(r);break;case"back":this.playBack(r);break;case"modalOpen":this.playModalOpen(r);break;case"folderOpen":this.playFolderOpen(r);break;case"scroll":this.playScroll(r);break;case"boundary":this.playBoundary(r);break;case"notification":this.playNotification(r);break;case"achievement":this.playAchievement(r);break;case"toastSuccess":this.playToastSuccess(r);break;case"toastInfo":this.playToastInfo(r);break;case"toastWarning":this.playToastWarning(r);break;case"toastError":this.playToastError(r);break;case"toggle":this.playToggle(r)}}catch(e){console.warn("Xbox Audio error:",e)}}}}},{key:"playHover",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain(),a=e.createBiquadFilter();r.type="sine",r.frequency.setValueAtTime(2200,t),r.frequency.exponentialRampToValueAtTime(1400,t+.025),a.type="bandpass",a.frequency.setValueAtTime(1800,t),a.Q.setValueAtTime(3,t);var i=.12*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(i,t+.002),n.gain.exponentialRampToValueAtTime(1e-4,t+.025),r.connect(a),a.connect(n),n.connect(e.destination),r.start(t),r.stop(t+.03)}},{key:"playSelect",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain();r.type="sine",r.frequency.setValueAtTime(920,t),r.frequency.exponentialRampToValueAtTime(1480,t+.035),r.frequency.exponentialRampToValueAtTime(1100,t+.07);var a=.28*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(a,t+.003),n.gain.exponentialRampToValueAtTime(.001,t+.07),r.connect(n),n.connect(e.destination);var i=e.createOscillator(),o=e.createGain();i.type="triangle",i.frequency.setValueAtTime(460,t),i.frequency.exponentialRampToValueAtTime(320,t+.05);var s=.15*this.volume;o.gain.setValueAtTime(0,t),o.gain.linearRampToValueAtTime(s,t+.004),o.gain.exponentialRampToValueAtTime(.001,t+.05),i.connect(o),o.connect(e.destination),r.start(t),i.start(t),r.stop(t+.08),i.stop(t+.06)}},{key:"playBack",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain();r.type="triangle",r.frequency.setValueAtTime(750,t),r.frequency.exponentialRampToValueAtTime(260,t+.015);var a=.16*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(a,t+.002),n.gain.exponentialRampToValueAtTime(1e-4,t+.018),r.connect(n),n.connect(e.destination),r.start(t),r.stop(t+.02);var i=e.createOscillator(),o=e.createGain(),s=e.createBiquadFilter();i.type="sine",i.frequency.setValueAtTime(540,t),i.frequency.exponentialRampToValueAtTime(210,t+.085),s.type="lowpass",s.frequency.setValueAtTime(1200,t),s.frequency.exponentialRampToValueAtTime(360,t+.09),s.Q.setValueAtTime(1.8,t);var l=.28*this.volume;o.gain.setValueAtTime(0,t),o.gain.linearRampToValueAtTime(l,t+.004),o.gain.exponentialRampToValueAtTime(1e-4,t+.095),i.connect(s),s.connect(o),o.connect(e.destination);var u=e.createOscillator(),c=e.createGain();u.type="sine",u.frequency.setValueAtTime(230,t),u.frequency.exponentialRampToValueAtTime(95,t+.095);var d=.18*this.volume;c.gain.setValueAtTime(0,t),c.gain.linearRampToValueAtTime(d,t+.005),c.gain.exponentialRampToValueAtTime(1e-4,t+.1),u.connect(c),c.connect(e.destination),i.start(t),u.start(t),i.stop(t+.1),u.stop(t+.11)}},{key:"playModalOpen",value:function(e){var t=this,r=e.currentTime,n=e.createBiquadFilter();if(n.type="lowpass",n.frequency.setValueAtTime(1100,r),n.Q.setValueAtTime(.7,r),n.connect(e.destination),this.noiseBuffer){var a=e.createBufferSource();a.buffer=this.noiseBuffer;var i=e.createBiquadFilter();i.type="bandpass",i.frequency.setValueAtTime(450,r),i.frequency.exponentialRampToValueAtTime(700,r+.1),i.Q.setValueAtTime(1.2,r);var o=e.createGain(),s=.045*this.volume;o.gain.setValueAtTime(0,r),o.gain.linearRampToValueAtTime(s,r+.03),o.gain.exponentialRampToValueAtTime(1e-4,r+.18),a.connect(i),i.connect(o),o.connect(n),a.start(r),a.stop(r+.19)}[{freqStart:370,freqEnd:392,startOffset:0,dur:.22,vol:.14},{freqStart:554,freqEnd:587.33,startOffset:.022,dur:.24,vol:.12},{freqStart:740,freqEnd:783.99,startOffset:.045,dur:.2,vol:.08}].forEach(function(a){var i=e.createOscillator(),o=e.createGain();i.type="sine";var s=r+a.startOffset;i.frequency.setValueAtTime(a.freqStart,s),i.frequency.exponentialRampToValueAtTime(a.freqEnd,s+.06);var l=t.volume*a.vol;o.gain.setValueAtTime(0,s),o.gain.linearRampToValueAtTime(l,s+.022),o.gain.exponentialRampToValueAtTime(1e-4,s+a.dur),i.connect(o),o.connect(n),i.start(s),i.stop(s+a.dur+.01)})}},{key:"playFolderOpen",value:function(e){var t=this,r=e.currentTime;if(this.noiseBuffer){var n=e.createBufferSource();n.buffer=this.noiseBuffer;var a=e.createBiquadFilter();a.type="bandpass",a.frequency.setValueAtTime(350,r),a.frequency.exponentialRampToValueAtTime(2400,r+.12),a.frequency.exponentialRampToValueAtTime(600,r+.28),a.Q.setValueAtTime(3.5,r);var i=e.createGain(),o=.2*this.volume;i.gain.setValueAtTime(0,r),i.gain.linearRampToValueAtTime(o,r+.08),i.gain.exponentialRampToValueAtTime(1e-4,r+.28),n.connect(a),a.connect(i),i.connect(e.destination),n.start(r),n.stop(r+.3)}[659.25,987.77,1318.5].forEach(function(n,a){var i=e.createOscillator(),o=e.createGain();i.type="sine",i.frequency.setValueAtTime(.85*n,r),i.frequency.exponentialRampToValueAtTime(n,r+.09);var s=.12*t.volume/(a+1);o.gain.setValueAtTime(0,r),o.gain.linearRampToValueAtTime(s,r+.04),o.gain.exponentialRampToValueAtTime(1e-4,r+.35),i.connect(o),o.connect(e.destination),i.start(r),i.stop(r+.36)})}},{key:"playScroll",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain(),a=e.createBiquadFilter();r.type="triangle",r.frequency.setValueAtTime(1400,t),r.frequency.exponentialRampToValueAtTime(800,t+.018),a.type="bandpass",a.frequency.setValueAtTime(1200,t),a.Q.setValueAtTime(2,t);var i=.16*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(i,t+.002),n.gain.exponentialRampToValueAtTime(1e-4,t+.018),r.connect(a),a.connect(n),n.connect(e.destination),r.start(t),r.stop(t+.02)}},{key:"playBoundary",value:function(e){var t=e.currentTime,r=e.createBiquadFilter();r.type="lowpass",r.frequency.setValueAtTime(450,t),r.frequency.exponentialRampToValueAtTime(180,t+.06),r.Q.setValueAtTime(1.2,t),r.connect(e.destination);var n=e.createOscillator(),a=e.createGain();n.type="sine",n.frequency.setValueAtTime(210,t),n.frequency.exponentialRampToValueAtTime(85,t+.055);var i=.17*this.volume;a.gain.setValueAtTime(0,t),a.gain.linearRampToValueAtTime(i,t+.003),a.gain.exponentialRampToValueAtTime(1e-4,t+.065),n.connect(a),a.connect(r),n.start(t),n.stop(t+.07);var o=e.createOscillator(),s=e.createGain();o.type="triangle",o.frequency.setValueAtTime(110,t),o.frequency.exponentialRampToValueAtTime(55,t+.045);var l=.11*this.volume;s.gain.setValueAtTime(0,t),s.gain.linearRampToValueAtTime(l,t+.002),s.gain.exponentialRampToValueAtTime(1e-4,t+.05),o.connect(s),s.connect(r),o.start(t),o.stop(t+.055)}},{key:"playNotification",value:function(e){var t=this,r=e.currentTime;[{f:880,start:0,dur:.22,vol:.25},{f:1320,start:.08,dur:.35,vol:.3}].forEach(function(n){var a=e.createOscillator(),i=e.createGain();a.type="sine",a.frequency.setValueAtTime(n.f,r+n.start);var o=t.volume*n.vol;i.gain.setValueAtTime(0,r+n.start),i.gain.linearRampToValueAtTime(o,r+n.start+.01),i.gain.exponentialRampToValueAtTime(1e-4,r+n.start+n.dur),a.connect(i),i.connect(e.destination),a.start(r+n.start),a.stop(r+n.start+n.dur)})}},{key:"playAchievement",value:function(e){var t=this,r=e.currentTime;[{freq:739.99,time:0,dur:.15},{freq:1108.73,time:.08,dur:.55}].forEach(function(n){var a=e.createOscillator(),i=e.createGain();a.type="sine",a.frequency.setValueAtTime(n.freq,r+n.time);var o=.3*t.volume;i.gain.setValueAtTime(0,r+n.time),i.gain.linearRampToValueAtTime(o,r+n.time+.01),i.gain.exponentialRampToValueAtTime(1e-4,r+n.time+n.dur),a.connect(i),i.connect(e.destination),a.start(r+n.time),a.stop(r+n.time+n.dur)}),[1479.98,1864.66,2217.46,2959.96].forEach(function(n,a){var i=e.createOscillator(),o=e.createGain();i.type="sine",i.frequency.setValueAtTime(n,r+.12);var s=.22*t.volume/(a+1);o.gain.setValueAtTime(0,r+.12),o.gain.linearRampToValueAtTime(s,r+.14),o.gain.exponentialRampToValueAtTime(1e-4,r+.85),i.connect(o),o.connect(e.destination),i.start(r+.12),i.stop(r+.9)})}},{key:"playToastSuccess",value:function(e){var t=this,r=e.currentTime;[{f:739.99,delay:0,dur:.2,vol:.24},{f:932.33,delay:.04,dur:.22,vol:.26},{f:1108.73,delay:.08,dur:.42,vol:.3}].forEach(function(n){var a=e.createOscillator(),i=e.createGain();a.type="sine";var o=r+n.delay;a.frequency.setValueAtTime(n.f,o);var s=t.volume*n.vol;i.gain.setValueAtTime(0,o),i.gain.linearRampToValueAtTime(s,o+.008),i.gain.exponentialRampToValueAtTime(1e-4,o+n.dur),a.connect(i),i.connect(e.destination),a.start(o),a.stop(o+n.dur+.02)})}},{key:"playToastInfo",value:function(e){var t=this,r=e.currentTime;[{f:880,delay:0,dur:.22,vol:.24},{f:1318.5,delay:.045,dur:.3,vol:.26},{f:440,delay:0,dur:.15,vol:.12}].forEach(function(n){var a=e.createOscillator(),i=e.createGain();a.type="sine";var o=r+n.delay;a.frequency.setValueAtTime(n.f,o);var s=t.volume*n.vol;i.gain.setValueAtTime(0,o),i.gain.linearRampToValueAtTime(s,o+.006),i.gain.exponentialRampToValueAtTime(1e-4,o+n.dur),a.connect(i),i.connect(e.destination),a.start(o),a.stop(o+n.dur+.02)})}},{key:"playToastWarning",value:function(e){var t=this,r=e.currentTime;[{f:554.37,delay:0,dur:.06,vol:.25},{f:466.16,delay:.075,dur:.12,vol:.26}].forEach(function(n){var a=e.createOscillator(),i=e.createGain(),o=e.createBiquadFilter();a.type="triangle",o.type="bandpass",o.frequency.setValueAtTime(900,r+n.delay),o.Q.setValueAtTime(2.2,r+n.delay);var s=r+n.delay;a.frequency.setValueAtTime(n.f,s);var l=t.volume*n.vol;i.gain.setValueAtTime(0,s),i.gain.linearRampToValueAtTime(l,s+.005),i.gain.exponentialRampToValueAtTime(1e-4,s+n.dur),a.connect(o),o.connect(i),i.connect(e.destination),a.start(s),a.stop(s+n.dur+.01)})}},{key:"playToastError",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain(),a=e.createBiquadFilter();r.type="sawtooth",r.frequency.setValueAtTime(392,t),r.frequency.exponentialRampToValueAtTime(220,t+.12),a.type="lowpass",a.frequency.setValueAtTime(650,t),a.frequency.exponentialRampToValueAtTime(200,t+.12),a.Q.setValueAtTime(2,t);var i=.24*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(i,t+.005),n.gain.exponentialRampToValueAtTime(1e-4,t+.13),r.connect(a),a.connect(n),n.connect(e.destination);var o=e.createOscillator(),s=e.createGain();o.type="sine",o.frequency.setValueAtTime(140,t),o.frequency.exponentialRampToValueAtTime(60,t+.15),s.gain.setValueAtTime(0,t),s.gain.linearRampToValueAtTime(.18*this.volume,t+.005),s.gain.exponentialRampToValueAtTime(1e-4,t+.15),o.connect(s),s.connect(e.destination),r.start(t),o.start(t),r.stop(t+.14),o.stop(t+.16)}},{key:"playToggle",value:function(e){var t=e.currentTime,r=e.createOscillator(),n=e.createGain();r.type="triangle",r.frequency.setValueAtTime(1100,t),r.frequency.exponentialRampToValueAtTime(1600,t+.02);var a=.18*this.volume;n.gain.setValueAtTime(0,t),n.gain.linearRampToValueAtTime(a,t+.002),n.gain.exponentialRampToValueAtTime(1e-4,t+.03),r.connect(n),n.connect(e.destination),r.start(t),r.stop(t+.035)}}],function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,e),t}());function NO(e){Nj.play(e)}function Nk(){return Nj.getIsMuted()}function NE(){return Nj.toggleMute()}var NP=(0,g.lazy)(function(){return Promise.all([r.e("6880"),r.e("4646")]).then(r.bind(r,9477)).then(function(e){return{default:e.RobotStage}})});function NA(){Promise.all([r.e("6880"),r.e("4646")]).then(r.bind(r,9477))}function ND(e){return(0,v.jsx)(g.Suspense,{fallback:(0,v.jsx)("div",{role:"status","aria-label":"Chargement du robot",style:{width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center"},children:(0,v.jsx)("div",{className:"w-10 h-10 border-2 border-teal-400 border-t-transparent rounded-full animate-spin"})}),children:(0,v.jsx)(NP,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},e))})}var NC=r(2707),NT=r(9881);function NN(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function NR(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function NM(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){NR(e,t,r[t])})}return e}function NI(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function N_(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||NF(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function NL(e){return function(e){if(Array.isArray(e))return NN(e)}(e)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||NF(e)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function NF(e,t){if(e){if("string"==typeof e)return NN(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return NN(e,t)}}var NB={type:"spring",stiffness:560,damping:34,mass:.7};function NV(e,t){return e.find(function(e){return e.id===t})}function Nz(e,t){return null==e?void 0:e.operators.find(function(e){return e.value===t})}function NW(e){var t,r,n=e.anchorKey,a=e.label,i=e.onClose,o=e.children,s=g.useRef(null),l=Ed(),u=N_(g.useState(null),2),c=u[0],d=u[1],f=N_(g.useState(!1),2),p=f[0],h=f[1],m=N_(g.useState(null),2),y=m[0],b=m[1];g.useLayoutEffect(function(){var e=document.querySelector('[data-fb-anchor="'.concat(n,'"]'));d(e),h(!!(null==e?void 0:e.closest(".dark")))},[n]);var x=g.useRef(n);return x.current=n,g.useEffect(function(){return function(){var e;null==(e=document.querySelector('[data-fb-anchor="'.concat(x.current,'"]')))||e.focus()}},[]),g.useLayoutEffect(function(){if(c){var e=function(){var e=s.current;if(e){var t=c.getBoundingClientRect(),r=e.offsetWidth,n=e.offsetHeight,a=t.left,i=t.bottom+6;a=Math.max(8,a=Math.min(a,window.innerWidth-r-8)),i+n>window.innerHeight-8&&(i=t.top-6-n),b({top:i,left:a})}};return e(),window.addEventListener("resize",e),window.addEventListener("scroll",e,!0),function(){window.removeEventListener("resize",e),window.removeEventListener("scroll",e,!0)}}},[c]),g.useEffect(function(){var e=function(e){!s.current||s.current.contains(e.target)||c&&c.contains(e.target)||i()},t=function(e){"Escape"===e.key&&(e.stopPropagation(),i())};return document.addEventListener("pointerdown",e,!0),document.addEventListener("keydown",t,!0),function(){document.removeEventListener("pointerdown",e,!0),document.removeEventListener("keydown",t,!0)}},[c,i]),(0,tZ.createPortal)((0,v.jsx)("div",{className:p?"dark":"",style:{display:"contents"},children:(0,v.jsx)(hz.div,{ref:s,role:"dialog","aria-label":a,initial:!l&&{opacity:0,y:-3,scale:.985},animate:{opacity:1,y:0,scale:1},transition:{duration:.12,ease:[.2,.8,.2,1]},style:{position:"fixed",top:null!=(t=null==y?void 0:y.top)?t:-9999,left:null!=(r=null==y?void 0:y.left)?r:-9999,zIndex:60},className:"min-w-[13rem] max-w-[18rem] overflow-hidden rounded-lg border border-[var(--fb-border)] bg-[var(--fb-bg-surface)] shadow-[0_10px_30px_-8px_rgba(0,0,0,0.25)]",children:o})}),document.body)}function N$(e){var t=e.items,r=e.multi,n=e.loading,a=e.error,i=e.searchable,o=e.placeholder,s=e.onQuery,l=e.onPick,u=e.onRetry,c=e.ariaLabel,d=N_(g.useState(""),2),f=d[0],p=d[1],h=N_(g.useState(0),2),m=h[0],y=h[1],b=g.useId(),x=g.useRef(null),w=g.useRef(null),S=g.useMemo(function(){if(s)return t;var e=f.trim().toLowerCase();return e?t.filter(function(t){return t.label.toLowerCase().includes(e)}):t},[t,f,s]);g.useEffect(function(){var e=requestAnimationFrame(function(){var e;return null==(e=x.current)?void 0:e.focus()});return function(){return cancelAnimationFrame(e)}},[]),g.useEffect(function(){y(function(e){return Math.min(e,Math.max(0,S.length-1))})},[S.length]),g.useEffect(function(){var e,t=null==(e=w.current)?void 0:e.querySelector('[data-idx="'.concat(m,'"]'));null==t||t.scrollIntoView({block:"nearest"})},[m]);var j=function(e){var t=S[e];t&&l(t.value)},O=function(e){"ArrowDown"===e.key?(e.preventDefault(),y(function(e){return Math.min(e+1,S.length-1)})):"ArrowUp"===e.key?(e.preventDefault(),y(function(e){return Math.max(e-1,0)})):"Home"===e.key?(e.preventDefault(),y(0)):"End"===e.key?(e.preventDefault(),y(S.length-1)):"Enter"===e.key&&(e.preventDefault(),j(m))};return(0,v.jsxs)("div",{children:[(void 0===i||i)&&(0,v.jsx)("div",{className:"border-b border-[var(--fb-border)] p-1.5",children:(0,v.jsx)("input",{ref:x,role:"combobox","aria-expanded":"true","aria-controls":b,"aria-activedescendant":S[m]?"".concat(b,"-").concat(m):void 0,"aria-label":c,value:f,onChange:function(e){p(e.target.value),null==s||s(e.target.value)},onKeyDown:O,placeholder:void 0===o?"Rechercher…":o,className:"w-full bg-transparent px-1.5 py-1 text-[13px] text-[var(--fb-fg)] outline-none placeholder:text-[var(--fb-fg-subtle)]",autoComplete:"off",spellCheck:!1})}),(0,v.jsxs)("ul",{ref:w,id:b,role:"listbox","aria-multiselectable":r||void 0,"aria-label":c,className:"max-h-60 overflow-y-auto p-1",onKeyDown:O,tabIndex:-1,children:[n&&(0,v.jsxs)("li",{className:"flex items-center gap-2 px-2 py-3 text-[13px] text-[var(--fb-fg-muted)]",children:[(0,v.jsx)(NX,{})," Chargement des options…"]}),a&&!n&&(0,v.jsxs)("li",{className:"px-2 py-2.5 text-[13px]",children:[(0,v.jsx)("p",{className:"text-[var(--fb-fg-muted)]",children:"Impossible de charger les options."}),(0,v.jsx)("button",{type:"button",onClick:u,className:"mt-1 rounded-md px-1.5 py-0.5 text-[13px] font-medium text-[var(--fb-fg)] underline decoration-[var(--fb-fg-subtle)] underline-offset-2 hover:decoration-[var(--fb-fg)] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--fb-accent)]/60",children:"R\xe9essayer"})]}),!n&&!a&&0===S.length&&(0,v.jsx)("li",{className:"px-2 py-3 text-[13px] text-[var(--fb-fg-muted)]",children:"Aucun r\xe9sultat"}),!n&&!a&&S.map(function(e,t){var n=t===m;return(0,v.jsxs)("li",{id:"".concat(b,"-").concat(t),"data-idx":t,role:"option","aria-selected":r?!!e.selected:n,onMouseEnter:function(){return y(t)},onClick:function(){return l(e.value)},className:["flex cursor-pointer items-center gap-2 rounded-md px-2 py-1.5 text-[13px] text-[var(--fb-fg)]",n?"bg-[var(--fb-bg-active)]":"bg-transparent"].join(" "),children:[r&&(0,v.jsx)("span",{"aria-hidden":!0,className:["flex h-3.5 w-3.5 shrink-0 items-center justify-center rounded-[4px] border transition-colors",e.selected?"border-[var(--fb-border-strong)] bg-[var(--fb-border-strong)] text-[var(--fb-fg-on-accent)]":"border-[var(--fb-border)]"].join(" "),children:e.selected&&(0,v.jsx)(NY,{})}),e.glyph&&(0,v.jsx)("span",{className:"shrink-0","aria-hidden":!0,children:e.glyph}),(0,v.jsx)("span",{className:"truncate",children:e.label}),!r&&e.selected&&(0,v.jsx)("span",{className:"ml-auto text-[var(--fb-fg-muted)]",children:(0,v.jsx)(NY,{})})]},e.value)})]})]})}function NU(e){var t=e.inputType,r=e.arity,n=e.values,a=e.onCommit,i=e.ariaLabel,o=e.rangeLabels,s=void 0===o?["Min","Max"]:o,l=e.placeholder,u=g.useRef(null);g.useEffect(function(){var e=requestAnimationFrame(function(){var e;return null==(e=u.current)?void 0:e.focus()});return function(){return cancelAnimationFrame(e)}},[]);var c="w-full rounded-md border border-[var(--fb-border)] bg-transparent px-2 py-1.5 text-[13px] text-[var(--fb-fg)] outline-none focus-visible:ring-2 focus-visible:ring-[var(--fb-accent)]/60";if(2===r){var d=N_(n,2),f=d[0],p=void 0===f?"":f,h=d[1],m=void 0===h?"":h;return(0,v.jsxs)("div",{className:"flex items-start gap-2 p-2",children:[(0,v.jsxs)("label",{className:"flex flex-1 flex-col gap-1",children:[(0,v.jsx)("span",{className:"text-[11px] text-[var(--fb-fg-muted)]",children:s[0]}),(0,v.jsx)("input",{ref:u,type:t,value:p,"aria-label":"".concat(i," — ").concat(s[0]),onChange:function(e){return a([e.target.value,m])},className:c})]}),(0,v.jsxs)("label",{className:"flex flex-1 flex-col gap-1",children:[(0,v.jsx)("span",{className:"text-[11px] text-[var(--fb-fg-muted)]",children:s[1]}),(0,v.jsx)("input",{type:t,value:m,"aria-label":"".concat(i," — ").concat(s[1]),onChange:function(e){return a([p,e.target.value])},className:c})]})]})}var y=N_(n,1)[0];return(0,v.jsx)("div",{className:"p-2",children:(0,v.jsx)("input",{ref:u,type:t,value:void 0===y?"":y,placeholder:l,"aria-label":i,onChange:function(e){return a([e.target.value])},onKeyDown:function(e){"Enter"===e.key&&e.currentTarget.blur()},className:c})})}function NH(e){var t=e.role,r=e.children,n=e.onOpen,a=e.registerRef,i=e.tabIndex,o=e.ariaLabel,s=e.anchorKey,l=e.onFocus,u=e.muted,c=e.active,d=e.flash,f=e.disabled;return(0,v.jsx)("button",{type:"button",ref:a,tabIndex:i,"aria-label":o,"aria-haspopup":"listbox","aria-expanded":c,"aria-disabled":f||void 0,"data-fb-anchor":s,onFocus:l,onClick:n,"data-flash":d?"":void 0,className:["relative flex items-center gap-1 whitespace-nowrap px-2 py-[4px] text-[13px] leading-[1.35] transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-[var(--fb-accent)]/70",f?"cursor-default":"active:scale-[0.98]",u?"text-[var(--fb-fg-muted)]":"text-[var(--fb-fg)]",c?"bg-[var(--fb-bg-active)]":f?"":"hover:bg-[var(--fb-bg-hover)]","field"===t?"rounded-l-md font-medium":"","data-[flash]:animate-[fb-flash_620ms_ease-out]"].join(" "),children:r})}function NG(e){var t,r,n=e.fields,a=e.value,i=e.onChange,o=e.addLabel,s=void 0===o?"Filtre":o,l=e.emptyLabel,u=void 0===l?"Ajouter un filtre":l,c=e.clearLabel,d=e.allowDuplicateFields,f=void 0!==d&&d,p=e.disabled,h=e.className,m=e["aria-label"],y=Ed(),b=N_(g.useState(null),2),x=b[0],w=b[1],S=N_(g.useState(null),2),j=S[0],O=S[1],k=g.useRef([]),E=N_(g.useState(0),2),P=E[0],A=E[1],D=N_(g.useState({}),2),C=D[0],T=D[1],N=[];a.forEach(function(e){N.push({filterId:e.id,kind:"field"}),N.push({filterId:e.id,kind:"operator"}),N.push({filterId:e.id,kind:"value"}),N.push({filterId:e.id,kind:"remove"})}),N.push({kind:"add"}),g.useEffect(function(){P>N.length-1&&A(N.length-1)},[N.length,P]);var R=function(e){var t,r=Math.max(0,Math.min(e,N.length-1));A(r),null==(t=k.current[r])||t.focus()},M=function(e){var t,r,o=NV(n,e);if(o){var s=o.operators[0],l={id:"u">typeof crypto&&"randomUUID"in crypto?crypto.randomUUID():"f_".concat(Math.random().toString(36).slice(2,9)),field:e,operator:null!=(t=null==s?void 0:s.value)?t:"is",values:[]};i(NL(a).concat([l])),w((null!=(r=null==s?void 0:s.arity)?r:1)===0?null:{kind:"value",filterId:l.id})}},I=function(e,t){var r,o=NV(n,t),s=null==o?void 0:o.operators[0];i(a.map(function(r){var n;return r.id===e?NI(NM({},r),{field:t,operator:null!=(n=null==s?void 0:s.value)?n:r.operator,values:[]}):r})),w((null!=(r=null==s?void 0:s.arity)?r:1)===0?null:{kind:"value",filterId:e})},L=function(e,t){var r,o,s=a.find(function(t){return t.id===e}),l=Nz(NV(n,null!=(r=null==s?void 0:s.field)?r:""),t),u=null!=(o=null==l?void 0:l.arity)?o:1;i(a.map(function(r){if(r.id!==e)return r;var n=0===u?[]:(null==l?void 0:l.multi)?r.values:r.values.slice(0,u);return NI(NM({},r),{operator:t,values:n})})),w(0===u?null:{kind:"value",filterId:e})},F=function(e,t,r){i(a.map(function(n){if(n.id!==e)return n;if(!r)return NI(NM({},n),{values:[t]});var a=n.values.includes(t);return NI(NM({},n),{values:a?n.values.filter(function(e){return e!==t}):NL(n.values).concat([t])})})),O(e),window.setTimeout(function(){return O(function(t){return t===e?null:t})},640),r||w(null)},B=function(e,t){i(a.map(function(r){return r.id===e?NI(NM({},r),{values:t}):r}))},V=function(e,t){i(a.filter(function(t){return t.id!==e})),w(null);var r=Math.max(0,(null!=t?t:P)-1);requestAnimationFrame(function(){return R(r)})},z=g.useCallback(function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";e.loadOptions&&(T(function(t){var r,n;return NI(NM({},t),NR({},e.id,{loading:!0,error:!1,options:null!=(r=null==(n=t[e.id])?void 0:n.options)?r:[]}))}),e.loadOptions(t).then(function(t){return T(function(r){return NI(NM({},r),NR({},e.id,{loading:!1,error:!1,options:t}))})}).catch(function(){return T(function(t){return NI(NM({},t),NR({},e.id,{loading:!1,error:!0,options:[]}))})}))},[]);g.useEffect(function(){if(x&&"value"===x.kind){var e,t,r=a.find(function(e){return e.id===x.filterId}),i=NV(n,null!=(e=null==r?void 0:r.field)?e:"");(null==i?void 0:i.loadOptions)&&!(null==(t=C[i.id])?void 0:t.options.length)&&z(i)}},[x]);var W=0,$=function(){var e=W++;return{idx:e,register:function(t){return k.current[e]=t},tabIndex:e===P?0:-1,onFocus:function(){return A(e)}}},U=x?"add"===x.kind?"add":"".concat(x.filterId,":").concat(x.kind):null,H=function(){if(!x)return"";if("add"===x.kind)return u;if("field"===x.kind)return"Modifier le champ du filtre";if("operator"===x.kind)return"Choisir un op\xe9rateur";var e,t=a.find(function(e){return e.id===x.filterId}),r=NV(n,null!=(e=null==t?void 0:t.field)?e:"");return r?"Valeur pour ".concat(r.label):"Valeur du filtre"}(),G=a.length>1;return(0,v.jsxs)("div",{role:"toolbar","aria-label":void 0===m?"Filtres":m,"aria-orientation":"horizontal","aria-disabled":p||void 0,onKeyDown:function(e){if(!x){var t=N.length-1;if("ArrowRight"===e.key)e.preventDefault(),R(P>=t?0:P+1);else if("ArrowLeft"===e.key)e.preventDefault(),R(P<=0?t:P-1);else if("Home"===e.key)e.preventDefault(),R(0);else if("End"===e.key)e.preventDefault(),R(t);else if("Backspace"===e.key||"Delete"===e.key){var r=N[P];(null==r?void 0:r.filterId)&&(e.preventDefault(),V(r.filterId,P))}}},className:["flex flex-wrap items-center gap-1.5",p?"pointer-events-none opacity-50":"",null!=h?h:""].join(" "),children:[(0,v.jsx)("style",{children:"\n:root {\n --fb-fg: #18181b;\n --fb-fg-muted: #71717a;\n --fb-fg-subtle: #a1a1aa;\n --fb-fg-on-accent: #ffffff;\n --fb-bg-surface: #ffffff;\n --fb-bg-chip: rgba(24, 24, 27, 0.04);\n --fb-bg-hover: rgba(24, 24, 27, 0.06);\n --fb-bg-active: rgba(24, 24, 27, 0.08);\n --fb-border: rgba(24, 24, 27, 0.09);\n --fb-border-strong: #18181b;\n --fb-accent: #3b82f6;\n --fb-accent-rgb: 59 130 246;\n}\n.dark {\n --fb-fg: #f4f4f5;\n --fb-fg-muted: #a1a1aa;\n --fb-fg-subtle: #71717a;\n --fb-fg-on-accent: #18181b;\n --fb-bg-surface: #18181b;\n --fb-bg-chip: rgba(255, 255, 255, 0.05);\n --fb-bg-hover: rgba(255, 255, 255, 0.08);\n --fb-bg-active: rgba(255, 255, 255, 0.12);\n --fb-border: rgba(255, 255, 255, 0.08);\n --fb-border-strong: #f4f4f5;\n --fb-accent: #60a5fa;\n --fb-accent-rgb: 96 165 250;\n}\n@keyframes fb-flash {\n 0% { background-color: rgb(var(--fb-accent-rgb) / 0.18); }\n 100% { background-color: transparent; }\n}\n@media (prefers-reduced-motion: reduce) {\n @keyframes fb-flash {\n 0%, 100% { background-color: transparent; }\n }\n}\n"}),(0,v.jsx)(jA,{initial:!1,mode:"popLayout",children:a.map(function(e){var t,r,a,i,o,s,l,u,c,d=NV(n,e.field),f=Nz(d,e.operator),p=null!=(t=null==f?void 0:f.arity)?t:1,h=null!=(r=null==d?void 0:d.type)?r:"select",m=0===p?{text:"—",empty:!1,glyphs:[]}:"select"===h?function(e,t){if(!t.length)return{text:"Choisir…",empty:!0,glyphs:[]};var r=function(t){return null==e?void 0:e.find(function(e){return e.value===t})},n=function(e){var t,n;return null!=(t=null==(n=r(e))?void 0:n.label)?t:e},a=t.map(function(e){var t;return null==(t=r(e))?void 0:t.glyph}).filter(Boolean).slice(0,3);return 1===t.length?{text:n(t[0]),empty:!1,glyphs:a}:t.length<=3?{text:t.map(n).join(", "),empty:!1,glyphs:a}:{text:"".concat(n(t[0])," +").concat(t.length-1),empty:!1,glyphs:a}}((null==d?void 0:d.loadOptions)?null==(c=C[d.id])?void 0:c.options:null==d?void 0:d.options,e.values):function(e,t,r){if(0===t)return{text:"—",empty:!1,glyphs:[]};if(!r.some(function(e){return""!==e&&null!=e}))return{text:"Choisir une valeur…",empty:!0,glyphs:[]};var n,a,i,o=function(t){if(!t)return"…";if("date"!==e)return t;var r=new Date(t);return Number.isNaN(r.getTime())?t:r.toLocaleDateString()};return 2===t?{text:"".concat(o(null!=(a=r[0])?a:"")," – ").concat(o(null!=(i=r[1])?i:"")),empty:!1,glyphs:[]}:{text:o(null!=(n=r[0])?n:""),empty:!1,glyphs:[]}}(h,p,e.values),g=$(),b=$(),S=$(),O=$(),k=j===e.id;return(0,v.jsxs)(hz.div,{layout:!y,initial:!y&&{opacity:0,scale:.9},animate:{opacity:1,scale:1},exit:y?{opacity:0}:{opacity:0,scale:.9},transition:NB,className:"group flex items-stretch overflow-hidden rounded-md border border-[var(--fb-border)] bg-[var(--fb-bg-chip)]",children:[(0,v.jsxs)(NH,{role:"field",registerRef:g.register,tabIndex:g.tabIndex,onFocus:g.onFocus,anchorKey:"".concat(e.id,":field"),active:(null==x?void 0:x.kind)==="field"&&x.filterId===e.id,ariaLabel:"Champ : ".concat(null!=(a=null==d?void 0:d.label)?a:e.field,". Modifier le champ."),onOpen:function(){return w({kind:"field",filterId:e.id})},children:[(null==d?void 0:d.icon)&&(0,v.jsx)("span",{className:"text-[var(--fb-fg-muted)]","aria-hidden":!0,children:d.icon}),null!=(i=null==d?void 0:d.label)?i:e.field]}),(0,v.jsx)("span",{"aria-hidden":!0,className:"w-px self-stretch bg-[var(--fb-border)]"}),(0,v.jsx)(NH,{role:"operator",registerRef:b.register,tabIndex:b.tabIndex,onFocus:b.onFocus,anchorKey:"".concat(e.id,":operator"),muted:!0,active:(null==x?void 0:x.kind)==="operator"&&x.filterId===e.id,ariaLabel:"Op\xe9rateur : ".concat(null!=(o=null==f?void 0:f.label)?o:e.operator,". Modifier l'op\xe9rateur."),onOpen:function(){return w({kind:"operator",filterId:e.id})},children:null!=(s=null==f?void 0:f.label)?s:e.operator}),(0,v.jsx)("span",{"aria-hidden":!0,className:"w-px self-stretch bg-[var(--fb-border)]"}),(0,v.jsxs)(NH,{role:"value",registerRef:S.register,tabIndex:S.tabIndex,onFocus:S.onFocus,anchorKey:"".concat(e.id,":value"),muted:m.empty||0===p,disabled:0===p,active:(null==x?void 0:x.kind)==="value"&&x.filterId===e.id,flash:k,ariaLabel:0===p?"Valeur : aucune valeur requise pour l'op\xe9rateur ".concat(null!=(l=null==f?void 0:f.label)?l:e.operator,"."):"Valeur : ".concat(m.empty?"aucune s\xe9lectionn\xe9e":m.text,". Modifier la valeur."),onOpen:function(){0!==p&&w({kind:"value",filterId:e.id})},children:[!m.empty&&m.glyphs.length>0&&(0,v.jsx)("span",{className:"flex shrink-0 items-center gap-0.5","aria-hidden":!0,children:m.glyphs.map(function(e,t){return(0,v.jsx)("span",{className:"flex items-center",children:e},t)})}),(0,v.jsx)("span",{className:"max-w-[12rem] truncate font-medium text-[var(--fb-fg)]",children:m.empty?(0,v.jsx)("span",{className:"font-normal text-[var(--fb-fg-subtle)]",children:m.text}):m.text})]}),(0,v.jsx)("button",{type:"button",ref:O.register,tabIndex:O.tabIndex,onFocus:O.onFocus,onClick:function(){return V(e.id,O.idx)},"aria-label":"Supprimer le filtre ".concat(null!=(u=null==d?void 0:d.label)?u:e.field),className:"flex items-center px-1.5 text-[var(--fb-fg-subtle)] transition-colors hover:bg-[var(--fb-bg-hover)] hover:text-[var(--fb-fg)] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-[var(--fb-accent)]/70 active:scale-[0.98]",children:(0,v.jsx)(Nq,{})})]},e.id)})}),(t=$(),r=0===a.length,(0,v.jsxs)("button",{type:"button",ref:t.register,tabIndex:t.tabIndex,onFocus:t.onFocus,"data-fb-anchor":"add","aria-label":r?u:s,"aria-haspopup":"listbox","aria-expanded":(null==x?void 0:x.kind)==="add",onClick:function(){return w({kind:"add"})},className:"flex items-center gap-1 rounded-md border border-dashed border-[var(--fb-border)] px-2 py-[6px] text-[13px] font-medium leading-none text-[var(--fb-fg-muted)] transition-colors hover:border-[var(--fb-border-strong)]/40 hover:bg-[var(--fb-bg-hover)] hover:text-[var(--fb-fg)] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--fb-accent)]/70 active:scale-[0.98]",children:[(0,v.jsx)(NK,{}),r?u:s]})),G&&(0,v.jsx)("button",{type:"button",onClick:function(){i([]),w(null),requestAnimationFrame(function(){return R(0)})},className:"ml-0.5 rounded-md px-2 py-[6px] text-[13px] leading-none text-[var(--fb-fg-muted)] transition-colors hover:bg-[var(--fb-bg-hover)] hover:text-[var(--fb-fg)] focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--fb-accent)]/70",children:void 0===c?"R\xe9initialiser":c}),x&&U&&(0,v.jsx)(NW,{anchorKey:U,label:H,onClose:function(){return w(null)},children:function(){if(!x)return null;if("add"===x.kind||"field"===x.kind){var e,t,r,i,o,s="field"===x.kind?x.filterId:null,l=new Set(a.filter(function(e){return e.id!==s}).map(function(e){return e.field})),u=n.filter(function(e){return f||!l.has(e.id)}).map(function(e){return{value:e.id,label:e.label,glyph:e.icon}});return(0,v.jsx)(N$,{ariaLabel:H,items:u,multi:!1,onPick:function(e){return"add"===x.kind?M(e):I(x.filterId,e)}},null!=U?U:void 0)}var c=a.find(function(e){return e.id===x.filterId}),d=NV(n,null!=(e=null==c?void 0:c.field)?e:"");if(!c||!d)return null;if("operator"===x.kind){var p=d.operators.map(function(e){return{value:e.value,label:e.label,selected:e.value===c.operator}});return(0,v.jsx)(N$,{ariaLabel:H,items:p,multi:!1,searchable:p.length>6,onPick:function(e){return L(c.id,e)}},null!=U?U:void 0)}var h=Nz(d,c.operator),m=null!=(t=null==h?void 0:h.arity)?t:1;if(0===m)return null;var y=null!=(r=d.type)?r:"select";if("text"===y||"number"===y||"date"===y)return(0,v.jsx)(NU,{inputType:y,arity:m,values:c.values,onCommit:function(e){return B(c.id,e)},ariaLabel:H,rangeLabels:"date"===y?["Du","Au"]:["Min","Max"],placeholder:"text"===y?"Rechercher…":void 0},null!=U?U:void 0);var g=!!(null==h?void 0:h.multi),b=d.loadOptions?C[d.id]:void 0,w=(d.loadOptions?null!=(i=null==b?void 0:b.options)?i:[]:null!=(o=d.options)?o:[]).map(function(e){return{value:e.value,label:e.label,glyph:e.glyph,selected:c.values.includes(e.value)}});return(0,v.jsx)(N$,{ariaLabel:H,items:w,multi:g,loading:null==b?void 0:b.loading,error:null==b?void 0:b.error,onQuery:d.loadOptions?function(e){return z(d,e)}:void 0,onRetry:function(){return z(d)},onPick:function(e){return F(c.id,e,g)}},null!=U?U:void 0)}()})]})}function NK(){return(0,v.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":!0,children:(0,v.jsx)("path",{d:"M6 2.5v7M2.5 6h7",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}function Nq(){return(0,v.jsx)("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none","aria-hidden":!0,children:(0,v.jsx)("path",{d:"M3 3l6 6M9 3l-6 6",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})})}function NY(){return(0,v.jsx)("svg",{width:"11",height:"11",viewBox:"0 0 12 12",fill:"none","aria-hidden":!0,children:(0,v.jsx)("path",{d:"M2.5 6.2l2.2 2.3L9.5 3.7",stroke:"currentColor",strokeWidth:"1.6",strokeLinecap:"round",strokeLinejoin:"round"})})}function NX(){return(0,v.jsxs)("svg",{width:"14",height:"14",viewBox:"0 0 14 14",fill:"none","aria-hidden":!0,className:"animate-spin",children:[(0,v.jsx)("circle",{cx:"7",cy:"7",r:"5.5",stroke:"currentColor",strokeOpacity:"0.2",strokeWidth:"1.5"}),(0,v.jsx)("path",{d:"M12.5 7A5.5 5.5 0 0 0 7 1.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]})}let NZ=NG;var NQ={text:[{value:"contains",label:"contient"},{value:"not_contains",label:"ne contient pas"},{value:"equals",label:"est exactement"},{value:"starts_with",label:"commence par"},{value:"is_empty",label:"est vide",arity:0},{value:"is_not_empty",label:"n'est pas vide",arity:0}],number:[{value:"eq",label:"="},{value:"neq",label:"≠"},{value:"gt",label:">"},{value:"gte",label:"≥"},{value:"lt",label:"<"},{value:"lte",label:"≤"},{value:"between",label:"entre",arity:2}],date:[{value:"on",label:"le"},{value:"before",label:"avant le"},{value:"after",label:"apr\xe8s le"},{value:"between",label:"entre",arity:2}],boolean:[{value:"is",label:"est"}],select:[{value:"is",label:"est"},{value:"is_not",label:"n'est pas"},{value:"is_any_of",label:"est l'un de",multi:!0}]},NJ=[{value:"true",label:"Oui"},{value:"false",label:"Non"}];function N0(e,t){var r=function(e){var r,n;return null!=(r=null==(n=t.find(function(t){return t.field===e}))?void 0:n.values)?r:[]};return e.fields.filter(function(e){return!e.dependsOn||r(e.dependsOn).length>0}).map(function(e){if("boolean"===e.type)return{id:e.id,label:e.label,icon:e.icon,type:"select",operators:null!=(a=e.operators)?a:NQ.boolean,options:null!=(i=e.options)?i:NJ};var t,n,a,i,o=null!=(t=e.operators)?t:NQ[e.type];if("select"!==e.type)return{id:e.id,label:e.label,icon:e.icon,type:e.type,operators:o};var s=e.dependsOn?r(e.dependsOn):[];return e.optionsByParent?{id:e.id,label:e.label,icon:e.icon,type:"select",operators:o,options:s.flatMap(function(t){var r,n;return null!=(r=null==(n=e.optionsByParent)?void 0:n[t])?r:[]})}:e.loadOptions?{id:e.id,label:e.label,icon:e.icon,type:"select",operators:o,loadOptions:function(t){return e.loadOptions(t,{parentValues:s})}}:{id:e.id,label:e.label,icon:e.icon,type:"select",operators:o,options:null!=(n=e.options)?n:[]}})}function N1(e,t){for(var r=t,n=0;n<e.fields.length&&"break"!==function(){var t=!1,n=r.filter(function(n){var a=e.fields.find(function(e){return e.id===n.field});if(!(null==a?void 0:a.dependsOn))return!0;var i=r.find(function(e){return e.field===a.dependsOn}),o=!!i&&i.values.length>0;return o||(t=!0),o});if(r=n.map(function(r){var a,i=e.fields.find(function(e){return e.id===r.field});if(!(null==i?void 0:i.dependsOn)||!i.optionsByParent)return r;var o=n.find(function(e){return e.field===i.dependsOn}),s=new Set((null!=(a=null==o?void 0:o.values)?a:[]).flatMap(function(e){var t,r,n;return null!=(t=null==(n=i.optionsByParent)||null==(r=n[e])?void 0:r.map(function(e){return e.value}))?t:[]})),l=r.values.filter(function(e){return s.has(e)});return l.length!==r.values.length&&(t=!0),l.length===r.values.length?r:NI(NM({},r),{values:l})}),!t)return"break"}();n++);return r}function N2(e,t,r){return{fields:g.useMemo(function(){return N0(e,t)},[e,t]),onChange:g.useCallback(function(t){return r(N1(e,t))},[e,r])}}function N3(e,t,r,n){var a=function(e){return null==e?"":String(e)};switch(t){case"is_empty":return""===a(r);case"is_not_empty":return""!==a(r);case"contains":return a(r).toLowerCase().includes(a(n[0]).toLowerCase());case"not_contains":return!a(r).toLowerCase().includes(a(n[0]).toLowerCase());case"starts_with":return a(r).toLowerCase().startsWith(a(n[0]).toLowerCase());case"equals":return a(r).toLowerCase()===a(n[0]).toLowerCase();case"is":return a(r)===n[0];case"is_not":return a(r)!==n[0];case"is_any_of":return n.includes(a(r));case"eq":return Number(r)===Number(n[0]);case"neq":return Number(r)!==Number(n[0]);case"gt":return Number(r)>Number(n[0]);case"gte":return Number(r)>=Number(n[0]);case"lt":return Number(r)<Number(n[0]);case"lte":return Number(r)<=Number(n[0]);case"between":var i=N_(n,2),o=i[0],s=i[1];if("date"===e){var l=new Date(a(r)).getTime(),u=!o||l>=new Date(o).getTime(),c=!s||l<=new Date(s).getTime();return u&&c}var d=Number(r),f=void 0===o||""===o||d>=Number(o),p=void 0===s||""===s||d<=Number(s);return f&&p;case"on":return a(r).slice(0,10)===a(n[0]).slice(0,10);case"before":return new Date(a(r)).getTime()<new Date(n[0]).getTime();case"after":return new Date(a(r)).getTime()>new Date(n[0]).getTime();default:return!0}}function N4(e,t,r,n){return Array.isArray(r)?r.some(function(r){return N3(e,t,r,n)}):N3(e,t,r,n)}function N5(e,t){return"is_empty"===e||"is_not_empty"===e||t.some(function(e){return""!==e&&void 0!==e})}function N6(e,t,r,n){return t.every(function(t){if(!N5(t.operator,t.values))return!0;var a=r.fields.find(function(e){return e.id===t.field}),i=null==a?void 0:a.type;return N4("boolean"===i||void 0===i?"select":i,t.operator,n(e,t.field),t.values)})}var N8=["\xe9lections","corruption","budget","diplomatie","sant\xe9","\xe9ducation","climat","s\xe9curit\xe9"],N9={fields:[{id:"status",label:"Statut",type:"select",options:[{value:"draft",label:"Brouillon"},{value:"published",label:"Publi\xe9"},{value:"archived",label:"Archiv\xe9"}]},{id:"category",label:"Cat\xe9gorie",type:"select",options:[{value:"politique",label:"Politique"},{value:"sport",label:"Sport"},{value:"economie",label:"\xc9conomie"},{value:"culture",label:"Culture"}]},{id:"subcategory",label:"Sous-cat\xe9gorie",type:"select",dependsOn:"category",optionsByParent:{politique:[{value:"national",label:"National"},{value:"international",label:"International"},{value:"institutions",label:"Institutions"}],sport:[{value:"football",label:"Football"},{value:"basketball",label:"Basketball"},{value:"athletisme",label:"Athl\xe9tisme"}],economie:[{value:"marches",label:"March\xe9s"},{value:"entreprises",label:"Entreprises"},{value:"emploi",label:"Emploi"}],culture:[{value:"musique",label:"Musique"},{value:"cinema",label:"Cin\xe9ma"},{value:"litterature",label:"Litt\xe9rature"}]}},{id:"tags",label:"Tags",type:"select",loadOptions:function(e){return new Promise(function(t){window.setTimeout(function(){var r=e.trim().toLowerCase();t(N8.filter(function(e){return e.toLowerCase().includes(r)}).map(function(e){return{value:e,label:e}}))},350)})}},{id:"title",label:"Titre",type:"text"},{id:"views",label:"Vues",type:"number"},{id:"publishedAt",label:"Date de publication",type:"date"},{id:"featured",label:"\xc0 la une",type:"boolean"}]},N7=[{id:"1",title:"Le budget 2027 d\xe9voil\xe9 \xe0 l'Assembl\xe9e",status:"published",category:"politique",subcategory:"national",tags:["budget","\xe9lections"],views:4300,publishedAt:"2026-09-02",featured:!0},{id:"2",title:"Sommet r\xe9gional sur le climat \xe0 Libreville",status:"published",category:"politique",subcategory:"international",tags:["climat","diplomatie"],views:2100,publishedAt:"2026-08-20",featured:!1},{id:"3",title:"Les Panth\xe8res qualifi\xe9es pour la CAN",status:"published",category:"sport",subcategory:"football",tags:["football"],views:9800,publishedAt:"2026-09-10",featured:!0},{id:"4",title:"R\xe9forme du syst\xe8me \xe9ducatif : ce qui change",status:"draft",category:"politique",subcategory:"institutions",tags:["\xe9ducation"],views:120,publishedAt:"2026-09-15",featured:!1},{id:"5",title:"Les march\xe9s locaux r\xe9sistent \xe0 l'inflation",status:"published",category:"economie",subcategory:"marches",tags:["budget"],views:1560,publishedAt:"2026-07-30",featured:!1},{id:"6",title:"Festival de musique urbaine \xe0 Port-Gentil",status:"published",category:"culture",subcategory:"musique",tags:[],views:870,publishedAt:"2026-09-05",featured:!1},{id:"7",title:"Nouvelle campagne de sensibilisation lanc\xe9e",status:"published",category:"politique",subcategory:"national",tags:["sant\xe9"],views:3400,publishedAt:"2026-06-18",featured:!1},{id:"8",title:"Championnat national de basketball : bilan",status:"archived",category:"sport",subcategory:"basketball",tags:[],views:640,publishedAt:"2026-05-02",featured:!1}];function Re(e,t){switch(t){case"status":return e.status;case"category":return e.category;case"subcategory":return e.subcategory;case"tags":return e.tags;case"title":return e.title;case"views":return e.views;case"publishedAt":return e.publishedAt;case"featured":return e.featured;default:return}}var Rt={contains:"icontains",not_contains:"icontains",equals:"iexact",starts_with:"istartswith",is_empty:"isnull",is_not_empty:"isnull",eq:"exact",neq:"exact",gt:"gt",gte:"gte",lt:"lt",lte:"lte",on:"exact",before:"lt",after:"gt",is:"exact",is_not:"exact",is_any_of:"in"};function Rr(){var e=N_(g.useState([]),2),t=e[0],r=N2(N9,t,e[1]),n=r.fields,a=r.onChange,i=g.useMemo(function(){return N7.filter(function(e){return N6(e,t,N9,Re)})},[t]),o=g.useMemo(function(){return function(e){var t=new URLSearchParams,r=!0,n=!1,a=void 0;try{for(var i,o=e[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s,l,u=i.value;if(N5(u.operator,u.values)){if("between"===u.operator){var c=N_(u.values,2),d=c[0],f=c[1];d&&t.append("".concat(u.field,"__gte"),d),f&&t.append("".concat(u.field,"__lte"),f);continue}if("is_empty"===u.operator){t.append("".concat(u.field,"__isnull"),"true");continue}if("is_not_empty"===u.operator){t.append("".concat(u.field,"__isnull"),"false");continue}var p=null!=(s=Rt[u.operator])?s:"exact",h="is_any_of"===u.operator?u.values.join(","):null!=(l=u.values[0])?l:"";t.append("".concat(u.field,"__").concat(p),h)}}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}return t.toString()}(t)},[t]);return(0,v.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,v.jsx)(NG,{fields:n,value:t,onChange:a,"aria-label":"Filtrer les articles"}),(0,v.jsxs)("ul",{className:"flex flex-col gap-2",children:[i.map(function(e){return(0,v.jsxs)("li",{className:"rounded-md border border-[var(--fb-border)] px-3 py-2 text-[13px] text-[var(--fb-fg)]",children:[(0,v.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,v.jsx)("span",{className:"font-medium",children:e.title}),e.featured&&(0,v.jsx)("span",{className:"text-[var(--fb-fg-muted)]",children:"★ \xe0 la une"})]}),(0,v.jsxs)("div",{className:"mt-0.5 text-[12px] text-[var(--fb-fg-muted)]",children:[e.category," / ",e.subcategory," \xb7 ",e.views," vues \xb7 ",new Date(e.publishedAt).toLocaleDateString()]})]},e.id)}),0===i.length&&(0,v.jsx)("li",{className:"rounded-md border border-dashed border-[var(--fb-border)] px-3 py-4 text-center text-[13px] text-[var(--fb-fg-muted)]",children:"Aucun article ne correspond \xe0 ces filtres."})]}),(0,v.jsxs)("details",{className:"text-[12px] text-[var(--fb-fg-muted)]",children:[(0,v.jsx)("summary",{className:"cursor-pointer select-none",children:"Voir l'\xe9tat brut (\xe0 des fins p\xe9dagogiques)"}),(0,v.jsx)("p",{className:"mt-2",children:"\xc9tat `filters` produit par <FilterBar> :"}),(0,v.jsx)("pre",{className:"mt-1 overflow-x-auto rounded-md bg-[var(--fb-bg-chip)] p-2",children:JSON.stringify(t,null,2)}),(0,v.jsx)("p",{className:"mt-2",children:"Query string \xe9quivalente (convention django-filter) :"}),(0,v.jsxs)("pre",{className:"mt-1 overflow-x-auto rounded-md bg-[var(--fb-bg-chip)] p-2",children:["?",o||"(aucun filtre actif)"]})]})]})}var Rn=(0,ya.A)("Image",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]]),Ra=(0,ya.A)("Video",[["path",{d:"m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",key:"ftymec"}],["rect",{x:"2",y:"6",width:"14",height:"12",rx:"2",key:"158x01"}]]),Ri=(0,ya.A)("Music",[["path",{d:"M9 18V5l12-2v13",key:"1jmyc2"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["circle",{cx:"18",cy:"16",r:"3",key:"1hluhg"}]]),Ro=(0,ya.A)("Archive",[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]]),Rs=(0,ya.A)("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),Rl=(0,ya.A)("Grid3x3",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}],["path",{d:"M3 15h18",key:"5xshup"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"M15 3v18",key:"14nvp0"}]]);function Ru(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function Rc(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Ru(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Ru(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Rd(e){var t,r=e.currentCategory,n=e.onSelectCategory,a=e.sortOption,i=e.onSelectSort,o=e.viewMode,s=e.onToggleViewMode,l=e.typeFilter,u=e.onSelectTypeFilter,c=Rc((0,g.useState)(!1),2),d=c[0],f=c[1],p=Rc((0,g.useState)(!1),2),h=p[0],m=p[1],y=[{id:"all",label:"Tout",icon:(0,v.jsx)(OF,{className:"w-3.5 h-3.5"})},{id:"documents",label:"Documents",icon:(0,v.jsx)(OQ,{className:"w-3.5 h-3.5"})},{id:"images",label:"Images",icon:(0,v.jsx)(Rn,{className:"w-3.5 h-3.5"})},{id:"videos",label:"Vid\xe9os",icon:(0,v.jsx)(Ra,{className:"w-3.5 h-3.5"})},{id:"music",label:"Musique",icon:(0,v.jsx)(Ri,{className:"w-3.5 h-3.5"})},{id:"archives",label:"Archives",icon:(0,v.jsx)(Ro,{className:"w-3.5 h-3.5"})}],b=[{id:"recent",label:"Plus r\xe9cents"},{id:"oldest",label:"Plus anciens"},{id:"name_asc",label:"Nom A → Z"},{id:"name_desc",label:"Nom Z → A"},{id:"items_count",label:"Nombre d’\xe9l\xe9ments"}],x=(null==(t=b.find(function(e){return e.id===a}))?void 0:t.label)||"Plus r\xe9cents";return(0,v.jsxs)("div",{className:"w-full flex flex-col sm:flex-row items-stretch sm:items-center justify-between gap-2.5 py-1 relative z-20",children:[(0,v.jsx)("div",{className:"flex items-center gap-1.5 overflow-x-auto pb-1 sm:pb-0 scrollbar-none w-full sm:w-auto",children:y.map(function(e){var t=r===e.id;return(0,v.jsxs)("button",{onClick:function(){return n(e.id)},className:"flex items-center gap-1 px-2.5 py-1 rounded-lg text-[10px] sm:text-xs font-semibold whitespace-nowrap transition-all duration-200 cursor-pointer ".concat(t?"bg-emerald-500/25 text-white border border-emerald-400/80 shadow-[0_0_12px_rgba(16,185,129,0.3)] drop-shadow-[0_1px_2px_rgba(0,0,0,0.8)]":"bg-transparent text-white/70 hover:text-white hover:bg-white/5 border border-white/10 hover:border-white/20 drop-shadow-[0_1px_1px_rgba(0,0,0,0.8)]"),children:[(0,v.jsx)("span",{className:t?"text-emerald-400":"text-white/60",children:e.icon}),(0,v.jsx)("span",{children:e.label})]},e.id)})}),(0,v.jsxs)("div",{className:"flex items-center justify-between sm:justify-end gap-1.5 sm:gap-2 w-full sm:w-auto mt-0.5 sm:mt-0",children:[(0,v.jsxs)("div",{className:"relative flex-1 sm:flex-none",children:[(0,v.jsxs)("button",{onClick:function(){f(!d),m(!1)},className:"w-full sm:w-auto flex items-center justify-between sm:justify-start gap-1 px-2.5 py-1 rounded-lg text-[10px] sm:text-xs font-semibold bg-black/30 hover:bg-white/5 border border-white/10 hover:border-white/20 text-white/90 transition-colors cursor-pointer",children:[(0,v.jsxs)("div",{className:"flex items-center gap-1",children:[(0,v.jsx)("span",{className:"text-white/40 hidden xs:inline",children:"Tri :"}),(0,v.jsx)("span",{className:"text-white font-semibold truncate max-w-[70px] sm:max-w-none",children:x})]}),(0,v.jsx)(Rs,{className:"w-3 h-3 text-white/50 shrink-0"})]}),d&&(0,v.jsx)("div",{className:"absolute right-0 mt-2 w-44 py-1 rounded-lg bg-[#040d10]/95 border border-white/15 shadow-[0_10px_30px_rgba(0,0,0,0.9)] backdrop-blur-xl z-50 animate-in fade-in zoom-in-95 duration-150",children:b.map(function(e){return(0,v.jsx)("button",{onClick:function(){i(e.id),f(!1)},className:"w-full text-left px-3 py-1.5 text-[10px] sm:text-xs transition-colors cursor-pointer ".concat(a===e.id?"bg-emerald-500/20 text-emerald-300 font-bold":"text-white/75 hover:bg-white/[0.08] hover:text-white"),children:e.label},e.id)})})]}),(0,v.jsxs)("div",{className:"relative flex-1 sm:flex-none",children:[(0,v.jsxs)("button",{onClick:function(){m(!h),f(!1)},className:"w-full sm:w-auto flex items-center justify-between sm:justify-start gap-1 px-2.5 py-1 rounded-lg text-[10px] sm:text-xs font-semibold bg-black/30 hover:bg-white/5 border border-white/10 hover:border-white/20 text-white/90 transition-colors cursor-pointer",children:[(0,v.jsxs)("div",{className:"flex items-center gap-1",children:[(0,v.jsx)("span",{className:"text-white/40 hidden xs:inline",children:"Type :"}),(0,v.jsx)("span",{className:"text-white font-semibold truncate max-w-[60px] sm:max-w-none",children:l})]}),(0,v.jsx)(Rs,{className:"w-3 h-3 text-white/50 shrink-0"})]}),h&&(0,v.jsx)("div",{className:"absolute right-0 mt-2 w-36 py-1 rounded-lg bg-[#040d10]/95 border border-white/15 shadow-[0_10px_30px_rgba(0,0,0,0.9)] backdrop-blur-xl z-50 animate-in fade-in zoom-in-95 duration-150",children:["Tous","Dossiers","Documents","Images","Vid\xe9os","Archives"].map(function(e){return(0,v.jsx)("button",{onClick:function(){u(e),m(!1)},className:"w-full text-left px-3 py-1.5 text-[10px] sm:text-xs transition-colors cursor-pointer ".concat(l===e?"bg-emerald-500/20 text-emerald-300 font-bold":"text-white/75 hover:bg-white/[0.08] hover:text-white"),children:e},e)})})]}),(0,v.jsxs)("div",{className:"flex items-center p-0.5 rounded-lg bg-black/20 border border-white/10 shrink-0",children:[(0,v.jsx)("button",{onClick:function(){return s("grid")},className:"p-1 rounded-md transition-all cursor-pointer ".concat("grid"===o?"bg-emerald-500/20 text-emerald-400":"text-white/40 hover:text-white/70"),title:"Vue Grille",children:(0,v.jsx)(Rl,{className:"w-3.5 h-3.5"})}),(0,v.jsx)("button",{onClick:function(){return s("list")},className:"p-1 rounded-md transition-all cursor-pointer ".concat("list"===o?"bg-emerald-500/20 text-emerald-400":"text-white/40 hover:text-white/70"),title:"Vue Liste",children:(0,v.jsx)(C3,{className:"w-3.5 h-3.5"})})]})]})]})}},8969(e,t,r){"use strict";r.d(t,{cn:()=>ey});var n=r(7064);let a=(e=new Map,t=null,r)=>({nextPart:e,validators:t,classGroupId:r}),i=[],o=(e,t,r)=>{if(0==e.length-t)return r.classGroupId;let n=e[t],a=r.nextPart.get(n);if(a){let r=o(e,t+1,a);if(r)return r}let i=r.validators;if(null===i)return;let s=0===t?e.join("-"):e.slice(t).join("-"),l=i.length;for(let e=0;e<l;e++){let t=i[e];if(t.validator(s))return t.classGroupId}},s=(e,t)=>{let r=a();for(let n in e)l(e[n],r,n,t);return r},l=(e,t,r,n)=>{let a=e.length;for(let i=0;i<a;i++)u(e[i],t,r,n)},u=(e,t,r,n)=>{"string"==typeof e?c(e,t,r):"function"==typeof e?d(e,t,r,n):f(e,t,r,n)},c=(e,t,r)=>{(""===e?t:p(t,e)).classGroupId=r},d=(e,t,r,n)=>{h(e)?l(e(n),t,r,n):(null===t.validators&&(t.validators=[]),t.validators.push({classGroupId:r,validator:e}))},f=(e,t,r,n)=>{let a=Object.entries(e),i=a.length;for(let e=0;e<i;e++){let[i,o]=a[e];l(o,p(t,i),r,n)}},p=(e,t)=>{let r=e,n=t.split("-"),i=n.length;for(let e=0;e<i;e++){let t=n[e],i=r.nextPart.get(t);i||(i=a(),r.nextPart.set(t,i)),r=i}return r},h=e=>"isThemeGetter"in e&&!0===e.isThemeGetter,m=[],y=(e,t,r,n,a)=>({modifiers:e,hasImportantModifier:t,baseClassName:r,maybePostfixModifierPosition:n,isExternal:a}),v=/\s+/,g=e=>{let t;if("string"==typeof e)return e;let r="";for(let n=0;n<e.length;n++)e[n]&&(t=g(e[n]))&&(r&&(r+=" "),r+=t);return r},b=[],x=e=>{let t=t=>t[e]||b;return t.isThemeGetter=!0,t.themeKey=e,t},w=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,S=/^\((?:(\w[\w-]*):)?(.+)\)$/i,j=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,O=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,k=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,E=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix|color|light-dark)\(.+\)$/,P=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,A=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,D=e=>j.test(e),C=e=>!!e&&!Number.isNaN(Number(e)),T=e=>!!e&&Number.isInteger(Number(e)),N=e=>e.endsWith("%")&&C(e.slice(0,-1)),R=e=>O.test(e),M=()=>!0,I=e=>k.test(e)&&!E.test(e),L=()=>!1,F=e=>P.test(e),B=e=>A.test(e),V=e=>!$(e)&&!Z(e),z=e=>e.startsWith("@container")&&("/"===e[10]&&void 0!==e[11]||"s"===e[11]&&void 0!==e[16]&&e.startsWith("-size/",10)||"n"===e[11]&&void 0!==e[18]&&e.startsWith("-normal/",10)),W=e=>ei(e,eu,L),$=e=>w.test(e),U=e=>ei(e,ec,I),H=e=>ei(e,ed,C),G=e=>ei(e,ep,M),K=e=>ei(e,ef,L),q=e=>ei(e,es,L),Y=e=>ei(e,el,B),X=e=>ei(e,eh,F),Z=e=>S.test(e),Q=e=>eo(e,ec),J=e=>eo(e,ef),ee=e=>eo(e,es),et=e=>eo(e,eu),er=e=>eo(e,el),en=e=>eo(e,eh,!0),ea=e=>eo(e,ep,!0),ei=(e,t,r)=>{let n=w.exec(e);return!!n&&(n[1]?t(n[1]):r(n[2]))},eo=(e,t,r=!1)=>{let n=S.exec(e);return!!n&&(n[1]?t(n[1]):r)},es=e=>"position"===e||"percentage"===e,el=e=>"image"===e||"url"===e,eu=e=>"length"===e||"size"===e||"bg-size"===e,ec=e=>"length"===e,ed=e=>"number"===e,ef=e=>"family-name"===e,ep=e=>"number"===e||"weight"===e,eh=e=>"shadow"===e,em=((e,...t)=>{let r,n,a,l,u=e=>{let t=n(e);if(t)return t;let i=((e,t)=>{let{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:a,sortModifiers:i,postfixLookupClassGroupIds:o}=t,s=[],l=e.trim().split(v),u="";for(let e=l.length-1;e>=0;e-=1){let t,c=l[e],{isExternal:d,modifiers:f,hasImportantModifier:p,baseClassName:h,maybePostfixModifierPosition:m}=r(c);if(d){u=c+(u.length>0?" "+u:u);continue}let y=!!m;if(y){let e=(t=n(h.substring(0,m)))&&o[t]?n(h):void 0;e&&e!==t&&(t=e,y=!1)}else t=n(h);if(!t){if(!y||!(t=n(h))){u=c+(u.length>0?" "+u:u);continue}y=!1}let v=0===f.length?"":1===f.length?f[0]:i(f).join(":"),g=p?v+"!":v,b=g+t;if(s.indexOf(b)>-1)continue;s.push(b);let x=a(t,y);for(let e=0;e<x.length;++e){let t=x[e];s.push(g+t)}u=c+(u.length>0?" "+u:u)}return u})(e,r);return a(e,i),i};return l=c=>{var d;let f;return n=(r={cache:(e=>{if(e<1)return{get:()=>void 0,set:()=>{}};let t=0,r=Object.create(null),n=Object.create(null),a=(a,i)=>{r[a]=i,++t>e&&(t=0,n=r,r=Object.create(null))};return{get(e){let t=r[e];return void 0!==t?t:void 0!==(t=n[e])?(a(e,t),t):void 0},set(e,t){e in r?r[e]=t:a(e,t)}}})((d=t.reduce((e,t)=>t(e),e())).cacheSize),parseClassName:(e=>{let{prefix:t,experimentalParseClassName:r}=e,n=e=>{let t,r=[],n=0,a=0,i=0,o=e.length;for(let s=0;s<o;s++){let o=e[s];if(0===n&&0===a){if(":"===o){r.push(e.slice(i,s)),i=s+1;continue}if("/"===o){t=s;continue}}"["===o?n++:"]"===o?n--:"("===o?a++:")"===o&&a--}let s=0===r.length?e:e.slice(i),l=s,u=!1;return s.endsWith("!")?(l=s.slice(0,-1),u=!0):s.startsWith("!")&&(l=s.slice(1),u=!0),y(r,u,l,t&&t>i?t-i:void 0)};if(t){let e=t+":",r=n;n=t=>t.startsWith(e)?r(t.slice(e.length)):y(m,!1,t,void 0,!0)}if(r){let e=n;n=t=>r({className:t,parseClassName:e})}return n})(d),sortModifiers:(f=new Map,d.orderSensitiveModifiers.forEach((e,t)=>{f.set(e,1e6+t)}),e=>{let t=[],r=[];for(let n=0;n<e.length;n++){let a=e[n],i="["===a[0],o=f.has(a);i||o?(r.length>0&&(r.sort(),t.push(...r),r=[]),t.push(a)):r.push(a)}return r.length>0&&(r.sort(),t.push(...r)),t}),postfixLookupClassGroupIds:(e=>{let t=Object.create(null),r=e.postfixLookupClassGroups;if(r)for(let e=0;e<r.length;e++)t[r[e]]=!0;return t})(d),...(e=>{let t=(e=>{let{theme:t,classGroups:r}=e;return s(r,t)})(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:e=>{if(e.startsWith("[")&&e.endsWith("]")){var r;let t,n,a;return -1===(r=e).slice(1,-1).indexOf(":")?void 0:(n=(t=r.slice(1,-1)).indexOf(":"),(a=t.slice(0,n))?"arbitrary.."+a:void 0)}let n=e.split("-"),a=+(""===n[0]&&n.length>1);return o(n,a,t)},getConflictingClassGroupIds:(e,t)=>{if(t){let t=n[e],a=r[e];if(t){if(a){let e=Array(a.length+t.length);for(let t=0;t<a.length;t++)e[t]=a[t];for(let r=0;r<t.length;r++)e[a.length+r]=t[r];return e}return t}return a||i}return r[e]||i}}})(d)}).cache.get,a=r.cache.set,l=u,u(c)},(...e)=>l(((...e)=>{let t,r,n=0,a="";for(;n<e.length;)(t=e[n++])&&(r=g(t))&&(a&&(a+=" "),a+=r);return a})(...e))})(()=>{let e=x("color"),t=x("font"),r=x("text"),n=x("font-weight"),a=x("tracking"),i=x("leading"),o=x("breakpoint"),s=x("container"),l=x("spacing"),u=x("radius"),c=x("shadow"),d=x("inset-shadow"),f=x("text-shadow"),p=x("drop-shadow"),h=x("blur"),m=x("perspective"),y=x("aspect"),v=x("ease"),g=x("animate"),b=()=>["auto","avoid","all","avoid-page","page","left","right","column"],w=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],S=()=>[...w(),Z,$],j=()=>["auto","hidden","clip","visible","scroll"],O=()=>["auto","contain","none"],k=()=>[Z,$,l],E=()=>[D,"full","auto",...k()],P=()=>[T,"none","subgrid",Z,$],A=()=>["auto",{span:["full",T,Z,$]},T,Z,$],I=()=>[T,"auto",Z,$],L=()=>["auto","min","max","fr",Z,$],F=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],B=()=>["start","end","center","stretch","center-safe","end-safe"],ei=()=>["auto",...k()],eo=()=>[D,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...k()],es=()=>[s,D,"screen","full","dvw","lvw","svw","min","max","fit",...k()],el=()=>[D,"screen","full","lh","dvh","lvh","svh","min","max","fit",...k()],eu=()=>[e,Z,$],ec=()=>[...w(),ee,q,{position:[Z,$]}],ed=()=>["no-repeat",{repeat:["","x","y","space","round"]}],ef=()=>["auto","cover","contain",et,W,{size:[Z,$]}],ep=()=>[N,Q,U],eh=()=>["","none","full",u,Z,$],em=()=>["",C,Q,U],ey=()=>["solid","dashed","dotted","double"],ev=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],eg=()=>[C,N,ee,q],eb=()=>["","none",h,Z,$],ex=()=>["none",C,Z,$],ew=()=>["none",C,Z,$],eS=()=>[C,Z,$],ej=()=>[D,"full",...k()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[R],breakpoint:[R],color:[M],container:[R],"drop-shadow":[R],ease:["in","out","in-out"],font:[V],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[R],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[R],shadow:[R],spacing:["px",C],text:[R],"text-shadow":[R],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",D,$,Z,y]}],container:["container"],"container-type":[{"@container":["","normal","size",Z,$]}],"container-named":[z],columns:[{columns:[C,"auto",$,Z,s]}],"break-after":[{"break-after":b()}],"break-before":[{"break-before":b()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:S()}],overflow:[{overflow:j()}],"overflow-x":[{"overflow-x":j()}],"overflow-y":[{"overflow-y":j()}],overscroll:[{overscroll:O()}],"overscroll-x":[{"overscroll-x":O()}],"overscroll-y":[{"overscroll-y":O()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:E()}],"inset-x":[{"inset-x":E()}],"inset-y":[{"inset-y":E()}],start:[{"inset-s":E(),start:E()}],end:[{"inset-e":E(),end:E()}],"inset-bs":[{"inset-bs":E()}],"inset-be":[{"inset-be":E()}],top:[{top:E()}],right:[{right:E()}],bottom:[{bottom:E()}],left:[{left:E()}],visibility:["visible","invisible","collapse"],z:[{z:[T,"auto",Z,$]}],basis:[{basis:[D,"full","auto",s,...k()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[C,D,"auto","initial","none",$]}],grow:[{grow:["",C,Z,$]}],shrink:[{shrink:["",C,Z,$]}],order:[{order:[T,"first","last","none",Z,$]}],"grid-cols":[{"grid-cols":P()}],"col-start-end":[{col:A()}],"col-start":[{"col-start":I()}],"col-end":[{"col-end":I()}],"grid-rows":[{"grid-rows":P()}],"row-start-end":[{row:A()}],"row-start":[{"row-start":I()}],"row-end":[{"row-end":I()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":L()}],"auto-rows":[{"auto-rows":L()}],gap:[{gap:k()}],"gap-x":[{"gap-x":k()}],"gap-y":[{"gap-y":k()}],"justify-content":[{justify:[...F(),"normal"]}],"justify-items":[{"justify-items":[...B(),"normal"]}],"justify-self":[{"justify-self":["auto",...B()]}],"align-content":[{content:["normal",...F()]}],"align-items":[{items:[...B(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...B(),{baseline:["","last"]}]}],"place-content":[{"place-content":F()}],"place-items":[{"place-items":[...B(),"baseline"]}],"place-self":[{"place-self":["auto",...B()]}],p:[{p:k()}],px:[{px:k()}],py:[{py:k()}],ps:[{ps:k()}],pe:[{pe:k()}],pbs:[{pbs:k()}],pbe:[{pbe:k()}],pt:[{pt:k()}],pr:[{pr:k()}],pb:[{pb:k()}],pl:[{pl:k()}],m:[{m:ei()}],mx:[{mx:ei()}],my:[{my:ei()}],ms:[{ms:ei()}],me:[{me:ei()}],mbs:[{mbs:ei()}],mbe:[{mbe:ei()}],mt:[{mt:ei()}],mr:[{mr:ei()}],mb:[{mb:ei()}],ml:[{ml:ei()}],"space-x":[{"space-x":k()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":k()}],"space-y-reverse":["space-y-reverse"],size:[{size:eo()}],"inline-size":[{inline:["auto",...es()]}],"min-inline-size":[{"min-inline":["auto",...es()]}],"max-inline-size":[{"max-inline":["none",...es()]}],"block-size":[{block:["auto",...el()]}],"min-block-size":[{"min-block":["auto",...el()]}],"max-block-size":[{"max-block":["none",...el()]}],w:[{w:[s,"screen",...eo()]}],"min-w":[{"min-w":[s,"screen","none",...eo()]}],"max-w":[{"max-w":[s,"screen","none","prose",{screen:[o]},...eo()]}],h:[{h:["screen","lh",...eo()]}],"min-h":[{"min-h":["screen","lh","none",...eo()]}],"max-h":[{"max-h":["screen","lh","none",...eo()]}],"font-size":[{text:["base",r,Q,U]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[n,ea,G]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",N,$]}],"font-family":[{font:[J,K,t]}],"font-features":[{"font-features":[$]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[a,Z,$]}],"line-clamp":[{"line-clamp":[C,"none",Z,H]}],leading:[{leading:["none",i,...k()]}],"list-image":[{"list-image":["none",Z,$]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",Z,$]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:eu()}],"text-color":[{text:eu()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ey(),"wavy"]}],"text-decoration-thickness":[{decoration:[C,"from-font","auto",Z,U]}],"text-decoration-color":[{decoration:eu()}],"underline-offset":[{"underline-offset":[C,"auto",Z,$]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:k()}],"tab-size":[{tab:[T,Z,$]}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Z,$]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Z,$]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:ec()}],"bg-repeat":[{bg:ed()}],"bg-size":[{bg:ef()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},T,Z,$],radial:["",Z,$],conic:["",T,Z,$]},er,Y]}],"bg-color":[{bg:eu()}],"gradient-from-pos":[{from:ep()}],"gradient-via-pos":[{via:ep()}],"gradient-to-pos":[{to:ep()}],"gradient-from":[{from:eu()}],"gradient-via":[{via:eu()}],"gradient-to":[{to:eu()}],rounded:[{rounded:eh()}],"rounded-s":[{"rounded-s":eh()}],"rounded-e":[{"rounded-e":eh()}],"rounded-t":[{"rounded-t":eh()}],"rounded-r":[{"rounded-r":eh()}],"rounded-b":[{"rounded-b":eh()}],"rounded-l":[{"rounded-l":eh()}],"rounded-ss":[{"rounded-ss":eh()}],"rounded-se":[{"rounded-se":eh()}],"rounded-ee":[{"rounded-ee":eh()}],"rounded-es":[{"rounded-es":eh()}],"rounded-tl":[{"rounded-tl":eh()}],"rounded-tr":[{"rounded-tr":eh()}],"rounded-br":[{"rounded-br":eh()}],"rounded-bl":[{"rounded-bl":eh()}],"border-w":[{border:em()}],"border-w-x":[{"border-x":em()}],"border-w-y":[{"border-y":em()}],"border-w-s":[{"border-s":em()}],"border-w-e":[{"border-e":em()}],"border-w-bs":[{"border-bs":em()}],"border-w-be":[{"border-be":em()}],"border-w-t":[{"border-t":em()}],"border-w-r":[{"border-r":em()}],"border-w-b":[{"border-b":em()}],"border-w-l":[{"border-l":em()}],"divide-x":[{"divide-x":em()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":em()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ey(),"hidden","none"]}],"divide-style":[{divide:[...ey(),"hidden","none"]}],"border-color":[{border:eu()}],"border-color-x":[{"border-x":eu()}],"border-color-y":[{"border-y":eu()}],"border-color-s":[{"border-s":eu()}],"border-color-e":[{"border-e":eu()}],"border-color-bs":[{"border-bs":eu()}],"border-color-be":[{"border-be":eu()}],"border-color-t":[{"border-t":eu()}],"border-color-r":[{"border-r":eu()}],"border-color-b":[{"border-b":eu()}],"border-color-l":[{"border-l":eu()}],"divide-color":[{divide:eu()}],"outline-style":[{outline:[...ey(),"none","hidden"]}],"outline-offset":[{"outline-offset":[C,Z,$]}],"outline-w":[{outline:["",C,Q,U]}],"outline-color":[{outline:eu()}],shadow:[{shadow:["","inner","none",c,en,X]}],"shadow-color":[{shadow:eu()}],"inset-shadow":[{"inset-shadow":["none",d,en,X]}],"inset-shadow-color":[{"inset-shadow":eu()}],"ring-w":[{ring:em()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:eu()}],"ring-offset-w":[{"ring-offset":[C,U]}],"ring-offset-color":[{"ring-offset":eu()}],"inset-ring-w":[{"inset-ring":em()}],"inset-ring-color":[{"inset-ring":eu()}],"text-shadow":[{"text-shadow":["none",f,en,X]}],"text-shadow-color":[{"text-shadow":eu()}],opacity:[{opacity:[C,Z,$]}],"mix-blend":[{"mix-blend":[...ev(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":ev()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[C]}],"mask-image-linear-from-pos":[{"mask-linear-from":eg()}],"mask-image-linear-to-pos":[{"mask-linear-to":eg()}],"mask-image-linear-from-color":[{"mask-linear-from":eu()}],"mask-image-linear-to-color":[{"mask-linear-to":eu()}],"mask-image-t-from-pos":[{"mask-t-from":eg()}],"mask-image-t-to-pos":[{"mask-t-to":eg()}],"mask-image-t-from-color":[{"mask-t-from":eu()}],"mask-image-t-to-color":[{"mask-t-to":eu()}],"mask-image-r-from-pos":[{"mask-r-from":eg()}],"mask-image-r-to-pos":[{"mask-r-to":eg()}],"mask-image-r-from-color":[{"mask-r-from":eu()}],"mask-image-r-to-color":[{"mask-r-to":eu()}],"mask-image-b-from-pos":[{"mask-b-from":eg()}],"mask-image-b-to-pos":[{"mask-b-to":eg()}],"mask-image-b-from-color":[{"mask-b-from":eu()}],"mask-image-b-to-color":[{"mask-b-to":eu()}],"mask-image-l-from-pos":[{"mask-l-from":eg()}],"mask-image-l-to-pos":[{"mask-l-to":eg()}],"mask-image-l-from-color":[{"mask-l-from":eu()}],"mask-image-l-to-color":[{"mask-l-to":eu()}],"mask-image-x-from-pos":[{"mask-x-from":eg()}],"mask-image-x-to-pos":[{"mask-x-to":eg()}],"mask-image-x-from-color":[{"mask-x-from":eu()}],"mask-image-x-to-color":[{"mask-x-to":eu()}],"mask-image-y-from-pos":[{"mask-y-from":eg()}],"mask-image-y-to-pos":[{"mask-y-to":eg()}],"mask-image-y-from-color":[{"mask-y-from":eu()}],"mask-image-y-to-color":[{"mask-y-to":eu()}],"mask-image-radial":[{"mask-radial":[Z,$]}],"mask-image-radial-from-pos":[{"mask-radial-from":eg()}],"mask-image-radial-to-pos":[{"mask-radial-to":eg()}],"mask-image-radial-from-color":[{"mask-radial-from":eu()}],"mask-image-radial-to-color":[{"mask-radial-to":eu()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":w()}],"mask-image-conic-pos":[{"mask-conic":[C]}],"mask-image-conic-from-pos":[{"mask-conic-from":eg()}],"mask-image-conic-to-pos":[{"mask-conic-to":eg()}],"mask-image-conic-from-color":[{"mask-conic-from":eu()}],"mask-image-conic-to-color":[{"mask-conic-to":eu()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:ec()}],"mask-repeat":[{mask:ed()}],"mask-size":[{mask:ef()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",Z,$]}],filter:[{filter:["","none",Z,$]}],blur:[{blur:eb()}],brightness:[{brightness:[C,Z,$]}],contrast:[{contrast:[C,Z,$]}],"drop-shadow":[{"drop-shadow":["","none",p,en,X]}],"drop-shadow-color":[{"drop-shadow":eu()}],grayscale:[{grayscale:["",C,Z,$]}],"hue-rotate":[{"hue-rotate":[C,Z,$]}],invert:[{invert:["",C,Z,$]}],saturate:[{saturate:[C,Z,$]}],sepia:[{sepia:["",C,Z,$]}],"backdrop-filter":[{"backdrop-filter":["","none",Z,$]}],"backdrop-blur":[{"backdrop-blur":eb()}],"backdrop-brightness":[{"backdrop-brightness":[C,Z,$]}],"backdrop-contrast":[{"backdrop-contrast":[C,Z,$]}],"backdrop-grayscale":[{"backdrop-grayscale":["",C,Z,$]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[C,Z,$]}],"backdrop-invert":[{"backdrop-invert":["",C,Z,$]}],"backdrop-opacity":[{"backdrop-opacity":[C,Z,$]}],"backdrop-saturate":[{"backdrop-saturate":[C,Z,$]}],"backdrop-sepia":[{"backdrop-sepia":["",C,Z,$]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":k()}],"border-spacing-x":[{"border-spacing-x":k()}],"border-spacing-y":[{"border-spacing-y":k()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",Z,$]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[C,"initial",Z,$]}],ease:[{ease:["linear","initial",v,Z,$]}],delay:[{delay:[C,Z,$]}],animate:[{animate:["none",g,Z,$]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[m,Z,$]}],"perspective-origin":[{"perspective-origin":S()}],rotate:[{rotate:ex()}],"rotate-x":[{"rotate-x":ex()}],"rotate-y":[{"rotate-y":ex()}],"rotate-z":[{"rotate-z":ex()}],scale:[{scale:ew()}],"scale-x":[{"scale-x":ew()}],"scale-y":[{"scale-y":ew()}],"scale-z":[{"scale-z":ew()}],"scale-3d":["scale-3d"],skew:[{skew:eS()}],"skew-x":[{"skew-x":eS()}],"skew-y":[{"skew-y":eS()}],transform:[{transform:[Z,$,"","none","gpu","cpu"]}],"transform-origin":[{origin:S()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:ej()}],"translate-x":[{"translate-x":ej()}],"translate-y":[{"translate-y":ej()}],"translate-z":[{"translate-z":ej()}],"translate-none":["translate-none"],zoom:[{zoom:[T,Z,$]}],accent:[{accent:eu()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:eu()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Z,$]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scrollbar-thumb-color":[{"scrollbar-thumb":eu()}],"scrollbar-track-color":[{"scrollbar-track":eu()}],"scrollbar-gutter":[{"scrollbar-gutter":["auto","stable","both"]}],"scrollbar-w":[{scrollbar:["auto","thin","none"]}],"scroll-m":[{"scroll-m":k()}],"scroll-mx":[{"scroll-mx":k()}],"scroll-my":[{"scroll-my":k()}],"scroll-ms":[{"scroll-ms":k()}],"scroll-me":[{"scroll-me":k()}],"scroll-mbs":[{"scroll-mbs":k()}],"scroll-mbe":[{"scroll-mbe":k()}],"scroll-mt":[{"scroll-mt":k()}],"scroll-mr":[{"scroll-mr":k()}],"scroll-mb":[{"scroll-mb":k()}],"scroll-ml":[{"scroll-ml":k()}],"scroll-p":[{"scroll-p":k()}],"scroll-px":[{"scroll-px":k()}],"scroll-py":[{"scroll-py":k()}],"scroll-ps":[{"scroll-ps":k()}],"scroll-pe":[{"scroll-pe":k()}],"scroll-pbs":[{"scroll-pbs":k()}],"scroll-pbe":[{"scroll-pbe":k()}],"scroll-pt":[{"scroll-pt":k()}],"scroll-pr":[{"scroll-pr":k()}],"scroll-pb":[{"scroll-pb":k()}],"scroll-pl":[{"scroll-pl":k()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Z,$]}],fill:[{fill:["none",...eu()]}],"stroke-w":[{stroke:[C,Q,U,H]}],stroke:[{stroke:["none",...eu()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{"container-named":["container-type"],overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["start","end","right","left"],"inset-y":["inset-bs","inset-be","top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["ps","pe","pr","pl"],py:["pbs","pbe","pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["ms","me","mr","ml"],my:["mbs","mbe","mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-s","border-w-e","border-w-r","border-w-l"],"border-w-y":["border-w-bs","border-w-be","border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-s","border-color-e","border-color-r","border-color-l"],"border-color-y":["border-color-bs","border-color-be","border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-ms","scroll-me","scroll-mr","scroll-ml"],"scroll-my":["scroll-mbs","scroll-mbe","scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-ps","scroll-pe","scroll-pr","scroll-pl"],"scroll-py":["scroll-pbs","scroll-pbe","scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},postfixLookupClassGroups:["container-type"],orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}});function ey(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return em((0,n.$)(t))}},5572(e,t,r){"use strict";let n;r.d(t,{jJ:()=>iv,cw:()=>is,FA:()=>nN,rr:()=>ir,lG:()=>a5,ul:()=>ig,jl:()=>il,L3:()=>it,Wd:()=>nT,Ad:()=>ih,Ex:()=>nO,$n:()=>q,Es:()=>ie,Cf:()=>a9,rQ:()=>io,K0:()=>ng,ci:()=>ib,tD:()=>ix,Ou:()=>nC,c7:()=>a7});var a,i,o,s,l,u,c,d,f=r(2883),p=r(8783),h=r(7064);let m=e=>"boolean"==typeof e?`${e}`:0===e?"0":e,y=h.$,v=(e,t)=>r=>{var n;if((null==t?void 0:t.variants)==null)return y(e,null==r?void 0:r.class,null==r?void 0:r.className);let{variants:a,defaultVariants:i}=t,o=Object.keys(a).map(e=>{let t=null==r?void 0:r[e],n=null==i?void 0:i[e];if(null===t)return null;let o=m(t)||m(n);return a[e][o]}),s=r&&Object.entries(r).reduce((e,t)=>{let[r,n]=t;return void 0===n||(e[r]=n),e},{});return y(e,o,null==t||null==(n=t.compoundVariants)?void 0:n.reduce((e,t)=>{let{class:r,className:n,...a}=t;return Object.entries(a).every(e=>{let[t,r]=e;return Array.isArray(r)?r.includes({...i,...s}[t]):({...i,...s})[t]===r})?[...e,r,n]:e},[]),null==r?void 0:r.class,null==r?void 0:r.className)};var g=r(8969),b=Object.defineProperty,x=(e,t)=>b(e,"name",{value:t,configurable:!0});function w(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function S(...e){return t=>{let r=!1,n=e.map(e=>{let n=w(e,t);return r||"function"!=typeof n||(r=!0),n});if(r)return()=>{for(let t=0;t<n.length;t++){let r=n[t];"function"==typeof r?r():w(e[t],null)}}}}function j(...e){return p.useCallback(S(...e),e)}x(w,"setRef"),x(S,"composeRefs"),x(j,"useComposedRefs");var O=Object.defineProperty,k=(e,t)=>O(e,"name",{value:t,configurable:!0});function E(e){let t=p.forwardRef((t,r)=>{let{children:n,...a}=t,i=null,o=!1,s=[];n=F(n),p.Children.forEach(n,e=>{if(R(e)){o=!0;let t="child"in e.props?e.props.child:e.props.children;for(;I(t)&&"function"==typeof W;)t=W(t._payload);i=C(e,t),s.push(i?.props?.children)}else s.push(e)}),i?i=p.cloneElement(i,void 0,s):!o&&1===p.Children.count(n)&&p.isValidElement(n)&&(i=n);let l=i?N(i):void 0,u=j(r,l);if(!i){if(n||0===n)throw Error(o?z(e):V(e));return n}let c=T(a,i.props??{});return i.type!==p.Fragment&&(c.ref=r?u:l),p.cloneElement(i,c)});return t.displayName=`${e}.Slot`,t}k(E,"createSlot");var P=E("Slot"),A=Symbol.for("radix.slottable");function D(e){let t=k(e=>"child"in e?e.children(e.child):e.children,"Slottable");return t.displayName=`${e}.Slottable`,t.__radixId=A,t}k(D,"createSlottable");var C=k((e,t)=>"child"in e.props?p.isValidElement(t)?p.cloneElement(t,void 0,e.props.children(t.props.children)):null:p.isValidElement(t)?t:null,"getSlottableElementFromSlottable");function T(e,t){let r={...t};for(let n in t){let a=e[n],i=t[n];/^on[A-Z]/.test(n)?a&&i?r[n]=(...e)=>{let t=i(...e);return a(...e),t}:a&&(r[n]=a):"style"===n?r[n]={...a,...i}:"className"===n?r[n]=[a,i].filter(Boolean).join(" "):"aria-describedby"===n&&(r[n]=B(i,a))}return{...e,...r}}function N(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(r=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}function R(e){return p.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===A}k(T,"mergeProps"),k(N,"getElementRef"),k(R,"isSlottable");var M=Symbol.for("react.lazy");function I(e){return null!=e&&"object"==typeof e&&"$$typeof"in e&&e.$$typeof===M&&"_payload"in e&&L(e._payload)}function L(e){return"object"==typeof e&&null!==e&&"then"in e}function F(e){let t=e;for(;I(t)&&"function"==typeof W;)t=W(t._payload);return t}function B(...e){let t=new Set;for(let r of e)if("string"==typeof r)for(let e of String(r).trim().split(/\s+/))e&&t.add(e);return t.size>0?Array.from(t).join(" "):void 0}k(I,"isLazyComponent"),k(L,"isPromiseLike"),k(F,"useUnwrappedLazy"),k(B,"concatAriaDescribedby");var V=k(e=>`${e} failed to slot onto its children. Expected a single React element child or \`Slottable\`.`,"createSlotError"),z=k(e=>`${e} failed to slot onto its \`Slottable\`. Expected \`Slottable\` to receive a single React element child.`,"createSlottableError"),W=p[" use ".trim().toString()];function $(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function U(e){if(Array.isArray(e))return e}function H(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function G(e,t){if(e){if("string"==typeof e)return $(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return $(e,t)}}var K=v("inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-sm font-medium whitespace-nowrap transition-all outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",xs:"h-6 gap-1 rounded-md px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3",sm:"h-8 gap-1.5 rounded-md px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9","icon-xs":"size-6 rounded-md [&_svg:not([class*='size-'])]:size-3","icon-sm":"size-8","icon-lg":"size-10"}},defaultVariants:{variant:"default",size:"default"}}),q=p.forwardRef(function(e,t){var r,n=U(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||G(r)||H(),a=n[0],i=n.slice(1),o=a.className,s=a.variant,l=void 0===s?"default":s,u=a.size,c=void 0===u?"default":u,d=a.asChild,p=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(a,["className","variant","size","asChild"]),h=(U(i)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),1!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(i)||G(i,1)||H())[0];return(0,f.jsx)(void 0!==d&&d?P:"button",function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({ref:h,"data-slot":"button","data-variant":l,"data-size":c,className:(0,g.cn)(K({variant:l,size:c,className:o}))},p))}),Y=Object.defineProperty,X=(e,t)=>Y(e,"name",{value:t,configurable:!0}),Z=!!("u">typeof window&&window.document&&window.document.createElement);function Q(e,t,{checkForDefaultPrevented:r=!0}={}){return X(function(n){if(e?.(n),!1===r||!n||!n.defaultPrevented)return t?.(n)},"handleEvent")}function J(e){if(!Z)throw Error("Cannot access document outside of the DOM");return e?.ownerDocument??document}function ee(e){return"IFRAME"===e.tagName}X(Q,"composeEventHandlers"),X(function(e){if(!Z)throw Error("Cannot access window outside of the DOM");return e?.ownerDocument?.defaultView??window},"getOwnerWindow"),X(J,"getOwnerDocument"),X(function e(t,r=!1){let{activeElement:n}=J(t);if(!n?.nodeName)return null;if(ee(n)&&n.contentDocument)return e(n.contentDocument.body,r);if(r){let e=n.getAttribute("aria-activedescendant");if(e){let t=J(n).getElementById(e);if(t)return t}}return n},"getActiveElement"),X(ee,"isFrame");var et=Object.defineProperty,er=(e,t)=>et(e,"name",{value:t,configurable:!0});function en(e,t=[]){let r=[];function n(t,n){let a=p.createContext(n);a.displayName=t+"Context";let i=r.length;r=[...r,n];let o=er(t=>{let{scope:r,children:n,...o}=t,s=r?.[e]?.[i]||a,l=p.useMemo(()=>o,Object.values(o));return(0,f.jsx)(s.Provider,{value:l,children:n})},"Provider");function s(r,o,l={}){let{optional:u=!1}=l,c=o?.[e]?.[i]||a,d=p.useContext(c);if(d)return d;if(void 0!==n)return n;if(!u)throw Error(`\`${r}\` must be used within \`${t}\``)}return o.displayName=t+"Provider",er(s,"useContext"),[o,s]}er(n,"createContext");let a=er(()=>{let t=r.map(e=>p.createContext(e));return er(function(r){let n=r?.[e]||t;return p.useMemo(()=>({[`__scope${e}`]:{...r,[e]:n}}),[r,n])},"useScope")},"createScope");return a.scopeName=e,[n,ea(a,...t)]}function ea(...e){let t=e[0];if(1===e.length)return t;let r=er(()=>{let r=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return er(function(e){let n=r.reduce((t,{useScope:r,scopeName:n})=>{let a=r(e)[`__scope${n}`];return{...t,...a}},{});return p.useMemo(()=>({[`__scope${t.scopeName}`]:n}),[n])},"useComposedScopes")},"createScope");return r.scopeName=t.scopeName,r}er(function(e,t){let r=p.createContext(t);r.displayName=e+"Context";let n=er(e=>{let{children:t,...n}=e,a=p.useMemo(()=>n,Object.values(n));return(0,f.jsx)(r.Provider,{value:a,children:t})},"Provider");function a(n,i={}){let{optional:o=!1}=i,s=p.useContext(r);if(s)return s;if(void 0!==t)return t;if(!o)throw Error(`\`${n}\` must be used within \`${e}\``)}return n.displayName=e+"Provider",er(a,"useContext"),[n,a]},"createContext"),er(en,"createContextScope"),er(ea,"composeContextScopes");var ei=r(803),eo=Object.defineProperty,es=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,t)=>{let r=E(`Primitive.${t}`),n=p.forwardRef((e,n)=>{let{asChild:a,...i}=e;return"u">typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,f.jsx)(a?r:t,{...i,ref:n})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function el(e,t){e&&ei.flushSync(()=>e.dispatchEvent(t))}eo(el,"name",{value:"dispatchDiscreteCustomEvent",configurable:!0});var eu=globalThis?.document?p.useLayoutEffect:()=>{},ec=Object.defineProperty,ed=p[" useInsertionEffect ".trim().toString()];function ef(e){let t=p.useRef(e);return"function"==typeof ed?ed(()=>{t.current=e}):eu(()=>{t.current=e}),p.useMemo(()=>(...e)=>t.current?.(...e),[])}ec(ef,"name",{value:"useCallbackRef",configurable:!0});var ep=Object.defineProperty,eh=(e,t)=>ep(e,"name",{value:t,configurable:!0}),em="dismissableLayer.update",ey=p.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),ev=p.forwardRef(eh(function(e,t){let{disableOutsidePointerEvents:r=!1,deferPointerDownOutside:n=!1,onEscapeKeyDown:a,onPointerDownOutside:i,onFocusOutside:o,onInteractOutside:s,onDismiss:l,...u}=e,d=p.useContext(ey),[h,m]=p.useState(null),y=h?.ownerDocument??globalThis?.document,[,v]=p.useState({}),g=j(t,m),b=Array.from(d.layers),[x]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),w=x?b.indexOf(x):-1,S=h?b.indexOf(h):-1,O=d.layersWithOutsidePointerEventsDisabled.size>0,k=S>=w,E=p.useRef(!1),P=ex(e=>{i?.(e),s?.(e),e.defaultPrevented||l?.()},{ownerDocument:y,deferPointerDownOutside:n,isDeferredPointerDownOutsideRef:E,dismissableSurfaces:d.dismissableSurfaces,shouldHandlePointerDownOutside:p.useCallback(e=>{if(!(e instanceof Node))return!1;let t=[...d.branches].some(t=>t.contains(e));return k&&!t},[d.branches,k])}),A=ew(e=>{if(n&&E.current)return;let t=e.target;![...d.branches].some(e=>e.contains(t))&&(o?.(e),s?.(e),e.defaultPrevented||l?.())},y),D=!!h&&S===b.length-1,C=ef(e=>{"Escape"===e.key&&(a?.(e),!e.defaultPrevented&&l&&(e.preventDefault(),l()))});return p.useEffect(()=>{if(D)return y.addEventListener("keydown",C,{capture:!0}),()=>y.removeEventListener("keydown",C,{capture:!0})},[y,D,C]),p.useEffect(()=>{if(h)return r&&(0===d.layersWithOutsidePointerEventsDisabled.size&&(c=y.body.style.pointerEvents,y.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(h)),d.layers.add(h),eS(),()=>{r&&(d.layersWithOutsidePointerEventsDisabled.delete(h),0===d.layersWithOutsidePointerEventsDisabled.size&&(y.body.style.pointerEvents=c))}},[h,y,r,d]),p.useEffect(()=>()=>{h&&(d.layers.delete(h),d.layersWithOutsidePointerEventsDisabled.delete(h),eS())},[h,d]),p.useEffect(()=>{let e=eh(()=>v({}),"handleUpdate");return document.addEventListener(em,e),()=>document.removeEventListener(em,e)},[]),(0,f.jsx)(es.div,{...u,ref:g,style:{pointerEvents:O?k?"auto":"none":void 0,...e.style},onFocusCapture:Q(e.onFocusCapture,A.onFocusCapture),onBlurCapture:Q(e.onBlurCapture,A.onBlurCapture),onPointerDownCapture:Q(e.onPointerDownCapture,P.onPointerDownCapture)})},"DismissableLayer"));function eg(){let e=p.useContext(ey),[t,r]=p.useState(null);return p.useEffect(()=>{if(t)return e.dismissableSurfaces.add(t),()=>{e.dismissableSurfaces.delete(t)}},[t,e.dismissableSurfaces]),r}eh(eg,"useDismissableLayerSurface");var eb=eh(()=>!0,"IS_TRUE");function ex(e,t){let{ownerDocument:r=globalThis?.document,deferPointerDownOutside:n=!1,isDeferredPointerDownOutsideRef:a,dismissableSurfaces:i,shouldHandlePointerDownOutside:o=eb}=t,s=ef(e),l=p.useRef(!1),u=p.useRef(!1),c=p.useRef(new Map),d=p.useRef(()=>{});return p.useEffect(()=>{function e(){u.current=!1,a.current=!1,c.current.clear()}function t(){return Array.from(c.current.values()).some(Boolean)}function f(e){if(!u.current)return;let t=e.target;t instanceof Node&&[...i].some(e=>e.contains(t))||c.current.set(e.type,!0),"click"===e.type&&window.setTimeout(()=>{u.current&&d.current()},0)}function p(e){u.current&&c.current.set(e.type,!1)}eh(e,"resetOutsideInteraction"),eh(t,"isOutsideInteractionIntercepted"),eh(f,"handleInteractionCapture"),eh(p,"handleInteractionBubble");let h=eh(i=>{if(i.target&&!l.current){let f=function(){r.removeEventListener("click",d.current);let n=t();e(),n||ej("dismissableLayer.pointerDownOutside",s,p,{discrete:!0})};if(eh(f,"handleAndDispatchPointerDownOutsideEvent"),!o(i.target)){r.removeEventListener("click",d.current),e(),l.current=!1;return}let p={originalEvent:i};u.current=!0,a.current=n&&0===i.button,c.current.clear(),n&&0===i.button?(r.removeEventListener("click",d.current),d.current=f,r.addEventListener("click",d.current,{once:!0})):f()}else r.removeEventListener("click",d.current),e();l.current=!1},"handlePointerDown"),m=["pointerup","mousedown","mouseup","touchstart","touchend","click"];for(let e of m)r.addEventListener(e,f,!0),r.addEventListener(e,p);let y=window.setTimeout(()=>{r.addEventListener("pointerdown",h)},0);return()=>{for(let e of(window.clearTimeout(y),r.removeEventListener("pointerdown",h),r.removeEventListener("click",d.current),m))r.removeEventListener(e,f,!0),r.removeEventListener(e,p)}},[r,s,n,a,i,o]),{onPointerDownCapture:eh(()=>l.current=!0,"onPointerDownCapture")}}function ew(e,t=globalThis?.document){let r=ef(e),n=p.useRef(!1);return p.useEffect(()=>{let e=eh(e=>{e.target&&!n.current&&ej("dismissableLayer.focusOutside",r,{originalEvent:e},{discrete:!1})},"handleFocus");return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)},[t,r]),{onFocusCapture:eh(()=>n.current=!0,"onFocusCapture"),onBlurCapture:eh(()=>n.current=!1,"onBlurCapture")}}function eS(){let e=new CustomEvent(em);document.dispatchEvent(e)}function ej(e,t,r,{discrete:n}){let a=r.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&a.addEventListener(e,t,{once:!0}),n?el(a,i):a.dispatchEvent(i)}eh(ex,"usePointerDownOutside"),eh(ew,"useFocusOutside"),eh(eS,"dispatchUpdate"),eh(ej,"handleAndDispatchCustomEvent");var eO=Object.defineProperty,ek=(e,t)=>eO(e,"name",{value:t,configurable:!0}),eE="focusScope.autoFocusOnMount",eP="focusScope.autoFocusOnUnmount",eA={bubbles:!1,cancelable:!0},eD=p.forwardRef(ek(function(e,t){let{loop:r=!1,trapped:n=!1,branches:a,onMountAutoFocus:i,onUnmountAutoFocus:o,...s}=e,[l,u]=p.useState(null),c=ef(i),d=ef(o),h=p.useRef(null),m=j(t,u),y=p.useRef(a);p.useEffect(()=>{y.current=a});let v=p.useCallback(e=>!!e&&(!!l?.contains(e)||!!y.current?.some(t=>t.contains(e))),[l]),g=p.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;p.useEffect(()=>{if(n){let e=function(e){if(g.paused||!l)return;let t=e.target;v(t)?h.current=t:eV(h.current,{select:!0})},t=function(e){if(g.paused||!l)return;let t=e.relatedTarget;null!==t&&(v(t)||eV(h.current,{select:!0}))},r=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&eV(l)};ek(e,"handleFocusIn"),ek(t,"handleFocusOut"),ek(r,"handleMutations"),document.addEventListener("focusin",e),document.addEventListener("focusout",t);let n=new MutationObserver(r);return l&&n.observe(l,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),n.disconnect()}}},[n,l,g.paused,v]),p.useEffect(()=>{if(l){ez.add(g);let e=document.activeElement;if(!l.contains(e)){let t=new CustomEvent(eE,eA);l.addEventListener(eE,c),l.dispatchEvent(t),t.defaultPrevented||(eM(eU(e_(l)),{select:!0}),document.activeElement===e&&eV(l))}return()=>{l.removeEventListener(eE,c);let t=l.ownerDocument,r=CustomEvent;setTimeout(()=>{let n=new r(eP,eA);l.addEventListener(eP,d),l.dispatchEvent(n),n.defaultPrevented||eV(e??t.body,{select:!0}),l.removeEventListener(eP,d),ez.remove(g)},0)}}},[l,c,d,g]);let b=p.useCallback(e=>{if(!r&&!n||g.paused)return;let t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,a=document.activeElement;if(t&&a){let t=e.currentTarget,[n,i]=eI(t);n&&i?e.shiftKey||a!==i?e.shiftKey&&a===n&&(e.preventDefault(),r&&eV(i,{select:!0})):(e.preventDefault(),r&&eV(n,{select:!0})):a===t&&e.preventDefault()}},[r,n,g.paused]);return(0,f.jsx)(es.div,{tabIndex:-1,...s,ref:m,onKeyDown:b})},"FocusScope")),eC=p.createContext(null);function eT({registry:e,children:t}){return e?(0,f.jsx)(eC.Provider,{value:e,children:t}):t}function eN(){let[e,t]=p.useState([]);return{nodes:e,registry:p.useMemo(()=>({add:ek(e=>t(t=>t.includes(e)?t:[...t,e]),"add"),remove:ek(e=>t(t=>t.filter(t=>t!==e)),"remove")}),[])}}function eR(e){let t=p.useContext(eC);p.useEffect(()=>{if(e&&t)return t.add(e),()=>t.remove(e)},[e,t])}function eM(e,{select:t=!1}={}){let r=document.activeElement;for(let n of e)if(eV(n,{select:t}),document.activeElement!==r)return}function eI(e){let t=e_(e);return[eL(t,e),eL(t.reverse(),e)]}function e_(e){let t=[],r=e.ownerDocument.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:ek(e=>{let t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP},"acceptNode")});for(;r.nextNode();)t.push(r.currentNode);return t}function eL(e,t){let r="function"==typeof t.checkVisibility&&t.checkVisibility({checkVisibilityCSS:!0});for(let n of e)if(!(r?!n.checkVisibility({checkVisibilityCSS:!0}):eF(n,{upTo:t})))return n}function eF(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e&&(void 0===t||e!==t);){if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function eB(e){return"INPUT"===e.tagName&&"function"==typeof e.select}function eV(e,{select:t=!1}={}){if(e&&e.focus){let r=(e.ownerDocument??document).activeElement;e.focus({preventScroll:!0}),e!==r&&eB(e)&&t&&e.select()}}ek(eT,"FocusScopeBranchProvider"),ek(eN,"useFocusScopeBranchRegistry"),ek(eR,"useFocusScopeBranch"),ek(eM,"focusFirst"),ek(eI,"getTabbableEdges"),ek(e_,"getTabbableCandidates"),ek(eL,"findVisible"),ek(eF,"isHidden"),ek(eB,"isSelectableInput"),ek(eV,"focus");var ez=eW();function eW(){let e=[];return{add(t){let r=e[0];t!==r&&r?.pause(),(e=e$(e,t)).unshift(t)},remove(t){e=e$(e,t),e[0]?.resume()}}}function e$(e,t){let r=[...e],n=r.indexOf(t);return -1!==n&&r.splice(n,1),r}function eU(e){return e.filter(e=>"A"!==e.tagName)}ek(eW,"createFocusScopesStack"),ek(e$,"arrayRemove"),ek(eU,"removeLinks");var eH=Object.defineProperty,eG=p[" useId ".trim().toString()]||(()=>void 0),eK=0;function eq(e){let[t,r]=p.useState(eG());return eu(()=>{e||r(e=>e??String(eK++))},[e]),e||(t?`radix-${t}`:"")}eH(eq,"name",{value:"useId",configurable:!0});let eY=["top","right","bottom","left"],eX=Math.min,eZ=Math.max,eQ=Math.round,eJ=Math.floor,e0=e=>({x:e,y:e}),e1={left:"right",right:"left",bottom:"top",top:"bottom"};function e2(e,t){return"function"==typeof e?e(t):e}function e3(e){return e.split("-")[0]}function e4(e){return e.split("-")[1]}function e5(e){return"x"===e?"y":"x"}function e6(e){return"y"===e?"height":"width"}function e8(e){let t=e[0];return"t"===t||"b"===t?"y":"x"}function e9(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}let e7=["left","right"],te=["right","left"],tt=["top","bottom"],tr=["bottom","top"];function tn(e){let t=e3(e);return e1[t]+e.slice(t.length)}function ta(e){var t,r,n,a;return"number"!=typeof e?{top:null!=(t=e.top)?t:0,right:null!=(r=e.right)?r:0,bottom:null!=(n=e.bottom)?n:0,left:null!=(a=e.left)?a:0}:{top:e,right:e,bottom:e,left:e}}function ti(e){let{x:t,y:r,width:n,height:a}=e;return{width:n,height:a,top:r,left:t,right:t+n,bottom:r+a,x:t,y:r}}function to(e,t,r){let n,{reference:a,floating:i}=e,o=e8(t),s=e5(e8(t)),l=e6(s),u=e3(t),c=a.x+a.width/2-i.width/2,d=a.y+a.height/2-i.height/2,f=a[l]/2-i[l]/2;switch(u){case"top":n={x:c,y:a.y-i.height};break;case"bottom":n={x:c,y:a.y+a.height};break;case"right":n={x:a.x+a.width,y:d};break;case"left":n={x:a.x-i.width,y:d};break;default:n={x:a.x,y:a.y}}let p=e4(t);return p&&(n[s]+=f*("end"===p?1:-1)*(r&&"y"===o?-1:1)),n}async function ts(e,t){var r;void 0===t&&(t={});let{x:n,y:a,platform:i,rects:o,elements:s,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=e2(t,e),h=ta(p),m=s[f?"floating"===d?"reference":"floating":d],y=ti(await i.getClippingRect({element:null==(r=await (null==i.isElement?void 0:i.isElement(m)))||r?m:m.contextElement||await (null==i.getDocumentElement?void 0:i.getDocumentElement(s.floating)),boundary:u,rootBoundary:c,strategy:l})),v="floating"===d?{x:n,y:a,width:o.floating.width,height:o.floating.height}:o.reference,g=await (null==i.getOffsetParent?void 0:i.getOffsetParent(s.floating)),b=await (null==i.isElement?void 0:i.isElement(g))&&await (null==i.getScale?void 0:i.getScale(g))||{x:1,y:1},x=ti(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:v,offsetParent:g,strategy:l}):v);return{top:(y.top-x.top+h.top)/b.y,bottom:(x.bottom-y.bottom+h.bottom)/b.y,left:(y.left-x.left+h.left)/b.x,right:(x.right-y.right+h.right)/b.x}}let tl=async(e,t,r)=>{let{placement:n="bottom",strategy:a="absolute",middleware:i=[],platform:o}=r,s=o.detectOverflow?o:{...o,detectOverflow:ts},l=await (null==o.isRTL?void 0:o.isRTL(t)),u=await o.getElementRects({reference:e,floating:t,strategy:a}),{x:c,y:d}=to(u,n,l),f=n,p=0,h={};for(let r=0;r<i.length;r++){let m=i[r];if(!m)continue;let{name:y,fn:v}=m,{x:g,y:b,data:x,reset:w}=await v({x:c,y:d,initialPlacement:n,placement:f,strategy:a,middlewareData:h,rects:u,platform:s,elements:{reference:e,floating:t}});c=null!=g?g:c,d=null!=b?b:d,h[y]={...h[y],...x},w&&p<50&&(p++,"object"==typeof w&&(w.placement&&(f=w.placement),w.rects&&(u=!0===w.rects?await o.getElementRects({reference:e,floating:t,strategy:a}):w.rects),{x:c,y:d}=to(u,f,l)),r=-1)}return{x:c,y:d,placement:f,strategy:a,middlewareData:h}};function tu(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function tc(e){return eY.some(t=>e[t]>=0)}let td=new Set(["left","top"]);async function tf(e,t){let{placement:r,platform:n,elements:a}=e,i=await (null==n.isRTL?void 0:n.isRTL(a.floating)),o=e3(r),s=e4(r),l="y"===e8(r),u=td.has(o)?-1:1,c=i&&l?-1:1,d=e2(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:h}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof h&&(p="end"===s?-1*h:h),l?{x:p*c,y:f*u}:{x:f*u,y:p*c}}function tp(){return"u">typeof window}function th(e){return tv(e)?(e.nodeName||"").toLowerCase():"#document"}function tm(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function ty(e){var t;return null==(t=(tv(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function tv(e){return!!tp()&&(e instanceof Node||e instanceof tm(e).Node)}function tg(e){return!!tp()&&(e instanceof Element||e instanceof tm(e).Element)}function tb(e){return!!tp()&&(e instanceof HTMLElement||e instanceof tm(e).HTMLElement)}function tx(e){return!(!tp()||"u"<typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof tm(e).ShadowRoot)}function tw(e){let{overflow:t,overflowX:r,overflowY:n,display:a}=tD(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&"inline"!==a&&"contents"!==a}function tS(e){try{if(e.matches(":popover-open"))return!0}catch(e){}try{return e.matches(":modal")}catch(e){return!1}}let tj=/transform|translate|scale|rotate|perspective|filter/,tO=/paint|layout|strict|content/,tk=e=>!!e&&"none"!==e;function tE(e){let t=tg(e)?tD(e):e;return tk(t.transform)||tk(t.translate)||tk(t.scale)||tk(t.rotate)||tk(t.perspective)||!tP()&&(tk(t.backdropFilter)||tk(t.filter))||tj.test(t.willChange||"")||tO.test(t.contain||"")}function tP(){return null==n&&(n="u">typeof CSS&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),n}function tA(e){return/^(html|body|#document)$/.test(th(e))}function tD(e){return tm(e).getComputedStyle(e)}function tC(e){return tg(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function tT(e){if("html"===th(e))return e;let t=e.assignedSlot||e.parentNode||tx(e)&&e.host||ty(e);return tx(t)?t.host:t}function tN(e,t,r){var n;void 0===t&&(t=[]),void 0===r&&(r=!0);let a=function e(t){let r=tT(t);return tA(r)?(t.ownerDocument||t).body:tb(r)&&tw(r)?r:e(r)}(e),i=a===(null==(n=e.ownerDocument)?void 0:n.body),o=tm(a);if(!i)return t.concat(a,tN(a,[],r));{let e=tR(o);return t.concat(o,o.visualViewport||[],tw(a)?a:[],e&&r?tN(e):[])}}function tR(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function tM(e){let t=tD(e),r=parseFloat(t.width)||0,n=parseFloat(t.height)||0,a=tb(e),i=a?e.offsetWidth:r,o=a?e.offsetHeight:n,s=eQ(r)!==i||eQ(n)!==o;return s&&(r=i,n=o),{width:r,height:n,$:s}}function tI(e){return tg(e)?e:e.contextElement}function t_(e){let t=tI(e);if(!tb(t))return e0(1);let r=t.getBoundingClientRect(),{width:n,height:a,$:i}=tM(t),o=(i?eQ(r.width):r.width)/n,s=(i?eQ(r.height):r.height)/a;return o&&Number.isFinite(o)||(o=1),s&&Number.isFinite(s)||(s=1),{x:o,y:s}}let tL=e0(0);function tF(e){let t=tm(e);return tP()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:tL}function tB(e,t,r,n){var a;void 0===t&&(t=!1),void 0===r&&(r=!1);let i=e.getBoundingClientRect(),o=tI(e),s=e0(1);t&&(n?tg(n)&&(s=t_(n)):s=t_(e));let l=(void 0===(a=r)&&(a=!1),n&&a&&n===tm(o))?tF(o):e0(0),u=(i.left+l.x)/s.x,c=(i.top+l.y)/s.y,d=i.width/s.x,f=i.height/s.y;if(o&&n){let e=tm(o),t=tg(n)?tm(n):n,r=e,a=tR(r);for(;a&&t!==r;){let e=t_(a),t=a.getBoundingClientRect(),n=tD(a),i=t.left+(a.clientLeft+parseFloat(n.paddingLeft))*e.x,o=t.top+(a.clientTop+parseFloat(n.paddingTop))*e.y;u*=e.x,c*=e.y,d*=e.x,f*=e.y,u+=i,c+=o,a=tR(r=tm(a))}}return ti({width:d,height:f,x:u,y:c})}function tV(e,t){let r=tC(e).scrollLeft;return t?t.left+r:tB(ty(e)).left+r}function tz(e,t){let r=e.getBoundingClientRect();return{x:r.left+t.scrollLeft-tV(e,r),y:r.top+t.scrollTop}}function tW(e,t,r){var n;let a;if("viewport"===t||"layoutViewport"===t)a=function(e,t,r){void 0===r&&(r="viewport");let n="layoutViewport"===r,a=tm(e),i=ty(e),o=a.visualViewport,s=i.clientWidth,l=i.clientHeight,u=0,c=0;if(o){let e=!tP()||"fixed"===t;n?e||(u=-o.offsetLeft,c=-o.offsetTop):(s=o.width,l=o.height,e&&(u=o.offsetLeft,c=o.offsetTop))}if(0>=tV(i)){let e=i.ownerDocument,t=e.body,r=getComputedStyle(t),n="CSS1Compat"===e.compatMode&&parseFloat(r.marginLeft)+parseFloat(r.marginRight)||0,a=Math.abs(i.clientWidth-t.clientWidth-n),o="stable both-edges"===getComputedStyle(i).scrollbarGutter?a/2:a;o<=25&&(s-=o)}return{width:s,height:l,x:u,y:c}}(e,r,t);else if("document"===t){let t,r,i,o,s,l;t=tC(n=ty(e)),r=n.ownerDocument.body,i=eZ(n.scrollWidth,n.clientWidth,r.scrollWidth,r.clientWidth),o=eZ(n.scrollHeight,n.clientHeight,r.scrollHeight,r.clientHeight),s=-t.scrollLeft+tV(n),l=-t.scrollTop,"rtl"===tD(r).direction&&(s+=eZ(n.clientWidth,r.clientWidth)-i),a={width:i,height:o,x:s,y:l}}else if(tg(t)){let e,n,i,o,s,l;n=(e=tB(t,!0,"fixed"===r)).top+t.clientTop,i=e.left+t.clientLeft,o=t_(t),s=t.clientWidth*o.x,l=t.clientHeight*o.y,a={width:s,height:l,x:i*o.x,y:n*o.y}}else{let r=tF(e);a={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return ti(a)}function t$(e){return"static"===tD(e).position}function tU(e,t){if(!tb(e)||"fixed"===tD(e).position)return null;if(t)return t(e);let r=e.offsetParent;return ty(e)===r&&(r=r.ownerDocument.body),r}function tH(e,t){var r;let n=tm(e);if(tS(e))return n;if(!tb(e)){let t=tT(e);for(;t&&!tA(t);){if(tg(t)&&!t$(t))return t;t=tT(t)}return n}let a=tU(e,t);for(;a&&(r=a,/^(table|td|th)$/.test(th(r)))&&t$(a);)a=tU(a,t);return a&&tA(a)&&t$(a)&&!tE(a)?n:a||function(e){let t=tT(e);for(;tb(t)&&!tA(t);){if(tE(t))return t;if(tS(t))break;t=tT(t)}return null}(e)||n}let tG=async function(e){let t=this.getOffsetParent||tH,r=this.getDimensions,n=await r(e.floating);return{reference:function(e,t,r){let n=tb(t),a=ty(t),i="fixed"===r,o=tB(e,!0,i,t),s={scrollLeft:0,scrollTop:0},l=e0(0);if((n||!i)&&(("body"!==th(t)||tw(a))&&(s=tC(t)),n)){let e=tB(t,!0,i,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}!n&&a&&(l.x=tV(a));let u=!a||n||i?e0(0):tz(a,s);return{x:o.left+s.scrollLeft-l.x-u.x,y:o.top+s.scrollTop-l.y-u.y,width:o.width,height:o.height}}(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}},tK={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:r,offsetParent:n,strategy:a}=e,i="fixed"===a,o=ty(n),s=!!t&&tS(t.floating);if(n===o||s&&i)return r;let l={scrollLeft:0,scrollTop:0},u=e0(1),c=e0(0),d=tb(n);if((d||!i)&&(("body"!==th(n)||tw(o))&&(l=tC(n)),d)){let e=tB(n);u=t_(n),c.x=e.x+n.clientLeft,c.y=e.y+n.clientTop}let f=!o||d||i?e0(0):tz(o,l);return{width:r.width*u.x,height:r.height*u.y,x:r.x*u.x-l.scrollLeft*u.x+c.x+f.x,y:r.y*u.y-l.scrollTop*u.y+c.y+f.y}},getDocumentElement:ty,getClippingRect:function(e){let{element:t,boundary:r,rootBoundary:n,strategy:a}=e,i=[..."clippingAncestors"===r?tS(t)?[]:function(e,t){let r=t.get(e);if(r)return r;let n=tN(e,[],!1).filter(e=>tg(e)&&"body"!==th(e)),a=null,i="fixed"===tD(e).position,o=i?tT(e):e;for(;tg(o)&&!tA(o);){let e=tD(o),t=tE(o),r=a?a.position:i?"fixed":"";t||"fixed"!==r&&("absolute"!==r||"static"!==e.position)?a=e:n=n.filter(e=>e!==o),o=tT(o)}return t.set(e,n),n}(t,this._c):[].concat(r),n],o=tW(t,i[0],a),s=o.top,l=o.right,u=o.bottom,c=o.left;for(let e=1;e<i.length;e++){let r=tW(t,i[e],a);s=eZ(r.top,s),l=eX(r.right,l),u=eX(r.bottom,u),c=eZ(r.left,c)}return{width:l-c,height:u-s,x:c,y:s}},getOffsetParent:tH,getElementRects:tG,getClientRects:function(e){return e.getClientRects?Array.from(e.getClientRects()):[]},getDimensions:function(e){let{width:t,height:r}=tM(e);return{width:t,height:r}},getScale:t_,isElement:tg,isRTL:function(e){return"rtl"===tD(e).direction}};function tq(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}let tY=e=>({name:"arrow",options:e,async fn(t){let{x:r,y:n,placement:a,rects:i,platform:o,elements:s,middlewareData:l}=t,{element:u,padding:c=0}=e2(e,t)||{};if(null==u)return{};let d=ta(c),f={x:r,y:n},p=e5(e8(a)),h=e6(p),m=await o.getDimensions(u),y="y"===p,v=y?"clientHeight":"clientWidth",g=i.reference[h]+i.reference[p]-f[p]-i.floating[h],b=f[p]-i.reference[p],x=await (null==o.getOffsetParent?void 0:o.getOffsetParent(u)),w=x?x[v]:0;w&&await (null==o.isElement?void 0:o.isElement(x))||(w=s.floating[v]||i.floating[h]);let S=w/2-m[h]/2-1,j=eX(d[y?"top":"left"],S),O=eX(d[y?"bottom":"right"],S),k=w-m[h]-O,E=w/2-m[h]/2+(g/2-b/2),P=eZ(j,eX(E,k)),A=!l.arrow&&null!=e4(a)&&E!==P&&i.reference[h]/2-(E<j?j:O)-m[h]/2<0,D=A?E<j?E-j:E-k:0;return{[p]:f[p]+D,data:{[p]:P,centerOffset:E-P-D,...A&&{alignmentOffset:D}},reset:A}}});var tX="u">typeof document?p.useLayoutEffect:function(){};function tZ(e,t){let r,n,a;if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if((r=e.length)!==t.length)return!1;for(n=r;0!=n--;)if(!tZ(e[n],t[n]))return!1;return!0}if((r=(a=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(n=r;0!=n--;)if(!({}).hasOwnProperty.call(t,a[n]))return!1;for(n=r;0!=n--;){let r=a[n];if(("_owner"!==r||!e.$$typeof)&&!tZ(e[r],t[r]))return!1}return!0}return e!=e&&t!=t}function tQ(e){return"u"<typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function tJ(e,t){let r=tQ(e);return Math.round(t*r)/r}function t0(e){let t=p.useRef(e);return tX(()=>{t.current=e}),t}var t1=Object.defineProperty,t2=p.forwardRef(t1(function(e,t){let{children:r,width:n=10,height:a=5,...i}=e;return(0,f.jsx)(es.svg,{...i,ref:t,width:n,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:(0,f.jsx)("polygon",{points:"0,0 30,0 15,10"})})},"name",{value:"Arrow",configurable:!0}));function t3(e){let[t,r]=p.useState(void 0);return eu(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});let t=0,n=new ResizeObserver(n=>{if(!Array.isArray(n)||!n.length)return;let a=n[0];window.cancelAnimationFrame(t),t=window.requestAnimationFrame(()=>{let t,n;if("borderBoxSize"in a){let e=a.borderBoxSize,r=Array.isArray(e)?e[0]:e;t=r.inlineSize,n=r.blockSize}else t=e.offsetWidth,n=e.offsetHeight;r({width:t,height:n})})});return n.observe(e,{box:"border-box"}),()=>{window.cancelAnimationFrame(t),n.unobserve(e)}}r(void 0)},[e]),t}(0,Object.defineProperty)(t3,"name",{value:"useSize",configurable:!0});var t4=Object.defineProperty,t5=(e,t)=>t4(e,"name",{value:t,configurable:!0}),t6="partial",t8="Popper",[t9,t7]=en(t8),[re,rt]=t9(t8),rr=t5(e=>{let{__scopePopper:t,children:r}=e,[n,a]=p.useState(null),[i,o]=p.useState(void 0);return(0,f.jsx)(re,{scope:t,anchor:n,onAnchorChange:a,placementState:i,setPlacementState:o,children:r})},"Popper"),rn=p.forwardRef(t5(function(e,t){let{__scopePopper:r,virtualRef:n,...a}=e,i=rt("PopperAnchor",r),o=p.useRef(null),s=i.onAnchorChange,l=j(t,p.useCallback(e=>{o.current=e,e&&s(e)},[s])),u=p.useRef(null);p.useEffect(()=>{if(!n)return;let e=u.current;u.current=n.current,e!==u.current&&s(u.current)});let c=i.placementState&&rf(i.placementState),d=c?.[0],h=c?.[1];return n?null:(0,f.jsx)(es.div,{"data-radix-popper-side":d,"data-radix-popper-align":h,...a,ref:l})},"PopperAnchor")),ra="PopperContent",[ri,ro]=t9(ra),rs=p.forwardRef(t5(function(e,t){var r,n,a,i,o,s,l,u,c,d,h,m,y,v,g,b,x,w,S,O,k;let E,P,A,D,C,T,{__scopePopper:N,side:R="bottom",sideOffset:M=0,align:I="center",alignOffset:L=0,arrowPadding:F=0,avoidCollisions:B=!0,collisionBoundary:V=[],collisionPadding:z=0,sticky:W=t6,hideWhenDetached:$=!1,updatePositionStrategy:U="optimized",onPlaced:H,...G}=e,K=rt(ra,N),[q,Y]=p.useState(null),X=j(t,Y),[Z,Q]=p.useState(null),J=t3(Z),ee=J?.width??0,et=J?.height??0,er="number"==typeof z?z:{top:0,right:0,bottom:0,left:0,...z},en=Array.isArray(V)?V:[V],ea=en.length>0,eo={padding:er,boundary:en.filter(rc),altBoundary:ea},{refs:el,floatingStyles:ec,placement:ed,isPositioned:ep,middlewareData:eh}=function(e){void 0===e&&(e={});let{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:a,elements:{reference:i,floating:o}={},transform:s=!0,whileElementsMounted:l,open:u}=e,[c,d]=p.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[f,h]=p.useState(n);tZ(f,n)||h(n);let[m,y]=p.useState(null),[v,g]=p.useState(null),b=p.useCallback(e=>{e!==j.current&&(j.current=e,y(e))},[]),x=p.useCallback(e=>{e!==O.current&&(O.current=e,g(e))},[]),w=i||m,S=o||v,j=p.useRef(null),O=p.useRef(null),k=p.useRef(c),E=null!=l,P=t0(l),A=t0(a),D=t0(u),C=p.useCallback(()=>{var e,n;let a,i,o;if(!j.current||!O.current)return;let s={placement:t,strategy:r,middleware:f};A.current&&(s.platform=A.current),(e=j.current,n=O.current,a=new Map,i=null!=s?s:{},o={...tK,...i.platform,_c:a},tl(e,n,{...i,platform:o})).then(e=>{let t={...e,isPositioned:!1!==D.current};T.current&&!tZ(k.current,t)&&(k.current=t,ei.flushSync(()=>{d(t)}))})},[f,t,r,A,D]);tX(()=>{!1===u&&k.current.isPositioned&&(k.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[u]);let T=p.useRef(!1);tX(()=>(T.current=!0,()=>{T.current=!1}),[]),tX(()=>{if(w&&(j.current=w),S&&(O.current=S),w&&S){if(P.current)return P.current(w,S,C);C()}},[w,S,C,P,E]);let N=p.useMemo(()=>({reference:j,floating:O,setReference:b,setFloating:x}),[b,x]),R=p.useMemo(()=>({reference:w,floating:S}),[w,S]),M=p.useMemo(()=>{let e={position:r,left:0,top:0};if(!R.floating)return e;let t=tJ(R.floating,c.x),n=tJ(R.floating,c.y);return s?{...e,transform:"translate("+t+"px, "+n+"px)",...tQ(R.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:t,top:n}},[r,s,R.floating,c.x,c.y]);return p.useMemo(()=>({...c,update:C,refs:N,elements:R,floatingStyles:M}),[c,C,N,R,M])}({strategy:"fixed",placement:R+("center"!==I?"-"+I:""),whileElementsMounted:t5((...e)=>(function(e,t,r,n){let a;void 0===n&&(n={});let{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:s="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:u=!1}=n,c=tI(e),d=i||o?[...c?tN(c):[],...t?tN(t):[]]:[];d.forEach(e=>{i&&e.addEventListener("scroll",r),o&&e.addEventListener("resize",r)});let f=c&&l?function(e,t,r){let n,a=null,i=ty(e);function o(){var e;clearTimeout(n),null==(e=a)||e.disconnect(),a=null}function s(r,l){void 0===r&&(r=!1),void 0===l&&(l=1),o();let u=e.getBoundingClientRect(),{left:c,top:d,width:f,height:p}=u;if(r||t(),!f||!p)return;let h={rootMargin:-eJ(d)+"px "+-eJ(i.clientWidth-(c+f))+"px "+-eJ(i.clientHeight-(d+p))+"px "+-eJ(c)+"px",threshold:eZ(0,eX(1,l))||1},m=!0;function y(t){let r=t[0].intersectionRatio;if(!tq(u,e.getBoundingClientRect()))return s();if(r!==l){if(!m)return s();r?s(!1,r):n=setTimeout(()=>{s(!1,1e-7)},1e3)}m=!1}try{a=new IntersectionObserver(y,{...h,root:i.ownerDocument})}catch(e){a=new IntersectionObserver(y,h)}a.observe(e)}let l=tm(e),u=()=>s(r);return l.addEventListener("resize",u),s(!0),()=>{l.removeEventListener("resize",u),o()}}(c,r,o):null,p=-1,h=null;s&&(h=new ResizeObserver(e=>{let[n]=e;n&&n.target===c&&h&&t&&(h.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var e;null==(e=h)||e.observe(t)})),r()}),c&&!u&&h.observe(c),t&&h.observe(t));let m=u?tB(e):null;return u&&function t(){let n=tB(e);m&&!tq(m,n)&&r(),m=n,a=requestAnimationFrame(t)}(),r(),()=>{var e;d.forEach(e=>{i&&e.removeEventListener("scroll",r),o&&e.removeEventListener("resize",r)}),null==f||f(),null==(e=h)||e.disconnect(),h=null,u&&cancelAnimationFrame(a)}})(...e,{animationFrame:"always"===U}),"whileElementsMounted"),elements:{reference:K.anchor},middleware:[{name:(E={name:"offset",options:a=r={mainAxis:M+et,alignmentAxis:L},async fn(e){var t,r;let{x:n,y:i,placement:o,middlewareData:s}=e,l=await tf(e,a);return o===(null==(t=s.offset)?void 0:t.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:n+l.x,y:i+l.y,data:{...l,placement:o}}}}).name,fn:E.fn,options:[r,n]},B&&{name:(P={name:"shift",options:c=l={mainAxis:!0,crossAxis:!1,...W===t6?{limiter:{fn:(void 0===(s=i)&&(s={}),{options:s,fn(e){var t,r,n,a;let{x:i,y:o,placement:l,rects:u,middlewareData:c}=e,{offset:d=0,mainAxis:f=!0,crossAxis:p=!0}=e2(s,e),h={x:i,y:o},m=e8(l),y=e5(m),v=h[y],g=h[m],b=e2(d,e),x="number"==typeof b?{mainAxis:b,crossAxis:0}:{mainAxis:null!=(t=b.mainAxis)?t:0,crossAxis:null!=(r=b.crossAxis)?r:0};if(f){let e="y"===y?"height":"width",t=u.reference[y]-u.floating[e]+x.mainAxis,r=u.reference[y]+u.reference[e]-x.mainAxis;v<t?v=t:v>r&&(v=r)}if(p){let e="y"===y?"width":"height",t=td.has(e3(l)),r=u.reference[m]-u.floating[e]+(t&&(null==(n=c.offset)?void 0:n[m])||0)+(t?0:x.crossAxis),i=u.reference[m]+u.reference[e]+(t?0:(null==(a=c.offset)?void 0:a[m])||0)-(t?x.crossAxis:0);g<r?g=r:g>i&&(g=i)}return{[y]:v,[m]:g}}}).fn,options:[i,o]}}:{},...eo},async fn(e){let{x:t,y:r,placement:n,platform:a}=e,{mainAxis:i=!0,crossAxis:o=!1,limiter:s={fn:e=>{let{x:t,y:r}=e;return{x:t,y:r}}},...l}=e2(c,e),u={x:t,y:r},d=await a.detectOverflow(e,l),f=e8(n),p=e5(f),h=u[p],m=u[f],y=(e,t)=>eZ(t+d["y"===e?"top":"left"],eX(t,t-d["y"===e?"bottom":"right"]));i&&(h=y(p,h)),o&&(m=y(f,m));let v=s.fn({...e,[p]:h,[f]:m});return{...v,data:{x:v.x-t,y:v.y-r,enabled:{[p]:i,[f]:o}}}}}).name,fn:P.fn,options:[l,u]},B&&{name:(A={name:"flip",options:m=d={...eo},async fn(e){var t,r,n,a,i,o,s,l;let u,c,d,{placement:f,middlewareData:p,rects:h,initialPlacement:y,platform:v,elements:g}=e,{mainAxis:b=!0,crossAxis:x=!0,fallbackPlacements:w,fallbackStrategy:S="bestFit",fallbackAxisSideDirection:j="none",flipAlignment:O=!0,...k}=e2(m,e);if(null!=(t=p.arrow)&&t.alignmentOffset)return{};let E=e3(f),P=e8(y),A=e3(y)===y,D=await (null==v.isRTL?void 0:v.isRTL(g.floating)),C=w||(A||!O?[tn(y)]:(u=tn(y),[e9(y),u,e9(u)])),T="none"!==j;!w&&T&&C.push(...(c=e4(y),d=function(e,t,r){switch(e){case"top":case"bottom":if(r)return t?te:e7;return t?e7:te;case"left":case"right":return t?tt:tr;default:return[]}}(e3(y),"start"===j,D),c&&(d=d.map(e=>e+"-"+c),O&&(d=d.concat(d.map(e9)))),d));let N=[y,...C],R=await v.detectOverflow(e,k),M=[],I=(null==(r=p.flip)?void 0:r.overflows)||[];if(b&&M.push(R[E]),x){let e,t,r,n,a=(o=f,s=h,void 0===(l=D)&&(l=!1),e=e4(o),r=e6(t=e5(e8(o))),n="x"===t?e===(l?"end":"start")?"right":"left":"start"===e?"bottom":"top",s.reference[r]>s.floating[r]&&(n=tn(n)),[n,tn(n)]);M.push(R[a[0]],R[a[1]])}if(I=[...I,{placement:f,overflows:M}],!M.every(e=>e<=0)){let e=((null==(n=p.flip)?void 0:n.index)||0)+1,t=N[e];if(t&&("alignment"!==x||P===e8(t)||I.every(e=>e8(e.placement)!==P||e.overflows[0]>0)))return{data:{index:e,overflows:I},reset:{placement:t}};let r=null==(a=I.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:a.placement;if(!r)switch(S){case"bestFit":{let e=null==(i=I.filter(e=>{if(T){let t=e8(e.placement);return t===P||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:i[0];e&&(r=e);break}case"initialPlacement":r=y}if(f!==r)return{reset:{placement:r}}}return{}}}).name,fn:A.fn,options:[d,h]},{name:(D={name:"size",options:g=y={...eo,apply:t5(({elements:e,rects:t,availableWidth:r,availableHeight:n})=>{let{width:a,height:i}=t.reference,o=e.floating.style;o.setProperty("--radix-popper-available-width",`${r}px`),o.setProperty("--radix-popper-available-height",`${n}px`),o.setProperty("--radix-popper-anchor-width",`${a}px`),o.setProperty("--radix-popper-anchor-height",`${i}px`)},"apply")},async fn(e){let t,r,{placement:n,rects:a,platform:i,elements:o}=e,{apply:s=()=>{},...l}=e2(g,e),u=await i.detectOverflow(e,l),c=e3(n),d=e4(n),f="y"===e8(n),{width:p,height:h}=a.floating;"top"===c||"bottom"===c?(t=c,r=d===(await (null==i.isRTL?void 0:i.isRTL(o.floating))?"start":"end")?"left":"right"):(r=c,t="end"===d?"top":"bottom");let m=h-u.top-u.bottom,y=p-u.left-u.right,v=eX(h-u[t],m),b=eX(p-u[r],y),x=e.middlewareData.shift,w=!x,S=v,j=b;null!=x&&x.enabled.x&&(j=y),null!=x&&x.enabled.y&&(S=m),w&&!d&&(f?j=p-2*eZ(u.left,u.right):S=h-2*eZ(u.top,u.bottom)),await s({...e,availableWidth:j,availableHeight:S});let O=await i.getDimensions(o.floating);return p!==O.width||h!==O.height?{reset:{rects:!0}}:{}}}).name,fn:D.fn,options:[y,v]},Z&&{name:(C={name:"arrow",options:w=b={element:Z,padding:F},fn(e){let{element:t,padding:r}="function"==typeof w?w(e):w;return t&&({}).hasOwnProperty.call(t,"current")?null!=t.current?tY({element:t.current,padding:r}).fn(e):{}:t?tY({element:t,padding:r}).fn(e):{}}}).name,fn:C.fn,options:[b,x]},rd({arrowWidth:ee,arrowHeight:et}),$&&{name:(T={name:"hide",options:k=S=ea?{strategy:"referenceHidden",...eo}:{strategy:"referenceHidden",padding:eo.padding,altBoundary:eo.altBoundary},async fn(e){let{rects:t,platform:r}=e,{strategy:n="referenceHidden",...a}=e2(k,e);switch(n){case"referenceHidden":{let n=tu(await r.detectOverflow(e,{...a,elementContext:"reference"}),t.reference);return{data:{referenceHiddenOffsets:n,referenceHidden:tc(n)}}}case"escaped":{let n=tu(await r.detectOverflow(e,{...a,altBoundary:!0}),t.floating);return{data:{escapedOffsets:n,escaped:tc(n)}}}default:return{}}}}).name,fn:T.fn,options:[S,O]}]}),em=K.setPlacementState;eu(()=>(em(ed),()=>{em(void 0)}),[ed,em]);let[ey,ev]=rf(ed),eg=ef(H);eu(()=>{ep&&eg?.()},[ep,eg]);let eb=eh.arrow?.x,ex=eh.arrow?.y,ew=eh.arrow?.centerOffset!==0,[eS,ej]=p.useState();return eu(()=>{q&&ej(window.getComputedStyle(q).zIndex)},[q]),(0,f.jsx)("div",{ref:el.setFloating,"data-radix-popper-content-wrapper":"",style:{...ec,transform:ep?ec.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:eS,"--radix-popper-transform-origin":[eh.transformOrigin?.x,eh.transformOrigin?.y].join(" "),...eh.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:(0,f.jsx)(ri,{scope:N,placedSide:ey,placedAlign:ev,onArrowChange:Q,arrowX:eb,arrowY:ex,shouldHideArrow:ew,children:(0,f.jsx)(es.div,{"data-side":ey,"data-align":ev,...G,ref:X,style:{...G.style,animation:ep?G.style?.animation:"none"}})})})},"PopperContent")),rl={top:"bottom",right:"left",bottom:"top",left:"right"},ru=p.forwardRef(t5(function(e,t){let{__scopePopper:r,...n}=e,a=ro("PopperArrow",r),i=rl[a.placedSide];return(0,f.jsx)("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:(0,f.jsx)(t2,{...n,ref:t,style:{...n.style,display:"block"}})})},"PopperArrow"));function rc(e){return null!==e}t5(rc,"isNotNull");var rd=t5(e=>({name:"transformOrigin",options:e,fn(t){let{placement:r,rects:n,middlewareData:a}=t,i=a.arrow?.centerOffset!==0,o=i?0:e.arrowWidth,s=i?0:e.arrowHeight,[l,u]=rf(r),c={start:"0%",center:"50%",end:"100%"}[u],d=(a.arrow?.x??0)+o/2,f=(a.arrow?.y??0)+s/2,p="",h="";return"bottom"===l?(p=i?c:`${d}px`,h=`${-s}px`):"top"===l?(p=i?c:`${d}px`,h=`${n.floating.height+s}px`):"right"===l?(p=`${-s}px`,h=i?c:`${f}px`):"left"===l&&(p=`${n.floating.width+s}px`,h=i?c:`${f}px`),{data:{x:p,y:h}}}}),"transformOrigin");function rf(e){let[t,r="center"]=e.split("-");return[t,r]}t5(rf,"getSideAndAlignFromPlacement");var rp=Object.defineProperty,rh=p.forwardRef(rp(function(e,t){let{container:r,...n}=e,[a,i]=p.useState(!1);eu(()=>i(!0),[]);let o=r||a&&globalThis?.document?.body;return o?ei.createPortal((0,f.jsx)(es.div,{...n,ref:t}),o):null},"name",{value:"Portal",configurable:!0})),rm=Object.defineProperty,ry=(e,t)=>rm(e,"name",{value:t,configurable:!0});function rv(e,t){return p.useReducer((e,r)=>t[e][r]??e,e)}ry(rv,"useStateMachine");var rg=ry(e=>{let{present:t,children:r}=e,n=rb(t),a="function"==typeof r?r({present:n.isPresent}):p.Children.only(r),i=rw(n.ref,rj(a));return"function"==typeof r||n.isPresent?p.cloneElement(a,{ref:i}):null},"Presence");function rb(e){let[t,r]=p.useState(),n=p.useRef(null),a=p.useRef(e),i=p.useRef("none"),o=p.useRef(void 0),[s,l]=rv(e?"mounted":"unmounted",{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return p.useEffect(()=>{"mounted"===s?(i.current=o.current??rS(n.current),o.current=void 0):i.current="none"},[s]),eu(()=>{let t=n.current,r=a.current;if(r!==e){let n=i.current,s=rS(t);e?(o.current=s,l("MOUNT")):"none"===s||t?.display==="none"?l("UNMOUNT"):r&&n!==s?l("ANIMATION_OUT"):l("UNMOUNT"),a.current=e}},[e,l]),eu(()=>{if(t){let e,r=t.ownerDocument.defaultView??window,o=ry(i=>{let o=rS(n.current).includes(CSS.escape(i.animationName));if(i.target===t&&o&&(l("ANIMATION_END"),!a.current)){let n=t.style.animationFillMode;t.style.animationFillMode="forwards",e=r.setTimeout(()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=n)})}},"handleAnimationEnd"),s=ry(e=>{e.target===t&&(i.current=rS(n.current))},"handleAnimationStart");return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",o),t.addEventListener("animationend",o),()=>{r.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",o),t.removeEventListener("animationend",o)}}l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:p.useCallback(e=>{if(e){let t=getComputedStyle(e);n.current=t,o.current=rS(t)}else n.current=null;r(e)},[])}}function rx(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function rw(...e){let t=p.useRef(e);return t.current=e,p.useCallback(e=>{let r=t.current,n=!1,a=r.map(t=>{let r=rx(t,e);return n||"function"!=typeof r||(n=!0),r});if(n)return()=>{for(let e=0;e<a.length;e++){let t=a[e];"function"==typeof t?t():rx(r[e],null)}}},[])}function rS(e){return e?.animationName||"none"}function rj(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(r=(t=Object.getOwnPropertyDescriptor(e,"ref")?.get)&&"isReactWarning"in t&&t.isReactWarning)?e.props.ref:e.props.ref||e.ref}ry(rb,"usePresence"),ry(rx,"setRef"),ry(rw,"useStableComposedRefs"),ry(rS,"getAnimationName"),ry(rj,"getElementRef");var rO=Object.defineProperty,rk=p[" useEffectEvent ".trim().toString()],rE=p[" useInsertionEffect ".trim().toString()];function rP(e){if("function"==typeof rk)return rk(e);let t=p.useRef(()=>{throw Error("Cannot call an event handler while rendering.")});return"function"==typeof rE?rE(()=>{t.current=e}):eu(()=>{t.current=e}),p.useMemo(()=>(...e)=>t.current?.(...e),[])}rO(rP,"name",{value:"useEffectEvent",configurable:!0});var rA=Object.defineProperty,rD=(e,t)=>rA(e,"name",{value:t,configurable:!0}),rC=p[" useInsertionEffect ".trim().toString()]||eu;function rT({prop:e,defaultProp:t,onChange:r=rD(()=>{},"onChange"),caller:n}){let[a,i,o]=rN({defaultProp:t,onChange:r}),s=void 0!==e,l=s?e:a;return[l,p.useCallback(t=>{if(s){let r=rR(t)?t(e):t;r!==e&&o.current?.(r)}else i(t)},[s,e,i,o])]}function rN({defaultProp:e,onChange:t}){let[r,n]=p.useState(e),a=p.useRef(r),i=p.useRef(t);return rC(()=>{i.current=t},[t]),p.useEffect(()=>{a.current!==r&&(i.current?.(r),a.current=r)},[r,a]),[r,n,i]}function rR(e){return"function"==typeof e}rD(rT,"useControllableState"),rD(rN,"useUncontrolledState"),rD(rR,"isFunction");var rM=Symbol("RADIX:SYNC_STATE");rD(function(e,t,r,n){let{prop:a,defaultProp:i,onChange:o,caller:s}=t,l=void 0!==a,u=rP(o),c=[{...r,state:i}];n&&c.push(n);let[d,f]=p.useReducer((t,r)=>{if(r.type===rM)return{...t,state:r.state};let n=e(t,r);return l&&!Object.is(n.state,t.state)&&u(n.state),n},...c),h=d.state,m=p.useRef(h);p.useEffect(()=>{m.current!==h&&(m.current=h,l||u(h))},[h,m,l]);let y=p.useMemo(()=>void 0!==a?{...d,state:a}:d,[d,a]);return p.useEffect(()=>{l&&!Object.is(a,d.state)&&f({type:rM,state:a})},[a,d.state,l]),[y,f]},"useControllableStateReducer");var rI=Object.defineProperty,r_=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),rL=p.forwardRef(rI(function(e,t){return(0,f.jsx)(es.span,{...e,ref:t,style:{...r_,...e.style}})},"name",{value:"VisuallyHidden",configurable:!0})),rF=Object.defineProperty,rB=(e,t)=>rF(e,"name",{value:t,configurable:!0}),[rV,rz]=en("Tooltip",[t7]),rW=t7(),r$="tooltip.open",[rU,rH]=rV("TooltipProvider"),rG=rB(e=>{let{__scopeTooltip:t,delayDuration:r=700,skipDelayDuration:n=300,disableHoverableContent:a=!1,children:i}=e,o=p.useRef(!0),s=p.useRef(!1),l=p.useRef(0);return p.useEffect(()=>{let e=l.current;return()=>window.clearTimeout(e)},[]),(0,f.jsx)(rU,{scope:t,isOpenDelayedRef:o,delayDuration:r,onOpen:p.useCallback(()=>{n<=0||(window.clearTimeout(l.current),o.current=!1)},[n]),onClose:p.useCallback(()=>{n<=0||(window.clearTimeout(l.current),l.current=window.setTimeout(()=>o.current=!0,n))},[n]),isPointerInTransitRef:s,onPointerInTransitChange:p.useCallback(e=>{s.current=e},[]),disableHoverableContent:a,children:i})},"TooltipProvider"),rK="Tooltip",[rq,rY]=rV(rK),rX=rB(e=>{let{__scopeTooltip:t,children:r,open:n,defaultOpen:a,onOpenChange:i,disableHoverableContent:o,delayDuration:s}=e,l=rH(rK,e.__scopeTooltip),u=rW(t),[c,d]=p.useState(null),[h,m]=p.useState(void 0),y=eq(),v=p.useRef(0),g=o??l.disableHoverableContent,b=s??l.delayDuration,x=p.useRef(!1),[w,S]=rT({prop:n,defaultProp:a??!1,onChange:rB(e=>{e?(l.onOpen(),document.dispatchEvent(new CustomEvent(r$))):l.onClose(),i?.(e)},"onChange"),caller:rK}),j=p.useMemo(()=>w?x.current?"delayed-open":"instant-open":"closed",[w]),O=p.useCallback(()=>{window.clearTimeout(v.current),v.current=0,x.current=!1,S(!0)},[S]),k=p.useCallback(()=>{window.clearTimeout(v.current),v.current=0,S(!1)},[S]),E=p.useCallback(()=>{window.clearTimeout(v.current),v.current=window.setTimeout(()=>{x.current=!0,S(!0),v.current=0},b)},[b,S]);return p.useEffect(()=>()=>{v.current&&(window.clearTimeout(v.current),v.current=0)},[]),(0,f.jsx)(rr,{...u,children:(0,f.jsx)(rq,{scope:t,contentId:h??y,setContentId:m,open:w,stateAttribute:j,trigger:c,onTriggerChange:d,onTriggerEnter:p.useCallback(()=>{l.isOpenDelayedRef.current?E():O()},[l.isOpenDelayedRef,E,O]),onTriggerLeave:p.useCallback(()=>{g?k():(window.clearTimeout(v.current),v.current=0)},[k,g]),onOpen:O,onClose:k,disableHoverableContent:g,children:r})})},"Tooltip"),rZ="TooltipTrigger",rQ=p.forwardRef(rB(function(e,t){let{__scopeTooltip:r,"aria-describedby":n,...a}=e,i=rY(rZ,r),o=rH(rZ,r),s=rW(r),l=j(t,p.useRef(null),i.onTriggerChange),u=p.useRef(!1),c=p.useRef(!1),d=p.useCallback(()=>u.current=!1,[]);return p.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),(0,f.jsx)(rn,{asChild:!0,...s,children:(0,f.jsx)(es.button,{"aria-describedby":i.open?ni(n,i.contentId):n,"data-state":i.stateAttribute,...a,ref:l,onPointerMove:Q(e.onPointerMove,e=>{"touch"!==e.pointerType&&(c.current||o.isPointerInTransitRef.current||(i.onTriggerEnter(),c.current=!0))}),onPointerLeave:Q(e.onPointerLeave,()=>{i.onTriggerLeave(),c.current=!1}),onPointerDown:Q(e.onPointerDown,()=>{i.open&&i.onClose(),u.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:Q(e.onFocus,()=>{u.current||i.onOpen()}),onBlur:Q(e.onBlur,i.onClose),onClick:Q(e.onClick,i.onClose)})})},"TooltipTrigger")),rJ="TooltipPortal",[r0,r1]=rV(rJ,{forceMount:void 0}),r2=rB(e=>{let{__scopeTooltip:t,forceMount:r,children:n,container:a}=e,i=rY(rJ,t);return(0,f.jsx)(r0,{scope:t,forceMount:r,children:(0,f.jsx)(rg,{present:r||i.open,children:(0,f.jsx)(rh,{asChild:!0,container:a,children:n})})})},"TooltipPortal"),r3="TooltipContent",r4=p.forwardRef(rB(function(e,t){let r=r1(r3,e.__scopeTooltip),{forceMount:n=r.forceMount,side:a="top",...i}=e,o=rY(r3,e.__scopeTooltip);return(0,f.jsx)(rg,{present:n||o.open,children:o.disableHoverableContent?(0,f.jsx)(r8,{side:a,...i,ref:t}):(0,f.jsx)(r5,{side:a,...i,ref:t})})},"TooltipContent")),r5=p.forwardRef(rB(function(e,t){let r=rY(r3,e.__scopeTooltip),n=rH(r3,e.__scopeTooltip),a=p.useRef(null),i=j(t,a),[o,s]=p.useState(null),{trigger:l,onClose:u}=r,c=a.current,{onPointerInTransitChange:d}=n,h=p.useCallback(()=>{s(null),d(!1)},[d]),m=p.useCallback((e,t)=>{let r=e.currentTarget,n={x:e.clientX,y:e.clientY},a=r7(n,r.getBoundingClientRect());s(nn([...ne(n,a),...nt(t.getBoundingClientRect())])),d(!0)},[d]);return p.useEffect(()=>()=>h(),[h]),p.useEffect(()=>{if(l&&c){let e=rB(e=>m(e,c),"handleTriggerLeave"),t=rB(e=>m(e,l),"handleContentLeave");return l.addEventListener("pointerleave",e),c.addEventListener("pointerleave",t),()=>{l.removeEventListener("pointerleave",e),c.removeEventListener("pointerleave",t)}}},[l,c,m,h]),p.useEffect(()=>{if(o){let e=rB(e=>{let t=e.target,r={x:e.clientX,y:e.clientY},n=l?.contains(t)||c?.contains(t),a=!nr(r,o);n?h():a&&(h(),u())},"handleTrackPointerGrace");return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}},[l,c,o,u,h]),(0,f.jsx)(r8,{...e,ref:i})},"TooltipContentHoverable")),r6=D("TooltipContent"),r8=p.forwardRef(rB(function(e,t){let{__scopeTooltip:r,children:n,"aria-label":a,id:i,onEscapeKeyDown:o,onPointerDownOutside:s,...l}=e,u=rY(r3,r),c=rW(r),{onClose:d}=u,[h,m]=p.useState(null),y=j(t,m);eR(h),p.useEffect(()=>(document.addEventListener(r$,d),()=>document.removeEventListener(r$,d)),[d]),p.useEffect(()=>{if(u.trigger){let e=rB(e=>{e.target instanceof Node&&e.target.contains(u.trigger)&&d()},"handleScroll");return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}},[u.trigger,d]);let{setContentId:v}=u;return eu(()=>(v(i),()=>{v(void 0)}),[i,v]),(0,f.jsx)(ev,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:e=>e.preventDefault(),onDismiss:d,children:(0,f.jsxs)(rs,{"data-state":u.stateAttribute,role:a?void 0:"tooltip",id:a?void 0:u.contentId,...c,...l,ref:y,style:{...l.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[(0,f.jsx)(r6,{children:n}),a?(0,f.jsx)(rL,{id:u.contentId,role:"tooltip",children:a}):null]})})},"TooltipContentImpl")),r9=p.forwardRef(rB(function(e,t){let{__scopeTooltip:r,...n}=e,a=rW(r);return(0,f.jsx)(ru,{...a,...n,ref:t})},"TooltipArrow"));function r7(e,t){let r=Math.abs(t.top-e.y),n=Math.abs(t.bottom-e.y),a=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(r,n,a,i)){case i:return"left";case a:return"right";case r:return"top";case n:return"bottom";default:throw Error("unreachable")}}function ne(e,t,r=5){let n=[];switch(t){case"top":n.push({x:e.x-r,y:e.y+r},{x:e.x+r,y:e.y+r});break;case"bottom":n.push({x:e.x-r,y:e.y-r},{x:e.x+r,y:e.y-r});break;case"left":n.push({x:e.x+r,y:e.y-r},{x:e.x+r,y:e.y+r});break;case"right":n.push({x:e.x-r,y:e.y-r},{x:e.x-r,y:e.y+r})}return n}function nt(e){let{top:t,right:r,bottom:n,left:a}=e;return[{x:a,y:t},{x:r,y:t},{x:r,y:n},{x:a,y:n}]}function nr(e,t){let{x:r,y:n}=e,a=!1;for(let e=0,i=t.length-1;e<t.length;i=e++){let o=t[e],s=t[i],l=o.x,u=o.y,c=s.x,d=s.y;u>n!=d>n&&r<(c-l)*(n-u)/(d-u)+l&&(a=!a)}return a}function nn(e){let t=e.slice();return t.sort((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:1*!!(e.y>t.y)),na(t)}function na(e){if(e.length<=1)return e.slice();let t=[];for(let r=0;r<e.length;r++){let n=e[r];for(;t.length>=2;){let e=t[t.length-1],r=t[t.length-2];if((e.x-r.x)*(n.y-r.y)>=(e.y-r.y)*(n.x-r.x))t.pop();else break}t.push(n)}t.pop();let r=[];for(let t=e.length-1;t>=0;t--){let n=e[t];for(;r.length>=2;){let e=r[r.length-1],t=r[r.length-2];if((e.x-t.x)*(n.y-t.y)>=(e.y-t.y)*(n.x-t.x))r.pop();else break}r.push(n)}return(r.pop(),1===t.length&&1===r.length&&t[0].x===r[0].x&&t[0].y===r[0].y)?t:t.concat(r)}function ni(...e){let t=new Set;for(let r of e)if("string"==typeof r)for(let e of String(r).trim().split(/\s+/))e&&t.add(e);return t.size>0?Array.from(t).join(" "):void 0}function no(){return(no=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e}).apply(this,arguments)}function ns(e){if(null==e)throw TypeError("Cannot destructure "+e);return e}function nl(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function nu(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function nc(e){var t=e.delayDuration,r=nu(e,["delayDuration"]);return(0,f.jsx)(rG,nl({"data-slot":"tooltip-provider",delayDuration:void 0===t?0:t},r))}function nd(e){ns(e);var t=no({},e);return(0,f.jsx)(rX,nl({"data-slot":"tooltip"},t))}function nf(e){ns(e);var t=no({},e);return(0,f.jsx)(rQ,nl({"data-slot":"tooltip-trigger"},t))}function np(e){var t,r,n=e.className,a=e.sideOffset,i=e.children,o=nu(e,["className","sideOffset","children"]);return(0,f.jsx)(r2,{children:(0,f.jsxs)(r4,(t=nl({"data-slot":"tooltip-content",sideOffset:void 0===a?0:a,className:(0,g.cn)("z-50 w-fit origin-(--radix-tooltip-content-transform-origin) animate-in rounded-md bg-foreground px-3 py-1.5 text-xs text-balance text-background fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",n)},o),r=r={children:[i,(0,f.jsx)(r9,{className:"z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground"})]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))})}function nh(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function nm(e){if(Array.isArray(e))return e}function ny(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function nv(e,t){if(e){if("string"==typeof e)return nh(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return nh(e,t)}}rB(r7,"getExitSideFromRect"),rB(ne,"getPaddedExitPoints"),rB(nt,"getPointsFromRect"),rB(nr,"isPointInPolygon"),rB(nn,"getHull"),rB(na,"getHullPresorted"),rB(ni,"concatAriaDescribedby");var ng=p.forwardRef(function(e,t){var r,n,a,i=nm(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||nv(r)||ny(),o=i[0],s=i.slice(1),l=o.icon,u=o.label,c=o.size,d=o.variant,p=o.tooltipSide,h=o.noTooltip,m=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(o,["icon","label","size","variant","tooltipSide","noTooltip"]),y=(nm(s)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),1!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(s)||nv(s,1)||ny())[0],v=(0,f.jsx)(q,(n=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({ref:y,type:"button",variant:void 0===d?"ghost":d,size:void 0===c?"icon":c,"aria-label":u},m),a=a={children:l},Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(a)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(a)).forEach(function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(a,e))}),n));return void 0!==h&&h?v:(0,f.jsx)(nc,{children:(0,f.jsxs)(nd,{children:[(0,f.jsx)(nf,{asChild:!0,children:v}),(0,f.jsx)(np,{side:void 0===p?"top":p,children:u})]})})});function nb(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function nx(e){if(Array.isArray(e))return e}function nw(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function nS(e,t){if(e){if("string"==typeof e)return nb(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return nb(e,t)}}var nj=v("inline-flex w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-full border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3",{variants:{variant:{default:"bg-primary text-primary-foreground [a&]:hover:bg-primary/90",secondary:"bg-secondary text-secondary-foreground [a&]:hover:bg-secondary/90",destructive:"bg-destructive text-white focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40 [a&]:hover:bg-destructive/90",outline:"border-border text-foreground [a&]:hover:bg-accent [a&]:hover:text-accent-foreground",ghost:"[a&]:hover:bg-accent [a&]:hover:text-accent-foreground",link:"text-primary underline-offset-4 [a&]:hover:underline"}},defaultVariants:{variant:"default"}}),nO=p.forwardRef(function(e,t){var r,n=nx(r=[e,t])||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||nS(r)||nw(),a=n[0],i=n.slice(1),o=a.className,s=a.variant,l=void 0===s?"default":s,u=a.asChild,c=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(a,["className","variant","asChild"]),d=(nx(i)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),1!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(i)||nS(i,1)||nw())[0];return(0,f.jsx)(void 0!==u&&u?P:"span",function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({ref:d,"data-slot":"badge","data-variant":l,className:(0,g.cn)(nj({variant:l}),o)},c))}),nk=r(4347),nE=(0,nk.A)("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);function nP(e){var t=e.className,r=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className"]);return(0,f.jsx)(nE,function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({role:"status","aria-label":"Loading",className:(0,g.cn)("size-4 animate-spin",t)},r))}var nA=r(3601),nD=(0,nk.A)("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);function nC(e){var t,r,n=e.status,a=void 0===n?"active":n,i=e.description,o=e.className,s=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["status","description","className"]);return"inactive"===a?null:(0,f.jsxs)("div",(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-slot":"inline-loading","data-status":a,role:"status","aria-live":"polite",className:(0,g.cn)("inline-flex items-center gap-2 text-sm text-muted-foreground",o)},s),r=r={children:["active"===a&&(0,f.jsx)(nP,{"aria-label":void 0,role:"presentation"}),"finished"===a&&(0,f.jsx)(nA.A,{className:"size-4 text-emerald-500","aria-hidden":"true"}),"error"===a&&(0,f.jsx)(nD,{className:"size-4 text-destructive","aria-hidden":"true"}),i?(0,f.jsx)("span",{children:i}):null]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))}function nT(e){var t=e.className,r=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className"]);return(0,f.jsx)("div",function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-slot":"layer",className:(0,g.cn)("bg-card text-card-foreground",t)},r))}function nN(e){var t=e.className,r=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["className"]);return(0,f.jsx)("div",function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({"data-slot":"tile",className:(0,g.cn)("flex flex-col gap-6 rounded-xl border bg-card py-6 text-card-foreground shadow-sm",t)},r))}function nR(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function nM(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}var nI=v("relative grid w-full grid-cols-[0_1fr] items-start gap-y-0.5 rounded-lg border px-4 py-3 text-sm has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] has-[>svg]:gap-x-3 [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 [&>svg]:text-current",info:"border-l-4 border-l-primary bg-card text-card-foreground [&>svg]:text-primary",success:"border-l-4 border-l-emerald-500 bg-card text-card-foreground [&>svg]:text-emerald-500",warning:"border-l-4 border-l-amber-500 bg-card text-card-foreground [&>svg]:text-amber-500",error:"border-l-4 border-l-destructive bg-card text-card-foreground [&>svg]:text-destructive"}},defaultVariants:{variant:"default"}});function n_(e){var t=e.className,r=e.variant,n=nM(e,["className","variant"]);return(0,f.jsx)("div",nR({"data-slot":"alert",role:"alert",className:(0,g.cn)(nI({variant:r}),t)},n))}function nL(e){var t=e.className,r=nM(e,["className"]);return(0,f.jsx)("div",nR({"data-slot":"alert-title",className:(0,g.cn)("col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",t)},r))}function nF(e){var t=e.className,r=nM(e,["className"]);return(0,f.jsx)("div",nR({"data-slot":"alert-description",className:(0,g.cn)("col-start-2 grid justify-items-start gap-1 text-sm text-muted-foreground [&_p]:leading-relaxed",t)},r))}var nB=r(822),nV=Object.defineProperty,nz=(e,t)=>nV(e,"name",{value:t,configurable:!0}),nW=0,n$=null;function nU(){p.useEffect(()=>{n$||(n$={start:nH(),end:nH()});let{start:e,end:t}=n$;return document.body.firstElementChild!==e&&document.body.insertAdjacentElement("afterbegin",e),document.body.lastElementChild!==t&&document.body.insertAdjacentElement("beforeend",t),nW++,()=>{1===nW&&(n$?.start.remove(),n$?.end.remove(),n$=null),nW=Math.max(0,nW-1)}},[])}function nH(){let e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}nz(function(e){return nU(),e.children},"FocusGuards"),nz(nU,"useFocusGuards"),nz(nH,"createFocusGuard");var nG=r(5823),nK="right-scroll-bar-position",nq="width-before-scroll-bar";function nY(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var nX="u">typeof window?p.useLayoutEffect:p.useEffect,nZ=new WeakMap,nQ=(void 0===a&&(a={}),(void 0===i&&(i=function(e){return e}),o=[],s=!1,l={read:function(){if(s)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return o.length?o[o.length-1]:null},useMedium:function(e){var t=i(e,s);return o.push(t),function(){o=o.filter(function(e){return e!==t})}},assignSyncMedium:function(e){for(s=!0;o.length;){var t=o;o=[],t.forEach(e)}o={push:function(t){return e(t)},filter:function(){return o}}},assignMedium:function(e){s=!0;var t=[];if(o.length){var r=o;o=[],r.forEach(e),t=o}var n=function(){var r=t;t=[],r.forEach(e)},a=function(){return Promise.resolve().then(n)};a(),o={push:function(e){t.push(e),a()},filter:function(e){return t=t.filter(e),o}}}}).options=(0,nG.Cl)({async:!0,ssr:!1},a),l),nJ=function(){},n0=p.forwardRef(function(e,t){var r,n,a,i,o=p.useRef(null),s=p.useState({onScrollCapture:nJ,onWheelCapture:nJ,onTouchMoveCapture:nJ}),l=s[0],u=s[1],c=e.forwardProps,d=e.children,f=e.className,h=e.removeScrollBar,m=e.enabled,y=e.shards,v=e.sideCar,g=e.noRelative,b=e.noIsolation,x=e.inert,w=e.allowPinchZoom,S=e.as,j=e.gapMode,O=(0,nG.Tt)(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),k=(r=[o,t],n=function(e){return r.forEach(function(t){return nY(t,e)})},(a=(0,p.useState)(function(){return{value:null,callback:n,facade:{get current(){return a.value},set current(value){var e=a.value;e!==value&&(a.value=value,a.callback(value,e))}}}})[0]).callback=n,i=a.facade,nX(function(){var e=nZ.get(i);if(e){var t=new Set(e),n=new Set(r),a=i.current;t.forEach(function(e){n.has(e)||nY(e,null)}),n.forEach(function(e){t.has(e)||nY(e,a)})}nZ.set(i,r)},[r]),i),E=(0,nG.Cl)((0,nG.Cl)({},O),l);return p.createElement(p.Fragment,null,m&&p.createElement(v,{sideCar:nQ,removeScrollBar:h,shards:y,noRelative:g,noIsolation:b,inert:x,setCallbacks:u,allowPinchZoom:!!w,lockRef:o,gapMode:j}),c?p.cloneElement(p.Children.only(d),(0,nG.Cl)((0,nG.Cl)({},E),{ref:k})):p.createElement(void 0===S?"div":S,(0,nG.Cl)({},E,{className:f,ref:k}),d))});n0.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},n0.classNames={fullWidth:nq,zeroRight:nK};var n1=function(e){var t=e.sideCar,r=(0,nG.Tt)(e,["sideCar"]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw Error("Sidecar medium not found");return p.createElement(n,(0,nG.Cl)({},r))};n1.isSideCarExport=!0;var n2=function(){var e=0,t=null;return{add:function(n){if(0==e&&(t=function(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=d||r.nc;return t&&e.setAttribute("nonce",t),e}())){var a,i;(a=t).styleSheet?a.styleSheet.cssText=n:a.appendChild(document.createTextNode(n)),i=t,(document.head||document.getElementsByTagName("head")[0]).appendChild(i)}e++},remove:function(){--e||!t||(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},n3=function(){var e=n2();return function(t,r){p.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},n4=function(){var e=n3();return function(t){return e(t.styles,t.dynamic),null}},n5={left:0,top:0,right:0,gap:0},n6=function(e){return parseInt(e||"",10)||0},n8=function(e){var t=window.getComputedStyle(document.body),r=t["padding"===e?"paddingLeft":"marginLeft"],n=t["padding"===e?"paddingTop":"marginTop"],a=t["padding"===e?"paddingRight":"marginRight"];return[n6(r),n6(n),n6(a)]},n9=function(e){if(void 0===e&&(e="margin"),"u"<typeof window)return n5;var t=n8(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},n7=n4(),ae="data-scroll-locked",at=function(e,t,r,n){var a=e.left,i=e.top,o=e.right,s=e.gap;return void 0===r&&(r="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(n,";\n padding-right: ").concat(s,"px ").concat(n,";\n }\n body[").concat(ae,"] {\n overflow: hidden ").concat(n,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(n,";"),"margin"===r&&"\n padding-left: ".concat(a,"px;\n padding-top: ").concat(i,"px;\n padding-right: ").concat(o,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(s,"px ").concat(n,";\n "),"padding"===r&&"padding-right: ".concat(s,"px ").concat(n,";")].filter(Boolean).join(""),"\n }\n \n .").concat(nK," {\n right: ").concat(s,"px ").concat(n,";\n }\n \n .").concat(nq," {\n margin-right: ").concat(s,"px ").concat(n,";\n }\n \n .").concat(nK," .").concat(nK," {\n right: 0 ").concat(n,";\n }\n \n .").concat(nq," .").concat(nq," {\n margin-right: 0 ").concat(n,";\n }\n \n body[").concat(ae,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(s,"px;\n }\n")},ar=function(){var e=parseInt(document.body.getAttribute(ae)||"0",10);return isFinite(e)?e:0},an=function(){p.useEffect(function(){return document.body.setAttribute(ae,(ar()+1).toString()),function(){var e=ar()-1;e<=0?document.body.removeAttribute(ae):document.body.setAttribute(ae,e.toString())}},[])},aa=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,a=void 0===n?"margin":n;an();var i=p.useMemo(function(){return n9(a)},[a]);return p.createElement(n7,{styles:at(i,!t,a,r?"":"!important")})},ai=!1;if("u">typeof window)try{var ao=Object.defineProperty({},"passive",{get:function(){return ai=!0,!0}});window.addEventListener("test",ao,ao),window.removeEventListener("test",ao,ao)}catch(e){ai=!1}var as=!!ai&&{passive:!1};function al(e,t){return null!=t&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](e):e instanceof t}var au=function(e,t){if(!al(e,Element))return!1;var r=window.getComputedStyle(e);return"hidden"!==r[t]&&(r.overflowY!==r.overflowX||"TEXTAREA"===e.tagName||"visible"!==r[t])},ac=function(e,t){var r=t.ownerDocument,n=t;do{if("u">typeof ShadowRoot&&al(n,ShadowRoot)&&(n=n.host),ad(e,n)){var a=af(e,n);if(a[1]>a[2])return!0}n=n.parentNode}while(n&&n!==r.body);return!1},ad=function(e,t){return"v"===e?au(t,"overflowY"):au(t,"overflowX")},af=function(e,t){return"v"===e?[t.scrollTop,t.scrollHeight,t.clientHeight]:[t.scrollLeft,t.scrollWidth,t.clientWidth]},ap=function(e,t,r,n,a){var i,o=(i=window.getComputedStyle(t).direction,"h"===e&&"rtl"===i?-1:1),s=o*n,l=r.target,u=t.contains(l),c=!1,d=s>0,f=0,p=0;do{if(!l)break;var h=af(e,l),m=h[0],y=h[1]-h[2]-o*m;(m||y)&&ad(e,l)&&(f+=y,p+=m);var v=l.parentNode;l=v&&v.nodeType===Node.DOCUMENT_FRAGMENT_NODE?v.host:v}while(!u&&l!==document.body||u&&(t.contains(l)||t===l));return d&&(a&&1>Math.abs(f)||!a&&s>f)?c=!0:!d&&(a&&1>Math.abs(p)||!a&&-s>p)&&(c=!0),c},ah=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},am=function(e){return[e.deltaX,e.deltaY]},ay=function(e){return e&&"current"in e?e.current:e},av=0,ag=[];let ab=(u=function(e){var t=p.useRef([]),r=p.useRef([0,0]),n=p.useRef(),a=p.useState(av++)[0],i=p.useState(n4)[0],o=p.useRef(e);p.useEffect(function(){o.current=e},[e]),p.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(a));var t=(0,nG.fX)([e.lockRef.current],(e.shards||[]).map(ay),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add("allow-interactivity-".concat(a))}),function(){document.body.classList.remove("block-interactivity-".concat(a)),t.forEach(function(e){return e.classList.remove("allow-interactivity-".concat(a))})}}},[e.inert,e.lockRef.current,e.shards]);var s=p.useCallback(function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!o.current.allowPinchZoom;var a,i=ah(e),s=r.current,l="deltaX"in e?e.deltaX:s[0]-i[0],u="deltaY"in e?e.deltaY:s[1]-i[1],c=e.target,d=Math.abs(l)>Math.abs(u)?"h":"v";if("touches"in e&&"h"===d&&"range"===c.type)return!1;var f=window.getSelection(),p=f&&f.anchorNode;if(p&&(p===c||p.contains(c)))return!1;var h=ac(d,c);if(!h)return!0;if(h?a=d:(a="v"===d?"h":"v",h=ac(d,c)),!h)return!1;if(!n.current&&"changedTouches"in e&&(l||u)&&(n.current=a),!a)return!0;var m=n.current||a;return ap(m,t,e,"h"===m?l:u,!0)},[]),l=p.useCallback(function(e){if(ag.length&&ag[ag.length-1]===i){var r="deltaY"in e?am(e):ah(e),n=t.current.filter(function(t){var n;return t.name===e.type&&(t.target===e.target||e.target===t.shadowParent)&&(n=t.delta,n[0]===r[0]&&n[1]===r[1])})[0];if(n&&n.should){e.cancelable&&e.preventDefault();return}if(!n){var a=(o.current.shards||[]).map(ay).filter(Boolean).filter(function(t){return t.contains(e.target)});(a.length>0?s(e,a[0]):!o.current.noIsolation)&&e.cancelable&&e.preventDefault()}}},[]),u=p.useCallback(function(e,r,n,a){var i={name:e,delta:r,target:n,should:a,shadowParent:function(e){for(var t,r,n=null;null!==e;)t=e,(null!=(r=ShadowRoot)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](t):t instanceof r)&&(n=e.host,e=e.host),e=e.parentNode;return n}(n)};t.current.push(i),setTimeout(function(){t.current=t.current.filter(function(e){return e!==i})},1)},[]),c=p.useCallback(function(e){r.current=ah(e),n.current=void 0},[]),d=p.useCallback(function(t){u(t.type,am(t),t.target,s(t,e.lockRef.current))},[]),f=p.useCallback(function(t){u(t.type,ah(t),t.target,s(t,e.lockRef.current))},[]);p.useEffect(function(){return ag.push(i),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener("wheel",l,as),document.addEventListener("touchmove",l,as),document.addEventListener("touchstart",c,as),function(){ag=ag.filter(function(e){return e!==i}),document.removeEventListener("wheel",l,as),document.removeEventListener("touchmove",l,as),document.removeEventListener("touchstart",c,as)}},[]);var h=e.removeScrollBar,m=e.inert;return p.createElement(p.Fragment,null,m?p.createElement(i,{styles:"\n .block-interactivity-".concat(a," {pointer-events: none;}\n .allow-interactivity-").concat(a," {pointer-events: all;}\n")}):null,h?p.createElement(aa,{noRelative:e.noRelative,gapMode:e.gapMode}):null)},nQ.useMedium(u),n1);var ax=p.forwardRef(function(e,t){return p.createElement(n0,(0,nG.Cl)({},e,{ref:t,sideCar:ab}))});ax.classNames=n0.classNames;var aw=new WeakMap,aS=new WeakMap,aj={},aO=0,ak=function(e){return e&&(e.host||ak(e.parentNode))},aE=function(e,t,r,n){var a=(Array.isArray(e)?e:[e]).map(function(e){if(t.contains(e))return e;var r=ak(e);return r&&t.contains(r)?r:(console.error("aria-hidden",e,"in not contained inside",t,". Doing nothing"),null)}).filter(function(e){return!!e});aj[r]||(aj[r]=new WeakMap);var i=aj[r],o=[],s=new Set,l=new Set(a),u=function(e){!e||s.has(e)||(s.add(e),u(e.parentNode))};a.forEach(u);var c=function(e){!e||l.has(e)||Array.prototype.forEach.call(e.children,function(e){if(s.has(e))c(e);else try{var t=e.getAttribute(n),a=null!==t&&"false"!==t,l=(aw.get(e)||0)+1,u=(i.get(e)||0)+1;aw.set(e,l),i.set(e,u),o.push(e),1===l&&a&&aS.set(e,!0),1===u&&e.setAttribute(r,"true"),a||e.setAttribute(n,"true")}catch(t){console.error("aria-hidden: cannot operate on ",e,t)}})};return c(t),s.clear(),aO++,function(){o.forEach(function(e){var t=aw.get(e)-1,a=i.get(e)-1;aw.set(e,t),i.set(e,a),t||(aS.has(e)||e.removeAttribute(n),aS.delete(e)),a||e.removeAttribute(r)}),--aO||(aw=new WeakMap,aw=new WeakMap,aS=new WeakMap,aj={})}},aP=function(e,t,r){void 0===r&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),a=t||("u"<typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body);return a?(n.push.apply(n,Array.from(a.querySelectorAll("[aria-live], script"))),aE(n,a,r,"aria-hidden")):function(){return null}},aA=Object.defineProperty,aD=(e,t)=>aA(e,"name",{value:t,configurable:!0}),aC="Dialog",[aT,aN]=en(aC),[aR,aM]=aT(aC),aI=aD(e=>{let{__scopeDialog:t,children:r,open:n,defaultOpen:a,onOpenChange:i,modal:o=!0}=e,s=p.useRef(null),l=p.useRef(null),{nodes:u,registry:c}=eN(),[d,h]=rT({prop:n,defaultProp:a??!1,onChange:i,caller:aC}),[m,y]=p.useState(0),[v,g]=p.useState(0);return(0,f.jsx)(aR,{scope:t,triggerRef:s,contentRef:l,contentId:eq(),titleId:eq(),descriptionId:eq(),titlePresent:m>0,descriptionPresent:v>0,setTitleCount:y,setDescriptionCount:g,open:d,onOpenChange:h,onOpenToggle:p.useCallback(()=>h(e=>!e),[h]),modal:o,branchNodes:u,branchRegistry:c,children:r})},"Dialog"),a_="DialogPortal",[aL,aF]=aT(a_,{forceMount:void 0}),aB=aD(e=>{let{__scopeDialog:t,forceMount:r,children:n,container:a}=e,i=aM(a_,t);return(0,f.jsx)(aL,{scope:t,forceMount:r,children:p.Children.map(n,e=>(0,f.jsx)(rg,{present:r||i.open,children:(0,f.jsx)(rh,{asChild:!0,container:a,children:e})}))})},"DialogPortal"),aV="DialogOverlay",az=p.forwardRef(aD(function(e,t){let r=aF(aV,e.__scopeDialog),{forceMount:n=r.forceMount,...a}=e,i=aM(aV,e.__scopeDialog);return i.modal?(0,f.jsx)(rg,{present:n||i.open,children:(0,f.jsx)(a$,{...a,ref:t})}):null},"DialogOverlay")),aW=E("DialogOverlay.RemoveScroll"),a$=p.forwardRef(aD(function(e,t){let{__scopeDialog:r,...n}=e,a=aM(aV,r),i=j(t,eg());return(0,f.jsx)(ax,{as:aW,allowPinchZoom:!0,shards:p.useMemo(()=>[a.contentRef,...a.branchNodes.map(e=>({current:e}))],[a.contentRef,a.branchNodes]),children:(0,f.jsx)(es.div,{"data-state":aJ(a.open),...n,ref:i,style:{pointerEvents:"auto",...n.style}})})},"DialogOverlayImpl")),aU="DialogContent",aH=p.forwardRef(aD(function(e,t){let r=aF(aU,e.__scopeDialog),{forceMount:n=r.forceMount,...a}=e,i=aM(aU,e.__scopeDialog);return(0,f.jsx)(rg,{present:n||i.open,children:i.modal?(0,f.jsx)(aG,{...a,ref:t}):(0,f.jsx)(aK,{...a,ref:t})})},"DialogContent")),aG=p.forwardRef(aD(function(e,t){let r=aM(aU,e.__scopeDialog),n=p.useRef(null),a=j(t,r.contentRef,n);return p.useEffect(()=>{let e=n.current;if(e)return aP(e)},[]),(0,f.jsx)(aq,{...e,ref:a,trapFocus:r.open,disableOutsidePointerEvents:r.open,onCloseAutoFocus:Q(e.onCloseAutoFocus,e=>{e.preventDefault(),r.triggerRef.current?.focus()}),onPointerDownOutside:Q(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,r=0===t.button&&!0===t.ctrlKey;(2===t.button||r)&&e.preventDefault()}),onFocusOutside:Q(e.onFocusOutside,e=>e.preventDefault())})},"DialogContentModal")),aK=p.forwardRef(aD(function(e,t){let r=aM(aU,e.__scopeDialog),n=p.useRef(!1),a=p.useRef(!1);return(0,f.jsx)(aq,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(n.current||r.triggerRef.current?.focus(),t.preventDefault()),n.current=!1,a.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(n.current=!0,"pointerdown"===t.detail.originalEvent.type&&(a.current=!0));let i=t.target;r.triggerRef.current?.contains(i)&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&a.current&&t.preventDefault()}})},"DialogContentNonModal")),aq=p.forwardRef(aD(function(e,t){let{__scopeDialog:r,trapFocus:n,onOpenAutoFocus:a,onCloseAutoFocus:i,"aria-describedby":o,children:s,...l}=e,u=aM(aU,r);return nU(),(0,f.jsx)(eT,{registry:u.branchRegistry,children:(0,f.jsx)(eD,{asChild:!0,loop:!0,trapped:n,branches:u.branchNodes,onMountAutoFocus:a,onUnmountAutoFocus:i,children:(0,f.jsx)(ev,{role:"dialog",id:u.contentId,"aria-labelledby":u.titlePresent?u.titleId:void 0,"aria-describedby":u.descriptionPresent?aQ(o,u.descriptionId):o,"data-state":aJ(u.open),...l,ref:t,deferPointerDownOutside:!0,onDismiss:()=>u.onOpenChange(!1),children:s})})})},"DialogContentImpl")),aY=p.forwardRef(aD(function(e,t){let{__scopeDialog:r,...n}=e,a=aM("DialogTitle",r),{setTitleCount:i}=a;return eu(()=>(i(e=>e+1),()=>i(e=>e-1)),[i]),(0,f.jsx)(es.h2,{id:a.titleId,...n,ref:t})},"DialogTitle")),aX=p.forwardRef(aD(function(e,t){let{__scopeDialog:r,...n}=e,a=aM("DialogDescription",r),{setDescriptionCount:i}=a;return eu(()=>(i(e=>e+1),()=>i(e=>e-1)),[i]),(0,f.jsx)(es.p,{id:a.descriptionId,...n,ref:t})},"DialogDescription")),aZ=p.forwardRef(aD(function(e,t){let{__scopeDialog:r,...n}=e,a=aM("DialogClose",r);return(0,f.jsx)(es.button,{type:"button",...n,ref:t,onClick:Q(e.onClick,()=>a.onOpenChange(!1))})},"DialogClose"));function aQ(...e){let t=new Set;for(let r of e)if("string"==typeof r)for(let e of String(r).trim().split(/\s+/))e&&t.add(e);return t.size>0?Array.from(t).join(" "):void 0}function aJ(e){return e?"open":"closed"}function a0(){return(a0=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e}).apply(this,arguments)}function a1(e){if(null==e)throw TypeError("Cannot destructure "+e);return e}function a2(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function a3(e,t){return t=null!=t?t:{},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e}function a4(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function a5(e){a1(e);var t=a0({},e);return(0,f.jsx)(aI,a2({"data-slot":"dialog"},t))}function a6(e){a1(e);var t=a0({},e);return(0,f.jsx)(aB,a2({"data-slot":"dialog-portal"},t))}function a8(e){var t=e.className,r=a4(e,["className"]);return(0,f.jsx)(az,a2({"data-slot":"dialog-overlay",className:(0,g.cn)("fixed inset-0 z-50 bg-black/50 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:animate-in data-[state=open]:fade-in-0",t)},r))}function a9(e){var t=e.className,r=e.children,n=e.showCloseButton,a=a4(e,["className","children","showCloseButton"]);return(0,f.jsxs)(a6,{"data-slot":"dialog-portal",children:[(0,f.jsx)(a8,{}),(0,f.jsxs)(aH,a3(a2({"data-slot":"dialog-content",className:(0,g.cn)("fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border bg-background p-6 shadow-lg duration-200 outline-none data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[state=open]:animate-in data-[state=open]:fade-in-0 data-[state=open]:zoom-in-95 sm:max-w-lg",t)},a),{children:[r,(void 0===n||n)&&(0,f.jsxs)(aZ,{"data-slot":"dialog-close",className:"absolute top-4 right-4 rounded-xs opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:ring-2 focus:ring-ring focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",children:[(0,f.jsx)(nB.A,{}),(0,f.jsx)("span",{className:"sr-only",children:"Close"})]})]}))]})}function a7(e){var t=e.className,r=a4(e,["className"]);return(0,f.jsx)("div",a2({"data-slot":"dialog-header",className:(0,g.cn)("flex flex-col gap-2 text-center sm:text-left",t)},r))}function ie(e){var t=e.className,r=e.showCloseButton,n=e.children,a=a4(e,["className","showCloseButton","children"]);return(0,f.jsxs)("div",a3(a2({"data-slot":"dialog-footer",className:(0,g.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",t)},a),{children:[n,void 0!==r&&r&&(0,f.jsx)(aZ,{asChild:!0,children:(0,f.jsx)(q,{variant:"outline",children:"Close"})})]}))}function it(e){var t=e.className,r=a4(e,["className"]);return(0,f.jsx)(aY,a2({"data-slot":"dialog-title",className:(0,g.cn)("text-lg leading-none font-semibold",t)},r))}function ir(e){var t=e.className,r=a4(e,["className"]);return(0,f.jsx)(aX,a2({"data-slot":"dialog-description",className:(0,g.cn)("text-sm text-muted-foreground",t)},r))}function ia(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function ii(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function io(e){var t,r,n=e.title,a=e.label,i=e.onClose,o=e.closeLabel,s=void 0===o?"Close":o,l=e.className,u=e.children,c=ii(e,["title","label","onClose","closeLabel","className","children"]);return(0,f.jsxs)("div",(t=ia({"data-slot":"modal-header",className:(0,g.cn)("relative flex shrink-0 flex-col gap-1 border-b px-6 py-4 pr-14 text-left",l)},c),r=r={children:[a?(0,f.jsx)("p",{className:"text-xs text-muted-foreground",children:a}):null,n?(0,f.jsx)("h2",{className:"text-lg leading-snug font-semibold",children:n}):null,u,i?(0,f.jsx)("button",{type:"button",onClick:i,"aria-label":s,title:s,className:"absolute top-3 right-3 inline-flex size-8 items-center justify-center rounded-md text-muted-foreground outline-none hover:bg-accent hover:text-accent-foreground focus-visible:ring-[3px] focus-visible:ring-ring/50",children:(0,f.jsx)(nB.A,{className:"size-4","aria-hidden":"true"})}):null]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))}function is(e){var t=e.className,r=ii(e,["className"]);return(0,f.jsx)("div",ia({"data-slot":"modal-body",className:(0,g.cn)("min-h-0 flex-1 overflow-y-auto px-6 py-4",t)},r))}function il(e){var t=e.className,r=ii(e,["className"]);return(0,f.jsx)("div",ia({"data-slot":"modal-footer",className:(0,g.cn)("flex shrink-0 flex-wrap items-center justify-end gap-2 border-t px-6 py-4",t)},r))}aD(aQ,"concatAriaDescribedby"),aD(aJ,"getState"),v("group/tabs-list inline-flex w-fit items-center justify-center rounded-lg p-[3px] text-muted-foreground group-data-[orientation=horizontal]/tabs:h-9 group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col data-[variant=line]:rounded-none",{variants:{variant:{default:"bg-muted",line:"gap-1 bg-transparent"}},defaultVariants:{variant:"default"}});var iu=r(8032),ic=(0,nk.A)("TriangleAlert",[["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",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),id=(0,nk.A)("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]),ip={info:iu.A,success:nA.A,warning:ic,error:id};function ih(e){var t,r,n=e.kind,a=e.title,i=e.subtitle,o=e.actionLabel,s=e.onAction,l=e.onClose,u=e.closeLabel,c=void 0===u?"Close":u,d=e.statusLabel,h=e.className,m=function(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}(e,["kind","title","subtitle","actionLabel","onAction","onClose","closeLabel","statusLabel","className"]),y="error"===n?"error":"success"===n?"success":"warning"===n||"warning-alt"===n?"warning":"info",v=p.useId(),b=!!(o||l),x=ip[y];return(0,f.jsxs)(n_,(t=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({variant:y,"data-kind":y,role:b?"alertdialog":"alert","aria-labelledby":a?v:void 0,"aria-label":a?void 0:d,className:(0,g.cn)("grid-cols-[auto_1fr_auto] items-center gap-x-3",h)},m),r=r={children:[(0,f.jsx)(x,{"aria-hidden":"true"}),(0,f.jsxs)("div",{className:"col-start-2 min-w-0",children:[a?(0,f.jsx)(nL,{id:v,children:a}):null,i?(0,f.jsx)(nF,{children:i}):null]}),(0,f.jsxs)("div",{className:"col-start-3 flex items-center gap-1",children:[o?(0,f.jsx)(q,{type:"button",variant:"ghost",size:"sm",onClick:s,children:o}):null,l?(0,f.jsx)(q,{type:"button",variant:"ghost",size:"icon-sm",onClick:l,"aria-label":c,title:c,children:(0,f.jsx)(nB.A,{"aria-hidden":"true"})}):null]})]},Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(r)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}),t))}function im(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function iy(e,t){if(null==e)return{};var r,n,a,i={};if("u">typeof Reflect&&Reflect.ownKeys){for(a=0,r=Reflect.ownKeys(Object(e));a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}if(i=function(e,t){if(null==e)return{};var r,n,a={},i=Object.getOwnPropertyNames(e);for(n=0;n<i.length;n++)r=i[n],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(a[r]=e[r]);return a}(e,t),Object.getOwnPropertySymbols)for(a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)n=r[a],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n]);return i}function iv(e){var t=e.className,r=iy(e,["className"]);return(0,f.jsx)("header",im({"data-slot":"app-header",className:(0,g.cn)("relative flex h-12 items-center bg-card text-foreground",t)},r))}function ig(e){var t=e.className,r=iy(e,["className"]);return(0,f.jsx)("span",im({"data-slot":"app-header-name",className:(0,g.cn)("flex h-12 items-center truncate px-4 text-sm font-semibold",t)},r))}function ib(e){var t=e.className,r=iy(e,["className"]);return(0,f.jsx)("div",im({"data-slot":"app-header-bar",className:(0,g.cn)("flex h-full items-center",t)},r))}function ix(e){var t=e.className,r=e.type,n=e["aria-label"],a=e.title,i=iy(e,["className","type","aria-label","title"]);return(0,f.jsx)("button",im({"data-slot":"app-header-action",type:void 0===r?"button":r,"aria-label":n,title:null!=a?a:n,className:(0,g.cn)("inline-flex size-12 shrink-0 cursor-pointer items-center justify-center border-0 bg-transparent text-current outline-none transition-colors hover:bg-accent hover:text-accent-foreground focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-inset [&_svg]:size-4",t)},i))}},9663(e){function t(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}!function(){"use strict";var r={}.hasOwnProperty;function n(){for(var e="",i=0;i<arguments.length;i++){var o=arguments[i];o&&(e=a(e,function(e){if("string"==typeof e||"number"==typeof e)return e;if((void 0===e?"undefined":t(e))!=="object")return"";if(Array.isArray(e))return n.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var i="";for(var o in e)r.call(e,o)&&e[o]&&(i=a(i,o));return i}(o)))}return e}function a(e,t){return t?e?e+" "+t:e+t:e}e.exports?(n.default=n,e.exports=n):"function"==typeof define&&"object"===t(define.amd)&&define.amd?define("classnames",[],function(){return n}):window.classNames=n}()},5923(e,t,r){"use strict";r.d(t,{Ip:()=>f,_l:()=>d,gX:()=>c,ng:()=>u});var n=r(2974),a=r(240),i=r(2298),o=r(345),s=r(9405);function l(e){let t,r="object"==typeof e[0]?e.shift():new(0,o.FG);if("string"==typeof e[0])t=e.shift();else{let e=r.getEras();t=e[e.length-1]}return[r,t,e.shift(),e.shift(),e.shift()]}class u{#t;constructor(...e){let[t,r,a,i,o]=l(e);this.calendar=t,this.era=r,this.year=a,this.month=i,this.day=o,(0,n.AU)(this)}copy(){return this.era?new u(this.calendar,this.era,this.year,this.month,this.day):new u(this.calendar,this.year,this.month,this.day)}add(e){return(0,n.WQ)(this,e)}subtract(e){return(0,n.Re)(this,e)}set(e){return(0,n.hZ)(this,e)}cycle(e,t,r){return(0,n.xy)(this,e,t,r)}toDate(e){return(0,s.ay)(this,e)}toString(){return(0,i.$T)(this)}compare(e){return(0,a.SE)(this,e)}}class c{#t;constructor(e=0,t=0,r=0,a=0){this.hour=e,this.minute=t,this.second=r,this.millisecond=a,(0,n.Rb)(this)}copy(){return new c(this.hour,this.minute,this.second,this.millisecond)}add(e){return(0,n.tY)(this,e)}subtract(e){return(0,n.YP)(this,e)}set(e){return(0,n.ib)(this,e)}cycle(e,t,r){return(0,n.gt)(this,e,t,r)}toString(){return(0,i.ot)(this)}compare(e){return(0,a.Nu)(this,e)}}class d{#t;constructor(...e){let[t,r,a,i,o]=l(e);this.calendar=t,this.era=r,this.year=a,this.month=i,this.day=o,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,(0,n.AU)(this)}copy(){return this.era?new d(this.calendar,this.era,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond):new d(this.calendar,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond)}add(e){return(0,n.WQ)(this,e)}subtract(e){return(0,n.Re)(this,e)}set(e){return(0,n.hZ)((0,n.ib)(this,e),e)}cycle(e,t,r){switch(e){case"era":case"year":case"month":case"day":return(0,n.xy)(this,e,t,r);default:return(0,n.gt)(this,e,t,r)}}toDate(e,t){return(0,s.ay)(this,e,t)}toString(){return(0,i.qk)(this)}compare(e){let t=(0,a.SE)(this,e);return 0===t?(0,a.Nu)(this,(0,s.tR)(e)):t}}class f{#t;constructor(...e){let[t,r,a,i,o]=l(e),s=e.shift(),u=e.shift();this.calendar=t,this.era=r,this.year=a,this.month=i,this.day=o,this.timeZone=s,this.offset=u,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,(0,n.AU)(this)}copy(){return this.era?new f(this.calendar,this.era,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond):new f(this.calendar,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond)}add(e){return(0,n.E0)(this,e)}subtract(e){return(0,n.d_)(this,e)}set(e,t){return(0,n.D8)(this,e,t)}cycle(e,t,r){return(0,n.XH)(this,e,t,r)}toDate(){return(0,s.cd)(this)}toString(){return(0,i.e6)(this)}toAbsoluteString(){return this.toDate().toISOString()}compare(e){return this.toDate().getTime()-(0,s.uB)(e,this.timeZone).toDate().getTime()}}},345(e,t,r){"use strict";r.d(t,{FG:()=>c,LA:()=>s,U_:()=>o,f5:()=>l,rG:()=>i});var n=r(5923),a=r(5504);function i(e,t,r,n){let a=(t=s(e,t))-1,i=-2;return r<=2?i=0:o(t)&&(i=-1),1721425+365*a+Math.floor(a/4)-Math.floor(a/100)+Math.floor(a/400)+Math.floor((367*r-362)/12+i+n)}function o(e){return e%4==0&&(e%100!=0||e%400==0)}function s(e,t){return"BC"===e?1-t:t}function l(e){let t="AD";return e<=0&&(t="BC",e=1-e),[t,e]}let u={standard:[31,28,31,30,31,30,31,31,30,31,30,31],leapyear:[31,29,31,30,31,30,31,31,30,31,30,31]};class c{fromJulianDay(e){let t=e-1721426,r=Math.floor(t/146097),s=(0,a.z)(t,146097),u=Math.floor(s/36524),c=(0,a.z)(s,36524),d=Math.floor(c/1461),f=Math.floor((0,a.z)(c,1461)/365),[p,h]=l(400*r+100*u+4*d+f+ +(4!==u&&4!==f)),m=e-i(p,h,1,1),y=2;e<i(p,h,3,1)?y=0:o(h)&&(y=1);let v=Math.floor(((m+y)*12+373)/367),g=e-i(p,h,v,1)+1;return new(0,n.ng)(p,h,v,g)}toJulianDay(e){return i(e.era,e.year,e.month,e.day)}getDaysInMonth(e){return u[o(e.year)?"leapyear":"standard"][e.month-1]}getMonthsInYear(e){return 12}getDaysInYear(e){return o(e.year)?366:365}getMaximumMonthsInYear(){return 12}getMaximumDaysInMonth(){return 31}getYearsInEra(e){return 9999}getEras(){return["BC","AD"]}isInverseEra(e){return"BC"===e.era}balanceDate(e){e.year<=0&&(e.era="BC"===e.era?"AD":"BC",e.year=1-e.year)}constructor(){this.identifier="gregory"}}},9405(e,t,r){"use strict";r.d(t,{Ou:()=>w,Tr:()=>f,Yd:()=>h,ay:()=>p,cd:()=>b,gw:()=>m,oU:()=>s,tR:()=>y,uB:()=>g,yP:()=>v});var n=r(5923),a=r(2974),i=r(345),o=r(240);function s(e){return e=v(e,new(0,i.FG)),l((0,i.LA)(e.era,e.year),e.month,e.day,e.hour,e.minute,e.second,e.millisecond)}function l(e,t,r,n,a,i,o){let s=new Date;return s.setUTCHours(n,a,i,o),s.setUTCFullYear(e,t-1,r),s.getTime()}function u(e,t){if("UTC"===t)return 0;if(e>0&&t===(0,o.Xj)()&&!(0,o.rS)())return -6e4*new Date(e).getTimezoneOffset();let{year:r,month:n,day:a,hour:i,minute:s,second:u}=d(e,t);return l(r,n,a,i,s,u,0)-1e3*Math.floor(e/1e3)}let c=new Map;function d(e,t){let r=c.get(t);r||(r=new Intl.DateTimeFormat("en-US",{timeZone:t,hour12:!1,era:"short",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),c.set(t,r));let n=r.formatToParts(new Date(e)),a={};for(let e of n)"literal"!==e.type&&(a[e.type]=e.value);return{year:"BC"===a.era||"B"===a.era?-a.year+1:+a.year,month:+a.month,day:+a.day,hour:"24"===a.hour?0:+a.hour,minute:+a.minute,second:+a.second}}function f(e,t,r="compatible"){var n,a,l;let c=y(e);if("UTC"===t)return s(c);if(t===(0,o.Xj)()&&"compatible"===r&&!(0,o.rS)()){c=v(c,new(0,i.FG));let e=new Date,t=(0,i.LA)(c.era,c.year);return e.setFullYear(t,c.month-1,c.day),e.setHours(c.hour,c.minute,c.second,c.millisecond),e.getTime()}let p=s(c),h=u(p-864e5,t),m=u(p+864e5,t),g=(n=c,((a=p-h)==(l=p-m)?[a]:[a,l]).filter(e=>{var r;let a;return r=n,a=d(e,t),r.year===a.year&&r.month===a.month&&r.day===a.day&&r.hour===a.hour&&r.minute===a.minute&&r.second===a.second}));if(1===g.length)return g[0];if(g.length>1)switch(r){case"compatible":case"earlier":return g[0];case"later":return g[g.length-1];case"reject":throw RangeError("Multiple possible absolute times found")}switch(r){case"earlier":return Math.min(p-h,p-m);case"compatible":case"later":return Math.max(p-h,p-m);case"reject":throw RangeError("No such absolute time found")}}function p(e,t,r="compatible"){return new Date(f(e,t,r))}function h(e,t){let r=u(e,t),a=new Date(e+r),i=a.getUTCFullYear(),o=a.getUTCMonth()+1,s=a.getUTCDate(),l=a.getUTCHours(),c=a.getUTCMinutes(),d=a.getUTCSeconds(),f=a.getUTCMilliseconds();return new(0,n.Ip)(i<1?"BC":"AD",i<1?-i+1:i,o,s,t,r,l,c,d,f)}function m(e){return new(0,n.ng)(e.calendar,e.era,e.year,e.month,e.day)}function y(e,t){let r=0,a=0,i=0,o=0;if("timeZone"in e)({hour:r,minute:a,second:i,millisecond:o}=e);else if("hour"in e&&!t)return e;return t&&({hour:r,minute:a,second:i,millisecond:o}=t),new(0,n._l)(e.calendar,e.era,e.year,e.month,e.day,r,a,i,o)}function v(e,t){if((0,o.Jg)(e.calendar,t))return e;let r=t.fromJulianDay(e.calendar.toJulianDay(e)),n=e.copy();return n.calendar=t,n.era=r.era,n.year=r.year,n.month=r.month,n.day=r.day,(0,a.AU)(n),n}function g(e,t,r){return e instanceof n.Ip?e.timeZone===t?e:x(e,t):h(f(e,t,r),t)}function b(e){return new Date(s(e)-e.offset)}function x(e,t){return v(h(s(e)-e.offset,t),e.calendar)}function w(e){return x(e,(0,o.Xj)())}},227(e,t,r){"use strict";let n,a;r.d(t,{d:()=>X});var i=r(5923),o=r(345);class s extends o.FG{fromJulianDay(e){let t=super.fromJulianDay(e),r=(0,o.LA)(t.era,t.year);return new(0,i.ng)(this,r- -543,t.month,t.day)}toJulianDay(e){return super.toJulianDay(l(e))}getEras(){return["BE"]}getDaysInMonth(e){return super.getDaysInMonth(l(e))}balanceDate(){}constructor(...e){super(...e),this.identifier="buddhist"}}function l(e){let[t,r]=(0,o.f5)(e.year+-543);return new(0,i.ng)(t,r,e.month,e.day)}function u(e,t,r,n){return e+365*t+Math.floor(t/4)+30*(r-1)+n-1}function c(e,t){let r=Math.floor(4*(t-e)/1461);t>=u(e,r+1,1,1)&&r++;let n=1+Math.floor((t-u(e,r,1,1))/30),a=t+1-u(e,r,n,1);return[r,n,a]}function d(e){return Math.floor(e%4/3)}function f(e,t){return t%13!=0?30:d(e)+5}class p{fromJulianDay(e){let[t,r,n]=c(1723856,e),a="AM";return t<=0&&(a="AA",t+=5500),new(0,i.ng)(this,a,t,r,n)}toJulianDay(e){let t=e.year;return"AA"===e.era&&(t-=5500),u(1723856,t,e.month,e.day)}getDaysInMonth(e){return f(e.year,e.month)}getMonthsInYear(){return 13}getDaysInYear(e){return 365+d(e.year)}getMaximumMonthsInYear(){return 13}getMaximumDaysInMonth(){return 30}getYearsInEra(e){return"AA"===e.era?9999:9991}getEras(){return["AA","AM"]}constructor(){this.identifier="ethiopic"}}class h extends p{fromJulianDay(e){let[t,r,n]=c(1723856,e);return t+=5500,new(0,i.ng)(this,"AA",t,r,n)}getEras(){return["AA"]}getYearsInEra(){return 9999}constructor(...e){super(...e),this.identifier="ethioaa"}}class m extends p{fromJulianDay(e){let[t,r,n]=c(1824665,e),a="CE";return t<=0&&(a="BCE",t=1-t),new(0,i.ng)(this,a,t,r,n)}toJulianDay(e){let t=e.year;return"BCE"===e.era&&(t=1-t),u(1824665,t,e.month,e.day)}getDaysInMonth(e){let t=e.year;return"BCE"===e.era&&(t=1-t),f(t,e.month)}isInverseEra(e){return"BCE"===e.era}balanceDate(e){e.year<=0&&(e.era="BCE"===e.era?"CE":"BCE",e.year=1-e.year)}getEras(){return["BCE","CE"]}getYearsInEra(e){return"BCE"===e.era?9999:9715}constructor(...e){super(...e),this.identifier="coptic"}}var y=r(5504);let v=765433;function g(e){return 7>(0,y.z)(7*e+1,19)}function b(e){let t=Math.floor((235*e-234)/19),r=29*t+Math.floor((12084+13753*t)/25920);return 3>(0,y.z)(3*(r+1),7)&&(r+=1),r}function x(e){let t,r;return b(e)+(t=b(e-1),r=b(e),b(e+1)-r==356?2:+(r-t==382))}function w(e){return x(e+1)-x(e)}function S(e,t){if(t>=6&&!g(e)&&t++,4===t||7===t||9===t||11===t||13===t)return 29;let r=function(e){let t=w(e);switch(t>380&&(t-=30),t){case 353:return 0;case 354:return 1;case 355:return 2}}(e);return 2===t?2===r?30:29:3===t?0===r?29:30:6===t?30*!!g(e):30}class j{fromJulianDay(e){let t=e-347997,r=Math.floor((25920*t/v*19+234)/235)+1,n=x(r),a=Math.floor(t-n);for(;a<1;)a=Math.floor(t-(n=x(--r)));let o=1,s=0;for(;s<a;)s+=S(r,o),o++;let l=a-(s-=S(r,--o));return new(0,i.ng)(this,r,o,l)}toJulianDay(e){let t=x(e.year);for(let r=1;r<e.month;r++)t+=S(e.year,r);return t+e.day+347997}getDaysInMonth(e){return S(e.year,e.month)}getMonthsInYear(e){return g(e.year)?13:12}getDaysInYear(e){return w(e.year)}getMaximumMonthsInYear(){return 13}getMaximumDaysInMonth(){return 30}getYearsInEra(){return 9999}getEras(){return["AM"]}balanceYearMonth(e,t){t.year!==e.year&&(g(t.year)&&!g(e.year)&&t.month>6?e.month--:!g(t.year)&&g(e.year)&&t.month>6&&e.month++)}constructor(){this.identifier="hebrew"}}class O extends o.FG{fromJulianDay(e){let t,r,n,a=super.fromJulianDay(e),s=a.year-78,l=e-(0,o.rG)(a.era,a.year,1,1);if(l<80?(s--,l+=(t=(0,o.U_)(a.year-1)?31:30)+155+90+10):(t=(0,o.U_)(a.year)?31:30,l-=80),l<t)r=1,n=l+1;else{let e=l-t;e<155?(r=Math.floor(e/31)+2,n=e%31+1):(e-=155,r=Math.floor(e/30)+7,n=e%30+1)}return new(0,i.ng)(this,s,r,n)}toJulianDay(e){let t,r,n=e.year+78,[a,i]=(0,o.f5)(n);return((0,o.U_)(i)?(t=31,r=(0,o.rG)(a,i,3,21)):(t=30,r=(0,o.rG)(a,i,3,22)),1===e.month)?r+e.day-1:(r+=t+31*Math.min(e.month-2,5),e.month>=8&&(r+=(e.month-7)*30),r+=e.day-1)}getDaysInMonth(e){return 1===e.month&&(0,o.U_)(e.year+78)||e.month>=2&&e.month<=6?31:30}getYearsInEra(){return 9919}getEras(){return["saka"]}balanceDate(){}constructor(...e){super(...e),this.identifier="indian"}}function k(e,t,r,n){return n+Math.ceil(29.5*(r-1))+(t-1)*354+Math.floor((3+11*t)/30)+e-1}function E(e,t,r){let n=Math.floor((30*(r-t)+10646)/10631),a=Math.min(12,Math.ceil((r-(29+k(t,n,1,1)))/29.5)+1),o=r-k(t,n,a,1)+1;return new(0,i.ng)(e,n,a,o)}function P(e){return(14+11*e)%30<11}class A{fromJulianDay(e){return E(this,1948440,e)}toJulianDay(e){return k(1948440,e.year,e.month,e.day)}getDaysInMonth(e){let t=29+e.month%2;return 12===e.month&&P(e.year)&&t++,t}getMonthsInYear(){return 12}getDaysInYear(e){return P(e.year)?355:354}getMaximumMonthsInYear(){return 12}getMaximumDaysInMonth(){return 30}getYearsInEra(){return 9665}getEras(){return["AH"]}constructor(){this.identifier="islamic-civil"}}class D extends A{fromJulianDay(e){return E(this,1948439,e)}toJulianDay(e){return k(1948439,e.year,e.month,e.day)}constructor(...e){super(...e),this.identifier="islamic-tbla"}}function C(e){return 460322+a[e-1300]}function T(e,t){return(n[e-1300]&1<<11-(t-1))==0?29:30}function N(e,t){let r=C(e);for(let n=1;n<t;n++)r+=T(e,n);return r}function R(e){return a[e+1-1300]-a[e-1300]}class M extends A{constructor(){if(super(),this.identifier="islamic-umalqura",n||(n=new Uint16Array(Uint8Array.from(atob("qgpUDckO1AbqBmwDrQpVBakGkgepC9QF2gpcBS0NlQZKB1QLagutBa4ETwoXBYsGpQbVCtYCWwmdBE0KJg2VDawFtgm6AlsKKwWVCsoG6Qr0AnYJtgJWCcoKpAvSC9kF3AJtCU0FpQpSC6ULtAW2CVcFlwJLBaMGUgdlC2oFqworBZUMSg2lDcoF1gpXCasESwmlClILagt1BXYCtwhbBFUFqQW0BdoJ3QRuAjYJqgpUDbIN1QXaAlsJqwRVCkkLZAtxC7QFtQpVCiUNkg7JDtQG6QprCasEkwpJDaQNsg25CroEWworBZUKKgtVC1wFvQQ9Ah0JlQpKC1oLbQW2AjsJmwRVBqkGVAdqC2wFrQpVBSkLkgupC9QF2gpaBasKlQVJB2QHqgu1BbYCVgpNDiULUgtqC60FrgIvCZcESwalBqwG1gpdBZ0ETQoWDZUNqgW1BdoCWwmtBJUFygbkBuoK9QS2AlYJqgpUC9IL2QXqAm0JrQSVCkoLpQuyBbUJ1gSXCkcFkwZJB1ULagVrCisFiwpGDaMNygXWCtsEawJLCaUKUgtpC3UFdgG3CFsCKwVlBbQF2gntBG0BtgimClINqQ3UBdoKWwmrBFMGKQdiB6kLsgW1ClUFJQuSDckO0gbpCmsFqwRVCikNVA2qDbUJugQ7CpsETQqqCtUK2gJdCV4ELgqaDFUNsga5BroEXQotBZUKUguoC7QLuQXaAloJSgukDdEO6AZqC20FNQWVBkoNqA3UDdoGWwWdAisGFQtKC5ULqgWuCi4JjwwnBZUGqgbWCl0FnQI="),e=>e.charCodeAt(0)).buffer)),!a){a=new Uint32Array(301);let e=0;for(let t=1300;t<=1600;t++){a[t-1300]=e;for(let r=1;r<=12;r++)e+=T(t,r)}}}fromJulianDay(e){let t=e-1948440,r=C(1300),n=C(1600);if(t<r||t>n)return super.fromJulianDay(e);{let e=1299,r=1,n=1;for(;n>0;){n=t-C(++e)+1;let a=R(e);if(n===a){r=12;break}if(n<a){let t=T(e,r);for(r=1;n>t;)n-=t,t=T(e,++r);break}}return new(0,i.ng)(this,e,r,t-N(e,r)+1)}}toJulianDay(e){return e.year<1300||e.year>1600?super.toJulianDay(e):1948440+N(e.year,e.month)+(e.day-1)}getDaysInMonth(e){return e.year<1300||e.year>1600?super.getDaysInMonth(e):T(e.year,e.month)}getDaysInYear(e){return e.year<1300||e.year>1600?super.getDaysInYear(e):R(e.year)}}let I=[[1868,9,8],[1912,7,30],[1926,12,25],[1989,1,8],[2019,5,1]],L=[[1912,7,29],[1926,12,24],[1989,1,7],[2019,4,30]],F=[1867,1911,1925,1988,2018],B=["meiji","taisho","showa","heisei","reiwa"];function V(e){let t=I.findIndex(([t,r,n])=>!!(e.year<t)||e.year===t&&!!(e.month<r)||e.year===t&&e.month===r&&!!(e.day<n));return -1===t?I.length-1:0===t?0:t-1}function z(e){let t=F[B.indexOf(e.era)];if(!t)throw Error("Unknown era: "+e.era);return new(0,i.ng)(e.year+t,e.month,e.day)}class W extends o.FG{fromJulianDay(e){let t=super.fromJulianDay(e),r=V(t);return new(0,i.ng)(this,B[r],t.year-F[r],t.month,t.day)}toJulianDay(e){return super.toJulianDay(z(e))}balanceDate(e){let t=z(e),r=V(t);B[r]!==e.era&&(e.era=B[r],e.year=t.year-F[r]),this.constrainDate(e)}constrainDate(e){let t=B.indexOf(e.era),r=L[t];if(null!=r){let[n,a,i]=r,o=n-F[t];e.year=Math.max(1,Math.min(o,e.year)),e.year===o&&(e.month=Math.min(a,e.month),e.month===a&&(e.day=Math.min(i,e.day)))}if(1===e.year&&t>=0){let[,r,n]=I[t];e.month=Math.max(r,e.month),e.month===r&&(e.day=Math.max(n,e.day))}}getEras(){return B}getYearsInEra(e){let t=B.indexOf(e.era),r=I[t],n=I[t+1];if(null==n)return 9999-r[0]+1;let a=n[0]-r[0];return(e.month<n[1]||e.month===n[1]&&e.day<n[2])&&a++,a}getDaysInMonth(e){return super.getDaysInMonth(z(e))}getMinimumMonthInYear(e){let t=$(e);return t?t[1]:1}getMinimumDayInMonth(e){let t=$(e);return t&&e.month===t[1]?t[2]:1}constructor(...e){super(...e),this.identifier="japanese"}}function $(e){if(1===e.year)return I[B.indexOf(e.era)]}let U=[0,31,62,93,124,155,186,216,246,276,306,336];class H{fromJulianDay(e){let t=e-1948320,r=1+Math.floor((33*t+3)/12053),n=t-(365*(r-1)+Math.floor((8*r+21)/33)),a=n<216?Math.floor(n/31):Math.floor((n-6)/30),o=n-U[a]+1;return new(0,i.ng)(this,r,a+1,o)}toJulianDay(e){let t=1948319+365*(e.year-1)+Math.floor((8*e.year+21)/33);return t+=U[e.month-1],t+=e.day}getMonthsInYear(){return 12}getDaysInMonth(e){return e.month<=6?31:e.month<=11||8>(0,y.z)(25*e.year+11,33)?30:29}getMaximumMonthsInYear(){return 12}getMaximumDaysInMonth(){return 31}getEras(){return["AP"]}getYearsInEra(){return 9377}constructor(){this.identifier="persian"}}function G(e){return"minguo"===e.era?e.year+1911:1-e.year+1911}function K(e){let t=e-1911;return t>0?["minguo",t]:["before_minguo",1-t]}class q extends o.FG{fromJulianDay(e){let t=super.fromJulianDay(e),[r,n]=K((0,o.LA)(t.era,t.year));return new(0,i.ng)(this,r,n,t.month,t.day)}toJulianDay(e){return super.toJulianDay(Y(e))}getEras(){return["before_minguo","minguo"]}balanceDate(e){let[t,r]=K(G(e));e.era=t,e.year=r}isInverseEra(e){return"before_minguo"===e.era}getDaysInMonth(e){return super.getDaysInMonth(Y(e))}getYearsInEra(e){return"before_minguo"===e.era?9999:8088}constructor(...e){super(...e),this.identifier="roc"}}function Y(e){let[t,r]=(0,o.f5)(G(e));return new(0,i.ng)(t,r,e.month,e.day)}function X(e){switch(e){case"buddhist":return new s;case"ethiopic":return new p;case"ethioaa":return new h;case"coptic":return new m;case"hebrew":return new j;case"indian":return new O;case"islamic-civil":return new A;case"islamic-tbla":return new D;case"islamic-umalqura":return new M;case"japanese":return new W;case"persian":return new H;case"roc":return new q;default:return new(0,o.FG)}}},2974(e,t,r){"use strict";r.d(t,{AU:()=>u,D8:()=>k,E0:()=>S,Rb:()=>h,Re:()=>d,WQ:()=>i,XH:()=>O,YP:()=>g,d_:()=>j,gt:()=>x,hZ:()=>f,ib:()=>p,tY:()=>v,xy:()=>b});var n=r(9405),a=r(345);function i(e,t){let r=e.copy(),n="hour"in r?y(r,t):0;o(r,t.years||0),r.calendar.balanceYearMonth&&r.calendar.balanceYearMonth(r,e),r.month+=t.months||0,s(r),l(r),r.day+=7*(t.weeks||0),r.day+=t.days||0,r.day+=n,function(e){for(;e.day<1;)e.month--,s(e),e.day+=e.calendar.getDaysInMonth(e);for(;e.day>e.calendar.getDaysInMonth(e);)e.day-=e.calendar.getDaysInMonth(e),e.month++,s(e)}(r),r.calendar.balanceDate&&r.calendar.balanceDate(r),r.year<1&&(r.year=1,r.month=1,r.day=1);let a=r.calendar.getYearsInEra(r);if(r.year>a){let e=r.calendar.isInverseEra?.(r);r.year=a,r.month=e?1:r.calendar.getMonthsInYear(r),r.day=e?1:r.calendar.getDaysInMonth(r)}r.month<1&&(r.month=1,r.day=1);let i=r.calendar.getMonthsInYear(r);return r.month>i&&(r.month=i,r.day=r.calendar.getDaysInMonth(r)),r.day=Math.max(1,Math.min(r.calendar.getDaysInMonth(r),r.day)),r}function o(e,t){e.calendar.isInverseEra?.(e)&&(t=-t),e.year+=t}function s(e){for(;e.month<1;)o(e,-1),e.month+=e.calendar.getMonthsInYear(e);let t=0;for(;e.month>(t=e.calendar.getMonthsInYear(e));)e.month-=t,o(e,1)}function l(e){e.month=Math.max(1,Math.min(e.calendar.getMonthsInYear(e),e.month)),e.day=Math.max(1,Math.min(e.calendar.getDaysInMonth(e),e.day))}function u(e){e.calendar.constrainDate&&e.calendar.constrainDate(e),e.year=Math.max(1,Math.min(e.calendar.getYearsInEra(e),e.year)),l(e)}function c(e){let t={};for(let r in e)"number"==typeof e[r]&&(t[r]=-e[r]);return t}function d(e,t){return i(e,c(t))}function f(e,t){let r=e.copy();return null!=t.era&&(r.era=t.era),null!=t.year&&(r.year=t.year),null!=t.month&&(r.month=t.month),null!=t.day&&(r.day=t.day),u(r),r}function p(e,t){let r=e.copy();return null!=t.hour&&(r.hour=t.hour),null!=t.minute&&(r.minute=t.minute),null!=t.second&&(r.second=t.second),null!=t.millisecond&&(r.millisecond=t.millisecond),h(r),r}function h(e){e.millisecond=Math.max(0,Math.min(e.millisecond,999)),e.second=Math.max(0,Math.min(e.second,59)),e.minute=Math.max(0,Math.min(e.minute,59)),e.hour=Math.max(0,Math.min(e.hour,23))}function m(e,t){let r=e%t;return r<0&&(r+=t),r}function y(e,t){let r;return e.hour+=t.hours||0,e.minute+=t.minutes||0,e.second+=t.seconds||0,e.millisecond+=t.milliseconds||0,e.second+=Math.floor(e.millisecond/1e3),e.millisecond=m(e.millisecond,1e3),e.minute+=Math.floor(e.second/60),e.second=m(e.second,60),e.hour+=Math.floor(e.minute/60),e.minute=m(e.minute,60),r=Math.floor(e.hour/24),e.hour=m(e.hour,24),r}function v(e,t){let r=e.copy();return y(r,t),r}function g(e,t){return v(e,c(t))}function b(e,t,r,n){let a=e.copy();switch(t){case"era":{let t=e.calendar.getEras(),i=t.indexOf(e.era);if(i<0)throw Error("Invalid era: "+e.era);i=w(i,r,0,t.length-1,n?.round),a.era=t[i],u(a);break}case"year":a.calendar.isInverseEra?.(a)&&(r=-r),a.year=w(e.year,r,-1/0,9999,n?.round),a.year===-1/0&&(a.year=1),a.calendar.balanceYearMonth&&a.calendar.balanceYearMonth(a,e);break;case"month":a.month=w(e.month,r,1,e.calendar.getMonthsInYear(e),n?.round);break;case"day":a.day=w(e.day,r,1,e.calendar.getDaysInMonth(e),n?.round);break;default:throw Error("Unsupported field "+t)}return e.calendar.balanceDate&&e.calendar.balanceDate(a),u(a),a}function x(e,t,r,n){let a=e.copy();switch(t){case"hour":{let t=e.hour,i=0,o=23;if(n?.hourCycle===12){let e=t>=12;i=12*!!e,o=e?23:11}a.hour=w(t,r,i,o,n?.round);break}case"minute":a.minute=w(e.minute,r,0,59,n?.round);break;case"second":a.second=w(e.second,r,0,59,n?.round);break;case"millisecond":a.millisecond=w(e.millisecond,r,0,999,n?.round);break;default:throw Error("Unsupported field "+t)}return a}function w(e,t,r,n,a=!1){if(a){(e+=Math.sign(t))<r&&(e=n);let a=Math.abs(t);(e=t>0?Math.ceil(e/a)*a:Math.floor(e/a)*a)>n&&(e=r)}else(e+=t)<r?e=n-(r-e-1):e>n&&(e=r+(e-n-1));return e}function S(e,t){let r;if(null!=t.years&&0!==t.years||null!=t.months&&0!==t.months||null!=t.weeks&&0!==t.weeks||null!=t.days&&0!==t.days){let a=i((0,n.tR)(e),{years:t.years,months:t.months,weeks:t.weeks,days:t.days});r=(0,n.Tr)(a,e.timeZone)}else r=(0,n.oU)(e)-e.offset;r+=t.milliseconds||0,r+=1e3*(t.seconds||0),r+=6e4*(t.minutes||0),r+=36e5*(t.hours||0);let a=(0,n.Yd)(r,e.timeZone);return(0,n.yP)(a,e.calendar)}function j(e,t){return S(e,c(t))}function O(e,t,r,i){switch(t){case"hour":{let t=0,o=23;if(i?.hourCycle===12){let r=e.hour>=12;t=12*!!r,o=r?23:11}let s=(0,n.tR)(e),l=(0,n.yP)(p(s,{hour:t}),new(0,a.FG)),u=[(0,n.Tr)(l,e.timeZone,"earlier"),(0,n.Tr)(l,e.timeZone,"later")].filter(t=>(0,n.Yd)(t,e.timeZone).day===l.day)[0],c=(0,n.yP)(p(s,{hour:o}),new(0,a.FG)),d=[(0,n.Tr)(c,e.timeZone,"earlier"),(0,n.Tr)(c,e.timeZone,"later")].filter(t=>(0,n.Yd)(t,e.timeZone).day===c.day).pop(),f=(0,n.oU)(e)-e.offset,h=Math.floor(f/36e5),m=f%36e5;return f=36e5*w(h,r,Math.floor(u/36e5),Math.floor(d/36e5),i?.round)+m,(0,n.yP)((0,n.Yd)(f,e.timeZone),e.calendar)}case"minute":case"second":case"millisecond":return x(e,t,r,i);case"era":case"year":case"month":case"day":{let a=b((0,n.tR)(e),t,r,i),o=(0,n.Tr)(a,e.timeZone);return(0,n.yP)((0,n.Yd)(o,e.timeZone),e.calendar)}default:throw Error("Unsupported field "+t)}}function k(e,t,r){let a=(0,n.tR)(e),i=p(f(a,t),t);if(0===i.compare(a))return e;let o=(0,n.Tr)(i,e.timeZone,r);return(0,n.yP)((0,n.Yd)(o,e.timeZone),e.calendar)}},240(e,t,r){"use strict";r.d(t,{p9:()=>w,$I:()=>O,RZ:()=>P,tB:()=>f,rS:()=>b,kq:()=>j,Jg:()=>l,Py:()=>A,tF:()=>o,Xj:()=>g,Nu:()=>m,SJ:()=>d,SE:()=>h,ro:()=>i,D:()=>S,ZI:()=>D,Ec:()=>p,cK:()=>u,NV:()=>s,wH:()=>x});var n=r(9405);let a={"001":1,AD:1,AE:6,AF:6,AI:1,AL:1,AM:1,AN:1,AR:1,AT:1,AU:1,AX:1,AZ:1,BA:1,BE:1,BG:1,BH:6,BM:1,BN:1,BY:1,CH:1,CL:1,CM:1,CN:1,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DZ:6,EC:1,EE:1,EG:6,ES:1,FI:1,FJ:1,FO:1,FR:1,GB:1,GE:1,GF:1,GP:1,GR:1,HR:1,HU:1,IE:1,IQ:6,IR:6,IS:1,IT:1,JO:6,KG:1,KW:6,KZ:1,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MK:1,MN:1,MQ:1,MV:5,MY:1,NL:1,NO:1,NZ:1,OM:6,PL:1,QA:6,RE:1,RO:1,RS:1,RU:1,SD:6,SE:1,SI:1,SK:1,SM:1,SY:6,TJ:1,TM:1,TR:1,UA:1,UY:1,UZ:1,VA:1,VN:1,XK:1};function i(e,t){return t=(0,n.yP)(t,e.calendar),e.era===t.era&&e.year===t.year&&e.month===t.month&&e.day===t.day}function o(e,t){return t=(0,n.yP)(t,e.calendar),e=x(e),t=x(t),e.era===t.era&&e.year===t.year&&e.month===t.month}function s(e,t){return l(e.calendar,t.calendar)&&i(e,t)}function l(e,t){return e.isEqual?.(t)??t.isEqual?.(e)??e.identifier===t.identifier}function u(e,t){return i(e,p(t))}let c={sun:0,mon:1,tue:2,wed:3,thu:4,fri:5,sat:6};function d(e,t,r){let n=Math.ceil(e.calendar.toJulianDay(e)+1-(r?c[r]:function(e){let t=E.get(e);if(!t){if(Intl.Locale){let r=new Intl.Locale(e);if("getWeekInfo"in r&&(t=r.getWeekInfo()))return E.set(e,t),t.firstDay}let r=function(e){if(Intl.Locale){let t=k.get(e);return!t&&(t=new Intl.Locale(e).maximize().region)&&k.set(e,t),t}let t=e.split("-")[1];return"u"===t?void 0:t}(e);if(e.includes("-fw-")){let r=e.split("-fw-")[1].split("-")[0];t="mon"===r?{firstDay:1}:"tue"===r?{firstDay:2}:"wed"===r?{firstDay:3}:"thu"===r?{firstDay:4}:"fri"===r?{firstDay:5}:"sat"===r?{firstDay:6}:{firstDay:0}}else t=e.includes("-ca-iso8601")?{firstDay:1}:{firstDay:r&&a[r]||0};E.set(e,t)}return t.firstDay}(t)))%7;return n<0&&(n+=7),n}function f(e){return(0,n.Yd)(Date.now(),e)}function p(e){return(0,n.gw)(f(e))}function h(e,t){return e.calendar.toJulianDay(e)-t.calendar.toJulianDay(t)}function m(e,t){return y(e)-y(t)}function y(e){return 36e5*e.hour+6e4*e.minute+1e3*e.second+e.millisecond}let v=null;function g(){return null==v&&(v=new Intl.DateTimeFormat().resolvedOptions().timeZone),v}function b(){return!1}function x(e){return e.subtract({days:e.day-1})}function w(e){return e.add({days:e.calendar.getDaysInMonth(e)-e.day})}function S(e){return x(e.subtract({months:e.month-1}))}function j(e,t,r){let n=d(e,t,r);return e.subtract({days:n})}function O(e,t,r){return j(e,t,r).add({days:6})}let k=new Map,E=new Map;function P(e,t,r){let n=e.calendar.getDaysInMonth(e);return Math.ceil((d(x(e),t,r)+n)/7)}function A(e,t){return e&&t?0>=e.compare(t)?e:t:e||t}function D(e,t){return e&&t?e.compare(t)>=0?e:t:e||t}},2298(e,t,r){"use strict";r.d(t,{$T:()=>p,DP:()=>c,_U:()=>u,e6:()=>m,ot:()=>f,qk:()=>h});var n=r(5923),a=r(9405),i=r(345);let o=/^([+-]\d{6}|\d{4})-(\d{2})-(\d{2})$/,s=/^([+-]\d{6}|\d{4})-(\d{2})-(\d{2})(?:T(\d{2}))?(?::(\d{2}))?(?::(\d{2}))?(\.\d+)?$/,l=/^([+-]\d{6}|\d{4})-(\d{2})-(\d{2})(?:T(\d{2}))?(?::(\d{2}))?(?::(\d{2}))?(\.\d+)?(?:(?:([+-]\d{2})(?::?(\d{2}))?)|Z)$/;function u(e){let t=e.match(o);if(!t){if(l.test(e))throw Error(`Invalid ISO 8601 date string: ${e}. Use parseAbsolute() instead.`);throw Error("Invalid ISO 8601 date string: "+e)}let r=new(0,n.ng)(d(t[1],0,9999),d(t[2],1,12),1);return r.day=d(t[3],1,r.calendar.getDaysInMonth(r)),r}function c(e){let t=e.match(s);if(!t){if(l.test(e))throw Error(`Invalid ISO 8601 date time string: ${e}. Use parseAbsolute() instead.`);throw Error("Invalid ISO 8601 date time string: "+e)}let r=d(t[1],-9999,9999),a=new(0,n._l)(r<1?"BC":"AD",r<1?-r+1:r,d(t[2],1,12),1,t[4]?d(t[4],0,23):0,t[5]?d(t[5],0,59):0,t[6]?d(t[6],0,59):0,t[7]?1e3*d(t[7],0,1/0):0);return a.day=d(t[3],0,a.calendar.getDaysInMonth(a)),a}function d(e,t,r){let n=Number(e);if(n<t||n>r)throw RangeError(`Value out of range: ${t} <= ${n} <= ${r}`);return n}function f(e){return`${String(e.hour).padStart(2,"0")}:${String(e.minute).padStart(2,"0")}:${String(e.second).padStart(2,"0")}${e.millisecond?String(e.millisecond/1e3).slice(1):""}`}function p(e){let t,r=(0,a.yP)(e,new(0,i.FG));return t="BC"===r.era?1===r.year?"0000":"-"+String(Math.abs(1-r.year)).padStart(6,"00"):String(r.year).padStart(4,"0"),`${t}-${String(r.month).padStart(2,"0")}-${String(r.day).padStart(2,"0")}`}function h(e){return`${p(e)}T${f(e)}`}function m(e){var t;let r,n,a,i,o;return`${h(e)}${r=0>Math.sign(t=e.offset)?"-":"+",n=Math.floor((t=Math.abs(t))/36e5),a=Math.floor(t%36e5/6e4),i=Math.floor(t%36e5%6e4/1e3),o=`${r}${String(n).padStart(2,"0")}:${String(a).padStart(2,"0")}`,0!==i&&(o+=`:${String(i).padStart(2,"0")}`),o}[${e.timeZone}]`}},5504(e,t,r){"use strict";function n(e,t){return e-t*Math.floor(e/t)}r.d(t,{z:()=>n})},7064(e,t,r){"use strict";function n(){for(var e,t,r=0,n="",a=arguments.length;r<a;r++)(e=arguments[r])&&(t=function e(t){var r,n,a="";if("string"==typeof t||"number"==typeof t)a+=t;else if("object"==typeof t)if(Array.isArray(t)){var i=t.length;for(r=0;r<i;r++)t[r]&&(n=e(t[r]))&&(a&&(a+=" "),a+=n)}else for(n in t)t[n]&&(a&&(a+=" "),a+=n);return a}(e))&&(n&&(n+=" "),n+=t);return n}r.d(t,{$:()=>n,A:()=>a});let a=n},1400(e,t,r){"use strict";r.d(t,{A:()=>o});for(var n=new Uint8Array(16),a=[],i=0;i<256;++i)a.push((i+256).toString(16).slice(1));let o=function(e,t,r){return t||e||!crypto.randomUUID?function(e,t,r){var i,o,s,l=null!=(i=null!=(o=(e=e||{}).random)?o:null==(s=e.rng)?void 0:s.call(e))?i:crypto.getRandomValues(n);if(l.length<16)throw Error("Random bytes length must be >= 16");if(l[6]=15&l[6]|64,l[8]=63&l[8]|128,t){if((r=r||0)<0||r+16>t.length)throw RangeError("UUID byte range ".concat(r,":").concat(r+15," is out of buffer bounds"));for(var u=0;u<16;++u)t[r+u]=l[u];return t}return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return(a[e[t+0]]+a[e[t+1]]+a[e[t+2]]+a[e[t+3]]+"-"+a[e[t+4]]+a[e[t+5]]+"-"+a[e[t+6]]+a[e[t+7]]+"-"+a[e[t+8]]+a[e[t+9]]+"-"+a[e[t+10]]+a[e[t+11]]+a[e[t+12]]+a[e[t+13]]+a[e[t+14]]+a[e[t+15]]).toLowerCase()}(l)}(e,t,r):crypto.randomUUID()}},99(e,t,r){"use strict";r.d(t,{Ln:()=>p,Yv:()=>c,rL:()=>d,zC:()=>f});var n=r(9726),a=r(5565),i=r(8048);function o(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function s(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function s(e){o(i,n,a,s,l,"next",e)}function l(e){o(i,n,a,s,l,"throw",e)}s(void 0)})}}function l(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function u(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}function c(e){return e.replace(/[\/\-@]/g,"_")}function d(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"./start",n=arguments.length>2?arguments[2]:void 0;return s(function(){var a,i,o,s,d,p,h;return u(this,function(u){switch(u.label){case 0:return a=(null==n?void 0:n.maxLoadingTime)&&!(n.maxLoadingTime<=0)?n.maxLoadingTime:6e5,i=void 0,[4,Promise.race([f(e,null==n?void 0:n.importMap),new Promise(function(t,r){i=setTimeout(function(){var t;r(Error("Could not resolve requested script, ".concat(e,", within ").concat((t=a)<1e3?"".concat(t," milliseconds"):t<6e4?"".concat(Math.floor(t/1e3)," seconds"):t<36e5?"".concat(Math.floor(t/6e4)," minutes"):t<864e5?"".concat(Math.floor(t/36e5)," hours"):"".concat(Math.floor(t/864e5)," days"),".")))},a)})])];case 1:var m;if(u.sent(),i&&clearTimeout(i),o=c(e),!((void 0===(m=s=window[o])?"undefined":l(m))==="object"&&null!==m&&"init"in m&&"function"==typeof m.init&&"get"in m&&"function"==typeof m.get))throw console.error(d="The global variable ".concat(o," does not refer to a federated module")),Error(d);return s.init(r.S.default),[4,s.get(t)];case 2:if((void 0===(p=u.sent()())?"undefined":l(p))!=="object"||null===p)throw console.error(h="Container for ".concat(e," did not return an ESM module as expected")),Error(h);return[2,p]}})})()}function f(e,t){return s(function(){var r,o,s,l,d,f,m;return u(this,function(u){switch(u.label){case 0:if("string"!=typeof e||0===e.trim().length)throw console.error("Attempted to call importDynamic() without supplying a package to load"),Error("Attempted to call importDynamic() without supplying a package to load");if(r=c(e),window[r])return[3,7];if(null==t)return[3,1];return s=t,[3,3];case 1:return[4,p()];case 2:s=u.sent(),u.label=3;case 3:if(!(o=s).imports.hasOwnProperty(e))throw console.error(l="Could not find the package ".concat(e," defined in the current importmap")),Error(l);(d=o.imports[e]).startsWith("./")&&(d=window.spaBase+d.substring(1)),f=e in(0,i.uT)().imports,u.label=4;case 4:return u.trys.push([4,6,,7]),[4,new Promise(function(e,t){!function(e,t,r){var n,a,i,o=document.head.querySelector('script[src="'.concat(e,'"]')),s=window[h];if(s||(s=window[h]=new Set([])),o)s.has(e)?(i=function(){n&&o.removeEventListener("load",n),a&&o.removeEventListener("error",a)},n=function(){i(),t(null)},a=function(e){i(),r(e.message)},o.addEventListener("load",n),o.addEventListener("error",a)):(console.warn("Script at ".concat(e," already loaded. Not loading it again.")),t(null));else{s.add(e);var l,u,c,d=document.createElement("script");d.src=e,d.type="text/javascript",d.async=!0;var f=setTimeout(function(){console.error("The script at ".concat(e," did not load within 5 seconds. This may indicate an issue with the imports in the script's entry-point file or with the script's bundler configuration."))},5e3);c=function(){clearTimeout(f),s.delete(e),l&&d.removeEventListener("load",l),u&&d.removeEventListener("error",u)},l=function(){c(),t(null)},u=function(t){c();var n,a="Failed to load script from ".concat(e);console.error(a,t),r(null!=(n=t.message)?n:a)},d.addEventListener("load",l),d.addEventListener("error",u),document.head.appendChild(d)}}(d,e,t)})];case 5:return[2,u.sent()];case 6:return m=u.sent(),f&&(0,n.Vt)({kind:"error",title:(0,a.V)("scriptLoadingFailed","Error: Script failed to load"),description:(0,a.V)("scriptLoadingError","Failed to load overridden script from {{- url}}. Please check that the bundled script is available at the expected URL. Click the button below to reset all import map overrides.",{url:d}),actionButtonLabel:(0,a.V)("resetOverrides","Reset overrides"),onActionButtonClick:function(){(0,i.w_)(),window.location.reload()}}),[2,Promise.reject(m)];case 7:return[2,Promise.resolve()]}})})()}function p(){return s(function(){return u(this,function(e){return[2,(0,i.F$)()]})})()}var h=Symbol("__egen_script_loading")},8048(e,t,r){"use strict";r.d(t,{BX:()=>O,E:()=>S,F$:()=>m,SM:()=>E,fd:()=>w,o5:()=>v,q1:()=>x,tK:()=>y,uT:()=>g,w_:()=>j,xI:()=>b});var n=r(3766);function a(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function i(e){return function(){var t=this,r=arguments;return new Promise(function(n,i){var o=e.apply(t,r);function s(e){a(o,n,i,s,l,"next",e)}function l(e){a(o,n,i,s,l,"throw",e)}s(void 0)})}}function o(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var s="import-map-override:",l="import-map-overrides-disabled",u="import-map-overrides:change",c=!1,d=null;function f(){return i(function(){var e,t,r,n,a,i,s;return o(this,function(o){switch(o.label){case 0:e=document.querySelectorAll('script[type="systemjs-importmap"]'),t=[],r=0,o.label=1;case 1:if(!(r<e.length))return[3,9];n=e[r],o.label=2;case 2:if(o.trys.push([2,7,,8]),!n.src)return[3,5];return[4,fetch(n.src)];case 3:return a=o.sent(),i=t.push,[4,a.json()];case 4:return i.apply(t,[o.sent()]),[3,6];case 5:n.textContent&&t.push(JSON.parse(n.textContent)),o.label=6;case 6:return[3,8];case 7:return s=o.sent(),console.warn("[import-maps] Failed to parse import map from script tag at index ".concat(r),s),[3,8];case 8:return r++,[3,1];case 9:return[2,p(t)]}})})()}function p(e){var t={imports:{}},r=!0,n=!1,a=void 0;try{for(var i,o=e[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s=i.value;(null==s?void 0:s.imports)&&Object.assign(t.imports,s.imports)}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}return t}function h(){var e={};try{for(var t=b(),r=0;r<localStorage.length;r++){var n=localStorage.key(r);if(null==n?void 0:n.startsWith(s)){var a=n.slice(s.length);if(!t.includes(a)){var i=localStorage.getItem(n);i&&(e[a]=i)}}}}catch(e){console.warn("[import-maps] Failed to read import-map overrides from localStorage",e)}return{imports:e}}function m(){return i(function(){var e;return o(this,function(t){switch(t.label){case 0:return[4,f()];case 1:if(e=t.sent(),!c)return[2,e];return[2,p([e,null!=d?d:h()])]}})})()}function y(){return i(function(){return o(this,function(e){return[2,f()]})})()}function v(){return i(function(){return o(this,function(e){switch(e.label){case 0:if(!c)return[2,f()];return[4,f()];case 1:return[2,p([e.sent(),h()])]}})})()}function g(e){if(!c)return{imports:{}};if(e){for(var t={},r=0;r<localStorage.length;r++){var n=localStorage.key(r);if(null==n?void 0:n.startsWith(s)){var a=localStorage.getItem(n);a&&(t[n.slice(s.length)]=a)}}return{imports:t}}return h()}function b(){if(!c)return[];try{var e=localStorage.getItem(l);if(e){var t=JSON.parse(e);if(Array.isArray(t))return t}}catch(e){}return[]}function x(e){return!!c&&b().includes(e)}function w(e,t){if(!c)return void console.warn("[Security] Import map overrides are disabled in production mode.");try{localStorage.setItem(s+e,t),window.dispatchEvent(new CustomEvent(u))}catch(e){console.warn("[import-maps] Failed to write import-map override to localStorage",e)}}function S(e){if(!c)return void console.warn("[Security] Import map overrides are disabled in production mode.");try{localStorage.removeItem(s+e);var t=b().filter(function(t){return t!==e});t.length>0?localStorage.setItem(l,JSON.stringify(t)):localStorage.removeItem(l),window.dispatchEvent(new CustomEvent(u))}catch(e){console.warn("[import-maps] Failed to update import-map overrides in localStorage",e)}}function j(){if(!c)return void console.warn("[Security] Import map overrides are disabled in production mode.");try{for(var e=[],t=0;t<localStorage.length;t++){var r=localStorage.key(t);(null==r?void 0:r.startsWith(s))&&e.push(r)}e.forEach(function(e){return localStorage.removeItem(e)}),localStorage.removeItem(l),window.dispatchEvent(new CustomEvent(u))}catch(e){console.warn("[import-maps] Failed to clear import-map overrides from localStorage",e)}}function O(e){if(!c)return void console.warn("[Security] Import map overrides are disabled in production mode.");try{var t=b().filter(function(t){return t!==e});t.length>0?localStorage.setItem(l,JSON.stringify(t)):localStorage.removeItem(l),window.dispatchEvent(new CustomEvent(u))}catch(e){console.warn("[import-maps] Failed to update import-map overrides in localStorage",e)}}var k=!1;function E(){!k&&(k=!0,(c="development"===window.spaEnv&&!(0,n.$)())&&(d=h()))}},101(e,t,r){"use strict";r.d(t,{xI:()=>a.xI,E:()=>a.E,eH:()=>j,SM:()=>a.SM,zU:()=>g,BX:()=>a.BX,w_:()=>a.w_,Y6:()=>b,Yv:()=>n.Yv,tK:()=>a.tK,Ln:()=>n.Ln,FM:()=>v,o5:()=>a.o5,fd:()=>a.fd,Tx:()=>w,KI:()=>S,rL:()=>n.rL,WY:()=>x,F$:()=>a.F$,zC:()=>n.zC,_m:()=>k,q1:()=>a.q1,uT:()=>a.uT});var n=r(99),a=r(8048),i=r(2235),o=r(3766);function s(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function l(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){s(i,n,a,o,l,"next",e)}function l(e){s(i,n,a,o,l,"throw",e)}o(void 0)})}}function u(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var c="egen-routes:",d="egen-routes:change",f=!1,p=null;function h(){return l(function(){var e,t,r,n,a,o;return u(this,function(s){switch(s.label){case 0:e=document.querySelectorAll("script[type='egen-routes']"),t=[],r=0,s.label=1;case 1:if(!(r<e.length))return[3,9];n=e[r],s.label=2;case 2:if(s.trys.push([2,7,,8]),a=void 0,!n.src)return[3,5];return[4,fetch(n.src)];case 3:return[4,s.sent().json()];case 4:return a=s.sent(),[3,6];case 5:n.textContent&&(a=JSON.parse(n.textContent)),s.label=6;case 6:return a&&(0,i.S)(a)&&t.push(a),[3,8];case 7:return o=s.sent(),console.warn("[route-maps] Failed to parse routes from script tag at index ".concat(r),o),[3,8];case 8:return r++,[3,1];case 9:return[2,m(t)]}})})()}function m(e){var t={},r=!0,n=!1,a=void 0;try{for(var i,o=e[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s=i.value;s&&(void 0===s?"undefined":s&&"u">typeof Symbol&&s.constructor===Symbol?"symbol":typeof s)=="object"&&Object.assign(t,s)}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}return t}function y(){return l(function(){var e,t,r,n,a,o,s,d,f,p,h,m;return u(this,function(y){switch(y.label){case 0:e={},y.label=1;case 1:for(y.trys.push([1,3,,4]),t=[],r=0;r<localStorage.length;r++)(null==(n=localStorage.key(r))?void 0:n.startsWith(c))&&(a=localStorage.getItem(n))&&t.push({moduleName:n.slice(c.length),raw:a});return[4,Promise.allSettled(t.map(function(e){var t=e.moduleName,r=e.raw;return l(function(){var e,n;return u(this,function(a){switch(a.label){case 0:if(e=JSON.parse(r),(0,i.j)(e))return[2,{moduleName:t,routes:e}];if(!("string"==typeof e&&e.startsWith("http")))return[3,3];return[4,fetch(e)];case 1:return[4,a.sent().json()];case 2:if(n=a.sent(),(0,i.j)(n))return[2,{moduleName:t,routes:n}];throw Error("".concat(e," did not resolve to a valid EgenAppRoutes object"));case 3:throw Error("Override for ".concat(t," is neither a valid routes object nor a URL"))}})})()}))];case 2:o=y.sent(),s=!0,d=!1,f=void 0;try{for(p=o[Symbol.iterator]();!(s=(h=p.next()).done);s=!0)m=h.value,"fulfilled"===m.status?e[m.value.moduleName]=m.value.routes:console.warn("[route-maps] Failed to load route override",m.reason)}catch(e){d=!0,f=e}finally{try{s||null==p.return||p.return()}finally{if(d)throw f}}return[3,4];case 3:return console.warn("[route-maps] Failed to read route overrides from localStorage",y.sent()),[3,4];case 4:return[2,e]}})})()}function v(){return l(function(){var e,t;return u(this,function(r){switch(r.label){case 0:return[4,h()];case 1:if(e=r.sent(),!f)return[2,e];if(null==p)return[3,2];return t=p,[3,4];case 2:return[4,y()];case 3:t=r.sent(),r.label=4;case 4:return[2,m([e,t])]}})})()}function g(){return l(function(){return u(this,function(e){return[2,h()]})})()}function b(){return l(function(){var e;return u(this,function(t){switch(t.label){case 0:if(!f)return[2,h()];return[4,h()];case 1:return e=[t.sent()],[4,y()];case 2:return[2,m.apply(void 0,[e.concat([t.sent()])])]}})})()}function x(){if(!f)return{};var e={};try{for(var t=0;t<localStorage.length;t++){var r=localStorage.key(t);if(null==r?void 0:r.startsWith(c)){var n=localStorage.getItem(r);n&&(e[r.slice(c.length)]=n)}}}catch(e){console.warn("[route-maps] Failed to read route overrides from localStorage",e)}return e}function w(e,t){if(!f)return void console.warn("[Security] Route overrides are disabled outside development mode.");try{if("string"==typeof t)if(t.startsWith("http"))localStorage.setItem(c+e,JSON.stringify(t));else{var r,n=JSON.parse(t);if(!(0,i.j)(n))return void console.error("The supplied routes for ".concat(e," is not a valid EgenAppRoutes object"),t);localStorage.setItem(c+e,JSON.stringify(n))}else if(r=URL,null!=r&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](t):t instanceof r)localStorage.setItem(c+e,JSON.stringify(t.toString()));else{if(!(0,i.j)(t))return void console.error("Override for ".concat(e," is not in a valid format. Expected either a Javascript Object, a JSON string of a Javascript object, or a URL"),t);localStorage.setItem(c+e,JSON.stringify(t))}window.dispatchEvent(new CustomEvent(d))}catch(e){console.warn("[route-maps] Failed to write route override to localStorage",e)}}function S(e){if(!f)return void console.warn("[Security] Route overrides are disabled outside development mode.");try{localStorage.removeItem(c+e),window.dispatchEvent(new CustomEvent(d))}catch(e){console.warn("[route-maps] Failed to remove route override from localStorage",e)}}function j(){if(!f)return void console.warn("[Security] Route overrides are disabled outside development mode.");try{for(var e=[],t=0;t<localStorage.length;t++){var r=localStorage.key(t);(null==r?void 0:r.startsWith(c))&&e.push(r)}e.forEach(function(e){return localStorage.removeItem(e)}),window.dispatchEvent(new CustomEvent(d))}catch(e){console.warn("[route-maps] Failed to clear route overrides from localStorage",e)}}var O=null;function k(){return O||(O=(f="development"===window.spaEnv&&!(0,o.$)())?y().then(function(e){p=e}):Promise.resolve())}},8507(e,t,r){"use strict";r.d(t,{J:()=>i,N:()=>a});var n=r(9726);function a(e){var t=o(e);setTimeout(function(){throw t})}function i(){var e=Error();return function(t){var r=o(t);r.stack+="\nAsync stacktrace:\n".concat(e.stack),a(t)}}function o(e){var t,r;if(null!=(r=Error)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](e):e instanceof r)return e;if(null===e)return Error("'null' was thrown as an error");if((void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"){try{t="Object thrown as error: ".concat(JSON.stringify(e))}catch(r){t="Object thrown as error with the following properties: ".concat(Object.keys(e))}return Error(t)}if(void 0===e)return Error("'undefined' was thrown as an error");return Error(e.toString())}window.onerror=function(e){return console.error("Unexpected error: ",e),(0,n.Vt)({description:null!=e?e:"Oops! An unexpected error occurred.",kind:"error",title:"Error"}),!1},window.onunhandledrejection=function(e){var t;console.error("Unhandled rejection: ",e.reason),(0,n.Vt)({description:null!=(t=e.reason)?t:"Oops! An unhandled promise rejection occurred.",kind:"error",title:"Error"})}},9360(e,t,r){"use strict";r.d(t,{dX:()=>n.dX,wE:()=>n.wE,_3:()=>n._3,uN:()=>n.uN,$F:()=>n.$F,Gz:()=>n.Gz,eb:()=>n.eb,Sj:()=>n.Sj,mv:()=>n.mv,yp:()=>l,PQ:()=>n.PQ});var n=r(6014),a=r(4356),i=r(4693);function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function s(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function l(e){if("string"!=typeof e&&((void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)!="object"||!e||!("type"in e)))throw"Unknown expression type ".concat(e,". Expressions must either be a string or pre-compiled string.");var t,r={globals:s({},i.f),isLocalExpression:!1,variables:new Set};return u("string"==typeof e?(0,a.A)(e):e,r),function(e){if(Array.isArray(e))return o(e)}(t=r.variables)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||function(e){if(e){if("string"==typeof e)return o(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return o(e,void 0)}}(t)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){switch(e.type){case"UnaryExpression":return r=e,n=t,u(r.argument,n);case"BinaryExpression":return a=e,i=t,[u(a.left,i),u(a.right,i)].filter(Boolean);case"ConditionalExpression":return o=e,l=t,[u(o.consequent,l),u(o.test,l),u(o.alternate,l)].filter(Boolean);case"CallExpression":return d=e,f=t,h=u(d.callee,f),null==(p=d.arguments)||p.map(c(f)),h;case"ArrowFunctionExpression":return function(e,t){var r=s({},t);r.isLocalExpression=!0;var n=null!=(d=null==(p=e.params)?void 0:p.map(c(r)))?d:[],a=null!=(f=u(e.body,r))?f:[];if(a&&Array.isArray(a)){var i=!0,o=!1,l=void 0;try{for(var d,f,p,h,m=a[Symbol.iterator]();!(i=(h=m.next()).done);i=!0){var y=h.value;n.includes(y)||t.variables.add(y)}}catch(e){o=!0,l=e}finally{try{i||null==m.return||m.return()}finally{if(o)throw l}}}}(e,t);case"MemberExpression":return m=e,y=t,u(m.object,y),void((v=s({},y)).isLocalExpression=!0,u(m.property,v));case"ArrayExpression":return g=e,b=t,void(null==(x=g.elements)||x.map(c(b)));case"SequenceExpression":return w=e,S=t,void(null==(j=w.expressions)||j.map(c(S)));case"NewExpression":return O=e,k=t,void(null==(E=O.arguments)||E.map(c(k)));case"Literal":case"TemplateElement":return;case"Identifier":var r,n,a,i,o,l,d,f,p,h,m,y,v,g,b,x,w,S,j,O,k,E,P,A,D,C,T=e,N=t;if(!(T.name in N.globals))if(N.isLocalExpression)return T.name;else N.variables.add(T.name);return;case"TemplateLiteral":return P=e,A=t,void(null==(D=P.expressions)||D.map(c(A)),null==(C=P.quasis)||C.map(c(A)));default:throw"Expression evaluator does not support expression of type '".concat(e.type,"'")}}function c(e){return function(t){return null===t?null:u(t,e)}}},8162(e,t,r){"use strict";r.r(t),r.d(t,{ASSISTANT_MODES:()=>b.wJ8,ActionMenu:()=>b.WyE,ActionMenuButton:()=>b.EDM,ActionMenuButton2:()=>b.Wjo,ActionableNotificationComponent:()=>b.drd,ActivityIcon:()=>b.npY,AddIcon:()=>b.REV,AnimatedHomeBackground:()=>b.BpM,ArrowDownIcon:()=>b.ZLN,ArrowLeftIcon:()=>b.A60,ArrowRightIcon:()=>b.flY,ArrowUpIcon:()=>b.Kpk,AssistantRobotScene:()=>b.JvV,AsyncSelect:()=>b.DWK,AttachmentIcon:()=>b.PtA,Autocomplete:()=>b.jT8,Breakpoint:()=>b.EA,CalendarHeatMapIcon:()=>b.mmM,CalendarIcon:()=>b.CTc,CardHeader:()=>b.aRn,CardModal:()=>b.oVc,CardModalWarpGlow:()=>b.F$l,CaretDownIcon:()=>b.bDP,CaretLeftIcon:()=>b.eCO,CaretRightIcon:()=>b.JJd,CaretUpIcon:()=>b.SwV,Carousel:()=>b.FNf,CarouselContext:()=>b.Ycj,CascadingNavDropdown:()=>b._PX,ChartAverageIcon:()=>b.ZHE,ChartLineIcon:()=>b.SCH,CheckmarkFilledIcon:()=>b.FtQ,CheckmarkOutlineIcon:()=>b.pm$,ChevronDownIcon:()=>b.D3D,ChevronLeftIcon:()=>b.YJP,ChevronRightIcon:()=>b.vKP,ChevronUpIcon:()=>b.Mtm,CircularGallery:()=>b.GF9,ClassificationTags:()=>b.QpY,CloseFilledIcon:()=>b.oCk,CloseIcon:()=>b.USm,CloseOutlineIcon:()=>b.Wdn,ColumnWithSearch:()=>b.Fny,Combobox:()=>b.G3_,CompartmentSplitter:()=>b.i_j,ContentSection:()=>b.Fe_,CornerSplitter:()=>b.rGP,CustomOverflowMenu:()=>b.TQT,CustomOverflowMenuItem:()=>b.cxd,DEFAULT_BOOLEAN_OPTIONS:()=>b.ofx,DEFAULT_COMPARTMENT_HEIGHTS:()=>c.eh,DEFAULT_COMPARTMENT_ID:()=>b.hpF,DEFAULT_COMPARTMENT_LIMITS:()=>b.oSs,DEFAULT_OPERATORS:()=>b.whL,DEFAULT_STAGGERED_MENU_AREA:()=>c.fP,DEFAULT_ZONE_SIZES:()=>b.AnT,DecoratedCard:()=>b.mqB,DefaultPageBackground:()=>b.NOx,DocumentAttachmentIcon:()=>b.Ce6,DocumentIcon:()=>b.pyG,DocumentToolbar:()=>b.PAB,DownloadIcon:()=>b.s3U,DynamicField:()=>b.koC,EditIcon:()=>b.qUP,EgenDatePicker:()=>b.O_s,EgenDateRangePicker:()=>b.tKr,EmptyCard:()=>b.slS,EmptyCardIllustration:()=>b.Ua6,EntityDetailBrowser:()=>b.NIm,ErrorCard:()=>b.JrA,ErrorState:()=>b.W5n,EventScheduleIcon:()=>b.XaH,EventsIcon:()=>b.Jc,FilterBar:()=>b.Qnn,FilterBarDefault:()=>b.vNL,FilterBarDemo:()=>b.RJr,FolderGallery:()=>b.fNA,GESTURE_NAMES:()=>b.rGw,GlobalPageBackground:()=>b.Nqf,GradientBlur:()=>b.wtE,GradientWave:()=>b.GcC,GroupAccessIcon:()=>b.Pyy,GroupIcon:()=>b.nFg,HeroMosaic:()=>b.LdX,HeroTileCard:()=>b.b6Z,HomePictogram:()=>b.KKH,Icon:()=>b.Int,ImageSwiper:()=>b.QeH,InformationFilledIcon:()=>b._e_,InformationIcon:()=>b.uQc,InformationSquareIcon:()=>b.ZrL,InteractiveSelector:()=>b.wmT,InventoryManagementIcon:()=>b.vFG,LayoutGrid:()=>b.D6i,LeftRail:()=>b.IHy,LiquidGlassCard:()=>b.lok,ListCheckedIcon:()=>b.Rt$,LiveOrb:()=>b.AFR,Loader:()=>b.aHM,LocationIcon:()=>b.BT6,MORPH_SELECT_DEFAULT_TRANSITION:()=>b.AOq,MaximizeIcon:()=>b._Xm,MaybeIcon:()=>b.oy0,MaybePictogram:()=>b.bmf,MenuToggleButton:()=>b.qLc,MessageQueueIcon:()=>b.uFu,MoneyIcon:()=>b.yBj,MorphSelect:()=>b.NGl,MorphSelectContent:()=>b.EiO,MorphSelectItem:()=>b.iRo,MorphSelectTrigger:()=>b.PK0,MorphSelectValue:()=>b.qXl,MovementIcon:()=>b.lyJ,NAV_ALL_WORKSPACES:()=>c.Xr,Notification:()=>b.Eg0,OverflowMenuHorizontalIcon:()=>b.rv3,OverflowMenuVerticalIcon:()=>b.Rnm,PageBackground:()=>b.Kz$,PageBackgroundProvider:()=>b.z0Y,PageHeader:()=>b.zYs,PageHeaderContent:()=>b.gpz,Pagination:()=>b.dKS,PasswordIcon:()=>b.BGy,PaymentsDeskPictogram:()=>b.dNG,PedestrianFamilyIcon:()=>b.PPo,PenIcon:()=>b.rZj,Pictogram:()=>b.bF1,PrinterIcon:()=>b.wwY,ProgramsIcon:()=>b.lq$,PromptInput:()=>b.Plc,RECURSIVE_EROSION_DEFAULTS:()=>b.Km0,RecursiveErosionBackground:()=>b.OoY,RenewIcon:()=>b.JTN,ReportIcon:()=>b.cQD,ResetIcon:()=>b.NAP,ResponsiveWrapper:()=>b.KFv,RightRail:()=>b.Bic,RobotController:()=>b.LMw,SECTION_CARD_CLASS:()=>b.YpM,SHELL_RAIL_BOTTOM_SLOT:()=>c.R6,SHELL_RAIL_LEFT_SLOT:()=>c.p$,SHELL_RAIL_RIGHT_SLOT:()=>c.SW,SIDE_ANCHORS:()=>b.RPL,STAGGERED_MENU_AREAS:()=>c.SK,STAGGERED_MENU_SLOT:()=>c.y$,STICKY_VARS:()=>b.Ddn,SaveIcon:()=>b.LPu,SearchIcon:()=>b.WIv,Section:()=>b.wn6,SectionAction:()=>b.SnF,SectionBody:()=>b.iq0,SectionCard:()=>b.ivh,SectionCardTitleButton:()=>b.Q5Y,SectionDivider:()=>b.nBS,SectionFooter:()=>b.lFh,SectionGrid:()=>b.KGd,SectionHeader:()=>b.X3I,SectionNavPanel:()=>b.frg,SectionSlot:()=>b.y0l,Select:()=>b.l6P,SelectContent:()=>b.gCo,SelectContext:()=>b.CW5,SelectTrigger:()=>b.bqE,ServiceQueuesPictogram:()=>b.Y21,SettingsIcon:()=>b.Zes,Sheet:()=>b.cjw,SheetClose:()=>b.kNS,SheetContent:()=>b.hae,SheetContext:()=>b.P8U,SheetDescription:()=>b.Qsg,SheetFooter:()=>b.XWC,SheetHeader:()=>b.Fm9,SheetOverlay:()=>b.YP7,SheetPortal:()=>b.yde,SheetRoot:()=>b.KId,SheetTitle:()=>b.qpM,SheetTrigger:()=>b.CGR,ShoppingCartAddItemIcon:()=>b.Uve,ShoppingCartArrowDownIcon:()=>b.Lfm,ShoppingCartIcon:()=>b.aJF,SiteActivityPanel:()=>b.Xac,SiteApplicationsPanel:()=>b.pyx,SiteBanner:()=>b.cBB,SiteCarousel:()=>b.aiS,SiteMembersPanel:()=>b.tyG,SitePanelHeader:()=>b.Xhy,SiteResourcesPanel:()=>b.Nvq,SiteSearchBar:()=>b.ttj,SiteSettingsPanel:()=>b.rmb,SiteTabbedLayout:()=>b.eFc,SiteTasksPanel:()=>b.SLu,Slider:()=>b.Apm,SliderContainer:()=>b.Jbi,SliderDotButton:()=>b.vY7,Snackbar:()=>b.qb_,SplineScene:()=>b.C44,Splitter:()=>b.O3W,StaggeredMenuPanel:()=>b._kB,StickyNoteAddIcon:()=>b.OC$,StockManagementPictogram:()=>b.q__,SwitcherIcon:()=>b.RFy,TOOL_WINDOW_CONTAINER_ATTRIBUTE:()=>b.ZLW,TOOL_WINDOW_HEADER_ATTRIBUTE:()=>b.lHJ,TOOL_WINDOW_SLOTS:()=>c.As,TOPBAR_NAV_SLOT:()=>c.yS,TOPBAR_SLOT:()=>c.sO,TableBatchActions:()=>b.GGC,TableIcon:()=>b.KbA,TableOfContentsIcon:()=>b.pYV,TestimonialCard:()=>b._f_,TestimonialCardStack:()=>b.uDL,ThumbsSlider:()=>b.BM2,TimeIcon:()=>b.b1c,Toast:()=>b.y8,ToolWindowHeader:()=>b.ICb,ToolWindowZone:()=>b.p4K,ToolsIcon:()=>b.dwU,TopBar:()=>b.Vsm,TopBarAvatar:()=>b.mIk,TopBarDivider:()=>b.AA7,TopBarIconButton:()=>b.gFP,TransferPictogram:()=>b.SKX,TranslateIcon:()=>b.SwB,TrashCanIcon:()=>b.EJV,TreeViewAltIcon:()=>b.MO4,UserAvatarIcon:()=>b.yDT,UserFollowIcon:()=>b.osL,UserIcon:()=>b.nys,ViewIcon:()=>b.tCQ,ViewOffIcon:()=>b.Oi_,WORKBENCH_ICONS:()=>b.BDu,WORKBENCH_STORAGE_KEY:()=>b.gHx,WarningIcon:()=>b.id,WaterGlassModal:()=>b.BIq,WorkSessionMode:()=>s.TG,WorkSessionStatus:()=>s.qd,Workspace2:()=>b.ozP,WorkspaceContainer:()=>b.XvC,WorkspaceNotification:()=>b.tMf,ZONE_ANCHORS:()=>b.c0o,activateOfflineCapability:()=>h.nr,addImportMapOverride:()=>o.fd,addRouteMapOverride:()=>o.Tx,attach:()=>c.K0,attachmentUrl:()=>s.Zu,beginEditSynchronizationItem:()=>h.FO,buildFilterFields:()=>b.mOW,canAccessStorage:()=>w._g,canBeginEditSynchronizationItemsOfType:()=>h.xN,canCloseWorkspaceWithoutPrompting:()=>b.SvQ,cancelPrompt:()=>b.zlb,cardModalAnimationPresets:()=>b.QsE,cardModalPresetStyles:()=>b.Zqu,changeWorkspaceContext:()=>b.JKc,checkStatus:()=>c.dO,checkStatusFor:()=>c.Ef,clampZoneSize:()=>b.foY,cleanCascadingFilters:()=>b._Jn,cleanupObsoleteFeatureFlags:()=>d.D3,clearHistory:()=>p.g4,closeAllWorkspaces:()=>b.G_3,closeCompartment:()=>b.lA$,closeToolWindow:()=>b.T7Q,closeWorkspace:()=>b.MJ8,closeWorkspaceGroup2:()=>b.biy,cn:()=>b.cn,compartmentKey:()=>b.aXL,compile:()=>u.wE,convertToLocaleCalendar:()=>w.d4,createAttachment:()=>s.cD,createErrorHandler:()=>l.J,createLiveOrb:()=>b.Ogf,defaultValidation:()=>b.n$t,defaultWorkSessionCustomRepresentation:()=>s.pJ,deleteAttachmentPermanently:()=>s.SY,deleteSynchronizationItem:()=>h.lY,detach:()=>c.Yo,detachAll:()=>c.No,dispatchActionableNotificationShown:()=>f.LQ,dispatchConnectivityChanged:()=>f.Yt,dispatchNotificationShown:()=>f.FI,dispatchPrecacheStaticDependencies:()=>f.pc,dispatchSnackbarShown:()=>f.$3,dispatchToastShown:()=>f.Vt,duration:()=>w.p0,egenOfflineCachingStrategyHttpHeaderName:()=>h.T$,egenOfflineResponseBodyHttpHeaderName:()=>h.Q1,egenOfflineResponseStatusHttpHeaderName:()=>h.Gt,enableImportMapOverride:()=>o.BX,esmStyleGuideSchema:()=>b.uQD,evaluate:()=>u._3,evaluateAsBoolean:()=>u.eb,evaluateAsBooleanAsync:()=>u.Gz,evaluateAsNumber:()=>u.dX,evaluateAsNumberAsync:()=>u.$F,evaluateAsType:()=>u.Sj,evaluateAsTypeAsync:()=>u.uN,evaluateAsync:()=>u.mv,evaluateFilter:()=>b.Ws0,extractVariableNames:()=>u.yp,featureFlagsStore:()=>d.jX,filterBreadcrumbs:()=>p.D_,finishRegisteringAllApps:()=>v.yw,fireEgenEvent:()=>s.g8,fitCompartmentHeights:()=>b.gz6,formatDate:()=>w.Yq,formatDatetime:()=>w.Rt,formatDuration:()=>w.a3,formatDurationBetween:()=>w.g2,formatPartialDate:()=>w.LW,formatTime:()=>w.fU,formatToolWindowBadge:()=>b.pd,generateOfflineUuid:()=>h.sA,getActiveModuleNames:()=>b.pJo,getAssignedExtensions:()=>c.zx,getAttachmentByUuid:()=>s.KU,getAttachments:()=>s.Bv,getBreadcrumbs:()=>p.lz,getBreadcrumbsFor:()=>p.qh,getCoreTranslation:()=>x.V,getCurrentImportMap:()=>o.Ln,getCurrentOfflineMode:()=>h.wJ,getCurrentPageMap:()=>o.F$,getCurrentRouteMap:()=>o.FM,getDefaultCalendar:()=>w.a7,getDefaultsFromConfigSchema:()=>w.kd,getDynamicOfflineDataEntries:()=>h.FE,getDynamicOfflineDataEntriesFor:()=>h.WA,getDynamicOfflineDataHandlers:()=>h.qb,getEgenServiceWorker:()=>h.b1,getEgenTarget:()=>f.tM,getExtensionInternalStore:()=>c.a9,getExtensionNameFromId:()=>c.ES,getExtensionRegistration:()=>c.Tj,getExtensionRegistrationFrom:()=>c.xg,getExtensionStore:()=>c.zF,getFeatureFlag:()=>d.jj,getFullSynchronizationItems:()=>h.C$,getFullSynchronizationItemsFor:()=>h.xc,getGroupByWindowName:()=>c.o1,getHistory:()=>p.JK,getImportMapDefaultMap:()=>o.tK,getImportMapDisabledOverrides:()=>o.xI,getImportMapNextPageMap:()=>o.o5,getImportMapOverrideMap:()=>o.uT,getLocale:()=>w.JK,getLocations:()=>s.Vs,getModalRegistration:()=>c.Fg,getNavBehavior:()=>c.Yw,getOfflineDb:()=>h.e,getOfflineEntityDataStore:()=>h.sm,getOfflineSynchronizationStore:()=>h.LM,getOpenCompartments:()=>b.u7L,getOpenedWindowIndexByWorkspace:()=>c.YX,getPromptBeforeClosingFcn:()=>b.OeE,getRegisteredWorkspace2Names:()=>b.uBm,getRouteMapDefaultMap:()=>o.zU,getRouteMapNextPageMap:()=>o.Y6,getRouteMapOverrideMap:()=>o.WY,getSavedAssistantMode:()=>b.T7$,getStaggeredMenuEntryProblems:()=>c.uu,getStartedWorkSession:()=>s.rm,getSynchronizationItem:()=>h.Gp,getSynchronizationItems:()=>h.pb,getSynchronizationItemsFor:()=>h.Io,getToolWindowCompartment:()=>c.lN,getToolWindowMetaProblems:()=>c.Sk,getWindowByWorkspaceName:()=>c.Ml,getWorkSessionStore:()=>s.r_,getWorkSessionTypes:()=>s.Ty,getWorkSessionsForEntity:()=>s.ly,getWorkspaceGroupRegistration:()=>c.Q_,getWorkspaceGroupStore:()=>b.e_T,getWorkspaceRegistration:()=>c.Xb,getWorkspaceStore:()=>b.XzH,goBackInHistory:()=>p.tA,hasCapability:()=>f.p0,hasOwnCompartment:()=>b.XWY,iconIds:()=>b.kE8,importDynamic:()=>o.rL,integrateBreakpoints:()=>b.WMK,interpolateString:()=>p.zl,interpolateUrl:()=>p.JG,isEgenAppRoutes:()=>f.j0,isEgenDateStrict:()=>w.pf,isEgenDateToday:()=>w.L8,isEgenRoutes:()=>f.Ss,isFilterReady:()=>b.iVR,isImportMapOverrideDisabled:()=>o.q1,isNativeTarget:()=>f.$6,isNavEntryInWorkspace:()=>c.oE,isNavEntryMeta:()=>c.DK,isOfflineUuid:()=>h.bO,isOnline:()=>w.sc,isSafeToolWindowIconUrl:()=>c.e4,isStaggeredMenuArea:()=>c.ND,isStaggeredMenuEntryMeta:()=>c.Te,isToolWindowMeta:()=>c.oW,isToolWindowSlot:()=>c.rq,isVersionSatisfied:()=>w.rX,isXboxAudioMuted:()=>b.lgu,jsep:()=>u.PQ,launchWorkspace:()=>b.TC2,launchWorkspace2:()=>b.pTx,launchWorkspaceGroup:()=>b.aN0,launchWorkspaceGroup2:()=>b.GYk,loadLifeCycles:()=>v.oB,loaderMarkup:()=>b.ilK,matchLocale:()=>w.w7,matchesFilters:()=>b.lu9,messageEgenServiceWorker:()=>h.Oc,navBehaviorStore:()=>c.rf,navigate:()=>p.oo,navigateAndLaunchWorkspace:()=>b.Fmw,offlineUuidPrefix:()=>h.jU,openCompartment:()=>b.$Kb,openToolWindow:()=>b.xlj,parseDate:()=>w._U,parseDateInput:()=>w.qE,pictogramIds:()=>b.vJW,playPageEnter:()=>b.m9A,playXboxSound:()=>b.x4I,preloadAssistantRobot:()=>b.mjw,preloadImport:()=>o.zC,preloadSplineScene:()=>b.Pfj,promptBeforeClosing:()=>b.F3N,promptForClosingWorkspaces:()=>b.hLN,putDynamicOfflineData:()=>h.yD,putDynamicOfflineDataFor:()=>h.ff,queueSynchronizationItem:()=>h.Zr,queueSynchronizationItemFor:()=>h.Iq,registerApp:()=>v.FZ,registerBreadcrumb:()=>p.vf,registerBreadcrumbs:()=>p.MY,registerDefaultCalendar:()=>w.XE,registerEgenServiceWorker:()=>h.QP,registerExtension:()=>c.VK,registerExtensionSlot:()=>c.FY,registerFeatureFlag:()=>d.uA,registerModal:()=>c.Ju,registerNavBehavior:()=>c.ZJ,registerOfflineEntityHandler:()=>h.Wo,registerStaggeredMenuEntry:()=>c.BR,registerToolWindow:()=>c.QS,registerWorkspace:()=>c.pm,registerWorkspaceGroup:()=>c.io,registerWorkspaceGroups2:()=>c.rD,registerWorkspaceWindows2:()=>c.Qb,registerWorkspaces2:()=>c.Uh,removeDynamicOfflineData:()=>h.NU,removeDynamicOfflineDataFor:()=>h.wn,removeImportMapOverride:()=>o.E,removeRouteMapOverride:()=>o.KI,renderActionableNotifications:()=>b.zfR,renderExtension:()=>c.wG,renderInlineNotifications:()=>b.CU$,renderLoadingSpinner:()=>b.uWG,renderPageBackground:()=>b.uTG,renderSnackbars:()=>b.ZLm,renderToasts:()=>b.f1b,renderWorkbench:()=>b.OFC,renderWorkspaceWindowsAndMenu:()=>b.jCr,reportError:()=>l.N,reset:()=>c.cL,resetImportMapOverrides:()=>o.w_,resetRouteMapOverrides:()=>o.eH,resetWorkspaceStore:()=>b._1W,resetZoneSize:()=>b.zkr,resizeCompartmentBoundary:()=>b.No8,resolveStaggeredMenuEntries:()=>c.wR,resolveWorkbenchIcon:()=>b.zLd,retry:()=>w.L5,runSynchronization:()=>h.AO,saveAssistantMode:()=>b.Pe5,saveWorkSession:()=>s.XM,setCapabilityResolver:()=>f.Zv,setCompartmentHeights:()=>b.lbO,setCurrentOfflineMode:()=>h.Og,setCurrentWorkSession:()=>s.R5,setFeatureFlag:()=>d.B4,setToolWindowBadge:()=>b.a8E,setZoneSize:()=>b.uge,setupDynamicOfflineDataHandler:()=>h.iD,setupHistory:()=>p.Wh,setupImportMapOverrides:()=>o.SM,setupModals:()=>b.EPe,setupOfflineSync:()=>h.cy,setupPageTransitions:()=>b.d1P,setupRouteMapOverrides:()=>o._m,shallowEqual:()=>w.bN,showActionableNotification:()=>b.ZyP,showModal:()=>b.toY,showNotification:()=>b.Dsh,showPageLoader:()=>b.EDr,showSnackbar:()=>b.tdF,showToast:()=>b.P0c,showWorkspacePrompts:()=>b.ctS,slugify:()=>o.Yv,staggeredMenuEntryTitle:()=>b.kxh,stickyStyleVars:()=>b.paI,subscribeActionableNotificationShown:()=>f.bK,subscribeConnectivity:()=>f.sT,subscribeConnectivityChanged:()=>f.gj,subscribeEgenEvent:()=>s.mI,subscribeNotificationShown:()=>f.bJ,subscribePrecacheStaticDependencies:()=>f.ff,subscribeSnackbarShown:()=>f.ls,subscribeToFeatureFlag:()=>d.sM,subscribeToastShown:()=>f.dX,syncAllDynamicOfflineData:()=>h.Td,syncDynamicOfflineData:()=>h.u1,syncOfflineEntityData:()=>h.Oj,toDateObjectStrict:()=>w.kQ,toEgenIsoString:()=>w.L3,toLocationObject:()=>s.E$,toWorkSessionTypeObject:()=>s.iS,toggleCompartment:()=>b.pdq,toggleToolWindow:()=>b.Hwc,toggleXboxAudio:()=>b.MiD,toolWindowTitle:()=>b.tp2,translateFrom:()=>x.t,tryRegisterExtension:()=>v.Y1,updateExtensionSlotState:()=>c.ap,updateInternalExtensionStore:()=>c.DQ,updateWorkSession:()=>s.bS,updateWorkspaceWindowState:()=>b._RD,useActiveAppModules:()=>b.Y26,useCarouselContext:()=>b.RGi,useCustomOverflowMenu:()=>b.ckU,useFilterSchema:()=>b.d4y,usePageBackground:()=>b.DYW,usePageLoading:()=>b.v99,useSelectContext:()=>b.hPu,useSheetContext:()=>b.sCq,useStaggeredMenuEntries:()=>b.NNe,useToolWindows:()=>b.ncA,useWorkspace2Context:()=>b.WO_,useWorkspace2Store:()=>b.AkA,useWorkspaces:()=>b.CH0,validateBuildManifest:()=>f.q0,workbenchBadgeStore:()=>b.UcB,workbenchStore:()=>b.Tqd,workspace2Store:()=>c.J_,workspace2StoreActions:()=>b.cJy,workspaceStore:()=>b.x9q,xboxAudio:()=>b.o81});var n=r(70),a={};for(let e in n)"default"!==e&&(a[e]=()=>n[e]);r.d(t,a);var i=r(3645),a={};for(let e in i)"default"!==e&&(a[e]=()=>i[e]);r.d(t,a);var o=r(101),s=r(3400),l=r(8507),u=r(9360),c=r(7267),d=r(5794),f=r(8840),p=r(7774),h=r(6563),m=r(4592),a={};for(let e in m)0>["registerBreadcrumbs","getImportMapOverrideMap","evaluateAsNumber","TOOL_WINDOW_SLOTS","importDynamic","registerNavBehavior","evaluateAsTypeAsync","getGroupByWindowName","WorkSessionMode","TOPBAR_SLOT","getToolWindowMetaProblems","updateInternalExtensionStore","compile","removeRouteMapOverride","checkStatus","getWorkSessionStore","goBackInHistory","getDynamicOfflineDataHandlers","dispatchConnectivityChanged","setCurrentOfflineMode","dispatchActionableNotificationShown","resetRouteMapOverrides","saveWorkSession","getModalRegistration","queueSynchronizationItem","setCapabilityResolver","getRouteMapNextPageMap","getBreadcrumbsFor","isToolWindowSlot","setupRouteMapOverrides","getEgenTarget","getWorkspaceGroupRegistration","hasCapability","registerWorkspace","registerEgenServiceWorker","DEFAULT_STAGGERED_MENU_AREA","attach","updateWorkSession","reset","validateBuildManifest","beginEditSynchronizationItem","offlineUuidPrefix","SHELL_RAIL_RIGHT_SLOT","getEgenServiceWorker","STAGGERED_MENU_SLOT","deleteAttachmentPermanently","setFeatureFlag","subscribeConnectivity","attachmentUrl","interpolateString","defaultWorkSessionCustomRepresentation","resolveStaggeredMenuEntries","detach","getToolWindowCompartment","canBeginEditSynchronizationItemsOfType","preloadImport","STAGGERED_MENU_AREAS","getCurrentImportMap","registerWorkspaceWindows2","toLocationObject","activateOfflineCapability","egenOfflineResponseBodyHttpHeaderName","getOpenedWindowIndexByWorkspace","renderExtension","evaluateAsBooleanAsync","getFeatureFlag","checkStatusFor","updateExtensionSlotState","getLocations","isEgenAppRoutes","clearHistory","dispatchSnackbarShown","NAV_ALL_WORKSPACES","egenOfflineResponseStatusHttpHeaderName","getOfflineDb","getSynchronizationItem","getHistory","getCurrentRouteMap","toWorkSessionTypeObject","subscribeSnackbarShown","getImportMapDisabledOverrides","getRouteMapDefaultMap","syncAllDynamicOfflineData","messageEgenServiceWorker","getDynamicOfflineDataEntriesFor","evaluateAsType","isOfflineUuid","registerWorkspaceGroups2","evaluateAsync","getBreadcrumbs","putDynamicOfflineDataFor","removeImportMapOverride","evaluateAsNumberAsync","getImportMapDefaultMap","extractVariableNames","removeDynamicOfflineData","getStaggeredMenuEntryProblems","subscribePrecacheStaticDependencies","getOfflineSynchronizationStore","getExtensionNameFromId","getNavBehavior","cleanupObsoleteFeatureFlags","dispatchPrecacheStaticDependencies","deleteSynchronizationItem","subscribeNotificationShown","putDynamicOfflineData","registerBreadcrumb","subscribeActionableNotificationShown","TOPBAR_NAV_SLOT","subscribeEgenEvent","subscribeToFeatureFlag","getCurrentOfflineMode","enableImportMapOverride","isEgenRoutes","createAttachment","registerOfflineEntityHandler","getStartedWorkSession","addImportMapOverride","subscribeConnectivityChanged","getWorkSessionTypes","interpolateUrl","setupHistory","getOfflineEntityDataStore","getCurrentPageMap","registerStaggeredMenuEntry","subscribeToastShown","detachAll","generateOfflineUuid","queueSynchronizationItemFor","isNavEntryInWorkspace","setupDynamicOfflineDataHandler","filterBreadcrumbs","dispatchNotificationShown","egenOfflineCachingStrategyHttpHeaderName","getAssignedExtensions","getSynchronizationItems","syncDynamicOfflineData","createErrorHandler","SHELL_RAIL_LEFT_SLOT","registerFeatureFlag","getWorkspaceRegistration","getAttachmentByUuid","isImportMapOverrideDisabled","DEFAULT_COMPARTMENT_HEIGHTS","getExtensionRegistration","registerExtension","getExtensionInternalStore","dispatchToastShown","getImportMapNextPageMap","evaluateAsBoolean","addRouteMapOverride","getAttachments","isSafeToolWindowIconUrl","workspace2Store","getFullSynchronizationItems","getFullSynchronizationItemsFor","getSynchronizationItemsFor","runSynchronization","setupOfflineSync","default","isStaggeredMenuEntryMeta","featureFlagsStore","navBehaviorStore","removeDynamicOfflineDataFor","jsep","resetImportMapOverrides","getRouteMapOverrideMap","isStaggeredMenuArea","registerWorkspaceGroup","slugify","reportError","registerToolWindow","getExtensionStore","registerWorkspaces2","fireEgenEvent","setupImportMapOverrides","setCurrentWorkSession","getWorkSessionsForEntity","registerExtensionSlot","registerModal","evaluate","getWindowByWorkspaceName","isNavEntryMeta","getDynamicOfflineDataEntries","WorkSessionStatus","syncOfflineEntityData","getExtensionRegistrationFrom","isToolWindowMeta","SHELL_RAIL_BOTTOM_SLOT","isNativeTarget","navigate"].indexOf(e)&&(a[e]=()=>m[e]);r.d(t,a);var y=r(7388),a={};for(let e in y)0>["registerBreadcrumbs","getImportMapOverrideMap","evaluateAsNumber","TOOL_WINDOW_SLOTS","importDynamic","registerNavBehavior","evaluateAsTypeAsync","getGroupByWindowName","WorkSessionMode","TOPBAR_SLOT","getToolWindowMetaProblems","updateInternalExtensionStore","compile","removeRouteMapOverride","checkStatus","getWorkSessionStore","goBackInHistory","getDynamicOfflineDataHandlers","dispatchConnectivityChanged","setCurrentOfflineMode","dispatchActionableNotificationShown","resetRouteMapOverrides","saveWorkSession","getModalRegistration","queueSynchronizationItem","setCapabilityResolver","getRouteMapNextPageMap","getBreadcrumbsFor","isToolWindowSlot","setupRouteMapOverrides","getEgenTarget","getWorkspaceGroupRegistration","hasCapability","registerWorkspace","registerEgenServiceWorker","DEFAULT_STAGGERED_MENU_AREA","attach","updateWorkSession","reset","validateBuildManifest","beginEditSynchronizationItem","offlineUuidPrefix","SHELL_RAIL_RIGHT_SLOT","getEgenServiceWorker","STAGGERED_MENU_SLOT","deleteAttachmentPermanently","setFeatureFlag","subscribeConnectivity","attachmentUrl","interpolateString","defaultWorkSessionCustomRepresentation","resolveStaggeredMenuEntries","detach","getToolWindowCompartment","canBeginEditSynchronizationItemsOfType","preloadImport","STAGGERED_MENU_AREAS","getCurrentImportMap","registerWorkspaceWindows2","toLocationObject","activateOfflineCapability","egenOfflineResponseBodyHttpHeaderName","getOpenedWindowIndexByWorkspace","renderExtension","evaluateAsBooleanAsync","getFeatureFlag","checkStatusFor","updateExtensionSlotState","getLocations","isEgenAppRoutes","clearHistory","dispatchSnackbarShown","NAV_ALL_WORKSPACES","egenOfflineResponseStatusHttpHeaderName","getOfflineDb","getSynchronizationItem","getHistory","getCurrentRouteMap","toWorkSessionTypeObject","subscribeSnackbarShown","getImportMapDisabledOverrides","getRouteMapDefaultMap","syncAllDynamicOfflineData","messageEgenServiceWorker","getDynamicOfflineDataEntriesFor","evaluateAsType","isOfflineUuid","registerWorkspaceGroups2","evaluateAsync","getBreadcrumbs","putDynamicOfflineDataFor","removeImportMapOverride","evaluateAsNumberAsync","getImportMapDefaultMap","extractVariableNames","removeDynamicOfflineData","getStaggeredMenuEntryProblems","subscribePrecacheStaticDependencies","getOfflineSynchronizationStore","getExtensionNameFromId","getNavBehavior","cleanupObsoleteFeatureFlags","dispatchPrecacheStaticDependencies","deleteSynchronizationItem","subscribeNotificationShown","putDynamicOfflineData","registerBreadcrumb","subscribeActionableNotificationShown","TOPBAR_NAV_SLOT","subscribeEgenEvent","subscribeToFeatureFlag","getCurrentOfflineMode","enableImportMapOverride","isEgenRoutes","createAttachment","registerOfflineEntityHandler","getStartedWorkSession","addImportMapOverride","subscribeConnectivityChanged","getWorkSessionTypes","interpolateUrl","setupHistory","getOfflineEntityDataStore","getCurrentPageMap","registerStaggeredMenuEntry","subscribeToastShown","detachAll","generateOfflineUuid","queueSynchronizationItemFor","isNavEntryInWorkspace","setupDynamicOfflineDataHandler","filterBreadcrumbs","dispatchNotificationShown","egenOfflineCachingStrategyHttpHeaderName","getAssignedExtensions","getSynchronizationItems","syncDynamicOfflineData","createErrorHandler","SHELL_RAIL_LEFT_SLOT","registerFeatureFlag","getWorkspaceRegistration","getAttachmentByUuid","isImportMapOverrideDisabled","DEFAULT_COMPARTMENT_HEIGHTS","getExtensionRegistration","registerExtension","getExtensionInternalStore","dispatchToastShown","getImportMapNextPageMap","evaluateAsBoolean","addRouteMapOverride","getAttachments","isSafeToolWindowIconUrl","workspace2Store","getFullSynchronizationItems","getFullSynchronizationItemsFor","getSynchronizationItemsFor","runSynchronization","setupOfflineSync","default","isStaggeredMenuEntryMeta","featureFlagsStore","navBehaviorStore","removeDynamicOfflineDataFor","jsep","resetImportMapOverrides","getRouteMapOverrideMap","isStaggeredMenuArea","registerWorkspaceGroup","slugify","reportError","registerToolWindow","getExtensionStore","registerWorkspaces2","fireEgenEvent","setupImportMapOverrides","setCurrentWorkSession","getWorkSessionsForEntity","registerExtensionSlot","registerModal","evaluate","getWindowByWorkspaceName","isNavEntryMeta","getDynamicOfflineDataEntries","WorkSessionStatus","syncOfflineEntityData","getExtensionRegistrationFrom","isToolWindowMeta","SHELL_RAIL_BOTTOM_SLOT","isNativeTarget","navigate"].indexOf(e)&&(a[e]=()=>y[e]);r.d(t,a);var v=r(7230),g=r(1442),a={};for(let e in g)0>["navigate","getImportMapOverrideMap","evaluateAsNumber","TOOL_WINDOW_SLOTS","importDynamic","registerNavBehavior","finishRegisteringAllApps","registerBreadcrumbs","evaluateAsTypeAsync","tryRegisterExtension","WorkSessionMode","TOPBAR_SLOT","getToolWindowMetaProblems","updateInternalExtensionStore","compile","removeRouteMapOverride","checkStatus","getWorkSessionStore","goBackInHistory","getDynamicOfflineDataHandlers","dispatchConnectivityChanged","setCurrentOfflineMode","dispatchActionableNotificationShown","resetRouteMapOverrides","saveWorkSession","getModalRegistration","queueSynchronizationItem","getGroupByWindowName","setCapabilityResolver","getRouteMapNextPageMap","getBreadcrumbsFor","isToolWindowSlot","setupRouteMapOverrides","getEgenTarget","getWorkspaceGroupRegistration","hasCapability","registerWorkspace","registerEgenServiceWorker","DEFAULT_STAGGERED_MENU_AREA","attach","updateWorkSession","reset","validateBuildManifest","beginEditSynchronizationItem","offlineUuidPrefix","SHELL_RAIL_RIGHT_SLOT","getEgenServiceWorker","STAGGERED_MENU_SLOT","deleteAttachmentPermanently","setFeatureFlag","subscribeConnectivity","attachmentUrl","interpolateString","defaultWorkSessionCustomRepresentation","resolveStaggeredMenuEntries","detach","getToolWindowCompartment","canBeginEditSynchronizationItemsOfType","preloadImport","STAGGERED_MENU_AREAS","getCurrentImportMap","registerWorkspaceWindows2","toLocationObject","activateOfflineCapability","egenOfflineResponseBodyHttpHeaderName","getOpenedWindowIndexByWorkspace","renderExtension","evaluateAsBooleanAsync","getFeatureFlag","checkStatusFor","updateExtensionSlotState","getLocations","isEgenAppRoutes","clearHistory","dispatchSnackbarShown","NAV_ALL_WORKSPACES","egenOfflineResponseStatusHttpHeaderName","getOfflineDb","getSynchronizationItem","getHistory","getCurrentRouteMap","toWorkSessionTypeObject","subscribeSnackbarShown","getImportMapDisabledOverrides","getRouteMapDefaultMap","syncAllDynamicOfflineData","messageEgenServiceWorker","getDynamicOfflineDataEntriesFor","evaluateAsType","isOfflineUuid","registerWorkspaceGroups2","evaluateAsync","getBreadcrumbs","putDynamicOfflineDataFor","removeImportMapOverride","evaluateAsNumberAsync","getImportMapDefaultMap","extractVariableNames","putDynamicOfflineData","removeDynamicOfflineData","getStaggeredMenuEntryProblems","subscribePrecacheStaticDependencies","getOfflineSynchronizationStore","getExtensionNameFromId","getNavBehavior","dispatchPrecacheStaticDependencies","deleteSynchronizationItem","cleanupObsoleteFeatureFlags","subscribeNotificationShown","registerBreadcrumb","subscribeActionableNotificationShown","TOPBAR_NAV_SLOT","subscribeEgenEvent","subscribeToFeatureFlag","getCurrentOfflineMode","enableImportMapOverride","isEgenRoutes","createAttachment","registerOfflineEntityHandler","getStartedWorkSession","addImportMapOverride","subscribeConnectivityChanged","getWorkSessionTypes","interpolateUrl","setupHistory","getOfflineEntityDataStore","getCurrentPageMap","registerStaggeredMenuEntry","subscribeToastShown","detachAll","generateOfflineUuid","queueSynchronizationItemFor","isNavEntryInWorkspace","registerApp","setupDynamicOfflineDataHandler","filterBreadcrumbs","dispatchNotificationShown","egenOfflineCachingStrategyHttpHeaderName","getAssignedExtensions","getSynchronizationItems","syncDynamicOfflineData","createErrorHandler","SHELL_RAIL_LEFT_SLOT","registerFeatureFlag","getWorkspaceRegistration","getAttachmentByUuid","isImportMapOverrideDisabled","DEFAULT_COMPARTMENT_HEIGHTS","getExtensionRegistration","registerExtension","getExtensionInternalStore","dispatchToastShown","getImportMapNextPageMap","evaluateAsBoolean","addRouteMapOverride","getAttachments","isSafeToolWindowIconUrl","workspace2Store","getFullSynchronizationItems","getFullSynchronizationItemsFor","getSynchronizationItemsFor","runSynchronization","setupOfflineSync","default","isStaggeredMenuEntryMeta","featureFlagsStore","navBehaviorStore","removeDynamicOfflineDataFor","jsep","resetImportMapOverrides","getRouteMapOverrideMap","isStaggeredMenuArea","registerWorkspaceGroup","slugify","reportError","registerToolWindow","getExtensionStore","registerWorkspaces2","fireEgenEvent","setupImportMapOverrides","setCurrentWorkSession","getWorkSessionsForEntity","registerExtensionSlot","registerModal","evaluate","getWindowByWorkspaceName","loadLifeCycles","getDynamicOfflineDataEntries","isNavEntryMeta","syncOfflineEntityData","WorkSessionStatus","getExtensionRegistrationFrom","isToolWindowMeta","isNativeTarget","SHELL_RAIL_BOTTOM_SLOT"].indexOf(e)&&(a[e]=()=>g[e]);r.d(t,a);var b=r(597),x=r(5565),w=r(4834)},1221(e,t,r){"use strict";r.d(t,{Z:()=>a,p:()=>i});var n=null;function a(e){n=e}function i(e){return!!n&&n(e)}},8840(e,t,r){"use strict";r.d(t,{Vt:()=>n.Vt,tM:()=>i.t,q0:()=>c,j0:()=>a.j,ff:()=>n.ff,ls:()=>n.ls,LQ:()=>n.LQ,sT:()=>n.sT,FI:()=>n.FI,Ss:()=>a.S,dX:()=>n.dX,$3:()=>n.$3,pc:()=>n.pc,bK:()=>n.bK,gj:()=>n.gj,Zv:()=>o.Z,bJ:()=>n.bJ,p0:()=>o.p,Yt:()=>n.Yt,$6:()=>i.$});var n=r(9726),a=r(2235),i=r(3766),o=r(1221),s=/^\d+\.\d+\.\d+(?:-[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?(?:\+[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/,l=/^sha(?:256|384|512)-[A-Za-z0-9+/]+={0,2}$/;function u(e){return(void 0===e?"undefined":e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e)=="object"&&null!==e&&!Array.isArray(e)}function c(e){var t=[];if(!u(e))return{valid:!1,errors:["le manifeste doit \xeatre un objet"]};var r=e.shellVersion,n=e.frameworkVersion,a=e.protocolVersion,i=e.apps;"string"==typeof r&&s.test(r)||t.push("shellVersion doit \xeatre une version semver (ex. 2.10.0)"),"string"==typeof n&&s.test(n)||t.push("frameworkVersion doit \xeatre une version semver (ex. 4.0.0)"),("number"!=typeof a||!Number.isInteger(a)||a<1)&&t.push("protocolVersion doit \xeatre un entier ≥ 1");var o=[];if(Array.isArray(i)){var c=new Set;i.forEach(function(e,r){var n="apps[".concat(r,"]");if(!u(e))return void t.push("".concat(n," doit \xeatre un objet"));var a=e.name,i=e.version,d=e.integrity;"string"!=typeof a||0===a.length?t.push("".concat(n,".name doit \xeatre une cha\xeene non vide")):c.has(a)?t.push("".concat(n,'.name "').concat(a,'" est en double')):c.add(a),"string"==typeof i&&s.test(i)||t.push("".concat(n,".version doit \xeatre une version semver exacte")),"string"==typeof d&&l.test(d)||t.push("".concat(n,".integrity doit \xeatre une empreinte SRI (sha256-…, sha384-… ou sha512-…)")),"string"==typeof a&&"string"==typeof i&&"string"==typeof d&&o.push({name:a,version:i,integrity:d})})}else t.push("apps doit \xeatre un tableau");return t.length>0?{valid:!1,errors:t}:{valid:!0,manifest:{shellVersion:r,frameworkVersion:n,protocolVersion:a,apps:o}}}},2235(e,t,r){"use strict";function n(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function a(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}function i(e){return!!e&&(void 0===e?"undefined":a(e))==="object"&&!(Object.hasOwn(e,"pages")&&(!e.pages||!Array.isArray(e.pages))||Object.hasOwn(e,"extensions")&&(!e.extensions||!Array.isArray(e.extensions))||Object.hasOwn(e,"workspaces")&&(!e.workspaces||!Array.isArray(e.workspaces))||Object.hasOwn(e,"modals")&&(!e.modals||!Array.isArray(e.modals)))}function o(e){return!!e&&(void 0===e?"undefined":a(e))==="object"&&Object.entries(e).every(function(e){var t=function(e){if(Array.isArray(e))return e}(e)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(e)||function(e){if(e){if("string"==typeof e)return n(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return n(e,2)}}(e)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=t[0],a=t[1];return"string"==typeof r&&i(a)})}r.d(t,{S:()=>o,j:()=>i})},6563(e,t,r){"use strict";let n;r.d(t,{nr:()=>C,xN:()=>np,u1:()=>nI,FO:()=>nh,Q1:()=>g,FE:()=>nA,sA:()=>nb,LM:()=>nn,ff:()=>nT,wn:()=>nR,Oj:()=>nz,lY:()=>nm,Zr:()=>ns,cy:()=>ny,WA:()=>nD,T$:()=>x,Gp:()=>nf,jU:()=>ng,Og:()=>D,iD:()=>nP,C$:()=>nd,qb:()=>nE,Iq:()=>no,NU:()=>nN,yD:()=>nC,Wo:()=>nV,sm:()=>nB,Io:()=>nl,wJ:()=>A,Oc:()=>S,e:()=>r4,xc:()=>nu,pb:()=>nc,bO:()=>nx,b1:()=>v,AO:()=>na,Td:()=>nM,QP:()=>y,Gt:()=>b});try{self["workbox:window:6.5.4"]&&_()}catch(e){}function a(e,t){return new Promise(function(r){var n=new MessageChannel;n.port1.onmessage=function(e){r(e.data)},e.postMessage(t,[n.port2])})}function i(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}try{self["workbox:core:6.5.4"]&&_()}catch(e){}var s=function(){var e=this;this.promise=new Promise(function(t,r){e.resolve=t,e.reject=r})};function l(e,t){var r=location.href;return new URL(e,r).href===new URL(t,r).href}var u=function(e,t){this.type=e,Object.assign(this,t)};function c(e,t,r){return r?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}function d(){}var f={type:"SKIP_WAITING"};function p(e,t){if(!t)return e&&e.then?e.then(d):Promise.resolve()}var h=function(e){function t(t,r){var n,a;return void 0===r&&(r={}),(n=e.call(this)||this).nn={},n.tn=0,n.rn=new s,n.en=new s,n.on=new s,n.un=0,n.an=new Set,n.cn=function(){var e=n.fn,t=e.installing;n.tn>0||!l(t.scriptURL,n.sn.toString())||performance.now()>n.un+6e4?(n.vn=t,e.removeEventListener("updatefound",n.cn)):(n.hn=t,n.an.add(t),n.rn.resolve(t)),++n.tn,t.addEventListener("statechange",n.ln)},n.ln=function(e){var t=n.fn,r=e.target,a=r.state,i=r===n.vn,o={sw:r,isExternal:i,originalEvent:e};!i&&n.mn&&(o.isUpdate=!0),n.dispatchEvent(new u(a,o)),"installed"===a?n.wn=self.setTimeout(function(){"installed"===a&&t.waiting===r&&n.dispatchEvent(new u("waiting",o))},200):"activating"===a&&(clearTimeout(n.wn),i||n.en.resolve(r))},n.dn=function(e){var t=n.hn,r=t!==navigator.serviceWorker.controller;n.dispatchEvent(new u("controlling",{isExternal:r,originalEvent:e,sw:t,isUpdate:n.mn})),r||n.on.resolve(t)},a=function(e){var t=e.data,r=e.ports,a=e.source;return c(n.getSW(),function(){n.an.has(a)&&n.dispatchEvent(new u("message",{data:t,originalEvent:e,ports:r,sw:a}))})},n.gn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];try{return Promise.resolve(a.apply(this,e))}catch(e){return Promise.reject(e)}},n.sn=t,n.nn=r,navigator.serviceWorker.addEventListener("message",n.gn),n}t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e;var r,n,o=t.prototype;return o.register=function(e){var t=(void 0===e?{}:e).immediate,r=void 0!==t&&t;try{var n,a,i,o=this;return n=function(){if(!r&&"complete"!==document.readyState)return p(new Promise(function(e){return window.addEventListener("load",e)}))},a=function(){return o.mn=!!navigator.serviceWorker.controller,o.yn=o.pn(),c(o.bn(),function(e){o.fn=e,o.yn&&(o.hn=o.yn,o.en.resolve(o.yn),o.on.resolve(o.yn),o.yn.addEventListener("statechange",o.ln,{once:!0}));var t=o.fn.waiting;return t&&l(t.scriptURL,o.sn.toString())&&(o.hn=t,Promise.resolve().then(function(){o.dispatchEvent(new u("waiting",{sw:t,wasWaitingBeforeRegister:!0}))}).then(function(){})),o.hn&&(o.rn.resolve(o.hn),o.an.add(o.hn)),o.fn.addEventListener("updatefound",o.cn),navigator.serviceWorker.addEventListener("controllerchange",o.dn),o.fn})},(i=n())&&i.then?i.then(a):a(i)}catch(e){return Promise.reject(e)}},o.update=function(){try{return this.fn?p(this.fn.update()):void 0}catch(e){return Promise.reject(e)}},o.getSW=function(){return void 0!==this.hn?Promise.resolve(this.hn):this.rn.promise},o.messageSW=function(e){try{return c(this.getSW(),function(t){return a(t,e)})}catch(e){return Promise.reject(e)}},o.messageSkipWaiting=function(){this.fn&&this.fn.waiting&&a(this.fn.waiting,f)},o.pn=function(){var e=navigator.serviceWorker.controller;return e&&l(e.scriptURL,this.sn.toString())?e:void 0},o.bn=function(){try{var e=this;return function(e,t){try{var r=e()}catch(e){return t(e)}return r&&r.then?r.then(void 0,t):r}(function(){return c(navigator.serviceWorker.register(e.sn,e.nn),function(t){return e.un=performance.now(),t})},function(e){throw e})}catch(e){return Promise.reject(e)}},r=[{key:"active",get:function(){return this.en.promise}},{key:"controlling",get:function(){return this.on.promise}}],i(t.prototype,r),n&&i(t,n),t}(function(){function e(){this.Pn=new Map}var t=e.prototype;return t.addEventListener=function(e,t){this.Sn(e).add(t)},t.removeEventListener=function(e,t){this.Sn(e).delete(t)},t.dispatchEvent=function(e){e.target=this;for(var t,r=function(e){var t;if("u"<typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(t=function(e){if(e){if("string"==typeof e)return o(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?o(e,void 0):void 0}}(e))){t&&(e=t);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(t=e[Symbol.iterator]()).next.bind(t)}(this.Sn(e.type));!(t=r()).done;)(0,t.value)(e)},t.Sn=function(e){return this.Pn.has(e)||this.Pn.set(e,new Set),this.Pn.get(e)},e}()),m=void 0;function y(e,t){if(void 0!==m)return console.warn("The application's Service Worker has already been registered. The new service worker at ".concat(e," will not be registered.")),m;if(!("serviceWorker"in navigator))throw Error("Registering the Service Worker is not possible due to missing browser capabilities.");var r=new h(e,t);return m=r.register().then(function(){return r.controlling.then(function(){return r})})}function v(){return null!=m?m:Promise.resolve(void 0)}var g="x-egen-offline-response-body",b="x-egen-offline-response-status",x="x-egen-offline-caching-strategy";function w(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function S(e){var t;return(t=function(){var t,r;return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(n){switch(n.label){case 0:return[4,v()];case 1:if(!(t=n.sent()))return[3,3];return[4,t.messageSW(e)];case 2:return r=n.sent(),[3,4];case 3:r={success:!1,result:void 0,error:"No service worker has been registered. This is typically the case when the application has been built without offline-related features."},n.label=4;case 4:return[2,r]}})},function(){var e=this,r=arguments;return new Promise(function(n,a){var i=t.apply(e,r);function o(e){w(i,n,a,o,s,"next",e)}function s(e){w(i,n,a,o,s,"throw",e)}o(void 0)})})()}function j(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function O(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){j(i,n,a,o,s,"next",e)}function s(e){j(i,n,a,o,s,"throw",e)}o(void 0)})}}function k(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var E="egen3:offline-mode",P="unavailable";function A(){return{current:P,notAvailable:"unavailable"===P,active:"on"===P}}function D(e){"unavailable"!==P&&"unavailable"!==e&&(localStorage.setItem(E,"on"===e?"active":"disabled"),P=e)}function C(){return O(function(){return k(this,function(e){switch(e.label){case 0:return[4,O(function(){var e,t;return k(this,function(r){switch(r.label){case 0:return[4,O(function(){return k(this,function(e){return[2,new Promise(function(e){var t=indexedDB.open("test");t.onerror=function(){return e(!0)},t.onsuccess=function(){return e(!1)}})]})})()];case 1:if(t=r.sent())return[3,3];return[4,O(function(){return k(this,function(e){return[2,!window.indexedDB]})})()];case 2:t=r.sent(),r.label=3;case 3:if(e=t)return[3,5];return[4,O(function(){var e;return k(this,function(t){e=window.sessionStorage;try{e.setItem("someKeyHere","test"),e.removeItem("someKeyHere")}catch(t){if(t.code===DOMException.QUOTA_EXCEEDED_ERR&&0===e.length)return[2,!0]}return[2,!1]})})()];case 4:e=r.sent(),r.label=5;case 5:return[2,e]}})})()];case 1:return e.sent()||(P="active"===localStorage.getItem(E)?"on":"off"),navigator.onLine,[2]}})})()}let T="u">typeof globalThis?globalThis:"u">typeof self?self:"u">typeof window?window:global,N=Object.keys,R=Array.isArray;function M(e,t){return"object"!=typeof t||N(t).forEach(function(r){e[r]=t[r]}),e}"u"<typeof Promise||T.Promise||(T.Promise=Promise);let I=Object.getPrototypeOf,L={}.hasOwnProperty;function F(e,t){return L.call(e,t)}function B(e,t){"function"==typeof t&&(t=t(I(e))),("u"<typeof Reflect?N:Reflect.ownKeys)(t).forEach(r=>{z(e,r,t[r])})}let V=Object.defineProperty;function z(e,t,r,n){V(e,t,M(r&&F(r,"get")&&"function"==typeof r.get?{get:r.get,set:r.set,configurable:!0}:{value:r,configurable:!0,writable:!0},n))}function W(e){return{from:function(t){return e.prototype=Object.create(t.prototype),z(e.prototype,"constructor",e),{extend:B.bind(null,e.prototype)}}}}let $=Object.getOwnPropertyDescriptor;function U(e,t){let r;return $(e,t)||(r=I(e))&&U(r,t)}let H=[].slice;function G(e,t,r){return H.call(e,t,r)}function K(e,t){return t(e)}function q(e){if(!e)throw Error("Assertion Failed")}function Y(e){T.setImmediate?setImmediate(e):setTimeout(e,0)}function X(e,t){return e.reduce((e,r,n)=>{var a=t(r,n);return a&&(e[a[0]]=a[1]),e},{})}function Z(e,t){if("string"==typeof t&&F(e,t))return e[t];if(!t)return e;if("string"!=typeof t){for(var r=[],n=0,a=t.length;n<a;++n){var i=Z(e,t[n]);r.push(i)}return r}var o=t.indexOf(".");if(-1!==o){var s=e[t.substr(0,o)];return null==s?void 0:Z(s,t.substr(o+1))}}function Q(e,t,r){if(e&&void 0!==t&&(!("isFrozen"in Object)||!Object.isFrozen(e)))if("string"!=typeof t&&"length"in t){q("string"!=typeof r&&"length"in r);for(var n=0,a=t.length;n<a;++n)Q(e,t[n],r[n])}else{var i=t.indexOf(".");if(-1!==i){var o=t.substr(0,i),s=t.substr(i+1);if(""===s)void 0===r?R(e)&&!isNaN(parseInt(o))?e.splice(o,1):delete e[o]:e[o]=r;else{var l=e[o];l&&F(e,o)||(l=e[o]={}),Q(l,s,r)}}else void 0===r?R(e)&&!isNaN(parseInt(t))?e.splice(t,1):delete e[t]:e[t]=r}}function J(e){var t={};for(var r in e)F(e,r)&&(t[r]=e[r]);return t}let ee=[].concat;function et(e){return ee.apply([],e)}let er="BigUint64Array,BigInt64Array,Array,Boolean,String,Date,RegExp,Blob,File,FileList,FileSystemFileHandle,FileSystemDirectoryHandle,ArrayBuffer,DataView,Uint8ClampedArray,ImageBitmap,ImageData,Map,Set,CryptoKey".split(",").concat(et([8,16,32,64].map(e=>["Int","Uint","Float"].map(t=>t+e+"Array")))).filter(e=>T[e]),en=er.map(e=>T[e]);X(er,e=>[e,!0]);let ea=null;function ei(e){ea="u">typeof WeakMap&&new WeakMap;let t=function e(t){if(!t||"object"!=typeof t)return t;let r=ea&&ea.get(t);if(r)return r;if(R(t)){r=[],ea&&ea.set(t,r);for(var n=0,a=t.length;n<a;++n)r.push(e(t[n]))}else if(en.indexOf(t.constructor)>=0)r=t;else{let n=I(t);for(var i in r=n===Object.prototype?{}:Object.create(n),ea&&ea.set(t,r),t)F(t,i)&&(r[i]=e(t[i]))}return r}(e);return ea=null,t}let{toString:eo}={};function es(e){return eo.call(e).slice(8,-1)}let el="u">typeof Symbol?Symbol.iterator:"@@iterator",eu="symbol"==typeof el?function(e){var t;return null!=e&&(t=e[el])&&t.apply(e)}:function(){return null},ec={};function ed(e){var t,r,n,a;if(1==arguments.length){if(R(e))return e.slice();if(this===ec&&"string"==typeof e)return[e];if(a=eu(e)){for(r=[];!(n=a.next()).done;)r.push(n.value);return r}if(null==e)return[e];if("number"==typeof(t=e.length)){for(r=Array(t);t--;)r[t]=e[t];return r}return[e]}for(t=arguments.length,r=Array(t);t--;)r[t]=arguments[t];return r}let ef="u">typeof Symbol?e=>"AsyncFunction"===e[Symbol.toStringTag]:()=>!1;var ep="u">typeof location&&/^(http|https):\/\/(localhost|127\.0\.0\.1)/.test(location.href),eh=()=>!0;let em=!Error("").stack;function ey(){if(em)try{throw ey.arguments,Error()}catch(e){return e}return Error()}function ev(e,t){var r=e.stack;return r?(t=t||0,0===r.indexOf(e.name)&&(t+=(e.name+e.message).split("\n").length),r.split("\n").slice(t).filter(eh).map(e=>"\n"+e).join("")):""}var eg=["Unknown","Constraint","Data","TransactionInactive","ReadOnly","Version","NotFound","InvalidState","InvalidAccess","Abort","Timeout","QuotaExceeded","Syntax","DataClone"],eb=["Modify","Bulk","OpenFailed","VersionChange","Schema","Upgrade","InvalidTable","MissingAPI","NoSuchDatabase","InvalidArgument","SubTransaction","Unsupported","Internal","DatabaseClosed","PrematureCommit","ForeignAwait"].concat(eg),ex={VersionChanged:"Database version changed by other database connection",DatabaseClosed:"Database has been closed",Abort:"Transaction aborted",TransactionInactive:"Transaction has already completed or failed",MissingAPI:"IndexedDB API missing. Please visit https://tinyurl.com/y2uuvskb"};function ew(e,t){this._e=ey(),this.name=e,this.message=t}function eS(e,t){return e+". Errors: "+Object.keys(t).map(e=>t[e].toString()).filter((e,t,r)=>r.indexOf(e)===t).join("\n")}function ej(e,t,r,n){this._e=ey(),this.failures=t,this.failedKeys=n,this.successCount=r,this.message=eS(e,t)}function eO(e,t){this._e=ey(),this.name="BulkError",this.failures=Object.keys(t).map(e=>t[e]),this.failuresByPos=t,this.message=eS(e,t)}W(ew).from(Error).extend({stack:{get:function(){return this._stack||(this._stack=this.name+": "+this.message+ev(this._e,2))}},toString:function(){return this.name+": "+this.message}}),W(ej).from(ew),W(eO).from(ew);var ek=eb.reduce((e,t)=>(e[t]=t+"Error",e),{}),eE=eb.reduce((e,t)=>{var r=t+"Error";function n(e,n){this._e=ey(),this.name=r,e?"string"==typeof e?(this.message=`${e}${n?"\n "+n:""}`,this.inner=n||null):"object"==typeof e&&(this.message=`${e.name} ${e.message}`,this.inner=e):(this.message=ex[t]||r,this.inner=null)}return W(n).from(ew),e[t]=n,e},{});eE.Syntax=SyntaxError,eE.Type=TypeError,eE.Range=RangeError;var eP=eg.reduce((e,t)=>(e[t+"Error"]=eE[t],e),{}),eA=eb.reduce((e,t)=>(-1===["Syntax","Type","Range"].indexOf(t)&&(e[t+"Error"]=eE[t]),e),{});function eD(){}function eC(e){return e}function eT(e,t){return null==e||e===eC?t:function(r){return t(e(r))}}function eN(e,t){return function(){e.apply(this,arguments),t.apply(this,arguments)}}function eR(e,t){return e===eD?t:function(){var r=e.apply(this,arguments);void 0!==r&&(arguments[0]=r);var n=this.onsuccess,a=this.onerror;this.onsuccess=null,this.onerror=null;var i=t.apply(this,arguments);return n&&(this.onsuccess=this.onsuccess?eN(n,this.onsuccess):n),a&&(this.onerror=this.onerror?eN(a,this.onerror):a),void 0!==i?i:r}}function eM(e,t){return e===eD?t:function(){e.apply(this,arguments);var r=this.onsuccess,n=this.onerror;this.onsuccess=this.onerror=null,t.apply(this,arguments),r&&(this.onsuccess=this.onsuccess?eN(r,this.onsuccess):r),n&&(this.onerror=this.onerror?eN(n,this.onerror):n)}}function eI(e,t){return e===eD?t:function(r){var n=e.apply(this,arguments);M(r,n);var a=this.onsuccess,i=this.onerror;this.onsuccess=null,this.onerror=null;var o=t.apply(this,arguments);return a&&(this.onsuccess=this.onsuccess?eN(a,this.onsuccess):a),i&&(this.onerror=this.onerror?eN(i,this.onerror):i),void 0===n?void 0===o?void 0:o:M(n,o)}}function e_(e,t){return e===eD?t:function(){return!1!==t.apply(this,arguments)&&e.apply(this,arguments)}}function eL(e,t){return e===eD?t:function(){var r=e.apply(this,arguments);if(r&&"function"==typeof r.then){for(var n=this,a=arguments.length,i=Array(a);a--;)i[a]=arguments[a];return r.then(function(){return t.apply(n,i)})}return t.apply(this,arguments)}}eA.ModifyError=ej,eA.DexieError=ew,eA.BulkError=eO;var eF={};let[eB,eV,ez]="u"<typeof Promise?[]:(()=>{let e=Promise.resolve();if("u"<typeof crypto||!crypto.subtle)return[e,I(e),e];let t=crypto.subtle.digest("SHA-512",new Uint8Array([0]));return[t,I(t),e]})(),eW=eV&&eV.then,e$=eB&&eB.constructor,eU=!!ez;var eH=!1,eG=ez?()=>{ez.then(tn)}:T.setImmediate?setImmediate.bind(null,tn):T.MutationObserver?()=>{var e=document.createElement("div");new MutationObserver(()=>{tn(),e=null}).observe(e,{attributes:!0}),e.setAttribute("i","1")}:()=>{setTimeout(tn,0)},eK=function(e,t){e2.push([e,t]),eY&&(eG(),eY=!1)},eq=!0,eY=!0,eX=[],eZ=[],eQ=null,eJ=eC,e0={id:"global",global:!0,ref:0,unhandleds:[],onunhandled:tP,pgp:!1,env:{},finalize:function(){this.unhandleds.forEach(e=>{try{tP(e[0],e[1])}catch(e){}})}},e1=e0,e2=[],e3=0,e4=[];function e5(e){if("object"!=typeof this)throw TypeError("Promises must be constructed via new");this._listeners=[],this.onuncatched=eD,this._lib=!1;var t=this._PSD=e1;if(ep&&(this._stackHolder=ey(),this._prev=null,this._numPrev=0),"function"!=typeof e){if(e!==eF)throw TypeError("Not a function");return this._state=arguments[1],this._value=arguments[2],void(!1===this._state&&e9(this,this._value))}this._state=null,this._value=null,++t.ref,function e(t,r){try{r(r=>{if(null===t._state){if(r===t)throw TypeError("A promise cannot be resolved with itself.");var n=t._lib&&ta();r&&"function"==typeof r.then?e(t,(e,t)=>{r instanceof e5?r._then(e,t):r.then(e,t)}):(t._state=!0,t._value=r,e7(t)),n&&ti()}},e9.bind(null,t))}catch(e){e9(t,e)}}(this,e)}let e6={get:function(){var e=e1,t=tp;function r(r,n){var a=!e.global&&(e!==e1||t!==tp);let i=a&&!tv();var o=new e5((t,o)=>{te(this,new e8(tO(r,e,a,i),tO(n,e,a,i),t,o,e))});return ep&&tr(o,this),o}return r.prototype=eF,r},set:function(e){z(this,"then",e&&e.prototype===eF?e6:{get:function(){return e},set:e6.set})}};function e8(e,t,r,n,a){this.onFulfilled="function"==typeof e?e:null,this.onRejected="function"==typeof t?t:null,this.resolve=r,this.reject=n,this.psd=a}function e9(e,t){if(eZ.push(t),null===e._state){var r=e._lib&&ta();t=eJ(t),e._state=!1,e._value=t,ep&&null!==t&&"object"==typeof t&&!t._promise&&function(e){try{e.apply(null,void 0)}catch(e){}}(()=>{var r=U(t,"stack");t._promise=e,z(t,"stack",{get:()=>eH?r&&(r.get?r.get.apply(t):r.value):e.stack})}),eX.some(t=>t._value===e._value)||eX.push(e),e7(e),r&&ti()}}function e7(e){var t=e._listeners;e._listeners=[];for(var r=0,n=t.length;r<n;++r)te(e,t[r]);var a=e._PSD;--a.ref||a.finalize(),0===e3&&(++e3,eK(()=>{0==--e3&&to()},[]))}function te(e,t){if(null!==e._state){var r=e._state?t.onFulfilled:t.onRejected;if(null===r)return(e._state?t.resolve:t.reject)(e._value);++t.psd.ref,++e3,eK(tt,[r,e,t])}else e._listeners.push(t)}function tt(e,t,r){try{eQ=t;var n,a=t._value;t._state?n=e(a):(eZ.length&&(eZ=[]),n=e(a),-1===eZ.indexOf(a)&&function(e){for(var t=eX.length;t;)if(eX[--t]._value===e._value)return void eX.splice(t,1)}(t)),r.resolve(n)}catch(e){r.reject(e)}finally{eQ=null,0==--e3&&to(),--r.psd.ref||r.psd.finalize()}}function tr(e,t){var r=t?t._numPrev+1:0;r<100&&(e._prev=t,e._numPrev=r)}function tn(){ta()&&ti()}function ta(){var e=eq;return eq=!1,eY=!1,e}function ti(){var e,t,r;do for(;e2.length>0;)for(e=e2,e2=[],r=e.length,t=0;t<r;++t){var n=e[t];n[0].apply(null,n[1])}while(e2.length>0);eq=!0,eY=!0}function to(){var e=eX;eX=[],e.forEach(e=>{e._PSD.onunhandled.call(null,e._value,e)});for(var t=e4.slice(0),r=t.length;r;)t[--r]()}function ts(e){return new e5(eF,!1,e)}function tl(e,t){var r=e1;return function(){var n=ta(),a=e1;try{return tw(r,!0),e.apply(this,arguments)}catch(e){t&&t(e)}finally{tw(a,!1),n&&ti()}}}B(e5.prototype,{then:e6,_then:function(e,t){te(this,new e8(null,null,e,t,e1))},catch:function(e){if(1==arguments.length)return this.then(null,e);var t=arguments[0],r=arguments[1];return"function"==typeof t?this.then(null,e=>e instanceof t?r(e):ts(e)):this.then(null,e=>e&&e.name===t?r(e):ts(e))},finally:function(e){return this.then(t=>(e(),t),t=>(e(),ts(t)))},stack:{get:function(){if(this._stack)return this._stack;try{eH=!0;var e=(function e(t,r,n){if(r.length===n)return r;var a="";if(!1===t._state){var i,o,s=t._value;null!=s?(i=s.name||"Error",o=s.message||s,a=ev(s,0)):(i=s,o=""),r.push(i+(o?": "+o:"")+a)}return ep&&((a=ev(t._stackHolder,2))&&-1===r.indexOf(a)&&r.push(a),t._prev&&e(t._prev,r,n)),r})(this,[],20).join("\nFrom previous: ");return null!==this._state&&(this._stack=e),e}finally{eH=!1}}},timeout:function(e,t){return e<1/0?new e5((r,n)=>{var a=setTimeout(()=>n(new eE.Timeout(t)),e);this.then(r,n).finally(clearTimeout.bind(null,a))}):this}}),"u">typeof Symbol&&Symbol.toStringTag&&z(e5.prototype,Symbol.toStringTag,"Dexie.Promise"),e0.env=tS(),B(e5,{all:function(){var e=ed.apply(null,arguments).map(tg);return new e5(function(t,r){0===e.length&&t([]);var n=e.length;e.forEach((a,i)=>e5.resolve(a).then(r=>{e[i]=r,--n||t(e)},r))})},resolve:e=>{if(e instanceof e5)return e;if(e&&"function"==typeof e.then)return new e5((t,r)=>{e.then(t,r)});var t=new e5(eF,!0,e);return tr(t,eQ),t},reject:ts,race:function(){var e=ed.apply(null,arguments).map(tg);return new e5((t,r)=>{e.map(e=>e5.resolve(e).then(t,r))})},PSD:{get:()=>e1,set:e=>e1=e},totalEchoes:{get:()=>tp},newPSD:tm,usePSD:tj,scheduler:{get:()=>eK,set:e=>{eK=e}},rejectionMapper:{get:()=>eJ,set:e=>{eJ=e}},follow:(e,t)=>new e5((r,n)=>tm((t,r)=>{var n=e1;n.unhandleds=[],n.onunhandled=r,n.finalize=eN(function(){var e;e=()=>{0===this.unhandleds.length?t():r(this.unhandleds[0])},e4.push(function t(){e(),e4.splice(e4.indexOf(t),1)}),++e3,eK(()=>{0==--e3&&to()},[])},n.finalize),e()},t,r,n))}),e$&&(e$.allSettled&&z(e5,"allSettled",function(){let e=ed.apply(null,arguments).map(tg);return new e5(t=>{0===e.length&&t([]);let r=e.length,n=Array(r);e.forEach((e,a)=>e5.resolve(e).then(e=>n[a]={status:"fulfilled",value:e},e=>n[a]={status:"rejected",reason:e}).then(()=>--r||t(n)))})}),e$.any&&"u">typeof AggregateError&&z(e5,"any",function(){let e=ed.apply(null,arguments).map(tg);return new e5((t,r)=>{0===e.length&&r(AggregateError([]));let n=e.length,a=Array(n);e.forEach((e,i)=>e5.resolve(e).then(e=>t(e),e=>{a[i]=e,--n||r(AggregateError(a))}))})}));let tu={awaits:0,echoes:0,id:0};var tc=0,td=[],tf=0,tp=0,th=0;function tm(e,t,r,n){var a=e1,i=Object.create(a);i.parent=a,i.ref=0,i.global=!1,i.id=++th;var o=e0.env;i.env=eU?{Promise:e5,PromiseProp:{value:e5,configurable:!0,writable:!0},all:e5.all,race:e5.race,allSettled:e5.allSettled,any:e5.any,resolve:e5.resolve,reject:e5.reject,nthen:tk(o.nthen,i),gthen:tk(o.gthen,i)}:{},t&&M(i,t),++a.ref,i.finalize=function(){--this.parent.ref||this.parent.finalize()};var s=tj(i,e,r,n);return 0===i.ref&&i.finalize(),s}function ty(){return tu.id||(tu.id=++tc),++tu.awaits,tu.echoes+=100,tu.id}function tv(){return!!tu.awaits&&(0==--tu.awaits&&(tu.id=0),tu.echoes=100*tu.awaits,!0)}function tg(e){return tu.echoes&&e&&e.constructor===e$?(ty(),e.then(e=>(tv(),e),e=>(tv(),tA(e)))):e}function tb(e){++tp,tu.echoes&&0!=--tu.echoes||(tu.echoes=tu.id=0),td.push(e1),tw(e,!0)}function tx(){var e=td[td.length-1];td.pop(),tw(e,!1)}function tw(e,t){var r,n=e1;if((t?!tu.echoes||tf++&&e===e1:!tf||--tf&&e===e1)||(r=t?tb.bind(null,e):tx,eW.call(eB,r)),e!==e1&&(e1=e,n===e0&&(e0.env=tS()),eU)){var a=e0.env.Promise,i=e.env;eV.then=i.nthen,a.prototype.then=i.gthen,(n.global||e.global)&&(Object.defineProperty(T,"Promise",i.PromiseProp),a.all=i.all,a.race=i.race,a.resolve=i.resolve,a.reject=i.reject,i.allSettled&&(a.allSettled=i.allSettled),i.any&&(a.any=i.any))}}function tS(){var e=T.Promise;return eU?{Promise:e,PromiseProp:Object.getOwnPropertyDescriptor(T,"Promise"),all:e.all,race:e.race,allSettled:e.allSettled,any:e.any,resolve:e.resolve,reject:e.reject,nthen:eV.then,gthen:e.prototype.then}:{}}function tj(e,t,r,n,a){var i=e1;try{return tw(e,!0),t(r,n,a)}finally{tw(i,!1)}}function tO(e,t,r,n){return"function"!=typeof e?e:function(){var a,i=e1;r&&ty(),tw(t,!0);try{return e.apply(this,arguments)}finally{tw(i,!1),n&&(a=tv,eW.call(eB,a))}}}function tk(e,t){return function(r,n){return e.call(this,tO(r,t),tO(n,t))}}-1===(""+eW).indexOf("[native code]")&&(ty=tv=eD);let tE="unhandledrejection";function tP(e,t){var r;try{r=t.onuncatched(e)}catch(e){}if(!1!==r)try{var n,a={promise:t,reason:e};if(T.document&&document.createEvent?((n=document.createEvent("Event")).initEvent(tE,!0,!0),M(n,a)):T.CustomEvent&&M(n=new CustomEvent(tE,{detail:a}),a),n&&T.dispatchEvent&&(dispatchEvent(n),!T.PromiseRejectionEvent&&T.onunhandledrejection))try{T.onunhandledrejection(n)}catch(e){}ep&&n&&!n.defaultPrevented&&console.warn(`Unhandled rejection: ${e.stack||e}`)}catch(e){}}var tA=e5.reject;let tD="3.2.7",tC=String.fromCharCode(65535),tT=-1/0,tN="Invalid key provided. Keys must be of type string, number, Date or Array<string | number | Date>.",tR="String expected.",tM=[],tI="u">typeof navigator&&/(MSIE|Trident|Edge)/.test(navigator.userAgent),t_=e=>!/(dexie\.js|dexie\.min\.js)/.test(e),tL="__dbnames",tF="readonly",tB="readwrite";function tV(e,t){return e?t?function(){return e.apply(this,arguments)&&t.apply(this,arguments)}:e:t}let tz={type:3,lower:-1/0,lowerOpen:!1,upper:[[]],upperOpen:!1};function tW(e){return"string"!=typeof e||/\./.test(e)?e=>e:t=>(void 0===t[e]&&e in t&&delete(t=ei(t))[e],t)}class t${_trans(e,t,r){let n=this._tx||e1.trans,a=this.name;function i(e,r,n){if(!n.schema[a])throw new eE.NotFound("Table "+a+" not part of transaction");return t(n.idbtrans,n)}let o=ta();try{return n&&n.db===this.db?n===e1.trans?n._promise(e,i,r):tm(()=>n._promise(e,i,r),{trans:n,transless:e1.transless||e1}):function e(t,r,n,a){if(t.idbdb&&(t._state.openComplete||e1.letThrough||t._vip)){var i=t._createTransaction(r,n,t._dbSchema);try{i.create(),t._state.PR1398_maxLoop=3}catch(i){return i.name===ek.InvalidState&&t.isOpen()&&--t._state.PR1398_maxLoop>0?(console.warn("Dexie: Need to reopen db"),t._close(),t.open().then(()=>e(t,r,n,a))):tA(i)}return i._promise(r,(e,t)=>tm(()=>(e1.trans=i,a(e,t,i)))).then(e=>i._completion.then(()=>e))}if(t._state.openComplete)return tA(new eE.DatabaseClosed(t._state.dbOpenError));if(!t._state.isBeingOpened){if(!t._options.autoOpen)return tA(new eE.DatabaseClosed);t.open().catch(eD)}return t._state.dbReadyPromise.then(()=>e(t,r,n,a))}(this.db,e,[this.name],i)}finally{o&&ti()}}get(e,t){return e&&e.constructor===Object?this.where(e).first(t):this._trans("readonly",t=>this.core.get({trans:t,key:e}).then(e=>this.hook.reading.fire(e))).then(t)}where(e){if("string"==typeof e)return new this.db.WhereClause(this,e);if(R(e))return new this.db.WhereClause(this,`[${e.join("+")}]`);let t=N(e);if(1===t.length)return this.where(t[0]).equals(e[t[0]]);let r=this.schema.indexes.concat(this.schema.primKey).filter(e=>{if(e.compound&&t.every(t=>e.keyPath.indexOf(t)>=0)){for(let r=0;r<t.length;++r)if(-1===t.indexOf(e.keyPath[r]))return!1;return!0}return!1}).sort((e,t)=>e.keyPath.length-t.keyPath.length)[0];if(r&&this.db._maxKey!==tC){let n=r.keyPath.slice(0,t.length);return this.where(n).equals(n.map(t=>e[t]))}!r&&ep&&console.warn(`The query ${JSON.stringify(e)} on ${this.name} would benefit of a compound index [${t.join("+")}]`);let{idxByName:n}=this.schema,a=this.db._deps.indexedDB;function i(e,t){try{return 0===a.cmp(e,t)}catch(e){return!1}}let[o,s]=t.reduce(([t,r],a)=>{let o=n[a],s=e[a];return[t||o,t||!o?tV(r,o&&o.multi?e=>{let t=Z(e,a);return R(t)&&t.some(e=>i(s,e))}:e=>i(s,Z(e,a))):r]},[null,null]);return o?this.where(o.name).equals(e[o.keyPath]).filter(s):r?this.filter(s):this.where(t).equals("")}filter(e){return this.toCollection().and(e)}count(e){return this.toCollection().count(e)}offset(e){return this.toCollection().offset(e)}limit(e){return this.toCollection().limit(e)}each(e){return this.toCollection().each(e)}toArray(e){return this.toCollection().toArray(e)}toCollection(){return new this.db.Collection(new this.db.WhereClause(this))}orderBy(e){return new this.db.Collection(new this.db.WhereClause(this,R(e)?`[${e.join("+")}]`:e))}reverse(){return this.toCollection().reverse()}mapToClass(e){this.schema.mappedClass=e;let t=t=>{if(!t)return t;let r=Object.create(e.prototype);for(var n in t)if(F(t,n))try{r[n]=t[n]}catch(e){}return r};return this.schema.readHook&&this.hook.reading.unsubscribe(this.schema.readHook),this.schema.readHook=t,this.hook("reading",t),e}defineClass(){return this.mapToClass(function(e){M(this,e)})}add(e,t){let{auto:r,keyPath:n}=this.schema.primKey,a=e;return n&&r&&(a=tW(n)(e)),this._trans("readwrite",e=>this.core.mutate({trans:e,type:"add",keys:null!=t?[t]:null,values:[a]})).then(e=>e.numFailures?e5.reject(e.failures[0]):e.lastResult).then(t=>{if(n)try{Q(e,n,t)}catch(e){}return t})}update(e,t){if("object"!=typeof e||R(e))return this.where(":id").equals(e).modify(t);{let r=Z(e,this.schema.primKey.keyPath);if(void 0===r)return tA(new eE.InvalidArgument("Given object does not contain its primary key"));try{"function"!=typeof t?N(t).forEach(r=>{Q(e,r,t[r])}):t(e,{value:e,primKey:r})}catch(e){}return this.where(":id").equals(r).modify(t)}}put(e,t){let{auto:r,keyPath:n}=this.schema.primKey,a=e;return n&&r&&(a=tW(n)(e)),this._trans("readwrite",e=>this.core.mutate({trans:e,type:"put",values:[a],keys:null!=t?[t]:null})).then(e=>e.numFailures?e5.reject(e.failures[0]):e.lastResult).then(t=>{if(n)try{Q(e,n,t)}catch(e){}return t})}delete(e){return this._trans("readwrite",t=>this.core.mutate({trans:t,type:"delete",keys:[e]})).then(e=>e.numFailures?e5.reject(e.failures[0]):void 0)}clear(){return this._trans("readwrite",e=>this.core.mutate({trans:e,type:"deleteRange",range:tz})).then(e=>e.numFailures?e5.reject(e.failures[0]):void 0)}bulkGet(e){return this._trans("readonly",t=>this.core.getMany({keys:e,trans:t}).then(e=>e.map(e=>this.hook.reading.fire(e))))}bulkAdd(e,t,r){let n=Array.isArray(t)?t:void 0,a=(r=r||(n?void 0:t))?r.allKeys:void 0;return this._trans("readwrite",t=>{let{auto:r,keyPath:i}=this.schema.primKey;if(i&&n)throw new eE.InvalidArgument("bulkAdd(): keys argument invalid on tables with inbound keys");if(n&&n.length!==e.length)throw new eE.InvalidArgument("Arguments objects and keys must have the same length");let o=e.length,s=i&&r?e.map(tW(i)):e;return this.core.mutate({trans:t,type:"add",keys:n,values:s,wantResults:a}).then(({numFailures:e,results:t,lastResult:r,failures:n})=>{if(0===e)return a?t:r;throw new eO(`${this.name}.bulkAdd(): ${e} of ${o} operations failed`,n)})})}bulkPut(e,t,r){let n=Array.isArray(t)?t:void 0,a=(r=r||(n?void 0:t))?r.allKeys:void 0;return this._trans("readwrite",t=>{let{auto:r,keyPath:i}=this.schema.primKey;if(i&&n)throw new eE.InvalidArgument("bulkPut(): keys argument invalid on tables with inbound keys");if(n&&n.length!==e.length)throw new eE.InvalidArgument("Arguments objects and keys must have the same length");let o=e.length,s=i&&r?e.map(tW(i)):e;return this.core.mutate({trans:t,type:"put",keys:n,values:s,wantResults:a}).then(({numFailures:e,results:t,lastResult:r,failures:n})=>{if(0===e)return a?t:r;throw new eO(`${this.name}.bulkPut(): ${e} of ${o} operations failed`,n)})})}bulkDelete(e){let t=e.length;return this._trans("readwrite",t=>this.core.mutate({trans:t,type:"delete",keys:e})).then(({numFailures:e,lastResult:r,failures:n})=>{if(0===e)return r;throw new eO(`${this.name}.bulkDelete(): ${e} of ${t} operations failed`,n)})}}function tU(e){var t={},r=function(r,n){if(n){for(var a=arguments.length,i=Array(a-1);--a;)i[a-1]=arguments[a];return t[r].subscribe.apply(null,i),e}if("string"==typeof r)return t[r]};r.addEventType=i;for(var n=1,a=arguments.length;n<a;++n)i(arguments[n]);return r;function i(e,n,a){if("object"!=typeof e){n||(n=e_),a||(a=eD);var o={subscribers:[],fire:a,subscribe:function(e){-1===o.subscribers.indexOf(e)&&(o.subscribers.push(e),o.fire=n(o.fire,e))},unsubscribe:function(e){o.subscribers=o.subscribers.filter(function(t){return t!==e}),o.fire=o.subscribers.reduce(n,a)}};return t[e]=r[e]=o,o}N(e).forEach(function(t){var r=e[t];if(R(r))i(t,e[t][0],e[t][1]);else{if("asap"!==r)throw new eE.InvalidArgument("Invalid event config");var n=i(t,eC,function(){for(var e=arguments.length,t=Array(e);e--;)t[e]=arguments[e];n.subscribers.forEach(function(e){Y(function(){e.apply(null,t)})})})}})}}function tH(e,t){return W(t).from({prototype:e}),t}function tG(e,t){return!(e.filter||e.algorithm||e.or)&&(t?e.justLimit:!e.replayFilter)}function tK(e,t){e.filter=tV(e.filter,t)}function tq(e,t,r){var n=e.replayFilter;e.replayFilter=n?()=>tV(n(),t()):t,e.justLimit=r&&!n}function tY(e,t){if(e.isPrimKey)return t.primaryKey;let r=t.getIndexByKeyPath(e.index);if(!r)throw new eE.Schema("KeyPath "+e.index+" on object store "+t.name+" is not indexed");return r}function tX(e,t,r){let n=tY(e,t.schema);return t.openCursor({trans:r,values:!e.keysOnly,reverse:"prev"===e.dir,unique:!!e.unique,query:{index:n,range:e.range}})}function tZ(e,t,r,n){let a=e.replayFilter?tV(e.filter,e.replayFilter()):e.filter;if(e.or){let i={},o=(e,r,n)=>{if(!a||a(r,n,e=>r.stop(e),e=>r.fail(e))){var o=r.primaryKey,s=""+o;"[object ArrayBuffer]"===s&&(s=""+new Uint8Array(o)),F(i,s)||(i[s]=!0,t(e,r,n))}};return Promise.all([e.or._iterate(o,r),tQ(tX(e,n,r),e.algorithm,o,!e.keysOnly&&e.valueMapper)])}return tQ(tX(e,n,r),tV(e.algorithm,a),t,!e.keysOnly&&e.valueMapper)}function tQ(e,t,r,n){var a=tl(n?(e,t,a)=>r(n(e),t,a):r);return e.then(e=>{if(e)return e.start(()=>{var r=()=>e.continue();t&&!t(e,e=>r=e,t=>{e.stop(t),r=eD},t=>{e.fail(t),r=eD})||a(e.value,e,e=>r=e),r()})})}function tJ(e,t){try{let r=t0(e),n=t0(t);if(r!==n)return"Array"===r?1:"Array"===n?-1:"binary"===r?1:"binary"===n?-1:"string"===r?1:"string"===n?-1:"Date"===r?1:"Date"!==n?NaN:-1;switch(r){case"number":case"Date":case"string":return e>t?1:e<t?-1:0;case"binary":return function(e,t){let r=e.length,n=t.length,a=r<n?r:n;for(let r=0;r<a;++r)if(e[r]!==t[r])return e[r]<t[r]?-1:1;return r===n?0:r<n?-1:1}(t1(e),t1(t));case"Array":return function(e,t){let r=e.length,n=t.length,a=r<n?r:n;for(let r=0;r<a;++r){let n=tJ(e[r],t[r]);if(0!==n)return n}return r===n?0:r<n?-1:1}(e,t)}}catch(e){}return NaN}function t0(e){let t=typeof e;if("object"!==t)return t;if(ArrayBuffer.isView(e))return"binary";let r=es(e);return"ArrayBuffer"===r?"binary":r}function t1(e){return e instanceof Uint8Array?e:ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e)}class t2{_read(e,t){var r=this._ctx;return r.error?r.table._trans(null,tA.bind(null,r.error)):r.table._trans("readonly",e).then(t)}_write(e){var t=this._ctx;return t.error?t.table._trans(null,tA.bind(null,t.error)):t.table._trans("readwrite",e,"locked")}_addAlgorithm(e){var t=this._ctx;t.algorithm=tV(t.algorithm,e)}_iterate(e,t){return tZ(this._ctx,e,t,this._ctx.table.core)}clone(e){var t=Object.create(this.constructor.prototype),r=Object.create(this._ctx);return e&&M(r,e),t._ctx=r,t}raw(){return this._ctx.valueMapper=null,this}each(e){var t=this._ctx;return this._read(r=>tZ(t,e,r,t.table.core))}count(e){return this._read(e=>{let t=this._ctx,r=t.table.core;if(tG(t,!0))return r.count({trans:e,query:{index:tY(t,r.schema),range:t.range}}).then(e=>Math.min(e,t.limit));var n=0;return tZ(t,()=>(++n,!1),e,r).then(()=>n)}).then(e)}sortBy(e,t){let r=e.split(".").reverse(),n=r[0],a=r.length-1;function i(e,t){return t?i(e[r[t]],t-1):e[n]}var o="next"===this._ctx.dir?1:-1;function s(e,t){var r=i(e,a),n=i(t,a);return r<n?-o:r>n?o:0}return this.toArray(function(e){return e.sort(s)}).then(t)}toArray(e){return this._read(e=>{var t=this._ctx;if("next"===t.dir&&tG(t,!0)&&t.limit>0){let{valueMapper:r}=t,n=tY(t,t.table.core.schema);return t.table.core.query({trans:e,limit:t.limit,values:!0,query:{index:n,range:t.range}}).then(({result:e})=>r?e.map(r):e)}{let r=[];return tZ(t,e=>r.push(e),e,t.table.core).then(()=>r)}},e)}offset(e){var t=this._ctx;return e<=0||(t.offset+=e,tG(t)?tq(t,()=>{var t=e;return(e,r)=>0===t||(1===t?--t:r(()=>{e.advance(t),t=0}),!1)}):tq(t,()=>{var t=e;return()=>--t<0})),this}limit(e){return this._ctx.limit=Math.min(this._ctx.limit,e),tq(this._ctx,()=>{var t=e;return function(e,r,n){return--t<=0&&r(n),t>=0}},!0),this}until(e,t){return tK(this._ctx,function(r,n,a){return!e(r.value)||(n(a),t)}),this}first(e){return this.limit(1).toArray(function(e){return e[0]}).then(e)}last(e){return this.reverse().first(e)}filter(e){var t;return tK(this._ctx,function(t){return e(t.value)}),(t=this._ctx).isMatch=tV(t.isMatch,e),this}and(e){return this.filter(e)}or(e){return new this.db.WhereClause(this._ctx.table,e,this)}reverse(){return this._ctx.dir="prev"===this._ctx.dir?"next":"prev",this._ondirectionchange&&this._ondirectionchange(this._ctx.dir),this}desc(){return this.reverse()}eachKey(e){var t=this._ctx;return t.keysOnly=!t.isMatch,this.each(function(t,r){e(r.key,r)})}eachUniqueKey(e){return this._ctx.unique="unique",this.eachKey(e)}eachPrimaryKey(e){var t=this._ctx;return t.keysOnly=!t.isMatch,this.each(function(t,r){e(r.primaryKey,r)})}keys(e){var t=this._ctx;t.keysOnly=!t.isMatch;var r=[];return this.each(function(e,t){r.push(t.key)}).then(function(){return r}).then(e)}primaryKeys(e){var t=this._ctx;if("next"===t.dir&&tG(t,!0)&&t.limit>0)return this._read(e=>{var r=tY(t,t.table.core.schema);return t.table.core.query({trans:e,values:!1,limit:t.limit,query:{index:r,range:t.range}})}).then(({result:e})=>e).then(e);t.keysOnly=!t.isMatch;var r=[];return this.each(function(e,t){r.push(t.primaryKey)}).then(function(){return r}).then(e)}uniqueKeys(e){return this._ctx.unique="unique",this.keys(e)}firstKey(e){return this.limit(1).keys(function(e){return e[0]}).then(e)}lastKey(e){return this.reverse().firstKey(e)}distinct(){var e=this._ctx,t=e.index&&e.table.schema.idxByName[e.index];if(!t||!t.multi)return this;var r={};return tK(this._ctx,function(e){var t=e.primaryKey.toString(),n=F(r,t);return r[t]=!0,!n}),this}modify(e){var t=this._ctx;return this._write(r=>{var n;if("function"==typeof e)n=e;else{var a=N(e),i=a.length;n=function(t){for(var r=!1,n=0;n<i;++n){var o=a[n],s=e[o];Z(t,o)!==s&&(Q(t,o,s),r=!0)}return r}}let o=t.table.core,{outbound:s,extractKey:l}=o.schema.primaryKey,u=this.db._options.modifyChunkSize||200,c=[],d=0,f=[],p=(e,t)=>{let{failures:r,numFailures:n}=t;for(let t of(d+=e-n,N(r)))c.push(r[t])};return this.clone().primaryKeys().then(a=>{let i=c=>{let d=Math.min(u,a.length-c);return o.getMany({trans:r,keys:a.slice(c,c+d),cache:"immutable"}).then(f=>{let h=[],m=[],y=s?[]:null,v=[];for(let e=0;e<d;++e){let t=f[e],r={value:ei(t),primKey:a[c+e]};!1!==n.call(r,r.value,r)&&(null==r.value?v.push(a[c+e]):s||0===tJ(l(t),l(r.value))?(m.push(r.value),s&&y.push(a[c+e])):(v.push(a[c+e]),h.push(r.value)))}let g=tG(t)&&t.limit===1/0&&("function"!=typeof e||e===t3)&&{index:t.index,range:t.range};return Promise.resolve(h.length>0&&o.mutate({trans:r,type:"add",values:h}).then(e=>{for(let t in e.failures)v.splice(parseInt(t),1);p(h.length,e)})).then(()=>(m.length>0||g&&"object"==typeof e)&&o.mutate({trans:r,type:"put",keys:y,values:m,criteria:g,changeSpec:"function"!=typeof e&&e}).then(e=>p(m.length,e))).then(()=>(v.length>0||g&&e===t3)&&o.mutate({trans:r,type:"delete",keys:v,criteria:g}).then(e=>p(v.length,e))).then(()=>a.length>c+d&&i(c+u))})};return i(0).then(()=>{if(c.length>0)throw new ej("Error modifying one or more objects",c,d,f);return a.length})})})}delete(){var e=this._ctx,t=e.range;return tG(e)&&(e.isPrimKey&&!tI||3===t.type)?this._write(r=>{let{primaryKey:n}=e.table.core.schema;return e.table.core.count({trans:r,query:{index:n,range:t}}).then(n=>e.table.core.mutate({trans:r,type:"deleteRange",range:t}).then(({failures:e,lastResult:t,results:r,numFailures:a})=>{if(a)throw new ej("Could not delete some values",Object.keys(e).map(t=>e[t]),n-a);return n-a}))}):this.modify(t3)}}let t3=(e,t)=>t.value=null;function t4(e,t){return e<t?-1:+(e!==t)}function t5(e,t){return e>t?-1:+(e!==t)}function t6(e,t,r){var n=e instanceof rt?new e.Collection(e):e;return n._ctx.error=r?new r(t):TypeError(t),n}function t8(e){return new e.Collection(e,()=>re("")).limit(0)}function t9(e,t,r,n){var a,i,o,s,l,u,c,d=r.length;if(!r.every(e=>"string"==typeof e))return t6(e,tR);function f(e){a="next"===e?e=>e.toUpperCase():e=>e.toLowerCase(),i="next"===e?e=>e.toLowerCase():e=>e.toUpperCase(),o="next"===e?t4:t5;var t=r.map(function(e){return{lower:i(e),upper:a(e)}}).sort(function(e,t){return o(e.lower,t.lower)});s=t.map(function(e){return e.upper}),l=t.map(function(e){return e.lower}),u=e,c="next"===e?"":n}f("next");var p=new e.Collection(e,()=>t7(s[0],l[d-1]+n));p._ondirectionchange=function(e){f(e)};var h=0;return p._addAlgorithm(function(e,r,n){var a=e.key;if("string"!=typeof a)return!1;var f=i(a);if(t(f,l,h))return!0;for(var p=null,m=h;m<d;++m){var y=function(e,t,r,n,a,i){for(var o=Math.min(e.length,n.length),s=-1,l=0;l<o;++l){var u=t[l];if(u!==n[l])return 0>a(e[l],r[l])?e.substr(0,l)+r[l]+r.substr(l+1):0>a(e[l],n[l])?e.substr(0,l)+n[l]+r.substr(l+1):s>=0?e.substr(0,s)+t[s]+r.substr(s+1):null;0>a(e[l],u)&&(s=l)}return o<n.length&&"next"===i?e+r.substr(e.length):o<e.length&&"prev"===i?e.substr(0,r.length):s<0?null:e.substr(0,s)+n[s]+r.substr(s+1)}(a,f,s[m],l[m],o,u);null===y&&null===p?h=m+1:(null===p||o(p,y)>0)&&(p=y)}return r(null!==p?function(){e.continue(p+c)}:n),!1}),p}function t7(e,t,r,n){return{type:2,lower:e,upper:t,lowerOpen:r,upperOpen:n}}function re(e){return{type:1,lower:e,upper:e}}class rt{get Collection(){return this._ctx.table.db.Collection}between(e,t,r,n){r=!1!==r,n=!0===n;try{return this._cmp(e,t)>0||0===this._cmp(e,t)&&(r||n)&&(!r||!n)?t8(this):new this.Collection(this,()=>t7(e,t,!r,!n))}catch(e){return t6(this,tN)}}equals(e){return null==e?t6(this,tN):new this.Collection(this,()=>re(e))}above(e){return null==e?t6(this,tN):new this.Collection(this,()=>t7(e,void 0,!0))}aboveOrEqual(e){return null==e?t6(this,tN):new this.Collection(this,()=>t7(e,void 0,!1))}below(e){return null==e?t6(this,tN):new this.Collection(this,()=>t7(void 0,e,!1,!0))}belowOrEqual(e){return null==e?t6(this,tN):new this.Collection(this,()=>t7(void 0,e))}startsWith(e){return"string"!=typeof e?t6(this,tR):this.between(e,e+tC,!0,!0)}startsWithIgnoreCase(e){return""===e?this.startsWith(e):t9(this,(e,t)=>0===e.indexOf(t[0]),[e],tC)}equalsIgnoreCase(e){return t9(this,(e,t)=>e===t[0],[e],"")}anyOfIgnoreCase(){var e=ed.apply(ec,arguments);return 0===e.length?t8(this):t9(this,(e,t)=>-1!==t.indexOf(e),e,"")}startsWithAnyOfIgnoreCase(){var e=ed.apply(ec,arguments);return 0===e.length?t8(this):t9(this,(e,t)=>t.some(t=>0===e.indexOf(t)),e,tC)}anyOf(){let e=ed.apply(ec,arguments),t=this._cmp;try{e.sort(t)}catch(e){return t6(this,tN)}if(0===e.length)return t8(this);let r=new this.Collection(this,()=>t7(e[0],e[e.length-1]));r._ondirectionchange=r=>{t="next"===r?this._ascending:this._descending,e.sort(t)};let n=0;return r._addAlgorithm((r,a,i)=>{let o=r.key;for(;t(o,e[n])>0;)if(++n===e.length)return a(i),!1;return 0===t(o,e[n])||(a(()=>{r.continue(e[n])}),!1)}),r}notEqual(e){return this.inAnyRange([[tT,e],[e,this.db._maxKey]],{includeLowers:!1,includeUppers:!1})}noneOf(){let e=ed.apply(ec,arguments);if(0===e.length)return new this.Collection(this);try{e.sort(this._ascending)}catch(e){return t6(this,tN)}let t=e.reduce((e,t)=>e?e.concat([[e[e.length-1][1],t]]):[[tT,t]],null);return t.push([e[e.length-1],this.db._maxKey]),this.inAnyRange(t,{includeLowers:!1,includeUppers:!1})}inAnyRange(e,t){let r=this._cmp,n=this._ascending,a=this._descending,i=this._min,o=this._max;if(0===e.length)return t8(this);if(!e.every(e=>void 0!==e[0]&&void 0!==e[1]&&0>=n(e[0],e[1])))return t6(this,"First argument to inAnyRange() must be an Array of two-value Arrays [lower,upper] where upper must not be lower than lower",eE.InvalidArgument);let s=!t||!1!==t.includeLowers,l=t&&!0===t.includeUppers,u,c=n;function d(e,t){return c(e[0],t[0])}try{(u=e.reduce(function(e,t){let n=0,a=e.length;for(;n<a;++n){let a=e[n];if(0>r(t[0],a[1])&&r(t[1],a[0])>0){a[0]=i(a[0],t[0]),a[1]=o(a[1],t[1]);break}}return n===a&&e.push(t),e},[])).sort(d)}catch(e){return t6(this,tN)}let f=0,p=l?e=>n(e,u[f][1])>0:e=>n(e,u[f][1])>=0,h=s?e=>a(e,u[f][0])>0:e=>a(e,u[f][0])>=0,m=p,y=new this.Collection(this,()=>t7(u[0][0],u[u.length-1][1],!s,!l));return y._ondirectionchange=e=>{"next"===e?(m=p,c=n):(m=h,c=a),u.sort(d)},y._addAlgorithm((e,t,r)=>{for(var a=e.key;m(a);)if(++f===u.length)return t(r),!1;return!!(!p(a)&&!h(a))||(0===this._cmp(a,u[f][1])||0===this._cmp(a,u[f][0])||t(()=>{c===n?e.continue(u[f][0]):e.continue(u[f][1])}),!1)}),y}startsWithAnyOf(){let e=ed.apply(ec,arguments);return e.every(e=>"string"==typeof e)?0===e.length?t8(this):this.inAnyRange(e.map(e=>[e,e+tC])):t6(this,"startsWithAnyOf() only works with strings")}}function rr(e){return tl(function(t){return rn(t),e(t.target.error),!1})}function rn(e){e.stopPropagation&&e.stopPropagation(),e.preventDefault&&e.preventDefault()}let ra="storagemutated",ri="x-storagemutated-1",ro=tU(null,ra);class rs{_lock(){return q(!e1.global),++this._reculock,1!==this._reculock||e1.global||(e1.lockOwnerFor=this),this}_unlock(){if(q(!e1.global),0==--this._reculock)for(e1.global||(e1.lockOwnerFor=null);this._blockedFuncs.length>0&&!this._locked();){var e=this._blockedFuncs.shift();try{tj(e[1],e[0])}catch(e){}}return this}_locked(){return this._reculock&&e1.lockOwnerFor!==this}create(e){if(!this.mode)return this;let t=this.db.idbdb,r=this.db._state.dbOpenError;if(q(!this.idbtrans),!e&&!t)switch(r&&r.name){case"DatabaseClosedError":throw new eE.DatabaseClosed(r);case"MissingAPIError":throw new eE.MissingAPI(r.message,r);default:throw new eE.OpenFailed(r)}if(!this.active)throw new eE.TransactionInactive;return q(null===this._completion._state),(e=this.idbtrans=e||(this.db.core?this.db.core.transaction(this.storeNames,this.mode,{durability:this.chromeTransactionDurability}):t.transaction(this.storeNames,this.mode,{durability:this.chromeTransactionDurability}))).onerror=tl(t=>{rn(t),this._reject(e.error)}),e.onabort=tl(t=>{rn(t),this.active&&this._reject(new eE.Abort(e.error)),this.active=!1,this.on("abort").fire(t)}),e.oncomplete=tl(()=>{this.active=!1,this._resolve(),"mutatedParts"in e&&ro.storagemutated.fire(e.mutatedParts)}),this}_promise(e,t,r){if("readwrite"===e&&"readwrite"!==this.mode)return tA(new eE.ReadOnly("Transaction is readonly"));if(!this.active)return tA(new eE.TransactionInactive);if(this._locked())return new e5((n,a)=>{this._blockedFuncs.push([()=>{this._promise(e,t,r).then(n,a)},e1])});if(r)return tm(()=>{var e=new e5((e,r)=>{this._lock();let n=t(e,r,this);n&&n.then&&n.then(e,r)});return e.finally(()=>this._unlock()),e._lib=!0,e});var n=new e5((e,r)=>{var n=t(e,r,this);n&&n.then&&n.then(e,r)});return n._lib=!0,n}_root(){return this.parent?this.parent._root():this}waitFor(e){var t=this._root();let r=e5.resolve(e);if(t._waitingFor)t._waitingFor=t._waitingFor.then(()=>r);else{t._waitingFor=r,t._waitingQueue=[];var n=t.idbtrans.objectStore(t.storeNames[0]);!function e(){for(++t._spinCount;t._waitingQueue.length;)t._waitingQueue.shift()();t._waitingFor&&(n.get(-1/0).onsuccess=e)}()}var a=t._waitingFor;return new e5((e,n)=>{r.then(r=>t._waitingQueue.push(tl(e.bind(null,r))),e=>t._waitingQueue.push(tl(n.bind(null,e)))).finally(()=>{t._waitingFor===a&&(t._waitingFor=null)})})}abort(){this.active&&(this.active=!1,this.idbtrans&&this.idbtrans.abort(),this._reject(new eE.Abort))}table(e){let t=this._memoizedTables||(this._memoizedTables={});if(F(t,e))return t[e];let r=this.schema[e];if(!r)throw new eE.NotFound("Table "+e+" not part of transaction");let n=new this.db.Table(e,r,this);return n.core=this.db.core.table(e),t[e]=n,n}}function rl(e,t,r,n,a,i,o){return{name:e,keyPath:t,unique:r,multi:n,auto:a,compound:i,src:(r&&!o?"&":"")+(n?"*":"")+(a?"++":"")+ru(t)}}function ru(e){return"string"==typeof e?e:e?"["+[].join.call(e,"+")+"]":""}function rc(e,t,r){return{name:e,primKey:t,indexes:r,mappedClass:null,idxByName:X(r,e=>[e.name,e])}}let rd=e=>{try{return e.only([[]]),rd=()=>[[]],[[]]}catch(e){return rd=()=>tC,tC}};function rf(e){return null==e?()=>{}:"string"==typeof e?1===e.split(".").length?t=>t[e]:t=>Z(t,e):t=>Z(t,e)}function rp(e){return[].slice.call(e)}let rh=0;function rm(e){return null==e?":id":"string"==typeof e?e:`[${e.join("+")}]`}function ry({_novip:e},t){let r=t.db,n=function(e,t,{IDBKeyRange:r,indexedDB:n},a){var i;return{dbcore:(i=function(e,t,r){let n;function a(e){if(3===e.type)return null;if(4===e.type)throw Error("Cannot convert never type to IDBKeyRange");let{lower:r,upper:n,lowerOpen:a,upperOpen:i}=e;return void 0===r?void 0===n?null:t.upperBound(n,!!i):void 0===n?t.lowerBound(r,!!a):t.bound(r,n,!!a,!!i)}let{schema:i,hasGetAll:o}=(n=rp(e.objectStoreNames),{schema:{name:e.name,tables:n.map(e=>r.objectStore(e)).map(e=>{let{keyPath:t,autoIncrement:r}=e,n=R(t),a=null==t,i={},o={name:e.name,primaryKey:{name:null,isPrimaryKey:!0,outbound:a,compound:n,keyPath:t,autoIncrement:r,unique:!0,extractKey:rf(t)},indexes:rp(e.indexNames).map(t=>e.index(t)).map(e=>{let{name:t,unique:r,multiEntry:n,keyPath:a}=e,o={name:t,compound:R(a),keyPath:a,unique:r,multiEntry:n,extractKey:rf(a)};return i[rm(a)]=o,o}),getIndexByKeyPath:e=>i[rm(e)]};return i[":id"]=o.primaryKey,null!=t&&(i[rm(t)]=o.primaryKey),o})},hasGetAll:n.length>0&&"getAll"in r.objectStore(n[0])&&!("u">typeof navigator&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604)}),s=i.tables.map(e=>{let t;return{name:t=e.name,schema:e,mutate:function({trans:e,type:r,keys:n,values:i,range:o}){return new Promise((s,l)=>{let u;s=tl(s);let c=e.objectStore(t),d=null==c.keyPath,f="put"===r||"add"===r;if(!f&&"delete"!==r&&"deleteRange"!==r)throw Error("Invalid operation type: "+r);let{length:p}=n||i||{length:1};if(n&&i&&n.length!==i.length)throw Error("Given keys array must have same length as given values array.");if(0===p)return s({numFailures:0,failures:{},results:[],lastResult:void 0});let h=[],m=[],y=0,v=e=>{++y,rn(e)};if("deleteRange"===r){if(4===o.type)return s({numFailures:y,failures:m,results:[],lastResult:void 0});3===o.type?h.push(u=c.clear()):h.push(u=c.delete(a(o)))}else{let[e,t]=f?d?[i,n]:[i,null]:[n,null];if(f)for(let n=0;n<p;++n)h.push(u=t&&void 0!==t[n]?c[r](e[n],t[n]):c[r](e[n])),u.onerror=v;else for(let t=0;t<p;++t)h.push(u=c[r](e[t])),u.onerror=v}let g=e=>{let t=e.target.result;h.forEach((e,t)=>null!=e.error&&(m[t]=e.error)),s({numFailures:y,failures:m,results:"delete"===r?n:h.map(e=>e.result),lastResult:t})};u.onerror=e=>{v(e),g(e)},u.onsuccess=g})},getMany:({trans:e,keys:r})=>new Promise((n,a)=>{n=tl(n);let i=e.objectStore(t),o=r.length,s=Array(o),l,u=0,c=0,d=e=>{let t=e.target;s[t._pos]=t.result,++c===u&&n(s)},f=rr(a);for(let e=0;e<o;++e)null!=r[e]&&((l=i.get(r[e]))._pos=e,l.onsuccess=d,l.onerror=f,++u);0===u&&n(s)}),get:({trans:e,key:r})=>new Promise((n,a)=>{n=tl(n);let i=e.objectStore(t).get(r);i.onsuccess=e=>n(e.target.result),i.onerror=rr(a)}),query:e=>new Promise((r,n)=>{r=tl(r);let{trans:i,values:s,limit:l,query:u}=e,c=l===1/0?void 0:l,{index:d,range:f}=u,p=i.objectStore(t),h=d.isPrimaryKey?p:p.index(d.name),m=a(f);if(0===l)return r({result:[]});if(o){let e=s?h.getAll(m,c):h.getAllKeys(m,c);e.onsuccess=e=>r({result:e.target.result}),e.onerror=rr(n)}else{let e=0,t=!s&&"openKeyCursor"in h?h.openKeyCursor(m):h.openCursor(m),a=[];t.onsuccess=n=>{let i=t.result;return i?(a.push(s?i.value:i.primaryKey),++e===l?r({result:a}):void i.continue()):r({result:a})},t.onerror=rr(n)}}),openCursor:function({trans:e,values:r,query:n,reverse:i,unique:o}){return new Promise((s,l)=>{s=tl(s);let{index:u,range:c}=n,d=e.objectStore(t),f=u.isPrimaryKey?d:d.index(u.name),p=i?o?"prevunique":"prev":o?"nextunique":"next",h=!r&&"openKeyCursor"in f?f.openKeyCursor(a(c),p):f.openCursor(a(c),p);h.onerror=rr(l),h.onsuccess=tl(t=>{let r=h.result;if(!r)return void s(null);r.___id=++rh,r.done=!1;let n=r.continue.bind(r),a=r.continuePrimaryKey;a&&(a=a.bind(r));let i=r.advance.bind(r),o=()=>{throw Error("Cursor not stopped")};r.trans=e,r.stop=r.continue=r.continuePrimaryKey=r.advance=()=>{throw Error("Cursor not started")},r.fail=tl(l),r.next=function(){let e=1;return this.start(()=>e--?this.continue():this.stop()).then(()=>this)},r.start=e=>{let t=new Promise((e,t)=>{e=tl(e),h.onerror=rr(t),r.fail=t,r.stop=t=>{r.stop=r.continue=r.continuePrimaryKey=r.advance=o,e(t)}}),s=()=>{if(h.result)try{e()}catch(e){r.fail(e)}else r.done=!0,r.start=()=>{throw Error("Cursor behind last entry")},r.stop()};return h.onsuccess=tl(e=>{h.onsuccess=s,s()}),r.continue=n,r.continuePrimaryKey=a,r.advance=i,s(),t},s(r)},l)})},count({query:e,trans:r}){let{index:n,range:i}=e;return new Promise((e,o)=>{let s=r.objectStore(t),l=n.isPrimaryKey?s:s.index(n.name),u=a(i),c=u?l.count(u):l.count();c.onsuccess=tl(t=>e(t.target.result)),c.onerror=rr(o)})}}}),l={};return s.forEach(e=>l[e.name]=e),{stack:"dbcore",transaction:e.transaction.bind(e),table(e){if(!l[e])throw Error(`Table '${e}' not found`);return l[e]},MIN_KEY:-1/0,MAX_KEY:rd(t),schema:i}}(t,r,a),e.dbcore.reduce((e,{create:t})=>({...e,...t(e)}),i))}}(e._middlewares,r,e._deps,t);e.core=n.dbcore,e.tables.forEach(t=>{let r=t.name;e.core.schema.tables.some(e=>e.name===r)&&(t.core=e.core.table(r),e[r]instanceof e.Table&&(e[r].core=t.core))})}function rv({_novip:e},t,r,n){r.forEach(r=>{let a=n[r];t.forEach(t=>{let n=U(t,r);(!n||"value"in n&&void 0===n.value)&&(t===e.Transaction.prototype||t instanceof e.Transaction?z(t,r,{get(){return this.table(r)},set(e){V(this,r,{value:e,writable:!0,configurable:!0,enumerable:!0})}}):t[r]=new e.Table(r,a))})})}function rg({_novip:e},t){t.forEach(t=>{for(let r in t)t[r]instanceof e.Table&&delete t[r]})}function rb(e,t){return e._cfg.version-t._cfg.version}function rx(e,t){let r,n={del:[],add:[],change:[]};for(r in e)t[r]||n.del.push(r);for(r in t){let a=e[r],i=t[r];if(a){let e={name:r,def:i,recreate:!1,del:[],add:[],change:[]};if(""+(a.primKey.keyPath||"")==""+(i.primKey.keyPath||"")&&(a.primKey.auto===i.primKey.auto||tI)){let t,r=a.idxByName,o=i.idxByName;for(t in r)o[t]||e.del.push(t);for(t in o){let n=r[t],a=o[t];n?n.src!==a.src&&e.change.push(a):e.add.push(a)}(e.del.length>0||e.add.length>0||e.change.length>0)&&n.change.push(e)}else e.recreate=!0,n.change.push(e)}else n.add.push([r,i])}return n}function rw(e,t,r,n){let a=e.db.createObjectStore(t,r.keyPath?{keyPath:r.keyPath,autoIncrement:r.auto}:{autoIncrement:r.auto});return n.forEach(e=>rS(a,e)),a}function rS(e,t){e.createIndex(t.name,t.keyPath,{unique:t.unique,multiEntry:t.multi})}function rj(e,t,r){let n={};return G(t.objectStoreNames,0).forEach(e=>{let t=r.objectStore(e),a=t.keyPath,i=rl(ru(a),a||"",!1,!1,!!t.autoIncrement,a&&"string"!=typeof a,!0),o=[];for(let e=0;e<t.indexNames.length;++e){let r=t.index(t.indexNames[e]);a=r.keyPath;var s=rl(r.name,a,!!r.unique,!!r.multiEntry,!1,a&&"string"!=typeof a,!1);o.push(s)}n[e]=rc(e,i,o)}),n}function rO({_novip:e},t,r){let n=r.db.objectStoreNames;for(let a=0;a<n.length;++a){let i=n[a],o=r.objectStore(i);e._hasGetAll="getAll"in o;for(let e=0;e<o.indexNames.length;++e){let r=o.indexNames[e],n=o.index(r).keyPath,a="string"==typeof n?n:"["+G(n).join("+")+"]";if(t[i]){let e=t[i].idxByName[a];e&&(e.name=r,delete t[i].idxByName[a],t[i].idxByName[r]=e)}}}"u">typeof navigator&&/Safari/.test(navigator.userAgent)&&!/(Chrome\/|Edge\/)/.test(navigator.userAgent)&&T.WorkerGlobalScope&&T instanceof T.WorkerGlobalScope&&[].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1]<604&&(e._hasGetAll=!1)}class rk{_parseStoresSpec(e,t){N(e).forEach(r=>{if(null!==e[r]){var n=e[r].split(",").map((e,t)=>{let r=(e=e.trim()).replace(/([&*]|\+\+)/g,""),n=/^\[/.test(r)?r.match(/^\[(.*)\]$/)[1].split("+"):r;return rl(r,n||null,/\&/.test(e),/\*/.test(e),/\+\+/.test(e),R(n),0===t)}),a=n.shift();if(a.multi)throw new eE.Schema("Primary key cannot be multi-valued");n.forEach(e=>{if(e.auto)throw new eE.Schema("Only primary key can be marked as autoIncrement (++)");if(!e.keyPath)throw new eE.Schema("Index must have a name and cannot be an empty string")}),t[r]=rc(r,a,n)}})}stores(e){let t=this.db;this._cfg.storesSource=this._cfg.storesSource?M(this._cfg.storesSource,e):e;let r=t._versions,n={},a={};return r.forEach(e=>{M(n,e._cfg.storesSource),a=e._cfg.dbschema={},e._parseStoresSpec(n,a)}),t._dbSchema=a,rg(t,[t._allTables,t,t.Transaction.prototype]),rv(t,[t._allTables,t,t.Transaction.prototype,this._cfg.tables],N(a),a),t._storeNames=N(a),this}upgrade(e){return this._cfg.contentUpgrade=eL(this._cfg.contentUpgrade||eD,e),this}}function rE(e,t){let r=e._dbNamesDB;return r||(r=e._dbNamesDB=new rH(tL,{addons:[],indexedDB:e,IDBKeyRange:t})).version(1).stores({dbnames:"name"}),r.table("dbnames")}function rP(e){return e&&"function"==typeof e.databases}function rA(e){return tm(function(){return e1.letThrough=!0,e()})}function rD(e){var t=t=>e.next(t),r=a(t),n=a(t=>e.throw(t));function a(e){return t=>{var a=e(t),i=a.value;return a.done?i:i&&"function"==typeof i.then?i.then(r,n):R(i)?Promise.all(i).then(r,n):r(i)}}return a(t)()}function rC(e,t,r){var n=arguments.length;if(n<2)throw new eE.InvalidArgument("Too few arguments");for(var a=Array(n-1);--n;)a[n-1]=arguments[n];return r=a.pop(),[e,et(a),r]}function rT(e,t,r){let n=R(e)?e.slice():[e];for(let e=0;e<r;++e)n.push(t);return n}let rN={stack:"dbcore",name:"VirtualIndexMiddleware",level:1,create:function(e){return{...e,table(t){let r=e.table(t),{schema:n}=r,a={},i=[];function o(e,t,r){let n=rm(e),s=a[n]=a[n]||[],l=null==e?0:"string"==typeof e?1:e.length,u=t>0,c={...r,isVirtual:u,keyTail:t,keyLength:l,extractKey:rf(e),unique:!u&&r.unique};return s.push(c),c.isPrimaryKey||i.push(c),l>1&&o(2===l?e[0]:e.slice(0,l-1),t+1,r),s.sort((e,t)=>e.keyTail-t.keyTail),c}let s=o(n.primaryKey.keyPath,0,n.primaryKey);for(let e of(a[":id"]=[s],n.indexes))o(e.keyPath,0,e);function l(t){var r,n;let a=t.query.index;return a.isVirtual?{...t,query:{index:a,range:(r=t.query.range,n=a.keyTail,{type:1===r.type?2:r.type,lower:rT(r.lower,r.lowerOpen?e.MAX_KEY:e.MIN_KEY,n),lowerOpen:!0,upper:rT(r.upper,r.upperOpen?e.MIN_KEY:e.MAX_KEY,n),upperOpen:!0})}}:t}return{...r,schema:{...n,primaryKey:s,indexes:i,getIndexByKeyPath:function(e){let t=a[rm(e)];return t&&t[0]}},count:e=>r.count(l(e)),query:e=>r.query(l(e)),openCursor(t){let{keyTail:n,isVirtual:a,keyLength:i}=t.query.index;return a?r.openCursor(l(t)).then(r=>r&&Object.create(r,{continue:{value:function(a){null!=a?r.continue(rT(a,t.reverse?e.MAX_KEY:e.MIN_KEY,n)):t.unique?r.continue(r.key.slice(0,i).concat(t.reverse?e.MIN_KEY:e.MAX_KEY,n)):r.continue()}},continuePrimaryKey:{value(t,a){r.continuePrimaryKey(rT(t,e.MAX_KEY,n),a)}},primaryKey:{get:()=>r.primaryKey},key:{get(){let e=r.key;return 1===i?e[0]:e.slice(0,i)}},value:{get:()=>r.value}})):r.openCursor(t)}}}}}};function rR(e,t,r,n){return r=r||{},n=n||"",N(e).forEach(a=>{if(F(t,a)){var i=e[a],o=t[a];if("object"==typeof i&&"object"==typeof o&&i&&o){let e=es(i);e!==es(o)?r[n+a]=t[a]:"Object"===e?rR(i,o,r,n+a+"."):i!==o&&(r[n+a]=t[a])}else i!==o&&(r[n+a]=t[a])}else r[n+a]=void 0}),N(t).forEach(a=>{F(e,a)||(r[n+a]=t[a])}),r}let rM={stack:"dbcore",name:"HooksMiddleware",level:2,create:e=>({...e,table(t){let r=e.table(t),{primaryKey:n}=r.schema;return{...r,mutate(e){let a=e1.trans,{deleting:i,creating:o,updating:s}=a.table(t).hook;switch(e.type){case"add":if(o.fire===eD)break;return a._promise("readwrite",()=>l(e),!0);case"put":if(o.fire===eD&&s.fire===eD)break;return a._promise("readwrite",()=>l(e),!0);case"delete":if(i.fire===eD)break;return a._promise("readwrite",()=>l(e),!0);case"deleteRange":if(i.fire===eD)break;return a._promise("readwrite",()=>(function e(t,a,i){return r.query({trans:t,values:!1,query:{index:n,range:a},limit:i}).then(({result:r})=>l({type:"delete",keys:r,trans:t}).then(n=>n.numFailures>0?Promise.reject(n.failures[0]):r.length<i?{failures:[],numFailures:0,lastResult:void 0}:e(t,{...a,lower:r[r.length-1],lowerOpen:!0},i)))})(e.trans,e.range,1e4),!0)}return r.mutate(e);function l(e){var t,a;let l=e1.trans,u=e.keys||("delete"===(t=e).type?t.keys:t.keys||t.values.map(n.extractKey));if(!u)throw Error("Keys missing");return"delete"!==(e="add"===e.type||"put"===e.type?{...e,keys:u}:{...e}).type&&(e.values=[...e.values]),e.keys&&(e.keys=[...e.keys]),("add"===(a=e).type?Promise.resolve([]):r.getMany({trans:a.trans,keys:u,cache:"immutable"})).then(t=>{let a=u.map((r,a)=>{let u=t[a],c={onerror:null,onsuccess:null};if("delete"===e.type)i.fire.call(c,r,u,l);else if("add"===e.type||void 0===u){let t=o.fire.call(c,r,e.values[a],l);null==r&&null!=t&&(r=t,e.keys[a]=r,n.outbound||Q(e.values[a],n.keyPath,r))}else{let t=rR(u,e.values[a]),n=s.fire.call(c,t,r,u,l);if(n){let t=e.values[a];Object.keys(n).forEach(e=>{F(t,e)?t[e]=n[e]:Q(t,e,n[e])})}}return c});return r.mutate(e).then(({failures:r,results:n,numFailures:i,lastResult:o})=>{for(let i=0;i<u.length;++i){let o=n?n[i]:u[i],s=a[i];null==o?s.onerror&&s.onerror(r[i]):s.onsuccess&&s.onsuccess("put"===e.type&&t[i]?e.values[i]:o)}return{failures:r,results:n,numFailures:i,lastResult:o}}).catch(e=>(a.forEach(t=>t.onerror&&t.onerror(e)),Promise.reject(e)))})}}}}})};function rI(e,t,r){try{if(!t||t.keys.length<e.length)return null;let n=[];for(let a=0,i=0;a<t.keys.length&&i<e.length;++a)0===tJ(t.keys[a],e[i])&&(n.push(r?ei(t.values[a]):t.values[a]),++i);return n.length===e.length?n:null}catch(e){return null}}let r_={stack:"dbcore",level:-1,create:e=>({table:t=>{let r=e.table(t);return{...r,getMany:e=>{if(!e.cache)return r.getMany(e);let t=rI(e.keys,e.trans._cache,"clone"===e.cache);return t?e5.resolve(t):r.getMany(e).then(t=>(e.trans._cache={keys:e.keys,values:"clone"===e.cache?ei(t):t},t))},mutate:e=>("add"!==e.type&&(e.trans._cache=null),r.mutate(e))}}})};function rL(e){return!("from"in e)}let rF=function(e,t){if(!this){let t=new rF;return e&&"d"in e&&M(t,e),t}M(this,arguments.length?{d:1,from:e,to:arguments.length>1?t:e}:{d:0})};function rB(e,t,r){let n=tJ(t,r);if(isNaN(n))return;if(n>0)throw RangeError();if(rL(e))return M(e,{from:t,to:r,d:1});let a=e.l,i=e.r;if(0>tJ(r,e.from))return a?rB(a,t,r):e.l={from:t,to:r,d:1,l:null,r:null},rW(e);if(tJ(t,e.to)>0)return i?rB(i,t,r):e.r={from:t,to:r,d:1,l:null,r:null},rW(e);0>tJ(t,e.from)&&(e.from=t,e.l=null,e.d=i?i.d+1:1),tJ(r,e.to)>0&&(e.to=r,e.r=null,e.d=e.l?e.l.d+1:1);let o=!e.r;a&&!e.l&&rV(e,a),i&&o&&rV(e,i)}function rV(e,t){rL(t)||function e(t,{from:r,to:n,l:a,r:i}){rB(t,r,n),a&&e(t,a),i&&e(t,i)}(e,t)}function rz(e){let t=rL(e)?null:{s:0,n:e};return{next(e){let r=arguments.length>0;for(;t;)switch(t.s){case 0:if(t.s=1,r)for(;t.n.l&&0>tJ(e,t.n.from);)t={up:t,n:t.n.l,s:1};else for(;t.n.l;)t={up:t,n:t.n.l,s:1};case 1:if(t.s=2,!r||0>=tJ(e,t.n.to))return{value:t.n,done:!1};case 2:if(t.n.r){t.s=3,t={up:t,n:t.n.r,s:0};continue}case 3:t=t.up}return{done:!0}}}}function rW(e){var t,r;let n=((null==(t=e.r)?void 0:t.d)||0)-((null==(r=e.l)?void 0:r.d)||0),a=n>1?"r":n<-1?"l":"";if(a){let t="r"===a?"l":"r",r={...e},n=e[a];e.from=n.from,e.to=n.to,e[a]=n[a],r[a]=n[t],e[t]=r,r.d=r$(r)}e.d=r$(e)}function r$({r:e,l:t}){return(e?t?Math.max(e.d,t.d):e.d:t?t.d:0)+1}B(rF.prototype,{add(e){return rV(this,e),this},addKey(e){return rB(this,e,e),this},addKeys(e){return e.forEach(e=>rB(this,e,e)),this},[el](){return rz(this)}});let rU={stack:"dbcore",level:0,create:e=>{let t=e.schema.name,r=new rF(e.MIN_KEY,e.MAX_KEY);return{...e,table:n=>{let a=e.table(n),{schema:i}=a,{primaryKey:o}=i,{extractKey:s,outbound:l}=o,u={...a,mutate:e=>{let o=e.trans,s=o.mutatedParts||(o.mutatedParts={}),l=e=>{let r=`idb://${t}/${n}/${e}`;return s[r]||(s[r]=new rF)},u=l(""),c=l(":dels"),{type:d}=e,[f,p]="deleteRange"===e.type?[e.range]:"delete"===e.type?[e.keys]:e.values.length<50?[[],e.values]:[],h=e.trans._cache;return a.mutate(e).then(e=>{if(R(f)){"delete"!==d&&(f=e.results),u.addKeys(f);let t=rI(f,h);t||"add"===d||c.addKeys(f),(t||p)&&i.indexes.forEach(function(e){let r=l(e.name||"");function n(t){return null!=t?e.extractKey(t):null}let a=t=>e.multiEntry&&R(t)?t.forEach(e=>r.addKey(e)):r.addKey(t);(t||p).forEach((e,r)=>{let i=t&&n(t[r]),o=p&&n(p[r]);0!==tJ(i,o)&&(null!=i&&a(i),null!=o&&a(o))})})}else if(f){let e={from:f.lower,to:f.upper};c.add(e),u.add(e)}else u.add(r),c.add(r),i.indexes.forEach(e=>l(e.name).add(r));return e})}},c=({query:{index:t,range:r}})=>{var n,a;return[t,new rF(null!=(n=r.lower)?n:e.MIN_KEY,null!=(a=r.upper)?a:e.MAX_KEY)]},d={get:e=>[o,new rF(e.key)],getMany:e=>[o,(new rF).addKeys(e.keys)],count:c,query:c,openCursor:c};return N(d).forEach(e=>{u[e]=function(i){let{subscr:o}=e1;if(o){let u=e=>{let r=`idb://${t}/${n}/${e}`;return o[r]||(o[r]=new rF)},c=u(""),f=u(":dels"),[p,h]=d[e](i);if(u(p.name||"").add(h),!p.isPrimaryKey){if("count"!==e){let t="query"===e&&l&&i.values&&a.query({...i,values:!1});return a[e].apply(this,arguments).then(r=>{if("query"===e){if(l&&i.values)return t.then(({result:e})=>(c.addKeys(e),r));let e=i.values?r.result.map(s):r.result;i.values?c.addKeys(e):f.addKeys(e)}else if("openCursor"===e){let e=i.values;return r&&Object.create(r,{key:{get:()=>(f.addKey(r.primaryKey),r.key)},primaryKey:{get(){let e=r.primaryKey;return f.addKey(e),e}},value:{get:()=>(e&&c.addKey(r.primaryKey),r.value)}})}return r})}f.add(r)}}return a[e].apply(this,arguments)}}),u}}}};class rH{constructor(e,t){var r;this._middlewares={},this.verno=0;const n=rH.dependencies;this._options=t={addons:rH.addons,autoOpen:!0,indexedDB:n.indexedDB,IDBKeyRange:n.IDBKeyRange,...t},this._deps={indexedDB:t.indexedDB,IDBKeyRange:t.IDBKeyRange};const{addons:a}=t;this._dbSchema={},this._versions=[],this._storeNames=[],this._allTables={},this.idbdb=null,this._novip=this;const i={dbOpenError:null,isBeingOpened:!1,onReadyBeingFired:null,openComplete:!1,dbReadyResolve:eD,dbReadyPromise:null,cancelOpen:eD,openCanceller:null,autoSchema:!0,PR1398_maxLoop:3};i.dbReadyPromise=new e5(e=>{i.dbReadyResolve=e}),i.openCanceller=new e5((e,t)=>{i.cancelOpen=t}),this._state=i,this.name=e,this.on=tU(this,"populate","blocked","versionchange","close",{ready:[eL,eD]}),this.on.ready.subscribe=K(this.on.ready.subscribe,e=>(t,r)=>{rH.vip(()=>{let n=this._state;if(n.openComplete)n.dbOpenError||e5.resolve().then(t),r&&e(t);else if(n.onReadyBeingFired)n.onReadyBeingFired.push(t),r&&e(t);else{e(t);let n=this;r||e(function e(){n.on.ready.unsubscribe(t),n.on.ready.unsubscribe(e)})}})}),this.Collection=(r=this,tH(t2.prototype,function(e,t){this.db=r;let n=tz,a=null;if(t)try{n=t()}catch(e){a=e}let i=e._ctx,o=i.table,s=o.hook.reading.fire;this._ctx={table:o,index:i.index,isPrimKey:!i.index||o.schema.primKey.keyPath&&i.index===o.schema.primKey.name,range:n,keysOnly:!1,dir:"next",unique:"",algorithm:null,filter:null,replayFilter:null,justLimit:!0,isMatch:null,offset:0,limit:1/0,error:a,or:i.or,valueMapper:s!==eC?s:null}})),this.Table=function(e){return tH(t$.prototype,function(t,r,n){this.db=e,this._tx=n,this.name=t,this.schema=r,this.hook=e._allTables[t]?e._allTables[t].hook:tU(null,{creating:[eR,eD],reading:[eT,eC],updating:[eI,eD],deleting:[eM,eD]})})}(this),this.Transaction=function(e){return tH(rs.prototype,function(t,r,n,a,i){this.db=e,this.mode=t,this.storeNames=r,this.schema=n,this.chromeTransactionDurability=a,this.idbtrans=null,this.on=tU(this,"complete","error","abort"),this.parent=i||null,this.active=!0,this._reculock=0,this._blockedFuncs=[],this._resolve=null,this._reject=null,this._waitingFor=null,this._waitingQueue=null,this._spinCount=0,this._completion=new e5((e,t)=>{this._resolve=e,this._reject=t}),this._completion.then(()=>{this.active=!1,this.on.complete.fire()},e=>{var t=this.active;return this.active=!1,this.on.error.fire(e),this.parent?this.parent._reject(e):t&&this.idbtrans&&this.idbtrans.abort(),tA(e)})})}(this),this.Version=function(e){return tH(rk.prototype,function(t){this.db=e,this._cfg={version:t,storesSource:null,dbschema:{},tables:{},contentUpgrade:null}})}(this),this.WhereClause=function(e){return tH(rt.prototype,function(t,r,n){this.db=e,this._ctx={table:t,index:":id"===r?null:r,or:n};let a=e._deps.indexedDB;if(!a)throw new eE.MissingAPI;this._cmp=this._ascending=a.cmp.bind(a),this._descending=(e,t)=>a.cmp(t,e),this._max=(e,t)=>a.cmp(e,t)>0?e:t,this._min=(e,t)=>0>a.cmp(e,t)?e:t,this._IDBKeyRange=e._deps.IDBKeyRange})}(this),this.on("versionchange",e=>{e.newVersion>0?console.warn(`Another connection wants to upgrade database '${this.name}'. Closing db now to resume the upgrade.`):console.warn(`Another connection wants to delete database '${this.name}'. Closing db now to resume the delete request.`),this.close()}),this.on("blocked",e=>{!e.newVersion||e.newVersion<e.oldVersion?console.warn(`Dexie.delete('${this.name}') was blocked`):console.warn(`Upgrade '${this.name}' blocked by other connection holding version ${e.oldVersion/10}`)}),this._maxKey=rd(t.IDBKeyRange),this._createTransaction=(e,t,r,n)=>new this.Transaction(e,t,r,this._options.chromeTransactionDurability,n),this._fireOnBlocked=e=>{this.on("blocked").fire(e),tM.filter(e=>e.name===this.name&&e!==this&&!e._state.vcFired).map(t=>t.on("versionchange").fire(e))},this.use(rN),this.use(rM),this.use(rU),this.use(r_),this.vip=Object.create(this,{_vip:{value:!0}}),a.forEach(e=>e(this))}version(e){if(isNaN(e)||e<.1)throw new eE.Type("Given version is not a positive number");if(e=Math.round(10*e)/10,this.idbdb||this._state.isBeingOpened)throw new eE.Schema("Cannot add version when database is open");this.verno=Math.max(this.verno,e);let t=this._versions;var r=t.filter(t=>t._cfg.version===e)[0];return r||(r=new this.Version(e),t.push(r),t.sort(rb),r.stores({}),this._state.autoSchema=!1,r)}_whenReady(e){return this.idbdb&&(this._state.openComplete||e1.letThrough||this._vip)?e():new e5((e,t)=>{if(this._state.openComplete)return t(new eE.DatabaseClosed(this._state.dbOpenError));if(!this._state.isBeingOpened){if(!this._options.autoOpen)return void t(new eE.DatabaseClosed);this.open().catch(eD)}this._state.dbReadyPromise.then(e,t)}).then(e)}use({stack:e,create:t,level:r,name:n}){n&&this.unuse({stack:e,name:n});let a=this._middlewares[e]||(this._middlewares[e]=[]);return a.push({stack:e,create:t,level:null==r?10:r,name:n}),a.sort((e,t)=>e.level-t.level),this}unuse({stack:e,name:t,create:r}){return e&&this._middlewares[e]&&(this._middlewares[e]=this._middlewares[e].filter(e=>r?e.create!==r:!!t&&e.name!==t)),this}open(){return function(e){var t;let r=e._state,{indexedDB:n}=e._deps;if(r.isBeingOpened||e.idbdb)return r.dbReadyPromise.then(()=>r.dbOpenError?tA(r.dbOpenError):e);ep&&(r.openCanceller._stackHolder=ey()),r.isBeingOpened=!0,r.dbOpenError=null,r.openComplete=!1;let a=r.openCanceller;function i(){if(r.openCanceller!==a)throw new eE.DatabaseClosed("db.open() was cancelled")}let o=r.dbReadyResolve,s=null,l=!1,u=()=>new e5((t,a)=>{if(i(),!n)throw new eE.MissingAPI;let o=e.name,u=r.autoSchema?n.open(o):n.open(o,Math.round(10*e.verno));if(!u)throw new eE.MissingAPI;u.onerror=rr(a),u.onblocked=tl(e._fireOnBlocked),u.onupgradeneeded=tl(t=>{if(s=u.transaction,r.autoSchema&&!e._options.allowEmptyDB){u.onerror=rn,s.abort(),u.result.close();let e=n.deleteDatabase(o);e.onsuccess=e.onerror=tl(()=>{a(new eE.NoSuchDatabase(`Database ${o} doesnt exist`))})}else{let r,n,o,f;s.onerror=rr(a);var i,c,d=t.oldVersion>0x4000000000000000?0:t.oldVersion;l=d<1,e._novip.idbdb=u.result,i=d/10,c=s,r=e._dbSchema,(n=e._createTransaction("readwrite",e._storeNames,r)).create(c),n._completion.catch(a),o=n._reject.bind(n),f=e1.transless||e1,tm(()=>{e1.trans=n,e1.transless=f,0===i?(N(r).forEach(e=>{rw(c,e,r[e].primKey,r[e].indexes)}),ry(e,c),e5.follow(()=>e.on.populate.fire(n)).catch(o)):(function({_novip:e},t,r,n){let a=[],i=e._versions,o=e._dbSchema=rj(e,e.idbdb,n),s=!1;return i.filter(e=>e._cfg.version>=t).forEach(i=>{a.push(()=>{let a=o,l=i._cfg.dbschema;rO(e,a,n),rO(e,l,n),o=e._dbSchema=l;let u=rx(a,l);u.add.forEach(e=>{rw(n,e[0],e[1].primKey,e[1].indexes)}),u.change.forEach(e=>{if(e.recreate)throw new eE.Upgrade("Not yet support for changing primary key");{let t=n.objectStore(e.name);e.add.forEach(e=>rS(t,e)),e.change.forEach(e=>{t.deleteIndex(e.name),rS(t,e)}),e.del.forEach(e=>t.deleteIndex(e))}});let c=i._cfg.contentUpgrade;if(c&&i._cfg.version>t){let t;ry(e,n),r._memoizedTables={},s=!0;let i=J(l);u.del.forEach(e=>{i[e]=a[e]}),rg(e,[e.Transaction.prototype]),rv(e,[e.Transaction.prototype],N(i),i),r.schema=i;let o=ef(c);o&&ty();let d=e5.follow(()=>{if((t=c(r))&&o){var e=tv.bind(null,null);t.then(e,e)}});return t&&"function"==typeof t.then?e5.resolve(t):d.then(()=>t)}}),a.push(t=>{var n;s&&tI||(n=i._cfg.dbschema,[].slice.call(t.db.objectStoreNames).forEach(e=>null==n[e]&&t.db.deleteObjectStore(e))),rg(e,[e.Transaction.prototype]),rv(e,[e.Transaction.prototype],e._storeNames,e._dbSchema),r.schema=e._dbSchema})}),(function e(){return a.length?e5.resolve(a.shift()(r.idbtrans)).then(e):e5.resolve()})().then(()=>{var e;N(e=o).forEach(t=>{n.db.objectStoreNames.contains(t)||rw(n,t,e[t].primKey,e[t].indexes)})})})(e,i,n,c).catch(o)})}},a),u.onsuccess=tl(()=>{s=null;let n=e._novip.idbdb=u.result,a=G(n.objectStoreNames);if(a.length>0)try{let t,i=n.transaction(1===a.length?a[0]:a,"readonly");r.autoSchema?function({_novip:e},t,r){e.verno=t.version/10;let n=e._dbSchema=rj(0,t,r);e._storeNames=G(t.objectStoreNames,0),rv(e,[e._allTables],N(n),n)}(e,n,i):(rO(e,e._dbSchema,i),((t=rx(rj(0,e.idbdb,i),e._dbSchema)).add.length||t.change.some(e=>e.add.length||e.change.length))&&console.warn("Dexie SchemaDiff: Schema was extended without increasing the number passed to db.version(). Some queries may fail.")),ry(e,i)}catch(e){}tM.push(e),n.onversionchange=tl(t=>{r.vcFired=!0,e.on("versionchange").fire(t)}),n.onclose=tl(t=>{e.on("close").fire(t)}),l&&function({indexedDB:e,IDBKeyRange:t},r){rP(e)||r===tL||rE(e,t).put({name:r}).catch(eD)}(e._deps,o),t()},a)}).catch(e=>e&&"UnknownError"===e.name&&r.PR1398_maxLoop>0?(r.PR1398_maxLoop--,console.warn("Dexie: Workaround for Chrome UnknownError on open()"),u()):e5.reject(e));return e5.race([a,("u"<typeof navigator?e5.resolve():!navigator.userAgentData&&/Safari\//.test(navigator.userAgent)&&!/Chrom(e|ium)\//.test(navigator.userAgent)&&indexedDB.databases?new Promise(function(e){var r=function(){return indexedDB.databases().finally(e)};t=setInterval(r,100),r()}).finally(function(){return clearInterval(t)}):Promise.resolve()).then(u)]).then(()=>(i(),r.onReadyBeingFired=[],e5.resolve(rA(()=>e.on.ready.fire(e.vip))).then(function t(){if(r.onReadyBeingFired.length>0){let n=r.onReadyBeingFired.reduce(eL,eD);return r.onReadyBeingFired=[],e5.resolve(rA(()=>n(e.vip))).then(t)}}))).finally(()=>{r.onReadyBeingFired=null,r.isBeingOpened=!1}).then(()=>e).catch(t=>{r.dbOpenError=t;try{s&&s.abort()}catch(e){}return a===r.openCanceller&&e._close(),tA(t)}).finally(()=>{r.openComplete=!0,o()})}(this)}_close(){let e=this._state,t=tM.indexOf(this);if(t>=0&&tM.splice(t,1),this.idbdb){try{this.idbdb.close()}catch(e){}this._novip.idbdb=null}e.dbReadyPromise=new e5(t=>{e.dbReadyResolve=t}),e.openCanceller=new e5((t,r)=>{e.cancelOpen=r})}close(){this._close();let e=this._state;this._options.autoOpen=!1,e.dbOpenError=new eE.DatabaseClosed,e.isBeingOpened&&e.cancelOpen(e.dbOpenError)}delete(){let e=arguments.length>0,t=this._state;return new e5((r,n)=>{let a=()=>{this.close();var e=this._deps.indexedDB.deleteDatabase(this.name);e.onsuccess=tl(()=>{!function({indexedDB:e,IDBKeyRange:t},r){rP(e)||r===tL||rE(e,t).delete(r).catch(eD)}(this._deps,this.name),r()}),e.onerror=rr(n),e.onblocked=this._fireOnBlocked};if(e)throw new eE.InvalidArgument("Arguments not allowed in db.delete()");t.isBeingOpened?t.dbReadyPromise.then(a):a()})}backendDB(){return this.idbdb}isOpen(){return null!==this.idbdb}hasBeenClosed(){let e=this._state.dbOpenError;return e&&"DatabaseClosed"===e.name}hasFailed(){return null!==this._state.dbOpenError}dynamicallyOpened(){return this._state.autoSchema}get tables(){return N(this._allTables).map(e=>this._allTables[e])}transaction(){let e=rC.apply(this,arguments);return this._transaction.apply(this,e)}_transaction(e,t,r){let n,a,i=e1.trans;i&&i.db===this&&-1===e.indexOf("!")||(i=null);let o=-1!==e.indexOf("?");e=e.replace("!","").replace("?","");try{if(a=t.map(e=>{var t=e instanceof this.Table?e.name:e;if("string"!=typeof t)throw TypeError("Invalid table argument to Dexie.transaction(). Only Table or String are allowed");return t}),"r"==e||e===tF)n=tF;else{if("rw"!=e&&e!=tB)throw new eE.InvalidArgument("Invalid transaction mode: "+e);n=tB}if(i){if(i.mode===tF&&n===tB){if(!o)throw new eE.SubTransaction("Cannot enter a sub-transaction with READWRITE mode when parent transaction is READONLY");i=null}i&&a.forEach(e=>{if(i&&-1===i.storeNames.indexOf(e)){if(!o)throw new eE.SubTransaction("Table "+e+" not included in parent transaction.");i=null}}),o&&i&&!i.active&&(i=null)}}catch(e){return i?i._promise(null,(t,r)=>{r(e)}):tA(e)}let s=(function e(t,r,n,a,i){return e5.resolve().then(()=>{let o,s=e1.transless||e1,l=t._createTransaction(r,n,t._dbSchema,a);if(a)l.idbtrans=a.idbtrans;else try{l.create(),t._state.PR1398_maxLoop=3}catch(a){return a.name===ek.InvalidState&&t.isOpen()&&--t._state.PR1398_maxLoop>0?(console.warn("Dexie: Need to reopen db"),t._close(),t.open().then(()=>e(t,r,n,null,i))):tA(a)}let u=ef(i);u&&ty();let c=e5.follow(()=>{if(o=i.call(l,l))if(u){var e=tv.bind(null,null);o.then(e,e)}else"function"==typeof o.next&&"function"==typeof o.throw&&(o=rD(o))},{trans:l,transless:s});return(o&&"function"==typeof o.then?e5.resolve(o).then(e=>l.active?e:tA(new eE.PrematureCommit("Transaction committed too early. See http://bit.ly/2kdckMn"))):c.then(()=>o)).then(e=>(a&&l._resolve(),l._completion.then(()=>e))).catch(e=>(l._reject(e),tA(e)))})}).bind(null,this,n,a,i,r);return i?i._promise(n,s,"lock"):e1.trans?tj(e1.transless,()=>this._whenReady(s)):this._whenReady(s)}table(e){if(!F(this._allTables,e))throw new eE.InvalidTable(`Table ${e} does not exist`);return this._allTables[e]}}let rG="u">typeof Symbol&&"observable"in Symbol?Symbol.observable:"@@observable";class rK{constructor(e){this._subscribe=e}subscribe(e,t,r){return this._subscribe(e&&"function"!=typeof e?e:{next:e,error:t,complete:r})}[rG](){return this}}function rq(e,t){return N(t).forEach(r=>{rV(e[r]||(e[r]=new rF),t[r])}),e}try{n={indexedDB:T.indexedDB||T.mozIndexedDB||T.webkitIndexedDB||T.msIndexedDB,IDBKeyRange:T.IDBKeyRange||T.webkitIDBKeyRange}}catch(e){n={indexedDB:null,IDBKeyRange:null}}function rY(e){let t=rX;try{rX=!0,ro.storagemutated.fire(e)}finally{rX=t}}B(rH,{...eA,delete:e=>new rH(e,{addons:[]}).delete(),exists:e=>new rH(e,{addons:[]}).open().then(e=>(e.close(),!0)).catch("NoSuchDatabaseError",()=>!1),getDatabaseNames(e){try{return(function({indexedDB:e,IDBKeyRange:t}){return rP(e)?Promise.resolve(e.databases()).then(e=>e.map(e=>e.name).filter(e=>e!==tL)):rE(e,t).toCollection().primaryKeys()})(rH.dependencies).then(e)}catch(e){return tA(new eE.MissingAPI)}},defineClass:()=>function(e){M(this,e)},ignoreTransaction:e=>e1.trans?tj(e1.transless,e):e(),vip:rA,async:function(e){return function(){try{var t=rD(e.apply(this,arguments));return t&&"function"==typeof t.then?t:e5.resolve(t)}catch(e){return tA(e)}}},spawn:function(e,t,r){try{var n=rD(e.apply(r,t||[]));return n&&"function"==typeof n.then?n:e5.resolve(n)}catch(e){return tA(e)}},currentTransaction:{get:()=>e1.trans||null},waitFor:function(e,t){let r=e5.resolve("function"==typeof e?rH.ignoreTransaction(e):e).timeout(t||6e4);return e1.trans?e1.trans.waitFor(r):r},Promise:e5,debug:{get:()=>ep,set:e=>{ep=e,eh="dexie"===e?()=>!0:t_}},derive:W,extend:M,props:B,override:K,Events:tU,on:ro,liveQuery:function(e){let t,r=!1,n=new rK(n=>{let a=ef(e),i=!1,o={},s={},l={get closed(){return i},unsubscribe:()=>{i=!0,ro.storagemutated.unsubscribe(f)}};n.start&&n.start(l);let u=!1,c=!1;function d(){return N(s).some(e=>o[e]&&function(e,t){let r=rz(t),n=r.next();if(n.done)return!1;let a=n.value,i=rz(e),o=i.next(a.from),s=o.value;for(;!n.done&&!o.done;){if(0>=tJ(s.from,a.to)&&tJ(s.to,a.from)>=0)return!0;0>tJ(a.from,s.from)?a=(n=r.next(s.from)).value:s=(o=i.next(a.from)).value}return!1}(o[e],s[e]))}let f=e=>{rq(o,e),d()&&p()},p=()=>{let h,m;if(u||i)return;o={};let y={},v=(a&&ty(),h=()=>tm(e,{subscr:y,trans:null}),m=e1.trans?tj(e1.transless,h):h(),a&&m.then(tv,tv),m);c||(ro(ra,f),c=!0),u=!0,Promise.resolve(v).then(e=>{r=!0,t=e,u=!1,i||(d()?p():(o={},s=y,n.next&&n.next(e)))},e=>{u=!1,r=!1,n.error&&n.error(e),l.unsubscribe()})};return p(),l});return n.hasValue=()=>r,n.getValue=()=>t,n},extendObservabilitySet:rq,getByKeyPath:Z,setByKeyPath:Q,delByKeyPath:function(e,t){"string"==typeof t?Q(e,t,void 0):"length"in t&&[].map.call(t,function(t){Q(e,t,void 0)})},shallowClone:J,deepClone:ei,getObjectDiff:rR,cmp:tJ,asap:Y,minKey:tT,addons:[],connections:tM,errnames:ek,dependencies:n,semVer:tD,version:tD.split(".").map(e=>parseInt(e)).reduce((e,t,r)=>e+t/Math.pow(10,2*r))}),rH.maxKey=rd(rH.dependencies.IDBKeyRange),"u">typeof dispatchEvent&&"u">typeof addEventListener&&(ro(ra,e=>{if(!rX){let t;tI?(t=document.createEvent("CustomEvent")).initCustomEvent(ri,!0,!0,e):t=new CustomEvent(ri,{detail:e}),rX=!0,dispatchEvent(t),rX=!1}}),addEventListener(ri,({detail:e})=>{rX||rY(e)}));let rX=!1;if("u">typeof BroadcastChannel){let e=new BroadcastChannel(ri);"function"==typeof e.unref&&e.unref(),ro(ra,t=>{rX||e.postMessage(t)}),e.onmessage=e=>{e.data&&rY(e.data)}}else if("u">typeof self&&"u">typeof navigator){ro(ra,e=>{try{rX||("u">typeof localStorage&&localStorage.setItem(ri,JSON.stringify({trig:Math.random(),changedParts:e})),"object"==typeof self.clients&&[...self.clients.matchAll({includeUncontrolled:!0})].forEach(t=>t.postMessage({type:ri,changedParts:e})))}catch(e){}}),"u">typeof addEventListener&&addEventListener("storage",e=>{if(e.key===ri){let t=JSON.parse(e.newValue);t&&rY(t.changedParts)}});let e=self.document&&navigator.serviceWorker;e&&e.addEventListener("message",function({data:e}){e&&e.type===ri&&rY(e.changedParts)})}e5.rejectionMapper=function(e,t){if(!e||e instanceof ew||e instanceof TypeError||e instanceof SyntaxError||!e.name||!eP[e.name])return e;var r=new eP[e.name](t||e.message,e);return"stack"in e&&z(r,"stack",{get:function(){return this.inner.stack}}),r},eh=t_;var rZ=r(70),rQ=r(1442);function rJ(e){return(rJ=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function r0(e,t){return(r0=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function r1(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(r1=function(){return!!e})()}function r2(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var r3=function(e){if("function"!=typeof e&&null!==e)throw TypeError("Super expression must either be null or a function");function t(){var e,r,n;if(!(this instanceof t))throw TypeError("Cannot call a class as a function");return n=["EsmOffline"],r=rJ(r=t),r2(e=function(e,t){var r;if(t&&("object"==((r=t)&&"u">typeof Symbol&&r.constructor===Symbol?"symbol":typeof r)||"function"==typeof t))return t;if(void 0===e)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(this,r1()?Reflect.construct(r,n||[],rJ(this).constructor):r.apply(this,n)),"syncQueue",void 0),r2(e,"dynamicOfflineData",void 0),e.version(4).stores({syncQueue:"++id,userId,type,[userId+type]",dynamicOfflineData:"++id,type,identifier,*users,&[type+identifier]"}),e.syncQueue=e.table("syncQueue"),e.dynamicOfflineData=e.table("dynamicOfflineData"),e}return t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&r0(t,e),t}(rH);function r4(){return new r3}function r5(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function r6(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function r8(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){r6(i,n,a,o,s,"next",e)}function s(e){r6(i,n,a,o,s,"throw",e)}o(void 0)})}}function r9(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r,n,a=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=a){var i=[],o=!0,s=!1;try{for(a=a.call(e);!(o=(r=a.next()).done)&&(i.push(r.value),!t||i.length!==t);o=!0);}catch(e){s=!0,n=e}finally{try{o||null==a.return||a.return()}finally{if(s)throw n}}return i}}(e,t)||function(e,t){if(e){if("string"==typeof e)return r5(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if("Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r)return Array.from(r);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return r5(e,t)}}(e,t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function r7(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var ne=new r3,nt={},nr=(0,rQ.createGlobalStore)("offline-synchronization",{});function nn(){return nr}function na(){return r8(function(){var e,t,r,n,a,i,o,s,l,u,c,d,f;return r7(this,function(p){switch(p.label){case 0:if(nr.getState().synchronization)return[2];return[4,ne.syncQueue.count()];case 1:e=p.sent(),t={},n=(r=Object.entries(nt)).length,a={},i=new AbortController,o=function(){var e,t,r=nr.getState().synchronization;nr.setState({synchronization:(e=function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}({},r),t=t={pendingCount:r.pendingCount-1},Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}),e)})},p.label=2;case 2:p.trys.push([2,,10,11]),nr.setState({synchronization:{totalCount:e,pendingCount:e,abortController:i}}),s=0,p.label=3;case 3:if(!(s<n&&r.length>0))return[3,8];l=r.length,p.label=4;case 4:if(!l--)return[3,7];if(c=(u=r9(r[l],2))[0],!(f=(d=u[1]).dependsOn.map(function(e){return t[e]})).every(Boolean))return[3,6];return a[c]={},[4,Promise.all(f)];case 5:p.sent(),t[c]=function(e,t,r,n){return r8(function(e,t,r,n){var a,i,o,s,l,u,c,d,f,p,h,m,y,v,g,b,x;return r7(this,function(w){switch(w.label){case 0:return a=e.type,i=e.dependsOn,o=e.process,s=[],l=[],[4,ni()];case 1:return u=w.sent(),[4,ne.syncQueue.where({type:a,userId:u}).each(function(e,t){s.push([t.primaryKey,e.content,e.descriptor]),l.push(e.content)})];case 2:w.sent(),c=0,w.label=3;case 3:if(!(c<s.length))return[3,11];f=(d=r9(s[c],3))[0],p=d[1],m=(h=d[2]).id,v=void 0===(y=h.dependencies)?[]:y,w.label=4;case 4:return w.trys.push([4,7,9,10]),[4,o(p,{abort:r,index:c,items:l,userId:u,dependencies:v.map(function(e){var r=e.id,n=e.type;return i.includes(n)?t[n][r]:void 0})})];case 5:return g=w.sent(),void 0!==m&&(t[a][m]=g),[4,ne.syncQueue.delete(f)];case 6:case 8:return w.sent(),[3,10];case 7:var S,j;return S=b=w.sent(),x=(null!=(j=Error)&&"u">typeof Symbol&&j[Symbol.hasInstance]?!!j[Symbol.hasInstance](S):S instanceof j)?b:{name:"UnknownError",message:String(b)},[4,ne.syncQueue.update(f,{lastError:{name:x.name,message:x.message}})];case 9:return n(),[7];case 10:return c++,[3,3];case 11:return[2]}})}).apply(this,arguments)}(d,a,i,o),r.splice(l,1),p.label=6;case 6:return[3,4];case 7:return s++,[3,3];case 8:return[4,Promise.allSettled(Object.values(t))];case 9:return p.sent(),[3,11];case 10:return nr.setState({synchronization:void 0}),[7];case 11:return[2]}})})()}function ni(){return r8(function(){var e;return r7(this,function(t){switch(t.label){case 0:return[4,(0,rZ.getLoggedInUser)()];case 1:return[2,(null==(e=t.sent())?void 0:e.uuid)||"*"]}})})()}function no(e,t,r,n){return r8(function(){var a;return r7(this,function(i){switch(i.label){case 0:if(void 0===(a=n&&n.id))return[3,2];return[4,ne.syncQueue.where({type:t,userId:e}).filter(function(e){return(null==e?void 0:e.descriptor.id)===a}).delete().catch(rH.errnames.DatabaseClosed)];case 1:i.sent(),i.label=2;case 2:return[4,ne.syncQueue.add({type:t,content:r,userId:e,descriptor:n||{},createdOn:new Date}).catch(rH.errnames.DatabaseClosed,function(){return -1})];case 3:return[2,i.sent()]}})})()}function ns(e,t,r){return r8(function(){return r7(this,function(n){switch(n.label){case 0:return[4,ni()];case 1:return[4,no(n.sent(),e,t,r)];case 2:return[2,n.sent()]}})})()}function nl(e,t){return r8(function(){return r7(this,function(r){switch(r.label){case 0:return[4,nu(e,t)];case 1:return[2,r.sent().map(function(e){return e.content})]}})})()}function nu(e,t){return r8(function(){var r;return r7(this,function(n){switch(n.label){case 0:return r=t?{type:t,userId:e}:{userId:e},[4,ne.syncQueue.where(r).toArray().catch(rH.errnames.DatabaseClosed,function(){return[]})];case 1:return[2,n.sent()]}})})()}function nc(e){return r8(function(){return r7(this,function(t){switch(t.label){case 0:return[4,ni()];case 1:return[4,nl(t.sent(),e)];case 2:return[2,t.sent()]}})})()}function nd(e){return r8(function(){return r7(this,function(t){switch(t.label){case 0:return[4,ni()];case 1:return[4,nu(t.sent(),e)];case 2:return[2,t.sent()]}})})()}function nf(e){return r8(function(){return r7(this,function(t){switch(t.label){case 0:return[4,ne.syncQueue.get(e).catch(rH.errnames.DatabaseClosed,function(){})];case 1:return[2,t.sent()]}})})()}function np(e){var t;return!!(null==(t=nt[e])?void 0:t.options.onBeginEditSyncItem)}function nh(e){return r8(function(){var t,r,n;return r7(this,function(a){switch(a.label){case 0:return[4,nf(e)];case 1:if(!(r=a.sent()))throw Error("No sync item with the ID ".concat(e," exists."));if(!(n=null==(t=nt[r.type])?void 0:t.options.onBeginEditSyncItem))throw Error("A sync item with the ID ".concat(e,' exists, but the associated handler (if one exists) doesn\'t support editing the item. You can avoid this error by either verifying that sync items of this type can be edited via the "canEditSynchronizationItemsOfType(type: string)" function or alternatively ensure that the synchronizaton handler for sync items of type "').concat(r.type,'" supports editing items.'));return n(r),[2]}})})()}function nm(e){return r8(function(){return r7(this,function(t){switch(t.label){case 0:return[4,ne.syncQueue.delete(e).catch(rH.errnames.DatabaseClosed)];case 1:return t.sent(),[2]}})})()}function ny(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};nt[e]={type:e,dependsOn:t,process:r,options:n}}var nv=r(1400),ng="OFFLINE+";function nb(){return ng+(0,nv.A)()}function nx(e){return e.startsWith(ng)}function nw(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function nS(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function nj(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){nS(i,n,a,o,s,"next",e)}function s(e){nS(i,n,a,o,s,"throw",e)}o(void 0)})}}function nO(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var nk={};function nE(){return Object.values(nk)}function nP(e){nk[e.id]&&console.warn('[setupDynamicOfflineDataHandler] Another second handler with the ID "'.concat(e.id,'" was registered. This handler will override the previous one. This could be unintended as the previous handler might run different flows than the newly registered one. If this is the case, ensure that you are setting up the handlers with different IDs.')),nk[e.id]=e}function nA(e){return nj(function(){return nO(this,function(t){switch(t.label){case 0:return[4,n_()];case 1:return[4,nD(t.sent(),e)];case 2:return[2,t.sent()]}})})()}function nD(e,t){return nj(function(){var r;return nO(this,function(n){switch(n.label){case 0:return r=t?{type:t,users:e}:{users:e},[4,new r3().dynamicOfflineData.where(r).toArray().catch(rH.errnames.DatabaseClosed,function(){return[]})];case 1:return[2,n.sent()]}})})()}function nC(e,t){return nj(function(){return nO(this,function(r){switch(r.label){case 0:return[4,n_()];case 1:return[4,nT(r.sent(),e,t)];case 2:return[2,r.sent()]}})})()}function nT(e,t,r){return nj(function(){var n,a;return nO(this,function(i){switch(i.label){case 0:return[4,(n=new r3).dynamicOfflineData.get({type:t,identifier:r}).catch(rH.errnames.DatabaseClosed,function(){})];case 1:if(a=i.sent())return[3,3];return[4,n.dynamicOfflineData.add({users:[e],type:t,identifier:r}).catch(rH.errnames.DatabaseClosed)];case 2:return i.sent(),[3,5];case 3:var o;if(a.users.includes(e))return[3,5];return[4,n.dynamicOfflineData.update(a.id,{users:((function(e){if(Array.isArray(e))return nw(e)})(o=a.users)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(o)||function(e){if(e){if("string"==typeof e)return nw(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return nw(e,void 0)}}(o)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat([e])}).catch(rH.errnames.DatabaseClosed)];case 4:i.sent(),i.label=5;case 5:return[2]}})})()}function nN(e,t){return nj(function(){return nO(this,function(r){switch(r.label){case 0:return[4,n_()];case 1:return[4,nR(r.sent(),e,t)];case 2:return[2,r.sent()]}})})()}function nR(e,t,r){return nj(function(){var n,a;return nO(this,function(i){switch(i.label){case 0:return[4,(n=new r3).dynamicOfflineData.get({type:t,identifier:r,users:e}).catch(rH.errnames.DatabaseClosed,function(){})];case 1:if(!(a=i.sent()))return[3,5];if(!(a.users.length>1))return[3,3];return[4,n.dynamicOfflineData.update(a.id,{users:a.users.filter(function(t){return t!==e})}).catch(rH.errnames.DatabaseClosed)];case 2:return i.sent(),[3,5];case 3:return[4,n.dynamicOfflineData.delete(a.id).catch(rH.errnames.DatabaseClosed)];case 4:i.sent(),i.label=5;case 5:return[2]}})})()}function nM(e,t){return nj(function(){return nO(this,function(r){switch(r.label){case 0:return[4,nA(e)];case 1:return[4,Promise.all(r.sent().map(function(e){return nj(function(){return nO(this,function(r){return[2,nI(e.type,e.identifier,t)]})})()}))];case 2:return r.sent(),[2]}})})()}function nI(e,t,r){return nj(function(){var n,a,i,o,s,l,u,c,d;return nO(this,function(f){switch(f.label){case 0:return[4,nC(e,t)];case 1:return f.sent(),n=new r3,[4,n_()];case 2:return a=f.sent(),[4,n.dynamicOfflineData.get({type:e,identifier:t}).catch(rH.errnames.DatabaseClosed,function(){})];case 3:if(i=f.sent(),o=nE().filter(function(t){return t.type===e}),!i)return[2];return[4,Promise.all(o.map(function(e){return nj(function(){var n,a,i;return nO(this,function(o){try{return e.sync(t,r),[2,{id:e.id,error:void 0}]}catch(t){return i=null!=(n=null==(a=t.message)?void 0:a.toString())?n:t.toString(),[2,{id:e.id,error:i}]}})})()}))];case 4:if(l=(s=f.sent()).filter(function(e){return!e.error}).map(function(e){return e.id}),u=s.filter(function(e){return e.error}).map(function(e){return e.id}),c=s.filter(function(e){return e.error}).map(function(e){return{handlerId:e.id,message:e.error}}),d={syncedOn:new Date,syncedBy:a,succeededHandlers:l,erroredHandlers:u,errors:c},!i.id)return[3,6];return[4,n.dynamicOfflineData.update(i.id,{syncState:d}).catch(rH.errnames.DatabaseClosed)];case 5:f.sent(),f.label=6;case 6:return[2]}})})()}function n_(){return nj(function(){var e;return nO(this,function(t){switch(t.label){case 0:return[4,(0,rZ.getLoggedInUser)()];case 1:if(!(e=t.sent().uuid))throw Error("Using the dynamic offline data API requires a logged in user.");return[2,e]}})})()}function nL(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}var nF=(0,rQ.createGlobalStore)("offline-entities",{offlineEntityDataSyncState:{},handlers:{}});function nB(){return nW(),nF}function nV(e,t){nW(),nP({type:"entity",displayName:t.displayName,id:e,isSynced:function(){return Promise.resolve(!0)},sync:function(e,r){return t.onOfflineEntityAdded({entityUuid:e,signal:null!=r?r:new AbortController().signal})}})}function nz(e){var t;return(t=function(){return function(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}(this,function(t){switch(t.label){case 0:return nW(),[4,nI("entity",e)];case 1:return t.sent(),[2]}})},function(){var e=this,r=arguments;return new Promise(function(n,a){var i=t.apply(e,r);function o(e){nL(i,n,a,o,s,"next",e)}function s(e){nL(i,n,a,o,s,"throw",e)}o(void 0)})})()}function nW(){console.warn("The offline entity API has been deprecated and will be removed in a future release. To prevent future crashes, the functions remain available for the moment, but any invocations should be migrated ASAP.")}},7230(e,t,r){"use strict";r.d(t,{yw:()=>v,Y1:()=>f,FZ:()=>y,oB:()=>d.o});var n=r(9250),a=r(3645),i=r(5794),o=r(3766),s=r(1221),l=r(9120);function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}var c=r(7267),d=r(8148);function f(e,t){var r=t.name;if(!r)return void console.error("An extension definition in ".concat(e,' is missing an name and thus cannot be\nregistered. To fix this, ensure that you define the "name" field inside the\nextension definition.'),t);t.slots&&t.slot&&console.warn("The extension ".concat(r," from ").concat(e," declares both a 'slots' property and\na 'slot' property. Only the 'slots' property will be honored."));var n=t.slots?t.slots:t.slot?[t.slot]:[];if(!t.component)return void console.error("The extension ".concat(r," from ").concat(e," is missing a 'component' entry and thus cannot be registered.\nTo fix this, ensure that you define a 'component' field inside the extension definition."),t);if(n.some(c.rq)){var a=(0,c.Sk)(t.meta);a.length>0&&console.warn("L'extension ".concat(r," de ").concat(e," est sur un slot de rail du shell mais ne s'affichera pas : ").concat(a.join(" ; "),"."))}(0,c.VK)({name:r,load:function(){return(0,d.o)(e,t.component)},meta:t.meta||{},order:t.order,moduleName:e,privileges:t.privileges,online:null==(l=t.online)||l,offline:null!=(u=t.offline)&&u,featureFlag:t.featureFlag,displayExpression:t.displayExpression});var i=!0,o=!1,s=void 0;try{for(var l,u,f,p=n[Symbol.iterator]();!(i=(f=p.next()).done);i=!0){var h=f.value;(0,c.K0)(h,r)}}catch(e){o=!0,s=e}finally{try{i||null==p.return||p.return()}finally{if(o)throw s}}}function p(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){var n;n=r[t],t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n})}return e}function h(e){return e&&"u">typeof Symbol&&e.constructor===Symbol?"symbol":typeof e}var m=[];function y(e,t){if(e&&t&&(void 0===t?"undefined":h(t))==="object"){var r,n,y,v,g,b,x,w,S,j=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){try{return"5.0.0"}catch(e){return}}(),r=e.platforms,n=e.requiredCapabilities,a=e.frameworkRange;if(Array.isArray(r)&&r.length>0){var i=(0,o.t)();if(!r.includes(i))return{reason:"platform",target:i,platforms:function(e){if(Array.isArray(e))return u(e)}(r)||function(e){if("u">typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(r)||function(e){if(e){if("string"==typeof e)return u(e,void 0);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return u(e,void 0)}}(r)||function(){throw TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}}if("string"==typeof a&&a.length>0&&t&&!(0,l.r)(a,t))return{reason:"framework",required:a,current:t};if(Array.isArray(n)&&n.length>0){var c=n.filter(function(e){return!(0,s.p)(e)});if(c.length>0)return{reason:"capability",missing:c}}return null}(t);if(j)return void console.warn("[egen] L'application ".concat(e," n'est pas enregistr\xe9e dans cet environnement."),p({app:e},j));(0,a.registerModuleWithConfigSystem)(e);var O=null!=(r=t.extensions)?r:[],k=null!=(n=t.modals)?n:[],E=null!=(y=t.workspaces)?y:[],P=null!=(v=t.workspaceGroups)?v:[],A=null!=(g=t.featureFlags)?g:[],D=null!=(b=t.workspaceGroups2)?b:[],C=null!=(x=t.workspaceWindows2)?x:[],T=null!=(w=t.workspaces2)?w:[];null==(S=t.pages)||S.forEach(function(t){if(t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"component")&&(Object.hasOwn(t,"route")||Object.hasOwn(t,"routeRegex")||Object.hasOwn(t,"routes"))){var r,n;m.push((r=p({},t),n=n={appName:e},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))}else console.warn("A page for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),O.forEach(function(t){t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"name")&&Object.hasOwn(t,"component")?f(e,t):console.warn("An extension for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),k.forEach(function(t){if(t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"name")&&Object.hasOwn(t,"component")){var r;(r=t.name)?t.component?(0,c.Ju)({name:r,moduleName:e,load:function(){return(0,d.o)(e,t.component)}}):console.error("The modal ".concat(r," from ").concat(e," is missing a 'component' entry and thus cannot be registered.\nTo fix this, ensure that you define a 'component' field inside the modal definition."),t):console.error("A modal definition in ".concat(e,' is missing an name and thus cannot be\nregistered. To fix this, ensure that you define the "name" field inside the\nmodal definition.'),t)}else console.warn("A modal for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),E.forEach(function(t){t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"name")&&Object.hasOwn(t,"component")?function(e,t){var r=t.name;if(!r)return console.error("A workspace definition in ".concat(e,' is missing a name and thus cannot be registered.\nTo fix this, ensure that you define the "name" field inside the workspace definition.'),t);var n=t.title;if(!n)return console.error("A workspace definition in ".concat(e,' is missing a title and thus cannot be registered.\nTo fix this, ensure that you define the "title" field inside the workspace definition.'),t);if(!t.component)return console.error("The workspace ".concat(r," from ").concat(e," is missing a 'component' entry and thus cannot be registered.\nTo fix this, ensure that you define a 'component' field inside the workspace definition."),t);(0,c.pm)({name:r,title:n,component:t.component,moduleName:e,type:t.type,canHide:t.canHide,canMaximize:t.canMaximize,width:t.width,preferredWindowSize:t.preferredWindowSize,groups:t.groups,load:function(){return(0,d.o)(e,t.component)}});var a=!0,i=!1,o=void 0;try{for(var s,l=(t.groups||[])[Symbol.iterator]();!(a=(s=l.next()).done);a=!0){var u=s.value;(0,c.io)({name:u,members:[r]})}}catch(e){i=!0,o=e}finally{try{a||null==l.return||l.return()}finally{if(i)throw o}}}(e,t):console.warn("A workspace for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),P.forEach(function(t){if(t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"name")){var r,n;(n=t.name)?(0,c.io)({name:n,members:null!=(r=t.members)?r:[]}):console.error("A workspace group definition in ".concat(e,' is missing a name and thus cannot be registered.\nTo fix this, ensure that you define the "name" field inside the workspace definition.'),t)}else console.warn("A workspace group for ".concat(e," could not be registered as it does not appear to have the required properties"),t)}),(0,c.rD)(e,D),function(e,t){(0,c.Qb)(e,t);var r=!0,n=!1,a=void 0;try{for(var i,o=t[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s=i.value;if(s.icon){var l={name:s.name,component:s.icon,slot:s.group,order:s.order};f(e,l)}}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}}(e,C),(0,c.Uh)(e,T),A.forEach(function(t){if(t&&(void 0===t?"undefined":h(t))==="object"&&Object.hasOwn(t,"flagName"))t.flagName?t.label?t.description?(0,i.uA)(t.flagName,t.label,t.description):console.error("A feature flag definition in ".concat(e,' is missing a description and thus cannot be registered.\nTo fix this, ensure that you define the "description" field inside the feature flag definition.'),t):console.error("A feature flag definition in ".concat(e,' is missing a description and thus cannot be registered.\nTo fix this, ensure that you define the "label" field inside the feature flag definition.'),t):console.error("A feature flag definition in ".concat(e,' is missing a name and thus cannot be registered.\nTo fix this, ensure that you define the "name" field inside the feature flag definition.'),t);else console.warn("A feature flag for ".concat(e," could not be registered as it does not appear to have the required properties"),t)})}}function v(){m.sort(function(e,t){return e.appName.localeCompare(t.appName,"en")});var e=new Map,t=!0,r=!1,a=void 0;try{for(var o,s=m[Symbol.iterator]();!(t=(o=s.next()).done);t=!0){var l,u=o.value;e.has(u.appName)?e.set(u.appName,e.get(u.appName)+1):e.set(u.appName,0);var c=e.get(u.appName),f="".concat(u.appName,"-page-").concat(c),p=null!=(l=u.containerDomId)?l:"egen-apps-container",h=document.getElementById(p),y="single-spa-application:".concat(f);if(h){var v=document.createElement("div");v.id=y,null==h||h.appendChild(v)}else throw Error("".concat(u.appName," ").concat(u.component,' cannot be mounted to "').concat(p,'"; DOM element does not exist.'));!function(e,t){var r,a,o,s,l=void 0!==t.route?t.route:void 0!==t.routeRegex&&new RegExp(t.routeRegex);if(!1===l)return console.warn('A registered page definition is missing a route and thus cannot be registered.\nTo fix this, ensure that you define the "route" (or alternatively the "routeRegex") field inside the extension definition.',e);if(!t.component)return console.warn('A registered page definition is missing a component and thus cannot be registered.\nTo fix this, ensure that you define the "component" field inside the page definition.',e);var u=(r=function e(t){if(Array.isArray(t)){var r,a=t.map(e);return function(e){return a.some(function(t){return t(e)})}}return"string"==typeof t?(0,n.pathToActiveWhen)(window.getEgenSpaBase()+t):(null!=(r=RegExp)&&"u">typeof Symbol&&r[Symbol.hasInstance]?!!r[Symbol.hasInstance](t):t instanceof r)?function(e){return t.test(e.pathname.replace(window.getEgenSpaBase(),""))}:function(){return t}}(l),a=t.online,o=t.offline,s=t.featureFlag,window.offlineEnabled?function(e){return!!(navigator.onLine&&(null==a||a)||!navigator.onLine&&null!=o&&o)&&(!s||!!(0,i.jj)(s))&&r(e)}:r);(0,n.registerApplication)(e,function(){return(0,d.o)(t.appName,t.component)},u)}(f,u)}}catch(e){r=!0,a=e}finally{try{t||null==s.return||s.return()}finally{if(r)throw a}}}},8148(e,t,r){"use strict";r.d(t,{o:()=>u});var n=r(99),a=r(3645);function i(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function o(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var o=e.apply(t,r);function s(e){i(o,n,a,s,l,"next",e)}function l(e){i(o,n,a,s,l,"throw",e)}s(void 0)})}}function s(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}var l=new Map;function u(e,t){return o(function(){var r,i,u,d,f;return s(this,function(p){switch(p.label){case 0:return u=(i=(r=t.indexOf("#"))>=0)?t.substring(0,r):e,d=i?t.substring(r+1):t,[4,(0,n.rL)(u)];case 1:if((f=p.sent())&&Object.hasOwn(f,d)&&"function"==typeof f[d]){var h,m;return[2,(h=u,m=f,o(function(){var e,t;return s(this,function(r){switch(r.label){case 0:if(h in l)return[3,5];if(null==m)return[3,1];return t=m,[3,3];case 1:return[4,(0,n.rL)(h)];case 2:t=r.sent(),r.label=3;case 3:return e=t,[4,l[h]=new Promise(function(t,r){if(Object.hasOwn(e,"startupApp")){var n=e.startupApp;if("function"==typeof n)return Promise.resolve(n()).then(function(){(0,a.registerModuleLoad)(h),t(null)}).catch(r)}(0,a.registerModuleLoad)(h),t(null)})];case 4:return r.sent(),[3,7];case 5:return[4,l[h]];case 6:r.sent(),r.label=7;case 7:return[2]}})})()).then(function(){return f[d]()})]}return f?f&&Object.hasOwn(f,d)?console.warn("The export ".concat(t,", defined in ").concat(e,"'s routes.json, is not a function")):console.warn("".concat(u,' does not define a component called "').concat(d,'", referenced in ').concat(e,"'s routes.json. This cannot be loaded.")):console.warn("Unknown app ".concat(u," for ").concat(t," defined in ").concat(e,"'s routes.json")),[2,c]}})})()}var c={bootstrap:function(){return Promise.resolve()},mount:function(){return Promise.resolve()},unmount:function(){return Promise.resolve()}}},3903(e,t,r){"use strict";r.d(t,{g2:()=>ev,Rt:()=>es,XE:()=>ee,a3:()=>eu,LW:()=>en,a7:()=>et,L8:()=>q,Yq:()=>ea,L3:()=>X,fU:()=>eo,_U:()=>Z,d4:()=>el,p0:()=>em,kQ:()=>Y,qE:()=>ec,pf:()=>K});var n,a=r(9405),i=r(227);if("u">typeof navigator){let e=navigator;n=Array.isArray(e.languages)?e.languages[0]:e.language}else if("u">typeof process){let e=process.env;n=e.LC_ALL||e.LC_MESSAGES||e.LANG||e.LANGUAGE}var o=function(e){e=(e=e.replace(/_/g,"-")).replace(/[.:][\w-]*$/,"");try{return new Intl.Locale(e).baseName}catch{return"en-US"}}(n||"en-US"),s=class extends Date{invalid=null;isValid(){return!Number.isNaN(this.valueOf())}},l={};for(let e=0;e<100;e++)l[(e<=9?"0":"")+e]=e+(e>51?1900:2e3);var u={arab:1632,arabext:1776,bali:6992,beng:2534,deva:2406,fullwide:65296,gujr:2790,khmr:6112,knda:3302,laoo:3792,limb:6470,mlym:3430,mong:6160,mymr:4160,orya:2918,tamldec:3046,telu:3174,thai:3664,tibt:3872},c="[1234567890一二三四五六七八九〇\\d]",d={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,"0":0,"1":1,"2":2,"3":3,"4":4,"5":5,"6":6,"7":7,"8":8,"9":9,〇:0,一:1,二:2,三:3,四:4,五:5,六:6,七:7,八:8,九:9},f={},p={"Eastern Daylight Time":-240,"Eastern Standard Time":-300,"Central Daylight Time":-300,"Central Standard Time":-360,"Mountain Daylight Time":-360,"Mountain Standard Time":-420,"Pacific Daylight Time":-420,"Pacific Standard Time":-480,"Coordinated Universal Time":0,ACDT:630,ACST:570,ACT:480,ADT:-180,AEDT:660,AEST:600,AFT:270,AKDT:-480,AKST:-540,AMST:-180,AMT:-240,ART:-180,AST:180,AWDT:540,AWST:480,AZOST:-60,AZT:240,BDT:360,BIOT:360,BIT:-720,BOT:-240,BRST:-120,BRT:-180,BTT:360,CAT:120,CCT:390,CDT:-300,CEDT:120,CEST:120,CET:60,CHADT:825,CHAST:765,CHOT:480,ChST:600,CHUT:600,CIST:-480,CIT:480,CKT:-600,CLST:-180,CLT:-240,COST:-240,COT:-300,CST:-360,CT:480,CVT:-60,CXT:420,DAVT:420,DDUT:600,DFT:60,EASST:-300,EAST:-360,EAT:180,ECT:-300,EDT:-240,EEDT:180,EEST:180,EET:120,EGST:0,EGT:-60,EIT:540,EST:-300,FET:180,FJT:720,FKST:-180,FKT:-240,FNT:-120,GALT:-360,GAMT:-540,GET:240,GFT:-180,GILT:720,GIT:-540,GMT:0,GST:-120,GYT:-240,HADT:-540,HAEC:120,HAST:-600,HKT:480,HMT:300,HOVT:420,HST:-600,IBST:0,ICT:420,IDT:180,IOT:180,IRDT:270,IRKT:480,IRST:210,IST:120,JST:540,KGT:360,KOST:660,KRAT:420,KST:540,LHST:630,LINT:840,MAGT:720,MART:-510,MAWT:300,MDT:-360,MET:60,MEST:120,MHT:720,MIST:660,MIT:-510,MMT:390,MSK:180,MST:-420,MUT:240,MVT:300,MYT:480,NCT:660,NDT:-90,NFT:660,NPT:345,NST:-150,NT:-150,NUT:-660,NZDT:780,NZST:720,OMST:360,ORAT:300,PDT:-420,PET:-300,PETT:720,PGT:600,PHOT:780,PKT:300,PMDT:-120,PMST:-180,PONT:660,PST:-480,PYST:-180,PYT:-240,RET:240,ROTT:-180,SAKT:660,SAMT:240,SAST:120,SBT:660,SCT:240,SGT:480,SLST:330,SRET:660,SRT:-180,SST:480,SYOT:180,TAHT:-600,THA:420,TFT:300,TJT:300,TKT:780,TLT:540,TMT:300,TOT:780,TVT:720,UCT:0,ULAT:480,USZ1:120,UTC:0,UYST:-120,UYT:-180,UZT:300,VET:-240,VLAT:600,VOLT:240,VOST:360,VUT:660,WAKT:720,WAST:120,WAT:60,WEDT:60,WEST:60,WET:0,WIT:420,WST:480,YAKT:540,YEKT:300},h={zone:p,year:l,meridiem:{am:0,pm:12,"a.m.":0,"p.m.":12},month:{january:1,jan:1,february:2,feb:2,march:3,mar:3,april:4,apr:4,may:5,june:6,jun:6,july:7,jul:7,august:8,aug:8,september:9,sep:9,october:10,oct:10,november:11,nov:11,december:12,dec:12},dayname:{sunday:0,sun:0,monday:1,mon:1,tuesday:2,tue:2,wednesday:3,wed:3,thursday:4,thu:4,friday:5,fri:5,saturday:6,sat:6},digit:{}},m={MONTHNAME:"january|february|march|april|may|june|july|august|september|october|november|december|jan\\.?|feb\\.?|mar\\.?|apr\\.?|may\\.?|jun\\.?|jul\\.?|aug\\.?|sep\\.?|oct\\.?|nov\\.?|dec\\.?",DAYNAME:"sunday|monday|tuesday|wednesday|thursday|friday|saturday|sun\\.?|mon\\.?|tue\\.?|wed\\.?|thu\\.?|fri\\.?|sat\\.?",ZONE:`\\(?(?:${Object.keys(p).join("|")})\\)?`,MERIDIEM:"am|pm|a.m.|p.m.",ORDINAL:"st|nd|rd|th|\\.",YEAR:"\\d{4}|\\d{2}",YEAR2:"\\d{2}",YEAR4:"\\d{4}",YEAR6:"-\\d{6}|\\+?\\d{5,6}",MONTH:"1[0-2]|0?[1-9]",MONTH2:"1[0-2]|0[1-9]",DAY:"3[01]|[12]\\d|0?[1-9]",DAY2:"3[01]|[12]\\d|0[1-9]",OFFSET:"(?:GMT)?[\xb1−+-](?:[01]\\d[0-5]\\d|[01]\\d:[0-5]\\d|[01]?\\d)",H24:"[01]\\d|2[0-3]",H12:"0?[1-9]|1[012]",MIN:"[0-5]\\d",SEC:"[0-5]\\d|60",MS:"\\d{9}|\\d{6}|\\d{1,3}",GAP:"[\\s/.,-]{1,}"},y={...m,YEAR:"*{4}|*{2}",YEAR4:"*{4}",YEAR6:"-*{6}|\\+?*{5,6}",MONTH:"*{1,2}",MONTH2:"*{2}",DAY:"*{1,2}",DAY2:"*{2}",OFFSET:"(?:GMT)?[\xb1−+-](?:*{4}|*{2}:*{2}|*{1,2})",H24:"*{2}",H12:"*{1,2}",MIN:"*{2}",SEC:"*{2}",MS:"*{9}|*{6}|*{3}"},v={},g=class e{locale;lookups;vars;numberingSystem;baseName;dateOptions;static factory(t=o){let r=t.toLowerCase(),n=v[r];if(n)return n;let a=new e(t);return v[r]=a,a}constructor(e=o){this.locale=e,this.lookups={...h},this.vars={...m};const t=new Intl.NumberFormat(this.locale);this.numberingSystem=t.resolvedOptions().numberingSystem,this.dateOptions=new Intl.DateTimeFormat(this.locale).resolvedOptions(),this.baseName=new Intl.Locale(this.locale).baseName,this.build()}toInt(e){return"number"==typeof e?e:"string"==typeof e?this.stringToInt(e):void 0}stringToInt(e){if("latn"===this.numberingSystem&&!this.baseName.startsWith("zh")){let t=parseInt(e,10);if(!Number.isNaN(t))return t}let t="";for(let r=0;r<e.length;r++)t+=String(this.lookups.digit[e[r]]);return parseInt(t,10)}millisecondToInt(e){if("number"==typeof e)return e;if("string"!=typeof e)return;let t=e.slice(0,3);return 1===t.length?100*this.stringToInt(t):2===t.length?10*this.stringToInt(t):this.stringToInt(t)}monthNameToInt(e){if("string"!=typeof e)return;let t=e.toLocaleLowerCase(this.locale).replace(/\.$/,"");return this.lookups.month[t]||12}h12ToInt(e,t){if("string"!=typeof e)return;let r=this.lookups.meridiem[t?.toLowerCase()]||0,n=this.stringToInt(e);return n<12&&12===r&&(n+=12),12===n&&0===r&&(n=0),n}zoneToOffset(e){if("string"==typeof e)return e=e.replace(/[^a-z\s]/gi,""),this.lookups.zone[e]}offsetToMinutes(e){if("string"!=typeof e)return;let t=e.match(/^(?:GMT)?([±−+-])(..?):?(..)?$/);if(t){let[,e,r,n]=t;return("-"===e||"−"===e?-1:1)*(60*this.stringToInt(r)+(n?this.stringToInt(n):0))}return 0}build(){"latn"===this.dateOptions.numberingSystem?this.lookups.digit=d:this.buildNumbers(),!/^en/i.test(this.locale)&&(this.buildMonthNames(),this.buildDaynames(),/zh/i.test(this.locale)||this.buildMeridiems())}buildNumbers(){let{group:e,lookup:t}=function(e){let t=f[e];if(t)return t;if("fullwide"===e||"hanidec"===e)return{group:c,lookup:{...d}};let r=u[e];if(!r)return{group:"\\d",lookup:{...d}};let n=String.fromCharCode(r),a=String.fromCharCode(r+9),i={};for(let e=0;e<10;e++)i[String.fromCharCode(r+e)]=e;return f[e]={group:`[${n}-${a}]`,lookup:i},f[e]}(this.numberingSystem);for(let r in this.lookups.digit=t,y)Object.hasOwn(y,r)&&(this.vars[r]=y[r].replace(/\*/g,e))}buildMonthNames(){let e={},t={};if(/^fi/i.test(this.locale))"tammi|helmi|maalis|huhti|touko|kes\xe4|hein\xe4|elo|syys|loka|marras|joulu".split("|").forEach((r,n)=>{["","k","kuu","kuuta"].forEach((a,i)=>{e[r+a+(i<2?"\\.?":"")]=!0,t[r+a]=n+1})});else{let r=[],n=e=>"month"===e.type;for(let e=0;e<12;e++)r.push(new Date(2017,e,1));for(let a of["full","long","medium"]){let i=Intl.DateTimeFormat(this.locale,{dateStyle:a});for(let o=0;o<12;o++){let s=i.formatToParts(r[o]).find(n);if(!s)continue;let l=s.value.toLocaleLowerCase(this.locale);/^\d+$/.test(l)||(/^ko/i.test(this.locale)&&(l+="월"),"medium"===a?(l=l.replace(/\.$/,""),e[`${l}\\.?`]=!0):e[l]=!0,t[l]=o+1)}}let a=Intl.DateTimeFormat(this.locale,{month:"short"});for(let i=0;i<12;i++){let o=a.formatToParts(r[i]).find(n);if(!o)continue;let s=o.value.toLocaleLowerCase(this.locale);s=s.replace(/\.$/,""),e[`${s}\\.?`]=!0,t[s]=i+1}}this.vars.MONTHNAME=Object.keys(e).join("|"),this.lookups.month=t}buildDaynames(){let e=[],t=e=>"weekday"===e.type;for(let t=0;t<7;t++)e.push(new Date(2017,0,t+1));let r=[],n={};for(let a of["long","short"]){let i=Intl.DateTimeFormat(this.locale,{weekday:a});for(let o=0;o<7;o++){let s=i.formatToParts(e[o]).find(t);if(!s)continue;let l=s.value.toLocaleLowerCase(this.locale);"short"===a?(l=l.replace(/\.$/,""),r.push(`${l}\\.?`)):r.push(l),n[l]=o}}this.vars.DAYNAME=r.join("|"),this.lookups.dayname=n}buildMeridiems(){let e=[new Date(2017,0,1),new Date(2017,0,1,23,0,0)],t=e=>"dayPeriod"===e.type,r=[],n={},a=Intl.DateTimeFormat(this.locale,{timeStyle:"long"});for(let i=0;i<2;i++){let o=a.formatToParts(e[i]).find(t);if(!o)return;let s=o.value.toLocaleLowerCase(this.locale);r.push(s),n[s]=12*i}this.vars.MERIDIEM=r.join("|"),this.lookups.meridiem=n}compile(e){return RegExp(e.replace(/_([A-Z0-9]+)_/g,(e,t)=>{if(!this.vars[t])throw Error(`Template string contains invalid variable _${t}_`);return this.vars[t]}),"i")}},b=["ee-TG","en-AS","en-CA","en-FM","en-GH","en-GU","en-KE","en-KY","en-MH","en-MP","en-US","en-VI","en-WS","jp-JP","sm-AS","sm-SM"],x={y:"year",M:"month",d:"day",w:"week",h:"hour",m:"minute",s:"second",ms:"millisecond"},w=()=>new Date;function S(e){return function(t){let r={};for(let n=0,a=e.length;n<a;n++){let a=e[n];a&&(r[a]=t[n])}return r}}var j=class{doneChecker;fallback;patterns;formatter;constructor({doneChecker:e,fallback:t,patterns:r,formatter:n}){this.doneChecker=e,this.fallback=t,this.patterns=r,this.formatter=n}attempt(e){if("string"!=typeof e)return this.fallback(e);let t=e.trim(),r={},n=!1;for(let e of this.patterns){let a=t.match(e.regex);if(!a)continue;n=!0;let i=e.handler(a);if(i){for(let[e,t]of Object.entries(i))e in r||void 0===t||(r[e]=t);let e=a.index??0;if(t=(t=t.slice(0,e)+t.slice(e+a[0].length+1)).trim(),this.doneChecker(r,t))break}}return n?this.formatter(r):this.fallback(e)}},O=["year","month","day","hour","minute","second","millisecond","offset"],k={};function E(e,t){return""===t||/^\s+$/.test(t)||"year"in e&&("month"in e||"monthname"in e)&&"day"in e&&"hour"in e&&"minute"in e&&"second"in e&&"millisecond"in e&&("zone"in e||"offset"in e)}var P=[[/([^\d.]+)(\d{1,2})\.(\d{2})\.(\d{2})(\D|$)/,"$1$2:$3:$4$5"],[/([^\d.]+)(\d{1,2})\.(\d{2})(\D|$)/,"$1$2:$3$4"]],A={ar:[[/ /g," "]],bn:[[/,/g,""]],zh:[[/早上\s*([\d:]+)/,"$1am"],[/凌晨\s*([\d:]+)/,"$1am"],[/上午\s*([\d:]+)/,"$1am"],[/下午\s*([\d:]+)/,"$1pm"],[/晚上\s*([\d:]+)/,"$1pm"]],he:[[/ב/gi,""]],de:[[/ um /g," "]],pt:[[/\sde /gi," "]],es:[[/\sde /gi," "]],da:[[/\sden /gi," "],...P],ru:[[/ г\./g,""]],th:[[/\s*นาฬิกา\s*/i,":"],[/\s*นาที\s*/i,":"],[/\s*วินาที\s*/i," "]],ko:[[/\s*시\s*/,":"],[/\s*분\s*/,":"],[/\s*초\s*/,""],[/(오전|오후)\s*([\d:]+)/,"$2$1"],[/(\d{4})\. (\d{1,2})\. (\d{1,2})\./,"$1-$2-$3"]],fi:P,id:P,fr:[[/(\d{2}) h /,"$1:"],[/(\d{2}) min /,"$1:"],[/(\d{2}) s /,"$1"]]};function D(e,t=o){let r=function(e){var t,r;let n,a,i=k[e];if(i)return i;let o=g.factory(e),s=new j({doneChecker:E,fallback:(t=e,function(e){let r=String(e).slice(0,50);return""===r&&(r="(empty string)"),{invalid:`Unable to parse "${r}" with locale "${t}"`}}),patterns:(n=[{name:"timestampWithOffset",regex:o.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? ?(_OFFSET_|Z)?$"),handler:S(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"timestampWithZone",regex:o.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))?\\s*(_ZONE_)$"),handler:S(["","year","month","day","hour","minute","second","millisecond","zone"])},{name:"timestampWithOffsetAndZone",regex:o.compile("^(_YEAR4_)-(_MONTH_)-(_DAY_)[T ](_H24_):(_MIN_):(_SEC_)(?:.(_MS_))? (_OFFSET_|Z)\\s*(_ZONE_)$"),handler:S(["","year","month","day","hour","minute","second","millisecond","offset"])},{name:"chinese",regex:o.compile(`^(${c}{2,4})\\s*\u5E74\\s*(${c}{1,2})\\s*\u6708\\s*(${c}{1,2})\\s*\u65E5$`),handler:S(["","year","month","day"])},{name:"korean",regex:o.compile("^(_YEAR_)년\\s*(_MONTH_)월\\s*(_DAY_)일$"),handler:S(["","year","month","day"])},{name:"twitter",regex:/^(?:sun|mon|tue|wed|thu|fri|sat) (jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec) (\d{2}) (\d{2}):(\d{2}):(\d{2}) ([+-]\d{4}) (\d{4})$/i,handler:S(["","monthname","day","hour","minute","second","offset","year"])},{name:"today",regex:/\b(now|today|tomorrow|yesterday)\b/i,handler:e=>{let t=w(),r=e[0].toLowerCase(),n={now:0,today:0,tomorrow:864e5,yesterday:-864e5}[r]??0;0!==n&&t.setTime(t.getTime()+n);let a={year:t.getFullYear(),month:t.getMonth()+1,day:t.getDate()};return"now"===r?{...a,hour:t.getHours(),minute:t.getMinutes(),second:t.getSeconds(),millisecond:t.getMilliseconds()}:a}},{name:"ago",regex:/^(\+|-|in|) ?([\d.]+) ?(years?|months?|weeks?|days?|hours?|minutes?|seconds?|milliseconds?|ms|s|m|h|w|d|M|y)( ago)?$/i,handler:([,e,t,r,n])=>{let a,i=parseFloat(t);"week"===(a=r.length<=2?x[r]:(a=r.replace(/s$/,"")).toLowerCase())&&(a="day",i*=7),("-"===e||n)&&(i*=-1);let o=w();return"millisecond"===a?o.setUTCMilliseconds(o.getUTCMilliseconds()+i):"second"===a?o.setUTCSeconds(o.getUTCSeconds()+i):"minute"===a?o.setUTCMinutes(o.getUTCMinutes()+i):"hour"===a?o.setUTCHours(o.getUTCHours()+i):"day"===a?o.setUTCDate(o.getUTCDate()+i):"month"===a?o.setUTCMonth(o.getUTCMonth()+i):"year"===a&&o.setUTCFullYear(o.getUTCFullYear()+i),{year:o.getUTCFullYear(),month:o.getUTCMonth()+1,day:o.getUTCDate(),hour:o.getUTCHours(),minute:o.getUTCMinutes(),second:o.getUTCSeconds(),millisecond:o.getUTCMilliseconds()}}},{name:"atSeconds",regex:/^@(\d+)$/,handler:e=>{let t=new Date(1e3*parseInt(e[1],10));return{year:t.getUTCFullYear(),month:t.getUTCMonth()+1,day:t.getUTCDate(),hour:t.getUTCHours(),minute:t.getUTCMinutes(),second:t.getUTCSeconds()}}},{name:"microsoftJson",regex:/^\/Date\((\d+)([+-]\d{4})?\)\/$/,handler:e=>{let t=new Date(parseInt(e[1],10));return{year:t.getUTCFullYear(),month:t.getUTCMonth()+1,day:t.getUTCDate(),hour:t.getUTCHours(),minute:t.getUTCMinutes(),second:t.getUTCSeconds(),millisecond:t.getUTCMilliseconds(),offset:e[2]}}},{name:"full24",regex:o.compile("(?:^|[\\sT])(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?(Z)?$"),handler:S(["","hour","minute","second","millisecond","zone"])},{name:"zone24",regex:o.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?[\\s\\[(]*(_ZONE_)?[\\s\\])]*$"),handler:S(["","hour","minute","second","millisecond","zone"])},{name:"hms12WithOffset",regex:o.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)\\s*(_OFFSET_)"),handler:S(["","hour","minute","second","meridiem","offset"])},{name:"hms12",regex:o.compile("(_H12_):(_MIN_):(_SEC_)\\s*(_MERIDIEM_)"),handler:S(["","hour","minute","second","meridiem"])},{name:"hms24",regex:o.compile("(_H24_):(_MIN_):(_SEC_)(?:\\.(_MS_))?"),handler:S(["","hour","minute","second","millisecond"])},{name:"hm12",regex:o.compile("(_H12_):(_MIN_)\\s*(_MERIDIEM_)"),handler:S(["","hour","minute","meridiem"])},{name:"hm24",regex:o.compile("(_H24_):(_MIN_)"),handler:S(["","hour","minute"])},{name:"h12",regex:o.compile("(_H12_)\\s*(_MERIDIEM_)"),handler:S(["","hour","meridiem"])},{name:"8digit",regex:/^((?:19|20)\d{2})(\d{2})(\d{2})$/,handler:S(["","year","month","day"])},{name:"yearMonthnameDay",regex:o.compile("(_YEAR4_)[\\s.-]+(_MONTHNAME_)[\\s,.-]+(_DAY_)(_ORDINAL_)?"),handler:S(["","year","monthname","day"])},{name:"dayMonthnameYear",regex:o.compile("(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)[\\s,.-]+(_YEAR_)"),handler:S(["","day","","monthname","year"])},{name:"monthnameDayYear",regex:o.compile("(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?[\\s,.-]+(_YEAR_)"),handler:S(["","monthname","day","","year"])},{name:"dayMonthname",regex:o.compile("\\b(_DAY_)(_ORDINAL_)?[\\s.-]*(_MONTHNAME_)\\b"),handler:S(["","day","","monthname"])},{name:"monthnameDay",regex:o.compile("\\b(_MONTHNAME_)[\\s.-]*(_DAY_)(_ORDINAL_)?\\b"),handler:S(["","monthname","day"])},{name:"hmsNoMeridiem",regex:o.compile("\\b(_H12_|_H24_):(_MIN_):(_SEC_)\\b"),handler:S(["","hour","minute","second"])},{name:"hmNoMeridiem",regex:o.compile("\\b(_H12_|_H24_):(_MIN_)\\b"),handler:S(["","hour","minute"])},{name:"ymd",regex:o.compile("(_YEAR4_)([./-])(_MONTH_)\\2+(_DAY_)"),handler:S(["","year","","month","day"])},{name:"mdy",regex:o.compile("(_MONTH_)([/-])(_DAY_)\\2(_YEAR_)"),handler:S(["","month","","day","year"])},{name:"dmy",regex:o.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)[./\\s-]+(_YEAR_)"),handler:S(["","day","month","year"])},{name:"yearLoose",regex:o.compile("_YEAR4_"),handler:S(["year"])},{name:"dayMonthnameLoose",regex:o.compile("(_DAY_)[\\s.]*(_MONTHNAME_)"),handler:S(["","day","monthname"])},{name:"monthnameDayLoose",regex:o.compile("(_MONTHNAME_)[\\s.]*(_DAY_)"),handler:S(["","monthname","day"])},{name:"monthname",regex:o.compile("_MONTHNAME_"),handler:S(["monthname"])},{name:"year4",regex:o.compile("_YEAR4_"),handler:S(["year"])},{name:"md",regex:o.compile("(_MONTH_)[/-](_DAY_)"),handler:S(["","month","day"])},{name:"dm",regex:o.compile("(_DAY_)(?:_ORDINAL_)?[./\\s-]+(_MONTH_)"),handler:S(["","day","month"])},{name:"day",regex:o.compile("_DAY_"),handler:S(["day"])},{name:"year2",regex:o.compile("_YEAR2_"),handler:S(["year"])},{name:"onlyZone",regex:o.compile("_ZONE_"),handler:S(["zone"])},{name:"onlyOffset",regex:o.compile("_OFFSET_"),handler:S(["offset"])}],a=o.baseName.slice(0,5),b.includes(a)?n:n.filter(e=>!["mdy","md"].includes(e.name))),formatter:(r=o,function(e){let t={};for(let[n,a]of Object.entries(e))if("monthname"===n){if(a){let e=r.monthNameToInt(a);void 0!==e&&(t.month=e)}}else if("hour"===n&&e.meridiem){let n=r.h12ToInt(a,e.meridiem);void 0!==n&&(t.hour=n)}else if("zone"===n){if(a){let e=r.zoneToOffset(a);void 0!==e&&(t.offset=e)}}else if("offset"===n){let e=r.offsetToMinutes(a);void 0!==e&&(t.offset=e)}else if("millisecond"===n){let e=r.millisecondToInt(a);"number"==typeof e&&(t.millisecond=e)}else if(O.includes(n)){let e=r.toInt(a);"number"==typeof e&&(t[n]=e)}return void 0!==t.year&&t.year<100&&(t.year=l[String(e.year)]),t.year&&"buddhist"===r.dateOptions.calendar&&(t.year-=543),t})});return k[e]=s,s}(t),n=function(e,t){let r=A[t.slice(0,2).toLowerCase()];if(!r)return e;for(let[t,n]of r)e=e.replace(t,n);return e}(e,t);return r.attempt(n)}function C(e){e.month&&e.day&&void 0===e.year&&(e.year=new Date().getFullYear()),60===e.second&&(e.second=59);let t=new s(e.year??NaN,(e.month??NaN)-1,e.day,e.hour||0,e.minute||0,e.second||0,e.millisecond||0);return"number"==typeof e.offset?new s(t.valueOf()-60*e.offset*1e3):t}function T(e,t=o){let r=D(e,t),n=r.invalid?new s(NaN):C(r);return n.isValid()||(n.invalid=`Unable to parse date "${e}"`),n}function N(e,t=o){return e instanceof Date?new s(e.valueOf()):"number"==typeof e?new s(e):T(e,t)}Date.fromString=s.fromString=T,Date.fromAny=s.fromAny=N,"u">typeof window&&(window.anyDateParser={fromString:T,fromAny:N,fromObject:C,attempt:D});var R=r(5350),M=r.n(R),I=r(648),L=r(6871),F=r(2147);let B=function(e){return null==e};var V=r(313),z=r(4232);function W(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function $(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function U(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(e){return Object.getOwnPropertyDescriptor(r,e).enumerable}))),n.forEach(function(t){$(e,t,r[t])})}return e}function H(e,t){var r=function(e,t){if(!t.has(e))throw TypeError("attempted to get private field on non-instance");return t.get(e)}(e,t);return r.get?r.get.call(e):r.value}M().extend(I),M().extend(F),M().extend(L);var G="YYYY-MM-DDTHH:mm:ss.SSSZZ";function K(e){return null!=e&&28===e.trim().length&&"T"===(e=e.trim())[10]&&":"===e[13]&&":"===e[16]&&"."===e[19]&&("+"===e[23]||"-"===e[23])&&M()(e,G).isValid()}function q(e){return M()(e).isToday()}function Y(e){return K(e)?M()(e,G).toDate():null}function X(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=M()(e);return t&&(r=r.utc()),r.format(G)}function Z(e){return M()(e).toDate()}var Q=new WeakMap,J=new(function(){var e;function t(){if(!(this instanceof t))throw TypeError("Cannot call a class as a function");var e=this,r=Q,n={writable:!0,value:new Map};if(r.has(e))throw TypeError("Cannot initialize the same private elements twice on an object");r.set(e,n)}return e=[{key:"register",value:function(e,t){H(this,Q).set(e,t)}},{key:"getCalendar",value:function(e){if(e){if(e.calendar)return e.calendar;if(e.region){var t="".concat(e.language,"-").concat(e.region);if(H(this,Q).has(t))return H(this,Q).get(t)}if(e.language&&H(this,Q).has(e.language))return H(this,Q).get(e.language);var r=new Intl.DateTimeFormat(e.toString()).resolvedOptions().calendar;return H(this,Q).set("".concat(e.language).concat(e.region?"-".concat(e.region):""),r),r}}}],function(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}(t.prototype,e),t}());function ee(e,t){J.register(e,t)}function et(e){var t,r=null!=e?e:(0,z.J)();return J.getCalendar((null!=(t=Intl.Locale)&&"u">typeof Symbol&&t[Symbol.hasInstance]?!!t[Symbol.hasInstance](r):r instanceof t)?r:new Intl.Locale(r))}var er={mode:"standard",time:"for today",day:!0,month:!0,year:!0,noToday:!1};function en(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=D(e,(0,z.J)());if(r.invalid)return console.warn("Could not parse invalid date '".concat(e,"'")),null;!B(r.day)&&B(r.month)&&(r=Object.assign({},(0,V.A)(r,"day"),{month:r.day})),r.month&&(r.month-=1),r.day&&(r=Object.assign({},(0,V.A)(r,"day"),{date:r.day}));var n=M()().set(r).toDate();return B(r.year)&&(t.year=!1),B(r.month)&&(t.month=!1),B(r.date)&&(t.day=!1),ea(n,t)}function ea(e,t){var r,n,a=null!=(r=null==t?void 0:t.locale)?r:(0,z.J)(),i=new Intl.Locale(a),o=U({},er,{noToday:"am"===i.language},t),s=o.calendar,l=o.mode,u=o.time,c=o.day,d=o.month,f=o.year,p=o.noToday,h=o.numberingSystem,m={calendar:null!=s?s:et(i),year:f?"numeric":void 0,month:d?"short":void 0,day:c?"2-digit":void 0,numberingSystem:h},y=M()(e).isToday();if(y&&!p)n=(n=new Intl.RelativeTimeFormat(a,{numeric:"auto"}).format(0,"day"))[0].toLocaleUpperCase(a)+n.slice(1);else{"en"===i.language&&(a="en-GB");var v=new Intl.DateTimeFormat(a,m).formatToParts(e);("en"===i.language||"am"===i.language)&&"standard"==l&&f&&c&&(v=v.map(ei("-"))),"wide"==l&&(v=v.map(ei(" — "))),"ethiopic"===m.calendar&&(v=v.filter(function(e,t,r){return"era"!==e.type&&("literal"!==e.type||!(t<r.length-1)||"era"!==r[t+1].type)})),n=v.map(function(e){return e.value}).join("")}return(!0===u||y&&"for today"===u)&&(n+=", ".concat(eo(e))),n}var ei=function(e){return function(t,r,n){return"literal"!==t.type||" "!==t.value||r<n.length-1&&"era"===n[r+1].type?t:{type:"literal",value:e}}};function eo(e){return e.toLocaleTimeString((0,z.J)(),{hour:"2-digit",minute:"2-digit"})}function es(e,t){var r,n;return ea(e,(r=U({},t),n=n={time:!0},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):(function(e){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t.push.apply(t,r)}return t})(Object(n)).forEach(function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))}),r))}function el(e,t){var r=et("string"==typeof t?new Intl.Locale(t):t);return r?(0,a.yP)(e,(0,i.d)(r)):e}function eu(e,t){return new Intl.DurationFormat((0,z.J)(),t).format(e)}function ec(e,t){if(null==e)return null;if("string"==typeof e){var r=D(e,(0,z.J)());return r.invalid?(console.warn("Could not interpret '".concat(e,"' as a date")),null):(r.day&&!r.month&&(r=U({},(0,V.A)(r,"day"),{month:r.day})),r.month&&(r.month-=1),r.day&&(r=U({},(0,V.A)(r,"day"),{date:r.day})),M()(t).set(r))}return M()(e)}var ed=["years","months","days","hours","minutes","seconds"],ef={second:"seconds",minute:"minutes",hour:"hours",day:"days",month:"months",year:"years"};function ep(e){var t;return null!=(t=ef[e])?t:e}var eh={seconds:45,minutes:45,hours:22,days:26,months:11,years:1/0};function em(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:M()(),n=arguments.length>2?arguments[2]:void 0,a=M()(r),i=ec(e,a);if(null==i)return null;if("string"==typeof n){var o=ep(n);return $({},o,a.diff(i,o))}var s=null!=n?n:{},l=s.thresholds,u=s.largestUnit,c=s.smallestUnit;if(void 0!==u||void 0!==c){var d,f=c?ep(c):void 0;return d="auto"===u||void 0===u?function(e,t,r){for(var n=ed.indexOf(r),a=0;a<ed.length;a++){var i=ed[a];if(t.diff(e,i)>0)return a<=n?i:r}return r}(i,a,null!=f?f:"seconds"):ep(u),function(e,t,r,n){var a=ed.indexOf(r),i=ed.indexOf(n),o=ed.slice(a,i+1),s={},l=e,u=!0,c=!1,d=void 0;try{for(var f,p=o[Symbol.iterator]();!(u=(f=p.next()).done);u=!0){var h=f.value,m=t.diff(l,h);s[h]=m,l=l.add(m,h)}}catch(e){c=!0,d=e}finally{try{u||null==p.return||p.return()}finally{if(c)throw d}}return s}(i,a,d,null!=f?f:d)}var p=(t=function(e){var t=U({},eh);if(e){var r=!0,n=!1,a=void 0;try{for(var i,o=Object.entries(e)[Symbol.iterator]();!(r=(i=o.next()).done);r=!0){var s,l=(s=i.value,function(e){if(Array.isArray(e))return e}(s)||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),2!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(s)||function(e){if(e){if("string"==typeof e)return W(e,2);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return W(e,2)}}(s)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),u=l[0],c=l[1];void 0!==c&&(t[ep(u)]=c)}}catch(e){n=!0,a=e}finally{try{r||null==o.return||o.return()}finally{if(n)throw a}}}return t}(l),a.diff(i,"seconds")<t.seconds?"seconds":a.diff(i,"minutes")<t.minutes?"minutes":a.diff(i,"hours")<t.hours?"hours":a.diff(i,"days")<t.days?"days":a.diff(i,"months")<t.months?"months":"years");return $({},p,a.diff(i,p))}var ey={style:"short",localeMatcher:"lookup"};function ev(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:M()(),r=arguments.length>2?arguments[2]:void 0,n=em(e,t,r);return null==n?null:eu(n,(void 0===r?"undefined":r&&"u">typeof Symbol&&r.constructor===Symbol?"symbol":typeof r)=="object"&&r.formatOptions?U({},ey,r.formatOptions):ey)}},4232(e,t,r){"use strict";function n(){var e=window.i18next.language;return"ht"===(e=e.replaceAll("_","-"))&&(e="fr-HT"),e}r.d(t,{J:()=>n})},4834(e,t,r){"use strict";r.d(t,{g2:()=>n.g2,kd:()=>function e(t){var r={},n=!0,a=!1,i=void 0;try{for(var o,s=Object.keys(t)[Symbol.iterator]();!(n=(o=s.next()).done);n=!0){var l=o.value;if(c(t[l])&&t[l].hasOwnProperty("_default"))r[l]=t[l]._default;else{if(l.startsWith("_"))continue;c(t[l])?r[l]=e(t[l]):r[l]=t[l]}}}catch(e){a=!0,i=e}finally{try{n||null==s.return||s.return()}finally{if(a)throw i}}return r},JK:()=>a.J,Rt:()=>n.Rt,_g:()=>u,a3:()=>n.a3,LW:()=>n.LW,XE:()=>n.XE,L5:()=>m,bN:()=>l.b,a7:()=>n.a7,sc:()=>i.s,rX:()=>d.r,L8:()=>n.L8,Yq:()=>n.Yq,w7:()=>s,L3:()=>n.L3,fU:()=>n.fU,_U:()=>n._U,d4:()=>n.d4,p0:()=>n.p0,kQ:()=>n.kQ,qE:()=>n.qE,pf:()=>n.pf});var n=r(3903),a=r(4232),i=r(2316);function o(e){if("string"==typeof e&&0!==e.trim().length){var t=e.replaceAll("_","-");try{return new Intl.Locale(t).toString()}catch(e){return}}}function s(e,t,r){if(null==e)return r;var n=o(e);if(!n)return console.warn("matchLocale: invalid requested locale tag: ".concat(JSON.stringify(e))),r;var a=[],i=!0,s=!1,l=void 0;try{for(var u,c=t[Symbol.iterator]();!(i=(u=c.next()).done);i=!0){var d=u.value,f=o(d);if(!f){console.warn("matchLocale: skipping invalid available locale tag: ".concat(JSON.stringify(d)));continue}a.push({canonical:f,original:d})}}catch(e){s=!0,l=e}finally{try{i||null==c.return||c.return()}finally{if(s)throw l}}for(var p=n;p;){var h=function(){var e=a.find(function(e){return e.canonical===p});if(e)return{v:e.original};var t=p+"-",r=a.find(function(e){return e.canonical.startsWith(t)});if(r)return{v:r.original};if("ht"===p)return p="fr-HT","continue";var n=p.lastIndexOf("-");if(-1===n)return"break";var i=(p=p.slice(0,n)).lastIndexOf("-");-1!==i&&p.length-i==2&&(p=p.slice(0,i))}();if("object"==(h&&"u">typeof Symbol&&h.constructor===Symbol?"symbol":typeof h))return h.v;if("break"===h)break}return r}var l=r(8254);function u(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window.localStorage;try{return e.getItem("test"),!0}catch(e){return!1}}function c(e){return!!e&&e.constructor===Object}var d=r(9120);function f(e,t,r,n,a,i,o){try{var s=e[i](o),l=s.value}catch(e){r(e);return}s.done?t(l):Promise.resolve(l).then(n,a)}function p(e){return function(){var t=this,r=arguments;return new Promise(function(n,a){var i=e.apply(t,r);function o(e){f(i,n,a,o,s,"next",e)}function s(e){f(i,n,a,o,s,"throw",e)}o(void 0)})}}function h(e,t){var r,n,a,i={label:0,sent:function(){if(1&a[0])throw a[1];return a[1]},trys:[],ops:[]},o=Object.create(("function"==typeof Iterator?Iterator:Object).prototype),s=Object.defineProperty;return s(o,"next",{value:l(0)}),s(o,"throw",{value:l(1)}),s(o,"return",{value:l(2)}),"function"==typeof Symbol&&s(o,Symbol.iterator,{value:function(){return this}}),o;function l(s){return function(l){var u=[s,l];if(r)throw TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(i=0)),i;)try{if(r=1,n&&(a=2&u[0]?n.return:u[0]?n.throw||((a=n.return)&&a.call(n),0):n.next)&&!(a=a.call(n,u[1])).done)return a;switch(n=0,a&&(u=[2&u[0],a.value]),u[0]){case 0:case 1:a=u;break;case 4:return i.label++,{value:u[1],done:!1};case 5:i.label++,n=u[1],u=[0];continue;case 7:u=i.ops.pop(),i.trys.pop();continue;default:if(!(a=(a=i.trys).length>0&&a[a.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!a||u[1]>a[0]&&u[1]<a[3])){i.label=u[1];break}if(6===u[0]&&i.label<a[1]){i.label=a[1],a=u;break}if(a&&i.label<a[2]){i.label=a[2],i.ops.push(u);break}a[2]&&i.ops.pop(),i.trys.pop();continue}u=t.call(e,i)}catch(e){u=[6,e],n=0}finally{r=a=0}if(5&u[0])throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}}function m(e){return p(function(e){var t,r,n,a,i,o,s,l=arguments;return h(this,function(u){switch(u.label){case 0:r=(t=l.length>1&&void 0!==l[1]?l[1]:{}).shouldRetry,n=t.getDelay,a=t.onError,r=null!=r?r:function(e){return e<=5},n=null!=n?n:function(e){return function(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return t*Math.pow(2,r?e+1:e)}(e,1e3)},i=0,o=void 0,u.label=1;case 1:var c;return u.trys.push([1,4,,5]),[4,(c=n(i),p(function(){return h(this,function(e){return c<=0?[2]:[2,new Promise(function(e){return setTimeout(e,c)})]})})())];case 2:return u.sent(),[4,e()];case 3:return[2,u.sent()];case 4:return s=u.sent(),null==a||a(s,i),o=s,[3,5];case 5:if(r(i++))return[3,1];u.label=6;case 6:throw o}})}).apply(this,arguments)}},9120(e,t,r){"use strict";r.d(t,{r:()=>o});var n=r(8164);function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r<t;r++)n[r]=e[r];return n}function i(e){var t,r=function(e){if(Array.isArray(e))return e}(t=e.split("."))||function(e){var t,r,n=null==e?null:"u">typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a=[],i=!0,o=!1;try{for(n=n.call(e);!(i=(t=n.next()).done)&&(a.push(t.value),3!==a.length);i=!0);}catch(e){o=!0,r=e}finally{try{i||null==n.return||n.return()}finally{if(o)throw r}}return a}}(t)||function(e){if(e){if("string"==typeof e)return a(e,3);var t=Object.prototype.toString.call(e).slice(8,-1);if("Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return a(e,3)}}(t)||function(){throw TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),n=r[0],i=r[1],o=r[2];return"".concat(n,".").concat(i,".").concat(o)}function o(e,t){var r=function(e){var t=e.indexOf("-");if(t>=0){var r=i(e.slice(0,t)),n=e.slice(t+1);return"".concat(r,"-").concat(n)}return i(e)}(t);return n.satisfies(r,e,{includePrerelease:!0})}}}]);