draftify-react 0.1.9 → 0.2.1

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(we,z){typeof exports=="object"&&typeof module<"u"?z(exports,require("react"),require("draftify")):typeof define=="function"&&define.amd?define(["exports","react","draftify"],z):(we=typeof globalThis<"u"?globalThis:we||self,z(we.DraftifyReact={},we.React,we.Draftify))})(this,(function(we,z,Z){"use strict";function vc(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 Sn=vc(z);var Tn={exports:{}},Kt={};var da;function bc(){if(da)return Kt;da=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,i,a){var s=null;if(a!==void 0&&(s=""+a),i.key!==void 0&&(s=""+i.key),"key"in i){a={};for(var o in i)o!=="key"&&(a[o]=i[o])}else a=i;return i=a.ref,{$$typeof:e,type:r,key:s,ref:i!==void 0?i:null,props:a}}return Kt.Fragment=t,Kt.jsx=n,Kt.jsxs=n,Kt}var Xt={};var ha;function xc(){return ha||(ha=1,process.env.NODE_ENV!=="production"&&(function(){function e(N){if(N==null)return null;if(typeof N=="function")return N.$$typeof===D?null:N.displayName||N.name||null;if(typeof N=="string")return N;switch(N){case A:return"Fragment";case I:return"Profiler";case v:return"StrictMode";case w:return"Suspense";case L:return"SuspenseList";case S:return"Activity"}if(typeof N=="object")switch(typeof N.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),N.$$typeof){case b:return"Portal";case C:return N.displayName||"Context";case T:return(N._context.displayName||"Context")+".Consumer";case P:var _=N.render;return N=N.displayName,N||(N=_.displayName||_.name||"",N=N!==""?"ForwardRef("+N+")":"ForwardRef"),N;case p:return _=N.displayName||null,_!==null?_:e(N.type)||"Memo";case y:_=N._payload,N=N._init;try{return e(N(_))}catch{}}return null}function t(N){return""+N}function n(N){try{t(N);var _=!1}catch{_=!0}if(_){_=console;var W=_.error,$=typeof Symbol=="function"&&Symbol.toStringTag&&N[Symbol.toStringTag]||N.constructor.name||"Object";return W.call(_,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",$),t(N)}}function r(N){if(N===A)return"<>";if(typeof N=="object"&&N!==null&&N.$$typeof===y)return"<...>";try{var _=e(N);return _?"<"+_+">":"<...>"}catch{return"<...>"}}function i(){var N=j.A;return N===null?null:N.getOwner()}function a(){return Error("react-stack-top-frame")}function s(N){if(F.call(N,"key")){var _=Object.getOwnPropertyDescriptor(N,"key").get;if(_&&_.isReactWarning)return!1}return N.key!==void 0}function o(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)",_))}W.isReactWarning=!0,Object.defineProperty(N,"key",{get:W,configurable:!0})}function u(){var N=e(this.type);return g[N]||(g[N]=!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.")),N=this.props.ref,N!==void 0?N:null}function d(N,_,W,$,M,H){var B=W.ref;return N={$$typeof:m,type:N,key:_,props:W,_owner:$},(B!==void 0?B:null)!==null?Object.defineProperty(N,"ref",{enumerable:!1,get:u}):Object.defineProperty(N,"ref",{enumerable:!1,value:null}),N._store={},Object.defineProperty(N._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(N,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(N,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:M}),Object.defineProperty(N,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:H}),Object.freeze&&(Object.freeze(N.props),Object.freeze(N)),N}function l(N,_,W,$,M,H){var B=_.children;if(B!==void 0)if($)if(E(B)){for($=0;$<B.length;$++)c(B[$]);Object.freeze&&Object.freeze(B)}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(B);if(F.call(_,"key")){B=e(N);var G=Object.keys(_).filter(function(J){return J!=="key"});$=0<G.length?"{key: someKey, "+G.join(": ..., ")+": ...}":"{key: someKey}",U[B+$]||(G=0<G.length?"{"+G.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
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_1bxps_1",optionButton:"_optionButton_1bxps_15",iconWrapper:"_iconWrapper_1bxps_53",subscript:"_subscript_1bxps_63"};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===I?null:F.displayName||F.name||null;if(typeof F=="string")return F;switch(F){case A:return"Fragment";case k:return"Profiler";case v:return"StrictMode";case w: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===A)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:
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,G,B),U[B+$]=!0)}if(B=null,W!==void 0&&(n(W),B=""+W),s(_)&&(n(_.key),B=""+_.key),"key"in _){W={};for(var Q in _)Q!=="key"&&(W[Q]=_[Q])}else W=_;return B&&o(W,typeof N=="function"?N.displayName||N.name||"Unknown":N),d(N,B,W,i(),M,H)}function c(N){f(N)?N._store&&(N._store.validated=1):typeof N=="object"&&N!==null&&N.$$typeof===y&&(N._payload.status==="fulfilled"?f(N._payload.value)&&N._payload.value._store&&(N._payload.value._store.validated=1):N._store&&(N._store.validated=1))}function f(N){return typeof N=="object"&&N!==null&&N.$$typeof===m}var h=z,m=Symbol.for("react.transitional.element"),b=Symbol.for("react.portal"),A=Symbol.for("react.fragment"),v=Symbol.for("react.strict_mode"),I=Symbol.for("react.profiler"),T=Symbol.for("react.consumer"),C=Symbol.for("react.context"),P=Symbol.for("react.forward_ref"),w=Symbol.for("react.suspense"),L=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),S=Symbol.for("react.activity"),D=Symbol.for("react.client.reference"),j=h.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,F=Object.prototype.hasOwnProperty,E=Array.isArray,R=console.createTask?console.createTask:function(){return null};h={react_stack_bottom_frame:function(N){return N()}};var x,g={},V=h.react_stack_bottom_frame.bind(h,a)(),O=R(r(a)),U={};Xt.Fragment=A,Xt.jsx=function(N,_,W){var $=1e4>j.recentlyCreatedOwnerStacks++;return l(N,_,W,!1,$?Error("react-stack-top-frame"):V,$?R(r(N)):O)},Xt.jsxs=function(N,_,W){var $=1e4>j.recentlyCreatedOwnerStacks++;return l(N,_,W,!0,$?Error("react-stack-top-frame"):V,$?R(r(N)):O)}})()),Xt}var ma;function wc(){return ma||(ma=1,process.env.NODE_ENV==="production"?Tn.exports=bc():Tn.exports=xc()),Tn.exports}var k=wc();const ur=z.createContext({});function cr(e){const t=z.useRef(null);return t.current===null&&(t.current=e()),t.current}const fr=typeof window<"u",pa=fr?z.useLayoutEffect:z.useEffect,Pn=z.createContext(null);function dr(e,t){e.indexOf(t)===-1&&e.push(t)}function hr(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Ge=(e,t,n)=>n>t?t:n<e?e:n;function mr(e,t){return t?`${e}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${t}`:e}let Ct=()=>{},Ke=()=>{};process.env.NODE_ENV!=="production"&&(Ct=(e,t,n)=>{!e&&typeof console<"u"&&console.warn(mr(t,n))},Ke=(e,t,n)=>{if(!e)throw new Error(mr(t,n))});const Xe={},ga=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function ya(e){return typeof e=="object"&&e!==null}const va=e=>/^0[^.\s]+$/u.test(e);function pr(e){let t;return()=>(t===void 0&&(t=e()),t)}const Ie=e=>e,Ac=(e,t)=>n=>t(e(n)),qt=(...e)=>e.reduce(Ac),Qt=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class gr{constructor(){this.subscriptions=[]}add(t){return dr(this.subscriptions,t),()=>hr(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 a=0;a<i;a++){const s=this.subscriptions[a];s&&s(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Oe=e=>e*1e3,je=e=>e/1e3;function ba(e,t){return t?e*(1e3/t):0}const xa=new Set;function yr(e,t,n){e||xa.has(t)||(console.warn(mr(t,n)),xa.add(t))}const wa=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Sc=1e-7,Tc=12;function Pc(e,t,n,r,i){let a,s,o=0;do s=t+(n-t)/2,a=wa(s,r,i)-e,a>0?n=s:t=s;while(Math.abs(a)>Sc&&++o<Tc);return s}function Zt(e,t,n,r){if(e===t&&n===r)return Ie;const i=a=>Pc(a,0,1,e,n);return a=>a===0||a===1?a:wa(i(a),t,r)}const Aa=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,Sa=e=>t=>1-e(1-t),Ta=Zt(.33,1.53,.69,.99),vr=Sa(Ta),Pa=Aa(vr),Ea=e=>(e*=2)<1?.5*vr(e):.5*(2-Math.pow(2,-10*(e-1))),br=e=>1-Math.sin(Math.acos(e)),Ca=Sa(br),ka=Aa(br),Ec=Zt(.42,0,1,1),Cc=Zt(0,0,.58,1),Ma=Zt(.42,0,.58,1),kc=e=>Array.isArray(e)&&typeof e[0]!="number",Da=e=>Array.isArray(e)&&typeof e[0]=="number",Ia={linear:Ie,easeIn:Ec,easeInOut:Ma,easeOut:Cc,circIn:br,circInOut:ka,circOut:Ca,backIn:vr,backInOut:Pa,backOut:Ta,anticipate:Ea},Mc=e=>typeof e=="string",ja=e=>{if(Da(e)){Ke(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,r,i]=e;return Zt(t,n,r,i)}else if(Mc(e))return Ke(Ia[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),Ia[e];return e},En=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function Dc(e,t){let n=new Set,r=new Set,i=!1,a=!1;const s=new WeakSet;let o={delta:0,timestamp:0,isProcessing:!1};function u(l){s.has(l)&&(d.schedule(l),e()),l(o)}const d={schedule:(l,c=!1,f=!1)=>{const m=f&&i?n:r;return c&&s.add(l),m.has(l)||m.add(l),l},cancel:l=>{r.delete(l),s.delete(l)},process:l=>{if(o=l,i){a=!0;return}i=!0,[n,r]=[r,n],n.forEach(u),n.clear(),i=!1,a&&(a=!1,d.process(l))}};return d}const Ic=40;function Fa(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},a=()=>n=!0,s=En.reduce((T,C)=>(T[C]=Dc(a),T),{}),{setup:o,read:u,resolveKeyframes:d,preUpdate:l,update:c,preRender:f,render:h,postRender:m}=s,b=()=>{const T=Xe.useManualTiming?i.timestamp:performance.now();n=!1,Xe.useManualTiming||(i.delta=r?1e3/60:Math.max(Math.min(T-i.timestamp,Ic),1)),i.timestamp=T,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))},A=()=>{n=!0,r=!0,i.isProcessing||e(b)};return{schedule:En.reduce((T,C)=>{const P=s[C];return T[C]=(w,L=!1,p=!1)=>(n||A(),P.schedule(w,L,p)),T},{}),cancel:T=>{for(let C=0;C<En.length;C++)s[En[C]].cancel(T)},state:i,steps:s}}const{schedule:re,cancel:nt,state:me,steps:xr}=Fa(typeof requestAnimationFrame<"u"?requestAnimationFrame:Ie,!0);let Cn;function jc(){Cn=void 0}const Pe={now:()=>(Cn===void 0&&Pe.set(me.isProcessing||Xe.useManualTiming?me.timestamp:performance.now()),Cn),set:e=>{Cn=e,queueMicrotask(jc)}},Na=e=>t=>typeof t=="string"&&t.startsWith(e),Oa=Na("--"),Fc=Na("var(--"),wr=e=>Fc(e)?Nc.test(e.split("/*")[0].trim()):!1,Nc=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,kt={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Jt={...kt,transform:e=>Ge(0,1,e)},kn={...kt,default:1},en=e=>Math.round(e*1e5)/1e5,Ar=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Oc(e){return e==null}const Lc=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Sr=(e,t)=>n=>!!(typeof n=="string"&&Lc.test(n)&&n.startsWith(e)||t&&!Oc(n)&&Object.prototype.hasOwnProperty.call(n,t)),La=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,a,s,o]=r.match(Ar);return{[e]:parseFloat(i),[t]:parseFloat(a),[n]:parseFloat(s),alpha:o!==void 0?parseFloat(o):1}},Rc=e=>Ge(0,255,e),Tr={...kt,transform:e=>Math.round(Rc(e))},dt={test:Sr("rgb","red"),parse:La("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Tr.transform(e)+", "+Tr.transform(t)+", "+Tr.transform(n)+", "+en(Jt.transform(r))+")"};function Vc(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 Pr={test:Sr("#"),parse:Vc,transform:dt.transform},tn=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),rt=tn("deg"),ze=tn("%"),X=tn("px"),_c=tn("vh"),Uc=tn("vw"),Ra={...ze,parse:e=>ze.parse(e)/100,transform:e=>ze.transform(e*100)},Mt={test:Sr("hsl","hue"),parse:La("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+ze.transform(en(t))+", "+ze.transform(en(n))+", "+en(Jt.transform(r))+")"},ue={test:e=>dt.test(e)||Pr.test(e)||Mt.test(e),parse:e=>dt.test(e)?dt.parse(e):Mt.test(e)?Mt.parse(e):Pr.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?dt.transform(e):Mt.transform(e),getAnimatableNone:e=>{const t=ue.parse(e);return t.alpha=0,ue.transform(t)}},$c=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function zc(e){return isNaN(e)&&typeof e=="string"&&(e.match(Ar)?.length||0)+(e.match($c)?.length||0)>0}const Va="number",_a="color",Bc="var",Wc="var(",Ua="${}",Hc=/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 nn(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let a=0;const o=t.replace(Hc,u=>(ue.test(u)?(r.color.push(a),i.push(_a),n.push(ue.parse(u))):u.startsWith(Wc)?(r.var.push(a),i.push(Bc),n.push(u)):(r.number.push(a),i.push(Va),n.push(parseFloat(u))),++a,Ua)).split(Ua);return{values:n,split:o,indexes:r,types:i}}function $a(e){return nn(e).values}function za(e){const{split:t,types:n}=nn(e),r=t.length;return i=>{let a="";for(let s=0;s<r;s++)if(a+=t[s],i[s]!==void 0){const o=n[s];o===Va?a+=en(i[s]):o===_a?a+=ue.transform(i[s]):a+=i[s]}return a}}const Yc=e=>typeof e=="number"?0:ue.test(e)?ue.getAnimatableNone(e):e;function Gc(e){const t=$a(e);return za(e)(t.map(Yc))}const it={test:zc,parse:$a,createTransformer:za,getAnimatableNone:Gc};function Er(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 Kc({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,a=0,s=0;if(!t)i=a=s=n;else{const o=n<.5?n*(1+t):n+t-n*t,u=2*n-o;i=Er(u,o,e+1/3),a=Er(u,o,e),s=Er(u,o,e-1/3)}return{red:Math.round(i*255),green:Math.round(a*255),blue:Math.round(s*255),alpha:r}}function Mn(e,t){return n=>n>0?t:e}const ae=(e,t,n)=>e+(t-e)*n,Cr=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},Xc=[Pr,dt,Mt],qc=e=>Xc.find(t=>t.test(e));function Ba(e){const t=qc(e);if(Ct(!!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=Kc(n)),n}const Wa=(e,t)=>{const n=Ba(e),r=Ba(t);if(!n||!r)return Mn(e,t);const i={...n};return a=>(i.red=Cr(n.red,r.red,a),i.green=Cr(n.green,r.green,a),i.blue=Cr(n.blue,r.blue,a),i.alpha=ae(n.alpha,r.alpha,a),dt.transform(i))},kr=new Set(["none","hidden"]);function Qc(e,t){return kr.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function Zc(e,t){return n=>ae(e,t,n)}function Mr(e){return typeof e=="number"?Zc:typeof e=="string"?wr(e)?Mn:ue.test(e)?Wa:tf:Array.isArray(e)?Ha:typeof e=="object"?ue.test(e)?Wa:Jc:Mn}function Ha(e,t){const n=[...e],r=n.length,i=e.map((a,s)=>Mr(a)(a,t[s]));return a=>{for(let s=0;s<r;s++)n[s]=i[s](a);return n}}function Jc(e,t){const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=Mr(e[i])(e[i],t[i]));return i=>{for(const a in r)n[a]=r[a](i);return n}}function ef(e,t){const n=[],r={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){const a=t.types[i],s=e.indexes[a][r[a]],o=e.values[s]??0;n[i]=o,r[a]++}return n}const tf=(e,t)=>{const n=it.createTransformer(t),r=nn(e),i=nn(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?kr.has(e)&&!i.values.length||kr.has(t)&&!r.values.length?Qc(e,t):qt(Ha(ef(r,i),i.values),n):(Ct(!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"),Mn(e,t))};function Ya(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?ae(e,t,n):Mr(e)(e,t)}const nf=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>re.update(t,n),stop:()=>nt(t),now:()=>me.isProcessing?me.timestamp:Pe.now()}},Ga=(e,t,n=10)=>{let r="";const i=Math.max(Math.round(t/n),2);for(let a=0;a<i;a++)r+=Math.round(e(a/(i-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},Dn=2e4;function Dr(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<Dn;)t+=n,r=e.next(t);return t>=Dn?1/0:t}function rf(e,t=100,n){const r=n({...e,keyframes:[0,t]}),i=Math.min(Dr(r),Dn);return{type:"keyframes",ease:a=>r.next(i*a).value/t,duration:je(i)}}const af=5;function Ka(e,t,n){const r=Math.max(t-af,0);return ba(n-e(r),t-r)}const se={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},Ir=.001;function sf({duration:e=se.duration,bounce:t=se.bounce,velocity:n=se.velocity,mass:r=se.mass}){let i,a;Ct(e<=Oe(se.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let s=1-t;s=Ge(se.minDamping,se.maxDamping,s),e=Ge(se.minDuration,se.maxDuration,je(e)),s<1?(i=d=>{const l=d*s,c=l*e,f=l-n,h=jr(d,s),m=Math.exp(-c);return Ir-f/h*m},a=d=>{const c=d*s*e,f=c*n+n,h=Math.pow(s,2)*Math.pow(d,2)*e,m=Math.exp(-c),b=jr(Math.pow(d,2),s);return(-i(d)+Ir>0?-1:1)*((f-h)*m)/b}):(i=d=>{const l=Math.exp(-d*e),c=(d-n)*e+1;return-Ir+l*c},a=d=>{const l=Math.exp(-d*e),c=(n-d)*(e*e);return l*c});const o=5/e,u=lf(i,a,o);if(e=Oe(e),isNaN(u))return{stiffness:se.stiffness,damping:se.damping,duration:e};{const d=Math.pow(u,2)*r;return{stiffness:d,damping:s*2*Math.sqrt(r*d),duration:e}}}const of=12;function lf(e,t,n){let r=n;for(let i=1;i<of;i++)r=r-e(r)/t(r);return r}function jr(e,t){return e*Math.sqrt(1-t*t)}const uf=["duration","bounce"],cf=["stiffness","damping","mass"];function Xa(e,t){return t.some(n=>e[n]!==void 0)}function ff(e){let t={velocity:se.velocity,stiffness:se.stiffness,damping:se.damping,mass:se.mass,isResolvedFromDuration:!1,...e};if(!Xa(e,cf)&&Xa(e,uf))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,a=2*Ge(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:se.mass,stiffness:i,damping:a}}else{const n=sf(e);t={...t,...n,mass:se.mass},t.isResolvedFromDuration=!0}return t}function In(e=se.visualDuration,t=se.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:i}=n;const a=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],o={done:!1,value:a},{stiffness:u,damping:d,mass:l,duration:c,velocity:f,isResolvedFromDuration:h}=ff({...n,velocity:-je(n.velocity||0)}),m=f||0,b=d/(2*Math.sqrt(u*l)),A=s-a,v=je(Math.sqrt(u/l)),I=Math.abs(A)<5;r||(r=I?se.restSpeed.granular:se.restSpeed.default),i||(i=I?se.restDelta.granular:se.restDelta.default);let T;if(b<1){const P=jr(v,b);T=w=>{const L=Math.exp(-b*v*w);return s-L*((m+b*v*A)/P*Math.sin(P*w)+A*Math.cos(P*w))}}else if(b===1)T=P=>s-Math.exp(-v*P)*(A+(m+v*A)*P);else{const P=v*Math.sqrt(b*b-1);T=w=>{const L=Math.exp(-b*v*w),p=Math.min(P*w,300);return s-L*((m+b*v*A)*Math.sinh(p)+P*A*Math.cosh(p))/P}}const C={calculatedDuration:h&&c||null,next:P=>{const w=T(P);if(h)o.done=P>=c;else{let L=P===0?m:0;b<1&&(L=P===0?Oe(m):Ka(T,P,w));const p=Math.abs(L)<=r,y=Math.abs(s-w)<=i;o.done=p&&y}return o.value=o.done?s:w,o},toString:()=>{const P=Math.min(Dr(C),Dn),w=Ga(L=>C.next(P*L).value,P,30);return P+"ms "+w},toTransition:()=>{}};return C}In.applyToOptions=e=>{const t=rf(e,100,In);return e.ease=t.ease,e.duration=Oe(t.duration),e.type="keyframes",e};function Fr({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:a=500,modifyTarget:s,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 A=c+b,v=s===void 0?A:s(A);v!==A&&(b=v-c);const I=p=>-b*Math.exp(-p/r),T=p=>v+I(p),C=p=>{const y=I(p),S=T(p);f.done=Math.abs(y)<=d,f.value=f.done?v:S};let P,w;const L=p=>{h(f.value)&&(P=p,w=In({keyframes:[f.value,m(f.value)],velocity:Ka(T,p,f.value),damping:i,stiffness:a,restDelta:d,restSpeed:l}))};return L(0),{calculatedDuration:null,next:p=>{let y=!1;return!w&&P===void 0&&(y=!0,C(p),L(p)),P!==void 0&&p>=P?w.next(p-P):(!y&&C(p),f)}}}function df(e,t,n){const r=[],i=n||Xe.mix||Ya,a=e.length-1;for(let s=0;s<a;s++){let o=i(e[s],e[s+1]);if(t){const u=Array.isArray(t)?t[s]||Ie:t;o=qt(u,o)}r.push(o)}return r}function hf(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const a=e.length;if(Ke(a===t.length,"Both input and output ranges must be the same length","range-length"),a===1)return()=>t[0];if(a===2&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[a-1]&&(e=[...e].reverse(),t=[...t].reverse());const o=df(t,r,i),u=o.length,d=l=>{if(s&&l<e[0])return t[0];let c=0;if(u>1)for(;c<e.length-2&&!(l<e[c+1]);c++);const f=Qt(e[c],e[c+1],l);return o[c](f)};return n?l=>d(Ge(e[0],e[a-1],l)):d}function mf(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=Qt(0,t,r);e.push(ae(n,1,i))}}function pf(e){const t=[0];return mf(t,e.length-1),t}function gf(e,t){return e.map(n=>n*t)}function yf(e,t){return e.map(()=>t||Ma).splice(0,e.length-1)}function Dt({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=kc(r)?r.map(ja):ja(r),a={done:!1,value:t[0]},s=gf(n&&n.length===t.length?n:pf(t),e),o=hf(s,t,{ease:Array.isArray(i)?i:yf(t,i)});return{calculatedDuration:e,next:u=>(a.value=o(u),a.done=u>=e,a)}}const vf=e=>e!==null;function Nr(e,{repeat:t,repeatType:n="loop"},r,i=1){const a=e.filter(vf),o=i<0||t&&n!=="loop"&&t%2===1?0:a.length-1;return!o||r===void 0?a[o]:r}const bf={decay:Fr,inertia:Fr,tween:Dt,keyframes:Dt,spring:In};function qa(e){typeof e.type=="string"&&(e.type=bf[e.type])}class Or{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 xf=e=>e/100;class Lr extends Or{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!==Pe.now()&&this.tick(Pe.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;qa(t);const{type:n=Dt,repeat:r=0,repeatDelay:i=0,repeatType:a,velocity:s=0}=t;let{keyframes:o}=t;const u=n||Dt;process.env.NODE_ENV!=="production"&&u!==Dt&&Ke(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(xf,Ya(o[0],o[1])),o=[0,100]);const d=u({...t,keyframes:o});a==="mirror"&&(this.mirroredGenerator=u({...t,keyframes:[...o].reverse(),velocity:-s})),d.calculatedDuration===null&&(d.calculatedDuration=Dr(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:a,mirroredGenerator:s,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:A}=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 T=this.currentTime,C=r;if(c){const p=Math.min(this.currentTime,i)/o;let y=Math.floor(p),S=p%1;!S&&p>=1&&(S=1),S===1&&y--,y=Math.min(y,c+1),y%2&&(f==="reverse"?(S=1-S,h&&(S-=h/o)):f==="mirror"&&(C=s)),T=Ge(0,1,S)*o}const P=I?{done:!1,value:l[0]}:C.next(T);a&&(P.value=a(P.value));let{done:w}=P;!I&&u!==null&&(w=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const L=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&w);return L&&m!==Fr&&(P.value=Nr(l,this.options,A,this.speed)),b&&b(P.value),L&&this.finish(),P}then(t,n){return this.finished.then(t,n)}get duration(){return je(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+je(t)}get time(){return je(this.currentTime)}set time(t){t=Oe(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(Pe.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=je(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=nf,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(Pe.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 wf(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const ht=e=>e*180/Math.PI,Rr=e=>{const t=ht(Math.atan2(e[1],e[0]));return Vr(t)},Af={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Rr,rotateZ:Rr,skewX:e=>ht(Math.atan(e[1])),skewY:e=>ht(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},Vr=e=>(e=e%360,e<0&&(e+=360),e),Qa=Rr,Za=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Ja=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Sf={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Za,scaleY:Ja,scale:e=>(Za(e)+Ja(e))/2,rotateX:e=>Vr(ht(Math.atan2(e[6],e[5]))),rotateY:e=>Vr(ht(Math.atan2(-e[2],e[0]))),rotateZ:Qa,rotate:Qa,skewX:e=>ht(Math.atan(e[4])),skewY:e=>ht(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function _r(e){return e.includes("scale")?1:0}function Ur(e,t){if(!e||e==="none")return _r(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,i;if(n)r=Sf,i=n;else{const o=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=Af,i=o}if(!i)return _r(t);const a=r[t],s=i[1].split(",").map(Pf);return typeof a=="function"?a(s):s[a]}const Tf=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return Ur(n,t)};function Pf(e){return parseFloat(e.trim())}const It=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],jt=new Set(It),es=e=>e===kt||e===X,Ef=new Set(["x","y","z"]),Cf=It.filter(e=>!Ef.has(e));function kf(e){const t=[];return Cf.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const mt={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})=>Ur(t,"x"),y:(e,{transform:t})=>Ur(t,"y")};mt.translateX=mt.x,mt.translateY=mt.y;const pt=new Set;let $r=!1,zr=!1,Br=!1;function ts(){if(zr){const e=Array.from(pt).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=kf(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(([a,s])=>{r.getValue(a)?.set(s)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}zr=!1,$r=!1,pt.forEach(e=>e.complete(Br)),pt.clear()}function ns(){pt.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(zr=!0)})}function Mf(){Br=!0,ns(),ts(),Br=!1}class Wr{constructor(t,n,r,i,a,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=a,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(pt.add(this),$r||($r=!0,re.read(ns),re.resolveKeyframes(ts))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;if(t[0]===null){const a=i?.get(),s=t[t.length-1];if(a!==void 0)t[0]=a;else if(r&&n){const o=r.readValue(n,s);o!=null&&(t[0]=o)}t[0]===void 0&&(t[0]=s),i&&a===void 0&&i.set(t[0])}wf(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),pt.delete(this)}cancel(){this.state==="scheduled"&&(pt.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const Df=e=>e.startsWith("--");function If(e,t,n){Df(t)?e.style.setProperty(t,n):e.style[t]=n}const jf=pr(()=>window.ScrollTimeline!==void 0),Ff={};function Nf(e,t){const n=pr(e);return()=>Ff[t]??n()}const rs=Nf(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),rn=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,is={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:rn([0,.65,.55,1]),circOut:rn([.55,0,1,.45]),backIn:rn([.31,.01,.66,-.59]),backOut:rn([.33,1.53,.69,.99])};function as(e,t){if(e)return typeof e=="function"?rs()?Ga(e,t):"ease-out":Da(e)?rn(e):Array.isArray(e)?e.map(n=>as(n,t)||is.easeOut):is[e]}function Of(e,t,n,{delay:r=0,duration:i=300,repeat:a=0,repeatType:s="loop",ease:o="easeOut",times:u}={},d=void 0){const l={[t]:n};u&&(l.offset=u);const c=as(o,i);Array.isArray(c)&&(l.easing=c);const f={delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:a+1,direction:s==="reverse"?"alternate":"normal"};return d&&(f.pseudoElement=d),e.animate(l,f)}function ss(e){return typeof e=="function"&&"applyToOptions"in e}function Lf({type:e,...t}){return ss(e)&&rs()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class Rf extends Or{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;const{element:n,name:r,keyframes:i,pseudoElement:a,allowFlatten:s=!1,finalKeyframe:o,onComplete:u}=t;this.isPseudoElement=!!a,this.allowFlatten=s,this.options=t,Ke(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const d=Lf(t);this.animation=Of(n,r,i,d,a),d.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!a){const l=Nr(i,this.options,o,this.speed);this.updateMotionValue?this.updateMotionValue(l):If(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 je(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+je(t)}get time(){return je(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=Oe(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&&jf()?(this.animation.timeline=t,Ie):n(this)}}const os={anticipate:Ea,backInOut:Pa,circInOut:ka};function Vf(e){return e in os}function _f(e){typeof e.ease=="string"&&Vf(e.ease)&&(e.ease=os[e.ease])}const ls=10;class Uf extends Rf{constructor(t){_f(t),qa(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:i,element:a,...s}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const o=new Lr({...s,autoplay:!1}),u=Oe(this.finishedTime??this.time);n.setWithVelocity(o.sample(u-ls).value,o.sample(u).value,ls),o.stop()}}const us=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(it.test(e)||e==="0")&&!e.startsWith("url("));function $f(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 zf(e,t,n,r){const i=e[0];if(i===null)return!1;if(t==="display"||t==="visibility")return!0;const a=e[e.length-1],s=us(i,t),o=us(a,t);return Ct(s===o,`You are trying to animate ${t} from "${i}" to "${a}". "${s?a:i}" is not an animatable value.`,"value-not-animatable"),!s||!o?!1:$f(e)||(n==="spring"||ss(n))&&r}function Hr(e){e.duration=0,e.type="keyframes"}const Bf=new Set(["opacity","clipPath","filter","transform"]),Wf=pr(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function Hf(e){const{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:a,type:s}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;const{onUpdate:u,transformTemplate:d}=t.owner.getProps();return Wf()&&n&&Bf.has(n)&&(n!=="transform"||!d)&&!u&&!r&&i!=="mirror"&&a!==0&&s!=="inertia"}const Yf=40;class Gf extends Or{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:a=0,repeatType:s="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=Pe.now();const f={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:a,repeatType:s,name:u,motionValue:d,element:l,...c},h=l?.KeyframeResolver||Wr;this.keyframeResolver=new h(o,(m,b,A)=>this.onKeyframesResolved(m,b,f,!A),u,d,l),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,n,r,i){this.keyframeResolver=void 0;const{name:a,type:s,velocity:o,delay:u,isHandoff:d,onUpdate:l}=r;this.resolvedAt=Pe.now(),zf(t,a,s,o)||((Xe.instantAnimations||!u)&&l?.(Nr(t,r,n)),t[0]=t[t.length-1],Hr(r),r.repeat=0);const f={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>Yf?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},h=!d&&Hf(f)?new Uf({...f,element:f.motionValue.owner.current}):new Lr(f);h.finished.then(()=>this.notifyFinished()).catch(Ie),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(),Mf()),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 Kf=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Xf(e){const t=Kf.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}const qf=4;function cs(e,t,n=1){Ke(n<=qf,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[r,i]=Xf(e);if(!r)return;const a=window.getComputedStyle(t).getPropertyValue(r);if(a){const s=a.trim();return ga(s)?parseFloat(s):s}return wr(i)?cs(i,t,n+1):i}function Yr(e,t){return e?.[t]??e?.default??e}const fs=new Set(["width","height","top","left","right","bottom",...It]),Qf={test:e=>e==="auto",parse:e=>e},ds=e=>t=>t.test(e),hs=[kt,X,ze,rt,Uc,_c,Qf],ms=e=>hs.find(ds(e));function Zf(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||va(e):!0}const Jf=new Set(["brightness","contrast","saturate","opacity"]);function ed(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Ar)||[];if(!r)return e;const i=n.replace(r,"");let a=Jf.has(t)?1:0;return r!==n&&(a*=100),t+"("+a+i+")"}const td=/\b([a-z-]*)\(.*?\)/gu,Gr={...it,getAnimatableNone:e=>{const t=e.match(td);return t?t.map(ed).join(" "):e}},ps={...kt,transform:Math.round},Kr={borderWidth:X,borderTopWidth:X,borderRightWidth:X,borderBottomWidth:X,borderLeftWidth:X,borderRadius:X,radius:X,borderTopLeftRadius:X,borderTopRightRadius:X,borderBottomRightRadius:X,borderBottomLeftRadius:X,width:X,maxWidth:X,height:X,maxHeight:X,top:X,right:X,bottom:X,left:X,padding:X,paddingTop:X,paddingRight:X,paddingBottom:X,paddingLeft:X,margin:X,marginTop:X,marginRight:X,marginBottom:X,marginLeft:X,backgroundPositionX:X,backgroundPositionY:X,...{rotate:rt,rotateX:rt,rotateY:rt,rotateZ:rt,scale:kn,scaleX:kn,scaleY:kn,scaleZ:kn,skew:rt,skewX:rt,skewY:rt,distance:X,translateX:X,translateY:X,translateZ:X,x:X,y:X,z:X,perspective:X,transformPerspective:X,opacity:Jt,originX:Ra,originY:Ra,originZ:X},zIndex:ps,fillOpacity:Jt,strokeOpacity:Jt,numOctaves:ps},nd={...Kr,color:ue,backgroundColor:ue,outlineColor:ue,fill:ue,stroke:ue,borderColor:ue,borderTopColor:ue,borderRightColor:ue,borderBottomColor:ue,borderLeftColor:ue,filter:Gr,WebkitFilter:Gr},gs=e=>nd[e];function ys(e,t){let n=gs(e);return n!==Gr&&(n=it),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const rd=new Set(["auto","none","0"]);function id(e,t,n){let r=0,i;for(;r<e.length&&!i;){const a=e[r];typeof a=="string"&&!rd.has(a)&&nn(a).values.length&&(i=e[r]),r++}if(i&&n)for(const a of t)e[a]=ys(n,i)}class ad extends Wr{constructor(t,n,r,i,a){super(t,n,r,i,a,!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(),wr(d))){const l=cs(d,n.current);l!==void 0&&(t[u]=l),u===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!fs.has(r)||t.length!==2)return;const[i,a]=t,s=ms(i),o=ms(a);if(s!==o)if(es(s)&&es(o))for(let u=0;u<t.length;u++){const d=t[u];typeof d=="string"&&(t[u]=parseFloat(d))}else mt[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let i=0;i<t.length;i++)(t[i]===null||Zf(t[i]))&&r.push(i);r.length&&id(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=mt[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 a=r.length-1,s=r[a];r[a]=mt[n](t.measureViewportBox(),window.getComputedStyle(t.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),this.removedTransforms?.length&&this.removedTransforms.forEach(([o,u])=>{t.getValue(o).set(u)}),this.resolveNoneKeyframes()}}function sd(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 vs=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function bs(e){return ya(e)&&"offsetHeight"in e}const xs=30,od=e=>!isNaN(parseFloat(e));class ld{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{const i=Pe.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 a of this.dependents)a.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=Pe.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=od(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&yr(!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 gr);const r=this.events[t].add(n);return t==="change"?()=>{r(),re.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=Pe.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>xs)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,xs);return ba(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 Ft(e,t){return new ld(e,t)}const{schedule:Xr}=Fa(queueMicrotask,!1),Le={x:!1,y:!1};function ws(){return Le.x||Le.y}function ud(e){return e==="x"||e==="y"?Le[e]?null:(Le[e]=!0,()=>{Le[e]=!1}):Le.x||Le.y?null:(Le.x=Le.y=!0,()=>{Le.x=Le.y=!1})}function As(e,t){const n=sd(e),r=new AbortController,i={passive:!0,...t,signal:r.signal};return[n,i,()=>r.abort()]}function Ss(e){return!(e.pointerType==="touch"||ws())}function cd(e,t,n={}){const[r,i,a]=As(e,n),s=o=>{if(!Ss(o))return;const{target:u}=o,d=t(u,o);if(typeof d!="function"||!u)return;const l=c=>{Ss(c)&&(d(c),u.removeEventListener("pointerleave",l))};u.addEventListener("pointerleave",l,i)};return r.forEach(o=>{o.addEventListener("pointerenter",s,i)}),a}const Ts=(e,t)=>t?e===t?!0:Ts(e,t.parentElement):!1,qr=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,fd=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function dd(e){return fd.has(e.tagName)||e.tabIndex!==-1}const jn=new WeakSet;function Ps(e){return t=>{t.key==="Enter"&&e(t)}}function Qr(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const hd=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=Ps(()=>{if(jn.has(n))return;Qr(n,"down");const i=Ps(()=>{Qr(n,"up")}),a=()=>Qr(n,"cancel");n.addEventListener("keyup",i,t),n.addEventListener("blur",a,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function Es(e){return qr(e)&&!ws()}function md(e,t,n={}){const[r,i,a]=As(e,n),s=o=>{const u=o.currentTarget;if(!Es(o))return;jn.add(u);const d=t(u,o),l=(h,m)=>{window.removeEventListener("pointerup",c),window.removeEventListener("pointercancel",f),jn.has(u)&&jn.delete(u),Es(h)&&typeof d=="function"&&d(h,{success:m})},c=h=>{l(h,u===window||u===document||n.useGlobalTarget||Ts(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",s,i),bs(o)&&(o.addEventListener("focus",d=>hd(d,i)),!dd(o)&&!o.hasAttribute("tabindex")&&(o.tabIndex=0))}),a}function Cs(e){return ya(e)&&"ownerSVGElement"in e}function pd(e){return Cs(e)&&e.tagName==="svg"}const ye=e=>!!(e&&e.getVelocity),gd=[...hs,ue,it],yd=e=>gd.find(ds(e)),Zr=z.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function ks(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function vd(...e){return t=>{let n=!1;const r=e.map(i=>{const a=ks(i,t);return!n&&typeof a=="function"&&(n=!0),a});if(n)return()=>{for(let i=0;i<r.length;i++){const a=r[i];typeof a=="function"?a():ks(e[i],null)}}}}function bd(...e){return Sn.useCallback(vd(...e),e)}class xd extends Sn.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=n.offsetParent,i=bs(r)&&r.offsetWidth||0,a=this.props.sizeRef.current;a.height=n.offsetHeight||0,a.width=n.offsetWidth||0,a.top=n.offsetTop,a.left=n.offsetLeft,a.right=i-a.width-a.left}return null}componentDidUpdate(){}render(){return this.props.children}}function wd({children:e,isPresent:t,anchorX:n,root:r}){const i=z.useId(),a=z.useRef(null),s=z.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:o}=z.useContext(Zr),u=bd(a,e?.ref);return z.useInsertionEffect(()=>{const{width:d,height:l,top:c,left:f,right:h}=s.current;if(t||!a.current||!d||!l)return;const m=n==="left"?`left: ${f}`:`right: ${h}`;a.current.dataset.motionPopId=i;const b=document.createElement("style");o&&(b.nonce=o);const A=r??document.head;return A.appendChild(b),b.sheet&&b.sheet.insertRule(`
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"),A=Symbol.for("react.fragment"),v=Symbol.for("react.strict_mode"),k=Symbol.for("react.profiler"),S=Symbol.for("react.consumer"),E=Symbol.for("react.context"),P=Symbol.for("react.forward_ref"),w=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"),I=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=A,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 kt=()=>{},qe=()=>{};process.env.NODE_ENV!=="production"&&(kt=(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),ks=e=>(e*=2)<1?.5*xr(e):.5*(2-Math.pow(2,-10*(e-1))),wr=e=>1-Math.sin(Math.acos(e)),Is=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:Is,backIn:xr,backInOut:Es,backOut:Cs,anticipate:ks},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},kn=["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=kn.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))},A=()=>{n=!0,r=!0,i.isProcessing||e(b)};return{schedule:kn.reduce((S,E)=>{const P=a[E];return S[E]=(w,O=!1,p=!1)=>(n||A(),P.schedule(w,O,p)),S},{}),cancel:S=>{for(let E=0;E<kn.length;E++)a[kn[E]].cancel(S)},state:i,steps:a}}const{schedule:oe,cancel:it,state:ge,steps:Ar}=Os(typeof requestAnimationFrame<"u"?requestAnimationFrame:Fe,!0);let In;function Wc(){In=void 0}const Ee={now:()=>(In===void 0&&Ee.set(ge.isProcessing||Qe.useManualTiming?ge.timestamp:performance.now()),In),set:e=>{In=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,It={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},en={...It,transform:e=>Xe(0,1,e)},Mn={...It,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={...It,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 kr(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=kr(u,o,e+1/3),s=kr(u,o,e),a=kr(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,Ir=(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(kt(!!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=Ir(n.red,r.red,s),i.green=Ir(n.green,r.green,s),i.blue=Ir(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):(kt(!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;kt(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)),A=a-s,v=Le(Math.sqrt(u/l)),k=Math.abs(A)<5;r||(r=k?ce.restSpeed.granular:ce.restSpeed.default),i||(i=k?ce.restDelta.granular:ce.restDelta.default);let S;if(b<1){const P=Lr(v,b);S=w=>{const O=Math.exp(-b*v*w);return a-O*((m+b*v*A)/P*Math.sin(P*w)+A*Math.cos(P*w))}}else if(b===1)S=P=>a-Math.exp(-v*P)*(A+(m+v*A)*P);else{const P=v*Math.sqrt(b*b-1);S=w=>{const O=Math.exp(-b*v*w),p=Math.min(P*w,300);return a-O*((m+b*v*A)*Math.sinh(p)+P*A*Math.cosh(p))/P}}const E={calculatedDuration:h&&c||null,next:P=>{const w=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,w));const p=Math.abs(O)<=r,y=Math.abs(a-w)<=i;o.done=p&&y}return o.value=o.done?a:w,o},toString:()=>{const P=Math.min(jr(E),jn),w=Xs(O=>E.next(P*O).value,P,30);return P+"ms "+w},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 A=c+b,v=a===void 0?A:a(A);v!==A&&(b=v-c);const k=p=>-b*Math.exp(-p/r),S=p=>v+k(p),E=p=>{const y=k(p),T=S(p);f.done=Math.abs(y)<=d,f.value=f.done?v:T};let P,w;const O=p=>{h(f.value)&&(P=p,w=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!w&&P===void 0&&(y=!0,E(p),O(p)),P!==void 0&&p>=P?w.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 kf(e,t){return e.map(n=>n*t)}function If(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=kf(n&&n.length===t.length?n:Ef(t),e),o=Pf(a,t,{ease:Array.isArray(i)?i:If(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:A}=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),k=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=k?{done:!1,value:l[0]}:E.next(S);s&&(P.value=s(P.value));let{done:w}=P;!k&&u!==null&&(w=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const O=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&w);return O&&m!==Or&&(P.value=Rr(l,this.options,A,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===It||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:ks,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 kt(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,A)=>this.onKeyframesResolved(m,b,f,!A),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=[It,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={...It,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 ka(e){return Zr(e)&&!Sa()}function Cd(e,t,n={}){const[r,i,s]=Ta(e,n),a=o=>{const u=o.currentTarget;if(!ka(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),ka(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 Ia(e){return bs(e)&&"ownerSVGElement"in e}function Ed(e){return Ia(e)&&e.tagName==="svg"}const be=e=>!!(e&&e.getVelocity),kd=[...pa,fe,at],Id=e=>kd.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 A=r??document.head;return A.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
- `),()=>{A.contains(b)&&A.removeChild(b)}},[t]),k.jsx(xd,{isPresent:t,childRef:a,sizeRef:s,children:Sn.cloneElement(e,{ref:u})})}const Ad=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:i,presenceAffectsLayout:a,mode:s,anchorX:o,root:u})=>{const d=cr(Sd),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 a&&c&&(f={...f}),z.useMemo(()=>{d.forEach((h,m)=>d.set(m,!1))},[n]),Sn.useEffect(()=>{!n&&!d.size&&r&&r()},[n]),s==="popLayout"&&(e=k.jsx(wd,{isPresent:n,anchorX:o,root:u,children:e})),k.jsx(Pn.Provider,{value:f,children:e})};function Sd(){return new Map}function Ms(e=!0){const t=z.useContext(Pn);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:i}=t,a=z.useId();z.useEffect(()=>{if(e)return i(a)},[e]);const s=z.useCallback(()=>e&&r&&r(a),[a,r,e]);return!n&&r?[!1,s]:[!0]}const Fn=e=>e.key||"";function Ds(e){const t=[];return z.Children.forEach(e,n=>{z.isValidElement(n)&&t.push(n)}),t}const Td=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:i=!0,mode:a="sync",propagate:s=!1,anchorX:o="left",root:u})=>{const[d,l]=Ms(s),c=z.useMemo(()=>Ds(e),[e]),f=s&&!d?[]:c.map(Fn),h=z.useRef(!0),m=z.useRef(c),b=cr(()=>new Map),[A,v]=z.useState(c),[I,T]=z.useState(c);pa(()=>{h.current=!1,m.current=c;for(let w=0;w<I.length;w++){const L=Fn(I[w]);f.includes(L)?b.delete(L):b.get(L)!==!0&&b.set(L,!1)}},[I,f.length,f.join("-")]);const C=[];if(c!==A){let w=[...c];for(let L=0;L<I.length;L++){const p=I[L],y=Fn(p);f.includes(y)||(w.splice(L,0,p),C.push(p))}return a==="wait"&&C.length&&(w=C),T(Ds(w)),v(c),null}process.env.NODE_ENV!=="production"&&a==="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(ur);return k.jsx(k.Fragment,{children:I.map(w=>{const L=Fn(w),p=s&&!d?!1:c===I||f.includes(L),y=()=>{if(b.has(L))b.set(L,!0);else return;let S=!0;b.forEach(D=>{D||(S=!1)}),S&&(P?.(),T(m.current),s&&l?.(),r&&r())};return k.jsx(Ad,{isPresent:p,initial:!h.current||n?void 0:!1,custom:t,presenceAffectsLayout:i,mode:a,root:u,onExitComplete:p?void 0:y,anchorX:o,children:w},L)})})},Is=z.createContext({strict:!1}),js={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"]},Nt={};for(const e in js)Nt[e]={isEnabled:t=>js[e].some(n=>!!t[n])};function Pd(e){for(const t in e)Nt[t]={...Nt[t],...e[t]}}const Ed=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 Nn(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Ed.has(e)}let Fs=e=>!Nn(e);function Cd(e){typeof e=="function"&&(Fs=t=>t.startsWith("on")?!Nn(t):e(t))}try{Cd(require("@emotion/is-prop-valid").default)}catch{}function kd(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(Fs(i)||n===!0&&Nn(i)||!t&&!Nn(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}const On=z.createContext({});function Ln(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function an(e){return typeof e=="string"||Array.isArray(e)}const Jr=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],ei=["initial",...Jr];function Rn(e){return Ln(e.animate)||ei.some(t=>an(e[t]))}function Ns(e){return!!(Rn(e)||e.variants)}function Md(e,t){if(Rn(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 Dd(e){const{initial:t,animate:n}=Md(e,z.useContext(On));return z.useMemo(()=>({initial:t,animate:n}),[Os(t),Os(n)])}function Os(e){return Array.isArray(e)?e.join(" "):e}function Ls(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const sn={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(X.test(e))e=parseFloat(e);else return e;const n=Ls(e,t.target.x),r=Ls(e,t.target.y);return`${n}% ${r}%`}},Id={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=it.parse(e);if(i.length>5)return r;const a=it.createTransformer(e),s=typeof i[0]!="number"?1:0,o=n.x.scale*t.x,u=n.y.scale*t.y;i[0+s]/=o,i[1+s]/=u;const d=ae(o,u,.5);return typeof i[2+s]=="number"&&(i[2+s]/=d),typeof i[3+s]=="number"&&(i[3+s]/=d),a(i)}},ti={borderRadius:{...sn,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:sn,borderTopRightRadius:sn,borderBottomLeftRadius:sn,borderBottomRightRadius:sn,boxShadow:Id};function Rs(e,{layout:t,layoutId:n}){return jt.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!ti[e]||e==="opacity")}const jd={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Fd=It.length;function Nd(e,t,n){let r="",i=!0;for(let a=0;a<Fd;a++){const s=It[a],o=e[s];if(o===void 0)continue;let u=!0;if(typeof o=="number"?u=o===(s.startsWith("scale")?1:0):u=parseFloat(o)===0,!u||n){const d=vs(o,Kr[s]);if(!u){i=!1;const l=jd[s]||s;r+=`${l}(${d}) `}n&&(t[s]=d)}}return r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}function ni(e,t,n){const{style:r,vars:i,transformOrigin:a}=e;let s=!1,o=!1;for(const u in t){const d=t[u];if(jt.has(u)){s=!0;continue}else if(Oa(u)){i[u]=d;continue}else{const l=vs(d,Kr[u]);u.startsWith("origin")?(o=!0,a[u]=l):r[u]=l}}if(t.transform||(s||n?r.transform=Nd(t,e.transform,n):r.transform&&(r.transform="none")),o){const{originX:u="50%",originY:d="50%",originZ:l=0}=a;r.transformOrigin=`${u} ${d} ${l}`}}const ri=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Vs(e,t,n){for(const r in t)!ye(t[r])&&!Rs(r,n)&&(e[r]=t[r])}function Od({transformTemplate:e},t){return z.useMemo(()=>{const n=ri();return ni(n,t,e),Object.assign({},n.vars,n.style)},[t])}function Ld(e,t){const n=e.style||{},r={};return Vs(r,n,e),Object.assign(r,Od(e,t)),r}function Rd(e,t){const n={},r=Ld(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 Vd={offset:"stroke-dashoffset",array:"stroke-dasharray"},_d={offset:"strokeDashoffset",array:"strokeDasharray"};function Ud(e,t,n=1,r=0,i=!0){e.pathLength=1;const a=i?Vd:_d;e[a.offset]=X.transform(-r);const s=X.transform(t),o=X.transform(n);e[a.array]=`${s} ${o}`}function _s(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:a=1,pathOffset:s=0,...o},u,d,l){if(ni(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&&Ud(c,i,a,s,!1)}const Us=()=>({...ri(),attrs:{}}),$s=e=>typeof e=="string"&&e.toLowerCase()==="svg";function $d(e,t,n,r){const i=z.useMemo(()=>{const a=Us();return _s(a,t,$s(r),e.transformTemplate,e.style),{...a.attrs,style:{...a.style}}},[t]);if(e.style){const a={};Vs(a,e.style,e),i.style={...a,...i.style}}return i}const zd=["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 ii(e){return typeof e!="string"||e.includes("-")?!1:!!(zd.indexOf(e)>-1||/[A-Z]/u.test(e))}function Bd(e,t,n,{latestValues:r},i,a=!1){const o=(ii(e)?$d:Rd)(t,r,i,e),u=kd(t,typeof e=="string",a),d=e!==z.Fragment?{...u,...o,ref:n}:{},{children:l}=t,c=z.useMemo(()=>ye(l)?l.get():l,[l]);return z.createElement(e,{...d,children:c})}function zs(e){const t=[{},{}];return e?.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function ai(e,t,n,r){if(typeof t=="function"){const[i,a]=zs(r);t=t(n!==void 0?n:e.custom,i,a)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,a]=zs(r);t=t(n!==void 0?n:e.custom,i,a)}return t}function Vn(e){return ye(e)?e.get():e}function Wd({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:Hd(n,r,i,e),renderState:t()}}function Hd(e,t,n,r){const i={},a=r(e,{});for(const f in a)i[f]=Vn(a[f]);let{initial:s,animate:o}=e;const u=Rn(e),d=Ns(e);t&&d&&!u&&e.inherit!==!1&&(s===void 0&&(s=t.initial),o===void 0&&(o=t.animate));let l=n?n.initial===!1:!1;l=l||s===!1;const c=l?o:s;if(c&&typeof c!="boolean"&&!Ln(c)){const f=Array.isArray(c)?c:[c];for(let h=0;h<f.length;h++){const m=ai(e,f[h]);if(m){const{transitionEnd:b,transition:A,...v}=m;for(const I in v){let T=v[I];if(Array.isArray(T)){const C=l?T.length-1:0;T=T[C]}T!==null&&(i[I]=T)}for(const I in b)i[I]=b[I]}}}return i}const Bs=e=>(t,n)=>{const r=z.useContext(On),i=z.useContext(Pn),a=()=>Wd(e,t,r,i);return n?a():cr(a)};function si(e,t,n){const{style:r}=e,i={};for(const a in r)(ye(r[a])||t.style&&ye(t.style[a])||Rs(a,e)||n?.getValue(a)?.liveStyle!==void 0)&&(i[a]=r[a]);return i}const Yd=Bs({scrapeMotionValuesFromProps:si,createRenderState:ri});function Ws(e,t,n){const r=si(e,t,n);for(const i in e)if(ye(e[i])||ye(t[i])){const a=It.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[a]=e[i]}return r}const Gd=Bs({scrapeMotionValuesFromProps:Ws,createRenderState:Us}),Kd=Symbol.for("motionComponentSymbol");function Ot(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function Xd(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):Ot(n)&&(n.current=r))},[t])}const oi=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),Hs="data-"+oi("framerAppearId"),Ys=z.createContext({});function qd(e,t,n,r,i){const{visualElement:a}=z.useContext(On),s=z.useContext(Is),o=z.useContext(Pn),u=z.useContext(Zr).reducedMotion,d=z.useRef(null);r=r||s.renderer,!d.current&&r&&(d.current=r(e,{visualState:t,parent:a,props:n,presenceContext:o,blockInitialAnimation:o?o.initial===!1:!1,reducedMotionConfig:u}));const l=d.current,c=z.useContext(Ys);l&&!l.projection&&i&&(l.type==="html"||l.type==="svg")&&Qd(d.current,n,i,c);const f=z.useRef(!1);z.useInsertionEffect(()=>{l&&f.current&&l.update(n,o)});const h=n[Hs],m=z.useRef(!!h&&!window.MotionHandoffIsComplete?.(h)&&window.MotionHasOptimisedAnimation?.(h));return pa(()=>{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 Qd(e,t,n,r){const{layoutId:i,layout:a,drag:s,dragConstraints:o,layoutScroll:u,layoutRoot:d,layoutCrossfade:l}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Gs(e.parent)),e.projection.setOptions({layoutId:i,layout:a,alwaysMeasureLayout:!!s||o&&Ot(o),visualElement:e,animationType:typeof a=="string"?a:"both",initialPromotionConfig:r,crossfade:l,layoutScroll:u,layoutRoot:d})}function Gs(e){if(e)return e.options.allowProjection!==!1?e.projection:Gs(e.parent)}function li(e,{forwardMotionProps:t=!1}={},n,r){n&&Pd(n);const i=ii(e)?Gd:Yd;function a(o,u){let d;const l={...z.useContext(Zr),...o,layoutId:Zd(o)},{isStatic:c}=l,f=Dd(o),h=i(o,c);if(!c&&fr){Jd(l,n);const m=eh(l);d=m.MeasureLayout,f.visualElement=qd(e,h,l,r,m.ProjectionNode)}return k.jsxs(On.Provider,{value:f,children:[d&&f.visualElement?k.jsx(d,{visualElement:f.visualElement,...l}):null,Bd(e,o,Xd(h,f.visualElement,u),h,c,t)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const s=z.forwardRef(a);return s[Kd]=e,s}function Zd({layoutId:e}){const t=z.useContext(ur).id;return t&&e!==void 0?t+"-"+e:e}function Jd(e,t){const n=z.useContext(Is).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?Ct(!1,r,"lazy-strict-mode"):Ke(!1,r,"lazy-strict-mode")}}function eh(e){const{drag:t,layout:n}=Nt;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t?.isEnabled(e)||n?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function th(e,t){if(typeof Proxy>"u")return li;const n=new Map,r=(a,s)=>li(a,s,e,t),i=(a,s)=>(process.env.NODE_ENV!=="production"&&yr(!1,"motion() is deprecated. Use motion.create() instead."),r(a,s));return new Proxy(i,{get:(a,s)=>s==="create"?r:(n.has(s)||n.set(s,li(s,void 0,e,t)),n.get(s))})}function Ks({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function nh({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function rh(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 ui(e){return e===void 0||e===1}function ci({scale:e,scaleX:t,scaleY:n}){return!ui(e)||!ui(t)||!ui(n)}function gt(e){return ci(e)||Xs(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Xs(e){return qs(e.x)||qs(e.y)}function qs(e){return e&&e!=="0%"}function _n(e,t,n){const r=e-n,i=t*r;return n+i}function Qs(e,t,n,r,i){return i!==void 0&&(e=_n(e,i,r)),_n(e,n,r)+t}function fi(e,t=0,n=1,r,i){e.min=Qs(e.min,t,n,r,i),e.max=Qs(e.max,t,n,r,i)}function Zs(e,{x:t,y:n}){fi(e.x,t.translate,t.scale,t.originPoint),fi(e.y,n.translate,n.scale,n.originPoint)}const Js=.999999999999,eo=1.0000000000001;function ih(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let a,s;for(let o=0;o<i;o++){a=n[o],s=a.projectionDelta;const{visualElement:u}=a.options;u&&u.props.style&&u.props.style.display==="contents"||(r&&a.options.layoutScroll&&a.scroll&&a!==a.root&&Rt(e,{x:-a.scroll.offset.x,y:-a.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Zs(e,s)),r&&gt(a.latestValues)&&Rt(e,a.latestValues))}t.x<eo&&t.x>Js&&(t.x=1),t.y<eo&&t.y>Js&&(t.y=1)}function Lt(e,t){e.min=e.min+t,e.max=e.max+t}function to(e,t,n,r,i=.5){const a=ae(e.min,e.max,i);fi(e,t,n,a,r)}function Rt(e,t){to(e.x,t.x,t.scaleX,t.scale,t.originX),to(e.y,t.y,t.scaleY,t.scale,t.originY)}function no(e,t){return Ks(rh(e.getBoundingClientRect(),t))}function ah(e,t,n){const r=no(e,n),{scroll:i}=t;return i&&(Lt(r.x,i.offset.x),Lt(r.y,i.offset.y)),r}const ro=()=>({translate:0,scale:1,origin:0,originPoint:0}),Vt=()=>({x:ro(),y:ro()}),io=()=>({min:0,max:0}),de=()=>({x:io(),y:io()}),di={current:null},ao={current:!1};function sh(){if(ao.current=!0,!!fr)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>di.current=e.matches;e.addEventListener("change",t),t()}else di.current=!1}const oh=new WeakMap;function lh(e,t,n){for(const r in t){const i=t[r],a=n[r];if(ye(i))e.addValue(r,i);else if(ye(a))e.addValue(r,Ft(i,{owner:e}));else if(a!==i)if(e.hasValue(r)){const s=e.getValue(r);s.liveStyle===!0?s.jump(i):s.hasAnimated||s.set(i)}else{const s=e.getStaticValue(r);e.addValue(r,Ft(s!==void 0?s:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const so=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class uh{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,blockInitialAnimation:a,visualState:s},o={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Wr,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=Pe.now();this.renderScheduledAt<f&&(this.renderScheduledAt=f,re.render(this.render,!1,!0))};const{latestValues:u,renderState:d}=s;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=!!a,this.isControllingVariants=Rn(n),this.isVariantNode=Ns(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&&ye(h)&&h.set(u[f])}}mount(t){this.current=t,oh.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)),ao.current||sh(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:di.current,process.env.NODE_ENV!=="production"&&yr(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(),nt(this.notifyUpdate),nt(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=jt.has(t);r&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&re.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let a;window.MotionCheckAppearSync&&(a=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),a&&a(),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 Nt){const n=Nt[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 a=this.features[t];a.isMounted?a.update():(a.mount(),a.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):de()}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<so.length;r++){const i=so[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const a="on"+i,s=t[a];s&&(this.propEventSubscriptions[i]=this.on(i,s))}this.prevMotionValues=lh(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=Ft(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"&&(ga(r)||va(r))?r=parseFloat(r):!yd(r)&&it.test(n)&&(r=ys(t,n)),this.setBaseTarget(t,ye(r)?r.get():r)),ye(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 a=ai(this.props,n,this.presenceContext?.custom);a&&(r=a[t])}if(n&&r!==void 0)return r;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!ye(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 gr),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Xr.render(this.render)}}class oo extends uh{constructor(){super(...arguments),this.KeyframeResolver=ad}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;ye(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function lo(e,{style:t,vars:n},r,i){const a=e.style;let s;for(s in t)a[s]=t[s];i?.applyProjectionStyles(a,r);for(s in n)a.setProperty(s,n[s])}function ch(e){return window.getComputedStyle(e)}class fh extends oo{constructor(){super(...arguments),this.type="html",this.renderInstance=lo}readValueFromInstance(t,n){if(jt.has(n))return this.projection?.isProjecting?_r(n):Tf(t,n);{const r=ch(t),i=(Oa(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return no(t,n)}build(t,n,r){ni(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return si(t,n,r)}}const uo=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 dh(e,t,n,r){lo(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(uo.has(i)?i:oi(i),t.attrs[i])}class hh extends oo{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=de}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(jt.has(n)){const r=gs(n);return r&&r.default||0}return n=uo.has(n)?n:oi(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return Ws(t,n,r)}build(t,n,r){_s(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,i){dh(t,n,r,i)}mount(t){this.isSVGTag=$s(t.tagName),super.mount(t)}}const mh=(e,t)=>ii(e)?new hh(t):new fh(t,{allowProjection:e!==z.Fragment});function _t(e,t,n){const r=e.getProps();return ai(r,t,n!==void 0?n:r.custom,e)}const hi=e=>Array.isArray(e);function ph(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Ft(n))}function gh(e){return hi(e)?e[e.length-1]||0:e}function yh(e,t){const n=_t(e,t);let{transitionEnd:r={},transition:i={},...a}=n||{};a={...a,...r};for(const s in a){const o=gh(a[s]);ph(e,s,o)}}function vh(e){return!!(ye(e)&&e.add)}function mi(e,t){const n=e.getValue("willChange");if(vh(n))return n.add(t);if(!n&&Xe.WillChange){const r=new Xe.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function co(e){return e.props[Hs]}const bh=e=>e!==null;function xh(e,{repeat:t,repeatType:n="loop"},r){const i=e.filter(bh),a=t&&n!=="loop"&&t%2===1?0:i.length-1;return i[a]}const wh={type:"spring",stiffness:500,damping:25,restSpeed:10},Ah=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Sh={type:"keyframes",duration:.8},Th={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Ph=(e,{keyframes:t})=>t.length>2?Sh:jt.has(e)?e.startsWith("scale")?Ah(t[1]):wh:Th;function Eh({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:a,repeatType:s,repeatDelay:o,from:u,elapsed:d,...l}){return!!Object.keys(l).length}const pi=(e,t,n,r={},i,a)=>s=>{const o=Yr(r,e)||{},u=o.delay||r.delay||0;let{elapsed:d=0}=r;d=d-Oe(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:()=>{s(),o.onComplete&&o.onComplete()},name:e,motionValue:t,element:a?void 0:i};Eh(o)||Object.assign(l,Ph(e,l)),l.duration&&(l.duration=Oe(l.duration)),l.repeatDelay&&(l.repeatDelay=Oe(l.repeatDelay)),l.from!==void 0&&(l.keyframes[0]=l.from);let c=!1;if((l.type===!1||l.duration===0&&!l.repeatDelay)&&(Hr(l),l.delay===0&&(c=!0)),(Xe.instantAnimations||Xe.skipAnimations)&&(c=!0,Hr(l),l.delay=0),l.allowFlatten=!o.type&&!o.ease,c&&!a&&t.get()!==void 0){const f=xh(l.keyframes,o);if(f!==void 0){re.update(()=>{l.onUpdate(f),l.onComplete()});return}}return o.isSync?new Lr(l):new Gf(l)};function Ch({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function fo(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:a=e.getDefaultTransition(),transitionEnd:s,...o}=t;r&&(a=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&&Ch(d,l))continue;const h={delay:n,...Yr(a||{},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=co(e);if(v){const I=window.MotionHandoffAnimation(v,l,re);I!==null&&(h.startTime=I,b=!0)}}mi(e,l),c.start(pi(l,c,f,e.shouldReduceMotion&&fs.has(l)?{type:!1}:h,e,b));const A=c.animation;A&&u.push(A)}return s&&Promise.all(u).then(()=>{re.update(()=>{s&&yh(e,s)})}),u}function ho(e,t,n,r=0,i=1){const a=Array.from(e).sort((d,l)=>d.sortNodePosition(l)).indexOf(t),s=e.size,o=(s-1)*r;return typeof n=="function"?n(a,s):i===1?a*r:o-a*r}function gi(e,t,n={}){const r=_t(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const a=r?()=>Promise.all(fo(e,r,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:d=0,staggerChildren:l,staggerDirection:c}=i;return kh(e,t,u,d,l,c,n)}:()=>Promise.resolve(),{when:o}=i;if(o){const[u,d]=o==="beforeChildren"?[a,s]:[s,a];return u().then(()=>d())}else return Promise.all([a(),s(n.delay)])}function kh(e,t,n=0,r=0,i=0,a=1,s){const o=[];for(const u of e.variantChildren)u.notify("AnimationStart",t),o.push(gi(u,t,{...s,delay:n+(typeof r=="function"?0:r)+ho(e.variantChildren,u,r,i,a)}).then(()=>u.notify("AnimationComplete",t)));return Promise.all(o)}function Mh(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(a=>gi(e,a,n));r=Promise.all(i)}else if(typeof t=="string")r=gi(e,t,n);else{const i=typeof t=="function"?_t(e,t,n.custom):t;r=Promise.all(fo(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}function mo(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 Dh=ei.length;function po(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?po(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<Dh;n++){const r=ei[n],i=e.props[r];(an(i)||i===!1)&&(t[r]=i)}return t}const Ih=[...Jr].reverse(),jh=Jr.length;function Fh(e){return t=>Promise.all(t.map(({animation:n,options:r})=>Mh(e,n,r)))}function Nh(e){let t=Fh(e),n=go(),r=!0;const i=u=>(d,l)=>{const c=_t(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 a(u){t=u(e)}function s(u){const{props:d}=e,l=po(e.parent)||{},c=[],f=new Set;let h={},m=1/0;for(let A=0;A<jh;A++){const v=Ih[A],I=n[v],T=d[v]!==void 0?d[v]:l[v],C=an(T),P=v===u?I.isActive:null;P===!1&&(m=A);let w=T===l[v]&&T!==d[v]&&C;if(w&&r&&e.manuallyAnimateOnMount&&(w=!1),I.protectedKeys={...h},!I.isActive&&P===null||!T&&!I.prevProp||Ln(T)||typeof T=="boolean")continue;const L=Oh(I.prevProp,T);let p=L||v===u&&I.isActive&&!w&&C||A>m&&C,y=!1;const S=Array.isArray(T)?T:[T];let D=S.reduce(i(v),{});P===!1&&(D={});const{prevResolvedValues:j={}}=I,F={...j,...D},E=g=>{p=!0,f.has(g)&&(y=!0,f.delete(g)),I.needsAnimating[g]=!0;const V=e.getValue(g);V&&(V.liveStyle=!1)};for(const g in F){const V=D[g],O=j[g];if(h.hasOwnProperty(g))continue;let U=!1;hi(V)&&hi(O)?U=!mo(V,O):U=V!==O,U?V!=null?E(g):f.add(g):V!==void 0&&f.has(g)?E(g):I.protectedKeys[g]=!0}I.prevProp=T,I.prevResolvedValues=D,I.isActive&&(h={...h,...D}),r&&e.blockInitialAnimation&&(p=!1);const R=w&&L;p&&(!R||y)&&c.push(...S.map(g=>{const V={type:v};if(typeof g=="string"&&r&&!R&&e.manuallyAnimateOnMount&&e.parent){const{parent:O}=e,U=_t(O,g);if(O.enteringChildren&&U){const{delayChildren:N}=U.transition||{};V.delay=ho(O.enteringChildren,e,N)}}return{animation:g,options:V}}))}if(f.size){const A={};if(typeof d.initial!="boolean"){const v=_t(e,Array.isArray(d.initial)?d.initial[0]:d.initial);v&&v.transition&&(A.transition=v.transition)}f.forEach(v=>{const I=e.getBaseTarget(v),T=e.getValue(v);T&&(T.liveStyle=!0),A[v]=I??null}),c.push({animation:A})}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=s(u);for(const c in n)n[c].protectedKeys={};return l}return{animateChanges:s,setActive:o,setAnimateFunction:a,getState:()=>n,reset:()=>{n=go()}}}function Oh(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!mo(t,e):!1}function yt(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function go(){return{animate:yt(!0),whileInView:yt(),whileHover:yt(),whileTap:yt(),whileDrag:yt(),whileFocus:yt(),exit:yt()}}class at{constructor(t){this.isMounted=!1,this.node=t}update(){}}class Lh extends at{constructor(t){super(t),t.animationState||(t.animationState=Nh(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Ln(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 Rh=0;class Vh extends at{constructor(){super(...arguments),this.id=Rh++}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 _h={animation:{Feature:Lh},exit:{Feature:Vh}};function on(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function ln(e){return{point:{x:e.pageX,y:e.pageY}}}const Uh=e=>t=>qr(t)&&e(t,ln(t));function un(e,t,n,r){return on(e,t,Uh(n),r)}const yo=1e-4,$h=1-yo,zh=1+yo,vo=.01,Bh=0-vo,Wh=0+vo;function Ae(e){return e.max-e.min}function Hh(e,t,n){return Math.abs(e-t)<=n}function bo(e,t,n,r=.5){e.origin=r,e.originPoint=ae(t.min,t.max,e.origin),e.scale=Ae(n)/Ae(t),e.translate=ae(n.min,n.max,e.origin)-e.originPoint,(e.scale>=$h&&e.scale<=zh||isNaN(e.scale))&&(e.scale=1),(e.translate>=Bh&&e.translate<=Wh||isNaN(e.translate))&&(e.translate=0)}function cn(e,t,n,r){bo(e.x,t.x,n.x,r?r.originX:void 0),bo(e.y,t.y,n.y,r?r.originY:void 0)}function xo(e,t,n){e.min=n.min+t.min,e.max=e.min+Ae(t)}function Yh(e,t,n){xo(e.x,t.x,n.x),xo(e.y,t.y,n.y)}function wo(e,t,n){e.min=t.min-n.min,e.max=e.min+Ae(t)}function Un(e,t,n){wo(e.x,t.x,n.x),wo(e.y,t.y,n.y)}function Fe(e){return[e("x"),e("y")]}const Ao=({current:e})=>e?e.ownerDocument.defaultView:null,So=(e,t)=>Math.abs(e-t);function Gh(e,t){const n=So(e.x,t.x),r=So(e.y,t.y);return Math.sqrt(n**2+r**2)}class To{constructor(t,n,{transformPagePoint:r,contextWindow:i=window,dragSnapToOrigin:a=!1,distanceThreshold:s=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=vi(this.lastMoveEventInfo,this.history),h=this.startEvent!==null,m=Gh(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!h&&!m)return;const{point:b}=f,{timestamp:A}=me;this.history.push({...b,timestamp:A});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=yi(h,this.transformPagePoint),re.update(this.updatePoint,!0)},this.handlePointerUp=(f,h)=>{this.end();const{onEnd:m,onSessionEnd:b,resumeAnimation:A}=this.handlers;if(this.dragSnapToOrigin&&A&&A(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const v=vi(f.type==="pointercancel"?this.lastMoveEventInfo:yi(h,this.transformPagePoint),this.history);this.startEvent&&m&&m(f,v),b&&b(f,v)},!qr(t))return;this.dragSnapToOrigin=a,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=s,this.contextWindow=i||window;const o=ln(t),u=yi(o,this.transformPagePoint),{point:d}=u,{timestamp:l}=me;this.history=[{...d,timestamp:l}];const{onSessionStart:c}=n;c&&c(t,vi(u,this.history)),this.removeListeners=qt(un(this.contextWindow,"pointermove",this.handlePointerMove),un(this.contextWindow,"pointerup",this.handlePointerUp),un(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),nt(this.updatePoint)}}function yi(e,t){return t?{point:t(e.point)}:e}function Po(e,t){return{x:e.x-t.x,y:e.y-t.y}}function vi({point:e},t){return{point:e,delta:Po(e,Eo(t)),offset:Po(e,Kh(t)),velocity:Xh(t,.1)}}function Kh(e){return e[0]}function Eo(e){return e[e.length-1]}function Xh(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=Eo(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>Oe(t)));)n--;if(!r)return{x:0,y:0};const a=je(i.timestamp-r.timestamp);if(a===0)return{x:0,y:0};const s={x:(i.x-r.x)/a,y:(i.y-r.y)/a};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function qh(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?ae(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?ae(n,e,r.max):Math.min(e,n)),e}function Co(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 Qh(e,{top:t,left:n,bottom:r,right:i}){return{x:Co(e.x,n,i),y:Co(e.y,t,r)}}function ko(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 Zh(e,t){return{x:ko(e.x,t.x),y:ko(e.y,t.y)}}function Jh(e,t){let n=.5;const r=Ae(e),i=Ae(t);return i>r?n=Qt(t.min,t.max-r,e.min):r>i&&(n=Qt(e.min,e.max-i,t.min)),Ge(0,1,n)}function em(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 bi=.35;function tm(e=bi){return e===!1?e=0:e===!0&&(e=bi),{x:Mo(e,"left","right"),y:Mo(e,"top","bottom")}}function Mo(e,t,n){return{min:Do(e,t),max:Do(e,n)}}function Do(e,t){return typeof e=="number"?e:e[t]||0}const nm=new WeakMap;class rm{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=de(),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 a=c=>{const{dragSnapToOrigin:f}=this.getProps();f?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(ln(c).point)},s=(c,f)=>{const{drag:h,dragPropagation:m,onDragStart:b}=this.getProps();if(h&&!m&&(this.openDragLock&&this.openDragLock(),this.openDragLock=ud(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),Fe(v=>{let I=this.getAxisMotionValue(v).get()||0;if(ze.test(I)){const{projection:T}=this.visualElement;if(T&&T.layout){const C=T.layout.layoutBox[v];C&&(I=Ae(C)*(parseFloat(I)/100))}}this.originPoint[v]=I}),b&&re.postRender(()=>b(c,f)),mi(this.visualElement,"transform");const{animationState:A}=this.visualElement;A&&A.setActive("whileDrag",!0)},o=(c,f)=>{this.latestPointerEvent=c,this.latestPanInfo=f;const{dragPropagation:h,dragDirectionLock:m,onDirectionLock:b,onDrag:A}=this.getProps();if(!h&&!this.openDragLock)return;const{offset:v}=f;if(m&&this.currentDirection===null){this.currentDirection=im(v),this.currentDirection!==null&&b&&b(this.currentDirection);return}this.updateAxis("x",f.point,v),this.updateAxis("y",f.point,v),this.visualElement.render(),A&&A(c,f)},u=(c,f)=>{this.latestPointerEvent=c,this.latestPanInfo=f,this.stop(c,f),this.latestPointerEvent=null,this.latestPanInfo=null},d=()=>Fe(c=>this.getAnimationState(c)==="paused"&&this.getAxisMotionValue(c).animation?.play()),{dragSnapToOrigin:l}=this.getProps();this.panSession=new To(t,{onSessionStart:a,onStart:s,onMove:o,onSessionEnd:u,resumeAnimation:d},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:l,distanceThreshold:r,contextWindow:Ao(this.visualElement)})}stop(t,n){const r=t||this.latestPointerEvent,i=n||this.latestPanInfo,a=this.isDragging;if(this.cancel(),!a||!i||!r)return;const{velocity:s}=i;this.startAnimation(s);const{onDragEnd:o}=this.getProps();o&&re.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 a=this.getAxisMotionValue(t);let s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=qh(s,this.constraints[t],this.elastic[t])),a.set(s)}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&&Ot(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=Qh(r.layoutBox,t):this.constraints=!1,this.elastic=tm(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Fe(a=>{this.constraints!==!1&&this.getAxisMotionValue(a)&&(this.constraints[a]=em(r.layoutBox[a],this.constraints[a]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Ot(t))return!1;const r=t.current;Ke(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 a=ah(r,i.root,this.visualElement.getTransformPagePoint());let s=Zh(i.layout.layoutBox,a);if(n){const o=n(nh(s));this.hasMutatedConstraints=!!o,o&&(s=Ks(o))}return s}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:a,dragSnapToOrigin:s,onDragTransitionEnd:o}=this.getProps(),u=this.constraints||{},d=Fe(l=>{if(!$n(l,n,this.currentDirection))return;let c=u&&u[l]||{};s&&(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,...a,...c};return this.startAxisValueAnimation(l,m)});return Promise.all(d).then(o)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return mi(this.visualElement,t),r.start(pi(t,r,0,n,this.visualElement,!1))}stopAnimation(){Fe(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Fe(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){Fe(n=>{const{drag:r}=this.getProps();if(!$n(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,a=this.getAxisMotionValue(n);if(i&&i.layout){const{min:s,max:o}=i.layout.layoutBox[n];a.set(t[n]-ae(s,o,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Ot(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Fe(s=>{const o=this.getAxisMotionValue(s);if(o&&this.constraints!==!1){const u=o.get();i[s]=Jh({min:u,max:u},this.constraints[s])}});const{transformTemplate:a}=this.visualElement.getProps();this.visualElement.current.style.transform=a?a({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Fe(s=>{if(!$n(s,t,null))return;const o=this.getAxisMotionValue(s),{min:u,max:d}=this.constraints[s];o.set(ae(u,d,i[s]))})}addListeners(){if(!this.visualElement.current)return;nm.set(this.visualElement,this);const t=this.visualElement.current,n=un(t,"pointerdown",u=>{const{drag:d,dragListener:l=!0}=this.getProps();d&&l&&this.start(u)}),r=()=>{const{dragConstraints:u}=this.getProps();Ot(u)&&u.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,a=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),re.read(r);const s=on(window,"resize",()=>this.scalePositionWithinConstraints()),o=i.addEventListener("didUpdate",(({delta:u,hasLayoutChanged:d})=>{this.isDragging&&d&&(Fe(l=>{const c=this.getAxisMotionValue(l);c&&(this.originPoint[l]+=u[l].translate,c.set(c.get()+u[l].translate))}),this.visualElement.render())}));return()=>{s(),n(),a(),o&&o()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:a=!1,dragElastic:s=bi,dragMomentum:o=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:a,dragElastic:s,dragMomentum:o}}}function $n(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function im(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class am extends at{constructor(t){super(t),this.removeGroupControls=Ie,this.removeListeners=Ie,this.controls=new rm(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ie}unmount(){this.removeGroupControls(),this.removeListeners()}}const Io=e=>(t,n)=>{e&&re.postRender(()=>e(t,n))};class sm extends at{constructor(){super(...arguments),this.removePointerDownListener=Ie}onPointerDown(t){this.session=new To(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Ao(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:Io(t),onStart:Io(n),onMove:r,onEnd:(a,s)=>{delete this.session,i&&re.postRender(()=>i(a,s))}}}mount(){this.removePointerDownListener=un(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 zn={hasAnimatedSinceResize:!0,hasEverUpdated:!1};let xi=!1;class om extends z.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:a}=t;a&&(n.group&&n.group.add(a),r&&r.register&&i&&r.register(a),xi&&a.root.didUpdate(),a.addEventListener("animationComplete",()=>{this.safeToRemove()}),a.setOptions({...a.options,onExitComplete:()=>this.safeToRemove()})),zn.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:a}=this.props,{projection:s}=r;return s&&(s.isPresent=a,xi=!0,i||t.layoutDependency!==n||n===void 0||t.isPresent!==a?s.willUpdate():this.safeToRemove(),t.isPresent!==a&&(a?s.promote():s.relegate()||re.postRender(()=>{const o=s.getStack();(!o||!o.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),Xr.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;xi=!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 jo(e){const[t,n]=Ms(),r=z.useContext(ur);return k.jsx(om,{...e,layoutGroup:r,switchLayoutGroup:z.useContext(Ys),isPresent:t,safeToRemove:n})}function lm(e,t,n){const r=ye(e)?e:Ft(e);return r.start(pi("",r,t,n)),r.animation}const um=(e,t)=>e.depth-t.depth;class cm{constructor(){this.children=[],this.isDirty=!1}add(t){dr(this.children,t),this.isDirty=!0}remove(t){hr(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(um),this.isDirty=!1,this.children.forEach(t)}}function fm(e,t){const n=Pe.now(),r=({timestamp:i})=>{const a=i-n;a>=t&&(nt(r),e(a-t))};return re.setup(r,!0),()=>nt(r)}const Fo=["TopLeft","TopRight","BottomLeft","BottomRight"],dm=Fo.length,No=e=>typeof e=="string"?parseFloat(e):e,Oo=e=>typeof e=="number"||X.test(e);function hm(e,t,n,r,i,a){i?(e.opacity=ae(0,n.opacity??1,mm(r)),e.opacityExit=ae(t.opacity??1,0,pm(r))):a&&(e.opacity=ae(t.opacity??1,n.opacity??1,r));for(let s=0;s<dm;s++){const o=`border${Fo[s]}Radius`;let u=Lo(t,o),d=Lo(n,o);if(u===void 0&&d===void 0)continue;u||(u=0),d||(d=0),u===0||d===0||Oo(u)===Oo(d)?(e[o]=Math.max(ae(No(u),No(d),r),0),(ze.test(d)||ze.test(u))&&(e[o]+="%")):e[o]=d}(t.rotate||n.rotate)&&(e.rotate=ae(t.rotate||0,n.rotate||0,r))}function Lo(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const mm=Ro(0,.5,Ca),pm=Ro(.5,.95,Ie);function Ro(e,t,n){return r=>r<e?0:r>t?1:n(Qt(e,t,r))}function Vo(e,t){e.min=t.min,e.max=t.max}function Re(e,t){Vo(e.x,t.x),Vo(e.y,t.y)}function _o(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Uo(e,t,n,r,i){return e-=t,e=_n(e,1/n,r),i!==void 0&&(e=_n(e,1/i,r)),e}function gm(e,t=0,n=1,r=.5,i,a=e,s=e){if(ze.test(t)&&(t=parseFloat(t),t=ae(s.min,s.max,t/100)-s.min),typeof t!="number")return;let o=ae(a.min,a.max,r);e===a&&(o-=t),e.min=Uo(e.min,t,n,o,i),e.max=Uo(e.max,t,n,o,i)}function $o(e,t,[n,r,i],a,s){gm(e,t[n],t[r],t[i],t.scale,a,s)}const ym=["x","scaleX","originX"],vm=["y","scaleY","originY"];function zo(e,t,n,r){$o(e.x,t,ym,n?n.x:void 0,r?r.x:void 0),$o(e.y,t,vm,n?n.y:void 0,r?r.y:void 0)}function Bo(e){return e.translate===0&&e.scale===1}function Wo(e){return Bo(e.x)&&Bo(e.y)}function Ho(e,t){return e.min===t.min&&e.max===t.max}function bm(e,t){return Ho(e.x,t.x)&&Ho(e.y,t.y)}function Yo(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Go(e,t){return Yo(e.x,t.x)&&Yo(e.y,t.y)}function Ko(e){return Ae(e.x)/Ae(e.y)}function Xo(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class xm{constructor(){this.members=[]}add(t){dr(this.members,t),t.scheduleRender()}remove(t){if(hr(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 a=this.members[i];if(a.isPresent!==!1){r=a;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 wm(e,t,n){let r="";const i=e.x.translate/t.x,a=e.y.translate/t.y,s=n?.z||0;if((i||a||s)&&(r=`translate3d(${i}px, ${a}px, ${s}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 wi=["","X","Y","Z"],Am=1e3;let Sm=0;function Ai(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function qo(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=co(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:a}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",re,!(i||a))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&qo(r)}function Qo({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(s={},o=t?.()){this.id=Sm++,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(Em),this.nodes.forEach(Dm),this.nodes.forEach(Im),this.nodes.forEach(Cm)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,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 cm)}addEventListener(s,o){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new gr),this.eventHandlers.get(s).add(o)}notifyListeners(s,...o){const u=this.eventHandlers.get(s);u&&u.notify(...o)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=Cs(s)&&!pd(s),this.instance=s;const{layoutId:o,layout:u,visualElement:d}=this.options;if(d&&!d.current&&d.mount(s),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;re.read(()=>{c=window.innerWidth}),e(s,()=>{const h=window.innerWidth;h!==c&&(c=h,this.root.updateBlockedByResize=!0,l&&l(),l=fm(f,250),zn.hasAnimatedSinceResize&&(zn.hasAnimatedSinceResize=!1,this.nodes.forEach(el)))})}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()||Lm,{onLayoutAnimationStart:b,onLayoutAnimationComplete:A}=d.getProps(),v=!this.targetLayout||!Go(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 T={...Yr(m,"layout"),onPlay:b,onComplete:A};(d.shouldReduceMotion||this.options.layoutRoot)&&(T.delay=0,T.type=!1),this.startAnimation(T),this.setAnimationOrigin(l,I)}else c||el(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=h})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),nt(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(jm),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&qo(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(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Zo);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(Jo);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Mm),this.nodes.forEach(Tm),this.nodes.forEach(Pm)):this.nodes.forEach(Jo),this.clearAllSnapshots();const o=Pe.now();me.delta=Ge(0,1e3/60,o-me.timestamp),me.timestamp=o,me.isProcessing=!0,xr.update.process(me),xr.preRender.process(me),xr.render.process(me),me.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Xr.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(km),this.sharedNodes.forEach(Fm)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,re.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){re.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Ae(this.snapshot.measuredBox.x)&&!Ae(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 s=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=de(),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,s?s.layoutBox:void 0)}updateScroll(s="measure"){let o=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(o=!1),o&&this.instance){const u=r(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:u,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:u}}}resetTransform(){if(!i)return;const s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,o=this.projectionDelta&&!Wo(this.projectionDelta),u=this.getTransformTemplate(),d=u?u(this.latestValues,""):void 0,l=d!==this.prevTransformTemplateValue;s&&this.instance&&(o||gt(this.latestValues)||l)&&(i(this.instance,d),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const o=this.measurePageBox();let u=this.removeElementScroll(o);return s&&(u=this.removeTransform(u)),Rm(u),{animationId:this.root.animationId,measuredBox:o,layoutBox:u,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:s}=this.options;if(!s)return de();const o=s.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(Vm))){const{scroll:d}=this.root;d&&(Lt(o.x,d.offset.x),Lt(o.y,d.offset.y))}return o}removeElementScroll(s){const o=de();if(Re(o,s),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&&Re(o,s),Lt(o.x,l.offset.x),Lt(o.y,l.offset.y))}return o}applyTransform(s,o=!1){const u=de();Re(u,s);for(let d=0;d<this.path.length;d++){const l=this.path[d];!o&&l.options.layoutScroll&&l.scroll&&l!==l.root&&Rt(u,{x:-l.scroll.offset.x,y:-l.scroll.offset.y}),gt(l.latestValues)&&Rt(u,l.latestValues)}return gt(this.latestValues)&&Rt(u,this.latestValues),u}removeTransform(s){const o=de();Re(o,s);for(let u=0;u<this.path.length;u++){const d=this.path[u];if(!d.instance||!gt(d.latestValues))continue;ci(d.latestValues)&&d.updateSnapshot();const l=de(),c=d.measurePageBox();Re(l,c),zo(o,d.latestValues,d.snapshot?d.snapshot.layoutBox:void 0,l)}return gt(this.latestValues)&&zo(o,this.latestValues),o}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.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!==me.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!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(!(s||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=me.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=de(),this.targetWithTransforms=de()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),Yh(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Re(this.target,this.layout.layoutBox),Zs(this.target,this.targetDelta)):Re(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||ci(this.parent.latestValues)||Xs(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(s,o,u){this.relativeParent=s,this.linkedParentVersion=s.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=de(),this.relativeTargetOrigin=de(),Un(this.relativeTargetOrigin,o,u),Re(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){const s=this.getLead(),o=!!this.resumingFrom||this!==s;let u=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(u=!1),o&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(u=!1),this.resolvedRelativeTargetAt===me.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;Re(this.layoutCorrected,this.layout.layoutBox);const c=this.treeScale.x,f=this.treeScale.y;ih(this.layoutCorrected,this.treeScale,this.path,o),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=de());const{target:h}=s;if(!h){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(_o(this.prevProjectionDelta.x,this.projectionDelta.x),_o(this.prevProjectionDelta.y,this.projectionDelta.y)),cn(this.projectionDelta,this.layoutCorrected,h,this.latestValues),(this.treeScale.x!==c||this.treeScale.y!==f||!Xo(this.projectionDelta.x,this.prevProjectionDelta.x)||!Xo(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",h))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.visualElement?.scheduleRender(),s){const o=this.getStack();o&&o.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Vt(),this.projectionDelta=Vt(),this.projectionDeltaWithTransform=Vt()}setAnimationOrigin(s,o=!1){const u=this.snapshot,d=u?u.latestValues:{},l={...this.latestValues},c=Vt();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!o;const f=de(),h=u?u.source:void 0,m=this.layout?this.layout.source:void 0,b=h!==m,A=this.getStack(),v=!A||A.members.length<=1,I=!!(b&&!v&&this.options.crossfade===!0&&!this.path.some(Om));this.animationProgress=0;let T;this.mixTargetDelta=C=>{const P=C/1e3;tl(c.x,s.x,P),tl(c.y,s.y,P),this.setTargetDelta(c),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Un(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Nm(this.relativeTarget,this.relativeTargetOrigin,f,P),T&&bm(this.relativeTarget,T)&&(this.isProjectionDirty=!1),T||(T=de()),Re(T,this.relativeTarget)),b&&(this.animationValues=l,hm(l,d,this.latestValues,P,I,v)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=P},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(nt(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=re.update(()=>{zn.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Ft(0)),this.currentAnimation=lm(this.motionValue,[0,1e3],{...s,velocity:0,isSync:!0,onUpdate:o=>{this.mixTargetDelta(o),s.onUpdate&&s.onUpdate(o)},onStop:()=>{},onComplete:()=>{s.onComplete&&s.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 s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Am),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:o,target:u,layout:d,latestValues:l}=s;if(!(!o||!u||!d)){if(this!==s&&this.layout&&d&&sl(this.options.animationType,this.layout.layoutBox,d.layoutBox)){u=this.target||de();const c=Ae(this.layout.layoutBox.x);u.x.min=s.target.x.min,u.x.max=u.x.min+c;const f=Ae(this.layout.layoutBox.y);u.y.min=s.target.y.min,u.y.max=u.y.min+f}Re(o,u),Rt(o,l),cn(this.projectionDeltaWithTransform,this.layoutCorrected,o,l)}}registerSharedNode(s,o){this.sharedNodes.has(s)||this.sharedNodes.set(s,new xm),this.sharedNodes.get(s).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 s=this.getStack();return s?s.lead===this:!0}getLead(){const{layoutId:s}=this.options;return s?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:s}=this.options;return s?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:o,preserveFollowOpacity:u}={}){const d=this.getStack();d&&d.promote(this,u),s&&(this.projectionDelta=void 0,this.needsReset=!0),o&&this.setOptions({transition:o})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){const{visualElement:s}=this.options;if(!s)return;let o=!1;const{latestValues:u}=s;if((u.z||u.rotate||u.rotateX||u.rotateY||u.rotateZ||u.skewX||u.skewY)&&(o=!0),!o)return;const d={};u.z&&Ai("z",s,d,this.animationValues);for(let l=0;l<wi.length;l++)Ai(`rotate${wi[l]}`,s,d,this.animationValues),Ai(`skew${wi[l]}`,s,d,this.animationValues);s.render();for(const l in d)s.setStaticValue(l,d[l]),this.animationValues&&(this.animationValues[l]=d[l]);s.scheduleRender()}applyProjectionStyles(s,o){if(!this.instance||this.isSVG)return;if(!this.isVisible){s.visibility="hidden";return}const u=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,s.visibility="",s.opacity="",s.pointerEvents=Vn(o?.pointerEvents)||"",s.transform=u?u(this.latestValues,""):"none";return}const d=this.getLead();if(!this.projectionDelta||!this.layout||!d.target){this.options.layoutId&&(s.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,s.pointerEvents=Vn(o?.pointerEvents)||""),this.hasProjected&&!gt(this.latestValues)&&(s.transform=u?u({},""):"none",this.hasProjected=!1);return}s.visibility="";const l=d.animationValues||d.latestValues;this.applyTransformsToTarget();let c=wm(this.projectionDeltaWithTransform,this.treeScale,l);u&&(c=u(l,c)),s.transform=c;const{x:f,y:h}=this.projectionDelta;s.transformOrigin=`${f.origin*100}% ${h.origin*100}% 0`,d.animationValues?s.opacity=d===this?l.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:l.opacityExit:s.opacity=d===this?l.opacity!==void 0?l.opacity:"":l.opacityExit!==void 0?l.opacityExit:0;for(const m in ti){if(l[m]===void 0)continue;const{correct:b,applyTo:A,isCSSVariable:v}=ti[m],I=c==="none"?l[m]:b(l[m],d);if(A){const T=A.length;for(let C=0;C<T;C++)s[A[C]]=I}else v?this.options.visualElement.renderState.vars[m]=I:s[m]=I}this.options.layoutId&&(s.pointerEvents=d===this?Vn(o?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>s.currentAnimation?.stop()),this.root.nodes.forEach(Zo),this.root.sharedNodes.clear()}}}function Tm(e){e.updateLayout()}function Pm(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,a=t.source!==e.layout.source;i==="size"?Fe(l=>{const c=a?t.measuredBox[l]:t.layoutBox[l],f=Ae(c);c.min=n[l].min,c.max=c.min+f}):sl(i,t.layoutBox,n)&&Fe(l=>{const c=a?t.measuredBox[l]:t.layoutBox[l],f=Ae(n[l]);c.max=c.min+f,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[l].max=e.relativeTarget[l].min+f)});const s=Vt();cn(s,n,t.layoutBox);const o=Vt();a?cn(o,e.applyTransform(r,!0),t.measuredBox):cn(o,n,t.layoutBox);const u=!Wo(s);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=de();Un(h,t.layoutBox,c.layoutBox);const m=de();Un(m,n,f.layoutBox),Go(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:s,hasLayoutChanged:u,hasRelativeLayoutChanged:d})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function Em(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 Cm(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function km(e){e.clearSnapshot()}function Zo(e){e.clearMeasurements()}function Jo(e){e.isLayoutDirty=!1}function Mm(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function el(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Dm(e){e.resolveTargetDelta()}function Im(e){e.calcProjection()}function jm(e){e.resetSkewAndRotation()}function Fm(e){e.removeLeadSnapshot()}function tl(e,t,n){e.translate=ae(t.translate,0,n),e.scale=ae(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function nl(e,t,n,r){e.min=ae(t.min,n.min,r),e.max=ae(t.max,n.max,r)}function Nm(e,t,n,r){nl(e.x,t.x,n.x,r),nl(e.y,t.y,n.y,r)}function Om(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const Lm={duration:.45,ease:[.4,0,.1,1]},rl=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),il=rl("applewebkit/")&&!rl("chrome/")?Math.round:Ie;function al(e){e.min=il(e.min),e.max=il(e.max)}function Rm(e){al(e.x),al(e.y)}function sl(e,t,n){return e==="position"||e==="preserve-aspect"&&!Hh(Ko(t),Ko(n),.2)}function Vm(e){return e!==e.root&&e.scroll?.wasRoot}const _m=Qo({attachResizeListener:(e,t)=>on(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Si={current:void 0},ol=Qo({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Si.current){const e=new _m({});e.mount(window),e.setOptions({layoutScroll:!0}),Si.current=e}return Si.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Um={pan:{Feature:sm},drag:{Feature:am,ProjectionNode:ol,MeasureLayout:jo}};function ll(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,a=r[i];a&&re.postRender(()=>a(t,ln(t)))}class $m extends at{mount(){const{current:t}=this.node;t&&(this.unmount=cd(t,(n,r)=>(ll(this.node,r,"Start"),i=>ll(this.node,i,"End"))))}unmount(){}}class zm extends at{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(on(this.node.current,"focus",()=>this.onFocus()),on(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function ul(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),a=r[i];a&&re.postRender(()=>a(t,ln(t)))}class Bm extends at{mount(){const{current:t}=this.node;t&&(this.unmount=md(t,(n,r)=>(ul(this.node,r,"Start"),(i,{success:a})=>ul(this.node,i,a?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Ti=new WeakMap,Pi=new WeakMap,Wm=e=>{const t=Ti.get(e.target);t&&t(e)},Hm=e=>{e.forEach(Wm)};function Ym({root:e,...t}){const n=e||document;Pi.has(n)||Pi.set(n,{});const r=Pi.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(Hm,{root:e,...t})),r[i]}function Gm(e,t,n){const r=Ym(t);return Ti.set(e,n),r.observe(e),()=>{Ti.delete(e),r.unobserve(e)}}const Km={some:0,all:1};class Xm extends at{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:a}=t,s={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:Km[i]},o=u=>{const{isIntersecting:d}=u;if(this.isInView===d||(this.isInView=d,a&&!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 Gm(this.node.current,s,o)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(qm(t,n))&&this.startObserver()}unmount(){}}function qm({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const Qm={..._h,...{inView:{Feature:Xm},tap:{Feature:Bm},focus:{Feature:zm},hover:{Feature:$m}},...Um,...{layout:{ProjectionNode:ol,MeasureLayout:jo}}},cl=th(Qm,mh);function Ei(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 Zm(e){if(Array.isArray(e))return e}function Jm(e){if(Array.isArray(e))return Ei(e)}function ep(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function tp(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,dl(r.key),r)}}function np(e,t,n){return t&&tp(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Bn(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=Ci(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 a,s=!0,o=!1;return{s:function(){n=n.call(e)},n:function(){var u=n.next();return s=u.done,u},e:function(u){o=!0,a=u},f:function(){try{s||n.return==null||n.return()}finally{if(o)throw a}}}}function q(e,t,n){return(t=dl(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rp(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function ip(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,a,s,o=[],u=!0,d=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=a.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&&(s=n.return(),Object(s)!==s))return}finally{if(d)throw i}}return o}}function ap(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
16
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function sp(){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 fl(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 Y(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fl(Object(n),!0).forEach(function(r){q(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fl(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Wn(e,t){return Zm(e)||ip(e,t)||Ci(e,t)||ap()}function Ve(e){return Jm(e)||rp(e)||Ci(e)||sp()}function op(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 dl(e){var t=op(e,"string");return typeof t=="symbol"?t:t+""}function Hn(e){"@babel/helpers - typeof";return Hn=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},Hn(e)}function Ci(e,t){if(e){if(typeof e=="string")return Ei(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)?Ei(e,t):void 0}}var hl=function(){},ki={},ml={},pl=null,gl={mark:hl,measure:hl};try{typeof window<"u"&&(ki=window),typeof document<"u"&&(ml=document),typeof MutationObserver<"u"&&(pl=MutationObserver),typeof performance<"u"&&(gl=performance)}catch{}var lp=ki.navigator||{},yl=lp.userAgent,vl=yl===void 0?"":yl,st=ki,ee=ml,bl=pl,Yn=gl;st.document;var qe=!!ee.documentElement&&!!ee.head&&typeof ee.addEventListener=="function"&&typeof ee.createElement=="function",xl=~vl.indexOf("MSIE")||~vl.indexOf("Trident/"),Mi,up=/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)?[\-\ ]/,cp=/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,wl={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"}},fp={GROUP:"duotone-group",PRIMARY:"primary",SECONDARY:"secondary"},Al=["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"],pe="classic",fn="duotone",Sl="sharp",Tl="sharp-duotone",Pl="chisel",El="etch",Cl="jelly",kl="jelly-duo",Ml="jelly-fill",Dl="notdog",Il="notdog-duo",jl="slab",Fl="slab-press",Nl="thumbprint",Ol="utility",Ll="utility-duo",Rl="utility-fill",Vl="whiteboard",dp="Classic",hp="Duotone",mp="Sharp",pp="Sharp Duotone",gp="Chisel",yp="Etch",vp="Jelly",bp="Jelly Duo",xp="Jelly Fill",wp="Notdog",Ap="Notdog Duo",Sp="Slab",Tp="Slab Press",Pp="Thumbprint",Ep="Utility",Cp="Utility Duo",kp="Utility Fill",Mp="Whiteboard",_l=[pe,fn,Sl,Tl,Pl,El,Cl,kl,Ml,Dl,Il,jl,Fl,Nl,Ol,Ll,Rl,Vl];Mi={},q(q(q(q(q(q(q(q(q(q(Mi,pe,dp),fn,hp),Sl,mp),Tl,pp),Pl,gp),El,yp),Cl,vp),kl,bp),Ml,xp),Dl,wp),q(q(q(q(q(q(q(q(Mi,Il,Ap),jl,Sp),Fl,Tp),Nl,Pp),Ol,Ep),Ll,Cp),Rl,kp),Vl,Mp);var Dp={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"}},Ip={"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"}},jp=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}]]),Fp={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"}},Ul=["fak","fa-kit","fakd","fa-kit-duotone"],$l={kit:{fak:"kit","fa-kit":"kit"},"kit-duotone":{fakd:"kit-duotone","fa-kit-duotone":"kit-duotone"}},Np=["kit"],Op="kit",Lp="kit-duotone",Rp="Kit",Vp="Kit Duotone";q(q({},Op,Rp),Lp,Vp);var _p={kit:{"fa-kit":"fak"}},Up={"Font Awesome Kit":{400:"fak",normal:"fak"},"Font Awesome Kit Duotone":{400:"fakd",normal:"fakd"}},$p={kit:{fak:"fa-kit"}},zl={kit:{kit:"fak"},"kit-duotone":{"kit-duotone":"fakd"}},Di,Gn={GROUP:"duotone-group",SWAP_OPACITY:"swap-opacity",PRIMARY:"primary",SECONDARY:"secondary"},zp=["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"],Bp="classic",Wp="duotone",Hp="sharp",Yp="sharp-duotone",Gp="chisel",Kp="etch",Xp="jelly",qp="jelly-duo",Qp="jelly-fill",Zp="notdog",Jp="notdog-duo",e0="slab",t0="slab-press",n0="thumbprint",r0="utility",i0="utility-duo",a0="utility-fill",s0="whiteboard",o0="Classic",l0="Duotone",u0="Sharp",c0="Sharp Duotone",f0="Chisel",d0="Etch",h0="Jelly",m0="Jelly Duo",p0="Jelly Fill",g0="Notdog",y0="Notdog Duo",v0="Slab",b0="Slab Press",x0="Thumbprint",w0="Utility",A0="Utility Duo",S0="Utility Fill",T0="Whiteboard";Di={},q(q(q(q(q(q(q(q(q(q(Di,Bp,o0),Wp,l0),Hp,u0),Yp,c0),Gp,f0),Kp,d0),Xp,h0),qp,m0),Qp,p0),Zp,g0),q(q(q(q(q(q(q(q(Di,Jp,y0),e0,v0),t0,b0),n0,x0),r0,w0),i0,A0),a0,S0),s0,T0);var P0="kit",E0="kit-duotone",C0="Kit",k0="Kit Duotone";q(q({},P0,C0),E0,k0);var M0={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"}},D0={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"]},Ii={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"}},I0=["fa-solid","fa-regular","fa-light","fa-thin","fa-duotone","fa-brands","fa-semibold"],Bl=["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(zp,I0),j0=["solid","regular","light","thin","duotone","brands","semibold"],Wl=[1,2,3,4,5,6,7,8,9,10],F0=Wl.concat([11,12,13,14,15,16,17,18,19,20]),N0=["aw","fw","pull-left","pull-right"],O0=[].concat(Ve(Object.keys(D0)),j0,N0,["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",Gn.GROUP,Gn.SWAP_OPACITY,Gn.PRIMARY,Gn.SECONDARY]).concat(Wl.map(function(e){return"".concat(e,"x")})).concat(F0.map(function(e){return"w-".concat(e)})),L0={"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"}},Qe="___FONT_AWESOME___",ji=16,Hl="fa",Yl="svg-inline--fa",vt="data-fa-i2svg",Fi="data-fa-pseudo-element",R0="data-fa-pseudo-element-pending",Ni="data-prefix",Oi="data-icon",Gl="fontawesome-i2svg",V0="async",_0=["HTML","HEAD","STYLE","SCRIPT"],Kl=["::before","::after",":before",":after"],Xl=(function(){try{return process.env.NODE_ENV==="production"}catch{return!1}})();function dn(e){return new Proxy(e,{get:function(n,r){return r in n?n[r]:n[pe]}})}var ql=Y({},wl);ql[pe]=Y(Y(Y(Y({},{"fa-duotone":"duotone"}),wl[pe]),$l.kit),$l["kit-duotone"]);var U0=dn(ql),Li=Y({},Fp);Li[pe]=Y(Y(Y(Y({},{duotone:"fad"}),Li[pe]),zl.kit),zl["kit-duotone"]);var Ql=dn(Li),Ri=Y({},Ii);Ri[pe]=Y(Y({},Ri[pe]),$p.kit);var Vi=dn(Ri),_i=Y({},M0);_i[pe]=Y(Y({},_i[pe]),_p.kit),dn(_i);var $0=up,Zl="fa-layers-text",z0=cp,B0=Y({},Dp);dn(B0);var W0=["class","data-prefix","data-icon","data-fa-transform","data-fa-mask"],Ui=fp,H0=[].concat(Ve(Np),Ve(O0)),hn=st.FontAwesomeConfig||{};function Y0(e){var t=ee.querySelector("script["+e+"]");if(t)return t.getAttribute(e)}function G0(e){return e===""?!0:e==="false"?!1:e==="true"?!0:e}if(ee&&typeof ee.querySelector=="function"){var K0=[["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"]];K0.forEach(function(e){var t=Wn(e,2),n=t[0],r=t[1],i=G0(Y0(n));i!=null&&(hn[r]=i)})}var Jl={styleDefault:"solid",familyDefault:pe,cssPrefix:Hl,replacementClass:Yl,autoReplaceSvg:!0,autoAddCss:!0,searchPseudoElements:!1,searchPseudoElementsWarnings:!0,searchPseudoElementsFullScan:!1,observeMutations:!0,mutateApproach:"async",keepOriginalSource:!0,measurePerformance:!1,showMissingIcons:!0};hn.familyPrefix&&(hn.cssPrefix=hn.familyPrefix);var Ut=Y(Y({},Jl),hn);Ut.autoReplaceSvg||(Ut.observeMutations=!1);var K={};Object.keys(Jl).forEach(function(e){Object.defineProperty(K,e,{enumerable:!0,set:function(n){Ut[e]=n,mn.forEach(function(r){return r(K)})},get:function(){return Ut[e]}})}),Object.defineProperty(K,"familyPrefix",{enumerable:!0,set:function(t){Ut.cssPrefix=t,mn.forEach(function(n){return n(K)})},get:function(){return Ut.cssPrefix}}),st.FontAwesomeConfig=K;var mn=[];function X0(e){return mn.push(e),function(){mn.splice(mn.indexOf(e),1)}}var $t=ji,Be={size:16,x:0,y:0,rotate:0,flipX:!1,flipY:!1};function q0(e){if(!(!e||!qe)){var t=ee.createElement("style");t.setAttribute("type","text/css"),t.innerHTML=e;for(var n=ee.head.childNodes,r=null,i=n.length-1;i>-1;i--){var a=n[i],s=(a.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(s)>-1&&(r=a)}return ee.head.insertBefore(t,r),e}}var Q0="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";function eu(){for(var e=12,t="";e-- >0;)t+=Q0[Math.random()*62|0];return t}function zt(e){for(var t=[],n=(e||[]).length>>>0;n--;)t[n]=e[n];return t}function $i(e){return e.classList?zt(e.classList):(e.getAttribute("class")||"").split(" ").filter(function(t){return t})}function tu(e){return"".concat(e).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function Z0(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,'="').concat(tu(e[n]),'" ')},"").trim()}function Kn(e){return Object.keys(e||{}).reduce(function(t,n){return t+"".concat(n,": ").concat(e[n].trim(),";")},"")}function zi(e){return e.size!==Be.size||e.x!==Be.x||e.y!==Be.y||e.rotate!==Be.rotate||e.flipX||e.flipY}function J0(e){var t=e.transform,n=e.containerWidth,r=e.iconWidth,i={transform:"translate(".concat(n/2," 256)")},a="translate(".concat(t.x*32,", ").concat(t.y*32,") "),s="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(a," ").concat(s," ").concat(o)},d={transform:"translate(".concat(r/2*-1," -256)")};return{outer:i,inner:u,path:d}}function eg(e){var t=e.transform,n=e.width,r=n===void 0?ji:n,i=e.height,a=i===void 0?ji:i,s="";return xl?s+="translate(".concat(t.x/$t-r/2,"em, ").concat(t.y/$t-a/2,"em) "):s+="translate(calc(-50% + ".concat(t.x/$t,"em), calc(-50% + ").concat(t.y/$t,"em)) "),s+="scale(".concat(t.size/$t*(t.flipX?-1:1),", ").concat(t.size/$t*(t.flipY?-1:1),") "),s+="rotate(".concat(t.rotate,"deg) "),s}var tg=`:root, :host {
14
+ `),()=>{A.contains(b)&&A.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),[A,v]=z.useState(c),[k,S]=z.useState(c);ys(()=>{h.current=!1,m.current=c;for(let w=0;w<k.length;w++){const O=On(k[w]);f.includes(O)?b.delete(O):b.get(O)!==!0&&b.set(O,!1)}},[k,f.length,f.join("-")]);const E=[];if(c!==A){let w=[...c];for(let O=0;O<k.length;O++){const p=k[O],y=On(p);f.includes(y)||(w.splice(O,0,p),E.push(p))}return s==="wait"&&E.length&&(w=E),S(ja(w)),v(c),null}process.env.NODE_ENV!=="production"&&s==="wait"&&k.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:k.map(w=>{const O=On(w),p=a&&!d?!1:c===k||f.includes(O),y=()=>{if(b.has(O))b.set(O,!0);else return;let T=!0;b.forEach(I=>{I||(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:w},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:A,...v}=m;for(const k in v){let S=v[k];if(Array.isArray(S)){const E=l?S.length-1:0;S=S[E]}S!==null&&(i[k]=S)}for(const k in b)i[k]=b[k]}}}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?kt(!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):!Id(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 kh(e){return pi(e)?e[e.length-1]||0:e}function Ih(e,t){const n=Ut(e,t);let{transitionEnd:r={},transition:i={},...s}=n||{};s={...s,...r};for(const a in s){const o=kh(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 k=window.MotionHandoffAnimation(v,l,oe);k!==null&&(h.startTime=k,b=!0)}}gi(e,l),c.start(yi(l,c,f,e.shouldReduceMotion&&ha.has(l)?{type:!1}:h,e,b));const A=c.animation;A&&u.push(A)}return a&&Promise.all(u).then(()=>{oe.update(()=>{a&&Ih(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 A=0;A<Wh;A++){const v=$h[A],k=n[v],S=d[v]!==void 0?d[v]:l[v],E=an(S),P=v===u?k.isActive:null;P===!1&&(m=A);let w=S===l[v]&&S!==d[v]&&E;if(w&&r&&e.manuallyAnimateOnMount&&(w=!1),k.protectedKeys={...h},!k.isActive&&P===null||!S&&!k.prevProp||Vn(S)||typeof S=="boolean")continue;const O=Gh(k.prevProp,S);let p=O||v===u&&k.isActive&&!w&&E||A>m&&E,y=!1;const T=Array.isArray(S)?S:[S];let I=T.reduce(i(v),{});P===!1&&(I={});const{prevResolvedValues:M={}}=k,j={...M,...I},C=g=>{p=!0,f.has(g)&&(y=!0,f.delete(g)),k.needsAnimating[g]=!0;const _=e.getValue(g);_&&(_.liveStyle=!1)};for(const g in j){const _=I[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):k.protectedKeys[g]=!0}k.prevProp=S,k.prevResolvedValues=I,k.isActive&&(h={...h,...I}),r&&e.blockInitialAnimation&&(p=!1);const R=w&&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 A={};if(typeof d.initial!="boolean"){const v=Ut(e,Array.isArray(d.initial)?d.initial[0]:d.initial);v&&v.transition&&(A.transition=v.transition)}f.forEach(v=>{const k=e.getBaseTarget(v),S=e.getValue(v);S&&(S.liveStyle=!0),A[v]=k??null}),c.push({animation:A})}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:A}=ge;this.history.push({...b,timestamp:A});const{onStart:v,onMove:k}=this.handlers;h||(v&&v(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),k&&k(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:A}=this.handlers;if(this.dragSnapToOrigin&&A&&A(),!(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,ko(t)),offset:Eo(e,am(t)),velocity:om(t,.1)}}function am(e){return e[0]}function ko(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=ko(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 Io(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:Io(e.x,n,i),y:Io(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 k=this.getAxisMotionValue(v).get()||0;if(We.test(k)){const{projection:S}=this.visualElement;if(S&&S.layout){const E=S.layout.layoutBox[v];E&&(k=Se(E)*(parseFloat(k)/100))}}this.originPoint[v]=k}),b&&oe.postRender(()=>b(c,f)),gi(this.visualElement,"transform");const{animationState:A}=this.visualElement;A&&A.setActive("whileDrag",!0)},o=(c,f)=>{this.latestPointerEvent=c,this.latestPanInfo=f;const{dragPropagation:h,dragDirectionLock:m,onDirectionLock:b,onDrag:A}=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(),A&&A(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,Is),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 km(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){km(e,t[n],t[r],t[i],t.scale,s,a)}const Im=["x","scaleX","originX"],Mm=["y","scaleY","originY"];function Wo(e,t,n,r){$o(e.x,t,Im,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=Ia(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:A}=d.getProps(),v=!this.targetLayout||!Xo(this.targetLayout,h),k=!c&&f;if(this.options.layoutRoot||this.resumeFrom||k||c&&(v||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const S={...Kr(m,"layout"),onPlay:b,onComplete:A};(d.shouldReduceMotion||this.options.layoutRoot)&&(S.delay=0,S.type=!1),this.startAnimation(S),this.setAnimationOrigin(l,k)}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,A=this.getStack(),v=!A||A.members.length<=1,k=!!(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,k,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:A,isCSSVariable:v}=ri[m],k=c==="none"?l[m]:b(l[m],d);if(A){const S=A.length;for(let E=0;E<S;E++)a[A[E]]=k}else v?this.options.visualElement.renderState.vars[m]=k:a[m]=k}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 ki(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 ki(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=Ii(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.
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)||Ii(e,t)||yp()}function Ue(e){return fp(e)||pp(e)||Ii(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 Ii(e,t){if(e){if(typeof e=="string")return ki(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)?ki(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",kl="etch",Il="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",kp="Chisel",Ip="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,kl,Il,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,kp),kl,Ip),Il,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",k0="Notdog",I0="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,k0),J(J(J(J(J(J(J(J(ji,f0,I0),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 {
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 nu(){var e=Hl,t=Yl,n=K.cssPrefix,r=K.replacementClass,i=tg;if(n!==e||r!==t){var a=new RegExp("\\.".concat(e,"\\-"),"g"),s=new RegExp("\\--".concat(e,"\\-"),"g"),o=new RegExp("\\.".concat(t),"g");i=i.replace(a,".".concat(n,"-")).replace(s,"--".concat(n,"-")).replace(o,".".concat(r))}return i}var ru=!1;function Bi(){K.autoAddCss&&!ru&&(q0(nu()),ru=!0)}var ng={mixout:function(){return{dom:{css:nu,insertCss:Bi}}},hooks:function(){return{beforeDOMElementCreation:function(){Bi()},beforeI2svg:function(){Bi()}}}},Ze=st||{};Ze[Qe]||(Ze[Qe]={}),Ze[Qe].styles||(Ze[Qe].styles={}),Ze[Qe].hooks||(Ze[Qe].hooks={}),Ze[Qe].shims||(Ze[Qe].shims=[]);var _e=Ze[Qe],iu=[],au=function(){ee.removeEventListener("DOMContentLoaded",au),Xn=1,iu.map(function(t){return t()})},Xn=!1;qe&&(Xn=(ee.documentElement.doScroll?/^loaded|^c/:/^loaded|^i|^c/).test(ee.readyState),Xn||ee.addEventListener("DOMContentLoaded",au));function rg(e){qe&&(Xn?setTimeout(e,0):iu.push(e))}function pn(e){var t=e.tag,n=e.attributes,r=n===void 0?{}:n,i=e.children,a=i===void 0?[]:i;return typeof e=="string"?tu(e):"<".concat(t," ").concat(Z0(r),">").concat(a.map(pn).join(""),"</").concat(t,">")}function su(e,t,n){if(e&&e[t]&&e[t][n])return{prefix:t,iconName:n,icon:e[t][n]}}var Wi=function(t,n,r,i){var a=Object.keys(t),s=a.length,o=n,u,d,l;for(r===void 0?(u=1,l=t[a[0]]):(u=0,l=r);u<s;u++)d=a[u],l=o(l,t[d],d,t);return l};function ou(e){return Ve(e).length!==1?null:e.codePointAt(0).toString(16)}function lu(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 Hi(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.skipHooks,i=r===void 0?!1:r,a=lu(t);typeof _e.hooks.addPack=="function"&&!i?_e.hooks.addPack(e,lu(t)):_e.styles[e]=Y(Y({},_e.styles[e]||{}),a),e==="fas"&&Hi("fa",t)}var gn=_e.styles,ig=_e.shims,uu=Object.keys(Vi),ag=uu.reduce(function(e,t){return e[t]=Object.keys(Vi[t]),e},{}),Yi=null,cu={},fu={},du={},hu={},mu={};function sg(e){return~H0.indexOf(e)}function og(e,t){var n=t.split("-"),r=n[0],i=n.slice(1).join("-");return r===e&&i!==""&&!sg(i)?i:null}var pu=function(){var t=function(a){return Wi(gn,function(s,o,u){return s[u]=Wi(o,a,{}),s},{})};cu=t(function(i,a,s){if(a[3]&&(i[a[3]]=s),a[2]){var o=a[2].filter(function(u){return typeof u=="number"});o.forEach(function(u){i[u.toString(16)]=s})}return i}),fu=t(function(i,a,s){if(i[s]=s,a[2]){var o=a[2].filter(function(u){return typeof u=="string"});o.forEach(function(u){i[u]=s})}return i}),mu=t(function(i,a,s){var o=a[2];return i[s]=s,o.forEach(function(u){i[u]=s}),i});var n="far"in gn||K.autoFetchSvg,r=Wi(ig,function(i,a){var s=a[0],o=a[1],u=a[2];return o==="far"&&!n&&(o="fas"),typeof s=="string"&&(i.names[s]={prefix:o,iconName:u}),typeof s=="number"&&(i.unicodes[s.toString(16)]={prefix:o,iconName:u}),i},{names:{},unicodes:{}});du=r.names,hu=r.unicodes,Yi=qn(K.styleDefault,{family:K.familyDefault})};X0(function(e){Yi=qn(e.styleDefault,{family:K.familyDefault})}),pu();function Gi(e,t){return(cu[e]||{})[t]}function lg(e,t){return(fu[e]||{})[t]}function bt(e,t){return(mu[e]||{})[t]}function gu(e){return du[e]||{prefix:null,iconName:null}}function ug(e){var t=hu[e],n=Gi("fas",e);return t||(n?{prefix:"fas",iconName:n}:null)||{prefix:null,iconName:null}}function ot(){return Yi}var yu=function(){return{prefix:null,iconName:null,rest:[]}};function cg(e){var t=pe,n=uu.reduce(function(r,i){return r[i]="".concat(K.cssPrefix,"-").concat(i),r},{});return _l.forEach(function(r){(e.includes(n[r])||e.some(function(i){return ag[r].includes(i)}))&&(t=r)}),t}function qn(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.family,r=n===void 0?pe:n,i=U0[r][e];if(r===fn&&!e)return"fad";var a=Ql[r][e]||Ql[r][i],s=e in _e.styles?e:null,o=a||s||null;return o}function fg(e){var t=[],n=null;return e.forEach(function(r){var i=og(K.cssPrefix,r);i?n=i:r&&t.push(r)}),{iconName:n,rest:t}}function vu(e){return e.sort().filter(function(t,n,r){return r.indexOf(t)===n})}var bu=Bl.concat(Ul);function Qn(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.skipLookups,r=n===void 0?!1:n,i=null,a=vu(e.filter(function(h){return bu.includes(h)})),s=vu(e.filter(function(h){return!bu.includes(h)})),o=a.filter(function(h){return i=h,!Al.includes(h)}),u=Wn(o,1),d=u[0],l=d===void 0?null:d,c=cg(a),f=Y(Y({},fg(s)),{},{prefix:qn(l,{family:c})});return Y(Y(Y({},f),pg({values:e,family:c,styles:gn,config:K,canonical:f,givenPrefix:i})),dg(r,i,f))}function dg(e,t,n){var r=n.prefix,i=n.iconName;if(e||!r||!i)return{prefix:r,iconName:i};var a=t==="fa"?gu(i):{},s=bt(r,i);return i=a.iconName||s||i,r=a.prefix||r,r==="far"&&!gn.far&&gn.fas&&!K.autoFetchSvg&&(r="fas"),{prefix:r,iconName:i}}var hg=_l.filter(function(e){return e!==pe||e!==fn}),mg=Object.keys(Ii).filter(function(e){return e!==pe}).map(function(e){return Object.keys(Ii[e])}).flat();function pg(e){var t=e.values,n=e.family,r=e.canonical,i=e.givenPrefix,a=i===void 0?"":i,s=e.styles,o=s===void 0?{}:s,u=e.config,d=u===void 0?{}:u,l=n===fn,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&&hg.includes(n)){var m=Object.keys(o).find(function(A){return mg.includes(A)});if(m||d.autoFetchSvg){var b=jp.get(n).defaultShortPrefixId;r.prefix=b,r.iconName=bt(r.prefix,r.iconName)||r.iconName}}return(r.prefix==="fa"||a==="fa")&&(r.prefix=ot()||"fas"),r}var gg=(function(){function e(){ep(this,e),this.definitions={}}return np(e,[{key:"add",value:function(){for(var n=this,r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];var s=i.reduce(this._pullDefinitions,{});Object.keys(s).forEach(function(o){n.definitions[o]=Y(Y({},n.definitions[o]||{}),s[o]),Hi(o,s[o]);var u=Vi[pe][o];u&&Hi(u,s[o]),pu()})}},{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(a){var s=i[a],o=s.prefix,u=s.iconName,d=s.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}}])})(),xu=[],Bt={},Wt={},yg=Object.keys(Wt);function vg(e,t){var n=t.mixoutsTo;return xu=e,Bt={},Object.keys(Wt).forEach(function(r){yg.indexOf(r)===-1&&delete Wt[r]}),xu.forEach(function(r){var i=r.mixout?r.mixout():{};if(Object.keys(i).forEach(function(s){typeof i[s]=="function"&&(n[s]=i[s]),Hn(i[s])==="object"&&Object.keys(i[s]).forEach(function(o){n[s]||(n[s]={}),n[s][o]=i[s][o]})}),r.hooks){var a=r.hooks();Object.keys(a).forEach(function(s){Bt[s]||(Bt[s]=[]),Bt[s].push(a[s])})}r.provides&&r.provides(Wt)}),n}function Ki(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 a=Bt[e]||[];return a.forEach(function(s){t=s.apply(null,[t].concat(r))}),t}function xt(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=Bt[e]||[];i.forEach(function(a){a.apply(null,n)})}function lt(){var e=arguments[0],t=Array.prototype.slice.call(arguments,1);return Wt[e]?Wt[e].apply(null,t):void 0}function Xi(e){e.prefix==="fa"&&(e.prefix="fas");var t=e.iconName,n=e.prefix||ot();if(t)return t=bt(n,t)||t,su(wu.definitions,n,t)||su(_e.styles,n,t)}var wu=new gg,bg=function(){K.autoReplaceSvg=!1,K.observeMutations=!1,xt("noAuto")},xg={i2svg:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return qe?(xt("beforeI2svg",t),lt("pseudoElements2svg",t),lt("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,rg(function(){Ag({autoReplaceSvgRoot:n}),xt("watch",t)})}},wg={icon:function(t){if(t===null)return null;if(Hn(t)==="object"&&t.prefix&&t.iconName)return{prefix:t.prefix,iconName:bt(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=qn(t[0]);return{prefix:r,iconName:bt(r,n)||n}}if(typeof t=="string"&&(t.indexOf("".concat(K.cssPrefix,"-"))>-1||t.match($0))){var i=Qn(t.split(" "),{skipLookups:!0});return{prefix:i.prefix||ot(),iconName:bt(i.prefix,i.iconName)||i.iconName}}if(typeof t=="string"){var a=ot();return{prefix:a,iconName:bt(a,t)||t}}}},Ce={noAuto:bg,config:K,dom:xg,parse:wg,library:wu,findIconDefinition:Xi,toHtml:pn},Ag=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.autoReplaceSvgRoot,r=n===void 0?ee:n;(Object.keys(_e.styles).length>0||K.autoFetchSvg)&&qe&&K.autoReplaceSvg&&Ce.dom.i2svg({node:r})};function Zn(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map(function(r){return pn(r)})}}),Object.defineProperty(e,"node",{get:function(){if(qe){var r=ee.createElement("div");return r.innerHTML=e.html,r.children}}}),e}function Sg(e){var t=e.children,n=e.main,r=e.mask,i=e.attributes,a=e.styles,s=e.transform;if(zi(s)&&n.found&&!r.found){var o=n.width,u=n.height,d={x:o/u/2,y:.5};i.style=Kn(Y(Y({},a),{},{"transform-origin":"".concat(d.x+s.x/16,"em ").concat(d.y+s.y/16,"em")}))}return[{tag:"svg",attributes:i,children:t}]}function Tg(e){var t=e.prefix,n=e.iconName,r=e.children,i=e.attributes,a=e.symbol,s=a===!0?"".concat(t,"-").concat(K.cssPrefix,"-").concat(n):a;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:Y(Y({},i),{},{id:s}),children:r}]}]}function Pg(e){var t=["aria-label","aria-labelledby","title","role"];return t.some(function(n){return n in e})}function qi(e){var t=e.icons,n=t.main,r=t.mask,i=e.prefix,a=e.iconName,s=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,a?"".concat(K.cssPrefix,"-").concat(a):""].filter(function(P){return d.classes.indexOf(P)===-1}).filter(function(P){return P!==""||!!P}).concat(d.classes).join(" "),A={children:[],attributes:Y(Y({},d.attributes),{},{"data-prefix":i,"data-icon":a,class:b,role:d.attributes.role||"img",viewBox:"0 0 ".concat(h," ").concat(m)})};!Pg(d.attributes)&&!d.attributes["aria-hidden"]&&(A.attributes["aria-hidden"]="true"),c&&(A.attributes[vt]="");var v=Y(Y({},A),{},{prefix:i,iconName:a,main:n,mask:r,maskId:u,transform:s,symbol:o,styles:Y({},d.styles)}),I=r.found&&n.found?lt("generateAbstractMask",v)||{children:[],attributes:{}}:lt("generateAbstractIcon",v)||{children:[],attributes:{}},T=I.children,C=I.attributes;return v.children=T,v.attributes=C,o?Tg(v):Sg(v)}function Au(e){var t=e.content,n=e.width,r=e.height,i=e.transform,a=e.extra,s=e.watchable,o=s===void 0?!1:s,u=Y(Y({},a.attributes),{},{class:a.classes.join(" ")});o&&(u[vt]="");var d=Y({},a.styles);zi(i)&&(d.transform=eg({transform:i,width:n,height:r}),d["-webkit-transform"]=d.transform);var l=Kn(d);l.length>0&&(u.style=l);var c=[];return c.push({tag:"span",attributes:u,children:[t]}),c}function Eg(e){var t=e.content,n=e.extra,r=Y(Y({},n.attributes),{},{class:n.classes.join(" ")}),i=Kn(n.styles);i.length>0&&(r.style=i);var a=[];return a.push({tag:"span",attributes:r,children:[t]}),a}var Qi=_e.styles;function Zi(e){var t=e[0],n=e[1],r=e.slice(4),i=Wn(r,1),a=i[0],s=null;return Array.isArray(a)?s={tag:"g",attributes:{class:"".concat(K.cssPrefix,"-").concat(Ui.GROUP)},children:[{tag:"path",attributes:{class:"".concat(K.cssPrefix,"-").concat(Ui.SECONDARY),fill:"currentColor",d:a[0]}},{tag:"path",attributes:{class:"".concat(K.cssPrefix,"-").concat(Ui.PRIMARY),fill:"currentColor",d:a[1]}}]}:s={tag:"path",attributes:{fill:"currentColor",d:a}},{found:!0,width:t,height:n,icon:s}}var Cg={found:!1,width:512,height:512};function kg(e,t){!Xl&&!K.showMissingIcons&&e&&console.error('Icon with name "'.concat(e,'" and prefix "').concat(t,'" is missing.'))}function Ji(e,t){var n=t;return t==="fa"&&K.styleDefault!==null&&(t=ot()),new Promise(function(r,i){if(n==="fa"){var a=gu(e)||{};e=a.iconName||e,t=a.prefix||t}if(e&&t&&Qi[t]&&Qi[t][e]){var s=Qi[t][e];return r(Zi(s))}kg(e,t),r(Y(Y({},Cg),{},{icon:K.showMissingIcons&&e?lt("missingIconAbstract")||{}:{}}))})}var Su=function(){},ea=K.measurePerformance&&Yn&&Yn.mark&&Yn.measure?Yn:{mark:Su,measure:Su},yn='FA "7.1.0"',Mg=function(t){return ea.mark("".concat(yn," ").concat(t," begins")),function(){return Tu(t)}},Tu=function(t){ea.mark("".concat(yn," ").concat(t," ends")),ea.measure("".concat(yn," ").concat(t),"".concat(yn," ").concat(t," begins"),"".concat(yn," ").concat(t," ends"))},ta={begin:Mg,end:Tu},Jn=function(){};function Pu(e){var t=e.getAttribute?e.getAttribute(vt):null;return typeof t=="string"}function Dg(e){var t=e.getAttribute?e.getAttribute(Ni):null,n=e.getAttribute?e.getAttribute(Oi):null;return t&&n}function Ig(e){return e&&e.classList&&e.classList.contains&&e.classList.contains(K.replacementClass)}function jg(){if(K.autoReplaceSvg===!0)return er.replace;var e=er[K.autoReplaceSvg];return e||er.replace}function Fg(e){return ee.createElementNS("http://www.w3.org/2000/svg",e)}function Ng(e){return ee.createElement(e)}function Eu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.ceFn,r=n===void 0?e.tag==="svg"?Fg:Ng:n;if(typeof e=="string")return ee.createTextNode(e);var i=r(e.tag);Object.keys(e.attributes||[]).forEach(function(s){i.setAttribute(s,e.attributes[s])});var a=e.children||[];return a.forEach(function(s){i.appendChild(Eu(s,{ceFn:r}))}),i}function Og(e){var t=" ".concat(e.outerHTML," ");return t="".concat(t,"Font Awesome fontawesome.com "),t}var er={replace:function(t){var n=t[0];if(n.parentNode)if(t[1].forEach(function(i){n.parentNode.insertBefore(Eu(i),n)}),n.getAttribute(vt)===null&&K.keepOriginalSource){var r=ee.createComment(Og(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 er.replace(t);var i=new RegExp("".concat(K.cssPrefix,"-.*"));if(delete r[0].attributes.id,r[0].attributes.class){var a=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=a.toSvg.join(" "),a.toNode.length===0?n.removeAttribute("class"):n.setAttribute("class",a.toNode.join(" "))}var s=r.map(function(o){return pn(o)}).join(`
568
- `);n.setAttribute(vt,""),n.innerHTML=s}};function Cu(e){e()}function ku(e,t){var n=typeof t=="function"?t:Jn;if(e.length===0)n();else{var r=Cu;K.mutateApproach===V0&&(r=st.requestAnimationFrame||Cu),r(function(){var i=jg(),a=ta.begin("mutate");e.map(i),a(),n()})}}var na=!1;function Mu(){na=!0}function ra(){na=!1}var tr=null;function Du(e){if(bl&&K.observeMutations){var t=e.treeCallback,n=t===void 0?Jn:t,r=e.nodeCallback,i=r===void 0?Jn:r,a=e.pseudoElementsCallback,s=a===void 0?Jn:a,o=e.observeMutationsRoot,u=o===void 0?ee:o;tr=new bl(function(d){if(!na){var l=ot();zt(d).forEach(function(c){if(c.type==="childList"&&c.addedNodes.length>0&&!Pu(c.addedNodes[0])&&(K.searchPseudoElements&&s(c.target),n(c.target)),c.type==="attributes"&&c.target.parentNode&&K.searchPseudoElements&&s([c.target],!0),c.type==="attributes"&&Pu(c.target)&&~W0.indexOf(c.attributeName))if(c.attributeName==="class"&&Dg(c.target)){var f=Qn($i(c.target)),h=f.prefix,m=f.iconName;c.target.setAttribute(Ni,h||l),m&&c.target.setAttribute(Oi,m)}else Ig(c.target)&&i(c.target)})}}),qe&&tr.observe(u,{childList:!0,attributes:!0,characterData:!0,subtree:!0})}}function Lg(){tr&&tr.disconnect()}function Rg(e){var t=e.getAttribute("style"),n=[];return t&&(n=t.split(";").reduce(function(r,i){var a=i.split(":"),s=a[0],o=a.slice(1);return s&&o.length>0&&(r[s]=o.join(":").trim()),r},{})),n}function Vg(e){var t=e.getAttribute("data-prefix"),n=e.getAttribute("data-icon"),r=e.innerText!==void 0?e.innerText.trim():"",i=Qn($i(e));return i.prefix||(i.prefix=ot()),t&&n&&(i.prefix=t,i.iconName=n),i.iconName&&i.prefix||(i.prefix&&r.length>0&&(i.iconName=lg(i.prefix,e.innerText)||Gi(i.prefix,ou(e.innerText))),!i.iconName&&K.autoFetchSvg&&e.firstChild&&e.firstChild.nodeType===Node.TEXT_NODE&&(i.iconName=e.firstChild.data)),i}function _g(e){var t=zt(e.attributes).reduce(function(n,r){return n.name!=="class"&&n.name!=="style"&&(n[r.name]=r.value),n},{});return t}function Ug(){return{iconName:null,prefix:null,transform:Be,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}}}function Iu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{styleParser:!0},n=Vg(e),r=n.iconName,i=n.prefix,a=n.rest,s=_g(e),o=Ki("parseNodeAttributes",{},e),u=t.styleParser?Rg(e):[];return Y({iconName:r,prefix:i,transform:Be,mask:{iconName:null,prefix:null,rest:[]},maskId:null,symbol:!1,extra:{classes:a,styles:u,attributes:s}},o)}var $g=_e.styles;function ju(e){var t=K.autoReplaceSvg==="nest"?Iu(e,{styleParser:!1}):Iu(e);return~t.extra.classes.indexOf(Zl)?lt("generateLayersText",e,t):lt("generateSvgReplacementMutation",e,t)}function zg(){return[].concat(Ve(Ul),Ve(Bl))}function Fu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(!qe)return Promise.resolve();var n=ee.documentElement.classList,r=function(c){return n.add("".concat(Gl,"-").concat(c))},i=function(c){return n.remove("".concat(Gl,"-").concat(c))},a=K.autoFetchSvg?zg():Al.concat(Object.keys($g));a.includes("fa")||a.push("fa");var s=[".".concat(Zl,":not([").concat(vt,"])")].concat(a.map(function(l){return".".concat(l,":not([").concat(vt,"])")})).join(", ");if(s.length===0)return Promise.resolve();var o=[];try{o=zt(e.querySelectorAll(s))}catch{}if(o.length>0)r("pending"),i("complete");else return Promise.resolve();var u=ta.begin("onTree"),d=o.reduce(function(l,c){try{var f=ju(c);f&&l.push(f)}catch(h){Xl||h.name==="MissingIcon"&&console.error(h)}return l},[]);return new Promise(function(l,c){Promise.all(d).then(function(f){ku(f,function(){r("active"),r("complete"),i("pending"),typeof t=="function"&&t(),u(),l()})}).catch(function(f){u(),c(f)})})}function Bg(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;ju(e).then(function(n){n&&ku([n],t)})}function Wg(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=(t||{}).icon?t:Xi(t||{}),i=n.mask;return i&&(i=(i||{}).icon?i:Xi(i||{})),e(r,Y(Y({},n),{},{mask:i}))}}var Hg=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.transform,i=r===void 0?Be:r,a=n.symbol,s=a===void 0?!1:a,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,A=b===void 0?{}:b;if(t){var v=t.prefix,I=t.iconName,T=t.icon;return Zn(Y({type:"icon"},t),function(){return xt("beforeDOMElementCreation",{iconDefinition:t,params:n}),qi({icons:{main:Zi(T),mask:u?Zi(u.icon):{found:!1,width:null,height:null,icon:{}}},prefix:v,iconName:I,transform:Y(Y({},Be),i),symbol:s,maskId:l,extra:{attributes:m,styles:A,classes:f}})})}},Yg={mixout:function(){return{icon:Wg(Hg)}},hooks:function(){return{mutationObserverCallbacks:function(n){return n.treeCallback=Fu,n.nodeCallback=Bg,n}}},provides:function(t){t.i2svg=function(n){var r=n.node,i=r===void 0?ee:r,a=n.callback,s=a===void 0?function(){}:a;return Fu(i,s)},t.generateSvgReplacementMutation=function(n,r){var i=r.iconName,a=r.prefix,s=r.transform,o=r.symbol,u=r.mask,d=r.maskId,l=r.extra;return new Promise(function(c,f){Promise.all([Ji(i,a),u.iconName?Ji(u.iconName,u.prefix):Promise.resolve({found:!1,width:512,height:512,icon:{}})]).then(function(h){var m=Wn(h,2),b=m[0],A=m[1];c([n,qi({icons:{main:b,mask:A},prefix:a,iconName:i,transform:s,symbol:o,maskId:d,extra:l,watchable:!0})])}).catch(f)})},t.generateAbstractIcon=function(n){var r=n.children,i=n.attributes,a=n.main,s=n.transform,o=n.styles,u=Kn(o);u.length>0&&(i.style=u);var d;return zi(s)&&(d=lt("generateAbstractTransformGrouping",{main:a,transform:s,containerWidth:a.width,iconWidth:a.width})),r.push(d||a.icon),{children:r,attributes:i}}}},Gg={mixout:function(){return{layer:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.classes,a=i===void 0?[]:i;return Zn({type:"layer"},function(){xt("beforeDOMElementCreation",{assembler:n,params:r});var s=[];return n(function(o){Array.isArray(o)?o.map(function(u){s=s.concat(u.abstract)}):s=s.concat(o.abstract)}),[{tag:"span",attributes:{class:["".concat(K.cssPrefix,"-layers")].concat(Ve(a)).join(" ")},children:s}]})}}}},Kg={mixout:function(){return{counter:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};r.title;var i=r.classes,a=i===void 0?[]:i,s=r.attributes,o=s===void 0?{}:s,u=r.styles,d=u===void 0?{}:u;return Zn({type:"counter",content:n},function(){return xt("beforeDOMElementCreation",{content:n,params:r}),Eg({content:n.toString(),extra:{attributes:o,styles:d,classes:["".concat(K.cssPrefix,"-layers-counter")].concat(Ve(a))}})})}}}},Xg={mixout:function(){return{text:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=r.transform,a=i===void 0?Be:i,s=r.classes,o=s===void 0?[]:s,u=r.attributes,d=u===void 0?{}:u,l=r.styles,c=l===void 0?{}:l;return Zn({type:"text",content:n},function(){return xt("beforeDOMElementCreation",{content:n,params:r}),Au({content:n,transform:Y(Y({},Be),a),extra:{attributes:d,styles:c,classes:["".concat(K.cssPrefix,"-layers-text")].concat(Ve(o))}})})}}},provides:function(t){t.generateLayersText=function(n,r){var i=r.transform,a=r.extra,s=null,o=null;if(xl){var u=parseInt(getComputedStyle(n).fontSize,10),d=n.getBoundingClientRect();s=d.width/u,o=d.height/u}return Promise.resolve([n,Au({content:n.innerHTML,width:s,height:o,transform:i,extra:a,watchable:!0})])}}},Nu=new RegExp('"',"ug"),Ou=[1105920,1112319],Lu=Y(Y(Y(Y({},{FontAwesome:{normal:"fas",400:"fas"}}),Ip),L0),Up),ia=Object.keys(Lu).reduce(function(e,t){return e[t.toLowerCase()]=Lu[t],e},{}),qg=Object.keys(ia).reduce(function(e,t){var n=ia[t];return e[t]=n[900]||Ve(Object.entries(n))[0][1],e},{});function Qg(e){var t=e.replace(Nu,"");return ou(Ve(t)[0]||"")}function Zg(e){var t=e.getPropertyValue("font-feature-settings").includes("ss01"),n=e.getPropertyValue("content"),r=n.replace(Nu,""),i=r.codePointAt(0),a=i>=Ou[0]&&i<=Ou[1],s=r.length===2?r[0]===r[1]:!1;return a||s||t}function Jg(e,t){var n=e.replace(/^['"]|['"]$/g,"").toLowerCase(),r=parseInt(t),i=isNaN(r)?"normal":r;return(ia[n]||{})[i]||qg[n]}function Ru(e,t){var n="".concat(R0).concat(t.replace(":","-"));return new Promise(function(r,i){if(e.getAttribute(n)!==null)return r();var a=zt(e.children),s=a.filter(function(w){return w.getAttribute(Fi)===t})[0],o=st.getComputedStyle(e,t),u=o.getPropertyValue("font-family"),d=u.match(z0),l=o.getPropertyValue("font-weight"),c=o.getPropertyValue("content");if(s&&!d)return e.removeChild(s),r();if(d&&c!=="none"&&c!==""){var f=o.getPropertyValue("content"),h=Jg(u,l),m=Qg(f),b=d[0].startsWith("FontAwesome"),A=Zg(o),v=Gi(h,m),I=v;if(b){var T=ug(m);T.iconName&&T.prefix&&(v=T.iconName,h=T.prefix)}if(v&&!A&&(!s||s.getAttribute(Ni)!==h||s.getAttribute(Oi)!==I)){e.setAttribute(n,I),s&&e.removeChild(s);var C=Ug(),P=C.extra;P.attributes[Fi]=t,Ji(v,h).then(function(w){var L=qi(Y(Y({},C),{},{icons:{main:w,mask:yu()},prefix:h,iconName:I,extra:P,watchable:!0})),p=ee.createElementNS("http://www.w3.org/2000/svg","svg");t==="::before"?e.insertBefore(p,e.firstChild):e.appendChild(p),p.outerHTML=L.map(function(y){return pn(y)}).join(`
569
- `),e.removeAttribute(n),r()}).catch(i)}else r()}else r()})}function e1(e){return Promise.all([Ru(e,"::before"),Ru(e,"::after")])}function t1(e){return e.parentNode!==document.head&&!~_0.indexOf(e.tagName.toUpperCase())&&!e.getAttribute(Fi)&&(!e.parentNode||e.parentNode.tagName!=="svg")}var n1=function(t){return!!t&&Kl.some(function(n){return t.includes(n)})},r1=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=Bn(r),a;try{for(i.s();!(a=i.n()).done;){var s=a.value;if(n1(s)){var o=Kl.reduce(function(u,d){return u.replace(d,"")},s);o!==""&&o!=="*"&&n.add(o)}}}catch(u){i.e(u)}finally{i.f()}return n};function Vu(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(qe){var n;if(t)n=e;else if(K.searchPseudoElementsFullScan)n=e.querySelectorAll("*");else{var r=new Set,i=Bn(document.styleSheets),a;try{for(i.s();!(a=i.n()).done;){var s=a.value;try{var o=Bn(s.cssRules),u;try{for(o.s();!(u=o.n()).done;){var d=u.value,l=r1(d.selectorText),c=Bn(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(s.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,A){var v=zt(n).filter(t1).map(e1),I=ta.begin("searchPseudoElements");Mu(),Promise.all(v).then(function(){I(),ra(),b()}).catch(function(){I(),ra(),A()})})}}var i1={hooks:function(){return{mutationObserverCallbacks:function(n){return n.pseudoElementsCallback=Vu,n}}},provides:function(t){t.pseudoElements2svg=function(n){var r=n.node,i=r===void 0?ee:r;K.searchPseudoElements&&Vu(i)}}},_u=!1,a1={mixout:function(){return{dom:{unwatch:function(){Mu(),_u=!0}}}},hooks:function(){return{bootstrap:function(){Du(Ki("mutationObserverCallbacks",{}))},noAuto:function(){Lg()},watch:function(n){var r=n.observeMutationsRoot;_u?ra():Du(Ki("mutationObserverCallbacks",{observeMutationsRoot:r}))}}}},Uu=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 a=i.toLowerCase().split("-"),s=a[0],o=a.slice(1).join("-");if(s&&o==="h")return r.flipX=!0,r;if(s&&o==="v")return r.flipY=!0,r;if(o=parseFloat(o),isNaN(o))return r;switch(s){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)},s1={mixout:function(){return{parse:{transform:function(n){return Uu(n)}}}},hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-transform");return i&&(n.transform=Uu(i)),n}}},provides:function(t){t.generateAbstractTransformGrouping=function(n){var r=n.main,i=n.transform,a=n.containerWidth,s=n.iconWidth,o={transform:"translate(".concat(a/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(s/2*-1," -256)")},h={outer:o,inner:c,path:f};return{tag:"g",attributes:Y({},h.outer),children:[{tag:"g",attributes:Y({},h.inner),children:[{tag:r.icon.tag,children:r.icon.children,attributes:Y(Y({},r.icon.attributes),h.path)}]}]}}}},aa={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 o1(e){return e.tag==="g"?e.children:[e]}var l1={hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-mask"),a=i?Qn(i.split(" ").map(function(s){return s.trim()})):yu();return a.prefix||(a.prefix=ot()),n.mask=a,n.maskId=r.getAttribute("data-fa-mask-id"),n}}},provides:function(t){t.generateAbstractMask=function(n){var r=n.children,i=n.attributes,a=n.main,s=n.mask,o=n.maskId,u=n.transform,d=a.width,l=a.icon,c=s.width,f=s.icon,h=J0({transform:u,containerWidth:c,iconWidth:d}),m={tag:"rect",attributes:Y(Y({},aa),{},{fill:"white"})},b=l.children?{children:l.children.map($u)}:{},A={tag:"g",attributes:Y({},h.inner),children:[$u(Y({tag:l.tag,attributes:Y(Y({},l.attributes),h.path)},b))]},v={tag:"g",attributes:Y({},h.outer),children:[A]},I="mask-".concat(o||eu()),T="clip-".concat(o||eu()),C={tag:"mask",attributes:Y(Y({},aa),{},{id:I,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[m,v]},P={tag:"defs",children:[{tag:"clipPath",attributes:{id:T},children:o1(f)},C]};return r.push(P,{tag:"rect",attributes:Y({fill:"currentColor","clip-path":"url(#".concat(T,")"),mask:"url(#".concat(I,")")},aa)}),{children:r,attributes:i}}}},u1={provides:function(t){var n=!1;st.matchMedia&&(n=st.matchMedia("(prefers-reduced-motion: reduce)").matches),t.missingIconAbstract=function(){var r=[],i={fill:"currentColor"},a={attributeType:"XML",repeatCount:"indefinite",dur:"2s"};r.push({tag:"path",attributes:Y(Y({},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 s=Y(Y({},a),{},{attributeName:"opacity"}),o={tag:"circle",attributes:Y(Y({},i),{},{cx:"256",cy:"364",r:"28"}),children:[]};return n||o.children.push({tag:"animate",attributes:Y(Y({},a),{},{attributeName:"r",values:"28;14;28;28;14;28;"})},{tag:"animate",attributes:Y(Y({},s),{},{values:"1;0;1;1;0;1;"})}),r.push(o),r.push({tag:"path",attributes:Y(Y({},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:Y(Y({},s),{},{values:"1;0;0;0;0;1;"})}]}),n||r.push({tag:"path",attributes:Y(Y({},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:Y(Y({},s),{},{values:"0;0;1;1;0;0;"})}]}),{tag:"g",attributes:{class:"missing"},children:r}}}},c1={hooks:function(){return{parseNodeAttributes:function(n,r){var i=r.getAttribute("data-fa-symbol"),a=i===null?!1:i===""?!0:i;return n.symbol=a,n}}}},f1=[ng,Yg,Gg,Kg,Xg,i1,a1,s1,l1,u1,c1];vg(f1,{mixoutsTo:Ce}),Ce.noAuto;var vn=Ce.config,d1=Ce.library;Ce.dom;var zu=Ce.parse;Ce.findIconDefinition,Ce.toHtml;var h1=Ce.icon;Ce.layer,Ce.text,Ce.counter;function m1(e){return e=e-0,e===e}function Bu(e){return m1(e)?e:(e=e.replace(/[_-]+(.)?/g,(t,n)=>n?n.toUpperCase():""),e.charAt(0).toLowerCase()+e.slice(1))}function p1(e){return e.charAt(0).toUpperCase()+e.slice(1)}var Ht=new Map,g1=1e3;function y1(e){if(Ht.has(e))return Ht.get(e);const t={};let n=0;const r=e.length;for(;n<r;){const i=e.indexOf(";",n),a=i===-1?r:i,s=e.slice(n,a).trim();if(s){const o=s.indexOf(":");if(o>0){const u=s.slice(0,o).trim(),d=s.slice(o+1).trim();if(u&&d){const l=Bu(u);t[l.startsWith("webkit")?p1(l):l]=d}}}n=a+1}if(Ht.size===g1){const i=Ht.keys().next().value;i&&Ht.delete(i)}return Ht.set(e,t),t}function Wu(e,t,n={}){if(typeof t=="string")return t;const r=(t.children||[]).map(l=>Wu(e,l)),i=t.attributes||{},a={};for(const[l,c]of Object.entries(i))switch(!0){case l==="class":{a.className=c;break}case l==="style":{a.style=y1(String(c));break}case l.startsWith("aria-"):case l.startsWith("data-"):{a[l.toLowerCase()]=c;break}default:a[Bu(l)]=c}const{style:s,role:o,"aria-label":u,...d}=n;return s&&(a.style=a.style?{...a.style,...s}:s),o&&(a.role=o),u&&(a["aria-label"]=u,a["aria-hidden"]="false"),e(t.tag,{...d,...a},...r)}var v1=Wu.bind(null,z.createElement),Hu=(e,t)=>{const n=z.useId();return e||(t?n:void 0)},b1=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 x1="searchPseudoElementsFullScan"in vn?"7.0.0":"6.0.0",w1=Number.parseInt(x1)>=7,bn="fa",Je={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"},A1={left:"fa-pull-left",right:"fa-pull-right"},S1={90:"fa-rotate-90",180:"fa-rotate-180",270:"fa-rotate-270"},T1={"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"},et={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 P1(e){const t=vn.cssPrefix||vn.familyPrefix||bn;return t===bn?e:e.replace(new RegExp(String.raw`(?<=^|\s)${bn}-`,"g"),`${t}-`)}function E1(e){const{beat:t,fade:n,beatFade:r,bounce:i,shake:a,spin:s,spinPulse:o,spinReverse:u,pulse:d,fixedWidth:l,inverse:c,border:f,flip:h,size:m,rotation:b,pull:A,swapOpacity:v,rotateBy:I,widthAuto:T,className:C}=e,P=[];return C&&P.push(...C.split(" ")),t&&P.push(Je.beat),n&&P.push(Je.fade),r&&P.push(Je.beatFade),i&&P.push(Je.bounce),a&&P.push(Je.shake),s&&P.push(Je.spin),u&&P.push(Je.spinReverse),o&&P.push(Je.spinPulse),d&&P.push(Je.pulse),l&&P.push(et.fixedWidth),c&&P.push(et.inverse),f&&P.push(et.border),h===!0&&P.push(et.flip),(h==="horizontal"||h==="both")&&P.push(et.flipHorizontal),(h==="vertical"||h==="both")&&P.push(et.flipVertical),m!=null&&P.push(T1[m]),b!=null&&b!==0&&P.push(S1[b]),A!=null&&P.push(A1[A]),v&&P.push(et.swapOpacity),w1?(I&&P.push(et.rotateBy),T&&P.push(et.widthAuto),(vn.cssPrefix||vn.familyPrefix||bn)===bn?P:P.map(P1)):P}var C1=e=>typeof e=="object"&&"icon"in e&&!!e.icon;function Yu(e){if(e)return C1(e)?e:zu.icon(e)}function k1(e){return Object.keys(e)}var Gu=new b1("FontAwesomeIcon"),Ku={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},M1=new Set(Object.keys(Ku)),ke=z.forwardRef((e,t)=>{const n={...Ku,...e},{icon:r,mask:i,symbol:a,title:s,titleId:o,maskId:u,transform:d}=n,l=Hu(u,!!i),c=Hu(o,!!s),f=Yu(r);if(!f)return Gu.error("Icon lookup is undefined",r),null;const h=E1(n),m=typeof d=="string"?zu.transform(d):d,b=Yu(i),A=h1(f,{...h.length>0&&{classes:h},...m&&{transform:m},...b&&{mask:b},symbol:a,title:s,titleId:c,maskId:l});if(!A)return Gu.error("Could not find icon",f),null;const{abstract:v}=A,I={ref:t};for(const T of k1(n))M1.has(T)||(I[T]=n[T]);return v1(v[0],I)});ke.displayName="FontAwesomeIcon";function D1({headingBlock:e,modifyHeading:t}){return k.jsx("input",{type:"text",className:"border-b heading",placeholder:"Heading...",autoFocus:!0,value:e.data.text,onChange:n=>t({headingBlockId:e.id,newContent:n.target.value,level:1})})}function I1({headingBlock:e}){return k.jsx("h2",{className:"heading",children:e.data.text},e.id)}function j1({subheadingBlock:e,modifySubheading:t}){return k.jsx("input",{type:"text",className:"border-b subheading",placeholder:"sub heading ...",autoFocus:!0,value:e.data.text,onChange:n=>t({subheadingBlockId:e.id,newContent:n.target.value})})}function F1({subheadingBlock:e}){return k.jsx("h2",{className:"subheading",children:e.data.text},e.id)}function N1({paragraphBlock:e,modifyParagraph:t}){return k.jsx("textarea",{className:"border-b paragraph",placeholder:"Write something...",autoFocus:!0,value:e.data.text,onChange:n=>t({paragraphBlockId:e.id,newContent:n.target.value})})}function O1({paragraphBlock:e}){return k.jsx("p",{className:"paragraph",children:e.data.text},e.id)}function L1({listBlock:e,modifyList:t}){return k.jsx("input",{type:"text",className:"border-b w-full list",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 R1({listBlock:e}){return k.jsx("ul",{className:"list-disc pl-5 list",children:e.data.items.map((t,n)=>k.jsx("li",{children:t},n))},e.id)}function V1({quoteBlock:e,modifyQuote:t}){return k.jsx("input",{type:"text",className:"border-b quote",placeholder:"Quote...",autoFocus:!0,value:e.data.text,onChange:n=>t({quoteBlockId:e.id,newContent:n.target.value,author:e.data.author})})}function _1({quoteBlock:e}){return k.jsx("blockquote",{className:"quote",children:e.data.text},e.id)}function U1({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 k.jsxs("table",{className:"mt-4",children:[k.jsx("thead",{children:k.jsx("tr",{children:e.data?.head?.map((i,a)=>k.jsx("th",{className:"border p-2",children:k.jsx("input",{type:"text",className:"outline-none w-full",autoFocus:!0,value:i.content,onChange:s=>{const o=e.data.head.map(d=>d.id===i.id?{...d,content:s.target.value}:d),u={...e.data,head:o};t({tableBlockId:e.id,tableContent:u})}})},a))})}),k.jsx("tbody",{children:Array.from({length:r.rows+1},(i,a)=>{const s=[];for(let o=0;o<=r.cols;o++)s.push(k.jsx("td",{className:"border p-2",children:k.jsx("input",{type:"text",className:"outline-none w-full",placeholder:`Row ${a+1}, Col ${o+1}`,value:n.body.find(u=>u.id[0]===a&&u.id[1]===o)?.content||"",onChange:u=>{const d=n.body.map(c=>c.id[0]===a&&c.id[1]===o?{...c,content:u.target.value}:c),l={...n,body:d};t({tableBlockId:e.id,tableContent:l})}})},`${a}-${o}`));return k.jsx("tr",{children:s},a)})})]})}function $1({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((a,s,o)=>{const u=Math.floor(o/r);return a[u]||(a[u]=[]),a[u].push(s),a},[]);return k.jsxs("table",{className:"w-full",children:[k.jsx("thead",{children:k.jsx("tr",{children:t.map(a=>k.jsx("th",{className:"border p-2",children:a.content},a.id))})}),k.jsx("tbody",{children:i.map((a,s)=>k.jsx("tr",{children:a.map(o=>k.jsx("td",{className:"border p-2",children:o.content},o.id.join("-")))},s))})]},e.id)}function z1({handleClick:e}){const[t,n]=z.useState(!1),[r,i]=z.useState(0),[a,s]=z.useState(0),[o,u]=z.useState({rows:2,cols:2}),d=10;z.useEffect(()=>{r<0&&i(0),a<0&&s(0),u({rows:r,cols:a})},[r,a]);const l=()=>{n(!1),e("table",o)};return k.jsxs("div",{className:"relative",children:[k.jsx(ke,{icon:["fas","angle-down"],onClick:()=>n(c=>!c)}),t?k.jsxs("div",{className:"absolute -translate-x-[40px] translate-y-[10px] bg-white flex flex-col gap-1 w-40 h-50 border border-gray-600 rounded-[10px] cursor-pointer p-2",children:[k.jsxs("div",{className:"flex w-full gap-1",children:[k.jsx("input",{className:"w-[40px] underline text-center border rounded-[5px]",type:"number",value:r,onChange:c=>i(c.target.value)}),"x",k.jsx("input",{className:"w-[40px] underline text-center border rounded-[5px]",type:"number",value:a,onChange:c=>s(c.target.value)}),k.jsx("button",{className:"border rounded-[5px] leading-none px-1 border-(--draftify-theme-color) text-(--draftify-theme-color) cursor-pointer hover:bg-(--draftify-theme-color) hover:text-white",onClick:l,children:"enter"})]}),[...Array(d)].map((c,f)=>k.jsx("div",{className:"flex gap-1",children:[...Array(d)].map((h,m)=>k.jsx("div",{className:`flex-1 h-3 border border-gray-600 rounded-2 ${f<=o.rows&&m<=o.cols?"bg-blue-400":"bg-gray-200"}`,onMouseEnter:()=>{i(f),s(m)},onMouseLeave:()=>u({rows:0,cols:0}),onClick:l},`${f}-${m}`))},f))]}):null]})}function B1(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 Xu(e,t){return new Promise((function(n,r){let i;return W1(e).then((function(a){try{return i=a,n(new Blob([t.slice(0,2),i,t.slice(2)],{type:"image/jpeg"}))}catch(s){return r(s)}}),r)}))}const W1=e=>new Promise(((t,n)=>{const r=new FileReader;r.addEventListener("load",(({target:{result:i}})=>{const a=new DataView(i);let s=0;if(a.getUint16(s)!==65496)return n("not a valid JPEG");for(s+=2;;){const o=a.getUint16(s);if(o===65498)break;const u=a.getUint16(s+2);if(o===65505&&a.getUint32(s+4)===1165519206){const d=s+10;let l;switch(a.getUint16(d)){case 18761:l=!0;break;case 19789:l=!1;break;default:return n("TIFF header contains invalid endian")}if(a.getUint16(d+2,l)!==42)return n("TIFF header contains invalid version");const c=a.getUint32(d+4,l),f=d+c+2+12*a.getUint16(d+c,l);for(let h=d+c+2;h<f;h+=12)if(a.getUint16(h,l)==274){if(a.getUint16(h+2,l)!==3)return n("Orientation data type is invalid");if(a.getUint32(h+4,l)!==1)return n("Orientation data count is invalid");a.setUint16(h+8,1,l);break}return t(i.slice(s,s+2+u))}s+=2+u}return t(new Blob)})),r.readAsArrayBuffer(e)}));var nr={},H1={get exports(){return nr},set exports(e){nr=e}};(function(e){var t,n,r={};H1.exports=r,r.parse=function(i,a){for(var s=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=s(l,u+=4);s(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 A=o(l,u+=4),v=s(l,u+=4),I=s(l,u+2),T=s(l,u+4);u+=6;var C=o(l,u+=8);u+=4,u+=v+I+T,r._readLocal(l,C,d,h,A,a)}return d},r._readLocal=function(i,a,s,o,u,d){var l=r.bin.readUshort,c=r.bin.readUint;c(i,a),l(i,a+=4),l(i,a+=2);var f=l(i,a+=2);c(i,a+=2),c(i,a+=4),a+=4;var h=l(i,a+=8),m=l(i,a+=2);a+=2;var b=r.bin.readUTF8(i,a,h);if(a+=h,a+=m,d)s[b]={size:u,csize:o};else{var A=new Uint8Array(i.buffer,a);if(f==0)s[b]=new Uint8Array(A.buffer.slice(a,a+o));else{if(f!=8)throw"unknown compression method: "+f;var v=new Uint8Array(u);r.inflateRaw(A,v),s[b]=v}}},r.inflateRaw=function(i,a){return r.F.inflate(i,a)},r.inflate=function(i,a){return i[0],i[1],r.inflateRaw(new Uint8Array(i.buffer,i.byteOffset+2,i.length-6),a)},r.deflate=function(i,a){a==null&&(a={level:6});var s=0,o=new Uint8Array(50+Math.floor(1.1*i.length));o[s]=120,o[s+1]=156,s+=2,s=r.F.deflateRaw(i,o,s,a.level);var u=r.adler(i,0,i.length);return o[s+0]=u>>>24&255,o[s+1]=u>>>16&255,o[s+2]=u>>>8&255,o[s+3]=u>>>0&255,new Uint8Array(o.buffer,0,s+4)},r.deflateRaw=function(i,a){a==null&&(a={level:6});var s=new Uint8Array(50+Math.floor(1.1*i.length)),o=r.F.deflateRaw(i,s,o,a.level);return new Uint8Array(s.buffer,0,o)},r.encode=function(i,a){a==null&&(a=!1);var s=0,o=r.bin.writeUint,u=r.bin.writeUshort,d={};for(var l in i){var c=!r._noNeed(l)&&!a,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)s+=d[l].file.length+30+46+2*r.bin.sizeUTF8(l);s+=22;var m=new Uint8Array(s),b=0,A=[];for(var l in d){var v=d[l];A.push(b),b=r._writeHeader(m,b,l,v,0)}var I=0,T=b;for(var l in d)v=d[l],A.push(b),b=r._writeHeader(m,b,l,v,1,A[I++]);var C=b-T;return o(m,b,101010256),b+=4,u(m,b+=4,I),u(m,b+=2,I),o(m,b+=2,C),o(m,b+=4,T),b+=4,b+=2,m.buffer},r._noNeed=function(i){var a=i.split(".").pop().toLowerCase();return"png,jpg,jpeg,zip".indexOf(a)!=-1},r._writeHeader=function(i,a,s,o,u,d){var l=r.bin.writeUint,c=r.bin.writeUshort,f=o.file;return l(i,a,u==0?67324752:33639248),a+=4,u==1&&(a+=2),c(i,a,20),c(i,a+=2,0),c(i,a+=2,o.cpr?8:0),l(i,a+=2,0),l(i,a+=4,o.crc),l(i,a+=4,f.length),l(i,a+=4,o.usize),c(i,a+=4,r.bin.sizeUTF8(s)),c(i,a+=2,0),a+=2,u==1&&(a+=2,a+=2,l(i,a+=6,d),a+=4),a+=r.bin.writeUTF8(i,a,s),u==0&&(i.set(f,a),a+=f.length),a},r.crc={table:(function(){for(var i=new Uint32Array(256),a=0;a<256;a++){for(var s=a,o=0;o<8;o++)1&s?s=3988292384^s>>>1:s>>>=1;i[a]=s}return i})(),update:function(i,a,s,o){for(var u=0;u<o;u++)i=r.crc.table[255&(i^a[s+u])]^i>>>8;return i},crc:function(i,a,s){return 4294967295^r.crc.update(4294967295,i,a,s)}},r.adler=function(i,a,s){for(var o=1,u=0,d=a,l=a+s;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,a){return i[a]|i[a+1]<<8},writeUshort:function(i,a,s){i[a]=255&s,i[a+1]=s>>8&255},readUint:function(i,a){return 16777216*i[a+3]+(i[a+2]<<16|i[a+1]<<8|i[a])},writeUint:function(i,a,s){i[a]=255&s,i[a+1]=s>>8&255,i[a+2]=s>>16&255,i[a+3]=s>>24&255},readASCII:function(i,a,s){for(var o="",u=0;u<s;u++)o+=String.fromCharCode(i[a+u]);return o},writeASCII:function(i,a,s){for(var o=0;o<s.length;o++)i[a+o]=s.charCodeAt(o)},pad:function(i){return i.length<2?"0"+i:i},readUTF8:function(i,a,s){for(var o,u="",d=0;d<s;d++)u+="%"+r.bin.pad(i[a+d].toString(16));try{o=decodeURIComponent(u)}catch{return r.bin.readASCII(i,a,s)}return o},writeUTF8:function(i,a,s){for(var o=s.length,u=0,d=0;d<o;d++){var l=s.charCodeAt(d);if((4294967168&l)==0)i[a+u]=l,u++;else if((4294965248&l)==0)i[a+u]=192|l>>6,i[a+u+1]=128|l>>0&63,u+=2;else if((4294901760&l)==0)i[a+u]=224|l>>12,i[a+u+1]=128|l>>6&63,i[a+u+2]=128|l>>0&63,u+=3;else{if((4292870144&l)!=0)throw"e";i[a+u]=240|l>>18,i[a+u+1]=128|l>>12&63,i[a+u+2]=128|l>>6&63,i[a+u+3]=128|l>>0&63,u+=4}}return u},sizeUTF8:function(i){for(var a=i.length,s=0,o=0;o<a;o++){var u=i.charCodeAt(o);if((4294967168&u)==0)s++;else if((4294965248&u)==0)s+=2;else if((4294901760&u)==0)s+=3;else{if((4292870144&u)!=0)throw"e";s+=4}}return s}},r.F={},r.F.deflateRaw=function(i,a,s,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=s<<3,m=0,b=i.length;if(o==0){for(;f<b;)c(a,h,f+(D=Math.min(65535,b-f))==b?1:0),h=r.F._copyExact(i,f,D,a,h+8),f+=D;return h>>>3}var A=d.lits,v=d.strt,I=d.prev,T=0,C=0,P=0,w=0,L=0,p=0;for(b>2&&(v[p=r.F._hash(i,0)]=0),f=0;f<b;f++){if(L=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){(T>14e3||C>26697)&&b-f>100&&(m<f&&(A[T]=f-m,T+=2,m=f),h=r.F._writeBlock(f==b-1||m==b?1:0,A,T,w,i,P,f-P,a,h),T=C=w=0,P=f);var S=0;f<b-2&&(S=r.F._bestMatch(i,f,I,L,Math.min(u[2],b-f),u[3]));var D=S>>>16,j=65535&S;if(S!=0){j=65535&S;var F=l(D=S>>>16,d.of0);d.lhst[257+F]++;var E=l(j,d.df0);d.dhst[E]++,w+=d.exb[F]+d.dxb[E],A[T]=D<<23|f-m,A[T+1]=j<<16|F<<8|E,T+=2,m=f+D}else d.lhst[i[f]]++;C++}}for(P==f&&i.length!=0||(m<f&&(A[T]=f-m,T+=2,m=f),h=r.F._writeBlock(1,A,T,w,i,P,f-P,a,h),T=0,C=0,T=C=w=0,P=f);(7&h)!=0;)h++;return h>>>3},r.F._bestMatch=function(i,a,s,o,u,d){var l=32767&a,c=s[l],f=l-c+32768&32767;if(c==l||o!=r.F._hash(i,a-f))return 0;for(var h=0,m=0,b=Math.min(32767,a);f<=b&&--d!=0&&c!=l;){if(h==0||i[a+h]==i[a+h-f]){var A=r.F._howLong(i,a,f);if(A>h){if(m=f,(h=A)>=u)break;f+2<A&&(A=f+2);for(var v=0,I=0;I<A-2;I++){var T=a-f+I+32768&32767,C=T-s[T]+32768&32767;C>v&&(v=C,c=T)}}}f+=(l=c)-(c=s[l])+32768&32767}return h<<16|m},r.F._howLong=function(i,a,s){if(i[a]!=i[a-s]||i[a+1]!=i[a+1-s]||i[a+2]!=i[a+2-s])return 0;var o=a,u=Math.min(i.length,a+258);for(a+=3;a<u&&i[a]==i[a-s];)a++;return a-o},r.F._hash=function(i,a){return(i[a]<<8|i[a+1])+(i[a+2]<<4)&65535},r.saved=0,r.F._writeBlock=function(i,a,s,o,u,d,l,c,f){var h,m,b,A,v,I,T,C,P,w=r.F.U,L=r.F._putsF,p=r.F._putsE;w.lhst[256]++,m=(h=r.F.getTrees())[0],b=h[1],A=h[2],v=h[3],I=h[4],T=h[5],C=h[6],P=h[7];var y=32+((f+3&7)==0?0:8-(f+3&7))+(l<<3),S=o+r.F.contSize(w.fltree,w.lhst)+r.F.contSize(w.fdtree,w.dhst),D=o+r.F.contSize(w.ltree,w.lhst)+r.F.contSize(w.dtree,w.dhst);D+=14+3*T+r.F.contSize(w.itree,w.ihst)+(2*w.ihst[16]+3*w.ihst[17]+7*w.ihst[18]);for(var j=0;j<286;j++)w.lhst[j]=0;for(j=0;j<30;j++)w.dhst[j]=0;for(j=0;j<19;j++)w.ihst[j]=0;var F=y<S&&y<D?0:S<D?1:2;if(L(c,f,i),L(c,f+1,F),f+=3,F==0){for(;(7&f)!=0;)f++;f=r.F._copyExact(u,d,l,c,f)}else{var E,R;if(F==1&&(E=w.fltree,R=w.fdtree),F==2){r.F.makeCodes(w.ltree,m),r.F.revCodes(w.ltree,m),r.F.makeCodes(w.dtree,b),r.F.revCodes(w.dtree,b),r.F.makeCodes(w.itree,A),r.F.revCodes(w.itree,A),E=w.ltree,R=w.dtree,p(c,f,v-257),p(c,f+=5,I-1),p(c,f+=5,T-4),f+=4;for(var x=0;x<T;x++)p(c,f+3*x,w.itree[1+(w.ordr[x]<<1)]);f+=3*T,f=r.F._codeTiny(C,w.itree,c,f),f=r.F._codeTiny(P,w.itree,c,f)}for(var g=d,V=0;V<s;V+=2){for(var O=a[V],U=O>>>23,N=g+(8388607&O);g<N;)f=r.F._writeLit(u[g++],E,c,f);if(U!=0){var _=a[V+1],W=_>>16,$=_>>8&255,M=255&_;p(c,f=r.F._writeLit(257+$,E,c,f),U-w.of0[$]),f+=w.exb[$],L(c,f=r.F._writeLit(M,R,c,f),W-w.df0[M]),f+=w.dxb[M],g+=U}}f=r.F._writeLit(256,E,c,f)}return f},r.F._copyExact=function(i,a,s,o,u){var d=u>>>3;return o[d]=s,o[d+1]=s>>>8,o[d+2]=255-o[d],o[d+3]=255-o[d+1],d+=4,o.set(new Uint8Array(i.buffer,a,s),d),u+(s+4<<3)},r.F.getTrees=function(){for(var i=r.F.U,a=r.F._hufTree(i.lhst,i.ltree,15),s=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[a,s,f,u,l,h,o,d]},r.F.getSecond=function(i){for(var a=[],s=0;s<i.length;s+=2)a.push(i[s+1]);return a},r.F.nonZero=function(i){for(var a="",s=0;s<i.length;s+=2)i[s+1]!=0&&(a+=(s>>1)+",");return a},r.F.contSize=function(i,a){for(var s=0,o=0;o<a.length;o++)s+=a[o]*i[1+(o<<1)];return s},r.F._codeTiny=function(i,a,s,o){for(var u=0;u<i.length;u+=2){var d=i[u],l=i[u+1];o=r.F._writeLit(d,a,s,o);var c=d==16?2:d==17?3:7;d>15&&(r.F._putsE(s,o,l,c),o+=c)}return o},r.F._lenCodes=function(i,a){for(var s=i.length;s!=2&&i[s-1]==0;)s-=2;for(var o=0;o<s;o+=2){var u=i[o+1],d=o+3<s?i[o+3]:-1,l=o+5<s?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<s&&i[f+2]==u;)f+=2;(h=Math.min(f+1-o>>>1,138))<11?a.push(17,h-3):a.push(18,h-11),o+=2*h-2}else if(u==c&&d==u&&l==u){for(f=o+5;f+2<s&&i[f+2]==u;)f+=2;var h=Math.min(f+1-o>>>1,6);a.push(16,h-3),o+=2*h-2}else a.push(u,0)}return s>>>1},r.F._hufTree=function(i,a,s){var o=[],u=i.length,d=a.length,l=0;for(l=0;l<d;l+=2)a[l]=0,a[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,a[1+(h<<1)]=1,a[1+(f<<1)]=1,1}o.sort((function(C,P){return C.f-P.f}));var m=o[0],b=o[1],A=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=A!=v&&(I==c||o[A].f<o[I].f)?o[A++]:o[I++],b=A!=v&&(I==c||o[A].f<o[I].f)?o[A++]:o[I++],o[v++]={lit:-1,f:m.f+b.f,l:m,r:b};var T=r.F.setDepth(o[v-1],0);for(T>s&&(r.F.restrictDepth(f,s,T),T=s),l=0;l<c;l++)a[1+(f[l].lit<<1)]=f[l].d;return T},r.F.setDepth=function(i,a){return i.lit!=-1?(i.d=a,a):Math.max(r.F.setDepth(i.l,a+1),r.F.setDepth(i.r,a+1))},r.F.restrictDepth=function(i,a,s){var o=0,u=1<<s-a,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>a;o++){var l=i[o].d;i[o].d=a,d+=u-(1<<s-l)}for(d>>>=s-a;d>0;)(l=i[o].d)<a?(i[o].d++,d-=1<<a-l-1):o++;for(;o>=0;o--)i[o].d==a&&d<0&&(i[o].d--,d++);d!=0&&console.log("debt left")},r.F._goodIndex=function(i,a){var s=0;return a[16|s]<=i&&(s|=16),a[8|s]<=i&&(s|=8),a[4|s]<=i&&(s|=4),a[2|s]<=i&&(s|=2),a[1|s]<=i&&(s|=1),s},r.F._writeLit=function(i,a,s,o){return r.F._putsF(s,o,a[i<<1]),o+a[1+(i<<1)]},r.F.inflate=function(i,a){var s=Uint8Array;if(i[0]==3&&i[1]==0)return a||new s(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=a==null;b&&(a=new s(i.length>>>2<<3));for(var A,v,I=0,T=0,C=0,P=0,w=0,L=0,p=0,y=0,S=0;I==0;)if(I=u(i,S,1),T=u(i,S+1,2),S+=3,T!=0){if(b&&(a=r.F._check(a,y+(1<<17))),T==1&&(A=m.flmap,v=m.fdmap,L=511,p=31),T==2){C=d(i,S,5)+257,P=d(i,S+5,5)+1,w=d(i,S+10,4)+4,S+=14;for(var D=0;D<38;D+=2)m.itree[D]=0,m.itree[D+1]=0;var j=1;for(D=0;D<w;D++){var F=d(i,S+3*D,3);m.itree[1+(m.ordr[D]<<1)]=F,F>j&&(j=F)}S+=3*w,c(m.itree,j),f(m.itree,j,m.imap),A=m.lmap,v=m.dmap,S=l(m.imap,(1<<j)-1,C+P,i,S,m.ttree);var E=o._copyOut(m.ttree,0,C,m.ltree);L=(1<<E)-1;var R=o._copyOut(m.ttree,C,P,m.dtree);p=(1<<R)-1,c(m.ltree,E),f(m.ltree,E,A),c(m.dtree,R),f(m.dtree,R,v)}for(;;){var x=A[h(i,S)&L];S+=15&x;var g=x>>>4;if(!(g>>>8))a[y++]=g;else{if(g==256)break;var V=y+g-254;if(g>264){var O=m.ldef[g-257];V=y+(O>>>3)+d(i,S,7&O),S+=7&O}var U=v[h(i,S)&p];S+=15&U;var N=U>>>4,_=m.ddef[N],W=(_>>>4)+u(i,S,15&_);for(S+=15&_,b&&(a=r.F._check(a,y+(1<<17)));y<V;)a[y]=a[y++-W],a[y]=a[y++-W],a[y]=a[y++-W],a[y]=a[y++-W];y=V}}}else{(7&S)!=0&&(S+=8-(7&S));var $=4+(S>>>3),M=i[$-4]|i[$-3]<<8;b&&(a=r.F._check(a,y+M)),a.set(new s(i.buffer,i.byteOffset+$,M),y),S=$+M<<3,y+=M}return a.length==y?a:a.slice(0,y)},r.F._check=function(i,a){var s=i.length;if(a<=s)return i;var o=new Uint8Array(Math.max(s<<1,a));return o.set(i,0),o},r.F._decodeTiny=function(i,a,s,o,u,d){for(var l=r.F._bitsE,c=r.F._get17,f=0;f<s;){var h=i[c(o,u)&a];u+=15&h;var m=h>>>4;if(m<=15)d[f]=m,f++;else{var b=0,A=0;m==16?(A=3+l(o,u,2),u+=2,b=d[f-1]):m==17?(A=3+l(o,u,3),u+=3):m==18&&(A=11+l(o,u,7),u+=7);for(var v=f+A;f<v;)d[f]=b,f++}}return u},r.F._copyOut=function(i,a,s,o){for(var u=0,d=0,l=o.length>>>1;d<s;){var c=i[d+a];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,a){for(var s,o,u,d,l=r.F.U,c=i.length,f=l.bl_count,h=0;h<=a;h++)f[h]=0;for(h=1;h<c;h+=2)f[i[h]]++;var m=l.next_code;for(s=0,f[0]=0,o=1;o<=a;o++)s=s+f[o-1]<<1,m[o]=s;for(u=0;u<c;u+=2)(d=i[u+1])!=0&&(i[u]=m[d],m[d]++)},r.F.codes2map=function(i,a,s){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=a-c,m=i[d]<<h,b=m+(1<<h);m!=b;)s[u[m]>>>15-a]=f,m++},r.F.revCodes=function(i,a){for(var s=r.F.U.rev15,o=15-a,u=0;u<i.length;u+=2){var d=i[u]<<a-i[u+1];i[u]=s[d]>>>o}},r.F._putsE=function(i,a,s){s<<=7&a;var o=a>>>3;i[o]|=s,i[o+1]|=s>>>8},r.F._putsF=function(i,a,s){s<<=7&a;var o=a>>>3;i[o]|=s,i[o+1]|=s>>>8,i[o+2]|=s>>>16},r.F._bitsE=function(i,a,s){return(i[a>>>3]|i[1+(a>>>3)]<<8)>>>(7&a)&(1<<s)-1},r.F._bitsF=function(i,a,s){return(i[a>>>3]|i[1+(a>>>3)]<<8|i[2+(a>>>3)]<<16)>>>(7&a)&(1<<s)-1},r.F._get17=function(i,a){return(i[a>>>3]|i[1+(a>>>3)]<<8|i[2+(a>>>3)]<<16)>>>(7&a)},r.F._get25=function(i,a){return(i[a>>>3]|i[1+(a>>>3)]<<8|i[2+(a>>>3)]<<16|i[3+(a>>>3)]<<24)>>>(7&a)},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,a=0;a<32768;a++){var s=a;s=(4278255360&(s=(4042322160&(s=(3435973836&(s=(2863311530&s)>>>1|(1431655765&s)<<1))>>>2|(858993459&s)<<2))>>>4|(252645135&s)<<4))>>>8|(16711935&s)<<8,i.rev15[a]=(s>>>16|s<<16)>>>17}function o(u,d,l){for(;d--!=0;)u.push(0,l)}for(a=0;a<32;a++)i.ldef[a]=i.of0[a]<<3|i.exb[a],i.ddef[a]=i.df0[a]<<4|i.dxb[a];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 Y1=B1({__proto__:null,default:nr},[nr]);const Ue=(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=a(h),A=Math.ceil(c*b/8),v=new Uint8Array(4*m),I=new Uint32Array(v.buffer),{ctype:T}=h,{depth:C}=h,P=e.readUshort;if(T==6){const O=m<<2;if(C==8)for(var w=0;w<O;w+=4)v[w]=l[w],v[w+1]=l[w+1],v[w+2]=l[w+2],v[w+3]=l[w+3];if(C==16)for(w=0;w<O;w++)v[w]=l[w<<1]}else if(T==2){const O=h.tabs.tRNS;if(O==null){if(C==8)for(w=0;w<m;w++){var L=3*w;I[w]=255<<24|l[L+2]<<16|l[L+1]<<8|l[L]}if(C==16)for(w=0;w<m;w++)L=6*w,I[w]=255<<24|l[L+4]<<16|l[L+2]<<8|l[L]}else{var p=O[0];const U=O[1],N=O[2];if(C==8)for(w=0;w<m;w++){var y=w<<2;L=3*w,I[w]=255<<24|l[L+2]<<16|l[L+1]<<8|l[L],l[L]==p&&l[L+1]==U&&l[L+2]==N&&(v[y+3]=0)}if(C==16)for(w=0;w<m;w++)y=w<<2,L=6*w,I[w]=255<<24|l[L+4]<<16|l[L+2]<<8|l[L],P(l,L)==p&&P(l,L+2)==U&&P(l,L+4)==N&&(v[y+3]=0)}}else if(T==3){const O=h.tabs.PLTE,U=h.tabs.tRNS,N=U?U.length:0;if(C==1)for(var S=0;S<f;S++){var D=S*A,j=S*c;for(w=0;w<c;w++){y=j+w<<2;var F=3*(E=l[D+(w>>3)]>>7-((7&w)<<0)&1);v[y]=O[F],v[y+1]=O[F+1],v[y+2]=O[F+2],v[y+3]=E<N?U[E]:255}}if(C==2)for(S=0;S<f;S++)for(D=S*A,j=S*c,w=0;w<c;w++)y=j+w<<2,F=3*(E=l[D+(w>>2)]>>6-((3&w)<<1)&3),v[y]=O[F],v[y+1]=O[F+1],v[y+2]=O[F+2],v[y+3]=E<N?U[E]:255;if(C==4)for(S=0;S<f;S++)for(D=S*A,j=S*c,w=0;w<c;w++)y=j+w<<2,F=3*(E=l[D+(w>>1)]>>4-((1&w)<<2)&15),v[y]=O[F],v[y+1]=O[F+1],v[y+2]=O[F+2],v[y+3]=E<N?U[E]:255;if(C==8)for(w=0;w<m;w++){var E;y=w<<2,F=3*(E=l[w]),v[y]=O[F],v[y+1]=O[F+1],v[y+2]=O[F+2],v[y+3]=E<N?U[E]:255}}else if(T==4){if(C==8)for(w=0;w<m;w++){y=w<<2;var R=l[x=w<<1];v[y]=R,v[y+1]=R,v[y+2]=R,v[y+3]=l[x+1]}if(C==16)for(w=0;w<m;w++){var x;y=w<<2,R=l[x=w<<2],v[y]=R,v[y+1]=R,v[y+2]=R,v[y+3]=l[x+2]}}else if(T==0)for(p=h.tabs.tRNS?h.tabs.tRNS:-1,S=0;S<f;S++){const O=S*A,U=S*c;if(C==1)for(var g=0;g<c;g++){var V=(R=255*(l[O+(g>>>3)]>>>7-(7&g)&1))==255*p?0:255;I[U+g]=V<<24|R<<16|R<<8|R}else if(C==2)for(g=0;g<c;g++)V=(R=85*(l[O+(g>>>2)]>>>6-((3&g)<<1)&3))==85*p?0:255,I[U+g]=V<<24|R<<16|R<<8|R;else if(C==4)for(g=0;g<c;g++)V=(R=17*(l[O+(g>>>1)]>>>4-((1&g)<<2)&15))==17*p?0:255,I[U+g]=V<<24|R<<16|R<<8|R;else if(C==8)for(g=0;g<c;g++)V=(R=l[O+g])==p?0:255,I[U+g]=V<<24|R<<16|R<<8|R;else if(C==16)for(g=0;g<c;g++)R=l[O+(g<<1)],V=P(l,O+(g<<1))==p?0:255,I[U+g]=V<<24|R<<16|R<<8|R}return v}function n(l,c,f,h){const m=a(l),b=Math.ceil(f*m/8),A=new Uint8Array((b+1+l.interlace)*h);return c=l.tabs.CgBI?i(c,A):r(c,A),l.interlace==0?c=s(c,l,0,f,h):l.interlace==1&&(c=(function(I,T){const C=T.width,P=T.height,w=a(T),L=w>>3,p=Math.ceil(C*w/8),y=new Uint8Array(P*p);let S=0;const D=[0,0,4,0,2,0,1],j=[0,4,0,2,0,1,0],F=[8,8,8,4,4,2,2],E=[8,8,4,4,2,2,1];let R=0;for(;R<7;){const g=F[R],V=E[R];let O=0,U=0,N=D[R];for(;N<P;)N+=g,U++;let _=j[R];for(;_<C;)_+=V,O++;const W=Math.ceil(O*w/8);s(I,T,S,O,U);let $=0,M=D[R];for(;M<P;){let H=j[R],B=S+$*W<<3;for(;H<C;){var x;if(w==1&&(x=(x=I[B>>3])>>7-(7&B)&1,y[M*p+(H>>3)]|=x<<7-((7&H)<<0)),w==2&&(x=(x=I[B>>3])>>6-(7&B)&3,y[M*p+(H>>2)]|=x<<6-((3&H)<<1)),w==4&&(x=(x=I[B>>3])>>4-(7&B)&15,y[M*p+(H>>1)]|=x<<4-((1&H)<<2)),w>=8){const G=M*p+H*L;for(let Q=0;Q<L;Q++)y[G+Q]=I[(B>>3)+Q]}B+=w,H+=V}$++,M+=g}O*U!=0&&(S+=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,A=0,v=0,I=0,T=0,C=0,P=0,w=0,L=0,p=0;if(c[0]==3&&c[1]==0)return f||new h(0);const y=l.H,S=y.b,D=y.e,j=y.R,F=y.n,E=y.A,R=y.Z,x=y.m,g=f==null;for(g&&(f=new h(c.length>>>2<<5));A==0;)if(A=S(c,p,1),v=S(c,p+1,2),p+=3,v!=0){if(g&&(f=l.H.W(f,L+(1<<17))),v==1&&(m=x.J,b=x.h,P=511,w=31),v==2){I=D(c,p,5)+257,T=D(c,p+5,5)+1,C=D(c,p+10,4)+4,p+=14;let O=1;for(var V=0;V<38;V+=2)x.Q[V]=0,x.Q[V+1]=0;for(V=0;V<C;V++){const _=D(c,p+3*V,3);x.Q[1+(x.X[V]<<1)]=_,_>O&&(O=_)}p+=3*C,F(x.Q,O),E(x.Q,O,x.u),m=x.w,b=x.d,p=j(x.u,(1<<O)-1,I+T,c,p,x.v);const U=y.V(x.v,0,I,x.C);P=(1<<U)-1;const N=y.V(x.v,I,T,x.D);w=(1<<N)-1,F(x.C,U),E(x.C,U,m),F(x.D,N),E(x.D,N,b)}for(;;){const O=m[R(c,p)&P];p+=15&O;const U=O>>>4;if(!(U>>>8))f[L++]=U;else{if(U==256)break;{let N=L+U-254;if(U>264){const H=x.q[U-257];N=L+(H>>>3)+D(c,p,7&H),p+=7&H}const _=b[R(c,p)&w];p+=15&_;const W=_>>>4,$=x.c[W],M=($>>>4)+S(c,p,15&$);for(p+=15&$;L<N;)f[L]=f[L++-M],f[L]=f[L++-M],f[L]=f[L++-M],f[L]=f[L++-M];L=N}}}}else{(7&p)!=0&&(p+=8-(7&p));const O=4+(p>>>3),U=c[O-4]|c[O-3]<<8;g&&(f=l.H.W(f,L+U)),f.set(new h(c.buffer,c.byteOffset+O,U),L),p=O+U<<3,L+=U}return f.length==L?f:f.slice(0,L)},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,A){const v=l.H.e,I=l.H.Z;let T=0;for(;T<h;){const C=c[I(m,b)&f];b+=15&C;const P=C>>>4;if(P<=15)A[T]=P,T++;else{let w=0,L=0;P==16?(L=3+v(m,b,2),b+=2,w=A[T-1]):P==17?(L=3+v(m,b,3),b+=3):P==18&&(L=11+v(m,b,7),b+=7);const p=T+L;for(;T<p;)A[T]=w,T++}}return b},l.H.V=function(c,f,h,m){let b=0,A=0;const v=m.length>>>1;for(;A<h;){const I=c[A+f];m[A<<1]=0,m[1+(A<<1)]=I,I>b&&(b=I),A++}for(;A<v;)m[A<<1]=0,m[1+(A<<1)]=0,A++;return b},l.H.n=function(c,f){const h=l.H.m,m=c.length;let b,A,v,I;const T=h.j;for(var C=0;C<=f;C++)T[C]=0;for(C=1;C<m;C+=2)T[c[C]]++;const P=h.K;for(b=0,T[0]=0,A=1;A<=f;A++)b=b+T[A-1]<<1,P[A]=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 A=0;A<m;A+=2)if(c[A+1]!=0){const v=A>>1,I=c[A+1],T=v<<4|I,C=f-I;let P=c[A]<<C;const w=P+(1<<C);for(;P!=w;)h[b[P]>>>15-f]=T,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 A=c[b]<<f-c[b+1];c[b]=h[A]>>>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,A){for(;b--!=0;)m.push(0,A)}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 a(l){return[1,null,3,1,2,null,4][l.ctype]*l.depth}function s(l,c,f,h,m){let b=a(c);const A=Math.ceil(h*b/8);let v,I;b=Math.ceil(b/8);let T=l[f],C=0;if(T>1&&(l[f]=[0,0,1][T-2]),T==3)for(C=b;C<A;C++)l[C+1]=l[C+1]+(l[C+1-b]>>>1)&255;for(let P=0;P<m;P++)if(v=f+P*A,I=v+P+1,T=l[I-1],C=0,T==0)for(;C<A;C++)l[v+C]=l[I+C];else if(T==1){for(;C<b;C++)l[v+C]=l[I+C];for(;C<A;C++)l[v+C]=l[I+C]+l[v+C-b]}else if(T==2)for(;C<A;C++)l[v+C]=l[I+C]+l[v+C-A];else if(T==3){for(;C<b;C++)l[v+C]=l[I+C]+(l[v+C-A]>>>1);for(;C<A;C++)l[v+C]=l[I+C]+(l[v+C-A]+l[v+C-b]>>>1)}else{for(;C<b;C++)l[v+C]=l[I+C]+o(0,l[v+C-A],0);for(;C<A;C++)l[v+C]=l[I+C]+o(l[v+C-b],l[v+C-A],l[v+C-b-A])}return l}function o(l,c,f){const h=l+c-f,m=h-l,b=h-c,A=h-f;return m*m<=b*b&&m*m<=A*A?l:b*b<=A*A?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,A,v,I){const T=Math.min(c,m),C=Math.min(f,b);let P=0,w=0;for(let R=0;R<C;R++)for(let x=0;x<T;x++)if(A>=0&&v>=0?(P=R*c+x<<2,w=(v+R)*m+A+x<<2):(P=(-v+R)*c-A+x<<2,w=R*m+x<<2),I==0)h[w]=l[P],h[w+1]=l[P+1],h[w+2]=l[P+2],h[w+3]=l[P+3];else if(I==1){var L=l[P+3]*.00392156862745098,p=l[P]*L,y=l[P+1]*L,S=l[P+2]*L,D=h[w+3]*(1/255),j=h[w]*D,F=h[w+1]*D,E=h[w+2]*D;const g=1-L,V=L+D*g,O=V==0?0:1/V;h[w+3]=255*V,h[w+0]=(p+j*g)*O,h[w+1]=(y+F*g)*O,h[w+2]=(S+E*g)*O}else if(I==2)L=l[P+3],p=l[P],y=l[P+1],S=l[P+2],D=h[w+3],j=h[w],F=h[w+1],E=h[w+2],L==D&&p==j&&y==F&&S==E?(h[w]=0,h[w+1]=0,h[w+2]=0,h[w+3]=0):(h[w]=p,h[w+1]=y,h[w+2]=S,h[w+3]=L);else if(I==3){if(L=l[P+3],p=l[P],y=l[P+1],S=l[P+2],D=h[w+3],j=h[w],F=h[w+1],E=h[w+2],L==D&&p==j&&y==F&&S==E)continue;if(L<220&&D>20)return!1}return!0}return{decode:function(c){const f=new Uint8Array(c);let h=8;const m=e,b=m.readUshort,A=m.readUint,v={tabs:{},frames:[]},I=new Uint8Array(f.length);let T,C=0,P=0;const w=[137,80,78,71,13,10,26,10];for(var L=0;L<8;L++)if(f[L]!=w[L])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 V=null;try{V=r(g)}catch{V=i(g)}v.tabs[x]=V}else if(x=="CgBI")v.tabs[x]=f.slice(h,h+4);else if(x=="IDAT"){for(L=0;L<R;L++)I[C+L]=f[h+L];C+=R}else if(x=="acTL")v.tabs[x]={num_frames:A(f,h),num_plays:A(f,h+4)},T=new Uint8Array(f.length);else if(x=="fcTL"){P!=0&&((E=v.frames[v.frames.length-1]).data=n(v,T.slice(0,P),E.rect.width,E.rect.height),P=0);const g={x:A(f,h+12),y:A(f,h+16),width:A(f,h+4),height:A(f,h+8)};let V=b(f,h+22);V=b(f,h+20)/(V==0?100:V);const O={rect:g,delay:Math.round(1e3*V),dispose:f[h+24],blend:f[h+25]};v.frames.push(O)}else if(x=="fdAT"){for(L=0;L<R-4;L++)T[P+L]=f[h+L+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]=[],L=0;L<8;L++)v.tabs[x].push(m.readUint(f,h+4*L));else if(x=="tEXt"||x=="zTXt"){v.tabs[x]==null&&(v.tabs[x]={});var y=m.nextZero(f,h),S=m.readASCII(f,h,y-h),D=h+R-y-1;if(x=="tEXt")F=m.readASCII(f,y+1,D);else{var j=r(f.slice(y+2,y+2+D));F=m.readUTF8(j,0,j.length)}v.tabs[x][S]=F}else if(x=="iTXt"){v.tabs[x]==null&&(v.tabs[x]={}),y=0,p=h,y=m.nextZero(f,p),S=m.readASCII(f,p,y-p);const g=f[p=y+1];var F;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),D=R-((p=y+1)-h),g==0?F=m.readUTF8(f,p,D):(j=r(f.slice(p,p+D)),F=m.readUTF8(j,0,j.length)),v.tabs[x][S]=F}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]=[],L=0;L<g;L++)v.tabs[x].push(b(f,h+2*L))}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 E;return P!=0&&((E=v.frames[v.frames.length-1]).data=n(v,T.slice(0,P),E.rect.width,E.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,A=new Uint8Array(b),v=new Uint8Array(b),I=new Uint8Array(b);for(let C=0;C<c.frames.length;C++){const P=c.frames[C],w=P.rect.x,L=P.rect.y,p=P.rect.width,y=P.rect.height,S=t(P.data,p,y,c);if(C!=0)for(var T=0;T<b;T++)I[T]=A[T];if(P.blend==0?d(S,p,y,A,f,h,w,L,0):P.blend==1&&d(S,p,y,A,f,h,w,L,1),m.push(A.buffer.slice(0)),P.dispose!=0){if(P.dispose==1)d(v,p,y,A,f,h,w,L,0);else if(P.dispose==2)for(T=0;T<b;T++)A[T]=I[T]}}return m},_paeth:o,_copyTile:d,_bin:e}})();(function(){const{_copyTile:e}=Ue,{_bin:t}=Ue,n=Ue._paeth;var r={table:(function(){const p=new Uint32Array(256);for(let y=0;y<256;y++){let S=y;for(let D=0;D<8;D++)1&S?S=3988292384^S>>>1:S>>>=1;p[y]=S}return p})(),update(p,y,S,D){for(let j=0;j<D;j++)p=r.table[255&(p^y[S+j])]^p>>>8;return p},crc:(p,y,S)=>4294967295^r.update(4294967295,p,y,S)};function i(p,y,S,D){y[S]+=p[0]*D>>4,y[S+1]+=p[1]*D>>4,y[S+2]+=p[2]*D>>4,y[S+3]+=p[3]*D>>4}function a(p){return Math.max(0,Math.min(255,p))}function s(p,y){const S=p[0]-y[0],D=p[1]-y[1],j=p[2]-y[2],F=p[3]-y[3];return S*S+D*D+j*j+F*F}function o(p,y,S,D,j,F,E){E==null&&(E=1);const R=D.length,x=[];for(var g=0;g<R;g++){const M=D[g];x.push([M>>>0&255,M>>>8&255,M>>>16&255,M>>>24&255])}for(g=0;g<R;g++){let M=4294967295;for(var V=0,O=0;O<R;O++){var U=s(x[g],x[O]);O!=g&&U<M&&(M=U,V=O)}}const N=new Uint32Array(j.buffer),_=new Int16Array(y*S*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 M=0;M<S;M++)for(let H=0;H<y;H++){var $;g=4*(M*y+H),E!=2?$=[a(p[g]+_[g]),a(p[g+1]+_[g+1]),a(p[g+2]+_[g+2]),a(p[g+3]+_[g+3])]:(U=W[4*(3&M)+(3&H)],$=[a(p[g]+U),a(p[g+1]+U),a(p[g+2]+U),a(p[g+3]+U)]),V=0;let B=16777215;for(O=0;O<R;O++){const J=s($,x[O]);J<B&&(B=J,V=O)}const G=x[V],Q=[$[0]-G[0],$[1]-G[1],$[2]-G[2],$[3]-G[3]];E==1&&(H!=y-1&&i(Q,_,g+4,7),M!=S-1&&(H!=0&&i(Q,_,g+4*y-4,3),i(Q,_,g+4*y,5),H!=y-1&&i(Q,_,g+4*y+4,1))),F[g>>2]=V,N[g>>2]=D[V]}}function u(p,y,S,D,j){j==null&&(j={});const{crc:F}=r,E=t.writeUint,R=t.writeUshort,x=t.writeASCII;let g=8;const V=p.frames.length>1;let O,U=!1,N=33+(V?20:0);if(j.sRGB!=null&&(N+=13),j.pHYs!=null&&(N+=21),j.iCCP!=null&&(O=pako.deflate(j.iCCP),N+=21+O.length+4),p.ctype==3){for(var _=p.plte.length,W=0;W<_;W++)p.plte[W]>>>24!=255&&(U=!0);N+=8+3*_+4+(U?8+1*_+4:0)}for(var $=0;$<p.frames.length;$++)V&&(N+=38),N+=(G=p.frames[$]).cimg.length+12,$!=0&&(N+=4);N+=12;const M=new Uint8Array(N),H=[137,80,78,71,13,10,26,10];for(W=0;W<8;W++)M[W]=H[W];if(E(M,g,13),g+=4,x(M,g,"IHDR"),g+=4,E(M,g,y),g+=4,E(M,g,S),g+=4,M[g]=p.depth,g++,M[g]=p.ctype,g++,M[g]=0,g++,M[g]=0,g++,M[g]=0,g++,E(M,g,F(M,g-17,17)),g+=4,j.sRGB!=null&&(E(M,g,1),g+=4,x(M,g,"sRGB"),g+=4,M[g]=j.sRGB,g++,E(M,g,F(M,g-5,5)),g+=4),j.iCCP!=null){const Q=13+O.length;E(M,g,Q),g+=4,x(M,g,"iCCP"),g+=4,x(M,g,"ICC profile"),g+=11,g+=2,M.set(O,g),g+=O.length,E(M,g,F(M,g-(Q+4),Q+4)),g+=4}if(j.pHYs!=null&&(E(M,g,9),g+=4,x(M,g,"pHYs"),g+=4,E(M,g,j.pHYs[0]),g+=4,E(M,g,j.pHYs[1]),g+=4,M[g]=j.pHYs[2],g++,E(M,g,F(M,g-13,13)),g+=4),V&&(E(M,g,8),g+=4,x(M,g,"acTL"),g+=4,E(M,g,p.frames.length),g+=4,E(M,g,j.loop!=null?j.loop:0),g+=4,E(M,g,F(M,g-12,12)),g+=4),p.ctype==3){for(E(M,g,3*(_=p.plte.length)),g+=4,x(M,g,"PLTE"),g+=4,W=0;W<_;W++){const Q=3*W,J=p.plte[W],le=255&J,he=J>>>8&255,At=J>>>16&255;M[g+Q+0]=le,M[g+Q+1]=he,M[g+Q+2]=At}if(g+=3*_,E(M,g,F(M,g-3*_-4,3*_+4)),g+=4,U){for(E(M,g,_),g+=4,x(M,g,"tRNS"),g+=4,W=0;W<_;W++)M[g+W]=p.plte[W]>>>24&255;g+=_,E(M,g,F(M,g-_-4,_+4)),g+=4}}let B=0;for($=0;$<p.frames.length;$++){var G=p.frames[$];V&&(E(M,g,26),g+=4,x(M,g,"fcTL"),g+=4,E(M,g,B++),g+=4,E(M,g,G.rect.width),g+=4,E(M,g,G.rect.height),g+=4,E(M,g,G.rect.x),g+=4,E(M,g,G.rect.y),g+=4,R(M,g,D[$]),g+=2,R(M,g,1e3),g+=2,M[g]=G.dispose,g++,M[g]=G.blend,g++,E(M,g,F(M,g-30,30)),g+=4);const Q=G.cimg;E(M,g,(_=Q.length)+($==0?0:4)),g+=4;const J=g;x(M,g,$==0?"IDAT":"fdAT"),g+=4,$!=0&&(E(M,g,B++),g+=4),M.set(Q,g),g+=_,E(M,g,F(M,J,g-J)),g+=4}return E(M,g,0),g+=4,x(M,g,"IEND"),g+=4,E(M,g,F(M,g-4,4)),g+=4,M.buffer}function d(p,y,S){for(let D=0;D<p.frames.length;D++){const j=p.frames[D];j.rect.width;const F=j.rect.height,E=new Uint8Array(F*j.bpl+F);j.cimg=h(j.img,F,j.bpp,j.bpl,E,y,S)}}function l(p,y,S,D,j){const F=j[0],E=j[1],R=j[2],x=j[3],g=j[4],V=j[5];let O=6,U=8,N=255;for(var _=0;_<p.length;_++){const be=new Uint8Array(p[_]);for(var W=be.length,$=0;$<W;$+=4)N&=be[$+3]}const M=N!=255,H=(function(ie,te,ge,Se,ce,Me){const fe=[];for(var ne=0;ne<ie.length;ne++){const Te=new Uint8Array(ie[ne]),$e=new Uint32Array(Te.buffer);var De;let Ne=0,tt=0,Ye=te,Tt=ge,ca=Se?1:0;if(ne!=0){const Dy=Me||Se||ne==1||fe[ne-2].dispose!=0?1:2;let fa=0,gc=1e9;for(let wn=0;wn<Dy;wn++){var ut=new Uint8Array(ie[ne-1-wn]);const Iy=new Uint32Array(ie[ne-1-wn]);let ct=te,ft=ge,Gt=-1,An=-1;for(let Pt=0;Pt<ge;Pt++)for(let Et=0;Et<te;Et++)$e[xe=Pt*te+Et]!=Iy[xe]&&(Et<ct&&(ct=Et),Et>Gt&&(Gt=Et),Pt<ft&&(ft=Pt),Pt>An&&(An=Pt));Gt==-1&&(ct=ft=Gt=An=0),ce&&((1&ct)==1&&ct--,(1&ft)==1&&ft--);const yc=(Gt-ct+1)*(An-ft+1);yc<gc&&(gc=yc,fa=wn,Ne=ct,tt=ft,Ye=Gt-ct+1,Tt=An-ft+1)}ut=new Uint8Array(ie[ne-1-fa]),fa==1&&(fe[ne-1].dispose=2),De=new Uint8Array(Ye*Tt*4),e(ut,te,ge,De,Ye,Tt,-Ne,-tt,0),ca=e(Te,te,ge,De,Ye,Tt,-Ne,-tt,3)?1:0,ca==1?f(Te,te,ge,De,{x:Ne,y:tt,width:Ye,height:Tt}):e(Te,te,ge,De,Ye,Tt,-Ne,-tt,0)}else De=Te.slice(0);fe.push({rect:{x:Ne,y:tt,width:Ye,height:Tt},img:De,blend:ca,dispose:0})}if(Se)for(ne=0;ne<fe.length;ne++){if((St=fe[ne]).blend==1)continue;const Te=St.rect,$e=fe[ne-1].rect,Ne=Math.min(Te.x,$e.x),tt=Math.min(Te.y,$e.y),Ye={x:Ne,y:tt,width:Math.max(Te.x+Te.width,$e.x+$e.width)-Ne,height:Math.max(Te.y+Te.height,$e.y+$e.height)-tt};fe[ne-1].dispose=1,ne-1!=0&&c(ie,te,ge,fe,ne-1,Ye,ce),c(ie,te,ge,fe,ne,Ye,ce)}let lr=0;if(ie.length!=1)for(var xe=0;xe<fe.length;xe++){var St;lr+=(St=fe[xe]).rect.width*St.rect.height}return fe})(p,y,S,F,E,R),B={},G=[],Q=[];if(D!=0){const be=[];for($=0;$<H.length;$++)be.push(H[$].img.buffer);const ie=(function(ce){let Me=0;for(var fe=0;fe<ce.length;fe++)Me+=ce[fe].byteLength;const ne=new Uint8Array(Me);let De=0;for(fe=0;fe<ce.length;fe++){const ut=new Uint8Array(ce[fe]),lr=ut.length;for(let xe=0;xe<lr;xe+=4){let St=ut[xe],Te=ut[xe+1],$e=ut[xe+2];const Ne=ut[xe+3];Ne==0&&(St=Te=$e=0),ne[De+xe]=St,ne[De+xe+1]=Te,ne[De+xe+2]=$e,ne[De+xe+3]=Ne}De+=lr}return ne.buffer})(be),te=b(ie,D);for($=0;$<te.plte.length;$++)G.push(te.plte[$].est.rgba);let ge=0;for($=0;$<H.length;$++){const Se=(le=H[$]).img.length;var J=new Uint8Array(te.inds.buffer,ge>>2,Se>>2);Q.push(J);const ce=new Uint8Array(te.abuf,ge,Se);V&&o(le.img,le.rect.width,le.rect.height,G,ce,J),le.img.set(ce),ge+=Se}}else for(_=0;_<H.length;_++){var le=H[_];const be=new Uint32Array(le.img.buffer);var he=le.rect.width;for(W=be.length,J=new Uint8Array(W),Q.push(J),$=0;$<W;$++){const ie=be[$];if($!=0&&ie==be[$-1])J[$]=J[$-1];else if($>he&&ie==be[$-he])J[$]=J[$-he];else{let te=B[ie];if(te==null&&(B[ie]=te=G.length,G.push(ie),G.length>=300))break;J[$]=te}}}const At=G.length;for(At<=256&&g==0&&(U=At<=2?1:At<=4?2:At<=16?4:8,U=Math.max(U,x)),_=0;_<H.length;_++){(le=H[_]).rect.x,le.rect.y,he=le.rect.width;const be=le.rect.height;let ie=le.img;new Uint32Array(ie.buffer);let te=4*he,ge=4;if(At<=256&&g==0){te=Math.ceil(U*he/8);var He=new Uint8Array(te*be);const Se=Q[_];for(let ce=0;ce<be;ce++){$=ce*te;const Me=ce*he;if(U==8)for(var oe=0;oe<he;oe++)He[$+oe]=Se[Me+oe];else if(U==4)for(oe=0;oe<he;oe++)He[$+(oe>>1)]|=Se[Me+oe]<<4-4*(1&oe);else if(U==2)for(oe=0;oe<he;oe++)He[$+(oe>>2)]|=Se[Me+oe]<<6-2*(3&oe);else if(U==1)for(oe=0;oe<he;oe++)He[$+(oe>>3)]|=Se[Me+oe]<<7-1*(7&oe)}ie=He,O=3,ge=1}else if(M==0&&H.length==1){He=new Uint8Array(he*be*3);const Se=he*be;for($=0;$<Se;$++){const ce=3*$,Me=4*$;He[ce]=ie[Me],He[ce+1]=ie[Me+1],He[ce+2]=ie[Me+2]}ie=He,O=2,ge=3,te=3*he}le.img=ie,le.bpl=te,le.bpp=ge}return{ctype:O,depth:U,plte:G,frames:H}}function c(p,y,S,D,j,F,E){const R=Uint8Array,x=Uint32Array,g=new R(p[j-1]),V=new x(p[j-1]),O=j+1<p.length?new R(p[j+1]):null,U=new R(p[j]),N=new x(U.buffer);let _=y,W=S,$=-1,M=-1;for(let B=0;B<F.height;B++)for(let G=0;G<F.width;G++){const Q=F.x+G,J=F.y+B,le=J*y+Q,he=N[le];he==0||D[j-1].dispose==0&&V[le]==he&&(O==null||O[4*le+3]!=0)||(Q<_&&(_=Q),Q>$&&($=Q),J<W&&(W=J),J>M&&(M=J))}$==-1&&(_=W=$=M=0),E&&((1&_)==1&&_--,(1&W)==1&&W--),F={x:_,y:W,width:$-_+1,height:M-W+1};const H=D[j];H.rect=F,H.blend=1,H.img=new Uint8Array(F.width*F.height*4),D[j-1].dispose==0?(e(g,y,S,H.img,F.width,F.height,-F.x,-F.y,0),f(U,y,S,H.img,F)):e(U,y,S,H.img,F.width,F.height,-F.x,-F.y,0)}function f(p,y,S,D,j){e(p,y,S,D,j.width,j.height,-j.x,-j.y,2)}function h(p,y,S,D,j,F,E){const R=[];let x,g=[0,1,2,3,4];F!=-1?g=[F]:(y*D>5e5||S==1)&&(g=[0]),E&&(x={level:0});const V=Y1;for(var O=0;O<g.length;O++){for(let _=0;_<y;_++)m(j,p,_,D,S,g[O]);R.push(V.deflate(j,x))}let U,N=1e9;for(O=0;O<R.length;O++)R[O].length<N&&(U=O,N=R[O].length);return R[U]}function m(p,y,S,D,j,F){const E=S*D;let R=E+S;if(p[R]=F,R++,F==0)if(D<500)for(var x=0;x<D;x++)p[R+x]=y[E+x];else p.set(new Uint8Array(y.buffer,E,D),R);else if(F==1){for(x=0;x<j;x++)p[R+x]=y[E+x];for(x=j;x<D;x++)p[R+x]=y[E+x]-y[E+x-j]+256&255}else if(S==0){for(x=0;x<j;x++)p[R+x]=y[E+x];if(F==2)for(x=j;x<D;x++)p[R+x]=y[E+x];if(F==3)for(x=j;x<D;x++)p[R+x]=y[E+x]-(y[E+x-j]>>1)+256&255;if(F==4)for(x=j;x<D;x++)p[R+x]=y[E+x]-n(y[E+x-j],0,0)+256&255}else{if(F==2)for(x=0;x<D;x++)p[R+x]=y[E+x]+256-y[E+x-D]&255;if(F==3){for(x=0;x<j;x++)p[R+x]=y[E+x]+256-(y[E+x-D]>>1)&255;for(x=j;x<D;x++)p[R+x]=y[E+x]+256-(y[E+x-D]+y[E+x-j]>>1)&255}if(F==4){for(x=0;x<j;x++)p[R+x]=y[E+x]+256-n(0,y[E+x-D],0)&255;for(x=j;x<D;x++)p[R+x]=y[E+x]+256-n(y[E+x-j],y[E+x-D],y[E+x-j-D])&255}}}function b(p,y){const S=new Uint8Array(p),D=S.slice(0),j=new Uint32Array(D.buffer),F=A(D,y),E=F[0],R=F[1],x=S.length,g=new Uint8Array(x>>2);let V;if(S.length<2e7)for(var O=0;O<x;O+=4)V=v(E,U=S[O]*(1/255),N=S[O+1]*(1/255),_=S[O+2]*(1/255),W=S[O+3]*(1/255)),g[O>>2]=V.ind,j[O>>2]=V.est.rgba;else for(O=0;O<x;O+=4){var U=S[O]*.00392156862745098,N=S[O+1]*(1/255),_=S[O+2]*(1/255),W=S[O+3]*(1/255);for(V=E;V.left;)V=I(V.est,U,N,_,W)<=0?V.left:V.right;g[O>>2]=V.ind,j[O>>2]=V.est.rgba}return{abuf:D.buffer,inds:g,plte:R}}function A(p,y,S){S==null&&(S=1e-4);const D=new Uint32Array(p.buffer),j={i0:0,i1:p.length,bst:null,est:null,tdst:0,left:null,right:null};j.bst=P(p,j.i0,j.i1),j.est=w(j.bst);const F=[j];for(;F.length<y;){let R=0,x=0;for(var E=0;E<F.length;E++)F[E].est.L>R&&(R=F[E].est.L,x=E);if(R<S)break;const g=F[x],V=T(p,D,g.i0,g.i1,g.est.e,g.est.eMq255);if(g.i0>=V||g.i1<=V){g.est.L=0;continue}const O={i0:g.i0,i1:V,bst:null,est:null,tdst:0,left:null,right:null};O.bst=P(p,O.i0,O.i1),O.est=w(O.bst);const U={i0:V,i1:g.i1,bst:null,est:null,tdst:0,left:null,right:null};for(U.bst={R:[],m:[],N:g.bst.N-O.bst.N},E=0;E<16;E++)U.bst.R[E]=g.bst.R[E]-O.bst.R[E];for(E=0;E<4;E++)U.bst.m[E]=g.bst.m[E]-O.bst.m[E];U.est=w(U.bst),g.left=O,g.right=U,F[x]=O,F.push(U)}for(F.sort(((R,x)=>x.bst.N-R.bst.N)),E=0;E<F.length;E++)F[E].ind=E;return[j,F]}function v(p,y,S,D,j){if(p.left==null)return p.tdst=(function(O,U,N,_,W){const $=U-O[0],M=N-O[1],H=_-O[2],B=W-O[3];return $*$+M*M+H*H+B*B})(p.est.q,y,S,D,j),p;const F=I(p.est,y,S,D,j);let E=p.left,R=p.right;F>0&&(E=p.right,R=p.left);const x=v(E,y,S,D,j);if(x.tdst<=F*F)return x;const g=v(R,y,S,D,j);return g.tdst<x.tdst?g:x}function I(p,y,S,D,j){const{e:F}=p;return F[0]*y+F[1]*S+F[2]*D+F[3]*j-p.eMq}function T(p,y,S,D,j,F){for(D-=4;S<D;){for(;C(p,S,j)<=F;)S+=4;for(;C(p,D,j)>F;)D-=4;if(S>=D)break;const E=y[S>>2];y[S>>2]=y[D>>2],y[D>>2]=E,S+=4,D-=4}for(;C(p,S,j)>F;)S-=4;return S+4}function C(p,y,S){return p[y]*S[0]+p[y+1]*S[1]+p[y+2]*S[2]+p[y+3]*S[3]}function P(p,y,S){const D=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],j=[0,0,0,0],F=S-y>>2;for(let E=y;E<S;E+=4){const R=p[E]*.00392156862745098,x=p[E+1]*(1/255),g=p[E+2]*(1/255),V=p[E+3]*(1/255);j[0]+=R,j[1]+=x,j[2]+=g,j[3]+=V,D[0]+=R*R,D[1]+=R*x,D[2]+=R*g,D[3]+=R*V,D[5]+=x*x,D[6]+=x*g,D[7]+=x*V,D[10]+=g*g,D[11]+=g*V,D[15]+=V*V}return D[4]=D[1],D[8]=D[2],D[9]=D[6],D[12]=D[3],D[13]=D[7],D[14]=D[11],{R:D,m:j,N:F}}function w(p){const{R:y}=p,{m:S}=p,{N:D}=p,j=S[0],F=S[1],E=S[2],R=S[3],x=D==0?0:1/D,g=[y[0]-j*j*x,y[1]-j*F*x,y[2]-j*E*x,y[3]-j*R*x,y[4]-F*j*x,y[5]-F*F*x,y[6]-F*E*x,y[7]-F*R*x,y[8]-E*j*x,y[9]-E*F*x,y[10]-E*E*x,y[11]-E*R*x,y[12]-R*j*x,y[13]-R*F*x,y[14]-R*E*x,y[15]-R*R*x],V=g,O=L;let U=[Math.random(),Math.random(),Math.random(),Math.random()],N=0,_=0;if(D!=0)for(let $=0;$<16&&(U=O.multVec(V,U),_=Math.sqrt(O.dot(U,U)),U=O.sml(1/_,U),!($!=0&&Math.abs(_-N)<1e-9));$++)N=_;const W=[j*x,F*x,E*x,R*x];return{Cov:g,q:W,e:U,L:N,eMq255:O.dot(O.sml(255,W),U),eMq:O.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 L={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]]};Ue.encode=function(y,S,D,j,F,E,R){j==null&&(j=0),R==null&&(R=!1);const x=l(y,S,D,j,[!1,!1,!1,0,R,!1]);return d(x,-1),u(x,S,D,F,E)},Ue.encodeLL=function(y,S,D,j,F,E,R,x){const g={ctype:0+(j==1?0:2)+(F==0?0:4),depth:E,frames:[]},V=(j+F)*E,O=V*S;for(let U=0;U<y.length;U++)g.frames.push({rect:{x:0,y:0,width:S,height:D},img:new Uint8Array(y[U]),blend:0,dispose:1,bpp:Math.ceil(V/8),bpl:Math.ceil(O/8)});return d(g,0,!0),u(g,S,D,R,x)},Ue.encode.compress=l,Ue.encode.dither=o,Ue.quantize=b,Ue.quantize.getKDtree=A,Ue.quantize.getNearest=v})();const qu={toArrayBuffer(e,t){const n=e.width,r=e.height,i=n<<2,a=e.getContext("2d").getImageData(0,0,n,r),s=new Uint32Array(a.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,A,v=f,I=0,T=0,C=0;function P(p){c.setUint16(T,p,!0),T+=2}function w(p){c.setUint32(T,p,!0),T+=4}function L(p){T+=p}P(19778),w(d),L(4),w(122),w(108),w(n),w(-r>>>0),P(1),P(32),w(3),w(u),w(2835),w(2835),L(8),w(16711680),w(65280),w(255),w(4278190080),w(1466527264),(function p(){for(;I<r&&v>0;){for(A=122+I*o,h=0;h<i;)v--,m=s[C++],b=m>>>24,c.setUint32(A+h,m<<8|b),h+=4;I++}C<s.length?(v=f,setTimeout(p,qu._dly)):t(l)})()},toBlob(e,t){this.toArrayBuffer(e,(n=>{t(new Blob([n],{type:"image/bmp"}))}))},_dly:9};var Ee={CHROME:"CHROME",FIREFOX:"FIREFOX",DESKTOP_SAFARI:"DESKTOP_SAFARI",IE:"IE",IOS:"IOS",ETC:"ETC"},G1={[Ee.CHROME]:16384,[Ee.FIREFOX]:11180,[Ee.DESKTOP_SAFARI]:16384,[Ee.IE]:8192,[Ee.IOS]:4096,[Ee.ETC]:8192};const sa=typeof window<"u",Qu=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,rr=sa&&window.cordova&&window.cordova.require&&window.cordova.require("cordova/modulemapper"),K1=(sa||Qu)&&(rr&&rr.getOriginalSymbol(window,"File")||typeof File<"u"&&File),Zu=(sa||Qu)&&(rr&&rr.getOriginalSymbol(window,"FileReader")||typeof FileReader<"u"&&FileReader);function oa(e,t,n=Date.now()){return new Promise((r=>{const i=e.split(","),a=i[0].match(/:(.*?);/)[1],s=globalThis.atob(i[1]);let o=s.length;const u=new Uint8Array(o);for(;o--;)u[o]=s.charCodeAt(o);const d=new Blob([u],{type:a});d.name=t,d.lastModified=n,r(d)}))}function Ju(e){return new Promise(((t,n)=>{const r=new Zu;r.onload=()=>t(r.result),r.onerror=i=>n(i),r.readAsDataURL(e)}))}function ec(e){return new Promise(((t,n)=>{const r=new Image;r.onload=()=>t(r),r.onerror=i=>n(i),r.src=e}))}function wt(){if(wt.cachedResult!==void 0)return wt.cachedResult;let e=Ee.ETC;const{userAgent:t}=navigator;return/Chrom(e|ium)/i.test(t)?e=Ee.CHROME:/iP(ad|od|hone)/i.test(t)&&/WebKit/i.test(t)?e=Ee.IOS:/Safari/i.test(t)?e=Ee.DESKTOP_SAFARI:/Firefox/i.test(t)?e=Ee.FIREFOX:(/MSIE/i.test(t)||document.documentMode)&&(e=Ee.IE),wt.cachedResult=e,wt.cachedResult}function tc(e,t){const n=wt(),r=G1[n];let i=e,a=t,s=i*a;const o=i>a?a/i:i/a;for(;s>r*r;){const u=(r+i)/2,d=(r+a)/2;u<d?(a=d,i=d*o):(a=u*o,i=u),s=i*a}return{width:i,height:a}}function ir(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 nc(e,t){const{width:n,height:r}=tc(e.width,e.height),[i,a]=ir(n,r);return t&&/jpe?g/.test(t)&&(a.fillStyle="white",a.fillRect(0,0,i.width,i.height)),a.drawImage(e,0,0,i.width,i.height),i}function ar(){return ar.cachedResult!==void 0||(ar.cachedResult=["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)||navigator.userAgent.includes("Mac")&&typeof document<"u"&&"ontouchend"in document),ar.cachedResult}function sr(e,t={}){return new Promise((function(n,r){let i,a;var s=function(){try{return a=nc(i,t.fileType||e.type),n([i,a])}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 Ju(e).then((function(c){try{return l=c,ec(l).then((function(f){try{return i=f,(function(){try{return s()}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(ar()||[Ee.DESKTOP_SAFARI,Ee.MOBILE_SAFARI].includes(wt()))throw new Error("Skip createImageBitmap on IOS and Safari");return createImageBitmap(e).then((function(u){try{return i=u,s()}catch{return o()}}),o)}catch{o()}}))}function or(e,t,n,r,i=1){return new Promise((function(a,s){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=Ue.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=>qu.toBlob(e,l))).then((function(l){try{return o=l,o.name=n,o.lastModified=r,d.call(this)}catch(c){return s(c)}}).bind(this),s);{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 s(f)}}).bind(this),s);{let c;return c=e.toDataURL(t,i),oa(c,n,r).then((function(f){try{return o=f,l.call(this)}catch(h){return s(h)}}).bind(this),s)}}}function u(){return a(o)}}))}function We(e){e.width=0,e.height=0}function Yt(){return new Promise((function(e,t){let n,r,i,a;return Yt.cachedResult!==void 0?e(Yt.cachedResult):oa("data:image/jpeg;base64,/9j/4QAiRXhpZgAATU0AKgAAAAgAAQESAAMAAAABAAYAAAAAAAD/2wCEAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAf/AABEIAAEAAgMBEQACEQEDEQH/xABKAAEAAAAAAAAAAAAAAAAAAAALEAEAAAAAAAAAAAAAAAAAAAAAAQEAAAAAAAAAAAAAAAAAAAAAEQEAAAAAAAAAAAAAAAAAAAAA/9oADAMBAAIRAxEAPwA/8H//2Q==","test.jpg",Date.now()).then((function(s){try{return n=s,sr(n).then((function(o){try{return r=o[1],or(r,n.type,n.name,n.lastModified).then((function(u){try{return i=u,We(r),sr(i).then((function(d){try{return a=d[0],Yt.cachedResult=a.width===1&&a.height===2,e(Yt.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 rc(e){return new Promise(((t,n)=>{const r=new Zu;r.onload=i=>{const a=new DataView(i.target.result);if(a.getUint16(0,!1)!=65496)return t(-2);const s=a.byteLength;let o=2;for(;o<s;){if(a.getUint16(o+2,!1)<=8)return t(-1);const u=a.getUint16(o,!1);if(o+=2,u==65505){if(a.getUint32(o+=2,!1)!=1165519206)return t(-1);const d=a.getUint16(o+=6,!1)==18761;o+=a.getUint32(o+4,d);const l=a.getUint16(o,d);o+=2;for(let c=0;c<l;c++)if(a.getUint16(o+12*c,d)==274)return t(a.getUint16(o+12*c+8,d))}else{if((65280&u)!=65280)break;o+=a.getUint16(o,!1)}}return t(-1)},r.onerror=i=>n(i),r.readAsArrayBuffer(e)}))}function ic(e,t){const{width:n}=e,{height:r}=e,{maxWidthOrHeight:i}=t;let a,s=e;return isFinite(i)&&(n>i||r>i)&&([s,a]=ir(n,r),n>r?(s.width=i,s.height=r/n*i):(s.width=n/r*i,s.height=i),a.drawImage(e,0,0,s.width,s.height),We(e)),s}function ac(e,t){const{width:n}=e,{height:r}=e,[i,a]=ir(n,r);switch(t>4&&t<9?(i.width=r,i.height=n):(i.width=n,i.height=r),t){case 2:a.transform(-1,0,0,1,n,0);break;case 3:a.transform(-1,0,0,-1,n,r);break;case 4:a.transform(1,0,0,-1,0,r);break;case 5:a.transform(0,1,1,0,0,0);break;case 6:a.transform(0,1,-1,0,r,0);break;case 7:a.transform(0,-1,-1,0,r,n);break;case 8:a.transform(0,-1,1,0,0,n)}return a.drawImage(e,0,0,n,r),We(e),i}function sc(e,t,n=0){return new Promise((function(r,i){let a,s,o,u,d,l,c,f,h,m,b,A,v,I,T,C,P,w,L,p;function y(D=5){if(t.signal&&t.signal.aborted)throw t.signal.reason;a+=D,t.onProgress(Math.min(a,100))}function S(D){if(t.signal&&t.signal.aborted)throw t.signal.reason;a=Math.min(Math.max(D,a),100),t.onProgress(a)}return a=n,s=t.maxIteration||10,o=1024*t.maxSizeMB*1024,y(),sr(e,t).then((function(D){try{return[,u]=D,y(),d=ic(u,t),y(),new Promise((function(j,F){var E;if(!(E=t.exifOrientation))return rc(e).then((function(x){try{return E=x,R.call(this)}catch(g){return F(g)}}).bind(this),F);function R(){return j(E)}return R.call(this)})).then((function(j){try{return l=j,y(),Yt().then((function(F){try{return c=F?d:ac(d,l),y(),f=t.initialQuality||1,h=t.fileType||e.type,or(c,h,e.name,e.lastModified,f).then((function(E){try{{let x=function(){if(s--&&(T>o||T>v)){let V,O;return V=p?.95*L.width:L.width,O=p?.95*L.height:L.height,[P,w]=ir(V,O),w.drawImage(L,0,0,V,O),f*=h==="image/png"?.85:.95,or(P,h,e.name,e.lastModified,f).then((function(U){try{return C=U,We(L),L=P,T=C.size,S(Math.min(99,Math.floor((I-T)/(I-o)*100))),x}catch(N){return i(N)}}),i)}return[1]},g=function(){return We(L),We(P),We(d),We(c),We(u),S(100),r(C)};if(m=E,y(),b=m.size>o,A=m.size>e.size,!b&&!A)return S(100),r(m);var R;return v=e.size,I=m.size,T=I,L=c,p=!t.alwaysKeepResolution&&b,(R=(function(V){for(;V;){if(V.then)return void V.then(R,i);try{if(V.pop){if(V.length)return V.pop()?g.call(this):V;V=x}else V=V.call(this)}catch(O){return i(O)}}}).bind(this))(x)}}catch(x){return i(x)}}).bind(this),i)}catch(E){return i(E)}}).bind(this),i)}catch(F){return i(F)}}).bind(this),i)}catch(j){return i(j)}}).bind(this),i)}))}const X1=`
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(A){return C1.includes(A)});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 k1=(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={},I1=Object.keys(Ht);function M1(e,t){var n=t.mixoutsTo;return Au=e,Wt={},Object.keys(Ht).forEach(function(r){I1.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 k1,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}}}},Ie={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&&Ie.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(" "),A={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"]&&(A.attributes["aria-hidden"]="true"),c&&(A.attributes[xt]="");var v=$($({},A),{},{prefix:i,iconName:s,main:n,mask:r,maskId:u,transform:a,symbol:o,styles:$({},d.styles)}),k=r.found&&n.found?ct("generateAbstractMask",v)||{children:[],attributes:{}}:ct("generateAbstractIcon",v)||{children:[],attributes:{}},S=k.children,E=k.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 ku(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(ku(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(ku(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 Iu(e){e()}function Mu(e,t){var n=typeof t=="function"?t:tr;if(e.length===0)n();else{var r=Iu;K.mutateApproach===q0&&(r=lt.requestAnimationFrame||Iu),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,A=b===void 0?{}:b;if(t){var v=t.prefix,k=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:k,transform:$($({},He),i),symbol:a,maskId:l,extra:{attributes:m,styles:A,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],A=m[1];c([n,Zi({icons:{main:b,mask:A},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(w){return w.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"),A=cg(o),v=Xi(h,m),k=v;if(b){var S=w1(m);S.iconName&&S.prefix&&(v=S.iconName,h=S.prefix)}if(v&&!A&&(!a||a.getAttribute(Ri)!==h||a.getAttribute(_i)!==k)){e.setAttribute(n,k),a&&e.removeChild(a);var E=Z1(),P=E.extra;P.attributes[Oi]=t,ts(v,h).then(function(w){var O=Zi($($({},E),{},{icons:{main:w,mask:bu()},prefix:h,iconName:k,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(`
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,A){var v=$t(n).filter(hg).map(dg),k=rs.begin("searchPseudoElements");Du(),Promise.all(v).then(function(){k(),ss(),b()}).catch(function(){k(),ss(),A()})})}}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)}:{},A={tag:"g",attributes:$({},h.inner),children:[$u($({tag:l.tag,attributes:$($({},l.attributes),h.path)},b))]},v={tag:"g",attributes:$({},h.outer),children:[A]},k="mask-".concat(o||nu()),S="clip-".concat(o||nu()),E={tag:"mask",attributes:$($({},os),{},{id:k,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(k,")")},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:Ie}),Ie.noAuto;var bn=Ie.config,Tg=Ie.library;Ie.dom;var Wu=Ie.parse;Ie.findIconDefinition,Ie.toHtml;var Pg=Ie.icon;Ie.layer,Ie.text,Ie.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,kg=1e3;function Ig(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===kg){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=Ig(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:A,swapOpacity:v,rotateBy:k,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]),A!=null&&P.push(Lg[A]),v&&P.push(nt.swapOpacity),Fg?(k&&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),A=Pg(f,{...h.length>0&&{classes:h},...m&&{transform:m},...b&&{mask:b},symbol:s,title:a,titleId:c,maskId:l});if(!A)return Xu.error("Could not find icon",f),null;const{abstract:v}=A,k={ref:t};for(const S of Ug(n))Bg.has(S)||(k[S]=n[S]);return Mg(v[0],k)});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(A=>!A)}),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:A=>i(A.target.value)}),"x",D.jsx("input",{style:h,type:"number",value:s,onChange:A=>a(A.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((A,v)=>D.jsx("div",{style:{display:"flex",gap:"0.25rem"},children:[...Array(c)].map((k,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 A=o(l,u+=4),v=a(l,u+=4),k=a(l,u+2),S=a(l,u+4);u+=6;var E=o(l,u+=8);u+=4,u+=v+k+S,r._readLocal(l,E,d,h,A,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 A=new Uint8Array(i.buffer,s);if(f==0)a[b]=new Uint8Array(A.buffer.slice(s,s+o));else{if(f!=8)throw"unknown compression method: "+f;var v=new Uint8Array(u);r.inflateRaw(A,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,A=[];for(var l in d){var v=d[l];A.push(b),b=r._writeHeader(m,b,l,v,0)}var k=0,S=b;for(var l in d)v=d[l],A.push(b),b=r._writeHeader(m,b,l,v,1,A[k++]);var E=b-S;return o(m,b,101010256),b+=4,u(m,b+=4,k),u(m,b+=2,k),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+(I=Math.min(65535,b-f))==b?1:0),h=r.F._copyExact(i,f,I,s,h+8),f+=I;return h>>>3}var A=d.lits,v=d.strt,k=d.prev,S=0,E=0,P=0,w=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;k[y]=v[p],v[p]=y}if(m<=f){(S>14e3||E>26697)&&b-f>100&&(m<f&&(A[S]=f-m,S+=2,m=f),h=r.F._writeBlock(f==b-1||m==b?1:0,A,S,w,i,P,f-P,s,h),S=E=w=0,P=f);var T=0;f<b-2&&(T=r.F._bestMatch(i,f,k,O,Math.min(u[2],b-f),u[3]));var I=T>>>16,M=65535&T;if(T!=0){M=65535&T;var j=l(I=T>>>16,d.of0);d.lhst[257+j]++;var C=l(M,d.df0);d.dhst[C]++,w+=d.exb[j]+d.dxb[C],A[S]=I<<23|f-m,A[S+1]=M<<16|j<<8|C,S+=2,m=f+I}else d.lhst[i[f]]++;E++}}for(P==f&&i.length!=0||(m<f&&(A[S]=f-m,S+=2,m=f),h=r.F._writeBlock(1,A,S,w,i,P,f-P,s,h),S=0,E=0,S=E=w=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 A=r.F._howLong(i,s,f);if(A>h){if(m=f,(h=A)>=u)break;f+2<A&&(A=f+2);for(var v=0,k=0;k<A-2;k++){var S=s-f+k+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,A,v,k,S,E,P,w=r.F.U,O=r.F._putsF,p=r.F._putsE;w.lhst[256]++,m=(h=r.F.getTrees())[0],b=h[1],A=h[2],v=h[3],k=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(w.fltree,w.lhst)+r.F.contSize(w.fdtree,w.dhst),I=o+r.F.contSize(w.ltree,w.lhst)+r.F.contSize(w.dtree,w.dhst);I+=14+3*S+r.F.contSize(w.itree,w.ihst)+(2*w.ihst[16]+3*w.ihst[17]+7*w.ihst[18]);for(var M=0;M<286;M++)w.lhst[M]=0;for(M=0;M<30;M++)w.dhst[M]=0;for(M=0;M<19;M++)w.ihst[M]=0;var j=y<T&&y<I?0:T<I?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=w.fltree,R=w.fdtree),j==2){r.F.makeCodes(w.ltree,m),r.F.revCodes(w.ltree,m),r.F.makeCodes(w.dtree,b),r.F.revCodes(w.dtree,b),r.F.makeCodes(w.itree,A),r.F.revCodes(w.itree,A),C=w.ltree,R=w.dtree,p(c,f,v-257),p(c,f+=5,k-1),p(c,f+=5,S-4),f+=4;for(var x=0;x<S;x++)p(c,f+3*x,w.itree[1+(w.ordr[x]<<1)]);f+=3*S,f=r.F._codeTiny(E,w.itree,c,f),f=r.F._codeTiny(P,w.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-w.of0[B]),f+=w.exb[B],O(c,f=r.F._writeLit(V,R,c,f),W-w.df0[V]),f+=w.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],A=0,v=1,k=2;for(o[0]={lit:-1,f:m.f+b.f,l:m,r:b,d:0};v!=c-1;)m=A!=v&&(k==c||o[A].f<o[k].f)?o[A++]:o[k++],b=A!=v&&(k==c||o[A].f<o[k].f)?o[A++]:o[k++],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 A,v,k=0,S=0,E=0,P=0,w=0,O=0,p=0,y=0,T=0;k==0;)if(k=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&&(A=m.flmap,v=m.fdmap,O=511,p=31),S==2){E=d(i,T,5)+257,P=d(i,T+5,5)+1,w=d(i,T+10,4)+4,T+=14;for(var I=0;I<38;I+=2)m.itree[I]=0,m.itree[I+1]=0;var M=1;for(I=0;I<w;I++){var j=d(i,T+3*I,3);m.itree[1+(m.ordr[I]<<1)]=j,j>M&&(M=j)}T+=3*w,c(m.itree,M),f(m.itree,M,m.imap),A=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,A),c(m.dtree,R),f(m.dtree,R,v)}for(;;){var x=A[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,A=0;m==16?(A=3+l(o,u,2),u+=2,b=d[f-1]):m==17?(A=3+l(o,u,3),u+=3):m==18&&(A=11+l(o,u,7),u+=7);for(var v=f+A;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),A=Math.ceil(c*b/8),v=new Uint8Array(4*m),k=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 w=0;w<L;w+=4)v[w]=l[w],v[w+1]=l[w+1],v[w+2]=l[w+2],v[w+3]=l[w+3];if(E==16)for(w=0;w<L;w++)v[w]=l[w<<1]}else if(S==2){const L=h.tabs.tRNS;if(L==null){if(E==8)for(w=0;w<m;w++){var O=3*w;k[w]=255<<24|l[O+2]<<16|l[O+1]<<8|l[O]}if(E==16)for(w=0;w<m;w++)O=6*w,k[w]=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(w=0;w<m;w++){var y=w<<2;O=3*w,k[w]=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(w=0;w<m;w++)y=w<<2,O=6*w,k[w]=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 I=T*A,M=T*c;for(w=0;w<c;w++){y=M+w<<2;var j=3*(C=l[I+(w>>3)]>>7-((7&w)<<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(I=T*A,M=T*c,w=0;w<c;w++)y=M+w<<2,j=3*(C=l[I+(w>>2)]>>6-((3&w)<<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(I=T*A,M=T*c,w=0;w<c;w++)y=M+w<<2,j=3*(C=l[I+(w>>1)]>>4-((1&w)<<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(w=0;w<m;w++){var C;y=w<<2,j=3*(C=l[w]),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(w=0;w<m;w++){y=w<<2;var R=l[x=w<<1];v[y]=R,v[y+1]=R,v[y+2]=R,v[y+3]=l[x+1]}if(E==16)for(w=0;w<m;w++){var x;y=w<<2,R=l[x=w<<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*A,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;k[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,k[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,k[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,k[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,k[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),A=new Uint8Array((b+1+l.interlace)*h);return c=l.tabs.CgBI?i(c,A):r(c,A),l.interlace==0?c=a(c,l,0,f,h):l.interlace==1&&(c=(function(k,S){const E=S.width,P=S.height,w=s(S),O=w>>3,p=Math.ceil(E*w/8),y=new Uint8Array(P*p);let T=0;const I=[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=I[R];for(;F<P;)F+=g,U++;let N=M[R];for(;N<E;)N+=_,L++;const W=Math.ceil(L*w/8);a(k,S,T,L,U);let B=0,V=I[R];for(;V<P;){let X=M[R],Z=T+B*W<<3;for(;X<E;){var x;if(w==1&&(x=(x=k[Z>>3])>>7-(7&Z)&1,y[V*p+(X>>3)]|=x<<7-((7&X)<<0)),w==2&&(x=(x=k[Z>>3])>>6-(7&Z)&3,y[V*p+(X>>2)]|=x<<6-((3&X)<<1)),w==4&&(x=(x=k[Z>>3])>>4-(7&Z)&15,y[V*p+(X>>1)]|=x<<4-((1&X)<<2)),w>=8){const ee=V*p+X*O;for(let H=0;H<O;H++)y[ee+H]=k[(Z>>3)+H]}Z+=w,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,A=0,v=0,k=0,S=0,E=0,P=0,w=0,O=0,p=0;if(c[0]==3&&c[1]==0)return f||new h(0);const y=l.H,T=y.b,I=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));A==0;)if(A=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,w=31),v==2){k=I(c,p,5)+257,S=I(c,p+5,5)+1,E=I(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=I(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,k+S,c,p,x.v);const U=y.V(x.v,0,k,x.C);P=(1<<U)-1;const F=y.V(x.v,k,S,x.D);w=(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)+I(c,p,7&X),p+=7&X}const N=b[R(c,p)&w];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,A){const v=l.H.e,k=l.H.Z;let S=0;for(;S<h;){const E=c[k(m,b)&f];b+=15&E;const P=E>>>4;if(P<=15)A[S]=P,S++;else{let w=0,O=0;P==16?(O=3+v(m,b,2),b+=2,w=A[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;)A[S]=w,S++}}return b},l.H.V=function(c,f,h,m){let b=0,A=0;const v=m.length>>>1;for(;A<h;){const k=c[A+f];m[A<<1]=0,m[1+(A<<1)]=k,k>b&&(b=k),A++}for(;A<v;)m[A<<1]=0,m[1+(A<<1)]=0,A++;return b},l.H.n=function(c,f){const h=l.H.m,m=c.length;let b,A,v,k;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,A=1;A<=f;A++)b=b+S[A-1]<<1,P[A]=b;for(v=0;v<m;v+=2)k=c[v+1],k!=0&&(c[v]=P[k],P[k]++)},l.H.A=function(c,f,h){const m=c.length,b=l.H.m.r;for(let A=0;A<m;A+=2)if(c[A+1]!=0){const v=A>>1,k=c[A+1],S=v<<4|k,E=f-k;let P=c[A]<<E;const w=P+(1<<E);for(;P!=w;)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 A=c[b]<<f-c[b+1];c[b]=h[A]>>>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,A){for(;b--!=0;)m.push(0,A)}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 A=Math.ceil(h*b/8);let v,k;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<A;E++)l[E+1]=l[E+1]+(l[E+1-b]>>>1)&255;for(let P=0;P<m;P++)if(v=f+P*A,k=v+P+1,S=l[k-1],E=0,S==0)for(;E<A;E++)l[v+E]=l[k+E];else if(S==1){for(;E<b;E++)l[v+E]=l[k+E];for(;E<A;E++)l[v+E]=l[k+E]+l[v+E-b]}else if(S==2)for(;E<A;E++)l[v+E]=l[k+E]+l[v+E-A];else if(S==3){for(;E<b;E++)l[v+E]=l[k+E]+(l[v+E-A]>>>1);for(;E<A;E++)l[v+E]=l[k+E]+(l[v+E-A]+l[v+E-b]>>>1)}else{for(;E<b;E++)l[v+E]=l[k+E]+o(0,l[v+E-A],0);for(;E<A;E++)l[v+E]=l[k+E]+o(l[v+E-b],l[v+E-A],l[v+E-b-A])}return l}function o(l,c,f){const h=l+c-f,m=h-l,b=h-c,A=h-f;return m*m<=b*b&&m*m<=A*A?l:b*b<=A*A?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,A,v,k){const S=Math.min(c,m),E=Math.min(f,b);let P=0,w=0;for(let R=0;R<E;R++)for(let x=0;x<S;x++)if(A>=0&&v>=0?(P=R*c+x<<2,w=(v+R)*m+A+x<<2):(P=(-v+R)*c-A+x<<2,w=R*m+x<<2),k==0)h[w]=l[P],h[w+1]=l[P+1],h[w+2]=l[P+2],h[w+3]=l[P+3];else if(k==1){var O=l[P+3]*.00392156862745098,p=l[P]*O,y=l[P+1]*O,T=l[P+2]*O,I=h[w+3]*(1/255),M=h[w]*I,j=h[w+1]*I,C=h[w+2]*I;const g=1-O,_=O+I*g,L=_==0?0:1/_;h[w+3]=255*_,h[w+0]=(p+M*g)*L,h[w+1]=(y+j*g)*L,h[w+2]=(T+C*g)*L}else if(k==2)O=l[P+3],p=l[P],y=l[P+1],T=l[P+2],I=h[w+3],M=h[w],j=h[w+1],C=h[w+2],O==I&&p==M&&y==j&&T==C?(h[w]=0,h[w+1]=0,h[w+2]=0,h[w+3]=0):(h[w]=p,h[w+1]=y,h[w+2]=T,h[w+3]=O);else if(k==3){if(O=l[P+3],p=l[P],y=l[P+1],T=l[P+2],I=h[w+3],M=h[w],j=h[w+1],C=h[w+2],O==I&&p==M&&y==j&&T==C)continue;if(O<220&&I>20)return!1}return!0}return{decode:function(c){const f=new Uint8Array(c);let h=8;const m=e,b=m.readUshort,A=m.readUint,v={tabs:{},frames:[]},k=new Uint8Array(f.length);let S,E=0,P=0;const w=[137,80,78,71,13,10,26,10];for(var O=0;O<8;O++)if(f[O]!=w[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++)k[E+O]=f[h+O];E+=R}else if(x=="acTL")v.tabs[x]={num_frames:A(f,h),num_plays:A(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:A(f,h+12),y:A(f,h+16),width:A(f,h+4),height:A(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),I=h+R-y-1;if(x=="tEXt")j=m.readASCII(f,y+1,I);else{var M=r(f.slice(y+2,y+2+I));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),I=R-((p=y+1)-h),g==0?j=m.readUTF8(f,p,I):(M=r(f.slice(p,p+I)),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,k,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,A=new Uint8Array(b),v=new Uint8Array(b),k=new Uint8Array(b);for(let E=0;E<c.frames.length;E++){const P=c.frames[E],w=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++)k[S]=A[S];if(P.blend==0?d(T,p,y,A,f,h,w,O,0):P.blend==1&&d(T,p,y,A,f,h,w,O,1),m.push(A.buffer.slice(0)),P.dispose!=0){if(P.dispose==1)d(v,p,y,A,f,h,w,O,0);else if(P.dispose==2)for(S=0;S<b;S++)A[S]=k[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 I=0;I<8;I++)1&T?T=3988292384^T>>>1:T>>>=1;p[y]=T}return p})(),update(p,y,T,I){for(let M=0;M<I;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,I){y[T]+=p[0]*I>>4,y[T+1]+=p[1]*I>>4,y[T+2]+=p[2]*I>>4,y[T+3]+=p[3]*I>>4}function s(p){return Math.max(0,Math.min(255,p))}function a(p,y){const T=p[0]-y[0],I=p[1]-y[1],M=p[2]-y[2],j=p[3]-y[3];return T*T+I*I+M*M+j*j}function o(p,y,T,I,M,j,C){C==null&&(C=1);const R=I.length,x=[];for(var g=0;g<R;g++){const V=I[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]=I[_]}}function u(p,y,T,I,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,I[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 I=0;I<p.frames.length;I++){const M=p.frames[I];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,I,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,kc=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 Ic=(Kt-dt+1)*(Sn-ht+1);Ic<kc&&(kc=Ic,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(I!=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,I);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,I,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||I[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=I[M];X.rect=j,X.blend=1,X.img=new Uint8Array(j.width*j.height*4),I[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,I,M){e(p,y,T,I,M.width,M.height,-M.x,-M.y,2)}function h(p,y,T,I,M,j,C){const R=[];let x,g=[0,1,2,3,4];j!=-1?g=[j]:(y*I>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,I,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,I,M,j){const C=T*I;let R=C+T;if(p[R]=j,R++,j==0)if(I<500)for(var x=0;x<I;x++)p[R+x]=y[C+x];else p.set(new Uint8Array(y.buffer,C,I),R);else if(j==1){for(x=0;x<M;x++)p[R+x]=y[C+x];for(x=M;x<I;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<I;x++)p[R+x]=y[C+x];if(j==3)for(x=M;x<I;x++)p[R+x]=y[C+x]-(y[C+x-M]>>1)+256&255;if(j==4)for(x=M;x<I;x++)p[R+x]=y[C+x]-n(y[C+x-M],0,0)+256&255}else{if(j==2)for(x=0;x<I;x++)p[R+x]=y[C+x]+256-y[C+x-I]&255;if(j==3){for(x=0;x<M;x++)p[R+x]=y[C+x]+256-(y[C+x-I]>>1)&255;for(x=M;x<I;x++)p[R+x]=y[C+x]+256-(y[C+x-I]+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-I],0)&255;for(x=M;x<I;x++)p[R+x]=y[C+x]+256-n(y[C+x-M],y[C+x-I],y[C+x-M-I])&255}}}function b(p,y){const T=new Uint8Array(p),I=T.slice(0),M=new Uint32Array(I.buffer),j=A(I,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;)_=k(_.est,U,F,N,W)<=0?_.left:_.right;g[L>>2]=_.ind,M[L>>2]=_.est.rgba}return{abuf:I.buffer,inds:g,plte:R}}function A(p,y,T){T==null&&(T=1e-4);const I=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=w(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,I,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=w(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=w(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,I,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,I,M),p;const j=k(p.est,y,T,I,M);let C=p.left,R=p.right;j>0&&(C=p.right,R=p.left);const x=v(C,y,T,I,M);if(x.tdst<=j*j)return x;const g=v(R,y,T,I,M);return g.tdst<x.tdst?g:x}function k(p,y,T,I,M){const{e:j}=p;return j[0]*y+j[1]*T+j[2]*I+j[3]*M-p.eMq}function S(p,y,T,I,M,j){for(I-=4;T<I;){for(;E(p,T,M)<=j;)T+=4;for(;E(p,I,M)>j;)I-=4;if(T>=I)break;const C=y[T>>2];y[T>>2]=y[I>>2],y[I>>2]=C,T+=4,I-=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 I=[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]+=_,I[0]+=R*R,I[1]+=R*x,I[2]+=R*g,I[3]+=R*_,I[5]+=x*x,I[6]+=x*g,I[7]+=x*_,I[10]+=g*g,I[11]+=g*_,I[15]+=_*_}return I[4]=I[1],I[8]=I[2],I[9]=I[6],I[12]=I[3],I[13]=I[7],I[14]=I[11],{R:I,m:M,N:j}}function w(p){const{R:y}=p,{m:T}=p,{N:I}=p,M=T[0],j=T[1],C=T[2],R=T[3],x=I==0?0:1/I,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(I!=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,I,M,j,C,R){M==null&&(M=0),R==null&&(R=!1);const x=l(y,T,I,M,[!1,!1,!1,0,R,!1]);return d(x,-1),u(x,T,I,j,C)},ze.encodeLL=function(y,T,I,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:I},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,I,R,x)},ze.encode.compress=l,ze.encode.dither=o,ze.quantize=b,ze.quantize.getKDtree=A,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,A,v=f,k=0,S=0,E=0;function P(p){c.setUint16(S,p,!0),S+=2}function w(p){c.setUint32(S,p,!0),S+=4}function O(p){S+=p}P(19778),w(d),O(4),w(122),w(108),w(n),w(-r>>>0),P(1),P(32),w(3),w(u),w(2835),w(2835),O(8),w(16711680),w(65280),w(255),w(4278190080),w(1466527264),(function p(){for(;k<r&&v>0;){for(A=122+k*o,h=0;h<i;)v--,m=a[E++],b=m>>>24,c.setUint32(A+h,m<<8|b),h+=4;k++}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 ke={CHROME:"CHROME",FIREFOX:"FIREFOX",DESKTOP_SAFARI:"DESKTOP_SAFARI",IE:"IE",IOS:"IOS",ETC:"ETC"},sy={[ke.CHROME]:16384,[ke.FIREFOX]:11180,[ke.DESKTOP_SAFARI]:16384,[ke.IE]:8192,[ke.IOS]:4096,[ke.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=ke.ETC;const{userAgent:t}=navigator;return/Chrom(e|ium)/i.test(t)?e=ke.CHROME:/iP(ad|od|hone)/i.test(t)&&/WebKit/i.test(t)?e=ke.IOS:/Safari/i.test(t)?e=ke.DESKTOP_SAFARI:/Firefox/i.test(t)?e=ke.FIREFOX:(/MSIE/i.test(t)||document.documentMode)&&(e=ke.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()||[ke.DESKTOP_SAFARI,ke.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,A,v,k,S,E,P,w,O,p;function y(I=5){if(t.signal&&t.signal.aborted)throw t.signal.reason;s+=I,t.onProgress(Math.min(s,100))}function T(I){if(t.signal&&t.signal.aborted)throw t.signal.reason;s=Math.min(Math.max(I,s),100),t.onProgress(s)}return s=n,a=t.maxIteration||10,o=1024*t.maxSizeMB*1024,y(),lr(e,t).then((function(I){try{return[,u]=I,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,w]=ar(_,L),w.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((k-S)/(k-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,A=m.size>e.size,!b&&!A)return T(100),r(m);var R;return v=e.size,k=m.size,S=k,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,5 +586,4 @@ self.addEventListener('message', async (e) => {
586
586
  self.postMessage({ error: e.message + '\\n' + e.stack, id })
587
587
  }
588
588
  })
589
- `;let la;function q1(e,t){return new Promise(((n,r)=>{la||(la=(function(s){const o=[];return o.push(s),URL.createObjectURL(new Blob(o))})(X1));const i=new Worker(la);i.addEventListener("message",(function(s){if(t.signal&&t.signal.aborted)i.terminate();else if(s.data.progress===void 0){if(s.data.error)return r(new Error(s.data.error)),void i.terminate();n(s.data.file),i.terminate()}else t.onProgress(s.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 ve(e,t){return new Promise((function(n,r){let i,a,s,o,u,d;if(i={...t},s=0,{onProgress:o}=i,i.maxSizeMB=i.maxSizeMB||Number.POSITIVE_INFINITY,u=typeof i.useWebWorker!="boolean"||i.useWebWorker,delete i.useWebWorker,i.onProgress=h=>{s=h,typeof o=="function"&&o(s)},!(e instanceof Blob||e instanceof K1))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 sc(e,i).then((function(h){try{return a=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 sc(e,i).then((function(m){try{return a=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",q1(e,i).then((function(h){try{return a=h,l()}catch{return c()}}),c)}catch{c()}function f(){try{a.name=e.name,a.lastModified=e.lastModified}catch{}try{i.preserveExif&&e.type==="image/jpeg"&&(!i.fileType||i.fileType&&i.fileType===e.type)&&(a=Xu(e,a))}catch{}return n(a)}}))}ve.getDataUrlFromFile=Ju,ve.getFilefromDataUrl=oa,ve.loadImage=ec,ve.drawImageInCanvas=nc,ve.drawFileInCanvas=sr,ve.canvasToFile=or,ve.getExifOrientation=rc,ve.handleMaxWidthOrHeight=ic,ve.followExifOrientation=ac,ve.cleanupCanvasMemory=We,ve.isAutoOrientationInBrowser=Yt,ve.approximateBelowMaximumCanvasSizeOfBrowser=tc,ve.copyExifWithoutOrientation=Xu,ve.getBrowserName=wt,ve.version="2.0.2";const oc=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 lc(e,t,n){if(oc(e.name)!=="image")return e;const r={maxSizeMB:1,maxWidthOrHeight:1920,useWebWorker:!0,onProgress:i=>n(i)};try{t(!0);const i=await ve(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 uc(e,t,n,r,i){e.preventDefault();for(const a of e.dataTransfer.items)if(a.kind==="file"){const s=a.getAsFile();if(!s)continue;const o=await lc(s,r,i);t(URL.createObjectURL(o)),n(o.name)}}async function cc(e,t,n,r,i){const a=e.target.files?.[0];if(!a)return;const s=await lc(a,r,i);t(URL.createObjectURL(s)),n(s.name)}function fc(e,t){e.preventDefault(),t.current&&(t.current.style.borderColor="blue")}function ua(e,t){e.preventDefault(),t.current&&(t.current.style.borderColor="grey")}function Q1({progress:e=null}){const t=e!==null?e/100*360:0;return k.jsx("div",{className:"w-full h-full flex justify-center items-center",children:k.jsx("div",{className:"grid justify-center items-center w-32 h-32 rounded-full",style:{background:`conic-gradient(rgb(59, 130, 246) ${t}deg, transparent 0)`},children:k.jsx("div",{className:"w-30 h-30 bg-white rounded-full text-center text-(--draftify-theme-color) grid items-center ",children:k.jsxs("div",{children:[k.jsx("div",{className:"italic text-[13px]",children:"progress"}),k.jsx("div",{className:"text-xl font-bold",children:e!==null&&`${e}%`})]})})})})}function dc({mediaBlock:e,modifyMedia:t}){const[n,r]=z.useState(""),[i,a]=z.useState(""),[s,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",A=>A.preventDefault()),window.addEventListener("drop",A=>A.preventDefault())},[]),z.useEffect(()=>{r("To remove image or media component, refresh first."),e.data.src!==""&&(a(e.data.src),o(e.type))},[e.data.src,e.type]),z.useEffect(()=>{e.type==="image"?t({imageBlockId:e.id,src:i,alt:e.data.alt,caption:e.data.caption}):e.type==="video"&&t({videoBlockId:e.id,src:i,provider:e.data.provider}),u&&o(oc(u))},[i]);const b=()=>{a(""),d("")};return k.jsx("div",{className:"border w-full h-68.75",children:i&&!l?s==="image"?k.jsxs("div",{className:"relative w-full h-68.75 text-(--draftify-theme-color) font-medium border-blue-200 pb-6.25",children:[k.jsx("img",{src:i,alt:"",className:"flex-1 media"}),k.jsxs("div",{className:"absolute bottom-0.5 flex gap-2 items-center w-full h-6.25 text-[12px]",children:[n&&k.jsx("div",{className:"text-(--draftify-theme-color)",children:n}),k.jsxs("div",{onClick:b,className:"flex gap-2 border rounded-[5px] items-center px-1 bg-(--draftify-theme-color) text-white cursor-pointer",children:["refresh",k.jsx(ke,{icon:["fas","refresh"]})]})]})]}):s==="video"||s==="media"?k.jsxs("div",{className:"relative w-full h-68.75 text-blue-600 font-medium border-blue-200 pb-6.25",children:[k.jsx("video",{autoPlay:!0,muted:!0,controls:!0,className:"flex-1 media",children:k.jsx("source",{src:i,type:"video/mp4"})}),k.jsxs("div",{className:"absolute bottom-0.5 flex gap-2 items-center w-full h-6.25 text-[12px]",children:[n&&k.jsx("div",{className:"text-(--draftify-theme-color)",children:n}),k.jsxs("div",{onClick:b,className:"flex gap-2 border rounded-[5px] items-center px-1 bg-(--draftify-theme-color) text-white cursor-pointer",children:["refresh",k.jsx(ke,{icon:["fas","refresh"]})]})]})]}):s==="unknown"&&k.jsxs("div",{className:"flex flex-col items-center justify-center h-full gap-4 p-4 text-gray-500 text-center",children:[k.jsx(ke,{icon:["fas","file"],size:"2x"}),k.jsxs("p",{className:"text-sm font-medium",children:["wrong format: ",u]}),k.jsx("p",{className:"text-sm font-medium",children:"accepted formats: png, jpg, jpeg, gif, mp4, webm,ogg"}),k.jsx(ke,{icon:["fas","refresh"],onClick:()=>{a(""),d("")}})]}):l?k.jsx(Q1,{progress:f}):k.jsxs("div",{ref:m,onDrop:A=>uc(A,a,d,c,h),onDragOver:A=>fc(A,m),onDragLeave:A=>ua(A,m),onMouseLeave:A=>ua(A,m),className:"border-2 border-dashed w-full h-full grid items-center",children:[k.jsx("input",{type:"file",id:"file",className:"hidden",onChange:A=>cc(A,a,d,c,h)}),k.jsxs("label",{htmlFor:"file",className:"flex flex-col justify-center items-center text-center gap-5 px-4 py-2 rounded-[10px] cursor-pointer",children:[k.jsx("div",{className:"border rounded-[50%] flex justify-center items-center w-15 h-15 text-[20px] cursor-pointer",children:k.jsx(ke,{icon:["fas","arrow-up-from-bracket"]})}),k.jsxs("div",{className:"normal-title",children:["Drop your"," ",e.type==="image"?k.jsx("strong",{children:"image/GIF"}):k.jsx("strong",{children:"video"})," ","here",k.jsx("div",{className:"normal-text text-(--grey-secondary)",children:"or click to browse"})]})]})]})})}function Z1({imageBlock:e}){return k.jsx("div",{children:k.jsx("img",{src:e.data.src,alt:"",className:"media rounded-[10px]"})},e.id)}function J1({videoBlock:e}){return k.jsx("div",{children:e.data.src&&k.jsx("video",{autoPlay:!0,muted:!0,controls:!0,className:"rounded-[10px] media",children:k.jsx("source",{src:e.data.src,type:"video/mp4"})})},e.id)}function ey({linkBlock:e,modifyLink:t}){const[n,r]=z.useState(e.data.linkText),[i,a]=z.useState(e.data.url);return z.useEffect(()=>{t({linkBlockId:e.id,linkText:n,url:i})},[n,i,e.id]),k.jsxs("div",{className:"flex",children:[k.jsx("input",{type:"text",placeholder:"Enter link text...",className:"flex-1 border-b link",autoFocus:!0,value:e.data.linkText,onChange:s=>r(s.target.value)}),k.jsx("span",{children:"["}),k.jsx("input",{type:"url",placeholder:"url",className:"flex-1 border-b link",autoFocus:!0,value:e.data.url,onChange:s=>a(s.target.value)}),k.jsx("span",{children:"]"})]})}function ty({linkBlock:e}){return k.jsx("a",{href:e.data.url,className:"link",children:e.data.linkText},e.id)}function ny({codeBlock:e,modifyCode:t}){return k.jsx("textarea",{className:"code",placeholder:"Code block...",autoFocus:!0,value:e.data.code,onChange:n=>t({codeBlockId:e.id,language:e.data.language,code:n.target.value})})}function ry({codeBlock:e}){return k.jsx("pre",{className:"code",children:k.jsx("code",{children:e.data.code})},e.id)}function iy({block:e,modifyHeading:t,modifySubheading:n,modifyParagraph:r,modifyQuote:i,modifyList:a,modifyTable:s,modifyImage:o,modifyVideo:u,modifyLink:d,modifyCode:l}){switch(e.type){case"heading":return k.jsx(D1,{headingBlock:e,modifyHeading:t});case"subheading":return k.jsx(j1,{subheadingBlock:e,modifySubheading:n});case"paragraph":return k.jsx(N1,{paragraphBlock:e,modifyParagraph:r});case"quote":return k.jsx(V1,{quoteBlock:e,modifyQuote:i});case"list":return k.jsx(L1,{listBlock:e,modifyList:a});case"table":return k.jsx(U1,{tableBlock:e,modifyTable:s});case"image":return k.jsx(dc,{mediaBlock:e,modifyMedia:o});case"video":return k.jsx(dc,{mediaBlock:e,modifyMedia:u});case"link":return k.jsx(ey,{linkBlock:e,modifyLink:d});case"code":return k.jsx(ny,{codeBlock:e,modifyCode:l});default:return null}}function xn({text:e,children:t}){return k.jsxs("div",{className:"relative inline-block group",children:[t,k.jsx("span",{className:`absolute bottom-full mb-2 left-1/2 -translate-x-1/2\r
590
- bg-gray-800 text-white text-xs rounded py-1 px-2 opacity-0 group-hover:opacity-100 group-hover:transition-y-[5px] transition duration-300 whitespace-nowrap z-10`,children:e})]})}const ay=[{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"]}];function sy({handleClick:e}){const[t,n]=z.useState(null),r=(i,a)=>{n(i),e(a)};return k.jsx("div",{className:"flex flex-wrap gap-1.25 md:gap-2.5 items-center",children:ay.map(i=>k.jsx(xn,{text:`${i.type}`,children:k.jsxs("div",{className:`flex items-center gap-2.5 h-10 p-2 border-2 border-gray-600 cursor-pointer rounded-[10px] text-sm md:text-md ${t===i.id?"text-(--draftify-theme-color)":"text-gray-600"}`,onClick:()=>i.type!=="table"&&r(i.id,i.type),children:[k.jsxs("div",{className:"flex",children:[k.jsx(ke,{icon:i.icon,onClick:()=>i.type==="table"&&r(i.id,i.type)}),k.jsx("div",{className:"text-xs",children:i.type==="subheading"?"2":""})]}),i.type==="table"&&k.jsx(z1,{handleClick:e,block:i})]})},i.id))})}function hc({blocksData:e}){return e.length!==0&&e.map(t=>{switch(t.type){case"heading":return k.jsx(I1,{headingBlock:t},t.id);case"subheading":return k.jsx(F1,{subheadingBlock:t},t.id);case"paragraph":return k.jsx(O1,{paragraphBlock:t},t.id);case"quote":return k.jsx(_1,{quoteBlock:t},t.id);case"list":return k.jsx(R1,{listBlock:t},t.id);case"table":return k.jsx($1,{tableBlock:t},t.id);case"image":return k.jsx(Z1,{imageBlock:t},t.id);case"video":return k.jsx(J1,{videoBlock:t},t.id);case"link":return k.jsx(ty,{linkBlock:t},t.id);case"code":return k.jsx(ry,{codeBlock:t},t.id);default:return null}})}function oy({view:e,setView:t,setPromptVisiblility:n,blocksData:r,setPromptAction:i,handleCopy:a}){const[s,o]=z.useState(!1),u=z.useRef(null),d=z.useRef(null);function l(c,f,h){!f||!h||(c==="editor"?h.style.transform="translateX(14px)":h.style.transform="translateX(0)")}return z.useEffect(()=>{setTimeout(()=>{o(!1)},3e3)},[s]),k.jsx("div",{className:"md:h-10",children:k.jsxs("div",{className:"relative grid md:flex items-center text-[12px] italic gap-2.5",children:[k.jsxs("div",{className:"md:flex gap-2.5 items-center font-bold logo-text text-[20px]",children:["DRAFTIFY PRO"," ",k.jsx("div",{className:"underline font-normal text-[12px]",children:"Write. Create. Build your story block by block."})]}),k.jsxs("div",{className:"md:absolute right-0 flex items-center gap-2.5",children:[k.jsx(xn,{text:"e.g. for dev dummy data",children:k.jsxs("button",{className:"border rounded-[10px] bg-(--hovered-draftify-theme-color) text-white hover:font-semibold hover:bg-(--draftify-theme-color) p-1 cursor-pointer",onClick:()=>{i("downloadJSON"),n(!0)},children:["Download JSON ",k.jsx(ke,{icon:["fas","download"]})]})}),k.jsx(xn,{text:"Download as document",children:k.jsxs("button",{className:"border rounded-[10px] bg-(--hovered-draftify-theme-color) text-white hover:font-semibold hover:bg-(--draftify-theme-color) p-1 cursor-pointer",onClick:()=>{i("exportDocx"),n(!0)},children:["Export .docx ",k.jsx(ke,{icon:["fas","download"]})]})}),k.jsx(xn,{text:"copy to clipboard",children:k.jsx("button",{className:`p-1 cursor-pointer ${s?"text-green-400":"text-(--hovered-draftify-theme-color)"}`,children:k.jsx(ke,{icon:["fas",`${s?"check":"copy"}`],onClick:()=>a(r,o)})})}),k.jsxs(xn,{text:"toggle btn editor & preview",children:[k.jsx("div",{ref:u,className:"border w-7.5 h-4 rounded-2xl cursor-pointer duration-300 flex items-center p-0",onClick:()=>{t(c=>c==="editor"?"preview":"editor"),l(e,u.current,d.current)},children:k.jsx("div",{ref:d,className:"w-3 h-3 rounded-xl bg-[#232323] duration-300 flex items-center leading-2 justify-center translate-x-px",children:k.jsx("div",{className:"flex items-center h-full text-white -translate-y-0.5",children:e==="editor"?"e":"p"})})})," "]}),k.jsxs("div",{className:"w-25",children:["viewing ",e]})]})]})})}function ly(){return k.jsx("div",{className:"group flex flex-col justify-center gap-y-0.75 w-3.75 h-full border border-(--draftify-theme-color) hover:border-black rounded-tl-[5px] rounded-bl-[5px] cursor-move",children:[1,2,3].map(e=>k.jsx("div",{className:"w-1 h-1 rounded-2.5 bg-(--draftify-theme-color) group-hover:bg-black self-center"},e))})}function uy({gridDots:e}){return k.jsx("div",{className:"fixed top-0 left-0 w-full h-full -z-1",children:e.map(t=>k.jsx("div",{className:"absolute w-px h-px bg-black","data-x":t.x,"data-y":t.y,style:{left:`${t.x*20}px`,top:`${t.y*20}px`}},t.key))})}function cy({docTitle:e,setDocTitle:t,description:n,setDescription:r,author:i,setAuthor:a,promptAction:s,handlePromptAction:o,setPromptVisiblility:u}){return k.jsxs("div",{className:"doc-metadata-prompt",children:[k.jsxs("div",{className:"flex",children:[k.jsx("div",{className:" flex-1 mb-2.5",children:"Would you like to add metadata before downloading?"}),k.jsx("div",{children:k.jsx(ke,{icon:["fas","xmark"],className:"cursor-pointer",onClick:()=>u(!1)})})]}),k.jsxs("div",{className:"font-semibold",children:[k.jsxs("div",{children:[k.jsx("div",{children:" document title: (optional)"}),k.jsx("input",{type:"text",className:"w-full border rounded-md p-1",value:e,onChange:d=>t(d.target.value)})]}),k.jsxs("div",{children:[k.jsx("div",{children:"description: (optional)"}),k.jsx("textarea",{name:"description",className:"w-full border rounded-md p-1",value:n,onChange:d=>r(d.target.value)})]}),k.jsxs("div",{children:[k.jsx("div",{children:"author: (optional)"}),k.jsx("input",{type:"text",className:"w-full border rounded-md p-1",value:i,onChange:d=>a(d.target.value)})]})]}),k.jsxs("div",{className:"mt-4 flex gap-2",children:[k.jsx("button",{className:"flex-1 px-4 py-2 bg-gray-300 text-black rounded-md hover:bg-gray-400 cursor-pointer",onClick:()=>o(s,"ignore"),children:"Ignore"}),k.jsx("button",{className:"flex-1 px-4 py-2 bg-blue-500 text-white rounded-md hover:bg-blue-600 cursor-pointer",onClick:()=>o(s,"add"),children:"Add"})]})]})}function mc({blocksData:e,modifyBlocks:t}){const[n,r]=z.useState({metadata:{},version:"1.0.0",blocks:e}),[i,a]=z.useState(""),[s,o]=z.useState(""),[u,d]=z.useState(""),[l,c]=z.useState([]),[f,h]=z.useState("editor"),[m,b]=z.useState(!1),[A,v]=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 M=localStorage.getItem("draftifyDoc"),H=JSON.parse(M);r(H),a(H.metadata?.docTitle||""),o(H.metadata?.description||""),d(H.metadata?.author||""),t(Z.normalizeDocument(H).blocks||Z.normalizeBlock(e))}else t(Z.normalizeBlock(e))},[]),z.useEffect(()=>{(async H=>{const B=await Promise.all(H.map(async G=>{if(G.type==="image"&&G.file){const Q=await Z.imageToBase64(G);return{...G,content:Q,file:void 0}}return G}));localStorage.setItem("draftifyDoc",JSON.stringify({...n,blocks:B}))})(e)},[e,n]),z.useEffect(()=>{const M={docTitle:i||"Untitled",description:s||"",author:u||"Unknown",createdAt:new Date().toISOString()};r(H=>({...H,metadata:M}))},[i,s,u]);const I=(M,H)=>{const B={docTitle:"Untitled Document",description:"",author:"Unknown Author",createdAt:new Date().toISOString()};M==="downloadJSON"?Z.handleDownloadJSON(H==="add"?n:{...n,metadata:B}):M==="exportDocx"&&Z.exportBlocksToDocx(H==="add"?n:{...n,metadata:B}),b(!1)},T=(M,H)=>{switch(M){case"heading":t(B=>[...B,Z.createHeadingBlock()]);break;case"subheading":t(B=>[...B,Z.createSubheadingBlock()]);break;case"paragraph":t(B=>[...B,Z.createParagraphBlock()]);break;case"quote":t(B=>[...B,Z.createQuoteBlock()]);break;case"list":t(B=>[...B,Z.createListBlock()]);break;case"table":t(B=>[...B,Z.createTableBlock(H)]);break;case"image":t(B=>[...B,Z.createImageBlock()]);break;case"video":t(B=>[...B,Z.createVideoBlock()]);break;case"link":t(B=>[...B,Z.createLinkBlock()]);break;case"code":t(B=>[...B,Z.createCodeBlock()]);break}},C=({headingBlockId:M,newContent:H,level:B})=>{t(G=>Z.modifyHeadingBlock(G,M,H,B))},P=({subheadingBlockId:M,newContent:H})=>{t(B=>Z.modifySubheadingBlock(B,M,H))},w=({paragraphBlockId:M,newContent:H})=>{t(B=>Z.modifyParagraphBlock(B,M,H))},L=({quoteBlockId:M,newContent:H,author:B})=>{t(G=>Z.modifyQuoteBlock(G,M,H,B))},p=({listBlockId:M,listStyle:H,items:B})=>{t(G=>Z.modifyListBlock(G,M,H,B))},y=({tableBlockId:M,tableContent:H})=>{t(B=>Z.modifyTableBlock(B,M,H))},S=({imageBlockId:M,src:H,alt:B,caption:G})=>{t(Q=>Z.modifyImageBlock(Q,M,H,B,G))},D=({videoBlockId:M,src:H,provider:B})=>{t(G=>Z.modifyVideoBlock(G,M,H,B))},j=({linkBlockId:M,linkText:H,url:B})=>{t(G=>Z.modifyLinkBlock(G,M,H,B))},F=({codeBlockId:M,language:H,code:B})=>{t(G=>Z.modifyCodeBlock(G,M,H,B))},E=M=>{const H=e.find(B=>B.id===M);(H.type==="image"||H.type==="video")&&H.data.src!==""||t(B=>B.filter(G=>G.id!==M))},R=(M,H)=>{t(B=>{const G=[...B],[Q]=G.splice(M,1);return G.splice(H,0,Q),G})},x=(M,H)=>{M.preventDefault(),M.currentTarget.classList.remove("bg-gray-100");const B=parseInt(M.dataTransfer.getData("text/plain")),G=H;B!==G&&R(B,G)},g=(M,H)=>{M.dataTransfer.setData("text/plain",H),M.currentTarget.style.opacity="0.5"},V=M=>{M.currentTarget.style.opacity="1"},O=M=>{M.currentTarget.classList.add("bg-gray-100")},U=M=>{M.currentTarget.classList.remove("bg-gray-100")},N={show:{transition:{staggerChildren:.07}}},_={hidden:{opacity:0,y:20},show:{opacity:1,y:0},exit:{opacity:0,y:-20}},W={type:"spring",stiffness:300,damping:20},$={scale:1.02,backgroundColor:"rgba(243, 244, 246, 0.8)"};return{view:f,setView:h,gridDots:l,setGridDots:c,docTitle:i,setDocTitle:a,description:s,setDescription:o,author:u,setAuthor:d,handleCopy:Z.handleCopy,handlePromptAction:I,promptAction:A,setPromptAction:v,promptVisibility:m,setPromptVisiblility:b,blocksData:e,handleClick:T,modifyHeading:C,modifySubheading:P,modifyParagraph:w,modifyQuote:L,modifyList:p,modifyTable:y,modifyImage:S,modifyVideo:D,modifyLink:j,modifyCode:F,onDropHandler:x,onDragStart:g,onDragEnd:V,onDragEnter:O,onDragLeave:U,containerVariants:N,itemVariants:_,transitions:W,whileHover:$,handleDelete:E}}function fy(e){z.useEffect(()=>{function t(){const r=Math.ceil(window.innerWidth/20),i=Math.ceil(document.documentElement.scrollHeight/20),a=[];for(let s=0;s<i;s++)for(let o=0;o<r;o++)a.push({x:o,y:s,key:`${o}-${s}`});e(a)}return t(),window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)},[e])}var dy={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"]},hy={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"]},my={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"]},py={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"]},gy={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"]},yy={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"]},vy={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"]},by={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"]},xy={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"]},wy={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"]},Ay={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"]},Sy={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"]},Ty={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"]},Py={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"]},Ey={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"]},Cy={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"]},ky=Cy;var My={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"]};d1.add(Ty,yy,py,Ay,gy,hy,My,wy,vy,Sy,xy,my,dy,Py,ky,Ey,by);function pc({blocksData:e,modifyBlocks:t}){const{view:n,setView:r,gridDots:i,setGridDots:a,docTitle:s,setDocTitle:o,description:u,setDescription:d,author:l,setAuthor:c,handleCopy:f,handlePromptAction:h,promptAction:m,setPromptAction:b,promptVisibility:A,setPromptVisiblility:v,handleClick:I,modifyHeading:T,modifySubheading:C,modifyParagraph:P,modifyQuote:w,modifyList:L,modifyTable:p,modifyImage:y,modifyVideo:S,modifyLink:D,modifyCode:j,onDropHandler:F,onDragStart:E,onDragEnd:R,onDragEnter:x,onDragLeave:g,containerVariants:V,itemVariants:O,transitions:U,whileHover:N,handleDelete:_}=mc({blocksData:e,modifyBlocks:t});return fy(a),k.jsxs(k.Fragment,{children:[k.jsx(uy,{gridDots:i}),k.jsxs("div",{className:"draftify-container",children:[k.jsx(oy,{view:n,setView:r,blocksData:e,setPromptAction:b,setPromptVisiblility:v,handleCopy:f}),A&&k.jsx(cy,{docTitle:s,setDocTitle:o,description:u,setDescription:d,author:l,setAuthor:c,promptAction:m,handlePromptAction:h,setPromptVisiblility:v}),n==="editor"&&k.jsxs(k.Fragment,{children:[k.jsx(sy,{handleClick:I}),k.jsx("div",{className:"editor-area",onSubmit:W=>W.preventDefault(),children:k.jsx(cl.div,{className:"grid gap-2.5",variants:V,animate:"show",exit:"hidden",children:k.jsx(Td,{children:e.map((W,$)=>k.jsxs(cl.div,{layout:!0,variants:O,transition:U,whileHover:N,draggable:!0,onDragStart:M=>E(M,$),onDragEnd:M=>R(M),onDragOver:M=>M.preventDefault(),onDragEnter:M=>x(M),onDragLeave:M=>g(M),onDrop:M=>F(M,$),className:"block-container",children:[k.jsx(ly,{}),k.jsx(iy,{block:W,modifyHeading:T,modifySubheading:C,modifyParagraph:P,modifyQuote:w,modifyList:L,modifyTable:p,modifyImage:y,modifyVideo:S,modifyLink:D,modifyCode:j}),k.jsx(ke,{icon:["fas","trash"],className:"cursor-pointer hover:text-red-500",onClick:()=>_(W.id)})]},W.id))})})})]}),n==="preview"&&k.jsx("div",{className:"output-area",onSubmit:W=>W.preventDefault(),children:k.jsx(hc,{blocksData:e})})]})]})}we.DraftifyBlocksReader=hc,we.DraftifyReact=pc,we.default=pc,we.dragHandler=fc,we.dragLeaveHandler=ua,we.dropHandler=uc,we.onFileChange=cc,we.useDraftifyReact=mc,Object.defineProperties(we,{__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 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(URL.createObjectURL(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(URL.createObjectURL(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",A=>A.preventDefault()),window.addEventListener("drop",A=>A.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(()=>{e.type==="image"?t({imageBlockId:e.id,src:i,alt:e.data.alt,caption:e.data.caption}):e.type==="video"&&t({videoBlockId:e.id,src:i,provider:e.data.provider}),u&&o(pc(u))},[i]);const b=()=>{s(""),d("")};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,alt:"",className:je.mediaItem}):D.jsx("video",{autoPlay:!0,muted:!0,controls:!0,className:je.mediaItem,children:D.jsx("source",{src:i,type:"video/mp4"})})}):l?D.jsx(uy,{progress:f}):D.jsxs("div",{ref:m,onDrop:A=>yc(A,s,d,c,h),onDragOver:A=>bc(A,m),onDragLeave:A=>xc(A,m),className:je.dropzone,children:[D.jsx("input",{type:"file",id:"file",style:{display:"none"},onChange:A=>vc(A,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,A]=z.useState("editor"),[v,k]=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}),k(!1)},w=(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))},I=({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:A,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:k,blocksData:e,handleClick:w,modifyHeading:O,modifySubheading:p,modifyParagraph:y,modifyQuote:T,modifyList:I,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"]},ky={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"]},Iy={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,ky,Cy,Fy,Ey,Ty,Uy,jy,Iy,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:A,setDocTitle:v,description:k,setDescription:S,author:E,setAuthor:P,handleCopy:w,handlePromptAction:O,promptAction:p,setPromptAction:y,promptVisibility:T,setPromptVisiblility:I,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:I,handleCopy:w}),T&&D.jsx(wy,{docTitle:A,setDocTitle:v,description:k,setDescription:S,author:E,setAuthor:P,promptAction:p,handlePromptAction:O,setPromptVisiblility:I}),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"}})}));