@worldresources/wri-design-systems 2.143.0 → 2.143.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.
package/dist/index.cjs.js CHANGED
@@ -3402,7 +3402,7 @@ function kc(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Obj
3402
3402
  font-weight: 700;
3403
3403
  color: ${u("Medium"===b?"warning":"Strong"===b||"Very Strong"===b?"success":"error",900)};
3404
3404
  }
3405
- `),"aria-live":"polite",role:"status",children:["Password Strength: ",t.jsx("span",{children:x.strength})]}),t.jsx("div",{css:Wt(x.strength),children:t.jsx("div",{})}),t.jsxs("div",{css:Ut(x.length),"aria-label":`Use a minimum of ${l} characters. ${x.length?"Requirement met.":"Requirement not met."}`,children:[t.jsx("div",{children:x.length?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsxs("p",{children:["Use a minimum of ",l," characters"]})]}),a?.uppercase?null:t.jsxs("div",{css:Ut(x.uppercase),"aria-label":"Use an uppercase letter. "+(x.uppercase?"Requirement met.":"Requirement not met."),children:[t.jsx("div",{children:x.uppercase?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsx("p",{children:"Use an uppercase letter"})]}),a?.lowercase?null:t.jsxs("div",{css:Ut(x.lowercase),"aria-label":"Use a lowercase letter. "+(x.lowercase?"Requirement met.":"Requirement not met."),children:[t.jsx("div",{children:x.lowercase?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsx("p",{children:"Use a lowercase letter"})]}),a?.numbers?null:t.jsxs("div",{css:Ut(x.numbers),"aria-label":"Use a number. "+(x.numbers?"Requirement met.":"Requirement not met."),children:[t.jsx("div",{children:x.numbers?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsx("p",{children:"Use a number"})]}),a?.specialCharacters?null:t.jsxs("div",{css:Ut(x.specialCharacters),"aria-label":"Use a special character. "+(x.specialCharacters?"Requirement met.":"Requirement not met."),children:[t.jsx("div",{children:x.specialCharacters?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsx("p",{children:"Use a special character"})]})]}):null]});var b},exports.ProgressBar=({progress:e})=>{let n=e;return n>100&&(n=100),n<0&&(n=0),t.jsx("div",{css:dp,role:"progressbar","aria-label":`Progress: ${n}%`,"aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":n,children:t.jsx("div",{css:up(n)})})},exports.QualitativeAttribute=({type:e,label:r,caption:i,color:o,onActionClick:a,showActionButton:s,pointIcon:l=t.jsx(F,{color:"#006D2C"})})=>{const[c,d]=n.useState(!0),u=n.useId(),p=n.useId(),h="raster"===e,f="line"===e,x="point"===e,g=c?"Hide":"Show",b=i?`${u} ${p}`:u;return t.jsxs("div",{css:Jn,children:[t.jsxs("div",{css:Qn,children:[t.jsxs("div",{children:[h&&t.jsx("div",{css:Xn(o)}),f&&t.jsx("div",{css:Yn(o)}),x&&t.jsx("div",{css:Kn(o),children:l})]}),t.jsxs("div",{children:[t.jsx("p",{id:u,css:er,children:r}),i?t.jsx("p",{id:p,css:tr,children:i}):null]})]}),a&&s?t.jsx("div",{css:nr,children:t.jsx(v,{type:"button",variant:"borderless",label:g,rightIcon:c?t.jsx(R,{}):t.jsx(O,{}),"aria-pressed":c,"aria-describedby":b,"aria-label":`${g} ${r}`,onClick:()=>{d((e=>!e)),a?.()}})}):null]})},exports.Radio=Ve,exports.RadioGroup=Ae,exports.RadioList=({label:n,caption:i,name:o,radios:a,defaultValue:s,onCheckedChange:l,errorMessage:c,horizontal:d,variant:u="default",required:p})=>{const h=`${n}. ${i?`${i}.`:""} ${p?"Required.":"Optional."} ${c?`Error: ${c}.`:""} `;return t.jsxs(e.Group,{tabIndex:0,css:Xt,"aria-roledescription":"group","aria-label":h,children:[c?t.jsx("div",{css:Qt}):null,t.jsxs("div",{css:(f=!!c,r.css`
3405
+ `),"aria-live":"polite",role:"status",children:["Password Strength: ",t.jsx("span",{children:x.strength})]}),t.jsx("div",{css:Wt(x.strength),children:t.jsx("div",{})}),t.jsxs("div",{css:Ut(x.length),"aria-label":`Use a minimum of ${l} characters. ${x.length?"Requirement met.":"Requirement not met."}`,children:[t.jsx("div",{children:x.length?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsxs("p",{children:["Use a minimum of ",l," characters"]})]}),a?.uppercase?null:t.jsxs("div",{css:Ut(x.uppercase),"aria-label":"Use an uppercase letter. "+(x.uppercase?"Requirement met.":"Requirement not met."),children:[t.jsx("div",{children:x.uppercase?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsx("p",{children:"Use an uppercase letter"})]}),a?.lowercase?null:t.jsxs("div",{css:Ut(x.lowercase),"aria-label":"Use a lowercase letter. "+(x.lowercase?"Requirement met.":"Requirement not met."),children:[t.jsx("div",{children:x.lowercase?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsx("p",{children:"Use a lowercase letter"})]}),a?.numbers?null:t.jsxs("div",{css:Ut(x.numbers),"aria-label":"Use a number. "+(x.numbers?"Requirement met.":"Requirement not met."),children:[t.jsx("div",{children:x.numbers?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsx("p",{children:"Use a number"})]}),a?.specialCharacters?null:t.jsxs("div",{css:Ut(x.specialCharacters),"aria-label":"Use a special character. "+(x.specialCharacters?"Requirement met.":"Requirement not met."),children:[t.jsx("div",{children:x.specialCharacters?t.jsx(y,{color:"var(--chakra-colors-success-500)",height:"8px",width:"8px"}):t.jsx(S,{color:"var(--chakra-colors-error-900)",height:"8px",width:"8px"})}),t.jsx("p",{children:"Use a special character"})]})]}):null]});var b},exports.ProgressBar=({progress:e})=>{let n=e;return n>100&&(n=100),n<0&&(n=0),t.jsx("div",{css:dp,role:"progressbar","aria-label":`Progress: ${n}%`,"aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":n,children:t.jsx("div",{css:up(n)})})},exports.QualitativeAttribute=({type:e,label:r,caption:i,color:o,onActionClick:a,showActionButton:s,pointIcon:l=t.jsx(F,{color:"#006D2C"})})=>{const[c,d]=n.useState(!0),u=n.useId(),p=n.useId(),h="raster"===e,f="line"===e,x="point"===e,g=n.useId(),b=n.useMemo((()=>`${e?`${e} layer`:"layer"}, ${r}${i?`, ${i}`:""}. Currently ${c?"visible":"hidden"}.`),[c,e,r,i]),m=c?"Hide":"Show";return t.jsxs("div",{css:Jn,children:[t.jsx("p",{id:g,css:{position:"absolute",width:1,height:1,margin:-1,padding:0,border:0,clip:"rect(0 0 0 0)",overflow:"hidden"},children:b}),t.jsxs("div",{css:Qn,children:[t.jsxs("div",{children:[h&&t.jsx("div",{css:Xn(o)}),f&&t.jsx("div",{css:Yn(o)}),x&&t.jsx("div",{css:Kn(o),children:l})]}),t.jsxs("div",{children:[t.jsx("p",{id:u,css:er,children:r}),i?t.jsx("p",{id:p,css:tr,children:i}):null]})]}),a&&s?t.jsx("div",{css:nr,children:t.jsx(v,{type:"button",variant:"borderless",label:m,rightIcon:c?t.jsx(R,{}):t.jsx(O,{}),"aria-pressed":c,"aria-labelledby":`${g} ${u}`,onClick:()=>{d((e=>!e)),a?.()}})}):null]})},exports.Radio=Ve,exports.RadioGroup=Ae,exports.RadioList=({label:n,caption:i,name:o,radios:a,defaultValue:s,onCheckedChange:l,errorMessage:c,horizontal:d,variant:u="default",required:p})=>{const h=`${n}. ${i?`${i}.`:""} ${p?"Required.":"Optional."} ${c?`Error: ${c}.`:""} `;return t.jsxs(e.Group,{tabIndex:0,css:Xt,"aria-roledescription":"group","aria-label":h,children:[c?t.jsx("div",{css:Qt}):null,t.jsxs("div",{css:(f=!!c,r.css`
3406
3406
  margin-left: ${f?"19px":"0px"};
3407
3407
  `),children:[t.jsxs("p",{css:Yt,"aria-label":n,children:[p&&t.jsx("span",{"aria-label":"required",children:"*"}),n]}),t.jsx("p",{css:Kt,"aria-label":i,children:i}),c?t.jsx("p",{css:en,"aria-label":c,children:c}):null,t.jsx("div",{css:Jt,children:t.jsx(Ae,{name:o,defaultValue:s,onChange:l,horizontal:d&&"card"!==u,children:a.map((e=>t.jsx(Ve,{css:"card"===u?tn:{},...e},e.value)))})})]})]});var f},exports.SSOButtons=J,exports.ScaleBar=({colors:e,values:n,subLabels:i,isGradient:o})=>{return t.jsxs("div",{css:rr,children:[o?t.jsx("div",{css:(a=lr(e),r.css`
3408
3408
  height: 20px;
package/dist/index.esm.js CHANGED
@@ -1,4 +1,4 @@
1
- import{createSystem as e,defaultConfig as t,Button as n,Box as r,Spinner as i,Icon as o,Menu as a,Portal as l,Group as s,Tooltip as c,Checkbox as d,CheckboxGroup as u,HStack as p,CheckboxCard as h,RadioCard as f,RadioGroup as g,Slider as v,For as m,Switch as x,Field as b,Input as y,Select as C,Tag as w,createListCollection as $,Textarea as k,Accordion as S,Popover as E,chakra as O,Flex as L,Text as _,Pagination as T,ButtonGroup as R,Table as P,Dialog as M,Breadcrumb as D,Tabs as N,Collapsible as j,createToaster as V,Toaster as I,Toast as z,Stack as A}from"@chakra-ui/react";import{jsxs as H,jsx as B,Fragment as F}from"@emotion/react/jsx-runtime";import*as Z from"react";import q,{forwardRef as G,useState as W,useEffect as U,useId as X,Children as Y,useRef as K,useLayoutEffect as J,useCallback as Q,createElement as ee,useMemo as te,useImperativeHandle as ne,useDebugValue as re,Fragment as ie}from"react";import{css as oe}from"@emotion/react";import{jsx as ae,jsxs as le,Fragment as se}from"react/jsx-runtime";import ce from"object-assign";import de,{createPortal as ue}from"react-dom";const pe={neutral:{100:{value:"#FFFFFF"},200:{value:"#F6F6F6"},300:{value:"#E7E6E6"},400:{value:"#C9C9C9"},500:{value:"#B0B0B0"},600:{value:"#A1A1A1"},700:{value:"#5C5959"},800:{value:"#3D3B3B"},900:{value:"#1A1919"}},primary:{100:{value:"#FFFBF2"},200:{value:"#FCEFD3"},300:{value:"#FADFA7"},400:{value:"#F5BF4F"},500:{value:"#F0AB00"},600:{value:"#DE9E00"},700:{value:"#855B00"},800:{value:"#5F4205"},900:{value:"#332300"}},secondary:{100:{value:"#F2F6FF"},200:{value:"#D7E0F7"},300:{value:"#B2C3F0"},400:{value:"#4F6CBA"},500:{value:"#3855A3"},600:{value:"#0A4298"},700:{value:"#123369"},800:{value:"#162241"},900:{value:"#0B1121"}},success:{100:{value:"#EBF5F2"},200:{value:"#D3EED1"},300:{value:"#C2E5DC"},500:{value:"#009E77"},900:{value:"#00664D"}},warning:{100:{value:"#FBF7EA"},200:{value:"#E3CC8F"},300:{value:"#EEDDA5"},500:{value:"#A88100"},900:{value:"#715804"}},error:{100:{value:"#FFEFED"},200:{value:"#EDA1A9"},300:{value:"#F6C5C1"},500:{value:"#C11101"},900:{value:"#8D0D01"}},accessible:{"text-on-primary-mids":{value:"#332300"},"text-on-secondary-mids":{value:"#F2F6FF"},"controls-on-neutral-lights":{value:"#855B00"},"controls-on-neutral-darks":{value:"#F5BF4F"}}},he=e(t,{theme:{tokens:{colors:pe}}}),fe=(e,t)=>he.tokens.getVar(`colors.${e}.${t}`)||pe?.[e]?.[t]?.value,ge=e=>oe`
1
+ import{createSystem as e,defaultConfig as t,Button as n,Box as r,Spinner as i,Icon as o,Menu as a,Portal as l,Group as s,Tooltip as c,Checkbox as d,CheckboxGroup as u,HStack as p,CheckboxCard as h,RadioCard as f,RadioGroup as g,Slider as v,For as m,Switch as x,Field as b,Input as y,Select as C,Tag as w,createListCollection as $,Textarea as k,Accordion as S,Popover as E,chakra as O,Flex as L,Text as _,Pagination as T,ButtonGroup as R,Table as P,Dialog as M,Breadcrumb as D,Tabs as N,Collapsible as j,createToaster as V,Toaster as I,Toast as z,Stack as A}from"@chakra-ui/react";import{jsxs as H,jsx as B,Fragment as F}from"@emotion/react/jsx-runtime";import*as Z from"react";import q,{forwardRef as G,useState as W,useEffect as U,useId as X,Children as Y,useMemo as K,useRef as J,useLayoutEffect as Q,useCallback as ee,createElement as te,useImperativeHandle as ne,useDebugValue as re,Fragment as ie}from"react";import{css as oe}from"@emotion/react";import{jsx as ae,jsxs as le,Fragment as se}from"react/jsx-runtime";import ce from"object-assign";import de,{createPortal as ue}from"react-dom";const pe={neutral:{100:{value:"#FFFFFF"},200:{value:"#F6F6F6"},300:{value:"#E7E6E6"},400:{value:"#C9C9C9"},500:{value:"#B0B0B0"},600:{value:"#A1A1A1"},700:{value:"#5C5959"},800:{value:"#3D3B3B"},900:{value:"#1A1919"}},primary:{100:{value:"#FFFBF2"},200:{value:"#FCEFD3"},300:{value:"#FADFA7"},400:{value:"#F5BF4F"},500:{value:"#F0AB00"},600:{value:"#DE9E00"},700:{value:"#855B00"},800:{value:"#5F4205"},900:{value:"#332300"}},secondary:{100:{value:"#F2F6FF"},200:{value:"#D7E0F7"},300:{value:"#B2C3F0"},400:{value:"#4F6CBA"},500:{value:"#3855A3"},600:{value:"#0A4298"},700:{value:"#123369"},800:{value:"#162241"},900:{value:"#0B1121"}},success:{100:{value:"#EBF5F2"},200:{value:"#D3EED1"},300:{value:"#C2E5DC"},500:{value:"#009E77"},900:{value:"#00664D"}},warning:{100:{value:"#FBF7EA"},200:{value:"#E3CC8F"},300:{value:"#EEDDA5"},500:{value:"#A88100"},900:{value:"#715804"}},error:{100:{value:"#FFEFED"},200:{value:"#EDA1A9"},300:{value:"#F6C5C1"},500:{value:"#C11101"},900:{value:"#8D0D01"}},accessible:{"text-on-primary-mids":{value:"#332300"},"text-on-secondary-mids":{value:"#F2F6FF"},"controls-on-neutral-lights":{value:"#855B00"},"controls-on-neutral-darks":{value:"#F5BF4F"}}},he=e(t,{theme:{tokens:{colors:pe}}}),fe=(e,t)=>he.tokens.getVar(`colors.${e}.${t}`)||pe?.[e]?.[t]?.value,ge=e=>oe`
2
2
  width: auto;
3
3
  height: ${"small"===e?"28px":"40px"};
4
4
  font-size: ${"small"===e?"12px":"16px"};
@@ -2026,7 +2026,7 @@ import{createSystem as e,defaultConfig as t,Button as n,Box as r,Spinner as i,Ic
2026
2026
  color: ${fe("neutral",600)};
2027
2027
  padding: 0 10px;
2028
2028
  }
2029
- `,wi=({type:e,label:t,caption:n,color:r,onActionClick:i,showActionButton:o,pointIcon:a=B(Ge,{color:"#006D2C"})})=>{const[l,s]=W(!0),c=X(),d=X(),u="line"===e,p="point"===e,h=l?"Hide":"Show",f=n?`${c} ${d}`:c;return H("div",{css:mi,children:[H("div",{css:xi,children:[H("div",{children:["raster"===e&&B("div",{css:fi(r)}),u&&B("div",{css:gi(r)}),p&&B("div",{css:vi(r),children:a})]}),H("div",{children:[B("p",{id:c,css:bi,children:t}),n?B("p",{id:d,css:yi,children:n}):null]})]}),i&&o?B("div",{css:Ci,children:B(ye,{type:"button",variant:"borderless",label:h,rightIcon:B(l?Pe:Re,{}),"aria-pressed":l,"aria-describedby":f,"aria-label":`${h} ${t}`,onClick:()=>{s((e=>!e)),i?.()}})}):null]})},$i=oe`
2029
+ `,wi=({type:e,label:t,caption:n,color:r,onActionClick:i,showActionButton:o,pointIcon:a=B(Ge,{color:"#006D2C"})})=>{const[l,s]=W(!0),c=X(),d=X(),u="raster"===e,p="line"===e,h="point"===e,f=X(),g=K((()=>`${e?`${e} layer`:"layer"}, ${t}${n?`, ${n}`:""}. Currently ${l?"visible":"hidden"}.`),[l,e,t,n]),v=l?"Hide":"Show";return H("div",{css:mi,children:[B("p",{id:f,css:{position:"absolute",width:1,height:1,margin:-1,padding:0,border:0,clip:"rect(0 0 0 0)",overflow:"hidden"},children:g}),H("div",{css:xi,children:[H("div",{children:[u&&B("div",{css:fi(r)}),p&&B("div",{css:gi(r)}),h&&B("div",{css:vi(r),children:a})]}),H("div",{children:[B("p",{id:c,css:bi,children:t}),n?B("p",{id:d,css:yi,children:n}):null]})]}),i&&o?B("div",{css:Ci,children:B(ye,{type:"button",variant:"borderless",label:v,rightIcon:B(l?Pe:Re,{}),"aria-pressed":l,"aria-labelledby":`${f} ${c}`,onClick:()=>{s((e=>!e)),i?.()}})}):null]})},$i=oe`
2030
2030
  width: 100%;
2031
2031
  display: flex;
2032
2032
  flex-direction: column;
@@ -2320,7 +2320,7 @@ import{createSystem as e,defaultConfig as t,Button as n,Box as r,Spinner as i,Ic
2320
2320
  bottom: 0;
2321
2321
  left: 0;
2322
2322
  border-top: 1px solid ${fe("neutral",300)};
2323
- `,ma=({header:e,content:t,footer:n,variant:r="fixed",width:i})=>{const[o,a]=W(void 0),[l,s]=W(void 0),c=K(null),d=K(null);U((()=>{a(c?.current?.getBoundingClientRect()?.height),s(d?.current?.getBoundingClientRect()?.height)}),[e,n]);return H("div",{css:[ua(i),"fixed"===r?pa:ha],children:[e?B("div",{css:fa,ref:c,children:e}):null,B("div",{css:ga(o,l),children:t}),n?B("div",{css:va,ref:d,children:n}):null]})};var xa,ba;!function(){if(ba)return xa;ba=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=function(e,t){var n=arguments.length;t=new Array(n>1?n-1:0);for(var r=1;r<n;r++)t[r-1]=arguments[r];var i=0,o="Warning: "+e.replace(/%s/g,(function(){return t[i++]}));"undefined"!=typeof console&&console.error(o);try{throw new Error(o)}catch(e){}};e=function(e,n,r){var i=arguments.length;r=new Array(i>2?i-2:0);for(var o=2;o<i;o++)r[o-2]=arguments[o];if(void 0===n)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");e||t.apply(null,[n].concat(r))}}xa=e}();var ya=Ca()?J:U;"production"!==process.env.NODE_ENV&&("undefined"!=typeof process?process:{env:{NODE_ENV:"development"}}).env;function Ca(){return!("undefined"==typeof window||!window.document||!window.document.createElement)}process.env.NODE_ENV,process.env.NODE_ENV,process.env.NODE_ENV;var wa=function(e){var t,n=e.children,r=e.type,i=void 0===r?"reach-portal":r,o=K(null),a=K(null),l=(t=W(Object.create(null))[1],Q((function(){t(Object.create(null))}),[]));return ya((function(){if(o.current){var e=o.current.ownerDocument;return a.current=null==e?void 0:e.createElement(i),e.body.appendChild(a.current),l(),function(){a.current&&a.current.ownerDocument&&a.current.ownerDocument.body.removeChild(a.current)}}}),[i,l]),a.current?ue(n,a.current):ee("span",{ref:o})};"production"!==process.env.NODE_ENV&&(wa.displayName="Portal");
2323
+ `,ma=({header:e,content:t,footer:n,variant:r="fixed",width:i})=>{const[o,a]=W(void 0),[l,s]=W(void 0),c=J(null),d=J(null);U((()=>{a(c?.current?.getBoundingClientRect()?.height),s(d?.current?.getBoundingClientRect()?.height)}),[e,n]);return H("div",{css:[ua(i),"fixed"===r?pa:ha],children:[e?B("div",{css:fa,ref:c,children:e}):null,B("div",{css:ga(o,l),children:t}),n?B("div",{css:va,ref:d,children:n}):null]})};var xa,ba;!function(){if(ba)return xa;ba=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=function(e,t){var n=arguments.length;t=new Array(n>1?n-1:0);for(var r=1;r<n;r++)t[r-1]=arguments[r];var i=0,o="Warning: "+e.replace(/%s/g,(function(){return t[i++]}));"undefined"!=typeof console&&console.error(o);try{throw new Error(o)}catch(e){}};e=function(e,n,r){var i=arguments.length;r=new Array(i>2?i-2:0);for(var o=2;o<i;o++)r[o-2]=arguments[o];if(void 0===n)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");e||t.apply(null,[n].concat(r))}}xa=e}();var ya=Ca()?Q:U;"production"!==process.env.NODE_ENV&&("undefined"!=typeof process?process:{env:{NODE_ENV:"development"}}).env;function Ca(){return!("undefined"==typeof window||!window.document||!window.document.createElement)}process.env.NODE_ENV,process.env.NODE_ENV,process.env.NODE_ENV;var wa=function(e){var t,n=e.children,r=e.type,i=void 0===r?"reach-portal":r,o=J(null),a=J(null),l=(t=W(Object.create(null))[1],ee((function(){t(Object.create(null))}),[]));return ya((function(){if(o.current){var e=o.current.ownerDocument;return a.current=null==e?void 0:e.createElement(i),e.body.appendChild(a.current),l(),function(){a.current&&a.current.ownerDocument&&a.current.ownerDocument.body.removeChild(a.current)}}}),[i,l]),a.current?ue(n,a.current):te("span",{ref:o})};"production"!==process.env.NODE_ENV&&(wa.displayName="Portal");
2324
2324
  /*! *****************************************************************************
2325
2325
  Copyright (c) Microsoft Corporation.
2326
2326
 
@@ -2334,7 +2334,7 @@ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
2334
2334
  LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
2335
2335
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
2336
2336
  PERFORMANCE OF THIS SOFTWARE.
2337
- ***************************************************************************** */var $a,ka,Sa=function(){return Sa=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Sa.apply(this,arguments)};function Ea(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n}function Oa(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function La(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function _a(e,t,n){if(2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}!function(e){e.Start="xstate.start",e.Stop="xstate.stop",e.Raise="xstate.raise",e.Send="xstate.send",e.Cancel="xstate.cancel",e.NullEvent="",e.Assign="xstate.assign",e.After="xstate.after",e.DoneState="done.state",e.DoneInvoke="done.invoke",e.Log="xstate.log",e.Init="xstate.init",e.Invoke="xstate.invoke",e.ErrorExecution="error.execution",e.ErrorCommunication="error.communication",e.ErrorPlatform="error.platform",e.ErrorCustom="xstate.error",e.Update="xstate.update",e.Pure="xstate.pure",e.Choose="xstate.choose"}($a||($a={})),function(e){e.Parent="#_parent",e.Internal="#_internal"}(ka||(ka={}));var Ta=$a.Start,Ra=$a.Stop,Pa=$a.Raise,Ma=$a.Send,Da=$a.Cancel,Na=$a.NullEvent,ja=$a.Assign;$a.After,$a.DoneState;var Va=$a.Log,Ia=$a.Init,za=$a.Invoke;$a.ErrorExecution;var Aa,Ha=$a.ErrorPlatform,Ba=$a.ErrorCustom,Fa=$a.Update,Za=$a.Choose,qa=$a.Pure,Ga={},Wa="xstate.guard",Ua="production"===process.env.NODE_ENV;function Xa(e,t,n){void 0===n&&(n=".");var r=Ja(e,n),i=Ja(t,n);return fl(i)?!!fl(r)&&i===r:fl(r)?r in i:Object.keys(r).every((function(e){return e in i&&Xa(r[e],i[e])}))}function Ya(e){try{return fl(e)||"number"==typeof e?"".concat(e):e.type}catch(e){throw new Error("Events must be strings or objects with a string event.type property.")}}function Ka(e,t){try{return pl(e)?e:e.toString().split(t)}catch(t){throw new Error("'".concat(e,"' is not a valid state path."))}}function Ja(e,t){return"object"==typeof(n=e)&&"value"in n&&"context"in n&&"event"in n&&"_event"in n?e.value:pl(e)?Qa(e):"string"!=typeof e?e:Qa(Ka(e,t));var n}function Qa(e){if(1===e.length)return e[0];for(var t={},n=t,r=0;r<e.length-1;r++)r===e.length-2?n[e[r]]=e[r+1]:(n[e[r]]={},n=n[e[r]]);return t}function el(e,t){for(var n={},r=Object.keys(e),i=0;i<r.length;i++){var o=r[i];n[o]=t(e[o],o,e,i)}return n}function tl(e,t,n){var r,i,o={};try{for(var a=Oa(Object.keys(e)),l=a.next();!l.done;l=a.next()){var s=l.value,c=e[s];n(c)&&(o[s]=t(c,s,e))}}catch(e){r={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}return o}var nl=function(e){return function(t){var n,r,i=t;try{for(var o=Oa(e),a=o.next();!a.done;a=o.next()){i=i[a.value]}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}return i}};function rl(e){return e?fl(e)?[[e]]:il(Object.keys(e).map((function(t){var n=e[t];return"string"==typeof n||n&&Object.keys(n).length?rl(e[t]).map((function(e){return[t].concat(e)})):[[t]]}))):[[]]}function il(e){var t;return(t=[]).concat.apply(t,_a([],La(e),!1))}function ol(e){return pl(e)?e:[e]}function al(e){return void 0===e?[]:ol(e)}function ll(e,t,n){var r,i;if(hl(e))return e(t,n.data);var o={};try{for(var a=Oa(Object.keys(e)),l=a.next();!l.done;l=a.next()){var s=l.value,c=e[s];hl(c)?o[s]=c(t,n.data):o[s]=c}}catch(e){r={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}return o}function sl(e){return e instanceof Promise||!(null===e||!hl(e)&&"object"!=typeof e||!hl(e.then))}function cl(e,t){return el(e.states,(function(e,n){if(e){var r=(fl(t)?void 0:t[n])||(e?e.current:void 0);if(r)return{current:r,states:cl(e,r)}}}))}function dl(e,t,n,r){Ua||ul(!!e,"Attempting to update undefined context");var i=e?n.reduce((function(e,n){var i,o,a=n.assignment,l={state:r,action:n,_event:t},s={};if(hl(a))s=a(e,t.data,l);else try{for(var c=Oa(Object.keys(a)),d=c.next();!d.done;d=c.next()){var u=d.value,p=a[u];s[u]=hl(p)?p(e,t.data,l):p}}catch(e){i={error:e}}finally{try{d&&!d.done&&(o=c.return)&&o.call(c)}finally{if(i)throw i.error}}return Object.assign({},e,s)}),e):e;return i}var ul=function(){};function pl(e){return Array.isArray(e)}function hl(e){return"function"==typeof e}function fl(e){return"string"==typeof e}function gl(e,t){if(e)return fl(e)?{type:Wa,name:e,predicate:t?t[e]:void 0}:hl(e)?{type:Wa,name:e.name,predicate:e}:e}Ua||(ul=function(e,t){var n=e instanceof Error?e:void 0;if((n||!e)&&void 0!==console){var r=["Warning: ".concat(t)];n&&r.push(n),console.warn.apply(console,r)}});var vl=function(){return"function"==typeof Symbol&&Symbol.observable||"@@observable"}();function ml(e){return!!e&&"__xstatenode"in e}function xl(e,t){return fl(e)||"number"==typeof e?Sa({type:e},t):e}function bl(e,t){if(!fl(e)&&"$$type"in e&&"scxml"===e.$$type)return e;var n=xl(e);return Sa({name:n.type,data:n,$$type:"scxml",type:"external"},t)}function yl(e,t){return ol(t).map((function(t){return void 0===t||"string"==typeof t||ml(t)?{target:t,event:e}:Sa(Sa({},t),{event:e})}))}function Cl(e,t,n,r,i){var o=e.options.guards,a={state:i,cond:t,_event:r};if(t.type===Wa)return((null==o?void 0:o[t.name])||t.predicate)(n,r.data,a);var l=null==o?void 0:o[t.type];if(!l)throw new Error("Guard '".concat(t.type,"' is not implemented on machine '").concat(e.id,"'."));return l(n,r.data,a)}function wl(e){return"string"==typeof e?{type:e}:e}function $l(e,t,n){var r=function(){},i="object"==typeof e,o=i?e:null;return{next:((i?e.next:e)||r).bind(o),error:((i?e.error:t)||r).bind(o),complete:((i?e.complete:n)||r).bind(o)}}function kl(e,t){return"".concat(e,":invocation[").concat(t,"]")}function Sl(e){return(e.type===Pa||e.type===Ma&&e.to===ka.Internal)&&"number"!=typeof e.delay}(Aa={})[vl]=function(){return this},Aa[Symbol.observable]=function(){return this};var El=bl({type:Ia});function Ol(e,t){return t&&t[e]||void 0}function Ll(e,t){var n;if(fl(e)||"number"==typeof e)n=hl(r=Ol(e,t))?{type:e,exec:r}:r||{type:e,exec:void 0};else if(hl(e))n={type:e.name||e.toString(),exec:e};else{var r;if(hl(r=Ol(e.type,t)))n=Sa(Sa({},e),{exec:r});else if(r){var i=r.type||e.type;n=Sa(Sa(Sa({},r),e),{type:i})}else n=e}return n}var _l=function(e,t){return e?(pl(e)?e:[e]).map((function(e){return Ll(e,t)})):[]};function Tl(e){var t=Ll(e);return Sa(Sa({id:fl(e)?e:t.id},t),{type:t.type})}function Rl(e,t){var n="".concat($a.DoneState,".").concat(e),r={type:n,data:t,toString:function(){return n}};return r}function Pl(e,t){var n="".concat($a.DoneInvoke,".").concat(e),r={type:n,data:t,toString:function(){return n}};return r}function Ml(e,t){var n="".concat($a.ErrorPlatform,".").concat(e),r={type:n,data:t,toString:function(){return n}};return r}function Dl(e,t,n,r,i,o,a){void 0===a&&(a=!1);var l=a?[]:function(e){var t,n,r=[];try{for(var i=Oa(e),o=i.next();!o.done;o=i.next())for(var a=o.value,l=0;l<a.actions.length;)a.actions[l].type!==ja?l++:(r.push(a.actions[l]),a.actions.splice(l,1))}catch(e){t={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r}(i),s=l.length?dl(n,r,l,t):n,c=a?[n]:void 0,d=[];function u(i,l){var u;switch(l.type){case Pa:var p=function(e,t,n,r){var i,o={_event:n},a=bl(hl(e.event)?e.event(t,n.data,o):e.event);if(fl(e.delay)){var l=r&&r[e.delay];i=hl(l)?l(t,n.data,o):l}else i=hl(e.delay)?e.delay(t,n.data,o):e.delay;return Sa(Sa({},e),{type:Pa,_event:a,delay:i})}(l,s,r,e.options.delays);return o&&"number"==typeof p.delay&&o(p,s,r),p;case Ma:var h=function(e,t,n,r){var i,o={_event:n},a=bl(hl(e.event)?e.event(t,n.data,o):e.event);if(fl(e.delay)){var l=r&&r[e.delay];i=hl(l)?l(t,n.data,o):l}else i=hl(e.delay)?e.delay(t,n.data,o):e.delay;var s=hl(e.to)?e.to(t,n.data,o):e.to;return Sa(Sa({},e),{to:s,_event:a,event:a.data,delay:i})}(l,s,r,e.options.delays);if(!Ua){var f=l.delay;ul(!fl(f)||"number"==typeof h.delay,"No delay reference for delay expression '".concat(f,"' was found on machine '").concat(e.id,"'"))}return o&&h.to!==ka.Internal&&("entry"===i?d.push(h):o(h,s,r)),h;case Va:var g=function(e,t,n){return Sa(Sa({},e),{value:fl(e.expr)?e.expr:e.expr(t,n.data,{_event:n})})}(l,s,r);return null==o||o(g,s,r),g;case Za:if(!(b=null===(u=l.conds.find((function(n){var i=gl(n.cond,e.options.guards);return!i||Cl(e,i,s,r,o?void 0:t)})))||void 0===u?void 0:u.actions))return[];var v=La(Dl(e,t,s,r,[{type:i,actions:_l(al(b),e.options.actions)}],o,a),2),m=v[0],x=v[1];return s=x,null==c||c.push(s),m;case qa:var b;if(!(b=l.get(s,r.data)))return[];var y=La(Dl(e,t,s,r,[{type:i,actions:_l(al(b),e.options.actions)}],o,a),2),C=y[0],w=y[1];return s=w,null==c||c.push(s),C;case Ra:g=function(e,t,n){var r=hl(e.activity)?e.activity(t,n.data):e.activity,i="string"==typeof r?{id:r}:r;return{type:$a.Stop,activity:i}}(l,s,r);return null==o||o(g,n,r),g;case ja:s=dl(s,r,[l],o?void 0:t),null==c||c.push(s);break;default:var $=Ll(l,e.options.actions),k=$.exec;if(o)o($,s,r);else if(k&&c){var S=c.length-1,E=Sa(Sa({},$),{exec:function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];k.apply(void 0,_a([c[S]],La(t),!1))}});$=E}return $}}var p=il(i.map((function(e){var t,n,i=[];try{for(var a=Oa(e.actions),l=a.next();!l.done;l=a.next()){var c=l.value,p=u(e.type,c);p&&(i=i.concat(p))}}catch(e){t={error:e}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}return d.forEach((function(e){o(e,s,r)})),d.length=0,i})));return[p,s]}var Nl=function(e,t){return t(e)};function jl(e){var t;return(t={id:e,send:function(){},subscribe:function(){return{unsubscribe:function(){}}},getSnapshot:function(){},toJSON:function(){return{id:e}}})[vl]=function(){return this},t}function Vl(e,t,n){var r=jl(t);if(r.deferred=!0,ml(e)){var i=r.state=Nl(void 0,(function(){return(n?e.withContext(n):e).initialState}));r.getSnapshot=function(){return i}}return r}var Il=function(e){return"atomic"===e.type||"final"===e.type};function zl(e){return Object.keys(e.states).map((function(t){return e.states[t]}))}function Al(e){return zl(e).filter((function(e){return"history"!==e.type}))}function Hl(e){var t=[e];return Il(e)?t:t.concat(il(Al(e).map(Hl)))}function Bl(e,t){var n,r,i,o,a,l,s,c,d=Zl(new Set(e)),u=new Set(t);try{for(var p=Oa(u),h=p.next();!h.done;h=p.next())for(var f=($=h.value).parent;f&&!u.has(f);)u.add(f),f=f.parent}catch(e){n={error:e}}finally{try{h&&!h.done&&(r=p.return)&&r.call(p)}finally{if(n)throw n.error}}var g=Zl(u);try{for(var v=Oa(u),m=v.next();!m.done;m=v.next()){if("compound"!==($=m.value).type||g.get($)&&g.get($).length){if("parallel"===$.type)try{for(var x=(a=void 0,Oa(Al($))),b=x.next();!b.done;b=x.next()){var y=b.value;u.has(y)||(u.add(y),d.get(y)?d.get(y).forEach((function(e){return u.add(e)})):y.initialStateNodes.forEach((function(e){return u.add(e)})))}}catch(e){a={error:e}}finally{try{b&&!b.done&&(l=x.return)&&l.call(x)}finally{if(a)throw a.error}}}else d.get($)?d.get($).forEach((function(e){return u.add(e)})):$.initialStateNodes.forEach((function(e){return u.add(e)}))}}catch(e){i={error:e}}finally{try{m&&!m.done&&(o=v.return)&&o.call(v)}finally{if(i)throw i.error}}try{for(var C=Oa(u),w=C.next();!w.done;w=C.next()){var $;for(f=($=w.value).parent;f&&!u.has(f);)u.add(f),f=f.parent}}catch(e){s={error:e}}finally{try{w&&!w.done&&(c=C.return)&&c.call(C)}finally{if(s)throw s.error}}return u}function Fl(e,t){var n=t.get(e);if(!n)return{};if("compound"===e.type){var r=n[0];if(!r)return{};if(Il(r))return r.key}var i={};return n.forEach((function(e){i[e.key]=Fl(e,t)})),i}function Zl(e){var t,n,r=new Map;try{for(var i=Oa(e),o=i.next();!o.done;o=i.next()){var a=o.value;r.has(a)||r.set(a,[]),a.parent&&(r.has(a.parent)||r.set(a.parent,[]),r.get(a.parent).push(a))}}catch(e){t={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r}function ql(e,t){return Fl(e,Zl(Bl([e],t)))}function Gl(e,t){return Array.isArray(e)?e.some((function(e){return e===t})):e instanceof Set&&e.has(t)}function Wl(e,t){return"compound"===t.type?Al(t).some((function(t){return"final"===t.type&&Gl(e,t)})):"parallel"===t.type&&Al(t).every((function(t){return Wl(e,t)}))}function Ul(e){return new Set(il(e.map((function(e){return e.tags}))))}function Xl(e,t){if(e===t)return!0;if(void 0===e||void 0===t)return!1;if(fl(e)||fl(t))return e===t;var n=Object.keys(e),r=Object.keys(t);return n.length===r.length&&n.every((function(n){return Xl(e[n],t[n])}))}var Yl=function(){function e(e){var t,n,r=this;this.actions=[],this.activities=Ga,this.meta={},this.events=[],this.value=e.value,this.context=e.context,this._event=e._event,this._sessionid=e._sessionid,this.event=this._event.data,this.historyValue=e.historyValue,this.history=e.history,this.actions=e.actions||[],this.activities=e.activities||Ga,this.meta=(void 0===(n=e.configuration)&&(n=[]),n.reduce((function(e,t){return void 0!==t.meta&&(e[t.id]=t.meta),e}),{})),this.events=e.events||[],this.matches=this.matches.bind(this),this.toStrings=this.toStrings.bind(this),this.configuration=e.configuration,this.transitions=e.transitions,this.children=e.children,this.done=!!e.done,this.tags=null!==(t=Array.isArray(e.tags)?new Set(e.tags):e.tags)&&void 0!==t?t:new Set,this.machine=e.machine,Object.defineProperty(this,"nextEvents",{get:function(){return function(e){return _a([],La(new Set(il(_a([],La(e.map((function(e){return e.ownEvents}))),!1)))),!1)}(r.configuration)}})}return e.from=function(t,n){return t instanceof e?t.context!==n?new e({value:t.value,context:n,_event:t._event,_sessionid:null,historyValue:t.historyValue,history:t.history,actions:[],activities:t.activities,events:[],configuration:[],transitions:[],children:{}}):t:new e({value:t,context:n,_event:El,_sessionid:null,historyValue:void 0,history:void 0,actions:[],activities:void 0,events:[],configuration:[],transitions:[],children:{}})},e.create=function(t){return new e(t)},e.inert=function(t,n){if(t instanceof e){if(!t.actions.length)return t;var r=El;return new e({value:t.value,context:n,_event:r,_sessionid:null,historyValue:t.historyValue,history:t.history,activities:t.activities,configuration:t.configuration,transitions:[],children:{}})}return e.from(t,n)},e.prototype.toStrings=function(e,t){var n=this;if(void 0===e&&(e=this.value),void 0===t&&(t="."),fl(e))return[e];var r=Object.keys(e);return r.concat.apply(r,_a([],La(r.map((function(r){return n.toStrings(e[r],t).map((function(e){return r+t+e}))}))),!1))},e.prototype.toJSON=function(){var e=this;e.configuration,e.transitions;var t=e.tags;e.machine;var n=Ea(e,["configuration","transitions","tags","machine"]);return Sa(Sa({},n),{tags:Array.from(t)})},e.prototype.matches=function(e){return Xa(e,this.value)},e.prototype.hasTag=function(e){return this.tags.has(e)},e.prototype.can=function(e){var t;Ua&&ul(!!this.machine,"state.can(...) used outside of a machine-created State object; this will always return false.");var n=null===(t=this.machine)||void 0===t?void 0:t.getTransitionData(this,e);return!!(null==n?void 0:n.transitions.length)&&n.transitions.some((function(e){return void 0!==e.target||e.actions.length}))},e}(),Kl={deferEvents:!1},Jl=function(){function e(e){this.processingEvent=!1,this.queue=[],this.initialized=!1,this.options=Sa(Sa({},Kl),e)}return e.prototype.initialize=function(e){if(this.initialized=!0,e){if(!this.options.deferEvents)return void this.schedule(e);this.process(e)}this.flushEvents()},e.prototype.schedule=function(e){if(this.initialized&&!this.processingEvent){if(0!==this.queue.length)throw new Error("Event queue should be empty when it is not processing events");this.process(e),this.flushEvents()}else this.queue.push(e)},e.prototype.clear=function(){this.queue=[]},e.prototype.flushEvents=function(){for(var e=this.queue.shift();e;)this.process(e),e=this.queue.shift()},e.prototype.process=function(e){this.processingEvent=!0;try{e()}catch(e){throw this.clear(),e}finally{this.processingEvent=!1}},e}(),Ql=new Map,es=0,ts=function(){return"x:".concat(es++)},ns=function(e,t){return Ql.set(e,t),e},rs=function(e){return Ql.get(e)},is=function(e){Ql.delete(e)};function os(){return"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:void(Ua||console.warn("XState could not find a global object in this environment. Please let the maintainers know and raise an issue here: https://github.com/statelyai/xstate/issues"))}function as(e){if(os()){var t=function(){var e=os();if(e&&"__xstate__"in e)return e.__xstate__}();t&&t.register(e)}}function ls(e,t){void 0===t&&(t={});var n=e.initialState,r=new Set,i=[],o=!1,a=function(e){var t;return Sa(((t={subscribe:function(){return{unsubscribe:function(){}}},id:"anonymous",getSnapshot:function(){}})[vl]=function(){return this},t),e)}({id:t.id,send:function(t){i.push(t),function(){if(!o){for(o=!0;i.length>0;){var t=i.shift();n=e.transition(n,t,l),r.forEach((function(e){return e.next(n)}))}o=!1}}()},getSnapshot:function(){return n},subscribe:function(e,t,i){var o=$l(e,t,i);return r.add(o),o.next(n),{unsubscribe:function(){r.delete(o)}}}}),l={parent:t.parent,self:a,id:t.id||"anonymous",observers:r};return n=e.start?e.start(l):n,a}var ss,cs={sync:!1,autoForward:!1};!function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"}(ss||(ss={}));var ds=function(){function e(t,n){void 0===n&&(n=e.defaultOptions);var r=this;this.machine=t,this.delayedEventsMap={},this.listeners=new Set,this.contextListeners=new Set,this.stopListeners=new Set,this.doneListeners=new Set,this.eventListeners=new Set,this.sendListeners=new Set,this.initialized=!1,this.status=ss.NotStarted,this.children=new Map,this.forwardTo=new Set,this._outgoingQueue=[],this.init=this.start,this.send=function(e,t){if(pl(e))return r.batch(e),r.state;var n=bl(xl(e,t));if(r.status===ss.Stopped)return Ua||ul(!1,'Event "'.concat(n.name,'" was sent to stopped service "').concat(r.machine.id,'". This service has already reached its final state, and will not transition.\nEvent: ').concat(JSON.stringify(n.data))),r.state;if(r.status!==ss.Running&&!r.options.deferEvents)throw new Error('Event "'.concat(n.name,'" was sent to uninitialized service "').concat(r.machine.id,'". Make sure .start() is called for this service, or set { deferEvents: true } in the service options.\nEvent: ').concat(JSON.stringify(n.data)));return r.scheduler.schedule((function(){r.forward(n);var e=r._nextState(n);r.update(e,n)})),r._state},this.sendTo=function(e,t,n){var i,o=r.parent&&(t===ka.Parent||r.parent.id===t),a=o?r.parent:fl(t)?t===ka.Internal?r:r.children.get(t)||rs(t):(i=t)&&"function"==typeof i.send?t:void 0;if(a)if("machine"in a){if(r.status!==ss.Stopped||r.parent!==a||r.state.done){var l=Sa(Sa({},e),{name:e.name===Ba?"".concat(Ml(r.id)):e.name,origin:r.sessionId});!n&&r.machine.config.predictableActionArguments?r._outgoingQueue.push([a,l]):a.send(l)}}else!n&&r.machine.config.predictableActionArguments?r._outgoingQueue.push([a,e.data]):a.send(e.data);else{if(!o)throw new Error("Unable to send event to child '".concat(t,"' from service '").concat(r.id,"'."));Ua||ul(!1,"Service '".concat(r.id,"' has no parent: unable to send event ").concat(e.type))}},this._exec=function(e,t,n,i){void 0===i&&(i=r.machine.options.actions);var o=e.exec||Ol(e.type,i),a=hl(o)?o:o?o.exec:e.exec;if(a)try{return a(t,n.data,r.machine.config.predictableActionArguments?{action:e,_event:n}:{action:e,state:r.state,_event:n})}catch(e){throw r.parent&&r.parent.send({type:"xstate.error",data:e}),e}switch(e.type){case Pa:var l=e;r.defer(l);break;case Ma:var s=e;if("number"==typeof s.delay)return void r.defer(s);s.to?r.sendTo(s._event,s.to,n===El):r.send(s._event);break;case Da:r.cancel(e.sendId);break;case Ta:if(r.status!==ss.Running)return;var c=e.activity;if(!r.machine.config.predictableActionArguments&&!r.state.activities[c.id||c.type])break;if(c.type===$a.Invoke){var d=wl(c.src),u=r.machine.options.services?r.machine.options.services[d.type]:void 0,p=c.id,h=c.data;Ua||ul(!("forward"in c),"`forward` property is deprecated (found in invocation of '".concat(c.src,"' in in machine '").concat(r.machine.id,"'). ")+"Please use `autoForward` instead.");var f="autoForward"in c?c.autoForward:!!c.forward;if(!u)return void(Ua||ul(!1,"No service found for invocation '".concat(c.src,"' in machine '").concat(r.machine.id,"'.")));var g=h?ll(h,t,n):void 0;if("string"==typeof u)return;var v=hl(u)?u(t,n.data,{data:g,src:d,meta:c.meta}):u;if(!v)return;var m=void 0;ml(v)&&(v=g?v.withContext(g):v,m={autoForward:f}),r.spawn(v,p,m)}else r.spawnActivity(c);break;case Ra:r.stopChild(e.activity.id);break;case Va:var x=e,b=x.label,y=x.value;b?r.logger(b,y):r.logger(y);break;default:Ua||ul(!1,"No implementation found for action type '".concat(e.type,"'"))}};var i=Sa(Sa({},e.defaultOptions),n),o=i.clock,a=i.logger,l=i.parent,s=i.id,c=void 0!==s?s:t.id;this.id=c,this.logger=a,this.clock=o,this.parent=l,this.options=i,this.scheduler=new Jl({deferEvents:this.options.deferEvents}),this.sessionId=ts()}return Object.defineProperty(e.prototype,"initialState",{get:function(){var e=this;return this._initialState?this._initialState:Nl(this,(function(){return e._initialState=e.machine.initialState,e._initialState}))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"state",{get:function(){return Ua||ul(this.status!==ss.NotStarted,"Attempted to read state from uninitialized service '".concat(this.id,"'. Make sure the service is started first.")),this._state},enumerable:!1,configurable:!0}),e.prototype.execute=function(e,t){var n,r;try{for(var i=Oa(e.actions),o=i.next();!o.done;o=i.next()){var a=o.value;this.exec(a,e,t)}}catch(e){n={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}},e.prototype.update=function(e,t){var n,r,i,o,a,l,s,c,d=this;if(e._sessionid=this.sessionId,this._state=e,this.machine.config.predictableActionArguments&&t!==El||!this.options.execute)for(var u=void 0;u=this._outgoingQueue.shift();)u[0].send(u[1]);else this.execute(this.state);if(this.children.forEach((function(e){d.state.children[e.id]=e})),this.devTools&&this.devTools.send(t.data,e),e.event)try{for(var p=Oa(this.eventListeners),h=p.next();!h.done;h=p.next()){(0,h.value)(e.event)}}catch(e){n={error:e}}finally{try{h&&!h.done&&(r=p.return)&&r.call(p)}finally{if(n)throw n.error}}try{for(var f=Oa(this.listeners),g=f.next();!g.done;g=f.next()){(0,g.value)(e,e.event)}}catch(e){i={error:e}}finally{try{g&&!g.done&&(o=f.return)&&o.call(f)}finally{if(i)throw i.error}}try{for(var v=Oa(this.contextListeners),m=v.next();!m.done;m=v.next()){(0,m.value)(this.state.context,this.state.history?this.state.history.context:void 0)}}catch(e){a={error:e}}finally{try{m&&!m.done&&(l=v.return)&&l.call(v)}finally{if(a)throw a.error}}if(this.state.done){var x=e.configuration.find((function(e){return"final"===e.type&&e.parent===d.machine})),b=x&&x.doneData?ll(x.doneData,e.context,t):void 0;this._doneEvent=Pl(this.id,b);try{for(var y=Oa(this.doneListeners),C=y.next();!C.done;C=y.next()){(0,C.value)(this._doneEvent)}}catch(e){s={error:e}}finally{try{C&&!C.done&&(c=y.return)&&c.call(y)}finally{if(s)throw s.error}}this._stop(),this._stopChildren(),is(this.sessionId)}},e.prototype.onTransition=function(e){return this.listeners.add(e),this.status===ss.Running&&e(this.state,this.state.event),this},e.prototype.subscribe=function(e,t,n){var r=this,i=$l(e,t,n);this.listeners.add(i.next),this.status!==ss.NotStarted&&i.next(this.state);var o=function(){r.doneListeners.delete(o),r.stopListeners.delete(o),i.complete()};return this.status===ss.Stopped?i.complete():(this.onDone(o),this.onStop(o)),{unsubscribe:function(){r.listeners.delete(i.next),r.doneListeners.delete(o),r.stopListeners.delete(o)}}},e.prototype.onEvent=function(e){return this.eventListeners.add(e),this},e.prototype.onSend=function(e){return this.sendListeners.add(e),this},e.prototype.onChange=function(e){return this.contextListeners.add(e),this},e.prototype.onStop=function(e){return this.stopListeners.add(e),this},e.prototype.onDone=function(e){return this.status===ss.Stopped&&this._doneEvent?e(this._doneEvent):this.doneListeners.add(e),this},e.prototype.off=function(e){return this.listeners.delete(e),this.eventListeners.delete(e),this.sendListeners.delete(e),this.stopListeners.delete(e),this.doneListeners.delete(e),this.contextListeners.delete(e),this},e.prototype.start=function(e){var t=this;if(this.status===ss.Running)return this;this.machine._init(),ns(this.sessionId,this),this.initialized=!0,this.status=ss.Running;var n=void 0===e?this.initialState:Nl(this,(function(){return"object"==typeof(n=e)&&null!==n&&"value"in n&&"_event"in n?t.machine.resolveState(e):t.machine.resolveState(Yl.from(e,t.machine.context));var n}));return this.options.devTools&&this.attachDev(),this.scheduler.initialize((function(){t.update(n,El)})),this},e.prototype._stopChildren=function(){this.children.forEach((function(e){hl(e.stop)&&e.stop()})),this.children.clear()},e.prototype._stop=function(){var e,t,n,r,i,o,a,l,s,c;try{for(var d=Oa(this.listeners),u=d.next();!u.done;u=d.next()){var p=u.value;this.listeners.delete(p)}}catch(t){e={error:t}}finally{try{u&&!u.done&&(t=d.return)&&t.call(d)}finally{if(e)throw e.error}}try{for(var h=Oa(this.stopListeners),f=h.next();!f.done;f=h.next()){(p=f.value)(),this.stopListeners.delete(p)}}catch(e){n={error:e}}finally{try{f&&!f.done&&(r=h.return)&&r.call(h)}finally{if(n)throw n.error}}try{for(var g=Oa(this.contextListeners),v=g.next();!v.done;v=g.next()){p=v.value;this.contextListeners.delete(p)}}catch(e){i={error:e}}finally{try{v&&!v.done&&(o=g.return)&&o.call(g)}finally{if(i)throw i.error}}try{for(var m=Oa(this.doneListeners),x=m.next();!x.done;x=m.next()){p=x.value;this.doneListeners.delete(p)}}catch(e){a={error:e}}finally{try{x&&!x.done&&(l=m.return)&&l.call(m)}finally{if(a)throw a.error}}if(!this.initialized)return this;this.initialized=!1,this.status=ss.Stopped,this._initialState=void 0;try{for(var b=Oa(Object.keys(this.delayedEventsMap)),y=b.next();!y.done;y=b.next()){var C=y.value;this.clock.clearTimeout(this.delayedEventsMap[C])}}catch(e){s={error:e}}finally{try{y&&!y.done&&(c=b.return)&&c.call(b)}finally{if(s)throw s.error}}this.scheduler.clear(),this.scheduler=new Jl({deferEvents:this.options.deferEvents})},e.prototype.stop=function(){var e=this,t=this.scheduler;return this._stop(),t.schedule((function(){var t;if(!(null===(t=e._state)||void 0===t?void 0:t.done)){var n=bl({type:"xstate.stop"}),r=Nl(e,(function(){var t=il(_a([],La(e.state.configuration),!1).sort((function(e,t){return t.order-e.order})).map((function(t){return _l(t.onExit,e.machine.options.actions)}))),r=La(Dl(e.machine,e.state,e.state.context,n,[{type:"exit",actions:t}],e.machine.config.predictableActionArguments?e._exec:void 0,e.machine.config.predictableActionArguments||e.machine.config.preserveActionOrder),2),i=r[0],o=r[1],a=new Yl({value:e.state.value,context:o,_event:n,_sessionid:e.sessionId,historyValue:void 0,history:e.state,actions:i.filter((function(e){return!Sl(e)})),activities:{},events:[],configuration:[],transitions:[],children:{},done:e.state.done,tags:e.state.tags,machine:e.machine});return a.changed=!0,a}));e.update(r,n),e._stopChildren(),is(e.sessionId)}})),this},e.prototype.batch=function(e){var t=this;if(this.status===ss.NotStarted&&this.options.deferEvents)Ua||ul(!1,"".concat(e.length,' event(s) were sent to uninitialized service "').concat(this.machine.id,'" and are deferred. Make sure .start() is called for this service.\nEvent: ').concat(JSON.stringify(event)));else if(this.status!==ss.Running)throw new Error("".concat(e.length,' event(s) were sent to uninitialized service "').concat(this.machine.id,'". Make sure .start() is called for this service, or set { deferEvents: true } in the service options.'));if(e.length){var n=!!this.machine.config.predictableActionArguments&&this._exec;this.scheduler.schedule((function(){var r,i,o=t.state,a=!1,l=[],s=function(e){var r=bl(e);t.forward(r),o=Nl(t,(function(){return t.machine.transition(o,r,void 0,n||void 0)})),l.push.apply(l,_a([],La(t.machine.config.predictableActionArguments?o.actions:o.actions.map((function(e){return function(e,t){var n=e.exec;return Sa(Sa({},e),{exec:void 0!==n?function(){return n(t.context,t.event,{action:e,state:t,_event:t._event})}:void 0})}(e,o)}))),!1)),a=a||!!o.changed};try{for(var c=Oa(e),d=c.next();!d.done;d=c.next()){s(d.value)}}catch(e){r={error:e}}finally{try{d&&!d.done&&(i=c.return)&&i.call(c)}finally{if(r)throw r.error}}o.changed=a,o.actions=l,t.update(o,bl(e[e.length-1]))}))}},e.prototype.sender=function(e){return this.send.bind(this,e)},e.prototype._nextState=function(e,t){var n=this;void 0===t&&(t=!!this.machine.config.predictableActionArguments&&this._exec);var r=bl(e);if(0===r.name.indexOf(Ha)&&!this.state.nextEvents.some((function(e){return 0===e.indexOf(Ha)})))throw r.data.data;return Nl(this,(function(){return n.machine.transition(n.state,r,void 0,t||void 0)}))},e.prototype.nextState=function(e){return this._nextState(e,!1)},e.prototype.forward=function(e){var t,n;try{for(var r=Oa(this.forwardTo),i=r.next();!i.done;i=r.next()){var o=i.value,a=this.children.get(o);if(!a)throw new Error("Unable to forward event '".concat(e,"' from interpreter '").concat(this.id,"' to nonexistant child '").concat(o,"'."));a.send(e)}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}},e.prototype.defer=function(e){var t=this,n=this.clock.setTimeout((function(){"to"in e&&e.to?t.sendTo(e._event,e.to,!0):t.send(e._event)}),e.delay);e.id&&(this.delayedEventsMap[e.id]=n)},e.prototype.cancel=function(e){this.clock.clearTimeout(this.delayedEventsMap[e]),delete this.delayedEventsMap[e]},e.prototype.exec=function(e,t,n){void 0===n&&(n=this.machine.options.actions),this._exec(e,t.context,t._event,n)},e.prototype.removeChild=function(e){var t;this.children.delete(e),this.forwardTo.delete(e),null===(t=this.state)||void 0===t||delete t.children[e]},e.prototype.stopChild=function(e){var t=this.children.get(e);t&&(this.removeChild(e),hl(t.stop)&&t.stop())},e.prototype.spawn=function(e,t,n){if(this.status!==ss.Running)return Vl(e,t);if(sl(e))return this.spawnPromise(Promise.resolve(e),t);if(hl(e))return this.spawnCallback(e,t);if(function(e){try{return"function"==typeof e.send}catch(e){return!1}}(i=e)&&"id"in i)return this.spawnActor(e,t);if(function(e){try{return"subscribe"in e&&hl(e.subscribe)}catch(e){return!1}}(e))return this.spawnObservable(e,t);if(ml(e))return this.spawnMachine(e,Sa(Sa({},n),{id:t}));if(null!==(r=e)&&"object"==typeof r&&"transition"in r&&"function"==typeof r.transition)return this.spawnBehavior(e,t);throw new Error('Unable to spawn entity "'.concat(t,'" of type "').concat(typeof e,'".'));var r,i},e.prototype.spawnMachine=function(t,n){var r=this;void 0===n&&(n={});var i=new e(t,Sa(Sa({},this.options),{parent:this,id:n.id||t.id})),o=Sa(Sa({},cs),n);o.sync&&i.onTransition((function(e){r.send(Fa,{state:e,id:i.id})}));var a=i;return this.children.set(i.id,a),o.autoForward&&this.forwardTo.add(i.id),i.onDone((function(e){r.removeChild(i.id),r.send(bl(e,{origin:i.id}))})).start(),a},e.prototype.spawnBehavior=function(e,t){var n=ls(e,{id:t,parent:this});return this.children.set(t,n),n},e.prototype.spawnPromise=function(e,t){var n,r,i=this,o=!1;e.then((function(e){o||(r=e,i.removeChild(t),i.send(bl(Pl(t,e),{origin:t})))}),(function(e){if(!o){i.removeChild(t);var n=Ml(t,e);try{i.send(bl(n,{origin:t}))}catch(r){!function(e,t,n){if(!Ua){var r=e.stack?" Stacktrace was '".concat(e.stack,"'"):"";if(e===t)console.error("Missing onError handler for invocation '".concat(n,"', error was '").concat(e,"'.").concat(r));else{var i=t.stack?" Stacktrace was '".concat(t.stack,"'"):"";console.error("Missing onError handler and/or unhandled exception/promise rejection for invocation '".concat(n,"'. ")+"Original error: '".concat(e,"'. ").concat(r," Current error is '").concat(t,"'.").concat(i))}}}(e,r,t),i.devTools&&i.devTools.send(n,i.state),i.machine.strict&&i.stop()}}}));var a=((n={id:t,send:function(){},subscribe:function(t,n,r){var i=$l(t,n,r),o=!1;return e.then((function(e){o||(i.next(e),o||i.complete())}),(function(e){o||i.error(e)})),{unsubscribe:function(){return o=!0}}},stop:function(){o=!0},toJSON:function(){return{id:t}},getSnapshot:function(){return r}})[vl]=function(){return this},n);return this.children.set(t,a),a},e.prototype.spawnCallback=function(e,t){var n,r,i,o=this,a=!1,l=new Set,s=new Set;try{i=e((function(e){r=e,s.forEach((function(t){return t(e)})),a||o.send(bl(e,{origin:t}))}),(function(e){l.add(e)}))}catch(e){this.send(Ml(t,e))}if(sl(i))return this.spawnPromise(i,t);var c=((n={id:t,send:function(e){return l.forEach((function(t){return t(e)}))},subscribe:function(e){var t=$l(e);return s.add(t.next),{unsubscribe:function(){s.delete(t.next)}}},stop:function(){a=!0,hl(i)&&i()},toJSON:function(){return{id:t}},getSnapshot:function(){return r}})[vl]=function(){return this},n);return this.children.set(t,c),c},e.prototype.spawnObservable=function(e,t){var n,r,i=this,o=e.subscribe((function(e){r=e,i.send(bl(e,{origin:t}))}),(function(e){i.removeChild(t),i.send(bl(Ml(t,e),{origin:t}))}),(function(){i.removeChild(t),i.send(bl(Pl(t),{origin:t}))})),a=((n={id:t,send:function(){},subscribe:function(t,n,r){return e.subscribe(t,n,r)},stop:function(){return o.unsubscribe()},getSnapshot:function(){return r},toJSON:function(){return{id:t}}})[vl]=function(){return this},n);return this.children.set(t,a),a},e.prototype.spawnActor=function(e,t){return this.children.set(t,e),e},e.prototype.spawnActivity=function(e){var t=this.machine.options&&this.machine.options.activities?this.machine.options.activities[e.type]:void 0;if(t){var n=t(this.state.context,e);this.spawnEffect(e.id,n)}else Ua||ul(!1,"No implementation found for activity '".concat(e.type,"'"))},e.prototype.spawnEffect=function(e,t){var n;this.children.set(e,((n={id:e,send:function(){},subscribe:function(){return{unsubscribe:function(){}}},stop:t||void 0,getSnapshot:function(){},toJSON:function(){return{id:e}}})[vl]=function(){return this},n))},e.prototype.attachDev=function(){var e=os();if(this.options.devTools&&e){if(e.__REDUX_DEVTOOLS_EXTENSION__){var t="object"==typeof this.options.devTools?this.options.devTools:void 0;this.devTools=e.__REDUX_DEVTOOLS_EXTENSION__.connect(Sa(Sa({name:this.id,autoPause:!0,stateSanitizer:function(e){return{value:e.value,context:e.context,actions:e.actions}}},t),{features:Sa({jump:!1,skip:!1},t?t.features:void 0)}),this.machine),this.devTools.init(this.state)}as(this)}},e.prototype.toJSON=function(){return{id:this.id}},e.prototype[vl]=function(){return this},e.prototype.getSnapshot=function(){return this.status===ss.NotStarted?this.initialState:this._state},e.defaultOptions={execute:!0,deferEvents:!0,clock:{setTimeout:function(e,t){return setTimeout(e,t)},clearTimeout:function(e){return clearTimeout(e)}},logger:console.log.bind(console),devTools:!1},e.interpret=us,e}();function us(e,t){return new ds(e,t)}function ps(e){if("string"==typeof e){var t={type:e,toString:function(){return e}};return t}return e}function hs(e){return Sa(Sa({type:za},e),{toJSON:function(){e.onDone,e.onError;var t=Ea(e,["onDone","onError"]);return Sa(Sa({},t),{type:za,src:ps(e.src)})}})}var fs="",gs="*",vs={},ms=function(e){return"#"===e[0]},xs=function(){function e(t,n,r,i){void 0===r&&(r="context"in t?t.context:void 0);var o,a=this;this.config=t,this._context=r,this.order=-1,this.__xstatenode=!0,this.__cache={events:void 0,relativeValue:new Map,initialStateValue:void 0,initialState:void 0,on:void 0,transitions:void 0,candidates:{},delayedTransitions:void 0},this.idMap={},this.tags=[],this.options=Object.assign({actions:{},guards:{},services:{},activities:{},delays:{}},n),this.parent=null==i?void 0:i.parent,this.key=this.config.key||(null==i?void 0:i.key)||this.config.id||"(machine)",this.machine=this.parent?this.parent.machine:this,this.path=this.parent?this.parent.path.concat(this.key):[],this.delimiter=this.config.delimiter||(this.parent?this.parent.delimiter:"."),this.id=this.config.id||_a([this.machine.key],La(this.path),!1).join(this.delimiter),this.version=this.parent?this.parent.version:this.config.version,this.type=this.config.type||(this.config.parallel?"parallel":this.config.states&&Object.keys(this.config.states).length?"compound":this.config.history?"history":"atomic"),this.schema=this.parent?this.machine.schema:null!==(o=this.config.schema)&&void 0!==o?o:{},this.description=this.config.description,Ua||ul(!("parallel"in this.config),'The "parallel" property is deprecated and will be removed in version 4.1. '.concat(this.config.parallel?"Replace with `type: 'parallel'`":"Use `type: '".concat(this.type,"'`")," in the config for state node '").concat(this.id,"' instead.")),this.initial=this.config.initial,this.states=this.config.states?el(this.config.states,(function(t,n){var r,i=new e(t,{},void 0,{parent:a,key:n});return Object.assign(a.idMap,Sa(((r={})[i.id]=i,r),i.idMap)),i})):vs;var l=0;!function e(t){var n,r;t.order=l++;try{for(var i=Oa(zl(t)),o=i.next();!o.done;o=i.next()){e(o.value)}}catch(e){n={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}(this),this.history=!0===this.config.history?"shallow":this.config.history||!1,this._transient=!!this.config.always||!!this.config.on&&(Array.isArray(this.config.on)?this.config.on.some((function(e){return e.event===fs})):fs in this.config.on),this.strict=!!this.config.strict,this.onEntry=al(this.config.entry||this.config.onEntry).map((function(e){return Ll(e)})),this.onExit=al(this.config.exit||this.config.onExit).map((function(e){return Ll(e)})),this.meta=this.config.meta,this.doneData="final"===this.type?this.config.data:void 0,this.invoke=al(this.config.invoke).map((function(e,t){var n,r;if(ml(e)){var i=kl(a.id,t);return a.machine.options.services=Sa(((n={})[i]=e,n),a.machine.options.services),hs({src:i,id:i})}if(fl(e.src)){i=e.id||kl(a.id,t);return hs(Sa(Sa({},e),{id:i,src:e.src}))}if(ml(e.src)||hl(e.src)){i=e.id||kl(a.id,t);return a.machine.options.services=Sa(((r={})[i]=e.src,r),a.machine.options.services),hs(Sa(Sa({id:i},e),{src:i}))}var o=e.src;return hs(Sa(Sa({id:kl(a.id,t)},e),{src:o}))})),this.activities=al(this.config.activities).concat(this.invoke).map((function(e){return Tl(e)})),this.transition=this.transition.bind(this),this.tags=al(this.config.tags)}return e.prototype._init=function(){this.__cache.transitions||Hl(this).forEach((function(e){return e.on}))},e.prototype.withConfig=function(t,n){var r=this.options,i=r.actions,o=r.activities,a=r.guards,l=r.services,s=r.delays;return new e(this.config,{actions:Sa(Sa({},i),t.actions),activities:Sa(Sa({},o),t.activities),guards:Sa(Sa({},a),t.guards),services:Sa(Sa({},l),t.services),delays:Sa(Sa({},s),t.delays)},null!=n?n:this.context)},e.prototype.withContext=function(t){return new e(this.config,this.options,t)},Object.defineProperty(e.prototype,"context",{get:function(){return hl(this._context)?this._context():this._context},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"definition",{get:function(){return{id:this.id,key:this.key,version:this.version,context:this.context,type:this.type,initial:this.initial,history:this.history,states:el(this.states,(function(e){return e.definition})),on:this.on,transitions:this.transitions,entry:this.onEntry,exit:this.onExit,activities:this.activities||[],meta:this.meta,order:this.order||-1,data:this.doneData,invoke:this.invoke,description:this.description,tags:this.tags}},enumerable:!1,configurable:!0}),e.prototype.toJSON=function(){return this.definition},Object.defineProperty(e.prototype,"on",{get:function(){if(this.__cache.on)return this.__cache.on;var e=this.transitions;return this.__cache.on=e.reduce((function(e,t){return e[t.eventType]=e[t.eventType]||[],e[t.eventType].push(t),e}),{})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"after",{get:function(){return this.__cache.delayedTransitions||(this.__cache.delayedTransitions=this.getDelayedTransitions(),this.__cache.delayedTransitions)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"transitions",{get:function(){return this.__cache.transitions||(this.__cache.transitions=this.formatTransitions(),this.__cache.transitions)},enumerable:!1,configurable:!0}),e.prototype.getCandidates=function(e){if(this.__cache.candidates[e])return this.__cache.candidates[e];var t=e===fs,n=this.transitions.filter((function(n){var r=n.eventType===e;return t?r:r||n.eventType===gs}));return this.__cache.candidates[e]=n,n},e.prototype.getDelayedTransitions=function(){var e=this,t=this.config.after;if(!t)return[];var n=function(t,n){var r=function(e,t){var n=t?"#".concat(t):"";return"".concat($a.After,"(").concat(e,")").concat(n)}(hl(t)?"".concat(e.id,":delay[").concat(n,"]"):t,e.id);return e.onEntry.push(function(e,t){return{to:t?t.to:void 0,type:Ma,event:hl(e)?e:xl(e),delay:t?t.delay:void 0,id:t&&void 0!==t.id?t.id:hl(e)?e.name:Ya(e)}}(r,{delay:t})),e.onExit.push({type:Da,sendId:r}),r},r=pl(t)?t.map((function(e,t){var r=n(e.delay,t);return Sa(Sa({},e),{event:r})})):il(Object.keys(t).map((function(e,r){var i=t[e],o=fl(i)?{target:i}:i,a=isNaN(+e)?e:+e,l=n(a,r);return al(o).map((function(e){return Sa(Sa({},e),{event:l,delay:a})}))})));return r.map((function(t){var n=t.delay;return Sa(Sa({},e.formatTransition(t)),{delay:n})}))},e.prototype.getStateNodes=function(e){var t,n=this;if(!e)return[];var r=e instanceof Yl?e.value:Ja(e,this.delimiter);if(fl(r)){var i=this.getStateNode(r).initial;return void 0!==i?this.getStateNodes(((t={})[r]=i,t)):[this,this.states[r]]}var o=Object.keys(r),a=[this];return a.push.apply(a,_a([],La(il(o.map((function(e){return n.getStateNode(e).getStateNodes(r[e])})))),!1)),a},e.prototype.handles=function(e){var t=Ya(e);return this.events.includes(t)},e.prototype.resolveState=function(e){var t=e instanceof Yl?e:Yl.create(e),n=Array.from(Bl([],this.getStateNodes(t.value)));return new Yl(Sa(Sa({},t),{value:this.resolve(t.value),configuration:n,done:Wl(n,this),tags:Ul(n),machine:this.machine}))},e.prototype.transitionLeafNode=function(e,t,n){var r=this.getStateNode(e).next(t,n);return r&&r.transitions.length?r:this.next(t,n)},e.prototype.transitionCompoundNode=function(e,t,n){var r=Object.keys(e),i=this.getStateNode(r[0])._transition(e[r[0]],t,n);return i&&i.transitions.length?i:this.next(t,n)},e.prototype.transitionParallelNode=function(e,t,n){var r,i,o={};try{for(var a=Oa(Object.keys(e)),l=a.next();!l.done;l=a.next()){var s=l.value,c=e[s];if(c){var d=this.getStateNode(s)._transition(c,t,n);d&&(o[s]=d)}}}catch(e){r={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}var u=Object.keys(o).map((function(e){return o[e]})),p=il(u.map((function(e){return e.transitions})));if(!u.some((function(e){return e.transitions.length>0})))return this.next(t,n);var h=il(Object.keys(o).map((function(e){return o[e].configuration})));return{transitions:p,exitSet:il(u.map((function(e){return e.exitSet}))),configuration:h,source:t,actions:il(Object.keys(o).map((function(e){return o[e].actions})))}},e.prototype._transition=function(e,t,n){return fl(e)?this.transitionLeafNode(e,t,n):1===Object.keys(e).length?this.transitionCompoundNode(e,t,n):this.transitionParallelNode(e,t,n)},e.prototype.getTransitionData=function(e,t){return this._transition(e.value,e,bl(t))},e.prototype.next=function(e,t){var n,r,i,o=this,a=t.name,l=[],s=[];try{for(var c=Oa(this.getCandidates(a)),d=c.next();!d.done;d=c.next()){var u=d.value,p=u.cond,h=u.in,f=e.context,g=!h||(fl(h)&&ms(h)?e.matches(Ja(this.getStateNodeById(h).path,this.delimiter)):Xa(Ja(h,this.delimiter),nl(this.path.slice(0,-2))(e.value))),v=!1;try{v=!p||Cl(this.machine,p,f,t,e)}catch(e){throw new Error("Unable to evaluate guard '".concat(p.name||p.type,"' in transition for event '").concat(a,"' in state node '").concat(this.id,"':\n").concat(e.message))}if(v&&g){void 0!==u.target&&(s=u.target),l.push.apply(l,_a([],La(u.actions),!1)),i=u;break}}}catch(e){n={error:e}}finally{try{d&&!d.done&&(r=c.return)&&r.call(c)}finally{if(n)throw n.error}}if(i){if(!s.length)return{transitions:[i],exitSet:[],configuration:e.value?[this]:[],source:e,actions:l};var m=il(s.map((function(t){return o.getRelativeStateNodes(t,e.historyValue)})));return{transitions:[i],exitSet:!!i.internal?[]:il(s.map((function(e){return o.getPotentiallyReenteringNodes(e)}))),configuration:m,source:e,actions:l}}},e.prototype.getPotentiallyReenteringNodes=function(e){if(this.order<e.order)return[this];for(var t=[],n=this,r=e;n&&n!==r;)t.push(n),n=n.parent;return n!==r?[]:(t.push(r),t)},e.prototype.getActions=function(e,t,n,r,i,o,a){var l,s,c,d,u=this,p=o?Bl([],this.getStateNodes(o.value)):[],h=new Set;try{for(var f=Oa(Array.from(e).sort((function(e,t){return e.order-t.order}))),g=f.next();!g.done;g=f.next()){(!Gl(p,x=g.value)||Gl(n.exitSet,x)||x.parent&&h.has(x.parent))&&h.add(x)}}catch(e){l={error:e}}finally{try{g&&!g.done&&(s=f.return)&&s.call(f)}finally{if(l)throw l.error}}try{for(var v=Oa(p),m=v.next();!m.done;m=v.next()){var x;Gl(e,x=m.value)&&!Gl(n.exitSet,x.parent)||n.exitSet.push(x)}}catch(e){c={error:e}}finally{try{m&&!m.done&&(d=v.return)&&d.call(v)}finally{if(c)throw c.error}}n.exitSet.sort((function(e,t){return t.order-e.order}));var b=Array.from(h).sort((function(e,t){return e.order-t.order})),y=new Set(n.exitSet),C=il(b.map((function(e){var t=[];if("final"!==e.type)return t;var o=e.parent;if(!o.parent)return t;t.push(Rl(e.id,e.doneData),Rl(o.id,e.doneData?ll(e.doneData,r,i):void 0));var a=o.parent;return"parallel"===a.type&&Al(a).every((function(e){return Wl(n.configuration,e)}))&&t.push(Rl(a.id)),t}))),w=b.map((function(e){var t=e.onEntry,n=e.activities.map((function(e){return function(e){var t=Tl(e);return{type:$a.Start,activity:t,exec:void 0}}(e)}));return{type:"entry",actions:_l(a?_a(_a([],La(t),!1),La(n),!1):_a(_a([],La(n),!1),La(t),!1),u.machine.options.actions)}})).concat({type:"state_done",actions:C.map((function(e){return function(e,t){return{type:Pa,event:"function"==typeof e?e:xl(e),delay:t?t.delay:void 0,id:null==t?void 0:t.id}}(e)}))}),$=Array.from(y).map((function(e){return{type:"exit",actions:_l(_a(_a([],La(e.onExit),!1),La(e.activities.map((function(e){return function(e){var t=hl(e)?e:Tl(e);return{type:$a.Stop,activity:t,exec:void 0}}(e)}))),!1),u.machine.options.actions)}})).concat({type:"transition",actions:_l(n.actions,this.machine.options.actions)}).concat(w);if(t){var k=_l(il(_a([],La(e),!1).sort((function(e,t){return t.order-e.order})).map((function(e){return e.onExit}))),this.machine.options.actions).filter((function(e){return!Sl(e)}));return $.concat({type:"stop",actions:k})}return $},e.prototype.transition=function(e,t,n,r){void 0===e&&(e=this.initialState);var i,o,a=bl(t);if(e instanceof Yl)i=void 0===n?e:this.resolveState(Yl.from(e,n));else{var l=fl(e)?this.resolve(Qa(this.getResolvedPath(e))):this.resolve(e),s=null!=n?n:this.machine.context;i=this.resolveState(Yl.from(l,s))}if(!Ua&&a.name===gs)throw new Error("An event cannot have the wildcard type ('".concat(gs,"')"));if(this.strict&&!this.events.includes(a.name)&&(o=a.name,!/^(done|error)\./.test(o)))throw new Error("Machine '".concat(this.id,"' does not accept event '").concat(a.name,"'"));var c=this._transition(i.value,i,a)||{transitions:[],configuration:[],exitSet:[],source:i,actions:[]},d=Bl([],this.getStateNodes(i.value)),u=c.configuration.length?Bl(d,c.configuration):d;return c.configuration=_a([],La(u),!1),this.resolveTransition(c,i,i.context,r,a)},e.prototype.resolveRaisedTransition=function(e,t,n,r){var i,o=e.actions;return(e=this.transition(e,t,void 0,r))._event=n,e.event=n.data,(i=e.actions).unshift.apply(i,_a([],La(o),!1)),e},e.prototype.resolveTransition=function(e,t,n,r,i){var o,a,l,s,c=this;void 0===i&&(i=El);var d=e.configuration,u=!t||e.transitions.length>0,p=u?e.configuration:t?t.configuration:[],h=Wl(p,this),f=u?ql(this.machine,d):void 0,g=t?t.historyValue?t.historyValue:e.source?this.machine.historyValue(t.value):void 0:void 0,v=this.getActions(new Set(p),h,e,n,i,t,r),m=t?Sa({},t.activities):{};try{for(var x=Oa(v),b=x.next();!b.done;b=x.next()){var y=b.value;try{for(var C=(l=void 0,Oa(y.actions)),w=C.next();!w.done;w=C.next()){var $=w.value;$.type===Ta?m[$.activity.id||$.activity.type]=$:$.type===Ra&&(m[$.activity.id||$.activity.type]=!1)}}catch(e){l={error:e}}finally{try{w&&!w.done&&(s=C.return)&&s.call(C)}finally{if(l)throw l.error}}}}catch(e){o={error:e}}finally{try{b&&!b.done&&(a=x.return)&&a.call(x)}finally{if(o)throw o.error}}var k,S,E=La(Dl(this,t,n,i,v,r,this.machine.config.predictableActionArguments||this.machine.config.preserveActionOrder),2),O=E[0],L=E[1],_=La(function(e,t){var n,r,i=La([[],[]],2),o=i[0],a=i[1];try{for(var l=Oa(e),s=l.next();!s.done;s=l.next()){var c=s.value;t(c)?o.push(c):a.push(c)}}catch(e){n={error:e}}finally{try{s&&!s.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}return[o,a]}(O,Sl),2),T=_[0],R=_[1],P=O.filter((function(e){var t;return e.type===Ta&&(null===(t=e.activity)||void 0===t?void 0:t.type)===za})),M=P.reduce((function(e,t){return e[t.activity.id]=function(e,t,n,r){var i,o=wl(e.src),a=null===(i=null==t?void 0:t.options.services)||void 0===i?void 0:i[o.type],l=e.data?ll(e.data,n,r):void 0,s=a?Vl(a,e.id,l):jl(e.id);return s.meta=e,s}(t.activity,c.machine,L,i),e}),t?Sa({},t.children):{}),D=new Yl({value:f||t.value,context:L,_event:i,_sessionid:t?t._sessionid:null,historyValue:f?g?(k=g,S=f,{current:S,states:cl(k,S)}):void 0:t?t.historyValue:void 0,history:!f||e.source?t:void 0,actions:f?R:[],activities:f?m:t?t.activities:{},events:[],configuration:p,transitions:e.transitions,children:M,done:h,tags:Ul(p),machine:this}),N=n!==L;D.changed=i.name===Fa||N;var j=D.history;j&&delete j.history;var V=!h&&(this._transient||d.some((function(e){return e._transient})));if(!(u||V&&i.name!==fs))return D;var I=D;if(!h)for(V&&(I=this.resolveRaisedTransition(I,{type:Na},i,r));T.length;){var z=T.shift();I=this.resolveRaisedTransition(I,z._event,i,r)}var A=I.changed||(j?!!I.actions.length||N||typeof j.value!=typeof I.value||!Xl(I.value,j.value):void 0);return I.changed=A,I.history=j,I},e.prototype.getStateNode=function(e){if(ms(e))return this.machine.getStateNodeById(e);if(!this.states)throw new Error("Unable to retrieve child state '".concat(e,"' from '").concat(this.id,"'; no child states exist."));var t=this.states[e];if(!t)throw new Error("Child state '".concat(e,"' does not exist on '").concat(this.id,"'"));return t},e.prototype.getStateNodeById=function(e){var t=ms(e)?e.slice(1):e;if(t===this.id)return this;var n=this.machine.idMap[t];if(!n)throw new Error("Child state node '#".concat(t,"' does not exist on machine '").concat(this.id,"'"));return n},e.prototype.getStateNodeByPath=function(e){if("string"==typeof e&&ms(e))try{return this.getStateNodeById(e.slice(1))}catch(e){}for(var t=Ka(e,this.delimiter).slice(),n=this;t.length;){var r=t.shift();if(!r.length)break;n=n.getStateNode(r)}return n},e.prototype.resolve=function(e){var t,n=this;if(!e)return this.initialStateValue||vs;switch(this.type){case"parallel":return el(this.initialStateValue,(function(t,r){return t?n.getStateNode(r).resolve(e[r]||t):vs}));case"compound":if(fl(e)){var r=this.getStateNode(e);return"parallel"===r.type||"compound"===r.type?((t={})[e]=r.initialStateValue,t):e}return Object.keys(e).length?el(e,(function(e,t){return e?n.getStateNode(t).resolve(e):vs})):this.initialStateValue||{};default:return e||vs}},e.prototype.getResolvedPath=function(e){if(ms(e)){var t=this.machine.idMap[e.slice(1)];if(!t)throw new Error("Unable to find state node '".concat(e,"'"));return t.path}return Ka(e,this.delimiter)},Object.defineProperty(e.prototype,"initialStateValue",{get:function(){var e,t;if(this.__cache.initialStateValue)return this.__cache.initialStateValue;if("parallel"===this.type)t=tl(this.states,(function(e){return e.initialStateValue||vs}),(function(e){return!("history"===e.type)}));else if(void 0!==this.initial){if(!this.states[this.initial])throw new Error("Initial state '".concat(this.initial,"' not found on '").concat(this.key,"'"));t=Il(this.states[this.initial])?this.initial:((e={})[this.initial]=this.states[this.initial].initialStateValue,e)}else t={};return this.__cache.initialStateValue=t,this.__cache.initialStateValue},enumerable:!1,configurable:!0}),e.prototype.getInitialState=function(e,t){this._init();var n=this.getStateNodes(e);return this.resolveTransition({configuration:n,exitSet:[],transitions:[],source:void 0,actions:[]},void 0,null!=t?t:this.machine.context,void 0)},Object.defineProperty(e.prototype,"initialState",{get:function(){var e=this.initialStateValue;if(!e)throw new Error("Cannot retrieve initial state from simple state '".concat(this.id,"'."));return this.getInitialState(e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"target",{get:function(){var e;if("history"===this.type){var t=this.config;e=fl(t.target)&&ms(t.target)?Qa(this.machine.getStateNodeById(t.target).path.slice(this.path.length-1)):t.target}return e},enumerable:!1,configurable:!0}),e.prototype.getRelativeStateNodes=function(e,t,n){return void 0===n&&(n=!0),n?"history"===e.type?e.resolveHistory(t):e.initialStateNodes:[e]},Object.defineProperty(e.prototype,"initialStateNodes",{get:function(){var e=this;return Il(this)?[this]:"compound"!==this.type||this.initial?il(rl(this.initialStateValue).map((function(t){return e.getFromRelativePath(t)}))):(Ua||ul(!1,"Compound state node '".concat(this.id,"' has no initial state.")),[this])},enumerable:!1,configurable:!0}),e.prototype.getFromRelativePath=function(e){if(!e.length)return[this];var t=La(e),n=t[0],r=t.slice(1);if(!this.states)throw new Error("Cannot retrieve subPath '".concat(n,"' from node with no states"));var i=this.getStateNode(n);if("history"===i.type)return i.resolveHistory();if(!this.states[n])throw new Error("Child state '".concat(n,"' does not exist on '").concat(this.id,"'"));return this.states[n].getFromRelativePath(r)},e.prototype.historyValue=function(e){if(Object.keys(this.states).length)return{current:e||this.initialStateValue,states:tl(this.states,(function(t,n){if(!e)return t.historyValue();var r=fl(e)?void 0:e[n];return t.historyValue(r||t.initialStateValue)}),(function(e){return!e.history}))}},e.prototype.resolveHistory=function(e){var t=this;if("history"!==this.type)return[this];var n=this.parent;if(!e){var r=this.target;return r?il(rl(r).map((function(e){return n.getFromRelativePath(e)}))):n.initialStateNodes}var i,o,a=(i=n.path,o="states",function(e){var t,n,r=e;try{for(var a=Oa(i),l=a.next();!l.done;l=a.next()){var s=l.value;r=r[o][s]}}catch(e){t={error:e}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}return r})(e).current;return fl(a)?[n.getStateNode(a)]:il(rl(a).map((function(e){return"deep"===t.history?n.getFromRelativePath(e):[n.states[e[0]]]})))},Object.defineProperty(e.prototype,"stateIds",{get:function(){var e=this,t=il(Object.keys(this.states).map((function(t){return e.states[t].stateIds})));return[this.id].concat(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"events",{get:function(){var e,t,n,r;if(this.__cache.events)return this.__cache.events;var i=this.states,o=new Set(this.ownEvents);if(i)try{for(var a=Oa(Object.keys(i)),l=a.next();!l.done;l=a.next()){var s=i[l.value];if(s.states)try{for(var c=(n=void 0,Oa(s.events)),d=c.next();!d.done;d=c.next()){var u=d.value;o.add("".concat(u))}}catch(e){n={error:e}}finally{try{d&&!d.done&&(r=c.return)&&r.call(c)}finally{if(n)throw n.error}}}}catch(t){e={error:t}}finally{try{l&&!l.done&&(t=a.return)&&t.call(a)}finally{if(e)throw e.error}}return this.__cache.events=Array.from(o)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ownEvents",{get:function(){var e=new Set(this.transitions.filter((function(e){return!(!e.target&&!e.actions.length&&e.internal)})).map((function(e){return e.eventType})));return Array.from(e)},enumerable:!1,configurable:!0}),e.prototype.resolveTarget=function(e){var t=this;if(void 0!==e)return e.map((function(e){if(!fl(e))return e;var n=e[0]===t.delimiter;if(n&&!t.parent)return t.getStateNodeByPath(e.slice(1));var r=n?t.key+e:e;if(!t.parent)return t.getStateNodeByPath(r);try{return t.parent.getStateNodeByPath(r)}catch(e){throw new Error("Invalid transition definition for state node '".concat(t.id,"':\n").concat(e.message))}}))},e.prototype.formatTransition=function(e){var t=this,n=function(e){if(void 0!==e&&""!==e)return al(e)}(e.target),r="internal"in e?e.internal:!n||n.some((function(e){return fl(e)&&e[0]===t.delimiter})),i=this.machine.options.guards,o=this.resolveTarget(n),a=Sa(Sa({},e),{actions:_l(al(e.actions)),cond:gl(e.cond,i),target:o,source:this,internal:r,eventType:e.event,toJSON:function(){return Sa(Sa({},a),{target:a.target?a.target.map((function(e){return"#".concat(e.id)})):void 0,source:"#".concat(t.id)})}});return a},e.prototype.formatTransitions=function(){var e,t,n,r=this;if(this.config.on)if(Array.isArray(this.config.on))n=this.config.on;else{var i=this.config.on,o=gs,a=i[o],l=void 0===a?[]:a,s=Ea(i,["*"]);n=il(Object.keys(s).map((function(e){Ua||e!==fs||ul(!1,"Empty string transition configs (e.g., `{ on: { '': ... }}`) for transient transitions are deprecated. Specify the transition in the `{ always: ... }` property instead. "+'Please check the `on` configuration for "#'.concat(r.id,'".'));var t=yl(e,s[e]);return Ua||function(e,t,n){var r=n.slice(0,-1).some((function(e){return!("cond"in e)&&!("in"in e)&&(fl(e.target)||ml(e.target))})),i=t===fs?"the transient event":"event '".concat(t,"'");ul(!r,"One or more transitions for ".concat(i," on state '").concat(e.id,"' are unreachable. ")+"Make sure that the default transition is the last one defined.")}(r,e,t),t})).concat(yl(gs,l)))}else n=[];var c=this.config.always?yl("",this.config.always):[],d=this.config.onDone?yl(String(Rl(this.id)),this.config.onDone):[];Ua||ul(!(this.config.onDone&&!this.parent),'Root nodes cannot have an ".onDone" transition. Please check the config of "'.concat(this.id,'".'));var u=il(this.invoke.map((function(e){var t=[];return e.onDone&&t.push.apply(t,_a([],La(yl(String(Pl(e.id)),e.onDone)),!1)),e.onError&&t.push.apply(t,_a([],La(yl(String(Ml(e.id)),e.onError)),!1)),t}))),p=this.after,h=il(_a(_a(_a(_a([],La(d),!1),La(u),!1),La(n),!1),La(c),!1).map((function(e){return al(e).map((function(e){return r.formatTransition(e)}))})));try{for(var f=Oa(p),g=f.next();!g.done;g=f.next()){var v=g.value;h.push(v)}}catch(t){e={error:t}}finally{try{g&&!g.done&&(t=f.return)&&t.call(f)}finally{if(e)throw e.error}}return h},e}();var bs,ys=function(e){return{type:ja,assignment:e}};!function(e){e[e.Effect=1]="Effect",e[e.LayoutEffect=2]="LayoutEffect"}(bs||(bs={}));var Cs="undefined"!=typeof document?J:function(){};function ws(e){var t=Z.useRef();return t.current||(t.current={v:e()}),t.current.v}var $s=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},ks=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};var Ss=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},Es=function(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))};function Os(e,t){(0,e.exec)(t.context,t._event.data,{action:e,state:t,_event:t._event})()}function Ls(e){var t=K([]),n=K([]);Cs((function(){var r=e.subscribe((function(e){var r,i;if(e.actions.length){var o=e.actions.filter((function(e){return"function"==typeof e.exec&&"__effect"in e.exec})),a=Ss(function(e,t){var n,r,i=$s([[],[]],2),o=i[0],a=i[1];try{for(var l=ks(e),s=l.next();!s.done;s=l.next()){var c=s.value;t(c)?o.push(c):a.push(c)}}catch(e){n={error:e}}finally{try{s&&!s.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}return[o,a]}(o,(function(e){return e.exec.__effect===bs.Effect})),2),l=a[0],s=a[1];(r=t.current).push.apply(r,Es([],Ss(l.map((function(t){return[t,e]}))),!1)),(i=n.current).push.apply(i,Es([],Ss(s.map((function(t){return[t,e]}))),!1))}}));return function(){r.unsubscribe()}}),[]),Cs((function(){for(;n.current.length;){var e=Ss(n.current.shift(),2);Os(e[0],e[1])}})),U((function(){for(;t.current.length;){var e=Ss(t.current.shift(),2);Os(e[0],e[1])}}))}var _s=function(){return _s=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},_s.apply(this,arguments)},Ts=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n},Rs=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a};var Ps=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a};function Ms(e,t){void 0===t&&(t={});var n=Q((function(e){var t=void 0===e.changed&&Object.keys(e.children).length;(e.changed||t)&&a(e)}),[]),r=function(e,t,n){void 0===t&&(t={});var r=ws((function(){return"function"==typeof e?e():e}));if("production"!==process.env.NODE_ENV&&"function"!=typeof e){var i=Rs(W(r),1)[0];e!==i&&console.warn("Machine given to `useMachine` has changed between renders. This is not supported and might lead to unexpected results.\nPlease make sure that you pass the same Machine as argument each time.")}var o=t.context,a=t.guards,l=t.actions,s=t.activities,c=t.services,d=t.delays,u=t.state,p=Ts(t,["context","guards","actions","activities","services","delays","state"]),h=ws((function(){var e={context:o,guards:a,actions:l,activities:s,services:c,delays:d};return us(r.withConfig(e,(function(){return _s(_s({},r.context),o)})),_s({deferEvents:!0},p))}));return Cs((function(){var e;return n&&(e=h.subscribe(function(e){if("object"==typeof e)return e;var t=function(){};return{next:e,error:void 0||t,complete:void 0||t}}(n))),function(){null==e||e.unsubscribe()}}),[n]),Cs((function(){return h.start(u?Yl.create(u):void 0),function(){h.stop()}}),[]),Cs((function(){Object.assign(h.machine.options.actions,l),Object.assign(h.machine.options.guards,a),Object.assign(h.machine.options.activities,s),Object.assign(h.machine.options.services,c),Object.assign(h.machine.options.delays,d)}),[l,a,s,c,d]),Ls(h),h}(e,t,n),i=Ps(W((function(){var e=r.machine.initialState;return t.state?Yl.create(t.state):e})),2),o=i[0],a=i[1];return[o,r.send,r]}function Ds(){return Ds=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ds.apply(null,arguments)}function Ns(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}const js={arr:Array.isArray,obj:e=>"[object Object]"===Object.prototype.toString.call(e),fun:e=>"function"==typeof e,str:e=>"string"==typeof e,num:e=>"number"==typeof e,und:e=>void 0===e,nul:e=>null===e,set:e=>e instanceof Set,map:e=>e instanceof Map,equ(e,t){if(typeof e!=typeof t)return!1;if(js.str(e)||js.num(e))return e===t;if(js.obj(e)&&js.obj(t)&&Object.keys(e).length+Object.keys(t).length===0)return!0;let n;for(n in e)if(!(n in t))return!1;for(n in t)if(e[n]!==t[n])return!1;return!js.und(n)||e===t}};function Vs(e,t){return js.und(e)||js.nul(e)?t:e}function Is(e){return js.und(e)?[]:js.arr(e)?e:[e]}function zs(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return js.fun(e)?e(...n):e}function As(e){const t=function(e){return e.to,e.from,e.config,e.onStart,e.onRest,e.onFrame,e.children,e.reset,e.reverse,e.force,e.immediate,e.delay,e.attach,e.destroyed,e.interpolateTo,e.ref,e.lazy,Ns(e,["to","from","config","onStart","onRest","onFrame","children","reset","reverse","force","immediate","delay","attach","destroyed","interpolateTo","ref","lazy"])}(e);if(js.und(t))return Ds({to:t},e);const n=Object.keys(e).reduce(((n,r)=>js.und(t[r])?Ds({},n,{[r]:e[r]}):n),{});return Ds({to:t},n)}class Hs{constructor(){this.payload=void 0,this.children=[]}getAnimatedValue(){return this.getValue()}getPayload(){return this.payload||this}attach(){}detach(){}getChildren(){return this.children}addChild(e){0===this.children.length&&this.attach(),this.children.push(e)}removeChild(e){const t=this.children.indexOf(e);this.children.splice(t,1),0===this.children.length&&this.detach()}}class Bs extends Hs{constructor(){super(...arguments),this.payload=[],this.attach=()=>this.payload.forEach((e=>e instanceof Hs&&e.addChild(this))),this.detach=()=>this.payload.forEach((e=>e instanceof Hs&&e.removeChild(this)))}}class Fs extends Hs{constructor(){super(...arguments),this.payload={},this.attach=()=>Object.values(this.payload).forEach((e=>e instanceof Hs&&e.addChild(this))),this.detach=()=>Object.values(this.payload).forEach((e=>e instanceof Hs&&e.removeChild(this)))}getValue(e){void 0===e&&(e=!1);const t={};for(const n in this.payload){const r=this.payload[n];(!e||r instanceof Hs)&&(t[n]=r instanceof Hs?r[e?"getAnimatedValue":"getValue"]():r)}return t}getAnimatedValue(){return this.getValue(!0)}}let Zs,qs;let Gs,Ws=e=>"undefined"!=typeof window?window.requestAnimationFrame(e):-1;let Us,Xs=()=>Date.now();class Ys extends Fs{constructor(e,t){super(),this.update=void 0,this.payload=e.style?Ds({},e,{style:Us(e.style)}):e,this.update=t,this.attach()}}let Ks=!1;const Js=new Set,Qs=()=>{if(!Ks)return!1;let e=Xs();for(let t of Js){let n=!1;for(let r=0;r<t.configs.length;r++){let i,o,a=t.configs[r];for(let t=0;t<a.animatedValues.length;t++){let r=a.animatedValues[t];if(r.done)continue;let l=a.fromValues[t],s=a.toValues[t],c=r.lastPosition,d=s instanceof Hs,u=Array.isArray(a.initialVelocity)?a.initialVelocity[t]:a.initialVelocity;if(d&&(s=s.getValue()),a.immediate)r.setValue(s),r.done=!0;else if("string"!=typeof l&&"string"!=typeof s){if(void 0!==a.duration)c=l+a.easing((e-r.startTime)/a.duration)*(s-l),i=e>=r.startTime+a.duration;else if(a.decay)c=l+u/(1-.998)*(1-Math.exp(-.0020000000000000018*(e-r.startTime))),i=Math.abs(r.lastPosition-c)<.1,i&&(s=c);else{o=void 0!==r.lastTime?r.lastTime:e,u=void 0!==r.lastVelocity?r.lastVelocity:a.initialVelocity,e>o+64&&(o=e);let t=Math.floor(e-o);for(let e=0;e<t;++e){u+=1*((-a.tension*(c-s)+-a.friction*u)/a.mass)/1e3,c+=1*u/1e3}let n=!(!a.clamp||0===a.tension)&&(l<s?c>s:c<s),d=Math.abs(u)<=a.precision,p=0===a.tension||Math.abs(s-c)<=a.precision;i=n||d&&p,r.lastVelocity=u,r.lastTime=e}d&&!a.toValues[t].done&&(i=!1),i?(r.value!==s&&(c=s),r.done=!0):n=!0,r.setValue(c),r.lastPosition=c}else r.setValue(s),r.done=!0}t.props.onFrame&&(t.values[a.name]=a.interpolation.getValue())}t.props.onFrame&&t.props.onFrame(t.values),n||(Js.delete(t),t.stop(!0))}return Js.size?Ws(Qs):Ks=!1,Ks};function ec(e,t,n){if("function"==typeof e)return e;if(Array.isArray(e))return ec({range:e,output:t,extrapolate:n});if(Gs&&"string"==typeof e.output[0])return Gs(e);const r=e,i=r.output,o=r.range||[0,1],a=r.extrapolateLeft||r.extrapolate||"extend",l=r.extrapolateRight||r.extrapolate||"extend",s=r.easing||(e=>e);return e=>{const t=function(e,t){for(var n=1;n<t.length-1&&!(t[n]>=e);++n);return n-1}(e,o);return function(e,t,n,r,i,o,a,l,s){let c=s?s(e):e;if(c<t){if("identity"===a)return c;"clamp"===a&&(c=t)}if(c>n){if("identity"===l)return c;"clamp"===l&&(c=n)}if(r===i)return r;if(t===n)return e<=t?r:i;t===-1/0?c=-c:n===1/0?c-=t:c=(c-t)/(n-t);c=o(c),r===-1/0?c=-c:i===1/0?c+=r:c=c*(i-r)+r;return c}(e,o[t],o[t+1],i[t],i[t+1],s,a,l,r.map)}}class tc extends Bs{constructor(e,t,n,r){super(),this.calc=void 0,this.payload=e instanceof Bs&&!(e instanceof tc)?e.getPayload():Array.isArray(e)?e:[e],this.calc=ec(t,n,r)}getValue(){return this.calc(...this.payload.map((e=>e.getValue())))}updateConfig(e,t,n){this.calc=ec(e,t,n)}interpolate(e,t,n){return new tc(this,e,t,n)}}const nc=(e,t,n)=>e&&new tc(e,t,n);function rc(e,t){"update"in e?t.add(e):e.getChildren().forEach((e=>rc(e,t)))}class ic extends Hs{constructor(e){var t;super(),t=this,this.animatedStyles=new Set,this.value=void 0,this.startPosition=void 0,this.lastPosition=void 0,this.lastVelocity=void 0,this.startTime=void 0,this.lastTime=void 0,this.done=!1,this.setValue=function(e,n){void 0===n&&(n=!0),t.value=e,n&&t.flush()},this.value=e,this.startPosition=e,this.lastPosition=e}flush(){0===this.animatedStyles.size&&rc(this,this.animatedStyles),this.animatedStyles.forEach((e=>e.update()))}clearStyles(){this.animatedStyles.clear()}getValue(){return this.value}interpolate(e,t,n){return new tc(this,e,t,n)}}class oc extends Bs{constructor(e){super(),this.payload=e.map((e=>new ic(e)))}setValue(e,t){void 0===t&&(t=!0),Array.isArray(e)?e.length===this.payload.length&&e.forEach(((e,n)=>this.payload[n].setValue(e,t))):this.payload.forEach((n=>n.setValue(e,t)))}getValue(){return this.payload.map((e=>e.getValue()))}interpolate(e,t){return new tc(this,e,t)}}let ac=0,lc=class{constructor(){this.id=void 0,this.idle=!0,this.hasChanged=!1,this.guid=0,this.local=0,this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.listeners=[],this.queue=[],this.localQueue=void 0,this.getValues=()=>this.interpolations,this.id=ac++}update(e){if(!e)return this;const t=As(e),n=t.delay,r=void 0===n?0:n,i=t.to,o=Ns(t,["delay","to"]);if(js.arr(i)||js.fun(i))this.queue.push(Ds({},o,{delay:r,to:i}));else if(i){let e={};Object.entries(i).forEach((t=>{let n=t[0],i=t[1];const a=Ds({to:{[n]:i},delay:zs(r,n)},o),l=e[a.delay]&&e[a.delay].to;e[a.delay]=Ds({},e[a.delay],a,{to:Ds({},l,a.to)})})),this.queue=Object.values(e)}return this.queue=this.queue.sort(((e,t)=>e.delay-t.delay)),this.diff(o),this}start(e){if(this.queue.length){this.idle=!1,this.localQueue&&this.localQueue.forEach((e=>{let t=e.from,n=void 0===t?{}:t,r=e.to,i=void 0===r?{}:r;js.obj(n)&&(this.merged=Ds({},n,this.merged)),js.obj(i)&&(this.merged=Ds({},this.merged,i))}));const t=this.local=++this.guid,n=this.localQueue=this.queue;this.queue=[],n.forEach(((r,i)=>{let o=r.delay,a=Ns(r,["delay"]);const l=r=>{i===n.length-1&&t===this.guid&&r&&(this.idle=!0,this.props.onRest&&this.props.onRest(this.merged)),e&&e()};let s=js.arr(a.to)||js.fun(a.to);o?setTimeout((()=>{t===this.guid&&(s?this.runAsync(a,l):this.diff(a).start(l))}),o):s?this.runAsync(a,l):this.diff(a).start(l)}))}else js.fun(e)&&this.listeners.push(e),this.props.onStart&&this.props.onStart(),t=this,Js.has(t)||Js.add(t),Ks||(Ks=!0,Ws(Qs));var t;return this}stop(e){return this.listeners.forEach((t=>t(e))),this.listeners=[],this}pause(e){var t;return this.stop(!0),e&&(t=this,Js.has(t)&&Js.delete(t)),this}runAsync(e,t){var n=this;e.delay;let r=Ns(e,["delay"]);const i=this.local;let o=Promise.resolve(void 0);if(js.arr(r.to))for(let e=0;e<r.to.length;e++){const t=e,n=Ds({},r,As(r.to[t]));js.arr(n.config)&&(n.config=n.config[t]),o=o.then((()=>{if(i===this.guid)return new Promise((e=>this.diff(n).start(e)))}))}else if(js.fun(r.to)){let e,t=0;o=o.then((()=>r.to((n=>{const o=Ds({},r,As(n));if(js.arr(o.config)&&(o.config=o.config[t]),t++,i===this.guid)return e=new Promise((e=>this.diff(o).start(e)))}),(function(e){return void 0===e&&(e=!0),n.stop(e)})).then((()=>e))))}o.then(t)}diff(e){this.props=Ds({},this.props,e);let t=this.props,n=t.from,r=void 0===n?{}:n,i=t.to,o=void 0===i?{}:i,a=t.config,l=void 0===a?{}:a,s=t.reverse,c=t.attach,d=t.reset,u=t.immediate;if(s){var p=[o,r];r=p[0],o=p[1]}this.merged=Ds({},r,this.merged,o),this.hasChanged=!1;let h=c&&c(this);if(this.animations=Object.entries(this.merged).reduce(((e,t)=>{let n=t[0],i=t[1],o=e[n]||{};const a=js.num(i),s=js.str(i)&&!i.startsWith("#")&&!/\d/.test(i)&&!qs[i],c=js.arr(i),p=!a&&!c&&!s;let f=js.und(r[n])?i:r[n],g=a||c||s?i:1,v=zs(l,n);h&&(g=h.animations[n].parent);let m,x=o.parent,b=o.interpolation,y=Is(h?g.getPayload():g),C=i;p&&(C=Gs({range:[0,1],output:[i,i]})(1));let w=b&&b.getValue();const $=!js.und(x)&&o.animatedValues.some((e=>!e.done)),k=!js.equ(C,w),S=!js.equ(C,o.previous),E=!js.equ(v,o.config);if(d||S&&k||E){if(a||s)x=b=o.parent||new ic(f);else if(c)x=b=o.parent||new oc(f);else if(p){let e=o.interpolation&&o.interpolation.calc(o.parent.value);e=void 0===e||d?f:e,o.parent?(x=o.parent,x.setValue(0,!1)):x=new ic(0);const t={output:[e,i]};o.interpolation?(b=o.interpolation,o.interpolation.updateConfig(t)):b=x.interpolate(t)}return y=Is(h?g.getPayload():g),m=Is(x.getPayload()),d&&!p&&x.setValue(f,!1),this.hasChanged=!0,m.forEach((e=>{e.startPosition=e.value,e.lastPosition=e.value,e.lastVelocity=$?e.lastVelocity:void 0,e.lastTime=$?e.lastTime:void 0,e.startTime=Xs(),e.done=!1,e.animatedStyles.clear()})),zs(u,n)&&x.setValue(p?g:i,!1),Ds({},e,{[n]:Ds({},o,{name:n,parent:x,interpolation:b,animatedValues:m,toValues:y,previous:C,config:v,fromValues:Is(x.getValue()),immediate:zs(u,n),initialVelocity:Vs(v.velocity,0),clamp:Vs(v.clamp,!1),precision:Vs(v.precision,.01),tension:Vs(v.tension,170),friction:Vs(v.friction,26),mass:Vs(v.mass,1),duration:v.duration,easing:Vs(v.easing,(e=>e)),decay:v.decay})})}return k?e:(p&&(x.setValue(1,!1),b.updateConfig({output:[C,C]})),x.done=!0,this.hasChanged=!0,Ds({},e,{[n]:Ds({},e[n],{previous:C})}))}),this.animations),this.hasChanged){this.configs=Object.values(this.animations),this.values={},this.interpolations={};for(let e in this.animations)this.interpolations[e]=this.animations[e].interpolation,this.values[e]=this.animations[e].interpolation.getValue()}return this}destroy(){this.stop(),this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.local=0}};const sc=e=>{const t=js.fun(e),n=((e,t)=>{const n=K(!1),r=K(),i=js.fun(t),o=te((()=>{let n;return r.current&&(r.current.map((e=>e.destroy())),r.current=void 0),[new Array(e).fill().map(((e,r)=>{const o=new lc,a=i?zs(t,r,o):t[r];return 0===r&&(n=a.ref),o.update(a),n||o.start(),o})),n]}),[e]),a=o[0],l=o[1];r.current=a,ne(l,(()=>({start:()=>Promise.all(r.current.map((e=>new Promise((t=>e.start(t)))))),stop:e=>r.current.forEach((t=>t.stop(e))),get controllers(){return r.current}})));const s=te((()=>e=>r.current.map(((t,n)=>{t.update(i?zs(e,n,t):e[n]),l||t.start()}))),[e]);U((()=>{n.current?i||s(t):l||r.current.forEach((e=>e.start()))})),U((()=>(n.current=!0,()=>r.current.forEach((e=>e.destroy())))),[]);const c=r.current.map((e=>e.getValues()));return i?[c,s,e=>r.current.forEach((t=>t.pause(e)))]:c})(1,t?e:[e]),r=n[0],i=n[1],o=n[2];return t?[r[0],i,o]:r};class cc extends Fs{constructor(e){void 0===e&&(e={}),super(),!e.transform||e.transform instanceof Hs||(e=Zs.transform(e)),this.payload=e}}const dc={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},uc="[-+]?\\d*\\.?\\d+",pc=uc+"%";function hc(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return"\\(\\s*("+t.join(")\\s*,\\s*(")+")\\s*\\)"}const fc=new RegExp("rgb"+hc(uc,uc,uc)),gc=new RegExp("rgba"+hc(uc,uc,uc,uc)),vc=new RegExp("hsl"+hc(uc,pc,pc)),mc=new RegExp("hsla"+hc(uc,pc,pc,uc)),xc=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,bc=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,yc=/^#([0-9a-fA-F]{6})$/,Cc=/^#([0-9a-fA-F]{8})$/;function wc(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function $c(e,t,n){const r=n<.5?n*(1+t):n+t-n*t,i=2*n-r,o=wc(i,r,e+1/3),a=wc(i,r,e),l=wc(i,r,e-1/3);return Math.round(255*o)<<24|Math.round(255*a)<<16|Math.round(255*l)<<8}function kc(e){const t=parseInt(e,10);return t<0?0:t>255?255:t}function Sc(e){return(parseFloat(e)%360+360)%360/360}function Ec(e){const t=parseFloat(e);return t<0?0:t>1?255:Math.round(255*t)}function Oc(e){const t=parseFloat(e);return t<0?0:t>100?1:t/100}function Lc(e){let t=function(e){let t;return"number"==typeof e?e>>>0===e&&e>=0&&e<=4294967295?e:null:(t=yc.exec(e))?parseInt(t[1]+"ff",16)>>>0:dc.hasOwnProperty(e)?dc[e]:(t=fc.exec(e))?(kc(t[1])<<24|kc(t[2])<<16|kc(t[3])<<8|255)>>>0:(t=gc.exec(e))?(kc(t[1])<<24|kc(t[2])<<16|kc(t[3])<<8|Ec(t[4]))>>>0:(t=xc.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+"ff",16)>>>0:(t=Cc.exec(e))?parseInt(t[1],16)>>>0:(t=bc.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+t[4]+t[4],16)>>>0:(t=vc.exec(e))?(255|$c(Sc(t[1]),Oc(t[2]),Oc(t[3])))>>>0:(t=mc.exec(e))?($c(Sc(t[1]),Oc(t[2]),Oc(t[3]))|Ec(t[4]))>>>0:null}(e);return null===t?e:(t=t||0,`rgba(${(4278190080&t)>>>24}, ${(16711680&t)>>>16}, ${(65280&t)>>>8}, ${(255&t)/255})`)}const _c=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,Tc=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,Rc=new RegExp(`(${Object.keys(dc).join("|")})`,"g");let Pc={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0};const Mc=["Webkit","Ms","Moz","O"];function Dc(e,t,n){return null==t||"boolean"==typeof t||""===t?"":n||"number"!=typeof t||0===t||Pc.hasOwnProperty(e)&&Pc[e]?(""+t).trim():t+"px"}Pc=Object.keys(Pc).reduce(((e,t)=>(Mc.forEach((n=>e[((e,t)=>e+t.charAt(0).toUpperCase()+t.substring(1))(n,t)]=e[t])),e)),Pc);const Nc={};var jc;Us=e=>new cc(e),jc=e=>{const t=e.output.map((e=>e.replace(Tc,Lc))).map((e=>e.replace(Rc,Lc))),n=t[0].match(_c).map((()=>[]));t.forEach((e=>{e.match(_c).forEach(((e,t)=>n[t].push(+e)))}));const r=t[0].match(_c).map(((t,r)=>ec(Ds({},e,{output:n[r]}))));return e=>{let n=0;return t[0].replace(_c,(()=>r[n++](e))).replace(/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,((e,t,n,r,i)=>`rgba(${Math.round(t)}, ${Math.round(n)}, ${Math.round(r)}, ${i})`))}},Gs=jc,qs=dc,function(e,t){Zs={fn:e,transform:t}}(((e,t)=>{if(!e.nodeType||void 0===e.setAttribute)return!1;{const i=t.style,o=t.children,a=t.scrollTop,l=t.scrollLeft,s=Ns(t,["style","children","scrollTop","scrollLeft"]),c="filter"===e.nodeName||e.parentNode&&"filter"===e.parentNode.nodeName;void 0!==a&&(e.scrollTop=a),void 0!==l&&(e.scrollLeft=l),void 0!==o&&(e.textContent=o);for(let t in i)if(i.hasOwnProperty(t)){var n=0===t.indexOf("--"),r=Dc(t,i[t],n);"float"===t&&(t="cssFloat"),n?e.style.setProperty(t,r):e.style[t]=r}for(let t in s){const n=c?t:Nc[t]||(Nc[t]=t.replace(/([A-Z])/g,(e=>"-"+e.toLowerCase())));void 0!==e.getAttribute(n)&&e.setAttribute(n,s[t])}}}),(e=>e));var Vc;const Ic=(Vc=e=>G(((t,n)=>{const r=function(){const e=W(!1)[1];return Q((()=>e((e=>!e))),[])}(),i=K(!0),o=K(null),a=K(null),l=Q((e=>{const t=o.current;o.current=new Ys(e,(()=>{let e=!1;a.current&&(e=Zs.fn(a.current,o.current.getAnimatedValue())),a.current&&!1!==e||r()})),t&&t.detach()}),[]);U((()=>()=>{i.current=!1,o.current&&o.current.detach()}),[]),ne(n,(()=>(e=>e.current)(a))),l(t);const s=o.current.getValue();s.scrollTop,s.scrollLeft;const c=Ns(s,["scrollTop","scrollLeft"]),d=(u=e,!js.fun(u)||u.prototype instanceof q.Component?e=>a.current=function(e,t){return t&&(js.fun(t)?t(e):js.obj(t)&&(t.current=e)),e}(e,n):void 0);var u;return q.createElement(e,Ds({},c,{ref:d}))})),e=>(js.arr(e)?e:Object.keys(e)).reduce(((e,t)=>{const n=t;return e[n]=Vc(n),e}),Vc))(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]);function zc(e,t){return e.map((function(e,n){return e+t[n]}))}function Ac(e,t){return e.map((function(e,n){return e-t[n]}))}function Hc(e){return Math.hypot.apply(Math,e)}function Bc(e){return Math.sign?Math.sign(e):Number(e>0)-Number(e<0)||+e}function Fc(e,t,n){return 0===t||Math.abs(t)===1/0?function(e,t){return Math.pow(e,5*t)}(e,n):e*t*n/(t+n*e)}function Zc(e,t,n,r){return void 0===r&&(r=.15),0===r?function(e,t,n){return Math.max(t,Math.min(e,n))}(e,t,n):e<t?-Fc(t-e,n-t,r)+t:e>n?+Fc(e-n,n-t,r)+n:e}function qc(e,t,n){return t&&function(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,r.key,r)}}(e.prototype,t),e}function Gc(){return Gc=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Gc.apply(this,arguments)}function Wc(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function Uc(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Xc(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Yc(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return Xc(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Xc(e,t):void 0}}(e))||t){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}function Kc(){}function Jc(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return 0===t.length?Kc:1===t.length?t[0]:function(){for(var e,n,r=Yc(t);!(n=r()).done;){e=n.value.apply(this,arguments)||e}return e}}function Qc(e,t){if(void 0===e){if(void 0===t)throw new Error("Must define fallback value if undefined is expected");e=t}return Array.isArray(e)?e:[e,e]}function ed(e){if("function"==typeof e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.apply(void 0,n)}return e}function td(e,t){void 0===e&&(e={});for(var n={},r=0,i=Object.entries(t);r<i.length;r++){var o=i[r],a=o[0],l=o[1];switch(typeof l){case"function":n[a]=l.call(n,e[a],a,e);break;case"object":n[a]=td(e[a],l);break;case"boolean":l&&(n[a]=e[a])}}return n}var nd=Gc({},{threshold:function(e){return void 0===e&&(e=0),Qc(e)},rubberband:function(e){switch(void 0===e&&(e=0),e){case!0:return Qc(.15);case!1:return Qc(0);default:return Qc(e)}},enabled:function(e){return void 0===e&&(e=!0),e},triggerAllEvents:function(e){return void 0===e&&(e=!1),e},initial:function(e){return void 0===e&&(e=0),"function"==typeof e?e:Qc(e)}},{axis:!0,lockDirection:function(e){return void 0===e&&(e=!1),e},bounds:function(e){if(void 0===e&&(e={}),"function"==typeof e)return function(t){return nd.bounds(e(t))};var t=e,n=t.left,r=void 0===n?-1/0:n,i=t.right,o=void 0===i?1/0:i,a=t.top,l=void 0===a?-1/0:a,s=t.bottom;return[[r,o],[l,void 0===s?1/0:s]]}}),rd="undefined"!=typeof window&&window.document&&window.document.createElement,id={enabled:function(e){return void 0===e&&(e=!0),e},domTarget:!0,window:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}((function(e){return void 0===e&&(e=rd?window:void 0),e})),eventOptions:function(e){var t=void 0===e?{}:e,n=t.passive,r=void 0===n||n,i=t.capture;return{passive:r,capture:void 0!==i&&i}}},od=Gc({},nd,{threshold:function(e,t,n){var r=n.filterTaps,i=void 0!==r&&r,o=n.lockDirection,a=void 0!==o&&o,l=n.axis,s=Qc(e,i?3:a||(void 0===l?void 0:l)?1:0);return this.filterTaps=i||s[0]+s[1]>0,s},swipeVelocity:function(e){return void 0===e&&(e=.5),Qc(e)},swipeDistance:function(e){return void 0===e&&(e=60),Qc(e)},delay:function(e){switch(void 0===e&&(e=0),e){case!0:return 180;case!1:return 0;default:return e}}});function ad(e){var t=e.domTarget,n=e.eventOptions,r=e.window,i=e.enabled,o=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,["domTarget","eventOptions","window","enabled"]),a=function(e){return void 0===e&&(e={}),td(e,id)}({domTarget:t,eventOptions:n,window:r,enabled:i});return a.drag=function(e){return void 0===e&&(e={}),td(e,od)}(o),a}function ld(e){return Gc({_active:!1,_blocked:!1,_intentional:[!1,!1],_movement:[0,0],_initial:[0,0],_bounds:[[-1/0,1/0],[-1/0,1/0]],_lastEventType:void 0,event:void 0,intentional:!1,values:[0,0],velocities:[0,0],delta:[0,0],movement:[0,0],offset:[0,0],lastOffset:[0,0],direction:[0,0],initial:[0,0],previous:[0,0],first:!1,last:!1,active:!1,timeStamp:0,startTime:0,elapsedTime:0,cancel:Kc,canceled:!1,memo:void 0,args:void 0},e)}function sd(){return{shared:{hovering:!1,scrolling:!1,wheeling:!1,dragging:!1,moving:!1,pinching:!1,touches:0,buttons:0,down:!1,shiftKey:!1,altKey:!1,metaKey:!1,ctrlKey:!1},drag:ld({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0,_isTap:!0,_delayedEvent:!1,_pointerId:void 0,tap:!1,swipe:[0,0]}),pinch:ld({da:[0,0],vdva:[0,0],origin:void 0,turns:0}),wheel:ld({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0}),move:ld({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0}),scroll:ld({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0})}}var cd=new Map,dd=function(){function e(e,t){var n=this;void 0===t&&(t=[]),this.controller=e,this.args=t,this.debounced=!0,this.setTimeout=function(e,t){var r;void 0===t&&(t=140),clearTimeout(n.controller.timeouts[n.stateKey]);for(var i=arguments.length,o=new Array(i>2?i-2:0),a=2;a<i;a++)o[a-2]=arguments[a];n.controller.timeouts[n.stateKey]=(r=window).setTimeout.apply(r,[e,t].concat(o))},this.clearTimeout=function(){clearTimeout(n.controller.timeouts[n.stateKey])},this.fireGestureHandler=function(e){if(void 0===e&&(e=!1),n.state._blocked)return n.debounced||(n.state._active=!1,n.clean()),null;if(!e&&!n.state.intentional&&!n.config.triggerAllEvents)return null;if(n.state.intentional){var t=n.state.active,r=n.state._active;n.state.active=r,n.state.first=r&&!t,n.state.last=t&&!r,n.controller.state.shared[n.ingKey]=r}var i=Gc({},n.controller.state.shared,n.state,n.mapStateValues(n.state)),o=n.handler(i);return n.state.memo=void 0!==o?o:n.state.memo,n.state._active||n.clean(),i}}var t=e.prototype;return t.updateSharedState=function(e){Object.assign(this.controller.state.shared,e)},t.updateGestureState=function(e){Object.assign(this.state,e)},t.checkIntentionality=function(e,t){return{_intentional:e,_blocked:!1}},t.getMovement=function(e){var t=this.config,n=t.initial,r=t.bounds,i=t.rubberband,o=t.threshold,a=this.state,l=a._bounds,s=a._initial,c=a._active,d=a._intentional,u=a.lastOffset,p=a.movement,h=this.getInternalMovement(e,this.state),f=!1===d[0]?ud(h[0],o[0]):d[0],g=!1===d[1]?ud(h[1],o[1]):d[1],v=this.checkIntentionality([f,g],h);if(v._blocked)return Gc({},v,{_movement:h,delta:[0,0]});var m,x,b,y,C=v._intentional,w=h;(!1!==C[0]&&!1===d[0]&&(x=ed(n,this.state),m=ed(r,this.state),s[0]=x[0],l[0]=m[0]),!1!==C[1]&&!1===d[1])&&(x=null!=(b=x)?b:ed(n,this.state),m=null!=(y=m)?y:ed(r,this.state),s[1]=x[1],l[1]=m[1]);var $=[!1!==C[0]?h[0]-C[0]:s[0],!1!==C[1]?h[1]-C[1]:s[1]],k=zc($,u),S=c?i:[0,0];return $=pd(l,zc($,s),S),Gc({},v,{intentional:!1!==C[0]||!1!==C[1],_initial:s,_movement:w,movement:$,values:e,offset:pd(l,k,S),delta:Ac($,p)})},t.clean=function(){this.clearTimeout()},qc(e,[{key:"config",get:function(){return this.controller.config[this.stateKey]}},{key:"enabled",get:function(){return this.controller.config.enabled&&this.config.enabled}},{key:"state",get:function(){return this.controller.state[this.stateKey]}},{key:"handler",get:function(){return this.controller.handlers[this.stateKey]}}]),e}();function ud(e,t){return Math.abs(e)>=t&&Bc(e)*t}function pd(e,t,n){var r=t[0],i=t[1],o=n[0],a=n[1],l=e[0],s=l[0],c=l[1],d=e[1],u=d[0],p=d[1];return[Zc(r,s,c,o),Zc(i,u,p,a)]}function hd(e,t,n){var r=e.state,i=e.args,o=t.timeStamp,a=t.type,l=r.values;return{_lastEventType:a,event:t,timeStamp:o,elapsedTime:n?0:o-r.startTime,args:i,previous:l}}function fd(e,t){return function(n){for(var r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];return e.call.apply(e,[this,Gc({},t,{event:n})].concat(i))}}var gd=function(e){var t=this;this.classes=e,this.bind=function(){for(var e={},n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];for(var o,a=Yc(t.classes);!(o=a()).done;){new(0,o.value)(t,r).addBindings(e)}for(var l=0,s=Object.entries(t.nativeRefs);l<s.length;l++){var c=s[l];xd(e,c[0],fd(c[1],Gc({},t.state.shared,{args:r})))}return t.config.domTarget?function(e,t){var n=e.config,r=e.domListeners,i=md(n);if(!i)throw new Error("domTarget must be defined");var o=n.eventOptions;yd(i,vd(r),o);for(var a=0,l=Object.entries(t);a<l.length;a++){var s=l[a],c=s[0],d=s[1],u=c.slice(2).toLowerCase();r.push([u,Jc.apply(void 0,d)])}bd(i,r,o)}(t,e):function(e,t){for(var n=e.config,r={},i=n.eventOptions.capture?"Capture":"",o=0,a=Object.entries(t);o<a.length;o++){var l=a[o],s=l[0],c=l[1],d=Array.isArray(c)?c:[c];r[s+i]=Jc.apply(void 0,d)}return r}(t,e)},this.effect=function(){return t.config.domTarget&&t.bind(),t.clean},this.clean=function(){var e=md(t.config),n=t.config.eventOptions;e&&yd(e,vd(t.domListeners),n),Object.values(t.timeouts).forEach(clearTimeout),function(e){var t=e.config,n=t.window,r=t.eventOptions,i=e.windowListeners;if(!n)return;for(var o in i){yd(n,i[o],r)}e.windowListeners={}}(t)},this.state=sd(),this.timeouts={},this.domListeners=[],this.windowListeners={}};function vd(e){return void 0===e&&(e=[]),e.splice(0,e.length)}function md(e){var t=e.domTarget;return t&&"current"in t?t.current:t}function xd(e,t,n){e[t]||(e[t]=[]),e[t].push(n)}function bd(e,t,n){void 0===t&&(t=[]),void 0===n&&(n={});for(var r,i=Yc(t);!(r=i()).done;){var o=r.value,a=o[0],l=o[1];e.addEventListener(a,l,n)}}function yd(e,t,n){void 0===t&&(t=[]),void 0===n&&(n={});for(var r,i=Yc(t);!(r=i()).done;){var o=r.value,a=o[0],l=o[1];e.removeEventListener(a,l,n)}}function Cd(e,t,n){void 0===n&&(n={});var r=function(e){var t=new Set;e.drag&&t.add(cd.get("drag"));e.wheel&&t.add(cd.get("wheel"));e.scroll&&t.add(cd.get("scroll"));e.move&&t.add(cd.get("move"));e.pinch&&t.add(cd.get("pinch"));e.hover&&t.add(cd.get("hover"));return t}(e),i=q.useMemo((function(){return new gd(r)}),[]);return i.config=t,i.handlers=e,i.nativeRefs=n,q.useEffect(i.effect,[]),i.config.domTarget?wd:i.bind}function wd(){"development"===process.env.NODE_ENV&&console.warn("Deprecation notice: When the `domTarget` option is specified, you don't need to write `useEffect(bind, [bind])` anymore: event binding is now made handled internally to this lib.\n\nNext version won't return anything when `domTarget` is provided, therefore your code will break if you try to call `useEffect`.")}function $d(e){if("touches"in e){var t=e.targetTouches,n=e.changedTouches;return t.length>0?t:n}return null}function kd(e){var t="buttons"in e?e.buttons:0,n=$d(e),r=n&&n.length||0;return{touches:r,down:r>0||t>0,buttons:t,shiftKey:e.shiftKey,altKey:e.altKey,metaKey:e.metaKey,ctrlKey:e.ctrlKey}}function Sd(e){var t=$d(e),n=t?t[0]:e;return[n.clientX,n.clientY]}var Ed=function(e){function t(){var t;return(t=e.apply(this,arguments)||this).ingKey="dragging",t.stateKey="drag",t.onDragStart=function(e){t.enabled&&!t.state._active&&(!function(e,t,n){var r=e.config,i=e.windowListeners;void 0===n&&(n=[]),r.window&&(yd(r.window,i[t],r.eventOptions),bd(r.window,i[t]=n,r.eventOptions))}(t.controller,t.stateKey,[["pointermove",t.onDragChange],["pointerup",t.onDragEnd],["pointercancel",t.onDragEnd]]),t.updateGestureState({_pointerId:e.pointerId}),t.config.delay>0?(t.state._delayedEvent=!0,"persist"in e&&"function"==typeof e.persist&&e.persist(),t.setTimeout(t.startDrag.bind(Uc(t)),t.config.delay,e)):t.startDrag(e))},t.onDragChange=function(e){if(!t.state.canceled&&e.pointerId===t.state._pointerId)if(t.state._active){var n=kd(e);if(n.down){t.updateSharedState(n);var r=Sd(e),i=t.getKinematics(r,e),o=hd(Uc(t),e),a=t.state._isTap,l=Hc(i._movement);a&&l>=3&&(a=!1),t.updateGestureState(Gc({},o,i,{_isTap:a})),t.fireGestureHandler()}else t.onDragEnd(e)}else t.state._delayedEvent&&(t.clearTimeout(),t.startDrag(e))},t.onDragEnd=function(e){if(e.pointerId===t.state._pointerId){t.state._active=!1,t.updateSharedState({down:!1,buttons:0,touches:0});var n=t.state._isTap,r=t.state.velocities,i=r[0],o=r[1],a=t.state.movement,l=a[0],s=a[1],c=t.state._intentional,d=c[0],u=c[1],p=t.config.swipeVelocity,h=p[0],f=p[1],g=t.config.swipeDistance,v=g[0],m=g[1],x=Gc({},hd(Uc(t),e),t.getMovement(t.state.values)),b=[0,0];x.elapsedTime<220&&(!1!==d&&Math.abs(i)>h&&Math.abs(l)>v&&(b[0]=Bc(i)),!1!==u&&Math.abs(o)>f&&Math.abs(s)>m&&(b[1]=Bc(o))),t.updateGestureState(Gc({},x,{tap:n,swipe:b})),t.fireGestureHandler(!0===n)}},t.clean=function(){e.prototype.clean.call(Uc(t)),t.state._delayedEvent=!1,function(e,t){var n=e.config,r=e.windowListeners;n.window&&(yd(n.window,r[t],n.eventOptions),delete r[t])}(t.controller,t.stateKey)},t.onCancel=function(){t.state.canceled||(t.updateGestureState({canceled:!0}),t.state._active=!1,t.updateSharedState({down:!1,buttons:0,touches:0}),requestAnimationFrame((function(){return t.fireGestureHandler()})))},t.onClick=function(e){t.state._isTap||e.stopPropagation()},t}Wc(t,e);var n=t.prototype;return n.startDrag=function(e){var t=Sd(e);this.updateSharedState(kd(e)),this.updateGestureState(Gc({},function(e,t,n){var r=e.state.offset,i=n.timeStamp;return Gc({},sd()[e.stateKey],{_active:!0,values:t,initial:t,offset:r,lastOffset:r,startTime:i})}(this,t,e),hd(this,e,!0),{_pointerId:e.pointerId,cancel:this.onCancel})),this.updateGestureState(this.getMovement(t)),this.fireGestureHandler()},n.addBindings=function(e){(xd(e,"onPointerDown",this.onDragStart),this.config.filterTaps)&&xd(e,this.controller.config.eventOptions.capture?"onClick":"onClickCapture",this.onClick)},t}(function(e){function t(){return e.apply(this,arguments)||this}Wc(t,e);var n=t.prototype;return n.getInternalMovement=function(e,t){return Ac(e,t.initial)},n.checkIntentionality=function(e,t){if(!1===e[0]&&!1===e[1])return{_intentional:e,axis:this.state.axis};var n=t.map(Math.abs),r=n[0],i=n[1],o=this.state.axis||(r>i?"x":r<i?"y":void 0);return this.config.axis||this.config.lockDirection?o?this.config.axis&&o!==this.config.axis?{_intentional:e,_blocked:!0,axis:o}:(e["x"===o?1:0]=!1,{_intentional:e,_blocked:!1,axis:o}):{_intentional:[!1,!1],_blocked:!1,axis:o}:{_intentional:e,_blocked:!1,axis:o}},n.getKinematics=function(e,t){var n=this.getMovement(e);if(!n._blocked){var r=t.timeStamp-this.state.timeStamp;Object.assign(n,function(e,t,n){var r=Hc(t),i=0===r?0:1/r,o=0===n?0:1/n,a=o*r,l=t.map((function(e){return o*e})),s=t.map((function(e){return i*e}));return{velocities:l,velocity:a,distance:Hc(e),direction:s}}(n.movement,n.delta,r))}return n},n.mapStateValues=function(e){return{xy:e.values,vxvy:e.velocities}},t}(dd));function Od(e,t){if(e===t)return!0;if(e&&t&&"object"==typeof e&&"object"==typeof t){if(e.constructor!==t.constructor)return!1;var n,r,i,o;if(Array.isArray(e)){if((n=e.length)!==t.length)return!1;for(r=n;0!=r--;)if(!Od(e[r],t[r]))return!1;return!0}if("function"==typeof Map&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(o=e.entries();!(r=o.next()).done;)if(!t.has(r.value[0]))return!1;for(o=e.entries();!(r=o.next()).done;)if(!Od(r.value[1],t.get(r.value[0])))return!1;return!0}if("function"==typeof Set&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(o=e.entries();!(r=o.next()).done;)if(!t.has(r.value[0]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if((n=(i=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!Object.prototype.hasOwnProperty.call(t,i[r]))return!1;if("undefined"!=typeof Element&&e instanceof Element)return!1;for(r=n;0!=r--;)if(!("_owner"===i[r]&&e.$$typeof||Od(e[i[r]],t[i[r]])))return!1;return!0}return e!=e&&t!=t}function Ld(e,t){try{return Od(e,t)}catch(e){if((e.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw e}}function _d(e,t){void 0===t&&(t={}),cd.set("drag",Ed);var n=K();return n.current||(n.current=function(e,t){var n,r,i=[],o=!1;return function(){for(var a=arguments.length,l=new Array(a),s=0;s<a;s++)l[s]=arguments[s];return o&&n===this&&t(l,i)||(r=e.apply(this,l),o=!0,n=this,i=l),r}}(ad,Ld)),Cd({drag:e},n.current(t))}
2337
+ ***************************************************************************** */var $a,ka,Sa=function(){return Sa=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Sa.apply(this,arguments)};function Ea(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n}function Oa(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function La(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function _a(e,t,n){if(2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))}!function(e){e.Start="xstate.start",e.Stop="xstate.stop",e.Raise="xstate.raise",e.Send="xstate.send",e.Cancel="xstate.cancel",e.NullEvent="",e.Assign="xstate.assign",e.After="xstate.after",e.DoneState="done.state",e.DoneInvoke="done.invoke",e.Log="xstate.log",e.Init="xstate.init",e.Invoke="xstate.invoke",e.ErrorExecution="error.execution",e.ErrorCommunication="error.communication",e.ErrorPlatform="error.platform",e.ErrorCustom="xstate.error",e.Update="xstate.update",e.Pure="xstate.pure",e.Choose="xstate.choose"}($a||($a={})),function(e){e.Parent="#_parent",e.Internal="#_internal"}(ka||(ka={}));var Ta=$a.Start,Ra=$a.Stop,Pa=$a.Raise,Ma=$a.Send,Da=$a.Cancel,Na=$a.NullEvent,ja=$a.Assign;$a.After,$a.DoneState;var Va=$a.Log,Ia=$a.Init,za=$a.Invoke;$a.ErrorExecution;var Aa,Ha=$a.ErrorPlatform,Ba=$a.ErrorCustom,Fa=$a.Update,Za=$a.Choose,qa=$a.Pure,Ga={},Wa="xstate.guard",Ua="production"===process.env.NODE_ENV;function Xa(e,t,n){void 0===n&&(n=".");var r=Ja(e,n),i=Ja(t,n);return fl(i)?!!fl(r)&&i===r:fl(r)?r in i:Object.keys(r).every((function(e){return e in i&&Xa(r[e],i[e])}))}function Ya(e){try{return fl(e)||"number"==typeof e?"".concat(e):e.type}catch(e){throw new Error("Events must be strings or objects with a string event.type property.")}}function Ka(e,t){try{return pl(e)?e:e.toString().split(t)}catch(t){throw new Error("'".concat(e,"' is not a valid state path."))}}function Ja(e,t){return"object"==typeof(n=e)&&"value"in n&&"context"in n&&"event"in n&&"_event"in n?e.value:pl(e)?Qa(e):"string"!=typeof e?e:Qa(Ka(e,t));var n}function Qa(e){if(1===e.length)return e[0];for(var t={},n=t,r=0;r<e.length-1;r++)r===e.length-2?n[e[r]]=e[r+1]:(n[e[r]]={},n=n[e[r]]);return t}function el(e,t){for(var n={},r=Object.keys(e),i=0;i<r.length;i++){var o=r[i];n[o]=t(e[o],o,e,i)}return n}function tl(e,t,n){var r,i,o={};try{for(var a=Oa(Object.keys(e)),l=a.next();!l.done;l=a.next()){var s=l.value,c=e[s];n(c)&&(o[s]=t(c,s,e))}}catch(e){r={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}return o}var nl=function(e){return function(t){var n,r,i=t;try{for(var o=Oa(e),a=o.next();!a.done;a=o.next()){i=i[a.value]}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}return i}};function rl(e){return e?fl(e)?[[e]]:il(Object.keys(e).map((function(t){var n=e[t];return"string"==typeof n||n&&Object.keys(n).length?rl(e[t]).map((function(e){return[t].concat(e)})):[[t]]}))):[[]]}function il(e){var t;return(t=[]).concat.apply(t,_a([],La(e),!1))}function ol(e){return pl(e)?e:[e]}function al(e){return void 0===e?[]:ol(e)}function ll(e,t,n){var r,i;if(hl(e))return e(t,n.data);var o={};try{for(var a=Oa(Object.keys(e)),l=a.next();!l.done;l=a.next()){var s=l.value,c=e[s];hl(c)?o[s]=c(t,n.data):o[s]=c}}catch(e){r={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}return o}function sl(e){return e instanceof Promise||!(null===e||!hl(e)&&"object"!=typeof e||!hl(e.then))}function cl(e,t){return el(e.states,(function(e,n){if(e){var r=(fl(t)?void 0:t[n])||(e?e.current:void 0);if(r)return{current:r,states:cl(e,r)}}}))}function dl(e,t,n,r){Ua||ul(!!e,"Attempting to update undefined context");var i=e?n.reduce((function(e,n){var i,o,a=n.assignment,l={state:r,action:n,_event:t},s={};if(hl(a))s=a(e,t.data,l);else try{for(var c=Oa(Object.keys(a)),d=c.next();!d.done;d=c.next()){var u=d.value,p=a[u];s[u]=hl(p)?p(e,t.data,l):p}}catch(e){i={error:e}}finally{try{d&&!d.done&&(o=c.return)&&o.call(c)}finally{if(i)throw i.error}}return Object.assign({},e,s)}),e):e;return i}var ul=function(){};function pl(e){return Array.isArray(e)}function hl(e){return"function"==typeof e}function fl(e){return"string"==typeof e}function gl(e,t){if(e)return fl(e)?{type:Wa,name:e,predicate:t?t[e]:void 0}:hl(e)?{type:Wa,name:e.name,predicate:e}:e}Ua||(ul=function(e,t){var n=e instanceof Error?e:void 0;if((n||!e)&&void 0!==console){var r=["Warning: ".concat(t)];n&&r.push(n),console.warn.apply(console,r)}});var vl=function(){return"function"==typeof Symbol&&Symbol.observable||"@@observable"}();function ml(e){return!!e&&"__xstatenode"in e}function xl(e,t){return fl(e)||"number"==typeof e?Sa({type:e},t):e}function bl(e,t){if(!fl(e)&&"$$type"in e&&"scxml"===e.$$type)return e;var n=xl(e);return Sa({name:n.type,data:n,$$type:"scxml",type:"external"},t)}function yl(e,t){return ol(t).map((function(t){return void 0===t||"string"==typeof t||ml(t)?{target:t,event:e}:Sa(Sa({},t),{event:e})}))}function Cl(e,t,n,r,i){var o=e.options.guards,a={state:i,cond:t,_event:r};if(t.type===Wa)return((null==o?void 0:o[t.name])||t.predicate)(n,r.data,a);var l=null==o?void 0:o[t.type];if(!l)throw new Error("Guard '".concat(t.type,"' is not implemented on machine '").concat(e.id,"'."));return l(n,r.data,a)}function wl(e){return"string"==typeof e?{type:e}:e}function $l(e,t,n){var r=function(){},i="object"==typeof e,o=i?e:null;return{next:((i?e.next:e)||r).bind(o),error:((i?e.error:t)||r).bind(o),complete:((i?e.complete:n)||r).bind(o)}}function kl(e,t){return"".concat(e,":invocation[").concat(t,"]")}function Sl(e){return(e.type===Pa||e.type===Ma&&e.to===ka.Internal)&&"number"!=typeof e.delay}(Aa={})[vl]=function(){return this},Aa[Symbol.observable]=function(){return this};var El=bl({type:Ia});function Ol(e,t){return t&&t[e]||void 0}function Ll(e,t){var n;if(fl(e)||"number"==typeof e)n=hl(r=Ol(e,t))?{type:e,exec:r}:r||{type:e,exec:void 0};else if(hl(e))n={type:e.name||e.toString(),exec:e};else{var r;if(hl(r=Ol(e.type,t)))n=Sa(Sa({},e),{exec:r});else if(r){var i=r.type||e.type;n=Sa(Sa(Sa({},r),e),{type:i})}else n=e}return n}var _l=function(e,t){return e?(pl(e)?e:[e]).map((function(e){return Ll(e,t)})):[]};function Tl(e){var t=Ll(e);return Sa(Sa({id:fl(e)?e:t.id},t),{type:t.type})}function Rl(e,t){var n="".concat($a.DoneState,".").concat(e),r={type:n,data:t,toString:function(){return n}};return r}function Pl(e,t){var n="".concat($a.DoneInvoke,".").concat(e),r={type:n,data:t,toString:function(){return n}};return r}function Ml(e,t){var n="".concat($a.ErrorPlatform,".").concat(e),r={type:n,data:t,toString:function(){return n}};return r}function Dl(e,t,n,r,i,o,a){void 0===a&&(a=!1);var l=a?[]:function(e){var t,n,r=[];try{for(var i=Oa(e),o=i.next();!o.done;o=i.next())for(var a=o.value,l=0;l<a.actions.length;)a.actions[l].type!==ja?l++:(r.push(a.actions[l]),a.actions.splice(l,1))}catch(e){t={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r}(i),s=l.length?dl(n,r,l,t):n,c=a?[n]:void 0,d=[];function u(i,l){var u;switch(l.type){case Pa:var p=function(e,t,n,r){var i,o={_event:n},a=bl(hl(e.event)?e.event(t,n.data,o):e.event);if(fl(e.delay)){var l=r&&r[e.delay];i=hl(l)?l(t,n.data,o):l}else i=hl(e.delay)?e.delay(t,n.data,o):e.delay;return Sa(Sa({},e),{type:Pa,_event:a,delay:i})}(l,s,r,e.options.delays);return o&&"number"==typeof p.delay&&o(p,s,r),p;case Ma:var h=function(e,t,n,r){var i,o={_event:n},a=bl(hl(e.event)?e.event(t,n.data,o):e.event);if(fl(e.delay)){var l=r&&r[e.delay];i=hl(l)?l(t,n.data,o):l}else i=hl(e.delay)?e.delay(t,n.data,o):e.delay;var s=hl(e.to)?e.to(t,n.data,o):e.to;return Sa(Sa({},e),{to:s,_event:a,event:a.data,delay:i})}(l,s,r,e.options.delays);if(!Ua){var f=l.delay;ul(!fl(f)||"number"==typeof h.delay,"No delay reference for delay expression '".concat(f,"' was found on machine '").concat(e.id,"'"))}return o&&h.to!==ka.Internal&&("entry"===i?d.push(h):o(h,s,r)),h;case Va:var g=function(e,t,n){return Sa(Sa({},e),{value:fl(e.expr)?e.expr:e.expr(t,n.data,{_event:n})})}(l,s,r);return null==o||o(g,s,r),g;case Za:if(!(b=null===(u=l.conds.find((function(n){var i=gl(n.cond,e.options.guards);return!i||Cl(e,i,s,r,o?void 0:t)})))||void 0===u?void 0:u.actions))return[];var v=La(Dl(e,t,s,r,[{type:i,actions:_l(al(b),e.options.actions)}],o,a),2),m=v[0],x=v[1];return s=x,null==c||c.push(s),m;case qa:var b;if(!(b=l.get(s,r.data)))return[];var y=La(Dl(e,t,s,r,[{type:i,actions:_l(al(b),e.options.actions)}],o,a),2),C=y[0],w=y[1];return s=w,null==c||c.push(s),C;case Ra:g=function(e,t,n){var r=hl(e.activity)?e.activity(t,n.data):e.activity,i="string"==typeof r?{id:r}:r;return{type:$a.Stop,activity:i}}(l,s,r);return null==o||o(g,n,r),g;case ja:s=dl(s,r,[l],o?void 0:t),null==c||c.push(s);break;default:var $=Ll(l,e.options.actions),k=$.exec;if(o)o($,s,r);else if(k&&c){var S=c.length-1,E=Sa(Sa({},$),{exec:function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];k.apply(void 0,_a([c[S]],La(t),!1))}});$=E}return $}}var p=il(i.map((function(e){var t,n,i=[];try{for(var a=Oa(e.actions),l=a.next();!l.done;l=a.next()){var c=l.value,p=u(e.type,c);p&&(i=i.concat(p))}}catch(e){t={error:e}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}return d.forEach((function(e){o(e,s,r)})),d.length=0,i})));return[p,s]}var Nl=function(e,t){return t(e)};function jl(e){var t;return(t={id:e,send:function(){},subscribe:function(){return{unsubscribe:function(){}}},getSnapshot:function(){},toJSON:function(){return{id:e}}})[vl]=function(){return this},t}function Vl(e,t,n){var r=jl(t);if(r.deferred=!0,ml(e)){var i=r.state=Nl(void 0,(function(){return(n?e.withContext(n):e).initialState}));r.getSnapshot=function(){return i}}return r}var Il=function(e){return"atomic"===e.type||"final"===e.type};function zl(e){return Object.keys(e.states).map((function(t){return e.states[t]}))}function Al(e){return zl(e).filter((function(e){return"history"!==e.type}))}function Hl(e){var t=[e];return Il(e)?t:t.concat(il(Al(e).map(Hl)))}function Bl(e,t){var n,r,i,o,a,l,s,c,d=Zl(new Set(e)),u=new Set(t);try{for(var p=Oa(u),h=p.next();!h.done;h=p.next())for(var f=($=h.value).parent;f&&!u.has(f);)u.add(f),f=f.parent}catch(e){n={error:e}}finally{try{h&&!h.done&&(r=p.return)&&r.call(p)}finally{if(n)throw n.error}}var g=Zl(u);try{for(var v=Oa(u),m=v.next();!m.done;m=v.next()){if("compound"!==($=m.value).type||g.get($)&&g.get($).length){if("parallel"===$.type)try{for(var x=(a=void 0,Oa(Al($))),b=x.next();!b.done;b=x.next()){var y=b.value;u.has(y)||(u.add(y),d.get(y)?d.get(y).forEach((function(e){return u.add(e)})):y.initialStateNodes.forEach((function(e){return u.add(e)})))}}catch(e){a={error:e}}finally{try{b&&!b.done&&(l=x.return)&&l.call(x)}finally{if(a)throw a.error}}}else d.get($)?d.get($).forEach((function(e){return u.add(e)})):$.initialStateNodes.forEach((function(e){return u.add(e)}))}}catch(e){i={error:e}}finally{try{m&&!m.done&&(o=v.return)&&o.call(v)}finally{if(i)throw i.error}}try{for(var C=Oa(u),w=C.next();!w.done;w=C.next()){var $;for(f=($=w.value).parent;f&&!u.has(f);)u.add(f),f=f.parent}}catch(e){s={error:e}}finally{try{w&&!w.done&&(c=C.return)&&c.call(C)}finally{if(s)throw s.error}}return u}function Fl(e,t){var n=t.get(e);if(!n)return{};if("compound"===e.type){var r=n[0];if(!r)return{};if(Il(r))return r.key}var i={};return n.forEach((function(e){i[e.key]=Fl(e,t)})),i}function Zl(e){var t,n,r=new Map;try{for(var i=Oa(e),o=i.next();!o.done;o=i.next()){var a=o.value;r.has(a)||r.set(a,[]),a.parent&&(r.has(a.parent)||r.set(a.parent,[]),r.get(a.parent).push(a))}}catch(e){t={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r}function ql(e,t){return Fl(e,Zl(Bl([e],t)))}function Gl(e,t){return Array.isArray(e)?e.some((function(e){return e===t})):e instanceof Set&&e.has(t)}function Wl(e,t){return"compound"===t.type?Al(t).some((function(t){return"final"===t.type&&Gl(e,t)})):"parallel"===t.type&&Al(t).every((function(t){return Wl(e,t)}))}function Ul(e){return new Set(il(e.map((function(e){return e.tags}))))}function Xl(e,t){if(e===t)return!0;if(void 0===e||void 0===t)return!1;if(fl(e)||fl(t))return e===t;var n=Object.keys(e),r=Object.keys(t);return n.length===r.length&&n.every((function(n){return Xl(e[n],t[n])}))}var Yl=function(){function e(e){var t,n,r=this;this.actions=[],this.activities=Ga,this.meta={},this.events=[],this.value=e.value,this.context=e.context,this._event=e._event,this._sessionid=e._sessionid,this.event=this._event.data,this.historyValue=e.historyValue,this.history=e.history,this.actions=e.actions||[],this.activities=e.activities||Ga,this.meta=(void 0===(n=e.configuration)&&(n=[]),n.reduce((function(e,t){return void 0!==t.meta&&(e[t.id]=t.meta),e}),{})),this.events=e.events||[],this.matches=this.matches.bind(this),this.toStrings=this.toStrings.bind(this),this.configuration=e.configuration,this.transitions=e.transitions,this.children=e.children,this.done=!!e.done,this.tags=null!==(t=Array.isArray(e.tags)?new Set(e.tags):e.tags)&&void 0!==t?t:new Set,this.machine=e.machine,Object.defineProperty(this,"nextEvents",{get:function(){return function(e){return _a([],La(new Set(il(_a([],La(e.map((function(e){return e.ownEvents}))),!1)))),!1)}(r.configuration)}})}return e.from=function(t,n){return t instanceof e?t.context!==n?new e({value:t.value,context:n,_event:t._event,_sessionid:null,historyValue:t.historyValue,history:t.history,actions:[],activities:t.activities,events:[],configuration:[],transitions:[],children:{}}):t:new e({value:t,context:n,_event:El,_sessionid:null,historyValue:void 0,history:void 0,actions:[],activities:void 0,events:[],configuration:[],transitions:[],children:{}})},e.create=function(t){return new e(t)},e.inert=function(t,n){if(t instanceof e){if(!t.actions.length)return t;var r=El;return new e({value:t.value,context:n,_event:r,_sessionid:null,historyValue:t.historyValue,history:t.history,activities:t.activities,configuration:t.configuration,transitions:[],children:{}})}return e.from(t,n)},e.prototype.toStrings=function(e,t){var n=this;if(void 0===e&&(e=this.value),void 0===t&&(t="."),fl(e))return[e];var r=Object.keys(e);return r.concat.apply(r,_a([],La(r.map((function(r){return n.toStrings(e[r],t).map((function(e){return r+t+e}))}))),!1))},e.prototype.toJSON=function(){var e=this;e.configuration,e.transitions;var t=e.tags;e.machine;var n=Ea(e,["configuration","transitions","tags","machine"]);return Sa(Sa({},n),{tags:Array.from(t)})},e.prototype.matches=function(e){return Xa(e,this.value)},e.prototype.hasTag=function(e){return this.tags.has(e)},e.prototype.can=function(e){var t;Ua&&ul(!!this.machine,"state.can(...) used outside of a machine-created State object; this will always return false.");var n=null===(t=this.machine)||void 0===t?void 0:t.getTransitionData(this,e);return!!(null==n?void 0:n.transitions.length)&&n.transitions.some((function(e){return void 0!==e.target||e.actions.length}))},e}(),Kl={deferEvents:!1},Jl=function(){function e(e){this.processingEvent=!1,this.queue=[],this.initialized=!1,this.options=Sa(Sa({},Kl),e)}return e.prototype.initialize=function(e){if(this.initialized=!0,e){if(!this.options.deferEvents)return void this.schedule(e);this.process(e)}this.flushEvents()},e.prototype.schedule=function(e){if(this.initialized&&!this.processingEvent){if(0!==this.queue.length)throw new Error("Event queue should be empty when it is not processing events");this.process(e),this.flushEvents()}else this.queue.push(e)},e.prototype.clear=function(){this.queue=[]},e.prototype.flushEvents=function(){for(var e=this.queue.shift();e;)this.process(e),e=this.queue.shift()},e.prototype.process=function(e){this.processingEvent=!0;try{e()}catch(e){throw this.clear(),e}finally{this.processingEvent=!1}},e}(),Ql=new Map,es=0,ts=function(){return"x:".concat(es++)},ns=function(e,t){return Ql.set(e,t),e},rs=function(e){return Ql.get(e)},is=function(e){Ql.delete(e)};function os(){return"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:void(Ua||console.warn("XState could not find a global object in this environment. Please let the maintainers know and raise an issue here: https://github.com/statelyai/xstate/issues"))}function as(e){if(os()){var t=function(){var e=os();if(e&&"__xstate__"in e)return e.__xstate__}();t&&t.register(e)}}function ls(e,t){void 0===t&&(t={});var n=e.initialState,r=new Set,i=[],o=!1,a=function(e){var t;return Sa(((t={subscribe:function(){return{unsubscribe:function(){}}},id:"anonymous",getSnapshot:function(){}})[vl]=function(){return this},t),e)}({id:t.id,send:function(t){i.push(t),function(){if(!o){for(o=!0;i.length>0;){var t=i.shift();n=e.transition(n,t,l),r.forEach((function(e){return e.next(n)}))}o=!1}}()},getSnapshot:function(){return n},subscribe:function(e,t,i){var o=$l(e,t,i);return r.add(o),o.next(n),{unsubscribe:function(){r.delete(o)}}}}),l={parent:t.parent,self:a,id:t.id||"anonymous",observers:r};return n=e.start?e.start(l):n,a}var ss,cs={sync:!1,autoForward:!1};!function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"}(ss||(ss={}));var ds=function(){function e(t,n){void 0===n&&(n=e.defaultOptions);var r=this;this.machine=t,this.delayedEventsMap={},this.listeners=new Set,this.contextListeners=new Set,this.stopListeners=new Set,this.doneListeners=new Set,this.eventListeners=new Set,this.sendListeners=new Set,this.initialized=!1,this.status=ss.NotStarted,this.children=new Map,this.forwardTo=new Set,this._outgoingQueue=[],this.init=this.start,this.send=function(e,t){if(pl(e))return r.batch(e),r.state;var n=bl(xl(e,t));if(r.status===ss.Stopped)return Ua||ul(!1,'Event "'.concat(n.name,'" was sent to stopped service "').concat(r.machine.id,'". This service has already reached its final state, and will not transition.\nEvent: ').concat(JSON.stringify(n.data))),r.state;if(r.status!==ss.Running&&!r.options.deferEvents)throw new Error('Event "'.concat(n.name,'" was sent to uninitialized service "').concat(r.machine.id,'". Make sure .start() is called for this service, or set { deferEvents: true } in the service options.\nEvent: ').concat(JSON.stringify(n.data)));return r.scheduler.schedule((function(){r.forward(n);var e=r._nextState(n);r.update(e,n)})),r._state},this.sendTo=function(e,t,n){var i,o=r.parent&&(t===ka.Parent||r.parent.id===t),a=o?r.parent:fl(t)?t===ka.Internal?r:r.children.get(t)||rs(t):(i=t)&&"function"==typeof i.send?t:void 0;if(a)if("machine"in a){if(r.status!==ss.Stopped||r.parent!==a||r.state.done){var l=Sa(Sa({},e),{name:e.name===Ba?"".concat(Ml(r.id)):e.name,origin:r.sessionId});!n&&r.machine.config.predictableActionArguments?r._outgoingQueue.push([a,l]):a.send(l)}}else!n&&r.machine.config.predictableActionArguments?r._outgoingQueue.push([a,e.data]):a.send(e.data);else{if(!o)throw new Error("Unable to send event to child '".concat(t,"' from service '").concat(r.id,"'."));Ua||ul(!1,"Service '".concat(r.id,"' has no parent: unable to send event ").concat(e.type))}},this._exec=function(e,t,n,i){void 0===i&&(i=r.machine.options.actions);var o=e.exec||Ol(e.type,i),a=hl(o)?o:o?o.exec:e.exec;if(a)try{return a(t,n.data,r.machine.config.predictableActionArguments?{action:e,_event:n}:{action:e,state:r.state,_event:n})}catch(e){throw r.parent&&r.parent.send({type:"xstate.error",data:e}),e}switch(e.type){case Pa:var l=e;r.defer(l);break;case Ma:var s=e;if("number"==typeof s.delay)return void r.defer(s);s.to?r.sendTo(s._event,s.to,n===El):r.send(s._event);break;case Da:r.cancel(e.sendId);break;case Ta:if(r.status!==ss.Running)return;var c=e.activity;if(!r.machine.config.predictableActionArguments&&!r.state.activities[c.id||c.type])break;if(c.type===$a.Invoke){var d=wl(c.src),u=r.machine.options.services?r.machine.options.services[d.type]:void 0,p=c.id,h=c.data;Ua||ul(!("forward"in c),"`forward` property is deprecated (found in invocation of '".concat(c.src,"' in in machine '").concat(r.machine.id,"'). ")+"Please use `autoForward` instead.");var f="autoForward"in c?c.autoForward:!!c.forward;if(!u)return void(Ua||ul(!1,"No service found for invocation '".concat(c.src,"' in machine '").concat(r.machine.id,"'.")));var g=h?ll(h,t,n):void 0;if("string"==typeof u)return;var v=hl(u)?u(t,n.data,{data:g,src:d,meta:c.meta}):u;if(!v)return;var m=void 0;ml(v)&&(v=g?v.withContext(g):v,m={autoForward:f}),r.spawn(v,p,m)}else r.spawnActivity(c);break;case Ra:r.stopChild(e.activity.id);break;case Va:var x=e,b=x.label,y=x.value;b?r.logger(b,y):r.logger(y);break;default:Ua||ul(!1,"No implementation found for action type '".concat(e.type,"'"))}};var i=Sa(Sa({},e.defaultOptions),n),o=i.clock,a=i.logger,l=i.parent,s=i.id,c=void 0!==s?s:t.id;this.id=c,this.logger=a,this.clock=o,this.parent=l,this.options=i,this.scheduler=new Jl({deferEvents:this.options.deferEvents}),this.sessionId=ts()}return Object.defineProperty(e.prototype,"initialState",{get:function(){var e=this;return this._initialState?this._initialState:Nl(this,(function(){return e._initialState=e.machine.initialState,e._initialState}))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"state",{get:function(){return Ua||ul(this.status!==ss.NotStarted,"Attempted to read state from uninitialized service '".concat(this.id,"'. Make sure the service is started first.")),this._state},enumerable:!1,configurable:!0}),e.prototype.execute=function(e,t){var n,r;try{for(var i=Oa(e.actions),o=i.next();!o.done;o=i.next()){var a=o.value;this.exec(a,e,t)}}catch(e){n={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}},e.prototype.update=function(e,t){var n,r,i,o,a,l,s,c,d=this;if(e._sessionid=this.sessionId,this._state=e,this.machine.config.predictableActionArguments&&t!==El||!this.options.execute)for(var u=void 0;u=this._outgoingQueue.shift();)u[0].send(u[1]);else this.execute(this.state);if(this.children.forEach((function(e){d.state.children[e.id]=e})),this.devTools&&this.devTools.send(t.data,e),e.event)try{for(var p=Oa(this.eventListeners),h=p.next();!h.done;h=p.next()){(0,h.value)(e.event)}}catch(e){n={error:e}}finally{try{h&&!h.done&&(r=p.return)&&r.call(p)}finally{if(n)throw n.error}}try{for(var f=Oa(this.listeners),g=f.next();!g.done;g=f.next()){(0,g.value)(e,e.event)}}catch(e){i={error:e}}finally{try{g&&!g.done&&(o=f.return)&&o.call(f)}finally{if(i)throw i.error}}try{for(var v=Oa(this.contextListeners),m=v.next();!m.done;m=v.next()){(0,m.value)(this.state.context,this.state.history?this.state.history.context:void 0)}}catch(e){a={error:e}}finally{try{m&&!m.done&&(l=v.return)&&l.call(v)}finally{if(a)throw a.error}}if(this.state.done){var x=e.configuration.find((function(e){return"final"===e.type&&e.parent===d.machine})),b=x&&x.doneData?ll(x.doneData,e.context,t):void 0;this._doneEvent=Pl(this.id,b);try{for(var y=Oa(this.doneListeners),C=y.next();!C.done;C=y.next()){(0,C.value)(this._doneEvent)}}catch(e){s={error:e}}finally{try{C&&!C.done&&(c=y.return)&&c.call(y)}finally{if(s)throw s.error}}this._stop(),this._stopChildren(),is(this.sessionId)}},e.prototype.onTransition=function(e){return this.listeners.add(e),this.status===ss.Running&&e(this.state,this.state.event),this},e.prototype.subscribe=function(e,t,n){var r=this,i=$l(e,t,n);this.listeners.add(i.next),this.status!==ss.NotStarted&&i.next(this.state);var o=function(){r.doneListeners.delete(o),r.stopListeners.delete(o),i.complete()};return this.status===ss.Stopped?i.complete():(this.onDone(o),this.onStop(o)),{unsubscribe:function(){r.listeners.delete(i.next),r.doneListeners.delete(o),r.stopListeners.delete(o)}}},e.prototype.onEvent=function(e){return this.eventListeners.add(e),this},e.prototype.onSend=function(e){return this.sendListeners.add(e),this},e.prototype.onChange=function(e){return this.contextListeners.add(e),this},e.prototype.onStop=function(e){return this.stopListeners.add(e),this},e.prototype.onDone=function(e){return this.status===ss.Stopped&&this._doneEvent?e(this._doneEvent):this.doneListeners.add(e),this},e.prototype.off=function(e){return this.listeners.delete(e),this.eventListeners.delete(e),this.sendListeners.delete(e),this.stopListeners.delete(e),this.doneListeners.delete(e),this.contextListeners.delete(e),this},e.prototype.start=function(e){var t=this;if(this.status===ss.Running)return this;this.machine._init(),ns(this.sessionId,this),this.initialized=!0,this.status=ss.Running;var n=void 0===e?this.initialState:Nl(this,(function(){return"object"==typeof(n=e)&&null!==n&&"value"in n&&"_event"in n?t.machine.resolveState(e):t.machine.resolveState(Yl.from(e,t.machine.context));var n}));return this.options.devTools&&this.attachDev(),this.scheduler.initialize((function(){t.update(n,El)})),this},e.prototype._stopChildren=function(){this.children.forEach((function(e){hl(e.stop)&&e.stop()})),this.children.clear()},e.prototype._stop=function(){var e,t,n,r,i,o,a,l,s,c;try{for(var d=Oa(this.listeners),u=d.next();!u.done;u=d.next()){var p=u.value;this.listeners.delete(p)}}catch(t){e={error:t}}finally{try{u&&!u.done&&(t=d.return)&&t.call(d)}finally{if(e)throw e.error}}try{for(var h=Oa(this.stopListeners),f=h.next();!f.done;f=h.next()){(p=f.value)(),this.stopListeners.delete(p)}}catch(e){n={error:e}}finally{try{f&&!f.done&&(r=h.return)&&r.call(h)}finally{if(n)throw n.error}}try{for(var g=Oa(this.contextListeners),v=g.next();!v.done;v=g.next()){p=v.value;this.contextListeners.delete(p)}}catch(e){i={error:e}}finally{try{v&&!v.done&&(o=g.return)&&o.call(g)}finally{if(i)throw i.error}}try{for(var m=Oa(this.doneListeners),x=m.next();!x.done;x=m.next()){p=x.value;this.doneListeners.delete(p)}}catch(e){a={error:e}}finally{try{x&&!x.done&&(l=m.return)&&l.call(m)}finally{if(a)throw a.error}}if(!this.initialized)return this;this.initialized=!1,this.status=ss.Stopped,this._initialState=void 0;try{for(var b=Oa(Object.keys(this.delayedEventsMap)),y=b.next();!y.done;y=b.next()){var C=y.value;this.clock.clearTimeout(this.delayedEventsMap[C])}}catch(e){s={error:e}}finally{try{y&&!y.done&&(c=b.return)&&c.call(b)}finally{if(s)throw s.error}}this.scheduler.clear(),this.scheduler=new Jl({deferEvents:this.options.deferEvents})},e.prototype.stop=function(){var e=this,t=this.scheduler;return this._stop(),t.schedule((function(){var t;if(!(null===(t=e._state)||void 0===t?void 0:t.done)){var n=bl({type:"xstate.stop"}),r=Nl(e,(function(){var t=il(_a([],La(e.state.configuration),!1).sort((function(e,t){return t.order-e.order})).map((function(t){return _l(t.onExit,e.machine.options.actions)}))),r=La(Dl(e.machine,e.state,e.state.context,n,[{type:"exit",actions:t}],e.machine.config.predictableActionArguments?e._exec:void 0,e.machine.config.predictableActionArguments||e.machine.config.preserveActionOrder),2),i=r[0],o=r[1],a=new Yl({value:e.state.value,context:o,_event:n,_sessionid:e.sessionId,historyValue:void 0,history:e.state,actions:i.filter((function(e){return!Sl(e)})),activities:{},events:[],configuration:[],transitions:[],children:{},done:e.state.done,tags:e.state.tags,machine:e.machine});return a.changed=!0,a}));e.update(r,n),e._stopChildren(),is(e.sessionId)}})),this},e.prototype.batch=function(e){var t=this;if(this.status===ss.NotStarted&&this.options.deferEvents)Ua||ul(!1,"".concat(e.length,' event(s) were sent to uninitialized service "').concat(this.machine.id,'" and are deferred. Make sure .start() is called for this service.\nEvent: ').concat(JSON.stringify(event)));else if(this.status!==ss.Running)throw new Error("".concat(e.length,' event(s) were sent to uninitialized service "').concat(this.machine.id,'". Make sure .start() is called for this service, or set { deferEvents: true } in the service options.'));if(e.length){var n=!!this.machine.config.predictableActionArguments&&this._exec;this.scheduler.schedule((function(){var r,i,o=t.state,a=!1,l=[],s=function(e){var r=bl(e);t.forward(r),o=Nl(t,(function(){return t.machine.transition(o,r,void 0,n||void 0)})),l.push.apply(l,_a([],La(t.machine.config.predictableActionArguments?o.actions:o.actions.map((function(e){return function(e,t){var n=e.exec;return Sa(Sa({},e),{exec:void 0!==n?function(){return n(t.context,t.event,{action:e,state:t,_event:t._event})}:void 0})}(e,o)}))),!1)),a=a||!!o.changed};try{for(var c=Oa(e),d=c.next();!d.done;d=c.next()){s(d.value)}}catch(e){r={error:e}}finally{try{d&&!d.done&&(i=c.return)&&i.call(c)}finally{if(r)throw r.error}}o.changed=a,o.actions=l,t.update(o,bl(e[e.length-1]))}))}},e.prototype.sender=function(e){return this.send.bind(this,e)},e.prototype._nextState=function(e,t){var n=this;void 0===t&&(t=!!this.machine.config.predictableActionArguments&&this._exec);var r=bl(e);if(0===r.name.indexOf(Ha)&&!this.state.nextEvents.some((function(e){return 0===e.indexOf(Ha)})))throw r.data.data;return Nl(this,(function(){return n.machine.transition(n.state,r,void 0,t||void 0)}))},e.prototype.nextState=function(e){return this._nextState(e,!1)},e.prototype.forward=function(e){var t,n;try{for(var r=Oa(this.forwardTo),i=r.next();!i.done;i=r.next()){var o=i.value,a=this.children.get(o);if(!a)throw new Error("Unable to forward event '".concat(e,"' from interpreter '").concat(this.id,"' to nonexistant child '").concat(o,"'."));a.send(e)}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}},e.prototype.defer=function(e){var t=this,n=this.clock.setTimeout((function(){"to"in e&&e.to?t.sendTo(e._event,e.to,!0):t.send(e._event)}),e.delay);e.id&&(this.delayedEventsMap[e.id]=n)},e.prototype.cancel=function(e){this.clock.clearTimeout(this.delayedEventsMap[e]),delete this.delayedEventsMap[e]},e.prototype.exec=function(e,t,n){void 0===n&&(n=this.machine.options.actions),this._exec(e,t.context,t._event,n)},e.prototype.removeChild=function(e){var t;this.children.delete(e),this.forwardTo.delete(e),null===(t=this.state)||void 0===t||delete t.children[e]},e.prototype.stopChild=function(e){var t=this.children.get(e);t&&(this.removeChild(e),hl(t.stop)&&t.stop())},e.prototype.spawn=function(e,t,n){if(this.status!==ss.Running)return Vl(e,t);if(sl(e))return this.spawnPromise(Promise.resolve(e),t);if(hl(e))return this.spawnCallback(e,t);if(function(e){try{return"function"==typeof e.send}catch(e){return!1}}(i=e)&&"id"in i)return this.spawnActor(e,t);if(function(e){try{return"subscribe"in e&&hl(e.subscribe)}catch(e){return!1}}(e))return this.spawnObservable(e,t);if(ml(e))return this.spawnMachine(e,Sa(Sa({},n),{id:t}));if(null!==(r=e)&&"object"==typeof r&&"transition"in r&&"function"==typeof r.transition)return this.spawnBehavior(e,t);throw new Error('Unable to spawn entity "'.concat(t,'" of type "').concat(typeof e,'".'));var r,i},e.prototype.spawnMachine=function(t,n){var r=this;void 0===n&&(n={});var i=new e(t,Sa(Sa({},this.options),{parent:this,id:n.id||t.id})),o=Sa(Sa({},cs),n);o.sync&&i.onTransition((function(e){r.send(Fa,{state:e,id:i.id})}));var a=i;return this.children.set(i.id,a),o.autoForward&&this.forwardTo.add(i.id),i.onDone((function(e){r.removeChild(i.id),r.send(bl(e,{origin:i.id}))})).start(),a},e.prototype.spawnBehavior=function(e,t){var n=ls(e,{id:t,parent:this});return this.children.set(t,n),n},e.prototype.spawnPromise=function(e,t){var n,r,i=this,o=!1;e.then((function(e){o||(r=e,i.removeChild(t),i.send(bl(Pl(t,e),{origin:t})))}),(function(e){if(!o){i.removeChild(t);var n=Ml(t,e);try{i.send(bl(n,{origin:t}))}catch(r){!function(e,t,n){if(!Ua){var r=e.stack?" Stacktrace was '".concat(e.stack,"'"):"";if(e===t)console.error("Missing onError handler for invocation '".concat(n,"', error was '").concat(e,"'.").concat(r));else{var i=t.stack?" Stacktrace was '".concat(t.stack,"'"):"";console.error("Missing onError handler and/or unhandled exception/promise rejection for invocation '".concat(n,"'. ")+"Original error: '".concat(e,"'. ").concat(r," Current error is '").concat(t,"'.").concat(i))}}}(e,r,t),i.devTools&&i.devTools.send(n,i.state),i.machine.strict&&i.stop()}}}));var a=((n={id:t,send:function(){},subscribe:function(t,n,r){var i=$l(t,n,r),o=!1;return e.then((function(e){o||(i.next(e),o||i.complete())}),(function(e){o||i.error(e)})),{unsubscribe:function(){return o=!0}}},stop:function(){o=!0},toJSON:function(){return{id:t}},getSnapshot:function(){return r}})[vl]=function(){return this},n);return this.children.set(t,a),a},e.prototype.spawnCallback=function(e,t){var n,r,i,o=this,a=!1,l=new Set,s=new Set;try{i=e((function(e){r=e,s.forEach((function(t){return t(e)})),a||o.send(bl(e,{origin:t}))}),(function(e){l.add(e)}))}catch(e){this.send(Ml(t,e))}if(sl(i))return this.spawnPromise(i,t);var c=((n={id:t,send:function(e){return l.forEach((function(t){return t(e)}))},subscribe:function(e){var t=$l(e);return s.add(t.next),{unsubscribe:function(){s.delete(t.next)}}},stop:function(){a=!0,hl(i)&&i()},toJSON:function(){return{id:t}},getSnapshot:function(){return r}})[vl]=function(){return this},n);return this.children.set(t,c),c},e.prototype.spawnObservable=function(e,t){var n,r,i=this,o=e.subscribe((function(e){r=e,i.send(bl(e,{origin:t}))}),(function(e){i.removeChild(t),i.send(bl(Ml(t,e),{origin:t}))}),(function(){i.removeChild(t),i.send(bl(Pl(t),{origin:t}))})),a=((n={id:t,send:function(){},subscribe:function(t,n,r){return e.subscribe(t,n,r)},stop:function(){return o.unsubscribe()},getSnapshot:function(){return r},toJSON:function(){return{id:t}}})[vl]=function(){return this},n);return this.children.set(t,a),a},e.prototype.spawnActor=function(e,t){return this.children.set(t,e),e},e.prototype.spawnActivity=function(e){var t=this.machine.options&&this.machine.options.activities?this.machine.options.activities[e.type]:void 0;if(t){var n=t(this.state.context,e);this.spawnEffect(e.id,n)}else Ua||ul(!1,"No implementation found for activity '".concat(e.type,"'"))},e.prototype.spawnEffect=function(e,t){var n;this.children.set(e,((n={id:e,send:function(){},subscribe:function(){return{unsubscribe:function(){}}},stop:t||void 0,getSnapshot:function(){},toJSON:function(){return{id:e}}})[vl]=function(){return this},n))},e.prototype.attachDev=function(){var e=os();if(this.options.devTools&&e){if(e.__REDUX_DEVTOOLS_EXTENSION__){var t="object"==typeof this.options.devTools?this.options.devTools:void 0;this.devTools=e.__REDUX_DEVTOOLS_EXTENSION__.connect(Sa(Sa({name:this.id,autoPause:!0,stateSanitizer:function(e){return{value:e.value,context:e.context,actions:e.actions}}},t),{features:Sa({jump:!1,skip:!1},t?t.features:void 0)}),this.machine),this.devTools.init(this.state)}as(this)}},e.prototype.toJSON=function(){return{id:this.id}},e.prototype[vl]=function(){return this},e.prototype.getSnapshot=function(){return this.status===ss.NotStarted?this.initialState:this._state},e.defaultOptions={execute:!0,deferEvents:!0,clock:{setTimeout:function(e,t){return setTimeout(e,t)},clearTimeout:function(e){return clearTimeout(e)}},logger:console.log.bind(console),devTools:!1},e.interpret=us,e}();function us(e,t){return new ds(e,t)}function ps(e){if("string"==typeof e){var t={type:e,toString:function(){return e}};return t}return e}function hs(e){return Sa(Sa({type:za},e),{toJSON:function(){e.onDone,e.onError;var t=Ea(e,["onDone","onError"]);return Sa(Sa({},t),{type:za,src:ps(e.src)})}})}var fs="",gs="*",vs={},ms=function(e){return"#"===e[0]},xs=function(){function e(t,n,r,i){void 0===r&&(r="context"in t?t.context:void 0);var o,a=this;this.config=t,this._context=r,this.order=-1,this.__xstatenode=!0,this.__cache={events:void 0,relativeValue:new Map,initialStateValue:void 0,initialState:void 0,on:void 0,transitions:void 0,candidates:{},delayedTransitions:void 0},this.idMap={},this.tags=[],this.options=Object.assign({actions:{},guards:{},services:{},activities:{},delays:{}},n),this.parent=null==i?void 0:i.parent,this.key=this.config.key||(null==i?void 0:i.key)||this.config.id||"(machine)",this.machine=this.parent?this.parent.machine:this,this.path=this.parent?this.parent.path.concat(this.key):[],this.delimiter=this.config.delimiter||(this.parent?this.parent.delimiter:"."),this.id=this.config.id||_a([this.machine.key],La(this.path),!1).join(this.delimiter),this.version=this.parent?this.parent.version:this.config.version,this.type=this.config.type||(this.config.parallel?"parallel":this.config.states&&Object.keys(this.config.states).length?"compound":this.config.history?"history":"atomic"),this.schema=this.parent?this.machine.schema:null!==(o=this.config.schema)&&void 0!==o?o:{},this.description=this.config.description,Ua||ul(!("parallel"in this.config),'The "parallel" property is deprecated and will be removed in version 4.1. '.concat(this.config.parallel?"Replace with `type: 'parallel'`":"Use `type: '".concat(this.type,"'`")," in the config for state node '").concat(this.id,"' instead.")),this.initial=this.config.initial,this.states=this.config.states?el(this.config.states,(function(t,n){var r,i=new e(t,{},void 0,{parent:a,key:n});return Object.assign(a.idMap,Sa(((r={})[i.id]=i,r),i.idMap)),i})):vs;var l=0;!function e(t){var n,r;t.order=l++;try{for(var i=Oa(zl(t)),o=i.next();!o.done;o=i.next()){e(o.value)}}catch(e){n={error:e}}finally{try{o&&!o.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}}(this),this.history=!0===this.config.history?"shallow":this.config.history||!1,this._transient=!!this.config.always||!!this.config.on&&(Array.isArray(this.config.on)?this.config.on.some((function(e){return e.event===fs})):fs in this.config.on),this.strict=!!this.config.strict,this.onEntry=al(this.config.entry||this.config.onEntry).map((function(e){return Ll(e)})),this.onExit=al(this.config.exit||this.config.onExit).map((function(e){return Ll(e)})),this.meta=this.config.meta,this.doneData="final"===this.type?this.config.data:void 0,this.invoke=al(this.config.invoke).map((function(e,t){var n,r;if(ml(e)){var i=kl(a.id,t);return a.machine.options.services=Sa(((n={})[i]=e,n),a.machine.options.services),hs({src:i,id:i})}if(fl(e.src)){i=e.id||kl(a.id,t);return hs(Sa(Sa({},e),{id:i,src:e.src}))}if(ml(e.src)||hl(e.src)){i=e.id||kl(a.id,t);return a.machine.options.services=Sa(((r={})[i]=e.src,r),a.machine.options.services),hs(Sa(Sa({id:i},e),{src:i}))}var o=e.src;return hs(Sa(Sa({id:kl(a.id,t)},e),{src:o}))})),this.activities=al(this.config.activities).concat(this.invoke).map((function(e){return Tl(e)})),this.transition=this.transition.bind(this),this.tags=al(this.config.tags)}return e.prototype._init=function(){this.__cache.transitions||Hl(this).forEach((function(e){return e.on}))},e.prototype.withConfig=function(t,n){var r=this.options,i=r.actions,o=r.activities,a=r.guards,l=r.services,s=r.delays;return new e(this.config,{actions:Sa(Sa({},i),t.actions),activities:Sa(Sa({},o),t.activities),guards:Sa(Sa({},a),t.guards),services:Sa(Sa({},l),t.services),delays:Sa(Sa({},s),t.delays)},null!=n?n:this.context)},e.prototype.withContext=function(t){return new e(this.config,this.options,t)},Object.defineProperty(e.prototype,"context",{get:function(){return hl(this._context)?this._context():this._context},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"definition",{get:function(){return{id:this.id,key:this.key,version:this.version,context:this.context,type:this.type,initial:this.initial,history:this.history,states:el(this.states,(function(e){return e.definition})),on:this.on,transitions:this.transitions,entry:this.onEntry,exit:this.onExit,activities:this.activities||[],meta:this.meta,order:this.order||-1,data:this.doneData,invoke:this.invoke,description:this.description,tags:this.tags}},enumerable:!1,configurable:!0}),e.prototype.toJSON=function(){return this.definition},Object.defineProperty(e.prototype,"on",{get:function(){if(this.__cache.on)return this.__cache.on;var e=this.transitions;return this.__cache.on=e.reduce((function(e,t){return e[t.eventType]=e[t.eventType]||[],e[t.eventType].push(t),e}),{})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"after",{get:function(){return this.__cache.delayedTransitions||(this.__cache.delayedTransitions=this.getDelayedTransitions(),this.__cache.delayedTransitions)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"transitions",{get:function(){return this.__cache.transitions||(this.__cache.transitions=this.formatTransitions(),this.__cache.transitions)},enumerable:!1,configurable:!0}),e.prototype.getCandidates=function(e){if(this.__cache.candidates[e])return this.__cache.candidates[e];var t=e===fs,n=this.transitions.filter((function(n){var r=n.eventType===e;return t?r:r||n.eventType===gs}));return this.__cache.candidates[e]=n,n},e.prototype.getDelayedTransitions=function(){var e=this,t=this.config.after;if(!t)return[];var n=function(t,n){var r=function(e,t){var n=t?"#".concat(t):"";return"".concat($a.After,"(").concat(e,")").concat(n)}(hl(t)?"".concat(e.id,":delay[").concat(n,"]"):t,e.id);return e.onEntry.push(function(e,t){return{to:t?t.to:void 0,type:Ma,event:hl(e)?e:xl(e),delay:t?t.delay:void 0,id:t&&void 0!==t.id?t.id:hl(e)?e.name:Ya(e)}}(r,{delay:t})),e.onExit.push({type:Da,sendId:r}),r},r=pl(t)?t.map((function(e,t){var r=n(e.delay,t);return Sa(Sa({},e),{event:r})})):il(Object.keys(t).map((function(e,r){var i=t[e],o=fl(i)?{target:i}:i,a=isNaN(+e)?e:+e,l=n(a,r);return al(o).map((function(e){return Sa(Sa({},e),{event:l,delay:a})}))})));return r.map((function(t){var n=t.delay;return Sa(Sa({},e.formatTransition(t)),{delay:n})}))},e.prototype.getStateNodes=function(e){var t,n=this;if(!e)return[];var r=e instanceof Yl?e.value:Ja(e,this.delimiter);if(fl(r)){var i=this.getStateNode(r).initial;return void 0!==i?this.getStateNodes(((t={})[r]=i,t)):[this,this.states[r]]}var o=Object.keys(r),a=[this];return a.push.apply(a,_a([],La(il(o.map((function(e){return n.getStateNode(e).getStateNodes(r[e])})))),!1)),a},e.prototype.handles=function(e){var t=Ya(e);return this.events.includes(t)},e.prototype.resolveState=function(e){var t=e instanceof Yl?e:Yl.create(e),n=Array.from(Bl([],this.getStateNodes(t.value)));return new Yl(Sa(Sa({},t),{value:this.resolve(t.value),configuration:n,done:Wl(n,this),tags:Ul(n),machine:this.machine}))},e.prototype.transitionLeafNode=function(e,t,n){var r=this.getStateNode(e).next(t,n);return r&&r.transitions.length?r:this.next(t,n)},e.prototype.transitionCompoundNode=function(e,t,n){var r=Object.keys(e),i=this.getStateNode(r[0])._transition(e[r[0]],t,n);return i&&i.transitions.length?i:this.next(t,n)},e.prototype.transitionParallelNode=function(e,t,n){var r,i,o={};try{for(var a=Oa(Object.keys(e)),l=a.next();!l.done;l=a.next()){var s=l.value,c=e[s];if(c){var d=this.getStateNode(s)._transition(c,t,n);d&&(o[s]=d)}}}catch(e){r={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}var u=Object.keys(o).map((function(e){return o[e]})),p=il(u.map((function(e){return e.transitions})));if(!u.some((function(e){return e.transitions.length>0})))return this.next(t,n);var h=il(Object.keys(o).map((function(e){return o[e].configuration})));return{transitions:p,exitSet:il(u.map((function(e){return e.exitSet}))),configuration:h,source:t,actions:il(Object.keys(o).map((function(e){return o[e].actions})))}},e.prototype._transition=function(e,t,n){return fl(e)?this.transitionLeafNode(e,t,n):1===Object.keys(e).length?this.transitionCompoundNode(e,t,n):this.transitionParallelNode(e,t,n)},e.prototype.getTransitionData=function(e,t){return this._transition(e.value,e,bl(t))},e.prototype.next=function(e,t){var n,r,i,o=this,a=t.name,l=[],s=[];try{for(var c=Oa(this.getCandidates(a)),d=c.next();!d.done;d=c.next()){var u=d.value,p=u.cond,h=u.in,f=e.context,g=!h||(fl(h)&&ms(h)?e.matches(Ja(this.getStateNodeById(h).path,this.delimiter)):Xa(Ja(h,this.delimiter),nl(this.path.slice(0,-2))(e.value))),v=!1;try{v=!p||Cl(this.machine,p,f,t,e)}catch(e){throw new Error("Unable to evaluate guard '".concat(p.name||p.type,"' in transition for event '").concat(a,"' in state node '").concat(this.id,"':\n").concat(e.message))}if(v&&g){void 0!==u.target&&(s=u.target),l.push.apply(l,_a([],La(u.actions),!1)),i=u;break}}}catch(e){n={error:e}}finally{try{d&&!d.done&&(r=c.return)&&r.call(c)}finally{if(n)throw n.error}}if(i){if(!s.length)return{transitions:[i],exitSet:[],configuration:e.value?[this]:[],source:e,actions:l};var m=il(s.map((function(t){return o.getRelativeStateNodes(t,e.historyValue)})));return{transitions:[i],exitSet:!!i.internal?[]:il(s.map((function(e){return o.getPotentiallyReenteringNodes(e)}))),configuration:m,source:e,actions:l}}},e.prototype.getPotentiallyReenteringNodes=function(e){if(this.order<e.order)return[this];for(var t=[],n=this,r=e;n&&n!==r;)t.push(n),n=n.parent;return n!==r?[]:(t.push(r),t)},e.prototype.getActions=function(e,t,n,r,i,o,a){var l,s,c,d,u=this,p=o?Bl([],this.getStateNodes(o.value)):[],h=new Set;try{for(var f=Oa(Array.from(e).sort((function(e,t){return e.order-t.order}))),g=f.next();!g.done;g=f.next()){(!Gl(p,x=g.value)||Gl(n.exitSet,x)||x.parent&&h.has(x.parent))&&h.add(x)}}catch(e){l={error:e}}finally{try{g&&!g.done&&(s=f.return)&&s.call(f)}finally{if(l)throw l.error}}try{for(var v=Oa(p),m=v.next();!m.done;m=v.next()){var x;Gl(e,x=m.value)&&!Gl(n.exitSet,x.parent)||n.exitSet.push(x)}}catch(e){c={error:e}}finally{try{m&&!m.done&&(d=v.return)&&d.call(v)}finally{if(c)throw c.error}}n.exitSet.sort((function(e,t){return t.order-e.order}));var b=Array.from(h).sort((function(e,t){return e.order-t.order})),y=new Set(n.exitSet),C=il(b.map((function(e){var t=[];if("final"!==e.type)return t;var o=e.parent;if(!o.parent)return t;t.push(Rl(e.id,e.doneData),Rl(o.id,e.doneData?ll(e.doneData,r,i):void 0));var a=o.parent;return"parallel"===a.type&&Al(a).every((function(e){return Wl(n.configuration,e)}))&&t.push(Rl(a.id)),t}))),w=b.map((function(e){var t=e.onEntry,n=e.activities.map((function(e){return function(e){var t=Tl(e);return{type:$a.Start,activity:t,exec:void 0}}(e)}));return{type:"entry",actions:_l(a?_a(_a([],La(t),!1),La(n),!1):_a(_a([],La(n),!1),La(t),!1),u.machine.options.actions)}})).concat({type:"state_done",actions:C.map((function(e){return function(e,t){return{type:Pa,event:"function"==typeof e?e:xl(e),delay:t?t.delay:void 0,id:null==t?void 0:t.id}}(e)}))}),$=Array.from(y).map((function(e){return{type:"exit",actions:_l(_a(_a([],La(e.onExit),!1),La(e.activities.map((function(e){return function(e){var t=hl(e)?e:Tl(e);return{type:$a.Stop,activity:t,exec:void 0}}(e)}))),!1),u.machine.options.actions)}})).concat({type:"transition",actions:_l(n.actions,this.machine.options.actions)}).concat(w);if(t){var k=_l(il(_a([],La(e),!1).sort((function(e,t){return t.order-e.order})).map((function(e){return e.onExit}))),this.machine.options.actions).filter((function(e){return!Sl(e)}));return $.concat({type:"stop",actions:k})}return $},e.prototype.transition=function(e,t,n,r){void 0===e&&(e=this.initialState);var i,o,a=bl(t);if(e instanceof Yl)i=void 0===n?e:this.resolveState(Yl.from(e,n));else{var l=fl(e)?this.resolve(Qa(this.getResolvedPath(e))):this.resolve(e),s=null!=n?n:this.machine.context;i=this.resolveState(Yl.from(l,s))}if(!Ua&&a.name===gs)throw new Error("An event cannot have the wildcard type ('".concat(gs,"')"));if(this.strict&&!this.events.includes(a.name)&&(o=a.name,!/^(done|error)\./.test(o)))throw new Error("Machine '".concat(this.id,"' does not accept event '").concat(a.name,"'"));var c=this._transition(i.value,i,a)||{transitions:[],configuration:[],exitSet:[],source:i,actions:[]},d=Bl([],this.getStateNodes(i.value)),u=c.configuration.length?Bl(d,c.configuration):d;return c.configuration=_a([],La(u),!1),this.resolveTransition(c,i,i.context,r,a)},e.prototype.resolveRaisedTransition=function(e,t,n,r){var i,o=e.actions;return(e=this.transition(e,t,void 0,r))._event=n,e.event=n.data,(i=e.actions).unshift.apply(i,_a([],La(o),!1)),e},e.prototype.resolveTransition=function(e,t,n,r,i){var o,a,l,s,c=this;void 0===i&&(i=El);var d=e.configuration,u=!t||e.transitions.length>0,p=u?e.configuration:t?t.configuration:[],h=Wl(p,this),f=u?ql(this.machine,d):void 0,g=t?t.historyValue?t.historyValue:e.source?this.machine.historyValue(t.value):void 0:void 0,v=this.getActions(new Set(p),h,e,n,i,t,r),m=t?Sa({},t.activities):{};try{for(var x=Oa(v),b=x.next();!b.done;b=x.next()){var y=b.value;try{for(var C=(l=void 0,Oa(y.actions)),w=C.next();!w.done;w=C.next()){var $=w.value;$.type===Ta?m[$.activity.id||$.activity.type]=$:$.type===Ra&&(m[$.activity.id||$.activity.type]=!1)}}catch(e){l={error:e}}finally{try{w&&!w.done&&(s=C.return)&&s.call(C)}finally{if(l)throw l.error}}}}catch(e){o={error:e}}finally{try{b&&!b.done&&(a=x.return)&&a.call(x)}finally{if(o)throw o.error}}var k,S,E=La(Dl(this,t,n,i,v,r,this.machine.config.predictableActionArguments||this.machine.config.preserveActionOrder),2),O=E[0],L=E[1],_=La(function(e,t){var n,r,i=La([[],[]],2),o=i[0],a=i[1];try{for(var l=Oa(e),s=l.next();!s.done;s=l.next()){var c=s.value;t(c)?o.push(c):a.push(c)}}catch(e){n={error:e}}finally{try{s&&!s.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}return[o,a]}(O,Sl),2),T=_[0],R=_[1],P=O.filter((function(e){var t;return e.type===Ta&&(null===(t=e.activity)||void 0===t?void 0:t.type)===za})),M=P.reduce((function(e,t){return e[t.activity.id]=function(e,t,n,r){var i,o=wl(e.src),a=null===(i=null==t?void 0:t.options.services)||void 0===i?void 0:i[o.type],l=e.data?ll(e.data,n,r):void 0,s=a?Vl(a,e.id,l):jl(e.id);return s.meta=e,s}(t.activity,c.machine,L,i),e}),t?Sa({},t.children):{}),D=new Yl({value:f||t.value,context:L,_event:i,_sessionid:t?t._sessionid:null,historyValue:f?g?(k=g,S=f,{current:S,states:cl(k,S)}):void 0:t?t.historyValue:void 0,history:!f||e.source?t:void 0,actions:f?R:[],activities:f?m:t?t.activities:{},events:[],configuration:p,transitions:e.transitions,children:M,done:h,tags:Ul(p),machine:this}),N=n!==L;D.changed=i.name===Fa||N;var j=D.history;j&&delete j.history;var V=!h&&(this._transient||d.some((function(e){return e._transient})));if(!(u||V&&i.name!==fs))return D;var I=D;if(!h)for(V&&(I=this.resolveRaisedTransition(I,{type:Na},i,r));T.length;){var z=T.shift();I=this.resolveRaisedTransition(I,z._event,i,r)}var A=I.changed||(j?!!I.actions.length||N||typeof j.value!=typeof I.value||!Xl(I.value,j.value):void 0);return I.changed=A,I.history=j,I},e.prototype.getStateNode=function(e){if(ms(e))return this.machine.getStateNodeById(e);if(!this.states)throw new Error("Unable to retrieve child state '".concat(e,"' from '").concat(this.id,"'; no child states exist."));var t=this.states[e];if(!t)throw new Error("Child state '".concat(e,"' does not exist on '").concat(this.id,"'"));return t},e.prototype.getStateNodeById=function(e){var t=ms(e)?e.slice(1):e;if(t===this.id)return this;var n=this.machine.idMap[t];if(!n)throw new Error("Child state node '#".concat(t,"' does not exist on machine '").concat(this.id,"'"));return n},e.prototype.getStateNodeByPath=function(e){if("string"==typeof e&&ms(e))try{return this.getStateNodeById(e.slice(1))}catch(e){}for(var t=Ka(e,this.delimiter).slice(),n=this;t.length;){var r=t.shift();if(!r.length)break;n=n.getStateNode(r)}return n},e.prototype.resolve=function(e){var t,n=this;if(!e)return this.initialStateValue||vs;switch(this.type){case"parallel":return el(this.initialStateValue,(function(t,r){return t?n.getStateNode(r).resolve(e[r]||t):vs}));case"compound":if(fl(e)){var r=this.getStateNode(e);return"parallel"===r.type||"compound"===r.type?((t={})[e]=r.initialStateValue,t):e}return Object.keys(e).length?el(e,(function(e,t){return e?n.getStateNode(t).resolve(e):vs})):this.initialStateValue||{};default:return e||vs}},e.prototype.getResolvedPath=function(e){if(ms(e)){var t=this.machine.idMap[e.slice(1)];if(!t)throw new Error("Unable to find state node '".concat(e,"'"));return t.path}return Ka(e,this.delimiter)},Object.defineProperty(e.prototype,"initialStateValue",{get:function(){var e,t;if(this.__cache.initialStateValue)return this.__cache.initialStateValue;if("parallel"===this.type)t=tl(this.states,(function(e){return e.initialStateValue||vs}),(function(e){return!("history"===e.type)}));else if(void 0!==this.initial){if(!this.states[this.initial])throw new Error("Initial state '".concat(this.initial,"' not found on '").concat(this.key,"'"));t=Il(this.states[this.initial])?this.initial:((e={})[this.initial]=this.states[this.initial].initialStateValue,e)}else t={};return this.__cache.initialStateValue=t,this.__cache.initialStateValue},enumerable:!1,configurable:!0}),e.prototype.getInitialState=function(e,t){this._init();var n=this.getStateNodes(e);return this.resolveTransition({configuration:n,exitSet:[],transitions:[],source:void 0,actions:[]},void 0,null!=t?t:this.machine.context,void 0)},Object.defineProperty(e.prototype,"initialState",{get:function(){var e=this.initialStateValue;if(!e)throw new Error("Cannot retrieve initial state from simple state '".concat(this.id,"'."));return this.getInitialState(e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"target",{get:function(){var e;if("history"===this.type){var t=this.config;e=fl(t.target)&&ms(t.target)?Qa(this.machine.getStateNodeById(t.target).path.slice(this.path.length-1)):t.target}return e},enumerable:!1,configurable:!0}),e.prototype.getRelativeStateNodes=function(e,t,n){return void 0===n&&(n=!0),n?"history"===e.type?e.resolveHistory(t):e.initialStateNodes:[e]},Object.defineProperty(e.prototype,"initialStateNodes",{get:function(){var e=this;return Il(this)?[this]:"compound"!==this.type||this.initial?il(rl(this.initialStateValue).map((function(t){return e.getFromRelativePath(t)}))):(Ua||ul(!1,"Compound state node '".concat(this.id,"' has no initial state.")),[this])},enumerable:!1,configurable:!0}),e.prototype.getFromRelativePath=function(e){if(!e.length)return[this];var t=La(e),n=t[0],r=t.slice(1);if(!this.states)throw new Error("Cannot retrieve subPath '".concat(n,"' from node with no states"));var i=this.getStateNode(n);if("history"===i.type)return i.resolveHistory();if(!this.states[n])throw new Error("Child state '".concat(n,"' does not exist on '").concat(this.id,"'"));return this.states[n].getFromRelativePath(r)},e.prototype.historyValue=function(e){if(Object.keys(this.states).length)return{current:e||this.initialStateValue,states:tl(this.states,(function(t,n){if(!e)return t.historyValue();var r=fl(e)?void 0:e[n];return t.historyValue(r||t.initialStateValue)}),(function(e){return!e.history}))}},e.prototype.resolveHistory=function(e){var t=this;if("history"!==this.type)return[this];var n=this.parent;if(!e){var r=this.target;return r?il(rl(r).map((function(e){return n.getFromRelativePath(e)}))):n.initialStateNodes}var i,o,a=(i=n.path,o="states",function(e){var t,n,r=e;try{for(var a=Oa(i),l=a.next();!l.done;l=a.next()){var s=l.value;r=r[o][s]}}catch(e){t={error:e}}finally{try{l&&!l.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}return r})(e).current;return fl(a)?[n.getStateNode(a)]:il(rl(a).map((function(e){return"deep"===t.history?n.getFromRelativePath(e):[n.states[e[0]]]})))},Object.defineProperty(e.prototype,"stateIds",{get:function(){var e=this,t=il(Object.keys(this.states).map((function(t){return e.states[t].stateIds})));return[this.id].concat(t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"events",{get:function(){var e,t,n,r;if(this.__cache.events)return this.__cache.events;var i=this.states,o=new Set(this.ownEvents);if(i)try{for(var a=Oa(Object.keys(i)),l=a.next();!l.done;l=a.next()){var s=i[l.value];if(s.states)try{for(var c=(n=void 0,Oa(s.events)),d=c.next();!d.done;d=c.next()){var u=d.value;o.add("".concat(u))}}catch(e){n={error:e}}finally{try{d&&!d.done&&(r=c.return)&&r.call(c)}finally{if(n)throw n.error}}}}catch(t){e={error:t}}finally{try{l&&!l.done&&(t=a.return)&&t.call(a)}finally{if(e)throw e.error}}return this.__cache.events=Array.from(o)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ownEvents",{get:function(){var e=new Set(this.transitions.filter((function(e){return!(!e.target&&!e.actions.length&&e.internal)})).map((function(e){return e.eventType})));return Array.from(e)},enumerable:!1,configurable:!0}),e.prototype.resolveTarget=function(e){var t=this;if(void 0!==e)return e.map((function(e){if(!fl(e))return e;var n=e[0]===t.delimiter;if(n&&!t.parent)return t.getStateNodeByPath(e.slice(1));var r=n?t.key+e:e;if(!t.parent)return t.getStateNodeByPath(r);try{return t.parent.getStateNodeByPath(r)}catch(e){throw new Error("Invalid transition definition for state node '".concat(t.id,"':\n").concat(e.message))}}))},e.prototype.formatTransition=function(e){var t=this,n=function(e){if(void 0!==e&&""!==e)return al(e)}(e.target),r="internal"in e?e.internal:!n||n.some((function(e){return fl(e)&&e[0]===t.delimiter})),i=this.machine.options.guards,o=this.resolveTarget(n),a=Sa(Sa({},e),{actions:_l(al(e.actions)),cond:gl(e.cond,i),target:o,source:this,internal:r,eventType:e.event,toJSON:function(){return Sa(Sa({},a),{target:a.target?a.target.map((function(e){return"#".concat(e.id)})):void 0,source:"#".concat(t.id)})}});return a},e.prototype.formatTransitions=function(){var e,t,n,r=this;if(this.config.on)if(Array.isArray(this.config.on))n=this.config.on;else{var i=this.config.on,o=gs,a=i[o],l=void 0===a?[]:a,s=Ea(i,["*"]);n=il(Object.keys(s).map((function(e){Ua||e!==fs||ul(!1,"Empty string transition configs (e.g., `{ on: { '': ... }}`) for transient transitions are deprecated. Specify the transition in the `{ always: ... }` property instead. "+'Please check the `on` configuration for "#'.concat(r.id,'".'));var t=yl(e,s[e]);return Ua||function(e,t,n){var r=n.slice(0,-1).some((function(e){return!("cond"in e)&&!("in"in e)&&(fl(e.target)||ml(e.target))})),i=t===fs?"the transient event":"event '".concat(t,"'");ul(!r,"One or more transitions for ".concat(i," on state '").concat(e.id,"' are unreachable. ")+"Make sure that the default transition is the last one defined.")}(r,e,t),t})).concat(yl(gs,l)))}else n=[];var c=this.config.always?yl("",this.config.always):[],d=this.config.onDone?yl(String(Rl(this.id)),this.config.onDone):[];Ua||ul(!(this.config.onDone&&!this.parent),'Root nodes cannot have an ".onDone" transition. Please check the config of "'.concat(this.id,'".'));var u=il(this.invoke.map((function(e){var t=[];return e.onDone&&t.push.apply(t,_a([],La(yl(String(Pl(e.id)),e.onDone)),!1)),e.onError&&t.push.apply(t,_a([],La(yl(String(Ml(e.id)),e.onError)),!1)),t}))),p=this.after,h=il(_a(_a(_a(_a([],La(d),!1),La(u),!1),La(n),!1),La(c),!1).map((function(e){return al(e).map((function(e){return r.formatTransition(e)}))})));try{for(var f=Oa(p),g=f.next();!g.done;g=f.next()){var v=g.value;h.push(v)}}catch(t){e={error:t}}finally{try{g&&!g.done&&(t=f.return)&&t.call(f)}finally{if(e)throw e.error}}return h},e}();var bs,ys=function(e){return{type:ja,assignment:e}};!function(e){e[e.Effect=1]="Effect",e[e.LayoutEffect=2]="LayoutEffect"}(bs||(bs={}));var Cs="undefined"!=typeof document?Q:function(){};function ws(e){var t=Z.useRef();return t.current||(t.current={v:e()}),t.current.v}var $s=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},ks=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};var Ss=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a},Es=function(e,t,n){if(n||2===arguments.length)for(var r,i=0,o=t.length;i<o;i++)!r&&i in t||(r||(r=Array.prototype.slice.call(t,0,i)),r[i]=t[i]);return e.concat(r||Array.prototype.slice.call(t))};function Os(e,t){(0,e.exec)(t.context,t._event.data,{action:e,state:t,_event:t._event})()}function Ls(e){var t=J([]),n=J([]);Cs((function(){var r=e.subscribe((function(e){var r,i;if(e.actions.length){var o=e.actions.filter((function(e){return"function"==typeof e.exec&&"__effect"in e.exec})),a=Ss(function(e,t){var n,r,i=$s([[],[]],2),o=i[0],a=i[1];try{for(var l=ks(e),s=l.next();!s.done;s=l.next()){var c=s.value;t(c)?o.push(c):a.push(c)}}catch(e){n={error:e}}finally{try{s&&!s.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}return[o,a]}(o,(function(e){return e.exec.__effect===bs.Effect})),2),l=a[0],s=a[1];(r=t.current).push.apply(r,Es([],Ss(l.map((function(t){return[t,e]}))),!1)),(i=n.current).push.apply(i,Es([],Ss(s.map((function(t){return[t,e]}))),!1))}}));return function(){r.unsubscribe()}}),[]),Cs((function(){for(;n.current.length;){var e=Ss(n.current.shift(),2);Os(e[0],e[1])}})),U((function(){for(;t.current.length;){var e=Ss(t.current.shift(),2);Os(e[0],e[1])}}))}var _s=function(){return _s=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},_s.apply(this,arguments)},Ts=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n},Rs=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a};var Ps=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a};function Ms(e,t){void 0===t&&(t={});var n=ee((function(e){var t=void 0===e.changed&&Object.keys(e.children).length;(e.changed||t)&&a(e)}),[]),r=function(e,t,n){void 0===t&&(t={});var r=ws((function(){return"function"==typeof e?e():e}));if("production"!==process.env.NODE_ENV&&"function"!=typeof e){var i=Rs(W(r),1)[0];e!==i&&console.warn("Machine given to `useMachine` has changed between renders. This is not supported and might lead to unexpected results.\nPlease make sure that you pass the same Machine as argument each time.")}var o=t.context,a=t.guards,l=t.actions,s=t.activities,c=t.services,d=t.delays,u=t.state,p=Ts(t,["context","guards","actions","activities","services","delays","state"]),h=ws((function(){var e={context:o,guards:a,actions:l,activities:s,services:c,delays:d};return us(r.withConfig(e,(function(){return _s(_s({},r.context),o)})),_s({deferEvents:!0},p))}));return Cs((function(){var e;return n&&(e=h.subscribe(function(e){if("object"==typeof e)return e;var t=function(){};return{next:e,error:void 0||t,complete:void 0||t}}(n))),function(){null==e||e.unsubscribe()}}),[n]),Cs((function(){return h.start(u?Yl.create(u):void 0),function(){h.stop()}}),[]),Cs((function(){Object.assign(h.machine.options.actions,l),Object.assign(h.machine.options.guards,a),Object.assign(h.machine.options.activities,s),Object.assign(h.machine.options.services,c),Object.assign(h.machine.options.delays,d)}),[l,a,s,c,d]),Ls(h),h}(e,t,n),i=Ps(W((function(){var e=r.machine.initialState;return t.state?Yl.create(t.state):e})),2),o=i[0],a=i[1];return[o,r.send,r]}function Ds(){return Ds=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ds.apply(null,arguments)}function Ns(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}const js={arr:Array.isArray,obj:e=>"[object Object]"===Object.prototype.toString.call(e),fun:e=>"function"==typeof e,str:e=>"string"==typeof e,num:e=>"number"==typeof e,und:e=>void 0===e,nul:e=>null===e,set:e=>e instanceof Set,map:e=>e instanceof Map,equ(e,t){if(typeof e!=typeof t)return!1;if(js.str(e)||js.num(e))return e===t;if(js.obj(e)&&js.obj(t)&&Object.keys(e).length+Object.keys(t).length===0)return!0;let n;for(n in e)if(!(n in t))return!1;for(n in t)if(e[n]!==t[n])return!1;return!js.und(n)||e===t}};function Vs(e,t){return js.und(e)||js.nul(e)?t:e}function Is(e){return js.und(e)?[]:js.arr(e)?e:[e]}function zs(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return js.fun(e)?e(...n):e}function As(e){const t=function(e){return e.to,e.from,e.config,e.onStart,e.onRest,e.onFrame,e.children,e.reset,e.reverse,e.force,e.immediate,e.delay,e.attach,e.destroyed,e.interpolateTo,e.ref,e.lazy,Ns(e,["to","from","config","onStart","onRest","onFrame","children","reset","reverse","force","immediate","delay","attach","destroyed","interpolateTo","ref","lazy"])}(e);if(js.und(t))return Ds({to:t},e);const n=Object.keys(e).reduce(((n,r)=>js.und(t[r])?Ds({},n,{[r]:e[r]}):n),{});return Ds({to:t},n)}class Hs{constructor(){this.payload=void 0,this.children=[]}getAnimatedValue(){return this.getValue()}getPayload(){return this.payload||this}attach(){}detach(){}getChildren(){return this.children}addChild(e){0===this.children.length&&this.attach(),this.children.push(e)}removeChild(e){const t=this.children.indexOf(e);this.children.splice(t,1),0===this.children.length&&this.detach()}}class Bs extends Hs{constructor(){super(...arguments),this.payload=[],this.attach=()=>this.payload.forEach((e=>e instanceof Hs&&e.addChild(this))),this.detach=()=>this.payload.forEach((e=>e instanceof Hs&&e.removeChild(this)))}}class Fs extends Hs{constructor(){super(...arguments),this.payload={},this.attach=()=>Object.values(this.payload).forEach((e=>e instanceof Hs&&e.addChild(this))),this.detach=()=>Object.values(this.payload).forEach((e=>e instanceof Hs&&e.removeChild(this)))}getValue(e){void 0===e&&(e=!1);const t={};for(const n in this.payload){const r=this.payload[n];(!e||r instanceof Hs)&&(t[n]=r instanceof Hs?r[e?"getAnimatedValue":"getValue"]():r)}return t}getAnimatedValue(){return this.getValue(!0)}}let Zs,qs;let Gs,Ws=e=>"undefined"!=typeof window?window.requestAnimationFrame(e):-1;let Us,Xs=()=>Date.now();class Ys extends Fs{constructor(e,t){super(),this.update=void 0,this.payload=e.style?Ds({},e,{style:Us(e.style)}):e,this.update=t,this.attach()}}let Ks=!1;const Js=new Set,Qs=()=>{if(!Ks)return!1;let e=Xs();for(let t of Js){let n=!1;for(let r=0;r<t.configs.length;r++){let i,o,a=t.configs[r];for(let t=0;t<a.animatedValues.length;t++){let r=a.animatedValues[t];if(r.done)continue;let l=a.fromValues[t],s=a.toValues[t],c=r.lastPosition,d=s instanceof Hs,u=Array.isArray(a.initialVelocity)?a.initialVelocity[t]:a.initialVelocity;if(d&&(s=s.getValue()),a.immediate)r.setValue(s),r.done=!0;else if("string"!=typeof l&&"string"!=typeof s){if(void 0!==a.duration)c=l+a.easing((e-r.startTime)/a.duration)*(s-l),i=e>=r.startTime+a.duration;else if(a.decay)c=l+u/(1-.998)*(1-Math.exp(-.0020000000000000018*(e-r.startTime))),i=Math.abs(r.lastPosition-c)<.1,i&&(s=c);else{o=void 0!==r.lastTime?r.lastTime:e,u=void 0!==r.lastVelocity?r.lastVelocity:a.initialVelocity,e>o+64&&(o=e);let t=Math.floor(e-o);for(let e=0;e<t;++e){u+=1*((-a.tension*(c-s)+-a.friction*u)/a.mass)/1e3,c+=1*u/1e3}let n=!(!a.clamp||0===a.tension)&&(l<s?c>s:c<s),d=Math.abs(u)<=a.precision,p=0===a.tension||Math.abs(s-c)<=a.precision;i=n||d&&p,r.lastVelocity=u,r.lastTime=e}d&&!a.toValues[t].done&&(i=!1),i?(r.value!==s&&(c=s),r.done=!0):n=!0,r.setValue(c),r.lastPosition=c}else r.setValue(s),r.done=!0}t.props.onFrame&&(t.values[a.name]=a.interpolation.getValue())}t.props.onFrame&&t.props.onFrame(t.values),n||(Js.delete(t),t.stop(!0))}return Js.size?Ws(Qs):Ks=!1,Ks};function ec(e,t,n){if("function"==typeof e)return e;if(Array.isArray(e))return ec({range:e,output:t,extrapolate:n});if(Gs&&"string"==typeof e.output[0])return Gs(e);const r=e,i=r.output,o=r.range||[0,1],a=r.extrapolateLeft||r.extrapolate||"extend",l=r.extrapolateRight||r.extrapolate||"extend",s=r.easing||(e=>e);return e=>{const t=function(e,t){for(var n=1;n<t.length-1&&!(t[n]>=e);++n);return n-1}(e,o);return function(e,t,n,r,i,o,a,l,s){let c=s?s(e):e;if(c<t){if("identity"===a)return c;"clamp"===a&&(c=t)}if(c>n){if("identity"===l)return c;"clamp"===l&&(c=n)}if(r===i)return r;if(t===n)return e<=t?r:i;t===-1/0?c=-c:n===1/0?c-=t:c=(c-t)/(n-t);c=o(c),r===-1/0?c=-c:i===1/0?c+=r:c=c*(i-r)+r;return c}(e,o[t],o[t+1],i[t],i[t+1],s,a,l,r.map)}}class tc extends Bs{constructor(e,t,n,r){super(),this.calc=void 0,this.payload=e instanceof Bs&&!(e instanceof tc)?e.getPayload():Array.isArray(e)?e:[e],this.calc=ec(t,n,r)}getValue(){return this.calc(...this.payload.map((e=>e.getValue())))}updateConfig(e,t,n){this.calc=ec(e,t,n)}interpolate(e,t,n){return new tc(this,e,t,n)}}const nc=(e,t,n)=>e&&new tc(e,t,n);function rc(e,t){"update"in e?t.add(e):e.getChildren().forEach((e=>rc(e,t)))}class ic extends Hs{constructor(e){var t;super(),t=this,this.animatedStyles=new Set,this.value=void 0,this.startPosition=void 0,this.lastPosition=void 0,this.lastVelocity=void 0,this.startTime=void 0,this.lastTime=void 0,this.done=!1,this.setValue=function(e,n){void 0===n&&(n=!0),t.value=e,n&&t.flush()},this.value=e,this.startPosition=e,this.lastPosition=e}flush(){0===this.animatedStyles.size&&rc(this,this.animatedStyles),this.animatedStyles.forEach((e=>e.update()))}clearStyles(){this.animatedStyles.clear()}getValue(){return this.value}interpolate(e,t,n){return new tc(this,e,t,n)}}class oc extends Bs{constructor(e){super(),this.payload=e.map((e=>new ic(e)))}setValue(e,t){void 0===t&&(t=!0),Array.isArray(e)?e.length===this.payload.length&&e.forEach(((e,n)=>this.payload[n].setValue(e,t))):this.payload.forEach((n=>n.setValue(e,t)))}getValue(){return this.payload.map((e=>e.getValue()))}interpolate(e,t){return new tc(this,e,t)}}let ac=0,lc=class{constructor(){this.id=void 0,this.idle=!0,this.hasChanged=!1,this.guid=0,this.local=0,this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.listeners=[],this.queue=[],this.localQueue=void 0,this.getValues=()=>this.interpolations,this.id=ac++}update(e){if(!e)return this;const t=As(e),n=t.delay,r=void 0===n?0:n,i=t.to,o=Ns(t,["delay","to"]);if(js.arr(i)||js.fun(i))this.queue.push(Ds({},o,{delay:r,to:i}));else if(i){let e={};Object.entries(i).forEach((t=>{let n=t[0],i=t[1];const a=Ds({to:{[n]:i},delay:zs(r,n)},o),l=e[a.delay]&&e[a.delay].to;e[a.delay]=Ds({},e[a.delay],a,{to:Ds({},l,a.to)})})),this.queue=Object.values(e)}return this.queue=this.queue.sort(((e,t)=>e.delay-t.delay)),this.diff(o),this}start(e){if(this.queue.length){this.idle=!1,this.localQueue&&this.localQueue.forEach((e=>{let t=e.from,n=void 0===t?{}:t,r=e.to,i=void 0===r?{}:r;js.obj(n)&&(this.merged=Ds({},n,this.merged)),js.obj(i)&&(this.merged=Ds({},this.merged,i))}));const t=this.local=++this.guid,n=this.localQueue=this.queue;this.queue=[],n.forEach(((r,i)=>{let o=r.delay,a=Ns(r,["delay"]);const l=r=>{i===n.length-1&&t===this.guid&&r&&(this.idle=!0,this.props.onRest&&this.props.onRest(this.merged)),e&&e()};let s=js.arr(a.to)||js.fun(a.to);o?setTimeout((()=>{t===this.guid&&(s?this.runAsync(a,l):this.diff(a).start(l))}),o):s?this.runAsync(a,l):this.diff(a).start(l)}))}else js.fun(e)&&this.listeners.push(e),this.props.onStart&&this.props.onStart(),t=this,Js.has(t)||Js.add(t),Ks||(Ks=!0,Ws(Qs));var t;return this}stop(e){return this.listeners.forEach((t=>t(e))),this.listeners=[],this}pause(e){var t;return this.stop(!0),e&&(t=this,Js.has(t)&&Js.delete(t)),this}runAsync(e,t){var n=this;e.delay;let r=Ns(e,["delay"]);const i=this.local;let o=Promise.resolve(void 0);if(js.arr(r.to))for(let e=0;e<r.to.length;e++){const t=e,n=Ds({},r,As(r.to[t]));js.arr(n.config)&&(n.config=n.config[t]),o=o.then((()=>{if(i===this.guid)return new Promise((e=>this.diff(n).start(e)))}))}else if(js.fun(r.to)){let e,t=0;o=o.then((()=>r.to((n=>{const o=Ds({},r,As(n));if(js.arr(o.config)&&(o.config=o.config[t]),t++,i===this.guid)return e=new Promise((e=>this.diff(o).start(e)))}),(function(e){return void 0===e&&(e=!0),n.stop(e)})).then((()=>e))))}o.then(t)}diff(e){this.props=Ds({},this.props,e);let t=this.props,n=t.from,r=void 0===n?{}:n,i=t.to,o=void 0===i?{}:i,a=t.config,l=void 0===a?{}:a,s=t.reverse,c=t.attach,d=t.reset,u=t.immediate;if(s){var p=[o,r];r=p[0],o=p[1]}this.merged=Ds({},r,this.merged,o),this.hasChanged=!1;let h=c&&c(this);if(this.animations=Object.entries(this.merged).reduce(((e,t)=>{let n=t[0],i=t[1],o=e[n]||{};const a=js.num(i),s=js.str(i)&&!i.startsWith("#")&&!/\d/.test(i)&&!qs[i],c=js.arr(i),p=!a&&!c&&!s;let f=js.und(r[n])?i:r[n],g=a||c||s?i:1,v=zs(l,n);h&&(g=h.animations[n].parent);let m,x=o.parent,b=o.interpolation,y=Is(h?g.getPayload():g),C=i;p&&(C=Gs({range:[0,1],output:[i,i]})(1));let w=b&&b.getValue();const $=!js.und(x)&&o.animatedValues.some((e=>!e.done)),k=!js.equ(C,w),S=!js.equ(C,o.previous),E=!js.equ(v,o.config);if(d||S&&k||E){if(a||s)x=b=o.parent||new ic(f);else if(c)x=b=o.parent||new oc(f);else if(p){let e=o.interpolation&&o.interpolation.calc(o.parent.value);e=void 0===e||d?f:e,o.parent?(x=o.parent,x.setValue(0,!1)):x=new ic(0);const t={output:[e,i]};o.interpolation?(b=o.interpolation,o.interpolation.updateConfig(t)):b=x.interpolate(t)}return y=Is(h?g.getPayload():g),m=Is(x.getPayload()),d&&!p&&x.setValue(f,!1),this.hasChanged=!0,m.forEach((e=>{e.startPosition=e.value,e.lastPosition=e.value,e.lastVelocity=$?e.lastVelocity:void 0,e.lastTime=$?e.lastTime:void 0,e.startTime=Xs(),e.done=!1,e.animatedStyles.clear()})),zs(u,n)&&x.setValue(p?g:i,!1),Ds({},e,{[n]:Ds({},o,{name:n,parent:x,interpolation:b,animatedValues:m,toValues:y,previous:C,config:v,fromValues:Is(x.getValue()),immediate:zs(u,n),initialVelocity:Vs(v.velocity,0),clamp:Vs(v.clamp,!1),precision:Vs(v.precision,.01),tension:Vs(v.tension,170),friction:Vs(v.friction,26),mass:Vs(v.mass,1),duration:v.duration,easing:Vs(v.easing,(e=>e)),decay:v.decay})})}return k?e:(p&&(x.setValue(1,!1),b.updateConfig({output:[C,C]})),x.done=!0,this.hasChanged=!0,Ds({},e,{[n]:Ds({},e[n],{previous:C})}))}),this.animations),this.hasChanged){this.configs=Object.values(this.animations),this.values={},this.interpolations={};for(let e in this.animations)this.interpolations[e]=this.animations[e].interpolation,this.values[e]=this.animations[e].interpolation.getValue()}return this}destroy(){this.stop(),this.props={},this.merged={},this.animations={},this.interpolations={},this.values={},this.configs=[],this.local=0}};const sc=e=>{const t=js.fun(e),n=((e,t)=>{const n=J(!1),r=J(),i=js.fun(t),o=K((()=>{let n;return r.current&&(r.current.map((e=>e.destroy())),r.current=void 0),[new Array(e).fill().map(((e,r)=>{const o=new lc,a=i?zs(t,r,o):t[r];return 0===r&&(n=a.ref),o.update(a),n||o.start(),o})),n]}),[e]),a=o[0],l=o[1];r.current=a,ne(l,(()=>({start:()=>Promise.all(r.current.map((e=>new Promise((t=>e.start(t)))))),stop:e=>r.current.forEach((t=>t.stop(e))),get controllers(){return r.current}})));const s=K((()=>e=>r.current.map(((t,n)=>{t.update(i?zs(e,n,t):e[n]),l||t.start()}))),[e]);U((()=>{n.current?i||s(t):l||r.current.forEach((e=>e.start()))})),U((()=>(n.current=!0,()=>r.current.forEach((e=>e.destroy())))),[]);const c=r.current.map((e=>e.getValues()));return i?[c,s,e=>r.current.forEach((t=>t.pause(e)))]:c})(1,t?e:[e]),r=n[0],i=n[1],o=n[2];return t?[r[0],i,o]:r};class cc extends Fs{constructor(e){void 0===e&&(e={}),super(),!e.transform||e.transform instanceof Hs||(e=Zs.transform(e)),this.payload=e}}const dc={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},uc="[-+]?\\d*\\.?\\d+",pc=uc+"%";function hc(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return"\\(\\s*("+t.join(")\\s*,\\s*(")+")\\s*\\)"}const fc=new RegExp("rgb"+hc(uc,uc,uc)),gc=new RegExp("rgba"+hc(uc,uc,uc,uc)),vc=new RegExp("hsl"+hc(uc,pc,pc)),mc=new RegExp("hsla"+hc(uc,pc,pc,uc)),xc=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,bc=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,yc=/^#([0-9a-fA-F]{6})$/,Cc=/^#([0-9a-fA-F]{8})$/;function wc(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function $c(e,t,n){const r=n<.5?n*(1+t):n+t-n*t,i=2*n-r,o=wc(i,r,e+1/3),a=wc(i,r,e),l=wc(i,r,e-1/3);return Math.round(255*o)<<24|Math.round(255*a)<<16|Math.round(255*l)<<8}function kc(e){const t=parseInt(e,10);return t<0?0:t>255?255:t}function Sc(e){return(parseFloat(e)%360+360)%360/360}function Ec(e){const t=parseFloat(e);return t<0?0:t>1?255:Math.round(255*t)}function Oc(e){const t=parseFloat(e);return t<0?0:t>100?1:t/100}function Lc(e){let t=function(e){let t;return"number"==typeof e?e>>>0===e&&e>=0&&e<=4294967295?e:null:(t=yc.exec(e))?parseInt(t[1]+"ff",16)>>>0:dc.hasOwnProperty(e)?dc[e]:(t=fc.exec(e))?(kc(t[1])<<24|kc(t[2])<<16|kc(t[3])<<8|255)>>>0:(t=gc.exec(e))?(kc(t[1])<<24|kc(t[2])<<16|kc(t[3])<<8|Ec(t[4]))>>>0:(t=xc.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+"ff",16)>>>0:(t=Cc.exec(e))?parseInt(t[1],16)>>>0:(t=bc.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+t[4]+t[4],16)>>>0:(t=vc.exec(e))?(255|$c(Sc(t[1]),Oc(t[2]),Oc(t[3])))>>>0:(t=mc.exec(e))?($c(Sc(t[1]),Oc(t[2]),Oc(t[3]))|Ec(t[4]))>>>0:null}(e);return null===t?e:(t=t||0,`rgba(${(4278190080&t)>>>24}, ${(16711680&t)>>>16}, ${(65280&t)>>>8}, ${(255&t)/255})`)}const _c=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,Tc=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,Rc=new RegExp(`(${Object.keys(dc).join("|")})`,"g");let Pc={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0};const Mc=["Webkit","Ms","Moz","O"];function Dc(e,t,n){return null==t||"boolean"==typeof t||""===t?"":n||"number"!=typeof t||0===t||Pc.hasOwnProperty(e)&&Pc[e]?(""+t).trim():t+"px"}Pc=Object.keys(Pc).reduce(((e,t)=>(Mc.forEach((n=>e[((e,t)=>e+t.charAt(0).toUpperCase()+t.substring(1))(n,t)]=e[t])),e)),Pc);const Nc={};var jc;Us=e=>new cc(e),jc=e=>{const t=e.output.map((e=>e.replace(Tc,Lc))).map((e=>e.replace(Rc,Lc))),n=t[0].match(_c).map((()=>[]));t.forEach((e=>{e.match(_c).forEach(((e,t)=>n[t].push(+e)))}));const r=t[0].match(_c).map(((t,r)=>ec(Ds({},e,{output:n[r]}))));return e=>{let n=0;return t[0].replace(_c,(()=>r[n++](e))).replace(/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,((e,t,n,r,i)=>`rgba(${Math.round(t)}, ${Math.round(n)}, ${Math.round(r)}, ${i})`))}},Gs=jc,qs=dc,function(e,t){Zs={fn:e,transform:t}}(((e,t)=>{if(!e.nodeType||void 0===e.setAttribute)return!1;{const i=t.style,o=t.children,a=t.scrollTop,l=t.scrollLeft,s=Ns(t,["style","children","scrollTop","scrollLeft"]),c="filter"===e.nodeName||e.parentNode&&"filter"===e.parentNode.nodeName;void 0!==a&&(e.scrollTop=a),void 0!==l&&(e.scrollLeft=l),void 0!==o&&(e.textContent=o);for(let t in i)if(i.hasOwnProperty(t)){var n=0===t.indexOf("--"),r=Dc(t,i[t],n);"float"===t&&(t="cssFloat"),n?e.style.setProperty(t,r):e.style[t]=r}for(let t in s){const n=c?t:Nc[t]||(Nc[t]=t.replace(/([A-Z])/g,(e=>"-"+e.toLowerCase())));void 0!==e.getAttribute(n)&&e.setAttribute(n,s[t])}}}),(e=>e));var Vc;const Ic=(Vc=e=>G(((t,n)=>{const r=function(){const e=W(!1)[1];return ee((()=>e((e=>!e))),[])}(),i=J(!0),o=J(null),a=J(null),l=ee((e=>{const t=o.current;o.current=new Ys(e,(()=>{let e=!1;a.current&&(e=Zs.fn(a.current,o.current.getAnimatedValue())),a.current&&!1!==e||r()})),t&&t.detach()}),[]);U((()=>()=>{i.current=!1,o.current&&o.current.detach()}),[]),ne(n,(()=>(e=>e.current)(a))),l(t);const s=o.current.getValue();s.scrollTop,s.scrollLeft;const c=Ns(s,["scrollTop","scrollLeft"]),d=(u=e,!js.fun(u)||u.prototype instanceof q.Component?e=>a.current=function(e,t){return t&&(js.fun(t)?t(e):js.obj(t)&&(t.current=e)),e}(e,n):void 0);var u;return q.createElement(e,Ds({},c,{ref:d}))})),e=>(js.arr(e)?e:Object.keys(e)).reduce(((e,t)=>{const n=t;return e[n]=Vc(n),e}),Vc))(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"]);function zc(e,t){return e.map((function(e,n){return e+t[n]}))}function Ac(e,t){return e.map((function(e,n){return e-t[n]}))}function Hc(e){return Math.hypot.apply(Math,e)}function Bc(e){return Math.sign?Math.sign(e):Number(e>0)-Number(e<0)||+e}function Fc(e,t,n){return 0===t||Math.abs(t)===1/0?function(e,t){return Math.pow(e,5*t)}(e,n):e*t*n/(t+n*e)}function Zc(e,t,n,r){return void 0===r&&(r=.15),0===r?function(e,t,n){return Math.max(t,Math.min(e,n))}(e,t,n):e<t?-Fc(t-e,n-t,r)+t:e>n?+Fc(e-n,n-t,r)+n:e}function qc(e,t,n){return t&&function(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,r.key,r)}}(e.prototype,t),e}function Gc(){return Gc=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Gc.apply(this,arguments)}function Wc(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}function Uc(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Xc(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Yc(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return Xc(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Xc(e,t):void 0}}(e))||t){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}function Kc(){}function Jc(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return 0===t.length?Kc:1===t.length?t[0]:function(){for(var e,n,r=Yc(t);!(n=r()).done;){e=n.value.apply(this,arguments)||e}return e}}function Qc(e,t){if(void 0===e){if(void 0===t)throw new Error("Must define fallback value if undefined is expected");e=t}return Array.isArray(e)?e:[e,e]}function ed(e){if("function"==typeof e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return e.apply(void 0,n)}return e}function td(e,t){void 0===e&&(e={});for(var n={},r=0,i=Object.entries(t);r<i.length;r++){var o=i[r],a=o[0],l=o[1];switch(typeof l){case"function":n[a]=l.call(n,e[a],a,e);break;case"object":n[a]=td(e[a],l);break;case"boolean":l&&(n[a]=e[a])}}return n}var nd=Gc({},{threshold:function(e){return void 0===e&&(e=0),Qc(e)},rubberband:function(e){switch(void 0===e&&(e=0),e){case!0:return Qc(.15);case!1:return Qc(0);default:return Qc(e)}},enabled:function(e){return void 0===e&&(e=!0),e},triggerAllEvents:function(e){return void 0===e&&(e=!1),e},initial:function(e){return void 0===e&&(e=0),"function"==typeof e?e:Qc(e)}},{axis:!0,lockDirection:function(e){return void 0===e&&(e=!1),e},bounds:function(e){if(void 0===e&&(e={}),"function"==typeof e)return function(t){return nd.bounds(e(t))};var t=e,n=t.left,r=void 0===n?-1/0:n,i=t.right,o=void 0===i?1/0:i,a=t.top,l=void 0===a?-1/0:a,s=t.bottom;return[[r,o],[l,void 0===s?1/0:s]]}}),rd="undefined"!=typeof window&&window.document&&window.document.createElement,id={enabled:function(e){return void 0===e&&(e=!0),e},domTarget:!0,window:function(e){function t(t){return e.apply(this,arguments)}return t.toString=function(){return e.toString()},t}((function(e){return void 0===e&&(e=rd?window:void 0),e})),eventOptions:function(e){var t=void 0===e?{}:e,n=t.passive,r=void 0===n||n,i=t.capture;return{passive:r,capture:void 0!==i&&i}}},od=Gc({},nd,{threshold:function(e,t,n){var r=n.filterTaps,i=void 0!==r&&r,o=n.lockDirection,a=void 0!==o&&o,l=n.axis,s=Qc(e,i?3:a||(void 0===l?void 0:l)?1:0);return this.filterTaps=i||s[0]+s[1]>0,s},swipeVelocity:function(e){return void 0===e&&(e=.5),Qc(e)},swipeDistance:function(e){return void 0===e&&(e=60),Qc(e)},delay:function(e){switch(void 0===e&&(e=0),e){case!0:return 180;case!1:return 0;default:return e}}});function ad(e){var t=e.domTarget,n=e.eventOptions,r=e.window,i=e.enabled,o=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}(e,["domTarget","eventOptions","window","enabled"]),a=function(e){return void 0===e&&(e={}),td(e,id)}({domTarget:t,eventOptions:n,window:r,enabled:i});return a.drag=function(e){return void 0===e&&(e={}),td(e,od)}(o),a}function ld(e){return Gc({_active:!1,_blocked:!1,_intentional:[!1,!1],_movement:[0,0],_initial:[0,0],_bounds:[[-1/0,1/0],[-1/0,1/0]],_lastEventType:void 0,event:void 0,intentional:!1,values:[0,0],velocities:[0,0],delta:[0,0],movement:[0,0],offset:[0,0],lastOffset:[0,0],direction:[0,0],initial:[0,0],previous:[0,0],first:!1,last:!1,active:!1,timeStamp:0,startTime:0,elapsedTime:0,cancel:Kc,canceled:!1,memo:void 0,args:void 0},e)}function sd(){return{shared:{hovering:!1,scrolling:!1,wheeling:!1,dragging:!1,moving:!1,pinching:!1,touches:0,buttons:0,down:!1,shiftKey:!1,altKey:!1,metaKey:!1,ctrlKey:!1},drag:ld({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0,_isTap:!0,_delayedEvent:!1,_pointerId:void 0,tap:!1,swipe:[0,0]}),pinch:ld({da:[0,0],vdva:[0,0],origin:void 0,turns:0}),wheel:ld({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0}),move:ld({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0}),scroll:ld({axis:void 0,xy:[0,0],vxvy:[0,0],velocity:0,distance:0})}}var cd=new Map,dd=function(){function e(e,t){var n=this;void 0===t&&(t=[]),this.controller=e,this.args=t,this.debounced=!0,this.setTimeout=function(e,t){var r;void 0===t&&(t=140),clearTimeout(n.controller.timeouts[n.stateKey]);for(var i=arguments.length,o=new Array(i>2?i-2:0),a=2;a<i;a++)o[a-2]=arguments[a];n.controller.timeouts[n.stateKey]=(r=window).setTimeout.apply(r,[e,t].concat(o))},this.clearTimeout=function(){clearTimeout(n.controller.timeouts[n.stateKey])},this.fireGestureHandler=function(e){if(void 0===e&&(e=!1),n.state._blocked)return n.debounced||(n.state._active=!1,n.clean()),null;if(!e&&!n.state.intentional&&!n.config.triggerAllEvents)return null;if(n.state.intentional){var t=n.state.active,r=n.state._active;n.state.active=r,n.state.first=r&&!t,n.state.last=t&&!r,n.controller.state.shared[n.ingKey]=r}var i=Gc({},n.controller.state.shared,n.state,n.mapStateValues(n.state)),o=n.handler(i);return n.state.memo=void 0!==o?o:n.state.memo,n.state._active||n.clean(),i}}var t=e.prototype;return t.updateSharedState=function(e){Object.assign(this.controller.state.shared,e)},t.updateGestureState=function(e){Object.assign(this.state,e)},t.checkIntentionality=function(e,t){return{_intentional:e,_blocked:!1}},t.getMovement=function(e){var t=this.config,n=t.initial,r=t.bounds,i=t.rubberband,o=t.threshold,a=this.state,l=a._bounds,s=a._initial,c=a._active,d=a._intentional,u=a.lastOffset,p=a.movement,h=this.getInternalMovement(e,this.state),f=!1===d[0]?ud(h[0],o[0]):d[0],g=!1===d[1]?ud(h[1],o[1]):d[1],v=this.checkIntentionality([f,g],h);if(v._blocked)return Gc({},v,{_movement:h,delta:[0,0]});var m,x,b,y,C=v._intentional,w=h;(!1!==C[0]&&!1===d[0]&&(x=ed(n,this.state),m=ed(r,this.state),s[0]=x[0],l[0]=m[0]),!1!==C[1]&&!1===d[1])&&(x=null!=(b=x)?b:ed(n,this.state),m=null!=(y=m)?y:ed(r,this.state),s[1]=x[1],l[1]=m[1]);var $=[!1!==C[0]?h[0]-C[0]:s[0],!1!==C[1]?h[1]-C[1]:s[1]],k=zc($,u),S=c?i:[0,0];return $=pd(l,zc($,s),S),Gc({},v,{intentional:!1!==C[0]||!1!==C[1],_initial:s,_movement:w,movement:$,values:e,offset:pd(l,k,S),delta:Ac($,p)})},t.clean=function(){this.clearTimeout()},qc(e,[{key:"config",get:function(){return this.controller.config[this.stateKey]}},{key:"enabled",get:function(){return this.controller.config.enabled&&this.config.enabled}},{key:"state",get:function(){return this.controller.state[this.stateKey]}},{key:"handler",get:function(){return this.controller.handlers[this.stateKey]}}]),e}();function ud(e,t){return Math.abs(e)>=t&&Bc(e)*t}function pd(e,t,n){var r=t[0],i=t[1],o=n[0],a=n[1],l=e[0],s=l[0],c=l[1],d=e[1],u=d[0],p=d[1];return[Zc(r,s,c,o),Zc(i,u,p,a)]}function hd(e,t,n){var r=e.state,i=e.args,o=t.timeStamp,a=t.type,l=r.values;return{_lastEventType:a,event:t,timeStamp:o,elapsedTime:n?0:o-r.startTime,args:i,previous:l}}function fd(e,t){return function(n){for(var r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];return e.call.apply(e,[this,Gc({},t,{event:n})].concat(i))}}var gd=function(e){var t=this;this.classes=e,this.bind=function(){for(var e={},n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];for(var o,a=Yc(t.classes);!(o=a()).done;){new(0,o.value)(t,r).addBindings(e)}for(var l=0,s=Object.entries(t.nativeRefs);l<s.length;l++){var c=s[l];xd(e,c[0],fd(c[1],Gc({},t.state.shared,{args:r})))}return t.config.domTarget?function(e,t){var n=e.config,r=e.domListeners,i=md(n);if(!i)throw new Error("domTarget must be defined");var o=n.eventOptions;yd(i,vd(r),o);for(var a=0,l=Object.entries(t);a<l.length;a++){var s=l[a],c=s[0],d=s[1],u=c.slice(2).toLowerCase();r.push([u,Jc.apply(void 0,d)])}bd(i,r,o)}(t,e):function(e,t){for(var n=e.config,r={},i=n.eventOptions.capture?"Capture":"",o=0,a=Object.entries(t);o<a.length;o++){var l=a[o],s=l[0],c=l[1],d=Array.isArray(c)?c:[c];r[s+i]=Jc.apply(void 0,d)}return r}(t,e)},this.effect=function(){return t.config.domTarget&&t.bind(),t.clean},this.clean=function(){var e=md(t.config),n=t.config.eventOptions;e&&yd(e,vd(t.domListeners),n),Object.values(t.timeouts).forEach(clearTimeout),function(e){var t=e.config,n=t.window,r=t.eventOptions,i=e.windowListeners;if(!n)return;for(var o in i){yd(n,i[o],r)}e.windowListeners={}}(t)},this.state=sd(),this.timeouts={},this.domListeners=[],this.windowListeners={}};function vd(e){return void 0===e&&(e=[]),e.splice(0,e.length)}function md(e){var t=e.domTarget;return t&&"current"in t?t.current:t}function xd(e,t,n){e[t]||(e[t]=[]),e[t].push(n)}function bd(e,t,n){void 0===t&&(t=[]),void 0===n&&(n={});for(var r,i=Yc(t);!(r=i()).done;){var o=r.value,a=o[0],l=o[1];e.addEventListener(a,l,n)}}function yd(e,t,n){void 0===t&&(t=[]),void 0===n&&(n={});for(var r,i=Yc(t);!(r=i()).done;){var o=r.value,a=o[0],l=o[1];e.removeEventListener(a,l,n)}}function Cd(e,t,n){void 0===n&&(n={});var r=function(e){var t=new Set;e.drag&&t.add(cd.get("drag"));e.wheel&&t.add(cd.get("wheel"));e.scroll&&t.add(cd.get("scroll"));e.move&&t.add(cd.get("move"));e.pinch&&t.add(cd.get("pinch"));e.hover&&t.add(cd.get("hover"));return t}(e),i=q.useMemo((function(){return new gd(r)}),[]);return i.config=t,i.handlers=e,i.nativeRefs=n,q.useEffect(i.effect,[]),i.config.domTarget?wd:i.bind}function wd(){"development"===process.env.NODE_ENV&&console.warn("Deprecation notice: When the `domTarget` option is specified, you don't need to write `useEffect(bind, [bind])` anymore: event binding is now made handled internally to this lib.\n\nNext version won't return anything when `domTarget` is provided, therefore your code will break if you try to call `useEffect`.")}function $d(e){if("touches"in e){var t=e.targetTouches,n=e.changedTouches;return t.length>0?t:n}return null}function kd(e){var t="buttons"in e?e.buttons:0,n=$d(e),r=n&&n.length||0;return{touches:r,down:r>0||t>0,buttons:t,shiftKey:e.shiftKey,altKey:e.altKey,metaKey:e.metaKey,ctrlKey:e.ctrlKey}}function Sd(e){var t=$d(e),n=t?t[0]:e;return[n.clientX,n.clientY]}var Ed=function(e){function t(){var t;return(t=e.apply(this,arguments)||this).ingKey="dragging",t.stateKey="drag",t.onDragStart=function(e){t.enabled&&!t.state._active&&(!function(e,t,n){var r=e.config,i=e.windowListeners;void 0===n&&(n=[]),r.window&&(yd(r.window,i[t],r.eventOptions),bd(r.window,i[t]=n,r.eventOptions))}(t.controller,t.stateKey,[["pointermove",t.onDragChange],["pointerup",t.onDragEnd],["pointercancel",t.onDragEnd]]),t.updateGestureState({_pointerId:e.pointerId}),t.config.delay>0?(t.state._delayedEvent=!0,"persist"in e&&"function"==typeof e.persist&&e.persist(),t.setTimeout(t.startDrag.bind(Uc(t)),t.config.delay,e)):t.startDrag(e))},t.onDragChange=function(e){if(!t.state.canceled&&e.pointerId===t.state._pointerId)if(t.state._active){var n=kd(e);if(n.down){t.updateSharedState(n);var r=Sd(e),i=t.getKinematics(r,e),o=hd(Uc(t),e),a=t.state._isTap,l=Hc(i._movement);a&&l>=3&&(a=!1),t.updateGestureState(Gc({},o,i,{_isTap:a})),t.fireGestureHandler()}else t.onDragEnd(e)}else t.state._delayedEvent&&(t.clearTimeout(),t.startDrag(e))},t.onDragEnd=function(e){if(e.pointerId===t.state._pointerId){t.state._active=!1,t.updateSharedState({down:!1,buttons:0,touches:0});var n=t.state._isTap,r=t.state.velocities,i=r[0],o=r[1],a=t.state.movement,l=a[0],s=a[1],c=t.state._intentional,d=c[0],u=c[1],p=t.config.swipeVelocity,h=p[0],f=p[1],g=t.config.swipeDistance,v=g[0],m=g[1],x=Gc({},hd(Uc(t),e),t.getMovement(t.state.values)),b=[0,0];x.elapsedTime<220&&(!1!==d&&Math.abs(i)>h&&Math.abs(l)>v&&(b[0]=Bc(i)),!1!==u&&Math.abs(o)>f&&Math.abs(s)>m&&(b[1]=Bc(o))),t.updateGestureState(Gc({},x,{tap:n,swipe:b})),t.fireGestureHandler(!0===n)}},t.clean=function(){e.prototype.clean.call(Uc(t)),t.state._delayedEvent=!1,function(e,t){var n=e.config,r=e.windowListeners;n.window&&(yd(n.window,r[t],n.eventOptions),delete r[t])}(t.controller,t.stateKey)},t.onCancel=function(){t.state.canceled||(t.updateGestureState({canceled:!0}),t.state._active=!1,t.updateSharedState({down:!1,buttons:0,touches:0}),requestAnimationFrame((function(){return t.fireGestureHandler()})))},t.onClick=function(e){t.state._isTap||e.stopPropagation()},t}Wc(t,e);var n=t.prototype;return n.startDrag=function(e){var t=Sd(e);this.updateSharedState(kd(e)),this.updateGestureState(Gc({},function(e,t,n){var r=e.state.offset,i=n.timeStamp;return Gc({},sd()[e.stateKey],{_active:!0,values:t,initial:t,offset:r,lastOffset:r,startTime:i})}(this,t,e),hd(this,e,!0),{_pointerId:e.pointerId,cancel:this.onCancel})),this.updateGestureState(this.getMovement(t)),this.fireGestureHandler()},n.addBindings=function(e){(xd(e,"onPointerDown",this.onDragStart),this.config.filterTaps)&&xd(e,this.controller.config.eventOptions.capture?"onClick":"onClickCapture",this.onClick)},t}(function(e){function t(){return e.apply(this,arguments)||this}Wc(t,e);var n=t.prototype;return n.getInternalMovement=function(e,t){return Ac(e,t.initial)},n.checkIntentionality=function(e,t){if(!1===e[0]&&!1===e[1])return{_intentional:e,axis:this.state.axis};var n=t.map(Math.abs),r=n[0],i=n[1],o=this.state.axis||(r>i?"x":r<i?"y":void 0);return this.config.axis||this.config.lockDirection?o?this.config.axis&&o!==this.config.axis?{_intentional:e,_blocked:!0,axis:o}:(e["x"===o?1:0]=!1,{_intentional:e,_blocked:!1,axis:o}):{_intentional:[!1,!1],_blocked:!1,axis:o}:{_intentional:e,_blocked:!1,axis:o}},n.getKinematics=function(e,t){var n=this.getMovement(e);if(!n._blocked){var r=t.timeStamp-this.state.timeStamp;Object.assign(n,function(e,t,n){var r=Hc(t),i=0===r?0:1/r,o=0===n?0:1/n,a=o*r,l=t.map((function(e){return o*e})),s=t.map((function(e){return i*e}));return{velocities:l,velocity:a,distance:Hc(e),direction:s}}(n.movement,n.delta,r))}return n},n.mapStateValues=function(e){return{xy:e.values,vxvy:e.velocities}},t}(dd));function Od(e,t){if(e===t)return!0;if(e&&t&&"object"==typeof e&&"object"==typeof t){if(e.constructor!==t.constructor)return!1;var n,r,i,o;if(Array.isArray(e)){if((n=e.length)!==t.length)return!1;for(r=n;0!=r--;)if(!Od(e[r],t[r]))return!1;return!0}if("function"==typeof Map&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(o=e.entries();!(r=o.next()).done;)if(!t.has(r.value[0]))return!1;for(o=e.entries();!(r=o.next()).done;)if(!Od(r.value[1],t.get(r.value[0])))return!1;return!0}if("function"==typeof Set&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(o=e.entries();!(r=o.next()).done;)if(!t.has(r.value[0]))return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();if((n=(i=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!Object.prototype.hasOwnProperty.call(t,i[r]))return!1;if("undefined"!=typeof Element&&e instanceof Element)return!1;for(r=n;0!=r--;)if(!("_owner"===i[r]&&e.$$typeof||Od(e[i[r]],t[i[r]])))return!1;return!0}return e!=e&&t!=t}function Ld(e,t){try{return Od(e,t)}catch(e){if((e.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw e}}function _d(e,t){void 0===t&&(t={}),cd.set("drag",Ed);var n=J();return n.current||(n.current=function(e,t){var n,r,i=[],o=!1;return function(){for(var a=arguments.length,l=new Array(a),s=0;s<a;s++)l[s]=arguments[s];return o&&n===this&&t(l,i)||(r=e.apply(this,l),o=!0,n=this,i=l),r}}(ad,Ld)),Cd({drag:e},n.current(t))}
2338
2338
  /*!
2339
2339
  * tabbable 5.3.3
2340
2340
  * @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
@@ -2343,7 +2343,7 @@ PERFORMANCE OF THIS SOFTWARE.
2343
2343
  * focus-trap 6.9.4
2344
2344
  * @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
2345
2345
  */
2346
- function Yd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Kd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yd(Object(n),!0).forEach((function(t){Jd(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Jd(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Qd,eu=(Qd=[],{activateTrap:function(e){if(Qd.length>0){var t=Qd[Qd.length-1];t!==e&&t.pause()}var n=Qd.indexOf(e);-1===n||Qd.splice(n,1),Qd.push(e)},deactivateTrap:function(e){var t=Qd.indexOf(e);-1!==t&&Qd.splice(t,1),Qd.length>0&&Qd[Qd.length-1].unpause()}}),tu=function(e){return setTimeout(e,0)},nu=function(e,t){var n=-1;return e.every((function(e,r){return!t(e)||(n=r,!1)})),n},ru=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return"function"==typeof e?e.apply(void 0,n):e},iu=function(e){return e.target.shadowRoot&&"function"==typeof e.composedPath?e.composedPath()[0]:e.target},ou=function(e,t){var n,r=(null==t?void 0:t.document)||document,i=Kd({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0},t),o={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0},a=function(e,t,n){return e&&void 0!==e[t]?e[t]:i[n||t]},l=function(e){return o.containerGroups.findIndex((function(t){var n=t.container,r=t.tabbableNodes;return n.contains(e)||r.find((function(t){return t===e}))}))},s=function(e){var t=i[e];if("function"==typeof t){for(var n=arguments.length,o=new Array(n>1?n-1:0),a=1;a<n;a++)o[a-1]=arguments[a];t=t.apply(void 0,o)}if(!0===t&&(t=void 0),!t){if(void 0===t||!1===t)return t;throw new Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var l=t;if("string"==typeof t&&!(l=r.querySelector(t)))throw new Error("`".concat(e,"` as selector refers to no known node"));return l},c=function(){var e=s("initialFocus");if(!1===e)return!1;if(void 0===e)if(l(r.activeElement)>=0)e=r.activeElement;else{var t=o.tabbableGroups[0];e=t&&t.firstTabbableNode||s("fallbackFocus")}if(!e)throw new Error("Your focus-trap needs to have at least one focusable element");return e},d=function(){if(o.containerGroups=o.containers.map((function(e){var t,n,r=Gd(e,i.tabbableOptions),o=(t=e,(n=(n=i.tabbableOptions)||{}).getShadowRoot?jd([t],n.includeContainer,{filter:Bd.bind(null,n),flatten:!0,getShadowRoot:n.getShadowRoot}):Nd(t,n.includeContainer,Bd.bind(null,n)));return{container:e,tabbableNodes:r,focusableNodes:o,firstTabbableNode:r.length>0?r[0]:null,lastTabbableNode:r.length>0?r[r.length-1]:null,nextTabbableNode:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=o.findIndex((function(t){return t===e}));if(!(n<0))return t?o.slice(n+1).find((function(e){return Wd(e,i.tabbableOptions)})):o.slice(0,n).reverse().find((function(e){return Wd(e,i.tabbableOptions)}))}}})),o.tabbableGroups=o.containerGroups.filter((function(e){return e.tabbableNodes.length>0})),o.tabbableGroups.length<=0&&!s("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times")},u=function e(t){!1!==t&&t!==r.activeElement&&(t&&t.focus?(t.focus({preventScroll:!!i.preventScroll}),o.mostRecentlyFocusedNode=t,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(t)&&t.select()):e(c()))},p=function(e){var t=s("setReturnFocus",e);return t||!1!==t&&e},h=function(e){var t=iu(e);l(t)>=0||(ru(i.clickOutsideDeactivates,e)?n.deactivate({returnFocus:i.returnFocusOnDeactivate&&!Xd(t,i.tabbableOptions)}):ru(i.allowOutsideClick,e)||e.preventDefault())},f=function(e){var t=iu(e),n=l(t)>=0;n||t instanceof Document?n&&(o.mostRecentlyFocusedNode=t):(e.stopImmediatePropagation(),u(o.mostRecentlyFocusedNode||c()))},g=function(e){if(function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e)&&!1!==ru(i.escapeDeactivates,e))return e.preventDefault(),void n.deactivate();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){var t=iu(e);d();var n=null;if(o.tabbableGroups.length>0){var r=l(t),a=r>=0?o.containerGroups[r]:void 0;if(r<0)n=e.shiftKey?o.tabbableGroups[o.tabbableGroups.length-1].lastTabbableNode:o.tabbableGroups[0].firstTabbableNode;else if(e.shiftKey){var c=nu(o.tabbableGroups,(function(e){var n=e.firstTabbableNode;return t===n}));if(c<0&&(a.container===t||Xd(t,i.tabbableOptions)&&!Wd(t,i.tabbableOptions)&&!a.nextTabbableNode(t,!1))&&(c=r),c>=0){var p=0===c?o.tabbableGroups.length-1:c-1;n=o.tabbableGroups[p].lastTabbableNode}}else{var h=nu(o.tabbableGroups,(function(e){var n=e.lastTabbableNode;return t===n}));if(h<0&&(a.container===t||Xd(t,i.tabbableOptions)&&!Wd(t,i.tabbableOptions)&&!a.nextTabbableNode(t))&&(h=r),h>=0){var f=h===o.tabbableGroups.length-1?0:h+1;n=o.tabbableGroups[f].firstTabbableNode}}}else n=s("fallbackFocus");n&&(e.preventDefault(),u(n))}(e)},v=function(e){var t=iu(e);l(t)>=0||ru(i.clickOutsideDeactivates,e)||ru(i.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())},m=function(){if(o.active)return eu.activateTrap(n),o.delayInitialFocusTimer=i.delayInitialFocus?tu((function(){u(c())})):u(c()),r.addEventListener("focusin",f,!0),r.addEventListener("mousedown",h,{capture:!0,passive:!1}),r.addEventListener("touchstart",h,{capture:!0,passive:!1}),r.addEventListener("click",v,{capture:!0,passive:!1}),r.addEventListener("keydown",g,{capture:!0,passive:!1}),n},x=function(){if(o.active)return r.removeEventListener("focusin",f,!0),r.removeEventListener("mousedown",h,!0),r.removeEventListener("touchstart",h,!0),r.removeEventListener("click",v,!0),r.removeEventListener("keydown",g,!0),n};return(n={get active(){return o.active},get paused(){return o.paused},activate:function(e){if(o.active)return this;var t=a(e,"onActivate"),n=a(e,"onPostActivate"),i=a(e,"checkCanFocusTrap");i||d(),o.active=!0,o.paused=!1,o.nodeFocusedBeforeActivation=r.activeElement,t&&t();var l=function(){i&&d(),m(),n&&n()};return i?(i(o.containers.concat()).then(l,l),this):(l(),this)},deactivate:function(e){if(!o.active)return this;var t=Kd({onDeactivate:i.onDeactivate,onPostDeactivate:i.onPostDeactivate,checkCanReturnFocus:i.checkCanReturnFocus},e);clearTimeout(o.delayInitialFocusTimer),o.delayInitialFocusTimer=void 0,x(),o.active=!1,o.paused=!1,eu.deactivateTrap(n);var r=a(t,"onDeactivate"),l=a(t,"onPostDeactivate"),s=a(t,"checkCanReturnFocus"),c=a(t,"returnFocus","returnFocusOnDeactivate");r&&r();var d=function(){tu((function(){c&&u(p(o.nodeFocusedBeforeActivation)),l&&l()}))};return c&&s?(s(p(o.nodeFocusedBeforeActivation)).then(d,d),this):(d(),this)},pause:function(){return o.paused||!o.active||(o.paused=!0,x()),this},unpause:function(){return o.paused&&o.active?(o.paused=!1,d(),m(),this):this},updateContainerElements:function(e){var t=[].concat(e).filter(Boolean);return o.containers=t.map((function(e){return"string"==typeof e?r.querySelector(e):e})),o.active&&d(),this}}).updateContainerElements(e),n};var au=!1;if("undefined"!=typeof window){var lu={get passive(){au=!0}};window.addEventListener("testPassive",null,lu),window.removeEventListener("testPassive",null,lu)}var su,cu="undefined"!=typeof window&&window.navigator&&window.navigator.platform&&(/iP(ad|hone|od)/.test(window.navigator.platform)||"MacIntel"===window.navigator.platform&&window.navigator.maxTouchPoints>1),du=[],uu=!1,pu=-1,hu=void 0,fu=void 0,gu=function(e){return du.some((function(t){return!(!t.options.allowTouchMove||!t.options.allowTouchMove(e))}))},vu=function(e){var t=e||window.event;return!!gu(t.target)||(t.touches.length>1||(t.preventDefault&&t.preventDefault(),!1))},mu=function(e,t){if(e){if(!du.some((function(t){return t.targetElement===e}))){var n={targetElement:e,options:t||{}};du=[].concat(function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(du),[n]),cu?(e.ontouchstart=function(e){1===e.targetTouches.length&&(pu=e.targetTouches[0].clientY)},e.ontouchmove=function(t){1===t.targetTouches.length&&function(e,t){var n=e.targetTouches[0].clientY-pu;!gu(e.target)&&(t&&0===t.scrollTop&&n>0||function(e){return!!e&&e.scrollHeight-e.scrollTop<=e.clientHeight}(t)&&n<0?vu(e):e.stopPropagation())}(t,e)},uu||(document.addEventListener("touchmove",vu,au?{passive:!1}:void 0),uu=!0)):function(e){if(void 0===fu){var t=!!e&&!0===e.reserveScrollBarGap,n=window.innerWidth-document.documentElement.clientWidth;t&&n>0&&(fu=document.body.style.paddingRight,document.body.style.paddingRight=n+"px")}void 0===hu&&(hu=document.body.style.overflow,document.body.style.overflow="hidden")}(t)}}else console.error("disableBodyScroll unsuccessful - targetElement must be provided when calling disableBodyScroll on IOS devices.")},xu=function(e){e?(du=du.filter((function(t){return t.targetElement!==e})),cu?(e.ontouchstart=null,e.ontouchmove=null,uu&&0===du.length&&(document.removeEventListener("touchmove",vu,au?{passive:!1}:void 0),uu=!1)):du.length||(void 0!==fu&&(document.body.style.paddingRight=fu,fu=void 0),void 0!==hu&&(document.body.style.overflow=hu,hu=void 0))):console.error("enableBodyScroll unsuccessful - targetElement must be provided when calling enableBodyScroll on IOS devices.")},bu=[],yu="ResizeObserver loop completed with undelivered notifications.";!function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"}(su||(su={}));var Cu,wu=function(e){return Object.freeze(e)},$u=function(e,t){this.inlineSize=e,this.blockSize=t,wu(this)},ku=function(){function e(e,t,n,r){return this.x=e,this.y=t,this.width=n,this.height=r,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,wu(this)}return e.prototype.toJSON=function(){var e=this;return{x:e.x,y:e.y,top:e.top,right:e.right,bottom:e.bottom,left:e.left,width:e.width,height:e.height}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e}(),Su=function(e){return e instanceof SVGElement&&"getBBox"in e},Eu=function(e){if(Su(e)){var t=e.getBBox(),n=t.width,r=t.height;return!n&&!r}var i=e,o=i.offsetWidth,a=i.offsetHeight;return!(o||a||e.getClientRects().length)},Ou=function(e){var t;if(e instanceof Element)return!0;var n=null===(t=null==e?void 0:e.ownerDocument)||void 0===t?void 0:t.defaultView;return!!(n&&e instanceof n.Element)},Lu="undefined"!=typeof window?window:{},_u=new WeakMap,Tu=/auto|scroll/,Ru=/^tb|vertical/,Pu=/msie|trident/i.test(Lu.navigator&&Lu.navigator.userAgent),Mu=function(e){return parseFloat(e||"0")},Du=function(e,t,n){return void 0===e&&(e=0),void 0===t&&(t=0),void 0===n&&(n=!1),new $u((n?t:e)||0,(n?e:t)||0)},Nu=wu({devicePixelContentBoxSize:Du(),borderBoxSize:Du(),contentBoxSize:Du(),contentRect:new ku(0,0,0,0)}),ju=function(e,t){if(void 0===t&&(t=!1),_u.has(e)&&!t)return _u.get(e);if(Eu(e))return _u.set(e,Nu),Nu;var n=getComputedStyle(e),r=Su(e)&&e.ownerSVGElement&&e.getBBox(),i=!Pu&&"border-box"===n.boxSizing,o=Ru.test(n.writingMode||""),a=!r&&Tu.test(n.overflowY||""),l=!r&&Tu.test(n.overflowX||""),s=r?0:Mu(n.paddingTop),c=r?0:Mu(n.paddingRight),d=r?0:Mu(n.paddingBottom),u=r?0:Mu(n.paddingLeft),p=r?0:Mu(n.borderTopWidth),h=r?0:Mu(n.borderRightWidth),f=r?0:Mu(n.borderBottomWidth),g=u+c,v=s+d,m=(r?0:Mu(n.borderLeftWidth))+h,x=p+f,b=l?e.offsetHeight-x-e.clientHeight:0,y=a?e.offsetWidth-m-e.clientWidth:0,C=i?g+m:0,w=i?v+x:0,$=r?r.width:Mu(n.width)-C-y,k=r?r.height:Mu(n.height)-w-b,S=$+g+y+m,E=k+v+b+x,O=wu({devicePixelContentBoxSize:Du(Math.round($*devicePixelRatio),Math.round(k*devicePixelRatio),o),borderBoxSize:Du(S,E,o),contentBoxSize:Du($,k,o),contentRect:new ku(u,s,$,k)});return _u.set(e,O),O},Vu=function(e,t,n){var r=ju(e,n),i=r.borderBoxSize,o=r.contentBoxSize,a=r.devicePixelContentBoxSize;switch(t){case su.DEVICE_PIXEL_CONTENT_BOX:return a;case su.BORDER_BOX:return i;default:return o}},Iu=function(e){var t=ju(e);this.target=e,this.contentRect=t.contentRect,this.borderBoxSize=wu([t.borderBoxSize]),this.contentBoxSize=wu([t.contentBoxSize]),this.devicePixelContentBoxSize=wu([t.devicePixelContentBoxSize])},zu=function(e){if(Eu(e))return 1/0;for(var t=0,n=e.parentNode;n;)t+=1,n=n.parentNode;return t},Au=function(){var e=1/0,t=[];bu.forEach((function(n){if(0!==n.activeTargets.length){var r=[];n.activeTargets.forEach((function(t){var n=new Iu(t.target),i=zu(t.target);r.push(n),t.lastReportedSize=Vu(t.target,t.observedBox),i<e&&(e=i)})),t.push((function(){n.callback.call(n.observer,r,n.observer)})),n.activeTargets.splice(0,n.activeTargets.length)}}));for(var n=0,r=t;n<r.length;n++){(0,r[n])()}return e},Hu=function(e){bu.forEach((function(t){t.activeTargets.splice(0,t.activeTargets.length),t.skippedTargets.splice(0,t.skippedTargets.length),t.observationTargets.forEach((function(n){n.isActive()&&(zu(n.target)>e?t.activeTargets.push(n):t.skippedTargets.push(n))}))}))},Bu=function(){var e=0;for(Hu(e);bu.some((function(e){return e.activeTargets.length>0}));)e=Au(),Hu(e);return bu.some((function(e){return e.skippedTargets.length>0}))&&function(){var e;"function"==typeof ErrorEvent?e=new ErrorEvent("error",{message:yu}):((e=document.createEvent("Event")).initEvent("error",!1,!1),e.message=yu),window.dispatchEvent(e)}(),e>0},Fu=[],Zu=function(e){if(!Cu){var t=0,n=document.createTextNode("");new MutationObserver((function(){return Fu.splice(0).forEach((function(e){return e()}))})).observe(n,{characterData:!0}),Cu=function(){n.textContent="".concat(t?t--:t++)}}Fu.push(e),Cu()},qu=0,Gu={attributes:!0,characterData:!0,childList:!0,subtree:!0},Wu=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],Uu=function(e){return void 0===e&&(e=0),Date.now()+e},Xu=!1,Yu=new(function(){function e(){var e=this;this.stopped=!0,this.listener=function(){return e.schedule()}}return e.prototype.run=function(e){var t=this;if(void 0===e&&(e=250),!Xu){Xu=!0;var n,r=Uu(e);n=function(){var n=!1;try{n=Bu()}finally{if(Xu=!1,e=r-Uu(),!qu)return;n?t.run(1e3):e>0?t.run(e):t.start()}},Zu((function(){requestAnimationFrame(n)}))}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var e=this,t=function(){return e.observer&&e.observer.observe(document.body,Gu)};document.body?t():Lu.addEventListener("DOMContentLoaded",t)},e.prototype.start=function(){var e=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),Wu.forEach((function(t){return Lu.addEventListener(t,e.listener,!0)})))},e.prototype.stop=function(){var e=this;this.stopped||(this.observer&&this.observer.disconnect(),Wu.forEach((function(t){return Lu.removeEventListener(t,e.listener,!0)})),this.stopped=!0)},e}()),Ku=function(e){!qu&&e>0&&Yu.start(),!(qu+=e)&&Yu.stop()},Ju=function(){function e(e,t){this.target=e,this.observedBox=t||su.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var e=Vu(this.target,this.observedBox,!0);return function(e){return!Su(e)&&!function(e){switch(e.tagName){case"INPUT":if("image"!==e.type)break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1}(e)&&"inline"===getComputedStyle(e).display}(this.target)&&(this.lastReportedSize=e),this.lastReportedSize.inlineSize!==e.inlineSize||this.lastReportedSize.blockSize!==e.blockSize},e}(),Qu=function(e,t){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=e,this.callback=t},ep=new WeakMap,tp=function(e,t){for(var n=0;n<e.length;n+=1)if(e[n].target===t)return n;return-1},np=function(){function e(){}return e.connect=function(e,t){var n=new Qu(e,t);ep.set(e,n)},e.observe=function(e,t,n){var r=ep.get(e),i=0===r.observationTargets.length;tp(r.observationTargets,t)<0&&(i&&bu.push(r),r.observationTargets.push(new Ju(t,n&&n.box)),Ku(1),Yu.schedule())},e.unobserve=function(e,t){var n=ep.get(e),r=tp(n.observationTargets,t),i=1===n.observationTargets.length;r>=0&&(i&&bu.splice(bu.indexOf(n),1),n.observationTargets.splice(r,1),Ku(-1))},e.disconnect=function(e){var t=this,n=ep.get(e);n.observationTargets.slice().forEach((function(n){return t.unobserve(e,n.target)})),n.activeTargets.splice(0,n.activeTargets.length)},e}(),rp=function(){function e(e){if(0===arguments.length)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if("function"!=typeof e)throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");np.connect(this,e)}return e.prototype.observe=function(e,t){if(0===arguments.length)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Ou(e))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");np.observe(this,e,t)},e.prototype.unobserve=function(e){if(0===arguments.length)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Ou(e))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");np.unobserve(this,e)},e.prototype.disconnect=function(){np.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e}();function ip(){return ip=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ip.apply(this,arguments)}function op(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)t.indexOf(n=o[r])>=0||(i[n]=e[n]);return i}var ap="undefined"!=typeof window?J:U;function lp(e,t,n){return t=(t=+t)==t?t:0,n=(n=+n)==n?n:0,(e=+e)==e&&(e=(e=e<=n?e:n)>=t?e:t),e}function sp(e){var t=Math.round(e);if(Number.isNaN(e))throw new TypeError("Found a NaN! Check your snapPoints / defaultSnap / snapTo ");return t}var cp={box:"border-box"};function dp(e,t){var n=t.label,r=t.enabled,i=t.resizeSourceRef,o=W(0),a=o[0],l=o[1];re(n+": "+a);var s=Q((function(e){l(e[0].borderBoxSize[0].blockSize),i.current="element"}),[i]);return ap((function(){if(e.current&&r){var t=new rp(s);return t.observe(e.current,cp),function(){t.disconnect()}}}),[e,s,r]),r?a:0}function up(e){return void 0===e&&(e=1e3),new Promise((function(t){return setTimeout(t,e)}))}var pp={DRAG:{target:"#overlay.dragging",actions:"onOpenEnd"}},hp={RESIZE:{target:"#overlay.resizing",actions:"onOpenEnd"}},fp=function(e,t,n){return void 0===n&&(n=e.context),new xs(e,t,n)}({id:"overlay",initial:"closed",context:{initialState:"CLOSED"},states:{closed:{on:{OPEN:"opening",CLOSE:void 0}},opening:{initial:"start",states:{start:{invoke:{src:"onOpenStart",onDone:"transition"}},transition:{always:[{target:"immediately",cond:"initiallyOpen"},{target:"smoothly",cond:"initiallyClosed"}]},immediately:{initial:"open",states:{open:{invoke:{src:"openImmediately",onDone:"activating"}},activating:{invoke:{src:"activate",onDone:"#overlay.opening.end"},on:ip({},pp,hp)}}},smoothly:{initial:"visuallyHidden",states:{visuallyHidden:{invoke:{src:"renderVisuallyHidden",onDone:"activating"}},activating:{invoke:{src:"activate",onDone:"open"}},open:{invoke:{src:"openSmoothly",onDone:"#overlay.opening.end"},on:ip({},pp,hp)}}},end:{invoke:{src:"onOpenEnd",onDone:"done"},on:{CLOSE:"#overlay.closing",DRAG:"#overlay.dragging"}},done:{type:"final"}},on:ip({},{CLOSE:{target:"#overlay.closing",actions:"onOpenCancel"}}),onDone:"open"},open:{on:{DRAG:"#overlay.dragging",SNAP:"snapping",RESIZE:"resizing"}},dragging:{on:{SNAP:"snapping"}},snapping:{initial:"start",states:{start:{invoke:{src:"onSnapStart",onDone:"snappingSmoothly"},entry:[ys({y:function(e,t){return t.payload.y},velocity:function(e,t){return t.payload.velocity},snapSource:function(e,t){var n=t.payload.source;return void 0===n?"custom":n}})]},snappingSmoothly:{invoke:{src:"snapSmoothly",onDone:"end"}},end:{invoke:{src:"onSnapEnd",onDone:"done"},on:{RESIZE:"#overlay.resizing",SNAP:"#overlay.snapping",CLOSE:"#overlay.closing",DRAG:"#overlay.dragging"}},done:{type:"final"}},on:{SNAP:{target:"snapping",actions:"onSnapEnd"},RESIZE:{target:"#overlay.resizing",actions:"onSnapCancel"},DRAG:{target:"#overlay.dragging",actions:"onSnapCancel"},CLOSE:{target:"#overlay.closing",actions:"onSnapCancel"}},onDone:"open"},resizing:{initial:"start",states:{start:{invoke:{src:"onResizeStart",onDone:"resizingSmoothly"}},resizingSmoothly:{invoke:{src:"resizeSmoothly",onDone:"end"}},end:{invoke:{src:"onResizeEnd",onDone:"done"},on:{SNAP:"#overlay.snapping",CLOSE:"#overlay.closing",DRAG:"#overlay.dragging"}},done:{type:"final"}},on:{RESIZE:{target:"resizing",actions:"onResizeEnd"},SNAP:{target:"snapping",actions:"onResizeCancel"},DRAG:{target:"#overlay.dragging",actions:"onResizeCancel"},CLOSE:{target:"#overlay.closing",actions:"onResizeCancel"}},onDone:"open"},closing:{initial:"start",states:{start:{invoke:{src:"onCloseStart",onDone:"deactivating"},on:{OPEN:{target:"#overlay.open",actions:"onCloseCancel"}}},deactivating:{invoke:{src:"deactivate",onDone:"closingSmoothly"}},closingSmoothly:{invoke:{src:"closeSmoothly",onDone:"end"}},end:{invoke:{src:"onCloseEnd",onDone:"done"},on:{OPEN:{target:"#overlay.opening",actions:"onCloseCancel"}}},done:{type:"final"}},on:{CLOSE:void 0,OPEN:{target:"#overlay.opening",actions:"onCloseCancel"}},onDone:"closed"}},on:{CLOSE:"closing"}},{actions:{onOpenCancel:function(e,t){},onSnapCancel:function(e,t){},onResizeCancel:function(e,t){},onCloseCancel:function(e,t){},onOpenEnd:function(e,t){},onSnapEnd:function(e,t){},onRezizeEnd:function(e,t){}},services:{onSnapStart:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onOpenStart:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onCloseStart:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onResizeStart:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onSnapEnd:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onOpenEnd:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onCloseEnd:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onResizeEnd:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},renderVisuallyHidden:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},activate:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},deactivate:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},openSmoothly:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},openImmediately:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},snapSmoothly:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},resizeSmoothly:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},closeSmoothly:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}}},guards:{initiallyClosed:function(e){return"CLOSED"===e.initialState},initiallyOpen:function(e){return"OPEN"===e.initialState}}}),gp=["children","sibling","className","footer","header","open","initialState","lastSnapRef","initialFocusRef","onDismiss","maxHeight","defaultSnap","snapPoints","blocking","scrollLocking","style","onSpringStart","onSpringCancel","onSpringEnd","reserveScrollBarGap","expandOnContentDrag"],vp=["velocity"],mp=["onRest","config"],xp={tension:170,friction:26},bp=xp.tension,yp=xp.friction,Cp=q.forwardRef((function(e,t){var n=e.children,r=e.sibling,i=e.className,o=e.footer,a=e.header,l=e.open,s=e.initialState,c=e.lastSnapRef,d=e.initialFocusRef,u=e.onDismiss,p=e.maxHeight,h=e.defaultSnap,f=void 0===h?$p:h,g=e.snapPoints,v=void 0===g?kp:g,m=e.blocking,x=void 0===m||m,b=e.scrollLocking,y=void 0===b||b,C=e.style,w=e.onSpringStart,$=e.onSpringCancel,k=e.onSpringEnd,S=e.reserveScrollBarGap,E=void 0===S?x:S,O=e.expandOnContentDrag,L=void 0!==O&&O,_=op(e,gp),T=function(){var e=W(!1),t=e[0],n=e[1],r=W({}),i=r[0],o=r[1],a=Q((function(e){return o((function(t){var n;return ip({},t,((n={})[e]=!1,n))})),function(){o((function(t){var n;return ip({},t,((n={})[e]=!0,n))}))}}),[]);return U((function(){var e=Object.values(i);0!==e.length&&e.every(Boolean)&&n(!0)}),[i]),{ready:t,registerReady:a}}(),R=T.ready,P=T.registerReady,M=K(!1),D=K(w),N=K($),j=K(k);U((function(){D.current=w,N.current=$,j.current=k}),[$,w,k]);var V,I,z=sc((function(){return{y:0,ready:0,maxHeight:0,minSnap:0,maxSnap:0}})),A=z[0],H=z[1],B=K(null),F=K(null),Z=K(null),G=K(null),X=K(null),Y=K(null),J=K(0),ee=K(),ie=K(!1),oe=(V=te((function(){return"undefined"!=typeof window?window.matchMedia("(prefers-reduced-motion: reduce)"):null}),[]),I=K(null==V?void 0:V.matches),re(I.current?"reduce":"no-preference"),U((function(){var e=function(e){I.current=e.matches};return null==V||V.addListener(e),function(){return null==V?void 0:V.removeListener(e)}}),[V]),I),ae=function(e){var t=e.targetRef,n=e.enabled,r=e.reserveScrollBarGap,i=K({activate:function(){throw new TypeError("Tried to activate scroll lock too early")},deactivate:function(){}});return re(n?"Enabled":"Disabled"),U((function(){if(!n)return i.current.deactivate(),void(i.current={activate:function(){},deactivate:function(){}});var e=t.current,o=!1;i.current={activate:function(){o||(o=!0,mu(e,{allowTouchMove:function(e){return e.closest("[data-body-scroll-lock-ignore]")},reserveScrollBarGap:r}))},deactivate:function(){o&&(o=!1,xu(e))}}}),[n,t,r]),i}({targetRef:F,enabled:R&&y,reserveScrollBarGap:E}),le=function(e){var t=e.targetRef,n=e.enabled,r=K({activate:function(){throw new TypeError("Tried to activate aria hider too early")},deactivate:function(){}});return re(n?"Enabled":"Disabled"),U((function(){if(!n)return r.current.deactivate(),void(r.current={activate:function(){},deactivate:function(){}});var e=t.current,i=!1,o=[],a=[];r.current={activate:function(){if(!i){i=!0;var t=e.parentNode;document.querySelectorAll("body > *").forEach((function(e){if(e!==t){var n=e.getAttribute("aria-hidden");null!==n&&"false"!==n||(o.push(n),a.push(e),e.setAttribute("aria-hidden","true"))}}))}},deactivate:function(){i&&(i=!1,a.forEach((function(e,t){var n=o[t];null===n?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",n)})),o=[],a=[])}}}),[t,n]),r}({targetRef:B,enabled:R&&x}),se=function(e){var t=e.targetRef,n=e.fallbackRef,r=e.initialFocusRef,i=e.enabled,o=K({activate:function(){throw new TypeError("Tried to activate focus trap too early")},deactivate:function(){}});return re(i?"Enabled":"Disabled"),U((function(){if(!i)return o.current.deactivate(),void(o.current={activate:function(){},deactivate:function(){}});var e=n.current,a=ou(t.current,{onActivate:void 0,initialFocus:r?function(){return(null==r?void 0:r.current)||e}:void 0,fallbackFocus:e,escapeDeactivates:!1,clickOutsideDeactivates:!1}),l=!1;o.current={activate:function(){try{return l?Promise.resolve():(l=!0,Promise.resolve(a.activate()).then((function(){return Promise.resolve(new Promise((function(e){return setTimeout((function(){return e(void 0)}),0)}))).then((function(){}))})))}catch(e){return Promise.reject(e)}},deactivate:function(){l&&(l=!1,a.deactivate())}}}),[i,n,r,t]),o}({targetRef:B,fallbackRef:Y,initialFocusRef:d||void 0,enabled:R&&x&&!1!==d}),ce=function(e){var t=e.getSnapPoints,n=e.heightRef,r=e.lastSnapRef,i=e.ready,o=function(e){var t=e.contentRef,n=e.controlledMaxHeight,r=e.footerEnabled,i=e.footerRef,o=e.headerEnabled,a=e.headerRef,l=e.registerReady,s=e.resizeSourceRef,c=te((function(){return l("contentHeight")}),[l]),d=function(e,t,n){var r=te((function(){return t("maxHeight")}),[t]),i=W((function(){return sp(e)||"undefined"!=typeof window?window.innerHeight:0})),o=i[0],a=i[1],l=o>0,s=K(0);return re(e?"controlled":"auto"),U((function(){l&&r()}),[l,r]),ap((function(){if(e)return a(sp(e)),void(n.current="maxheightprop");var t=function(){s.current||(s.current=requestAnimationFrame((function(){a(window.innerHeight),n.current="window",s.current=0})))};return window.addEventListener("resize",t),a(window.innerHeight),n.current="window",r(),function(){window.removeEventListener("resize",t),cancelAnimationFrame(s.current)}}),[e,r,n]),o}(n,l,s),u=dp(a,{label:"headerHeight",enabled:o,resizeSourceRef:s}),p=dp(t,{label:"contentHeight",enabled:!0,resizeSourceRef:s}),h=dp(i,{label:"footerHeight",enabled:r,resizeSourceRef:s}),f=Math.min(d-u-h,p)+u+h;re("minHeight: "+f);var g=p>0;return U((function(){g&&c()}),[g,c]),{maxHeight:d,minHeight:f,headerHeight:u,footerHeight:h}}({contentRef:e.contentRef,controlledMaxHeight:e.controlledMaxHeight,footerEnabled:e.footerEnabled,footerRef:e.footerRef,headerEnabled:e.headerEnabled,headerRef:e.headerRef,registerReady:e.registerReady,resizeSourceRef:e.resizeSourceRef}),a=o.maxHeight,l=o.minHeight,s=o.headerHeight,c=o.footerHeight,d=function(e,t){var n=[].concat(e).map(sp).reduce((function(e,n){return e.add(lp(n,0,t)),e}),new Set),r=Array.from(n),i=Math.min.apply(Math,r);if(Number.isNaN(i))throw new TypeError("minSnap is NaN");var o=Math.max.apply(Math,r);if(Number.isNaN(o))throw new TypeError("maxSnap is NaN");return{snapPoints:r,minSnap:i,maxSnap:o}}(i?t({height:n.current,footerHeight:c,headerHeight:s,minHeight:l,maxHeight:a}):[0],a),u=d.snapPoints,p=d.minSnap,h=d.maxSnap;return re("minSnap: "+p+", maxSnap:"+h),{minSnap:p,maxSnap:h,findSnap:function(e){var t=sp("function"==typeof e?e({footerHeight:c,headerHeight:s,height:n.current,minHeight:l,maxHeight:a,snapPoints:u,lastSnap:r.current}):e);return u.reduce((function(e,n){return Math.abs(n-t)<Math.abs(e-t)?n:e}),p)},maxHeight:a}}({contentRef:Z,controlledMaxHeight:p,footerEnabled:!!o,footerRef:X,getSnapPoints:v,headerEnabled:!1!==a,headerRef:G,heightRef:J,lastSnapRef:c,ready:R,registerReady:P,resizeSourceRef:ee}),de=ce.minSnap,ue=ce.maxSnap,pe=ce.maxHeight,he=ce.findSnap,fe=K(pe),ge=K(de),ve=K(ue),me=K(he),xe=K(0);ap((function(){fe.current=pe,ve.current=ue,ge.current=de,me.current=he,xe.current=he(f)}),[he,f,pe,ue,de]);var be=Q((function(e){var t=e.onRest,n=e.config,r=(n=void 0===n?{}:n).velocity,i=void 0===r?1:r,o=op(n,vp),a=op(e,mp);return new Promise((function(e){return H(ip({},a,{config:ip({velocity:i},o,{mass:1,tension:bp,friction:Math.max(yp,yp+(yp-yp*i))}),onRest:function(){var n=[].slice.call(arguments);e.apply(void 0,n),null==t||t.apply(void 0,n)}}))}))}),[H]),ye=Ms(fp,{devTools:!1,actions:{onOpenCancel:Q((function(){return null==N.current?void 0:N.current({type:"OPEN"})}),[]),onSnapCancel:Q((function(e){return null==N.current?void 0:N.current({type:"SNAP",source:e.snapSource})}),[]),onCloseCancel:Q((function(){return null==N.current?void 0:N.current({type:"CLOSE"})}),[]),onResizeCancel:Q((function(){return null==N.current?void 0:N.current({type:"RESIZE",source:ee.current})}),[]),onOpenEnd:Q((function(){return null==j.current?void 0:j.current({type:"OPEN"})}),[]),onSnapEnd:Q((function(e,t){return null==j.current?void 0:j.current({type:"SNAP",source:e.snapSource})}),[]),onResizeEnd:Q((function(){return null==j.current?void 0:j.current({type:"RESIZE",source:ee.current})}),[])},context:{initialState:s},services:{onSnapStart:Q((function(e,t){try{return Promise.resolve(null==D.current?void 0:D.current({type:"SNAP",source:t.payload.source||"custom"}))}catch(e){return Promise.reject(e)}}),[]),onOpenStart:Q((function(){try{return Promise.resolve(null==D.current?void 0:D.current({type:"OPEN"}))}catch(e){return Promise.reject(e)}}),[]),onCloseStart:Q((function(){try{return Promise.resolve(null==D.current?void 0:D.current({type:"CLOSE"}))}catch(e){return Promise.reject(e)}}),[]),onResizeStart:Q((function(){try{return Promise.resolve(null==D.current?void 0:D.current({type:"RESIZE",source:ee.current}))}catch(e){return Promise.reject(e)}}),[]),onSnapEnd:Q((function(e,t){try{return Promise.resolve(null==j.current?void 0:j.current({type:"SNAP",source:e.snapSource}))}catch(e){return Promise.reject(e)}}),[]),onOpenEnd:Q((function(){try{return Promise.resolve(null==j.current?void 0:j.current({type:"OPEN"}))}catch(e){return Promise.reject(e)}}),[]),onCloseEnd:Q((function(){try{return Promise.resolve(null==j.current?void 0:j.current({type:"CLOSE"}))}catch(e){return Promise.reject(e)}}),[]),onResizeEnd:Q((function(){try{return Promise.resolve(null==j.current?void 0:j.current({type:"RESIZE",source:ee.current}))}catch(e){return Promise.reject(e)}}),[]),renderVisuallyHidden:Q((function(e,t){try{return Promise.resolve(be({y:xe.current,ready:0,maxHeight:fe.current,maxSnap:ve.current,minSnap:xe.current,immediate:!0})).then((function(){}))}catch(e){return Promise.reject(e)}}),[be]),activate:Q((function(e,t){try{return M.current=!0,Promise.resolve(Promise.all([ae.current.activate(),se.current.activate(),le.current.activate()])).then((function(){}))}catch(e){return Promise.reject(e)}}),[le,se,ae]),deactivate:Q((function(){try{return ae.current.deactivate(),se.current.deactivate(),le.current.deactivate(),M.current=!1,Promise.resolve()}catch(e){return Promise.reject(e)}}),[le,se,ae]),openImmediately:Q((function(){try{return J.current=xe.current,Promise.resolve(be({y:xe.current,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:xe.current,immediate:!0})).then((function(){}))}catch(e){return Promise.reject(e)}}),[be]),openSmoothly:Q((function(){try{return Promise.resolve(be({y:0,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:xe.current,immediate:!0})).then((function(){return J.current=xe.current,Promise.resolve(be({y:xe.current,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:xe.current,immediate:oe.current})).then((function(){}))}))}catch(e){return Promise.reject(e)}}),[be,oe]),snapSmoothly:Q((function(e,t){try{var n=me.current(e.y);return J.current=n,c.current=n,Promise.resolve(be({y:n,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:ge.current,immediate:oe.current,config:{velocity:e.velocity}})).then((function(){}))}catch(e){return Promise.reject(e)}}),[be,c,oe]),resizeSmoothly:Q((function(){try{var e=me.current(J.current);return J.current=e,c.current=e,Promise.resolve(be({y:e,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:ge.current,immediate:"element"!==ee.current||oe.current})).then((function(){}))}catch(e){return Promise.reject(e)}}),[be,c,oe]),closeSmoothly:Q((function(e,t){try{return be({minSnap:J.current,immediate:!0}),J.current=0,Promise.resolve(be({y:0,maxHeight:fe.current,maxSnap:ve.current,immediate:oe.current})).then((function(){return Promise.resolve(be({ready:0,immediate:!0})).then((function(){}))}))}catch(e){return Promise.reject(e)}}),[be,oe])}}),Ce=ye[0],we=ye[1];U((function(){R&&we(l?"OPEN":"CLOSE")}),[l,we,R]),ap((function(){(pe||ue||de)&&we("RESIZE")}),[pe,ue,de,we]),U((function(){return function(){ae.current.deactivate(),se.current.deactivate(),le.current.deactivate()}}),[le,se,ae]),ne(t,(function(){return{snapTo:function(e,t){var n=void 0===t?{}:t,r=n.velocity,i=void 0===r?1:r,o=n.source,a=void 0===o?"custom":o;we("SNAP",{payload:{y:me.current(e),velocity:i,source:a}})},get height(){return J.current}}}),[we]),U((function(){var e=F.current,t=function(e){ie.current&&e.preventDefault()},n=function(t){e.scrollTop<0&&(requestAnimationFrame((function(){e.style.overflow="hidden",e.scrollTop=0,e.style.removeProperty("overflow")})),t.preventDefault())};return L&&(e.addEventListener("scroll",t),e.addEventListener("touchmove",t),e.addEventListener("touchstart",n)),function(){e.removeEventListener("scroll",t),e.removeEventListener("touchmove",t),e.removeEventListener("touchstart",n)}}),[L,F]);var $e=_d((function(e){var t=e.args,n=(t=void 0===t?[]:t)[0],r=(n=void 0===n?{}:n).closeOnTap,i=void 0!==r&&r,o=n.isContentDragging,a=void 0!==o&&o,l=e.cancel,s=e.direction[1],c=e.down,d=e.first,p=e.last,h=e.memo,f=void 0===h?A.y.getValue():h,g=e.tap,v=e.velocity,m=-1*e.movement[1];if(!M.current)return l(),f;if(u&&i&&g)return l(),setTimeout((function(){return u()}),0),f;if(g)return f;var x=f+m,b=m*v,y=Math.max(ge.current,Math.min(ve.current,x+2*b));if(!c&&u&&s>0&&x+b<ge.current/2)return l(),u(),f;var C=c?u||ge.current!==ve.current?Zc(x,u?0:ge.current,ve.current,.55):x<ge.current?Zc(x,ge.current,2*ve.current,.55):Zc(x,ge.current/2,ve.current,.55):y;return L&&a?(C>=ve.current&&(C=ve.current),f===ve.current&&F.current.scrollTop>0&&(C=ve.current),ie.current=C<ve.current):ie.current=!1,d&&we("DRAG"),p?(we("SNAP",{payload:{y:C,velocity:v>.05?v:1,source:"dragging"}}),f):(H({y:C,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:ge.current,immediate:!0,config:{velocity:v}}),f)}),{filterTaps:!0});if(Number.isNaN(ve.current))throw new TypeError("maxSnapRef is NaN!!");if(Number.isNaN(ge.current))throw new TypeError("minSnapRef is NaN!!");var ke=function(e){var t,n=e.spring,r=nc([n.y,n.maxHeight],(function(e,t){return Math.round(lp(t-e,0,16))+"px"})),i=nc([n.y,n.minSnap,n.maxSnap],(function(e,t,n){return lp(e,t,n)+"px"})),o=nc([n.y,n.minSnap,n.maxSnap],(function(e,t,n){return e<t?t-e+"px":e>n?n-e+"px":"0px"})),a=nc([n.y,n.maxSnap],(function(e,t){return e>=t?Math.ceil(e-t):0})),l=nc([n.y,n.minSnap],(function(e,t){if(!t)return 0;var n=Math.max(t/2-45,0);return lp((e-n)*(1/(Math.min(t/2+45,t)-n)+0),0,1)})),s=nc([n.y,n.minSnap],(function(e,t){return t?lp(e/t,0,1):0}));return(t={})["--rsbs-content-opacity"]=l,t["--rsbs-backdrop-opacity"]=s,t["--rsbs-antigap-scale-y"]=a,t["--rsbs-overlay-translate-y"]=o,t["--rsbs-overlay-rounded"]=r,t["--rsbs-overlay-h"]=i,t}({spring:A});return q.createElement(Ic.div,ip({},_,{"data-rsbs-root":!0,"data-rsbs-state":wp.find(Ce.matches),"data-rsbs-is-blocking":x,"data-rsbs-is-dismissable":!!u,"data-rsbs-has-header":!!a,"data-rsbs-has-footer":!!o,className:i,ref:B,style:ip({},ke,C,{opacity:A.ready})}),r,x&&q.createElement("div",ip({key:"backdrop","data-rsbs-backdrop":!0},$e({closeOnTap:!0}))),q.createElement("div",{key:"overlay","aria-modal":"true",role:"dialog","data-rsbs-overlay":!0,tabIndex:-1,ref:Y,onKeyDown:function(e){"Escape"===e.key&&(e.stopPropagation(),u&&u())}},!1!==a&&q.createElement("div",ip({key:"header","data-rsbs-header":!0,ref:G},$e()),a),q.createElement("div",ip({key:"scroll","data-rsbs-scroll":!0,ref:F},L?$e({isContentDragging:!0}):{}),q.createElement("div",{"data-rsbs-content":!0,ref:Z},n)),o&&q.createElement("div",ip({key:"footer",ref:X,"data-rsbs-footer":!0},$e()),o)))})),wp=["closed","opening","open","closing","dragging","snapping","resizing"];function $p(e){var t=e.lastSnap;return null!=t?t:Math.min.apply(Math,e.snapPoints)}function kp(e){return e.minHeight}var Sp=["onSpringStart","onSpringEnd","skipInitialTransition"],Ep=G((function(e,t){var n=e.onSpringStart,r=e.onSpringEnd,i=e.skipInitialTransition,o=op(e,Sp),a=W(!1),l=a[0],s=a[1],c=K(),d=K(null),u=K(i&&o.open?"OPEN":"CLOSED");ap((function(){if(o.open)return cancelAnimationFrame(c.current),s(!0),function(){u.current="CLOSED"}}),[o.open]);var p=Q((function(e){return Promise.resolve(null==n?void 0:n(e)).then((function(){"OPEN"===e.type&&cancelAnimationFrame(c.current)}))}),[n]),h=Q((function(e){return Promise.resolve(null==r?void 0:r(e)).then((function(){"CLOSE"===e.type&&(c.current=requestAnimationFrame((function(){return s(!1)})))}))}),[r]);return l?q.createElement(wa,{"data-rsbs-portal":!0},q.createElement(Cp,ip({},o,{lastSnapRef:d,ref:t,initialState:u.current,onSpringStart:p,onSpringEnd:h}))):null}));const Op=(e,t)=>oe`
2346
+ function Yd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Kd(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Yd(Object(n),!0).forEach((function(t){Jd(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yd(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function Jd(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Qd,eu=(Qd=[],{activateTrap:function(e){if(Qd.length>0){var t=Qd[Qd.length-1];t!==e&&t.pause()}var n=Qd.indexOf(e);-1===n||Qd.splice(n,1),Qd.push(e)},deactivateTrap:function(e){var t=Qd.indexOf(e);-1!==t&&Qd.splice(t,1),Qd.length>0&&Qd[Qd.length-1].unpause()}}),tu=function(e){return setTimeout(e,0)},nu=function(e,t){var n=-1;return e.every((function(e,r){return!t(e)||(n=r,!1)})),n},ru=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return"function"==typeof e?e.apply(void 0,n):e},iu=function(e){return e.target.shadowRoot&&"function"==typeof e.composedPath?e.composedPath()[0]:e.target},ou=function(e,t){var n,r=(null==t?void 0:t.document)||document,i=Kd({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0},t),o={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,delayInitialFocusTimer:void 0},a=function(e,t,n){return e&&void 0!==e[t]?e[t]:i[n||t]},l=function(e){return o.containerGroups.findIndex((function(t){var n=t.container,r=t.tabbableNodes;return n.contains(e)||r.find((function(t){return t===e}))}))},s=function(e){var t=i[e];if("function"==typeof t){for(var n=arguments.length,o=new Array(n>1?n-1:0),a=1;a<n;a++)o[a-1]=arguments[a];t=t.apply(void 0,o)}if(!0===t&&(t=void 0),!t){if(void 0===t||!1===t)return t;throw new Error("`".concat(e,"` was specified but was not a node, or did not return a node"))}var l=t;if("string"==typeof t&&!(l=r.querySelector(t)))throw new Error("`".concat(e,"` as selector refers to no known node"));return l},c=function(){var e=s("initialFocus");if(!1===e)return!1;if(void 0===e)if(l(r.activeElement)>=0)e=r.activeElement;else{var t=o.tabbableGroups[0];e=t&&t.firstTabbableNode||s("fallbackFocus")}if(!e)throw new Error("Your focus-trap needs to have at least one focusable element");return e},d=function(){if(o.containerGroups=o.containers.map((function(e){var t,n,r=Gd(e,i.tabbableOptions),o=(t=e,(n=(n=i.tabbableOptions)||{}).getShadowRoot?jd([t],n.includeContainer,{filter:Bd.bind(null,n),flatten:!0,getShadowRoot:n.getShadowRoot}):Nd(t,n.includeContainer,Bd.bind(null,n)));return{container:e,tabbableNodes:r,focusableNodes:o,firstTabbableNode:r.length>0?r[0]:null,lastTabbableNode:r.length>0?r[r.length-1]:null,nextTabbableNode:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=o.findIndex((function(t){return t===e}));if(!(n<0))return t?o.slice(n+1).find((function(e){return Wd(e,i.tabbableOptions)})):o.slice(0,n).reverse().find((function(e){return Wd(e,i.tabbableOptions)}))}}})),o.tabbableGroups=o.containerGroups.filter((function(e){return e.tabbableNodes.length>0})),o.tabbableGroups.length<=0&&!s("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times")},u=function e(t){!1!==t&&t!==r.activeElement&&(t&&t.focus?(t.focus({preventScroll:!!i.preventScroll}),o.mostRecentlyFocusedNode=t,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(t)&&t.select()):e(c()))},p=function(e){var t=s("setReturnFocus",e);return t||!1!==t&&e},h=function(e){var t=iu(e);l(t)>=0||(ru(i.clickOutsideDeactivates,e)?n.deactivate({returnFocus:i.returnFocusOnDeactivate&&!Xd(t,i.tabbableOptions)}):ru(i.allowOutsideClick,e)||e.preventDefault())},f=function(e){var t=iu(e),n=l(t)>=0;n||t instanceof Document?n&&(o.mostRecentlyFocusedNode=t):(e.stopImmediatePropagation(),u(o.mostRecentlyFocusedNode||c()))},g=function(e){if(function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e)&&!1!==ru(i.escapeDeactivates,e))return e.preventDefault(),void n.deactivate();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){var t=iu(e);d();var n=null;if(o.tabbableGroups.length>0){var r=l(t),a=r>=0?o.containerGroups[r]:void 0;if(r<0)n=e.shiftKey?o.tabbableGroups[o.tabbableGroups.length-1].lastTabbableNode:o.tabbableGroups[0].firstTabbableNode;else if(e.shiftKey){var c=nu(o.tabbableGroups,(function(e){var n=e.firstTabbableNode;return t===n}));if(c<0&&(a.container===t||Xd(t,i.tabbableOptions)&&!Wd(t,i.tabbableOptions)&&!a.nextTabbableNode(t,!1))&&(c=r),c>=0){var p=0===c?o.tabbableGroups.length-1:c-1;n=o.tabbableGroups[p].lastTabbableNode}}else{var h=nu(o.tabbableGroups,(function(e){var n=e.lastTabbableNode;return t===n}));if(h<0&&(a.container===t||Xd(t,i.tabbableOptions)&&!Wd(t,i.tabbableOptions)&&!a.nextTabbableNode(t))&&(h=r),h>=0){var f=h===o.tabbableGroups.length-1?0:h+1;n=o.tabbableGroups[f].firstTabbableNode}}}else n=s("fallbackFocus");n&&(e.preventDefault(),u(n))}(e)},v=function(e){var t=iu(e);l(t)>=0||ru(i.clickOutsideDeactivates,e)||ru(i.allowOutsideClick,e)||(e.preventDefault(),e.stopImmediatePropagation())},m=function(){if(o.active)return eu.activateTrap(n),o.delayInitialFocusTimer=i.delayInitialFocus?tu((function(){u(c())})):u(c()),r.addEventListener("focusin",f,!0),r.addEventListener("mousedown",h,{capture:!0,passive:!1}),r.addEventListener("touchstart",h,{capture:!0,passive:!1}),r.addEventListener("click",v,{capture:!0,passive:!1}),r.addEventListener("keydown",g,{capture:!0,passive:!1}),n},x=function(){if(o.active)return r.removeEventListener("focusin",f,!0),r.removeEventListener("mousedown",h,!0),r.removeEventListener("touchstart",h,!0),r.removeEventListener("click",v,!0),r.removeEventListener("keydown",g,!0),n};return(n={get active(){return o.active},get paused(){return o.paused},activate:function(e){if(o.active)return this;var t=a(e,"onActivate"),n=a(e,"onPostActivate"),i=a(e,"checkCanFocusTrap");i||d(),o.active=!0,o.paused=!1,o.nodeFocusedBeforeActivation=r.activeElement,t&&t();var l=function(){i&&d(),m(),n&&n()};return i?(i(o.containers.concat()).then(l,l),this):(l(),this)},deactivate:function(e){if(!o.active)return this;var t=Kd({onDeactivate:i.onDeactivate,onPostDeactivate:i.onPostDeactivate,checkCanReturnFocus:i.checkCanReturnFocus},e);clearTimeout(o.delayInitialFocusTimer),o.delayInitialFocusTimer=void 0,x(),o.active=!1,o.paused=!1,eu.deactivateTrap(n);var r=a(t,"onDeactivate"),l=a(t,"onPostDeactivate"),s=a(t,"checkCanReturnFocus"),c=a(t,"returnFocus","returnFocusOnDeactivate");r&&r();var d=function(){tu((function(){c&&u(p(o.nodeFocusedBeforeActivation)),l&&l()}))};return c&&s?(s(p(o.nodeFocusedBeforeActivation)).then(d,d),this):(d(),this)},pause:function(){return o.paused||!o.active||(o.paused=!0,x()),this},unpause:function(){return o.paused&&o.active?(o.paused=!1,d(),m(),this):this},updateContainerElements:function(e){var t=[].concat(e).filter(Boolean);return o.containers=t.map((function(e){return"string"==typeof e?r.querySelector(e):e})),o.active&&d(),this}}).updateContainerElements(e),n};var au=!1;if("undefined"!=typeof window){var lu={get passive(){au=!0}};window.addEventListener("testPassive",null,lu),window.removeEventListener("testPassive",null,lu)}var su,cu="undefined"!=typeof window&&window.navigator&&window.navigator.platform&&(/iP(ad|hone|od)/.test(window.navigator.platform)||"MacIntel"===window.navigator.platform&&window.navigator.maxTouchPoints>1),du=[],uu=!1,pu=-1,hu=void 0,fu=void 0,gu=function(e){return du.some((function(t){return!(!t.options.allowTouchMove||!t.options.allowTouchMove(e))}))},vu=function(e){var t=e||window.event;return!!gu(t.target)||(t.touches.length>1||(t.preventDefault&&t.preventDefault(),!1))},mu=function(e,t){if(e){if(!du.some((function(t){return t.targetElement===e}))){var n={targetElement:e,options:t||{}};du=[].concat(function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(du),[n]),cu?(e.ontouchstart=function(e){1===e.targetTouches.length&&(pu=e.targetTouches[0].clientY)},e.ontouchmove=function(t){1===t.targetTouches.length&&function(e,t){var n=e.targetTouches[0].clientY-pu;!gu(e.target)&&(t&&0===t.scrollTop&&n>0||function(e){return!!e&&e.scrollHeight-e.scrollTop<=e.clientHeight}(t)&&n<0?vu(e):e.stopPropagation())}(t,e)},uu||(document.addEventListener("touchmove",vu,au?{passive:!1}:void 0),uu=!0)):function(e){if(void 0===fu){var t=!!e&&!0===e.reserveScrollBarGap,n=window.innerWidth-document.documentElement.clientWidth;t&&n>0&&(fu=document.body.style.paddingRight,document.body.style.paddingRight=n+"px")}void 0===hu&&(hu=document.body.style.overflow,document.body.style.overflow="hidden")}(t)}}else console.error("disableBodyScroll unsuccessful - targetElement must be provided when calling disableBodyScroll on IOS devices.")},xu=function(e){e?(du=du.filter((function(t){return t.targetElement!==e})),cu?(e.ontouchstart=null,e.ontouchmove=null,uu&&0===du.length&&(document.removeEventListener("touchmove",vu,au?{passive:!1}:void 0),uu=!1)):du.length||(void 0!==fu&&(document.body.style.paddingRight=fu,fu=void 0),void 0!==hu&&(document.body.style.overflow=hu,hu=void 0))):console.error("enableBodyScroll unsuccessful - targetElement must be provided when calling enableBodyScroll on IOS devices.")},bu=[],yu="ResizeObserver loop completed with undelivered notifications.";!function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"}(su||(su={}));var Cu,wu=function(e){return Object.freeze(e)},$u=function(e,t){this.inlineSize=e,this.blockSize=t,wu(this)},ku=function(){function e(e,t,n,r){return this.x=e,this.y=t,this.width=n,this.height=r,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,wu(this)}return e.prototype.toJSON=function(){var e=this;return{x:e.x,y:e.y,top:e.top,right:e.right,bottom:e.bottom,left:e.left,width:e.width,height:e.height}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e}(),Su=function(e){return e instanceof SVGElement&&"getBBox"in e},Eu=function(e){if(Su(e)){var t=e.getBBox(),n=t.width,r=t.height;return!n&&!r}var i=e,o=i.offsetWidth,a=i.offsetHeight;return!(o||a||e.getClientRects().length)},Ou=function(e){var t;if(e instanceof Element)return!0;var n=null===(t=null==e?void 0:e.ownerDocument)||void 0===t?void 0:t.defaultView;return!!(n&&e instanceof n.Element)},Lu="undefined"!=typeof window?window:{},_u=new WeakMap,Tu=/auto|scroll/,Ru=/^tb|vertical/,Pu=/msie|trident/i.test(Lu.navigator&&Lu.navigator.userAgent),Mu=function(e){return parseFloat(e||"0")},Du=function(e,t,n){return void 0===e&&(e=0),void 0===t&&(t=0),void 0===n&&(n=!1),new $u((n?t:e)||0,(n?e:t)||0)},Nu=wu({devicePixelContentBoxSize:Du(),borderBoxSize:Du(),contentBoxSize:Du(),contentRect:new ku(0,0,0,0)}),ju=function(e,t){if(void 0===t&&(t=!1),_u.has(e)&&!t)return _u.get(e);if(Eu(e))return _u.set(e,Nu),Nu;var n=getComputedStyle(e),r=Su(e)&&e.ownerSVGElement&&e.getBBox(),i=!Pu&&"border-box"===n.boxSizing,o=Ru.test(n.writingMode||""),a=!r&&Tu.test(n.overflowY||""),l=!r&&Tu.test(n.overflowX||""),s=r?0:Mu(n.paddingTop),c=r?0:Mu(n.paddingRight),d=r?0:Mu(n.paddingBottom),u=r?0:Mu(n.paddingLeft),p=r?0:Mu(n.borderTopWidth),h=r?0:Mu(n.borderRightWidth),f=r?0:Mu(n.borderBottomWidth),g=u+c,v=s+d,m=(r?0:Mu(n.borderLeftWidth))+h,x=p+f,b=l?e.offsetHeight-x-e.clientHeight:0,y=a?e.offsetWidth-m-e.clientWidth:0,C=i?g+m:0,w=i?v+x:0,$=r?r.width:Mu(n.width)-C-y,k=r?r.height:Mu(n.height)-w-b,S=$+g+y+m,E=k+v+b+x,O=wu({devicePixelContentBoxSize:Du(Math.round($*devicePixelRatio),Math.round(k*devicePixelRatio),o),borderBoxSize:Du(S,E,o),contentBoxSize:Du($,k,o),contentRect:new ku(u,s,$,k)});return _u.set(e,O),O},Vu=function(e,t,n){var r=ju(e,n),i=r.borderBoxSize,o=r.contentBoxSize,a=r.devicePixelContentBoxSize;switch(t){case su.DEVICE_PIXEL_CONTENT_BOX:return a;case su.BORDER_BOX:return i;default:return o}},Iu=function(e){var t=ju(e);this.target=e,this.contentRect=t.contentRect,this.borderBoxSize=wu([t.borderBoxSize]),this.contentBoxSize=wu([t.contentBoxSize]),this.devicePixelContentBoxSize=wu([t.devicePixelContentBoxSize])},zu=function(e){if(Eu(e))return 1/0;for(var t=0,n=e.parentNode;n;)t+=1,n=n.parentNode;return t},Au=function(){var e=1/0,t=[];bu.forEach((function(n){if(0!==n.activeTargets.length){var r=[];n.activeTargets.forEach((function(t){var n=new Iu(t.target),i=zu(t.target);r.push(n),t.lastReportedSize=Vu(t.target,t.observedBox),i<e&&(e=i)})),t.push((function(){n.callback.call(n.observer,r,n.observer)})),n.activeTargets.splice(0,n.activeTargets.length)}}));for(var n=0,r=t;n<r.length;n++){(0,r[n])()}return e},Hu=function(e){bu.forEach((function(t){t.activeTargets.splice(0,t.activeTargets.length),t.skippedTargets.splice(0,t.skippedTargets.length),t.observationTargets.forEach((function(n){n.isActive()&&(zu(n.target)>e?t.activeTargets.push(n):t.skippedTargets.push(n))}))}))},Bu=function(){var e=0;for(Hu(e);bu.some((function(e){return e.activeTargets.length>0}));)e=Au(),Hu(e);return bu.some((function(e){return e.skippedTargets.length>0}))&&function(){var e;"function"==typeof ErrorEvent?e=new ErrorEvent("error",{message:yu}):((e=document.createEvent("Event")).initEvent("error",!1,!1),e.message=yu),window.dispatchEvent(e)}(),e>0},Fu=[],Zu=function(e){if(!Cu){var t=0,n=document.createTextNode("");new MutationObserver((function(){return Fu.splice(0).forEach((function(e){return e()}))})).observe(n,{characterData:!0}),Cu=function(){n.textContent="".concat(t?t--:t++)}}Fu.push(e),Cu()},qu=0,Gu={attributes:!0,characterData:!0,childList:!0,subtree:!0},Wu=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],Uu=function(e){return void 0===e&&(e=0),Date.now()+e},Xu=!1,Yu=new(function(){function e(){var e=this;this.stopped=!0,this.listener=function(){return e.schedule()}}return e.prototype.run=function(e){var t=this;if(void 0===e&&(e=250),!Xu){Xu=!0;var n,r=Uu(e);n=function(){var n=!1;try{n=Bu()}finally{if(Xu=!1,e=r-Uu(),!qu)return;n?t.run(1e3):e>0?t.run(e):t.start()}},Zu((function(){requestAnimationFrame(n)}))}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var e=this,t=function(){return e.observer&&e.observer.observe(document.body,Gu)};document.body?t():Lu.addEventListener("DOMContentLoaded",t)},e.prototype.start=function(){var e=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),Wu.forEach((function(t){return Lu.addEventListener(t,e.listener,!0)})))},e.prototype.stop=function(){var e=this;this.stopped||(this.observer&&this.observer.disconnect(),Wu.forEach((function(t){return Lu.removeEventListener(t,e.listener,!0)})),this.stopped=!0)},e}()),Ku=function(e){!qu&&e>0&&Yu.start(),!(qu+=e)&&Yu.stop()},Ju=function(){function e(e,t){this.target=e,this.observedBox=t||su.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var e=Vu(this.target,this.observedBox,!0);return function(e){return!Su(e)&&!function(e){switch(e.tagName){case"INPUT":if("image"!==e.type)break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1}(e)&&"inline"===getComputedStyle(e).display}(this.target)&&(this.lastReportedSize=e),this.lastReportedSize.inlineSize!==e.inlineSize||this.lastReportedSize.blockSize!==e.blockSize},e}(),Qu=function(e,t){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=e,this.callback=t},ep=new WeakMap,tp=function(e,t){for(var n=0;n<e.length;n+=1)if(e[n].target===t)return n;return-1},np=function(){function e(){}return e.connect=function(e,t){var n=new Qu(e,t);ep.set(e,n)},e.observe=function(e,t,n){var r=ep.get(e),i=0===r.observationTargets.length;tp(r.observationTargets,t)<0&&(i&&bu.push(r),r.observationTargets.push(new Ju(t,n&&n.box)),Ku(1),Yu.schedule())},e.unobserve=function(e,t){var n=ep.get(e),r=tp(n.observationTargets,t),i=1===n.observationTargets.length;r>=0&&(i&&bu.splice(bu.indexOf(n),1),n.observationTargets.splice(r,1),Ku(-1))},e.disconnect=function(e){var t=this,n=ep.get(e);n.observationTargets.slice().forEach((function(n){return t.unobserve(e,n.target)})),n.activeTargets.splice(0,n.activeTargets.length)},e}(),rp=function(){function e(e){if(0===arguments.length)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if("function"!=typeof e)throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");np.connect(this,e)}return e.prototype.observe=function(e,t){if(0===arguments.length)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Ou(e))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");np.observe(this,e,t)},e.prototype.unobserve=function(e){if(0===arguments.length)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Ou(e))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");np.unobserve(this,e)},e.prototype.disconnect=function(){np.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e}();function ip(){return ip=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ip.apply(this,arguments)}function op(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)t.indexOf(n=o[r])>=0||(i[n]=e[n]);return i}var ap="undefined"!=typeof window?Q:U;function lp(e,t,n){return t=(t=+t)==t?t:0,n=(n=+n)==n?n:0,(e=+e)==e&&(e=(e=e<=n?e:n)>=t?e:t),e}function sp(e){var t=Math.round(e);if(Number.isNaN(e))throw new TypeError("Found a NaN! Check your snapPoints / defaultSnap / snapTo ");return t}var cp={box:"border-box"};function dp(e,t){var n=t.label,r=t.enabled,i=t.resizeSourceRef,o=W(0),a=o[0],l=o[1];re(n+": "+a);var s=ee((function(e){l(e[0].borderBoxSize[0].blockSize),i.current="element"}),[i]);return ap((function(){if(e.current&&r){var t=new rp(s);return t.observe(e.current,cp),function(){t.disconnect()}}}),[e,s,r]),r?a:0}function up(e){return void 0===e&&(e=1e3),new Promise((function(t){return setTimeout(t,e)}))}var pp={DRAG:{target:"#overlay.dragging",actions:"onOpenEnd"}},hp={RESIZE:{target:"#overlay.resizing",actions:"onOpenEnd"}},fp=function(e,t,n){return void 0===n&&(n=e.context),new xs(e,t,n)}({id:"overlay",initial:"closed",context:{initialState:"CLOSED"},states:{closed:{on:{OPEN:"opening",CLOSE:void 0}},opening:{initial:"start",states:{start:{invoke:{src:"onOpenStart",onDone:"transition"}},transition:{always:[{target:"immediately",cond:"initiallyOpen"},{target:"smoothly",cond:"initiallyClosed"}]},immediately:{initial:"open",states:{open:{invoke:{src:"openImmediately",onDone:"activating"}},activating:{invoke:{src:"activate",onDone:"#overlay.opening.end"},on:ip({},pp,hp)}}},smoothly:{initial:"visuallyHidden",states:{visuallyHidden:{invoke:{src:"renderVisuallyHidden",onDone:"activating"}},activating:{invoke:{src:"activate",onDone:"open"}},open:{invoke:{src:"openSmoothly",onDone:"#overlay.opening.end"},on:ip({},pp,hp)}}},end:{invoke:{src:"onOpenEnd",onDone:"done"},on:{CLOSE:"#overlay.closing",DRAG:"#overlay.dragging"}},done:{type:"final"}},on:ip({},{CLOSE:{target:"#overlay.closing",actions:"onOpenCancel"}}),onDone:"open"},open:{on:{DRAG:"#overlay.dragging",SNAP:"snapping",RESIZE:"resizing"}},dragging:{on:{SNAP:"snapping"}},snapping:{initial:"start",states:{start:{invoke:{src:"onSnapStart",onDone:"snappingSmoothly"},entry:[ys({y:function(e,t){return t.payload.y},velocity:function(e,t){return t.payload.velocity},snapSource:function(e,t){var n=t.payload.source;return void 0===n?"custom":n}})]},snappingSmoothly:{invoke:{src:"snapSmoothly",onDone:"end"}},end:{invoke:{src:"onSnapEnd",onDone:"done"},on:{RESIZE:"#overlay.resizing",SNAP:"#overlay.snapping",CLOSE:"#overlay.closing",DRAG:"#overlay.dragging"}},done:{type:"final"}},on:{SNAP:{target:"snapping",actions:"onSnapEnd"},RESIZE:{target:"#overlay.resizing",actions:"onSnapCancel"},DRAG:{target:"#overlay.dragging",actions:"onSnapCancel"},CLOSE:{target:"#overlay.closing",actions:"onSnapCancel"}},onDone:"open"},resizing:{initial:"start",states:{start:{invoke:{src:"onResizeStart",onDone:"resizingSmoothly"}},resizingSmoothly:{invoke:{src:"resizeSmoothly",onDone:"end"}},end:{invoke:{src:"onResizeEnd",onDone:"done"},on:{SNAP:"#overlay.snapping",CLOSE:"#overlay.closing",DRAG:"#overlay.dragging"}},done:{type:"final"}},on:{RESIZE:{target:"resizing",actions:"onResizeEnd"},SNAP:{target:"snapping",actions:"onResizeCancel"},DRAG:{target:"#overlay.dragging",actions:"onResizeCancel"},CLOSE:{target:"#overlay.closing",actions:"onResizeCancel"}},onDone:"open"},closing:{initial:"start",states:{start:{invoke:{src:"onCloseStart",onDone:"deactivating"},on:{OPEN:{target:"#overlay.open",actions:"onCloseCancel"}}},deactivating:{invoke:{src:"deactivate",onDone:"closingSmoothly"}},closingSmoothly:{invoke:{src:"closeSmoothly",onDone:"end"}},end:{invoke:{src:"onCloseEnd",onDone:"done"},on:{OPEN:{target:"#overlay.opening",actions:"onCloseCancel"}}},done:{type:"final"}},on:{CLOSE:void 0,OPEN:{target:"#overlay.opening",actions:"onCloseCancel"}},onDone:"closed"}},on:{CLOSE:"closing"}},{actions:{onOpenCancel:function(e,t){},onSnapCancel:function(e,t){},onResizeCancel:function(e,t){},onCloseCancel:function(e,t){},onOpenEnd:function(e,t){},onSnapEnd:function(e,t){},onRezizeEnd:function(e,t){}},services:{onSnapStart:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onOpenStart:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onCloseStart:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onResizeStart:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onSnapEnd:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onOpenEnd:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onCloseEnd:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},onResizeEnd:function(){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},renderVisuallyHidden:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},activate:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},deactivate:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},openSmoothly:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},openImmediately:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},snapSmoothly:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},resizeSmoothly:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}},closeSmoothly:function(e,t){try{return Promise.resolve(up()).then((function(){}))}catch(e){return Promise.reject(e)}}},guards:{initiallyClosed:function(e){return"CLOSED"===e.initialState},initiallyOpen:function(e){return"OPEN"===e.initialState}}}),gp=["children","sibling","className","footer","header","open","initialState","lastSnapRef","initialFocusRef","onDismiss","maxHeight","defaultSnap","snapPoints","blocking","scrollLocking","style","onSpringStart","onSpringCancel","onSpringEnd","reserveScrollBarGap","expandOnContentDrag"],vp=["velocity"],mp=["onRest","config"],xp={tension:170,friction:26},bp=xp.tension,yp=xp.friction,Cp=q.forwardRef((function(e,t){var n=e.children,r=e.sibling,i=e.className,o=e.footer,a=e.header,l=e.open,s=e.initialState,c=e.lastSnapRef,d=e.initialFocusRef,u=e.onDismiss,p=e.maxHeight,h=e.defaultSnap,f=void 0===h?$p:h,g=e.snapPoints,v=void 0===g?kp:g,m=e.blocking,x=void 0===m||m,b=e.scrollLocking,y=void 0===b||b,C=e.style,w=e.onSpringStart,$=e.onSpringCancel,k=e.onSpringEnd,S=e.reserveScrollBarGap,E=void 0===S?x:S,O=e.expandOnContentDrag,L=void 0!==O&&O,_=op(e,gp),T=function(){var e=W(!1),t=e[0],n=e[1],r=W({}),i=r[0],o=r[1],a=ee((function(e){return o((function(t){var n;return ip({},t,((n={})[e]=!1,n))})),function(){o((function(t){var n;return ip({},t,((n={})[e]=!0,n))}))}}),[]);return U((function(){var e=Object.values(i);0!==e.length&&e.every(Boolean)&&n(!0)}),[i]),{ready:t,registerReady:a}}(),R=T.ready,P=T.registerReady,M=J(!1),D=J(w),N=J($),j=J(k);U((function(){D.current=w,N.current=$,j.current=k}),[$,w,k]);var V,I,z=sc((function(){return{y:0,ready:0,maxHeight:0,minSnap:0,maxSnap:0}})),A=z[0],H=z[1],B=J(null),F=J(null),Z=J(null),G=J(null),X=J(null),Y=J(null),Q=J(0),te=J(),ie=J(!1),oe=(V=K((function(){return"undefined"!=typeof window?window.matchMedia("(prefers-reduced-motion: reduce)"):null}),[]),I=J(null==V?void 0:V.matches),re(I.current?"reduce":"no-preference"),U((function(){var e=function(e){I.current=e.matches};return null==V||V.addListener(e),function(){return null==V?void 0:V.removeListener(e)}}),[V]),I),ae=function(e){var t=e.targetRef,n=e.enabled,r=e.reserveScrollBarGap,i=J({activate:function(){throw new TypeError("Tried to activate scroll lock too early")},deactivate:function(){}});return re(n?"Enabled":"Disabled"),U((function(){if(!n)return i.current.deactivate(),void(i.current={activate:function(){},deactivate:function(){}});var e=t.current,o=!1;i.current={activate:function(){o||(o=!0,mu(e,{allowTouchMove:function(e){return e.closest("[data-body-scroll-lock-ignore]")},reserveScrollBarGap:r}))},deactivate:function(){o&&(o=!1,xu(e))}}}),[n,t,r]),i}({targetRef:F,enabled:R&&y,reserveScrollBarGap:E}),le=function(e){var t=e.targetRef,n=e.enabled,r=J({activate:function(){throw new TypeError("Tried to activate aria hider too early")},deactivate:function(){}});return re(n?"Enabled":"Disabled"),U((function(){if(!n)return r.current.deactivate(),void(r.current={activate:function(){},deactivate:function(){}});var e=t.current,i=!1,o=[],a=[];r.current={activate:function(){if(!i){i=!0;var t=e.parentNode;document.querySelectorAll("body > *").forEach((function(e){if(e!==t){var n=e.getAttribute("aria-hidden");null!==n&&"false"!==n||(o.push(n),a.push(e),e.setAttribute("aria-hidden","true"))}}))}},deactivate:function(){i&&(i=!1,a.forEach((function(e,t){var n=o[t];null===n?e.removeAttribute("aria-hidden"):e.setAttribute("aria-hidden",n)})),o=[],a=[])}}}),[t,n]),r}({targetRef:B,enabled:R&&x}),se=function(e){var t=e.targetRef,n=e.fallbackRef,r=e.initialFocusRef,i=e.enabled,o=J({activate:function(){throw new TypeError("Tried to activate focus trap too early")},deactivate:function(){}});return re(i?"Enabled":"Disabled"),U((function(){if(!i)return o.current.deactivate(),void(o.current={activate:function(){},deactivate:function(){}});var e=n.current,a=ou(t.current,{onActivate:void 0,initialFocus:r?function(){return(null==r?void 0:r.current)||e}:void 0,fallbackFocus:e,escapeDeactivates:!1,clickOutsideDeactivates:!1}),l=!1;o.current={activate:function(){try{return l?Promise.resolve():(l=!0,Promise.resolve(a.activate()).then((function(){return Promise.resolve(new Promise((function(e){return setTimeout((function(){return e(void 0)}),0)}))).then((function(){}))})))}catch(e){return Promise.reject(e)}},deactivate:function(){l&&(l=!1,a.deactivate())}}}),[i,n,r,t]),o}({targetRef:B,fallbackRef:Y,initialFocusRef:d||void 0,enabled:R&&x&&!1!==d}),ce=function(e){var t=e.getSnapPoints,n=e.heightRef,r=e.lastSnapRef,i=e.ready,o=function(e){var t=e.contentRef,n=e.controlledMaxHeight,r=e.footerEnabled,i=e.footerRef,o=e.headerEnabled,a=e.headerRef,l=e.registerReady,s=e.resizeSourceRef,c=K((function(){return l("contentHeight")}),[l]),d=function(e,t,n){var r=K((function(){return t("maxHeight")}),[t]),i=W((function(){return sp(e)||"undefined"!=typeof window?window.innerHeight:0})),o=i[0],a=i[1],l=o>0,s=J(0);return re(e?"controlled":"auto"),U((function(){l&&r()}),[l,r]),ap((function(){if(e)return a(sp(e)),void(n.current="maxheightprop");var t=function(){s.current||(s.current=requestAnimationFrame((function(){a(window.innerHeight),n.current="window",s.current=0})))};return window.addEventListener("resize",t),a(window.innerHeight),n.current="window",r(),function(){window.removeEventListener("resize",t),cancelAnimationFrame(s.current)}}),[e,r,n]),o}(n,l,s),u=dp(a,{label:"headerHeight",enabled:o,resizeSourceRef:s}),p=dp(t,{label:"contentHeight",enabled:!0,resizeSourceRef:s}),h=dp(i,{label:"footerHeight",enabled:r,resizeSourceRef:s}),f=Math.min(d-u-h,p)+u+h;re("minHeight: "+f);var g=p>0;return U((function(){g&&c()}),[g,c]),{maxHeight:d,minHeight:f,headerHeight:u,footerHeight:h}}({contentRef:e.contentRef,controlledMaxHeight:e.controlledMaxHeight,footerEnabled:e.footerEnabled,footerRef:e.footerRef,headerEnabled:e.headerEnabled,headerRef:e.headerRef,registerReady:e.registerReady,resizeSourceRef:e.resizeSourceRef}),a=o.maxHeight,l=o.minHeight,s=o.headerHeight,c=o.footerHeight,d=function(e,t){var n=[].concat(e).map(sp).reduce((function(e,n){return e.add(lp(n,0,t)),e}),new Set),r=Array.from(n),i=Math.min.apply(Math,r);if(Number.isNaN(i))throw new TypeError("minSnap is NaN");var o=Math.max.apply(Math,r);if(Number.isNaN(o))throw new TypeError("maxSnap is NaN");return{snapPoints:r,minSnap:i,maxSnap:o}}(i?t({height:n.current,footerHeight:c,headerHeight:s,minHeight:l,maxHeight:a}):[0],a),u=d.snapPoints,p=d.minSnap,h=d.maxSnap;return re("minSnap: "+p+", maxSnap:"+h),{minSnap:p,maxSnap:h,findSnap:function(e){var t=sp("function"==typeof e?e({footerHeight:c,headerHeight:s,height:n.current,minHeight:l,maxHeight:a,snapPoints:u,lastSnap:r.current}):e);return u.reduce((function(e,n){return Math.abs(n-t)<Math.abs(e-t)?n:e}),p)},maxHeight:a}}({contentRef:Z,controlledMaxHeight:p,footerEnabled:!!o,footerRef:X,getSnapPoints:v,headerEnabled:!1!==a,headerRef:G,heightRef:Q,lastSnapRef:c,ready:R,registerReady:P,resizeSourceRef:te}),de=ce.minSnap,ue=ce.maxSnap,pe=ce.maxHeight,he=ce.findSnap,fe=J(pe),ge=J(de),ve=J(ue),me=J(he),xe=J(0);ap((function(){fe.current=pe,ve.current=ue,ge.current=de,me.current=he,xe.current=he(f)}),[he,f,pe,ue,de]);var be=ee((function(e){var t=e.onRest,n=e.config,r=(n=void 0===n?{}:n).velocity,i=void 0===r?1:r,o=op(n,vp),a=op(e,mp);return new Promise((function(e){return H(ip({},a,{config:ip({velocity:i},o,{mass:1,tension:bp,friction:Math.max(yp,yp+(yp-yp*i))}),onRest:function(){var n=[].slice.call(arguments);e.apply(void 0,n),null==t||t.apply(void 0,n)}}))}))}),[H]),ye=Ms(fp,{devTools:!1,actions:{onOpenCancel:ee((function(){return null==N.current?void 0:N.current({type:"OPEN"})}),[]),onSnapCancel:ee((function(e){return null==N.current?void 0:N.current({type:"SNAP",source:e.snapSource})}),[]),onCloseCancel:ee((function(){return null==N.current?void 0:N.current({type:"CLOSE"})}),[]),onResizeCancel:ee((function(){return null==N.current?void 0:N.current({type:"RESIZE",source:te.current})}),[]),onOpenEnd:ee((function(){return null==j.current?void 0:j.current({type:"OPEN"})}),[]),onSnapEnd:ee((function(e,t){return null==j.current?void 0:j.current({type:"SNAP",source:e.snapSource})}),[]),onResizeEnd:ee((function(){return null==j.current?void 0:j.current({type:"RESIZE",source:te.current})}),[])},context:{initialState:s},services:{onSnapStart:ee((function(e,t){try{return Promise.resolve(null==D.current?void 0:D.current({type:"SNAP",source:t.payload.source||"custom"}))}catch(e){return Promise.reject(e)}}),[]),onOpenStart:ee((function(){try{return Promise.resolve(null==D.current?void 0:D.current({type:"OPEN"}))}catch(e){return Promise.reject(e)}}),[]),onCloseStart:ee((function(){try{return Promise.resolve(null==D.current?void 0:D.current({type:"CLOSE"}))}catch(e){return Promise.reject(e)}}),[]),onResizeStart:ee((function(){try{return Promise.resolve(null==D.current?void 0:D.current({type:"RESIZE",source:te.current}))}catch(e){return Promise.reject(e)}}),[]),onSnapEnd:ee((function(e,t){try{return Promise.resolve(null==j.current?void 0:j.current({type:"SNAP",source:e.snapSource}))}catch(e){return Promise.reject(e)}}),[]),onOpenEnd:ee((function(){try{return Promise.resolve(null==j.current?void 0:j.current({type:"OPEN"}))}catch(e){return Promise.reject(e)}}),[]),onCloseEnd:ee((function(){try{return Promise.resolve(null==j.current?void 0:j.current({type:"CLOSE"}))}catch(e){return Promise.reject(e)}}),[]),onResizeEnd:ee((function(){try{return Promise.resolve(null==j.current?void 0:j.current({type:"RESIZE",source:te.current}))}catch(e){return Promise.reject(e)}}),[]),renderVisuallyHidden:ee((function(e,t){try{return Promise.resolve(be({y:xe.current,ready:0,maxHeight:fe.current,maxSnap:ve.current,minSnap:xe.current,immediate:!0})).then((function(){}))}catch(e){return Promise.reject(e)}}),[be]),activate:ee((function(e,t){try{return M.current=!0,Promise.resolve(Promise.all([ae.current.activate(),se.current.activate(),le.current.activate()])).then((function(){}))}catch(e){return Promise.reject(e)}}),[le,se,ae]),deactivate:ee((function(){try{return ae.current.deactivate(),se.current.deactivate(),le.current.deactivate(),M.current=!1,Promise.resolve()}catch(e){return Promise.reject(e)}}),[le,se,ae]),openImmediately:ee((function(){try{return Q.current=xe.current,Promise.resolve(be({y:xe.current,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:xe.current,immediate:!0})).then((function(){}))}catch(e){return Promise.reject(e)}}),[be]),openSmoothly:ee((function(){try{return Promise.resolve(be({y:0,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:xe.current,immediate:!0})).then((function(){return Q.current=xe.current,Promise.resolve(be({y:xe.current,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:xe.current,immediate:oe.current})).then((function(){}))}))}catch(e){return Promise.reject(e)}}),[be,oe]),snapSmoothly:ee((function(e,t){try{var n=me.current(e.y);return Q.current=n,c.current=n,Promise.resolve(be({y:n,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:ge.current,immediate:oe.current,config:{velocity:e.velocity}})).then((function(){}))}catch(e){return Promise.reject(e)}}),[be,c,oe]),resizeSmoothly:ee((function(){try{var e=me.current(Q.current);return Q.current=e,c.current=e,Promise.resolve(be({y:e,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:ge.current,immediate:"element"!==te.current||oe.current})).then((function(){}))}catch(e){return Promise.reject(e)}}),[be,c,oe]),closeSmoothly:ee((function(e,t){try{return be({minSnap:Q.current,immediate:!0}),Q.current=0,Promise.resolve(be({y:0,maxHeight:fe.current,maxSnap:ve.current,immediate:oe.current})).then((function(){return Promise.resolve(be({ready:0,immediate:!0})).then((function(){}))}))}catch(e){return Promise.reject(e)}}),[be,oe])}}),Ce=ye[0],we=ye[1];U((function(){R&&we(l?"OPEN":"CLOSE")}),[l,we,R]),ap((function(){(pe||ue||de)&&we("RESIZE")}),[pe,ue,de,we]),U((function(){return function(){ae.current.deactivate(),se.current.deactivate(),le.current.deactivate()}}),[le,se,ae]),ne(t,(function(){return{snapTo:function(e,t){var n=void 0===t?{}:t,r=n.velocity,i=void 0===r?1:r,o=n.source,a=void 0===o?"custom":o;we("SNAP",{payload:{y:me.current(e),velocity:i,source:a}})},get height(){return Q.current}}}),[we]),U((function(){var e=F.current,t=function(e){ie.current&&e.preventDefault()},n=function(t){e.scrollTop<0&&(requestAnimationFrame((function(){e.style.overflow="hidden",e.scrollTop=0,e.style.removeProperty("overflow")})),t.preventDefault())};return L&&(e.addEventListener("scroll",t),e.addEventListener("touchmove",t),e.addEventListener("touchstart",n)),function(){e.removeEventListener("scroll",t),e.removeEventListener("touchmove",t),e.removeEventListener("touchstart",n)}}),[L,F]);var $e=_d((function(e){var t=e.args,n=(t=void 0===t?[]:t)[0],r=(n=void 0===n?{}:n).closeOnTap,i=void 0!==r&&r,o=n.isContentDragging,a=void 0!==o&&o,l=e.cancel,s=e.direction[1],c=e.down,d=e.first,p=e.last,h=e.memo,f=void 0===h?A.y.getValue():h,g=e.tap,v=e.velocity,m=-1*e.movement[1];if(!M.current)return l(),f;if(u&&i&&g)return l(),setTimeout((function(){return u()}),0),f;if(g)return f;var x=f+m,b=m*v,y=Math.max(ge.current,Math.min(ve.current,x+2*b));if(!c&&u&&s>0&&x+b<ge.current/2)return l(),u(),f;var C=c?u||ge.current!==ve.current?Zc(x,u?0:ge.current,ve.current,.55):x<ge.current?Zc(x,ge.current,2*ve.current,.55):Zc(x,ge.current/2,ve.current,.55):y;return L&&a?(C>=ve.current&&(C=ve.current),f===ve.current&&F.current.scrollTop>0&&(C=ve.current),ie.current=C<ve.current):ie.current=!1,d&&we("DRAG"),p?(we("SNAP",{payload:{y:C,velocity:v>.05?v:1,source:"dragging"}}),f):(H({y:C,ready:1,maxHeight:fe.current,maxSnap:ve.current,minSnap:ge.current,immediate:!0,config:{velocity:v}}),f)}),{filterTaps:!0});if(Number.isNaN(ve.current))throw new TypeError("maxSnapRef is NaN!!");if(Number.isNaN(ge.current))throw new TypeError("minSnapRef is NaN!!");var ke=function(e){var t,n=e.spring,r=nc([n.y,n.maxHeight],(function(e,t){return Math.round(lp(t-e,0,16))+"px"})),i=nc([n.y,n.minSnap,n.maxSnap],(function(e,t,n){return lp(e,t,n)+"px"})),o=nc([n.y,n.minSnap,n.maxSnap],(function(e,t,n){return e<t?t-e+"px":e>n?n-e+"px":"0px"})),a=nc([n.y,n.maxSnap],(function(e,t){return e>=t?Math.ceil(e-t):0})),l=nc([n.y,n.minSnap],(function(e,t){if(!t)return 0;var n=Math.max(t/2-45,0);return lp((e-n)*(1/(Math.min(t/2+45,t)-n)+0),0,1)})),s=nc([n.y,n.minSnap],(function(e,t){return t?lp(e/t,0,1):0}));return(t={})["--rsbs-content-opacity"]=l,t["--rsbs-backdrop-opacity"]=s,t["--rsbs-antigap-scale-y"]=a,t["--rsbs-overlay-translate-y"]=o,t["--rsbs-overlay-rounded"]=r,t["--rsbs-overlay-h"]=i,t}({spring:A});return q.createElement(Ic.div,ip({},_,{"data-rsbs-root":!0,"data-rsbs-state":wp.find(Ce.matches),"data-rsbs-is-blocking":x,"data-rsbs-is-dismissable":!!u,"data-rsbs-has-header":!!a,"data-rsbs-has-footer":!!o,className:i,ref:B,style:ip({},ke,C,{opacity:A.ready})}),r,x&&q.createElement("div",ip({key:"backdrop","data-rsbs-backdrop":!0},$e({closeOnTap:!0}))),q.createElement("div",{key:"overlay","aria-modal":"true",role:"dialog","data-rsbs-overlay":!0,tabIndex:-1,ref:Y,onKeyDown:function(e){"Escape"===e.key&&(e.stopPropagation(),u&&u())}},!1!==a&&q.createElement("div",ip({key:"header","data-rsbs-header":!0,ref:G},$e()),a),q.createElement("div",ip({key:"scroll","data-rsbs-scroll":!0,ref:F},L?$e({isContentDragging:!0}):{}),q.createElement("div",{"data-rsbs-content":!0,ref:Z},n)),o&&q.createElement("div",ip({key:"footer",ref:X,"data-rsbs-footer":!0},$e()),o)))})),wp=["closed","opening","open","closing","dragging","snapping","resizing"];function $p(e){var t=e.lastSnap;return null!=t?t:Math.min.apply(Math,e.snapPoints)}function kp(e){return e.minHeight}var Sp=["onSpringStart","onSpringEnd","skipInitialTransition"],Ep=G((function(e,t){var n=e.onSpringStart,r=e.onSpringEnd,i=e.skipInitialTransition,o=op(e,Sp),a=W(!1),l=a[0],s=a[1],c=J(),d=J(null),u=J(i&&o.open?"OPEN":"CLOSED");ap((function(){if(o.open)return cancelAnimationFrame(c.current),s(!0),function(){u.current="CLOSED"}}),[o.open]);var p=ee((function(e){return Promise.resolve(null==n?void 0:n(e)).then((function(){"OPEN"===e.type&&cancelAnimationFrame(c.current)}))}),[n]),h=ee((function(e){return Promise.resolve(null==r?void 0:r(e)).then((function(){"CLOSE"===e.type&&(c.current=requestAnimationFrame((function(){return s(!1)})))}))}),[r]);return l?q.createElement(wa,{"data-rsbs-portal":!0},q.createElement(Cp,ip({},o,{lastSnapRef:d,ref:t,initialState:u.current,onSpringStart:p,onSpringEnd:h}))):null}));const Op=(e,t)=>oe`
2347
2347
  [data-rsbs-overlay] {
2348
2348
  border-top-left-radius: 16px;
2349
2349
  border-top-right-radius: 16px;
@@ -2842,7 +2842,7 @@ function Yd(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Obj
2842
2842
  button {
2843
2843
  width: calc(48% - 24px);
2844
2844
  }
2845
- `,dh=({navigationSection:e,utilitySection:t,actionsSection:n,linkRouter:r,isOpen:i,setIsOpen:o,pathname:a})=>{const[l,s]=W(void 0),[c,d]=W(-1),u=K(null),p=K([]),h=r;return H(F,{children:[B("div",{css:eh(i),children:i&&H("div",{css:th,children:[H("div",{style:{overflowY:"scroll",width:"100%",height:"100%",paddingBottom:"72px"},children:[t?B("div",{css:nh,children:t?.map((e=>B("div",{className:"ds-utility-item",children:e})))}):null,e?B("div",{css:rh,children:e.map(((e,t)=>e.link?B(h,{to:e.link,href:e.link,onClick:()=>{s(void 0),d(-1),o(!1)},css:oh(a===e.link),children:e.label},e.label):H("button",{css:ah,type:"button",ref:e=>p.current[t]=e,onClick:()=>{e.items&&(s(e),d(t),setTimeout((()=>{u.current?.focus()}),100))},children:[e.label,e.items?B(Ee,{rotate:"270",color:"var(--chakra-colors-neutral-700)"}):null]},e.label)))}):null]}),n?B("div",{css:ch,children:n.map((e=>B(ye,{label:e.label,onClick:()=>{e?.onClick?.(),s(void 0),d(-1),o(!1)}},e.label)))}):null]})}),B("div",{css:lh(!!l?.items),children:l?.items?H(F,{children:[H("div",{css:sh,children:[H("button",{type:"button",onClick:()=>{s(void 0),d(-1),p.current[c]?.focus()},"aria-label":"Go back",css:Qp,ref:u,children:[B(Ee,{rotate:"90",color:"var(--chakra-colors-neutral-700)"}),l?.label]}),H("button",{type:"button",onClick:()=>{s(void 0),d(-1),o(!1)},"aria-label":"Close menu",css:Qp,children:["Close",B(_e,{height:"16px",width:"16px"})]})]}),B("div",{css:ih,children:l?.items?.map((e=>B(h,{to:e.link,href:e.link,css:oh(),onClick:()=>{s(void 0),d(-1),o(!1)},children:e.label},e.label)))})]}):null})]})},uh=1023,ph=({logo:e,linkRouter:t,pathname:n,navigationSection:r,utilitySection:i,actionsSection:o,maxWidth:a,fixed:l,onNavbarHeightChange:s})=>{const c=K(null),d=K(null),u=K(null),[p,h]=W(!1),[f,g]=W(-1),[v,m]=W("undefined"!=typeof window&&window?.innerWidth<=uh),[x,b]=W(!1),y=t,C=Q((()=>{if(d.current&&c.current&&u.current){const e=c.current.getBoundingClientRect(),t=d.current.getBoundingClientRect(),n=u.current.getBoundingClientRect();t.width,e.width,window.innerWidth<=uh||window.innerWidth<=f?(s?.(96),h(!0)):window.innerWidth>uh&&window.innerWidth<=1440?e.right>=t.left?(s?.(96),h(!0),g(window.innerWidth)):window.innerWidth>f&&(s?.(48),h(!1),g(-1)):(s?.(48),h(!1),g(-1)),p&&(window.innerWidth<=uh||n.right>=t.left?(m(!0),s?.(48)):(m(!1),s?.(96)))}}),[f,p]);return U((()=>(C(),window.addEventListener("resize",C),()=>{window.removeEventListener("resize",C)})),[C]),H("nav",{css:Zp(p&&!v,l),children:[H("div",{css:Gp(p&&!v,a),children:[H("div",{css:(w=p&&!v,oe`
2845
+ `,dh=({navigationSection:e,utilitySection:t,actionsSection:n,linkRouter:r,isOpen:i,setIsOpen:o,pathname:a})=>{const[l,s]=W(void 0),[c,d]=W(-1),u=J(null),p=J([]),h=r;return H(F,{children:[B("div",{css:eh(i),children:i&&H("div",{css:th,children:[H("div",{style:{overflowY:"scroll",width:"100%",height:"100%",paddingBottom:"72px"},children:[t?B("div",{css:nh,children:t?.map((e=>B("div",{className:"ds-utility-item",children:e})))}):null,e?B("div",{css:rh,children:e.map(((e,t)=>e.link?B(h,{to:e.link,href:e.link,onClick:()=>{s(void 0),d(-1),o(!1)},css:oh(a===e.link),children:e.label},e.label):H("button",{css:ah,type:"button",ref:e=>p.current[t]=e,onClick:()=>{e.items&&(s(e),d(t),setTimeout((()=>{u.current?.focus()}),100))},children:[e.label,e.items?B(Ee,{rotate:"270",color:"var(--chakra-colors-neutral-700)"}):null]},e.label)))}):null]}),n?B("div",{css:ch,children:n.map((e=>B(ye,{label:e.label,onClick:()=>{e?.onClick?.(),s(void 0),d(-1),o(!1)}},e.label)))}):null]})}),B("div",{css:lh(!!l?.items),children:l?.items?H(F,{children:[H("div",{css:sh,children:[H("button",{type:"button",onClick:()=>{s(void 0),d(-1),p.current[c]?.focus()},"aria-label":"Go back",css:Qp,ref:u,children:[B(Ee,{rotate:"90",color:"var(--chakra-colors-neutral-700)"}),l?.label]}),H("button",{type:"button",onClick:()=>{s(void 0),d(-1),o(!1)},"aria-label":"Close menu",css:Qp,children:["Close",B(_e,{height:"16px",width:"16px"})]})]}),B("div",{css:ih,children:l?.items?.map((e=>B(h,{to:e.link,href:e.link,css:oh(),onClick:()=>{s(void 0),d(-1),o(!1)},children:e.label},e.label)))})]}):null})]})},uh=1023,ph=({logo:e,linkRouter:t,pathname:n,navigationSection:r,utilitySection:i,actionsSection:o,maxWidth:a,fixed:l,onNavbarHeightChange:s})=>{const c=J(null),d=J(null),u=J(null),[p,h]=W(!1),[f,g]=W(-1),[v,m]=W("undefined"!=typeof window&&window?.innerWidth<=uh),[x,b]=W(!1),y=t,C=ee((()=>{if(d.current&&c.current&&u.current){const e=c.current.getBoundingClientRect(),t=d.current.getBoundingClientRect(),n=u.current.getBoundingClientRect();t.width,e.width,window.innerWidth<=uh||window.innerWidth<=f?(s?.(96),h(!0)):window.innerWidth>uh&&window.innerWidth<=1440?e.right>=t.left?(s?.(96),h(!0),g(window.innerWidth)):window.innerWidth>f&&(s?.(48),h(!1),g(-1)):(s?.(48),h(!1),g(-1)),p&&(window.innerWidth<=uh||n.right>=t.left?(m(!0),s?.(48)):(m(!1),s?.(96)))}}),[f,p]);return U((()=>(C(),window.addEventListener("resize",C),()=>{window.removeEventListener("resize",C)})),[C]),H("nav",{css:Zp(p&&!v,l),children:[H("div",{css:Gp(p&&!v,a),children:[H("div",{css:(w=p&&!v,oe`
2846
2846
  display: flex;
2847
2847
  align-items: center;
2848
2848
  justify-content: flex-start;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@worldresources/wri-design-systems",
3
- "version": "2.143.0",
3
+ "version": "2.143.1",
4
4
  "description": "WRI UI Library",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",