draftify-react 0.2.4 → 0.2.6

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.
@@ -1,9 +1,9 @@
1
- (function(Ae,z){typeof exports=="object"&&typeof module<"u"?z(exports,require("react"),require("draftify")):typeof define=="function"&&define.amd?define(["exports","react","draftify"],z):(Ae=typeof globalThis<"u"?globalThis:Ae||self,z(Ae.DraftifyReact={},Ae.React,Ae.Draftify))})(this,(function(Ae,z,te){"use strict";function Mc(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Tn=Mc(z),je={container:"_container_1mz3p_3",mediaWrapper:"_mediaWrapper_1mz3p_19",mediaItem:"_mediaItem_1mz3p_37",footerOverlay:"_footerOverlay_1mz3p_49",refreshButton:"_refreshButton_1mz3p_69",dropzone:"_dropzone_1mz3p_95",uploadLabel:"_uploadLabel_1mz3p_111",uploadIconCircle:"_uploadIconCircle_1mz3p_135",donutContainer:"_donutContainer_1mz3p_159",donutOuter:"_donutOuter_1mz3p_175",donutInner:"_donutInner_1mz3p_191"},Pn={optionsContainer:"_optionsContainer_114lu_1",optionButton:"_optionButton_114lu_27",iconWrapper:"_iconWrapper_114lu_65",subscript:"_subscript_114lu_75"};var Cn={exports:{}},Xt={};var ms;function Dc(){if(ms)return Xt;ms=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,i,s){var a=null;if(s!==void 0&&(a=""+s),i.key!==void 0&&(a=""+i.key),"key"in i){s={};for(var o in i)o!=="key"&&(s[o]=i[o])}else s=i;return i=s.ref,{$$typeof:e,type:r,key:a,ref:i!==void 0?i:null,props:s}}return Xt.Fragment=t,Xt.jsx=n,Xt.jsxs=n,Xt}var qt={};var ps;function jc(){return ps||(ps=1,process.env.NODE_ENV!=="production"&&(function(){function e(F){if(F==null)return null;if(typeof F=="function")return F.$$typeof===k?null:F.displayName||F.name||null;if(typeof F=="string")return F;switch(F){case w:return"Fragment";case I:return"Profiler";case v:return"StrictMode";case A:return"Suspense";case O:return"SuspenseList";case T:return"Activity"}if(typeof F=="object")switch(typeof F.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),F.$$typeof){case b:return"Portal";case E:return F.displayName||"Context";case S:return(F._context.displayName||"Context")+".Consumer";case P:var N=F.render;return F=F.displayName,F||(F=N.displayName||N.name||"",F=F!==""?"ForwardRef("+F+")":"ForwardRef"),F;case p:return N=F.displayName||null,N!==null?N:e(F.type)||"Memo";case y:N=F._payload,F=F._init;try{return e(F(N))}catch{}}return null}function t(F){return""+F}function n(F){try{t(F);var N=!1}catch{N=!0}if(N){N=console;var W=N.error,B=typeof Symbol=="function"&&Symbol.toStringTag&&F[Symbol.toStringTag]||F.constructor.name||"Object";return W.call(N,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",B),t(F)}}function r(F){if(F===w)return"<>";if(typeof F=="object"&&F!==null&&F.$$typeof===y)return"<...>";try{var N=e(F);return N?"<"+N+">":"<...>"}catch{return"<...>"}}function i(){var F=M.A;return F===null?null:F.getOwner()}function s(){return Error("react-stack-top-frame")}function a(F){if(j.call(F,"key")){var N=Object.getOwnPropertyDescriptor(F,"key").get;if(N&&N.isReactWarning)return!1}return F.key!==void 0}function o(F,N){function W(){x||(x=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",N))}W.isReactWarning=!0,Object.defineProperty(F,"key",{get:W,configurable:!0})}function u(){var F=e(this.type);return g[F]||(g[F]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),F=this.props.ref,F!==void 0?F:null}function d(F,N,W,B,V,X){var Z=W.ref;return F={$$typeof:m,type:F,key:N,props:W,_owner:B},(Z!==void 0?Z:null)!==null?Object.defineProperty(F,"ref",{enumerable:!1,get:u}):Object.defineProperty(F,"ref",{enumerable:!1,value:null}),F._store={},Object.defineProperty(F._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(F,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(F,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:V}),Object.defineProperty(F,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:X}),Object.freeze&&(Object.freeze(F.props),Object.freeze(F)),F}function l(F,N,W,B,V,X){var Z=N.children;if(Z!==void 0)if(B)if(C(Z)){for(B=0;B<Z.length;B++)c(Z[B]);Object.freeze&&Object.freeze(Z)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else c(Z);if(j.call(N,"key")){Z=e(F);var ee=Object.keys(N).filter(function(G){return G!=="key"});B=0<ee.length?"{key: someKey, "+ee.join(": ..., ")+": ...}":"{key: someKey}",U[Z+B]||(ee=0<ee.length?"{"+ee.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
1
+ (function(Se,z){typeof exports=="object"&&typeof module<"u"?z(exports,require("react"),require("draftify")):typeof define=="function"&&define.amd?define(["exports","react","draftify"],z):(Se=typeof globalThis<"u"?globalThis:Se||self,z(Se.DraftifyReact={},Se.React,Se.Draftify))})(this,(function(Se,z,re){"use strict";function Mc(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Tn=Mc(z),je={container:"_container_1mz3p_3",mediaWrapper:"_mediaWrapper_1mz3p_19",mediaItem:"_mediaItem_1mz3p_37",footerOverlay:"_footerOverlay_1mz3p_49",refreshButton:"_refreshButton_1mz3p_69",dropzone:"_dropzone_1mz3p_95",uploadLabel:"_uploadLabel_1mz3p_111",uploadIconCircle:"_uploadIconCircle_1mz3p_135",donutContainer:"_donutContainer_1mz3p_159",donutOuter:"_donutOuter_1mz3p_175",donutInner:"_donutInner_1mz3p_191"},Pn={optionsContainer:"_optionsContainer_114lu_1",optionButton:"_optionButton_114lu_27",iconWrapper:"_iconWrapper_114lu_65",subscript:"_subscript_114lu_75"};var Cn={exports:{}},Xt={};var ms;function Dc(){if(ms)return Xt;ms=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,i,s){var a=null;if(s!==void 0&&(a=""+s),i.key!==void 0&&(a=""+i.key),"key"in i){s={};for(var o in i)o!=="key"&&(s[o]=i[o])}else s=i;return i=s.ref,{$$typeof:e,type:r,key:a,ref:i!==void 0?i:null,props:s}}return Xt.Fragment=t,Xt.jsx=n,Xt.jsxs=n,Xt}var qt={};var ps;function jc(){return ps||(ps=1,process.env.NODE_ENV!=="production"&&(function(){function e(F){if(F==null)return null;if(typeof F=="function")return F.$$typeof===k?null:F.displayName||F.name||null;if(typeof F=="string")return F;switch(F){case w:return"Fragment";case I:return"Profiler";case v:return"StrictMode";case A:return"Suspense";case O:return"SuspenseList";case T:return"Activity"}if(typeof F=="object")switch(typeof F.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),F.$$typeof){case b:return"Portal";case E:return F.displayName||"Context";case S:return(F._context.displayName||"Context")+".Consumer";case P:var N=F.render;return F=F.displayName,F||(F=N.displayName||N.name||"",F=F!==""?"ForwardRef("+F+")":"ForwardRef"),F;case p:return N=F.displayName||null,N!==null?N:e(F.type)||"Memo";case y:N=F._payload,F=F._init;try{return e(F(N))}catch{}}return null}function t(F){return""+F}function n(F){try{t(F);var N=!1}catch{N=!0}if(N){N=console;var W=N.error,B=typeof Symbol=="function"&&Symbol.toStringTag&&F[Symbol.toStringTag]||F.constructor.name||"Object";return W.call(N,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",B),t(F)}}function r(F){if(F===w)return"<>";if(typeof F=="object"&&F!==null&&F.$$typeof===y)return"<...>";try{var N=e(F);return N?"<"+N+">":"<...>"}catch{return"<...>"}}function i(){var F=M.A;return F===null?null:F.getOwner()}function s(){return Error("react-stack-top-frame")}function a(F){if(j.call(F,"key")){var N=Object.getOwnPropertyDescriptor(F,"key").get;if(N&&N.isReactWarning)return!1}return F.key!==void 0}function o(F,N){function W(){x||(x=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",N))}W.isReactWarning=!0,Object.defineProperty(F,"key",{get:W,configurable:!0})}function u(){var F=e(this.type);return g[F]||(g[F]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),F=this.props.ref,F!==void 0?F:null}function d(F,N,W,B,V,X){var Q=W.ref;return F={$$typeof:m,type:F,key:N,props:W,_owner:B},(Q!==void 0?Q:null)!==null?Object.defineProperty(F,"ref",{enumerable:!1,get:u}):Object.defineProperty(F,"ref",{enumerable:!1,value:null}),F._store={},Object.defineProperty(F._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(F,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(F,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:V}),Object.defineProperty(F,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:X}),Object.freeze&&(Object.freeze(F.props),Object.freeze(F)),F}function l(F,N,W,B,V,X){var Q=N.children;if(Q!==void 0)if(B)if(C(Q)){for(B=0;B<Q.length;B++)c(Q[B]);Object.freeze&&Object.freeze(Q)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else c(Q);if(j.call(N,"key")){Q=e(F);var J=Object.keys(N).filter(function(Y){return Y!=="key"});B=0<J.length?"{key: someKey, "+J.join(": ..., ")+": ...}":"{key: someKey}",U[Q+B]||(J=0<J.length?"{"+J.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
2
2
  let props = %s;
3
3
  <%s {...props} />
4
4
  React keys must be passed directly to JSX without using spread:
5
5
  let props = %s;
6
- <%s key={someKey} {...props} />`,B,Z,ee,Z),U[Z+B]=!0)}if(Z=null,W!==void 0&&(n(W),Z=""+W),a(N)&&(n(N.key),Z=""+N.key),"key"in N){W={};for(var H in N)H!=="key"&&(W[H]=N[H])}else W=N;return Z&&o(W,typeof F=="function"?F.displayName||F.name||"Unknown":F),d(F,Z,W,i(),V,X)}function c(F){f(F)?F._store&&(F._store.validated=1):typeof F=="object"&&F!==null&&F.$$typeof===y&&(F._payload.status==="fulfilled"?f(F._payload.value)&&F._payload.value._store&&(F._payload.value._store.validated=1):F._store&&(F._store.validated=1))}function f(F){return typeof F=="object"&&F!==null&&F.$$typeof===m}var h=z,m=Symbol.for("react.transitional.element"),b=Symbol.for("react.portal"),w=Symbol.for("react.fragment"),v=Symbol.for("react.strict_mode"),I=Symbol.for("react.profiler"),S=Symbol.for("react.consumer"),E=Symbol.for("react.context"),P=Symbol.for("react.forward_ref"),A=Symbol.for("react.suspense"),O=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),T=Symbol.for("react.activity"),k=Symbol.for("react.client.reference"),M=h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,j=Object.prototype.hasOwnProperty,C=Array.isArray,R=console.createTask?console.createTask:function(){return null};h={react_stack_bottom_frame:function(F){return F()}};var x,g={},_=h.react_stack_bottom_frame.bind(h,s)(),L=R(r(s)),U={};qt.Fragment=w,qt.jsx=function(F,N,W){var B=1e4>M.recentlyCreatedOwnerStacks++;return l(F,N,W,!1,B?Error("react-stack-top-frame"):_,B?R(r(F)):L)},qt.jsxs=function(F,N,W){var B=1e4>M.recentlyCreatedOwnerStacks++;return l(F,N,W,!0,B?Error("react-stack-top-frame"):_,B?R(r(F)):L)}})()),qt}var gs;function Fc(){return gs||(gs=1,process.env.NODE_ENV==="production"?Cn.exports=Dc():Cn.exports=jc()),Cn.exports}var D=Fc();const fr=z.createContext({});function dr(e){const t=z.useRef(null);return t.current===null&&(t.current=e()),t.current}const hr=typeof window<"u",ys=hr?z.useLayoutEffect:z.useEffect,En=z.createContext(null);function mr(e,t){e.indexOf(t)===-1&&e.push(t)}function pr(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Xe=(e,t,n)=>n>t?t:n<e?e:n;function gr(e,t){return t?`${e}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${t}`:e}let It=()=>{},qe=()=>{};process.env.NODE_ENV!=="production"&&(It=(e,t,n)=>{!e&&typeof console<"u"&&console.warn(gr(t,n))},qe=(e,t,n)=>{if(!e)throw new Error(gr(t,n))});const Qe={},vs=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function bs(e){return typeof e=="object"&&e!==null}const xs=e=>/^0[^.\s]+$/u.test(e);function yr(e){let t;return()=>(t===void 0&&(t=e()),t)}const Fe=e=>e,Lc=(e,t)=>n=>t(e(n)),Qt=(...e)=>e.reduce(Lc),Zt=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class vr{constructor(){this.subscriptions=[]}add(t){return mr(this.subscriptions,t),()=>pr(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let s=0;s<i;s++){const a=this.subscriptions[s];a&&a(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const _e=e=>e*1e3,Le=e=>e/1e3;function ws(e,t){return t?e*(1e3/t):0}const As=new Set;function br(e,t,n){e||As.has(t)||(console.warn(gr(t,n)),As.add(t))}const Ss=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Oc=1e-7,Rc=12;function _c(e,t,n,r,i){let s,a,o=0;do a=t+(n-t)/2,s=Ss(a,r,i)-e,s>0?n=a:t=a;while(Math.abs(s)>Oc&&++o<Rc);return a}function Jt(e,t,n,r){if(e===t&&n===r)return Fe;const i=s=>_c(s,0,1,e,n);return s=>s===0||s===1?s:Ss(i(s),t,r)}const Ts=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Ps=e=>t=>1-e(1-t),Cs=Jt(.33,1.53,.69,.99),xr=Ps(Cs),Es=Ts(xr),Is=e=>(e*=2)<1?.5*xr(e):.5*(2-Math.pow(2,-10*(e-1))),wr=e=>1-Math.sin(Math.acos(e)),ks=Ps(wr),Ms=Ts(wr),Vc=Jt(.42,0,1,1),Nc=Jt(0,0,.58,1),Ds=Jt(.42,0,.58,1),Uc=e=>Array.isArray(e)&&typeof e[0]!="number",js=e=>Array.isArray(e)&&typeof e[0]=="number",Fs={linear:Fe,easeIn:Vc,easeInOut:Ds,easeOut:Nc,circIn:wr,circInOut:Ms,circOut:ks,backIn:xr,backInOut:Es,backOut:Cs,anticipate:Is},Bc=e=>typeof e=="string",Ls=e=>{if(js(e)){qe(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,r,i]=e;return Jt(t,n,r,i)}else if(Bc(e))return qe(Fs[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),Fs[e];return e},In=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function zc(e,t){let n=new Set,r=new Set,i=!1,s=!1;const a=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1};function u(l){a.has(l)&&(d.schedule(l),e()),l(o)}const d={schedule:(l,c=!1,f=!1)=>{const m=f&&i?n:r;return c&&a.add(l),m.has(l)||m.add(l),l},cancel:l=>{r.delete(l),a.delete(l)},process:l=>{if(o=l,i){s=!0;return}i=!0,[n,r]=[r,n],n.forEach(u),n.clear(),i=!1,s&&(s=!1,d.process(l))}};return d}const $c=40;function Os(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,a=In.reduce((S,E)=>(S[E]=zc(s),S),{}),{setup:o,read:u,resolveKeyframes:d,preUpdate:l,update:c,preRender:f,render:h,postRender:m}=a,b=()=>{const S=Qe.useManualTiming?i.timestamp:performance.now();n=!1,Qe.useManualTiming||(i.delta=r?1e3/60:Math.max(Math.min(S-i.timestamp,$c),1)),i.timestamp=S,i.isProcessing=!0,o.process(i),u.process(i),d.process(i),l.process(i),c.process(i),f.process(i),h.process(i),m.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(b))},w=()=>{n=!0,r=!0,i.isProcessing||e(b)};return{schedule:In.reduce((S,E)=>{const P=a[E];return S[E]=(A,O=!1,p=!1)=>(n||w(),P.schedule(A,O,p)),S},{}),cancel:S=>{for(let E=0;E<In.length;E++)a[In[E]].cancel(S)},state:i,steps:a}}const{schedule:oe,cancel:it,state:ge,steps:Ar}=Os(typeof requestAnimationFrame<"u"?requestAnimationFrame:Fe,!0);let kn;function Wc(){kn=void 0}const Ee={now:()=>(kn===void 0&&Ee.set(ge.isProcessing||Qe.useManualTiming?ge.timestamp:performance.now()),kn),set:e=>{kn=e,queueMicrotask(Wc)}},Rs=e=>t=>typeof t=="string"&&t.startsWith(e),_s=Rs("--"),Hc=Rs("var(--"),Sr=e=>Hc(e)?Yc.test(e.split("/*")[0].trim()):!1,Yc=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,kt={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},en={...kt,transform:e=>Xe(0,1,e)},Mn={...kt,default:1},tn=e=>Math.round(e*1e5)/1e5,Tr=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Gc(e){return e==null}const Kc=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Pr=(e,t)=>n=>!!(typeof n=="string"&&Kc.test(n)&&n.startsWith(e)||t&&!Gc(n)&&Object.prototype.hasOwnProperty.call(n,t)),Vs=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,s,a,o]=r.match(Tr);return{[e]:parseFloat(i),[t]:parseFloat(s),[n]:parseFloat(a),alpha:o!==void 0?parseFloat(o):1}},Xc=e=>Xe(0,255,e),Cr={...kt,transform:e=>Math.round(Xc(e))},mt={test:Pr("rgb","red"),parse:Vs("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Cr.transform(e)+", "+Cr.transform(t)+", "+Cr.transform(n)+", "+tn(en.transform(r))+")"};function qc(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const Er={test:Pr("#"),parse:qc,transform:mt.transform},nn=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),st=nn("deg"),We=nn("%"),Q=nn("px"),Qc=nn("vh"),Zc=nn("vw"),Ns={...We,parse:e=>We.parse(e)/100,transform:e=>We.transform(e*100)},Mt={test:Pr("hsl","hue"),parse:Vs("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+We.transform(tn(t))+", "+We.transform(tn(n))+", "+tn(en.transform(r))+")"},fe={test:e=>mt.test(e)||Er.test(e)||Mt.test(e),parse:e=>mt.test(e)?mt.parse(e):Mt.test(e)?Mt.parse(e):Er.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?mt.transform(e):Mt.transform(e),getAnimatableNone:e=>{const t=fe.parse(e);return t.alpha=0,fe.transform(t)}},Jc=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function ef(e){return isNaN(e)&&typeof e=="string"&&(e.match(Tr)?.length||0)+(e.match(Jc)?.length||0)>0}const Us="number",Bs="color",tf="var",nf="var(",zs="${}",rf=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function rn(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let s=0;const o=t.replace(rf,u=>(fe.test(u)?(r.color.push(s),i.push(Bs),n.push(fe.parse(u))):u.startsWith(nf)?(r.var.push(s),i.push(tf),n.push(u)):(r.number.push(s),i.push(Us),n.push(parseFloat(u))),++s,zs)).split(zs);return{values:n,split:o,indexes:r,types:i}}function $s(e){return rn(e).values}function Ws(e){const{split:t,types:n}=rn(e),r=t.length;return i=>{let s="";for(let a=0;a<r;a++)if(s+=t[a],i[a]!==void 0){const o=n[a];o===Us?s+=tn(i[a]):o===Bs?s+=fe.transform(i[a]):s+=i[a]}return s}}const sf=e=>typeof e=="number"?0:fe.test(e)?fe.getAnimatableNone(e):e;function af(e){const t=$s(e);return Ws(e)(t.map(sf))}const at={test:ef,parse:$s,createTransformer:Ws,getAnimatableNone:af};function Ir(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function of({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,s=0,a=0;if(!t)i=s=a=n;else{const o=n<.5?n*(1+t):n+t-n*t,u=2*n-o;i=Ir(u,o,e+1/3),s=Ir(u,o,e),a=Ir(u,o,e-1/3)}return{red:Math.round(i*255),green:Math.round(s*255),blue:Math.round(a*255),alpha:r}}function Dn(e,t){return n=>n>0?t:e}const ue=(e,t,n)=>e+(t-e)*n,kr=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},lf=[Er,mt,Mt],uf=e=>lf.find(t=>t.test(e));function Hs(e){const t=uf(e);if(It(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let n=t.parse(e);return t===Mt&&(n=of(n)),n}const Ys=(e,t)=>{const n=Hs(e),r=Hs(t);if(!n||!r)return Dn(e,t);const i={...n};return s=>(i.red=kr(n.red,r.red,s),i.green=kr(n.green,r.green,s),i.blue=kr(n.blue,r.blue,s),i.alpha=ue(n.alpha,r.alpha,s),mt.transform(i))},Mr=new Set(["none","hidden"]);function cf(e,t){return Mr.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function ff(e,t){return n=>ue(e,t,n)}function Dr(e){return typeof e=="number"?ff:typeof e=="string"?Sr(e)?Dn:fe.test(e)?Ys:mf:Array.isArray(e)?Gs:typeof e=="object"?fe.test(e)?Ys:df:Dn}function Gs(e,t){const n=[...e],r=n.length,i=e.map((s,a)=>Dr(s)(s,t[a]));return s=>{for(let a=0;a<r;a++)n[a]=i[a](s);return n}}function df(e,t){const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=Dr(e[i])(e[i],t[i]));return i=>{for(const s in r)n[s]=r[s](i);return n}}function hf(e,t){const n=[],r={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){const s=t.types[i],a=e.indexes[s][r[s]],o=e.values[a]??0;n[i]=o,r[s]++}return n}const mf=(e,t)=>{const n=at.createTransformer(t),r=rn(e),i=rn(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Mr.has(e)&&!i.values.length||Mr.has(t)&&!r.values.length?cf(e,t):Qt(Gs(hf(r,i),i.values),n):(It(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),Dn(e,t))};function Ks(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?ue(e,t,n):Dr(e)(e,t)}const pf=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>oe.update(t,n),stop:()=>it(t),now:()=>ge.isProcessing?ge.timestamp:Ee.now()}},Xs=(e,t,n=10)=>{let r="";const i=Math.max(Math.round(t/n),2);for(let s=0;s<i;s++)r+=Math.round(e(s/(i-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},jn=2e4;function jr(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<jn;)t+=n,r=e.next(t);return t>=jn?1/0:t}function gf(e,t=100,n){const r=n({...e,keyframes:[0,t]}),i=Math.min(jr(r),jn);return{type:"keyframes",ease:s=>r.next(i*s).value/t,duration:Le(i)}}const yf=5;function qs(e,t,n){const r=Math.max(t-yf,0);return ws(n-e(r),t-r)}const ce={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},Fr=.001;function vf({duration:e=ce.duration,bounce:t=ce.bounce,velocity:n=ce.velocity,mass:r=ce.mass}){let i,s;It(e<=_e(ce.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let a=1-t;a=Xe(ce.minDamping,ce.maxDamping,a),e=Xe(ce.minDuration,ce.maxDuration,Le(e)),a<1?(i=d=>{const l=d*a,c=l*e,f=l-n,h=Lr(d,a),m=Math.exp(-c);return Fr-f/h*m},s=d=>{const c=d*a*e,f=c*n+n,h=Math.pow(a,2)*Math.pow(d,2)*e,m=Math.exp(-c),b=Lr(Math.pow(d,2),a);return(-i(d)+Fr>0?-1:1)*((f-h)*m)/b}):(i=d=>{const l=Math.exp(-d*e),c=(d-n)*e+1;return-Fr+l*c},s=d=>{const l=Math.exp(-d*e),c=(n-d)*(e*e);return l*c});const o=5/e,u=xf(i,s,o);if(e=_e(e),isNaN(u))return{stiffness:ce.stiffness,damping:ce.damping,duration:e};{const d=Math.pow(u,2)*r;return{stiffness:d,damping:a*2*Math.sqrt(r*d),duration:e}}}const bf=12;function xf(e,t,n){let r=n;for(let i=1;i<bf;i++)r=r-e(r)/t(r);return r}function Lr(e,t){return e*Math.sqrt(1-t*t)}const wf=["duration","bounce"],Af=["stiffness","damping","mass"];function Qs(e,t){return t.some(n=>e[n]!==void 0)}function Sf(e){let t={velocity:ce.velocity,stiffness:ce.stiffness,damping:ce.damping,mass:ce.mass,isResolvedFromDuration:!1,...e};if(!Qs(e,Af)&&Qs(e,wf))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,s=2*Xe(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:ce.mass,stiffness:i,damping:s}}else{const n=vf(e);t={...t,...n,mass:ce.mass},t.isResolvedFromDuration=!0}return t}function Fn(e=ce.visualDuration,t=ce.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:i}=n;const s=n.keyframes[0],a=n.keyframes[n.keyframes.length-1],o={done:!1,value:s},{stiffness:u,damping:d,mass:l,duration:c,velocity:f,isResolvedFromDuration:h}=Sf({...n,velocity:-Le(n.velocity||0)}),m=f||0,b=d/(2*Math.sqrt(u*l)),w=a-s,v=Le(Math.sqrt(u/l)),I=Math.abs(w)<5;r||(r=I?ce.restSpeed.granular:ce.restSpeed.default),i||(i=I?ce.restDelta.granular:ce.restDelta.default);let S;if(b<1){const P=Lr(v,b);S=A=>{const O=Math.exp(-b*v*A);return a-O*((m+b*v*w)/P*Math.sin(P*A)+w*Math.cos(P*A))}}else if(b===1)S=P=>a-Math.exp(-v*P)*(w+(m+v*w)*P);else{const P=v*Math.sqrt(b*b-1);S=A=>{const O=Math.exp(-b*v*A),p=Math.min(P*A,300);return a-O*((m+b*v*w)*Math.sinh(p)+P*w*Math.cosh(p))/P}}const E={calculatedDuration:h&&c||null,next:P=>{const A=S(P);if(h)o.done=P>=c;else{let O=P===0?m:0;b<1&&(O=P===0?_e(m):qs(S,P,A));const p=Math.abs(O)<=r,y=Math.abs(a-A)<=i;o.done=p&&y}return o.value=o.done?a:A,o},toString:()=>{const P=Math.min(jr(E),jn),A=Xs(O=>E.next(P*O).value,P,30);return P+"ms "+A},toTransition:()=>{}};return E}Fn.applyToOptions=e=>{const t=gf(e,100,Fn);return e.ease=t.ease,e.duration=_e(t.duration),e.type="keyframes",e};function Or({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:s=500,modifyTarget:a,min:o,max:u,restDelta:d=.5,restSpeed:l}){const c=e[0],f={done:!1,value:c},h=p=>o!==void 0&&p<o||u!==void 0&&p>u,m=p=>o===void 0?u:u===void 0||Math.abs(o-p)<Math.abs(u-p)?o:u;let b=n*t;const w=c+b,v=a===void 0?w:a(w);v!==w&&(b=v-c);const I=p=>-b*Math.exp(-p/r),S=p=>v+I(p),E=p=>{const y=I(p),T=S(p);f.done=Math.abs(y)<=d,f.value=f.done?v:T};let P,A;const O=p=>{h(f.value)&&(P=p,A=Fn({keyframes:[f.value,m(f.value)],velocity:qs(S,p,f.value),damping:i,stiffness:s,restDelta:d,restSpeed:l}))};return O(0),{calculatedDuration:null,next:p=>{let y=!1;return!A&&P===void 0&&(y=!0,E(p),O(p)),P!==void 0&&p>=P?A.next(p-P):(!y&&E(p),f)}}}function Tf(e,t,n){const r=[],i=n||Qe.mix||Ks,s=e.length-1;for(let a=0;a<s;a++){let o=i(e[a],e[a+1]);if(t){const u=Array.isArray(t)?t[a]||Fe:t;o=Qt(u,o)}r.push(o)}return r}function Pf(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const s=e.length;if(qe(s===t.length,"Both input and output ranges must be the same length","range-length"),s===1)return()=>t[0];if(s===2&&t[0]===t[1])return()=>t[1];const a=e[0]===e[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const o=Tf(t,r,i),u=o.length,d=l=>{if(a&&l<e[0])return t[0];let c=0;if(u>1)for(;c<e.length-2&&!(l<e[c+1]);c++);const f=Zt(e[c],e[c+1],l);return o[c](f)};return n?l=>d(Xe(e[0],e[s-1],l)):d}function Cf(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=Zt(0,t,r);e.push(ue(n,1,i))}}function Ef(e){const t=[0];return Cf(t,e.length-1),t}function If(e,t){return e.map(n=>n*t)}function kf(e,t){return e.map(()=>t||Ds).splice(0,e.length-1)}function Dt({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=Uc(r)?r.map(Ls):Ls(r),s={done:!1,value:t[0]},a=If(n&&n.length===t.length?n:Ef(t),e),o=Pf(a,t,{ease:Array.isArray(i)?i:kf(t,i)});return{calculatedDuration:e,next:u=>(s.value=o(u),s.done=u>=e,s)}}const Mf=e=>e!==null;function Rr(e,{repeat:t,repeatType:n="loop"},r,i=1){const s=e.filter(Mf),o=i<0||t&&n!=="loop"&&t%2===1?0:s.length-1;return!o||r===void 0?s[o]:r}const Df={decay:Or,inertia:Or,tween:Dt,keyframes:Dt,spring:Fn};function Zs(e){typeof e.type=="string"&&(e.type=Df[e.type])}class _r{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const jf=e=>e/100;class Vr extends _r{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{const{motionValue:n}=this.options;n&&n.updatedAt!==Ee.now()&&this.tick(Ee.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;Zs(t);const{type:n=Dt,repeat:r=0,repeatDelay:i=0,repeatType:s,velocity:a=0}=t;let{keyframes:o}=t;const u=n||Dt;process.env.NODE_ENV!=="production"&&u!==Dt&&qe(o.length<=2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${o}`,"spring-two-frames"),u!==Dt&&typeof o[0]!="number"&&(this.mixKeyframes=Qt(jf,Ks(o[0],o[1])),o=[0,100]);const d=u({...t,keyframes:o});s==="mirror"&&(this.mirroredGenerator=u({...t,keyframes:[...o].reverse(),velocity:-a})),d.calculatedDuration===null&&(d.calculatedDuration=jr(d));const{calculatedDuration:l}=d;this.calculatedDuration=l,this.resolvedDuration=l+i,this.totalDuration=this.resolvedDuration*(r+1)-i,this.generator=d}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:i,mixKeyframes:s,mirroredGenerator:a,resolvedDuration:o,calculatedDuration:u}=this;if(this.startTime===null)return r.next(0);const{delay:d=0,keyframes:l,repeat:c,repeatType:f,repeatDelay:h,type:m,onUpdate:b,finalKeyframe:w}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const v=this.currentTime-d*(this.playbackSpeed>=0?1:-1),I=this.playbackSpeed>=0?v<0:v>i;this.currentTime=Math.max(v,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let S=this.currentTime,E=r;if(c){const p=Math.min(this.currentTime,i)/o;let y=Math.floor(p),T=p%1;!T&&p>=1&&(T=1),T===1&&y--,y=Math.min(y,c+1),y%2&&(f==="reverse"?(T=1-T,h&&(T-=h/o)):f==="mirror"&&(E=a)),S=Xe(0,1,T)*o}const P=I?{done:!1,value:l[0]}:E.next(S);s&&(P.value=s(P.value));let{done:A}=P;!I&&u!==null&&(A=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const O=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&A);return O&&m!==Or&&(P.value=Rr(l,this.options,w,this.speed)),b&&b(P.value),O&&this.finish(),P}then(t,n){return this.finished.then(t,n)}get duration(){return Le(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Le(t)}get time(){return Le(this.currentTime)}set time(t){t=_e(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(Ee.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=Le(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=pf,startTime:n}=this.options;this.driver||(this.driver=t(i=>this.tick(i))),this.options.onPlay?.();const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(Ee.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}function Ff(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const pt=e=>e*180/Math.PI,Nr=e=>{const t=pt(Math.atan2(e[1],e[0]));return Ur(t)},Lf={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Nr,rotateZ:Nr,skewX:e=>pt(Math.atan(e[1])),skewY:e=>pt(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},Ur=e=>(e=e%360,e<0&&(e+=360),e),Js=Nr,ea=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),ta=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Of={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:ea,scaleY:ta,scale:e=>(ea(e)+ta(e))/2,rotateX:e=>Ur(pt(Math.atan2(e[6],e[5]))),rotateY:e=>Ur(pt(Math.atan2(-e[2],e[0]))),rotateZ:Js,rotate:Js,skewX:e=>pt(Math.atan(e[4])),skewY:e=>pt(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function Br(e){return e.includes("scale")?1:0}function zr(e,t){if(!e||e==="none")return Br(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,i;if(n)r=Of,i=n;else{const o=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=Lf,i=o}if(!i)return Br(t);const s=r[t],a=i[1].split(",").map(_f);return typeof s=="function"?s(a):a[s]}const Rf=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return zr(n,t)};function _f(e){return parseFloat(e.trim())}const jt=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Ft=new Set(jt),na=e=>e===kt||e===Q,Vf=new Set(["x","y","z"]),Nf=jt.filter(e=>!Vf.has(e));function Uf(e){const t=[];return Nf.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const gt={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>zr(t,"x"),y:(e,{transform:t})=>zr(t,"y")};gt.translateX=gt.x,gt.translateY=gt.y;const yt=new Set;let $r=!1,Wr=!1,Hr=!1;function ra(){if(Wr){const e=Array.from(yt).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=Uf(r);i.length&&(n.set(r,i),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const i=n.get(r);i&&i.forEach(([s,a])=>{r.getValue(s)?.set(a)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Wr=!1,$r=!1,yt.forEach(e=>e.complete(Hr)),yt.clear()}function ia(){yt.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Wr=!0)})}function Bf(){Hr=!0,ia(),ra(),Hr=!1}class Yr{constructor(t,n,r,i,s,a=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=s,this.isAsync=a}scheduleResolve(){this.state="scheduled",this.isAsync?(yt.add(this),$r||($r=!0,oe.read(ia),oe.resolveKeyframes(ra))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;if(t[0]===null){const s=i?.get(),a=t[t.length-1];if(s!==void 0)t[0]=s;else if(r&&n){const o=r.readValue(n,a);o!=null&&(t[0]=o)}t[0]===void 0&&(t[0]=a),i&&s===void 0&&i.set(t[0])}Ff(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),yt.delete(this)}cancel(){this.state==="scheduled"&&(yt.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const zf=e=>e.startsWith("--");function $f(e,t,n){zf(t)?e.style.setProperty(t,n):e.style[t]=n}const Wf=yr(()=>window.ScrollTimeline!==void 0),Hf={};function Yf(e,t){const n=yr(e);return()=>Hf[t]??n()}const sa=Yf(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),sn=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,aa={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:sn([0,.65,.55,1]),circOut:sn([.55,0,1,.45]),backIn:sn([.31,.01,.66,-.59]),backOut:sn([.33,1.53,.69,.99])};function oa(e,t){if(e)return typeof e=="function"?sa()?Xs(e,t):"ease-out":js(e)?sn(e):Array.isArray(e)?e.map(n=>oa(n,t)||aa.easeOut):aa[e]}function Gf(e,t,n,{delay:r=0,duration:i=300,repeat:s=0,repeatType:a="loop",ease:o="easeOut",times:u}={},d=void 0){const l={[t]:n};u&&(l.offset=u);const c=oa(o,i);Array.isArray(c)&&(l.easing=c);const f={delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:s+1,direction:a==="reverse"?"alternate":"normal"};return d&&(f.pseudoElement=d),e.animate(l,f)}function la(e){return typeof e=="function"&&"applyToOptions"in e}function Kf({type:e,...t}){return la(e)&&sa()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class Xf extends _r{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;const{element:n,name:r,keyframes:i,pseudoElement:s,allowFlatten:a=!1,finalKeyframe:o,onComplete:u}=t;this.isPseudoElement=!!s,this.allowFlatten=a,this.options=t,qe(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const d=Kf(t);this.animation=Gf(n,r,i,d,s),d.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!s){const l=Rr(i,this.options,o,this.speed);this.updateMotionValue?this.updateMotionValue(l):$f(n,r,l),this.animation.cancel()}u?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return Le(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Le(t)}get time(){return Le(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=_e(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&Wf()?(this.animation.timeline=t,Fe):n(this)}}const ua={anticipate:Is,backInOut:Es,circInOut:Ms};function qf(e){return e in ua}function Qf(e){typeof e.ease=="string"&&qf(e.ease)&&(e.ease=ua[e.ease])}const ca=10;class Zf extends Xf{constructor(t){Qf(t),Zs(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:i,element:s,...a}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const o=new Vr({...a,autoplay:!1}),u=_e(this.finishedTime??this.time);n.setWithVelocity(o.sample(u-ca).value,o.sample(u).value,ca),o.stop()}}const fa=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(at.test(e)||e==="0")&&!e.startsWith("url("));function Jf(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function ed(e,t,n,r){const i=e[0];if(i===null)return!1;if(t==="display"||t==="visibility")return!0;const s=e[e.length-1],a=fa(i,t),o=fa(s,t);return It(a===o,`You are trying to animate ${t} from "${i}" to "${s}". "${a?s:i}" is not an animatable value.`,"value-not-animatable"),!a||!o?!1:Jf(e)||(n==="spring"||la(n))&&r}function Gr(e){e.duration=0,e.type="keyframes"}const td=new Set(["opacity","clipPath","filter","transform"]),nd=yr(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function rd(e){const{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:s,type:a}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;const{onUpdate:u,transformTemplate:d}=t.owner.getProps();return nd()&&n&&td.has(n)&&(n!=="transform"||!d)&&!u&&!r&&i!=="mirror"&&s!==0&&a!=="inertia"}const id=40;class sd extends _r{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:s=0,repeatType:a="loop",keyframes:o,name:u,motionValue:d,element:l,...c}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=Ee.now();const f={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:s,repeatType:a,name:u,motionValue:d,element:l,...c},h=l?.KeyframeResolver||Yr;this.keyframeResolver=new h(o,(m,b,w)=>this.onKeyframesResolved(m,b,f,!w),u,d,l),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,n,r,i){this.keyframeResolver=void 0;const{name:s,type:a,velocity:o,delay:u,isHandoff:d,onUpdate:l}=r;this.resolvedAt=Ee.now(),ed(t,s,a,o)||((Qe.instantAnimations||!u)&&l?.(Rr(t,r,n)),t[0]=t[t.length-1],Gr(r),r.repeat=0);const f={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>id?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},h=!d&&rd(f)?new Zf({...f,element:f.motionValue.owner.current}):new Vr(f);h.finished.then(()=>this.notifyFinished()).catch(Fe),this.pendingTimeline&&(this.stopTimeline=h.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=h}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Bf()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}const ad=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function od(e){const t=ad.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}const ld=4;function da(e,t,n=1){qe(n<=ld,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[r,i]=od(e);if(!r)return;const s=window.getComputedStyle(t).getPropertyValue(r);if(s){const a=s.trim();return vs(a)?parseFloat(a):a}return Sr(i)?da(i,t,n+1):i}function Kr(e,t){return e?.[t]??e?.default??e}const ha=new Set(["width","height","top","left","right","bottom",...jt]),ud={test:e=>e==="auto",parse:e=>e},ma=e=>t=>t.test(e),pa=[kt,Q,We,st,Zc,Qc,ud],ga=e=>pa.find(ma(e));function cd(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||xs(e):!0}const fd=new Set(["brightness","contrast","saturate","opacity"]);function dd(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Tr)||[];if(!r)return e;const i=n.replace(r,"");let s=fd.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+i+")"}const hd=/\b([a-z-]*)\(.*?\)/gu,Xr={...at,getAnimatableNone:e=>{const t=e.match(hd);return t?t.map(dd).join(" "):e}},ya={...kt,transform:Math.round},qr={borderWidth:Q,borderTopWidth:Q,borderRightWidth:Q,borderBottomWidth:Q,borderLeftWidth:Q,borderRadius:Q,radius:Q,borderTopLeftRadius:Q,borderTopRightRadius:Q,borderBottomRightRadius:Q,borderBottomLeftRadius:Q,width:Q,maxWidth:Q,height:Q,maxHeight:Q,top:Q,right:Q,bottom:Q,left:Q,padding:Q,paddingTop:Q,paddingRight:Q,paddingBottom:Q,paddingLeft:Q,margin:Q,marginTop:Q,marginRight:Q,marginBottom:Q,marginLeft:Q,backgroundPositionX:Q,backgroundPositionY:Q,...{rotate:st,rotateX:st,rotateY:st,rotateZ:st,scale:Mn,scaleX:Mn,scaleY:Mn,scaleZ:Mn,skew:st,skewX:st,skewY:st,distance:Q,translateX:Q,translateY:Q,translateZ:Q,x:Q,y:Q,z:Q,perspective:Q,transformPerspective:Q,opacity:en,originX:Ns,originY:Ns,originZ:Q},zIndex:ya,fillOpacity:en,strokeOpacity:en,numOctaves:ya},md={...qr,color:fe,backgroundColor:fe,outlineColor:fe,fill:fe,stroke:fe,borderColor:fe,borderTopColor:fe,borderRightColor:fe,borderBottomColor:fe,borderLeftColor:fe,filter:Xr,WebkitFilter:Xr},va=e=>md[e];function ba(e,t){let n=va(e);return n!==Xr&&(n=at),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const pd=new Set(["auto","none","0"]);function gd(e,t,n){let r=0,i;for(;r<e.length&&!i;){const s=e[r];typeof s=="string"&&!pd.has(s)&&rn(s).values.length&&(i=e[r]),r++}if(i&&n)for(const s of t)e[s]=ba(n,i)}class yd extends Yr{constructor(t,n,r,i,s){super(t,n,r,i,s,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let u=0;u<t.length;u++){let d=t[u];if(typeof d=="string"&&(d=d.trim(),Sr(d))){const l=da(d,n.current);l!==void 0&&(t[u]=l),u===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!ha.has(r)||t.length!==2)return;const[i,s]=t,a=ga(i),o=ga(s);if(a!==o)if(na(a)&&na(o))for(let u=0;u<t.length;u++){const d=t[u];typeof d=="string"&&(t[u]=parseFloat(d))}else gt[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let i=0;i<t.length;i++)(t[i]===null||cd(t[i]))&&r.push(i);r.length&&gd(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=gt[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&t.getValue(r,i).jump(i,!1)}measureEndState(){const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);const s=r.length-1,a=r[s];r[s]=gt[n](t.measureViewportBox(),window.getComputedStyle(t.current)),a!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=a),this.removedTransforms?.length&&this.removedTransforms.forEach(([o,u])=>{t.getValue(o).set(u)}),this.resolveNoneKeyframes()}}function vd(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const i=n?.[e]??r.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e)}const xa=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function wa(e){return bs(e)&&"offsetHeight"in e}const Aa=30,bd=e=>!isNaN(parseFloat(e));class xd{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{const i=Ee.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const s of this.dependents)s.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Ee.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=bd(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&br(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new vr);const r=this.events[t].add(n);return t==="change"?()=>{r(),oe.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=Ee.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Aa)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Aa);return ws(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Lt(e,t){return new xd(e,t)}const{schedule:Qr}=Os(queueMicrotask,!1),Ve={x:!1,y:!1};function Sa(){return Ve.x||Ve.y}function wd(e){return e==="x"||e==="y"?Ve[e]?null:(Ve[e]=!0,()=>{Ve[e]=!1}):Ve.x||Ve.y?null:(Ve.x=Ve.y=!0,()=>{Ve.x=Ve.y=!1})}function Ta(e,t){const n=vd(e),r=new AbortController,i={passive:!0,...t,signal:r.signal};return[n,i,()=>r.abort()]}function Pa(e){return!(e.pointerType==="touch"||Sa())}function Ad(e,t,n={}){const[r,i,s]=Ta(e,n),a=o=>{if(!Pa(o))return;const{target:u}=o,d=t(u,o);if(typeof d!="function"||!u)return;const l=c=>{Pa(c)&&(d(c),u.removeEventListener("pointerleave",l))};u.addEventListener("pointerleave",l,i)};return r.forEach(o=>{o.addEventListener("pointerenter",a,i)}),s}const Ca=(e,t)=>t?e===t?!0:Ca(e,t.parentElement):!1,Zr=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Sd=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Td(e){return Sd.has(e.tagName)||e.tabIndex!==-1}const Ln=new WeakSet;function Ea(e){return t=>{t.key==="Enter"&&e(t)}}function Jr(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Pd=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=Ea(()=>{if(Ln.has(n))return;Jr(n,"down");const i=Ea(()=>{Jr(n,"up")}),s=()=>Jr(n,"cancel");n.addEventListener("keyup",i,t),n.addEventListener("blur",s,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function Ia(e){return Zr(e)&&!Sa()}function Cd(e,t,n={}){const[r,i,s]=Ta(e,n),a=o=>{const u=o.currentTarget;if(!Ia(o))return;Ln.add(u);const d=t(u,o),l=(h,m)=>{window.removeEventListener("pointerup",c),window.removeEventListener("pointercancel",f),Ln.has(u)&&Ln.delete(u),Ia(h)&&typeof d=="function"&&d(h,{success:m})},c=h=>{l(h,u===window||u===document||n.useGlobalTarget||Ca(u,h.target))},f=h=>{l(h,!1)};window.addEventListener("pointerup",c,i),window.addEventListener("pointercancel",f,i)};return r.forEach(o=>{(n.useGlobalTarget?window:o).addEventListener("pointerdown",a,i),wa(o)&&(o.addEventListener("focus",d=>Pd(d,i)),!Td(o)&&!o.hasAttribute("tabindex")&&(o.tabIndex=0))}),s}function ka(e){return bs(e)&&"ownerSVGElement"in e}function Ed(e){return ka(e)&&e.tagName==="svg"}const be=e=>!!(e&&e.getVelocity),Id=[...pa,fe,at],kd=e=>Id.find(ma(e)),ei=z.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function Ma(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Md(...e){return t=>{let n=!1;const r=e.map(i=>{const s=Ma(i,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let i=0;i<r.length;i++){const s=r[i];typeof s=="function"?s():Ma(e[i],null)}}}}function Dd(...e){return Tn.useCallback(Md(...e),e)}class jd extends Tn.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=n.offsetParent,i=wa(r)&&r.offsetWidth||0,s=this.props.sizeRef.current;s.height=n.offsetHeight||0,s.width=n.offsetWidth||0,s.top=n.offsetTop,s.left=n.offsetLeft,s.right=i-s.width-s.left}return null}componentDidUpdate(){}render(){return this.props.children}}function Fd({children:e,isPresent:t,anchorX:n,root:r}){const i=z.useId(),s=z.useRef(null),a=z.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:o}=z.useContext(ei),u=Dd(s,e?.ref);return z.useInsertionEffect(()=>{const{width:d,height:l,top:c,left:f,right:h}=a.current;if(t||!s.current||!d||!l)return;const m=n==="left"?`left: ${f}`:`right: ${h}`;s.current.dataset.motionPopId=i;const b=document.createElement("style");o&&(b.nonce=o);const w=r??document.head;return w.appendChild(b),b.sheet&&b.sheet.insertRule(`
6
+ <%s key={someKey} {...props} />`,B,Q,J,Q),U[Q+B]=!0)}if(Q=null,W!==void 0&&(n(W),Q=""+W),a(N)&&(n(N.key),Q=""+N.key),"key"in N){W={};for(var ee in N)ee!=="key"&&(W[ee]=N[ee])}else W=N;return Q&&o(W,typeof F=="function"?F.displayName||F.name||"Unknown":F),d(F,Q,W,i(),V,X)}function c(F){f(F)?F._store&&(F._store.validated=1):typeof F=="object"&&F!==null&&F.$$typeof===y&&(F._payload.status==="fulfilled"?f(F._payload.value)&&F._payload.value._store&&(F._payload.value._store.validated=1):F._store&&(F._store.validated=1))}function f(F){return typeof F=="object"&&F!==null&&F.$$typeof===m}var h=z,m=Symbol.for("react.transitional.element"),b=Symbol.for("react.portal"),w=Symbol.for("react.fragment"),v=Symbol.for("react.strict_mode"),I=Symbol.for("react.profiler"),S=Symbol.for("react.consumer"),E=Symbol.for("react.context"),P=Symbol.for("react.forward_ref"),A=Symbol.for("react.suspense"),O=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),T=Symbol.for("react.activity"),k=Symbol.for("react.client.reference"),M=h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,j=Object.prototype.hasOwnProperty,C=Array.isArray,R=console.createTask?console.createTask:function(){return null};h={react_stack_bottom_frame:function(F){return F()}};var x,g={},_=h.react_stack_bottom_frame.bind(h,s)(),L=R(r(s)),U={};qt.Fragment=w,qt.jsx=function(F,N,W){var B=1e4>M.recentlyCreatedOwnerStacks++;return l(F,N,W,!1,B?Error("react-stack-top-frame"):_,B?R(r(F)):L)},qt.jsxs=function(F,N,W){var B=1e4>M.recentlyCreatedOwnerStacks++;return l(F,N,W,!0,B?Error("react-stack-top-frame"):_,B?R(r(F)):L)}})()),qt}var gs;function Fc(){return gs||(gs=1,process.env.NODE_ENV==="production"?Cn.exports=Dc():Cn.exports=jc()),Cn.exports}var D=Fc();const fr=z.createContext({});function dr(e){const t=z.useRef(null);return t.current===null&&(t.current=e()),t.current}const hr=typeof window<"u",ys=hr?z.useLayoutEffect:z.useEffect,En=z.createContext(null);function mr(e,t){e.indexOf(t)===-1&&e.push(t)}function pr(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Xe=(e,t,n)=>n>t?t:n<e?e:n;function gr(e,t){return t?`${e}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${t}`:e}let It=()=>{},qe=()=>{};process.env.NODE_ENV!=="production"&&(It=(e,t,n)=>{!e&&typeof console<"u"&&console.warn(gr(t,n))},qe=(e,t,n)=>{if(!e)throw new Error(gr(t,n))});const Qe={},vs=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function bs(e){return typeof e=="object"&&e!==null}const xs=e=>/^0[^.\s]+$/u.test(e);function yr(e){let t;return()=>(t===void 0&&(t=e()),t)}const Fe=e=>e,Lc=(e,t)=>n=>t(e(n)),Qt=(...e)=>e.reduce(Lc),Zt=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class vr{constructor(){this.subscriptions=[]}add(t){return mr(this.subscriptions,t),()=>pr(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let s=0;s<i;s++){const a=this.subscriptions[s];a&&a(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const _e=e=>e*1e3,Le=e=>e/1e3;function ws(e,t){return t?e*(1e3/t):0}const As=new Set;function br(e,t,n){e||As.has(t)||(console.warn(gr(t,n)),As.add(t))}const Ss=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Oc=1e-7,Rc=12;function _c(e,t,n,r,i){let s,a,o=0;do a=t+(n-t)/2,s=Ss(a,r,i)-e,s>0?n=a:t=a;while(Math.abs(s)>Oc&&++o<Rc);return a}function Jt(e,t,n,r){if(e===t&&n===r)return Fe;const i=s=>_c(s,0,1,e,n);return s=>s===0||s===1?s:Ss(i(s),t,r)}const Ts=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Ps=e=>t=>1-e(1-t),Cs=Jt(.33,1.53,.69,.99),xr=Ps(Cs),Es=Ts(xr),Is=e=>(e*=2)<1?.5*xr(e):.5*(2-Math.pow(2,-10*(e-1))),wr=e=>1-Math.sin(Math.acos(e)),ks=Ps(wr),Ms=Ts(wr),Vc=Jt(.42,0,1,1),Nc=Jt(0,0,.58,1),Ds=Jt(.42,0,.58,1),Uc=e=>Array.isArray(e)&&typeof e[0]!="number",js=e=>Array.isArray(e)&&typeof e[0]=="number",Fs={linear:Fe,easeIn:Vc,easeInOut:Ds,easeOut:Nc,circIn:wr,circInOut:Ms,circOut:ks,backIn:xr,backInOut:Es,backOut:Cs,anticipate:Is},Bc=e=>typeof e=="string",Ls=e=>{if(js(e)){qe(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,r,i]=e;return Jt(t,n,r,i)}else if(Bc(e))return qe(Fs[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),Fs[e];return e},In=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function zc(e,t){let n=new Set,r=new Set,i=!1,s=!1;const a=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1};function u(l){a.has(l)&&(d.schedule(l),e()),l(o)}const d={schedule:(l,c=!1,f=!1)=>{const m=f&&i?n:r;return c&&a.add(l),m.has(l)||m.add(l),l},cancel:l=>{r.delete(l),a.delete(l)},process:l=>{if(o=l,i){s=!0;return}i=!0,[n,r]=[r,n],n.forEach(u),n.clear(),i=!1,s&&(s=!1,d.process(l))}};return d}const $c=40;function Os(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,a=In.reduce((S,E)=>(S[E]=zc(s),S),{}),{setup:o,read:u,resolveKeyframes:d,preUpdate:l,update:c,preRender:f,render:h,postRender:m}=a,b=()=>{const S=Qe.useManualTiming?i.timestamp:performance.now();n=!1,Qe.useManualTiming||(i.delta=r?1e3/60:Math.max(Math.min(S-i.timestamp,$c),1)),i.timestamp=S,i.isProcessing=!0,o.process(i),u.process(i),d.process(i),l.process(i),c.process(i),f.process(i),h.process(i),m.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(b))},w=()=>{n=!0,r=!0,i.isProcessing||e(b)};return{schedule:In.reduce((S,E)=>{const P=a[E];return S[E]=(A,O=!1,p=!1)=>(n||w(),P.schedule(A,O,p)),S},{}),cancel:S=>{for(let E=0;E<In.length;E++)a[In[E]].cancel(S)},state:i,steps:a}}const{schedule:oe,cancel:it,state:ye,steps:Ar}=Os(typeof requestAnimationFrame<"u"?requestAnimationFrame:Fe,!0);let kn;function Wc(){kn=void 0}const Ee={now:()=>(kn===void 0&&Ee.set(ye.isProcessing||Qe.useManualTiming?ye.timestamp:performance.now()),kn),set:e=>{kn=e,queueMicrotask(Wc)}},Rs=e=>t=>typeof t=="string"&&t.startsWith(e),_s=Rs("--"),Hc=Rs("var(--"),Sr=e=>Hc(e)?Yc.test(e.split("/*")[0].trim()):!1,Yc=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,kt={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},en={...kt,transform:e=>Xe(0,1,e)},Mn={...kt,default:1},tn=e=>Math.round(e*1e5)/1e5,Tr=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Gc(e){return e==null}const Kc=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Pr=(e,t)=>n=>!!(typeof n=="string"&&Kc.test(n)&&n.startsWith(e)||t&&!Gc(n)&&Object.prototype.hasOwnProperty.call(n,t)),Vs=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,s,a,o]=r.match(Tr);return{[e]:parseFloat(i),[t]:parseFloat(s),[n]:parseFloat(a),alpha:o!==void 0?parseFloat(o):1}},Xc=e=>Xe(0,255,e),Cr={...kt,transform:e=>Math.round(Xc(e))},mt={test:Pr("rgb","red"),parse:Vs("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Cr.transform(e)+", "+Cr.transform(t)+", "+Cr.transform(n)+", "+tn(en.transform(r))+")"};function qc(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const Er={test:Pr("#"),parse:qc,transform:mt.transform},nn=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),st=nn("deg"),We=nn("%"),q=nn("px"),Qc=nn("vh"),Zc=nn("vw"),Ns={...We,parse:e=>We.parse(e)/100,transform:e=>We.transform(e*100)},Mt={test:Pr("hsl","hue"),parse:Vs("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+We.transform(tn(t))+", "+We.transform(tn(n))+", "+tn(en.transform(r))+")"},de={test:e=>mt.test(e)||Er.test(e)||Mt.test(e),parse:e=>mt.test(e)?mt.parse(e):Mt.test(e)?Mt.parse(e):Er.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?mt.transform(e):Mt.transform(e),getAnimatableNone:e=>{const t=de.parse(e);return t.alpha=0,de.transform(t)}},Jc=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function ef(e){return isNaN(e)&&typeof e=="string"&&(e.match(Tr)?.length||0)+(e.match(Jc)?.length||0)>0}const Us="number",Bs="color",tf="var",nf="var(",zs="${}",rf=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function rn(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let s=0;const o=t.replace(rf,u=>(de.test(u)?(r.color.push(s),i.push(Bs),n.push(de.parse(u))):u.startsWith(nf)?(r.var.push(s),i.push(tf),n.push(u)):(r.number.push(s),i.push(Us),n.push(parseFloat(u))),++s,zs)).split(zs);return{values:n,split:o,indexes:r,types:i}}function $s(e){return rn(e).values}function Ws(e){const{split:t,types:n}=rn(e),r=t.length;return i=>{let s="";for(let a=0;a<r;a++)if(s+=t[a],i[a]!==void 0){const o=n[a];o===Us?s+=tn(i[a]):o===Bs?s+=de.transform(i[a]):s+=i[a]}return s}}const sf=e=>typeof e=="number"?0:de.test(e)?de.getAnimatableNone(e):e;function af(e){const t=$s(e);return Ws(e)(t.map(sf))}const at={test:ef,parse:$s,createTransformer:Ws,getAnimatableNone:af};function Ir(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function of({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,s=0,a=0;if(!t)i=s=a=n;else{const o=n<.5?n*(1+t):n+t-n*t,u=2*n-o;i=Ir(u,o,e+1/3),s=Ir(u,o,e),a=Ir(u,o,e-1/3)}return{red:Math.round(i*255),green:Math.round(s*255),blue:Math.round(a*255),alpha:r}}function Dn(e,t){return n=>n>0?t:e}const ce=(e,t,n)=>e+(t-e)*n,kr=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},lf=[Er,mt,Mt],uf=e=>lf.find(t=>t.test(e));function Hs(e){const t=uf(e);if(It(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let n=t.parse(e);return t===Mt&&(n=of(n)),n}const Ys=(e,t)=>{const n=Hs(e),r=Hs(t);if(!n||!r)return Dn(e,t);const i={...n};return s=>(i.red=kr(n.red,r.red,s),i.green=kr(n.green,r.green,s),i.blue=kr(n.blue,r.blue,s),i.alpha=ce(n.alpha,r.alpha,s),mt.transform(i))},Mr=new Set(["none","hidden"]);function cf(e,t){return Mr.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function ff(e,t){return n=>ce(e,t,n)}function Dr(e){return typeof e=="number"?ff:typeof e=="string"?Sr(e)?Dn:de.test(e)?Ys:mf:Array.isArray(e)?Gs:typeof e=="object"?de.test(e)?Ys:df:Dn}function Gs(e,t){const n=[...e],r=n.length,i=e.map((s,a)=>Dr(s)(s,t[a]));return s=>{for(let a=0;a<r;a++)n[a]=i[a](s);return n}}function df(e,t){const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=Dr(e[i])(e[i],t[i]));return i=>{for(const s in r)n[s]=r[s](i);return n}}function hf(e,t){const n=[],r={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){const s=t.types[i],a=e.indexes[s][r[s]],o=e.values[a]??0;n[i]=o,r[s]++}return n}const mf=(e,t)=>{const n=at.createTransformer(t),r=rn(e),i=rn(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Mr.has(e)&&!i.values.length||Mr.has(t)&&!r.values.length?cf(e,t):Qt(Gs(hf(r,i),i.values),n):(It(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),Dn(e,t))};function Ks(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?ce(e,t,n):Dr(e)(e,t)}const pf=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>oe.update(t,n),stop:()=>it(t),now:()=>ye.isProcessing?ye.timestamp:Ee.now()}},Xs=(e,t,n=10)=>{let r="";const i=Math.max(Math.round(t/n),2);for(let s=0;s<i;s++)r+=Math.round(e(s/(i-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},jn=2e4;function jr(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<jn;)t+=n,r=e.next(t);return t>=jn?1/0:t}function gf(e,t=100,n){const r=n({...e,keyframes:[0,t]}),i=Math.min(jr(r),jn);return{type:"keyframes",ease:s=>r.next(i*s).value/t,duration:Le(i)}}const yf=5;function qs(e,t,n){const r=Math.max(t-yf,0);return ws(n-e(r),t-r)}const fe={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},Fr=.001;function vf({duration:e=fe.duration,bounce:t=fe.bounce,velocity:n=fe.velocity,mass:r=fe.mass}){let i,s;It(e<=_e(fe.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let a=1-t;a=Xe(fe.minDamping,fe.maxDamping,a),e=Xe(fe.minDuration,fe.maxDuration,Le(e)),a<1?(i=d=>{const l=d*a,c=l*e,f=l-n,h=Lr(d,a),m=Math.exp(-c);return Fr-f/h*m},s=d=>{const c=d*a*e,f=c*n+n,h=Math.pow(a,2)*Math.pow(d,2)*e,m=Math.exp(-c),b=Lr(Math.pow(d,2),a);return(-i(d)+Fr>0?-1:1)*((f-h)*m)/b}):(i=d=>{const l=Math.exp(-d*e),c=(d-n)*e+1;return-Fr+l*c},s=d=>{const l=Math.exp(-d*e),c=(n-d)*(e*e);return l*c});const o=5/e,u=xf(i,s,o);if(e=_e(e),isNaN(u))return{stiffness:fe.stiffness,damping:fe.damping,duration:e};{const d=Math.pow(u,2)*r;return{stiffness:d,damping:a*2*Math.sqrt(r*d),duration:e}}}const bf=12;function xf(e,t,n){let r=n;for(let i=1;i<bf;i++)r=r-e(r)/t(r);return r}function Lr(e,t){return e*Math.sqrt(1-t*t)}const wf=["duration","bounce"],Af=["stiffness","damping","mass"];function Qs(e,t){return t.some(n=>e[n]!==void 0)}function Sf(e){let t={velocity:fe.velocity,stiffness:fe.stiffness,damping:fe.damping,mass:fe.mass,isResolvedFromDuration:!1,...e};if(!Qs(e,Af)&&Qs(e,wf))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,s=2*Xe(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:fe.mass,stiffness:i,damping:s}}else{const n=vf(e);t={...t,...n,mass:fe.mass},t.isResolvedFromDuration=!0}return t}function Fn(e=fe.visualDuration,t=fe.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:i}=n;const s=n.keyframes[0],a=n.keyframes[n.keyframes.length-1],o={done:!1,value:s},{stiffness:u,damping:d,mass:l,duration:c,velocity:f,isResolvedFromDuration:h}=Sf({...n,velocity:-Le(n.velocity||0)}),m=f||0,b=d/(2*Math.sqrt(u*l)),w=a-s,v=Le(Math.sqrt(u/l)),I=Math.abs(w)<5;r||(r=I?fe.restSpeed.granular:fe.restSpeed.default),i||(i=I?fe.restDelta.granular:fe.restDelta.default);let S;if(b<1){const P=Lr(v,b);S=A=>{const O=Math.exp(-b*v*A);return a-O*((m+b*v*w)/P*Math.sin(P*A)+w*Math.cos(P*A))}}else if(b===1)S=P=>a-Math.exp(-v*P)*(w+(m+v*w)*P);else{const P=v*Math.sqrt(b*b-1);S=A=>{const O=Math.exp(-b*v*A),p=Math.min(P*A,300);return a-O*((m+b*v*w)*Math.sinh(p)+P*w*Math.cosh(p))/P}}const E={calculatedDuration:h&&c||null,next:P=>{const A=S(P);if(h)o.done=P>=c;else{let O=P===0?m:0;b<1&&(O=P===0?_e(m):qs(S,P,A));const p=Math.abs(O)<=r,y=Math.abs(a-A)<=i;o.done=p&&y}return o.value=o.done?a:A,o},toString:()=>{const P=Math.min(jr(E),jn),A=Xs(O=>E.next(P*O).value,P,30);return P+"ms "+A},toTransition:()=>{}};return E}Fn.applyToOptions=e=>{const t=gf(e,100,Fn);return e.ease=t.ease,e.duration=_e(t.duration),e.type="keyframes",e};function Or({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:s=500,modifyTarget:a,min:o,max:u,restDelta:d=.5,restSpeed:l}){const c=e[0],f={done:!1,value:c},h=p=>o!==void 0&&p<o||u!==void 0&&p>u,m=p=>o===void 0?u:u===void 0||Math.abs(o-p)<Math.abs(u-p)?o:u;let b=n*t;const w=c+b,v=a===void 0?w:a(w);v!==w&&(b=v-c);const I=p=>-b*Math.exp(-p/r),S=p=>v+I(p),E=p=>{const y=I(p),T=S(p);f.done=Math.abs(y)<=d,f.value=f.done?v:T};let P,A;const O=p=>{h(f.value)&&(P=p,A=Fn({keyframes:[f.value,m(f.value)],velocity:qs(S,p,f.value),damping:i,stiffness:s,restDelta:d,restSpeed:l}))};return O(0),{calculatedDuration:null,next:p=>{let y=!1;return!A&&P===void 0&&(y=!0,E(p),O(p)),P!==void 0&&p>=P?A.next(p-P):(!y&&E(p),f)}}}function Tf(e,t,n){const r=[],i=n||Qe.mix||Ks,s=e.length-1;for(let a=0;a<s;a++){let o=i(e[a],e[a+1]);if(t){const u=Array.isArray(t)?t[a]||Fe:t;o=Qt(u,o)}r.push(o)}return r}function Pf(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const s=e.length;if(qe(s===t.length,"Both input and output ranges must be the same length","range-length"),s===1)return()=>t[0];if(s===2&&t[0]===t[1])return()=>t[1];const a=e[0]===e[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const o=Tf(t,r,i),u=o.length,d=l=>{if(a&&l<e[0])return t[0];let c=0;if(u>1)for(;c<e.length-2&&!(l<e[c+1]);c++);const f=Zt(e[c],e[c+1],l);return o[c](f)};return n?l=>d(Xe(e[0],e[s-1],l)):d}function Cf(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=Zt(0,t,r);e.push(ce(n,1,i))}}function Ef(e){const t=[0];return Cf(t,e.length-1),t}function If(e,t){return e.map(n=>n*t)}function kf(e,t){return e.map(()=>t||Ds).splice(0,e.length-1)}function Dt({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=Uc(r)?r.map(Ls):Ls(r),s={done:!1,value:t[0]},a=If(n&&n.length===t.length?n:Ef(t),e),o=Pf(a,t,{ease:Array.isArray(i)?i:kf(t,i)});return{calculatedDuration:e,next:u=>(s.value=o(u),s.done=u>=e,s)}}const Mf=e=>e!==null;function Rr(e,{repeat:t,repeatType:n="loop"},r,i=1){const s=e.filter(Mf),o=i<0||t&&n!=="loop"&&t%2===1?0:s.length-1;return!o||r===void 0?s[o]:r}const Df={decay:Or,inertia:Or,tween:Dt,keyframes:Dt,spring:Fn};function Zs(e){typeof e.type=="string"&&(e.type=Df[e.type])}class _r{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const jf=e=>e/100;class Vr extends _r{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{const{motionValue:n}=this.options;n&&n.updatedAt!==Ee.now()&&this.tick(Ee.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;Zs(t);const{type:n=Dt,repeat:r=0,repeatDelay:i=0,repeatType:s,velocity:a=0}=t;let{keyframes:o}=t;const u=n||Dt;process.env.NODE_ENV!=="production"&&u!==Dt&&qe(o.length<=2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${o}`,"spring-two-frames"),u!==Dt&&typeof o[0]!="number"&&(this.mixKeyframes=Qt(jf,Ks(o[0],o[1])),o=[0,100]);const d=u({...t,keyframes:o});s==="mirror"&&(this.mirroredGenerator=u({...t,keyframes:[...o].reverse(),velocity:-a})),d.calculatedDuration===null&&(d.calculatedDuration=jr(d));const{calculatedDuration:l}=d;this.calculatedDuration=l,this.resolvedDuration=l+i,this.totalDuration=this.resolvedDuration*(r+1)-i,this.generator=d}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:i,mixKeyframes:s,mirroredGenerator:a,resolvedDuration:o,calculatedDuration:u}=this;if(this.startTime===null)return r.next(0);const{delay:d=0,keyframes:l,repeat:c,repeatType:f,repeatDelay:h,type:m,onUpdate:b,finalKeyframe:w}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const v=this.currentTime-d*(this.playbackSpeed>=0?1:-1),I=this.playbackSpeed>=0?v<0:v>i;this.currentTime=Math.max(v,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let S=this.currentTime,E=r;if(c){const p=Math.min(this.currentTime,i)/o;let y=Math.floor(p),T=p%1;!T&&p>=1&&(T=1),T===1&&y--,y=Math.min(y,c+1),y%2&&(f==="reverse"?(T=1-T,h&&(T-=h/o)):f==="mirror"&&(E=a)),S=Xe(0,1,T)*o}const P=I?{done:!1,value:l[0]}:E.next(S);s&&(P.value=s(P.value));let{done:A}=P;!I&&u!==null&&(A=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const O=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&A);return O&&m!==Or&&(P.value=Rr(l,this.options,w,this.speed)),b&&b(P.value),O&&this.finish(),P}then(t,n){return this.finished.then(t,n)}get duration(){return Le(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Le(t)}get time(){return Le(this.currentTime)}set time(t){t=_e(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(Ee.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=Le(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=pf,startTime:n}=this.options;this.driver||(this.driver=t(i=>this.tick(i))),this.options.onPlay?.();const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(Ee.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}function Ff(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const pt=e=>e*180/Math.PI,Nr=e=>{const t=pt(Math.atan2(e[1],e[0]));return Ur(t)},Lf={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Nr,rotateZ:Nr,skewX:e=>pt(Math.atan(e[1])),skewY:e=>pt(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},Ur=e=>(e=e%360,e<0&&(e+=360),e),Js=Nr,ea=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),ta=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Of={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:ea,scaleY:ta,scale:e=>(ea(e)+ta(e))/2,rotateX:e=>Ur(pt(Math.atan2(e[6],e[5]))),rotateY:e=>Ur(pt(Math.atan2(-e[2],e[0]))),rotateZ:Js,rotate:Js,skewX:e=>pt(Math.atan(e[4])),skewY:e=>pt(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function Br(e){return e.includes("scale")?1:0}function zr(e,t){if(!e||e==="none")return Br(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,i;if(n)r=Of,i=n;else{const o=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=Lf,i=o}if(!i)return Br(t);const s=r[t],a=i[1].split(",").map(_f);return typeof s=="function"?s(a):a[s]}const Rf=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return zr(n,t)};function _f(e){return parseFloat(e.trim())}const jt=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Ft=new Set(jt),na=e=>e===kt||e===q,Vf=new Set(["x","y","z"]),Nf=jt.filter(e=>!Vf.has(e));function Uf(e){const t=[];return Nf.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const gt={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>zr(t,"x"),y:(e,{transform:t})=>zr(t,"y")};gt.translateX=gt.x,gt.translateY=gt.y;const yt=new Set;let $r=!1,Wr=!1,Hr=!1;function ra(){if(Wr){const e=Array.from(yt).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=Uf(r);i.length&&(n.set(r,i),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const i=n.get(r);i&&i.forEach(([s,a])=>{r.getValue(s)?.set(a)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Wr=!1,$r=!1,yt.forEach(e=>e.complete(Hr)),yt.clear()}function ia(){yt.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Wr=!0)})}function Bf(){Hr=!0,ia(),ra(),Hr=!1}class Yr{constructor(t,n,r,i,s,a=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=s,this.isAsync=a}scheduleResolve(){this.state="scheduled",this.isAsync?(yt.add(this),$r||($r=!0,oe.read(ia),oe.resolveKeyframes(ra))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;if(t[0]===null){const s=i?.get(),a=t[t.length-1];if(s!==void 0)t[0]=s;else if(r&&n){const o=r.readValue(n,a);o!=null&&(t[0]=o)}t[0]===void 0&&(t[0]=a),i&&s===void 0&&i.set(t[0])}Ff(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),yt.delete(this)}cancel(){this.state==="scheduled"&&(yt.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const zf=e=>e.startsWith("--");function $f(e,t,n){zf(t)?e.style.setProperty(t,n):e.style[t]=n}const Wf=yr(()=>window.ScrollTimeline!==void 0),Hf={};function Yf(e,t){const n=yr(e);return()=>Hf[t]??n()}const sa=Yf(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),sn=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,aa={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:sn([0,.65,.55,1]),circOut:sn([.55,0,1,.45]),backIn:sn([.31,.01,.66,-.59]),backOut:sn([.33,1.53,.69,.99])};function oa(e,t){if(e)return typeof e=="function"?sa()?Xs(e,t):"ease-out":js(e)?sn(e):Array.isArray(e)?e.map(n=>oa(n,t)||aa.easeOut):aa[e]}function Gf(e,t,n,{delay:r=0,duration:i=300,repeat:s=0,repeatType:a="loop",ease:o="easeOut",times:u}={},d=void 0){const l={[t]:n};u&&(l.offset=u);const c=oa(o,i);Array.isArray(c)&&(l.easing=c);const f={delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:s+1,direction:a==="reverse"?"alternate":"normal"};return d&&(f.pseudoElement=d),e.animate(l,f)}function la(e){return typeof e=="function"&&"applyToOptions"in e}function Kf({type:e,...t}){return la(e)&&sa()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class Xf extends _r{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;const{element:n,name:r,keyframes:i,pseudoElement:s,allowFlatten:a=!1,finalKeyframe:o,onComplete:u}=t;this.isPseudoElement=!!s,this.allowFlatten=a,this.options=t,qe(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const d=Kf(t);this.animation=Gf(n,r,i,d,s),d.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!s){const l=Rr(i,this.options,o,this.speed);this.updateMotionValue?this.updateMotionValue(l):$f(n,r,l),this.animation.cancel()}u?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return Le(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Le(t)}get time(){return Le(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=_e(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&Wf()?(this.animation.timeline=t,Fe):n(this)}}const ua={anticipate:Is,backInOut:Es,circInOut:Ms};function qf(e){return e in ua}function Qf(e){typeof e.ease=="string"&&qf(e.ease)&&(e.ease=ua[e.ease])}const ca=10;class Zf extends Xf{constructor(t){Qf(t),Zs(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:i,element:s,...a}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const o=new Vr({...a,autoplay:!1}),u=_e(this.finishedTime??this.time);n.setWithVelocity(o.sample(u-ca).value,o.sample(u).value,ca),o.stop()}}const fa=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(at.test(e)||e==="0")&&!e.startsWith("url("));function Jf(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function ed(e,t,n,r){const i=e[0];if(i===null)return!1;if(t==="display"||t==="visibility")return!0;const s=e[e.length-1],a=fa(i,t),o=fa(s,t);return It(a===o,`You are trying to animate ${t} from "${i}" to "${s}". "${a?s:i}" is not an animatable value.`,"value-not-animatable"),!a||!o?!1:Jf(e)||(n==="spring"||la(n))&&r}function Gr(e){e.duration=0,e.type="keyframes"}const td=new Set(["opacity","clipPath","filter","transform"]),nd=yr(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function rd(e){const{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:s,type:a}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;const{onUpdate:u,transformTemplate:d}=t.owner.getProps();return nd()&&n&&td.has(n)&&(n!=="transform"||!d)&&!u&&!r&&i!=="mirror"&&s!==0&&a!=="inertia"}const id=40;class sd extends _r{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:s=0,repeatType:a="loop",keyframes:o,name:u,motionValue:d,element:l,...c}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=Ee.now();const f={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:s,repeatType:a,name:u,motionValue:d,element:l,...c},h=l?.KeyframeResolver||Yr;this.keyframeResolver=new h(o,(m,b,w)=>this.onKeyframesResolved(m,b,f,!w),u,d,l),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,n,r,i){this.keyframeResolver=void 0;const{name:s,type:a,velocity:o,delay:u,isHandoff:d,onUpdate:l}=r;this.resolvedAt=Ee.now(),ed(t,s,a,o)||((Qe.instantAnimations||!u)&&l?.(Rr(t,r,n)),t[0]=t[t.length-1],Gr(r),r.repeat=0);const f={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>id?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},h=!d&&rd(f)?new Zf({...f,element:f.motionValue.owner.current}):new Vr(f);h.finished.then(()=>this.notifyFinished()).catch(Fe),this.pendingTimeline&&(this.stopTimeline=h.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=h}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Bf()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}const ad=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function od(e){const t=ad.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}const ld=4;function da(e,t,n=1){qe(n<=ld,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[r,i]=od(e);if(!r)return;const s=window.getComputedStyle(t).getPropertyValue(r);if(s){const a=s.trim();return vs(a)?parseFloat(a):a}return Sr(i)?da(i,t,n+1):i}function Kr(e,t){return e?.[t]??e?.default??e}const ha=new Set(["width","height","top","left","right","bottom",...jt]),ud={test:e=>e==="auto",parse:e=>e},ma=e=>t=>t.test(e),pa=[kt,q,We,st,Zc,Qc,ud],ga=e=>pa.find(ma(e));function cd(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||xs(e):!0}const fd=new Set(["brightness","contrast","saturate","opacity"]);function dd(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Tr)||[];if(!r)return e;const i=n.replace(r,"");let s=fd.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+i+")"}const hd=/\b([a-z-]*)\(.*?\)/gu,Xr={...at,getAnimatableNone:e=>{const t=e.match(hd);return t?t.map(dd).join(" "):e}},ya={...kt,transform:Math.round},qr={borderWidth:q,borderTopWidth:q,borderRightWidth:q,borderBottomWidth:q,borderLeftWidth:q,borderRadius:q,radius:q,borderTopLeftRadius:q,borderTopRightRadius:q,borderBottomRightRadius:q,borderBottomLeftRadius:q,width:q,maxWidth:q,height:q,maxHeight:q,top:q,right:q,bottom:q,left:q,padding:q,paddingTop:q,paddingRight:q,paddingBottom:q,paddingLeft:q,margin:q,marginTop:q,marginRight:q,marginBottom:q,marginLeft:q,backgroundPositionX:q,backgroundPositionY:q,...{rotate:st,rotateX:st,rotateY:st,rotateZ:st,scale:Mn,scaleX:Mn,scaleY:Mn,scaleZ:Mn,skew:st,skewX:st,skewY:st,distance:q,translateX:q,translateY:q,translateZ:q,x:q,y:q,z:q,perspective:q,transformPerspective:q,opacity:en,originX:Ns,originY:Ns,originZ:q},zIndex:ya,fillOpacity:en,strokeOpacity:en,numOctaves:ya},md={...qr,color:de,backgroundColor:de,outlineColor:de,fill:de,stroke:de,borderColor:de,borderTopColor:de,borderRightColor:de,borderBottomColor:de,borderLeftColor:de,filter:Xr,WebkitFilter:Xr},va=e=>md[e];function ba(e,t){let n=va(e);return n!==Xr&&(n=at),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const pd=new Set(["auto","none","0"]);function gd(e,t,n){let r=0,i;for(;r<e.length&&!i;){const s=e[r];typeof s=="string"&&!pd.has(s)&&rn(s).values.length&&(i=e[r]),r++}if(i&&n)for(const s of t)e[s]=ba(n,i)}class yd extends Yr{constructor(t,n,r,i,s){super(t,n,r,i,s,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let u=0;u<t.length;u++){let d=t[u];if(typeof d=="string"&&(d=d.trim(),Sr(d))){const l=da(d,n.current);l!==void 0&&(t[u]=l),u===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!ha.has(r)||t.length!==2)return;const[i,s]=t,a=ga(i),o=ga(s);if(a!==o)if(na(a)&&na(o))for(let u=0;u<t.length;u++){const d=t[u];typeof d=="string"&&(t[u]=parseFloat(d))}else gt[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let i=0;i<t.length;i++)(t[i]===null||cd(t[i]))&&r.push(i);r.length&&gd(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=gt[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&t.getValue(r,i).jump(i,!1)}measureEndState(){const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);const s=r.length-1,a=r[s];r[s]=gt[n](t.measureViewportBox(),window.getComputedStyle(t.current)),a!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=a),this.removedTransforms?.length&&this.removedTransforms.forEach(([o,u])=>{t.getValue(o).set(u)}),this.resolveNoneKeyframes()}}function vd(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const i=n?.[e]??r.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e)}const xa=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function wa(e){return bs(e)&&"offsetHeight"in e}const Aa=30,bd=e=>!isNaN(parseFloat(e));class xd{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{const i=Ee.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const s of this.dependents)s.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Ee.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=bd(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&br(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new vr);const r=this.events[t].add(n);return t==="change"?()=>{r(),oe.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=Ee.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Aa)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Aa);return ws(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Lt(e,t){return new xd(e,t)}const{schedule:Qr}=Os(queueMicrotask,!1),Ve={x:!1,y:!1};function Sa(){return Ve.x||Ve.y}function wd(e){return e==="x"||e==="y"?Ve[e]?null:(Ve[e]=!0,()=>{Ve[e]=!1}):Ve.x||Ve.y?null:(Ve.x=Ve.y=!0,()=>{Ve.x=Ve.y=!1})}function Ta(e,t){const n=vd(e),r=new AbortController,i={passive:!0,...t,signal:r.signal};return[n,i,()=>r.abort()]}function Pa(e){return!(e.pointerType==="touch"||Sa())}function Ad(e,t,n={}){const[r,i,s]=Ta(e,n),a=o=>{if(!Pa(o))return;const{target:u}=o,d=t(u,o);if(typeof d!="function"||!u)return;const l=c=>{Pa(c)&&(d(c),u.removeEventListener("pointerleave",l))};u.addEventListener("pointerleave",l,i)};return r.forEach(o=>{o.addEventListener("pointerenter",a,i)}),s}const Ca=(e,t)=>t?e===t?!0:Ca(e,t.parentElement):!1,Zr=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Sd=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Td(e){return Sd.has(e.tagName)||e.tabIndex!==-1}const Ln=new WeakSet;function Ea(e){return t=>{t.key==="Enter"&&e(t)}}function Jr(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Pd=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=Ea(()=>{if(Ln.has(n))return;Jr(n,"down");const i=Ea(()=>{Jr(n,"up")}),s=()=>Jr(n,"cancel");n.addEventListener("keyup",i,t),n.addEventListener("blur",s,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function Ia(e){return Zr(e)&&!Sa()}function Cd(e,t,n={}){const[r,i,s]=Ta(e,n),a=o=>{const u=o.currentTarget;if(!Ia(o))return;Ln.add(u);const d=t(u,o),l=(h,m)=>{window.removeEventListener("pointerup",c),window.removeEventListener("pointercancel",f),Ln.has(u)&&Ln.delete(u),Ia(h)&&typeof d=="function"&&d(h,{success:m})},c=h=>{l(h,u===window||u===document||n.useGlobalTarget||Ca(u,h.target))},f=h=>{l(h,!1)};window.addEventListener("pointerup",c,i),window.addEventListener("pointercancel",f,i)};return r.forEach(o=>{(n.useGlobalTarget?window:o).addEventListener("pointerdown",a,i),wa(o)&&(o.addEventListener("focus",d=>Pd(d,i)),!Td(o)&&!o.hasAttribute("tabindex")&&(o.tabIndex=0))}),s}function ka(e){return bs(e)&&"ownerSVGElement"in e}function Ed(e){return ka(e)&&e.tagName==="svg"}const xe=e=>!!(e&&e.getVelocity),Id=[...pa,de,at],kd=e=>Id.find(ma(e)),ei=z.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function Ma(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Md(...e){return t=>{let n=!1;const r=e.map(i=>{const s=Ma(i,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let i=0;i<r.length;i++){const s=r[i];typeof s=="function"?s():Ma(e[i],null)}}}}function Dd(...e){return Tn.useCallback(Md(...e),e)}class jd extends Tn.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=n.offsetParent,i=wa(r)&&r.offsetWidth||0,s=this.props.sizeRef.current;s.height=n.offsetHeight||0,s.width=n.offsetWidth||0,s.top=n.offsetTop,s.left=n.offsetLeft,s.right=i-s.width-s.left}return null}componentDidUpdate(){}render(){return this.props.children}}function Fd({children:e,isPresent:t,anchorX:n,root:r}){const i=z.useId(),s=z.useRef(null),a=z.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:o}=z.useContext(ei),u=Dd(s,e?.ref);return z.useInsertionEffect(()=>{const{width:d,height:l,top:c,left:f,right:h}=a.current;if(t||!s.current||!d||!l)return;const m=n==="left"?`left: ${f}`:`right: ${h}`;s.current.dataset.motionPopId=i;const b=document.createElement("style");o&&(b.nonce=o);const w=r??document.head;return w.appendChild(b),b.sheet&&b.sheet.insertRule(`
7
7
  [data-motion-pop-id="${i}"] {
8
8
  position: absolute !important;
9
9
  width: ${d}px !important;
@@ -11,10 +11,10 @@ React keys must be passed directly to JSX without using spread:
11
11
  ${m}px !important;
12
12
  top: ${c}px !important;
13
13
  }
14
- `),()=>{w.contains(b)&&w.removeChild(b)}},[t]),D.jsx(jd,{isPresent:t,childRef:s,sizeRef:a,children:Tn.cloneElement(e,{ref:u})})}const Ld=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:s,mode:a,anchorX:o,root:u})=>{const d=dr(Od),l=z.useId();let c=!0,f=z.useMemo(()=>(c=!1,{id:l,initial:t,isPresent:n,custom:i,onExitComplete:h=>{d.set(h,!0);for(const m of d.values())if(!m)return;r&&r()},register:h=>(d.set(h,!1),()=>d.delete(h))}),[n,d,r]);return s&&c&&(f={...f}),z.useMemo(()=>{d.forEach((h,m)=>d.set(m,!1))},[n]),Tn.useEffect(()=>{!n&&!d.size&&r&&r()},[n]),a==="popLayout"&&(e=D.jsx(Fd,{isPresent:n,anchorX:o,root:u,children:e})),D.jsx(En.Provider,{value:f,children:e})};function Od(){return new Map}function Da(e=!0){const t=z.useContext(En);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:i}=t,s=z.useId();z.useEffect(()=>{if(e)return i(s)},[e]);const a=z.useCallback(()=>e&&r&&r(s),[s,r,e]);return!n&&r?[!1,a]:[!0]}const On=e=>e.key||"";function ja(e){const t=[];return z.Children.forEach(e,n=>{z.isValidElement(n)&&t.push(n)}),t}const Rd=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:i=!0,mode:s="sync",propagate:a=!1,anchorX:o="left",root:u})=>{const[d,l]=Da(a),c=z.useMemo(()=>ja(e),[e]),f=a&&!d?[]:c.map(On),h=z.useRef(!0),m=z.useRef(c),b=dr(()=>new Map),[w,v]=z.useState(c),[I,S]=z.useState(c);ys(()=>{h.current=!1,m.current=c;for(let A=0;A<I.length;A++){const O=On(I[A]);f.includes(O)?b.delete(O):b.get(O)!==!0&&b.set(O,!1)}},[I,f.length,f.join("-")]);const E=[];if(c!==w){let A=[...c];for(let O=0;O<I.length;O++){const p=I[O],y=On(p);f.includes(y)||(A.splice(O,0,p),E.push(p))}return s==="wait"&&E.length&&(A=E),S(ja(A)),v(c),null}process.env.NODE_ENV!=="production"&&s==="wait"&&I.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`);const{forceRender:P}=z.useContext(fr);return D.jsx(D.Fragment,{children:I.map(A=>{const O=On(A),p=a&&!d?!1:c===I||f.includes(O),y=()=>{if(b.has(O))b.set(O,!0);else return;let T=!0;b.forEach(k=>{k||(T=!1)}),T&&(P?.(),S(m.current),a&&l?.(),r&&r())};return D.jsx(Ld,{isPresent:p,initial:!h.current||n?void 0:!1,custom:t,presenceAffectsLayout:i,mode:s,root:u,onExitComplete:p?void 0:y,anchorX:o,children:A},O)})})},Fa=z.createContext({strict:!1}),La={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Ot={};for(const e in La)Ot[e]={isEnabled:t=>La[e].some(n=>!!t[n])};function _d(e){for(const t in e)Ot[t]={...Ot[t],...e[t]}}const Vd=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Rn(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Vd.has(e)}let Oa=e=>!Rn(e);function Nd(e){typeof e=="function"&&(Oa=t=>t.startsWith("on")?!Rn(t):e(t))}try{Nd(require("@emotion/is-prop-valid").default)}catch{}function Ud(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(Oa(i)||n===!0&&Rn(i)||!t&&!Rn(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}const _n=z.createContext({});function Vn(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function an(e){return typeof e=="string"||Array.isArray(e)}const ti=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],ni=["initial",...ti];function Nn(e){return Vn(e.animate)||ni.some(t=>an(e[t]))}function Ra(e){return!!(Nn(e)||e.variants)}function Bd(e,t){if(Nn(e)){const{initial:n,animate:r}=e;return{initial:n===!1||an(n)?n:void 0,animate:an(r)?r:void 0}}return e.inherit!==!1?t:{}}function zd(e){const{initial:t,animate:n}=Bd(e,z.useContext(_n));return z.useMemo(()=>({initial:t,animate:n}),[_a(t),_a(n)])}function _a(e){return Array.isArray(e)?e.join(" "):e}function Va(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const on={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(Q.test(e))e=parseFloat(e);else return e;const n=Va(e,t.target.x),r=Va(e,t.target.y);return`${n}% ${r}%`}},$d={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=at.parse(e);if(i.length>5)return r;const s=at.createTransformer(e),a=typeof i[0]!="number"?1:0,o=n.x.scale*t.x,u=n.y.scale*t.y;i[0+a]/=o,i[1+a]/=u;const d=ue(o,u,.5);return typeof i[2+a]=="number"&&(i[2+a]/=d),typeof i[3+a]=="number"&&(i[3+a]/=d),s(i)}},ri={borderRadius:{...on,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:on,borderTopRightRadius:on,borderBottomLeftRadius:on,borderBottomRightRadius:on,boxShadow:$d};function Na(e,{layout:t,layoutId:n}){return Ft.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!ri[e]||e==="opacity")}const Wd={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Hd=jt.length;function Yd(e,t,n){let r="",i=!0;for(let s=0;s<Hd;s++){const a=jt[s],o=e[a];if(o===void 0)continue;let u=!0;if(typeof o=="number"?u=o===(a.startsWith("scale")?1:0):u=parseFloat(o)===0,!u||n){const d=xa(o,qr[a]);if(!u){i=!1;const l=Wd[a]||a;r+=`${l}(${d}) `}n&&(t[a]=d)}}return r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}function ii(e,t,n){const{style:r,vars:i,transformOrigin:s}=e;let a=!1,o=!1;for(const u in t){const d=t[u];if(Ft.has(u)){a=!0;continue}else if(_s(u)){i[u]=d;continue}else{const l=xa(d,qr[u]);u.startsWith("origin")?(o=!0,s[u]=l):r[u]=l}}if(t.transform||(a||n?r.transform=Yd(t,e.transform,n):r.transform&&(r.transform="none")),o){const{originX:u="50%",originY:d="50%",originZ:l=0}=s;r.transformOrigin=`${u} ${d} ${l}`}}const si=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Ua(e,t,n){for(const r in t)!be(t[r])&&!Na(r,n)&&(e[r]=t[r])}function Gd({transformTemplate:e},t){return z.useMemo(()=>{const n=si();return ii(n,t,e),Object.assign({},n.vars,n.style)},[t])}function Kd(e,t){const n=e.style||{},r={};return Ua(r,n,e),Object.assign(r,Gd(e,t)),r}function Xd(e,t){const n={},r=Kd(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const qd={offset:"stroke-dashoffset",array:"stroke-dasharray"},Qd={offset:"strokeDashoffset",array:"strokeDasharray"};function Zd(e,t,n=1,r=0,i=!0){e.pathLength=1;const s=i?qd:Qd;e[s.offset]=Q.transform(-r);const a=Q.transform(t),o=Q.transform(n);e[s.array]=`${a} ${o}`}function Ba(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:s=1,pathOffset:a=0,...o},u,d,l){if(ii(e,o,d),u){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:c,style:f}=e;c.transform&&(f.transform=c.transform,delete c.transform),(f.transform||c.transformOrigin)&&(f.transformOrigin=c.transformOrigin??"50% 50%",delete c.transformOrigin),f.transform&&(f.transformBox=l?.transformBox??"fill-box",delete c.transformBox),t!==void 0&&(c.x=t),n!==void 0&&(c.y=n),r!==void 0&&(c.scale=r),i!==void 0&&Zd(c,i,s,a,!1)}const za=()=>({...si(),attrs:{}}),$a=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Jd(e,t,n,r){const i=z.useMemo(()=>{const s=za();return Ba(s,t,$a(r),e.transformTemplate,e.style),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};Ua(s,e.style,e),i.style={...s,...i.style}}return i}const eh=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function ai(e){return typeof e!="string"||e.includes("-")?!1:!!(eh.indexOf(e)>-1||/[A-Z]/u.test(e))}function th(e,t,n,{latestValues:r},i,s=!1){const o=(ai(e)?Jd:Xd)(t,r,i,e),u=Ud(t,typeof e=="string",s),d=e!==z.Fragment?{...u,...o,ref:n}:{},{children:l}=t,c=z.useMemo(()=>be(l)?l.get():l,[l]);return z.createElement(e,{...d,children:c})}function Wa(e){const t=[{},{}];return e?.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function oi(e,t,n,r){if(typeof t=="function"){const[i,s]=Wa(r);t=t(n!==void 0?n:e.custom,i,s)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,s]=Wa(r);t=t(n!==void 0?n:e.custom,i,s)}return t}function Un(e){return be(e)?e.get():e}function nh({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:rh(n,r,i,e),renderState:t()}}function rh(e,t,n,r){const i={},s=r(e,{});for(const f in s)i[f]=Un(s[f]);let{initial:a,animate:o}=e;const u=Nn(e),d=Ra(e);t&&d&&!u&&e.inherit!==!1&&(a===void 0&&(a=t.initial),o===void 0&&(o=t.animate));let l=n?n.initial===!1:!1;l=l||a===!1;const c=l?o:a;if(c&&typeof c!="boolean"&&!Vn(c)){const f=Array.isArray(c)?c:[c];for(let h=0;h<f.length;h++){const m=oi(e,f[h]);if(m){const{transitionEnd:b,transition:w,...v}=m;for(const I in v){let S=v[I];if(Array.isArray(S)){const E=l?S.length-1:0;S=S[E]}S!==null&&(i[I]=S)}for(const I in b)i[I]=b[I]}}}return i}const Ha=e=>(t,n)=>{const r=z.useContext(_n),i=z.useContext(En),s=()=>nh(e,t,r,i);return n?s():dr(s)};function li(e,t,n){const{style:r}=e,i={};for(const s in r)(be(r[s])||t.style&&be(t.style[s])||Na(s,e)||n?.getValue(s)?.liveStyle!==void 0)&&(i[s]=r[s]);return i}const ih=Ha({scrapeMotionValuesFromProps:li,createRenderState:si});function Ya(e,t,n){const r=li(e,t,n);for(const i in e)if(be(e[i])||be(t[i])){const s=jt.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[s]=e[i]}return r}const sh=Ha({scrapeMotionValuesFromProps:Ya,createRenderState:za}),ah=Symbol.for("motionComponentSymbol");function Rt(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function oh(e,t,n){return z.useCallback(r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):Rt(n)&&(n.current=r))},[t])}const ui=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),Ga="data-"+ui("framerAppearId"),Ka=z.createContext({});function lh(e,t,n,r,i){const{visualElement:s}=z.useContext(_n),a=z.useContext(Fa),o=z.useContext(En),u=z.useContext(ei).reducedMotion,d=z.useRef(null);r=r||a.renderer,!d.current&&r&&(d.current=r(e,{visualState:t,parent:s,props:n,presenceContext:o,blockInitialAnimation:o?o.initial===!1:!1,reducedMotionConfig:u}));const l=d.current,c=z.useContext(Ka);l&&!l.projection&&i&&(l.type==="html"||l.type==="svg")&&uh(d.current,n,i,c);const f=z.useRef(!1);z.useInsertionEffect(()=>{l&&f.current&&l.update(n,o)});const h=n[Ga],m=z.useRef(!!h&&!window.MotionHandoffIsComplete?.(h)&&window.MotionHasOptimisedAnimation?.(h));return ys(()=>{l&&(f.current=!0,window.MotionIsMounted=!0,l.updateFeatures(),l.scheduleRenderMicrotask(),m.current&&l.animationState&&l.animationState.animateChanges())}),z.useEffect(()=>{l&&(!m.current&&l.animationState&&l.animationState.animateChanges(),m.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(h)}),m.current=!1),l.enteringChildren=void 0)}),l}function uh(e,t,n,r){const{layoutId:i,layout:s,drag:a,dragConstraints:o,layoutScroll:u,layoutRoot:d,layoutCrossfade:l}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Xa(e.parent)),e.projection.setOptions({layoutId:i,layout:s,alwaysMeasureLayout:!!a||o&&Rt(o),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:r,crossfade:l,layoutScroll:u,layoutRoot:d})}function Xa(e){if(e)return e.options.allowProjection!==!1?e.projection:Xa(e.parent)}function ci(e,{forwardMotionProps:t=!1}={},n,r){n&&_d(n);const i=ai(e)?sh:ih;function s(o,u){let d;const l={...z.useContext(ei),...o,layoutId:ch(o)},{isStatic:c}=l,f=zd(o),h=i(o,c);if(!c&&hr){fh(l,n);const m=dh(l);d=m.MeasureLayout,f.visualElement=lh(e,h,l,r,m.ProjectionNode)}return D.jsxs(_n.Provider,{value:f,children:[d&&f.visualElement?D.jsx(d,{visualElement:f.visualElement,...l}):null,th(e,o,oh(h,f.visualElement,u),h,c,t)]})}s.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const a=z.forwardRef(s);return a[ah]=e,a}function ch({layoutId:e}){const t=z.useContext(fr).id;return t&&e!==void 0?t+"-"+e:e}function fh(e,t){const n=z.useContext(Fa).strict;if(process.env.NODE_ENV!=="production"&&t&&n){const r="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?It(!1,r,"lazy-strict-mode"):qe(!1,r,"lazy-strict-mode")}}function dh(e){const{drag:t,layout:n}=Ot;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t?.isEnabled(e)||n?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function hh(e,t){if(typeof Proxy>"u")return ci;const n=new Map,r=(s,a)=>ci(s,a,e,t),i=(s,a)=>(process.env.NODE_ENV!=="production"&&br(!1,"motion() is deprecated. Use motion.create() instead."),r(s,a));return new Proxy(i,{get:(s,a)=>a==="create"?r:(n.has(a)||n.set(a,ci(a,void 0,e,t)),n.get(a))})}function qa({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function mh({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function ph(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function fi(e){return e===void 0||e===1}function di({scale:e,scaleX:t,scaleY:n}){return!fi(e)||!fi(t)||!fi(n)}function vt(e){return di(e)||Qa(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Qa(e){return Za(e.x)||Za(e.y)}function Za(e){return e&&e!=="0%"}function Bn(e,t,n){const r=e-n,i=t*r;return n+i}function Ja(e,t,n,r,i){return i!==void 0&&(e=Bn(e,i,r)),Bn(e,n,r)+t}function hi(e,t=0,n=1,r,i){e.min=Ja(e.min,t,n,r,i),e.max=Ja(e.max,t,n,r,i)}function eo(e,{x:t,y:n}){hi(e.x,t.translate,t.scale,t.originPoint),hi(e.y,n.translate,n.scale,n.originPoint)}const to=.999999999999,no=1.0000000000001;function gh(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let s,a;for(let o=0;o<i;o++){s=n[o],a=s.projectionDelta;const{visualElement:u}=s.options;u&&u.props.style&&u.props.style.display==="contents"||(r&&s.options.layoutScroll&&s.scroll&&s!==s.root&&Vt(e,{x:-s.scroll.offset.x,y:-s.scroll.offset.y}),a&&(t.x*=a.x.scale,t.y*=a.y.scale,eo(e,a)),r&&vt(s.latestValues)&&Vt(e,s.latestValues))}t.x<no&&t.x>to&&(t.x=1),t.y<no&&t.y>to&&(t.y=1)}function _t(e,t){e.min=e.min+t,e.max=e.max+t}function ro(e,t,n,r,i=.5){const s=ue(e.min,e.max,i);hi(e,t,n,s,r)}function Vt(e,t){ro(e.x,t.x,t.scaleX,t.scale,t.originX),ro(e.y,t.y,t.scaleY,t.scale,t.originY)}function io(e,t){return qa(ph(e.getBoundingClientRect(),t))}function yh(e,t,n){const r=io(e,n),{scroll:i}=t;return i&&(_t(r.x,i.offset.x),_t(r.y,i.offset.y)),r}const so=()=>({translate:0,scale:1,origin:0,originPoint:0}),Nt=()=>({x:so(),y:so()}),ao=()=>({min:0,max:0}),me=()=>({x:ao(),y:ao()}),mi={current:null},oo={current:!1};function vh(){if(oo.current=!0,!!hr)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>mi.current=e.matches;e.addEventListener("change",t),t()}else mi.current=!1}const bh=new WeakMap;function xh(e,t,n){for(const r in t){const i=t[r],s=n[r];if(be(i))e.addValue(r,i);else if(be(s))e.addValue(r,Lt(i,{owner:e}));else if(s!==i)if(e.hasValue(r)){const a=e.getValue(r);a.liveStyle===!0?a.jump(i):a.hasAnimated||a.set(i)}else{const a=e.getStaticValue(r);e.addValue(r,Lt(a!==void 0?a:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const lo=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class wh{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,blockInitialAnimation:s,visualState:a},o={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Yr,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const f=Ee.now();this.renderScheduledAt<f&&(this.renderScheduledAt=f,oe.render(this.render,!1,!0))};const{latestValues:u,renderState:d}=a;this.latestValues=u,this.baseTarget={...u},this.initialValues=n.initial?{...u}:{},this.renderState=d,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=o,this.blockInitialAnimation=!!s,this.isControllingVariants=Nn(n),this.isVariantNode=Ra(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:l,...c}=this.scrapeMotionValuesFromProps(n,{},this);for(const f in c){const h=c[f];u[f]!==void 0&&be(h)&&h.set(u[f])}}mount(t){this.current=t,bh.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),oo.current||vh(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:mi.current,process.env.NODE_ENV!=="production"&&br(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected.","reduced-motion-disabled"),this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),it(this.notifyUpdate),it(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=Ft.has(t);r&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&oe.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),s&&s(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Ot){const n=Ot[t];if(!n)continue;const{isEnabled:r,Feature:i}=n;if(!this.features[t]&&i&&r(this.props)&&(this.features[t]=new i(this)),this.features[t]){const s=this.features[t];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):me()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<lo.length;r++){const i=lo[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const s="on"+i,a=t[s];a&&(this.propEventSubscriptions[i]=this.on(i,a))}this.prevMotionValues=xh(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Lt(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(vs(r)||xs(r))?r=parseFloat(r):!kd(r)&&at.test(n)&&(r=ba(t,n)),this.setBaseTarget(t,be(r)?r.get():r)),be(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const s=oi(this.props,n,this.presenceContext?.custom);s&&(r=s[t])}if(n&&r!==void 0)return r;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!be(i)?i:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new vr),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Qr.render(this.render)}}class uo extends wh{constructor(){super(...arguments),this.KeyframeResolver=yd}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;be(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function co(e,{style:t,vars:n},r,i){const s=e.style;let a;for(a in t)s[a]=t[a];i?.applyProjectionStyles(s,r);for(a in n)s.setProperty(a,n[a])}function Ah(e){return window.getComputedStyle(e)}class Sh extends uo{constructor(){super(...arguments),this.type="html",this.renderInstance=co}readValueFromInstance(t,n){if(Ft.has(n))return this.projection?.isProjecting?Br(n):Rf(t,n);{const r=Ah(t),i=(_s(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return io(t,n)}build(t,n,r){ii(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return li(t,n,r)}}const fo=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function Th(e,t,n,r){co(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(fo.has(i)?i:ui(i),t.attrs[i])}class Ph extends uo{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=me}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Ft.has(n)){const r=va(n);return r&&r.default||0}return n=fo.has(n)?n:ui(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return Ya(t,n,r)}build(t,n,r){Ba(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,i){Th(t,n,r,i)}mount(t){this.isSVGTag=$a(t.tagName),super.mount(t)}}const Ch=(e,t)=>ai(e)?new Ph(t):new Sh(t,{allowProjection:e!==z.Fragment});function Ut(e,t,n){const r=e.getProps();return oi(r,t,n!==void 0?n:r.custom,e)}const pi=e=>Array.isArray(e);function Eh(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Lt(n))}function Ih(e){return pi(e)?e[e.length-1]||0:e}function kh(e,t){const n=Ut(e,t);let{transitionEnd:r={},transition:i={},...s}=n||{};s={...s,...r};for(const a in s){const o=Ih(s[a]);Eh(e,a,o)}}function Mh(e){return!!(be(e)&&e.add)}function gi(e,t){const n=e.getValue("willChange");if(Mh(n))return n.add(t);if(!n&&Qe.WillChange){const r=new Qe.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function ho(e){return e.props[Ga]}const Dh=e=>e!==null;function jh(e,{repeat:t,repeatType:n="loop"},r){const i=e.filter(Dh),s=t&&n!=="loop"&&t%2===1?0:i.length-1;return i[s]}const Fh={type:"spring",stiffness:500,damping:25,restSpeed:10},Lh=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Oh={type:"keyframes",duration:.8},Rh={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},_h=(e,{keyframes:t})=>t.length>2?Oh:Ft.has(e)?e.startsWith("scale")?Lh(t[1]):Fh:Rh;function Vh({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:s,repeatType:a,repeatDelay:o,from:u,elapsed:d,...l}){return!!Object.keys(l).length}const yi=(e,t,n,r={},i,s)=>a=>{const o=Kr(r,e)||{},u=o.delay||r.delay||0;let{elapsed:d=0}=r;d=d-_e(u);const l={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...o,delay:-d,onUpdate:f=>{t.set(f),o.onUpdate&&o.onUpdate(f)},onComplete:()=>{a(),o.onComplete&&o.onComplete()},name:e,motionValue:t,element:s?void 0:i};Vh(o)||Object.assign(l,_h(e,l)),l.duration&&(l.duration=_e(l.duration)),l.repeatDelay&&(l.repeatDelay=_e(l.repeatDelay)),l.from!==void 0&&(l.keyframes[0]=l.from);let c=!1;if((l.type===!1||l.duration===0&&!l.repeatDelay)&&(Gr(l),l.delay===0&&(c=!0)),(Qe.instantAnimations||Qe.skipAnimations)&&(c=!0,Gr(l),l.delay=0),l.allowFlatten=!o.type&&!o.ease,c&&!s&&t.get()!==void 0){const f=jh(l.keyframes,o);if(f!==void 0){oe.update(()=>{l.onUpdate(f),l.onComplete()});return}}return o.isSync?new Vr(l):new sd(l)};function Nh({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function mo(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:a,...o}=t;r&&(s=r);const u=[],d=i&&e.animationState&&e.animationState.getState()[i];for(const l in o){const c=e.getValue(l,e.latestValues[l]??null),f=o[l];if(f===void 0||d&&Nh(d,l))continue;const h={delay:n,...Kr(s||{},l)},m=c.get();if(m!==void 0&&!c.isAnimating&&!Array.isArray(f)&&f===m&&!h.velocity)continue;let b=!1;if(window.MotionHandoffAnimation){const v=ho(e);if(v){const I=window.MotionHandoffAnimation(v,l,oe);I!==null&&(h.startTime=I,b=!0)}}gi(e,l),c.start(yi(l,c,f,e.shouldReduceMotion&&ha.has(l)?{type:!1}:h,e,b));const w=c.animation;w&&u.push(w)}return a&&Promise.all(u).then(()=>{oe.update(()=>{a&&kh(e,a)})}),u}function po(e,t,n,r=0,i=1){const s=Array.from(e).sort((d,l)=>d.sortNodePosition(l)).indexOf(t),a=e.size,o=(a-1)*r;return typeof n=="function"?n(s,a):i===1?s*r:o-s*r}function vi(e,t,n={}){const r=Ut(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const s=r?()=>Promise.all(mo(e,r,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:d=0,staggerChildren:l,staggerDirection:c}=i;return Uh(e,t,u,d,l,c,n)}:()=>Promise.resolve(),{when:o}=i;if(o){const[u,d]=o==="beforeChildren"?[s,a]:[a,s];return u().then(()=>d())}else return Promise.all([s(),a(n.delay)])}function Uh(e,t,n=0,r=0,i=0,s=1,a){const o=[];for(const u of e.variantChildren)u.notify("AnimationStart",t),o.push(vi(u,t,{...a,delay:n+(typeof r=="function"?0:r)+po(e.variantChildren,u,r,i,s)}).then(()=>u.notify("AnimationComplete",t)));return Promise.all(o)}function Bh(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(s=>vi(e,s,n));r=Promise.all(i)}else if(typeof t=="string")r=vi(e,t,n);else{const i=typeof t=="function"?Ut(e,t,n.custom):t;r=Promise.all(mo(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}function go(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const zh=ni.length;function yo(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?yo(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<zh;n++){const r=ni[n],i=e.props[r];(an(i)||i===!1)&&(t[r]=i)}return t}const $h=[...ti].reverse(),Wh=ti.length;function Hh(e){return t=>Promise.all(t.map(({animation:n,options:r})=>Bh(e,n,r)))}function Yh(e){let t=Hh(e),n=vo(),r=!0;const i=u=>(d,l)=>{const c=Ut(e,l,u==="exit"?e.presenceContext?.custom:void 0);if(c){const{transition:f,transitionEnd:h,...m}=c;d={...d,...m,...h}}return d};function s(u){t=u(e)}function a(u){const{props:d}=e,l=yo(e.parent)||{},c=[],f=new Set;let h={},m=1/0;for(let w=0;w<Wh;w++){const v=$h[w],I=n[v],S=d[v]!==void 0?d[v]:l[v],E=an(S),P=v===u?I.isActive:null;P===!1&&(m=w);let A=S===l[v]&&S!==d[v]&&E;if(A&&r&&e.manuallyAnimateOnMount&&(A=!1),I.protectedKeys={...h},!I.isActive&&P===null||!S&&!I.prevProp||Vn(S)||typeof S=="boolean")continue;const O=Gh(I.prevProp,S);let p=O||v===u&&I.isActive&&!A&&E||w>m&&E,y=!1;const T=Array.isArray(S)?S:[S];let k=T.reduce(i(v),{});P===!1&&(k={});const{prevResolvedValues:M={}}=I,j={...M,...k},C=g=>{p=!0,f.has(g)&&(y=!0,f.delete(g)),I.needsAnimating[g]=!0;const _=e.getValue(g);_&&(_.liveStyle=!1)};for(const g in j){const _=k[g],L=M[g];if(h.hasOwnProperty(g))continue;let U=!1;pi(_)&&pi(L)?U=!go(_,L):U=_!==L,U?_!=null?C(g):f.add(g):_!==void 0&&f.has(g)?C(g):I.protectedKeys[g]=!0}I.prevProp=S,I.prevResolvedValues=k,I.isActive&&(h={...h,...k}),r&&e.blockInitialAnimation&&(p=!1);const R=A&&O;p&&(!R||y)&&c.push(...T.map(g=>{const _={type:v};if(typeof g=="string"&&r&&!R&&e.manuallyAnimateOnMount&&e.parent){const{parent:L}=e,U=Ut(L,g);if(L.enteringChildren&&U){const{delayChildren:F}=U.transition||{};_.delay=po(L.enteringChildren,e,F)}}return{animation:g,options:_}}))}if(f.size){const w={};if(typeof d.initial!="boolean"){const v=Ut(e,Array.isArray(d.initial)?d.initial[0]:d.initial);v&&v.transition&&(w.transition=v.transition)}f.forEach(v=>{const I=e.getBaseTarget(v),S=e.getValue(v);S&&(S.liveStyle=!0),w[v]=I??null}),c.push({animation:w})}let b=!!c.length;return r&&(d.initial===!1||d.initial===d.animate)&&!e.manuallyAnimateOnMount&&(b=!1),r=!1,b?t(c):Promise.resolve()}function o(u,d){if(n[u].isActive===d)return Promise.resolve();e.variantChildren?.forEach(c=>c.animationState?.setActive(u,d)),n[u].isActive=d;const l=a(u);for(const c in n)n[c].protectedKeys={};return l}return{animateChanges:a,setActive:o,setAnimateFunction:s,getState:()=>n,reset:()=>{n=vo()}}}function Gh(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!go(t,e):!1}function bt(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function vo(){return{animate:bt(!0),whileInView:bt(),whileHover:bt(),whileTap:bt(),whileDrag:bt(),whileFocus:bt(),exit:bt()}}class ot{constructor(t){this.isMounted=!1,this.node=t}update(){}}class Kh extends ot{constructor(t){super(t),t.animationState||(t.animationState=Yh(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Vn(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let Xh=0;class qh extends ot{constructor(){super(...arguments),this.id=Xh++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const i=this.node.animationState.setActive("exit",!t);n&&!t&&i.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const Qh={animation:{Feature:Kh},exit:{Feature:qh}};function ln(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function un(e){return{point:{x:e.pageX,y:e.pageY}}}const Zh=e=>t=>Zr(t)&&e(t,un(t));function cn(e,t,n,r){return ln(e,t,Zh(n),r)}const bo=1e-4,Jh=1-bo,em=1+bo,xo=.01,tm=0-xo,nm=0+xo;function Se(e){return e.max-e.min}function rm(e,t,n){return Math.abs(e-t)<=n}function wo(e,t,n,r=.5){e.origin=r,e.originPoint=ue(t.min,t.max,e.origin),e.scale=Se(n)/Se(t),e.translate=ue(n.min,n.max,e.origin)-e.originPoint,(e.scale>=Jh&&e.scale<=em||isNaN(e.scale))&&(e.scale=1),(e.translate>=tm&&e.translate<=nm||isNaN(e.translate))&&(e.translate=0)}function fn(e,t,n,r){wo(e.x,t.x,n.x,r?r.originX:void 0),wo(e.y,t.y,n.y,r?r.originY:void 0)}function Ao(e,t,n){e.min=n.min+t.min,e.max=e.min+Se(t)}function im(e,t,n){Ao(e.x,t.x,n.x),Ao(e.y,t.y,n.y)}function So(e,t,n){e.min=t.min-n.min,e.max=e.min+Se(t)}function zn(e,t,n){So(e.x,t.x,n.x),So(e.y,t.y,n.y)}function Oe(e){return[e("x"),e("y")]}const To=({current:e})=>e?e.ownerDocument.defaultView:null,Po=(e,t)=>Math.abs(e-t);function sm(e,t){const n=Po(e.x,t.x),r=Po(e.y,t.y);return Math.sqrt(n**2+r**2)}class Co{constructor(t,n,{transformPagePoint:r,contextWindow:i=window,dragSnapToOrigin:s=!1,distanceThreshold:a=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const f=xi(this.lastMoveEventInfo,this.history),h=this.startEvent!==null,m=sm(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!h&&!m)return;const{point:b}=f,{timestamp:w}=ge;this.history.push({...b,timestamp:w});const{onStart:v,onMove:I}=this.handlers;h||(v&&v(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),I&&I(this.lastMoveEvent,f)},this.handlePointerMove=(f,h)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=bi(h,this.transformPagePoint),oe.update(this.updatePoint,!0)},this.handlePointerUp=(f,h)=>{this.end();const{onEnd:m,onSessionEnd:b,resumeAnimation:w}=this.handlers;if(this.dragSnapToOrigin&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const v=xi(f.type==="pointercancel"?this.lastMoveEventInfo:bi(h,this.transformPagePoint),this.history);this.startEvent&&m&&m(f,v),b&&b(f,v)},!Zr(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=a,this.contextWindow=i||window;const o=un(t),u=bi(o,this.transformPagePoint),{point:d}=u,{timestamp:l}=ge;this.history=[{...d,timestamp:l}];const{onSessionStart:c}=n;c&&c(t,xi(u,this.history)),this.removeListeners=Qt(cn(this.contextWindow,"pointermove",this.handlePointerMove),cn(this.contextWindow,"pointerup",this.handlePointerUp),cn(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),it(this.updatePoint)}}function bi(e,t){return t?{point:t(e.point)}:e}function Eo(e,t){return{x:e.x-t.x,y:e.y-t.y}}function xi({point:e},t){return{point:e,delta:Eo(e,Io(t)),offset:Eo(e,am(t)),velocity:om(t,.1)}}function am(e){return e[0]}function Io(e){return e[e.length-1]}function om(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=Io(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>_e(t)));)n--;if(!r)return{x:0,y:0};const s=Le(i.timestamp-r.timestamp);if(s===0)return{x:0,y:0};const a={x:(i.x-r.x)/s,y:(i.y-r.y)/s};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function lm(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?ue(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?ue(n,e,r.max):Math.min(e,n)),e}function ko(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function um(e,{top:t,left:n,bottom:r,right:i}){return{x:ko(e.x,n,i),y:ko(e.y,t,r)}}function Mo(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function cm(e,t){return{x:Mo(e.x,t.x),y:Mo(e.y,t.y)}}function fm(e,t){let n=.5;const r=Se(e),i=Se(t);return i>r?n=Zt(t.min,t.max-r,e.min):r>i&&(n=Zt(e.min,e.max-i,t.min)),Xe(0,1,n)}function dm(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const wi=.35;function hm(e=wi){return e===!1?e=0:e===!0&&(e=wi),{x:Do(e,"left","right"),y:Do(e,"top","bottom")}}function Do(e,t,n){return{min:jo(e,t),max:jo(e,n)}}function jo(e,t){return typeof e=="number"?e:e[t]||0}const mm=new WeakMap;class pm{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=me(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const s=c=>{const{dragSnapToOrigin:f}=this.getProps();f?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(un(c).point)},a=(c,f)=>{const{drag:h,dragPropagation:m,onDragStart:b}=this.getProps();if(h&&!m&&(this.openDragLock&&this.openDragLock(),this.openDragLock=wd(h),!this.openDragLock))return;this.latestPointerEvent=c,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Oe(v=>{let I=this.getAxisMotionValue(v).get()||0;if(We.test(I)){const{projection:S}=this.visualElement;if(S&&S.layout){const E=S.layout.layoutBox[v];E&&(I=Se(E)*(parseFloat(I)/100))}}this.originPoint[v]=I}),b&&oe.postRender(()=>b(c,f)),gi(this.visualElement,"transform");const{animationState:w}=this.visualElement;w&&w.setActive("whileDrag",!0)},o=(c,f)=>{this.latestPointerEvent=c,this.latestPanInfo=f;const{dragPropagation:h,dragDirectionLock:m,onDirectionLock:b,onDrag:w}=this.getProps();if(!h&&!this.openDragLock)return;const{offset:v}=f;if(m&&this.currentDirection===null){this.currentDirection=gm(v),this.currentDirection!==null&&b&&b(this.currentDirection);return}this.updateAxis("x",f.point,v),this.updateAxis("y",f.point,v),this.visualElement.render(),w&&w(c,f)},u=(c,f)=>{this.latestPointerEvent=c,this.latestPanInfo=f,this.stop(c,f),this.latestPointerEvent=null,this.latestPanInfo=null},d=()=>Oe(c=>this.getAnimationState(c)==="paused"&&this.getAxisMotionValue(c).animation?.play()),{dragSnapToOrigin:l}=this.getProps();this.panSession=new Co(t,{onSessionStart:s,onStart:a,onMove:o,onSessionEnd:u,resumeAnimation:d},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:l,distanceThreshold:r,contextWindow:To(this.visualElement)})}stop(t,n){const r=t||this.latestPointerEvent,i=n||this.latestPanInfo,s=this.isDragging;if(this.cancel(),!s||!i||!r)return;const{velocity:a}=i;this.startAnimation(a);const{onDragEnd:o}=this.getProps();o&&oe.postRender(()=>o(r,i))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!$n(t,i,this.currentDirection))return;const s=this.getAxisMotionValue(t);let a=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(a=lm(a,this.constraints[t],this.elastic[t])),s.set(a)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,i=this.constraints;t&&Rt(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=um(r.layoutBox,t):this.constraints=!1,this.elastic=hm(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Oe(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=dm(r.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Rt(t))return!1;const r=t.current;qe(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");const{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const s=yh(r,i.root,this.visualElement.getTransformPagePoint());let a=cm(i.layout.layoutBox,s);if(n){const o=n(mh(a));this.hasMutatedConstraints=!!o,o&&(a=qa(o))}return a}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:s,dragSnapToOrigin:a,onDragTransitionEnd:o}=this.getProps(),u=this.constraints||{},d=Oe(l=>{if(!$n(l,n,this.currentDirection))return;let c=u&&u[l]||{};a&&(c={min:0,max:0});const f=i?200:1e6,h=i?40:1e7,m={type:"inertia",velocity:r?t[l]:0,bounceStiffness:f,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10,...s,...c};return this.startAxisValueAnimation(l,m)});return Promise.all(d).then(o)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return gi(this.visualElement,t),r.start(yi(t,r,0,n,this.visualElement,!1))}stopAnimation(){Oe(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Oe(t=>this.getAxisMotionValue(t).animation?.pause())}getAnimationState(t){return this.getAxisMotionValue(t).animation?.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Oe(n=>{const{drag:r}=this.getProps();if(!$n(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,s=this.getAxisMotionValue(n);if(i&&i.layout){const{min:a,max:o}=i.layout.layoutBox[n];s.set(t[n]-ue(a,o,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Rt(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Oe(a=>{const o=this.getAxisMotionValue(a);if(o&&this.constraints!==!1){const u=o.get();i[a]=fm({min:u,max:u},this.constraints[a])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Oe(a=>{if(!$n(a,t,null))return;const o=this.getAxisMotionValue(a),{min:u,max:d}=this.constraints[a];o.set(ue(u,d,i[a]))})}addListeners(){if(!this.visualElement.current)return;mm.set(this.visualElement,this);const t=this.visualElement.current,n=cn(t,"pointerdown",u=>{const{drag:d,dragListener:l=!0}=this.getProps();d&&l&&this.start(u)}),r=()=>{const{dragConstraints:u}=this.getProps();Rt(u)&&u.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,s=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),oe.read(r);const a=ln(window,"resize",()=>this.scalePositionWithinConstraints()),o=i.addEventListener("didUpdate",(({delta:u,hasLayoutChanged:d})=>{this.isDragging&&d&&(Oe(l=>{const c=this.getAxisMotionValue(l);c&&(this.originPoint[l]+=u[l].translate,c.set(c.get()+u[l].translate))}),this.visualElement.render())}));return()=>{a(),n(),s(),o&&o()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:s=!1,dragElastic:a=wi,dragMomentum:o=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:s,dragElastic:a,dragMomentum:o}}}function $n(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function gm(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class ym extends ot{constructor(t){super(t),this.removeGroupControls=Fe,this.removeListeners=Fe,this.controls=new pm(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Fe}unmount(){this.removeGroupControls(),this.removeListeners()}}const Fo=e=>(t,n)=>{e&&oe.postRender(()=>e(t,n))};class vm extends ot{constructor(){super(...arguments),this.removePointerDownListener=Fe}onPointerDown(t){this.session=new Co(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:To(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:Fo(t),onStart:Fo(n),onMove:r,onEnd:(s,a)=>{delete this.session,i&&oe.postRender(()=>i(s,a))}}}mount(){this.removePointerDownListener=cn(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const Wn={hasAnimatedSinceResize:!0,hasEverUpdated:!1};let Ai=!1;class bm extends z.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:s}=t;s&&(n.group&&n.group.add(s),r&&r.register&&i&&r.register(s),Ai&&s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,onExitComplete:()=>this.safeToRemove()})),Wn.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:s}=this.props,{projection:a}=r;return a&&(a.isPresent=s,Ai=!0,i||t.layoutDependency!==n||n===void 0||t.isPresent!==s?a.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?a.promote():a.relegate()||oe.postRender(()=>{const o=a.getStack();(!o||!o.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),Qr.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;Ai=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Lo(e){const[t,n]=Da(),r=z.useContext(fr);return D.jsx(bm,{...e,layoutGroup:r,switchLayoutGroup:z.useContext(Ka),isPresent:t,safeToRemove:n})}function xm(e,t,n){const r=be(e)?e:Lt(e);return r.start(yi("",r,t,n)),r.animation}const wm=(e,t)=>e.depth-t.depth;class Am{constructor(){this.children=[],this.isDirty=!1}add(t){mr(this.children,t),this.isDirty=!0}remove(t){pr(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(wm),this.isDirty=!1,this.children.forEach(t)}}function Sm(e,t){const n=Ee.now(),r=({timestamp:i})=>{const s=i-n;s>=t&&(it(r),e(s-t))};return oe.setup(r,!0),()=>it(r)}const Oo=["TopLeft","TopRight","BottomLeft","BottomRight"],Tm=Oo.length,Ro=e=>typeof e=="string"?parseFloat(e):e,_o=e=>typeof e=="number"||Q.test(e);function Pm(e,t,n,r,i,s){i?(e.opacity=ue(0,n.opacity??1,Cm(r)),e.opacityExit=ue(t.opacity??1,0,Em(r))):s&&(e.opacity=ue(t.opacity??1,n.opacity??1,r));for(let a=0;a<Tm;a++){const o=`border${Oo[a]}Radius`;let u=Vo(t,o),d=Vo(n,o);if(u===void 0&&d===void 0)continue;u||(u=0),d||(d=0),u===0||d===0||_o(u)===_o(d)?(e[o]=Math.max(ue(Ro(u),Ro(d),r),0),(We.test(d)||We.test(u))&&(e[o]+="%")):e[o]=d}(t.rotate||n.rotate)&&(e.rotate=ue(t.rotate||0,n.rotate||0,r))}function Vo(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const Cm=No(0,.5,ks),Em=No(.5,.95,Fe);function No(e,t,n){return r=>r<e?0:r>t?1:n(Zt(e,t,r))}function Uo(e,t){e.min=t.min,e.max=t.max}function Ne(e,t){Uo(e.x,t.x),Uo(e.y,t.y)}function Bo(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function zo(e,t,n,r,i){return e-=t,e=Bn(e,1/n,r),i!==void 0&&(e=Bn(e,1/i,r)),e}function Im(e,t=0,n=1,r=.5,i,s=e,a=e){if(We.test(t)&&(t=parseFloat(t),t=ue(a.min,a.max,t/100)-a.min),typeof t!="number")return;let o=ue(s.min,s.max,r);e===s&&(o-=t),e.min=zo(e.min,t,n,o,i),e.max=zo(e.max,t,n,o,i)}function $o(e,t,[n,r,i],s,a){Im(e,t[n],t[r],t[i],t.scale,s,a)}const km=["x","scaleX","originX"],Mm=["y","scaleY","originY"];function Wo(e,t,n,r){$o(e.x,t,km,n?n.x:void 0,r?r.x:void 0),$o(e.y,t,Mm,n?n.y:void 0,r?r.y:void 0)}function Ho(e){return e.translate===0&&e.scale===1}function Yo(e){return Ho(e.x)&&Ho(e.y)}function Go(e,t){return e.min===t.min&&e.max===t.max}function Dm(e,t){return Go(e.x,t.x)&&Go(e.y,t.y)}function Ko(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Xo(e,t){return Ko(e.x,t.x)&&Ko(e.y,t.y)}function qo(e){return Se(e.x)/Se(e.y)}function Qo(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class jm{constructor(){this.members=[]}add(t){mr(this.members,t),t.scheduleRender()}remove(t){if(pr(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const s=this.members[i];if(s.isPresent!==!1){r=s;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:i}=t.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function Fm(e,t,n){let r="";const i=e.x.translate/t.x,s=e.y.translate/t.y,a=n?.z||0;if((i||s||a)&&(r=`translate3d(${i}px, ${s}px, ${a}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:d,rotate:l,rotateX:c,rotateY:f,skewX:h,skewY:m}=n;d&&(r=`perspective(${d}px) ${r}`),l&&(r+=`rotate(${l}deg) `),c&&(r+=`rotateX(${c}deg) `),f&&(r+=`rotateY(${f}deg) `),h&&(r+=`skewX(${h}deg) `),m&&(r+=`skewY(${m}deg) `)}const o=e.x.scale*t.x,u=e.y.scale*t.y;return(o!==1||u!==1)&&(r+=`scale(${o}, ${u})`),r||"none"}const Si=["","X","Y","Z"],Lm=1e3;let Om=0;function Ti(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Zo(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=ho(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:s}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",oe,!(i||s))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Zo(r)}function Jo({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(a={},o=t?.()){this.id=Om++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(Vm),this.nodes.forEach(zm),this.nodes.forEach($m),this.nodes.forEach(Nm)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=a,this.root=o?o.root||o:this,this.path=o?[...o.path,o]:[],this.parent=o,this.depth=o?o.depth+1:0;for(let u=0;u<this.path.length;u++)this.path[u].shouldResetTransform=!0;this.root===this&&(this.nodes=new Am)}addEventListener(a,o){return this.eventHandlers.has(a)||this.eventHandlers.set(a,new vr),this.eventHandlers.get(a).add(o)}notifyListeners(a,...o){const u=this.eventHandlers.get(a);u&&u.notify(...o)}hasListeners(a){return this.eventHandlers.has(a)}mount(a){if(this.instance)return;this.isSVG=ka(a)&&!Ed(a),this.instance=a;const{layoutId:o,layout:u,visualElement:d}=this.options;if(d&&!d.current&&d.mount(a),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(u||o)&&(this.isLayoutDirty=!0),e){let l,c=0;const f=()=>this.root.updateBlockedByResize=!1;oe.read(()=>{c=window.innerWidth}),e(a,()=>{const h=window.innerWidth;h!==c&&(c=h,this.root.updateBlockedByResize=!0,l&&l(),l=Sm(f,250),Wn.hasAnimatedSinceResize&&(Wn.hasAnimatedSinceResize=!1,this.nodes.forEach(nl)))})}o&&this.root.registerSharedNode(o,this),this.options.animate!==!1&&d&&(o||u)&&this.addEventListener("didUpdate",({delta:l,hasLayoutChanged:c,hasRelativeLayoutChanged:f,layout:h})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const m=this.options.transition||d.getDefaultTransition()||Km,{onLayoutAnimationStart:b,onLayoutAnimationComplete:w}=d.getProps(),v=!this.targetLayout||!Xo(this.targetLayout,h),I=!c&&f;if(this.options.layoutRoot||this.resumeFrom||I||c&&(v||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const S={...Kr(m,"layout"),onPlay:b,onComplete:w};(d.shouldReduceMotion||this.options.layoutRoot)&&(S.delay=0,S.type=!1),this.startAnimation(S),this.setAnimationOrigin(l,I)}else c||nl(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=h})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const a=this.getStack();a&&a.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),it(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(Wm),this.animationId++)}getTransformTemplate(){const{visualElement:a}=this.options;return a&&a.getProps().transformTemplate}willUpdate(a=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Zo(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let l=0;l<this.path.length;l++){const c=this.path[l];c.shouldResetTransform=!0,c.updateScroll("snapshot"),c.options.layoutRoot&&c.willUpdate(!1)}const{layoutId:o,layout:u}=this.options;if(o===void 0&&!u)return;const d=this.getTransformTemplate();this.prevTransformTemplateValue=d?d(this.latestValues,""):void 0,this.updateSnapshot(),a&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(el);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(tl);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Bm),this.nodes.forEach(Rm),this.nodes.forEach(_m)):this.nodes.forEach(tl),this.clearAllSnapshots();const o=Ee.now();ge.delta=Xe(0,1e3/60,o-ge.timestamp),ge.timestamp=o,ge.isProcessing=!0,Ar.update.process(ge),Ar.preRender.process(ge),Ar.render.process(ge),ge.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Qr.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Um),this.sharedNodes.forEach(Hm)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,oe.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){oe.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Se(this.snapshot.measuredBox.x)&&!Se(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let u=0;u<this.path.length;u++)this.path[u].updateScroll();const a=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=me(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:o}=this.options;o&&o.notify("LayoutMeasure",this.layout.layoutBox,a?a.layoutBox:void 0)}updateScroll(a="measure"){let o=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===a&&(o=!1),o&&this.instance){const u=r(this.instance);this.scroll={animationId:this.root.animationId,phase:a,isRoot:u,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:u}}}resetTransform(){if(!i)return;const a=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,o=this.projectionDelta&&!Yo(this.projectionDelta),u=this.getTransformTemplate(),d=u?u(this.latestValues,""):void 0,l=d!==this.prevTransformTemplateValue;a&&this.instance&&(o||vt(this.latestValues)||l)&&(i(this.instance,d),this.shouldResetTransform=!1,this.scheduleRender())}measure(a=!0){const o=this.measurePageBox();let u=this.removeElementScroll(o);return a&&(u=this.removeTransform(u)),Xm(u),{animationId:this.root.animationId,measuredBox:o,layoutBox:u,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:a}=this.options;if(!a)return me();const o=a.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(qm))){const{scroll:d}=this.root;d&&(_t(o.x,d.offset.x),_t(o.y,d.offset.y))}return o}removeElementScroll(a){const o=me();if(Ne(o,a),this.scroll?.wasRoot)return o;for(let u=0;u<this.path.length;u++){const d=this.path[u],{scroll:l,options:c}=d;d!==this.root&&l&&c.layoutScroll&&(l.wasRoot&&Ne(o,a),_t(o.x,l.offset.x),_t(o.y,l.offset.y))}return o}applyTransform(a,o=!1){const u=me();Ne(u,a);for(let d=0;d<this.path.length;d++){const l=this.path[d];!o&&l.options.layoutScroll&&l.scroll&&l!==l.root&&Vt(u,{x:-l.scroll.offset.x,y:-l.scroll.offset.y}),vt(l.latestValues)&&Vt(u,l.latestValues)}return vt(this.latestValues)&&Vt(u,this.latestValues),u}removeTransform(a){const o=me();Ne(o,a);for(let u=0;u<this.path.length;u++){const d=this.path[u];if(!d.instance||!vt(d.latestValues))continue;di(d.latestValues)&&d.updateSnapshot();const l=me(),c=d.measurePageBox();Ne(l,c),Wo(o,d.latestValues,d.snapshot?d.snapshot.layoutBox:void 0,l)}return vt(this.latestValues)&&Wo(o,this.latestValues),o}setTargetDelta(a){this.targetDelta=a,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(a){this.options={...this.options,...a,crossfade:a.crossfade!==void 0?a.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==ge.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(a=!1){const o=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=o.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=o.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=o.isSharedProjectionDirty);const u=!!this.resumingFrom||this!==o;if(!(a||u&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:l,layoutId:c}=this.options;if(!this.layout||!(l||c))return;this.resolvedRelativeTargetAt=ge.timestamp;const f=this.getClosestProjectingParent();f&&this.linkedParentVersion!==f.layoutVersion&&!f.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(f&&f.layout?this.createRelativeTarget(f,this.layout.layoutBox,f.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=me(),this.targetWithTransforms=me()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),im(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Ne(this.target,this.layout.layoutBox),eo(this.target,this.targetDelta)):Ne(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,f&&!!f.resumingFrom==!!this.resumingFrom&&!f.options.layoutScroll&&f.target&&this.animationProgress!==1?this.createRelativeTarget(f,this.target,f.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||di(this.parent.latestValues)||Qa(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(a,o,u){this.relativeParent=a,this.linkedParentVersion=a.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=me(),this.relativeTargetOrigin=me(),zn(this.relativeTargetOrigin,o,u),Ne(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){const a=this.getLead(),o=!!this.resumingFrom||this!==a;let u=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(u=!1),o&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(u=!1),this.resolvedRelativeTargetAt===ge.timestamp&&(u=!1),u)return;const{layout:d,layoutId:l}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(d||l))return;Ne(this.layoutCorrected,this.layout.layoutBox);const c=this.treeScale.x,f=this.treeScale.y;gh(this.layoutCorrected,this.treeScale,this.path,o),a.layout&&!a.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(a.target=a.layout.layoutBox,a.targetWithTransforms=me());const{target:h}=a;if(!h){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Bo(this.prevProjectionDelta.x,this.projectionDelta.x),Bo(this.prevProjectionDelta.y,this.projectionDelta.y)),fn(this.projectionDelta,this.layoutCorrected,h,this.latestValues),(this.treeScale.x!==c||this.treeScale.y!==f||!Qo(this.projectionDelta.x,this.prevProjectionDelta.x)||!Qo(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",h))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(a=!0){if(this.options.visualElement?.scheduleRender(),a){const o=this.getStack();o&&o.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Nt(),this.projectionDelta=Nt(),this.projectionDeltaWithTransform=Nt()}setAnimationOrigin(a,o=!1){const u=this.snapshot,d=u?u.latestValues:{},l={...this.latestValues},c=Nt();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!o;const f=me(),h=u?u.source:void 0,m=this.layout?this.layout.source:void 0,b=h!==m,w=this.getStack(),v=!w||w.members.length<=1,I=!!(b&&!v&&this.options.crossfade===!0&&!this.path.some(Gm));this.animationProgress=0;let S;this.mixTargetDelta=E=>{const P=E/1e3;rl(c.x,a.x,P),rl(c.y,a.y,P),this.setTargetDelta(c),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(zn(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Ym(this.relativeTarget,this.relativeTargetOrigin,f,P),S&&Dm(this.relativeTarget,S)&&(this.isProjectionDirty=!1),S||(S=me()),Ne(S,this.relativeTarget)),b&&(this.animationValues=l,Pm(l,d,this.latestValues,P,I,v)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=P},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(a){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(it(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=oe.update(()=>{Wn.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Lt(0)),this.currentAnimation=xm(this.motionValue,[0,1e3],{...a,velocity:0,isSync:!0,onUpdate:o=>{this.mixTargetDelta(o),a.onUpdate&&a.onUpdate(o)},onStop:()=>{},onComplete:()=>{a.onComplete&&a.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const a=this.getStack();a&&a.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Lm),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const a=this.getLead();let{targetWithTransforms:o,target:u,layout:d,latestValues:l}=a;if(!(!o||!u||!d)){if(this!==a&&this.layout&&d&&ll(this.options.animationType,this.layout.layoutBox,d.layoutBox)){u=this.target||me();const c=Se(this.layout.layoutBox.x);u.x.min=a.target.x.min,u.x.max=u.x.min+c;const f=Se(this.layout.layoutBox.y);u.y.min=a.target.y.min,u.y.max=u.y.min+f}Ne(o,u),Vt(o,l),fn(this.projectionDeltaWithTransform,this.layoutCorrected,o,l)}}registerSharedNode(a,o){this.sharedNodes.has(a)||this.sharedNodes.set(a,new jm),this.sharedNodes.get(a).add(o);const d=o.options.initialPromotionConfig;o.promote({transition:d?d.transition:void 0,preserveFollowOpacity:d&&d.shouldPreserveFollowOpacity?d.shouldPreserveFollowOpacity(o):void 0})}isLead(){const a=this.getStack();return a?a.lead===this:!0}getLead(){const{layoutId:a}=this.options;return a?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:a}=this.options;return a?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:a}=this.options;if(a)return this.root.sharedNodes.get(a)}promote({needsReset:a,transition:o,preserveFollowOpacity:u}={}){const d=this.getStack();d&&d.promote(this,u),a&&(this.projectionDelta=void 0,this.needsReset=!0),o&&this.setOptions({transition:o})}relegate(){const a=this.getStack();return a?a.relegate(this):!1}resetSkewAndRotation(){const{visualElement:a}=this.options;if(!a)return;let o=!1;const{latestValues:u}=a;if((u.z||u.rotate||u.rotateX||u.rotateY||u.rotateZ||u.skewX||u.skewY)&&(o=!0),!o)return;const d={};u.z&&Ti("z",a,d,this.animationValues);for(let l=0;l<Si.length;l++)Ti(`rotate${Si[l]}`,a,d,this.animationValues),Ti(`skew${Si[l]}`,a,d,this.animationValues);a.render();for(const l in d)a.setStaticValue(l,d[l]),this.animationValues&&(this.animationValues[l]=d[l]);a.scheduleRender()}applyProjectionStyles(a,o){if(!this.instance||this.isSVG)return;if(!this.isVisible){a.visibility="hidden";return}const u=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,a.visibility="",a.opacity="",a.pointerEvents=Un(o?.pointerEvents)||"",a.transform=u?u(this.latestValues,""):"none";return}const d=this.getLead();if(!this.projectionDelta||!this.layout||!d.target){this.options.layoutId&&(a.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,a.pointerEvents=Un(o?.pointerEvents)||""),this.hasProjected&&!vt(this.latestValues)&&(a.transform=u?u({},""):"none",this.hasProjected=!1);return}a.visibility="";const l=d.animationValues||d.latestValues;this.applyTransformsToTarget();let c=Fm(this.projectionDeltaWithTransform,this.treeScale,l);u&&(c=u(l,c)),a.transform=c;const{x:f,y:h}=this.projectionDelta;a.transformOrigin=`${f.origin*100}% ${h.origin*100}% 0`,d.animationValues?a.opacity=d===this?l.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:l.opacityExit:a.opacity=d===this?l.opacity!==void 0?l.opacity:"":l.opacityExit!==void 0?l.opacityExit:0;for(const m in ri){if(l[m]===void 0)continue;const{correct:b,applyTo:w,isCSSVariable:v}=ri[m],I=c==="none"?l[m]:b(l[m],d);if(w){const S=w.length;for(let E=0;E<S;E++)a[w[E]]=I}else v?this.options.visualElement.renderState.vars[m]=I:a[m]=I}this.options.layoutId&&(a.pointerEvents=d===this?Un(o?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(a=>a.currentAnimation?.stop()),this.root.nodes.forEach(el),this.root.sharedNodes.clear()}}}function Rm(e){e.updateLayout()}function _m(e){const t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:r}=e.layout,{animationType:i}=e.options,s=t.source!==e.layout.source;i==="size"?Oe(l=>{const c=s?t.measuredBox[l]:t.layoutBox[l],f=Se(c);c.min=n[l].min,c.max=c.min+f}):ll(i,t.layoutBox,n)&&Oe(l=>{const c=s?t.measuredBox[l]:t.layoutBox[l],f=Se(n[l]);c.max=c.min+f,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[l].max=e.relativeTarget[l].min+f)});const a=Nt();fn(a,n,t.layoutBox);const o=Nt();s?fn(o,e.applyTransform(r,!0),t.measuredBox):fn(o,n,t.layoutBox);const u=!Yo(a);let d=!1;if(!e.resumeFrom){const l=e.getClosestProjectingParent();if(l&&!l.resumeFrom){const{snapshot:c,layout:f}=l;if(c&&f){const h=me();zn(h,t.layoutBox,c.layoutBox);const m=me();zn(m,n,f.layoutBox),Xo(h,m)||(d=!0),l.options.layoutRoot&&(e.relativeTarget=m,e.relativeTargetOrigin=h,e.relativeParent=l)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:t,delta:o,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:d})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function Vm(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Nm(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Um(e){e.clearSnapshot()}function el(e){e.clearMeasurements()}function tl(e){e.isLayoutDirty=!1}function Bm(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function nl(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function zm(e){e.resolveTargetDelta()}function $m(e){e.calcProjection()}function Wm(e){e.resetSkewAndRotation()}function Hm(e){e.removeLeadSnapshot()}function rl(e,t,n){e.translate=ue(t.translate,0,n),e.scale=ue(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function il(e,t,n,r){e.min=ue(t.min,n.min,r),e.max=ue(t.max,n.max,r)}function Ym(e,t,n,r){il(e.x,t.x,n.x,r),il(e.y,t.y,n.y,r)}function Gm(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const Km={duration:.45,ease:[.4,0,.1,1]},sl=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),al=sl("applewebkit/")&&!sl("chrome/")?Math.round:Fe;function ol(e){e.min=al(e.min),e.max=al(e.max)}function Xm(e){ol(e.x),ol(e.y)}function ll(e,t,n){return e==="position"||e==="preserve-aspect"&&!rm(qo(t),qo(n),.2)}function qm(e){return e!==e.root&&e.scroll?.wasRoot}const Qm=Jo({attachResizeListener:(e,t)=>ln(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Pi={current:void 0},ul=Jo({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Pi.current){const e=new Qm({});e.mount(window),e.setOptions({layoutScroll:!0}),Pi.current=e}return Pi.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Zm={pan:{Feature:vm},drag:{Feature:ym,ProjectionNode:ul,MeasureLayout:Lo}};function cl(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,s=r[i];s&&oe.postRender(()=>s(t,un(t)))}class Jm extends ot{mount(){const{current:t}=this.node;t&&(this.unmount=Ad(t,(n,r)=>(cl(this.node,r,"Start"),i=>cl(this.node,i,"End"))))}unmount(){}}class ep extends ot{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Qt(ln(this.node.current,"focus",()=>this.onFocus()),ln(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function fl(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),s=r[i];s&&oe.postRender(()=>s(t,un(t)))}class tp extends ot{mount(){const{current:t}=this.node;t&&(this.unmount=Cd(t,(n,r)=>(fl(this.node,r,"Start"),(i,{success:s})=>fl(this.node,i,s?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Ci=new WeakMap,Ei=new WeakMap,np=e=>{const t=Ci.get(e.target);t&&t(e)},rp=e=>{e.forEach(np)};function ip({root:e,...t}){const n=e||document;Ei.has(n)||Ei.set(n,{});const r=Ei.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(rp,{root:e,...t})),r[i]}function sp(e,t,n){const r=ip(t);return Ci.set(e,n),r.observe(e),()=>{Ci.delete(e),r.unobserve(e)}}const ap={some:0,all:1};class op extends ot{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:s}=t,a={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:ap[i]},o=u=>{const{isIntersecting:d}=u;if(this.isInView===d||(this.isInView=d,s&&!d&&this.hasEnteredView))return;d&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",d);const{onViewportEnter:l,onViewportLeave:c}=this.node.getProps(),f=d?l:c;f&&f(u)};return sp(this.node.current,a,o)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(lp(t,n))&&this.startObserver()}unmount(){}}function lp({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const up={...Qh,...{inView:{Feature:op},tap:{Feature:tp},focus:{Feature:ep},hover:{Feature:Jm}},...Zm,...{layout:{ProjectionNode:ul,MeasureLayout:Lo}}},dl=hh(up,Ch);function Ii(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function cp(e){if(Array.isArray(e))return e}function fp(e){if(Array.isArray(e))return Ii(e)}function dp(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,ml(r.key),r)}}function mp(e,t,n){return t&&hp(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Hn(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=ki(e))||t){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(u){throw u},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
15
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var s,a=!0,o=!1;return{s:function(){n=n.call(e)},n:function(){var u=n.next();return a=u.done,u},e:function(u){o=!0,s=u},f:function(){try{a||n.return==null||n.return()}finally{if(o)throw s}}}}function J(e,t,n){return(t=ml(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pp(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function gp(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,s,a,o=[],u=!0,d=!1;try{if(s=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=s.call(n)).done)&&(o.push(r.value),o.length!==t);u=!0);}catch(l){d=!0,i=l}finally{try{if(!u&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(d)throw i}}return o}}function yp(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
14
+ `),()=>{w.contains(b)&&w.removeChild(b)}},[t]),D.jsx(jd,{isPresent:t,childRef:s,sizeRef:a,children:Tn.cloneElement(e,{ref:u})})}const Ld=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:s,mode:a,anchorX:o,root:u})=>{const d=dr(Od),l=z.useId();let c=!0,f=z.useMemo(()=>(c=!1,{id:l,initial:t,isPresent:n,custom:i,onExitComplete:h=>{d.set(h,!0);for(const m of d.values())if(!m)return;r&&r()},register:h=>(d.set(h,!1),()=>d.delete(h))}),[n,d,r]);return s&&c&&(f={...f}),z.useMemo(()=>{d.forEach((h,m)=>d.set(m,!1))},[n]),Tn.useEffect(()=>{!n&&!d.size&&r&&r()},[n]),a==="popLayout"&&(e=D.jsx(Fd,{isPresent:n,anchorX:o,root:u,children:e})),D.jsx(En.Provider,{value:f,children:e})};function Od(){return new Map}function Da(e=!0){const t=z.useContext(En);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:i}=t,s=z.useId();z.useEffect(()=>{if(e)return i(s)},[e]);const a=z.useCallback(()=>e&&r&&r(s),[s,r,e]);return!n&&r?[!1,a]:[!0]}const On=e=>e.key||"";function ja(e){const t=[];return z.Children.forEach(e,n=>{z.isValidElement(n)&&t.push(n)}),t}const Rd=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:i=!0,mode:s="sync",propagate:a=!1,anchorX:o="left",root:u})=>{const[d,l]=Da(a),c=z.useMemo(()=>ja(e),[e]),f=a&&!d?[]:c.map(On),h=z.useRef(!0),m=z.useRef(c),b=dr(()=>new Map),[w,v]=z.useState(c),[I,S]=z.useState(c);ys(()=>{h.current=!1,m.current=c;for(let A=0;A<I.length;A++){const O=On(I[A]);f.includes(O)?b.delete(O):b.get(O)!==!0&&b.set(O,!1)}},[I,f.length,f.join("-")]);const E=[];if(c!==w){let A=[...c];for(let O=0;O<I.length;O++){const p=I[O],y=On(p);f.includes(y)||(A.splice(O,0,p),E.push(p))}return s==="wait"&&E.length&&(A=E),S(ja(A)),v(c),null}process.env.NODE_ENV!=="production"&&s==="wait"&&I.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`);const{forceRender:P}=z.useContext(fr);return D.jsx(D.Fragment,{children:I.map(A=>{const O=On(A),p=a&&!d?!1:c===I||f.includes(O),y=()=>{if(b.has(O))b.set(O,!0);else return;let T=!0;b.forEach(k=>{k||(T=!1)}),T&&(P?.(),S(m.current),a&&l?.(),r&&r())};return D.jsx(Ld,{isPresent:p,initial:!h.current||n?void 0:!1,custom:t,presenceAffectsLayout:i,mode:s,root:u,onExitComplete:p?void 0:y,anchorX:o,children:A},O)})})},Fa=z.createContext({strict:!1}),La={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Ot={};for(const e in La)Ot[e]={isEnabled:t=>La[e].some(n=>!!t[n])};function _d(e){for(const t in e)Ot[t]={...Ot[t],...e[t]}}const Vd=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Rn(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Vd.has(e)}let Oa=e=>!Rn(e);function Nd(e){typeof e=="function"&&(Oa=t=>t.startsWith("on")?!Rn(t):e(t))}try{Nd(require("@emotion/is-prop-valid").default)}catch{}function Ud(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(Oa(i)||n===!0&&Rn(i)||!t&&!Rn(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}const _n=z.createContext({});function Vn(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function an(e){return typeof e=="string"||Array.isArray(e)}const ti=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],ni=["initial",...ti];function Nn(e){return Vn(e.animate)||ni.some(t=>an(e[t]))}function Ra(e){return!!(Nn(e)||e.variants)}function Bd(e,t){if(Nn(e)){const{initial:n,animate:r}=e;return{initial:n===!1||an(n)?n:void 0,animate:an(r)?r:void 0}}return e.inherit!==!1?t:{}}function zd(e){const{initial:t,animate:n}=Bd(e,z.useContext(_n));return z.useMemo(()=>({initial:t,animate:n}),[_a(t),_a(n)])}function _a(e){return Array.isArray(e)?e.join(" "):e}function Va(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const on={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(q.test(e))e=parseFloat(e);else return e;const n=Va(e,t.target.x),r=Va(e,t.target.y);return`${n}% ${r}%`}},$d={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=at.parse(e);if(i.length>5)return r;const s=at.createTransformer(e),a=typeof i[0]!="number"?1:0,o=n.x.scale*t.x,u=n.y.scale*t.y;i[0+a]/=o,i[1+a]/=u;const d=ce(o,u,.5);return typeof i[2+a]=="number"&&(i[2+a]/=d),typeof i[3+a]=="number"&&(i[3+a]/=d),s(i)}},ri={borderRadius:{...on,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:on,borderTopRightRadius:on,borderBottomLeftRadius:on,borderBottomRightRadius:on,boxShadow:$d};function Na(e,{layout:t,layoutId:n}){return Ft.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!ri[e]||e==="opacity")}const Wd={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Hd=jt.length;function Yd(e,t,n){let r="",i=!0;for(let s=0;s<Hd;s++){const a=jt[s],o=e[a];if(o===void 0)continue;let u=!0;if(typeof o=="number"?u=o===(a.startsWith("scale")?1:0):u=parseFloat(o)===0,!u||n){const d=xa(o,qr[a]);if(!u){i=!1;const l=Wd[a]||a;r+=`${l}(${d}) `}n&&(t[a]=d)}}return r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}function ii(e,t,n){const{style:r,vars:i,transformOrigin:s}=e;let a=!1,o=!1;for(const u in t){const d=t[u];if(Ft.has(u)){a=!0;continue}else if(_s(u)){i[u]=d;continue}else{const l=xa(d,qr[u]);u.startsWith("origin")?(o=!0,s[u]=l):r[u]=l}}if(t.transform||(a||n?r.transform=Yd(t,e.transform,n):r.transform&&(r.transform="none")),o){const{originX:u="50%",originY:d="50%",originZ:l=0}=s;r.transformOrigin=`${u} ${d} ${l}`}}const si=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Ua(e,t,n){for(const r in t)!xe(t[r])&&!Na(r,n)&&(e[r]=t[r])}function Gd({transformTemplate:e},t){return z.useMemo(()=>{const n=si();return ii(n,t,e),Object.assign({},n.vars,n.style)},[t])}function Kd(e,t){const n=e.style||{},r={};return Ua(r,n,e),Object.assign(r,Gd(e,t)),r}function Xd(e,t){const n={},r=Kd(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const qd={offset:"stroke-dashoffset",array:"stroke-dasharray"},Qd={offset:"strokeDashoffset",array:"strokeDasharray"};function Zd(e,t,n=1,r=0,i=!0){e.pathLength=1;const s=i?qd:Qd;e[s.offset]=q.transform(-r);const a=q.transform(t),o=q.transform(n);e[s.array]=`${a} ${o}`}function Ba(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:s=1,pathOffset:a=0,...o},u,d,l){if(ii(e,o,d),u){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:c,style:f}=e;c.transform&&(f.transform=c.transform,delete c.transform),(f.transform||c.transformOrigin)&&(f.transformOrigin=c.transformOrigin??"50% 50%",delete c.transformOrigin),f.transform&&(f.transformBox=l?.transformBox??"fill-box",delete c.transformBox),t!==void 0&&(c.x=t),n!==void 0&&(c.y=n),r!==void 0&&(c.scale=r),i!==void 0&&Zd(c,i,s,a,!1)}const za=()=>({...si(),attrs:{}}),$a=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Jd(e,t,n,r){const i=z.useMemo(()=>{const s=za();return Ba(s,t,$a(r),e.transformTemplate,e.style),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};Ua(s,e.style,e),i.style={...s,...i.style}}return i}const eh=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function ai(e){return typeof e!="string"||e.includes("-")?!1:!!(eh.indexOf(e)>-1||/[A-Z]/u.test(e))}function th(e,t,n,{latestValues:r},i,s=!1){const o=(ai(e)?Jd:Xd)(t,r,i,e),u=Ud(t,typeof e=="string",s),d=e!==z.Fragment?{...u,...o,ref:n}:{},{children:l}=t,c=z.useMemo(()=>xe(l)?l.get():l,[l]);return z.createElement(e,{...d,children:c})}function Wa(e){const t=[{},{}];return e?.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function oi(e,t,n,r){if(typeof t=="function"){const[i,s]=Wa(r);t=t(n!==void 0?n:e.custom,i,s)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,s]=Wa(r);t=t(n!==void 0?n:e.custom,i,s)}return t}function Un(e){return xe(e)?e.get():e}function nh({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:rh(n,r,i,e),renderState:t()}}function rh(e,t,n,r){const i={},s=r(e,{});for(const f in s)i[f]=Un(s[f]);let{initial:a,animate:o}=e;const u=Nn(e),d=Ra(e);t&&d&&!u&&e.inherit!==!1&&(a===void 0&&(a=t.initial),o===void 0&&(o=t.animate));let l=n?n.initial===!1:!1;l=l||a===!1;const c=l?o:a;if(c&&typeof c!="boolean"&&!Vn(c)){const f=Array.isArray(c)?c:[c];for(let h=0;h<f.length;h++){const m=oi(e,f[h]);if(m){const{transitionEnd:b,transition:w,...v}=m;for(const I in v){let S=v[I];if(Array.isArray(S)){const E=l?S.length-1:0;S=S[E]}S!==null&&(i[I]=S)}for(const I in b)i[I]=b[I]}}}return i}const Ha=e=>(t,n)=>{const r=z.useContext(_n),i=z.useContext(En),s=()=>nh(e,t,r,i);return n?s():dr(s)};function li(e,t,n){const{style:r}=e,i={};for(const s in r)(xe(r[s])||t.style&&xe(t.style[s])||Na(s,e)||n?.getValue(s)?.liveStyle!==void 0)&&(i[s]=r[s]);return i}const ih=Ha({scrapeMotionValuesFromProps:li,createRenderState:si});function Ya(e,t,n){const r=li(e,t,n);for(const i in e)if(xe(e[i])||xe(t[i])){const s=jt.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[s]=e[i]}return r}const sh=Ha({scrapeMotionValuesFromProps:Ya,createRenderState:za}),ah=Symbol.for("motionComponentSymbol");function Rt(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function oh(e,t,n){return z.useCallback(r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):Rt(n)&&(n.current=r))},[t])}const ui=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),Ga="data-"+ui("framerAppearId"),Ka=z.createContext({});function lh(e,t,n,r,i){const{visualElement:s}=z.useContext(_n),a=z.useContext(Fa),o=z.useContext(En),u=z.useContext(ei).reducedMotion,d=z.useRef(null);r=r||a.renderer,!d.current&&r&&(d.current=r(e,{visualState:t,parent:s,props:n,presenceContext:o,blockInitialAnimation:o?o.initial===!1:!1,reducedMotionConfig:u}));const l=d.current,c=z.useContext(Ka);l&&!l.projection&&i&&(l.type==="html"||l.type==="svg")&&uh(d.current,n,i,c);const f=z.useRef(!1);z.useInsertionEffect(()=>{l&&f.current&&l.update(n,o)});const h=n[Ga],m=z.useRef(!!h&&!window.MotionHandoffIsComplete?.(h)&&window.MotionHasOptimisedAnimation?.(h));return ys(()=>{l&&(f.current=!0,window.MotionIsMounted=!0,l.updateFeatures(),l.scheduleRenderMicrotask(),m.current&&l.animationState&&l.animationState.animateChanges())}),z.useEffect(()=>{l&&(!m.current&&l.animationState&&l.animationState.animateChanges(),m.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(h)}),m.current=!1),l.enteringChildren=void 0)}),l}function uh(e,t,n,r){const{layoutId:i,layout:s,drag:a,dragConstraints:o,layoutScroll:u,layoutRoot:d,layoutCrossfade:l}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Xa(e.parent)),e.projection.setOptions({layoutId:i,layout:s,alwaysMeasureLayout:!!a||o&&Rt(o),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:r,crossfade:l,layoutScroll:u,layoutRoot:d})}function Xa(e){if(e)return e.options.allowProjection!==!1?e.projection:Xa(e.parent)}function ci(e,{forwardMotionProps:t=!1}={},n,r){n&&_d(n);const i=ai(e)?sh:ih;function s(o,u){let d;const l={...z.useContext(ei),...o,layoutId:ch(o)},{isStatic:c}=l,f=zd(o),h=i(o,c);if(!c&&hr){fh(l,n);const m=dh(l);d=m.MeasureLayout,f.visualElement=lh(e,h,l,r,m.ProjectionNode)}return D.jsxs(_n.Provider,{value:f,children:[d&&f.visualElement?D.jsx(d,{visualElement:f.visualElement,...l}):null,th(e,o,oh(h,f.visualElement,u),h,c,t)]})}s.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const a=z.forwardRef(s);return a[ah]=e,a}function ch({layoutId:e}){const t=z.useContext(fr).id;return t&&e!==void 0?t+"-"+e:e}function fh(e,t){const n=z.useContext(Fa).strict;if(process.env.NODE_ENV!=="production"&&t&&n){const r="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?It(!1,r,"lazy-strict-mode"):qe(!1,r,"lazy-strict-mode")}}function dh(e){const{drag:t,layout:n}=Ot;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t?.isEnabled(e)||n?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function hh(e,t){if(typeof Proxy>"u")return ci;const n=new Map,r=(s,a)=>ci(s,a,e,t),i=(s,a)=>(process.env.NODE_ENV!=="production"&&br(!1,"motion() is deprecated. Use motion.create() instead."),r(s,a));return new Proxy(i,{get:(s,a)=>a==="create"?r:(n.has(a)||n.set(a,ci(a,void 0,e,t)),n.get(a))})}function qa({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function mh({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function ph(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function fi(e){return e===void 0||e===1}function di({scale:e,scaleX:t,scaleY:n}){return!fi(e)||!fi(t)||!fi(n)}function vt(e){return di(e)||Qa(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Qa(e){return Za(e.x)||Za(e.y)}function Za(e){return e&&e!=="0%"}function Bn(e,t,n){const r=e-n,i=t*r;return n+i}function Ja(e,t,n,r,i){return i!==void 0&&(e=Bn(e,i,r)),Bn(e,n,r)+t}function hi(e,t=0,n=1,r,i){e.min=Ja(e.min,t,n,r,i),e.max=Ja(e.max,t,n,r,i)}function eo(e,{x:t,y:n}){hi(e.x,t.translate,t.scale,t.originPoint),hi(e.y,n.translate,n.scale,n.originPoint)}const to=.999999999999,no=1.0000000000001;function gh(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let s,a;for(let o=0;o<i;o++){s=n[o],a=s.projectionDelta;const{visualElement:u}=s.options;u&&u.props.style&&u.props.style.display==="contents"||(r&&s.options.layoutScroll&&s.scroll&&s!==s.root&&Vt(e,{x:-s.scroll.offset.x,y:-s.scroll.offset.y}),a&&(t.x*=a.x.scale,t.y*=a.y.scale,eo(e,a)),r&&vt(s.latestValues)&&Vt(e,s.latestValues))}t.x<no&&t.x>to&&(t.x=1),t.y<no&&t.y>to&&(t.y=1)}function _t(e,t){e.min=e.min+t,e.max=e.max+t}function ro(e,t,n,r,i=.5){const s=ce(e.min,e.max,i);hi(e,t,n,s,r)}function Vt(e,t){ro(e.x,t.x,t.scaleX,t.scale,t.originX),ro(e.y,t.y,t.scaleY,t.scale,t.originY)}function io(e,t){return qa(ph(e.getBoundingClientRect(),t))}function yh(e,t,n){const r=io(e,n),{scroll:i}=t;return i&&(_t(r.x,i.offset.x),_t(r.y,i.offset.y)),r}const so=()=>({translate:0,scale:1,origin:0,originPoint:0}),Nt=()=>({x:so(),y:so()}),ao=()=>({min:0,max:0}),pe=()=>({x:ao(),y:ao()}),mi={current:null},oo={current:!1};function vh(){if(oo.current=!0,!!hr)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>mi.current=e.matches;e.addEventListener("change",t),t()}else mi.current=!1}const bh=new WeakMap;function xh(e,t,n){for(const r in t){const i=t[r],s=n[r];if(xe(i))e.addValue(r,i);else if(xe(s))e.addValue(r,Lt(i,{owner:e}));else if(s!==i)if(e.hasValue(r)){const a=e.getValue(r);a.liveStyle===!0?a.jump(i):a.hasAnimated||a.set(i)}else{const a=e.getStaticValue(r);e.addValue(r,Lt(a!==void 0?a:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const lo=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class wh{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,blockInitialAnimation:s,visualState:a},o={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Yr,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const f=Ee.now();this.renderScheduledAt<f&&(this.renderScheduledAt=f,oe.render(this.render,!1,!0))};const{latestValues:u,renderState:d}=a;this.latestValues=u,this.baseTarget={...u},this.initialValues=n.initial?{...u}:{},this.renderState=d,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=o,this.blockInitialAnimation=!!s,this.isControllingVariants=Nn(n),this.isVariantNode=Ra(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:l,...c}=this.scrapeMotionValuesFromProps(n,{},this);for(const f in c){const h=c[f];u[f]!==void 0&&xe(h)&&h.set(u[f])}}mount(t){this.current=t,bh.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),oo.current||vh(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:mi.current,process.env.NODE_ENV!=="production"&&br(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected.","reduced-motion-disabled"),this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),it(this.notifyUpdate),it(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=Ft.has(t);r&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&oe.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),s&&s(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Ot){const n=Ot[t];if(!n)continue;const{isEnabled:r,Feature:i}=n;if(!this.features[t]&&i&&r(this.props)&&(this.features[t]=new i(this)),this.features[t]){const s=this.features[t];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):pe()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<lo.length;r++){const i=lo[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const s="on"+i,a=t[s];a&&(this.propEventSubscriptions[i]=this.on(i,a))}this.prevMotionValues=xh(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Lt(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(vs(r)||xs(r))?r=parseFloat(r):!kd(r)&&at.test(n)&&(r=ba(t,n)),this.setBaseTarget(t,xe(r)?r.get():r)),xe(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const s=oi(this.props,n,this.presenceContext?.custom);s&&(r=s[t])}if(n&&r!==void 0)return r;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!xe(i)?i:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new vr),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Qr.render(this.render)}}class uo extends wh{constructor(){super(...arguments),this.KeyframeResolver=yd}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;xe(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function co(e,{style:t,vars:n},r,i){const s=e.style;let a;for(a in t)s[a]=t[a];i?.applyProjectionStyles(s,r);for(a in n)s.setProperty(a,n[a])}function Ah(e){return window.getComputedStyle(e)}class Sh extends uo{constructor(){super(...arguments),this.type="html",this.renderInstance=co}readValueFromInstance(t,n){if(Ft.has(n))return this.projection?.isProjecting?Br(n):Rf(t,n);{const r=Ah(t),i=(_s(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return io(t,n)}build(t,n,r){ii(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return li(t,n,r)}}const fo=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function Th(e,t,n,r){co(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(fo.has(i)?i:ui(i),t.attrs[i])}class Ph extends uo{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=pe}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Ft.has(n)){const r=va(n);return r&&r.default||0}return n=fo.has(n)?n:ui(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return Ya(t,n,r)}build(t,n,r){Ba(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,i){Th(t,n,r,i)}mount(t){this.isSVGTag=$a(t.tagName),super.mount(t)}}const Ch=(e,t)=>ai(e)?new Ph(t):new Sh(t,{allowProjection:e!==z.Fragment});function Ut(e,t,n){const r=e.getProps();return oi(r,t,n!==void 0?n:r.custom,e)}const pi=e=>Array.isArray(e);function Eh(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Lt(n))}function Ih(e){return pi(e)?e[e.length-1]||0:e}function kh(e,t){const n=Ut(e,t);let{transitionEnd:r={},transition:i={},...s}=n||{};s={...s,...r};for(const a in s){const o=Ih(s[a]);Eh(e,a,o)}}function Mh(e){return!!(xe(e)&&e.add)}function gi(e,t){const n=e.getValue("willChange");if(Mh(n))return n.add(t);if(!n&&Qe.WillChange){const r=new Qe.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function ho(e){return e.props[Ga]}const Dh=e=>e!==null;function jh(e,{repeat:t,repeatType:n="loop"},r){const i=e.filter(Dh),s=t&&n!=="loop"&&t%2===1?0:i.length-1;return i[s]}const Fh={type:"spring",stiffness:500,damping:25,restSpeed:10},Lh=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Oh={type:"keyframes",duration:.8},Rh={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},_h=(e,{keyframes:t})=>t.length>2?Oh:Ft.has(e)?e.startsWith("scale")?Lh(t[1]):Fh:Rh;function Vh({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:s,repeatType:a,repeatDelay:o,from:u,elapsed:d,...l}){return!!Object.keys(l).length}const yi=(e,t,n,r={},i,s)=>a=>{const o=Kr(r,e)||{},u=o.delay||r.delay||0;let{elapsed:d=0}=r;d=d-_e(u);const l={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...o,delay:-d,onUpdate:f=>{t.set(f),o.onUpdate&&o.onUpdate(f)},onComplete:()=>{a(),o.onComplete&&o.onComplete()},name:e,motionValue:t,element:s?void 0:i};Vh(o)||Object.assign(l,_h(e,l)),l.duration&&(l.duration=_e(l.duration)),l.repeatDelay&&(l.repeatDelay=_e(l.repeatDelay)),l.from!==void 0&&(l.keyframes[0]=l.from);let c=!1;if((l.type===!1||l.duration===0&&!l.repeatDelay)&&(Gr(l),l.delay===0&&(c=!0)),(Qe.instantAnimations||Qe.skipAnimations)&&(c=!0,Gr(l),l.delay=0),l.allowFlatten=!o.type&&!o.ease,c&&!s&&t.get()!==void 0){const f=jh(l.keyframes,o);if(f!==void 0){oe.update(()=>{l.onUpdate(f),l.onComplete()});return}}return o.isSync?new Vr(l):new sd(l)};function Nh({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function mo(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:a,...o}=t;r&&(s=r);const u=[],d=i&&e.animationState&&e.animationState.getState()[i];for(const l in o){const c=e.getValue(l,e.latestValues[l]??null),f=o[l];if(f===void 0||d&&Nh(d,l))continue;const h={delay:n,...Kr(s||{},l)},m=c.get();if(m!==void 0&&!c.isAnimating&&!Array.isArray(f)&&f===m&&!h.velocity)continue;let b=!1;if(window.MotionHandoffAnimation){const v=ho(e);if(v){const I=window.MotionHandoffAnimation(v,l,oe);I!==null&&(h.startTime=I,b=!0)}}gi(e,l),c.start(yi(l,c,f,e.shouldReduceMotion&&ha.has(l)?{type:!1}:h,e,b));const w=c.animation;w&&u.push(w)}return a&&Promise.all(u).then(()=>{oe.update(()=>{a&&kh(e,a)})}),u}function po(e,t,n,r=0,i=1){const s=Array.from(e).sort((d,l)=>d.sortNodePosition(l)).indexOf(t),a=e.size,o=(a-1)*r;return typeof n=="function"?n(s,a):i===1?s*r:o-s*r}function vi(e,t,n={}){const r=Ut(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const s=r?()=>Promise.all(mo(e,r,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:d=0,staggerChildren:l,staggerDirection:c}=i;return Uh(e,t,u,d,l,c,n)}:()=>Promise.resolve(),{when:o}=i;if(o){const[u,d]=o==="beforeChildren"?[s,a]:[a,s];return u().then(()=>d())}else return Promise.all([s(),a(n.delay)])}function Uh(e,t,n=0,r=0,i=0,s=1,a){const o=[];for(const u of e.variantChildren)u.notify("AnimationStart",t),o.push(vi(u,t,{...a,delay:n+(typeof r=="function"?0:r)+po(e.variantChildren,u,r,i,s)}).then(()=>u.notify("AnimationComplete",t)));return Promise.all(o)}function Bh(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(s=>vi(e,s,n));r=Promise.all(i)}else if(typeof t=="string")r=vi(e,t,n);else{const i=typeof t=="function"?Ut(e,t,n.custom):t;r=Promise.all(mo(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}function go(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const zh=ni.length;function yo(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?yo(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<zh;n++){const r=ni[n],i=e.props[r];(an(i)||i===!1)&&(t[r]=i)}return t}const $h=[...ti].reverse(),Wh=ti.length;function Hh(e){return t=>Promise.all(t.map(({animation:n,options:r})=>Bh(e,n,r)))}function Yh(e){let t=Hh(e),n=vo(),r=!0;const i=u=>(d,l)=>{const c=Ut(e,l,u==="exit"?e.presenceContext?.custom:void 0);if(c){const{transition:f,transitionEnd:h,...m}=c;d={...d,...m,...h}}return d};function s(u){t=u(e)}function a(u){const{props:d}=e,l=yo(e.parent)||{},c=[],f=new Set;let h={},m=1/0;for(let w=0;w<Wh;w++){const v=$h[w],I=n[v],S=d[v]!==void 0?d[v]:l[v],E=an(S),P=v===u?I.isActive:null;P===!1&&(m=w);let A=S===l[v]&&S!==d[v]&&E;if(A&&r&&e.manuallyAnimateOnMount&&(A=!1),I.protectedKeys={...h},!I.isActive&&P===null||!S&&!I.prevProp||Vn(S)||typeof S=="boolean")continue;const O=Gh(I.prevProp,S);let p=O||v===u&&I.isActive&&!A&&E||w>m&&E,y=!1;const T=Array.isArray(S)?S:[S];let k=T.reduce(i(v),{});P===!1&&(k={});const{prevResolvedValues:M={}}=I,j={...M,...k},C=g=>{p=!0,f.has(g)&&(y=!0,f.delete(g)),I.needsAnimating[g]=!0;const _=e.getValue(g);_&&(_.liveStyle=!1)};for(const g in j){const _=k[g],L=M[g];if(h.hasOwnProperty(g))continue;let U=!1;pi(_)&&pi(L)?U=!go(_,L):U=_!==L,U?_!=null?C(g):f.add(g):_!==void 0&&f.has(g)?C(g):I.protectedKeys[g]=!0}I.prevProp=S,I.prevResolvedValues=k,I.isActive&&(h={...h,...k}),r&&e.blockInitialAnimation&&(p=!1);const R=A&&O;p&&(!R||y)&&c.push(...T.map(g=>{const _={type:v};if(typeof g=="string"&&r&&!R&&e.manuallyAnimateOnMount&&e.parent){const{parent:L}=e,U=Ut(L,g);if(L.enteringChildren&&U){const{delayChildren:F}=U.transition||{};_.delay=po(L.enteringChildren,e,F)}}return{animation:g,options:_}}))}if(f.size){const w={};if(typeof d.initial!="boolean"){const v=Ut(e,Array.isArray(d.initial)?d.initial[0]:d.initial);v&&v.transition&&(w.transition=v.transition)}f.forEach(v=>{const I=e.getBaseTarget(v),S=e.getValue(v);S&&(S.liveStyle=!0),w[v]=I??null}),c.push({animation:w})}let b=!!c.length;return r&&(d.initial===!1||d.initial===d.animate)&&!e.manuallyAnimateOnMount&&(b=!1),r=!1,b?t(c):Promise.resolve()}function o(u,d){if(n[u].isActive===d)return Promise.resolve();e.variantChildren?.forEach(c=>c.animationState?.setActive(u,d)),n[u].isActive=d;const l=a(u);for(const c in n)n[c].protectedKeys={};return l}return{animateChanges:a,setActive:o,setAnimateFunction:s,getState:()=>n,reset:()=>{n=vo()}}}function Gh(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!go(t,e):!1}function bt(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function vo(){return{animate:bt(!0),whileInView:bt(),whileHover:bt(),whileTap:bt(),whileDrag:bt(),whileFocus:bt(),exit:bt()}}class ot{constructor(t){this.isMounted=!1,this.node=t}update(){}}class Kh extends ot{constructor(t){super(t),t.animationState||(t.animationState=Yh(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Vn(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let Xh=0;class qh extends ot{constructor(){super(...arguments),this.id=Xh++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const i=this.node.animationState.setActive("exit",!t);n&&!t&&i.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const Qh={animation:{Feature:Kh},exit:{Feature:qh}};function ln(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function un(e){return{point:{x:e.pageX,y:e.pageY}}}const Zh=e=>t=>Zr(t)&&e(t,un(t));function cn(e,t,n,r){return ln(e,t,Zh(n),r)}const bo=1e-4,Jh=1-bo,em=1+bo,xo=.01,tm=0-xo,nm=0+xo;function Te(e){return e.max-e.min}function rm(e,t,n){return Math.abs(e-t)<=n}function wo(e,t,n,r=.5){e.origin=r,e.originPoint=ce(t.min,t.max,e.origin),e.scale=Te(n)/Te(t),e.translate=ce(n.min,n.max,e.origin)-e.originPoint,(e.scale>=Jh&&e.scale<=em||isNaN(e.scale))&&(e.scale=1),(e.translate>=tm&&e.translate<=nm||isNaN(e.translate))&&(e.translate=0)}function fn(e,t,n,r){wo(e.x,t.x,n.x,r?r.originX:void 0),wo(e.y,t.y,n.y,r?r.originY:void 0)}function Ao(e,t,n){e.min=n.min+t.min,e.max=e.min+Te(t)}function im(e,t,n){Ao(e.x,t.x,n.x),Ao(e.y,t.y,n.y)}function So(e,t,n){e.min=t.min-n.min,e.max=e.min+Te(t)}function zn(e,t,n){So(e.x,t.x,n.x),So(e.y,t.y,n.y)}function Oe(e){return[e("x"),e("y")]}const To=({current:e})=>e?e.ownerDocument.defaultView:null,Po=(e,t)=>Math.abs(e-t);function sm(e,t){const n=Po(e.x,t.x),r=Po(e.y,t.y);return Math.sqrt(n**2+r**2)}class Co{constructor(t,n,{transformPagePoint:r,contextWindow:i=window,dragSnapToOrigin:s=!1,distanceThreshold:a=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const f=xi(this.lastMoveEventInfo,this.history),h=this.startEvent!==null,m=sm(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!h&&!m)return;const{point:b}=f,{timestamp:w}=ye;this.history.push({...b,timestamp:w});const{onStart:v,onMove:I}=this.handlers;h||(v&&v(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),I&&I(this.lastMoveEvent,f)},this.handlePointerMove=(f,h)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=bi(h,this.transformPagePoint),oe.update(this.updatePoint,!0)},this.handlePointerUp=(f,h)=>{this.end();const{onEnd:m,onSessionEnd:b,resumeAnimation:w}=this.handlers;if(this.dragSnapToOrigin&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const v=xi(f.type==="pointercancel"?this.lastMoveEventInfo:bi(h,this.transformPagePoint),this.history);this.startEvent&&m&&m(f,v),b&&b(f,v)},!Zr(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=a,this.contextWindow=i||window;const o=un(t),u=bi(o,this.transformPagePoint),{point:d}=u,{timestamp:l}=ye;this.history=[{...d,timestamp:l}];const{onSessionStart:c}=n;c&&c(t,xi(u,this.history)),this.removeListeners=Qt(cn(this.contextWindow,"pointermove",this.handlePointerMove),cn(this.contextWindow,"pointerup",this.handlePointerUp),cn(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),it(this.updatePoint)}}function bi(e,t){return t?{point:t(e.point)}:e}function Eo(e,t){return{x:e.x-t.x,y:e.y-t.y}}function xi({point:e},t){return{point:e,delta:Eo(e,Io(t)),offset:Eo(e,am(t)),velocity:om(t,.1)}}function am(e){return e[0]}function Io(e){return e[e.length-1]}function om(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=Io(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>_e(t)));)n--;if(!r)return{x:0,y:0};const s=Le(i.timestamp-r.timestamp);if(s===0)return{x:0,y:0};const a={x:(i.x-r.x)/s,y:(i.y-r.y)/s};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function lm(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?ce(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?ce(n,e,r.max):Math.min(e,n)),e}function ko(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function um(e,{top:t,left:n,bottom:r,right:i}){return{x:ko(e.x,n,i),y:ko(e.y,t,r)}}function Mo(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function cm(e,t){return{x:Mo(e.x,t.x),y:Mo(e.y,t.y)}}function fm(e,t){let n=.5;const r=Te(e),i=Te(t);return i>r?n=Zt(t.min,t.max-r,e.min):r>i&&(n=Zt(e.min,e.max-i,t.min)),Xe(0,1,n)}function dm(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const wi=.35;function hm(e=wi){return e===!1?e=0:e===!0&&(e=wi),{x:Do(e,"left","right"),y:Do(e,"top","bottom")}}function Do(e,t,n){return{min:jo(e,t),max:jo(e,n)}}function jo(e,t){return typeof e=="number"?e:e[t]||0}const mm=new WeakMap;class pm{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=pe(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const s=c=>{const{dragSnapToOrigin:f}=this.getProps();f?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(un(c).point)},a=(c,f)=>{const{drag:h,dragPropagation:m,onDragStart:b}=this.getProps();if(h&&!m&&(this.openDragLock&&this.openDragLock(),this.openDragLock=wd(h),!this.openDragLock))return;this.latestPointerEvent=c,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Oe(v=>{let I=this.getAxisMotionValue(v).get()||0;if(We.test(I)){const{projection:S}=this.visualElement;if(S&&S.layout){const E=S.layout.layoutBox[v];E&&(I=Te(E)*(parseFloat(I)/100))}}this.originPoint[v]=I}),b&&oe.postRender(()=>b(c,f)),gi(this.visualElement,"transform");const{animationState:w}=this.visualElement;w&&w.setActive("whileDrag",!0)},o=(c,f)=>{this.latestPointerEvent=c,this.latestPanInfo=f;const{dragPropagation:h,dragDirectionLock:m,onDirectionLock:b,onDrag:w}=this.getProps();if(!h&&!this.openDragLock)return;const{offset:v}=f;if(m&&this.currentDirection===null){this.currentDirection=gm(v),this.currentDirection!==null&&b&&b(this.currentDirection);return}this.updateAxis("x",f.point,v),this.updateAxis("y",f.point,v),this.visualElement.render(),w&&w(c,f)},u=(c,f)=>{this.latestPointerEvent=c,this.latestPanInfo=f,this.stop(c,f),this.latestPointerEvent=null,this.latestPanInfo=null},d=()=>Oe(c=>this.getAnimationState(c)==="paused"&&this.getAxisMotionValue(c).animation?.play()),{dragSnapToOrigin:l}=this.getProps();this.panSession=new Co(t,{onSessionStart:s,onStart:a,onMove:o,onSessionEnd:u,resumeAnimation:d},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:l,distanceThreshold:r,contextWindow:To(this.visualElement)})}stop(t,n){const r=t||this.latestPointerEvent,i=n||this.latestPanInfo,s=this.isDragging;if(this.cancel(),!s||!i||!r)return;const{velocity:a}=i;this.startAnimation(a);const{onDragEnd:o}=this.getProps();o&&oe.postRender(()=>o(r,i))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!$n(t,i,this.currentDirection))return;const s=this.getAxisMotionValue(t);let a=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(a=lm(a,this.constraints[t],this.elastic[t])),s.set(a)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,i=this.constraints;t&&Rt(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=um(r.layoutBox,t):this.constraints=!1,this.elastic=hm(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Oe(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=dm(r.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Rt(t))return!1;const r=t.current;qe(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");const{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const s=yh(r,i.root,this.visualElement.getTransformPagePoint());let a=cm(i.layout.layoutBox,s);if(n){const o=n(mh(a));this.hasMutatedConstraints=!!o,o&&(a=qa(o))}return a}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:s,dragSnapToOrigin:a,onDragTransitionEnd:o}=this.getProps(),u=this.constraints||{},d=Oe(l=>{if(!$n(l,n,this.currentDirection))return;let c=u&&u[l]||{};a&&(c={min:0,max:0});const f=i?200:1e6,h=i?40:1e7,m={type:"inertia",velocity:r?t[l]:0,bounceStiffness:f,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10,...s,...c};return this.startAxisValueAnimation(l,m)});return Promise.all(d).then(o)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return gi(this.visualElement,t),r.start(yi(t,r,0,n,this.visualElement,!1))}stopAnimation(){Oe(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Oe(t=>this.getAxisMotionValue(t).animation?.pause())}getAnimationState(t){return this.getAxisMotionValue(t).animation?.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Oe(n=>{const{drag:r}=this.getProps();if(!$n(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,s=this.getAxisMotionValue(n);if(i&&i.layout){const{min:a,max:o}=i.layout.layoutBox[n];s.set(t[n]-ce(a,o,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Rt(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Oe(a=>{const o=this.getAxisMotionValue(a);if(o&&this.constraints!==!1){const u=o.get();i[a]=fm({min:u,max:u},this.constraints[a])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Oe(a=>{if(!$n(a,t,null))return;const o=this.getAxisMotionValue(a),{min:u,max:d}=this.constraints[a];o.set(ce(u,d,i[a]))})}addListeners(){if(!this.visualElement.current)return;mm.set(this.visualElement,this);const t=this.visualElement.current,n=cn(t,"pointerdown",u=>{const{drag:d,dragListener:l=!0}=this.getProps();d&&l&&this.start(u)}),r=()=>{const{dragConstraints:u}=this.getProps();Rt(u)&&u.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,s=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),oe.read(r);const a=ln(window,"resize",()=>this.scalePositionWithinConstraints()),o=i.addEventListener("didUpdate",(({delta:u,hasLayoutChanged:d})=>{this.isDragging&&d&&(Oe(l=>{const c=this.getAxisMotionValue(l);c&&(this.originPoint[l]+=u[l].translate,c.set(c.get()+u[l].translate))}),this.visualElement.render())}));return()=>{a(),n(),s(),o&&o()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:s=!1,dragElastic:a=wi,dragMomentum:o=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:s,dragElastic:a,dragMomentum:o}}}function $n(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function gm(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class ym extends ot{constructor(t){super(t),this.removeGroupControls=Fe,this.removeListeners=Fe,this.controls=new pm(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Fe}unmount(){this.removeGroupControls(),this.removeListeners()}}const Fo=e=>(t,n)=>{e&&oe.postRender(()=>e(t,n))};class vm extends ot{constructor(){super(...arguments),this.removePointerDownListener=Fe}onPointerDown(t){this.session=new Co(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:To(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:Fo(t),onStart:Fo(n),onMove:r,onEnd:(s,a)=>{delete this.session,i&&oe.postRender(()=>i(s,a))}}}mount(){this.removePointerDownListener=cn(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const Wn={hasAnimatedSinceResize:!0,hasEverUpdated:!1};let Ai=!1;class bm extends z.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:s}=t;s&&(n.group&&n.group.add(s),r&&r.register&&i&&r.register(s),Ai&&s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,onExitComplete:()=>this.safeToRemove()})),Wn.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:s}=this.props,{projection:a}=r;return a&&(a.isPresent=s,Ai=!0,i||t.layoutDependency!==n||n===void 0||t.isPresent!==s?a.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?a.promote():a.relegate()||oe.postRender(()=>{const o=a.getStack();(!o||!o.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),Qr.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;Ai=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Lo(e){const[t,n]=Da(),r=z.useContext(fr);return D.jsx(bm,{...e,layoutGroup:r,switchLayoutGroup:z.useContext(Ka),isPresent:t,safeToRemove:n})}function xm(e,t,n){const r=xe(e)?e:Lt(e);return r.start(yi("",r,t,n)),r.animation}const wm=(e,t)=>e.depth-t.depth;class Am{constructor(){this.children=[],this.isDirty=!1}add(t){mr(this.children,t),this.isDirty=!0}remove(t){pr(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(wm),this.isDirty=!1,this.children.forEach(t)}}function Sm(e,t){const n=Ee.now(),r=({timestamp:i})=>{const s=i-n;s>=t&&(it(r),e(s-t))};return oe.setup(r,!0),()=>it(r)}const Oo=["TopLeft","TopRight","BottomLeft","BottomRight"],Tm=Oo.length,Ro=e=>typeof e=="string"?parseFloat(e):e,_o=e=>typeof e=="number"||q.test(e);function Pm(e,t,n,r,i,s){i?(e.opacity=ce(0,n.opacity??1,Cm(r)),e.opacityExit=ce(t.opacity??1,0,Em(r))):s&&(e.opacity=ce(t.opacity??1,n.opacity??1,r));for(let a=0;a<Tm;a++){const o=`border${Oo[a]}Radius`;let u=Vo(t,o),d=Vo(n,o);if(u===void 0&&d===void 0)continue;u||(u=0),d||(d=0),u===0||d===0||_o(u)===_o(d)?(e[o]=Math.max(ce(Ro(u),Ro(d),r),0),(We.test(d)||We.test(u))&&(e[o]+="%")):e[o]=d}(t.rotate||n.rotate)&&(e.rotate=ce(t.rotate||0,n.rotate||0,r))}function Vo(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const Cm=No(0,.5,ks),Em=No(.5,.95,Fe);function No(e,t,n){return r=>r<e?0:r>t?1:n(Zt(e,t,r))}function Uo(e,t){e.min=t.min,e.max=t.max}function Ne(e,t){Uo(e.x,t.x),Uo(e.y,t.y)}function Bo(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function zo(e,t,n,r,i){return e-=t,e=Bn(e,1/n,r),i!==void 0&&(e=Bn(e,1/i,r)),e}function Im(e,t=0,n=1,r=.5,i,s=e,a=e){if(We.test(t)&&(t=parseFloat(t),t=ce(a.min,a.max,t/100)-a.min),typeof t!="number")return;let o=ce(s.min,s.max,r);e===s&&(o-=t),e.min=zo(e.min,t,n,o,i),e.max=zo(e.max,t,n,o,i)}function $o(e,t,[n,r,i],s,a){Im(e,t[n],t[r],t[i],t.scale,s,a)}const km=["x","scaleX","originX"],Mm=["y","scaleY","originY"];function Wo(e,t,n,r){$o(e.x,t,km,n?n.x:void 0,r?r.x:void 0),$o(e.y,t,Mm,n?n.y:void 0,r?r.y:void 0)}function Ho(e){return e.translate===0&&e.scale===1}function Yo(e){return Ho(e.x)&&Ho(e.y)}function Go(e,t){return e.min===t.min&&e.max===t.max}function Dm(e,t){return Go(e.x,t.x)&&Go(e.y,t.y)}function Ko(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Xo(e,t){return Ko(e.x,t.x)&&Ko(e.y,t.y)}function qo(e){return Te(e.x)/Te(e.y)}function Qo(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class jm{constructor(){this.members=[]}add(t){mr(this.members,t),t.scheduleRender()}remove(t){if(pr(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const s=this.members[i];if(s.isPresent!==!1){r=s;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:i}=t.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function Fm(e,t,n){let r="";const i=e.x.translate/t.x,s=e.y.translate/t.y,a=n?.z||0;if((i||s||a)&&(r=`translate3d(${i}px, ${s}px, ${a}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:d,rotate:l,rotateX:c,rotateY:f,skewX:h,skewY:m}=n;d&&(r=`perspective(${d}px) ${r}`),l&&(r+=`rotate(${l}deg) `),c&&(r+=`rotateX(${c}deg) `),f&&(r+=`rotateY(${f}deg) `),h&&(r+=`skewX(${h}deg) `),m&&(r+=`skewY(${m}deg) `)}const o=e.x.scale*t.x,u=e.y.scale*t.y;return(o!==1||u!==1)&&(r+=`scale(${o}, ${u})`),r||"none"}const Si=["","X","Y","Z"],Lm=1e3;let Om=0;function Ti(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Zo(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=ho(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:s}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",oe,!(i||s))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Zo(r)}function Jo({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(a={},o=t?.()){this.id=Om++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(Vm),this.nodes.forEach(zm),this.nodes.forEach($m),this.nodes.forEach(Nm)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=a,this.root=o?o.root||o:this,this.path=o?[...o.path,o]:[],this.parent=o,this.depth=o?o.depth+1:0;for(let u=0;u<this.path.length;u++)this.path[u].shouldResetTransform=!0;this.root===this&&(this.nodes=new Am)}addEventListener(a,o){return this.eventHandlers.has(a)||this.eventHandlers.set(a,new vr),this.eventHandlers.get(a).add(o)}notifyListeners(a,...o){const u=this.eventHandlers.get(a);u&&u.notify(...o)}hasListeners(a){return this.eventHandlers.has(a)}mount(a){if(this.instance)return;this.isSVG=ka(a)&&!Ed(a),this.instance=a;const{layoutId:o,layout:u,visualElement:d}=this.options;if(d&&!d.current&&d.mount(a),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(u||o)&&(this.isLayoutDirty=!0),e){let l,c=0;const f=()=>this.root.updateBlockedByResize=!1;oe.read(()=>{c=window.innerWidth}),e(a,()=>{const h=window.innerWidth;h!==c&&(c=h,this.root.updateBlockedByResize=!0,l&&l(),l=Sm(f,250),Wn.hasAnimatedSinceResize&&(Wn.hasAnimatedSinceResize=!1,this.nodes.forEach(nl)))})}o&&this.root.registerSharedNode(o,this),this.options.animate!==!1&&d&&(o||u)&&this.addEventListener("didUpdate",({delta:l,hasLayoutChanged:c,hasRelativeLayoutChanged:f,layout:h})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const m=this.options.transition||d.getDefaultTransition()||Km,{onLayoutAnimationStart:b,onLayoutAnimationComplete:w}=d.getProps(),v=!this.targetLayout||!Xo(this.targetLayout,h),I=!c&&f;if(this.options.layoutRoot||this.resumeFrom||I||c&&(v||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const S={...Kr(m,"layout"),onPlay:b,onComplete:w};(d.shouldReduceMotion||this.options.layoutRoot)&&(S.delay=0,S.type=!1),this.startAnimation(S),this.setAnimationOrigin(l,I)}else c||nl(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=h})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const a=this.getStack();a&&a.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),it(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(Wm),this.animationId++)}getTransformTemplate(){const{visualElement:a}=this.options;return a&&a.getProps().transformTemplate}willUpdate(a=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Zo(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let l=0;l<this.path.length;l++){const c=this.path[l];c.shouldResetTransform=!0,c.updateScroll("snapshot"),c.options.layoutRoot&&c.willUpdate(!1)}const{layoutId:o,layout:u}=this.options;if(o===void 0&&!u)return;const d=this.getTransformTemplate();this.prevTransformTemplateValue=d?d(this.latestValues,""):void 0,this.updateSnapshot(),a&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(el);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(tl);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Bm),this.nodes.forEach(Rm),this.nodes.forEach(_m)):this.nodes.forEach(tl),this.clearAllSnapshots();const o=Ee.now();ye.delta=Xe(0,1e3/60,o-ye.timestamp),ye.timestamp=o,ye.isProcessing=!0,Ar.update.process(ye),Ar.preRender.process(ye),Ar.render.process(ye),ye.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Qr.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Um),this.sharedNodes.forEach(Hm)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,oe.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){oe.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Te(this.snapshot.measuredBox.x)&&!Te(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let u=0;u<this.path.length;u++)this.path[u].updateScroll();const a=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=pe(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:o}=this.options;o&&o.notify("LayoutMeasure",this.layout.layoutBox,a?a.layoutBox:void 0)}updateScroll(a="measure"){let o=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===a&&(o=!1),o&&this.instance){const u=r(this.instance);this.scroll={animationId:this.root.animationId,phase:a,isRoot:u,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:u}}}resetTransform(){if(!i)return;const a=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,o=this.projectionDelta&&!Yo(this.projectionDelta),u=this.getTransformTemplate(),d=u?u(this.latestValues,""):void 0,l=d!==this.prevTransformTemplateValue;a&&this.instance&&(o||vt(this.latestValues)||l)&&(i(this.instance,d),this.shouldResetTransform=!1,this.scheduleRender())}measure(a=!0){const o=this.measurePageBox();let u=this.removeElementScroll(o);return a&&(u=this.removeTransform(u)),Xm(u),{animationId:this.root.animationId,measuredBox:o,layoutBox:u,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:a}=this.options;if(!a)return pe();const o=a.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(qm))){const{scroll:d}=this.root;d&&(_t(o.x,d.offset.x),_t(o.y,d.offset.y))}return o}removeElementScroll(a){const o=pe();if(Ne(o,a),this.scroll?.wasRoot)return o;for(let u=0;u<this.path.length;u++){const d=this.path[u],{scroll:l,options:c}=d;d!==this.root&&l&&c.layoutScroll&&(l.wasRoot&&Ne(o,a),_t(o.x,l.offset.x),_t(o.y,l.offset.y))}return o}applyTransform(a,o=!1){const u=pe();Ne(u,a);for(let d=0;d<this.path.length;d++){const l=this.path[d];!o&&l.options.layoutScroll&&l.scroll&&l!==l.root&&Vt(u,{x:-l.scroll.offset.x,y:-l.scroll.offset.y}),vt(l.latestValues)&&Vt(u,l.latestValues)}return vt(this.latestValues)&&Vt(u,this.latestValues),u}removeTransform(a){const o=pe();Ne(o,a);for(let u=0;u<this.path.length;u++){const d=this.path[u];if(!d.instance||!vt(d.latestValues))continue;di(d.latestValues)&&d.updateSnapshot();const l=pe(),c=d.measurePageBox();Ne(l,c),Wo(o,d.latestValues,d.snapshot?d.snapshot.layoutBox:void 0,l)}return vt(this.latestValues)&&Wo(o,this.latestValues),o}setTargetDelta(a){this.targetDelta=a,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(a){this.options={...this.options,...a,crossfade:a.crossfade!==void 0?a.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==ye.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(a=!1){const o=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=o.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=o.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=o.isSharedProjectionDirty);const u=!!this.resumingFrom||this!==o;if(!(a||u&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:l,layoutId:c}=this.options;if(!this.layout||!(l||c))return;this.resolvedRelativeTargetAt=ye.timestamp;const f=this.getClosestProjectingParent();f&&this.linkedParentVersion!==f.layoutVersion&&!f.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(f&&f.layout?this.createRelativeTarget(f,this.layout.layoutBox,f.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=pe(),this.targetWithTransforms=pe()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),im(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Ne(this.target,this.layout.layoutBox),eo(this.target,this.targetDelta)):Ne(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,f&&!!f.resumingFrom==!!this.resumingFrom&&!f.options.layoutScroll&&f.target&&this.animationProgress!==1?this.createRelativeTarget(f,this.target,f.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||di(this.parent.latestValues)||Qa(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(a,o,u){this.relativeParent=a,this.linkedParentVersion=a.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=pe(),this.relativeTargetOrigin=pe(),zn(this.relativeTargetOrigin,o,u),Ne(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){const a=this.getLead(),o=!!this.resumingFrom||this!==a;let u=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(u=!1),o&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(u=!1),this.resolvedRelativeTargetAt===ye.timestamp&&(u=!1),u)return;const{layout:d,layoutId:l}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(d||l))return;Ne(this.layoutCorrected,this.layout.layoutBox);const c=this.treeScale.x,f=this.treeScale.y;gh(this.layoutCorrected,this.treeScale,this.path,o),a.layout&&!a.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(a.target=a.layout.layoutBox,a.targetWithTransforms=pe());const{target:h}=a;if(!h){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Bo(this.prevProjectionDelta.x,this.projectionDelta.x),Bo(this.prevProjectionDelta.y,this.projectionDelta.y)),fn(this.projectionDelta,this.layoutCorrected,h,this.latestValues),(this.treeScale.x!==c||this.treeScale.y!==f||!Qo(this.projectionDelta.x,this.prevProjectionDelta.x)||!Qo(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",h))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(a=!0){if(this.options.visualElement?.scheduleRender(),a){const o=this.getStack();o&&o.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Nt(),this.projectionDelta=Nt(),this.projectionDeltaWithTransform=Nt()}setAnimationOrigin(a,o=!1){const u=this.snapshot,d=u?u.latestValues:{},l={...this.latestValues},c=Nt();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!o;const f=pe(),h=u?u.source:void 0,m=this.layout?this.layout.source:void 0,b=h!==m,w=this.getStack(),v=!w||w.members.length<=1,I=!!(b&&!v&&this.options.crossfade===!0&&!this.path.some(Gm));this.animationProgress=0;let S;this.mixTargetDelta=E=>{const P=E/1e3;rl(c.x,a.x,P),rl(c.y,a.y,P),this.setTargetDelta(c),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(zn(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Ym(this.relativeTarget,this.relativeTargetOrigin,f,P),S&&Dm(this.relativeTarget,S)&&(this.isProjectionDirty=!1),S||(S=pe()),Ne(S,this.relativeTarget)),b&&(this.animationValues=l,Pm(l,d,this.latestValues,P,I,v)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=P},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(a){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(it(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=oe.update(()=>{Wn.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Lt(0)),this.currentAnimation=xm(this.motionValue,[0,1e3],{...a,velocity:0,isSync:!0,onUpdate:o=>{this.mixTargetDelta(o),a.onUpdate&&a.onUpdate(o)},onStop:()=>{},onComplete:()=>{a.onComplete&&a.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const a=this.getStack();a&&a.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Lm),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const a=this.getLead();let{targetWithTransforms:o,target:u,layout:d,latestValues:l}=a;if(!(!o||!u||!d)){if(this!==a&&this.layout&&d&&ll(this.options.animationType,this.layout.layoutBox,d.layoutBox)){u=this.target||pe();const c=Te(this.layout.layoutBox.x);u.x.min=a.target.x.min,u.x.max=u.x.min+c;const f=Te(this.layout.layoutBox.y);u.y.min=a.target.y.min,u.y.max=u.y.min+f}Ne(o,u),Vt(o,l),fn(this.projectionDeltaWithTransform,this.layoutCorrected,o,l)}}registerSharedNode(a,o){this.sharedNodes.has(a)||this.sharedNodes.set(a,new jm),this.sharedNodes.get(a).add(o);const d=o.options.initialPromotionConfig;o.promote({transition:d?d.transition:void 0,preserveFollowOpacity:d&&d.shouldPreserveFollowOpacity?d.shouldPreserveFollowOpacity(o):void 0})}isLead(){const a=this.getStack();return a?a.lead===this:!0}getLead(){const{layoutId:a}=this.options;return a?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:a}=this.options;return a?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:a}=this.options;if(a)return this.root.sharedNodes.get(a)}promote({needsReset:a,transition:o,preserveFollowOpacity:u}={}){const d=this.getStack();d&&d.promote(this,u),a&&(this.projectionDelta=void 0,this.needsReset=!0),o&&this.setOptions({transition:o})}relegate(){const a=this.getStack();return a?a.relegate(this):!1}resetSkewAndRotation(){const{visualElement:a}=this.options;if(!a)return;let o=!1;const{latestValues:u}=a;if((u.z||u.rotate||u.rotateX||u.rotateY||u.rotateZ||u.skewX||u.skewY)&&(o=!0),!o)return;const d={};u.z&&Ti("z",a,d,this.animationValues);for(let l=0;l<Si.length;l++)Ti(`rotate${Si[l]}`,a,d,this.animationValues),Ti(`skew${Si[l]}`,a,d,this.animationValues);a.render();for(const l in d)a.setStaticValue(l,d[l]),this.animationValues&&(this.animationValues[l]=d[l]);a.scheduleRender()}applyProjectionStyles(a,o){if(!this.instance||this.isSVG)return;if(!this.isVisible){a.visibility="hidden";return}const u=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,a.visibility="",a.opacity="",a.pointerEvents=Un(o?.pointerEvents)||"",a.transform=u?u(this.latestValues,""):"none";return}const d=this.getLead();if(!this.projectionDelta||!this.layout||!d.target){this.options.layoutId&&(a.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,a.pointerEvents=Un(o?.pointerEvents)||""),this.hasProjected&&!vt(this.latestValues)&&(a.transform=u?u({},""):"none",this.hasProjected=!1);return}a.visibility="";const l=d.animationValues||d.latestValues;this.applyTransformsToTarget();let c=Fm(this.projectionDeltaWithTransform,this.treeScale,l);u&&(c=u(l,c)),a.transform=c;const{x:f,y:h}=this.projectionDelta;a.transformOrigin=`${f.origin*100}% ${h.origin*100}% 0`,d.animationValues?a.opacity=d===this?l.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:l.opacityExit:a.opacity=d===this?l.opacity!==void 0?l.opacity:"":l.opacityExit!==void 0?l.opacityExit:0;for(const m in ri){if(l[m]===void 0)continue;const{correct:b,applyTo:w,isCSSVariable:v}=ri[m],I=c==="none"?l[m]:b(l[m],d);if(w){const S=w.length;for(let E=0;E<S;E++)a[w[E]]=I}else v?this.options.visualElement.renderState.vars[m]=I:a[m]=I}this.options.layoutId&&(a.pointerEvents=d===this?Un(o?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(a=>a.currentAnimation?.stop()),this.root.nodes.forEach(el),this.root.sharedNodes.clear()}}}function Rm(e){e.updateLayout()}function _m(e){const t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:r}=e.layout,{animationType:i}=e.options,s=t.source!==e.layout.source;i==="size"?Oe(l=>{const c=s?t.measuredBox[l]:t.layoutBox[l],f=Te(c);c.min=n[l].min,c.max=c.min+f}):ll(i,t.layoutBox,n)&&Oe(l=>{const c=s?t.measuredBox[l]:t.layoutBox[l],f=Te(n[l]);c.max=c.min+f,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[l].max=e.relativeTarget[l].min+f)});const a=Nt();fn(a,n,t.layoutBox);const o=Nt();s?fn(o,e.applyTransform(r,!0),t.measuredBox):fn(o,n,t.layoutBox);const u=!Yo(a);let d=!1;if(!e.resumeFrom){const l=e.getClosestProjectingParent();if(l&&!l.resumeFrom){const{snapshot:c,layout:f}=l;if(c&&f){const h=pe();zn(h,t.layoutBox,c.layoutBox);const m=pe();zn(m,n,f.layoutBox),Xo(h,m)||(d=!0),l.options.layoutRoot&&(e.relativeTarget=m,e.relativeTargetOrigin=h,e.relativeParent=l)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:t,delta:o,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:d})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function Vm(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Nm(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Um(e){e.clearSnapshot()}function el(e){e.clearMeasurements()}function tl(e){e.isLayoutDirty=!1}function Bm(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function nl(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function zm(e){e.resolveTargetDelta()}function $m(e){e.calcProjection()}function Wm(e){e.resetSkewAndRotation()}function Hm(e){e.removeLeadSnapshot()}function rl(e,t,n){e.translate=ce(t.translate,0,n),e.scale=ce(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function il(e,t,n,r){e.min=ce(t.min,n.min,r),e.max=ce(t.max,n.max,r)}function Ym(e,t,n,r){il(e.x,t.x,n.x,r),il(e.y,t.y,n.y,r)}function Gm(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const Km={duration:.45,ease:[.4,0,.1,1]},sl=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),al=sl("applewebkit/")&&!sl("chrome/")?Math.round:Fe;function ol(e){e.min=al(e.min),e.max=al(e.max)}function Xm(e){ol(e.x),ol(e.y)}function ll(e,t,n){return e==="position"||e==="preserve-aspect"&&!rm(qo(t),qo(n),.2)}function qm(e){return e!==e.root&&e.scroll?.wasRoot}const Qm=Jo({attachResizeListener:(e,t)=>ln(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Pi={current:void 0},ul=Jo({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Pi.current){const e=new Qm({});e.mount(window),e.setOptions({layoutScroll:!0}),Pi.current=e}return Pi.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Zm={pan:{Feature:vm},drag:{Feature:ym,ProjectionNode:ul,MeasureLayout:Lo}};function cl(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,s=r[i];s&&oe.postRender(()=>s(t,un(t)))}class Jm extends ot{mount(){const{current:t}=this.node;t&&(this.unmount=Ad(t,(n,r)=>(cl(this.node,r,"Start"),i=>cl(this.node,i,"End"))))}unmount(){}}class ep extends ot{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Qt(ln(this.node.current,"focus",()=>this.onFocus()),ln(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function fl(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),s=r[i];s&&oe.postRender(()=>s(t,un(t)))}class tp extends ot{mount(){const{current:t}=this.node;t&&(this.unmount=Cd(t,(n,r)=>(fl(this.node,r,"Start"),(i,{success:s})=>fl(this.node,i,s?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Ci=new WeakMap,Ei=new WeakMap,np=e=>{const t=Ci.get(e.target);t&&t(e)},rp=e=>{e.forEach(np)};function ip({root:e,...t}){const n=e||document;Ei.has(n)||Ei.set(n,{});const r=Ei.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(rp,{root:e,...t})),r[i]}function sp(e,t,n){const r=ip(t);return Ci.set(e,n),r.observe(e),()=>{Ci.delete(e),r.unobserve(e)}}const ap={some:0,all:1};class op extends ot{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:s}=t,a={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:ap[i]},o=u=>{const{isIntersecting:d}=u;if(this.isInView===d||(this.isInView=d,s&&!d&&this.hasEnteredView))return;d&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",d);const{onViewportEnter:l,onViewportLeave:c}=this.node.getProps(),f=d?l:c;f&&f(u)};return sp(this.node.current,a,o)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(lp(t,n))&&this.startObserver()}unmount(){}}function lp({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const up={...Qh,...{inView:{Feature:op},tap:{Feature:tp},focus:{Feature:ep},hover:{Feature:Jm}},...Zm,...{layout:{ProjectionNode:ul,MeasureLayout:Lo}}},dl=hh(up,Ch);function Ii(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function cp(e){if(Array.isArray(e))return e}function fp(e){if(Array.isArray(e))return Ii(e)}function dp(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function hp(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,ml(r.key),r)}}function mp(e,t,n){return t&&hp(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Hn(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=ki(e))||t){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(u){throw u},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
15
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var s,a=!0,o=!1;return{s:function(){n=n.call(e)},n:function(){var u=n.next();return a=u.done,u},e:function(u){o=!0,s=u},f:function(){try{a||n.return==null||n.return()}finally{if(o)throw s}}}}function Z(e,t,n){return(t=ml(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function pp(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function gp(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,s,a,o=[],u=!0,d=!1;try{if(s=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=s.call(n)).done)&&(o.push(r.value),o.length!==t);u=!0);}catch(l){d=!0,i=l}finally{try{if(!u&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(d)throw i}}return o}}function yp(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
16
16
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vp(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
17
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function hl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function $(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?hl(Object(n),!0).forEach(function(r){J(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hl(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Yn(e,t){return cp(e)||gp(e,t)||ki(e,t)||yp()}function Ue(e){return fp(e)||pp(e)||ki(e)||vp()}function bp(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ml(e){var t=bp(e,"string");return typeof t=="symbol"?t:t+""}function Gn(e){"@babel/helpers - typeof";return Gn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Gn(e)}function ki(e,t){if(e){if(typeof e=="string")return Ii(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ii(e,t):void 0}}var pl=function(){},Mi={},gl={},yl=null,vl={mark:pl,measure:pl};try{typeof window<"u"&&(Mi=window),typeof document<"u"&&(gl=document),typeof MutationObserver<"u"&&(yl=MutationObserver),typeof performance<"u"&&(vl=performance)}catch{}var xp=Mi.navigator||{},bl=xp.userAgent,xl=bl===void 0?"":bl,lt=Mi,re=gl,wl=yl,Kn=vl;lt.document;var Ze=!!re.documentElement&&!!re.head&&typeof re.addEventListener=="function"&&typeof re.createElement=="function",Al=~xl.indexOf("MSIE")||~xl.indexOf("Trident/"),Di,wp=/fa(k|kd|s|r|l|t|d|dr|dl|dt|b|slr|slpr|wsb|tl|ns|nds|es|jr|jfr|jdr|usb|ufsb|udsb|cr|ss|sr|sl|st|sds|sdr|sdl|sdt)?[\-\ ]/,Ap=/Font ?Awesome ?([567 ]*)(Solid|Regular|Light|Thin|Duotone|Brands|Free|Pro|Sharp Duotone|Sharp|Kit|Notdog Duo|Notdog|Chisel|Etch|Thumbprint|Jelly Fill|Jelly Duo|Jelly|Utility|Utility Fill|Utility Duo|Slab Press|Slab|Whiteboard)?.*/i,Sl={classic:{fa:"solid",fas:"solid","fa-solid":"solid",far:"regular","fa-regular":"regular",fal:"light","fa-light":"light",fat:"thin","fa-thin":"thin",fab:"brands","fa-brands":"brands"},duotone:{fa:"solid",fad:"solid","fa-solid":"solid","fa-duotone":"solid",fadr:"regular","fa-regular":"regular",fadl:"light","fa-light":"light",fadt:"thin","fa-thin":"thin"},sharp:{fa:"solid",fass:"solid","fa-solid":"solid",fasr:"regular","fa-regular":"regular",fasl:"light","fa-light":"light",fast:"thin","fa-thin":"thin"},"sharp-duotone":{fa:"solid",fasds:"solid","fa-solid":"solid",fasdr:"regular","fa-regular":"regular",fasdl:"light","fa-light":"light",fasdt:"thin","fa-thin":"thin"},slab:{"fa-regular":"regular",faslr:"regular"},"slab-press":{"fa-regular":"regular",faslpr:"regular"},thumbprint:{"fa-light":"light",fatl:"light"},whiteboard:{"fa-semibold":"semibold",fawsb:"semibold"},notdog:{"fa-solid":"solid",fans:"solid"},"notdog-duo":{"fa-solid":"solid",fands:"solid"},etch:{"fa-solid":"solid",faes:"solid"},jelly:{"fa-regular":"regular",fajr:"regular"},"jelly-fill":{"fa-regular":"regular",fajfr:"regular"},"jelly-duo":{"fa-regular":"regular",fajdr:"regular"},chisel:{"fa-regular":"regular",facr:"regular"},utility:{"fa-semibold":"semibold",fausb:"semibold"},"utility-duo":{"fa-semibold":"semibold",faudsb:"semibold"},"utility-fill":{"fa-semibold":"semibold",faufsb:"semibold"}},Sp={GROUP:"duotone-group",PRIMARY:"primary",SECONDARY:"secondary"},Tl=["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone","fa-thumbprint","fa-whiteboard","fa-notdog","fa-notdog-duo","fa-chisel","fa-etch","fa-jelly","fa-jelly-fill","fa-jelly-duo","fa-slab","fa-slab-press","fa-utility","fa-utility-duo","fa-utility-fill"],ye="classic",dn="duotone",Pl="sharp",Cl="sharp-duotone",El="chisel",Il="etch",kl="jelly",Ml="jelly-duo",Dl="jelly-fill",jl="notdog",Fl="notdog-duo",Ll="slab",Ol="slab-press",Rl="thumbprint",_l="utility",Vl="utility-duo",Nl="utility-fill",Ul="whiteboard",Tp="Classic",Pp="Duotone",Cp="Sharp",Ep="Sharp Duotone",Ip="Chisel",kp="Etch",Mp="Jelly",Dp="Jelly Duo",jp="Jelly Fill",Fp="Notdog",Lp="Notdog Duo",Op="Slab",Rp="Slab Press",_p="Thumbprint",Vp="Utility",Np="Utility Duo",Up="Utility Fill",Bp="Whiteboard",Bl=[ye,dn,Pl,Cl,El,Il,kl,Ml,Dl,jl,Fl,Ll,Ol,Rl,_l,Vl,Nl,Ul];Di={},J(J(J(J(J(J(J(J(J(J(Di,ye,Tp),dn,Pp),Pl,Cp),Cl,Ep),El,Ip),Il,kp),kl,Mp),Ml,Dp),Dl,jp),jl,Fp),J(J(J(J(J(J(J(J(Di,Fl,Lp),Ll,Op),Ol,Rp),Rl,_p),_l,Vp),Vl,Np),Nl,Up),Ul,Bp);var zp={classic:{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},duotone:{900:"fad",400:"fadr",300:"fadl",100:"fadt"},sharp:{900:"fass",400:"fasr",300:"fasl",100:"fast"},"sharp-duotone":{900:"fasds",400:"fasdr",300:"fasdl",100:"fasdt"},slab:{400:"faslr"},"slab-press":{400:"faslpr"},whiteboard:{600:"fawsb"},thumbprint:{300:"fatl"},notdog:{900:"fans"},"notdog-duo":{900:"fands"},etch:{900:"faes"},chisel:{400:"facr"},jelly:{400:"fajr"},"jelly-fill":{400:"fajfr"},"jelly-duo":{400:"fajdr"},utility:{600:"fausb"},"utility-duo":{600:"faudsb"},"utility-fill":{600:"faufsb"}},$p={"Font Awesome 7 Free":{900:"fas",400:"far"},"Font Awesome 7 Pro":{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},"Font Awesome 7 Brands":{400:"fab",normal:"fab"},"Font Awesome 7 Duotone":{900:"fad",400:"fadr",normal:"fadr",300:"fadl",100:"fadt"},"Font Awesome 7 Sharp":{900:"fass",400:"fasr",normal:"fasr",300:"fasl",100:"fast"},"Font Awesome 7 Sharp Duotone":{900:"fasds",400:"fasdr",normal:"fasdr",300:"fasdl",100:"fasdt"},"Font Awesome 7 Jelly":{400:"fajr",normal:"fajr"},"Font Awesome 7 Jelly Fill":{400:"fajfr",normal:"fajfr"},"Font Awesome 7 Jelly Duo":{400:"fajdr",normal:"fajdr"},"Font Awesome 7 Slab":{400:"faslr",normal:"faslr"},"Font Awesome 7 Slab Press":{400:"faslpr",normal:"faslpr"},"Font Awesome 7 Thumbprint":{300:"fatl",normal:"fatl"},"Font Awesome 7 Notdog":{900:"fans",normal:"fans"},"Font Awesome 7 Notdog Duo":{900:"fands",normal:"fands"},"Font Awesome 7 Etch":{900:"faes",normal:"faes"},"Font Awesome 7 Chisel":{400:"facr",normal:"facr"},"Font Awesome 7 Whiteboard":{600:"fawsb",normal:"fawsb"},"Font Awesome 7 Utility":{600:"fausb",normal:"fausb"},"Font Awesome 7 Utility Duo":{600:"faudsb",normal:"faudsb"},"Font Awesome 7 Utility Fill":{600:"faufsb",normal:"faufsb"}},Wp=new Map([["classic",{defaultShortPrefixId:"fas",defaultStyleId:"solid",styleIds:["solid","regular","light","thin","brands"],futureStyleIds:[],defaultFontWeight:900}],["duotone",{defaultShortPrefixId:"fad",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["sharp",{defaultShortPrefixId:"fass",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["sharp-duotone",{defaultShortPrefixId:"fasds",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["chisel",{defaultShortPrefixId:"facr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["etch",{defaultShortPrefixId:"faes",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["jelly",{defaultShortPrefixId:"fajr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["jelly-duo",{defaultShortPrefixId:"fajdr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["jelly-fill",{defaultShortPrefixId:"fajfr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["notdog",{defaultShortPrefixId:"fans",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["notdog-duo",{defaultShortPrefixId:"fands",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["slab",{defaultShortPrefixId:"faslr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["slab-press",{defaultShortPrefixId:"faslpr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["thumbprint",{defaultShortPrefixId:"fatl",defaultStyleId:"light",styleIds:["light"],futureStyleIds:[],defaultFontWeight:300}],["utility",{defaultShortPrefixId:"fausb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["utility-duo",{defaultShortPrefixId:"faudsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["utility-fill",{defaultShortPrefixId:"faufsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["whiteboard",{defaultShortPrefixId:"fawsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}]]),Hp={chisel:{regular:"facr"},classic:{brands:"fab",light:"fal",regular:"far",solid:"fas",thin:"fat"},duotone:{light:"fadl",regular:"fadr",solid:"fad",thin:"fadt"},etch:{solid:"faes"},jelly:{regular:"fajr"},"jelly-duo":{regular:"fajdr"},"jelly-fill":{regular:"fajfr"},notdog:{solid:"fans"},"notdog-duo":{solid:"fands"},sharp:{light:"fasl",regular:"fasr",solid:"fass",thin:"fast"},"sharp-duotone":{light:"fasdl",regular:"fasdr",solid:"fasds",thin:"fasdt"},slab:{regular:"faslr"},"slab-press":{regular:"faslpr"},thumbprint:{light:"fatl"},utility:{semibold:"fausb"},"utility-duo":{semibold:"faudsb"},"utility-fill":{semibold:"faufsb"},whiteboard:{semibold:"fawsb"}},zl=["fak","fa-kit","fakd","fa-kit-duotone"],$l={kit:{fak:"kit","fa-kit":"kit"},"kit-duotone":{fakd:"kit-duotone","fa-kit-duotone":"kit-duotone"}},Yp=["kit"],Gp="kit",Kp="kit-duotone",Xp="Kit",qp="Kit Duotone";J(J({},Gp,Xp),Kp,qp);var Qp={kit:{"fa-kit":"fak"}},Zp={"Font Awesome Kit":{400:"fak",normal:"fak"},"Font Awesome Kit Duotone":{400:"fakd",normal:"fakd"}},Jp={kit:{fak:"fa-kit"}},Wl={kit:{kit:"fak"},"kit-duotone":{"kit-duotone":"fakd"}},ji,Xn={GROUP:"duotone-group",SWAP_OPACITY:"swap-opacity",PRIMARY:"primary",SECONDARY:"secondary"},e0=["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone","fa-thumbprint","fa-whiteboard","fa-notdog","fa-notdog-duo","fa-chisel","fa-etch","fa-jelly","fa-jelly-fill","fa-jelly-duo","fa-slab","fa-slab-press","fa-utility","fa-utility-duo","fa-utility-fill"],t0="classic",n0="duotone",r0="sharp",i0="sharp-duotone",s0="chisel",a0="etch",o0="jelly",l0="jelly-duo",u0="jelly-fill",c0="notdog",f0="notdog-duo",d0="slab",h0="slab-press",m0="thumbprint",p0="utility",g0="utility-duo",y0="utility-fill",v0="whiteboard",b0="Classic",x0="Duotone",w0="Sharp",A0="Sharp Duotone",S0="Chisel",T0="Etch",P0="Jelly",C0="Jelly Duo",E0="Jelly Fill",I0="Notdog",k0="Notdog Duo",M0="Slab",D0="Slab Press",j0="Thumbprint",F0="Utility",L0="Utility Duo",O0="Utility Fill",R0="Whiteboard";ji={},J(J(J(J(J(J(J(J(J(J(ji,t0,b0),n0,x0),r0,w0),i0,A0),s0,S0),a0,T0),o0,P0),l0,C0),u0,E0),c0,I0),J(J(J(J(J(J(J(J(ji,f0,k0),d0,M0),h0,D0),m0,j0),p0,F0),g0,L0),y0,O0),v0,R0);var _0="kit",V0="kit-duotone",N0="Kit",U0="Kit Duotone";J(J({},_0,N0),V0,U0);var B0={classic:{"fa-brands":"fab","fa-duotone":"fad","fa-light":"fal","fa-regular":"far","fa-solid":"fas","fa-thin":"fat"},duotone:{"fa-regular":"fadr","fa-light":"fadl","fa-thin":"fadt"},sharp:{"fa-solid":"fass","fa-regular":"fasr","fa-light":"fasl","fa-thin":"fast"},"sharp-duotone":{"fa-solid":"fasds","fa-regular":"fasdr","fa-light":"fasdl","fa-thin":"fasdt"},slab:{"fa-regular":"faslr"},"slab-press":{"fa-regular":"faslpr"},whiteboard:{"fa-semibold":"fawsb"},thumbprint:{"fa-light":"fatl"},notdog:{"fa-solid":"fans"},"notdog-duo":{"fa-solid":"fands"},etch:{"fa-solid":"faes"},jelly:{"fa-regular":"fajr"},"jelly-fill":{"fa-regular":"fajfr"},"jelly-duo":{"fa-regular":"fajdr"},chisel:{"fa-regular":"facr"},utility:{"fa-semibold":"fausb"},"utility-duo":{"fa-semibold":"faudsb"},"utility-fill":{"fa-semibold":"faufsb"}},z0={classic:["fas","far","fal","fat","fad"],duotone:["fadr","fadl","fadt"],sharp:["fass","fasr","fasl","fast"],"sharp-duotone":["fasds","fasdr","fasdl","fasdt"],slab:["faslr"],"slab-press":["faslpr"],whiteboard:["fawsb"],thumbprint:["fatl"],notdog:["fans"],"notdog-duo":["fands"],etch:["faes"],jelly:["fajr"],"jelly-fill":["fajfr"],"jelly-duo":["fajdr"],chisel:["facr"],utility:["fausb"],"utility-duo":["faudsb"],"utility-fill":["faufsb"]},Fi={classic:{fab:"fa-brands",fad:"fa-duotone",fal:"fa-light",far:"fa-regular",fas:"fa-solid",fat:"fa-thin"},duotone:{fadr:"fa-regular",fadl:"fa-light",fadt:"fa-thin"},sharp:{fass:"fa-solid",fasr:"fa-regular",fasl:"fa-light",fast:"fa-thin"},"sharp-duotone":{fasds:"fa-solid",fasdr:"fa-regular",fasdl:"fa-light",fasdt:"fa-thin"},slab:{faslr:"fa-regular"},"slab-press":{faslpr:"fa-regular"},whiteboard:{fawsb:"fa-semibold"},thumbprint:{fatl:"fa-light"},notdog:{fans:"fa-solid"},"notdog-duo":{fands:"fa-solid"},etch:{faes:"fa-solid"},jelly:{fajr:"fa-regular"},"jelly-fill":{fajfr:"fa-regular"},"jelly-duo":{fajdr:"fa-regular"},chisel:{facr:"fa-regular"},utility:{fausb:"fa-semibold"},"utility-duo":{faudsb:"fa-semibold"},"utility-fill":{faufsb:"fa-semibold"}},$0=["fa-solid","fa-regular","fa-light","fa-thin","fa-duotone","fa-brands","fa-semibold"],Hl=["fa","fas","far","fal","fat","fad","fadr","fadl","fadt","fab","fass","fasr","fasl","fast","fasds","fasdr","fasdl","fasdt","faslr","faslpr","fawsb","fatl","fans","fands","faes","fajr","fajfr","fajdr","facr","fausb","faudsb","faufsb"].concat(e0,$0),W0=["solid","regular","light","thin","duotone","brands","semibold"],Yl=[1,2,3,4,5,6,7,8,9,10],H0=Yl.concat([11,12,13,14,15,16,17,18,19,20]),Y0=["aw","fw","pull-left","pull-right"],G0=[].concat(Ue(Object.keys(z0)),W0,Y0,["2xs","xs","sm","lg","xl","2xl","beat","border","fade","beat-fade","bounce","flip-both","flip-horizontal","flip-vertical","flip","inverse","layers","layers-bottom-left","layers-bottom-right","layers-counter","layers-text","layers-top-left","layers-top-right","li","pull-end","pull-start","pulse","rotate-180","rotate-270","rotate-90","rotate-by","shake","spin-pulse","spin-reverse","spin","stack-1x","stack-2x","stack","ul","width-auto","width-fixed",Xn.GROUP,Xn.SWAP_OPACITY,Xn.PRIMARY,Xn.SECONDARY]).concat(Yl.map(function(e){return"".concat(e,"x")})).concat(H0.map(function(e){return"w-".concat(e)})),K0={"Font Awesome 5 Free":{900:"fas",400:"far"},"Font Awesome 5 Pro":{900:"fas",400:"far",normal:"far",300:"fal"},"Font Awesome 5 Brands":{400:"fab",normal:"fab"},"Font Awesome 5 Duotone":{900:"fad"}},Je="___FONT_AWESOME___",Li=16,Gl="fa",Kl="svg-inline--fa",xt="data-fa-i2svg",Oi="data-fa-pseudo-element",X0="data-fa-pseudo-element-pending",Ri="data-prefix",_i="data-icon",Xl="fontawesome-i2svg",q0="async",Q0=["HTML","HEAD","STYLE","SCRIPT"],ql=["::before","::after",":before",":after"],Ql=(function(){try{return process.env.NODE_ENV==="production"}catch{return!1}})();function hn(e){return new Proxy(e,{get:function(n,r){return r in n?n[r]:n[ye]}})}var Zl=$({},Sl);Zl[ye]=$($($($({},{"fa-duotone":"duotone"}),Sl[ye]),$l.kit),$l["kit-duotone"]);var Z0=hn(Zl),Vi=$({},Hp);Vi[ye]=$($($($({},{duotone:"fad"}),Vi[ye]),Wl.kit),Wl["kit-duotone"]);var Jl=hn(Vi),Ni=$({},Fi);Ni[ye]=$($({},Ni[ye]),Jp.kit);var Ui=hn(Ni),Bi=$({},B0);Bi[ye]=$($({},Bi[ye]),Qp.kit),hn(Bi);var J0=wp,eu="fa-layers-text",e1=Ap,t1=$({},zp);hn(t1);var n1=["class","data-prefix","data-icon","data-fa-transform","data-fa-mask"],zi=Sp,r1=[].concat(Ue(Yp),Ue(G0)),mn=lt.FontAwesomeConfig||{};function i1(e){var t=re.querySelector("script["+e+"]");if(t)return t.getAttribute(e)}function s1(e){return e===""?!0:e==="false"?!1:e==="true"?!0:e}if(re&&typeof re.querySelector=="function"){var a1=[["data-family-prefix","familyPrefix"],["data-css-prefix","cssPrefix"],["data-family-default","familyDefault"],["data-style-default","styleDefault"],["data-replacement-class","replacementClass"],["data-auto-replace-svg","autoReplaceSvg"],["data-auto-add-css","autoAddCss"],["data-search-pseudo-elements","searchPseudoElements"],["data-search-pseudo-elements-warnings","searchPseudoElementsWarnings"],["data-search-pseudo-elements-full-scan","searchPseudoElementsFullScan"],["data-observe-mutations","observeMutations"],["data-mutate-approach","mutateApproach"],["data-keep-original-source","keepOriginalSource"],["data-measure-performance","measurePerformance"],["data-show-missing-icons","showMissingIcons"]];a1.forEach(function(e){var t=Yn(e,2),n=t[0],r=t[1],i=s1(i1(n));i!=null&&(mn[r]=i)})}var tu={styleDefault:"solid",familyDefault:ye,cssPrefix:Gl,replacementClass:Kl,autoReplaceSvg:!0,autoAddCss:!0,searchPseudoElements:!1,searchPseudoElementsWarnings:!0,searchPseudoElementsFullScan:!1,observeMutations:!0,mutateApproach:"async",keepOriginalSource:!0,measurePerformance:!1,showMissingIcons:!0};mn.familyPrefix&&(mn.cssPrefix=mn.familyPrefix);var Bt=$($({},tu),mn);Bt.autoReplaceSvg||(Bt.observeMutations=!1);var K={};Object.keys(tu).forEach(function(e){Object.defineProperty(K,e,{enumerable:!0,set:function(n){Bt[e]=n,pn.forEach(function(r){return r(K)})},get:function(){return Bt[e]}})}),Object.defineProperty(K,"familyPrefix",{enumerable:!0,set:function(t){Bt.cssPrefix=t,pn.forEach(function(n){return n(K)})},get:function(){return Bt.cssPrefix}}),lt.FontAwesomeConfig=K;var pn=[];function o1(e){return pn.push(e),function(){pn.splice(pn.indexOf(e),1)}}var zt=Li,He={size:16,x:0,y:0,rotate:0,flipX:!1,flipY:!1};function l1(e){if(!(!e||!Ze)){var t=re.createElement("style");t.setAttribute("type","text/css"),t.innerHTML=e;for(var n=re.head.childNodes,r=null,i=n.length-1;i>-1;i--){var s=n[i],a=(s.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(a)>-1&&(r=s)}return re.head.insertBefore(t,r),e}}var u1="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";function nu(){for(var e=12,t="";e-- >0;)t+=u1[Math.random()*62|0];return t}function $t(e){for(var t=[],n=(e||[]).length>>>0;n--;)t[n]=e[n];return t}function $i(e){return e.classList?$t(e.classList):(e.getAttribute("class")||"").split(" ").filter(function(t){return t})}function ru(e){return"".concat(e).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function c1(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,'="').concat(ru(e[n]),'" ')},"").trim()}function qn(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,": ").concat(e[n].trim(),";")},"")}function Wi(e){return e.size!==He.size||e.x!==He.x||e.y!==He.y||e.rotate!==He.rotate||e.flipX||e.flipY}function f1(e){var t=e.transform,n=e.containerWidth,r=e.iconWidth,i={transform:"translate(".concat(n/2," 256)")},s="translate(".concat(t.x*32,", ").concat(t.y*32,") "),a="scale(".concat(t.size/16*(t.flipX?-1:1),", ").concat(t.size/16*(t.flipY?-1:1),") "),o="rotate(".concat(t.rotate," 0 0)"),u={transform:"".concat(s," ").concat(a," ").concat(o)},d={transform:"translate(".concat(r/2*-1," -256)")};return{outer:i,inner:u,path:d}}function d1(e){var t=e.transform,n=e.width,r=n===void 0?Li:n,i=e.height,s=i===void 0?Li:i,a="";return Al?a+="translate(".concat(t.x/zt-r/2,"em, ").concat(t.y/zt-s/2,"em) "):a+="translate(calc(-50% + ".concat(t.x/zt,"em), calc(-50% + ").concat(t.y/zt,"em)) "),a+="scale(".concat(t.size/zt*(t.flipX?-1:1),", ").concat(t.size/zt*(t.flipY?-1:1),") "),a+="rotate(".concat(t.rotate,"deg) "),a}var h1=`:root, :host {
17
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function hl(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function $(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?hl(Object(n),!0).forEach(function(r){Z(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):hl(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Yn(e,t){return cp(e)||gp(e,t)||ki(e,t)||yp()}function Ue(e){return fp(e)||pp(e)||ki(e)||vp()}function bp(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ml(e){var t=bp(e,"string");return typeof t=="symbol"?t:t+""}function Gn(e){"@babel/helpers - typeof";return Gn=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Gn(e)}function ki(e,t){if(e){if(typeof e=="string")return Ii(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ii(e,t):void 0}}var pl=function(){},Mi={},gl={},yl=null,vl={mark:pl,measure:pl};try{typeof window<"u"&&(Mi=window),typeof document<"u"&&(gl=document),typeof MutationObserver<"u"&&(yl=MutationObserver),typeof performance<"u"&&(vl=performance)}catch{}var xp=Mi.navigator||{},bl=xp.userAgent,xl=bl===void 0?"":bl,lt=Mi,se=gl,wl=yl,Kn=vl;lt.document;var Ze=!!se.documentElement&&!!se.head&&typeof se.addEventListener=="function"&&typeof se.createElement=="function",Al=~xl.indexOf("MSIE")||~xl.indexOf("Trident/"),Di,wp=/fa(k|kd|s|r|l|t|d|dr|dl|dt|b|slr|slpr|wsb|tl|ns|nds|es|jr|jfr|jdr|usb|ufsb|udsb|cr|ss|sr|sl|st|sds|sdr|sdl|sdt)?[\-\ ]/,Ap=/Font ?Awesome ?([567 ]*)(Solid|Regular|Light|Thin|Duotone|Brands|Free|Pro|Sharp Duotone|Sharp|Kit|Notdog Duo|Notdog|Chisel|Etch|Thumbprint|Jelly Fill|Jelly Duo|Jelly|Utility|Utility Fill|Utility Duo|Slab Press|Slab|Whiteboard)?.*/i,Sl={classic:{fa:"solid",fas:"solid","fa-solid":"solid",far:"regular","fa-regular":"regular",fal:"light","fa-light":"light",fat:"thin","fa-thin":"thin",fab:"brands","fa-brands":"brands"},duotone:{fa:"solid",fad:"solid","fa-solid":"solid","fa-duotone":"solid",fadr:"regular","fa-regular":"regular",fadl:"light","fa-light":"light",fadt:"thin","fa-thin":"thin"},sharp:{fa:"solid",fass:"solid","fa-solid":"solid",fasr:"regular","fa-regular":"regular",fasl:"light","fa-light":"light",fast:"thin","fa-thin":"thin"},"sharp-duotone":{fa:"solid",fasds:"solid","fa-solid":"solid",fasdr:"regular","fa-regular":"regular",fasdl:"light","fa-light":"light",fasdt:"thin","fa-thin":"thin"},slab:{"fa-regular":"regular",faslr:"regular"},"slab-press":{"fa-regular":"regular",faslpr:"regular"},thumbprint:{"fa-light":"light",fatl:"light"},whiteboard:{"fa-semibold":"semibold",fawsb:"semibold"},notdog:{"fa-solid":"solid",fans:"solid"},"notdog-duo":{"fa-solid":"solid",fands:"solid"},etch:{"fa-solid":"solid",faes:"solid"},jelly:{"fa-regular":"regular",fajr:"regular"},"jelly-fill":{"fa-regular":"regular",fajfr:"regular"},"jelly-duo":{"fa-regular":"regular",fajdr:"regular"},chisel:{"fa-regular":"regular",facr:"regular"},utility:{"fa-semibold":"semibold",fausb:"semibold"},"utility-duo":{"fa-semibold":"semibold",faudsb:"semibold"},"utility-fill":{"fa-semibold":"semibold",faufsb:"semibold"}},Sp={GROUP:"duotone-group",PRIMARY:"primary",SECONDARY:"secondary"},Tl=["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone","fa-thumbprint","fa-whiteboard","fa-notdog","fa-notdog-duo","fa-chisel","fa-etch","fa-jelly","fa-jelly-fill","fa-jelly-duo","fa-slab","fa-slab-press","fa-utility","fa-utility-duo","fa-utility-fill"],ve="classic",dn="duotone",Pl="sharp",Cl="sharp-duotone",El="chisel",Il="etch",kl="jelly",Ml="jelly-duo",Dl="jelly-fill",jl="notdog",Fl="notdog-duo",Ll="slab",Ol="slab-press",Rl="thumbprint",_l="utility",Vl="utility-duo",Nl="utility-fill",Ul="whiteboard",Tp="Classic",Pp="Duotone",Cp="Sharp",Ep="Sharp Duotone",Ip="Chisel",kp="Etch",Mp="Jelly",Dp="Jelly Duo",jp="Jelly Fill",Fp="Notdog",Lp="Notdog Duo",Op="Slab",Rp="Slab Press",_p="Thumbprint",Vp="Utility",Np="Utility Duo",Up="Utility Fill",Bp="Whiteboard",Bl=[ve,dn,Pl,Cl,El,Il,kl,Ml,Dl,jl,Fl,Ll,Ol,Rl,_l,Vl,Nl,Ul];Di={},Z(Z(Z(Z(Z(Z(Z(Z(Z(Z(Di,ve,Tp),dn,Pp),Pl,Cp),Cl,Ep),El,Ip),Il,kp),kl,Mp),Ml,Dp),Dl,jp),jl,Fp),Z(Z(Z(Z(Z(Z(Z(Z(Di,Fl,Lp),Ll,Op),Ol,Rp),Rl,_p),_l,Vp),Vl,Np),Nl,Up),Ul,Bp);var zp={classic:{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},duotone:{900:"fad",400:"fadr",300:"fadl",100:"fadt"},sharp:{900:"fass",400:"fasr",300:"fasl",100:"fast"},"sharp-duotone":{900:"fasds",400:"fasdr",300:"fasdl",100:"fasdt"},slab:{400:"faslr"},"slab-press":{400:"faslpr"},whiteboard:{600:"fawsb"},thumbprint:{300:"fatl"},notdog:{900:"fans"},"notdog-duo":{900:"fands"},etch:{900:"faes"},chisel:{400:"facr"},jelly:{400:"fajr"},"jelly-fill":{400:"fajfr"},"jelly-duo":{400:"fajdr"},utility:{600:"fausb"},"utility-duo":{600:"faudsb"},"utility-fill":{600:"faufsb"}},$p={"Font Awesome 7 Free":{900:"fas",400:"far"},"Font Awesome 7 Pro":{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},"Font Awesome 7 Brands":{400:"fab",normal:"fab"},"Font Awesome 7 Duotone":{900:"fad",400:"fadr",normal:"fadr",300:"fadl",100:"fadt"},"Font Awesome 7 Sharp":{900:"fass",400:"fasr",normal:"fasr",300:"fasl",100:"fast"},"Font Awesome 7 Sharp Duotone":{900:"fasds",400:"fasdr",normal:"fasdr",300:"fasdl",100:"fasdt"},"Font Awesome 7 Jelly":{400:"fajr",normal:"fajr"},"Font Awesome 7 Jelly Fill":{400:"fajfr",normal:"fajfr"},"Font Awesome 7 Jelly Duo":{400:"fajdr",normal:"fajdr"},"Font Awesome 7 Slab":{400:"faslr",normal:"faslr"},"Font Awesome 7 Slab Press":{400:"faslpr",normal:"faslpr"},"Font Awesome 7 Thumbprint":{300:"fatl",normal:"fatl"},"Font Awesome 7 Notdog":{900:"fans",normal:"fans"},"Font Awesome 7 Notdog Duo":{900:"fands",normal:"fands"},"Font Awesome 7 Etch":{900:"faes",normal:"faes"},"Font Awesome 7 Chisel":{400:"facr",normal:"facr"},"Font Awesome 7 Whiteboard":{600:"fawsb",normal:"fawsb"},"Font Awesome 7 Utility":{600:"fausb",normal:"fausb"},"Font Awesome 7 Utility Duo":{600:"faudsb",normal:"faudsb"},"Font Awesome 7 Utility Fill":{600:"faufsb",normal:"faufsb"}},Wp=new Map([["classic",{defaultShortPrefixId:"fas",defaultStyleId:"solid",styleIds:["solid","regular","light","thin","brands"],futureStyleIds:[],defaultFontWeight:900}],["duotone",{defaultShortPrefixId:"fad",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["sharp",{defaultShortPrefixId:"fass",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["sharp-duotone",{defaultShortPrefixId:"fasds",defaultStyleId:"solid",styleIds:["solid","regular","light","thin"],futureStyleIds:[],defaultFontWeight:900}],["chisel",{defaultShortPrefixId:"facr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["etch",{defaultShortPrefixId:"faes",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["jelly",{defaultShortPrefixId:"fajr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["jelly-duo",{defaultShortPrefixId:"fajdr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["jelly-fill",{defaultShortPrefixId:"fajfr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["notdog",{defaultShortPrefixId:"fans",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["notdog-duo",{defaultShortPrefixId:"fands",defaultStyleId:"solid",styleIds:["solid"],futureStyleIds:[],defaultFontWeight:900}],["slab",{defaultShortPrefixId:"faslr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["slab-press",{defaultShortPrefixId:"faslpr",defaultStyleId:"regular",styleIds:["regular"],futureStyleIds:[],defaultFontWeight:400}],["thumbprint",{defaultShortPrefixId:"fatl",defaultStyleId:"light",styleIds:["light"],futureStyleIds:[],defaultFontWeight:300}],["utility",{defaultShortPrefixId:"fausb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["utility-duo",{defaultShortPrefixId:"faudsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["utility-fill",{defaultShortPrefixId:"faufsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}],["whiteboard",{defaultShortPrefixId:"fawsb",defaultStyleId:"semibold",styleIds:["semibold"],futureStyleIds:[],defaultFontWeight:600}]]),Hp={chisel:{regular:"facr"},classic:{brands:"fab",light:"fal",regular:"far",solid:"fas",thin:"fat"},duotone:{light:"fadl",regular:"fadr",solid:"fad",thin:"fadt"},etch:{solid:"faes"},jelly:{regular:"fajr"},"jelly-duo":{regular:"fajdr"},"jelly-fill":{regular:"fajfr"},notdog:{solid:"fans"},"notdog-duo":{solid:"fands"},sharp:{light:"fasl",regular:"fasr",solid:"fass",thin:"fast"},"sharp-duotone":{light:"fasdl",regular:"fasdr",solid:"fasds",thin:"fasdt"},slab:{regular:"faslr"},"slab-press":{regular:"faslpr"},thumbprint:{light:"fatl"},utility:{semibold:"fausb"},"utility-duo":{semibold:"faudsb"},"utility-fill":{semibold:"faufsb"},whiteboard:{semibold:"fawsb"}},zl=["fak","fa-kit","fakd","fa-kit-duotone"],$l={kit:{fak:"kit","fa-kit":"kit"},"kit-duotone":{fakd:"kit-duotone","fa-kit-duotone":"kit-duotone"}},Yp=["kit"],Gp="kit",Kp="kit-duotone",Xp="Kit",qp="Kit Duotone";Z(Z({},Gp,Xp),Kp,qp);var Qp={kit:{"fa-kit":"fak"}},Zp={"Font Awesome Kit":{400:"fak",normal:"fak"},"Font Awesome Kit Duotone":{400:"fakd",normal:"fakd"}},Jp={kit:{fak:"fa-kit"}},Wl={kit:{kit:"fak"},"kit-duotone":{"kit-duotone":"fakd"}},ji,Xn={GROUP:"duotone-group",SWAP_OPACITY:"swap-opacity",PRIMARY:"primary",SECONDARY:"secondary"},e0=["fa-classic","fa-duotone","fa-sharp","fa-sharp-duotone","fa-thumbprint","fa-whiteboard","fa-notdog","fa-notdog-duo","fa-chisel","fa-etch","fa-jelly","fa-jelly-fill","fa-jelly-duo","fa-slab","fa-slab-press","fa-utility","fa-utility-duo","fa-utility-fill"],t0="classic",n0="duotone",r0="sharp",i0="sharp-duotone",s0="chisel",a0="etch",o0="jelly",l0="jelly-duo",u0="jelly-fill",c0="notdog",f0="notdog-duo",d0="slab",h0="slab-press",m0="thumbprint",p0="utility",g0="utility-duo",y0="utility-fill",v0="whiteboard",b0="Classic",x0="Duotone",w0="Sharp",A0="Sharp Duotone",S0="Chisel",T0="Etch",P0="Jelly",C0="Jelly Duo",E0="Jelly Fill",I0="Notdog",k0="Notdog Duo",M0="Slab",D0="Slab Press",j0="Thumbprint",F0="Utility",L0="Utility Duo",O0="Utility Fill",R0="Whiteboard";ji={},Z(Z(Z(Z(Z(Z(Z(Z(Z(Z(ji,t0,b0),n0,x0),r0,w0),i0,A0),s0,S0),a0,T0),o0,P0),l0,C0),u0,E0),c0,I0),Z(Z(Z(Z(Z(Z(Z(Z(ji,f0,k0),d0,M0),h0,D0),m0,j0),p0,F0),g0,L0),y0,O0),v0,R0);var _0="kit",V0="kit-duotone",N0="Kit",U0="Kit Duotone";Z(Z({},_0,N0),V0,U0);var B0={classic:{"fa-brands":"fab","fa-duotone":"fad","fa-light":"fal","fa-regular":"far","fa-solid":"fas","fa-thin":"fat"},duotone:{"fa-regular":"fadr","fa-light":"fadl","fa-thin":"fadt"},sharp:{"fa-solid":"fass","fa-regular":"fasr","fa-light":"fasl","fa-thin":"fast"},"sharp-duotone":{"fa-solid":"fasds","fa-regular":"fasdr","fa-light":"fasdl","fa-thin":"fasdt"},slab:{"fa-regular":"faslr"},"slab-press":{"fa-regular":"faslpr"},whiteboard:{"fa-semibold":"fawsb"},thumbprint:{"fa-light":"fatl"},notdog:{"fa-solid":"fans"},"notdog-duo":{"fa-solid":"fands"},etch:{"fa-solid":"faes"},jelly:{"fa-regular":"fajr"},"jelly-fill":{"fa-regular":"fajfr"},"jelly-duo":{"fa-regular":"fajdr"},chisel:{"fa-regular":"facr"},utility:{"fa-semibold":"fausb"},"utility-duo":{"fa-semibold":"faudsb"},"utility-fill":{"fa-semibold":"faufsb"}},z0={classic:["fas","far","fal","fat","fad"],duotone:["fadr","fadl","fadt"],sharp:["fass","fasr","fasl","fast"],"sharp-duotone":["fasds","fasdr","fasdl","fasdt"],slab:["faslr"],"slab-press":["faslpr"],whiteboard:["fawsb"],thumbprint:["fatl"],notdog:["fans"],"notdog-duo":["fands"],etch:["faes"],jelly:["fajr"],"jelly-fill":["fajfr"],"jelly-duo":["fajdr"],chisel:["facr"],utility:["fausb"],"utility-duo":["faudsb"],"utility-fill":["faufsb"]},Fi={classic:{fab:"fa-brands",fad:"fa-duotone",fal:"fa-light",far:"fa-regular",fas:"fa-solid",fat:"fa-thin"},duotone:{fadr:"fa-regular",fadl:"fa-light",fadt:"fa-thin"},sharp:{fass:"fa-solid",fasr:"fa-regular",fasl:"fa-light",fast:"fa-thin"},"sharp-duotone":{fasds:"fa-solid",fasdr:"fa-regular",fasdl:"fa-light",fasdt:"fa-thin"},slab:{faslr:"fa-regular"},"slab-press":{faslpr:"fa-regular"},whiteboard:{fawsb:"fa-semibold"},thumbprint:{fatl:"fa-light"},notdog:{fans:"fa-solid"},"notdog-duo":{fands:"fa-solid"},etch:{faes:"fa-solid"},jelly:{fajr:"fa-regular"},"jelly-fill":{fajfr:"fa-regular"},"jelly-duo":{fajdr:"fa-regular"},chisel:{facr:"fa-regular"},utility:{fausb:"fa-semibold"},"utility-duo":{faudsb:"fa-semibold"},"utility-fill":{faufsb:"fa-semibold"}},$0=["fa-solid","fa-regular","fa-light","fa-thin","fa-duotone","fa-brands","fa-semibold"],Hl=["fa","fas","far","fal","fat","fad","fadr","fadl","fadt","fab","fass","fasr","fasl","fast","fasds","fasdr","fasdl","fasdt","faslr","faslpr","fawsb","fatl","fans","fands","faes","fajr","fajfr","fajdr","facr","fausb","faudsb","faufsb"].concat(e0,$0),W0=["solid","regular","light","thin","duotone","brands","semibold"],Yl=[1,2,3,4,5,6,7,8,9,10],H0=Yl.concat([11,12,13,14,15,16,17,18,19,20]),Y0=["aw","fw","pull-left","pull-right"],G0=[].concat(Ue(Object.keys(z0)),W0,Y0,["2xs","xs","sm","lg","xl","2xl","beat","border","fade","beat-fade","bounce","flip-both","flip-horizontal","flip-vertical","flip","inverse","layers","layers-bottom-left","layers-bottom-right","layers-counter","layers-text","layers-top-left","layers-top-right","li","pull-end","pull-start","pulse","rotate-180","rotate-270","rotate-90","rotate-by","shake","spin-pulse","spin-reverse","spin","stack-1x","stack-2x","stack","ul","width-auto","width-fixed",Xn.GROUP,Xn.SWAP_OPACITY,Xn.PRIMARY,Xn.SECONDARY]).concat(Yl.map(function(e){return"".concat(e,"x")})).concat(H0.map(function(e){return"w-".concat(e)})),K0={"Font Awesome 5 Free":{900:"fas",400:"far"},"Font Awesome 5 Pro":{900:"fas",400:"far",normal:"far",300:"fal"},"Font Awesome 5 Brands":{400:"fab",normal:"fab"},"Font Awesome 5 Duotone":{900:"fad"}},Je="___FONT_AWESOME___",Li=16,Gl="fa",Kl="svg-inline--fa",xt="data-fa-i2svg",Oi="data-fa-pseudo-element",X0="data-fa-pseudo-element-pending",Ri="data-prefix",_i="data-icon",Xl="fontawesome-i2svg",q0="async",Q0=["HTML","HEAD","STYLE","SCRIPT"],ql=["::before","::after",":before",":after"],Ql=(function(){try{return process.env.NODE_ENV==="production"}catch{return!1}})();function hn(e){return new Proxy(e,{get:function(n,r){return r in n?n[r]:n[ve]}})}var Zl=$({},Sl);Zl[ve]=$($($($({},{"fa-duotone":"duotone"}),Sl[ve]),$l.kit),$l["kit-duotone"]);var Z0=hn(Zl),Vi=$({},Hp);Vi[ve]=$($($($({},{duotone:"fad"}),Vi[ve]),Wl.kit),Wl["kit-duotone"]);var Jl=hn(Vi),Ni=$({},Fi);Ni[ve]=$($({},Ni[ve]),Jp.kit);var Ui=hn(Ni),Bi=$({},B0);Bi[ve]=$($({},Bi[ve]),Qp.kit),hn(Bi);var J0=wp,eu="fa-layers-text",e1=Ap,t1=$({},zp);hn(t1);var n1=["class","data-prefix","data-icon","data-fa-transform","data-fa-mask"],zi=Sp,r1=[].concat(Ue(Yp),Ue(G0)),mn=lt.FontAwesomeConfig||{};function i1(e){var t=se.querySelector("script["+e+"]");if(t)return t.getAttribute(e)}function s1(e){return e===""?!0:e==="false"?!1:e==="true"?!0:e}if(se&&typeof se.querySelector=="function"){var a1=[["data-family-prefix","familyPrefix"],["data-css-prefix","cssPrefix"],["data-family-default","familyDefault"],["data-style-default","styleDefault"],["data-replacement-class","replacementClass"],["data-auto-replace-svg","autoReplaceSvg"],["data-auto-add-css","autoAddCss"],["data-search-pseudo-elements","searchPseudoElements"],["data-search-pseudo-elements-warnings","searchPseudoElementsWarnings"],["data-search-pseudo-elements-full-scan","searchPseudoElementsFullScan"],["data-observe-mutations","observeMutations"],["data-mutate-approach","mutateApproach"],["data-keep-original-source","keepOriginalSource"],["data-measure-performance","measurePerformance"],["data-show-missing-icons","showMissingIcons"]];a1.forEach(function(e){var t=Yn(e,2),n=t[0],r=t[1],i=s1(i1(n));i!=null&&(mn[r]=i)})}var tu={styleDefault:"solid",familyDefault:ve,cssPrefix:Gl,replacementClass:Kl,autoReplaceSvg:!0,autoAddCss:!0,searchPseudoElements:!1,searchPseudoElementsWarnings:!0,searchPseudoElementsFullScan:!1,observeMutations:!0,mutateApproach:"async",keepOriginalSource:!0,measurePerformance:!1,showMissingIcons:!0};mn.familyPrefix&&(mn.cssPrefix=mn.familyPrefix);var Bt=$($({},tu),mn);Bt.autoReplaceSvg||(Bt.observeMutations=!1);var K={};Object.keys(tu).forEach(function(e){Object.defineProperty(K,e,{enumerable:!0,set:function(n){Bt[e]=n,pn.forEach(function(r){return r(K)})},get:function(){return Bt[e]}})}),Object.defineProperty(K,"familyPrefix",{enumerable:!0,set:function(t){Bt.cssPrefix=t,pn.forEach(function(n){return n(K)})},get:function(){return Bt.cssPrefix}}),lt.FontAwesomeConfig=K;var pn=[];function o1(e){return pn.push(e),function(){pn.splice(pn.indexOf(e),1)}}var zt=Li,He={size:16,x:0,y:0,rotate:0,flipX:!1,flipY:!1};function l1(e){if(!(!e||!Ze)){var t=se.createElement("style");t.setAttribute("type","text/css"),t.innerHTML=e;for(var n=se.head.childNodes,r=null,i=n.length-1;i>-1;i--){var s=n[i],a=(s.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(a)>-1&&(r=s)}return se.head.insertBefore(t,r),e}}var u1="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";function nu(){for(var e=12,t="";e-- >0;)t+=u1[Math.random()*62|0];return t}function $t(e){for(var t=[],n=(e||[]).length>>>0;n--;)t[n]=e[n];return t}function $i(e){return e.classList?$t(e.classList):(e.getAttribute("class")||"").split(" ").filter(function(t){return t})}function ru(e){return"".concat(e).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function c1(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,'="').concat(ru(e[n]),'" ')},"").trim()}function qn(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,": ").concat(e[n].trim(),";")},"")}function Wi(e){return e.size!==He.size||e.x!==He.x||e.y!==He.y||e.rotate!==He.rotate||e.flipX||e.flipY}function f1(e){var t=e.transform,n=e.containerWidth,r=e.iconWidth,i={transform:"translate(".concat(n/2," 256)")},s="translate(".concat(t.x*32,", ").concat(t.y*32,") "),a="scale(".concat(t.size/16*(t.flipX?-1:1),", ").concat(t.size/16*(t.flipY?-1:1),") "),o="rotate(".concat(t.rotate," 0 0)"),u={transform:"".concat(s," ").concat(a," ").concat(o)},d={transform:"translate(".concat(r/2*-1," -256)")};return{outer:i,inner:u,path:d}}function d1(e){var t=e.transform,n=e.width,r=n===void 0?Li:n,i=e.height,s=i===void 0?Li:i,a="";return Al?a+="translate(".concat(t.x/zt-r/2,"em, ").concat(t.y/zt-s/2,"em) "):a+="translate(calc(-50% + ".concat(t.x/zt,"em), calc(-50% + ").concat(t.y/zt,"em)) "),a+="scale(".concat(t.size/zt*(t.flipX?-1:1),", ").concat(t.size/zt*(t.flipY?-1:1),") "),a+="rotate(".concat(t.rotate,"deg) "),a}var h1=`:root, :host {
18
18
  --fa-font-solid: normal 900 1em/1 "Font Awesome 7 Free";
19
19
  --fa-font-regular: normal 400 1em/1 "Font Awesome 7 Free";
20
20
  --fa-font-light: normal 300 1em/1 "Font Awesome 7 Pro";
@@ -564,10 +564,10 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
564
564
  margin: auto;
565
565
  position: absolute;
566
566
  z-index: var(--fa-stack-z-index, auto);
567
- }`;function iu(){var e=Gl,t=Kl,n=K.cssPrefix,r=K.replacementClass,i=h1;if(n!==e||r!==t){var s=new RegExp("\\.".concat(e,"\\-"),"g"),a=new RegExp("\\--".concat(e,"\\-"),"g"),o=new RegExp("\\.".concat(t),"g");i=i.replace(s,".".concat(n,"-")).replace(a,"--".concat(n,"-")).replace(o,".".concat(r))}return i}var su=!1;function Hi(){K.autoAddCss&&!su&&(l1(iu()),su=!0)}var m1={mixout:function(){return{dom:{css:iu,insertCss:Hi}}},hooks:function(){return{beforeDOMElementCreation:function(){Hi()},beforeI2svg:function(){Hi()}}}},et=lt||{};et[Je]||(et[Je]={}),et[Je].styles||(et[Je].styles={}),et[Je].hooks||(et[Je].hooks={}),et[Je].shims||(et[Je].shims=[]);var Be=et[Je],au=[],ou=function(){re.removeEventListener("DOMContentLoaded",ou),Qn=1,au.map(function(t){return t()})},Qn=!1;Ze&&(Qn=(re.documentElement.doScroll?/^loaded|^c/:/^loaded|^i|^c/).test(re.readyState),Qn||re.addEventListener("DOMContentLoaded",ou));function p1(e){Ze&&(Qn?setTimeout(e,0):au.push(e))}function gn(e){var t=e.tag,n=e.attributes,r=n===void 0?{}:n,i=e.children,s=i===void 0?[]:i;return typeof e=="string"?ru(e):"<".concat(t," ").concat(c1(r),">").concat(s.map(gn).join(""),"</").concat(t,">")}function lu(e,t,n){if(e&&e[t]&&e[t][n])return{prefix:t,iconName:n,icon:e[t][n]}}var Yi=function(t,n,r,i){var s=Object.keys(t),a=s.length,o=n,u,d,l;for(r===void 0?(u=1,l=t[s[0]]):(u=0,l=r);u<a;u++)d=s[u],l=o(l,t[d],d,t);return l};function uu(e){return Ue(e).length!==1?null:e.codePointAt(0).toString(16)}function cu(e){return Object.keys(e).reduce(function(t,n){var r=e[n],i=!!r.icon;return i?t[r.iconName]=r.icon:t[n]=r,t},{})}function Gi(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.skipHooks,i=r===void 0?!1:r,s=cu(t);typeof Be.hooks.addPack=="function"&&!i?Be.hooks.addPack(e,cu(t)):Be.styles[e]=$($({},Be.styles[e]||{}),s),e==="fas"&&Gi("fa",t)}var yn=Be.styles,g1=Be.shims,fu=Object.keys(Ui),y1=fu.reduce(function(e,t){return e[t]=Object.keys(Ui[t]),e},{}),Ki=null,du={},hu={},mu={},pu={},gu={};function v1(e){return~r1.indexOf(e)}function b1(e,t){var n=t.split("-"),r=n[0],i=n.slice(1).join("-");return r===e&&i!==""&&!v1(i)?i:null}var yu=function(){var t=function(s){return Yi(yn,function(a,o,u){return a[u]=Yi(o,s,{}),a},{})};du=t(function(i,s,a){if(s[3]&&(i[s[3]]=a),s[2]){var o=s[2].filter(function(u){return typeof u=="number"});o.forEach(function(u){i[u.toString(16)]=a})}return i}),hu=t(function(i,s,a){if(i[a]=a,s[2]){var o=s[2].filter(function(u){return typeof u=="string"});o.forEach(function(u){i[u]=a})}return i}),gu=t(function(i,s,a){var o=s[2];return i[a]=a,o.forEach(function(u){i[u]=a}),i});var n="far"in yn||K.autoFetchSvg,r=Yi(g1,function(i,s){var a=s[0],o=s[1],u=s[2];return o==="far"&&!n&&(o="fas"),typeof a=="string"&&(i.names[a]={prefix:o,iconName:u}),typeof a=="number"&&(i.unicodes[a.toString(16)]={prefix:o,iconName:u}),i},{names:{},unicodes:{}});mu=r.names,pu=r.unicodes,Ki=Zn(K.styleDefault,{family:K.familyDefault})};o1(function(e){Ki=Zn(e.styleDefault,{family:K.familyDefault})}),yu();function Xi(e,t){return(du[e]||{})[t]}function x1(e,t){return(hu[e]||{})[t]}function wt(e,t){return(gu[e]||{})[t]}function vu(e){return mu[e]||{prefix:null,iconName:null}}function w1(e){var t=pu[e],n=Xi("fas",e);return t||(n?{prefix:"fas",iconName:n}:null)||{prefix:null,iconName:null}}function ut(){return Ki}var bu=function(){return{prefix:null,iconName:null,rest:[]}};function A1(e){var t=ye,n=fu.reduce(function(r,i){return r[i]="".concat(K.cssPrefix,"-").concat(i),r},{});return Bl.forEach(function(r){(e.includes(n[r])||e.some(function(i){return y1[r].includes(i)}))&&(t=r)}),t}function Zn(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.family,r=n===void 0?ye:n,i=Z0[r][e];if(r===dn&&!e)return"fad";var s=Jl[r][e]||Jl[r][i],a=e in Be.styles?e:null,o=s||a||null;return o}function S1(e){var t=[],n=null;return e.forEach(function(r){var i=b1(K.cssPrefix,r);i?n=i:r&&t.push(r)}),{iconName:n,rest:t}}function xu(e){return e.sort().filter(function(t,n,r){return r.indexOf(t)===n})}var wu=Hl.concat(zl);function Jn(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.skipLookups,r=n===void 0?!1:n,i=null,s=xu(e.filter(function(h){return wu.includes(h)})),a=xu(e.filter(function(h){return!wu.includes(h)})),o=s.filter(function(h){return i=h,!Tl.includes(h)}),u=Yn(o,1),d=u[0],l=d===void 0?null:d,c=A1(s),f=$($({},S1(a)),{},{prefix:Zn(l,{family:c})});return $($($({},f),E1({values:e,family:c,styles:yn,config:K,canonical:f,givenPrefix:i})),T1(r,i,f))}function T1(e,t,n){var r=n.prefix,i=n.iconName;if(e||!r||!i)return{prefix:r,iconName:i};var s=t==="fa"?vu(i):{},a=wt(r,i);return i=s.iconName||a||i,r=s.prefix||r,r==="far"&&!yn.far&&yn.fas&&!K.autoFetchSvg&&(r="fas"),{prefix:r,iconName:i}}var P1=Bl.filter(function(e){return e!==ye||e!==dn}),C1=Object.keys(Fi).filter(function(e){return e!==ye}).map(function(e){return Object.keys(Fi[e])}).flat();function E1(e){var t=e.values,n=e.family,r=e.canonical,i=e.givenPrefix,s=i===void 0?"":i,a=e.styles,o=a===void 0?{}:a,u=e.config,d=u===void 0?{}:u,l=n===dn,c=t.includes("fa-duotone")||t.includes("fad"),f=d.familyDefault==="duotone",h=r.prefix==="fad"||r.prefix==="fa-duotone";if(!l&&(c||f||h)&&(r.prefix="fad"),(t.includes("fa-brands")||t.includes("fab"))&&(r.prefix="fab"),!r.prefix&&P1.includes(n)){var m=Object.keys(o).find(function(w){return C1.includes(w)});if(m||d.autoFetchSvg){var b=Wp.get(n).defaultShortPrefixId;r.prefix=b,r.iconName=wt(r.prefix,r.iconName)||r.iconName}}return(r.prefix==="fa"||s==="fa")&&(r.prefix=ut()||"fas"),r}var I1=(function(){function e(){dp(this,e),this.definitions={}}return mp(e,[{key:"add",value:function(){for(var n=this,r=arguments.length,i=new Array(r),s=0;s<r;s++)i[s]=arguments[s];var a=i.reduce(this._pullDefinitions,{});Object.keys(a).forEach(function(o){n.definitions[o]=$($({},n.definitions[o]||{}),a[o]),Gi(o,a[o]);var u=Ui[ye][o];u&&Gi(u,a[o]),yu()})}},{key:"reset",value:function(){this.definitions={}}},{key:"_pullDefinitions",value:function(n,r){var i=r.prefix&&r.iconName&&r.icon?{0:r}:r;return Object.keys(i).map(function(s){var a=i[s],o=a.prefix,u=a.iconName,d=a.icon,l=d[2];n[o]||(n[o]={}),l.length>0&&l.forEach(function(c){typeof c=="string"&&(n[o][c]=d)}),n[o][u]=d}),n}}])})(),Au=[],Wt={},Ht={},k1=Object.keys(Ht);function M1(e,t){var n=t.mixoutsTo;return Au=e,Wt={},Object.keys(Ht).forEach(function(r){k1.indexOf(r)===-1&&delete Ht[r]}),Au.forEach(function(r){var i=r.mixout?r.mixout():{};if(Object.keys(i).forEach(function(a){typeof i[a]=="function"&&(n[a]=i[a]),Gn(i[a])==="object"&&Object.keys(i[a]).forEach(function(o){n[a]||(n[a]={}),n[a][o]=i[a][o]})}),r.hooks){var s=r.hooks();Object.keys(s).forEach(function(a){Wt[a]||(Wt[a]=[]),Wt[a].push(s[a])})}r.provides&&r.provides(Ht)}),n}function qi(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];var s=Wt[e]||[];return s.forEach(function(a){t=a.apply(null,[t].concat(r))}),t}function At(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var i=Wt[e]||[];i.forEach(function(s){s.apply(null,n)})}function ct(){var e=arguments[0],t=Array.prototype.slice.call(arguments,1);return Ht[e]?Ht[e].apply(null,t):void 0}function Qi(e){e.prefix==="fa"&&(e.prefix="fas");var t=e.iconName,n=e.prefix||ut();if(t)return t=wt(n,t)||t,lu(Su.definitions,n,t)||lu(Be.styles,n,t)}var Su=new I1,D1=function(){K.autoReplaceSvg=!1,K.observeMutations=!1,At("noAuto")},j1={i2svg:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Ze?(At("beforeI2svg",t),ct("pseudoElements2svg",t),ct("i2svg",t)):Promise.reject(new Error("Operation requires a DOM of some kind."))},watch:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.autoReplaceSvgRoot;K.autoReplaceSvg===!1&&(K.autoReplaceSvg=!0),K.observeMutations=!0,p1(function(){L1({autoReplaceSvgRoot:n}),At("watch",t)})}},F1={icon:function(t){if(t===null)return null;if(Gn(t)==="object"&&t.prefix&&t.iconName)return{prefix:t.prefix,iconName:wt(t.prefix,t.iconName)||t.iconName};if(Array.isArray(t)&&t.length===2){var n=t[1].indexOf("fa-")===0?t[1].slice(3):t[1],r=Zn(t[0]);return{prefix:r,iconName:wt(r,n)||n}}if(typeof t=="string"&&(t.indexOf("".concat(K.cssPrefix,"-"))>-1||t.match(J0))){var i=Jn(t.split(" "),{skipLookups:!0});return{prefix:i.prefix||ut(),iconName:wt(i.prefix,i.iconName)||i.iconName}}if(typeof t=="string"){var s=ut();return{prefix:s,iconName:wt(s,t)||t}}}},ke={noAuto:D1,config:K,dom:j1,parse:F1,library:Su,findIconDefinition:Qi,toHtml:gn},L1=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.autoReplaceSvgRoot,r=n===void 0?re:n;(Object.keys(Be.styles).length>0||K.autoFetchSvg)&&Ze&&K.autoReplaceSvg&&ke.dom.i2svg({node:r})};function er(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map(function(r){return gn(r)})}}),Object.defineProperty(e,"node",{get:function(){if(Ze){var r=re.createElement("div");return r.innerHTML=e.html,r.children}}}),e}function O1(e){var t=e.children,n=e.main,r=e.mask,i=e.attributes,s=e.styles,a=e.transform;if(Wi(a)&&n.found&&!r.found){var o=n.width,u=n.height,d={x:o/u/2,y:.5};i.style=qn($($({},s),{},{"transform-origin":"".concat(d.x+a.x/16,"em ").concat(d.y+a.y/16,"em")}))}return[{tag:"svg",attributes:i,children:t}]}function R1(e){var t=e.prefix,n=e.iconName,r=e.children,i=e.attributes,s=e.symbol,a=s===!0?"".concat(t,"-").concat(K.cssPrefix,"-").concat(n):s;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:$($({},i),{},{id:a}),children:r}]}]}function _1(e){var t=["aria-label","aria-labelledby","title","role"];return t.some(function(n){return n in e})}function Zi(e){var t=e.icons,n=t.main,r=t.mask,i=e.prefix,s=e.iconName,a=e.transform,o=e.symbol,u=e.maskId,d=e.extra,l=e.watchable,c=l===void 0?!1:l,f=r.found?r:n,h=f.width,m=f.height,b=[K.replacementClass,s?"".concat(K.cssPrefix,"-").concat(s):""].filter(function(P){return d.classes.indexOf(P)===-1}).filter(function(P){return P!==""||!!P}).concat(d.classes).join(" "),w={children:[],attributes:$($({},d.attributes),{},{"data-prefix":i,"data-icon":s,class:b,role:d.attributes.role||"img",viewBox:"0 0 ".concat(h," ").concat(m)})};!_1(d.attributes)&&!d.attributes["aria-hidden"]&&(w.attributes["aria-hidden"]="true"),c&&(w.attributes[xt]="");var v=$($({},w),{},{prefix:i,iconName:s,main:n,mask:r,maskId:u,transform:a,symbol:o,styles:$({},d.styles)}),I=r.found&&n.found?ct("generateAbstractMask",v)||{children:[],attributes:{}}:ct("generateAbstractIcon",v)||{children:[],attributes:{}},S=I.children,E=I.attributes;return v.children=S,v.attributes=E,o?R1(v):O1(v)}function Tu(e){var t=e.content,n=e.width,r=e.height,i=e.transform,s=e.extra,a=e.watchable,o=a===void 0?!1:a,u=$($({},s.attributes),{},{class:s.classes.join(" ")});o&&(u[xt]="");var d=$({},s.styles);Wi(i)&&(d.transform=d1({transform:i,width:n,height:r}),d["-webkit-transform"]=d.transform);var l=qn(d);l.length>0&&(u.style=l);var c=[];return c.push({tag:"span",attributes:u,children:[t]}),c}function V1(e){var t=e.content,n=e.extra,r=$($({},n.attributes),{},{class:n.classes.join(" ")}),i=qn(n.styles);i.length>0&&(r.style=i);var s=[];return s.push({tag:"span",attributes:r,children:[t]}),s}var Ji=Be.styles;function es(e){var t=e[0],n=e[1],r=e.slice(4),i=Yn(r,1),s=i[0],a=null;return Array.isArray(s)?a={tag:"g",attributes:{class:"".concat(K.cssPrefix,"-").concat(zi.GROUP)},children:[{tag:"path",attributes:{class:"".concat(K.cssPrefix,"-").concat(zi.SECONDARY),fill:"currentColor",d:s[0]}},{tag:"path",attributes:{class:"".concat(K.cssPrefix,"-").concat(zi.PRIMARY),fill:"currentColor",d:s[1]}}]}:a={tag:"path",attributes:{fill:"currentColor",d:s}},{found:!0,width:t,height:n,icon:a}}var N1={found:!1,width:512,height:512};function U1(e,t){!Ql&&!K.showMissingIcons&&e&&console.error('Icon with name "'.concat(e,'" and prefix "').concat(t,'" is missing.'))}function ts(e,t){var n=t;return t==="fa"&&K.styleDefault!==null&&(t=ut()),new Promise(function(r,i){if(n==="fa"){var s=vu(e)||{};e=s.iconName||e,t=s.prefix||t}if(e&&t&&Ji[t]&&Ji[t][e]){var a=Ji[t][e];return r(es(a))}U1(e,t),r($($({},N1),{},{icon:K.showMissingIcons&&e?ct("missingIconAbstract")||{}:{}}))})}var Pu=function(){},ns=K.measurePerformance&&Kn&&Kn.mark&&Kn.measure?Kn:{mark:Pu,measure:Pu},vn='FA "7.1.0"',B1=function(t){return ns.mark("".concat(vn," ").concat(t," begins")),function(){return Cu(t)}},Cu=function(t){ns.mark("".concat(vn," ").concat(t," ends")),ns.measure("".concat(vn," ").concat(t),"".concat(vn," ").concat(t," begins"),"".concat(vn," ").concat(t," ends"))},rs={begin:B1,end:Cu},tr=function(){};function Eu(e){var t=e.getAttribute?e.getAttribute(xt):null;return typeof t=="string"}function z1(e){var t=e.getAttribute?e.getAttribute(Ri):null,n=e.getAttribute?e.getAttribute(_i):null;return t&&n}function $1(e){return e&&e.classList&&e.classList.contains&&e.classList.contains(K.replacementClass)}function W1(){if(K.autoReplaceSvg===!0)return nr.replace;var e=nr[K.autoReplaceSvg];return e||nr.replace}function H1(e){return re.createElementNS("http://www.w3.org/2000/svg",e)}function Y1(e){return re.createElement(e)}function Iu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.ceFn,r=n===void 0?e.tag==="svg"?H1:Y1:n;if(typeof e=="string")return re.createTextNode(e);var i=r(e.tag);Object.keys(e.attributes||[]).forEach(function(a){i.setAttribute(a,e.attributes[a])});var s=e.children||[];return s.forEach(function(a){i.appendChild(Iu(a,{ceFn:r}))}),i}function G1(e){var t=" ".concat(e.outerHTML," ");return t="".concat(t,"Font Awesome fontawesome.com "),t}var nr={replace:function(t){var n=t[0];if(n.parentNode)if(t[1].forEach(function(i){n.parentNode.insertBefore(Iu(i),n)}),n.getAttribute(xt)===null&&K.keepOriginalSource){var r=re.createComment(G1(n));n.parentNode.replaceChild(r,n)}else n.remove()},nest:function(t){var n=t[0],r=t[1];if(~$i(n).indexOf(K.replacementClass))return nr.replace(t);var i=new RegExp("".concat(K.cssPrefix,"-.*"));if(delete r[0].attributes.id,r[0].attributes.class){var s=r[0].attributes.class.split(" ").reduce(function(o,u){return u===K.replacementClass||u.match(i)?o.toSvg.push(u):o.toNode.push(u),o},{toNode:[],toSvg:[]});r[0].attributes.class=s.toSvg.join(" "),s.toNode.length===0?n.removeAttribute("class"):n.setAttribute("class",s.toNode.join(" "))}var a=r.map(function(o){return gn(o)}).join(`
568
- `);n.setAttribute(xt,""),n.innerHTML=a}};function ku(e){e()}function Mu(e,t){var n=typeof t=="function"?t:tr;if(e.length===0)n();else{var r=ku;K.mutateApproach===q0&&(r=lt.requestAnimationFrame||ku),r(function(){var i=W1(),s=rs.begin("mutate");e.map(i),s(),n()})}}var is=!1;function Du(){is=!0}function ss(){is=!1}var rr=null;function ju(e){if(wl&&K.observeMutations){var t=e.treeCallback,n=t===void 0?tr:t,r=e.nodeCallback,i=r===void 0?tr:r,s=e.pseudoElementsCallback,a=s===void 0?tr:s,o=e.observeMutationsRoot,u=o===void 0?re:o;rr=new wl(function(d){if(!is){var l=ut();$t(d).forEach(function(c){if(c.type==="childList"&&c.addedNodes.length>0&&!Eu(c.addedNodes[0])&&(K.searchPseudoElements&&a(c.target),n(c.target)),c.type==="attributes"&&c.target.parentNode&&K.searchPseudoElements&&a([c.target],!0),c.type==="attributes"&&Eu(c.target)&&~n1.indexOf(c.attributeName))if(c.attributeName==="class"&&z1(c.target)){var f=Jn($i(c.target)),h=f.prefix,m=f.iconName;c.target.setAttribute(Ri,h||l),m&&c.target.setAttribute(_i,m)}else $1(c.target)&&i(c.target)})}}),Ze&&rr.observe(u,{childList:!0,attributes:!0,characterData:!0,subtree:!0})}}function K1(){rr&&rr.disconnect()}function X1(e){var t=e.getAttribute("style"),n=[];return t&&(n=t.split(";").reduce(function(r,i){var s=i.split(":"),a=s[0],o=s.slice(1);return a&&o.length>0&&(r[a]=o.join(":").trim()),r},{})),n}function q1(e){var t=e.getAttribute("data-prefix"),n=e.getAttribute("data-icon"),r=e.innerText!==void 0?e.innerText.trim():"",i=Jn($i(e));return i.prefix||(i.prefix=ut()),t&&n&&(i.prefix=t,i.iconName=n),i.iconName&&i.prefix||(i.prefix&&r.length>0&&(i.iconName=x1(i.prefix,e.innerText)||Xi(i.prefix,uu(e.innerText))),!i.iconName&&K.autoFetchSvg&&e.firstChild&&e.firstChild.nodeType===Node.TEXT_NODE&&(i.iconName=e.firstChild.data)),i}function Q1(e){var t=$t(e.attributes).reduce(function(n,r){return n.name!=="class"&&n.name!=="style"&&(n[r.name]=r.value),n},{});return t}function Z1(){return{iconName:null,prefix:null,transform:He,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}}}function Fu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{styleParser:!0},n=q1(e),r=n.iconName,i=n.prefix,s=n.rest,a=Q1(e),o=qi("parseNodeAttributes",{},e),u=t.styleParser?X1(e):[];return $({iconName:r,prefix:i,transform:He,mask:{iconName:null,prefix:null,rest:[]},maskId:null,symbol:!1,extra:{classes:s,styles:u,attributes:a}},o)}var J1=Be.styles;function Lu(e){var t=K.autoReplaceSvg==="nest"?Fu(e,{styleParser:!1}):Fu(e);return~t.extra.classes.indexOf(eu)?ct("generateLayersText",e,t):ct("generateSvgReplacementMutation",e,t)}function eg(){return[].concat(Ue(zl),Ue(Hl))}function Ou(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(!Ze)return Promise.resolve();var n=re.documentElement.classList,r=function(c){return n.add("".concat(Xl,"-").concat(c))},i=function(c){return n.remove("".concat(Xl,"-").concat(c))},s=K.autoFetchSvg?eg():Tl.concat(Object.keys(J1));s.includes("fa")||s.push("fa");var a=[".".concat(eu,":not([").concat(xt,"])")].concat(s.map(function(l){return".".concat(l,":not([").concat(xt,"])")})).join(", ");if(a.length===0)return Promise.resolve();var o=[];try{o=$t(e.querySelectorAll(a))}catch{}if(o.length>0)r("pending"),i("complete");else return Promise.resolve();var u=rs.begin("onTree"),d=o.reduce(function(l,c){try{var f=Lu(c);f&&l.push(f)}catch(h){Ql||h.name==="MissingIcon"&&console.error(h)}return l},[]);return new Promise(function(l,c){Promise.all(d).then(function(f){Mu(f,function(){r("active"),r("complete"),i("pending"),typeof t=="function"&&t(),u(),l()})}).catch(function(f){u(),c(f)})})}function tg(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;Lu(e).then(function(n){n&&Mu([n],t)})}function ng(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=(t||{}).icon?t:Qi(t||{}),i=n.mask;return i&&(i=(i||{}).icon?i:Qi(i||{})),e(r,$($({},n),{},{mask:i}))}}var rg=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.transform,i=r===void 0?He:r,s=n.symbol,a=s===void 0?!1:s,o=n.mask,u=o===void 0?null:o,d=n.maskId,l=d===void 0?null:d,c=n.classes,f=c===void 0?[]:c,h=n.attributes,m=h===void 0?{}:h,b=n.styles,w=b===void 0?{}:b;if(t){var v=t.prefix,I=t.iconName,S=t.icon;return er($({type:"icon"},t),function(){return At("beforeDOMElementCreation",{iconDefinition:t,params:n}),Zi({icons:{main:es(S),mask:u?es(u.icon):{found:!1,width:null,height:null,icon:{}}},prefix:v,iconName:I,transform:$($({},He),i),symbol:a,maskId:l,extra:{attributes:m,styles:w,classes:f}})})}},ig={mixout:function(){return{icon:ng(rg)}},hooks:function(){return{mutationObserverCallbacks:function(n){return n.treeCallback=Ou,n.nodeCallback=tg,n}}},provides:function(t){t.i2svg=function(n){var r=n.node,i=r===void 0?re:r,s=n.callback,a=s===void 0?function(){}:s;return Ou(i,a)},t.generateSvgReplacementMutation=function(n,r){var i=r.iconName,s=r.prefix,a=r.transform,o=r.symbol,u=r.mask,d=r.maskId,l=r.extra;return new Promise(function(c,f){Promise.all([ts(i,s),u.iconName?ts(u.iconName,u.prefix):Promise.resolve({found:!1,width:512,height:512,icon:{}})]).then(function(h){var m=Yn(h,2),b=m[0],w=m[1];c([n,Zi({icons:{main:b,mask:w},prefix:s,iconName:i,transform:a,symbol:o,maskId:d,extra:l,watchable:!0})])}).catch(f)})},t.generateAbstractIcon=function(n){var r=n.children,i=n.attributes,s=n.main,a=n.transform,o=n.styles,u=qn(o);u.length>0&&(i.style=u);var d;return Wi(a)&&(d=ct("generateAbstractTransformGrouping",{main:s,transform:a,containerWidth:s.width,iconWidth:s.width})),r.push(d||s.icon),{children:r,attributes:i}}}},sg={mixout:function(){return{layer:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.classes,s=i===void 0?[]:i;return er({type:"layer"},function(){At("beforeDOMElementCreation",{assembler:n,params:r});var a=[];return n(function(o){Array.isArray(o)?o.map(function(u){a=a.concat(u.abstract)}):a=a.concat(o.abstract)}),[{tag:"span",attributes:{class:["".concat(K.cssPrefix,"-layers")].concat(Ue(s)).join(" ")},children:a}]})}}}},ag={mixout:function(){return{counter:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};r.title;var i=r.classes,s=i===void 0?[]:i,a=r.attributes,o=a===void 0?{}:a,u=r.styles,d=u===void 0?{}:u;return er({type:"counter",content:n},function(){return At("beforeDOMElementCreation",{content:n,params:r}),V1({content:n.toString(),extra:{attributes:o,styles:d,classes:["".concat(K.cssPrefix,"-layers-counter")].concat(Ue(s))}})})}}}},og={mixout:function(){return{text:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.transform,s=i===void 0?He:i,a=r.classes,o=a===void 0?[]:a,u=r.attributes,d=u===void 0?{}:u,l=r.styles,c=l===void 0?{}:l;return er({type:"text",content:n},function(){return At("beforeDOMElementCreation",{content:n,params:r}),Tu({content:n,transform:$($({},He),s),extra:{attributes:d,styles:c,classes:["".concat(K.cssPrefix,"-layers-text")].concat(Ue(o))}})})}}},provides:function(t){t.generateLayersText=function(n,r){var i=r.transform,s=r.extra,a=null,o=null;if(Al){var u=parseInt(getComputedStyle(n).fontSize,10),d=n.getBoundingClientRect();a=d.width/u,o=d.height/u}return Promise.resolve([n,Tu({content:n.innerHTML,width:a,height:o,transform:i,extra:s,watchable:!0})])}}},Ru=new RegExp('"',"ug"),_u=[1105920,1112319],Vu=$($($($({},{FontAwesome:{normal:"fas",400:"fas"}}),$p),K0),Zp),as=Object.keys(Vu).reduce(function(e,t){return e[t.toLowerCase()]=Vu[t],e},{}),lg=Object.keys(as).reduce(function(e,t){var n=as[t];return e[t]=n[900]||Ue(Object.entries(n))[0][1],e},{});function ug(e){var t=e.replace(Ru,"");return uu(Ue(t)[0]||"")}function cg(e){var t=e.getPropertyValue("font-feature-settings").includes("ss01"),n=e.getPropertyValue("content"),r=n.replace(Ru,""),i=r.codePointAt(0),s=i>=_u[0]&&i<=_u[1],a=r.length===2?r[0]===r[1]:!1;return s||a||t}function fg(e,t){var n=e.replace(/^['"]|['"]$/g,"").toLowerCase(),r=parseInt(t),i=isNaN(r)?"normal":r;return(as[n]||{})[i]||lg[n]}function Nu(e,t){var n="".concat(X0).concat(t.replace(":","-"));return new Promise(function(r,i){if(e.getAttribute(n)!==null)return r();var s=$t(e.children),a=s.filter(function(A){return A.getAttribute(Oi)===t})[0],o=lt.getComputedStyle(e,t),u=o.getPropertyValue("font-family"),d=u.match(e1),l=o.getPropertyValue("font-weight"),c=o.getPropertyValue("content");if(a&&!d)return e.removeChild(a),r();if(d&&c!=="none"&&c!==""){var f=o.getPropertyValue("content"),h=fg(u,l),m=ug(f),b=d[0].startsWith("FontAwesome"),w=cg(o),v=Xi(h,m),I=v;if(b){var S=w1(m);S.iconName&&S.prefix&&(v=S.iconName,h=S.prefix)}if(v&&!w&&(!a||a.getAttribute(Ri)!==h||a.getAttribute(_i)!==I)){e.setAttribute(n,I),a&&e.removeChild(a);var E=Z1(),P=E.extra;P.attributes[Oi]=t,ts(v,h).then(function(A){var O=Zi($($({},E),{},{icons:{main:A,mask:bu()},prefix:h,iconName:I,extra:P,watchable:!0})),p=re.createElementNS("http://www.w3.org/2000/svg","svg");t==="::before"?e.insertBefore(p,e.firstChild):e.appendChild(p),p.outerHTML=O.map(function(y){return gn(y)}).join(`
567
+ }`;function iu(){var e=Gl,t=Kl,n=K.cssPrefix,r=K.replacementClass,i=h1;if(n!==e||r!==t){var s=new RegExp("\\.".concat(e,"\\-"),"g"),a=new RegExp("\\--".concat(e,"\\-"),"g"),o=new RegExp("\\.".concat(t),"g");i=i.replace(s,".".concat(n,"-")).replace(a,"--".concat(n,"-")).replace(o,".".concat(r))}return i}var su=!1;function Hi(){K.autoAddCss&&!su&&(l1(iu()),su=!0)}var m1={mixout:function(){return{dom:{css:iu,insertCss:Hi}}},hooks:function(){return{beforeDOMElementCreation:function(){Hi()},beforeI2svg:function(){Hi()}}}},et=lt||{};et[Je]||(et[Je]={}),et[Je].styles||(et[Je].styles={}),et[Je].hooks||(et[Je].hooks={}),et[Je].shims||(et[Je].shims=[]);var Be=et[Je],au=[],ou=function(){se.removeEventListener("DOMContentLoaded",ou),Qn=1,au.map(function(t){return t()})},Qn=!1;Ze&&(Qn=(se.documentElement.doScroll?/^loaded|^c/:/^loaded|^i|^c/).test(se.readyState),Qn||se.addEventListener("DOMContentLoaded",ou));function p1(e){Ze&&(Qn?setTimeout(e,0):au.push(e))}function gn(e){var t=e.tag,n=e.attributes,r=n===void 0?{}:n,i=e.children,s=i===void 0?[]:i;return typeof e=="string"?ru(e):"<".concat(t," ").concat(c1(r),">").concat(s.map(gn).join(""),"</").concat(t,">")}function lu(e,t,n){if(e&&e[t]&&e[t][n])return{prefix:t,iconName:n,icon:e[t][n]}}var Yi=function(t,n,r,i){var s=Object.keys(t),a=s.length,o=n,u,d,l;for(r===void 0?(u=1,l=t[s[0]]):(u=0,l=r);u<a;u++)d=s[u],l=o(l,t[d],d,t);return l};function uu(e){return Ue(e).length!==1?null:e.codePointAt(0).toString(16)}function cu(e){return Object.keys(e).reduce(function(t,n){var r=e[n],i=!!r.icon;return i?t[r.iconName]=r.icon:t[n]=r,t},{})}function Gi(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.skipHooks,i=r===void 0?!1:r,s=cu(t);typeof Be.hooks.addPack=="function"&&!i?Be.hooks.addPack(e,cu(t)):Be.styles[e]=$($({},Be.styles[e]||{}),s),e==="fas"&&Gi("fa",t)}var yn=Be.styles,g1=Be.shims,fu=Object.keys(Ui),y1=fu.reduce(function(e,t){return e[t]=Object.keys(Ui[t]),e},{}),Ki=null,du={},hu={},mu={},pu={},gu={};function v1(e){return~r1.indexOf(e)}function b1(e,t){var n=t.split("-"),r=n[0],i=n.slice(1).join("-");return r===e&&i!==""&&!v1(i)?i:null}var yu=function(){var t=function(s){return Yi(yn,function(a,o,u){return a[u]=Yi(o,s,{}),a},{})};du=t(function(i,s,a){if(s[3]&&(i[s[3]]=a),s[2]){var o=s[2].filter(function(u){return typeof u=="number"});o.forEach(function(u){i[u.toString(16)]=a})}return i}),hu=t(function(i,s,a){if(i[a]=a,s[2]){var o=s[2].filter(function(u){return typeof u=="string"});o.forEach(function(u){i[u]=a})}return i}),gu=t(function(i,s,a){var o=s[2];return i[a]=a,o.forEach(function(u){i[u]=a}),i});var n="far"in yn||K.autoFetchSvg,r=Yi(g1,function(i,s){var a=s[0],o=s[1],u=s[2];return o==="far"&&!n&&(o="fas"),typeof a=="string"&&(i.names[a]={prefix:o,iconName:u}),typeof a=="number"&&(i.unicodes[a.toString(16)]={prefix:o,iconName:u}),i},{names:{},unicodes:{}});mu=r.names,pu=r.unicodes,Ki=Zn(K.styleDefault,{family:K.familyDefault})};o1(function(e){Ki=Zn(e.styleDefault,{family:K.familyDefault})}),yu();function Xi(e,t){return(du[e]||{})[t]}function x1(e,t){return(hu[e]||{})[t]}function wt(e,t){return(gu[e]||{})[t]}function vu(e){return mu[e]||{prefix:null,iconName:null}}function w1(e){var t=pu[e],n=Xi("fas",e);return t||(n?{prefix:"fas",iconName:n}:null)||{prefix:null,iconName:null}}function ut(){return Ki}var bu=function(){return{prefix:null,iconName:null,rest:[]}};function A1(e){var t=ve,n=fu.reduce(function(r,i){return r[i]="".concat(K.cssPrefix,"-").concat(i),r},{});return Bl.forEach(function(r){(e.includes(n[r])||e.some(function(i){return y1[r].includes(i)}))&&(t=r)}),t}function Zn(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.family,r=n===void 0?ve:n,i=Z0[r][e];if(r===dn&&!e)return"fad";var s=Jl[r][e]||Jl[r][i],a=e in Be.styles?e:null,o=s||a||null;return o}function S1(e){var t=[],n=null;return e.forEach(function(r){var i=b1(K.cssPrefix,r);i?n=i:r&&t.push(r)}),{iconName:n,rest:t}}function xu(e){return e.sort().filter(function(t,n,r){return r.indexOf(t)===n})}var wu=Hl.concat(zl);function Jn(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.skipLookups,r=n===void 0?!1:n,i=null,s=xu(e.filter(function(h){return wu.includes(h)})),a=xu(e.filter(function(h){return!wu.includes(h)})),o=s.filter(function(h){return i=h,!Tl.includes(h)}),u=Yn(o,1),d=u[0],l=d===void 0?null:d,c=A1(s),f=$($({},S1(a)),{},{prefix:Zn(l,{family:c})});return $($($({},f),E1({values:e,family:c,styles:yn,config:K,canonical:f,givenPrefix:i})),T1(r,i,f))}function T1(e,t,n){var r=n.prefix,i=n.iconName;if(e||!r||!i)return{prefix:r,iconName:i};var s=t==="fa"?vu(i):{},a=wt(r,i);return i=s.iconName||a||i,r=s.prefix||r,r==="far"&&!yn.far&&yn.fas&&!K.autoFetchSvg&&(r="fas"),{prefix:r,iconName:i}}var P1=Bl.filter(function(e){return e!==ve||e!==dn}),C1=Object.keys(Fi).filter(function(e){return e!==ve}).map(function(e){return Object.keys(Fi[e])}).flat();function E1(e){var t=e.values,n=e.family,r=e.canonical,i=e.givenPrefix,s=i===void 0?"":i,a=e.styles,o=a===void 0?{}:a,u=e.config,d=u===void 0?{}:u,l=n===dn,c=t.includes("fa-duotone")||t.includes("fad"),f=d.familyDefault==="duotone",h=r.prefix==="fad"||r.prefix==="fa-duotone";if(!l&&(c||f||h)&&(r.prefix="fad"),(t.includes("fa-brands")||t.includes("fab"))&&(r.prefix="fab"),!r.prefix&&P1.includes(n)){var m=Object.keys(o).find(function(w){return C1.includes(w)});if(m||d.autoFetchSvg){var b=Wp.get(n).defaultShortPrefixId;r.prefix=b,r.iconName=wt(r.prefix,r.iconName)||r.iconName}}return(r.prefix==="fa"||s==="fa")&&(r.prefix=ut()||"fas"),r}var I1=(function(){function e(){dp(this,e),this.definitions={}}return mp(e,[{key:"add",value:function(){for(var n=this,r=arguments.length,i=new Array(r),s=0;s<r;s++)i[s]=arguments[s];var a=i.reduce(this._pullDefinitions,{});Object.keys(a).forEach(function(o){n.definitions[o]=$($({},n.definitions[o]||{}),a[o]),Gi(o,a[o]);var u=Ui[ve][o];u&&Gi(u,a[o]),yu()})}},{key:"reset",value:function(){this.definitions={}}},{key:"_pullDefinitions",value:function(n,r){var i=r.prefix&&r.iconName&&r.icon?{0:r}:r;return Object.keys(i).map(function(s){var a=i[s],o=a.prefix,u=a.iconName,d=a.icon,l=d[2];n[o]||(n[o]={}),l.length>0&&l.forEach(function(c){typeof c=="string"&&(n[o][c]=d)}),n[o][u]=d}),n}}])})(),Au=[],Wt={},Ht={},k1=Object.keys(Ht);function M1(e,t){var n=t.mixoutsTo;return Au=e,Wt={},Object.keys(Ht).forEach(function(r){k1.indexOf(r)===-1&&delete Ht[r]}),Au.forEach(function(r){var i=r.mixout?r.mixout():{};if(Object.keys(i).forEach(function(a){typeof i[a]=="function"&&(n[a]=i[a]),Gn(i[a])==="object"&&Object.keys(i[a]).forEach(function(o){n[a]||(n[a]={}),n[a][o]=i[a][o]})}),r.hooks){var s=r.hooks();Object.keys(s).forEach(function(a){Wt[a]||(Wt[a]=[]),Wt[a].push(s[a])})}r.provides&&r.provides(Ht)}),n}function qi(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];var s=Wt[e]||[];return s.forEach(function(a){t=a.apply(null,[t].concat(r))}),t}function At(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var i=Wt[e]||[];i.forEach(function(s){s.apply(null,n)})}function ct(){var e=arguments[0],t=Array.prototype.slice.call(arguments,1);return Ht[e]?Ht[e].apply(null,t):void 0}function Qi(e){e.prefix==="fa"&&(e.prefix="fas");var t=e.iconName,n=e.prefix||ut();if(t)return t=wt(n,t)||t,lu(Su.definitions,n,t)||lu(Be.styles,n,t)}var Su=new I1,D1=function(){K.autoReplaceSvg=!1,K.observeMutations=!1,At("noAuto")},j1={i2svg:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Ze?(At("beforeI2svg",t),ct("pseudoElements2svg",t),ct("i2svg",t)):Promise.reject(new Error("Operation requires a DOM of some kind."))},watch:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.autoReplaceSvgRoot;K.autoReplaceSvg===!1&&(K.autoReplaceSvg=!0),K.observeMutations=!0,p1(function(){L1({autoReplaceSvgRoot:n}),At("watch",t)})}},F1={icon:function(t){if(t===null)return null;if(Gn(t)==="object"&&t.prefix&&t.iconName)return{prefix:t.prefix,iconName:wt(t.prefix,t.iconName)||t.iconName};if(Array.isArray(t)&&t.length===2){var n=t[1].indexOf("fa-")===0?t[1].slice(3):t[1],r=Zn(t[0]);return{prefix:r,iconName:wt(r,n)||n}}if(typeof t=="string"&&(t.indexOf("".concat(K.cssPrefix,"-"))>-1||t.match(J0))){var i=Jn(t.split(" "),{skipLookups:!0});return{prefix:i.prefix||ut(),iconName:wt(i.prefix,i.iconName)||i.iconName}}if(typeof t=="string"){var s=ut();return{prefix:s,iconName:wt(s,t)||t}}}},ke={noAuto:D1,config:K,dom:j1,parse:F1,library:Su,findIconDefinition:Qi,toHtml:gn},L1=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.autoReplaceSvgRoot,r=n===void 0?se:n;(Object.keys(Be.styles).length>0||K.autoFetchSvg)&&Ze&&K.autoReplaceSvg&&ke.dom.i2svg({node:r})};function er(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map(function(r){return gn(r)})}}),Object.defineProperty(e,"node",{get:function(){if(Ze){var r=se.createElement("div");return r.innerHTML=e.html,r.children}}}),e}function O1(e){var t=e.children,n=e.main,r=e.mask,i=e.attributes,s=e.styles,a=e.transform;if(Wi(a)&&n.found&&!r.found){var o=n.width,u=n.height,d={x:o/u/2,y:.5};i.style=qn($($({},s),{},{"transform-origin":"".concat(d.x+a.x/16,"em ").concat(d.y+a.y/16,"em")}))}return[{tag:"svg",attributes:i,children:t}]}function R1(e){var t=e.prefix,n=e.iconName,r=e.children,i=e.attributes,s=e.symbol,a=s===!0?"".concat(t,"-").concat(K.cssPrefix,"-").concat(n):s;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:$($({},i),{},{id:a}),children:r}]}]}function _1(e){var t=["aria-label","aria-labelledby","title","role"];return t.some(function(n){return n in e})}function Zi(e){var t=e.icons,n=t.main,r=t.mask,i=e.prefix,s=e.iconName,a=e.transform,o=e.symbol,u=e.maskId,d=e.extra,l=e.watchable,c=l===void 0?!1:l,f=r.found?r:n,h=f.width,m=f.height,b=[K.replacementClass,s?"".concat(K.cssPrefix,"-").concat(s):""].filter(function(P){return d.classes.indexOf(P)===-1}).filter(function(P){return P!==""||!!P}).concat(d.classes).join(" "),w={children:[],attributes:$($({},d.attributes),{},{"data-prefix":i,"data-icon":s,class:b,role:d.attributes.role||"img",viewBox:"0 0 ".concat(h," ").concat(m)})};!_1(d.attributes)&&!d.attributes["aria-hidden"]&&(w.attributes["aria-hidden"]="true"),c&&(w.attributes[xt]="");var v=$($({},w),{},{prefix:i,iconName:s,main:n,mask:r,maskId:u,transform:a,symbol:o,styles:$({},d.styles)}),I=r.found&&n.found?ct("generateAbstractMask",v)||{children:[],attributes:{}}:ct("generateAbstractIcon",v)||{children:[],attributes:{}},S=I.children,E=I.attributes;return v.children=S,v.attributes=E,o?R1(v):O1(v)}function Tu(e){var t=e.content,n=e.width,r=e.height,i=e.transform,s=e.extra,a=e.watchable,o=a===void 0?!1:a,u=$($({},s.attributes),{},{class:s.classes.join(" ")});o&&(u[xt]="");var d=$({},s.styles);Wi(i)&&(d.transform=d1({transform:i,width:n,height:r}),d["-webkit-transform"]=d.transform);var l=qn(d);l.length>0&&(u.style=l);var c=[];return c.push({tag:"span",attributes:u,children:[t]}),c}function V1(e){var t=e.content,n=e.extra,r=$($({},n.attributes),{},{class:n.classes.join(" ")}),i=qn(n.styles);i.length>0&&(r.style=i);var s=[];return s.push({tag:"span",attributes:r,children:[t]}),s}var Ji=Be.styles;function es(e){var t=e[0],n=e[1],r=e.slice(4),i=Yn(r,1),s=i[0],a=null;return Array.isArray(s)?a={tag:"g",attributes:{class:"".concat(K.cssPrefix,"-").concat(zi.GROUP)},children:[{tag:"path",attributes:{class:"".concat(K.cssPrefix,"-").concat(zi.SECONDARY),fill:"currentColor",d:s[0]}},{tag:"path",attributes:{class:"".concat(K.cssPrefix,"-").concat(zi.PRIMARY),fill:"currentColor",d:s[1]}}]}:a={tag:"path",attributes:{fill:"currentColor",d:s}},{found:!0,width:t,height:n,icon:a}}var N1={found:!1,width:512,height:512};function U1(e,t){!Ql&&!K.showMissingIcons&&e&&console.error('Icon with name "'.concat(e,'" and prefix "').concat(t,'" is missing.'))}function ts(e,t){var n=t;return t==="fa"&&K.styleDefault!==null&&(t=ut()),new Promise(function(r,i){if(n==="fa"){var s=vu(e)||{};e=s.iconName||e,t=s.prefix||t}if(e&&t&&Ji[t]&&Ji[t][e]){var a=Ji[t][e];return r(es(a))}U1(e,t),r($($({},N1),{},{icon:K.showMissingIcons&&e?ct("missingIconAbstract")||{}:{}}))})}var Pu=function(){},ns=K.measurePerformance&&Kn&&Kn.mark&&Kn.measure?Kn:{mark:Pu,measure:Pu},vn='FA "7.1.0"',B1=function(t){return ns.mark("".concat(vn," ").concat(t," begins")),function(){return Cu(t)}},Cu=function(t){ns.mark("".concat(vn," ").concat(t," ends")),ns.measure("".concat(vn," ").concat(t),"".concat(vn," ").concat(t," begins"),"".concat(vn," ").concat(t," ends"))},rs={begin:B1,end:Cu},tr=function(){};function Eu(e){var t=e.getAttribute?e.getAttribute(xt):null;return typeof t=="string"}function z1(e){var t=e.getAttribute?e.getAttribute(Ri):null,n=e.getAttribute?e.getAttribute(_i):null;return t&&n}function $1(e){return e&&e.classList&&e.classList.contains&&e.classList.contains(K.replacementClass)}function W1(){if(K.autoReplaceSvg===!0)return nr.replace;var e=nr[K.autoReplaceSvg];return e||nr.replace}function H1(e){return se.createElementNS("http://www.w3.org/2000/svg",e)}function Y1(e){return se.createElement(e)}function Iu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.ceFn,r=n===void 0?e.tag==="svg"?H1:Y1:n;if(typeof e=="string")return se.createTextNode(e);var i=r(e.tag);Object.keys(e.attributes||[]).forEach(function(a){i.setAttribute(a,e.attributes[a])});var s=e.children||[];return s.forEach(function(a){i.appendChild(Iu(a,{ceFn:r}))}),i}function G1(e){var t=" ".concat(e.outerHTML," ");return t="".concat(t,"Font Awesome fontawesome.com "),t}var nr={replace:function(t){var n=t[0];if(n.parentNode)if(t[1].forEach(function(i){n.parentNode.insertBefore(Iu(i),n)}),n.getAttribute(xt)===null&&K.keepOriginalSource){var r=se.createComment(G1(n));n.parentNode.replaceChild(r,n)}else n.remove()},nest:function(t){var n=t[0],r=t[1];if(~$i(n).indexOf(K.replacementClass))return nr.replace(t);var i=new RegExp("".concat(K.cssPrefix,"-.*"));if(delete r[0].attributes.id,r[0].attributes.class){var s=r[0].attributes.class.split(" ").reduce(function(o,u){return u===K.replacementClass||u.match(i)?o.toSvg.push(u):o.toNode.push(u),o},{toNode:[],toSvg:[]});r[0].attributes.class=s.toSvg.join(" "),s.toNode.length===0?n.removeAttribute("class"):n.setAttribute("class",s.toNode.join(" "))}var a=r.map(function(o){return gn(o)}).join(`
568
+ `);n.setAttribute(xt,""),n.innerHTML=a}};function ku(e){e()}function Mu(e,t){var n=typeof t=="function"?t:tr;if(e.length===0)n();else{var r=ku;K.mutateApproach===q0&&(r=lt.requestAnimationFrame||ku),r(function(){var i=W1(),s=rs.begin("mutate");e.map(i),s(),n()})}}var is=!1;function Du(){is=!0}function ss(){is=!1}var rr=null;function ju(e){if(wl&&K.observeMutations){var t=e.treeCallback,n=t===void 0?tr:t,r=e.nodeCallback,i=r===void 0?tr:r,s=e.pseudoElementsCallback,a=s===void 0?tr:s,o=e.observeMutationsRoot,u=o===void 0?se:o;rr=new wl(function(d){if(!is){var l=ut();$t(d).forEach(function(c){if(c.type==="childList"&&c.addedNodes.length>0&&!Eu(c.addedNodes[0])&&(K.searchPseudoElements&&a(c.target),n(c.target)),c.type==="attributes"&&c.target.parentNode&&K.searchPseudoElements&&a([c.target],!0),c.type==="attributes"&&Eu(c.target)&&~n1.indexOf(c.attributeName))if(c.attributeName==="class"&&z1(c.target)){var f=Jn($i(c.target)),h=f.prefix,m=f.iconName;c.target.setAttribute(Ri,h||l),m&&c.target.setAttribute(_i,m)}else $1(c.target)&&i(c.target)})}}),Ze&&rr.observe(u,{childList:!0,attributes:!0,characterData:!0,subtree:!0})}}function K1(){rr&&rr.disconnect()}function X1(e){var t=e.getAttribute("style"),n=[];return t&&(n=t.split(";").reduce(function(r,i){var s=i.split(":"),a=s[0],o=s.slice(1);return a&&o.length>0&&(r[a]=o.join(":").trim()),r},{})),n}function q1(e){var t=e.getAttribute("data-prefix"),n=e.getAttribute("data-icon"),r=e.innerText!==void 0?e.innerText.trim():"",i=Jn($i(e));return i.prefix||(i.prefix=ut()),t&&n&&(i.prefix=t,i.iconName=n),i.iconName&&i.prefix||(i.prefix&&r.length>0&&(i.iconName=x1(i.prefix,e.innerText)||Xi(i.prefix,uu(e.innerText))),!i.iconName&&K.autoFetchSvg&&e.firstChild&&e.firstChild.nodeType===Node.TEXT_NODE&&(i.iconName=e.firstChild.data)),i}function Q1(e){var t=$t(e.attributes).reduce(function(n,r){return n.name!=="class"&&n.name!=="style"&&(n[r.name]=r.value),n},{});return t}function Z1(){return{iconName:null,prefix:null,transform:He,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}}}function Fu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{styleParser:!0},n=q1(e),r=n.iconName,i=n.prefix,s=n.rest,a=Q1(e),o=qi("parseNodeAttributes",{},e),u=t.styleParser?X1(e):[];return $({iconName:r,prefix:i,transform:He,mask:{iconName:null,prefix:null,rest:[]},maskId:null,symbol:!1,extra:{classes:s,styles:u,attributes:a}},o)}var J1=Be.styles;function Lu(e){var t=K.autoReplaceSvg==="nest"?Fu(e,{styleParser:!1}):Fu(e);return~t.extra.classes.indexOf(eu)?ct("generateLayersText",e,t):ct("generateSvgReplacementMutation",e,t)}function eg(){return[].concat(Ue(zl),Ue(Hl))}function Ou(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(!Ze)return Promise.resolve();var n=se.documentElement.classList,r=function(c){return n.add("".concat(Xl,"-").concat(c))},i=function(c){return n.remove("".concat(Xl,"-").concat(c))},s=K.autoFetchSvg?eg():Tl.concat(Object.keys(J1));s.includes("fa")||s.push("fa");var a=[".".concat(eu,":not([").concat(xt,"])")].concat(s.map(function(l){return".".concat(l,":not([").concat(xt,"])")})).join(", ");if(a.length===0)return Promise.resolve();var o=[];try{o=$t(e.querySelectorAll(a))}catch{}if(o.length>0)r("pending"),i("complete");else return Promise.resolve();var u=rs.begin("onTree"),d=o.reduce(function(l,c){try{var f=Lu(c);f&&l.push(f)}catch(h){Ql||h.name==="MissingIcon"&&console.error(h)}return l},[]);return new Promise(function(l,c){Promise.all(d).then(function(f){Mu(f,function(){r("active"),r("complete"),i("pending"),typeof t=="function"&&t(),u(),l()})}).catch(function(f){u(),c(f)})})}function tg(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;Lu(e).then(function(n){n&&Mu([n],t)})}function ng(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=(t||{}).icon?t:Qi(t||{}),i=n.mask;return i&&(i=(i||{}).icon?i:Qi(i||{})),e(r,$($({},n),{},{mask:i}))}}var rg=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.transform,i=r===void 0?He:r,s=n.symbol,a=s===void 0?!1:s,o=n.mask,u=o===void 0?null:o,d=n.maskId,l=d===void 0?null:d,c=n.classes,f=c===void 0?[]:c,h=n.attributes,m=h===void 0?{}:h,b=n.styles,w=b===void 0?{}:b;if(t){var v=t.prefix,I=t.iconName,S=t.icon;return er($({type:"icon"},t),function(){return At("beforeDOMElementCreation",{iconDefinition:t,params:n}),Zi({icons:{main:es(S),mask:u?es(u.icon):{found:!1,width:null,height:null,icon:{}}},prefix:v,iconName:I,transform:$($({},He),i),symbol:a,maskId:l,extra:{attributes:m,styles:w,classes:f}})})}},ig={mixout:function(){return{icon:ng(rg)}},hooks:function(){return{mutationObserverCallbacks:function(n){return n.treeCallback=Ou,n.nodeCallback=tg,n}}},provides:function(t){t.i2svg=function(n){var r=n.node,i=r===void 0?se:r,s=n.callback,a=s===void 0?function(){}:s;return Ou(i,a)},t.generateSvgReplacementMutation=function(n,r){var i=r.iconName,s=r.prefix,a=r.transform,o=r.symbol,u=r.mask,d=r.maskId,l=r.extra;return new Promise(function(c,f){Promise.all([ts(i,s),u.iconName?ts(u.iconName,u.prefix):Promise.resolve({found:!1,width:512,height:512,icon:{}})]).then(function(h){var m=Yn(h,2),b=m[0],w=m[1];c([n,Zi({icons:{main:b,mask:w},prefix:s,iconName:i,transform:a,symbol:o,maskId:d,extra:l,watchable:!0})])}).catch(f)})},t.generateAbstractIcon=function(n){var r=n.children,i=n.attributes,s=n.main,a=n.transform,o=n.styles,u=qn(o);u.length>0&&(i.style=u);var d;return Wi(a)&&(d=ct("generateAbstractTransformGrouping",{main:s,transform:a,containerWidth:s.width,iconWidth:s.width})),r.push(d||s.icon),{children:r,attributes:i}}}},sg={mixout:function(){return{layer:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.classes,s=i===void 0?[]:i;return er({type:"layer"},function(){At("beforeDOMElementCreation",{assembler:n,params:r});var a=[];return n(function(o){Array.isArray(o)?o.map(function(u){a=a.concat(u.abstract)}):a=a.concat(o.abstract)}),[{tag:"span",attributes:{class:["".concat(K.cssPrefix,"-layers")].concat(Ue(s)).join(" ")},children:a}]})}}}},ag={mixout:function(){return{counter:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};r.title;var i=r.classes,s=i===void 0?[]:i,a=r.attributes,o=a===void 0?{}:a,u=r.styles,d=u===void 0?{}:u;return er({type:"counter",content:n},function(){return At("beforeDOMElementCreation",{content:n,params:r}),V1({content:n.toString(),extra:{attributes:o,styles:d,classes:["".concat(K.cssPrefix,"-layers-counter")].concat(Ue(s))}})})}}}},og={mixout:function(){return{text:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.transform,s=i===void 0?He:i,a=r.classes,o=a===void 0?[]:a,u=r.attributes,d=u===void 0?{}:u,l=r.styles,c=l===void 0?{}:l;return er({type:"text",content:n},function(){return At("beforeDOMElementCreation",{content:n,params:r}),Tu({content:n,transform:$($({},He),s),extra:{attributes:d,styles:c,classes:["".concat(K.cssPrefix,"-layers-text")].concat(Ue(o))}})})}}},provides:function(t){t.generateLayersText=function(n,r){var i=r.transform,s=r.extra,a=null,o=null;if(Al){var u=parseInt(getComputedStyle(n).fontSize,10),d=n.getBoundingClientRect();a=d.width/u,o=d.height/u}return Promise.resolve([n,Tu({content:n.innerHTML,width:a,height:o,transform:i,extra:s,watchable:!0})])}}},Ru=new RegExp('"',"ug"),_u=[1105920,1112319],Vu=$($($($({},{FontAwesome:{normal:"fas",400:"fas"}}),$p),K0),Zp),as=Object.keys(Vu).reduce(function(e,t){return e[t.toLowerCase()]=Vu[t],e},{}),lg=Object.keys(as).reduce(function(e,t){var n=as[t];return e[t]=n[900]||Ue(Object.entries(n))[0][1],e},{});function ug(e){var t=e.replace(Ru,"");return uu(Ue(t)[0]||"")}function cg(e){var t=e.getPropertyValue("font-feature-settings").includes("ss01"),n=e.getPropertyValue("content"),r=n.replace(Ru,""),i=r.codePointAt(0),s=i>=_u[0]&&i<=_u[1],a=r.length===2?r[0]===r[1]:!1;return s||a||t}function fg(e,t){var n=e.replace(/^['"]|['"]$/g,"").toLowerCase(),r=parseInt(t),i=isNaN(r)?"normal":r;return(as[n]||{})[i]||lg[n]}function Nu(e,t){var n="".concat(X0).concat(t.replace(":","-"));return new Promise(function(r,i){if(e.getAttribute(n)!==null)return r();var s=$t(e.children),a=s.filter(function(A){return A.getAttribute(Oi)===t})[0],o=lt.getComputedStyle(e,t),u=o.getPropertyValue("font-family"),d=u.match(e1),l=o.getPropertyValue("font-weight"),c=o.getPropertyValue("content");if(a&&!d)return e.removeChild(a),r();if(d&&c!=="none"&&c!==""){var f=o.getPropertyValue("content"),h=fg(u,l),m=ug(f),b=d[0].startsWith("FontAwesome"),w=cg(o),v=Xi(h,m),I=v;if(b){var S=w1(m);S.iconName&&S.prefix&&(v=S.iconName,h=S.prefix)}if(v&&!w&&(!a||a.getAttribute(Ri)!==h||a.getAttribute(_i)!==I)){e.setAttribute(n,I),a&&e.removeChild(a);var E=Z1(),P=E.extra;P.attributes[Oi]=t,ts(v,h).then(function(A){var O=Zi($($({},E),{},{icons:{main:A,mask:bu()},prefix:h,iconName:I,extra:P,watchable:!0})),p=se.createElementNS("http://www.w3.org/2000/svg","svg");t==="::before"?e.insertBefore(p,e.firstChild):e.appendChild(p),p.outerHTML=O.map(function(y){return gn(y)}).join(`
569
569
  `),e.removeAttribute(n),r()}).catch(i)}else r()}else r()})}function dg(e){return Promise.all([Nu(e,"::before"),Nu(e,"::after")])}function hg(e){return e.parentNode!==document.head&&!~Q0.indexOf(e.tagName.toUpperCase())&&!e.getAttribute(Oi)&&(!e.parentNode||e.parentNode.tagName!=="svg")}var mg=function(t){return!!t&&ql.some(function(n){return t.includes(n)})},pg=function(t){if(!t)return[];var n=new Set,r=t.split(/,(?![^()]*\))/).map(function(u){return u.trim()});r=r.flatMap(function(u){return u.includes("(")?u:u.split(",").map(function(d){return d.trim()})});var i=Hn(r),s;try{for(i.s();!(s=i.n()).done;){var a=s.value;if(mg(a)){var o=ql.reduce(function(u,d){return u.replace(d,"")},a);o!==""&&o!=="*"&&n.add(o)}}}catch(u){i.e(u)}finally{i.f()}return n};function Uu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(Ze){var n;if(t)n=e;else if(K.searchPseudoElementsFullScan)n=e.querySelectorAll("*");else{var r=new Set,i=Hn(document.styleSheets),s;try{for(i.s();!(s=i.n()).done;){var a=s.value;try{var o=Hn(a.cssRules),u;try{for(o.s();!(u=o.n()).done;){var d=u.value,l=pg(d.selectorText),c=Hn(l),f;try{for(c.s();!(f=c.n()).done;){var h=f.value;r.add(h)}}catch(b){c.e(b)}finally{c.f()}}}catch(b){o.e(b)}finally{o.f()}}catch(b){K.searchPseudoElementsWarnings&&console.warn("Font Awesome: cannot parse stylesheet: ".concat(a.href," (").concat(b.message,`)
570
- If it declares any Font Awesome CSS pseudo-elements, they will not be rendered as SVG icons. Add crossorigin="anonymous" to the <link>, enable searchPseudoElementsFullScan for slower but more thorough DOM parsing, or suppress this warning by setting searchPseudoElementsWarnings to false.`))}}}catch(b){i.e(b)}finally{i.f()}if(!r.size)return;var m=Array.from(r).join(", ");try{n=e.querySelectorAll(m)}catch{}}return new Promise(function(b,w){var v=$t(n).filter(hg).map(dg),I=rs.begin("searchPseudoElements");Du(),Promise.all(v).then(function(){I(),ss(),b()}).catch(function(){I(),ss(),w()})})}}var gg={hooks:function(){return{mutationObserverCallbacks:function(n){return n.pseudoElementsCallback=Uu,n}}},provides:function(t){t.pseudoElements2svg=function(n){var r=n.node,i=r===void 0?re:r;K.searchPseudoElements&&Uu(i)}}},Bu=!1,yg={mixout:function(){return{dom:{unwatch:function(){Du(),Bu=!0}}}},hooks:function(){return{bootstrap:function(){ju(qi("mutationObserverCallbacks",{}))},noAuto:function(){K1()},watch:function(n){var r=n.observeMutationsRoot;Bu?ss():ju(qi("mutationObserverCallbacks",{observeMutationsRoot:r}))}}}},zu=function(t){var n={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return t.toLowerCase().split(" ").reduce(function(r,i){var s=i.toLowerCase().split("-"),a=s[0],o=s.slice(1).join("-");if(a&&o==="h")return r.flipX=!0,r;if(a&&o==="v")return r.flipY=!0,r;if(o=parseFloat(o),isNaN(o))return r;switch(a){case"grow":r.size=r.size+o;break;case"shrink":r.size=r.size-o;break;case"left":r.x=r.x-o;break;case"right":r.x=r.x+o;break;case"up":r.y=r.y-o;break;case"down":r.y=r.y+o;break;case"rotate":r.rotate=r.rotate+o;break}return r},n)},vg={mixout:function(){return{parse:{transform:function(n){return zu(n)}}}},hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-transform");return i&&(n.transform=zu(i)),n}}},provides:function(t){t.generateAbstractTransformGrouping=function(n){var r=n.main,i=n.transform,s=n.containerWidth,a=n.iconWidth,o={transform:"translate(".concat(s/2," 256)")},u="translate(".concat(i.x*32,", ").concat(i.y*32,") "),d="scale(".concat(i.size/16*(i.flipX?-1:1),", ").concat(i.size/16*(i.flipY?-1:1),") "),l="rotate(".concat(i.rotate," 0 0)"),c={transform:"".concat(u," ").concat(d," ").concat(l)},f={transform:"translate(".concat(a/2*-1," -256)")},h={outer:o,inner:c,path:f};return{tag:"g",attributes:$({},h.outer),children:[{tag:"g",attributes:$({},h.inner),children:[{tag:r.icon.tag,children:r.icon.children,attributes:$($({},r.icon.attributes),h.path)}]}]}}}},os={x:0,y:0,width:"100%",height:"100%"};function $u(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return e.attributes&&(e.attributes.fill||t)&&(e.attributes.fill="black"),e}function bg(e){return e.tag==="g"?e.children:[e]}var xg={hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-mask"),s=i?Jn(i.split(" ").map(function(a){return a.trim()})):bu();return s.prefix||(s.prefix=ut()),n.mask=s,n.maskId=r.getAttribute("data-fa-mask-id"),n}}},provides:function(t){t.generateAbstractMask=function(n){var r=n.children,i=n.attributes,s=n.main,a=n.mask,o=n.maskId,u=n.transform,d=s.width,l=s.icon,c=a.width,f=a.icon,h=f1({transform:u,containerWidth:c,iconWidth:d}),m={tag:"rect",attributes:$($({},os),{},{fill:"white"})},b=l.children?{children:l.children.map($u)}:{},w={tag:"g",attributes:$({},h.inner),children:[$u($({tag:l.tag,attributes:$($({},l.attributes),h.path)},b))]},v={tag:"g",attributes:$({},h.outer),children:[w]},I="mask-".concat(o||nu()),S="clip-".concat(o||nu()),E={tag:"mask",attributes:$($({},os),{},{id:I,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[m,v]},P={tag:"defs",children:[{tag:"clipPath",attributes:{id:S},children:bg(f)},E]};return r.push(P,{tag:"rect",attributes:$({fill:"currentColor","clip-path":"url(#".concat(S,")"),mask:"url(#".concat(I,")")},os)}),{children:r,attributes:i}}}},wg={provides:function(t){var n=!1;lt.matchMedia&&(n=lt.matchMedia("(prefers-reduced-motion: reduce)").matches),t.missingIconAbstract=function(){var r=[],i={fill:"currentColor"},s={attributeType:"XML",repeatCount:"indefinite",dur:"2s"};r.push({tag:"path",attributes:$($({},i),{},{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})});var a=$($({},s),{},{attributeName:"opacity"}),o={tag:"circle",attributes:$($({},i),{},{cx:"256",cy:"364",r:"28"}),children:[]};return n||o.children.push({tag:"animate",attributes:$($({},s),{},{attributeName:"r",values:"28;14;28;28;14;28;"})},{tag:"animate",attributes:$($({},a),{},{values:"1;0;1;1;0;1;"})}),r.push(o),r.push({tag:"path",attributes:$($({},i),{},{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),children:n?[]:[{tag:"animate",attributes:$($({},a),{},{values:"1;0;0;0;0;1;"})}]}),n||r.push({tag:"path",attributes:$($({},i),{},{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),children:[{tag:"animate",attributes:$($({},a),{},{values:"0;0;1;1;0;0;"})}]}),{tag:"g",attributes:{class:"missing"},children:r}}}},Ag={hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-symbol"),s=i===null?!1:i===""?!0:i;return n.symbol=s,n}}}},Sg=[m1,ig,sg,ag,og,gg,yg,vg,xg,wg,Ag];M1(Sg,{mixoutsTo:ke}),ke.noAuto;var bn=ke.config,Tg=ke.library;ke.dom;var Wu=ke.parse;ke.findIconDefinition,ke.toHtml;var Pg=ke.icon;ke.layer,ke.text,ke.counter;function Cg(e){return e=e-0,e===e}function Hu(e){return Cg(e)?e:(e=e.replace(/[_-]+(.)?/g,(t,n)=>n?n.toUpperCase():""),e.charAt(0).toLowerCase()+e.slice(1))}function Eg(e){return e.charAt(0).toUpperCase()+e.slice(1)}var Yt=new Map,Ig=1e3;function kg(e){if(Yt.has(e))return Yt.get(e);const t={};let n=0;const r=e.length;for(;n<r;){const i=e.indexOf(";",n),s=i===-1?r:i,a=e.slice(n,s).trim();if(a){const o=a.indexOf(":");if(o>0){const u=a.slice(0,o).trim(),d=a.slice(o+1).trim();if(u&&d){const l=Hu(u);t[l.startsWith("webkit")?Eg(l):l]=d}}}n=s+1}if(Yt.size===Ig){const i=Yt.keys().next().value;i&&Yt.delete(i)}return Yt.set(e,t),t}function Yu(e,t,n={}){if(typeof t=="string")return t;const r=(t.children||[]).map(l=>Yu(e,l)),i=t.attributes||{},s={};for(const[l,c]of Object.entries(i))switch(!0){case l==="class":{s.className=c;break}case l==="style":{s.style=kg(String(c));break}case l.startsWith("aria-"):case l.startsWith("data-"):{s[l.toLowerCase()]=c;break}default:s[Hu(l)]=c}const{style:a,role:o,"aria-label":u,...d}=n;return a&&(s.style=s.style?{...s.style,...a}:a),o&&(s.role=o),u&&(s["aria-label"]=u,s["aria-hidden"]="false"),e(t.tag,{...d,...s},...r)}var Mg=Yu.bind(null,z.createElement),Gu=(e,t)=>{const n=z.useId();return e||(t?n:void 0)},Dg=class{constructor(e="react-fontawesome"){this.enabled=!1;let t=!1;try{t=typeof process<"u"&&process.env.NODE_ENV==="development"}catch{}this.scope=e,this.enabled=t}log(...e){this.enabled&&console.log(`[${this.scope}]`,...e)}warn(...e){this.enabled&&console.warn(`[${this.scope}]`,...e)}error(...e){this.enabled&&console.error(`[${this.scope}]`,...e)}};typeof process<"u"&&process.env.FA_VERSION;var jg="searchPseudoElementsFullScan"in bn?"7.0.0":"6.0.0",Fg=Number.parseInt(jg)>=7,xn="fa",tt={beat:"fa-beat",fade:"fa-fade",beatFade:"fa-beat-fade",bounce:"fa-bounce",shake:"fa-shake",spin:"fa-spin",spinPulse:"fa-spin-pulse",spinReverse:"fa-spin-reverse",pulse:"fa-pulse"},Lg={left:"fa-pull-left",right:"fa-pull-right"},Og={90:"fa-rotate-90",180:"fa-rotate-180",270:"fa-rotate-270"},Rg={"2xs":"fa-2xs",xs:"fa-xs",sm:"fa-sm",lg:"fa-lg",xl:"fa-xl","2xl":"fa-2xl","1x":"fa-1x","2x":"fa-2x","3x":"fa-3x","4x":"fa-4x","5x":"fa-5x","6x":"fa-6x","7x":"fa-7x","8x":"fa-8x","9x":"fa-9x","10x":"fa-10x"},nt={border:"fa-border",fixedWidth:"fa-fw",flip:"fa-flip",flipHorizontal:"fa-flip-horizontal",flipVertical:"fa-flip-vertical",inverse:"fa-inverse",rotateBy:"fa-rotate-by",swapOpacity:"fa-swap-opacity",widthAuto:"fa-width-auto"};function _g(e){const t=bn.cssPrefix||bn.familyPrefix||xn;return t===xn?e:e.replace(new RegExp(String.raw`(?<=^|\s)${xn}-`,"g"),`${t}-`)}function Vg(e){const{beat:t,fade:n,beatFade:r,bounce:i,shake:s,spin:a,spinPulse:o,spinReverse:u,pulse:d,fixedWidth:l,inverse:c,border:f,flip:h,size:m,rotation:b,pull:w,swapOpacity:v,rotateBy:I,widthAuto:S,className:E}=e,P=[];return E&&P.push(...E.split(" ")),t&&P.push(tt.beat),n&&P.push(tt.fade),r&&P.push(tt.beatFade),i&&P.push(tt.bounce),s&&P.push(tt.shake),a&&P.push(tt.spin),u&&P.push(tt.spinReverse),o&&P.push(tt.spinPulse),d&&P.push(tt.pulse),l&&P.push(nt.fixedWidth),c&&P.push(nt.inverse),f&&P.push(nt.border),h===!0&&P.push(nt.flip),(h==="horizontal"||h==="both")&&P.push(nt.flipHorizontal),(h==="vertical"||h==="both")&&P.push(nt.flipVertical),m!=null&&P.push(Rg[m]),b!=null&&b!==0&&P.push(Og[b]),w!=null&&P.push(Lg[w]),v&&P.push(nt.swapOpacity),Fg?(I&&P.push(nt.rotateBy),S&&P.push(nt.widthAuto),(bn.cssPrefix||bn.familyPrefix||xn)===xn?P:P.map(_g)):P}var Ng=e=>typeof e=="object"&&"icon"in e&&!!e.icon;function Ku(e){if(e)return Ng(e)?e:Wu.icon(e)}function Ug(e){return Object.keys(e)}var Xu=new Dg("FontAwesomeIcon"),qu={border:!1,className:"",mask:void 0,maskId:void 0,fixedWidth:!1,inverse:!1,flip:!1,icon:void 0,listItem:!1,pull:void 0,pulse:!1,rotation:void 0,rotateBy:!1,size:void 0,spin:!1,spinPulse:!1,spinReverse:!1,beat:!1,fade:!1,beatFade:!1,bounce:!1,shake:!1,symbol:!1,title:"",titleId:void 0,transform:void 0,swapOpacity:!1,widthAuto:!1},Bg=new Set(Object.keys(qu)),Ye=z.forwardRef((e,t)=>{const n={...qu,...e},{icon:r,mask:i,symbol:s,title:a,titleId:o,maskId:u,transform:d}=n,l=Gu(u,!!i),c=Gu(o,!!a),f=Ku(r);if(!f)return Xu.error("Icon lookup is undefined",r),null;const h=Vg(n),m=typeof d=="string"?Wu.transform(d):d,b=Ku(i),w=Pg(f,{...h.length>0&&{classes:h},...m&&{transform:m},...b&&{mask:b},symbol:s,title:a,titleId:c,maskId:l});if(!w)return Xu.error("Could not find icon",f),null;const{abstract:v}=w,I={ref:t};for(const S of Ug(n))Bg.has(S)||(I[S]=n[S]);return Mg(v[0],I)});Ye.displayName="FontAwesomeIcon";const Qu={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",fontSize:"24px",fontWeight:"630"};function zg({headingBlock:e,modifyHeading:t}){return D.jsx("input",{style:{...Qu,borderBottom:"1px solid #232323"},type:"text",placeholder:"Heading...",autoFocus:!0,value:e.data.text,onChange:n=>t({headingBlockId:e.id,newContent:n.target.value,level:1})})}function $g({headingBlock:e}){return D.jsx("h2",{style:Qu,children:e.data.text},e.id)}const Zu={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",fontSize:"20px",fontWeight:"600"};function Wg({subheadingBlock:e,modifySubheading:t}){return D.jsx("input",{style:{...Zu,borderBottom:"1px solid #232323"},type:"text",placeholder:"sub heading ...",autoFocus:!0,value:e.data.text,onChange:n=>t({subheadingBlockId:e.id,newContent:n.target.value})})}function Hg({subheadingBlock:e}){return D.jsx("h2",{style:Zu,children:e.data.text},e.id)}const Ju={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",height:"fit-content"};function Yg({paragraphBlock:e,modifyParagraph:t}){return D.jsx("textarea",{style:{...Ju,borderBottom:"1px solid #232323"},placeholder:"Write something...",autoFocus:!0,value:e.data.text,onChange:n=>t({paragraphBlockId:e.id,newContent:n.target.value})})}function Gg({paragraphBlock:e}){return D.jsx("p",{style:Ju,children:e.data.text},e.id)}const ec={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",fontSize:"14px",listStyleType:"disc"};function Kg({listBlock:e,modifyList:t}){return D.jsx("input",{style:{...ec,borderBottom:"1px solid #232323"},type:"text",placeholder:"separate items using comma",autoFocus:!0,value:e.data.items.join(","),onChange:n=>t({listBlockId:e.id,listStyle:e.data.listStyle,items:n.target.value.split(",").map(r=>r.trim())})})}function Xg({listBlock:e}){return D.jsx("ul",{style:ec,children:e.data.items.map((t,n)=>D.jsx("li",{children:t},n))},e.id)}const tc={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",borderLeft:"4px solid #3b82f6",width:"100%",fontSize:"18px",fontStyle:"italic",paddingLeft:"8px",fontWeight:"400"};function qg({quoteBlock:e,modifyQuote:t}){return D.jsx("input",{style:{...tc,borderBottom:"1px solid #232323"},type:"text",placeholder:"Quote...",autoFocus:!0,value:e.data.text,onChange:n=>t({quoteBlockId:e.id,newContent:n.target.value,author:e.data.author})})}function Qg({quoteBlock:e}){return D.jsx("blockquote",{style:tc,children:e.data.text},e.id)}const nc={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",width:"100%",border:"1px solid #d1d5db",borderCollapse:"collapse",tableLayout:"fixed"};function Zg({tableBlock:e,modifyTable:t}){const{data:n}=e;if(!n?.body?.length)return null;const r={rows:n.body.at(-1)?.id[0]??0,cols:n.body.at(-1)?.id[1]??0};return D.jsxs("table",{style:nc,children:[D.jsx("thead",{children:D.jsx("tr",{children:e.data?.head?.map((i,s)=>D.jsx("th",{style:{border:"1px solid #ccc",padding:"8px",backgroundColor:"#f9f9f9"},children:D.jsx("input",{type:"text",style:{border:"none",borderBottom:"1px solid #3b82f6",outline:"none",width:"100%",background:"transparent"},value:i.content,onChange:a=>{const o=e.data.head.map(d=>d.id===i.id?{...d,content:a.target.value}:d),u={...e.data,head:o};t({tableBlockId:e.id,tableContent:u})}})},s))})}),D.jsx("tbody",{children:Array.from({length:r.rows+1},(i,s)=>D.jsx("tr",{children:Array.from({length:r.cols+1},(a,o)=>D.jsx("td",{style:{border:"1px solid #ccc",padding:"8px"},children:D.jsx("input",{type:"text",style:{border:"none",borderBottom:"1px solid #3b82f6",outline:"none",width:"100%",fontSize:"14px"},placeholder:`Row ${s+1}, Col ${o+1}`,value:n.body.find(u=>u.id[0]===s&&u.id[1]===o)?.content||"",onChange:u=>{const d=n.body.map(c=>c.id[0]===s&&c.id[1]===o?{...c,content:u.target.value}:c),l={...n,body:d};t({tableBlockId:e.id,tableContent:l})}})},`${s}-${o}`))},s))})]})}function Jg({tableBlock:e}){if(!e.data||!e.data.head||!e.data.body)return null;const{head:t,body:n}=e.data,r=t.length,i=n.reduce((s,a,o)=>{const u=Math.floor(o/r);return s[u]||(s[u]=[]),s[u].push(a),s},[]);return D.jsxs("table",{style:nc,children:[D.jsx("thead",{children:D.jsx("tr",{style:{backgroundColor:"#f3f4f6"},children:t.map(s=>D.jsx("th",{style:{border:"1px solid #d1d5db",padding:"10px 12px",textAlign:"left",fontSize:"0.85rem",fontWeight:"bold",color:"#374151"},children:s.content},s.id))})}),D.jsx("tbody",{children:i.map((s,a)=>D.jsx("tr",{children:s.map(o=>D.jsx("td",{style:{border:"1px solid #d1d5db",padding:"10px 12px",color:"#4b5563",fontSize:"0.9rem",verticalAlign:"top"},children:o.content},o.id.join("-")))},a))})]},e.id)}function ey({handleClick:e}){const[t,n]=z.useState(!1),[r,i]=z.useState(0),[s,a]=z.useState(0),[o,u]=z.useState({rows:2,cols:2}),[d,l]=z.useState(!1),c=10,f={position:"absolute",transform:"translateX(-40px) translateY(10px)",backgroundColor:"white",display:"flex",flexDirection:"column",gap:"0.25rem",width:"10rem",height:"12.5rem",border:"1px solid #d1d5db",borderRadius:"0.625rem",cursor:"pointer",padding:"0.5rem",zIndex:"10"},h={width:"40px",textDecoration:"underline",textAlign:"center",border:"1px solid #d1d5db",borderRadius:"5px"},m={flex:"1",border:"1px solid #3b82f6",borderRadius:"5px",lineHeight:"normal",padding:"0 4px",color:"#3b82f6",cursor:"pointer"};z.useEffect(()=>{r<0&&i(0),s<0&&a(0),u({rows:r,cols:s})},[r,s]);const b=()=>{n(!1),e("table",o)};return D.jsxs("div",{style:{position:"relative"},children:[D.jsx(Ye,{icon:["fas","angle-down"],onClick:()=>n(w=>!w)}),t?D.jsxs("div",{style:f,children:[D.jsxs("div",{style:{display:"flex",width:"100%",gap:"0.25rem"},children:[D.jsx("input",{style:h,type:"number",value:r,onChange:w=>i(w.target.value)}),"x",D.jsx("input",{style:h,type:"number",value:s,onChange:w=>a(w.target.value)}),D.jsx("button",{style:{...m,...d?{backgroundColor:"#3b82f6",color:"white"}:{}},onMouseEnter:()=>l(!0),onMouseLeave:()=>l(!1),onClick:b,children:"enter"})]}),[...Array(c)].map((w,v)=>D.jsx("div",{style:{display:"flex",gap:"0.25rem"},children:[...Array(c)].map((I,S)=>D.jsx("div",{style:{flex:"1",height:"0.75rem",border:"1px solid #d1d5db",borderRadius:"2px",backgroundColor:v<=o.rows&&S<=o.cols?"#60a5fa":"#e5e7eb"},onMouseEnter:()=>{i(v),a(S)},onMouseLeave:()=>u({rows:0,cols:0}),onClick:b},`${v}-${S}`))},v))]}):null]})}function ty(e,t){return t.forEach((function(n){n&&typeof n!="string"&&!Array.isArray(n)&&Object.keys(n).forEach((function(r){if(r!=="default"&&!(r in e)){var i=Object.getOwnPropertyDescriptor(n,r);Object.defineProperty(e,r,i.get?i:{enumerable:!0,get:function(){return n[r]}})}}))})),Object.freeze(e)}function rc(e,t){return new Promise((function(n,r){let i;return ny(e).then((function(s){try{return i=s,n(new Blob([t.slice(0,2),i,t.slice(2)],{type:"image/jpeg"}))}catch(a){return r(a)}}),r)}))}const ny=e=>new Promise(((t,n)=>{const r=new FileReader;r.addEventListener("load",(({target:{result:i}})=>{const s=new DataView(i);let a=0;if(s.getUint16(a)!==65496)return n("not a valid JPEG");for(a+=2;;){const o=s.getUint16(a);if(o===65498)break;const u=s.getUint16(a+2);if(o===65505&&s.getUint32(a+4)===1165519206){const d=a+10;let l;switch(s.getUint16(d)){case 18761:l=!0;break;case 19789:l=!1;break;default:return n("TIFF header contains invalid endian")}if(s.getUint16(d+2,l)!==42)return n("TIFF header contains invalid version");const c=s.getUint32(d+4,l),f=d+c+2+12*s.getUint16(d+c,l);for(let h=d+c+2;h<f;h+=12)if(s.getUint16(h,l)==274){if(s.getUint16(h+2,l)!==3)return n("Orientation data type is invalid");if(s.getUint32(h+4,l)!==1)return n("Orientation data count is invalid");s.setUint16(h+8,1,l);break}return t(i.slice(a,a+2+u))}a+=2+u}return t(new Blob)})),r.readAsArrayBuffer(e)}));var ir={},ry={get exports(){return ir},set exports(e){ir=e}};(function(e){var t,n,r={};ry.exports=r,r.parse=function(i,s){for(var a=r.bin.readUshort,o=r.bin.readUint,u=0,d={},l=new Uint8Array(i),c=l.length-4;o(l,c)!=101010256;)c--;u=c,u+=4;var f=a(l,u+=4);a(l,u+=2);var h=o(l,u+=2),m=o(l,u+=4);u+=4,u=m;for(var b=0;b<f;b++){o(l,u),u+=4,u+=4,u+=4,o(l,u+=4),h=o(l,u+=4);var w=o(l,u+=4),v=a(l,u+=4),I=a(l,u+2),S=a(l,u+4);u+=6;var E=o(l,u+=8);u+=4,u+=v+I+S,r._readLocal(l,E,d,h,w,s)}return d},r._readLocal=function(i,s,a,o,u,d){var l=r.bin.readUshort,c=r.bin.readUint;c(i,s),l(i,s+=4),l(i,s+=2);var f=l(i,s+=2);c(i,s+=2),c(i,s+=4),s+=4;var h=l(i,s+=8),m=l(i,s+=2);s+=2;var b=r.bin.readUTF8(i,s,h);if(s+=h,s+=m,d)a[b]={size:u,csize:o};else{var w=new Uint8Array(i.buffer,s);if(f==0)a[b]=new Uint8Array(w.buffer.slice(s,s+o));else{if(f!=8)throw"unknown compression method: "+f;var v=new Uint8Array(u);r.inflateRaw(w,v),a[b]=v}}},r.inflateRaw=function(i,s){return r.F.inflate(i,s)},r.inflate=function(i,s){return i[0],i[1],r.inflateRaw(new Uint8Array(i.buffer,i.byteOffset+2,i.length-6),s)},r.deflate=function(i,s){s==null&&(s={level:6});var a=0,o=new Uint8Array(50+Math.floor(1.1*i.length));o[a]=120,o[a+1]=156,a+=2,a=r.F.deflateRaw(i,o,a,s.level);var u=r.adler(i,0,i.length);return o[a+0]=u>>>24&255,o[a+1]=u>>>16&255,o[a+2]=u>>>8&255,o[a+3]=u>>>0&255,new Uint8Array(o.buffer,0,a+4)},r.deflateRaw=function(i,s){s==null&&(s={level:6});var a=new Uint8Array(50+Math.floor(1.1*i.length)),o=r.F.deflateRaw(i,a,o,s.level);return new Uint8Array(a.buffer,0,o)},r.encode=function(i,s){s==null&&(s=!1);var a=0,o=r.bin.writeUint,u=r.bin.writeUshort,d={};for(var l in i){var c=!r._noNeed(l)&&!s,f=i[l],h=r.crc.crc(f,0,f.length);d[l]={cpr:c,usize:f.length,crc:h,file:c?r.deflateRaw(f):f}}for(var l in d)a+=d[l].file.length+30+46+2*r.bin.sizeUTF8(l);a+=22;var m=new Uint8Array(a),b=0,w=[];for(var l in d){var v=d[l];w.push(b),b=r._writeHeader(m,b,l,v,0)}var I=0,S=b;for(var l in d)v=d[l],w.push(b),b=r._writeHeader(m,b,l,v,1,w[I++]);var E=b-S;return o(m,b,101010256),b+=4,u(m,b+=4,I),u(m,b+=2,I),o(m,b+=2,E),o(m,b+=4,S),b+=4,b+=2,m.buffer},r._noNeed=function(i){var s=i.split(".").pop().toLowerCase();return"png,jpg,jpeg,zip".indexOf(s)!=-1},r._writeHeader=function(i,s,a,o,u,d){var l=r.bin.writeUint,c=r.bin.writeUshort,f=o.file;return l(i,s,u==0?67324752:33639248),s+=4,u==1&&(s+=2),c(i,s,20),c(i,s+=2,0),c(i,s+=2,o.cpr?8:0),l(i,s+=2,0),l(i,s+=4,o.crc),l(i,s+=4,f.length),l(i,s+=4,o.usize),c(i,s+=4,r.bin.sizeUTF8(a)),c(i,s+=2,0),s+=2,u==1&&(s+=2,s+=2,l(i,s+=6,d),s+=4),s+=r.bin.writeUTF8(i,s,a),u==0&&(i.set(f,s),s+=f.length),s},r.crc={table:(function(){for(var i=new Uint32Array(256),s=0;s<256;s++){for(var a=s,o=0;o<8;o++)1&a?a=3988292384^a>>>1:a>>>=1;i[s]=a}return i})(),update:function(i,s,a,o){for(var u=0;u<o;u++)i=r.crc.table[255&(i^s[a+u])]^i>>>8;return i},crc:function(i,s,a){return 4294967295^r.crc.update(4294967295,i,s,a)}},r.adler=function(i,s,a){for(var o=1,u=0,d=s,l=s+a;d<l;){for(var c=Math.min(d+5552,l);d<c;)u+=o+=i[d++];o%=65521,u%=65521}return u<<16|o},r.bin={readUshort:function(i,s){return i[s]|i[s+1]<<8},writeUshort:function(i,s,a){i[s]=255&a,i[s+1]=a>>8&255},readUint:function(i,s){return 16777216*i[s+3]+(i[s+2]<<16|i[s+1]<<8|i[s])},writeUint:function(i,s,a){i[s]=255&a,i[s+1]=a>>8&255,i[s+2]=a>>16&255,i[s+3]=a>>24&255},readASCII:function(i,s,a){for(var o="",u=0;u<a;u++)o+=String.fromCharCode(i[s+u]);return o},writeASCII:function(i,s,a){for(var o=0;o<a.length;o++)i[s+o]=a.charCodeAt(o)},pad:function(i){return i.length<2?"0"+i:i},readUTF8:function(i,s,a){for(var o,u="",d=0;d<a;d++)u+="%"+r.bin.pad(i[s+d].toString(16));try{o=decodeURIComponent(u)}catch{return r.bin.readASCII(i,s,a)}return o},writeUTF8:function(i,s,a){for(var o=a.length,u=0,d=0;d<o;d++){var l=a.charCodeAt(d);if((4294967168&l)==0)i[s+u]=l,u++;else if((4294965248&l)==0)i[s+u]=192|l>>6,i[s+u+1]=128|l>>0&63,u+=2;else if((4294901760&l)==0)i[s+u]=224|l>>12,i[s+u+1]=128|l>>6&63,i[s+u+2]=128|l>>0&63,u+=3;else{if((4292870144&l)!=0)throw"e";i[s+u]=240|l>>18,i[s+u+1]=128|l>>12&63,i[s+u+2]=128|l>>6&63,i[s+u+3]=128|l>>0&63,u+=4}}return u},sizeUTF8:function(i){for(var s=i.length,a=0,o=0;o<s;o++){var u=i.charCodeAt(o);if((4294967168&u)==0)a++;else if((4294965248&u)==0)a+=2;else if((4294901760&u)==0)a+=3;else{if((4292870144&u)!=0)throw"e";a+=4}}return a}},r.F={},r.F.deflateRaw=function(i,s,a,o){var u=[[0,0,0,0,0],[4,4,8,4,0],[4,5,16,8,0],[4,6,16,16,0],[4,10,16,32,0],[8,16,32,32,0],[8,16,128,128,0],[8,32,128,256,0],[32,128,258,1024,1],[32,258,258,4096,1]][o],d=r.F.U,l=r.F._goodIndex;r.F._hash;var c=r.F._putsE,f=0,h=a<<3,m=0,b=i.length;if(o==0){for(;f<b;)c(s,h,f+(k=Math.min(65535,b-f))==b?1:0),h=r.F._copyExact(i,f,k,s,h+8),f+=k;return h>>>3}var w=d.lits,v=d.strt,I=d.prev,S=0,E=0,P=0,A=0,O=0,p=0;for(b>2&&(v[p=r.F._hash(i,0)]=0),f=0;f<b;f++){if(O=p,f+1<b-2){p=r.F._hash(i,f+1);var y=f+1&32767;I[y]=v[p],v[p]=y}if(m<=f){(S>14e3||E>26697)&&b-f>100&&(m<f&&(w[S]=f-m,S+=2,m=f),h=r.F._writeBlock(f==b-1||m==b?1:0,w,S,A,i,P,f-P,s,h),S=E=A=0,P=f);var T=0;f<b-2&&(T=r.F._bestMatch(i,f,I,O,Math.min(u[2],b-f),u[3]));var k=T>>>16,M=65535&T;if(T!=0){M=65535&T;var j=l(k=T>>>16,d.of0);d.lhst[257+j]++;var C=l(M,d.df0);d.dhst[C]++,A+=d.exb[j]+d.dxb[C],w[S]=k<<23|f-m,w[S+1]=M<<16|j<<8|C,S+=2,m=f+k}else d.lhst[i[f]]++;E++}}for(P==f&&i.length!=0||(m<f&&(w[S]=f-m,S+=2,m=f),h=r.F._writeBlock(1,w,S,A,i,P,f-P,s,h),S=0,E=0,S=E=A=0,P=f);(7&h)!=0;)h++;return h>>>3},r.F._bestMatch=function(i,s,a,o,u,d){var l=32767&s,c=a[l],f=l-c+32768&32767;if(c==l||o!=r.F._hash(i,s-f))return 0;for(var h=0,m=0,b=Math.min(32767,s);f<=b&&--d!=0&&c!=l;){if(h==0||i[s+h]==i[s+h-f]){var w=r.F._howLong(i,s,f);if(w>h){if(m=f,(h=w)>=u)break;f+2<w&&(w=f+2);for(var v=0,I=0;I<w-2;I++){var S=s-f+I+32768&32767,E=S-a[S]+32768&32767;E>v&&(v=E,c=S)}}}f+=(l=c)-(c=a[l])+32768&32767}return h<<16|m},r.F._howLong=function(i,s,a){if(i[s]!=i[s-a]||i[s+1]!=i[s+1-a]||i[s+2]!=i[s+2-a])return 0;var o=s,u=Math.min(i.length,s+258);for(s+=3;s<u&&i[s]==i[s-a];)s++;return s-o},r.F._hash=function(i,s){return(i[s]<<8|i[s+1])+(i[s+2]<<4)&65535},r.saved=0,r.F._writeBlock=function(i,s,a,o,u,d,l,c,f){var h,m,b,w,v,I,S,E,P,A=r.F.U,O=r.F._putsF,p=r.F._putsE;A.lhst[256]++,m=(h=r.F.getTrees())[0],b=h[1],w=h[2],v=h[3],I=h[4],S=h[5],E=h[6],P=h[7];var y=32+((f+3&7)==0?0:8-(f+3&7))+(l<<3),T=o+r.F.contSize(A.fltree,A.lhst)+r.F.contSize(A.fdtree,A.dhst),k=o+r.F.contSize(A.ltree,A.lhst)+r.F.contSize(A.dtree,A.dhst);k+=14+3*S+r.F.contSize(A.itree,A.ihst)+(2*A.ihst[16]+3*A.ihst[17]+7*A.ihst[18]);for(var M=0;M<286;M++)A.lhst[M]=0;for(M=0;M<30;M++)A.dhst[M]=0;for(M=0;M<19;M++)A.ihst[M]=0;var j=y<T&&y<k?0:T<k?1:2;if(O(c,f,i),O(c,f+1,j),f+=3,j==0){for(;(7&f)!=0;)f++;f=r.F._copyExact(u,d,l,c,f)}else{var C,R;if(j==1&&(C=A.fltree,R=A.fdtree),j==2){r.F.makeCodes(A.ltree,m),r.F.revCodes(A.ltree,m),r.F.makeCodes(A.dtree,b),r.F.revCodes(A.dtree,b),r.F.makeCodes(A.itree,w),r.F.revCodes(A.itree,w),C=A.ltree,R=A.dtree,p(c,f,v-257),p(c,f+=5,I-1),p(c,f+=5,S-4),f+=4;for(var x=0;x<S;x++)p(c,f+3*x,A.itree[1+(A.ordr[x]<<1)]);f+=3*S,f=r.F._codeTiny(E,A.itree,c,f),f=r.F._codeTiny(P,A.itree,c,f)}for(var g=d,_=0;_<a;_+=2){for(var L=s[_],U=L>>>23,F=g+(8388607&L);g<F;)f=r.F._writeLit(u[g++],C,c,f);if(U!=0){var N=s[_+1],W=N>>16,B=N>>8&255,V=255&N;p(c,f=r.F._writeLit(257+B,C,c,f),U-A.of0[B]),f+=A.exb[B],O(c,f=r.F._writeLit(V,R,c,f),W-A.df0[V]),f+=A.dxb[V],g+=U}}f=r.F._writeLit(256,C,c,f)}return f},r.F._copyExact=function(i,s,a,o,u){var d=u>>>3;return o[d]=a,o[d+1]=a>>>8,o[d+2]=255-o[d],o[d+3]=255-o[d+1],d+=4,o.set(new Uint8Array(i.buffer,s,a),d),u+(a+4<<3)},r.F.getTrees=function(){for(var i=r.F.U,s=r.F._hufTree(i.lhst,i.ltree,15),a=r.F._hufTree(i.dhst,i.dtree,15),o=[],u=r.F._lenCodes(i.ltree,o),d=[],l=r.F._lenCodes(i.dtree,d),c=0;c<o.length;c+=2)i.ihst[o[c]]++;for(c=0;c<d.length;c+=2)i.ihst[d[c]]++;for(var f=r.F._hufTree(i.ihst,i.itree,7),h=19;h>4&&i.itree[1+(i.ordr[h-1]<<1)]==0;)h--;return[s,a,f,u,l,h,o,d]},r.F.getSecond=function(i){for(var s=[],a=0;a<i.length;a+=2)s.push(i[a+1]);return s},r.F.nonZero=function(i){for(var s="",a=0;a<i.length;a+=2)i[a+1]!=0&&(s+=(a>>1)+",");return s},r.F.contSize=function(i,s){for(var a=0,o=0;o<s.length;o++)a+=s[o]*i[1+(o<<1)];return a},r.F._codeTiny=function(i,s,a,o){for(var u=0;u<i.length;u+=2){var d=i[u],l=i[u+1];o=r.F._writeLit(d,s,a,o);var c=d==16?2:d==17?3:7;d>15&&(r.F._putsE(a,o,l,c),o+=c)}return o},r.F._lenCodes=function(i,s){for(var a=i.length;a!=2&&i[a-1]==0;)a-=2;for(var o=0;o<a;o+=2){var u=i[o+1],d=o+3<a?i[o+3]:-1,l=o+5<a?i[o+5]:-1,c=o==0?-1:i[o-1];if(u==0&&d==u&&l==u){for(var f=o+5;f+2<a&&i[f+2]==u;)f+=2;(h=Math.min(f+1-o>>>1,138))<11?s.push(17,h-3):s.push(18,h-11),o+=2*h-2}else if(u==c&&d==u&&l==u){for(f=o+5;f+2<a&&i[f+2]==u;)f+=2;var h=Math.min(f+1-o>>>1,6);s.push(16,h-3),o+=2*h-2}else s.push(u,0)}return a>>>1},r.F._hufTree=function(i,s,a){var o=[],u=i.length,d=s.length,l=0;for(l=0;l<d;l+=2)s[l]=0,s[l+1]=0;for(l=0;l<u;l++)i[l]!=0&&o.push({lit:l,f:i[l]});var c=o.length,f=o.slice(0);if(c==0)return 0;if(c==1){var h=o[0].lit;return f=h==0?1:0,s[1+(h<<1)]=1,s[1+(f<<1)]=1,1}o.sort((function(E,P){return E.f-P.f}));var m=o[0],b=o[1],w=0,v=1,I=2;for(o[0]={lit:-1,f:m.f+b.f,l:m,r:b,d:0};v!=c-1;)m=w!=v&&(I==c||o[w].f<o[I].f)?o[w++]:o[I++],b=w!=v&&(I==c||o[w].f<o[I].f)?o[w++]:o[I++],o[v++]={lit:-1,f:m.f+b.f,l:m,r:b};var S=r.F.setDepth(o[v-1],0);for(S>a&&(r.F.restrictDepth(f,a,S),S=a),l=0;l<c;l++)s[1+(f[l].lit<<1)]=f[l].d;return S},r.F.setDepth=function(i,s){return i.lit!=-1?(i.d=s,s):Math.max(r.F.setDepth(i.l,s+1),r.F.setDepth(i.r,s+1))},r.F.restrictDepth=function(i,s,a){var o=0,u=1<<a-s,d=0;for(i.sort((function(c,f){return f.d==c.d?c.f-f.f:f.d-c.d})),o=0;o<i.length&&i[o].d>s;o++){var l=i[o].d;i[o].d=s,d+=u-(1<<a-l)}for(d>>>=a-s;d>0;)(l=i[o].d)<s?(i[o].d++,d-=1<<s-l-1):o++;for(;o>=0;o--)i[o].d==s&&d<0&&(i[o].d--,d++);d!=0&&console.log("debt left")},r.F._goodIndex=function(i,s){var a=0;return s[16|a]<=i&&(a|=16),s[8|a]<=i&&(a|=8),s[4|a]<=i&&(a|=4),s[2|a]<=i&&(a|=2),s[1|a]<=i&&(a|=1),a},r.F._writeLit=function(i,s,a,o){return r.F._putsF(a,o,s[i<<1]),o+s[1+(i<<1)]},r.F.inflate=function(i,s){var a=Uint8Array;if(i[0]==3&&i[1]==0)return s||new a(0);var o=r.F,u=o._bitsF,d=o._bitsE,l=o._decodeTiny,c=o.makeCodes,f=o.codes2map,h=o._get17,m=o.U,b=s==null;b&&(s=new a(i.length>>>2<<3));for(var w,v,I=0,S=0,E=0,P=0,A=0,O=0,p=0,y=0,T=0;I==0;)if(I=u(i,T,1),S=u(i,T+1,2),T+=3,S!=0){if(b&&(s=r.F._check(s,y+(1<<17))),S==1&&(w=m.flmap,v=m.fdmap,O=511,p=31),S==2){E=d(i,T,5)+257,P=d(i,T+5,5)+1,A=d(i,T+10,4)+4,T+=14;for(var k=0;k<38;k+=2)m.itree[k]=0,m.itree[k+1]=0;var M=1;for(k=0;k<A;k++){var j=d(i,T+3*k,3);m.itree[1+(m.ordr[k]<<1)]=j,j>M&&(M=j)}T+=3*A,c(m.itree,M),f(m.itree,M,m.imap),w=m.lmap,v=m.dmap,T=l(m.imap,(1<<M)-1,E+P,i,T,m.ttree);var C=o._copyOut(m.ttree,0,E,m.ltree);O=(1<<C)-1;var R=o._copyOut(m.ttree,E,P,m.dtree);p=(1<<R)-1,c(m.ltree,C),f(m.ltree,C,w),c(m.dtree,R),f(m.dtree,R,v)}for(;;){var x=w[h(i,T)&O];T+=15&x;var g=x>>>4;if(!(g>>>8))s[y++]=g;else{if(g==256)break;var _=y+g-254;if(g>264){var L=m.ldef[g-257];_=y+(L>>>3)+d(i,T,7&L),T+=7&L}var U=v[h(i,T)&p];T+=15&U;var F=U>>>4,N=m.ddef[F],W=(N>>>4)+u(i,T,15&N);for(T+=15&N,b&&(s=r.F._check(s,y+(1<<17)));y<_;)s[y]=s[y++-W],s[y]=s[y++-W],s[y]=s[y++-W],s[y]=s[y++-W];y=_}}}else{(7&T)!=0&&(T+=8-(7&T));var B=4+(T>>>3),V=i[B-4]|i[B-3]<<8;b&&(s=r.F._check(s,y+V)),s.set(new a(i.buffer,i.byteOffset+B,V),y),T=B+V<<3,y+=V}return s.length==y?s:s.slice(0,y)},r.F._check=function(i,s){var a=i.length;if(s<=a)return i;var o=new Uint8Array(Math.max(a<<1,s));return o.set(i,0),o},r.F._decodeTiny=function(i,s,a,o,u,d){for(var l=r.F._bitsE,c=r.F._get17,f=0;f<a;){var h=i[c(o,u)&s];u+=15&h;var m=h>>>4;if(m<=15)d[f]=m,f++;else{var b=0,w=0;m==16?(w=3+l(o,u,2),u+=2,b=d[f-1]):m==17?(w=3+l(o,u,3),u+=3):m==18&&(w=11+l(o,u,7),u+=7);for(var v=f+w;f<v;)d[f]=b,f++}}return u},r.F._copyOut=function(i,s,a,o){for(var u=0,d=0,l=o.length>>>1;d<a;){var c=i[d+s];o[d<<1]=0,o[1+(d<<1)]=c,c>u&&(u=c),d++}for(;d<l;)o[d<<1]=0,o[1+(d<<1)]=0,d++;return u},r.F.makeCodes=function(i,s){for(var a,o,u,d,l=r.F.U,c=i.length,f=l.bl_count,h=0;h<=s;h++)f[h]=0;for(h=1;h<c;h+=2)f[i[h]]++;var m=l.next_code;for(a=0,f[0]=0,o=1;o<=s;o++)a=a+f[o-1]<<1,m[o]=a;for(u=0;u<c;u+=2)(d=i[u+1])!=0&&(i[u]=m[d],m[d]++)},r.F.codes2map=function(i,s,a){for(var o=i.length,u=r.F.U.rev15,d=0;d<o;d+=2)if(i[d+1]!=0)for(var l=d>>1,c=i[d+1],f=l<<4|c,h=s-c,m=i[d]<<h,b=m+(1<<h);m!=b;)a[u[m]>>>15-s]=f,m++},r.F.revCodes=function(i,s){for(var a=r.F.U.rev15,o=15-s,u=0;u<i.length;u+=2){var d=i[u]<<s-i[u+1];i[u]=a[d]>>>o}},r.F._putsE=function(i,s,a){a<<=7&s;var o=s>>>3;i[o]|=a,i[o+1]|=a>>>8},r.F._putsF=function(i,s,a){a<<=7&s;var o=s>>>3;i[o]|=a,i[o+1]|=a>>>8,i[o+2]|=a>>>16},r.F._bitsE=function(i,s,a){return(i[s>>>3]|i[1+(s>>>3)]<<8)>>>(7&s)&(1<<a)-1},r.F._bitsF=function(i,s,a){return(i[s>>>3]|i[1+(s>>>3)]<<8|i[2+(s>>>3)]<<16)>>>(7&s)&(1<<a)-1},r.F._get17=function(i,s){return(i[s>>>3]|i[1+(s>>>3)]<<8|i[2+(s>>>3)]<<16)>>>(7&s)},r.F._get25=function(i,s){return(i[s>>>3]|i[1+(s>>>3)]<<8|i[2+(s>>>3)]<<16|i[3+(s>>>3)]<<24)>>>(7&s)},r.F.U=(t=Uint16Array,n=Uint32Array,{next_code:new t(16),bl_count:new t(16),ordr:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],of0:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],exb:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],ldef:new t(32),df0:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],dxb:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],ddef:new n(32),flmap:new t(512),fltree:[],fdmap:new t(32),fdtree:[],lmap:new t(32768),ltree:[],ttree:[],dmap:new t(32768),dtree:[],imap:new t(512),itree:[],rev15:new t(32768),lhst:new n(286),dhst:new n(30),ihst:new n(19),lits:new n(15e3),strt:new t(65536),prev:new t(32768)}),(function(){for(var i=r.F.U,s=0;s<32768;s++){var a=s;a=(4278255360&(a=(4042322160&(a=(3435973836&(a=(2863311530&a)>>>1|(1431655765&a)<<1))>>>2|(858993459&a)<<2))>>>4|(252645135&a)<<4))>>>8|(16711935&a)<<8,i.rev15[s]=(a>>>16|a<<16)>>>17}function o(u,d,l){for(;d--!=0;)u.push(0,l)}for(s=0;s<32;s++)i.ldef[s]=i.of0[s]<<3|i.exb[s],i.ddef[s]=i.df0[s]<<4|i.dxb[s];o(i.fltree,144,8),o(i.fltree,112,9),o(i.fltree,24,7),o(i.fltree,8,8),r.F.makeCodes(i.fltree,9),r.F.codes2map(i.fltree,9,i.flmap),r.F.revCodes(i.fltree,9),o(i.fdtree,32,5),r.F.makeCodes(i.fdtree,5),r.F.codes2map(i.fdtree,5,i.fdmap),r.F.revCodes(i.fdtree,5),o(i.itree,19,0),o(i.ltree,286,0),o(i.dtree,30,0),o(i.ttree,320,0)})()})();var iy=ty({__proto__:null,default:ir},[ir]);const ze=(function(){var e={nextZero(l,c){for(;l[c]!=0;)c++;return c},readUshort:(l,c)=>l[c]<<8|l[c+1],writeUshort(l,c,f){l[c]=f>>8&255,l[c+1]=255&f},readUint:(l,c)=>16777216*l[c]+(l[c+1]<<16|l[c+2]<<8|l[c+3]),writeUint(l,c,f){l[c]=f>>24&255,l[c+1]=f>>16&255,l[c+2]=f>>8&255,l[c+3]=255&f},readASCII(l,c,f){let h="";for(let m=0;m<f;m++)h+=String.fromCharCode(l[c+m]);return h},writeASCII(l,c,f){for(let h=0;h<f.length;h++)l[c+h]=f.charCodeAt(h)},readBytes(l,c,f){const h=[];for(let m=0;m<f;m++)h.push(l[c+m]);return h},pad:l=>l.length<2?`0${l}`:l,readUTF8(l,c,f){let h,m="";for(let b=0;b<f;b++)m+=`%${e.pad(l[c+b].toString(16))}`;try{h=decodeURIComponent(m)}catch{return e.readASCII(l,c,f)}return h}};function t(l,c,f,h){const m=c*f,b=s(h),w=Math.ceil(c*b/8),v=new Uint8Array(4*m),I=new Uint32Array(v.buffer),{ctype:S}=h,{depth:E}=h,P=e.readUshort;if(S==6){const L=m<<2;if(E==8)for(var A=0;A<L;A+=4)v[A]=l[A],v[A+1]=l[A+1],v[A+2]=l[A+2],v[A+3]=l[A+3];if(E==16)for(A=0;A<L;A++)v[A]=l[A<<1]}else if(S==2){const L=h.tabs.tRNS;if(L==null){if(E==8)for(A=0;A<m;A++){var O=3*A;I[A]=255<<24|l[O+2]<<16|l[O+1]<<8|l[O]}if(E==16)for(A=0;A<m;A++)O=6*A,I[A]=255<<24|l[O+4]<<16|l[O+2]<<8|l[O]}else{var p=L[0];const U=L[1],F=L[2];if(E==8)for(A=0;A<m;A++){var y=A<<2;O=3*A,I[A]=255<<24|l[O+2]<<16|l[O+1]<<8|l[O],l[O]==p&&l[O+1]==U&&l[O+2]==F&&(v[y+3]=0)}if(E==16)for(A=0;A<m;A++)y=A<<2,O=6*A,I[A]=255<<24|l[O+4]<<16|l[O+2]<<8|l[O],P(l,O)==p&&P(l,O+2)==U&&P(l,O+4)==F&&(v[y+3]=0)}}else if(S==3){const L=h.tabs.PLTE,U=h.tabs.tRNS,F=U?U.length:0;if(E==1)for(var T=0;T<f;T++){var k=T*w,M=T*c;for(A=0;A<c;A++){y=M+A<<2;var j=3*(C=l[k+(A>>3)]>>7-((7&A)<<0)&1);v[y]=L[j],v[y+1]=L[j+1],v[y+2]=L[j+2],v[y+3]=C<F?U[C]:255}}if(E==2)for(T=0;T<f;T++)for(k=T*w,M=T*c,A=0;A<c;A++)y=M+A<<2,j=3*(C=l[k+(A>>2)]>>6-((3&A)<<1)&3),v[y]=L[j],v[y+1]=L[j+1],v[y+2]=L[j+2],v[y+3]=C<F?U[C]:255;if(E==4)for(T=0;T<f;T++)for(k=T*w,M=T*c,A=0;A<c;A++)y=M+A<<2,j=3*(C=l[k+(A>>1)]>>4-((1&A)<<2)&15),v[y]=L[j],v[y+1]=L[j+1],v[y+2]=L[j+2],v[y+3]=C<F?U[C]:255;if(E==8)for(A=0;A<m;A++){var C;y=A<<2,j=3*(C=l[A]),v[y]=L[j],v[y+1]=L[j+1],v[y+2]=L[j+2],v[y+3]=C<F?U[C]:255}}else if(S==4){if(E==8)for(A=0;A<m;A++){y=A<<2;var R=l[x=A<<1];v[y]=R,v[y+1]=R,v[y+2]=R,v[y+3]=l[x+1]}if(E==16)for(A=0;A<m;A++){var x;y=A<<2,R=l[x=A<<2],v[y]=R,v[y+1]=R,v[y+2]=R,v[y+3]=l[x+2]}}else if(S==0)for(p=h.tabs.tRNS?h.tabs.tRNS:-1,T=0;T<f;T++){const L=T*w,U=T*c;if(E==1)for(var g=0;g<c;g++){var _=(R=255*(l[L+(g>>>3)]>>>7-(7&g)&1))==255*p?0:255;I[U+g]=_<<24|R<<16|R<<8|R}else if(E==2)for(g=0;g<c;g++)_=(R=85*(l[L+(g>>>2)]>>>6-((3&g)<<1)&3))==85*p?0:255,I[U+g]=_<<24|R<<16|R<<8|R;else if(E==4)for(g=0;g<c;g++)_=(R=17*(l[L+(g>>>1)]>>>4-((1&g)<<2)&15))==17*p?0:255,I[U+g]=_<<24|R<<16|R<<8|R;else if(E==8)for(g=0;g<c;g++)_=(R=l[L+g])==p?0:255,I[U+g]=_<<24|R<<16|R<<8|R;else if(E==16)for(g=0;g<c;g++)R=l[L+(g<<1)],_=P(l,L+(g<<1))==p?0:255,I[U+g]=_<<24|R<<16|R<<8|R}return v}function n(l,c,f,h){const m=s(l),b=Math.ceil(f*m/8),w=new Uint8Array((b+1+l.interlace)*h);return c=l.tabs.CgBI?i(c,w):r(c,w),l.interlace==0?c=a(c,l,0,f,h):l.interlace==1&&(c=(function(I,S){const E=S.width,P=S.height,A=s(S),O=A>>3,p=Math.ceil(E*A/8),y=new Uint8Array(P*p);let T=0;const k=[0,0,4,0,2,0,1],M=[0,4,0,2,0,1,0],j=[8,8,8,4,4,2,2],C=[8,8,4,4,2,2,1];let R=0;for(;R<7;){const g=j[R],_=C[R];let L=0,U=0,F=k[R];for(;F<P;)F+=g,U++;let N=M[R];for(;N<E;)N+=_,L++;const W=Math.ceil(L*A/8);a(I,S,T,L,U);let B=0,V=k[R];for(;V<P;){let X=M[R],Z=T+B*W<<3;for(;X<E;){var x;if(A==1&&(x=(x=I[Z>>3])>>7-(7&Z)&1,y[V*p+(X>>3)]|=x<<7-((7&X)<<0)),A==2&&(x=(x=I[Z>>3])>>6-(7&Z)&3,y[V*p+(X>>2)]|=x<<6-((3&X)<<1)),A==4&&(x=(x=I[Z>>3])>>4-(7&Z)&15,y[V*p+(X>>1)]|=x<<4-((1&X)<<2)),A>=8){const ee=V*p+X*O;for(let H=0;H<O;H++)y[ee+H]=I[(Z>>3)+H]}Z+=A,X+=_}B++,V+=g}L*U!=0&&(T+=U*(1+W)),R+=1}return y})(c,l)),c}function r(l,c){return i(new Uint8Array(l.buffer,2,l.length-6),c)}var i=(function(){const l={H:{}};return l.H.N=function(c,f){const h=Uint8Array;let m,b,w=0,v=0,I=0,S=0,E=0,P=0,A=0,O=0,p=0;if(c[0]==3&&c[1]==0)return f||new h(0);const y=l.H,T=y.b,k=y.e,M=y.R,j=y.n,C=y.A,R=y.Z,x=y.m,g=f==null;for(g&&(f=new h(c.length>>>2<<5));w==0;)if(w=T(c,p,1),v=T(c,p+1,2),p+=3,v!=0){if(g&&(f=l.H.W(f,O+(1<<17))),v==1&&(m=x.J,b=x.h,P=511,A=31),v==2){I=k(c,p,5)+257,S=k(c,p+5,5)+1,E=k(c,p+10,4)+4,p+=14;let L=1;for(var _=0;_<38;_+=2)x.Q[_]=0,x.Q[_+1]=0;for(_=0;_<E;_++){const N=k(c,p+3*_,3);x.Q[1+(x.X[_]<<1)]=N,N>L&&(L=N)}p+=3*E,j(x.Q,L),C(x.Q,L,x.u),m=x.w,b=x.d,p=M(x.u,(1<<L)-1,I+S,c,p,x.v);const U=y.V(x.v,0,I,x.C);P=(1<<U)-1;const F=y.V(x.v,I,S,x.D);A=(1<<F)-1,j(x.C,U),C(x.C,U,m),j(x.D,F),C(x.D,F,b)}for(;;){const L=m[R(c,p)&P];p+=15&L;const U=L>>>4;if(!(U>>>8))f[O++]=U;else{if(U==256)break;{let F=O+U-254;if(U>264){const X=x.q[U-257];F=O+(X>>>3)+k(c,p,7&X),p+=7&X}const N=b[R(c,p)&A];p+=15&N;const W=N>>>4,B=x.c[W],V=(B>>>4)+T(c,p,15&B);for(p+=15&B;O<F;)f[O]=f[O++-V],f[O]=f[O++-V],f[O]=f[O++-V],f[O]=f[O++-V];O=F}}}}else{(7&p)!=0&&(p+=8-(7&p));const L=4+(p>>>3),U=c[L-4]|c[L-3]<<8;g&&(f=l.H.W(f,O+U)),f.set(new h(c.buffer,c.byteOffset+L,U),O),p=L+U<<3,O+=U}return f.length==O?f:f.slice(0,O)},l.H.W=function(c,f){const h=c.length;if(f<=h)return c;const m=new Uint8Array(h<<1);return m.set(c,0),m},l.H.R=function(c,f,h,m,b,w){const v=l.H.e,I=l.H.Z;let S=0;for(;S<h;){const E=c[I(m,b)&f];b+=15&E;const P=E>>>4;if(P<=15)w[S]=P,S++;else{let A=0,O=0;P==16?(O=3+v(m,b,2),b+=2,A=w[S-1]):P==17?(O=3+v(m,b,3),b+=3):P==18&&(O=11+v(m,b,7),b+=7);const p=S+O;for(;S<p;)w[S]=A,S++}}return b},l.H.V=function(c,f,h,m){let b=0,w=0;const v=m.length>>>1;for(;w<h;){const I=c[w+f];m[w<<1]=0,m[1+(w<<1)]=I,I>b&&(b=I),w++}for(;w<v;)m[w<<1]=0,m[1+(w<<1)]=0,w++;return b},l.H.n=function(c,f){const h=l.H.m,m=c.length;let b,w,v,I;const S=h.j;for(var E=0;E<=f;E++)S[E]=0;for(E=1;E<m;E+=2)S[c[E]]++;const P=h.K;for(b=0,S[0]=0,w=1;w<=f;w++)b=b+S[w-1]<<1,P[w]=b;for(v=0;v<m;v+=2)I=c[v+1],I!=0&&(c[v]=P[I],P[I]++)},l.H.A=function(c,f,h){const m=c.length,b=l.H.m.r;for(let w=0;w<m;w+=2)if(c[w+1]!=0){const v=w>>1,I=c[w+1],S=v<<4|I,E=f-I;let P=c[w]<<E;const A=P+(1<<E);for(;P!=A;)h[b[P]>>>15-f]=S,P++}},l.H.l=function(c,f){const h=l.H.m.r,m=15-f;for(let b=0;b<c.length;b+=2){const w=c[b]<<f-c[b+1];c[b]=h[w]>>>m}},l.H.M=function(c,f,h){h<<=7&f;const m=f>>>3;c[m]|=h,c[m+1]|=h>>>8},l.H.I=function(c,f,h){h<<=7&f;const m=f>>>3;c[m]|=h,c[m+1]|=h>>>8,c[m+2]|=h>>>16},l.H.e=function(c,f,h){return(c[f>>>3]|c[1+(f>>>3)]<<8)>>>(7&f)&(1<<h)-1},l.H.b=function(c,f,h){return(c[f>>>3]|c[1+(f>>>3)]<<8|c[2+(f>>>3)]<<16)>>>(7&f)&(1<<h)-1},l.H.Z=function(c,f){return(c[f>>>3]|c[1+(f>>>3)]<<8|c[2+(f>>>3)]<<16)>>>(7&f)},l.H.i=function(c,f){return(c[f>>>3]|c[1+(f>>>3)]<<8|c[2+(f>>>3)]<<16|c[3+(f>>>3)]<<24)>>>(7&f)},l.H.m=(function(){const c=Uint16Array,f=Uint32Array;return{K:new c(16),j:new c(16),X:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],T:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],q:new c(32),p:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],z:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],c:new f(32),J:new c(512),_:[],h:new c(32),$:[],w:new c(32768),C:[],v:[],d:new c(32768),D:[],u:new c(512),Q:[],r:new c(32768),s:new f(286),Y:new f(30),a:new f(19),t:new f(15e3),k:new c(65536),g:new c(32768)}})(),(function(){const c=l.H.m;for(var f=0;f<32768;f++){let m=f;m=(2863311530&m)>>>1|(1431655765&m)<<1,m=(3435973836&m)>>>2|(858993459&m)<<2,m=(4042322160&m)>>>4|(252645135&m)<<4,m=(4278255360&m)>>>8|(16711935&m)<<8,c.r[f]=(m>>>16|m<<16)>>>17}function h(m,b,w){for(;b--!=0;)m.push(0,w)}for(f=0;f<32;f++)c.q[f]=c.S[f]<<3|c.T[f],c.c[f]=c.p[f]<<4|c.z[f];h(c._,144,8),h(c._,112,9),h(c._,24,7),h(c._,8,8),l.H.n(c._,9),l.H.A(c._,9,c.J),l.H.l(c._,9),h(c.$,32,5),l.H.n(c.$,5),l.H.A(c.$,5,c.h),l.H.l(c.$,5),h(c.Q,19,0),h(c.C,286,0),h(c.D,30,0),h(c.v,320,0)})(),l.H.N})();function s(l){return[1,null,3,1,2,null,4][l.ctype]*l.depth}function a(l,c,f,h,m){let b=s(c);const w=Math.ceil(h*b/8);let v,I;b=Math.ceil(b/8);let S=l[f],E=0;if(S>1&&(l[f]=[0,0,1][S-2]),S==3)for(E=b;E<w;E++)l[E+1]=l[E+1]+(l[E+1-b]>>>1)&255;for(let P=0;P<m;P++)if(v=f+P*w,I=v+P+1,S=l[I-1],E=0,S==0)for(;E<w;E++)l[v+E]=l[I+E];else if(S==1){for(;E<b;E++)l[v+E]=l[I+E];for(;E<w;E++)l[v+E]=l[I+E]+l[v+E-b]}else if(S==2)for(;E<w;E++)l[v+E]=l[I+E]+l[v+E-w];else if(S==3){for(;E<b;E++)l[v+E]=l[I+E]+(l[v+E-w]>>>1);for(;E<w;E++)l[v+E]=l[I+E]+(l[v+E-w]+l[v+E-b]>>>1)}else{for(;E<b;E++)l[v+E]=l[I+E]+o(0,l[v+E-w],0);for(;E<w;E++)l[v+E]=l[I+E]+o(l[v+E-b],l[v+E-w],l[v+E-b-w])}return l}function o(l,c,f){const h=l+c-f,m=h-l,b=h-c,w=h-f;return m*m<=b*b&&m*m<=w*w?l:b*b<=w*w?c:f}function u(l,c,f){f.width=e.readUint(l,c),c+=4,f.height=e.readUint(l,c),c+=4,f.depth=l[c],c++,f.ctype=l[c],c++,f.compress=l[c],c++,f.filter=l[c],c++,f.interlace=l[c],c++}function d(l,c,f,h,m,b,w,v,I){const S=Math.min(c,m),E=Math.min(f,b);let P=0,A=0;for(let R=0;R<E;R++)for(let x=0;x<S;x++)if(w>=0&&v>=0?(P=R*c+x<<2,A=(v+R)*m+w+x<<2):(P=(-v+R)*c-w+x<<2,A=R*m+x<<2),I==0)h[A]=l[P],h[A+1]=l[P+1],h[A+2]=l[P+2],h[A+3]=l[P+3];else if(I==1){var O=l[P+3]*.00392156862745098,p=l[P]*O,y=l[P+1]*O,T=l[P+2]*O,k=h[A+3]*(1/255),M=h[A]*k,j=h[A+1]*k,C=h[A+2]*k;const g=1-O,_=O+k*g,L=_==0?0:1/_;h[A+3]=255*_,h[A+0]=(p+M*g)*L,h[A+1]=(y+j*g)*L,h[A+2]=(T+C*g)*L}else if(I==2)O=l[P+3],p=l[P],y=l[P+1],T=l[P+2],k=h[A+3],M=h[A],j=h[A+1],C=h[A+2],O==k&&p==M&&y==j&&T==C?(h[A]=0,h[A+1]=0,h[A+2]=0,h[A+3]=0):(h[A]=p,h[A+1]=y,h[A+2]=T,h[A+3]=O);else if(I==3){if(O=l[P+3],p=l[P],y=l[P+1],T=l[P+2],k=h[A+3],M=h[A],j=h[A+1],C=h[A+2],O==k&&p==M&&y==j&&T==C)continue;if(O<220&&k>20)return!1}return!0}return{decode:function(c){const f=new Uint8Array(c);let h=8;const m=e,b=m.readUshort,w=m.readUint,v={tabs:{},frames:[]},I=new Uint8Array(f.length);let S,E=0,P=0;const A=[137,80,78,71,13,10,26,10];for(var O=0;O<8;O++)if(f[O]!=A[O])throw"The input is not a PNG file!";for(;h<f.length;){const R=m.readUint(f,h);h+=4;const x=m.readASCII(f,h,4);if(h+=4,x=="IHDR")u(f,h,v);else if(x=="iCCP"){for(var p=h;f[p]!=0;)p++;m.readASCII(f,h,p-h),f[p+1];const g=f.slice(p+2,h+R);let _=null;try{_=r(g)}catch{_=i(g)}v.tabs[x]=_}else if(x=="CgBI")v.tabs[x]=f.slice(h,h+4);else if(x=="IDAT"){for(O=0;O<R;O++)I[E+O]=f[h+O];E+=R}else if(x=="acTL")v.tabs[x]={num_frames:w(f,h),num_plays:w(f,h+4)},S=new Uint8Array(f.length);else if(x=="fcTL"){P!=0&&((C=v.frames[v.frames.length-1]).data=n(v,S.slice(0,P),C.rect.width,C.rect.height),P=0);const g={x:w(f,h+12),y:w(f,h+16),width:w(f,h+4),height:w(f,h+8)};let _=b(f,h+22);_=b(f,h+20)/(_==0?100:_);const L={rect:g,delay:Math.round(1e3*_),dispose:f[h+24],blend:f[h+25]};v.frames.push(L)}else if(x=="fdAT"){for(O=0;O<R-4;O++)S[P+O]=f[h+O+4];P+=R-4}else if(x=="pHYs")v.tabs[x]=[m.readUint(f,h),m.readUint(f,h+4),f[h+8]];else if(x=="cHRM")for(v.tabs[x]=[],O=0;O<8;O++)v.tabs[x].push(m.readUint(f,h+4*O));else if(x=="tEXt"||x=="zTXt"){v.tabs[x]==null&&(v.tabs[x]={});var y=m.nextZero(f,h),T=m.readASCII(f,h,y-h),k=h+R-y-1;if(x=="tEXt")j=m.readASCII(f,y+1,k);else{var M=r(f.slice(y+2,y+2+k));j=m.readUTF8(M,0,M.length)}v.tabs[x][T]=j}else if(x=="iTXt"){v.tabs[x]==null&&(v.tabs[x]={}),y=0,p=h,y=m.nextZero(f,p),T=m.readASCII(f,p,y-p);const g=f[p=y+1];var j;f[p+1],p+=2,y=m.nextZero(f,p),m.readASCII(f,p,y-p),p=y+1,y=m.nextZero(f,p),m.readUTF8(f,p,y-p),k=R-((p=y+1)-h),g==0?j=m.readUTF8(f,p,k):(M=r(f.slice(p,p+k)),j=m.readUTF8(M,0,M.length)),v.tabs[x][T]=j}else if(x=="PLTE")v.tabs[x]=m.readBytes(f,h,R);else if(x=="hIST"){const g=v.tabs.PLTE.length/3;for(v.tabs[x]=[],O=0;O<g;O++)v.tabs[x].push(b(f,h+2*O))}else if(x=="tRNS")v.ctype==3?v.tabs[x]=m.readBytes(f,h,R):v.ctype==0?v.tabs[x]=b(f,h):v.ctype==2&&(v.tabs[x]=[b(f,h),b(f,h+2),b(f,h+4)]);else if(x=="gAMA")v.tabs[x]=m.readUint(f,h)/1e5;else if(x=="sRGB")v.tabs[x]=f[h];else if(x=="bKGD")v.ctype==0||v.ctype==4?v.tabs[x]=[b(f,h)]:v.ctype==2||v.ctype==6?v.tabs[x]=[b(f,h),b(f,h+2),b(f,h+4)]:v.ctype==3&&(v.tabs[x]=f[h]);else if(x=="IEND")break;h+=R,m.readUint(f,h),h+=4}var C;return P!=0&&((C=v.frames[v.frames.length-1]).data=n(v,S.slice(0,P),C.rect.width,C.rect.height)),v.data=n(v,I,v.width,v.height),delete v.compress,delete v.interlace,delete v.filter,v},toRGBA8:function(c){const f=c.width,h=c.height;if(c.tabs.acTL==null)return[t(c.data,f,h,c).buffer];const m=[];c.frames[0].data==null&&(c.frames[0].data=c.data);const b=f*h*4,w=new Uint8Array(b),v=new Uint8Array(b),I=new Uint8Array(b);for(let E=0;E<c.frames.length;E++){const P=c.frames[E],A=P.rect.x,O=P.rect.y,p=P.rect.width,y=P.rect.height,T=t(P.data,p,y,c);if(E!=0)for(var S=0;S<b;S++)I[S]=w[S];if(P.blend==0?d(T,p,y,w,f,h,A,O,0):P.blend==1&&d(T,p,y,w,f,h,A,O,1),m.push(w.buffer.slice(0)),P.dispose!=0){if(P.dispose==1)d(v,p,y,w,f,h,A,O,0);else if(P.dispose==2)for(S=0;S<b;S++)w[S]=I[S]}}return m},_paeth:o,_copyTile:d,_bin:e}})();(function(){const{_copyTile:e}=ze,{_bin:t}=ze,n=ze._paeth;var r={table:(function(){const p=new Uint32Array(256);for(let y=0;y<256;y++){let T=y;for(let k=0;k<8;k++)1&T?T=3988292384^T>>>1:T>>>=1;p[y]=T}return p})(),update(p,y,T,k){for(let M=0;M<k;M++)p=r.table[255&(p^y[T+M])]^p>>>8;return p},crc:(p,y,T)=>4294967295^r.update(4294967295,p,y,T)};function i(p,y,T,k){y[T]+=p[0]*k>>4,y[T+1]+=p[1]*k>>4,y[T+2]+=p[2]*k>>4,y[T+3]+=p[3]*k>>4}function s(p){return Math.max(0,Math.min(255,p))}function a(p,y){const T=p[0]-y[0],k=p[1]-y[1],M=p[2]-y[2],j=p[3]-y[3];return T*T+k*k+M*M+j*j}function o(p,y,T,k,M,j,C){C==null&&(C=1);const R=k.length,x=[];for(var g=0;g<R;g++){const V=k[g];x.push([V>>>0&255,V>>>8&255,V>>>16&255,V>>>24&255])}for(g=0;g<R;g++){let V=4294967295;for(var _=0,L=0;L<R;L++){var U=a(x[g],x[L]);L!=g&&U<V&&(V=U,_=L)}}const F=new Uint32Array(M.buffer),N=new Int16Array(y*T*4),W=[0,8,2,10,12,4,14,6,3,11,1,9,15,7,13,5];for(g=0;g<W.length;g++)W[g]=255*((W[g]+.5)/16-.5);for(let V=0;V<T;V++)for(let X=0;X<y;X++){var B;g=4*(V*y+X),C!=2?B=[s(p[g]+N[g]),s(p[g+1]+N[g+1]),s(p[g+2]+N[g+2]),s(p[g+3]+N[g+3])]:(U=W[4*(3&V)+(3&X)],B=[s(p[g]+U),s(p[g+1]+U),s(p[g+2]+U),s(p[g+3]+U)]),_=0;let Z=16777215;for(L=0;L<R;L++){const G=a(B,x[L]);G<Z&&(Z=G,_=L)}const ee=x[_],H=[B[0]-ee[0],B[1]-ee[1],B[2]-ee[2],B[3]-ee[3]];C==1&&(X!=y-1&&i(H,N,g+4,7),V!=T-1&&(X!=0&&i(H,N,g+4*y-4,3),i(H,N,g+4*y,5),X!=y-1&&i(H,N,g+4*y+4,1))),j[g>>2]=_,F[g>>2]=k[_]}}function u(p,y,T,k,M){M==null&&(M={});const{crc:j}=r,C=t.writeUint,R=t.writeUshort,x=t.writeASCII;let g=8;const _=p.frames.length>1;let L,U=!1,F=33+(_?20:0);if(M.sRGB!=null&&(F+=13),M.pHYs!=null&&(F+=21),M.iCCP!=null&&(L=pako.deflate(M.iCCP),F+=21+L.length+4),p.ctype==3){for(var N=p.plte.length,W=0;W<N;W++)p.plte[W]>>>24!=255&&(U=!0);F+=8+3*N+4+(U?8+1*N+4:0)}for(var B=0;B<p.frames.length;B++)_&&(F+=38),F+=(ee=p.frames[B]).cimg.length+12,B!=0&&(F+=4);F+=12;const V=new Uint8Array(F),X=[137,80,78,71,13,10,26,10];for(W=0;W<8;W++)V[W]=X[W];if(C(V,g,13),g+=4,x(V,g,"IHDR"),g+=4,C(V,g,y),g+=4,C(V,g,T),g+=4,V[g]=p.depth,g++,V[g]=p.ctype,g++,V[g]=0,g++,V[g]=0,g++,V[g]=0,g++,C(V,g,j(V,g-17,17)),g+=4,M.sRGB!=null&&(C(V,g,1),g+=4,x(V,g,"sRGB"),g+=4,V[g]=M.sRGB,g++,C(V,g,j(V,g-5,5)),g+=4),M.iCCP!=null){const H=13+L.length;C(V,g,H),g+=4,x(V,g,"iCCP"),g+=4,x(V,g,"ICC profile"),g+=11,g+=2,V.set(L,g),g+=L.length,C(V,g,j(V,g-(H+4),H+4)),g+=4}if(M.pHYs!=null&&(C(V,g,9),g+=4,x(V,g,"pHYs"),g+=4,C(V,g,M.pHYs[0]),g+=4,C(V,g,M.pHYs[1]),g+=4,V[g]=M.pHYs[2],g++,C(V,g,j(V,g-13,13)),g+=4),_&&(C(V,g,8),g+=4,x(V,g,"acTL"),g+=4,C(V,g,p.frames.length),g+=4,C(V,g,M.loop!=null?M.loop:0),g+=4,C(V,g,j(V,g-12,12)),g+=4),p.ctype==3){for(C(V,g,3*(N=p.plte.length)),g+=4,x(V,g,"PLTE"),g+=4,W=0;W<N;W++){const H=3*W,G=p.plte[W],Y=255&G,q=G>>>8&255,Te=G>>>16&255;V[g+H+0]=Y,V[g+H+1]=q,V[g+H+2]=Te}if(g+=3*N,C(V,g,j(V,g-3*N-4,3*N+4)),g+=4,U){for(C(V,g,N),g+=4,x(V,g,"tRNS"),g+=4,W=0;W<N;W++)V[g+W]=p.plte[W]>>>24&255;g+=N,C(V,g,j(V,g-N-4,N+4)),g+=4}}let Z=0;for(B=0;B<p.frames.length;B++){var ee=p.frames[B];_&&(C(V,g,26),g+=4,x(V,g,"fcTL"),g+=4,C(V,g,Z++),g+=4,C(V,g,ee.rect.width),g+=4,C(V,g,ee.rect.height),g+=4,C(V,g,ee.rect.x),g+=4,C(V,g,ee.rect.y),g+=4,R(V,g,k[B]),g+=2,R(V,g,1e3),g+=2,V[g]=ee.dispose,g++,V[g]=ee.blend,g++,C(V,g,j(V,g-30,30)),g+=4);const H=ee.cimg;C(V,g,(N=H.length)+(B==0?0:4)),g+=4;const G=g;x(V,g,B==0?"IDAT":"fdAT"),g+=4,B!=0&&(C(V,g,Z++),g+=4),V.set(H,g),g+=N,C(V,g,j(V,G,g-G)),g+=4}return C(V,g,0),g+=4,x(V,g,"IEND"),g+=4,C(V,g,j(V,g-4,4)),g+=4,V.buffer}function d(p,y,T){for(let k=0;k<p.frames.length;k++){const M=p.frames[k];M.rect.width;const j=M.rect.height,C=new Uint8Array(j*M.bpl+j);M.cimg=h(M.img,j,M.bpp,M.bpl,C,y,T)}}function l(p,y,T,k,M){const j=M[0],C=M[1],R=M[2],x=M[3],g=M[4],_=M[5];let L=6,U=8,F=255;for(var N=0;N<p.length;N++){const ne=new Uint8Array(p[N]);for(var W=ne.length,B=0;B<W;B+=4)F&=ne[B+3]}const V=F!=255,X=(function(le,se,ve,Pe,de,Me){const he=[];for(var ae=0;ae<le.length;ae++){const Ce=new Uint8Array(le[ae]),$e=new Uint32Array(Ce.buffer);var De;let Re=0,rt=0,Ke=se,Pt=ve,ds=Pe?1:0;if(ae!=0){const By=Me||Pe||ae==1||he[ae-2].dispose!=0?1:2;let hs=0,Ic=1e9;for(let An=0;An<By;An++){var ft=new Uint8Array(le[ae-1-An]);const zy=new Uint32Array(le[ae-1-An]);let dt=se,ht=ve,Kt=-1,Sn=-1;for(let Ct=0;Ct<ve;Ct++)for(let Et=0;Et<se;Et++)$e[we=Ct*se+Et]!=zy[we]&&(Et<dt&&(dt=Et),Et>Kt&&(Kt=Et),Ct<ht&&(ht=Ct),Ct>Sn&&(Sn=Ct));Kt==-1&&(dt=ht=Kt=Sn=0),de&&((1&dt)==1&&dt--,(1&ht)==1&&ht--);const kc=(Kt-dt+1)*(Sn-ht+1);kc<Ic&&(Ic=kc,hs=An,Re=dt,rt=ht,Ke=Kt-dt+1,Pt=Sn-ht+1)}ft=new Uint8Array(le[ae-1-hs]),hs==1&&(he[ae-1].dispose=2),De=new Uint8Array(Ke*Pt*4),e(ft,se,ve,De,Ke,Pt,-Re,-rt,0),ds=e(Ce,se,ve,De,Ke,Pt,-Re,-rt,3)?1:0,ds==1?f(Ce,se,ve,De,{x:Re,y:rt,width:Ke,height:Pt}):e(Ce,se,ve,De,Ke,Pt,-Re,-rt,0)}else De=Ce.slice(0);he.push({rect:{x:Re,y:rt,width:Ke,height:Pt},img:De,blend:ds,dispose:0})}if(Pe)for(ae=0;ae<he.length;ae++){if((Tt=he[ae]).blend==1)continue;const Ce=Tt.rect,$e=he[ae-1].rect,Re=Math.min(Ce.x,$e.x),rt=Math.min(Ce.y,$e.y),Ke={x:Re,y:rt,width:Math.max(Ce.x+Ce.width,$e.x+$e.width)-Re,height:Math.max(Ce.y+Ce.height,$e.y+$e.height)-rt};he[ae-1].dispose=1,ae-1!=0&&c(le,se,ve,he,ae-1,Ke,de),c(le,se,ve,he,ae,Ke,de)}let cr=0;if(le.length!=1)for(var we=0;we<he.length;we++){var Tt;cr+=(Tt=he[we]).rect.width*Tt.rect.height}return he})(p,y,T,j,C,R),Z={},ee=[],H=[];if(k!=0){const ne=[];for(B=0;B<X.length;B++)ne.push(X[B].img.buffer);const le=(function(de){let Me=0;for(var he=0;he<de.length;he++)Me+=de[he].byteLength;const ae=new Uint8Array(Me);let De=0;for(he=0;he<de.length;he++){const ft=new Uint8Array(de[he]),cr=ft.length;for(let we=0;we<cr;we+=4){let Tt=ft[we],Ce=ft[we+1],$e=ft[we+2];const Re=ft[we+3];Re==0&&(Tt=Ce=$e=0),ae[De+we]=Tt,ae[De+we+1]=Ce,ae[De+we+2]=$e,ae[De+we+3]=Re}De+=cr}return ae.buffer})(ne),se=b(le,k);for(B=0;B<se.plte.length;B++)ee.push(se.plte[B].est.rgba);let ve=0;for(B=0;B<X.length;B++){const Pe=(Y=X[B]).img.length;var G=new Uint8Array(se.inds.buffer,ve>>2,Pe>>2);H.push(G);const de=new Uint8Array(se.abuf,ve,Pe);_&&o(Y.img,Y.rect.width,Y.rect.height,ee,de,G),Y.img.set(de),ve+=Pe}}else for(N=0;N<X.length;N++){var Y=X[N];const ne=new Uint32Array(Y.img.buffer);var q=Y.rect.width;for(W=ne.length,G=new Uint8Array(W),H.push(G),B=0;B<W;B++){const le=ne[B];if(B!=0&&le==ne[B-1])G[B]=G[B-1];else if(B>q&&le==ne[B-q])G[B]=G[B-q];else{let se=Z[le];if(se==null&&(Z[le]=se=ee.length,ee.push(le),ee.length>=300))break;G[B]=se}}}const Te=ee.length;for(Te<=256&&g==0&&(U=Te<=2?1:Te<=4?2:Te<=16?4:8,U=Math.max(U,x)),N=0;N<X.length;N++){(Y=X[N]).rect.x,Y.rect.y,q=Y.rect.width;const ne=Y.rect.height;let le=Y.img;new Uint32Array(le.buffer);let se=4*q,ve=4;if(Te<=256&&g==0){se=Math.ceil(U*q/8);var pe=new Uint8Array(se*ne);const Pe=H[N];for(let de=0;de<ne;de++){B=de*se;const Me=de*q;if(U==8)for(var ie=0;ie<q;ie++)pe[B+ie]=Pe[Me+ie];else if(U==4)for(ie=0;ie<q;ie++)pe[B+(ie>>1)]|=Pe[Me+ie]<<4-4*(1&ie);else if(U==2)for(ie=0;ie<q;ie++)pe[B+(ie>>2)]|=Pe[Me+ie]<<6-2*(3&ie);else if(U==1)for(ie=0;ie<q;ie++)pe[B+(ie>>3)]|=Pe[Me+ie]<<7-1*(7&ie)}le=pe,L=3,ve=1}else if(V==0&&X.length==1){pe=new Uint8Array(q*ne*3);const Pe=q*ne;for(B=0;B<Pe;B++){const de=3*B,Me=4*B;pe[de]=le[Me],pe[de+1]=le[Me+1],pe[de+2]=le[Me+2]}le=pe,L=2,ve=3,se=3*q}Y.img=le,Y.bpl=se,Y.bpp=ve}return{ctype:L,depth:U,plte:ee,frames:X}}function c(p,y,T,k,M,j,C){const R=Uint8Array,x=Uint32Array,g=new R(p[M-1]),_=new x(p[M-1]),L=M+1<p.length?new R(p[M+1]):null,U=new R(p[M]),F=new x(U.buffer);let N=y,W=T,B=-1,V=-1;for(let Z=0;Z<j.height;Z++)for(let ee=0;ee<j.width;ee++){const H=j.x+ee,G=j.y+Z,Y=G*y+H,q=F[Y];q==0||k[M-1].dispose==0&&_[Y]==q&&(L==null||L[4*Y+3]!=0)||(H<N&&(N=H),H>B&&(B=H),G<W&&(W=G),G>V&&(V=G))}B==-1&&(N=W=B=V=0),C&&((1&N)==1&&N--,(1&W)==1&&W--),j={x:N,y:W,width:B-N+1,height:V-W+1};const X=k[M];X.rect=j,X.blend=1,X.img=new Uint8Array(j.width*j.height*4),k[M-1].dispose==0?(e(g,y,T,X.img,j.width,j.height,-j.x,-j.y,0),f(U,y,T,X.img,j)):e(U,y,T,X.img,j.width,j.height,-j.x,-j.y,0)}function f(p,y,T,k,M){e(p,y,T,k,M.width,M.height,-M.x,-M.y,2)}function h(p,y,T,k,M,j,C){const R=[];let x,g=[0,1,2,3,4];j!=-1?g=[j]:(y*k>5e5||T==1)&&(g=[0]),C&&(x={level:0});const _=iy;for(var L=0;L<g.length;L++){for(let N=0;N<y;N++)m(M,p,N,k,T,g[L]);R.push(_.deflate(M,x))}let U,F=1e9;for(L=0;L<R.length;L++)R[L].length<F&&(U=L,F=R[L].length);return R[U]}function m(p,y,T,k,M,j){const C=T*k;let R=C+T;if(p[R]=j,R++,j==0)if(k<500)for(var x=0;x<k;x++)p[R+x]=y[C+x];else p.set(new Uint8Array(y.buffer,C,k),R);else if(j==1){for(x=0;x<M;x++)p[R+x]=y[C+x];for(x=M;x<k;x++)p[R+x]=y[C+x]-y[C+x-M]+256&255}else if(T==0){for(x=0;x<M;x++)p[R+x]=y[C+x];if(j==2)for(x=M;x<k;x++)p[R+x]=y[C+x];if(j==3)for(x=M;x<k;x++)p[R+x]=y[C+x]-(y[C+x-M]>>1)+256&255;if(j==4)for(x=M;x<k;x++)p[R+x]=y[C+x]-n(y[C+x-M],0,0)+256&255}else{if(j==2)for(x=0;x<k;x++)p[R+x]=y[C+x]+256-y[C+x-k]&255;if(j==3){for(x=0;x<M;x++)p[R+x]=y[C+x]+256-(y[C+x-k]>>1)&255;for(x=M;x<k;x++)p[R+x]=y[C+x]+256-(y[C+x-k]+y[C+x-M]>>1)&255}if(j==4){for(x=0;x<M;x++)p[R+x]=y[C+x]+256-n(0,y[C+x-k],0)&255;for(x=M;x<k;x++)p[R+x]=y[C+x]+256-n(y[C+x-M],y[C+x-k],y[C+x-M-k])&255}}}function b(p,y){const T=new Uint8Array(p),k=T.slice(0),M=new Uint32Array(k.buffer),j=w(k,y),C=j[0],R=j[1],x=T.length,g=new Uint8Array(x>>2);let _;if(T.length<2e7)for(var L=0;L<x;L+=4)_=v(C,U=T[L]*(1/255),F=T[L+1]*(1/255),N=T[L+2]*(1/255),W=T[L+3]*(1/255)),g[L>>2]=_.ind,M[L>>2]=_.est.rgba;else for(L=0;L<x;L+=4){var U=T[L]*.00392156862745098,F=T[L+1]*(1/255),N=T[L+2]*(1/255),W=T[L+3]*(1/255);for(_=C;_.left;)_=I(_.est,U,F,N,W)<=0?_.left:_.right;g[L>>2]=_.ind,M[L>>2]=_.est.rgba}return{abuf:k.buffer,inds:g,plte:R}}function w(p,y,T){T==null&&(T=1e-4);const k=new Uint32Array(p.buffer),M={i0:0,i1:p.length,bst:null,est:null,tdst:0,left:null,right:null};M.bst=P(p,M.i0,M.i1),M.est=A(M.bst);const j=[M];for(;j.length<y;){let R=0,x=0;for(var C=0;C<j.length;C++)j[C].est.L>R&&(R=j[C].est.L,x=C);if(R<T)break;const g=j[x],_=S(p,k,g.i0,g.i1,g.est.e,g.est.eMq255);if(g.i0>=_||g.i1<=_){g.est.L=0;continue}const L={i0:g.i0,i1:_,bst:null,est:null,tdst:0,left:null,right:null};L.bst=P(p,L.i0,L.i1),L.est=A(L.bst);const U={i0:_,i1:g.i1,bst:null,est:null,tdst:0,left:null,right:null};for(U.bst={R:[],m:[],N:g.bst.N-L.bst.N},C=0;C<16;C++)U.bst.R[C]=g.bst.R[C]-L.bst.R[C];for(C=0;C<4;C++)U.bst.m[C]=g.bst.m[C]-L.bst.m[C];U.est=A(U.bst),g.left=L,g.right=U,j[x]=L,j.push(U)}for(j.sort(((R,x)=>x.bst.N-R.bst.N)),C=0;C<j.length;C++)j[C].ind=C;return[M,j]}function v(p,y,T,k,M){if(p.left==null)return p.tdst=(function(L,U,F,N,W){const B=U-L[0],V=F-L[1],X=N-L[2],Z=W-L[3];return B*B+V*V+X*X+Z*Z})(p.est.q,y,T,k,M),p;const j=I(p.est,y,T,k,M);let C=p.left,R=p.right;j>0&&(C=p.right,R=p.left);const x=v(C,y,T,k,M);if(x.tdst<=j*j)return x;const g=v(R,y,T,k,M);return g.tdst<x.tdst?g:x}function I(p,y,T,k,M){const{e:j}=p;return j[0]*y+j[1]*T+j[2]*k+j[3]*M-p.eMq}function S(p,y,T,k,M,j){for(k-=4;T<k;){for(;E(p,T,M)<=j;)T+=4;for(;E(p,k,M)>j;)k-=4;if(T>=k)break;const C=y[T>>2];y[T>>2]=y[k>>2],y[k>>2]=C,T+=4,k-=4}for(;E(p,T,M)>j;)T-=4;return T+4}function E(p,y,T){return p[y]*T[0]+p[y+1]*T[1]+p[y+2]*T[2]+p[y+3]*T[3]}function P(p,y,T){const k=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],M=[0,0,0,0],j=T-y>>2;for(let C=y;C<T;C+=4){const R=p[C]*.00392156862745098,x=p[C+1]*(1/255),g=p[C+2]*(1/255),_=p[C+3]*(1/255);M[0]+=R,M[1]+=x,M[2]+=g,M[3]+=_,k[0]+=R*R,k[1]+=R*x,k[2]+=R*g,k[3]+=R*_,k[5]+=x*x,k[6]+=x*g,k[7]+=x*_,k[10]+=g*g,k[11]+=g*_,k[15]+=_*_}return k[4]=k[1],k[8]=k[2],k[9]=k[6],k[12]=k[3],k[13]=k[7],k[14]=k[11],{R:k,m:M,N:j}}function A(p){const{R:y}=p,{m:T}=p,{N:k}=p,M=T[0],j=T[1],C=T[2],R=T[3],x=k==0?0:1/k,g=[y[0]-M*M*x,y[1]-M*j*x,y[2]-M*C*x,y[3]-M*R*x,y[4]-j*M*x,y[5]-j*j*x,y[6]-j*C*x,y[7]-j*R*x,y[8]-C*M*x,y[9]-C*j*x,y[10]-C*C*x,y[11]-C*R*x,y[12]-R*M*x,y[13]-R*j*x,y[14]-R*C*x,y[15]-R*R*x],_=g,L=O;let U=[Math.random(),Math.random(),Math.random(),Math.random()],F=0,N=0;if(k!=0)for(let B=0;B<16&&(U=L.multVec(_,U),N=Math.sqrt(L.dot(U,U)),U=L.sml(1/N,U),!(B!=0&&Math.abs(N-F)<1e-9));B++)F=N;const W=[M*x,j*x,C*x,R*x];return{Cov:g,q:W,e:U,L:F,eMq255:L.dot(L.sml(255,W),U),eMq:L.dot(U,W),rgba:(Math.round(255*W[3])<<24|Math.round(255*W[2])<<16|Math.round(255*W[1])<<8|Math.round(255*W[0])<<0)>>>0}}var O={multVec:(p,y)=>[p[0]*y[0]+p[1]*y[1]+p[2]*y[2]+p[3]*y[3],p[4]*y[0]+p[5]*y[1]+p[6]*y[2]+p[7]*y[3],p[8]*y[0]+p[9]*y[1]+p[10]*y[2]+p[11]*y[3],p[12]*y[0]+p[13]*y[1]+p[14]*y[2]+p[15]*y[3]],dot:(p,y)=>p[0]*y[0]+p[1]*y[1]+p[2]*y[2]+p[3]*y[3],sml:(p,y)=>[p*y[0],p*y[1],p*y[2],p*y[3]]};ze.encode=function(y,T,k,M,j,C,R){M==null&&(M=0),R==null&&(R=!1);const x=l(y,T,k,M,[!1,!1,!1,0,R,!1]);return d(x,-1),u(x,T,k,j,C)},ze.encodeLL=function(y,T,k,M,j,C,R,x){const g={ctype:0+(M==1?0:2)+(j==0?0:4),depth:C,frames:[]},_=(M+j)*C,L=_*T;for(let U=0;U<y.length;U++)g.frames.push({rect:{x:0,y:0,width:T,height:k},img:new Uint8Array(y[U]),blend:0,dispose:1,bpp:Math.ceil(_/8),bpl:Math.ceil(L/8)});return d(g,0,!0),u(g,T,k,R,x)},ze.encode.compress=l,ze.encode.dither=o,ze.quantize=b,ze.quantize.getKDtree=w,ze.quantize.getNearest=v})();const ic={toArrayBuffer(e,t){const n=e.width,r=e.height,i=n<<2,s=e.getContext("2d").getImageData(0,0,n,r),a=new Uint32Array(s.data.buffer),o=(32*n+31)/32<<2,u=o*r,d=122+u,l=new ArrayBuffer(d),c=new DataView(l),f=1<<20;let h,m,b,w,v=f,I=0,S=0,E=0;function P(p){c.setUint16(S,p,!0),S+=2}function A(p){c.setUint32(S,p,!0),S+=4}function O(p){S+=p}P(19778),A(d),O(4),A(122),A(108),A(n),A(-r>>>0),P(1),P(32),A(3),A(u),A(2835),A(2835),O(8),A(16711680),A(65280),A(255),A(4278190080),A(1466527264),(function p(){for(;I<r&&v>0;){for(w=122+I*o,h=0;h<i;)v--,m=a[E++],b=m>>>24,c.setUint32(w+h,m<<8|b),h+=4;I++}E<a.length?(v=f,setTimeout(p,ic._dly)):t(l)})()},toBlob(e,t){this.toArrayBuffer(e,(n=>{t(new Blob([n],{type:"image/bmp"}))}))},_dly:9};var Ie={CHROME:"CHROME",FIREFOX:"FIREFOX",DESKTOP_SAFARI:"DESKTOP_SAFARI",IE:"IE",IOS:"IOS",ETC:"ETC"},sy={[Ie.CHROME]:16384,[Ie.FIREFOX]:11180,[Ie.DESKTOP_SAFARI]:16384,[Ie.IE]:8192,[Ie.IOS]:4096,[Ie.ETC]:8192};const ls=typeof window<"u",sc=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,sr=ls&&window.cordova&&window.cordova.require&&window.cordova.require("cordova/modulemapper"),ay=(ls||sc)&&(sr&&sr.getOriginalSymbol(window,"File")||typeof File<"u"&&File),ac=(ls||sc)&&(sr&&sr.getOriginalSymbol(window,"FileReader")||typeof FileReader<"u"&&FileReader);function us(e,t,n=Date.now()){return new Promise((r=>{const i=e.split(","),s=i[0].match(/:(.*?);/)[1],a=globalThis.atob(i[1]);let o=a.length;const u=new Uint8Array(o);for(;o--;)u[o]=a.charCodeAt(o);const d=new Blob([u],{type:s});d.name=t,d.lastModified=n,r(d)}))}function oc(e){return new Promise(((t,n)=>{const r=new ac;r.onload=()=>t(r.result),r.onerror=i=>n(i),r.readAsDataURL(e)}))}function lc(e){return new Promise(((t,n)=>{const r=new Image;r.onload=()=>t(r),r.onerror=i=>n(i),r.src=e}))}function St(){if(St.cachedResult!==void 0)return St.cachedResult;let e=Ie.ETC;const{userAgent:t}=navigator;return/Chrom(e|ium)/i.test(t)?e=Ie.CHROME:/iP(ad|od|hone)/i.test(t)&&/WebKit/i.test(t)?e=Ie.IOS:/Safari/i.test(t)?e=Ie.DESKTOP_SAFARI:/Firefox/i.test(t)?e=Ie.FIREFOX:(/MSIE/i.test(t)||document.documentMode)&&(e=Ie.IE),St.cachedResult=e,St.cachedResult}function uc(e,t){const n=St(),r=sy[n];let i=e,s=t,a=i*s;const o=i>s?s/i:i/s;for(;a>r*r;){const u=(r+i)/2,d=(r+s)/2;u<d?(s=d,i=d*o):(s=u*o,i=u),a=i*s}return{width:i,height:s}}function ar(e,t){let n,r;try{if(n=new OffscreenCanvas(e,t),r=n.getContext("2d"),r===null)throw new Error("getContext of OffscreenCanvas returns null")}catch{n=document.createElement("canvas"),r=n.getContext("2d")}return n.width=e,n.height=t,[n,r]}function cc(e,t){const{width:n,height:r}=uc(e.width,e.height),[i,s]=ar(n,r);return t&&/jpe?g/.test(t)&&(s.fillStyle="white",s.fillRect(0,0,i.width,i.height)),s.drawImage(e,0,0,i.width,i.height),i}function or(){return or.cachedResult!==void 0||(or.cachedResult=["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&typeof document<"u"&&"ontouchend"in document),or.cachedResult}function lr(e,t={}){return new Promise((function(n,r){let i,s;var a=function(){try{return s=cc(i,t.fileType||e.type),n([i,s])}catch(u){return r(u)}},o=function(u){try{var d=function(l){try{throw l}catch(c){return r(c)}};try{let l;return oc(e).then((function(c){try{return l=c,lc(l).then((function(f){try{return i=f,(function(){try{return a()}catch(h){return r(h)}})()}catch(h){return d(h)}}),d)}catch(f){return d(f)}}),d)}catch(l){d(l)}}catch(l){return r(l)}};try{if(or()||[Ie.DESKTOP_SAFARI,Ie.MOBILE_SAFARI].includes(St()))throw new Error("Skip createImageBitmap on IOS and Safari");return createImageBitmap(e).then((function(u){try{return i=u,a()}catch{return o()}}),o)}catch{o()}}))}function ur(e,t,n,r,i=1){return new Promise((function(s,a){let o;if(t==="image/png"){let d,l,c;return d=e.getContext("2d"),{data:l}=d.getImageData(0,0,e.width,e.height),c=ze.encode([l.buffer],e.width,e.height,4096*i),o=new Blob([c],{type:t}),o.name=n,o.lastModified=r,u.call(this)}{let d=function(){return u.call(this)};if(t==="image/bmp")return new Promise((l=>ic.toBlob(e,l))).then((function(l){try{return o=l,o.name=n,o.lastModified=r,d.call(this)}catch(c){return a(c)}}).bind(this),a);{let l=function(){return d.call(this)};if(typeof OffscreenCanvas=="function"&&e instanceof OffscreenCanvas)return e.convertToBlob({type:t,quality:i}).then((function(c){try{return o=c,o.name=n,o.lastModified=r,l.call(this)}catch(f){return a(f)}}).bind(this),a);{let c;return c=e.toDataURL(t,i),us(c,n,r).then((function(f){try{return o=f,l.call(this)}catch(h){return a(h)}}).bind(this),a)}}}function u(){return s(o)}}))}function Ge(e){e.width=0,e.height=0}function Gt(){return new Promise((function(e,t){let n,r,i,s;return Gt.cachedResult!==void 0?e(Gt.cachedResult):us("data:image/jpeg;base64,/9j/4QAiRXhpZgAATU0AKgAAAAgAAQESAAMAAAABAAYAAAAAAAD/2wCEAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAf/AABEIAAEAAgMBEQACEQEDEQH/xABKAAEAAAAAAAAAAAAAAAAAAAALEAEAAAAAAAAAAAAAAAAAAAAAAQEAAAAAAAAAAAAAAAAAAAAAEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwA/8H//2Q==","test.jpg",Date.now()).then((function(a){try{return n=a,lr(n).then((function(o){try{return r=o[1],ur(r,n.type,n.name,n.lastModified).then((function(u){try{return i=u,Ge(r),lr(i).then((function(d){try{return s=d[0],Gt.cachedResult=s.width===1&&s.height===2,e(Gt.cachedResult)}catch(l){return t(l)}}),t)}catch(d){return t(d)}}),t)}catch(u){return t(u)}}),t)}catch(o){return t(o)}}),t)}))}function fc(e){return new Promise(((t,n)=>{const r=new ac;r.onload=i=>{const s=new DataView(i.target.result);if(s.getUint16(0,!1)!=65496)return t(-2);const a=s.byteLength;let o=2;for(;o<a;){if(s.getUint16(o+2,!1)<=8)return t(-1);const u=s.getUint16(o,!1);if(o+=2,u==65505){if(s.getUint32(o+=2,!1)!=1165519206)return t(-1);const d=s.getUint16(o+=6,!1)==18761;o+=s.getUint32(o+4,d);const l=s.getUint16(o,d);o+=2;for(let c=0;c<l;c++)if(s.getUint16(o+12*c,d)==274)return t(s.getUint16(o+12*c+8,d))}else{if((65280&u)!=65280)break;o+=s.getUint16(o,!1)}}return t(-1)},r.onerror=i=>n(i),r.readAsArrayBuffer(e)}))}function dc(e,t){const{width:n}=e,{height:r}=e,{maxWidthOrHeight:i}=t;let s,a=e;return isFinite(i)&&(n>i||r>i)&&([a,s]=ar(n,r),n>r?(a.width=i,a.height=r/n*i):(a.width=n/r*i,a.height=i),s.drawImage(e,0,0,a.width,a.height),Ge(e)),a}function hc(e,t){const{width:n}=e,{height:r}=e,[i,s]=ar(n,r);switch(t>4&&t<9?(i.width=r,i.height=n):(i.width=n,i.height=r),t){case 2:s.transform(-1,0,0,1,n,0);break;case 3:s.transform(-1,0,0,-1,n,r);break;case 4:s.transform(1,0,0,-1,0,r);break;case 5:s.transform(0,1,1,0,0,0);break;case 6:s.transform(0,1,-1,0,r,0);break;case 7:s.transform(0,-1,-1,0,r,n);break;case 8:s.transform(0,-1,1,0,0,n)}return s.drawImage(e,0,0,n,r),Ge(e),i}function mc(e,t,n=0){return new Promise((function(r,i){let s,a,o,u,d,l,c,f,h,m,b,w,v,I,S,E,P,A,O,p;function y(k=5){if(t.signal&&t.signal.aborted)throw t.signal.reason;s+=k,t.onProgress(Math.min(s,100))}function T(k){if(t.signal&&t.signal.aborted)throw t.signal.reason;s=Math.min(Math.max(k,s),100),t.onProgress(s)}return s=n,a=t.maxIteration||10,o=1024*t.maxSizeMB*1024,y(),lr(e,t).then((function(k){try{return[,u]=k,y(),d=dc(u,t),y(),new Promise((function(M,j){var C;if(!(C=t.exifOrientation))return fc(e).then((function(x){try{return C=x,R.call(this)}catch(g){return j(g)}}).bind(this),j);function R(){return M(C)}return R.call(this)})).then((function(M){try{return l=M,y(),Gt().then((function(j){try{return c=j?d:hc(d,l),y(),f=t.initialQuality||1,h=t.fileType||e.type,ur(c,h,e.name,e.lastModified,f).then((function(C){try{{let x=function(){if(a--&&(S>o||S>v)){let _,L;return _=p?.95*O.width:O.width,L=p?.95*O.height:O.height,[P,A]=ar(_,L),A.drawImage(O,0,0,_,L),f*=h==="image/png"?.85:.95,ur(P,h,e.name,e.lastModified,f).then((function(U){try{return E=U,Ge(O),O=P,S=E.size,T(Math.min(99,Math.floor((I-S)/(I-o)*100))),x}catch(F){return i(F)}}),i)}return[1]},g=function(){return Ge(O),Ge(P),Ge(d),Ge(c),Ge(u),T(100),r(E)};if(m=C,y(),b=m.size>o,w=m.size>e.size,!b&&!w)return T(100),r(m);var R;return v=e.size,I=m.size,S=I,O=c,p=!t.alwaysKeepResolution&&b,(R=(function(_){for(;_;){if(_.then)return void _.then(R,i);try{if(_.pop){if(_.length)return _.pop()?g.call(this):_;_=x}else _=_.call(this)}catch(L){return i(L)}}}).bind(this))(x)}}catch(x){return i(x)}}).bind(this),i)}catch(C){return i(C)}}).bind(this),i)}catch(j){return i(j)}}).bind(this),i)}catch(M){return i(M)}}).bind(this),i)}))}const oy=`
570
+ If it declares any Font Awesome CSS pseudo-elements, they will not be rendered as SVG icons. Add crossorigin="anonymous" to the <link>, enable searchPseudoElementsFullScan for slower but more thorough DOM parsing, or suppress this warning by setting searchPseudoElementsWarnings to false.`))}}}catch(b){i.e(b)}finally{i.f()}if(!r.size)return;var m=Array.from(r).join(", ");try{n=e.querySelectorAll(m)}catch{}}return new Promise(function(b,w){var v=$t(n).filter(hg).map(dg),I=rs.begin("searchPseudoElements");Du(),Promise.all(v).then(function(){I(),ss(),b()}).catch(function(){I(),ss(),w()})})}}var gg={hooks:function(){return{mutationObserverCallbacks:function(n){return n.pseudoElementsCallback=Uu,n}}},provides:function(t){t.pseudoElements2svg=function(n){var r=n.node,i=r===void 0?se:r;K.searchPseudoElements&&Uu(i)}}},Bu=!1,yg={mixout:function(){return{dom:{unwatch:function(){Du(),Bu=!0}}}},hooks:function(){return{bootstrap:function(){ju(qi("mutationObserverCallbacks",{}))},noAuto:function(){K1()},watch:function(n){var r=n.observeMutationsRoot;Bu?ss():ju(qi("mutationObserverCallbacks",{observeMutationsRoot:r}))}}}},zu=function(t){var n={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return t.toLowerCase().split(" ").reduce(function(r,i){var s=i.toLowerCase().split("-"),a=s[0],o=s.slice(1).join("-");if(a&&o==="h")return r.flipX=!0,r;if(a&&o==="v")return r.flipY=!0,r;if(o=parseFloat(o),isNaN(o))return r;switch(a){case"grow":r.size=r.size+o;break;case"shrink":r.size=r.size-o;break;case"left":r.x=r.x-o;break;case"right":r.x=r.x+o;break;case"up":r.y=r.y-o;break;case"down":r.y=r.y+o;break;case"rotate":r.rotate=r.rotate+o;break}return r},n)},vg={mixout:function(){return{parse:{transform:function(n){return zu(n)}}}},hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-transform");return i&&(n.transform=zu(i)),n}}},provides:function(t){t.generateAbstractTransformGrouping=function(n){var r=n.main,i=n.transform,s=n.containerWidth,a=n.iconWidth,o={transform:"translate(".concat(s/2," 256)")},u="translate(".concat(i.x*32,", ").concat(i.y*32,") "),d="scale(".concat(i.size/16*(i.flipX?-1:1),", ").concat(i.size/16*(i.flipY?-1:1),") "),l="rotate(".concat(i.rotate," 0 0)"),c={transform:"".concat(u," ").concat(d," ").concat(l)},f={transform:"translate(".concat(a/2*-1," -256)")},h={outer:o,inner:c,path:f};return{tag:"g",attributes:$({},h.outer),children:[{tag:"g",attributes:$({},h.inner),children:[{tag:r.icon.tag,children:r.icon.children,attributes:$($({},r.icon.attributes),h.path)}]}]}}}},os={x:0,y:0,width:"100%",height:"100%"};function $u(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return e.attributes&&(e.attributes.fill||t)&&(e.attributes.fill="black"),e}function bg(e){return e.tag==="g"?e.children:[e]}var xg={hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-mask"),s=i?Jn(i.split(" ").map(function(a){return a.trim()})):bu();return s.prefix||(s.prefix=ut()),n.mask=s,n.maskId=r.getAttribute("data-fa-mask-id"),n}}},provides:function(t){t.generateAbstractMask=function(n){var r=n.children,i=n.attributes,s=n.main,a=n.mask,o=n.maskId,u=n.transform,d=s.width,l=s.icon,c=a.width,f=a.icon,h=f1({transform:u,containerWidth:c,iconWidth:d}),m={tag:"rect",attributes:$($({},os),{},{fill:"white"})},b=l.children?{children:l.children.map($u)}:{},w={tag:"g",attributes:$({},h.inner),children:[$u($({tag:l.tag,attributes:$($({},l.attributes),h.path)},b))]},v={tag:"g",attributes:$({},h.outer),children:[w]},I="mask-".concat(o||nu()),S="clip-".concat(o||nu()),E={tag:"mask",attributes:$($({},os),{},{id:I,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[m,v]},P={tag:"defs",children:[{tag:"clipPath",attributes:{id:S},children:bg(f)},E]};return r.push(P,{tag:"rect",attributes:$({fill:"currentColor","clip-path":"url(#".concat(S,")"),mask:"url(#".concat(I,")")},os)}),{children:r,attributes:i}}}},wg={provides:function(t){var n=!1;lt.matchMedia&&(n=lt.matchMedia("(prefers-reduced-motion: reduce)").matches),t.missingIconAbstract=function(){var r=[],i={fill:"currentColor"},s={attributeType:"XML",repeatCount:"indefinite",dur:"2s"};r.push({tag:"path",attributes:$($({},i),{},{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})});var a=$($({},s),{},{attributeName:"opacity"}),o={tag:"circle",attributes:$($({},i),{},{cx:"256",cy:"364",r:"28"}),children:[]};return n||o.children.push({tag:"animate",attributes:$($({},s),{},{attributeName:"r",values:"28;14;28;28;14;28;"})},{tag:"animate",attributes:$($({},a),{},{values:"1;0;1;1;0;1;"})}),r.push(o),r.push({tag:"path",attributes:$($({},i),{},{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),children:n?[]:[{tag:"animate",attributes:$($({},a),{},{values:"1;0;0;0;0;1;"})}]}),n||r.push({tag:"path",attributes:$($({},i),{},{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),children:[{tag:"animate",attributes:$($({},a),{},{values:"0;0;1;1;0;0;"})}]}),{tag:"g",attributes:{class:"missing"},children:r}}}},Ag={hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-symbol"),s=i===null?!1:i===""?!0:i;return n.symbol=s,n}}}},Sg=[m1,ig,sg,ag,og,gg,yg,vg,xg,wg,Ag];M1(Sg,{mixoutsTo:ke}),ke.noAuto;var bn=ke.config,Tg=ke.library;ke.dom;var Wu=ke.parse;ke.findIconDefinition,ke.toHtml;var Pg=ke.icon;ke.layer,ke.text,ke.counter;function Cg(e){return e=e-0,e===e}function Hu(e){return Cg(e)?e:(e=e.replace(/[_-]+(.)?/g,(t,n)=>n?n.toUpperCase():""),e.charAt(0).toLowerCase()+e.slice(1))}function Eg(e){return e.charAt(0).toUpperCase()+e.slice(1)}var Yt=new Map,Ig=1e3;function kg(e){if(Yt.has(e))return Yt.get(e);const t={};let n=0;const r=e.length;for(;n<r;){const i=e.indexOf(";",n),s=i===-1?r:i,a=e.slice(n,s).trim();if(a){const o=a.indexOf(":");if(o>0){const u=a.slice(0,o).trim(),d=a.slice(o+1).trim();if(u&&d){const l=Hu(u);t[l.startsWith("webkit")?Eg(l):l]=d}}}n=s+1}if(Yt.size===Ig){const i=Yt.keys().next().value;i&&Yt.delete(i)}return Yt.set(e,t),t}function Yu(e,t,n={}){if(typeof t=="string")return t;const r=(t.children||[]).map(l=>Yu(e,l)),i=t.attributes||{},s={};for(const[l,c]of Object.entries(i))switch(!0){case l==="class":{s.className=c;break}case l==="style":{s.style=kg(String(c));break}case l.startsWith("aria-"):case l.startsWith("data-"):{s[l.toLowerCase()]=c;break}default:s[Hu(l)]=c}const{style:a,role:o,"aria-label":u,...d}=n;return a&&(s.style=s.style?{...s.style,...a}:a),o&&(s.role=o),u&&(s["aria-label"]=u,s["aria-hidden"]="false"),e(t.tag,{...d,...s},...r)}var Mg=Yu.bind(null,z.createElement),Gu=(e,t)=>{const n=z.useId();return e||(t?n:void 0)},Dg=class{constructor(e="react-fontawesome"){this.enabled=!1;let t=!1;try{t=typeof process<"u"&&process.env.NODE_ENV==="development"}catch{}this.scope=e,this.enabled=t}log(...e){this.enabled&&console.log(`[${this.scope}]`,...e)}warn(...e){this.enabled&&console.warn(`[${this.scope}]`,...e)}error(...e){this.enabled&&console.error(`[${this.scope}]`,...e)}};typeof process<"u"&&process.env.FA_VERSION;var jg="searchPseudoElementsFullScan"in bn?"7.0.0":"6.0.0",Fg=Number.parseInt(jg)>=7,xn="fa",tt={beat:"fa-beat",fade:"fa-fade",beatFade:"fa-beat-fade",bounce:"fa-bounce",shake:"fa-shake",spin:"fa-spin",spinPulse:"fa-spin-pulse",spinReverse:"fa-spin-reverse",pulse:"fa-pulse"},Lg={left:"fa-pull-left",right:"fa-pull-right"},Og={90:"fa-rotate-90",180:"fa-rotate-180",270:"fa-rotate-270"},Rg={"2xs":"fa-2xs",xs:"fa-xs",sm:"fa-sm",lg:"fa-lg",xl:"fa-xl","2xl":"fa-2xl","1x":"fa-1x","2x":"fa-2x","3x":"fa-3x","4x":"fa-4x","5x":"fa-5x","6x":"fa-6x","7x":"fa-7x","8x":"fa-8x","9x":"fa-9x","10x":"fa-10x"},nt={border:"fa-border",fixedWidth:"fa-fw",flip:"fa-flip",flipHorizontal:"fa-flip-horizontal",flipVertical:"fa-flip-vertical",inverse:"fa-inverse",rotateBy:"fa-rotate-by",swapOpacity:"fa-swap-opacity",widthAuto:"fa-width-auto"};function _g(e){const t=bn.cssPrefix||bn.familyPrefix||xn;return t===xn?e:e.replace(new RegExp(String.raw`(?<=^|\s)${xn}-`,"g"),`${t}-`)}function Vg(e){const{beat:t,fade:n,beatFade:r,bounce:i,shake:s,spin:a,spinPulse:o,spinReverse:u,pulse:d,fixedWidth:l,inverse:c,border:f,flip:h,size:m,rotation:b,pull:w,swapOpacity:v,rotateBy:I,widthAuto:S,className:E}=e,P=[];return E&&P.push(...E.split(" ")),t&&P.push(tt.beat),n&&P.push(tt.fade),r&&P.push(tt.beatFade),i&&P.push(tt.bounce),s&&P.push(tt.shake),a&&P.push(tt.spin),u&&P.push(tt.spinReverse),o&&P.push(tt.spinPulse),d&&P.push(tt.pulse),l&&P.push(nt.fixedWidth),c&&P.push(nt.inverse),f&&P.push(nt.border),h===!0&&P.push(nt.flip),(h==="horizontal"||h==="both")&&P.push(nt.flipHorizontal),(h==="vertical"||h==="both")&&P.push(nt.flipVertical),m!=null&&P.push(Rg[m]),b!=null&&b!==0&&P.push(Og[b]),w!=null&&P.push(Lg[w]),v&&P.push(nt.swapOpacity),Fg?(I&&P.push(nt.rotateBy),S&&P.push(nt.widthAuto),(bn.cssPrefix||bn.familyPrefix||xn)===xn?P:P.map(_g)):P}var Ng=e=>typeof e=="object"&&"icon"in e&&!!e.icon;function Ku(e){if(e)return Ng(e)?e:Wu.icon(e)}function Ug(e){return Object.keys(e)}var Xu=new Dg("FontAwesomeIcon"),qu={border:!1,className:"",mask:void 0,maskId:void 0,fixedWidth:!1,inverse:!1,flip:!1,icon:void 0,listItem:!1,pull:void 0,pulse:!1,rotation:void 0,rotateBy:!1,size:void 0,spin:!1,spinPulse:!1,spinReverse:!1,beat:!1,fade:!1,beatFade:!1,bounce:!1,shake:!1,symbol:!1,title:"",titleId:void 0,transform:void 0,swapOpacity:!1,widthAuto:!1},Bg=new Set(Object.keys(qu)),Ye=z.forwardRef((e,t)=>{const n={...qu,...e},{icon:r,mask:i,symbol:s,title:a,titleId:o,maskId:u,transform:d}=n,l=Gu(u,!!i),c=Gu(o,!!a),f=Ku(r);if(!f)return Xu.error("Icon lookup is undefined",r),null;const h=Vg(n),m=typeof d=="string"?Wu.transform(d):d,b=Ku(i),w=Pg(f,{...h.length>0&&{classes:h},...m&&{transform:m},...b&&{mask:b},symbol:s,title:a,titleId:c,maskId:l});if(!w)return Xu.error("Could not find icon",f),null;const{abstract:v}=w,I={ref:t};for(const S of Ug(n))Bg.has(S)||(I[S]=n[S]);return Mg(v[0],I)});Ye.displayName="FontAwesomeIcon";const Qu={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",fontSize:"24px",fontWeight:"630"};function zg({headingBlock:e,modifyHeading:t}){return D.jsx("input",{style:{...Qu,borderBottom:"1px solid #232323"},type:"text",placeholder:"Heading...",autoFocus:!0,value:e.data.text,onChange:n=>t({headingBlockId:e.id,newContent:n.target.value,level:1})})}function $g({headingBlock:e}){return D.jsx("h2",{style:Qu,children:e.data.text},e.id)}const Zu={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",fontSize:"20px",fontWeight:"600"};function Wg({subheadingBlock:e,modifySubheading:t}){return D.jsx("input",{style:{...Zu,borderBottom:"1px solid #232323"},type:"text",placeholder:"sub heading ...",autoFocus:!0,value:e.data.text,onChange:n=>t({subheadingBlockId:e.id,newContent:n.target.value})})}function Hg({subheadingBlock:e}){return D.jsx("h2",{style:Zu,children:e.data.text},e.id)}const Ju={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",height:"fit-content"};function Yg({paragraphBlock:e,modifyParagraph:t}){return D.jsx("textarea",{style:{...Ju,borderBottom:"1px solid #232323"},placeholder:"Write something...",autoFocus:!0,value:e.data.text,onChange:n=>t({paragraphBlockId:e.id,newContent:n.target.value})})}function Gg({paragraphBlock:e}){return D.jsx("p",{style:Ju,children:e.data.text},e.id)}const ec={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",fontSize:"14px",listStyleType:"disc"};function Kg({listBlock:e,modifyList:t}){return D.jsx("input",{style:{...ec,borderBottom:"1px solid #232323"},type:"text",placeholder:"separate items using comma",autoFocus:!0,value:e.data.items.join(","),onChange:n=>t({listBlockId:e.id,listStyle:e.data.listStyle,items:n.target.value.split(",").map(r=>r.trim())})})}function Xg({listBlock:e}){return D.jsx("ul",{style:ec,children:e.data.items.map((t,n)=>D.jsx("li",{children:t},n))},e.id)}const tc={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",borderLeft:"4px solid #3b82f6",width:"100%",fontSize:"18px",fontStyle:"italic",paddingLeft:"8px",fontWeight:"400"};function qg({quoteBlock:e,modifyQuote:t}){return D.jsx("input",{style:{...tc,borderBottom:"1px solid #232323"},type:"text",placeholder:"Quote...",autoFocus:!0,value:e.data.text,onChange:n=>t({quoteBlockId:e.id,newContent:n.target.value,author:e.data.author})})}function Qg({quoteBlock:e}){return D.jsx("blockquote",{style:tc,children:e.data.text},e.id)}const nc={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",width:"100%",border:"1px solid #d1d5db",borderCollapse:"collapse",tableLayout:"fixed"};function Zg({tableBlock:e,modifyTable:t}){const{data:n}=e;if(!n?.body?.length)return null;const r={rows:n.body.at(-1)?.id[0]??0,cols:n.body.at(-1)?.id[1]??0};return D.jsxs("table",{style:nc,children:[D.jsx("thead",{children:D.jsx("tr",{children:e.data?.head?.map((i,s)=>D.jsx("th",{style:{border:"1px solid #ccc",padding:"8px",backgroundColor:"#f9f9f9"},children:D.jsx("input",{type:"text",style:{border:"none",borderBottom:"1px solid #3b82f6",outline:"none",width:"100%",background:"transparent"},value:i.content,onChange:a=>{const o=e.data.head.map(d=>d.id===i.id?{...d,content:a.target.value}:d),u={...e.data,head:o};t({tableBlockId:e.id,tableContent:u})}})},s))})}),D.jsx("tbody",{children:Array.from({length:r.rows+1},(i,s)=>D.jsx("tr",{children:Array.from({length:r.cols+1},(a,o)=>D.jsx("td",{style:{border:"1px solid #ccc",padding:"8px"},children:D.jsx("input",{type:"text",style:{border:"none",borderBottom:"1px solid #3b82f6",outline:"none",width:"100%",fontSize:"14px"},placeholder:`Row ${s+1}, Col ${o+1}`,value:n.body.find(u=>u.id[0]===s&&u.id[1]===o)?.content||"",onChange:u=>{const d=n.body.map(c=>c.id[0]===s&&c.id[1]===o?{...c,content:u.target.value}:c),l={...n,body:d};t({tableBlockId:e.id,tableContent:l})}})},`${s}-${o}`))},s))})]})}function Jg({tableBlock:e}){if(!e.data||!e.data.head||!e.data.body)return null;const{head:t,body:n}=e.data,r=t.length,i=n.reduce((s,a,o)=>{const u=Math.floor(o/r);return s[u]||(s[u]=[]),s[u].push(a),s},[]);return D.jsxs("table",{style:nc,children:[D.jsx("thead",{children:D.jsx("tr",{style:{backgroundColor:"#f3f4f6"},children:t.map(s=>D.jsx("th",{style:{border:"1px solid #d1d5db",padding:"10px 12px",textAlign:"left",fontSize:"0.85rem",fontWeight:"bold",color:"#374151"},children:s.content},s.id))})}),D.jsx("tbody",{children:i.map((s,a)=>D.jsx("tr",{children:s.map(o=>D.jsx("td",{style:{border:"1px solid #d1d5db",padding:"10px 12px",color:"#4b5563",fontSize:"0.9rem",verticalAlign:"top"},children:o.content},o.id.join("-")))},a))})]},e.id)}function ey({handleClick:e}){const[t,n]=z.useState(!1),[r,i]=z.useState(0),[s,a]=z.useState(0),[o,u]=z.useState({rows:2,cols:2}),[d,l]=z.useState(!1),c=10,f={position:"absolute",transform:"translateX(-40px) translateY(10px)",backgroundColor:"white",display:"flex",flexDirection:"column",gap:"0.25rem",width:"10rem",height:"12.5rem",border:"1px solid #d1d5db",borderRadius:"0.625rem",cursor:"pointer",padding:"0.5rem",zIndex:"10"},h={width:"40px",textDecoration:"underline",textAlign:"center",border:"1px solid #d1d5db",borderRadius:"5px"},m={flex:"1",border:"1px solid #3b82f6",borderRadius:"5px",lineHeight:"normal",padding:"0 4px",color:"#3b82f6",cursor:"pointer"};z.useEffect(()=>{r<0&&i(0),s<0&&a(0),u({rows:r,cols:s})},[r,s]);const b=()=>{n(!1),e("table",o)};return D.jsxs("div",{style:{position:"relative"},children:[D.jsx(Ye,{icon:["fas","angle-down"],onClick:()=>n(w=>!w)}),t?D.jsxs("div",{style:f,children:[D.jsxs("div",{style:{display:"flex",width:"100%",gap:"0.25rem"},children:[D.jsx("input",{style:h,type:"number",value:r,onChange:w=>i(w.target.value)}),"x",D.jsx("input",{style:h,type:"number",value:s,onChange:w=>a(w.target.value)}),D.jsx("button",{style:{...m,...d?{backgroundColor:"#3b82f6",color:"white"}:{}},onMouseEnter:()=>l(!0),onMouseLeave:()=>l(!1),onClick:b,children:"enter"})]}),[...Array(c)].map((w,v)=>D.jsx("div",{style:{display:"flex",gap:"0.25rem"},children:[...Array(c)].map((I,S)=>D.jsx("div",{style:{flex:"1",height:"0.75rem",border:"1px solid #d1d5db",borderRadius:"2px",backgroundColor:v<=o.rows&&S<=o.cols?"#60a5fa":"#e5e7eb"},onMouseEnter:()=>{i(v),a(S)},onMouseLeave:()=>u({rows:0,cols:0}),onClick:b},`${v}-${S}`))},v))]}):null]})}function ty(e,t){return t.forEach((function(n){n&&typeof n!="string"&&!Array.isArray(n)&&Object.keys(n).forEach((function(r){if(r!=="default"&&!(r in e)){var i=Object.getOwnPropertyDescriptor(n,r);Object.defineProperty(e,r,i.get?i:{enumerable:!0,get:function(){return n[r]}})}}))})),Object.freeze(e)}function rc(e,t){return new Promise((function(n,r){let i;return ny(e).then((function(s){try{return i=s,n(new Blob([t.slice(0,2),i,t.slice(2)],{type:"image/jpeg"}))}catch(a){return r(a)}}),r)}))}const ny=e=>new Promise(((t,n)=>{const r=new FileReader;r.addEventListener("load",(({target:{result:i}})=>{const s=new DataView(i);let a=0;if(s.getUint16(a)!==65496)return n("not a valid JPEG");for(a+=2;;){const o=s.getUint16(a);if(o===65498)break;const u=s.getUint16(a+2);if(o===65505&&s.getUint32(a+4)===1165519206){const d=a+10;let l;switch(s.getUint16(d)){case 18761:l=!0;break;case 19789:l=!1;break;default:return n("TIFF header contains invalid endian")}if(s.getUint16(d+2,l)!==42)return n("TIFF header contains invalid version");const c=s.getUint32(d+4,l),f=d+c+2+12*s.getUint16(d+c,l);for(let h=d+c+2;h<f;h+=12)if(s.getUint16(h,l)==274){if(s.getUint16(h+2,l)!==3)return n("Orientation data type is invalid");if(s.getUint32(h+4,l)!==1)return n("Orientation data count is invalid");s.setUint16(h+8,1,l);break}return t(i.slice(a,a+2+u))}a+=2+u}return t(new Blob)})),r.readAsArrayBuffer(e)}));var ir={},ry={get exports(){return ir},set exports(e){ir=e}};(function(e){var t,n,r={};ry.exports=r,r.parse=function(i,s){for(var a=r.bin.readUshort,o=r.bin.readUint,u=0,d={},l=new Uint8Array(i),c=l.length-4;o(l,c)!=101010256;)c--;u=c,u+=4;var f=a(l,u+=4);a(l,u+=2);var h=o(l,u+=2),m=o(l,u+=4);u+=4,u=m;for(var b=0;b<f;b++){o(l,u),u+=4,u+=4,u+=4,o(l,u+=4),h=o(l,u+=4);var w=o(l,u+=4),v=a(l,u+=4),I=a(l,u+2),S=a(l,u+4);u+=6;var E=o(l,u+=8);u+=4,u+=v+I+S,r._readLocal(l,E,d,h,w,s)}return d},r._readLocal=function(i,s,a,o,u,d){var l=r.bin.readUshort,c=r.bin.readUint;c(i,s),l(i,s+=4),l(i,s+=2);var f=l(i,s+=2);c(i,s+=2),c(i,s+=4),s+=4;var h=l(i,s+=8),m=l(i,s+=2);s+=2;var b=r.bin.readUTF8(i,s,h);if(s+=h,s+=m,d)a[b]={size:u,csize:o};else{var w=new Uint8Array(i.buffer,s);if(f==0)a[b]=new Uint8Array(w.buffer.slice(s,s+o));else{if(f!=8)throw"unknown compression method: "+f;var v=new Uint8Array(u);r.inflateRaw(w,v),a[b]=v}}},r.inflateRaw=function(i,s){return r.F.inflate(i,s)},r.inflate=function(i,s){return i[0],i[1],r.inflateRaw(new Uint8Array(i.buffer,i.byteOffset+2,i.length-6),s)},r.deflate=function(i,s){s==null&&(s={level:6});var a=0,o=new Uint8Array(50+Math.floor(1.1*i.length));o[a]=120,o[a+1]=156,a+=2,a=r.F.deflateRaw(i,o,a,s.level);var u=r.adler(i,0,i.length);return o[a+0]=u>>>24&255,o[a+1]=u>>>16&255,o[a+2]=u>>>8&255,o[a+3]=u>>>0&255,new Uint8Array(o.buffer,0,a+4)},r.deflateRaw=function(i,s){s==null&&(s={level:6});var a=new Uint8Array(50+Math.floor(1.1*i.length)),o=r.F.deflateRaw(i,a,o,s.level);return new Uint8Array(a.buffer,0,o)},r.encode=function(i,s){s==null&&(s=!1);var a=0,o=r.bin.writeUint,u=r.bin.writeUshort,d={};for(var l in i){var c=!r._noNeed(l)&&!s,f=i[l],h=r.crc.crc(f,0,f.length);d[l]={cpr:c,usize:f.length,crc:h,file:c?r.deflateRaw(f):f}}for(var l in d)a+=d[l].file.length+30+46+2*r.bin.sizeUTF8(l);a+=22;var m=new Uint8Array(a),b=0,w=[];for(var l in d){var v=d[l];w.push(b),b=r._writeHeader(m,b,l,v,0)}var I=0,S=b;for(var l in d)v=d[l],w.push(b),b=r._writeHeader(m,b,l,v,1,w[I++]);var E=b-S;return o(m,b,101010256),b+=4,u(m,b+=4,I),u(m,b+=2,I),o(m,b+=2,E),o(m,b+=4,S),b+=4,b+=2,m.buffer},r._noNeed=function(i){var s=i.split(".").pop().toLowerCase();return"png,jpg,jpeg,zip".indexOf(s)!=-1},r._writeHeader=function(i,s,a,o,u,d){var l=r.bin.writeUint,c=r.bin.writeUshort,f=o.file;return l(i,s,u==0?67324752:33639248),s+=4,u==1&&(s+=2),c(i,s,20),c(i,s+=2,0),c(i,s+=2,o.cpr?8:0),l(i,s+=2,0),l(i,s+=4,o.crc),l(i,s+=4,f.length),l(i,s+=4,o.usize),c(i,s+=4,r.bin.sizeUTF8(a)),c(i,s+=2,0),s+=2,u==1&&(s+=2,s+=2,l(i,s+=6,d),s+=4),s+=r.bin.writeUTF8(i,s,a),u==0&&(i.set(f,s),s+=f.length),s},r.crc={table:(function(){for(var i=new Uint32Array(256),s=0;s<256;s++){for(var a=s,o=0;o<8;o++)1&a?a=3988292384^a>>>1:a>>>=1;i[s]=a}return i})(),update:function(i,s,a,o){for(var u=0;u<o;u++)i=r.crc.table[255&(i^s[a+u])]^i>>>8;return i},crc:function(i,s,a){return 4294967295^r.crc.update(4294967295,i,s,a)}},r.adler=function(i,s,a){for(var o=1,u=0,d=s,l=s+a;d<l;){for(var c=Math.min(d+5552,l);d<c;)u+=o+=i[d++];o%=65521,u%=65521}return u<<16|o},r.bin={readUshort:function(i,s){return i[s]|i[s+1]<<8},writeUshort:function(i,s,a){i[s]=255&a,i[s+1]=a>>8&255},readUint:function(i,s){return 16777216*i[s+3]+(i[s+2]<<16|i[s+1]<<8|i[s])},writeUint:function(i,s,a){i[s]=255&a,i[s+1]=a>>8&255,i[s+2]=a>>16&255,i[s+3]=a>>24&255},readASCII:function(i,s,a){for(var o="",u=0;u<a;u++)o+=String.fromCharCode(i[s+u]);return o},writeASCII:function(i,s,a){for(var o=0;o<a.length;o++)i[s+o]=a.charCodeAt(o)},pad:function(i){return i.length<2?"0"+i:i},readUTF8:function(i,s,a){for(var o,u="",d=0;d<a;d++)u+="%"+r.bin.pad(i[s+d].toString(16));try{o=decodeURIComponent(u)}catch{return r.bin.readASCII(i,s,a)}return o},writeUTF8:function(i,s,a){for(var o=a.length,u=0,d=0;d<o;d++){var l=a.charCodeAt(d);if((4294967168&l)==0)i[s+u]=l,u++;else if((4294965248&l)==0)i[s+u]=192|l>>6,i[s+u+1]=128|l>>0&63,u+=2;else if((4294901760&l)==0)i[s+u]=224|l>>12,i[s+u+1]=128|l>>6&63,i[s+u+2]=128|l>>0&63,u+=3;else{if((4292870144&l)!=0)throw"e";i[s+u]=240|l>>18,i[s+u+1]=128|l>>12&63,i[s+u+2]=128|l>>6&63,i[s+u+3]=128|l>>0&63,u+=4}}return u},sizeUTF8:function(i){for(var s=i.length,a=0,o=0;o<s;o++){var u=i.charCodeAt(o);if((4294967168&u)==0)a++;else if((4294965248&u)==0)a+=2;else if((4294901760&u)==0)a+=3;else{if((4292870144&u)!=0)throw"e";a+=4}}return a}},r.F={},r.F.deflateRaw=function(i,s,a,o){var u=[[0,0,0,0,0],[4,4,8,4,0],[4,5,16,8,0],[4,6,16,16,0],[4,10,16,32,0],[8,16,32,32,0],[8,16,128,128,0],[8,32,128,256,0],[32,128,258,1024,1],[32,258,258,4096,1]][o],d=r.F.U,l=r.F._goodIndex;r.F._hash;var c=r.F._putsE,f=0,h=a<<3,m=0,b=i.length;if(o==0){for(;f<b;)c(s,h,f+(k=Math.min(65535,b-f))==b?1:0),h=r.F._copyExact(i,f,k,s,h+8),f+=k;return h>>>3}var w=d.lits,v=d.strt,I=d.prev,S=0,E=0,P=0,A=0,O=0,p=0;for(b>2&&(v[p=r.F._hash(i,0)]=0),f=0;f<b;f++){if(O=p,f+1<b-2){p=r.F._hash(i,f+1);var y=f+1&32767;I[y]=v[p],v[p]=y}if(m<=f){(S>14e3||E>26697)&&b-f>100&&(m<f&&(w[S]=f-m,S+=2,m=f),h=r.F._writeBlock(f==b-1||m==b?1:0,w,S,A,i,P,f-P,s,h),S=E=A=0,P=f);var T=0;f<b-2&&(T=r.F._bestMatch(i,f,I,O,Math.min(u[2],b-f),u[3]));var k=T>>>16,M=65535&T;if(T!=0){M=65535&T;var j=l(k=T>>>16,d.of0);d.lhst[257+j]++;var C=l(M,d.df0);d.dhst[C]++,A+=d.exb[j]+d.dxb[C],w[S]=k<<23|f-m,w[S+1]=M<<16|j<<8|C,S+=2,m=f+k}else d.lhst[i[f]]++;E++}}for(P==f&&i.length!=0||(m<f&&(w[S]=f-m,S+=2,m=f),h=r.F._writeBlock(1,w,S,A,i,P,f-P,s,h),S=0,E=0,S=E=A=0,P=f);(7&h)!=0;)h++;return h>>>3},r.F._bestMatch=function(i,s,a,o,u,d){var l=32767&s,c=a[l],f=l-c+32768&32767;if(c==l||o!=r.F._hash(i,s-f))return 0;for(var h=0,m=0,b=Math.min(32767,s);f<=b&&--d!=0&&c!=l;){if(h==0||i[s+h]==i[s+h-f]){var w=r.F._howLong(i,s,f);if(w>h){if(m=f,(h=w)>=u)break;f+2<w&&(w=f+2);for(var v=0,I=0;I<w-2;I++){var S=s-f+I+32768&32767,E=S-a[S]+32768&32767;E>v&&(v=E,c=S)}}}f+=(l=c)-(c=a[l])+32768&32767}return h<<16|m},r.F._howLong=function(i,s,a){if(i[s]!=i[s-a]||i[s+1]!=i[s+1-a]||i[s+2]!=i[s+2-a])return 0;var o=s,u=Math.min(i.length,s+258);for(s+=3;s<u&&i[s]==i[s-a];)s++;return s-o},r.F._hash=function(i,s){return(i[s]<<8|i[s+1])+(i[s+2]<<4)&65535},r.saved=0,r.F._writeBlock=function(i,s,a,o,u,d,l,c,f){var h,m,b,w,v,I,S,E,P,A=r.F.U,O=r.F._putsF,p=r.F._putsE;A.lhst[256]++,m=(h=r.F.getTrees())[0],b=h[1],w=h[2],v=h[3],I=h[4],S=h[5],E=h[6],P=h[7];var y=32+((f+3&7)==0?0:8-(f+3&7))+(l<<3),T=o+r.F.contSize(A.fltree,A.lhst)+r.F.contSize(A.fdtree,A.dhst),k=o+r.F.contSize(A.ltree,A.lhst)+r.F.contSize(A.dtree,A.dhst);k+=14+3*S+r.F.contSize(A.itree,A.ihst)+(2*A.ihst[16]+3*A.ihst[17]+7*A.ihst[18]);for(var M=0;M<286;M++)A.lhst[M]=0;for(M=0;M<30;M++)A.dhst[M]=0;for(M=0;M<19;M++)A.ihst[M]=0;var j=y<T&&y<k?0:T<k?1:2;if(O(c,f,i),O(c,f+1,j),f+=3,j==0){for(;(7&f)!=0;)f++;f=r.F._copyExact(u,d,l,c,f)}else{var C,R;if(j==1&&(C=A.fltree,R=A.fdtree),j==2){r.F.makeCodes(A.ltree,m),r.F.revCodes(A.ltree,m),r.F.makeCodes(A.dtree,b),r.F.revCodes(A.dtree,b),r.F.makeCodes(A.itree,w),r.F.revCodes(A.itree,w),C=A.ltree,R=A.dtree,p(c,f,v-257),p(c,f+=5,I-1),p(c,f+=5,S-4),f+=4;for(var x=0;x<S;x++)p(c,f+3*x,A.itree[1+(A.ordr[x]<<1)]);f+=3*S,f=r.F._codeTiny(E,A.itree,c,f),f=r.F._codeTiny(P,A.itree,c,f)}for(var g=d,_=0;_<a;_+=2){for(var L=s[_],U=L>>>23,F=g+(8388607&L);g<F;)f=r.F._writeLit(u[g++],C,c,f);if(U!=0){var N=s[_+1],W=N>>16,B=N>>8&255,V=255&N;p(c,f=r.F._writeLit(257+B,C,c,f),U-A.of0[B]),f+=A.exb[B],O(c,f=r.F._writeLit(V,R,c,f),W-A.df0[V]),f+=A.dxb[V],g+=U}}f=r.F._writeLit(256,C,c,f)}return f},r.F._copyExact=function(i,s,a,o,u){var d=u>>>3;return o[d]=a,o[d+1]=a>>>8,o[d+2]=255-o[d],o[d+3]=255-o[d+1],d+=4,o.set(new Uint8Array(i.buffer,s,a),d),u+(a+4<<3)},r.F.getTrees=function(){for(var i=r.F.U,s=r.F._hufTree(i.lhst,i.ltree,15),a=r.F._hufTree(i.dhst,i.dtree,15),o=[],u=r.F._lenCodes(i.ltree,o),d=[],l=r.F._lenCodes(i.dtree,d),c=0;c<o.length;c+=2)i.ihst[o[c]]++;for(c=0;c<d.length;c+=2)i.ihst[d[c]]++;for(var f=r.F._hufTree(i.ihst,i.itree,7),h=19;h>4&&i.itree[1+(i.ordr[h-1]<<1)]==0;)h--;return[s,a,f,u,l,h,o,d]},r.F.getSecond=function(i){for(var s=[],a=0;a<i.length;a+=2)s.push(i[a+1]);return s},r.F.nonZero=function(i){for(var s="",a=0;a<i.length;a+=2)i[a+1]!=0&&(s+=(a>>1)+",");return s},r.F.contSize=function(i,s){for(var a=0,o=0;o<s.length;o++)a+=s[o]*i[1+(o<<1)];return a},r.F._codeTiny=function(i,s,a,o){for(var u=0;u<i.length;u+=2){var d=i[u],l=i[u+1];o=r.F._writeLit(d,s,a,o);var c=d==16?2:d==17?3:7;d>15&&(r.F._putsE(a,o,l,c),o+=c)}return o},r.F._lenCodes=function(i,s){for(var a=i.length;a!=2&&i[a-1]==0;)a-=2;for(var o=0;o<a;o+=2){var u=i[o+1],d=o+3<a?i[o+3]:-1,l=o+5<a?i[o+5]:-1,c=o==0?-1:i[o-1];if(u==0&&d==u&&l==u){for(var f=o+5;f+2<a&&i[f+2]==u;)f+=2;(h=Math.min(f+1-o>>>1,138))<11?s.push(17,h-3):s.push(18,h-11),o+=2*h-2}else if(u==c&&d==u&&l==u){for(f=o+5;f+2<a&&i[f+2]==u;)f+=2;var h=Math.min(f+1-o>>>1,6);s.push(16,h-3),o+=2*h-2}else s.push(u,0)}return a>>>1},r.F._hufTree=function(i,s,a){var o=[],u=i.length,d=s.length,l=0;for(l=0;l<d;l+=2)s[l]=0,s[l+1]=0;for(l=0;l<u;l++)i[l]!=0&&o.push({lit:l,f:i[l]});var c=o.length,f=o.slice(0);if(c==0)return 0;if(c==1){var h=o[0].lit;return f=h==0?1:0,s[1+(h<<1)]=1,s[1+(f<<1)]=1,1}o.sort((function(E,P){return E.f-P.f}));var m=o[0],b=o[1],w=0,v=1,I=2;for(o[0]={lit:-1,f:m.f+b.f,l:m,r:b,d:0};v!=c-1;)m=w!=v&&(I==c||o[w].f<o[I].f)?o[w++]:o[I++],b=w!=v&&(I==c||o[w].f<o[I].f)?o[w++]:o[I++],o[v++]={lit:-1,f:m.f+b.f,l:m,r:b};var S=r.F.setDepth(o[v-1],0);for(S>a&&(r.F.restrictDepth(f,a,S),S=a),l=0;l<c;l++)s[1+(f[l].lit<<1)]=f[l].d;return S},r.F.setDepth=function(i,s){return i.lit!=-1?(i.d=s,s):Math.max(r.F.setDepth(i.l,s+1),r.F.setDepth(i.r,s+1))},r.F.restrictDepth=function(i,s,a){var o=0,u=1<<a-s,d=0;for(i.sort((function(c,f){return f.d==c.d?c.f-f.f:f.d-c.d})),o=0;o<i.length&&i[o].d>s;o++){var l=i[o].d;i[o].d=s,d+=u-(1<<a-l)}for(d>>>=a-s;d>0;)(l=i[o].d)<s?(i[o].d++,d-=1<<s-l-1):o++;for(;o>=0;o--)i[o].d==s&&d<0&&(i[o].d--,d++);d!=0&&console.log("debt left")},r.F._goodIndex=function(i,s){var a=0;return s[16|a]<=i&&(a|=16),s[8|a]<=i&&(a|=8),s[4|a]<=i&&(a|=4),s[2|a]<=i&&(a|=2),s[1|a]<=i&&(a|=1),a},r.F._writeLit=function(i,s,a,o){return r.F._putsF(a,o,s[i<<1]),o+s[1+(i<<1)]},r.F.inflate=function(i,s){var a=Uint8Array;if(i[0]==3&&i[1]==0)return s||new a(0);var o=r.F,u=o._bitsF,d=o._bitsE,l=o._decodeTiny,c=o.makeCodes,f=o.codes2map,h=o._get17,m=o.U,b=s==null;b&&(s=new a(i.length>>>2<<3));for(var w,v,I=0,S=0,E=0,P=0,A=0,O=0,p=0,y=0,T=0;I==0;)if(I=u(i,T,1),S=u(i,T+1,2),T+=3,S!=0){if(b&&(s=r.F._check(s,y+(1<<17))),S==1&&(w=m.flmap,v=m.fdmap,O=511,p=31),S==2){E=d(i,T,5)+257,P=d(i,T+5,5)+1,A=d(i,T+10,4)+4,T+=14;for(var k=0;k<38;k+=2)m.itree[k]=0,m.itree[k+1]=0;var M=1;for(k=0;k<A;k++){var j=d(i,T+3*k,3);m.itree[1+(m.ordr[k]<<1)]=j,j>M&&(M=j)}T+=3*A,c(m.itree,M),f(m.itree,M,m.imap),w=m.lmap,v=m.dmap,T=l(m.imap,(1<<M)-1,E+P,i,T,m.ttree);var C=o._copyOut(m.ttree,0,E,m.ltree);O=(1<<C)-1;var R=o._copyOut(m.ttree,E,P,m.dtree);p=(1<<R)-1,c(m.ltree,C),f(m.ltree,C,w),c(m.dtree,R),f(m.dtree,R,v)}for(;;){var x=w[h(i,T)&O];T+=15&x;var g=x>>>4;if(!(g>>>8))s[y++]=g;else{if(g==256)break;var _=y+g-254;if(g>264){var L=m.ldef[g-257];_=y+(L>>>3)+d(i,T,7&L),T+=7&L}var U=v[h(i,T)&p];T+=15&U;var F=U>>>4,N=m.ddef[F],W=(N>>>4)+u(i,T,15&N);for(T+=15&N,b&&(s=r.F._check(s,y+(1<<17)));y<_;)s[y]=s[y++-W],s[y]=s[y++-W],s[y]=s[y++-W],s[y]=s[y++-W];y=_}}}else{(7&T)!=0&&(T+=8-(7&T));var B=4+(T>>>3),V=i[B-4]|i[B-3]<<8;b&&(s=r.F._check(s,y+V)),s.set(new a(i.buffer,i.byteOffset+B,V),y),T=B+V<<3,y+=V}return s.length==y?s:s.slice(0,y)},r.F._check=function(i,s){var a=i.length;if(s<=a)return i;var o=new Uint8Array(Math.max(a<<1,s));return o.set(i,0),o},r.F._decodeTiny=function(i,s,a,o,u,d){for(var l=r.F._bitsE,c=r.F._get17,f=0;f<a;){var h=i[c(o,u)&s];u+=15&h;var m=h>>>4;if(m<=15)d[f]=m,f++;else{var b=0,w=0;m==16?(w=3+l(o,u,2),u+=2,b=d[f-1]):m==17?(w=3+l(o,u,3),u+=3):m==18&&(w=11+l(o,u,7),u+=7);for(var v=f+w;f<v;)d[f]=b,f++}}return u},r.F._copyOut=function(i,s,a,o){for(var u=0,d=0,l=o.length>>>1;d<a;){var c=i[d+s];o[d<<1]=0,o[1+(d<<1)]=c,c>u&&(u=c),d++}for(;d<l;)o[d<<1]=0,o[1+(d<<1)]=0,d++;return u},r.F.makeCodes=function(i,s){for(var a,o,u,d,l=r.F.U,c=i.length,f=l.bl_count,h=0;h<=s;h++)f[h]=0;for(h=1;h<c;h+=2)f[i[h]]++;var m=l.next_code;for(a=0,f[0]=0,o=1;o<=s;o++)a=a+f[o-1]<<1,m[o]=a;for(u=0;u<c;u+=2)(d=i[u+1])!=0&&(i[u]=m[d],m[d]++)},r.F.codes2map=function(i,s,a){for(var o=i.length,u=r.F.U.rev15,d=0;d<o;d+=2)if(i[d+1]!=0)for(var l=d>>1,c=i[d+1],f=l<<4|c,h=s-c,m=i[d]<<h,b=m+(1<<h);m!=b;)a[u[m]>>>15-s]=f,m++},r.F.revCodes=function(i,s){for(var a=r.F.U.rev15,o=15-s,u=0;u<i.length;u+=2){var d=i[u]<<s-i[u+1];i[u]=a[d]>>>o}},r.F._putsE=function(i,s,a){a<<=7&s;var o=s>>>3;i[o]|=a,i[o+1]|=a>>>8},r.F._putsF=function(i,s,a){a<<=7&s;var o=s>>>3;i[o]|=a,i[o+1]|=a>>>8,i[o+2]|=a>>>16},r.F._bitsE=function(i,s,a){return(i[s>>>3]|i[1+(s>>>3)]<<8)>>>(7&s)&(1<<a)-1},r.F._bitsF=function(i,s,a){return(i[s>>>3]|i[1+(s>>>3)]<<8|i[2+(s>>>3)]<<16)>>>(7&s)&(1<<a)-1},r.F._get17=function(i,s){return(i[s>>>3]|i[1+(s>>>3)]<<8|i[2+(s>>>3)]<<16)>>>(7&s)},r.F._get25=function(i,s){return(i[s>>>3]|i[1+(s>>>3)]<<8|i[2+(s>>>3)]<<16|i[3+(s>>>3)]<<24)>>>(7&s)},r.F.U=(t=Uint16Array,n=Uint32Array,{next_code:new t(16),bl_count:new t(16),ordr:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],of0:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],exb:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],ldef:new t(32),df0:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],dxb:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],ddef:new n(32),flmap:new t(512),fltree:[],fdmap:new t(32),fdtree:[],lmap:new t(32768),ltree:[],ttree:[],dmap:new t(32768),dtree:[],imap:new t(512),itree:[],rev15:new t(32768),lhst:new n(286),dhst:new n(30),ihst:new n(19),lits:new n(15e3),strt:new t(65536),prev:new t(32768)}),(function(){for(var i=r.F.U,s=0;s<32768;s++){var a=s;a=(4278255360&(a=(4042322160&(a=(3435973836&(a=(2863311530&a)>>>1|(1431655765&a)<<1))>>>2|(858993459&a)<<2))>>>4|(252645135&a)<<4))>>>8|(16711935&a)<<8,i.rev15[s]=(a>>>16|a<<16)>>>17}function o(u,d,l){for(;d--!=0;)u.push(0,l)}for(s=0;s<32;s++)i.ldef[s]=i.of0[s]<<3|i.exb[s],i.ddef[s]=i.df0[s]<<4|i.dxb[s];o(i.fltree,144,8),o(i.fltree,112,9),o(i.fltree,24,7),o(i.fltree,8,8),r.F.makeCodes(i.fltree,9),r.F.codes2map(i.fltree,9,i.flmap),r.F.revCodes(i.fltree,9),o(i.fdtree,32,5),r.F.makeCodes(i.fdtree,5),r.F.codes2map(i.fdtree,5,i.fdmap),r.F.revCodes(i.fdtree,5),o(i.itree,19,0),o(i.ltree,286,0),o(i.dtree,30,0),o(i.ttree,320,0)})()})();var iy=ty({__proto__:null,default:ir},[ir]);const ze=(function(){var e={nextZero(l,c){for(;l[c]!=0;)c++;return c},readUshort:(l,c)=>l[c]<<8|l[c+1],writeUshort(l,c,f){l[c]=f>>8&255,l[c+1]=255&f},readUint:(l,c)=>16777216*l[c]+(l[c+1]<<16|l[c+2]<<8|l[c+3]),writeUint(l,c,f){l[c]=f>>24&255,l[c+1]=f>>16&255,l[c+2]=f>>8&255,l[c+3]=255&f},readASCII(l,c,f){let h="";for(let m=0;m<f;m++)h+=String.fromCharCode(l[c+m]);return h},writeASCII(l,c,f){for(let h=0;h<f.length;h++)l[c+h]=f.charCodeAt(h)},readBytes(l,c,f){const h=[];for(let m=0;m<f;m++)h.push(l[c+m]);return h},pad:l=>l.length<2?`0${l}`:l,readUTF8(l,c,f){let h,m="";for(let b=0;b<f;b++)m+=`%${e.pad(l[c+b].toString(16))}`;try{h=decodeURIComponent(m)}catch{return e.readASCII(l,c,f)}return h}};function t(l,c,f,h){const m=c*f,b=s(h),w=Math.ceil(c*b/8),v=new Uint8Array(4*m),I=new Uint32Array(v.buffer),{ctype:S}=h,{depth:E}=h,P=e.readUshort;if(S==6){const L=m<<2;if(E==8)for(var A=0;A<L;A+=4)v[A]=l[A],v[A+1]=l[A+1],v[A+2]=l[A+2],v[A+3]=l[A+3];if(E==16)for(A=0;A<L;A++)v[A]=l[A<<1]}else if(S==2){const L=h.tabs.tRNS;if(L==null){if(E==8)for(A=0;A<m;A++){var O=3*A;I[A]=255<<24|l[O+2]<<16|l[O+1]<<8|l[O]}if(E==16)for(A=0;A<m;A++)O=6*A,I[A]=255<<24|l[O+4]<<16|l[O+2]<<8|l[O]}else{var p=L[0];const U=L[1],F=L[2];if(E==8)for(A=0;A<m;A++){var y=A<<2;O=3*A,I[A]=255<<24|l[O+2]<<16|l[O+1]<<8|l[O],l[O]==p&&l[O+1]==U&&l[O+2]==F&&(v[y+3]=0)}if(E==16)for(A=0;A<m;A++)y=A<<2,O=6*A,I[A]=255<<24|l[O+4]<<16|l[O+2]<<8|l[O],P(l,O)==p&&P(l,O+2)==U&&P(l,O+4)==F&&(v[y+3]=0)}}else if(S==3){const L=h.tabs.PLTE,U=h.tabs.tRNS,F=U?U.length:0;if(E==1)for(var T=0;T<f;T++){var k=T*w,M=T*c;for(A=0;A<c;A++){y=M+A<<2;var j=3*(C=l[k+(A>>3)]>>7-((7&A)<<0)&1);v[y]=L[j],v[y+1]=L[j+1],v[y+2]=L[j+2],v[y+3]=C<F?U[C]:255}}if(E==2)for(T=0;T<f;T++)for(k=T*w,M=T*c,A=0;A<c;A++)y=M+A<<2,j=3*(C=l[k+(A>>2)]>>6-((3&A)<<1)&3),v[y]=L[j],v[y+1]=L[j+1],v[y+2]=L[j+2],v[y+3]=C<F?U[C]:255;if(E==4)for(T=0;T<f;T++)for(k=T*w,M=T*c,A=0;A<c;A++)y=M+A<<2,j=3*(C=l[k+(A>>1)]>>4-((1&A)<<2)&15),v[y]=L[j],v[y+1]=L[j+1],v[y+2]=L[j+2],v[y+3]=C<F?U[C]:255;if(E==8)for(A=0;A<m;A++){var C;y=A<<2,j=3*(C=l[A]),v[y]=L[j],v[y+1]=L[j+1],v[y+2]=L[j+2],v[y+3]=C<F?U[C]:255}}else if(S==4){if(E==8)for(A=0;A<m;A++){y=A<<2;var R=l[x=A<<1];v[y]=R,v[y+1]=R,v[y+2]=R,v[y+3]=l[x+1]}if(E==16)for(A=0;A<m;A++){var x;y=A<<2,R=l[x=A<<2],v[y]=R,v[y+1]=R,v[y+2]=R,v[y+3]=l[x+2]}}else if(S==0)for(p=h.tabs.tRNS?h.tabs.tRNS:-1,T=0;T<f;T++){const L=T*w,U=T*c;if(E==1)for(var g=0;g<c;g++){var _=(R=255*(l[L+(g>>>3)]>>>7-(7&g)&1))==255*p?0:255;I[U+g]=_<<24|R<<16|R<<8|R}else if(E==2)for(g=0;g<c;g++)_=(R=85*(l[L+(g>>>2)]>>>6-((3&g)<<1)&3))==85*p?0:255,I[U+g]=_<<24|R<<16|R<<8|R;else if(E==4)for(g=0;g<c;g++)_=(R=17*(l[L+(g>>>1)]>>>4-((1&g)<<2)&15))==17*p?0:255,I[U+g]=_<<24|R<<16|R<<8|R;else if(E==8)for(g=0;g<c;g++)_=(R=l[L+g])==p?0:255,I[U+g]=_<<24|R<<16|R<<8|R;else if(E==16)for(g=0;g<c;g++)R=l[L+(g<<1)],_=P(l,L+(g<<1))==p?0:255,I[U+g]=_<<24|R<<16|R<<8|R}return v}function n(l,c,f,h){const m=s(l),b=Math.ceil(f*m/8),w=new Uint8Array((b+1+l.interlace)*h);return c=l.tabs.CgBI?i(c,w):r(c,w),l.interlace==0?c=a(c,l,0,f,h):l.interlace==1&&(c=(function(I,S){const E=S.width,P=S.height,A=s(S),O=A>>3,p=Math.ceil(E*A/8),y=new Uint8Array(P*p);let T=0;const k=[0,0,4,0,2,0,1],M=[0,4,0,2,0,1,0],j=[8,8,8,4,4,2,2],C=[8,8,4,4,2,2,1];let R=0;for(;R<7;){const g=j[R],_=C[R];let L=0,U=0,F=k[R];for(;F<P;)F+=g,U++;let N=M[R];for(;N<E;)N+=_,L++;const W=Math.ceil(L*A/8);a(I,S,T,L,U);let B=0,V=k[R];for(;V<P;){let X=M[R],Q=T+B*W<<3;for(;X<E;){var x;if(A==1&&(x=(x=I[Q>>3])>>7-(7&Q)&1,y[V*p+(X>>3)]|=x<<7-((7&X)<<0)),A==2&&(x=(x=I[Q>>3])>>6-(7&Q)&3,y[V*p+(X>>2)]|=x<<6-((3&X)<<1)),A==4&&(x=(x=I[Q>>3])>>4-(7&Q)&15,y[V*p+(X>>1)]|=x<<4-((1&X)<<2)),A>=8){const J=V*p+X*O;for(let ee=0;ee<O;ee++)y[J+ee]=I[(Q>>3)+ee]}Q+=A,X+=_}B++,V+=g}L*U!=0&&(T+=U*(1+W)),R+=1}return y})(c,l)),c}function r(l,c){return i(new Uint8Array(l.buffer,2,l.length-6),c)}var i=(function(){const l={H:{}};return l.H.N=function(c,f){const h=Uint8Array;let m,b,w=0,v=0,I=0,S=0,E=0,P=0,A=0,O=0,p=0;if(c[0]==3&&c[1]==0)return f||new h(0);const y=l.H,T=y.b,k=y.e,M=y.R,j=y.n,C=y.A,R=y.Z,x=y.m,g=f==null;for(g&&(f=new h(c.length>>>2<<5));w==0;)if(w=T(c,p,1),v=T(c,p+1,2),p+=3,v!=0){if(g&&(f=l.H.W(f,O+(1<<17))),v==1&&(m=x.J,b=x.h,P=511,A=31),v==2){I=k(c,p,5)+257,S=k(c,p+5,5)+1,E=k(c,p+10,4)+4,p+=14;let L=1;for(var _=0;_<38;_+=2)x.Q[_]=0,x.Q[_+1]=0;for(_=0;_<E;_++){const N=k(c,p+3*_,3);x.Q[1+(x.X[_]<<1)]=N,N>L&&(L=N)}p+=3*E,j(x.Q,L),C(x.Q,L,x.u),m=x.w,b=x.d,p=M(x.u,(1<<L)-1,I+S,c,p,x.v);const U=y.V(x.v,0,I,x.C);P=(1<<U)-1;const F=y.V(x.v,I,S,x.D);A=(1<<F)-1,j(x.C,U),C(x.C,U,m),j(x.D,F),C(x.D,F,b)}for(;;){const L=m[R(c,p)&P];p+=15&L;const U=L>>>4;if(!(U>>>8))f[O++]=U;else{if(U==256)break;{let F=O+U-254;if(U>264){const X=x.q[U-257];F=O+(X>>>3)+k(c,p,7&X),p+=7&X}const N=b[R(c,p)&A];p+=15&N;const W=N>>>4,B=x.c[W],V=(B>>>4)+T(c,p,15&B);for(p+=15&B;O<F;)f[O]=f[O++-V],f[O]=f[O++-V],f[O]=f[O++-V],f[O]=f[O++-V];O=F}}}}else{(7&p)!=0&&(p+=8-(7&p));const L=4+(p>>>3),U=c[L-4]|c[L-3]<<8;g&&(f=l.H.W(f,O+U)),f.set(new h(c.buffer,c.byteOffset+L,U),O),p=L+U<<3,O+=U}return f.length==O?f:f.slice(0,O)},l.H.W=function(c,f){const h=c.length;if(f<=h)return c;const m=new Uint8Array(h<<1);return m.set(c,0),m},l.H.R=function(c,f,h,m,b,w){const v=l.H.e,I=l.H.Z;let S=0;for(;S<h;){const E=c[I(m,b)&f];b+=15&E;const P=E>>>4;if(P<=15)w[S]=P,S++;else{let A=0,O=0;P==16?(O=3+v(m,b,2),b+=2,A=w[S-1]):P==17?(O=3+v(m,b,3),b+=3):P==18&&(O=11+v(m,b,7),b+=7);const p=S+O;for(;S<p;)w[S]=A,S++}}return b},l.H.V=function(c,f,h,m){let b=0,w=0;const v=m.length>>>1;for(;w<h;){const I=c[w+f];m[w<<1]=0,m[1+(w<<1)]=I,I>b&&(b=I),w++}for(;w<v;)m[w<<1]=0,m[1+(w<<1)]=0,w++;return b},l.H.n=function(c,f){const h=l.H.m,m=c.length;let b,w,v,I;const S=h.j;for(var E=0;E<=f;E++)S[E]=0;for(E=1;E<m;E+=2)S[c[E]]++;const P=h.K;for(b=0,S[0]=0,w=1;w<=f;w++)b=b+S[w-1]<<1,P[w]=b;for(v=0;v<m;v+=2)I=c[v+1],I!=0&&(c[v]=P[I],P[I]++)},l.H.A=function(c,f,h){const m=c.length,b=l.H.m.r;for(let w=0;w<m;w+=2)if(c[w+1]!=0){const v=w>>1,I=c[w+1],S=v<<4|I,E=f-I;let P=c[w]<<E;const A=P+(1<<E);for(;P!=A;)h[b[P]>>>15-f]=S,P++}},l.H.l=function(c,f){const h=l.H.m.r,m=15-f;for(let b=0;b<c.length;b+=2){const w=c[b]<<f-c[b+1];c[b]=h[w]>>>m}},l.H.M=function(c,f,h){h<<=7&f;const m=f>>>3;c[m]|=h,c[m+1]|=h>>>8},l.H.I=function(c,f,h){h<<=7&f;const m=f>>>3;c[m]|=h,c[m+1]|=h>>>8,c[m+2]|=h>>>16},l.H.e=function(c,f,h){return(c[f>>>3]|c[1+(f>>>3)]<<8)>>>(7&f)&(1<<h)-1},l.H.b=function(c,f,h){return(c[f>>>3]|c[1+(f>>>3)]<<8|c[2+(f>>>3)]<<16)>>>(7&f)&(1<<h)-1},l.H.Z=function(c,f){return(c[f>>>3]|c[1+(f>>>3)]<<8|c[2+(f>>>3)]<<16)>>>(7&f)},l.H.i=function(c,f){return(c[f>>>3]|c[1+(f>>>3)]<<8|c[2+(f>>>3)]<<16|c[3+(f>>>3)]<<24)>>>(7&f)},l.H.m=(function(){const c=Uint16Array,f=Uint32Array;return{K:new c(16),j:new c(16),X:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S:[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,999,999,999],T:[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0],q:new c(32),p:[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,65535,65535],z:[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0],c:new f(32),J:new c(512),_:[],h:new c(32),$:[],w:new c(32768),C:[],v:[],d:new c(32768),D:[],u:new c(512),Q:[],r:new c(32768),s:new f(286),Y:new f(30),a:new f(19),t:new f(15e3),k:new c(65536),g:new c(32768)}})(),(function(){const c=l.H.m;for(var f=0;f<32768;f++){let m=f;m=(2863311530&m)>>>1|(1431655765&m)<<1,m=(3435973836&m)>>>2|(858993459&m)<<2,m=(4042322160&m)>>>4|(252645135&m)<<4,m=(4278255360&m)>>>8|(16711935&m)<<8,c.r[f]=(m>>>16|m<<16)>>>17}function h(m,b,w){for(;b--!=0;)m.push(0,w)}for(f=0;f<32;f++)c.q[f]=c.S[f]<<3|c.T[f],c.c[f]=c.p[f]<<4|c.z[f];h(c._,144,8),h(c._,112,9),h(c._,24,7),h(c._,8,8),l.H.n(c._,9),l.H.A(c._,9,c.J),l.H.l(c._,9),h(c.$,32,5),l.H.n(c.$,5),l.H.A(c.$,5,c.h),l.H.l(c.$,5),h(c.Q,19,0),h(c.C,286,0),h(c.D,30,0),h(c.v,320,0)})(),l.H.N})();function s(l){return[1,null,3,1,2,null,4][l.ctype]*l.depth}function a(l,c,f,h,m){let b=s(c);const w=Math.ceil(h*b/8);let v,I;b=Math.ceil(b/8);let S=l[f],E=0;if(S>1&&(l[f]=[0,0,1][S-2]),S==3)for(E=b;E<w;E++)l[E+1]=l[E+1]+(l[E+1-b]>>>1)&255;for(let P=0;P<m;P++)if(v=f+P*w,I=v+P+1,S=l[I-1],E=0,S==0)for(;E<w;E++)l[v+E]=l[I+E];else if(S==1){for(;E<b;E++)l[v+E]=l[I+E];for(;E<w;E++)l[v+E]=l[I+E]+l[v+E-b]}else if(S==2)for(;E<w;E++)l[v+E]=l[I+E]+l[v+E-w];else if(S==3){for(;E<b;E++)l[v+E]=l[I+E]+(l[v+E-w]>>>1);for(;E<w;E++)l[v+E]=l[I+E]+(l[v+E-w]+l[v+E-b]>>>1)}else{for(;E<b;E++)l[v+E]=l[I+E]+o(0,l[v+E-w],0);for(;E<w;E++)l[v+E]=l[I+E]+o(l[v+E-b],l[v+E-w],l[v+E-b-w])}return l}function o(l,c,f){const h=l+c-f,m=h-l,b=h-c,w=h-f;return m*m<=b*b&&m*m<=w*w?l:b*b<=w*w?c:f}function u(l,c,f){f.width=e.readUint(l,c),c+=4,f.height=e.readUint(l,c),c+=4,f.depth=l[c],c++,f.ctype=l[c],c++,f.compress=l[c],c++,f.filter=l[c],c++,f.interlace=l[c],c++}function d(l,c,f,h,m,b,w,v,I){const S=Math.min(c,m),E=Math.min(f,b);let P=0,A=0;for(let R=0;R<E;R++)for(let x=0;x<S;x++)if(w>=0&&v>=0?(P=R*c+x<<2,A=(v+R)*m+w+x<<2):(P=(-v+R)*c-w+x<<2,A=R*m+x<<2),I==0)h[A]=l[P],h[A+1]=l[P+1],h[A+2]=l[P+2],h[A+3]=l[P+3];else if(I==1){var O=l[P+3]*.00392156862745098,p=l[P]*O,y=l[P+1]*O,T=l[P+2]*O,k=h[A+3]*(1/255),M=h[A]*k,j=h[A+1]*k,C=h[A+2]*k;const g=1-O,_=O+k*g,L=_==0?0:1/_;h[A+3]=255*_,h[A+0]=(p+M*g)*L,h[A+1]=(y+j*g)*L,h[A+2]=(T+C*g)*L}else if(I==2)O=l[P+3],p=l[P],y=l[P+1],T=l[P+2],k=h[A+3],M=h[A],j=h[A+1],C=h[A+2],O==k&&p==M&&y==j&&T==C?(h[A]=0,h[A+1]=0,h[A+2]=0,h[A+3]=0):(h[A]=p,h[A+1]=y,h[A+2]=T,h[A+3]=O);else if(I==3){if(O=l[P+3],p=l[P],y=l[P+1],T=l[P+2],k=h[A+3],M=h[A],j=h[A+1],C=h[A+2],O==k&&p==M&&y==j&&T==C)continue;if(O<220&&k>20)return!1}return!0}return{decode:function(c){const f=new Uint8Array(c);let h=8;const m=e,b=m.readUshort,w=m.readUint,v={tabs:{},frames:[]},I=new Uint8Array(f.length);let S,E=0,P=0;const A=[137,80,78,71,13,10,26,10];for(var O=0;O<8;O++)if(f[O]!=A[O])throw"The input is not a PNG file!";for(;h<f.length;){const R=m.readUint(f,h);h+=4;const x=m.readASCII(f,h,4);if(h+=4,x=="IHDR")u(f,h,v);else if(x=="iCCP"){for(var p=h;f[p]!=0;)p++;m.readASCII(f,h,p-h),f[p+1];const g=f.slice(p+2,h+R);let _=null;try{_=r(g)}catch{_=i(g)}v.tabs[x]=_}else if(x=="CgBI")v.tabs[x]=f.slice(h,h+4);else if(x=="IDAT"){for(O=0;O<R;O++)I[E+O]=f[h+O];E+=R}else if(x=="acTL")v.tabs[x]={num_frames:w(f,h),num_plays:w(f,h+4)},S=new Uint8Array(f.length);else if(x=="fcTL"){P!=0&&((C=v.frames[v.frames.length-1]).data=n(v,S.slice(0,P),C.rect.width,C.rect.height),P=0);const g={x:w(f,h+12),y:w(f,h+16),width:w(f,h+4),height:w(f,h+8)};let _=b(f,h+22);_=b(f,h+20)/(_==0?100:_);const L={rect:g,delay:Math.round(1e3*_),dispose:f[h+24],blend:f[h+25]};v.frames.push(L)}else if(x=="fdAT"){for(O=0;O<R-4;O++)S[P+O]=f[h+O+4];P+=R-4}else if(x=="pHYs")v.tabs[x]=[m.readUint(f,h),m.readUint(f,h+4),f[h+8]];else if(x=="cHRM")for(v.tabs[x]=[],O=0;O<8;O++)v.tabs[x].push(m.readUint(f,h+4*O));else if(x=="tEXt"||x=="zTXt"){v.tabs[x]==null&&(v.tabs[x]={});var y=m.nextZero(f,h),T=m.readASCII(f,h,y-h),k=h+R-y-1;if(x=="tEXt")j=m.readASCII(f,y+1,k);else{var M=r(f.slice(y+2,y+2+k));j=m.readUTF8(M,0,M.length)}v.tabs[x][T]=j}else if(x=="iTXt"){v.tabs[x]==null&&(v.tabs[x]={}),y=0,p=h,y=m.nextZero(f,p),T=m.readASCII(f,p,y-p);const g=f[p=y+1];var j;f[p+1],p+=2,y=m.nextZero(f,p),m.readASCII(f,p,y-p),p=y+1,y=m.nextZero(f,p),m.readUTF8(f,p,y-p),k=R-((p=y+1)-h),g==0?j=m.readUTF8(f,p,k):(M=r(f.slice(p,p+k)),j=m.readUTF8(M,0,M.length)),v.tabs[x][T]=j}else if(x=="PLTE")v.tabs[x]=m.readBytes(f,h,R);else if(x=="hIST"){const g=v.tabs.PLTE.length/3;for(v.tabs[x]=[],O=0;O<g;O++)v.tabs[x].push(b(f,h+2*O))}else if(x=="tRNS")v.ctype==3?v.tabs[x]=m.readBytes(f,h,R):v.ctype==0?v.tabs[x]=b(f,h):v.ctype==2&&(v.tabs[x]=[b(f,h),b(f,h+2),b(f,h+4)]);else if(x=="gAMA")v.tabs[x]=m.readUint(f,h)/1e5;else if(x=="sRGB")v.tabs[x]=f[h];else if(x=="bKGD")v.ctype==0||v.ctype==4?v.tabs[x]=[b(f,h)]:v.ctype==2||v.ctype==6?v.tabs[x]=[b(f,h),b(f,h+2),b(f,h+4)]:v.ctype==3&&(v.tabs[x]=f[h]);else if(x=="IEND")break;h+=R,m.readUint(f,h),h+=4}var C;return P!=0&&((C=v.frames[v.frames.length-1]).data=n(v,S.slice(0,P),C.rect.width,C.rect.height)),v.data=n(v,I,v.width,v.height),delete v.compress,delete v.interlace,delete v.filter,v},toRGBA8:function(c){const f=c.width,h=c.height;if(c.tabs.acTL==null)return[t(c.data,f,h,c).buffer];const m=[];c.frames[0].data==null&&(c.frames[0].data=c.data);const b=f*h*4,w=new Uint8Array(b),v=new Uint8Array(b),I=new Uint8Array(b);for(let E=0;E<c.frames.length;E++){const P=c.frames[E],A=P.rect.x,O=P.rect.y,p=P.rect.width,y=P.rect.height,T=t(P.data,p,y,c);if(E!=0)for(var S=0;S<b;S++)I[S]=w[S];if(P.blend==0?d(T,p,y,w,f,h,A,O,0):P.blend==1&&d(T,p,y,w,f,h,A,O,1),m.push(w.buffer.slice(0)),P.dispose!=0){if(P.dispose==1)d(v,p,y,w,f,h,A,O,0);else if(P.dispose==2)for(S=0;S<b;S++)w[S]=I[S]}}return m},_paeth:o,_copyTile:d,_bin:e}})();(function(){const{_copyTile:e}=ze,{_bin:t}=ze,n=ze._paeth;var r={table:(function(){const p=new Uint32Array(256);for(let y=0;y<256;y++){let T=y;for(let k=0;k<8;k++)1&T?T=3988292384^T>>>1:T>>>=1;p[y]=T}return p})(),update(p,y,T,k){for(let M=0;M<k;M++)p=r.table[255&(p^y[T+M])]^p>>>8;return p},crc:(p,y,T)=>4294967295^r.update(4294967295,p,y,T)};function i(p,y,T,k){y[T]+=p[0]*k>>4,y[T+1]+=p[1]*k>>4,y[T+2]+=p[2]*k>>4,y[T+3]+=p[3]*k>>4}function s(p){return Math.max(0,Math.min(255,p))}function a(p,y){const T=p[0]-y[0],k=p[1]-y[1],M=p[2]-y[2],j=p[3]-y[3];return T*T+k*k+M*M+j*j}function o(p,y,T,k,M,j,C){C==null&&(C=1);const R=k.length,x=[];for(var g=0;g<R;g++){const V=k[g];x.push([V>>>0&255,V>>>8&255,V>>>16&255,V>>>24&255])}for(g=0;g<R;g++){let V=4294967295;for(var _=0,L=0;L<R;L++){var U=a(x[g],x[L]);L!=g&&U<V&&(V=U,_=L)}}const F=new Uint32Array(M.buffer),N=new Int16Array(y*T*4),W=[0,8,2,10,12,4,14,6,3,11,1,9,15,7,13,5];for(g=0;g<W.length;g++)W[g]=255*((W[g]+.5)/16-.5);for(let V=0;V<T;V++)for(let X=0;X<y;X++){var B;g=4*(V*y+X),C!=2?B=[s(p[g]+N[g]),s(p[g+1]+N[g+1]),s(p[g+2]+N[g+2]),s(p[g+3]+N[g+3])]:(U=W[4*(3&V)+(3&X)],B=[s(p[g]+U),s(p[g+1]+U),s(p[g+2]+U),s(p[g+3]+U)]),_=0;let Q=16777215;for(L=0;L<R;L++){const Y=a(B,x[L]);Y<Q&&(Q=Y,_=L)}const J=x[_],ee=[B[0]-J[0],B[1]-J[1],B[2]-J[2],B[3]-J[3]];C==1&&(X!=y-1&&i(ee,N,g+4,7),V!=T-1&&(X!=0&&i(ee,N,g+4*y-4,3),i(ee,N,g+4*y,5),X!=y-1&&i(ee,N,g+4*y+4,1))),j[g>>2]=_,F[g>>2]=k[_]}}function u(p,y,T,k,M){M==null&&(M={});const{crc:j}=r,C=t.writeUint,R=t.writeUshort,x=t.writeASCII;let g=8;const _=p.frames.length>1;let L,U=!1,F=33+(_?20:0);if(M.sRGB!=null&&(F+=13),M.pHYs!=null&&(F+=21),M.iCCP!=null&&(L=pako.deflate(M.iCCP),F+=21+L.length+4),p.ctype==3){for(var N=p.plte.length,W=0;W<N;W++)p.plte[W]>>>24!=255&&(U=!0);F+=8+3*N+4+(U?8+1*N+4:0)}for(var B=0;B<p.frames.length;B++)_&&(F+=38),F+=(J=p.frames[B]).cimg.length+12,B!=0&&(F+=4);F+=12;const V=new Uint8Array(F),X=[137,80,78,71,13,10,26,10];for(W=0;W<8;W++)V[W]=X[W];if(C(V,g,13),g+=4,x(V,g,"IHDR"),g+=4,C(V,g,y),g+=4,C(V,g,T),g+=4,V[g]=p.depth,g++,V[g]=p.ctype,g++,V[g]=0,g++,V[g]=0,g++,V[g]=0,g++,C(V,g,j(V,g-17,17)),g+=4,M.sRGB!=null&&(C(V,g,1),g+=4,x(V,g,"sRGB"),g+=4,V[g]=M.sRGB,g++,C(V,g,j(V,g-5,5)),g+=4),M.iCCP!=null){const ee=13+L.length;C(V,g,ee),g+=4,x(V,g,"iCCP"),g+=4,x(V,g,"ICC profile"),g+=11,g+=2,V.set(L,g),g+=L.length,C(V,g,j(V,g-(ee+4),ee+4)),g+=4}if(M.pHYs!=null&&(C(V,g,9),g+=4,x(V,g,"pHYs"),g+=4,C(V,g,M.pHYs[0]),g+=4,C(V,g,M.pHYs[1]),g+=4,V[g]=M.pHYs[2],g++,C(V,g,j(V,g-13,13)),g+=4),_&&(C(V,g,8),g+=4,x(V,g,"acTL"),g+=4,C(V,g,p.frames.length),g+=4,C(V,g,M.loop!=null?M.loop:0),g+=4,C(V,g,j(V,g-12,12)),g+=4),p.ctype==3){for(C(V,g,3*(N=p.plte.length)),g+=4,x(V,g,"PLTE"),g+=4,W=0;W<N;W++){const ee=3*W,Y=p.plte[W],G=255&Y,H=Y>>>8&255,te=Y>>>16&255;V[g+ee+0]=G,V[g+ee+1]=H,V[g+ee+2]=te}if(g+=3*N,C(V,g,j(V,g-3*N-4,3*N+4)),g+=4,U){for(C(V,g,N),g+=4,x(V,g,"tRNS"),g+=4,W=0;W<N;W++)V[g+W]=p.plte[W]>>>24&255;g+=N,C(V,g,j(V,g-N-4,N+4)),g+=4}}let Q=0;for(B=0;B<p.frames.length;B++){var J=p.frames[B];_&&(C(V,g,26),g+=4,x(V,g,"fcTL"),g+=4,C(V,g,Q++),g+=4,C(V,g,J.rect.width),g+=4,C(V,g,J.rect.height),g+=4,C(V,g,J.rect.x),g+=4,C(V,g,J.rect.y),g+=4,R(V,g,k[B]),g+=2,R(V,g,1e3),g+=2,V[g]=J.dispose,g++,V[g]=J.blend,g++,C(V,g,j(V,g-30,30)),g+=4);const ee=J.cimg;C(V,g,(N=ee.length)+(B==0?0:4)),g+=4;const Y=g;x(V,g,B==0?"IDAT":"fdAT"),g+=4,B!=0&&(C(V,g,Q++),g+=4),V.set(ee,g),g+=N,C(V,g,j(V,Y,g-Y)),g+=4}return C(V,g,0),g+=4,x(V,g,"IEND"),g+=4,C(V,g,j(V,g-4,4)),g+=4,V.buffer}function d(p,y,T){for(let k=0;k<p.frames.length;k++){const M=p.frames[k];M.rect.width;const j=M.rect.height,C=new Uint8Array(j*M.bpl+j);M.cimg=h(M.img,j,M.bpp,M.bpl,C,y,T)}}function l(p,y,T,k,M){const j=M[0],C=M[1],R=M[2],x=M[3],g=M[4],_=M[5];let L=6,U=8,F=255;for(var N=0;N<p.length;N++){const ue=new Uint8Array(p[N]);for(var W=ue.length,B=0;B<W;B+=4)F&=ue[B+3]}const V=F!=255,X=(function(ie,ne,be,Pe,he,Me){const me=[];for(var ae=0;ae<ie.length;ae++){const Ce=new Uint8Array(ie[ae]),$e=new Uint32Array(Ce.buffer);var De;let Re=0,rt=0,Ke=ne,Pt=be,ds=Pe?1:0;if(ae!=0){const By=Me||Pe||ae==1||me[ae-2].dispose!=0?1:2;let hs=0,Ic=1e9;for(let An=0;An<By;An++){var ft=new Uint8Array(ie[ae-1-An]);const zy=new Uint32Array(ie[ae-1-An]);let dt=ne,ht=be,Kt=-1,Sn=-1;for(let Ct=0;Ct<be;Ct++)for(let Et=0;Et<ne;Et++)$e[Ae=Ct*ne+Et]!=zy[Ae]&&(Et<dt&&(dt=Et),Et>Kt&&(Kt=Et),Ct<ht&&(ht=Ct),Ct>Sn&&(Sn=Ct));Kt==-1&&(dt=ht=Kt=Sn=0),he&&((1&dt)==1&&dt--,(1&ht)==1&&ht--);const kc=(Kt-dt+1)*(Sn-ht+1);kc<Ic&&(Ic=kc,hs=An,Re=dt,rt=ht,Ke=Kt-dt+1,Pt=Sn-ht+1)}ft=new Uint8Array(ie[ae-1-hs]),hs==1&&(me[ae-1].dispose=2),De=new Uint8Array(Ke*Pt*4),e(ft,ne,be,De,Ke,Pt,-Re,-rt,0),ds=e(Ce,ne,be,De,Ke,Pt,-Re,-rt,3)?1:0,ds==1?f(Ce,ne,be,De,{x:Re,y:rt,width:Ke,height:Pt}):e(Ce,ne,be,De,Ke,Pt,-Re,-rt,0)}else De=Ce.slice(0);me.push({rect:{x:Re,y:rt,width:Ke,height:Pt},img:De,blend:ds,dispose:0})}if(Pe)for(ae=0;ae<me.length;ae++){if((Tt=me[ae]).blend==1)continue;const Ce=Tt.rect,$e=me[ae-1].rect,Re=Math.min(Ce.x,$e.x),rt=Math.min(Ce.y,$e.y),Ke={x:Re,y:rt,width:Math.max(Ce.x+Ce.width,$e.x+$e.width)-Re,height:Math.max(Ce.y+Ce.height,$e.y+$e.height)-rt};me[ae-1].dispose=1,ae-1!=0&&c(ie,ne,be,me,ae-1,Ke,he),c(ie,ne,be,me,ae,Ke,he)}let cr=0;if(ie.length!=1)for(var Ae=0;Ae<me.length;Ae++){var Tt;cr+=(Tt=me[Ae]).rect.width*Tt.rect.height}return me})(p,y,T,j,C,R),Q={},J=[],ee=[];if(k!=0){const ue=[];for(B=0;B<X.length;B++)ue.push(X[B].img.buffer);const ie=(function(he){let Me=0;for(var me=0;me<he.length;me++)Me+=he[me].byteLength;const ae=new Uint8Array(Me);let De=0;for(me=0;me<he.length;me++){const ft=new Uint8Array(he[me]),cr=ft.length;for(let Ae=0;Ae<cr;Ae+=4){let Tt=ft[Ae],Ce=ft[Ae+1],$e=ft[Ae+2];const Re=ft[Ae+3];Re==0&&(Tt=Ce=$e=0),ae[De+Ae]=Tt,ae[De+Ae+1]=Ce,ae[De+Ae+2]=$e,ae[De+Ae+3]=Re}De+=cr}return ae.buffer})(ue),ne=b(ie,k);for(B=0;B<ne.plte.length;B++)J.push(ne.plte[B].est.rgba);let be=0;for(B=0;B<X.length;B++){const Pe=(G=X[B]).img.length;var Y=new Uint8Array(ne.inds.buffer,be>>2,Pe>>2);ee.push(Y);const he=new Uint8Array(ne.abuf,be,Pe);_&&o(G.img,G.rect.width,G.rect.height,J,he,Y),G.img.set(he),be+=Pe}}else for(N=0;N<X.length;N++){var G=X[N];const ue=new Uint32Array(G.img.buffer);var H=G.rect.width;for(W=ue.length,Y=new Uint8Array(W),ee.push(Y),B=0;B<W;B++){const ie=ue[B];if(B!=0&&ie==ue[B-1])Y[B]=Y[B-1];else if(B>H&&ie==ue[B-H])Y[B]=Y[B-H];else{let ne=Q[ie];if(ne==null&&(Q[ie]=ne=J.length,J.push(ie),J.length>=300))break;Y[B]=ne}}}const te=J.length;for(te<=256&&g==0&&(U=te<=2?1:te<=4?2:te<=16?4:8,U=Math.max(U,x)),N=0;N<X.length;N++){(G=X[N]).rect.x,G.rect.y,H=G.rect.width;const ue=G.rect.height;let ie=G.img;new Uint32Array(ie.buffer);let ne=4*H,be=4;if(te<=256&&g==0){ne=Math.ceil(U*H/8);var ge=new Uint8Array(ne*ue);const Pe=ee[N];for(let he=0;he<ue;he++){B=he*ne;const Me=he*H;if(U==8)for(var le=0;le<H;le++)ge[B+le]=Pe[Me+le];else if(U==4)for(le=0;le<H;le++)ge[B+(le>>1)]|=Pe[Me+le]<<4-4*(1&le);else if(U==2)for(le=0;le<H;le++)ge[B+(le>>2)]|=Pe[Me+le]<<6-2*(3&le);else if(U==1)for(le=0;le<H;le++)ge[B+(le>>3)]|=Pe[Me+le]<<7-1*(7&le)}ie=ge,L=3,be=1}else if(V==0&&X.length==1){ge=new Uint8Array(H*ue*3);const Pe=H*ue;for(B=0;B<Pe;B++){const he=3*B,Me=4*B;ge[he]=ie[Me],ge[he+1]=ie[Me+1],ge[he+2]=ie[Me+2]}ie=ge,L=2,be=3,ne=3*H}G.img=ie,G.bpl=ne,G.bpp=be}return{ctype:L,depth:U,plte:J,frames:X}}function c(p,y,T,k,M,j,C){const R=Uint8Array,x=Uint32Array,g=new R(p[M-1]),_=new x(p[M-1]),L=M+1<p.length?new R(p[M+1]):null,U=new R(p[M]),F=new x(U.buffer);let N=y,W=T,B=-1,V=-1;for(let Q=0;Q<j.height;Q++)for(let J=0;J<j.width;J++){const ee=j.x+J,Y=j.y+Q,G=Y*y+ee,H=F[G];H==0||k[M-1].dispose==0&&_[G]==H&&(L==null||L[4*G+3]!=0)||(ee<N&&(N=ee),ee>B&&(B=ee),Y<W&&(W=Y),Y>V&&(V=Y))}B==-1&&(N=W=B=V=0),C&&((1&N)==1&&N--,(1&W)==1&&W--),j={x:N,y:W,width:B-N+1,height:V-W+1};const X=k[M];X.rect=j,X.blend=1,X.img=new Uint8Array(j.width*j.height*4),k[M-1].dispose==0?(e(g,y,T,X.img,j.width,j.height,-j.x,-j.y,0),f(U,y,T,X.img,j)):e(U,y,T,X.img,j.width,j.height,-j.x,-j.y,0)}function f(p,y,T,k,M){e(p,y,T,k,M.width,M.height,-M.x,-M.y,2)}function h(p,y,T,k,M,j,C){const R=[];let x,g=[0,1,2,3,4];j!=-1?g=[j]:(y*k>5e5||T==1)&&(g=[0]),C&&(x={level:0});const _=iy;for(var L=0;L<g.length;L++){for(let N=0;N<y;N++)m(M,p,N,k,T,g[L]);R.push(_.deflate(M,x))}let U,F=1e9;for(L=0;L<R.length;L++)R[L].length<F&&(U=L,F=R[L].length);return R[U]}function m(p,y,T,k,M,j){const C=T*k;let R=C+T;if(p[R]=j,R++,j==0)if(k<500)for(var x=0;x<k;x++)p[R+x]=y[C+x];else p.set(new Uint8Array(y.buffer,C,k),R);else if(j==1){for(x=0;x<M;x++)p[R+x]=y[C+x];for(x=M;x<k;x++)p[R+x]=y[C+x]-y[C+x-M]+256&255}else if(T==0){for(x=0;x<M;x++)p[R+x]=y[C+x];if(j==2)for(x=M;x<k;x++)p[R+x]=y[C+x];if(j==3)for(x=M;x<k;x++)p[R+x]=y[C+x]-(y[C+x-M]>>1)+256&255;if(j==4)for(x=M;x<k;x++)p[R+x]=y[C+x]-n(y[C+x-M],0,0)+256&255}else{if(j==2)for(x=0;x<k;x++)p[R+x]=y[C+x]+256-y[C+x-k]&255;if(j==3){for(x=0;x<M;x++)p[R+x]=y[C+x]+256-(y[C+x-k]>>1)&255;for(x=M;x<k;x++)p[R+x]=y[C+x]+256-(y[C+x-k]+y[C+x-M]>>1)&255}if(j==4){for(x=0;x<M;x++)p[R+x]=y[C+x]+256-n(0,y[C+x-k],0)&255;for(x=M;x<k;x++)p[R+x]=y[C+x]+256-n(y[C+x-M],y[C+x-k],y[C+x-M-k])&255}}}function b(p,y){const T=new Uint8Array(p),k=T.slice(0),M=new Uint32Array(k.buffer),j=w(k,y),C=j[0],R=j[1],x=T.length,g=new Uint8Array(x>>2);let _;if(T.length<2e7)for(var L=0;L<x;L+=4)_=v(C,U=T[L]*(1/255),F=T[L+1]*(1/255),N=T[L+2]*(1/255),W=T[L+3]*(1/255)),g[L>>2]=_.ind,M[L>>2]=_.est.rgba;else for(L=0;L<x;L+=4){var U=T[L]*.00392156862745098,F=T[L+1]*(1/255),N=T[L+2]*(1/255),W=T[L+3]*(1/255);for(_=C;_.left;)_=I(_.est,U,F,N,W)<=0?_.left:_.right;g[L>>2]=_.ind,M[L>>2]=_.est.rgba}return{abuf:k.buffer,inds:g,plte:R}}function w(p,y,T){T==null&&(T=1e-4);const k=new Uint32Array(p.buffer),M={i0:0,i1:p.length,bst:null,est:null,tdst:0,left:null,right:null};M.bst=P(p,M.i0,M.i1),M.est=A(M.bst);const j=[M];for(;j.length<y;){let R=0,x=0;for(var C=0;C<j.length;C++)j[C].est.L>R&&(R=j[C].est.L,x=C);if(R<T)break;const g=j[x],_=S(p,k,g.i0,g.i1,g.est.e,g.est.eMq255);if(g.i0>=_||g.i1<=_){g.est.L=0;continue}const L={i0:g.i0,i1:_,bst:null,est:null,tdst:0,left:null,right:null};L.bst=P(p,L.i0,L.i1),L.est=A(L.bst);const U={i0:_,i1:g.i1,bst:null,est:null,tdst:0,left:null,right:null};for(U.bst={R:[],m:[],N:g.bst.N-L.bst.N},C=0;C<16;C++)U.bst.R[C]=g.bst.R[C]-L.bst.R[C];for(C=0;C<4;C++)U.bst.m[C]=g.bst.m[C]-L.bst.m[C];U.est=A(U.bst),g.left=L,g.right=U,j[x]=L,j.push(U)}for(j.sort(((R,x)=>x.bst.N-R.bst.N)),C=0;C<j.length;C++)j[C].ind=C;return[M,j]}function v(p,y,T,k,M){if(p.left==null)return p.tdst=(function(L,U,F,N,W){const B=U-L[0],V=F-L[1],X=N-L[2],Q=W-L[3];return B*B+V*V+X*X+Q*Q})(p.est.q,y,T,k,M),p;const j=I(p.est,y,T,k,M);let C=p.left,R=p.right;j>0&&(C=p.right,R=p.left);const x=v(C,y,T,k,M);if(x.tdst<=j*j)return x;const g=v(R,y,T,k,M);return g.tdst<x.tdst?g:x}function I(p,y,T,k,M){const{e:j}=p;return j[0]*y+j[1]*T+j[2]*k+j[3]*M-p.eMq}function S(p,y,T,k,M,j){for(k-=4;T<k;){for(;E(p,T,M)<=j;)T+=4;for(;E(p,k,M)>j;)k-=4;if(T>=k)break;const C=y[T>>2];y[T>>2]=y[k>>2],y[k>>2]=C,T+=4,k-=4}for(;E(p,T,M)>j;)T-=4;return T+4}function E(p,y,T){return p[y]*T[0]+p[y+1]*T[1]+p[y+2]*T[2]+p[y+3]*T[3]}function P(p,y,T){const k=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],M=[0,0,0,0],j=T-y>>2;for(let C=y;C<T;C+=4){const R=p[C]*.00392156862745098,x=p[C+1]*(1/255),g=p[C+2]*(1/255),_=p[C+3]*(1/255);M[0]+=R,M[1]+=x,M[2]+=g,M[3]+=_,k[0]+=R*R,k[1]+=R*x,k[2]+=R*g,k[3]+=R*_,k[5]+=x*x,k[6]+=x*g,k[7]+=x*_,k[10]+=g*g,k[11]+=g*_,k[15]+=_*_}return k[4]=k[1],k[8]=k[2],k[9]=k[6],k[12]=k[3],k[13]=k[7],k[14]=k[11],{R:k,m:M,N:j}}function A(p){const{R:y}=p,{m:T}=p,{N:k}=p,M=T[0],j=T[1],C=T[2],R=T[3],x=k==0?0:1/k,g=[y[0]-M*M*x,y[1]-M*j*x,y[2]-M*C*x,y[3]-M*R*x,y[4]-j*M*x,y[5]-j*j*x,y[6]-j*C*x,y[7]-j*R*x,y[8]-C*M*x,y[9]-C*j*x,y[10]-C*C*x,y[11]-C*R*x,y[12]-R*M*x,y[13]-R*j*x,y[14]-R*C*x,y[15]-R*R*x],_=g,L=O;let U=[Math.random(),Math.random(),Math.random(),Math.random()],F=0,N=0;if(k!=0)for(let B=0;B<16&&(U=L.multVec(_,U),N=Math.sqrt(L.dot(U,U)),U=L.sml(1/N,U),!(B!=0&&Math.abs(N-F)<1e-9));B++)F=N;const W=[M*x,j*x,C*x,R*x];return{Cov:g,q:W,e:U,L:F,eMq255:L.dot(L.sml(255,W),U),eMq:L.dot(U,W),rgba:(Math.round(255*W[3])<<24|Math.round(255*W[2])<<16|Math.round(255*W[1])<<8|Math.round(255*W[0])<<0)>>>0}}var O={multVec:(p,y)=>[p[0]*y[0]+p[1]*y[1]+p[2]*y[2]+p[3]*y[3],p[4]*y[0]+p[5]*y[1]+p[6]*y[2]+p[7]*y[3],p[8]*y[0]+p[9]*y[1]+p[10]*y[2]+p[11]*y[3],p[12]*y[0]+p[13]*y[1]+p[14]*y[2]+p[15]*y[3]],dot:(p,y)=>p[0]*y[0]+p[1]*y[1]+p[2]*y[2]+p[3]*y[3],sml:(p,y)=>[p*y[0],p*y[1],p*y[2],p*y[3]]};ze.encode=function(y,T,k,M,j,C,R){M==null&&(M=0),R==null&&(R=!1);const x=l(y,T,k,M,[!1,!1,!1,0,R,!1]);return d(x,-1),u(x,T,k,j,C)},ze.encodeLL=function(y,T,k,M,j,C,R,x){const g={ctype:0+(M==1?0:2)+(j==0?0:4),depth:C,frames:[]},_=(M+j)*C,L=_*T;for(let U=0;U<y.length;U++)g.frames.push({rect:{x:0,y:0,width:T,height:k},img:new Uint8Array(y[U]),blend:0,dispose:1,bpp:Math.ceil(_/8),bpl:Math.ceil(L/8)});return d(g,0,!0),u(g,T,k,R,x)},ze.encode.compress=l,ze.encode.dither=o,ze.quantize=b,ze.quantize.getKDtree=w,ze.quantize.getNearest=v})();const ic={toArrayBuffer(e,t){const n=e.width,r=e.height,i=n<<2,s=e.getContext("2d").getImageData(0,0,n,r),a=new Uint32Array(s.data.buffer),o=(32*n+31)/32<<2,u=o*r,d=122+u,l=new ArrayBuffer(d),c=new DataView(l),f=1<<20;let h,m,b,w,v=f,I=0,S=0,E=0;function P(p){c.setUint16(S,p,!0),S+=2}function A(p){c.setUint32(S,p,!0),S+=4}function O(p){S+=p}P(19778),A(d),O(4),A(122),A(108),A(n),A(-r>>>0),P(1),P(32),A(3),A(u),A(2835),A(2835),O(8),A(16711680),A(65280),A(255),A(4278190080),A(1466527264),(function p(){for(;I<r&&v>0;){for(w=122+I*o,h=0;h<i;)v--,m=a[E++],b=m>>>24,c.setUint32(w+h,m<<8|b),h+=4;I++}E<a.length?(v=f,setTimeout(p,ic._dly)):t(l)})()},toBlob(e,t){this.toArrayBuffer(e,(n=>{t(new Blob([n],{type:"image/bmp"}))}))},_dly:9};var Ie={CHROME:"CHROME",FIREFOX:"FIREFOX",DESKTOP_SAFARI:"DESKTOP_SAFARI",IE:"IE",IOS:"IOS",ETC:"ETC"},sy={[Ie.CHROME]:16384,[Ie.FIREFOX]:11180,[Ie.DESKTOP_SAFARI]:16384,[Ie.IE]:8192,[Ie.IOS]:4096,[Ie.ETC]:8192};const ls=typeof window<"u",sc=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,sr=ls&&window.cordova&&window.cordova.require&&window.cordova.require("cordova/modulemapper"),ay=(ls||sc)&&(sr&&sr.getOriginalSymbol(window,"File")||typeof File<"u"&&File),ac=(ls||sc)&&(sr&&sr.getOriginalSymbol(window,"FileReader")||typeof FileReader<"u"&&FileReader);function us(e,t,n=Date.now()){return new Promise((r=>{const i=e.split(","),s=i[0].match(/:(.*?);/)[1],a=globalThis.atob(i[1]);let o=a.length;const u=new Uint8Array(o);for(;o--;)u[o]=a.charCodeAt(o);const d=new Blob([u],{type:s});d.name=t,d.lastModified=n,r(d)}))}function oc(e){return new Promise(((t,n)=>{const r=new ac;r.onload=()=>t(r.result),r.onerror=i=>n(i),r.readAsDataURL(e)}))}function lc(e){return new Promise(((t,n)=>{const r=new Image;r.onload=()=>t(r),r.onerror=i=>n(i),r.src=e}))}function St(){if(St.cachedResult!==void 0)return St.cachedResult;let e=Ie.ETC;const{userAgent:t}=navigator;return/Chrom(e|ium)/i.test(t)?e=Ie.CHROME:/iP(ad|od|hone)/i.test(t)&&/WebKit/i.test(t)?e=Ie.IOS:/Safari/i.test(t)?e=Ie.DESKTOP_SAFARI:/Firefox/i.test(t)?e=Ie.FIREFOX:(/MSIE/i.test(t)||document.documentMode)&&(e=Ie.IE),St.cachedResult=e,St.cachedResult}function uc(e,t){const n=St(),r=sy[n];let i=e,s=t,a=i*s;const o=i>s?s/i:i/s;for(;a>r*r;){const u=(r+i)/2,d=(r+s)/2;u<d?(s=d,i=d*o):(s=u*o,i=u),a=i*s}return{width:i,height:s}}function ar(e,t){let n,r;try{if(n=new OffscreenCanvas(e,t),r=n.getContext("2d"),r===null)throw new Error("getContext of OffscreenCanvas returns null")}catch{n=document.createElement("canvas"),r=n.getContext("2d")}return n.width=e,n.height=t,[n,r]}function cc(e,t){const{width:n,height:r}=uc(e.width,e.height),[i,s]=ar(n,r);return t&&/jpe?g/.test(t)&&(s.fillStyle="white",s.fillRect(0,0,i.width,i.height)),s.drawImage(e,0,0,i.width,i.height),i}function or(){return or.cachedResult!==void 0||(or.cachedResult=["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&typeof document<"u"&&"ontouchend"in document),or.cachedResult}function lr(e,t={}){return new Promise((function(n,r){let i,s;var a=function(){try{return s=cc(i,t.fileType||e.type),n([i,s])}catch(u){return r(u)}},o=function(u){try{var d=function(l){try{throw l}catch(c){return r(c)}};try{let l;return oc(e).then((function(c){try{return l=c,lc(l).then((function(f){try{return i=f,(function(){try{return a()}catch(h){return r(h)}})()}catch(h){return d(h)}}),d)}catch(f){return d(f)}}),d)}catch(l){d(l)}}catch(l){return r(l)}};try{if(or()||[Ie.DESKTOP_SAFARI,Ie.MOBILE_SAFARI].includes(St()))throw new Error("Skip createImageBitmap on IOS and Safari");return createImageBitmap(e).then((function(u){try{return i=u,a()}catch{return o()}}),o)}catch{o()}}))}function ur(e,t,n,r,i=1){return new Promise((function(s,a){let o;if(t==="image/png"){let d,l,c;return d=e.getContext("2d"),{data:l}=d.getImageData(0,0,e.width,e.height),c=ze.encode([l.buffer],e.width,e.height,4096*i),o=new Blob([c],{type:t}),o.name=n,o.lastModified=r,u.call(this)}{let d=function(){return u.call(this)};if(t==="image/bmp")return new Promise((l=>ic.toBlob(e,l))).then((function(l){try{return o=l,o.name=n,o.lastModified=r,d.call(this)}catch(c){return a(c)}}).bind(this),a);{let l=function(){return d.call(this)};if(typeof OffscreenCanvas=="function"&&e instanceof OffscreenCanvas)return e.convertToBlob({type:t,quality:i}).then((function(c){try{return o=c,o.name=n,o.lastModified=r,l.call(this)}catch(f){return a(f)}}).bind(this),a);{let c;return c=e.toDataURL(t,i),us(c,n,r).then((function(f){try{return o=f,l.call(this)}catch(h){return a(h)}}).bind(this),a)}}}function u(){return s(o)}}))}function Ge(e){e.width=0,e.height=0}function Gt(){return new Promise((function(e,t){let n,r,i,s;return Gt.cachedResult!==void 0?e(Gt.cachedResult):us("data:image/jpeg;base64,/9j/4QAiRXhpZgAATU0AKgAAAAgAAQESAAMAAAABAAYAAAAAAAD/2wCEAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAf/AABEIAAEAAgMBEQACEQEDEQH/xABKAAEAAAAAAAAAAAAAAAAAAAALEAEAAAAAAAAAAAAAAAAAAAAAAQEAAAAAAAAAAAAAAAAAAAAAEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwA/8H//2Q==","test.jpg",Date.now()).then((function(a){try{return n=a,lr(n).then((function(o){try{return r=o[1],ur(r,n.type,n.name,n.lastModified).then((function(u){try{return i=u,Ge(r),lr(i).then((function(d){try{return s=d[0],Gt.cachedResult=s.width===1&&s.height===2,e(Gt.cachedResult)}catch(l){return t(l)}}),t)}catch(d){return t(d)}}),t)}catch(u){return t(u)}}),t)}catch(o){return t(o)}}),t)}))}function fc(e){return new Promise(((t,n)=>{const r=new ac;r.onload=i=>{const s=new DataView(i.target.result);if(s.getUint16(0,!1)!=65496)return t(-2);const a=s.byteLength;let o=2;for(;o<a;){if(s.getUint16(o+2,!1)<=8)return t(-1);const u=s.getUint16(o,!1);if(o+=2,u==65505){if(s.getUint32(o+=2,!1)!=1165519206)return t(-1);const d=s.getUint16(o+=6,!1)==18761;o+=s.getUint32(o+4,d);const l=s.getUint16(o,d);o+=2;for(let c=0;c<l;c++)if(s.getUint16(o+12*c,d)==274)return t(s.getUint16(o+12*c+8,d))}else{if((65280&u)!=65280)break;o+=s.getUint16(o,!1)}}return t(-1)},r.onerror=i=>n(i),r.readAsArrayBuffer(e)}))}function dc(e,t){const{width:n}=e,{height:r}=e,{maxWidthOrHeight:i}=t;let s,a=e;return isFinite(i)&&(n>i||r>i)&&([a,s]=ar(n,r),n>r?(a.width=i,a.height=r/n*i):(a.width=n/r*i,a.height=i),s.drawImage(e,0,0,a.width,a.height),Ge(e)),a}function hc(e,t){const{width:n}=e,{height:r}=e,[i,s]=ar(n,r);switch(t>4&&t<9?(i.width=r,i.height=n):(i.width=n,i.height=r),t){case 2:s.transform(-1,0,0,1,n,0);break;case 3:s.transform(-1,0,0,-1,n,r);break;case 4:s.transform(1,0,0,-1,0,r);break;case 5:s.transform(0,1,1,0,0,0);break;case 6:s.transform(0,1,-1,0,r,0);break;case 7:s.transform(0,-1,-1,0,r,n);break;case 8:s.transform(0,-1,1,0,0,n)}return s.drawImage(e,0,0,n,r),Ge(e),i}function mc(e,t,n=0){return new Promise((function(r,i){let s,a,o,u,d,l,c,f,h,m,b,w,v,I,S,E,P,A,O,p;function y(k=5){if(t.signal&&t.signal.aborted)throw t.signal.reason;s+=k,t.onProgress(Math.min(s,100))}function T(k){if(t.signal&&t.signal.aborted)throw t.signal.reason;s=Math.min(Math.max(k,s),100),t.onProgress(s)}return s=n,a=t.maxIteration||10,o=1024*t.maxSizeMB*1024,y(),lr(e,t).then((function(k){try{return[,u]=k,y(),d=dc(u,t),y(),new Promise((function(M,j){var C;if(!(C=t.exifOrientation))return fc(e).then((function(x){try{return C=x,R.call(this)}catch(g){return j(g)}}).bind(this),j);function R(){return M(C)}return R.call(this)})).then((function(M){try{return l=M,y(),Gt().then((function(j){try{return c=j?d:hc(d,l),y(),f=t.initialQuality||1,h=t.fileType||e.type,ur(c,h,e.name,e.lastModified,f).then((function(C){try{{let x=function(){if(a--&&(S>o||S>v)){let _,L;return _=p?.95*O.width:O.width,L=p?.95*O.height:O.height,[P,A]=ar(_,L),A.drawImage(O,0,0,_,L),f*=h==="image/png"?.85:.95,ur(P,h,e.name,e.lastModified,f).then((function(U){try{return E=U,Ge(O),O=P,S=E.size,T(Math.min(99,Math.floor((I-S)/(I-o)*100))),x}catch(F){return i(F)}}),i)}return[1]},g=function(){return Ge(O),Ge(P),Ge(d),Ge(c),Ge(u),T(100),r(E)};if(m=C,y(),b=m.size>o,w=m.size>e.size,!b&&!w)return T(100),r(m);var R;return v=e.size,I=m.size,S=I,O=c,p=!t.alwaysKeepResolution&&b,(R=(function(_){for(;_;){if(_.then)return void _.then(R,i);try{if(_.pop){if(_.length)return _.pop()?g.call(this):_;_=x}else _=_.call(this)}catch(L){return i(L)}}}).bind(this))(x)}}catch(x){return i(x)}}).bind(this),i)}catch(C){return i(C)}}).bind(this),i)}catch(j){return i(j)}}).bind(this),i)}catch(M){return i(M)}}).bind(this),i)}))}const oy=`
571
571
  let scriptImported = false
572
572
  self.addEventListener('message', async (e) => {
573
573
  const { file, id, imageCompressionLibUrl, options } = e.data
@@ -586,4 +586,4 @@ self.addEventListener('message', async (e) => {
586
586
  self.postMessage({ error: e.message + '\\n' + e.stack, id })
587
587
  }
588
588
  })
589
- `;let cs;function ly(e,t){return new Promise(((n,r)=>{cs||(cs=(function(a){const o=[];return o.push(a),URL.createObjectURL(new Blob(o))})(oy));const i=new Worker(cs);i.addEventListener("message",(function(a){if(t.signal&&t.signal.aborted)i.terminate();else if(a.data.progress===void 0){if(a.data.error)return r(new Error(a.data.error)),void i.terminate();n(a.data.file),i.terminate()}else t.onProgress(a.data.progress)})),i.addEventListener("error",r),t.signal&&t.signal.addEventListener("abort",(()=>{r(t.signal.reason),i.terminate()})),i.postMessage({file:e,imageCompressionLibUrl:t.libURL,options:{...t,onProgress:void 0,signal:void 0}})}))}function xe(e,t){return new Promise((function(n,r){let i,s,a,o,u,d;if(i={...t},a=0,{onProgress:o}=i,i.maxSizeMB=i.maxSizeMB||Number.POSITIVE_INFINITY,u=typeof i.useWebWorker!="boolean"||i.useWebWorker,delete i.useWebWorker,i.onProgress=h=>{a=h,typeof o=="function"&&o(a)},!(e instanceof Blob||e instanceof ay))return r(new Error("The file given is not an instance of Blob or File"));if(!/^image/.test(e.type))return r(new Error("The file given is not an image"));if(d=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,!u||typeof Worker!="function"||d)return mc(e,i).then((function(h){try{return s=h,f.call(this)}catch(m){return r(m)}}).bind(this),r);var l=(function(){try{return f.call(this)}catch(h){return r(h)}}).bind(this),c=function(h){try{return mc(e,i).then((function(m){try{return s=m,l()}catch(b){return r(b)}}),r)}catch(m){return r(m)}};try{return i.libURL=i.libURL||"https://cdn.jsdelivr.net/npm/browser-image-compression@2.0.2/dist/browser-image-compression.js",ly(e,i).then((function(h){try{return s=h,l()}catch{return c()}}),c)}catch{c()}function f(){try{s.name=e.name,s.lastModified=e.lastModified}catch{}try{i.preserveExif&&e.type==="image/jpeg"&&(!i.fileType||i.fileType&&i.fileType===e.type)&&(s=rc(e,s))}catch{}return n(s)}}))}xe.getDataUrlFromFile=oc,xe.getFilefromDataUrl=us,xe.loadImage=lc,xe.drawImageInCanvas=cc,xe.drawFileInCanvas=lr,xe.canvasToFile=ur,xe.getExifOrientation=fc,xe.handleMaxWidthOrHeight=dc,xe.followExifOrientation=hc,xe.cleanupCanvasMemory=Ge,xe.isAutoOrientationInBrowser=Gt,xe.approximateBelowMaximumCanvasSizeOfBrowser=uc,xe.copyExifWithoutOrientation=rc,xe.getBrowserName=St,xe.version="2.0.2";const pc=e=>{if(!e||typeof e!="string")return"unknown";const t=[".jpg",".jpeg",".png",".gif",".bmp",".webp",".svg"],n=[".mp4",".avi",".mov",".wmv",".flv",".mkv",".webm"];for(const r of t)if(e.toLowerCase().includes(r))return"image";for(const r of n)if(e.toLowerCase().includes(r))return"video";return"unknown"};async function gc(e,t,n){if(pc(e.name)!=="image")return e;const r={maxSizeMB:1,maxWidthOrHeight:1920,useWebWorker:!0,onProgress:i=>n(i)};try{t(!0);const i=await xe(e,r);return i instanceof File?i:new File([i],e.name,{type:e.type})}catch(i){return console.error("Compression failed; using original file:",i),e}finally{t(!1)}}async function yc(e,t,n,r,i){e.preventDefault();for(const s of e.dataTransfer.items)if(s.kind==="file"){const a=s.getAsFile();if(!a)continue;const o=await gc(a,r,i);t(o),n(o.name)}}async function vc(e,t,n,r,i){const s=e.target.files?.[0];if(!s)return;const a=await gc(s,r,i);t(a),n(a.name)}function bc(e,t){e.preventDefault(),t.current&&(t.current.style.borderColor="blue")}function xc(e,t){e.preventDefault(),t.current&&(t.current.style.borderColor="grey")}const wc={width:"100%",height:"100%",objectFit:"cover",borderRadius:"10px"};function uy({progress:e=null}){const t=e!==null?e/100*360:0;return D.jsx("div",{className:je.donutContainer,children:D.jsx("div",{className:je.donutOuter,style:{background:`conic-gradient(rgb(59, 130, 246) ${t}deg, transparent 0)`},children:D.jsx("div",{className:je.donutInner,children:D.jsxs("div",{children:[D.jsx("div",{style:{fontStyle:"italic",fontSize:"13px"},children:"progress"}),D.jsx("div",{style:{fontSize:"1.25rem",fontWeight:"bold"},children:e!==null&&`${e}%`})]})})})})}function Ac({mediaBlock:e,modifyMedia:t}){const[n,r]=z.useState(""),[i,s]=z.useState(""),[a,o]=z.useState(""),[u,d]=z.useState(""),[l,c]=z.useState(!1),[f,h]=z.useState(null),m=z.useRef(null);z.useEffect(()=>{window.addEventListener("dragover",w=>w.preventDefault()),window.addEventListener("drop",w=>w.preventDefault())},[]),z.useEffect(()=>{r("To remove image or video component, refresh first."),e.data.src!==""&&(s(e.data.src),o(e.type))},[e.data.src,e.type]),z.useEffect(()=>{if(i&&i instanceof File){const w=URL.createObjectURL(i);e.type==="image"?t({imageBlockId:e.id,src:w,alt:e.data.alt,caption:e.data.caption}):e.type==="video"&&t({videoBlockId:e.id,src:w,provider:e.data.provider})}u&&o(pc(u))},[i]);const b=()=>{s(""),d(""),e.type==="image"?t({imageBlockId:e.id,src:"",alt:e.data.alt,caption:e.data.caption}):e.type==="video"&&t({videoBlockId:e.id,src:"",provider:e.data.provider})};return D.jsxs("div",{style:{width:"100%"},children:[D.jsx("div",{className:je.container,children:i&&!l?D.jsx("div",{className:je.mediaWrapper,children:a==="image"?D.jsx("img",{src:i instanceof File?URL.createObjectURL(i):i,alt:"",className:je.mediaItem}):D.jsx("video",{autoPlay:!0,muted:!0,controls:!0,className:je.mediaItem,children:D.jsx("source",{src:i instanceof File?URL.createObjectURL(i):i,type:"video/mp4"})})}):l?D.jsx(uy,{progress:f}):D.jsxs("div",{ref:m,onDrop:w=>yc(w,s,d,c,h),onDragOver:w=>bc(w,m),onDragLeave:w=>xc(w,m),className:je.dropzone,children:[D.jsx("input",{type:"file",id:"file",style:{display:"none"},onChange:w=>vc(w,s,d,c,h)}),D.jsxs("label",{htmlFor:"file",className:je.uploadLabel,children:[D.jsx("div",{className:je.uploadIconCircle,children:D.jsx(Ye,{icon:["fas","arrow-up-from-bracket"]})}),D.jsxs("div",{children:["Drop your"," ",D.jsx("strong",{children:e.type==="image"?"image/GIF":"video"})," ","here",D.jsx("div",{style:{color:"var(--grey-secondary)"},children:"or click to browse"})]})]})]})}),D.jsxs("div",{className:je.footerOverlay,children:[n&&D.jsx("div",{children:n}),D.jsxs("div",{onClick:b,className:je.refreshButton,children:["refresh",D.jsx(Ye,{icon:["fas","refresh"]})]})]})]})}function cy({imageBlock:e}){return D.jsx("div",{children:D.jsx("img",{src:e.data.src===""?null:e.data.src,alt:"",style:wc})},e.id)}function fy({videoBlock:e}){return D.jsx("div",{children:e.data.src&&D.jsx("video",{autoPlay:!0,muted:!0,controls:!0,style:wc,children:D.jsx("source",{src:e.data.src===""?null:e.data.src,type:"video/mp4"})})},e.id)}const fs={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",fontSize:"14px"};function dy({linkBlock:e,modifyLink:t}){const[n,r]=z.useState(e.data.linkText),[i,s]=z.useState(e.data.url);return z.useEffect(()=>{t({linkBlockId:e.id,linkText:n,url:i})},[n,i,e.id]),D.jsxs("div",{style:{display:"flex"},children:[D.jsx("input",{style:{...fs,color:"#232323",borderBottom:"1px solid #232323"},type:"text",placeholder:"Enter link text...",autoFocus:!0,value:e.data.linkText,onChange:a=>r(a.target.value)}),D.jsx("span",{children:"["}),D.jsx("input",{style:{...fs,color:"var(--hovered-draftify-theme-color)",borderBottom:"1px solid #232323"},type:"url",placeholder:"url",autoFocus:!0,value:e.data.url,onChange:a=>s(a.target.value)}),D.jsx("span",{children:"]"})]})}function hy({linkBlock:e}){return D.jsx("a",{style:{...fs,color:"#3b82f6"},href:e.data.url,children:e.data.linkText},e.id)}const Sc={fontFamily:"monospace",backgroundColor:"black",color:"white",padding:"8px",whiteSpace:"pre-wrap",borderRadius:"6px",width:"100%"};function my({codeBlock:e,modifyCode:t}){return D.jsx("textarea",{style:Sc,placeholder:"Code block...",autoFocus:!0,value:e.data.code,onChange:n=>t({codeBlockId:e.id,language:e.data.language,code:n.target.value})})}function py({codeBlock:e}){return D.jsx("pre",{style:Sc,children:D.jsx("code",{children:e.data.code})},e.id)}function gy({block:e,modifyHeading:t,modifySubheading:n,modifyParagraph:r,modifyQuote:i,modifyList:s,modifyTable:a,modifyImage:o,modifyVideo:u,modifyLink:d,modifyCode:l,modifyCustom:c,CustomEditor1:f,CustomEditor2:h,CustomEditor3:m}){switch(e.type){case"heading":return D.jsx(zg,{headingBlock:e,modifyHeading:t});case"subheading":return D.jsx(Wg,{subheadingBlock:e,modifySubheading:n});case"paragraph":return D.jsx(Yg,{paragraphBlock:e,modifyParagraph:r});case"quote":return D.jsx(qg,{quoteBlock:e,modifyQuote:i});case"list":return D.jsx(Kg,{listBlock:e,modifyList:s});case"table":return D.jsx(Zg,{tableBlock:e,modifyTable:a});case"image":return D.jsx(Ac,{mediaBlock:e,modifyMedia:o});case"video":return D.jsx(Ac,{mediaBlock:e,modifyMedia:u});case"link":return D.jsx(dy,{linkBlock:e,modifyLink:d});case"code":return D.jsx(my,{codeBlock:e,modifyCode:l});case"custom-1":return f?D.jsx(f,{customBlock:e,modifyCustom:c}):null;case"custom-2":return h?D.jsx(h,{customBlock:e,modifyCustom:c}):null;case"custom-3":return m?D.jsx(m,{customBlock:e,modifyCustom:c}):null;default:return null}}function wn({text:e,children:t}){const[n,r]=z.useState(!1),i={position:"relative",display:"inline-block"},s={position:"absolute",bottom:"100%",left:"50%",transform:n?"translateX(-50%) translateY(-5px)":"translateX(-50%) translateY(0)",marginBottom:"8px",padding:"4px 8px",whiteSpace:"nowrap",zIndex:10,backgroundColor:"#1f2937",color:"#ffffff",fontSize:"0.75rem",borderRadius:"0.25rem",opacity:n?1:0,transition:"all 300ms ease",pointerEvents:"none"};return D.jsxs("div",{style:i,onMouseEnter:()=>r(!0),onMouseLeave:()=>r(!1),children:[t,D.jsx("span",{style:s,children:e})]})}const Tc=[{id:1,type:"heading",icon:["fas","heading"]},{id:2,type:"subheading",icon:["fas","heading"]},{id:3,type:"paragraph",icon:["fas","paragraph"]},{id:4,type:"quote",icon:["fas","quote-right"]},{id:5,type:"list",icon:["fas","list"]},{id:6,type:"table",icon:["fas","table-list"]},{id:7,type:"image",icon:["far","image"]},{id:8,type:"video",icon:["fas","play"]},{id:9,type:"link",icon:["fas","link"]},{id:10,type:"code",icon:["fas","code"]},{id:11,type:"custom-1",iconText:"C1"},{id:12,type:"custom-2",iconText:"C2"},{id:13,type:"custom-3",iconText:"C3"}];function yy({handleClick:e,options:t}){const[n,r]=z.useState(null),i=(o,u)=>{r(o),e(u)},s=t.map(o=>{if(o.includes("-")){const u=o.split("-");if(u[0]==="custom")return u.slice(0,2).join("-")}return o}),a=s?Tc.filter(o=>s.includes(o.type)):Tc;return D.jsx("div",{className:Pn.optionsContainer,children:a.map(o=>{const u=l=>l.type.split("-")[0]==="custom",d=u(o)?(()=>{const l=t.find(c=>c.startsWith(o.type+"-"));return l&&l.split("-")[2]||o.iconText})():o.type;return D.jsx(wn,{text:d,children:D.jsxs("div",{className:Pn.optionButton,style:{color:n===o.id?"var(--draftify-theme-color)":"#4b5563"},onClick:()=>o.type!=="table"&&i(o.id,o.type),children:[D.jsxs("div",{className:Pn.iconWrapper,children:[u(o)?D.jsx("div",{children:(()=>{const l=t.find(c=>c.startsWith(o.type+"-"));return l&&l.split("-")[2]||o.iconText})()}):D.jsx(Ye,{icon:o.icon,onClick:()=>o.type==="table"&&i(o.id,o.type)}),D.jsx("div",{className:Pn.subscript,children:o.type==="subheading"?"2":""})]}),o.type==="table"&&D.jsx(ey,{handleClick:e,block:o})]})},o.id)})})}function Pc({blocksData:e,CustomOutput1:t,CustomOutput2:n,CustomOutput3:r}){return e.length!==0&&e.map(i=>{switch(i.type){case"heading":return D.jsx($g,{headingBlock:i},i.id);case"subheading":return D.jsx(Hg,{subheadingBlock:i},i.id);case"paragraph":return D.jsx(Gg,{paragraphBlock:i},i.id);case"quote":return D.jsx(Qg,{quoteBlock:i},i.id);case"list":return D.jsx(Xg,{listBlock:i},i.id);case"table":return D.jsx(Jg,{tableBlock:i},i.id);case"image":return D.jsx(cy,{imageBlock:i},i.id);case"video":return D.jsx(fy,{videoBlock:i},i.id);case"link":return D.jsx(hy,{linkBlock:i},i.id);case"code":return D.jsx(py,{codeBlock:i},i.id);case"custom-1":return t?D.jsx(t,{customBlock:i},i.id):null;case"custom-2":return n?D.jsx(n,{customBlock:i},i.id):null;case"custom-3":return r?D.jsx(r,{customBlock:i},i.id):null;default:return null}})}function vy({view:e,setView:t,setPromptVisiblility:n,blocksData:r,setPromptAction:i,handleCopy:s}){const[a,o]=z.useState(!1),[u,d]=z.useState(null),l=z.useRef(null);z.useEffect(()=>{l.current&&(l.current.style.transform=e==="editor"?"translateX(14px)":"translateX(1px)")},[e]),z.useEffect(()=>{if(a){const m=setTimeout(()=>o(!1),3e3);return()=>clearTimeout(m)}},[a]);const c=m=>({border:"1px solid #d1d5db",borderRadius:"10px",backgroundColor:u===m?"var(--draftify-theme-color)":"var(--hovered-draftify-theme-color)",color:"white",fontWeight:u===m?"600":"400",padding:"0.25rem",cursor:"pointer",transition:"all 0.2s ease"}),f={width:"30px",height:"16px",border:"1px solid #232323",borderRadius:"1rem",cursor:"pointer",display:"flex",alignItems:"center",padding:"0",position:"relative"},h={width:"12px",height:"12px",borderRadius:"50%",backgroundColor:"#232323",transition:"transform 0.3s ease",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"9px"};return D.jsxs("div",{style:{height:"auto",minHeight:"40px",position:"relative",display:"flex",flexWrap:"wrap",alignItems:"center",fontSize:"12px",fontStyle:"italic",gap:"10px"},children:[D.jsxs("div",{className:"logo-text",children:["DRAFTIFY",D.jsx("div",{className:"logo-description",children:"Write. Create. Build your story block by block."})]}),D.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"10px",marginLeft:"auto"},children:[D.jsx(wn,{text:"e.g. for dev dummy data",children:D.jsxs("button",{style:c("json"),onMouseEnter:()=>d("json"),onMouseLeave:()=>d(null),onClick:()=>{i("downloadJSON"),n(!0)},children:["Download JSON ",D.jsx(Ye,{icon:["fas","download"]})]})}),D.jsx(wn,{text:"Download as document",children:D.jsxs("button",{style:c("docx"),onMouseEnter:()=>d("docx"),onMouseLeave:()=>d(null),onClick:()=>{i("exportDocx"),n(!0)},children:["Export .docx ",D.jsx(Ye,{icon:["fas","download"]})]})}),D.jsx(wn,{text:"copy to clipboard",children:D.jsx("button",{style:{padding:"0.25rem",cursor:"pointer",border:"none",background:"none",color:a?"#4ade80":"var(--hovered-draftify-theme-color)"},onClick:()=>s(r,o),children:D.jsx(Ye,{icon:["fas",a?"check":"copy"]})})}),D.jsx(wn,{text:"toggle btn editor & preview",children:D.jsx("div",{style:f,onClick:()=>t(m=>m==="editor"?"preview":"editor"),children:D.jsx("div",{ref:l,style:h,children:D.jsx("div",{style:{color:"white",transform:"translateY(-1px)"},children:e==="editor"?"e":"p"})})})}),D.jsxs("div",{style:{width:"100px"},children:["viewing ",e]})]})]})}function by(){const[e,t]=z.useState(!1),n={display:"flex",flexDirection:"column",justifyContent:"center",gap:"3px",width:"15px",height:"100%",border:`1px solid ${e?"black":"var(--draftify-theme-color)"}`,borderTopLeftRadius:"5px",borderBottomLeftRadius:"5px",cursor:"move",transition:"border-color 0.2s ease"},r={width:"4px",height:"4px",borderRadius:"10px",backgroundColor:e?"black":"var(--draftify-theme-color)",alignSelf:"center",transition:"background-color 0.2s ease"};return D.jsx("div",{style:n,onMouseEnter:()=>t(!0),onMouseLeave:()=>t(!1),children:[1,2,3].map(i=>D.jsx("div",{style:r},i))})}function xy({gridDots:e}){const t={position:"fixed",top:0,left:0,width:"100%",height:"100%",zIndex:-1},n={position:"absolute",width:"1px",height:"1px",backgroundColor:"black"};return D.jsx("div",{style:t,children:e.map(r=>D.jsx("div",{"data-x":r.x,"data-y":r.y,style:{...n,left:`${r.x*20}px`,top:`${r.y*20}px`}},r.key))})}function wy({docTitle:e,setDocTitle:t,description:n,setDescription:r,author:i,setAuthor:s,promptAction:a,handlePromptAction:o,setPromptVisiblility:u}){const[d,l]=z.useState(null),c={width:"100%",border:"1px solid #d1d5db",borderRadius:"0.375rem",padding:"0.25rem",marginTop:"0.25rem",marginBottom:"0.75rem"},f={flex:1,padding:"0.5rem 1rem",borderRadius:"0.375rem",cursor:"pointer",border:"none",transition:"background-color 0.2s"};return D.jsxs("div",{style:{padding:"1rem"},children:[D.jsxs("div",{style:{display:"flex"},children:[D.jsx("div",{style:{flex:1,marginBottom:"0.625rem"},children:"Would you like to add metadata before downloading?"}),D.jsx("div",{style:{cursor:"pointer"},onClick:()=>u(!1),children:D.jsx(Ye,{icon:["fas","xmark"]})})]}),D.jsxs("div",{style:{fontWeight:600},children:[D.jsxs("div",{children:[D.jsx("div",{children:" document title: (optional)"}),D.jsx("input",{type:"text",style:c,value:e,onChange:h=>t(h.target.value)})]}),D.jsxs("div",{children:[D.jsx("div",{children:"description: (optional)"}),D.jsx("textarea",{name:"description",style:{...c,minHeight:"60px"},value:n,onChange:h=>r(h.target.value)})]}),D.jsxs("div",{children:[D.jsx("div",{children:"author: (optional)"}),D.jsx("input",{type:"text",style:c,value:i,onChange:h=>s(h.target.value)})]})]}),D.jsxs("div",{style:{marginTop:"1rem",display:"flex",gap:"0.5rem"},children:[D.jsx("button",{style:{...f,backgroundColor:d==="ignore"?"#9ca3af":"#d1d5db",color:"black"},onMouseEnter:()=>l("ignore"),onMouseLeave:()=>l(null),onClick:()=>o(a,"ignore"),children:"Ignore"}),D.jsx("button",{style:{...f,backgroundColor:d==="add"?"#2563eb":"#3b82f6",color:"white"},onMouseEnter:()=>l("add"),onMouseLeave:()=>l(null),onClick:()=>o(a,"add"),children:"Add"})]})]})}function Cc({blocksData:e,modifyBlocks:t,defaultCustomData1:n,defaultCustomData2:r,defaultCustomData3:i}){const[s,a]=z.useState({metadata:{},version:"1.0.0",blocks:e}),[o,u]=z.useState(""),[d,l]=z.useState(""),[c,f]=z.useState(""),[h,m]=z.useState([]),[b,w]=z.useState("editor"),[v,I]=z.useState(!1),[S,E]=z.useState("");z.useEffect(()=>{if(!Array.isArray(e))throw new Error("DraftifyReact: blocksData must be an array of DraftifyBlock[]");if(typeof window<"u"&&localStorage.getItem("draftifyDoc")){const H=localStorage.getItem("draftifyDoc"),G=JSON.parse(H);a(G),u(G.metadata?.docTitle||""),l(G.metadata?.description||""),f(G.metadata?.author||""),t(te.normalizeDocument(G).blocks||te.normalizeBlock(e))}else t(te.normalizeBlock(e))},[]),z.useEffect(()=>{(async G=>{const Y=await Promise.all(G.map(async q=>{if(q.type==="image"&&q.file){const Te=await te.imageToBase64(q);return{...q,content:Te,file:void 0}}return q}));localStorage.setItem("draftifyDoc",JSON.stringify({...s,blocks:Y}))})(e)},[e,s]),z.useEffect(()=>{const H={docTitle:o||"Untitled",description:d||"",author:c||"Unknown",createdAt:new Date().toISOString()};a(G=>({...G,metadata:H}))},[o,d,c]);const P=(H,G)=>{const Y={docTitle:"Untitled Document",description:"",author:"Unknown Author",createdAt:new Date().toISOString()};H==="downloadJSON"?te.handleDownloadJSON(G==="add"?s:{...s,metadata:Y}):H==="exportDocx"&&te.exportBlocksToDocx(G==="add"?s:{...s,metadata:Y}),I(!1)},A=(H,G)=>{switch(H){case"heading":t(Y=>[...Y,te.createHeadingBlock()]);break;case"subheading":t(Y=>[...Y,te.createSubheadingBlock()]);break;case"paragraph":t(Y=>[...Y,te.createParagraphBlock()]);break;case"quote":t(Y=>[...Y,te.createQuoteBlock()]);break;case"list":t(Y=>[...Y,te.createListBlock()]);break;case"table":t(Y=>[...Y,te.createTableBlock(G)]);break;case"image":t(Y=>[...Y,te.createImageBlock()]);break;case"video":t(Y=>[...Y,te.createVideoBlock()]);break;case"link":t(Y=>[...Y,te.createLinkBlock()]);break;case"code":t(Y=>[...Y,te.createCodeBlock()]);break;case"custom-1":t(Y=>[...Y,te.createCustomBlock("custom-1",n)]);break;case"custom-2":t(Y=>[...Y,te.createCustomBlock("custom-2",r)]);break;case"custom-3":t(Y=>[...Y,te.createCustomBlock("custom-3",i)]);break}},O=({headingBlockId:H,newContent:G,level:Y})=>{t(q=>te.modifyHeadingBlock(q,H,G,Y))},p=({subheadingBlockId:H,newContent:G})=>{t(Y=>te.modifySubheadingBlock(Y,H,G))},y=({paragraphBlockId:H,newContent:G})=>{t(Y=>te.modifyParagraphBlock(Y,H,G))},T=({quoteBlockId:H,newContent:G,author:Y})=>{t(q=>te.modifyQuoteBlock(q,H,G,Y))},k=({listBlockId:H,listStyle:G,items:Y})=>{t(q=>te.modifyListBlock(q,H,G,Y))},M=({tableBlockId:H,tableContent:G})=>{t(Y=>te.modifyTableBlock(Y,H,G))},j=({imageBlockId:H,src:G,alt:Y,caption:q})=>{t(Te=>te.modifyImageBlock(Te,H,G,Y,q))},C=({videoBlockId:H,src:G,provider:Y})=>{t(q=>te.modifyVideoBlock(q,H,G,Y))},R=({linkBlockId:H,linkText:G,url:Y})=>{t(q=>te.modifyLinkBlock(q,H,G,Y))},x=({codeBlockId:H,language:G,code:Y})=>{t(q=>te.modifyCodeBlock(q,H,G,Y))},g=({customBlockId:H,data:G})=>{t(Y=>te.modifyCustomBlock(Y,H,G))},_=H=>{const G=e.find(Y=>Y.id===H);(G.type==="image"||G.type==="video")&&G.data.src!==""||t(Y=>Y.filter(q=>q.id!==H))},L=(H,G)=>{t(Y=>{const q=[...Y],[Te]=q.splice(H,1);return q.splice(G,0,Te),q})},U=(H,G)=>{H.preventDefault(),H.currentTarget.classList.remove("bg-gray-100");const Y=parseInt(H.dataTransfer.getData("text/plain")),q=G;Y!==q&&L(Y,q)},F=(H,G)=>{H.dataTransfer.setData("text/plain",G),H.currentTarget.style.opacity="0.5"},N=H=>{H.currentTarget.style.opacity="1"},W=H=>{H.currentTarget.classList.add("bg-gray-100")},B=H=>{H.currentTarget.classList.remove("bg-gray-100")},V={show:{transition:{staggerChildren:.07}}},X={hidden:{opacity:0,y:20},show:{opacity:1,y:0},exit:{opacity:0,y:-20}},Z={type:"spring",stiffness:300,damping:20},ee={scale:1.02,backgroundColor:"rgba(243, 244, 246, 0.8)"};return{view:b,setView:w,gridDots:h,setGridDots:m,docTitle:o,setDocTitle:u,description:d,setDescription:l,author:c,setAuthor:f,handleCopy:te.handleCopy,handlePromptAction:P,promptAction:S,setPromptAction:E,promptVisibility:v,setPromptVisiblility:I,blocksData:e,handleClick:A,modifyHeading:O,modifySubheading:p,modifyParagraph:y,modifyQuote:T,modifyList:k,modifyTable:M,modifyImage:j,modifyVideo:C,modifyLink:R,modifyCode:x,modifyCustom:g,onDropHandler:U,onDragStart:F,onDragEnd:N,onDragEnter:W,onDragLeave:B,containerVariants:V,itemVariants:X,transitions:Z,whileHover:ee,handleDelete:_}}function Ay(e){z.useEffect(()=>{function t(){const r=Math.ceil(window.innerWidth/20),i=Math.ceil(document.documentElement.scrollHeight/20),s=[];for(let a=0;a<i;a++)for(let o=0;o<r;o++)s.push({x:o,y:a,key:`${o}-${a}`});e(s)}return t(),window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)},[e])}var Sy={prefix:"fas",iconName:"trash",icon:[448,512,[],"f1f8","M136.7 5.9L128 32 32 32C14.3 32 0 46.3 0 64S14.3 96 32 96l384 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-96 0-8.7-26.1C306.9-7.2 294.7-16 280.9-16L167.1-16c-13.8 0-26 8.8-30.4 21.9zM416 144L32 144 53.1 467.1C54.7 492.4 75.7 512 101 512L347 512c25.3 0 46.3-19.6 47.9-44.9L416 144z"]},Ty={prefix:"fas",iconName:"code",icon:[576,512,[],"f121","M360.8 1.2c-17-4.9-34.7 5-39.6 22l-128 448c-4.9 17 5 34.7 22 39.6s34.7-5 39.6-22l128-448c4.9-17-5-34.7-22-39.6zm64.6 136.1c-12.5 12.5-12.5 32.8 0 45.3l73.4 73.4-73.4 73.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l96-96c12.5-12.5 12.5-32.8 0-45.3l-96-96c-12.5-12.5-32.8-12.5-45.3 0zm-274.7 0c-12.5-12.5-32.8-12.5-45.3 0l-96 96c-12.5 12.5-12.5 32.8 0 45.3l96 96c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 150.6 182.6c12.5-12.5 12.5-32.8 0-45.3z"]},Py={prefix:"fas",iconName:"arrow-up-from-bracket",icon:[448,512,[],"e09a","M246.6 9.4c-12.5-12.5-32.8-12.5-45.3 0l-128 128c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 109.3 192 320c0 17.7 14.3 32 32 32s32-14.3 32-32l0-210.7 73.4 73.4c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3l-128-128zM64 352c0-17.7-14.3-32-32-32S0 334.3 0 352l0 64c0 53 43 96 96 96l256 0c53 0 96-43 96-96l0-64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 64c0 17.7-14.3 32-32 32L96 448c-17.7 0-32-14.3-32-32l0-64z"]},Cy={prefix:"fas",iconName:"table-list",icon:[448,512,["th-list"],"f00b","M0 96C0 60.7 28.7 32 64 32l320 0c35.3 0 64 28.7 64 64l0 320c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 96zm64 0l0 64 64 0 0-64-64 0zm320 0l-192 0 0 64 192 0 0-64zM64 224l0 64 64 0 0-64-64 0zm320 0l-192 0 0 64 192 0 0-64zM64 352l0 64 64 0 0-64-64 0zm320 0l-192 0 0 64 192 0 0-64z"]},Ey={prefix:"fas",iconName:"link",icon:[576,512,[128279,"chain"],"f0c1","M419.5 96c-16.6 0-32.7 4.5-46.8 12.7-15.8-16-34.2-29.4-54.5-39.5 28.2-24 64.1-37.2 101.3-37.2 86.4 0 156.5 70 156.5 156.5 0 41.5-16.5 81.3-45.8 110.6l-71.1 71.1c-29.3 29.3-69.1 45.8-110.6 45.8-86.4 0-156.5-70-156.5-156.5 0-1.5 0-3 .1-4.5 .5-17.7 15.2-31.6 32.9-31.1s31.6 15.2 31.1 32.9c0 .9 0 1.8 0 2.6 0 51.1 41.4 92.5 92.5 92.5 24.5 0 48-9.7 65.4-27.1l71.1-71.1c17.3-17.3 27.1-40.9 27.1-65.4 0-51.1-41.4-92.5-92.5-92.5zM275.2 173.3c-1.9-.8-3.8-1.9-5.5-3.1-12.6-6.5-27-10.2-42.1-10.2-24.5 0-48 9.7-65.4 27.1L91.1 258.2c-17.3 17.3-27.1 40.9-27.1 65.4 0 51.1 41.4 92.5 92.5 92.5 16.5 0 32.6-4.4 46.7-12.6 15.8 16 34.2 29.4 54.6 39.5-28.2 23.9-64 37.2-101.3 37.2-86.4 0-156.5-70-156.5-156.5 0-41.5 16.5-81.3 45.8-110.6l71.1-71.1c29.3-29.3 69.1-45.8 110.6-45.8 86.6 0 156.5 70.6 156.5 156.9 0 1.3 0 2.6 0 3.9-.4 17.7-15.1 31.6-32.8 31.2s-31.6-15.1-31.2-32.8c0-.8 0-1.5 0-2.3 0-33.7-18-63.3-44.8-79.6z"]},Iy={prefix:"fas",iconName:"paragraph",icon:[448,512,[182],"f1dd","M160 0L416 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-32 0 0 416c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-416-48 0 0 416c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-160-48 0C71.6 320 0 248.4 0 160S71.6 0 160 0z"]},ky={prefix:"fas",iconName:"play",icon:[448,512,[9654],"f04b","M91.2 36.9c-12.4-6.8-27.4-6.5-39.6 .7S32 57.9 32 72l0 368c0 14.1 7.5 27.2 19.6 34.4s27.2 7.5 39.6 .7l336-184c12.8-7 20.8-20.5 20.8-35.1s-8-28.1-20.8-35.1l-336-184z"]},My={prefix:"fas",iconName:"check",icon:[448,512,[10003,10004],"f00c","M434.8 70.1c14.3 10.4 17.5 30.4 7.1 44.7l-256 352c-5.5 7.6-14 12.3-23.4 13.1s-18.5-2.7-25.1-9.3l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l101.5 101.5 234-321.7c10.4-14.3 30.4-17.5 44.7-7.1z"]},Dy={prefix:"fas",iconName:"xmark",icon:[384,512,[128473,10005,10006,10060,215,"close","multiply","remove","times"],"f00d","M55.1 73.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L147.2 256 9.9 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192.5 301.3 329.9 438.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.8 256 375.1 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192.5 210.7 55.1 73.4z"]},jy={prefix:"fas",iconName:"quote-right",icon:[448,512,[8221,"quote-right-alt"],"f10e","M448 296c0 66.3-53.7 120-120 120l-8 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l8 0c30.9 0 56-25.1 56-56l0-8-64 0c-35.3 0-64-28.7-64-64l0-64c0-35.3 28.7-64 64-64l64 0c35.3 0 64 28.7 64 64l0 136zm-256 0c0 66.3-53.7 120-120 120l-8 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l8 0c30.9 0 56-25.1 56-56l0-8-64 0c-35.3 0-64-28.7-64-64l0-64c0-35.3 28.7-64 64-64l64 0c35.3 0 64 28.7 64 64l0 136z"]},Fy={prefix:"fas",iconName:"list",icon:[512,512,["list-squares"],"f03a","M40 48C26.7 48 16 58.7 16 72l0 48c0 13.3 10.7 24 24 24l48 0c13.3 0 24-10.7 24-24l0-48c0-13.3-10.7-24-24-24L40 48zM192 64c-17.7 0-32 14.3-32 32s14.3 32 32 32l288 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L192 64zm0 160c-17.7 0-32 14.3-32 32s14.3 32 32 32l288 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-288 0zm0 160c-17.7 0-32 14.3-32 32s14.3 32 32 32l288 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-288 0zM16 232l0 48c0 13.3 10.7 24 24 24l48 0c13.3 0 24-10.7 24-24l0-48c0-13.3-10.7-24-24-24l-48 0c-13.3 0-24 10.7-24 24zM40 368c-13.3 0-24 10.7-24 24l0 48c0 13.3 10.7 24 24 24l48 0c13.3 0 24-10.7 24-24l0-48c0-13.3-10.7-24-24-24l-48 0z"]},Ly={prefix:"fas",iconName:"angle-down",icon:[384,512,[8964],"f107","M169.4 374.6c12.5 12.5 32.8 12.5 45.3 0l160-160c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 306.7 54.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l160 160z"]},Oy={prefix:"fas",iconName:"heading",icon:[448,512,["header"],"f1dc","M0 64C0 46.3 14.3 32 32 32l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-16 0 0 112 224 0 0-112-16 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-16 0 0 320 16 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-96 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l16 0 0-144-224 0 0 144 16 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-96 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l16 0 0-320-16 0C14.3 96 0 81.7 0 64z"]},Ry={prefix:"fas",iconName:"download",icon:[448,512,[],"f019","M256 32c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 210.7-41.4-41.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l96 96c12.5 12.5 32.8 12.5 45.3 0l96-96c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 242.7 256 32zM64 320c-35.3 0-64 28.7-64 64l0 32c0 35.3 28.7 64 64 64l320 0c35.3 0 64-28.7 64-64l0-32c0-35.3-28.7-64-64-64l-46.9 0-56.6 56.6c-31.2 31.2-81.9 31.2-113.1 0L110.9 320 64 320zm304 56a24 24 0 1 1 0 48 24 24 0 1 1 0-48z"]},_y={prefix:"fas",iconName:"copy",icon:[448,512,[],"f0c5","M192 0c-35.3 0-64 28.7-64 64l0 256c0 35.3 28.7 64 64 64l192 0c35.3 0 64-28.7 64-64l0-200.6c0-17.4-7.1-34.1-19.7-46.2L370.6 17.8C358.7 6.4 342.8 0 326.3 0L192 0zM64 128c-35.3 0-64 28.7-64 64L0 448c0 35.3 28.7 64 64 64l192 0c35.3 0 64-28.7 64-64l0-16-64 0 0 16-192 0 0-256 16 0 0-64-16 0z"]},Vy={prefix:"fas",iconName:"arrows-rotate",icon:[512,512,[128472,"refresh","sync"],"f021","M65.9 228.5c13.3-93 93.4-164.5 190.1-164.5 53 0 101 21.5 135.8 56.2 .2 .2 .4 .4 .6 .6l7.6 7.2-47.9 0c-17.7 0-32 14.3-32 32s14.3 32 32 32l128 0c17.7 0 32-14.3 32-32l0-128c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 53.4-11.3-10.7C390.5 28.6 326.5 0 256 0 127 0 20.3 95.4 2.6 219.5 .1 237 12.2 253.2 29.7 255.7s33.7-9.7 36.2-27.1zm443.5 64c2.5-17.5-9.7-33.7-27.1-36.2s-33.7 9.7-36.2 27.1c-13.3 93-93.4 164.5-190.1 164.5-53 0-101-21.5-135.8-56.2-.2-.2-.4-.4-.6-.6l-7.6-7.2 47.9 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L32 320c-8.5 0-16.7 3.4-22.7 9.5S-.1 343.7 0 352.3l1 127c.1 17.7 14.6 31.9 32.3 31.7S65.2 496.4 65 478.7l-.4-51.5 10.7 10.1c46.3 46.1 110.2 74.7 180.7 74.7 129 0 235.7-95.4 253.4-219.5z"]},Ny=Vy;var Uy={prefix:"far",iconName:"image",icon:[448,512,[],"f03e","M64 80c-8.8 0-16 7.2-16 16l0 320c0 8.8 7.2 16 16 16l320 0c8.8 0 16-7.2 16-16l0-320c0-8.8-7.2-16-16-16L64 80zM0 96C0 60.7 28.7 32 64 32l320 0c35.3 0 64 28.7 64 64l0 320c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 96zm128 32a32 32 0 1 1 0 64 32 32 0 1 1 0-64zm136 72c8.5 0 16.4 4.5 20.7 11.8l80 136c4.4 7.4 4.4 16.6 .1 24.1S352.6 384 344 384l-240 0c-8.9 0-17.2-5-21.3-12.9s-3.5-17.5 1.6-24.8l56-80c4.5-6.4 11.8-10.2 19.7-10.2s15.2 3.8 19.7 10.2l17.2 24.6 46.5-79c4.3-7.3 12.2-11.8 20.7-11.8z"]};Tg.add(Oy,Iy,Cy,Fy,Ey,Ty,Uy,jy,ky,Ly,Dy,Py,Sy,Ry,Ny,_y,My);function Ec({blocksData:e,modifyBlocks:t,options:n,CustomEditor1:r,CustomEditor2:i,CustomEditor3:s,CustomOutput1:a,CustomOutput2:o,CustomOutput3:u,defaultCustomData1:d,defaultCustomData2:l,defaultCustomData3:c}){const{view:f,setView:h,gridDots:m,setGridDots:b,docTitle:w,setDocTitle:v,description:I,setDescription:S,author:E,setAuthor:P,handleCopy:A,handlePromptAction:O,promptAction:p,setPromptAction:y,promptVisibility:T,setPromptVisiblility:k,handleClick:M,modifyHeading:j,modifySubheading:C,modifyParagraph:R,modifyQuote:x,modifyList:g,modifyTable:_,modifyImage:L,modifyVideo:U,modifyLink:F,modifyCode:N,modifyCustom:W,onDropHandler:B,onDragStart:V,onDragEnd:X,onDragEnter:Z,onDragLeave:ee,containerVariants:H,itemVariants:G,transitions:Y,whileHover:q,handleDelete:Te}=Cc({blocksData:e,modifyBlocks:t,defaultCustomData1:d,defaultCustomData2:l,defaultCustomData3:c});return Ay(b),D.jsxs("div",{className:"draftify-root",children:[D.jsx(xy,{gridDots:m}),D.jsxs("div",{className:"draftify-container",children:[D.jsx(vy,{view:f,setView:h,blocksData:e,setPromptAction:y,setPromptVisiblility:k,handleCopy:A}),T&&D.jsx(wy,{docTitle:w,setDocTitle:v,description:I,setDescription:S,author:E,setAuthor:P,promptAction:p,handlePromptAction:O,setPromptVisiblility:k}),f==="editor"&&D.jsxs(D.Fragment,{children:[D.jsx(yy,{handleClick:M,options:n}),D.jsx("div",{className:"editor-area",onSubmit:pe=>pe.preventDefault(),children:D.jsx(dl.div,{style:{display:"grid",gap:"10px"},variants:H,animate:"show",exit:"hidden",children:D.jsx(Rd,{children:e.map((pe,ie)=>D.jsxs(dl.div,{layout:!0,variants:G,transition:Y,whileHover:q,draggable:!0,onDragStart:ne=>V(ne,ie),onDragEnd:ne=>X(ne),onDragOver:ne=>ne.preventDefault(),onDragEnter:ne=>Z(ne),onDragLeave:ne=>ee(ne),onDrop:ne=>B(ne,ie),className:"block-container",children:[D.jsx(by,{}),D.jsx(gy,{block:pe,modifyHeading:j,modifySubheading:C,modifyParagraph:R,modifyQuote:x,modifyList:g,modifyTable:_,modifyImage:L,modifyVideo:U,modifyLink:F,modifyCode:N,modifyCustom:W,CustomEditor1:r,CustomEditor2:i,CustomEditor3:s}),D.jsx(Ye,{icon:["fas","trash"],className:"delete-icon",onClick:()=>Te(pe.id)})]},pe.id))})})})]}),f==="preview"&&D.jsx("div",{className:"output-area",onSubmit:pe=>pe.preventDefault(),children:D.jsx(Pc,{blocksData:e,CustomOutput1:a,CustomOutput2:o,CustomOutput3:u})})]})]})}Ae.DraftifyBlocksReader=Pc,Ae.DraftifyReact=Ec,Ae.default=Ec,Ae.dragHandler=bc,Ae.dragLeaveHandler=xc,Ae.dropHandler=yc,Ae.onFileChange=vc,Ae.useDraftifyReact=Cc,Object.defineProperties(Ae,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
589
+ `;let cs;function ly(e,t){return new Promise(((n,r)=>{cs||(cs=(function(a){const o=[];return o.push(a),URL.createObjectURL(new Blob(o))})(oy));const i=new Worker(cs);i.addEventListener("message",(function(a){if(t.signal&&t.signal.aborted)i.terminate();else if(a.data.progress===void 0){if(a.data.error)return r(new Error(a.data.error)),void i.terminate();n(a.data.file),i.terminate()}else t.onProgress(a.data.progress)})),i.addEventListener("error",r),t.signal&&t.signal.addEventListener("abort",(()=>{r(t.signal.reason),i.terminate()})),i.postMessage({file:e,imageCompressionLibUrl:t.libURL,options:{...t,onProgress:void 0,signal:void 0}})}))}function we(e,t){return new Promise((function(n,r){let i,s,a,o,u,d;if(i={...t},a=0,{onProgress:o}=i,i.maxSizeMB=i.maxSizeMB||Number.POSITIVE_INFINITY,u=typeof i.useWebWorker!="boolean"||i.useWebWorker,delete i.useWebWorker,i.onProgress=h=>{a=h,typeof o=="function"&&o(a)},!(e instanceof Blob||e instanceof ay))return r(new Error("The file given is not an instance of Blob or File"));if(!/^image/.test(e.type))return r(new Error("The file given is not an image"));if(d=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,!u||typeof Worker!="function"||d)return mc(e,i).then((function(h){try{return s=h,f.call(this)}catch(m){return r(m)}}).bind(this),r);var l=(function(){try{return f.call(this)}catch(h){return r(h)}}).bind(this),c=function(h){try{return mc(e,i).then((function(m){try{return s=m,l()}catch(b){return r(b)}}),r)}catch(m){return r(m)}};try{return i.libURL=i.libURL||"https://cdn.jsdelivr.net/npm/browser-image-compression@2.0.2/dist/browser-image-compression.js",ly(e,i).then((function(h){try{return s=h,l()}catch{return c()}}),c)}catch{c()}function f(){try{s.name=e.name,s.lastModified=e.lastModified}catch{}try{i.preserveExif&&e.type==="image/jpeg"&&(!i.fileType||i.fileType&&i.fileType===e.type)&&(s=rc(e,s))}catch{}return n(s)}}))}we.getDataUrlFromFile=oc,we.getFilefromDataUrl=us,we.loadImage=lc,we.drawImageInCanvas=cc,we.drawFileInCanvas=lr,we.canvasToFile=ur,we.getExifOrientation=fc,we.handleMaxWidthOrHeight=dc,we.followExifOrientation=hc,we.cleanupCanvasMemory=Ge,we.isAutoOrientationInBrowser=Gt,we.approximateBelowMaximumCanvasSizeOfBrowser=uc,we.copyExifWithoutOrientation=rc,we.getBrowserName=St,we.version="2.0.2";const pc=e=>{if(!e||typeof e!="string")return"unknown";const t=[".jpg",".jpeg",".png",".gif",".bmp",".webp",".svg"],n=[".mp4",".avi",".mov",".wmv",".flv",".mkv",".webm"];for(const r of t)if(e.toLowerCase().includes(r))return"image";for(const r of n)if(e.toLowerCase().includes(r))return"video";return"unknown"};async function gc(e,t,n){if(pc(e.name)!=="image")return e;const r={maxSizeMB:1,maxWidthOrHeight:1920,useWebWorker:!0,onProgress:i=>n(i)};try{t(!0);const i=await we(e,r);return i instanceof File?i:new File([i],e.name,{type:e.type})}catch(i){return console.error("Compression failed; using original file:",i),e}finally{t(!1)}}async function yc(e,t,n,r,i){e.preventDefault();for(const s of e.dataTransfer.items)if(s.kind==="file"){const a=s.getAsFile();if(!a)continue;const o=await gc(a,r,i);t(o),n(o.name)}}async function vc(e,t,n,r,i){const s=e.target.files?.[0];if(!s)return;const a=await gc(s,r,i);t(a),n(a.name)}function bc(e,t){e.preventDefault(),t.current&&(t.current.style.borderColor="blue")}function xc(e,t){e.preventDefault(),t.current&&(t.current.style.borderColor="grey")}const wc={width:"100%",height:"100%",objectFit:"cover",borderRadius:"10px"};function uy({progress:e=null}){const t=e!==null?e/100*360:0;return D.jsx("div",{className:je.donutContainer,children:D.jsx("div",{className:je.donutOuter,style:{background:`conic-gradient(rgb(59, 130, 246) ${t}deg, transparent 0)`},children:D.jsx("div",{className:je.donutInner,children:D.jsxs("div",{children:[D.jsx("div",{style:{fontStyle:"italic",fontSize:"13px"},children:"progress"}),D.jsx("div",{style:{fontSize:"1.25rem",fontWeight:"bold"},children:e!==null&&`${e}%`})]})})})})}function Ac({mediaBlock:e,modifyMedia:t}){const[n,r]=z.useState(""),[i,s]=z.useState(""),[a,o]=z.useState(""),[u,d]=z.useState(""),[l,c]=z.useState(!1),[f,h]=z.useState(null),m=z.useRef(null);z.useEffect(()=>{window.addEventListener("dragover",w=>w.preventDefault()),window.addEventListener("drop",w=>w.preventDefault())},[]),z.useEffect(()=>{r("To remove image or video component, refresh first."),e.data.src!==""&&(s(e.data.src),o(e.type))},[e.data.src,e.type]),z.useEffect(()=>{if(i&&i instanceof File){const w=URL.createObjectURL(i);e.type==="image"?t({imageBlockId:e.id,src:w,alt:e.data.alt,caption:e.data.caption}):e.type==="video"&&t({videoBlockId:e.id,src:w,provider:e.data.provider})}u&&o(pc(u))},[i]);const b=()=>{s(""),d(""),e.type==="image"?t({imageBlockId:e.id,src:"",alt:e.data.alt,caption:e.data.caption}):e.type==="video"&&t({videoBlockId:e.id,src:"",provider:e.data.provider})};return D.jsxs("div",{style:{width:"100%"},children:[D.jsx("div",{className:je.container,children:i&&!l?D.jsx("div",{className:je.mediaWrapper,children:a==="image"?D.jsx("img",{src:i instanceof File?URL.createObjectURL(i):i,alt:"",className:je.mediaItem}):D.jsx("video",{autoPlay:!0,muted:!0,controls:!0,className:je.mediaItem,children:D.jsx("source",{src:i instanceof File?URL.createObjectURL(i):i,type:"video/mp4"})})}):l?D.jsx(uy,{progress:f}):D.jsxs("div",{ref:m,onDrop:w=>yc(w,s,d,c,h),onDragOver:w=>bc(w,m),onDragLeave:w=>xc(w,m),className:je.dropzone,children:[D.jsx("input",{type:"file",id:"file",style:{display:"none"},onChange:w=>vc(w,s,d,c,h)}),D.jsxs("label",{htmlFor:"file",className:je.uploadLabel,children:[D.jsx("div",{className:je.uploadIconCircle,children:D.jsx(Ye,{icon:["fas","arrow-up-from-bracket"]})}),D.jsxs("div",{children:["Drop your"," ",D.jsx("strong",{children:e.type==="image"?"image/GIF":"video"})," ","here",D.jsx("div",{style:{color:"var(--grey-secondary)"},children:"or click to browse"})]})]})]})}),D.jsxs("div",{className:je.footerOverlay,children:[n&&D.jsx("div",{children:n}),D.jsxs("div",{onClick:b,className:je.refreshButton,children:["refresh",D.jsx(Ye,{icon:["fas","refresh"]})]})]})]})}function cy({imageBlock:e}){return D.jsx("div",{children:D.jsx("img",{src:e.data.src===""?null:e.data.src,alt:"",style:wc})},e.id)}function fy({videoBlock:e}){return D.jsx("div",{children:e.data.src&&D.jsx("video",{autoPlay:!0,muted:!0,controls:!0,style:wc,children:D.jsx("source",{src:e.data.src===""?null:e.data.src,type:"video/mp4"})})},e.id)}const fs={fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol",border:"none",outline:"none",width:"100%",fontSize:"14px"};function dy({linkBlock:e,modifyLink:t}){const[n,r]=z.useState(e.data.linkText),[i,s]=z.useState(e.data.url);return z.useEffect(()=>{t({linkBlockId:e.id,linkText:n,url:i})},[n,i,e.id]),D.jsxs("div",{style:{display:"flex"},children:[D.jsx("input",{style:{...fs,color:"#232323",borderBottom:"1px solid #232323"},type:"text",placeholder:"Enter link text...",autoFocus:!0,value:e.data.linkText,onChange:a=>r(a.target.value)}),D.jsx("span",{children:"["}),D.jsx("input",{style:{...fs,color:"var(--hovered-draftify-theme-color)",borderBottom:"1px solid #232323"},type:"url",placeholder:"url",autoFocus:!0,value:e.data.url,onChange:a=>s(a.target.value)}),D.jsx("span",{children:"]"})]})}function hy({linkBlock:e}){return D.jsx("a",{style:{...fs,color:"#3b82f6"},href:e.data.url,children:e.data.linkText},e.id)}const Sc={fontFamily:"monospace",backgroundColor:"black",color:"white",padding:"8px",whiteSpace:"pre-wrap",borderRadius:"6px",width:"100%"};function my({codeBlock:e,modifyCode:t}){return D.jsx("textarea",{style:Sc,placeholder:"Code block...",autoFocus:!0,value:e.data.code,onChange:n=>t({codeBlockId:e.id,language:e.data.language,code:n.target.value})})}function py({codeBlock:e}){return D.jsx("pre",{style:Sc,children:D.jsx("code",{children:e.data.code})},e.id)}function gy({block:e,modifyHeading:t,modifySubheading:n,modifyParagraph:r,modifyQuote:i,modifyList:s,modifyTable:a,modifyImage:o,modifyVideo:u,modifyLink:d,modifyCode:l,modifyCustom:c,CustomEditor1:f,CustomEditor2:h,CustomEditor3:m}){switch(e.type){case"heading":return D.jsx(zg,{headingBlock:e,modifyHeading:t});case"subheading":return D.jsx(Wg,{subheadingBlock:e,modifySubheading:n});case"paragraph":return D.jsx(Yg,{paragraphBlock:e,modifyParagraph:r});case"quote":return D.jsx(qg,{quoteBlock:e,modifyQuote:i});case"list":return D.jsx(Kg,{listBlock:e,modifyList:s});case"table":return D.jsx(Zg,{tableBlock:e,modifyTable:a});case"image":return D.jsx(Ac,{mediaBlock:e,modifyMedia:o});case"video":return D.jsx(Ac,{mediaBlock:e,modifyMedia:u});case"link":return D.jsx(dy,{linkBlock:e,modifyLink:d});case"code":return D.jsx(my,{codeBlock:e,modifyCode:l});case"custom-1":return f?D.jsx(f,{customBlock:e,modifyCustom:c}):null;case"custom-2":return h?D.jsx(h,{customBlock:e,modifyCustom:c}):null;case"custom-3":return m?D.jsx(m,{customBlock:e,modifyCustom:c}):null;default:return null}}function wn({text:e,children:t}){const[n,r]=z.useState(!1),i={position:"relative",display:"inline-block"},s={position:"absolute",bottom:"100%",left:"50%",transform:n?"translateX(-50%) translateY(-5px)":"translateX(-50%) translateY(0)",marginBottom:"8px",padding:"4px 8px",whiteSpace:"nowrap",zIndex:10,backgroundColor:"#1f2937",color:"#ffffff",fontSize:"0.75rem",borderRadius:"0.25rem",opacity:n?1:0,transition:"all 300ms ease",pointerEvents:"none"};return D.jsxs("div",{style:i,onMouseEnter:()=>r(!0),onMouseLeave:()=>r(!1),children:[t,D.jsx("span",{style:s,children:e})]})}const Tc=[{id:1,type:"heading",icon:["fas","heading"]},{id:2,type:"subheading",icon:["fas","heading"]},{id:3,type:"paragraph",icon:["fas","paragraph"]},{id:4,type:"quote",icon:["fas","quote-right"]},{id:5,type:"list",icon:["fas","list"]},{id:6,type:"table",icon:["fas","table-list"]},{id:7,type:"image",icon:["far","image"]},{id:8,type:"video",icon:["fas","play"]},{id:9,type:"link",icon:["fas","link"]},{id:10,type:"code",icon:["fas","code"]},{id:11,type:"custom-1",iconText:"C1"},{id:12,type:"custom-2",iconText:"C2"},{id:13,type:"custom-3",iconText:"C3"}];function yy({handleClick:e,options:t}){const[n,r]=z.useState(null),i=(o,u)=>{r(o),e(u)},s=t.map(o=>{if(o.includes("-")){const u=o.split("-");if(u[0]==="custom")return u.slice(0,2).join("-")}return o}),a=s?Tc.filter(o=>s.includes(o.type)):Tc;return D.jsx("div",{className:Pn.optionsContainer,children:a.map(o=>{const u=l=>l.type.split("-")[0]==="custom",d=u(o)?(()=>{const l=t.find(c=>c.startsWith(o.type+"-"));return l&&l.split("-")[2]||o.iconText})():o.type;return D.jsx(wn,{text:d,children:D.jsxs("div",{className:Pn.optionButton,style:{color:n===o.id?"var(--draftify-theme-color)":"#4b5563"},onClick:()=>o.type!=="table"&&i(o.id,o.type),children:[D.jsxs("div",{className:Pn.iconWrapper,children:[u(o)?D.jsx("div",{children:(()=>{const l=t.find(c=>c.startsWith(o.type+"-"));return l&&l.split("-")[2]||o.iconText})()}):D.jsx(Ye,{icon:o.icon,onClick:()=>o.type==="table"&&i(o.id,o.type)}),D.jsx("div",{className:Pn.subscript,children:o.type==="subheading"?"2":""})]}),o.type==="table"&&D.jsx(ey,{handleClick:e,block:o})]})},o.id)})})}function Pc({blocksData:e,CustomOutput1:t,CustomOutput2:n,CustomOutput3:r}){return e.length!==0&&e.map(i=>{switch(i.type){case"heading":return D.jsx($g,{headingBlock:i},i.id);case"subheading":return D.jsx(Hg,{subheadingBlock:i},i.id);case"paragraph":return D.jsx(Gg,{paragraphBlock:i},i.id);case"quote":return D.jsx(Qg,{quoteBlock:i},i.id);case"list":return D.jsx(Xg,{listBlock:i},i.id);case"table":return D.jsx(Jg,{tableBlock:i},i.id);case"image":return D.jsx(cy,{imageBlock:i},i.id);case"video":return D.jsx(fy,{videoBlock:i},i.id);case"link":return D.jsx(hy,{linkBlock:i},i.id);case"code":return D.jsx(py,{codeBlock:i},i.id);case"custom-1":return t?D.jsx(t,{customBlock:i},i.id):null;case"custom-2":return n?D.jsx(n,{customBlock:i},i.id):null;case"custom-3":return r?D.jsx(r,{customBlock:i},i.id):null;default:return null}})}function vy({view:e,setView:t,setPromptVisiblility:n,blocksData:r,setPromptAction:i,handleCopy:s}){const[a,o]=z.useState(!1),[u,d]=z.useState(null),l=z.useRef(null);z.useEffect(()=>{l.current&&(l.current.style.transform=e==="editor"?"translateX(14px)":"translateX(1px)")},[e]),z.useEffect(()=>{if(a){const m=setTimeout(()=>o(!1),3e3);return()=>clearTimeout(m)}},[a]);const c=m=>({border:"1px solid #d1d5db",borderRadius:"10px",backgroundColor:u===m?"var(--draftify-theme-color)":"var(--hovered-draftify-theme-color)",color:"white",fontWeight:u===m?"600":"400",padding:"0.25rem",cursor:"pointer",transition:"all 0.2s ease"}),f={width:"30px",height:"16px",border:"1px solid #232323",borderRadius:"1rem",cursor:"pointer",display:"flex",alignItems:"center",padding:"0",position:"relative"},h={width:"12px",height:"12px",borderRadius:"50%",backgroundColor:"#232323",transition:"transform 0.3s ease",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"9px"};return D.jsxs("div",{style:{height:"auto",minHeight:"40px",position:"relative",display:"flex",flexWrap:"wrap",alignItems:"center",fontSize:"12px",fontStyle:"italic",gap:"10px"},children:[D.jsxs("div",{className:"logo-text",children:["DRAFTIFY",D.jsx("div",{className:"logo-description",children:"Write. Create. Build your story block by block."})]}),D.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"10px",marginLeft:"auto"},children:[D.jsx(wn,{text:"e.g. for dev dummy data",children:D.jsxs("button",{style:c("json"),onMouseEnter:()=>d("json"),onMouseLeave:()=>d(null),onClick:()=>{i("downloadJSON"),n(!0)},children:["Download JSON ",D.jsx(Ye,{icon:["fas","download"]})]})}),D.jsx(wn,{text:"Download as document",children:D.jsxs("button",{style:c("docx"),onMouseEnter:()=>d("docx"),onMouseLeave:()=>d(null),onClick:()=>{i("exportDocx"),n(!0)},children:["Export .docx ",D.jsx(Ye,{icon:["fas","download"]})]})}),D.jsx(wn,{text:"copy to clipboard",children:D.jsx("button",{style:{padding:"0.25rem",cursor:"pointer",border:"none",background:"none",color:a?"#4ade80":"var(--hovered-draftify-theme-color)"},onClick:()=>s(r,o),children:D.jsx(Ye,{icon:["fas",a?"check":"copy"]})})}),D.jsx(wn,{text:"toggle btn editor & preview",children:D.jsx("div",{style:f,onClick:()=>t(m=>m==="editor"?"preview":"editor"),children:D.jsx("div",{ref:l,style:h,children:D.jsx("div",{style:{color:"white",transform:"translateY(-1px)"},children:e==="editor"?"e":"p"})})})}),D.jsxs("div",{style:{width:"100px"},children:["viewing ",e]})]})]})}function by(){const[e,t]=z.useState(!1),n={display:"flex",flexDirection:"column",justifyContent:"center",gap:"3px",width:"15px",height:"100%",border:`1px solid ${e?"black":"var(--draftify-theme-color)"}`,borderTopLeftRadius:"5px",borderBottomLeftRadius:"5px",cursor:"move",transition:"border-color 0.2s ease"},r={width:"4px",height:"4px",borderRadius:"10px",backgroundColor:e?"black":"var(--draftify-theme-color)",alignSelf:"center",transition:"background-color 0.2s ease"};return D.jsx("div",{style:n,onMouseEnter:()=>t(!0),onMouseLeave:()=>t(!1),children:[1,2,3].map(i=>D.jsx("div",{style:r},i))})}function xy({gridDots:e}){const t={position:"fixed",top:0,left:0,width:"100%",height:"100%",zIndex:-1},n={position:"absolute",width:"1px",height:"1px",backgroundColor:"black"};return D.jsx("div",{style:t,children:e.map(r=>D.jsx("div",{"data-x":r.x,"data-y":r.y,style:{...n,left:`${r.x*20}px`,top:`${r.y*20}px`}},r.key))})}function wy({docTitle:e,setDocTitle:t,description:n,setDescription:r,author:i,setAuthor:s,promptAction:a,handlePromptAction:o,setPromptVisiblility:u}){const[d,l]=z.useState(null),c={width:"100%",border:"1px solid #d1d5db",borderRadius:"0.375rem",padding:"0.25rem",marginTop:"0.25rem",marginBottom:"0.75rem"},f={flex:1,padding:"0.5rem 1rem",borderRadius:"0.375rem",cursor:"pointer",border:"none",transition:"background-color 0.2s"};return D.jsxs("div",{style:{padding:"1rem"},children:[D.jsxs("div",{style:{display:"flex"},children:[D.jsx("div",{style:{flex:1,marginBottom:"0.625rem"},children:"Would you like to add metadata before downloading?"}),D.jsx("div",{style:{cursor:"pointer"},onClick:()=>u(!1),children:D.jsx(Ye,{icon:["fas","xmark"]})})]}),D.jsxs("div",{style:{fontWeight:600},children:[D.jsxs("div",{children:[D.jsx("div",{children:" document title: (optional)"}),D.jsx("input",{type:"text",style:c,value:e,onChange:h=>t(h.target.value)})]}),D.jsxs("div",{children:[D.jsx("div",{children:"description: (optional)"}),D.jsx("textarea",{name:"description",style:{...c,minHeight:"60px"},value:n,onChange:h=>r(h.target.value)})]}),D.jsxs("div",{children:[D.jsx("div",{children:"author: (optional)"}),D.jsx("input",{type:"text",style:c,value:i,onChange:h=>s(h.target.value)})]})]}),D.jsxs("div",{style:{marginTop:"1rem",display:"flex",gap:"0.5rem"},children:[D.jsx("button",{style:{...f,backgroundColor:d==="ignore"?"#9ca3af":"#d1d5db",color:"black"},onMouseEnter:()=>l("ignore"),onMouseLeave:()=>l(null),onClick:()=>o(a,"ignore"),children:"Ignore"}),D.jsx("button",{style:{...f,backgroundColor:d==="add"?"#2563eb":"#3b82f6",color:"white"},onMouseEnter:()=>l("add"),onMouseLeave:()=>l(null),onClick:()=>o(a,"add"),children:"Add"})]})]})}function Cc({blocksData:e,modifyBlocks:t,defaultCustomData1:n,defaultCustomData2:r,defaultCustomData3:i,localStorageEnable:s}){const[a,o]=z.useState({metadata:{},version:"1.0.0",blocks:e}),[u,d]=z.useState(""),[l,c]=z.useState(""),[f,h]=z.useState(""),[m,b]=z.useState([]),[w,v]=z.useState("editor"),[I,S]=z.useState(!1),[E,P]=z.useState("");z.useEffect(()=>{if(!Array.isArray(e))throw new Error("DraftifyReact: blocksData must be an array of DraftifyBlock[]");if(s)if(typeof window<"u"&&localStorage.getItem("draftifyDoc")){const Y=localStorage.getItem("draftifyDoc"),G=JSON.parse(Y);o(G),d(G.metadata?.docTitle||""),c(G.metadata?.description||""),h(G.metadata?.author||""),t(re.normalizeDocument(G).blocks||re.normalizeBlock(e))}else t(re.normalizeBlock(e));else t(re.normalizeBlock(e))},[]),z.useEffect(()=>{s&&(async G=>{const H=await Promise.all(G.map(async te=>{if(te.type==="image"&&te.file){const ge=await re.imageToBase64(te);return{...te,content:ge,file:void 0}}return te}));localStorage.setItem("draftifyDoc",JSON.stringify({...a,blocks:H}))})(e)},[e,a]),z.useEffect(()=>{const Y={docTitle:u||"Untitled",description:l||"",author:f||"Unknown",createdAt:new Date().toISOString()};o(G=>({...G,metadata:Y}))},[u,l,f]);const A=(Y,G)=>{const H={docTitle:"Untitled Document",description:"",author:"Unknown Author",createdAt:new Date().toISOString()};Y==="downloadJSON"?re.handleDownloadJSON(G==="add"?a:{...a,metadata:H}):Y==="exportDocx"&&re.exportBlocksToDocx(G==="add"?a:{...a,metadata:H}),S(!1)},O=(Y,G)=>{switch(Y){case"heading":t(H=>[...H,re.createHeadingBlock()]);break;case"subheading":t(H=>[...H,re.createSubheadingBlock()]);break;case"paragraph":t(H=>[...H,re.createParagraphBlock()]);break;case"quote":t(H=>[...H,re.createQuoteBlock()]);break;case"list":t(H=>[...H,re.createListBlock()]);break;case"table":t(H=>[...H,re.createTableBlock(G)]);break;case"image":t(H=>[...H,re.createImageBlock()]);break;case"video":t(H=>[...H,re.createVideoBlock()]);break;case"link":t(H=>[...H,re.createLinkBlock()]);break;case"code":t(H=>[...H,re.createCodeBlock()]);break;case"custom-1":t(H=>[...H,re.createCustomBlock("custom-1",n)]);break;case"custom-2":t(H=>[...H,re.createCustomBlock("custom-2",r)]);break;case"custom-3":t(H=>[...H,re.createCustomBlock("custom-3",i)]);break}},p=({headingBlockId:Y,newContent:G,level:H})=>{t(te=>re.modifyHeadingBlock(te,Y,G,H))},y=({subheadingBlockId:Y,newContent:G})=>{t(H=>re.modifySubheadingBlock(H,Y,G))},T=({paragraphBlockId:Y,newContent:G})=>{t(H=>re.modifyParagraphBlock(H,Y,G))},k=({quoteBlockId:Y,newContent:G,author:H})=>{t(te=>re.modifyQuoteBlock(te,Y,G,H))},M=({listBlockId:Y,listStyle:G,items:H})=>{t(te=>re.modifyListBlock(te,Y,G,H))},j=({tableBlockId:Y,tableContent:G})=>{t(H=>re.modifyTableBlock(H,Y,G))},C=({imageBlockId:Y,src:G,alt:H,caption:te})=>{t(ge=>re.modifyImageBlock(ge,Y,G,H,te))},R=({videoBlockId:Y,src:G,provider:H})=>{t(te=>re.modifyVideoBlock(te,Y,G,H))},x=({linkBlockId:Y,linkText:G,url:H})=>{t(te=>re.modifyLinkBlock(te,Y,G,H))},g=({codeBlockId:Y,language:G,code:H})=>{t(te=>re.modifyCodeBlock(te,Y,G,H))},_=({customBlockId:Y,data:G})=>{t(H=>re.modifyCustomBlock(H,Y,G))},L=Y=>{const G=e.find(H=>H.id===Y);(G.type==="image"||G.type==="video")&&G.data.src!==""||t(H=>H.filter(te=>te.id!==Y))},U=(Y,G)=>{t(H=>{const te=[...H],[ge]=te.splice(Y,1);return te.splice(G,0,ge),te})},F=(Y,G)=>{Y.preventDefault(),Y.currentTarget.classList.remove("bg-gray-100");const H=parseInt(Y.dataTransfer.getData("text/plain")),te=G;H!==te&&U(H,te)},N=(Y,G)=>{Y.dataTransfer.setData("text/plain",G),Y.currentTarget.style.opacity="0.5"},W=Y=>{Y.currentTarget.style.opacity="1"},B=Y=>{Y.currentTarget.classList.add("bg-gray-100")},V=Y=>{Y.currentTarget.classList.remove("bg-gray-100")},X={show:{transition:{staggerChildren:.07}}},Q={hidden:{opacity:0,y:20},show:{opacity:1,y:0},exit:{opacity:0,y:-20}},J={type:"spring",stiffness:300,damping:20},ee={scale:1.02,backgroundColor:"rgba(243, 244, 246, 0.8)"};return{view:w,setView:v,gridDots:m,setGridDots:b,docTitle:u,setDocTitle:d,description:l,setDescription:c,author:f,setAuthor:h,handleCopy:re.handleCopy,handlePromptAction:A,promptAction:E,setPromptAction:P,promptVisibility:I,setPromptVisiblility:S,blocksData:e,handleClick:O,modifyHeading:p,modifySubheading:y,modifyParagraph:T,modifyQuote:k,modifyList:M,modifyTable:j,modifyImage:C,modifyVideo:R,modifyLink:x,modifyCode:g,modifyCustom:_,onDropHandler:F,onDragStart:N,onDragEnd:W,onDragEnter:B,onDragLeave:V,containerVariants:X,itemVariants:Q,transitions:J,whileHover:ee,handleDelete:L}}function Ay(e){z.useEffect(()=>{function t(){const r=Math.ceil(window.innerWidth/20),i=Math.ceil(document.documentElement.scrollHeight/20),s=[];for(let a=0;a<i;a++)for(let o=0;o<r;o++)s.push({x:o,y:a,key:`${o}-${a}`});e(s)}return t(),window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)},[e])}var Sy={prefix:"fas",iconName:"trash",icon:[448,512,[],"f1f8","M136.7 5.9L128 32 32 32C14.3 32 0 46.3 0 64S14.3 96 32 96l384 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-96 0-8.7-26.1C306.9-7.2 294.7-16 280.9-16L167.1-16c-13.8 0-26 8.8-30.4 21.9zM416 144L32 144 53.1 467.1C54.7 492.4 75.7 512 101 512L347 512c25.3 0 46.3-19.6 47.9-44.9L416 144z"]},Ty={prefix:"fas",iconName:"code",icon:[576,512,[],"f121","M360.8 1.2c-17-4.9-34.7 5-39.6 22l-128 448c-4.9 17 5 34.7 22 39.6s34.7-5 39.6-22l128-448c4.9-17-5-34.7-22-39.6zm64.6 136.1c-12.5 12.5-12.5 32.8 0 45.3l73.4 73.4-73.4 73.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0l96-96c12.5-12.5 12.5-32.8 0-45.3l-96-96c-12.5-12.5-32.8-12.5-45.3 0zm-274.7 0c-12.5-12.5-32.8-12.5-45.3 0l-96 96c-12.5 12.5-12.5 32.8 0 45.3l96 96c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 150.6 182.6c12.5-12.5 12.5-32.8 0-45.3z"]},Py={prefix:"fas",iconName:"arrow-up-from-bracket",icon:[448,512,[],"e09a","M246.6 9.4c-12.5-12.5-32.8-12.5-45.3 0l-128 128c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 109.3 192 320c0 17.7 14.3 32 32 32s32-14.3 32-32l0-210.7 73.4 73.4c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3l-128-128zM64 352c0-17.7-14.3-32-32-32S0 334.3 0 352l0 64c0 53 43 96 96 96l256 0c53 0 96-43 96-96l0-64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 64c0 17.7-14.3 32-32 32L96 448c-17.7 0-32-14.3-32-32l0-64z"]},Cy={prefix:"fas",iconName:"table-list",icon:[448,512,["th-list"],"f00b","M0 96C0 60.7 28.7 32 64 32l320 0c35.3 0 64 28.7 64 64l0 320c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 96zm64 0l0 64 64 0 0-64-64 0zm320 0l-192 0 0 64 192 0 0-64zM64 224l0 64 64 0 0-64-64 0zm320 0l-192 0 0 64 192 0 0-64zM64 352l0 64 64 0 0-64-64 0zm320 0l-192 0 0 64 192 0 0-64z"]},Ey={prefix:"fas",iconName:"link",icon:[576,512,[128279,"chain"],"f0c1","M419.5 96c-16.6 0-32.7 4.5-46.8 12.7-15.8-16-34.2-29.4-54.5-39.5 28.2-24 64.1-37.2 101.3-37.2 86.4 0 156.5 70 156.5 156.5 0 41.5-16.5 81.3-45.8 110.6l-71.1 71.1c-29.3 29.3-69.1 45.8-110.6 45.8-86.4 0-156.5-70-156.5-156.5 0-1.5 0-3 .1-4.5 .5-17.7 15.2-31.6 32.9-31.1s31.6 15.2 31.1 32.9c0 .9 0 1.8 0 2.6 0 51.1 41.4 92.5 92.5 92.5 24.5 0 48-9.7 65.4-27.1l71.1-71.1c17.3-17.3 27.1-40.9 27.1-65.4 0-51.1-41.4-92.5-92.5-92.5zM275.2 173.3c-1.9-.8-3.8-1.9-5.5-3.1-12.6-6.5-27-10.2-42.1-10.2-24.5 0-48 9.7-65.4 27.1L91.1 258.2c-17.3 17.3-27.1 40.9-27.1 65.4 0 51.1 41.4 92.5 92.5 92.5 16.5 0 32.6-4.4 46.7-12.6 15.8 16 34.2 29.4 54.6 39.5-28.2 23.9-64 37.2-101.3 37.2-86.4 0-156.5-70-156.5-156.5 0-41.5 16.5-81.3 45.8-110.6l71.1-71.1c29.3-29.3 69.1-45.8 110.6-45.8 86.6 0 156.5 70.6 156.5 156.9 0 1.3 0 2.6 0 3.9-.4 17.7-15.1 31.6-32.8 31.2s-31.6-15.1-31.2-32.8c0-.8 0-1.5 0-2.3 0-33.7-18-63.3-44.8-79.6z"]},Iy={prefix:"fas",iconName:"paragraph",icon:[448,512,[182],"f1dd","M160 0L416 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-32 0 0 416c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-416-48 0 0 416c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-160-48 0C71.6 320 0 248.4 0 160S71.6 0 160 0z"]},ky={prefix:"fas",iconName:"play",icon:[448,512,[9654],"f04b","M91.2 36.9c-12.4-6.8-27.4-6.5-39.6 .7S32 57.9 32 72l0 368c0 14.1 7.5 27.2 19.6 34.4s27.2 7.5 39.6 .7l336-184c12.8-7 20.8-20.5 20.8-35.1s-8-28.1-20.8-35.1l-336-184z"]},My={prefix:"fas",iconName:"check",icon:[448,512,[10003,10004],"f00c","M434.8 70.1c14.3 10.4 17.5 30.4 7.1 44.7l-256 352c-5.5 7.6-14 12.3-23.4 13.1s-18.5-2.7-25.1-9.3l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l101.5 101.5 234-321.7c10.4-14.3 30.4-17.5 44.7-7.1z"]},Dy={prefix:"fas",iconName:"xmark",icon:[384,512,[128473,10005,10006,10060,215,"close","multiply","remove","times"],"f00d","M55.1 73.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L147.2 256 9.9 393.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192.5 301.3 329.9 438.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.8 256 375.1 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192.5 210.7 55.1 73.4z"]},jy={prefix:"fas",iconName:"quote-right",icon:[448,512,[8221,"quote-right-alt"],"f10e","M448 296c0 66.3-53.7 120-120 120l-8 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l8 0c30.9 0 56-25.1 56-56l0-8-64 0c-35.3 0-64-28.7-64-64l0-64c0-35.3 28.7-64 64-64l64 0c35.3 0 64 28.7 64 64l0 136zm-256 0c0 66.3-53.7 120-120 120l-8 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l8 0c30.9 0 56-25.1 56-56l0-8-64 0c-35.3 0-64-28.7-64-64l0-64c0-35.3 28.7-64 64-64l64 0c35.3 0 64 28.7 64 64l0 136z"]},Fy={prefix:"fas",iconName:"list",icon:[512,512,["list-squares"],"f03a","M40 48C26.7 48 16 58.7 16 72l0 48c0 13.3 10.7 24 24 24l48 0c13.3 0 24-10.7 24-24l0-48c0-13.3-10.7-24-24-24L40 48zM192 64c-17.7 0-32 14.3-32 32s14.3 32 32 32l288 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L192 64zm0 160c-17.7 0-32 14.3-32 32s14.3 32 32 32l288 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-288 0zm0 160c-17.7 0-32 14.3-32 32s14.3 32 32 32l288 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-288 0zM16 232l0 48c0 13.3 10.7 24 24 24l48 0c13.3 0 24-10.7 24-24l0-48c0-13.3-10.7-24-24-24l-48 0c-13.3 0-24 10.7-24 24zM40 368c-13.3 0-24 10.7-24 24l0 48c0 13.3 10.7 24 24 24l48 0c13.3 0 24-10.7 24-24l0-48c0-13.3-10.7-24-24-24l-48 0z"]},Ly={prefix:"fas",iconName:"angle-down",icon:[384,512,[8964],"f107","M169.4 374.6c12.5 12.5 32.8 12.5 45.3 0l160-160c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 306.7 54.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l160 160z"]},Oy={prefix:"fas",iconName:"heading",icon:[448,512,["header"],"f1dc","M0 64C0 46.3 14.3 32 32 32l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-16 0 0 112 224 0 0-112-16 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l96 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-16 0 0 320 16 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-96 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l16 0 0-144-224 0 0 144 16 0c17.7 0 32 14.3 32 32s-14.3 32-32 32l-96 0c-17.7 0-32-14.3-32-32s14.3-32 32-32l16 0 0-320-16 0C14.3 96 0 81.7 0 64z"]},Ry={prefix:"fas",iconName:"download",icon:[448,512,[],"f019","M256 32c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 210.7-41.4-41.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l96 96c12.5 12.5 32.8 12.5 45.3 0l96-96c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 242.7 256 32zM64 320c-35.3 0-64 28.7-64 64l0 32c0 35.3 28.7 64 64 64l320 0c35.3 0 64-28.7 64-64l0-32c0-35.3-28.7-64-64-64l-46.9 0-56.6 56.6c-31.2 31.2-81.9 31.2-113.1 0L110.9 320 64 320zm304 56a24 24 0 1 1 0 48 24 24 0 1 1 0-48z"]},_y={prefix:"fas",iconName:"copy",icon:[448,512,[],"f0c5","M192 0c-35.3 0-64 28.7-64 64l0 256c0 35.3 28.7 64 64 64l192 0c35.3 0 64-28.7 64-64l0-200.6c0-17.4-7.1-34.1-19.7-46.2L370.6 17.8C358.7 6.4 342.8 0 326.3 0L192 0zM64 128c-35.3 0-64 28.7-64 64L0 448c0 35.3 28.7 64 64 64l192 0c35.3 0 64-28.7 64-64l0-16-64 0 0 16-192 0 0-256 16 0 0-64-16 0z"]},Vy={prefix:"fas",iconName:"arrows-rotate",icon:[512,512,[128472,"refresh","sync"],"f021","M65.9 228.5c13.3-93 93.4-164.5 190.1-164.5 53 0 101 21.5 135.8 56.2 .2 .2 .4 .4 .6 .6l7.6 7.2-47.9 0c-17.7 0-32 14.3-32 32s14.3 32 32 32l128 0c17.7 0 32-14.3 32-32l0-128c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 53.4-11.3-10.7C390.5 28.6 326.5 0 256 0 127 0 20.3 95.4 2.6 219.5 .1 237 12.2 253.2 29.7 255.7s33.7-9.7 36.2-27.1zm443.5 64c2.5-17.5-9.7-33.7-27.1-36.2s-33.7 9.7-36.2 27.1c-13.3 93-93.4 164.5-190.1 164.5-53 0-101-21.5-135.8-56.2-.2-.2-.4-.4-.6-.6l-7.6-7.2 47.9 0c17.7 0 32-14.3 32-32s-14.3-32-32-32L32 320c-8.5 0-16.7 3.4-22.7 9.5S-.1 343.7 0 352.3l1 127c.1 17.7 14.6 31.9 32.3 31.7S65.2 496.4 65 478.7l-.4-51.5 10.7 10.1c46.3 46.1 110.2 74.7 180.7 74.7 129 0 235.7-95.4 253.4-219.5z"]},Ny=Vy;var Uy={prefix:"far",iconName:"image",icon:[448,512,[],"f03e","M64 80c-8.8 0-16 7.2-16 16l0 320c0 8.8 7.2 16 16 16l320 0c8.8 0 16-7.2 16-16l0-320c0-8.8-7.2-16-16-16L64 80zM0 96C0 60.7 28.7 32 64 32l320 0c35.3 0 64 28.7 64 64l0 320c0 35.3-28.7 64-64 64L64 480c-35.3 0-64-28.7-64-64L0 96zm128 32a32 32 0 1 1 0 64 32 32 0 1 1 0-64zm136 72c8.5 0 16.4 4.5 20.7 11.8l80 136c4.4 7.4 4.4 16.6 .1 24.1S352.6 384 344 384l-240 0c-8.9 0-17.2-5-21.3-12.9s-3.5-17.5 1.6-24.8l56-80c4.5-6.4 11.8-10.2 19.7-10.2s15.2 3.8 19.7 10.2l17.2 24.6 46.5-79c4.3-7.3 12.2-11.8 20.7-11.8z"]};Tg.add(Oy,Iy,Cy,Fy,Ey,Ty,Uy,jy,ky,Ly,Dy,Py,Sy,Ry,Ny,_y,My);function Ec({blocksData:e,modifyBlocks:t,options:n,CustomEditor1:r,CustomEditor2:i,CustomEditor3:s,CustomOutput1:a,CustomOutput2:o,CustomOutput3:u,defaultCustomData1:d,defaultCustomData2:l,defaultCustomData3:c,localStorageEnable:f,backgroundEnable:h}){const{view:m,setView:b,gridDots:w,setGridDots:v,docTitle:I,setDocTitle:S,description:E,setDescription:P,author:A,setAuthor:O,handleCopy:p,handlePromptAction:y,promptAction:T,setPromptAction:k,promptVisibility:M,setPromptVisiblility:j,handleClick:C,modifyHeading:R,modifySubheading:x,modifyParagraph:g,modifyQuote:_,modifyList:L,modifyTable:U,modifyImage:F,modifyVideo:N,modifyLink:W,modifyCode:B,modifyCustom:V,onDropHandler:X,onDragStart:Q,onDragEnd:J,onDragEnter:ee,onDragLeave:Y,containerVariants:G,itemVariants:H,transitions:te,whileHover:ge,handleDelete:le}=Cc({blocksData:e,modifyBlocks:t,defaultCustomData1:d,defaultCustomData2:l,defaultCustomData3:c,localStorageEnable:f});return Ay(v),D.jsxs("div",{className:"draftify-root",children:[h&&D.jsx(xy,{gridDots:w}),D.jsxs("div",{className:"draftify-container",children:[D.jsx(vy,{view:m,setView:b,blocksData:e,setPromptAction:k,setPromptVisiblility:j,handleCopy:p}),M&&D.jsx(wy,{docTitle:I,setDocTitle:S,description:E,setDescription:P,author:A,setAuthor:O,promptAction:T,handlePromptAction:y,setPromptVisiblility:j}),m==="editor"&&D.jsxs(D.Fragment,{children:[D.jsx(yy,{handleClick:C,options:n}),D.jsx("div",{className:"editor-area",onSubmit:ue=>ue.preventDefault(),children:D.jsx(dl.div,{style:{display:"grid",gap:"10px"},variants:G,animate:"show",exit:"hidden",children:D.jsx(Rd,{children:e.map((ue,ie)=>D.jsxs(dl.div,{layout:!0,variants:H,transition:te,whileHover:ge,draggable:!0,onDragStart:ne=>Q(ne,ie),onDragEnd:ne=>J(ne),onDragOver:ne=>ne.preventDefault(),onDragEnter:ne=>ee(ne),onDragLeave:ne=>Y(ne),onDrop:ne=>X(ne,ie),className:"block-container",children:[D.jsx(by,{}),D.jsx(gy,{block:ue,modifyHeading:R,modifySubheading:x,modifyParagraph:g,modifyQuote:_,modifyList:L,modifyTable:U,modifyImage:F,modifyVideo:N,modifyLink:W,modifyCode:B,modifyCustom:V,CustomEditor1:r,CustomEditor2:i,CustomEditor3:s}),D.jsx(Ye,{icon:["fas","trash"],className:"delete-icon",onClick:()=>le(ue.id)})]},ue.id))})})})]}),m==="preview"&&D.jsx("div",{className:"output-area",onSubmit:ue=>ue.preventDefault(),children:D.jsx(Pc,{blocksData:e,CustomOutput1:a,CustomOutput2:o,CustomOutput3:u})})]})]})}Se.DraftifyBlocksReader=Pc,Se.DraftifyReact=Ec,Se.default=Ec,Se.dragHandler=bc,Se.dragLeaveHandler=xc,Se.dropHandler=yc,Se.onFileChange=vc,Se.useDraftifyReact=Cc,Object.defineProperties(Se,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));