ode-explorer 1.5.1-develop.202411251437 → 1.5.2-develop.202411261453
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.
- package/dist/index.html +1 -1
- package/dist/index.js +3 -3
- package/dist/version.txt +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var sP=t=>{throw TypeError(t)};var DB=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Sb=(t,e,r)=>e.has(t)||sP("Cannot "+r);var Y=(t,e,r)=>(Sb(t,e,"read from private field"),r?r.call(t):e.get(t)),Ze=(t,e,r)=>e.has(t)?sP("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,r),Ne=(t,e,r,n)=>(Sb(t,e,"write to private field"),n?n.call(t,r):e.set(t,r),r),lt=(t,e,r)=>(Sb(t,e,"access private method"),r);var wg=(t,e,r,n)=>({set _(i){Ne(t,e,i,r)},get _(){return Y(t,e,n)}});import{odeServices as Me,FOLDER as Er,LAYER_NAME as NB,SnipletsService as Eb,DocumentHelper as Vk,StringUtils as LB,ERROR_CODE as Gk,SORT_ORDER as FB,ResourceService as Wk,ACTION as Wr}from"/assets/js/edifice-ts-client/index.js?v=
|
|
1
|
+
var sP=t=>{throw TypeError(t)};var DB=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Sb=(t,e,r)=>e.has(t)||sP("Cannot "+r);var Y=(t,e,r)=>(Sb(t,e,"read from private field"),r?r.call(t):e.get(t)),Ze=(t,e,r)=>e.has(t)?sP("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,r),Ne=(t,e,r,n)=>(Sb(t,e,"write to private field"),n?n.call(t,r):e.set(t,r),r),lt=(t,e,r)=>(Sb(t,e,"access private method"),r);var wg=(t,e,r,n)=>({set _(i){Ne(t,e,i,r)},get _(){return Y(t,e,n)}});import{odeServices as Me,FOLDER as Er,LAYER_NAME as NB,SnipletsService as Eb,DocumentHelper as Vk,StringUtils as LB,ERROR_CODE as Gk,SORT_ORDER as FB,ResourceService as Wk,ACTION as Wr}from"/assets/js/edifice-ts-client/index.js?v=059e3b32";var Kme=DB((ige,C1)=>{function Xk(t,e){for(var r=0;r<e.length;r++){const n=e[r];if(typeof n!="string"&&!Array.isArray(n)){for(const i in n)if(i!=="default"&&!(i in t)){const s=Object.getOwnPropertyDescriptor(n,i);s&&Object.defineProperty(t,i,s.get?s:{enumerable:!0,get:()=>n[i]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&n(o)}).observe(document,{childList:!0,subtree:!0});function r(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function n(i){if(i.ep)return;i.ep=!0;const s=r(i);fetch(i.href,s)}})();var rr=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Po(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function qk(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var r=function n(){return this instanceof n?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}),r}var Yk={exports:{}},Gy={},Qk={exports:{}},ft={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* react.production.min.js
|
|
4
4
|
*
|
|
@@ -38,7 +38,7 @@ var sP=t=>{throw TypeError(t)};var DB=(t,e)=>()=>(e||t((e={exports:{}}).exports,
|
|
|
38
38
|
`+i[o].replace(" at new "," at ");return t.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",t.displayName)),l}while(1<=o&&0<=a);break}}}finally{Rb=!1,Error.prepareStackTrace=r}return(t=t?t.displayName||t.name:"")?gf(t):""}function d9(t){switch(t.tag){case 5:return gf(t.type);case 16:return gf("Lazy");case 13:return gf("Suspense");case 19:return gf("SuspenseList");case 0:case 2:case 15:return t=Pb(t.type,!1),t;case 11:return t=Pb(t.type.render,!1),t;case 1:return t=Pb(t.type,!0),t;default:return""}}function L_(t){if(t==null)return null;if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t;switch(t){case Qc:return"Fragment";case Yc:return"Portal";case O_:return"Profiler";case U2:return"StrictMode";case D_:return"Suspense";case N_:return"SuspenseList"}if(typeof t=="object")switch(t.$$typeof){case SO:return(t.displayName||"Context")+".Consumer";case _O:return(t._context.displayName||"Context")+".Provider";case $2:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case z2:return e=t.displayName||null,e!==null?e:L_(t.type)||"Memo";case za:e=t._payload,t=t._init;try{return L_(t(e))}catch{}}return null}function h9(t){var e=t.type;switch(t.tag){case 24:return"Cache";case 9:return(e.displayName||"Context")+".Consumer";case 10:return(e._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return t=e.render,t=t.displayName||t.name||"",e.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case 7:return"Fragment";case 5:return e;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return L_(e);case 8:return e===U2?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e}return null}function Al(t){switch(typeof t){case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function TO(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function f9(t){var e=TO(t)?"checked":"value",r=Object.getOwnPropertyDescriptor(t.constructor.prototype,e),n=""+t[e];if(!t.hasOwnProperty(e)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var i=r.get,s=r.set;return Object.defineProperty(t,e,{configurable:!0,get:function(){return i.call(this)},set:function(o){n=""+o,s.call(this,o)}}),Object.defineProperty(t,e,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(o){n=""+o},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function Cg(t){t._valueTracker||(t._valueTracker=f9(t))}function CO(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var r=e.getValue(),n="";return t&&(n=TO(t)?t.checked?"true":"false":t.value),t=n,t!==r?(e.setValue(t),!0):!1}function Ev(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch{return t.body}}function F_(t,e){var r=e.checked;return Yt({},e,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??t._wrapperState.initialChecked})}function RP(t,e){var r=e.defaultValue==null?"":e.defaultValue,n=e.checked!=null?e.checked:e.defaultChecked;r=Al(e.value!=null?e.value:r),t._wrapperState={initialChecked:n,initialValue:r,controlled:e.type==="checkbox"||e.type==="radio"?e.checked!=null:e.value!=null}}function AO(t,e){e=e.checked,e!=null&&B2(t,"checked",e,!1)}function j_(t,e){AO(t,e);var r=Al(e.value),n=e.type;if(r!=null)n==="number"?(r===0&&t.value===""||t.value!=r)&&(t.value=""+r):t.value!==""+r&&(t.value=""+r);else if(n==="submit"||n==="reset"){t.removeAttribute("value");return}e.hasOwnProperty("value")?B_(t,e.type,r):e.hasOwnProperty("defaultValue")&&B_(t,e.type,Al(e.defaultValue)),e.checked==null&&e.defaultChecked!=null&&(t.defaultChecked=!!e.defaultChecked)}function PP(t,e,r){if(e.hasOwnProperty("value")||e.hasOwnProperty("defaultValue")){var n=e.type;if(!(n!=="submit"&&n!=="reset"||e.value!==void 0&&e.value!==null))return;e=""+t._wrapperState.initialValue,r||e===t.value||(t.value=e),t.defaultValue=e}r=t.name,r!==""&&(t.name=""),t.defaultChecked=!!t._wrapperState.initialChecked,r!==""&&(t.name=r)}function B_(t,e,r){(e!=="number"||Ev(t.ownerDocument)!==t)&&(r==null?t.defaultValue=""+t._wrapperState.initialValue:t.defaultValue!==""+r&&(t.defaultValue=""+r))}var vf=Array.isArray;function hd(t,e,r,n){if(t=t.options,e){e={};for(var i=0;i<r.length;i++)e["$"+r[i]]=!0;for(r=0;r<t.length;r++)i=e.hasOwnProperty("$"+t[r].value),t[r].selected!==i&&(t[r].selected=i),i&&n&&(t[r].defaultSelected=!0)}else{for(r=""+Al(r),e=null,i=0;i<t.length;i++){if(t[i].value===r){t[i].selected=!0,n&&(t[i].defaultSelected=!0);return}e!==null||t[i].disabled||(e=t[i])}e!==null&&(e.selected=!0)}}function U_(t,e){if(e.dangerouslySetInnerHTML!=null)throw Error(pe(91));return Yt({},e,{value:void 0,defaultValue:void 0,children:""+t._wrapperState.initialValue})}function IP(t,e){var r=e.value;if(r==null){if(r=e.children,e=e.defaultValue,r!=null){if(e!=null)throw Error(pe(92));if(vf(r)){if(1<r.length)throw Error(pe(93));r=r[0]}e=r}e==null&&(e=""),r=e}t._wrapperState={initialValue:Al(r)}}function RO(t,e){var r=Al(e.value),n=Al(e.defaultValue);r!=null&&(r=""+r,r!==t.value&&(t.value=r),e.defaultValue==null&&t.defaultValue!==r&&(t.defaultValue=r)),n!=null&&(t.defaultValue=""+n)}function MP(t){var e=t.textContent;e===t._wrapperState.initialValue&&e!==""&&e!==null&&(t.value=e)}function PO(t){switch(t){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function $_(t,e){return t==null||t==="http://www.w3.org/1999/xhtml"?PO(e):t==="http://www.w3.org/2000/svg"&&e==="foreignObject"?"http://www.w3.org/1999/xhtml":t}var Ag,IO=function(t){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(e,r,n,i){MSApp.execUnsafeLocalFunction(function(){return t(e,r,n,i)})}:t}(function(t,e){if(t.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in t)t.innerHTML=e;else{for(Ag=Ag||document.createElement("div"),Ag.innerHTML="<svg>"+e.valueOf().toString()+"</svg>",e=Ag.firstChild;t.firstChild;)t.removeChild(t.firstChild);for(;e.firstChild;)t.appendChild(e.firstChild)}});function up(t,e){if(e){var r=t.firstChild;if(r&&r===t.lastChild&&r.nodeType===3){r.nodeValue=e;return}}t.textContent=e}var Of={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},p9=["Webkit","ms","Moz","O"];Object.keys(Of).forEach(function(t){p9.forEach(function(e){e=e+t.charAt(0).toUpperCase()+t.substring(1),Of[e]=Of[t]})});function MO(t,e,r){return e==null||typeof e=="boolean"||e===""?"":r||typeof e!="number"||e===0||Of.hasOwnProperty(t)&&Of[t]?(""+e).trim():e+"px"}function kO(t,e){t=t.style;for(var r in e)if(e.hasOwnProperty(r)){var n=r.indexOf("--")===0,i=MO(r,e[r],n);r==="float"&&(r="cssFloat"),n?t.setProperty(r,i):t[r]=i}}var m9=Yt({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function z_(t,e){if(e){if(m9[t]&&(e.children!=null||e.dangerouslySetInnerHTML!=null))throw Error(pe(137,t));if(e.dangerouslySetInnerHTML!=null){if(e.children!=null)throw Error(pe(60));if(typeof e.dangerouslySetInnerHTML!="object"||!("__html"in e.dangerouslySetInnerHTML))throw Error(pe(61))}if(e.style!=null&&typeof e.style!="object")throw Error(pe(62))}}function H_(t,e){if(t.indexOf("-")===-1)return typeof e.is=="string";switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var V_=null;function H2(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}var G_=null,fd=null,pd=null;function kP(t){if(t=sm(t)){if(typeof G_!="function")throw Error(pe(280));var e=t.stateNode;e&&(e=Ky(e),G_(t.stateNode,t.type,e))}}function OO(t){fd?pd?pd.push(t):pd=[t]:fd=t}function DO(){if(fd){var t=fd,e=pd;if(pd=fd=null,kP(t),e)for(t=0;t<e.length;t++)kP(e[t])}}function NO(t,e){return t(e)}function LO(){}var Ib=!1;function FO(t,e,r){if(Ib)return t(e,r);Ib=!0;try{return NO(t,e,r)}finally{Ib=!1,(fd!==null||pd!==null)&&(LO(),DO())}}function cp(t,e){var r=t.stateNode;if(r===null)return null;var n=Ky(r);if(n===null)return null;r=n[e];e:switch(e){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(n=!n.disabled)||(t=t.type,n=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!n;break e;default:t=!1}if(t)return null;if(r&&typeof r!="function")throw Error(pe(231,e,typeof r));return r}var W_=!1;if(la)try{var Wh={};Object.defineProperty(Wh,"passive",{get:function(){W_=!0}}),window.addEventListener("test",Wh,Wh),window.removeEventListener("test",Wh,Wh)}catch{W_=!1}function g9(t,e,r,n,i,s,o,a,l){var u=Array.prototype.slice.call(arguments,3);try{e.apply(r,u)}catch(c){this.onError(c)}}var Df=!1,Tv=null,Cv=!1,X_=null,v9={onError:function(t){Df=!0,Tv=t}};function y9(t,e,r,n,i,s,o,a,l){Df=!1,Tv=null,g9.apply(v9,arguments)}function x9(t,e,r,n,i,s,o,a,l){if(y9.apply(this,arguments),Df){if(Df){var u=Tv;Df=!1,Tv=null}else throw Error(pe(198));Cv||(Cv=!0,X_=u)}}function uc(t){var e=t,r=t;if(t.alternate)for(;e.return;)e=e.return;else{t=e;do e=t,e.flags&4098&&(r=e.return),t=e.return;while(t)}return e.tag===3?r:null}function jO(t){if(t.tag===13){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function OP(t){if(uc(t)!==t)throw Error(pe(188))}function b9(t){var e=t.alternate;if(!e){if(e=uc(t),e===null)throw Error(pe(188));return e!==t?null:t}for(var r=t,n=e;;){var i=r.return;if(i===null)break;var s=i.alternate;if(s===null){if(n=i.return,n!==null){r=n;continue}break}if(i.child===s.child){for(s=i.child;s;){if(s===r)return OP(i),t;if(s===n)return OP(i),e;s=s.sibling}throw Error(pe(188))}if(r.return!==n.return)r=i,n=s;else{for(var o=!1,a=i.child;a;){if(a===r){o=!0,r=i,n=s;break}if(a===n){o=!0,n=i,r=s;break}a=a.sibling}if(!o){for(a=s.child;a;){if(a===r){o=!0,r=s,n=i;break}if(a===n){o=!0,n=s,r=i;break}a=a.sibling}if(!o)throw Error(pe(189))}}if(r.alternate!==n)throw Error(pe(190))}if(r.tag!==3)throw Error(pe(188));return r.stateNode.current===r?t:e}function BO(t){return t=b9(t),t!==null?UO(t):null}function UO(t){if(t.tag===5||t.tag===6)return t;for(t=t.child;t!==null;){var e=UO(t);if(e!==null)return e;t=t.sibling}return null}var $O=mi.unstable_scheduleCallback,DP=mi.unstable_cancelCallback,w9=mi.unstable_shouldYield,_9=mi.unstable_requestPaint,lr=mi.unstable_now,S9=mi.unstable_getCurrentPriorityLevel,V2=mi.unstable_ImmediatePriority,zO=mi.unstable_UserBlockingPriority,Av=mi.unstable_NormalPriority,E9=mi.unstable_LowPriority,HO=mi.unstable_IdlePriority,Xy=null,po=null;function T9(t){if(po&&typeof po.onCommitFiberRoot=="function")try{po.onCommitFiberRoot(Xy,t,void 0,(t.current.flags&128)===128)}catch{}}var ws=Math.clz32?Math.clz32:R9,C9=Math.log,A9=Math.LN2;function R9(t){return t>>>=0,t===0?32:31-(C9(t)/A9|0)|0}var Rg=64,Pg=4194304;function yf(t){switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return t&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return t}}function Rv(t,e){var r=t.pendingLanes;if(r===0)return 0;var n=0,i=t.suspendedLanes,s=t.pingedLanes,o=r&268435455;if(o!==0){var a=o&~i;a!==0?n=yf(a):(s&=o,s!==0&&(n=yf(s)))}else o=r&~i,o!==0?n=yf(o):s!==0&&(n=yf(s));if(n===0)return 0;if(e!==0&&e!==n&&!(e&i)&&(i=n&-n,s=e&-e,i>=s||i===16&&(s&4194240)!==0))return e;if(n&4&&(n|=r&16),e=t.entangledLanes,e!==0)for(t=t.entanglements,e&=n;0<e;)r=31-ws(e),i=1<<r,n|=t[r],e&=~i;return n}function P9(t,e){switch(t){case 1:case 2:case 4:return e+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function I9(t,e){for(var r=t.suspendedLanes,n=t.pingedLanes,i=t.expirationTimes,s=t.pendingLanes;0<s;){var o=31-ws(s),a=1<<o,l=i[o];l===-1?(!(a&r)||a&n)&&(i[o]=P9(a,e)):l<=e&&(t.expiredLanes|=a),s&=~a}}function q_(t){return t=t.pendingLanes&-1073741825,t!==0?t:t&1073741824?1073741824:0}function VO(){var t=Rg;return Rg<<=1,!(Rg&4194240)&&(Rg=64),t}function Mb(t){for(var e=[],r=0;31>r;r++)e.push(t);return e}function nm(t,e,r){t.pendingLanes|=e,e!==536870912&&(t.suspendedLanes=0,t.pingedLanes=0),t=t.eventTimes,e=31-ws(e),t[e]=r}function M9(t,e){var r=t.pendingLanes&~e;t.pendingLanes=e,t.suspendedLanes=0,t.pingedLanes=0,t.expiredLanes&=e,t.mutableReadLanes&=e,t.entangledLanes&=e,e=t.entanglements;var n=t.eventTimes;for(t=t.expirationTimes;0<r;){var i=31-ws(r),s=1<<i;e[i]=0,n[i]=-1,t[i]=-1,r&=~s}}function G2(t,e){var r=t.entangledLanes|=e;for(t=t.entanglements;r;){var n=31-ws(r),i=1<<n;i&e|t[n]&e&&(t[n]|=e),r&=~i}}var At=0;function GO(t){return t&=-t,1<t?4<t?t&268435455?16:536870912:4:1}var WO,W2,XO,qO,YO,Y_=!1,Ig=[],gl=null,vl=null,yl=null,dp=new Map,hp=new Map,Wa=[],k9="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function NP(t,e){switch(t){case"focusin":case"focusout":gl=null;break;case"dragenter":case"dragleave":vl=null;break;case"mouseover":case"mouseout":yl=null;break;case"pointerover":case"pointerout":dp.delete(e.pointerId);break;case"gotpointercapture":case"lostpointercapture":hp.delete(e.pointerId)}}function Xh(t,e,r,n,i,s){return t===null||t.nativeEvent!==s?(t={blockedOn:e,domEventName:r,eventSystemFlags:n,nativeEvent:s,targetContainers:[i]},e!==null&&(e=sm(e),e!==null&&W2(e)),t):(t.eventSystemFlags|=n,e=t.targetContainers,i!==null&&e.indexOf(i)===-1&&e.push(i),t)}function O9(t,e,r,n,i){switch(e){case"focusin":return gl=Xh(gl,t,e,r,n,i),!0;case"dragenter":return vl=Xh(vl,t,e,r,n,i),!0;case"mouseover":return yl=Xh(yl,t,e,r,n,i),!0;case"pointerover":var s=i.pointerId;return dp.set(s,Xh(dp.get(s)||null,t,e,r,n,i)),!0;case"gotpointercapture":return s=i.pointerId,hp.set(s,Xh(hp.get(s)||null,t,e,r,n,i)),!0}return!1}function QO(t){var e=Tu(t.target);if(e!==null){var r=uc(e);if(r!==null){if(e=r.tag,e===13){if(e=jO(r),e!==null){t.blockedOn=e,YO(t.priority,function(){XO(r)});return}}else if(e===3&&r.stateNode.current.memoizedState.isDehydrated){t.blockedOn=r.tag===3?r.stateNode.containerInfo:null;return}}}t.blockedOn=null}function B0(t){if(t.blockedOn!==null)return!1;for(var e=t.targetContainers;0<e.length;){var r=Q_(t.domEventName,t.eventSystemFlags,e[0],t.nativeEvent);if(r===null){r=t.nativeEvent;var n=new r.constructor(r.type,r);V_=n,r.target.dispatchEvent(n),V_=null}else return e=sm(r),e!==null&&W2(e),t.blockedOn=r,!1;e.shift()}return!0}function LP(t,e,r){B0(t)&&r.delete(e)}function D9(){Y_=!1,gl!==null&&B0(gl)&&(gl=null),vl!==null&&B0(vl)&&(vl=null),yl!==null&&B0(yl)&&(yl=null),dp.forEach(LP),hp.forEach(LP)}function qh(t,e){t.blockedOn===e&&(t.blockedOn=null,Y_||(Y_=!0,mi.unstable_scheduleCallback(mi.unstable_NormalPriority,D9)))}function fp(t){function e(i){return qh(i,t)}if(0<Ig.length){qh(Ig[0],t);for(var r=1;r<Ig.length;r++){var n=Ig[r];n.blockedOn===t&&(n.blockedOn=null)}}for(gl!==null&&qh(gl,t),vl!==null&&qh(vl,t),yl!==null&&qh(yl,t),dp.forEach(e),hp.forEach(e),r=0;r<Wa.length;r++)n=Wa[r],n.blockedOn===t&&(n.blockedOn=null);for(;0<Wa.length&&(r=Wa[0],r.blockedOn===null);)QO(r),r.blockedOn===null&&Wa.shift()}var md=xa.ReactCurrentBatchConfig,Pv=!0;function N9(t,e,r,n){var i=At,s=md.transition;md.transition=null;try{At=1,X2(t,e,r,n)}finally{At=i,md.transition=s}}function L9(t,e,r,n){var i=At,s=md.transition;md.transition=null;try{At=4,X2(t,e,r,n)}finally{At=i,md.transition=s}}function X2(t,e,r,n){if(Pv){var i=Q_(t,e,r,n);if(i===null)$b(t,e,n,Iv,r),NP(t,n);else if(O9(i,t,e,r,n))n.stopPropagation();else if(NP(t,n),e&4&&-1<k9.indexOf(t)){for(;i!==null;){var s=sm(i);if(s!==null&&WO(s),s=Q_(t,e,r,n),s===null&&$b(t,e,n,Iv,r),s===i)break;i=s}i!==null&&n.stopPropagation()}else $b(t,e,n,null,r)}}var Iv=null;function Q_(t,e,r,n){if(Iv=null,t=H2(n),t=Tu(t),t!==null)if(e=uc(t),e===null)t=null;else if(r=e.tag,r===13){if(t=jO(e),t!==null)return t;t=null}else if(r===3){if(e.stateNode.current.memoizedState.isDehydrated)return e.tag===3?e.stateNode.containerInfo:null;t=null}else e!==t&&(t=null);return Iv=t,null}function KO(t){switch(t){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(S9()){case V2:return 1;case zO:return 4;case Av:case E9:return 16;case HO:return 536870912;default:return 16}default:return 16}}var ol=null,q2=null,U0=null;function ZO(){if(U0)return U0;var t,e=q2,r=e.length,n,i="value"in ol?ol.value:ol.textContent,s=i.length;for(t=0;t<r&&e[t]===i[t];t++);var o=r-t;for(n=1;n<=o&&e[r-n]===i[s-n];n++);return U0=i.slice(t,1<n?1-n:void 0)}function $0(t){var e=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&e===13&&(t=13)):t=e,t===10&&(t=13),32<=t||t===13?t:0}function Mg(){return!0}function FP(){return!1}function yi(t){function e(r,n,i,s,o){this._reactName=r,this._targetInst=i,this.type=n,this.nativeEvent=s,this.target=o,this.currentTarget=null;for(var a in t)t.hasOwnProperty(a)&&(r=t[a],this[a]=r?r(s):s[a]);return this.isDefaultPrevented=(s.defaultPrevented!=null?s.defaultPrevented:s.returnValue===!1)?Mg:FP,this.isPropagationStopped=FP,this}return Yt(e.prototype,{preventDefault:function(){this.defaultPrevented=!0;var r=this.nativeEvent;r&&(r.preventDefault?r.preventDefault():typeof r.returnValue!="unknown"&&(r.returnValue=!1),this.isDefaultPrevented=Mg)},stopPropagation:function(){var r=this.nativeEvent;r&&(r.stopPropagation?r.stopPropagation():typeof r.cancelBubble!="unknown"&&(r.cancelBubble=!0),this.isPropagationStopped=Mg)},persist:function(){},isPersistent:Mg}),e}var ch={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Y2=yi(ch),im=Yt({},ch,{view:0,detail:0}),F9=yi(im),kb,Ob,Yh,qy=Yt({},im,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Q2,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){return"movementX"in t?t.movementX:(t!==Yh&&(Yh&&t.type==="mousemove"?(kb=t.screenX-Yh.screenX,Ob=t.screenY-Yh.screenY):Ob=kb=0,Yh=t),kb)},movementY:function(t){return"movementY"in t?t.movementY:Ob}}),jP=yi(qy),j9=Yt({},qy,{dataTransfer:0}),B9=yi(j9),U9=Yt({},im,{relatedTarget:0}),Db=yi(U9),$9=Yt({},ch,{animationName:0,elapsedTime:0,pseudoElement:0}),z9=yi($9),H9=Yt({},ch,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),V9=yi(H9),G9=Yt({},ch,{data:0}),BP=yi(G9),W9={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},X9={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},q9={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Y9(t){var e=this.nativeEvent;return e.getModifierState?e.getModifierState(t):(t=q9[t])?!!e[t]:!1}function Q2(){return Y9}var Q9=Yt({},im,{key:function(t){if(t.key){var e=W9[t.key]||t.key;if(e!=="Unidentified")return e}return t.type==="keypress"?(t=$0(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?X9[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Q2,charCode:function(t){return t.type==="keypress"?$0(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?$0(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),K9=yi(Q9),Z9=Yt({},qy,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),UP=yi(Z9),J9=Yt({},im,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Q2}),eU=yi(J9),tU=Yt({},ch,{propertyName:0,elapsedTime:0,pseudoElement:0}),rU=yi(tU),nU=Yt({},qy,{deltaX:function(t){return"deltaX"in t?t.deltaX:"wheelDeltaX"in t?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:"wheelDeltaY"in t?-t.wheelDeltaY:"wheelDelta"in t?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),iU=yi(nU),sU=[9,13,27,32],K2=la&&"CompositionEvent"in window,Nf=null;la&&"documentMode"in document&&(Nf=document.documentMode);var oU=la&&"TextEvent"in window&&!Nf,JO=la&&(!K2||Nf&&8<Nf&&11>=Nf),$P=" ",zP=!1;function eD(t,e){switch(t){case"keyup":return sU.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function tD(t){return t=t.detail,typeof t=="object"&&"data"in t?t.data:null}var Kc=!1;function aU(t,e){switch(t){case"compositionend":return tD(e);case"keypress":return e.which!==32?null:(zP=!0,$P);case"textInput":return t=e.data,t===$P&&zP?null:t;default:return null}}function lU(t,e){if(Kc)return t==="compositionend"||!K2&&eD(t,e)?(t=ZO(),U0=q2=ol=null,Kc=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1<e.char.length)return e.char;if(e.which)return String.fromCharCode(e.which)}return null;case"compositionend":return JO&&e.locale!=="ko"?null:e.data;default:return null}}var uU={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function HP(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e==="input"?!!uU[t.type]:e==="textarea"}function rD(t,e,r,n){OO(n),e=Mv(e,"onChange"),0<e.length&&(r=new Y2("onChange","change",null,r,n),t.push({event:r,listeners:e}))}var Lf=null,pp=null;function cU(t){fD(t,0)}function Yy(t){var e=ed(t);if(CO(e))return t}function dU(t,e){if(t==="change")return e}var nD=!1;if(la){var Nb;if(la){var Lb="oninput"in document;if(!Lb){var VP=document.createElement("div");VP.setAttribute("oninput","return;"),Lb=typeof VP.oninput=="function"}Nb=Lb}else Nb=!1;nD=Nb&&(!document.documentMode||9<document.documentMode)}function GP(){Lf&&(Lf.detachEvent("onpropertychange",iD),pp=Lf=null)}function iD(t){if(t.propertyName==="value"&&Yy(pp)){var e=[];rD(e,pp,t,H2(t)),FO(cU,e)}}function hU(t,e,r){t==="focusin"?(GP(),Lf=e,pp=r,Lf.attachEvent("onpropertychange",iD)):t==="focusout"&&GP()}function fU(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return Yy(pp)}function pU(t,e){if(t==="click")return Yy(e)}function mU(t,e){if(t==="input"||t==="change")return Yy(e)}function gU(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}var Cs=typeof Object.is=="function"?Object.is:gU;function mp(t,e){if(Cs(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;var r=Object.keys(t),n=Object.keys(e);if(r.length!==n.length)return!1;for(n=0;n<r.length;n++){var i=r[n];if(!k_.call(e,i)||!Cs(t[i],e[i]))return!1}return!0}function WP(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function XP(t,e){var r=WP(t);t=0;for(var n;r;){if(r.nodeType===3){if(n=t+r.textContent.length,t<=e&&n>=e)return{node:r,offset:e-t};t=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=WP(r)}}function sD(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?sD(t,e.parentNode):"contains"in t?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function oD(){for(var t=window,e=Ev();e instanceof t.HTMLIFrameElement;){try{var r=typeof e.contentWindow.location.href=="string"}catch{r=!1}if(r)t=e.contentWindow;else break;e=Ev(t.document)}return e}function Z2(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}function vU(t){var e=oD(),r=t.focusedElem,n=t.selectionRange;if(e!==r&&r&&r.ownerDocument&&sD(r.ownerDocument.documentElement,r)){if(n!==null&&Z2(r)){if(e=n.start,t=n.end,t===void 0&&(t=e),"selectionStart"in r)r.selectionStart=e,r.selectionEnd=Math.min(t,r.value.length);else if(t=(e=r.ownerDocument||document)&&e.defaultView||window,t.getSelection){t=t.getSelection();var i=r.textContent.length,s=Math.min(n.start,i);n=n.end===void 0?s:Math.min(n.end,i),!t.extend&&s>n&&(i=n,n=s,s=i),i=XP(r,s);var o=XP(r,n);i&&o&&(t.rangeCount!==1||t.anchorNode!==i.node||t.anchorOffset!==i.offset||t.focusNode!==o.node||t.focusOffset!==o.offset)&&(e=e.createRange(),e.setStart(i.node,i.offset),t.removeAllRanges(),s>n?(t.addRange(e),t.extend(o.node,o.offset)):(e.setEnd(o.node,o.offset),t.addRange(e)))}}for(e=[],t=r;t=t.parentNode;)t.nodeType===1&&e.push({element:t,left:t.scrollLeft,top:t.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r<e.length;r++)t=e[r],t.element.scrollLeft=t.left,t.element.scrollTop=t.top}}var yU=la&&"documentMode"in document&&11>=document.documentMode,Zc=null,K_=null,Ff=null,Z_=!1;function qP(t,e,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;Z_||Zc==null||Zc!==Ev(n)||(n=Zc,"selectionStart"in n&&Z2(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Ff&&mp(Ff,n)||(Ff=n,n=Mv(K_,"onSelect"),0<n.length&&(e=new Y2("onSelect","select",null,e,r),t.push({event:e,listeners:n}),e.target=Zc)))}function kg(t,e){var r={};return r[t.toLowerCase()]=e.toLowerCase(),r["Webkit"+t]="webkit"+e,r["Moz"+t]="moz"+e,r}var Jc={animationend:kg("Animation","AnimationEnd"),animationiteration:kg("Animation","AnimationIteration"),animationstart:kg("Animation","AnimationStart"),transitionend:kg("Transition","TransitionEnd")},Fb={},aD={};la&&(aD=document.createElement("div").style,"AnimationEvent"in window||(delete Jc.animationend.animation,delete Jc.animationiteration.animation,delete Jc.animationstart.animation),"TransitionEvent"in window||delete Jc.transitionend.transition);function Qy(t){if(Fb[t])return Fb[t];if(!Jc[t])return t;var e=Jc[t],r;for(r in e)if(e.hasOwnProperty(r)&&r in aD)return Fb[t]=e[r];return t}var lD=Qy("animationend"),uD=Qy("animationiteration"),cD=Qy("animationstart"),dD=Qy("transitionend"),hD=new Map,YP="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Nl(t,e){hD.set(t,e),lc(e,[t])}for(var jb=0;jb<YP.length;jb++){var Bb=YP[jb],xU=Bb.toLowerCase(),bU=Bb[0].toUpperCase()+Bb.slice(1);Nl(xU,"on"+bU)}Nl(lD,"onAnimationEnd");Nl(uD,"onAnimationIteration");Nl(cD,"onAnimationStart");Nl("dblclick","onDoubleClick");Nl("focusin","onFocus");Nl("focusout","onBlur");Nl(dD,"onTransitionEnd");Vd("onMouseEnter",["mouseout","mouseover"]);Vd("onMouseLeave",["mouseout","mouseover"]);Vd("onPointerEnter",["pointerout","pointerover"]);Vd("onPointerLeave",["pointerout","pointerover"]);lc("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));lc("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));lc("onBeforeInput",["compositionend","keypress","textInput","paste"]);lc("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));lc("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));lc("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var xf="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),wU=new Set("cancel close invalid load scroll toggle".split(" ").concat(xf));function QP(t,e,r){var n=t.type||"unknown-event";t.currentTarget=r,x9(n,e,void 0,t),t.currentTarget=null}function fD(t,e){e=(e&4)!==0;for(var r=0;r<t.length;r++){var n=t[r],i=n.event;n=n.listeners;e:{var s=void 0;if(e)for(var o=n.length-1;0<=o;o--){var a=n[o],l=a.instance,u=a.currentTarget;if(a=a.listener,l!==s&&i.isPropagationStopped())break e;QP(i,a,u),s=l}else for(o=0;o<n.length;o++){if(a=n[o],l=a.instance,u=a.currentTarget,a=a.listener,l!==s&&i.isPropagationStopped())break e;QP(i,a,u),s=l}}}if(Cv)throw t=X_,Cv=!1,X_=null,t}function Nt(t,e){var r=e[nS];r===void 0&&(r=e[nS]=new Set);var n=t+"__bubble";r.has(n)||(pD(e,t,2,!1),r.add(n))}function Ub(t,e,r){var n=0;e&&(n|=4),pD(r,t,n,e)}var Og="_reactListening"+Math.random().toString(36).slice(2);function gp(t){if(!t[Og]){t[Og]=!0,wO.forEach(function(r){r!=="selectionchange"&&(wU.has(r)||Ub(r,!1,t),Ub(r,!0,t))});var e=t.nodeType===9?t:t.ownerDocument;e===null||e[Og]||(e[Og]=!0,Ub("selectionchange",!1,e))}}function pD(t,e,r,n){switch(KO(e)){case 1:var i=N9;break;case 4:i=L9;break;default:i=X2}r=i.bind(null,e,r,t),i=void 0,!W_||e!=="touchstart"&&e!=="touchmove"&&e!=="wheel"||(i=!0),n?i!==void 0?t.addEventListener(e,r,{capture:!0,passive:i}):t.addEventListener(e,r,!0):i!==void 0?t.addEventListener(e,r,{passive:i}):t.addEventListener(e,r,!1)}function $b(t,e,r,n,i){var s=n;if(!(e&1)&&!(e&2)&&n!==null)e:for(;;){if(n===null)return;var o=n.tag;if(o===3||o===4){var a=n.stateNode.containerInfo;if(a===i||a.nodeType===8&&a.parentNode===i)break;if(o===4)for(o=n.return;o!==null;){var l=o.tag;if((l===3||l===4)&&(l=o.stateNode.containerInfo,l===i||l.nodeType===8&&l.parentNode===i))return;o=o.return}for(;a!==null;){if(o=Tu(a),o===null)return;if(l=o.tag,l===5||l===6){n=s=o;continue e}a=a.parentNode}}n=n.return}FO(function(){var u=s,c=H2(r),h=[];e:{var f=hD.get(t);if(f!==void 0){var m=Y2,y=t;switch(t){case"keypress":if($0(r)===0)break e;case"keydown":case"keyup":m=K9;break;case"focusin":y="focus",m=Db;break;case"focusout":y="blur",m=Db;break;case"beforeblur":case"afterblur":m=Db;break;case"click":if(r.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":m=jP;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":m=B9;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":m=eU;break;case lD:case uD:case cD:m=z9;break;case dD:m=rU;break;case"scroll":m=F9;break;case"wheel":m=iU;break;case"copy":case"cut":case"paste":m=V9;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":m=UP}var v=(e&4)!==0,x=!v&&t==="scroll",b=v?f!==null?f+"Capture":null:f;v=[];for(var _=u,w;_!==null;){w=_;var E=w.stateNode;if(w.tag===5&&E!==null&&(w=E,b!==null&&(E=cp(_,b),E!=null&&v.push(vp(_,E,w)))),x)break;_=_.return}0<v.length&&(f=new m(f,y,null,r,c),h.push({event:f,listeners:v}))}}if(!(e&7)){e:{if(f=t==="mouseover"||t==="pointerover",m=t==="mouseout"||t==="pointerout",f&&r!==V_&&(y=r.relatedTarget||r.fromElement)&&(Tu(y)||y[ua]))break e;if((m||f)&&(f=c.window===c?c:(f=c.ownerDocument)?f.defaultView||f.parentWindow:window,m?(y=r.relatedTarget||r.toElement,m=u,y=y?Tu(y):null,y!==null&&(x=uc(y),y!==x||y.tag!==5&&y.tag!==6)&&(y=null)):(m=null,y=u),m!==y)){if(v=jP,E="onMouseLeave",b="onMouseEnter",_="mouse",(t==="pointerout"||t==="pointerover")&&(v=UP,E="onPointerLeave",b="onPointerEnter",_="pointer"),x=m==null?f:ed(m),w=y==null?f:ed(y),f=new v(E,_+"leave",m,r,c),f.target=x,f.relatedTarget=w,E=null,Tu(c)===u&&(v=new v(b,_+"enter",y,r,c),v.target=w,v.relatedTarget=x,E=v),x=E,m&&y)t:{for(v=m,b=y,_=0,w=v;w;w=kc(w))_++;for(w=0,E=b;E;E=kc(E))w++;for(;0<_-w;)v=kc(v),_--;for(;0<w-_;)b=kc(b),w--;for(;_--;){if(v===b||b!==null&&v===b.alternate)break t;v=kc(v),b=kc(b)}v=null}else v=null;m!==null&&KP(h,f,m,v,!1),y!==null&&x!==null&&KP(h,x,y,v,!0)}}e:{if(f=u?ed(u):window,m=f.nodeName&&f.nodeName.toLowerCase(),m==="select"||m==="input"&&f.type==="file")var A=dU;else if(HP(f))if(nD)A=mU;else{A=fU;var P=hU}else(m=f.nodeName)&&m.toLowerCase()==="input"&&(f.type==="checkbox"||f.type==="radio")&&(A=pU);if(A&&(A=A(t,u))){rD(h,A,r,c);break e}P&&P(t,f,u),t==="focusout"&&(P=f._wrapperState)&&P.controlled&&f.type==="number"&&B_(f,"number",f.value)}switch(P=u?ed(u):window,t){case"focusin":(HP(P)||P.contentEditable==="true")&&(Zc=P,K_=u,Ff=null);break;case"focusout":Ff=K_=Zc=null;break;case"mousedown":Z_=!0;break;case"contextmenu":case"mouseup":case"dragend":Z_=!1,qP(h,r,c);break;case"selectionchange":if(yU)break;case"keydown":case"keyup":qP(h,r,c)}var I;if(K2)e:{switch(t){case"compositionstart":var M="onCompositionStart";break e;case"compositionend":M="onCompositionEnd";break e;case"compositionupdate":M="onCompositionUpdate";break e}M=void 0}else Kc?eD(t,r)&&(M="onCompositionEnd"):t==="keydown"&&r.keyCode===229&&(M="onCompositionStart");M&&(JO&&r.locale!=="ko"&&(Kc||M!=="onCompositionStart"?M==="onCompositionEnd"&&Kc&&(I=ZO()):(ol=c,q2="value"in ol?ol.value:ol.textContent,Kc=!0)),P=Mv(u,M),0<P.length&&(M=new BP(M,t,null,r,c),h.push({event:M,listeners:P}),I?M.data=I:(I=tD(r),I!==null&&(M.data=I)))),(I=oU?aU(t,r):lU(t,r))&&(u=Mv(u,"onBeforeInput"),0<u.length&&(c=new BP("onBeforeInput","beforeinput",null,r,c),h.push({event:c,listeners:u}),c.data=I))}fD(h,e)})}function vp(t,e,r){return{instance:t,listener:e,currentTarget:r}}function Mv(t,e){for(var r=e+"Capture",n=[];t!==null;){var i=t,s=i.stateNode;i.tag===5&&s!==null&&(i=s,s=cp(t,r),s!=null&&n.unshift(vp(t,s,i)),s=cp(t,e),s!=null&&n.push(vp(t,s,i))),t=t.return}return n}function kc(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5);return t||null}function KP(t,e,r,n,i){for(var s=e._reactName,o=[];r!==null&&r!==n;){var a=r,l=a.alternate,u=a.stateNode;if(l!==null&&l===n)break;a.tag===5&&u!==null&&(a=u,i?(l=cp(r,s),l!=null&&o.unshift(vp(r,l,a))):i||(l=cp(r,s),l!=null&&o.push(vp(r,l,a)))),r=r.return}o.length!==0&&t.push({event:e,listeners:o})}var _U=/\r\n?/g,SU=/\u0000|\uFFFD/g;function ZP(t){return(typeof t=="string"?t:""+t).replace(_U,`
|
|
39
39
|
`).replace(SU,"")}function Dg(t,e,r){if(e=ZP(e),ZP(t)!==e&&r)throw Error(pe(425))}function kv(){}var J_=null,eS=null;function tS(t,e){return t==="textarea"||t==="noscript"||typeof e.children=="string"||typeof e.children=="number"||typeof e.dangerouslySetInnerHTML=="object"&&e.dangerouslySetInnerHTML!==null&&e.dangerouslySetInnerHTML.__html!=null}var rS=typeof setTimeout=="function"?setTimeout:void 0,EU=typeof clearTimeout=="function"?clearTimeout:void 0,JP=typeof Promise=="function"?Promise:void 0,TU=typeof queueMicrotask=="function"?queueMicrotask:typeof JP<"u"?function(t){return JP.resolve(null).then(t).catch(CU)}:rS;function CU(t){setTimeout(function(){throw t})}function zb(t,e){var r=e,n=0;do{var i=r.nextSibling;if(t.removeChild(r),i&&i.nodeType===8)if(r=i.data,r==="/$"){if(n===0){t.removeChild(i),fp(e);return}n--}else r!=="$"&&r!=="$?"&&r!=="$!"||n++;r=i}while(r);fp(e)}function xl(t){for(;t!=null;t=t.nextSibling){var e=t.nodeType;if(e===1||e===3)break;if(e===8){if(e=t.data,e==="$"||e==="$!"||e==="$?")break;if(e==="/$")return null}}return t}function eI(t){t=t.previousSibling;for(var e=0;t;){if(t.nodeType===8){var r=t.data;if(r==="$"||r==="$!"||r==="$?"){if(e===0)return t;e--}else r==="/$"&&e++}t=t.previousSibling}return null}var dh=Math.random().toString(36).slice(2),oo="__reactFiber$"+dh,yp="__reactProps$"+dh,ua="__reactContainer$"+dh,nS="__reactEvents$"+dh,AU="__reactListeners$"+dh,RU="__reactHandles$"+dh;function Tu(t){var e=t[oo];if(e)return e;for(var r=t.parentNode;r;){if(e=r[ua]||r[oo]){if(r=e.alternate,e.child!==null||r!==null&&r.child!==null)for(t=eI(t);t!==null;){if(r=t[oo])return r;t=eI(t)}return e}t=r,r=t.parentNode}return null}function sm(t){return t=t[oo]||t[ua],!t||t.tag!==5&&t.tag!==6&&t.tag!==13&&t.tag!==3?null:t}function ed(t){if(t.tag===5||t.tag===6)return t.stateNode;throw Error(pe(33))}function Ky(t){return t[yp]||null}var iS=[],td=-1;function Ll(t){return{current:t}}function Ft(t){0>td||(t.current=iS[td],iS[td]=null,td--)}function Mt(t,e){td++,iS[td]=t.current,t.current=e}var Rl={},hn=Ll(Rl),Gn=Ll(!1),Xu=Rl;function Gd(t,e){var r=t.type.contextTypes;if(!r)return Rl;var n=t.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===e)return n.__reactInternalMemoizedMaskedChildContext;var i={},s;for(s in r)i[s]=e[s];return n&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=e,t.__reactInternalMemoizedMaskedChildContext=i),i}function Wn(t){return t=t.childContextTypes,t!=null}function Ov(){Ft(Gn),Ft(hn)}function tI(t,e,r){if(hn.current!==Rl)throw Error(pe(168));Mt(hn,e),Mt(Gn,r)}function mD(t,e,r){var n=t.stateNode;if(e=e.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var i in n)if(!(i in e))throw Error(pe(108,h9(t)||"Unknown",i));return Yt({},r,n)}function Dv(t){return t=(t=t.stateNode)&&t.__reactInternalMemoizedMergedChildContext||Rl,Xu=hn.current,Mt(hn,t),Mt(Gn,Gn.current),!0}function rI(t,e,r){var n=t.stateNode;if(!n)throw Error(pe(169));r?(t=mD(t,e,Xu),n.__reactInternalMemoizedMergedChildContext=t,Ft(Gn),Ft(hn),Mt(hn,t)):Ft(Gn),Mt(Gn,r)}var qo=null,Zy=!1,Hb=!1;function gD(t){qo===null?qo=[t]:qo.push(t)}function PU(t){Zy=!0,gD(t)}function Fl(){if(!Hb&&qo!==null){Hb=!0;var t=0,e=At;try{var r=qo;for(At=1;t<r.length;t++){var n=r[t];do n=n(!0);while(n!==null)}qo=null,Zy=!1}catch(i){throw qo!==null&&(qo=qo.slice(t+1)),$O(V2,Fl),i}finally{At=e,Hb=!1}}return null}var rd=[],nd=0,Nv=null,Lv=0,Di=[],Ni=0,qu=null,Qo=1,Ko="";function pu(t,e){rd[nd++]=Lv,rd[nd++]=Nv,Nv=t,Lv=e}function vD(t,e,r){Di[Ni++]=Qo,Di[Ni++]=Ko,Di[Ni++]=qu,qu=t;var n=Qo;t=Ko;var i=32-ws(n)-1;n&=~(1<<i),r+=1;var s=32-ws(e)+i;if(30<s){var o=i-i%5;s=(n&(1<<o)-1).toString(32),n>>=o,i-=o,Qo=1<<32-ws(e)+i|r<<i|n,Ko=s+t}else Qo=1<<s|r<<i|n,Ko=t}function J2(t){t.return!==null&&(pu(t,1),vD(t,1,0))}function eT(t){for(;t===Nv;)Nv=rd[--nd],rd[nd]=null,Lv=rd[--nd],rd[nd]=null;for(;t===qu;)qu=Di[--Ni],Di[Ni]=null,Ko=Di[--Ni],Di[Ni]=null,Qo=Di[--Ni],Di[Ni]=null}var hi=null,ci=null,zt=!1,fs=null;function yD(t,e){var r=Bi(5,null,null,0);r.elementType="DELETED",r.stateNode=e,r.return=t,e=t.deletions,e===null?(t.deletions=[r],t.flags|=16):e.push(r)}function nI(t,e){switch(t.tag){case 5:var r=t.type;return e=e.nodeType!==1||r.toLowerCase()!==e.nodeName.toLowerCase()?null:e,e!==null?(t.stateNode=e,hi=t,ci=xl(e.firstChild),!0):!1;case 6:return e=t.pendingProps===""||e.nodeType!==3?null:e,e!==null?(t.stateNode=e,hi=t,ci=null,!0):!1;case 13:return e=e.nodeType!==8?null:e,e!==null?(r=qu!==null?{id:Qo,overflow:Ko}:null,t.memoizedState={dehydrated:e,treeContext:r,retryLane:1073741824},r=Bi(18,null,null,0),r.stateNode=e,r.return=t,t.child=r,hi=t,ci=null,!0):!1;default:return!1}}function sS(t){return(t.mode&1)!==0&&(t.flags&128)===0}function oS(t){if(zt){var e=ci;if(e){var r=e;if(!nI(t,e)){if(sS(t))throw Error(pe(418));e=xl(r.nextSibling);var n=hi;e&&nI(t,e)?yD(n,r):(t.flags=t.flags&-4097|2,zt=!1,hi=t)}}else{if(sS(t))throw Error(pe(418));t.flags=t.flags&-4097|2,zt=!1,hi=t}}}function iI(t){for(t=t.return;t!==null&&t.tag!==5&&t.tag!==3&&t.tag!==13;)t=t.return;hi=t}function Ng(t){if(t!==hi)return!1;if(!zt)return iI(t),zt=!0,!1;var e;if((e=t.tag!==3)&&!(e=t.tag!==5)&&(e=t.type,e=e!=="head"&&e!=="body"&&!tS(t.type,t.memoizedProps)),e&&(e=ci)){if(sS(t))throw xD(),Error(pe(418));for(;e;)yD(t,e),e=xl(e.nextSibling)}if(iI(t),t.tag===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(pe(317));e:{for(t=t.nextSibling,e=0;t;){if(t.nodeType===8){var r=t.data;if(r==="/$"){if(e===0){ci=xl(t.nextSibling);break e}e--}else r!=="$"&&r!=="$!"&&r!=="$?"||e++}t=t.nextSibling}ci=null}}else ci=hi?xl(t.stateNode.nextSibling):null;return!0}function xD(){for(var t=ci;t;)t=xl(t.nextSibling)}function Wd(){ci=hi=null,zt=!1}function tT(t){fs===null?fs=[t]:fs.push(t)}var IU=xa.ReactCurrentBatchConfig;function Qh(t,e,r){if(t=r.ref,t!==null&&typeof t!="function"&&typeof t!="object"){if(r._owner){if(r=r._owner,r){if(r.tag!==1)throw Error(pe(309));var n=r.stateNode}if(!n)throw Error(pe(147,t));var i=n,s=""+t;return e!==null&&e.ref!==null&&typeof e.ref=="function"&&e.ref._stringRef===s?e.ref:(e=function(o){var a=i.refs;o===null?delete a[s]:a[s]=o},e._stringRef=s,e)}if(typeof t!="string")throw Error(pe(284));if(!r._owner)throw Error(pe(290,t))}return t}function Lg(t,e){throw t=Object.prototype.toString.call(e),Error(pe(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t))}function sI(t){var e=t._init;return e(t._payload)}function bD(t){function e(b,_){if(t){var w=b.deletions;w===null?(b.deletions=[_],b.flags|=16):w.push(_)}}function r(b,_){if(!t)return null;for(;_!==null;)e(b,_),_=_.sibling;return null}function n(b,_){for(b=new Map;_!==null;)_.key!==null?b.set(_.key,_):b.set(_.index,_),_=_.sibling;return b}function i(b,_){return b=Sl(b,_),b.index=0,b.sibling=null,b}function s(b,_,w){return b.index=w,t?(w=b.alternate,w!==null?(w=w.index,w<_?(b.flags|=2,_):w):(b.flags|=2,_)):(b.flags|=1048576,_)}function o(b){return t&&b.alternate===null&&(b.flags|=2),b}function a(b,_,w,E){return _===null||_.tag!==6?(_=Qb(w,b.mode,E),_.return=b,_):(_=i(_,w),_.return=b,_)}function l(b,_,w,E){var A=w.type;return A===Qc?c(b,_,w.props.children,E,w.key):_!==null&&(_.elementType===A||typeof A=="object"&&A!==null&&A.$$typeof===za&&sI(A)===_.type)?(E=i(_,w.props),E.ref=Qh(b,_,w),E.return=b,E):(E=q0(w.type,w.key,w.props,null,b.mode,E),E.ref=Qh(b,_,w),E.return=b,E)}function u(b,_,w,E){return _===null||_.tag!==4||_.stateNode.containerInfo!==w.containerInfo||_.stateNode.implementation!==w.implementation?(_=Kb(w,b.mode,E),_.return=b,_):(_=i(_,w.children||[]),_.return=b,_)}function c(b,_,w,E,A){return _===null||_.tag!==7?(_=Bu(w,b.mode,E,A),_.return=b,_):(_=i(_,w),_.return=b,_)}function h(b,_,w){if(typeof _=="string"&&_!==""||typeof _=="number")return _=Qb(""+_,b.mode,w),_.return=b,_;if(typeof _=="object"&&_!==null){switch(_.$$typeof){case Tg:return w=q0(_.type,_.key,_.props,null,b.mode,w),w.ref=Qh(b,null,_),w.return=b,w;case Yc:return _=Kb(_,b.mode,w),_.return=b,_;case za:var E=_._init;return h(b,E(_._payload),w)}if(vf(_)||Gh(_))return _=Bu(_,b.mode,w,null),_.return=b,_;Lg(b,_)}return null}function f(b,_,w,E){var A=_!==null?_.key:null;if(typeof w=="string"&&w!==""||typeof w=="number")return A!==null?null:a(b,_,""+w,E);if(typeof w=="object"&&w!==null){switch(w.$$typeof){case Tg:return w.key===A?l(b,_,w,E):null;case Yc:return w.key===A?u(b,_,w,E):null;case za:return A=w._init,f(b,_,A(w._payload),E)}if(vf(w)||Gh(w))return A!==null?null:c(b,_,w,E,null);Lg(b,w)}return null}function m(b,_,w,E,A){if(typeof E=="string"&&E!==""||typeof E=="number")return b=b.get(w)||null,a(_,b,""+E,A);if(typeof E=="object"&&E!==null){switch(E.$$typeof){case Tg:return b=b.get(E.key===null?w:E.key)||null,l(_,b,E,A);case Yc:return b=b.get(E.key===null?w:E.key)||null,u(_,b,E,A);case za:var P=E._init;return m(b,_,w,P(E._payload),A)}if(vf(E)||Gh(E))return b=b.get(w)||null,c(_,b,E,A,null);Lg(_,E)}return null}function y(b,_,w,E){for(var A=null,P=null,I=_,M=_=0,N=null;I!==null&&M<w.length;M++){I.index>M?(N=I,I=null):N=I.sibling;var z=f(b,I,w[M],E);if(z===null){I===null&&(I=N);break}t&&I&&z.alternate===null&&e(b,I),_=s(z,_,M),P===null?A=z:P.sibling=z,P=z,I=N}if(M===w.length)return r(b,I),zt&&pu(b,M),A;if(I===null){for(;M<w.length;M++)I=h(b,w[M],E),I!==null&&(_=s(I,_,M),P===null?A=I:P.sibling=I,P=I);return zt&&pu(b,M),A}for(I=n(b,I);M<w.length;M++)N=m(I,b,M,w[M],E),N!==null&&(t&&N.alternate!==null&&I.delete(N.key===null?M:N.key),_=s(N,_,M),P===null?A=N:P.sibling=N,P=N);return t&&I.forEach(function(j){return e(b,j)}),zt&&pu(b,M),A}function v(b,_,w,E){var A=Gh(w);if(typeof A!="function")throw Error(pe(150));if(w=A.call(w),w==null)throw Error(pe(151));for(var P=A=null,I=_,M=_=0,N=null,z=w.next();I!==null&&!z.done;M++,z=w.next()){I.index>M?(N=I,I=null):N=I.sibling;var j=f(b,I,z.value,E);if(j===null){I===null&&(I=N);break}t&&I&&j.alternate===null&&e(b,I),_=s(j,_,M),P===null?A=j:P.sibling=j,P=j,I=N}if(z.done)return r(b,I),zt&&pu(b,M),A;if(I===null){for(;!z.done;M++,z=w.next())z=h(b,z.value,E),z!==null&&(_=s(z,_,M),P===null?A=z:P.sibling=z,P=z);return zt&&pu(b,M),A}for(I=n(b,I);!z.done;M++,z=w.next())z=m(I,b,M,z.value,E),z!==null&&(t&&z.alternate!==null&&I.delete(z.key===null?M:z.key),_=s(z,_,M),P===null?A=z:P.sibling=z,P=z);return t&&I.forEach(function(H){return e(b,H)}),zt&&pu(b,M),A}function x(b,_,w,E){if(typeof w=="object"&&w!==null&&w.type===Qc&&w.key===null&&(w=w.props.children),typeof w=="object"&&w!==null){switch(w.$$typeof){case Tg:e:{for(var A=w.key,P=_;P!==null;){if(P.key===A){if(A=w.type,A===Qc){if(P.tag===7){r(b,P.sibling),_=i(P,w.props.children),_.return=b,b=_;break e}}else if(P.elementType===A||typeof A=="object"&&A!==null&&A.$$typeof===za&&sI(A)===P.type){r(b,P.sibling),_=i(P,w.props),_.ref=Qh(b,P,w),_.return=b,b=_;break e}r(b,P);break}else e(b,P);P=P.sibling}w.type===Qc?(_=Bu(w.props.children,b.mode,E,w.key),_.return=b,b=_):(E=q0(w.type,w.key,w.props,null,b.mode,E),E.ref=Qh(b,_,w),E.return=b,b=E)}return o(b);case Yc:e:{for(P=w.key;_!==null;){if(_.key===P)if(_.tag===4&&_.stateNode.containerInfo===w.containerInfo&&_.stateNode.implementation===w.implementation){r(b,_.sibling),_=i(_,w.children||[]),_.return=b,b=_;break e}else{r(b,_);break}else e(b,_);_=_.sibling}_=Kb(w,b.mode,E),_.return=b,b=_}return o(b);case za:return P=w._init,x(b,_,P(w._payload),E)}if(vf(w))return y(b,_,w,E);if(Gh(w))return v(b,_,w,E);Lg(b,w)}return typeof w=="string"&&w!==""||typeof w=="number"?(w=""+w,_!==null&&_.tag===6?(r(b,_.sibling),_=i(_,w),_.return=b,b=_):(r(b,_),_=Qb(w,b.mode,E),_.return=b,b=_),o(b)):r(b,_)}return x}var Xd=bD(!0),wD=bD(!1),Fv=Ll(null),jv=null,id=null,rT=null;function nT(){rT=id=jv=null}function iT(t){var e=Fv.current;Ft(Fv),t._currentValue=e}function aS(t,e,r){for(;t!==null;){var n=t.alternate;if((t.childLanes&e)!==e?(t.childLanes|=e,n!==null&&(n.childLanes|=e)):n!==null&&(n.childLanes&e)!==e&&(n.childLanes|=e),t===r)break;t=t.return}}function gd(t,e){jv=t,rT=id=null,t=t.dependencies,t!==null&&t.firstContext!==null&&(t.lanes&e&&(Hn=!0),t.firstContext=null)}function Xi(t){var e=t._currentValue;if(rT!==t)if(t={context:t,memoizedValue:e,next:null},id===null){if(jv===null)throw Error(pe(308));id=t,jv.dependencies={lanes:0,firstContext:t}}else id=id.next=t;return e}var Cu=null;function sT(t){Cu===null?Cu=[t]:Cu.push(t)}function _D(t,e,r,n){var i=e.interleaved;return i===null?(r.next=r,sT(e)):(r.next=i.next,i.next=r),e.interleaved=r,ca(t,n)}function ca(t,e){t.lanes|=e;var r=t.alternate;for(r!==null&&(r.lanes|=e),r=t,t=t.return;t!==null;)t.childLanes|=e,r=t.alternate,r!==null&&(r.childLanes|=e),r=t,t=t.return;return r.tag===3?r.stateNode:null}var Ha=!1;function oT(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function SD(t,e){t=t.updateQueue,e.updateQueue===t&&(e.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,effects:t.effects})}function na(t,e){return{eventTime:t,lane:e,tag:0,payload:null,callback:null,next:null}}function bl(t,e,r){var n=t.updateQueue;if(n===null)return null;if(n=n.shared,bt&2){var i=n.pending;return i===null?e.next=e:(e.next=i.next,i.next=e),n.pending=e,ca(t,r)}return i=n.interleaved,i===null?(e.next=e,sT(n)):(e.next=i.next,i.next=e),n.interleaved=e,ca(t,r)}function z0(t,e,r){if(e=e.updateQueue,e!==null&&(e=e.shared,(r&4194240)!==0)){var n=e.lanes;n&=t.pendingLanes,r|=n,e.lanes=r,G2(t,r)}}function oI(t,e){var r=t.updateQueue,n=t.alternate;if(n!==null&&(n=n.updateQueue,r===n)){var i=null,s=null;if(r=r.firstBaseUpdate,r!==null){do{var o={eventTime:r.eventTime,lane:r.lane,tag:r.tag,payload:r.payload,callback:r.callback,next:null};s===null?i=s=o:s=s.next=o,r=r.next}while(r!==null);s===null?i=s=e:s=s.next=e}else i=s=e;r={baseState:n.baseState,firstBaseUpdate:i,lastBaseUpdate:s,shared:n.shared,effects:n.effects},t.updateQueue=r;return}t=r.lastBaseUpdate,t===null?r.firstBaseUpdate=e:t.next=e,r.lastBaseUpdate=e}function Bv(t,e,r,n){var i=t.updateQueue;Ha=!1;var s=i.firstBaseUpdate,o=i.lastBaseUpdate,a=i.shared.pending;if(a!==null){i.shared.pending=null;var l=a,u=l.next;l.next=null,o===null?s=u:o.next=u,o=l;var c=t.alternate;c!==null&&(c=c.updateQueue,a=c.lastBaseUpdate,a!==o&&(a===null?c.firstBaseUpdate=u:a.next=u,c.lastBaseUpdate=l))}if(s!==null){var h=i.baseState;o=0,c=u=l=null,a=s;do{var f=a.lane,m=a.eventTime;if((n&f)===f){c!==null&&(c=c.next={eventTime:m,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var y=t,v=a;switch(f=e,m=r,v.tag){case 1:if(y=v.payload,typeof y=="function"){h=y.call(m,h,f);break e}h=y;break e;case 3:y.flags=y.flags&-65537|128;case 0:if(y=v.payload,f=typeof y=="function"?y.call(m,h,f):y,f==null)break e;h=Yt({},h,f);break e;case 2:Ha=!0}}a.callback!==null&&a.lane!==0&&(t.flags|=64,f=i.effects,f===null?i.effects=[a]:f.push(a))}else m={eventTime:m,lane:f,tag:a.tag,payload:a.payload,callback:a.callback,next:null},c===null?(u=c=m,l=h):c=c.next=m,o|=f;if(a=a.next,a===null){if(a=i.shared.pending,a===null)break;f=a,a=f.next,f.next=null,i.lastBaseUpdate=f,i.shared.pending=null}}while(!0);if(c===null&&(l=h),i.baseState=l,i.firstBaseUpdate=u,i.lastBaseUpdate=c,e=i.shared.interleaved,e!==null){i=e;do o|=i.lane,i=i.next;while(i!==e)}else s===null&&(i.shared.lanes=0);Qu|=o,t.lanes=o,t.memoizedState=h}}function aI(t,e,r){if(t=e.effects,e.effects=null,t!==null)for(e=0;e<t.length;e++){var n=t[e],i=n.callback;if(i!==null){if(n.callback=null,n=r,typeof i!="function")throw Error(pe(191,i));i.call(n)}}}var om={},mo=Ll(om),xp=Ll(om),bp=Ll(om);function Au(t){if(t===om)throw Error(pe(174));return t}function aT(t,e){switch(Mt(bp,e),Mt(xp,t),Mt(mo,om),t=e.nodeType,t){case 9:case 11:e=(e=e.documentElement)?e.namespaceURI:$_(null,"");break;default:t=t===8?e.parentNode:e,e=t.namespaceURI||null,t=t.tagName,e=$_(e,t)}Ft(mo),Mt(mo,e)}function qd(){Ft(mo),Ft(xp),Ft(bp)}function ED(t){Au(bp.current);var e=Au(mo.current),r=$_(e,t.type);e!==r&&(Mt(xp,t),Mt(mo,r))}function lT(t){xp.current===t&&(Ft(mo),Ft(xp))}var Wt=Ll(0);function Uv(t){for(var e=t;e!==null;){if(e.tag===13){var r=e.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return e}else if(e.tag===19&&e.memoizedProps.revealOrder!==void 0){if(e.flags&128)return e}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return null;e=e.return}e.sibling.return=e.return,e=e.sibling}return null}var Vb=[];function uT(){for(var t=0;t<Vb.length;t++)Vb[t]._workInProgressVersionPrimary=null;Vb.length=0}var H0=xa.ReactCurrentDispatcher,Gb=xa.ReactCurrentBatchConfig,Yu=0,qt=null,wr=null,Fr=null,$v=!1,jf=!1,wp=0,MU=0;function ln(){throw Error(pe(321))}function cT(t,e){if(e===null)return!1;for(var r=0;r<e.length&&r<t.length;r++)if(!Cs(t[r],e[r]))return!1;return!0}function dT(t,e,r,n,i,s){if(Yu=s,qt=e,e.memoizedState=null,e.updateQueue=null,e.lanes=0,H0.current=t===null||t.memoizedState===null?NU:LU,t=r(n,i),jf){s=0;do{if(jf=!1,wp=0,25<=s)throw Error(pe(301));s+=1,Fr=wr=null,e.updateQueue=null,H0.current=FU,t=r(n,i)}while(jf)}if(H0.current=zv,e=wr!==null&&wr.next!==null,Yu=0,Fr=wr=qt=null,$v=!1,e)throw Error(pe(300));return t}function hT(){var t=wp!==0;return wp=0,t}function Qs(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Fr===null?qt.memoizedState=Fr=t:Fr=Fr.next=t,Fr}function qi(){if(wr===null){var t=qt.alternate;t=t!==null?t.memoizedState:null}else t=wr.next;var e=Fr===null?qt.memoizedState:Fr.next;if(e!==null)Fr=e,wr=t;else{if(t===null)throw Error(pe(310));wr=t,t={memoizedState:wr.memoizedState,baseState:wr.baseState,baseQueue:wr.baseQueue,queue:wr.queue,next:null},Fr===null?qt.memoizedState=Fr=t:Fr=Fr.next=t}return Fr}function _p(t,e){return typeof e=="function"?e(t):e}function Wb(t){var e=qi(),r=e.queue;if(r===null)throw Error(pe(311));r.lastRenderedReducer=t;var n=wr,i=n.baseQueue,s=r.pending;if(s!==null){if(i!==null){var o=i.next;i.next=s.next,s.next=o}n.baseQueue=i=s,r.pending=null}if(i!==null){s=i.next,n=n.baseState;var a=o=null,l=null,u=s;do{var c=u.lane;if((Yu&c)===c)l!==null&&(l=l.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),n=u.hasEagerState?u.eagerState:t(n,u.action);else{var h={lane:c,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};l===null?(a=l=h,o=n):l=l.next=h,qt.lanes|=c,Qu|=c}u=u.next}while(u!==null&&u!==s);l===null?o=n:l.next=a,Cs(n,e.memoizedState)||(Hn=!0),e.memoizedState=n,e.baseState=o,e.baseQueue=l,r.lastRenderedState=n}if(t=r.interleaved,t!==null){i=t;do s=i.lane,qt.lanes|=s,Qu|=s,i=i.next;while(i!==t)}else i===null&&(r.lanes=0);return[e.memoizedState,r.dispatch]}function Xb(t){var e=qi(),r=e.queue;if(r===null)throw Error(pe(311));r.lastRenderedReducer=t;var n=r.dispatch,i=r.pending,s=e.memoizedState;if(i!==null){r.pending=null;var o=i=i.next;do s=t(s,o.action),o=o.next;while(o!==i);Cs(s,e.memoizedState)||(Hn=!0),e.memoizedState=s,e.baseQueue===null&&(e.baseState=s),r.lastRenderedState=s}return[s,n]}function TD(){}function CD(t,e){var r=qt,n=qi(),i=e(),s=!Cs(n.memoizedState,i);if(s&&(n.memoizedState=i,Hn=!0),n=n.queue,fT(PD.bind(null,r,n,t),[t]),n.getSnapshot!==e||s||Fr!==null&&Fr.memoizedState.tag&1){if(r.flags|=2048,Sp(9,RD.bind(null,r,n,i,e),void 0,null),$r===null)throw Error(pe(349));Yu&30||AD(r,e,i)}return i}function AD(t,e,r){t.flags|=16384,t={getSnapshot:e,value:r},e=qt.updateQueue,e===null?(e={lastEffect:null,stores:null},qt.updateQueue=e,e.stores=[t]):(r=e.stores,r===null?e.stores=[t]:r.push(t))}function RD(t,e,r,n){e.value=r,e.getSnapshot=n,ID(e)&&MD(t)}function PD(t,e,r){return r(function(){ID(e)&&MD(t)})}function ID(t){var e=t.getSnapshot;t=t.value;try{var r=e();return!Cs(t,r)}catch{return!0}}function MD(t){var e=ca(t,1);e!==null&&_s(e,t,1,-1)}function lI(t){var e=Qs();return typeof t=="function"&&(t=t()),e.memoizedState=e.baseState=t,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:_p,lastRenderedState:t},e.queue=t,t=t.dispatch=DU.bind(null,qt,t),[e.memoizedState,t]}function Sp(t,e,r,n){return t={tag:t,create:e,destroy:r,deps:n,next:null},e=qt.updateQueue,e===null?(e={lastEffect:null,stores:null},qt.updateQueue=e,e.lastEffect=t.next=t):(r=e.lastEffect,r===null?e.lastEffect=t.next=t:(n=r.next,r.next=t,t.next=n,e.lastEffect=t)),t}function kD(){return qi().memoizedState}function V0(t,e,r,n){var i=Qs();qt.flags|=t,i.memoizedState=Sp(1|e,r,void 0,n===void 0?null:n)}function Jy(t,e,r,n){var i=qi();n=n===void 0?null:n;var s=void 0;if(wr!==null){var o=wr.memoizedState;if(s=o.destroy,n!==null&&cT(n,o.deps)){i.memoizedState=Sp(e,r,s,n);return}}qt.flags|=t,i.memoizedState=Sp(1|e,r,s,n)}function uI(t,e){return V0(8390656,8,t,e)}function fT(t,e){return Jy(2048,8,t,e)}function OD(t,e){return Jy(4,2,t,e)}function DD(t,e){return Jy(4,4,t,e)}function ND(t,e){if(typeof e=="function")return t=t(),e(t),function(){e(null)};if(e!=null)return t=t(),e.current=t,function(){e.current=null}}function LD(t,e,r){return r=r!=null?r.concat([t]):null,Jy(4,4,ND.bind(null,e,t),r)}function pT(){}function FD(t,e){var r=qi();e=e===void 0?null:e;var n=r.memoizedState;return n!==null&&e!==null&&cT(e,n[1])?n[0]:(r.memoizedState=[t,e],t)}function jD(t,e){var r=qi();e=e===void 0?null:e;var n=r.memoizedState;return n!==null&&e!==null&&cT(e,n[1])?n[0]:(t=t(),r.memoizedState=[t,e],t)}function BD(t,e,r){return Yu&21?(Cs(r,e)||(r=VO(),qt.lanes|=r,Qu|=r,t.baseState=!0),e):(t.baseState&&(t.baseState=!1,Hn=!0),t.memoizedState=r)}function kU(t,e){var r=At;At=r!==0&&4>r?r:4,t(!0);var n=Gb.transition;Gb.transition={};try{t(!1),e()}finally{At=r,Gb.transition=n}}function UD(){return qi().memoizedState}function OU(t,e,r){var n=_l(t);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},$D(t))zD(e,r);else if(r=_D(t,e,r,n),r!==null){var i=Tn();_s(r,t,n,i),HD(r,e,n)}}function DU(t,e,r){var n=_l(t),i={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if($D(t))zD(e,i);else{var s=t.alternate;if(t.lanes===0&&(s===null||s.lanes===0)&&(s=e.lastRenderedReducer,s!==null))try{var o=e.lastRenderedState,a=s(o,r);if(i.hasEagerState=!0,i.eagerState=a,Cs(a,o)){var l=e.interleaved;l===null?(i.next=i,sT(e)):(i.next=l.next,l.next=i),e.interleaved=i;return}}catch{}finally{}r=_D(t,e,i,n),r!==null&&(i=Tn(),_s(r,t,n,i),HD(r,e,n))}}function $D(t){var e=t.alternate;return t===qt||e!==null&&e===qt}function zD(t,e){jf=$v=!0;var r=t.pending;r===null?e.next=e:(e.next=r.next,r.next=e),t.pending=e}function HD(t,e,r){if(r&4194240){var n=e.lanes;n&=t.pendingLanes,r|=n,e.lanes=r,G2(t,r)}}var zv={readContext:Xi,useCallback:ln,useContext:ln,useEffect:ln,useImperativeHandle:ln,useInsertionEffect:ln,useLayoutEffect:ln,useMemo:ln,useReducer:ln,useRef:ln,useState:ln,useDebugValue:ln,useDeferredValue:ln,useTransition:ln,useMutableSource:ln,useSyncExternalStore:ln,useId:ln,unstable_isNewReconciler:!1},NU={readContext:Xi,useCallback:function(t,e){return Qs().memoizedState=[t,e===void 0?null:e],t},useContext:Xi,useEffect:uI,useImperativeHandle:function(t,e,r){return r=r!=null?r.concat([t]):null,V0(4194308,4,ND.bind(null,e,t),r)},useLayoutEffect:function(t,e){return V0(4194308,4,t,e)},useInsertionEffect:function(t,e){return V0(4,2,t,e)},useMemo:function(t,e){var r=Qs();return e=e===void 0?null:e,t=t(),r.memoizedState=[t,e],t},useReducer:function(t,e,r){var n=Qs();return e=r!==void 0?r(e):e,n.memoizedState=n.baseState=e,t={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:e},n.queue=t,t=t.dispatch=OU.bind(null,qt,t),[n.memoizedState,t]},useRef:function(t){var e=Qs();return t={current:t},e.memoizedState=t},useState:lI,useDebugValue:pT,useDeferredValue:function(t){return Qs().memoizedState=t},useTransition:function(){var t=lI(!1),e=t[0];return t=kU.bind(null,t[1]),Qs().memoizedState=t,[e,t]},useMutableSource:function(){},useSyncExternalStore:function(t,e,r){var n=qt,i=Qs();if(zt){if(r===void 0)throw Error(pe(407));r=r()}else{if(r=e(),$r===null)throw Error(pe(349));Yu&30||AD(n,e,r)}i.memoizedState=r;var s={value:r,getSnapshot:e};return i.queue=s,uI(PD.bind(null,n,s,t),[t]),n.flags|=2048,Sp(9,RD.bind(null,n,s,r,e),void 0,null),r},useId:function(){var t=Qs(),e=$r.identifierPrefix;if(zt){var r=Ko,n=Qo;r=(n&~(1<<32-ws(n)-1)).toString(32)+r,e=":"+e+"R"+r,r=wp++,0<r&&(e+="H"+r.toString(32)),e+=":"}else r=MU++,e=":"+e+"r"+r.toString(32)+":";return t.memoizedState=e},unstable_isNewReconciler:!1},LU={readContext:Xi,useCallback:FD,useContext:Xi,useEffect:fT,useImperativeHandle:LD,useInsertionEffect:OD,useLayoutEffect:DD,useMemo:jD,useReducer:Wb,useRef:kD,useState:function(){return Wb(_p)},useDebugValue:pT,useDeferredValue:function(t){var e=qi();return BD(e,wr.memoizedState,t)},useTransition:function(){var t=Wb(_p)[0],e=qi().memoizedState;return[t,e]},useMutableSource:TD,useSyncExternalStore:CD,useId:UD,unstable_isNewReconciler:!1},FU={readContext:Xi,useCallback:FD,useContext:Xi,useEffect:fT,useImperativeHandle:LD,useInsertionEffect:OD,useLayoutEffect:DD,useMemo:jD,useReducer:Xb,useRef:kD,useState:function(){return Xb(_p)},useDebugValue:pT,useDeferredValue:function(t){var e=qi();return wr===null?e.memoizedState=t:BD(e,wr.memoizedState,t)},useTransition:function(){var t=Xb(_p)[0],e=qi().memoizedState;return[t,e]},useMutableSource:TD,useSyncExternalStore:CD,useId:UD,unstable_isNewReconciler:!1};function cs(t,e){if(t&&t.defaultProps){e=Yt({},e),t=t.defaultProps;for(var r in t)e[r]===void 0&&(e[r]=t[r]);return e}return e}function lS(t,e,r,n){e=t.memoizedState,r=r(n,e),r=r==null?e:Yt({},e,r),t.memoizedState=r,t.lanes===0&&(t.updateQueue.baseState=r)}var e1={isMounted:function(t){return(t=t._reactInternals)?uc(t)===t:!1},enqueueSetState:function(t,e,r){t=t._reactInternals;var n=Tn(),i=_l(t),s=na(n,i);s.payload=e,r!=null&&(s.callback=r),e=bl(t,s,i),e!==null&&(_s(e,t,i,n),z0(e,t,i))},enqueueReplaceState:function(t,e,r){t=t._reactInternals;var n=Tn(),i=_l(t),s=na(n,i);s.tag=1,s.payload=e,r!=null&&(s.callback=r),e=bl(t,s,i),e!==null&&(_s(e,t,i,n),z0(e,t,i))},enqueueForceUpdate:function(t,e){t=t._reactInternals;var r=Tn(),n=_l(t),i=na(r,n);i.tag=2,e!=null&&(i.callback=e),e=bl(t,i,n),e!==null&&(_s(e,t,n,r),z0(e,t,n))}};function cI(t,e,r,n,i,s,o){return t=t.stateNode,typeof t.shouldComponentUpdate=="function"?t.shouldComponentUpdate(n,s,o):e.prototype&&e.prototype.isPureReactComponent?!mp(r,n)||!mp(i,s):!0}function VD(t,e,r){var n=!1,i=Rl,s=e.contextType;return typeof s=="object"&&s!==null?s=Xi(s):(i=Wn(e)?Xu:hn.current,n=e.contextTypes,s=(n=n!=null)?Gd(t,i):Rl),e=new e(r,s),t.memoizedState=e.state!==null&&e.state!==void 0?e.state:null,e.updater=e1,t.stateNode=e,e._reactInternals=t,n&&(t=t.stateNode,t.__reactInternalMemoizedUnmaskedChildContext=i,t.__reactInternalMemoizedMaskedChildContext=s),e}function dI(t,e,r,n){t=e.state,typeof e.componentWillReceiveProps=="function"&&e.componentWillReceiveProps(r,n),typeof e.UNSAFE_componentWillReceiveProps=="function"&&e.UNSAFE_componentWillReceiveProps(r,n),e.state!==t&&e1.enqueueReplaceState(e,e.state,null)}function uS(t,e,r,n){var i=t.stateNode;i.props=r,i.state=t.memoizedState,i.refs={},oT(t);var s=e.contextType;typeof s=="object"&&s!==null?i.context=Xi(s):(s=Wn(e)?Xu:hn.current,i.context=Gd(t,s)),i.state=t.memoizedState,s=e.getDerivedStateFromProps,typeof s=="function"&&(lS(t,e,s,r),i.state=t.memoizedState),typeof e.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(e=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),e!==i.state&&e1.enqueueReplaceState(i,i.state,null),Bv(t,r,i,n),i.state=t.memoizedState),typeof i.componentDidMount=="function"&&(t.flags|=4194308)}function Yd(t,e){try{var r="",n=e;do r+=d9(n),n=n.return;while(n);var i=r}catch(s){i=`
|
|
40
40
|
Error generating stack: `+s.message+`
|
|
41
|
-
`+s.stack}return{value:t,source:e,stack:i,digest:null}}function qb(t,e,r){return{value:t,source:null,stack:r??null,digest:e??null}}function cS(t,e){try{console.error(e.value)}catch(r){setTimeout(function(){throw r})}}var jU=typeof WeakMap=="function"?WeakMap:Map;function GD(t,e,r){r=na(-1,r),r.tag=3,r.payload={element:null};var n=e.value;return r.callback=function(){Vv||(Vv=!0,bS=n),cS(t,e)},r}function WD(t,e,r){r=na(-1,r),r.tag=3;var n=t.type.getDerivedStateFromError;if(typeof n=="function"){var i=e.value;r.payload=function(){return n(i)},r.callback=function(){cS(t,e)}}var s=t.stateNode;return s!==null&&typeof s.componentDidCatch=="function"&&(r.callback=function(){cS(t,e),typeof n!="function"&&(wl===null?wl=new Set([this]):wl.add(this));var o=e.stack;this.componentDidCatch(e.value,{componentStack:o!==null?o:""})}),r}function hI(t,e,r){var n=t.pingCache;if(n===null){n=t.pingCache=new jU;var i=new Set;n.set(e,i)}else i=n.get(e),i===void 0&&(i=new Set,n.set(e,i));i.has(r)||(i.add(r),t=ZU.bind(null,t,e,r),e.then(t,t))}function fI(t){do{var e;if((e=t.tag===13)&&(e=t.memoizedState,e=e!==null?e.dehydrated!==null:!0),e)return t;t=t.return}while(t!==null);return null}function pI(t,e,r,n,i){return t.mode&1?(t.flags|=65536,t.lanes=i,t):(t===e?t.flags|=65536:(t.flags|=128,r.flags|=131072,r.flags&=-52805,r.tag===1&&(r.alternate===null?r.tag=17:(e=na(-1,1),e.tag=2,bl(r,e,1))),r.lanes|=1),t)}var BU=xa.ReactCurrentOwner,Hn=!1;function bn(t,e,r,n){e.child=t===null?wD(e,null,r,n):Xd(e,t.child,r,n)}function mI(t,e,r,n,i){r=r.render;var s=e.ref;return gd(e,i),n=dT(t,e,r,n,s,i),r=hT(),t!==null&&!Hn?(e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~i,da(t,e,i)):(zt&&r&&J2(e),e.flags|=1,bn(t,e,n,i),e.child)}function gI(t,e,r,n,i){if(t===null){var s=r.type;return typeof s=="function"&&!_T(s)&&s.defaultProps===void 0&&r.compare===null&&r.defaultProps===void 0?(e.tag=15,e.type=s,XD(t,e,s,n,i)):(t=q0(r.type,null,n,e,e.mode,i),t.ref=e.ref,t.return=e,e.child=t)}if(s=t.child,!(t.lanes&i)){var o=s.memoizedProps;if(r=r.compare,r=r!==null?r:mp,r(o,n)&&t.ref===e.ref)return da(t,e,i)}return e.flags|=1,t=Sl(s,n),t.ref=e.ref,t.return=e,e.child=t}function XD(t,e,r,n,i){if(t!==null){var s=t.memoizedProps;if(mp(s,n)&&t.ref===e.ref)if(Hn=!1,e.pendingProps=n=s,(t.lanes&i)!==0)t.flags&131072&&(Hn=!0);else return e.lanes=t.lanes,da(t,e,i)}return dS(t,e,r,n,i)}function qD(t,e,r){var n=e.pendingProps,i=n.children,s=t!==null?t.memoizedState:null;if(n.mode==="hidden")if(!(e.mode&1))e.memoizedState={baseLanes:0,cachePool:null,transitions:null},Mt(od,li),li|=r;else{if(!(r&1073741824))return t=s!==null?s.baseLanes|r:r,e.lanes=e.childLanes=1073741824,e.memoizedState={baseLanes:t,cachePool:null,transitions:null},e.updateQueue=null,Mt(od,li),li|=t,null;e.memoizedState={baseLanes:0,cachePool:null,transitions:null},n=s!==null?s.baseLanes:r,Mt(od,li),li|=n}else s!==null?(n=s.baseLanes|r,e.memoizedState=null):n=r,Mt(od,li),li|=n;return bn(t,e,i,r),e.child}function YD(t,e){var r=e.ref;(t===null&&r!==null||t!==null&&t.ref!==r)&&(e.flags|=512,e.flags|=2097152)}function dS(t,e,r,n,i){var s=Wn(r)?Xu:hn.current;return s=Gd(e,s),gd(e,i),r=dT(t,e,r,n,s,i),n=hT(),t!==null&&!Hn?(e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~i,da(t,e,i)):(zt&&n&&J2(e),e.flags|=1,bn(t,e,r,i),e.child)}function vI(t,e,r,n,i){if(Wn(r)){var s=!0;Dv(e)}else s=!1;if(gd(e,i),e.stateNode===null)G0(t,e),VD(e,r,n),uS(e,r,n,i),n=!0;else if(t===null){var o=e.stateNode,a=e.memoizedProps;o.props=a;var l=o.context,u=r.contextType;typeof u=="object"&&u!==null?u=Xi(u):(u=Wn(r)?Xu:hn.current,u=Gd(e,u));var c=r.getDerivedStateFromProps,h=typeof c=="function"||typeof o.getSnapshotBeforeUpdate=="function";h||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==n||l!==u)&&dI(e,o,n,u),Ha=!1;var f=e.memoizedState;o.state=f,Bv(e,n,o,i),l=e.memoizedState,a!==n||f!==l||Gn.current||Ha?(typeof c=="function"&&(lS(e,r,c,n),l=e.memoizedState),(a=Ha||cI(e,r,a,n,f,l,u))?(h||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(e.flags|=4194308)):(typeof o.componentDidMount=="function"&&(e.flags|=4194308),e.memoizedProps=n,e.memoizedState=l),o.props=n,o.state=l,o.context=u,n=a):(typeof o.componentDidMount=="function"&&(e.flags|=4194308),n=!1)}else{o=e.stateNode,SD(t,e),a=e.memoizedProps,u=e.type===e.elementType?a:cs(e.type,a),o.props=u,h=e.pendingProps,f=o.context,l=r.contextType,typeof l=="object"&&l!==null?l=Xi(l):(l=Wn(r)?Xu:hn.current,l=Gd(e,l));var m=r.getDerivedStateFromProps;(c=typeof m=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==h||f!==l)&&dI(e,o,n,l),Ha=!1,f=e.memoizedState,o.state=f,Bv(e,n,o,i);var y=e.memoizedState;a!==h||f!==y||Gn.current||Ha?(typeof m=="function"&&(lS(e,r,m,n),y=e.memoizedState),(u=Ha||cI(e,r,u,n,f,y,l)||!1)?(c||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(n,y,l),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(n,y,l)),typeof o.componentDidUpdate=="function"&&(e.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(e.flags|=1024)):(typeof o.componentDidUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),e.memoizedProps=n,e.memoizedState=y),o.props=n,o.state=y,o.context=l,n=u):(typeof o.componentDidUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),n=!1)}return hS(t,e,r,n,s,i)}function hS(t,e,r,n,i,s){YD(t,e);var o=(e.flags&128)!==0;if(!n&&!o)return i&&rI(e,r,!1),da(t,e,s);n=e.stateNode,BU.current=e;var a=o&&typeof r.getDerivedStateFromError!="function"?null:n.render();return e.flags|=1,t!==null&&o?(e.child=Xd(e,t.child,null,s),e.child=Xd(e,null,a,s)):bn(t,e,a,s),e.memoizedState=n.state,i&&rI(e,r,!0),e.child}function QD(t){var e=t.stateNode;e.pendingContext?tI(t,e.pendingContext,e.pendingContext!==e.context):e.context&&tI(t,e.context,!1),aT(t,e.containerInfo)}function yI(t,e,r,n,i){return Wd(),tT(i),e.flags|=256,bn(t,e,r,n),e.child}var fS={dehydrated:null,treeContext:null,retryLane:0};function pS(t){return{baseLanes:t,cachePool:null,transitions:null}}function KD(t,e,r){var n=e.pendingProps,i=Wt.current,s=!1,o=(e.flags&128)!==0,a;if((a=o)||(a=t!==null&&t.memoizedState===null?!1:(i&2)!==0),a?(s=!0,e.flags&=-129):(t===null||t.memoizedState!==null)&&(i|=1),Mt(Wt,i&1),t===null)return oS(e),t=e.memoizedState,t!==null&&(t=t.dehydrated,t!==null)?(e.mode&1?t.data==="$!"?e.lanes=8:e.lanes=1073741824:e.lanes=1,null):(o=n.children,t=n.fallback,s?(n=e.mode,s=e.child,o={mode:"hidden",children:o},!(n&1)&&s!==null?(s.childLanes=0,s.pendingProps=o):s=n1(o,n,0,null),t=Bu(t,n,r,null),s.return=e,t.return=e,s.sibling=t,e.child=s,e.child.memoizedState=pS(r),e.memoizedState=fS,t):mT(e,o));if(i=t.memoizedState,i!==null&&(a=i.dehydrated,a!==null))return UU(t,e,o,n,a,i,r);if(s){s=n.fallback,o=e.mode,i=t.child,a=i.sibling;var l={mode:"hidden",children:n.children};return!(o&1)&&e.child!==i?(n=e.child,n.childLanes=0,n.pendingProps=l,e.deletions=null):(n=Sl(i,l),n.subtreeFlags=i.subtreeFlags&14680064),a!==null?s=Sl(a,s):(s=Bu(s,o,r,null),s.flags|=2),s.return=e,n.return=e,n.sibling=s,e.child=n,n=s,s=e.child,o=t.child.memoizedState,o=o===null?pS(r):{baseLanes:o.baseLanes|r,cachePool:null,transitions:o.transitions},s.memoizedState=o,s.childLanes=t.childLanes&~r,e.memoizedState=fS,n}return s=t.child,t=s.sibling,n=Sl(s,{mode:"visible",children:n.children}),!(e.mode&1)&&(n.lanes=r),n.return=e,n.sibling=null,t!==null&&(r=e.deletions,r===null?(e.deletions=[t],e.flags|=16):r.push(t)),e.child=n,e.memoizedState=null,n}function mT(t,e){return e=n1({mode:"visible",children:e},t.mode,0,null),e.return=t,t.child=e}function Fg(t,e,r,n){return n!==null&&tT(n),Xd(e,t.child,null,r),t=mT(e,e.pendingProps.children),t.flags|=2,e.memoizedState=null,t}function UU(t,e,r,n,i,s,o){if(r)return e.flags&256?(e.flags&=-257,n=qb(Error(pe(422))),Fg(t,e,o,n)):e.memoizedState!==null?(e.child=t.child,e.flags|=128,null):(s=n.fallback,i=e.mode,n=n1({mode:"visible",children:n.children},i,0,null),s=Bu(s,i,o,null),s.flags|=2,n.return=e,s.return=e,n.sibling=s,e.child=n,e.mode&1&&Xd(e,t.child,null,o),e.child.memoizedState=pS(o),e.memoizedState=fS,s);if(!(e.mode&1))return Fg(t,e,o,null);if(i.data==="$!"){if(n=i.nextSibling&&i.nextSibling.dataset,n)var a=n.dgst;return n=a,s=Error(pe(419)),n=qb(s,n,void 0),Fg(t,e,o,n)}if(a=(o&t.childLanes)!==0,Hn||a){if(n=$r,n!==null){switch(o&-o){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(n.suspendedLanes|o)?0:i,i!==0&&i!==s.retryLane&&(s.retryLane=i,ca(t,i),_s(n,t,i,-1))}return wT(),n=qb(Error(pe(421))),Fg(t,e,o,n)}return i.data==="$?"?(e.flags|=128,e.child=t.child,e=JU.bind(null,t),i._reactRetry=e,null):(t=s.treeContext,ci=xl(i.nextSibling),hi=e,zt=!0,fs=null,t!==null&&(Di[Ni++]=Qo,Di[Ni++]=Ko,Di[Ni++]=qu,Qo=t.id,Ko=t.overflow,qu=e),e=mT(e,n.children),e.flags|=4096,e)}function xI(t,e,r){t.lanes|=e;var n=t.alternate;n!==null&&(n.lanes|=e),aS(t.return,e,r)}function Yb(t,e,r,n,i){var s=t.memoizedState;s===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:n,tail:r,tailMode:i}:(s.isBackwards=e,s.rendering=null,s.renderingStartTime=0,s.last=n,s.tail=r,s.tailMode=i)}function ZD(t,e,r){var n=e.pendingProps,i=n.revealOrder,s=n.tail;if(bn(t,e,n.children,r),n=Wt.current,n&2)n=n&1|2,e.flags|=128;else{if(t!==null&&t.flags&128)e:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&xI(t,r,e);else if(t.tag===19)xI(t,r,e);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}n&=1}if(Mt(Wt,n),!(e.mode&1))e.memoizedState=null;else switch(i){case"forwards":for(r=e.child,i=null;r!==null;)t=r.alternate,t!==null&&Uv(t)===null&&(i=r),r=r.sibling;r=i,r===null?(i=e.child,e.child=null):(i=r.sibling,r.sibling=null),Yb(e,!1,i,r,s);break;case"backwards":for(r=null,i=e.child,e.child=null;i!==null;){if(t=i.alternate,t!==null&&Uv(t)===null){e.child=i;break}t=i.sibling,i.sibling=r,r=i,i=t}Yb(e,!0,r,null,s);break;case"together":Yb(e,!1,null,null,void 0);break;default:e.memoizedState=null}return e.child}function G0(t,e){!(e.mode&1)&&t!==null&&(t.alternate=null,e.alternate=null,e.flags|=2)}function da(t,e,r){if(t!==null&&(e.dependencies=t.dependencies),Qu|=e.lanes,!(r&e.childLanes))return null;if(t!==null&&e.child!==t.child)throw Error(pe(153));if(e.child!==null){for(t=e.child,r=Sl(t,t.pendingProps),e.child=r,r.return=e;t.sibling!==null;)t=t.sibling,r=r.sibling=Sl(t,t.pendingProps),r.return=e;r.sibling=null}return e.child}function $U(t,e,r){switch(e.tag){case 3:QD(e),Wd();break;case 5:ED(e);break;case 1:Wn(e.type)&&Dv(e);break;case 4:aT(e,e.stateNode.containerInfo);break;case 10:var n=e.type._context,i=e.memoizedProps.value;Mt(Fv,n._currentValue),n._currentValue=i;break;case 13:if(n=e.memoizedState,n!==null)return n.dehydrated!==null?(Mt(Wt,Wt.current&1),e.flags|=128,null):r&e.child.childLanes?KD(t,e,r):(Mt(Wt,Wt.current&1),t=da(t,e,r),t!==null?t.sibling:null);Mt(Wt,Wt.current&1);break;case 19:if(n=(r&e.childLanes)!==0,t.flags&128){if(n)return ZD(t,e,r);e.flags|=128}if(i=e.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),Mt(Wt,Wt.current),n)break;return null;case 22:case 23:return e.lanes=0,qD(t,e,r)}return da(t,e,r)}var JD,mS,eN,tN;JD=function(t,e){for(var r=e.child;r!==null;){if(r.tag===5||r.tag===6)t.appendChild(r.stateNode);else if(r.tag!==4&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===e)break;for(;r.sibling===null;){if(r.return===null||r.return===e)return;r=r.return}r.sibling.return=r.return,r=r.sibling}};mS=function(){};eN=function(t,e,r,n){var i=t.memoizedProps;if(i!==n){t=e.stateNode,Au(mo.current);var s=null;switch(r){case"input":i=F_(t,i),n=F_(t,n),s=[];break;case"select":i=Yt({},i,{value:void 0}),n=Yt({},n,{value:void 0}),s=[];break;case"textarea":i=U_(t,i),n=U_(t,n),s=[];break;default:typeof i.onClick!="function"&&typeof n.onClick=="function"&&(t.onclick=kv)}z_(r,n);var o;r=null;for(u in i)if(!n.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var a=i[u];for(o in a)a.hasOwnProperty(o)&&(r||(r={}),r[o]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(lp.hasOwnProperty(u)?s||(s=[]):(s=s||[]).push(u,null));for(u in n){var l=n[u];if(a=i!=null?i[u]:void 0,n.hasOwnProperty(u)&&l!==a&&(l!=null||a!=null))if(u==="style")if(a){for(o in a)!a.hasOwnProperty(o)||l&&l.hasOwnProperty(o)||(r||(r={}),r[o]="");for(o in l)l.hasOwnProperty(o)&&a[o]!==l[o]&&(r||(r={}),r[o]=l[o])}else r||(s||(s=[]),s.push(u,r)),r=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,a=a?a.__html:void 0,l!=null&&a!==l&&(s=s||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(s=s||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(lp.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&Nt("scroll",t),s||a===l||(s=[])):(s=s||[]).push(u,l))}r&&(s=s||[]).push("style",r);var u=s;(e.updateQueue=u)&&(e.flags|=4)}};tN=function(t,e,r,n){r!==n&&(e.flags|=4)};function Kh(t,e){if(!zt)switch(t.tailMode){case"hidden":e=t.tail;for(var r=null;e!==null;)e.alternate!==null&&(r=e),e=e.sibling;r===null?t.tail=null:r.sibling=null;break;case"collapsed":r=t.tail;for(var n=null;r!==null;)r.alternate!==null&&(n=r),r=r.sibling;n===null?e||t.tail===null?t.tail=null:t.tail.sibling=null:n.sibling=null}}function un(t){var e=t.alternate!==null&&t.alternate.child===t.child,r=0,n=0;if(e)for(var i=t.child;i!==null;)r|=i.lanes|i.childLanes,n|=i.subtreeFlags&14680064,n|=i.flags&14680064,i.return=t,i=i.sibling;else for(i=t.child;i!==null;)r|=i.lanes|i.childLanes,n|=i.subtreeFlags,n|=i.flags,i.return=t,i=i.sibling;return t.subtreeFlags|=n,t.childLanes=r,e}function zU(t,e,r){var n=e.pendingProps;switch(eT(e),e.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return un(e),null;case 1:return Wn(e.type)&&Ov(),un(e),null;case 3:return n=e.stateNode,qd(),Ft(Gn),Ft(hn),uT(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(t===null||t.child===null)&&(Ng(e)?e.flags|=4:t===null||t.memoizedState.isDehydrated&&!(e.flags&256)||(e.flags|=1024,fs!==null&&(SS(fs),fs=null))),mS(t,e),un(e),null;case 5:lT(e);var i=Au(bp.current);if(r=e.type,t!==null&&e.stateNode!=null)eN(t,e,r,n,i),t.ref!==e.ref&&(e.flags|=512,e.flags|=2097152);else{if(!n){if(e.stateNode===null)throw Error(pe(166));return un(e),null}if(t=Au(mo.current),Ng(e)){n=e.stateNode,r=e.type;var s=e.memoizedProps;switch(n[oo]=e,n[yp]=s,t=(e.mode&1)!==0,r){case"dialog":Nt("cancel",n),Nt("close",n);break;case"iframe":case"object":case"embed":Nt("load",n);break;case"video":case"audio":for(i=0;i<xf.length;i++)Nt(xf[i],n);break;case"source":Nt("error",n);break;case"img":case"image":case"link":Nt("error",n),Nt("load",n);break;case"details":Nt("toggle",n);break;case"input":RP(n,s),Nt("invalid",n);break;case"select":n._wrapperState={wasMultiple:!!s.multiple},Nt("invalid",n);break;case"textarea":IP(n,s),Nt("invalid",n)}z_(r,s),i=null;for(var o in s)if(s.hasOwnProperty(o)){var a=s[o];o==="children"?typeof a=="string"?n.textContent!==a&&(s.suppressHydrationWarning!==!0&&Dg(n.textContent,a,t),i=["children",a]):typeof a=="number"&&n.textContent!==""+a&&(s.suppressHydrationWarning!==!0&&Dg(n.textContent,a,t),i=["children",""+a]):lp.hasOwnProperty(o)&&a!=null&&o==="onScroll"&&Nt("scroll",n)}switch(r){case"input":Cg(n),PP(n,s,!0);break;case"textarea":Cg(n),MP(n);break;case"select":case"option":break;default:typeof s.onClick=="function"&&(n.onclick=kv)}n=i,e.updateQueue=n,n!==null&&(e.flags|=4)}else{o=i.nodeType===9?i:i.ownerDocument,t==="http://www.w3.org/1999/xhtml"&&(t=PO(r)),t==="http://www.w3.org/1999/xhtml"?r==="script"?(t=o.createElement("div"),t.innerHTML="<script><\/script>",t=t.removeChild(t.firstChild)):typeof n.is=="string"?t=o.createElement(r,{is:n.is}):(t=o.createElement(r),r==="select"&&(o=t,n.multiple?o.multiple=!0:n.size&&(o.size=n.size))):t=o.createElementNS(t,r),t[oo]=e,t[yp]=n,JD(t,e,!1,!1),e.stateNode=t;e:{switch(o=H_(r,n),r){case"dialog":Nt("cancel",t),Nt("close",t),i=n;break;case"iframe":case"object":case"embed":Nt("load",t),i=n;break;case"video":case"audio":for(i=0;i<xf.length;i++)Nt(xf[i],t);i=n;break;case"source":Nt("error",t),i=n;break;case"img":case"image":case"link":Nt("error",t),Nt("load",t),i=n;break;case"details":Nt("toggle",t),i=n;break;case"input":RP(t,n),i=F_(t,n),Nt("invalid",t);break;case"option":i=n;break;case"select":t._wrapperState={wasMultiple:!!n.multiple},i=Yt({},n,{value:void 0}),Nt("invalid",t);break;case"textarea":IP(t,n),i=U_(t,n),Nt("invalid",t);break;default:i=n}z_(r,i),a=i;for(s in a)if(a.hasOwnProperty(s)){var l=a[s];s==="style"?kO(t,l):s==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&IO(t,l)):s==="children"?typeof l=="string"?(r!=="textarea"||l!=="")&&up(t,l):typeof l=="number"&&up(t,""+l):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(lp.hasOwnProperty(s)?l!=null&&s==="onScroll"&&Nt("scroll",t):l!=null&&B2(t,s,l,o))}switch(r){case"input":Cg(t),PP(t,n,!1);break;case"textarea":Cg(t),MP(t);break;case"option":n.value!=null&&t.setAttribute("value",""+Al(n.value));break;case"select":t.multiple=!!n.multiple,s=n.value,s!=null?hd(t,!!n.multiple,s,!1):n.defaultValue!=null&&hd(t,!!n.multiple,n.defaultValue,!0);break;default:typeof i.onClick=="function"&&(t.onclick=kv)}switch(r){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break e;case"img":n=!0;break e;default:n=!1}}n&&(e.flags|=4)}e.ref!==null&&(e.flags|=512,e.flags|=2097152)}return un(e),null;case 6:if(t&&e.stateNode!=null)tN(t,e,t.memoizedProps,n);else{if(typeof n!="string"&&e.stateNode===null)throw Error(pe(166));if(r=Au(bp.current),Au(mo.current),Ng(e)){if(n=e.stateNode,r=e.memoizedProps,n[oo]=e,(s=n.nodeValue!==r)&&(t=hi,t!==null))switch(t.tag){case 3:Dg(n.nodeValue,r,(t.mode&1)!==0);break;case 5:t.memoizedProps.suppressHydrationWarning!==!0&&Dg(n.nodeValue,r,(t.mode&1)!==0)}s&&(e.flags|=4)}else n=(r.nodeType===9?r:r.ownerDocument).createTextNode(n),n[oo]=e,e.stateNode=n}return un(e),null;case 13:if(Ft(Wt),n=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(zt&&ci!==null&&e.mode&1&&!(e.flags&128))xD(),Wd(),e.flags|=98560,s=!1;else if(s=Ng(e),n!==null&&n.dehydrated!==null){if(t===null){if(!s)throw Error(pe(318));if(s=e.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(pe(317));s[oo]=e}else Wd(),!(e.flags&128)&&(e.memoizedState=null),e.flags|=4;un(e),s=!1}else fs!==null&&(SS(fs),fs=null),s=!0;if(!s)return e.flags&65536?e:null}return e.flags&128?(e.lanes=r,e):(n=n!==null,n!==(t!==null&&t.memoizedState!==null)&&n&&(e.child.flags|=8192,e.mode&1&&(t===null||Wt.current&1?Cr===0&&(Cr=3):wT())),e.updateQueue!==null&&(e.flags|=4),un(e),null);case 4:return qd(),mS(t,e),t===null&&gp(e.stateNode.containerInfo),un(e),null;case 10:return iT(e.type._context),un(e),null;case 17:return Wn(e.type)&&Ov(),un(e),null;case 19:if(Ft(Wt),s=e.memoizedState,s===null)return un(e),null;if(n=(e.flags&128)!==0,o=s.rendering,o===null)if(n)Kh(s,!1);else{if(Cr!==0||t!==null&&t.flags&128)for(t=e.child;t!==null;){if(o=Uv(t),o!==null){for(e.flags|=128,Kh(s,!1),n=o.updateQueue,n!==null&&(e.updateQueue=n,e.flags|=4),e.subtreeFlags=0,n=r,r=e.child;r!==null;)s=r,t=n,s.flags&=14680066,o=s.alternate,o===null?(s.childLanes=0,s.lanes=t,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=o.childLanes,s.lanes=o.lanes,s.child=o.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=o.memoizedProps,s.memoizedState=o.memoizedState,s.updateQueue=o.updateQueue,s.type=o.type,t=o.dependencies,s.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),r=r.sibling;return Mt(Wt,Wt.current&1|2),e.child}t=t.sibling}s.tail!==null&&lr()>Qd&&(e.flags|=128,n=!0,Kh(s,!1),e.lanes=4194304)}else{if(!n)if(t=Uv(o),t!==null){if(e.flags|=128,n=!0,r=t.updateQueue,r!==null&&(e.updateQueue=r,e.flags|=4),Kh(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!zt)return un(e),null}else 2*lr()-s.renderingStartTime>Qd&&r!==1073741824&&(e.flags|=128,n=!0,Kh(s,!1),e.lanes=4194304);s.isBackwards?(o.sibling=e.child,e.child=o):(r=s.last,r!==null?r.sibling=o:e.child=o,s.last=o)}return s.tail!==null?(e=s.tail,s.rendering=e,s.tail=e.sibling,s.renderingStartTime=lr(),e.sibling=null,r=Wt.current,Mt(Wt,n?r&1|2:r&1),e):(un(e),null);case 22:case 23:return bT(),n=e.memoizedState!==null,t!==null&&t.memoizedState!==null!==n&&(e.flags|=8192),n&&e.mode&1?li&1073741824&&(un(e),e.subtreeFlags&6&&(e.flags|=8192)):un(e),null;case 24:return null;case 25:return null}throw Error(pe(156,e.tag))}function HU(t,e){switch(eT(e),e.tag){case 1:return Wn(e.type)&&Ov(),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return qd(),Ft(Gn),Ft(hn),uT(),t=e.flags,t&65536&&!(t&128)?(e.flags=t&-65537|128,e):null;case 5:return lT(e),null;case 13:if(Ft(Wt),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(pe(340));Wd()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return Ft(Wt),null;case 4:return qd(),null;case 10:return iT(e.type._context),null;case 22:case 23:return bT(),null;case 24:return null;default:return null}}var jg=!1,dn=!1,VU=typeof WeakSet=="function"?WeakSet:Set,Fe=null;function sd(t,e){var r=t.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){Jt(t,e,n)}else r.current=null}function gS(t,e,r){try{r()}catch(n){Jt(t,e,n)}}var bI=!1;function GU(t,e){if(J_=Pv,t=oD(),Z2(t)){if("selectionStart"in t)var r={start:t.selectionStart,end:t.selectionEnd};else e:{r=(r=t.ownerDocument)&&r.defaultView||window;var n=r.getSelection&&r.getSelection();if(n&&n.rangeCount!==0){r=n.anchorNode;var i=n.anchorOffset,s=n.focusNode;n=n.focusOffset;try{r.nodeType,s.nodeType}catch{r=null;break e}var o=0,a=-1,l=-1,u=0,c=0,h=t,f=null;t:for(;;){for(var m;h!==r||i!==0&&h.nodeType!==3||(a=o+i),h!==s||n!==0&&h.nodeType!==3||(l=o+n),h.nodeType===3&&(o+=h.nodeValue.length),(m=h.firstChild)!==null;)f=h,h=m;for(;;){if(h===t)break t;if(f===r&&++u===i&&(a=o),f===s&&++c===n&&(l=o),(m=h.nextSibling)!==null)break;h=f,f=h.parentNode}h=m}r=a===-1||l===-1?null:{start:a,end:l}}else r=null}r=r||{start:0,end:0}}else r=null;for(eS={focusedElem:t,selectionRange:r},Pv=!1,Fe=e;Fe!==null;)if(e=Fe,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,Fe=t;else for(;Fe!==null;){e=Fe;try{var y=e.alternate;if(e.flags&1024)switch(e.tag){case 0:case 11:case 15:break;case 1:if(y!==null){var v=y.memoizedProps,x=y.memoizedState,b=e.stateNode,_=b.getSnapshotBeforeUpdate(e.elementType===e.type?v:cs(e.type,v),x);b.__reactInternalSnapshotBeforeUpdate=_}break;case 3:var w=e.stateNode.containerInfo;w.nodeType===1?w.textContent="":w.nodeType===9&&w.documentElement&&w.removeChild(w.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(pe(163))}}catch(E){Jt(e,e.return,E)}if(t=e.sibling,t!==null){t.return=e.return,Fe=t;break}Fe=e.return}return y=bI,bI=!1,y}function Bf(t,e,r){var n=e.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var i=n=n.next;do{if((i.tag&t)===t){var s=i.destroy;i.destroy=void 0,s!==void 0&&gS(e,r,s)}i=i.next}while(i!==n)}}function t1(t,e){if(e=e.updateQueue,e=e!==null?e.lastEffect:null,e!==null){var r=e=e.next;do{if((r.tag&t)===t){var n=r.create;r.destroy=n()}r=r.next}while(r!==e)}}function vS(t){var e=t.ref;if(e!==null){var r=t.stateNode;switch(t.tag){case 5:t=r;break;default:t=r}typeof e=="function"?e(t):e.current=t}}function rN(t){var e=t.alternate;e!==null&&(t.alternate=null,rN(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&(delete e[oo],delete e[yp],delete e[nS],delete e[AU],delete e[RU])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function nN(t){return t.tag===5||t.tag===3||t.tag===4}function wI(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||nN(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function yS(t,e,r){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?r.nodeType===8?r.parentNode.insertBefore(t,e):r.insertBefore(t,e):(r.nodeType===8?(e=r.parentNode,e.insertBefore(t,r)):(e=r,e.appendChild(t)),r=r._reactRootContainer,r!=null||e.onclick!==null||(e.onclick=kv));else if(n!==4&&(t=t.child,t!==null))for(yS(t,e,r),t=t.sibling;t!==null;)yS(t,e,r),t=t.sibling}function xS(t,e,r){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?r.insertBefore(t,e):r.appendChild(t);else if(n!==4&&(t=t.child,t!==null))for(xS(t,e,r),t=t.sibling;t!==null;)xS(t,e,r),t=t.sibling}var qr=null,hs=!1;function Na(t,e,r){for(r=r.child;r!==null;)iN(t,e,r),r=r.sibling}function iN(t,e,r){if(po&&typeof po.onCommitFiberUnmount=="function")try{po.onCommitFiberUnmount(Xy,r)}catch{}switch(r.tag){case 5:dn||sd(r,e);case 6:var n=qr,i=hs;qr=null,Na(t,e,r),qr=n,hs=i,qr!==null&&(hs?(t=qr,r=r.stateNode,t.nodeType===8?t.parentNode.removeChild(r):t.removeChild(r)):qr.removeChild(r.stateNode));break;case 18:qr!==null&&(hs?(t=qr,r=r.stateNode,t.nodeType===8?zb(t.parentNode,r):t.nodeType===1&&zb(t,r),fp(t)):zb(qr,r.stateNode));break;case 4:n=qr,i=hs,qr=r.stateNode.containerInfo,hs=!0,Na(t,e,r),qr=n,hs=i;break;case 0:case 11:case 14:case 15:if(!dn&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){i=n=n.next;do{var s=i,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&gS(r,e,o),i=i.next}while(i!==n)}Na(t,e,r);break;case 1:if(!dn&&(sd(r,e),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(a){Jt(r,e,a)}Na(t,e,r);break;case 21:Na(t,e,r);break;case 22:r.mode&1?(dn=(n=dn)||r.memoizedState!==null,Na(t,e,r),dn=n):Na(t,e,r);break;default:Na(t,e,r)}}function _I(t){var e=t.updateQueue;if(e!==null){t.updateQueue=null;var r=t.stateNode;r===null&&(r=t.stateNode=new VU),e.forEach(function(n){var i=e$.bind(null,t,n);r.has(n)||(r.add(n),n.then(i,i))})}}function ss(t,e){var r=e.deletions;if(r!==null)for(var n=0;n<r.length;n++){var i=r[n];try{var s=t,o=e,a=o;e:for(;a!==null;){switch(a.tag){case 5:qr=a.stateNode,hs=!1;break e;case 3:qr=a.stateNode.containerInfo,hs=!0;break e;case 4:qr=a.stateNode.containerInfo,hs=!0;break e}a=a.return}if(qr===null)throw Error(pe(160));iN(s,o,i),qr=null,hs=!1;var l=i.alternate;l!==null&&(l.return=null),i.return=null}catch(u){Jt(i,e,u)}}if(e.subtreeFlags&12854)for(e=e.child;e!==null;)sN(e,t),e=e.sibling}function sN(t,e){var r=t.alternate,n=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:if(ss(e,t),Hs(t),n&4){try{Bf(3,t,t.return),t1(3,t)}catch(v){Jt(t,t.return,v)}try{Bf(5,t,t.return)}catch(v){Jt(t,t.return,v)}}break;case 1:ss(e,t),Hs(t),n&512&&r!==null&&sd(r,r.return);break;case 5:if(ss(e,t),Hs(t),n&512&&r!==null&&sd(r,r.return),t.flags&32){var i=t.stateNode;try{up(i,"")}catch(v){Jt(t,t.return,v)}}if(n&4&&(i=t.stateNode,i!=null)){var s=t.memoizedProps,o=r!==null?r.memoizedProps:s,a=t.type,l=t.updateQueue;if(t.updateQueue=null,l!==null)try{a==="input"&&s.type==="radio"&&s.name!=null&&AO(i,s),H_(a,o);var u=H_(a,s);for(o=0;o<l.length;o+=2){var c=l[o],h=l[o+1];c==="style"?kO(i,h):c==="dangerouslySetInnerHTML"?IO(i,h):c==="children"?up(i,h):B2(i,c,h,u)}switch(a){case"input":j_(i,s);break;case"textarea":RO(i,s);break;case"select":var f=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!s.multiple;var m=s.value;m!=null?hd(i,!!s.multiple,m,!1):f!==!!s.multiple&&(s.defaultValue!=null?hd(i,!!s.multiple,s.defaultValue,!0):hd(i,!!s.multiple,s.multiple?[]:"",!1))}i[yp]=s}catch(v){Jt(t,t.return,v)}}break;case 6:if(ss(e,t),Hs(t),n&4){if(t.stateNode===null)throw Error(pe(162));i=t.stateNode,s=t.memoizedProps;try{i.nodeValue=s}catch(v){Jt(t,t.return,v)}}break;case 3:if(ss(e,t),Hs(t),n&4&&r!==null&&r.memoizedState.isDehydrated)try{fp(e.containerInfo)}catch(v){Jt(t,t.return,v)}break;case 4:ss(e,t),Hs(t);break;case 13:ss(e,t),Hs(t),i=t.child,i.flags&8192&&(s=i.memoizedState!==null,i.stateNode.isHidden=s,!s||i.alternate!==null&&i.alternate.memoizedState!==null||(yT=lr())),n&4&&_I(t);break;case 22:if(c=r!==null&&r.memoizedState!==null,t.mode&1?(dn=(u=dn)||c,ss(e,t),dn=u):ss(e,t),Hs(t),n&8192){if(u=t.memoizedState!==null,(t.stateNode.isHidden=u)&&!c&&t.mode&1)for(Fe=t,c=t.child;c!==null;){for(h=Fe=c;Fe!==null;){switch(f=Fe,m=f.child,f.tag){case 0:case 11:case 14:case 15:Bf(4,f,f.return);break;case 1:sd(f,f.return);var y=f.stateNode;if(typeof y.componentWillUnmount=="function"){n=f,r=f.return;try{e=n,y.props=e.memoizedProps,y.state=e.memoizedState,y.componentWillUnmount()}catch(v){Jt(n,r,v)}}break;case 5:sd(f,f.return);break;case 22:if(f.memoizedState!==null){EI(h);continue}}m!==null?(m.return=f,Fe=m):EI(h)}c=c.sibling}e:for(c=null,h=t;;){if(h.tag===5){if(c===null){c=h;try{i=h.stateNode,u?(s=i.style,typeof s.setProperty=="function"?s.setProperty("display","none","important"):s.display="none"):(a=h.stateNode,l=h.memoizedProps.style,o=l!=null&&l.hasOwnProperty("display")?l.display:null,a.style.display=MO("display",o))}catch(v){Jt(t,t.return,v)}}}else if(h.tag===6){if(c===null)try{h.stateNode.nodeValue=u?"":h.memoizedProps}catch(v){Jt(t,t.return,v)}}else if((h.tag!==22&&h.tag!==23||h.memoizedState===null||h===t)&&h.child!==null){h.child.return=h,h=h.child;continue}if(h===t)break e;for(;h.sibling===null;){if(h.return===null||h.return===t)break e;c===h&&(c=null),h=h.return}c===h&&(c=null),h.sibling.return=h.return,h=h.sibling}}break;case 19:ss(e,t),Hs(t),n&4&&_I(t);break;case 21:break;default:ss(e,t),Hs(t)}}function Hs(t){var e=t.flags;if(e&2){try{e:{for(var r=t.return;r!==null;){if(nN(r)){var n=r;break e}r=r.return}throw Error(pe(160))}switch(n.tag){case 5:var i=n.stateNode;n.flags&32&&(up(i,""),n.flags&=-33);var s=wI(t);xS(t,s,i);break;case 3:case 4:var o=n.stateNode.containerInfo,a=wI(t);yS(t,a,o);break;default:throw Error(pe(161))}}catch(l){Jt(t,t.return,l)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function WU(t,e,r){Fe=t,oN(t)}function oN(t,e,r){for(var n=(t.mode&1)!==0;Fe!==null;){var i=Fe,s=i.child;if(i.tag===22&&n){var o=i.memoizedState!==null||jg;if(!o){var a=i.alternate,l=a!==null&&a.memoizedState!==null||dn;a=jg;var u=dn;if(jg=o,(dn=l)&&!u)for(Fe=i;Fe!==null;)o=Fe,l=o.child,o.tag===22&&o.memoizedState!==null?TI(i):l!==null?(l.return=o,Fe=l):TI(i);for(;s!==null;)Fe=s,oN(s),s=s.sibling;Fe=i,jg=a,dn=u}SI(t)}else i.subtreeFlags&8772&&s!==null?(s.return=i,Fe=s):SI(t)}}function SI(t){for(;Fe!==null;){var e=Fe;if(e.flags&8772){var r=e.alternate;try{if(e.flags&8772)switch(e.tag){case 0:case 11:case 15:dn||t1(5,e);break;case 1:var n=e.stateNode;if(e.flags&4&&!dn)if(r===null)n.componentDidMount();else{var i=e.elementType===e.type?r.memoizedProps:cs(e.type,r.memoizedProps);n.componentDidUpdate(i,r.memoizedState,n.__reactInternalSnapshotBeforeUpdate)}var s=e.updateQueue;s!==null&&aI(e,s,n);break;case 3:var o=e.updateQueue;if(o!==null){if(r=null,e.child!==null)switch(e.child.tag){case 5:r=e.child.stateNode;break;case 1:r=e.child.stateNode}aI(e,o,r)}break;case 5:var a=e.stateNode;if(r===null&&e.flags&4){r=a;var l=e.memoizedProps;switch(e.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&r.focus();break;case"img":l.src&&(r.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(e.memoizedState===null){var u=e.alternate;if(u!==null){var c=u.memoizedState;if(c!==null){var h=c.dehydrated;h!==null&&fp(h)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(pe(163))}dn||e.flags&512&&vS(e)}catch(f){Jt(e,e.return,f)}}if(e===t){Fe=null;break}if(r=e.sibling,r!==null){r.return=e.return,Fe=r;break}Fe=e.return}}function EI(t){for(;Fe!==null;){var e=Fe;if(e===t){Fe=null;break}var r=e.sibling;if(r!==null){r.return=e.return,Fe=r;break}Fe=e.return}}function TI(t){for(;Fe!==null;){var e=Fe;try{switch(e.tag){case 0:case 11:case 15:var r=e.return;try{t1(4,e)}catch(l){Jt(e,r,l)}break;case 1:var n=e.stateNode;if(typeof n.componentDidMount=="function"){var i=e.return;try{n.componentDidMount()}catch(l){Jt(e,i,l)}}var s=e.return;try{vS(e)}catch(l){Jt(e,s,l)}break;case 5:var o=e.return;try{vS(e)}catch(l){Jt(e,o,l)}}}catch(l){Jt(e,e.return,l)}if(e===t){Fe=null;break}var a=e.sibling;if(a!==null){a.return=e.return,Fe=a;break}Fe=e.return}}var XU=Math.ceil,Hv=xa.ReactCurrentDispatcher,gT=xa.ReactCurrentOwner,zi=xa.ReactCurrentBatchConfig,bt=0,$r=null,pr=null,Qr=0,li=0,od=Ll(0),Cr=0,Ep=null,Qu=0,r1=0,vT=0,Uf=null,zn=null,yT=0,Qd=1/0,Go=null,Vv=!1,bS=null,wl=null,Bg=!1,al=null,Gv=0,$f=0,wS=null,W0=-1,X0=0;function Tn(){return bt&6?lr():W0!==-1?W0:W0=lr()}function _l(t){return t.mode&1?bt&2&&Qr!==0?Qr&-Qr:IU.transition!==null?(X0===0&&(X0=VO()),X0):(t=At,t!==0||(t=window.event,t=t===void 0?16:KO(t.type)),t):1}function _s(t,e,r,n){if(50<$f)throw $f=0,wS=null,Error(pe(185));nm(t,r,n),(!(bt&2)||t!==$r)&&(t===$r&&(!(bt&2)&&(r1|=r),Cr===4&&Xa(t,Qr)),Xn(t,n),r===1&&bt===0&&!(e.mode&1)&&(Qd=lr()+500,Zy&&Fl()))}function Xn(t,e){var r=t.callbackNode;I9(t,e);var n=Rv(t,t===$r?Qr:0);if(n===0)r!==null&&DP(r),t.callbackNode=null,t.callbackPriority=0;else if(e=n&-n,t.callbackPriority!==e){if(r!=null&&DP(r),e===1)t.tag===0?PU(CI.bind(null,t)):gD(CI.bind(null,t)),TU(function(){!(bt&6)&&Fl()}),r=null;else{switch(GO(n)){case 1:r=V2;break;case 4:r=zO;break;case 16:r=Av;break;case 536870912:r=HO;break;default:r=Av}r=pN(r,aN.bind(null,t))}t.callbackPriority=e,t.callbackNode=r}}function aN(t,e){if(W0=-1,X0=0,bt&6)throw Error(pe(327));var r=t.callbackNode;if(vd()&&t.callbackNode!==r)return null;var n=Rv(t,t===$r?Qr:0);if(n===0)return null;if(n&30||n&t.expiredLanes||e)e=Wv(t,n);else{e=n;var i=bt;bt|=2;var s=uN();($r!==t||Qr!==e)&&(Go=null,Qd=lr()+500,ju(t,e));do try{QU();break}catch(a){lN(t,a)}while(!0);nT(),Hv.current=s,bt=i,pr!==null?e=0:($r=null,Qr=0,e=Cr)}if(e!==0){if(e===2&&(i=q_(t),i!==0&&(n=i,e=_S(t,i))),e===1)throw r=Ep,ju(t,0),Xa(t,n),Xn(t,lr()),r;if(e===6)Xa(t,n);else{if(i=t.current.alternate,!(n&30)&&!qU(i)&&(e=Wv(t,n),e===2&&(s=q_(t),s!==0&&(n=s,e=_S(t,s))),e===1))throw r=Ep,ju(t,0),Xa(t,n),Xn(t,lr()),r;switch(t.finishedWork=i,t.finishedLanes=n,e){case 0:case 1:throw Error(pe(345));case 2:mu(t,zn,Go);break;case 3:if(Xa(t,n),(n&130023424)===n&&(e=yT+500-lr(),10<e)){if(Rv(t,0)!==0)break;if(i=t.suspendedLanes,(i&n)!==n){Tn(),t.pingedLanes|=t.suspendedLanes&i;break}t.timeoutHandle=rS(mu.bind(null,t,zn,Go),e);break}mu(t,zn,Go);break;case 4:if(Xa(t,n),(n&4194240)===n)break;for(e=t.eventTimes,i=-1;0<n;){var o=31-ws(n);s=1<<o,o=e[o],o>i&&(i=o),n&=~s}if(n=i,n=lr()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*XU(n/1960))-n,10<n){t.timeoutHandle=rS(mu.bind(null,t,zn,Go),n);break}mu(t,zn,Go);break;case 5:mu(t,zn,Go);break;default:throw Error(pe(329))}}}return Xn(t,lr()),t.callbackNode===r?aN.bind(null,t):null}function _S(t,e){var r=Uf;return t.current.memoizedState.isDehydrated&&(ju(t,e).flags|=256),t=Wv(t,e),t!==2&&(e=zn,zn=r,e!==null&&SS(e)),t}function SS(t){zn===null?zn=t:zn.push.apply(zn,t)}function qU(t){for(var e=t;;){if(e.flags&16384){var r=e.updateQueue;if(r!==null&&(r=r.stores,r!==null))for(var n=0;n<r.length;n++){var i=r[n],s=i.getSnapshot;i=i.value;try{if(!Cs(s(),i))return!1}catch{return!1}}}if(r=e.child,e.subtreeFlags&16384&&r!==null)r.return=e,e=r;else{if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return!0;e=e.return}e.sibling.return=e.return,e=e.sibling}}return!0}function Xa(t,e){for(e&=~vT,e&=~r1,t.suspendedLanes|=e,t.pingedLanes&=~e,t=t.expirationTimes;0<e;){var r=31-ws(e),n=1<<r;t[r]=-1,e&=~n}}function CI(t){if(bt&6)throw Error(pe(327));vd();var e=Rv(t,0);if(!(e&1))return Xn(t,lr()),null;var r=Wv(t,e);if(t.tag!==0&&r===2){var n=q_(t);n!==0&&(e=n,r=_S(t,n))}if(r===1)throw r=Ep,ju(t,0),Xa(t,e),Xn(t,lr()),r;if(r===6)throw Error(pe(345));return t.finishedWork=t.current.alternate,t.finishedLanes=e,mu(t,zn,Go),Xn(t,lr()),null}function xT(t,e){var r=bt;bt|=1;try{return t(e)}finally{bt=r,bt===0&&(Qd=lr()+500,Zy&&Fl())}}function Ku(t){al!==null&&al.tag===0&&!(bt&6)&&vd();var e=bt;bt|=1;var r=zi.transition,n=At;try{if(zi.transition=null,At=1,t)return t()}finally{At=n,zi.transition=r,bt=e,!(bt&6)&&Fl()}}function bT(){li=od.current,Ft(od)}function ju(t,e){t.finishedWork=null,t.finishedLanes=0;var r=t.timeoutHandle;if(r!==-1&&(t.timeoutHandle=-1,EU(r)),pr!==null)for(r=pr.return;r!==null;){var n=r;switch(eT(n),n.tag){case 1:n=n.type.childContextTypes,n!=null&&Ov();break;case 3:qd(),Ft(Gn),Ft(hn),uT();break;case 5:lT(n);break;case 4:qd();break;case 13:Ft(Wt);break;case 19:Ft(Wt);break;case 10:iT(n.type._context);break;case 22:case 23:bT()}r=r.return}if($r=t,pr=t=Sl(t.current,null),Qr=li=e,Cr=0,Ep=null,vT=r1=Qu=0,zn=Uf=null,Cu!==null){for(e=0;e<Cu.length;e++)if(r=Cu[e],n=r.interleaved,n!==null){r.interleaved=null;var i=n.next,s=r.pending;if(s!==null){var o=s.next;s.next=i,n.next=o}r.pending=n}Cu=null}return t}function lN(t,e){do{var r=pr;try{if(nT(),H0.current=zv,$v){for(var n=qt.memoizedState;n!==null;){var i=n.queue;i!==null&&(i.pending=null),n=n.next}$v=!1}if(Yu=0,Fr=wr=qt=null,jf=!1,wp=0,gT.current=null,r===null||r.return===null){Cr=1,Ep=e,pr=null;break}e:{var s=t,o=r.return,a=r,l=e;if(e=Qr,a.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l,c=a,h=c.tag;if(!(c.mode&1)&&(h===0||h===11||h===15)){var f=c.alternate;f?(c.updateQueue=f.updateQueue,c.memoizedState=f.memoizedState,c.lanes=f.lanes):(c.updateQueue=null,c.memoizedState=null)}var m=fI(o);if(m!==null){m.flags&=-257,pI(m,o,a,s,e),m.mode&1&&hI(s,u,e),e=m,l=u;var y=e.updateQueue;if(y===null){var v=new Set;v.add(l),e.updateQueue=v}else y.add(l);break e}else{if(!(e&1)){hI(s,u,e),wT();break e}l=Error(pe(426))}}else if(zt&&a.mode&1){var x=fI(o);if(x!==null){!(x.flags&65536)&&(x.flags|=256),pI(x,o,a,s,e),tT(Yd(l,a));break e}}s=l=Yd(l,a),Cr!==4&&(Cr=2),Uf===null?Uf=[s]:Uf.push(s),s=o;do{switch(s.tag){case 3:s.flags|=65536,e&=-e,s.lanes|=e;var b=GD(s,l,e);oI(s,b);break e;case 1:a=l;var _=s.type,w=s.stateNode;if(!(s.flags&128)&&(typeof _.getDerivedStateFromError=="function"||w!==null&&typeof w.componentDidCatch=="function"&&(wl===null||!wl.has(w)))){s.flags|=65536,e&=-e,s.lanes|=e;var E=WD(s,a,e);oI(s,E);break e}}s=s.return}while(s!==null)}dN(r)}catch(A){e=A,pr===r&&r!==null&&(pr=r=r.return);continue}break}while(!0)}function uN(){var t=Hv.current;return Hv.current=zv,t===null?zv:t}function wT(){(Cr===0||Cr===3||Cr===2)&&(Cr=4),$r===null||!(Qu&268435455)&&!(r1&268435455)||Xa($r,Qr)}function Wv(t,e){var r=bt;bt|=2;var n=uN();($r!==t||Qr!==e)&&(Go=null,ju(t,e));do try{YU();break}catch(i){lN(t,i)}while(!0);if(nT(),bt=r,Hv.current=n,pr!==null)throw Error(pe(261));return $r=null,Qr=0,Cr}function YU(){for(;pr!==null;)cN(pr)}function QU(){for(;pr!==null&&!w9();)cN(pr)}function cN(t){var e=fN(t.alternate,t,li);t.memoizedProps=t.pendingProps,e===null?dN(t):pr=e,gT.current=null}function dN(t){var e=t;do{var r=e.alternate;if(t=e.return,e.flags&32768){if(r=HU(r,e),r!==null){r.flags&=32767,pr=r;return}if(t!==null)t.flags|=32768,t.subtreeFlags=0,t.deletions=null;else{Cr=6,pr=null;return}}else if(r=zU(r,e,li),r!==null){pr=r;return}if(e=e.sibling,e!==null){pr=e;return}pr=e=t}while(e!==null);Cr===0&&(Cr=5)}function mu(t,e,r){var n=At,i=zi.transition;try{zi.transition=null,At=1,KU(t,e,r,n)}finally{zi.transition=i,At=n}return null}function KU(t,e,r,n){do vd();while(al!==null);if(bt&6)throw Error(pe(327));r=t.finishedWork;var i=t.finishedLanes;if(r===null)return null;if(t.finishedWork=null,t.finishedLanes=0,r===t.current)throw Error(pe(177));t.callbackNode=null,t.callbackPriority=0;var s=r.lanes|r.childLanes;if(M9(t,s),t===$r&&(pr=$r=null,Qr=0),!(r.subtreeFlags&2064)&&!(r.flags&2064)||Bg||(Bg=!0,pN(Av,function(){return vd(),null})),s=(r.flags&15990)!==0,r.subtreeFlags&15990||s){s=zi.transition,zi.transition=null;var o=At;At=1;var a=bt;bt|=4,gT.current=null,GU(t,r),sN(r,t),vU(eS),Pv=!!J_,eS=J_=null,t.current=r,WU(r),_9(),bt=a,At=o,zi.transition=s}else t.current=r;if(Bg&&(Bg=!1,al=t,Gv=i),s=t.pendingLanes,s===0&&(wl=null),T9(r.stateNode),Xn(t,lr()),e!==null)for(n=t.onRecoverableError,r=0;r<e.length;r++)i=e[r],n(i.value,{componentStack:i.stack,digest:i.digest});if(Vv)throw Vv=!1,t=bS,bS=null,t;return Gv&1&&t.tag!==0&&vd(),s=t.pendingLanes,s&1?t===wS?$f++:($f=0,wS=t):$f=0,Fl(),null}function vd(){if(al!==null){var t=GO(Gv),e=zi.transition,r=At;try{if(zi.transition=null,At=16>t?16:t,al===null)var n=!1;else{if(t=al,al=null,Gv=0,bt&6)throw Error(pe(331));var i=bt;for(bt|=4,Fe=t.current;Fe!==null;){var s=Fe,o=s.child;if(Fe.flags&16){var a=s.deletions;if(a!==null){for(var l=0;l<a.length;l++){var u=a[l];for(Fe=u;Fe!==null;){var c=Fe;switch(c.tag){case 0:case 11:case 15:Bf(8,c,s)}var h=c.child;if(h!==null)h.return=c,Fe=h;else for(;Fe!==null;){c=Fe;var f=c.sibling,m=c.return;if(rN(c),c===u){Fe=null;break}if(f!==null){f.return=m,Fe=f;break}Fe=m}}}var y=s.alternate;if(y!==null){var v=y.child;if(v!==null){y.child=null;do{var x=v.sibling;v.sibling=null,v=x}while(v!==null)}}Fe=s}}if(s.subtreeFlags&2064&&o!==null)o.return=s,Fe=o;else e:for(;Fe!==null;){if(s=Fe,s.flags&2048)switch(s.tag){case 0:case 11:case 15:Bf(9,s,s.return)}var b=s.sibling;if(b!==null){b.return=s.return,Fe=b;break e}Fe=s.return}}var _=t.current;for(Fe=_;Fe!==null;){o=Fe;var w=o.child;if(o.subtreeFlags&2064&&w!==null)w.return=o,Fe=w;else e:for(o=_;Fe!==null;){if(a=Fe,a.flags&2048)try{switch(a.tag){case 0:case 11:case 15:t1(9,a)}}catch(A){Jt(a,a.return,A)}if(a===o){Fe=null;break e}var E=a.sibling;if(E!==null){E.return=a.return,Fe=E;break e}Fe=a.return}}if(bt=i,Fl(),po&&typeof po.onPostCommitFiberRoot=="function")try{po.onPostCommitFiberRoot(Xy,t)}catch{}n=!0}return n}finally{At=r,zi.transition=e}}return!1}function AI(t,e,r){e=Yd(r,e),e=GD(t,e,1),t=bl(t,e,1),e=Tn(),t!==null&&(nm(t,1,e),Xn(t,e))}function Jt(t,e,r){if(t.tag===3)AI(t,t,r);else for(;e!==null;){if(e.tag===3){AI(e,t,r);break}else if(e.tag===1){var n=e.stateNode;if(typeof e.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(wl===null||!wl.has(n))){t=Yd(r,t),t=WD(e,t,1),e=bl(e,t,1),t=Tn(),e!==null&&(nm(e,1,t),Xn(e,t));break}}e=e.return}}function ZU(t,e,r){var n=t.pingCache;n!==null&&n.delete(e),e=Tn(),t.pingedLanes|=t.suspendedLanes&r,$r===t&&(Qr&r)===r&&(Cr===4||Cr===3&&(Qr&130023424)===Qr&&500>lr()-yT?ju(t,0):vT|=r),Xn(t,e)}function hN(t,e){e===0&&(t.mode&1?(e=Pg,Pg<<=1,!(Pg&130023424)&&(Pg=4194304)):e=1);var r=Tn();t=ca(t,e),t!==null&&(nm(t,e,r),Xn(t,r))}function JU(t){var e=t.memoizedState,r=0;e!==null&&(r=e.retryLane),hN(t,r)}function e$(t,e){var r=0;switch(t.tag){case 13:var n=t.stateNode,i=t.memoizedState;i!==null&&(r=i.retryLane);break;case 19:n=t.stateNode;break;default:throw Error(pe(314))}n!==null&&n.delete(e),hN(t,r)}var fN;fN=function(t,e,r){if(t!==null)if(t.memoizedProps!==e.pendingProps||Gn.current)Hn=!0;else{if(!(t.lanes&r)&&!(e.flags&128))return Hn=!1,$U(t,e,r);Hn=!!(t.flags&131072)}else Hn=!1,zt&&e.flags&1048576&&vD(e,Lv,e.index);switch(e.lanes=0,e.tag){case 2:var n=e.type;G0(t,e),t=e.pendingProps;var i=Gd(e,hn.current);gd(e,r),i=dT(null,e,n,t,i,r);var s=hT();return e.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(e.tag=1,e.memoizedState=null,e.updateQueue=null,Wn(n)?(s=!0,Dv(e)):s=!1,e.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,oT(e),i.updater=e1,e.stateNode=i,i._reactInternals=e,uS(e,n,t,r),e=hS(null,e,n,!0,s,r)):(e.tag=0,zt&&s&&J2(e),bn(null,e,i,r),e=e.child),e;case 16:n=e.elementType;e:{switch(G0(t,e),t=e.pendingProps,i=n._init,n=i(n._payload),e.type=n,i=e.tag=r$(n),t=cs(n,t),i){case 0:e=dS(null,e,n,t,r);break e;case 1:e=vI(null,e,n,t,r);break e;case 11:e=mI(null,e,n,t,r);break e;case 14:e=gI(null,e,n,cs(n.type,t),r);break e}throw Error(pe(306,n,""))}return e;case 0:return n=e.type,i=e.pendingProps,i=e.elementType===n?i:cs(n,i),dS(t,e,n,i,r);case 1:return n=e.type,i=e.pendingProps,i=e.elementType===n?i:cs(n,i),vI(t,e,n,i,r);case 3:e:{if(QD(e),t===null)throw Error(pe(387));n=e.pendingProps,s=e.memoizedState,i=s.element,SD(t,e),Bv(e,n,null,r);var o=e.memoizedState;if(n=o.element,s.isDehydrated)if(s={element:n,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},e.updateQueue.baseState=s,e.memoizedState=s,e.flags&256){i=Yd(Error(pe(423)),e),e=yI(t,e,n,r,i);break e}else if(n!==i){i=Yd(Error(pe(424)),e),e=yI(t,e,n,r,i);break e}else for(ci=xl(e.stateNode.containerInfo.firstChild),hi=e,zt=!0,fs=null,r=wD(e,null,n,r),e.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(Wd(),n===i){e=da(t,e,r);break e}bn(t,e,n,r)}e=e.child}return e;case 5:return ED(e),t===null&&oS(e),n=e.type,i=e.pendingProps,s=t!==null?t.memoizedProps:null,o=i.children,tS(n,i)?o=null:s!==null&&tS(n,s)&&(e.flags|=32),YD(t,e),bn(t,e,o,r),e.child;case 6:return t===null&&oS(e),null;case 13:return KD(t,e,r);case 4:return aT(e,e.stateNode.containerInfo),n=e.pendingProps,t===null?e.child=Xd(e,null,n,r):bn(t,e,n,r),e.child;case 11:return n=e.type,i=e.pendingProps,i=e.elementType===n?i:cs(n,i),mI(t,e,n,i,r);case 7:return bn(t,e,e.pendingProps,r),e.child;case 8:return bn(t,e,e.pendingProps.children,r),e.child;case 12:return bn(t,e,e.pendingProps.children,r),e.child;case 10:e:{if(n=e.type._context,i=e.pendingProps,s=e.memoizedProps,o=i.value,Mt(Fv,n._currentValue),n._currentValue=o,s!==null)if(Cs(s.value,o)){if(s.children===i.children&&!Gn.current){e=da(t,e,r);break e}}else for(s=e.child,s!==null&&(s.return=e);s!==null;){var a=s.dependencies;if(a!==null){o=s.child;for(var l=a.firstContext;l!==null;){if(l.context===n){if(s.tag===1){l=na(-1,r&-r),l.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}s.lanes|=r,l=s.alternate,l!==null&&(l.lanes|=r),aS(s.return,r,e),a.lanes|=r;break}l=l.next}}else if(s.tag===10)o=s.type===e.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(pe(341));o.lanes|=r,a=o.alternate,a!==null&&(a.lanes|=r),aS(o,r,e),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===e){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}bn(t,e,i.children,r),e=e.child}return e;case 9:return i=e.type,n=e.pendingProps.children,gd(e,r),i=Xi(i),n=n(i),e.flags|=1,bn(t,e,n,r),e.child;case 14:return n=e.type,i=cs(n,e.pendingProps),i=cs(n.type,i),gI(t,e,n,i,r);case 15:return XD(t,e,e.type,e.pendingProps,r);case 17:return n=e.type,i=e.pendingProps,i=e.elementType===n?i:cs(n,i),G0(t,e),e.tag=1,Wn(n)?(t=!0,Dv(e)):t=!1,gd(e,r),VD(e,n,i),uS(e,n,i,r),hS(null,e,n,!0,t,r);case 19:return ZD(t,e,r);case 22:return qD(t,e,r)}throw Error(pe(156,e.tag))};function pN(t,e){return $O(t,e)}function t$(t,e,r,n){this.tag=t,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Bi(t,e,r,n){return new t$(t,e,r,n)}function _T(t){return t=t.prototype,!(!t||!t.isReactComponent)}function r$(t){if(typeof t=="function")return _T(t)?1:0;if(t!=null){if(t=t.$$typeof,t===$2)return 11;if(t===z2)return 14}return 2}function Sl(t,e){var r=t.alternate;return r===null?(r=Bi(t.tag,e,t.key,t.mode),r.elementType=t.elementType,r.type=t.type,r.stateNode=t.stateNode,r.alternate=t,t.alternate=r):(r.pendingProps=e,r.type=t.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=t.flags&14680064,r.childLanes=t.childLanes,r.lanes=t.lanes,r.child=t.child,r.memoizedProps=t.memoizedProps,r.memoizedState=t.memoizedState,r.updateQueue=t.updateQueue,e=t.dependencies,r.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},r.sibling=t.sibling,r.index=t.index,r.ref=t.ref,r}function q0(t,e,r,n,i,s){var o=2;if(n=t,typeof t=="function")_T(t)&&(o=1);else if(typeof t=="string")o=5;else e:switch(t){case Qc:return Bu(r.children,i,s,e);case U2:o=8,i|=8;break;case O_:return t=Bi(12,r,e,i|2),t.elementType=O_,t.lanes=s,t;case D_:return t=Bi(13,r,e,i),t.elementType=D_,t.lanes=s,t;case N_:return t=Bi(19,r,e,i),t.elementType=N_,t.lanes=s,t;case EO:return n1(r,i,s,e);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case _O:o=10;break e;case SO:o=9;break e;case $2:o=11;break e;case z2:o=14;break e;case za:o=16,n=null;break e}throw Error(pe(130,t==null?t:typeof t,""))}return e=Bi(o,r,e,i),e.elementType=t,e.type=n,e.lanes=s,e}function Bu(t,e,r,n){return t=Bi(7,t,n,e),t.lanes=r,t}function n1(t,e,r,n){return t=Bi(22,t,n,e),t.elementType=EO,t.lanes=r,t.stateNode={isHidden:!1},t}function Qb(t,e,r){return t=Bi(6,t,null,e),t.lanes=r,t}function Kb(t,e,r){return e=Bi(4,t.children!==null?t.children:[],t.key,e),e.lanes=r,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}function n$(t,e,r,n,i){this.tag=e,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Mb(0),this.expirationTimes=Mb(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Mb(0),this.identifierPrefix=n,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function ST(t,e,r,n,i,s,o,a,l){return t=new n$(t,e,r,a,l),e===1?(e=1,s===!0&&(e|=8)):e=0,s=Bi(3,null,null,e),t.current=s,s.stateNode=t,s.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},oT(s),t}function i$(t,e,r){var n=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Yc,key:n==null?null:""+n,children:t,containerInfo:e,implementation:r}}function mN(t){if(!t)return Rl;t=t._reactInternals;e:{if(uc(t)!==t||t.tag!==1)throw Error(pe(170));var e=t;do{switch(e.tag){case 3:e=e.stateNode.context;break e;case 1:if(Wn(e.type)){e=e.stateNode.__reactInternalMemoizedMergedChildContext;break e}}e=e.return}while(e!==null);throw Error(pe(171))}if(t.tag===1){var r=t.type;if(Wn(r))return mD(t,r,e)}return e}function gN(t,e,r,n,i,s,o,a,l){return t=ST(r,n,!0,t,i,s,o,a,l),t.context=mN(null),r=t.current,n=Tn(),i=_l(r),s=na(n,i),s.callback=e??null,bl(r,s,i),t.current.lanes=i,nm(t,i,n),Xn(t,n),t}function i1(t,e,r,n){var i=e.current,s=Tn(),o=_l(i);return r=mN(r),e.context===null?e.context=r:e.pendingContext=r,e=na(s,o),e.payload={element:t},n=n===void 0?null:n,n!==null&&(e.callback=n),t=bl(i,e,o),t!==null&&(_s(t,i,o,s),z0(t,i,o)),o}function Xv(t){if(t=t.current,!t.child)return null;switch(t.child.tag){case 5:return t.child.stateNode;default:return t.child.stateNode}}function RI(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var r=t.retryLane;t.retryLane=r!==0&&r<e?r:e}}function ET(t,e){RI(t,e),(t=t.alternate)&&RI(t,e)}function s$(){return null}var vN=typeof reportError=="function"?reportError:function(t){console.error(t)};function TT(t){this._internalRoot=t}s1.prototype.render=TT.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(pe(409));i1(t,e,null,null)};s1.prototype.unmount=TT.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;Ku(function(){i1(null,t,null,null)}),e[ua]=null}};function s1(t){this._internalRoot=t}s1.prototype.unstable_scheduleHydration=function(t){if(t){var e=qO();t={blockedOn:null,target:t,priority:e};for(var r=0;r<Wa.length&&e!==0&&e<Wa[r].priority;r++);Wa.splice(r,0,t),r===0&&QO(t)}};function CT(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function o1(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11&&(t.nodeType!==8||t.nodeValue!==" react-mount-point-unstable "))}function PI(){}function o$(t,e,r,n,i){if(i){if(typeof n=="function"){var s=n;n=function(){var u=Xv(o);s.call(u)}}var o=gN(e,n,t,0,null,!1,!1,"",PI);return t._reactRootContainer=o,t[ua]=o.current,gp(t.nodeType===8?t.parentNode:t),Ku(),o}for(;i=t.lastChild;)t.removeChild(i);if(typeof n=="function"){var a=n;n=function(){var u=Xv(l);a.call(u)}}var l=ST(t,0,!1,null,null,!1,!1,"",PI);return t._reactRootContainer=l,t[ua]=l.current,gp(t.nodeType===8?t.parentNode:t),Ku(function(){i1(e,l,r,n)}),l}function a1(t,e,r,n,i){var s=r._reactRootContainer;if(s){var o=s;if(typeof i=="function"){var a=i;i=function(){var l=Xv(o);a.call(l)}}i1(e,o,t,i)}else o=o$(r,e,t,i,n);return Xv(o)}WO=function(t){switch(t.tag){case 3:var e=t.stateNode;if(e.current.memoizedState.isDehydrated){var r=yf(e.pendingLanes);r!==0&&(G2(e,r|1),Xn(e,lr()),!(bt&6)&&(Qd=lr()+500,Fl()))}break;case 13:Ku(function(){var n=ca(t,1);if(n!==null){var i=Tn();_s(n,t,1,i)}}),ET(t,1)}};W2=function(t){if(t.tag===13){var e=ca(t,134217728);if(e!==null){var r=Tn();_s(e,t,134217728,r)}ET(t,134217728)}};XO=function(t){if(t.tag===13){var e=_l(t),r=ca(t,e);if(r!==null){var n=Tn();_s(r,t,e,n)}ET(t,e)}};qO=function(){return At};YO=function(t,e){var r=At;try{return At=t,e()}finally{At=r}};G_=function(t,e,r){switch(e){case"input":if(j_(t,r),e=r.name,r.type==="radio"&&e!=null){for(r=t;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll("input[name="+JSON.stringify(""+e)+'][type="radio"]'),e=0;e<r.length;e++){var n=r[e];if(n!==t&&n.form===t.form){var i=Ky(n);if(!i)throw Error(pe(90));CO(n),j_(n,i)}}}break;case"textarea":RO(t,r);break;case"select":e=r.value,e!=null&&hd(t,!!r.multiple,e,!1)}};NO=xT;LO=Ku;var a$={usingClientEntryPoint:!1,Events:[sm,ed,Ky,OO,DO,xT]},Zh={findFiberByHostInstance:Tu,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},l$={bundleType:Zh.bundleType,version:Zh.version,rendererPackageName:Zh.rendererPackageName,rendererConfig:Zh.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:xa.ReactCurrentDispatcher,findHostInstanceByFiber:function(t){return t=BO(t),t===null?null:t.stateNode},findFiberByHostInstance:Zh.findFiberByHostInstance||s$,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Ug=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Ug.isDisabled&&Ug.supportsFiber)try{Xy=Ug.inject(l$),po=Ug}catch{}}vi.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=a$;vi.createPortal=function(t,e){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!CT(e))throw Error(pe(200));return i$(t,e,null,r)};vi.createRoot=function(t,e){if(!CT(t))throw Error(pe(299));var r=!1,n="",i=vN;return e!=null&&(e.unstable_strictMode===!0&&(r=!0),e.identifierPrefix!==void 0&&(n=e.identifierPrefix),e.onRecoverableError!==void 0&&(i=e.onRecoverableError)),e=ST(t,1,!1,null,null,r,!1,n,i),t[ua]=e.current,gp(t.nodeType===8?t.parentNode:t),new TT(e)};vi.findDOMNode=function(t){if(t==null)return null;if(t.nodeType===1)return t;var e=t._reactInternals;if(e===void 0)throw typeof t.render=="function"?Error(pe(188)):(t=Object.keys(t).join(","),Error(pe(268,t)));return t=BO(e),t=t===null?null:t.stateNode,t};vi.flushSync=function(t){return Ku(t)};vi.hydrate=function(t,e,r){if(!o1(e))throw Error(pe(200));return a1(null,t,e,!0,r)};vi.hydrateRoot=function(t,e,r){if(!CT(t))throw Error(pe(405));var n=r!=null&&r.hydratedSources||null,i=!1,s="",o=vN;if(r!=null&&(r.unstable_strictMode===!0&&(i=!0),r.identifierPrefix!==void 0&&(s=r.identifierPrefix),r.onRecoverableError!==void 0&&(o=r.onRecoverableError)),e=gN(e,null,t,1,r??null,i,!1,s,o),t[ua]=e.current,gp(t),n)for(t=0;t<n.length;t++)r=n[t],i=r._getVersion,i=i(r._source),e.mutableSourceEagerHydrationData==null?e.mutableSourceEagerHydrationData=[r,i]:e.mutableSourceEagerHydrationData.push(r,i);return new s1(e)};vi.render=function(t,e,r){if(!o1(e))throw Error(pe(200));return a1(null,t,e,!1,r)};vi.unmountComponentAtNode=function(t){if(!o1(t))throw Error(pe(40));return t._reactRootContainer?(Ku(function(){a1(null,null,t,!1,function(){t._reactRootContainer=null,t[ua]=null})}),!0):!1};vi.unstable_batchedUpdates=xT;vi.unstable_renderSubtreeIntoContainer=function(t,e,r,n){if(!o1(r))throw Error(pe(200));if(t==null||t._reactInternals===void 0)throw Error(pe(38));return a1(t,e,r,!1,n)};vi.version="18.3.1-next-f1338f8080-20240426";function yN(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(yN)}catch(t){console.error(t)}}yN(),yO.exports=vi;var mr=yO.exports,xN,II=mr;xN=II.createRoot,II.hydrateRoot;var am=t=>t.type==="checkbox",Ru=t=>t instanceof Date,wn=t=>t==null;const bN=t=>typeof t=="object";var ur=t=>!wn(t)&&!Array.isArray(t)&&bN(t)&&!Ru(t),wN=t=>ur(t)&&t.target?am(t.target)?t.target.checked:t.target.value:t,u$=t=>t.substring(0,t.search(/\.\d+(\.|$)/))||t,_N=(t,e)=>t.has(u$(e)),c$=t=>{const e=t.constructor&&t.constructor.prototype;return ur(e)&&e.hasOwnProperty("isPrototypeOf")},AT=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function Ln(t){let e;const r=Array.isArray(t);if(t instanceof Date)e=new Date(t);else if(t instanceof Set)e=new Set(t);else if(!(AT&&(t instanceof Blob||t instanceof FileList))&&(r||ur(t)))if(e=r?[]:{},!r&&!c$(t))e=t;else for(const n in t)t.hasOwnProperty(n)&&(e[n]=Ln(t[n]));else return t;return e}var l1=t=>Array.isArray(t)?t.filter(Boolean):[],er=t=>t===void 0,Se=(t,e,r)=>{if(!e||!ur(t))return r;const n=l1(e.split(/[,[\].]+?/)).reduce((i,s)=>wn(i)?i:i[s],t);return er(n)||n===t?er(t[e])?r:t[e]:n},ki=t=>typeof t=="boolean",RT=t=>/^\w*$/.test(t),SN=t=>l1(t.replace(/["|']|\]/g,"").split(/\.|\[/)),Pt=(t,e,r)=>{let n=-1;const i=RT(e)?[e]:SN(e),s=i.length,o=s-1;for(;++n<s;){const a=i[n];let l=r;if(n!==o){const u=t[a];l=ur(u)||Array.isArray(u)?u:isNaN(+i[n+1])?{}:[]}if(a==="__proto__")return;t[a]=l,t=t[a]}return t};const qv={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},gs={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},jo={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},d$=Ie.createContext(null),PT=()=>Ie.useContext(d$);var EN=(t,e,r,n=!0)=>{const i={defaultValues:e._defaultValues};for(const s in t)Object.defineProperty(i,s,{get:()=>{const o=s;return e._proxyFormState[o]!==gs.all&&(e._proxyFormState[o]=!n||gs.all),r&&(r[o]=!0),t[o]}});return i},Bn=t=>ur(t)&&!Object.keys(t).length,TN=(t,e,r,n)=>{r(t);const{name:i,...s}=t;return Bn(s)||Object.keys(s).length>=Object.keys(e).length||Object.keys(s).find(o=>e[o]===(!n||gs.all))},zf=t=>Array.isArray(t)?t:[t],CN=(t,e,r)=>!t||!e||t===e||zf(t).some(n=>n&&(r?n===e:n.startsWith(e)||e.startsWith(n)));function IT(t){const e=Ie.useRef(t);e.current=t,Ie.useEffect(()=>{const r=!t.disabled&&e.current.subject&&e.current.subject.subscribe({next:e.current.next});return()=>{r&&r.unsubscribe()}},[t.disabled])}function h$(t){const e=PT(),{control:r=e.control,disabled:n,name:i,exact:s}=t||{},[o,a]=Ie.useState(r._formState),l=Ie.useRef(!0),u=Ie.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1}),c=Ie.useRef(i);return c.current=i,IT({disabled:n,next:h=>l.current&&CN(c.current,h.name,s)&&TN(h,u.current,r._updateFormState)&&a({...r._formState,...h}),subject:r._subjects.state}),Ie.useEffect(()=>(l.current=!0,u.current.isValid&&r._updateValid(!0),()=>{l.current=!1}),[r]),EN(o,r,u.current,!1)}var uo=t=>typeof t=="string",AN=(t,e,r,n,i)=>uo(t)?(n&&e.watch.add(t),Se(r,t,i)):Array.isArray(t)?t.map(s=>(n&&e.watch.add(s),Se(r,s))):(n&&(e.watchAll=!0),r);function f$(t){const e=PT(),{control:r=e.control,name:n,defaultValue:i,disabled:s,exact:o}=t||{},a=Ie.useRef(n);a.current=n,IT({disabled:s,subject:r._subjects.values,next:c=>{CN(a.current,c.name,o)&&u(Ln(AN(a.current,r._names,c.values||r._formValues,!1,i)))}});const[l,u]=Ie.useState(r._getWatch(n,i));return Ie.useEffect(()=>r._removeUnmounted()),l}function p$(t){const e=PT(),{name:r,disabled:n,control:i=e.control,shouldUnregister:s}=t,o=_N(i._names.array,r),a=f$({control:i,name:r,defaultValue:Se(i._formValues,r,Se(i._defaultValues,r,t.defaultValue)),exact:!0}),l=h$({control:i,name:r,exact:!0}),u=Ie.useRef(i.register(r,{...t.rules,value:a,...ki(t.disabled)?{disabled:t.disabled}:{}}));return Ie.useEffect(()=>{const c=i._options.shouldUnregister||s,h=(f,m)=>{const y=Se(i._fields,f);y&&y._f&&(y._f.mount=m)};if(h(r,!0),c){const f=Ln(Se(i._options.defaultValues,r));Pt(i._defaultValues,r,f),er(Se(i._formValues,r))&&Pt(i._formValues,r,f)}return()=>{(o?c&&!i._state.action:c)?i.unregister(r):h(r,!1)}},[r,i,o,s]),Ie.useEffect(()=>{Se(i._fields,r)&&i._updateDisabledField({disabled:n,fields:i._fields,name:r,value:Se(i._fields,r)._f.value})},[n,r,i]),{field:{name:r,value:a,...ki(n)||l.disabled?{disabled:l.disabled||n}:{},onChange:Ie.useCallback(c=>u.current.onChange({target:{value:wN(c),name:r},type:qv.CHANGE}),[r]),onBlur:Ie.useCallback(()=>u.current.onBlur({target:{value:Se(i._formValues,r),name:r},type:qv.BLUR}),[r,i]),ref:Ie.useCallback(c=>{const h=Se(i._fields,r);h&&c&&(h._f.ref={focus:()=>c.focus(),select:()=>c.select(),setCustomValidity:f=>c.setCustomValidity(f),reportValidity:()=>c.reportValidity()})},[i._fields,r])},formState:l,fieldState:Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Se(l.errors,r)},isDirty:{enumerable:!0,get:()=>!!Se(l.dirtyFields,r)},isTouched:{enumerable:!0,get:()=>!!Se(l.touchedFields,r)},isValidating:{enumerable:!0,get:()=>!!Se(l.validatingFields,r)},error:{enumerable:!0,get:()=>Se(l.errors,r)}})}}const u1=t=>t.render(p$(t));var m$=(t,e,r,n,i)=>e?{...r[t],types:{...r[t]&&r[t].types?r[t].types:{},[n]:i||!0}}:{},MI=t=>({isOnSubmit:!t||t===gs.onSubmit,isOnBlur:t===gs.onBlur,isOnChange:t===gs.onChange,isOnAll:t===gs.all,isOnTouch:t===gs.onTouched}),kI=(t,e,r)=>!r&&(e.watchAll||e.watch.has(t)||[...e.watch].some(n=>t.startsWith(n)&&/^\.\w+/.test(t.slice(n.length))));const Hf=(t,e,r,n)=>{for(const i of r||Object.keys(t)){const s=Se(t,i);if(s){const{_f:o,...a}=s;if(o){if(o.refs&&o.refs[0]&&e(o.refs[0],i)&&!n)return!0;if(o.ref&&e(o.ref,o.name)&&!n)return!0;if(Hf(a,e))break}else if(ur(a)&&Hf(a,e))break}}};var g$=(t,e,r)=>{const n=zf(Se(t,r));return Pt(n,"root",e[r]),Pt(t,r,n),t},MT=t=>t.type==="file",ao=t=>typeof t=="function",Yv=t=>{if(!AT)return!1;const e=t?t.ownerDocument:0;return t instanceof(e&&e.defaultView?e.defaultView.HTMLElement:HTMLElement)},Y0=t=>uo(t),kT=t=>t.type==="radio",Qv=t=>t instanceof RegExp;const OI={value:!1,isValid:!1},DI={value:!0,isValid:!0};var RN=t=>{if(Array.isArray(t)){if(t.length>1){const e=t.filter(r=>r&&r.checked&&!r.disabled).map(r=>r.value);return{value:e,isValid:!!e.length}}return t[0].checked&&!t[0].disabled?t[0].attributes&&!er(t[0].attributes.value)?er(t[0].value)||t[0].value===""?DI:{value:t[0].value,isValid:!0}:DI:OI}return OI};const NI={isValid:!1,value:null};var PN=t=>Array.isArray(t)?t.reduce((e,r)=>r&&r.checked&&!r.disabled?{isValid:!0,value:r.value}:e,NI):NI;function LI(t,e,r="validate"){if(Y0(t)||Array.isArray(t)&&t.every(Y0)||ki(t)&&!t)return{type:r,message:Y0(t)?t:"",ref:e}}var Oc=t=>ur(t)&&!Qv(t)?t:{value:t,message:""},FI=async(t,e,r,n,i)=>{const{ref:s,refs:o,required:a,maxLength:l,minLength:u,min:c,max:h,pattern:f,validate:m,name:y,valueAsNumber:v,mount:x,disabled:b}=t._f,_=Se(e,y);if(!x||b)return{};const w=o?o[0]:s,E=H=>{n&&w.reportValidity&&(w.setCustomValidity(ki(H)?"":H||""),w.reportValidity())},A={},P=kT(s),I=am(s),M=P||I,N=(v||MT(s))&&er(s.value)&&er(_)||Yv(s)&&s.value===""||_===""||Array.isArray(_)&&!_.length,z=m$.bind(null,y,r,A),j=(H,F,L,O=jo.maxLength,$=jo.minLength)=>{const V=H?F:L;A[y]={type:H?O:$,message:V,ref:s,...z(H?O:$,V)}};if(i?!Array.isArray(_)||!_.length:a&&(!M&&(N||wn(_))||ki(_)&&!_||I&&!RN(o).isValid||P&&!PN(o).isValid)){const{value:H,message:F}=Y0(a)?{value:!!a,message:a}:Oc(a);if(H&&(A[y]={type:jo.required,message:F,ref:w,...z(jo.required,F)},!r))return E(F),A}if(!N&&(!wn(c)||!wn(h))){let H,F;const L=Oc(h),O=Oc(c);if(!wn(_)&&!isNaN(_)){const $=s.valueAsNumber||_&&+_;wn(L.value)||(H=$>L.value),wn(O.value)||(F=$<O.value)}else{const $=s.valueAsDate||new Date(_),V=B=>new Date(new Date().toDateString()+" "+B),k=s.type=="time",U=s.type=="week";uo(L.value)&&_&&(H=k?V(_)>V(L.value):U?_>L.value:$>new Date(L.value)),uo(O.value)&&_&&(F=k?V(_)<V(O.value):U?_<O.value:$<new Date(O.value))}if((H||F)&&(j(!!H,L.message,O.message,jo.max,jo.min),!r))return E(A[y].message),A}if((l||u)&&!N&&(uo(_)||i&&Array.isArray(_))){const H=Oc(l),F=Oc(u),L=!wn(H.value)&&_.length>+H.value,O=!wn(F.value)&&_.length<+F.value;if((L||O)&&(j(L,H.message,F.message),!r))return E(A[y].message),A}if(f&&!N&&uo(_)){const{value:H,message:F}=Oc(f);if(Qv(H)&&!_.match(H)&&(A[y]={type:jo.pattern,message:F,ref:s,...z(jo.pattern,F)},!r))return E(F),A}if(m){if(ao(m)){const H=await m(_,e),F=LI(H,w);if(F&&(A[y]={...F,...z(jo.validate,F.message)},!r))return E(F.message),A}else if(ur(m)){let H={};for(const F in m){if(!Bn(H)&&!r)break;const L=LI(await m[F](_,e),w,F);L&&(H={...L,...z(F,L.message)},E(L.message),r&&(A[y]=H))}if(!Bn(H)&&(A[y]={ref:w,...H},!r))return A}}return E(!0),A};function v$(t,e){const r=e.slice(0,-1).length;let n=0;for(;n<r;)t=er(t)?n++:t[e[n++]];return t}function y$(t){for(const e in t)if(t.hasOwnProperty(e)&&!er(t[e]))return!1;return!0}function yr(t,e){const r=Array.isArray(e)?e:RT(e)?[e]:SN(e),n=r.length===1?t:v$(t,r),i=r.length-1,s=r[i];return n&&delete n[s],i!==0&&(ur(n)&&Bn(n)||Array.isArray(n)&&y$(n))&&yr(t,r.slice(0,-1)),t}var Zb=()=>{let t=[];return{get observers(){return t},next:i=>{for(const s of t)s.next&&s.next(i)},subscribe:i=>(t.push(i),{unsubscribe:()=>{t=t.filter(s=>s!==i)}}),unsubscribe:()=>{t=[]}}},ES=t=>wn(t)||!bN(t);function qa(t,e){if(ES(t)||ES(e))return t===e;if(Ru(t)&&Ru(e))return t.getTime()===e.getTime();const r=Object.keys(t),n=Object.keys(e);if(r.length!==n.length)return!1;for(const i of r){const s=t[i];if(!n.includes(i))return!1;if(i!=="ref"){const o=e[i];if(Ru(s)&&Ru(o)||ur(s)&&ur(o)||Array.isArray(s)&&Array.isArray(o)?!qa(s,o):s!==o)return!1}}return!0}var IN=t=>t.type==="select-multiple",x$=t=>kT(t)||am(t),Jb=t=>Yv(t)&&t.isConnected,MN=t=>{for(const e in t)if(ao(t[e]))return!0;return!1};function Kv(t,e={}){const r=Array.isArray(t);if(ur(t)||r)for(const n in t)Array.isArray(t[n])||ur(t[n])&&!MN(t[n])?(e[n]=Array.isArray(t[n])?[]:{},Kv(t[n],e[n])):wn(t[n])||(e[n]=!0);return e}function kN(t,e,r){const n=Array.isArray(t);if(ur(t)||n)for(const i in t)Array.isArray(t[i])||ur(t[i])&&!MN(t[i])?er(e)||ES(r[i])?r[i]=Array.isArray(t[i])?Kv(t[i],[]):{...Kv(t[i])}:kN(t[i],wn(e)?{}:e[i],r[i]):r[i]=!qa(t[i],e[i]);return r}var Jh=(t,e)=>kN(t,e,Kv(e)),ON=(t,{valueAsNumber:e,valueAsDate:r,setValueAs:n})=>er(t)?t:e?t===""?NaN:t&&+t:r&&uo(t)?new Date(t):n?n(t):t;function ew(t){const e=t.ref;if(!(t.refs?t.refs.every(r=>r.disabled):e.disabled))return MT(e)?e.files:kT(e)?PN(t.refs).value:IN(e)?[...e.selectedOptions].map(({value:r})=>r):am(e)?RN(t.refs).value:ON(er(e.value)?t.ref.value:e.value,t)}var b$=(t,e,r,n)=>{const i={};for(const s of t){const o=Se(e,s);o&&Pt(i,s,o._f)}return{criteriaMode:r,names:[...t],fields:i,shouldUseNativeValidation:n}},ef=t=>er(t)?t:Qv(t)?t.source:ur(t)?Qv(t.value)?t.value.source:t.value:t;const jI="AsyncFunction";var w$=t=>(!t||!t.validate)&&!!(ao(t.validate)&&t.validate.constructor.name===jI||ur(t.validate)&&Object.values(t.validate).find(e=>e.constructor.name===jI)),_$=t=>t.mount&&(t.required||t.min||t.max||t.maxLength||t.minLength||t.pattern||t.validate);function BI(t,e,r){const n=Se(t,r);if(n||RT(r))return{error:n,name:r};const i=r.split(".");for(;i.length;){const s=i.join("."),o=Se(e,s),a=Se(t,s);if(o&&!Array.isArray(o)&&r!==s)return{name:r};if(a&&a.type)return{name:s,error:a};i.pop()}return{name:r}}var S$=(t,e,r,n,i)=>i.isOnAll?!1:!r&&i.isOnTouch?!(e||t):(r?n.isOnBlur:i.isOnBlur)?!t:(r?n.isOnChange:i.isOnChange)?t:!0,E$=(t,e)=>!l1(Se(t,e)).length&&yr(t,e);const T$={mode:gs.onSubmit,reValidateMode:gs.onChange,shouldFocusError:!0};function C$(t={}){let e={...T$,...t},r={submitCount:0,isDirty:!1,isLoading:ao(e.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1},n={},i=ur(e.defaultValues)||ur(e.values)?Ln(e.defaultValues||e.values)||{}:{},s=e.shouldUnregister?{}:Ln(i),o={action:!1,mount:!1,watch:!1},a={mount:new Set,unMount:new Set,array:new Set,watch:new Set},l,u=0;const c={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},h={values:Zb(),array:Zb(),state:Zb()},f=MI(e.mode),m=MI(e.reValidateMode),y=e.criteriaMode===gs.all,v=W=>J=>{clearTimeout(u),u=setTimeout(W,J)},x=async W=>{if(!e.disabled&&(c.isValid||W)){const J=e.resolver?Bn((await M()).errors):await z(n,!0);J!==r.isValid&&h.state.next({isValid:J})}},b=(W,J)=>{!e.disabled&&(c.isValidating||c.validatingFields)&&((W||Array.from(a.mount)).forEach(te=>{te&&(J?Pt(r.validatingFields,te,J):yr(r.validatingFields,te))}),h.state.next({validatingFields:r.validatingFields,isValidating:!Bn(r.validatingFields)}))},_=(W,J=[],te,be,ge=!0,ce=!0)=>{if(be&&te&&!e.disabled){if(o.action=!0,ce&&Array.isArray(Se(n,W))){const ke=te(Se(n,W),be.argA,be.argB);ge&&Pt(n,W,ke)}if(ce&&Array.isArray(Se(r.errors,W))){const ke=te(Se(r.errors,W),be.argA,be.argB);ge&&Pt(r.errors,W,ke),E$(r.errors,W)}if(c.touchedFields&&ce&&Array.isArray(Se(r.touchedFields,W))){const ke=te(Se(r.touchedFields,W),be.argA,be.argB);ge&&Pt(r.touchedFields,W,ke)}c.dirtyFields&&(r.dirtyFields=Jh(i,s)),h.state.next({name:W,isDirty:H(W,J),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else Pt(s,W,J)},w=(W,J)=>{Pt(r.errors,W,J),h.state.next({errors:r.errors})},E=W=>{r.errors=W,h.state.next({errors:r.errors,isValid:!1})},A=(W,J,te,be)=>{const ge=Se(n,W);if(ge){const ce=Se(s,W,er(te)?Se(i,W):te);er(ce)||be&&be.defaultChecked||J?Pt(s,W,J?ce:ew(ge._f)):O(W,ce),o.mount&&x()}},P=(W,J,te,be,ge)=>{let ce=!1,ke=!1;const et={name:W};if(!e.disabled){const ze=!!(Se(n,W)&&Se(n,W)._f&&Se(n,W)._f.disabled);if(!te||be){c.isDirty&&(ke=r.isDirty,r.isDirty=et.isDirty=H(),ce=ke!==et.isDirty);const Ue=ze||qa(Se(i,W),J);ke=!!(!ze&&Se(r.dirtyFields,W)),Ue||ze?yr(r.dirtyFields,W):Pt(r.dirtyFields,W,!0),et.dirtyFields=r.dirtyFields,ce=ce||c.dirtyFields&&ke!==!Ue}if(te){const Ue=Se(r.touchedFields,W);Ue||(Pt(r.touchedFields,W,te),et.touchedFields=r.touchedFields,ce=ce||c.touchedFields&&Ue!==te)}ce&&ge&&h.state.next(et)}return ce?et:{}},I=(W,J,te,be)=>{const ge=Se(r.errors,W),ce=c.isValid&&ki(J)&&r.isValid!==J;if(t.delayError&&te?(l=v(()=>w(W,te)),l(t.delayError)):(clearTimeout(u),l=null,te?Pt(r.errors,W,te):yr(r.errors,W)),(te?!qa(ge,te):ge)||!Bn(be)||ce){const ke={...be,...ce&&ki(J)?{isValid:J}:{},errors:r.errors,name:W};r={...r,...ke},h.state.next(ke)}},M=async W=>{b(W,!0);const J=await e.resolver(s,e.context,b$(W||a.mount,n,e.criteriaMode,e.shouldUseNativeValidation));return b(W),J},N=async W=>{const{errors:J}=await M(W);if(W)for(const te of W){const be=Se(J,te);be?Pt(r.errors,te,be):yr(r.errors,te)}else r.errors=J;return J},z=async(W,J,te={valid:!0})=>{for(const be in W){const ge=W[be];if(ge){const{_f:ce,...ke}=ge;if(ce){const et=a.array.has(ce.name),ze=ge._f&&w$(ge._f);ze&&c.validatingFields&&b([be],!0);const Ue=await FI(ge,s,y,e.shouldUseNativeValidation&&!J,et);if(ze&&c.validatingFields&&b([be]),Ue[ce.name]&&(te.valid=!1,J))break;!J&&(Se(Ue,ce.name)?et?g$(r.errors,Ue,ce.name):Pt(r.errors,ce.name,Ue[ce.name]):yr(r.errors,ce.name))}!Bn(ke)&&await z(ke,J,te)}}return te.valid},j=()=>{for(const W of a.unMount){const J=Se(n,W);J&&(J._f.refs?J._f.refs.every(te=>!Jb(te)):!Jb(J._f.ref))&&le(W)}a.unMount=new Set},H=(W,J)=>!e.disabled&&(W&&J&&Pt(s,W,J),!qa(X(),i)),F=(W,J,te)=>AN(W,a,{...o.mount?s:er(J)?i:uo(W)?{[W]:J}:J},te,J),L=W=>l1(Se(o.mount?s:i,W,t.shouldUnregister?Se(i,W,[]):[])),O=(W,J,te={})=>{const be=Se(n,W);let ge=J;if(be){const ce=be._f;ce&&(!ce.disabled&&Pt(s,W,ON(J,ce)),ge=Yv(ce.ref)&&wn(J)?"":J,IN(ce.ref)?[...ce.ref.options].forEach(ke=>ke.selected=ge.includes(ke.value)):ce.refs?am(ce.ref)?ce.refs.length>1?ce.refs.forEach(ke=>(!ke.defaultChecked||!ke.disabled)&&(ke.checked=Array.isArray(ge)?!!ge.find(et=>et===ke.value):ge===ke.value)):ce.refs[0]&&(ce.refs[0].checked=!!ge):ce.refs.forEach(ke=>ke.checked=ke.value===ge):MT(ce.ref)?ce.ref.value="":(ce.ref.value=ge,ce.ref.type||h.values.next({name:W,values:{...s}})))}(te.shouldDirty||te.shouldTouch)&&P(W,ge,te.shouldTouch,te.shouldDirty,!0),te.shouldValidate&&B(W)},$=(W,J,te)=>{for(const be in J){const ge=J[be],ce=`${W}.${be}`,ke=Se(n,ce);(a.array.has(W)||ur(ge)||ke&&!ke._f)&&!Ru(ge)?$(ce,ge,te):O(ce,ge,te)}},V=(W,J,te={})=>{const be=Se(n,W),ge=a.array.has(W),ce=Ln(J);Pt(s,W,ce),ge?(h.array.next({name:W,values:{...s}}),(c.isDirty||c.dirtyFields)&&te.shouldDirty&&h.state.next({name:W,dirtyFields:Jh(i,s),isDirty:H(W,ce)})):be&&!be._f&&!wn(ce)?$(W,ce,te):O(W,ce,te),kI(W,a)&&h.state.next({...r}),h.values.next({name:o.mount?W:void 0,values:{...s}})},k=async W=>{o.mount=!0;const J=W.target;let te=J.name,be=!0;const ge=Se(n,te),ce=()=>J.type?ew(ge._f):wN(W),ke=et=>{be=Number.isNaN(et)||Ru(et)&&isNaN(et.getTime())||qa(et,Se(s,te,et))};if(ge){let et,ze;const Ue=ce(),$e=W.type===qv.BLUR||W.type===qv.FOCUS_OUT,pt=!_$(ge._f)&&!e.resolver&&!Se(r.errors,te)&&!ge._f.deps||S$($e,Se(r.touchedFields,te),r.isSubmitted,m,f),Pr=kI(te,a,$e);Pt(s,te,Ue),$e?(ge._f.onBlur&&ge._f.onBlur(W),l&&l(0)):ge._f.onChange&&ge._f.onChange(W);const Dt=P(te,Ue,$e,!1),ct=!Bn(Dt)||Pr;if(!$e&&h.values.next({name:te,type:W.type,values:{...s}}),pt)return c.isValid&&(t.mode==="onBlur"?$e&&x():x()),ct&&h.state.next({name:te,...Pr?{}:Dt});if(!$e&&Pr&&h.state.next({...r}),e.resolver){const{errors:Qe}=await M([te]);if(ke(Ue),be){const tn=BI(r.errors,n,te),bi=BI(Qe,n,tn.name||te);et=bi.error,te=bi.name,ze=Bn(Qe)}}else b([te],!0),et=(await FI(ge,s,y,e.shouldUseNativeValidation))[te],b([te]),ke(Ue),be&&(et?ze=!1:c.isValid&&(ze=await z(n,!0)));be&&(ge._f.deps&&B(ge._f.deps),I(te,ze,et,Dt))}},U=(W,J)=>{if(Se(r.errors,J)&&W.focus)return W.focus(),1},B=async(W,J={})=>{let te,be;const ge=zf(W);if(e.resolver){const ce=await N(er(W)?W:ge);te=Bn(ce),be=W?!ge.some(ke=>Se(ce,ke)):te}else W?(be=(await Promise.all(ge.map(async ce=>{const ke=Se(n,ce);return await z(ke&&ke._f?{[ce]:ke}:ke)}))).every(Boolean),!(!be&&!r.isValid)&&x()):be=te=await z(n);return h.state.next({...!uo(W)||c.isValid&&te!==r.isValid?{}:{name:W},...e.resolver||!W?{isValid:te}:{},errors:r.errors}),J.shouldFocus&&!be&&Hf(n,U,W?ge:a.mount),be},X=W=>{const J={...o.mount?s:i};return er(W)?J:uo(W)?Se(J,W):W.map(te=>Se(J,te))},K=(W,J)=>({invalid:!!Se((J||r).errors,W),isDirty:!!Se((J||r).dirtyFields,W),error:Se((J||r).errors,W),isValidating:!!Se(r.validatingFields,W),isTouched:!!Se((J||r).touchedFields,W)}),q=W=>{W&&zf(W).forEach(J=>yr(r.errors,J)),h.state.next({errors:W?r.errors:{}})},re=(W,J,te)=>{const be=(Se(n,W,{_f:{}})._f||{}).ref,ge=Se(r.errors,W)||{},{ref:ce,message:ke,type:et,...ze}=ge;Pt(r.errors,W,{...ze,...J,ref:be}),h.state.next({name:W,errors:r.errors,isValid:!1}),te&&te.shouldFocus&&be&&be.focus&&be.focus()},ue=(W,J)=>ao(W)?h.values.subscribe({next:te=>W(F(void 0,J),te)}):F(W,J,!0),le=(W,J={})=>{for(const te of W?zf(W):a.mount)a.mount.delete(te),a.array.delete(te),J.keepValue||(yr(n,te),yr(s,te)),!J.keepError&&yr(r.errors,te),!J.keepDirty&&yr(r.dirtyFields,te),!J.keepTouched&&yr(r.touchedFields,te),!J.keepIsValidating&&yr(r.validatingFields,te),!e.shouldUnregister&&!J.keepDefaultValue&&yr(i,te);h.values.next({values:{...s}}),h.state.next({...r,...J.keepDirty?{isDirty:H()}:{}}),!J.keepIsValid&&x()},me=({disabled:W,name:J,field:te,fields:be,value:ge})=>{if(ki(W)&&o.mount||W){const ce=W?void 0:er(ge)?ew(te?te._f:Se(be,J)._f):ge;Pt(s,J,ce),P(J,ce,!1,!1,!0)}},xe=(W,J={})=>{let te=Se(n,W);const be=ki(J.disabled)||ki(e.disabled);return Pt(n,W,{...te||{},_f:{...te&&te._f?te._f:{ref:{name:W}},name:W,mount:!0,...J}}),a.mount.add(W),te?me({field:te,disabled:ki(J.disabled)?J.disabled:e.disabled,name:W,value:J.value}):A(W,!0,J.value),{...be?{disabled:J.disabled||e.disabled}:{},...e.progressive?{required:!!J.required,min:ef(J.min),max:ef(J.max),minLength:ef(J.minLength),maxLength:ef(J.maxLength),pattern:ef(J.pattern)}:{},name:W,onChange:k,onBlur:k,ref:ge=>{if(ge){xe(W,J),te=Se(n,W);const ce=er(ge.value)&&ge.querySelectorAll&&ge.querySelectorAll("input,select,textarea")[0]||ge,ke=x$(ce),et=te._f.refs||[];if(ke?et.find(ze=>ze===ce):ce===te._f.ref)return;Pt(n,W,{_f:{...te._f,...ke?{refs:[...et.filter(Jb),ce,...Array.isArray(Se(i,W))?[{}]:[]],ref:{type:ce.type,name:W}}:{ref:ce}}}),A(W,!1,void 0,ce)}else te=Se(n,W,{}),te._f&&(te._f.mount=!1),(e.shouldUnregister||J.shouldUnregister)&&!(_N(a.array,W)&&o.action)&&a.unMount.add(W)}}},_e=()=>e.shouldFocusError&&Hf(n,U,a.mount),Te=W=>{ki(W)&&(h.state.next({disabled:W}),Hf(n,(J,te)=>{const be=Se(n,te);be&&(J.disabled=be._f.disabled||W,Array.isArray(be._f.refs)&&be._f.refs.forEach(ge=>{ge.disabled=be._f.disabled||W}))},0,!1))},de=(W,J)=>async te=>{let be;if(te&&(te.preventDefault&&te.preventDefault(),te.persist&&te.persist()),e.disabled){J&&await J({...r.errors},te);return}let ge=Ln(s);if(h.state.next({isSubmitting:!0}),e.resolver){const{errors:ce,values:ke}=await M();r.errors=ce,ge=ke}else await z(n);if(yr(r.errors,"root"),Bn(r.errors)){h.state.next({errors:{}});try{await W(ge,te)}catch(ce){be=ce}}else J&&await J({...r.errors},te),_e(),setTimeout(_e);if(h.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:Bn(r.errors)&&!be,submitCount:r.submitCount+1,errors:r.errors}),be)throw be},Be=(W,J={})=>{Se(n,W)&&(er(J.defaultValue)?V(W,Ln(Se(i,W))):(V(W,J.defaultValue),Pt(i,W,Ln(J.defaultValue))),J.keepTouched||yr(r.touchedFields,W),J.keepDirty||(yr(r.dirtyFields,W),r.isDirty=J.defaultValue?H(W,Ln(Se(i,W))):H()),J.keepError||(yr(r.errors,W),c.isValid&&x()),h.state.next({...r}))},je=(W,J={})=>{const te=W?Ln(W):i,be=Ln(te),ge=Bn(W),ce=ge?i:be;if(J.keepDefaultValues||(i=te),!J.keepValues){if(J.keepDirtyValues){const ke=new Set([...a.mount,...Object.keys(Jh(i,s))]);for(const et of Array.from(ke))Se(r.dirtyFields,et)?Pt(ce,et,Se(s,et)):V(et,Se(ce,et))}else{if(AT&&er(W))for(const ke of a.mount){const et=Se(n,ke);if(et&&et._f){const ze=Array.isArray(et._f.refs)?et._f.refs[0]:et._f.ref;if(Yv(ze)){const Ue=ze.closest("form");if(Ue){Ue.reset();break}}}}n={}}s=t.shouldUnregister?J.keepDefaultValues?Ln(i):{}:Ln(ce),h.array.next({values:{...ce}}),h.values.next({values:{...ce}})}a={mount:J.keepDirtyValues?a.mount:new Set,unMount:new Set,array:new Set,watch:new Set,watchAll:!1,focus:""},o.mount=!c.isValid||!!J.keepIsValid||!!J.keepDirtyValues,o.watch=!!t.shouldUnregister,h.state.next({submitCount:J.keepSubmitCount?r.submitCount:0,isDirty:ge?!1:J.keepDirty?r.isDirty:!!(J.keepDefaultValues&&!qa(W,i)),isSubmitted:J.keepIsSubmitted?r.isSubmitted:!1,dirtyFields:ge?{}:J.keepDirtyValues?J.keepDefaultValues&&s?Jh(i,s):r.dirtyFields:J.keepDefaultValues&&W?Jh(i,W):J.keepDirty?r.dirtyFields:{},touchedFields:J.keepTouched?r.touchedFields:{},errors:J.keepErrors?r.errors:{},isSubmitSuccessful:J.keepIsSubmitSuccessful?r.isSubmitSuccessful:!1,isSubmitting:!1})},ut=(W,J)=>je(ao(W)?W(s):W,J);return{control:{register:xe,unregister:le,getFieldState:K,handleSubmit:de,setError:re,_executeSchema:M,_getWatch:F,_getDirty:H,_updateValid:x,_removeUnmounted:j,_updateFieldArray:_,_updateDisabledField:me,_getFieldArray:L,_reset:je,_resetDefaultValues:()=>ao(e.defaultValues)&&e.defaultValues().then(W=>{ut(W,e.resetOptions),h.state.next({isLoading:!1})}),_updateFormState:W=>{r={...r,...W}},_disableForm:Te,_subjects:h,_proxyFormState:c,_setErrors:E,get _fields(){return n},get _formValues(){return s},get _state(){return o},set _state(W){o=W},get _defaultValues(){return i},get _names(){return a},set _names(W){a=W},get _formState(){return r},set _formState(W){r=W},get _options(){return e},set _options(W){e={...e,...W}}},trigger:B,register:xe,handleSubmit:de,watch:ue,setValue:V,getValues:X,reset:ut,resetField:Be,clearErrors:q,unregister:le,setError:re,setFocus:(W,J={})=>{const te=Se(n,W),be=te&&te._f;if(be){const ge=be.refs?be.refs[0]:be.ref;ge.focus&&(ge.focus(),J.shouldSelect&&ao(ge.select)&&ge.select())}},getFieldState:K}}function OT(t={}){const e=Ie.useRef(),r=Ie.useRef(),[n,i]=Ie.useState({isDirty:!1,isValidating:!1,isLoading:ao(t.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:t.errors||{},disabled:t.disabled||!1,defaultValues:ao(t.defaultValues)?void 0:t.defaultValues});e.current||(e.current={...C$(t),formState:n});const s=e.current.control;return s._options=t,IT({subject:s._subjects.state,next:o=>{TN(o,s._proxyFormState,s._updateFormState,!0)&&i({...s._formState})}}),Ie.useEffect(()=>s._disableForm(t.disabled),[s,t.disabled]),Ie.useEffect(()=>{if(s._proxyFormState.isDirty){const o=s._getDirty();o!==n.isDirty&&s._subjects.state.next({isDirty:o})}},[s,n.isDirty]),Ie.useEffect(()=>{t.values&&!qa(t.values,r.current)?(s._reset(t.values,s._options.resetOptions),r.current=t.values,i(o=>({...o}))):s._resetDefaultValues()},[t.values,s]),Ie.useEffect(()=>{t.errors&&s._setErrors(t.errors)},[t.errors,s]),Ie.useEffect(()=>{s._state.mount||(s._updateValid(),s._state.mount=!0),s._state.watch&&(s._state.watch=!1,s._subjects.state.next({...s._formState})),s._removeUnmounted()}),Ie.useEffect(()=>{t.shouldUnregister&&s._subjects.values.next({values:s._getWatch()})},[t.shouldUnregister,s]),e.current.formState=EN(n,s),e.current}function DN(t){var e,r,n="";if(typeof t=="string"||typeof t=="number")n+=t;else if(typeof t=="object")if(Array.isArray(t)){var i=t.length;for(e=0;e<i;e++)t[e]&&(r=DN(t[e]))&&(n&&(n+=" "),n+=r)}else for(r in t)t[r]&&(n&&(n+=" "),n+=r);return n}function Re(){for(var t,e,r=0,n="",i=arguments.length;r<i;r++)(t=arguments[r])&&(e=DN(t))&&(n&&(n+=" "),n+=e);return n}const A$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18M1 12C1 5.925 5.925 1 12 1s11 4.925 11 11-4.925 11-11 11S1 18.075 1 12",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 6a1 1 0 0 1 1 1v5a1 1 0 1 1-2 0V7a1 1 0 0 1 1-1M11 16a1 1 0 0 1 1-1h.01a1 1 0 1 1 0 2H12a1 1 0 0 1-1-1",clipRule:"evenodd"})]}),R$=A$,P$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M1 3c0-1.1.9-2 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2zm8 0H3v6h6zm4 0c0-1.1.9-2 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2h-6a2 2 0 0 1-2-2zm8 0h-6v6h6zm-8 12c0-1.1.9-2 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2h-6a2 2 0 0 1-2-2zm8 0h-6v6h6zM1 15c0-1.1.9-2 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2zm8 0H3v6h6z",clipRule:"evenodd"})]}),NN=P$,I$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 12a1 1 0 0 1 1-1h14a1 1 0 1 1 0 2H5a1 1 0 0 1-1-1",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12.707 4.293a1 1 0 0 1 0 1.414L6.414 12l6.293 6.293a1 1 0 0 1-1.414 1.414l-7-7a1 1 0 0 1 0-1.414l7-7a1 1 0 0 1 1.414 0",clipRule:"evenodd"})]}),M$=I$,k$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 12a1 1 0 0 1 1-1h14a1 1 0 1 1 0 2H5a1 1 0 0 1-1-1",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M11.293 4.293a1 1 0 0 1 1.414 0l7 7a1 1 0 0 1 0 1.414l-7 7a1 1 0 0 1-1.414-1.414L17.586 12l-6.293-6.293a1 1 0 0 1 0-1.414",clipRule:"evenodd"})]}),TS=k$,O$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("g",{fill:"currentColor",fillRule:"evenodd",clipPath:"url(#blur_svg__a)",clipRule:"evenodd",children:g.jsx("path",{d:"M17.504 1.673a1 1 0 0 1 .932.491c.37.63.9 1.935 1.404 3.18l.08.197c.502 1.24.994 2.457 1.369 3.205l-.895.447.895-.447c.561 1.122 1.962 4.049 2.136 6.753.087 1.364-.125 2.839-1.094 3.978-.987 1.16-2.573 1.76-4.757 1.76-2.186 0-3.777-.6-4.777-1.752-.983-1.134-1.221-2.604-1.152-3.973.138-2.711 1.514-5.636 2.13-6.79.86-1.611 2.414-5.32 2.874-6.433a1 1 0 0 1 .855-.616m.104 3.492c-.657 1.533-1.496 3.425-2.07 4.5-.59 1.106-1.781 3.703-1.895 5.949-.057 1.11.158 1.976.665 2.56.49.565 1.427 1.063 3.266 1.063 1.84 0 2.76-.498 3.233-1.055.492-.579.694-1.44.622-2.555-.145-2.253-1.36-4.848-1.929-5.986-.412-.823-.932-2.108-1.417-3.308l-.097-.238q-.196-.487-.378-.93M12.843 22.535a1 1 0 0 1-1.034.964l-.259-.009a1 1 0 0 1-.257-.042q-.125.029-.26.024l-.257-.009a11 11 0 0 1-2.102-.279 1 1 0 0 1 .457-1.947 9 9 0 0 0 1.715.228l.258.009q.134.004.257.042.125-.028.26-.024l.257.009a1 1 0 0 1 .965 1.034m-6.615-1.329a1 1 0 0 1-1.396.226 10.9 10.9 0 0 1-2.877-3.086 1 1 0 1 1 1.7-1.054 8.9 8.9 0 0 0 2.347 2.518 1 1 0 0 1 .226 1.396M1.622 15.22a1 1 0 0 1-1.147-.827 10.9 10.9 0 0 1 .148-4.218 1 1 0 0 1 1.947.457 8.9 8.9 0 0 0-.12 3.441 1 1 0 0 1-.828 1.147m.978-7.49a1 1 0 0 1-.226-1.397A10.9 10.9 0 0 1 5.46 3.455a1 1 0 0 1 1.054 1.7 8.9 8.9 0 0 0-2.518 2.347 1 1 0 0 1-1.396.226m5.988-4.607a1 1 0 0 1 .827-1.147 11 11 0 0 1 2.116-.132l.258.01q.135.004.257.042.125-.03.26-.025l.258.01a1 1 0 0 1-.07 1.998l-.258-.009a1 1 0 0 1-.258-.043q-.125.03-.259.025l-.258-.009a9 9 0 0 0-1.727.108 1 1 0 0 1-1.146-.828"})}),g.jsx("defs",{children:g.jsx("clipPath",{id:"blur_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),D$=O$,N$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",d:"M7 4a1 1 0 0 0-1 1v14.06l5.42-3.87a1 1 0 0 1 1.16 0L18 19.06V5a1 1 0 0 0-1-1zM4.88 2.88A3 3 0 0 1 7 2h10a3 3 0 0 1 3 3v16a1 1 0 0 1-1.58.81L12 17.23 5.58 21.8A1 1 0 0 1 4 21V5a3 3 0 0 1 .88-2.12"})]}),DT=N$,L$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M21 5c0 .828-.711 1.5-1.588 1.5H4.588C3.711 6.5 3 5.828 3 5s.711-1.5 1.588-1.5h14.824C20.289 3.5 21 4.172 21 5M21 12c0 .828-.711 1.5-1.588 1.5H4.588C3.711 13.5 3 12.828 3 12s.711-1.5 1.588-1.5h14.824c.877 0 1.588.672 1.588 1.5M21 19c0 .828-.711 1.5-1.588 1.5H4.588C3.711 20.5 3 19.828 3 19s.711-1.5 1.588-1.5h14.824c.877 0 1.588.672 1.588 1.5",clipRule:"evenodd"})]}),F$=L$,j$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4.222 4.222a1.1 1.1 0 0 1 1.556 0l14 14a1.1 1.1 0 1 1-1.556 1.556l-14-14a1.1 1.1 0 0 1 0-1.556",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M19.778 4.222a1.1 1.1 0 0 1 0 1.556l-14 14a1.1 1.1 0 1 1-1.556-1.556l14-14a1.1 1.1 0 0 1 1.556 0",clipRule:"evenodd"})]}),NT=j$,B$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M17.327 5.76a1 1 0 0 1 1.413.067l5 5.5a1 1 0 0 1 0 1.346l-5 5.5a1 1 0 1 1-1.48-1.346L21.648 12 17.26 7.173a1 1 0 0 1 .067-1.413M6.673 5.76a1 1 0 0 1 .067 1.413L2.35 12l4.389 4.827a1 1 0 0 1-1.48 1.346l-5-5.5a1 1 0 0 1 0-1.346l5-5.5a1 1 0 0 1 1.413-.067M8.979 21.609a1 1 0 0 1-.658-1.252l5.375-17.29a1 1 0 1 1 1.91.594L10.23 20.95a1 1 0 0 1-1.251.658",clipRule:"evenodd"})]}),CS=B$,U$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M6.676 3c.284-.672.853-1 1.263-1h11.423c.566 0 1.438.628 1.438 1.923v13.154c0 1.056-.58 1.668-1.1 1.858V6.923C19.7 4.99 18.3 3 16.061 3zm-2.272.007C4.765 1.41 6.056 0 7.939 0h11.423C21.599 0 23 1.99 23 3.923v13.154c0 1.865-1.303 3.782-3.403 3.916C19.235 22.59 17.944 24 16.06 24H4.638C2.401 24 1 22.01 1 20.077V6.923c0-1.865 1.303-3.782 3.404-3.916M3.2 6.923C3.2 5.628 4.072 5 4.638 5h11.423c.567 0 1.439.628 1.439 1.923v13.154c0 1.295-.872 1.923-1.439 1.923H4.638c-.566 0-1.438-.628-1.438-1.923z",clipRule:"evenodd"})]}),$$=U$,z$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("g",{clipPath:"url(#crop_svg__a)",children:g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7.13 1.009a1 1 0 1 0-2-.018l-.036 4.103-4.103.036a1 1 0 1 0 .018 2l4.068-.035L5 15.99V16a3 3 0 0 0 3 3h9v4a1 1 0 1 0 2 0v-4h4a1 1 0 1 0 0-2h-4V8a3 3 0 0 0-3-3l-8.905.077zm-.053 6.068L7 16.004A1 1 0 0 0 8 17h9V8a1 1 0 0 0-.996-1z",clipRule:"evenodd"})}),g.jsx("defs",{children:g.jsx("clipPath",{id:"crop_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),H$=z$,V$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M9.461 3.689a.96.96 0 0 1 .675-.28h3.819a.955.955 0 0 1 .954.955v.954H9.182v-.954c0-.254.1-.496.28-.675m7.357.675v.954h3.818a.955.955 0 0 1 0 1.91h-.954v12.408a2.864 2.864 0 0 1-2.864 2.864H7.273a2.864 2.864 0 0 1-2.864-2.864V7.227h-.954a.955.955 0 1 1 0-1.909h3.818v-.954A2.864 2.864 0 0 1 10.136 1.5h3.819a2.864 2.864 0 0 1 2.863 2.864m-10.5 2.863v12.41a.954.954 0 0 0 .955.954h9.545a.955.955 0 0 0 .955-.955V7.227zm3.818 2.864c.528 0 .955.427.955.955v5.727a.955.955 0 1 1-1.91 0v-5.727c0-.528.428-.955.955-.955m4.773 6.682v-5.727a.955.955 0 0 0-1.909 0v5.727a.955.955 0 1 0 1.91 0",clipRule:"evenodd"})]}),LN=V$,G$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsxs("g",{fill:"currentColor",fillRule:"evenodd",clipPath:"url(#download_svg__a)",clipRule:"evenodd",children:[g.jsx("path",{d:"M7.293 16.293a1 1 0 0 1 1.414 0L12 19.586l3.293-3.293a1 1 0 0 1 1.414 1.414l-4 4a1 1 0 0 1-1.414 0l-4-4a1 1 0 0 1 0-1.414"}),g.jsx("path",{d:"M12 11a1 1 0 0 1 1 1v9a1 1 0 1 1-2 0v-9a1 1 0 0 1 1-1"}),g.jsx("path",{d:"M8.668 1.994A9 9 0 0 1 17.48 8H18a6.002 6.002 0 0 1 5.689 7.919 6 6 0 0 1-2.234 2.989 1 1 0 1 1-1.15-1.636A4 4 0 0 0 18 10H16.74a1 1 0 0 1-.969-.751A7 7 0 1 0 3.75 15.627a1 1 0 1 1-1.498 1.326A9 9 0 0 1 8.668 1.994"})]}),g.jsx("defs",{children:g.jsx("clipPath",{id:"download_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),W$=G$,X$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M1.879 3.879A3 3 0 0 1 4 3h7a1 1 0 1 1 0 2H4a1 1 0 0 0-1 1v14a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1v-7a1 1 0 1 1 2 0v7a3 3 0 0 1-3 3H4a3 3 0 0 1-3-3V6a3 3 0 0 1 .879-2.121",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M20 2.879c-.297 0-.583.118-.793.328l-9.304 9.304-.529 2.115 2.115-.529 9.304-9.304A1.121 1.121 0 0 0 20 2.879m-2.207-1.086a3.121 3.121 0 0 1 4.414 4.414l-9.5 9.5a1 1 0 0 1-.464.263l-4 1a1 1 0 0 1-1.213-1.212l1-4a1 1 0 0 1 .263-.465z",clipRule:"evenodd"})]}),q$=X$,Y$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M3 12a9 9 0 1 1 18 0 9 9 0 0 1-18 0m9-11C5.925 1 1 5.925 1 12s4.925 11 11 11 11-4.925 11-11S18.075 1 12 1M8.293 15.707a1 1 0 0 1 0-1.414L10.586 12 8.293 9.707a1 1 0 0 1 1.414-1.414L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414 0",clipRule:"evenodd"})]}),Q$=Y$,K$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M20.91 9.14v1.27H8.25a4.7 4.7 0 0 0-3.86 1.98L1.5 16.53V6.4a2.3 2.3 0 0 1 .77-1.69A2.68 2.68 0 0 1 4.11 4h3.73a2.68 2.68 0 0 1 1.84.71c.25.22.45.48.58.77s.2.6.2.92v.34h7.84c.7.01 1.35.27 1.84.71.49.45.76 1.06.77 1.7ZM8.25 11.92h14.47c.63 0 1 .68.64 1.18l-3.52 5.04a3.13 3.13 0 0 1-2.57 1.32H2.79c-.62 0-.99-.68-.64-1.18l3.53-5.04a3.13 3.13 0 0 1 2.57-1.32",clipRule:"evenodd"})]}),FN=K$,Z$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M1.093 2.58A1 1 0 0 1 2 2h20a1 1 0 0 1 .764 1.646L15 12.826V21a1 1 0 0 1-1.447.894l-4-2A1 1 0 0 1 9 19v-6.174l-7.764-9.18a1 1 0 0 1-.143-1.067M4.155 4l6.609 7.814a1 1 0 0 1 .236.646v5.922l2 1V12.46a1 1 0 0 1 .236-.646L19.845 4z",clipRule:"evenodd"})]}),J$=Z$,ez=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M3.057 5.5A.057.057 0 0 0 3 5.557v13.03h18V7.875h-8.697a1 1 0 0 1-1-1c0-.759-.615-1.374-1.374-1.374zM1 5.557C1 4.42 1.92 3.5 3.057 3.5h6.872c1.515 0 2.797.999 3.223 2.374H21a2 2 0 0 1 2 2v10.714a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2z",clipRule:"evenodd"})]}),jN=ez,tz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M9.726 3.29A9.01 9.01 0 0 0 3.055 11H7.05a16.3 16.3 0 0 1 2.676-7.71m4.548 0A16.3 16.3 0 0 1 16.95 11h3.995a9.01 9.01 0 0 0-6.67-7.71m.668 7.71A14.3 14.3 0 0 0 12 3.55 14.3 14.3 0 0 0 9.058 11zm-5.884 2h5.884A14.3 14.3 0 0 1 12 20.45 14.3 14.3 0 0 1 9.058 13M7.05 13H3.055a9.01 9.01 0 0 0 6.67 7.71A16.3 16.3 0 0 1 7.05 13m7.224 7.71A16.3 16.3 0 0 0 16.95 13h3.995a9.01 9.01 0 0 1-6.67 7.71M12 23c6.075 0 11-4.925 11-11S18.075 1 12 1 1 5.925 1 12s4.925 11 11 11",clipRule:"evenodd"})]}),LT=tz,rz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18M1 12C1 5.925 5.925 1 12 1s11 4.925 11 11-4.925 11-11 11S1 18.075 1 12",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12.01 17a1 1 0 0 1-1-1v-5a1 1 0 1 1 2 0v5a1 1 0 0 1-1 1M13.01 7.5a1 1 0 0 1-1 1H12a1 1 0 1 1 0-2h.01a1 1 0 0 1 1 1",clipRule:"evenodd"})]}),BN=rz,nz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4.222 5.037c-.895 0-1.222.555-1.222.792v12.675c0 .237.327.792 1.222.792h1.364l9.707-9.886a.987.987 0 0 1 1.414 0L21 13.782V5.829c0-.237-.328-.792-1.222-.792zM23 16.224V5.829C23 4.066 21.337 3 19.778 3H4.222C2.662 3 1 4.066 1 5.83v12.674c0 1.763 1.662 2.829 3.222 2.829h15.556c1.56 0 3.222-1.066 3.222-2.83v-2.279m-2 .439-5-5.093-7.585 7.726h11.363c.894 0 1.222-.555 1.222-.792zM8 8.093c-.552 0-1 .455-1 1.018a1.01 1.01 0 0 0 1 1.018c.552 0 1-.456 1-1.018a1.01 1.01 0 0 0-1-1.019M5 9.11c0-1.688 1.343-3.056 3-3.056s3 1.368 3 3.056-1.343 3.055-3 3.055-3-1.368-3-3.055",clipRule:"evenodd"})]}),iz=nz,sz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M16.672 5.558a7.96 7.96 0 0 0-9.841.397 7.95 7.95 0 0 0-1.908 9.66 7.964 7.964 0 0 0 8.949 4.12A7.95 7.95 0 0 0 19.962 12a1.021 1.021 0 1 1 2.045 0A9.994 9.994 0 0 1 7.83 21.083a10.01 10.01 0 0 1-5.634-11.027 9.99 9.99 0 0 1 9.402-8.048c2.244-.09 4.453.577 6.272 1.895a1.022 1.022 0 1 1-1.198 1.655",clipRule:"evenodd"})]}),UN=sz,oz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 .5a4.07 4.07 0 0 0-2.812 1.115A3.8 3.8 0 0 0 8 4.364V12a3.8 3.8 0 0 0 1.188 2.748A4.07 4.07 0 0 0 12 15.864a4.07 4.07 0 0 0 2.812-1.116A3.8 3.8 0 0 0 16 12V4.364a3.8 3.8 0 0 0-1.188-2.749A4.07 4.07 0 0 0 12 .5m-1.43 2.562A2.07 2.07 0 0 1 12 2.5c.545 0 1.059.207 1.43.562.371.354.57.823.57 1.302V12a1.8 1.8 0 0 1-.57 1.302 2.07 2.07 0 0 1-1.43.562 2.07 2.07 0 0 1-1.43-.562A1.8 1.8 0 0 1 10 12V4.364a1.8 1.8 0 0 1 .57-1.302M6 10.091a1 1 0 0 0-2 0V12c0 2.053.855 4.011 2.36 5.448A8.13 8.13 0 0 0 11 19.622V21.5H8a1 1 0 1 0 0 2h8a1 1 0 1 0 0-2h-3v-1.878a8.13 8.13 0 0 0 4.64-2.174C19.145 16.011 20 14.053 20 12v-1.91a1 1 0 0 0-2 0V12c0 1.491-.62 2.932-1.74 4.001s-2.646 1.678-4.248 1.68h-.024c-1.602-.002-3.128-.611-4.247-1.68C6.62 14.931 6 13.491 6 12z",clipRule:"evenodd"})]}),c1=oz,az=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("circle",{cx:12,cy:4,r:2.5,fill:"currentColor"}),g.jsx("circle",{cx:12,cy:12,r:2.5,fill:"currentColor"}),g.jsx("circle",{cx:12,cy:20,r:2.5,fill:"currentColor"})]}),lz=az,uz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M15.968 3c-.775 0-1.517.306-2.062.847l-8.983 8.918a4.8 4.8 0 0 0-1.423 3.41c0 1.277.511 2.504 1.423 3.41A4.9 4.9 0 0 0 8.368 21a4.9 4.9 0 0 0 3.445-1.416l8.983-8.918a1 1 0 1 1 1.409 1.42l-8.983 8.917A6.9 6.9 0 0 1 8.368 23a6.9 6.9 0 0 1-4.854-1.997A6.8 6.8 0 0 1 1.5 16.174c0-1.812.725-3.549 2.014-4.828l8.983-8.918A4.93 4.93 0 0 1 15.967 1c1.301 0 2.55.513 3.471 1.428a4.87 4.87 0 0 1 1.442 3.456 4.87 4.87 0 0 1-1.442 3.455l-8.992 8.918a2.965 2.965 0 0 1-4.175 0 2.935 2.935 0 0 1 0-4.165l8.299-8.23a1 1 0 0 1 1.408 1.42l-8.298 8.23a.935.935 0 0 0 0 1.326.963.963 0 0 0 1.357 0l8.992-8.918c.545-.541.85-1.274.85-2.036a2.87 2.87 0 0 0-.85-2.037A2.93 2.93 0 0 0 15.968 3",clipRule:"evenodd"})]}),cz=uz,dz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M5.5 2a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h3a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2zm0 2h3v16h-3zm10-2a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h3a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2zm0 2h3v16h-3z",clipRule:"evenodd"})]}),FT=dz,hz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",d:"M5 3.804c0-1.57 1.728-2.528 3.06-1.696l13.113 8.196a2 2 0 0 1 0 3.392L8.06 21.892C6.728 22.724 5 21.767 5 20.196z"})]}),$N=hz,fz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M13 4a1 1 0 1 0-2 0v7H4a1 1 0 1 0 0 2h7v7a1 1 0 1 0 2 0v-7h7a1 1 0 1 0 0-2h-7z",clipRule:"evenodd"})]}),d1=fz,pz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4.012 7.871a1.5 1.5 0 0 1 2.117.141L12 14.722l5.871-6.71a1.5 1.5 0 1 1 2.258 1.976l-7 8a1.5 1.5 0 0 1-2.258 0l-7-8a1.5 1.5 0 0 1 .141-2.117",clipRule:"evenodd"})]}),Tp=pz,mz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7.871 19.988a1.5 1.5 0 0 1 .141-2.117L14.722 12l-6.71-5.871A1.5 1.5 0 0 1 9.988 3.87l8 7a1.5 1.5 0 0 1 0 2.258l-8 7a1.5 1.5 0 0 1-2.117-.141",clipRule:"evenodd"})]}),zN=mz,gz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M19.988 17.129a1.5 1.5 0 0 1-2.117-.141L12 10.278l-5.871 6.71a1.5 1.5 0 0 1-2.258-1.976l7-8a1.5 1.5 0 0 1 2.258 0l7 8a1.5 1.5 0 0 1-.141 2.117",clipRule:"evenodd"})]}),vz=gz,yz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M23 12c0 6.075-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1s11 4.925 11 11M10 6H8a1 1 0 0 0-1 1v10a1 1 0 0 0 1 1h2a1 1 0 0 0 1-1V7a1 1 0 0 0-1-1m4 0h2a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1h-2a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1",clipRule:"evenodd"})]}),xz=yz,bz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",d:"M2 6a4 4 0 0 1 4-4h12a4 4 0 0 1 4 4v12a4 4 0 0 1-4 4H6a4 4 0 0 1-4-4z"})]}),wz=bz,_z=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M2 4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h13a2 2 0 0 0 2-2v-1.936l4.409 1.365A2 2 0 0 0 24 15.519V8.48a2 2 0 0 0-2.591-1.91l-4.41 1.364V6a2 2 0 0 0-2-2zm0 2h13v12H2zm15 7.97V10.03l5-1.548v7.037z",clipRule:"evenodd"})]}),HN=_z,Sz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("circle",{cx:12,cy:12,r:11,fill:"currentColor"})]}),Zv=Sz,Ez=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("g",{clipPath:"url(#refresh_svg__a)",children:g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12.304 21c3.015 0 5.65-1.924 6.838-4.752a.986.986 0 0 1 1.297-.53c.503.216.738.803.524 1.311C19.498 20.522 16.19 23 12.304 23c-4.644 0-8.444-3.522-9.299-8.113L1.86 17.142a.99.99 0 0 1-1.33.449 1 1 0 0 1-.417-1.348L2.51 11.52c.135-.265.376-.457.66-.527a.96.96 0 0 1 .812.169L8.1 14.297c.433.33.515.958.185 1.404a.98.98 0 0 1-1.382.212L4.93 14.41c.65 3.785 3.744 6.59 7.374 6.59m4.794-12.913a.98.98 0 0 0-1.381.211 1.01 1.01 0 0 0 .184 1.405l4.117 3.135a.96.96 0 0 0 .812.169c.284-.07.525-.262.66-.527l2.398-4.723c.252-.496.065-1.1-.418-1.348a.99.99 0 0 0-1.329.449l-1.145 2.255C20.14 4.522 16.34 1 11.696 1 7.81 1 4.505 3.478 3.037 6.97a1.004 1.004 0 0 0 .525 1.312.986.986 0 0 0 1.297-.53C6.046 4.924 8.681 3 11.697 3c3.63 0 6.724 2.805 7.374 6.59z",clipRule:"evenodd"})}),g.jsx("defs",{children:g.jsx("clipPath",{id:"refresh_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),VN=Ez,Tz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4.583 7.313 3.976 3.87a.996.996 0 1 0-1.96.346l1.012 5.747a.996.996 0 0 0 1.153.809l5.743-1.014a.997.997 0 0 0-.346-1.962l-3.3.582a7.754 7.754 0 0 1 8.399-4.254 7.76 7.76 0 0 1 .78 15.064 7.745 7.745 0 0 1-8.912-3.56.995.995 0 1 0-1.724.997 9.744 9.744 0 0 0 11.201 4.474 9.74 9.74 0 0 0 5.19-3.718 9.756 9.756 0 0 0-.625-12.055A9.74 9.74 0 0 0 8.73 3.117a9.75 9.75 0 0 0-4.147 4.196",clipRule:"evenodd"})]}),GN=Tz,Cz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",d:"M17.919 3.15c1.33-.856 3.081.1 3.081 1.682v14.336c0 1.583-1.75 2.538-3.081 1.683L7 13.83V19a2 2 0 1 1-4 0V5a2 2 0 1 1 4 0v5.168z"})]}),Az=Cz,Rz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M5 4a1 1 0 0 0-1 1v14a1 1 0 0 0 1 1h1v-7a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v7h1a1 1 0 0 0 1-1V8.414L15.586 4H8v3h7a1 1 0 1 1 0 2H7a1 1 0 0 1-1-1V4zm2-2H5a3 3 0 0 0-3 3v14a3 3 0 0 0 3 3h14a3 3 0 0 0 3-3V8a1 1 0 0 0-.293-.707l-5-5A1 1 0 0 0 16 2zm1 12v6h8v-6z",clipRule:"evenodd"})]}),jT=Rz,Pz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 10a7 7 0 1 1 14 0 7 7 0 0 1-14 0m7-9a9 9 0 1 0 5.7 15.96 1 1 0 0 0 .24.4l4.35 4.35a1 1 0 0 0 1.42-1.42l-4.35-4.35a1 1 0 0 0-.4-.24A9 9 0 0 0 11 1",clipRule:"evenodd"})]}),AS=Pz,Iz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7 3a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h10a1 1 0 0 0 1-1V4a1 1 0 0 0-1-1zM4 4a3 3 0 0 1 3-3h10a3 3 0 0 1 3 3v16a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3z",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M11 18a1 1 0 0 1 1-1h.01a1 1 0 1 1 0 2H12a1 1 0 0 1-1-1",clipRule:"evenodd"})]}),Mz=Iz,kz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M16.133 6.173c-.026.023-.133.118-.133.541v.715h2v-.715c0-.423-.107-.518-.133-.541C17.805 6.12 17.594 6 17 6s-.805.12-.867.173M20 6.714c0-.76-.203-1.521-.832-2.06C18.575 4.145 17.786 4 17 4s-1.575.145-2.168.654c-.629.539-.832 1.3-.832 2.06V11a1 1 0 1 0 2 0V9.429h2V11a1 1 0 1 0 2 0zM14 14a1 1 0 0 1 1-1h4a1 1 0 0 1 .832 1.555L16.87 19H19a1 1 0 1 1 0 2h-4a1 1 0 0 1-.832-1.555L17.132 15H15a1 1 0 0 1-1-1M3.293 16.293a1 1 0 0 1 1.414 0L7 18.586l2.293-2.293a1 1 0 0 1 1.414 1.414l-3 3a1 1 0 0 1-1.414 0l-3-3a1 1 0 0 1 0-1.414",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7 4a1 1 0 0 1 1 1v15a1 1 0 1 1-2 0V5a1 1 0 0 1 1-1",clipRule:"evenodd"})]}),Oz=kz,Dz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M16.133 6.173c-.026.023-.133.118-.133.541v.715h2v-.715c0-.423-.107-.518-.133-.541C17.805 6.12 17.594 6 17 6s-.805.12-.867.173M20 6.714c0-.76-.203-1.521-.832-2.06C18.575 4.145 17.786 4 17 4s-1.575.145-2.168.654c-.629.539-.832 1.3-.832 2.06V11a1 1 0 1 0 2 0V9.429h2V11a1 1 0 1 0 2 0zM14 14a1 1 0 0 1 1-1h4a1 1 0 0 1 .832 1.555L16.87 19H19a1 1 0 1 1 0 2h-4a1 1 0 0 1-.832-1.555L17.132 15H15a1 1 0 0 1-1-1M3.293 8.707a1 1 0 0 0 1.414 0L7 6.414l2.293 2.293a1 1 0 0 0 1.414-1.414l-3-3a1 1 0 0 0-1.414 0l-3 3a1 1 0 0 0 0 1.414",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7 21a1 1 0 0 0 1-1V5a1 1 0 0 0-2 0v15a1 1 0 0 0 1 1",clipRule:"evenodd"})]}),Nz=Dz,Lz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M13.509 6.027a6.138 6.138 0 1 1-.28 12.099 1 1 0 1 0-.383 1.963A8.138 8.138 0 1 0 9.653 5.488a1 1 0 1 0 1.168 1.624 6.1 6.1 0 0 1 2.688-1.085",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M14.38 8.252a1 1 0 0 0-1 1v3.8a1 1 0 0 0 .456.838l2.052 1.332a1 1 0 0 0 1.089-1.678l-1.597-1.036V9.252a1 1 0 0 0-1-1M1.793 16.293a1 1 0 0 1 1.414 0L5.5 18.586l2.293-2.293a1 1 0 0 1 1.414 1.414l-3 3a1 1 0 0 1-1.414 0l-3-3a1 1 0 0 1 0-1.414",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M5.5 4a1 1 0 0 0-1 1v15a1 1 0 1 0 2 0V5a1 1 0 0 0-1-1",clipRule:"evenodd"})]}),Fz=Lz,jz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18M1 12C1 5.925 5.925 1 12 1s11 4.925 11 11-4.925 11-11 11S1 18.075 1 12",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M16.59 8.192a1 1 0 0 1 .218 1.397l-4.375 6a1 1 0 0 1-1.584.042L8.224 12.4a1 1 0 0 1 1.552-1.261l1.806 2.223 3.61-4.951a1 1 0 0 1 1.397-.219",clipRule:"evenodd"})]}),WN=jz,Bz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M6.286 3c-.35 0-.68.135-.92.368-.238.231-.366.54-.366.854v15.556c0 .315.128.623.367.854.239.233.569.368.919.368h11.428c.35 0 .68-.135.92-.368.238-.231.366-.54.366-.854V8h-3a2 2 0 0 1-2-2V3zM16 6h1.986L16 4.08zm5 13.778V6.556a1 1 0 0 0-.305-.72L15.98 1.281A1 1 0 0 0 15.286 1h-9a3.32 3.32 0 0 0-2.314.934A3.2 3.2 0 0 0 3 4.222v15.556c0 .864.353 1.686.972 2.288S5.423 23 6.286 23h11.428c.863 0 1.695-.333 2.314-.934.619-.602.972-1.424.972-2.288M8 6a1 1 0 0 0 0 2h3a1 1 0 1 0 0-2zm-1 6a1 1 0 0 1 1-1h8a1 1 0 1 1 0 2H8a1 1 0 0 1-1-1m5 4a1 1 0 1 0 0 2h4a1 1 0 1 0 0-2z",clipRule:"evenodd"})]}),Uz=Bz,$z=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M9.707 13.707a1 1 0 0 0 0-1.414L5.414 8l4.293-4.293a1 1 0 0 0-1.414-1.414l-5 5a1 1 0 0 0 0 1.414l5 5a1 1 0 0 0 1.414 0",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M20 20a1 1 0 0 0 1-1v-7a5 5 0 0 0-5-5H4a1 1 0 1 0 0 2h12a3 3 0 0 1 3 3v7a1 1 0 0 0 1 1",clipRule:"evenodd"})]}),zz=$z,Hz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("g",{fill:"currentColor",fillRule:"evenodd",clipPath:"url(#users_svg__a)",clipRule:"evenodd",children:g.jsx("path",{d:"M19.055 12.803a1 1 0 0 1 1.272-.618c1.128.39 2.061 1.247 2.7 2.351.64 1.106.972 2.435.973 3.782V21a1 1 0 1 1-2 0v-2.681c0-1.03-.258-2.009-.704-2.782-.448-.773-1.034-1.258-1.623-1.462a1 1 0 0 1-.618-1.272M15.187 1.384a1 1 0 0 1 1.036-.962 5.129 5.129 0 0 1 2.11 9.71 1 1 0 1 1-.896-1.788 3.129 3.129 0 0 0-1.288-5.924 1 1 0 0 1-.962-1.036M1.505 15.694C2.481 14.622 3.825 14 5.25 14h8.5c1.424 0 2.769.622 3.744 1.694.974 1.068 1.506 2.498 1.506 3.973V22a1 1 0 1 1-2 0v-2.333c0-1.001-.363-1.945-.984-2.627-.618-.679-1.436-1.04-2.266-1.04h-8.5c-.83 0-1.648.361-2.266 1.04-.621.682-.984 1.626-.984 2.627V22a1 1 0 1 1-2 0v-2.333c0-1.475.533-2.905 1.505-3.974M9.5 3a3.5 3.5 0 1 0 0 7 3.5 3.5 0 0 0 0-7M4 6.5a5.5 5.5 0 1 1 11 0 5.5 5.5 0 0 1-11 0"})}),g.jsx("defs",{children:g.jsx("clipPath",{id:"users_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),BT=Hz,Vz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 4.962C4 4.376 4.435 4 4.853 4H6.5v2H4zM4 8h2.5v3H4zm-2 4V4.962C2 3.381 3.224 2 4.853 2h13.294C19.776 2 21 3.38 21 4.962v14.076C21 20.619 19.776 22 18.147 22H4.853C3.224 22 2 20.62 2 19.038zm17-6V4.962c0-.586-.435-.962-.853-.962H16.5v2zm0 2h-2.5v3H19zm-2.5 5H19v3h-2.5zm0 5H19v1.038c0 .586-.435.962-.853.962H16.5zm-2-7V4h-6v7zm-6 2h6v7h-6zm-2 5v2H4.853C4.435 20 4 19.624 4 19.038V18zm0-2v-3H4v3z",clipRule:"evenodd"})]}),Gz=Vz,Wz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M10 0a1 1 0 0 1 1 1 1 1 0 0 0 1 1 1 1 0 1 1 0 2 1 1 0 0 0-1 1 1 1 0 1 1-2 0 1 1 0 0 0-1-1 1 1 0 0 1 0-2 1 1 0 0 0 1-1 1 1 0 0 1 1-1m9.914 2a2 2 0 0 0-2.828 0L1 18.086a2 2 0 0 0 0 2.828L3.086 23a2 2 0 0 0 2.828 0L22 6.914a2 2 0 0 0 0-2.828zm-3.75 3.75L18.5 3.414 20.586 5.5 18.25 7.836zM14.75 7.164 2.414 19.5 4.5 21.586 16.836 9.25zM21 13a1 1 0 1 0-2 0 1 1 0 0 1-1 1 1 1 0 1 0 0 2 1 1 0 0 1 1 1 1 1 0 1 0 2 0 1 1 0 0 1 1-1 1 1 0 1 0 0-2 1 1 0 0 1-1-1",clipRule:"evenodd"})]}),Xz=Wz;function XN(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function Pu(t){return t instanceof Element||t instanceof XN(t).Element}function qz(t){return typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof XN(t).ShadowRoot}function Q0(t,e){if(!t||!e)return!1;const r=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(r&&qz(r)){let n=e;for(;n;){if(t===n)return!0;n=n.parentNode||n.host}}return!1}function qN(t,e){const r=["mouse","pen"];return r.push("",void 0),r.includes(t)}function $g(t){return(t==null?void 0:t.ownerDocument)||document}function Yz(t){return"composedPath"in t?t.composedPath()[0]:t.target}const Cp=Math.min,Li=Math.max,Jv=Math.round,zg=Math.floor,go=t=>({x:t,y:t}),Qz={left:"right",right:"left",bottom:"top",top:"bottom"},Kz={start:"end",end:"start"};function h1(t,e){return typeof t=="function"?t(e):t}function Zu(t){return t.split("-")[0]}function lm(t){return t.split("-")[1]}function Zz(t){return t==="x"?"y":"x"}function YN(t){return t==="y"?"height":"width"}function Kd(t){return["top","bottom"].includes(Zu(t))?"y":"x"}function QN(t){return Zz(Kd(t))}function Jz(t,e,r){r===void 0&&(r=!1);const n=lm(t),i=QN(t),s=YN(i);let o=i==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return e.reference[s]>e.floating[s]&&(o=ey(o)),[o,ey(o)]}function eH(t){const e=ey(t);return[RS(t),e,RS(e)]}function RS(t){return t.replace(/start|end/g,e=>Kz[e])}function tH(t,e,r){const n=["left","right"],i=["right","left"],s=["top","bottom"],o=["bottom","top"];switch(t){case"top":case"bottom":return r?e?i:n:e?n:i;case"left":case"right":return e?s:o;default:return[]}}function rH(t,e,r,n){const i=lm(t);let s=tH(Zu(t),r==="start",n);return i&&(s=s.map(o=>o+"-"+i),e&&(s=s.concat(s.map(RS)))),s}function ey(t){return t.replace(/left|right|bottom|top/g,e=>Qz[e])}function nH(t){return{top:0,right:0,bottom:0,left:0,...t}}function iH(t){return typeof t!="number"?nH(t):{top:t,right:t,bottom:t,left:t}}function ty(t){const{x:e,y:r,width:n,height:i}=t;return{width:n,height:i,top:r,left:e,right:e+n,bottom:r+i,x:e,y:r}}function UI(t,e,r){let{reference:n,floating:i}=t;const s=Kd(e),o=QN(e),a=YN(o),l=Zu(e),u=s==="y",c=n.x+n.width/2-i.width/2,h=n.y+n.height/2-i.height/2,f=n[a]/2-i[a]/2;let m;switch(l){case"top":m={x:c,y:n.y-i.height};break;case"bottom":m={x:c,y:n.y+n.height};break;case"right":m={x:n.x+n.width,y:h};break;case"left":m={x:n.x-i.width,y:h};break;default:m={x:n.x,y:n.y}}switch(lm(e)){case"start":m[o]-=f*(r&&u?-1:1);break;case"end":m[o]+=f*(r&&u?-1:1);break}return m}const sH=async(t,e,r)=>{const{placement:n="bottom",strategy:i="absolute",middleware:s=[],platform:o}=r,a=s.filter(Boolean),l=await(o.isRTL==null?void 0:o.isRTL(e));let u=await o.getElementRects({reference:t,floating:e,strategy:i}),{x:c,y:h}=UI(u,n,l),f=n,m={},y=0;for(let v=0;v<a.length;v++){const{name:x,fn:b}=a[v],{x:_,y:w,data:E,reset:A}=await b({x:c,y:h,initialPlacement:n,placement:f,strategy:i,middlewareData:m,rects:u,platform:o,elements:{reference:t,floating:e}});c=_??c,h=w??h,m={...m,[x]:{...m[x],...E}},A&&y<=50&&(y++,typeof A=="object"&&(A.placement&&(f=A.placement),A.rects&&(u=A.rects===!0?await o.getElementRects({reference:t,floating:e,strategy:i}):A.rects),{x:c,y:h}=UI(u,f,l)),v=-1)}return{x:c,y:h,placement:f,strategy:i,middlewareData:m}};async function KN(t,e){var r;e===void 0&&(e={});const{x:n,y:i,platform:s,rects:o,elements:a,strategy:l}=t,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:h="floating",altBoundary:f=!1,padding:m=0}=h1(e,t),y=iH(m),x=a[f?h==="floating"?"reference":"floating":h],b=ty(await s.getClippingRect({element:(r=await(s.isElement==null?void 0:s.isElement(x)))==null||r?x:x.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:u,rootBoundary:c,strategy:l})),_=h==="floating"?{x:n,y:i,width:o.floating.width,height:o.floating.height}:o.reference,w=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),E=await(s.isElement==null?void 0:s.isElement(w))?await(s.getScale==null?void 0:s.getScale(w))||{x:1,y:1}:{x:1,y:1},A=ty(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:_,offsetParent:w,strategy:l}):_);return{top:(b.top-A.top+y.top)/E.y,bottom:(A.bottom-b.bottom+y.bottom)/E.y,left:(b.left-A.left+y.left)/E.x,right:(A.right-b.right+y.right)/E.x}}const oH=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var r,n;const{placement:i,middlewareData:s,rects:o,initialPlacement:a,platform:l,elements:u}=e,{mainAxis:c=!0,crossAxis:h=!0,fallbackPlacements:f,fallbackStrategy:m="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:v=!0,...x}=h1(t,e);if((r=s.arrow)!=null&&r.alignmentOffset)return{};const b=Zu(i),_=Kd(a),w=Zu(a)===a,E=await(l.isRTL==null?void 0:l.isRTL(u.floating)),A=f||(w||!v?[ey(a)]:eH(a)),P=y!=="none";!f&&P&&A.push(...rH(a,v,y,E));const I=[a,...A],M=await KN(e,x),N=[];let z=((n=s.flip)==null?void 0:n.overflows)||[];if(c&&N.push(M[b]),h){const L=Jz(i,o,E);N.push(M[L[0]],M[L[1]])}if(z=[...z,{placement:i,overflows:N}],!N.every(L=>L<=0)){var j,H;const L=(((j=s.flip)==null?void 0:j.index)||0)+1,O=I[L];if(O)return{data:{index:L,overflows:z},reset:{placement:O}};let $=(H=z.filter(V=>V.overflows[0]<=0).sort((V,k)=>V.overflows[1]-k.overflows[1])[0])==null?void 0:H.placement;if(!$)switch(m){case"bestFit":{var F;const V=(F=z.filter(k=>{if(P){const U=Kd(k.placement);return U===_||U==="y"}return!0}).map(k=>[k.placement,k.overflows.filter(U=>U>0).reduce((U,B)=>U+B,0)]).sort((k,U)=>k[1]-U[1])[0])==null?void 0:F[0];V&&($=V);break}case"initialPlacement":$=a;break}if(i!==$)return{reset:{placement:$}}}return{}}}};async function aH(t,e){const{placement:r,platform:n,elements:i}=t,s=await(n.isRTL==null?void 0:n.isRTL(i.floating)),o=Zu(r),a=lm(r),l=Kd(r)==="y",u=["left","top"].includes(o)?-1:1,c=s&&l?-1:1,h=h1(e,t);let{mainAxis:f,crossAxis:m,alignmentAxis:y}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:h.mainAxis||0,crossAxis:h.crossAxis||0,alignmentAxis:h.alignmentAxis};return a&&typeof y=="number"&&(m=a==="end"?y*-1:y),l?{x:m*c,y:f*u}:{x:f*u,y:m*c}}const lH=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var r,n;const{x:i,y:s,placement:o,middlewareData:a}=e,l=await aH(e,t);return o===((r=a.offset)==null?void 0:r.placement)&&(n=a.arrow)!=null&&n.alignmentOffset?{}:{x:i+l.x,y:s+l.y,data:{...l,placement:o}}}}},uH=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var r,n;const{placement:i,rects:s,platform:o,elements:a}=e,{apply:l=()=>{},...u}=h1(t,e),c=await KN(e,u),h=Zu(i),f=lm(i),m=Kd(i)==="y",{width:y,height:v}=s.floating;let x,b;h==="top"||h==="bottom"?(x=h,b=f===(await(o.isRTL==null?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(b=h,x=f==="end"?"top":"bottom");const _=v-c.top-c.bottom,w=y-c.left-c.right,E=Cp(v-c[x],_),A=Cp(y-c[b],w),P=!e.middlewareData.shift;let I=E,M=A;if((r=e.middlewareData.shift)!=null&&r.enabled.x&&(M=w),(n=e.middlewareData.shift)!=null&&n.enabled.y&&(I=_),P&&!f){const z=Li(c.left,0),j=Li(c.right,0),H=Li(c.top,0),F=Li(c.bottom,0);m?M=y-2*(z!==0||j!==0?z+j:Li(c.left,c.right)):I=v-2*(H!==0||F!==0?H+F:Li(c.top,c.bottom))}await l({...e,availableWidth:M,availableHeight:I});const N=await o.getDimensions(a.floating);return y!==N.width||v!==N.height?{reset:{rects:!0}}:{}}}};function f1(){return typeof window<"u"}function hh(t){return ZN(t)?(t.nodeName||"").toLowerCase():"#document"}function fi(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function Io(t){var e;return(e=(ZN(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function ZN(t){return f1()?t instanceof Node||t instanceof fi(t).Node:!1}function As(t){return f1()?t instanceof Element||t instanceof fi(t).Element:!1}function bo(t){return f1()?t instanceof HTMLElement||t instanceof fi(t).HTMLElement:!1}function $I(t){return!f1()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof fi(t).ShadowRoot}function um(t){const{overflow:e,overflowX:r,overflowY:n,display:i}=Rs(t);return/auto|scroll|overlay|hidden|clip/.test(e+n+r)&&!["inline","contents"].includes(i)}function cH(t){return["table","td","th"].includes(hh(t))}function p1(t){return[":popover-open",":modal"].some(e=>{try{return t.matches(e)}catch{return!1}})}function UT(t){const e=$T(),r=As(t)?Rs(t):t;return r.transform!=="none"||r.perspective!=="none"||(r.containerType?r.containerType!=="normal":!1)||!e&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!e&&(r.filter?r.filter!=="none":!1)||["transform","perspective","filter"].some(n=>(r.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(r.contain||"").includes(n))}function dH(t){let e=Pl(t);for(;bo(e)&&!Zd(e);){if(UT(e))return e;if(p1(e))return null;e=Pl(e)}return null}function $T(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Zd(t){return["html","body","#document"].includes(hh(t))}function Rs(t){return fi(t).getComputedStyle(t)}function m1(t){return As(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function Pl(t){if(hh(t)==="html")return t;const e=t.assignedSlot||t.parentNode||$I(t)&&t.host||Io(t);return $I(e)?e.host:e}function JN(t){const e=Pl(t);return Zd(e)?t.ownerDocument?t.ownerDocument.body:t.body:bo(e)&&um(e)?e:JN(e)}function Ap(t,e,r){var n;e===void 0&&(e=[]),r===void 0&&(r=!0);const i=JN(t),s=i===((n=t.ownerDocument)==null?void 0:n.body),o=fi(i);if(s){const a=PS(o);return e.concat(o,o.visualViewport||[],um(i)?i:[],a&&r?Ap(a):[])}return e.concat(i,Ap(i,[],r))}function PS(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function eL(t){const e=Rs(t);let r=parseFloat(e.width)||0,n=parseFloat(e.height)||0;const i=bo(t),s=i?t.offsetWidth:r,o=i?t.offsetHeight:n,a=Jv(r)!==s||Jv(n)!==o;return a&&(r=s,n=o),{width:r,height:n,$:a}}function zT(t){return As(t)?t:t.contextElement}function yd(t){const e=zT(t);if(!bo(e))return go(1);const r=e.getBoundingClientRect(),{width:n,height:i,$:s}=eL(e);let o=(s?Jv(r.width):r.width)/n,a=(s?Jv(r.height):r.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!a||!Number.isFinite(a))&&(a=1),{x:o,y:a}}const hH=go(0);function tL(t){const e=fi(t);return!$T()||!e.visualViewport?hH:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function fH(t,e,r){return e===void 0&&(e=!1),!r||e&&r!==fi(t)?!1:e}function Ju(t,e,r,n){e===void 0&&(e=!1),r===void 0&&(r=!1);const i=t.getBoundingClientRect(),s=zT(t);let o=go(1);e&&(n?As(n)&&(o=yd(n)):o=yd(t));const a=fH(s,r,n)?tL(s):go(0);let l=(i.left+a.x)/o.x,u=(i.top+a.y)/o.y,c=i.width/o.x,h=i.height/o.y;if(s){const f=fi(s),m=n&&As(n)?fi(n):n;let y=f,v=PS(y);for(;v&&n&&m!==y;){const x=yd(v),b=v.getBoundingClientRect(),_=Rs(v),w=b.left+(v.clientLeft+parseFloat(_.paddingLeft))*x.x,E=b.top+(v.clientTop+parseFloat(_.paddingTop))*x.y;l*=x.x,u*=x.y,c*=x.x,h*=x.y,l+=w,u+=E,y=fi(v),v=PS(y)}}return ty({width:c,height:h,x:l,y:u})}function HT(t,e){const r=m1(t).scrollLeft;return e?e.left+r:Ju(Io(t)).left+r}function rL(t,e,r){r===void 0&&(r=!1);const n=t.getBoundingClientRect(),i=n.left+e.scrollLeft-(r?0:HT(t,n)),s=n.top+e.scrollTop;return{x:i,y:s}}function pH(t){let{elements:e,rect:r,offsetParent:n,strategy:i}=t;const s=i==="fixed",o=Io(n),a=e?p1(e.floating):!1;if(n===o||a&&s)return r;let l={scrollLeft:0,scrollTop:0},u=go(1);const c=go(0),h=bo(n);if((h||!h&&!s)&&((hh(n)!=="body"||um(o))&&(l=m1(n)),bo(n))){const m=Ju(n);u=yd(n),c.x=m.x+n.clientLeft,c.y=m.y+n.clientTop}const f=o&&!h&&!s?rL(o,l,!0):go(0);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}}function mH(t){return Array.from(t.getClientRects())}function gH(t){const e=Io(t),r=m1(t),n=t.ownerDocument.body,i=Li(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),s=Li(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight);let o=-r.scrollLeft+HT(t);const a=-r.scrollTop;return Rs(n).direction==="rtl"&&(o+=Li(e.clientWidth,n.clientWidth)-i),{width:i,height:s,x:o,y:a}}function vH(t,e){const r=fi(t),n=Io(t),i=r.visualViewport;let s=n.clientWidth,o=n.clientHeight,a=0,l=0;if(i){s=i.width,o=i.height;const u=$T();(!u||u&&e==="fixed")&&(a=i.offsetLeft,l=i.offsetTop)}return{width:s,height:o,x:a,y:l}}function yH(t,e){const r=Ju(t,!0,e==="fixed"),n=r.top+t.clientTop,i=r.left+t.clientLeft,s=bo(t)?yd(t):go(1),o=t.clientWidth*s.x,a=t.clientHeight*s.y,l=i*s.x,u=n*s.y;return{width:o,height:a,x:l,y:u}}function zI(t,e,r){let n;if(e==="viewport")n=vH(t,r);else if(e==="document")n=gH(Io(t));else if(As(e))n=yH(e,r);else{const i=tL(t);n={x:e.x-i.x,y:e.y-i.y,width:e.width,height:e.height}}return ty(n)}function nL(t,e){const r=Pl(t);return r===e||!As(r)||Zd(r)?!1:Rs(r).position==="fixed"||nL(r,e)}function xH(t,e){const r=e.get(t);if(r)return r;let n=Ap(t,[],!1).filter(a=>As(a)&&hh(a)!=="body"),i=null;const s=Rs(t).position==="fixed";let o=s?Pl(t):t;for(;As(o)&&!Zd(o);){const a=Rs(o),l=UT(o);!l&&a.position==="fixed"&&(i=null),(s?!l&&!i:!l&&a.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||um(o)&&!l&&nL(t,o))?n=n.filter(c=>c!==o):i=a,o=Pl(o)}return e.set(t,n),n}function bH(t){let{element:e,boundary:r,rootBoundary:n,strategy:i}=t;const o=[...r==="clippingAncestors"?p1(e)?[]:xH(e,this._c):[].concat(r),n],a=o[0],l=o.reduce((u,c)=>{const h=zI(e,c,i);return u.top=Li(h.top,u.top),u.right=Cp(h.right,u.right),u.bottom=Cp(h.bottom,u.bottom),u.left=Li(h.left,u.left),u},zI(e,a,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function wH(t){const{width:e,height:r}=eL(t);return{width:e,height:r}}function _H(t,e,r){const n=bo(e),i=Io(e),s=r==="fixed",o=Ju(t,!0,s,e);let a={scrollLeft:0,scrollTop:0};const l=go(0);if(n||!n&&!s)if((hh(e)!=="body"||um(i))&&(a=m1(e)),n){const f=Ju(e,!0,s,e);l.x=f.x+e.clientLeft,l.y=f.y+e.clientTop}else i&&(l.x=HT(i));const u=i&&!n&&!s?rL(i,a):go(0),c=o.left+a.scrollLeft-l.x-u.x,h=o.top+a.scrollTop-l.y-u.y;return{x:c,y:h,width:o.width,height:o.height}}function tw(t){return Rs(t).position==="static"}function HI(t,e){if(!bo(t)||Rs(t).position==="fixed")return null;if(e)return e(t);let r=t.offsetParent;return Io(t)===r&&(r=r.ownerDocument.body),r}function iL(t,e){const r=fi(t);if(p1(t))return r;if(!bo(t)){let i=Pl(t);for(;i&&!Zd(i);){if(As(i)&&!tw(i))return i;i=Pl(i)}return r}let n=HI(t,e);for(;n&&cH(n)&&tw(n);)n=HI(n,e);return n&&Zd(n)&&tw(n)&&!UT(n)?r:n||dH(t)||r}const SH=async function(t){const e=this.getOffsetParent||iL,r=this.getDimensions,n=await r(t.floating);return{reference:_H(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function EH(t){return Rs(t).direction==="rtl"}const TH={convertOffsetParentRelativeRectToViewportRelativeRect:pH,getDocumentElement:Io,getClippingRect:bH,getOffsetParent:iL,getElementRects:SH,getClientRects:mH,getDimensions:wH,getScale:yd,isElement:As,isRTL:EH};function CH(t,e){let r=null,n;const i=Io(t);function s(){var a;clearTimeout(n),(a=r)==null||a.disconnect(),r=null}function o(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),s();const{left:u,top:c,width:h,height:f}=t.getBoundingClientRect();if(a||e(),!h||!f)return;const m=zg(c),y=zg(i.clientWidth-(u+h)),v=zg(i.clientHeight-(c+f)),x=zg(u),_={rootMargin:-m+"px "+-y+"px "+-v+"px "+-x+"px",threshold:Li(0,Cp(1,l))||1};let w=!0;function E(A){const P=A[0].intersectionRatio;if(P!==l){if(!w)return o();P?o(!1,P):n=setTimeout(()=>{o(!1,1e-7)},1e3)}w=!1}try{r=new IntersectionObserver(E,{..._,root:i.ownerDocument})}catch{r=new IntersectionObserver(E,_)}r.observe(t)}return o(!0),s}function AH(t,e,r,n){n===void 0&&(n={});const{ancestorScroll:i=!0,ancestorResize:s=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,u=zT(t),c=i||s?[...u?Ap(u):[],...Ap(e)]:[];c.forEach(b=>{i&&b.addEventListener("scroll",r,{passive:!0}),s&&b.addEventListener("resize",r)});const h=u&&a?CH(u,r):null;let f=-1,m=null;o&&(m=new ResizeObserver(b=>{let[_]=b;_&&_.target===u&&m&&(m.unobserve(e),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var w;(w=m)==null||w.observe(e)})),r()}),u&&!l&&m.observe(u),m.observe(e));let y,v=l?Ju(t):null;l&&x();function x(){const b=Ju(t);v&&(b.x!==v.x||b.y!==v.y||b.width!==v.width||b.height!==v.height)&&r(),v=b,y=requestAnimationFrame(x)}return r(),()=>{var b;c.forEach(_=>{i&&_.removeEventListener("scroll",r),s&&_.removeEventListener("resize",r)}),h==null||h(),(b=m)==null||b.disconnect(),m=null,l&&cancelAnimationFrame(y)}}const RH=lH,PH=oH,IH=uH,MH=(t,e,r)=>{const n=new Map,i={platform:TH,...r},s={...i.platform,_c:n};return sH(t,e,{...i,platform:s})};var K0=typeof document<"u"?T.useLayoutEffect:T.useEffect;function ry(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if(typeof t=="function"&&t.toString()===e.toString())return!0;let r,n,i;if(t&&e&&typeof t=="object"){if(Array.isArray(t)){if(r=t.length,r!==e.length)return!1;for(n=r;n--!==0;)if(!ry(t[n],e[n]))return!1;return!0}if(i=Object.keys(t),r=i.length,r!==Object.keys(e).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(e,i[n]))return!1;for(n=r;n--!==0;){const s=i[n];if(!(s==="_owner"&&t.$$typeof)&&!ry(t[s],e[s]))return!1}return!0}return t!==t&&e!==e}function sL(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function VI(t,e){const r=sL(t);return Math.round(e*r)/r}function rw(t){const e=T.useRef(t);return K0(()=>{e.current=t}),e}function kH(t){t===void 0&&(t={});const{placement:e="bottom",strategy:r="absolute",middleware:n=[],platform:i,elements:{reference:s,floating:o}={},transform:a=!0,whileElementsMounted:l,open:u}=t,[c,h]=T.useState({x:0,y:0,strategy:r,placement:e,middlewareData:{},isPositioned:!1}),[f,m]=T.useState(n);ry(f,n)||m(n);const[y,v]=T.useState(null),[x,b]=T.useState(null),_=T.useCallback(k=>{k!==P.current&&(P.current=k,v(k))},[]),w=T.useCallback(k=>{k!==I.current&&(I.current=k,b(k))},[]),E=s||y,A=o||x,P=T.useRef(null),I=T.useRef(null),M=T.useRef(c),N=l!=null,z=rw(l),j=rw(i),H=rw(u),F=T.useCallback(()=>{if(!P.current||!I.current)return;const k={placement:e,strategy:r,middleware:f};j.current&&(k.platform=j.current),MH(P.current,I.current,k).then(U=>{const B={...U,isPositioned:H.current!==!1};L.current&&!ry(M.current,B)&&(M.current=B,mr.flushSync(()=>{h(B)}))})},[f,e,r,j,H]);K0(()=>{u===!1&&M.current.isPositioned&&(M.current.isPositioned=!1,h(k=>({...k,isPositioned:!1})))},[u]);const L=T.useRef(!1);K0(()=>(L.current=!0,()=>{L.current=!1}),[]),K0(()=>{if(E&&(P.current=E),A&&(I.current=A),E&&A){if(z.current)return z.current(E,A,F);F()}},[E,A,F,z,N]);const O=T.useMemo(()=>({reference:P,floating:I,setReference:_,setFloating:w}),[_,w]),$=T.useMemo(()=>({reference:E,floating:A}),[E,A]),V=T.useMemo(()=>{const k={position:r,left:0,top:0};if(!$.floating)return k;const U=VI($.floating,c.x),B=VI($.floating,c.y);return a?{...k,transform:"translate("+U+"px, "+B+"px)",...sL($.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:U,top:B}},[r,a,$.floating,c.x,c.y]);return T.useMemo(()=>({...c,update:F,refs:O,elements:$,floatingStyles:V}),[c,F,O,$,V])}const OH=(t,e)=>({...RH(t),options:[t,e]}),DH=(t,e)=>({...PH(t),options:[t,e]}),NH=(t,e)=>({...IH(t),options:[t,e]});var Rp=typeof document<"u"?T.useLayoutEffect:T.useEffect;let nw=!1,LH=0;const GI=()=>"floating-ui-"+LH++;function FH(){const[t,e]=T.useState(()=>nw?GI():void 0);return Rp(()=>{t==null&&e(GI())},[]),T.useEffect(()=>{nw||(nw=!0)},[]),t}const jH=sO.useId,BH=jH||FH;function UH(){const t=new Map;return{emit(e,r){var n;(n=t.get(e))==null||n.forEach(i=>i(r))},on(e,r){t.set(e,[...t.get(e)||[],r])},off(e,r){var n;t.set(e,((n=t.get(e))==null?void 0:n.filter(i=>i!==r))||[])}}}const $H=T.createContext(null),zH=T.createContext(null),HH=()=>{var t;return((t=T.useContext($H))==null?void 0:t.id)||null},oL=()=>T.useContext(zH);function VH(t){return"data-floating-ui-"+t}function WI(t){const e=T.useRef(t);return Rp(()=>{e.current=t}),e}const XI=VH("safe-polygon");function iw(t,e,r){return r&&!qN(r)?0:typeof t=="number"?t:t==null?void 0:t[e]}function GH(t,e){e===void 0&&(e={});const{open:r,onOpenChange:n,dataRef:i,events:s,elements:{domReference:o,floating:a},refs:l}=t,{enabled:u=!0,delay:c=0,handleClose:h=null,mouseOnly:f=!1,restMs:m=0,move:y=!0}=e,v=oL(),x=HH(),b=WI(h),_=WI(c),w=T.useRef(),E=T.useRef(),A=T.useRef(),P=T.useRef(),I=T.useRef(!0),M=T.useRef(!1),N=T.useRef(()=>{}),z=T.useCallback(()=>{var L;const O=(L=i.current.openEvent)==null?void 0:L.type;return(O==null?void 0:O.includes("mouse"))&&O!=="mousedown"},[i]);T.useEffect(()=>{if(!u)return;function L(){clearTimeout(E.current),clearTimeout(P.current),I.current=!0}return s.on("dismiss",L),()=>{s.off("dismiss",L)}},[u,s]),T.useEffect(()=>{if(!u||!b.current||!r)return;function L($){z()&&n(!1,$)}const O=$g(a).documentElement;return O.addEventListener("mouseleave",L),()=>{O.removeEventListener("mouseleave",L)}},[a,r,n,u,b,i,z]);const j=T.useCallback(function(L,O){O===void 0&&(O=!0);const $=iw(_.current,"close",w.current);$&&!A.current?(clearTimeout(E.current),E.current=setTimeout(()=>n(!1,L),$)):O&&(clearTimeout(E.current),n(!1,L))},[_,n]),H=T.useCallback(()=>{N.current(),A.current=void 0},[]),F=T.useCallback(()=>{if(M.current){const L=$g(l.floating.current).body;L.style.pointerEvents="",L.removeAttribute(XI),M.current=!1}},[l]);return T.useEffect(()=>{if(!u)return;function L(){return i.current.openEvent?["click","mousedown"].includes(i.current.openEvent.type):!1}function O(k){if(clearTimeout(E.current),I.current=!1,f&&!qN(w.current)||m>0&&iw(_.current,"open")===0)return;const U=iw(_.current,"open",w.current);U?E.current=setTimeout(()=>{n(!0,k)},U):n(!0,k)}function $(k){if(L())return;N.current();const U=$g(a);if(clearTimeout(P.current),b.current){r||clearTimeout(E.current),A.current=b.current({...t,tree:v,x:k.clientX,y:k.clientY,onClose(){F(),H(),j(k)}});const X=A.current;U.addEventListener("mousemove",X),N.current=()=>{U.removeEventListener("mousemove",X)};return}(w.current==="touch"?!Q0(a,k.relatedTarget):!0)&&j(k)}function V(k){L()||b.current==null||b.current({...t,tree:v,x:k.clientX,y:k.clientY,onClose(){F(),H(),j(k)}})(k)}if(Pu(o)){const k=o;return r&&k.addEventListener("mouseleave",V),a==null||a.addEventListener("mouseleave",V),y&&k.addEventListener("mousemove",O,{once:!0}),k.addEventListener("mouseenter",O),k.addEventListener("mouseleave",$),()=>{r&&k.removeEventListener("mouseleave",V),a==null||a.removeEventListener("mouseleave",V),y&&k.removeEventListener("mousemove",O),k.removeEventListener("mouseenter",O),k.removeEventListener("mouseleave",$)}}},[o,a,u,t,f,m,y,j,H,F,n,r,v,_,b,i]),Rp(()=>{var L;if(u&&r&&(L=b.current)!=null&&L.__options.blockPointerEvents&&z()){const V=$g(a).body;if(V.setAttribute(XI,""),V.style.pointerEvents="none",M.current=!0,Pu(o)&&a){var O,$;const k=o,U=v==null||(O=v.nodesRef.current.find(B=>B.id===x))==null||($=O.context)==null?void 0:$.elements.floating;return U&&(U.style.pointerEvents=""),k.style.pointerEvents="auto",a.style.pointerEvents="auto",()=>{k.style.pointerEvents="",a.style.pointerEvents=""}}}},[u,r,x,a,o,v,b,i,z]),Rp(()=>{r||(w.current=void 0,H(),F())},[r,H,F]),T.useEffect(()=>()=>{H(),clearTimeout(E.current),clearTimeout(P.current),F()},[u,o,H,F]),T.useMemo(()=>{if(!u)return{};function L(O){w.current=O.pointerType}return{reference:{onPointerDown:L,onPointerEnter:L,onMouseMove(O){r||m===0||(clearTimeout(P.current),P.current=setTimeout(()=>{I.current||n(!0,O.nativeEvent)},m))}},floating:{onMouseEnter(){clearTimeout(E.current)},onMouseLeave(O){s.emit("dismiss",{type:"mouseLeave",data:{returnFocus:!1}}),j(O.nativeEvent,!1)}}}},[s,u,m,r,n,j])}function WH(t,e){let r=t.filter(i=>{var s;return i.parentId===e&&((s=i.context)==null?void 0:s.open)}),n=r;for(;n.length;)n=t.filter(i=>{var s;return(s=n)==null?void 0:s.some(o=>{var a;return i.parentId===o.id&&((a=i.context)==null?void 0:a.open)})}),r=r.concat(n);return r}const XH=sO.useInsertionEffect,qH=XH||(t=>t());function YH(t){const e=T.useRef(()=>{});return qH(()=>{e.current=t}),T.useCallback(function(){for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];return e.current==null?void 0:e.current(...n)},[])}function QH(t){var e;t===void 0&&(t={});const{open:r=!1,onOpenChange:n,nodeId:i}=t,[s,o]=T.useState(null),a=((e=t.elements)==null?void 0:e.reference)||s,l=kH(t),u=oL(),c=YH((E,A)=>{E&&(f.current.openEvent=A),n==null||n(E,A)}),h=T.useRef(null),f=T.useRef({}),m=T.useState(()=>UH())[0],y=BH(),v=T.useCallback(E=>{const A=Pu(E)?{getBoundingClientRect:()=>E.getBoundingClientRect(),contextElement:E}:E;l.refs.setReference(A)},[l.refs]),x=T.useCallback(E=>{(Pu(E)||E===null)&&(h.current=E,o(E)),(Pu(l.refs.reference.current)||l.refs.reference.current===null||E!==null&&!Pu(E))&&l.refs.setReference(E)},[l.refs]),b=T.useMemo(()=>({...l.refs,setReference:x,setPositionReference:v,domReference:h}),[l.refs,x,v]),_=T.useMemo(()=>({...l.elements,domReference:a}),[l.elements,a]),w=T.useMemo(()=>({...l,refs:b,elements:_,dataRef:f,nodeId:i,floatingId:y,events:m,open:r,onOpenChange:c}),[l,i,y,m,r,c,b,_]);return Rp(()=>{const E=u==null?void 0:u.nodesRef.current.find(A=>A.id===i);E&&(E.context=w)}),T.useMemo(()=>({...l,context:w,refs:b,elements:_}),[l,b,_,w])}function qI(t,e){const[r,n]=t;let i=!1;const s=e.length;for(let o=0,a=s-1;o<s;a=o++){const[l,u]=e[o]||[0,0],[c,h]=e[a]||[0,0];u>=n!=h>=n&&r<=(c-l)*(n-u)/(h-u)+l&&(i=!i)}return i}function KH(t,e){return t[0]>=e.x&&t[0]<=e.x+e.width&&t[1]>=e.y&&t[1]<=e.y+e.height}function ZH(t){t===void 0&&(t={});const{buffer:e=.5,blockPointerEvents:r=!1,requireIntent:n=!0}=t;let i,s=!1,o=null,a=null,l=performance.now();function u(h,f){const m=performance.now(),y=m-l;if(o===null||a===null||y===0)return o=h,a=f,l=m,null;const v=h-o,x=f-a,_=Math.sqrt(v*v+x*x)/y;return o=h,a=f,l=m,_}const c=h=>{let{x:f,y:m,placement:y,elements:v,onClose:x,nodeId:b,tree:_}=h;return function(E){function A(){clearTimeout(i),x()}if(clearTimeout(i),!v.domReference||!v.floating||y==null||f==null||m==null)return;const{clientX:P,clientY:I}=E,M=[P,I],N=Yz(E),z=E.type==="mouseleave",j=Q0(v.floating,N),H=Q0(v.domReference,N),F=v.domReference.getBoundingClientRect(),L=v.floating.getBoundingClientRect(),O=y.split("-")[0],$=f>L.right-L.width/2,V=m>L.bottom-L.height/2,k=KH(M,F),U=L.width>F.width,B=L.height>F.height,X=(U?F:L).left,K=(U?F:L).right,q=(B?F:L).top,re=(B?F:L).bottom;if(j&&(s=!0,!z))return;if(H&&(s=!1),H&&!z){s=!0;return}if(z&&Pu(E.relatedTarget)&&Q0(v.floating,E.relatedTarget)||_&&WH(_.nodesRef.current,b).some(me=>{let{context:xe}=me;return xe==null?void 0:xe.open}))return;if(O==="top"&&m>=F.bottom-1||O==="bottom"&&m<=F.top+1||O==="left"&&f>=F.right-1||O==="right"&&f<=F.left+1)return A();let ue=[];switch(O){case"top":ue=[[X,F.top+1],[X,L.bottom-1],[K,L.bottom-1],[K,F.top+1]];break;case"bottom":ue=[[X,L.top+1],[X,F.bottom-1],[K,F.bottom-1],[K,L.top+1]];break;case"left":ue=[[L.right-1,re],[L.right-1,q],[F.left+1,q],[F.left+1,re]];break;case"right":ue=[[F.right-1,re],[F.right-1,q],[L.left+1,q],[L.left+1,re]];break}function le(me){let[xe,_e]=me;switch(O){case"top":{const Te=[U?xe+e/2:$?xe+e*4:xe-e*4,_e+e+1],de=[U?xe-e/2:$?xe+e*4:xe-e*4,_e+e+1],Be=[[L.left,$||U?L.bottom-e:L.top],[L.right,$?U?L.bottom-e:L.top:L.bottom-e]];return[Te,de,...Be]}case"bottom":{const Te=[U?xe+e/2:$?xe+e*4:xe-e*4,_e-e],de=[U?xe-e/2:$?xe+e*4:xe-e*4,_e-e],Be=[[L.left,$||U?L.top+e:L.bottom],[L.right,$?U?L.top+e:L.bottom:L.top+e]];return[Te,de,...Be]}case"left":{const Te=[xe+e+1,B?_e+e/2:V?_e+e*4:_e-e*4],de=[xe+e+1,B?_e-e/2:V?_e+e*4:_e-e*4];return[...[[V||B?L.right-e:L.left,L.top],[V?B?L.right-e:L.left:L.right-e,L.bottom]],Te,de]}case"right":{const Te=[xe-e,B?_e+e/2:V?_e+e*4:_e-e*4],de=[xe-e,B?_e-e/2:V?_e+e*4:_e-e*4],Be=[[V||B?L.left+e:L.right,L.top],[V?B?L.left+e:L.right:L.left+e,L.bottom]];return[Te,de,...Be]}}}if(!qI([P,I],ue)){if(s&&!k)return A();if(!z&&n){const me=u(E.clientX,E.clientY);if(me!==null&&me<.1)return A()}qI([P,I],le([f,m]))?!s&&n&&(i=window.setTimeout(A,40)):A()}}};return c.__options={blockPointerEvents:r},c}var aL={exports:{}};(function(t,e){(function(r,n){t.exports=n()})(rr,function(){var r=1e3,n=6e4,i=36e5,s="millisecond",o="second",a="minute",l="hour",u="day",c="week",h="month",f="quarter",m="year",y="date",v="Invalid Date",x=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,b=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,_={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(L){var O=["th","st","nd","rd"],$=L%100;return"["+L+(O[($-20)%10]||O[$]||O[0])+"]"}},w=function(L,O,$){var V=String(L);return!V||V.length>=O?L:""+Array(O+1-V.length).join($)+L},E={s:w,z:function(L){var O=-L.utcOffset(),$=Math.abs(O),V=Math.floor($/60),k=$%60;return(O<=0?"+":"-")+w(V,2,"0")+":"+w(k,2,"0")},m:function L(O,$){if(O.date()<$.date())return-L($,O);var V=12*($.year()-O.year())+($.month()-O.month()),k=O.clone().add(V,h),U=$-k<0,B=O.clone().add(V+(U?-1:1),h);return+(-(V+($-k)/(U?k-B:B-k))||0)},a:function(L){return L<0?Math.ceil(L)||0:Math.floor(L)},p:function(L){return{M:h,y:m,w:c,d:u,D:y,h:l,m:a,s:o,ms:s,Q:f}[L]||String(L||"").toLowerCase().replace(/s$/,"")},u:function(L){return L===void 0}},A="en",P={};P[A]=_;var I="$isDayjsObject",M=function(L){return L instanceof H||!(!L||!L[I])},N=function L(O,$,V){var k;if(!O)return A;if(typeof O=="string"){var U=O.toLowerCase();P[U]&&(k=U),$&&(P[U]=$,k=U);var B=O.split("-");if(!k&&B.length>1)return L(B[0])}else{var X=O.name;P[X]=O,k=X}return!V&&k&&(A=k),k||!V&&A},z=function(L,O){if(M(L))return L.clone();var $=typeof O=="object"?O:{};return $.date=L,$.args=arguments,new H($)},j=E;j.l=N,j.i=M,j.w=function(L,O){return z(L,{locale:O.$L,utc:O.$u,x:O.$x,$offset:O.$offset})};var H=function(){function L($){this.$L=N($.locale,null,!0),this.parse($),this.$x=this.$x||$.x||{},this[I]=!0}var O=L.prototype;return O.parse=function($){this.$d=function(V){var k=V.date,U=V.utc;if(k===null)return new Date(NaN);if(j.u(k))return new Date;if(k instanceof Date)return new Date(k);if(typeof k=="string"&&!/Z$/i.test(k)){var B=k.match(x);if(B){var X=B[2]-1||0,K=(B[7]||"0").substring(0,3);return U?new Date(Date.UTC(B[1],X,B[3]||1,B[4]||0,B[5]||0,B[6]||0,K)):new Date(B[1],X,B[3]||1,B[4]||0,B[5]||0,B[6]||0,K)}}return new Date(k)}($),this.init()},O.init=function(){var $=this.$d;this.$y=$.getFullYear(),this.$M=$.getMonth(),this.$D=$.getDate(),this.$W=$.getDay(),this.$H=$.getHours(),this.$m=$.getMinutes(),this.$s=$.getSeconds(),this.$ms=$.getMilliseconds()},O.$utils=function(){return j},O.isValid=function(){return this.$d.toString()!==v},O.isSame=function($,V){var k=z($);return this.startOf(V)<=k&&k<=this.endOf(V)},O.isAfter=function($,V){return z($)<this.startOf(V)},O.isBefore=function($,V){return this.endOf(V)<z($)},O.$g=function($,V,k){return j.u($)?this[V]:this.set(k,$)},O.unix=function(){return Math.floor(this.valueOf()/1e3)},O.valueOf=function(){return this.$d.getTime()},O.startOf=function($,V){var k=this,U=!!j.u(V)||V,B=j.p($),X=function(_e,Te){var de=j.w(k.$u?Date.UTC(k.$y,Te,_e):new Date(k.$y,Te,_e),k);return U?de:de.endOf(u)},K=function(_e,Te){return j.w(k.toDate()[_e].apply(k.toDate("s"),(U?[0,0,0,0]:[23,59,59,999]).slice(Te)),k)},q=this.$W,re=this.$M,ue=this.$D,le="set"+(this.$u?"UTC":"");switch(B){case m:return U?X(1,0):X(31,11);case h:return U?X(1,re):X(0,re+1);case c:var me=this.$locale().weekStart||0,xe=(q<me?q+7:q)-me;return X(U?ue-xe:ue+(6-xe),re);case u:case y:return K(le+"Hours",0);case l:return K(le+"Minutes",1);case a:return K(le+"Seconds",2);case o:return K(le+"Milliseconds",3);default:return this.clone()}},O.endOf=function($){return this.startOf($,!1)},O.$set=function($,V){var k,U=j.p($),B="set"+(this.$u?"UTC":""),X=(k={},k[u]=B+"Date",k[y]=B+"Date",k[h]=B+"Month",k[m]=B+"FullYear",k[l]=B+"Hours",k[a]=B+"Minutes",k[o]=B+"Seconds",k[s]=B+"Milliseconds",k)[U],K=U===u?this.$D+(V-this.$W):V;if(U===h||U===m){var q=this.clone().set(y,1);q.$d[X](K),q.init(),this.$d=q.set(y,Math.min(this.$D,q.daysInMonth())).$d}else X&&this.$d[X](K);return this.init(),this},O.set=function($,V){return this.clone().$set($,V)},O.get=function($){return this[j.p($)]()},O.add=function($,V){var k,U=this;$=Number($);var B=j.p(V),X=function(re){var ue=z(U);return j.w(ue.date(ue.date()+Math.round(re*$)),U)};if(B===h)return this.set(h,this.$M+$);if(B===m)return this.set(m,this.$y+$);if(B===u)return X(1);if(B===c)return X(7);var K=(k={},k[a]=n,k[l]=i,k[o]=r,k)[B]||1,q=this.$d.getTime()+$*K;return j.w(q,this)},O.subtract=function($,V){return this.add(-1*$,V)},O.format=function($){var V=this,k=this.$locale();if(!this.isValid())return k.invalidDate||v;var U=$||"YYYY-MM-DDTHH:mm:ssZ",B=j.z(this),X=this.$H,K=this.$m,q=this.$M,re=k.weekdays,ue=k.months,le=k.meridiem,me=function(Te,de,Be,je){return Te&&(Te[de]||Te(V,U))||Be[de].slice(0,je)},xe=function(Te){return j.s(X%12||12,Te,"0")},_e=le||function(Te,de,Be){var je=Te<12?"AM":"PM";return Be?je.toLowerCase():je};return U.replace(b,function(Te,de){return de||function(Be){switch(Be){case"YY":return String(V.$y).slice(-2);case"YYYY":return j.s(V.$y,4,"0");case"M":return q+1;case"MM":return j.s(q+1,2,"0");case"MMM":return me(k.monthsShort,q,ue,3);case"MMMM":return me(ue,q);case"D":return V.$D;case"DD":return j.s(V.$D,2,"0");case"d":return String(V.$W);case"dd":return me(k.weekdaysMin,V.$W,re,2);case"ddd":return me(k.weekdaysShort,V.$W,re,3);case"dddd":return re[V.$W];case"H":return String(X);case"HH":return j.s(X,2,"0");case"h":return xe(1);case"hh":return xe(2);case"a":return _e(X,K,!0);case"A":return _e(X,K,!1);case"m":return String(K);case"mm":return j.s(K,2,"0");case"s":return String(V.$s);case"ss":return j.s(V.$s,2,"0");case"SSS":return j.s(V.$ms,3,"0");case"Z":return B}return null}(Te)||B.replace(":","")})},O.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},O.diff=function($,V,k){var U,B=this,X=j.p(V),K=z($),q=(K.utcOffset()-this.utcOffset())*n,re=this-K,ue=function(){return j.m(B,K)};switch(X){case m:U=ue()/12;break;case h:U=ue();break;case f:U=ue()/3;break;case c:U=(re-q)/6048e5;break;case u:U=(re-q)/864e5;break;case l:U=re/i;break;case a:U=re/n;break;case o:U=re/r;break;default:U=re}return k?U:j.a(U)},O.daysInMonth=function(){return this.endOf(h).$D},O.$locale=function(){return P[this.$L]},O.locale=function($,V){if(!$)return this.$L;var k=this.clone(),U=N($,V,!0);return U&&(k.$L=U),k},O.clone=function(){return j.w(this.$d,this)},O.toDate=function(){return new Date(this.valueOf())},O.toJSON=function(){return this.isValid()?this.toISOString():null},O.toISOString=function(){return this.$d.toISOString()},O.toString=function(){return this.$d.toUTCString()},L}(),F=H.prototype;return z.prototype=F,[["$ms",s],["$s",o],["$m",a],["$H",l],["$W",u],["$M",h],["$y",m],["$D",y]].forEach(function(L){F[L[1]]=function(O){return this.$g(O,L[0],L[1])}}),z.extend=function(L,O){return L.$i||(L(O,H,z),L.$i=!0),z},z.locale=N,z.isDayjs=M,z.unix=function(L){return z(1e3*L)},z.en=P[A],z.Ls=P,z.p={},z})})(aL);var JH=aL.exports;const Lr=Po(JH);var fh=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},ec=typeof window>"u"||"Deno"in globalThis;function Ii(){}function eV(t,e){return typeof t=="function"?t(e):t}function IS(t){return typeof t=="number"&&t>=0&&t!==1/0}function lL(t,e){return Math.max(t+(e||0)-Date.now(),0)}function xd(t,e){return typeof t=="function"?t(e):t}function ps(t,e){return typeof t=="function"?t(e):t}function YI(t,e){const{type:r="all",exact:n,fetchStatus:i,predicate:s,queryKey:o,stale:a}=t;if(o){if(n){if(e.queryHash!==VT(o,e.options))return!1}else if(!Pp(e.queryKey,o))return!1}if(r!=="all"){const l=e.isActive();if(r==="active"&&!l||r==="inactive"&&l)return!1}return!(typeof a=="boolean"&&e.isStale()!==a||i&&i!==e.state.fetchStatus||s&&!s(e))}function QI(t,e){const{exact:r,status:n,predicate:i,mutationKey:s}=t;if(s){if(!e.options.mutationKey)return!1;if(r){if(tc(e.options.mutationKey)!==tc(s))return!1}else if(!Pp(e.options.mutationKey,s))return!1}return!(n&&e.state.status!==n||i&&!i(e))}function VT(t,e){return((e==null?void 0:e.queryKeyHashFn)||tc)(t)}function tc(t){return JSON.stringify(t,(e,r)=>MS(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function Pp(t,e){return t===e?!0:typeof t!=typeof e?!1:t&&e&&typeof t=="object"&&typeof e=="object"?!Object.keys(e).some(r=>!Pp(t[r],e[r])):!1}function uL(t,e){if(t===e)return t;const r=KI(t)&&KI(e);if(r||MS(t)&&MS(e)){const n=r?t:Object.keys(t),i=n.length,s=r?e:Object.keys(e),o=s.length,a=r?[]:{};let l=0;for(let u=0;u<o;u++){const c=r?u:s[u];(!r&&n.includes(c)||r)&&t[c]===void 0&&e[c]===void 0?(a[c]=void 0,l++):(a[c]=uL(t[c],e[c]),a[c]===t[c]&&t[c]!==void 0&&l++)}return i===o&&l===i?t:a}return e}function ny(t,e){if(!e||Object.keys(t).length!==Object.keys(e).length)return!1;for(const r in t)if(t[r]!==e[r])return!1;return!0}function KI(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function MS(t){if(!ZI(t))return!1;const e=t.constructor;if(e===void 0)return!0;const r=e.prototype;return!(!ZI(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(t)!==Object.prototype)}function ZI(t){return Object.prototype.toString.call(t)==="[object Object]"}function tV(t){return new Promise(e=>{setTimeout(e,t)})}function kS(t,e,r){return typeof r.structuralSharing=="function"?r.structuralSharing(t,e):r.structuralSharing!==!1?uL(t,e):e}function rV(t,e,r=0){const n=[...t,e];return r&&n.length>r?n.slice(1):n}function nV(t,e,r=0){const n=[e,...t];return r&&n.length>r?n.slice(0,-1):n}var GT=Symbol();function cL(t,e){return!t.queryFn&&(e!=null&&e.initialPromise)?()=>e.initialPromise:!t.queryFn||t.queryFn===GT?()=>Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`)):t.queryFn}var Mu,Ka,Md,Dk,iV=(Dk=class extends fh{constructor(){super();Ze(this,Mu);Ze(this,Ka);Ze(this,Md);Ne(this,Md,e=>{if(!ec&&window.addEventListener){const r=()=>e();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){Y(this,Ka)||this.setEventListener(Y(this,Md))}onUnsubscribe(){var e;this.hasListeners()||((e=Y(this,Ka))==null||e.call(this),Ne(this,Ka,void 0))}setEventListener(e){var r;Ne(this,Md,e),(r=Y(this,Ka))==null||r.call(this),Ne(this,Ka,e(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(e){Y(this,Mu)!==e&&(Ne(this,Mu,e),this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach(r=>{r(e)})}isFocused(){var e;return typeof Y(this,Mu)=="boolean"?Y(this,Mu):((e=globalThis.document)==null?void 0:e.visibilityState)!=="hidden"}},Mu=new WeakMap,Ka=new WeakMap,Md=new WeakMap,Dk),WT=new iV,kd,Za,Od,Nk,sV=(Nk=class extends fh{constructor(){super();Ze(this,kd,!0);Ze(this,Za);Ze(this,Od);Ne(this,Od,e=>{if(!ec&&window.addEventListener){const r=()=>e(!0),n=()=>e(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",n)}}})}onSubscribe(){Y(this,Za)||this.setEventListener(Y(this,Od))}onUnsubscribe(){var e;this.hasListeners()||((e=Y(this,Za))==null||e.call(this),Ne(this,Za,void 0))}setEventListener(e){var r;Ne(this,Od,e),(r=Y(this,Za))==null||r.call(this),Ne(this,Za,e(this.setOnline.bind(this)))}setOnline(e){Y(this,kd)!==e&&(Ne(this,kd,e),this.listeners.forEach(n=>{n(e)}))}isOnline(){return Y(this,kd)}},kd=new WeakMap,Za=new WeakMap,Od=new WeakMap,Nk),iy=new sV;function OS(){let t,e;const r=new Promise((i,s)=>{t=i,e=s});r.status="pending",r.catch(()=>{});function n(i){Object.assign(r,i),delete r.resolve,delete r.reject}return r.resolve=i=>{n({status:"fulfilled",value:i}),t(i)},r.reject=i=>{n({status:"rejected",reason:i}),e(i)},r}function oV(t){return Math.min(1e3*2**t,3e4)}function dL(t){return(t??"online")==="online"?iy.isOnline():!0}var hL=class extends Error{constructor(t){super("CancelledError"),this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent}};function sw(t){return t instanceof hL}function fL(t){let e=!1,r=0,n=!1,i;const s=OS(),o=v=>{var x;n||(f(new hL(v)),(x=t.abort)==null||x.call(t))},a=()=>{e=!0},l=()=>{e=!1},u=()=>WT.isFocused()&&(t.networkMode==="always"||iy.isOnline())&&t.canRun(),c=()=>dL(t.networkMode)&&t.canRun(),h=v=>{var x;n||(n=!0,(x=t.onSuccess)==null||x.call(t,v),i==null||i(),s.resolve(v))},f=v=>{var x;n||(n=!0,(x=t.onError)==null||x.call(t,v),i==null||i(),s.reject(v))},m=()=>new Promise(v=>{var x;i=b=>{(n||u())&&v(b)},(x=t.onPause)==null||x.call(t)}).then(()=>{var v;i=void 0,n||(v=t.onContinue)==null||v.call(t)}),y=()=>{if(n)return;let v;const x=r===0?t.initialPromise:void 0;try{v=x??t.fn()}catch(b){v=Promise.reject(b)}Promise.resolve(v).then(h).catch(b=>{var P;if(n)return;const _=t.retry??(ec?0:3),w=t.retryDelay??oV,E=typeof w=="function"?w(r,b):w,A=_===!0||typeof _=="number"&&r<_||typeof _=="function"&&_(r,b);if(e||!A){f(b);return}r++,(P=t.onFail)==null||P.call(t,r,b),tV(E).then(()=>u()?void 0:m()).then(()=>{e?f(b):y()})})};return{promise:s,cancel:o,continue:()=>(i==null||i(),s),cancelRetry:a,continueRetry:l,canStart:c,start:()=>(c()?y():m().then(y),s)}}function aV(){let t=[],e=0,r=a=>{a()},n=a=>{a()},i=a=>setTimeout(a,0);const s=a=>{e?t.push(a):i(()=>{r(a)})},o=()=>{const a=t;t=[],a.length&&i(()=>{n(()=>{a.forEach(l=>{r(l)})})})};return{batch:a=>{let l;e++;try{l=a()}finally{e--,e||o()}return l},batchCalls:a=>(...l)=>{s(()=>{a(...l)})},schedule:s,setNotifyFunction:a=>{r=a},setBatchNotifyFunction:a=>{n=a},setScheduler:a=>{i=a}}}var Tr=aV(),ku,Lk,pL=(Lk=class{constructor(){Ze(this,ku)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),IS(this.gcTime)&&Ne(this,ku,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(t){this.gcTime=Math.max(this.gcTime||0,t??(ec?1/0:5*60*1e3))}clearGcTimeout(){Y(this,ku)&&(clearTimeout(Y(this,ku)),Ne(this,ku,void 0))}},ku=new WeakMap,Lk),Dd,Nd,Pi,cn,Zp,Ou,ds,zo,Fk,lV=(Fk=class extends pL{constructor(e){super();Ze(this,ds);Ze(this,Dd);Ze(this,Nd);Ze(this,Pi);Ze(this,cn);Ze(this,Zp);Ze(this,Ou);Ne(this,Ou,!1),Ne(this,Zp,e.defaultOptions),this.setOptions(e.options),this.observers=[],Ne(this,Pi,e.cache),this.queryKey=e.queryKey,this.queryHash=e.queryHash,Ne(this,Dd,uV(this.options)),this.state=e.state??Y(this,Dd),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var e;return(e=Y(this,cn))==null?void 0:e.promise}setOptions(e){this.options={...Y(this,Zp),...e},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&Y(this,Pi).remove(this)}setData(e,r){const n=kS(this.state.data,e,this.options);return lt(this,ds,zo).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(e,r){lt(this,ds,zo).call(this,{type:"setState",state:e,setStateOptions:r})}cancel(e){var n,i;const r=(n=Y(this,cn))==null?void 0:n.promise;return(i=Y(this,cn))==null||i.cancel(e),r?r.then(Ii).catch(Ii):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(Y(this,Dd))}isActive(){return this.observers.some(e=>ps(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===GT||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return this.state.isInvalidated?!0:this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0}isStaleByTime(e=0){return this.state.isInvalidated||this.state.data===void 0||!lL(this.state.dataUpdatedAt,e)}onFocus(){var r;const e=this.observers.find(n=>n.shouldFetchOnWindowFocus());e==null||e.refetch({cancelRefetch:!1}),(r=Y(this,cn))==null||r.continue()}onOnline(){var r;const e=this.observers.find(n=>n.shouldFetchOnReconnect());e==null||e.refetch({cancelRefetch:!1}),(r=Y(this,cn))==null||r.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),Y(this,Pi).notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(r=>r!==e),this.observers.length||(Y(this,cn)&&(Y(this,Ou)?Y(this,cn).cancel({revert:!0}):Y(this,cn).cancelRetry()),this.scheduleGc()),Y(this,Pi).notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||lt(this,ds,zo).call(this,{type:"invalidate"})}fetch(e,r){var l,u,c;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(Y(this,cn))return Y(this,cn).continueRetry(),Y(this,cn).promise}if(e&&this.setOptions(e),!this.options.queryFn){const h=this.observers.find(f=>f.options.queryFn);h&&this.setOptions(h.options)}const n=new AbortController,i=h=>{Object.defineProperty(h,"signal",{enumerable:!0,get:()=>(Ne(this,Ou,!0),n.signal)})},s=()=>{const h=cL(this.options,r),f={queryKey:this.queryKey,meta:this.meta};return i(f),Ne(this,Ou,!1),this.options.persister?this.options.persister(h,f,this):h(f)},o={fetchOptions:r,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:s};i(o),(l=this.options.behavior)==null||l.onFetch(o,this),Ne(this,Nd,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=o.fetchOptions)==null?void 0:u.meta))&<(this,ds,zo).call(this,{type:"fetch",meta:(c=o.fetchOptions)==null?void 0:c.meta});const a=h=>{var f,m,y,v;sw(h)&&h.silent||lt(this,ds,zo).call(this,{type:"error",error:h}),sw(h)||((m=(f=Y(this,Pi).config).onError)==null||m.call(f,h,this),(v=(y=Y(this,Pi).config).onSettled)==null||v.call(y,this.state.data,h,this)),this.scheduleGc()};return Ne(this,cn,fL({initialPromise:r==null?void 0:r.initialPromise,fn:o.fetchFn,abort:n.abort.bind(n),onSuccess:h=>{var f,m,y,v;if(h===void 0){a(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(h)}catch(x){a(x);return}(m=(f=Y(this,Pi).config).onSuccess)==null||m.call(f,h,this),(v=(y=Y(this,Pi).config).onSettled)==null||v.call(y,h,this.state.error,this),this.scheduleGc()},onError:a,onFail:(h,f)=>{lt(this,ds,zo).call(this,{type:"failed",failureCount:h,error:f})},onPause:()=>{lt(this,ds,zo).call(this,{type:"pause"})},onContinue:()=>{lt(this,ds,zo).call(this,{type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0})),Y(this,cn).start()}},Dd=new WeakMap,Nd=new WeakMap,Pi=new WeakMap,cn=new WeakMap,Zp=new WeakMap,Ou=new WeakMap,ds=new WeakSet,zo=function(e){const r=n=>{switch(e.type){case"failed":return{...n,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...mL(n.data,this.options),fetchMeta:e.meta??null};case"success":return{...n,data:e.data,dataUpdateCount:n.dataUpdateCount+1,dataUpdatedAt:e.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const i=e.error;return sw(i)&&i.revert&&Y(this,Nd)?{...Y(this,Nd),fetchStatus:"idle"}:{...n,error:i,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...e.state}}};this.state=r(this.state),Tr.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),Y(this,Pi).notify({query:this,type:"updated",action:e})})},Fk);function mL(t,e){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:dL(e.networkMode)?"fetching":"paused",...t===void 0&&{error:null,status:"pending"}}}function uV(t){const e=typeof t.initialData=="function"?t.initialData():t.initialData,r=e!==void 0,n=r?typeof t.initialDataUpdatedAt=="function"?t.initialDataUpdatedAt():t.initialDataUpdatedAt:0;return{data:e,dataUpdateCount:0,dataUpdatedAt:r?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var Js,jk,gL=(jk=class extends fh{constructor(e={}){super();Ze(this,Js);this.config=e,Ne(this,Js,new Map)}build(e,r,n){const i=r.queryKey,s=r.queryHash??VT(i,r);let o=this.get(s);return o||(o=new lV({cache:this,queryKey:i,queryHash:s,options:e.defaultQueryOptions(r),state:n,defaultOptions:e.getQueryDefaults(i)}),this.add(o)),o}add(e){Y(this,Js).has(e.queryHash)||(Y(this,Js).set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const r=Y(this,Js).get(e.queryHash);r&&(e.destroy(),r===e&&Y(this,Js).delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){Tr.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return Y(this,Js).get(e)}getAll(){return[...Y(this,Js).values()]}find(e){const r={exact:!0,...e};return this.getAll().find(n=>YI(r,n))}findAll(e={}){const r=this.getAll();return Object.keys(e).length>0?r.filter(n=>YI(e,n)):r}notify(e){Tr.batch(()=>{this.listeners.forEach(r=>{r(e)})})}onFocus(){Tr.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){Tr.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},Js=new WeakMap,jk),eo,yn,Du,to,Ba,Bk,cV=(Bk=class extends pL{constructor(e){super();Ze(this,to);Ze(this,eo);Ze(this,yn);Ze(this,Du);this.mutationId=e.mutationId,Ne(this,yn,e.mutationCache),Ne(this,eo,[]),this.state=e.state||vL(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){Y(this,eo).includes(e)||(Y(this,eo).push(e),this.clearGcTimeout(),Y(this,yn).notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){Ne(this,eo,Y(this,eo).filter(r=>r!==e)),this.scheduleGc(),Y(this,yn).notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){Y(this,eo).length||(this.state.status==="pending"?this.scheduleGc():Y(this,yn).remove(this))}continue(){var e;return((e=Y(this,Du))==null?void 0:e.continue())??this.execute(this.state.variables)}async execute(e){var i,s,o,a,l,u,c,h,f,m,y,v,x,b,_,w,E,A,P,I;Ne(this,Du,fL({fn:()=>this.options.mutationFn?this.options.mutationFn(e):Promise.reject(new Error("No mutationFn found")),onFail:(M,N)=>{lt(this,to,Ba).call(this,{type:"failed",failureCount:M,error:N})},onPause:()=>{lt(this,to,Ba).call(this,{type:"pause"})},onContinue:()=>{lt(this,to,Ba).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>Y(this,yn).canRun(this)}));const r=this.state.status==="pending",n=!Y(this,Du).canStart();try{if(!r){lt(this,to,Ba).call(this,{type:"pending",variables:e,isPaused:n}),await((s=(i=Y(this,yn).config).onMutate)==null?void 0:s.call(i,e,this));const N=await((a=(o=this.options).onMutate)==null?void 0:a.call(o,e));N!==this.state.context&<(this,to,Ba).call(this,{type:"pending",context:N,variables:e,isPaused:n})}const M=await Y(this,Du).start();return await((u=(l=Y(this,yn).config).onSuccess)==null?void 0:u.call(l,M,e,this.state.context,this)),await((h=(c=this.options).onSuccess)==null?void 0:h.call(c,M,e,this.state.context)),await((m=(f=Y(this,yn).config).onSettled)==null?void 0:m.call(f,M,null,this.state.variables,this.state.context,this)),await((v=(y=this.options).onSettled)==null?void 0:v.call(y,M,null,e,this.state.context)),lt(this,to,Ba).call(this,{type:"success",data:M}),M}catch(M){try{throw await((b=(x=Y(this,yn).config).onError)==null?void 0:b.call(x,M,e,this.state.context,this)),await((w=(_=this.options).onError)==null?void 0:w.call(_,M,e,this.state.context)),await((A=(E=Y(this,yn).config).onSettled)==null?void 0:A.call(E,void 0,M,this.state.variables,this.state.context,this)),await((I=(P=this.options).onSettled)==null?void 0:I.call(P,void 0,M,e,this.state.context)),M}finally{lt(this,to,Ba).call(this,{type:"error",error:M})}}finally{Y(this,yn).runNext(this)}}},eo=new WeakMap,yn=new WeakMap,Du=new WeakMap,to=new WeakSet,Ba=function(e){const r=n=>{switch(e.type){case"failed":return{...n,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...n,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:e.error,failureCount:n.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Tr.batch(()=>{Y(this,eo).forEach(n=>{n.onMutationUpdate(e)}),Y(this,yn).notify({mutation:this,type:"updated",action:e})})},Bk);function vL(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var ai,Jp,Uk,dV=(Uk=class extends fh{constructor(e={}){super();Ze(this,ai);Ze(this,Jp);this.config=e,Ne(this,ai,new Map),Ne(this,Jp,Date.now())}build(e,r,n){const i=new cV({mutationCache:this,mutationId:++wg(this,Jp)._,options:e.defaultMutationOptions(r),state:n});return this.add(i),i}add(e){const r=Hg(e),n=Y(this,ai).get(r)??[];n.push(e),Y(this,ai).set(r,n),this.notify({type:"added",mutation:e})}remove(e){var n;const r=Hg(e);if(Y(this,ai).has(r)){const i=(n=Y(this,ai).get(r))==null?void 0:n.filter(s=>s!==e);i&&(i.length===0?Y(this,ai).delete(r):Y(this,ai).set(r,i))}this.notify({type:"removed",mutation:e})}canRun(e){var n;const r=(n=Y(this,ai).get(Hg(e)))==null?void 0:n.find(i=>i.state.status==="pending");return!r||r===e}runNext(e){var n;const r=(n=Y(this,ai).get(Hg(e)))==null?void 0:n.find(i=>i!==e&&i.state.isPaused);return(r==null?void 0:r.continue())??Promise.resolve()}clear(){Tr.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}getAll(){return[...Y(this,ai).values()].flat()}find(e){const r={exact:!0,...e};return this.getAll().find(n=>QI(r,n))}findAll(e={}){return this.getAll().filter(r=>QI(e,r))}notify(e){Tr.batch(()=>{this.listeners.forEach(r=>{r(e)})})}resumePausedMutations(){const e=this.getAll().filter(r=>r.state.isPaused);return Tr.batch(()=>Promise.all(e.map(r=>r.continue().catch(Ii))))}},ai=new WeakMap,Jp=new WeakMap,Uk);function Hg(t){var e;return((e=t.options.scope)==null?void 0:e.id)??String(t.mutationId)}function sy(t){return{onFetch:(e,r)=>{var c,h,f,m,y;const n=e.options,i=(f=(h=(c=e.fetchOptions)==null?void 0:c.meta)==null?void 0:h.fetchMore)==null?void 0:f.direction,s=((m=e.state.data)==null?void 0:m.pages)||[],o=((y=e.state.data)==null?void 0:y.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const u=async()=>{let v=!1;const x=w=>{Object.defineProperty(w,"signal",{enumerable:!0,get:()=>(e.signal.aborted?v=!0:e.signal.addEventListener("abort",()=>{v=!0}),e.signal)})},b=cL(e.options,e.fetchOptions),_=async(w,E,A)=>{if(v)return Promise.reject();if(E==null&&w.pages.length)return Promise.resolve(w);const P={queryKey:e.queryKey,pageParam:E,direction:A?"backward":"forward",meta:e.options.meta};x(P);const I=await b(P),{maxPages:M}=e.options,N=A?nV:rV;return{pages:N(w.pages,I,M),pageParams:N(w.pageParams,E,M)}};if(i&&s.length){const w=i==="backward",E=w?yL:DS,A={pages:s,pageParams:o},P=E(n,A);a=await _(A,P,w)}else{const w=t??s.length;do{const E=l===0?o[0]??n.initialPageParam:DS(n,a);if(l>0&&E==null)break;a=await _(a,E),l++}while(l<w)}return a};e.options.persister?e.fetchFn=()=>{var v,x;return(x=(v=e.options).persister)==null?void 0:x.call(v,u,{queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},r)}:e.fetchFn=u}}}function DS(t,{pages:e,pageParams:r}){const n=e.length-1;return e.length>0?t.getNextPageParam(e[n],e,r[n],r):void 0}function yL(t,{pages:e,pageParams:r}){var n;return e.length>0?(n=t.getPreviousPageParam)==null?void 0:n.call(t,e[0],e,r[0],r):void 0}function hV(t,e){return e?DS(t,e)!=null:!1}function fV(t,e){return!e||!t.getPreviousPageParam?!1:yL(t,e)!=null}var Zt,Ja,el,Ld,Fd,tl,jd,Bd,$k,pV=($k=class{constructor(t={}){Ze(this,Zt);Ze(this,Ja);Ze(this,el);Ze(this,Ld);Ze(this,Fd);Ze(this,tl);Ze(this,jd);Ze(this,Bd);Ne(this,Zt,t.queryCache||new gL),Ne(this,Ja,t.mutationCache||new dV),Ne(this,el,t.defaultOptions||{}),Ne(this,Ld,new Map),Ne(this,Fd,new Map),Ne(this,tl,0)}mount(){wg(this,tl)._++,Y(this,tl)===1&&(Ne(this,jd,WT.subscribe(async t=>{t&&(await this.resumePausedMutations(),Y(this,Zt).onFocus())})),Ne(this,Bd,iy.subscribe(async t=>{t&&(await this.resumePausedMutations(),Y(this,Zt).onOnline())})))}unmount(){var t,e;wg(this,tl)._--,Y(this,tl)===0&&((t=Y(this,jd))==null||t.call(this),Ne(this,jd,void 0),(e=Y(this,Bd))==null||e.call(this),Ne(this,Bd,void 0))}isFetching(t){return Y(this,Zt).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return Y(this,Ja).findAll({...t,status:"pending"}).length}getQueryData(t){var r;const e=this.defaultQueryOptions({queryKey:t});return(r=Y(this,Zt).get(e.queryHash))==null?void 0:r.state.data}ensureQueryData(t){const e=this.getQueryData(t.queryKey);if(e===void 0)return this.fetchQuery(t);{const r=this.defaultQueryOptions(t),n=Y(this,Zt).build(this,r);return t.revalidateIfStale&&n.isStaleByTime(xd(r.staleTime,n))&&this.prefetchQuery(r),Promise.resolve(e)}}getQueriesData(t){return Y(this,Zt).findAll(t).map(({queryKey:e,state:r})=>{const n=r.data;return[e,n]})}setQueryData(t,e,r){const n=this.defaultQueryOptions({queryKey:t}),i=Y(this,Zt).get(n.queryHash),s=i==null?void 0:i.state.data,o=eV(e,s);if(o!==void 0)return Y(this,Zt).build(this,n).setData(o,{...r,manual:!0})}setQueriesData(t,e,r){return Tr.batch(()=>Y(this,Zt).findAll(t).map(({queryKey:n})=>[n,this.setQueryData(n,e,r)]))}getQueryState(t){var r;const e=this.defaultQueryOptions({queryKey:t});return(r=Y(this,Zt).get(e.queryHash))==null?void 0:r.state}removeQueries(t){const e=Y(this,Zt);Tr.batch(()=>{e.findAll(t).forEach(r=>{e.remove(r)})})}resetQueries(t,e){const r=Y(this,Zt),n={type:"active",...t};return Tr.batch(()=>(r.findAll(t).forEach(i=>{i.reset()}),this.refetchQueries(n,e)))}cancelQueries(t={},e={}){const r={revert:!0,...e},n=Tr.batch(()=>Y(this,Zt).findAll(t).map(i=>i.cancel(r)));return Promise.all(n).then(Ii).catch(Ii)}invalidateQueries(t={},e={}){return Tr.batch(()=>{if(Y(this,Zt).findAll(t).forEach(n=>{n.invalidate()}),t.refetchType==="none")return Promise.resolve();const r={...t,type:t.refetchType??t.type??"active"};return this.refetchQueries(r,e)})}refetchQueries(t={},e){const r={...e,cancelRefetch:(e==null?void 0:e.cancelRefetch)??!0},n=Tr.batch(()=>Y(this,Zt).findAll(t).filter(i=>!i.isDisabled()).map(i=>{let s=i.fetch(void 0,r);return r.throwOnError||(s=s.catch(Ii)),i.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(n).then(Ii)}fetchQuery(t){const e=this.defaultQueryOptions(t);e.retry===void 0&&(e.retry=!1);const r=Y(this,Zt).build(this,e);return r.isStaleByTime(xd(e.staleTime,r))?r.fetch(e):Promise.resolve(r.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(Ii).catch(Ii)}fetchInfiniteQuery(t){return t.behavior=sy(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(Ii).catch(Ii)}ensureInfiniteQueryData(t){return t.behavior=sy(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return iy.isOnline()?Y(this,Ja).resumePausedMutations():Promise.resolve()}getQueryCache(){return Y(this,Zt)}getMutationCache(){return Y(this,Ja)}getDefaultOptions(){return Y(this,el)}setDefaultOptions(t){Ne(this,el,t)}setQueryDefaults(t,e){Y(this,Ld).set(tc(t),{queryKey:t,defaultOptions:e})}getQueryDefaults(t){const e=[...Y(this,Ld).values()];let r={};return e.forEach(n=>{Pp(t,n.queryKey)&&(r={...r,...n.defaultOptions})}),r}setMutationDefaults(t,e){Y(this,Fd).set(tc(t),{mutationKey:t,defaultOptions:e})}getMutationDefaults(t){const e=[...Y(this,Fd).values()];let r={};return e.forEach(n=>{Pp(t,n.mutationKey)&&(r={...r,...n.defaultOptions})}),r}defaultQueryOptions(t){if(t._defaulted)return t;const e={...Y(this,el).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return e.queryHash||(e.queryHash=VT(e.queryKey,e)),e.refetchOnReconnect===void 0&&(e.refetchOnReconnect=e.networkMode!=="always"),e.throwOnError===void 0&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),e.enabled!==!0&&e.queryFn===GT&&(e.enabled=!1),e}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...Y(this,el).mutations,...(t==null?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){Y(this,Zt).clear(),Y(this,Ja).clear()}},Zt=new WeakMap,Ja=new WeakMap,el=new WeakMap,Ld=new WeakMap,Fd=new WeakMap,tl=new WeakMap,jd=new WeakMap,Bd=new WeakMap,$k),Fn,vt,em,xn,Nu,Ud,rl,ro,tm,$d,zd,Lu,Fu,nl,Hd,Ct,bf,NS,LS,FS,jS,BS,US,$S,bL,zk,xL=(zk=class extends fh{constructor(e,r){super();Ze(this,Ct);Ze(this,Fn);Ze(this,vt);Ze(this,em);Ze(this,xn);Ze(this,Nu);Ze(this,Ud);Ze(this,rl);Ze(this,ro);Ze(this,tm);Ze(this,$d);Ze(this,zd);Ze(this,Lu);Ze(this,Fu);Ze(this,nl);Ze(this,Hd,new Set);this.options=r,Ne(this,Fn,e),Ne(this,ro,null),Ne(this,rl,OS()),this.options.experimental_prefetchInRender||Y(this,rl).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(r)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(Y(this,vt).addObserver(this),JI(Y(this,vt),this.options)?lt(this,Ct,bf).call(this):this.updateResult(),lt(this,Ct,jS).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return zS(Y(this,vt),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return zS(Y(this,vt),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,lt(this,Ct,BS).call(this),lt(this,Ct,US).call(this),Y(this,vt).removeObserver(this)}setOptions(e,r){const n=this.options,i=Y(this,vt);if(this.options=Y(this,Fn).defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof ps(this.options.enabled,Y(this,vt))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");lt(this,Ct,$S).call(this),Y(this,vt).setOptions(this.options),n._defaulted&&!ny(this.options,n)&&Y(this,Fn).getQueryCache().notify({type:"observerOptionsUpdated",query:Y(this,vt),observer:this});const s=this.hasListeners();s&&e3(Y(this,vt),i,this.options,n)&<(this,Ct,bf).call(this),this.updateResult(r),s&&(Y(this,vt)!==i||ps(this.options.enabled,Y(this,vt))!==ps(n.enabled,Y(this,vt))||xd(this.options.staleTime,Y(this,vt))!==xd(n.staleTime,Y(this,vt)))&<(this,Ct,NS).call(this);const o=lt(this,Ct,LS).call(this);s&&(Y(this,vt)!==i||ps(this.options.enabled,Y(this,vt))!==ps(n.enabled,Y(this,vt))||o!==Y(this,nl))&<(this,Ct,FS).call(this,o)}getOptimisticResult(e){const r=Y(this,Fn).getQueryCache().build(Y(this,Fn),e),n=this.createResult(r,e);return gV(this,n)&&(Ne(this,xn,n),Ne(this,Ud,this.options),Ne(this,Nu,Y(this,vt).state)),n}getCurrentResult(){return Y(this,xn)}trackResult(e,r){const n={};return Object.keys(e).forEach(i=>{Object.defineProperty(n,i,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(i),r==null||r(i),e[i])})}),n}trackProp(e){Y(this,Hd).add(e)}getCurrentQuery(){return Y(this,vt)}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const r=Y(this,Fn).defaultQueryOptions(e),n=Y(this,Fn).getQueryCache().build(Y(this,Fn),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(e){return lt(this,Ct,bf).call(this,{...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),Y(this,xn)))}createResult(e,r){var M;const n=Y(this,vt),i=this.options,s=Y(this,xn),o=Y(this,Nu),a=Y(this,Ud),u=e!==n?e.state:Y(this,em),{state:c}=e;let h={...c},f=!1,m;if(r._optimisticResults){const N=this.hasListeners(),z=!N&&JI(e,r),j=N&&e3(e,n,r,i);(z||j)&&(h={...h,...mL(c.data,e.options)}),r._optimisticResults==="isRestoring"&&(h.fetchStatus="idle")}let{error:y,errorUpdatedAt:v,status:x}=h;if(r.select&&h.data!==void 0)if(s&&h.data===(o==null?void 0:o.data)&&r.select===Y(this,tm))m=Y(this,$d);else try{Ne(this,tm,r.select),m=r.select(h.data),m=kS(s==null?void 0:s.data,m,r),Ne(this,$d,m),Ne(this,ro,null)}catch(N){Ne(this,ro,N)}else m=h.data;if(r.placeholderData!==void 0&&m===void 0&&x==="pending"){let N;if(s!=null&&s.isPlaceholderData&&r.placeholderData===(a==null?void 0:a.placeholderData))N=s.data;else if(N=typeof r.placeholderData=="function"?r.placeholderData((M=Y(this,zd))==null?void 0:M.state.data,Y(this,zd)):r.placeholderData,r.select&&N!==void 0)try{N=r.select(N),Ne(this,ro,null)}catch(z){Ne(this,ro,z)}N!==void 0&&(x="success",m=kS(s==null?void 0:s.data,N,r),f=!0)}Y(this,ro)&&(y=Y(this,ro),m=Y(this,$d),v=Date.now(),x="error");const b=h.fetchStatus==="fetching",_=x==="pending",w=x==="error",E=_&&b,A=m!==void 0,I={status:x,fetchStatus:h.fetchStatus,isPending:_,isSuccess:x==="success",isError:w,isInitialLoading:E,isLoading:E,data:m,dataUpdatedAt:h.dataUpdatedAt,error:y,errorUpdatedAt:v,failureCount:h.fetchFailureCount,failureReason:h.fetchFailureReason,errorUpdateCount:h.errorUpdateCount,isFetched:h.dataUpdateCount>0||h.errorUpdateCount>0,isFetchedAfterMount:h.dataUpdateCount>u.dataUpdateCount||h.errorUpdateCount>u.errorUpdateCount,isFetching:b,isRefetching:b&&!_,isLoadingError:w&&!A,isPaused:h.fetchStatus==="paused",isPlaceholderData:f,isRefetchError:w&&A,isStale:XT(e,r),refetch:this.refetch,promise:Y(this,rl)};if(this.options.experimental_prefetchInRender){const N=H=>{I.status==="error"?H.reject(I.error):I.data!==void 0&&H.resolve(I.data)},z=()=>{const H=Ne(this,rl,I.promise=OS());N(H)},j=Y(this,rl);switch(j.status){case"pending":e.queryHash===n.queryHash&&N(j);break;case"fulfilled":(I.status==="error"||I.data!==j.value)&&z();break;case"rejected":(I.status!=="error"||I.error!==j.reason)&&z();break}}return I}updateResult(e){const r=Y(this,xn),n=this.createResult(Y(this,vt),this.options);if(Ne(this,Nu,Y(this,vt).state),Ne(this,Ud,this.options),Y(this,Nu).data!==void 0&&Ne(this,zd,Y(this,vt)),ny(n,r))return;Ne(this,xn,n);const i={},s=()=>{if(!r)return!0;const{notifyOnChangeProps:o}=this.options,a=typeof o=="function"?o():o;if(a==="all"||!a&&!Y(this,Hd).size)return!0;const l=new Set(a??Y(this,Hd));return this.options.throwOnError&&l.add("error"),Object.keys(Y(this,xn)).some(u=>{const c=u;return Y(this,xn)[c]!==r[c]&&l.has(c)})};(e==null?void 0:e.listeners)!==!1&&s()&&(i.listeners=!0),lt(this,Ct,bL).call(this,{...i,...e})}onQueryUpdate(){this.updateResult(),this.hasListeners()&<(this,Ct,jS).call(this)}},Fn=new WeakMap,vt=new WeakMap,em=new WeakMap,xn=new WeakMap,Nu=new WeakMap,Ud=new WeakMap,rl=new WeakMap,ro=new WeakMap,tm=new WeakMap,$d=new WeakMap,zd=new WeakMap,Lu=new WeakMap,Fu=new WeakMap,nl=new WeakMap,Hd=new WeakMap,Ct=new WeakSet,bf=function(e){lt(this,Ct,$S).call(this);let r=Y(this,vt).fetch(this.options,e);return e!=null&&e.throwOnError||(r=r.catch(Ii)),r},NS=function(){lt(this,Ct,BS).call(this);const e=xd(this.options.staleTime,Y(this,vt));if(ec||Y(this,xn).isStale||!IS(e))return;const n=lL(Y(this,xn).dataUpdatedAt,e)+1;Ne(this,Lu,setTimeout(()=>{Y(this,xn).isStale||this.updateResult()},n))},LS=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(Y(this,vt)):this.options.refetchInterval)??!1},FS=function(e){lt(this,Ct,US).call(this),Ne(this,nl,e),!(ec||ps(this.options.enabled,Y(this,vt))===!1||!IS(Y(this,nl))||Y(this,nl)===0)&&Ne(this,Fu,setInterval(()=>{(this.options.refetchIntervalInBackground||WT.isFocused())&<(this,Ct,bf).call(this)},Y(this,nl)))},jS=function(){lt(this,Ct,NS).call(this),lt(this,Ct,FS).call(this,lt(this,Ct,LS).call(this))},BS=function(){Y(this,Lu)&&(clearTimeout(Y(this,Lu)),Ne(this,Lu,void 0))},US=function(){Y(this,Fu)&&(clearInterval(Y(this,Fu)),Ne(this,Fu,void 0))},$S=function(){const e=Y(this,Fn).getQueryCache().build(Y(this,Fn),this.options);if(e===Y(this,vt))return;const r=Y(this,vt);Ne(this,vt,e),Ne(this,em,e.state),this.hasListeners()&&(r==null||r.removeObserver(this),e.addObserver(this))},bL=function(e){Tr.batch(()=>{e.listeners&&this.listeners.forEach(r=>{r(Y(this,xn))}),Y(this,Fn).getQueryCache().notify({query:Y(this,vt),type:"observerResultsUpdated"})})},zk);function mV(t,e){return ps(e.enabled,t)!==!1&&t.state.data===void 0&&!(t.state.status==="error"&&e.retryOnMount===!1)}function JI(t,e){return mV(t,e)||t.state.data!==void 0&&zS(t,e,e.refetchOnMount)}function zS(t,e,r){if(ps(e.enabled,t)!==!1){const n=typeof r=="function"?r(t):r;return n==="always"||n!==!1&&XT(t,e)}return!1}function e3(t,e,r,n){return(t!==e||ps(n.enabled,t)===!1)&&(!r.suspense||t.state.status!=="error")&&XT(t,r)}function XT(t,e){return ps(e.enabled,t)!==!1&&t.isStaleByTime(xd(e.staleTime,t))}function gV(t,e){return!ny(t.getCurrentResult(),e)}var vV=class extends xL{constructor(t,e){super(t,e)}bindMethods(){super.bindMethods(),this.fetchNextPage=this.fetchNextPage.bind(this),this.fetchPreviousPage=this.fetchPreviousPage.bind(this)}setOptions(t,e){super.setOptions({...t,behavior:sy()},e)}getOptimisticResult(t){return t.behavior=sy(),super.getOptimisticResult(t)}fetchNextPage(t){return this.fetch({...t,meta:{fetchMore:{direction:"forward"}}})}fetchPreviousPage(t){return this.fetch({...t,meta:{fetchMore:{direction:"backward"}}})}createResult(t,e){var y,v;const{state:r}=t,n=super.createResult(t,e),{isFetching:i,isRefetching:s,isError:o,isRefetchError:a}=n,l=(v=(y=r.fetchMeta)==null?void 0:y.fetchMore)==null?void 0:v.direction,u=o&&l==="forward",c=i&&l==="forward",h=o&&l==="backward",f=i&&l==="backward";return{...n,fetchNextPage:this.fetchNextPage,fetchPreviousPage:this.fetchPreviousPage,hasNextPage:hV(e,r.data),hasPreviousPage:fV(e,r.data),isFetchNextPageError:u,isFetchingNextPage:c,isFetchPreviousPageError:h,isFetchingPreviousPage:f,isRefetchError:a&&!u&&!h,isRefetching:s&&!c&&!f}}},il,sl,jn,Yo,aa,Z0,HS,Hk,yV=(Hk=class extends fh{constructor(r,n){super();Ze(this,aa);Ze(this,il);Ze(this,sl);Ze(this,jn);Ze(this,Yo);Ne(this,il,r),this.setOptions(n),this.bindMethods(),lt(this,aa,Z0).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(r){var i;const n=this.options;this.options=Y(this,il).defaultMutationOptions(r),ny(this.options,n)||Y(this,il).getMutationCache().notify({type:"observerOptionsUpdated",mutation:Y(this,jn),observer:this}),n!=null&&n.mutationKey&&this.options.mutationKey&&tc(n.mutationKey)!==tc(this.options.mutationKey)?this.reset():((i=Y(this,jn))==null?void 0:i.state.status)==="pending"&&Y(this,jn).setOptions(this.options)}onUnsubscribe(){var r;this.hasListeners()||(r=Y(this,jn))==null||r.removeObserver(this)}onMutationUpdate(r){lt(this,aa,Z0).call(this),lt(this,aa,HS).call(this,r)}getCurrentResult(){return Y(this,sl)}reset(){var r;(r=Y(this,jn))==null||r.removeObserver(this),Ne(this,jn,void 0),lt(this,aa,Z0).call(this),lt(this,aa,HS).call(this)}mutate(r,n){var i;return Ne(this,Yo,n),(i=Y(this,jn))==null||i.removeObserver(this),Ne(this,jn,Y(this,il).getMutationCache().build(Y(this,il),this.options)),Y(this,jn).addObserver(this),Y(this,jn).execute(r)}},il=new WeakMap,sl=new WeakMap,jn=new WeakMap,Yo=new WeakMap,aa=new WeakSet,Z0=function(){var n;const r=((n=Y(this,jn))==null?void 0:n.state)??vL();Ne(this,sl,{...r,isPending:r.status==="pending",isSuccess:r.status==="success",isError:r.status==="error",isIdle:r.status==="idle",mutate:this.mutate,reset:this.reset})},HS=function(r){Tr.batch(()=>{var n,i,s,o,a,l,u,c;if(Y(this,Yo)&&this.hasListeners()){const h=Y(this,sl).variables,f=Y(this,sl).context;(r==null?void 0:r.type)==="success"?((i=(n=Y(this,Yo)).onSuccess)==null||i.call(n,r.data,h,f),(o=(s=Y(this,Yo)).onSettled)==null||o.call(s,r.data,null,h,f)):(r==null?void 0:r.type)==="error"&&((l=(a=Y(this,Yo)).onError)==null||l.call(a,r.error,h,f),(c=(u=Y(this,Yo)).onSettled)==null||c.call(u,void 0,r.error,h,f))}this.listeners.forEach(h=>{h(Y(this,sl))})})},Hk),wL=T.createContext(void 0),Jr=t=>{const e=T.useContext(wL);if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},xV=({client:t,children:e})=>(T.useEffect(()=>(t.mount(),()=>{t.unmount()}),[t]),g.jsx(wL.Provider,{value:t,children:e})),_L=T.createContext(!1),bV=()=>T.useContext(_L);_L.Provider;function wV(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}var _V=T.createContext(wV()),SV=()=>T.useContext(_V);function SL(t,e){return typeof t=="function"?t(...e):!!t}function VS(){}var EV=(t,e)=>{(t.suspense||t.throwOnError||t.experimental_prefetchInRender)&&(e.isReset()||(t.retryOnMount=!1))},TV=t=>{T.useEffect(()=>{t.clearReset()},[t])},CV=({result:t,errorResetBoundary:e,throwOnError:r,query:n})=>t.isError&&!e.isReset()&&!t.isFetching&&n&&SL(r,[t.error,n]),AV=t=>{t.suspense&&(t.staleTime===void 0&&(t.staleTime=1e3),typeof t.gcTime=="number"&&(t.gcTime=Math.max(t.gcTime,1e3)))},RV=(t,e)=>t.isLoading&&t.isFetching&&!e,PV=(t,e)=>(t==null?void 0:t.suspense)&&e.isPending,t3=(t,e,r)=>e.fetchOptimistic(t).catch(()=>{r.clearReset()});function EL(t,e,r){var c,h,f,m,y;const n=Jr(),i=bV(),s=SV(),o=n.defaultQueryOptions(t);(h=(c=n.getDefaultOptions().queries)==null?void 0:c._experimental_beforeQuery)==null||h.call(c,o),o._optimisticResults=i?"isRestoring":"optimistic",AV(o),EV(o,s),TV(s);const a=!n.getQueryCache().get(o.queryHash),[l]=T.useState(()=>new e(n,o)),u=l.getOptimisticResult(o);if(T.useSyncExternalStore(T.useCallback(v=>{const x=i?VS:l.subscribe(Tr.batchCalls(v));return l.updateResult(),x},[l,i]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),T.useEffect(()=>{l.setOptions(o,{listeners:!1})},[o,l]),PV(o,u))throw t3(o,l,s);if(CV({result:u,errorResetBoundary:s,throwOnError:o.throwOnError,query:n.getQueryCache().get(o.queryHash)}))throw u.error;if((m=(f=n.getDefaultOptions().queries)==null?void 0:f._experimental_afterQuery)==null||m.call(f,o,u),o.experimental_prefetchInRender&&!ec&&RV(u,i)){const v=a?t3(o,l,s):(y=n.getQueryCache().get(o.queryHash))==null?void 0:y.promise;v==null||v.catch(VS).finally(()=>{l.updateResult()})}return o.notifyOnChangeProps?u:l.trackResult(u)}function qT(t,e){return EL(t,xL)}function Mo(t,e){const r=Jr(),[n]=T.useState(()=>new yV(r,t));T.useEffect(()=>{n.setOptions(t)},[n,t]);const i=T.useSyncExternalStore(T.useCallback(o=>n.subscribe(Tr.batchCalls(o)),[n]),()=>n.getCurrentResult(),()=>n.getCurrentResult()),s=T.useCallback((o,a)=>{n.mutate(o,a).catch(VS)},[n]);if(i.error&&SL(n.options.throwOnError,[i.error]))throw i.error;return{...i,mutate:s,mutateAsync:i.mutate}}function IV(t,e){return EL(t,vV)}function MV({src:t,placeholder:e}){const[r,n]=T.useState(t||e),i=T.useCallback(()=>{n(e)},[e]);return T.useEffect(()=>{n(t)},[t]),{imgSrc:r,onError:i}}const kV=T.forwardRef((t,e)=>{const{isLoading:r,loadingIcon:n,loadingPosition:i="left",children:s,className:o,...a}=t,l=()=>{let c;return n?c=n:c=g.jsx(UN,{...a,"aria-label":"Loading"}),c},u=Re("loading d-flex align-items-center gap-8",{"is-loading":r},o);return g.jsxs("div",{className:u,role:"status",ref:e,children:[(!i||i==="left")&&l(),s,i==="right"&&l()]})}),YT=kV,OV=T.forwardRef(({color:t="primary",type:e="button",size:r="md",children:n,isLoading:i,loadingIcon:s,loadingPosition:o,leftIcon:a,rightIcon:l,className:u,variant:c="filled",...h},f)=>{const m=Re("btn",{[`btn-filled btn-${t}`]:c==="filled",[`btn-${c}-${t}`]:c==="outline"||c==="ghost","btn-icon":!n,"btn-loading":i,"btn-lg":r==="lg","btn-sm":r==="sm"},u);return g.jsx("button",{ref:f,className:m,type:e,...h,children:i?g.jsx(YT,{isLoading:!0,loadingIcon:s,loadingPosition:o,children:n}):g.jsxs("span",{children:[a,n,l]})})}),it=OV;function Pn(){return["./assets/themes/edifice-bootstrap/images","./assets/themes/edifice-bootstrap/icons","./assets/themes/edifice-bootstrap/fonts"]}function TL({appCode:t}){return qT({queryKey:["conf"],queryFn:async()=>await Me.conf().getConf(t)})}function DV(){return qT({queryKey:["session"],queryFn:async()=>await Me.session().getSession()})}const CL=T.createContext(null);function NV({children:t,params:e}){var r;const n=e.app,{t:i}=we(),s=i(n),o=DV(),a=TL({appCode:n}),l=(a==null?void 0:a.isSuccess)&&(o==null?void 0:o.isSuccess),u=((r=o==null?void 0:o.data)==null?void 0:r.currentLanguage)??"fr";T.useEffect(()=>{[{data:"html",value:u},{data:"translate",value:"no"}].forEach(h=>{var f;return(f=document.querySelector("html"))==null?void 0:f.setAttribute(h.data,h.value)})},[u,o.data]),T.useEffect(()=>{document.title=`${s}`},[n,o.data,s]);const c=T.useMemo(()=>{var h,f,m,y,v;return{appCode:n,applications:(h=a==null?void 0:a.data)==null?void 0:h.applications,confQuery:a,currentApp:(f=a==null?void 0:a.data)==null?void 0:f.currentApp,currentLanguage:u,init:l,sessionQuery:o,user:(m=o==null?void 0:o.data)==null?void 0:m.user,userDescription:(y=o==null?void 0:o.data)==null?void 0:y.userDescription,userProfile:(v=o==null?void 0:o.data)==null?void 0:v.userProfile}},[n,a,u,l,o]);return g.jsx(CL.Provider,{value:c,children:t})}function yt(){const t=T.useContext(CL);if(!t)throw new Error("Cannot be used outside of OdeClientProvider");return t}const LV=T.forwardRef(({src:t,alt:e,imgPlaceholder:r,ratio:n,objectFit:i,className:s,...o},a)=>{const[l]=Pn(),u=r??`${l}/common/image-placeholder.png`,{imgSrc:c,onError:h}=MV({src:t,placeholder:u}),f={"ratio ratio-1x1":n==="1","ratio ratio-4x3":n==="4","ratio ratio-16x9":n==="16","ratio ratio-21x9":n==="21"},m={"object-fit-contain":i==="contain","object-fit-cover":i==="cover","object-fit-fill":i==="fill","object-fit-scale":i==="scale","object-fit-none":i==="none"},y=Re({...f}),v=Re({...m},s),x=g.jsx("img",{alt:e,onError:h,ref:a,src:c,className:v,...o});return n?g.jsx("div",{className:y,children:x}):x}),wo=LV,FV=T.forwardRef(({variant:t="square",size:e="md",alt:r,src:n,imgPlaceholder:i,className:s,...o},a)=>{const[l]=Pn(),u=i||`${l}/avatar/no-avatar.svg`,c=Re("avatar",{"avatar-xs":e==="xs","avatar-sm":e==="sm","avatar-md":e==="md","avatar-lg":e==="lg","avatar-xl":e==="xl",square:t==="square",rounded:t==="rounded","rounded-circle":t==="circle"},s);return g.jsx("div",{ref:a,className:c,children:g.jsx(wo,{src:n||u,alt:r,imgPlaceholder:u,...o})})}),rc=FV,jV=T.forwardRef(({className:t,variant:e={type:"notification",level:"info"},children:r,...n},i)=>{const s=Re("badge rounded-pill",(e.type==="content"||e.type==="user")&&"background"in e?"bg-gray-200":(e.type==="content"||e.type==="user")&&!("background"in e)?"border border-0":"",e.type==="content"&&`text-${e.level}`,e.type==="notification"&&`badge-notification bg-${e.level} text-light border border-0`,e.type==="user"&&`badge-profile-${e.profile.toLowerCase()}`,e.type==="link"&&"badge-link border border-0",e.type==="chip"&&"bg-gray-200",t);return g.jsx("span",{ref:i,className:s,...n,children:e.type==="chip"?g.jsx("div",{className:"d-flex fw-800 align-items-center",children:r}):r})}),ow=jV,BV=T.forwardRef(({level:t="h1",headingStyle:e="h1",children:r,className:n,...i},s)=>{const o=Re(e,n);return g.jsx(t,{ref:s,className:o,...i,children:r})}),Ss=BV,UV=({imageSrc:t,imageAlt:e="",title:r,text:n,size:i=250,className:s})=>{const o=Re("text",s);return g.jsxs("div",{className:"emptyscreen",children:[t&&g.jsx("div",{className:"emptyscreen-image mb-12",children:g.jsx("img",{className:"mx-auto",src:t,alt:e,width:i,height:i})}),r&&g.jsx(Ss,{level:"h2",headingStyle:"h2",className:"text-secondary mb-8",children:r}),n&&g.jsx("div",{className:o,children:n})]})},ha=UV;var jl=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function QT(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var AL={exports:{}};(function(t,e){(function(r,n){t.exports=n()})(jl,function(){var r={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},n=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,i=/\d\d/,s=/\d\d?/,o=/\d*[^-_:/,()\s\d]+/,a={},l=function(v){return(v=+v)+(v>68?1900:2e3)},u=function(v){return function(x){this[v]=+x}},c=[/[+-]\d\d:?(\d\d)?|Z/,function(v){(this.zone||(this.zone={})).offset=function(x){if(!x||x==="Z")return 0;var b=x.match(/([+-]|\d\d)/g),_=60*b[1]+(+b[2]||0);return _===0?0:b[0]==="+"?-_:_}(v)}],h=function(v){var x=a[v];return x&&(x.indexOf?x:x.s.concat(x.f))},f=function(v,x){var b,_=a.meridiem;if(_){for(var w=1;w<=24;w+=1)if(v.indexOf(_(w,0,x))>-1){b=w>12;break}}else b=v===(x?"pm":"PM");return b},m={A:[o,function(v){this.afternoon=f(v,!1)}],a:[o,function(v){this.afternoon=f(v,!0)}],S:[/\d/,function(v){this.milliseconds=100*+v}],SS:[i,function(v){this.milliseconds=10*+v}],SSS:[/\d{3}/,function(v){this.milliseconds=+v}],s:[s,u("seconds")],ss:[s,u("seconds")],m:[s,u("minutes")],mm:[s,u("minutes")],H:[s,u("hours")],h:[s,u("hours")],HH:[s,u("hours")],hh:[s,u("hours")],D:[s,u("day")],DD:[i,u("day")],Do:[o,function(v){var x=a.ordinal,b=v.match(/\d+/);if(this.day=b[0],x)for(var _=1;_<=31;_+=1)x(_).replace(/\[|\]/g,"")===v&&(this.day=_)}],M:[s,u("month")],MM:[i,u("month")],MMM:[o,function(v){var x=h("months"),b=(h("monthsShort")||x.map(function(_){return _.slice(0,3)})).indexOf(v)+1;if(b<1)throw new Error;this.month=b%12||b}],MMMM:[o,function(v){var x=h("months").indexOf(v)+1;if(x<1)throw new Error;this.month=x%12||x}],Y:[/[+-]?\d+/,u("year")],YY:[i,function(v){this.year=l(v)}],YYYY:[/\d{4}/,u("year")],Z:c,ZZ:c};function y(v){var x,b;x=v,b=a&&a.formats;for(var _=(v=x.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(N,z,j){var H=j&&j.toUpperCase();return z||b[j]||r[j]||b[H].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(F,L,O){return L||O.slice(1)})})).match(n),w=_.length,E=0;E<w;E+=1){var A=_[E],P=m[A],I=P&&P[0],M=P&&P[1];_[E]=M?{regex:I,parser:M}:A.replace(/^\[|\]$/g,"")}return function(N){for(var z={},j=0,H=0;j<w;j+=1){var F=_[j];if(typeof F=="string")H+=F.length;else{var L=F.regex,O=F.parser,$=N.slice(H),V=L.exec($)[0];O.call(z,V),N=N.replace(V,"")}}return function(k){var U=k.afternoon;if(U!==void 0){var B=k.hours;U?B<12&&(k.hours+=12):B===12&&(k.hours=0),delete k.afternoon}}(z),z}}return function(v,x,b){b.p.customParseFormat=!0,v&&v.parseTwoDigitYear&&(l=v.parseTwoDigitYear);var _=x.prototype,w=_.parse;_.parse=function(E){var A=E.date,P=E.utc,I=E.args;this.$u=P;var M=I[1];if(typeof M=="string"){var N=I[2]===!0,z=I[3]===!0,j=N||z,H=I[2];z&&(H=I[2]),a=this.$locale(),!N&&H&&(a=b.Ls[H]),this.$d=function($,V,k){try{if(["x","X"].indexOf(V)>-1)return new Date((V==="X"?1e3:1)*$);var U=y(V)($),B=U.year,X=U.month,K=U.day,q=U.hours,re=U.minutes,ue=U.seconds,le=U.milliseconds,me=U.zone,xe=new Date,_e=K||(B||X?1:xe.getDate()),Te=B||xe.getFullYear(),de=0;B&&!X||(de=X>0?X-1:xe.getMonth());var Be=q||0,je=re||0,ut=ue||0,Pe=le||0;return me?new Date(Date.UTC(Te,de,_e,Be,je,ut,Pe+60*me.offset*1e3)):k?new Date(Date.UTC(Te,de,_e,Be,je,ut,Pe)):new Date(Te,de,_e,Be,je,ut,Pe)}catch{return new Date("")}}(A,M,P),this.init(),H&&H!==!0&&(this.$L=this.locale(H).$L),j&&A!=this.format(M)&&(this.$d=new Date("")),a={}}else if(M instanceof Array)for(var F=M.length,L=1;L<=F;L+=1){I[1]=M[L-1];var O=b.apply(this,I);if(O.isValid()){this.$d=O.$d,this.$L=O.$L,this.init();break}L===F&&(this.$d=new Date(""))}else w.call(this,E)}}})})(AL);var $V=AL.exports;const zV=QT($V);var RL={exports:{}};(function(t,e){(function(r,n){t.exports=n()})(jl,function(){var r={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(n,i,s){var o=i.prototype,a=o.format;s.en.formats=r,o.format=function(l){l===void 0&&(l="YYYY-MM-DDTHH:mm:ssZ");var u=this.$locale().formats,c=function(h,f){return h.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(m,y,v){var x=v&&v.toUpperCase();return y||f[v]||r[v]||f[x].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(b,_,w){return _||w.slice(1)})})}(l,u===void 0?{}:u);return a.call(this,c)}}})})(RL);var HV=RL.exports;const VV=QT(HV);var PL={exports:{}};(function(t,e){(function(r,n){t.exports=n()})(jl,function(){return function(r,n,i){r=r||{};var s=n.prototype,o={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function a(u,c,h,f){return s.fromToBase(u,c,h,f)}i.en.relativeTime=o,s.fromToBase=function(u,c,h,f,m){for(var y,v,x,b=h.$locale().relativeTime||o,_=r.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],w=_.length,E=0;E<w;E+=1){var A=_[E];A.d&&(y=f?i(u).diff(h,A.d,!0):h.diff(u,A.d,!0));var P=(r.rounding||Math.round)(Math.abs(y));if(x=y>0,P<=A.r||!A.r){P<=1&&E>0&&(A=_[E-1]);var I=b[A.l];m&&(P=m(""+P)),v=typeof I=="string"?I.replace("%d",P):I(P,c,A.l,x);break}}if(c)return v;var M=x?b.future:b.past;return typeof M=="function"?M(v):M.replace("%s",v)},s.to=function(u,c){return a(u,c,this,!0)},s.from=function(u,c){return a(u,c,this)};var l=function(u){return u.$u?i.utc():i()};s.toNow=function(u){return this.to(l(this),u)},s.fromNow=function(u){return this.from(l(this),u)}}})})(PL);var GV=PL.exports;const WV=QT(GV);var XV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(l){return l&&typeof l=="object"&&"default"in l?l:{default:l}}var i=n(r),s={s:"ein paar Sekunden",m:["eine Minute","einer Minute"],mm:"%d Minuten",h:["eine Stunde","einer Stunde"],hh:"%d Stunden",d:["ein Tag","einem Tag"],dd:["%d Tage","%d Tagen"],M:["ein Monat","einem Monat"],MM:["%d Monate","%d Monaten"],y:["ein Jahr","einem Jahr"],yy:["%d Jahre","%d Jahren"]};function o(l,u,c){var h=s[c];return Array.isArray(h)&&(h=h[u?0:1]),h.replace("%d",l)}var a={name:"de",weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sept._Okt._Nov._Dez.".split("_"),ordinal:function(l){return l+"."},weekStart:1,yearStart:4,formats:{LTS:"HH:mm:ss",LT:"HH:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},relativeTime:{future:"in %s",past:"vor %s",s:o,m:o,mm:o,h:o,hh:o,d:o,dd:o,M:o,MM:o,y:o,yy:o}};return i.default.locale(a,null,!0),a})})(XV);var qV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(o){return o&&typeof o=="object"&&"default"in o?o:{default:o}}var i=n(r),s={name:"es",monthsShort:"ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),weekStart:1,formats:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},ordinal:function(o){return o+"º"}};return i.default.locale(s,null,!0),s})})(qV);var YV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(o){return o&&typeof o=="object"&&"default"in o?o:{default:o}}var i=n(r),s={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(o){return""+o+(o===1?"er":"")}};return i.default.locale(s,null,!0),s})})(YV);var QV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(o){return o&&typeof o=="object"&&"default"in o?o:{default:o}}var i=n(r),s={name:"it",weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),weekStart:1,monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"tra %s",past:"%s fa",s:"qualche secondo",m:"un minuto",mm:"%d minuti",h:"un' ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},ordinal:function(o){return o+"º"}};return i.default.locale(s,null,!0),s})})(QV);var KV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(o){return o&&typeof o=="object"&&"default"in o?o:{default:o}}var i=n(r),s={name:"pt",weekdays:"domingo_segunda-feira_terça-feira_quarta-feira_quinta-feira_sexta-feira_sábado".split("_"),weekdaysShort:"dom_seg_ter_qua_qui_sex_sab".split("_"),weekdaysMin:"Do_2ª_3ª_4ª_5ª_6ª_Sa".split("_"),months:"janeiro_fevereiro_março_abril_maio_junho_julho_agosto_setembro_outubro_novembro_dezembro".split("_"),monthsShort:"jan_fev_mar_abr_mai_jun_jul_ago_set_out_nov_dez".split("_"),ordinal:function(o){return o+"º"},weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY [às] HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY [às] HH:mm"},relativeTime:{future:"em %s",past:"há %s",s:"alguns segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"}};return i.default.locale(s,null,!0),s})})(KV);Lr.extend(WV);Lr.extend(zV);Lr.extend(VV);function IL(){const{currentLanguage:t}=yt(),e=T.useCallback((i,s)=>{if(i.length<11)return Lr(i,["YYYY-MM-DD"],s);if(i.split("").findIndex(o=>"0">o||o>"9")<0)return Lr(Number.parseInt(i)).locale(t);{let o=Lr(i).locale(t);return o.isValid()||(o=Lr(i,["YYYY-MM-DD HH:mm:ss.SSS"]).locale(t)),o}},[t]),r=T.useCallback(i=>{let s=Lr();try{return typeof i>"u"?"":(typeof i=="string"?s=e(i):typeof i=="number"?s=Lr(i).locale(t):typeof i.$date=="number"?s=Lr(new Date(i.$date)).locale(t):typeof i.$date=="string"&&(s=e(i.$date)),s.isValid()?s.fromNow():"")}catch{return""}},[t,e]),n=T.useCallback((i,s="short")=>{let o=Lr();try{if(typeof i>"u")return"";typeof i=="string"?o=e(i):typeof i=="number"?o=Lr(i).locale(t):typeof i.$date=="number"?o=Lr(new Date(i.$date)).locale(t):typeof i.$date=="string"&&(o=e(i.$date));let a="";switch(s){case"short":a="L";break;case"long":a="LL";break;case"abbr":a="ll";break;default:a=s}return o.isValid()?o.locale(t).format(a):""}catch{return""}},[t,e]);return{fromNow:r,formatDate:n}}let ZV={data:""},JV=t=>typeof window=="object"?((t?t.querySelector("#_goober"):window._goober)||Object.assign((t||document.head).appendChild(document.createElement("style")),{innerHTML:" ",id:"_goober"})).firstChild:t||ZV,eG=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,tG=/\/\*[^]*?\*\/| +/g,r3=/\n+/g,Ya=(t,e)=>{let r="",n="",i="";for(let s in t){let o=t[s];s[0]=="@"?s[1]=="i"?r=s+" "+o+";":n+=s[1]=="f"?Ya(o,s):s+"{"+Ya(o,s[1]=="k"?"":e)+"}":typeof o=="object"?n+=Ya(o,e?e.replace(/([^,])+/g,a=>s.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,l=>/&/.test(l)?l.replace(/&/g,a):a?a+" "+l:l)):s):o!=null&&(s=/^--/.test(s)?s:s.replace(/[A-Z]/g,"-$&").toLowerCase(),i+=Ya.p?Ya.p(s,o):s+":"+o+";")}return r+(e&&i?e+"{"+i+"}":i)+n},Bo={},ML=t=>{if(typeof t=="object"){let e="";for(let r in t)e+=r+ML(t[r]);return e}return t},rG=(t,e,r,n,i)=>{let s=ML(t),o=Bo[s]||(Bo[s]=(l=>{let u=0,c=11;for(;u<l.length;)c=101*c+l.charCodeAt(u++)>>>0;return"go"+c})(s));if(!Bo[o]){let l=s!==t?t:(u=>{let c,h,f=[{}];for(;c=eG.exec(u.replace(tG,""));)c[4]?f.shift():c[3]?(h=c[3].replace(r3," ").trim(),f.unshift(f[0][h]=f[0][h]||{})):f[0][c[1]]=c[2].replace(r3," ").trim();return f[0]})(t);Bo[o]=Ya(i?{["@keyframes "+o]:l}:l,r?"":"."+o)}let a=r&&Bo.g?Bo.g:null;return r&&(Bo.g=Bo[o]),((l,u,c,h)=>{h?u.data=u.data.replace(h,l):u.data.indexOf(l)===-1&&(u.data=c?l+u.data:u.data+l)})(Bo[o],e,n,a),o},nG=(t,e,r)=>t.reduce((n,i,s)=>{let o=e[s];if(o&&o.call){let a=o(r),l=a&&a.props&&a.props.className||/^go/.test(a)&&a;o=l?"."+l:a&&typeof a=="object"?a.props?"":Ya(a,""):a===!1?"":a}return n+i+(o??"")},"");function g1(t){let e=this||{},r=t.call?t(e.p):t;return rG(r.unshift?r.raw?nG(r,[].slice.call(arguments,1),e.p):r.reduce((n,i)=>Object.assign(n,i&&i.call?i(e.p):i),{}):r,JV(e.target),e.g,e.o,e.k)}let kL,GS,WS;g1.bind({g:1});let fa=g1.bind({k:1});function iG(t,e,r,n){Ya.p=e,kL=t,GS=r,WS=n}function Bl(t,e){let r=this||{};return function(){let n=arguments;function i(s,o){let a=Object.assign({},s),l=a.className||i.className;r.p=Object.assign({theme:GS&&GS()},a),r.o=/ *go\d+/.test(l),a.className=g1.apply(r,n)+(l?" "+l:"");let u=t;return t[0]&&(u=a.as||t,delete a.as),WS&&u[0]&&WS(a),kL(u,a)}return i}}var sG=t=>typeof t=="function",oy=(t,e)=>sG(t)?t(e):t,oG=(()=>{let t=0;return()=>(++t).toString()})(),OL=(()=>{let t;return()=>{if(t===void 0&&typeof window<"u"){let e=matchMedia("(prefers-reduced-motion: reduce)");t=!e||e.matches}return t}})(),aG=20,J0=new Map,lG=1e3,n3=t=>{if(J0.has(t))return;let e=setTimeout(()=>{J0.delete(t),cc({type:4,toastId:t})},lG);J0.set(t,e)},uG=t=>{let e=J0.get(t);e&&clearTimeout(e)},XS=(t,e)=>{switch(e.type){case 0:return{...t,toasts:[e.toast,...t.toasts].slice(0,aG)};case 1:return e.toast.id&&uG(e.toast.id),{...t,toasts:t.toasts.map(s=>s.id===e.toast.id?{...s,...e.toast}:s)};case 2:let{toast:r}=e;return t.toasts.find(s=>s.id===r.id)?XS(t,{type:1,toast:r}):XS(t,{type:0,toast:r});case 3:let{toastId:n}=e;return n?n3(n):t.toasts.forEach(s=>{n3(s.id)}),{...t,toasts:t.toasts.map(s=>s.id===n||n===void 0?{...s,visible:!1}:s)};case 4:return e.toastId===void 0?{...t,toasts:[]}:{...t,toasts:t.toasts.filter(s=>s.id!==e.toastId)};case 5:return{...t,pausedAt:e.time};case 6:let i=e.time-(t.pausedAt||0);return{...t,pausedAt:void 0,toasts:t.toasts.map(s=>({...s,pauseDuration:s.pauseDuration+i}))}}},ev=[],tv={toasts:[],pausedAt:void 0},cc=t=>{tv=XS(tv,t),ev.forEach(e=>{e(tv)})},cG={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},dG=(t={})=>{let[e,r]=T.useState(tv);T.useEffect(()=>(ev.push(r),()=>{let i=ev.indexOf(r);i>-1&&ev.splice(i,1)}),[e]);let n=e.toasts.map(i=>{var s,o;return{...t,...t[i.type],...i,duration:i.duration||((s=t[i.type])==null?void 0:s.duration)||(t==null?void 0:t.duration)||cG[i.type],style:{...t.style,...(o=t[i.type])==null?void 0:o.style,...i.style}}});return{...e,toasts:n}},hG=(t,e="blank",r)=>({createdAt:Date.now(),visible:!0,type:e,ariaProps:{role:"status","aria-live":"polite"},message:t,pauseDuration:0,...r,id:(r==null?void 0:r.id)||oG()}),cm=t=>(e,r)=>{let n=hG(e,t,r);return cc({type:2,toast:n}),n.id},di=(t,e)=>cm("blank")(t,e);di.error=cm("error");di.success=cm("success");di.loading=cm("loading");di.custom=cm("custom");di.dismiss=t=>{cc({type:3,toastId:t})};di.remove=t=>cc({type:4,toastId:t});di.promise=(t,e,r)=>{let n=di.loading(e.loading,{...r,...r==null?void 0:r.loading});return t.then(i=>(di.success(oy(e.success,i),{id:n,...r,...r==null?void 0:r.success}),i)).catch(i=>{di.error(oy(e.error,i),{id:n,...r,...r==null?void 0:r.error})}),t};var fG=(t,e)=>{cc({type:1,toast:{id:t,height:e}})},pG=()=>{cc({type:5,time:Date.now()})},mG=t=>{let{toasts:e,pausedAt:r}=dG(t);T.useEffect(()=>{if(r)return;let s=Date.now(),o=e.map(a=>{if(a.duration===1/0)return;let l=(a.duration||0)+a.pauseDuration-(s-a.createdAt);if(l<0){a.visible&&di.dismiss(a.id);return}return setTimeout(()=>di.dismiss(a.id),l)});return()=>{o.forEach(a=>a&&clearTimeout(a))}},[e,r]);let n=T.useCallback(()=>{r&&cc({type:6,time:Date.now()})},[r]),i=T.useCallback((s,o)=>{let{reverseOrder:a=!1,gutter:l=8,defaultPosition:u}=o||{},c=e.filter(m=>(m.position||u)===(s.position||u)&&m.height),h=c.findIndex(m=>m.id===s.id),f=c.filter((m,y)=>y<h&&m.visible).length;return c.filter(m=>m.visible).slice(...a?[f+1]:[0,f]).reduce((m,y)=>m+(y.height||0)+l,0)},[e]);return{toasts:e,handlers:{updateHeight:fG,startPause:pG,endPause:n,calculateOffset:i}}},gG=fa`
|
|
41
|
+
`+s.stack}return{value:t,source:e,stack:i,digest:null}}function qb(t,e,r){return{value:t,source:null,stack:r??null,digest:e??null}}function cS(t,e){try{console.error(e.value)}catch(r){setTimeout(function(){throw r})}}var jU=typeof WeakMap=="function"?WeakMap:Map;function GD(t,e,r){r=na(-1,r),r.tag=3,r.payload={element:null};var n=e.value;return r.callback=function(){Vv||(Vv=!0,bS=n),cS(t,e)},r}function WD(t,e,r){r=na(-1,r),r.tag=3;var n=t.type.getDerivedStateFromError;if(typeof n=="function"){var i=e.value;r.payload=function(){return n(i)},r.callback=function(){cS(t,e)}}var s=t.stateNode;return s!==null&&typeof s.componentDidCatch=="function"&&(r.callback=function(){cS(t,e),typeof n!="function"&&(wl===null?wl=new Set([this]):wl.add(this));var o=e.stack;this.componentDidCatch(e.value,{componentStack:o!==null?o:""})}),r}function hI(t,e,r){var n=t.pingCache;if(n===null){n=t.pingCache=new jU;var i=new Set;n.set(e,i)}else i=n.get(e),i===void 0&&(i=new Set,n.set(e,i));i.has(r)||(i.add(r),t=ZU.bind(null,t,e,r),e.then(t,t))}function fI(t){do{var e;if((e=t.tag===13)&&(e=t.memoizedState,e=e!==null?e.dehydrated!==null:!0),e)return t;t=t.return}while(t!==null);return null}function pI(t,e,r,n,i){return t.mode&1?(t.flags|=65536,t.lanes=i,t):(t===e?t.flags|=65536:(t.flags|=128,r.flags|=131072,r.flags&=-52805,r.tag===1&&(r.alternate===null?r.tag=17:(e=na(-1,1),e.tag=2,bl(r,e,1))),r.lanes|=1),t)}var BU=xa.ReactCurrentOwner,Hn=!1;function bn(t,e,r,n){e.child=t===null?wD(e,null,r,n):Xd(e,t.child,r,n)}function mI(t,e,r,n,i){r=r.render;var s=e.ref;return gd(e,i),n=dT(t,e,r,n,s,i),r=hT(),t!==null&&!Hn?(e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~i,da(t,e,i)):(zt&&r&&J2(e),e.flags|=1,bn(t,e,n,i),e.child)}function gI(t,e,r,n,i){if(t===null){var s=r.type;return typeof s=="function"&&!_T(s)&&s.defaultProps===void 0&&r.compare===null&&r.defaultProps===void 0?(e.tag=15,e.type=s,XD(t,e,s,n,i)):(t=q0(r.type,null,n,e,e.mode,i),t.ref=e.ref,t.return=e,e.child=t)}if(s=t.child,!(t.lanes&i)){var o=s.memoizedProps;if(r=r.compare,r=r!==null?r:mp,r(o,n)&&t.ref===e.ref)return da(t,e,i)}return e.flags|=1,t=Sl(s,n),t.ref=e.ref,t.return=e,e.child=t}function XD(t,e,r,n,i){if(t!==null){var s=t.memoizedProps;if(mp(s,n)&&t.ref===e.ref)if(Hn=!1,e.pendingProps=n=s,(t.lanes&i)!==0)t.flags&131072&&(Hn=!0);else return e.lanes=t.lanes,da(t,e,i)}return dS(t,e,r,n,i)}function qD(t,e,r){var n=e.pendingProps,i=n.children,s=t!==null?t.memoizedState:null;if(n.mode==="hidden")if(!(e.mode&1))e.memoizedState={baseLanes:0,cachePool:null,transitions:null},Mt(od,li),li|=r;else{if(!(r&1073741824))return t=s!==null?s.baseLanes|r:r,e.lanes=e.childLanes=1073741824,e.memoizedState={baseLanes:t,cachePool:null,transitions:null},e.updateQueue=null,Mt(od,li),li|=t,null;e.memoizedState={baseLanes:0,cachePool:null,transitions:null},n=s!==null?s.baseLanes:r,Mt(od,li),li|=n}else s!==null?(n=s.baseLanes|r,e.memoizedState=null):n=r,Mt(od,li),li|=n;return bn(t,e,i,r),e.child}function YD(t,e){var r=e.ref;(t===null&&r!==null||t!==null&&t.ref!==r)&&(e.flags|=512,e.flags|=2097152)}function dS(t,e,r,n,i){var s=Wn(r)?Xu:hn.current;return s=Gd(e,s),gd(e,i),r=dT(t,e,r,n,s,i),n=hT(),t!==null&&!Hn?(e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~i,da(t,e,i)):(zt&&n&&J2(e),e.flags|=1,bn(t,e,r,i),e.child)}function vI(t,e,r,n,i){if(Wn(r)){var s=!0;Dv(e)}else s=!1;if(gd(e,i),e.stateNode===null)G0(t,e),VD(e,r,n),uS(e,r,n,i),n=!0;else if(t===null){var o=e.stateNode,a=e.memoizedProps;o.props=a;var l=o.context,u=r.contextType;typeof u=="object"&&u!==null?u=Xi(u):(u=Wn(r)?Xu:hn.current,u=Gd(e,u));var c=r.getDerivedStateFromProps,h=typeof c=="function"||typeof o.getSnapshotBeforeUpdate=="function";h||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==n||l!==u)&&dI(e,o,n,u),Ha=!1;var f=e.memoizedState;o.state=f,Bv(e,n,o,i),l=e.memoizedState,a!==n||f!==l||Gn.current||Ha?(typeof c=="function"&&(lS(e,r,c,n),l=e.memoizedState),(a=Ha||cI(e,r,a,n,f,l,u))?(h||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(e.flags|=4194308)):(typeof o.componentDidMount=="function"&&(e.flags|=4194308),e.memoizedProps=n,e.memoizedState=l),o.props=n,o.state=l,o.context=u,n=a):(typeof o.componentDidMount=="function"&&(e.flags|=4194308),n=!1)}else{o=e.stateNode,SD(t,e),a=e.memoizedProps,u=e.type===e.elementType?a:cs(e.type,a),o.props=u,h=e.pendingProps,f=o.context,l=r.contextType,typeof l=="object"&&l!==null?l=Xi(l):(l=Wn(r)?Xu:hn.current,l=Gd(e,l));var m=r.getDerivedStateFromProps;(c=typeof m=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==h||f!==l)&&dI(e,o,n,l),Ha=!1,f=e.memoizedState,o.state=f,Bv(e,n,o,i);var y=e.memoizedState;a!==h||f!==y||Gn.current||Ha?(typeof m=="function"&&(lS(e,r,m,n),y=e.memoizedState),(u=Ha||cI(e,r,u,n,f,y,l)||!1)?(c||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(n,y,l),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(n,y,l)),typeof o.componentDidUpdate=="function"&&(e.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(e.flags|=1024)):(typeof o.componentDidUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),e.memoizedProps=n,e.memoizedState=y),o.props=n,o.state=y,o.context=l,n=u):(typeof o.componentDidUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===t.memoizedProps&&f===t.memoizedState||(e.flags|=1024),n=!1)}return hS(t,e,r,n,s,i)}function hS(t,e,r,n,i,s){YD(t,e);var o=(e.flags&128)!==0;if(!n&&!o)return i&&rI(e,r,!1),da(t,e,s);n=e.stateNode,BU.current=e;var a=o&&typeof r.getDerivedStateFromError!="function"?null:n.render();return e.flags|=1,t!==null&&o?(e.child=Xd(e,t.child,null,s),e.child=Xd(e,null,a,s)):bn(t,e,a,s),e.memoizedState=n.state,i&&rI(e,r,!0),e.child}function QD(t){var e=t.stateNode;e.pendingContext?tI(t,e.pendingContext,e.pendingContext!==e.context):e.context&&tI(t,e.context,!1),aT(t,e.containerInfo)}function yI(t,e,r,n,i){return Wd(),tT(i),e.flags|=256,bn(t,e,r,n),e.child}var fS={dehydrated:null,treeContext:null,retryLane:0};function pS(t){return{baseLanes:t,cachePool:null,transitions:null}}function KD(t,e,r){var n=e.pendingProps,i=Wt.current,s=!1,o=(e.flags&128)!==0,a;if((a=o)||(a=t!==null&&t.memoizedState===null?!1:(i&2)!==0),a?(s=!0,e.flags&=-129):(t===null||t.memoizedState!==null)&&(i|=1),Mt(Wt,i&1),t===null)return oS(e),t=e.memoizedState,t!==null&&(t=t.dehydrated,t!==null)?(e.mode&1?t.data==="$!"?e.lanes=8:e.lanes=1073741824:e.lanes=1,null):(o=n.children,t=n.fallback,s?(n=e.mode,s=e.child,o={mode:"hidden",children:o},!(n&1)&&s!==null?(s.childLanes=0,s.pendingProps=o):s=n1(o,n,0,null),t=Bu(t,n,r,null),s.return=e,t.return=e,s.sibling=t,e.child=s,e.child.memoizedState=pS(r),e.memoizedState=fS,t):mT(e,o));if(i=t.memoizedState,i!==null&&(a=i.dehydrated,a!==null))return UU(t,e,o,n,a,i,r);if(s){s=n.fallback,o=e.mode,i=t.child,a=i.sibling;var l={mode:"hidden",children:n.children};return!(o&1)&&e.child!==i?(n=e.child,n.childLanes=0,n.pendingProps=l,e.deletions=null):(n=Sl(i,l),n.subtreeFlags=i.subtreeFlags&14680064),a!==null?s=Sl(a,s):(s=Bu(s,o,r,null),s.flags|=2),s.return=e,n.return=e,n.sibling=s,e.child=n,n=s,s=e.child,o=t.child.memoizedState,o=o===null?pS(r):{baseLanes:o.baseLanes|r,cachePool:null,transitions:o.transitions},s.memoizedState=o,s.childLanes=t.childLanes&~r,e.memoizedState=fS,n}return s=t.child,t=s.sibling,n=Sl(s,{mode:"visible",children:n.children}),!(e.mode&1)&&(n.lanes=r),n.return=e,n.sibling=null,t!==null&&(r=e.deletions,r===null?(e.deletions=[t],e.flags|=16):r.push(t)),e.child=n,e.memoizedState=null,n}function mT(t,e){return e=n1({mode:"visible",children:e},t.mode,0,null),e.return=t,t.child=e}function Fg(t,e,r,n){return n!==null&&tT(n),Xd(e,t.child,null,r),t=mT(e,e.pendingProps.children),t.flags|=2,e.memoizedState=null,t}function UU(t,e,r,n,i,s,o){if(r)return e.flags&256?(e.flags&=-257,n=qb(Error(pe(422))),Fg(t,e,o,n)):e.memoizedState!==null?(e.child=t.child,e.flags|=128,null):(s=n.fallback,i=e.mode,n=n1({mode:"visible",children:n.children},i,0,null),s=Bu(s,i,o,null),s.flags|=2,n.return=e,s.return=e,n.sibling=s,e.child=n,e.mode&1&&Xd(e,t.child,null,o),e.child.memoizedState=pS(o),e.memoizedState=fS,s);if(!(e.mode&1))return Fg(t,e,o,null);if(i.data==="$!"){if(n=i.nextSibling&&i.nextSibling.dataset,n)var a=n.dgst;return n=a,s=Error(pe(419)),n=qb(s,n,void 0),Fg(t,e,o,n)}if(a=(o&t.childLanes)!==0,Hn||a){if(n=$r,n!==null){switch(o&-o){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(n.suspendedLanes|o)?0:i,i!==0&&i!==s.retryLane&&(s.retryLane=i,ca(t,i),_s(n,t,i,-1))}return wT(),n=qb(Error(pe(421))),Fg(t,e,o,n)}return i.data==="$?"?(e.flags|=128,e.child=t.child,e=JU.bind(null,t),i._reactRetry=e,null):(t=s.treeContext,ci=xl(i.nextSibling),hi=e,zt=!0,fs=null,t!==null&&(Di[Ni++]=Qo,Di[Ni++]=Ko,Di[Ni++]=qu,Qo=t.id,Ko=t.overflow,qu=e),e=mT(e,n.children),e.flags|=4096,e)}function xI(t,e,r){t.lanes|=e;var n=t.alternate;n!==null&&(n.lanes|=e),aS(t.return,e,r)}function Yb(t,e,r,n,i){var s=t.memoizedState;s===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:n,tail:r,tailMode:i}:(s.isBackwards=e,s.rendering=null,s.renderingStartTime=0,s.last=n,s.tail=r,s.tailMode=i)}function ZD(t,e,r){var n=e.pendingProps,i=n.revealOrder,s=n.tail;if(bn(t,e,n.children,r),n=Wt.current,n&2)n=n&1|2,e.flags|=128;else{if(t!==null&&t.flags&128)e:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&xI(t,r,e);else if(t.tag===19)xI(t,r,e);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;t=t.return}t.sibling.return=t.return,t=t.sibling}n&=1}if(Mt(Wt,n),!(e.mode&1))e.memoizedState=null;else switch(i){case"forwards":for(r=e.child,i=null;r!==null;)t=r.alternate,t!==null&&Uv(t)===null&&(i=r),r=r.sibling;r=i,r===null?(i=e.child,e.child=null):(i=r.sibling,r.sibling=null),Yb(e,!1,i,r,s);break;case"backwards":for(r=null,i=e.child,e.child=null;i!==null;){if(t=i.alternate,t!==null&&Uv(t)===null){e.child=i;break}t=i.sibling,i.sibling=r,r=i,i=t}Yb(e,!0,r,null,s);break;case"together":Yb(e,!1,null,null,void 0);break;default:e.memoizedState=null}return e.child}function G0(t,e){!(e.mode&1)&&t!==null&&(t.alternate=null,e.alternate=null,e.flags|=2)}function da(t,e,r){if(t!==null&&(e.dependencies=t.dependencies),Qu|=e.lanes,!(r&e.childLanes))return null;if(t!==null&&e.child!==t.child)throw Error(pe(153));if(e.child!==null){for(t=e.child,r=Sl(t,t.pendingProps),e.child=r,r.return=e;t.sibling!==null;)t=t.sibling,r=r.sibling=Sl(t,t.pendingProps),r.return=e;r.sibling=null}return e.child}function $U(t,e,r){switch(e.tag){case 3:QD(e),Wd();break;case 5:ED(e);break;case 1:Wn(e.type)&&Dv(e);break;case 4:aT(e,e.stateNode.containerInfo);break;case 10:var n=e.type._context,i=e.memoizedProps.value;Mt(Fv,n._currentValue),n._currentValue=i;break;case 13:if(n=e.memoizedState,n!==null)return n.dehydrated!==null?(Mt(Wt,Wt.current&1),e.flags|=128,null):r&e.child.childLanes?KD(t,e,r):(Mt(Wt,Wt.current&1),t=da(t,e,r),t!==null?t.sibling:null);Mt(Wt,Wt.current&1);break;case 19:if(n=(r&e.childLanes)!==0,t.flags&128){if(n)return ZD(t,e,r);e.flags|=128}if(i=e.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),Mt(Wt,Wt.current),n)break;return null;case 22:case 23:return e.lanes=0,qD(t,e,r)}return da(t,e,r)}var JD,mS,eN,tN;JD=function(t,e){for(var r=e.child;r!==null;){if(r.tag===5||r.tag===6)t.appendChild(r.stateNode);else if(r.tag!==4&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===e)break;for(;r.sibling===null;){if(r.return===null||r.return===e)return;r=r.return}r.sibling.return=r.return,r=r.sibling}};mS=function(){};eN=function(t,e,r,n){var i=t.memoizedProps;if(i!==n){t=e.stateNode,Au(mo.current);var s=null;switch(r){case"input":i=F_(t,i),n=F_(t,n),s=[];break;case"select":i=Yt({},i,{value:void 0}),n=Yt({},n,{value:void 0}),s=[];break;case"textarea":i=U_(t,i),n=U_(t,n),s=[];break;default:typeof i.onClick!="function"&&typeof n.onClick=="function"&&(t.onclick=kv)}z_(r,n);var o;r=null;for(u in i)if(!n.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var a=i[u];for(o in a)a.hasOwnProperty(o)&&(r||(r={}),r[o]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(lp.hasOwnProperty(u)?s||(s=[]):(s=s||[]).push(u,null));for(u in n){var l=n[u];if(a=i!=null?i[u]:void 0,n.hasOwnProperty(u)&&l!==a&&(l!=null||a!=null))if(u==="style")if(a){for(o in a)!a.hasOwnProperty(o)||l&&l.hasOwnProperty(o)||(r||(r={}),r[o]="");for(o in l)l.hasOwnProperty(o)&&a[o]!==l[o]&&(r||(r={}),r[o]=l[o])}else r||(s||(s=[]),s.push(u,r)),r=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,a=a?a.__html:void 0,l!=null&&a!==l&&(s=s||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(s=s||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(lp.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&Nt("scroll",t),s||a===l||(s=[])):(s=s||[]).push(u,l))}r&&(s=s||[]).push("style",r);var u=s;(e.updateQueue=u)&&(e.flags|=4)}};tN=function(t,e,r,n){r!==n&&(e.flags|=4)};function Kh(t,e){if(!zt)switch(t.tailMode){case"hidden":e=t.tail;for(var r=null;e!==null;)e.alternate!==null&&(r=e),e=e.sibling;r===null?t.tail=null:r.sibling=null;break;case"collapsed":r=t.tail;for(var n=null;r!==null;)r.alternate!==null&&(n=r),r=r.sibling;n===null?e||t.tail===null?t.tail=null:t.tail.sibling=null:n.sibling=null}}function un(t){var e=t.alternate!==null&&t.alternate.child===t.child,r=0,n=0;if(e)for(var i=t.child;i!==null;)r|=i.lanes|i.childLanes,n|=i.subtreeFlags&14680064,n|=i.flags&14680064,i.return=t,i=i.sibling;else for(i=t.child;i!==null;)r|=i.lanes|i.childLanes,n|=i.subtreeFlags,n|=i.flags,i.return=t,i=i.sibling;return t.subtreeFlags|=n,t.childLanes=r,e}function zU(t,e,r){var n=e.pendingProps;switch(eT(e),e.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return un(e),null;case 1:return Wn(e.type)&&Ov(),un(e),null;case 3:return n=e.stateNode,qd(),Ft(Gn),Ft(hn),uT(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(t===null||t.child===null)&&(Ng(e)?e.flags|=4:t===null||t.memoizedState.isDehydrated&&!(e.flags&256)||(e.flags|=1024,fs!==null&&(SS(fs),fs=null))),mS(t,e),un(e),null;case 5:lT(e);var i=Au(bp.current);if(r=e.type,t!==null&&e.stateNode!=null)eN(t,e,r,n,i),t.ref!==e.ref&&(e.flags|=512,e.flags|=2097152);else{if(!n){if(e.stateNode===null)throw Error(pe(166));return un(e),null}if(t=Au(mo.current),Ng(e)){n=e.stateNode,r=e.type;var s=e.memoizedProps;switch(n[oo]=e,n[yp]=s,t=(e.mode&1)!==0,r){case"dialog":Nt("cancel",n),Nt("close",n);break;case"iframe":case"object":case"embed":Nt("load",n);break;case"video":case"audio":for(i=0;i<xf.length;i++)Nt(xf[i],n);break;case"source":Nt("error",n);break;case"img":case"image":case"link":Nt("error",n),Nt("load",n);break;case"details":Nt("toggle",n);break;case"input":RP(n,s),Nt("invalid",n);break;case"select":n._wrapperState={wasMultiple:!!s.multiple},Nt("invalid",n);break;case"textarea":IP(n,s),Nt("invalid",n)}z_(r,s),i=null;for(var o in s)if(s.hasOwnProperty(o)){var a=s[o];o==="children"?typeof a=="string"?n.textContent!==a&&(s.suppressHydrationWarning!==!0&&Dg(n.textContent,a,t),i=["children",a]):typeof a=="number"&&n.textContent!==""+a&&(s.suppressHydrationWarning!==!0&&Dg(n.textContent,a,t),i=["children",""+a]):lp.hasOwnProperty(o)&&a!=null&&o==="onScroll"&&Nt("scroll",n)}switch(r){case"input":Cg(n),PP(n,s,!0);break;case"textarea":Cg(n),MP(n);break;case"select":case"option":break;default:typeof s.onClick=="function"&&(n.onclick=kv)}n=i,e.updateQueue=n,n!==null&&(e.flags|=4)}else{o=i.nodeType===9?i:i.ownerDocument,t==="http://www.w3.org/1999/xhtml"&&(t=PO(r)),t==="http://www.w3.org/1999/xhtml"?r==="script"?(t=o.createElement("div"),t.innerHTML="<script><\/script>",t=t.removeChild(t.firstChild)):typeof n.is=="string"?t=o.createElement(r,{is:n.is}):(t=o.createElement(r),r==="select"&&(o=t,n.multiple?o.multiple=!0:n.size&&(o.size=n.size))):t=o.createElementNS(t,r),t[oo]=e,t[yp]=n,JD(t,e,!1,!1),e.stateNode=t;e:{switch(o=H_(r,n),r){case"dialog":Nt("cancel",t),Nt("close",t),i=n;break;case"iframe":case"object":case"embed":Nt("load",t),i=n;break;case"video":case"audio":for(i=0;i<xf.length;i++)Nt(xf[i],t);i=n;break;case"source":Nt("error",t),i=n;break;case"img":case"image":case"link":Nt("error",t),Nt("load",t),i=n;break;case"details":Nt("toggle",t),i=n;break;case"input":RP(t,n),i=F_(t,n),Nt("invalid",t);break;case"option":i=n;break;case"select":t._wrapperState={wasMultiple:!!n.multiple},i=Yt({},n,{value:void 0}),Nt("invalid",t);break;case"textarea":IP(t,n),i=U_(t,n),Nt("invalid",t);break;default:i=n}z_(r,i),a=i;for(s in a)if(a.hasOwnProperty(s)){var l=a[s];s==="style"?kO(t,l):s==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&IO(t,l)):s==="children"?typeof l=="string"?(r!=="textarea"||l!=="")&&up(t,l):typeof l=="number"&&up(t,""+l):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(lp.hasOwnProperty(s)?l!=null&&s==="onScroll"&&Nt("scroll",t):l!=null&&B2(t,s,l,o))}switch(r){case"input":Cg(t),PP(t,n,!1);break;case"textarea":Cg(t),MP(t);break;case"option":n.value!=null&&t.setAttribute("value",""+Al(n.value));break;case"select":t.multiple=!!n.multiple,s=n.value,s!=null?hd(t,!!n.multiple,s,!1):n.defaultValue!=null&&hd(t,!!n.multiple,n.defaultValue,!0);break;default:typeof i.onClick=="function"&&(t.onclick=kv)}switch(r){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break e;case"img":n=!0;break e;default:n=!1}}n&&(e.flags|=4)}e.ref!==null&&(e.flags|=512,e.flags|=2097152)}return un(e),null;case 6:if(t&&e.stateNode!=null)tN(t,e,t.memoizedProps,n);else{if(typeof n!="string"&&e.stateNode===null)throw Error(pe(166));if(r=Au(bp.current),Au(mo.current),Ng(e)){if(n=e.stateNode,r=e.memoizedProps,n[oo]=e,(s=n.nodeValue!==r)&&(t=hi,t!==null))switch(t.tag){case 3:Dg(n.nodeValue,r,(t.mode&1)!==0);break;case 5:t.memoizedProps.suppressHydrationWarning!==!0&&Dg(n.nodeValue,r,(t.mode&1)!==0)}s&&(e.flags|=4)}else n=(r.nodeType===9?r:r.ownerDocument).createTextNode(n),n[oo]=e,e.stateNode=n}return un(e),null;case 13:if(Ft(Wt),n=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(zt&&ci!==null&&e.mode&1&&!(e.flags&128))xD(),Wd(),e.flags|=98560,s=!1;else if(s=Ng(e),n!==null&&n.dehydrated!==null){if(t===null){if(!s)throw Error(pe(318));if(s=e.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(pe(317));s[oo]=e}else Wd(),!(e.flags&128)&&(e.memoizedState=null),e.flags|=4;un(e),s=!1}else fs!==null&&(SS(fs),fs=null),s=!0;if(!s)return e.flags&65536?e:null}return e.flags&128?(e.lanes=r,e):(n=n!==null,n!==(t!==null&&t.memoizedState!==null)&&n&&(e.child.flags|=8192,e.mode&1&&(t===null||Wt.current&1?Cr===0&&(Cr=3):wT())),e.updateQueue!==null&&(e.flags|=4),un(e),null);case 4:return qd(),mS(t,e),t===null&&gp(e.stateNode.containerInfo),un(e),null;case 10:return iT(e.type._context),un(e),null;case 17:return Wn(e.type)&&Ov(),un(e),null;case 19:if(Ft(Wt),s=e.memoizedState,s===null)return un(e),null;if(n=(e.flags&128)!==0,o=s.rendering,o===null)if(n)Kh(s,!1);else{if(Cr!==0||t!==null&&t.flags&128)for(t=e.child;t!==null;){if(o=Uv(t),o!==null){for(e.flags|=128,Kh(s,!1),n=o.updateQueue,n!==null&&(e.updateQueue=n,e.flags|=4),e.subtreeFlags=0,n=r,r=e.child;r!==null;)s=r,t=n,s.flags&=14680066,o=s.alternate,o===null?(s.childLanes=0,s.lanes=t,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=o.childLanes,s.lanes=o.lanes,s.child=o.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=o.memoizedProps,s.memoizedState=o.memoizedState,s.updateQueue=o.updateQueue,s.type=o.type,t=o.dependencies,s.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),r=r.sibling;return Mt(Wt,Wt.current&1|2),e.child}t=t.sibling}s.tail!==null&&lr()>Qd&&(e.flags|=128,n=!0,Kh(s,!1),e.lanes=4194304)}else{if(!n)if(t=Uv(o),t!==null){if(e.flags|=128,n=!0,r=t.updateQueue,r!==null&&(e.updateQueue=r,e.flags|=4),Kh(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!zt)return un(e),null}else 2*lr()-s.renderingStartTime>Qd&&r!==1073741824&&(e.flags|=128,n=!0,Kh(s,!1),e.lanes=4194304);s.isBackwards?(o.sibling=e.child,e.child=o):(r=s.last,r!==null?r.sibling=o:e.child=o,s.last=o)}return s.tail!==null?(e=s.tail,s.rendering=e,s.tail=e.sibling,s.renderingStartTime=lr(),e.sibling=null,r=Wt.current,Mt(Wt,n?r&1|2:r&1),e):(un(e),null);case 22:case 23:return bT(),n=e.memoizedState!==null,t!==null&&t.memoizedState!==null!==n&&(e.flags|=8192),n&&e.mode&1?li&1073741824&&(un(e),e.subtreeFlags&6&&(e.flags|=8192)):un(e),null;case 24:return null;case 25:return null}throw Error(pe(156,e.tag))}function HU(t,e){switch(eT(e),e.tag){case 1:return Wn(e.type)&&Ov(),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return qd(),Ft(Gn),Ft(hn),uT(),t=e.flags,t&65536&&!(t&128)?(e.flags=t&-65537|128,e):null;case 5:return lT(e),null;case 13:if(Ft(Wt),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(pe(340));Wd()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return Ft(Wt),null;case 4:return qd(),null;case 10:return iT(e.type._context),null;case 22:case 23:return bT(),null;case 24:return null;default:return null}}var jg=!1,dn=!1,VU=typeof WeakSet=="function"?WeakSet:Set,Fe=null;function sd(t,e){var r=t.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){Jt(t,e,n)}else r.current=null}function gS(t,e,r){try{r()}catch(n){Jt(t,e,n)}}var bI=!1;function GU(t,e){if(J_=Pv,t=oD(),Z2(t)){if("selectionStart"in t)var r={start:t.selectionStart,end:t.selectionEnd};else e:{r=(r=t.ownerDocument)&&r.defaultView||window;var n=r.getSelection&&r.getSelection();if(n&&n.rangeCount!==0){r=n.anchorNode;var i=n.anchorOffset,s=n.focusNode;n=n.focusOffset;try{r.nodeType,s.nodeType}catch{r=null;break e}var o=0,a=-1,l=-1,u=0,c=0,h=t,f=null;t:for(;;){for(var m;h!==r||i!==0&&h.nodeType!==3||(a=o+i),h!==s||n!==0&&h.nodeType!==3||(l=o+n),h.nodeType===3&&(o+=h.nodeValue.length),(m=h.firstChild)!==null;)f=h,h=m;for(;;){if(h===t)break t;if(f===r&&++u===i&&(a=o),f===s&&++c===n&&(l=o),(m=h.nextSibling)!==null)break;h=f,f=h.parentNode}h=m}r=a===-1||l===-1?null:{start:a,end:l}}else r=null}r=r||{start:0,end:0}}else r=null;for(eS={focusedElem:t,selectionRange:r},Pv=!1,Fe=e;Fe!==null;)if(e=Fe,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,Fe=t;else for(;Fe!==null;){e=Fe;try{var y=e.alternate;if(e.flags&1024)switch(e.tag){case 0:case 11:case 15:break;case 1:if(y!==null){var v=y.memoizedProps,x=y.memoizedState,b=e.stateNode,_=b.getSnapshotBeforeUpdate(e.elementType===e.type?v:cs(e.type,v),x);b.__reactInternalSnapshotBeforeUpdate=_}break;case 3:var w=e.stateNode.containerInfo;w.nodeType===1?w.textContent="":w.nodeType===9&&w.documentElement&&w.removeChild(w.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(pe(163))}}catch(E){Jt(e,e.return,E)}if(t=e.sibling,t!==null){t.return=e.return,Fe=t;break}Fe=e.return}return y=bI,bI=!1,y}function Bf(t,e,r){var n=e.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var i=n=n.next;do{if((i.tag&t)===t){var s=i.destroy;i.destroy=void 0,s!==void 0&&gS(e,r,s)}i=i.next}while(i!==n)}}function t1(t,e){if(e=e.updateQueue,e=e!==null?e.lastEffect:null,e!==null){var r=e=e.next;do{if((r.tag&t)===t){var n=r.create;r.destroy=n()}r=r.next}while(r!==e)}}function vS(t){var e=t.ref;if(e!==null){var r=t.stateNode;switch(t.tag){case 5:t=r;break;default:t=r}typeof e=="function"?e(t):e.current=t}}function rN(t){var e=t.alternate;e!==null&&(t.alternate=null,rN(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&(delete e[oo],delete e[yp],delete e[nS],delete e[AU],delete e[RU])),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function nN(t){return t.tag===5||t.tag===3||t.tag===4}function wI(t){e:for(;;){for(;t.sibling===null;){if(t.return===null||nN(t.return))return null;t=t.return}for(t.sibling.return=t.return,t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.flags&2||t.child===null||t.tag===4)continue e;t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function yS(t,e,r){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?r.nodeType===8?r.parentNode.insertBefore(t,e):r.insertBefore(t,e):(r.nodeType===8?(e=r.parentNode,e.insertBefore(t,r)):(e=r,e.appendChild(t)),r=r._reactRootContainer,r!=null||e.onclick!==null||(e.onclick=kv));else if(n!==4&&(t=t.child,t!==null))for(yS(t,e,r),t=t.sibling;t!==null;)yS(t,e,r),t=t.sibling}function xS(t,e,r){var n=t.tag;if(n===5||n===6)t=t.stateNode,e?r.insertBefore(t,e):r.appendChild(t);else if(n!==4&&(t=t.child,t!==null))for(xS(t,e,r),t=t.sibling;t!==null;)xS(t,e,r),t=t.sibling}var qr=null,hs=!1;function Na(t,e,r){for(r=r.child;r!==null;)iN(t,e,r),r=r.sibling}function iN(t,e,r){if(po&&typeof po.onCommitFiberUnmount=="function")try{po.onCommitFiberUnmount(Xy,r)}catch{}switch(r.tag){case 5:dn||sd(r,e);case 6:var n=qr,i=hs;qr=null,Na(t,e,r),qr=n,hs=i,qr!==null&&(hs?(t=qr,r=r.stateNode,t.nodeType===8?t.parentNode.removeChild(r):t.removeChild(r)):qr.removeChild(r.stateNode));break;case 18:qr!==null&&(hs?(t=qr,r=r.stateNode,t.nodeType===8?zb(t.parentNode,r):t.nodeType===1&&zb(t,r),fp(t)):zb(qr,r.stateNode));break;case 4:n=qr,i=hs,qr=r.stateNode.containerInfo,hs=!0,Na(t,e,r),qr=n,hs=i;break;case 0:case 11:case 14:case 15:if(!dn&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){i=n=n.next;do{var s=i,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&gS(r,e,o),i=i.next}while(i!==n)}Na(t,e,r);break;case 1:if(!dn&&(sd(r,e),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(a){Jt(r,e,a)}Na(t,e,r);break;case 21:Na(t,e,r);break;case 22:r.mode&1?(dn=(n=dn)||r.memoizedState!==null,Na(t,e,r),dn=n):Na(t,e,r);break;default:Na(t,e,r)}}function _I(t){var e=t.updateQueue;if(e!==null){t.updateQueue=null;var r=t.stateNode;r===null&&(r=t.stateNode=new VU),e.forEach(function(n){var i=e$.bind(null,t,n);r.has(n)||(r.add(n),n.then(i,i))})}}function ss(t,e){var r=e.deletions;if(r!==null)for(var n=0;n<r.length;n++){var i=r[n];try{var s=t,o=e,a=o;e:for(;a!==null;){switch(a.tag){case 5:qr=a.stateNode,hs=!1;break e;case 3:qr=a.stateNode.containerInfo,hs=!0;break e;case 4:qr=a.stateNode.containerInfo,hs=!0;break e}a=a.return}if(qr===null)throw Error(pe(160));iN(s,o,i),qr=null,hs=!1;var l=i.alternate;l!==null&&(l.return=null),i.return=null}catch(u){Jt(i,e,u)}}if(e.subtreeFlags&12854)for(e=e.child;e!==null;)sN(e,t),e=e.sibling}function sN(t,e){var r=t.alternate,n=t.flags;switch(t.tag){case 0:case 11:case 14:case 15:if(ss(e,t),Hs(t),n&4){try{Bf(3,t,t.return),t1(3,t)}catch(v){Jt(t,t.return,v)}try{Bf(5,t,t.return)}catch(v){Jt(t,t.return,v)}}break;case 1:ss(e,t),Hs(t),n&512&&r!==null&&sd(r,r.return);break;case 5:if(ss(e,t),Hs(t),n&512&&r!==null&&sd(r,r.return),t.flags&32){var i=t.stateNode;try{up(i,"")}catch(v){Jt(t,t.return,v)}}if(n&4&&(i=t.stateNode,i!=null)){var s=t.memoizedProps,o=r!==null?r.memoizedProps:s,a=t.type,l=t.updateQueue;if(t.updateQueue=null,l!==null)try{a==="input"&&s.type==="radio"&&s.name!=null&&AO(i,s),H_(a,o);var u=H_(a,s);for(o=0;o<l.length;o+=2){var c=l[o],h=l[o+1];c==="style"?kO(i,h):c==="dangerouslySetInnerHTML"?IO(i,h):c==="children"?up(i,h):B2(i,c,h,u)}switch(a){case"input":j_(i,s);break;case"textarea":RO(i,s);break;case"select":var f=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!s.multiple;var m=s.value;m!=null?hd(i,!!s.multiple,m,!1):f!==!!s.multiple&&(s.defaultValue!=null?hd(i,!!s.multiple,s.defaultValue,!0):hd(i,!!s.multiple,s.multiple?[]:"",!1))}i[yp]=s}catch(v){Jt(t,t.return,v)}}break;case 6:if(ss(e,t),Hs(t),n&4){if(t.stateNode===null)throw Error(pe(162));i=t.stateNode,s=t.memoizedProps;try{i.nodeValue=s}catch(v){Jt(t,t.return,v)}}break;case 3:if(ss(e,t),Hs(t),n&4&&r!==null&&r.memoizedState.isDehydrated)try{fp(e.containerInfo)}catch(v){Jt(t,t.return,v)}break;case 4:ss(e,t),Hs(t);break;case 13:ss(e,t),Hs(t),i=t.child,i.flags&8192&&(s=i.memoizedState!==null,i.stateNode.isHidden=s,!s||i.alternate!==null&&i.alternate.memoizedState!==null||(yT=lr())),n&4&&_I(t);break;case 22:if(c=r!==null&&r.memoizedState!==null,t.mode&1?(dn=(u=dn)||c,ss(e,t),dn=u):ss(e,t),Hs(t),n&8192){if(u=t.memoizedState!==null,(t.stateNode.isHidden=u)&&!c&&t.mode&1)for(Fe=t,c=t.child;c!==null;){for(h=Fe=c;Fe!==null;){switch(f=Fe,m=f.child,f.tag){case 0:case 11:case 14:case 15:Bf(4,f,f.return);break;case 1:sd(f,f.return);var y=f.stateNode;if(typeof y.componentWillUnmount=="function"){n=f,r=f.return;try{e=n,y.props=e.memoizedProps,y.state=e.memoizedState,y.componentWillUnmount()}catch(v){Jt(n,r,v)}}break;case 5:sd(f,f.return);break;case 22:if(f.memoizedState!==null){EI(h);continue}}m!==null?(m.return=f,Fe=m):EI(h)}c=c.sibling}e:for(c=null,h=t;;){if(h.tag===5){if(c===null){c=h;try{i=h.stateNode,u?(s=i.style,typeof s.setProperty=="function"?s.setProperty("display","none","important"):s.display="none"):(a=h.stateNode,l=h.memoizedProps.style,o=l!=null&&l.hasOwnProperty("display")?l.display:null,a.style.display=MO("display",o))}catch(v){Jt(t,t.return,v)}}}else if(h.tag===6){if(c===null)try{h.stateNode.nodeValue=u?"":h.memoizedProps}catch(v){Jt(t,t.return,v)}}else if((h.tag!==22&&h.tag!==23||h.memoizedState===null||h===t)&&h.child!==null){h.child.return=h,h=h.child;continue}if(h===t)break e;for(;h.sibling===null;){if(h.return===null||h.return===t)break e;c===h&&(c=null),h=h.return}c===h&&(c=null),h.sibling.return=h.return,h=h.sibling}}break;case 19:ss(e,t),Hs(t),n&4&&_I(t);break;case 21:break;default:ss(e,t),Hs(t)}}function Hs(t){var e=t.flags;if(e&2){try{e:{for(var r=t.return;r!==null;){if(nN(r)){var n=r;break e}r=r.return}throw Error(pe(160))}switch(n.tag){case 5:var i=n.stateNode;n.flags&32&&(up(i,""),n.flags&=-33);var s=wI(t);xS(t,s,i);break;case 3:case 4:var o=n.stateNode.containerInfo,a=wI(t);yS(t,a,o);break;default:throw Error(pe(161))}}catch(l){Jt(t,t.return,l)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function WU(t,e,r){Fe=t,oN(t)}function oN(t,e,r){for(var n=(t.mode&1)!==0;Fe!==null;){var i=Fe,s=i.child;if(i.tag===22&&n){var o=i.memoizedState!==null||jg;if(!o){var a=i.alternate,l=a!==null&&a.memoizedState!==null||dn;a=jg;var u=dn;if(jg=o,(dn=l)&&!u)for(Fe=i;Fe!==null;)o=Fe,l=o.child,o.tag===22&&o.memoizedState!==null?TI(i):l!==null?(l.return=o,Fe=l):TI(i);for(;s!==null;)Fe=s,oN(s),s=s.sibling;Fe=i,jg=a,dn=u}SI(t)}else i.subtreeFlags&8772&&s!==null?(s.return=i,Fe=s):SI(t)}}function SI(t){for(;Fe!==null;){var e=Fe;if(e.flags&8772){var r=e.alternate;try{if(e.flags&8772)switch(e.tag){case 0:case 11:case 15:dn||t1(5,e);break;case 1:var n=e.stateNode;if(e.flags&4&&!dn)if(r===null)n.componentDidMount();else{var i=e.elementType===e.type?r.memoizedProps:cs(e.type,r.memoizedProps);n.componentDidUpdate(i,r.memoizedState,n.__reactInternalSnapshotBeforeUpdate)}var s=e.updateQueue;s!==null&&aI(e,s,n);break;case 3:var o=e.updateQueue;if(o!==null){if(r=null,e.child!==null)switch(e.child.tag){case 5:r=e.child.stateNode;break;case 1:r=e.child.stateNode}aI(e,o,r)}break;case 5:var a=e.stateNode;if(r===null&&e.flags&4){r=a;var l=e.memoizedProps;switch(e.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&r.focus();break;case"img":l.src&&(r.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(e.memoizedState===null){var u=e.alternate;if(u!==null){var c=u.memoizedState;if(c!==null){var h=c.dehydrated;h!==null&&fp(h)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(pe(163))}dn||e.flags&512&&vS(e)}catch(f){Jt(e,e.return,f)}}if(e===t){Fe=null;break}if(r=e.sibling,r!==null){r.return=e.return,Fe=r;break}Fe=e.return}}function EI(t){for(;Fe!==null;){var e=Fe;if(e===t){Fe=null;break}var r=e.sibling;if(r!==null){r.return=e.return,Fe=r;break}Fe=e.return}}function TI(t){for(;Fe!==null;){var e=Fe;try{switch(e.tag){case 0:case 11:case 15:var r=e.return;try{t1(4,e)}catch(l){Jt(e,r,l)}break;case 1:var n=e.stateNode;if(typeof n.componentDidMount=="function"){var i=e.return;try{n.componentDidMount()}catch(l){Jt(e,i,l)}}var s=e.return;try{vS(e)}catch(l){Jt(e,s,l)}break;case 5:var o=e.return;try{vS(e)}catch(l){Jt(e,o,l)}}}catch(l){Jt(e,e.return,l)}if(e===t){Fe=null;break}var a=e.sibling;if(a!==null){a.return=e.return,Fe=a;break}Fe=e.return}}var XU=Math.ceil,Hv=xa.ReactCurrentDispatcher,gT=xa.ReactCurrentOwner,zi=xa.ReactCurrentBatchConfig,bt=0,$r=null,pr=null,Qr=0,li=0,od=Ll(0),Cr=0,Ep=null,Qu=0,r1=0,vT=0,Uf=null,zn=null,yT=0,Qd=1/0,Go=null,Vv=!1,bS=null,wl=null,Bg=!1,al=null,Gv=0,$f=0,wS=null,W0=-1,X0=0;function Tn(){return bt&6?lr():W0!==-1?W0:W0=lr()}function _l(t){return t.mode&1?bt&2&&Qr!==0?Qr&-Qr:IU.transition!==null?(X0===0&&(X0=VO()),X0):(t=At,t!==0||(t=window.event,t=t===void 0?16:KO(t.type)),t):1}function _s(t,e,r,n){if(50<$f)throw $f=0,wS=null,Error(pe(185));nm(t,r,n),(!(bt&2)||t!==$r)&&(t===$r&&(!(bt&2)&&(r1|=r),Cr===4&&Xa(t,Qr)),Xn(t,n),r===1&&bt===0&&!(e.mode&1)&&(Qd=lr()+500,Zy&&Fl()))}function Xn(t,e){var r=t.callbackNode;I9(t,e);var n=Rv(t,t===$r?Qr:0);if(n===0)r!==null&&DP(r),t.callbackNode=null,t.callbackPriority=0;else if(e=n&-n,t.callbackPriority!==e){if(r!=null&&DP(r),e===1)t.tag===0?PU(CI.bind(null,t)):gD(CI.bind(null,t)),TU(function(){!(bt&6)&&Fl()}),r=null;else{switch(GO(n)){case 1:r=V2;break;case 4:r=zO;break;case 16:r=Av;break;case 536870912:r=HO;break;default:r=Av}r=pN(r,aN.bind(null,t))}t.callbackPriority=e,t.callbackNode=r}}function aN(t,e){if(W0=-1,X0=0,bt&6)throw Error(pe(327));var r=t.callbackNode;if(vd()&&t.callbackNode!==r)return null;var n=Rv(t,t===$r?Qr:0);if(n===0)return null;if(n&30||n&t.expiredLanes||e)e=Wv(t,n);else{e=n;var i=bt;bt|=2;var s=uN();($r!==t||Qr!==e)&&(Go=null,Qd=lr()+500,ju(t,e));do try{QU();break}catch(a){lN(t,a)}while(!0);nT(),Hv.current=s,bt=i,pr!==null?e=0:($r=null,Qr=0,e=Cr)}if(e!==0){if(e===2&&(i=q_(t),i!==0&&(n=i,e=_S(t,i))),e===1)throw r=Ep,ju(t,0),Xa(t,n),Xn(t,lr()),r;if(e===6)Xa(t,n);else{if(i=t.current.alternate,!(n&30)&&!qU(i)&&(e=Wv(t,n),e===2&&(s=q_(t),s!==0&&(n=s,e=_S(t,s))),e===1))throw r=Ep,ju(t,0),Xa(t,n),Xn(t,lr()),r;switch(t.finishedWork=i,t.finishedLanes=n,e){case 0:case 1:throw Error(pe(345));case 2:mu(t,zn,Go);break;case 3:if(Xa(t,n),(n&130023424)===n&&(e=yT+500-lr(),10<e)){if(Rv(t,0)!==0)break;if(i=t.suspendedLanes,(i&n)!==n){Tn(),t.pingedLanes|=t.suspendedLanes&i;break}t.timeoutHandle=rS(mu.bind(null,t,zn,Go),e);break}mu(t,zn,Go);break;case 4:if(Xa(t,n),(n&4194240)===n)break;for(e=t.eventTimes,i=-1;0<n;){var o=31-ws(n);s=1<<o,o=e[o],o>i&&(i=o),n&=~s}if(n=i,n=lr()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*XU(n/1960))-n,10<n){t.timeoutHandle=rS(mu.bind(null,t,zn,Go),n);break}mu(t,zn,Go);break;case 5:mu(t,zn,Go);break;default:throw Error(pe(329))}}}return Xn(t,lr()),t.callbackNode===r?aN.bind(null,t):null}function _S(t,e){var r=Uf;return t.current.memoizedState.isDehydrated&&(ju(t,e).flags|=256),t=Wv(t,e),t!==2&&(e=zn,zn=r,e!==null&&SS(e)),t}function SS(t){zn===null?zn=t:zn.push.apply(zn,t)}function qU(t){for(var e=t;;){if(e.flags&16384){var r=e.updateQueue;if(r!==null&&(r=r.stores,r!==null))for(var n=0;n<r.length;n++){var i=r[n],s=i.getSnapshot;i=i.value;try{if(!Cs(s(),i))return!1}catch{return!1}}}if(r=e.child,e.subtreeFlags&16384&&r!==null)r.return=e,e=r;else{if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return!0;e=e.return}e.sibling.return=e.return,e=e.sibling}}return!0}function Xa(t,e){for(e&=~vT,e&=~r1,t.suspendedLanes|=e,t.pingedLanes&=~e,t=t.expirationTimes;0<e;){var r=31-ws(e),n=1<<r;t[r]=-1,e&=~n}}function CI(t){if(bt&6)throw Error(pe(327));vd();var e=Rv(t,0);if(!(e&1))return Xn(t,lr()),null;var r=Wv(t,e);if(t.tag!==0&&r===2){var n=q_(t);n!==0&&(e=n,r=_S(t,n))}if(r===1)throw r=Ep,ju(t,0),Xa(t,e),Xn(t,lr()),r;if(r===6)throw Error(pe(345));return t.finishedWork=t.current.alternate,t.finishedLanes=e,mu(t,zn,Go),Xn(t,lr()),null}function xT(t,e){var r=bt;bt|=1;try{return t(e)}finally{bt=r,bt===0&&(Qd=lr()+500,Zy&&Fl())}}function Ku(t){al!==null&&al.tag===0&&!(bt&6)&&vd();var e=bt;bt|=1;var r=zi.transition,n=At;try{if(zi.transition=null,At=1,t)return t()}finally{At=n,zi.transition=r,bt=e,!(bt&6)&&Fl()}}function bT(){li=od.current,Ft(od)}function ju(t,e){t.finishedWork=null,t.finishedLanes=0;var r=t.timeoutHandle;if(r!==-1&&(t.timeoutHandle=-1,EU(r)),pr!==null)for(r=pr.return;r!==null;){var n=r;switch(eT(n),n.tag){case 1:n=n.type.childContextTypes,n!=null&&Ov();break;case 3:qd(),Ft(Gn),Ft(hn),uT();break;case 5:lT(n);break;case 4:qd();break;case 13:Ft(Wt);break;case 19:Ft(Wt);break;case 10:iT(n.type._context);break;case 22:case 23:bT()}r=r.return}if($r=t,pr=t=Sl(t.current,null),Qr=li=e,Cr=0,Ep=null,vT=r1=Qu=0,zn=Uf=null,Cu!==null){for(e=0;e<Cu.length;e++)if(r=Cu[e],n=r.interleaved,n!==null){r.interleaved=null;var i=n.next,s=r.pending;if(s!==null){var o=s.next;s.next=i,n.next=o}r.pending=n}Cu=null}return t}function lN(t,e){do{var r=pr;try{if(nT(),H0.current=zv,$v){for(var n=qt.memoizedState;n!==null;){var i=n.queue;i!==null&&(i.pending=null),n=n.next}$v=!1}if(Yu=0,Fr=wr=qt=null,jf=!1,wp=0,gT.current=null,r===null||r.return===null){Cr=1,Ep=e,pr=null;break}e:{var s=t,o=r.return,a=r,l=e;if(e=Qr,a.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l,c=a,h=c.tag;if(!(c.mode&1)&&(h===0||h===11||h===15)){var f=c.alternate;f?(c.updateQueue=f.updateQueue,c.memoizedState=f.memoizedState,c.lanes=f.lanes):(c.updateQueue=null,c.memoizedState=null)}var m=fI(o);if(m!==null){m.flags&=-257,pI(m,o,a,s,e),m.mode&1&&hI(s,u,e),e=m,l=u;var y=e.updateQueue;if(y===null){var v=new Set;v.add(l),e.updateQueue=v}else y.add(l);break e}else{if(!(e&1)){hI(s,u,e),wT();break e}l=Error(pe(426))}}else if(zt&&a.mode&1){var x=fI(o);if(x!==null){!(x.flags&65536)&&(x.flags|=256),pI(x,o,a,s,e),tT(Yd(l,a));break e}}s=l=Yd(l,a),Cr!==4&&(Cr=2),Uf===null?Uf=[s]:Uf.push(s),s=o;do{switch(s.tag){case 3:s.flags|=65536,e&=-e,s.lanes|=e;var b=GD(s,l,e);oI(s,b);break e;case 1:a=l;var _=s.type,w=s.stateNode;if(!(s.flags&128)&&(typeof _.getDerivedStateFromError=="function"||w!==null&&typeof w.componentDidCatch=="function"&&(wl===null||!wl.has(w)))){s.flags|=65536,e&=-e,s.lanes|=e;var E=WD(s,a,e);oI(s,E);break e}}s=s.return}while(s!==null)}dN(r)}catch(A){e=A,pr===r&&r!==null&&(pr=r=r.return);continue}break}while(!0)}function uN(){var t=Hv.current;return Hv.current=zv,t===null?zv:t}function wT(){(Cr===0||Cr===3||Cr===2)&&(Cr=4),$r===null||!(Qu&268435455)&&!(r1&268435455)||Xa($r,Qr)}function Wv(t,e){var r=bt;bt|=2;var n=uN();($r!==t||Qr!==e)&&(Go=null,ju(t,e));do try{YU();break}catch(i){lN(t,i)}while(!0);if(nT(),bt=r,Hv.current=n,pr!==null)throw Error(pe(261));return $r=null,Qr=0,Cr}function YU(){for(;pr!==null;)cN(pr)}function QU(){for(;pr!==null&&!w9();)cN(pr)}function cN(t){var e=fN(t.alternate,t,li);t.memoizedProps=t.pendingProps,e===null?dN(t):pr=e,gT.current=null}function dN(t){var e=t;do{var r=e.alternate;if(t=e.return,e.flags&32768){if(r=HU(r,e),r!==null){r.flags&=32767,pr=r;return}if(t!==null)t.flags|=32768,t.subtreeFlags=0,t.deletions=null;else{Cr=6,pr=null;return}}else if(r=zU(r,e,li),r!==null){pr=r;return}if(e=e.sibling,e!==null){pr=e;return}pr=e=t}while(e!==null);Cr===0&&(Cr=5)}function mu(t,e,r){var n=At,i=zi.transition;try{zi.transition=null,At=1,KU(t,e,r,n)}finally{zi.transition=i,At=n}return null}function KU(t,e,r,n){do vd();while(al!==null);if(bt&6)throw Error(pe(327));r=t.finishedWork;var i=t.finishedLanes;if(r===null)return null;if(t.finishedWork=null,t.finishedLanes=0,r===t.current)throw Error(pe(177));t.callbackNode=null,t.callbackPriority=0;var s=r.lanes|r.childLanes;if(M9(t,s),t===$r&&(pr=$r=null,Qr=0),!(r.subtreeFlags&2064)&&!(r.flags&2064)||Bg||(Bg=!0,pN(Av,function(){return vd(),null})),s=(r.flags&15990)!==0,r.subtreeFlags&15990||s){s=zi.transition,zi.transition=null;var o=At;At=1;var a=bt;bt|=4,gT.current=null,GU(t,r),sN(r,t),vU(eS),Pv=!!J_,eS=J_=null,t.current=r,WU(r),_9(),bt=a,At=o,zi.transition=s}else t.current=r;if(Bg&&(Bg=!1,al=t,Gv=i),s=t.pendingLanes,s===0&&(wl=null),T9(r.stateNode),Xn(t,lr()),e!==null)for(n=t.onRecoverableError,r=0;r<e.length;r++)i=e[r],n(i.value,{componentStack:i.stack,digest:i.digest});if(Vv)throw Vv=!1,t=bS,bS=null,t;return Gv&1&&t.tag!==0&&vd(),s=t.pendingLanes,s&1?t===wS?$f++:($f=0,wS=t):$f=0,Fl(),null}function vd(){if(al!==null){var t=GO(Gv),e=zi.transition,r=At;try{if(zi.transition=null,At=16>t?16:t,al===null)var n=!1;else{if(t=al,al=null,Gv=0,bt&6)throw Error(pe(331));var i=bt;for(bt|=4,Fe=t.current;Fe!==null;){var s=Fe,o=s.child;if(Fe.flags&16){var a=s.deletions;if(a!==null){for(var l=0;l<a.length;l++){var u=a[l];for(Fe=u;Fe!==null;){var c=Fe;switch(c.tag){case 0:case 11:case 15:Bf(8,c,s)}var h=c.child;if(h!==null)h.return=c,Fe=h;else for(;Fe!==null;){c=Fe;var f=c.sibling,m=c.return;if(rN(c),c===u){Fe=null;break}if(f!==null){f.return=m,Fe=f;break}Fe=m}}}var y=s.alternate;if(y!==null){var v=y.child;if(v!==null){y.child=null;do{var x=v.sibling;v.sibling=null,v=x}while(v!==null)}}Fe=s}}if(s.subtreeFlags&2064&&o!==null)o.return=s,Fe=o;else e:for(;Fe!==null;){if(s=Fe,s.flags&2048)switch(s.tag){case 0:case 11:case 15:Bf(9,s,s.return)}var b=s.sibling;if(b!==null){b.return=s.return,Fe=b;break e}Fe=s.return}}var _=t.current;for(Fe=_;Fe!==null;){o=Fe;var w=o.child;if(o.subtreeFlags&2064&&w!==null)w.return=o,Fe=w;else e:for(o=_;Fe!==null;){if(a=Fe,a.flags&2048)try{switch(a.tag){case 0:case 11:case 15:t1(9,a)}}catch(A){Jt(a,a.return,A)}if(a===o){Fe=null;break e}var E=a.sibling;if(E!==null){E.return=a.return,Fe=E;break e}Fe=a.return}}if(bt=i,Fl(),po&&typeof po.onPostCommitFiberRoot=="function")try{po.onPostCommitFiberRoot(Xy,t)}catch{}n=!0}return n}finally{At=r,zi.transition=e}}return!1}function AI(t,e,r){e=Yd(r,e),e=GD(t,e,1),t=bl(t,e,1),e=Tn(),t!==null&&(nm(t,1,e),Xn(t,e))}function Jt(t,e,r){if(t.tag===3)AI(t,t,r);else for(;e!==null;){if(e.tag===3){AI(e,t,r);break}else if(e.tag===1){var n=e.stateNode;if(typeof e.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(wl===null||!wl.has(n))){t=Yd(r,t),t=WD(e,t,1),e=bl(e,t,1),t=Tn(),e!==null&&(nm(e,1,t),Xn(e,t));break}}e=e.return}}function ZU(t,e,r){var n=t.pingCache;n!==null&&n.delete(e),e=Tn(),t.pingedLanes|=t.suspendedLanes&r,$r===t&&(Qr&r)===r&&(Cr===4||Cr===3&&(Qr&130023424)===Qr&&500>lr()-yT?ju(t,0):vT|=r),Xn(t,e)}function hN(t,e){e===0&&(t.mode&1?(e=Pg,Pg<<=1,!(Pg&130023424)&&(Pg=4194304)):e=1);var r=Tn();t=ca(t,e),t!==null&&(nm(t,e,r),Xn(t,r))}function JU(t){var e=t.memoizedState,r=0;e!==null&&(r=e.retryLane),hN(t,r)}function e$(t,e){var r=0;switch(t.tag){case 13:var n=t.stateNode,i=t.memoizedState;i!==null&&(r=i.retryLane);break;case 19:n=t.stateNode;break;default:throw Error(pe(314))}n!==null&&n.delete(e),hN(t,r)}var fN;fN=function(t,e,r){if(t!==null)if(t.memoizedProps!==e.pendingProps||Gn.current)Hn=!0;else{if(!(t.lanes&r)&&!(e.flags&128))return Hn=!1,$U(t,e,r);Hn=!!(t.flags&131072)}else Hn=!1,zt&&e.flags&1048576&&vD(e,Lv,e.index);switch(e.lanes=0,e.tag){case 2:var n=e.type;G0(t,e),t=e.pendingProps;var i=Gd(e,hn.current);gd(e,r),i=dT(null,e,n,t,i,r);var s=hT();return e.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(e.tag=1,e.memoizedState=null,e.updateQueue=null,Wn(n)?(s=!0,Dv(e)):s=!1,e.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,oT(e),i.updater=e1,e.stateNode=i,i._reactInternals=e,uS(e,n,t,r),e=hS(null,e,n,!0,s,r)):(e.tag=0,zt&&s&&J2(e),bn(null,e,i,r),e=e.child),e;case 16:n=e.elementType;e:{switch(G0(t,e),t=e.pendingProps,i=n._init,n=i(n._payload),e.type=n,i=e.tag=r$(n),t=cs(n,t),i){case 0:e=dS(null,e,n,t,r);break e;case 1:e=vI(null,e,n,t,r);break e;case 11:e=mI(null,e,n,t,r);break e;case 14:e=gI(null,e,n,cs(n.type,t),r);break e}throw Error(pe(306,n,""))}return e;case 0:return n=e.type,i=e.pendingProps,i=e.elementType===n?i:cs(n,i),dS(t,e,n,i,r);case 1:return n=e.type,i=e.pendingProps,i=e.elementType===n?i:cs(n,i),vI(t,e,n,i,r);case 3:e:{if(QD(e),t===null)throw Error(pe(387));n=e.pendingProps,s=e.memoizedState,i=s.element,SD(t,e),Bv(e,n,null,r);var o=e.memoizedState;if(n=o.element,s.isDehydrated)if(s={element:n,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},e.updateQueue.baseState=s,e.memoizedState=s,e.flags&256){i=Yd(Error(pe(423)),e),e=yI(t,e,n,r,i);break e}else if(n!==i){i=Yd(Error(pe(424)),e),e=yI(t,e,n,r,i);break e}else for(ci=xl(e.stateNode.containerInfo.firstChild),hi=e,zt=!0,fs=null,r=wD(e,null,n,r),e.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(Wd(),n===i){e=da(t,e,r);break e}bn(t,e,n,r)}e=e.child}return e;case 5:return ED(e),t===null&&oS(e),n=e.type,i=e.pendingProps,s=t!==null?t.memoizedProps:null,o=i.children,tS(n,i)?o=null:s!==null&&tS(n,s)&&(e.flags|=32),YD(t,e),bn(t,e,o,r),e.child;case 6:return t===null&&oS(e),null;case 13:return KD(t,e,r);case 4:return aT(e,e.stateNode.containerInfo),n=e.pendingProps,t===null?e.child=Xd(e,null,n,r):bn(t,e,n,r),e.child;case 11:return n=e.type,i=e.pendingProps,i=e.elementType===n?i:cs(n,i),mI(t,e,n,i,r);case 7:return bn(t,e,e.pendingProps,r),e.child;case 8:return bn(t,e,e.pendingProps.children,r),e.child;case 12:return bn(t,e,e.pendingProps.children,r),e.child;case 10:e:{if(n=e.type._context,i=e.pendingProps,s=e.memoizedProps,o=i.value,Mt(Fv,n._currentValue),n._currentValue=o,s!==null)if(Cs(s.value,o)){if(s.children===i.children&&!Gn.current){e=da(t,e,r);break e}}else for(s=e.child,s!==null&&(s.return=e);s!==null;){var a=s.dependencies;if(a!==null){o=s.child;for(var l=a.firstContext;l!==null;){if(l.context===n){if(s.tag===1){l=na(-1,r&-r),l.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?l.next=l:(l.next=c.next,c.next=l),u.pending=l}}s.lanes|=r,l=s.alternate,l!==null&&(l.lanes|=r),aS(s.return,r,e),a.lanes|=r;break}l=l.next}}else if(s.tag===10)o=s.type===e.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(pe(341));o.lanes|=r,a=o.alternate,a!==null&&(a.lanes|=r),aS(o,r,e),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===e){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}bn(t,e,i.children,r),e=e.child}return e;case 9:return i=e.type,n=e.pendingProps.children,gd(e,r),i=Xi(i),n=n(i),e.flags|=1,bn(t,e,n,r),e.child;case 14:return n=e.type,i=cs(n,e.pendingProps),i=cs(n.type,i),gI(t,e,n,i,r);case 15:return XD(t,e,e.type,e.pendingProps,r);case 17:return n=e.type,i=e.pendingProps,i=e.elementType===n?i:cs(n,i),G0(t,e),e.tag=1,Wn(n)?(t=!0,Dv(e)):t=!1,gd(e,r),VD(e,n,i),uS(e,n,i,r),hS(null,e,n,!0,t,r);case 19:return ZD(t,e,r);case 22:return qD(t,e,r)}throw Error(pe(156,e.tag))};function pN(t,e){return $O(t,e)}function t$(t,e,r,n){this.tag=t,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Bi(t,e,r,n){return new t$(t,e,r,n)}function _T(t){return t=t.prototype,!(!t||!t.isReactComponent)}function r$(t){if(typeof t=="function")return _T(t)?1:0;if(t!=null){if(t=t.$$typeof,t===$2)return 11;if(t===z2)return 14}return 2}function Sl(t,e){var r=t.alternate;return r===null?(r=Bi(t.tag,e,t.key,t.mode),r.elementType=t.elementType,r.type=t.type,r.stateNode=t.stateNode,r.alternate=t,t.alternate=r):(r.pendingProps=e,r.type=t.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=t.flags&14680064,r.childLanes=t.childLanes,r.lanes=t.lanes,r.child=t.child,r.memoizedProps=t.memoizedProps,r.memoizedState=t.memoizedState,r.updateQueue=t.updateQueue,e=t.dependencies,r.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},r.sibling=t.sibling,r.index=t.index,r.ref=t.ref,r}function q0(t,e,r,n,i,s){var o=2;if(n=t,typeof t=="function")_T(t)&&(o=1);else if(typeof t=="string")o=5;else e:switch(t){case Qc:return Bu(r.children,i,s,e);case U2:o=8,i|=8;break;case O_:return t=Bi(12,r,e,i|2),t.elementType=O_,t.lanes=s,t;case D_:return t=Bi(13,r,e,i),t.elementType=D_,t.lanes=s,t;case N_:return t=Bi(19,r,e,i),t.elementType=N_,t.lanes=s,t;case EO:return n1(r,i,s,e);default:if(typeof t=="object"&&t!==null)switch(t.$$typeof){case _O:o=10;break e;case SO:o=9;break e;case $2:o=11;break e;case z2:o=14;break e;case za:o=16,n=null;break e}throw Error(pe(130,t==null?t:typeof t,""))}return e=Bi(o,r,e,i),e.elementType=t,e.type=n,e.lanes=s,e}function Bu(t,e,r,n){return t=Bi(7,t,n,e),t.lanes=r,t}function n1(t,e,r,n){return t=Bi(22,t,n,e),t.elementType=EO,t.lanes=r,t.stateNode={isHidden:!1},t}function Qb(t,e,r){return t=Bi(6,t,null,e),t.lanes=r,t}function Kb(t,e,r){return e=Bi(4,t.children!==null?t.children:[],t.key,e),e.lanes=r,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}function n$(t,e,r,n,i){this.tag=e,this.containerInfo=t,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Mb(0),this.expirationTimes=Mb(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Mb(0),this.identifierPrefix=n,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function ST(t,e,r,n,i,s,o,a,l){return t=new n$(t,e,r,a,l),e===1?(e=1,s===!0&&(e|=8)):e=0,s=Bi(3,null,null,e),t.current=s,s.stateNode=t,s.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},oT(s),t}function i$(t,e,r){var n=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Yc,key:n==null?null:""+n,children:t,containerInfo:e,implementation:r}}function mN(t){if(!t)return Rl;t=t._reactInternals;e:{if(uc(t)!==t||t.tag!==1)throw Error(pe(170));var e=t;do{switch(e.tag){case 3:e=e.stateNode.context;break e;case 1:if(Wn(e.type)){e=e.stateNode.__reactInternalMemoizedMergedChildContext;break e}}e=e.return}while(e!==null);throw Error(pe(171))}if(t.tag===1){var r=t.type;if(Wn(r))return mD(t,r,e)}return e}function gN(t,e,r,n,i,s,o,a,l){return t=ST(r,n,!0,t,i,s,o,a,l),t.context=mN(null),r=t.current,n=Tn(),i=_l(r),s=na(n,i),s.callback=e??null,bl(r,s,i),t.current.lanes=i,nm(t,i,n),Xn(t,n),t}function i1(t,e,r,n){var i=e.current,s=Tn(),o=_l(i);return r=mN(r),e.context===null?e.context=r:e.pendingContext=r,e=na(s,o),e.payload={element:t},n=n===void 0?null:n,n!==null&&(e.callback=n),t=bl(i,e,o),t!==null&&(_s(t,i,o,s),z0(t,i,o)),o}function Xv(t){if(t=t.current,!t.child)return null;switch(t.child.tag){case 5:return t.child.stateNode;default:return t.child.stateNode}}function RI(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var r=t.retryLane;t.retryLane=r!==0&&r<e?r:e}}function ET(t,e){RI(t,e),(t=t.alternate)&&RI(t,e)}function s$(){return null}var vN=typeof reportError=="function"?reportError:function(t){console.error(t)};function TT(t){this._internalRoot=t}s1.prototype.render=TT.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(pe(409));i1(t,e,null,null)};s1.prototype.unmount=TT.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;Ku(function(){i1(null,t,null,null)}),e[ua]=null}};function s1(t){this._internalRoot=t}s1.prototype.unstable_scheduleHydration=function(t){if(t){var e=qO();t={blockedOn:null,target:t,priority:e};for(var r=0;r<Wa.length&&e!==0&&e<Wa[r].priority;r++);Wa.splice(r,0,t),r===0&&QO(t)}};function CT(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function o1(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11&&(t.nodeType!==8||t.nodeValue!==" react-mount-point-unstable "))}function PI(){}function o$(t,e,r,n,i){if(i){if(typeof n=="function"){var s=n;n=function(){var u=Xv(o);s.call(u)}}var o=gN(e,n,t,0,null,!1,!1,"",PI);return t._reactRootContainer=o,t[ua]=o.current,gp(t.nodeType===8?t.parentNode:t),Ku(),o}for(;i=t.lastChild;)t.removeChild(i);if(typeof n=="function"){var a=n;n=function(){var u=Xv(l);a.call(u)}}var l=ST(t,0,!1,null,null,!1,!1,"",PI);return t._reactRootContainer=l,t[ua]=l.current,gp(t.nodeType===8?t.parentNode:t),Ku(function(){i1(e,l,r,n)}),l}function a1(t,e,r,n,i){var s=r._reactRootContainer;if(s){var o=s;if(typeof i=="function"){var a=i;i=function(){var l=Xv(o);a.call(l)}}i1(e,o,t,i)}else o=o$(r,e,t,i,n);return Xv(o)}WO=function(t){switch(t.tag){case 3:var e=t.stateNode;if(e.current.memoizedState.isDehydrated){var r=yf(e.pendingLanes);r!==0&&(G2(e,r|1),Xn(e,lr()),!(bt&6)&&(Qd=lr()+500,Fl()))}break;case 13:Ku(function(){var n=ca(t,1);if(n!==null){var i=Tn();_s(n,t,1,i)}}),ET(t,1)}};W2=function(t){if(t.tag===13){var e=ca(t,134217728);if(e!==null){var r=Tn();_s(e,t,134217728,r)}ET(t,134217728)}};XO=function(t){if(t.tag===13){var e=_l(t),r=ca(t,e);if(r!==null){var n=Tn();_s(r,t,e,n)}ET(t,e)}};qO=function(){return At};YO=function(t,e){var r=At;try{return At=t,e()}finally{At=r}};G_=function(t,e,r){switch(e){case"input":if(j_(t,r),e=r.name,r.type==="radio"&&e!=null){for(r=t;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll("input[name="+JSON.stringify(""+e)+'][type="radio"]'),e=0;e<r.length;e++){var n=r[e];if(n!==t&&n.form===t.form){var i=Ky(n);if(!i)throw Error(pe(90));CO(n),j_(n,i)}}}break;case"textarea":RO(t,r);break;case"select":e=r.value,e!=null&&hd(t,!!r.multiple,e,!1)}};NO=xT;LO=Ku;var a$={usingClientEntryPoint:!1,Events:[sm,ed,Ky,OO,DO,xT]},Zh={findFiberByHostInstance:Tu,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},l$={bundleType:Zh.bundleType,version:Zh.version,rendererPackageName:Zh.rendererPackageName,rendererConfig:Zh.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:xa.ReactCurrentDispatcher,findHostInstanceByFiber:function(t){return t=BO(t),t===null?null:t.stateNode},findFiberByHostInstance:Zh.findFiberByHostInstance||s$,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Ug=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Ug.isDisabled&&Ug.supportsFiber)try{Xy=Ug.inject(l$),po=Ug}catch{}}vi.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=a$;vi.createPortal=function(t,e){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!CT(e))throw Error(pe(200));return i$(t,e,null,r)};vi.createRoot=function(t,e){if(!CT(t))throw Error(pe(299));var r=!1,n="",i=vN;return e!=null&&(e.unstable_strictMode===!0&&(r=!0),e.identifierPrefix!==void 0&&(n=e.identifierPrefix),e.onRecoverableError!==void 0&&(i=e.onRecoverableError)),e=ST(t,1,!1,null,null,r,!1,n,i),t[ua]=e.current,gp(t.nodeType===8?t.parentNode:t),new TT(e)};vi.findDOMNode=function(t){if(t==null)return null;if(t.nodeType===1)return t;var e=t._reactInternals;if(e===void 0)throw typeof t.render=="function"?Error(pe(188)):(t=Object.keys(t).join(","),Error(pe(268,t)));return t=BO(e),t=t===null?null:t.stateNode,t};vi.flushSync=function(t){return Ku(t)};vi.hydrate=function(t,e,r){if(!o1(e))throw Error(pe(200));return a1(null,t,e,!0,r)};vi.hydrateRoot=function(t,e,r){if(!CT(t))throw Error(pe(405));var n=r!=null&&r.hydratedSources||null,i=!1,s="",o=vN;if(r!=null&&(r.unstable_strictMode===!0&&(i=!0),r.identifierPrefix!==void 0&&(s=r.identifierPrefix),r.onRecoverableError!==void 0&&(o=r.onRecoverableError)),e=gN(e,null,t,1,r??null,i,!1,s,o),t[ua]=e.current,gp(t),n)for(t=0;t<n.length;t++)r=n[t],i=r._getVersion,i=i(r._source),e.mutableSourceEagerHydrationData==null?e.mutableSourceEagerHydrationData=[r,i]:e.mutableSourceEagerHydrationData.push(r,i);return new s1(e)};vi.render=function(t,e,r){if(!o1(e))throw Error(pe(200));return a1(null,t,e,!1,r)};vi.unmountComponentAtNode=function(t){if(!o1(t))throw Error(pe(40));return t._reactRootContainer?(Ku(function(){a1(null,null,t,!1,function(){t._reactRootContainer=null,t[ua]=null})}),!0):!1};vi.unstable_batchedUpdates=xT;vi.unstable_renderSubtreeIntoContainer=function(t,e,r,n){if(!o1(r))throw Error(pe(200));if(t==null||t._reactInternals===void 0)throw Error(pe(38));return a1(t,e,r,!1,n)};vi.version="18.3.1-next-f1338f8080-20240426";function yN(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(yN)}catch(t){console.error(t)}}yN(),yO.exports=vi;var mr=yO.exports,xN,II=mr;xN=II.createRoot,II.hydrateRoot;var am=t=>t.type==="checkbox",Ru=t=>t instanceof Date,wn=t=>t==null;const bN=t=>typeof t=="object";var ur=t=>!wn(t)&&!Array.isArray(t)&&bN(t)&&!Ru(t),wN=t=>ur(t)&&t.target?am(t.target)?t.target.checked:t.target.value:t,u$=t=>t.substring(0,t.search(/\.\d+(\.|$)/))||t,_N=(t,e)=>t.has(u$(e)),c$=t=>{const e=t.constructor&&t.constructor.prototype;return ur(e)&&e.hasOwnProperty("isPrototypeOf")},AT=typeof window<"u"&&typeof window.HTMLElement<"u"&&typeof document<"u";function Ln(t){let e;const r=Array.isArray(t);if(t instanceof Date)e=new Date(t);else if(t instanceof Set)e=new Set(t);else if(!(AT&&(t instanceof Blob||t instanceof FileList))&&(r||ur(t)))if(e=r?[]:{},!r&&!c$(t))e=t;else for(const n in t)t.hasOwnProperty(n)&&(e[n]=Ln(t[n]));else return t;return e}var l1=t=>Array.isArray(t)?t.filter(Boolean):[],er=t=>t===void 0,Se=(t,e,r)=>{if(!e||!ur(t))return r;const n=l1(e.split(/[,[\].]+?/)).reduce((i,s)=>wn(i)?i:i[s],t);return er(n)||n===t?er(t[e])?r:t[e]:n},ki=t=>typeof t=="boolean",RT=t=>/^\w*$/.test(t),SN=t=>l1(t.replace(/["|']|\]/g,"").split(/\.|\[/)),Pt=(t,e,r)=>{let n=-1;const i=RT(e)?[e]:SN(e),s=i.length,o=s-1;for(;++n<s;){const a=i[n];let l=r;if(n!==o){const u=t[a];l=ur(u)||Array.isArray(u)?u:isNaN(+i[n+1])?{}:[]}if(a==="__proto__")return;t[a]=l,t=t[a]}return t};const qv={BLUR:"blur",FOCUS_OUT:"focusout",CHANGE:"change"},gs={onBlur:"onBlur",onChange:"onChange",onSubmit:"onSubmit",onTouched:"onTouched",all:"all"},jo={max:"max",min:"min",maxLength:"maxLength",minLength:"minLength",pattern:"pattern",required:"required",validate:"validate"},d$=Ie.createContext(null),PT=()=>Ie.useContext(d$);var EN=(t,e,r,n=!0)=>{const i={defaultValues:e._defaultValues};for(const s in t)Object.defineProperty(i,s,{get:()=>{const o=s;return e._proxyFormState[o]!==gs.all&&(e._proxyFormState[o]=!n||gs.all),r&&(r[o]=!0),t[o]}});return i},Bn=t=>ur(t)&&!Object.keys(t).length,TN=(t,e,r,n)=>{r(t);const{name:i,...s}=t;return Bn(s)||Object.keys(s).length>=Object.keys(e).length||Object.keys(s).find(o=>e[o]===(!n||gs.all))},zf=t=>Array.isArray(t)?t:[t],CN=(t,e,r)=>!t||!e||t===e||zf(t).some(n=>n&&(r?n===e:n.startsWith(e)||e.startsWith(n)));function IT(t){const e=Ie.useRef(t);e.current=t,Ie.useEffect(()=>{const r=!t.disabled&&e.current.subject&&e.current.subject.subscribe({next:e.current.next});return()=>{r&&r.unsubscribe()}},[t.disabled])}function h$(t){const e=PT(),{control:r=e.control,disabled:n,name:i,exact:s}=t||{},[o,a]=Ie.useState(r._formState),l=Ie.useRef(!0),u=Ie.useRef({isDirty:!1,isLoading:!1,dirtyFields:!1,touchedFields:!1,validatingFields:!1,isValidating:!1,isValid:!1,errors:!1}),c=Ie.useRef(i);return c.current=i,IT({disabled:n,next:h=>l.current&&CN(c.current,h.name,s)&&TN(h,u.current,r._updateFormState)&&a({...r._formState,...h}),subject:r._subjects.state}),Ie.useEffect(()=>(l.current=!0,u.current.isValid&&r._updateValid(!0),()=>{l.current=!1}),[r]),EN(o,r,u.current,!1)}var uo=t=>typeof t=="string",AN=(t,e,r,n,i)=>uo(t)?(n&&e.watch.add(t),Se(r,t,i)):Array.isArray(t)?t.map(s=>(n&&e.watch.add(s),Se(r,s))):(n&&(e.watchAll=!0),r);function f$(t){const e=PT(),{control:r=e.control,name:n,defaultValue:i,disabled:s,exact:o}=t||{},a=Ie.useRef(n);a.current=n,IT({disabled:s,subject:r._subjects.values,next:c=>{CN(a.current,c.name,o)&&u(Ln(AN(a.current,r._names,c.values||r._formValues,!1,i)))}});const[l,u]=Ie.useState(r._getWatch(n,i));return Ie.useEffect(()=>r._removeUnmounted()),l}function p$(t){const e=PT(),{name:r,disabled:n,control:i=e.control,shouldUnregister:s}=t,o=_N(i._names.array,r),a=f$({control:i,name:r,defaultValue:Se(i._formValues,r,Se(i._defaultValues,r,t.defaultValue)),exact:!0}),l=h$({control:i,name:r,exact:!0}),u=Ie.useRef(i.register(r,{...t.rules,value:a,...ki(t.disabled)?{disabled:t.disabled}:{}}));return Ie.useEffect(()=>{const c=i._options.shouldUnregister||s,h=(f,m)=>{const y=Se(i._fields,f);y&&y._f&&(y._f.mount=m)};if(h(r,!0),c){const f=Ln(Se(i._options.defaultValues,r));Pt(i._defaultValues,r,f),er(Se(i._formValues,r))&&Pt(i._formValues,r,f)}return()=>{(o?c&&!i._state.action:c)?i.unregister(r):h(r,!1)}},[r,i,o,s]),Ie.useEffect(()=>{Se(i._fields,r)&&i._updateDisabledField({disabled:n,fields:i._fields,name:r,value:Se(i._fields,r)._f.value})},[n,r,i]),{field:{name:r,value:a,...ki(n)||l.disabled?{disabled:l.disabled||n}:{},onChange:Ie.useCallback(c=>u.current.onChange({target:{value:wN(c),name:r},type:qv.CHANGE}),[r]),onBlur:Ie.useCallback(()=>u.current.onBlur({target:{value:Se(i._formValues,r),name:r},type:qv.BLUR}),[r,i]),ref:Ie.useCallback(c=>{const h=Se(i._fields,r);h&&c&&(h._f.ref={focus:()=>c.focus(),select:()=>c.select(),setCustomValidity:f=>c.setCustomValidity(f),reportValidity:()=>c.reportValidity()})},[i._fields,r])},formState:l,fieldState:Object.defineProperties({},{invalid:{enumerable:!0,get:()=>!!Se(l.errors,r)},isDirty:{enumerable:!0,get:()=>!!Se(l.dirtyFields,r)},isTouched:{enumerable:!0,get:()=>!!Se(l.touchedFields,r)},isValidating:{enumerable:!0,get:()=>!!Se(l.validatingFields,r)},error:{enumerable:!0,get:()=>Se(l.errors,r)}})}}const u1=t=>t.render(p$(t));var m$=(t,e,r,n,i)=>e?{...r[t],types:{...r[t]&&r[t].types?r[t].types:{},[n]:i||!0}}:{},MI=t=>({isOnSubmit:!t||t===gs.onSubmit,isOnBlur:t===gs.onBlur,isOnChange:t===gs.onChange,isOnAll:t===gs.all,isOnTouch:t===gs.onTouched}),kI=(t,e,r)=>!r&&(e.watchAll||e.watch.has(t)||[...e.watch].some(n=>t.startsWith(n)&&/^\.\w+/.test(t.slice(n.length))));const Hf=(t,e,r,n)=>{for(const i of r||Object.keys(t)){const s=Se(t,i);if(s){const{_f:o,...a}=s;if(o){if(o.refs&&o.refs[0]&&e(o.refs[0],i)&&!n)return!0;if(o.ref&&e(o.ref,o.name)&&!n)return!0;if(Hf(a,e))break}else if(ur(a)&&Hf(a,e))break}}};var g$=(t,e,r)=>{const n=zf(Se(t,r));return Pt(n,"root",e[r]),Pt(t,r,n),t},MT=t=>t.type==="file",ao=t=>typeof t=="function",Yv=t=>{if(!AT)return!1;const e=t?t.ownerDocument:0;return t instanceof(e&&e.defaultView?e.defaultView.HTMLElement:HTMLElement)},Y0=t=>uo(t),kT=t=>t.type==="radio",Qv=t=>t instanceof RegExp;const OI={value:!1,isValid:!1},DI={value:!0,isValid:!0};var RN=t=>{if(Array.isArray(t)){if(t.length>1){const e=t.filter(r=>r&&r.checked&&!r.disabled).map(r=>r.value);return{value:e,isValid:!!e.length}}return t[0].checked&&!t[0].disabled?t[0].attributes&&!er(t[0].attributes.value)?er(t[0].value)||t[0].value===""?DI:{value:t[0].value,isValid:!0}:DI:OI}return OI};const NI={isValid:!1,value:null};var PN=t=>Array.isArray(t)?t.reduce((e,r)=>r&&r.checked&&!r.disabled?{isValid:!0,value:r.value}:e,NI):NI;function LI(t,e,r="validate"){if(Y0(t)||Array.isArray(t)&&t.every(Y0)||ki(t)&&!t)return{type:r,message:Y0(t)?t:"",ref:e}}var Oc=t=>ur(t)&&!Qv(t)?t:{value:t,message:""},FI=async(t,e,r,n,i)=>{const{ref:s,refs:o,required:a,maxLength:l,minLength:u,min:c,max:h,pattern:f,validate:m,name:y,valueAsNumber:v,mount:x,disabled:b}=t._f,_=Se(e,y);if(!x||b)return{};const w=o?o[0]:s,E=H=>{n&&w.reportValidity&&(w.setCustomValidity(ki(H)?"":H||""),w.reportValidity())},A={},P=kT(s),I=am(s),M=P||I,N=(v||MT(s))&&er(s.value)&&er(_)||Yv(s)&&s.value===""||_===""||Array.isArray(_)&&!_.length,z=m$.bind(null,y,r,A),j=(H,F,L,O=jo.maxLength,$=jo.minLength)=>{const V=H?F:L;A[y]={type:H?O:$,message:V,ref:s,...z(H?O:$,V)}};if(i?!Array.isArray(_)||!_.length:a&&(!M&&(N||wn(_))||ki(_)&&!_||I&&!RN(o).isValid||P&&!PN(o).isValid)){const{value:H,message:F}=Y0(a)?{value:!!a,message:a}:Oc(a);if(H&&(A[y]={type:jo.required,message:F,ref:w,...z(jo.required,F)},!r))return E(F),A}if(!N&&(!wn(c)||!wn(h))){let H,F;const L=Oc(h),O=Oc(c);if(!wn(_)&&!isNaN(_)){const $=s.valueAsNumber||_&&+_;wn(L.value)||(H=$>L.value),wn(O.value)||(F=$<O.value)}else{const $=s.valueAsDate||new Date(_),V=B=>new Date(new Date().toDateString()+" "+B),k=s.type=="time",U=s.type=="week";uo(L.value)&&_&&(H=k?V(_)>V(L.value):U?_>L.value:$>new Date(L.value)),uo(O.value)&&_&&(F=k?V(_)<V(O.value):U?_<O.value:$<new Date(O.value))}if((H||F)&&(j(!!H,L.message,O.message,jo.max,jo.min),!r))return E(A[y].message),A}if((l||u)&&!N&&(uo(_)||i&&Array.isArray(_))){const H=Oc(l),F=Oc(u),L=!wn(H.value)&&_.length>+H.value,O=!wn(F.value)&&_.length<+F.value;if((L||O)&&(j(L,H.message,F.message),!r))return E(A[y].message),A}if(f&&!N&&uo(_)){const{value:H,message:F}=Oc(f);if(Qv(H)&&!_.match(H)&&(A[y]={type:jo.pattern,message:F,ref:s,...z(jo.pattern,F)},!r))return E(F),A}if(m){if(ao(m)){const H=await m(_,e),F=LI(H,w);if(F&&(A[y]={...F,...z(jo.validate,F.message)},!r))return E(F.message),A}else if(ur(m)){let H={};for(const F in m){if(!Bn(H)&&!r)break;const L=LI(await m[F](_,e),w,F);L&&(H={...L,...z(F,L.message)},E(L.message),r&&(A[y]=H))}if(!Bn(H)&&(A[y]={ref:w,...H},!r))return A}}return E(!0),A};function v$(t,e){const r=e.slice(0,-1).length;let n=0;for(;n<r;)t=er(t)?n++:t[e[n++]];return t}function y$(t){for(const e in t)if(t.hasOwnProperty(e)&&!er(t[e]))return!1;return!0}function yr(t,e){const r=Array.isArray(e)?e:RT(e)?[e]:SN(e),n=r.length===1?t:v$(t,r),i=r.length-1,s=r[i];return n&&delete n[s],i!==0&&(ur(n)&&Bn(n)||Array.isArray(n)&&y$(n))&&yr(t,r.slice(0,-1)),t}var Zb=()=>{let t=[];return{get observers(){return t},next:i=>{for(const s of t)s.next&&s.next(i)},subscribe:i=>(t.push(i),{unsubscribe:()=>{t=t.filter(s=>s!==i)}}),unsubscribe:()=>{t=[]}}},ES=t=>wn(t)||!bN(t);function qa(t,e){if(ES(t)||ES(e))return t===e;if(Ru(t)&&Ru(e))return t.getTime()===e.getTime();const r=Object.keys(t),n=Object.keys(e);if(r.length!==n.length)return!1;for(const i of r){const s=t[i];if(!n.includes(i))return!1;if(i!=="ref"){const o=e[i];if(Ru(s)&&Ru(o)||ur(s)&&ur(o)||Array.isArray(s)&&Array.isArray(o)?!qa(s,o):s!==o)return!1}}return!0}var IN=t=>t.type==="select-multiple",x$=t=>kT(t)||am(t),Jb=t=>Yv(t)&&t.isConnected,MN=t=>{for(const e in t)if(ao(t[e]))return!0;return!1};function Kv(t,e={}){const r=Array.isArray(t);if(ur(t)||r)for(const n in t)Array.isArray(t[n])||ur(t[n])&&!MN(t[n])?(e[n]=Array.isArray(t[n])?[]:{},Kv(t[n],e[n])):wn(t[n])||(e[n]=!0);return e}function kN(t,e,r){const n=Array.isArray(t);if(ur(t)||n)for(const i in t)Array.isArray(t[i])||ur(t[i])&&!MN(t[i])?er(e)||ES(r[i])?r[i]=Array.isArray(t[i])?Kv(t[i],[]):{...Kv(t[i])}:kN(t[i],wn(e)?{}:e[i],r[i]):r[i]=!qa(t[i],e[i]);return r}var Jh=(t,e)=>kN(t,e,Kv(e)),ON=(t,{valueAsNumber:e,valueAsDate:r,setValueAs:n})=>er(t)?t:e?t===""?NaN:t&&+t:r&&uo(t)?new Date(t):n?n(t):t;function ew(t){const e=t.ref;if(!(t.refs?t.refs.every(r=>r.disabled):e.disabled))return MT(e)?e.files:kT(e)?PN(t.refs).value:IN(e)?[...e.selectedOptions].map(({value:r})=>r):am(e)?RN(t.refs).value:ON(er(e.value)?t.ref.value:e.value,t)}var b$=(t,e,r,n)=>{const i={};for(const s of t){const o=Se(e,s);o&&Pt(i,s,o._f)}return{criteriaMode:r,names:[...t],fields:i,shouldUseNativeValidation:n}},ef=t=>er(t)?t:Qv(t)?t.source:ur(t)?Qv(t.value)?t.value.source:t.value:t;const jI="AsyncFunction";var w$=t=>(!t||!t.validate)&&!!(ao(t.validate)&&t.validate.constructor.name===jI||ur(t.validate)&&Object.values(t.validate).find(e=>e.constructor.name===jI)),_$=t=>t.mount&&(t.required||t.min||t.max||t.maxLength||t.minLength||t.pattern||t.validate);function BI(t,e,r){const n=Se(t,r);if(n||RT(r))return{error:n,name:r};const i=r.split(".");for(;i.length;){const s=i.join("."),o=Se(e,s),a=Se(t,s);if(o&&!Array.isArray(o)&&r!==s)return{name:r};if(a&&a.type)return{name:s,error:a};i.pop()}return{name:r}}var S$=(t,e,r,n,i)=>i.isOnAll?!1:!r&&i.isOnTouch?!(e||t):(r?n.isOnBlur:i.isOnBlur)?!t:(r?n.isOnChange:i.isOnChange)?t:!0,E$=(t,e)=>!l1(Se(t,e)).length&&yr(t,e);const T$={mode:gs.onSubmit,reValidateMode:gs.onChange,shouldFocusError:!0};function C$(t={}){let e={...T$,...t},r={submitCount:0,isDirty:!1,isLoading:ao(e.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1},n={},i=ur(e.defaultValues)||ur(e.values)?Ln(e.defaultValues||e.values)||{}:{},s=e.shouldUnregister?{}:Ln(i),o={action:!1,mount:!1,watch:!1},a={mount:new Set,unMount:new Set,array:new Set,watch:new Set},l,u=0;const c={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1},h={values:Zb(),array:Zb(),state:Zb()},f=MI(e.mode),m=MI(e.reValidateMode),y=e.criteriaMode===gs.all,v=W=>J=>{clearTimeout(u),u=setTimeout(W,J)},x=async W=>{if(!e.disabled&&(c.isValid||W)){const J=e.resolver?Bn((await M()).errors):await z(n,!0);J!==r.isValid&&h.state.next({isValid:J})}},b=(W,J)=>{!e.disabled&&(c.isValidating||c.validatingFields)&&((W||Array.from(a.mount)).forEach(te=>{te&&(J?Pt(r.validatingFields,te,J):yr(r.validatingFields,te))}),h.state.next({validatingFields:r.validatingFields,isValidating:!Bn(r.validatingFields)}))},_=(W,J=[],te,be,ge=!0,ce=!0)=>{if(be&&te&&!e.disabled){if(o.action=!0,ce&&Array.isArray(Se(n,W))){const ke=te(Se(n,W),be.argA,be.argB);ge&&Pt(n,W,ke)}if(ce&&Array.isArray(Se(r.errors,W))){const ke=te(Se(r.errors,W),be.argA,be.argB);ge&&Pt(r.errors,W,ke),E$(r.errors,W)}if(c.touchedFields&&ce&&Array.isArray(Se(r.touchedFields,W))){const ke=te(Se(r.touchedFields,W),be.argA,be.argB);ge&&Pt(r.touchedFields,W,ke)}c.dirtyFields&&(r.dirtyFields=Jh(i,s)),h.state.next({name:W,isDirty:H(W,J),dirtyFields:r.dirtyFields,errors:r.errors,isValid:r.isValid})}else Pt(s,W,J)},w=(W,J)=>{Pt(r.errors,W,J),h.state.next({errors:r.errors})},E=W=>{r.errors=W,h.state.next({errors:r.errors,isValid:!1})},A=(W,J,te,be)=>{const ge=Se(n,W);if(ge){const ce=Se(s,W,er(te)?Se(i,W):te);er(ce)||be&&be.defaultChecked||J?Pt(s,W,J?ce:ew(ge._f)):O(W,ce),o.mount&&x()}},P=(W,J,te,be,ge)=>{let ce=!1,ke=!1;const et={name:W};if(!e.disabled){const ze=!!(Se(n,W)&&Se(n,W)._f&&Se(n,W)._f.disabled);if(!te||be){c.isDirty&&(ke=r.isDirty,r.isDirty=et.isDirty=H(),ce=ke!==et.isDirty);const Ue=ze||qa(Se(i,W),J);ke=!!(!ze&&Se(r.dirtyFields,W)),Ue||ze?yr(r.dirtyFields,W):Pt(r.dirtyFields,W,!0),et.dirtyFields=r.dirtyFields,ce=ce||c.dirtyFields&&ke!==!Ue}if(te){const Ue=Se(r.touchedFields,W);Ue||(Pt(r.touchedFields,W,te),et.touchedFields=r.touchedFields,ce=ce||c.touchedFields&&Ue!==te)}ce&&ge&&h.state.next(et)}return ce?et:{}},I=(W,J,te,be)=>{const ge=Se(r.errors,W),ce=c.isValid&&ki(J)&&r.isValid!==J;if(t.delayError&&te?(l=v(()=>w(W,te)),l(t.delayError)):(clearTimeout(u),l=null,te?Pt(r.errors,W,te):yr(r.errors,W)),(te?!qa(ge,te):ge)||!Bn(be)||ce){const ke={...be,...ce&&ki(J)?{isValid:J}:{},errors:r.errors,name:W};r={...r,...ke},h.state.next(ke)}},M=async W=>{b(W,!0);const J=await e.resolver(s,e.context,b$(W||a.mount,n,e.criteriaMode,e.shouldUseNativeValidation));return b(W),J},N=async W=>{const{errors:J}=await M(W);if(W)for(const te of W){const be=Se(J,te);be?Pt(r.errors,te,be):yr(r.errors,te)}else r.errors=J;return J},z=async(W,J,te={valid:!0})=>{for(const be in W){const ge=W[be];if(ge){const{_f:ce,...ke}=ge;if(ce){const et=a.array.has(ce.name),ze=ge._f&&w$(ge._f);ze&&c.validatingFields&&b([be],!0);const Ue=await FI(ge,s,y,e.shouldUseNativeValidation&&!J,et);if(ze&&c.validatingFields&&b([be]),Ue[ce.name]&&(te.valid=!1,J))break;!J&&(Se(Ue,ce.name)?et?g$(r.errors,Ue,ce.name):Pt(r.errors,ce.name,Ue[ce.name]):yr(r.errors,ce.name))}!Bn(ke)&&await z(ke,J,te)}}return te.valid},j=()=>{for(const W of a.unMount){const J=Se(n,W);J&&(J._f.refs?J._f.refs.every(te=>!Jb(te)):!Jb(J._f.ref))&&le(W)}a.unMount=new Set},H=(W,J)=>!e.disabled&&(W&&J&&Pt(s,W,J),!qa(X(),i)),F=(W,J,te)=>AN(W,a,{...o.mount?s:er(J)?i:uo(W)?{[W]:J}:J},te,J),L=W=>l1(Se(o.mount?s:i,W,t.shouldUnregister?Se(i,W,[]):[])),O=(W,J,te={})=>{const be=Se(n,W);let ge=J;if(be){const ce=be._f;ce&&(!ce.disabled&&Pt(s,W,ON(J,ce)),ge=Yv(ce.ref)&&wn(J)?"":J,IN(ce.ref)?[...ce.ref.options].forEach(ke=>ke.selected=ge.includes(ke.value)):ce.refs?am(ce.ref)?ce.refs.length>1?ce.refs.forEach(ke=>(!ke.defaultChecked||!ke.disabled)&&(ke.checked=Array.isArray(ge)?!!ge.find(et=>et===ke.value):ge===ke.value)):ce.refs[0]&&(ce.refs[0].checked=!!ge):ce.refs.forEach(ke=>ke.checked=ke.value===ge):MT(ce.ref)?ce.ref.value="":(ce.ref.value=ge,ce.ref.type||h.values.next({name:W,values:{...s}})))}(te.shouldDirty||te.shouldTouch)&&P(W,ge,te.shouldTouch,te.shouldDirty,!0),te.shouldValidate&&B(W)},$=(W,J,te)=>{for(const be in J){const ge=J[be],ce=`${W}.${be}`,ke=Se(n,ce);(a.array.has(W)||ur(ge)||ke&&!ke._f)&&!Ru(ge)?$(ce,ge,te):O(ce,ge,te)}},V=(W,J,te={})=>{const be=Se(n,W),ge=a.array.has(W),ce=Ln(J);Pt(s,W,ce),ge?(h.array.next({name:W,values:{...s}}),(c.isDirty||c.dirtyFields)&&te.shouldDirty&&h.state.next({name:W,dirtyFields:Jh(i,s),isDirty:H(W,ce)})):be&&!be._f&&!wn(ce)?$(W,ce,te):O(W,ce,te),kI(W,a)&&h.state.next({...r}),h.values.next({name:o.mount?W:void 0,values:{...s}})},k=async W=>{o.mount=!0;const J=W.target;let te=J.name,be=!0;const ge=Se(n,te),ce=()=>J.type?ew(ge._f):wN(W),ke=et=>{be=Number.isNaN(et)||Ru(et)&&isNaN(et.getTime())||qa(et,Se(s,te,et))};if(ge){let et,ze;const Ue=ce(),$e=W.type===qv.BLUR||W.type===qv.FOCUS_OUT,pt=!_$(ge._f)&&!e.resolver&&!Se(r.errors,te)&&!ge._f.deps||S$($e,Se(r.touchedFields,te),r.isSubmitted,m,f),Pr=kI(te,a,$e);Pt(s,te,Ue),$e?(ge._f.onBlur&&ge._f.onBlur(W),l&&l(0)):ge._f.onChange&&ge._f.onChange(W);const Dt=P(te,Ue,$e,!1),ct=!Bn(Dt)||Pr;if(!$e&&h.values.next({name:te,type:W.type,values:{...s}}),pt)return c.isValid&&(t.mode==="onBlur"?$e&&x():x()),ct&&h.state.next({name:te,...Pr?{}:Dt});if(!$e&&Pr&&h.state.next({...r}),e.resolver){const{errors:Qe}=await M([te]);if(ke(Ue),be){const tn=BI(r.errors,n,te),bi=BI(Qe,n,tn.name||te);et=bi.error,te=bi.name,ze=Bn(Qe)}}else b([te],!0),et=(await FI(ge,s,y,e.shouldUseNativeValidation))[te],b([te]),ke(Ue),be&&(et?ze=!1:c.isValid&&(ze=await z(n,!0)));be&&(ge._f.deps&&B(ge._f.deps),I(te,ze,et,Dt))}},U=(W,J)=>{if(Se(r.errors,J)&&W.focus)return W.focus(),1},B=async(W,J={})=>{let te,be;const ge=zf(W);if(e.resolver){const ce=await N(er(W)?W:ge);te=Bn(ce),be=W?!ge.some(ke=>Se(ce,ke)):te}else W?(be=(await Promise.all(ge.map(async ce=>{const ke=Se(n,ce);return await z(ke&&ke._f?{[ce]:ke}:ke)}))).every(Boolean),!(!be&&!r.isValid)&&x()):be=te=await z(n);return h.state.next({...!uo(W)||c.isValid&&te!==r.isValid?{}:{name:W},...e.resolver||!W?{isValid:te}:{},errors:r.errors}),J.shouldFocus&&!be&&Hf(n,U,W?ge:a.mount),be},X=W=>{const J={...o.mount?s:i};return er(W)?J:uo(W)?Se(J,W):W.map(te=>Se(J,te))},K=(W,J)=>({invalid:!!Se((J||r).errors,W),isDirty:!!Se((J||r).dirtyFields,W),error:Se((J||r).errors,W),isValidating:!!Se(r.validatingFields,W),isTouched:!!Se((J||r).touchedFields,W)}),q=W=>{W&&zf(W).forEach(J=>yr(r.errors,J)),h.state.next({errors:W?r.errors:{}})},re=(W,J,te)=>{const be=(Se(n,W,{_f:{}})._f||{}).ref,ge=Se(r.errors,W)||{},{ref:ce,message:ke,type:et,...ze}=ge;Pt(r.errors,W,{...ze,...J,ref:be}),h.state.next({name:W,errors:r.errors,isValid:!1}),te&&te.shouldFocus&&be&&be.focus&&be.focus()},ue=(W,J)=>ao(W)?h.values.subscribe({next:te=>W(F(void 0,J),te)}):F(W,J,!0),le=(W,J={})=>{for(const te of W?zf(W):a.mount)a.mount.delete(te),a.array.delete(te),J.keepValue||(yr(n,te),yr(s,te)),!J.keepError&&yr(r.errors,te),!J.keepDirty&&yr(r.dirtyFields,te),!J.keepTouched&&yr(r.touchedFields,te),!J.keepIsValidating&&yr(r.validatingFields,te),!e.shouldUnregister&&!J.keepDefaultValue&&yr(i,te);h.values.next({values:{...s}}),h.state.next({...r,...J.keepDirty?{isDirty:H()}:{}}),!J.keepIsValid&&x()},me=({disabled:W,name:J,field:te,fields:be,value:ge})=>{if(ki(W)&&o.mount||W){const ce=W?void 0:er(ge)?ew(te?te._f:Se(be,J)._f):ge;Pt(s,J,ce),P(J,ce,!1,!1,!0)}},xe=(W,J={})=>{let te=Se(n,W);const be=ki(J.disabled)||ki(e.disabled);return Pt(n,W,{...te||{},_f:{...te&&te._f?te._f:{ref:{name:W}},name:W,mount:!0,...J}}),a.mount.add(W),te?me({field:te,disabled:ki(J.disabled)?J.disabled:e.disabled,name:W,value:J.value}):A(W,!0,J.value),{...be?{disabled:J.disabled||e.disabled}:{},...e.progressive?{required:!!J.required,min:ef(J.min),max:ef(J.max),minLength:ef(J.minLength),maxLength:ef(J.maxLength),pattern:ef(J.pattern)}:{},name:W,onChange:k,onBlur:k,ref:ge=>{if(ge){xe(W,J),te=Se(n,W);const ce=er(ge.value)&&ge.querySelectorAll&&ge.querySelectorAll("input,select,textarea")[0]||ge,ke=x$(ce),et=te._f.refs||[];if(ke?et.find(ze=>ze===ce):ce===te._f.ref)return;Pt(n,W,{_f:{...te._f,...ke?{refs:[...et.filter(Jb),ce,...Array.isArray(Se(i,W))?[{}]:[]],ref:{type:ce.type,name:W}}:{ref:ce}}}),A(W,!1,void 0,ce)}else te=Se(n,W,{}),te._f&&(te._f.mount=!1),(e.shouldUnregister||J.shouldUnregister)&&!(_N(a.array,W)&&o.action)&&a.unMount.add(W)}}},_e=()=>e.shouldFocusError&&Hf(n,U,a.mount),Te=W=>{ki(W)&&(h.state.next({disabled:W}),Hf(n,(J,te)=>{const be=Se(n,te);be&&(J.disabled=be._f.disabled||W,Array.isArray(be._f.refs)&&be._f.refs.forEach(ge=>{ge.disabled=be._f.disabled||W}))},0,!1))},de=(W,J)=>async te=>{let be;if(te&&(te.preventDefault&&te.preventDefault(),te.persist&&te.persist()),e.disabled){J&&await J({...r.errors},te);return}let ge=Ln(s);if(h.state.next({isSubmitting:!0}),e.resolver){const{errors:ce,values:ke}=await M();r.errors=ce,ge=ke}else await z(n);if(yr(r.errors,"root"),Bn(r.errors)){h.state.next({errors:{}});try{await W(ge,te)}catch(ce){be=ce}}else J&&await J({...r.errors},te),_e(),setTimeout(_e);if(h.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:Bn(r.errors)&&!be,submitCount:r.submitCount+1,errors:r.errors}),be)throw be},Be=(W,J={})=>{Se(n,W)&&(er(J.defaultValue)?V(W,Ln(Se(i,W))):(V(W,J.defaultValue),Pt(i,W,Ln(J.defaultValue))),J.keepTouched||yr(r.touchedFields,W),J.keepDirty||(yr(r.dirtyFields,W),r.isDirty=J.defaultValue?H(W,Ln(Se(i,W))):H()),J.keepError||(yr(r.errors,W),c.isValid&&x()),h.state.next({...r}))},je=(W,J={})=>{const te=W?Ln(W):i,be=Ln(te),ge=Bn(W),ce=ge?i:be;if(J.keepDefaultValues||(i=te),!J.keepValues){if(J.keepDirtyValues){const ke=new Set([...a.mount,...Object.keys(Jh(i,s))]);for(const et of Array.from(ke))Se(r.dirtyFields,et)?Pt(ce,et,Se(s,et)):V(et,Se(ce,et))}else{if(AT&&er(W))for(const ke of a.mount){const et=Se(n,ke);if(et&&et._f){const ze=Array.isArray(et._f.refs)?et._f.refs[0]:et._f.ref;if(Yv(ze)){const Ue=ze.closest("form");if(Ue){Ue.reset();break}}}}n={}}s=t.shouldUnregister?J.keepDefaultValues?Ln(i):{}:Ln(ce),h.array.next({values:{...ce}}),h.values.next({values:{...ce}})}a={mount:J.keepDirtyValues?a.mount:new Set,unMount:new Set,array:new Set,watch:new Set,watchAll:!1,focus:""},o.mount=!c.isValid||!!J.keepIsValid||!!J.keepDirtyValues,o.watch=!!t.shouldUnregister,h.state.next({submitCount:J.keepSubmitCount?r.submitCount:0,isDirty:ge?!1:J.keepDirty?r.isDirty:!!(J.keepDefaultValues&&!qa(W,i)),isSubmitted:J.keepIsSubmitted?r.isSubmitted:!1,dirtyFields:ge?{}:J.keepDirtyValues?J.keepDefaultValues&&s?Jh(i,s):r.dirtyFields:J.keepDefaultValues&&W?Jh(i,W):J.keepDirty?r.dirtyFields:{},touchedFields:J.keepTouched?r.touchedFields:{},errors:J.keepErrors?r.errors:{},isSubmitSuccessful:J.keepIsSubmitSuccessful?r.isSubmitSuccessful:!1,isSubmitting:!1})},ut=(W,J)=>je(ao(W)?W(s):W,J);return{control:{register:xe,unregister:le,getFieldState:K,handleSubmit:de,setError:re,_executeSchema:M,_getWatch:F,_getDirty:H,_updateValid:x,_removeUnmounted:j,_updateFieldArray:_,_updateDisabledField:me,_getFieldArray:L,_reset:je,_resetDefaultValues:()=>ao(e.defaultValues)&&e.defaultValues().then(W=>{ut(W,e.resetOptions),h.state.next({isLoading:!1})}),_updateFormState:W=>{r={...r,...W}},_disableForm:Te,_subjects:h,_proxyFormState:c,_setErrors:E,get _fields(){return n},get _formValues(){return s},get _state(){return o},set _state(W){o=W},get _defaultValues(){return i},get _names(){return a},set _names(W){a=W},get _formState(){return r},set _formState(W){r=W},get _options(){return e},set _options(W){e={...e,...W}}},trigger:B,register:xe,handleSubmit:de,watch:ue,setValue:V,getValues:X,reset:ut,resetField:Be,clearErrors:q,unregister:le,setError:re,setFocus:(W,J={})=>{const te=Se(n,W),be=te&&te._f;if(be){const ge=be.refs?be.refs[0]:be.ref;ge.focus&&(ge.focus(),J.shouldSelect&&ao(ge.select)&&ge.select())}},getFieldState:K}}function OT(t={}){const e=Ie.useRef(),r=Ie.useRef(),[n,i]=Ie.useState({isDirty:!1,isValidating:!1,isLoading:ao(t.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:t.errors||{},disabled:t.disabled||!1,defaultValues:ao(t.defaultValues)?void 0:t.defaultValues});e.current||(e.current={...C$(t),formState:n});const s=e.current.control;return s._options=t,IT({subject:s._subjects.state,next:o=>{TN(o,s._proxyFormState,s._updateFormState,!0)&&i({...s._formState})}}),Ie.useEffect(()=>s._disableForm(t.disabled),[s,t.disabled]),Ie.useEffect(()=>{if(s._proxyFormState.isDirty){const o=s._getDirty();o!==n.isDirty&&s._subjects.state.next({isDirty:o})}},[s,n.isDirty]),Ie.useEffect(()=>{t.values&&!qa(t.values,r.current)?(s._reset(t.values,s._options.resetOptions),r.current=t.values,i(o=>({...o}))):s._resetDefaultValues()},[t.values,s]),Ie.useEffect(()=>{t.errors&&s._setErrors(t.errors)},[t.errors,s]),Ie.useEffect(()=>{s._state.mount||(s._updateValid(),s._state.mount=!0),s._state.watch&&(s._state.watch=!1,s._subjects.state.next({...s._formState})),s._removeUnmounted()}),Ie.useEffect(()=>{t.shouldUnregister&&s._subjects.values.next({values:s._getWatch()})},[t.shouldUnregister,s]),e.current.formState=EN(n,s),e.current}function DN(t){var e,r,n="";if(typeof t=="string"||typeof t=="number")n+=t;else if(typeof t=="object")if(Array.isArray(t)){var i=t.length;for(e=0;e<i;e++)t[e]&&(r=DN(t[e]))&&(n&&(n+=" "),n+=r)}else for(r in t)t[r]&&(n&&(n+=" "),n+=r);return n}function Re(){for(var t,e,r=0,n="",i=arguments.length;r<i;r++)(t=arguments[r])&&(e=DN(t))&&(n&&(n+=" "),n+=e);return n}const A$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18M1 12C1 5.925 5.925 1 12 1s11 4.925 11 11-4.925 11-11 11S1 18.075 1 12",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 6a1 1 0 0 1 1 1v5a1 1 0 1 1-2 0V7a1 1 0 0 1 1-1M11 16a1 1 0 0 1 1-1h.01a1 1 0 1 1 0 2H12a1 1 0 0 1-1-1",clipRule:"evenodd"})]}),R$=A$,P$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M1 3c0-1.1.9-2 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2zm8 0H3v6h6zm4 0c0-1.1.9-2 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2h-6a2 2 0 0 1-2-2zm8 0h-6v6h6zm-8 12c0-1.1.9-2 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2h-6a2 2 0 0 1-2-2zm8 0h-6v6h6zM1 15c0-1.1.9-2 2-2h6a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2zm8 0H3v6h6z",clipRule:"evenodd"})]}),NN=P$,I$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 12a1 1 0 0 1 1-1h14a1 1 0 1 1 0 2H5a1 1 0 0 1-1-1",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12.707 4.293a1 1 0 0 1 0 1.414L6.414 12l6.293 6.293a1 1 0 0 1-1.414 1.414l-7-7a1 1 0 0 1 0-1.414l7-7a1 1 0 0 1 1.414 0",clipRule:"evenodd"})]}),M$=I$,k$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 12a1 1 0 0 1 1-1h14a1 1 0 1 1 0 2H5a1 1 0 0 1-1-1",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M11.293 4.293a1 1 0 0 1 1.414 0l7 7a1 1 0 0 1 0 1.414l-7 7a1 1 0 0 1-1.414-1.414L17.586 12l-6.293-6.293a1 1 0 0 1 0-1.414",clipRule:"evenodd"})]}),TS=k$,O$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("g",{fill:"currentColor",fillRule:"evenodd",clipPath:"url(#blur_svg__a)",clipRule:"evenodd",children:g.jsx("path",{d:"M17.504 1.673a1 1 0 0 1 .932.491c.37.63.9 1.935 1.404 3.18l.08.197c.502 1.24.994 2.457 1.369 3.205l-.895.447.895-.447c.561 1.122 1.962 4.049 2.136 6.753.087 1.364-.125 2.839-1.094 3.978-.987 1.16-2.573 1.76-4.757 1.76-2.186 0-3.777-.6-4.777-1.752-.983-1.134-1.221-2.604-1.152-3.973.138-2.711 1.514-5.636 2.13-6.79.86-1.611 2.414-5.32 2.874-6.433a1 1 0 0 1 .855-.616m.104 3.492c-.657 1.533-1.496 3.425-2.07 4.5-.59 1.106-1.781 3.703-1.895 5.949-.057 1.11.158 1.976.665 2.56.49.565 1.427 1.063 3.266 1.063 1.84 0 2.76-.498 3.233-1.055.492-.579.694-1.44.622-2.555-.145-2.253-1.36-4.848-1.929-5.986-.412-.823-.932-2.108-1.417-3.308l-.097-.238q-.196-.487-.378-.93M12.843 22.535a1 1 0 0 1-1.034.964l-.259-.009a1 1 0 0 1-.257-.042q-.125.029-.26.024l-.257-.009a11 11 0 0 1-2.102-.279 1 1 0 0 1 .457-1.947 9 9 0 0 0 1.715.228l.258.009q.134.004.257.042.125-.028.26-.024l.257.009a1 1 0 0 1 .965 1.034m-6.615-1.329a1 1 0 0 1-1.396.226 10.9 10.9 0 0 1-2.877-3.086 1 1 0 1 1 1.7-1.054 8.9 8.9 0 0 0 2.347 2.518 1 1 0 0 1 .226 1.396M1.622 15.22a1 1 0 0 1-1.147-.827 10.9 10.9 0 0 1 .148-4.218 1 1 0 0 1 1.947.457 8.9 8.9 0 0 0-.12 3.441 1 1 0 0 1-.828 1.147m.978-7.49a1 1 0 0 1-.226-1.397A10.9 10.9 0 0 1 5.46 3.455a1 1 0 0 1 1.054 1.7 8.9 8.9 0 0 0-2.518 2.347 1 1 0 0 1-1.396.226m5.988-4.607a1 1 0 0 1 .827-1.147 11 11 0 0 1 2.116-.132l.258.01q.135.004.257.042.125-.03.26-.025l.258.01a1 1 0 0 1-.07 1.998l-.258-.009a1 1 0 0 1-.258-.043q-.125.03-.259.025l-.258-.009a9 9 0 0 0-1.727.108 1 1 0 0 1-1.146-.828"})}),g.jsx("defs",{children:g.jsx("clipPath",{id:"blur_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),D$=O$,N$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",d:"M7 4a1 1 0 0 0-1 1v14.06l5.42-3.87a1 1 0 0 1 1.16 0L18 19.06V5a1 1 0 0 0-1-1zM4.88 2.88A3 3 0 0 1 7 2h10a3 3 0 0 1 3 3v16a1 1 0 0 1-1.58.81L12 17.23 5.58 21.8A1 1 0 0 1 4 21V5a3 3 0 0 1 .88-2.12"})]}),DT=N$,L$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M21 5c0 .828-.711 1.5-1.588 1.5H4.588C3.711 6.5 3 5.828 3 5s.711-1.5 1.588-1.5h14.824C20.289 3.5 21 4.172 21 5M21 12c0 .828-.711 1.5-1.588 1.5H4.588C3.711 13.5 3 12.828 3 12s.711-1.5 1.588-1.5h14.824c.877 0 1.588.672 1.588 1.5M21 19c0 .828-.711 1.5-1.588 1.5H4.588C3.711 20.5 3 19.828 3 19s.711-1.5 1.588-1.5h14.824c.877 0 1.588.672 1.588 1.5",clipRule:"evenodd"})]}),F$=L$,j$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4.222 4.222a1.1 1.1 0 0 1 1.556 0l14 14a1.1 1.1 0 1 1-1.556 1.556l-14-14a1.1 1.1 0 0 1 0-1.556",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M19.778 4.222a1.1 1.1 0 0 1 0 1.556l-14 14a1.1 1.1 0 1 1-1.556-1.556l14-14a1.1 1.1 0 0 1 1.556 0",clipRule:"evenodd"})]}),NT=j$,B$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M17.327 5.76a1 1 0 0 1 1.413.067l5 5.5a1 1 0 0 1 0 1.346l-5 5.5a1 1 0 1 1-1.48-1.346L21.648 12 17.26 7.173a1 1 0 0 1 .067-1.413M6.673 5.76a1 1 0 0 1 .067 1.413L2.35 12l4.389 4.827a1 1 0 0 1-1.48 1.346l-5-5.5a1 1 0 0 1 0-1.346l5-5.5a1 1 0 0 1 1.413-.067M8.979 21.609a1 1 0 0 1-.658-1.252l5.375-17.29a1 1 0 1 1 1.91.594L10.23 20.95a1 1 0 0 1-1.251.658",clipRule:"evenodd"})]}),CS=B$,U$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M6.676 3c.284-.672.853-1 1.263-1h11.423c.566 0 1.438.628 1.438 1.923v13.154c0 1.056-.58 1.668-1.1 1.858V6.923C19.7 4.99 18.3 3 16.061 3zm-2.272.007C4.765 1.41 6.056 0 7.939 0h11.423C21.599 0 23 1.99 23 3.923v13.154c0 1.865-1.303 3.782-3.403 3.916C19.235 22.59 17.944 24 16.06 24H4.638C2.401 24 1 22.01 1 20.077V6.923c0-1.865 1.303-3.782 3.404-3.916M3.2 6.923C3.2 5.628 4.072 5 4.638 5h11.423c.567 0 1.439.628 1.439 1.923v13.154c0 1.295-.872 1.923-1.439 1.923H4.638c-.566 0-1.438-.628-1.438-1.923z",clipRule:"evenodd"})]}),$$=U$,z$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("g",{clipPath:"url(#crop_svg__a)",children:g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7.13 1.009a1 1 0 1 0-2-.018l-.036 4.103-4.103.036a1 1 0 1 0 .018 2l4.068-.035L5 15.99V16a3 3 0 0 0 3 3h9v4a1 1 0 1 0 2 0v-4h4a1 1 0 1 0 0-2h-4V8a3 3 0 0 0-3-3l-8.905.077zm-.053 6.068L7 16.004A1 1 0 0 0 8 17h9V8a1 1 0 0 0-.996-1z",clipRule:"evenodd"})}),g.jsx("defs",{children:g.jsx("clipPath",{id:"crop_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),H$=z$,V$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M9.461 3.689a.96.96 0 0 1 .675-.28h3.819a.955.955 0 0 1 .954.955v.954H9.182v-.954c0-.254.1-.496.28-.675m7.357.675v.954h3.818a.955.955 0 0 1 0 1.91h-.954v12.408a2.864 2.864 0 0 1-2.864 2.864H7.273a2.864 2.864 0 0 1-2.864-2.864V7.227h-.954a.955.955 0 1 1 0-1.909h3.818v-.954A2.864 2.864 0 0 1 10.136 1.5h3.819a2.864 2.864 0 0 1 2.863 2.864m-10.5 2.863v12.41a.954.954 0 0 0 .955.954h9.545a.955.955 0 0 0 .955-.955V7.227zm3.818 2.864c.528 0 .955.427.955.955v5.727a.955.955 0 1 1-1.91 0v-5.727c0-.528.428-.955.955-.955m4.773 6.682v-5.727a.955.955 0 0 0-1.909 0v5.727a.955.955 0 1 0 1.91 0",clipRule:"evenodd"})]}),LN=V$,G$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsxs("g",{fill:"currentColor",fillRule:"evenodd",clipPath:"url(#download_svg__a)",clipRule:"evenodd",children:[g.jsx("path",{d:"M7.293 16.293a1 1 0 0 1 1.414 0L12 19.586l3.293-3.293a1 1 0 0 1 1.414 1.414l-4 4a1 1 0 0 1-1.414 0l-4-4a1 1 0 0 1 0-1.414"}),g.jsx("path",{d:"M12 11a1 1 0 0 1 1 1v9a1 1 0 1 1-2 0v-9a1 1 0 0 1 1-1"}),g.jsx("path",{d:"M8.668 1.994A9 9 0 0 1 17.48 8H18a6.002 6.002 0 0 1 5.689 7.919 6 6 0 0 1-2.234 2.989 1 1 0 1 1-1.15-1.636A4 4 0 0 0 18 10H16.74a1 1 0 0 1-.969-.751A7 7 0 1 0 3.75 15.627a1 1 0 1 1-1.498 1.326A9 9 0 0 1 8.668 1.994"})]}),g.jsx("defs",{children:g.jsx("clipPath",{id:"download_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),W$=G$,X$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M1.879 3.879A3 3 0 0 1 4 3h7a1 1 0 1 1 0 2H4a1 1 0 0 0-1 1v14a1 1 0 0 0 1 1h14a1 1 0 0 0 1-1v-7a1 1 0 1 1 2 0v7a3 3 0 0 1-3 3H4a3 3 0 0 1-3-3V6a3 3 0 0 1 .879-2.121",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M20 2.879c-.297 0-.583.118-.793.328l-9.304 9.304-.529 2.115 2.115-.529 9.304-9.304A1.121 1.121 0 0 0 20 2.879m-2.207-1.086a3.121 3.121 0 0 1 4.414 4.414l-9.5 9.5a1 1 0 0 1-.464.263l-4 1a1 1 0 0 1-1.213-1.212l1-4a1 1 0 0 1 .263-.465z",clipRule:"evenodd"})]}),q$=X$,Y$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M3 12a9 9 0 1 1 18 0 9 9 0 0 1-18 0m9-11C5.925 1 1 5.925 1 12s4.925 11 11 11 11-4.925 11-11S18.075 1 12 1M8.293 15.707a1 1 0 0 1 0-1.414L10.586 12 8.293 9.707a1 1 0 0 1 1.414-1.414L12 10.586l2.293-2.293a1 1 0 1 1 1.414 1.414L13.414 12l2.293 2.293a1 1 0 0 1-1.414 1.414L12 13.414l-2.293 2.293a1 1 0 0 1-1.414 0",clipRule:"evenodd"})]}),Q$=Y$,K$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M20.91 9.14v1.27H8.25a4.7 4.7 0 0 0-3.86 1.98L1.5 16.53V6.4a2.3 2.3 0 0 1 .77-1.69A2.68 2.68 0 0 1 4.11 4h3.73a2.68 2.68 0 0 1 1.84.71c.25.22.45.48.58.77s.2.6.2.92v.34h7.84c.7.01 1.35.27 1.84.71.49.45.76 1.06.77 1.7ZM8.25 11.92h14.47c.63 0 1 .68.64 1.18l-3.52 5.04a3.13 3.13 0 0 1-2.57 1.32H2.79c-.62 0-.99-.68-.64-1.18l3.53-5.04a3.13 3.13 0 0 1 2.57-1.32",clipRule:"evenodd"})]}),FN=K$,Z$=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M1.093 2.58A1 1 0 0 1 2 2h20a1 1 0 0 1 .764 1.646L15 12.826V21a1 1 0 0 1-1.447.894l-4-2A1 1 0 0 1 9 19v-6.174l-7.764-9.18a1 1 0 0 1-.143-1.067M4.155 4l6.609 7.814a1 1 0 0 1 .236.646v5.922l2 1V12.46a1 1 0 0 1 .236-.646L19.845 4z",clipRule:"evenodd"})]}),J$=Z$,ez=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M3.057 5.5A.057.057 0 0 0 3 5.557v13.03h18V7.875h-8.697a1 1 0 0 1-1-1c0-.759-.615-1.374-1.374-1.374zM1 5.557C1 4.42 1.92 3.5 3.057 3.5h6.872c1.515 0 2.797.999 3.223 2.374H21a2 2 0 0 1 2 2v10.714a2 2 0 0 1-2 2H3a2 2 0 0 1-2-2z",clipRule:"evenodd"})]}),jN=ez,tz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M9.726 3.29A9.01 9.01 0 0 0 3.055 11H7.05a16.3 16.3 0 0 1 2.676-7.71m4.548 0A16.3 16.3 0 0 1 16.95 11h3.995a9.01 9.01 0 0 0-6.67-7.71m.668 7.71A14.3 14.3 0 0 0 12 3.55 14.3 14.3 0 0 0 9.058 11zm-5.884 2h5.884A14.3 14.3 0 0 1 12 20.45 14.3 14.3 0 0 1 9.058 13M7.05 13H3.055a9.01 9.01 0 0 0 6.67 7.71A16.3 16.3 0 0 1 7.05 13m7.224 7.71A16.3 16.3 0 0 0 16.95 13h3.995a9.01 9.01 0 0 1-6.67 7.71M12 23c6.075 0 11-4.925 11-11S18.075 1 12 1 1 5.925 1 12s4.925 11 11 11",clipRule:"evenodd"})]}),LT=tz,rz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18M1 12C1 5.925 5.925 1 12 1s11 4.925 11 11-4.925 11-11 11S1 18.075 1 12",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12.01 17a1 1 0 0 1-1-1v-5a1 1 0 1 1 2 0v5a1 1 0 0 1-1 1M13.01 7.5a1 1 0 0 1-1 1H12a1 1 0 1 1 0-2h.01a1 1 0 0 1 1 1",clipRule:"evenodd"})]}),BN=rz,nz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4.222 5.037c-.895 0-1.222.555-1.222.792v12.675c0 .237.327.792 1.222.792h1.364l9.707-9.886a.987.987 0 0 1 1.414 0L21 13.782V5.829c0-.237-.328-.792-1.222-.792zM23 16.224V5.829C23 4.066 21.337 3 19.778 3H4.222C2.662 3 1 4.066 1 5.83v12.674c0 1.763 1.662 2.829 3.222 2.829h15.556c1.56 0 3.222-1.066 3.222-2.83v-2.279m-2 .439-5-5.093-7.585 7.726h11.363c.894 0 1.222-.555 1.222-.792zM8 8.093c-.552 0-1 .455-1 1.018a1.01 1.01 0 0 0 1 1.018c.552 0 1-.456 1-1.018a1.01 1.01 0 0 0-1-1.019M5 9.11c0-1.688 1.343-3.056 3-3.056s3 1.368 3 3.056-1.343 3.055-3 3.055-3-1.368-3-3.055",clipRule:"evenodd"})]}),iz=nz,sz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M16.672 5.558a7.96 7.96 0 0 0-9.841.397 7.95 7.95 0 0 0-1.908 9.66 7.964 7.964 0 0 0 8.949 4.12A7.95 7.95 0 0 0 19.962 12a1.021 1.021 0 1 1 2.045 0A9.994 9.994 0 0 1 7.83 21.083a10.01 10.01 0 0 1-5.634-11.027 9.99 9.99 0 0 1 9.402-8.048c2.244-.09 4.453.577 6.272 1.895a1.022 1.022 0 1 1-1.198 1.655",clipRule:"evenodd"})]}),UN=sz,oz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 .5a4.07 4.07 0 0 0-2.812 1.115A3.8 3.8 0 0 0 8 4.364V12a3.8 3.8 0 0 0 1.188 2.748A4.07 4.07 0 0 0 12 15.864a4.07 4.07 0 0 0 2.812-1.116A3.8 3.8 0 0 0 16 12V4.364a3.8 3.8 0 0 0-1.188-2.749A4.07 4.07 0 0 0 12 .5m-1.43 2.562A2.07 2.07 0 0 1 12 2.5c.545 0 1.059.207 1.43.562.371.354.57.823.57 1.302V12a1.8 1.8 0 0 1-.57 1.302 2.07 2.07 0 0 1-1.43.562 2.07 2.07 0 0 1-1.43-.562A1.8 1.8 0 0 1 10 12V4.364a1.8 1.8 0 0 1 .57-1.302M6 10.091a1 1 0 0 0-2 0V12c0 2.053.855 4.011 2.36 5.448A8.13 8.13 0 0 0 11 19.622V21.5H8a1 1 0 1 0 0 2h8a1 1 0 1 0 0-2h-3v-1.878a8.13 8.13 0 0 0 4.64-2.174C19.145 16.011 20 14.053 20 12v-1.91a1 1 0 0 0-2 0V12c0 1.491-.62 2.932-1.74 4.001s-2.646 1.678-4.248 1.68h-.024c-1.602-.002-3.128-.611-4.247-1.68C6.62 14.931 6 13.491 6 12z",clipRule:"evenodd"})]}),c1=oz,az=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("circle",{cx:12,cy:4,r:2.5,fill:"currentColor"}),g.jsx("circle",{cx:12,cy:12,r:2.5,fill:"currentColor"}),g.jsx("circle",{cx:12,cy:20,r:2.5,fill:"currentColor"})]}),lz=az,uz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M15.968 3c-.775 0-1.517.306-2.062.847l-8.983 8.918a4.8 4.8 0 0 0-1.423 3.41c0 1.277.511 2.504 1.423 3.41A4.9 4.9 0 0 0 8.368 21a4.9 4.9 0 0 0 3.445-1.416l8.983-8.918a1 1 0 1 1 1.409 1.42l-8.983 8.917A6.9 6.9 0 0 1 8.368 23a6.9 6.9 0 0 1-4.854-1.997A6.8 6.8 0 0 1 1.5 16.174c0-1.812.725-3.549 2.014-4.828l8.983-8.918A4.93 4.93 0 0 1 15.967 1c1.301 0 2.55.513 3.471 1.428a4.87 4.87 0 0 1 1.442 3.456 4.87 4.87 0 0 1-1.442 3.455l-8.992 8.918a2.965 2.965 0 0 1-4.175 0 2.935 2.935 0 0 1 0-4.165l8.299-8.23a1 1 0 0 1 1.408 1.42l-8.298 8.23a.935.935 0 0 0 0 1.326.963.963 0 0 0 1.357 0l8.992-8.918c.545-.541.85-1.274.85-2.036a2.87 2.87 0 0 0-.85-2.037A2.93 2.93 0 0 0 15.968 3",clipRule:"evenodd"})]}),cz=uz,dz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M5.5 2a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h3a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2zm0 2h3v16h-3zm10-2a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h3a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2zm0 2h3v16h-3z",clipRule:"evenodd"})]}),FT=dz,hz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",d:"M5 3.804c0-1.57 1.728-2.528 3.06-1.696l13.113 8.196a2 2 0 0 1 0 3.392L8.06 21.892C6.728 22.724 5 21.767 5 20.196z"})]}),$N=hz,fz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M13 4a1 1 0 1 0-2 0v7H4a1 1 0 1 0 0 2h7v7a1 1 0 1 0 2 0v-7h7a1 1 0 1 0 0-2h-7z",clipRule:"evenodd"})]}),d1=fz,pz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4.012 7.871a1.5 1.5 0 0 1 2.117.141L12 14.722l5.871-6.71a1.5 1.5 0 1 1 2.258 1.976l-7 8a1.5 1.5 0 0 1-2.258 0l-7-8a1.5 1.5 0 0 1 .141-2.117",clipRule:"evenodd"})]}),Tp=pz,mz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7.871 19.988a1.5 1.5 0 0 1 .141-2.117L14.722 12l-6.71-5.871A1.5 1.5 0 0 1 9.988 3.87l8 7a1.5 1.5 0 0 1 0 2.258l-8 7a1.5 1.5 0 0 1-2.117-.141",clipRule:"evenodd"})]}),zN=mz,gz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M19.988 17.129a1.5 1.5 0 0 1-2.117-.141L12 10.278l-5.871 6.71a1.5 1.5 0 0 1-2.258-1.976l7-8a1.5 1.5 0 0 1 2.258 0l7 8a1.5 1.5 0 0 1-.141 2.117",clipRule:"evenodd"})]}),vz=gz,yz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M23 12c0 6.075-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1s11 4.925 11 11M10 6H8a1 1 0 0 0-1 1v10a1 1 0 0 0 1 1h2a1 1 0 0 0 1-1V7a1 1 0 0 0-1-1m4 0h2a1 1 0 0 1 1 1v10a1 1 0 0 1-1 1h-2a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1",clipRule:"evenodd"})]}),xz=yz,bz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",d:"M2 6a4 4 0 0 1 4-4h12a4 4 0 0 1 4 4v12a4 4 0 0 1-4 4H6a4 4 0 0 1-4-4z"})]}),wz=bz,_z=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M2 4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h13a2 2 0 0 0 2-2v-1.936l4.409 1.365A2 2 0 0 0 24 15.519V8.48a2 2 0 0 0-2.591-1.91l-4.41 1.364V6a2 2 0 0 0-2-2zm0 2h13v12H2zm15 7.97V10.03l5-1.548v7.037z",clipRule:"evenodd"})]}),HN=_z,Sz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("circle",{cx:12,cy:12,r:11,fill:"currentColor"})]}),Zv=Sz,Ez=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("g",{clipPath:"url(#refresh_svg__a)",children:g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12.304 21c3.015 0 5.65-1.924 6.838-4.752a.986.986 0 0 1 1.297-.53c.503.216.738.803.524 1.311C19.498 20.522 16.19 23 12.304 23c-4.644 0-8.444-3.522-9.299-8.113L1.86 17.142a.99.99 0 0 1-1.33.449 1 1 0 0 1-.417-1.348L2.51 11.52c.135-.265.376-.457.66-.527a.96.96 0 0 1 .812.169L8.1 14.297c.433.33.515.958.185 1.404a.98.98 0 0 1-1.382.212L4.93 14.41c.65 3.785 3.744 6.59 7.374 6.59m4.794-12.913a.98.98 0 0 0-1.381.211 1.01 1.01 0 0 0 .184 1.405l4.117 3.135a.96.96 0 0 0 .812.169c.284-.07.525-.262.66-.527l2.398-4.723c.252-.496.065-1.1-.418-1.348a.99.99 0 0 0-1.329.449l-1.145 2.255C20.14 4.522 16.34 1 11.696 1 7.81 1 4.505 3.478 3.037 6.97a1.004 1.004 0 0 0 .525 1.312.986.986 0 0 0 1.297-.53C6.046 4.924 8.681 3 11.697 3c3.63 0 6.724 2.805 7.374 6.59z",clipRule:"evenodd"})}),g.jsx("defs",{children:g.jsx("clipPath",{id:"refresh_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),VN=Ez,Tz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4.583 7.313 3.976 3.87a.996.996 0 1 0-1.96.346l1.012 5.747a.996.996 0 0 0 1.153.809l5.743-1.014a.997.997 0 0 0-.346-1.962l-3.3.582a7.754 7.754 0 0 1 8.399-4.254 7.76 7.76 0 0 1 .78 15.064 7.745 7.745 0 0 1-8.912-3.56.995.995 0 1 0-1.724.997 9.744 9.744 0 0 0 11.201 4.474 9.74 9.74 0 0 0 5.19-3.718 9.756 9.756 0 0 0-.625-12.055A9.74 9.74 0 0 0 8.73 3.117a9.75 9.75 0 0 0-4.147 4.196",clipRule:"evenodd"})]}),GN=Tz,Cz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",d:"M17.919 3.15c1.33-.856 3.081.1 3.081 1.682v14.336c0 1.583-1.75 2.538-3.081 1.683L7 13.83V19a2 2 0 1 1-4 0V5a2 2 0 1 1 4 0v5.168z"})]}),Az=Cz,Rz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M5 4a1 1 0 0 0-1 1v14a1 1 0 0 0 1 1h1v-7a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v7h1a1 1 0 0 0 1-1V8.414L15.586 4H8v3h7a1 1 0 1 1 0 2H7a1 1 0 0 1-1-1V4zm2-2H5a3 3 0 0 0-3 3v14a3 3 0 0 0 3 3h14a3 3 0 0 0 3-3V8a1 1 0 0 0-.293-.707l-5-5A1 1 0 0 0 16 2zm1 12v6h8v-6z",clipRule:"evenodd"})]}),jT=Rz,Pz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 10a7 7 0 1 1 14 0 7 7 0 0 1-14 0m7-9a9 9 0 1 0 5.7 15.96 1 1 0 0 0 .24.4l4.35 4.35a1 1 0 0 0 1.42-1.42l-4.35-4.35a1 1 0 0 0-.4-.24A9 9 0 0 0 11 1",clipRule:"evenodd"})]}),AS=Pz,Iz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7 3a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h10a1 1 0 0 0 1-1V4a1 1 0 0 0-1-1zM4 4a3 3 0 0 1 3-3h10a3 3 0 0 1 3 3v16a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3z",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M11 18a1 1 0 0 1 1-1h.01a1 1 0 1 1 0 2H12a1 1 0 0 1-1-1",clipRule:"evenodd"})]}),Mz=Iz,kz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M16.133 6.173c-.026.023-.133.118-.133.541v.715h2v-.715c0-.423-.107-.518-.133-.541C17.805 6.12 17.594 6 17 6s-.805.12-.867.173M20 6.714c0-.76-.203-1.521-.832-2.06C18.575 4.145 17.786 4 17 4s-1.575.145-2.168.654c-.629.539-.832 1.3-.832 2.06V11a1 1 0 1 0 2 0V9.429h2V11a1 1 0 1 0 2 0zM14 14a1 1 0 0 1 1-1h4a1 1 0 0 1 .832 1.555L16.87 19H19a1 1 0 1 1 0 2h-4a1 1 0 0 1-.832-1.555L17.132 15H15a1 1 0 0 1-1-1M3.293 16.293a1 1 0 0 1 1.414 0L7 18.586l2.293-2.293a1 1 0 0 1 1.414 1.414l-3 3a1 1 0 0 1-1.414 0l-3-3a1 1 0 0 1 0-1.414",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7 4a1 1 0 0 1 1 1v15a1 1 0 1 1-2 0V5a1 1 0 0 1 1-1",clipRule:"evenodd"})]}),Oz=kz,Dz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M16.133 6.173c-.026.023-.133.118-.133.541v.715h2v-.715c0-.423-.107-.518-.133-.541C17.805 6.12 17.594 6 17 6s-.805.12-.867.173M20 6.714c0-.76-.203-1.521-.832-2.06C18.575 4.145 17.786 4 17 4s-1.575.145-2.168.654c-.629.539-.832 1.3-.832 2.06V11a1 1 0 1 0 2 0V9.429h2V11a1 1 0 1 0 2 0zM14 14a1 1 0 0 1 1-1h4a1 1 0 0 1 .832 1.555L16.87 19H19a1 1 0 1 1 0 2h-4a1 1 0 0 1-.832-1.555L17.132 15H15a1 1 0 0 1-1-1M3.293 8.707a1 1 0 0 0 1.414 0L7 6.414l2.293 2.293a1 1 0 0 0 1.414-1.414l-3-3a1 1 0 0 0-1.414 0l-3 3a1 1 0 0 0 0 1.414",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M7 21a1 1 0 0 0 1-1V5a1 1 0 0 0-2 0v15a1 1 0 0 0 1 1",clipRule:"evenodd"})]}),Nz=Dz,Lz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M13.509 6.027a6.138 6.138 0 1 1-.28 12.099 1 1 0 1 0-.383 1.963A8.138 8.138 0 1 0 9.653 5.488a1 1 0 1 0 1.168 1.624 6.1 6.1 0 0 1 2.688-1.085",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M14.38 8.252a1 1 0 0 0-1 1v3.8a1 1 0 0 0 .456.838l2.052 1.332a1 1 0 0 0 1.089-1.678l-1.597-1.036V9.252a1 1 0 0 0-1-1M1.793 16.293a1 1 0 0 1 1.414 0L5.5 18.586l2.293-2.293a1 1 0 0 1 1.414 1.414l-3 3a1 1 0 0 1-1.414 0l-3-3a1 1 0 0 1 0-1.414",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M5.5 4a1 1 0 0 0-1 1v15a1 1 0 1 0 2 0V5a1 1 0 0 0-1-1",clipRule:"evenodd"})]}),Fz=Lz,jz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 3a9 9 0 1 0 0 18 9 9 0 0 0 0-18M1 12C1 5.925 5.925 1 12 1s11 4.925 11 11-4.925 11-11 11S1 18.075 1 12",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M16.59 8.192a1 1 0 0 1 .218 1.397l-4.375 6a1 1 0 0 1-1.584.042L8.224 12.4a1 1 0 0 1 1.552-1.261l1.806 2.223 3.61-4.951a1 1 0 0 1 1.397-.219",clipRule:"evenodd"})]}),WN=jz,Bz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M6.286 3c-.35 0-.68.135-.92.368-.238.231-.366.54-.366.854v15.556c0 .315.128.623.367.854.239.233.569.368.919.368h11.428c.35 0 .68-.135.92-.368.238-.231.366-.54.366-.854V8h-3a2 2 0 0 1-2-2V3zM16 6h1.986L16 4.08zm5 13.778V6.556a1 1 0 0 0-.305-.72L15.98 1.281A1 1 0 0 0 15.286 1h-9a3.32 3.32 0 0 0-2.314.934A3.2 3.2 0 0 0 3 4.222v15.556c0 .864.353 1.686.972 2.288S5.423 23 6.286 23h11.428c.863 0 1.695-.333 2.314-.934.619-.602.972-1.424.972-2.288M8 6a1 1 0 0 0 0 2h3a1 1 0 1 0 0-2zm-1 6a1 1 0 0 1 1-1h8a1 1 0 1 1 0 2H8a1 1 0 0 1-1-1m5 4a1 1 0 1 0 0 2h4a1 1 0 1 0 0-2z",clipRule:"evenodd"})]}),Uz=Bz,$z=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M9.707 13.707a1 1 0 0 0 0-1.414L5.414 8l4.293-4.293a1 1 0 0 0-1.414-1.414l-5 5a1 1 0 0 0 0 1.414l5 5a1 1 0 0 0 1.414 0",clipRule:"evenodd"}),g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M20 20a1 1 0 0 0 1-1v-7a5 5 0 0 0-5-5H4a1 1 0 1 0 0 2h12a3 3 0 0 1 3 3v7a1 1 0 0 0 1 1",clipRule:"evenodd"})]}),zz=$z,Hz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("g",{fill:"currentColor",fillRule:"evenodd",clipPath:"url(#users_svg__a)",clipRule:"evenodd",children:g.jsx("path",{d:"M19.055 12.803a1 1 0 0 1 1.272-.618c1.128.39 2.061 1.247 2.7 2.351.64 1.106.972 2.435.973 3.782V21a1 1 0 1 1-2 0v-2.681c0-1.03-.258-2.009-.704-2.782-.448-.773-1.034-1.258-1.623-1.462a1 1 0 0 1-.618-1.272M15.187 1.384a1 1 0 0 1 1.036-.962 5.129 5.129 0 0 1 2.11 9.71 1 1 0 1 1-.896-1.788 3.129 3.129 0 0 0-1.288-5.924 1 1 0 0 1-.962-1.036M1.505 15.694C2.481 14.622 3.825 14 5.25 14h8.5c1.424 0 2.769.622 3.744 1.694.974 1.068 1.506 2.498 1.506 3.973V22a1 1 0 1 1-2 0v-2.333c0-1.001-.363-1.945-.984-2.627-.618-.679-1.436-1.04-2.266-1.04h-8.5c-.83 0-1.648.361-2.266 1.04-.621.682-.984 1.626-.984 2.627V22a1 1 0 1 1-2 0v-2.333c0-1.475.533-2.905 1.505-3.974M9.5 3a3.5 3.5 0 1 0 0 7 3.5 3.5 0 0 0 0-7M4 6.5a5.5 5.5 0 1 1 11 0 5.5 5.5 0 0 1-11 0"})}),g.jsx("defs",{children:g.jsx("clipPath",{id:"users_svg__a",children:g.jsx("path",{fill:"#fff",d:"M0 0h24v24H0z"})})})]}),BT=Hz,Vz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 4.962C4 4.376 4.435 4 4.853 4H6.5v2H4zM4 8h2.5v3H4zm-2 4V4.962C2 3.381 3.224 2 4.853 2h13.294C19.776 2 21 3.38 21 4.962v14.076C21 20.619 19.776 22 18.147 22H4.853C3.224 22 2 20.62 2 19.038zm17-6V4.962c0-.586-.435-.962-.853-.962H16.5v2zm0 2h-2.5v3H19zm-2.5 5H19v3h-2.5zm0 5H19v1.038c0 .586-.435.962-.853.962H16.5zm-2-7V4h-6v7zm-6 2h6v7h-6zm-2 5v2H4.853C4.435 20 4 19.624 4 19.038V18zm0-2v-3H4v3z",clipRule:"evenodd"})]}),Gz=Vz,Wz=({title:t,titleId:e,...r})=>g.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24","aria-hidden":"true","aria-labelledby":e,...r,children:[t?g.jsx("title",{id:e,children:t}):null,g.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M10 0a1 1 0 0 1 1 1 1 1 0 0 0 1 1 1 1 0 1 1 0 2 1 1 0 0 0-1 1 1 1 0 1 1-2 0 1 1 0 0 0-1-1 1 1 0 0 1 0-2 1 1 0 0 0 1-1 1 1 0 0 1 1-1m9.914 2a2 2 0 0 0-2.828 0L1 18.086a2 2 0 0 0 0 2.828L3.086 23a2 2 0 0 0 2.828 0L22 6.914a2 2 0 0 0 0-2.828zm-3.75 3.75L18.5 3.414 20.586 5.5 18.25 7.836zM14.75 7.164 2.414 19.5 4.5 21.586 16.836 9.25zM21 13a1 1 0 1 0-2 0 1 1 0 0 1-1 1 1 1 0 1 0 0 2 1 1 0 0 1 1 1 1 1 0 1 0 2 0 1 1 0 0 1 1-1 1 1 0 1 0 0-2 1 1 0 0 1-1-1",clipRule:"evenodd"})]}),Xz=Wz;function XN(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function Pu(t){return t instanceof Element||t instanceof XN(t).Element}function qz(t){return typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof XN(t).ShadowRoot}function Q0(t,e){if(!t||!e)return!1;const r=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(r&&qz(r)){let n=e;for(;n;){if(t===n)return!0;n=n.parentNode||n.host}}return!1}function qN(t,e){const r=["mouse","pen"];return r.push("",void 0),r.includes(t)}function $g(t){return(t==null?void 0:t.ownerDocument)||document}function Yz(t){return"composedPath"in t?t.composedPath()[0]:t.target}const Cp=Math.min,Li=Math.max,Jv=Math.round,zg=Math.floor,go=t=>({x:t,y:t}),Qz={left:"right",right:"left",bottom:"top",top:"bottom"},Kz={start:"end",end:"start"};function h1(t,e){return typeof t=="function"?t(e):t}function Zu(t){return t.split("-")[0]}function lm(t){return t.split("-")[1]}function Zz(t){return t==="x"?"y":"x"}function YN(t){return t==="y"?"height":"width"}function Kd(t){return["top","bottom"].includes(Zu(t))?"y":"x"}function QN(t){return Zz(Kd(t))}function Jz(t,e,r){r===void 0&&(r=!1);const n=lm(t),i=QN(t),s=YN(i);let o=i==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return e.reference[s]>e.floating[s]&&(o=ey(o)),[o,ey(o)]}function eH(t){const e=ey(t);return[RS(t),e,RS(e)]}function RS(t){return t.replace(/start|end/g,e=>Kz[e])}function tH(t,e,r){const n=["left","right"],i=["right","left"],s=["top","bottom"],o=["bottom","top"];switch(t){case"top":case"bottom":return r?e?i:n:e?n:i;case"left":case"right":return e?s:o;default:return[]}}function rH(t,e,r,n){const i=lm(t);let s=tH(Zu(t),r==="start",n);return i&&(s=s.map(o=>o+"-"+i),e&&(s=s.concat(s.map(RS)))),s}function ey(t){return t.replace(/left|right|bottom|top/g,e=>Qz[e])}function nH(t){return{top:0,right:0,bottom:0,left:0,...t}}function iH(t){return typeof t!="number"?nH(t):{top:t,right:t,bottom:t,left:t}}function ty(t){const{x:e,y:r,width:n,height:i}=t;return{width:n,height:i,top:r,left:e,right:e+n,bottom:r+i,x:e,y:r}}function UI(t,e,r){let{reference:n,floating:i}=t;const s=Kd(e),o=QN(e),a=YN(o),l=Zu(e),u=s==="y",c=n.x+n.width/2-i.width/2,h=n.y+n.height/2-i.height/2,f=n[a]/2-i[a]/2;let m;switch(l){case"top":m={x:c,y:n.y-i.height};break;case"bottom":m={x:c,y:n.y+n.height};break;case"right":m={x:n.x+n.width,y:h};break;case"left":m={x:n.x-i.width,y:h};break;default:m={x:n.x,y:n.y}}switch(lm(e)){case"start":m[o]-=f*(r&&u?-1:1);break;case"end":m[o]+=f*(r&&u?-1:1);break}return m}const sH=async(t,e,r)=>{const{placement:n="bottom",strategy:i="absolute",middleware:s=[],platform:o}=r,a=s.filter(Boolean),l=await(o.isRTL==null?void 0:o.isRTL(e));let u=await o.getElementRects({reference:t,floating:e,strategy:i}),{x:c,y:h}=UI(u,n,l),f=n,m={},y=0;for(let v=0;v<a.length;v++){const{name:x,fn:b}=a[v],{x:_,y:w,data:E,reset:A}=await b({x:c,y:h,initialPlacement:n,placement:f,strategy:i,middlewareData:m,rects:u,platform:o,elements:{reference:t,floating:e}});c=_??c,h=w??h,m={...m,[x]:{...m[x],...E}},A&&y<=50&&(y++,typeof A=="object"&&(A.placement&&(f=A.placement),A.rects&&(u=A.rects===!0?await o.getElementRects({reference:t,floating:e,strategy:i}):A.rects),{x:c,y:h}=UI(u,f,l)),v=-1)}return{x:c,y:h,placement:f,strategy:i,middlewareData:m}};async function KN(t,e){var r;e===void 0&&(e={});const{x:n,y:i,platform:s,rects:o,elements:a,strategy:l}=t,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:h="floating",altBoundary:f=!1,padding:m=0}=h1(e,t),y=iH(m),x=a[f?h==="floating"?"reference":"floating":h],b=ty(await s.getClippingRect({element:(r=await(s.isElement==null?void 0:s.isElement(x)))==null||r?x:x.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:u,rootBoundary:c,strategy:l})),_=h==="floating"?{x:n,y:i,width:o.floating.width,height:o.floating.height}:o.reference,w=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),E=await(s.isElement==null?void 0:s.isElement(w))?await(s.getScale==null?void 0:s.getScale(w))||{x:1,y:1}:{x:1,y:1},A=ty(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:_,offsetParent:w,strategy:l}):_);return{top:(b.top-A.top+y.top)/E.y,bottom:(A.bottom-b.bottom+y.bottom)/E.y,left:(b.left-A.left+y.left)/E.x,right:(A.right-b.right+y.right)/E.x}}const oH=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var r,n;const{placement:i,middlewareData:s,rects:o,initialPlacement:a,platform:l,elements:u}=e,{mainAxis:c=!0,crossAxis:h=!0,fallbackPlacements:f,fallbackStrategy:m="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:v=!0,...x}=h1(t,e);if((r=s.arrow)!=null&&r.alignmentOffset)return{};const b=Zu(i),_=Kd(a),w=Zu(a)===a,E=await(l.isRTL==null?void 0:l.isRTL(u.floating)),A=f||(w||!v?[ey(a)]:eH(a)),P=y!=="none";!f&&P&&A.push(...rH(a,v,y,E));const I=[a,...A],M=await KN(e,x),N=[];let z=((n=s.flip)==null?void 0:n.overflows)||[];if(c&&N.push(M[b]),h){const L=Jz(i,o,E);N.push(M[L[0]],M[L[1]])}if(z=[...z,{placement:i,overflows:N}],!N.every(L=>L<=0)){var j,H;const L=(((j=s.flip)==null?void 0:j.index)||0)+1,O=I[L];if(O)return{data:{index:L,overflows:z},reset:{placement:O}};let $=(H=z.filter(V=>V.overflows[0]<=0).sort((V,k)=>V.overflows[1]-k.overflows[1])[0])==null?void 0:H.placement;if(!$)switch(m){case"bestFit":{var F;const V=(F=z.filter(k=>{if(P){const U=Kd(k.placement);return U===_||U==="y"}return!0}).map(k=>[k.placement,k.overflows.filter(U=>U>0).reduce((U,B)=>U+B,0)]).sort((k,U)=>k[1]-U[1])[0])==null?void 0:F[0];V&&($=V);break}case"initialPlacement":$=a;break}if(i!==$)return{reset:{placement:$}}}return{}}}};async function aH(t,e){const{placement:r,platform:n,elements:i}=t,s=await(n.isRTL==null?void 0:n.isRTL(i.floating)),o=Zu(r),a=lm(r),l=Kd(r)==="y",u=["left","top"].includes(o)?-1:1,c=s&&l?-1:1,h=h1(e,t);let{mainAxis:f,crossAxis:m,alignmentAxis:y}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:h.mainAxis||0,crossAxis:h.crossAxis||0,alignmentAxis:h.alignmentAxis};return a&&typeof y=="number"&&(m=a==="end"?y*-1:y),l?{x:m*c,y:f*u}:{x:f*u,y:m*c}}const lH=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var r,n;const{x:i,y:s,placement:o,middlewareData:a}=e,l=await aH(e,t);return o===((r=a.offset)==null?void 0:r.placement)&&(n=a.arrow)!=null&&n.alignmentOffset?{}:{x:i+l.x,y:s+l.y,data:{...l,placement:o}}}}},uH=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var r,n;const{placement:i,rects:s,platform:o,elements:a}=e,{apply:l=()=>{},...u}=h1(t,e),c=await KN(e,u),h=Zu(i),f=lm(i),m=Kd(i)==="y",{width:y,height:v}=s.floating;let x,b;h==="top"||h==="bottom"?(x=h,b=f===(await(o.isRTL==null?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(b=h,x=f==="end"?"top":"bottom");const _=v-c.top-c.bottom,w=y-c.left-c.right,E=Cp(v-c[x],_),A=Cp(y-c[b],w),P=!e.middlewareData.shift;let I=E,M=A;if((r=e.middlewareData.shift)!=null&&r.enabled.x&&(M=w),(n=e.middlewareData.shift)!=null&&n.enabled.y&&(I=_),P&&!f){const z=Li(c.left,0),j=Li(c.right,0),H=Li(c.top,0),F=Li(c.bottom,0);m?M=y-2*(z!==0||j!==0?z+j:Li(c.left,c.right)):I=v-2*(H!==0||F!==0?H+F:Li(c.top,c.bottom))}await l({...e,availableWidth:M,availableHeight:I});const N=await o.getDimensions(a.floating);return y!==N.width||v!==N.height?{reset:{rects:!0}}:{}}}};function f1(){return typeof window<"u"}function hh(t){return ZN(t)?(t.nodeName||"").toLowerCase():"#document"}function fi(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function Io(t){var e;return(e=(ZN(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function ZN(t){return f1()?t instanceof Node||t instanceof fi(t).Node:!1}function As(t){return f1()?t instanceof Element||t instanceof fi(t).Element:!1}function bo(t){return f1()?t instanceof HTMLElement||t instanceof fi(t).HTMLElement:!1}function $I(t){return!f1()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof fi(t).ShadowRoot}function um(t){const{overflow:e,overflowX:r,overflowY:n,display:i}=Rs(t);return/auto|scroll|overlay|hidden|clip/.test(e+n+r)&&!["inline","contents"].includes(i)}function cH(t){return["table","td","th"].includes(hh(t))}function p1(t){return[":popover-open",":modal"].some(e=>{try{return t.matches(e)}catch{return!1}})}function UT(t){const e=$T(),r=As(t)?Rs(t):t;return r.transform!=="none"||r.perspective!=="none"||(r.containerType?r.containerType!=="normal":!1)||!e&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!e&&(r.filter?r.filter!=="none":!1)||["transform","perspective","filter"].some(n=>(r.willChange||"").includes(n))||["paint","layout","strict","content"].some(n=>(r.contain||"").includes(n))}function dH(t){let e=Pl(t);for(;bo(e)&&!Zd(e);){if(UT(e))return e;if(p1(e))return null;e=Pl(e)}return null}function $T(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Zd(t){return["html","body","#document"].includes(hh(t))}function Rs(t){return fi(t).getComputedStyle(t)}function m1(t){return As(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function Pl(t){if(hh(t)==="html")return t;const e=t.assignedSlot||t.parentNode||$I(t)&&t.host||Io(t);return $I(e)?e.host:e}function JN(t){const e=Pl(t);return Zd(e)?t.ownerDocument?t.ownerDocument.body:t.body:bo(e)&&um(e)?e:JN(e)}function Ap(t,e,r){var n;e===void 0&&(e=[]),r===void 0&&(r=!0);const i=JN(t),s=i===((n=t.ownerDocument)==null?void 0:n.body),o=fi(i);if(s){const a=PS(o);return e.concat(o,o.visualViewport||[],um(i)?i:[],a&&r?Ap(a):[])}return e.concat(i,Ap(i,[],r))}function PS(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function eL(t){const e=Rs(t);let r=parseFloat(e.width)||0,n=parseFloat(e.height)||0;const i=bo(t),s=i?t.offsetWidth:r,o=i?t.offsetHeight:n,a=Jv(r)!==s||Jv(n)!==o;return a&&(r=s,n=o),{width:r,height:n,$:a}}function zT(t){return As(t)?t:t.contextElement}function yd(t){const e=zT(t);if(!bo(e))return go(1);const r=e.getBoundingClientRect(),{width:n,height:i,$:s}=eL(e);let o=(s?Jv(r.width):r.width)/n,a=(s?Jv(r.height):r.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!a||!Number.isFinite(a))&&(a=1),{x:o,y:a}}const hH=go(0);function tL(t){const e=fi(t);return!$T()||!e.visualViewport?hH:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function fH(t,e,r){return e===void 0&&(e=!1),!r||e&&r!==fi(t)?!1:e}function Ju(t,e,r,n){e===void 0&&(e=!1),r===void 0&&(r=!1);const i=t.getBoundingClientRect(),s=zT(t);let o=go(1);e&&(n?As(n)&&(o=yd(n)):o=yd(t));const a=fH(s,r,n)?tL(s):go(0);let l=(i.left+a.x)/o.x,u=(i.top+a.y)/o.y,c=i.width/o.x,h=i.height/o.y;if(s){const f=fi(s),m=n&&As(n)?fi(n):n;let y=f,v=PS(y);for(;v&&n&&m!==y;){const x=yd(v),b=v.getBoundingClientRect(),_=Rs(v),w=b.left+(v.clientLeft+parseFloat(_.paddingLeft))*x.x,E=b.top+(v.clientTop+parseFloat(_.paddingTop))*x.y;l*=x.x,u*=x.y,c*=x.x,h*=x.y,l+=w,u+=E,y=fi(v),v=PS(y)}}return ty({width:c,height:h,x:l,y:u})}function HT(t,e){const r=m1(t).scrollLeft;return e?e.left+r:Ju(Io(t)).left+r}function rL(t,e,r){r===void 0&&(r=!1);const n=t.getBoundingClientRect(),i=n.left+e.scrollLeft-(r?0:HT(t,n)),s=n.top+e.scrollTop;return{x:i,y:s}}function pH(t){let{elements:e,rect:r,offsetParent:n,strategy:i}=t;const s=i==="fixed",o=Io(n),a=e?p1(e.floating):!1;if(n===o||a&&s)return r;let l={scrollLeft:0,scrollTop:0},u=go(1);const c=go(0),h=bo(n);if((h||!h&&!s)&&((hh(n)!=="body"||um(o))&&(l=m1(n)),bo(n))){const m=Ju(n);u=yd(n),c.x=m.x+n.clientLeft,c.y=m.y+n.clientTop}const f=o&&!h&&!s?rL(o,l,!0):go(0);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}}function mH(t){return Array.from(t.getClientRects())}function gH(t){const e=Io(t),r=m1(t),n=t.ownerDocument.body,i=Li(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),s=Li(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight);let o=-r.scrollLeft+HT(t);const a=-r.scrollTop;return Rs(n).direction==="rtl"&&(o+=Li(e.clientWidth,n.clientWidth)-i),{width:i,height:s,x:o,y:a}}function vH(t,e){const r=fi(t),n=Io(t),i=r.visualViewport;let s=n.clientWidth,o=n.clientHeight,a=0,l=0;if(i){s=i.width,o=i.height;const u=$T();(!u||u&&e==="fixed")&&(a=i.offsetLeft,l=i.offsetTop)}return{width:s,height:o,x:a,y:l}}function yH(t,e){const r=Ju(t,!0,e==="fixed"),n=r.top+t.clientTop,i=r.left+t.clientLeft,s=bo(t)?yd(t):go(1),o=t.clientWidth*s.x,a=t.clientHeight*s.y,l=i*s.x,u=n*s.y;return{width:o,height:a,x:l,y:u}}function zI(t,e,r){let n;if(e==="viewport")n=vH(t,r);else if(e==="document")n=gH(Io(t));else if(As(e))n=yH(e,r);else{const i=tL(t);n={x:e.x-i.x,y:e.y-i.y,width:e.width,height:e.height}}return ty(n)}function nL(t,e){const r=Pl(t);return r===e||!As(r)||Zd(r)?!1:Rs(r).position==="fixed"||nL(r,e)}function xH(t,e){const r=e.get(t);if(r)return r;let n=Ap(t,[],!1).filter(a=>As(a)&&hh(a)!=="body"),i=null;const s=Rs(t).position==="fixed";let o=s?Pl(t):t;for(;As(o)&&!Zd(o);){const a=Rs(o),l=UT(o);!l&&a.position==="fixed"&&(i=null),(s?!l&&!i:!l&&a.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||um(o)&&!l&&nL(t,o))?n=n.filter(c=>c!==o):i=a,o=Pl(o)}return e.set(t,n),n}function bH(t){let{element:e,boundary:r,rootBoundary:n,strategy:i}=t;const o=[...r==="clippingAncestors"?p1(e)?[]:xH(e,this._c):[].concat(r),n],a=o[0],l=o.reduce((u,c)=>{const h=zI(e,c,i);return u.top=Li(h.top,u.top),u.right=Cp(h.right,u.right),u.bottom=Cp(h.bottom,u.bottom),u.left=Li(h.left,u.left),u},zI(e,a,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function wH(t){const{width:e,height:r}=eL(t);return{width:e,height:r}}function _H(t,e,r){const n=bo(e),i=Io(e),s=r==="fixed",o=Ju(t,!0,s,e);let a={scrollLeft:0,scrollTop:0};const l=go(0);if(n||!n&&!s)if((hh(e)!=="body"||um(i))&&(a=m1(e)),n){const f=Ju(e,!0,s,e);l.x=f.x+e.clientLeft,l.y=f.y+e.clientTop}else i&&(l.x=HT(i));const u=i&&!n&&!s?rL(i,a):go(0),c=o.left+a.scrollLeft-l.x-u.x,h=o.top+a.scrollTop-l.y-u.y;return{x:c,y:h,width:o.width,height:o.height}}function tw(t){return Rs(t).position==="static"}function HI(t,e){if(!bo(t)||Rs(t).position==="fixed")return null;if(e)return e(t);let r=t.offsetParent;return Io(t)===r&&(r=r.ownerDocument.body),r}function iL(t,e){const r=fi(t);if(p1(t))return r;if(!bo(t)){let i=Pl(t);for(;i&&!Zd(i);){if(As(i)&&!tw(i))return i;i=Pl(i)}return r}let n=HI(t,e);for(;n&&cH(n)&&tw(n);)n=HI(n,e);return n&&Zd(n)&&tw(n)&&!UT(n)?r:n||dH(t)||r}const SH=async function(t){const e=this.getOffsetParent||iL,r=this.getDimensions,n=await r(t.floating);return{reference:_H(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function EH(t){return Rs(t).direction==="rtl"}const TH={convertOffsetParentRelativeRectToViewportRelativeRect:pH,getDocumentElement:Io,getClippingRect:bH,getOffsetParent:iL,getElementRects:SH,getClientRects:mH,getDimensions:wH,getScale:yd,isElement:As,isRTL:EH};function CH(t,e){let r=null,n;const i=Io(t);function s(){var a;clearTimeout(n),(a=r)==null||a.disconnect(),r=null}function o(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),s();const{left:u,top:c,width:h,height:f}=t.getBoundingClientRect();if(a||e(),!h||!f)return;const m=zg(c),y=zg(i.clientWidth-(u+h)),v=zg(i.clientHeight-(c+f)),x=zg(u),_={rootMargin:-m+"px "+-y+"px "+-v+"px "+-x+"px",threshold:Li(0,Cp(1,l))||1};let w=!0;function E(A){const P=A[0].intersectionRatio;if(P!==l){if(!w)return o();P?o(!1,P):n=setTimeout(()=>{o(!1,1e-7)},1e3)}w=!1}try{r=new IntersectionObserver(E,{..._,root:i.ownerDocument})}catch{r=new IntersectionObserver(E,_)}r.observe(t)}return o(!0),s}function AH(t,e,r,n){n===void 0&&(n={});const{ancestorScroll:i=!0,ancestorResize:s=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,u=zT(t),c=i||s?[...u?Ap(u):[],...Ap(e)]:[];c.forEach(b=>{i&&b.addEventListener("scroll",r,{passive:!0}),s&&b.addEventListener("resize",r)});const h=u&&a?CH(u,r):null;let f=-1,m=null;o&&(m=new ResizeObserver(b=>{let[_]=b;_&&_.target===u&&m&&(m.unobserve(e),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var w;(w=m)==null||w.observe(e)})),r()}),u&&!l&&m.observe(u),m.observe(e));let y,v=l?Ju(t):null;l&&x();function x(){const b=Ju(t);v&&(b.x!==v.x||b.y!==v.y||b.width!==v.width||b.height!==v.height)&&r(),v=b,y=requestAnimationFrame(x)}return r(),()=>{var b;c.forEach(_=>{i&&_.removeEventListener("scroll",r),s&&_.removeEventListener("resize",r)}),h==null||h(),(b=m)==null||b.disconnect(),m=null,l&&cancelAnimationFrame(y)}}const RH=lH,PH=oH,IH=uH,MH=(t,e,r)=>{const n=new Map,i={platform:TH,...r},s={...i.platform,_c:n};return sH(t,e,{...i,platform:s})};var K0=typeof document<"u"?T.useLayoutEffect:T.useEffect;function ry(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if(typeof t=="function"&&t.toString()===e.toString())return!0;let r,n,i;if(t&&e&&typeof t=="object"){if(Array.isArray(t)){if(r=t.length,r!==e.length)return!1;for(n=r;n--!==0;)if(!ry(t[n],e[n]))return!1;return!0}if(i=Object.keys(t),r=i.length,r!==Object.keys(e).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(e,i[n]))return!1;for(n=r;n--!==0;){const s=i[n];if(!(s==="_owner"&&t.$$typeof)&&!ry(t[s],e[s]))return!1}return!0}return t!==t&&e!==e}function sL(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function VI(t,e){const r=sL(t);return Math.round(e*r)/r}function rw(t){const e=T.useRef(t);return K0(()=>{e.current=t}),e}function kH(t){t===void 0&&(t={});const{placement:e="bottom",strategy:r="absolute",middleware:n=[],platform:i,elements:{reference:s,floating:o}={},transform:a=!0,whileElementsMounted:l,open:u}=t,[c,h]=T.useState({x:0,y:0,strategy:r,placement:e,middlewareData:{},isPositioned:!1}),[f,m]=T.useState(n);ry(f,n)||m(n);const[y,v]=T.useState(null),[x,b]=T.useState(null),_=T.useCallback(k=>{k!==P.current&&(P.current=k,v(k))},[]),w=T.useCallback(k=>{k!==I.current&&(I.current=k,b(k))},[]),E=s||y,A=o||x,P=T.useRef(null),I=T.useRef(null),M=T.useRef(c),N=l!=null,z=rw(l),j=rw(i),H=rw(u),F=T.useCallback(()=>{if(!P.current||!I.current)return;const k={placement:e,strategy:r,middleware:f};j.current&&(k.platform=j.current),MH(P.current,I.current,k).then(U=>{const B={...U,isPositioned:H.current!==!1};L.current&&!ry(M.current,B)&&(M.current=B,mr.flushSync(()=>{h(B)}))})},[f,e,r,j,H]);K0(()=>{u===!1&&M.current.isPositioned&&(M.current.isPositioned=!1,h(k=>({...k,isPositioned:!1})))},[u]);const L=T.useRef(!1);K0(()=>(L.current=!0,()=>{L.current=!1}),[]),K0(()=>{if(E&&(P.current=E),A&&(I.current=A),E&&A){if(z.current)return z.current(E,A,F);F()}},[E,A,F,z,N]);const O=T.useMemo(()=>({reference:P,floating:I,setReference:_,setFloating:w}),[_,w]),$=T.useMemo(()=>({reference:E,floating:A}),[E,A]),V=T.useMemo(()=>{const k={position:r,left:0,top:0};if(!$.floating)return k;const U=VI($.floating,c.x),B=VI($.floating,c.y);return a?{...k,transform:"translate("+U+"px, "+B+"px)",...sL($.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:U,top:B}},[r,a,$.floating,c.x,c.y]);return T.useMemo(()=>({...c,update:F,refs:O,elements:$,floatingStyles:V}),[c,F,O,$,V])}const OH=(t,e)=>({...RH(t),options:[t,e]}),DH=(t,e)=>({...PH(t),options:[t,e]}),NH=(t,e)=>({...IH(t),options:[t,e]});var Rp=typeof document<"u"?T.useLayoutEffect:T.useEffect;let nw=!1,LH=0;const GI=()=>"floating-ui-"+LH++;function FH(){const[t,e]=T.useState(()=>nw?GI():void 0);return Rp(()=>{t==null&&e(GI())},[]),T.useEffect(()=>{nw||(nw=!0)},[]),t}const jH=sO.useId,BH=jH||FH;function UH(){const t=new Map;return{emit(e,r){var n;(n=t.get(e))==null||n.forEach(i=>i(r))},on(e,r){t.set(e,[...t.get(e)||[],r])},off(e,r){var n;t.set(e,((n=t.get(e))==null?void 0:n.filter(i=>i!==r))||[])}}}const $H=T.createContext(null),zH=T.createContext(null),HH=()=>{var t;return((t=T.useContext($H))==null?void 0:t.id)||null},oL=()=>T.useContext(zH);function VH(t){return"data-floating-ui-"+t}function WI(t){const e=T.useRef(t);return Rp(()=>{e.current=t}),e}const XI=VH("safe-polygon");function iw(t,e,r){return r&&!qN(r)?0:typeof t=="number"?t:t==null?void 0:t[e]}function GH(t,e){e===void 0&&(e={});const{open:r,onOpenChange:n,dataRef:i,events:s,elements:{domReference:o,floating:a},refs:l}=t,{enabled:u=!0,delay:c=0,handleClose:h=null,mouseOnly:f=!1,restMs:m=0,move:y=!0}=e,v=oL(),x=HH(),b=WI(h),_=WI(c),w=T.useRef(),E=T.useRef(),A=T.useRef(),P=T.useRef(),I=T.useRef(!0),M=T.useRef(!1),N=T.useRef(()=>{}),z=T.useCallback(()=>{var L;const O=(L=i.current.openEvent)==null?void 0:L.type;return(O==null?void 0:O.includes("mouse"))&&O!=="mousedown"},[i]);T.useEffect(()=>{if(!u)return;function L(){clearTimeout(E.current),clearTimeout(P.current),I.current=!0}return s.on("dismiss",L),()=>{s.off("dismiss",L)}},[u,s]),T.useEffect(()=>{if(!u||!b.current||!r)return;function L($){z()&&n(!1,$)}const O=$g(a).documentElement;return O.addEventListener("mouseleave",L),()=>{O.removeEventListener("mouseleave",L)}},[a,r,n,u,b,i,z]);const j=T.useCallback(function(L,O){O===void 0&&(O=!0);const $=iw(_.current,"close",w.current);$&&!A.current?(clearTimeout(E.current),E.current=setTimeout(()=>n(!1,L),$)):O&&(clearTimeout(E.current),n(!1,L))},[_,n]),H=T.useCallback(()=>{N.current(),A.current=void 0},[]),F=T.useCallback(()=>{if(M.current){const L=$g(l.floating.current).body;L.style.pointerEvents="",L.removeAttribute(XI),M.current=!1}},[l]);return T.useEffect(()=>{if(!u)return;function L(){return i.current.openEvent?["click","mousedown"].includes(i.current.openEvent.type):!1}function O(k){if(clearTimeout(E.current),I.current=!1,f&&!qN(w.current)||m>0&&iw(_.current,"open")===0)return;const U=iw(_.current,"open",w.current);U?E.current=setTimeout(()=>{n(!0,k)},U):n(!0,k)}function $(k){if(L())return;N.current();const U=$g(a);if(clearTimeout(P.current),b.current){r||clearTimeout(E.current),A.current=b.current({...t,tree:v,x:k.clientX,y:k.clientY,onClose(){F(),H(),j(k)}});const X=A.current;U.addEventListener("mousemove",X),N.current=()=>{U.removeEventListener("mousemove",X)};return}(w.current==="touch"?!Q0(a,k.relatedTarget):!0)&&j(k)}function V(k){L()||b.current==null||b.current({...t,tree:v,x:k.clientX,y:k.clientY,onClose(){F(),H(),j(k)}})(k)}if(Pu(o)){const k=o;return r&&k.addEventListener("mouseleave",V),a==null||a.addEventListener("mouseleave",V),y&&k.addEventListener("mousemove",O,{once:!0}),k.addEventListener("mouseenter",O),k.addEventListener("mouseleave",$),()=>{r&&k.removeEventListener("mouseleave",V),a==null||a.removeEventListener("mouseleave",V),y&&k.removeEventListener("mousemove",O),k.removeEventListener("mouseenter",O),k.removeEventListener("mouseleave",$)}}},[o,a,u,t,f,m,y,j,H,F,n,r,v,_,b,i]),Rp(()=>{var L;if(u&&r&&(L=b.current)!=null&&L.__options.blockPointerEvents&&z()){const V=$g(a).body;if(V.setAttribute(XI,""),V.style.pointerEvents="none",M.current=!0,Pu(o)&&a){var O,$;const k=o,U=v==null||(O=v.nodesRef.current.find(B=>B.id===x))==null||($=O.context)==null?void 0:$.elements.floating;return U&&(U.style.pointerEvents=""),k.style.pointerEvents="auto",a.style.pointerEvents="auto",()=>{k.style.pointerEvents="",a.style.pointerEvents=""}}}},[u,r,x,a,o,v,b,i,z]),Rp(()=>{r||(w.current=void 0,H(),F())},[r,H,F]),T.useEffect(()=>()=>{H(),clearTimeout(E.current),clearTimeout(P.current),F()},[u,o,H,F]),T.useMemo(()=>{if(!u)return{};function L(O){w.current=O.pointerType}return{reference:{onPointerDown:L,onPointerEnter:L,onMouseMove(O){r||m===0||(clearTimeout(P.current),P.current=setTimeout(()=>{I.current||n(!0,O.nativeEvent)},m))}},floating:{onMouseEnter(){clearTimeout(E.current)},onMouseLeave(O){s.emit("dismiss",{type:"mouseLeave",data:{returnFocus:!1}}),j(O.nativeEvent,!1)}}}},[s,u,m,r,n,j])}function WH(t,e){let r=t.filter(i=>{var s;return i.parentId===e&&((s=i.context)==null?void 0:s.open)}),n=r;for(;n.length;)n=t.filter(i=>{var s;return(s=n)==null?void 0:s.some(o=>{var a;return i.parentId===o.id&&((a=i.context)==null?void 0:a.open)})}),r=r.concat(n);return r}const XH=sO.useInsertionEffect,qH=XH||(t=>t());function YH(t){const e=T.useRef(()=>{});return qH(()=>{e.current=t}),T.useCallback(function(){for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];return e.current==null?void 0:e.current(...n)},[])}function QH(t){var e;t===void 0&&(t={});const{open:r=!1,onOpenChange:n,nodeId:i}=t,[s,o]=T.useState(null),a=((e=t.elements)==null?void 0:e.reference)||s,l=kH(t),u=oL(),c=YH((E,A)=>{E&&(f.current.openEvent=A),n==null||n(E,A)}),h=T.useRef(null),f=T.useRef({}),m=T.useState(()=>UH())[0],y=BH(),v=T.useCallback(E=>{const A=Pu(E)?{getBoundingClientRect:()=>E.getBoundingClientRect(),contextElement:E}:E;l.refs.setReference(A)},[l.refs]),x=T.useCallback(E=>{(Pu(E)||E===null)&&(h.current=E,o(E)),(Pu(l.refs.reference.current)||l.refs.reference.current===null||E!==null&&!Pu(E))&&l.refs.setReference(E)},[l.refs]),b=T.useMemo(()=>({...l.refs,setReference:x,setPositionReference:v,domReference:h}),[l.refs,x,v]),_=T.useMemo(()=>({...l.elements,domReference:a}),[l.elements,a]),w=T.useMemo(()=>({...l,refs:b,elements:_,dataRef:f,nodeId:i,floatingId:y,events:m,open:r,onOpenChange:c}),[l,i,y,m,r,c,b,_]);return Rp(()=>{const E=u==null?void 0:u.nodesRef.current.find(A=>A.id===i);E&&(E.context=w)}),T.useMemo(()=>({...l,context:w,refs:b,elements:_}),[l,b,_,w])}function qI(t,e){const[r,n]=t;let i=!1;const s=e.length;for(let o=0,a=s-1;o<s;a=o++){const[l,u]=e[o]||[0,0],[c,h]=e[a]||[0,0];u>=n!=h>=n&&r<=(c-l)*(n-u)/(h-u)+l&&(i=!i)}return i}function KH(t,e){return t[0]>=e.x&&t[0]<=e.x+e.width&&t[1]>=e.y&&t[1]<=e.y+e.height}function ZH(t){t===void 0&&(t={});const{buffer:e=.5,blockPointerEvents:r=!1,requireIntent:n=!0}=t;let i,s=!1,o=null,a=null,l=performance.now();function u(h,f){const m=performance.now(),y=m-l;if(o===null||a===null||y===0)return o=h,a=f,l=m,null;const v=h-o,x=f-a,_=Math.sqrt(v*v+x*x)/y;return o=h,a=f,l=m,_}const c=h=>{let{x:f,y:m,placement:y,elements:v,onClose:x,nodeId:b,tree:_}=h;return function(E){function A(){clearTimeout(i),x()}if(clearTimeout(i),!v.domReference||!v.floating||y==null||f==null||m==null)return;const{clientX:P,clientY:I}=E,M=[P,I],N=Yz(E),z=E.type==="mouseleave",j=Q0(v.floating,N),H=Q0(v.domReference,N),F=v.domReference.getBoundingClientRect(),L=v.floating.getBoundingClientRect(),O=y.split("-")[0],$=f>L.right-L.width/2,V=m>L.bottom-L.height/2,k=KH(M,F),U=L.width>F.width,B=L.height>F.height,X=(U?F:L).left,K=(U?F:L).right,q=(B?F:L).top,re=(B?F:L).bottom;if(j&&(s=!0,!z))return;if(H&&(s=!1),H&&!z){s=!0;return}if(z&&Pu(E.relatedTarget)&&Q0(v.floating,E.relatedTarget)||_&&WH(_.nodesRef.current,b).some(me=>{let{context:xe}=me;return xe==null?void 0:xe.open}))return;if(O==="top"&&m>=F.bottom-1||O==="bottom"&&m<=F.top+1||O==="left"&&f>=F.right-1||O==="right"&&f<=F.left+1)return A();let ue=[];switch(O){case"top":ue=[[X,F.top+1],[X,L.bottom-1],[K,L.bottom-1],[K,F.top+1]];break;case"bottom":ue=[[X,L.top+1],[X,F.bottom-1],[K,F.bottom-1],[K,L.top+1]];break;case"left":ue=[[L.right-1,re],[L.right-1,q],[F.left+1,q],[F.left+1,re]];break;case"right":ue=[[F.right-1,re],[F.right-1,q],[L.left+1,q],[L.left+1,re]];break}function le(me){let[xe,_e]=me;switch(O){case"top":{const Te=[U?xe+e/2:$?xe+e*4:xe-e*4,_e+e+1],de=[U?xe-e/2:$?xe+e*4:xe-e*4,_e+e+1],Be=[[L.left,$||U?L.bottom-e:L.top],[L.right,$?U?L.bottom-e:L.top:L.bottom-e]];return[Te,de,...Be]}case"bottom":{const Te=[U?xe+e/2:$?xe+e*4:xe-e*4,_e-e],de=[U?xe-e/2:$?xe+e*4:xe-e*4,_e-e],Be=[[L.left,$||U?L.top+e:L.bottom],[L.right,$?U?L.top+e:L.bottom:L.top+e]];return[Te,de,...Be]}case"left":{const Te=[xe+e+1,B?_e+e/2:V?_e+e*4:_e-e*4],de=[xe+e+1,B?_e-e/2:V?_e+e*4:_e-e*4];return[...[[V||B?L.right-e:L.left,L.top],[V?B?L.right-e:L.left:L.right-e,L.bottom]],Te,de]}case"right":{const Te=[xe-e,B?_e+e/2:V?_e+e*4:_e-e*4],de=[xe-e,B?_e-e/2:V?_e+e*4:_e-e*4],Be=[[V||B?L.left+e:L.right,L.top],[V?B?L.left+e:L.right:L.left+e,L.bottom]];return[Te,de,...Be]}}}if(!qI([P,I],ue)){if(s&&!k)return A();if(!z&&n){const me=u(E.clientX,E.clientY);if(me!==null&&me<.1)return A()}qI([P,I],le([f,m]))?!s&&n&&(i=window.setTimeout(A,40)):A()}}};return c.__options={blockPointerEvents:r},c}var aL={exports:{}};(function(t,e){(function(r,n){t.exports=n()})(rr,function(){var r=1e3,n=6e4,i=36e5,s="millisecond",o="second",a="minute",l="hour",u="day",c="week",h="month",f="quarter",m="year",y="date",v="Invalid Date",x=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,b=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,_={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(L){var O=["th","st","nd","rd"],$=L%100;return"["+L+(O[($-20)%10]||O[$]||O[0])+"]"}},w=function(L,O,$){var V=String(L);return!V||V.length>=O?L:""+Array(O+1-V.length).join($)+L},E={s:w,z:function(L){var O=-L.utcOffset(),$=Math.abs(O),V=Math.floor($/60),k=$%60;return(O<=0?"+":"-")+w(V,2,"0")+":"+w(k,2,"0")},m:function L(O,$){if(O.date()<$.date())return-L($,O);var V=12*($.year()-O.year())+($.month()-O.month()),k=O.clone().add(V,h),U=$-k<0,B=O.clone().add(V+(U?-1:1),h);return+(-(V+($-k)/(U?k-B:B-k))||0)},a:function(L){return L<0?Math.ceil(L)||0:Math.floor(L)},p:function(L){return{M:h,y:m,w:c,d:u,D:y,h:l,m:a,s:o,ms:s,Q:f}[L]||String(L||"").toLowerCase().replace(/s$/,"")},u:function(L){return L===void 0}},A="en",P={};P[A]=_;var I="$isDayjsObject",M=function(L){return L instanceof H||!(!L||!L[I])},N=function L(O,$,V){var k;if(!O)return A;if(typeof O=="string"){var U=O.toLowerCase();P[U]&&(k=U),$&&(P[U]=$,k=U);var B=O.split("-");if(!k&&B.length>1)return L(B[0])}else{var X=O.name;P[X]=O,k=X}return!V&&k&&(A=k),k||!V&&A},z=function(L,O){if(M(L))return L.clone();var $=typeof O=="object"?O:{};return $.date=L,$.args=arguments,new H($)},j=E;j.l=N,j.i=M,j.w=function(L,O){return z(L,{locale:O.$L,utc:O.$u,x:O.$x,$offset:O.$offset})};var H=function(){function L($){this.$L=N($.locale,null,!0),this.parse($),this.$x=this.$x||$.x||{},this[I]=!0}var O=L.prototype;return O.parse=function($){this.$d=function(V){var k=V.date,U=V.utc;if(k===null)return new Date(NaN);if(j.u(k))return new Date;if(k instanceof Date)return new Date(k);if(typeof k=="string"&&!/Z$/i.test(k)){var B=k.match(x);if(B){var X=B[2]-1||0,K=(B[7]||"0").substring(0,3);return U?new Date(Date.UTC(B[1],X,B[3]||1,B[4]||0,B[5]||0,B[6]||0,K)):new Date(B[1],X,B[3]||1,B[4]||0,B[5]||0,B[6]||0,K)}}return new Date(k)}($),this.init()},O.init=function(){var $=this.$d;this.$y=$.getFullYear(),this.$M=$.getMonth(),this.$D=$.getDate(),this.$W=$.getDay(),this.$H=$.getHours(),this.$m=$.getMinutes(),this.$s=$.getSeconds(),this.$ms=$.getMilliseconds()},O.$utils=function(){return j},O.isValid=function(){return this.$d.toString()!==v},O.isSame=function($,V){var k=z($);return this.startOf(V)<=k&&k<=this.endOf(V)},O.isAfter=function($,V){return z($)<this.startOf(V)},O.isBefore=function($,V){return this.endOf(V)<z($)},O.$g=function($,V,k){return j.u($)?this[V]:this.set(k,$)},O.unix=function(){return Math.floor(this.valueOf()/1e3)},O.valueOf=function(){return this.$d.getTime()},O.startOf=function($,V){var k=this,U=!!j.u(V)||V,B=j.p($),X=function(_e,Te){var de=j.w(k.$u?Date.UTC(k.$y,Te,_e):new Date(k.$y,Te,_e),k);return U?de:de.endOf(u)},K=function(_e,Te){return j.w(k.toDate()[_e].apply(k.toDate("s"),(U?[0,0,0,0]:[23,59,59,999]).slice(Te)),k)},q=this.$W,re=this.$M,ue=this.$D,le="set"+(this.$u?"UTC":"");switch(B){case m:return U?X(1,0):X(31,11);case h:return U?X(1,re):X(0,re+1);case c:var me=this.$locale().weekStart||0,xe=(q<me?q+7:q)-me;return X(U?ue-xe:ue+(6-xe),re);case u:case y:return K(le+"Hours",0);case l:return K(le+"Minutes",1);case a:return K(le+"Seconds",2);case o:return K(le+"Milliseconds",3);default:return this.clone()}},O.endOf=function($){return this.startOf($,!1)},O.$set=function($,V){var k,U=j.p($),B="set"+(this.$u?"UTC":""),X=(k={},k[u]=B+"Date",k[y]=B+"Date",k[h]=B+"Month",k[m]=B+"FullYear",k[l]=B+"Hours",k[a]=B+"Minutes",k[o]=B+"Seconds",k[s]=B+"Milliseconds",k)[U],K=U===u?this.$D+(V-this.$W):V;if(U===h||U===m){var q=this.clone().set(y,1);q.$d[X](K),q.init(),this.$d=q.set(y,Math.min(this.$D,q.daysInMonth())).$d}else X&&this.$d[X](K);return this.init(),this},O.set=function($,V){return this.clone().$set($,V)},O.get=function($){return this[j.p($)]()},O.add=function($,V){var k,U=this;$=Number($);var B=j.p(V),X=function(re){var ue=z(U);return j.w(ue.date(ue.date()+Math.round(re*$)),U)};if(B===h)return this.set(h,this.$M+$);if(B===m)return this.set(m,this.$y+$);if(B===u)return X(1);if(B===c)return X(7);var K=(k={},k[a]=n,k[l]=i,k[o]=r,k)[B]||1,q=this.$d.getTime()+$*K;return j.w(q,this)},O.subtract=function($,V){return this.add(-1*$,V)},O.format=function($){var V=this,k=this.$locale();if(!this.isValid())return k.invalidDate||v;var U=$||"YYYY-MM-DDTHH:mm:ssZ",B=j.z(this),X=this.$H,K=this.$m,q=this.$M,re=k.weekdays,ue=k.months,le=k.meridiem,me=function(Te,de,Be,je){return Te&&(Te[de]||Te(V,U))||Be[de].slice(0,je)},xe=function(Te){return j.s(X%12||12,Te,"0")},_e=le||function(Te,de,Be){var je=Te<12?"AM":"PM";return Be?je.toLowerCase():je};return U.replace(b,function(Te,de){return de||function(Be){switch(Be){case"YY":return String(V.$y).slice(-2);case"YYYY":return j.s(V.$y,4,"0");case"M":return q+1;case"MM":return j.s(q+1,2,"0");case"MMM":return me(k.monthsShort,q,ue,3);case"MMMM":return me(ue,q);case"D":return V.$D;case"DD":return j.s(V.$D,2,"0");case"d":return String(V.$W);case"dd":return me(k.weekdaysMin,V.$W,re,2);case"ddd":return me(k.weekdaysShort,V.$W,re,3);case"dddd":return re[V.$W];case"H":return String(X);case"HH":return j.s(X,2,"0");case"h":return xe(1);case"hh":return xe(2);case"a":return _e(X,K,!0);case"A":return _e(X,K,!1);case"m":return String(K);case"mm":return j.s(K,2,"0");case"s":return String(V.$s);case"ss":return j.s(V.$s,2,"0");case"SSS":return j.s(V.$ms,3,"0");case"Z":return B}return null}(Te)||B.replace(":","")})},O.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},O.diff=function($,V,k){var U,B=this,X=j.p(V),K=z($),q=(K.utcOffset()-this.utcOffset())*n,re=this-K,ue=function(){return j.m(B,K)};switch(X){case m:U=ue()/12;break;case h:U=ue();break;case f:U=ue()/3;break;case c:U=(re-q)/6048e5;break;case u:U=(re-q)/864e5;break;case l:U=re/i;break;case a:U=re/n;break;case o:U=re/r;break;default:U=re}return k?U:j.a(U)},O.daysInMonth=function(){return this.endOf(h).$D},O.$locale=function(){return P[this.$L]},O.locale=function($,V){if(!$)return this.$L;var k=this.clone(),U=N($,V,!0);return U&&(k.$L=U),k},O.clone=function(){return j.w(this.$d,this)},O.toDate=function(){return new Date(this.valueOf())},O.toJSON=function(){return this.isValid()?this.toISOString():null},O.toISOString=function(){return this.$d.toISOString()},O.toString=function(){return this.$d.toUTCString()},L}(),F=H.prototype;return z.prototype=F,[["$ms",s],["$s",o],["$m",a],["$H",l],["$W",u],["$M",h],["$y",m],["$D",y]].forEach(function(L){F[L[1]]=function(O){return this.$g(O,L[0],L[1])}}),z.extend=function(L,O){return L.$i||(L(O,H,z),L.$i=!0),z},z.locale=N,z.isDayjs=M,z.unix=function(L){return z(1e3*L)},z.en=P[A],z.Ls=P,z.p={},z})})(aL);var JH=aL.exports;const Lr=Po(JH);var fh=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},ec=typeof window>"u"||"Deno"in globalThis;function Ii(){}function eV(t,e){return typeof t=="function"?t(e):t}function IS(t){return typeof t=="number"&&t>=0&&t!==1/0}function lL(t,e){return Math.max(t+(e||0)-Date.now(),0)}function xd(t,e){return typeof t=="function"?t(e):t}function ps(t,e){return typeof t=="function"?t(e):t}function YI(t,e){const{type:r="all",exact:n,fetchStatus:i,predicate:s,queryKey:o,stale:a}=t;if(o){if(n){if(e.queryHash!==VT(o,e.options))return!1}else if(!Pp(e.queryKey,o))return!1}if(r!=="all"){const l=e.isActive();if(r==="active"&&!l||r==="inactive"&&l)return!1}return!(typeof a=="boolean"&&e.isStale()!==a||i&&i!==e.state.fetchStatus||s&&!s(e))}function QI(t,e){const{exact:r,status:n,predicate:i,mutationKey:s}=t;if(s){if(!e.options.mutationKey)return!1;if(r){if(tc(e.options.mutationKey)!==tc(s))return!1}else if(!Pp(e.options.mutationKey,s))return!1}return!(n&&e.state.status!==n||i&&!i(e))}function VT(t,e){return((e==null?void 0:e.queryKeyHashFn)||tc)(t)}function tc(t){return JSON.stringify(t,(e,r)=>MS(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function Pp(t,e){return t===e?!0:typeof t!=typeof e?!1:t&&e&&typeof t=="object"&&typeof e=="object"?!Object.keys(e).some(r=>!Pp(t[r],e[r])):!1}function uL(t,e){if(t===e)return t;const r=KI(t)&&KI(e);if(r||MS(t)&&MS(e)){const n=r?t:Object.keys(t),i=n.length,s=r?e:Object.keys(e),o=s.length,a=r?[]:{};let l=0;for(let u=0;u<o;u++){const c=r?u:s[u];(!r&&n.includes(c)||r)&&t[c]===void 0&&e[c]===void 0?(a[c]=void 0,l++):(a[c]=uL(t[c],e[c]),a[c]===t[c]&&t[c]!==void 0&&l++)}return i===o&&l===i?t:a}return e}function ny(t,e){if(!e||Object.keys(t).length!==Object.keys(e).length)return!1;for(const r in t)if(t[r]!==e[r])return!1;return!0}function KI(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function MS(t){if(!ZI(t))return!1;const e=t.constructor;if(e===void 0)return!0;const r=e.prototype;return!(!ZI(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(t)!==Object.prototype)}function ZI(t){return Object.prototype.toString.call(t)==="[object Object]"}function tV(t){return new Promise(e=>{setTimeout(e,t)})}function kS(t,e,r){return typeof r.structuralSharing=="function"?r.structuralSharing(t,e):r.structuralSharing!==!1?uL(t,e):e}function rV(t,e,r=0){const n=[...t,e];return r&&n.length>r?n.slice(1):n}function nV(t,e,r=0){const n=[e,...t];return r&&n.length>r?n.slice(0,-1):n}var GT=Symbol();function cL(t,e){return!t.queryFn&&(e!=null&&e.initialPromise)?()=>e.initialPromise:!t.queryFn||t.queryFn===GT?()=>Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`)):t.queryFn}var Mu,Ka,Md,Dk,iV=(Dk=class extends fh{constructor(){super();Ze(this,Mu);Ze(this,Ka);Ze(this,Md);Ne(this,Md,e=>{if(!ec&&window.addEventListener){const r=()=>e();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){Y(this,Ka)||this.setEventListener(Y(this,Md))}onUnsubscribe(){var e;this.hasListeners()||((e=Y(this,Ka))==null||e.call(this),Ne(this,Ka,void 0))}setEventListener(e){var r;Ne(this,Md,e),(r=Y(this,Ka))==null||r.call(this),Ne(this,Ka,e(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(e){Y(this,Mu)!==e&&(Ne(this,Mu,e),this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach(r=>{r(e)})}isFocused(){var e;return typeof Y(this,Mu)=="boolean"?Y(this,Mu):((e=globalThis.document)==null?void 0:e.visibilityState)!=="hidden"}},Mu=new WeakMap,Ka=new WeakMap,Md=new WeakMap,Dk),WT=new iV,kd,Za,Od,Nk,sV=(Nk=class extends fh{constructor(){super();Ze(this,kd,!0);Ze(this,Za);Ze(this,Od);Ne(this,Od,e=>{if(!ec&&window.addEventListener){const r=()=>e(!0),n=()=>e(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",n)}}})}onSubscribe(){Y(this,Za)||this.setEventListener(Y(this,Od))}onUnsubscribe(){var e;this.hasListeners()||((e=Y(this,Za))==null||e.call(this),Ne(this,Za,void 0))}setEventListener(e){var r;Ne(this,Od,e),(r=Y(this,Za))==null||r.call(this),Ne(this,Za,e(this.setOnline.bind(this)))}setOnline(e){Y(this,kd)!==e&&(Ne(this,kd,e),this.listeners.forEach(n=>{n(e)}))}isOnline(){return Y(this,kd)}},kd=new WeakMap,Za=new WeakMap,Od=new WeakMap,Nk),iy=new sV;function OS(){let t,e;const r=new Promise((i,s)=>{t=i,e=s});r.status="pending",r.catch(()=>{});function n(i){Object.assign(r,i),delete r.resolve,delete r.reject}return r.resolve=i=>{n({status:"fulfilled",value:i}),t(i)},r.reject=i=>{n({status:"rejected",reason:i}),e(i)},r}function oV(t){return Math.min(1e3*2**t,3e4)}function dL(t){return(t??"online")==="online"?iy.isOnline():!0}var hL=class extends Error{constructor(t){super("CancelledError"),this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent}};function sw(t){return t instanceof hL}function fL(t){let e=!1,r=0,n=!1,i;const s=OS(),o=v=>{var x;n||(f(new hL(v)),(x=t.abort)==null||x.call(t))},a=()=>{e=!0},l=()=>{e=!1},u=()=>WT.isFocused()&&(t.networkMode==="always"||iy.isOnline())&&t.canRun(),c=()=>dL(t.networkMode)&&t.canRun(),h=v=>{var x;n||(n=!0,(x=t.onSuccess)==null||x.call(t,v),i==null||i(),s.resolve(v))},f=v=>{var x;n||(n=!0,(x=t.onError)==null||x.call(t,v),i==null||i(),s.reject(v))},m=()=>new Promise(v=>{var x;i=b=>{(n||u())&&v(b)},(x=t.onPause)==null||x.call(t)}).then(()=>{var v;i=void 0,n||(v=t.onContinue)==null||v.call(t)}),y=()=>{if(n)return;let v;const x=r===0?t.initialPromise:void 0;try{v=x??t.fn()}catch(b){v=Promise.reject(b)}Promise.resolve(v).then(h).catch(b=>{var P;if(n)return;const _=t.retry??(ec?0:3),w=t.retryDelay??oV,E=typeof w=="function"?w(r,b):w,A=_===!0||typeof _=="number"&&r<_||typeof _=="function"&&_(r,b);if(e||!A){f(b);return}r++,(P=t.onFail)==null||P.call(t,r,b),tV(E).then(()=>u()?void 0:m()).then(()=>{e?f(b):y()})})};return{promise:s,cancel:o,continue:()=>(i==null||i(),s),cancelRetry:a,continueRetry:l,canStart:c,start:()=>(c()?y():m().then(y),s)}}function aV(){let t=[],e=0,r=a=>{a()},n=a=>{a()},i=a=>setTimeout(a,0);const s=a=>{e?t.push(a):i(()=>{r(a)})},o=()=>{const a=t;t=[],a.length&&i(()=>{n(()=>{a.forEach(l=>{r(l)})})})};return{batch:a=>{let l;e++;try{l=a()}finally{e--,e||o()}return l},batchCalls:a=>(...l)=>{s(()=>{a(...l)})},schedule:s,setNotifyFunction:a=>{r=a},setBatchNotifyFunction:a=>{n=a},setScheduler:a=>{i=a}}}var Tr=aV(),ku,Lk,pL=(Lk=class{constructor(){Ze(this,ku)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),IS(this.gcTime)&&Ne(this,ku,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(t){this.gcTime=Math.max(this.gcTime||0,t??(ec?1/0:5*60*1e3))}clearGcTimeout(){Y(this,ku)&&(clearTimeout(Y(this,ku)),Ne(this,ku,void 0))}},ku=new WeakMap,Lk),Dd,Nd,Pi,cn,Zp,Ou,ds,zo,Fk,lV=(Fk=class extends pL{constructor(e){super();Ze(this,ds);Ze(this,Dd);Ze(this,Nd);Ze(this,Pi);Ze(this,cn);Ze(this,Zp);Ze(this,Ou);Ne(this,Ou,!1),Ne(this,Zp,e.defaultOptions),this.setOptions(e.options),this.observers=[],Ne(this,Pi,e.cache),this.queryKey=e.queryKey,this.queryHash=e.queryHash,Ne(this,Dd,uV(this.options)),this.state=e.state??Y(this,Dd),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var e;return(e=Y(this,cn))==null?void 0:e.promise}setOptions(e){this.options={...Y(this,Zp),...e},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&Y(this,Pi).remove(this)}setData(e,r){const n=kS(this.state.data,e,this.options);return lt(this,ds,zo).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(e,r){lt(this,ds,zo).call(this,{type:"setState",state:e,setStateOptions:r})}cancel(e){var n,i;const r=(n=Y(this,cn))==null?void 0:n.promise;return(i=Y(this,cn))==null||i.cancel(e),r?r.then(Ii).catch(Ii):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(Y(this,Dd))}isActive(){return this.observers.some(e=>ps(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===GT||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return this.state.isInvalidated?!0:this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0}isStaleByTime(e=0){return this.state.isInvalidated||this.state.data===void 0||!lL(this.state.dataUpdatedAt,e)}onFocus(){var r;const e=this.observers.find(n=>n.shouldFetchOnWindowFocus());e==null||e.refetch({cancelRefetch:!1}),(r=Y(this,cn))==null||r.continue()}onOnline(){var r;const e=this.observers.find(n=>n.shouldFetchOnReconnect());e==null||e.refetch({cancelRefetch:!1}),(r=Y(this,cn))==null||r.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),Y(this,Pi).notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(r=>r!==e),this.observers.length||(Y(this,cn)&&(Y(this,Ou)?Y(this,cn).cancel({revert:!0}):Y(this,cn).cancelRetry()),this.scheduleGc()),Y(this,Pi).notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||lt(this,ds,zo).call(this,{type:"invalidate"})}fetch(e,r){var l,u,c;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(Y(this,cn))return Y(this,cn).continueRetry(),Y(this,cn).promise}if(e&&this.setOptions(e),!this.options.queryFn){const h=this.observers.find(f=>f.options.queryFn);h&&this.setOptions(h.options)}const n=new AbortController,i=h=>{Object.defineProperty(h,"signal",{enumerable:!0,get:()=>(Ne(this,Ou,!0),n.signal)})},s=()=>{const h=cL(this.options,r),f={queryKey:this.queryKey,meta:this.meta};return i(f),Ne(this,Ou,!1),this.options.persister?this.options.persister(h,f,this):h(f)},o={fetchOptions:r,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:s};i(o),(l=this.options.behavior)==null||l.onFetch(o,this),Ne(this,Nd,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=o.fetchOptions)==null?void 0:u.meta))&<(this,ds,zo).call(this,{type:"fetch",meta:(c=o.fetchOptions)==null?void 0:c.meta});const a=h=>{var f,m,y,v;sw(h)&&h.silent||lt(this,ds,zo).call(this,{type:"error",error:h}),sw(h)||((m=(f=Y(this,Pi).config).onError)==null||m.call(f,h,this),(v=(y=Y(this,Pi).config).onSettled)==null||v.call(y,this.state.data,h,this)),this.scheduleGc()};return Ne(this,cn,fL({initialPromise:r==null?void 0:r.initialPromise,fn:o.fetchFn,abort:n.abort.bind(n),onSuccess:h=>{var f,m,y,v;if(h===void 0){a(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(h)}catch(x){a(x);return}(m=(f=Y(this,Pi).config).onSuccess)==null||m.call(f,h,this),(v=(y=Y(this,Pi).config).onSettled)==null||v.call(y,h,this.state.error,this),this.scheduleGc()},onError:a,onFail:(h,f)=>{lt(this,ds,zo).call(this,{type:"failed",failureCount:h,error:f})},onPause:()=>{lt(this,ds,zo).call(this,{type:"pause"})},onContinue:()=>{lt(this,ds,zo).call(this,{type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0})),Y(this,cn).start()}},Dd=new WeakMap,Nd=new WeakMap,Pi=new WeakMap,cn=new WeakMap,Zp=new WeakMap,Ou=new WeakMap,ds=new WeakSet,zo=function(e){const r=n=>{switch(e.type){case"failed":return{...n,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...mL(n.data,this.options),fetchMeta:e.meta??null};case"success":return{...n,data:e.data,dataUpdateCount:n.dataUpdateCount+1,dataUpdatedAt:e.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const i=e.error;return sw(i)&&i.revert&&Y(this,Nd)?{...Y(this,Nd),fetchStatus:"idle"}:{...n,error:i,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...e.state}}};this.state=r(this.state),Tr.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),Y(this,Pi).notify({query:this,type:"updated",action:e})})},Fk);function mL(t,e){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:dL(e.networkMode)?"fetching":"paused",...t===void 0&&{error:null,status:"pending"}}}function uV(t){const e=typeof t.initialData=="function"?t.initialData():t.initialData,r=e!==void 0,n=r?typeof t.initialDataUpdatedAt=="function"?t.initialDataUpdatedAt():t.initialDataUpdatedAt:0;return{data:e,dataUpdateCount:0,dataUpdatedAt:r?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var Js,jk,gL=(jk=class extends fh{constructor(e={}){super();Ze(this,Js);this.config=e,Ne(this,Js,new Map)}build(e,r,n){const i=r.queryKey,s=r.queryHash??VT(i,r);let o=this.get(s);return o||(o=new lV({cache:this,queryKey:i,queryHash:s,options:e.defaultQueryOptions(r),state:n,defaultOptions:e.getQueryDefaults(i)}),this.add(o)),o}add(e){Y(this,Js).has(e.queryHash)||(Y(this,Js).set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const r=Y(this,Js).get(e.queryHash);r&&(e.destroy(),r===e&&Y(this,Js).delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){Tr.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return Y(this,Js).get(e)}getAll(){return[...Y(this,Js).values()]}find(e){const r={exact:!0,...e};return this.getAll().find(n=>YI(r,n))}findAll(e={}){const r=this.getAll();return Object.keys(e).length>0?r.filter(n=>YI(e,n)):r}notify(e){Tr.batch(()=>{this.listeners.forEach(r=>{r(e)})})}onFocus(){Tr.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){Tr.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},Js=new WeakMap,jk),eo,yn,Du,to,Ba,Bk,cV=(Bk=class extends pL{constructor(e){super();Ze(this,to);Ze(this,eo);Ze(this,yn);Ze(this,Du);this.mutationId=e.mutationId,Ne(this,yn,e.mutationCache),Ne(this,eo,[]),this.state=e.state||vL(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){Y(this,eo).includes(e)||(Y(this,eo).push(e),this.clearGcTimeout(),Y(this,yn).notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){Ne(this,eo,Y(this,eo).filter(r=>r!==e)),this.scheduleGc(),Y(this,yn).notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){Y(this,eo).length||(this.state.status==="pending"?this.scheduleGc():Y(this,yn).remove(this))}continue(){var e;return((e=Y(this,Du))==null?void 0:e.continue())??this.execute(this.state.variables)}async execute(e){var i,s,o,a,l,u,c,h,f,m,y,v,x,b,_,w,E,A,P,I;Ne(this,Du,fL({fn:()=>this.options.mutationFn?this.options.mutationFn(e):Promise.reject(new Error("No mutationFn found")),onFail:(M,N)=>{lt(this,to,Ba).call(this,{type:"failed",failureCount:M,error:N})},onPause:()=>{lt(this,to,Ba).call(this,{type:"pause"})},onContinue:()=>{lt(this,to,Ba).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>Y(this,yn).canRun(this)}));const r=this.state.status==="pending",n=!Y(this,Du).canStart();try{if(!r){lt(this,to,Ba).call(this,{type:"pending",variables:e,isPaused:n}),await((s=(i=Y(this,yn).config).onMutate)==null?void 0:s.call(i,e,this));const N=await((a=(o=this.options).onMutate)==null?void 0:a.call(o,e));N!==this.state.context&<(this,to,Ba).call(this,{type:"pending",context:N,variables:e,isPaused:n})}const M=await Y(this,Du).start();return await((u=(l=Y(this,yn).config).onSuccess)==null?void 0:u.call(l,M,e,this.state.context,this)),await((h=(c=this.options).onSuccess)==null?void 0:h.call(c,M,e,this.state.context)),await((m=(f=Y(this,yn).config).onSettled)==null?void 0:m.call(f,M,null,this.state.variables,this.state.context,this)),await((v=(y=this.options).onSettled)==null?void 0:v.call(y,M,null,e,this.state.context)),lt(this,to,Ba).call(this,{type:"success",data:M}),M}catch(M){try{throw await((b=(x=Y(this,yn).config).onError)==null?void 0:b.call(x,M,e,this.state.context,this)),await((w=(_=this.options).onError)==null?void 0:w.call(_,M,e,this.state.context)),await((A=(E=Y(this,yn).config).onSettled)==null?void 0:A.call(E,void 0,M,this.state.variables,this.state.context,this)),await((I=(P=this.options).onSettled)==null?void 0:I.call(P,void 0,M,e,this.state.context)),M}finally{lt(this,to,Ba).call(this,{type:"error",error:M})}}finally{Y(this,yn).runNext(this)}}},eo=new WeakMap,yn=new WeakMap,Du=new WeakMap,to=new WeakSet,Ba=function(e){const r=n=>{switch(e.type){case"failed":return{...n,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...n,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:e.error,failureCount:n.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Tr.batch(()=>{Y(this,eo).forEach(n=>{n.onMutationUpdate(e)}),Y(this,yn).notify({mutation:this,type:"updated",action:e})})},Bk);function vL(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var ai,Jp,Uk,dV=(Uk=class extends fh{constructor(e={}){super();Ze(this,ai);Ze(this,Jp);this.config=e,Ne(this,ai,new Map),Ne(this,Jp,Date.now())}build(e,r,n){const i=new cV({mutationCache:this,mutationId:++wg(this,Jp)._,options:e.defaultMutationOptions(r),state:n});return this.add(i),i}add(e){const r=Hg(e),n=Y(this,ai).get(r)??[];n.push(e),Y(this,ai).set(r,n),this.notify({type:"added",mutation:e})}remove(e){var n;const r=Hg(e);if(Y(this,ai).has(r)){const i=(n=Y(this,ai).get(r))==null?void 0:n.filter(s=>s!==e);i&&(i.length===0?Y(this,ai).delete(r):Y(this,ai).set(r,i))}this.notify({type:"removed",mutation:e})}canRun(e){var n;const r=(n=Y(this,ai).get(Hg(e)))==null?void 0:n.find(i=>i.state.status==="pending");return!r||r===e}runNext(e){var n;const r=(n=Y(this,ai).get(Hg(e)))==null?void 0:n.find(i=>i!==e&&i.state.isPaused);return(r==null?void 0:r.continue())??Promise.resolve()}clear(){Tr.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}getAll(){return[...Y(this,ai).values()].flat()}find(e){const r={exact:!0,...e};return this.getAll().find(n=>QI(r,n))}findAll(e={}){return this.getAll().filter(r=>QI(e,r))}notify(e){Tr.batch(()=>{this.listeners.forEach(r=>{r(e)})})}resumePausedMutations(){const e=this.getAll().filter(r=>r.state.isPaused);return Tr.batch(()=>Promise.all(e.map(r=>r.continue().catch(Ii))))}},ai=new WeakMap,Jp=new WeakMap,Uk);function Hg(t){var e;return((e=t.options.scope)==null?void 0:e.id)??String(t.mutationId)}function sy(t){return{onFetch:(e,r)=>{var c,h,f,m,y;const n=e.options,i=(f=(h=(c=e.fetchOptions)==null?void 0:c.meta)==null?void 0:h.fetchMore)==null?void 0:f.direction,s=((m=e.state.data)==null?void 0:m.pages)||[],o=((y=e.state.data)==null?void 0:y.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const u=async()=>{let v=!1;const x=w=>{Object.defineProperty(w,"signal",{enumerable:!0,get:()=>(e.signal.aborted?v=!0:e.signal.addEventListener("abort",()=>{v=!0}),e.signal)})},b=cL(e.options,e.fetchOptions),_=async(w,E,A)=>{if(v)return Promise.reject();if(E==null&&w.pages.length)return Promise.resolve(w);const P={queryKey:e.queryKey,pageParam:E,direction:A?"backward":"forward",meta:e.options.meta};x(P);const I=await b(P),{maxPages:M}=e.options,N=A?nV:rV;return{pages:N(w.pages,I,M),pageParams:N(w.pageParams,E,M)}};if(i&&s.length){const w=i==="backward",E=w?yL:DS,A={pages:s,pageParams:o},P=E(n,A);a=await _(A,P,w)}else{const w=t??s.length;do{const E=l===0?o[0]??n.initialPageParam:DS(n,a);if(l>0&&E==null)break;a=await _(a,E),l++}while(l<w)}return a};e.options.persister?e.fetchFn=()=>{var v,x;return(x=(v=e.options).persister)==null?void 0:x.call(v,u,{queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},r)}:e.fetchFn=u}}}function DS(t,{pages:e,pageParams:r}){const n=e.length-1;return e.length>0?t.getNextPageParam(e[n],e,r[n],r):void 0}function yL(t,{pages:e,pageParams:r}){var n;return e.length>0?(n=t.getPreviousPageParam)==null?void 0:n.call(t,e[0],e,r[0],r):void 0}function hV(t,e){return e?DS(t,e)!=null:!1}function fV(t,e){return!e||!t.getPreviousPageParam?!1:yL(t,e)!=null}var Zt,Ja,el,Ld,Fd,tl,jd,Bd,$k,pV=($k=class{constructor(t={}){Ze(this,Zt);Ze(this,Ja);Ze(this,el);Ze(this,Ld);Ze(this,Fd);Ze(this,tl);Ze(this,jd);Ze(this,Bd);Ne(this,Zt,t.queryCache||new gL),Ne(this,Ja,t.mutationCache||new dV),Ne(this,el,t.defaultOptions||{}),Ne(this,Ld,new Map),Ne(this,Fd,new Map),Ne(this,tl,0)}mount(){wg(this,tl)._++,Y(this,tl)===1&&(Ne(this,jd,WT.subscribe(async t=>{t&&(await this.resumePausedMutations(),Y(this,Zt).onFocus())})),Ne(this,Bd,iy.subscribe(async t=>{t&&(await this.resumePausedMutations(),Y(this,Zt).onOnline())})))}unmount(){var t,e;wg(this,tl)._--,Y(this,tl)===0&&((t=Y(this,jd))==null||t.call(this),Ne(this,jd,void 0),(e=Y(this,Bd))==null||e.call(this),Ne(this,Bd,void 0))}isFetching(t){return Y(this,Zt).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return Y(this,Ja).findAll({...t,status:"pending"}).length}getQueryData(t){var r;const e=this.defaultQueryOptions({queryKey:t});return(r=Y(this,Zt).get(e.queryHash))==null?void 0:r.state.data}ensureQueryData(t){const e=this.getQueryData(t.queryKey);if(e===void 0)return this.fetchQuery(t);{const r=this.defaultQueryOptions(t),n=Y(this,Zt).build(this,r);return t.revalidateIfStale&&n.isStaleByTime(xd(r.staleTime,n))&&this.prefetchQuery(r),Promise.resolve(e)}}getQueriesData(t){return Y(this,Zt).findAll(t).map(({queryKey:e,state:r})=>{const n=r.data;return[e,n]})}setQueryData(t,e,r){const n=this.defaultQueryOptions({queryKey:t}),i=Y(this,Zt).get(n.queryHash),s=i==null?void 0:i.state.data,o=eV(e,s);if(o!==void 0)return Y(this,Zt).build(this,n).setData(o,{...r,manual:!0})}setQueriesData(t,e,r){return Tr.batch(()=>Y(this,Zt).findAll(t).map(({queryKey:n})=>[n,this.setQueryData(n,e,r)]))}getQueryState(t){var r;const e=this.defaultQueryOptions({queryKey:t});return(r=Y(this,Zt).get(e.queryHash))==null?void 0:r.state}removeQueries(t){const e=Y(this,Zt);Tr.batch(()=>{e.findAll(t).forEach(r=>{e.remove(r)})})}resetQueries(t,e){const r=Y(this,Zt),n={type:"active",...t};return Tr.batch(()=>(r.findAll(t).forEach(i=>{i.reset()}),this.refetchQueries(n,e)))}cancelQueries(t={},e={}){const r={revert:!0,...e},n=Tr.batch(()=>Y(this,Zt).findAll(t).map(i=>i.cancel(r)));return Promise.all(n).then(Ii).catch(Ii)}invalidateQueries(t={},e={}){return Tr.batch(()=>{if(Y(this,Zt).findAll(t).forEach(n=>{n.invalidate()}),t.refetchType==="none")return Promise.resolve();const r={...t,type:t.refetchType??t.type??"active"};return this.refetchQueries(r,e)})}refetchQueries(t={},e){const r={...e,cancelRefetch:(e==null?void 0:e.cancelRefetch)??!0},n=Tr.batch(()=>Y(this,Zt).findAll(t).filter(i=>!i.isDisabled()).map(i=>{let s=i.fetch(void 0,r);return r.throwOnError||(s=s.catch(Ii)),i.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(n).then(Ii)}fetchQuery(t){const e=this.defaultQueryOptions(t);e.retry===void 0&&(e.retry=!1);const r=Y(this,Zt).build(this,e);return r.isStaleByTime(xd(e.staleTime,r))?r.fetch(e):Promise.resolve(r.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(Ii).catch(Ii)}fetchInfiniteQuery(t){return t.behavior=sy(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(Ii).catch(Ii)}ensureInfiniteQueryData(t){return t.behavior=sy(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return iy.isOnline()?Y(this,Ja).resumePausedMutations():Promise.resolve()}getQueryCache(){return Y(this,Zt)}getMutationCache(){return Y(this,Ja)}getDefaultOptions(){return Y(this,el)}setDefaultOptions(t){Ne(this,el,t)}setQueryDefaults(t,e){Y(this,Ld).set(tc(t),{queryKey:t,defaultOptions:e})}getQueryDefaults(t){const e=[...Y(this,Ld).values()];let r={};return e.forEach(n=>{Pp(t,n.queryKey)&&(r={...r,...n.defaultOptions})}),r}setMutationDefaults(t,e){Y(this,Fd).set(tc(t),{mutationKey:t,defaultOptions:e})}getMutationDefaults(t){const e=[...Y(this,Fd).values()];let r={};return e.forEach(n=>{Pp(t,n.mutationKey)&&(r={...r,...n.defaultOptions})}),r}defaultQueryOptions(t){if(t._defaulted)return t;const e={...Y(this,el).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return e.queryHash||(e.queryHash=VT(e.queryKey,e)),e.refetchOnReconnect===void 0&&(e.refetchOnReconnect=e.networkMode!=="always"),e.throwOnError===void 0&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),e.enabled!==!0&&e.queryFn===GT&&(e.enabled=!1),e}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...Y(this,el).mutations,...(t==null?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){Y(this,Zt).clear(),Y(this,Ja).clear()}},Zt=new WeakMap,Ja=new WeakMap,el=new WeakMap,Ld=new WeakMap,Fd=new WeakMap,tl=new WeakMap,jd=new WeakMap,Bd=new WeakMap,$k),Fn,vt,em,xn,Nu,Ud,rl,ro,tm,$d,zd,Lu,Fu,nl,Hd,Ct,bf,NS,LS,FS,jS,BS,US,$S,bL,zk,xL=(zk=class extends fh{constructor(e,r){super();Ze(this,Ct);Ze(this,Fn);Ze(this,vt);Ze(this,em);Ze(this,xn);Ze(this,Nu);Ze(this,Ud);Ze(this,rl);Ze(this,ro);Ze(this,tm);Ze(this,$d);Ze(this,zd);Ze(this,Lu);Ze(this,Fu);Ze(this,nl);Ze(this,Hd,new Set);this.options=r,Ne(this,Fn,e),Ne(this,ro,null),Ne(this,rl,OS()),this.options.experimental_prefetchInRender||Y(this,rl).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(r)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(Y(this,vt).addObserver(this),JI(Y(this,vt),this.options)?lt(this,Ct,bf).call(this):this.updateResult(),lt(this,Ct,jS).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return zS(Y(this,vt),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return zS(Y(this,vt),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,lt(this,Ct,BS).call(this),lt(this,Ct,US).call(this),Y(this,vt).removeObserver(this)}setOptions(e,r){const n=this.options,i=Y(this,vt);if(this.options=Y(this,Fn).defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof ps(this.options.enabled,Y(this,vt))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");lt(this,Ct,$S).call(this),Y(this,vt).setOptions(this.options),n._defaulted&&!ny(this.options,n)&&Y(this,Fn).getQueryCache().notify({type:"observerOptionsUpdated",query:Y(this,vt),observer:this});const s=this.hasListeners();s&&e3(Y(this,vt),i,this.options,n)&<(this,Ct,bf).call(this),this.updateResult(r),s&&(Y(this,vt)!==i||ps(this.options.enabled,Y(this,vt))!==ps(n.enabled,Y(this,vt))||xd(this.options.staleTime,Y(this,vt))!==xd(n.staleTime,Y(this,vt)))&<(this,Ct,NS).call(this);const o=lt(this,Ct,LS).call(this);s&&(Y(this,vt)!==i||ps(this.options.enabled,Y(this,vt))!==ps(n.enabled,Y(this,vt))||o!==Y(this,nl))&<(this,Ct,FS).call(this,o)}getOptimisticResult(e){const r=Y(this,Fn).getQueryCache().build(Y(this,Fn),e),n=this.createResult(r,e);return gV(this,n)&&(Ne(this,xn,n),Ne(this,Ud,this.options),Ne(this,Nu,Y(this,vt).state)),n}getCurrentResult(){return Y(this,xn)}trackResult(e,r){const n={};return Object.keys(e).forEach(i=>{Object.defineProperty(n,i,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(i),r==null||r(i),e[i])})}),n}trackProp(e){Y(this,Hd).add(e)}getCurrentQuery(){return Y(this,vt)}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const r=Y(this,Fn).defaultQueryOptions(e),n=Y(this,Fn).getQueryCache().build(Y(this,Fn),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(e){return lt(this,Ct,bf).call(this,{...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),Y(this,xn)))}createResult(e,r){var M;const n=Y(this,vt),i=this.options,s=Y(this,xn),o=Y(this,Nu),a=Y(this,Ud),u=e!==n?e.state:Y(this,em),{state:c}=e;let h={...c},f=!1,m;if(r._optimisticResults){const N=this.hasListeners(),z=!N&&JI(e,r),j=N&&e3(e,n,r,i);(z||j)&&(h={...h,...mL(c.data,e.options)}),r._optimisticResults==="isRestoring"&&(h.fetchStatus="idle")}let{error:y,errorUpdatedAt:v,status:x}=h;if(r.select&&h.data!==void 0)if(s&&h.data===(o==null?void 0:o.data)&&r.select===Y(this,tm))m=Y(this,$d);else try{Ne(this,tm,r.select),m=r.select(h.data),m=kS(s==null?void 0:s.data,m,r),Ne(this,$d,m),Ne(this,ro,null)}catch(N){Ne(this,ro,N)}else m=h.data;if(r.placeholderData!==void 0&&m===void 0&&x==="pending"){let N;if(s!=null&&s.isPlaceholderData&&r.placeholderData===(a==null?void 0:a.placeholderData))N=s.data;else if(N=typeof r.placeholderData=="function"?r.placeholderData((M=Y(this,zd))==null?void 0:M.state.data,Y(this,zd)):r.placeholderData,r.select&&N!==void 0)try{N=r.select(N),Ne(this,ro,null)}catch(z){Ne(this,ro,z)}N!==void 0&&(x="success",m=kS(s==null?void 0:s.data,N,r),f=!0)}Y(this,ro)&&(y=Y(this,ro),m=Y(this,$d),v=Date.now(),x="error");const b=h.fetchStatus==="fetching",_=x==="pending",w=x==="error",E=_&&b,A=m!==void 0,I={status:x,fetchStatus:h.fetchStatus,isPending:_,isSuccess:x==="success",isError:w,isInitialLoading:E,isLoading:E,data:m,dataUpdatedAt:h.dataUpdatedAt,error:y,errorUpdatedAt:v,failureCount:h.fetchFailureCount,failureReason:h.fetchFailureReason,errorUpdateCount:h.errorUpdateCount,isFetched:h.dataUpdateCount>0||h.errorUpdateCount>0,isFetchedAfterMount:h.dataUpdateCount>u.dataUpdateCount||h.errorUpdateCount>u.errorUpdateCount,isFetching:b,isRefetching:b&&!_,isLoadingError:w&&!A,isPaused:h.fetchStatus==="paused",isPlaceholderData:f,isRefetchError:w&&A,isStale:XT(e,r),refetch:this.refetch,promise:Y(this,rl)};if(this.options.experimental_prefetchInRender){const N=H=>{I.status==="error"?H.reject(I.error):I.data!==void 0&&H.resolve(I.data)},z=()=>{const H=Ne(this,rl,I.promise=OS());N(H)},j=Y(this,rl);switch(j.status){case"pending":e.queryHash===n.queryHash&&N(j);break;case"fulfilled":(I.status==="error"||I.data!==j.value)&&z();break;case"rejected":(I.status!=="error"||I.error!==j.reason)&&z();break}}return I}updateResult(e){const r=Y(this,xn),n=this.createResult(Y(this,vt),this.options);if(Ne(this,Nu,Y(this,vt).state),Ne(this,Ud,this.options),Y(this,Nu).data!==void 0&&Ne(this,zd,Y(this,vt)),ny(n,r))return;Ne(this,xn,n);const i={},s=()=>{if(!r)return!0;const{notifyOnChangeProps:o}=this.options,a=typeof o=="function"?o():o;if(a==="all"||!a&&!Y(this,Hd).size)return!0;const l=new Set(a??Y(this,Hd));return this.options.throwOnError&&l.add("error"),Object.keys(Y(this,xn)).some(u=>{const c=u;return Y(this,xn)[c]!==r[c]&&l.has(c)})};(e==null?void 0:e.listeners)!==!1&&s()&&(i.listeners=!0),lt(this,Ct,bL).call(this,{...i,...e})}onQueryUpdate(){this.updateResult(),this.hasListeners()&<(this,Ct,jS).call(this)}},Fn=new WeakMap,vt=new WeakMap,em=new WeakMap,xn=new WeakMap,Nu=new WeakMap,Ud=new WeakMap,rl=new WeakMap,ro=new WeakMap,tm=new WeakMap,$d=new WeakMap,zd=new WeakMap,Lu=new WeakMap,Fu=new WeakMap,nl=new WeakMap,Hd=new WeakMap,Ct=new WeakSet,bf=function(e){lt(this,Ct,$S).call(this);let r=Y(this,vt).fetch(this.options,e);return e!=null&&e.throwOnError||(r=r.catch(Ii)),r},NS=function(){lt(this,Ct,BS).call(this);const e=xd(this.options.staleTime,Y(this,vt));if(ec||Y(this,xn).isStale||!IS(e))return;const n=lL(Y(this,xn).dataUpdatedAt,e)+1;Ne(this,Lu,setTimeout(()=>{Y(this,xn).isStale||this.updateResult()},n))},LS=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(Y(this,vt)):this.options.refetchInterval)??!1},FS=function(e){lt(this,Ct,US).call(this),Ne(this,nl,e),!(ec||ps(this.options.enabled,Y(this,vt))===!1||!IS(Y(this,nl))||Y(this,nl)===0)&&Ne(this,Fu,setInterval(()=>{(this.options.refetchIntervalInBackground||WT.isFocused())&<(this,Ct,bf).call(this)},Y(this,nl)))},jS=function(){lt(this,Ct,NS).call(this),lt(this,Ct,FS).call(this,lt(this,Ct,LS).call(this))},BS=function(){Y(this,Lu)&&(clearTimeout(Y(this,Lu)),Ne(this,Lu,void 0))},US=function(){Y(this,Fu)&&(clearInterval(Y(this,Fu)),Ne(this,Fu,void 0))},$S=function(){const e=Y(this,Fn).getQueryCache().build(Y(this,Fn),this.options);if(e===Y(this,vt))return;const r=Y(this,vt);Ne(this,vt,e),Ne(this,em,e.state),this.hasListeners()&&(r==null||r.removeObserver(this),e.addObserver(this))},bL=function(e){Tr.batch(()=>{e.listeners&&this.listeners.forEach(r=>{r(Y(this,xn))}),Y(this,Fn).getQueryCache().notify({query:Y(this,vt),type:"observerResultsUpdated"})})},zk);function mV(t,e){return ps(e.enabled,t)!==!1&&t.state.data===void 0&&!(t.state.status==="error"&&e.retryOnMount===!1)}function JI(t,e){return mV(t,e)||t.state.data!==void 0&&zS(t,e,e.refetchOnMount)}function zS(t,e,r){if(ps(e.enabled,t)!==!1){const n=typeof r=="function"?r(t):r;return n==="always"||n!==!1&&XT(t,e)}return!1}function e3(t,e,r,n){return(t!==e||ps(n.enabled,t)===!1)&&(!r.suspense||t.state.status!=="error")&&XT(t,r)}function XT(t,e){return ps(e.enabled,t)!==!1&&t.isStaleByTime(xd(e.staleTime,t))}function gV(t,e){return!ny(t.getCurrentResult(),e)}var vV=class extends xL{constructor(t,e){super(t,e)}bindMethods(){super.bindMethods(),this.fetchNextPage=this.fetchNextPage.bind(this),this.fetchPreviousPage=this.fetchPreviousPage.bind(this)}setOptions(t,e){super.setOptions({...t,behavior:sy()},e)}getOptimisticResult(t){return t.behavior=sy(),super.getOptimisticResult(t)}fetchNextPage(t){return this.fetch({...t,meta:{fetchMore:{direction:"forward"}}})}fetchPreviousPage(t){return this.fetch({...t,meta:{fetchMore:{direction:"backward"}}})}createResult(t,e){var y,v;const{state:r}=t,n=super.createResult(t,e),{isFetching:i,isRefetching:s,isError:o,isRefetchError:a}=n,l=(v=(y=r.fetchMeta)==null?void 0:y.fetchMore)==null?void 0:v.direction,u=o&&l==="forward",c=i&&l==="forward",h=o&&l==="backward",f=i&&l==="backward";return{...n,fetchNextPage:this.fetchNextPage,fetchPreviousPage:this.fetchPreviousPage,hasNextPage:hV(e,r.data),hasPreviousPage:fV(e,r.data),isFetchNextPageError:u,isFetchingNextPage:c,isFetchPreviousPageError:h,isFetchingPreviousPage:f,isRefetchError:a&&!u&&!h,isRefetching:s&&!c&&!f}}},il,sl,jn,Yo,aa,Z0,HS,Hk,yV=(Hk=class extends fh{constructor(r,n){super();Ze(this,aa);Ze(this,il);Ze(this,sl);Ze(this,jn);Ze(this,Yo);Ne(this,il,r),this.setOptions(n),this.bindMethods(),lt(this,aa,Z0).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(r){var i;const n=this.options;this.options=Y(this,il).defaultMutationOptions(r),ny(this.options,n)||Y(this,il).getMutationCache().notify({type:"observerOptionsUpdated",mutation:Y(this,jn),observer:this}),n!=null&&n.mutationKey&&this.options.mutationKey&&tc(n.mutationKey)!==tc(this.options.mutationKey)?this.reset():((i=Y(this,jn))==null?void 0:i.state.status)==="pending"&&Y(this,jn).setOptions(this.options)}onUnsubscribe(){var r;this.hasListeners()||(r=Y(this,jn))==null||r.removeObserver(this)}onMutationUpdate(r){lt(this,aa,Z0).call(this),lt(this,aa,HS).call(this,r)}getCurrentResult(){return Y(this,sl)}reset(){var r;(r=Y(this,jn))==null||r.removeObserver(this),Ne(this,jn,void 0),lt(this,aa,Z0).call(this),lt(this,aa,HS).call(this)}mutate(r,n){var i;return Ne(this,Yo,n),(i=Y(this,jn))==null||i.removeObserver(this),Ne(this,jn,Y(this,il).getMutationCache().build(Y(this,il),this.options)),Y(this,jn).addObserver(this),Y(this,jn).execute(r)}},il=new WeakMap,sl=new WeakMap,jn=new WeakMap,Yo=new WeakMap,aa=new WeakSet,Z0=function(){var n;const r=((n=Y(this,jn))==null?void 0:n.state)??vL();Ne(this,sl,{...r,isPending:r.status==="pending",isSuccess:r.status==="success",isError:r.status==="error",isIdle:r.status==="idle",mutate:this.mutate,reset:this.reset})},HS=function(r){Tr.batch(()=>{var n,i,s,o,a,l,u,c;if(Y(this,Yo)&&this.hasListeners()){const h=Y(this,sl).variables,f=Y(this,sl).context;(r==null?void 0:r.type)==="success"?((i=(n=Y(this,Yo)).onSuccess)==null||i.call(n,r.data,h,f),(o=(s=Y(this,Yo)).onSettled)==null||o.call(s,r.data,null,h,f)):(r==null?void 0:r.type)==="error"&&((l=(a=Y(this,Yo)).onError)==null||l.call(a,r.error,h,f),(c=(u=Y(this,Yo)).onSettled)==null||c.call(u,void 0,r.error,h,f))}this.listeners.forEach(h=>{h(Y(this,sl))})})},Hk),wL=T.createContext(void 0),Jr=t=>{const e=T.useContext(wL);if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},xV=({client:t,children:e})=>(T.useEffect(()=>(t.mount(),()=>{t.unmount()}),[t]),g.jsx(wL.Provider,{value:t,children:e})),_L=T.createContext(!1),bV=()=>T.useContext(_L);_L.Provider;function wV(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}var _V=T.createContext(wV()),SV=()=>T.useContext(_V);function SL(t,e){return typeof t=="function"?t(...e):!!t}function VS(){}var EV=(t,e)=>{(t.suspense||t.throwOnError||t.experimental_prefetchInRender)&&(e.isReset()||(t.retryOnMount=!1))},TV=t=>{T.useEffect(()=>{t.clearReset()},[t])},CV=({result:t,errorResetBoundary:e,throwOnError:r,query:n})=>t.isError&&!e.isReset()&&!t.isFetching&&n&&SL(r,[t.error,n]),AV=t=>{t.suspense&&(t.staleTime===void 0&&(t.staleTime=1e3),typeof t.gcTime=="number"&&(t.gcTime=Math.max(t.gcTime,1e3)))},RV=(t,e)=>t.isLoading&&t.isFetching&&!e,PV=(t,e)=>(t==null?void 0:t.suspense)&&e.isPending,t3=(t,e,r)=>e.fetchOptimistic(t).catch(()=>{r.clearReset()});function EL(t,e,r){var c,h,f,m,y;const n=Jr(),i=bV(),s=SV(),o=n.defaultQueryOptions(t);(h=(c=n.getDefaultOptions().queries)==null?void 0:c._experimental_beforeQuery)==null||h.call(c,o),o._optimisticResults=i?"isRestoring":"optimistic",AV(o),EV(o,s),TV(s);const a=!n.getQueryCache().get(o.queryHash),[l]=T.useState(()=>new e(n,o)),u=l.getOptimisticResult(o);if(T.useSyncExternalStore(T.useCallback(v=>{const x=i?VS:l.subscribe(Tr.batchCalls(v));return l.updateResult(),x},[l,i]),()=>l.getCurrentResult(),()=>l.getCurrentResult()),T.useEffect(()=>{l.setOptions(o,{listeners:!1})},[o,l]),PV(o,u))throw t3(o,l,s);if(CV({result:u,errorResetBoundary:s,throwOnError:o.throwOnError,query:n.getQueryCache().get(o.queryHash)}))throw u.error;if((m=(f=n.getDefaultOptions().queries)==null?void 0:f._experimental_afterQuery)==null||m.call(f,o,u),o.experimental_prefetchInRender&&!ec&&RV(u,i)){const v=a?t3(o,l,s):(y=n.getQueryCache().get(o.queryHash))==null?void 0:y.promise;v==null||v.catch(VS).finally(()=>{l.updateResult()})}return o.notifyOnChangeProps?u:l.trackResult(u)}function qT(t,e){return EL(t,xL)}function Mo(t,e){const r=Jr(),[n]=T.useState(()=>new yV(r,t));T.useEffect(()=>{n.setOptions(t)},[n,t]);const i=T.useSyncExternalStore(T.useCallback(o=>n.subscribe(Tr.batchCalls(o)),[n]),()=>n.getCurrentResult(),()=>n.getCurrentResult()),s=T.useCallback((o,a)=>{n.mutate(o,a).catch(VS)},[n]);if(i.error&&SL(n.options.throwOnError,[i.error]))throw i.error;return{...i,mutate:s,mutateAsync:i.mutate}}function IV(t,e){return EL(t,vV)}function MV({src:t,placeholder:e}){const[r,n]=T.useState(t||e),i=T.useCallback(()=>{n(e)},[e]);return T.useEffect(()=>{n(t)},[t]),{imgSrc:r,onError:i}}const kV=T.forwardRef((t,e)=>{const{isLoading:r,loadingIcon:n,loadingPosition:i="left",children:s,className:o,...a}=t,l=()=>{let c;return n?c=n:c=g.jsx(UN,{...a,"aria-label":"Loading"}),c},u=Re("loading d-flex align-items-center gap-8",{"is-loading":r},o);return g.jsxs("div",{className:u,role:"status",ref:e,children:[(!i||i==="left")&&l(),s,i==="right"&&l()]})}),YT=kV,OV=T.forwardRef(({color:t="primary",type:e="button",size:r="md",children:n,isLoading:i,loadingIcon:s,loadingPosition:o,leftIcon:a,rightIcon:l,className:u,variant:c="filled",...h},f)=>{const m=Re("btn",{[`btn-filled btn-${t}`]:c==="filled",[`btn-${c}-${t}`]:c==="outline"||c==="ghost","btn-icon":!n,"btn-loading":i,"btn-lg":r==="lg","btn-sm":r==="sm"},u);return g.jsx("button",{ref:f,className:m,type:e,...h,children:i?g.jsx(YT,{isLoading:!0,loadingIcon:s,loadingPosition:o,children:n}):g.jsxs("span",{children:[a,n,l]})})}),it=OV;function Pn(){const t="/",e=`${t}assets/themes/edifice-bootstrap/images`,r=`${t}assets/themes/edifice-bootstrap/icons`,n=`${t}assets/themes/edifice-bootstrap/fonts`;return[e,r,n]}function TL({appCode:t}){return qT({queryKey:["conf"],queryFn:async()=>await Me.conf().getConf(t)})}function DV(){return qT({queryKey:["session"],queryFn:async()=>await Me.session().getSession()})}const CL=T.createContext(null);function NV({children:t,params:e}){var r;const n=e.app,{t:i}=we(),s=i(n),o=DV(),a=TL({appCode:n}),l=(a==null?void 0:a.isSuccess)&&(o==null?void 0:o.isSuccess),u=((r=o==null?void 0:o.data)==null?void 0:r.currentLanguage)??"fr";T.useEffect(()=>{[{data:"html",value:u},{data:"translate",value:"no"}].forEach(h=>{var f;return(f=document.querySelector("html"))==null?void 0:f.setAttribute(h.data,h.value)})},[u,o.data]),T.useEffect(()=>{document.title=`${s}`},[n,o.data,s]);const c=T.useMemo(()=>{var h,f,m,y,v;return{appCode:n,applications:(h=a==null?void 0:a.data)==null?void 0:h.applications,confQuery:a,currentApp:(f=a==null?void 0:a.data)==null?void 0:f.currentApp,currentLanguage:u,init:l,sessionQuery:o,user:(m=o==null?void 0:o.data)==null?void 0:m.user,userDescription:(y=o==null?void 0:o.data)==null?void 0:y.userDescription,userProfile:(v=o==null?void 0:o.data)==null?void 0:v.userProfile}},[n,a,u,l,o]);return g.jsx(CL.Provider,{value:c,children:t})}function yt(){const t=T.useContext(CL);if(!t)throw new Error("Cannot be used outside of OdeClientProvider");return t}const LV=T.forwardRef(({src:t,alt:e,imgPlaceholder:r,ratio:n,objectFit:i,className:s,...o},a)=>{const[l]=Pn(),u=r??`${l}/common/image-placeholder.png`,{imgSrc:c,onError:h}=MV({src:t,placeholder:u}),f={"ratio ratio-1x1":n==="1","ratio ratio-4x3":n==="4","ratio ratio-16x9":n==="16","ratio ratio-21x9":n==="21"},m={"object-fit-contain":i==="contain","object-fit-cover":i==="cover","object-fit-fill":i==="fill","object-fit-scale":i==="scale","object-fit-none":i==="none"},y=Re({...f}),v=Re({...m},s),x=g.jsx("img",{alt:e,onError:h,ref:a,src:c,className:v,...o});return n?g.jsx("div",{className:y,children:x}):x}),wo=LV,FV=T.forwardRef(({variant:t="square",size:e="md",alt:r,src:n,imgPlaceholder:i,className:s,...o},a)=>{const[l]=Pn(),u=i||`${l}/avatar/no-avatar.svg`,c=Re("avatar",{"avatar-xs":e==="xs","avatar-sm":e==="sm","avatar-md":e==="md","avatar-lg":e==="lg","avatar-xl":e==="xl",square:t==="square",rounded:t==="rounded","rounded-circle":t==="circle"},s);return g.jsx("div",{ref:a,className:c,children:g.jsx(wo,{src:n||u,alt:r,imgPlaceholder:u,...o})})}),rc=FV,jV=T.forwardRef(({className:t,variant:e={type:"notification",level:"info"},children:r,...n},i)=>{const s=Re("badge rounded-pill",(e.type==="content"||e.type==="user")&&"background"in e?"bg-gray-200":(e.type==="content"||e.type==="user")&&!("background"in e)?"border border-0":"",e.type==="content"&&`text-${e.level}`,e.type==="notification"&&`badge-notification bg-${e.level} text-light border border-0`,e.type==="user"&&`badge-profile-${e.profile.toLowerCase()}`,e.type==="link"&&"badge-link border border-0",e.type==="chip"&&"bg-gray-200",t);return g.jsx("span",{ref:i,className:s,...n,children:e.type==="chip"?g.jsx("div",{className:"d-flex fw-800 align-items-center",children:r}):r})}),ow=jV,BV=T.forwardRef(({level:t="h1",headingStyle:e="h1",children:r,className:n,...i},s)=>{const o=Re(e,n);return g.jsx(t,{ref:s,className:o,...i,children:r})}),Ss=BV,UV=({imageSrc:t,imageAlt:e="",title:r,text:n,size:i=250,className:s})=>{const o=Re("text",s);return g.jsxs("div",{className:"emptyscreen",children:[t&&g.jsx("div",{className:"emptyscreen-image mb-12",children:g.jsx("img",{className:"mx-auto",src:t,alt:e,width:i,height:i})}),r&&g.jsx(Ss,{level:"h2",headingStyle:"h2",className:"text-secondary mb-8",children:r}),n&&g.jsx("div",{className:o,children:n})]})},ha=UV;var jl=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function QT(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var AL={exports:{}};(function(t,e){(function(r,n){t.exports=n()})(jl,function(){var r={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},n=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,i=/\d\d/,s=/\d\d?/,o=/\d*[^-_:/,()\s\d]+/,a={},l=function(v){return(v=+v)+(v>68?1900:2e3)},u=function(v){return function(x){this[v]=+x}},c=[/[+-]\d\d:?(\d\d)?|Z/,function(v){(this.zone||(this.zone={})).offset=function(x){if(!x||x==="Z")return 0;var b=x.match(/([+-]|\d\d)/g),_=60*b[1]+(+b[2]||0);return _===0?0:b[0]==="+"?-_:_}(v)}],h=function(v){var x=a[v];return x&&(x.indexOf?x:x.s.concat(x.f))},f=function(v,x){var b,_=a.meridiem;if(_){for(var w=1;w<=24;w+=1)if(v.indexOf(_(w,0,x))>-1){b=w>12;break}}else b=v===(x?"pm":"PM");return b},m={A:[o,function(v){this.afternoon=f(v,!1)}],a:[o,function(v){this.afternoon=f(v,!0)}],S:[/\d/,function(v){this.milliseconds=100*+v}],SS:[i,function(v){this.milliseconds=10*+v}],SSS:[/\d{3}/,function(v){this.milliseconds=+v}],s:[s,u("seconds")],ss:[s,u("seconds")],m:[s,u("minutes")],mm:[s,u("minutes")],H:[s,u("hours")],h:[s,u("hours")],HH:[s,u("hours")],hh:[s,u("hours")],D:[s,u("day")],DD:[i,u("day")],Do:[o,function(v){var x=a.ordinal,b=v.match(/\d+/);if(this.day=b[0],x)for(var _=1;_<=31;_+=1)x(_).replace(/\[|\]/g,"")===v&&(this.day=_)}],M:[s,u("month")],MM:[i,u("month")],MMM:[o,function(v){var x=h("months"),b=(h("monthsShort")||x.map(function(_){return _.slice(0,3)})).indexOf(v)+1;if(b<1)throw new Error;this.month=b%12||b}],MMMM:[o,function(v){var x=h("months").indexOf(v)+1;if(x<1)throw new Error;this.month=x%12||x}],Y:[/[+-]?\d+/,u("year")],YY:[i,function(v){this.year=l(v)}],YYYY:[/\d{4}/,u("year")],Z:c,ZZ:c};function y(v){var x,b;x=v,b=a&&a.formats;for(var _=(v=x.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(N,z,j){var H=j&&j.toUpperCase();return z||b[j]||r[j]||b[H].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(F,L,O){return L||O.slice(1)})})).match(n),w=_.length,E=0;E<w;E+=1){var A=_[E],P=m[A],I=P&&P[0],M=P&&P[1];_[E]=M?{regex:I,parser:M}:A.replace(/^\[|\]$/g,"")}return function(N){for(var z={},j=0,H=0;j<w;j+=1){var F=_[j];if(typeof F=="string")H+=F.length;else{var L=F.regex,O=F.parser,$=N.slice(H),V=L.exec($)[0];O.call(z,V),N=N.replace(V,"")}}return function(k){var U=k.afternoon;if(U!==void 0){var B=k.hours;U?B<12&&(k.hours+=12):B===12&&(k.hours=0),delete k.afternoon}}(z),z}}return function(v,x,b){b.p.customParseFormat=!0,v&&v.parseTwoDigitYear&&(l=v.parseTwoDigitYear);var _=x.prototype,w=_.parse;_.parse=function(E){var A=E.date,P=E.utc,I=E.args;this.$u=P;var M=I[1];if(typeof M=="string"){var N=I[2]===!0,z=I[3]===!0,j=N||z,H=I[2];z&&(H=I[2]),a=this.$locale(),!N&&H&&(a=b.Ls[H]),this.$d=function($,V,k){try{if(["x","X"].indexOf(V)>-1)return new Date((V==="X"?1e3:1)*$);var U=y(V)($),B=U.year,X=U.month,K=U.day,q=U.hours,re=U.minutes,ue=U.seconds,le=U.milliseconds,me=U.zone,xe=new Date,_e=K||(B||X?1:xe.getDate()),Te=B||xe.getFullYear(),de=0;B&&!X||(de=X>0?X-1:xe.getMonth());var Be=q||0,je=re||0,ut=ue||0,Pe=le||0;return me?new Date(Date.UTC(Te,de,_e,Be,je,ut,Pe+60*me.offset*1e3)):k?new Date(Date.UTC(Te,de,_e,Be,je,ut,Pe)):new Date(Te,de,_e,Be,je,ut,Pe)}catch{return new Date("")}}(A,M,P),this.init(),H&&H!==!0&&(this.$L=this.locale(H).$L),j&&A!=this.format(M)&&(this.$d=new Date("")),a={}}else if(M instanceof Array)for(var F=M.length,L=1;L<=F;L+=1){I[1]=M[L-1];var O=b.apply(this,I);if(O.isValid()){this.$d=O.$d,this.$L=O.$L,this.init();break}L===F&&(this.$d=new Date(""))}else w.call(this,E)}}})})(AL);var $V=AL.exports;const zV=QT($V);var RL={exports:{}};(function(t,e){(function(r,n){t.exports=n()})(jl,function(){var r={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(n,i,s){var o=i.prototype,a=o.format;s.en.formats=r,o.format=function(l){l===void 0&&(l="YYYY-MM-DDTHH:mm:ssZ");var u=this.$locale().formats,c=function(h,f){return h.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(m,y,v){var x=v&&v.toUpperCase();return y||f[v]||r[v]||f[x].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(b,_,w){return _||w.slice(1)})})}(l,u===void 0?{}:u);return a.call(this,c)}}})})(RL);var HV=RL.exports;const VV=QT(HV);var PL={exports:{}};(function(t,e){(function(r,n){t.exports=n()})(jl,function(){return function(r,n,i){r=r||{};var s=n.prototype,o={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function a(u,c,h,f){return s.fromToBase(u,c,h,f)}i.en.relativeTime=o,s.fromToBase=function(u,c,h,f,m){for(var y,v,x,b=h.$locale().relativeTime||o,_=r.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],w=_.length,E=0;E<w;E+=1){var A=_[E];A.d&&(y=f?i(u).diff(h,A.d,!0):h.diff(u,A.d,!0));var P=(r.rounding||Math.round)(Math.abs(y));if(x=y>0,P<=A.r||!A.r){P<=1&&E>0&&(A=_[E-1]);var I=b[A.l];m&&(P=m(""+P)),v=typeof I=="string"?I.replace("%d",P):I(P,c,A.l,x);break}}if(c)return v;var M=x?b.future:b.past;return typeof M=="function"?M(v):M.replace("%s",v)},s.to=function(u,c){return a(u,c,this,!0)},s.from=function(u,c){return a(u,c,this)};var l=function(u){return u.$u?i.utc():i()};s.toNow=function(u){return this.to(l(this),u)},s.fromNow=function(u){return this.from(l(this),u)}}})})(PL);var GV=PL.exports;const WV=QT(GV);var XV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(l){return l&&typeof l=="object"&&"default"in l?l:{default:l}}var i=n(r),s={s:"ein paar Sekunden",m:["eine Minute","einer Minute"],mm:"%d Minuten",h:["eine Stunde","einer Stunde"],hh:"%d Stunden",d:["ein Tag","einem Tag"],dd:["%d Tage","%d Tagen"],M:["ein Monat","einem Monat"],MM:["%d Monate","%d Monaten"],y:["ein Jahr","einem Jahr"],yy:["%d Jahre","%d Jahren"]};function o(l,u,c){var h=s[c];return Array.isArray(h)&&(h=h[u?0:1]),h.replace("%d",l)}var a={name:"de",weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sept._Okt._Nov._Dez.".split("_"),ordinal:function(l){return l+"."},weekStart:1,yearStart:4,formats:{LTS:"HH:mm:ss",LT:"HH:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},relativeTime:{future:"in %s",past:"vor %s",s:o,m:o,mm:o,h:o,hh:o,d:o,dd:o,M:o,MM:o,y:o,yy:o}};return i.default.locale(a,null,!0),a})})(XV);var qV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(o){return o&&typeof o=="object"&&"default"in o?o:{default:o}}var i=n(r),s={name:"es",monthsShort:"ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),weekStart:1,formats:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},ordinal:function(o){return o+"º"}};return i.default.locale(s,null,!0),s})})(qV);var YV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(o){return o&&typeof o=="object"&&"default"in o?o:{default:o}}var i=n(r),s={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(o){return""+o+(o===1?"er":"")}};return i.default.locale(s,null,!0),s})})(YV);var QV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(o){return o&&typeof o=="object"&&"default"in o?o:{default:o}}var i=n(r),s={name:"it",weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),weekStart:1,monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"tra %s",past:"%s fa",s:"qualche secondo",m:"un minuto",mm:"%d minuti",h:"un' ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},ordinal:function(o){return o+"º"}};return i.default.locale(s,null,!0),s})})(QV);var KV={exports:{}};(function(t,e){(function(r,n){t.exports=n(Lr)})(jl,function(r){function n(o){return o&&typeof o=="object"&&"default"in o?o:{default:o}}var i=n(r),s={name:"pt",weekdays:"domingo_segunda-feira_terça-feira_quarta-feira_quinta-feira_sexta-feira_sábado".split("_"),weekdaysShort:"dom_seg_ter_qua_qui_sex_sab".split("_"),weekdaysMin:"Do_2ª_3ª_4ª_5ª_6ª_Sa".split("_"),months:"janeiro_fevereiro_março_abril_maio_junho_julho_agosto_setembro_outubro_novembro_dezembro".split("_"),monthsShort:"jan_fev_mar_abr_mai_jun_jul_ago_set_out_nov_dez".split("_"),ordinal:function(o){return o+"º"},weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY [às] HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY [às] HH:mm"},relativeTime:{future:"em %s",past:"há %s",s:"alguns segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"}};return i.default.locale(s,null,!0),s})})(KV);Lr.extend(WV);Lr.extend(zV);Lr.extend(VV);function IL(){const{currentLanguage:t}=yt(),e=T.useCallback((i,s)=>{if(i.length<11)return Lr(i,["YYYY-MM-DD"],s);if(i.split("").findIndex(o=>"0">o||o>"9")<0)return Lr(Number.parseInt(i)).locale(t);{let o=Lr(i).locale(t);return o.isValid()||(o=Lr(i,["YYYY-MM-DD HH:mm:ss.SSS"]).locale(t)),o}},[t]),r=T.useCallback(i=>{let s=Lr();try{return typeof i>"u"?"":(typeof i=="string"?s=e(i):typeof i=="number"?s=Lr(i).locale(t):typeof i.$date=="number"?s=Lr(new Date(i.$date)).locale(t):typeof i.$date=="string"&&(s=e(i.$date)),s.isValid()?s.fromNow():"")}catch{return""}},[t,e]),n=T.useCallback((i,s="short")=>{let o=Lr();try{if(typeof i>"u")return"";typeof i=="string"?o=e(i):typeof i=="number"?o=Lr(i).locale(t):typeof i.$date=="number"?o=Lr(new Date(i.$date)).locale(t):typeof i.$date=="string"&&(o=e(i.$date));let a="";switch(s){case"short":a="L";break;case"long":a="LL";break;case"abbr":a="ll";break;default:a=s}return o.isValid()?o.locale(t).format(a):""}catch{return""}},[t,e]);return{fromNow:r,formatDate:n}}let ZV={data:""},JV=t=>typeof window=="object"?((t?t.querySelector("#_goober"):window._goober)||Object.assign((t||document.head).appendChild(document.createElement("style")),{innerHTML:" ",id:"_goober"})).firstChild:t||ZV,eG=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,tG=/\/\*[^]*?\*\/| +/g,r3=/\n+/g,Ya=(t,e)=>{let r="",n="",i="";for(let s in t){let o=t[s];s[0]=="@"?s[1]=="i"?r=s+" "+o+";":n+=s[1]=="f"?Ya(o,s):s+"{"+Ya(o,s[1]=="k"?"":e)+"}":typeof o=="object"?n+=Ya(o,e?e.replace(/([^,])+/g,a=>s.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,l=>/&/.test(l)?l.replace(/&/g,a):a?a+" "+l:l)):s):o!=null&&(s=/^--/.test(s)?s:s.replace(/[A-Z]/g,"-$&").toLowerCase(),i+=Ya.p?Ya.p(s,o):s+":"+o+";")}return r+(e&&i?e+"{"+i+"}":i)+n},Bo={},ML=t=>{if(typeof t=="object"){let e="";for(let r in t)e+=r+ML(t[r]);return e}return t},rG=(t,e,r,n,i)=>{let s=ML(t),o=Bo[s]||(Bo[s]=(l=>{let u=0,c=11;for(;u<l.length;)c=101*c+l.charCodeAt(u++)>>>0;return"go"+c})(s));if(!Bo[o]){let l=s!==t?t:(u=>{let c,h,f=[{}];for(;c=eG.exec(u.replace(tG,""));)c[4]?f.shift():c[3]?(h=c[3].replace(r3," ").trim(),f.unshift(f[0][h]=f[0][h]||{})):f[0][c[1]]=c[2].replace(r3," ").trim();return f[0]})(t);Bo[o]=Ya(i?{["@keyframes "+o]:l}:l,r?"":"."+o)}let a=r&&Bo.g?Bo.g:null;return r&&(Bo.g=Bo[o]),((l,u,c,h)=>{h?u.data=u.data.replace(h,l):u.data.indexOf(l)===-1&&(u.data=c?l+u.data:u.data+l)})(Bo[o],e,n,a),o},nG=(t,e,r)=>t.reduce((n,i,s)=>{let o=e[s];if(o&&o.call){let a=o(r),l=a&&a.props&&a.props.className||/^go/.test(a)&&a;o=l?"."+l:a&&typeof a=="object"?a.props?"":Ya(a,""):a===!1?"":a}return n+i+(o??"")},"");function g1(t){let e=this||{},r=t.call?t(e.p):t;return rG(r.unshift?r.raw?nG(r,[].slice.call(arguments,1),e.p):r.reduce((n,i)=>Object.assign(n,i&&i.call?i(e.p):i),{}):r,JV(e.target),e.g,e.o,e.k)}let kL,GS,WS;g1.bind({g:1});let fa=g1.bind({k:1});function iG(t,e,r,n){Ya.p=e,kL=t,GS=r,WS=n}function Bl(t,e){let r=this||{};return function(){let n=arguments;function i(s,o){let a=Object.assign({},s),l=a.className||i.className;r.p=Object.assign({theme:GS&&GS()},a),r.o=/ *go\d+/.test(l),a.className=g1.apply(r,n)+(l?" "+l:"");let u=t;return t[0]&&(u=a.as||t,delete a.as),WS&&u[0]&&WS(a),kL(u,a)}return i}}var sG=t=>typeof t=="function",oy=(t,e)=>sG(t)?t(e):t,oG=(()=>{let t=0;return()=>(++t).toString()})(),OL=(()=>{let t;return()=>{if(t===void 0&&typeof window<"u"){let e=matchMedia("(prefers-reduced-motion: reduce)");t=!e||e.matches}return t}})(),aG=20,J0=new Map,lG=1e3,n3=t=>{if(J0.has(t))return;let e=setTimeout(()=>{J0.delete(t),cc({type:4,toastId:t})},lG);J0.set(t,e)},uG=t=>{let e=J0.get(t);e&&clearTimeout(e)},XS=(t,e)=>{switch(e.type){case 0:return{...t,toasts:[e.toast,...t.toasts].slice(0,aG)};case 1:return e.toast.id&&uG(e.toast.id),{...t,toasts:t.toasts.map(s=>s.id===e.toast.id?{...s,...e.toast}:s)};case 2:let{toast:r}=e;return t.toasts.find(s=>s.id===r.id)?XS(t,{type:1,toast:r}):XS(t,{type:0,toast:r});case 3:let{toastId:n}=e;return n?n3(n):t.toasts.forEach(s=>{n3(s.id)}),{...t,toasts:t.toasts.map(s=>s.id===n||n===void 0?{...s,visible:!1}:s)};case 4:return e.toastId===void 0?{...t,toasts:[]}:{...t,toasts:t.toasts.filter(s=>s.id!==e.toastId)};case 5:return{...t,pausedAt:e.time};case 6:let i=e.time-(t.pausedAt||0);return{...t,pausedAt:void 0,toasts:t.toasts.map(s=>({...s,pauseDuration:s.pauseDuration+i}))}}},ev=[],tv={toasts:[],pausedAt:void 0},cc=t=>{tv=XS(tv,t),ev.forEach(e=>{e(tv)})},cG={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},dG=(t={})=>{let[e,r]=T.useState(tv);T.useEffect(()=>(ev.push(r),()=>{let i=ev.indexOf(r);i>-1&&ev.splice(i,1)}),[e]);let n=e.toasts.map(i=>{var s,o;return{...t,...t[i.type],...i,duration:i.duration||((s=t[i.type])==null?void 0:s.duration)||(t==null?void 0:t.duration)||cG[i.type],style:{...t.style,...(o=t[i.type])==null?void 0:o.style,...i.style}}});return{...e,toasts:n}},hG=(t,e="blank",r)=>({createdAt:Date.now(),visible:!0,type:e,ariaProps:{role:"status","aria-live":"polite"},message:t,pauseDuration:0,...r,id:(r==null?void 0:r.id)||oG()}),cm=t=>(e,r)=>{let n=hG(e,t,r);return cc({type:2,toast:n}),n.id},di=(t,e)=>cm("blank")(t,e);di.error=cm("error");di.success=cm("success");di.loading=cm("loading");di.custom=cm("custom");di.dismiss=t=>{cc({type:3,toastId:t})};di.remove=t=>cc({type:4,toastId:t});di.promise=(t,e,r)=>{let n=di.loading(e.loading,{...r,...r==null?void 0:r.loading});return t.then(i=>(di.success(oy(e.success,i),{id:n,...r,...r==null?void 0:r.success}),i)).catch(i=>{di.error(oy(e.error,i),{id:n,...r,...r==null?void 0:r.error})}),t};var fG=(t,e)=>{cc({type:1,toast:{id:t,height:e}})},pG=()=>{cc({type:5,time:Date.now()})},mG=t=>{let{toasts:e,pausedAt:r}=dG(t);T.useEffect(()=>{if(r)return;let s=Date.now(),o=e.map(a=>{if(a.duration===1/0)return;let l=(a.duration||0)+a.pauseDuration-(s-a.createdAt);if(l<0){a.visible&&di.dismiss(a.id);return}return setTimeout(()=>di.dismiss(a.id),l)});return()=>{o.forEach(a=>a&&clearTimeout(a))}},[e,r]);let n=T.useCallback(()=>{r&&cc({type:6,time:Date.now()})},[r]),i=T.useCallback((s,o)=>{let{reverseOrder:a=!1,gutter:l=8,defaultPosition:u}=o||{},c=e.filter(m=>(m.position||u)===(s.position||u)&&m.height),h=c.findIndex(m=>m.id===s.id),f=c.filter((m,y)=>y<h&&m.visible).length;return c.filter(m=>m.visible).slice(...a?[f+1]:[0,f]).reduce((m,y)=>m+(y.height||0)+l,0)},[e]);return{toasts:e,handlers:{updateHeight:fG,startPause:pG,endPause:n,calculateOffset:i}}},gG=fa`
|
|
42
42
|
from {
|
|
43
43
|
transform: scale(0) rotate(45deg);
|
|
44
44
|
opacity: 0;
|
|
@@ -1387,7 +1387,7 @@ void main()
|
|
|
1387
1387
|
Use "options.replacer" or "options.ignoreUnknown"
|
|
1388
1388
|
`)},domwindow(){return n("domwindow")},bigint(i){return n("bigint:"+i.toString())},process(){return n("process")},timer(){return n("timer")},pipe(){return n("pipe")},tcp(){return n("tcp")},udp(){return n("udp")},tty(){return n("tty")},statwatcher(){return n("statwatcher")},securecontext(){return n("securecontext")},connection(){return n("connection")},zlib(){return n("zlib")},context(){return n("context")},nodescript(){return n("nodescript")},httpparser(){return n("httpparser")},dataview(){return n("dataview")},signal(){return n("signal")},fsevent(){return n("fsevent")},tlswrap(){return n("tlswrap")}}}const u6="[native code] }",Ooe=u6.length;function rk(t){return typeof t!="function"?!1:Function.prototype.toString.call(t).slice(-Ooe)===u6}class Cl{constructor(e,r){e=this.words=e||[],this.sigBytes=r===void 0?e.length*4:r}toString(e){return(e||Doe).stringify(this)}concat(e){if(this.clamp(),this.sigBytes%4)for(let r=0;r<e.sigBytes;r++){const n=e.words[r>>>2]>>>24-r%4*8&255;this.words[this.sigBytes+r>>>2]|=n<<24-(this.sigBytes+r)%4*8}else for(let r=0;r<e.sigBytes;r+=4)this.words[this.sigBytes+r>>>2]=e.words[r>>>2];return this.sigBytes+=e.sigBytes,this}clamp(){this.words[this.sigBytes>>>2]&=4294967295<<32-this.sigBytes%4*8,this.words.length=Math.ceil(this.sigBytes/4)}clone(){return new Cl([...this.words])}}const Doe={stringify(t){const e=[];for(let r=0;r<t.sigBytes;r++){const n=t.words[r>>>2]>>>24-r%4*8&255;e.push((n>>>4).toString(16),(n&15).toString(16))}return e.join("")}},Noe={stringify(t){const e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",r=[];for(let n=0;n<t.sigBytes;n+=3){const i=t.words[n>>>2]>>>24-n%4*8&255,s=t.words[n+1>>>2]>>>24-(n+1)%4*8&255,o=t.words[n+2>>>2]>>>24-(n+2)%4*8&255,a=i<<16|s<<8|o;for(let l=0;l<4&&n*8+l*6<t.sigBytes*8;l++)r.push(e.charAt(a>>>6*(3-l)&63))}return r.join("")}},Loe={parse(t){const e=t.length,r=[];for(let n=0;n<e;n++)r[n>>>2]|=(t.charCodeAt(n)&255)<<24-n%4*8;return new Cl(r,e)}},Foe={parse(t){return Loe.parse(unescape(encodeURIComponent(t)))}};class joe{constructor(){this._data=new Cl,this._nDataBytes=0,this._minBufferSize=0,this.blockSize=512/32}reset(){this._data=new Cl,this._nDataBytes=0}_append(e){typeof e=="string"&&(e=Foe.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes}_doProcessBlock(e,r){}_process(e){let r,n=this._data.sigBytes/(this.blockSize*4);e?n=Math.ceil(n):n=Math.max((n|0)-this._minBufferSize,0);const i=n*this.blockSize,s=Math.min(i*4,this._data.sigBytes);if(i){for(let o=0;o<i;o+=this.blockSize)this._doProcessBlock(this._data.words,o);r=this._data.words.splice(0,i),this._data.sigBytes-=s}return new Cl(r,s)}}class Boe extends joe{update(e){return this._append(e),this._process(),this}finalize(e){e&&this._append(e)}}const nk=[1779033703,-1150833019,1013904242,-1521486534,1359893119,-1694144372,528734635,1541459225],Uoe=[1116352408,1899447441,-1245643825,-373957723,961987163,1508970993,-1841331548,-1424204075,-670586216,310598401,607225278,1426881987,1925078388,-2132889090,-1680079193,-1046744716,-459576895,-272742522,264347078,604807628,770255983,1249150122,1555081692,1996064986,-1740746414,-1473132947,-1341970488,-1084653625,-958395405,-710438585,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,-2117940946,-1838011259,-1564481375,-1474664885,-1035236496,-949202525,-778901479,-694614492,-200395387,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,-2067236844,-1933114872,-1866530822,-1538233109,-1090935817,-965641998],hu=[];class $oe extends Boe{constructor(){super(...arguments),this._hash=new Cl([...nk])}reset(){super.reset(),this._hash=new Cl([...nk])}_doProcessBlock(e,r){const n=this._hash.words;let i=n[0],s=n[1],o=n[2],a=n[3],l=n[4],u=n[5],c=n[6],h=n[7];for(let f=0;f<64;f++){if(f<16)hu[f]=e[r+f]|0;else{const w=hu[f-15],E=(w<<25|w>>>7)^(w<<14|w>>>18)^w>>>3,A=hu[f-2],P=(A<<15|A>>>17)^(A<<13|A>>>19)^A>>>10;hu[f]=E+hu[f-7]+P+hu[f-16]}const m=l&u^~l&c,y=i&s^i&o^s&o,v=(i<<30|i>>>2)^(i<<19|i>>>13)^(i<<10|i>>>22),x=(l<<26|l>>>6)^(l<<21|l>>>11)^(l<<7|l>>>25),b=h+x+m+Uoe[f]+hu[f],_=v+y;h=c,c=u,u=l,l=a+b|0,a=o,o=s,s=i,i=b+_|0}n[0]=n[0]+i|0,n[1]=n[1]+s|0,n[2]=n[2]+o|0,n[3]=n[3]+a|0,n[4]=n[4]+l|0,n[5]=n[5]+u|0,n[6]=n[6]+c|0,n[7]=n[7]+h|0}finalize(e){super.finalize(e);const r=this._nDataBytes*8,n=this._data.sigBytes*8;return this._data.words[n>>>5]|=128<<24-n%32,this._data.words[(n+64>>>9<<4)+14]=Math.floor(r/4294967296),this._data.words[(n+64>>>9<<4)+15]=r,this._data.sigBytes=this._data.words.length*4,this._process(),this._hash}}function zoe(t){return new $oe().finalize(t).toString(Noe)}function ik(t,e={}){const r=typeof t=="string"?t:Moe(t,e);return zoe(r).slice(0,10)}var c6={};Object.defineProperty(c6,"__esModule",{value:!0});const Hoe=t=>{const e="ÀÁÂÃÄÅĄĀàáâãäåąāÒÓÔÕÕÖØòóôõöøÈÉÊËĘĒèéêëðęēÇĆČçćčÐÌÍÎÏĪìíîïīÙÚÛÜŪùúûüūÑŅñņŠŚšśŸÿýŽŹŻžźżŁĻłļŃŅńņàáãảạăằắẳẵặâầấẩẫậèéẻẽẹêềếểễệđùúủũụưừứửữựòóỏõọôồốổỗộơờớởỡợìíỉĩịäëïîüûñçýỳỹỵỷğışĞİŞĢģĶķ",r="AAAAAAAAaaaaaaaaOOOOOOOooooooEEEEEEeeeeeeeCCCcccDIIIIIiiiiiUUUUUuuuuuNNnnSSssYyyZZZzzzLLllNNnnaaaaaaaaaaaaaaaaaeeeeeeeeeeeduuuuuuuuuuuoooooooooooooooooiiiiiaeiiuuncyyyyygisGISGgKk",n=e.split("").join("|"),i=new RegExp(`(${n})`,"g");function s(o){return r[e.indexOf(o)]||""}return t.replace(i,s)},Voe=t=>t.split("").map(e=>`\\${e}`).join(""),sk=(t,e,r=!1)=>{const n=Hoe(t).trim().toLowerCase(),i=Voe(e);return r?n.replace(/\s+/g,e):n.replace(new RegExp(`[^a-z0-9${i}]+`,"g"),e).replace(new RegExp(`${i}+`,"g"),e).replace(new RegExp(`^${i}`,"g"),"").replace(new RegExp(`${i}$`,"g"),"")},If=(t,e={delimiter:"-",prefix:""})=>{if(e.delimiter||(e.delimiter="-"),e.prefix||(e.prefix=""),!t||typeof t=="boolean")return"";const{delimiter:r,prefix:n}=e;if(typeof t=="boolean")return"";if(typeof t=="string"||typeof t=="number"){const i=sk(n,r,!0),s=sk(String(t),r);return i?`${i}${r}${s}`:s}return"children"in t?If(t.children):"type"in t?If(t.props.children,e):Symbol.iterator in t?If(Array.from(t).map(i=>If(i,{delimiter:r})).join(r),e):""};var ok=c6.default=If;Tt.Down,Tt.Right,Tt.Up,Tt.Left;var YC={},QC={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.Doctype=t.CDATA=t.Tag=t.Style=t.Script=t.Comment=t.Directive=t.Text=t.Root=t.isTag=t.ElementType=void 0;var e;(function(n){n.Root="root",n.Text="text",n.Directive="directive",n.Comment="comment",n.Script="script",n.Style="style",n.Tag="tag",n.CDATA="cdata",n.Doctype="doctype"})(e=t.ElementType||(t.ElementType={}));function r(n){return n.type===e.Tag||n.type===e.Script||n.type===e.Style}t.isTag=r,t.Root=e.Root,t.Text=e.Text,t.Directive=e.Directive,t.Comment=e.Comment,t.Script=e.Script,t.Style=e.Style,t.Tag=e.Tag,t.CDATA=e.CDATA,t.Doctype=e.Doctype})(QC);var dt={},Vl=rr&&rr.__extends||function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var s in i)Object.prototype.hasOwnProperty.call(i,s)&&(n[s]=i[s])},t(e,r)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}(),ip=rr&&rr.__assign||function(){return ip=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++){e=arguments[r];for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i])}return t},ip.apply(this,arguments)};Object.defineProperty(dt,"__esModule",{value:!0});dt.cloneNode=dt.hasChildren=dt.isDocument=dt.isDirective=dt.isComment=dt.isText=dt.isCDATA=dt.isTag=dt.Element=dt.Document=dt.CDATA=dt.NodeWithChildren=dt.ProcessingInstruction=dt.Comment=dt.Text=dt.DataNode=dt.Node=void 0;var Qn=QC,KC=function(){function t(){this.parent=null,this.prev=null,this.next=null,this.startIndex=null,this.endIndex=null}return Object.defineProperty(t.prototype,"parentNode",{get:function(){return this.parent},set:function(e){this.parent=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"previousSibling",{get:function(){return this.prev},set:function(e){this.prev=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"nextSibling",{get:function(){return this.next},set:function(e){this.next=e},enumerable:!1,configurable:!0}),t.prototype.cloneNode=function(e){return e===void 0&&(e=!1),ZC(this,e)},t}();dt.Node=KC;var G1=function(t){Vl(e,t);function e(r){var n=t.call(this)||this;return n.data=r,n}return Object.defineProperty(e.prototype,"nodeValue",{get:function(){return this.data},set:function(r){this.data=r},enumerable:!1,configurable:!0}),e}(KC);dt.DataNode=G1;var d6=function(t){Vl(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.type=Qn.ElementType.Text,r}return Object.defineProperty(e.prototype,"nodeType",{get:function(){return 3},enumerable:!1,configurable:!0}),e}(G1);dt.Text=d6;var h6=function(t){Vl(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.type=Qn.ElementType.Comment,r}return Object.defineProperty(e.prototype,"nodeType",{get:function(){return 8},enumerable:!1,configurable:!0}),e}(G1);dt.Comment=h6;var f6=function(t){Vl(e,t);function e(r,n){var i=t.call(this,n)||this;return i.name=r,i.type=Qn.ElementType.Directive,i}return Object.defineProperty(e.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),e}(G1);dt.ProcessingInstruction=f6;var W1=function(t){Vl(e,t);function e(r){var n=t.call(this)||this;return n.children=r,n}return Object.defineProperty(e.prototype,"firstChild",{get:function(){var r;return(r=this.children[0])!==null&&r!==void 0?r:null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastChild",{get:function(){return this.children.length>0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"childNodes",{get:function(){return this.children},set:function(r){this.children=r},enumerable:!1,configurable:!0}),e}(KC);dt.NodeWithChildren=W1;var p6=function(t){Vl(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.type=Qn.ElementType.CDATA,r}return Object.defineProperty(e.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),e}(W1);dt.CDATA=p6;var m6=function(t){Vl(e,t);function e(){var r=t!==null&&t.apply(this,arguments)||this;return r.type=Qn.ElementType.Root,r}return Object.defineProperty(e.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),e}(W1);dt.Document=m6;var g6=function(t){Vl(e,t);function e(r,n,i,s){i===void 0&&(i=[]),s===void 0&&(s=r==="script"?Qn.ElementType.Script:r==="style"?Qn.ElementType.Style:Qn.ElementType.Tag);var o=t.call(this,i)||this;return o.name=r,o.attribs=n,o.type=s,o}return Object.defineProperty(e.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tagName",{get:function(){return this.name},set:function(r){this.name=r},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"attributes",{get:function(){var r=this;return Object.keys(this.attribs).map(function(n){var i,s;return{name:n,value:r.attribs[n],namespace:(i=r["x-attribsNamespace"])===null||i===void 0?void 0:i[n],prefix:(s=r["x-attribsPrefix"])===null||s===void 0?void 0:s[n]}})},enumerable:!1,configurable:!0}),e}(W1);dt.Element=g6;function v6(t){return(0,Qn.isTag)(t)}dt.isTag=v6;function y6(t){return t.type===Qn.ElementType.CDATA}dt.isCDATA=y6;function x6(t){return t.type===Qn.ElementType.Text}dt.isText=x6;function b6(t){return t.type===Qn.ElementType.Comment}dt.isComment=b6;function w6(t){return t.type===Qn.ElementType.Directive}dt.isDirective=w6;function _6(t){return t.type===Qn.ElementType.Root}dt.isDocument=_6;function Goe(t){return Object.prototype.hasOwnProperty.call(t,"children")}dt.hasChildren=Goe;function ZC(t,e){e===void 0&&(e=!1);var r;if(x6(t))r=new d6(t.data);else if(b6(t))r=new h6(t.data);else if(v6(t)){var n=e?f_(t.children):[],i=new g6(t.name,ip({},t.attribs),n);n.forEach(function(l){return l.parent=i}),t.namespace!=null&&(i.namespace=t.namespace),t["x-attribsNamespace"]&&(i["x-attribsNamespace"]=ip({},t["x-attribsNamespace"])),t["x-attribsPrefix"]&&(i["x-attribsPrefix"]=ip({},t["x-attribsPrefix"])),r=i}else if(y6(t)){var n=e?f_(t.children):[],s=new p6(n);n.forEach(function(u){return u.parent=s}),r=s}else if(_6(t)){var n=e?f_(t.children):[],o=new m6(n);n.forEach(function(u){return u.parent=o}),t["x-mode"]&&(o["x-mode"]=t["x-mode"]),r=o}else if(w6(t)){var a=new f6(t.name,t.data);t["x-name"]!=null&&(a["x-name"]=t["x-name"],a["x-publicId"]=t["x-publicId"],a["x-systemId"]=t["x-systemId"]),r=a}else throw new Error("Not implemented yet: ".concat(t.type));return r.startIndex=t.startIndex,r.endIndex=t.endIndex,t.sourceCodeLocation!=null&&(r.sourceCodeLocation=t.sourceCodeLocation),r}dt.cloneNode=ZC;function f_(t){for(var e=t.map(function(n){return ZC(n,!0)}),r=1;r<e.length;r++)e[r].prev=e[r-1],e[r-1].next=e[r];return e}(function(t){var e=rr&&rr.__createBinding||(Object.create?function(a,l,u,c){c===void 0&&(c=u);var h=Object.getOwnPropertyDescriptor(l,u);(!h||("get"in h?!l.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:function(){return l[u]}}),Object.defineProperty(a,c,h)}:function(a,l,u,c){c===void 0&&(c=u),a[c]=l[u]}),r=rr&&rr.__exportStar||function(a,l){for(var u in a)u!=="default"&&!Object.prototype.hasOwnProperty.call(l,u)&&e(l,a,u)};Object.defineProperty(t,"__esModule",{value:!0}),t.DomHandler=void 0;var n=QC,i=dt;r(dt,t);var s={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},o=function(){function a(l,u,c){this.dom=[],this.root=new i.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,typeof u=="function"&&(c=u,u=s),typeof l=="object"&&(u=l,l=void 0),this.callback=l??null,this.options=u??s,this.elementCB=c??null}return a.prototype.onparserinit=function(l){this.parser=l},a.prototype.onreset=function(){this.dom=[],this.root=new i.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null},a.prototype.onend=function(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))},a.prototype.onerror=function(l){this.handleCallback(l)},a.prototype.onclosetag=function(){this.lastNode=null;var l=this.tagStack.pop();this.options.withEndIndices&&(l.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(l)},a.prototype.onopentag=function(l,u){var c=this.options.xmlMode?n.ElementType.Tag:void 0,h=new i.Element(l,u,void 0,c);this.addNode(h),this.tagStack.push(h)},a.prototype.ontext=function(l){var u=this.lastNode;if(u&&u.type===n.ElementType.Text)u.data+=l,this.options.withEndIndices&&(u.endIndex=this.parser.endIndex);else{var c=new i.Text(l);this.addNode(c),this.lastNode=c}},a.prototype.oncomment=function(l){if(this.lastNode&&this.lastNode.type===n.ElementType.Comment){this.lastNode.data+=l;return}var u=new i.Comment(l);this.addNode(u),this.lastNode=u},a.prototype.oncommentend=function(){this.lastNode=null},a.prototype.oncdatastart=function(){var l=new i.Text(""),u=new i.CDATA([l]);this.addNode(u),l.parent=u,this.lastNode=l},a.prototype.oncdataend=function(){this.lastNode=null},a.prototype.onprocessinginstruction=function(l,u){var c=new i.ProcessingInstruction(l,u);this.addNode(c)},a.prototype.handleCallback=function(l){if(typeof this.callback=="function")this.callback(l,this.dom);else if(l)throw l},a.prototype.addNode=function(l){var u=this.tagStack[this.tagStack.length-1],c=u.children[u.children.length-1];this.options.withStartIndices&&(l.startIndex=this.parser.startIndex),this.options.withEndIndices&&(l.endIndex=this.parser.endIndex),u.children.push(l),c&&(l.prev=c,c.next=l),l.parent=u,this.lastNode=null},a}();t.DomHandler=o,t.default=o})(YC);var ak="html",lk="head",R0="body",Woe=/<([a-zA-Z]+[0-9]?)/,uk=/<head[^]*>/i,ck=/<body[^]*>/i,Hy=function(){throw new Error("This browser does not support `document.implementation.createHTMLDocument`")},_2=function(){throw new Error("This browser does not support `DOMParser.prototype.parseFromString`")},dk=typeof window=="object"&&window.DOMParser;if(typeof dk=="function"){var Xoe=new dk,qoe="text/html";_2=function(t,e){return e&&(t="<"+e+">"+t+"</"+e+">"),Xoe.parseFromString(t,qoe)},Hy=_2}if(typeof document=="object"&&document.implementation){var P0=document.implementation.createHTMLDocument();Hy=function(t,e){if(e){var r=P0.documentElement.querySelector(e);return r.innerHTML=t,P0}return P0.documentElement.innerHTML=t,P0}}var p_=typeof document=="object"?document.createElement("template"):{},S2;p_.content&&(S2=function(t){return p_.innerHTML=t,p_.content.childNodes});function Yoe(t){var e,r=t.match(Woe);r&&r[1]&&(e=r[1].toLowerCase());var n,i,s;switch(e){case ak:return n=_2(t),uk.test(t)||(i=n.querySelector(lk),i&&i.parentNode.removeChild(i)),ck.test(t)||(i=n.querySelector(R0),i&&i.parentNode.removeChild(i)),n.querySelectorAll(ak);case lk:case R0:return n=Hy(t),s=n.querySelectorAll(e),ck.test(t)&&uk.test(t)?s[0].parentNode.childNodes:s;default:return S2?S2(t):(i=Hy(t,R0).querySelector(R0),i.childNodes)}}var Qoe=Yoe,JC={},S6={};S6.CASE_SENSITIVE_TAG_NAMES=["animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","linearGradient","radialGradient","textPath"];var X1=YC,Koe=S6,hk=Koe.CASE_SENSITIVE_TAG_NAMES,Zoe=X1.Comment,Joe=X1.Element,eae=X1.ProcessingInstruction,tae=X1.Text,E6={},m_;for(var g_=0,rae=hk.length;g_<rae;g_++)m_=hk[g_],E6[m_.toLowerCase()]=m_;function nae(t){return E6[t]}function T6(t){for(var e={},r,n=0,i=t.length;n<i;n++)r=t[n],e[r.name]=r.value;return e}function iae(t){t=t.toLowerCase();var e=nae(t);return e||t}function C6(t,e,r){e=e||null;for(var n=[],i,s=0,o=t.length;s<o;s++){var a=t[s],l;switch(a.nodeType){case 1:i=iae(a.nodeName),l=new Joe(i,T6(a.attributes)),l.children=C6(i==="template"?a.content.childNodes:a.childNodes,l);break;case 3:l=new tae(a.nodeValue);break;case 8:l=new Zoe(a.nodeValue);break;default:continue}var u=n[s-1]||null;u&&(u.next=l),l.parent=e,l.prev=u,l.next=null,n.push(l)}return r&&(l=new eae(r.substring(0,r.indexOf(" ")).toLowerCase(),r),l.next=n[0]||null,l.parent=e,n.unshift(l),n[1]&&(n[1].prev=n[0])),n}JC.formatAttributes=T6;JC.formatDOM=C6;var sae=Qoe,oae=JC,aae=oae.formatDOM,lae=/<(![a-zA-Z\s]+)>/;function uae(t){if(typeof t!="string")throw new TypeError("First argument must be a string");if(t==="")return[];var e=t.match(lae),r;return e&&e[1]&&(r=e[1]),aae(sae(t),null,r)}var cae=uae,Zi={},q1={},dae=0;q1.SAME=dae;var hae=1;q1.CAMELCASE=hae;q1.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":"acceptCharset",accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:"className",classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:"htmlFor",form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":"httpEquiv",icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":"accentHeight",accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":"alignmentBaseline",allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":"arabicForm",ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":"baselineShift",baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":"capHeight",clip:0,clipPath:1,"clip-path":"clipPath",clipPathUnits:1,clipRule:1,"clip-rule":"clipRule",color:0,colorInterpolation:1,"color-interpolation":"colorInterpolation",colorInterpolationFilters:1,"color-interpolation-filters":"colorInterpolationFilters",colorProfile:1,"color-profile":"colorProfile",colorRendering:1,"color-rendering":"colorRendering",contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":"dominantBaseline",dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":"enableBackground",end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":"fillOpacity",fillRule:1,"fill-rule":"fillRule",filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":"floodOpacity",floodColor:1,"flood-color":"floodColor",focusable:0,fontFamily:1,"font-family":"fontFamily",fontSize:1,"font-size":"fontSize",fontSizeAdjust:1,"font-size-adjust":"fontSizeAdjust",fontStretch:1,"font-stretch":"fontStretch",fontStyle:1,"font-style":"fontStyle",fontVariant:1,"font-variant":"fontVariant",fontWeight:1,"font-weight":"fontWeight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":"glyphName",glyphOrientationHorizontal:1,"glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphOrientationVertical:1,"glyph-orientation-vertical":"glyphOrientationVertical",glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":"horizAdvX",horizOriginX:1,"horiz-origin-x":"horizOriginX",ideographic:0,imageRendering:1,"image-rendering":"imageRendering",in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":"letterSpacing",lightingColor:1,"lighting-color":"lightingColor",limitingConeAngle:1,local:0,markerEnd:1,"marker-end":"markerEnd",markerHeight:1,markerMid:1,"marker-mid":"markerMid",markerStart:1,"marker-start":"markerStart",markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":"overlinePosition",overlineThickness:1,"overline-thickness":"overlineThickness",paintOrder:1,"paint-order":"paintOrder",panose1:0,"panose-1":"panose1",pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":"pointerEvents",points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":"renderingIntent",repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":"shapeRendering",slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":"stopColor",stopOpacity:1,"stop-opacity":"stopOpacity",strikethroughPosition:1,"strikethrough-position":"strikethroughPosition",strikethroughThickness:1,"strikethrough-thickness":"strikethroughThickness",string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":"strokeDasharray",strokeDashoffset:1,"stroke-dashoffset":"strokeDashoffset",strokeLinecap:1,"stroke-linecap":"strokeLinecap",strokeLinejoin:1,"stroke-linejoin":"strokeLinejoin",strokeMiterlimit:1,"stroke-miterlimit":"strokeMiterlimit",strokeWidth:1,"stroke-width":"strokeWidth",strokeOpacity:1,"stroke-opacity":"strokeOpacity",suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":"textAnchor",textDecoration:1,"text-decoration":"textDecoration",textLength:1,textRendering:1,"text-rendering":"textRendering",to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":"underlinePosition",underlineThickness:1,"underline-thickness":"underlineThickness",unicode:0,unicodeBidi:1,"unicode-bidi":"unicodeBidi",unicodeRange:1,"unicode-range":"unicodeRange",unitsPerEm:1,"units-per-em":"unitsPerEm",unselectable:0,vAlphabetic:1,"v-alphabetic":"vAlphabetic",values:0,vectorEffect:1,"vector-effect":"vectorEffect",version:0,vertAdvY:1,"vert-adv-y":"vertAdvY",vertOriginX:1,"vert-origin-x":"vertOriginX",vertOriginY:1,"vert-origin-y":"vertOriginY",vHanging:1,"v-hanging":"vHanging",vIdeographic:1,"v-ideographic":"vIdeographic",viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":"vMathematical",vocab:0,widths:0,wordSpacing:1,"word-spacing":"wordSpacing",writingMode:1,"writing-mode":"writingMode",x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":"xHeight",xlinkActuate:1,"xlink:actuate":"xlinkActuate",xlinkArcrole:1,"xlink:arcrole":"xlinkArcrole",xlinkHref:1,"xlink:href":"xlinkHref",xlinkRole:1,"xlink:role":"xlinkRole",xlinkShow:1,"xlink:show":"xlinkShow",xlinkTitle:1,"xlink:title":"xlinkTitle",xlinkType:1,"xlink:type":"xlinkType",xmlBase:1,"xml:base":"xmlBase",xmlLang:1,"xml:lang":"xmlLang",xmlns:0,"xml:space":"xmlSpace",xmlnsXlink:1,"xmlns:xlink":"xmlnsXlink",xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1};Object.defineProperty(Zi,"__esModule",{value:!0});function fae(t,e){return pae(t)||mae(t,e)||gae(t,e)||vae()}function pae(t){if(Array.isArray(t))return t}function mae(t,e){var r=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(r!=null){var n=[],i=!0,s=!1,o,a;try{for(r=r.call(t);!(i=(o=r.next()).done)&&(n.push(o.value),!(e&&n.length===e));i=!0);}catch(l){s=!0,a=l}finally{try{!i&&r.return!=null&&r.return()}finally{if(s)throw a}}return n}}function gae(t,e){if(t){if(typeof t=="string")return fk(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);if(r==="Object"&&t.constructor&&(r=t.constructor.name),r==="Map"||r==="Set")return Array.from(t);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return fk(t,e)}}function fk(t,e){(e==null||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function vae(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
1389
1389
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var A6=0,Gl=1,Y1=2,Q1=3,eA=4,R6=5,P6=6;function yae(t){return Zr.hasOwnProperty(t)?Zr[t]:null}function In(t,e,r,n,i,s,o){this.acceptsBooleans=e===Y1||e===Q1||e===eA,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=t,this.type=e,this.sanitizeURL=s,this.removeEmptyString=o}var Zr={},xae=["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"];xae.forEach(function(t){Zr[t]=new In(t,A6,!1,t,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(t){var e=fae(t,2),r=e[0],n=e[1];Zr[r]=new In(r,Gl,!1,n,null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(t){Zr[t]=new In(t,Y1,!1,t.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(t){Zr[t]=new In(t,Y1,!1,t,null,!1,!1)});["allowFullScreen","async","autoFocus","autoPlay","controls","default","defer","disabled","disablePictureInPicture","disableRemotePlayback","formNoValidate","hidden","loop","noModule","noValidate","open","playsInline","readOnly","required","reversed","scoped","seamless","itemScope"].forEach(function(t){Zr[t]=new In(t,Q1,!1,t.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(t){Zr[t]=new In(t,Q1,!0,t,null,!1,!1)});["capture","download"].forEach(function(t){Zr[t]=new In(t,eA,!1,t,null,!1,!1)});["cols","rows","size","span"].forEach(function(t){Zr[t]=new In(t,P6,!1,t,null,!1,!1)});["rowSpan","start"].forEach(function(t){Zr[t]=new In(t,R6,!1,t.toLowerCase(),null,!1,!1)});var tA=/[\-\:]([a-z])/g,rA=function(e){return e[1].toUpperCase()};["accent-height","alignment-baseline","arabic-form","baseline-shift","cap-height","clip-path","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","dominant-baseline","enable-background","fill-opacity","fill-rule","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","horiz-adv-x","horiz-origin-x","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","overline-position","overline-thickness","paint-order","panose-1","pointer-events","rendering-intent","shape-rendering","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-rendering","underline-position","underline-thickness","unicode-bidi","unicode-range","units-per-em","v-alphabetic","v-hanging","v-ideographic","v-mathematical","vector-effect","vert-adv-y","vert-origin-x","vert-origin-y","word-spacing","writing-mode","xmlns:xlink","x-height"].forEach(function(t){var e=t.replace(tA,rA);Zr[e]=new In(e,Gl,!1,t,null,!1,!1)});["xlink:actuate","xlink:arcrole","xlink:role","xlink:show","xlink:title","xlink:type"].forEach(function(t){var e=t.replace(tA,rA);Zr[e]=new In(e,Gl,!1,t,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(t){var e=t.replace(tA,rA);Zr[e]=new In(e,Gl,!1,t,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(t){Zr[t]=new In(t,Gl,!1,t.toLowerCase(),null,!1,!1)});var bae="xlinkHref";Zr[bae]=new In("xlinkHref",Gl,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(t){Zr[t]=new In(t,Gl,!1,t.toLowerCase(),null,!0,!0)});var nA=q1,wae=nA.CAMELCASE,_ae=nA.SAME,pk=nA.possibleStandardNames,Sae=":A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",Eae=Sae+"\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",Tae=RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+Eae+"]*$")),Cae=Object.keys(pk).reduce(function(t,e){var r=pk[e];return r===_ae?t[e]=e:r===wae?t[e.toLowerCase()]=e:t[e]=r,t},{});Zi.BOOLEAN=Q1;Zi.BOOLEANISH_STRING=Y1;Zi.NUMERIC=R6;Zi.OVERLOADED_BOOLEAN=eA;Zi.POSITIVE_NUMERIC=P6;Zi.RESERVED=A6;Zi.STRING=Gl;Zi.getPropertyInfo=yae;Zi.isCustomAttribute=Tae;Zi.possibleStandardNames=Cae;var I6={},iA={exports:{}},mk=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,Aae=/\n/g,Rae=/^\s*/,Pae=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,Iae=/^:\s*/,Mae=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,kae=/^[;\s]*/,Oae=/^\s+|\s+$/g,Dae=`
|
|
1390
|
-
`,gk="/",vk="*",Eu="",Nae="comment",Lae="declaration",Fae=function(t,e){if(typeof t!="string")throw new TypeError("First argument must be a string");if(!t)return[];e=e||{};var r=1,n=1;function i(y){var v=y.match(Aae);v&&(r+=v.length);var x=y.lastIndexOf(Dae);n=~x?y.length-x:n+y.length}function s(){var y={line:r,column:n};return function(v){return v.position=new o(y),u(),v}}function o(y){this.start=y,this.end={line:r,column:n},this.source=e.source}o.prototype.content=t;function a(y){var v=new Error(e.source+":"+r+":"+n+": "+y);if(v.reason=y,v.filename=e.source,v.line=r,v.column=n,v.source=t,!e.silent)throw v}function l(y){var v=y.exec(t);if(v){var x=v[0];return i(x),t=t.slice(x.length),v}}function u(){l(Rae)}function c(y){var v;for(y=y||[];v=h();)v!==!1&&y.push(v);return y}function h(){var y=s();if(!(gk!=t.charAt(0)||vk!=t.charAt(1))){for(var v=2;Eu!=t.charAt(v)&&(vk!=t.charAt(v)||gk!=t.charAt(v+1));)++v;if(v+=2,Eu===t.charAt(v-1))return a("End of comment missing");var x=t.slice(2,v-2);return n+=2,i(x),t=t.slice(v),n+=2,y({type:Nae,comment:x})}}function f(){var y=s(),v=l(Pae);if(v){if(h(),!l(Iae))return a("property missing ':'");var x=l(Mae),b=y({type:Lae,property:yk(v[0].replace(mk,Eu)),value:x?yk(x[0].replace(mk,Eu)):Eu});return l(kae),b}}function m(){var y=[];c(y);for(var v;v=f();)v!==!1&&(y.push(v),c(y));return y}return u(),m()};function yk(t){return t?t.replace(Oae,Eu):Eu}var jae=Fae;function M6(t,e){var r=null;if(!t||typeof t!="string")return r;for(var n,i=jae(t),s=typeof e=="function",o,a,l=0,u=i.length;l<u;l++)n=i[l],o=n.property,a=n.value,s?e(o,a,n):a&&(r||(r={}),r[o]=a);return r}iA.exports=M6;iA.exports.default=M6;var Bae=iA.exports,K1={};K1.__esModule=!0;K1.camelCase=void 0;var Uae=/^--[a-zA-Z0-9-]+$/,$ae=/-([a-z])/g,zae=/^[^-]+$/,Hae=/^-(webkit|moz|ms|o|khtml)-/,Vae=/^-(ms)-/,Gae=function(t){return!t||zae.test(t)||Uae.test(t)},Wae=function(t,e){return e.toUpperCase()},xk=function(t,e){return"".concat(e,"-")},Xae=function(t,e){return e===void 0&&(e={}),Gae(t)?t:(t=t.toLowerCase(),e.reactCompat?t=t.replace(Vae,xk):t=t.replace(Hae,xk),t.replace($ae,Wae))};K1.camelCase=Xae;(function(t){var e=rr&&rr.__importDefault||function(s){return s&&s.__esModule?s:{default:s}};t.__esModule=!0;var r=e(Bae),n=K1;function i(s,o){var a={};return!s||typeof s!="string"||(0,r.default)(s,function(l,u){l&&u&&(a[(0,n.camelCase)(l,o)]=u)}),a}t.default=i})(I6);var qae=T,Yae=I6.default;function Qae(t,e){if(!t||typeof t!="object")throw new TypeError("First argument must be an object");var r=typeof e=="function",n={},i={};for(var s in t){var o=t[s];if(r&&(n=e(s,o),n&&n.length===2)){i[n[0]]=n[1];continue}typeof o=="string"&&(i[o]=s)}return i}var Kae=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);function Zae(t,e){return t.indexOf("-")===-1?e&&typeof e.is=="string":!Kae.has(t)}var Jae={reactCompat:!0};function ele(t,e){if(t!=null)try{e.style=Yae(t,Jae)}catch{e.style={}}}var tle=qae.version.split(".")[0]>=16,k6=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);function rle(t){return!k6.has(t.name)}function nle(t){return t}var O6={PRESERVE_CUSTOM_ATTRIBUTES:tle,ELEMENTS_WITH_NO_TEXT_CHILDREN:k6,invertObject:Qae,isCustomComponent:Zae,setStyleProp:ele,canTextBeChildOfNode:rle,returnFirstArg:nle},Mf=Zi,bk=O6,ile=["checked","value"],sle=["input","select","textarea"],ole={reset:!0,submit:!0},D6=function(e,r){e=e||{};var n,i,s,o,a,l={},u=e.type&&ole[e.type];for(n in e){if(s=e[n],Mf.isCustomAttribute(n)){l[n]=s;continue}if(i=n.toLowerCase(),o=wk(i),o){switch(a=Mf.getPropertyInfo(o),ile.indexOf(o)!==-1&&sle.indexOf(r)!==-1&&!u&&(o=wk("default"+i)),l[o]=s,a&&a.type){case Mf.BOOLEAN:l[o]=!0;break;case Mf.OVERLOADED_BOOLEAN:s===""&&(l[o]=!0);break}continue}bk.PRESERVE_CUSTOM_ATTRIBUTES&&(l[n]=s)}return bk.setStyleProp(e.style,l),l};function wk(t){return Mf.possibleStandardNames[t]}var ale=T,lle=D6,Kp=O6,ule=Kp.setStyleProp,cle=Kp.canTextBeChildOfNode;function N6(t,e){e=e||{};for(var r=e.library||ale,n=r.cloneElement,i=r.createElement,s=r.isValidElement,o=[],a,l,u=typeof e.replace=="function",c=e.transform||Kp.returnFirstArg,h,f,m,y=e.trim,v=0,x=t.length;v<x;v++){if(a=t[v],u&&(h=e.replace(a),s(h))){x>1&&(h=n(h,{key:h.key||v})),o.push(c(h,a,v));continue}if(a.type==="text"){if(l=!a.data.trim().length,l&&a.parent&&!cle(a.parent)||y&&l)continue;o.push(c(a.data,a,v));continue}switch(f=a.attribs,dle(a)?ule(f.style,f):f&&(f=lle(f,a.name)),m=null,a.type){case"script":case"style":a.children[0]&&(f.dangerouslySetInnerHTML={__html:a.children[0].data});break;case"tag":a.name==="textarea"&&a.children[0]?f.defaultValue=a.children[0].data:a.children&&a.children.length&&(m=N6(a.children,e));break;default:continue}x>1&&(f.key=v),o.push(c(i(a.name,f,m),a,v))}return o.length===1?o[0]:o}function dle(t){return Kp.PRESERVE_CUSTOM_ATTRIBUTES&&t.type==="tag"&&Kp.isCustomComponent(t.name,t.attribs)}var hle=N6,Z1=YC,cd=cae,fle=D6,L6=hle;cd=typeof cd.default=="function"?cd.default:cd;var ple={lowerCaseAttributeNames:!1};function Ao(t,e){if(typeof t!="string")throw new TypeError("First argument must be a string");return t===""?[]:(e=e||{},L6(cd(t,e.htmlparser2||ple),e))}Ao.domToReact=L6;Ao.htmlToDOM=cd;Ao.attributesToProps=fle;Ao.Comment=Z1.Comment;Ao.Element=Z1.Element;Ao.ProcessingInstruction=Z1.ProcessingInstruction;Ao.Text=Z1.Text;var mle=Ao;Ao.default=Ao;const Wl=Po(mle);var I0=Wl.domToReact;Wl.htmlToDOM;var v_=Wl.attributesToProps;Wl.Comment;Wl.Element;Wl.ProcessingInstruction;Wl.Text;var gle=Object.defineProperty,vle=(t,e,r)=>e in t?gle(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,ff=(t,e,r)=>(vle(t,typeof e!="symbol"?e+"":e,r),r);const yle=async t=>await Me.conf().getPreference(t),xle=async t=>await Me.conf().savePreference(t,JSON.stringify({key:!1})),ble=t=>{const[e,r]=T.useState(!0),[n,i]=T.useState(!1);return T.useEffect(()=>{(async()=>{const s=await yle(t);if(s){const{key:o}=s;i(o);return}i(!0)})()},[t]),{isOpen:e,setIsOpen:r,isOnboarding:n,handleSavePreference:async()=>{await xle(t),r(!1)}}},wle=({id:t,items:e,modalOptions:r})=>{const[n]=Pn(),[i,s]=T.useState(),[o,a]=T.useState(0),{isOpen:l,isOnboarding:u,setIsOpen:c,handleSavePreference:h}=ble(t);T.useEffect(()=>{const b=document.createElement("link");return b.href="https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.css",b.rel="stylesheet",b.type="text/css",document.head.appendChild(b),()=>{document.head.removeChild(b)}},[]);const{t:f}=we(),{title:m,prevText:y,closeText:v,nextText:x}=r;return u?mr.createPortal(g.jsxs(Ye,{id:"onboarding-modal",size:"md",isOpen:l,focusId:"nextButtonId",onModalClose:()=>c(!1),children:[g.jsx(Ye.Header,{onModalClose:()=>c(!1),children:f(m||"explorer.modal.onboarding.trash.title")}),g.jsx(Ye.Body,{children:g.jsx(o6,{modules:[cse],onSwiper:b=>{s(b)},onSlideChange:b=>{a(b.progress)},pagination:{clickable:!0},children:e.map((b,_)=>g.jsxs(a6,{children:[g.jsx(wo,{width:"270",height:"140",className:"mx-auto my-12",loading:"lazy",src:`${n}/${b.src}`,alt:f(b.alt)}),g.jsx("p",{children:f(b.text)})]},_))})}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{type:"button",color:"tertiary",variant:"ghost",onClick:()=>c(!1),children:f("explorer.modal.onboarding.trash.later")}),o>0&&g.jsx(it,{type:"button",color:"primary",variant:"outline",onClick:()=>i.slidePrev(),children:f(y||"explorer.modal.onboarding.trash.prev")}),o<1&&g.jsx(it,{id:"nextButtonId",type:"button",color:"primary",variant:"filled",onClick:()=>i.slideNext(),children:f(x||"explorer.modal.onboarding.trash.next")}),o===1&&g.jsx(it,{type:"button",color:"primary",variant:"filled",onClick:h,children:f(v||"explorer.modal.onboarding.trash.close")})]})]}),document.getElementById("portal")):null},_le=wle,F6=T.createContext(null),bh=()=>{const t=T.useContext(F6);if(!t)throw new Error("Cannot be rendered outside the Dropdown Component");return t},Sle=T.forwardRef(({label:t,disabled:e=!1,checked:r=!1,indeterminate:n=!1,...i},s)=>{const o=T.useRef(null);T.useImperativeHandle(s,()=>({...o.current})),T.useEffect(()=>{o.current.indeterminate=n},[o,n]);const a=T.useId(),l={type:"checkbox",checked:r,disabled:e,ref:o,className:Re(i.className,"form-check-input c-pointer"),id:a},u={...i,...l};return g.jsxs("div",{className:"form-check d-flex align-items-center gap-8",children:[g.jsx("input",{...u}),t&&g.jsx("label",{className:"form-check-label",htmlFor:u.id,children:t})]})}),Tm=Sle,Ele=({children:t,value:e,model:r,onChange:n})=>{const{itemProps:i,itemRefs:s,isFocused:o}=bh(),{onMenuItemKeyDown:a,onMenuItemMouseEnter:l}=i,u=T.useId(),c=r.includes(e),h={value:e,model:r,checked:c,readOnly:!0},f=Re("dropdown-item c-pointer",{focus:o===u});return g.jsx("div",{id:u,ref:m=>s.current[u]=m,role:"menuitemcheckbox","aria-checked":c,onMouseUp:()=>n(e),onKeyDown:m=>a(m,()=>n(e)),onMouseEnter:l,tabIndex:c?0:-1,className:f,children:g.jsxs("div",{className:"d-flex gap-8 align-items-center justify-content-between position-relative",children:[t,g.jsx(Tm,{...h})]})})},Tle=Ele,Cle=({type:t="action",icon:e,onClick:r,children:n,className:i,...s})=>{const{itemProps:o,itemRefs:a,isFocused:l}=bh(),{onMenuItemKeyDown:u,onMenuItemMouseEnter:c,onMenuItemClick:h}=o,f=v=>{r==null||r(v),t==="action"&&(h(),v.stopPropagation())},m=T.useId(),y=Re("dropdown-item",{focus:l===m},i);return g.jsx("div",{id:m,role:"menuitem",ref:v=>a.current[m]=v,tabIndex:l===m?0:-1,className:y,"aria-current":l===m,onClick:f,onMouseEnter:c,onKeyDown:v=>u(v,r),...s,children:g.jsxs("div",{className:"d-flex gap-8 align-items-center",children:[e,n]})})},Ale=Cle,Rle=T.forwardRef(({children:t,block:e,unstyled:r,...n},i)=>{const{menuProps:s,visible:o}=bh(),a=Re({"w-100":e,"bg-white shadow rounded-4 p-8":!r},s.className,n.className),l={...s,...n,className:a};return o?g.jsx("div",{ref:i,...l,children:t}):null}),Ple=Rle,Ile=T.forwardRef(({label:t,children:e},r)=>g.jsxs("div",{ref:r,role:"group",children:[g.jsx("span",{className:"small px-4",children:g.jsx("strong",{children:t})}),e]})),Mle=Ile,kle=T.forwardRef(({model:t,icon:e,label:r=!1,disabled:n=!1,checked:i,...s},o)=>{const a=T.useId(),l={type:"radio",checked:i,disabled:n,ref:o,className:Re(s.className,"form-check-input c-pointer",e&&"d-none"),id:a},u={...s,...l};return g.jsxs("div",{className:Re("form-check d-flex align-items-center gap-8",e&&"ps-0"),children:[g.jsx("input",{...u}),e&&g.jsx("label",{htmlFor:u.id,className:Re("c-pointer",t!==s.value&&"text-muted"),children:e}),!e&&r&&g.jsx("label",{className:"form-check-label",htmlFor:u.id,children:r})]})}),E2=kle,Ole=({children:t,value:e,model:r,onChange:n})=>{const{itemProps:i,itemRefs:s,isFocused:o}=bh(),{onMenuItemKeyDown:a,onMenuItemMouseEnter:l}=i,u=T.useId(),c={value:e,model:r,checked:e===r,readOnly:!0},h=Re("dropdown-item c-pointer",{focus:o===u});return g.jsx("div",{id:u,ref:f=>s.current[u]=f,role:"menuitemradio","aria-checked":e===r,onMouseUp:()=>n(e),onKeyDown:f=>a(f,()=>n(e)),onMouseEnter:l,tabIndex:e===r?0:-1,className:h,children:g.jsxs("div",{className:"d-flex gap-8 align-items-center justify-content-between position-relative",children:[t,g.jsx(E2,{...c,className:"position-absolute start-0 end-0 top-0 bottom-0 opacity-0"})]})})},Dle=Ole,Nle=()=>g.jsx("div",{role:"separator",className:"px-4",children:g.jsx("hr",{className:"m-0"})}),Lle=Nle,Fle=T.forwardRef(({label:t,icon:e,variant:r,disabled:n=!1,size:i,badgeContent:s,hideCarret:o=!1,...a},l)=>{const{triggerProps:u,block:c}=bh(),h=Re("dropdown-toggle ",i,r,{"w-100":c},u.className,a.className),f={...u,...a,className:h};return g.jsxs("button",{ref:l,type:"button",disabled:n,...f,children:[e,t,s?g.jsx("span",{className:"badge text-bg-secondary rounded-pill",children:s}):!o&&g.jsx(vz,{width:16,height:16,className:"dropdown-toggle-caret"})]})}),jle=Fle;function j6(){return{xs:$c("only screen and (min-width: 0)"),sm:$c("only screen and (min-width: 375px)"),md:$c("only screen and (min-width: 768px)"),lg:$c("only screen and (min-width: 1024px)"),xl:$c("only screen and (min-width: 1280px)"),xxl:$c("only screen and (min-width: 1400px)")}}function B6(t){var e,r,n;const i=new Hq(t),s=i.getOS(),o=i.getDevice(),a=i.getBrowser(),l=((e=o.model)==null?void 0:e.indexOf("iPhone"))!=-1,u=((r=o.model)==null?void 0:r.indexOf("iPod"))!=-1,c=((n=o.model)==null?void 0:n.indexOf("iPad"))!=-1;return{os:s,device:o,browser:a,isIphone:l,isIpod:u,isIpad:c}}const _k=["mousedown","touchstart"];function U6(t,e,r){const n=T.useRef();return T.useEffect(()=>{const i=s=>{const{target:o}=s??{};if(Array.isArray(r)){const a=(o==null?void 0:o.hasAttribute("data-ignore-outside-clicks"))||!document.body.contains(o)&&o.tagName!=="HTML";r.every(l=>!!l&&!s.composedPath().includes(l))&&!a&&t()}else n.current&&!n.current.contains(o)&&t()};return _k.forEach(s=>{document.addEventListener(s,i)}),()=>{_k.forEach(s=>{document.removeEventListener(s,i)})}},[n,t,r,e]),n}function sA(t,e){const[r,n]=T.useState(t);return T.useEffect(()=>{const i=setTimeout(()=>{n(t)},e||500);return()=>{clearTimeout(i)}},[t,e]),r}function T2(...t){return e=>{Ble(e,...t)}}function Ble(t,...e){e.forEach(r=>{typeof r=="function"?r(t):r!=null&&(r.current=t)})}const Ule=(t,e,r=!1)=>{const n=T.useId(),[i,s]=T.useState(!1),[o,a]=T.useState(-1),[l,u]=T.useState(null),{refs:c,floatingStyles:h,context:f}=QH({placement:t,open:i,onOpenChange:s,whileElementsMounted:AH,middleware:[OH(4),NH({apply({rects:j,elements:H}){H.floating.style.minWidth=`${j.reference.width}px`}}),DH({padding:0})]});GH(f,{enabled:r,delay:{open:200},handleClose:ZH()});const m=T.useRef(null),y=T.useRef(null),v=T.useRef({});T.useEffect(()=>{i?m.current&&(m.current.focus(),a(0)):(a(-1),v.current={})},[i]),T.useEffect(()=>{if(o!==-1){const j=Object.values(v.current)[o];if(j){const H=j.getAttribute("id");u(H),j.focus()}}},[o]);const x=()=>{const j=Object.values(v.current).length;a(H=>(H+1)%j)},b=()=>{const j=Object.values(v.current).length;a(H=>(H-1+j)%j)},_=()=>{a(0)},w=()=>{const j=Object.values(v.current).length;a(j-1)},E=T.useCallback(()=>{s(!0)},[]),A=T.useCallback(()=>{y.current&&(y.current.focus({preventScroll:!0}),s(!1))},[]),P=(j,H)=>{j&&(H.stopPropagation(),H.preventDefault())},I=T.useCallback(j=>{let H=!1;switch(j.code){case" ":case"Space":case"Enter":case"ArrowDown":case"Down":E(),H=!0;break;case"Esc":case"Escape":A(),H=!0;break;case"Up":case"ArrowUp":E(),H=!0;break}e==null||e(j),P(H,j)},[A,E]),M=j=>{const H=Object.values(v.current).findIndex(F=>F.id===j.currentTarget.getAttribute("id"));a(H)},N=T.useCallback((j,H)=>{let F=!1;if(j.shiftKey)j.key==="Tab"&&(A(),F=!0);else{switch(j.code){case"Escape":A();break;case" ":case"Enter":o!==-1&&(Object.values(v.current)[o].getAttribute("role")==="menuitem"&&y.current&&(y.current.focus(),s(!1)),H==null||H()),F=!0;break;case"ArrowDown":case"Down":x(),F=!0;break;case"ArrowUp":case"Up":b(),F=!0;break;case"Home":_(),F=!0;break;case"End":w(),F=!0;break}P(F,j)}},[o,A]),z=T.useCallback(j=>{s(i!==!0),j.stopPropagation(),j.preventDefault()},[i]);return{isFocused:l,visible:i,itemRefs:v,triggerRef:y,menuRef:m,triggerProps:{ref:T2(y,c.setReference),id:`dropdown-toggle-${n}`,"aria-haspopup":"menu","aria-controls":`dropdown-${n}`,"aria-expanded":!!i,className:`${i?"selected":""}`,onClick:z,onKeyDown:I,"aria-activedescendant":l},menuProps:{ref:T2(m,c.setFloating),className:"dropdown-menu","aria-labelledby":`dropdown-toggle-${n}`,style:{...h}},itemProps:{onMenuItemMouseEnter:M,onMenuItemClick:A,onMenuItemKeyDown:N},setVisible:s}},$le=Ule,zle=t=>{const[e,r]=T.useState(!1),[n,i]=T.useState([]),s=T.useRef(null),o=v=>{c([v])},a=v=>{i(x=>x.filter(b=>b.name!==v.name))},l=(v,x)=>{i(b=>{if(0<=v&&v<b.length){const _=b.slice(0,v),w=v===b.length-1?[]:b.slice(v+1);return[..._,x,...w]}return b})},u=v=>{var x;let b=v;if((x=s.current)!=null&&x.accept){const _=s.current.accept.split(",").map(A=>A.trim().toLowerCase()),w=_.filter(A=>A.startsWith(".")),E=_.filter(A=>!A.startsWith(".")).map(A=>A.replace("*",""));b=[],v.forEach(A=>{const P=A.name.toLowerCase();(w.some(I=>P.endsWith(I))||E.some(I=>A.type.includes(I)))&&b.push(A)})}return b},c=v=>{let x=v.map(b=>new File([b],b.name.replace(/[!:,;="']/g,""),{type:b.type}));t!=null&&t.forceFilters?(x=u(x),x&&x.length&&i(b=>[...b,...x])):i(b=>[...b,...v])},h=()=>{i([])},f=v=>{const x=v.target.files;x&&c([...x])},m=v=>{v.preventDefault(),v.stopPropagation(),r(!0)},y=v=>{v.preventDefault(),v.stopPropagation(),r(!1)};return{inputRef:s,files:n,dragging:e,handleDragging:m,handleDragLeave:y,handleDrop:v=>{var x;y(v);const b=(x=v.dataTransfer)==null?void 0:x.files;b&&(c([...b]),s!=null&&s.current&&(s.current.files=b))},replaceFileAt:l,deleteFile:a,addFile:o,addFiles:c,cleanFiles:h,handleOnChange:f}},Hle=zle;function $6(){const[t,e]=T.useState(!1),r=T.useRef(null),n=()=>{e(!0)},i=()=>{e(!1)};return T.useEffect(()=>{const s=r.current;if(s)return s.addEventListener("mouseover",n),s.addEventListener("mouseout",i),()=>{s.removeEventListener("mouseover",n),s.removeEventListener("mouseout",i)}},[r]),[r,t]}function Vle(t,e){const r=T.useCallback(({code:n})=>{e.includes(n)&&t()},[t,e]);T.useEffect(()=>(window.addEventListener("keydown",r),()=>{window.removeEventListener("keydown",r)}),[r])}function z6(){const t=document.querySelector("html");return()=>{t&&t.scrollIntoView()}}const Gle=T.forwardRef(({icon:t,className:e,...r},n)=>{const i={...r,className:Re("btn-icon btn-sm",e)};return g.jsx(it,{ref:n,...i,children:t})}),Ro=Gle,Wle=T.forwardRef(({icon:t=g.jsx(AS,{}),onClick:e,className:r,...n},i)=>{const s=Re("btn-search",r);return g.jsx(Ro,{ref:i,className:s,icon:t,onClick:e,...n})}),oA=Wle,Xle=T.forwardRef(({type:t="success",className:e="",children:r,button:n,isDismissible:i=!1,isToast:s=!1,isConfirm:o=!1,position:a="none",autoClose:l=!1,autoCloseDelay:u=3e3,onClose:c,onVisibilityChange:h},f)=>{const[m,y]=T.useState(!0),v=T.useRef(null),{t:x}=we(),b=T.useCallback(()=>{y(!1),c==null||c()},[c]);T.useImperativeHandle(f,()=>({show:_,hide:b,...v.current})),T.useLayoutEffect(()=>{h==null||h(m)},[m,h]),T.useEffect(()=>{l&&m&&setTimeout(()=>{b()},u)},[l,u,b,m]);const _=()=>{y(!0)},w={success:{icon:g.jsx(WN,{}),classModifier:"alert-success"},warning:{icon:g.jsx(R$,{}),classModifier:"alert-warning"},info:{icon:g.jsx(BN,{}),classModifier:"alert-info"},danger:{icon:g.jsx(Q$,{}),classModifier:"alert-danger"}},E={"is-dismissible":i,"is-toast ":s},A={"is-confirm":o},P=Re("alert gap-12",w[t].classModifier,E,A,a,e);return g.jsx(g.Fragment,{children:m?g.jsxs("div",{ref:v,className:P,role:"alert",children:[!o&&w[t].icon,g.jsx("div",{className:"alert-content small",children:r}),n&&g.jsxs("div",{className:"ms-12",children:[n," ",o&&g.jsx(it,{onClick:b,children:x("close")})]}),(i||o)&&g.jsx("div",{className:"btn-close-container",children:g.jsx("button",{type:"button",className:"btn-close","data-bs-dismiss":"alert","aria-label":x("close"),onClick:b})}),l&&g.jsx("div",{className:"alert-progress",style:{transform:"scaleX(0)"}})]}):null})}),ta=Xle,M0="top-right";function en(){return{success:(t,e)=>lu.custom(g.jsx(ta,{type:"success",isToast:!0,isDismissible:e==null?void 0:e.isDismissible,className:"mb-12",children:t}),{id:e==null?void 0:e.id,duration:e==null?void 0:e.duration,position:(e==null?void 0:e.position)??M0}),error:(t,e)=>lu.custom(g.jsx(ta,{type:"danger",isToast:!0,isDismissible:e==null?void 0:e.isDismissible,className:"mb-12",children:t}),{id:e==null?void 0:e.id,duration:e==null?void 0:e.duration,position:(e==null?void 0:e.position)??M0}),info:(t,e)=>lu.custom(g.jsx(ta,{type:"info",isToast:!0,isDismissible:e==null?void 0:e.isDismissible,className:"mb-12",children:t}),{id:e==null?void 0:e.id,duration:e==null?void 0:e.duration,position:(e==null?void 0:e.position)??M0}),warning:(t,e)=>lu.custom(g.jsx(ta,{type:"warning",isToast:!0,isDismissible:e==null?void 0:e.isDismissible,className:"mb-12",children:t}),{id:e==null?void 0:e.id,duration:e==null?void 0:e.duration,position:(e==null?void 0:e.position)??M0}),loading:lu.loading,dismiss:t=>lu.dismiss(t),remove:t=>lu.remove(t)}}function Cm(t=!1){const[e,r]=T.useState(t),n=T.useCallback(()=>{r(i=>!i)},[]);return[e,n]}function qle(){const t=T.useRef(null),e='button:not([disabled]), [href], input, select, textarea, [tabindex]:not([tabindex="-1"])';return T.useEffect(()=>{const r=t.current,n=r.querySelectorAll(e)[0],i=r.querySelectorAll(e),s=t&&(i==null?void 0:i[i.length-1]),o=a=>{a.key==="Tab"&&(a.shiftKey?document.activeElement===n&&(s.focus(),a.preventDefault()):document.activeElement===s&&(n.focus(),a.preventDefault()))};if(r)return r.addEventListener("keydown",o),()=>{r.removeEventListener("keydown",o)}},[]),t}const Yle=({children:t,block:e,overflow:r=!0,placement:n="bottom-start",extraTriggerKeyDownHandler:i,onToggle:s,isTriggerHovered:o=!1})=>{const{visible:a,isFocused:l,triggerProps:u,menuProps:c,itemProps:h,itemRefs:f,setVisible:m}=$le(n,i,o),y=U6(()=>{m(!1)}),v=T.useMemo(()=>({visible:a,isFocused:l,triggerProps:u,menuProps:c,itemProps:h,itemRefs:f,block:e,setVisible:m}),[a,l,u,c,h,f,e,m]),x=Re("dropdown",{"w-100":e,overflow:r});return T.useEffect(()=>{s==null||s(a)},[a]),g.jsx(F6.Provider,{value:v,children:g.jsx("div",{ref:y,className:x,children:typeof t=="function"?t(u,f,m):t})})},Qle=Object.assign(Yle,{Trigger:jle,Menu:Ple,Item:Ale,Separator:Lle,CheckboxItem:Tle,RadioItem:Dle,MenuGroup:Mle}),xt=Qle,Kle=()=>{const{t}=we();return[{value:"bpr.activityType.classroomActivity",label:t("bpr.activityType.classroomActivity")},{value:"bpr.activityType.groupActivity",label:t("bpr.activityType.groupActivity")},{value:"bpr.activityType.personalActivity",label:t("bpr.activityType.personalActivity")},{value:"bpr.activityType.homework",label:t("bpr.activityType.homework")},{value:"bpr.activityType.exercize",label:t("bpr.activityType.exercize")},{value:"bpr.activityType.learningPath",label:t("bpr.activityType.learningPath")},{value:"bpr.activityType.courseElement",label:t("bpr.activityType.courseElement")},{value:"bpr.other",label:t("bpr.other")}]},Zle=({control:t,selectedActivities:e,selectActivities:r})=>{const n=Kle(),{t:i}=we();return g.jsx("div",{className:"col d-flex",children:g.jsx(u1,{name:"activityType",control:t,rules:{required:!0},render:({field:{onChange:s}})=>g.jsxs(xt,{block:!0,overflow:!0,children:[g.jsx(xt.Trigger,{size:"md",label:i("bpr.form.publication.type"),badgeContent:e==null?void 0:e.length}),g.jsx(xt.Menu,{children:n.map((o,a)=>g.jsx(xt.CheckboxItem,{value:o.value,model:e,onChange:()=>{r(o.value),s(o.value)},children:o.label},a))})]})})})},Jle=t=>g.jsx(xt.Trigger,{...t,"aria-haspopup":"listbox",role:"combobox"}),eue=Jle,tue=({icon:t,options:e,overflow:r,block:n,variant:i,size:s,disabled:o,placeholderOption:a,onValueChange:l})=>{const[u,c]=T.useState(),{t:h}=we();T.useEffect(()=>{if(u){const y=typeof u=="object"?u.value:u;l==null||l(y)}},[u]);const f=typeof u=="object"?u.label:u,m=typeof u=="object"?u.icon:void 0;return g.jsxs(xt,{overflow:r,block:n,children:[g.jsx(eue,{icon:m||t,label:h(f||a),variant:i,size:s,disabled:o}),g.jsx(xt.Menu,{role:"listbox",children:e==null?void 0:e.map(y=>{const v=typeof y=="object"?y.value:y,x=typeof y=="object"?y.label:y,b=typeof y=="object"?y.icon:void 0;return g.jsx(xt.Item,{type:"action",onClick:()=>c(y),icon:b,children:x},v)})})]})},aA=tue,rue=["3","4","5","6","7","8","9","10","11","12","13","14","15","16","17","18"],Sk=({name:t,control:e,placeholderOption:r,validate:n})=>g.jsx(u1,{name:t,control:e,rules:{required:!0,validate:n},render:({field:{onChange:i}})=>g.jsx(aA,{block:!0,size:"md",onValueChange:i,options:rue,"aria-required":!0,placeholderOption:r})}),nue=()=>{const{t}=we();return[{value:"de_DE",label:t("de_DE")},{value:"en_EN",label:t("en_EN")},{value:"ar_DZ",label:t("ar_DZ")},{value:"es_ES",label:t("es_ES")},{value:"fr_FR",label:t("fr_FR")},{value:"it_IT",label:t("it_IT")},{value:"ja_JP",label:t("ja_JP")},{value:"zh_CN",label:t("zh_CN")},{value:"pt_PT",label:t("pt_PT")},{value:"ru_RU",label:t("ru_RU")},{value:"bpr.other",label:t("bpr.other")}]},iue="bpr.form.publication.language",sue=({control:t})=>{const e=nue();return g.jsx("div",{className:"col",children:g.jsx(u1,{name:"language",control:t,rules:{required:!0},render:({field:{onChange:r}})=>g.jsx(aA,{block:!0,size:"md",onValueChange:r,options:e,"aria-required":!0,placeholderOption:iue})})})},oue=()=>{const{t}=we(),[e]=Pn();return g.jsxs(g.Fragment,{children:[g.jsxs("ul",{className:"mb-12",children:[g.jsxs("li",{children:[t("bpr.form.publication.licence.text.1"),g.jsx("img",{className:"ms-8 d-inline-block",src:`${e}/common/image-creative-commons.png`,alt:"licence creative commons"})]}),g.jsx("li",{children:t("bpr.form.publication.licence.text.2")})]}),g.jsx(ta,{type:"info",className:"mb-12",children:t("bpr.form.publication.licence.text.3")}),g.jsx(ta,{type:"warning",children:t("bpr.form.publication.licence.text.4")})]})},aue=()=>{const{t}=we();return[{value:"bpr.subjectArea.artActivity",label:t("bpr.subjectArea.artActivity")},{value:"bpr.subjectArea.readLearning",label:t("bpr.subjectArea.readLearning")},{value:"bpr.subjectArea.chemistry",label:t("bpr.subjectArea.chemistry")},{value:"bpr.subjectArea.law",label:t("bpr.subjectArea.law")},{value:"bpr.subjectArea.worldDiscovery",label:t("bpr.subjectArea.worldDiscovery")},{value:"bpr.subjectArea.economy",label:t("bpr.subjectArea.economy")},{value:"bpr.subjectArea.mediaEducation",label:t("bpr.subjectArea.mediaEducation")},{value:"bpr.subjectArea.musicEducation",label:t("bpr.subjectArea.musicEducation")},{value:"bpr.subjectArea.sportEducation",label:t("bpr.subjectArea.sportEducation")},{value:"bpr.subjectArea.citizenshipEducation",label:t("bpr.subjectArea.citizenshipEducation")},{value:"bpr.subjectArea.geography",label:t("bpr.subjectArea.geography")},{value:"bpr.subjectArea.history",label:t("bpr.subjectArea.history")},{value:"bpr.subjectArea.artHistory",label:t("bpr.subjectArea.artHistory")},{value:"bpr.subjectArea.ComputerScience",label:t("bpr.subjectArea.ComputerScience")},{value:"bpr.subjectArea.languages",label:t("bpr.subjectArea.languages")},{value:"bpr.subjectArea.italian",label:t("bpr.subjectArea.italian")},{value:"bpr.subjectArea.spanish",label:t("bpr.subjectArea.spanish")},{value:"bpr.subjectArea.french",label:t("bpr.subjectArea.french")},{value:"bpr.subjectArea.german",label:t("bpr.subjectArea.german")},{value:"bpr.subjectArea.english",label:t("bpr.subjectArea.english")},{value:"bpr.subjectArea.ancientLanguages",label:t("bpr.subjectArea.ancientLanguages")},{value:"bpr.subjectArea.literature",label:t("bpr.subjectArea.literature")},{value:"bpr.subjectArea.mathematics",label:t("bpr.subjectArea.mathematics")},{value:"bpr.subjectArea.vocationalGuidance",label:t("bpr.subjectArea.vocationalGuidance")},{value:"bpr.subjectArea.philosohppy",label:t("bpr.subjectArea.philosohppy")},{value:"bpr.subjectArea.physics",label:t("bpr.subjectArea.physics")},{value:"bpr.subjectArea.politicalSscience",label:t("bpr.subjectArea.politicalSscience")},{value:"bpr.subjectArea.sociology",label:t("bpr.subjectArea.sociology")},{value:"bpr.subjectArea.biology",label:t("bpr.subjectArea.biology")},{value:"bpr.subjectArea.geology",label:t("bpr.subjectArea.geology")},{value:"bpr.subjectArea.technology",label:t("bpr.subjectArea.technology")},{value:"bpr.subjectArea.Arabic",label:t("bpr.subjectArea.Arabic")},{value:"bpr.subjectArea.Chinese",label:t("bpr.subjectArea.Chinese")},{value:"bpr.subjectArea.NaturalSciences",label:t("bpr.subjectArea.NaturalSciences")},{value:"bpr.subjectArea.SocioEmotionalEducation",label:t("bpr.subjectArea.SocioEmotionalEducation")},{value:"bpr.other",label:t("bpr.other")}]},lue=({control:t,selectedSubjectAreas:e,selectSubjects:r})=>{const n=aue(),{t:i}=we();return g.jsx("div",{className:"col d-flex",children:g.jsx(u1,{name:"subjectArea",control:t,rules:{required:!0},render:({field:{onChange:s}})=>g.jsxs(xt,{block:!0,overflow:!0,children:[g.jsx(xt.Trigger,{size:"md",label:i("bpr.form.publication.discipline"),badgeContent:e==null?void 0:e.length}),g.jsx(xt.Menu,{children:n.map((o,a)=>g.jsx(xt.CheckboxItem,{value:o.value,model:e,onChange:()=>{r(o.value),s(o.value)},children:o.label},a))})]})})})},H6=T.createContext(null);function uue({defaultTheme:t,children:e}){var r;const{appCode:n}=yt(),i=TL({appCode:n});T.useEffect(()=>{var o,a,l,u,c,h,f,m,y,v,x;const b=document.getElementById("favicon");b.href=`${(a=(o=i==null?void 0:i.data)==null?void 0:o.theme)==null?void 0:a.basePath}/img/illustrations/favicon.ico`;const _=(c=(u=(l=i==null?void 0:i.data)==null?void 0:l.theme)==null?void 0:u.bootstrapVersion)==null?void 0:c.split("-"),w=_?_[_.length-1]:void 0;[{data:"data-skin",value:(f=(h=i==null?void 0:i.data)==null?void 0:h.theme)==null?void 0:f.skinName},{data:"data-theme",value:((y=(m=i==null?void 0:i.data)==null?void 0:m.theme)==null?void 0:y.npmTheme)??((x=(v=i==null?void 0:i.data)==null?void 0:v.theme)==null?void 0:x.themeName)},{data:"data-product",value:t==="none"?"":t??w}].forEach(E=>{var A;return(A=document.querySelector("html"))==null?void 0:A.setAttribute(E.data,E.value)})},[i==null?void 0:i.data,t]);const s=T.useMemo(()=>{var o;return{theme:(o=i==null?void 0:i.data)==null?void 0:o.theme}},[(r=i==null?void 0:i.data)==null?void 0:r.theme]);return g.jsx(H6.Provider,{value:s,children:e})}function ba(){const t=T.useContext(H6);if(!t)throw new Error("Cannot be used outside of OdeClientProvider");return t}const cue=({children:t,space:e=null,flexDirection:r="row"})=>{const n=Re("card-body",{[`p-${e}`]:e,[`gap-${e}`]:e,"align-items-start":r==="column","flex-column":r==="column"});return g.jsx("div",{className:n,children:t})},due=cue,V6=T.createContext(null),G6=()=>{const t=T.useContext(V6);if(!t)throw new Error("Cannot be rendered outside the Card component");return t},hue=({children:t})=>g.jsx("div",{className:"card-footer gap-16",children:t}),fue=hue,pue=()=>{const{isSelectable:t,isClickable:e,onClick:r,onSelect:n}=G6(),{t:i}=we();return t||e?g.jsxs("div",{className:"card-header",children:[t?g.jsx(Ro,{"aria-label":i("card.open.menu"),className:"z-3 bg-white",color:"secondary",icon:g.jsx(lz,{}),onClick:n,variant:"ghost"}):null,e?g.jsx("button",{type:"button",onClick:r,className:"position-absolute bottom-0 end-0 top-0 start-0 opacity-0 z-1 w-100","aria-label":i("card.open.resource")}):null]}):null},mue=pue,gue=T.forwardRef(({app:t,size:e="24",iconFit:r="contain",variant:n="square",className:i=""},s)=>{const{isIconUrl:o,getIconCode:a}=cA(),[,l]=Pn(),u=n==="square",c=n==="rounded",h=n==="circle",f=r==="contain",m=r==="ratio",y={"icon-xs":e==="24","icon-sm":e==="40","icon-md":e==="48","icon-lg":e==="80","icon-xl":e==="160"},v={square:u,rounded:c,"rounded-circle":h},x={"icon-contain":f,"icon-ratio":m},b=typeof t=="string"?t:(t==null?void 0:t.icon)!==void 0?t.icon:"placeholder",_=typeof t!="string"&&(t==null?void 0:t.displayName)!==void 0?t.displayName:"",w=t?a(t):"",E=o(b),A=w||"placeholder";if(E){const I=Re("h-full",i);return g.jsx(wo,{src:b,alt:_,objectFit:"contain",width:e,height:e,className:I,style:{minWidth:e+"px"}})}const P=Re("app-icon",{...y,...v,...x,[`bg-light-${A}`]:A&&!f,[`color-app-${A}`]:A},i);return g.jsx("div",{className:P,style:{width:e+"px",height:e+"px"},children:g.jsx("svg",{ref:s,width:e,height:e,role:"img",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:g.jsx("use",{xlinkHref:`${l}/apps.svg#${A}`})})})}),ya=gue,vue=({imageSrc:t,className:e,variant:r="medium"})=>{const{app:n}=G6(),i=r==="landscape"?{width:"100%",height:"auto"}:null;return g.jsx("div",{className:Re("card-image",r),children:t?g.jsx(wo,{alt:"",src:t,objectFit:"cover",className:Re("h-full w-100",e)}):g.jsx(ya,{app:n,iconFit:"ratio",size:"80",variant:"rounded",...i})})},yue=vue,xue=({children:t,className:e})=>{const r=Re("card-text small text-break text-truncate text-truncate-1",e);return g.jsx("p",{className:r,children:t})},bue=xue,wue=({children:t,className:e})=>{const r=Re("card-title body text-break text-truncate text-truncate-2",e);return g.jsx("h3",{className:r,children:g.jsx("strong",{children:t})})},_ue=wue,Sue=({userSrc:t,creatorName:e})=>t?g.jsx(rc,{alt:e||"",size:"xs",src:t,variant:"circle",width:"24",height:"24"}):g.jsx(bC,{}),Eue=Sue,Tue=T.forwardRef(({app:t,isSelectable:e=!0,isClickable:r=!0,isSelected:n=!1,isFocused:i=!1,onClick:s,onSelect:o,children:a,className:l},u)=>{const{getIconCode:c}=cA(),h=t?c(t):"placeholder",f=T.useMemo(()=>({app:t,appCode:h,isSelectable:e,isClickable:r,onClick:s,onSelect:o}),[t,h,e,r,s,o]);return g.jsx(V6.Provider,{value:f,children:g.jsxs("div",{ref:u,className:Re("card",{"drag-focus":i,"is-selected":n,"c-pointer":r},l),children:[g.jsx(W6.Header,{}),typeof a=="function"?a(h):a]})})}),W6=Object.assign(Tue,{Title:_ue,Text:bue,Image:yue,Body:due,User:Eue,Footer:fue,Header:mue}),tr=W6;function Cue(t,e){const[r,n]=T.useState(null),{ref:i,inView:s}=tse({triggerOnce:!0,...e==null?void 0:e.intersectionOptions});return T.useEffect(()=>{var o;(o=e==null?void 0:e.ref)!=null&&o.current&&(i==null||i(e.ref.current))},[e==null?void 0:e.ref,i]),T.useEffect(()=>{if((e==null?void 0:e.ref)===void 0||s){const o=new Image;return o.src=t,o.onload=()=>{n(!0)},o.onerror=()=>{n(!1)},()=>{o.onload=null,o.onerror=null,n(null)}}},[s]),r}const Aue=({type:t,roleMap:e})=>{const r=typeof(e==null?void 0:e.icon)!="string"&&t!=="unknown",n=Re("position-absolute top-50 start-50 translate-middle",{"p-12 rounded-circle shadow":r},e==null?void 0:e.color);return g.jsx("div",{className:n,children:(e==null?void 0:e.icon)??g.jsx(cz,{})})},Rue=Aue,Pue=({doc:t,isClickable:e=!0,isSelectable:r=!1,isSelected:n=!1,onClick:i,className:s})=>{var o;const a=T.useRef(null),l=Vk.getRole(t);function u(y){const v={csv:{icon:".CSV",color:"bg-orange-200"},xls:{icon:".XLS",color:"bg-green-200"},doc:{icon:".DOC",color:"bg-blue-200"},txt:{icon:".TXT",color:"bg-blue-200"},pdf:{icon:".PDF",color:"bg-red-200"},audio:{icon:g.jsx(c1,{width:22,height:22}),color:"bg-red-200"},ppt:{icon:".PPT",color:"bg-yellow-200"},img:{icon:g.jsx(iz,{width:22,height:22}),color:"bg-green-200"},video:{icon:g.jsx(Gz,{width:22,height:22}),color:"bg-purple-200"},zip:{icon:".ZIP",color:"bg-gray-300"},md:{icon:".MD",color:"bg-blue-200"},unknown:{icon:g.jsx(Uz,{width:22,height:22}),color:"bg-gray-300"}};return v[y]||v.unknown}const c=Re("file position-relative rounded",((o=u(l??"default"))==null?void 0:o.color)??"bg-yellow-200"),h=l==="img"||l==="video"?Me.workspace().getThumbnailUrl(t):null,f=Cue(h,{ref:a}),m=f&&{backgroundImage:`url(${h})`,backgroundSize:"cover"};return g.jsx(tr,{className:Re("card-file",s),isClickable:e,isSelectable:r,isSelected:n,onClick:i,children:g.jsxs(tr.Body,{space:"8",children:[g.jsx("div",{ref:a,className:c,style:{aspectRatio:"16/10",...m},children:l!=="img"||l==="img"&&!f?g.jsx(Rue,{type:l,roleMap:u(l)}):null}),g.jsxs("div",{className:"mt-4",children:[g.jsx(tr.Text,{children:t.name}),g.jsx(tr.Text,{className:"text-black-50",children:t==null?void 0:t.ownerName})]})]})})},Iue=Pue,Mue=({item:t,status:e="idle",isClickable:r=!1,isSelectable:n=!1,onDelete:i,onEdit:s,onRetry:o})=>{const[a]=Pn(),{t:l}=we(),{src:u,name:c,info:h}=t,f=e==="idle",m=e==="loading",y=e==="success",v=h==null?void 0:h.type.startsWith("image"),x=`${a}/common/image-placeholder.png`,b={text:"",context:null,image:g.jsx("img",{src:x,alt:"",width:"48",height:"48"})},_={error:{text:g.jsx("strong",{children:g.jsx("small",{className:"text-danger caption",children:l("tiptap.upload.error")})}),context:g.jsx(it,{leftIcon:g.jsx(GN,{}),variant:"ghost",color:"tertiary",onClick:o,children:l("tiptap.upload.retry")}),image:g.jsx(wo,{alt:"",src:`${a}/common/image-status-error.svg`,objectFit:"cover"})},idle:b,loading:{text:"",context:g.jsx(fo,{message:l("tiptap.tooltip.upload.loading"),placement:"top",children:g.jsx(YT,{isLoading:!0,loadingPosition:"left",className:"text-secondary"})}),image:b.image},warning:b,success:{text:g.jsxs("em",{children:[h==null?void 0:h.type," ",(h==null?void 0:h.weight)&&`- ${h.weight}`]}),context:g.jsx(fo,{message:l("tiptap.tooltip.upload.loaded"),placement:"top",children:g.jsx(WN,{className:"text-success"})}),image:g.jsx(wo,{alt:"",src:u??"",width:"48",objectFit:"cover",className:"rounded",style:{aspectRatio:1/1}})},unknown:b},w=()=>v&&g.jsx(fo,{message:l("tiptap.tooltip.upload.edit"),placement:"top",children:g.jsx(Ro,{icon:g.jsx(Xz,{}),variant:"ghost","aria-label":l("tiptap.tooltip.upload.loading"),disabled:m||!y,onClick:s,color:"secondary"})});return g.jsx(tr,{isClickable:r,isSelectable:n,className:"card-upload",children:g.jsxs(tr.Body,{children:[g.jsx("div",{className:"card-image",children:_[e].image}),g.jsxs("div",{className:"text-truncate",children:[g.jsx(tr.Text,{children:c}),g.jsx(tr.Text,{className:"caption",children:_[e].text})]}),!f&&g.jsx("div",{className:"ms-auto",children:g.jsxs("div",{className:"d-flex align-items-center gap-12",children:[_[e].context,!f&&g.jsx("div",{className:"vr"}),w(),g.jsx(fo,{message:l("tiptap.tooltip.upload.delete"),placement:"top",children:g.jsx(Ro,{icon:g.jsx(NT,{}),variant:"ghost","aria-label":l("tiptap.tooltip.upload.delete"),color:"tertiary",onClick:i})})]})})]})})},kue=Mue,Oue=T.forwardRef(({children:t},e)=>g.jsx("div",{ref:e,className:"actionbar",children:t})),Due=Oue,Nue=T.forwardRef(({children:t,render:e,isFullscreen:r=!1,...n},i)=>{const s=Re("d-flex flex-wrap p-16 gap-8 border-bottom bg-white",{"justify-content-between":e,"mx-n16":!r,"z-3 top-0 start-0 end-0":r});return g.jsxs("div",{ref:i,className:s,...n,children:[t,e?g.jsx("div",{className:"d-flex align-items-center ms-auto gap-8",children:e()}):null]})}),Lue=Nue;function Ki(t,e){if(Array.isArray(t))for(const r of t){const n=Ki(r,e);if(n)return n}else{if(t.id===e)return t;if(t.children)for(const r of t.children){const n=Ki(r,e);if(n)return n}}}function Fue(t,{parentId:e,newFolder:r}){return Am(t,n=>{var i;if(n.id===e){const s=[...((i=n.folder)==null?void 0:i.ancestors)||[]],o=X6([...s,n.id]);return{...n,children:[...n.children||[],new lA({...r,ancestors:o})]}}else return n})}function X6(t){return t.filter((e,r)=>t.indexOf(e)===r)}function jue(t,{folders:e}){return Am(t,r=>{if(!e.includes(r.id))return r})}const q6=(t,e)=>{if(t.children)for(const r of t.children){if(r.id===e)return t;const n=q6(r,e);if(n)return n}};function C2(t,e){var r;const n=Ki(t,e);return(r=n==null?void 0:n.folder)!=null&&r.ancestors?[...(n==null?void 0:n.folder.ancestors)||[],e]:e===Er.BIN?[Er.BIN]:[Er.DEFAULT]}function Am(t,e){return Y6(t,e)||t}function Y6(t,e,r){var n;const i=e(t,r);if((n=i==null?void 0:i.children)!=null&&n.length){const s=[];for(const o of(i==null?void 0:i.children)||[]){const a=Y6(o,e,i);a&&s.push(a)}return{...i,children:s}}return i}function Bue(t,{destinationId:e,folders:r}){return Am(t,(n,i)=>{var s,o;if(e===n.id){const a=[...((s=n.folder)==null?void 0:s.ancestors)||[]],l=X6([...a,n.id]),u=[...n.children||[]],c=((o=n.children)==null?void 0:o.map(h=>h.id))||[];for(const h of r)if(!c.includes(h)){const f=Ki(n,h);f&&u.push({...f,folder:{...f==null?void 0:f.folder,ancestors:l}})}return{...n,children:u}}else return r.includes(n.id)&&e!==(i==null?void 0:i.id)?void 0:n})}const Uue=(t,e,r)=>Am(t,n=>(n.id===r&&(n.children=e==null?void 0:e.map(i=>new lA(i))),n));function $ue(t,{folderId:e,newFolder:r}){return Am(t,n=>n.id===e?new lA(r):n)}function zue(t,e){let r=[];function n(s,o){if(s.id===e)return r=o.concat(s.id),!0;if(s.children){for(const a of s.children)if(n(a,o.concat(s.id)))return!0}return!1}function i(s){if(Array.isArray(s)){for(const o of s)if(n(o,[]))break}else n(s,[])}return i(t),r}class lA{constructor(e){ff(this,"id"),ff(this,"name"),ff(this,"childNumber"),ff(this,"section",!1),ff(this,"children",[]),this.folder=e,this.id=e.id,this.name=e.name,this.childNumber=e.childNumber}}const Hue=T.createContext(null);function Q6(){return T.useContext(Hue)}class Ek{static isLocalURL(e){return e.length>0&&e.charAt(0)==="/"}static startWithHttp(e){return/^https?:\/\//gi.test(e)}static toCounter(e){return e>999?`${Number(e/1e3).toFixed(1)} k`:""+e}}function Vue(t){const e=new Date().getTime(),r=t.includes("?")?"&":"?";return`${t}${r}timestamp=${e}`}const pf=(t,e)=>{const r="virtualID";if(!Object.hasOwnProperty.apply(t,[r])){const n=e??`${LB.generateVirtualId()}#${t.size}`;Object.defineProperty(t,r,{value:n,writable:!1})}return t[r]};function K6(t,e){if(e(t))return t;if(Array.isArray(t.children))for(const r of t.children){const n=K6(r,e);if(n)return n}}const Vy=(t,e)=>{const r=e==null?void 0:e.filter(n=>n.id===t&&n.available);return r&&r.length>0},Z6={blog:"Blog",mindmap:"MindMap",scrapbook:"ScrapBook",collaborativewall:"CollaborativeWall",timelinegenerator:"TimelineGenerator",wiki:"Wiki",exercizer:"Exercizer"},pl=t=>{if(t>0){let e=Math.floor(t/1e3),r=Math.floor(e/60);return e=e%60,r=r%60,Tk(r)+":"+Tk(e)}return"00:00"},Tk=t=>t.toString().padStart(2,"0"),Gue=()=>MediaRecorder.isTypeSupported?["video/webm;codecs=vp9",'video/mp4; codecs="avc1.424028, mp4a.40.2"',"video/webm;codecs=vp8,opus","video/webm"].find(t=>MediaRecorder.isTypeSupported(t)?!0:(console.error(`${t} is not Supported`),!1))||"video/ogg":"video/webm;codecs=vp8,opus",J6=T.createContext({ariaLabelId:"",ariaDescriptionId:"",focusId:""}),e8=()=>{const t=T.useContext(J6);if(!t)throw new Error("Cannot be rendered outside the Modal component");return t},Wue=t=>{const{ariaDescriptionId:e}=e8(),{children:r,className:n}=t,i=Re("modal-body",n);return g.jsx("div",{id:e,className:i,children:r})},Xue=Wue,que=t=>g.jsx("div",{className:"modal-footer",children:t.children}),Yue=que,Que=t=>{const{onModalClose:e,children:r}=t,{ariaLabelId:n,focusId:i}=e8(),s=T.useRef(null),{t:o}=we();return T.useEffect(()=>{var a;i||(a=s.current)==null||a.focus()},[i]),g.jsxs("div",{className:"modal-header",children:[g.jsx("h2",{id:n,className:"modal-title",tabIndex:-1,children:r}),g.jsx(Ro,{ref:s,"aria-label":o("close"),color:"tertiary",icon:g.jsx(NT,{}),type:"button",variant:"ghost",title:o("close"),onClick:e,className:"btn-close"})]})},Kue=Que,Zue=t=>g.jsx("p",{className:"modal-subtitle",children:t.children}),Jue=Zue,ece=T.forwardRef((t,e)=>{const{id:r,isOpen:n,onModalClose:i,size:s="md",viewport:o=!1,scrollable:a=!1,focusId:l,children:u}=t,c=`aria_label_${r}`,h=`aria_desc_${r}`,f=U6(i),m=qle();Vle(i,["Escape"]),T.useEffect(()=>{if(n&&(document.body.style.overflow="hidden",l)){const _=document.getElementById(l);_==null||_.focus()}return()=>{document.body.style.overflow=""}},[l,n]);const y=Re("modal fade",{"show d-block":n,"modal-scrollable":a,viewport:o,[`modal-${s}`]:s}),v=Re("modal-dialog"),x={ariaLabelId:c,ariaDescriptionId:h,focusId:l},b=hC(n,{from:{x:-50,opacity:0},enter:{x:0,opacity:1},leave:{x:50,opacity:0}});return g.jsx(J6.Provider,{value:x,children:b((_,w)=>g.jsxs(g.Fragment,{children:[w&&g.jsx(Il.div,{id:r,ref:e,role:"dialog","aria-modal":"true","aria-labelledby":c,"aria-describedby":h,className:y,style:_,tabIndex:-1,children:g.jsx("div",{id:`${r}_ref`,ref:E=>{f.current=E,w&&(m.current=E)},className:v,children:g.jsx("div",{className:"modal-content",children:u})})}),w&&g.jsx(Il.div,{className:"modal-backdrop fade show",style:{opacity:.65}})]}))})}),tce=Object.assign(ece,{Header:Kue,Subtitle:Jue,Body:Xue,Footer:Yue}),Ye=tce,rce=({children:t,message:e,icon:r=null,placement:n="auto",...i})=>{const[s,o]=T.useState(null),[a,l]=T.useState(null),[u,c]=T.useState(null),{styles:h,attributes:f}=bq(s,a,{placement:n,modifiers:[{name:"arrow",options:{element:u}}]}),[m,y]=T.useState(!1);return g.jsxs(g.Fragment,{children:[g.jsx("div",{className:"d-inline-block position-relative z-2",ref:o,onMouseEnter:()=>{y(!0)},onMouseLeave:()=>{y(!1)},...i,children:t}),m&&e&&g.jsxs("div",{className:Re("tooltip d-block show mb-12","bs-tooltip-auto"),ref:l,style:h.popper,...f.popper,children:[g.jsxs("div",{className:"tooltip-inner shadow-hover d-flex gap-8 align-items-center",children:[r&&r,g.jsx("div",{children:e})]}),g.jsx("div",{className:"tooltip-arrow",ref:c,style:h.arrow})]})]})},fo=rce,t8=T.createContext(null);function uA(){const t=T.useContext(t8);if(!t)throw new Error("Tabs compound components cannot be rendered outside the Tabs component");return t}const nce=({defaultId:t,items:e,onChange:r})=>{const[n,i]=T.useState(t||""),[s,o]=T.useState(0),[a,l]=T.useState(0),u=T.useRef([]),c=T.useCallback(y=>{i(y)},[]);T.useEffect(()=>{const y=e.find(v=>v.id===n);y&&(r==null||r(y))},[n]),T.useEffect(()=>{function y(){var v;if(((v=document==null?void 0:document.activeElement)==null?void 0:v.tagName)!=="INPUT"){const x=e.findIndex(_=>_.id===n);x===-1&&t&&i(t);const b=u.current[x];b&&(b.focus(),l((b==null?void 0:b.offsetLeft)??0),o((b==null?void 0:b.clientWidth)??0))}}return y(),window.addEventListener("resize",y),()=>window.removeEventListener("resize",y)},[n,e,t]);const h=T.useCallback(y=>{var v,x,b;const _=e.findIndex(w=>w.id===y);y===((v=e[0])==null?void 0:v.id)?i((x=e[e.length-1])==null?void 0:x.id):i((b=e[_-1])==null?void 0:b.id)},[e]),f=T.useCallback(y=>{var v,x,b;const _=e.findIndex(w=>w.id===y);y===((v=e[e.length-1])==null?void 0:v.id)?i((x=e[0])==null?void 0:x.id):i((b=e[_+1])==null?void 0:b.id)},[e]),m=T.useCallback(y=>{var v,x;switch(y.code){case"ArrowLeft":h(n);break;case"ArrowRight":f(n);break;case"Home":i((v=e[0])==null?void 0:v.id);break;case"End":i((x=e[e.length-1])==null?void 0:x.id);break}},[n,e,f,h]);return{activeTab:n,setSelectedTab:c,tabsRef:u,tabUnderlineLeft:a,tabUnderlineWidth:s,onKeyDown:m}},ice=({icon:t,label:e,id:r,order:n})=>{const{activeTab:i,setSelectedTab:s,onKeyDown:o,tabsRef:a}=uA(),{t:l}=we(),u=Re("nav-link d-inline-flex gap-8 border-0",i===r?"selected":"");return g.jsx("li",{className:"nav-item flex-shrink-0",role:"presentation",children:g.jsxs("button",{ref:c=>a.current[n]=c,type:"button",id:`tab-${r}`,className:u,onClick:()=>s(r),onKeyDown:c=>o(c),role:"tab","aria-controls":`tabpanel-${r}`,"aria-selected":i===r,tabIndex:i===r?0:-1,children:[t,g.jsx("small",{children:l(e)})]})})},sce=ice,oce=t=>{const{items:e,tabUnderlineLeft:r,tabUnderlineWidth:n}=uA(),{className:i,...s}=t,o=Re("position-relative flex-shrink-0 overflow-x-auto",i);return g.jsxs("div",{className:o,...s,children:[g.jsx("ul",{className:"nav nav-tabs flex-nowrap",role:"tablist",children:e.map((a,l)=>g.jsx(oa.Item,{order:l,...a},a.id))}),g.jsx("span",{className:"nav-slide",style:{left:r,width:n}})]})},ace=oce,lce=({children:t,currentItem:e})=>{const{activeTab:r}=uA();return g.jsx("div",{className:"tab-content d-flex flex-fill w-100",children:g.jsx("div",{className:`tab-pane flex-fill w-100 fade ${r===(e==null?void 0:e.id)?"show active":""}`,id:`tabpanel-${e==null?void 0:e.id}`,role:"tabpanel","aria-labelledby":`tab-${e==null?void 0:e.id}`,tabIndex:0,children:t})})},uce=lce,oa=({defaultId:t,items:e,onChange:r,children:n})=>{const{activeTab:i,setSelectedTab:s,tabsRef:o,tabUnderlineLeft:a,tabUnderlineWidth:l,onKeyDown:u}=nce({defaultId:t,items:e,onChange:r}),c=T.useMemo(()=>({activeTab:i,items:e,setSelectedTab:s,tabsRef:o,tabUnderlineLeft:a,tabUnderlineWidth:l,onKeyDown:u}),[i,e,u,s,a,l,o]),h=e.find(f=>f.id===i);return g.jsx(t8.Provider,{value:c,children:typeof n=="function"?n(h):g.jsxs(g.Fragment,{children:[g.jsx(oa.List,{}),g.jsx(oa.Panel,{currentItem:h,children:h==null?void 0:h.content})]})})};oa.Item=sce;oa.Panel=uce;oa.List=ace;const cce=T.forwardRef(({children:t,className:e,...r},n)=>{const i=Re("breadcrumb-item",e);return g.jsx("li",{ref:n,className:i,...r,children:t})}),k0=cce,dce=T.forwardRef(({children:t,className:e},r)=>{const n=Re("breadcrumb d-flex flex-nowrap align-items-center mb-0",e);return g.jsx("ol",{ref:r,className:n,children:t})}),hce=dce;function cA(){const t={"last-infos-widget":"ic-widget-actualites",birthday:"ic-star","calendar-widget":"ic-widget-calendar","carnet-de-bord":"ic-widget-carnet-de-bord","record-me":"ic-widget-microphone",mood:"ic-star","my-apps":"ic-widget-apps",notes:"ic-widget-notes","rss-widget":"ic-widget-rss","bookmark-widget":"ic-widget-signets",qwant:"ic-widget-qwant","qwant-junior":"ic-widget-qwant","agenda-widget":"ic-widget-agenda","cursus-widget":"ic-widget-aide-devoirs","maxicours-widget":"ic-widget-maxicours","school-widget":"ic-widget-schoolbook","universalis-widget":"ic-widget-universalis","briefme-widget":"ic-widget-briefme"};function e(a){let l="";switch(typeof a=="string"?l=a:l=(a==null?void 0:a.icon)!==void 0?a==null?void 0:a.icon.trim().toLowerCase():"placeholder",l&&l.length>0?l.endsWith("-large")&&(l=l.replace("-large","")):typeof a=="object"&&(l=(a==null?void 0:a.displayName)!==void 0?a==null?void 0:a.displayName.trim().toLowerCase():""),l){case"admin.title":l="admin";break;case"banques des savoirs":l="banquesavoir";break;case"collaborativewall":l="collaborative-wall";break;case"communautés":l="community";break;case"directory.user":l="userbook";break;case"emploi du temps":l="edt";break;case"formulaire":l="forms";break;case"messagerie":l="conversation";break;case"news":l="actualites";break;case"homeworks":case"cahier de texte":l="cahier-de-texte";break;case"diary":case"cahier de texte 2d":l="cahier-textes";break}return l}function r(a){return a&&(a.startsWith("/")||a.startsWith("http://")||a.startsWith("https://"))}function n(a){const l=e(a);return l?`color-app-${l}`:"color-app-placeholder"}function i(a){const l=e(a);return l?`bg-app-${l}`:"bg-app-placeholder"}function s(a){const l=e(a);return l?`bg-light-${l}`:"bg-light-placeholder"}function o(a){return t[a.platformConf.name]}return{getIconClass:n,getBackgroundIconClass:i,getBackgroundLightIconClass:s,getIconCode:e,getWidgetIconClass:o,isIconUrl:r}}const fce=T.forwardRef(({children:t,app:e,className:r},n)=>{const{t:i}=we(),{getIconClass:s}=cA(),o=Re("d-flex align-items-center mb-0",s(e),r),a={"--edifice-breadcrumb-divider":"-"};return g.jsx("nav",{ref:n,className:o,"aria-label":i("breadcrumb"),style:a,children:t})}),pce=fce,mce=T.forwardRef(({app:t,name:e},r)=>{const{t:n}=we();return g.jsx(pce,{app:t,ref:r,className:"mw-100",children:g.jsx(hce,{className:"gap-12 mw-100",children:e?g.jsxs(g.Fragment,{children:[g.jsx(k0,{children:g.jsx("a",{href:t==null?void 0:t.address,className:"d-flex","aria-label":n(t==null?void 0:t.displayName),children:g.jsx(ya,{app:t,size:"40"})})}),g.jsx(k0,{children:g.jsx(zN,{color:"var(--edifice-gray-600)",width:20,height:20})}),g.jsx(k0,{className:"text-truncate",children:g.jsx(Ss,{level:"h1",headingStyle:"h3",className:"text-truncate",children:e})})]}):g.jsxs(k0,{className:"gap-12 d-flex align-items-center",children:[g.jsx("a",{href:t==null?void 0:t.address,className:"d-flex","aria-label":n(t==null?void 0:t.displayName),children:g.jsx(ya,{app:t,size:"40"})}),g.jsx(Ss,{level:"h1",headingStyle:"h3",className:"d-none d-md-flex",children:n(t==null?void 0:t.displayName)})]})})})}),gce=mce,r8=T.createContext(null),J1=()=>{const t=T.useContext(r8);if(!t)throw new Error("Cannot be rendered outside the FormControl component");return t},vce=({children:t})=>{const{status:e}=J1(),r=Re("form-text",{"is-invalid":e==="invalid",valid:e==="valid"});return g.jsx("p",{className:r,children:g.jsx("em",{children:t})})},yce=vce,xce=T.forwardRef(({noValidationIcon:t,placeholder:e,size:r="md",type:n="text",className:i,...s},o)=>{const{id:a,isRequired:l,isReadOnly:u,status:c}=J1(),h=Re({"form-control":!u,"form-control-lg":r==="lg","form-control-sm":r==="sm","is-invalid":c==="invalid","is-valid":c==="valid","form-control-plaintext":u,"no-validation-icon":t},i);return g.jsx("input",{ref:o,id:a,className:h,type:n,placeholder:e,required:l,readOnly:u,...s})}),Kn=xce,bce=T.forwardRef(({leftIcon:t,optionalText:e,requiredText:r="*",children:n,className:i},s)=>{const{id:o,isOptional:a,isRequired:l}=J1(),{t:u}=we(),c=Re("form-label",{"has-icon":t},i),h=a&&!l,f=l&&!a;return T.useEffect(()=>{if(a&&l)throw new Error("Cannot be optional and required at the same time")},[a,l]),g.jsxs("label",{ref:s,htmlFor:o,className:c,children:[t,n,h&&g.jsxs("em",{className:"optional",children:["- ",e??u("explorer.optional")]}),f&&g.jsx("em",{className:"required",children:r})]})}),Gi=bce,wce=T.forwardRef(({children:t,className:e,id:r,isOptional:n,isReadOnly:i,isRequired:s,status:o,...a},l)=>{const u=T.useMemo(()=>({id:r,isOptional:n,isRequired:s,isReadOnly:i,status:o}),[r,n,i,s,o]);return g.jsx(r8.Provider,{value:u,children:g.jsx("div",{ref:l,className:e,...a,children:t})})}),_ce=Object.assign(wce,{Label:Gi,Input:Kn,Text:yce}),Ot=_ce,Sce=({placeholder:t,value:e="",searchMinLength:r=3,handleSearchInputChange:n})=>{const{triggerProps:i,itemProps:s,setVisible:o}=bh(),a={...i,role:"combobox",onClick:()=>{e.length>=r&&o(!0)},onChange:n};return T.useEffect(()=>{o(e.length>=r)},[o,e,r]),g.jsx(Ot,{className:"d-flex align-items-center",id:"search",children:g.jsx(Kn,{...a,className:"max-w-512",noValidationIcon:!0,placeholder:t,size:"md",type:"search",onKeyDown:s.onMenuItemKeyDown})})},Ece=Sce,dA=({onSearchResultsChange:t,onSearchInputChange:e,options:r,value:n,isLoading:i,noResult:s,searchMinLength:o,placeholder:a})=>{const{t:l}=we(),[u,c]=T.useState([]);T.useEffect(()=>{t(u)},[u]);const h=m=>{c([m])},f=()=>i?g.jsxs("div",{className:"d-flex align-items-center p-4",children:[g.jsx(YT,{isLoading:i}),g.jsx("span",{className:"ps-4",children:l("explorer.search.pending")})]}):s?g.jsx("div",{className:"p-4",children:l("portal.no.result")}):r.map((m,y)=>g.jsxs(T.Fragment,{children:[g.jsx(xt.Item,{type:"select",icon:m.icon,onClick:()=>h(m.value),children:m.label}),y<r.length-1&&g.jsx(xt.Separator,{})]},y));return g.jsxs(xt,{block:!0,children:[g.jsx(dA.Trigger,{placeholder:a,searchMinLength:o,handleSearchInputChange:e,value:n}),g.jsx(xt.Menu,{children:f()})]})};dA.Trigger=Ece;const Tce=dA,n8=T.createContext(null);function hA(){const t=T.useContext(n8);if(!t)throw new Error("Cannot be rendered outside Dropzone Provider");return t}const Cce=()=>{const{t}=we();return g.jsx("div",{className:"drop-wrapper",children:g.jsx("div",{className:"drop-content",children:g.jsx("p",{className:"drop-text",children:t("dropzone.drop")})})})},Ace=Cce,Rce=({children:t,multiple:e})=>{const{t:r}=we(),{files:n,inputRef:i}=hA(),s=n&&n.length>0,o=Re("drop-file-wrapper",{"d-block":s,"d-none":!s});return g.jsxs("div",{className:o,children:[g.jsx("div",{className:"drop-file-content",children:g.jsx("div",{className:"add-button p-4",children:g.jsx(it,{variant:"ghost",leftIcon:g.jsx(d1,{}),disabled:!e,onClick:()=>{var a;return(a=i==null?void 0:i.current)==null?void 0:a.click()},children:r("dropzone.add.more")})})}),g.jsx("div",{className:"p-8",children:t})]})},Pce=Rce,Ice=()=>{const{t}=we(),{files:e,inputRef:r}=hA(),n=e&&e.length>0,i=Re("dropzone-import-wrapper",{"d-flex":!n,"d-none":n});return g.jsxs("div",{className:i,children:[g.jsx(W$,{height:48,width:48}),g.jsx("p",{className:"my-16",children:t("dropzone.text")}),g.jsx(it,{onClick:()=>{var s;return(s=r==null?void 0:r.current)==null?void 0:s.click()},children:t("dropzone.import")})]})},Mce=Ice,Wu=({className:t,accept:e,multiple:r=!0,handle:n=!1,children:i})=>{const{inputRef:s,dragging:o,files:a,addFile:l,deleteFile:u,replaceFileAt:c,handleDragLeave:h,handleDragging:f,handleDrop:m,handleOnChange:y}=Hle(e?{forceFilters:!0}:void 0),v=Re("dropzone",{"is-dragging":(r||a.length<1)&&o,"is-drop-files":!(a.length!==0&&!n)},t),x=T.useMemo(()=>({inputRef:s,files:a,addFile:l,deleteFile:u,replaceFileAt:c}),[l,u,c,a,s]);return g.jsx(n8.Provider,{value:x,children:g.jsxs("div",{className:v,onDragEnter:f,onDragOver:f,onDragLeave:h,onDrop:a.length>0&&!r?void 0:m,children:[g.jsxs("div",{className:"d-flex flex-fill",children:[n?null:g.jsxs(g.Fragment,{children:[g.jsx(Wu.File,{multiple:r,children:i}),g.jsx(Wu.Import,{})]}),g.jsx(Wu.Drag,{})]}),g.jsx("input",{ref:s,accept:e==null?void 0:e.join(","),multiple:r,type:"file",name:"attachment-input",id:"attachment-input",onChange:y,hidden:!0})]})})};Wu.File=Pce;Wu.Import=Mce;Wu.Drag=Ace;const kce=Wu,so=({children:t,className:e,...r})=>{const n=Re("grid",e);return g.jsx("div",{className:n,...r,children:t})},Oce=({sm:t,md:e,lg:r,xl:n,children:i,className:s,as:o,...a})=>{const l=o||"div",u=Re({[`g-col-${t}`]:t,[e?`g-col-md-${e}`:""]:e,[r?`g-col-lg-${r}`:""]:r,[n?`g-col-xl-${n}`:""]:n},s);return g.jsx(l,{className:u,...a,children:i})};so.Col=Oce;const Dce=T.forwardRef(({position:t=!0,caption:e},r)=>{const[n]=Pn(),i=`${n}/loading/screen-loading.gif`,s=Re("top-0 end-0 start-0 bottom-0 d-grid justify-content-center align-content-center align-items-center z-2000",{"position-fixed":!t,"position-static":t}),o=Re("text-center pt-12",{"text-white":!t});return g.jsxs(g.Fragment,{children:[g.jsxs("div",{ref:r,className:s,children:[g.jsx("div",{className:"bg-white rounded-circle mx-auto w-25",children:g.jsx("img",{src:i,alt:"loading"})}),e&&g.jsx("div",{className:o,children:e})]}),!t&&g.jsx("div",{className:"modal-backdrop fade show"})]})}),fr=Dce,Nce=T.forwardRef(({src:t,is1d:e,translate:r="Retour accueil"},n)=>{const i=Re("navbar-brand d-none d-md-block");return g.jsx("a",{ref:n,className:i,href:"/timeline/timeline","aria-label":r,children:g.jsx("img",{className:"logo",src:t,alt:`logo ${e?"ONE":"NEO"}`,width:"300",height:"52"})})}),Ck=Nce,Lce=({children:t,className:e})=>{const r=Re("popover-body",e);return g.jsx("div",{className:r,children:t})},Fce=({children:t,className:e})=>{const r=Re("popover-footer p-8",e);return g.jsx("div",{className:r,children:t})},i8=T.forwardRef(({children:t,className:e,id:r,isVisible:n,...i},s)=>{const o=Re("popover d-block position-absolute top-100 start-50 translate-middle-x",e);return hC(n,{from:{opacity:0},enter:{opacity:1},leave:{opacity:0},config:{duration:0}})((a,l)=>l&&g.jsx(Il.div,{ref:s,"aria-labelledby":r,className:o,role:"tooltip",style:a,...i,children:t}))}),jce=({isVariant:t=!1,size:e="md",placeholder:r="search",className:n,disabled:i,onChange:s,onClick:o,...a})=>{const{t:l}=we(),u=Re(n,{"input-group":!t,"position-relative":t}),c=Re({"border-end-0":!t,"ps-48":t}),h=()=>{o==null||o()};return g.jsxs(Ot,{id:"search-bar",className:u,children:[t&&g.jsx("div",{className:"position-absolute z-1 top-50 start-0 translate-middle-y border-0 ps-12 bg-transparent",children:g.jsx(AS,{})}),g.jsx(Ot.Input,{type:"search",placeholder:l(r),size:e,noValidationIcon:!0,className:c,onChange:s,disabled:i,...a}),!t&&g.jsx(oA,{type:"submit","aria-label":l("search"),icon:g.jsx(AS,{}),className:"border-start-0",onClick:h})]})},s8=jce,Bce=T.forwardRef(({noValidationIcon:t,placeholder:e,size:r="md",height:n="md",className:i,...s},o)=>{const{id:a,isRequired:l,isReadOnly:u,status:c}=J1(),h=Re({"form-control":!u,"form-control-lg":r==="lg","form-control-sm":r==="sm","textarea-height-lg":n==="lg","textarea-height-md":n==="md","textarea-height-sm":n==="sm","is-invalid":c==="invalid","is-valid":c==="valid","form-control-plaintext":u,"no-validation-icon":t},i);return g.jsx(g.Fragment,{children:g.jsx("textarea",{ref:o,id:a,className:h,placeholder:e,required:l,readOnly:u,...s})})}),fA=Bce,pA=T.forwardRef(({items:t,variant:e="default",align:r="space",isBlock:n=!1,ariaControls:i,className:s},o)=>{const[a,l]=T.useState(0),[u,c]=T.useState([]),[h,f]=T.useState(),[m,y]=T.useState(),v=T.useRef(),x=Re("toolbar z-1000 bg-white",s,{default:e==="default","no-shadow":e==="no-shadow","d-flex":n,"d-inline-flex":!n,"overflow-x-auto":n,"justify-content-start":r==="left","justify-content-between":r==="space","justify-content-center":r==="center","justify-content-end":r==="right"});T.useEffect(()=>{var P;const I=(P=v.current)==null?void 0:P.querySelectorAll("button"),M=[];let N=!1;I==null||I.forEach(z=>{z.disabled||(N||(f(z),N=!0),y(z),M.push(z))}),c(M),l(t.findIndex(z=>(z.type==="button"||z.type==="icon")&&!z.props.disabled))},[t]);const b=P=>{P.target.classList.add("focus")},_=P=>{P.target.classList.remove("focus")},w=P=>{var I,M;const N=u.indexOf(P.currentTarget);switch(P.code){case"ArrowLeft":P.currentTarget===h?m==null||m.focus():(I=u[N-1])==null||I.focus();break;case"ArrowRight":P.currentTarget===m?h==null||h.focus():(M=u[N+1])==null||M.focus();break}},E=P=>{var I;return typeof P.tooltip=="string"?P.tooltip:(I=P.tooltip)==null?void 0:I.message},A=P=>{var I;return typeof P.tooltip!="string"?(I=P.tooltip)==null?void 0:I.position:"top"};return g.jsx("div",{ref:T2(o,v),className:x,role:"toolbar","aria-label":"Text Formatting","aria-controls":i,onFocus:b,onBlur:_,children:t.map((P,I)=>{if(P.visibility==="hide")return null;switch(P.type){case"divider":return g.jsx("div",{className:"toolbar-divider"},P.name??I);case"button":return g.jsx(fo,{message:E(P),placement:A(P),children:T.createElement(it,{...P.props,key:P.name??I,color:P.props.color?P.props.color:"tertiary",variant:"ghost",tabIndex:I===a?0:-1,onKeyDown:w})},P.name??I);case"icon":return g.jsx(fo,{message:E(P),placement:A(P),children:T.createElement(Ro,{...P.props,key:P.name??I,color:P.props.color?P.props.color:"tertiary",variant:P.props.variant?P.props.variant:"ghost",tabIndex:I===a?0:-1,onKeyDown:w})},P.name??I);case"dropdown":return T.createElement(xt,{...P.props,key:P.name??I,extraTriggerKeyDownHandler:w,overflow:P.overflow});case"primary":return g.jsx(fo,{message:E(P),placement:A(P),children:g.jsx(it,{...P.props,variant:"filled",color:"primary",tabIndex:I===a?0:-1,onKeyDown:w})},P.name??I)}return null})})}),A2=({node:t,showIcon:e,selectedNodeId:r,expandedNodes:n,siblingsNodes:i,draggedNodeId:s,handleItemClick:o,handleToggleNode:a,handleItemAction:l})=>{const u=n.has(t.id),c=i==null?void 0:i.current.has(t.id),h=r===t.id,f=s===t.id,m={action:Re("action-container d-flex align-items-center gap-8 px-2",{"drag-focus":f,"py-4":!t.section}),arrow:Re({"py-4":!t.section,"py-8":t.section,invisible:!Array.isArray(t.children)||t.children.length===0}),button:Re("flex-fill d-flex align-items-center text-truncate gap-8",{"py-8":t.section})},y=t.section?16:12,{t:v}=we(),{setNodeRef:x}=Gj({id:T.useId(),data:{id:t.id,name:t.name,isTreeview:!0,accepts:["folder","resource"]}}),b=M=>o==null?void 0:o(M),_=M=>a==null?void 0:a(M),w=M=>l==null?void 0:l(M),E=M=>{(M.code==="Enter"||M.code==="Space")&&(M.preventDefault(),M.stopPropagation(),o==null||o(t.id))},A=M=>{(M.code==="Enter"||M.code==="Space")&&(M.preventDefault(),M.stopPropagation(),a==null||a(t.id))},P=M=>g.jsx(M?Tp:zN,{title:v("foldUnfold"),width:y,height:y}),I=()=>{var M;const N=!((M=i==null?void 0:i.current)!=null&&M.has(t.id)),z=Array.isArray(t.children)&&t.children.length>0;return c||N&&z};return g.jsx("li",{ref:x,id:`treeitem-${t.id}`,role:"treeitem","aria-selected":h&&h,"aria-expanded":u&&u,children:g.jsxs("div",{children:[g.jsxs("div",{className:m.action,children:[g.jsx("div",{className:m.arrow,tabIndex:0,role:"button",onClick:()=>_(t.id),onKeyDown:A,"aria-label":v("foldUnfold"),children:I()&&P(u)}),g.jsxs("div",{tabIndex:0,role:"button",className:m.button,onClick:()=>b(t.id),onKeyDown:E,children:[t.section&&e&&g.jsx(jN,{title:v("folder"),width:20,height:20}),g.jsx("span",{className:"text-truncate",children:t.name})]}),t.section&&l&&g.jsx("button",{className:"tree-btn mx-8",onClick:()=>w(t.id),children:g.jsx(d1,{height:16,width:16})})]}),Array.isArray(t.children)&&!!t.children.length&&u&&g.jsx("ul",{role:"group",children:t.children.map(M=>g.jsx(A2,{node:M,selectedNodeId:r,expandedNodes:n,siblingsNodes:i,draggedNodeId:s,handleItemClick:o,handleToggleNode:a},M.id))})]})},t.id)},Uce=({data:t,ref:e,externalSelectedNodeId:r,draggedNode:n,allExpandedNodes:i,onTreeItemUnfold:s,onTreeItemFold:o,onTreeItemClick:a})=>{const[l,u]=T.useState(void 0),[c,h]=T.useState(new Set),f=T.useRef(new Set),[m,y]=T.useState(void 0),v=l??r;function x(j){var H;Array.isArray(j)?j.forEach(F=>{const L=new Set(f.current);j.filter(({id:O})=>O!==F.id).some(O=>O.children&&O.children.length>0)&&L.add(F.id),F.children&&F.children.length>0&&F.children.forEach(O=>{var $;const V=($=F.children)==null?void 0:$.filter(({id:k})=>k!==O.id);V!=null&&V.some(k=>k.children&&k.children.length>0)&&L.add(O.id),x(O)})}):(H=j.children)==null||H.forEach(F=>{var L;const O=new Set(f.current),$=(L=j.children)==null?void 0:L.filter(V=>V.id!==F.id);$!=null&&$.some(V=>V.children&&V.children.length>0)&&(O.add(F.id),f.current=O),x(F)})}const b=j=>{const H=new Set("");t&&Array.isArray(t)&&j&&(t.forEach(F=>{H.add(F.id)}),h(H))};T.useEffect(()=>{t&&x(t)},[t]),T.useEffect(()=>{n!=null&&n.isOver&&n.isTreeview?(n.overId&&z(n.overId),y(n.overId)):y(void 0)},[n]);const _=T.useMemo(()=>({unselectAll(){u(void 0)},select(j){M(j)},allExpandedNodes(){b(i)}}),[]);T.useImperativeHandle(e,()=>_,[_]),T.useEffect(()=>{b(i)},[]),T.useEffect(()=>{r&&!i?(w(r),u(r)):u(void 0)},[r]);const w=j=>{if(!Ki(t,v)){u(void 0);return}if(r==="default"){c.forEach(H=>s==null?void 0:s(H));return}E(j)},E=j=>{const H=new Set(c),F=zue(t,j),L=Array.from(H);F.forEach(O=>{const $=L.indexOf(O);$>-1&&L.splice($,1),L.push(O)}),H.clear(),L.forEach(O=>H.add(O)),H.forEach(O=>s==null?void 0:s(O)),h(H)},A=j=>{const H=new Set(c);H.delete(j),H.forEach(F=>o==null?void 0:o(F)),h(H)},P=j=>{c.has(j)?A(j):E(j)},I=j=>{v!==j&&u(j)},M=j=>{I(j),E(j),a==null||a(j)},N=j=>{P(j)},z=j=>{Ki(t,r)&&E(j)};return{selectedNodeId:v,expandedNodes:c,siblingsNodes:f,draggedNodeId:m,handleItemClick:M,handleFoldUnfold:N}},$ce=T.forwardRef((t,e)=>{const{data:r,onTreeItemClick:n,onTreeItemUnfold:i,onTreeItemFold:s,onTreeItemAction:o,draggedNode:a,showIcon:l=!0,allExpandedNodes:u=!1,selectedNodeId:c}=t,{selectedNodeId:h,expandedNodes:f,siblingsNodes:m,draggedNodeId:y,handleItemClick:v,handleFoldUnfold:x}=Uce({data:r,ref:e,externalSelectedNodeId:c,draggedNode:a,allExpandedNodes:u,onTreeItemClick:n,onTreeItemFold:s,onTreeItemUnfold:i});return g.jsx("div",{className:"treeview",children:g.jsx("ul",{role:"tree",className:"m-0 p-0",children:Array.isArray(r)?r.map(b=>g.jsx(A2,{node:b,showIcon:l,selectedNodeId:h,expandedNodes:f,siblingsNodes:m,draggedNodeId:y,handleItemClick:v,handleToggleNode:x,handleItemAction:o},b.id)):g.jsx(A2,{node:r,selectedNodeId:h,expandedNodes:f,siblingsNodes:m,showIcon:l,draggedNodeId:y,handleItemClick:v,handleToggleNode:x})})})}),dd=$ce,zce=T.forwardRef(({children:t},e)=>g.jsx("span",{className:"visually-hidden",ref:e,children:t})),ml=zce;function Hce(){var t;const{sessionQuery:e}=yt(),r=new Set;return(t=e==null?void 0:e.data)==null?void 0:t.bookmarkedApps.filter(n=>{const i=r.has(n.displayName);return r.add(n.displayName),!i})}function Wi(t){const e=Q6(),[r,n]=T.useState();return T.useEffect(()=>{(async()=>{let i;if(e!=null&&e.hasWorkflow)if(typeof t=="string")i=await e.hasWorkflow(t);else throw"not.implemented.yet)";else typeof t=="string"?i=await Me.rights().sessionHasWorkflowRight(t):i=await Me.rights().sessionHasWorkflowRights(t);n(i)})()},[t,e]),r}const Vce=()=>{const t=Wi("fr.openent.zimbra.controllers.ZimbraController|view"),e=Wi("fr.openent.zimbra.controllers.ZimbraController|preauth"),[r,n]=T.useState(0),[i,s]=T.useState(""),o={unread:!0,_:new Date().getTime()},a=async()=>{const u=t?"/zimbra/count/INBOX":"/conversation/count/INBOX";try{const{count:c}=await Me.http().get(u,{queryParams:o});n(c??0)}catch(c){console.error(c),n(0)}},l=async()=>{const u="/zimbra/zimbra";try{const{preference:c}=await Me.http().get("/userbook/preference/zimbra"),h=c?JSON.parse(c).modeExpert:!1;s(h&&e?"/zimbra/preauth":window.location.origin+u)}catch(c){console.error(c),s(window.location.origin+u)}};return T.useEffect(()=>{a()},[]),T.useEffect(()=>{l()},[]),{messages:r,msgLink:i,zimbraWorkflow:t}},Gce=Vce;function Wce({user:t,avatar:e}){const{appCode:r}=yt(),{t:n}=we(),{theme:i}=ba(),s=n(r),[o,a]=T.useState(!0),[l,u]=$6(),c=T.useId(),h=T.useId(),f=e,m=t==null?void 0:t.username,y=n("welcome",{username:t==null?void 0:t.firstName}),v=Hce(),x=Wi("net.atos.entng.community.controllers.CommunityController|view"),b=Wi("org.entcore.conversation.controllers.ConversationController|view"),_=Wi("fr.openent.searchengine.controllers.SearchEngineController|view"),w=T.useCallback(()=>{a(!o)},[o]),E=async()=>{await Me.session().logout(),window.location.href=(i==null?void 0:i.logoutCallback)??"/auth/login"};return T.useMemo(()=>({title:s,bookmarkedApps:v,appsRef:l,isAppsHovered:u,popoverAppsId:c,popoverSearchId:h,userAvatar:f,userName:m,welcomeUser:y,communityWorkflow:x,conversationWorflow:b,searchWorkflow:_,isCollapsed:o,toggleCollapsedNav:w,handleLogout:E}),[l,v,x,b,u,o,c,h,_,s,w,f,m,y])}const Xce=t=>{const e=T.useRef(),r=en(),{t:n}=we();return T.useEffect(()=>{const i=Me.notify().events().subscribe(NB.TRANSPORT,s=>{var o,a;e.current=n(((a=(o=s==null?void 0:s.data)==null?void 0:o.payload)==null?void 0:a.error)||s.data.response.statusText),r.error(Ie.createElement("div",{children:[e.current]}),t)});return()=>i.revoke()},[n,r]),e.current},qce=Xce;function o8(){const[t,e]=T.useState(!1);T.useEffect(()=>{r()},[]);const r=T.useCallback(async()=>{const n=await Me.session().isAdml();e(n)},[]);return{isAdml:t}}const Yce=()=>{var t;const{user:e,appCode:r}=yt(),n=Z6[r],i=e==null?void 0:e.apps.find(u=>u.isExternal&&u.address.includes("library"));if(!i)return null;const s=(t=i.address)==null?void 0:t.split("?");if(!s||s.length<2)return null;let o=s[0];o.endsWith("/")||(o=`${o}/`);const a=s==null?void 0:s[1],l=`application%5B0%5D=${n}&page=1&sort_field=views&sort_order=desc`;return`${o}search/?${a}&${l}`},Qce=Yce,Kce=()=>({createOrUpdate:async({alt:t,uri:e,blob:r,legend:n,parentId:i,application:s,visibility:o})=>{const a=/\/workspace\/document\/([0-9a-fA-F-]+)/,l=(e??"").match(a);if(l&&l.length===2){const u=l[1],c=await Me.workspace().searchDocuments({filter:"all",id:u,limit:1}),h=c.length?c[0].name:void 0;await Me.workspace().updateFile(u,r,{alt:t,legend:n,name:h});const f=(await Me.workspace().searchDocuments({filter:"all",id:u,limit:1}))[0];return{file:f,src:`/workspace/${f.public?"pub/":""}document/${u}`}}else{const u=await Me.workspace().saveFile(r,{application:s,parentId:i,visibility:o});return`/workspace/${u.public?"pub/":""}document/${u._id}`}},create:async(t,e)=>await Me.workspace().saveFile(t,e),remove:async t=>!t||Array.isArray(t)&&t.length===0?Promise.resolve():await Me.workspace().deleteFile(Array.isArray(t)?t:[t])}),ex=Kce,Zce=()=>{const t=T.useRef(null),[e,r]=T.useState(),{remove:n}=ex();return{ref:t,libraryMedia:e,setLibraryMedia:r,onCancel:async i=>{var s,o;(s=t.current)!=null&&s.type&&i&&i.length>0&&await n(i),(o=t.current)==null||o.hide()},onSuccess:i=>{var s,o,a,l;let u;switch((s=t.current)==null?void 0:s.type){case"video":{if(typeof i=="object")u=i[0];else{const c=new DOMParser().parseFromString(i,"text/html").body.firstChild,h=c==null?void 0:c.getAttribute("src");(o=t.current)==null||o.hide(),u=h}break}case"embedder":{const c=new DOMParser().parseFromString(i,"text/html").body.firstChild,h=c==null?void 0:c.getAttribute("src");(a=t.current)==null||a.hide(),u=h;break}case"audio":{i.length===void 0?u=i:u=i[0];break}case"hyperlink":{u=i;break}case"image":{u=`/workspace/document/${i[0]._id}`;break}default:u=i[0]}(l=t.current)==null||l.hide(),r(u)},onTabChange:async(i,s)=>{var o;(o=t.current)!=null&&o.type&&s&&s.length>0&&await n(s)}}},a8=Zce,Jce=t=>{const[e,r]=T.useState([]);T.useEffect(()=>{(async()=>(await Eb.initialize(Me,t),await Eb.registerBehaviours(t),r(Eb.resourceProducingApps)))()},[]);const n=T.useCallback(async i=>{const[s]=i.types;return await Me.behaviour(t,s).loadResources(i)},[t]);return{resourceApplications:e,loadResources:n}},ede=(t,e="media-library")=>{const[r,n]=T.useState({}),{browser:i,device:s}=B6(navigator.userAgent),{create:o}=ex(),a=T.useCallback(y=>r[pf(y)],[r]),l=(y,v)=>{n(x=>{const b=pf(y);return{...x,[b]:v}})},u=y=>{n(v=>{const x=pf(y),{[x]:b,..._}=v;return _})};async function c(y,v){l(y,"loading");try{let x;return e==="media-library"&&y.type.includes("video")?x=await f(y,{filename:y.name,...v}):x=await o(y,{application:e,visibility:t}),l(y,"success"),x}catch{return l(y,"error"),null}}async function h(y,v){l(y,"loading");try{let x;if(y.type.includes("video"))x=await f(y,v);else throw new Error(Gk.NOT_SUPPORTED);return l(y,"success"),x}catch{return l(y,"error"),null}}const f=async(y,v)=>{const x={data:{device:s.type,browser:{name:i.name,version:i.version},url:window.location.hostname,file:y,filename:(v==null?void 0:v.filename)??"filename",weight:y.size},appCode:e,captation:!(y instanceof File),duration:(v==null?void 0:v.duration)??0},b=await Me.video().upload(x);if(b.state==="succeed")return{_id:b.videoworkspaceid,file:b.videoid,name:x.data.filename,eType:"file",eParent:"",children:[],created:new Date,_shared:[],_isShared:!1,owner:{userId:"",displayName:""}};throw b.state==="error"?new Error(b.code||"Error while uploading video"):new Error("Video encoding is still running")};function m(y,v,x){return pf(v,pf(y)),c(v,x)}return{getUploadStatus:a,setUploadStatus:l,clearUploadStatus:u,uploadFile:c,uploadAlternateFile:m,uploadBlob:h}},l8=ede,tde=({handleOnChange:t,visibility:e,application:r})=>{const[n,i]=T.useState([]),[s,o]=T.useState(void 0),{files:a,deleteFile:l,replaceFileAt:u}=hA(),{remove:c,createOrUpdate:h}=ex(),{getUploadStatus:f,setUploadStatus:m,clearUploadStatus:y,uploadFile:v,uploadAlternateFile:x}=l8(e,r),b=T.useCallback(P=>{P.forEach(async(I,M)=>{if(I==null)return;let N;if(I.type.startsWith("image"))try{const z=await $q.resizeImageFile(I);N=await x(I,z),u(M,z)}catch(z){console.error(z)}N||(N=await v(I)),N&&i(z=>[...z,N])})},[x,v,u]);T.useEffect(()=>{let P=0;const I=a.map(M=>{if(P>=5)return null;const N=f(M);return N==="loading"&&P++,N?null:M});I.forEach(M=>M&&m(M,"idle")),b(I)},[a,n,f,m,b]),T.useEffect(()=>{const P=_(a,n);t(P)},[n]);const _=(P,I)=>{const M=P.reduce((N,z,j)=>(N[z.name]=j,N),{});return I.sort((N,z)=>M[N.name]-M[z.name])};async function w(P){const I=n.find(M=>M.name===P.name);I&&(await c(I),y(P),i(M=>M.filter(N=>N.name!==(I==null?void 0:I.name)))),l(P)}async function E({blob:P,legend:I,altText:M}){if(s)try{const N=await h({blob:P,legend:I,alt:M,uri:A(s)});N&&typeof N=="object"&&i(z=>z.map(j=>j._id===N.file._id?{...N.file}:j))}finally{o(void 0)}}const A=(P,I)=>{const M=`/workspace/${P!=null&&P.public?"pub/":""}document/${P==null?void 0:P._id}`;return P?I?Vue(M):M:""};return{files:a,getUploadStatus:f,clearUploadStatus:y,uploadedFiles:n,editingImage:s,setEditingImage:o,getUrl:A,updateImage:E,uploadFile:v,removeFile:w}},rde=tde;function wh(){const{user:t,userDescription:e}=yt(),{theme:r}=ba();function n(){let i=e==null?void 0:e.picture;return(!i||i==="no-avatar.jpg"||i==="no-avatar.svg")&&(i=`${r==null?void 0:r.basePath}/img/illustrations/no-avatar.svg`),i}return{user:t,avatar:n(),userDescription:e}}function O0(t,e,r,n){const i=Q6(),s=Wi("org.entcore.workspace.controllers.WorkspaceController|listDocuments"),o=Wi("org.entcore.workspace.controllers.WorkspaceController|listFolders");function a(h,f){switch(f.type){case"update":{const m=Ki(h,f.folderId);return m&&(m.children=f.subfolders.map(y=>({id:y._id||"",name:y.name})),m.files=f.files),{...h}}default:throw Error("[useWorkspaceSearch] Unknown action type: "+f.type)}}const[l,u]=T.useReducer(a,{id:t,name:e,section:!0}),c=T.useCallback(async h=>{var f;if(s&&o){const m=h===t?"":h,y=i!=null&&i.listWorkspaceDocuments?await((f=i==null?void 0:i.listWorkspaceDocuments)==null?void 0:f.call(i).then(b=>b.map(_=>{const w={..._,_id:""+Math.round(Math.random()*9999)};return w.name=_.eType=="folder"?"folder id="+w._id:"file id="+w._id,w}))):await Me.workspace().listDocuments(r,m),v=[],x=[];y.filter(b=>{if(!n||b.eType==="folder")return!0;const _=Vk.getRole(b);return typeof n=="string"?n===_:Array.isArray(n)?n.findIndex(w=>w===_)>=0:!1}).forEach(b=>{b.eType==="folder"?v.push(b):x.push(b)}),u({folderId:h,subfolders:v,files:x,type:"update"})}},[s,o,t,i,r,n]);return{root:l,loadContent:c}}function nde(){const[t,e]=T.useState("pending"),{currentApp:r}=yt();T.useEffect(()=>{n()},[]);const n=async()=>{if(!r){e("[Xiti] Error, currentApp is not defined.");return}try{await Me.analytics().trackPageLoad(window.location.pathname,r),console.info(`[Xiti] Success tracking page ${window.location.pathname}`),e(`[Xiti] Success tracking page ${window.location.pathname}`)}catch(i){console.error("[Xiti] Error Tracking Page Load",i),e(`[Xiti] Error Tracking Page Load: ${i}`)}};return{xitiStatus:t}}function ide(){const{currentLanguage:t}=yt(),{userDescription:e}=wh(),{isAdml:r}=o8(),{theme:n}=ba(),i=window.innerWidth<=768,s=Wi("net.atos.entng.support.controllers.DisplayController|view"),[o,a]=T.useState(""),[l,u]=T.useState(void 0),c=()=>{const h=o.split("/");let f="",m="";if(l!=null&&l.labels&&Object.keys(l==null?void 0:l.labels).length>0&&h.length>1){for(let y=1;y<h.length;y++)h[y].length>0&&h[y].match(/\d/)==null&&(f.length===0?f=h[y]:f=f+"/"+h[y]);l!=null&&l.labels&&Object.prototype.hasOwnProperty.call(l==null?void 0:l.labels,f)?m=l==null?void 0:l.labels[f]:l!=null&&l.default&&String(l.default).length>0&&(m=l==null?void 0:l.default)}else l!=null&&l.default&&String(l==null?void 0:l.default).length>0&&(m=l==null?void 0:l.default);if(h.includes("collaborativewall")&&h.includes("id")&&i&&window.zE("webWidget","hide"),m.includes("${adml}")&&(r?m=m.replace("${adml}","adml"):m=m.replace("/${adml}","")),m.includes("${profile}")){const y=e==null?void 0:e.profiles;m=m.replace("${profile}",y[0].toLowerCase())}m.includes("${theme")&&(n!=null&&n.is1d?m=m.replace("${theme}","1D"):m=m.replace("${theme}","2D")),window.zE("webWidget","helpCenter:setSuggestions",{labels:[m]})};return T.useEffect(()=>{window.location.pathname!==o&&a(window.location.pathname),!(l===void 0||Object.keys(l).length===0)&&c()},[window.location.pathname,l]),T.useEffect(()=>{document.getElementById("ze-snippet")||s===void 0||(async()=>{const h=await Me.http().get("/zendeskGuide/config");if(h&&h.key&&h.key!==""){const f=document.createElement("script");f.id="ze-snippet",f.src=`https://static.zdassets.com/ekr/snippet.js?key=${h.key}`,document.body.appendChild(f).onload=()=>{t==="es"?window.zE(function(){window.zE.setLocale("es-419")}):window.zE(function(){window.zE.setLocale("fr")}),Object.keys(h.module).length>0&&u(h.module),window.zE("webWidget","show"),window.zE("webWidget","updateSettings",{webWidget:{color:{theme:h.color||"#ffc400"},zIndex:3,launcher:{mobile:{labelVisible:!0}},contactForm:{suppress:!s},helpCenter:{messageButton:{"*":"Assistance ENT","es-419":"Asistencia ENT"}}}}),window.addEventListener("scroll",()=>{window.zE("webWidget","updateSettings",{webWidget:{launcher:{mobile:{labelVisible:window.scrollY<=5}}}})}),window.zE("webWidget:on","open",function(){s&&window.zE("webWidget","updateSettings",{webWidget:{contactForm:{suppress:!1}}})}),window.zE("webWidget:on","userEvent",function(m){const y=m.category,v=m.action,x=m.properties;v==="Contact Form Shown"&&y==="Zendesk Web Widget"&&x&&x.name==="contact-form"&&s&&(window.zE("webWidget","updateSettings",{webWidget:{contactForm:{suppress:!0}}}),window.zE("webWidget","close"),window.open("/support","_blank"))})}}})()},[s]),null}function sde(){const t=Wi("org.entcore.portal.controllers.PortalController|optionalFeatureCantoo");return T.useEffect(()=>{t&&!document.getElementById("cantoo-edifice-script")&&(async()=>{const e=await Me.http().get("/optionalFeature/cantoo");if(e&&e.scriptPath){const r=document.createElement("script");r.id="cantoo-edifice-script",r.src=e.scriptPath,r.async=!0,document.body.appendChild(r)}})()},[t]),null}function y_({formData:t,errorMessage:e}){const{t:r}=we(),n=i=>i==null?void 0:i.match(/^\s/);return e==="CONTENT_TOO_LARGE"?g.jsxs(g.Fragment,{children:[g.jsx("h3",{className:"pt-24",children:r("bpr.form.publication.response.error.title")}),g.jsx("p",{className:"pt-24 pb-24",children:g.jsx("strong",{children:r("bpr.form.publication.response.error.content_too_large")})})]}):g.jsxs(g.Fragment,{children:[g.jsx("h3",{className:"pt-24",children:r("bpr.form.publication.response.error.title")}),g.jsx("p",{className:"pt-24 pb-24",children:g.jsx("strong",{children:r("bpr.form.publication.response.error.content")})}),g.jsxs("ul",{children:[n(t==null?void 0:t.title)&&g.jsx("li",{className:"pt-2 pb-2",children:g.jsx("strong",{children:r("bpr.form.publication.response.empty.title")})}),n(t==null?void 0:t.description)&&g.jsx("li",{className:"pt-2 pb-2",children:g.jsx("strong",{children:r("bpr.form.publication.response.empty.description")})})]})]})}function ode({result:t}){const{t:e}=we();return g.jsxs(g.Fragment,{children:[g.jsx("h3",{className:"pt-24",children:e("bpr.form.publication.response.success.title")}),g.jsx("p",{className:"pt-24",children:e("bpr.form.publication.response.success.content.1")}),g.jsx("p",{className:"pt-24",children:e("bpr.form.publication.response.success.content.2")}),t.details.front_url&&g.jsx("p",{className:"pt-24 pb-24",children:g.jsx("a",{className:"button right-magnet",href:t.details.front_url,target:"_blank",rel:"noreferrer",children:e("bpr.form.publication.response.success.button")})})]})}function ade({onSuccess:t,resource:e}){const{user:r,appCode:n}=yt(),i=en(),[s,o]=T.useState((e==null?void 0:e.thumbnail)||"");T.useEffect(()=>{o(e==null?void 0:e.thumbnail)},[e]);const{control:a,register:l,watch:u,setValue:c,handleSubmit:h,formState:{errors:f,isSubmitting:m,isDirty:y,isValid:v}}=OT({mode:"onChange"}),[x,b]=T.useState([]),[_,w]=T.useState([]),E=(A,P,I)=>{let M=[...P];const N=M.findIndex(z=>z===A);P.includes(A)?M=P.filter((z,j)=>j!==N):M=[...P,A],I(M)};return{control:a,cover:s,formState:{errors:f,isSubmitting:m,isDirty:y,isValid:v},handleDeleteImage:()=>o(""),handlePublish:async A=>{const P=r?r==null?void 0:r.userId:"";try{let I=new Blob;typeof s=="string"?I=await Me.http().get(s,{responseType:"blob"}):s?I=await Me.http().get(URL.createObjectURL(s),{responseType:"blob"}):e!=null&&e.thumbnail&&(I=await Me.http().get(e==null?void 0:e.thumbnail,{responseType:"blob"}));const M=await Me.http().get(`/userbook/avatar/${P}?thumbnail=48x48`,{responseType:"blob"}),N=await Me.http().get(`/directory/user/${P}/attachment-school`,{responseType:"json"}),z=Z6[n],j={activityType:x,age:[A.ageMin,A.ageMax],application:z,cover:I,description:A.description,keyWords:A.keyWords,language:A.language,licence:"CC-BY",resourceId:e==null?void 0:e.assetId,resourceEntId:e==null?void 0:e.assetId,subjectArea:_,teacherAvatar:M,title:A.title,userId:P,userStructureName:N.name||(r==null?void 0:r.structureNames[0])},H=await Me.resource(n).publish(j);H.success?i.success(g.jsx(ode,{result:H}),{duration:1e4}):H.message==="CONTENT_TOO_LARGE"?i.error(g.jsx(y_,{errorMessage:H.message})):i.error(g.jsx(y_,{formData:A})),t==null||t()}catch(I){console.error(I),i.error(g.jsx(y_,{formData:A}))}},handleSubmit:h,handleUploadImage:A=>o(A),register:l,selectActivities:A=>{E(A,x,b)},selectedActivities:x,selectedSubjectAreas:_,selectSubjects:A=>{E(A,_,w)},setValue:c,watch:u}}const lde=(t,e)=>{const[r,n]=T.useState(null);return T.useEffect(()=>{if(e===""){console.warn("resourceId must be an assetId and not an empty string");return}(async()=>{try{const i=await Me.resource(t).searchResource({application:t,id:e});n(i)}catch(i){console.error(i)}})()},[]),r},mA=lde,ude=({addButtonLabel:t="Add image",deleteButtonLabel:e="Delete image",src:r,className:n,mediaLibraryRef:i,libraryMedia:s,app:o,onUploadImage:a,onDeleteImage:l})=>{const[u,c]=T.useState(r||"");T.useEffect(()=>{s&&(c(s),a(s))},[s]);const h=()=>{var y;(y=i.current)==null||y.show("image")},f=()=>{c(""),l()},m=Re("image-input",n);return g.jsxs("div",{id:"image-input",className:m,children:[g.jsxs("div",{className:"image-input-actions gap-8",children:[g.jsx(Ro,{"aria-label":t,color:"tertiary",icon:g.jsx(q$,{}),onClick:h,type:"button",variant:"ghost"}),g.jsx(Ro,{"aria-label":e,color:"danger",disabled:!u,icon:g.jsx(LN,{width:"20",height:"20"}),onClick:f,type:"button",variant:"ghost"})]}),u?g.jsx(rc,{alt:"",src:u,size:"xl"}):g.jsx(ya,{app:o,iconFit:"ratio",size:"160",variant:"rounded"})]})},u8=ude,cde=({recordState:t,playState:e,recordTime:r,audioTime:n,maxDuration:i})=>g.jsxs("div",{className:"audio-recorder-time my-16 mx-auto",children:[e==="IDLE"&&g.jsxs("div",{className:"d-flex align-items-center",children:[t==="PAUSED"?g.jsx(FT,{width:12,height:12,className:"me-8 text-danger"}):g.jsx(Zv,{width:12,height:12,className:"me-8 text-danger"}),pl(t!=="IDLE"?r:0)+" / "+pl(i)]}),e!=="IDLE"&&g.jsxs("div",{className:"d-flex align-items-center mx-auto",children:[g.jsx(c1,{width:12,height:12,className:"me-8"}),pl(n*1e3)," /",pl(r)]})]}),dde=cde;function hde(t,e,r=!1,n="protected",i="media-library"){var s;function o(q,re){return{...q,...re.updatedState}}const[{recordState:a,playState:l,micStream:u,micStreamAudioSourceNode:c,audioWorkletNode:h,audioContext:f,encoderWorker:m,maxDuration:y,recordTime:v,isEncoding:x},b]=T.useReducer(o,{recordState:"IDLE",isEncoding:!1,playState:"IDLE",recordTime:0,maxDuration:180}),_=T.useRef(null),w=T.useRef(null),E=T.useRef(),A=T.useRef(),{t:P}=we(),{create:I}=ex(),M=128,N=48e3;T.useEffect(()=>{const q=new Worker("/infra/public/js/audioEncoder.js");return b({type:"update",updatedState:{encoderWorker:q}}),q.postMessage(["init",(f==null?void 0:f.sampleRate)||N]),()=>{j(),q.terminate()}},[]);const z=q=>{var re,ue;const le=q.data.inputs[0][0];let me=q.data.inputs[0][1];(!me||me.filter(xe=>xe!==void 0).length===0)&&(me=le),(re=E.current)==null||re.push(le),(ue=A.current)==null||ue.push(me)},j=T.useCallback(()=>{u==null||u.getTracks().forEach(q=>q.stop()),c==null||c.disconnect(),h==null||h.port.removeEventListener("message",z),h==null||h.port.close(),h==null||h.disconnect(),f==null||f.close()},[f,h,u,c]),H=async()=>{const q=await navigator.mediaDevices.getUserMedia({audio:!0}),re=new AudioContext({sampleRate:N}),ue=re.createMediaStreamSource(q);try{await re.audioWorklet.addModule("/infra/public/js/audio-recorder-processor.js")}catch(me){console.error(me)}const le=new AudioWorkletNode(re,"audio-recorder-processor");le.port.addEventListener("message",z),b({type:"update",updatedState:{micStream:q,micStreamAudioSourceNode:ue,audioContext:re,recordTime:0,audioWorkletNode:le,recordState:"RECORDING",playState:"IDLE"}}),A.current=[],E.current=[],le.port.start(),ue.connect(le),le.connect(re.destination)},F=T.useCallback(async()=>{w.current&&(w.current.currentTime=0,w.current.pause()),a==="PAUSED"?(b({type:"update",updatedState:{recordState:"RECORDING",playState:"IDLE"}}),f==null||f.resume(),e==null||e(void 0)):H()},[a,f,w]),L=T.useCallback(()=>{b({type:"update",updatedState:{recordState:"PAUSED",playState:"IDLE",isEncoding:!0}}),f==null||f.suspend(),m&&E.current&&A.current&&(m.postMessage(["wav",A.current,E.current,A.current.length*M]),m.onmessage=q=>{const re=window.URL.createObjectURL(q.data);b({type:"update",updatedState:{isEncoding:!1}}),w.current&&(w.current.src=re),e&&e(re)})},[f,m,e]),O=T.useCallback(()=>{var q;b({type:"update",updatedState:{playState:"PLAYING"}}),((q=w==null?void 0:w.current)!=null&&q.currentTime||w.current)&&w.current.play()},[w]),$=T.useCallback(()=>{var q;(q=w==null?void 0:w.current)==null||q.pause(),b({type:"update",updatedState:{playState:"PAUSED"}})},[w]),V=T.useCallback(()=>{j(),b({type:"update",updatedState:{playState:"IDLE",recordState:"IDLE"}}),A.current=[],E.current=[],e&&e(void 0)},[j,e]),k=T.useCallback(async()=>{var q;const re=(q=_.current)==null?void 0:q.value;if(!re){console.error("Audio name is required");return}return w.current&&(w.current.pause(),w.current.currentTime=0),b({type:"update",updatedState:{recordState:"SAVING",playState:"IDLE"}}),new Promise((ue,le)=>{try{m&&E.current&&A.current&&(m.postMessage(["mp3",A.current,E.current,A.current.length*M]),m.onmessage=async me=>{if(me.data instanceof Blob){const xe=new File([me.data],re,{type:"audio/mp3"}),_e=await I(xe,{application:i,visibility:n});_e&&t&&t(_e),b({type:"update",updatedState:{recordState:"SAVED"}}),ue(_e)}})}catch(me){b({type:"update",updatedState:{playState:"IDLE",recordState:"IDLE"}}),console.error("Error while saving",me),le()}})},[a,t,j]),U=T.useCallback(()=>{w!=null&&w.current&&(w.current.pause(),w.current.currentTime=0),b({type:"update",updatedState:{playState:"IDLE"}})},[w]),B=T.useCallback(()=>{b({type:"update",updatedState:{playState:"PAUSED"}}),w.current&&(w.current.currentTime=0)},[w]);T.useEffect(()=>{if(a==="RECORDING"&&f){const q=window.setInterval(()=>{b({type:"update",updatedState:{recordTime:f.currentTime}}),f.currentTime>=y&&(L(),window.clearInterval(q))},100);return()=>window.clearInterval(q)}},[f,L,y,a]);const X=P(a==="IDLE"?"bbm.audio.record.start":"bbm.audio.record.resume"),K=[{type:"icon",name:"record",visibility:a==="RECORDING"?"hide":"show",props:{icon:g.jsx(Zv,{}),color:"danger",disabled:a!=="IDLE"&&a!=="PAUSED"||v>=y,onClick:F,"aria-label":X},tooltip:X},{type:"icon",name:"recordPause",visibility:a==="RECORDING"?"show":"hide",props:{icon:g.jsx(xz,{}),color:"danger",disabled:a!=="RECORDING",onClick:L,"aria-label":P("bbm.audio.record.pause")},tooltip:P("bbm.audio.record.pause")},{type:"divider"},{type:"icon",name:"encoding",visibility:x?"show":"hide",props:{icon:g.jsx(UN,{style:{animation:"loading 1s infinite"}}),disabled:!0}},{type:"icon",name:"play",visibility:x||l==="PLAYING"?"hide":"show",props:{icon:g.jsx($N,{}),disabled:a!=="RECORDED"&&a!=="PAUSED"&&a!=="SAVED",onClick:O,"aria-label":P("bbm.audio.play.start")},tooltip:P("bbm.audio.play.start")},{type:"icon",name:"playPause",visibility:!x&&l==="PLAYING"?"show":"hide",props:{icon:g.jsx(FT,{}),onClick:$,"aria-label":P("bbm.audio.play.pause")},tooltip:P("bbm.audio.play.pause")},{type:"icon",name:"stop",props:{icon:g.jsx(Az,{}),disabled:l!=="PLAYING"&&l!=="PAUSED",onClick:U,"aria-label":P("bbm.audio.play.stop")},tooltip:P("bbm.audio.play.stop")},{type:"divider"},{type:"icon",name:"reset",props:{icon:g.jsx(VN,{}),disabled:a!=="RECORDED"&&a!=="PAUSED"&&l!=="PLAYING"&&l!=="PAUSED",onClick:V,"aria-label":P("bbm.audio.record.reset")},tooltip:P("bbm.audio.record.reset")},{type:"icon",name:"save",visibility:r?"hide":"show",props:{icon:g.jsx(jT,{}),disabled:a!=="RECORDED"&&a!=="PAUSED"&&l!=="PLAYING"&&l!=="PAUSED"||a==="SAVED"||!((s=_.current)!=null&&s.value),onClick:k,"aria-label":P("bbm.audio.record.save")},tooltip:P("bbm.audio.record.save")}];return{recordState:a,playState:l,audioContext:f,recordTime:v*1e3,maxDuration:y*1e3,audioRef:w,audioNameRef:_,toolbarItems:K,handlePlayEnded:B,handleSave:k}}const fde=T.forwardRef(({onSaveSuccess:t,onRecordUpdated:e,hideSaveAction:r=!1,visibility:n="protected"},i)=>{const{recordState:s,playState:o,recordTime:a,audioRef:l,audioNameRef:u,toolbarItems:c,maxDuration:h,handlePlayEnded:f,handleSave:m}=hde(t,e,r,n,"media-library"),{t:y}=we();T.useImperativeHandle(i,()=>({save:m}));const[v,x]=T.useState(0),b=Re({"text-danger":s==="RECORDING","text-success":o==="PLAYING"}),_=w=>{x(w.target.currentTime)};return g.jsxs("div",{className:"audio-recorder m-auto d-flex flex-column",children:[g.jsx(Ot,{id:"recordName",className:"mb-32",isRequired:!0,isReadOnly:s==="SAVED"||s==="SAVING",children:g.jsx(Kn,{type:"text",size:"sm",placeholder:y("bbm.audio.recorder.name"),ref:u,defaultValue:y("bbm.audio.recorder.defaultName")+new Date().toLocaleDateString()})}),g.jsx("div",{className:"audio-recorder-icon mx-auto",children:g.jsx(c1,{width:64,height:64,className:b})}),g.jsx(dde,{recordState:s,playState:o,recordTime:a,audioTime:v,maxDuration:h}),g.jsx("audio",{ref:l,onEnded:f,onTimeUpdate:_,children:g.jsx("track",{default:!0,kind:"captions",srcLang:"fr",src:""})}),g.jsx(pA,{items:c})]})}),pde=fde,mde=({onSuccess:t})=>{const{t:e}=we(),[r,n]=T.useState();function i(s){const o=s.target.value;n(o),o!=null&&o.length?t(o):t()}return g.jsxs("div",{className:"d-flex flex-column flex-fill",children:[g.jsx("div",{className:"mb-32",children:e("bbm.embed.description")}),g.jsxs("div",{className:"mb-8 d-flex",children:[g.jsx(CS,{className:"me-8"}),e("bbm.embed.title")]}),g.jsx(Ot,{id:"iframeContent",children:g.jsx(fA,{size:"md",height:"sm",placeholder:e("bbm.embed.placeholder"),onChange:i})}),!!(r!=null&&r.length)&&g.jsx("div",{className:"embed-preview mt-12",dangerouslySetInnerHTML:{__html:r}}),!(r!=null&&r.length)&&g.jsx("div",{className:"embed-preview mt-12 d-flex align-items-center justify-content-center bg-gray-300 text-black-50 rounded-3",children:g.jsx("strong",{children:e("bbm.embed.preview")})})]})},gde=mde,vde=({historyCount:t,handle:e})=>{const{t:r}=we(),[n,i]=T.useState(void 0),s=a=>{i(a),e(a)},o=[{type:"button",name:"undo",props:{color:"tertiary",leftIcon:g.jsx(zz,{}),"aria-label":r("cancel"),children:r("cancel"),onClick:()=>s("UNDO"),disabled:t===0},tooltip:r("cancel")},{type:"divider",name:"div-1"},{type:"button",name:"reset",props:{color:"tertiary",leftIcon:g.jsx(GN,{}),"aria-label":r("rotate"),children:r("rotate"),onClick:()=>s("ROTATE")},tooltip:r("rotate")},{type:"button",name:"crop",props:{color:"tertiary",leftIcon:g.jsx(H$,{}),"aria-label":r("crop"),children:r("crop"),className:n==="CROP"?"is-selected":"",onClick:()=>s("CROP")},tooltip:r("crop")},{type:"button",name:"blur",props:{color:"tertiary",leftIcon:g.jsx(D$,{}),"aria-label":r("blur"),children:r("blur"),className:n==="BLUR"?"is-selected":"",onClick:()=>s("BLUR")},tooltip:r("blur")}];return g.jsx(pA,{variant:"no-shadow",align:"left",isBlock:!0,items:o})},yde=vde,xde=100,Ak=100,bde=450,wde=64,_de=.5,Sde="image";function R2(t,{spriteName:e,imgDatasource:r,settings:n}){const i=URL.createObjectURL(r),s=new Image;return s.src=i,new Promise(o=>{s.onload=async()=>{await P2(t,{spriteName:e,imgDatasource:s,settings:n});const a=t==null?void 0:t.stage.getChildByName(e,!0);o(a)}})}async function P2(t,{spriteName:e,imgDatasource:r,settings:n}){if(t===void 0||t.stage===null)return;const i=t.stage.getChildByName(e,!0);i==null||i.removeFromParent();const s=r instanceof HTMLImageElement?Ee.from(r):r instanceof Ar?r:await Ee.fromURL(r),o=s instanceof Ar?s:Ar.from(s,{});if(o.interactive=!0,o.name=e,n){const{sprite:{anchor:a,position:l,scale:u,size:c,rotation:h},stage:{size:f}}=n,m=h%Math.PI!==0;o.anchor.x=a.x,o.anchor.y=a.y,o.position.x=l.x,o.position.y=l.y,o.scale.x=u.x,o.scale.y=u.y,o.width=m?c.height:c.width,o.height=m?c.width:c.height,t.stage.height=f.height,t.stage.width=f.width,t.renderer.resize(f.width,f.height),t.stage.addChild(o)}else t.stage.addChild(o),t.renderer.resize(o.width,o.height);Ede(t,o)}function Ede(t,e){var r;const n=t.view.parentNode,i=window.innerWidth-wde,s=Math.max((n==null?void 0:n.offsetWidth)??0,Ak),o=Tde({width:e.width,height:e.height},{width:{max:Math.min(s,i),min:Ak},height:{min:xde,max:window.innerHeight-bde}}),{height:a,width:l}=o;(r=t.view)!=null&&r.style&&(t.view.style.width=`${l}px`,t.view.style.height=`${a}px`)}function Tde(t,e){const{height:r,width:n}=t,i=n/r,{height:s,width:o}=e;let a=o.max,l=o.max/i;return n>o.max&&(a=o.max,l=a/i),l>s.max&&(l=s.max,a=l*i),a<o.min&&(a=o.min,l=a/i),l<s.min&&(l=s.min,a=l*i),{width:a,height:l}}function Cde(t){return new Promise((e,r)=>{var n;(n=t==null?void 0:t.view)!=null&&n.toBlob?t.view.toBlob(i=>{i?e(i):r("EXTRACT_FAILED")},"image/jpeg",_de):r("EXTRACT_FAILED")})}function Ade(t){var e,r;return(r=(e=t.view).toDataURL)==null?void 0:r.call(e)}function gA(t){return t.view.getBoundingClientRect?t.view.getBoundingClientRect().width/t.view.width:1}function I2(t){return new Promise((e,r)=>{var n,i;(i=(n=t.view).toBlob)==null||i.call(n,s=>{s?e(s):r("EXTRACT_FAIL")},"image/png",1)})}function Rde({application:t,sprite:e}){return{sprite:{rotation:e.rotation,size:{width:e.width,height:e.height},position:{x:e.position.x,y:e.position.y},scale:{x:e.scale.x,y:e.scale.y},anchor:{x:e.anchor.x,y:e.anchor.y}},stage:{size:{width:t.stage.width,height:t.stage.height},scale:{x:t.stage.scale.x,y:t.stage.scale.y}}}}function Pde({application:t,sprite:e,newHeight:r,newWidth:n}){e.anchor.x=.5,e.anchor.y=.5,e.position=new tt(n/2,r/2),t.stage.height=r,t.stage.width=n,t.renderer.resize(n,r)}const Ide=20,Mde=({maxSize:t=Ide,application:e,spriteName:r,onRestore:n})=>{const[i,s]=T.useState([]);T.useEffect(()=>{s([])},[e]);const o=async()=>{const u=i.pop();u&&(n(await u.backup,u),s(i.filter(c=>c!==u)))},a=u=>(u.length>t&&u.splice(0,u.length-t),u),l=async u=>{{if(!e)return;const c=e.stage.getChildByName(r,!0);if(c==null)return;const h=I2(e),f={backup:h,sprite:{rotation:c.rotation,size:{width:c.width,height:c.height},position:{x:c.position.x,y:c.position.y},scale:{x:c.scale.x,y:c.scale.y},anchor:{x:c.anchor.x,y:c.anchor.y}},stage:{size:{width:e.stage.width,height:e.stage.height},scale:{x:e.stage.scale.x,y:e.stage.scale.y}}};return s([...a(i),f]),await h,u.call(u)}};return{historyCount:i.length,restore:o,historize:l}},kde=Mde;function Ode(t,e,r){let n;const i=[];return function(s){i.push(e(s)),!n&&(n=setTimeout(()=>{const o=[...i];i.splice(0,i.length),r(o),n=void 0},t))}}const c8=20,Dde=50,vA="BRUSH_CURSOR";function Nde(t,e){const r=new Vi;for(const n of t)n&&(r.beginFill(16777215,1),r.drawCircle(n.x,n.y,c8/e),r.lineStyle(0),r.endFill());return r}function Lde(t,{spriteName:e}){return Ode(Dde,r=>t.stage.toLocal(r.global),r=>{const n=t.stage.getChildByName(e),i=gA(t);if(n==null)return;const s=new Ar(n.texture);s.filters=[new bj(8,4,Math.min(i,1))],s.width=n.width,s.height=n.height,s.scale=new tt(1,1),s.anchor=n.anchor,s.mask=Nde(r,i),n.addChild(s)})}function Fde(t){d8(t);const e=gA(t),r=new Vi;return r.lineStyle(Math.max(1,1/e),16711680),r.drawCircle(0,0,c8/e),r.endFill(),r.name=vA,t.stage.addChild(r),r}function d8(t){const e=t.stage.getChildByName(vA);e&&e.removeFromParent()}function jde(t){return e=>{if(!t)return;const r=t.stage.toLocal(e.global),n=t.stage.getChildByName(vA,!0);n&&(n.position.x=r.x,n.position.y=r.y)}}function Bde(t,{spriteName:e}){t.stage.interactive=!0;const r=Fde(t),n=jde(t);t.stage.on("pointermove",n);const i=Lde(t,{spriteName:e});t.stage.on("pointerdown",()=>{t.stage.on("pointermove",i)});const s=()=>{var o;(o=t==null?void 0:t.stage)==null||o.off("pointermove",i)};globalThis.addEventListener("pointerup",s),r.once("destroyed",()=>{globalThis.removeEventListener("pointerup",s)})}function Ude(t){d8(t),t.stage.off("pointerdown"),t.stage.off("pointermove")}const $de=["TOP_LEFT","TOP_RIGHT","BOTTOM_LEFT","BOTTOM_RIGHT"],D0=0,zde=20,yA="CROP_BACKGROUND_NAME",Rm="CROP_MASK_NAME";function M2(t){return"CROP_CORNER_"+t}function Hde(t,{spriteName:e}){h8(t);const r=t.stage.getChildByName(e);if(r==null)return;const n=r.getBounds(),i=t.renderer.generateTexture(t.stage).clone(),s=new Ar(i);s.height=n.height,s.width=n.width,s.position=new tt(0,0);const o=new Vi;o.beginFill(16777215,.5),o.drawRect(0,0,n.width,n.height),o.endFill(),o.name=yA,o.position=new tt(n.x,n.y);const a=new Vi;a.beginFill(0,1),a.drawRect(0,0,n.width-2*D0,n.height-2*D0),a.endFill(),a.position=new tt(D0,D0),a.name=Rm,s.mask=a,t.stage.addChild(o),o.addChild(a),o.addChild(s)}function h8(t){const e=t.stage.getChildByName(yA,!0);e==null||e.removeFromParent()}function f8(t,e){switch(t){case"TOP_LEFT":return{x:e.x,y:e.y,start:0,end:Math.PI/2};case"TOP_RIGHT":return{x:e.x+e.width,y:e.y,start:Math.PI/2,end:Math.PI};case"BOTTOM_LEFT":return{x:e.x,y:e.y+e.height,start:3*Math.PI/2,end:2*Math.PI};case"BOTTOM_RIGHT":return{x:e.x+e.width,y:e.y+e.height,start:Math.PI,end:3*Math.PI/2}}}function Vde(t){const e=t.stage.getChildByName(Rm,!0);e!=null&&$de.forEach(r=>{const n=t.stage.getChildByName(M2(r),!0);if(n==null)return;const i=f8(r,{height:e.height,width:e.width,x:e.x,y:e.y});n.position=new tt(i.x,i.y)})}function N0(t,e,{spriteName:r}){const n=t.stage.getChildByName(M2(e),!0),i=gA(t);n==null||n.removeFromParent();const s=t.stage.getChildByName(yA,!0),o=t.stage.getChildByName(Rm,!0);if(t.stage.getChildByName(r)==null||s===null||s===void 0||o===void 0||o===null)return;const l=f8(e,{height:o.height,width:o.width,x:o.x,y:o.y}),u=new Vi;u.beginFill(4960213,1),u.arc(0,0,zde/i,l.start,l.end),u.lineTo(0,0),u.endFill(),u.position=new tt(l.x,l.y),u.name=M2(e),u.interactive=!0;let c=!1;t.stage.on("pointermove",m=>{if(c===!1)return;const y=s.toLocal(m.global);u.position.x=y.x,u.position.y=y.y,Gde(t,e,y)});const h=()=>{c=!0};u.on("pointerdown",h);const f=()=>{c=!1};globalThis.addEventListener("pointerup",f),u.once("destroyed",()=>{u.off("pointerdown"),globalThis.removeEventListener("pointerup",f)}),s.addChild(u)}function Gde(t,e,r){const n=t.stage.getChildByName(Rm,!0);if(n==null)return;const i=n.position.x+n.width,s=n.position.y+n.height;switch(e){case"TOP_LEFT":{n.position.x=r.x,n.position.y=r.y,n.width=i-r.x,n.height=s-r.y;break}case"TOP_RIGHT":{n.position.y=r.y,n.width=r.x-n.position.x,n.height=s-r.y;break}case"BOTTOM_LEFT":{n.position.x=r.x,n.width=i-r.x,n.height=r.y-n.position.y;break}case"BOTTOM_RIGHT":{n.width=r.x-n.position.x,n.height=r.y-n.position.y;break}}Vde(t)}function Wde(t,{spriteName:e}){xA(t),t.stage.interactive=!0,t.stage.interactiveChildren=!0,Hde(t,{spriteName:e}),N0(t,"BOTTOM_LEFT",{spriteName:e}),N0(t,"BOTTOM_RIGHT",{spriteName:e}),N0(t,"TOP_LEFT",{spriteName:e}),N0(t,"TOP_RIGHT",{spriteName:e})}function xA(t){h8(t),t.stage.off("pointermove"),t.render()}function Xde(t){const e=t.stage.getChildByName(Rm,!0);if(e==null)return;xA(t);const r=t.renderer.generateTexture(t.stage).clone(),n=new Ar(r),i=e.getBounds(),s=new st(Math.floor(i.x),Math.floor(i.y),Math.floor(i.width),Math.floor(i.height)),o=new Ee(n.texture.baseTexture,s);return new Ar(o)}const qde=20,tx="CONTROL_NAME";function p8(t){return"RESIZE_CORNER_"+t}function Yde(t,e){const r=e.x,n=e.y;switch(t){case"TOP_LEFT":return{x:r,y:n,start:0,end:Math.PI/2};case"TOP_RIGHT":return{x:r+e.width,y:n,start:Math.PI/2,end:Math.PI};case"BOTTOM_LEFT":return{x:r,y:n+e.height,start:3*Math.PI/2,end:2*Math.PI};case"BOTTOM_RIGHT":return{x:r+e.width,y:n+e.height,start:Math.PI,end:3*Math.PI/2}}}function Qde(t,{container:e,cornerType:r,position:n,spriteName:i}){const s=t.stage.getChildByName(i,!0);if(s==null)return;const o=s.rotation%Math.PI!==0,a=o?s.height:s.width,l=o?s.width:s.height;switch(r){case"TOP_LEFT":{e.position=new tt(n.x,n.y),e.width=a-2*n.x,e.height=l-2*n.y;break}case"TOP_RIGHT":{const u=a-n.x;e.position=new tt(u,n.y),e.width=a-2*u,e.height=l-2*n.y;break}case"BOTTOM_LEFT":{const u=l-n.y;e.position=new tt(n.x,u),e.width=a-2*n.x,e.height=l-2*u;break}case"BOTTOM_RIGHT":{const u=l-n.y,c=a-n.x;e.position=new tt(c,u),e.width=a-2*c,e.height=l-2*u;break}}}function kf(t,e){const r=t.stage.getChildByName(p8(e),!0);r==null||r.removeFromParent()}function L0(t,e,{spriteName:r}){kf(t,e);const n=t.stage.getChildByName(r,!0),i=t.stage.getChildByName(tx,!0);if(n==null||i===null||i===void 0)return;const s=Yde(e,i),o=new Vi;o.beginFill(4960213,1),o.arc(0,0,qde,s.start,s.end),o.lineTo(0,0),o.endFill(),o.position=new tt(s.x,s.y),o.name=p8(e),o.interactive=!0;let a=!1;t.stage.on("pointermove",c=>{if(a===!1)return;const h=t.stage.toLocal(c.global);Qde(t,{cornerType:e,position:h,container:i,spriteName:r})});const l=()=>{a=!1};globalThis.addEventListener("pointerup",l),o.once("destroyed",()=>{o.off("pointerdown"),globalThis.removeEventListener("pointerup",l)});const u=()=>{a=!0};o.on("pointerdown",u),i.addChild(o)}function Kde(t,e){m8(t);const r=t.stage.getChildByName(e,!0);if(r==null)return;const n=t.renderer.generateTexture(t.stage),i=new Ar(n);t.stage.children.forEach(o=>{o.alpha=0});const s=new Vi;s.drawRect(0,0,r.width,r.height),s.name=tx,s.interactive=!0,s.interactiveChildren=!0,t.stage.interactive=!0,t.stage.interactiveChildren=!0,t.stage.addChild(s),s.addChild(i)}function m8(t){const e=t.stage.getChildByName(tx,!0);e==null||e.removeFromParent(),t.stage.children.forEach(r=>{r.alpha=1})}function Zde(t,e){Kde(t,e),L0(t,"BOTTOM_LEFT",{spriteName:e}),L0(t,"BOTTOM_RIGHT",{spriteName:e}),L0(t,"TOP_LEFT",{spriteName:e}),L0(t,"TOP_RIGHT",{spriteName:e})}function g8(t){m8(t),kf(t,"BOTTOM_LEFT"),kf(t,"BOTTOM_RIGHT"),kf(t,"TOP_LEFT"),kf(t,"TOP_RIGHT"),t.stage.off("pointermove")}function Jde(t,e){Zde(t,e)}function ehe(t){g8(t),t.stage.off("pointermove"),t.render()}function the(t){var e;const r=(e=t==null?void 0:t.stage)==null?void 0:e.getChildByName(tx,!0),n=r?{height:r.height,width:r.width}:void 0;if(g8(t),n){const i=t.renderer.generateTexture(t.stage).clone(),s=new Ar(i);return s.width=n.width,s.height=n.height,s}else return}async function rhe(t,e){const r=t==null?void 0:t.stage.getChildByName(e,!0);if(t&&r){if(!t)return;const n=await I2(t),i=await R2(t,{imgDatasource:n,spriteName:e,settings:Rde({application:t,sprite:r})});if(!i)return;let s,o;const a=t.view;a.style&&(s=a.style.maxHeight??"",o=a.style.visibility??"",a.style.maxHeight=`${a.clientHeight}px`,a.style.visibility="hidden"),i.rotation+=Math.PI/2,Pde({application:t,sprite:i,newHeight:i.width,newWidth:i.height}),t.render();const l=await I2(t);s!==void 0&&(a.style.maxHeight=s),o!==void 0&&(a.style.visibility=o),await R2(t,{imgDatasource:l,spriteName:e})}}function nhe({application:t,spriteName:e,onSave:r}){return{rotate:async()=>{t&&await rhe(t,e)},startCrop:()=>{t&&Wde(t,{spriteName:e})},stopCrop:n=>{if(t){if(n){const i=Xde(t);i&&r(i)}xA(t)}},startBlur:()=>{t&&Bde(t,{spriteName:e})},stopBlur:()=>{t&&Ude(t)},startResize:()=>{t&&Jde(t,e)},stopResize:n=>{if(t){if(n){const i=the(t);i&&r(i)}ehe(t)}}}}function ihe({imageSrc:t,spriteName:e=Sde}){const[r,n]=T.useState(void 0),[i,s]=T.useState(!0),{rotate:o,startBlur:a,startCrop:l,startResize:u,stopBlur:c,stopCrop:h,stopResize:f}=nhe({spriteName:e,application:r,onSave(_){r&&P2(r,{imgDatasource:_,spriteName:e})}}),m=()=>r?Cde(r):Promise.resolve(void 0),y=()=>{if(r)return Ade(r)},{restore:v,historize:x,historyCount:b}=kde({application:r,spriteName:e,onRestore(_,w){r&&R2(r,{imgDatasource:_,spriteName:e,settings:w})}});return T.useEffect(()=>{r&&(s(!0),P2(r,{spriteName:e,imgDatasource:t}).finally(()=>s(!1)))},[r,t,e]),{historyCount:b,setApplication:n,restore:v,stopCrop:h,stopBlur:c,stopResize:f,startResize:async()=>{s(!0),await x(u),s(!1)},startCrop:async()=>{s(!0),await x(l),s(!1)},startBlur:async()=>{s(!0),await x(a),s(!1)},rotate:async()=>{s(!0),await x(o),s(!1)},toBlob:m,toDataURL:y,loading:i}}const she=({altText:t,legend:e,image:r,isOpen:n,onCancel:i,onError:s,onSave:o})=>{const{t:a}=we(),[l,u]=T.useState(void 0),[c,h]=T.useState(!1),[f,m]=T.useState(t??""),[y,v]=T.useState(e??""),[x,b]=T.useState(!1),{toBlob:_,setApplication:w,startBlur:E,stopBlur:A,restore:P,rotate:I,startCrop:M,stopCrop:N,startResize:z,stopResize:j,historyCount:H,loading:F}=ihe({imageSrc:r}),L=()=>{A(),N(l==="CROP"),j(l==="RESIZE")},O=async()=>{try{h(!0),L();const k=await _();k&&await o({blob:k,legend:y,altText:f})}catch(k){s==null||s(`${k}`)}finally{h(!1)}},$=()=>{i()},V=async k=>{switch(L(),u(k),b(!0),k){case"ROTATE":{await I();break}case"UNDO":{await P();break}case"CROP":{M();break}case"RESIZE":{await z();break}case"BLUR":{await E();break}}};return g.jsxs(Ye,{id:"image-editor",isOpen:n,onModalClose:$,size:"lg",children:[g.jsx(Ye.Header,{onModalClose:$,children:g.jsx("span",{className:"h2",children:a("imageeditor.title")})}),g.jsx(Ye.Body,{className:"d-flex flex-column align-items-center",children:g.jsxs("div",{className:"d-flex flex-column gap-12 w-100 flex-grow-1",children:[g.jsx(yde,{handle:V,historyCount:H}),g.jsxs("div",{className:"position-relative d-flex flex-column align-items-center justify-content-center flex-grow-1 w-100 image-editor",children:[g.jsx(lre.Stage,{onMount:k=>w(k),options:{preserveDrawingBuffer:!0,backgroundAlpha:0,resolution:1}}),!!F&&g.jsx("div",{className:"position-absolute top-0 start-0 bottom-0 end-0 m-10 d-flex align-items-center justify-content-center bg-black opacity-25",children:g.jsx(fr,{})})]}),g.jsxs("div",{className:"d-flex flex-column flex-md-row m-10 gap-12 w-100",children:[g.jsxs(Ot,{id:"alt",className:"flex-grow-1",children:[g.jsx(Gi,{children:a("alttext")}),g.jsx(Kn,{value:f,onChange:k=>{b(!0),m(k.target.value)},placeholder:a("alttext.help"),size:"md",type:"text"})]}),g.jsxs(Ot,{id:"legend",className:"flex-grow-1",children:[g.jsx(Gi,{children:a("legend")}),g.jsx(Kn,{value:y,onChange:k=>{b(!0),v(k.target.value)},placeholder:a("legend.help"),size:"md",type:"text"})]})]})]})}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{color:"tertiary",onClick:$,type:"button",variant:"ghost",children:a("imageeditor.cancel")}),g.jsx(it,{color:"primary",onClick:O,type:"button",variant:"filled",isLoading:c,disabled:c||!x,children:a("imageeditor.save")})]})]})},ohe=she,ahe=({doc:t,isClickable:e=!0,isSelectable:r=!1,isSelected:n=!1,onClick:i,className:s})=>{const{fromNow:o}=IL(),{fromDate:a}=T.useMemo(()=>({fromDate:o(t.modifiedAt)}),[o,t]);return g.jsx(tr,{className:Re("card-linker shadow-none",s),isClickable:e,isSelectable:r,isSelected:n,onClick:i,children:g.jsxs(tr.Body,{space:"8",children:[g.jsx("div",{className:"card-image ps-8 pe-4",children:t.thumbnail&&t.thumbnail.length>0?g.jsx(wo,{alt:"",height:48,width:48,src:t.thumbnail,objectFit:"cover",className:"rounded h-full",style:{aspectRatio:1/1}}):g.jsx(ya,{app:t.application,iconFit:"ratio",size:"48",variant:"rounded"})}),g.jsxs("div",{className:"w-75",children:[g.jsx(tr.Text,{children:t.name}),g.jsx(tr.Text,{className:"text-black-50",children:t==null?void 0:t.creatorName})]}),g.jsx("div",{className:"d-none d-md-block text-black-50 ps-4 pe-8",children:g.jsx(tr.Text,{children:a})}),t.shared&&g.jsx("div",{className:"ps-4 pe-8",children:g.jsx(BT,{width:"20",height:"20"})})]})})},lhe=ahe,uhe=({appCode:t,defaultAppCode:e,defaultResourceId:r,onChange:n,onSelect:i,multiple:s=!0,resourceList:o,applicationList:a,showApplicationSelector:l=!0})=>{const{t:u}=we(),{theme:c}=ba(),[h]=Pn(),{resourceApplications:f,loadResources:m}=Jce(t),[y,v]=T.useState(),[x,b]=T.useState(),[_,w]=T.useState(),E=sA(_||"",500),[A,P]=T.useState([]),I=T.useCallback((k,U)=>{var B,X,K;if(!U)return!0;const q=(U==null?void 0:U.toLowerCase())||"";return((B=k.name)==null?void 0:B.toLowerCase().includes(q))||((X=k.creatorName)==null?void 0:X.toLowerCase().includes(q))||((K=k.description)==null?void 0:K.toLowerCase().includes(q))},[]),M=T.useCallback(k=>k.sort((U,B)=>U.modifiedAt<B.modifiedAt?1:-1),[]),N=T.useCallback(k=>{async function U(){if(o){const B=o.filter(X=>I(X,k));P(M(B));return}else if(x)try{const B=(await m({application:x.application,search:k,types:[x.application],filters:{},pagination:{startIdx:0,pageSize:300}})).filter(X=>I(X,k));P(M(B));return}catch{}P([])}U()},[m,x,I,M,o]),[z,j]=T.useState([]),H=k=>{n==null||n(k),b(k)},F=k=>{const U=k.target.value;w(U.toString())},L=T.useCallback(k=>{N(_),k.stopPropagation(),k.preventDefault()},[N,_]),O=T.useCallback(k=>z.findIndex(U=>U.assetId===k),[z]),$=T.useCallback(k=>{j(s?U=>[...U,k]:[k])},[j,s]),V=T.useCallback(k=>{const U=O(k.assetId);U<0?$(k):j(z.filter((B,X)=>X!==U))},[O,$,z]);return T.useEffect(()=>{(async()=>{if(a){v(a.sort((B,X)=>B.displayName.localeCompare(X.displayName)));return}const k=f.map(B=>Me.session().getWebApp(B)),U=await Promise.all(k);v(f.map((B,X)=>{var K;return{application:B,displayName:u(((K=U[X])==null?void 0:K.displayName)??B),icon:g.jsx(ya,{app:U[X],size:"24"})}}).sort((B,X)=>B.displayName.localeCompare(X.displayName)))})()},[f,u,a]),T.useEffect(()=>{N(E)},[N,E]),T.useEffect(()=>{i==null||i(z)},[z]),T.useEffect(()=>{var k;const U=e??((a==null?void 0:a.length)===1&&((k=a==null?void 0:a[0])==null?void 0:k.application));if(U){const B=y==null?void 0:y.find(X=>U===X.application);b(B),N("")}},[y,e]),T.useEffect(()=>{if(r&&O(r)<0){const k=A==null?void 0:A.find(U=>r===U.assetId);k&&$(k)}},[A]),g.jsxs("div",{className:"d-flex flex-column flex-fill overflow-hidden",children:[g.jsxs("div",{className:"search d-flex bg-light rounded-top border border-bottom-0",children:[l&&g.jsx("div",{className:"flex-shrink-1 px-8 py-12 border-end",children:g.jsxs(xt,{overflow:!0,children:[g.jsx(xt.Trigger,{icon:g.jsx("div",{className:"pe-8",children:(x==null?void 0:x.icon)||g.jsx(NN,{})}),label:u((x==null?void 0:x.displayName)||"bbm.linker.int.choose"),variant:"ghost",size:"md"}),g.jsx(xt.Menu,{children:y==null?void 0:y.map(k=>g.jsx(xt.Item,{icon:k.icon,onClick:()=>H(k),children:k.displayName},k.application))})]})}),g.jsx("div",{className:"flex-grow-1 align-self-center",children:g.jsx("form",{className:"gap-16 d-flex w-100 align-items-center px-16 py-8",onSubmit:L,children:g.jsx(s8,{isVariant:!0,placeholder:u("search"),size:"lg",className:"w-100",disabled:!x,onChange:F})})})]}),g.jsxs("div",{className:"internal-linker flex-grow-1 w-100 rounded-bottom border gap-0 overflow-auto",children:[x&&A&&A.length>0&&g.jsx("div",{children:A.map(k=>{const U=z.findIndex(B=>B.assetId===k.assetId)>=0;return g.jsx(lhe,{doc:k,isSelected:U,onClick:()=>V(k)},k.path)})}),x&&A&&A.length<=0&&g.jsx("div",{className:"d-flex justify-content-center mt-16",children:g.jsx(ha,{imageSrc:`${h}/${c==null?void 0:c.bootstrapVersion}/illu-empty-search-${x.application}.svg`,text:u("bbm.linker.int.notfound"),className:"mt-16"})}),!x&&g.jsx("div",{className:"d-flex justify-content-center mt-32",children:g.jsx(ha,{imageSrc:`${h}/${c==null?void 0:c.bootstrapVersion}/illu-empty-search.svg`,text:u("bbm.linker.int.empty"),className:"mt-32"})})]})]})},che=uhe,dhe=({link:t,onChange:e,multiNodeSelected:r=!1})=>{const{t:n}=we(),[i,s]=T.useState((t==null?void 0:t.text)||""),[o,a]=T.useState((t==null?void 0:t.url)||""),[l,u]=Cm(t?t.target==="_blank":!0);return T.useEffect(()=>{r&&t!=null&&t.text&&s(t.text.slice(0,20)+"...")},[r,t]),T.useEffect(()=>{if(!o.length){e==null||e();return}const c={url:o,text:r?t==null?void 0:t.text:i||o,target:l?"_blank":void 0};!Ek.isLocalURL(o)&&!Ek.startWithHttp(o)&&(c.url="http://"+o),e==null||e(c)},[i,o,l]),g.jsx(g.Fragment,{children:g.jsxs("div",{className:"d-flex flex-column flex-fill gap-24",children:[g.jsxs(Ot,{id:"linkText",isOptional:!0,children:[g.jsx(Gi,{children:n("bbm.linker.ext.text")}),g.jsx(Kn,{type:"text",placeholder:n("bbm.linker.ext.text.placeholder"),size:"md",disabled:r,value:i,onChange:c=>s(c.target.value)})]}),g.jsxs(Ot,{id:"linkUrl",isRequired:!0,children:[g.jsx(Gi,{children:n("bbm.linker.ext.url")}),g.jsx(Kn,{type:"text",placeholder:n("bbm.linker.ext.url.placeholder"),size:"md",value:o,onChange:c=>a(c.target.value)})]}),g.jsx(Tm,{label:n("bbm.linker.open.tab"),onChange:()=>u(),checked:l})]})})},hhe=dhe,v8=T.createContext(null);function Xl(){const t=T.useContext(v8);if(!t)throw new Error("Innertabs compound components cannot be rendered outside the MediaLibrary component");return t}const fhe=()=>{const{setResult:t,setPreSuccess:e,visibility:r}=Xl(),n=T.useRef(null);return g.jsx(pde,{ref:n,onRecordUpdated:i=>{i?(t(i),e(()=>n.current.save)):t()},onSaveSuccess:i=>{i&&t(i)},hideSaveAction:!0,visibility:r})},phe=({link:t,multiNodeSelected:e=!1})=>{const{setResult:r}=Xl();return g.jsx(hhe,{link:t,onChange:n=>{r(n)},multiNodeSelected:e})},mhe=()=>{const{setResult:t}=Xl();return g.jsx(gde,{onSuccess:e=>{e=e==null?void 0:e.replace(/<p /g,"<div ").replace(/\/p>/g,"/div>"),t(e)}})},ghe=({target:t,resourceId:e,appPrefix:r})=>{const{t:n}=we(),{setResult:i,setResultCounter:s,appCode:o,multiple:a}=Xl(),[l,u]=Cm(t==="_blank"),[c,h]=T.useState([]),f=m=>{h(m)};return T.useEffect(()=>{i({target:l?"_blank":void 0,resources:c}),c&&c.length?s(c.length):s(void 0)},[l,c]),g.jsxs("div",{className:"d-flex flex-column flex-fill gap-16 overflow-hidden",children:[g.jsx(che,{appCode:o,defaultAppCode:r,defaultResourceId:e,onSelect:f,multiple:a}),g.jsx(Tm,{className:"align-items-center",checked:l,label:n("bbm.linker.open.tab"),onChange:u})]})},vhe=(t,e)=>{if(t==0)return"0 octets";const r=1e3,n=e,i=["octets","Ko","Mo","Go"],s=Math.floor(Math.log(t)/Math.log(r));return parseFloat((t/Math.pow(r,s)).toFixed(n))+" "+i[s]},yhe=({onFilesChange:t,visibility:e="protected"})=>{const{files:r,uploadedFiles:n,getUploadStatus:i,uploadFile:s,removeFile:o,updateImage:a,editingImage:l,setEditingImage:u,getUrl:c}=rde({handleOnChange:t,application:"media-library",visibility:e}),h=T.useRef(new Map);T.useEffect(()=>{const y=h.current;return()=>{y.forEach(v=>URL.revokeObjectURL(v)),y.clear()}},[]);const f=y=>{const v=y.type.startsWith("image")?h.current.get(y.name):"";return h.current.has(y.name)||h.current.set(y.name,URL.createObjectURL(y)),{name:y.name,info:{type:y.type,weight:vhe(y.size||0,1)},src:v}},m=y=>{const v=h.current.get(y.name);v&&(URL.revokeObjectURL(v),h.current.delete(y.name)),o(y)};return g.jsxs(g.Fragment,{children:[r.map(y=>{const v=n.find(x=>x.name===y.name);return g.jsx(kue,{status:i(y),item:f(y),onEdit:()=>u(v),onRetry:()=>s(y),onDelete:()=>m(y)},y.name)}),l&&g.jsx(ohe,{altText:l.alt,legend:l.title,image:c(l,!0),isOpen:!!l,onCancel:()=>u(void 0),onSave:a,onError:console.error})]})},xhe=yhe,bhe=t=>{const e=[];switch(t){case"audio":e.push("audio/*");break;case"video":e.push("video/*");break;case"image":e.push("image/png"),e.push("image/jpeg"),e.push("image/webp"),e.push("image/gif"),e.push("image/avif");break}return e},whe=()=>{const{type:t,visibility:e,multiple:r,setResult:n,setResultCounter:i,setCancellable:s}=Xl(),o=a=>{a.length?(s(a),i(a.length),n(a)):(s([]),i(void 0),n(void 0))};return g.jsx("div",{className:"py-8 flex-grow-1",children:g.jsx(kce,{multiple:r,accept:bhe(t??"embedder"),children:g.jsx(xhe,{onFilesChange:o,visibility:e})})})},x_=9,b_=16,_he=T.forwardRef(({appCode:t,caption:e,onSuccess:r,onError:n,onRecordUpdated:i,hideSaveAction:s=!1},o)=>{const[a,l]=T.useState(18e4),[u,c]=T.useState([]),[h,f]=T.useState(!1),[m,y]=T.useState(!1),[v,x]=T.useState(!1),[b,_]=T.useState(!1),[w,E]=T.useState(!1),[A,P]=T.useState({audio:!0,video:{facingMode:"environment",aspectRatio:b_/x_}}),[I,M]=T.useState(),[N,z]=T.useState(""),[j,H]=T.useState([]),[F,L]=T.useState(),[O,$]=T.useState(0),[V,k]=T.useState(0),U=T.useRef(null),B=T.useRef(null),{uploadBlob:X}=l8(void 0,t),{device:K}=B6(navigator.userAgent);T.useImperativeHandle(o,()=>({save:de}));const{t:q}=we();T.useEffect(()=>{re(),ue()},[]),T.useEffect(()=>(I||le(A),()=>{I&&I.getTracks().forEach(Pe=>Pe.stop())}),[I]),T.useEffect(()=>{if(j.length&&!h&&U.current){const Pe=new Blob(j,{type:N});if(L(Pe),i){const Ke=window.URL.createObjectURL(Pe);i(Ke)}U.current.autoplay=!1,U.current.srcObject=null,U.current.src=window.URL.createObjectURL(Pe)}},[h,j]),T.useEffect(()=>{if(h){const Pe=Date.now(),Ke=window.setInterval(()=>$(Date.now()-Pe),500);return()=>{window.clearInterval(Ke)}}},[h]),T.useEffect(()=>{if(v){const Pe=window.setInterval(()=>k(Ke=>Ke+500),500);return()=>{window.clearInterval(Pe)}}},[v]);const re=async()=>{const Pe=await Me.video().getVideoConf();l((Pe.maxDuration??3)*60*1e3)},ue=async()=>{const Pe=(await navigator.mediaDevices.enumerateDevices()).filter(Ke=>Ke.kind==="videoinput");switch(K.type){case"mobile":case"tablet":{const Ke={deviceId:"environment",label:q("video.back.camera"),groupId:"",kind:"videoinput"},Rt={deviceId:"user",label:q("video.front.camera"),groupId:"",kind:"videoinput"};(Pe==null?void 0:Pe.length)>1?c([Ke,Rt]):c([Ke]);break}default:c(Pe);break}},le=async Pe=>{try{const Ke=await navigator.mediaDevices.getUserMedia(Pe);M(Ke),U.current&&(U.current.src&&(window.URL.revokeObjectURL(U.current.src),U.current.src=""),U.current.srcObject=Ke,U.current.autoplay=!0,U.current.volume=1,U.current.muted=!0)}catch(Ke){console.error(Ke)}},me=T.useCallback(()=>{f(!0),U&&U.current&&(U.current.muted=!0);const Pe=Gue();z(Pe),I&&(B.current=new MediaRecorder(I,{mimeType:Pe}),B.current.ondataavailable=({data:Ke})=>{Ke.size>0&&H(Rt=>[...Rt,Ke])},B.current.onerror=Ke=>console.error(Ke),B.current.start(1e3))},[I]),xe=T.useCallback(()=>{var Pe;f(!1),y(!0),((Pe=B.current)==null?void 0:Pe.state)==="recording"&&(B.current.requestData(),B.current.stop())},[B]),_e=T.useCallback(()=>{var Pe,Ke;U&&U.current&&(U.current.muted=!1),v?((Ke=U==null?void 0:U.current)==null||Ke.pause(),x(!1)):((Pe=U==null?void 0:U.current)==null||Pe.play(),x(!0))},[v]),Te=()=>{y(!1),f(!1),x(!1),E(!1),$(0),H([]),L(void 0),le(A),i&&i()},de=async()=>{var Pe;if((Pe=U==null?void 0:U.current)==null||Pe.pause(),_(!0),!F){console.error("Error while saving video: recorded video is undefined.");return}const Ke=await X(F,{duration:O});if(Ke!=null)return r==null||r([Ke]),_(!1),E(!0),[Ke];n("Error while uploading video"),_(!1),E(!0)},Be=()=>{x(!1),k(0),U.current&&(U.current.currentTime=0)},je=Pe=>{var Ke;const Rt=u.find(J=>J.label===Pe);let W={};Rt!=null&&Rt.deviceId?((Rt==null?void 0:Rt.deviceId)==="environment"||(Rt==null?void 0:Rt.deviceId)==="user"?W={audio:!0,video:{aspectRatio:b_/x_,facingMode:Rt==null?void 0:Rt.deviceId}}:W={audio:!0,video:{aspectRatio:b_/x_,deviceId:Rt.deviceId}},P(W),I&&(((Ke=B.current)==null?void 0:Ke.state)==="recording"&&(B.current.requestData(),B.current.stop()),I.getTracks().forEach(J=>J.stop()),M(void 0)),le(W)):console.error("Selected input device id is null")};T.useEffect(()=>{O>=a&&xe()},[O,xe]);const ut=[{type:"icon",name:"record",props:{icon:g.jsx(Zv,{color:h||m?"":"red"}),color:"danger",disabled:h||m||b,onClick:me,"aria-label":q("bbm.video.record.start")},tooltip:q("bbm.video.record.start")},{type:"icon",name:"stop",props:{icon:g.jsx(wz,{}),disabled:!h||m||b,onClick:xe,"aria-label":q("bbm.video.record.stop")},tooltip:q("bbm.video.record.stop")},{type:"icon",name:"play",visibility:v?"hide":"show",props:{icon:g.jsx($N,{}),disabled:!m||b,onClick:_e,"aria-label":q("bbm.video.play.start")},tooltip:q("bbm.video.play.start")},{type:"icon",name:"pause",visibility:v?"show":"hide",props:{icon:g.jsx(FT,{}),disabled:!m||b,onClick:_e,"aria-label":q("bbm.video.play.pause")},tooltip:q("bbm.video.play.pause")},{type:"divider"},{type:"icon",name:"reset",props:{icon:g.jsx(VN,{}),disabled:!m||b,onClick:Te,"aria-label":q("bbm.video.record.reset")},tooltip:q("bbm.video.record.reset")},{type:"icon",name:"save",visibility:s?"hide":"show",props:{icon:g.jsx(jT,{}),disabled:!m||b||w,onClick:de,"aria-label":q("bbm.video.record.save")},tooltip:q("bbm.video.record.save")}];return g.jsxs("div",{className:"video-recorder d-flex flex-fill flex-column align-items-center pb-8",children:[g.jsx("div",{className:"video-recorder-caption d-none d-md-block",children:e}),u.length>1&&g.jsx("div",{className:"video-recorder-devices mb-12",children:g.jsxs(Ot,{id:"selectInputDevice",children:[g.jsx(Gi,{className:"d-none d-md-block",children:q("bbm.video.record.select.devices.label")}),g.jsx(aA,{placeholderOption:q("bbm.video.record.select.devices.placeholder"),options:u.map(Pe=>Pe.label),onValueChange:je})]})}),g.jsxs("div",{className:"video-recorder-video-container position-relative align-self-stretch",children:[g.jsx("video",{ref:U,playsInline:!0,autoPlay:!0,controls:!1,muted:!0,onEnded:Be,className:"rounded",children:g.jsx("track",{default:!0,kind:"captions",srcLang:"fr",src:""})}),(h||m)&&g.jsxs("div",{className:"video-recorder-time d-flex align-items-center font-monospace fs-6 text-bg-dark rounded",children:[h&&g.jsxs(g.Fragment,{children:[g.jsx(Zv,{width:12,height:12,color:"red",className:"me-4"}),g.jsxs("span",{children:[pl(O),"/",pl(a)]})]}),m&&g.jsxs(g.Fragment,{children:[g.jsx(HN,{width:14,height:14,className:"me-4"}),g.jsxs("span",{children:[pl(V),"/",pl(O)]})]})]}),I&&g.jsx(pA,{items:ut,className:"position-absolute bottom-0 start-50 bg-white"})]}),b&&g.jsx(fr,{position:!1,caption:q("bbm.video.save.loader.caption")})]})}),She=_he,Ehe=()=>{const{appCode:t,setResult:e,setPreSuccess:r}=Xl(),{t:n}=we(),i=T.useRef(null),s=a=>{a?(e(a),r(()=>i.current.save)):e()},o=a=>{console.error(a)};return g.jsx(She,{ref:i,appCode:t,caption:n("bbm.video.caption"),onRecordUpdated:s,onError:o,hideSaveAction:!0})},The=({switchType:t,onSuccess:e})=>{const{t:r}=we(),[n,i]=T.useState(),[s,o]=T.useState(),[a,l]=T.useState(void 0),[u,c]=T.useState(),h=sA(n||"",300),f=T.useId(),[m]=Pn();T.useEffect(()=>{y()},[]),T.useEffect(()=>{if(u&&h){const _=Me.embedder().getProviderFromUrl(u,h);if(_){l(_);const w=Me.embedder().getEmbedCodeForProvider(_,h);o(w),e(w)}else l(void 0),e()}},[h,u]);const y=async()=>{const _=await Promise.all([Me.embedder().getDefault(),Me.embedder().getCustom()]).then(w=>w.flat());c(_)};function v(_){const w=_.currentTarget.value;i(w),e(w!=null&&w.length?w:void 0)}function x(){t==null||t("embedder")}const b=()=>h?a?g.jsxs("div",{className:"mx-auto mt-16",children:[g.jsxs("div",{className:"video-embed-provider d-flex align-items-center",children:[g.jsx(wo,{src:a.logo,alt:"Logo "+a.displayName,className:"video-embed-provider-logo"}),a.displayName]}),s&&g.jsx("div",{className:"video-embed-preview mt-12",dangerouslySetInnerHTML:{__html:s}})]}):g.jsxs("div",{className:"d-flex flex-column align-items-center m-16",children:[g.jsx(ha,{imageSrc:`${m}/emptyscreen/illu-error.svg`,title:r("bbm.video.previewError.title"),text:r("bbm.video.previewError.text")}),t&&g.jsxs(it,{variant:"ghost",color:"primary",onClick:x,className:"align-items-start mt-16",children:[r("bbm.video.useEmbedCode")," ",g.jsx(TS,{})]})]}):t&&g.jsx("div",{className:"d-flex my-16 align-items-start",children:g.jsxs(it,{variant:"ghost",color:"primary",onClick:x,className:"align-items-start",children:[r("bbm.video.useEmbedCode")," ",g.jsx(TS,{})]})});return g.jsxs("div",{className:"d-flex flex-column flex-fill video-embed",children:[g.jsxs("div",{className:"mb-8 d-flex",children:[g.jsx(LT,{className:"me-8"}),r("bbm.video.url.title")]}),g.jsx(Ot,{id:f,children:g.jsx(Kn,{size:"md",type:"text",placeholder:r("bbm.video.url.placeholder"),onChange:v})}),g.jsx(g.Fragment,{children:b()})]})},Che=The,Ahe=()=>{const{switchType:t,setResult:e}=Xl();return g.jsx(Che,{switchType:t,onSuccess:r=>{e(r)}})},Rhe=({roles:t,onSelect:e,multiple:r=!0,className:n,defaultFolder:i,showPublicFolder:s})=>{const{t:o}=we(),{root:a,loadContent:l}=O0("root",o("workspace.tree.owner"),"owner",t),{root:u,loadContent:c}=O0("root",o("workspace.tree.shared"),"shared",t),{root:h,loadContent:f}=O0("root",o("workspace.tree.protected"),"protected",t),{root:m,loadContent:y}=O0("root",o("workspace.tree.public"),"public",t),v=T.useRef(null),x=T.useRef(null),b=T.useRef(null),_=T.useRef(null),[w,E]=T.useState(()=>i==="public"?s?i:"protected":i==="protected"||i==="shared"?i:"owner"),[A,P]=T.useState(()=>i==="public"?s?m:h:i==="protected"?h:i==="shared"?u:a),[I,M]=T.useState(),[N,z]=T.useState(null),[j,H]=T.useState(["modified","desc"]),[F,L]=T.useState([]),O=T.useCallback(q=>{switch(q){case"owner":return{root:a,othersRef:[x,b,_]};case"shared":return{root:u,othersRef:[v,b,_]};case"protected":return{root:h,othersRef:[v,x,_]};case"public":return{root:m,othersRef:[v,x,b]};default:throw"no.root.node"}},[a,u,h,m]),$=T.useCallback(()=>{switch(w){case"owner":l(A.id);break;case"shared":c(A.id);break;case"protected":f(A.id);break;case"public":y(A.id);break;default:throw"no.way"}},[w,A.id,l,f,y,c]);function V(q,re){E(q);const{root:ue,othersRef:le}=O(q),me=K6(ue,xe=>xe.id===re);me&&(P(me),le.forEach(xe=>{var _e;return(_e=xe.current)==null?void 0:_e.unselectAll()}))}T.useEffect(()=>{var q;let re;switch(w){case"owner":re=v;break;case"shared":re=x;break;case"protected":re=b;break;case"public":re=_;break;default:return}(q=re==null?void 0:re.current)==null||q.select("root")},[w]),T.useEffect($,[$]),T.useEffect(()=>{if(A.files){let q=[].concat(A.files);N&&(q=q.filter(ue=>ue.name.indexOf(N)>=0));const re=j[0]==="name"?j[1]==="asc"?(ue,le)=>U(ue.name,le.name):(ue,le)=>U(le.name,ue.name):(ue,le)=>U(le.modified,ue.modified);M(()=>q.sort(re))}else M(void 0)},[A,a,h,u,m,N,j]);const k=T.useCallback(q=>{z(q.target.value)},[z]);function U(q,re){return q?re?q.localeCompare(re):1:-1}function B(){return j[0]==="name"?j[1]==="asc"?o("sort.order.alpha.asc"):o("sort.order.alpha.desc"):o("sort.order.modify.desc")}function X(q){let re=[...F];r?re.includes(q)?re=re.filter(ue=>ue._id!==q._id):re=[...re,q]:re=[q],L(re),e(re)}const K=Re("workspace flex-grow-1 gap-0",n);return g.jsxs(so,{className:K,children:[g.jsx(so.Col,{sm:"12",md:"3",xl:"4",className:"workspace-folders p-12 pt-0 gap-12",children:g.jsxs("div",{style:{position:"sticky",top:0,paddingTop:"1.2rem"},children:[g.jsx(dd,{ref:v,data:a,onTreeItemClick:q=>V("owner",q),onTreeItemUnfold:q=>V("owner",q)}),g.jsx(dd,{ref:x,data:u,onTreeItemClick:q=>V("shared",q),onTreeItemUnfold:q=>V("shared",q)}),g.jsx(dd,{ref:b,data:h,onTreeItemClick:q=>V("protected",q),onTreeItemUnfold:q=>V("protected",q)}),s&&g.jsx(dd,{ref:_,data:m,onTreeItemClick:q=>V("public",q),onTreeItemUnfold:q=>V("public",q)})]})}),g.jsx(so.Col,{sm:"12",md:"5",xl:"8",children:g.jsxs(so,{className:"flex-grow-1 gap-0",children:[g.jsxs(so.Col,{sm:"4",md:"8",xl:"12",children:[g.jsx("div",{className:"workspace-search px-16 py-8 ",children:g.jsx(s8,{isVariant:!0,className:"gap-16",onChange:k})}),g.jsxs("div",{className:"d-flex align-items-center justify-content-end px-8 py-4",children:[g.jsx("small",{className:"text-muted",children:o("workspace.search.order")}),g.jsxs(xt,{children:[g.jsx(xt.Trigger,{size:"sm",label:B(),variant:"ghost"}),g.jsxs(xt.Menu,{children:[g.jsx(xt.Item,{icon:g.jsx(Fz,{}),onClick:()=>H(["modified","desc"]),children:o("sort.order.modify.desc")}),g.jsx(xt.Item,{icon:g.jsx(Oz,{}),onClick:()=>H(["name","asc"]),children:o("sort.order.alpha.asc")}),g.jsx(xt.Item,{icon:g.jsx(Nz,{}),onClick:()=>H(["name","desc"]),children:o("sort.order.alpha.desc")})]})]})]})]}),g.jsx(so.Col,{sm:"4",md:"8",xl:"12",className:"p-8 gap-8",children:I?I.length!==0?g.jsx("div",{className:"grid grid-workspace",children:I.map(q=>{const re=F.includes(q);return g.jsx(Iue,{doc:q,isSelected:re,onClick:()=>X(q)},q._id)})}):g.jsx(ha,{imageSrc:"./assets/themes/edifice-bootstrap/images/emptyscreen/illu-trash.svg",text:o("workspace.empty.docSpace"),title:o("explorer.emptyScreen.trash.title")}):g.jsx(fr,{})})]})})]})},Phe=Rhe,Ihe=()=>{const{type:t,setResultCounter:e,setResult:r,multiple:n,visibility:i}=Xl();function s(){switch(t){case"image":return"img";case"audio":return"audio";case"video":return"video";default:return null}}function o(a){e(a.length),a.length?r(a):r()}return g.jsx(Phe,{roles:s(),onSelect:o,multiple:n,className:"border rounded overflow-y-auto",defaultFolder:i,showPublicFolder:i==="public"})},ja={Audio:fhe,Video:Ehe,Upload:whe,ExternalLink:phe,Workspace:Ihe,InternalLink:ghe,Iframe:mhe,VideoEmbedder:Ahe},Mhe=["audio-capture","video-capture","internal-link","external-link","iframe","upload","workspace","video-embedder"],w_={none:null,audio:{title:"bbm.audio.modal.title",defaultTab:"audio-capture"},video:{title:"bbm.video.modal.title",defaultTab:"video-capture"},image:{title:"bbm.image.modal.title",defaultTab:"workspace"},attachment:{title:"bbm.attachment.modal.title",defaultTab:"workspace"},hyperlink:{title:"bbm.link.modal.title",defaultTab:"linker"},embedder:{title:"bbm.embed.modal.title",defaultTab:"iframe"}},khe=T.forwardRef(({appCode:t,visibility:e,multiple:r,onSuccess:n,onCancel:i,onTabChange:s},o)=>{var a;const l=T.useRef(),u=T.useRef(null);T.useImperativeHandle(o,()=>({show:L,hide:O,showLink:$,type:m,...u.current})),qce({isDismissible:!0,duration:1/0});const{t:c}=we(),h=Wi("org.entcore.workspace.controllers.WorkspaceController|addDocument"),f=Wi("com.opendigitaleducation.video.controllers.VideoController|capture"),[m,y]=T.useState(null),v={workspace:{id:"workspace",icon:g.jsx(jN,{}),label:c("bbm.workspace"),content:g.jsx(ja.Workspace,{}),availableFor:["audio","video","image","attachment"],isEnable:null},upload:{id:"upload",icon:g.jsx(Mz,{}),label:c("bbm.device"),content:g.jsx(ja.Upload,{}),availableFor:["audio","video","image","attachment"],isEnable:()=>!!h},"video-capture":{id:"video-capture",icon:g.jsx(HN,{}),label:c("bbm.video"),content:g.jsx(ja.Video,{}),availableFor:["video"],isEnable:()=>!!f},"audio-capture":{id:"audio-capture",icon:g.jsx(c1,{}),label:c("bbm.audio"),content:g.jsx(ja.Audio,{}),availableFor:["audio"],isEnable:()=>!!h},"external-link":{id:"external-link",icon:g.jsx(LT,{}),label:c("bbm.linker.ext"),content:g.jsx(ja.ExternalLink,{...l.current}),availableFor:["hyperlink"],isEnable:null},"internal-link":{id:"internal-link",icon:g.jsx(NN,{}),label:c("bbm.linker.int"),content:g.jsx(ja.InternalLink,{...l.current}),availableFor:["hyperlink"],isEnable:null},iframe:{id:"iframe",icon:g.jsx(CS,{}),label:c("bbm.embed"),content:g.jsx(ja.Iframe,{}),availableFor:["embedder"],isEnable:null},"video-embedder":{id:"iframe",icon:g.jsx(CS,{}),label:c("bbm.embed"),content:g.jsx(ja.VideoEmbedder,{}),availableFor:["video"],isEnable:null}},x=T.useMemo(()=>Mhe.map(K=>v[K]).filter(K=>{var q;return((q=K.isEnable)==null?void 0:q.call(K))!==!1&&(K.availableFor.length===0||K.availableFor.includes(m))}),[m]),[b,_]=T.useState(),w=T.useMemo(()=>{const K=x.findIndex(q=>q.id===b);return 0>K||K>=x.length?0:K},[x,b]),[E,A]=T.useState(),[P,I]=T.useState(),[M,N]=T.useState([]),[z,j]=T.useState();function H(K){throw x.findIndex(q=>q.id===K)<0?"tab.not.visible":"not.implemented.yet"}function F(K){l.current=void 0,_(void 0),y(K)}const L=K=>{y(K)},O=()=>{y(null)},$=K=>{l.current=K,!("resourceId"in K||"appPrefix"in K)&&_("external-link"),y("hyperlink")};T.useEffect(()=>{var K,q;const re=m||"none";!b&&typeof((K=w_[re])==null?void 0:K.defaultTab)=="string"&&_((q=w_[re])==null?void 0:q.defaultTab)},[b,m]);const V=c(((a=w_[m??"none"])==null?void 0:a.title)??"bbm"),k=()=>{l.current=void 0,I(void 0),A(void 0),_(void 0),j(void 0),N([])},U=K=>{s==null||s(K,M),k()},B=T.useCallback(()=>{const K=async q=>{q instanceof Array&&["protected","public"].findIndex(re=>re===e)>=0&&(q=await Me.workspace().transferDocuments(q,t??"media-library",e)),n(q)};z?z().then(q=>{K(q)}):P&&K(P),k()},[z,P,n,e,t]),X=()=>{i(M),k()};return m&&g.jsx(v8.Provider,{value:{appCode:t,visibility:e,multiple:r,type:m,setResultCounter:A,setResult:I,setCancellable:K=>N([...K]),setVisibleTab:H,switchType:F,setPreSuccess:j},children:g.jsxs(Ye,{id:"media-library",isOpen:m!==null,onModalClose:X,size:"lg",viewport:!0,scrollable:!0,children:[g.jsx(Ye.Header,{onModalClose:X,children:V}),g.jsx(oa,{items:x,defaultId:x[w].id,onChange:U,children:K=>g.jsxs(g.Fragment,{children:[x.length>1&&g.jsx(oa.List,{className:"mt-16"}),g.jsx(Ye.Body,{className:"d-flex",children:g.jsx(oa.Panel,{currentItem:K,children:K==null?void 0:K.content})})]})}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{type:"button",color:"tertiary",variant:"ghost",onClick:X,children:c("cancel")}),g.jsx(it,{type:"button",color:"primary",variant:"filled",disabled:typeof P>"u",onClick:B,children:E&&E>1?c("addMultiple",{number:E}):c("add")})]})]})})}),y8=khe;function Ohe({isOpen:t,resourceId:e,onSuccess:r,onCancel:n}){const{appCode:i,currentApp:s}=yt(),{ref:o,libraryMedia:a,...l}=a8(),{t:u}=we(),c=mA(i,e),{control:h,cover:f,formState:{isDirty:m,isValid:y,isSubmitting:v},handleDeleteImage:x,handleSubmit:b,handleUploadImage:_,handlePublish:w,register:E,selectActivities:A,selectedActivities:P,selectedSubjectAreas:I,selectSubjects:M}=ade({resource:c,onSuccess:r});return c?mr.createPortal(g.jsxs(Ye,{isOpen:t,onModalClose:n,id:"libraryModal",size:"lg",children:[g.jsx(Ye.Header,{onModalClose:n,children:u("bpr.publish")}),g.jsx(Ye.Subtitle,{children:u("bpr.form.tip")}),g.jsxs(Ye.Body,{children:[g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:u("bpr.form.publication.heading.general")}),g.jsxs("form",{id:"libraryModalForm",onSubmit:b(w),children:[g.jsxs("div",{className:"d-block d-md-flex mb-24 gap-24",children:[g.jsxs("div",{style:{maxWidth:"160px"},children:[g.jsx("div",{className:"form-label",children:u("bpr.form.publication.cover.title")}),g.jsx(u8,{app:s,src:c==null?void 0:c.thumbnail,addButtonLabel:u("bpr.form.publication.cover.upload.add"),deleteButtonLabel:u("bpr.form.publication.cover.upload.remove"),onUploadImage:_,onDeleteImage:x,className:"align-self-center",libraryMedia:a,mediaLibraryRef:o}),!f&&g.jsx("p",{className:"form-text is-invalid",children:g.jsx("em",{children:u("bpr.form.publication.cover.upload.required.image")})})]}),g.jsxs("div",{className:"flex-fill",children:[g.jsxs(Ot,{id:"title",className:"mb-16",isRequired:!0,children:[g.jsx(Gi,{children:u("bpr.form.publication.title")}),g.jsx(Kn,{type:"text",defaultValue:c==null?void 0:c.name,...E("title",{required:!0}),placeholder:u("bpr.form.publication.title.placeholder"),size:"md","aria-required":!0})]}),g.jsxs(Ot,{id:"description",isRequired:!0,children:[g.jsx(Gi,{children:u("bpr.form.publication.description")}),g.jsx(fA,{...E("description",{required:!0}),placeholder:u("bpr.form.publication.description.placeholder"),size:"md"})]})]})]}),g.jsx("hr",{}),g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:u("bpr.form.publication.heading.infos")}),g.jsxs("div",{className:"d-flex flex-column flex-md-row gap-16 row mb-24",children:[g.jsx(Zle,{control:h,selectedActivities:P,selectActivities:A}),g.jsx(lue,{control:h,selectedSubjectAreas:I,selectSubjects:M}),g.jsx(sue,{control:h})]}),g.jsxs("div",{className:"mb-24",children:[g.jsx("label",{htmlFor:"",className:"form-label",children:u("bpr.form.publication.age")}),g.jsxs("div",{className:"d-flex gap-8",children:[g.jsx("div",{className:"col col-md-2 d-flex",children:g.jsx(Sk,{control:h,name:"ageMin",placeholderOption:"bpr.form.publication.age.min",validate:(j,H)=>parseInt(j)<=parseInt(H.ageMax)})}),g.jsx("div",{className:"col col-md-2 d-flex",children:g.jsx(Sk,{control:h,name:"ageMax",placeholderOption:"bpr.form.publication.age.max",validate:(j,H)=>parseInt(j)>=parseInt(H.ageMin)})})]})]}),g.jsx("div",{className:"mb-24",children:g.jsxs(Ot,{id:"keywords",isOptional:!0,children:[g.jsx(Gi,{children:u("bpr.form.publication.keywords")}),g.jsx(Kn,{type:"text",...E("keyWords"),size:"md",placeholder:u("bpr.form.publication.keywords.placeholder")})]})}),g.jsx("hr",{}),g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:u("bpr.form.publication.licence.text")}),g.jsx(oue,{})]})]}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{color:"tertiary",onClick:n,type:"button",variant:"ghost",children:u("cancel")}),g.jsx(it,{form:"libraryModalForm",type:"submit",color:"primary",variant:"filled",isLoading:v,disabled:!f||v||!m||!y,children:u("bpr.form.submit")})]}),g.jsx(y8,{appCode:i,ref:o,multiple:!1,visibility:"protected",...l})]}),document.getElementById("portal")):g.jsx(fr,{})}const Dhe=({content:t,maxLength:e})=>g.jsx("p",{className:"small text-gray-700 p-2 text-end",children:t?`${t.length} / ${e}`:""}),Nhe=({isUpdating:t,selectedResource:e})=>{const[r,n]=T.useState(t&&(e==null?void 0:e.thumbnail)||"");return T.useEffect(()=>{n((e==null?void 0:e.thumbnail)||"")},[e]),{thumbnail:r,handleDeleteImage:()=>n(""),handleUploadImage:i=>n(i)}},Lhe=60,Fhe=400,jhe=({isOpen:t,onCancel:e,onSuccess:r,children:n,inputMaxLength:i=Lhe,textareaMaxLength:s=Fhe,...o})=>{const{appCode:a,currentApp:l}=yt(),{t:u}=we(),{mode:c}=o,h=en(),f=T.useId(),m=c==="create",y=c==="update",v=mA(a,y?o.resourceId:""),{watch:x,register:b,handleSubmit:_,setValue:w,formState:{isSubmitting:E,isValid:A}}=OT({mode:"onChange",defaultValues:{description:y?v==null?void 0:v.description:"",enablePublic:y?v==null?void 0:v.public:!1,title:y?v==null?void 0:v.name:"",formSlug:y?v==null?void 0:v.slug:""}}),{ref:P,libraryMedia:I,...M}=a8(),{appCode:N}=yt(),{thumbnail:z,handleDeleteImage:j,handleUploadImage:H}=Nhe({isUpdating:y,selectedResource:y?v:void 0}),F=x("description"),L=async function(O){var $,V;try{const k={description:O.description||"",name:O.title,public:O.enablePublic,slug:O.enablePublic&&O.formSlug||"",thumbnail:z};if(m){const U={...k,folder:o.currentFolder===void 0||(($=o.currentFolder)==null?void 0:$.id)==="default"?void 0:parseInt(((V=o.currentFolder)==null?void 0:V.id)||""),application:a};o.createResource?await o.createResource.mutateAsync(U):await Me.resource(a).create(U)}else{const U={...k,entId:v.assetId,trashed:v.trashed};o.updateResource?await o.updateResource.mutateAsync(U):await Me.resource(a).update(U)}h.success(g.jsxs(g.Fragment,{children:[g.jsx("strong",{children:u(m?"explorer.resource.created":"explorer.resource.updated")}),g.jsxs("p",{children:[u("title")," : ",O.title]}),g.jsxs("p",{children:[u("description")," : ",O.description]}),a==="blog"&&g.jsxs("p",{children:["Public:",O.enablePublic?u("explorer.enable.public.yes"):u("explorer.enable.public.no")]})]})),r()}catch(k){console.error(k)}};return y&&!v?g.jsx(fr,{}):mr.createPortal(g.jsxs(Ye,{id:`${c}-resource`,size:"lg",isOpen:t,onModalClose:e,children:[g.jsx(Ye.Header,{onModalClose:e,children:u(`explorer.resource.editModal.header.${m?"create":"edit"}`)}),g.jsxs(Ye.Body,{children:[g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:u("explorer.resource.editModal.heading.general")}),g.jsxs("form",{id:f,onSubmit:_(L),children:[g.jsxs("div",{className:"d-block d-md-flex gap-16 mb-24",children:[g.jsx("div",{children:g.jsx(u8,{app:l,src:y&&(v==null?void 0:v.thumbnail)||"",addButtonLabel:u("explorer.imagepicker.button.add"),deleteButtonLabel:u("explorer.imagepicker.button.delete"),onUploadImage:H,onDeleteImage:j,className:"align-self-center mt-8",libraryMedia:I,mediaLibraryRef:P})}),g.jsxs("div",{className:"col",children:[g.jsxs(Ot,{id:"title",className:"mb-16",isRequired:!0,children:[g.jsx(Gi,{children:u("title")}),g.jsx(Kn,{type:"text",defaultValue:y?v==null?void 0:v.name:"",...b("title",{required:!0,maxLength:i,pattern:{value:/[^ ]/,message:"invalid title"}}),placeholder:u("explorer.resource.editModal.title.placeholder"),size:"md","aria-required":!0,maxLength:i})]}),g.jsxs(Ot,{id:"description",isOptional:!0,children:[g.jsx(Gi,{children:u("description")}),g.jsx(fA,{defaultValue:(v==null?void 0:v.description)||"",...b("description",{required:!1,maxLength:s}),placeholder:u("explorer.resource.editModal.description.placeholder"),size:"md",maxLength:s}),F&&g.jsx(Dhe,{content:F,maxLength:s})]})]})]}),typeof n=="function"?n(v,y,x,w,b):n]})]}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{color:"tertiary",onClick:e,type:"button",variant:"ghost",children:u("explorer.cancel")}),g.jsx(it,{form:f,type:"submit",color:"primary",isLoading:E,variant:"filled",disabled:!A||E,children:u(m?"explorer.create":"save")})]}),g.jsx(y8,{appCode:N,ref:P,multiple:!1,visibility:"protected",...M})]}),document.getElementById("portal"))},Bhe=jhe,Uhe=({application:t,options:e})=>Mo({mutationFn:async r=>await Me.resource(t).update(r),...e}),$he=Uhe,zhe=({watch:t,setValue:e,selectedResource:r})=>{const[n,i]=T.useState(""),[s,o]=T.useState((r==null?void 0:r.public)||!1),a=T.useId(),l=t("title"),{t:u}=we(),c=en();T.useEffect(()=>{if(s){let m="";r?m=r.slug?r.slug:`${ik({foo:`${l}${a}`})}-${ok(l)}`:m=`${ik({foo:`${l}${a}`})}-${ok(l)}`,e("formSlug",m),i(m)}},[s,l]);function h(m){o(m)}function f(m){navigator.clipboard.writeText(`${window.location.origin}${m||window.location.pathname}/pub/${n}`),c.success(u("explorer.copy.clipboard"))}return{slug:n,uniqueId:a,isPublic:s,resourceName:l,onPublicChange:h,onCopyToClipBoard:f}},Hhe=({appCode:t,isUpdating:e,resource:r,watch:n,register:i,setValue:s})=>{const{t:o}=we(),{slug:a,isPublic:l,resourceName:u,onPublicChange:c,onCopyToClipBoard:h}=zhe({watch:n,setValue:s,selectedResource:e?r:void 0});return g.jsxs(g.Fragment,{children:[g.jsxs(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:[o("explorer.resource.editModal.heading.access"),t]}),g.jsx(ta,{type:"info",children:o("explorer.resource.editModal.access.alert")}),g.jsxs(Ot,{id:"flexSwitchCheckDefault",className:"form-switch d-flex gap-8 mt-16 mb-8",children:[g.jsx(Ot.Input,{type:"checkbox",role:"switch",defaultChecked:e?r.public:!1,...i("enablePublic",{disabled:!u,onChange:f=>{const m=f.target.checked;c(m)}}),className:"form-check-input mt-0",size:"md"}),g.jsx(Ot.Label,{className:"form-check-label mb-0",children:o("explorer.resource.editModal.access.flexSwitchCheckDefault.label")})]}),l&&g.jsxs(g.Fragment,{children:[g.jsx(Ot,{id:"formSlug",children:g.jsx(Kn,{type:"text",hidden:!0,defaultValue:e?a:"",...i("formSlug"),size:"sm"})},a),g.jsxs("div",{className:"d-flex flex-wrap align-items-center gap-4",children:[g.jsxs("p",{className:"text-break",children:[window.location.origin,"/blog/pub/",a]}),g.jsx(it,{color:"primary",disabled:!l,onClick:()=>h("/blog"),type:"button",leftIcon:g.jsx($$,{}),variant:"ghost",className:"text-nowrap",children:o("explorer.resource.editModal.access.url.button")})]})]})]})},x8=Hhe,Vhe=({bookmark:t,refBookmark:e,onBookmarkChange:r,onSave:n})=>{const{t:i}=we();return g.jsx("div",{className:"mt-16",children:g.jsxs(Ot,{id:"bookmarkName",className:"d-flex flex-wrap align-items-center gap-16",children:[g.jsx("div",{className:"flex-fill",children:g.jsx(Ot.Input,{ref:e,onChange:r,placeholder:i("explorer.modal.share.sharebookmark.placeholder"),size:"sm",type:"text"},t.id)}),g.jsx(it,{type:"button",color:"primary",variant:"ghost",disabled:t.name.length===0,leftIcon:g.jsx(jT,{}),onClick:n,className:"text-nowrap",children:i("explorer.modal.share.sharebookmark.save")})]})})},Ghe=(t,e)=>t.actions.filter(r=>e.id===r.id).length>0,Whe=(t,e)=>t.isBookmarkMember&&e||!t.isBookmarkMember,Xhe=({shareRights:t,showBookmark:e,toggleBookmark:r,shareRightActions:n,toggleRight:i,onDeleteRow:s})=>{const{t:o}=we();return t==null?void 0:t.rights.map(a=>{const l={user:g.jsx(rc,{alt:o("explorer.modal.share.avatar.shared.alt"),size:"xs",src:a.avatarUrl,variant:"circle"}),group:g.jsx("div",{className:"avatar-xs bg-primary-200 justify-content-center d-flex rounded-circle",children:g.jsx(BT,{width:16})}),sharebookmark:g.jsx(DT,{})}[a.type]||null,u=a.type==="sharebookmark",c=a.type==="user";return Whe(a,e)&&g.jsxs("tr",{className:a.isBookmarkMember?"bg-light":"",children:[g.jsx("td",{children:l}),g.jsx("td",{children:g.jsxs("div",{className:"d-flex",children:[u&&g.jsx(it,{color:"tertiary",rightIcon:g.jsx(Tp,{title:o("show"),className:"w-16 min-w-0",style:{transition:"rotate 0.2s ease-out",rotate:e?"-180deg":"0deg"}}),type:"button",variant:"ghost",className:"fw-normal ps-0",onClick:r,children:a.displayName}),!u&&a.displayName,c&&` (${o(a.profile||"")})`]})}),n.map(h=>g.jsx("td",{style:{width:"80px"},className:"text-center text-white",children:g.jsx(Tm,{checked:Ghe(a,h),onChange:()=>i(a,h.id)})},h.displayName)),g.jsx("td",{children:!a.isBookmarkMember&&g.jsx(Ro,{"aria-label":o("close"),color:"tertiary",icon:g.jsx(NT,{}),type:"button",variant:"ghost",title:o("close"),onClick:()=>s(a)})})]},a.id)})},qhe={searchInputValue:"",searchResults:[],searchAPIResults:[],isSearching:!1};function Yhe(t,e){switch(e.type){case"onChange":return{...t,searchInputValue:e.payload};case"isSearching":return{...t,isSearching:e.payload};case"addResult":return{...t,searchResults:e.payload};case"addApiResult":return{...t,searchAPIResults:e.payload};case"updateSearchResult":return{...t,searchResults:e.payload};case"emptyResult":return{...t,searchResults:e.payload};default:throw new Error("Unhandled action type")}}const __=[{id:"read",displayName:"read"},{id:"comment",displayName:"comment"}],Qhe=({resourceId:t,resourceCreatorId:e,shareRights:r,shareDispatch:n})=>{const[i,s]=T.useReducer(Yhe,qhe),o=sA(i.searchInputValue,500),{isAdml:a}=o8(),{appCode:l}=yt(),{t:u}=we();T.useEffect(()=>{h(o)},[o]);const c=f=>{const m=f.target.value;s({type:"onChange",payload:m})},h=async f=>{if(t){if(s({type:"isSearching",payload:!0}),!a&&f.length>=1||a&&f.length>=3){const m=await Me.share().searchShareSubjects(l,t,f);s({type:"addApiResult",payload:m});const y=m.filter(v=>!r.rights.find(x=>x.id===v.id)).filter(v=>!(v.type==="user"&&v.id===e)).map(v=>{let x=v.displayName;return v.type==="user"&&v.profile?x=`${x} (${u(v.profile)})`:v.type==="group"&&v.structureName&&(x=`${x} (${v.structureName})`),{value:v.id,label:x,icon:v.type==="sharebookmark"?g.jsx(DT,{}):null}});s({type:"addResult",payload:y})}else s({type:"emptyResult",payload:[]}),Promise.resolve();s({type:"isSearching",payload:!1})}};return{state:i,showSearchAdmlHint:()=>a&&i.searchInputValue.length<3,showSearchLoading:()=>i.isSearching,showSearchNoResults:()=>!i.isSearching&&!a&&o.length>0&&i.searchResults.length===0||!i.isSearching&&a&&o.length>3&&i.searchResults.length===0,getSearchMinLength:()=>a?3:1,handleSearchInputChange:c,handleSearchResultsChange:async f=>{const m=i.searchAPIResults.find(y=>y.id===f[0]);if(m){let y=[];if(m.type==="sharebookmark"){const v=await Me.directory().getBookMarkById(m.id);y.push({...v,type:"sharebookmark",avatarUrl:"",directoryUrl:"",actions:__}),v==null||v.users.filter(x=>!r.rights.find(b=>b.id===x.id)).forEach(x=>{y.push({...x,type:"user",avatarUrl:"",directoryUrl:"",actions:__,isBookmarkMember:!0})}),v.groups.filter(x=>!r.rights.find(b=>b.id===x.id)).forEach(x=>{y.push({...x,type:"group",avatarUrl:"",directoryUrl:"",actions:__,isBookmarkMember:!0})})}else y=[{...m,actions:[{id:"read",displayName:"read"},{id:"comment",displayName:"comment"}]}];n({type:"updateShareRights",payload:{...r,rights:[...r.rights,...y]}}),s({type:"updateSearchResult",payload:i.searchResults.filter(v=>v.value!==f[0])})}}}},Khe={isSharing:!1,shareRights:{rights:[],visibleBookmarks:[],visibleGroups:[],visibleUsers:[]},shareRightActions:[]};function Zhe(t,e){switch(e.type){case"init":return{...t,...e.payload};case"deleteRow":return{...t,shareRights:e.payload};case"updateShareRights":return{...t,shareRights:e.payload};case"toggleRight":return{...t,shareRights:e.payload};case"isSharing":return{...t,isSharing:e.payload};default:throw new Error("Unhandled action type")}}function Jhe({resourceId:t,resourceRights:e,resourceCreatorId:r,shareResource:n,setIsLoading:i,onSuccess:s}){const{appCode:o}=yt(),{user:a,avatar:l}=wh(),u=en(),{t:c}=we(),[h,f]=T.useReducer(Zhe,Khe);T.useEffect(()=>{t&&(async()=>{try{const[v,x]=await Promise.all([Me.share().getActionsForApp(o),Me.share().getRightsForResource(o,t)]);f({type:"init",payload:{shareRightActions:v,shareRights:x}})}catch(v){console.error(v)}i(!1)})()},[t]);const m=(v,x)=>{var b,_;const{rights:w,...E}=h.shareRights,A=[...w],P=A.findIndex(M=>M.id===v.id),I=h.shareRightActions.filter(M=>M.id===x)[0];if(A[P].actions.findIndex(M=>M.id===x)>-1){let M=A[P].actions.filter(z=>z.id!==x);const N=h.shareRightActions.filter(z=>{var j;return(j=z.requires)==null?void 0:j.includes(x)});M=M.filter(z=>!N.find(j=>j.id===z.id)),A[P]={...A[P],actions:M}}else{const M=h.shareRightActions.filter(N=>{var z;return((z=I.requires)==null?void 0:z.includes(N.id))&&!A[P].actions.find(j=>j.id===N.id)});A[P]={...A[P],actions:[...A[P].actions,I,...M]}}v.type==="sharebookmark"&&((b=A[P].users)==null||b.forEach(M=>{const N=A.findIndex(z=>z.id===M.id);A[N]={...A[N],actions:A[P].actions}}),(_=A[P].groups)==null||_.forEach(M=>{const N=A.findIndex(z=>z.id===M.id);A[N]={...A[N],actions:A[P].actions}})),f({type:"toggleRight",payload:{rights:A,...E}})},y=v=>{Object.keys(v)[0]==="error"?(u.error(c("explorer.shared.status.error")),console.error("Failed to save share",v)):u.success(c("explorer.shared.status.saved"))};return{state:h,dispatch:f,currentIsAuthor:()=>r===(a==null?void 0:a.userId),myAvatar:l,handleDeleteRow:v=>{f({type:"deleteRow",payload:{...h.shareRights,rights:h.shareRights.rights.filter(x=>{var b,_;return x.id!==v.id&&!((b=v.users)!=null&&b.find(w=>w.id===x.id))&&!((_=v.groups)!=null&&_.find(w=>w.id===x.id))})}})},handleShare:async()=>{f({type:"isSharing",payload:!0});try{const v=e.filter(b=>a&&b.includes(`user:${a.userId}`)).map(b=>b.split(":")[2]).filter(b=>!!b),x=[...h.shareRights.rights];if(v.length>0){const b=v.map(_=>({displayName:_,id:_}));x.push({actions:b,avatarUrl:"",directoryUrl:"",displayName:a.username,id:a.userId,type:"user"})}if(n){const b=await n.mutateAsync({resourceId:t,rights:x});y(b)}else{const b=await Me.share().saveRights(o,t,x);y(b)}s()}catch(v){typeof v=="string"&&u.error(c("explorer.shared.status.error")),console.error("Failed to save share",v)}finally{f({type:"isSharing",payload:!1})}},toggleRight:m}}const efe=({shareRights:t,shareDispatch:e})=>{const r=en(),{t:n}=we(),i=T.useRef(null),[s,o]=T.useState({name:"",id:T.useId()}),[a,l]=Cm(!1),[u,c]=T.useState(!1),h=()=>{l()},f=()=>{o(y=>{var v;return{...y,name:((v=i.current)==null?void 0:v.value)||""}})},m=async y=>{try{const v=await Me.directory().saveBookmarks(y,{users:t.rights.filter(x=>x.type==="user").map(x=>x.id),groups:t.rights.filter(x=>x.type==="group").map(x=>x.id),bookmarks:t.rights.filter(x=>x.type==="sharebookmark").map(x=>x.id)});r.success(n("explorer.bookmarked.status.saved")),e({type:"updateShareRights",payload:{...t,visibleBookmarks:[...t.visibleBookmarks,{displayName:y,id:v.id}]}}),o(x=>({...x,bookmarkId:x.id+new Date().getTime().toString()})),c(!1)}catch(v){console.error("Failed to save bookmark",v),r.error(n("explorer.bookmarked.status.error"))}};return{refBookmark:i,showBookmark:a,showBookmarkInput:u,bookmark:s,handleBookmarkChange:f,setBookmark:o,handleOnSave:()=>{var y;const v=((y=i.current)==null?void 0:y.value)||"";m(v)},toggleBookmark:h,toggleBookmarkInput:c}};function tfe({isOpen:t,shareOptions:e,shareResource:r,children:n,onSuccess:i,onCancel:s}){const{resourceId:o,resourceCreatorId:a,resourceRights:l}=e,[u,c]=T.useState(!0),{state:{isSharing:h,shareRights:f,shareRightActions:m},dispatch:y,myAvatar:v,currentIsAuthor:x,handleShare:b,toggleRight:_,handleDeleteRow:w}=Jhe({resourceId:o,resourceCreatorId:a,resourceRights:l,shareResource:r,setIsLoading:c,onSuccess:i}),{state:{searchResults:E,searchInputValue:A},showSearchAdmlHint:P,showSearchLoading:I,showSearchNoResults:M,getSearchMinLength:N,handleSearchInputChange:z,handleSearchResultsChange:j}=Qhe({resourceId:o,resourceCreatorId:a,shareRights:f,shareDispatch:y}),{refBookmark:H,showBookmark:F,handleBookmarkChange:L,toggleBookmark:O,bookmark:$,handleOnSave:V,showBookmarkInput:k,toggleBookmarkInput:U}=efe({shareRights:f,shareDispatch:y}),{t:B}=we(),X=P()?B("explorer.search.adml.hint"):B("explorer.modal.share.search.placeholder");return mr.createPortal(g.jsxs(Ye,{id:"share_modal",size:"lg",isOpen:t,onModalClose:s,children:[g.jsx(Ye.Header,{onModalClose:s,children:B("share.title")}),g.jsxs(Ye.Body,{children:[g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:B("explorer.modal.share.usersWithAccess")}),g.jsx("div",{className:"table-responsive",children:u?g.jsx(fr,{}):g.jsxs("table",{className:"table border align-middle mb-0",children:[g.jsx("thead",{className:"bg-secondary",children:g.jsxs("tr",{children:[g.jsx("th",{scope:"col",className:"w-32",children:g.jsx(ml,{children:B("explorer.modal.share.avatar.shared.alt")})}),g.jsx("th",{scope:"col",children:g.jsx(ml,{children:B("explorer.modal.share.search.placeholder")})}),m.map(K=>g.jsx("th",{scope:"col",className:"text-center text-white",children:B(K.displayName)},K.displayName)),g.jsx("th",{scope:"col",children:g.jsx(ml,{children:B("close")})})]})}),g.jsxs("tbody",{children:[x()&&g.jsxs("tr",{children:[g.jsx("th",{scope:"row",children:g.jsx(rc,{alt:B("explorer.modal.share.avatar.me.alt"),size:"xs",src:v,variant:"circle"})}),g.jsx("td",{children:B("share.me")}),m.map(K=>g.jsx("td",{style:{width:"80px"},className:"text-center text-white",children:g.jsx(Tm,{checked:!0,disabled:!0})},K.displayName)),g.jsx("td",{})]}),g.jsx(Xhe,{showBookmark:F,shareRightActions:m,shareRights:f,onDeleteRow:w,toggleRight:_,toggleBookmark:O})]})]})}),g.jsxs("div",{className:"mt-16",children:[g.jsx(it,{color:"tertiary",leftIcon:g.jsx(DT,{}),rightIcon:g.jsx(Tp,{title:B("show"),className:"w-16 min-w-0",style:{transition:"rotate 0.2s ease-out",rotate:k?"-180deg":"0deg"}}),type:"button",variant:"ghost",className:"fw-normal",onClick:()=>U(!k),children:B("share.save.sharebookmark")}),k&&g.jsx(Vhe,{refBookmark:H,bookmark:$,onBookmarkChange:L,onSave:V})]}),g.jsx("hr",{}),g.jsxs(Ss,{headingStyle:"h4",level:"h3",className:"mb-16 d-flex align-items-center",children:[g.jsx("div",{className:"me-8",children:B("explorer.modal.share.search")}),g.jsx(fo,{message:"Vos favoris de partage s’affichent en priorité dans votre liste lorsque vous recherchez un groupe ou une personne, vous pouvez les retrouver dans l’annuaire.",placement:"top",children:g.jsx(BN,{className:"c-pointer",height:"18"})})]}),g.jsx("div",{className:"row",children:g.jsx("div",{className:"col-10",children:g.jsx(Tce,{value:A,placeholder:X,isLoading:I(),noResult:M(),options:E,searchMinLength:N(),onSearchInputChange:z,onSearchResultsChange:j})})}),n]}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{type:"button",color:"tertiary",variant:"ghost",onClick:s,children:B("explorer.cancel")}),g.jsx(it,{type:"button",color:"primary",variant:"filled",isLoading:h,onClick:b,disabled:h,children:B("share")})]})]}),document.getElementById("portal"))}function rfe({resourceId:t,updateResource:e}){const{appCode:r}=yt(),{t:n}=we(r),i=mA("blog",t),s=i&&i["publish-type"],[o,a]=T.useState(s??"RESTRAINT");T.useEffect(()=>{s&&a(s)},[s]);const l=async u=>{const c=u.target.value,h={description:i.description||"",entId:i.assetId,name:i.name,public:!!i.public,slug:i.slug||"",thumbnail:i.thumbnail,trashed:i.trashed,"publish-type":c};e?await e.mutateAsync(h):await Me.resource("blog").update(h),a(c)};return g.jsxs(g.Fragment,{children:[g.jsx("hr",{}),g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:n("explorer.publication.steps")}),g.jsx(E2,{label:n("explorer.immediat.publication"),id:"publication-now",name:"publication",value:"IMMEDIATE",model:o,checked:o==="IMMEDIATE",onChange:l}),g.jsx(E2,{label:n("explorer.validate.publication"),id:"publication-validate",name:"publication",value:"RESTRAINT",checked:o==="RESTRAINT",model:o,onChange:l})]})}const nfe=({application:t,options:e})=>Mo({mutationFn:async({resourceId:r,rights:n})=>await Me.share().saveRights(t,r,n),...e}),ife=nfe;function sfe(t){return{getPreference:async()=>await Me.conf().getPreference(t),savePreference:async e=>await Me.conf().savePreference(t,JSON.stringify(e))}}function ofe(){const[t,e]=T.useState(!1),{getPreference:r,savePreference:n}=sfe("rgpdCookies");return T.useEffect(()=>{(async()=>{const i=await r();e(i===null?!0:i.showInfoTip)})()},[]),{showCookiesConsent:t,handleConsultCookies:()=>{document.location.href="/userbook/mon-compte",n({showInfoTip:!1}),e(!1)},handleCloseCookiesConsent:()=>{n({showInfoTip:!1}),e(!1)}}}function Rk({isHelpOpen:t,setIsHelpOpen:e,parsedHeadline:r,parsedContent:n,error:i}){const{t:s}=we(),o=()=>{e(!1)};return t?mr.createPortal(g.jsxs(Ye,{id:"help-modal",isOpen:t,onModalClose:o,scrollable:!0,size:"lg",children:[g.jsx(Ye.Header,{onModalClose:o,children:s("navbar.help")}),g.jsx(Ye.Subtitle,{children:i?s("help.notfound.title"):r}),g.jsx(Ye.Body,{className:i?"d-flex":null,children:i?s("help.notfound.text"):n})]}),document.getElementById("portal")):null}function afe(){var t,e,r,n,i;const{appCode:s}=yt(),{theme:o}=ba(),[a,l]=T.useState(""),[u,c]=T.useState(!0),[h,f]=T.useState(!1),[m,y]=T.useState(!1),v=o!=null&&o.is1d?"/help-1d":"/help-2d";T.useEffect(()=>{(async()=>{let w="";w=v+"/application/"+s+"/",!s&&window.location.pathname!=="/adapter"?w=v+"/application/portal/":window.location.pathname==="/adapter"?w=v+"/application/"+window.location.search.split("eliot=")[1].split("&")[0]+"/":window.location.pathname.includes("/directory/class-admin")?w=v+"/application/parametrage-de-la-classe/":(window.location.pathname.includes("/userbook/mon-compte")||window.location.pathname.includes("/timeline/preferencesView")||window.location.pathname.includes("/timeline/historyView"))&&(w=v+"/application/userbook/");try{const E=await fetch(w),A=await E.text();if(E.status===404){y(!0);return}l(A),y(!1)}catch(E){y(!0),console.error(E)}})()},[s,v]);const x=Wl(a,{replace:w=>{const E=w;if(E.attribs&&E.attribs.id==="TOC")return g.jsxs("nav",{id:"TOC",children:[g.jsx(it,{onClick:()=>{c(!u)},children:g.jsx(F$,{})}),I0(E.children,{replace:A=>{const P=A;if(P.attribs&&P.name==="ul")return g.jsx("ul",{id:"TOC-list",style:{display:u?"block":"none"},children:I0(P.children,{replace:I=>{const M=I;if(M.attribs&&M.name==="a")return g.jsx("a",{...v_(M.attribs),children:g.jsx("span",{onClick:()=>{c(!1)},children:I0(M.children)})})}})})}})]});if(E.attribs&&E.attribs.class==="section level2"){const A=v_(w.attribs);return g.jsx("div",{...A,className:"section level2",style:{display:E.attribs.id!=="présentation"?"none":"block"},children:I0(E.children,{replace:P=>{const I=P;if(I.attribs&&I.name==="img"){const M=P.attribs.src;return g.jsx("img",{...v_(I.attribs),src:`${v}/${M}`,alt:""})}}})})}}}),b=(r=(e=(t=x==null?void 0:x.props)==null?void 0:t.children.find(w=>w.type==="body"))==null?void 0:e.props)==null?void 0:r.children,_=(i=(n=b==null?void 0:b.find(w=>w.type==="p"))==null?void 0:n.props)==null?void 0:i.children;return{html:a,visibility:u,isModalOpen:h,setIsModalOpen:f,parsedContent:b,parsedHeadline:_,error:m}}const vr=T.forwardRef(({children:t,className:e,...r},n)=>{const i=Re("nav-item",e);return g.jsx("li",{ref:n,className:i,...r,children:t})}),lfe=()=>{const[t,e]=$6(),r=T.useRef(null),n=T.useId(),{t:i}=we();function s(){if(r.current){const o=r.current.value;window.location.href=`/searchengine#/${o}`}}return g.jsxs(vr,{id:n,ref:t,className:"position-relative","aria-haspopup":"true","aria-expanded":e,children:[g.jsxs("a",{href:"/searchengine",className:"nav-link dropdown-item",children:[g.jsx(jq,{className:"icon search"}),g.jsx("span",{className:"nav-text",children:i("navbar.search")})]}),g.jsx(i8,{id:n,isVisible:e,className:"d-none d-md-flex",children:g.jsxs(Ot,{id:"my-search-input",className:"search-text input-group py-8 px-12",children:[g.jsx(Ot.Input,{ref:r,size:"sm",type:"text",name:"my-search-input",placeholder:"Rechercher"}),g.jsx(oA,{type:"submit",size:"sm",onClick:s,"aria-label":i("navbar.search")})]})})]})},ufe=lfe;function S_({children:t,className:e,...r}){const n=Re("navbar",e);return g.jsx("nav",{className:n,...r,children:t})}function Pk({children:t,className:e,...r}){const n=Re("navbar-nav",e);return g.jsx("ul",{className:n,...r,children:t})}function mf({link:t,className:e,children:r,translate:n,...i}){const s=Re("nav-link",e);return g.jsxs("a",{href:t,className:s,...i,children:[r,n&&g.jsx(ml,{children:g.jsx("span",{className:"nav-text",children:n})})]})}const cfe=()=>{const{t}=we();return g.jsx("div",{className:"widget-footer",children:g.jsx("div",{className:"widget-footer-action",children:g.jsx("a",{href:"/welcome",className:"link",children:t("plus")})})})},dfe=({bookmarkedApps:t})=>{const{t:e}=we();return g.jsxs("div",{className:"widget-body d-flex flex-wrap",children:[!t.length&&g.jsx("div",{className:"text-dark",children:e("navbar.myapps.more")}),t.slice(0,6).map((r,n)=>g.jsx("a",{href:r.address,className:"bookmarked-app",children:g.jsx(ya,{app:r,size:"32"})},n))]})},hfe=({is1d:t=!1,src:e=""})=>{const{t:r}=we(),{messages:n,msgLink:i,zimbraWorkflow:s}=Gce(),{user:o,avatar:a}=wh(),{currentLanguage:l,currentApp:u}=yt(),c=Wi("org.entcore.portal.controllers.PortalController|oldHelpEnable")||!1,{isModalOpen:h,setIsModalOpen:f,parsedContent:m,parsedHeadline:y,error:v}=afe(),x=Re("header",{"no-2d":t,"no-1d":!t}),{title:b,bookmarkedApps:_,appsRef:w,isAppsHovered:E,popoverAppsId:A,userAvatar:P,userName:I,welcomeUser:M,communityWorkflow:N,conversationWorflow:z,searchWorkflow:j,isCollapsed:H,toggleCollapsedNav:F,handleLogout:L}=Wce({user:o,avatar:a}),O=n>0,{theme:$}=ba();return g.jsx("header",{className:x,children:t?g.jsxs(g.Fragment,{children:[g.jsx("div",{className:"container-fluid",children:g.jsxs(S_,{children:[g.jsx("a",{className:"navbar-title d-md-none text-truncate h4",href:u?u.address:"/timeline/timeline",children:b}),g.jsxs("div",{className:"d-none d-md-inline-flex gap-12 align-items-center",children:[g.jsx(rc,{alt:I,size:"sm",src:P,variant:"circle",width:"32",height:"32"}),g.jsx("span",{className:"navbar-text",children:M})]}),g.jsxs(Pk,{className:"gap-8","aria-hidden":"false","aria-label":r("navbar.main.navigation"),children:[z&&g.jsx(vr,{children:g.jsxs("a",{href:"/conversation/conversation",className:"nav-link",children:[g.jsx(Nq,{className:"icon notification"}),O&&g.jsx(ow,{variant:{type:"notification",level:"danger"},className:"position-absolute",children:n}),g.jsx(ml,{children:r("navbar.messages")})]})}),g.jsx(vr,{children:g.jsx(mf,{link:"/userbook/mon-compte",className:"dropdown-item",translate:r("navbar.myaccount"),children:g.jsx(bC,{className:"icon user"})})}),l==="fr"&&c?g.jsxs(vr,{children:[g.jsxs("button",{className:"nav-link",onClick:()=>{f(!0)},children:[g.jsx(Oq,{className:"icon help"}),g.jsx(ml,{children:r("navbar.help")})]}),g.jsx(Rk,{isHelpOpen:h,setIsHelpOpen:f,parsedContent:m,parsedHeadline:y,error:v})]}):null,g.jsx(vr,{children:g.jsxs("button",{className:"nav-link",onClick:L,children:[g.jsx(F3,{className:"icon logout"}),g.jsx(ml,{children:r("navbar.disconnect")})]})}),g.jsx(vr,{className:"d-md-none",children:g.jsx("button",{className:"nav-link btn btn-naked",type:"button","aria-controls":"navbarCollapsed","aria-expanded":!H,"aria-label":r("navbar.secondary.navigation"),onClick:F,children:g.jsx(Tp,{className:"icon rafter-down",width:"20",height:"20"})})})]})]})}),g.jsx(S_,{className:"no-2d navbar-secondary navbar-expand-md","aria-label":r("navbar.secondary.navigation"),children:g.jsx("div",{className:"container-fluid",children:g.jsxs("div",{className:`collapse navbar-collapse ${H?"":"show"}`,id:"navbarCollapsed",children:[g.jsx(Ck,{is1d:!0,src:`${e}/img/illustrations/logo.png`,translate:r("navbar.home")}),g.jsxs(Pk,{className:"gap-8",children:[g.jsx(vr,{children:g.jsxs("a",{href:"/timeline/timeline",className:"button",children:[g.jsx(Mq,{color:"#fff",className:"d-md-none"}),g.jsx("span",{className:"d-inline-block",children:r("portal.header.navigation.whatsnew")})]})}),g.jsx(vr,{children:g.jsxs("a",{href:"/userbook/annuaire",className:"button",children:[g.jsx(Uq,{color:"#fff",className:"d-md-none"}),g.jsx("span",{className:"d-inline-block",children:r("portal.header.navigation.classMembers")})]})}),g.jsx(vr,{children:g.jsxs("a",{href:"/welcome",className:"button",children:[g.jsx(j3,{color:"#fff",className:"d-md-none"}),g.jsx("span",{className:"d-inline-block",children:r("portal.header.navigation.myapps")})]})})]})]})})})]}):g.jsx(S_,{className:"navbar-expand-md",children:g.jsxs("div",{className:"container-fluid",children:[g.jsx(Ck,{src:`${e}/img/illustrations/logo.png`}),g.jsx("a",{href:u?u.address:"/timeline/timeline",className:"navbar-title text-truncate d-md-none",children:b}),g.jsxs("ul",{className:"navbar-nav",children:[g.jsx(vr,{children:g.jsx(mf,{link:"/timeline/timeline",translate:r("navbar.home"),children:g.jsx(Tq,{color:"#fff"})})}),g.jsxs(vr,{className:"position-relative",ref:w,id:A,"aria-haspopup":"true","aria-expanded":E,children:[g.jsx(mf,{link:"/welcome",translate:r("navbar.applications"),children:g.jsx(j3,{color:"#fff"})}),g.jsxs(i8,{className:"top-100 widget",id:A,isVisible:E,children:[g.jsx(Lce,{children:g.jsx(dfe,{bookmarkedApps:_})}),g.jsx(Fce,{className:"widget-footer border-top border-ghost",children:g.jsx(cfe,{})})]})]}),z&&g.jsx(vr,{children:g.jsxs(mf,{className:"position-relative",link:"/conversation/conversation",translate:r("conversation"),children:[g.jsx(B3,{color:"#fff"}),O&&g.jsx(ow,{variant:{type:"notification",level:"warning"},className:"position-absolute",children:n})]})}),s&&g.jsx(vr,{children:g.jsxs(mf,{className:"position-relative",link:i,translate:r("conversation"),children:[g.jsx(B3,{color:"#fff"}),O&&g.jsx(ow,{variant:{type:"notification",level:"warning"},className:"position-absolute",children:n})]})}),l==="fr"&&c?g.jsxs(vr,{children:[g.jsxs("button",{className:"nav-link btn btn-naked",onClick:()=>{f(!0)},children:[g.jsx(Rq,{color:"#fff"}),g.jsx(ml,{children:r("support")})]}),g.jsx(Rk,{isHelpOpen:h,setIsHelpOpen:f,parsedContent:m,parsedHeadline:y,error:v})]}):null,g.jsx(vr,{children:g.jsxs("div",{className:"dropdown",children:[g.jsx("button",{className:"nav-link btn btn-naked d-md-none",type:"button","aria-controls":"dropdown-navbar","aria-expanded":!H,"aria-label":r("navbar.open.menu"),onClick:F,children:g.jsx(Tp,{className:"icon rafter-down",width:"20",height:"20",color:"#fff"})}),g.jsxs("ul",{className:`dropdown-menu dropdown-menu-end ${H?"":"show"}`,id:"dropdown-navbar",children:[N&&g.jsx(vr,{children:g.jsxs("a",{href:"/community",className:"nav-link dropdown-item",children:[g.jsx(_q,{className:"icon community"}),g.jsx("span",{className:"nav-text",children:r("navbar.community")})]})}),j?g.jsx(ufe,{}):null,g.jsx(vr,{children:g.jsxs("a",{href:"/userbook/mon-compte",className:"nav-link dropdown-item",children:[g.jsx(rc,{alt:I,size:"sm",src:P,variant:"circle",className:"bg-white",width:"32",height:"32"}),g.jsx("span",{className:"nav-text",children:r("navbar.myaccount")})]})}),g.jsx(vr,{children:g.jsx("hr",{className:"dropdown-divider"})}),g.jsx(vr,{children:g.jsxs("a",{href:"/auth/logout?callback="+(($==null?void 0:$.logoutCallback)??"/"),className:"nav-link dropdown-item",children:[g.jsx(F3,{className:"icon logout"}),g.jsx("span",{id:"logout-label",className:"nav-text",children:r("navbar.disconnect")})]})})]})]})})]})]})})})},ffe=hfe,pfe=({children:t,headless:e=!1,...r})=>{const{theme:n}=ba(),{t:i}=we(),{showCookiesConsent:s,handleConsultCookies:o,handleCloseCookiesConsent:a}=ofe();ide(),sde();const l=Re("d-flex flex-column bg-white",{"container-fluid":!e,"rounded-4 border":(n==null?void 0:n.is1d)&&!e,"mt-24":(n==null?void 0:n.is1d)&&!e}),u=e?null:g.jsx(ffe,{is1d:n==null?void 0:n.is1d,src:n==null?void 0:n.basePath}),c=s&&g.jsx(ta,{type:"info",className:"m-12 rgpd",isConfirm:!0,position:"bottom-right",button:g.jsx(it,{color:"tertiary",variant:"ghost",onClick:o,children:i("rgpd.cookies.banner.button.consult")}),onClose:a,children:i("rgpd.cookies.banner.text1")}),h=g.jsx($G,{containerClassName:"toaster-container",toastOptions:{position:"top-right"}});return g.jsxs(g.Fragment,{children:[u,g.jsx("main",{className:l,...r,children:t}),h,c]})},mfe=pfe,gfe="modulepreload",vfe=function(t){return"/"+t},Ik={},cr=function(e,r,n){let i=Promise.resolve();if(r&&r.length>0){document.getElementsByTagName("link");const s=document.querySelector("meta[property=csp-nonce]"),o=(s==null?void 0:s.nonce)||(s==null?void 0:s.getAttribute("nonce"));i=Promise.all(r.map(a=>{if(a=vfe(a),a in Ik)return;Ik[a]=!0;const l=a.endsWith(".css"),u=l?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${a}"]${u}`))return;const c=document.createElement("link");if(c.rel=l?"stylesheet":gfe,l||(c.as="script",c.crossOrigin=""),c.href=a,o&&c.setAttribute("nonce",o),document.head.appendChild(c),l)return new Promise((h,f)=>{c.addEventListener("load",h),c.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${a}`)))})}))}return i.then(()=>e()).catch(s=>{const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=s,window.dispatchEvent(o),!o.defaultPrevented)throw s})},yfe=t=>{let{activatorEvent:e,draggingNodeRect:r,transform:n}=t;if(r&&e){const i=Fy(e);if(!i)return n;const s=i.x-r.left,o=i.y-r.top;return{...n,x:n.x+s-r.width/2,y:n.y+o-r.height/2}}return n},xfe={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},bfe=t=>{let e;const r=new Set,n=(c,h)=>{const f=typeof c=="function"?c(e):c;if(!Object.is(f,e)){const m=e;e=h??(typeof f!="object"||f===null)?f:Object.assign({},e,f),r.forEach(y=>y(e,m))}},i=()=>e,l={setState:n,getState:i,getInitialState:()=>u,subscribe:c=>(r.add(c),()=>r.delete(c)),destroy:()=>{(xfe?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),r.clear()}},u=e=t(n,i,l);return l},wfe=t=>bfe;var b8={exports:{}},w8={},_8={exports:{}},S8={};/**
|
|
1390
|
+
`,gk="/",vk="*",Eu="",Nae="comment",Lae="declaration",Fae=function(t,e){if(typeof t!="string")throw new TypeError("First argument must be a string");if(!t)return[];e=e||{};var r=1,n=1;function i(y){var v=y.match(Aae);v&&(r+=v.length);var x=y.lastIndexOf(Dae);n=~x?y.length-x:n+y.length}function s(){var y={line:r,column:n};return function(v){return v.position=new o(y),u(),v}}function o(y){this.start=y,this.end={line:r,column:n},this.source=e.source}o.prototype.content=t;function a(y){var v=new Error(e.source+":"+r+":"+n+": "+y);if(v.reason=y,v.filename=e.source,v.line=r,v.column=n,v.source=t,!e.silent)throw v}function l(y){var v=y.exec(t);if(v){var x=v[0];return i(x),t=t.slice(x.length),v}}function u(){l(Rae)}function c(y){var v;for(y=y||[];v=h();)v!==!1&&y.push(v);return y}function h(){var y=s();if(!(gk!=t.charAt(0)||vk!=t.charAt(1))){for(var v=2;Eu!=t.charAt(v)&&(vk!=t.charAt(v)||gk!=t.charAt(v+1));)++v;if(v+=2,Eu===t.charAt(v-1))return a("End of comment missing");var x=t.slice(2,v-2);return n+=2,i(x),t=t.slice(v),n+=2,y({type:Nae,comment:x})}}function f(){var y=s(),v=l(Pae);if(v){if(h(),!l(Iae))return a("property missing ':'");var x=l(Mae),b=y({type:Lae,property:yk(v[0].replace(mk,Eu)),value:x?yk(x[0].replace(mk,Eu)):Eu});return l(kae),b}}function m(){var y=[];c(y);for(var v;v=f();)v!==!1&&(y.push(v),c(y));return y}return u(),m()};function yk(t){return t?t.replace(Oae,Eu):Eu}var jae=Fae;function M6(t,e){var r=null;if(!t||typeof t!="string")return r;for(var n,i=jae(t),s=typeof e=="function",o,a,l=0,u=i.length;l<u;l++)n=i[l],o=n.property,a=n.value,s?e(o,a,n):a&&(r||(r={}),r[o]=a);return r}iA.exports=M6;iA.exports.default=M6;var Bae=iA.exports,K1={};K1.__esModule=!0;K1.camelCase=void 0;var Uae=/^--[a-zA-Z0-9-]+$/,$ae=/-([a-z])/g,zae=/^[^-]+$/,Hae=/^-(webkit|moz|ms|o|khtml)-/,Vae=/^-(ms)-/,Gae=function(t){return!t||zae.test(t)||Uae.test(t)},Wae=function(t,e){return e.toUpperCase()},xk=function(t,e){return"".concat(e,"-")},Xae=function(t,e){return e===void 0&&(e={}),Gae(t)?t:(t=t.toLowerCase(),e.reactCompat?t=t.replace(Vae,xk):t=t.replace(Hae,xk),t.replace($ae,Wae))};K1.camelCase=Xae;(function(t){var e=rr&&rr.__importDefault||function(s){return s&&s.__esModule?s:{default:s}};t.__esModule=!0;var r=e(Bae),n=K1;function i(s,o){var a={};return!s||typeof s!="string"||(0,r.default)(s,function(l,u){l&&u&&(a[(0,n.camelCase)(l,o)]=u)}),a}t.default=i})(I6);var qae=T,Yae=I6.default;function Qae(t,e){if(!t||typeof t!="object")throw new TypeError("First argument must be an object");var r=typeof e=="function",n={},i={};for(var s in t){var o=t[s];if(r&&(n=e(s,o),n&&n.length===2)){i[n[0]]=n[1];continue}typeof o=="string"&&(i[o]=s)}return i}var Kae=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);function Zae(t,e){return t.indexOf("-")===-1?e&&typeof e.is=="string":!Kae.has(t)}var Jae={reactCompat:!0};function ele(t,e){if(t!=null)try{e.style=Yae(t,Jae)}catch{e.style={}}}var tle=qae.version.split(".")[0]>=16,k6=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);function rle(t){return!k6.has(t.name)}function nle(t){return t}var O6={PRESERVE_CUSTOM_ATTRIBUTES:tle,ELEMENTS_WITH_NO_TEXT_CHILDREN:k6,invertObject:Qae,isCustomComponent:Zae,setStyleProp:ele,canTextBeChildOfNode:rle,returnFirstArg:nle},Mf=Zi,bk=O6,ile=["checked","value"],sle=["input","select","textarea"],ole={reset:!0,submit:!0},D6=function(e,r){e=e||{};var n,i,s,o,a,l={},u=e.type&&ole[e.type];for(n in e){if(s=e[n],Mf.isCustomAttribute(n)){l[n]=s;continue}if(i=n.toLowerCase(),o=wk(i),o){switch(a=Mf.getPropertyInfo(o),ile.indexOf(o)!==-1&&sle.indexOf(r)!==-1&&!u&&(o=wk("default"+i)),l[o]=s,a&&a.type){case Mf.BOOLEAN:l[o]=!0;break;case Mf.OVERLOADED_BOOLEAN:s===""&&(l[o]=!0);break}continue}bk.PRESERVE_CUSTOM_ATTRIBUTES&&(l[n]=s)}return bk.setStyleProp(e.style,l),l};function wk(t){return Mf.possibleStandardNames[t]}var ale=T,lle=D6,Kp=O6,ule=Kp.setStyleProp,cle=Kp.canTextBeChildOfNode;function N6(t,e){e=e||{};for(var r=e.library||ale,n=r.cloneElement,i=r.createElement,s=r.isValidElement,o=[],a,l,u=typeof e.replace=="function",c=e.transform||Kp.returnFirstArg,h,f,m,y=e.trim,v=0,x=t.length;v<x;v++){if(a=t[v],u&&(h=e.replace(a),s(h))){x>1&&(h=n(h,{key:h.key||v})),o.push(c(h,a,v));continue}if(a.type==="text"){if(l=!a.data.trim().length,l&&a.parent&&!cle(a.parent)||y&&l)continue;o.push(c(a.data,a,v));continue}switch(f=a.attribs,dle(a)?ule(f.style,f):f&&(f=lle(f,a.name)),m=null,a.type){case"script":case"style":a.children[0]&&(f.dangerouslySetInnerHTML={__html:a.children[0].data});break;case"tag":a.name==="textarea"&&a.children[0]?f.defaultValue=a.children[0].data:a.children&&a.children.length&&(m=N6(a.children,e));break;default:continue}x>1&&(f.key=v),o.push(c(i(a.name,f,m),a,v))}return o.length===1?o[0]:o}function dle(t){return Kp.PRESERVE_CUSTOM_ATTRIBUTES&&t.type==="tag"&&Kp.isCustomComponent(t.name,t.attribs)}var hle=N6,Z1=YC,cd=cae,fle=D6,L6=hle;cd=typeof cd.default=="function"?cd.default:cd;var ple={lowerCaseAttributeNames:!1};function Ao(t,e){if(typeof t!="string")throw new TypeError("First argument must be a string");return t===""?[]:(e=e||{},L6(cd(t,e.htmlparser2||ple),e))}Ao.domToReact=L6;Ao.htmlToDOM=cd;Ao.attributesToProps=fle;Ao.Comment=Z1.Comment;Ao.Element=Z1.Element;Ao.ProcessingInstruction=Z1.ProcessingInstruction;Ao.Text=Z1.Text;var mle=Ao;Ao.default=Ao;const Wl=Po(mle);var I0=Wl.domToReact;Wl.htmlToDOM;var v_=Wl.attributesToProps;Wl.Comment;Wl.Element;Wl.ProcessingInstruction;Wl.Text;var gle=Object.defineProperty,vle=(t,e,r)=>e in t?gle(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,ff=(t,e,r)=>(vle(t,typeof e!="symbol"?e+"":e,r),r);const yle=async t=>await Me.conf().getPreference(t),xle=async t=>await Me.conf().savePreference(t,JSON.stringify({key:!1})),ble=t=>{const[e,r]=T.useState(!0),[n,i]=T.useState(!1);return T.useEffect(()=>{(async()=>{const s=await yle(t);if(s){const{key:o}=s;i(o);return}i(!0)})()},[t]),{isOpen:e,setIsOpen:r,isOnboarding:n,handleSavePreference:async()=>{await xle(t),r(!1)}}},wle=({id:t,items:e,modalOptions:r})=>{const[n]=Pn(),[i,s]=T.useState(),[o,a]=T.useState(0),{isOpen:l,isOnboarding:u,setIsOpen:c,handleSavePreference:h}=ble(t);T.useEffect(()=>{const b=document.createElement("link");return b.href="https://cdn.jsdelivr.net/npm/swiper@11/swiper-bundle.min.css",b.rel="stylesheet",b.type="text/css",document.head.appendChild(b),()=>{document.head.removeChild(b)}},[]);const{t:f}=we(),{title:m,prevText:y,closeText:v,nextText:x}=r;return u?mr.createPortal(g.jsxs(Ye,{id:"onboarding-modal",size:"md",isOpen:l,focusId:"nextButtonId",onModalClose:()=>c(!1),children:[g.jsx(Ye.Header,{onModalClose:()=>c(!1),children:f(m||"explorer.modal.onboarding.trash.title")}),g.jsx(Ye.Body,{children:g.jsx(o6,{modules:[cse],onSwiper:b=>{s(b)},onSlideChange:b=>{a(b.progress)},pagination:{clickable:!0},children:e.map((b,_)=>g.jsxs(a6,{children:[g.jsx(wo,{width:"270",height:"140",className:"mx-auto my-12",loading:"lazy",src:`${n}/${b.src}`,alt:f(b.alt)}),g.jsx("p",{children:f(b.text)})]},_))})}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{type:"button",color:"tertiary",variant:"ghost",onClick:()=>c(!1),children:f("explorer.modal.onboarding.trash.later")}),o>0&&g.jsx(it,{type:"button",color:"primary",variant:"outline",onClick:()=>i.slidePrev(),children:f(y||"explorer.modal.onboarding.trash.prev")}),o<1&&g.jsx(it,{id:"nextButtonId",type:"button",color:"primary",variant:"filled",onClick:()=>i.slideNext(),children:f(x||"explorer.modal.onboarding.trash.next")}),o===1&&g.jsx(it,{type:"button",color:"primary",variant:"filled",onClick:h,children:f(v||"explorer.modal.onboarding.trash.close")})]})]}),document.getElementById("portal")):null},_le=wle,F6=T.createContext(null),bh=()=>{const t=T.useContext(F6);if(!t)throw new Error("Cannot be rendered outside the Dropdown Component");return t},Sle=T.forwardRef(({label:t,disabled:e=!1,checked:r=!1,indeterminate:n=!1,...i},s)=>{const o=T.useRef(null);T.useImperativeHandle(s,()=>({...o.current})),T.useEffect(()=>{o.current.indeterminate=n},[o,n]);const a=T.useId(),l={type:"checkbox",checked:r,disabled:e,ref:o,className:Re(i.className,"form-check-input c-pointer"),id:a},u={...i,...l};return g.jsxs("div",{className:"form-check d-flex align-items-center gap-8",children:[g.jsx("input",{...u}),t&&g.jsx("label",{className:"form-check-label",htmlFor:u.id,children:t})]})}),Tm=Sle,Ele=({children:t,value:e,model:r,onChange:n})=>{const{itemProps:i,itemRefs:s,isFocused:o}=bh(),{onMenuItemKeyDown:a,onMenuItemMouseEnter:l}=i,u=T.useId(),c=r.includes(e),h={value:e,model:r,checked:c,readOnly:!0},f=Re("dropdown-item c-pointer",{focus:o===u});return g.jsx("div",{id:u,ref:m=>s.current[u]=m,role:"menuitemcheckbox","aria-checked":c,onMouseUp:()=>n(e),onKeyDown:m=>a(m,()=>n(e)),onMouseEnter:l,tabIndex:c?0:-1,className:f,children:g.jsxs("div",{className:"d-flex gap-8 align-items-center justify-content-between position-relative",children:[t,g.jsx(Tm,{...h})]})})},Tle=Ele,Cle=({type:t="action",icon:e,onClick:r,children:n,className:i,...s})=>{const{itemProps:o,itemRefs:a,isFocused:l}=bh(),{onMenuItemKeyDown:u,onMenuItemMouseEnter:c,onMenuItemClick:h}=o,f=v=>{r==null||r(v),t==="action"&&(h(),v.stopPropagation())},m=T.useId(),y=Re("dropdown-item",{focus:l===m},i);return g.jsx("div",{id:m,role:"menuitem",ref:v=>a.current[m]=v,tabIndex:l===m?0:-1,className:y,"aria-current":l===m,onClick:f,onMouseEnter:c,onKeyDown:v=>u(v,r),...s,children:g.jsxs("div",{className:"d-flex gap-8 align-items-center",children:[e,n]})})},Ale=Cle,Rle=T.forwardRef(({children:t,block:e,unstyled:r,...n},i)=>{const{menuProps:s,visible:o}=bh(),a=Re({"w-100":e,"bg-white shadow rounded-4 p-8":!r},s.className,n.className),l={...s,...n,className:a};return o?g.jsx("div",{ref:i,...l,children:t}):null}),Ple=Rle,Ile=T.forwardRef(({label:t,children:e},r)=>g.jsxs("div",{ref:r,role:"group",children:[g.jsx("span",{className:"small px-4",children:g.jsx("strong",{children:t})}),e]})),Mle=Ile,kle=T.forwardRef(({model:t,icon:e,label:r=!1,disabled:n=!1,checked:i,...s},o)=>{const a=T.useId(),l={type:"radio",checked:i,disabled:n,ref:o,className:Re(s.className,"form-check-input c-pointer",e&&"d-none"),id:a},u={...s,...l};return g.jsxs("div",{className:Re("form-check d-flex align-items-center gap-8",e&&"ps-0"),children:[g.jsx("input",{...u}),e&&g.jsx("label",{htmlFor:u.id,className:Re("c-pointer",t!==s.value&&"text-muted"),children:e}),!e&&r&&g.jsx("label",{className:"form-check-label",htmlFor:u.id,children:r})]})}),E2=kle,Ole=({children:t,value:e,model:r,onChange:n})=>{const{itemProps:i,itemRefs:s,isFocused:o}=bh(),{onMenuItemKeyDown:a,onMenuItemMouseEnter:l}=i,u=T.useId(),c={value:e,model:r,checked:e===r,readOnly:!0},h=Re("dropdown-item c-pointer",{focus:o===u});return g.jsx("div",{id:u,ref:f=>s.current[u]=f,role:"menuitemradio","aria-checked":e===r,onMouseUp:()=>n(e),onKeyDown:f=>a(f,()=>n(e)),onMouseEnter:l,tabIndex:e===r?0:-1,className:h,children:g.jsxs("div",{className:"d-flex gap-8 align-items-center justify-content-between position-relative",children:[t,g.jsx(E2,{...c,className:"position-absolute start-0 end-0 top-0 bottom-0 opacity-0"})]})})},Dle=Ole,Nle=()=>g.jsx("div",{role:"separator",className:"px-4",children:g.jsx("hr",{className:"m-0"})}),Lle=Nle,Fle=T.forwardRef(({label:t,icon:e,variant:r,disabled:n=!1,size:i,badgeContent:s,hideCarret:o=!1,...a},l)=>{const{triggerProps:u,block:c}=bh(),h=Re("dropdown-toggle ",i,r,{"w-100":c},u.className,a.className),f={...u,...a,className:h};return g.jsxs("button",{ref:l,type:"button",disabled:n,...f,children:[e,t,s?g.jsx("span",{className:"badge text-bg-secondary rounded-pill",children:s}):!o&&g.jsx(vz,{width:16,height:16,className:"dropdown-toggle-caret"})]})}),jle=Fle;function j6(){return{xs:$c("only screen and (min-width: 0)"),sm:$c("only screen and (min-width: 375px)"),md:$c("only screen and (min-width: 768px)"),lg:$c("only screen and (min-width: 1024px)"),xl:$c("only screen and (min-width: 1280px)"),xxl:$c("only screen and (min-width: 1400px)")}}function B6(t){var e,r,n;const i=new Hq(t),s=i.getOS(),o=i.getDevice(),a=i.getBrowser(),l=((e=o.model)==null?void 0:e.indexOf("iPhone"))!=-1,u=((r=o.model)==null?void 0:r.indexOf("iPod"))!=-1,c=((n=o.model)==null?void 0:n.indexOf("iPad"))!=-1;return{os:s,device:o,browser:a,isIphone:l,isIpod:u,isIpad:c}}const _k=["mousedown","touchstart"];function U6(t,e,r){const n=T.useRef();return T.useEffect(()=>{const i=s=>{const{target:o}=s??{};if(Array.isArray(r)){const a=(o==null?void 0:o.hasAttribute("data-ignore-outside-clicks"))||!document.body.contains(o)&&o.tagName!=="HTML";r.every(l=>!!l&&!s.composedPath().includes(l))&&!a&&t()}else n.current&&!n.current.contains(o)&&t()};return _k.forEach(s=>{document.addEventListener(s,i)}),()=>{_k.forEach(s=>{document.removeEventListener(s,i)})}},[n,t,r,e]),n}function sA(t,e){const[r,n]=T.useState(t);return T.useEffect(()=>{const i=setTimeout(()=>{n(t)},e||500);return()=>{clearTimeout(i)}},[t,e]),r}function T2(...t){return e=>{Ble(e,...t)}}function Ble(t,...e){e.forEach(r=>{typeof r=="function"?r(t):r!=null&&(r.current=t)})}const Ule=(t,e,r=!1)=>{const n=T.useId(),[i,s]=T.useState(!1),[o,a]=T.useState(-1),[l,u]=T.useState(null),{refs:c,floatingStyles:h,context:f}=QH({placement:t,open:i,onOpenChange:s,whileElementsMounted:AH,middleware:[OH(4),NH({apply({rects:j,elements:H}){H.floating.style.minWidth=`${j.reference.width}px`}}),DH({padding:0})]});GH(f,{enabled:r,delay:{open:200},handleClose:ZH()});const m=T.useRef(null),y=T.useRef(null),v=T.useRef({});T.useEffect(()=>{i?m.current&&(m.current.focus(),a(0)):(a(-1),v.current={})},[i]),T.useEffect(()=>{if(o!==-1){const j=Object.values(v.current)[o];if(j){const H=j.getAttribute("id");u(H),j.focus()}}},[o]);const x=()=>{const j=Object.values(v.current).length;a(H=>(H+1)%j)},b=()=>{const j=Object.values(v.current).length;a(H=>(H-1+j)%j)},_=()=>{a(0)},w=()=>{const j=Object.values(v.current).length;a(j-1)},E=T.useCallback(()=>{s(!0)},[]),A=T.useCallback(()=>{y.current&&(y.current.focus({preventScroll:!0}),s(!1))},[]),P=(j,H)=>{j&&(H.stopPropagation(),H.preventDefault())},I=T.useCallback(j=>{let H=!1;switch(j.code){case" ":case"Space":case"Enter":case"ArrowDown":case"Down":E(),H=!0;break;case"Esc":case"Escape":A(),H=!0;break;case"Up":case"ArrowUp":E(),H=!0;break}e==null||e(j),P(H,j)},[A,E]),M=j=>{const H=Object.values(v.current).findIndex(F=>F.id===j.currentTarget.getAttribute("id"));a(H)},N=T.useCallback((j,H)=>{let F=!1;if(j.shiftKey)j.key==="Tab"&&(A(),F=!0);else{switch(j.code){case"Escape":A();break;case" ":case"Enter":o!==-1&&(Object.values(v.current)[o].getAttribute("role")==="menuitem"&&y.current&&(y.current.focus(),s(!1)),H==null||H()),F=!0;break;case"ArrowDown":case"Down":x(),F=!0;break;case"ArrowUp":case"Up":b(),F=!0;break;case"Home":_(),F=!0;break;case"End":w(),F=!0;break}P(F,j)}},[o,A]),z=T.useCallback(j=>{s(i!==!0),j.stopPropagation(),j.preventDefault()},[i]);return{isFocused:l,visible:i,itemRefs:v,triggerRef:y,menuRef:m,triggerProps:{ref:T2(y,c.setReference),id:`dropdown-toggle-${n}`,"aria-haspopup":"menu","aria-controls":`dropdown-${n}`,"aria-expanded":!!i,className:`${i?"selected":""}`,onClick:z,onKeyDown:I,"aria-activedescendant":l},menuProps:{ref:T2(m,c.setFloating),className:"dropdown-menu","aria-labelledby":`dropdown-toggle-${n}`,style:{...h}},itemProps:{onMenuItemMouseEnter:M,onMenuItemClick:A,onMenuItemKeyDown:N},setVisible:s}},$le=Ule,zle=t=>{const[e,r]=T.useState(!1),[n,i]=T.useState([]),s=T.useRef(null),o=v=>{c([v])},a=v=>{i(x=>x.filter(b=>b.name!==v.name))},l=(v,x)=>{i(b=>{if(0<=v&&v<b.length){const _=b.slice(0,v),w=v===b.length-1?[]:b.slice(v+1);return[..._,x,...w]}return b})},u=v=>{var x;let b=v;if((x=s.current)!=null&&x.accept){const _=s.current.accept.split(",").map(A=>A.trim().toLowerCase()),w=_.filter(A=>A.startsWith(".")),E=_.filter(A=>!A.startsWith(".")).map(A=>A.replace("*",""));b=[],v.forEach(A=>{const P=A.name.toLowerCase();(w.some(I=>P.endsWith(I))||E.some(I=>A.type.includes(I)))&&b.push(A)})}return b},c=v=>{let x=v.map(b=>new File([b],b.name.replace(/[!:,;="']/g,""),{type:b.type}));t!=null&&t.forceFilters?(x=u(x),x&&x.length&&i(b=>[...b,...x])):i(b=>[...b,...v])},h=()=>{i([])},f=v=>{const x=v.target.files;x&&c([...x])},m=v=>{v.preventDefault(),v.stopPropagation(),r(!0)},y=v=>{v.preventDefault(),v.stopPropagation(),r(!1)};return{inputRef:s,files:n,dragging:e,handleDragging:m,handleDragLeave:y,handleDrop:v=>{var x;y(v);const b=(x=v.dataTransfer)==null?void 0:x.files;b&&(c([...b]),s!=null&&s.current&&(s.current.files=b))},replaceFileAt:l,deleteFile:a,addFile:o,addFiles:c,cleanFiles:h,handleOnChange:f}},Hle=zle;function $6(){const[t,e]=T.useState(!1),r=T.useRef(null),n=()=>{e(!0)},i=()=>{e(!1)};return T.useEffect(()=>{const s=r.current;if(s)return s.addEventListener("mouseover",n),s.addEventListener("mouseout",i),()=>{s.removeEventListener("mouseover",n),s.removeEventListener("mouseout",i)}},[r]),[r,t]}function Vle(t,e){const r=T.useCallback(({code:n})=>{e.includes(n)&&t()},[t,e]);T.useEffect(()=>(window.addEventListener("keydown",r),()=>{window.removeEventListener("keydown",r)}),[r])}function z6(){const t=document.querySelector("html");return()=>{t&&t.scrollIntoView()}}const Gle=T.forwardRef(({icon:t,className:e,...r},n)=>{const i={...r,className:Re("btn-icon btn-sm",e)};return g.jsx(it,{ref:n,...i,children:t})}),Ro=Gle,Wle=T.forwardRef(({icon:t=g.jsx(AS,{}),onClick:e,className:r,...n},i)=>{const s=Re("btn-search",r);return g.jsx(Ro,{ref:i,className:s,icon:t,onClick:e,...n})}),oA=Wle,Xle=T.forwardRef(({type:t="success",className:e="",children:r,button:n,isDismissible:i=!1,isToast:s=!1,isConfirm:o=!1,position:a="none",autoClose:l=!1,autoCloseDelay:u=3e3,onClose:c,onVisibilityChange:h},f)=>{const[m,y]=T.useState(!0),v=T.useRef(null),{t:x}=we(),b=T.useCallback(()=>{y(!1),c==null||c()},[c]);T.useImperativeHandle(f,()=>({show:_,hide:b,...v.current})),T.useLayoutEffect(()=>{h==null||h(m)},[m,h]),T.useEffect(()=>{l&&m&&setTimeout(()=>{b()},u)},[l,u,b,m]);const _=()=>{y(!0)},w={success:{icon:g.jsx(WN,{}),classModifier:"alert-success"},warning:{icon:g.jsx(R$,{}),classModifier:"alert-warning"},info:{icon:g.jsx(BN,{}),classModifier:"alert-info"},danger:{icon:g.jsx(Q$,{}),classModifier:"alert-danger"}},E={"is-dismissible":i,"is-toast ":s},A={"is-confirm":o},P=Re("alert gap-12",w[t].classModifier,E,A,a,e);return g.jsx(g.Fragment,{children:m?g.jsxs("div",{ref:v,className:P,role:"alert",children:[!o&&w[t].icon,g.jsx("div",{className:"alert-content small",children:r}),n&&g.jsxs("div",{className:"ms-12",children:[n," ",o&&g.jsx(it,{onClick:b,children:x("close")})]}),(i||o)&&g.jsx("div",{className:"btn-close-container",children:g.jsx("button",{type:"button",className:"btn-close","data-bs-dismiss":"alert","aria-label":x("close"),onClick:b})}),l&&g.jsx("div",{className:"alert-progress",style:{transform:"scaleX(0)"}})]}):null})}),ta=Xle,M0="top-right";function en(){return{success:(t,e)=>lu.custom(g.jsx(ta,{type:"success",isToast:!0,isDismissible:e==null?void 0:e.isDismissible,className:"mb-12",children:t}),{id:e==null?void 0:e.id,duration:e==null?void 0:e.duration,position:(e==null?void 0:e.position)??M0}),error:(t,e)=>lu.custom(g.jsx(ta,{type:"danger",isToast:!0,isDismissible:e==null?void 0:e.isDismissible,className:"mb-12",children:t}),{id:e==null?void 0:e.id,duration:e==null?void 0:e.duration,position:(e==null?void 0:e.position)??M0}),info:(t,e)=>lu.custom(g.jsx(ta,{type:"info",isToast:!0,isDismissible:e==null?void 0:e.isDismissible,className:"mb-12",children:t}),{id:e==null?void 0:e.id,duration:e==null?void 0:e.duration,position:(e==null?void 0:e.position)??M0}),warning:(t,e)=>lu.custom(g.jsx(ta,{type:"warning",isToast:!0,isDismissible:e==null?void 0:e.isDismissible,className:"mb-12",children:t}),{id:e==null?void 0:e.id,duration:e==null?void 0:e.duration,position:(e==null?void 0:e.position)??M0}),loading:lu.loading,dismiss:t=>lu.dismiss(t),remove:t=>lu.remove(t)}}function Cm(t=!1){const[e,r]=T.useState(t),n=T.useCallback(()=>{r(i=>!i)},[]);return[e,n]}function qle(){const t=T.useRef(null),e='button:not([disabled]), [href], input, select, textarea, [tabindex]:not([tabindex="-1"])';return T.useEffect(()=>{const r=t.current,n=r.querySelectorAll(e)[0],i=r.querySelectorAll(e),s=t&&(i==null?void 0:i[i.length-1]),o=a=>{a.key==="Tab"&&(a.shiftKey?document.activeElement===n&&(s.focus(),a.preventDefault()):document.activeElement===s&&(n.focus(),a.preventDefault()))};if(r)return r.addEventListener("keydown",o),()=>{r.removeEventListener("keydown",o)}},[]),t}const Yle=({children:t,block:e,overflow:r=!0,placement:n="bottom-start",extraTriggerKeyDownHandler:i,onToggle:s,isTriggerHovered:o=!1})=>{const{visible:a,isFocused:l,triggerProps:u,menuProps:c,itemProps:h,itemRefs:f,setVisible:m}=$le(n,i,o),y=U6(()=>{m(!1)}),v=T.useMemo(()=>({visible:a,isFocused:l,triggerProps:u,menuProps:c,itemProps:h,itemRefs:f,block:e,setVisible:m}),[a,l,u,c,h,f,e,m]),x=Re("dropdown",{"w-100":e,overflow:r});return T.useEffect(()=>{s==null||s(a)},[a]),g.jsx(F6.Provider,{value:v,children:g.jsx("div",{ref:y,className:x,children:typeof t=="function"?t(u,f,m):t})})},Qle=Object.assign(Yle,{Trigger:jle,Menu:Ple,Item:Ale,Separator:Lle,CheckboxItem:Tle,RadioItem:Dle,MenuGroup:Mle}),xt=Qle,Kle=()=>{const{t}=we();return[{value:"bpr.activityType.classroomActivity",label:t("bpr.activityType.classroomActivity")},{value:"bpr.activityType.groupActivity",label:t("bpr.activityType.groupActivity")},{value:"bpr.activityType.personalActivity",label:t("bpr.activityType.personalActivity")},{value:"bpr.activityType.homework",label:t("bpr.activityType.homework")},{value:"bpr.activityType.exercize",label:t("bpr.activityType.exercize")},{value:"bpr.activityType.learningPath",label:t("bpr.activityType.learningPath")},{value:"bpr.activityType.courseElement",label:t("bpr.activityType.courseElement")},{value:"bpr.other",label:t("bpr.other")}]},Zle=({control:t,selectedActivities:e,selectActivities:r})=>{const n=Kle(),{t:i}=we();return g.jsx("div",{className:"col d-flex",children:g.jsx(u1,{name:"activityType",control:t,rules:{required:!0},render:({field:{onChange:s}})=>g.jsxs(xt,{block:!0,overflow:!0,children:[g.jsx(xt.Trigger,{size:"md",label:i("bpr.form.publication.type"),badgeContent:e==null?void 0:e.length}),g.jsx(xt.Menu,{children:n.map((o,a)=>g.jsx(xt.CheckboxItem,{value:o.value,model:e,onChange:()=>{r(o.value),s(o.value)},children:o.label},a))})]})})})},Jle=t=>g.jsx(xt.Trigger,{...t,"aria-haspopup":"listbox",role:"combobox"}),eue=Jle,tue=({icon:t,options:e,overflow:r,block:n,variant:i,size:s,disabled:o,placeholderOption:a,onValueChange:l})=>{const[u,c]=T.useState(),{t:h}=we();T.useEffect(()=>{if(u){const y=typeof u=="object"?u.value:u;l==null||l(y)}},[u]);const f=typeof u=="object"?u.label:u,m=typeof u=="object"?u.icon:void 0;return g.jsxs(xt,{overflow:r,block:n,children:[g.jsx(eue,{icon:m||t,label:h(f||a),variant:i,size:s,disabled:o}),g.jsx(xt.Menu,{role:"listbox",children:e==null?void 0:e.map(y=>{const v=typeof y=="object"?y.value:y,x=typeof y=="object"?y.label:y,b=typeof y=="object"?y.icon:void 0;return g.jsx(xt.Item,{type:"action",onClick:()=>c(y),icon:b,children:x},v)})})]})},aA=tue,rue=["3","4","5","6","7","8","9","10","11","12","13","14","15","16","17","18"],Sk=({name:t,control:e,placeholderOption:r,validate:n})=>g.jsx(u1,{name:t,control:e,rules:{required:!0,validate:n},render:({field:{onChange:i}})=>g.jsx(aA,{block:!0,size:"md",onValueChange:i,options:rue,"aria-required":!0,placeholderOption:r})}),nue=()=>{const{t}=we();return[{value:"de_DE",label:t("de_DE")},{value:"en_EN",label:t("en_EN")},{value:"ar_DZ",label:t("ar_DZ")},{value:"es_ES",label:t("es_ES")},{value:"fr_FR",label:t("fr_FR")},{value:"it_IT",label:t("it_IT")},{value:"ja_JP",label:t("ja_JP")},{value:"zh_CN",label:t("zh_CN")},{value:"pt_PT",label:t("pt_PT")},{value:"ru_RU",label:t("ru_RU")},{value:"bpr.other",label:t("bpr.other")}]},iue="bpr.form.publication.language",sue=({control:t})=>{const e=nue();return g.jsx("div",{className:"col",children:g.jsx(u1,{name:"language",control:t,rules:{required:!0},render:({field:{onChange:r}})=>g.jsx(aA,{block:!0,size:"md",onValueChange:r,options:e,"aria-required":!0,placeholderOption:iue})})})},oue=()=>{const{t}=we(),[e]=Pn();return g.jsxs(g.Fragment,{children:[g.jsxs("ul",{className:"mb-12",children:[g.jsxs("li",{children:[t("bpr.form.publication.licence.text.1"),g.jsx("img",{className:"ms-8 d-inline-block",src:`${e}/common/image-creative-commons.png`,alt:"licence creative commons"})]}),g.jsx("li",{children:t("bpr.form.publication.licence.text.2")})]}),g.jsx(ta,{type:"info",className:"mb-12",children:t("bpr.form.publication.licence.text.3")}),g.jsx(ta,{type:"warning",children:t("bpr.form.publication.licence.text.4")})]})},aue=()=>{const{t}=we();return[{value:"bpr.subjectArea.artActivity",label:t("bpr.subjectArea.artActivity")},{value:"bpr.subjectArea.readLearning",label:t("bpr.subjectArea.readLearning")},{value:"bpr.subjectArea.chemistry",label:t("bpr.subjectArea.chemistry")},{value:"bpr.subjectArea.law",label:t("bpr.subjectArea.law")},{value:"bpr.subjectArea.worldDiscovery",label:t("bpr.subjectArea.worldDiscovery")},{value:"bpr.subjectArea.economy",label:t("bpr.subjectArea.economy")},{value:"bpr.subjectArea.mediaEducation",label:t("bpr.subjectArea.mediaEducation")},{value:"bpr.subjectArea.musicEducation",label:t("bpr.subjectArea.musicEducation")},{value:"bpr.subjectArea.sportEducation",label:t("bpr.subjectArea.sportEducation")},{value:"bpr.subjectArea.citizenshipEducation",label:t("bpr.subjectArea.citizenshipEducation")},{value:"bpr.subjectArea.geography",label:t("bpr.subjectArea.geography")},{value:"bpr.subjectArea.history",label:t("bpr.subjectArea.history")},{value:"bpr.subjectArea.artHistory",label:t("bpr.subjectArea.artHistory")},{value:"bpr.subjectArea.ComputerScience",label:t("bpr.subjectArea.ComputerScience")},{value:"bpr.subjectArea.languages",label:t("bpr.subjectArea.languages")},{value:"bpr.subjectArea.italian",label:t("bpr.subjectArea.italian")},{value:"bpr.subjectArea.spanish",label:t("bpr.subjectArea.spanish")},{value:"bpr.subjectArea.french",label:t("bpr.subjectArea.french")},{value:"bpr.subjectArea.german",label:t("bpr.subjectArea.german")},{value:"bpr.subjectArea.english",label:t("bpr.subjectArea.english")},{value:"bpr.subjectArea.ancientLanguages",label:t("bpr.subjectArea.ancientLanguages")},{value:"bpr.subjectArea.literature",label:t("bpr.subjectArea.literature")},{value:"bpr.subjectArea.mathematics",label:t("bpr.subjectArea.mathematics")},{value:"bpr.subjectArea.vocationalGuidance",label:t("bpr.subjectArea.vocationalGuidance")},{value:"bpr.subjectArea.philosohppy",label:t("bpr.subjectArea.philosohppy")},{value:"bpr.subjectArea.physics",label:t("bpr.subjectArea.physics")},{value:"bpr.subjectArea.politicalSscience",label:t("bpr.subjectArea.politicalSscience")},{value:"bpr.subjectArea.sociology",label:t("bpr.subjectArea.sociology")},{value:"bpr.subjectArea.biology",label:t("bpr.subjectArea.biology")},{value:"bpr.subjectArea.geology",label:t("bpr.subjectArea.geology")},{value:"bpr.subjectArea.technology",label:t("bpr.subjectArea.technology")},{value:"bpr.subjectArea.Arabic",label:t("bpr.subjectArea.Arabic")},{value:"bpr.subjectArea.Chinese",label:t("bpr.subjectArea.Chinese")},{value:"bpr.subjectArea.NaturalSciences",label:t("bpr.subjectArea.NaturalSciences")},{value:"bpr.subjectArea.SocioEmotionalEducation",label:t("bpr.subjectArea.SocioEmotionalEducation")},{value:"bpr.other",label:t("bpr.other")}]},lue=({control:t,selectedSubjectAreas:e,selectSubjects:r})=>{const n=aue(),{t:i}=we();return g.jsx("div",{className:"col d-flex",children:g.jsx(u1,{name:"subjectArea",control:t,rules:{required:!0},render:({field:{onChange:s}})=>g.jsxs(xt,{block:!0,overflow:!0,children:[g.jsx(xt.Trigger,{size:"md",label:i("bpr.form.publication.discipline"),badgeContent:e==null?void 0:e.length}),g.jsx(xt.Menu,{children:n.map((o,a)=>g.jsx(xt.CheckboxItem,{value:o.value,model:e,onChange:()=>{r(o.value),s(o.value)},children:o.label},a))})]})})})},H6=T.createContext(null);function uue({defaultTheme:t,children:e}){var r;const{appCode:n}=yt(),i=TL({appCode:n});T.useEffect(()=>{var o,a,l,u,c,h,f,m,y,v,x;const b=document.getElementById("favicon");b.href=`${(a=(o=i==null?void 0:i.data)==null?void 0:o.theme)==null?void 0:a.basePath}/img/illustrations/favicon.ico`;const _=(c=(u=(l=i==null?void 0:i.data)==null?void 0:l.theme)==null?void 0:u.bootstrapVersion)==null?void 0:c.split("-"),w=_?_[_.length-1]:void 0;[{data:"data-skin",value:(f=(h=i==null?void 0:i.data)==null?void 0:h.theme)==null?void 0:f.skinName},{data:"data-theme",value:((y=(m=i==null?void 0:i.data)==null?void 0:m.theme)==null?void 0:y.npmTheme)??((x=(v=i==null?void 0:i.data)==null?void 0:v.theme)==null?void 0:x.themeName)},{data:"data-product",value:t==="none"?"":t??w}].forEach(E=>{var A;return(A=document.querySelector("html"))==null?void 0:A.setAttribute(E.data,E.value)})},[i==null?void 0:i.data,t]);const s=T.useMemo(()=>{var o;return{theme:(o=i==null?void 0:i.data)==null?void 0:o.theme}},[(r=i==null?void 0:i.data)==null?void 0:r.theme]);return g.jsx(H6.Provider,{value:s,children:e})}function ba(){const t=T.useContext(H6);if(!t)throw new Error("Cannot be used outside of OdeClientProvider");return t}const cue=({children:t,space:e=null,flexDirection:r="row"})=>{const n=Re("card-body",{[`p-${e}`]:e,[`gap-${e}`]:e,"align-items-start":r==="column","flex-column":r==="column"});return g.jsx("div",{className:n,children:t})},due=cue,V6=T.createContext(null),G6=()=>{const t=T.useContext(V6);if(!t)throw new Error("Cannot be rendered outside the Card component");return t},hue=({children:t})=>g.jsx("div",{className:"card-footer gap-16",children:t}),fue=hue,pue=()=>{const{isSelectable:t,isClickable:e,onClick:r,onSelect:n}=G6(),{t:i}=we();return t||e?g.jsxs("div",{className:"card-header",children:[t?g.jsx(Ro,{"aria-label":i("card.open.menu"),className:"z-3 bg-white",color:"secondary",icon:g.jsx(lz,{}),onClick:n,variant:"ghost"}):null,e?g.jsx("button",{type:"button",onClick:r,className:"position-absolute bottom-0 end-0 top-0 start-0 opacity-0 z-1 w-100","aria-label":i("card.open.resource")}):null]}):null},mue=pue,gue=T.forwardRef(({app:t,size:e="24",iconFit:r="contain",variant:n="square",className:i=""},s)=>{const{isIconUrl:o,getIconCode:a}=cA(),[,l]=Pn(),u=n==="square",c=n==="rounded",h=n==="circle",f=r==="contain",m=r==="ratio",y={"icon-xs":e==="24","icon-sm":e==="40","icon-md":e==="48","icon-lg":e==="80","icon-xl":e==="160"},v={square:u,rounded:c,"rounded-circle":h},x={"icon-contain":f,"icon-ratio":m},b=typeof t=="string"?t:(t==null?void 0:t.icon)!==void 0?t.icon:"placeholder",_=typeof t!="string"&&(t==null?void 0:t.displayName)!==void 0?t.displayName:"",w=t?a(t):"",E=o(b),A=w||"placeholder";if(E){const I=Re("h-full",i);return g.jsx(wo,{src:b,alt:_,objectFit:"contain",width:e,height:e,className:I,style:{minWidth:e+"px"}})}const P=Re("app-icon",{...y,...v,...x,[`bg-light-${A}`]:A&&!f,[`color-app-${A}`]:A},i);return g.jsx("div",{className:P,style:{width:e+"px",height:e+"px"},children:g.jsx("svg",{ref:s,width:e,height:e,role:"img",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:g.jsx("use",{xlinkHref:`${l}/apps.svg#${A}`})})})}),ya=gue,vue=({imageSrc:t,className:e,variant:r="medium"})=>{const{app:n}=G6(),i=r==="landscape"?{width:"100%",height:"auto"}:null;return g.jsx("div",{className:Re("card-image",r),children:t?g.jsx(wo,{alt:"",src:t,objectFit:"cover",className:Re("h-full w-100",e)}):g.jsx(ya,{app:n,iconFit:"ratio",size:"80",variant:"rounded",...i})})},yue=vue,xue=({children:t,className:e})=>{const r=Re("card-text small text-break text-truncate text-truncate-1",e);return g.jsx("p",{className:r,children:t})},bue=xue,wue=({children:t,className:e})=>{const r=Re("card-title body text-break text-truncate text-truncate-2",e);return g.jsx("h3",{className:r,children:g.jsx("strong",{children:t})})},_ue=wue,Sue=({userSrc:t,creatorName:e})=>t?g.jsx(rc,{alt:e||"",size:"xs",src:t,variant:"circle",width:"24",height:"24"}):g.jsx(bC,{}),Eue=Sue,Tue=T.forwardRef(({app:t,isSelectable:e=!0,isClickable:r=!0,isSelected:n=!1,isFocused:i=!1,onClick:s,onSelect:o,children:a,className:l},u)=>{const{getIconCode:c}=cA(),h=t?c(t):"placeholder",f=T.useMemo(()=>({app:t,appCode:h,isSelectable:e,isClickable:r,onClick:s,onSelect:o}),[t,h,e,r,s,o]);return g.jsx(V6.Provider,{value:f,children:g.jsxs("div",{ref:u,className:Re("card",{"drag-focus":i,"is-selected":n,"c-pointer":r},l),children:[g.jsx(W6.Header,{}),typeof a=="function"?a(h):a]})})}),W6=Object.assign(Tue,{Title:_ue,Text:bue,Image:yue,Body:due,User:Eue,Footer:fue,Header:mue}),tr=W6;function Cue(t,e){const[r,n]=T.useState(null),{ref:i,inView:s}=tse({triggerOnce:!0,...e==null?void 0:e.intersectionOptions});return T.useEffect(()=>{var o;(o=e==null?void 0:e.ref)!=null&&o.current&&(i==null||i(e.ref.current))},[e==null?void 0:e.ref,i]),T.useEffect(()=>{if((e==null?void 0:e.ref)===void 0||s){const o=new Image;return o.src=t,o.onload=()=>{n(!0)},o.onerror=()=>{n(!1)},()=>{o.onload=null,o.onerror=null,n(null)}}},[s]),r}const Aue=({type:t,roleMap:e})=>{const r=typeof(e==null?void 0:e.icon)!="string"&&t!=="unknown",n=Re("position-absolute top-50 start-50 translate-middle",{"p-12 rounded-circle shadow":r},e==null?void 0:e.color);return g.jsx("div",{className:n,children:(e==null?void 0:e.icon)??g.jsx(cz,{})})},Rue=Aue,Pue=({doc:t,isClickable:e=!0,isSelectable:r=!1,isSelected:n=!1,onClick:i,className:s})=>{var o;const a=T.useRef(null),l=Vk.getRole(t);function u(y){const v={csv:{icon:".CSV",color:"bg-orange-200"},xls:{icon:".XLS",color:"bg-green-200"},doc:{icon:".DOC",color:"bg-blue-200"},txt:{icon:".TXT",color:"bg-blue-200"},pdf:{icon:".PDF",color:"bg-red-200"},audio:{icon:g.jsx(c1,{width:22,height:22}),color:"bg-red-200"},ppt:{icon:".PPT",color:"bg-yellow-200"},img:{icon:g.jsx(iz,{width:22,height:22}),color:"bg-green-200"},video:{icon:g.jsx(Gz,{width:22,height:22}),color:"bg-purple-200"},zip:{icon:".ZIP",color:"bg-gray-300"},md:{icon:".MD",color:"bg-blue-200"},unknown:{icon:g.jsx(Uz,{width:22,height:22}),color:"bg-gray-300"}};return v[y]||v.unknown}const c=Re("file position-relative rounded",((o=u(l??"default"))==null?void 0:o.color)??"bg-yellow-200"),h=l==="img"||l==="video"?Me.workspace().getThumbnailUrl(t):null,f=Cue(h,{ref:a}),m=f&&{backgroundImage:`url(${h})`,backgroundSize:"cover"};return g.jsx(tr,{className:Re("card-file",s),isClickable:e,isSelectable:r,isSelected:n,onClick:i,children:g.jsxs(tr.Body,{space:"8",children:[g.jsx("div",{ref:a,className:c,style:{aspectRatio:"16/10",...m},children:l!=="img"||l==="img"&&!f?g.jsx(Rue,{type:l,roleMap:u(l)}):null}),g.jsxs("div",{className:"mt-4",children:[g.jsx(tr.Text,{children:t.name}),g.jsx(tr.Text,{className:"text-black-50",children:t==null?void 0:t.ownerName})]})]})})},Iue=Pue,Mue=({item:t,status:e="idle",isClickable:r=!1,isSelectable:n=!1,onDelete:i,onEdit:s,onRetry:o})=>{const[a]=Pn(),{t:l}=we(),{src:u,name:c,info:h}=t,f=e==="idle",m=e==="loading",y=e==="success",v=h==null?void 0:h.type.startsWith("image"),x=`${a}/common/image-placeholder.png`,b={text:"",context:null,image:g.jsx("img",{src:x,alt:"",width:"48",height:"48"})},_={error:{text:g.jsx("strong",{children:g.jsx("small",{className:"text-danger caption",children:l("tiptap.upload.error")})}),context:g.jsx(it,{leftIcon:g.jsx(GN,{}),variant:"ghost",color:"tertiary",onClick:o,children:l("tiptap.upload.retry")}),image:g.jsx(wo,{alt:"",src:`${a}/common/image-status-error.svg`,objectFit:"cover"})},idle:b,loading:{text:"",context:g.jsx(fo,{message:l("tiptap.tooltip.upload.loading"),placement:"top",children:g.jsx(YT,{isLoading:!0,loadingPosition:"left",className:"text-secondary"})}),image:b.image},warning:b,success:{text:g.jsxs("em",{children:[h==null?void 0:h.type," ",(h==null?void 0:h.weight)&&`- ${h.weight}`]}),context:g.jsx(fo,{message:l("tiptap.tooltip.upload.loaded"),placement:"top",children:g.jsx(WN,{className:"text-success"})}),image:g.jsx(wo,{alt:"",src:u??"",width:"48",objectFit:"cover",className:"rounded",style:{aspectRatio:1/1}})},unknown:b},w=()=>v&&g.jsx(fo,{message:l("tiptap.tooltip.upload.edit"),placement:"top",children:g.jsx(Ro,{icon:g.jsx(Xz,{}),variant:"ghost","aria-label":l("tiptap.tooltip.upload.loading"),disabled:m||!y,onClick:s,color:"secondary"})});return g.jsx(tr,{isClickable:r,isSelectable:n,className:"card-upload",children:g.jsxs(tr.Body,{children:[g.jsx("div",{className:"card-image",children:_[e].image}),g.jsxs("div",{className:"text-truncate",children:[g.jsx(tr.Text,{children:c}),g.jsx(tr.Text,{className:"caption",children:_[e].text})]}),!f&&g.jsx("div",{className:"ms-auto",children:g.jsxs("div",{className:"d-flex align-items-center gap-12",children:[_[e].context,!f&&g.jsx("div",{className:"vr"}),w(),g.jsx(fo,{message:l("tiptap.tooltip.upload.delete"),placement:"top",children:g.jsx(Ro,{icon:g.jsx(NT,{}),variant:"ghost","aria-label":l("tiptap.tooltip.upload.delete"),color:"tertiary",onClick:i})})]})})]})})},kue=Mue,Oue=T.forwardRef(({children:t},e)=>g.jsx("div",{ref:e,className:"actionbar",children:t})),Due=Oue,Nue=T.forwardRef(({children:t,render:e,isFullscreen:r=!1,...n},i)=>{const s=Re("d-flex flex-wrap p-16 gap-8 border-bottom bg-white",{"justify-content-between":e,"mx-n16":!r,"z-3 top-0 start-0 end-0":r});return g.jsxs("div",{ref:i,className:s,...n,children:[t,e?g.jsx("div",{className:"d-flex align-items-center ms-auto gap-8",children:e()}):null]})}),Lue=Nue;function Ki(t,e){if(Array.isArray(t))for(const r of t){const n=Ki(r,e);if(n)return n}else{if(t.id===e)return t;if(t.children)for(const r of t.children){const n=Ki(r,e);if(n)return n}}}function Fue(t,{parentId:e,newFolder:r}){return Am(t,n=>{var i;if(n.id===e){const s=[...((i=n.folder)==null?void 0:i.ancestors)||[]],o=X6([...s,n.id]);return{...n,children:[...n.children||[],new lA({...r,ancestors:o})]}}else return n})}function X6(t){return t.filter((e,r)=>t.indexOf(e)===r)}function jue(t,{folders:e}){return Am(t,r=>{if(!e.includes(r.id))return r})}const q6=(t,e)=>{if(t.children)for(const r of t.children){if(r.id===e)return t;const n=q6(r,e);if(n)return n}};function C2(t,e){var r;const n=Ki(t,e);return(r=n==null?void 0:n.folder)!=null&&r.ancestors?[...(n==null?void 0:n.folder.ancestors)||[],e]:e===Er.BIN?[Er.BIN]:[Er.DEFAULT]}function Am(t,e){return Y6(t,e)||t}function Y6(t,e,r){var n;const i=e(t,r);if((n=i==null?void 0:i.children)!=null&&n.length){const s=[];for(const o of(i==null?void 0:i.children)||[]){const a=Y6(o,e,i);a&&s.push(a)}return{...i,children:s}}return i}function Bue(t,{destinationId:e,folders:r}){return Am(t,(n,i)=>{var s,o;if(e===n.id){const a=[...((s=n.folder)==null?void 0:s.ancestors)||[]],l=X6([...a,n.id]),u=[...n.children||[]],c=((o=n.children)==null?void 0:o.map(h=>h.id))||[];for(const h of r)if(!c.includes(h)){const f=Ki(n,h);f&&u.push({...f,folder:{...f==null?void 0:f.folder,ancestors:l}})}return{...n,children:u}}else return r.includes(n.id)&&e!==(i==null?void 0:i.id)?void 0:n})}const Uue=(t,e,r)=>Am(t,n=>(n.id===r&&(n.children=e==null?void 0:e.map(i=>new lA(i))),n));function $ue(t,{folderId:e,newFolder:r}){return Am(t,n=>n.id===e?new lA(r):n)}function zue(t,e){let r=[];function n(s,o){if(s.id===e)return r=o.concat(s.id),!0;if(s.children){for(const a of s.children)if(n(a,o.concat(s.id)))return!0}return!1}function i(s){if(Array.isArray(s)){for(const o of s)if(n(o,[]))break}else n(s,[])}return i(t),r}class lA{constructor(e){ff(this,"id"),ff(this,"name"),ff(this,"childNumber"),ff(this,"section",!1),ff(this,"children",[]),this.folder=e,this.id=e.id,this.name=e.name,this.childNumber=e.childNumber}}const Hue=T.createContext(null);function Q6(){return T.useContext(Hue)}class Ek{static isLocalURL(e){return e.length>0&&e.charAt(0)==="/"}static startWithHttp(e){return/^https?:\/\//gi.test(e)}static toCounter(e){return e>999?`${Number(e/1e3).toFixed(1)} k`:""+e}}function Vue(t){const e=new Date().getTime(),r=t.includes("?")?"&":"?";return`${t}${r}timestamp=${e}`}const pf=(t,e)=>{const r="virtualID";if(!Object.hasOwnProperty.apply(t,[r])){const n=e??`${LB.generateVirtualId()}#${t.size}`;Object.defineProperty(t,r,{value:n,writable:!1})}return t[r]};function K6(t,e){if(e(t))return t;if(Array.isArray(t.children))for(const r of t.children){const n=K6(r,e);if(n)return n}}const Vy=(t,e)=>{const r=e==null?void 0:e.filter(n=>n.id===t&&n.available);return r&&r.length>0},Z6={blog:"Blog",mindmap:"MindMap",scrapbook:"ScrapBook",collaborativewall:"CollaborativeWall",timelinegenerator:"TimelineGenerator",wiki:"Wiki",exercizer:"Exercizer"},pl=t=>{if(t>0){let e=Math.floor(t/1e3),r=Math.floor(e/60);return e=e%60,r=r%60,Tk(r)+":"+Tk(e)}return"00:00"},Tk=t=>t.toString().padStart(2,"0"),Gue=()=>MediaRecorder.isTypeSupported?["video/webm;codecs=vp9",'video/mp4; codecs="avc1.424028, mp4a.40.2"',"video/webm;codecs=vp8,opus","video/webm"].find(t=>MediaRecorder.isTypeSupported(t)?!0:(console.error(`${t} is not Supported`),!1))||"video/ogg":"video/webm;codecs=vp8,opus",J6=T.createContext({ariaLabelId:"",ariaDescriptionId:"",focusId:""}),e8=()=>{const t=T.useContext(J6);if(!t)throw new Error("Cannot be rendered outside the Modal component");return t},Wue=t=>{const{ariaDescriptionId:e}=e8(),{children:r,className:n}=t,i=Re("modal-body",n);return g.jsx("div",{id:e,className:i,children:r})},Xue=Wue,que=t=>g.jsx("div",{className:"modal-footer",children:t.children}),Yue=que,Que=t=>{const{onModalClose:e,children:r}=t,{ariaLabelId:n,focusId:i}=e8(),s=T.useRef(null),{t:o}=we();return T.useEffect(()=>{var a;i||(a=s.current)==null||a.focus()},[i]),g.jsxs("div",{className:"modal-header",children:[g.jsx("h2",{id:n,className:"modal-title",tabIndex:-1,children:r}),g.jsx(Ro,{ref:s,"aria-label":o("close"),color:"tertiary",icon:g.jsx(NT,{}),type:"button",variant:"ghost",title:o("close"),onClick:e,className:"btn-close"})]})},Kue=Que,Zue=t=>g.jsx("p",{className:"modal-subtitle",children:t.children}),Jue=Zue,ece=T.forwardRef((t,e)=>{const{id:r,isOpen:n,onModalClose:i,size:s="md",viewport:o=!1,scrollable:a=!1,focusId:l,children:u}=t,c=`aria_label_${r}`,h=`aria_desc_${r}`,f=U6(i),m=qle();Vle(i,["Escape"]),T.useEffect(()=>{if(n&&(document.body.style.overflow="hidden",l)){const _=document.getElementById(l);_==null||_.focus()}return()=>{document.body.style.overflow=""}},[l,n]);const y=Re("modal fade",{"show d-block":n,"modal-scrollable":a,viewport:o,[`modal-${s}`]:s}),v=Re("modal-dialog"),x={ariaLabelId:c,ariaDescriptionId:h,focusId:l},b=hC(n,{from:{x:-50,opacity:0},enter:{x:0,opacity:1},leave:{x:50,opacity:0}});return g.jsx(J6.Provider,{value:x,children:b((_,w)=>g.jsxs(g.Fragment,{children:[w&&g.jsx(Il.div,{id:r,ref:e,role:"dialog","aria-modal":"true","aria-labelledby":c,"aria-describedby":h,className:y,style:_,tabIndex:-1,children:g.jsx("div",{id:`${r}_ref`,ref:E=>{f.current=E,w&&(m.current=E)},className:v,children:g.jsx("div",{className:"modal-content",children:u})})}),w&&g.jsx(Il.div,{className:"modal-backdrop fade show",style:{opacity:.65}})]}))})}),tce=Object.assign(ece,{Header:Kue,Subtitle:Jue,Body:Xue,Footer:Yue}),Ye=tce,rce=({children:t,message:e,icon:r=null,placement:n="auto",...i})=>{const[s,o]=T.useState(null),[a,l]=T.useState(null),[u,c]=T.useState(null),{styles:h,attributes:f}=bq(s,a,{placement:n,modifiers:[{name:"arrow",options:{element:u}}]}),[m,y]=T.useState(!1);return g.jsxs(g.Fragment,{children:[g.jsx("div",{className:"d-inline-block position-relative z-2",ref:o,onMouseEnter:()=>{y(!0)},onMouseLeave:()=>{y(!1)},...i,children:t}),m&&e&&g.jsxs("div",{className:Re("tooltip d-block show mb-12","bs-tooltip-auto"),ref:l,style:h.popper,...f.popper,children:[g.jsxs("div",{className:"tooltip-inner shadow-hover d-flex gap-8 align-items-center",children:[r&&r,g.jsx("div",{children:e})]}),g.jsx("div",{className:"tooltip-arrow",ref:c,style:h.arrow})]})]})},fo=rce,t8=T.createContext(null);function uA(){const t=T.useContext(t8);if(!t)throw new Error("Tabs compound components cannot be rendered outside the Tabs component");return t}const nce=({defaultId:t,items:e,onChange:r})=>{const[n,i]=T.useState(t||""),[s,o]=T.useState(0),[a,l]=T.useState(0),u=T.useRef([]),c=T.useCallback(y=>{i(y)},[]);T.useEffect(()=>{const y=e.find(v=>v.id===n);y&&(r==null||r(y))},[n]),T.useEffect(()=>{function y(){var v;if(((v=document==null?void 0:document.activeElement)==null?void 0:v.tagName)!=="INPUT"){const x=e.findIndex(_=>_.id===n);x===-1&&t&&i(t);const b=u.current[x];b&&(b.focus(),l((b==null?void 0:b.offsetLeft)??0),o((b==null?void 0:b.clientWidth)??0))}}return y(),window.addEventListener("resize",y),()=>window.removeEventListener("resize",y)},[n,e,t]);const h=T.useCallback(y=>{var v,x,b;const _=e.findIndex(w=>w.id===y);y===((v=e[0])==null?void 0:v.id)?i((x=e[e.length-1])==null?void 0:x.id):i((b=e[_-1])==null?void 0:b.id)},[e]),f=T.useCallback(y=>{var v,x,b;const _=e.findIndex(w=>w.id===y);y===((v=e[e.length-1])==null?void 0:v.id)?i((x=e[0])==null?void 0:x.id):i((b=e[_+1])==null?void 0:b.id)},[e]),m=T.useCallback(y=>{var v,x;switch(y.code){case"ArrowLeft":h(n);break;case"ArrowRight":f(n);break;case"Home":i((v=e[0])==null?void 0:v.id);break;case"End":i((x=e[e.length-1])==null?void 0:x.id);break}},[n,e,f,h]);return{activeTab:n,setSelectedTab:c,tabsRef:u,tabUnderlineLeft:a,tabUnderlineWidth:s,onKeyDown:m}},ice=({icon:t,label:e,id:r,order:n})=>{const{activeTab:i,setSelectedTab:s,onKeyDown:o,tabsRef:a}=uA(),{t:l}=we(),u=Re("nav-link d-inline-flex gap-8 border-0",i===r?"selected":"");return g.jsx("li",{className:"nav-item flex-shrink-0",role:"presentation",children:g.jsxs("button",{ref:c=>a.current[n]=c,type:"button",id:`tab-${r}`,className:u,onClick:()=>s(r),onKeyDown:c=>o(c),role:"tab","aria-controls":`tabpanel-${r}`,"aria-selected":i===r,tabIndex:i===r?0:-1,children:[t,g.jsx("small",{children:l(e)})]})})},sce=ice,oce=t=>{const{items:e,tabUnderlineLeft:r,tabUnderlineWidth:n}=uA(),{className:i,...s}=t,o=Re("position-relative flex-shrink-0 overflow-x-auto",i);return g.jsxs("div",{className:o,...s,children:[g.jsx("ul",{className:"nav nav-tabs flex-nowrap",role:"tablist",children:e.map((a,l)=>g.jsx(oa.Item,{order:l,...a},a.id))}),g.jsx("span",{className:"nav-slide",style:{left:r,width:n}})]})},ace=oce,lce=({children:t,currentItem:e})=>{const{activeTab:r}=uA();return g.jsx("div",{className:"tab-content d-flex flex-fill w-100",children:g.jsx("div",{className:`tab-pane flex-fill w-100 fade ${r===(e==null?void 0:e.id)?"show active":""}`,id:`tabpanel-${e==null?void 0:e.id}`,role:"tabpanel","aria-labelledby":`tab-${e==null?void 0:e.id}`,tabIndex:0,children:t})})},uce=lce,oa=({defaultId:t,items:e,onChange:r,children:n})=>{const{activeTab:i,setSelectedTab:s,tabsRef:o,tabUnderlineLeft:a,tabUnderlineWidth:l,onKeyDown:u}=nce({defaultId:t,items:e,onChange:r}),c=T.useMemo(()=>({activeTab:i,items:e,setSelectedTab:s,tabsRef:o,tabUnderlineLeft:a,tabUnderlineWidth:l,onKeyDown:u}),[i,e,u,s,a,l,o]),h=e.find(f=>f.id===i);return g.jsx(t8.Provider,{value:c,children:typeof n=="function"?n(h):g.jsxs(g.Fragment,{children:[g.jsx(oa.List,{}),g.jsx(oa.Panel,{currentItem:h,children:h==null?void 0:h.content})]})})};oa.Item=sce;oa.Panel=uce;oa.List=ace;const cce=T.forwardRef(({children:t,className:e,...r},n)=>{const i=Re("breadcrumb-item",e);return g.jsx("li",{ref:n,className:i,...r,children:t})}),k0=cce,dce=T.forwardRef(({children:t,className:e},r)=>{const n=Re("breadcrumb d-flex flex-nowrap align-items-center mb-0",e);return g.jsx("ol",{ref:r,className:n,children:t})}),hce=dce;function cA(){const t={"last-infos-widget":"ic-widget-actualites",birthday:"ic-star","calendar-widget":"ic-widget-calendar","carnet-de-bord":"ic-widget-carnet-de-bord","record-me":"ic-widget-microphone",mood:"ic-star","my-apps":"ic-widget-apps",notes:"ic-widget-notes","rss-widget":"ic-widget-rss","bookmark-widget":"ic-widget-signets",qwant:"ic-widget-qwant","qwant-junior":"ic-widget-qwant","agenda-widget":"ic-widget-agenda","cursus-widget":"ic-widget-aide-devoirs","maxicours-widget":"ic-widget-maxicours","school-widget":"ic-widget-schoolbook","universalis-widget":"ic-widget-universalis","briefme-widget":"ic-widget-briefme"};function e(a){let l="";switch(typeof a=="string"?l=a:l=(a==null?void 0:a.icon)!==void 0?a==null?void 0:a.icon.trim().toLowerCase():"placeholder",l&&l.length>0?l.endsWith("-large")&&(l=l.replace("-large","")):typeof a=="object"&&(l=(a==null?void 0:a.displayName)!==void 0?a==null?void 0:a.displayName.trim().toLowerCase():""),l){case"admin.title":l="admin";break;case"banques des savoirs":l="banquesavoir";break;case"collaborativewall":l="collaborative-wall";break;case"communautés":l="community";break;case"directory.user":l="userbook";break;case"emploi du temps":l="edt";break;case"formulaire":l="forms";break;case"messagerie":l="conversation";break;case"news":l="actualites";break;case"homeworks":case"cahier de texte":l="cahier-de-texte";break;case"diary":case"cahier de texte 2d":l="cahier-textes";break}return l}function r(a){return a&&(a.startsWith("/")||a.startsWith("http://")||a.startsWith("https://"))}function n(a){const l=e(a);return l?`color-app-${l}`:"color-app-placeholder"}function i(a){const l=e(a);return l?`bg-app-${l}`:"bg-app-placeholder"}function s(a){const l=e(a);return l?`bg-light-${l}`:"bg-light-placeholder"}function o(a){return t[a.platformConf.name]}return{getIconClass:n,getBackgroundIconClass:i,getBackgroundLightIconClass:s,getIconCode:e,getWidgetIconClass:o,isIconUrl:r}}const fce=T.forwardRef(({children:t,app:e,className:r},n)=>{const{t:i}=we(),{getIconClass:s}=cA(),o=Re("d-flex align-items-center mb-0",s(e),r),a={"--edifice-breadcrumb-divider":"-"};return g.jsx("nav",{ref:n,className:o,"aria-label":i("breadcrumb"),style:a,children:t})}),pce=fce,mce=T.forwardRef(({app:t,name:e},r)=>{const{t:n}=we();return g.jsx(pce,{app:t,ref:r,className:"mw-100",children:g.jsx(hce,{className:"gap-12 mw-100",children:e?g.jsxs(g.Fragment,{children:[g.jsx(k0,{children:g.jsx("a",{href:t==null?void 0:t.address,className:"d-flex","aria-label":n(t==null?void 0:t.displayName),children:g.jsx(ya,{app:t,size:"40"})})}),g.jsx(k0,{children:g.jsx(zN,{color:"var(--edifice-gray-600)",width:20,height:20})}),g.jsx(k0,{className:"text-truncate",children:g.jsx(Ss,{level:"h1",headingStyle:"h3",className:"text-truncate",children:e})})]}):g.jsxs(k0,{className:"gap-12 d-flex align-items-center",children:[g.jsx("a",{href:t==null?void 0:t.address,className:"d-flex","aria-label":n(t==null?void 0:t.displayName),children:g.jsx(ya,{app:t,size:"40"})}),g.jsx(Ss,{level:"h1",headingStyle:"h3",className:"d-none d-md-flex",children:n(t==null?void 0:t.displayName)})]})})})}),gce=mce,r8=T.createContext(null),J1=()=>{const t=T.useContext(r8);if(!t)throw new Error("Cannot be rendered outside the FormControl component");return t},vce=({children:t})=>{const{status:e}=J1(),r=Re("form-text",{"is-invalid":e==="invalid",valid:e==="valid"});return g.jsx("p",{className:r,children:g.jsx("em",{children:t})})},yce=vce,xce=T.forwardRef(({noValidationIcon:t,placeholder:e,size:r="md",type:n="text",className:i,...s},o)=>{const{id:a,isRequired:l,isReadOnly:u,status:c}=J1(),h=Re({"form-control":!u,"form-control-lg":r==="lg","form-control-sm":r==="sm","is-invalid":c==="invalid","is-valid":c==="valid","form-control-plaintext":u,"no-validation-icon":t},i);return g.jsx("input",{ref:o,id:a,className:h,type:n,placeholder:e,required:l,readOnly:u,...s})}),Kn=xce,bce=T.forwardRef(({leftIcon:t,optionalText:e,requiredText:r="*",children:n,className:i},s)=>{const{id:o,isOptional:a,isRequired:l}=J1(),{t:u}=we(),c=Re("form-label",{"has-icon":t},i),h=a&&!l,f=l&&!a;return T.useEffect(()=>{if(a&&l)throw new Error("Cannot be optional and required at the same time")},[a,l]),g.jsxs("label",{ref:s,htmlFor:o,className:c,children:[t,n,h&&g.jsxs("em",{className:"optional",children:["- ",e??u("explorer.optional")]}),f&&g.jsx("em",{className:"required",children:r})]})}),Gi=bce,wce=T.forwardRef(({children:t,className:e,id:r,isOptional:n,isReadOnly:i,isRequired:s,status:o,...a},l)=>{const u=T.useMemo(()=>({id:r,isOptional:n,isRequired:s,isReadOnly:i,status:o}),[r,n,i,s,o]);return g.jsx(r8.Provider,{value:u,children:g.jsx("div",{ref:l,className:e,...a,children:t})})}),_ce=Object.assign(wce,{Label:Gi,Input:Kn,Text:yce}),Ot=_ce,Sce=({placeholder:t,value:e="",searchMinLength:r=3,handleSearchInputChange:n})=>{const{triggerProps:i,itemProps:s,setVisible:o}=bh(),a={...i,role:"combobox",onClick:()=>{e.length>=r&&o(!0)},onChange:n};return T.useEffect(()=>{o(e.length>=r)},[o,e,r]),g.jsx(Ot,{className:"d-flex align-items-center",id:"search",children:g.jsx(Kn,{...a,className:"max-w-512",noValidationIcon:!0,placeholder:t,size:"md",type:"search",onKeyDown:s.onMenuItemKeyDown})})},Ece=Sce,dA=({onSearchResultsChange:t,onSearchInputChange:e,options:r,value:n,isLoading:i,noResult:s,searchMinLength:o,placeholder:a})=>{const{t:l}=we(),[u,c]=T.useState([]);T.useEffect(()=>{t(u)},[u]);const h=m=>{c([m])},f=()=>i?g.jsxs("div",{className:"d-flex align-items-center p-4",children:[g.jsx(YT,{isLoading:i}),g.jsx("span",{className:"ps-4",children:l("explorer.search.pending")})]}):s?g.jsx("div",{className:"p-4",children:l("portal.no.result")}):r.map((m,y)=>g.jsxs(T.Fragment,{children:[g.jsx(xt.Item,{type:"select",icon:m.icon,onClick:()=>h(m.value),children:m.label}),y<r.length-1&&g.jsx(xt.Separator,{})]},y));return g.jsxs(xt,{block:!0,children:[g.jsx(dA.Trigger,{placeholder:a,searchMinLength:o,handleSearchInputChange:e,value:n}),g.jsx(xt.Menu,{children:f()})]})};dA.Trigger=Ece;const Tce=dA,n8=T.createContext(null);function hA(){const t=T.useContext(n8);if(!t)throw new Error("Cannot be rendered outside Dropzone Provider");return t}const Cce=()=>{const{t}=we();return g.jsx("div",{className:"drop-wrapper",children:g.jsx("div",{className:"drop-content",children:g.jsx("p",{className:"drop-text",children:t("dropzone.drop")})})})},Ace=Cce,Rce=({children:t,multiple:e})=>{const{t:r}=we(),{files:n,inputRef:i}=hA(),s=n&&n.length>0,o=Re("drop-file-wrapper",{"d-block":s,"d-none":!s});return g.jsxs("div",{className:o,children:[g.jsx("div",{className:"drop-file-content",children:g.jsx("div",{className:"add-button p-4",children:g.jsx(it,{variant:"ghost",leftIcon:g.jsx(d1,{}),disabled:!e,onClick:()=>{var a;return(a=i==null?void 0:i.current)==null?void 0:a.click()},children:r("dropzone.add.more")})})}),g.jsx("div",{className:"p-8",children:t})]})},Pce=Rce,Ice=()=>{const{t}=we(),{files:e,inputRef:r}=hA(),n=e&&e.length>0,i=Re("dropzone-import-wrapper",{"d-flex":!n,"d-none":n});return g.jsxs("div",{className:i,children:[g.jsx(W$,{height:48,width:48}),g.jsx("p",{className:"my-16",children:t("dropzone.text")}),g.jsx(it,{onClick:()=>{var s;return(s=r==null?void 0:r.current)==null?void 0:s.click()},children:t("dropzone.import")})]})},Mce=Ice,Wu=({className:t,accept:e,multiple:r=!0,handle:n=!1,children:i})=>{const{inputRef:s,dragging:o,files:a,addFile:l,deleteFile:u,replaceFileAt:c,handleDragLeave:h,handleDragging:f,handleDrop:m,handleOnChange:y}=Hle(e?{forceFilters:!0}:void 0),v=Re("dropzone",{"is-dragging":(r||a.length<1)&&o,"is-drop-files":!(a.length!==0&&!n)},t),x=T.useMemo(()=>({inputRef:s,files:a,addFile:l,deleteFile:u,replaceFileAt:c}),[l,u,c,a,s]);return g.jsx(n8.Provider,{value:x,children:g.jsxs("div",{className:v,onDragEnter:f,onDragOver:f,onDragLeave:h,onDrop:a.length>0&&!r?void 0:m,children:[g.jsxs("div",{className:"d-flex flex-fill",children:[n?null:g.jsxs(g.Fragment,{children:[g.jsx(Wu.File,{multiple:r,children:i}),g.jsx(Wu.Import,{})]}),g.jsx(Wu.Drag,{})]}),g.jsx("input",{ref:s,accept:e==null?void 0:e.join(","),multiple:r,type:"file",name:"attachment-input",id:"attachment-input",onChange:y,hidden:!0})]})})};Wu.File=Pce;Wu.Import=Mce;Wu.Drag=Ace;const kce=Wu,so=({children:t,className:e,...r})=>{const n=Re("grid",e);return g.jsx("div",{className:n,...r,children:t})},Oce=({sm:t,md:e,lg:r,xl:n,children:i,className:s,as:o,...a})=>{const l=o||"div",u=Re({[`g-col-${t}`]:t,[e?`g-col-md-${e}`:""]:e,[r?`g-col-lg-${r}`:""]:r,[n?`g-col-xl-${n}`:""]:n},s);return g.jsx(l,{className:u,...a,children:i})};so.Col=Oce;const Dce=T.forwardRef(({position:t=!0,caption:e},r)=>{const[n]=Pn(),i=`${n}/loading/screen-loading.gif`,s=Re("top-0 end-0 start-0 bottom-0 d-grid justify-content-center align-content-center align-items-center z-2000",{"position-fixed":!t,"position-static":t}),o=Re("text-center pt-12",{"text-white":!t});return g.jsxs(g.Fragment,{children:[g.jsxs("div",{ref:r,className:s,children:[g.jsx("div",{className:"bg-white rounded-circle mx-auto w-25",children:g.jsx("img",{src:i,alt:"loading"})}),e&&g.jsx("div",{className:o,children:e})]}),!t&&g.jsx("div",{className:"modal-backdrop fade show"})]})}),fr=Dce,Nce=T.forwardRef(({src:t,is1d:e,translate:r="Retour accueil"},n)=>{const i=Re("navbar-brand d-none d-md-block");return g.jsx("a",{ref:n,className:i,href:"/timeline/timeline","aria-label":r,children:g.jsx("img",{className:"logo",src:t,alt:`logo ${e?"ONE":"NEO"}`,width:"300",height:"52"})})}),Ck=Nce,Lce=({children:t,className:e})=>{const r=Re("popover-body",e);return g.jsx("div",{className:r,children:t})},Fce=({children:t,className:e})=>{const r=Re("popover-footer p-8",e);return g.jsx("div",{className:r,children:t})},i8=T.forwardRef(({children:t,className:e,id:r,isVisible:n,...i},s)=>{const o=Re("popover d-block position-absolute top-100 start-50 translate-middle-x",e);return hC(n,{from:{opacity:0},enter:{opacity:1},leave:{opacity:0},config:{duration:0}})((a,l)=>l&&g.jsx(Il.div,{ref:s,"aria-labelledby":r,className:o,role:"tooltip",style:a,...i,children:t}))}),jce=({isVariant:t=!1,size:e="md",placeholder:r="search",className:n,disabled:i,onChange:s,onClick:o,...a})=>{const{t:l}=we(),u=Re(n,{"input-group":!t,"position-relative":t}),c=Re({"border-end-0":!t,"ps-48":t}),h=()=>{o==null||o()};return g.jsxs(Ot,{id:"search-bar",className:u,children:[t&&g.jsx("div",{className:"position-absolute z-1 top-50 start-0 translate-middle-y border-0 ps-12 bg-transparent",children:g.jsx(AS,{})}),g.jsx(Ot.Input,{type:"search",placeholder:l(r),size:e,noValidationIcon:!0,className:c,onChange:s,disabled:i,...a}),!t&&g.jsx(oA,{type:"submit","aria-label":l("search"),icon:g.jsx(AS,{}),className:"border-start-0",onClick:h})]})},s8=jce,Bce=T.forwardRef(({noValidationIcon:t,placeholder:e,size:r="md",height:n="md",className:i,...s},o)=>{const{id:a,isRequired:l,isReadOnly:u,status:c}=J1(),h=Re({"form-control":!u,"form-control-lg":r==="lg","form-control-sm":r==="sm","textarea-height-lg":n==="lg","textarea-height-md":n==="md","textarea-height-sm":n==="sm","is-invalid":c==="invalid","is-valid":c==="valid","form-control-plaintext":u,"no-validation-icon":t},i);return g.jsx(g.Fragment,{children:g.jsx("textarea",{ref:o,id:a,className:h,placeholder:e,required:l,readOnly:u,...s})})}),fA=Bce,pA=T.forwardRef(({items:t,variant:e="default",align:r="space",isBlock:n=!1,ariaControls:i,className:s},o)=>{const[a,l]=T.useState(0),[u,c]=T.useState([]),[h,f]=T.useState(),[m,y]=T.useState(),v=T.useRef(),x=Re("toolbar z-1000 bg-white",s,{default:e==="default","no-shadow":e==="no-shadow","d-flex":n,"d-inline-flex":!n,"overflow-x-auto":n,"justify-content-start":r==="left","justify-content-between":r==="space","justify-content-center":r==="center","justify-content-end":r==="right"});T.useEffect(()=>{var P;const I=(P=v.current)==null?void 0:P.querySelectorAll("button"),M=[];let N=!1;I==null||I.forEach(z=>{z.disabled||(N||(f(z),N=!0),y(z),M.push(z))}),c(M),l(t.findIndex(z=>(z.type==="button"||z.type==="icon")&&!z.props.disabled))},[t]);const b=P=>{P.target.classList.add("focus")},_=P=>{P.target.classList.remove("focus")},w=P=>{var I,M;const N=u.indexOf(P.currentTarget);switch(P.code){case"ArrowLeft":P.currentTarget===h?m==null||m.focus():(I=u[N-1])==null||I.focus();break;case"ArrowRight":P.currentTarget===m?h==null||h.focus():(M=u[N+1])==null||M.focus();break}},E=P=>{var I;return typeof P.tooltip=="string"?P.tooltip:(I=P.tooltip)==null?void 0:I.message},A=P=>{var I;return typeof P.tooltip!="string"?(I=P.tooltip)==null?void 0:I.position:"top"};return g.jsx("div",{ref:T2(o,v),className:x,role:"toolbar","aria-label":"Text Formatting","aria-controls":i,onFocus:b,onBlur:_,children:t.map((P,I)=>{if(P.visibility==="hide")return null;switch(P.type){case"divider":return g.jsx("div",{className:"toolbar-divider"},P.name??I);case"button":return g.jsx(fo,{message:E(P),placement:A(P),children:T.createElement(it,{...P.props,key:P.name??I,color:P.props.color?P.props.color:"tertiary",variant:"ghost",tabIndex:I===a?0:-1,onKeyDown:w})},P.name??I);case"icon":return g.jsx(fo,{message:E(P),placement:A(P),children:T.createElement(Ro,{...P.props,key:P.name??I,color:P.props.color?P.props.color:"tertiary",variant:P.props.variant?P.props.variant:"ghost",tabIndex:I===a?0:-1,onKeyDown:w})},P.name??I);case"dropdown":return T.createElement(xt,{...P.props,key:P.name??I,extraTriggerKeyDownHandler:w,overflow:P.overflow});case"primary":return g.jsx(fo,{message:E(P),placement:A(P),children:g.jsx(it,{...P.props,variant:"filled",color:"primary",tabIndex:I===a?0:-1,onKeyDown:w})},P.name??I)}return null})})}),A2=({node:t,showIcon:e,selectedNodeId:r,expandedNodes:n,siblingsNodes:i,draggedNodeId:s,handleItemClick:o,handleToggleNode:a,handleItemAction:l})=>{const u=n.has(t.id),c=i==null?void 0:i.current.has(t.id),h=r===t.id,f=s===t.id,m={action:Re("action-container d-flex align-items-center gap-8 px-2",{"drag-focus":f,"py-4":!t.section}),arrow:Re({"py-4":!t.section,"py-8":t.section,invisible:!Array.isArray(t.children)||t.children.length===0}),button:Re("flex-fill d-flex align-items-center text-truncate gap-8",{"py-8":t.section})},y=t.section?16:12,{t:v}=we(),{setNodeRef:x}=Gj({id:T.useId(),data:{id:t.id,name:t.name,isTreeview:!0,accepts:["folder","resource"]}}),b=M=>o==null?void 0:o(M),_=M=>a==null?void 0:a(M),w=M=>l==null?void 0:l(M),E=M=>{(M.code==="Enter"||M.code==="Space")&&(M.preventDefault(),M.stopPropagation(),o==null||o(t.id))},A=M=>{(M.code==="Enter"||M.code==="Space")&&(M.preventDefault(),M.stopPropagation(),a==null||a(t.id))},P=M=>g.jsx(M?Tp:zN,{title:v("foldUnfold"),width:y,height:y}),I=()=>{var M;const N=!((M=i==null?void 0:i.current)!=null&&M.has(t.id)),z=Array.isArray(t.children)&&t.children.length>0;return c||N&&z};return g.jsx("li",{ref:x,id:`treeitem-${t.id}`,role:"treeitem","aria-selected":h&&h,"aria-expanded":u&&u,children:g.jsxs("div",{children:[g.jsxs("div",{className:m.action,children:[g.jsx("div",{className:m.arrow,tabIndex:0,role:"button",onClick:()=>_(t.id),onKeyDown:A,"aria-label":v("foldUnfold"),children:I()&&P(u)}),g.jsxs("div",{tabIndex:0,role:"button",className:m.button,onClick:()=>b(t.id),onKeyDown:E,children:[t.section&&e&&g.jsx(jN,{title:v("folder"),width:20,height:20}),g.jsx("span",{className:"text-truncate",children:t.name})]}),t.section&&l&&g.jsx("button",{className:"tree-btn mx-8",onClick:()=>w(t.id),children:g.jsx(d1,{height:16,width:16})})]}),Array.isArray(t.children)&&!!t.children.length&&u&&g.jsx("ul",{role:"group",children:t.children.map(M=>g.jsx(A2,{node:M,selectedNodeId:r,expandedNodes:n,siblingsNodes:i,draggedNodeId:s,handleItemClick:o,handleToggleNode:a},M.id))})]})},t.id)},Uce=({data:t,ref:e,externalSelectedNodeId:r,draggedNode:n,allExpandedNodes:i,onTreeItemUnfold:s,onTreeItemFold:o,onTreeItemClick:a})=>{const[l,u]=T.useState(void 0),[c,h]=T.useState(new Set),f=T.useRef(new Set),[m,y]=T.useState(void 0),v=l??r;function x(j){var H;Array.isArray(j)?j.forEach(F=>{const L=new Set(f.current);j.filter(({id:O})=>O!==F.id).some(O=>O.children&&O.children.length>0)&&L.add(F.id),F.children&&F.children.length>0&&F.children.forEach(O=>{var $;const V=($=F.children)==null?void 0:$.filter(({id:k})=>k!==O.id);V!=null&&V.some(k=>k.children&&k.children.length>0)&&L.add(O.id),x(O)})}):(H=j.children)==null||H.forEach(F=>{var L;const O=new Set(f.current),$=(L=j.children)==null?void 0:L.filter(V=>V.id!==F.id);$!=null&&$.some(V=>V.children&&V.children.length>0)&&(O.add(F.id),f.current=O),x(F)})}const b=j=>{const H=new Set("");t&&Array.isArray(t)&&j&&(t.forEach(F=>{H.add(F.id)}),h(H))};T.useEffect(()=>{t&&x(t)},[t]),T.useEffect(()=>{n!=null&&n.isOver&&n.isTreeview?(n.overId&&z(n.overId),y(n.overId)):y(void 0)},[n]);const _=T.useMemo(()=>({unselectAll(){u(void 0)},select(j){M(j)},allExpandedNodes(){b(i)}}),[]);T.useImperativeHandle(e,()=>_,[_]),T.useEffect(()=>{b(i)},[]),T.useEffect(()=>{r&&!i?(w(r),u(r)):u(void 0)},[r]);const w=j=>{if(!Ki(t,v)){u(void 0);return}if(r==="default"){c.forEach(H=>s==null?void 0:s(H));return}E(j)},E=j=>{const H=new Set(c),F=zue(t,j),L=Array.from(H);F.forEach(O=>{const $=L.indexOf(O);$>-1&&L.splice($,1),L.push(O)}),H.clear(),L.forEach(O=>H.add(O)),H.forEach(O=>s==null?void 0:s(O)),h(H)},A=j=>{const H=new Set(c);H.delete(j),H.forEach(F=>o==null?void 0:o(F)),h(H)},P=j=>{c.has(j)?A(j):E(j)},I=j=>{v!==j&&u(j)},M=j=>{I(j),E(j),a==null||a(j)},N=j=>{P(j)},z=j=>{Ki(t,r)&&E(j)};return{selectedNodeId:v,expandedNodes:c,siblingsNodes:f,draggedNodeId:m,handleItemClick:M,handleFoldUnfold:N}},$ce=T.forwardRef((t,e)=>{const{data:r,onTreeItemClick:n,onTreeItemUnfold:i,onTreeItemFold:s,onTreeItemAction:o,draggedNode:a,showIcon:l=!0,allExpandedNodes:u=!1,selectedNodeId:c}=t,{selectedNodeId:h,expandedNodes:f,siblingsNodes:m,draggedNodeId:y,handleItemClick:v,handleFoldUnfold:x}=Uce({data:r,ref:e,externalSelectedNodeId:c,draggedNode:a,allExpandedNodes:u,onTreeItemClick:n,onTreeItemFold:s,onTreeItemUnfold:i});return g.jsx("div",{className:"treeview",children:g.jsx("ul",{role:"tree",className:"m-0 p-0",children:Array.isArray(r)?r.map(b=>g.jsx(A2,{node:b,showIcon:l,selectedNodeId:h,expandedNodes:f,siblingsNodes:m,draggedNodeId:y,handleItemClick:v,handleToggleNode:x,handleItemAction:o},b.id)):g.jsx(A2,{node:r,selectedNodeId:h,expandedNodes:f,siblingsNodes:m,showIcon:l,draggedNodeId:y,handleItemClick:v,handleToggleNode:x})})})}),dd=$ce,zce=T.forwardRef(({children:t},e)=>g.jsx("span",{className:"visually-hidden",ref:e,children:t})),ml=zce;function Hce(){var t;const{sessionQuery:e}=yt(),r=new Set;return(t=e==null?void 0:e.data)==null?void 0:t.bookmarkedApps.filter(n=>{const i=r.has(n.displayName);return r.add(n.displayName),!i})}function Wi(t){const e=Q6(),[r,n]=T.useState();return T.useEffect(()=>{(async()=>{let i;if(e!=null&&e.hasWorkflow)if(typeof t=="string")i=await e.hasWorkflow(t);else throw"not.implemented.yet)";else typeof t=="string"?i=await Me.rights().sessionHasWorkflowRight(t):i=await Me.rights().sessionHasWorkflowRights(t);n(i)})()},[t,e]),r}const Vce=()=>{const t=Wi("fr.openent.zimbra.controllers.ZimbraController|view"),e=Wi("fr.openent.zimbra.controllers.ZimbraController|preauth"),[r,n]=T.useState(0),[i,s]=T.useState(""),o={unread:!0,_:new Date().getTime()},a=async()=>{const u=t?"/zimbra/count/INBOX":"/conversation/count/INBOX";try{const{count:c}=await Me.http().get(u,{queryParams:o});n(c??0)}catch(c){console.error(c),n(0)}},l=async()=>{const u="/zimbra/zimbra";try{const{preference:c}=await Me.http().get("/userbook/preference/zimbra"),h=c?JSON.parse(c).modeExpert:!1;s(h&&e?"/zimbra/preauth":window.location.origin+u)}catch(c){console.error(c),s(window.location.origin+u)}};return T.useEffect(()=>{a()},[]),T.useEffect(()=>{l()},[]),{messages:r,msgLink:i,zimbraWorkflow:t}},Gce=Vce;function Wce({user:t,avatar:e}){const{appCode:r}=yt(),{t:n}=we(),{theme:i}=ba(),s=n(r),[o,a]=T.useState(!0),[l,u]=$6(),c=T.useId(),h=T.useId(),f=e,m=t==null?void 0:t.username,y=n("welcome",{username:t==null?void 0:t.firstName}),v=Hce(),x=Wi("net.atos.entng.community.controllers.CommunityController|view"),b=Wi("org.entcore.conversation.controllers.ConversationController|view"),_=Wi("fr.openent.searchengine.controllers.SearchEngineController|view"),w=T.useCallback(()=>{a(!o)},[o]),E=async()=>{await Me.session().logout(),window.location.href=(i==null?void 0:i.logoutCallback)??"/auth/login"};return T.useMemo(()=>({title:s,bookmarkedApps:v,appsRef:l,isAppsHovered:u,popoverAppsId:c,popoverSearchId:h,userAvatar:f,userName:m,welcomeUser:y,communityWorkflow:x,conversationWorflow:b,searchWorkflow:_,isCollapsed:o,toggleCollapsedNav:w,handleLogout:E}),[l,v,x,b,u,o,c,h,_,s,w,f,m,y])}const Xce=t=>{const e=T.useRef(),r=en(),{t:n}=we();return T.useEffect(()=>{const i=Me.notify().events().subscribe(NB.TRANSPORT,s=>{var o,a;e.current=n(((a=(o=s==null?void 0:s.data)==null?void 0:o.payload)==null?void 0:a.error)||s.data.response.statusText),r.error(Ie.createElement("div",{children:[e.current]}),t)});return()=>i.revoke()},[n,r]),e.current},qce=Xce;function o8(){const[t,e]=T.useState(!1);T.useEffect(()=>{r()},[]);const r=T.useCallback(async()=>{const n=await Me.session().isAdml();e(n)},[]);return{isAdml:t}}const Yce=()=>{var t;const{user:e,appCode:r}=yt(),n=Z6[r],i=e==null?void 0:e.apps.find(u=>u.isExternal&&u.address.includes("library"));if(!i)return null;const s=(t=i.address)==null?void 0:t.split("?");if(!s||s.length<2)return null;let o=s[0];o.endsWith("/")||(o=`${o}/`);const a=s==null?void 0:s[1],l=`application%5B0%5D=${n}&page=1&sort_field=views&sort_order=desc`;return`${o}search/?${a}&${l}`},Qce=Yce,Kce=()=>({createOrUpdate:async({alt:t,uri:e,blob:r,legend:n,parentId:i,application:s,visibility:o})=>{const a=/\/workspace\/document\/([0-9a-fA-F-]+)/,l=(e??"").match(a);if(l&&l.length===2){const u=l[1],c=await Me.workspace().searchDocuments({filter:"all",id:u,limit:1}),h=c.length?c[0].name:void 0;await Me.workspace().updateFile(u,r,{alt:t,legend:n,name:h});const f=(await Me.workspace().searchDocuments({filter:"all",id:u,limit:1}))[0];return{file:f,src:`/workspace/${f.public?"pub/":""}document/${u}`}}else{const u=await Me.workspace().saveFile(r,{application:s,parentId:i,visibility:o});return`/workspace/${u.public?"pub/":""}document/${u._id}`}},create:async(t,e)=>await Me.workspace().saveFile(t,e),remove:async t=>!t||Array.isArray(t)&&t.length===0?Promise.resolve():await Me.workspace().deleteFile(Array.isArray(t)?t:[t])}),ex=Kce,Zce=()=>{const t=T.useRef(null),[e,r]=T.useState(),{remove:n}=ex();return{ref:t,libraryMedia:e,setLibraryMedia:r,onCancel:async i=>{var s,o;(s=t.current)!=null&&s.type&&i&&i.length>0&&await n(i),(o=t.current)==null||o.hide()},onSuccess:i=>{var s,o,a,l;let u;switch((s=t.current)==null?void 0:s.type){case"video":{if(typeof i=="object")u=i[0];else{const c=new DOMParser().parseFromString(i,"text/html").body.firstChild,h=c==null?void 0:c.getAttribute("src");(o=t.current)==null||o.hide(),u=h}break}case"embedder":{const c=new DOMParser().parseFromString(i,"text/html").body.firstChild,h=c==null?void 0:c.getAttribute("src");(a=t.current)==null||a.hide(),u=h;break}case"audio":{i.length===void 0?u=i:u=i[0];break}case"hyperlink":{u=i;break}case"image":{u=`/workspace/document/${i[0]._id}`;break}default:u=i[0]}(l=t.current)==null||l.hide(),r(u)},onTabChange:async(i,s)=>{var o;(o=t.current)!=null&&o.type&&s&&s.length>0&&await n(s)}}},a8=Zce,Jce=t=>{const[e,r]=T.useState([]);T.useEffect(()=>{(async()=>(await Eb.initialize(Me,t),await Eb.registerBehaviours(t),r(Eb.resourceProducingApps)))()},[]);const n=T.useCallback(async i=>{const[s]=i.types;return await Me.behaviour(t,s).loadResources(i)},[t]);return{resourceApplications:e,loadResources:n}},ede=(t,e="media-library")=>{const[r,n]=T.useState({}),{browser:i,device:s}=B6(navigator.userAgent),{create:o}=ex(),a=T.useCallback(y=>r[pf(y)],[r]),l=(y,v)=>{n(x=>{const b=pf(y);return{...x,[b]:v}})},u=y=>{n(v=>{const x=pf(y),{[x]:b,..._}=v;return _})};async function c(y,v){l(y,"loading");try{let x;return e==="media-library"&&y.type.includes("video")?x=await f(y,{filename:y.name,...v}):x=await o(y,{application:e,visibility:t}),l(y,"success"),x}catch{return l(y,"error"),null}}async function h(y,v){l(y,"loading");try{let x;if(y.type.includes("video"))x=await f(y,v);else throw new Error(Gk.NOT_SUPPORTED);return l(y,"success"),x}catch{return l(y,"error"),null}}const f=async(y,v)=>{const x={data:{device:s.type,browser:{name:i.name,version:i.version},url:window.location.hostname,file:y,filename:(v==null?void 0:v.filename)??"filename",weight:y.size},appCode:e,captation:!(y instanceof File),duration:(v==null?void 0:v.duration)??0},b=await Me.video().upload(x);if(b.state==="succeed")return{_id:b.videoworkspaceid,file:b.videoid,name:x.data.filename,eType:"file",eParent:"",children:[],created:new Date,_shared:[],_isShared:!1,owner:{userId:"",displayName:""}};throw b.state==="error"?new Error(b.code||"Error while uploading video"):new Error("Video encoding is still running")};function m(y,v,x){return pf(v,pf(y)),c(v,x)}return{getUploadStatus:a,setUploadStatus:l,clearUploadStatus:u,uploadFile:c,uploadAlternateFile:m,uploadBlob:h}},l8=ede,tde=({handleOnChange:t,visibility:e,application:r})=>{const[n,i]=T.useState([]),[s,o]=T.useState(void 0),{files:a,deleteFile:l,replaceFileAt:u}=hA(),{remove:c,createOrUpdate:h}=ex(),{getUploadStatus:f,setUploadStatus:m,clearUploadStatus:y,uploadFile:v,uploadAlternateFile:x}=l8(e,r),b=T.useCallback(P=>{P.forEach(async(I,M)=>{if(I==null)return;let N;if(I.type.startsWith("image"))try{const z=await $q.resizeImageFile(I);N=await x(I,z),u(M,z)}catch(z){console.error(z)}N||(N=await v(I)),N&&i(z=>[...z,N])})},[x,v,u]);T.useEffect(()=>{let P=0;const I=a.map(M=>{if(P>=5)return null;const N=f(M);return N==="loading"&&P++,N?null:M});I.forEach(M=>M&&m(M,"idle")),b(I)},[a,n,f,m,b]),T.useEffect(()=>{const P=_(a,n);t(P)},[n]);const _=(P,I)=>{const M=P.reduce((N,z,j)=>(N[z.name]=j,N),{});return I.sort((N,z)=>M[N.name]-M[z.name])};async function w(P){const I=n.find(M=>M.name===P.name);I&&(await c(I),y(P),i(M=>M.filter(N=>N.name!==(I==null?void 0:I.name)))),l(P)}async function E({blob:P,legend:I,altText:M}){if(s)try{const N=await h({blob:P,legend:I,alt:M,uri:A(s)});N&&typeof N=="object"&&i(z=>z.map(j=>j._id===N.file._id?{...N.file}:j))}finally{o(void 0)}}const A=(P,I)=>{const M=`/workspace/${P!=null&&P.public?"pub/":""}document/${P==null?void 0:P._id}`;return P?I?Vue(M):M:""};return{files:a,getUploadStatus:f,clearUploadStatus:y,uploadedFiles:n,editingImage:s,setEditingImage:o,getUrl:A,updateImage:E,uploadFile:v,removeFile:w}},rde=tde;function wh(){const{user:t,userDescription:e}=yt(),{theme:r}=ba();function n(){let i=e==null?void 0:e.picture;return(!i||i==="no-avatar.jpg"||i==="no-avatar.svg")&&(i=`${r==null?void 0:r.basePath}/img/illustrations/no-avatar.svg`),i}return{user:t,avatar:n(),userDescription:e}}function O0(t,e,r,n){const i=Q6(),s=Wi("org.entcore.workspace.controllers.WorkspaceController|listDocuments"),o=Wi("org.entcore.workspace.controllers.WorkspaceController|listFolders");function a(h,f){switch(f.type){case"update":{const m=Ki(h,f.folderId);return m&&(m.children=f.subfolders.map(y=>({id:y._id||"",name:y.name})),m.files=f.files),{...h}}default:throw Error("[useWorkspaceSearch] Unknown action type: "+f.type)}}const[l,u]=T.useReducer(a,{id:t,name:e,section:!0}),c=T.useCallback(async h=>{var f;if(s&&o){const m=h===t?"":h,y=i!=null&&i.listWorkspaceDocuments?await((f=i==null?void 0:i.listWorkspaceDocuments)==null?void 0:f.call(i).then(b=>b.map(_=>{const w={..._,_id:""+Math.round(Math.random()*9999)};return w.name=_.eType=="folder"?"folder id="+w._id:"file id="+w._id,w}))):await Me.workspace().listDocuments(r,m),v=[],x=[];y.filter(b=>{if(!n||b.eType==="folder")return!0;const _=Vk.getRole(b);return typeof n=="string"?n===_:Array.isArray(n)?n.findIndex(w=>w===_)>=0:!1}).forEach(b=>{b.eType==="folder"?v.push(b):x.push(b)}),u({folderId:h,subfolders:v,files:x,type:"update"})}},[s,o,t,i,r,n]);return{root:l,loadContent:c}}function nde(){const[t,e]=T.useState("pending"),{currentApp:r}=yt();T.useEffect(()=>{n()},[]);const n=async()=>{if(!r){e("[Xiti] Error, currentApp is not defined.");return}try{await Me.analytics().trackPageLoad(window.location.pathname,r),console.info(`[Xiti] Success tracking page ${window.location.pathname}`),e(`[Xiti] Success tracking page ${window.location.pathname}`)}catch(i){console.error("[Xiti] Error Tracking Page Load",i),e(`[Xiti] Error Tracking Page Load: ${i}`)}};return{xitiStatus:t}}function ide(){const{currentLanguage:t}=yt(),{userDescription:e}=wh(),{isAdml:r}=o8(),{theme:n}=ba(),i=window.innerWidth<=768,s=Wi("net.atos.entng.support.controllers.DisplayController|view"),[o,a]=T.useState(""),[l,u]=T.useState(void 0),c=()=>{const h=o.split("/");let f="",m="";if(l!=null&&l.labels&&Object.keys(l==null?void 0:l.labels).length>0&&h.length>1){for(let y=1;y<h.length;y++)h[y].length>0&&h[y].match(/\d/)==null&&(f.length===0?f=h[y]:f=f+"/"+h[y]);l!=null&&l.labels&&Object.prototype.hasOwnProperty.call(l==null?void 0:l.labels,f)?m=l==null?void 0:l.labels[f]:l!=null&&l.default&&String(l.default).length>0&&(m=l==null?void 0:l.default)}else l!=null&&l.default&&String(l==null?void 0:l.default).length>0&&(m=l==null?void 0:l.default);if(h.includes("collaborativewall")&&h.includes("id")&&i&&window.zE("webWidget","hide"),m.includes("${adml}")&&(r?m=m.replace("${adml}","adml"):m=m.replace("/${adml}","")),m.includes("${profile}")){const y=e==null?void 0:e.profiles;m=m.replace("${profile}",y[0].toLowerCase())}m.includes("${theme")&&(n!=null&&n.is1d?m=m.replace("${theme}","1D"):m=m.replace("${theme}","2D")),window.zE("webWidget","helpCenter:setSuggestions",{labels:[m]})};return T.useEffect(()=>{window.location.pathname!==o&&a(window.location.pathname),!(l===void 0||Object.keys(l).length===0)&&c()},[window.location.pathname,l]),T.useEffect(()=>{document.getElementById("ze-snippet")||s===void 0||(async()=>{const h=await Me.http().get("/zendeskGuide/config");if(h&&h.key&&h.key!==""){const f=document.createElement("script");f.id="ze-snippet",f.src=`https://static.zdassets.com/ekr/snippet.js?key=${h.key}`,document.body.appendChild(f).onload=()=>{t==="es"?window.zE(function(){window.zE.setLocale("es-419")}):window.zE(function(){window.zE.setLocale("fr")}),Object.keys(h.module).length>0&&u(h.module),window.zE("webWidget","show"),window.zE("webWidget","updateSettings",{webWidget:{color:{theme:h.color||"#ffc400"},zIndex:3,launcher:{mobile:{labelVisible:!0}},contactForm:{suppress:!s},helpCenter:{messageButton:{"*":"Assistance ENT","es-419":"Asistencia ENT"}}}}),window.addEventListener("scroll",()=>{window.zE("webWidget","updateSettings",{webWidget:{launcher:{mobile:{labelVisible:window.scrollY<=5}}}})}),window.zE("webWidget:on","open",function(){s&&window.zE("webWidget","updateSettings",{webWidget:{contactForm:{suppress:!1}}})}),window.zE("webWidget:on","userEvent",function(m){const y=m.category,v=m.action,x=m.properties;v==="Contact Form Shown"&&y==="Zendesk Web Widget"&&x&&x.name==="contact-form"&&s&&(window.zE("webWidget","updateSettings",{webWidget:{contactForm:{suppress:!0}}}),window.zE("webWidget","close"),window.open("/support","_blank"))})}}})()},[s]),null}function sde(){const t=Wi("org.entcore.portal.controllers.PortalController|optionalFeatureCantoo");return T.useEffect(()=>{t&&!document.getElementById("cantoo-edifice-script")&&(async()=>{const e=await Me.http().get("/optionalFeature/cantoo");if(e&&e.scriptPath){const r=document.createElement("script");r.id="cantoo-edifice-script",r.src=e.scriptPath,r.async=!0,document.body.appendChild(r)}})()},[t]),null}function y_({formData:t,errorMessage:e}){const{t:r}=we(),n=i=>i==null?void 0:i.match(/^\s/);return e==="CONTENT_TOO_LARGE"?g.jsxs(g.Fragment,{children:[g.jsx("h3",{className:"pt-24",children:r("bpr.form.publication.response.error.title")}),g.jsx("p",{className:"pt-24 pb-24",children:g.jsx("strong",{children:r("bpr.form.publication.response.error.content_too_large")})})]}):g.jsxs(g.Fragment,{children:[g.jsx("h3",{className:"pt-24",children:r("bpr.form.publication.response.error.title")}),g.jsx("p",{className:"pt-24 pb-24",children:g.jsx("strong",{children:r("bpr.form.publication.response.error.content")})}),g.jsxs("ul",{children:[n(t==null?void 0:t.title)&&g.jsx("li",{className:"pt-2 pb-2",children:g.jsx("strong",{children:r("bpr.form.publication.response.empty.title")})}),n(t==null?void 0:t.description)&&g.jsx("li",{className:"pt-2 pb-2",children:g.jsx("strong",{children:r("bpr.form.publication.response.empty.description")})})]})]})}function ode({result:t}){const{t:e}=we();return g.jsxs(g.Fragment,{children:[g.jsx("h3",{className:"pt-24",children:e("bpr.form.publication.response.success.title")}),g.jsx("p",{className:"pt-24",children:e("bpr.form.publication.response.success.content.1")}),g.jsx("p",{className:"pt-24",children:e("bpr.form.publication.response.success.content.2")}),t.details.front_url&&g.jsx("p",{className:"pt-24 pb-24",children:g.jsx("a",{className:"button right-magnet",href:t.details.front_url,target:"_blank",rel:"noreferrer",children:e("bpr.form.publication.response.success.button")})})]})}function ade({onSuccess:t,resource:e}){const{user:r,appCode:n}=yt(),i=en(),[s,o]=T.useState((e==null?void 0:e.thumbnail)||"");T.useEffect(()=>{o(e==null?void 0:e.thumbnail)},[e]);const{control:a,register:l,watch:u,setValue:c,handleSubmit:h,formState:{errors:f,isSubmitting:m,isDirty:y,isValid:v}}=OT({mode:"onChange"}),[x,b]=T.useState([]),[_,w]=T.useState([]),E=(A,P,I)=>{let M=[...P];const N=M.findIndex(z=>z===A);P.includes(A)?M=P.filter((z,j)=>j!==N):M=[...P,A],I(M)};return{control:a,cover:s,formState:{errors:f,isSubmitting:m,isDirty:y,isValid:v},handleDeleteImage:()=>o(""),handlePublish:async A=>{const P=r?r==null?void 0:r.userId:"";try{let I=new Blob;typeof s=="string"?I=await Me.http().get(s,{responseType:"blob"}):s?I=await Me.http().get(URL.createObjectURL(s),{responseType:"blob"}):e!=null&&e.thumbnail&&(I=await Me.http().get(e==null?void 0:e.thumbnail,{responseType:"blob"}));const M=await Me.http().get(`/userbook/avatar/${P}?thumbnail=48x48`,{responseType:"blob"}),N=await Me.http().get(`/directory/user/${P}/attachment-school`,{responseType:"json"}),z=Z6[n],j={activityType:x,age:[A.ageMin,A.ageMax],application:z,cover:I,description:A.description,keyWords:A.keyWords,language:A.language,licence:"CC-BY",resourceId:e==null?void 0:e.assetId,resourceEntId:e==null?void 0:e.assetId,subjectArea:_,teacherAvatar:M,title:A.title,userId:P,userStructureName:N.name||(r==null?void 0:r.structureNames[0])},H=await Me.resource(n).publish(j);H.success?i.success(g.jsx(ode,{result:H}),{duration:1e4}):H.message==="CONTENT_TOO_LARGE"?i.error(g.jsx(y_,{errorMessage:H.message})):i.error(g.jsx(y_,{formData:A})),t==null||t()}catch(I){console.error(I),i.error(g.jsx(y_,{formData:A}))}},handleSubmit:h,handleUploadImage:A=>o(A),register:l,selectActivities:A=>{E(A,x,b)},selectedActivities:x,selectedSubjectAreas:_,selectSubjects:A=>{E(A,_,w)},setValue:c,watch:u}}const lde=(t,e)=>{const[r,n]=T.useState(null);return T.useEffect(()=>{if(e===""){console.warn("resourceId must be an assetId and not an empty string");return}(async()=>{try{const i=await Me.resource(t).searchResource({application:t,id:e});n(i)}catch(i){console.error(i)}})()},[]),r},mA=lde,ude=({addButtonLabel:t="Add image",deleteButtonLabel:e="Delete image",src:r,className:n,mediaLibraryRef:i,libraryMedia:s,app:o,onUploadImage:a,onDeleteImage:l})=>{const[u,c]=T.useState(r||"");T.useEffect(()=>{s&&(c(s),a(s))},[s]);const h=()=>{var y;(y=i.current)==null||y.show("image")},f=()=>{c(""),l()},m=Re("image-input",n);return g.jsxs("div",{id:"image-input",className:m,children:[g.jsxs("div",{className:"image-input-actions gap-8",children:[g.jsx(Ro,{"aria-label":t,color:"tertiary",icon:g.jsx(q$,{}),onClick:h,type:"button",variant:"ghost"}),g.jsx(Ro,{"aria-label":e,color:"danger",disabled:!u,icon:g.jsx(LN,{width:"20",height:"20"}),onClick:f,type:"button",variant:"ghost"})]}),u?g.jsx(rc,{alt:"",src:u,size:"xl"}):g.jsx(ya,{app:o,iconFit:"ratio",size:"160",variant:"rounded"})]})},u8=ude,cde=({recordState:t,playState:e,recordTime:r,audioTime:n,maxDuration:i})=>g.jsxs("div",{className:"audio-recorder-time my-16 mx-auto",children:[e==="IDLE"&&g.jsxs("div",{className:"d-flex align-items-center",children:[t==="PAUSED"?g.jsx(FT,{width:12,height:12,className:"me-8 text-danger"}):g.jsx(Zv,{width:12,height:12,className:"me-8 text-danger"}),pl(t!=="IDLE"?r:0)+" / "+pl(i)]}),e!=="IDLE"&&g.jsxs("div",{className:"d-flex align-items-center mx-auto",children:[g.jsx(c1,{width:12,height:12,className:"me-8"}),pl(n*1e3)," /",pl(r)]})]}),dde=cde;function hde(t,e,r=!1,n="protected",i="media-library"){var s;function o(q,re){return{...q,...re.updatedState}}const[{recordState:a,playState:l,micStream:u,micStreamAudioSourceNode:c,audioWorkletNode:h,audioContext:f,encoderWorker:m,maxDuration:y,recordTime:v,isEncoding:x},b]=T.useReducer(o,{recordState:"IDLE",isEncoding:!1,playState:"IDLE",recordTime:0,maxDuration:180}),_=T.useRef(null),w=T.useRef(null),E=T.useRef(),A=T.useRef(),{t:P}=we(),{create:I}=ex(),M=128,N=48e3;T.useEffect(()=>{const q=new Worker("/infra/public/js/audioEncoder.js");return b({type:"update",updatedState:{encoderWorker:q}}),q.postMessage(["init",(f==null?void 0:f.sampleRate)||N]),()=>{j(),q.terminate()}},[]);const z=q=>{var re,ue;const le=q.data.inputs[0][0];let me=q.data.inputs[0][1];(!me||me.filter(xe=>xe!==void 0).length===0)&&(me=le),(re=E.current)==null||re.push(le),(ue=A.current)==null||ue.push(me)},j=T.useCallback(()=>{u==null||u.getTracks().forEach(q=>q.stop()),c==null||c.disconnect(),h==null||h.port.removeEventListener("message",z),h==null||h.port.close(),h==null||h.disconnect(),f==null||f.close()},[f,h,u,c]),H=async()=>{const q=await navigator.mediaDevices.getUserMedia({audio:!0}),re=new AudioContext({sampleRate:N}),ue=re.createMediaStreamSource(q);try{await re.audioWorklet.addModule("/infra/public/js/audio-recorder-processor.js")}catch(me){console.error(me)}const le=new AudioWorkletNode(re,"audio-recorder-processor");le.port.addEventListener("message",z),b({type:"update",updatedState:{micStream:q,micStreamAudioSourceNode:ue,audioContext:re,recordTime:0,audioWorkletNode:le,recordState:"RECORDING",playState:"IDLE"}}),A.current=[],E.current=[],le.port.start(),ue.connect(le),le.connect(re.destination)},F=T.useCallback(async()=>{w.current&&(w.current.currentTime=0,w.current.pause()),a==="PAUSED"?(b({type:"update",updatedState:{recordState:"RECORDING",playState:"IDLE"}}),f==null||f.resume(),e==null||e(void 0)):H()},[a,f,w]),L=T.useCallback(()=>{b({type:"update",updatedState:{recordState:"PAUSED",playState:"IDLE",isEncoding:!0}}),f==null||f.suspend(),m&&E.current&&A.current&&(m.postMessage(["wav",A.current,E.current,A.current.length*M]),m.onmessage=q=>{const re=window.URL.createObjectURL(q.data);b({type:"update",updatedState:{isEncoding:!1}}),w.current&&(w.current.src=re),e&&e(re)})},[f,m,e]),O=T.useCallback(()=>{var q;b({type:"update",updatedState:{playState:"PLAYING"}}),((q=w==null?void 0:w.current)!=null&&q.currentTime||w.current)&&w.current.play()},[w]),$=T.useCallback(()=>{var q;(q=w==null?void 0:w.current)==null||q.pause(),b({type:"update",updatedState:{playState:"PAUSED"}})},[w]),V=T.useCallback(()=>{j(),b({type:"update",updatedState:{playState:"IDLE",recordState:"IDLE"}}),A.current=[],E.current=[],e&&e(void 0)},[j,e]),k=T.useCallback(async()=>{var q;const re=(q=_.current)==null?void 0:q.value;if(!re){console.error("Audio name is required");return}return w.current&&(w.current.pause(),w.current.currentTime=0),b({type:"update",updatedState:{recordState:"SAVING",playState:"IDLE"}}),new Promise((ue,le)=>{try{m&&E.current&&A.current&&(m.postMessage(["mp3",A.current,E.current,A.current.length*M]),m.onmessage=async me=>{if(me.data instanceof Blob){const xe=new File([me.data],re,{type:"audio/mp3"}),_e=await I(xe,{application:i,visibility:n});_e&&t&&t(_e),b({type:"update",updatedState:{recordState:"SAVED"}}),ue(_e)}})}catch(me){b({type:"update",updatedState:{playState:"IDLE",recordState:"IDLE"}}),console.error("Error while saving",me),le()}})},[a,t,j]),U=T.useCallback(()=>{w!=null&&w.current&&(w.current.pause(),w.current.currentTime=0),b({type:"update",updatedState:{playState:"IDLE"}})},[w]),B=T.useCallback(()=>{b({type:"update",updatedState:{playState:"PAUSED"}}),w.current&&(w.current.currentTime=0)},[w]);T.useEffect(()=>{if(a==="RECORDING"&&f){const q=window.setInterval(()=>{b({type:"update",updatedState:{recordTime:f.currentTime}}),f.currentTime>=y&&(L(),window.clearInterval(q))},100);return()=>window.clearInterval(q)}},[f,L,y,a]);const X=P(a==="IDLE"?"bbm.audio.record.start":"bbm.audio.record.resume"),K=[{type:"icon",name:"record",visibility:a==="RECORDING"?"hide":"show",props:{icon:g.jsx(Zv,{}),color:"danger",disabled:a!=="IDLE"&&a!=="PAUSED"||v>=y,onClick:F,"aria-label":X},tooltip:X},{type:"icon",name:"recordPause",visibility:a==="RECORDING"?"show":"hide",props:{icon:g.jsx(xz,{}),color:"danger",disabled:a!=="RECORDING",onClick:L,"aria-label":P("bbm.audio.record.pause")},tooltip:P("bbm.audio.record.pause")},{type:"divider"},{type:"icon",name:"encoding",visibility:x?"show":"hide",props:{icon:g.jsx(UN,{style:{animation:"loading 1s infinite"}}),disabled:!0}},{type:"icon",name:"play",visibility:x||l==="PLAYING"?"hide":"show",props:{icon:g.jsx($N,{}),disabled:a!=="RECORDED"&&a!=="PAUSED"&&a!=="SAVED",onClick:O,"aria-label":P("bbm.audio.play.start")},tooltip:P("bbm.audio.play.start")},{type:"icon",name:"playPause",visibility:!x&&l==="PLAYING"?"show":"hide",props:{icon:g.jsx(FT,{}),onClick:$,"aria-label":P("bbm.audio.play.pause")},tooltip:P("bbm.audio.play.pause")},{type:"icon",name:"stop",props:{icon:g.jsx(Az,{}),disabled:l!=="PLAYING"&&l!=="PAUSED",onClick:U,"aria-label":P("bbm.audio.play.stop")},tooltip:P("bbm.audio.play.stop")},{type:"divider"},{type:"icon",name:"reset",props:{icon:g.jsx(VN,{}),disabled:a!=="RECORDED"&&a!=="PAUSED"&&l!=="PLAYING"&&l!=="PAUSED",onClick:V,"aria-label":P("bbm.audio.record.reset")},tooltip:P("bbm.audio.record.reset")},{type:"icon",name:"save",visibility:r?"hide":"show",props:{icon:g.jsx(jT,{}),disabled:a!=="RECORDED"&&a!=="PAUSED"&&l!=="PLAYING"&&l!=="PAUSED"||a==="SAVED"||!((s=_.current)!=null&&s.value),onClick:k,"aria-label":P("bbm.audio.record.save")},tooltip:P("bbm.audio.record.save")}];return{recordState:a,playState:l,audioContext:f,recordTime:v*1e3,maxDuration:y*1e3,audioRef:w,audioNameRef:_,toolbarItems:K,handlePlayEnded:B,handleSave:k}}const fde=T.forwardRef(({onSaveSuccess:t,onRecordUpdated:e,hideSaveAction:r=!1,visibility:n="protected"},i)=>{const{recordState:s,playState:o,recordTime:a,audioRef:l,audioNameRef:u,toolbarItems:c,maxDuration:h,handlePlayEnded:f,handleSave:m}=hde(t,e,r,n,"media-library"),{t:y}=we();T.useImperativeHandle(i,()=>({save:m}));const[v,x]=T.useState(0),b=Re({"text-danger":s==="RECORDING","text-success":o==="PLAYING"}),_=w=>{x(w.target.currentTime)};return g.jsxs("div",{className:"audio-recorder m-auto d-flex flex-column",children:[g.jsx(Ot,{id:"recordName",className:"mb-32",isRequired:!0,isReadOnly:s==="SAVED"||s==="SAVING",children:g.jsx(Kn,{type:"text",size:"sm",placeholder:y("bbm.audio.recorder.name"),ref:u,defaultValue:y("bbm.audio.recorder.defaultName")+new Date().toLocaleDateString()})}),g.jsx("div",{className:"audio-recorder-icon mx-auto",children:g.jsx(c1,{width:64,height:64,className:b})}),g.jsx(dde,{recordState:s,playState:o,recordTime:a,audioTime:v,maxDuration:h}),g.jsx("audio",{ref:l,onEnded:f,onTimeUpdate:_,children:g.jsx("track",{default:!0,kind:"captions",srcLang:"fr",src:""})}),g.jsx(pA,{items:c})]})}),pde=fde,mde=({onSuccess:t})=>{const{t:e}=we(),[r,n]=T.useState();function i(s){const o=s.target.value;n(o),o!=null&&o.length?t(o):t()}return g.jsxs("div",{className:"d-flex flex-column flex-fill",children:[g.jsx("div",{className:"mb-32",children:e("bbm.embed.description")}),g.jsxs("div",{className:"mb-8 d-flex",children:[g.jsx(CS,{className:"me-8"}),e("bbm.embed.title")]}),g.jsx(Ot,{id:"iframeContent",children:g.jsx(fA,{size:"md",height:"sm",placeholder:e("bbm.embed.placeholder"),onChange:i})}),!!(r!=null&&r.length)&&g.jsx("div",{className:"embed-preview mt-12",dangerouslySetInnerHTML:{__html:r}}),!(r!=null&&r.length)&&g.jsx("div",{className:"embed-preview mt-12 d-flex align-items-center justify-content-center bg-gray-300 text-black-50 rounded-3",children:g.jsx("strong",{children:e("bbm.embed.preview")})})]})},gde=mde,vde=({historyCount:t,handle:e})=>{const{t:r}=we(),[n,i]=T.useState(void 0),s=a=>{i(a),e(a)},o=[{type:"button",name:"undo",props:{color:"tertiary",leftIcon:g.jsx(zz,{}),"aria-label":r("cancel"),children:r("cancel"),onClick:()=>s("UNDO"),disabled:t===0},tooltip:r("cancel")},{type:"divider",name:"div-1"},{type:"button",name:"reset",props:{color:"tertiary",leftIcon:g.jsx(GN,{}),"aria-label":r("rotate"),children:r("rotate"),onClick:()=>s("ROTATE")},tooltip:r("rotate")},{type:"button",name:"crop",props:{color:"tertiary",leftIcon:g.jsx(H$,{}),"aria-label":r("crop"),children:r("crop"),className:n==="CROP"?"is-selected":"",onClick:()=>s("CROP")},tooltip:r("crop")},{type:"button",name:"blur",props:{color:"tertiary",leftIcon:g.jsx(D$,{}),"aria-label":r("blur"),children:r("blur"),className:n==="BLUR"?"is-selected":"",onClick:()=>s("BLUR")},tooltip:r("blur")}];return g.jsx(pA,{variant:"no-shadow",align:"left",isBlock:!0,items:o})},yde=vde,xde=100,Ak=100,bde=450,wde=64,_de=.5,Sde="image";function R2(t,{spriteName:e,imgDatasource:r,settings:n}){const i=URL.createObjectURL(r),s=new Image;return s.src=i,new Promise(o=>{s.onload=async()=>{await P2(t,{spriteName:e,imgDatasource:s,settings:n});const a=t==null?void 0:t.stage.getChildByName(e,!0);o(a)}})}async function P2(t,{spriteName:e,imgDatasource:r,settings:n}){if(t===void 0||t.stage===null)return;const i=t.stage.getChildByName(e,!0);i==null||i.removeFromParent();const s=r instanceof HTMLImageElement?Ee.from(r):r instanceof Ar?r:await Ee.fromURL(r),o=s instanceof Ar?s:Ar.from(s,{});if(o.interactive=!0,o.name=e,n){const{sprite:{anchor:a,position:l,scale:u,size:c,rotation:h},stage:{size:f}}=n,m=h%Math.PI!==0;o.anchor.x=a.x,o.anchor.y=a.y,o.position.x=l.x,o.position.y=l.y,o.scale.x=u.x,o.scale.y=u.y,o.width=m?c.height:c.width,o.height=m?c.width:c.height,t.stage.height=f.height,t.stage.width=f.width,t.renderer.resize(f.width,f.height),t.stage.addChild(o)}else t.stage.addChild(o),t.renderer.resize(o.width,o.height);Ede(t,o)}function Ede(t,e){var r;const n=t.view.parentNode,i=window.innerWidth-wde,s=Math.max((n==null?void 0:n.offsetWidth)??0,Ak),o=Tde({width:e.width,height:e.height},{width:{max:Math.min(s,i),min:Ak},height:{min:xde,max:window.innerHeight-bde}}),{height:a,width:l}=o;(r=t.view)!=null&&r.style&&(t.view.style.width=`${l}px`,t.view.style.height=`${a}px`)}function Tde(t,e){const{height:r,width:n}=t,i=n/r,{height:s,width:o}=e;let a=o.max,l=o.max/i;return n>o.max&&(a=o.max,l=a/i),l>s.max&&(l=s.max,a=l*i),a<o.min&&(a=o.min,l=a/i),l<s.min&&(l=s.min,a=l*i),{width:a,height:l}}function Cde(t){return new Promise((e,r)=>{var n;(n=t==null?void 0:t.view)!=null&&n.toBlob?t.view.toBlob(i=>{i?e(i):r("EXTRACT_FAILED")},"image/jpeg",_de):r("EXTRACT_FAILED")})}function Ade(t){var e,r;return(r=(e=t.view).toDataURL)==null?void 0:r.call(e)}function gA(t){return t.view.getBoundingClientRect?t.view.getBoundingClientRect().width/t.view.width:1}function I2(t){return new Promise((e,r)=>{var n,i;(i=(n=t.view).toBlob)==null||i.call(n,s=>{s?e(s):r("EXTRACT_FAIL")},"image/png",1)})}function Rde({application:t,sprite:e}){return{sprite:{rotation:e.rotation,size:{width:e.width,height:e.height},position:{x:e.position.x,y:e.position.y},scale:{x:e.scale.x,y:e.scale.y},anchor:{x:e.anchor.x,y:e.anchor.y}},stage:{size:{width:t.stage.width,height:t.stage.height},scale:{x:t.stage.scale.x,y:t.stage.scale.y}}}}function Pde({application:t,sprite:e,newHeight:r,newWidth:n}){e.anchor.x=.5,e.anchor.y=.5,e.position=new tt(n/2,r/2),t.stage.height=r,t.stage.width=n,t.renderer.resize(n,r)}const Ide=20,Mde=({maxSize:t=Ide,application:e,spriteName:r,onRestore:n})=>{const[i,s]=T.useState([]);T.useEffect(()=>{s([])},[e]);const o=async()=>{const u=i.pop();u&&(n(await u.backup,u),s(i.filter(c=>c!==u)))},a=u=>(u.length>t&&u.splice(0,u.length-t),u),l=async u=>{{if(!e)return;const c=e.stage.getChildByName(r,!0);if(c==null)return;const h=I2(e),f={backup:h,sprite:{rotation:c.rotation,size:{width:c.width,height:c.height},position:{x:c.position.x,y:c.position.y},scale:{x:c.scale.x,y:c.scale.y},anchor:{x:c.anchor.x,y:c.anchor.y}},stage:{size:{width:e.stage.width,height:e.stage.height},scale:{x:e.stage.scale.x,y:e.stage.scale.y}}};return s([...a(i),f]),await h,u.call(u)}};return{historyCount:i.length,restore:o,historize:l}},kde=Mde;function Ode(t,e,r){let n;const i=[];return function(s){i.push(e(s)),!n&&(n=setTimeout(()=>{const o=[...i];i.splice(0,i.length),r(o),n=void 0},t))}}const c8=20,Dde=50,vA="BRUSH_CURSOR";function Nde(t,e){const r=new Vi;for(const n of t)n&&(r.beginFill(16777215,1),r.drawCircle(n.x,n.y,c8/e),r.lineStyle(0),r.endFill());return r}function Lde(t,{spriteName:e}){return Ode(Dde,r=>t.stage.toLocal(r.global),r=>{const n=t.stage.getChildByName(e),i=gA(t);if(n==null)return;const s=new Ar(n.texture);s.filters=[new bj(8,4,Math.min(i,1))],s.width=n.width,s.height=n.height,s.scale=new tt(1,1),s.anchor=n.anchor,s.mask=Nde(r,i),n.addChild(s)})}function Fde(t){d8(t);const e=gA(t),r=new Vi;return r.lineStyle(Math.max(1,1/e),16711680),r.drawCircle(0,0,c8/e),r.endFill(),r.name=vA,t.stage.addChild(r),r}function d8(t){const e=t.stage.getChildByName(vA);e&&e.removeFromParent()}function jde(t){return e=>{if(!t)return;const r=t.stage.toLocal(e.global),n=t.stage.getChildByName(vA,!0);n&&(n.position.x=r.x,n.position.y=r.y)}}function Bde(t,{spriteName:e}){t.stage.interactive=!0;const r=Fde(t),n=jde(t);t.stage.on("pointermove",n);const i=Lde(t,{spriteName:e});t.stage.on("pointerdown",()=>{t.stage.on("pointermove",i)});const s=()=>{var o;(o=t==null?void 0:t.stage)==null||o.off("pointermove",i)};globalThis.addEventListener("pointerup",s),r.once("destroyed",()=>{globalThis.removeEventListener("pointerup",s)})}function Ude(t){d8(t),t.stage.off("pointerdown"),t.stage.off("pointermove")}const $de=["TOP_LEFT","TOP_RIGHT","BOTTOM_LEFT","BOTTOM_RIGHT"],D0=0,zde=20,yA="CROP_BACKGROUND_NAME",Rm="CROP_MASK_NAME";function M2(t){return"CROP_CORNER_"+t}function Hde(t,{spriteName:e}){h8(t);const r=t.stage.getChildByName(e);if(r==null)return;const n=r.getBounds(),i=t.renderer.generateTexture(t.stage).clone(),s=new Ar(i);s.height=n.height,s.width=n.width,s.position=new tt(0,0);const o=new Vi;o.beginFill(16777215,.5),o.drawRect(0,0,n.width,n.height),o.endFill(),o.name=yA,o.position=new tt(n.x,n.y);const a=new Vi;a.beginFill(0,1),a.drawRect(0,0,n.width-2*D0,n.height-2*D0),a.endFill(),a.position=new tt(D0,D0),a.name=Rm,s.mask=a,t.stage.addChild(o),o.addChild(a),o.addChild(s)}function h8(t){const e=t.stage.getChildByName(yA,!0);e==null||e.removeFromParent()}function f8(t,e){switch(t){case"TOP_LEFT":return{x:e.x,y:e.y,start:0,end:Math.PI/2};case"TOP_RIGHT":return{x:e.x+e.width,y:e.y,start:Math.PI/2,end:Math.PI};case"BOTTOM_LEFT":return{x:e.x,y:e.y+e.height,start:3*Math.PI/2,end:2*Math.PI};case"BOTTOM_RIGHT":return{x:e.x+e.width,y:e.y+e.height,start:Math.PI,end:3*Math.PI/2}}}function Vde(t){const e=t.stage.getChildByName(Rm,!0);e!=null&&$de.forEach(r=>{const n=t.stage.getChildByName(M2(r),!0);if(n==null)return;const i=f8(r,{height:e.height,width:e.width,x:e.x,y:e.y});n.position=new tt(i.x,i.y)})}function N0(t,e,{spriteName:r}){const n=t.stage.getChildByName(M2(e),!0),i=gA(t);n==null||n.removeFromParent();const s=t.stage.getChildByName(yA,!0),o=t.stage.getChildByName(Rm,!0);if(t.stage.getChildByName(r)==null||s===null||s===void 0||o===void 0||o===null)return;const l=f8(e,{height:o.height,width:o.width,x:o.x,y:o.y}),u=new Vi;u.beginFill(4960213,1),u.arc(0,0,zde/i,l.start,l.end),u.lineTo(0,0),u.endFill(),u.position=new tt(l.x,l.y),u.name=M2(e),u.interactive=!0;let c=!1;t.stage.on("pointermove",m=>{if(c===!1)return;const y=s.toLocal(m.global);u.position.x=y.x,u.position.y=y.y,Gde(t,e,y)});const h=()=>{c=!0};u.on("pointerdown",h);const f=()=>{c=!1};globalThis.addEventListener("pointerup",f),u.once("destroyed",()=>{u.off("pointerdown"),globalThis.removeEventListener("pointerup",f)}),s.addChild(u)}function Gde(t,e,r){const n=t.stage.getChildByName(Rm,!0);if(n==null)return;const i=n.position.x+n.width,s=n.position.y+n.height;switch(e){case"TOP_LEFT":{n.position.x=r.x,n.position.y=r.y,n.width=i-r.x,n.height=s-r.y;break}case"TOP_RIGHT":{n.position.y=r.y,n.width=r.x-n.position.x,n.height=s-r.y;break}case"BOTTOM_LEFT":{n.position.x=r.x,n.width=i-r.x,n.height=r.y-n.position.y;break}case"BOTTOM_RIGHT":{n.width=r.x-n.position.x,n.height=r.y-n.position.y;break}}Vde(t)}function Wde(t,{spriteName:e}){xA(t),t.stage.interactive=!0,t.stage.interactiveChildren=!0,Hde(t,{spriteName:e}),N0(t,"BOTTOM_LEFT",{spriteName:e}),N0(t,"BOTTOM_RIGHT",{spriteName:e}),N0(t,"TOP_LEFT",{spriteName:e}),N0(t,"TOP_RIGHT",{spriteName:e})}function xA(t){h8(t),t.stage.off("pointermove"),t.render()}function Xde(t){const e=t.stage.getChildByName(Rm,!0);if(e==null)return;xA(t);const r=t.renderer.generateTexture(t.stage).clone(),n=new Ar(r),i=e.getBounds(),s=new st(Math.floor(i.x),Math.floor(i.y),Math.floor(i.width),Math.floor(i.height)),o=new Ee(n.texture.baseTexture,s);return new Ar(o)}const qde=20,tx="CONTROL_NAME";function p8(t){return"RESIZE_CORNER_"+t}function Yde(t,e){const r=e.x,n=e.y;switch(t){case"TOP_LEFT":return{x:r,y:n,start:0,end:Math.PI/2};case"TOP_RIGHT":return{x:r+e.width,y:n,start:Math.PI/2,end:Math.PI};case"BOTTOM_LEFT":return{x:r,y:n+e.height,start:3*Math.PI/2,end:2*Math.PI};case"BOTTOM_RIGHT":return{x:r+e.width,y:n+e.height,start:Math.PI,end:3*Math.PI/2}}}function Qde(t,{container:e,cornerType:r,position:n,spriteName:i}){const s=t.stage.getChildByName(i,!0);if(s==null)return;const o=s.rotation%Math.PI!==0,a=o?s.height:s.width,l=o?s.width:s.height;switch(r){case"TOP_LEFT":{e.position=new tt(n.x,n.y),e.width=a-2*n.x,e.height=l-2*n.y;break}case"TOP_RIGHT":{const u=a-n.x;e.position=new tt(u,n.y),e.width=a-2*u,e.height=l-2*n.y;break}case"BOTTOM_LEFT":{const u=l-n.y;e.position=new tt(n.x,u),e.width=a-2*n.x,e.height=l-2*u;break}case"BOTTOM_RIGHT":{const u=l-n.y,c=a-n.x;e.position=new tt(c,u),e.width=a-2*c,e.height=l-2*u;break}}}function kf(t,e){const r=t.stage.getChildByName(p8(e),!0);r==null||r.removeFromParent()}function L0(t,e,{spriteName:r}){kf(t,e);const n=t.stage.getChildByName(r,!0),i=t.stage.getChildByName(tx,!0);if(n==null||i===null||i===void 0)return;const s=Yde(e,i),o=new Vi;o.beginFill(4960213,1),o.arc(0,0,qde,s.start,s.end),o.lineTo(0,0),o.endFill(),o.position=new tt(s.x,s.y),o.name=p8(e),o.interactive=!0;let a=!1;t.stage.on("pointermove",c=>{if(a===!1)return;const h=t.stage.toLocal(c.global);Qde(t,{cornerType:e,position:h,container:i,spriteName:r})});const l=()=>{a=!1};globalThis.addEventListener("pointerup",l),o.once("destroyed",()=>{o.off("pointerdown"),globalThis.removeEventListener("pointerup",l)});const u=()=>{a=!0};o.on("pointerdown",u),i.addChild(o)}function Kde(t,e){m8(t);const r=t.stage.getChildByName(e,!0);if(r==null)return;const n=t.renderer.generateTexture(t.stage),i=new Ar(n);t.stage.children.forEach(o=>{o.alpha=0});const s=new Vi;s.drawRect(0,0,r.width,r.height),s.name=tx,s.interactive=!0,s.interactiveChildren=!0,t.stage.interactive=!0,t.stage.interactiveChildren=!0,t.stage.addChild(s),s.addChild(i)}function m8(t){const e=t.stage.getChildByName(tx,!0);e==null||e.removeFromParent(),t.stage.children.forEach(r=>{r.alpha=1})}function Zde(t,e){Kde(t,e),L0(t,"BOTTOM_LEFT",{spriteName:e}),L0(t,"BOTTOM_RIGHT",{spriteName:e}),L0(t,"TOP_LEFT",{spriteName:e}),L0(t,"TOP_RIGHT",{spriteName:e})}function g8(t){m8(t),kf(t,"BOTTOM_LEFT"),kf(t,"BOTTOM_RIGHT"),kf(t,"TOP_LEFT"),kf(t,"TOP_RIGHT"),t.stage.off("pointermove")}function Jde(t,e){Zde(t,e)}function ehe(t){g8(t),t.stage.off("pointermove"),t.render()}function the(t){var e;const r=(e=t==null?void 0:t.stage)==null?void 0:e.getChildByName(tx,!0),n=r?{height:r.height,width:r.width}:void 0;if(g8(t),n){const i=t.renderer.generateTexture(t.stage).clone(),s=new Ar(i);return s.width=n.width,s.height=n.height,s}else return}async function rhe(t,e){const r=t==null?void 0:t.stage.getChildByName(e,!0);if(t&&r){if(!t)return;const n=await I2(t),i=await R2(t,{imgDatasource:n,spriteName:e,settings:Rde({application:t,sprite:r})});if(!i)return;let s,o;const a=t.view;a.style&&(s=a.style.maxHeight??"",o=a.style.visibility??"",a.style.maxHeight=`${a.clientHeight}px`,a.style.visibility="hidden"),i.rotation+=Math.PI/2,Pde({application:t,sprite:i,newHeight:i.width,newWidth:i.height}),t.render();const l=await I2(t);s!==void 0&&(a.style.maxHeight=s),o!==void 0&&(a.style.visibility=o),await R2(t,{imgDatasource:l,spriteName:e})}}function nhe({application:t,spriteName:e,onSave:r}){return{rotate:async()=>{t&&await rhe(t,e)},startCrop:()=>{t&&Wde(t,{spriteName:e})},stopCrop:n=>{if(t){if(n){const i=Xde(t);i&&r(i)}xA(t)}},startBlur:()=>{t&&Bde(t,{spriteName:e})},stopBlur:()=>{t&&Ude(t)},startResize:()=>{t&&Jde(t,e)},stopResize:n=>{if(t){if(n){const i=the(t);i&&r(i)}ehe(t)}}}}function ihe({imageSrc:t,spriteName:e=Sde}){const[r,n]=T.useState(void 0),[i,s]=T.useState(!0),{rotate:o,startBlur:a,startCrop:l,startResize:u,stopBlur:c,stopCrop:h,stopResize:f}=nhe({spriteName:e,application:r,onSave(_){r&&P2(r,{imgDatasource:_,spriteName:e})}}),m=()=>r?Cde(r):Promise.resolve(void 0),y=()=>{if(r)return Ade(r)},{restore:v,historize:x,historyCount:b}=kde({application:r,spriteName:e,onRestore(_,w){r&&R2(r,{imgDatasource:_,spriteName:e,settings:w})}});return T.useEffect(()=>{r&&(s(!0),P2(r,{spriteName:e,imgDatasource:t}).finally(()=>s(!1)))},[r,t,e]),{historyCount:b,setApplication:n,restore:v,stopCrop:h,stopBlur:c,stopResize:f,startResize:async()=>{s(!0),await x(u),s(!1)},startCrop:async()=>{s(!0),await x(l),s(!1)},startBlur:async()=>{s(!0),await x(a),s(!1)},rotate:async()=>{s(!0),await x(o),s(!1)},toBlob:m,toDataURL:y,loading:i}}const she=({altText:t,legend:e,image:r,isOpen:n,onCancel:i,onError:s,onSave:o})=>{const{t:a}=we(),[l,u]=T.useState(void 0),[c,h]=T.useState(!1),[f,m]=T.useState(t??""),[y,v]=T.useState(e??""),[x,b]=T.useState(!1),{toBlob:_,setApplication:w,startBlur:E,stopBlur:A,restore:P,rotate:I,startCrop:M,stopCrop:N,startResize:z,stopResize:j,historyCount:H,loading:F}=ihe({imageSrc:r}),L=()=>{A(),N(l==="CROP"),j(l==="RESIZE")},O=async()=>{try{h(!0),L();const k=await _();k&&await o({blob:k,legend:y,altText:f})}catch(k){s==null||s(`${k}`)}finally{h(!1)}},$=()=>{i()},V=async k=>{switch(L(),u(k),b(!0),k){case"ROTATE":{await I();break}case"UNDO":{await P();break}case"CROP":{M();break}case"RESIZE":{await z();break}case"BLUR":{await E();break}}};return g.jsxs(Ye,{id:"image-editor",isOpen:n,onModalClose:$,size:"lg",children:[g.jsx(Ye.Header,{onModalClose:$,children:g.jsx("span",{className:"h2",children:a("imageeditor.title")})}),g.jsx(Ye.Body,{className:"d-flex flex-column align-items-center",children:g.jsxs("div",{className:"d-flex flex-column gap-12 w-100 flex-grow-1",children:[g.jsx(yde,{handle:V,historyCount:H}),g.jsxs("div",{className:"position-relative d-flex flex-column align-items-center justify-content-center flex-grow-1 w-100 image-editor",children:[g.jsx(lre.Stage,{onMount:k=>w(k),options:{preserveDrawingBuffer:!0,backgroundAlpha:0,resolution:1}}),!!F&&g.jsx("div",{className:"position-absolute top-0 start-0 bottom-0 end-0 m-10 d-flex align-items-center justify-content-center bg-black opacity-25",children:g.jsx(fr,{})})]}),g.jsxs("div",{className:"d-flex flex-column flex-md-row m-10 gap-12 w-100",children:[g.jsxs(Ot,{id:"alt",className:"flex-grow-1",children:[g.jsx(Gi,{children:a("alttext")}),g.jsx(Kn,{value:f,onChange:k=>{b(!0),m(k.target.value)},placeholder:a("alttext.help"),size:"md",type:"text"})]}),g.jsxs(Ot,{id:"legend",className:"flex-grow-1",children:[g.jsx(Gi,{children:a("legend")}),g.jsx(Kn,{value:y,onChange:k=>{b(!0),v(k.target.value)},placeholder:a("legend.help"),size:"md",type:"text"})]})]})]})}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{color:"tertiary",onClick:$,type:"button",variant:"ghost",children:a("imageeditor.cancel")}),g.jsx(it,{color:"primary",onClick:O,type:"button",variant:"filled",isLoading:c,disabled:c||!x,children:a("imageeditor.save")})]})]})},ohe=she,ahe=({doc:t,isClickable:e=!0,isSelectable:r=!1,isSelected:n=!1,onClick:i,className:s})=>{const{fromNow:o}=IL(),{fromDate:a}=T.useMemo(()=>({fromDate:o(t.modifiedAt)}),[o,t]);return g.jsx(tr,{className:Re("card-linker shadow-none",s),isClickable:e,isSelectable:r,isSelected:n,onClick:i,children:g.jsxs(tr.Body,{space:"8",children:[g.jsx("div",{className:"card-image ps-8 pe-4",children:t.thumbnail&&t.thumbnail.length>0?g.jsx(wo,{alt:"",height:48,width:48,src:t.thumbnail,objectFit:"cover",className:"rounded h-full",style:{aspectRatio:1/1}}):g.jsx(ya,{app:t.application,iconFit:"ratio",size:"48",variant:"rounded"})}),g.jsxs("div",{className:"w-75",children:[g.jsx(tr.Text,{children:t.name}),g.jsx(tr.Text,{className:"text-black-50",children:t==null?void 0:t.creatorName})]}),g.jsx("div",{className:"d-none d-md-block text-black-50 ps-4 pe-8",children:g.jsx(tr.Text,{children:a})}),t.shared&&g.jsx("div",{className:"ps-4 pe-8",children:g.jsx(BT,{width:"20",height:"20"})})]})})},lhe=ahe,uhe=({appCode:t,defaultAppCode:e,defaultResourceId:r,onChange:n,onSelect:i,multiple:s=!0,resourceList:o,applicationList:a,showApplicationSelector:l=!0})=>{const{t:u}=we(),{theme:c}=ba(),[h]=Pn(),{resourceApplications:f,loadResources:m}=Jce(t),[y,v]=T.useState(),[x,b]=T.useState(),[_,w]=T.useState(),E=sA(_||"",500),[A,P]=T.useState([]),I=T.useCallback((k,U)=>{var B,X,K;if(!U)return!0;const q=(U==null?void 0:U.toLowerCase())||"";return((B=k.name)==null?void 0:B.toLowerCase().includes(q))||((X=k.creatorName)==null?void 0:X.toLowerCase().includes(q))||((K=k.description)==null?void 0:K.toLowerCase().includes(q))},[]),M=T.useCallback(k=>k.sort((U,B)=>U.modifiedAt<B.modifiedAt?1:-1),[]),N=T.useCallback(k=>{async function U(){if(o){const B=o.filter(X=>I(X,k));P(M(B));return}else if(x)try{const B=(await m({application:x.application,search:k,types:[x.application],filters:{},pagination:{startIdx:0,pageSize:300}})).filter(X=>I(X,k));P(M(B));return}catch{}P([])}U()},[m,x,I,M,o]),[z,j]=T.useState([]),H=k=>{n==null||n(k),b(k)},F=k=>{const U=k.target.value;w(U.toString())},L=T.useCallback(k=>{N(_),k.stopPropagation(),k.preventDefault()},[N,_]),O=T.useCallback(k=>z.findIndex(U=>U.assetId===k),[z]),$=T.useCallback(k=>{j(s?U=>[...U,k]:[k])},[j,s]),V=T.useCallback(k=>{const U=O(k.assetId);U<0?$(k):j(z.filter((B,X)=>X!==U))},[O,$,z]);return T.useEffect(()=>{(async()=>{if(a){v(a.sort((B,X)=>B.displayName.localeCompare(X.displayName)));return}const k=f.map(B=>Me.session().getWebApp(B)),U=await Promise.all(k);v(f.map((B,X)=>{var K;return{application:B,displayName:u(((K=U[X])==null?void 0:K.displayName)??B),icon:g.jsx(ya,{app:U[X],size:"24"})}}).sort((B,X)=>B.displayName.localeCompare(X.displayName)))})()},[f,u,a]),T.useEffect(()=>{N(E)},[N,E]),T.useEffect(()=>{i==null||i(z)},[z]),T.useEffect(()=>{var k;const U=e??((a==null?void 0:a.length)===1&&((k=a==null?void 0:a[0])==null?void 0:k.application));if(U){const B=y==null?void 0:y.find(X=>U===X.application);b(B),N("")}},[y,e]),T.useEffect(()=>{if(r&&O(r)<0){const k=A==null?void 0:A.find(U=>r===U.assetId);k&&$(k)}},[A]),g.jsxs("div",{className:"d-flex flex-column flex-fill overflow-hidden",children:[g.jsxs("div",{className:"search d-flex bg-light rounded-top border border-bottom-0",children:[l&&g.jsx("div",{className:"flex-shrink-1 px-8 py-12 border-end",children:g.jsxs(xt,{overflow:!0,children:[g.jsx(xt.Trigger,{icon:g.jsx("div",{className:"pe-8",children:(x==null?void 0:x.icon)||g.jsx(NN,{})}),label:u((x==null?void 0:x.displayName)||"bbm.linker.int.choose"),variant:"ghost",size:"md"}),g.jsx(xt.Menu,{children:y==null?void 0:y.map(k=>g.jsx(xt.Item,{icon:k.icon,onClick:()=>H(k),children:k.displayName},k.application))})]})}),g.jsx("div",{className:"flex-grow-1 align-self-center",children:g.jsx("form",{className:"gap-16 d-flex w-100 align-items-center px-16 py-8",onSubmit:L,children:g.jsx(s8,{isVariant:!0,placeholder:u("search"),size:"lg",className:"w-100",disabled:!x,onChange:F})})})]}),g.jsxs("div",{className:"internal-linker flex-grow-1 w-100 rounded-bottom border gap-0 overflow-auto",children:[x&&A&&A.length>0&&g.jsx("div",{children:A.map(k=>{const U=z.findIndex(B=>B.assetId===k.assetId)>=0;return g.jsx(lhe,{doc:k,isSelected:U,onClick:()=>V(k)},k.path)})}),x&&A&&A.length<=0&&g.jsx("div",{className:"d-flex justify-content-center mt-16",children:g.jsx(ha,{imageSrc:`${h}/${c==null?void 0:c.bootstrapVersion}/illu-empty-search-${x.application}.svg`,text:u("bbm.linker.int.notfound"),className:"mt-16"})}),!x&&g.jsx("div",{className:"d-flex justify-content-center mt-32",children:g.jsx(ha,{imageSrc:`${h}/${c==null?void 0:c.bootstrapVersion}/illu-empty-search.svg`,text:u("bbm.linker.int.empty"),className:"mt-32"})})]})]})},che=uhe,dhe=({link:t,onChange:e,multiNodeSelected:r=!1})=>{const{t:n}=we(),[i,s]=T.useState((t==null?void 0:t.text)||""),[o,a]=T.useState((t==null?void 0:t.url)||""),[l,u]=Cm(t?t.target==="_blank":!0);return T.useEffect(()=>{r&&t!=null&&t.text&&s(t.text.slice(0,20)+"...")},[r,t]),T.useEffect(()=>{if(!o.length){e==null||e();return}const c={url:o,text:r?t==null?void 0:t.text:i||o,target:l?"_blank":void 0};!Ek.isLocalURL(o)&&!Ek.startWithHttp(o)&&(c.url="http://"+o),e==null||e(c)},[i,o,l]),g.jsx(g.Fragment,{children:g.jsxs("div",{className:"d-flex flex-column flex-fill gap-24",children:[g.jsxs(Ot,{id:"linkText",isOptional:!0,children:[g.jsx(Gi,{children:n("bbm.linker.ext.text")}),g.jsx(Kn,{type:"text",placeholder:n("bbm.linker.ext.text.placeholder"),size:"md",disabled:r,value:i,onChange:c=>s(c.target.value)})]}),g.jsxs(Ot,{id:"linkUrl",isRequired:!0,children:[g.jsx(Gi,{children:n("bbm.linker.ext.url")}),g.jsx(Kn,{type:"text",placeholder:n("bbm.linker.ext.url.placeholder"),size:"md",value:o,onChange:c=>a(c.target.value)})]}),g.jsx(Tm,{label:n("bbm.linker.open.tab"),onChange:()=>u(),checked:l})]})})},hhe=dhe,v8=T.createContext(null);function Xl(){const t=T.useContext(v8);if(!t)throw new Error("Innertabs compound components cannot be rendered outside the MediaLibrary component");return t}const fhe=()=>{const{setResult:t,setPreSuccess:e,visibility:r}=Xl(),n=T.useRef(null);return g.jsx(pde,{ref:n,onRecordUpdated:i=>{i?(t(i),e(()=>n.current.save)):t()},onSaveSuccess:i=>{i&&t(i)},hideSaveAction:!0,visibility:r})},phe=({link:t,multiNodeSelected:e=!1})=>{const{setResult:r}=Xl();return g.jsx(hhe,{link:t,onChange:n=>{r(n)},multiNodeSelected:e})},mhe=()=>{const{setResult:t}=Xl();return g.jsx(gde,{onSuccess:e=>{e=e==null?void 0:e.replace(/<p /g,"<div ").replace(/\/p>/g,"/div>"),t(e)}})},ghe=({target:t,resourceId:e,appPrefix:r})=>{const{t:n}=we(),{setResult:i,setResultCounter:s,appCode:o,multiple:a}=Xl(),[l,u]=Cm(t==="_blank"),[c,h]=T.useState([]),f=m=>{h(m)};return T.useEffect(()=>{i({target:l?"_blank":void 0,resources:c}),c&&c.length?s(c.length):s(void 0)},[l,c]),g.jsxs("div",{className:"d-flex flex-column flex-fill gap-16 overflow-hidden",children:[g.jsx(che,{appCode:o,defaultAppCode:r,defaultResourceId:e,onSelect:f,multiple:a}),g.jsx(Tm,{className:"align-items-center",checked:l,label:n("bbm.linker.open.tab"),onChange:u})]})},vhe=(t,e)=>{if(t==0)return"0 octets";const r=1e3,n=e,i=["octets","Ko","Mo","Go"],s=Math.floor(Math.log(t)/Math.log(r));return parseFloat((t/Math.pow(r,s)).toFixed(n))+" "+i[s]},yhe=({onFilesChange:t,visibility:e="protected"})=>{const{files:r,uploadedFiles:n,getUploadStatus:i,uploadFile:s,removeFile:o,updateImage:a,editingImage:l,setEditingImage:u,getUrl:c}=rde({handleOnChange:t,application:"media-library",visibility:e}),h=T.useRef(new Map);T.useEffect(()=>{const y=h.current;return()=>{y.forEach(v=>URL.revokeObjectURL(v)),y.clear()}},[]);const f=y=>{const v=y.type.startsWith("image")?h.current.get(y.name):"";return h.current.has(y.name)||h.current.set(y.name,URL.createObjectURL(y)),{name:y.name,info:{type:y.type,weight:vhe(y.size||0,1)},src:v}},m=y=>{const v=h.current.get(y.name);v&&(URL.revokeObjectURL(v),h.current.delete(y.name)),o(y)};return g.jsxs(g.Fragment,{children:[r.map(y=>{const v=n.find(x=>x.name===y.name);return g.jsx(kue,{status:i(y),item:f(y),onEdit:()=>u(v),onRetry:()=>s(y),onDelete:()=>m(y)},y.name)}),l&&g.jsx(ohe,{altText:l.alt,legend:l.title,image:c(l,!0),isOpen:!!l,onCancel:()=>u(void 0),onSave:a,onError:console.error})]})},xhe=yhe,bhe=t=>{const e=[];switch(t){case"audio":e.push("audio/*");break;case"video":e.push("video/*");break;case"image":e.push("image/png"),e.push("image/jpeg"),e.push("image/webp"),e.push("image/gif"),e.push("image/avif");break}return e},whe=()=>{const{type:t,visibility:e,multiple:r,setResult:n,setResultCounter:i,setCancellable:s}=Xl(),o=a=>{a.length?(s(a),i(a.length),n(a)):(s([]),i(void 0),n(void 0))};return g.jsx("div",{className:"py-8 flex-grow-1",children:g.jsx(kce,{multiple:r,accept:bhe(t??"embedder"),children:g.jsx(xhe,{onFilesChange:o,visibility:e})})})},x_=9,b_=16,_he=T.forwardRef(({appCode:t,caption:e,onSuccess:r,onError:n,onRecordUpdated:i,hideSaveAction:s=!1},o)=>{const[a,l]=T.useState(18e4),[u,c]=T.useState([]),[h,f]=T.useState(!1),[m,y]=T.useState(!1),[v,x]=T.useState(!1),[b,_]=T.useState(!1),[w,E]=T.useState(!1),[A,P]=T.useState({audio:!0,video:{facingMode:"environment",aspectRatio:b_/x_}}),[I,M]=T.useState(),[N,z]=T.useState(""),[j,H]=T.useState([]),[F,L]=T.useState(),[O,$]=T.useState(0),[V,k]=T.useState(0),U=T.useRef(null),B=T.useRef(null),{uploadBlob:X}=l8(void 0,t),{device:K}=B6(navigator.userAgent);T.useImperativeHandle(o,()=>({save:de}));const{t:q}=we();T.useEffect(()=>{re(),ue()},[]),T.useEffect(()=>(I||le(A),()=>{I&&I.getTracks().forEach(Pe=>Pe.stop())}),[I]),T.useEffect(()=>{if(j.length&&!h&&U.current){const Pe=new Blob(j,{type:N});if(L(Pe),i){const Ke=window.URL.createObjectURL(Pe);i(Ke)}U.current.autoplay=!1,U.current.srcObject=null,U.current.src=window.URL.createObjectURL(Pe)}},[h,j]),T.useEffect(()=>{if(h){const Pe=Date.now(),Ke=window.setInterval(()=>$(Date.now()-Pe),500);return()=>{window.clearInterval(Ke)}}},[h]),T.useEffect(()=>{if(v){const Pe=window.setInterval(()=>k(Ke=>Ke+500),500);return()=>{window.clearInterval(Pe)}}},[v]);const re=async()=>{const Pe=await Me.video().getVideoConf();l((Pe.maxDuration??3)*60*1e3)},ue=async()=>{const Pe=(await navigator.mediaDevices.enumerateDevices()).filter(Ke=>Ke.kind==="videoinput");switch(K.type){case"mobile":case"tablet":{const Ke={deviceId:"environment",label:q("video.back.camera"),groupId:"",kind:"videoinput"},Rt={deviceId:"user",label:q("video.front.camera"),groupId:"",kind:"videoinput"};(Pe==null?void 0:Pe.length)>1?c([Ke,Rt]):c([Ke]);break}default:c(Pe);break}},le=async Pe=>{try{const Ke=await navigator.mediaDevices.getUserMedia(Pe);M(Ke),U.current&&(U.current.src&&(window.URL.revokeObjectURL(U.current.src),U.current.src=""),U.current.srcObject=Ke,U.current.autoplay=!0,U.current.volume=1,U.current.muted=!0)}catch(Ke){console.error(Ke)}},me=T.useCallback(()=>{f(!0),U&&U.current&&(U.current.muted=!0);const Pe=Gue();z(Pe),I&&(B.current=new MediaRecorder(I,{mimeType:Pe}),B.current.ondataavailable=({data:Ke})=>{Ke.size>0&&H(Rt=>[...Rt,Ke])},B.current.onerror=Ke=>console.error(Ke),B.current.start(1e3))},[I]),xe=T.useCallback(()=>{var Pe;f(!1),y(!0),((Pe=B.current)==null?void 0:Pe.state)==="recording"&&(B.current.requestData(),B.current.stop())},[B]),_e=T.useCallback(()=>{var Pe,Ke;U&&U.current&&(U.current.muted=!1),v?((Ke=U==null?void 0:U.current)==null||Ke.pause(),x(!1)):((Pe=U==null?void 0:U.current)==null||Pe.play(),x(!0))},[v]),Te=()=>{y(!1),f(!1),x(!1),E(!1),$(0),H([]),L(void 0),le(A),i&&i()},de=async()=>{var Pe;if((Pe=U==null?void 0:U.current)==null||Pe.pause(),_(!0),!F){console.error("Error while saving video: recorded video is undefined.");return}const Ke=await X(F,{duration:O});if(Ke!=null)return r==null||r([Ke]),_(!1),E(!0),[Ke];n("Error while uploading video"),_(!1),E(!0)},Be=()=>{x(!1),k(0),U.current&&(U.current.currentTime=0)},je=Pe=>{var Ke;const Rt=u.find(J=>J.label===Pe);let W={};Rt!=null&&Rt.deviceId?((Rt==null?void 0:Rt.deviceId)==="environment"||(Rt==null?void 0:Rt.deviceId)==="user"?W={audio:!0,video:{aspectRatio:b_/x_,facingMode:Rt==null?void 0:Rt.deviceId}}:W={audio:!0,video:{aspectRatio:b_/x_,deviceId:Rt.deviceId}},P(W),I&&(((Ke=B.current)==null?void 0:Ke.state)==="recording"&&(B.current.requestData(),B.current.stop()),I.getTracks().forEach(J=>J.stop()),M(void 0)),le(W)):console.error("Selected input device id is null")};T.useEffect(()=>{O>=a&&xe()},[O,xe]);const ut=[{type:"icon",name:"record",props:{icon:g.jsx(Zv,{color:h||m?"":"red"}),color:"danger",disabled:h||m||b,onClick:me,"aria-label":q("bbm.video.record.start")},tooltip:q("bbm.video.record.start")},{type:"icon",name:"stop",props:{icon:g.jsx(wz,{}),disabled:!h||m||b,onClick:xe,"aria-label":q("bbm.video.record.stop")},tooltip:q("bbm.video.record.stop")},{type:"icon",name:"play",visibility:v?"hide":"show",props:{icon:g.jsx($N,{}),disabled:!m||b,onClick:_e,"aria-label":q("bbm.video.play.start")},tooltip:q("bbm.video.play.start")},{type:"icon",name:"pause",visibility:v?"show":"hide",props:{icon:g.jsx(FT,{}),disabled:!m||b,onClick:_e,"aria-label":q("bbm.video.play.pause")},tooltip:q("bbm.video.play.pause")},{type:"divider"},{type:"icon",name:"reset",props:{icon:g.jsx(VN,{}),disabled:!m||b,onClick:Te,"aria-label":q("bbm.video.record.reset")},tooltip:q("bbm.video.record.reset")},{type:"icon",name:"save",visibility:s?"hide":"show",props:{icon:g.jsx(jT,{}),disabled:!m||b||w,onClick:de,"aria-label":q("bbm.video.record.save")},tooltip:q("bbm.video.record.save")}];return g.jsxs("div",{className:"video-recorder d-flex flex-fill flex-column align-items-center pb-8",children:[g.jsx("div",{className:"video-recorder-caption d-none d-md-block",children:e}),u.length>1&&g.jsx("div",{className:"video-recorder-devices mb-12",children:g.jsxs(Ot,{id:"selectInputDevice",children:[g.jsx(Gi,{className:"d-none d-md-block",children:q("bbm.video.record.select.devices.label")}),g.jsx(aA,{placeholderOption:q("bbm.video.record.select.devices.placeholder"),options:u.map(Pe=>Pe.label),onValueChange:je})]})}),g.jsxs("div",{className:"video-recorder-video-container position-relative align-self-stretch",children:[g.jsx("video",{ref:U,playsInline:!0,autoPlay:!0,controls:!1,muted:!0,onEnded:Be,className:"rounded",children:g.jsx("track",{default:!0,kind:"captions",srcLang:"fr",src:""})}),(h||m)&&g.jsxs("div",{className:"video-recorder-time d-flex align-items-center font-monospace fs-6 text-bg-dark rounded",children:[h&&g.jsxs(g.Fragment,{children:[g.jsx(Zv,{width:12,height:12,color:"red",className:"me-4"}),g.jsxs("span",{children:[pl(O),"/",pl(a)]})]}),m&&g.jsxs(g.Fragment,{children:[g.jsx(HN,{width:14,height:14,className:"me-4"}),g.jsxs("span",{children:[pl(V),"/",pl(O)]})]})]}),I&&g.jsx(pA,{items:ut,className:"position-absolute bottom-0 start-50 bg-white"})]}),b&&g.jsx(fr,{position:!1,caption:q("bbm.video.save.loader.caption")})]})}),She=_he,Ehe=()=>{const{appCode:t,setResult:e,setPreSuccess:r}=Xl(),{t:n}=we(),i=T.useRef(null),s=a=>{a?(e(a),r(()=>i.current.save)):e()},o=a=>{console.error(a)};return g.jsx(She,{ref:i,appCode:t,caption:n("bbm.video.caption"),onRecordUpdated:s,onError:o,hideSaveAction:!0})},The=({switchType:t,onSuccess:e})=>{const{t:r}=we(),[n,i]=T.useState(),[s,o]=T.useState(),[a,l]=T.useState(void 0),[u,c]=T.useState(),h=sA(n||"",300),f=T.useId(),[m]=Pn();T.useEffect(()=>{y()},[]),T.useEffect(()=>{if(u&&h){const _=Me.embedder().getProviderFromUrl(u,h);if(_){l(_);const w=Me.embedder().getEmbedCodeForProvider(_,h);o(w),e(w)}else l(void 0),e()}},[h,u]);const y=async()=>{const _=await Promise.all([Me.embedder().getDefault(),Me.embedder().getCustom()]).then(w=>w.flat());c(_)};function v(_){const w=_.currentTarget.value;i(w),e(w!=null&&w.length?w:void 0)}function x(){t==null||t("embedder")}const b=()=>h?a?g.jsxs("div",{className:"mx-auto mt-16",children:[g.jsxs("div",{className:"video-embed-provider d-flex align-items-center",children:[g.jsx(wo,{src:a.logo,alt:"Logo "+a.displayName,className:"video-embed-provider-logo"}),a.displayName]}),s&&g.jsx("div",{className:"video-embed-preview mt-12",dangerouslySetInnerHTML:{__html:s}})]}):g.jsxs("div",{className:"d-flex flex-column align-items-center m-16",children:[g.jsx(ha,{imageSrc:`${m}/emptyscreen/illu-error.svg`,title:r("bbm.video.previewError.title"),text:r("bbm.video.previewError.text")}),t&&g.jsxs(it,{variant:"ghost",color:"primary",onClick:x,className:"align-items-start mt-16",children:[r("bbm.video.useEmbedCode")," ",g.jsx(TS,{})]})]}):t&&g.jsx("div",{className:"d-flex my-16 align-items-start",children:g.jsxs(it,{variant:"ghost",color:"primary",onClick:x,className:"align-items-start",children:[r("bbm.video.useEmbedCode")," ",g.jsx(TS,{})]})});return g.jsxs("div",{className:"d-flex flex-column flex-fill video-embed",children:[g.jsxs("div",{className:"mb-8 d-flex",children:[g.jsx(LT,{className:"me-8"}),r("bbm.video.url.title")]}),g.jsx(Ot,{id:f,children:g.jsx(Kn,{size:"md",type:"text",placeholder:r("bbm.video.url.placeholder"),onChange:v})}),g.jsx(g.Fragment,{children:b()})]})},Che=The,Ahe=()=>{const{switchType:t,setResult:e}=Xl();return g.jsx(Che,{switchType:t,onSuccess:r=>{e(r)}})},Rhe=({roles:t,onSelect:e,multiple:r=!0,className:n,defaultFolder:i,showPublicFolder:s})=>{const{t:o}=we(),{root:a,loadContent:l}=O0("root",o("workspace.tree.owner"),"owner",t),{root:u,loadContent:c}=O0("root",o("workspace.tree.shared"),"shared",t),{root:h,loadContent:f}=O0("root",o("workspace.tree.protected"),"protected",t),{root:m,loadContent:y}=O0("root",o("workspace.tree.public"),"public",t),v=T.useRef(null),x=T.useRef(null),b=T.useRef(null),_=T.useRef(null),[w,E]=T.useState(()=>i==="public"?s?i:"protected":i==="protected"||i==="shared"?i:"owner"),[A,P]=T.useState(()=>i==="public"?s?m:h:i==="protected"?h:i==="shared"?u:a),[I,M]=T.useState(),[N,z]=T.useState(null),[j,H]=T.useState(["modified","desc"]),[F,L]=T.useState([]),O=T.useCallback(q=>{switch(q){case"owner":return{root:a,othersRef:[x,b,_]};case"shared":return{root:u,othersRef:[v,b,_]};case"protected":return{root:h,othersRef:[v,x,_]};case"public":return{root:m,othersRef:[v,x,b]};default:throw"no.root.node"}},[a,u,h,m]),$=T.useCallback(()=>{switch(w){case"owner":l(A.id);break;case"shared":c(A.id);break;case"protected":f(A.id);break;case"public":y(A.id);break;default:throw"no.way"}},[w,A.id,l,f,y,c]);function V(q,re){E(q);const{root:ue,othersRef:le}=O(q),me=K6(ue,xe=>xe.id===re);me&&(P(me),le.forEach(xe=>{var _e;return(_e=xe.current)==null?void 0:_e.unselectAll()}))}T.useEffect(()=>{var q;let re;switch(w){case"owner":re=v;break;case"shared":re=x;break;case"protected":re=b;break;case"public":re=_;break;default:return}(q=re==null?void 0:re.current)==null||q.select("root")},[w]),T.useEffect($,[$]),T.useEffect(()=>{if(A.files){let q=[].concat(A.files);N&&(q=q.filter(ue=>ue.name.indexOf(N)>=0));const re=j[0]==="name"?j[1]==="asc"?(ue,le)=>U(ue.name,le.name):(ue,le)=>U(le.name,ue.name):(ue,le)=>U(le.modified,ue.modified);M(()=>q.sort(re))}else M(void 0)},[A,a,h,u,m,N,j]);const k=T.useCallback(q=>{z(q.target.value)},[z]);function U(q,re){return q?re?q.localeCompare(re):1:-1}function B(){return j[0]==="name"?j[1]==="asc"?o("sort.order.alpha.asc"):o("sort.order.alpha.desc"):o("sort.order.modify.desc")}function X(q){let re=[...F];r?re.includes(q)?re=re.filter(ue=>ue._id!==q._id):re=[...re,q]:re=[q],L(re),e(re)}const K=Re("workspace flex-grow-1 gap-0",n);return g.jsxs(so,{className:K,children:[g.jsx(so.Col,{sm:"12",md:"3",xl:"4",className:"workspace-folders p-12 pt-0 gap-12",children:g.jsxs("div",{style:{position:"sticky",top:0,paddingTop:"1.2rem"},children:[g.jsx(dd,{ref:v,data:a,onTreeItemClick:q=>V("owner",q),onTreeItemUnfold:q=>V("owner",q)}),g.jsx(dd,{ref:x,data:u,onTreeItemClick:q=>V("shared",q),onTreeItemUnfold:q=>V("shared",q)}),g.jsx(dd,{ref:b,data:h,onTreeItemClick:q=>V("protected",q),onTreeItemUnfold:q=>V("protected",q)}),s&&g.jsx(dd,{ref:_,data:m,onTreeItemClick:q=>V("public",q),onTreeItemUnfold:q=>V("public",q)})]})}),g.jsx(so.Col,{sm:"12",md:"5",xl:"8",children:g.jsxs(so,{className:"flex-grow-1 gap-0",children:[g.jsxs(so.Col,{sm:"4",md:"8",xl:"12",children:[g.jsx("div",{className:"workspace-search px-16 py-8 ",children:g.jsx(s8,{isVariant:!0,className:"gap-16",onChange:k})}),g.jsxs("div",{className:"d-flex align-items-center justify-content-end px-8 py-4",children:[g.jsx("small",{className:"text-muted",children:o("workspace.search.order")}),g.jsxs(xt,{children:[g.jsx(xt.Trigger,{size:"sm",label:B(),variant:"ghost"}),g.jsxs(xt.Menu,{children:[g.jsx(xt.Item,{icon:g.jsx(Fz,{}),onClick:()=>H(["modified","desc"]),children:o("sort.order.modify.desc")}),g.jsx(xt.Item,{icon:g.jsx(Oz,{}),onClick:()=>H(["name","asc"]),children:o("sort.order.alpha.asc")}),g.jsx(xt.Item,{icon:g.jsx(Nz,{}),onClick:()=>H(["name","desc"]),children:o("sort.order.alpha.desc")})]})]})]})]}),g.jsx(so.Col,{sm:"4",md:"8",xl:"12",className:"p-8 gap-8",children:I?I.length!==0?g.jsx("div",{className:"grid grid-workspace",children:I.map(q=>{const re=F.includes(q);return g.jsx(Iue,{doc:q,isSelected:re,onClick:()=>X(q)},q._id)})}):g.jsx(ha,{imageSrc:"/assets/themes/edifice-bootstrap/images/emptyscreen/illu-trash.svg",text:o("workspace.empty.docSpace"),title:o("explorer.emptyScreen.trash.title")}):g.jsx(fr,{})})]})})]})},Phe=Rhe,Ihe=()=>{const{type:t,setResultCounter:e,setResult:r,multiple:n,visibility:i}=Xl();function s(){switch(t){case"image":return"img";case"audio":return"audio";case"video":return"video";default:return null}}function o(a){e(a.length),a.length?r(a):r()}return g.jsx(Phe,{roles:s(),onSelect:o,multiple:n,className:"border rounded overflow-y-auto",defaultFolder:i,showPublicFolder:i==="public"})},ja={Audio:fhe,Video:Ehe,Upload:whe,ExternalLink:phe,Workspace:Ihe,InternalLink:ghe,Iframe:mhe,VideoEmbedder:Ahe},Mhe=["audio-capture","video-capture","internal-link","external-link","iframe","upload","workspace","video-embedder"],w_={none:null,audio:{title:"bbm.audio.modal.title",defaultTab:"audio-capture"},video:{title:"bbm.video.modal.title",defaultTab:"video-capture"},image:{title:"bbm.image.modal.title",defaultTab:"workspace"},attachment:{title:"bbm.attachment.modal.title",defaultTab:"workspace"},hyperlink:{title:"bbm.link.modal.title",defaultTab:"linker"},embedder:{title:"bbm.embed.modal.title",defaultTab:"iframe"}},khe=T.forwardRef(({appCode:t,visibility:e,multiple:r,onSuccess:n,onCancel:i,onTabChange:s},o)=>{var a;const l=T.useRef(),u=T.useRef(null);T.useImperativeHandle(o,()=>({show:L,hide:O,showLink:$,type:m,...u.current})),qce({isDismissible:!0,duration:1/0});const{t:c}=we(),h=Wi("org.entcore.workspace.controllers.WorkspaceController|addDocument"),f=Wi("com.opendigitaleducation.video.controllers.VideoController|capture"),[m,y]=T.useState(null),v={workspace:{id:"workspace",icon:g.jsx(jN,{}),label:c("bbm.workspace"),content:g.jsx(ja.Workspace,{}),availableFor:["audio","video","image","attachment"],isEnable:null},upload:{id:"upload",icon:g.jsx(Mz,{}),label:c("bbm.device"),content:g.jsx(ja.Upload,{}),availableFor:["audio","video","image","attachment"],isEnable:()=>!!h},"video-capture":{id:"video-capture",icon:g.jsx(HN,{}),label:c("bbm.video"),content:g.jsx(ja.Video,{}),availableFor:["video"],isEnable:()=>!!f},"audio-capture":{id:"audio-capture",icon:g.jsx(c1,{}),label:c("bbm.audio"),content:g.jsx(ja.Audio,{}),availableFor:["audio"],isEnable:()=>!!h},"external-link":{id:"external-link",icon:g.jsx(LT,{}),label:c("bbm.linker.ext"),content:g.jsx(ja.ExternalLink,{...l.current}),availableFor:["hyperlink"],isEnable:null},"internal-link":{id:"internal-link",icon:g.jsx(NN,{}),label:c("bbm.linker.int"),content:g.jsx(ja.InternalLink,{...l.current}),availableFor:["hyperlink"],isEnable:null},iframe:{id:"iframe",icon:g.jsx(CS,{}),label:c("bbm.embed"),content:g.jsx(ja.Iframe,{}),availableFor:["embedder"],isEnable:null},"video-embedder":{id:"iframe",icon:g.jsx(CS,{}),label:c("bbm.embed"),content:g.jsx(ja.VideoEmbedder,{}),availableFor:["video"],isEnable:null}},x=T.useMemo(()=>Mhe.map(K=>v[K]).filter(K=>{var q;return((q=K.isEnable)==null?void 0:q.call(K))!==!1&&(K.availableFor.length===0||K.availableFor.includes(m))}),[m]),[b,_]=T.useState(),w=T.useMemo(()=>{const K=x.findIndex(q=>q.id===b);return 0>K||K>=x.length?0:K},[x,b]),[E,A]=T.useState(),[P,I]=T.useState(),[M,N]=T.useState([]),[z,j]=T.useState();function H(K){throw x.findIndex(q=>q.id===K)<0?"tab.not.visible":"not.implemented.yet"}function F(K){l.current=void 0,_(void 0),y(K)}const L=K=>{y(K)},O=()=>{y(null)},$=K=>{l.current=K,!("resourceId"in K||"appPrefix"in K)&&_("external-link"),y("hyperlink")};T.useEffect(()=>{var K,q;const re=m||"none";!b&&typeof((K=w_[re])==null?void 0:K.defaultTab)=="string"&&_((q=w_[re])==null?void 0:q.defaultTab)},[b,m]);const V=c(((a=w_[m??"none"])==null?void 0:a.title)??"bbm"),k=()=>{l.current=void 0,I(void 0),A(void 0),_(void 0),j(void 0),N([])},U=K=>{s==null||s(K,M),k()},B=T.useCallback(()=>{const K=async q=>{q instanceof Array&&["protected","public"].findIndex(re=>re===e)>=0&&(q=await Me.workspace().transferDocuments(q,t??"media-library",e)),n(q)};z?z().then(q=>{K(q)}):P&&K(P),k()},[z,P,n,e,t]),X=()=>{i(M),k()};return m&&g.jsx(v8.Provider,{value:{appCode:t,visibility:e,multiple:r,type:m,setResultCounter:A,setResult:I,setCancellable:K=>N([...K]),setVisibleTab:H,switchType:F,setPreSuccess:j},children:g.jsxs(Ye,{id:"media-library",isOpen:m!==null,onModalClose:X,size:"lg",viewport:!0,scrollable:!0,children:[g.jsx(Ye.Header,{onModalClose:X,children:V}),g.jsx(oa,{items:x,defaultId:x[w].id,onChange:U,children:K=>g.jsxs(g.Fragment,{children:[x.length>1&&g.jsx(oa.List,{className:"mt-16"}),g.jsx(Ye.Body,{className:"d-flex",children:g.jsx(oa.Panel,{currentItem:K,children:K==null?void 0:K.content})})]})}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{type:"button",color:"tertiary",variant:"ghost",onClick:X,children:c("cancel")}),g.jsx(it,{type:"button",color:"primary",variant:"filled",disabled:typeof P>"u",onClick:B,children:E&&E>1?c("addMultiple",{number:E}):c("add")})]})]})})}),y8=khe;function Ohe({isOpen:t,resourceId:e,onSuccess:r,onCancel:n}){const{appCode:i,currentApp:s}=yt(),{ref:o,libraryMedia:a,...l}=a8(),{t:u}=we(),c=mA(i,e),{control:h,cover:f,formState:{isDirty:m,isValid:y,isSubmitting:v},handleDeleteImage:x,handleSubmit:b,handleUploadImage:_,handlePublish:w,register:E,selectActivities:A,selectedActivities:P,selectedSubjectAreas:I,selectSubjects:M}=ade({resource:c,onSuccess:r});return c?mr.createPortal(g.jsxs(Ye,{isOpen:t,onModalClose:n,id:"libraryModal",size:"lg",children:[g.jsx(Ye.Header,{onModalClose:n,children:u("bpr.publish")}),g.jsx(Ye.Subtitle,{children:u("bpr.form.tip")}),g.jsxs(Ye.Body,{children:[g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:u("bpr.form.publication.heading.general")}),g.jsxs("form",{id:"libraryModalForm",onSubmit:b(w),children:[g.jsxs("div",{className:"d-block d-md-flex mb-24 gap-24",children:[g.jsxs("div",{style:{maxWidth:"160px"},children:[g.jsx("div",{className:"form-label",children:u("bpr.form.publication.cover.title")}),g.jsx(u8,{app:s,src:c==null?void 0:c.thumbnail,addButtonLabel:u("bpr.form.publication.cover.upload.add"),deleteButtonLabel:u("bpr.form.publication.cover.upload.remove"),onUploadImage:_,onDeleteImage:x,className:"align-self-center",libraryMedia:a,mediaLibraryRef:o}),!f&&g.jsx("p",{className:"form-text is-invalid",children:g.jsx("em",{children:u("bpr.form.publication.cover.upload.required.image")})})]}),g.jsxs("div",{className:"flex-fill",children:[g.jsxs(Ot,{id:"title",className:"mb-16",isRequired:!0,children:[g.jsx(Gi,{children:u("bpr.form.publication.title")}),g.jsx(Kn,{type:"text",defaultValue:c==null?void 0:c.name,...E("title",{required:!0}),placeholder:u("bpr.form.publication.title.placeholder"),size:"md","aria-required":!0})]}),g.jsxs(Ot,{id:"description",isRequired:!0,children:[g.jsx(Gi,{children:u("bpr.form.publication.description")}),g.jsx(fA,{...E("description",{required:!0}),placeholder:u("bpr.form.publication.description.placeholder"),size:"md"})]})]})]}),g.jsx("hr",{}),g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:u("bpr.form.publication.heading.infos")}),g.jsxs("div",{className:"d-flex flex-column flex-md-row gap-16 row mb-24",children:[g.jsx(Zle,{control:h,selectedActivities:P,selectActivities:A}),g.jsx(lue,{control:h,selectedSubjectAreas:I,selectSubjects:M}),g.jsx(sue,{control:h})]}),g.jsxs("div",{className:"mb-24",children:[g.jsx("label",{htmlFor:"",className:"form-label",children:u("bpr.form.publication.age")}),g.jsxs("div",{className:"d-flex gap-8",children:[g.jsx("div",{className:"col col-md-2 d-flex",children:g.jsx(Sk,{control:h,name:"ageMin",placeholderOption:"bpr.form.publication.age.min",validate:(j,H)=>parseInt(j)<=parseInt(H.ageMax)})}),g.jsx("div",{className:"col col-md-2 d-flex",children:g.jsx(Sk,{control:h,name:"ageMax",placeholderOption:"bpr.form.publication.age.max",validate:(j,H)=>parseInt(j)>=parseInt(H.ageMin)})})]})]}),g.jsx("div",{className:"mb-24",children:g.jsxs(Ot,{id:"keywords",isOptional:!0,children:[g.jsx(Gi,{children:u("bpr.form.publication.keywords")}),g.jsx(Kn,{type:"text",...E("keyWords"),size:"md",placeholder:u("bpr.form.publication.keywords.placeholder")})]})}),g.jsx("hr",{}),g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:u("bpr.form.publication.licence.text")}),g.jsx(oue,{})]})]}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{color:"tertiary",onClick:n,type:"button",variant:"ghost",children:u("cancel")}),g.jsx(it,{form:"libraryModalForm",type:"submit",color:"primary",variant:"filled",isLoading:v,disabled:!f||v||!m||!y,children:u("bpr.form.submit")})]}),g.jsx(y8,{appCode:i,ref:o,multiple:!1,visibility:"protected",...l})]}),document.getElementById("portal")):g.jsx(fr,{})}const Dhe=({content:t,maxLength:e})=>g.jsx("p",{className:"small text-gray-700 p-2 text-end",children:t?`${t.length} / ${e}`:""}),Nhe=({isUpdating:t,selectedResource:e})=>{const[r,n]=T.useState(t&&(e==null?void 0:e.thumbnail)||"");return T.useEffect(()=>{n((e==null?void 0:e.thumbnail)||"")},[e]),{thumbnail:r,handleDeleteImage:()=>n(""),handleUploadImage:i=>n(i)}},Lhe=60,Fhe=400,jhe=({isOpen:t,onCancel:e,onSuccess:r,children:n,inputMaxLength:i=Lhe,textareaMaxLength:s=Fhe,...o})=>{const{appCode:a,currentApp:l}=yt(),{t:u}=we(),{mode:c}=o,h=en(),f=T.useId(),m=c==="create",y=c==="update",v=mA(a,y?o.resourceId:""),{watch:x,register:b,handleSubmit:_,setValue:w,formState:{isSubmitting:E,isValid:A}}=OT({mode:"onChange",defaultValues:{description:y?v==null?void 0:v.description:"",enablePublic:y?v==null?void 0:v.public:!1,title:y?v==null?void 0:v.name:"",formSlug:y?v==null?void 0:v.slug:""}}),{ref:P,libraryMedia:I,...M}=a8(),{appCode:N}=yt(),{thumbnail:z,handleDeleteImage:j,handleUploadImage:H}=Nhe({isUpdating:y,selectedResource:y?v:void 0}),F=x("description"),L=async function(O){var $,V;try{const k={description:O.description||"",name:O.title,public:O.enablePublic,slug:O.enablePublic&&O.formSlug||"",thumbnail:z};if(m){const U={...k,folder:o.currentFolder===void 0||(($=o.currentFolder)==null?void 0:$.id)==="default"?void 0:parseInt(((V=o.currentFolder)==null?void 0:V.id)||""),application:a};o.createResource?await o.createResource.mutateAsync(U):await Me.resource(a).create(U)}else{const U={...k,entId:v.assetId,trashed:v.trashed};o.updateResource?await o.updateResource.mutateAsync(U):await Me.resource(a).update(U)}h.success(g.jsxs(g.Fragment,{children:[g.jsx("strong",{children:u(m?"explorer.resource.created":"explorer.resource.updated")}),g.jsxs("p",{children:[u("title")," : ",O.title]}),g.jsxs("p",{children:[u("description")," : ",O.description]}),a==="blog"&&g.jsxs("p",{children:["Public:",O.enablePublic?u("explorer.enable.public.yes"):u("explorer.enable.public.no")]})]})),r()}catch(k){console.error(k)}};return y&&!v?g.jsx(fr,{}):mr.createPortal(g.jsxs(Ye,{id:`${c}-resource`,size:"lg",isOpen:t,onModalClose:e,children:[g.jsx(Ye.Header,{onModalClose:e,children:u(`explorer.resource.editModal.header.${m?"create":"edit"}`)}),g.jsxs(Ye.Body,{children:[g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:u("explorer.resource.editModal.heading.general")}),g.jsxs("form",{id:f,onSubmit:_(L),children:[g.jsxs("div",{className:"d-block d-md-flex gap-16 mb-24",children:[g.jsx("div",{children:g.jsx(u8,{app:l,src:y&&(v==null?void 0:v.thumbnail)||"",addButtonLabel:u("explorer.imagepicker.button.add"),deleteButtonLabel:u("explorer.imagepicker.button.delete"),onUploadImage:H,onDeleteImage:j,className:"align-self-center mt-8",libraryMedia:I,mediaLibraryRef:P})}),g.jsxs("div",{className:"col",children:[g.jsxs(Ot,{id:"title",className:"mb-16",isRequired:!0,children:[g.jsx(Gi,{children:u("title")}),g.jsx(Kn,{type:"text",defaultValue:y?v==null?void 0:v.name:"",...b("title",{required:!0,maxLength:i,pattern:{value:/[^ ]/,message:"invalid title"}}),placeholder:u("explorer.resource.editModal.title.placeholder"),size:"md","aria-required":!0,maxLength:i})]}),g.jsxs(Ot,{id:"description",isOptional:!0,children:[g.jsx(Gi,{children:u("description")}),g.jsx(fA,{defaultValue:(v==null?void 0:v.description)||"",...b("description",{required:!1,maxLength:s}),placeholder:u("explorer.resource.editModal.description.placeholder"),size:"md",maxLength:s}),F&&g.jsx(Dhe,{content:F,maxLength:s})]})]})]}),typeof n=="function"?n(v,y,x,w,b):n]})]}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{color:"tertiary",onClick:e,type:"button",variant:"ghost",children:u("explorer.cancel")}),g.jsx(it,{form:f,type:"submit",color:"primary",isLoading:E,variant:"filled",disabled:!A||E,children:u(m?"explorer.create":"save")})]}),g.jsx(y8,{appCode:N,ref:P,multiple:!1,visibility:"protected",...M})]}),document.getElementById("portal"))},Bhe=jhe,Uhe=({application:t,options:e})=>Mo({mutationFn:async r=>await Me.resource(t).update(r),...e}),$he=Uhe,zhe=({watch:t,setValue:e,selectedResource:r})=>{const[n,i]=T.useState(""),[s,o]=T.useState((r==null?void 0:r.public)||!1),a=T.useId(),l=t("title"),{t:u}=we(),c=en();T.useEffect(()=>{if(s){let m="";r?m=r.slug?r.slug:`${ik({foo:`${l}${a}`})}-${ok(l)}`:m=`${ik({foo:`${l}${a}`})}-${ok(l)}`,e("formSlug",m),i(m)}},[s,l]);function h(m){o(m)}function f(m){navigator.clipboard.writeText(`${window.location.origin}${m||window.location.pathname}/pub/${n}`),c.success(u("explorer.copy.clipboard"))}return{slug:n,uniqueId:a,isPublic:s,resourceName:l,onPublicChange:h,onCopyToClipBoard:f}},Hhe=({appCode:t,isUpdating:e,resource:r,watch:n,register:i,setValue:s})=>{const{t:o}=we(),{slug:a,isPublic:l,resourceName:u,onPublicChange:c,onCopyToClipBoard:h}=zhe({watch:n,setValue:s,selectedResource:e?r:void 0});return g.jsxs(g.Fragment,{children:[g.jsxs(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:[o("explorer.resource.editModal.heading.access"),t]}),g.jsx(ta,{type:"info",children:o("explorer.resource.editModal.access.alert")}),g.jsxs(Ot,{id:"flexSwitchCheckDefault",className:"form-switch d-flex gap-8 mt-16 mb-8",children:[g.jsx(Ot.Input,{type:"checkbox",role:"switch",defaultChecked:e?r.public:!1,...i("enablePublic",{disabled:!u,onChange:f=>{const m=f.target.checked;c(m)}}),className:"form-check-input mt-0",size:"md"}),g.jsx(Ot.Label,{className:"form-check-label mb-0",children:o("explorer.resource.editModal.access.flexSwitchCheckDefault.label")})]}),l&&g.jsxs(g.Fragment,{children:[g.jsx(Ot,{id:"formSlug",children:g.jsx(Kn,{type:"text",hidden:!0,defaultValue:e?a:"",...i("formSlug"),size:"sm"})},a),g.jsxs("div",{className:"d-flex flex-wrap align-items-center gap-4",children:[g.jsxs("p",{className:"text-break",children:[window.location.origin,"/blog/pub/",a]}),g.jsx(it,{color:"primary",disabled:!l,onClick:()=>h("/blog"),type:"button",leftIcon:g.jsx($$,{}),variant:"ghost",className:"text-nowrap",children:o("explorer.resource.editModal.access.url.button")})]})]})]})},x8=Hhe,Vhe=({bookmark:t,refBookmark:e,onBookmarkChange:r,onSave:n})=>{const{t:i}=we();return g.jsx("div",{className:"mt-16",children:g.jsxs(Ot,{id:"bookmarkName",className:"d-flex flex-wrap align-items-center gap-16",children:[g.jsx("div",{className:"flex-fill",children:g.jsx(Ot.Input,{ref:e,onChange:r,placeholder:i("explorer.modal.share.sharebookmark.placeholder"),size:"sm",type:"text"},t.id)}),g.jsx(it,{type:"button",color:"primary",variant:"ghost",disabled:t.name.length===0,leftIcon:g.jsx(jT,{}),onClick:n,className:"text-nowrap",children:i("explorer.modal.share.sharebookmark.save")})]})})},Ghe=(t,e)=>t.actions.filter(r=>e.id===r.id).length>0,Whe=(t,e)=>t.isBookmarkMember&&e||!t.isBookmarkMember,Xhe=({shareRights:t,showBookmark:e,toggleBookmark:r,shareRightActions:n,toggleRight:i,onDeleteRow:s})=>{const{t:o}=we();return t==null?void 0:t.rights.map(a=>{const l={user:g.jsx(rc,{alt:o("explorer.modal.share.avatar.shared.alt"),size:"xs",src:a.avatarUrl,variant:"circle"}),group:g.jsx("div",{className:"avatar-xs bg-primary-200 justify-content-center d-flex rounded-circle",children:g.jsx(BT,{width:16})}),sharebookmark:g.jsx(DT,{})}[a.type]||null,u=a.type==="sharebookmark",c=a.type==="user";return Whe(a,e)&&g.jsxs("tr",{className:a.isBookmarkMember?"bg-light":"",children:[g.jsx("td",{children:l}),g.jsx("td",{children:g.jsxs("div",{className:"d-flex",children:[u&&g.jsx(it,{color:"tertiary",rightIcon:g.jsx(Tp,{title:o("show"),className:"w-16 min-w-0",style:{transition:"rotate 0.2s ease-out",rotate:e?"-180deg":"0deg"}}),type:"button",variant:"ghost",className:"fw-normal ps-0",onClick:r,children:a.displayName}),!u&&a.displayName,c&&` (${o(a.profile||"")})`]})}),n.map(h=>g.jsx("td",{style:{width:"80px"},className:"text-center text-white",children:g.jsx(Tm,{checked:Ghe(a,h),onChange:()=>i(a,h.id)})},h.displayName)),g.jsx("td",{children:!a.isBookmarkMember&&g.jsx(Ro,{"aria-label":o("close"),color:"tertiary",icon:g.jsx(NT,{}),type:"button",variant:"ghost",title:o("close"),onClick:()=>s(a)})})]},a.id)})},qhe={searchInputValue:"",searchResults:[],searchAPIResults:[],isSearching:!1};function Yhe(t,e){switch(e.type){case"onChange":return{...t,searchInputValue:e.payload};case"isSearching":return{...t,isSearching:e.payload};case"addResult":return{...t,searchResults:e.payload};case"addApiResult":return{...t,searchAPIResults:e.payload};case"updateSearchResult":return{...t,searchResults:e.payload};case"emptyResult":return{...t,searchResults:e.payload};default:throw new Error("Unhandled action type")}}const __=[{id:"read",displayName:"read"},{id:"comment",displayName:"comment"}],Qhe=({resourceId:t,resourceCreatorId:e,shareRights:r,shareDispatch:n})=>{const[i,s]=T.useReducer(Yhe,qhe),o=sA(i.searchInputValue,500),{isAdml:a}=o8(),{appCode:l}=yt(),{t:u}=we();T.useEffect(()=>{h(o)},[o]);const c=f=>{const m=f.target.value;s({type:"onChange",payload:m})},h=async f=>{if(t){if(s({type:"isSearching",payload:!0}),!a&&f.length>=1||a&&f.length>=3){const m=await Me.share().searchShareSubjects(l,t,f);s({type:"addApiResult",payload:m});const y=m.filter(v=>!r.rights.find(x=>x.id===v.id)).filter(v=>!(v.type==="user"&&v.id===e)).map(v=>{let x=v.displayName;return v.type==="user"&&v.profile?x=`${x} (${u(v.profile)})`:v.type==="group"&&v.structureName&&(x=`${x} (${v.structureName})`),{value:v.id,label:x,icon:v.type==="sharebookmark"?g.jsx(DT,{}):null}});s({type:"addResult",payload:y})}else s({type:"emptyResult",payload:[]}),Promise.resolve();s({type:"isSearching",payload:!1})}};return{state:i,showSearchAdmlHint:()=>a&&i.searchInputValue.length<3,showSearchLoading:()=>i.isSearching,showSearchNoResults:()=>!i.isSearching&&!a&&o.length>0&&i.searchResults.length===0||!i.isSearching&&a&&o.length>3&&i.searchResults.length===0,getSearchMinLength:()=>a?3:1,handleSearchInputChange:c,handleSearchResultsChange:async f=>{const m=i.searchAPIResults.find(y=>y.id===f[0]);if(m){let y=[];if(m.type==="sharebookmark"){const v=await Me.directory().getBookMarkById(m.id);y.push({...v,type:"sharebookmark",avatarUrl:"",directoryUrl:"",actions:__}),v==null||v.users.filter(x=>!r.rights.find(b=>b.id===x.id)).forEach(x=>{y.push({...x,type:"user",avatarUrl:"",directoryUrl:"",actions:__,isBookmarkMember:!0})}),v.groups.filter(x=>!r.rights.find(b=>b.id===x.id)).forEach(x=>{y.push({...x,type:"group",avatarUrl:"",directoryUrl:"",actions:__,isBookmarkMember:!0})})}else y=[{...m,actions:[{id:"read",displayName:"read"},{id:"comment",displayName:"comment"}]}];n({type:"updateShareRights",payload:{...r,rights:[...r.rights,...y]}}),s({type:"updateSearchResult",payload:i.searchResults.filter(v=>v.value!==f[0])})}}}},Khe={isSharing:!1,shareRights:{rights:[],visibleBookmarks:[],visibleGroups:[],visibleUsers:[]},shareRightActions:[]};function Zhe(t,e){switch(e.type){case"init":return{...t,...e.payload};case"deleteRow":return{...t,shareRights:e.payload};case"updateShareRights":return{...t,shareRights:e.payload};case"toggleRight":return{...t,shareRights:e.payload};case"isSharing":return{...t,isSharing:e.payload};default:throw new Error("Unhandled action type")}}function Jhe({resourceId:t,resourceRights:e,resourceCreatorId:r,shareResource:n,setIsLoading:i,onSuccess:s}){const{appCode:o}=yt(),{user:a,avatar:l}=wh(),u=en(),{t:c}=we(),[h,f]=T.useReducer(Zhe,Khe);T.useEffect(()=>{t&&(async()=>{try{const[v,x]=await Promise.all([Me.share().getActionsForApp(o),Me.share().getRightsForResource(o,t)]);f({type:"init",payload:{shareRightActions:v,shareRights:x}})}catch(v){console.error(v)}i(!1)})()},[t]);const m=(v,x)=>{var b,_;const{rights:w,...E}=h.shareRights,A=[...w],P=A.findIndex(M=>M.id===v.id),I=h.shareRightActions.filter(M=>M.id===x)[0];if(A[P].actions.findIndex(M=>M.id===x)>-1){let M=A[P].actions.filter(z=>z.id!==x);const N=h.shareRightActions.filter(z=>{var j;return(j=z.requires)==null?void 0:j.includes(x)});M=M.filter(z=>!N.find(j=>j.id===z.id)),A[P]={...A[P],actions:M}}else{const M=h.shareRightActions.filter(N=>{var z;return((z=I.requires)==null?void 0:z.includes(N.id))&&!A[P].actions.find(j=>j.id===N.id)});A[P]={...A[P],actions:[...A[P].actions,I,...M]}}v.type==="sharebookmark"&&((b=A[P].users)==null||b.forEach(M=>{const N=A.findIndex(z=>z.id===M.id);A[N]={...A[N],actions:A[P].actions}}),(_=A[P].groups)==null||_.forEach(M=>{const N=A.findIndex(z=>z.id===M.id);A[N]={...A[N],actions:A[P].actions}})),f({type:"toggleRight",payload:{rights:A,...E}})},y=v=>{Object.keys(v)[0]==="error"?(u.error(c("explorer.shared.status.error")),console.error("Failed to save share",v)):u.success(c("explorer.shared.status.saved"))};return{state:h,dispatch:f,currentIsAuthor:()=>r===(a==null?void 0:a.userId),myAvatar:l,handleDeleteRow:v=>{f({type:"deleteRow",payload:{...h.shareRights,rights:h.shareRights.rights.filter(x=>{var b,_;return x.id!==v.id&&!((b=v.users)!=null&&b.find(w=>w.id===x.id))&&!((_=v.groups)!=null&&_.find(w=>w.id===x.id))})}})},handleShare:async()=>{f({type:"isSharing",payload:!0});try{const v=e.filter(b=>a&&b.includes(`user:${a.userId}`)).map(b=>b.split(":")[2]).filter(b=>!!b),x=[...h.shareRights.rights];if(v.length>0){const b=v.map(_=>({displayName:_,id:_}));x.push({actions:b,avatarUrl:"",directoryUrl:"",displayName:a.username,id:a.userId,type:"user"})}if(n){const b=await n.mutateAsync({resourceId:t,rights:x});y(b)}else{const b=await Me.share().saveRights(o,t,x);y(b)}s()}catch(v){typeof v=="string"&&u.error(c("explorer.shared.status.error")),console.error("Failed to save share",v)}finally{f({type:"isSharing",payload:!1})}},toggleRight:m}}const efe=({shareRights:t,shareDispatch:e})=>{const r=en(),{t:n}=we(),i=T.useRef(null),[s,o]=T.useState({name:"",id:T.useId()}),[a,l]=Cm(!1),[u,c]=T.useState(!1),h=()=>{l()},f=()=>{o(y=>{var v;return{...y,name:((v=i.current)==null?void 0:v.value)||""}})},m=async y=>{try{const v=await Me.directory().saveBookmarks(y,{users:t.rights.filter(x=>x.type==="user").map(x=>x.id),groups:t.rights.filter(x=>x.type==="group").map(x=>x.id),bookmarks:t.rights.filter(x=>x.type==="sharebookmark").map(x=>x.id)});r.success(n("explorer.bookmarked.status.saved")),e({type:"updateShareRights",payload:{...t,visibleBookmarks:[...t.visibleBookmarks,{displayName:y,id:v.id}]}}),o(x=>({...x,bookmarkId:x.id+new Date().getTime().toString()})),c(!1)}catch(v){console.error("Failed to save bookmark",v),r.error(n("explorer.bookmarked.status.error"))}};return{refBookmark:i,showBookmark:a,showBookmarkInput:u,bookmark:s,handleBookmarkChange:f,setBookmark:o,handleOnSave:()=>{var y;const v=((y=i.current)==null?void 0:y.value)||"";m(v)},toggleBookmark:h,toggleBookmarkInput:c}};function tfe({isOpen:t,shareOptions:e,shareResource:r,children:n,onSuccess:i,onCancel:s}){const{resourceId:o,resourceCreatorId:a,resourceRights:l}=e,[u,c]=T.useState(!0),{state:{isSharing:h,shareRights:f,shareRightActions:m},dispatch:y,myAvatar:v,currentIsAuthor:x,handleShare:b,toggleRight:_,handleDeleteRow:w}=Jhe({resourceId:o,resourceCreatorId:a,resourceRights:l,shareResource:r,setIsLoading:c,onSuccess:i}),{state:{searchResults:E,searchInputValue:A},showSearchAdmlHint:P,showSearchLoading:I,showSearchNoResults:M,getSearchMinLength:N,handleSearchInputChange:z,handleSearchResultsChange:j}=Qhe({resourceId:o,resourceCreatorId:a,shareRights:f,shareDispatch:y}),{refBookmark:H,showBookmark:F,handleBookmarkChange:L,toggleBookmark:O,bookmark:$,handleOnSave:V,showBookmarkInput:k,toggleBookmarkInput:U}=efe({shareRights:f,shareDispatch:y}),{t:B}=we(),X=P()?B("explorer.search.adml.hint"):B("explorer.modal.share.search.placeholder");return mr.createPortal(g.jsxs(Ye,{id:"share_modal",size:"lg",isOpen:t,onModalClose:s,children:[g.jsx(Ye.Header,{onModalClose:s,children:B("share.title")}),g.jsxs(Ye.Body,{children:[g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:B("explorer.modal.share.usersWithAccess")}),g.jsx("div",{className:"table-responsive",children:u?g.jsx(fr,{}):g.jsxs("table",{className:"table border align-middle mb-0",children:[g.jsx("thead",{className:"bg-secondary",children:g.jsxs("tr",{children:[g.jsx("th",{scope:"col",className:"w-32",children:g.jsx(ml,{children:B("explorer.modal.share.avatar.shared.alt")})}),g.jsx("th",{scope:"col",children:g.jsx(ml,{children:B("explorer.modal.share.search.placeholder")})}),m.map(K=>g.jsx("th",{scope:"col",className:"text-center text-white",children:B(K.displayName)},K.displayName)),g.jsx("th",{scope:"col",children:g.jsx(ml,{children:B("close")})})]})}),g.jsxs("tbody",{children:[x()&&g.jsxs("tr",{children:[g.jsx("th",{scope:"row",children:g.jsx(rc,{alt:B("explorer.modal.share.avatar.me.alt"),size:"xs",src:v,variant:"circle"})}),g.jsx("td",{children:B("share.me")}),m.map(K=>g.jsx("td",{style:{width:"80px"},className:"text-center text-white",children:g.jsx(Tm,{checked:!0,disabled:!0})},K.displayName)),g.jsx("td",{})]}),g.jsx(Xhe,{showBookmark:F,shareRightActions:m,shareRights:f,onDeleteRow:w,toggleRight:_,toggleBookmark:O})]})]})}),g.jsxs("div",{className:"mt-16",children:[g.jsx(it,{color:"tertiary",leftIcon:g.jsx(DT,{}),rightIcon:g.jsx(Tp,{title:B("show"),className:"w-16 min-w-0",style:{transition:"rotate 0.2s ease-out",rotate:k?"-180deg":"0deg"}}),type:"button",variant:"ghost",className:"fw-normal",onClick:()=>U(!k),children:B("share.save.sharebookmark")}),k&&g.jsx(Vhe,{refBookmark:H,bookmark:$,onBookmarkChange:L,onSave:V})]}),g.jsx("hr",{}),g.jsxs(Ss,{headingStyle:"h4",level:"h3",className:"mb-16 d-flex align-items-center",children:[g.jsx("div",{className:"me-8",children:B("explorer.modal.share.search")}),g.jsx(fo,{message:"Vos favoris de partage s’affichent en priorité dans votre liste lorsque vous recherchez un groupe ou une personne, vous pouvez les retrouver dans l’annuaire.",placement:"top",children:g.jsx(BN,{className:"c-pointer",height:"18"})})]}),g.jsx("div",{className:"row",children:g.jsx("div",{className:"col-10",children:g.jsx(Tce,{value:A,placeholder:X,isLoading:I(),noResult:M(),options:E,searchMinLength:N(),onSearchInputChange:z,onSearchResultsChange:j})})}),n]}),g.jsxs(Ye.Footer,{children:[g.jsx(it,{type:"button",color:"tertiary",variant:"ghost",onClick:s,children:B("explorer.cancel")}),g.jsx(it,{type:"button",color:"primary",variant:"filled",isLoading:h,onClick:b,disabled:h,children:B("share")})]})]}),document.getElementById("portal"))}function rfe({resourceId:t,updateResource:e}){const{appCode:r}=yt(),{t:n}=we(r),i=mA("blog",t),s=i&&i["publish-type"],[o,a]=T.useState(s??"RESTRAINT");T.useEffect(()=>{s&&a(s)},[s]);const l=async u=>{const c=u.target.value,h={description:i.description||"",entId:i.assetId,name:i.name,public:!!i.public,slug:i.slug||"",thumbnail:i.thumbnail,trashed:i.trashed,"publish-type":c};e?await e.mutateAsync(h):await Me.resource("blog").update(h),a(c)};return g.jsxs(g.Fragment,{children:[g.jsx("hr",{}),g.jsx(Ss,{headingStyle:"h4",level:"h3",className:"mb-16",children:n("explorer.publication.steps")}),g.jsx(E2,{label:n("explorer.immediat.publication"),id:"publication-now",name:"publication",value:"IMMEDIATE",model:o,checked:o==="IMMEDIATE",onChange:l}),g.jsx(E2,{label:n("explorer.validate.publication"),id:"publication-validate",name:"publication",value:"RESTRAINT",checked:o==="RESTRAINT",model:o,onChange:l})]})}const nfe=({application:t,options:e})=>Mo({mutationFn:async({resourceId:r,rights:n})=>await Me.share().saveRights(t,r,n),...e}),ife=nfe;function sfe(t){return{getPreference:async()=>await Me.conf().getPreference(t),savePreference:async e=>await Me.conf().savePreference(t,JSON.stringify(e))}}function ofe(){const[t,e]=T.useState(!1),{getPreference:r,savePreference:n}=sfe("rgpdCookies");return T.useEffect(()=>{(async()=>{const i=await r();e(i===null?!0:i.showInfoTip)})()},[]),{showCookiesConsent:t,handleConsultCookies:()=>{document.location.href="/userbook/mon-compte",n({showInfoTip:!1}),e(!1)},handleCloseCookiesConsent:()=>{n({showInfoTip:!1}),e(!1)}}}function Rk({isHelpOpen:t,setIsHelpOpen:e,parsedHeadline:r,parsedContent:n,error:i}){const{t:s}=we(),o=()=>{e(!1)};return t?mr.createPortal(g.jsxs(Ye,{id:"help-modal",isOpen:t,onModalClose:o,scrollable:!0,size:"lg",children:[g.jsx(Ye.Header,{onModalClose:o,children:s("navbar.help")}),g.jsx(Ye.Subtitle,{children:i?s("help.notfound.title"):r}),g.jsx(Ye.Body,{className:i?"d-flex":null,children:i?s("help.notfound.text"):n})]}),document.getElementById("portal")):null}function afe(){var t,e,r,n,i;const{appCode:s}=yt(),{theme:o}=ba(),[a,l]=T.useState(""),[u,c]=T.useState(!0),[h,f]=T.useState(!1),[m,y]=T.useState(!1),v=o!=null&&o.is1d?"/help-1d":"/help-2d";T.useEffect(()=>{(async()=>{let w="";w=v+"/application/"+s+"/",!s&&window.location.pathname!=="/adapter"?w=v+"/application/portal/":window.location.pathname==="/adapter"?w=v+"/application/"+window.location.search.split("eliot=")[1].split("&")[0]+"/":window.location.pathname.includes("/directory/class-admin")?w=v+"/application/parametrage-de-la-classe/":(window.location.pathname.includes("/userbook/mon-compte")||window.location.pathname.includes("/timeline/preferencesView")||window.location.pathname.includes("/timeline/historyView"))&&(w=v+"/application/userbook/");try{const E=await fetch(w),A=await E.text();if(E.status===404){y(!0);return}l(A),y(!1)}catch(E){y(!0),console.error(E)}})()},[s,v]);const x=Wl(a,{replace:w=>{const E=w;if(E.attribs&&E.attribs.id==="TOC")return g.jsxs("nav",{id:"TOC",children:[g.jsx(it,{onClick:()=>{c(!u)},children:g.jsx(F$,{})}),I0(E.children,{replace:A=>{const P=A;if(P.attribs&&P.name==="ul")return g.jsx("ul",{id:"TOC-list",style:{display:u?"block":"none"},children:I0(P.children,{replace:I=>{const M=I;if(M.attribs&&M.name==="a")return g.jsx("a",{...v_(M.attribs),children:g.jsx("span",{onClick:()=>{c(!1)},children:I0(M.children)})})}})})}})]});if(E.attribs&&E.attribs.class==="section level2"){const A=v_(w.attribs);return g.jsx("div",{...A,className:"section level2",style:{display:E.attribs.id!=="présentation"?"none":"block"},children:I0(E.children,{replace:P=>{const I=P;if(I.attribs&&I.name==="img"){const M=P.attribs.src;return g.jsx("img",{...v_(I.attribs),src:`${v}/${M}`,alt:""})}}})})}}}),b=(r=(e=(t=x==null?void 0:x.props)==null?void 0:t.children.find(w=>w.type==="body"))==null?void 0:e.props)==null?void 0:r.children,_=(i=(n=b==null?void 0:b.find(w=>w.type==="p"))==null?void 0:n.props)==null?void 0:i.children;return{html:a,visibility:u,isModalOpen:h,setIsModalOpen:f,parsedContent:b,parsedHeadline:_,error:m}}const vr=T.forwardRef(({children:t,className:e,...r},n)=>{const i=Re("nav-item",e);return g.jsx("li",{ref:n,className:i,...r,children:t})}),lfe=()=>{const[t,e]=$6(),r=T.useRef(null),n=T.useId(),{t:i}=we();function s(){if(r.current){const o=r.current.value;window.location.href=`/searchengine#/${o}`}}return g.jsxs(vr,{id:n,ref:t,className:"position-relative","aria-haspopup":"true","aria-expanded":e,children:[g.jsxs("a",{href:"/searchengine",className:"nav-link dropdown-item",children:[g.jsx(jq,{className:"icon search"}),g.jsx("span",{className:"nav-text",children:i("navbar.search")})]}),g.jsx(i8,{id:n,isVisible:e,className:"d-none d-md-flex",children:g.jsxs(Ot,{id:"my-search-input",className:"search-text input-group py-8 px-12",children:[g.jsx(Ot.Input,{ref:r,size:"sm",type:"text",name:"my-search-input",placeholder:"Rechercher"}),g.jsx(oA,{type:"submit",size:"sm",onClick:s,"aria-label":i("navbar.search")})]})})]})},ufe=lfe;function S_({children:t,className:e,...r}){const n=Re("navbar",e);return g.jsx("nav",{className:n,...r,children:t})}function Pk({children:t,className:e,...r}){const n=Re("navbar-nav",e);return g.jsx("ul",{className:n,...r,children:t})}function mf({link:t,className:e,children:r,translate:n,...i}){const s=Re("nav-link",e);return g.jsxs("a",{href:t,className:s,...i,children:[r,n&&g.jsx(ml,{children:g.jsx("span",{className:"nav-text",children:n})})]})}const cfe=()=>{const{t}=we();return g.jsx("div",{className:"widget-footer",children:g.jsx("div",{className:"widget-footer-action",children:g.jsx("a",{href:"/welcome",className:"link",children:t("plus")})})})},dfe=({bookmarkedApps:t})=>{const{t:e}=we();return g.jsxs("div",{className:"widget-body d-flex flex-wrap",children:[!t.length&&g.jsx("div",{className:"text-dark",children:e("navbar.myapps.more")}),t.slice(0,6).map((r,n)=>g.jsx("a",{href:r.address,className:"bookmarked-app",children:g.jsx(ya,{app:r,size:"32"})},n))]})},hfe=({is1d:t=!1,src:e=""})=>{const{t:r}=we(),{messages:n,msgLink:i,zimbraWorkflow:s}=Gce(),{user:o,avatar:a}=wh(),{currentLanguage:l,currentApp:u}=yt(),c=Wi("org.entcore.portal.controllers.PortalController|oldHelpEnable")||!1,{isModalOpen:h,setIsModalOpen:f,parsedContent:m,parsedHeadline:y,error:v}=afe(),x=Re("header",{"no-2d":t,"no-1d":!t}),{title:b,bookmarkedApps:_,appsRef:w,isAppsHovered:E,popoverAppsId:A,userAvatar:P,userName:I,welcomeUser:M,communityWorkflow:N,conversationWorflow:z,searchWorkflow:j,isCollapsed:H,toggleCollapsedNav:F,handleLogout:L}=Wce({user:o,avatar:a}),O=n>0,{theme:$}=ba();return g.jsx("header",{className:x,children:t?g.jsxs(g.Fragment,{children:[g.jsx("div",{className:"container-fluid",children:g.jsxs(S_,{children:[g.jsx("a",{className:"navbar-title d-md-none text-truncate h4",href:u?u.address:"/timeline/timeline",children:b}),g.jsxs("div",{className:"d-none d-md-inline-flex gap-12 align-items-center",children:[g.jsx(rc,{alt:I,size:"sm",src:P,variant:"circle",width:"32",height:"32"}),g.jsx("span",{className:"navbar-text",children:M})]}),g.jsxs(Pk,{className:"gap-8","aria-hidden":"false","aria-label":r("navbar.main.navigation"),children:[z&&g.jsx(vr,{children:g.jsxs("a",{href:"/conversation/conversation",className:"nav-link",children:[g.jsx(Nq,{className:"icon notification"}),O&&g.jsx(ow,{variant:{type:"notification",level:"danger"},className:"position-absolute",children:n}),g.jsx(ml,{children:r("navbar.messages")})]})}),g.jsx(vr,{children:g.jsx(mf,{link:"/userbook/mon-compte",className:"dropdown-item",translate:r("navbar.myaccount"),children:g.jsx(bC,{className:"icon user"})})}),l==="fr"&&c?g.jsxs(vr,{children:[g.jsxs("button",{className:"nav-link",onClick:()=>{f(!0)},children:[g.jsx(Oq,{className:"icon help"}),g.jsx(ml,{children:r("navbar.help")})]}),g.jsx(Rk,{isHelpOpen:h,setIsHelpOpen:f,parsedContent:m,parsedHeadline:y,error:v})]}):null,g.jsx(vr,{children:g.jsxs("button",{className:"nav-link",onClick:L,children:[g.jsx(F3,{className:"icon logout"}),g.jsx(ml,{children:r("navbar.disconnect")})]})}),g.jsx(vr,{className:"d-md-none",children:g.jsx("button",{className:"nav-link btn btn-naked",type:"button","aria-controls":"navbarCollapsed","aria-expanded":!H,"aria-label":r("navbar.secondary.navigation"),onClick:F,children:g.jsx(Tp,{className:"icon rafter-down",width:"20",height:"20"})})})]})]})}),g.jsx(S_,{className:"no-2d navbar-secondary navbar-expand-md","aria-label":r("navbar.secondary.navigation"),children:g.jsx("div",{className:"container-fluid",children:g.jsxs("div",{className:`collapse navbar-collapse ${H?"":"show"}`,id:"navbarCollapsed",children:[g.jsx(Ck,{is1d:!0,src:`${e}/img/illustrations/logo.png`,translate:r("navbar.home")}),g.jsxs(Pk,{className:"gap-8",children:[g.jsx(vr,{children:g.jsxs("a",{href:"/timeline/timeline",className:"button",children:[g.jsx(Mq,{color:"#fff",className:"d-md-none"}),g.jsx("span",{className:"d-inline-block",children:r("portal.header.navigation.whatsnew")})]})}),g.jsx(vr,{children:g.jsxs("a",{href:"/userbook/annuaire",className:"button",children:[g.jsx(Uq,{color:"#fff",className:"d-md-none"}),g.jsx("span",{className:"d-inline-block",children:r("portal.header.navigation.classMembers")})]})}),g.jsx(vr,{children:g.jsxs("a",{href:"/welcome",className:"button",children:[g.jsx(j3,{color:"#fff",className:"d-md-none"}),g.jsx("span",{className:"d-inline-block",children:r("portal.header.navigation.myapps")})]})})]})]})})})]}):g.jsx(S_,{className:"navbar-expand-md",children:g.jsxs("div",{className:"container-fluid",children:[g.jsx(Ck,{src:`${e}/img/illustrations/logo.png`}),g.jsx("a",{href:u?u.address:"/timeline/timeline",className:"navbar-title text-truncate d-md-none",children:b}),g.jsxs("ul",{className:"navbar-nav",children:[g.jsx(vr,{children:g.jsx(mf,{link:"/timeline/timeline",translate:r("navbar.home"),children:g.jsx(Tq,{color:"#fff"})})}),g.jsxs(vr,{className:"position-relative",ref:w,id:A,"aria-haspopup":"true","aria-expanded":E,children:[g.jsx(mf,{link:"/welcome",translate:r("navbar.applications"),children:g.jsx(j3,{color:"#fff"})}),g.jsxs(i8,{className:"top-100 widget",id:A,isVisible:E,children:[g.jsx(Lce,{children:g.jsx(dfe,{bookmarkedApps:_})}),g.jsx(Fce,{className:"widget-footer border-top border-ghost",children:g.jsx(cfe,{})})]})]}),z&&g.jsx(vr,{children:g.jsxs(mf,{className:"position-relative",link:"/conversation/conversation",translate:r("conversation"),children:[g.jsx(B3,{color:"#fff"}),O&&g.jsx(ow,{variant:{type:"notification",level:"warning"},className:"position-absolute",children:n})]})}),s&&g.jsx(vr,{children:g.jsxs(mf,{className:"position-relative",link:i,translate:r("conversation"),children:[g.jsx(B3,{color:"#fff"}),O&&g.jsx(ow,{variant:{type:"notification",level:"warning"},className:"position-absolute",children:n})]})}),l==="fr"&&c?g.jsxs(vr,{children:[g.jsxs("button",{className:"nav-link btn btn-naked",onClick:()=>{f(!0)},children:[g.jsx(Rq,{color:"#fff"}),g.jsx(ml,{children:r("support")})]}),g.jsx(Rk,{isHelpOpen:h,setIsHelpOpen:f,parsedContent:m,parsedHeadline:y,error:v})]}):null,g.jsx(vr,{children:g.jsxs("div",{className:"dropdown",children:[g.jsx("button",{className:"nav-link btn btn-naked d-md-none",type:"button","aria-controls":"dropdown-navbar","aria-expanded":!H,"aria-label":r("navbar.open.menu"),onClick:F,children:g.jsx(Tp,{className:"icon rafter-down",width:"20",height:"20",color:"#fff"})}),g.jsxs("ul",{className:`dropdown-menu dropdown-menu-end ${H?"":"show"}`,id:"dropdown-navbar",children:[N&&g.jsx(vr,{children:g.jsxs("a",{href:"/community",className:"nav-link dropdown-item",children:[g.jsx(_q,{className:"icon community"}),g.jsx("span",{className:"nav-text",children:r("navbar.community")})]})}),j?g.jsx(ufe,{}):null,g.jsx(vr,{children:g.jsxs("a",{href:"/userbook/mon-compte",className:"nav-link dropdown-item",children:[g.jsx(rc,{alt:I,size:"sm",src:P,variant:"circle",className:"bg-white",width:"32",height:"32"}),g.jsx("span",{className:"nav-text",children:r("navbar.myaccount")})]})}),g.jsx(vr,{children:g.jsx("hr",{className:"dropdown-divider"})}),g.jsx(vr,{children:g.jsxs("a",{href:"/auth/logout?callback="+(($==null?void 0:$.logoutCallback)??"/"),className:"nav-link dropdown-item",children:[g.jsx(F3,{className:"icon logout"}),g.jsx("span",{id:"logout-label",className:"nav-text",children:r("navbar.disconnect")})]})})]})]})})]})]})})})},ffe=hfe,pfe=({children:t,headless:e=!1,...r})=>{const{theme:n}=ba(),{t:i}=we(),{showCookiesConsent:s,handleConsultCookies:o,handleCloseCookiesConsent:a}=ofe();ide(),sde();const l=Re("d-flex flex-column bg-white",{"container-fluid":!e,"rounded-4 border":(n==null?void 0:n.is1d)&&!e,"mt-24":(n==null?void 0:n.is1d)&&!e}),u=e?null:g.jsx(ffe,{is1d:n==null?void 0:n.is1d,src:n==null?void 0:n.basePath}),c=s&&g.jsx(ta,{type:"info",className:"m-12 rgpd",isConfirm:!0,position:"bottom-right",button:g.jsx(it,{color:"tertiary",variant:"ghost",onClick:o,children:i("rgpd.cookies.banner.button.consult")}),onClose:a,children:i("rgpd.cookies.banner.text1")}),h=g.jsx($G,{containerClassName:"toaster-container",toastOptions:{position:"top-right"}});return g.jsxs(g.Fragment,{children:[u,g.jsx("main",{className:l,...r,children:t}),h,c]})},mfe=pfe,gfe="modulepreload",vfe=function(t){return"/"+t},Ik={},cr=function(e,r,n){let i=Promise.resolve();if(r&&r.length>0){document.getElementsByTagName("link");const s=document.querySelector("meta[property=csp-nonce]"),o=(s==null?void 0:s.nonce)||(s==null?void 0:s.getAttribute("nonce"));i=Promise.all(r.map(a=>{if(a=vfe(a),a in Ik)return;Ik[a]=!0;const l=a.endsWith(".css"),u=l?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${a}"]${u}`))return;const c=document.createElement("link");if(c.rel=l?"stylesheet":gfe,l||(c.as="script",c.crossOrigin=""),c.href=a,o&&c.setAttribute("nonce",o),document.head.appendChild(c),l)return new Promise((h,f)=>{c.addEventListener("load",h),c.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${a}`)))})}))}return i.then(()=>e()).catch(s=>{const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=s,window.dispatchEvent(o),!o.defaultPrevented)throw s})},yfe=t=>{let{activatorEvent:e,draggingNodeRect:r,transform:n}=t;if(r&&e){const i=Fy(e);if(!i)return n;const s=i.x-r.left,o=i.y-r.top;return{...n,x:n.x+s-r.width/2,y:n.y+o-r.height/2}}return n},xfe={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},bfe=t=>{let e;const r=new Set,n=(c,h)=>{const f=typeof c=="function"?c(e):c;if(!Object.is(f,e)){const m=e;e=h??(typeof f!="object"||f===null)?f:Object.assign({},e,f),r.forEach(y=>y(e,m))}},i=()=>e,l={setState:n,getState:i,getInitialState:()=>u,subscribe:c=>(r.add(c),()=>r.delete(c)),destroy:()=>{(xfe?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),r.clear()}},u=e=t(n,i,l);return l},wfe=t=>bfe;var b8={exports:{}},w8={},_8={exports:{}},S8={};/**
|
|
1391
1391
|
* @license React
|
|
1392
1392
|
* use-sync-external-store-shim.production.min.js
|
|
1393
1393
|
*
|