@medipha/chat 1.0.57 → 1.0.58

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 CHANGED
@@ -55,7 +55,7 @@ Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});var e=Object.
55
55
  `,ce=e=>{let{csp:t,prefixCls:n,layer:r,zeroRuntime:i}=(0,u.useContext)(x),a=se;n&&(a=a.replace(/anticon/g,n)),r&&(a=`@layer ${r} {\n${a}\n}`),(0,u.useEffect)(()=>{if(i)return;let n=e.current,o=ee(n);L(a,`@ant-design-icons`,{prepend:!r,csp:t,attachTo:o})},[])},le=e=>{let{icon:t,className:n,onClick:r,style:i,primaryColor:a,secondaryColor:o,...s}=e,c=u.useRef(null);if(ce(c),re(ie(t),`icon should be icon definiton, but got ${t}`),!ie(t))return null;let l=t;return oe(l.icon,`svg-${l.name}`,{className:n,onClick:r,style:i,"data-icon":l.name,width:`1em`,height:`1em`,fill:`currentColor`,"aria-hidden":`true`,...s,ref:c})};le.displayName=`IconReact`;function ue(){return ue=Object.assign?Object.assign.bind():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},ue.apply(this,arguments)}var B=u.forwardRef((e,t)=>{let{className:n,icon:r,spin:i,rotate:a,tabIndex:o,onClick:s,twoToneColor:c,...l}=e,{prefixCls:d=`anticon`,rootClassName:f}=u.useContext(x),p=C(f,d,{[`${d}-${r.name}`]:!!r.name,[`${d}-spin`]:!!i||r.name===`loading`},n),m=o;m===void 0&&s&&(m=-1);let h=a?{msTransform:`rotate(${a}deg)`,transform:`rotate(${a}deg)`}:void 0;return u.createElement(`span`,ue({role:`img`,"aria-label":r.name},l,{ref:t,tabIndex:m,onClick:s,className:p}),u.createElement(le,{icon:r,style:h}))});process.env.NODE_ENV!==`production`&&(B.displayName=`AntdIcon`);var de=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M862 465.3h-81c-4.6 0-9 2-12.1 5.5L550 723.1V160c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v563.1L255.1 470.8c-3-3.5-7.4-5.5-12.1-5.5h-81c-6.8 0-10.5 8.1-6 13.2L487.9 861a31.96 31.96 0 0048.3 0L868 478.5c4.5-5.2.8-13.2-6-13.2z`}}]},name:`arrow-down`,theme:`outlined`}}))());function fe(){return fe=Object.assign?Object.assign.bind():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},fe.apply(this,arguments)}var pe=u.forwardRef((e,t)=>u.createElement(B,fe({},e,{ref:t,icon:de.default})));process.env.NODE_ENV!==`production`&&(pe.displayName=`ArrowDownOutlined`);var me=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M816 768h-24V428c0-141.1-104.3-257.7-240-277.1V112c0-22.1-17.9-40-40-40s-40 17.9-40 40v38.9c-135.7 19.4-240 136-240 277.1v340h-24c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h216c0 61.8 50.2 112 112 112s112-50.2 112-112h216c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM512 888c-26.5 0-48-21.5-48-48h96c0 26.5-21.5 48-48 48zM304 768V428c0-55.6 21.6-107.8 60.9-147.1S456.4 220 512 220c55.6 0 107.8 21.6 147.1 60.9S720 372.4 720 428v340H304z`}}]},name:`bell`,theme:`outlined`}}))());function he(){return he=Object.assign?Object.assign.bind():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},he.apply(this,arguments)}var ge=u.forwardRef((e,t)=>u.createElement(B,he({},e,{ref:t,icon:me.default})));process.env.NODE_ENV!==`production`&&(ge.displayName=`BellOutlined`);var _e=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M697.8 481.4c33.6-35 54.2-82.3 54.2-134.3v-10.2C752 229.3 663.9 142 555.3 142H259.4c-15.1 0-27.4 12.3-27.4 27.4v679.1c0 16.3 13.2 29.5 29.5 29.5h318.7c117 0 211.8-94.2 211.8-210.5v-11c0-73-37.4-137.3-94.2-175.1zM328 238h224.7c57.1 0 103.3 44.4 103.3 99.3v9.5c0 54.8-46.3 99.3-103.3 99.3H328V238zm366.6 429.4c0 62.9-51.7 113.9-115.5 113.9H328V542.7h251.1c63.8 0 115.5 51 115.5 113.9v10.8z`}}]},name:`bold`,theme:`outlined`}}))());function ve(){return ve=Object.assign?Object.assign.bind():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},ve.apply(this,arguments)}var ye=u.forwardRef((e,t)=>u.createElement(B,ve({},e,{ref:t,icon:_e.default})));process.env.NODE_ENV!==`production`&&(ye.displayName=`BoldOutlined`);var be=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M880 184H712v-64c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v64H384v-64c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v64H144c-17.7 0-32 14.3-32 32v664c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V216c0-17.7-14.3-32-32-32zm-40 656H184V460h656v380zM184 392V256h128v48c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8v-48h256v48c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8v-48h128v136H184z`}}]},name:`calendar`,theme:`outlined`}}))());function xe(){return xe=Object.assign?Object.assign.bind():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},xe.apply(this,arguments)}var Se=u.forwardRef((e,t)=>u.createElement(B,xe({},e,{ref:t,icon:be.default})));process.env.NODE_ENV!==`production`&&(Se.displayName=`CalendarOutlined`);var Ce=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M864 248H728l-32.4-90.8a32.07 32.07 0 00-30.2-21.2H358.6c-13.5 0-25.6 8.5-30.1 21.2L296 248H160c-44.2 0-80 35.8-80 80v456c0 44.2 35.8 80 80 80h704c44.2 0 80-35.8 80-80V328c0-44.2-35.8-80-80-80zm8 536c0 4.4-3.6 8-8 8H160c-4.4 0-8-3.6-8-8V328c0-4.4 3.6-8 8-8h186.7l17.1-47.8 22.9-64.2h250.5l22.9 64.2 17.1 47.8H864c4.4 0 8 3.6 8 8v456zM512 384c-88.4 0-160 71.6-160 160s71.6 160 160 160 160-71.6 160-160-71.6-160-160-160zm0 256c-53 0-96-43-96-96s43-96 96-96 96 43 96 96-43 96-96 96z`}}]},name:`camera`,theme:`outlined`}}))());function we(){return we=Object.assign?Object.assign.bind():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},we.apply(this,arguments)}var Te=u.forwardRef((e,t)=>u.createElement(B,we({},e,{ref:t,icon:Ce.default})));process.env.NODE_ENV!==`production`&&(Te.displayName=`CameraOutlined`);var Ee=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`0 0 1024 1024`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M715.8 493.5L335 165.1c-14.2-12.2-35-1.2-35 18.5v656.8c0 19.7 20.8 30.7 35 18.5l380.8-328.4c10.9-9.4 10.9-27.6 0-37z`}}]},name:`caret-right`,theme:`filled`}}))());function De(){return De=Object.assign?Object.assign.bind():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},De.apply(this,arguments)}var Oe=u.forwardRef((e,t)=>u.createElement(B,De({},e,{ref:t,icon:Ee.default})));process.env.NODE_ENV!==`production`&&(Oe.displayName=`CaretRightFilled`);var ke=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z`}}]},name:`check-circle`,theme:`filled`}}))());function Ae(){return Ae=Object.assign?Object.assign.bind():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},Ae.apply(this,arguments)}var je=u.forwardRef((e,t)=>u.createElement(B,Ae({},e,{ref:t,icon:ke.default})));process.env.NODE_ENV!==`production`&&(je.displayName=`CheckCircleFilled`);var Me=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M699 353h-46.9c-10.2 0-19.9 4.9-25.9 13.3L469 584.3l-71.2-98.8c-6-8.3-15.6-13.3-25.9-13.3H325c-6.5 0-10.3 7.4-6.5 12.7l124.6 172.8a31.8 31.8 0 0051.7 0l210.6-292c3.9-5.3.1-12.7-6.4-12.7z`}},{tag:`path`,attrs:{d:`M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z`}}]},name:`check-circle`,theme:`outlined`}}))());function Ne(){return Ne=Object.assign?Object.assign.bind():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},Ne.apply(this,arguments)}var Pe=u.forwardRef((e,t)=>u.createElement(B,Ne({},e,{ref:t,icon:Me.default})));process.env.NODE_ENV!==`production`&&(Pe.displayName=`CheckCircleOutlined`);var Fe=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z`}}]},name:`check`,theme:`outlined`}}))());function Ie(){return Ie=Object.assign?Object.assign.bind():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},Ie.apply(this,arguments)}var Le=u.forwardRef((e,t)=>u.createElement(B,Ie({},e,{ref:t,icon:Fe.default})));process.env.NODE_ENV!==`production`&&(Le.displayName=`CheckOutlined`);var Re=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M899.1 869.6l-53-305.6H864c14.4 0 26-11.6 26-26V346c0-14.4-11.6-26-26-26H618V138c0-14.4-11.6-26-26-26H432c-14.4 0-26 11.6-26 26v182H160c-14.4 0-26 11.6-26 26v192c0 14.4 11.6 26 26 26h17.9l-53 305.6a25.95 25.95 0 0025.6 30.4h723c1.5 0 3-.1 4.4-.4a25.88 25.88 0 0021.2-30zM204 390h272V182h72v208h272v104H204V390zm468 440V674c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v156H416V674c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v156H202.8l45.1-260H776l45.1 260H672z`}}]},name:`clear`,theme:`outlined`}}))());function ze(){return ze=Object.assign?Object.assign.bind():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},ze.apply(this,arguments)}var Be=u.forwardRef((e,t)=>u.createElement(B,ze({},e,{ref:t,icon:Re.default})));process.env.NODE_ENV!==`production`&&(Be.displayName=`ClearOutlined`);var Ve=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z`}},{tag:`path`,attrs:{d:`M686.7 638.6L544.1 535.5V288c0-4.4-3.6-8-8-8H488c-4.4 0-8 3.6-8 8v275.4c0 2.6 1.2 5 3.3 6.5l165.4 120.6c3.6 2.6 8.6 1.8 11.2-1.7l28.6-39c2.6-3.7 1.8-8.7-1.8-11.2z`}}]},name:`clock-circle`,theme:`outlined`}}))());function He(){return He=Object.assign?Object.assign.bind():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},He.apply(this,arguments)}var Ue=u.forwardRef((e,t)=>u.createElement(B,He({},e,{ref:t,icon:Ve.default})));process.env.NODE_ENV!==`production`&&(Ue.displayName=`ClockCircleOutlined`);var We=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{"fill-rule":`evenodd`,viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z`}}]},name:`close-circle`,theme:`filled`}}))());function Ge(){return Ge=Object.assign?Object.assign.bind():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},Ge.apply(this,arguments)}var Ke=u.forwardRef((e,t)=>u.createElement(B,Ge({},e,{ref:t,icon:We.default})));process.env.NODE_ENV!==`production`&&(Ke.displayName=`CloseCircleFilled`);var qe=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{"fill-rule":`evenodd`,viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z`}}]},name:`close`,theme:`outlined`}}))());function Je(){return Je=Object.assign?Object.assign.bind():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},Je.apply(this,arguments)}var Ye=u.forwardRef((e,t)=>u.createElement(B,Je({},e,{ref:t,icon:qe.default})));process.env.NODE_ENV!==`production`&&(Ye.displayName=`CloseOutlined`);var Xe=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M326 664H104c-8.8 0-16 7.2-16 16v48c0 8.8 7.2 16 16 16h174v176c0 8.8 7.2 16 16 16h48c8.8 0 16-7.2 16-16V696c0-17.7-14.3-32-32-32zm16-576h-48c-8.8 0-16 7.2-16 16v176H104c-8.8 0-16 7.2-16 16v48c0 8.8 7.2 16 16 16h222c17.7 0 32-14.3 32-32V104c0-8.8-7.2-16-16-16zm578 576H698c-17.7 0-32 14.3-32 32v224c0 8.8 7.2 16 16 16h48c8.8 0 16-7.2 16-16V744h174c8.8 0 16-7.2 16-16v-48c0-8.8-7.2-16-16-16zm0-384H746V104c0-8.8-7.2-16-16-16h-48c-8.8 0-16 7.2-16 16v224c0 17.7 14.3 32 32 32h222c8.8 0 16-7.2 16-16v-48c0-8.8-7.2-16-16-16z`}}]},name:`compress`,theme:`outlined`}}))());function Ze(){return Ze=Object.assign?Object.assign.bind():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},Ze.apply(this,arguments)}var Qe=u.forwardRef((e,t)=>u.createElement(B,Ze({},e,{ref:t,icon:Xe.default})));process.env.NODE_ENV!==`production`&&(Qe.displayName=`CompressOutlined`);var $e=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M832 64H296c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h496v688c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8V96c0-17.7-14.3-32-32-32zM704 192H192c-17.7 0-32 14.3-32 32v530.7c0 8.5 3.4 16.6 9.4 22.6l173.3 173.3c2.2 2.2 4.7 4 7.4 5.5v1.9h4.2c3.5 1.3 7.2 2 11 2H704c17.7 0 32-14.3 32-32V224c0-17.7-14.3-32-32-32zM350 856.2L263.9 770H350v86.2zM664 888H414V746c0-22.1-17.9-40-40-40H232V264h432v624z`}}]},name:`copy`,theme:`outlined`}}))());function et(){return et=Object.assign?Object.assign.bind():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},et.apply(this,arguments)}var tt=u.forwardRef((e,t)=>u.createElement(B,et({},e,{ref:t,icon:$e.default})));process.env.NODE_ENV!==`production`&&(tt.displayName=`CopyOutlined`);var nt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z`}}]},name:`delete`,theme:`outlined`}}))());function rt(){return rt=Object.assign?Object.assign.bind():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},rt.apply(this,arguments)}var it=u.forwardRef((e,t)=>u.createElement(B,rt({},e,{ref:t,icon:nt.default})));process.env.NODE_ENV!==`production`&&(it.displayName=`DeleteOutlined`);var at=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M272.9 512l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L186.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H532c6.7 0 10.4-7.7 6.3-12.9L272.9 512zm304 0l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L490.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H836c6.7 0 10.4-7.7 6.3-12.9L576.9 512z`}}]},name:`double-left`,theme:`outlined`}}))());function ot(){return ot=Object.assign?Object.assign.bind():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},ot.apply(this,arguments)}var st=u.forwardRef((e,t)=>u.createElement(B,ot({},e,{ref:t,icon:at.default})));process.env.NODE_ENV!==`production`&&(st.displayName=`DoubleLeftOutlined`);var ct=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M533.2 492.3L277.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H188c-6.7 0-10.4 7.7-6.3 12.9L447.1 512 181.7 851.1A7.98 7.98 0 00188 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5zm304 0L581.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H492c-6.7 0-10.4 7.7-6.3 12.9L751.1 512 485.7 851.1A7.98 7.98 0 00492 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5z`}}]},name:`double-right`,theme:`outlined`}}))());function lt(){return lt=Object.assign?Object.assign.bind():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},lt.apply(this,arguments)}var ut=u.forwardRef((e,t)=>u.createElement(B,lt({},e,{ref:t,icon:ct.default})));process.env.NODE_ENV!==`production`&&(ut.displayName=`DoubleRightOutlined`);var dt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z`}}]},name:`down`,theme:`outlined`}}))());function ft(){return ft=Object.assign?Object.assign.bind():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},ft.apply(this,arguments)}var pt=u.forwardRef((e,t)=>u.createElement(B,ft({},e,{ref:t,icon:dt.default})));process.env.NODE_ENV!==`production`&&(pt.displayName=`DownOutlined`);var mt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M505.7 661a8 8 0 0012.6 0l112-141.7c4.1-5.2.4-12.9-6.3-12.9h-74.1V168c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v338.3H400c-6.7 0-10.4 7.7-6.3 12.9l112 141.8zM878 626h-60c-4.4 0-8 3.6-8 8v154H214V634c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v198c0 17.7 14.3 32 32 32h684c17.7 0 32-14.3 32-32V634c0-4.4-3.6-8-8-8z`}}]},name:`download`,theme:`outlined`}}))());function ht(){return ht=Object.assign?Object.assign.bind():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},ht.apply(this,arguments)}var gt=u.forwardRef((e,t)=>u.createElement(B,ht({},e,{ref:t,icon:mt.default})));process.env.NODE_ENV!==`production`&&(gt.displayName=`DownloadOutlined`);var _t=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M257.7 752c2 0 4-.2 6-.5L431.9 722c2-.4 3.9-1.3 5.3-2.8l423.9-423.9a9.96 9.96 0 000-14.1L694.9 114.9c-1.9-1.9-4.4-2.9-7.1-2.9s-5.2 1-7.1 2.9L256.8 538.8c-1.5 1.5-2.4 3.3-2.8 5.3l-29.5 168.2a33.5 33.5 0 009.4 29.8c6.6 6.4 14.9 9.9 23.8 9.9zm67.4-174.4L687.8 215l73.3 73.3-362.7 362.6-88.9 15.7 15.6-89zM880 836H144c-17.7 0-32 14.3-32 32v36c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-36c0-17.7-14.3-32-32-32z`}}]},name:`edit`,theme:`outlined`}}))());function vt(){return vt=Object.assign?Object.assign.bind():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},vt.apply(this,arguments)}var yt=u.forwardRef((e,t)=>u.createElement(B,vt({},e,{ref:t,icon:_t.default})));process.env.NODE_ENV!==`production`&&(yt.displayName=`EditOutlined`);var bt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M176 511a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0z`}}]},name:`ellipsis`,theme:`outlined`}}))());function xt(){return xt=Object.assign?Object.assign.bind():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},xt.apply(this,arguments)}var St=u.forwardRef((e,t)=>u.createElement(B,xt({},e,{ref:t,icon:bt.default})));process.env.NODE_ENV!==`production`&&(St.displayName=`EllipsisOutlined`);var Ct=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M855 160.1l-189.2 23.5c-6.6.8-9.3 8.8-4.7 13.5l54.7 54.7-153.5 153.5a8.03 8.03 0 000 11.3l45.1 45.1c3.1 3.1 8.2 3.1 11.3 0l153.6-153.6 54.7 54.7a7.94 7.94 0 0013.5-4.7L863.9 169a7.9 7.9 0 00-8.9-8.9zM416.6 562.3a8.03 8.03 0 00-11.3 0L251.8 715.9l-54.7-54.7a7.94 7.94 0 00-13.5 4.7L160.1 855c-.6 5.2 3.7 9.5 8.9 8.9l189.2-23.5c6.6-.8 9.3-8.8 4.7-13.5l-54.7-54.7 153.6-153.6c3.1-3.1 3.1-8.2 0-11.3l-45.2-45z`}}]},name:`expand-alt`,theme:`outlined`}}))());function wt(){return wt=Object.assign?Object.assign.bind():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},wt.apply(this,arguments)}var Tt=u.forwardRef((e,t)=>u.createElement(B,wt({},e,{ref:t,icon:Ct.default})));process.env.NODE_ENV!==`production`&&(Tt.displayName=`ExpandAltOutlined`);var Et=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M342 88H120c-17.7 0-32 14.3-32 32v224c0 8.8 7.2 16 16 16h48c8.8 0 16-7.2 16-16V168h174c8.8 0 16-7.2 16-16v-48c0-8.8-7.2-16-16-16zm578 576h-48c-8.8 0-16 7.2-16 16v176H682c-8.8 0-16 7.2-16 16v48c0 8.8 7.2 16 16 16h222c17.7 0 32-14.3 32-32V680c0-8.8-7.2-16-16-16zM342 856H168V680c0-8.8-7.2-16-16-16h-48c-8.8 0-16 7.2-16 16v224c0 17.7 14.3 32 32 32h222c8.8 0 16-7.2 16-16v-48c0-8.8-7.2-16-16-16zM904 88H682c-8.8 0-16 7.2-16 16v48c0 8.8 7.2 16 16 16h174v176c0 8.8 7.2 16 16 16h48c8.8 0 16-7.2 16-16V120c0-17.7-14.3-32-32-32z`}}]},name:`expand`,theme:`outlined`}}))());function Dt(){return Dt=Object.assign?Object.assign.bind():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},Dt.apply(this,arguments)}var Ot=u.forwardRef((e,t)=>u.createElement(B,Dt({},e,{ref:t,icon:Et.default})));process.env.NODE_ENV!==`production`&&(Ot.displayName=`ExpandOutlined`);var kt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{"fill-rule":`evenodd`,viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M880 912H144c-17.7 0-32-14.3-32-32V144c0-17.7 14.3-32 32-32h360c4.4 0 8 3.6 8 8v56c0 4.4-3.6 8-8 8H184v656h656V520c0-4.4 3.6-8 8-8h56c4.4 0 8 3.6 8 8v360c0 17.7-14.3 32-32 32zM770.87 199.13l-52.2-52.2a8.01 8.01 0 014.7-13.6l179.4-21c5.1-.6 9.5 3.7 8.9 8.9l-21 179.4c-.8 6.6-8.9 9.4-13.6 4.7l-52.4-52.4-256.2 256.2a8.03 8.03 0 01-11.3 0l-42.4-42.4a8.03 8.03 0 010-11.3l256.1-256.3z`}}]},name:`export`,theme:`outlined`}}))());function At(){return At=Object.assign?Object.assign.bind():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},At.apply(this,arguments)}var jt=u.forwardRef((e,t)=>u.createElement(B,At({},e,{ref:t,icon:kt.default})));process.env.NODE_ENV!==`production`&&(jt.displayName=`ExportOutlined`);var Mt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z`}}]},name:`eye`,theme:`outlined`}}))());function Nt(){return Nt=Object.assign?Object.assign.bind():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},Nt.apply(this,arguments)}var Pt=u.forwardRef((e,t)=>u.createElement(B,Nt({},e,{ref:t,icon:Mt.default})));process.env.NODE_ENV!==`production`&&(Pt.displayName=`EyeOutlined`);var Ft=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M904 816H120c-4.4 0-8 3.6-8 8v80c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-80c0-4.4-3.6-8-8-8zm-650.3-80h85c4.2 0 8-2.7 9.3-6.8l53.7-166h219.2l53.2 166c1.3 4 5 6.8 9.3 6.8h89.1c1.1 0 2.2-.2 3.2-.5a9.7 9.7 0 006-12.4L573.6 118.6a9.9 9.9 0 00-9.2-6.6H462.1c-4.2 0-7.9 2.6-9.2 6.6L244.5 723.1c-.4 1-.5 2.1-.5 3.2-.1 5.3 4.3 9.7 9.7 9.7zm255.9-516.1h4.1l83.8 263.8H424.9l84.7-263.8z`}}]},name:`font-colors`,theme:`outlined`}}))());function It(){return It=Object.assign?Object.assign.bind():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},It.apply(this,arguments)}var Lt=u.forwardRef((e,t)=>u.createElement(B,It({},e,{ref:t,icon:Ft.default})));process.env.NODE_ENV!==`production`&&(Lt.displayName=`FontColorsOutlined`);var Rt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M920 416H616c-4.4 0-8 3.6-8 8v112c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-56h60v320h-46c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h164c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8h-46V480h60v56c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V424c0-4.4-3.6-8-8-8zM656 296V168c0-4.4-3.6-8-8-8H104c-4.4 0-8 3.6-8 8v128c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8v-64h168v560h-92c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h264c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8h-92V232h168v64c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8z`}}]},name:`font-size`,theme:`outlined`}}))());function zt(){return zt=Object.assign?Object.assign.bind():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},zt.apply(this,arguments)}var Bt=u.forwardRef((e,t)=>u.createElement(B,zt({},e,{ref:t,icon:Rt.default})));process.env.NODE_ENV!==`production`&&(Bt.displayName=`FontSizeOutlined`);var Vt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`0 0 1024 1024`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M885.2 446.3l-.2-.8-112.2-285.1c-5-16.1-19.9-27.2-36.8-27.2H281.2c-17 0-32.1 11.3-36.9 27.6L139.4 443l-.3.7-.2.8c-1.3 4.9-1.7 9.9-1 14.8-.1 1.6-.2 3.2-.2 4.8V830a60.9 60.9 0 0060.8 60.8h627.2c33.5 0 60.8-27.3 60.9-60.8V464.1c0-1.3 0-2.6-.1-3.7.4-4.9 0-9.6-1.3-14.1zm-295.8-43l-.3 15.7c-.8 44.9-31.8 75.1-77.1 75.1-22.1 0-41.1-7.1-54.8-20.6S436 441.2 435.6 419l-.3-15.7H229.5L309 210h399.2l81.7 193.3H589.4zm-375 76.8h157.3c24.3 57.1 76 90.8 140.4 90.8 33.7 0 65-9.4 90.3-27.2 22.2-15.6 39.5-37.4 50.7-63.6h156.5V814H214.4V480.1z`}}]},name:`inbox`,theme:`outlined`}}))());function Ht(){return Ht=Object.assign?Object.assign.bind():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},Ht.apply(this,arguments)}var Ut=u.forwardRef((e,t)=>u.createElement(B,Ht({},e,{ref:t,icon:Vt.default})));process.env.NODE_ENV!==`production`&&(Ut.displayName=`InboxOutlined`);var Wt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z`}},{tag:`path`,attrs:{d:`M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z`}}]},name:`info-circle`,theme:`outlined`}}))());function Gt(){return Gt=Object.assign?Object.assign.bind():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},Gt.apply(this,arguments)}var Kt=u.forwardRef((e,t)=>u.createElement(B,Gt({},e,{ref:t,icon:Wt.default})));process.env.NODE_ENV!==`production`&&(Kt.displayName=`InfoCircleOutlined`);var qt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M798 160H366c-4.4 0-8 3.6-8 8v64c0 4.4 3.6 8 8 8h181.2l-156 544H229c-4.4 0-8 3.6-8 8v64c0 4.4 3.6 8 8 8h432c4.4 0 8-3.6 8-8v-64c0-4.4-3.6-8-8-8H474.4l156-544H798c4.4 0 8-3.6 8-8v-64c0-4.4-3.6-8-8-8z`}}]},name:`italic`,theme:`outlined`}}))());function Jt(){return Jt=Object.assign?Object.assign.bind():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},Jt.apply(this,arguments)}var Yt=u.forwardRef((e,t)=>u.createElement(B,Jt({},e,{ref:t,icon:qt.default})));process.env.NODE_ENV!==`production`&&(Yt.displayName=`ItalicOutlined`);var Xt=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z`}}]},name:`left`,theme:`outlined`}}))());function Zt(){return Zt=Object.assign?Object.assign.bind():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},Zt.apply(this,arguments)}var Qt=u.forwardRef((e,t)=>u.createElement(B,Zt({},e,{ref:t,icon:Xt.default})));process.env.NODE_ENV!==`production`&&(Qt.displayName=`LeftOutlined`);var $t=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M574 665.4a8.03 8.03 0 00-11.3 0L446.5 781.6c-53.8 53.8-144.6 59.5-204 0-59.5-59.5-53.8-150.2 0-204l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3l-39.8-39.8a8.03 8.03 0 00-11.3 0L191.4 526.5c-84.6 84.6-84.6 221.5 0 306s221.5 84.6 306 0l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3L574 665.4zm258.6-474c-84.6-84.6-221.5-84.6-306 0L410.3 307.6a8.03 8.03 0 000 11.3l39.7 39.7c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c53.8-53.8 144.6-59.5 204 0 59.5 59.5 53.8 150.2 0 204L665.3 562.6a8.03 8.03 0 000 11.3l39.8 39.8c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c84.5-84.6 84.5-221.5 0-306.1zM610.1 372.3a8.03 8.03 0 00-11.3 0L372.3 598.7a8.03 8.03 0 000 11.3l39.6 39.6c3.1 3.1 8.2 3.1 11.3 0l226.4-226.4c3.1-3.1 3.1-8.2 0-11.3l-39.5-39.6z`}}]},name:`link`,theme:`outlined`}}))());function en(){return en=Object.assign?Object.assign.bind():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},en.apply(this,arguments)}var tn=u.forwardRef((e,t)=>u.createElement(B,en({},e,{ref:t,icon:$t.default})));process.env.NODE_ENV!==`production`&&(tn.displayName=`LinkOutlined`);var nn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`0 0 1024 1024`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z`}}]},name:`loading`,theme:`outlined`}}))());function rn(){return rn=Object.assign?Object.assign.bind():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},rn.apply(this,arguments)}var an=u.forwardRef((e,t)=>u.createElement(B,rn({},e,{ref:t,icon:nn.default})));process.env.NODE_ENV!==`production`&&(an.displayName=`LoadingOutlined`);var on=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M832 464h-68V240c0-70.7-57.3-128-128-128H388c-70.7 0-128 57.3-128 128v224h-68c-17.7 0-32 14.3-32 32v384c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V496c0-17.7-14.3-32-32-32zM332 240c0-30.9 25.1-56 56-56h248c30.9 0 56 25.1 56 56v224H332V240zm460 600H232V536h560v304zM484 701v53c0 4.4 3.6 8 8 8h40c4.4 0 8-3.6 8-8v-53a48.01 48.01 0 10-56 0z`}}]},name:`lock`,theme:`outlined`}}))());function sn(){return sn=Object.assign?Object.assign.bind():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},sn.apply(this,arguments)}var cn=u.forwardRef((e,t)=>u.createElement(B,sn({},e,{ref:t,icon:on.default})));process.env.NODE_ENV!==`production`&&(cn.displayName=`LockOutlined`);var ln=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M868 732h-70.3c-4.8 0-9.3 2.1-12.3 5.8-7 8.5-14.5 16.7-22.4 24.5a353.84 353.84 0 01-112.7 75.9A352.8 352.8 0 01512.4 866c-47.9 0-94.3-9.4-137.9-27.8a353.84 353.84 0 01-112.7-75.9 353.28 353.28 0 01-76-112.5C167.3 606.2 158 559.9 158 512s9.4-94.2 27.8-137.8c17.8-42.1 43.4-80 76-112.5s70.5-58.1 112.7-75.9c43.6-18.4 90-27.8 137.9-27.8 47.9 0 94.3 9.3 137.9 27.8 42.2 17.8 80.1 43.4 112.7 75.9 7.9 7.9 15.3 16.1 22.4 24.5 3 3.7 7.6 5.8 12.3 5.8H868c6.3 0 10.2-7 6.7-12.3C798 160.5 663.8 81.6 511.3 82 271.7 82.6 79.6 277.1 82 516.4 84.4 751.9 276.2 942 512.4 942c152.1 0 285.7-78.8 362.3-197.7 3.4-5.3-.4-12.3-6.7-12.3zm88.9-226.3L815 393.7c-5.3-4.2-13-.4-13 6.3v76H488c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h314v76c0 6.7 7.8 10.5 13 6.3l141.9-112a8 8 0 000-12.6z`}}]},name:`logout`,theme:`outlined`}}))());function un(){return un=Object.assign?Object.assign.bind():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},un.apply(this,arguments)}var dn=u.forwardRef((e,t)=>u.createElement(B,un({},e,{ref:t,icon:ln.default})));process.env.NODE_ENV!==`production`&&(dn.displayName=`LogoutOutlined`);var fn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M408 442h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8zm-8 204c0 4.4 3.6 8 8 8h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56zm504-486H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 632H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM115.4 518.9L271.7 642c5.8 4.6 14.4.5 14.4-6.9V388.9c0-7.4-8.5-11.5-14.4-6.9L115.4 505.1a8.74 8.74 0 000 13.8z`}}]},name:`menu-fold`,theme:`outlined`}}))());function pn(){return pn=Object.assign?Object.assign.bind():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},pn.apply(this,arguments)}var mn=u.forwardRef((e,t)=>u.createElement(B,pn({},e,{ref:t,icon:fn.default})));process.env.NODE_ENV!==`production`&&(mn.displayName=`MenuFoldOutlined`);var hn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M408 442h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8zm-8 204c0 4.4 3.6 8 8 8h480c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H408c-4.4 0-8 3.6-8 8v56zm504-486H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 632H120c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h784c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM142.4 642.1L298.7 519a8.84 8.84 0 000-13.9L142.4 381.9c-5.8-4.6-14.4-.5-14.4 6.9v246.3a8.9 8.9 0 0014.4 7z`}}]},name:`menu-unfold`,theme:`outlined`}}))());function gn(){return gn=Object.assign?Object.assign.bind():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},gn.apply(this,arguments)}var _n=u.forwardRef((e,t)=>u.createElement(B,gn({},e,{ref:t,icon:hn.default})));process.env.NODE_ENV!==`production`&&(_n.displayName=`MenuUnfoldOutlined`);var vn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M464 512a48 48 0 1096 0 48 48 0 10-96 0zm200 0a48 48 0 1096 0 48 48 0 10-96 0zm-400 0a48 48 0 1096 0 48 48 0 10-96 0zm661.2-173.6c-22.6-53.7-55-101.9-96.3-143.3a444.35 444.35 0 00-143.3-96.3C630.6 75.7 572.2 64 512 64h-2c-60.6.3-119.3 12.3-174.5 35.9a445.35 445.35 0 00-142 96.5c-40.9 41.3-73 89.3-95.2 142.8-23 55.4-34.6 114.3-34.3 174.9A449.4 449.4 0 00112 714v152a46 46 0 0046 46h152.1A449.4 449.4 0 00510 960h2.1c59.9 0 118-11.6 172.7-34.3a444.48 444.48 0 00142.8-95.2c41.3-40.9 73.8-88.7 96.5-142 23.6-55.2 35.6-113.9 35.9-174.5.3-60.9-11.5-120-34.8-175.6zm-151.1 438C704 845.8 611 884 512 884h-1.7c-60.3-.3-120.2-15.3-173.1-43.5l-8.4-4.5H188V695.2l-4.5-8.4C155.3 633.9 140.3 574 140 513.7c-.4-99.7 37.7-193.3 107.6-263.8 69.8-70.5 163.1-109.5 262.8-109.9h1.7c50 0 98.5 9.7 144.2 28.9 44.6 18.7 84.6 45.6 119 80 34.3 34.3 61.3 74.4 80 119 19.4 46.2 29.1 95.2 28.9 145.8-.6 99.6-39.7 192.9-110.1 262.7z`}}]},name:`message`,theme:`outlined`}}))());function yn(){return yn=Object.assign?Object.assign.bind():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},yn.apply(this,arguments)}var bn=u.forwardRef((e,t)=>u.createElement(B,yn({},e,{ref:t,icon:vn.default})));process.env.NODE_ENV!==`production`&&(bn.displayName=`MessageOutlined`);var xn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M920 760H336c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0-568H336c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H336c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM216 712H100c-2.2 0-4 1.8-4 4v34c0 2.2 1.8 4 4 4h72.4v20.5h-35.7c-2.2 0-4 1.8-4 4v34c0 2.2 1.8 4 4 4h35.7V838H100c-2.2 0-4 1.8-4 4v34c0 2.2 1.8 4 4 4h116c2.2 0 4-1.8 4-4V716c0-2.2-1.8-4-4-4zM100 188h38v120c0 2.2 1.8 4 4 4h40c2.2 0 4-1.8 4-4V152c0-4.4-3.6-8-8-8h-78c-2.2 0-4 1.8-4 4v36c0 2.2 1.8 4 4 4zm116 240H100c-2.2 0-4 1.8-4 4v36c0 2.2 1.8 4 4 4h68.4l-70.3 77.7a8.3 8.3 0 00-2.1 5.4V592c0 2.2 1.8 4 4 4h116c2.2 0 4-1.8 4-4v-36c0-2.2-1.8-4-4-4h-68.4l70.3-77.7a8.3 8.3 0 002.1-5.4V432c0-2.2-1.8-4-4-4z`}}]},name:`ordered-list`,theme:`outlined`}}))());function Sn(){return Sn=Object.assign?Object.assign.bind():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},Sn.apply(this,arguments)}var Cn=u.forwardRef((e,t)=>u.createElement(B,Sn({},e,{ref:t,icon:xn.default})));process.env.NODE_ENV!==`production`&&(Cn.displayName=`OrderedListOutlined`);var wn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M779.3 196.6c-94.2-94.2-247.6-94.2-341.7 0l-261 260.8c-1.7 1.7-2.6 4-2.6 6.4s.9 4.7 2.6 6.4l36.9 36.9a9 9 0 0012.7 0l261-260.8c32.4-32.4 75.5-50.2 121.3-50.2s88.9 17.8 121.2 50.2c32.4 32.4 50.2 75.5 50.2 121.2 0 45.8-17.8 88.8-50.2 121.2l-266 265.9-43.1 43.1c-40.3 40.3-105.8 40.3-146.1 0-19.5-19.5-30.2-45.4-30.2-73s10.7-53.5 30.2-73l263.9-263.8c6.7-6.6 15.5-10.3 24.9-10.3h.1c9.4 0 18.1 3.7 24.7 10.3 6.7 6.7 10.3 15.5 10.3 24.9 0 9.3-3.7 18.1-10.3 24.7L372.4 653c-1.7 1.7-2.6 4-2.6 6.4s.9 4.7 2.6 6.4l36.9 36.9a9 9 0 0012.7 0l215.6-215.6c19.9-19.9 30.8-46.3 30.8-74.4s-11-54.6-30.8-74.4c-41.1-41.1-107.9-41-149 0L463 364 224.8 602.1A172.22 172.22 0 00174 724.8c0 46.3 18.1 89.8 50.8 122.5 33.9 33.8 78.3 50.7 122.7 50.7 44.4 0 88.8-16.9 122.6-50.7l309.2-309C824.8 492.7 850 432 850 367.5c.1-64.6-25.1-125.3-70.7-170.9z`}}]},name:`paper-clip`,theme:`outlined`}}))());function Tn(){return Tn=Object.assign?Object.assign.bind():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},Tn.apply(this,arguments)}var En=u.forwardRef((e,t)=>u.createElement(B,Tn({},e,{ref:t,icon:wn.default})));process.env.NODE_ENV!==`production`&&(En.displayName=`PaperClipOutlined`);var Dn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M304 176h80v672h-80zm408 0h-64c-4.4 0-8 3.6-8 8v656c0 4.4 3.6 8 8 8h64c4.4 0 8-3.6 8-8V184c0-4.4-3.6-8-8-8z`}}]},name:`pause`,theme:`outlined`}}))());function On(){return On=Object.assign?Object.assign.bind():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},On.apply(this,arguments)}var kn=u.forwardRef((e,t)=>u.createElement(B,On({},e,{ref:t,icon:Dn.default})));process.env.NODE_ENV!==`production`&&(kn.displayName=`PauseOutlined`);var An=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M928 160H96c-17.7 0-32 14.3-32 32v640c0 17.7 14.3 32 32 32h832c17.7 0 32-14.3 32-32V192c0-17.7-14.3-32-32-32zm-40 632H136v-39.9l138.5-164.3 150.1 178L658.1 489 888 761.6V792zm0-129.8L664.2 396.8c-3.2-3.8-9-3.8-12.2 0L424.6 666.4l-144-170.7c-3.2-3.8-9-3.8-12.2 0L136 652.7V232h752v430.2zM304 456a88 88 0 100-176 88 88 0 000 176zm0-116c15.5 0 28 12.5 28 28s-12.5 28-28 28-28-12.5-28-28 12.5-28 28-28z`}}]},name:`picture`,theme:`outlined`}}))());function jn(){return jn=Object.assign?Object.assign.bind():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},jn.apply(this,arguments)}var Mn=u.forwardRef((e,t)=>u.createElement(B,jn({},e,{ref:t,icon:An.default})));process.env.NODE_ENV!==`production`&&(Mn.displayName=`PictureOutlined`);var Nn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M482 152h60q8 0 8 8v704q0 8-8 8h-60q-8 0-8-8V160q0-8 8-8z`}},{tag:`path`,attrs:{d:`M192 474h672q8 0 8 8v60q0 8-8 8H160q-8 0-8-8v-60q0-8 8-8z`}}]},name:`plus`,theme:`outlined`}}))());function Pn(){return Pn=Object.assign?Object.assign.bind():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},Pn.apply(this,arguments)}var Fn=u.forwardRef((e,t)=>u.createElement(B,Pn({},e,{ref:t,icon:Nn.default})));process.env.NODE_ENV!==`production`&&(Fn.displayName=`PlusOutlined`);var In=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M878.3 392.1L631.9 145.7c-6.5-6.5-15-9.7-23.5-9.7s-17 3.2-23.5 9.7L423.8 306.9c-12.2-1.4-24.5-2-36.8-2-73.2 0-146.4 24.1-206.5 72.3-15.4 12.3-16.6 35.4-2.7 49.4l181.7 181.7-215.4 215.2a15.8 15.8 0 00-4.6 9.8l-3.4 37.2c-.9 9.4 6.6 17.4 15.9 17.4.5 0 1 0 1.5-.1l37.2-3.4c3.7-.3 7.2-2 9.8-4.6l215.4-215.4 181.7 181.7c6.5 6.5 15 9.7 23.5 9.7 9.7 0 19.3-4.2 25.9-12.4 56.3-70.3 79.7-158.3 70.2-243.4l161.1-161.1c12.9-12.8 12.9-33.8 0-46.8z`}}]},name:`pushpin`,theme:`filled`}}))());function Ln(){return Ln=Object.assign?Object.assign.bind():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},Ln.apply(this,arguments)}var Rn=u.forwardRef((e,t)=>u.createElement(B,Ln({},e,{ref:t,icon:In.default})));process.env.NODE_ENV!==`production`&&(Rn.displayName=`PushpinFilled`);var zn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M878.3 392.1L631.9 145.7c-6.5-6.5-15-9.7-23.5-9.7s-17 3.2-23.5 9.7L423.8 306.9c-12.2-1.4-24.5-2-36.8-2-73.2 0-146.4 24.1-206.5 72.3a33.23 33.23 0 00-2.7 49.4l181.7 181.7-215.4 215.2a15.8 15.8 0 00-4.6 9.8l-3.4 37.2c-.9 9.4 6.6 17.4 15.9 17.4.5 0 1 0 1.5-.1l37.2-3.4c3.7-.3 7.2-2 9.8-4.6l215.4-215.4 181.7 181.7c6.5 6.5 15 9.7 23.5 9.7 9.7 0 19.3-4.2 25.9-12.4 56.3-70.3 79.7-158.3 70.2-243.4l161.1-161.1c12.9-12.8 12.9-33.8 0-46.8zM666.2 549.3l-24.5 24.5 3.8 34.4a259.92 259.92 0 01-30.4 153.9L262 408.8c12.9-7.1 26.3-13.1 40.3-17.9 27.2-9.4 55.7-14.1 84.7-14.1 9.6 0 19.3.5 28.9 1.6l34.4 3.8 24.5-24.5L608.5 224 800 415.5 666.2 549.3z`}}]},name:`pushpin`,theme:`outlined`}}))());function Bn(){return Bn=Object.assign?Object.assign.bind():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},Bn.apply(this,arguments)}var Vn=u.forwardRef((e,t)=>u.createElement(B,Bn({},e,{ref:t,icon:zn.default})));process.env.NODE_ENV!==`production`&&(Vn.displayName=`PushpinOutlined`);var Hn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M758.2 839.1C851.8 765.9 912 651.9 912 523.9 912 303 733.5 124.3 512.6 124 291.4 123.7 112 302.8 112 523.9c0 125.2 57.5 236.9 147.6 310.2 3.5 2.8 8.6 2.2 11.4-1.3l39.4-50.5c2.7-3.4 2.1-8.3-1.2-11.1-8.1-6.6-15.9-13.7-23.4-21.2a318.64 318.64 0 01-68.6-101.7C200.4 609 192 567.1 192 523.9s8.4-85.1 25.1-124.5c16.1-38.1 39.2-72.3 68.6-101.7 29.4-29.4 63.6-52.5 101.7-68.6C426.9 212.4 468.8 204 512 204s85.1 8.4 124.5 25.1c38.1 16.1 72.3 39.2 101.7 68.6 29.4 29.4 52.5 63.6 68.6 101.7 16.7 39.4 25.1 81.3 25.1 124.5s-8.4 85.1-25.1 124.5a318.64 318.64 0 01-68.6 101.7c-9.3 9.3-19.1 18-29.3 26L668.2 724a8 8 0 00-14.1 3l-39.6 162.2c-1.2 5 2.6 9.9 7.7 9.9l167 .8c6.7 0 10.5-7.7 6.3-12.9l-37.3-47.9z`}}]},name:`redo`,theme:`outlined`}}))());function Un(){return Un=Object.assign?Object.assign.bind():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},Un.apply(this,arguments)}var Wn=u.forwardRef((e,t)=>u.createElement(B,Un({},e,{ref:t,icon:Hn.default})));process.env.NODE_ENV!==`production`&&(Wn.displayName=`RedoOutlined`);var Gn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M909.1 209.3l-56.4 44.1C775.8 155.1 656.2 92 521.9 92 290 92 102.3 279.5 102 511.5 101.7 743.7 289.8 932 521.9 932c181.3 0 335.8-115 394.6-276.1 1.5-4.2-.7-8.9-4.9-10.3l-56.7-19.5a8 8 0 00-10.1 4.8c-1.8 5-3.8 10-5.9 14.9-17.3 41-42.1 77.8-73.7 109.4A344.77 344.77 0 01655.9 829c-42.3 17.9-87.4 27-133.8 27-46.5 0-91.5-9.1-133.8-27A341.5 341.5 0 01279 755.2a342.16 342.16 0 01-73.7-109.4c-17.9-42.4-27-87.4-27-133.9s9.1-91.5 27-133.9c17.3-41 42.1-77.8 73.7-109.4 31.6-31.6 68.4-56.4 109.3-73.8 42.3-17.9 87.4-27 133.8-27 46.5 0 91.5 9.1 133.8 27a341.5 341.5 0 01109.3 73.8c9.9 9.9 19.2 20.4 27.8 31.4l-60.2 47a8 8 0 003 14.1l175.6 43c5 1.2 9.9-2.6 9.9-7.7l.8-180.9c-.1-6.6-7.8-10.3-13-6.2z`}}]},name:`reload`,theme:`outlined`}}))());function Kn(){return Kn=Object.assign?Object.assign.bind():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},Kn.apply(this,arguments)}var qn=u.forwardRef((e,t)=>u.createElement(B,Kn({},e,{ref:t,icon:Gn.default})));process.env.NODE_ENV!==`production`&&(qn.displayName=`ReloadOutlined`);var Jn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M765.7 486.8L314.9 134.7A7.97 7.97 0 00302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 000-50.4z`}}]},name:`right`,theme:`outlined`}}))());function Yn(){return Yn=Object.assign?Object.assign.bind():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},Yn.apply(this,arguments)}var Xn=u.forwardRef((e,t)=>u.createElement(B,Yn({},e,{ref:t,icon:Jn.default})));process.env.NODE_ENV!==`production`&&(Xn.displayName=`RightOutlined`);var Zn=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M480.5 251.2c13-1.6 25.9-2.4 38.8-2.5v63.9c0 6.5 7.5 10.1 12.6 6.1L660 217.6c4-3.2 4-9.2 0-12.3l-128-101c-5.1-4-12.6-.4-12.6 6.1l-.2 64c-118.6.5-235.8 53.4-314.6 154.2A399.75 399.75 0 00123.5 631h74.9c-.9-5.3-1.7-10.7-2.4-16.1-5.1-42.1-2.1-84.1 8.9-124.8 11.4-42.2 31-81.1 58.1-115.8 27.2-34.7 60.3-63.2 98.4-84.3 37-20.6 76.9-33.6 119.1-38.8z`}},{tag:`path`,attrs:{d:`M880 418H352c-17.7 0-32 14.3-32 32v414c0 17.7 14.3 32 32 32h528c17.7 0 32-14.3 32-32V450c0-17.7-14.3-32-32-32zm-44 402H396V494h440v326z`}}]},name:`rotate-right`,theme:`outlined`}}))());function Qn(){return Qn=Object.assign?Object.assign.bind():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},Qn.apply(this,arguments)}var $n=u.forwardRef((e,t)=>u.createElement(B,Qn({},e,{ref:t,icon:Zn.default})));process.env.NODE_ENV!==`production`&&($n.displayName=`RotateRightOutlined`);var er=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z`}}]},name:`search`,theme:`outlined`}}))());function tr(){return tr=Object.assign?Object.assign.bind():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},tr.apply(this,arguments)}var nr=u.forwardRef((e,t)=>u.createElement(B,tr({},e,{ref:t,icon:er.default})));process.env.NODE_ENV!==`production`&&(nr.displayName=`SearchOutlined`);var eee=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M931.4 498.9L94.9 79.5c-3.4-1.7-7.3-2.1-11-1.2a15.99 15.99 0 00-11.7 19.3l86.2 352.2c1.3 5.3 5.2 9.6 10.4 11.3l147.7 50.7-147.6 50.7c-5.2 1.8-9.1 6-10.3 11.3L72.2 926.5c-.9 3.7-.5 7.6 1.2 10.9 3.9 7.9 13.5 11.1 21.5 7.2l836.5-417c3.1-1.5 5.6-4.1 7.2-7.1 3.9-8 .7-17.6-7.2-21.6zM170.8 826.3l50.3-205.6 295.2-101.3c2.3-.8 4.2-2.6 5-5 1.4-4.2-.8-8.7-5-10.2L221.1 403 171 198.2l628 314.9-628.2 313.2z`}}]},name:`send`,theme:`outlined`}}))());function rr(){return rr=Object.assign?Object.assign.bind():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},rr.apply(this,arguments)}var ir=u.forwardRef((e,t)=>u.createElement(B,rr({},e,{ref:t,icon:eee.default})));process.env.NODE_ENV!==`production`&&(ir.displayName=`SendOutlined`);var ar=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M924.8 625.7l-65.5-56c3.1-19 4.7-38.4 4.7-57.8s-1.6-38.8-4.7-57.8l65.5-56a32.03 32.03 0 009.3-35.2l-.9-2.6a443.74 443.74 0 00-79.7-137.9l-1.8-2.1a32.12 32.12 0 00-35.1-9.5l-81.3 28.9c-30-24.6-63.5-44-99.7-57.6l-15.7-85a32.05 32.05 0 00-25.8-25.7l-2.7-.5c-52.1-9.4-106.9-9.4-159 0l-2.7.5a32.05 32.05 0 00-25.8 25.7l-15.8 85.4a351.86 351.86 0 00-99 57.4l-81.9-29.1a32 32 0 00-35.1 9.5l-1.8 2.1a446.02 446.02 0 00-79.7 137.9l-.9 2.6c-4.5 12.5-.8 26.5 9.3 35.2l66.3 56.6c-3.1 18.8-4.6 38-4.6 57.1 0 19.2 1.5 38.4 4.6 57.1L99 625.5a32.03 32.03 0 00-9.3 35.2l.9 2.6c18.1 50.4 44.9 96.9 79.7 137.9l1.8 2.1a32.12 32.12 0 0035.1 9.5l81.9-29.1c29.8 24.5 63.1 43.9 99 57.4l15.8 85.4a32.05 32.05 0 0025.8 25.7l2.7.5a449.4 449.4 0 00159 0l2.7-.5a32.05 32.05 0 0025.8-25.7l15.7-85a350 350 0 0099.7-57.6l81.3 28.9a32 32 0 0035.1-9.5l1.8-2.1c34.8-41.1 61.6-87.5 79.7-137.9l.9-2.6c4.5-12.3.8-26.3-9.3-35zM788.3 465.9c2.5 15.1 3.8 30.6 3.8 46.1s-1.3 31-3.8 46.1l-6.6 40.1 74.7 63.9a370.03 370.03 0 01-42.6 73.6L721 702.8l-31.4 25.8c-23.9 19.6-50.5 35-79.3 45.8l-38.1 14.3-17.9 97a377.5 377.5 0 01-85 0l-17.9-97.2-37.8-14.5c-28.5-10.8-55-26.2-78.7-45.7l-31.4-25.9-93.4 33.2c-17-22.9-31.2-47.6-42.6-73.6l75.5-64.5-6.5-40c-2.4-14.9-3.7-30.3-3.7-45.5 0-15.3 1.2-30.6 3.7-45.5l6.5-40-75.5-64.5c11.3-26.1 25.6-50.7 42.6-73.6l93.4 33.2 31.4-25.9c23.7-19.5 50.2-34.9 78.7-45.7l37.9-14.3 17.9-97.2c28.1-3.2 56.8-3.2 85 0l17.9 97 38.1 14.3c28.7 10.8 55.4 26.2 79.3 45.8l31.4 25.8 92.8-32.9c17 22.9 31.2 47.6 42.6 73.6L781.8 426l6.5 39.9zM512 326c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm79.2 255.2A111.6 111.6 0 01512 614c-29.9 0-58-11.7-79.2-32.8A111.6 111.6 0 01400 502c0-29.9 11.7-58 32.8-79.2C454 401.6 482.1 390 512 390c29.9 0 58 11.6 79.2 32.8A111.6 111.6 0 01624 502c0 29.9-11.7 58-32.8 79.2z`}}]},name:`setting`,theme:`outlined`}}))());function or(){return or=Object.assign?Object.assign.bind():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},or.apply(this,arguments)}var sr=u.forwardRef((e,t)=>u.createElement(B,or({},e,{ref:t,icon:ar.default})));process.env.NODE_ENV!==`production`&&(sr.displayName=`SettingOutlined`);var cr=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M288 421a48 48 0 1096 0 48 48 0 10-96 0zm352 0a48 48 0 1096 0 48 48 0 10-96 0zM512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm263 711c-34.2 34.2-74 61-118.3 79.8C611 874.2 562.3 884 512 884c-50.3 0-99-9.8-144.8-29.2A370.4 370.4 0 01248.9 775c-34.2-34.2-61-74-79.8-118.3C149.8 611 140 562.3 140 512s9.8-99 29.2-144.8A370.4 370.4 0 01249 248.9c34.2-34.2 74-61 118.3-79.8C413 149.8 461.7 140 512 140c50.3 0 99 9.8 144.8 29.2A370.4 370.4 0 01775.1 249c34.2 34.2 61 74 79.8 118.3C874.2 413 884 461.7 884 512s-9.8 99-29.2 144.8A368.89 368.89 0 01775 775zM664 533h-48.1c-4.2 0-7.8 3.2-8.1 7.4C604 589.9 562.5 629 512 629s-92.1-39.1-95.8-88.6c-.3-4.2-3.9-7.4-8.1-7.4H360a8 8 0 00-8 8.4c4.4 84.3 74.5 151.6 160 151.6s155.6-67.3 160-151.6a8 8 0 00-8-8.4z`}}]},name:`smile`,theme:`outlined`}}))());function lr(){return lr=Object.assign?Object.assign.bind():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},lr.apply(this,arguments)}var ur=u.forwardRef((e,t)=>u.createElement(B,lr({},e,{ref:t,icon:cr.default})));process.env.NODE_ENV!==`production`&&(ur.displayName=`SmileOutlined`);var dr=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M952 474H569.9c-10-2-20.5-4-31.6-6-15.9-2.9-22.2-4.1-30.8-5.8-51.3-10-82.2-20-106.8-34.2-35.1-20.5-52.2-48.3-52.2-85.1 0-37 15.2-67.7 44-89 28.4-21 68.8-32.1 116.8-32.1 54.8 0 97.1 14.4 125.8 42.8 14.6 14.4 25.3 32.1 31.8 52.6 1.3 4.1 2.8 10 4.3 17.8.9 4.8 5.2 8.2 9.9 8.2h72.8c5.6 0 10.1-4.6 10.1-10.1v-1c-.7-6.8-1.3-12.1-2-16-7.3-43.5-28-81.7-59.7-110.3-44.4-40.5-109.7-61.8-188.7-61.8-72.3 0-137.4 18.1-183.3 50.9-25.6 18.4-45.4 41.2-58.6 67.7-13.5 27.1-20.3 58.4-20.3 92.9 0 29.5 5.7 54.5 17.3 76.5 8.3 15.7 19.6 29.5 34.1 42H72c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h433.2c2.1.4 3.9.8 5.9 1.2 30.9 6.2 49.5 10.4 66.6 15.2 23 6.5 40.6 13.3 55.2 21.5 35.8 20.2 53.3 49.2 53.3 89 0 35.3-15.5 66.8-43.6 88.8-30.5 23.9-75.6 36.4-130.5 36.4-43.7 0-80.7-8.5-110.2-25-29.1-16.3-49.1-39.8-59.7-69.5-.8-2.2-1.7-5.2-2.7-9-1.2-4.4-5.3-7.5-9.7-7.5h-79.7c-5.6 0-10.1 4.6-10.1 10.1v1c.2 2.3.4 4.2.6 5.7 6.5 48.8 30.3 88.8 70.7 118.8 47.1 34.8 113.4 53.2 191.8 53.2 84.2 0 154.8-19.8 204.2-57.3 25-18.9 44.2-42.2 57.1-69 13-27.1 19.7-57.9 19.7-91.5 0-31.8-5.8-58.4-17.8-81.4-5.8-11.2-13.1-21.5-21.8-30.8H952c4.4 0 8-3.6 8-8v-60a8 8 0 00-8-7.9z`}}]},name:`strikethrough`,theme:`outlined`}}))());function fr(){return fr=Object.assign?Object.assign.bind():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},fr.apply(this,arguments)}var pr=u.forwardRef((e,t)=>u.createElement(B,fr({},e,{ref:t,icon:dr.default})));process.env.NODE_ENV!==`production`&&(pr.displayName=`StrikethroughOutlined`);var mr=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M824.2 699.9a301.55 301.55 0 00-86.4-60.4C783.1 602.8 812 546.8 812 484c0-110.8-92.4-201.7-203.2-200-109.1 1.7-197 90.6-197 200 0 62.8 29 118.8 74.2 155.5a300.95 300.95 0 00-86.4 60.4C345 754.6 314 826.8 312 903.8a8 8 0 008 8.2h56c4.3 0 7.9-3.4 8-7.7 1.9-58 25.4-112.3 66.7-153.5A226.62 226.62 0 01612 684c60.9 0 118.2 23.7 161.3 66.8C814.5 792 838 846.3 840 904.3c.1 4.3 3.7 7.7 8 7.7h56a8 8 0 008-8.2c-2-77-33-149.2-87.8-203.9zM612 612c-34.2 0-66.4-13.3-90.5-37.5a126.86 126.86 0 01-37.5-91.8c.3-32.8 13.4-64.5 36.3-88 24-24.6 56.1-38.3 90.4-38.7 33.9-.3 66.8 12.9 91 36.6 24.8 24.3 38.4 56.8 38.4 91.4 0 34.2-13.3 66.3-37.5 90.5A127.3 127.3 0 01612 612zM361.5 510.4c-.9-8.7-1.4-17.5-1.4-26.4 0-15.9 1.5-31.4 4.3-46.5.7-3.6-1.2-7.3-4.5-8.8-13.6-6.1-26.1-14.5-36.9-25.1a127.54 127.54 0 01-38.7-95.4c.9-32.1 13.8-62.6 36.3-85.6 24.7-25.3 57.9-39.1 93.2-38.7 31.9.3 62.7 12.6 86 34.4 7.9 7.4 14.7 15.6 20.4 24.4 2 3.1 5.9 4.4 9.3 3.2 17.6-6.1 36.2-10.4 55.3-12.4 5.6-.6 8.8-6.6 6.3-11.6-32.5-64.3-98.9-108.7-175.7-109.9-110.9-1.7-203.3 89.2-203.3 199.9 0 62.8 28.9 118.8 74.2 155.5-31.8 14.7-61.1 35-86.5 60.4-54.8 54.7-85.8 126.9-87.8 204a8 8 0 008 8.2h56.1c4.3 0 7.9-3.4 8-7.7 1.9-58 25.4-112.3 66.7-153.5 29.4-29.4 65.4-49.8 104.7-59.7 3.9-1 6.5-4.7 6-8.7z`}}]},name:`team`,theme:`outlined`}}))());function hr(){return hr=Object.assign?Object.assign.bind():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},hr.apply(this,arguments)}var gr=u.forwardRef((e,t)=>u.createElement(B,hr({},e,{ref:t,icon:mr.default})));process.env.NODE_ENV!==`production`&&(gr.displayName=`TeamOutlined`);var _r=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M824 804H200c-4.4 0-8 3.4-8 7.6v60.8c0 4.2 3.6 7.6 8 7.6h624c4.4 0 8-3.4 8-7.6v-60.8c0-4.2-3.6-7.6-8-7.6zm-312-76c69.4 0 134.6-27.1 183.8-76.2C745 602.7 772 537.4 772 468V156c0-6.6-5.4-12-12-12h-60c-6.6 0-12 5.4-12 12v312c0 97-79 176-176 176s-176-79-176-176V156c0-6.6-5.4-12-12-12h-60c-6.6 0-12 5.4-12 12v312c0 69.4 27.1 134.6 76.2 183.8C377.3 701 442.6 728 512 728z`}}]},name:`underline`,theme:`outlined`}}))());function vr(){return vr=Object.assign?Object.assign.bind():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},vr.apply(this,arguments)}var yr=u.forwardRef((e,t)=>u.createElement(B,vr({},e,{ref:t,icon:_r.default})));process.env.NODE_ENV!==`production`&&(yr.displayName=`UnderlineOutlined`);var tee=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M511.4 124C290.5 124.3 112 303 112 523.9c0 128 60.2 242 153.8 315.2l-37.5 48c-4.1 5.3-.3 13 6.3 12.9l167-.8c5.2 0 9-4.9 7.7-9.9L369.8 727a8 8 0 00-14.1-3L315 776.1c-10.2-8-20-16.7-29.3-26a318.64 318.64 0 01-68.6-101.7C200.4 609 192 567.1 192 523.9s8.4-85.1 25.1-124.5c16.1-38.1 39.2-72.3 68.6-101.7 29.4-29.4 63.6-52.5 101.7-68.6C426.9 212.4 468.8 204 512 204s85.1 8.4 124.5 25.1c38.1 16.1 72.3 39.2 101.7 68.6 29.4 29.4 52.5 63.6 68.6 101.7 16.7 39.4 25.1 81.3 25.1 124.5s-8.4 85.1-25.1 124.5a318.64 318.64 0 01-68.6 101.7c-7.5 7.5-15.3 14.5-23.4 21.2a7.93 7.93 0 00-1.2 11.1l39.4 50.5c2.8 3.5 7.9 4.1 11.4 1.3C854.5 760.8 912 649.1 912 523.9c0-221.1-179.4-400.2-400.6-399.9z`}}]},name:`undo`,theme:`outlined`}}))());function br(){return br=Object.assign?Object.assign.bind():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},br.apply(this,arguments)}var xr=u.forwardRef((e,t)=>u.createElement(B,br({},e,{ref:t,icon:tee.default})));process.env.NODE_ENV!==`production`&&(xr.displayName=`UndoOutlined`);var Sr=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M912 192H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zm0 284H328c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h584c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8zM104 228a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0zm0 284a56 56 0 10112 0 56 56 0 10-112 0z`}}]},name:`unordered-list`,theme:`outlined`}}))());function Cr(){return Cr=Object.assign?Object.assign.bind():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},Cr.apply(this,arguments)}var wr=u.forwardRef((e,t)=>u.createElement(B,Cr({},e,{ref:t,icon:Sr.default})));process.env.NODE_ENV!==`production`&&(wr.displayName=`UnorderedListOutlined`);var Tr=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M678.3 642.4c24.2-13 51.9-20.4 81.4-20.4h.1c3 0 4.4-3.6 2.2-5.6a371.67 371.67 0 00-103.7-65.8c-.4-.2-.8-.3-1.2-.5C719.2 505 759.6 431.7 759.6 349c0-137-110.8-248-247.5-248S264.7 212 264.7 349c0 82.7 40.4 156 102.6 201.1-.4.2-.8.3-1.2.5-44.7 18.9-84.8 46-119.3 80.6a373.42 373.42 0 00-80.4 119.5A373.6 373.6 0 00137 888.8a8 8 0 008 8.2h59.9c4.3 0 7.9-3.5 8-7.8 2-77.2 32.9-149.5 87.6-204.3C357 628.2 432.2 597 512.2 597c56.7 0 111.1 15.7 158 45.1a8.1 8.1 0 008.1.3zM512.2 521c-45.8 0-88.9-17.9-121.4-50.4A171.2 171.2 0 01340.5 349c0-45.9 17.9-89.1 50.3-121.6S466.3 177 512.2 177s88.9 17.9 121.4 50.4A171.2 171.2 0 01683.9 349c0 45.9-17.9 89.1-50.3 121.6C601.1 503.1 558 521 512.2 521zM880 759h-84v-84c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v84h-84c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h84v84c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8v-84h84c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8z`}}]},name:`user-add`,theme:`outlined`}}))());function Er(){return Er=Object.assign?Object.assign.bind():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},Er.apply(this,arguments)}var Dr=u.forwardRef((e,t)=>u.createElement(B,Er({},e,{ref:t,icon:Tr.default})));process.env.NODE_ENV!==`production`&&(Dr.displayName=`UserAddOutlined`);var Or=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M678.3 655.4c24.2-13 51.9-20.4 81.4-20.4h.1c3 0 4.4-3.6 2.2-5.6a371.67 371.67 0 00-103.7-65.8c-.4-.2-.8-.3-1.2-.5C719.2 518 759.6 444.7 759.6 362c0-137-110.8-248-247.5-248S264.7 225 264.7 362c0 82.7 40.4 156 102.6 201.1-.4.2-.8.3-1.2.5-44.7 18.9-84.8 46-119.3 80.6a373.42 373.42 0 00-80.4 119.5A373.6 373.6 0 00137 901.8a8 8 0 008 8.2h59.9c4.3 0 7.9-3.5 8-7.8 2-77.2 32.9-149.5 87.6-204.3C357 641.2 432.2 610 512.2 610c56.7 0 111.1 15.7 158 45.1a8.1 8.1 0 008.1.3zM512.2 534c-45.8 0-88.9-17.9-121.4-50.4A171.2 171.2 0 01340.5 362c0-45.9 17.9-89.1 50.3-121.6S466.3 190 512.2 190s88.9 17.9 121.4 50.4A171.2 171.2 0 01683.9 362c0 45.9-17.9 89.1-50.3 121.6C601.1 516.1 558 534 512.2 534zM880 772H640c-4.4 0-8 3.6-8 8v56c0 4.4 3.6 8 8 8h240c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8z`}}]},name:`user-delete`,theme:`outlined`}}))());function kr(){return kr=Object.assign?Object.assign.bind():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},kr.apply(this,arguments)}var Ar=u.forwardRef((e,t)=>u.createElement(B,kr({},e,{ref:t,icon:Or.default})));process.env.NODE_ENV!==`production`&&(Ar.displayName=`UserDeleteOutlined`);var jr=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M858.5 763.6a374 374 0 00-80.6-119.5 375.63 375.63 0 00-119.5-80.6c-.4-.2-.8-.3-1.2-.5C719.5 518 760 444.7 760 362c0-137-111-248-248-248S264 225 264 362c0 82.7 40.5 156 102.8 201.1-.4.2-.8.3-1.2.5-44.8 18.9-85 46-119.5 80.6a375.63 375.63 0 00-80.6 119.5A371.7 371.7 0 00136 901.8a8 8 0 008 8.2h60c4.4 0 7.9-3.5 8-7.8 2-77.2 33-149.5 87.8-204.3 56.7-56.7 132-87.9 212.2-87.9s155.5 31.2 212.2 87.9C779 752.7 810 825 812 902.2c.1 4.4 3.6 7.8 8 7.8h60a8 8 0 008-8.2c-1-47.8-10.9-94.3-29.5-138.2zM512 534c-45.9 0-89.1-17.9-121.6-50.4S340 407.9 340 362c0-45.9 17.9-89.1 50.4-121.6S466.1 190 512 190s89.1 17.9 121.6 50.4S684 316.1 684 362c0 45.9-17.9 89.1-50.4 121.6S557.9 534 512 534z`}}]},name:`user`,theme:`outlined`}}))());function Mr(){return Mr=Object.assign?Object.assign.bind():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},Mr.apply(this,arguments)}var Nr=u.forwardRef((e,t)=>u.createElement(B,Mr({},e,{ref:t,icon:jr.default})));process.env.NODE_ENV!==`production`&&(Nr.displayName=`UserOutlined`);var Pr=l(o((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default={icon:{tag:`svg`,attrs:{viewBox:`64 64 896 896`,focusable:`false`},children:[{tag:`path`,attrs:{d:`M464 720a48 48 0 1096 0 48 48 0 10-96 0zm16-304v184c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V416c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8zm475.7 440l-416-720c-6.2-10.7-16.9-16-27.7-16s-21.6 5.3-27.7 16l-416 720C56 877.4 71.4 904 96 904h832c24.6 0 40-26.6 27.7-48zm-783.5-27.9L512 239.9l339.8 588.2H172.2z`}}]},name:`warning`,theme:`outlined`}}))());function Fr(){return Fr=Object.assign?Object.assign.bind():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},Fr.apply(this,arguments)}var Ir=u.forwardRef((e,t)=>u.createElement(B,Fr({},e,{ref:t,icon:Pr.default})));process.env.NODE_ENV!==`production`&&(Ir.displayName=`WarningOutlined`);var Lr=4e3;function Rr({images:e,className:t}){let[n,r]=(0,d.useState)(0),i=t=>r((t+e.length)%e.length);return(0,d.useEffect)(()=>{if(e.length<=1)return;let t=window.setInterval(()=>{r(t=>(t+1)%e.length)},Lr);return()=>window.clearInterval(t)},[e.length]),(0,p.jsxs)(`div`,{className:`banner-carousel${t?` ${t}`:``}`,children:[e.length>1?(0,p.jsx)(`button`,{type:`button`,className:`banner-carousel-arrow banner-carousel-arrow--prev`,"aria-label":`Banner trước`,onClick:()=>i(n-1),children:(0,p.jsx)(Qt,{})}):null,(0,p.jsx)(`div`,{className:`banner-carousel-viewport`,children:(0,p.jsx)(`div`,{className:`banner-carousel-track`,style:{transform:`translateX(-${n*100}%)`},children:e.map(e=>(0,p.jsx)(`img`,{className:`banner-carousel-slide`,src:e,alt:``},e))})}),e.length>1?(0,p.jsx)(`button`,{type:`button`,className:`banner-carousel-arrow banner-carousel-arrow--next`,"aria-label":`Banner tiếp theo`,onClick:()=>i(n+1),children:(0,p.jsx)(Xn,{})}):null,e.length>1?(0,p.jsx)(`div`,{className:`banner-carousel-dots`,children:e.map((e,t)=>(0,p.jsx)(`button`,{type:`button`,className:`banner-carousel-dot${t===n?` is-active`:``}`,"aria-label":`Xem banner ${t+1}`,onClick:()=>r(t)},e))}):null]})}var zr=[_,v,y,b];function Br(){return(0,p.jsxs)(`div`,{className:`conversation-placeholder`,children:[(0,p.jsxs)(`h2`,{className:`conversation-placeholder-title`,children:[`Chào mừng bạn đến với `,(0,p.jsx)(`strong`,{className:`conversation-placeholder-title-strong`,children:`MEDITECH CHAT`})]}),(0,p.jsx)(`p`,{className:`conversation-placeholder-subtitle`,children:`Khám phá những tiện ích hỗ trợ việc làm và trò chuyện cùng bạn bè, đồng nghiệp được tối ưu ngay trên ERP`}),(0,p.jsx)(Rr,{images:zr,className:`conversation-placeholder-banner`}),(0,p.jsx)(`p`,{className:`conversation-placeholder-footer`,children:`Chọn một cuộc trò chuyện để bắt đầu.`})]})}var Vr=(0,d.createContext)(null);function Hr(){let e=(0,d.useContext)(Vr);if(!e)throw Error(`Chat screens must render inside a chat navigation provider.`);return e}function Ur(e,t){let[n,r]=(0,d.useState)(e);return(0,d.useEffect)(()=>{let n=window.setTimeout(()=>r(e),t);return()=>window.clearTimeout(n)},[e,t]),n}var Wr=e=>{let t,n=new Set,r=(e,r)=>{let i=typeof e==`function`?e(t):e;if(!Object.is(i,t)){let e=t;t=r??(typeof i!=`object`||!i)?i:Object.assign({},t,i),n.forEach(n=>n(t,e))}},i=()=>t,a={setState:r,getState:i,getInitialState:()=>o,subscribe:e=>(n.add(e),()=>n.delete(e))},o=t=e(r,i,a);return a},Gr=(e=>e?Wr(e):Wr),Kr=e=>e;function nee(e,t=Kr){let n=d.default.useSyncExternalStore(e.subscribe,d.default.useCallback(()=>t(e.getState()),[e,t]),d.default.useCallback(()=>t(e.getInitialState()),[e,t]));return d.default.useDebugValue(n),n}var qr=e=>{let t=Gr(e),n=e=>nee(t,e);return Object.assign(n,t),n},Jr=(e=>e?qr(e):qr);function ree(e,t){let n;try{n=e()}catch{return}return{getItem:e=>{let r=e=>e===null?null:JSON.parse(e,t?.reviver),i=n.getItem(e)??null;return i instanceof Promise?i.then(r):r(i)},setItem:(e,r)=>n.setItem(e,JSON.stringify(r,t?.replacer)),removeItem:e=>n.removeItem(e)}}var Yr=e=>t=>{try{let n=e(t);return n instanceof Promise?n:{then(e){return Yr(e)(n)},catch(e){return this}}}catch(e){return{then(e){return this},catch(t){return Yr(t)(e)}}}},Xr=Jr()(((e,t)=>(n,r,i)=>{let a={storage:ree(()=>window.localStorage),partialize:e=>e,version:0,merge:(e,t)=>({...t,...e}),...t},o=!1,s=0,c=new Set,l=new Set,u=a.storage;if(!u)return e((...e)=>{console.warn(`[zustand persist middleware] Unable to update item '${a.name}', the given storage is currently unavailable.`),n(...e)},r,i);let d=()=>{let e=a.partialize({...r()});return u.setItem(a.name,{state:e,version:a.version})},f=i.setState;i.setState=(e,t)=>(f(e,t),d());let p=e((...e)=>(n(...e),d()),r,i);i.getInitialState=()=>p;let m,h=()=>{if(!u)return;let e=++s;o=!1,c.forEach(e=>e(r()??p));let t=a.onRehydrateStorage?.call(a,r()??p)||void 0;return Yr(u.getItem.bind(u))(a.name).then(e=>{if(e)if(typeof e.version==`number`&&e.version!==a.version){if(a.migrate){let t=a.migrate(e.state,e.version);return t instanceof Promise?t.then(e=>[!0,e]):[!0,t]}console.error(`State loaded from storage couldn't be migrated since no migrate function was provided`)}else return[!1,e.state];return[!1,void 0]}).then(t=>{if(e!==s)return;let[i,o]=t;if(m=a.merge(o,r()??p),n(m,!0),i)return d()}).then(()=>{e===s&&(t?.(r(),void 0),m=r(),o=!0,l.forEach(e=>e(m)))}).catch(n=>{e===s&&t?.(void 0,n)})};return i.persist={setOptions:e=>{a={...a,...e},e.storage&&(u=e.storage)},clearStorage:()=>{u?.removeItem(a.name)},getOptions:()=>a,rehydrate:()=>h(),hasHydrated:()=>o,onHydrate:e=>(c.add(e),()=>{c.delete(e)}),onFinishHydration:e=>(l.add(e),()=>{l.delete(e)})},a.skipHydration||h(),m||p})(e=>({user:null,userId:null,accountStatus:`pending`,hasHydrated:!1,setUser:t=>e({user:t}),setUserId:t=>e({userId:t}),setAccountStatus:t=>e({accountStatus:t}),setHasHydrated:t=>e({hasHydrated:t}),logout:()=>e({user:null,userId:null,accountStatus:`pending`})}),{name:`med-chat-auth`,partialize:e=>({user:e.user,userId:e.userId}),onRehydrateStorage:()=>e=>{e?.setHasHydrated(!0)}})),Zr=[`#1f2937`,`#dc2626`,`#f97316`,`#ca8a04`,`#16a34a`,`#0284c7`,`#7c3aed`,`#db2777`],Qr=[`13px`,`18px`],$r=Object.keys({LIKE:`👍`,LOVE:`❤️`,HAHA:`😂`,WOW:`😮`,SAD:`😢`,ANGRY:`😡`}),ei=()=>({totalCount:0,totalUsers:0,byType:[],mine:null}),ti=e=>e.kind===`VIDEO`&&!!e.thumbnailUrl,ni=e=>e.kind===`AUDIO`,ri=e=>{if(e==null||!Number.isFinite(e)||e<0)return`0:00`;let t=Math.floor(e),n=Math.floor(t/3600),r=Math.floor(t%3600/60),i=String(t%60).padStart(2,`0`);return n>0?`${n}:${String(r).padStart(2,`0`)}:${i}`:`${r}:${i}`},ii={ACTIVE:`ACTIVE`,PENDING:`PENDING`,REJECTED:`REJECTED`};function ai(e,t){return e?.type!==`GROUP`||e.settings?.messagePermission!==`OWNER_ONLY`?!1:t!==`OWNER`}var oi=e=>typeof e==`object`&&e?e:{},si=e=>e==null?void 0:String(e),ci=e=>Array.isArray(e)?e:[],li=[`bold`,`italic`,`underline`,`strike`],ui=e=>{let t=oi(e);return si(t.id??t._id??t.userId)??null},di=e=>{let t=oi(e);return si(t.fullName)??si(t.name)??si(t.displayName)??si(t.account)??si(t.email)??`User`},fi=e=>{let t=String(e??``).trim().split(/\s+/).filter(Boolean);return t.length===0?`?`:t.slice(0,2).map(e=>e.charAt(0).toUpperCase()).join(``)},pi=e=>{let t=oi(e),n=oi(t.data);return Array.isArray(n.items)?n.items:Array.isArray(n.users)?n.users:Array.isArray(t.data)?t.data:Array.isArray(t.items)?t.items:Array.isArray(t.users)?t.users:Array.isArray(e)?e:[]},mi=e=>{let t=oi(e);return Array.isArray(t.data)?t.data:Array.isArray(t.items)?t.items:Array.isArray(e)?e:[]},V=(e,t)=>e!=null&&String(e)===String(t),hi=e=>String(oi(e).type??``).toUpperCase()===`GROUP`,gi=e=>e?`nhóm`:`cuộc trò chuyện`,_i=(e,t)=>{let n=oi(e);return[t[String(n.branchId??``)],si(n.departmentName),si(n.jobTitleName)].filter(Boolean).join(` - `)},vi=(e,t)=>{let n=oi(e);return ci(n.participants??n.members).find(e=>{let n=oi(e),r=si(n.userId)??ui(n.user??e);return!t||r!==t})},yi=(e,t)=>{let n=oi(e),r=`Conversation ${ui(e)??``}`;if(hi(e))return si(n.title)||si(n.name)||r;let i=vi(e,t);return(i?di(oi(i).user??i):``)||si(n.title)||si(n.name)||r},bi=(e,t)=>{let n=oi(e),r=si(n.avatarUrl??n.avatar);if(r)return r;if(hi(e))return null;let i=vi(e,t);if(!i)return null;let a=oi(oi(i).user??i);return si(a.avatarUrl??a.avatar)??null},xi=e=>{let t=oi(oi(e).data??e);return{messages:Array.isArray(t.messages)?t.messages:[],oldestSequence:si(t.oldestSequence)??null,newestSequence:si(t.newestSequence)??null,hasOlderMessages:!!t.hasOlderMessages,hasNewerMessages:!!t.hasNewerMessages,targetMessageId:si(t.targetMessageId)??null}},Si=e=>typeof e==`number`&&Number.isFinite(e)?e:null,Ci=e=>oi(e.attachment??e.mediaAttachment??e.media??ci(e.attachments)[0]),wi=e=>ci(e).reduce((e,t)=>{let n=oi(t),r=si(n.id),i=si(n.url);return!r||!i||e.push({id:r,url:i,name:si(n.originalName??n.name)??null,mimeType:si(n.mimeType)??null,sizeBytes:typeof n.sizeBytes==`number`?n.sizeBytes:null,kind:si(n.kind)??null,thumbnailUrl:si(n.thumbnailUrl)??null,durationMs:Si(n.durationMs),width:Si(n.width),height:Si(n.height)}),e},[]),Ti=e=>typeof e==`string`?e:void 0,Ei=e=>Array.isArray(e)?e.reduce((e,t)=>{let n=oi(t);if(n.type===`text`){let t=String(n.text??``);t&&e.push({type:`text`,text:t})}if(n.type===`mention_all`&&e.push({type:`mention_all`}),n.type===`mention_user`&&n.userId){let t=Ti(n.fallbackName);e.push({type:`mention_user`,userId:String(n.userId),...t===void 0?{}:{fallbackName:t}})}return e},[]):null,Di=e=>typeof e==`string`&&Zr.includes(e),iee=/^rgba?\(\s*(\d{1,3})\s*[,\s]\s*(\d{1,3})\s*[,\s]\s*(\d{1,3})/i,aee=e=>{if(Di(e))return e;if(typeof e!=`string`)return;let t=e.trim().match(iee);if(!t)return;let n=`#${[t[1],t[2],t[3]].map(e=>Number(e).toString(16).padStart(2,`0`)).join(``)}`;return Di(n)?n:void 0},oee=e=>typeof e==`string`&&Qr.includes(e),see=e=>{let t=ci(e).reduce((e,t)=>{let n=oi(t),r=si(n.type);if(r&&li.includes(r))return e.push({type:r}),e;if(n.type===`textStyle`){let t=oi(n.attrs),r=aee(t.color),i=oee(t.fontSize)?t.fontSize:void 0;r&&i?e.push({type:`textStyle`,attrs:{color:r,fontSize:i}}):r?e.push({type:`textStyle`,attrs:{color:r}}):i&&e.push({type:`textStyle`,attrs:{fontSize:i}})}return e},[]);return t.length?t:void 0},cee=e=>{let t=String(e.text??``);if(!t)return null;let n=see(e.marks);return n?{type:`text`,text:t,marks:n}:{type:`text`,text:t}},lee=e=>{if(e.type===`mention`){let t=oi(e.attrs);return{userId:si(t.id),fallbackName:t.fallbackName}}return{userId:si(e.userId),fallbackName:e.fallbackName}},uee=e=>{let{userId:t,fallbackName:n}=lee(e);if(e.type===`mention`&&t===`__mention_all__`)return{type:`mention_all`};if(!t)return null;let r=Ti(n);return r===void 0?{type:`mention_user`,userId:t}:{type:`mention_user`,userId:t,fallbackName:r}},dee=e=>{let t=oi(e);switch(t.type){case`text`:return cee(t);case`hardBreak`:return{type:`hardBreak`};case`mention_all`:return{type:`mention_all`};case`mention_user`:case`mention`:return uee(t);default:return null}},fee=e=>{let t=oi(e);if(t.type!==`paragraph`)return null;let n=ci(t.content).map(dee).filter(e=>e!==null);return n.length?{type:`paragraph`,content:n}:null},pee=e=>{let t=ci(oi(e).content).map(e=>si(oi(e).text)??``).join(``),n=[];return t.split(`
56
56
  `).forEach((e,t)=>{t>0&&n.push({type:`hardBreak`}),e&&n.push({type:`text`,text:e})}),n.length?{type:`paragraph`,content:n}:null},mee=e=>{let t=oi(e);if(t.type!==`listItem`)return null;let n=ci(t.content).map(ki).filter(e=>e!==null);return n.length?{type:`listItem`,content:n}:null},Oi=(e,t)=>{let n=oi(e);if(n.type!==t)return null;let r=ci(n.content).map(mee).filter(e=>e!==null);return r.length?{type:t,content:r}:null};function ki(e){let t=oi(e).type;return t===`paragraph`?fee(e):t===`bulletList`?Oi(e,`bulletList`):t===`orderedList`?Oi(e,`orderedList`):t===`codeBlock`?pee(e):null}var Ai=e=>{let t=oi(e);return t.type===`doc`?{type:`doc`,content:ci(t.content).map(ki).filter(e=>e!==null)}:null},hee=e=>e.type===`text`?e.text.trim().length>0:e.type!==`hardBreak`,ji=e=>e.type===`paragraph`?(e.content??[]).some(hee):e.content.some(ji),Mi=e=>e.content.some(ji),Ni=e=>e.content.length!==1||e.content[0].type!==`paragraph`?!1:(e.content[0].content??[]).every(e=>e.type===`text`&&!e.marks?.length||e.type===`mention_user`||e.type===`mention_all`),Pi=e=>(e.content??[]).flatMap(e=>e.type===`text`?[{type:`text`,text:e.text}]:e.type===`mention_all`?[{type:`mention_all`}]:e.type===`mention_user`?[{type:`mention_user`,userId:e.userId,...e.fallbackName===void 0?{}:{fallbackName:e.fallbackName}}]:[]),Fi=e=>{let t=Ai(e);return!t||!Mi(t)?null:Ni(t)?Pi(t.content[0]):t},Ii=(e,t)=>({type:`text`,text:`@${t??e}`}),Li=(e,t)=>e.map(e=>e.type===`mention_user`&&!t.has(String(e.userId))?Ii(e.userId,e.fallbackName):e),Ri=(e,t)=>e.type===`paragraph`?e.content?{...e,content:Li(e.content,t)}:e:{...e,content:e.content.map(e=>({...e,content:e.content.map(e=>(e.type,Ri(e,t)))}))},zi=(e,t)=>Array.isArray(e)?e.map(e=>e.type===`mention_user`&&!t.has(String(e.userId))?{type:`text`,text:`@${e.fallbackName??e.userId}`}:e):{...e,content:e.content.map(e=>Ri(e,t))},Bi=e=>Array.isArray(e)?Ei(e):Ai(e),Vi=e=>e!=null&&(Array.isArray(e)?e.length>0:Mi(e)),Hi=e=>{let t=oi(e),n=new Map(ci(t.mentionedUsers).map(e=>{let t=e;return[String(t?.userId),t]})),r=Bi(t.content);return Array.isArray(r)?r.map((e,t)=>{if(e.type===`text`)return{key:`text-${t}`,kind:`text`,value:e.text};if(e.type===`mention_all`)return{key:`all-${t}`,kind:`mention_all`,value:`@all`};let r=n.get(String(e.userId));return{key:`user-${e.userId}-${t}`,kind:`mention_user`,userId:e.userId,value:`@${r?.fullName??e.fallbackName??`Unknown user`}`}}):[]},Ui=e=>{switch(e.type){case`text`:return e.text;case`hardBreak`:return`
57
57
  `;case`mention_all`:return`@all`;case`mention_user`:return`@${e.fallbackName??`Unknown user`}`}},Wi=e=>e.type===`paragraph`?(e.content??[]).map(Ui).join(``):e.content.map(Wi).join(`
58
- `),Gi=3e3,Ki=e=>{let t=Bi(oi(e).content);return Array.isArray(t)?Hi(e).map(e=>e.value).join(``):t?Wi(t):``},qi=`(?:\\p{Emoji_Presentation}|\\p{Emoji}\\uFE0F)\\p{Emoji_Modifier}?`,Ji=RegExp(`^(?:\\p{Regional_Indicator}{2}|${qi}(?:\\u200D${qi})*)$`,`u`),Yi=e=>{if(e.type!==`TEXT`)return!1;let t=Ki(e).trim();return t.length>0&&Ji.test(t)},Xi=e=>Hi(e).map(e=>e.kind===`mention_user`?e.value.replace(/^@/,``):e.value).join(``),Zi=e=>{let t=oi(e),n=si(t.id);if(!n)return null;let r={id:n,senderId:si(t.senderId)??``,senderName:si(t.senderName)??``,type:si(t.type)??`TEXT`,content:Bi(t.content),attachmentName:si(t.attachmentName)??null,attachmentUrl:si(t.attachmentUrl)??null,attachmentKind:si(t.attachmentKind)??null,attachmentThumbnailUrl:si(t.attachmentThumbnailUrl)??null,createdAt:si(t.createdAt)??null,removedAt:si(t.removedAt)??null,removedById:si(t.removedById)??null};return $i(r)?ea(r,r):r},Qi=e=>e.sourceMessageId?{...e,id:e.sourceMessageId}:e,$i=e=>!!e.removedAt,ea=(e,t)=>({...e,content:null,attachmentName:null,attachmentUrl:null,removedAt:e.removedAt??t.removedAt,removedById:e.removedById??t.removedById}),ta=(e,t)=>({...e,content:null,mentionsAll:!1,mentionedUserIds:[],mentionedUsers:[],attachmentId:null,attachmentName:null,attachmentMimeType:null,attachmentUrl:null,attachmentSizeBytes:null,attachments:[],attachmentIds:[],reactionSummary:ei(),pinnedAt:null,pinnedById:null,pinnedByName:null,pinnedByAvatarUrl:null,removedAt:e.removedAt??t.removedAt,removedById:e.removedById??t.removedById,previewUrl:void 0,previewUrls:void 0}),na=e=>typeof e==`string`&&$r.includes(e),ra=e=>e===`SENDER_RECALL`||e===`OWNER_MODERATION`?e:null,ia=e=>{let t=oi(e),n=ci(t.byType).reduce((e,t)=>{let n=oi(t);return na(n.type)&&e.push({type:n.type,count:typeof n.count==`number`?n.count:0,userCount:typeof n.userCount==`number`?n.userCount:0}),e},[]),r=oi(t.mine),i=na(r.type)?{type:r.type,count:typeof r.count==`number`?r.count:0}:null;return{totalCount:typeof t.totalCount==`number`?t.totalCount:0,totalUsers:typeof t.totalUsers==`number`?t.totalUsers:0,byType:n,mine:i}},aa=(e,t)=>{let n=oi(e),r=Ci(n),i={id:si(n.id??n._id??n.messageId??n.clientMessageId),sourceMessageId:si(n.sourceMessageId),clientMessageId:si(n.clientMessageId),conversationId:si(n.conversationId)??t,content:Bi(n.content),mentionsAll:!!n.mentionsAll,mentionedUserIds:ci(n.mentionedUserIds).map(String),mentionedUsers:ci(n.mentionedUsers),senderId:si(n.senderId??n.userId??n.authorId),senderName:si(n.senderName),senderAvatarUrl:si(n.senderAvatarUrl)??null,searchSnippet:si(n.searchSnippet)??null,searchSnippetTruncatedStart:!!n.searchSnippetTruncatedStart,searchSnippetTruncatedEnd:!!n.searchSnippetTruncatedEnd,sequence:si(n.sequence),createdAt:si(n.createdAt)??new Date().toISOString(),status:si(n.status)??`sent`,type:si(n.type)??`TEXT`,systemCategory:si(n.systemCategory)??null,systemMemberCount:typeof n.systemMemberCount==`number`?n.systemMemberCount:null,attachmentId:si(n.attachmentId??n.mediaId??r.id??r.mediaId)??null,attachmentName:si(r.originalName)??null,attachmentKind:si(n.attachmentKind??r.kind)??null,attachmentMimeType:si(n.attachmentMimeType??n.mimeType??r.mimeType??r.type)??null,attachmentUrl:si(n.attachmentUrl??r.url)??null,attachmentSizeBytes:typeof r.sizeBytes==`number`?r.sizeBytes:typeof n.attachmentSizeBytes==`number`?n.attachmentSizeBytes:null,attachments:wi(n.attachments),replyToId:si(n.replyToId)??null,replyTo:Zi(n.replyTo),reactionSummary:ia(n.reactionSummary),pinnedAt:si(n.pinnedAt)??null,pinnedById:si(n.pinnedById)??null,pinnedByName:si(n.pinnedByName)??null,pinnedByAvatarUrl:si(n.pinnedByAvatarUrl)??null,removedAt:si(n.removedAt)??null,removedById:si(n.removedById)??null,removalType:ra(n.removalType)};return $i(i)?ta(i,i):i},oa=e=>{if(!e||e<=0)return``;let t=[`B`,`KB`,`MB`,`GB`],n=e,r=0;for(;n>=1024&&r<t.length-1;)n/=1024,r+=1;return`${n.toFixed(r===0?0:1)} ${t[r]}`},sa=(e,t)=>V(e.conversationId??``,t.conversationId??``)?[[e.clientMessageId,t.clientMessageId],[e.id,t.id],[e.sequence,t.sequence]].some(([e,t])=>t!=null&&V(e,t)):!1,ca=e=>{let t=String(e??``);return/^\d+$/.test(t)?BigInt(t):null},la=e=>[...e].sort((e,t)=>{let n=ca(e.sequence),r=ca(t.sequence);return n===null&&r===null?0:n===null?1:r===null?-1:n===r?0:n<r?-1:1}),ua=(e,t)=>{let n=e.findIndex(e=>sa(e,t));return n===-1?[...e,t]:e.map((e,r)=>{if(r!==n)return e;if($i(e))return ta(e,e);let i={...e,...t};return $i(t)?ta(i,t):i})},da=(e,t)=>la((Array.isArray(t)?t:[]).reduce((e,t)=>ua(e,t),e)),fa=/[̀-ͯ]/g;function pa(e){return e.toLocaleLowerCase(`vi`).normalize(`NFD`).replace(fa,``).replace(/đ/g,`d`)}var ma=Object.create(null);ma.open=`0`,ma.close=`1`,ma.ping=`2`,ma.pong=`3`,ma.message=`4`,ma.upgrade=`5`,ma.noop=`6`;var ha=Object.create(null);Object.keys(ma).forEach(e=>{ha[ma[e]]=e});var ga={type:`error`,data:`parser error`},_a=typeof Blob==`function`||typeof Blob<`u`&&Object.prototype.toString.call(Blob)===`[object BlobConstructor]`,va=typeof ArrayBuffer==`function`,ya=e=>typeof ArrayBuffer.isView==`function`?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,ba=({type:e,data:t},n,r)=>_a&&t instanceof Blob?n?r(t):xa(t,r):va&&(t instanceof ArrayBuffer||ya(t))?n?r(t):xa(new Blob([t]),r):r(ma[e]+(t||``)),xa=(e,t)=>{let n=new FileReader;return n.onload=function(){let e=n.result.split(`,`)[1];t(`b`+(e||``))},n.readAsDataURL(e)};function Sa(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}var Ca;function wa(e,t){if(_a&&e.data instanceof Blob)return e.data.arrayBuffer().then(Sa).then(t);if(va&&(e.data instanceof ArrayBuffer||ya(e.data)))return t(Sa(e.data));ba(e,!1,e=>{Ca||=new TextEncoder,t(Ca.encode(e))})}var Ta=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/`,Ea=typeof Uint8Array>`u`?[]:new Uint8Array(256);for(let e=0;e<64;e++)Ea[Ta.charCodeAt(e)]=e;var gee=e=>{let t=e.length*.75,n=e.length,r,i=0,a,o,s,c;e[e.length-1]===`=`&&(t--,e[e.length-2]===`=`&&t--);let l=new ArrayBuffer(t),u=new Uint8Array(l);for(r=0;r<n;r+=4)a=Ea[e.charCodeAt(r)],o=Ea[e.charCodeAt(r+1)],s=Ea[e.charCodeAt(r+2)],c=Ea[e.charCodeAt(r+3)],u[i++]=a<<2|o>>4,u[i++]=(o&15)<<4|s>>2,u[i++]=(s&3)<<6|c&63;return l},_ee=typeof ArrayBuffer==`function`,Da=(e,t)=>{if(typeof e!=`string`)return{type:`message`,data:Oa(e,t)};let n=e.charAt(0);return n===`b`?{type:`message`,data:vee(e.substring(1),t)}:ha[n]?e.length>1?{type:ha[n],data:e.substring(1)}:{type:ha[n]}:ga},vee=(e,t)=>_ee?Oa(gee(e),t):{base64:!0,data:e},Oa=(e,t)=>{switch(t){case`blob`:return e instanceof Blob?e:new Blob([e]);default:return e instanceof ArrayBuffer?e:e.buffer}},ka=``,yee=(e,t)=>{let n=e.length,r=Array(n),i=0;e.forEach((e,a)=>{ba(e,!1,e=>{r[a]=e,++i===n&&t(r.join(ka))})})},bee=(e,t)=>{let n=e.split(ka),r=[];for(let e=0;e<n.length;e++){let i=Da(n[e],t);if(r.push(i),i.type===`error`)break}return r};function xee(){return new TransformStream({transform(e,t){wa(e,n=>{let r=n.length,i;if(r<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,r);else if(r<65536){i=new Uint8Array(3);let e=new DataView(i.buffer);e.setUint8(0,126),e.setUint16(1,r)}else{i=new Uint8Array(9);let e=new DataView(i.buffer);e.setUint8(0,127),e.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!=`string`&&(i[0]|=128),t.enqueue(i),t.enqueue(n)})}})}var Aa;function ja(e){return e.reduce((e,t)=>e+t.length,0)}function Ma(e,t){if(e[0].length===t)return e.shift();let n=new Uint8Array(t),r=0;for(let i=0;i<t;i++)n[i]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function See(e,t){Aa||=new TextDecoder;let n=[],r=0,i=-1,a=!1;return new TransformStream({transform(o,s){for(n.push(o);;){if(r===0){if(ja(n)<1)break;let e=Ma(n,1);a=(e[0]&128)==128,i=e[0]&127,r=i<126?3:i===126?1:2}else if(r===1){if(ja(n)<2)break;let e=Ma(n,2);i=new DataView(e.buffer,e.byteOffset,e.length).getUint16(0),r=3}else if(r===2){if(ja(n)<8)break;let e=Ma(n,8),t=new DataView(e.buffer,e.byteOffset,e.length),a=t.getUint32(0);if(a>2**21-1){s.enqueue(ga);break}i=a*2**32+t.getUint32(4),r=3}else{if(ja(n)<i)break;let e=Ma(n,i);s.enqueue(Da(a?e:Aa.decode(e),t)),r=0}if(i===0||i>e){s.enqueue(ga);break}}}})}function Na(e){if(e)return Cee(e)}function Cee(e){for(var t in Na.prototype)e[t]=Na.prototype[t];return e}Na.prototype.on=Na.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks[`$`+e]=this._callbacks[`$`+e]||[]).push(t),this},Na.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},Na.prototype.off=Na.prototype.removeListener=Na.prototype.removeAllListeners=Na.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks[`$`+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks[`$`+e],this;for(var r,i=0;i<n.length;i++)if(r=n[i],r===t||r.fn===t){n.splice(i,1);break}return n.length===0&&delete this._callbacks[`$`+e],this},Na.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=Array(arguments.length-1),n=this._callbacks[`$`+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){n=n.slice(0);for(var r=0,i=n.length;r<i;++r)n[r].apply(this,t)}return this},Na.prototype.emitReserved=Na.prototype.emit,Na.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks[`$`+e]||[]},Na.prototype.hasListeners=function(e){return!!this.listeners(e).length};var Pa=typeof Promise==`function`&&typeof Promise.resolve==`function`?e=>Promise.resolve().then(e):(e,t)=>t(e,0),Fa=typeof self<`u`?self:typeof window<`u`?window:Function(`return this`)(),wee=`arraybuffer`;function Ia(e,...t){return t.reduce((t,n)=>(e.hasOwnProperty(n)&&(t[n]=e[n]),t),{})}var Tee=Fa.setTimeout,Eee=Fa.clearTimeout;function La(e,t){t.useNativeTimers?(e.setTimeoutFn=Tee.bind(Fa),e.clearTimeoutFn=Eee.bind(Fa)):(e.setTimeoutFn=Fa.setTimeout.bind(Fa),e.clearTimeoutFn=Fa.clearTimeout.bind(Fa))}var Dee=1.33;function Oee(e){return typeof e==`string`?kee(e):Math.ceil((e.byteLength||e.size)*Dee)}function kee(e){let t=0,n=0;for(let r=0,i=e.length;r<i;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}function Ra(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function Aee(e){let t=``;for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+=`&`),t+=encodeURIComponent(n)+`=`+encodeURIComponent(e[n]));return t}function jee(e){let t={},n=e.split(`&`);for(let e=0,r=n.length;e<r;e++){let r=n[e].split(`=`);t[decodeURIComponent(r[0])]=decodeURIComponent(r[1])}return t}var Mee=class extends Error{constructor(e,t,n){super(e),this.description=t,this.context=n,this.type=`TransportError`}},za=class extends Na{constructor(e){super(),this.writable=!1,La(this,e),this.opts=e,this.query=e.query,this.socket=e.socket,this.supportsBinary=!e.forceBase64}onError(e,t,n){return super.emitReserved(`error`,new Mee(e,t,n)),this}open(){return this.readyState=`opening`,this.doOpen(),this}close(){return(this.readyState===`opening`||this.readyState===`open`)&&(this.doClose(),this.onClose()),this}send(e){this.readyState===`open`&&this.write(e)}onOpen(){this.readyState=`open`,this.writable=!0,super.emitReserved(`open`)}onData(e){let t=Da(e,this.socket.binaryType);this.onPacket(t)}onPacket(e){super.emitReserved(`packet`,e)}onClose(e){this.readyState=`closed`,super.emitReserved(`close`,e)}pause(e){}createUri(e,t={}){return e+`://`+this._hostname()+this._port()+this.opts.path+this._query(t)}_hostname(){let e=this.opts.hostname;return e.indexOf(`:`)===-1?e:`[`+e+`]`}_port(){return this.opts.port&&(this.opts.secure&&Number(this.opts.port)!==443||!this.opts.secure&&Number(this.opts.port)!==80)?`:`+this.opts.port:``}_query(e){let t=Aee(e);return t.length?`?`+t:``}},Nee=class extends za{constructor(){super(...arguments),this._polling=!1}get name(){return`polling`}doOpen(){this._poll()}pause(e){this.readyState=`pausing`;let t=()=>{this.readyState=`paused`,e()};if(this._polling||!this.writable){let e=0;this._polling&&(e++,this.once(`pollComplete`,function(){--e||t()})),this.writable||(e++,this.once(`drain`,function(){--e||t()}))}else t()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved(`poll`)}onData(e){bee(e,this.socket.binaryType).forEach(e=>{if(this.readyState===`opening`&&e.type===`open`&&this.onOpen(),e.type===`close`)return this.onClose({description:`transport closed by the server`}),!1;this.onPacket(e)}),this.readyState!==`closed`&&(this._polling=!1,this.emitReserved(`pollComplete`),this.readyState===`open`&&this._poll())}doClose(){let e=()=>{this.write([{type:`close`}])};this.readyState===`open`?e():this.once(`open`,e)}write(e){this.writable=!1,yee(e,e=>{this.doWrite(e,()=>{this.writable=!0,this.emitReserved(`drain`)})})}uri(){let e=this.opts.secure?`https`:`http`,t=this.query||{};return!1!==this.opts.timestampRequests&&(t[this.opts.timestampParam]=Ra()),!this.supportsBinary&&!t.sid&&(t.b64=1),this.createUri(e,t)}},Ba=!1;try{Ba=typeof XMLHttpRequest<`u`&&`withCredentials`in new XMLHttpRequest}catch{}var Pee=Ba;function Fee(){}var Iee=class extends Nee{constructor(e){if(super(e),typeof location<`u`){let t=location.protocol===`https:`,n=location.port;n||=t?`443`:`80`,this.xd=typeof location<`u`&&e.hostname!==location.hostname||n!==e.port}}doWrite(e,t){let n=this.request({method:`POST`,data:e});n.on(`success`,t),n.on(`error`,(e,t)=>{this.onError(`xhr post error`,e,t)})}doPoll(){let e=this.request();e.on(`data`,this.onData.bind(this)),e.on(`error`,(e,t)=>{this.onError(`xhr poll error`,e,t)}),this.pollXhr=e}},Va=class e extends Na{constructor(e,t,n){super(),this.createRequest=e,La(this,n),this._opts=n,this._method=n.method||`GET`,this._uri=t,this._data=n.data===void 0?null:n.data,this._create()}_create(){var t;let n=Ia(this._opts,`agent`,`pfx`,`key`,`passphrase`,`cert`,`ca`,`ciphers`,`rejectUnauthorized`,`autoUnref`);n.xdomain=!!this._opts.xd;let r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let e in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(e)&&r.setRequestHeader(e,this._opts.extraHeaders[e])}}catch{}if(this._method===`POST`)try{r.setRequestHeader(`Content-type`,`text/plain;charset=UTF-8`)}catch{}try{r.setRequestHeader(`Accept`,`*/*`)}catch{}(t=this._opts.cookieJar)==null||t.addCookies(r),`withCredentials`in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var e;r.readyState===3&&((e=this._opts.cookieJar)==null||e.parseCookies(r.getResponseHeader(`set-cookie`))),r.readyState===4&&(r.status===200||r.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof r.status==`number`?r.status:0)},0))},r.send(this._data)}catch(e){this.setTimeoutFn(()=>{this._onError(e)},0);return}typeof document<`u`&&(this._index=e.requestsCount++,e.requests[this._index]=this)}_onError(e){this.emitReserved(`error`,e,this._xhr),this._cleanup(!0)}_cleanup(t){if(this._xhr!==void 0&&this._xhr!==null){if(this._xhr.onreadystatechange=Fee,t)try{this._xhr.abort()}catch{}typeof document<`u`&&delete e.requests[this._index],this._xhr=null}}_onLoad(){let e=this._xhr.responseText;e!==null&&(this.emitReserved(`data`,e),this.emitReserved(`success`),this._cleanup())}abort(){this._cleanup()}};if(Va.requestsCount=0,Va.requests={},typeof document<`u`){if(typeof attachEvent==`function`)attachEvent(`onunload`,Ha);else if(typeof addEventListener==`function`){let e=`onpagehide`in Fa?`pagehide`:`unload`;addEventListener(e,Ha,!1)}}function Ha(){for(let e in Va.requests)Va.requests.hasOwnProperty(e)&&Va.requests[e].abort()}var Ua=(function(){let e=Ga({xdomain:!1});return e&&e.responseType!==null})(),Wa=class extends Iee{constructor(e){super(e);let t=e&&e.forceBase64;this.supportsBinary=Ua&&!t}request(e={}){return Object.assign(e,{xd:this.xd},this.opts),new Va(Ga,this.uri(),e)}};function Ga(e){let t=e.xdomain;try{if(typeof XMLHttpRequest<`u`&&(!t||Pee))return new XMLHttpRequest}catch{}if(!t)try{return new Fa[[`Active`,`Object`].join(`X`)](`Microsoft.XMLHTTP`)}catch{}}var Ka=typeof navigator<`u`&&typeof navigator.product==`string`&&navigator.product.toLowerCase()===`reactnative`,qa=class extends za{get name(){return`websocket`}doOpen(){let e=this.uri(),t=this.opts.protocols,n=Ka?{}:Ia(this.opts,`agent`,`perMessageDeflate`,`pfx`,`key`,`passphrase`,`cert`,`ca`,`ciphers`,`rejectUnauthorized`,`localAddress`,`protocolVersion`,`origin`,`maxPayload`,`family`,`checkServerIdentity`);this.opts.extraHeaders&&(n.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(e,t,n)}catch(e){return this.emitReserved(`error`,e)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=e=>this.onClose({description:`websocket connection closed`,context:e}),this.ws.onmessage=e=>this.onData(e.data),this.ws.onerror=e=>this.onError(`websocket error`,e)}write(e){this.writable=!1;for(let t=0;t<e.length;t++){let n=e[t],r=t===e.length-1;ba(n,this.supportsBinary,e=>{try{this.doWrite(n,e)}catch{}r&&Pa(()=>{this.writable=!0,this.emitReserved(`drain`)},this.setTimeoutFn)})}}doClose(){this.ws!==void 0&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){let e=this.opts.secure?`wss`:`ws`,t=this.query||{};return this.opts.timestampRequests&&(t[this.opts.timestampParam]=Ra()),this.supportsBinary||(t.b64=1),this.createUri(e,t)}},Ja=Fa.WebSocket||Fa.MozWebSocket,Ya={websocket:class extends qa{createSocket(e,t,n){return Ka?new Ja(e,t,n):t?new Ja(e,t):new Ja(e)}doWrite(e,t){this.ws.send(t)}},webtransport:class extends za{get name(){return`webtransport`}doOpen(){try{this._transport=new WebTransport(this.createUri(`https`),this.opts.transportOptions[this.name])}catch(e){return this.emitReserved(`error`,e)}this._transport.closed.then(()=>{this.onClose()}).catch(e=>{this.onError(`webtransport error`,e)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(e=>{let t=See(2**53-1,this.socket.binaryType),n=e.readable.pipeThrough(t).getReader(),r=xee();r.readable.pipeTo(e.writable),this._writer=r.writable.getWriter();let i=()=>{n.read().then(({done:e,value:t})=>{e||(this.onPacket(t),i())}).catch(e=>{})};i();let a={type:`open`};this.query.sid&&(a.data=`{"sid":"${this.query.sid}"}`),this._writer.write(a).then(()=>this.onOpen())})})}write(e){this.writable=!1;for(let t=0;t<e.length;t++){let n=e[t],r=t===e.length-1;this._writer.write(n).then(()=>{r&&Pa(()=>{this.writable=!0,this.emitReserved(`drain`)},this.setTimeoutFn)})}}doClose(){var e;(e=this._transport)==null||e.close()}},polling:Wa},Xa=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Za=[`source`,`protocol`,`authority`,`userInfo`,`user`,`password`,`host`,`port`,`relative`,`path`,`directory`,`file`,`query`,`anchor`];function Qa(e){if(e.length>8e3)throw`URI too long`;let t=e,n=e.indexOf(`[`),r=e.indexOf(`]`);n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,`;`)+e.substring(r,e.length));let i=Xa.exec(e||``),a={},o=14;for(;o--;)a[Za[o]]=i[o]||``;return n!=-1&&r!=-1&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,`:`),a.authority=a.authority.replace(`[`,``).replace(`]`,``).replace(/;/g,`:`),a.ipv6uri=!0),a.pathNames=$a(a,a.path),a.queryKey=eo(a,a.query),a}function $a(e,t){let n=t.replace(/\/{2,9}/g,`/`).split(`/`);return(t.slice(0,1)==`/`||t.length===0)&&n.splice(0,1),t.slice(-1)==`/`&&n.splice(n.length-1,1),n}function eo(e,t){let n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(e,t,r){t&&(n[t]=r)}),n}var to=typeof addEventListener==`function`&&typeof removeEventListener==`function`,no=[];to&&addEventListener(`offline`,()=>{no.forEach(e=>e())},!1);var ro=class e extends Na{constructor(e,t){if(super(),this.binaryType=wee,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,e&&typeof e==`object`&&(t=e,e=null),e){let n=Qa(e);t.hostname=n.host,t.secure=n.protocol===`https`||n.protocol===`wss`,t.port=n.port,n.query&&(t.query=n.query)}else t.host&&(t.hostname=Qa(t.host).host);La(this,t),this.secure=t.secure==null?typeof location<`u`&&location.protocol===`https:`:t.secure,t.hostname&&!t.port&&(t.port=this.secure?`443`:`80`),this.hostname=t.hostname||(typeof location<`u`?location.hostname:`localhost`),this.port=t.port||(typeof location<`u`&&location.port?location.port:this.secure?`443`:`80`),this.transports=[],this._transportsByName={},t.transports.forEach(e=>{let t=e.prototype.name;this.transports.push(t),this._transportsByName[t]=e}),this.opts=Object.assign({path:`/engine.io`,agent:!1,withCredentials:!1,upgrade:!0,timestampParam:`t`,rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},t),this.opts.path=this.opts.path.replace(/\/$/,``)+(this.opts.addTrailingSlash?`/`:``),typeof this.opts.query==`string`&&(this.opts.query=jee(this.opts.query)),to&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener(`beforeunload`,this._beforeunloadEventListener,!1)),this.hostname!==`localhost`&&(this._offlineEventListener=()=>{this._onClose(`transport close`,{description:`network connection lost`})},no.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(e){let t=Object.assign({},this.opts.query);t.EIO=4,t.transport=e,this.id&&(t.sid=this.id);let n=Object.assign({},this.opts,{query:t,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[e]);return new this._transportsByName[e](n)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved(`error`,`No transports available`)},0);return}let t=this.opts.rememberUpgrade&&e.priorWebsocketSuccess&&this.transports.indexOf(`websocket`)!==-1?`websocket`:this.transports[0];this.readyState=`opening`;let n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(e){this.transport&&this.transport.removeAllListeners(),this.transport=e,e.on(`drain`,this._onDrain.bind(this)).on(`packet`,this._onPacket.bind(this)).on(`error`,this._onError.bind(this)).on(`close`,e=>this._onClose(`transport close`,e))}onOpen(){this.readyState=`open`,e.priorWebsocketSuccess=this.transport.name===`websocket`,this.emitReserved(`open`),this.flush()}_onPacket(e){if(this.readyState===`opening`||this.readyState===`open`||this.readyState===`closing`)switch(this.emitReserved(`packet`,e),this.emitReserved(`heartbeat`),e.type){case`open`:this.onHandshake(JSON.parse(e.data));break;case`ping`:this._sendPacket(`pong`),this.emitReserved(`ping`),this.emitReserved(`pong`),this._resetPingTimeout();break;case`error`:let t=Error(`server error`);t.code=e.data,this._onError(t);break;case`message`:this.emitReserved(`data`,e.data),this.emitReserved(`message`,e.data)}}onHandshake(e){this.emitReserved(`handshake`,e),this.id=e.sid,this.transport.query.sid=e.sid,this._pingInterval=e.pingInterval,this._pingTimeout=e.pingTimeout,this._maxPayload=e.maxPayload,this.onOpen(),this.readyState!==`closed`&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);let e=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+e,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose(`ping timeout`)},e),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved(`drain`):this.flush()}flush(){if(this.readyState!==`closed`&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){let e=this._getWritablePackets();this.transport.send(e),this._prevBufferLen=e.length,this.emitReserved(`flush`)}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name===`polling`&&this.writeBuffer.length>1))return this.writeBuffer;let e=1;for(let t=0;t<this.writeBuffer.length;t++){let n=this.writeBuffer[t].data;if(n&&(e+=Oee(n)),t>0&&e>this._maxPayload)return this.writeBuffer.slice(0,t);e+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;let e=Date.now()>this._pingTimeoutTime;return e&&(this._pingTimeoutTime=0,Pa(()=>{this._onClose(`ping timeout`)},this.setTimeoutFn)),e}write(e,t,n){return this._sendPacket(`message`,e,t,n),this}send(e,t,n){return this._sendPacket(`message`,e,t,n),this}_sendPacket(e,t,n,r){if(typeof t==`function`&&(r=t,t=void 0),typeof n==`function`&&(r=n,n=null),this.readyState===`closing`||this.readyState===`closed`)return;n||={},n.compress=!1!==n.compress;let i={type:e,data:t,options:n};this.emitReserved(`packetCreate`,i),this.writeBuffer.push(i),r&&this.once(`flush`,r),this.flush()}close(){let e=()=>{this._onClose(`forced close`),this.transport.close()},t=()=>{this.off(`upgrade`,t),this.off(`upgradeError`,t),e()},n=()=>{this.once(`upgrade`,t),this.once(`upgradeError`,t)};return(this.readyState===`opening`||this.readyState===`open`)&&(this.readyState=`closing`,this.writeBuffer.length?this.once(`drain`,()=>{this.upgrading?n():e()}):this.upgrading?n():e()),this}_onError(t){if(e.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState===`opening`)return this.transports.shift(),this._open();this.emitReserved(`error`,t),this._onClose(`transport error`,t)}_onClose(e,t){if(this.readyState===`opening`||this.readyState===`open`||this.readyState===`closing`){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners(`close`),this.transport.close(),this.transport.removeAllListeners(),to&&(this._beforeunloadEventListener&&removeEventListener(`beforeunload`,this._beforeunloadEventListener,!1),this._offlineEventListener)){let e=no.indexOf(this._offlineEventListener);e!==-1&&no.splice(e,1)}this.readyState=`closed`,this.id=null,this.emitReserved(`close`,e,t),this.writeBuffer=[],this._prevBufferLen=0}}};ro.protocol=4;var io=class extends ro{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState===`open`&&this.opts.upgrade)for(let e=0;e<this._upgrades.length;e++)this._probe(this._upgrades[e])}_probe(e){let t=this.createTransport(e),n=!1;ro.priorWebsocketSuccess=!1;let r=()=>{n||(t.send([{type:`ping`,data:`probe`}]),t.once(`packet`,e=>{if(!n)if(e.type===`pong`&&e.data===`probe`){if(this.upgrading=!0,this.emitReserved(`upgrading`,t),!t)return;ro.priorWebsocketSuccess=t.name===`websocket`,this.transport.pause(()=>{n||this.readyState!==`closed`&&(l(),this.setTransport(t),t.send([{type:`upgrade`}]),this.emitReserved(`upgrade`,t),t=null,this.upgrading=!1,this.flush())})}else{let e=Error(`probe error`);e.transport=t.name,this.emitReserved(`upgradeError`,e)}}))};function i(){n||(n=!0,l(),t.close(),t=null)}let a=e=>{let n=Error(`probe error: `+e);n.transport=t.name,i(),this.emitReserved(`upgradeError`,n)};function o(){a(`transport closed`)}function s(){a(`socket closed`)}function c(e){t&&e.name!==t.name&&i()}let l=()=>{t.removeListener(`open`,r),t.removeListener(`error`,a),t.removeListener(`close`,o),this.off(`close`,s),this.off(`upgrading`,c)};t.once(`open`,r),t.once(`error`,a),t.once(`close`,o),this.once(`close`,s),this.once(`upgrading`,c),this._upgrades.indexOf(`webtransport`)!==-1&&e!==`webtransport`?this.setTimeoutFn(()=>{n||t.open()},200):t.open()}onHandshake(e){this._upgrades=this._filterUpgrades(e.upgrades),super.onHandshake(e)}_filterUpgrades(e){let t=[];for(let n=0;n<e.length;n++)~this.transports.indexOf(e[n])&&t.push(e[n]);return t}},ao=class extends io{constructor(e,t={}){let n=typeof e==`object`,r=n?{...e}:{...t};(!r.transports||r.transports&&typeof r.transports[0]==`string`)&&(r.transports=(r.transports||[`polling`,`websocket`,`webtransport`]).map(e=>Ya[e]).filter(e=>!!e)),super(n?r:e,r)}};ao.protocol;function oo(e,t=``,n){let r=e;n||=typeof location<`u`&&location,e??=n.protocol+`//`+n.host,typeof e==`string`&&(e.charAt(0)===`/`&&(e=e.charAt(1)===`/`?n.protocol+e:n.host+e),/^(https?|wss?):\/\//.test(e)||(e=n===void 0?`https://`+e:n.protocol+`//`+e),r=Qa(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port=`80`:/^(http|ws)s$/.test(r.protocol)&&(r.port=`443`)),r.path=r.path||`/`;let i=r.host.indexOf(`:`)===-1?r.host:`[`+r.host+`]`;return r.id=r.protocol+`://`+i+`:`+r.port+t,r.href=r.protocol+`://`+i+(n&&n.port===r.port?``:`:`+r.port),r}var so=typeof ArrayBuffer==`function`,co=e=>typeof ArrayBuffer.isView==`function`?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,lo=Object.prototype.toString,uo=typeof Blob==`function`||typeof Blob<`u`&&lo.call(Blob)===`[object BlobConstructor]`,fo=typeof File==`function`||typeof File<`u`&&lo.call(File)===`[object FileConstructor]`;function po(e){return so&&(e instanceof ArrayBuffer||co(e))||uo&&e instanceof Blob||fo&&e instanceof File}function mo(e,t){if(!e||typeof e!=`object`)return!1;if(Array.isArray(e)){for(let t=0,n=e.length;t<n;t++)if(mo(e[t]))return!0;return!1}if(po(e))return!0;if(e.toJSON&&typeof e.toJSON==`function`&&arguments.length===1)return mo(e.toJSON(),!0);for(let t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&mo(e[t]))return!0;return!1}function ho(e){let t=[],n=e.data,r=e;return r.data=go(n,t),r.attachments=t.length,{packet:r,buffers:t}}function go(e,t,n){if(!e)return e;if(po(e)){let n={_placeholder:!0,num:t.length};return t.push(e),n}if(Array.isArray(e)){let n=Array(e.length);for(let r=0;r<e.length;r++)n[r]=go(e[r],t);return n}if(typeof e==`object`&&!(e instanceof Date)){if(e.toJSON&&typeof e.toJSON==`function`&&!n)return go(e.toJSON(),t,!0);let r={};for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&(r[n]=go(e[n],t));return r}return e}function _o(e,t){return e.data=vo(e.data,t),delete e.attachments,e}function vo(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num==`number`&&e.num>=0&&e.num<t.length)return t[e.num];throw Error(`illegal attachments`)}if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=vo(e[n],t);else if(typeof e==`object`)for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=vo(e[n],t));return e}var yo=s({Decoder:()=>Co,Encoder:()=>So,PacketType:()=>xo,isPacketValid:()=>Ao,protocol:()=>5}),bo=[`connect`,`connect_error`,`disconnect`,`disconnecting`,`newListener`,`removeListener`],xo;(function(e){e[e.CONNECT=0]=`CONNECT`,e[e.DISCONNECT=1]=`DISCONNECT`,e[e.EVENT=2]=`EVENT`,e[e.ACK=3]=`ACK`,e[e.CONNECT_ERROR=4]=`CONNECT_ERROR`,e[e.BINARY_EVENT=5]=`BINARY_EVENT`,e[e.BINARY_ACK=6]=`BINARY_ACK`})(xo||={});var So=class{constructor(e){this.replacer=e}encode(e){return(e.type===xo.EVENT||e.type===xo.ACK)&&mo(e)?this.encodeAsBinary({type:e.type===xo.EVENT?xo.BINARY_EVENT:xo.BINARY_ACK,nsp:e.nsp,data:e.data,id:e.id}):[this.encodeAsString(e)]}encodeAsString(e){let t=``+e.type;return(e.type===xo.BINARY_EVENT||e.type===xo.BINARY_ACK)&&(t+=e.attachments+`-`),e.nsp&&e.nsp!==`/`&&(t+=e.nsp+`,`),e.id!=null&&(t+=e.id),e.data!=null&&(t+=JSON.stringify(e.data,this.replacer)),t}encodeAsBinary(e){let t=ho(e),n=this.encodeAsString(t.packet),r=t.buffers;return r.unshift(n),r}},Co=class e extends Na{constructor(e){super(),this.opts=Object.assign({reviver:void 0,maxAttachments:10},typeof e==`function`?{reviver:e}:e)}add(e){let t;if(typeof e==`string`){if(this.reconstructor)throw Error(`got plaintext data when reconstructing a packet`);t=this.decodeString(e);let n=t.type===xo.BINARY_EVENT;n||t.type===xo.BINARY_ACK?(t.type=n?xo.EVENT:xo.ACK,this.reconstructor=new wo(t)):super.emitReserved(`decoded`,t)}else if(po(e)||e.base64)if(this.reconstructor)t=this.reconstructor.takeBinaryData(e),t&&(this.reconstructor=null,super.emitReserved(`decoded`,t));else throw Error(`got binary data when not reconstructing a packet`);else throw Error(`Unknown type: `+e)}decodeString(t){let n=0,r={type:Number(t.charAt(0))};if(xo[r.type]===void 0)throw Error(`unknown packet type `+r.type);if(r.type===xo.BINARY_EVENT||r.type===xo.BINARY_ACK){let e=n+1;for(;t.charAt(++n)!==`-`&&n!=t.length;);let i=t.substring(e,n);if(i!=Number(i)||t.charAt(n)!==`-`)throw Error(`Illegal attachments`);let a=Number(i);if(!Eo(a)||a<1)throw Error(`Illegal attachments`);if(a>this.opts.maxAttachments)throw Error(`too many attachments`);r.attachments=a}if(t.charAt(n+1)===`/`){let e=n+1;for(;++n&&t.charAt(n)!==`,`&&n!==t.length;);r.nsp=t.substring(e,n)}else r.nsp=`/`;let i=t.charAt(n+1);if(i!==``&&Number(i)==i){let e=n+1;for(;++n;){let e=t.charAt(n);if(e==null||Number(e)!=e){--n;break}if(n===t.length)break}r.id=Number(t.substring(e,n+1))}if(t.charAt(++n)){let i=this.tryParse(t.substr(n));if(e.isPayloadValid(r.type,i))r.data=i;else throw Error(`invalid payload`)}return r}tryParse(e){try{return JSON.parse(e,this.opts.reviver)}catch{return!1}}static isPayloadValid(e,t){switch(e){case xo.CONNECT:return Oo(t);case xo.DISCONNECT:return t===void 0;case xo.CONNECT_ERROR:return typeof t==`string`||Oo(t);case xo.EVENT:case xo.BINARY_EVENT:return Array.isArray(t)&&(typeof t[0]==`number`||typeof t[0]==`string`&&bo.indexOf(t[0])===-1);case xo.ACK:case xo.BINARY_ACK:return Array.isArray(t)}}destroy(){this.reconstructor&&=(this.reconstructor.finishedReconstruction(),null)}},wo=class{constructor(e){this.packet=e,this.buffers=[],this.reconPack=e}takeBinaryData(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){let e=_o(this.reconPack,this.buffers);return this.finishedReconstruction(),e}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}};function To(e){return typeof e==`string`}var Eo=Number.isInteger||function(e){return typeof e==`number`&&isFinite(e)&&Math.floor(e)===e};function Do(e){return e===void 0||Eo(e)}function Oo(e){return Object.prototype.toString.call(e)===`[object Object]`}function ko(e,t){switch(e){case xo.CONNECT:return t===void 0||Oo(t);case xo.DISCONNECT:return t===void 0;case xo.EVENT:return Array.isArray(t)&&(typeof t[0]==`number`||typeof t[0]==`string`&&bo.indexOf(t[0])===-1);case xo.ACK:return Array.isArray(t);case xo.CONNECT_ERROR:return typeof t==`string`||Oo(t);default:return!1}}function Ao(e){return To(e.nsp)&&Do(e.id)&&ko(e.type,e.data)}function jo(e,t,n){return e.on(t,n),function(){e.off(t,n)}}var Mo=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1}),No=class extends Na{constructor(e,t,n){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=e,this.nsp=t,n&&n.auth&&(this.auth=n.auth),this._opts=Object.assign({},n),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;let e=this.io;this.subs=[jo(e,`open`,this.onopen.bind(this)),jo(e,`packet`,this.onpacket.bind(this)),jo(e,`error`,this.onerror.bind(this)),jo(e,`close`,this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState===`open`&&this.onopen(),this)}open(){return this.connect()}send(...e){return e.unshift(`message`),this.emit.apply(this,e),this}emit(e,...t){if(Mo.hasOwnProperty(e))throw Error(`"`+e.toString()+`" is a reserved event name`);if(t.unshift(e),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(t),this;let n={type:xo.EVENT,data:t};if(n.options={},n.options.compress=this.flags.compress!==!1,typeof t[t.length-1]==`function`){let e=this.ids++,r=t.pop();this._registerAckCallback(e,r),n.id=e}let r=this.io.engine?.transport?.writable,i=this.connected&&!this.io.engine?._hasPingExpired();return this.flags.volatile&&!r||(i?(this.notifyOutgoingListeners(n),this.packet(n)):this.sendBuffer.push(n)),this.flags={},this}_registerAckCallback(e,t){let n=this.flags.timeout??this._opts.ackTimeout;if(n===void 0){this.acks[e]=t;return}let r=this.io.setTimeoutFn(()=>{delete this.acks[e];for(let t=0;t<this.sendBuffer.length;t++)this.sendBuffer[t].id===e&&this.sendBuffer.splice(t,1);t.call(this,Error(`operation has timed out`))},n),i=(...e)=>{this.io.clearTimeoutFn(r),t.apply(this,e)};i.withError=!0,this.acks[e]=i}emitWithAck(e,...t){return new Promise((n,r)=>{let i=(e,t)=>e?r(e):n(t);i.withError=!0,t.push(i),this.emit(e,...t)})}_addToQueue(e){let t;typeof e[e.length-1]==`function`&&(t=e.pop());let n={id:this._queueSeq++,tryCount:0,pending:!1,args:e,flags:Object.assign({fromQueue:!0},this.flags)};e.push((e,...r)=>(this._queue[0],e===null?(this._queue.shift(),t&&t(null,...r)):n.tryCount>this._opts.retries&&(this._queue.shift(),t&&t(e)),n.pending=!1,this._drainQueue())),this._queue.push(n),this._drainQueue()}_drainQueue(e=!1){if(!this.connected||this._queue.length===0)return;let t=this._queue[0];t.pending&&!e||(t.pending=!0,t.tryCount++,this.flags=t.flags,this.emit.apply(this,t.args))}packet(e){e.nsp=this.nsp,this.io._packet(e)}onopen(){typeof this.auth==`function`?this.auth(e=>{this._sendConnectPacket(e)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(e){this.packet({type:xo.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},e):e})}onerror(e){this.connected||this.emitReserved(`connect_error`,e)}onclose(e,t){this.connected=!1,delete this.id,this.emitReserved(`disconnect`,e,t),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(e=>{if(!this.sendBuffer.some(t=>String(t.id)===e)){let t=this.acks[e];delete this.acks[e],t.withError&&t.call(this,Error(`socket has been disconnected`))}})}onpacket(e){if(e.nsp===this.nsp)switch(e.type){case xo.CONNECT:e.data&&e.data.sid?this.onconnect(e.data.sid,e.data.pid):this.emitReserved(`connect_error`,Error(`It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)`));break;case xo.EVENT:case xo.BINARY_EVENT:this.onevent(e);break;case xo.ACK:case xo.BINARY_ACK:this.onack(e);break;case xo.DISCONNECT:this.ondisconnect();break;case xo.CONNECT_ERROR:this.destroy();let t=Error(e.data.message);t.data=e.data.data,this.emitReserved(`connect_error`,t)}}onevent(e){let t=e.data||[];e.id!=null&&t.push(this.ack(e.id)),this.connected?this.emitEvent(t):this.receiveBuffer.push(Object.freeze(t))}emitEvent(e){if(this._anyListeners&&this._anyListeners.length){let t=this._anyListeners.slice();for(let n of t)n.apply(this,e)}super.emit.apply(this,e),this._pid&&e.length&&typeof e[e.length-1]==`string`&&(this._lastOffset=e[e.length-1])}ack(e){let t=this,n=!1;return function(...r){n||(n=!0,t.packet({type:xo.ACK,id:e,data:r}))}}onack(e){let t=this.acks[e.id];typeof t==`function`&&(delete this.acks[e.id],t.withError&&e.data.unshift(null),t.apply(this,e.data))}onconnect(e,t){this.id=e,this.recovered=t&&this._pid===t,this._pid=t,this.connected=!0,this.emitBuffered(),this._drainQueue(!0),this.emitReserved(`connect`)}emitBuffered(){this.receiveBuffer.forEach(e=>this.emitEvent(e)),this.receiveBuffer=[],this.sendBuffer.forEach(e=>{this.notifyOutgoingListeners(e),this.packet(e)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose(`io server disconnect`)}destroy(){this.subs&&=(this.subs.forEach(e=>e()),void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:xo.DISCONNECT}),this.destroy(),this.connected&&this.onclose(`io client disconnect`),this}close(){return this.disconnect()}compress(e){return this.flags.compress=e,this}get volatile(){return this.flags.volatile=!0,this}timeout(e){return this.flags.timeout=e,this}onAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(e),this}prependAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(e),this}offAny(e){if(!this._anyListeners)return this;if(e){let t=this._anyListeners;for(let n=0;n<t.length;n++)if(e===t[n])return t.splice(n,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(e),this}prependAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(e),this}offAnyOutgoing(e){if(!this._anyOutgoingListeners)return this;if(e){let t=this._anyOutgoingListeners;for(let n=0;n<t.length;n++)if(e===t[n])return t.splice(n,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(e){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){let t=this._anyOutgoingListeners.slice();for(let n of t)n.apply(this,e.data)}}};function Po(e){e||={},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}Po.prototype.duration=function(){var e=this.ms*this.factor**+this.attempts++;if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+n:e-n}return Math.min(e,this.max)|0},Po.prototype.reset=function(){this.attempts=0},Po.prototype.setMin=function(e){this.ms=e},Po.prototype.setMax=function(e){this.max=e},Po.prototype.setJitter=function(e){this.jitter=e};var Fo=class extends Na{constructor(e,t){super(),this.nsps={},this.subs=[],e&&typeof e==`object`&&(t=e,e=void 0),t||={},t.path=t.path||`/socket.io`,this.opts=t,La(this,t),this.reconnection(t.reconnection!==!1),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(t.randomizationFactor??.5),this.backoff=new Po({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(t.timeout==null?2e4:t.timeout),this._readyState=`closed`,this.uri=e;let n=t.parser||yo;this.encoder=new n.Encoder,this.decoder=new n.Decoder,this._autoConnect=t.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(e){return arguments.length?(this._reconnection=!!e,e||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(e){return e===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=e,this)}reconnectionDelay(e){var t;return e===void 0?this._reconnectionDelay:(this._reconnectionDelay=e,(t=this.backoff)==null||t.setMin(e),this)}randomizationFactor(e){var t;return e===void 0?this._randomizationFactor:(this._randomizationFactor=e,(t=this.backoff)==null||t.setJitter(e),this)}reconnectionDelayMax(e){var t;return e===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=e,(t=this.backoff)==null||t.setMax(e),this)}timeout(e){return arguments.length?(this._timeout=e,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(e){if(~this._readyState.indexOf(`open`))return this;this.engine=new ao(this.uri,this.opts);let t=this.engine,n=this;this._readyState=`opening`,this.skipReconnect=!1;let r=jo(t,`open`,function(){n.onopen(),e&&e()}),i=t=>{this.cleanup(),this._readyState=`closed`,this.emitReserved(`error`,t),e?e(t):this.maybeReconnectOnOpen()},a=jo(t,`error`,i);if(!1!==this._timeout){let e=this._timeout,n=this.setTimeoutFn(()=>{r(),i(Error(`timeout`)),t.close()},e);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}return this.subs.push(r),this.subs.push(a),this}connect(e){return this.open(e)}onopen(){this.cleanup(),this._readyState=`open`,this.emitReserved(`open`);let e=this.engine;this.subs.push(jo(e,`ping`,this.onping.bind(this)),jo(e,`data`,this.ondata.bind(this)),jo(e,`error`,this.onerror.bind(this)),jo(e,`close`,this.onclose.bind(this)),jo(this.decoder,`decoded`,this.ondecoded.bind(this)))}onping(){this.emitReserved(`ping`)}ondata(e){try{this.decoder.add(e)}catch(e){this.onclose(`parse error`,e)}}ondecoded(e){Pa(()=>{this.emitReserved(`packet`,e)},this.setTimeoutFn)}onerror(e){this.emitReserved(`error`,e)}socket(e,t){let n=this.nsps[e];return n?this._autoConnect&&!n.active&&n.connect():(n=new No(this,e,t),this.nsps[e]=n),n}_destroy(e){let t=Object.keys(this.nsps);for(let e of t)if(this.nsps[e].active)return;this._close()}_packet(e){let t=this.encoder.encode(e);for(let n=0;n<t.length;n++)this.engine.write(t[n],e.options)}cleanup(){this.subs.forEach(e=>e()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose(`forced close`)}disconnect(){return this._close()}onclose(e,t){var n;this.cleanup(),(n=this.engine)==null||n.close(),this.backoff.reset(),this._readyState=`closed`,this.emitReserved(`close`,e,t),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;let e=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved(`reconnect_failed`),this._reconnecting=!1;else{let t=this.backoff.duration();this._reconnecting=!0;let n=this.setTimeoutFn(()=>{e.skipReconnect||(this.emitReserved(`reconnect_attempt`,e.backoff.attempts),!e.skipReconnect&&e.open(t=>{t?(e._reconnecting=!1,e.reconnect(),this.emitReserved(`reconnect_error`,t)):e.onreconnect()}))},t);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}}onreconnect(){let e=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved(`reconnect`,e)}},Io={};function Lo(e,t){typeof e==`object`&&(t=e,e=void 0),t||={};let n=oo(e,t.path||`/socket.io`),r=n.source,i=n.id,a=n.path,o=Io[i]&&a in Io[i].nsps,s=t.forceNew||t[`force new connection`]||!1===t.multiplex||o,c;return s?c=new Fo(r,t):(Io[i]||(Io[i]=new Fo(r,t)),c=Io[i]),n.query&&!t.query&&(t.query=n.queryKey),c.socket(n.path,t)}Object.assign(Lo,{Manager:Fo,Socket:No,io:Lo,connect:Lo});function Ro(e,t=600){if(e==null||e===``)return!0;let n=Number(e)*1e3;return!Number.isFinite(n)||Date.now()>=n-t*1e3}var zo=/[̀-ͯ]/g;function Bo(e){return e.toLocaleLowerCase(`vi`).normalize(`NFD`).replace(zo,``).replace(/đ/g,`d`)}function Vo(e){return e.map(([e,t])=>`${Ho(e)}=${Ho(String(t))}`).join(`&`)}function Ho(e){return encodeURIComponent(e).replace(/[!'()~]/g,e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`).replace(/%20/g,`+`)}var Uo=e=>typeof e==`object`&&!!e&&!Array.isArray(e),Wo=e=>{let t=Uo(e)&&Uo(e.data)?e.data:e;return Uo(t)?t:{}};function Go(e){let t=Wo(e).pageInfo,n=Uo(t)&&typeof t.nextCursor==`string`?t.nextCursor:null;return{nextCursor:n,hasMore:Uo(t)&&t.hasMore===!0&&n!==null}}function Ko(e){let t=Wo(e).items;return Array.isArray(t)?t.filter(Uo):[]}function qo(e,t,n){return`${e}:${t}:${n}`}function Jo(e){return e.flatMap(e=>{let t=String(e.id??``),n=Array.isArray(e.attachments)?e.attachments.filter(Uo):[];return n.length===0?[{...e,sourceMessageId:t}]:n.map((n,r)=>({...e,id:qo(t,String(n.id??``),r),sourceMessageId:t,attachmentId:n.id??null,attachment:n,attachments:[n]}))})}function Yo(e){return{items:Jo(Ko(e)),pageInfo:Go(e)}}var Xo=e=>JSON.stringify({c:e.sourceCursor,s:e.skippedItems}),Zo=e=>{if(!e)return{sourceCursor:null,skippedItems:0};try{let t=JSON.parse(e);if(Uo(t))return{sourceCursor:typeof t.c==`string`?t.c:null,skippedItems:typeof t.s==`number`&&Number.isInteger(t.s)&&t.s>0?t.s:0}}catch{return{sourceCursor:null,skippedItems:0}}return{sourceCursor:null,skippedItems:0}},Qo=30,$o=new Map,es=(e,t)=>{if($o.delete(e),$o.set(e,t),$o.size>Qo){let e=$o.keys().next().value;e!==void 0&&$o.delete(e)}};async function ts({fetchSourcePage:e,cursor:t,limit:n,cacheScope:r}){let{sourceCursor:i,skippedItems:a}=Zo(t),o=[];for(;;){let t=`${r}|${i??``}`,s=(a>0?$o.get(t):void 0)??await e(i);es(t,s);let c=s.items.slice(a),l=n-o.length,u=c.slice(0,l);if(o.push(...u),c.length>u.length)return{items:o,pageInfo:{nextCursor:Xo({sourceCursor:i,skippedItems:a+u.length}),hasMore:!0}};if(!s.pageInfo.hasMore||!s.pageInfo.nextCursor)return{items:o,pageInfo:{nextCursor:null,hasMore:!1}};if(i=s.pageInfo.nextCursor,a=0,o.length>=n)return{items:o,pageInfo:{nextCursor:Xo({sourceCursor:i,skippedItems:0}),hasMore:!0}}}}var ns=class extends Error{constructor(e,t,n){super(e),this.status=t,this.code=n,this.name=`ChatApiError`}},rs={apiBaseUrl:``,getAccessToken:()=>null},is=null;function as(e){rs=e}var ss=(e,t=rs)=>`${t.apiBaseUrl}${e.startsWith(`/`)?e:`/${e}`}`,cs=e=>ss(`/data/docs/${e}`),ls=(e,t)=>e?/^https?:\/\//i.test(e)?e:ss(e):t?cs(t):null;async function us(e,t={},n=rs,r){let i=new Headers(t.headers),a=r??n.getAccessToken(),o=t.auth!==!1,s={...t};delete s.auth,t.body instanceof FormData||i.set(`Content-Type`,`application/json`),o&&a&&i.set(`Authorization`,`Bearer ${a}`);let c=await fetch(ss(e,n),{...s,headers:i}),l=c.headers.get(`content-type`)?.includes(`application/json`)?await c.json():null;if(!c.ok){let e=l;throw new ns(e?.message??`Request failed with status ${c.status}`,c.status,e?.code)}return l}function ds(e){return us(`/users/${e}`)}function fs(e={}){let t=[];e.cursor&&t.push([`cursor`,e.cursor]),e.limit&&t.push([`limit`,String(e.limit)]),e.search&&t.push([`search`,Bo(e.search)]),e.departmentId&&t.push([`departmentId`,e.departmentId]),e.branchId&&t.push([`branchId`,e.branchId]),e.workStatus?.forEach(e=>t.push([`workStatus`,e]));let n=Vo(t);return us(n?`/users?${n}`:`/users`)}function ps(e){return us(`/departments/by-branch/${e}`)}function ms(e={}){let t=[];e.tagId&&t.push([`tagId`,e.tagId]),e.untagged&&t.push([`untagged`,`true`]);let n=Vo(t);return us(n?`/conversations?${n}`:`/conversations`,{method:`GET`,auth:!0})}function hs(){return us(`/tags`)}function gs(e){return us(`/tags`,{method:`POST`,body:JSON.stringify(e)})}function _s(e,t){return us(`/tags/${e}`,{method:`PATCH`,body:JSON.stringify(t)})}function vs(e){return us(`/tags/${e}`,{method:`DELETE`})}function ys(e,t){return us(`/tags/${e}/conversations`,{method:`PUT`,body:JSON.stringify({conversationIds:t})})}function bs(e,t){return us(`/tags/conversations/${e}`,{method:`PUT`,body:JSON.stringify({tagId:t})})}function xs(e=20){return us(`/conversations/recent?limit=${e}`,{method:`GET`,auth:!0})}function Ss(e){return us(`/conversations/${e}`)}function Cs(e){return us(`/conversations`,{method:`POST`,body:JSON.stringify(e)})}function ws(e,t){return us(`/conversations/${e}`,{method:`PATCH`,body:JSON.stringify(t)})}function Ts(e,t){return us(`/conversations/${e}/group-settings`,{method:`PATCH`,body:JSON.stringify(t)})}function Es(e){return us(`/conversations/${e}/invite-link`)}function Ds(e,t){return us(`/conversations/${e}/invite-link`,{method:`PATCH`,body:JSON.stringify({enabled:t})})}function Os(e){return us(`/conversations/${e}/invite-link/refresh`,{method:`POST`})}function ks(e){return us(`/conversations/join/${e}`)}function As(e){return us(`/conversations/join/${e}`,{method:`POST`})}function js(e,t){return us(`/conversations/${e}/pin`,{method:`PATCH`,body:JSON.stringify({pinned:t})})}function Ms(e){return e?.erpNotificationEnabled!==!1}function Ns(e){return e?.erpDirectMentionNotificationEnabled!==!1}function Ps(){return us(`/users/me/settings`)}function Fs(e){return us(`/users/me/settings`,{method:`PATCH`,body:JSON.stringify(e)})}function Is(e,t){return us(`/conversations/${e}/notification-settings`,{method:`PATCH`,body:JSON.stringify(t)})}function Ls(e){return us(`/conversations/${e}`,{method:`DELETE`})}function Rs(e){return us(`/conversations/${e}/clear`,{method:`POST`})}function zs(e,t){return us(`/conversations/${e}/members`,{method:`POST`,body:JSON.stringify({userId:t})})}function Bs(e,t){return us(`/conversations/${e}/members`,{method:`POST`,body:JSON.stringify({userIds:t})})}function Vs(e,t){return us(`/conversations/${e}/members`,{method:`DELETE`,body:JSON.stringify({userIds:t})})}function Lee(e,t={}){let n=[[`limit`,String(t.limit??30)]];return t.cursorPosition!==void 0&&t.cursorPosition!==null&&n.push([`cursorPosition`,String(t.cursorPosition)]),us(`/messages/${e}/system-members?${Vo(n)}`)}function Ree(e,t){return us(`/conversations/${e}/members/${t}`,{method:`DELETE`})}function zee(e){return us(`/conversations/${e}/members/pending`)}function Bee(e,t){return us(`/conversations/${e}/members/approve`,{method:`POST`,body:JSON.stringify({userIds:t})})}function Vee(e,t){return us(`/conversations/${e}/members/reject`,{method:`POST`,body:JSON.stringify({userIds:t})})}function Hee(e,t){return us(`/conversations/${e}/leave`,{method:`PATCH`,body:JSON.stringify({nextOwnerId:t})})}function Uee(e){return us(`/messages/conversation/${e}/latest`)}function Wee(e,t){return us(`/messages/conversation/${e}/${t}`,{method:`DELETE`})}function Hs(e,t={}){let n=[],r=t.beforeSequence!==void 0&&t.beforeSequence!==null,i=t.afterSequence!==void 0&&t.afterSequence!==null;if(r===i)throw Error(`Message history requires exactly one cursor direction`);return r&&n.push([`beforeSequence`,String(t.beforeSequence)]),i&&n.push([`afterSequence`,String(t.afterSequence)]),n.push([`limit`,String(t.limit??20)]),us(`/messages/conversation/${e}?${Vo(n)}`)}function Gee(e,t){return us(`/messages/conversation/${e}/around/${t}`)}function Us(e,t={}){let n=[[`limit`,String(t.limit??30)]];return t.type&&n.push([`type`,t.type]),t.cursorUpdatedAt&&t.cursorUserId&&(n.push([`cursorUpdatedAt`,t.cursorUpdatedAt]),n.push([`cursorUserId`,t.cursorUserId])),us(`/messages/${e}/reactions?${Vo(n)}`)}function Kee(e){return us(`/messages/conversation/${e}/pinned`)}function qee(e,t={}){let n=String(t.q??``).trim();if(!n)throw Error(`Search keyword is required`);let r=[[`q`,n],[`messageLimit`,String(t.messageLimit??20)],[`documentLimit`,String(t.documentLimit??20)]];return t.messageBeforeSequence&&r.push([`messageBeforeSequence`,String(t.messageBeforeSequence)]),t.documentBeforeSequence&&r.push([`documentBeforeSequence`,String(t.documentBeforeSequence)]),t.senderId&&r.push([`senderId`,t.senderId]),t.fromDate&&r.push([`fromDate`,t.fromDate]),t.toDate&&r.push([`toDate`,t.toDate]),us(`/messages/conversation/${e}/search?${Vo(r)}`)}function Ws(e,t){let n=[[`type`,t.type]];return t.month&&n.push([`month`,t.month]),t.from&&n.push([`from`,t.from]),t.to&&n.push([`to`,t.to]),t.senderId&&n.push([`senderId`,t.senderId]),t.cursor&&n.push([`cursor`,t.cursor]),t.limit&&n.push([`limit`,String(t.limit)]),us(`/messages/conversation/${e}/archive?${Vo(n)}`)}async function Gs(e,t){if(t.type===`link`){let n=await Ws(e,t);return{items:Ko(n),pageInfo:Go(n)}}return t.limit?ts({fetchSourcePage:async n=>Yo(await Ws(e,{...t,cursor:n})),cursor:t.cursor,limit:t.limit,cacheScope:[e,t.type,t.senderId??``,t.from??``,t.to??``,t.month??``,t.limit].join(`|`)}):Yo(await Ws(e,t))}async function Jee(e){let t=e.onRefreshToken;if(!t)return e.getAccessToken()??``;if(is?.callback!==t){let n=Promise.resolve().then(t).catch(t=>{throw e.onUnauthorized?.(),t});is={callback:t,promise:n};let r=()=>{is?.promise===n&&(is=null)};n.then(r,r)}return is.promise}async function Ks(e,t,n,r){let i=rs,a=n!==void 0&&i.onRefreshToken&&Ro(n)?await Jee(i):i.getAccessToken(),o=new FormData;o.append(`file`,e),o.append(`conversationId`,t),r&&o.append(`asDocument`,`true`);let s=await us(`/media/uploads`,{method:`POST`,body:o},i,a??void 0),c=s?.id;if(!c)throw Error(`Not found media-id response`);return{mediaId:c,attachmentUrl:s?.url??null,kind:s?.kind??null,mimeType:s?.mimeType??null,thumbnailUrl:s?.thumbnailUrl??null,durationMs:s?.durationMs??null,width:s?.width??null,height:s?.height??null,response:s}}async function Yee(e,t,n){let{mediaId:r,attachmentUrl:i}=await Ks(e,t,n);return ws(t,{avatarUrl:i??`/data/docs/${r}`})}function qs({from:e,to:t,userId:n,kind:r,search:i}){let a=[[`kind`,r]];return e&&a.push([`from`,e]),t&&a.push([`to`,t]),n&&a.push([`userId`,n]),i?.trim()&&a.push([`search`,i.trim()]),a}function Xee(e){let t=qs(e);return t.push([`page`,String(e.page)],[`pageSize`,String(e.pageSize)]),Vo(t)}function Zee(e){return us(`/stats/conversations/overview?${Vo(qs(e))}`)}function Qee(e){return us(`/stats/conversations/created-trend?${Vo(qs(e))}`)}function $ee(e){return us(`/stats/conversations/top-interactive?${Vo(qs(e))}`)}function ete(e){return us(`/stats/conversations?${Xee(e)}`)}function tte(e){let t=[[`page`,String(e.page)],[`pageSize`,String(e.pageSize)]];return e.userId&&t.push([`userId`,e.userId]),e.departmentId&&t.push([`departmentId`,e.departmentId]),e.branchId&&t.push([`branchId`,e.branchId]),us(`/stats/users/top-interactive?${Vo(t)}`)}function nte(e){return us(`/stats/users/group-breakdown?${Vo([[`userId`,e.userId],[`page`,String(e.page)],[`pageSize`,String(e.pageSize)]])}`)}function rte(e){let t=Vo([[`page`,String(e.page)],[`pageSize`,String(e.pageSize)]]);return us(`/stats/conversations/${e.conversationId}/members?${t}`)}var Js=``,Ys=null,Xs=``,Zs=new Set,Qs=!1,$s=!1;function ite(e){Js=e}function ec(e){let t=Ys;if(!t)return()=>void 0;let n=[],r=(e,r)=>{r&&(t.on(e,r),n.push({event:e,listener:r}))};if(r(`conversation:new`,e.onConversationNew),r(`conversation:deleted`,e.onConversationDeleted),r(`conversation:updated`,e.onConversationUpdated),r(`conversation:pinned`,e.onConversationPinned),r(`conversation:membership:changed`,e.onConversationMembershipChanged),e.onMessageSent&&(r(`message:sent`,e.onMessageSent),r(`message:ack`,e.onMessageSent)),e.onMessageNew&&(r(`message:new`,e.onMessageNew),r(`message:created`,e.onMessageNew)),r(`message:removed`,e.onMessageRemoved),r(`message:reaction:updated`,e.onMessageReactionUpdated),r(`message:pinned`,e.onMessagePinned),r(`conversation:read`,e.onConversationRead),r(`conversation:unread`,e.onConversationUnread),r(`presence:changed`,e.onPresenceChanged),r(`typing:start`,e.onTypingStart),r(`typing:stop`,e.onTypingStop),(e.onConnected||e.onConnectionRestored)&&r(`connect`,()=>{e.onConnected?.(),$s&&e.onConnectionRestored?.()}),r(`disconnect`,e.onConnectionLost),e.onConnectFailed){let t=t=>{e.onConnectFailed?.(t)};r(`connect_error`,t),r(`error`,t),r(`exception`,t)}return()=>{n.forEach(({event:e,listener:n})=>t.off(e,n))}}function tc(e){let t={handlers:e,detach:()=>void 0};return Zs.add(t),t.detach=ec(e),()=>{t.detach(),Zs.delete(t)}}function ate(){Zs.forEach(e=>{e.detach(),e.detach=ec(e.handlers)})}function ote(e,t){let n=Ys?.auth?.token;return Ys&&n===e&&Xs===Js?(t&&tc(t),Ys):(Ys&&oc(),Ys=Lo(Js,{transports:[`websocket`],upgrade:!1,auth:{token:e}}),Xs=Js,Ys.on(`connect`,()=>{$s=Qs,Qs=!0}),ate(),t&&tc(t),Ys)}function ste(){return Ys}function nc(e,t,n){return Ys?.connected?(n?Ys.emit(e,t,n):Ys.emit(e,t),{ok:!0,status:`EMITTED`}):{ok:!1,status:`DISCONNECTED`}}function cte(e,t){return nc(`conversation:create`,e,t)}var rc=new Map;function ic(e,t){if(t){let n=rc.get(e)??new Set;n.add(t),rc.set(e,n)}return nc(`conversation:subscribe`,{conversationId:e})}function lte(e,t){if(t){let n=rc.get(e);if(n?.delete(t),n&&n.size>0)return{ok:!0,status:`RETAINED`};rc.delete(e)}return nc(`conversation:unsubscribe`,{conversationId:e})}function ac(e,t){return nc(`message:send`,e,t)}function ute(e){return nc(`message:reaction:apply`,e)}function dte(e){return nc(`message:reaction:remove`,e)}function fte(e,t){return nc(`message:pin`,e,t)}function pte(e,t){return nc(`message:forward`,e,t)}function mte(e,t){return nc(`conversation:read`,e,t)}function hte(e){return nc(`typing:start`,e)}function gte(e){return nc(`typing:stop`,e)}function oc(){Ys&&=(Ys.removeAllListeners(),Ys.disconnect(),null),Xs=``,Qs=!1,$s=!1}var sc=260,cc=160;function lc({label:e,value:t,options:n,onChange:r,disabled:i}){let[a,o]=(0,d.useState)(!1),[s,c]=(0,d.useState)(``),[l,u]=(0,d.useState)(0),[f,m]=(0,d.useState)(null),h=(0,d.useRef)(null),g=(0,d.useRef)(null),_=(0,d.useRef)(null),v=(0,d.useRef)(!1);(0,d.useEffect)(()=>{_.current?.scrollIntoView({block:`nearest`})},[l]),(0,d.useEffect)(()=>{if(!a)return;let e=e=>{h.current?.contains(e.target)||o(!1)};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[a]);let y=n.find(e=>e.value===t),b=!y||y.value===n[0]?.value,x=()=>{let e=g.current?.getBoundingClientRect();if(!e)return;let t=window.innerHeight-e.bottom,n=e.top,r=t<sc&&n>t?Math.max(8,e.top-sc-6):e.bottom+6,i=Math.max(e.width,cc),a=Math.max(8,Math.min(e.left,window.innerWidth-i-8));m({top:r,left:a,width:e.width})};(0,d.useEffect)(()=>{if(!a)return;let e=()=>x();return window.addEventListener(`scroll`,e,!0),window.addEventListener(`resize`,e),()=>{window.removeEventListener(`scroll`,e,!0),window.removeEventListener(`resize`,e)}},[a]);let S=()=>{c(``);let e=n.findIndex(e=>e.value===t);u(Math.max(e,0))},C=()=>{if(!i){if(v.current){v.current=!1;return}o(e=>{let t=!e;return t&&(x(),S()),t})}},w=e=>{e.target===e.currentTarget&&(i||a||(v.current=!0,x(),S(),o(!0)))},T=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),!i&&o(e=>{let t=!e;return t&&(x(),S()),t}))},E=pa(s.trim()),D=E?n.filter(e=>pa(e.label).includes(E)):n,O=()=>{let e=D[l];e&&(r(e.value),o(!1))};return(0,p.jsxs)(`div`,{className:`filter-pill`,ref:h,children:[(0,p.jsxs)(`div`,{ref:g,className:`filter-pill-trigger${b?``:` is-active`}${i?` is-disabled`:``}`,role:`button`,tabIndex:i?-1:0,"aria-disabled":i||void 0,onClick:C,onFocus:w,onKeyDown:T,children:[(0,p.jsx)(`span`,{className:`filter-pill-trigger-label`,children:b?e:y?.label}),b?(0,p.jsx)(pt,{className:`filter-pill-trigger-chevron`}):(0,p.jsx)(`button`,{type:`button`,className:`filter-pill-trigger-clear`,"aria-label":`Bỏ lọc ${e}`,onClick:e=>{e.stopPropagation(),r(n[0].value)},children:(0,p.jsx)(Ke,{})})]}),a&&f?(0,p.jsxs)(`div`,{className:`filter-pill-menu`,role:`menu`,"aria-label":e,style:{top:f.top,left:f.left,minWidth:Math.max(f.width,cc)},children:[(0,p.jsx)(`input`,{className:`filter-pill-menu-search`,type:`text`,value:s,onChange:e=>{c(e.target.value),u(0)},onKeyDown:e=>{e.key===`ArrowDown`?(e.preventDefault(),u(e=>Math.min(e+1,D.length-1))):e.key===`ArrowUp`?(e.preventDefault(),u(e=>Math.max(e-1,0))):e.key===`Enter`?(e.preventDefault(),O()):e.key===`Escape`&&o(!1)},onClick:e=>e.stopPropagation(),placeholder:`Tìm...`,autoFocus:!0}),D.length===0?(0,p.jsx)(`p`,{className:`filter-pill-menu-empty`,children:`Không tìm thấy`}):D.map((e,n)=>(0,p.jsx)(`button`,{ref:n===l?_:void 0,type:`button`,role:`menuitem`,className:`${e.value===t?`is-active`:``}${n===l?` is-highlighted`:``}`,onMouseEnter:()=>u(n),onClick:()=>{r(e.value),o(!1)},children:e.label},e.value))]}):null]})}var uc=260,dc=6;function fc({label:e,value:t,options:n,onChange:r,disabled:i}){let[a,o]=(0,d.useState)(!1),[s,c]=(0,d.useState)(!1),[l,u]=(0,d.useState)(``),[f,m]=(0,d.useState)(0),[h,g]=(0,d.useState)(null),_=(0,d.useRef)(null),v=(0,d.useRef)(null),y=(0,d.useRef)(null),b=(0,d.useRef)(null),x=(0,d.useRef)(null),S=(0,d.useRef)(null),C=(0,d.useRef)(!1),[w,T]=(0,d.useState)(null);(0,d.useEffect)(()=>{S.current?.scrollIntoView({block:`nearest`})},[f]),(0,d.useEffect)(()=>{if(!a)return;let e=e=>{_.current?.contains(e.target)||o(!1)};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[a]);let E=t.length>0,D=n.filter(e=>t.includes(e.value)),O=D.map(e=>e.value).join(`|`);(0,d.useLayoutEffect)(()=>{if(s){T(null);return}let e=y.current,t=b.current;if(!e||!t||D.length===0){T(null);return}let n=()=>{let n=e.clientWidth,r=x.current?.offsetWidth??0,i=Array.from(t.children),a=0,o=i.length;for(let e=0;e<i.length;e+=1){let t=i[e].offsetWidth,s=a+(e>0?dc:0)+t;if(s+(i.length-(e+1)>0?dc+r:0)>n){o=e;break}a=s}T(o>=i.length?null:Math.max(o,1))};n();let r=new ResizeObserver(n);return r.observe(e),()=>r.disconnect()},[s,O]);let k=()=>{let e=v.current?.getBoundingClientRect();if(!e)return;let t=window.innerHeight-e.bottom,n=e.top,r=t<uc&&n>t?Math.max(8,e.top-uc-6):e.bottom+6;g({top:r,left:e.left})},A=()=>{u(``);let e=n.findIndex(e=>t.includes(e.value));m(Math.max(e,0))},j=()=>{if(!i){if(C.current){C.current=!1;return}o(e=>{let t=!e;return t&&(k(),A()),t})}},M=e=>{e.target===e.currentTarget&&(i||a||(C.current=!0,k(),A(),o(!0)))},N=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),!i&&o(e=>{let t=!e;return t&&(k(),A()),t}))},P=pa(l.trim()),F=P?n.filter(e=>pa(e.label).includes(P)):n,I=e=>{r(t.includes(e)?t.filter(t=>t!==e):[...t,e])},L=e=>{if(e.key===`ArrowDown`)e.preventDefault(),m(e=>Math.min(e+1,F.length-1));else if(e.key===`ArrowUp`)e.preventDefault(),m(e=>Math.max(e-1,0));else if(e.key===`Enter`){e.preventDefault();let t=F[f];t&&I(t.value)}else e.key===`Escape`&&o(!1)},R=e=>{r(t.filter(t=>t!==e))},ee=s||w===null?D:D.slice(0,w),te=D.length-ee.length;return(0,p.jsxs)(`div`,{className:`multi-select-filter-pill-wrap`,ref:_,children:[(0,p.jsx)(`div`,{ref:v,className:`multi-select-filter-box${E?` is-active`:``}${i?` is-disabled`:``}`,role:`button`,tabIndex:i?-1:0,"aria-disabled":i||void 0,onClick:j,onFocus:M,onKeyDown:N,children:E?(0,p.jsxs)(`div`,{className:`multi-select-filter-tags`,ref:y,children:[(0,p.jsx)(`div`,{className:`multi-select-filter-tags-measure`,"aria-hidden":`true`,ref:b,children:D.map(e=>(0,p.jsxs)(`span`,{className:`multi-select-filter-tag`,children:[e.label,(0,p.jsx)(`button`,{type:`button`,tabIndex:-1,children:`×`})]},e.value))}),(0,p.jsxs)(`span`,{className:`multi-select-filter-tag-more`,"aria-hidden":`true`,ref:x,children:[`+`,D.length]}),ee.map(e=>(0,p.jsxs)(`span`,{className:`multi-select-filter-tag`,children:[e.label,(0,p.jsx)(`button`,{type:`button`,"aria-label":`Bỏ ${e.label}`,onClick:t=>{t.stopPropagation(),R(e.value)},children:`×`})]},e.value)),te>0?(0,p.jsxs)(`button`,{type:`button`,className:`multi-select-filter-tag-more`,onClick:e=>{e.stopPropagation(),c(!0)},children:[`+`,te]}):null]}):(0,p.jsxs)(`div`,{className:`multi-select-filter-box-header`,children:[(0,p.jsx)(`span`,{className:`filter-pill-trigger-label`,children:e}),(0,p.jsx)(pt,{className:`filter-pill-trigger-chevron`})]})}),a&&h?(0,p.jsxs)(`div`,{className:`filter-pill-menu`,role:`menu`,"aria-label":e,style:{top:h.top,left:h.left},children:[(0,p.jsx)(`input`,{className:`filter-pill-menu-search`,type:`text`,value:l,onChange:e=>{u(e.target.value),m(0)},onKeyDown:L,onClick:e=>e.stopPropagation(),placeholder:`Tìm...`,autoFocus:!0}),F.length===0?(0,p.jsx)(`p`,{className:`filter-pill-menu-empty`,children:`Không tìm thấy`}):F.map((e,n)=>{let r=t.includes(e.value);return(0,p.jsxs)(`button`,{ref:n===f?S:void 0,type:`button`,role:`menuitemcheckbox`,"aria-checked":r,className:`${r?`is-active`:``}${n===f?` is-highlighted`:``}`,onMouseEnter:()=>m(n),onClick:()=>I(e.value),children:[r?(0,p.jsx)(Le,{}):null,e.label]},e.value)})]}):null]})}var pc=`data:image/svg+xml,%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3c!--%20Uploaded%20to:%20SVG%20Repo,%20www.svgrepo.com,%20Transformed%20by:%20SVG%20Repo%20Mixer%20Tools%20--%3e%3csvg%20width='800px'%20height='800px'%20viewBox='0%200%201024%201024'%20class='icon'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20fill='%23000000'%3e%3cg%20id='SVGRepo_bgCarrier'%20stroke-width='0'/%3e%3cg%20id='SVGRepo_tracerCarrier'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cg%20id='SVGRepo_iconCarrier'%3e%3cpath%20d='M640%20874.666667l-85.333333%2085.333333h-85.333334l-85.333333-85.333333V448h256v170.666667l-42.666667%2042.666666%2042.666667%2042.666667v42.666667l-42.666667%2042.666666%2042.666667%2042.666667z'%20fill='%23FFA000'/%3e%3cpath%20d='M810.666667%20166.4c-10.666667-38.4-42.666667-66.133333-78.933334-76.8C680.533333%2078.933333%20601.6%2064%20512%2064s-168.533333%2014.933333-219.733333%2025.6C256%20100.266667%20224%20128%20213.333333%20166.4c-10.666667%2036.266667-21.333333%2087.466667-21.333333%20142.933333%200%2055.466667%2010.666667%20106.666667%2021.333333%20142.933334%2010.666667%2038.4%2040.533333%2066.133333%2078.933334%2074.666666%2051.2%2012.8%20130.133333%2027.733333%20219.733333%2027.733334s168.533333-14.933333%20219.733333-25.6c38.4-8.533333%2068.266667-38.4%2078.933334-74.666667s21.333333-87.466667%2021.333333-142.933333c0-57.6-10.666667-108.8-21.333333-145.066667zM618.666667%20277.333333H405.333333c-23.466667%200-42.666667-19.2-42.666666-42.666666V192c0-12.8%2066.133333-21.333333%20149.333333-21.333333s149.333333%208.533333%20149.333333%2021.333333v42.666667c0%2023.466667-19.2%2042.666667-42.666666%2042.666666z'%20fill='%23FFA000'/%3e%3cpath%20d='M490.666667%20554.666667h42.666666v405.333333h-42.666666z'%20fill='%23D68600'/%3e%3c/g%3e%3c/svg%3e`,mc=[];function hc(e){let t=(0,d.useRef)(Symbol(`overlay`));(0,d.useEffect)(()=>{let e=t.current;return mc.push(e),()=>{let t=mc.indexOf(e);t!==-1&&mc.splice(t,1)}},[]),(0,d.useEffect)(()=>{let n=n=>{n.key===`Escape`&&mc.at(-1)===t.current&&(n.stopPropagation(),e())};return document.addEventListener(`keydown`,n,!0),()=>document.removeEventListener(`keydown`,n,!0)},[e])}function gc(e){"@babel/helpers - typeof";return gc=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},gc(e)}function _te(e,t){if(gc(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(gc(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function vte(e){var t=_te(e,`string`);return gc(t)==`symbol`?t:t+``}function _c(e,t,n){return(t=vte(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var yte=class{requestAnimationFrame(e){return requestAnimationFrame(e)}cancelAnimationFrame(e){cancelAnimationFrame(e)}},bte=class{constructor(){_c(this,`_lastHandleId`,0),_c(this,`_lastImmediate`,null)}requestAnimationFrame(e){return this._lastHandleId>=2**53-1&&(this._lastHandleId=0),this._lastHandleId+=1,this._lastImmediate=setImmediate(()=>{e(performance.now())}),this._lastHandleId}cancelAnimationFrame(e){this._lastImmediate&&clearImmediate(this._lastImmediate)}},xte=class{constructor(){_c(this,`_strategy`,void 0),this._strategy=typeof requestAnimationFrame==`function`?new yte:new bte}requestAnimationFrame(e){return this._strategy.requestAnimationFrame(e)}cancelAnimationFrame(e){this._strategy.cancelAnimationFrame(e)}},vc=typeof window<`u`&&window.document!==void 0,yc=new Uint8Array([80,75,3,4]),Ste=[`v`,`ip`,`op`,`layers`,`fr`,`w`,`h`],H,bc=Array(128).fill(void 0);bc.push(void 0,null,!0,!1);function xc(e){return bc[e]}var Sc=bc.length;function Cc(e){Sc===bc.length&&bc.push(bc.length+1);let t=Sc;return Sc=bc[t],bc[t]=e,t}function wc(e,t){try{return e.apply(this,t)}catch(e){H.__wbindgen_export_0(Cc(e))}}var Tc=0,Ec=null;function Dc(){return(Ec===null||Ec.byteLength===0)&&(Ec=new Uint8Array(H.memory.buffer)),Ec}var Oc=typeof TextEncoder<`u`?new TextEncoder(`utf-8`):{encode:()=>{throw Error(`TextEncoder not available`)}},kc=typeof Oc.encodeInto==`function`?function(e,t){return Oc.encodeInto(e,t)}:function(e,t){let n=Oc.encode(e);return t.set(n),{read:e.length,written:n.length}};function Ac(e,t,n){if(n===void 0){let n=Oc.encode(e),r=t(n.length,1)>>>0;return Dc().subarray(r,r+n.length).set(n),Tc=n.length,r}let r=e.length,i=t(r,1)>>>0,a=Dc(),o=0;for(;o<r;o++){let t=e.charCodeAt(o);if(t>127)break;a[i+o]=t}if(o!==r){o!==0&&(e=e.slice(o)),i=n(i,r,r=o+e.length*3,1)>>>0;let t=Dc().subarray(i+o,i+r),a=kc(e,t);o+=a.written,i=n(i,r,o,1)>>>0}return Tc=o,i}var jc=null;function Mc(){return(jc===null||jc.buffer.detached===!0||jc.buffer.detached===void 0&&jc.buffer!==H.memory.buffer)&&(jc=new DataView(H.memory.buffer)),jc}var Nc=typeof TextDecoder<`u`?new TextDecoder(`utf-8`,{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error(`TextDecoder not available`)}};typeof TextDecoder<`u`&&Nc.decode();function Pc(e,t){return e>>>=0,Nc.decode(Dc().subarray(e,e+t))}function Fc(e){e<132||(bc[e]=Sc,Sc=e)}function Ic(e){let t=xc(e);return Fc(e),t}function Lc(e){return e==null}function Rc(e,t){let n=t(e.length*1,1)>>>0;return Dc().set(e,n/1),Tc=e.length,n}function zc(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Rc(t,H.__wbindgen_export_1),a=Tc;return H.register_font(n,r,i,a)!==0}var Bc=null;function Vc(){return(Bc===null||Bc.byteLength===0)&&(Bc=new Float32Array(H.memory.buffer)),Bc}function Hc(e,t){let n=t(e.length*4,4)>>>0;return Vc().set(e,n/4),Tc=e.length,n}function Uc(e,t){let n=t(e.length*4,4)>>>0,r=Mc();for(let t=0;t<e.length;t++)r.setUint32(n+4*t,Cc(e[t]),!0);return Tc=e.length,n}var Wc=Object.freeze({Forward:0,0:`Forward`,Reverse:1,1:`Reverse`,Bounce:2,2:`Bounce`,ReverseBounce:3,3:`ReverseBounce`}),Gc=Object.freeze({Idle:0,0:`Idle`,Playing:1,1:`Playing`,Paused:2,2:`Paused`,Stopped:3,3:`Stopped`,Tweening:4,4:`Tweening`}),Kc=typeof FinalizationRegistry>`u`?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(e=>H.__wbg_dotlottieplayerwasm_free(e>>>0,1)),qc=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,Kc.unregister(this),e}free(){let e=this.__destroy_into_raw();H.__wbg_dotlottieplayerwasm_free(e,0)}clear_slot(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_clear_slot(this.__wbg_ptr,t,n)!==0}layout_fit(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_layout_fit(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}loop_count(){return H.dotlottieplayerwasm_loop_count(this.__wbg_ptr)>>>0}poll_event(){return Ic(H.dotlottieplayerwasm_poll_event(this.__wbg_ptr))}reset_slot(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_reset_slot(this.__wbg_ptr,t,n)!==0}set_layout(e,t,n){let r=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),i=Tc;return H.dotlottieplayerwasm_set_layout(this.__wbg_ptr,r,i,t,n)!==0}set_marker(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;H.dotlottieplayerwasm_set_marker(this.__wbg_ptr,t,n)}clear_slots(){return H.dotlottieplayerwasm_clear_slots(this.__wbg_ptr)!==0}is_complete(){return H.dotlottieplayerwasm_is_complete(this.__wbg_ptr)!==0}reset_slots(){return H.dotlottieplayerwasm_reset_slots(this.__wbg_ptr)!==0}reset_theme(){return H.dotlottieplayerwasm_reset_theme(this.__wbg_ptr)!==0}segment_end(){return H.dotlottieplayerwasm_segment_end(this.__wbg_ptr)}set_quality(e){return H.dotlottieplayerwasm_set_quality(this.__wbg_ptr,e)!==0}set_segment(e,t){return H.dotlottieplayerwasm_set_segment(this.__wbg_ptr,e,t)!==0}sm_set_seed(e){return H.dotlottieplayerwasm_sm_set_seed(this.__wbg_ptr,e)!==0}static unload_font(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_unload_font(t,n)!==0}animation_id(){try{let n=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_animation_id(n,this.__wbg_ptr);var e=Mc().getInt32(n+0,!0),t=Mc().getInt32(n+4,!0);let r;return e!==0&&(r=Pc(e,t).slice(),H.__wbindgen_export_3(e,t*1,1)),r}finally{H.__wbindgen_add_to_stack_pointer(16)}}audio_volume(){return H.dotlottieplayerwasm_audio_volume(this.__wbg_ptr)}background_a(){return H.dotlottieplayerwasm_background_a(this.__wbg_ptr)}background_b(){return H.dotlottieplayerwasm_background_b(this.__wbg_ptr)}background_g(){return H.dotlottieplayerwasm_background_g(this.__wbg_ptr)}background_r(){return H.dotlottieplayerwasm_background_r(this.__wbg_ptr)}clear_marker(){H.dotlottieplayerwasm_clear_marker(this.__wbg_ptr)}emit_on_loop(){H.dotlottieplayerwasm_emit_on_loop(this.__wbg_ptr)}get_slot_ids(){return Ic(H.dotlottieplayerwasm_get_slot_ids(this.__wbg_ptr))}get_slot_str(e){try{let r=H.__wbindgen_add_to_stack_pointer(-16),i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;H.dotlottieplayerwasm_get_slot_str(r,this.__wbg_ptr,i,a);var t=Mc().getInt32(r+0,!0),n=Mc().getInt32(r+4,!0);let o;return t!==0&&(o=Pc(t,n).slice(),H.__wbindgen_export_3(t,n*1,1)),o}finally{H.__wbindgen_add_to_stack_pointer(16)}}marker_names(){return Ic(H.dotlottieplayerwasm_marker_names(this.__wbg_ptr))}set_autoplay(e){H.dotlottieplayerwasm_set_autoplay(this.__wbg_ptr,e)}set_slot_str(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Ac(t,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_set_slot_str(this.__wbg_ptr,n,r,i,a)!==0}set_viewport(e,t,n,r){return H.dotlottieplayerwasm_set_viewport(this.__wbg_ptr,e,t,n,r)!==0}total_frames(){return H.dotlottieplayerwasm_total_frames(this.__wbg_ptr)}clear_segment(){return H.dotlottieplayerwasm_clear_segment(this.__wbg_ptr)!==0}current_frame(){return H.dotlottieplayerwasm_current_frame(this.__wbg_ptr)}get_slot_type(e){try{let r=H.__wbindgen_add_to_stack_pointer(-16),i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;H.dotlottieplayerwasm_get_slot_type(r,this.__wbg_ptr,i,a);var t=Mc().getInt32(r+0,!0),n=Mc().getInt32(r+4,!0);let o;return t!==0&&(o=Pc(t,n).slice(),H.__wbindgen_export_3(t,n*1,1)),o}finally{H.__wbindgen_add_to_stack_pointer(16)}}get_slots_str(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_get_slots_str(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}get_transform(){return Ic(H.dotlottieplayerwasm_get_transform(this.__wbg_ptr))}segment_start(){return H.dotlottieplayerwasm_segment_start(this.__wbg_ptr)}set_slots_str(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_set_slots_str(this.__wbg_ptr,t,n)!==0}set_text_slot(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Ac(t,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_set_text_slot(this.__wbg_ptr,n,r,i,a)!==0}set_transform(e){let t=Hc(e,H.__wbindgen_export_1),n=Tc;return H.dotlottieplayerwasm_set_transform(this.__wbg_ptr,t,n)!==0}sm_get_inputs(){return Ic(H.dotlottieplayerwasm_sm_get_inputs(this.__wbg_ptr))}sm_poll_event(){return Ic(H.dotlottieplayerwasm_sm_poll_event(this.__wbg_ptr))}sm_post_click(e,t){H.dotlottieplayerwasm_sm_post_click(this.__wbg_ptr,e,t)}animation_size(){return Ic(H.dotlottieplayerwasm_animation_size(this.__wbg_ptr))}current_marker(){try{let n=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_current_marker(n,this.__wbg_ptr);var e=Mc().getInt32(n+0,!0),t=Mc().getInt32(n+4,!0);let r;return e!==0&&(r=Pc(e,t).slice(),H.__wbindgen_export_3(e,t*1,1)),r}finally{H.__wbindgen_add_to_stack_pointer(16)}}layout_align_x(){return H.dotlottieplayerwasm_layout_align_x(this.__wbg_ptr)}layout_align_y(){return H.dotlottieplayerwasm_layout_align_y(this.__wbg_ptr)}load_animation(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_load_animation(this.__wbg_ptr,t,n)!==0}loop_animation(){return H.dotlottieplayerwasm_loop_animation(this.__wbg_ptr)!==0}set_background(e,t,n,r){return H.dotlottieplayerwasm_set_background(this.__wbg_ptr,e,t,n,r)!==0}set_color_slot(e,t,n,r){let i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_set_color_slot(this.__wbg_ptr,i,a,t,n,r)!==0}set_image_slot(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Ac(t,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_set_image_slot(this.__wbg_ptr,n,r,i,a)!==0}set_loop_count(e){H.dotlottieplayerwasm_set_loop_count(this.__wbg_ptr,e)}set_theme_data(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_set_theme_data(this.__wbg_ptr,t,n)!==0}sm_reset_input(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;H.dotlottieplayerwasm_sm_reset_input(this.__wbg_ptr,t,n)}manifest_string(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_manifest_string(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}set_scalar_slot(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;return H.dotlottieplayerwasm_set_scalar_slot(this.__wbg_ptr,n,r,t)!==0}set_vector_slot(e,t,n){let r=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),i=Tc;return H.dotlottieplayerwasm_set_vector_slot(this.__wbg_ptr,r,i,t,n)!==0}setup_sw_target(e,t){return H.dotlottieplayerwasm_setup_sw_target(this.__wbg_ptr,e,t)!==0}get_pixel_buffer(){return Ic(H.dotlottieplayerwasm_get_pixel_buffer(this.__wbg_ptr))}set_audio_volume(e){H.dotlottieplayerwasm_set_audio_volume(this.__wbg_ptr,e)}sm_current_state(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_sm_current_state(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}state_machine_id(){try{let n=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_state_machine_id(n,this.__wbg_ptr);var e=Mc().getInt32(n+0,!0),t=Mc().getInt32(n+4,!0);let r;return e!==0&&(r=Pc(e,t).slice(),H.__wbindgen_export_3(e,t*1,1)),r}finally{H.__wbindgen_add_to_stack_pointer(16)}}get_state_machine(e){try{let r=H.__wbindgen_add_to_stack_pointer(-16),i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;H.dotlottieplayerwasm_get_state_machine(r,this.__wbg_ptr,i,a);var t=Mc().getInt32(r+0,!0),n=Mc().getInt32(r+4,!0);let o;return t!==0&&(o=Pc(t,n).slice(),H.__wbindgen_export_3(t,n*1,1)),o}finally{H.__wbindgen_add_to_stack_pointer(16)}}set_position_slot(e,t,n){let r=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),i=Tc;return H.dotlottieplayerwasm_set_position_slot(this.__wbg_ptr,r,i,t,n)!==0}current_loop_count(){return H.dotlottieplayerwasm_current_loop_count(this.__wbg_ptr)>>>0}set_asset_resolver(e){H.dotlottieplayerwasm_set_asset_resolver(this.__wbg_ptr,Lc(e)?0:Cc(e))}sm_framework_setup(){return Ic(H.dotlottieplayerwasm_sm_framework_setup(this.__wbg_ptr))}sm_post_pointer_up(e,t){H.dotlottieplayerwasm_sm_post_pointer_up(this.__wbg_ptr,e,t)}state_machine_load(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_state_machine_load(this.__wbg_ptr,t,n)!==0}load_dotlottie_data(e){let t=Rc(e,H.__wbindgen_export_1),n=Tc;return H.dotlottieplayerwasm_load_dotlottie_data(this.__wbg_ptr,t,n)!==0}sm_get_string_input(e){try{let r=H.__wbindgen_add_to_stack_pointer(-16),i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;H.dotlottieplayerwasm_sm_get_string_input(r,this.__wbg_ptr,i,a);var t=Mc().getInt32(r+0,!0),n=Mc().getInt32(r+4,!0);let o;return t!==0&&(o=Pc(t,n).slice(),H.__wbindgen_export_3(t,n*1,1)),o}finally{H.__wbindgen_add_to_stack_pointer(16)}}sm_set_string_input(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Ac(t,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_sm_set_string_input(this.__wbg_ptr,n,r,i,a)!==0}sm_get_boolean_input(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc,r=H.dotlottieplayerwasm_sm_get_boolean_input(this.__wbg_ptr,t,n);return r===16777215?void 0:r!==0}sm_get_numeric_input(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc,r=H.dotlottieplayerwasm_sm_get_numeric_input(this.__wbg_ptr,t,n);return r===4294967297?void 0:r}sm_post_pointer_down(e,t){H.dotlottieplayerwasm_sm_post_pointer_down(this.__wbg_ptr,e,t)}sm_post_pointer_exit(e,t){H.dotlottieplayerwasm_sm_post_pointer_exit(this.__wbg_ptr,e,t)}sm_post_pointer_move(e,t){H.dotlottieplayerwasm_sm_post_pointer_move(this.__wbg_ptr,e,t)}sm_set_boolean_input(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;return H.dotlottieplayerwasm_sm_set_boolean_input(this.__wbg_ptr,n,r,t)!==0}sm_set_numeric_input(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;return H.dotlottieplayerwasm_sm_set_numeric_input(this.__wbg_ptr,n,r,t)!==0}state_machine_unload(){H.dotlottieplayerwasm_state_machine_unload(this.__wbg_ptr)}sm_post_pointer_enter(e,t){H.dotlottieplayerwasm_sm_post_pointer_enter(this.__wbg_ptr,e,t)}load_animation_from_id(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_load_animation_from_id(this.__wbg_ptr,t,n)!==0}sm_poll_internal_event(){return Ic(H.dotlottieplayerwasm_sm_poll_internal_event(this.__wbg_ptr))}use_frame_interpolation(){return H.dotlottieplayerwasm_use_frame_interpolation(this.__wbg_ptr)!==0}reset_current_loop_count(){H.dotlottieplayerwasm_reset_current_loop_count(this.__wbg_ptr)}sm_override_current_state(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;return H.dotlottieplayerwasm_sm_override_current_state(this.__wbg_ptr,n,r,t)!==0}state_machine_load_from_id(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_state_machine_load_from_id(this.__wbg_ptr,t,n)!==0}set_use_frame_interpolation(e){H.dotlottieplayerwasm_set_use_frame_interpolation(this.__wbg_ptr,e)}constructor(){let e=H.dotlottieplayerwasm_new();return this.__wbg_ptr=e>>>0,Kc.register(this,this.__wbg_ptr,this),this}mode(){return H.dotlottieplayerwasm_mode(this.__wbg_ptr)}play(){return H.dotlottieplayerwasm_play(this.__wbg_ptr)!==0}stop(){return H.dotlottieplayerwasm_stop(this.__wbg_ptr)!==0}tick(e){return H.dotlottieplayerwasm_tick(this.__wbg_ptr,e)!==0}pause(){return H.dotlottieplayerwasm_pause(this.__wbg_ptr)!==0}speed(){return H.dotlottieplayerwasm_speed(this.__wbg_ptr)}width(){return H.dotlottieplayerwasm_width(this.__wbg_ptr)>>>0}height(){return H.dotlottieplayerwasm_height(this.__wbg_ptr)>>>0}render(){return H.dotlottieplayerwasm_render(this.__wbg_ptr)!==0}status(){return H.dotlottieplayerwasm_status(this.__wbg_ptr)}markers(){return Ic(H.dotlottieplayerwasm_markers(this.__wbg_ptr))}sm_fire(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_sm_fire(this.__wbg_ptr,t,n)!==0}sm_stop(){return H.dotlottieplayerwasm_sm_stop(this.__wbg_ptr)!==0}sm_tick(e){return H.dotlottieplayerwasm_sm_tick(this.__wbg_ptr,e)!==0}autoplay(){return H.dotlottieplayerwasm_autoplay(this.__wbg_ptr)!==0}duration(){return H.dotlottieplayerwasm_duration(this.__wbg_ptr)}set_loop(e){H.dotlottieplayerwasm_set_loop(this.__wbg_ptr,e)}set_mode(e){H.dotlottieplayerwasm_set_mode(this.__wbg_ptr,e)}sm_start(e,t){let n=Uc(t,H.__wbindgen_export_1),r=Tc;return H.dotlottieplayerwasm_sm_start(this.__wbg_ptr,e,n,r)!==0}theme_id(){try{let n=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_theme_id(n,this.__wbg_ptr);var e=Mc().getInt32(n+0,!0),t=Mc().getInt32(n+4,!0);let r;return e!==0&&(r=Pc(e,t).slice(),H.__wbindgen_export_3(e,t*1,1)),r}finally{H.__wbindgen_add_to_stack_pointer(16)}}load_font(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Rc(t,H.__wbindgen_export_1),a=Tc;return H.dotlottieplayerwasm_load_font(this.__wbg_ptr,n,r,i,a)!==0}set_frame(e){return H.dotlottieplayerwasm_set_frame(this.__wbg_ptr,e)!==0}set_speed(e){H.dotlottieplayerwasm_set_speed(this.__wbg_ptr,e)}set_theme(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_set_theme(this.__wbg_ptr,t,n)!==0}sm_status(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_sm_status(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}};async function Jc(e,t){if(typeof Response==`function`&&e instanceof Response){if(typeof WebAssembly.instantiateStreaming==`function`)try{return await WebAssembly.instantiateStreaming(e,t)}catch(t){if(e.headers.get(`Content-Type`)!=`application/wasm`)console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t);else throw t}let n=await e.arrayBuffer();return await WebAssembly.instantiate(n,t)}{let n=await WebAssembly.instantiate(e,t);return n instanceof WebAssembly.Instance?{instance:n,module:e}:n}}function Yc(){let e={};return e.wbg={},e.wbg.__wbg_buffer_609cc3eee51ed158=function(e){let t=xc(e).buffer;return Cc(t)},e.wbg.__wbg_call_7cccdd69e0791ae2=function(){return wc(function(e,t,n){return Cc(xc(e).call(xc(t),xc(n)))},arguments)},e.wbg.__wbg_createObjectURL_6e98d2f9c7bd9764=function(){return wc(function(e,t){let n=Ac(URL.createObjectURL(xc(t)),H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;Mc().setInt32(e+4,r,!0),Mc().setInt32(e+0,n,!0)},arguments)},e.wbg.__wbg_ended_b873fb75d0c13ca7=function(e){return xc(e).ended},e.wbg.__wbg_error_7534b8e9a36f1ab4=function(e,t){let n,r;try{n=e,r=t,console.error(Pc(e,t))}finally{H.__wbindgen_export_3(n,r,1)}},e.wbg.__wbg_length_a446193dc22c12f8=function(e){return xc(e).length},e.wbg.__wbg_new_405e22f390576ce2=function(){return Cc({})},e.wbg.__wbg_new_78feb108b6472713=function(){return Cc([])},e.wbg.__wbg_new_8a6f238a6ece86ea=function(){return Cc(Error())},e.wbg.__wbg_new_a12002a7f91c75be=function(e){return Cc(new Uint8Array(xc(e)))},e.wbg.__wbg_newwithbyteoffsetandlength_d97e637ebe145a9a=function(e,t,n){return Cc(new Uint8Array(xc(e),t>>>0,n>>>0))},e.wbg.__wbg_newwithlength_5a5efe313cfd59f1=function(e){return Cc(new Float32Array(e>>>0))},e.wbg.__wbg_newwithsrc_20307ca7e8762a81=function(){return wc(function(e,t){return Cc(new Audio(Pc(e,t)))},arguments)},e.wbg.__wbg_newwithu8arraysequenceandoptions_068570c487f69127=function(){return wc(function(e,t){return Cc(new Blob(xc(e),xc(t)))},arguments)},e.wbg.__wbg_pause_b74c96d69f769518=function(){return wc(function(e){xc(e).pause()},arguments)},e.wbg.__wbg_play_f6ec5fc4e84b0d26=function(){return wc(function(e){return Cc(xc(e).play())},arguments)},e.wbg.__wbg_push_737cfc8c1432c2c6=function(e,t){return xc(e).push(xc(t))},e.wbg.__wbg_revokeObjectURL_27267efebeb457c7=function(){return wc(function(e,t){URL.revokeObjectURL(Pc(e,t))},arguments)},e.wbg.__wbg_set_65595bdd868b3009=function(e,t,n){xc(e).set(xc(t),n>>>0)},e.wbg.__wbg_set_bb8cecf6a62b9f46=function(){return wc(function(e,t,n){return Reflect.set(xc(e),xc(t),xc(n))},arguments)},e.wbg.__wbg_setcurrentTime_64727eddd3966512=function(e,t){xc(e).currentTime=t},e.wbg.__wbg_setindex_4e73afdcd9bb95cd=function(e,t,n){xc(e)[t>>>0]=n},e.wbg.__wbg_settype_39ed370d3edd403c=function(e,t,n){xc(e).type=Pc(t,n)},e.wbg.__wbg_setvolume_3895e06a030ca4f7=function(e,t){xc(e).volume=t},e.wbg.__wbg_stack_0ed75d68575b0f3c=function(e,t){let n=xc(t).stack,r=Ac(n,H.__wbindgen_export_1,H.__wbindgen_export_2),i=Tc;Mc().setInt32(e+4,i,!0),Mc().setInt32(e+0,r,!0)},e.wbg.__wbindgen_is_null=function(e){return xc(e)===null},e.wbg.__wbindgen_is_undefined=function(e){return xc(e)===void 0},e.wbg.__wbindgen_memory=function(){let e=H.memory;return Cc(e)},e.wbg.__wbindgen_number_new=function(e){return Cc(e)},e.wbg.__wbindgen_object_drop_ref=function(e){Ic(e)},e.wbg.__wbindgen_string_get=function(e,t){let n=xc(t),r=typeof n==`string`?n:void 0;var i=Lc(r)?0:Ac(r,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;Mc().setInt32(e+4,a,!0),Mc().setInt32(e+0,i,!0)},e.wbg.__wbindgen_string_new=function(e,t){return Cc(Pc(e,t))},e.wbg.__wbindgen_throw=function(e,t){throw Error(Pc(e,t))},e}function Xc(e,t){return H=e.exports,Zc.__wbindgen_wasm_module=t,jc=null,Bc=null,Ec=null,H}async function Zc(e){if(H!==void 0)return H;if(e!==void 0&&(Object.getPrototypeOf(e)===Object.prototype?{module_or_path:e}=e:console.warn(`using deprecated parameters for the initialization function; pass a single object instead`)),e===void 0)throw Error(`WASM module URL must be provided via DotLottieWasmLoader or setWasmUrl().`);let t=Yc();(typeof e==`string`||typeof Request==`function`&&e instanceof Request||typeof URL==`function`&&e instanceof URL)&&(e=fetch(e));let{instance:n,module:r}=await Jc(await e,t);return Xc(n,r)}var Qc=class{constructor(){_c(this,`_eventListeners`,new Map)}addEventListener(e,t){let n=this._eventListeners.get(e);n||(n=new Set,this._eventListeners.set(e,n)),n.add(t)}removeEventListener(e,t){let n=this._eventListeners.get(e);n&&(t?(n.delete(t),n.size===0&&this._eventListeners.delete(e)):this._eventListeners.delete(e))}dispatch(e){this._eventListeners.get(e.type)?.forEach(t=>t(e))}removeAllEventListeners(){this._eventListeners.clear()}},$c=class e{static _initializeObserver(){e._observer||=new IntersectionObserver(t=>{t.forEach(t=>{let n=e._observedCanvases.get(t.target);n&&(t.isIntersecting?n.unfreeze():n.freeze())})},{threshold:0})}static observe(t,n){e._initializeObserver(),!e._observedCanvases.has(t)&&(e._observedCanvases.set(t,n),e._observer?.observe(t))}static unobserve(t){e._observer?.unobserve(t),e._observedCanvases.delete(t),e._observedCanvases.size===0&&(e._observer?.disconnect(),e._observer=null)}};_c($c,`_observer`,null),_c($c,`_observedCanvases`,new Map);var el=class e{static _initializeObserver(){e._observer||=new ResizeObserver(t=>{t.forEach(t=>{let n=e._observedCanvases.get(t.target);if(!n)return;let[r,i]=n;clearTimeout(i);let a=setTimeout(()=>{r.resize()},100);e._observedCanvases.set(t.target,[r,a])})})}static observe(t,n){e._initializeObserver(),!e._observedCanvases.has(t)&&(e._observedCanvases.set(t,[n,0]),e._observer?.observe(t))}static unobserve(t){let n=e._observedCanvases.get(t);if(n){let e=n[1];e&&clearTimeout(e)}e._observer?.unobserve(t),e._observedCanvases.delete(t),!e._observedCanvases.size&&e._observer&&(e._observer.disconnect(),e._observer=null)}};_c(el,`_observer`,null),_c(el,`_observedCanvases`,new Map);function tl(e){return/^#([\da-f]{6}|[\da-f]{8})$/iu.test(e)}function nl(e){if(!tl(e))return[0,0,0,0];let t=e.replace(`#`,``);return t=t.length===6?`${t}ff`:t,[parseInt(t.slice(0,2),16)/255,parseInt(t.slice(2,4),16)/255,parseInt(t.slice(4,6),16)/255,parseInt(t.slice(6,8),16)/255]}function rl(e){if(e.byteLength<4)return!1;let t=new Uint8Array(e.slice(0,yc.byteLength));for(let e=0;e<yc.length;e+=1)if(yc[e]!==t[e])return!1;return!0}function il(e){return Ste.every(t=>Object.hasOwn(e,t))}function al(e){return typeof e==`string`?/^\s*\{/u.test(e)&&/\}\s*$/u.test(e):il(e)}function ol(){return 1+((vc?window.devicePixelRatio:1)-1)*.75}function sl(e){let t=e.getBoundingClientRect(),n=window.innerHeight||document.documentElement.clientHeight,r=window.innerWidth||document.documentElement.clientWidth;return!(t.bottom<0||t.top>n||t.right<0||t.left>r)}function cl(e){let t=e.target;if(t instanceof HTMLCanvasElement){let n=t.getBoundingClientRect();if(n.width===0||n.height===0||t.width===0||t.height===0)return null;let r=t.width/n.width,i=t.height/n.height,a=(e.clientX-n.left)*r,o=(e.clientY-n.top)*i;return!Number.isFinite(a)||!Number.isFinite(o)||Number.isNaN(a)||Number.isNaN(o)?null:{x:a,y:o}}return null}function ll(e){return new Promise((t,n)=>{let r=new FileReader;r.onerror=()=>n(r.error??Error(`Failed to read image slot source`)),r.onload=()=>t(r.result),r.readAsDataURL(e)})}async function ul(e){if(!/^https?:\/\//i.test(e))return e;let t=await fetch(e);if(!t.ok)throw Error(`Failed to fetch image slot source from URL: ${e}. ${t.status}: ${t.statusText}`);return ll(await t.blob())}function dl(e){let t=e.replace(`OpenUrl: `,``),n=t.indexOf(` | Target: `),r,i;n===-1?(r=t,i=`_blank`):(r=t.substring(0,n),i=t.substring(n+11)),window.open(r,i)}function fl(e,t,n){let r=null,i=t;async function a(t){await e({module_or_path:t})}async function o(t){let n=await fetch(t);if(!n.ok)throw Error(`fetch ${t} responded with ${n.status} ${n.statusText}`);await e({module_or_path:await n.arrayBuffer()})}return{load(){if(!r){let e=i,t=n;r=(async()=>{let n,i;try{await a(e);return}catch(r){n=r,console.warn(`Primary WASM load failed from ${e}: ${r.message}`),console.warn(`Attempting to load WASM from backup URL: ${t}`)}try{await a(t);return}catch(e){i=e,console.warn(`Backup WASM load failed from ${t}: ${e.message}`)}console.warn(`Retrying WASM load with buffered instantiation`);try{await o(e);return}catch(t){console.warn(`Buffered WASM load from ${e} failed: ${t.message}`)}try{await o(t);return}catch(e){throw console.error(`Primary WASM URL failed: ${n.message}`),console.error(`Backup WASM URL failed: ${i.message}`),console.error(`Buffered fallback failed: ${e.message}`),r=null,Error(`WASM loading failed from all sources.`)}})()}return r},setWasmUrl(e){e!==i&&(i=e,r=null)}}}var pl=null;function ml(){return pl??=fl(Zc,`https://cdn.jsdelivr.net/npm/@lottiefiles/dotlottie-web@0.79.1/dist/dotlottie-player.wasm`,`https://unpkg.com/@lottiefiles/dotlottie-web@0.79.1/dist/dotlottie-player.wasm`),pl}var hl=e=>{switch(e){case`reverse`:return Wc.Reverse;case`bounce`:return Wc.Bounce;case`reverse-bounce`:return Wc.ReverseBounce;default:return Wc.Forward}},gl=e=>{switch(e){case Wc.Reverse:return`reverse`;case Wc.Bounce:return`bounce`;case Wc.ReverseBounce:return`reverse-bounce`;default:return`forward`}},_l=e=>{switch(e){case`contain`:return`contain`;case`cover`:return`cover`;case`fill`:return`fill`;case`fit-height`:return`fit-height`;case`fit-width`:return`fit-width`;case`none`:return`none`;default:return`contain`}},vl=class{constructor(e){_c(this,`_canvas`,null),_c(this,`_pendingLoad`,null),_c(this,`_srcFetchAbort`,null),_c(this,`_context`,null),_c(this,`_eventManager`,void 0),_c(this,`_animationFrameId`,null),_c(this,`_frameManager`,void 0),_c(this,`_boundAnimationLoop`,void 0),_c(this,`_dotLottieCore`,null),_c(this,`_stateMachineId`,``),_c(this,`_stateMachineConfig`,null),_c(this,`_isStateMachineRunning`,!1),_c(this,`_renderConfig`,{}),_c(this,`_isFrozen`,!1),_c(this,`_backgroundColor`,null),_c(this,`_lastFrameTime`,null),_c(this,`_boundOnClick`,null),_c(this,`_boundOnPointerUp`,null),_c(this,`_boundOnPointerDown`,null),_c(this,`_boundOnPointerMove`,null),_c(this,`_boundOnPointerEnter`,null),_c(this,`_boundOnPointerLeave`,null),_c(this,`_bufferMismatchCount`,0),_c(this,`_lastExpectedBufferSize`,0),_c(this,`_cachedImageData`,null),_c(this,`_cachedImageDataBuffer`,null),_c(this,`_cachedImageDataByteOffset`,0),_c(this,`_marker`,``),_c(this,`_segment`,null),this._canvas=e.canvas??null,this._eventManager=new Qc,this._frameManager=new xte,this._boundAnimationLoop=this._animationLoop.bind(this),this._renderConfig={...e.renderConfig,devicePixelRatio:e.renderConfig?.devicePixelRatio||ol(),freezeOnOffscreen:e.renderConfig?.freezeOnOffscreen??!0};let t=null;e.src&&!e.data&&(this._srcFetchAbort=new AbortController,t=this._fetchData(e.src,this._srcFetchAbort.signal),t.catch(()=>{})),this._initWasm().then(()=>{this._dotLottieCore=this._createCore(),this._dotLottieCore.set_autoplay(e.autoplay??!1),this._dotLottieCore.set_loop(e.loop??!1),this._dotLottieCore.set_loop_count(e.loopCount??0),this._dotLottieCore.set_mode(hl(e.mode??`forward`)),this._dotLottieCore.set_speed(e.speed??1),this._dotLottieCore.set_use_frame_interpolation(e.useFrameInterpolation??!0),e.segment&&e.segment.length===2&&(this._segment=[e.segment[0],e.segment[1]],this._dotLottieCore.set_segment(this._segment[0],this._segment[1])),this._marker=e.marker??``,this._marker&&this._dotLottieCore.set_marker(this._marker),this._dotLottieCore.set_layout(e.layout?.fit??`contain`,e.layout?.align?.[0]??.5,e.layout?.align?.[1]??.5),this._applyAssetResolver(e.assetResolver??null),this._stateMachineId=e.stateMachineId??``,this._stateMachineConfig=e.stateMachineConfig??null,this._onCoreCreated(),this._eventManager.dispatch({type:`ready`}),e.data?this._canvas?this._loadFromData(e.data):this._pendingLoad={data:e.data}:e.src&&(this._canvas?this._loadFromSrc(e.src,t):this._pendingLoad={src:e.src,dataPromise:t}),e.backgroundColor&&this.setBackgroundColor(e.backgroundColor)}).catch(e=>{this._srcFetchAbort?.abort(),console.error(`[dotlottie-web] Initialization failed:`,e),this._eventManager.dispatch({type:`loadError`,error:Error(`Failed to load wasm module: ${e}`)})})}async _initWasm(){return ml().load()}_createCore(){return new qc}_onCoreCreated(){}_setupTarget(e,t){return this._dotLottieCore?this._dotLottieCore.setup_sw_target(e,t):!1}_drainPlayerEvents({skipFrame:e=!1}={}){if(this._dotLottieCore)for(;;){let t=this._dotLottieCore.poll_event();if(t==null)break;switch(t.type){case`Load`:setTimeout(()=>this._eventManager.dispatch({type:`load`}),0);break;case`LoadError`:setTimeout(()=>this._eventManager.dispatch({type:`loadError`,error:Error(`failed to load`)}),0);break;case`Play`:queueMicrotask(()=>this._eventManager.dispatch({type:`play`}));break;case`Pause`:queueMicrotask(()=>this._eventManager.dispatch({type:`pause`}));break;case`Stop`:queueMicrotask(()=>this._eventManager.dispatch({type:`stop`}));break;case`Frame`:{let n=t.frameNo??0;e||queueMicrotask(()=>this._eventManager.dispatch({type:`frame`,currentFrame:n}));break}case`Render`:{let n=t.frameNo??0;e||queueMicrotask(()=>this._eventManager.dispatch({type:`render`,currentFrame:n}));break}case`Loop`:{let e=t.loopCount??0;queueMicrotask(()=>this._eventManager.dispatch({type:`loop`,loopCount:e}));break}case`Complete`:queueMicrotask(()=>this._eventManager.dispatch({type:`complete`}))}}}_discardPlayerEvents(){for(;this._dotLottieCore?.poll_event()!=null;);}_drainSmEvents(){if(this._dotLottieCore){for(;;){let e=this._dotLottieCore.sm_poll_event();if(e==null)break;switch(e.type){case`Start`:queueMicrotask(()=>{this._isStateMachineRunning=!0,this._eventManager.dispatch({type:`stateMachineStart`}),this._startAnimationLoop()});break;case`Stop`:queueMicrotask(()=>{this._isStateMachineRunning=!1,this._eventManager.dispatch({type:`stateMachineStop`}),this._dotLottieCore?.status()!==Gc.Playing&&this._stopAnimationLoop()});break;case`CustomEvent`:this._eventManager.dispatch({type:`stateMachineCustomEvent`,eventName:e.message??``});break;case`BooleanInputChange`:this._eventManager.dispatch({type:`stateMachineBooleanInputValueChange`,inputName:e.name??``,newValue:e.newValue,oldValue:e.oldValue});break;case`NumericInputChange`:this._eventManager.dispatch({type:`stateMachineNumericInputValueChange`,inputName:e.name??``,newValue:e.newValue,oldValue:e.oldValue});break;case`StringInputChange`:this._eventManager.dispatch({type:`stateMachineStringInputValueChange`,inputName:e.name??``,newValue:e.newValue,oldValue:e.oldValue});break;case`InputFired`:this._eventManager.dispatch({type:`stateMachineInputFired`,inputName:e.name??``});break;case`Transition`:this._eventManager.dispatch({type:`stateMachineTransition`,fromState:e.previousState??``,toState:e.newState??``});break;case`StateEntered`:this._eventManager.dispatch({type:`stateMachineStateEntered`,state:e.state??``});break;case`StateExit`:this._eventManager.dispatch({type:`stateMachineStateExit`,state:e.state??``});break;case`Error`:this._eventManager.dispatch({type:`stateMachineError`,error:e.message??``})}}for(;;){let e=this._dotLottieCore.sm_poll_internal_event();if(e==null)break;if(e.type===`Message`){let t=e.message??``;vc&&t.startsWith(`OpenUrl: `)?dl(t):this._eventManager.dispatch({type:`stateMachineInternalMessage`,message:t})}}}}_dispatchError(e){console.error(e),this._eventManager.dispatch({type:`loadError`,error:Error(e)})}async _fetchData(e,t=null){let n=await fetch(e,{signal:t});if(!n.ok)throw Error(`Failed to fetch animation data from URL: ${e}. ${n.status}: ${n.statusText}`);let r=await n.arrayBuffer();return rl(r)?r:new TextDecoder().decode(r)}_loadFromData(e){if(this._dotLottieCore===null)return;if(!this._canvas){console.warn(`[dotlottie-web] Cannot load animation without canvas. Call setCanvas() first.`);return}this._syncCanvasSize(),this._setupTarget(this._canvas.width,this._canvas.height);let t=!1;if(typeof e==`string`){if(t=this._dotLottieCore.load_animation(e),!t&&!al(e)){this._discardPlayerEvents(),this._dispatchError(`Invalid Lottie JSON string: The provided string does not conform to the Lottie JSON format.`);return}}else if(e instanceof ArrayBuffer){if(!rl(e)){this._dispatchError(`Invalid dotLottie ArrayBuffer: The provided ArrayBuffer does not conform to the dotLottie format.`);return}t=this._dotLottieCore.load_dotlottie_data(new Uint8Array(e))}else if(typeof e==`object`){if(!al(e)){this._dispatchError(`Invalid Lottie JSON object: The provided object does not conform to the Lottie JSON format.`);return}t=this._dotLottieCore.load_animation(JSON.stringify(e))}else{this._dispatchError(`Unsupported data type for animation data. Expected:
58
+ `),Gi=3e3,Ki=e=>{let t=Bi(oi(e).content);return Array.isArray(t)?Hi(e).map(e=>e.value).join(``):t?Wi(t):``},qi=`(?:\\p{Emoji_Presentation}|\\p{Emoji}\\uFE0F)\\p{Emoji_Modifier}?`,Ji=RegExp(`^(?:\\p{Regional_Indicator}{2}|${qi}(?:\\u200D${qi})*)$`,`u`),Yi=e=>{if(e.type!==`TEXT`)return!1;let t=Ki(e).trim();return t.length>0&&Ji.test(t)},Xi=e=>Hi(e).map(e=>e.kind===`mention_user`?e.value.replace(/^@/,``):e.value).join(``),Zi=e=>{let t=oi(e),n=si(t.id);if(!n)return null;let r={id:n,senderId:si(t.senderId)??``,senderName:si(t.senderName)??``,type:si(t.type)??`TEXT`,content:Bi(t.content),attachmentName:si(t.attachmentName)??null,attachmentUrl:si(t.attachmentUrl)??null,attachmentKind:si(t.attachmentKind)??null,attachmentThumbnailUrl:si(t.attachmentThumbnailUrl)??null,createdAt:si(t.createdAt)??null,removedAt:si(t.removedAt)??null,removedById:si(t.removedById)??null};return $i(r)?ea(r,r):r},Qi=e=>e.sourceMessageId?{...e,id:e.sourceMessageId}:e,$i=e=>!!e.removedAt,ea=(e,t)=>({...e,content:null,attachmentName:null,attachmentUrl:null,removedAt:e.removedAt??t.removedAt,removedById:e.removedById??t.removedById}),ta=(e,t)=>({...e,content:null,mentionsAll:!1,mentionedUserIds:[],mentionedUsers:[],attachmentId:null,attachmentName:null,attachmentMimeType:null,attachmentUrl:null,attachmentSizeBytes:null,attachments:[],attachmentIds:[],reactionSummary:ei(),pinnedAt:null,pinnedById:null,pinnedByName:null,pinnedByAvatarUrl:null,removedAt:e.removedAt??t.removedAt,removedById:e.removedById??t.removedById,previewUrl:void 0,previewUrls:void 0}),na=e=>typeof e==`string`&&$r.includes(e),ra=e=>e===`SENDER_RECALL`||e===`OWNER_MODERATION`?e:null,ia=e=>{let t=oi(e),n=ci(t.byType).reduce((e,t)=>{let n=oi(t);return na(n.type)&&e.push({type:n.type,count:typeof n.count==`number`?n.count:0,userCount:typeof n.userCount==`number`?n.userCount:0}),e},[]),r=oi(t.mine),i=na(r.type)?{type:r.type,count:typeof r.count==`number`?r.count:0}:null;return{totalCount:typeof t.totalCount==`number`?t.totalCount:0,totalUsers:typeof t.totalUsers==`number`?t.totalUsers:0,byType:n,mine:i}},aa=(e,t)=>{let n=oi(e),r=Ci(n),i={id:si(n.id??n._id??n.messageId??n.clientMessageId),sourceMessageId:si(n.sourceMessageId),clientMessageId:si(n.clientMessageId),conversationId:si(n.conversationId)??t,content:Bi(n.content),mentionsAll:!!n.mentionsAll,mentionedUserIds:ci(n.mentionedUserIds).map(String),mentionedUsers:ci(n.mentionedUsers),senderId:si(n.senderId??n.userId??n.authorId),senderName:si(n.senderName),senderAvatarUrl:si(n.senderAvatarUrl)??null,searchSnippet:si(n.searchSnippet)??null,searchSnippetTruncatedStart:!!n.searchSnippetTruncatedStart,searchSnippetTruncatedEnd:!!n.searchSnippetTruncatedEnd,sequence:si(n.sequence),createdAt:si(n.createdAt)??new Date().toISOString(),status:si(n.status)??`sent`,type:si(n.type)??`TEXT`,systemCategory:si(n.systemCategory)??null,systemMemberCount:typeof n.systemMemberCount==`number`?n.systemMemberCount:null,attachmentId:si(n.attachmentId??n.mediaId??r.id??r.mediaId)??null,attachmentName:si(r.originalName)??null,attachmentKind:si(n.attachmentKind??r.kind)??null,attachmentMimeType:si(n.attachmentMimeType??n.mimeType??r.mimeType??r.type)??null,attachmentUrl:si(n.attachmentUrl??r.url)??null,attachmentSizeBytes:typeof r.sizeBytes==`number`?r.sizeBytes:typeof n.attachmentSizeBytes==`number`?n.attachmentSizeBytes:null,attachments:wi(n.attachments),replyToId:si(n.replyToId)??null,replyTo:Zi(n.replyTo),reactionSummary:ia(n.reactionSummary),pinnedAt:si(n.pinnedAt)??null,pinnedById:si(n.pinnedById)??null,pinnedByName:si(n.pinnedByName)??null,pinnedByAvatarUrl:si(n.pinnedByAvatarUrl)??null,removedAt:si(n.removedAt)??null,removedById:si(n.removedById)??null,removalType:ra(n.removalType)};return $i(i)?ta(i,i):i},oa=e=>{if(!e||e<=0)return``;let t=[`B`,`KB`,`MB`,`GB`],n=e,r=0;for(;n>=1024&&r<t.length-1;)n/=1024,r+=1;return`${n.toFixed(r===0?0:1)} ${t[r]}`},sa=(e,t)=>V(e.conversationId??``,t.conversationId??``)?[[e.clientMessageId,t.clientMessageId],[e.id,t.id],[e.sequence,t.sequence]].some(([e,t])=>t!=null&&V(e,t)):!1,ca=e=>{let t=String(e??``);return/^\d+$/.test(t)?BigInt(t):null},la=e=>[...e].sort((e,t)=>{let n=ca(e.sequence),r=ca(t.sequence);return n===null&&r===null?0:n===null?1:r===null?-1:n===r?0:n<r?-1:1}),ua=(e,t)=>{let n=e.findIndex(e=>sa(e,t));return n===-1?[...e,t]:e.map((e,r)=>{if(r!==n)return e;if($i(e))return ta(e,e);let i={...e,...t};return $i(t)?ta(i,t):i})},da=(e,t)=>la((Array.isArray(t)?t:[]).reduce((e,t)=>ua(e,t),e)),fa=/[̀-ͯ]/g;function pa(e){return e.toLocaleLowerCase(`vi`).normalize(`NFD`).replace(fa,``).replace(/đ/g,`d`)}var ma=Object.create(null);ma.open=`0`,ma.close=`1`,ma.ping=`2`,ma.pong=`3`,ma.message=`4`,ma.upgrade=`5`,ma.noop=`6`;var ha=Object.create(null);Object.keys(ma).forEach(e=>{ha[ma[e]]=e});var ga={type:`error`,data:`parser error`},_a=typeof Blob==`function`||typeof Blob<`u`&&Object.prototype.toString.call(Blob)===`[object BlobConstructor]`,va=typeof ArrayBuffer==`function`,ya=e=>typeof ArrayBuffer.isView==`function`?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,ba=({type:e,data:t},n,r)=>_a&&t instanceof Blob?n?r(t):xa(t,r):va&&(t instanceof ArrayBuffer||ya(t))?n?r(t):xa(new Blob([t]),r):r(ma[e]+(t||``)),xa=(e,t)=>{let n=new FileReader;return n.onload=function(){let e=n.result.split(`,`)[1];t(`b`+(e||``))},n.readAsDataURL(e)};function Sa(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}var Ca;function wa(e,t){if(_a&&e.data instanceof Blob)return e.data.arrayBuffer().then(Sa).then(t);if(va&&(e.data instanceof ArrayBuffer||ya(e.data)))return t(Sa(e.data));ba(e,!1,e=>{Ca||=new TextEncoder,t(Ca.encode(e))})}var Ta=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/`,Ea=typeof Uint8Array>`u`?[]:new Uint8Array(256);for(let e=0;e<64;e++)Ea[Ta.charCodeAt(e)]=e;var gee=e=>{let t=e.length*.75,n=e.length,r,i=0,a,o,s,c;e[e.length-1]===`=`&&(t--,e[e.length-2]===`=`&&t--);let l=new ArrayBuffer(t),u=new Uint8Array(l);for(r=0;r<n;r+=4)a=Ea[e.charCodeAt(r)],o=Ea[e.charCodeAt(r+1)],s=Ea[e.charCodeAt(r+2)],c=Ea[e.charCodeAt(r+3)],u[i++]=a<<2|o>>4,u[i++]=(o&15)<<4|s>>2,u[i++]=(s&3)<<6|c&63;return l},_ee=typeof ArrayBuffer==`function`,Da=(e,t)=>{if(typeof e!=`string`)return{type:`message`,data:Oa(e,t)};let n=e.charAt(0);return n===`b`?{type:`message`,data:vee(e.substring(1),t)}:ha[n]?e.length>1?{type:ha[n],data:e.substring(1)}:{type:ha[n]}:ga},vee=(e,t)=>_ee?Oa(gee(e),t):{base64:!0,data:e},Oa=(e,t)=>{switch(t){case`blob`:return e instanceof Blob?e:new Blob([e]);default:return e instanceof ArrayBuffer?e:e.buffer}},ka=``,yee=(e,t)=>{let n=e.length,r=Array(n),i=0;e.forEach((e,a)=>{ba(e,!1,e=>{r[a]=e,++i===n&&t(r.join(ka))})})},bee=(e,t)=>{let n=e.split(ka),r=[];for(let e=0;e<n.length;e++){let i=Da(n[e],t);if(r.push(i),i.type===`error`)break}return r};function xee(){return new TransformStream({transform(e,t){wa(e,n=>{let r=n.length,i;if(r<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,r);else if(r<65536){i=new Uint8Array(3);let e=new DataView(i.buffer);e.setUint8(0,126),e.setUint16(1,r)}else{i=new Uint8Array(9);let e=new DataView(i.buffer);e.setUint8(0,127),e.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!=`string`&&(i[0]|=128),t.enqueue(i),t.enqueue(n)})}})}var Aa;function ja(e){return e.reduce((e,t)=>e+t.length,0)}function Ma(e,t){if(e[0].length===t)return e.shift();let n=new Uint8Array(t),r=0;for(let i=0;i<t;i++)n[i]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function See(e,t){Aa||=new TextDecoder;let n=[],r=0,i=-1,a=!1;return new TransformStream({transform(o,s){for(n.push(o);;){if(r===0){if(ja(n)<1)break;let e=Ma(n,1);a=(e[0]&128)==128,i=e[0]&127,r=i<126?3:i===126?1:2}else if(r===1){if(ja(n)<2)break;let e=Ma(n,2);i=new DataView(e.buffer,e.byteOffset,e.length).getUint16(0),r=3}else if(r===2){if(ja(n)<8)break;let e=Ma(n,8),t=new DataView(e.buffer,e.byteOffset,e.length),a=t.getUint32(0);if(a>2**21-1){s.enqueue(ga);break}i=a*2**32+t.getUint32(4),r=3}else{if(ja(n)<i)break;let e=Ma(n,i);s.enqueue(Da(a?e:Aa.decode(e),t)),r=0}if(i===0||i>e){s.enqueue(ga);break}}}})}function Na(e){if(e)return Cee(e)}function Cee(e){for(var t in Na.prototype)e[t]=Na.prototype[t];return e}Na.prototype.on=Na.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks[`$`+e]=this._callbacks[`$`+e]||[]).push(t),this},Na.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},Na.prototype.off=Na.prototype.removeListener=Na.prototype.removeAllListeners=Na.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks[`$`+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks[`$`+e],this;for(var r,i=0;i<n.length;i++)if(r=n[i],r===t||r.fn===t){n.splice(i,1);break}return n.length===0&&delete this._callbacks[`$`+e],this},Na.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=Array(arguments.length-1),n=this._callbacks[`$`+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){n=n.slice(0);for(var r=0,i=n.length;r<i;++r)n[r].apply(this,t)}return this},Na.prototype.emitReserved=Na.prototype.emit,Na.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks[`$`+e]||[]},Na.prototype.hasListeners=function(e){return!!this.listeners(e).length};var Pa=typeof Promise==`function`&&typeof Promise.resolve==`function`?e=>Promise.resolve().then(e):(e,t)=>t(e,0),Fa=typeof self<`u`?self:typeof window<`u`?window:Function(`return this`)(),wee=`arraybuffer`;function Ia(e,...t){return t.reduce((t,n)=>(e.hasOwnProperty(n)&&(t[n]=e[n]),t),{})}var Tee=Fa.setTimeout,Eee=Fa.clearTimeout;function La(e,t){t.useNativeTimers?(e.setTimeoutFn=Tee.bind(Fa),e.clearTimeoutFn=Eee.bind(Fa)):(e.setTimeoutFn=Fa.setTimeout.bind(Fa),e.clearTimeoutFn=Fa.clearTimeout.bind(Fa))}var Dee=1.33;function Oee(e){return typeof e==`string`?kee(e):Math.ceil((e.byteLength||e.size)*Dee)}function kee(e){let t=0,n=0;for(let r=0,i=e.length;r<i;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}function Ra(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function Aee(e){let t=``;for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+=`&`),t+=encodeURIComponent(n)+`=`+encodeURIComponent(e[n]));return t}function jee(e){let t={},n=e.split(`&`);for(let e=0,r=n.length;e<r;e++){let r=n[e].split(`=`);t[decodeURIComponent(r[0])]=decodeURIComponent(r[1])}return t}var Mee=class extends Error{constructor(e,t,n){super(e),this.description=t,this.context=n,this.type=`TransportError`}},za=class extends Na{constructor(e){super(),this.writable=!1,La(this,e),this.opts=e,this.query=e.query,this.socket=e.socket,this.supportsBinary=!e.forceBase64}onError(e,t,n){return super.emitReserved(`error`,new Mee(e,t,n)),this}open(){return this.readyState=`opening`,this.doOpen(),this}close(){return(this.readyState===`opening`||this.readyState===`open`)&&(this.doClose(),this.onClose()),this}send(e){this.readyState===`open`&&this.write(e)}onOpen(){this.readyState=`open`,this.writable=!0,super.emitReserved(`open`)}onData(e){let t=Da(e,this.socket.binaryType);this.onPacket(t)}onPacket(e){super.emitReserved(`packet`,e)}onClose(e){this.readyState=`closed`,super.emitReserved(`close`,e)}pause(e){}createUri(e,t={}){return e+`://`+this._hostname()+this._port()+this.opts.path+this._query(t)}_hostname(){let e=this.opts.hostname;return e.indexOf(`:`)===-1?e:`[`+e+`]`}_port(){return this.opts.port&&(this.opts.secure&&Number(this.opts.port)!==443||!this.opts.secure&&Number(this.opts.port)!==80)?`:`+this.opts.port:``}_query(e){let t=Aee(e);return t.length?`?`+t:``}},Nee=class extends za{constructor(){super(...arguments),this._polling=!1}get name(){return`polling`}doOpen(){this._poll()}pause(e){this.readyState=`pausing`;let t=()=>{this.readyState=`paused`,e()};if(this._polling||!this.writable){let e=0;this._polling&&(e++,this.once(`pollComplete`,function(){--e||t()})),this.writable||(e++,this.once(`drain`,function(){--e||t()}))}else t()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved(`poll`)}onData(e){bee(e,this.socket.binaryType).forEach(e=>{if(this.readyState===`opening`&&e.type===`open`&&this.onOpen(),e.type===`close`)return this.onClose({description:`transport closed by the server`}),!1;this.onPacket(e)}),this.readyState!==`closed`&&(this._polling=!1,this.emitReserved(`pollComplete`),this.readyState===`open`&&this._poll())}doClose(){let e=()=>{this.write([{type:`close`}])};this.readyState===`open`?e():this.once(`open`,e)}write(e){this.writable=!1,yee(e,e=>{this.doWrite(e,()=>{this.writable=!0,this.emitReserved(`drain`)})})}uri(){let e=this.opts.secure?`https`:`http`,t=this.query||{};return!1!==this.opts.timestampRequests&&(t[this.opts.timestampParam]=Ra()),!this.supportsBinary&&!t.sid&&(t.b64=1),this.createUri(e,t)}},Ba=!1;try{Ba=typeof XMLHttpRequest<`u`&&`withCredentials`in new XMLHttpRequest}catch{}var Pee=Ba;function Fee(){}var Iee=class extends Nee{constructor(e){if(super(e),typeof location<`u`){let t=location.protocol===`https:`,n=location.port;n||=t?`443`:`80`,this.xd=typeof location<`u`&&e.hostname!==location.hostname||n!==e.port}}doWrite(e,t){let n=this.request({method:`POST`,data:e});n.on(`success`,t),n.on(`error`,(e,t)=>{this.onError(`xhr post error`,e,t)})}doPoll(){let e=this.request();e.on(`data`,this.onData.bind(this)),e.on(`error`,(e,t)=>{this.onError(`xhr poll error`,e,t)}),this.pollXhr=e}},Va=class e extends Na{constructor(e,t,n){super(),this.createRequest=e,La(this,n),this._opts=n,this._method=n.method||`GET`,this._uri=t,this._data=n.data===void 0?null:n.data,this._create()}_create(){var t;let n=Ia(this._opts,`agent`,`pfx`,`key`,`passphrase`,`cert`,`ca`,`ciphers`,`rejectUnauthorized`,`autoUnref`);n.xdomain=!!this._opts.xd;let r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let e in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(e)&&r.setRequestHeader(e,this._opts.extraHeaders[e])}}catch{}if(this._method===`POST`)try{r.setRequestHeader(`Content-type`,`text/plain;charset=UTF-8`)}catch{}try{r.setRequestHeader(`Accept`,`*/*`)}catch{}(t=this._opts.cookieJar)==null||t.addCookies(r),`withCredentials`in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var e;r.readyState===3&&((e=this._opts.cookieJar)==null||e.parseCookies(r.getResponseHeader(`set-cookie`))),r.readyState===4&&(r.status===200||r.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof r.status==`number`?r.status:0)},0))},r.send(this._data)}catch(e){this.setTimeoutFn(()=>{this._onError(e)},0);return}typeof document<`u`&&(this._index=e.requestsCount++,e.requests[this._index]=this)}_onError(e){this.emitReserved(`error`,e,this._xhr),this._cleanup(!0)}_cleanup(t){if(this._xhr!==void 0&&this._xhr!==null){if(this._xhr.onreadystatechange=Fee,t)try{this._xhr.abort()}catch{}typeof document<`u`&&delete e.requests[this._index],this._xhr=null}}_onLoad(){let e=this._xhr.responseText;e!==null&&(this.emitReserved(`data`,e),this.emitReserved(`success`),this._cleanup())}abort(){this._cleanup()}};if(Va.requestsCount=0,Va.requests={},typeof document<`u`){if(typeof attachEvent==`function`)attachEvent(`onunload`,Ha);else if(typeof addEventListener==`function`){let e=`onpagehide`in Fa?`pagehide`:`unload`;addEventListener(e,Ha,!1)}}function Ha(){for(let e in Va.requests)Va.requests.hasOwnProperty(e)&&Va.requests[e].abort()}var Ua=(function(){let e=Ga({xdomain:!1});return e&&e.responseType!==null})(),Wa=class extends Iee{constructor(e){super(e);let t=e&&e.forceBase64;this.supportsBinary=Ua&&!t}request(e={}){return Object.assign(e,{xd:this.xd},this.opts),new Va(Ga,this.uri(),e)}};function Ga(e){let t=e.xdomain;try{if(typeof XMLHttpRequest<`u`&&(!t||Pee))return new XMLHttpRequest}catch{}if(!t)try{return new Fa[[`Active`,`Object`].join(`X`)](`Microsoft.XMLHTTP`)}catch{}}var Ka=typeof navigator<`u`&&typeof navigator.product==`string`&&navigator.product.toLowerCase()===`reactnative`,qa=class extends za{get name(){return`websocket`}doOpen(){let e=this.uri(),t=this.opts.protocols,n=Ka?{}:Ia(this.opts,`agent`,`perMessageDeflate`,`pfx`,`key`,`passphrase`,`cert`,`ca`,`ciphers`,`rejectUnauthorized`,`localAddress`,`protocolVersion`,`origin`,`maxPayload`,`family`,`checkServerIdentity`);this.opts.extraHeaders&&(n.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(e,t,n)}catch(e){return this.emitReserved(`error`,e)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=e=>this.onClose({description:`websocket connection closed`,context:e}),this.ws.onmessage=e=>this.onData(e.data),this.ws.onerror=e=>this.onError(`websocket error`,e)}write(e){this.writable=!1;for(let t=0;t<e.length;t++){let n=e[t],r=t===e.length-1;ba(n,this.supportsBinary,e=>{try{this.doWrite(n,e)}catch{}r&&Pa(()=>{this.writable=!0,this.emitReserved(`drain`)},this.setTimeoutFn)})}}doClose(){this.ws!==void 0&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){let e=this.opts.secure?`wss`:`ws`,t=this.query||{};return this.opts.timestampRequests&&(t[this.opts.timestampParam]=Ra()),this.supportsBinary||(t.b64=1),this.createUri(e,t)}},Ja=Fa.WebSocket||Fa.MozWebSocket,Ya={websocket:class extends qa{createSocket(e,t,n){return Ka?new Ja(e,t,n):t?new Ja(e,t):new Ja(e)}doWrite(e,t){this.ws.send(t)}},webtransport:class extends za{get name(){return`webtransport`}doOpen(){try{this._transport=new WebTransport(this.createUri(`https`),this.opts.transportOptions[this.name])}catch(e){return this.emitReserved(`error`,e)}this._transport.closed.then(()=>{this.onClose()}).catch(e=>{this.onError(`webtransport error`,e)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(e=>{let t=See(2**53-1,this.socket.binaryType),n=e.readable.pipeThrough(t).getReader(),r=xee();r.readable.pipeTo(e.writable),this._writer=r.writable.getWriter();let i=()=>{n.read().then(({done:e,value:t})=>{e||(this.onPacket(t),i())}).catch(e=>{})};i();let a={type:`open`};this.query.sid&&(a.data=`{"sid":"${this.query.sid}"}`),this._writer.write(a).then(()=>this.onOpen())})})}write(e){this.writable=!1;for(let t=0;t<e.length;t++){let n=e[t],r=t===e.length-1;this._writer.write(n).then(()=>{r&&Pa(()=>{this.writable=!0,this.emitReserved(`drain`)},this.setTimeoutFn)})}}doClose(){var e;(e=this._transport)==null||e.close()}},polling:Wa},Xa=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Za=[`source`,`protocol`,`authority`,`userInfo`,`user`,`password`,`host`,`port`,`relative`,`path`,`directory`,`file`,`query`,`anchor`];function Qa(e){if(e.length>8e3)throw`URI too long`;let t=e,n=e.indexOf(`[`),r=e.indexOf(`]`);n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,`;`)+e.substring(r,e.length));let i=Xa.exec(e||``),a={},o=14;for(;o--;)a[Za[o]]=i[o]||``;return n!=-1&&r!=-1&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,`:`),a.authority=a.authority.replace(`[`,``).replace(`]`,``).replace(/;/g,`:`),a.ipv6uri=!0),a.pathNames=$a(a,a.path),a.queryKey=eo(a,a.query),a}function $a(e,t){let n=t.replace(/\/{2,9}/g,`/`).split(`/`);return(t.slice(0,1)==`/`||t.length===0)&&n.splice(0,1),t.slice(-1)==`/`&&n.splice(n.length-1,1),n}function eo(e,t){let n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(e,t,r){t&&(n[t]=r)}),n}var to=typeof addEventListener==`function`&&typeof removeEventListener==`function`,no=[];to&&addEventListener(`offline`,()=>{no.forEach(e=>e())},!1);var ro=class e extends Na{constructor(e,t){if(super(),this.binaryType=wee,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,e&&typeof e==`object`&&(t=e,e=null),e){let n=Qa(e);t.hostname=n.host,t.secure=n.protocol===`https`||n.protocol===`wss`,t.port=n.port,n.query&&(t.query=n.query)}else t.host&&(t.hostname=Qa(t.host).host);La(this,t),this.secure=t.secure==null?typeof location<`u`&&location.protocol===`https:`:t.secure,t.hostname&&!t.port&&(t.port=this.secure?`443`:`80`),this.hostname=t.hostname||(typeof location<`u`?location.hostname:`localhost`),this.port=t.port||(typeof location<`u`&&location.port?location.port:this.secure?`443`:`80`),this.transports=[],this._transportsByName={},t.transports.forEach(e=>{let t=e.prototype.name;this.transports.push(t),this._transportsByName[t]=e}),this.opts=Object.assign({path:`/engine.io`,agent:!1,withCredentials:!1,upgrade:!0,timestampParam:`t`,rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},t),this.opts.path=this.opts.path.replace(/\/$/,``)+(this.opts.addTrailingSlash?`/`:``),typeof this.opts.query==`string`&&(this.opts.query=jee(this.opts.query)),to&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener(`beforeunload`,this._beforeunloadEventListener,!1)),this.hostname!==`localhost`&&(this._offlineEventListener=()=>{this._onClose(`transport close`,{description:`network connection lost`})},no.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(e){let t=Object.assign({},this.opts.query);t.EIO=4,t.transport=e,this.id&&(t.sid=this.id);let n=Object.assign({},this.opts,{query:t,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[e]);return new this._transportsByName[e](n)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved(`error`,`No transports available`)},0);return}let t=this.opts.rememberUpgrade&&e.priorWebsocketSuccess&&this.transports.indexOf(`websocket`)!==-1?`websocket`:this.transports[0];this.readyState=`opening`;let n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(e){this.transport&&this.transport.removeAllListeners(),this.transport=e,e.on(`drain`,this._onDrain.bind(this)).on(`packet`,this._onPacket.bind(this)).on(`error`,this._onError.bind(this)).on(`close`,e=>this._onClose(`transport close`,e))}onOpen(){this.readyState=`open`,e.priorWebsocketSuccess=this.transport.name===`websocket`,this.emitReserved(`open`),this.flush()}_onPacket(e){if(this.readyState===`opening`||this.readyState===`open`||this.readyState===`closing`)switch(this.emitReserved(`packet`,e),this.emitReserved(`heartbeat`),e.type){case`open`:this.onHandshake(JSON.parse(e.data));break;case`ping`:this._sendPacket(`pong`),this.emitReserved(`ping`),this.emitReserved(`pong`),this._resetPingTimeout();break;case`error`:let t=Error(`server error`);t.code=e.data,this._onError(t);break;case`message`:this.emitReserved(`data`,e.data),this.emitReserved(`message`,e.data)}}onHandshake(e){this.emitReserved(`handshake`,e),this.id=e.sid,this.transport.query.sid=e.sid,this._pingInterval=e.pingInterval,this._pingTimeout=e.pingTimeout,this._maxPayload=e.maxPayload,this.onOpen(),this.readyState!==`closed`&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);let e=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+e,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose(`ping timeout`)},e),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved(`drain`):this.flush()}flush(){if(this.readyState!==`closed`&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){let e=this._getWritablePackets();this.transport.send(e),this._prevBufferLen=e.length,this.emitReserved(`flush`)}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name===`polling`&&this.writeBuffer.length>1))return this.writeBuffer;let e=1;for(let t=0;t<this.writeBuffer.length;t++){let n=this.writeBuffer[t].data;if(n&&(e+=Oee(n)),t>0&&e>this._maxPayload)return this.writeBuffer.slice(0,t);e+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;let e=Date.now()>this._pingTimeoutTime;return e&&(this._pingTimeoutTime=0,Pa(()=>{this._onClose(`ping timeout`)},this.setTimeoutFn)),e}write(e,t,n){return this._sendPacket(`message`,e,t,n),this}send(e,t,n){return this._sendPacket(`message`,e,t,n),this}_sendPacket(e,t,n,r){if(typeof t==`function`&&(r=t,t=void 0),typeof n==`function`&&(r=n,n=null),this.readyState===`closing`||this.readyState===`closed`)return;n||={},n.compress=!1!==n.compress;let i={type:e,data:t,options:n};this.emitReserved(`packetCreate`,i),this.writeBuffer.push(i),r&&this.once(`flush`,r),this.flush()}close(){let e=()=>{this._onClose(`forced close`),this.transport.close()},t=()=>{this.off(`upgrade`,t),this.off(`upgradeError`,t),e()},n=()=>{this.once(`upgrade`,t),this.once(`upgradeError`,t)};return(this.readyState===`opening`||this.readyState===`open`)&&(this.readyState=`closing`,this.writeBuffer.length?this.once(`drain`,()=>{this.upgrading?n():e()}):this.upgrading?n():e()),this}_onError(t){if(e.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState===`opening`)return this.transports.shift(),this._open();this.emitReserved(`error`,t),this._onClose(`transport error`,t)}_onClose(e,t){if(this.readyState===`opening`||this.readyState===`open`||this.readyState===`closing`){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners(`close`),this.transport.close(),this.transport.removeAllListeners(),to&&(this._beforeunloadEventListener&&removeEventListener(`beforeunload`,this._beforeunloadEventListener,!1),this._offlineEventListener)){let e=no.indexOf(this._offlineEventListener);e!==-1&&no.splice(e,1)}this.readyState=`closed`,this.id=null,this.emitReserved(`close`,e,t),this.writeBuffer=[],this._prevBufferLen=0}}};ro.protocol=4;var io=class extends ro{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState===`open`&&this.opts.upgrade)for(let e=0;e<this._upgrades.length;e++)this._probe(this._upgrades[e])}_probe(e){let t=this.createTransport(e),n=!1;ro.priorWebsocketSuccess=!1;let r=()=>{n||(t.send([{type:`ping`,data:`probe`}]),t.once(`packet`,e=>{if(!n)if(e.type===`pong`&&e.data===`probe`){if(this.upgrading=!0,this.emitReserved(`upgrading`,t),!t)return;ro.priorWebsocketSuccess=t.name===`websocket`,this.transport.pause(()=>{n||this.readyState!==`closed`&&(l(),this.setTransport(t),t.send([{type:`upgrade`}]),this.emitReserved(`upgrade`,t),t=null,this.upgrading=!1,this.flush())})}else{let e=Error(`probe error`);e.transport=t.name,this.emitReserved(`upgradeError`,e)}}))};function i(){n||(n=!0,l(),t.close(),t=null)}let a=e=>{let n=Error(`probe error: `+e);n.transport=t.name,i(),this.emitReserved(`upgradeError`,n)};function o(){a(`transport closed`)}function s(){a(`socket closed`)}function c(e){t&&e.name!==t.name&&i()}let l=()=>{t.removeListener(`open`,r),t.removeListener(`error`,a),t.removeListener(`close`,o),this.off(`close`,s),this.off(`upgrading`,c)};t.once(`open`,r),t.once(`error`,a),t.once(`close`,o),this.once(`close`,s),this.once(`upgrading`,c),this._upgrades.indexOf(`webtransport`)!==-1&&e!==`webtransport`?this.setTimeoutFn(()=>{n||t.open()},200):t.open()}onHandshake(e){this._upgrades=this._filterUpgrades(e.upgrades),super.onHandshake(e)}_filterUpgrades(e){let t=[];for(let n=0;n<e.length;n++)~this.transports.indexOf(e[n])&&t.push(e[n]);return t}},ao=class extends io{constructor(e,t={}){let n=typeof e==`object`,r=n?{...e}:{...t};(!r.transports||r.transports&&typeof r.transports[0]==`string`)&&(r.transports=(r.transports||[`polling`,`websocket`,`webtransport`]).map(e=>Ya[e]).filter(e=>!!e)),super(n?r:e,r)}};ao.protocol;function oo(e,t=``,n){let r=e;n||=typeof location<`u`&&location,e??=n.protocol+`//`+n.host,typeof e==`string`&&(e.charAt(0)===`/`&&(e=e.charAt(1)===`/`?n.protocol+e:n.host+e),/^(https?|wss?):\/\//.test(e)||(e=n===void 0?`https://`+e:n.protocol+`//`+e),r=Qa(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port=`80`:/^(http|ws)s$/.test(r.protocol)&&(r.port=`443`)),r.path=r.path||`/`;let i=r.host.indexOf(`:`)===-1?r.host:`[`+r.host+`]`;return r.id=r.protocol+`://`+i+`:`+r.port+t,r.href=r.protocol+`://`+i+(n&&n.port===r.port?``:`:`+r.port),r}var so=typeof ArrayBuffer==`function`,co=e=>typeof ArrayBuffer.isView==`function`?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,lo=Object.prototype.toString,uo=typeof Blob==`function`||typeof Blob<`u`&&lo.call(Blob)===`[object BlobConstructor]`,fo=typeof File==`function`||typeof File<`u`&&lo.call(File)===`[object FileConstructor]`;function po(e){return so&&(e instanceof ArrayBuffer||co(e))||uo&&e instanceof Blob||fo&&e instanceof File}function mo(e,t){if(!e||typeof e!=`object`)return!1;if(Array.isArray(e)){for(let t=0,n=e.length;t<n;t++)if(mo(e[t]))return!0;return!1}if(po(e))return!0;if(e.toJSON&&typeof e.toJSON==`function`&&arguments.length===1)return mo(e.toJSON(),!0);for(let t in e)if(Object.prototype.hasOwnProperty.call(e,t)&&mo(e[t]))return!0;return!1}function ho(e){let t=[],n=e.data,r=e;return r.data=go(n,t),r.attachments=t.length,{packet:r,buffers:t}}function go(e,t,n){if(!e)return e;if(po(e)){let n={_placeholder:!0,num:t.length};return t.push(e),n}if(Array.isArray(e)){let n=Array(e.length);for(let r=0;r<e.length;r++)n[r]=go(e[r],t);return n}if(typeof e==`object`&&!(e instanceof Date)){if(e.toJSON&&typeof e.toJSON==`function`&&!n)return go(e.toJSON(),t,!0);let r={};for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&(r[n]=go(e[n],t));return r}return e}function _o(e,t){return e.data=vo(e.data,t),delete e.attachments,e}function vo(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num==`number`&&e.num>=0&&e.num<t.length)return t[e.num];throw Error(`illegal attachments`)}if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=vo(e[n],t);else if(typeof e==`object`)for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=vo(e[n],t));return e}var yo=s({Decoder:()=>Co,Encoder:()=>So,PacketType:()=>xo,isPacketValid:()=>Ao,protocol:()=>5}),bo=[`connect`,`connect_error`,`disconnect`,`disconnecting`,`newListener`,`removeListener`],xo;(function(e){e[e.CONNECT=0]=`CONNECT`,e[e.DISCONNECT=1]=`DISCONNECT`,e[e.EVENT=2]=`EVENT`,e[e.ACK=3]=`ACK`,e[e.CONNECT_ERROR=4]=`CONNECT_ERROR`,e[e.BINARY_EVENT=5]=`BINARY_EVENT`,e[e.BINARY_ACK=6]=`BINARY_ACK`})(xo||={});var So=class{constructor(e){this.replacer=e}encode(e){return(e.type===xo.EVENT||e.type===xo.ACK)&&mo(e)?this.encodeAsBinary({type:e.type===xo.EVENT?xo.BINARY_EVENT:xo.BINARY_ACK,nsp:e.nsp,data:e.data,id:e.id}):[this.encodeAsString(e)]}encodeAsString(e){let t=``+e.type;return(e.type===xo.BINARY_EVENT||e.type===xo.BINARY_ACK)&&(t+=e.attachments+`-`),e.nsp&&e.nsp!==`/`&&(t+=e.nsp+`,`),e.id!=null&&(t+=e.id),e.data!=null&&(t+=JSON.stringify(e.data,this.replacer)),t}encodeAsBinary(e){let t=ho(e),n=this.encodeAsString(t.packet),r=t.buffers;return r.unshift(n),r}},Co=class e extends Na{constructor(e){super(),this.opts=Object.assign({reviver:void 0,maxAttachments:10},typeof e==`function`?{reviver:e}:e)}add(e){let t;if(typeof e==`string`){if(this.reconstructor)throw Error(`got plaintext data when reconstructing a packet`);t=this.decodeString(e);let n=t.type===xo.BINARY_EVENT;n||t.type===xo.BINARY_ACK?(t.type=n?xo.EVENT:xo.ACK,this.reconstructor=new wo(t)):super.emitReserved(`decoded`,t)}else if(po(e)||e.base64)if(this.reconstructor)t=this.reconstructor.takeBinaryData(e),t&&(this.reconstructor=null,super.emitReserved(`decoded`,t));else throw Error(`got binary data when not reconstructing a packet`);else throw Error(`Unknown type: `+e)}decodeString(t){let n=0,r={type:Number(t.charAt(0))};if(xo[r.type]===void 0)throw Error(`unknown packet type `+r.type);if(r.type===xo.BINARY_EVENT||r.type===xo.BINARY_ACK){let e=n+1;for(;t.charAt(++n)!==`-`&&n!=t.length;);let i=t.substring(e,n);if(i!=Number(i)||t.charAt(n)!==`-`)throw Error(`Illegal attachments`);let a=Number(i);if(!Eo(a)||a<1)throw Error(`Illegal attachments`);if(a>this.opts.maxAttachments)throw Error(`too many attachments`);r.attachments=a}if(t.charAt(n+1)===`/`){let e=n+1;for(;++n&&t.charAt(n)!==`,`&&n!==t.length;);r.nsp=t.substring(e,n)}else r.nsp=`/`;let i=t.charAt(n+1);if(i!==``&&Number(i)==i){let e=n+1;for(;++n;){let e=t.charAt(n);if(e==null||Number(e)!=e){--n;break}if(n===t.length)break}r.id=Number(t.substring(e,n+1))}if(t.charAt(++n)){let i=this.tryParse(t.substr(n));if(e.isPayloadValid(r.type,i))r.data=i;else throw Error(`invalid payload`)}return r}tryParse(e){try{return JSON.parse(e,this.opts.reviver)}catch{return!1}}static isPayloadValid(e,t){switch(e){case xo.CONNECT:return Oo(t);case xo.DISCONNECT:return t===void 0;case xo.CONNECT_ERROR:return typeof t==`string`||Oo(t);case xo.EVENT:case xo.BINARY_EVENT:return Array.isArray(t)&&(typeof t[0]==`number`||typeof t[0]==`string`&&bo.indexOf(t[0])===-1);case xo.ACK:case xo.BINARY_ACK:return Array.isArray(t)}}destroy(){this.reconstructor&&=(this.reconstructor.finishedReconstruction(),null)}},wo=class{constructor(e){this.packet=e,this.buffers=[],this.reconPack=e}takeBinaryData(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){let e=_o(this.reconPack,this.buffers);return this.finishedReconstruction(),e}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}};function To(e){return typeof e==`string`}var Eo=Number.isInteger||function(e){return typeof e==`number`&&isFinite(e)&&Math.floor(e)===e};function Do(e){return e===void 0||Eo(e)}function Oo(e){return Object.prototype.toString.call(e)===`[object Object]`}function ko(e,t){switch(e){case xo.CONNECT:return t===void 0||Oo(t);case xo.DISCONNECT:return t===void 0;case xo.EVENT:return Array.isArray(t)&&(typeof t[0]==`number`||typeof t[0]==`string`&&bo.indexOf(t[0])===-1);case xo.ACK:return Array.isArray(t);case xo.CONNECT_ERROR:return typeof t==`string`||Oo(t);default:return!1}}function Ao(e){return To(e.nsp)&&Do(e.id)&&ko(e.type,e.data)}function jo(e,t,n){return e.on(t,n),function(){e.off(t,n)}}var Mo=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1}),No=class extends Na{constructor(e,t,n){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=e,this.nsp=t,n&&n.auth&&(this.auth=n.auth),this._opts=Object.assign({},n),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;let e=this.io;this.subs=[jo(e,`open`,this.onopen.bind(this)),jo(e,`packet`,this.onpacket.bind(this)),jo(e,`error`,this.onerror.bind(this)),jo(e,`close`,this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState===`open`&&this.onopen(),this)}open(){return this.connect()}send(...e){return e.unshift(`message`),this.emit.apply(this,e),this}emit(e,...t){if(Mo.hasOwnProperty(e))throw Error(`"`+e.toString()+`" is a reserved event name`);if(t.unshift(e),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(t),this;let n={type:xo.EVENT,data:t};if(n.options={},n.options.compress=this.flags.compress!==!1,typeof t[t.length-1]==`function`){let e=this.ids++,r=t.pop();this._registerAckCallback(e,r),n.id=e}let r=this.io.engine?.transport?.writable,i=this.connected&&!this.io.engine?._hasPingExpired();return this.flags.volatile&&!r||(i?(this.notifyOutgoingListeners(n),this.packet(n)):this.sendBuffer.push(n)),this.flags={},this}_registerAckCallback(e,t){let n=this.flags.timeout??this._opts.ackTimeout;if(n===void 0){this.acks[e]=t;return}let r=this.io.setTimeoutFn(()=>{delete this.acks[e];for(let t=0;t<this.sendBuffer.length;t++)this.sendBuffer[t].id===e&&this.sendBuffer.splice(t,1);t.call(this,Error(`operation has timed out`))},n),i=(...e)=>{this.io.clearTimeoutFn(r),t.apply(this,e)};i.withError=!0,this.acks[e]=i}emitWithAck(e,...t){return new Promise((n,r)=>{let i=(e,t)=>e?r(e):n(t);i.withError=!0,t.push(i),this.emit(e,...t)})}_addToQueue(e){let t;typeof e[e.length-1]==`function`&&(t=e.pop());let n={id:this._queueSeq++,tryCount:0,pending:!1,args:e,flags:Object.assign({fromQueue:!0},this.flags)};e.push((e,...r)=>(this._queue[0],e===null?(this._queue.shift(),t&&t(null,...r)):n.tryCount>this._opts.retries&&(this._queue.shift(),t&&t(e)),n.pending=!1,this._drainQueue())),this._queue.push(n),this._drainQueue()}_drainQueue(e=!1){if(!this.connected||this._queue.length===0)return;let t=this._queue[0];t.pending&&!e||(t.pending=!0,t.tryCount++,this.flags=t.flags,this.emit.apply(this,t.args))}packet(e){e.nsp=this.nsp,this.io._packet(e)}onopen(){typeof this.auth==`function`?this.auth(e=>{this._sendConnectPacket(e)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(e){this.packet({type:xo.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},e):e})}onerror(e){this.connected||this.emitReserved(`connect_error`,e)}onclose(e,t){this.connected=!1,delete this.id,this.emitReserved(`disconnect`,e,t),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(e=>{if(!this.sendBuffer.some(t=>String(t.id)===e)){let t=this.acks[e];delete this.acks[e],t.withError&&t.call(this,Error(`socket has been disconnected`))}})}onpacket(e){if(e.nsp===this.nsp)switch(e.type){case xo.CONNECT:e.data&&e.data.sid?this.onconnect(e.data.sid,e.data.pid):this.emitReserved(`connect_error`,Error(`It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)`));break;case xo.EVENT:case xo.BINARY_EVENT:this.onevent(e);break;case xo.ACK:case xo.BINARY_ACK:this.onack(e);break;case xo.DISCONNECT:this.ondisconnect();break;case xo.CONNECT_ERROR:this.destroy();let t=Error(e.data.message);t.data=e.data.data,this.emitReserved(`connect_error`,t)}}onevent(e){let t=e.data||[];e.id!=null&&t.push(this.ack(e.id)),this.connected?this.emitEvent(t):this.receiveBuffer.push(Object.freeze(t))}emitEvent(e){if(this._anyListeners&&this._anyListeners.length){let t=this._anyListeners.slice();for(let n of t)n.apply(this,e)}super.emit.apply(this,e),this._pid&&e.length&&typeof e[e.length-1]==`string`&&(this._lastOffset=e[e.length-1])}ack(e){let t=this,n=!1;return function(...r){n||(n=!0,t.packet({type:xo.ACK,id:e,data:r}))}}onack(e){let t=this.acks[e.id];typeof t==`function`&&(delete this.acks[e.id],t.withError&&e.data.unshift(null),t.apply(this,e.data))}onconnect(e,t){this.id=e,this.recovered=t&&this._pid===t,this._pid=t,this.connected=!0,this.emitBuffered(),this._drainQueue(!0),this.emitReserved(`connect`)}emitBuffered(){this.receiveBuffer.forEach(e=>this.emitEvent(e)),this.receiveBuffer=[],this.sendBuffer.forEach(e=>{this.notifyOutgoingListeners(e),this.packet(e)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose(`io server disconnect`)}destroy(){this.subs&&=(this.subs.forEach(e=>e()),void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:xo.DISCONNECT}),this.destroy(),this.connected&&this.onclose(`io client disconnect`),this}close(){return this.disconnect()}compress(e){return this.flags.compress=e,this}get volatile(){return this.flags.volatile=!0,this}timeout(e){return this.flags.timeout=e,this}onAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(e),this}prependAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(e),this}offAny(e){if(!this._anyListeners)return this;if(e){let t=this._anyListeners;for(let n=0;n<t.length;n++)if(e===t[n])return t.splice(n,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(e),this}prependAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(e),this}offAnyOutgoing(e){if(!this._anyOutgoingListeners)return this;if(e){let t=this._anyOutgoingListeners;for(let n=0;n<t.length;n++)if(e===t[n])return t.splice(n,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(e){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){let t=this._anyOutgoingListeners.slice();for(let n of t)n.apply(this,e.data)}}};function Po(e){e||={},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}Po.prototype.duration=function(){var e=this.ms*this.factor**+this.attempts++;if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+n:e-n}return Math.min(e,this.max)|0},Po.prototype.reset=function(){this.attempts=0},Po.prototype.setMin=function(e){this.ms=e},Po.prototype.setMax=function(e){this.max=e},Po.prototype.setJitter=function(e){this.jitter=e};var Fo=class extends Na{constructor(e,t){super(),this.nsps={},this.subs=[],e&&typeof e==`object`&&(t=e,e=void 0),t||={},t.path=t.path||`/socket.io`,this.opts=t,La(this,t),this.reconnection(t.reconnection!==!1),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(t.randomizationFactor??.5),this.backoff=new Po({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(t.timeout==null?2e4:t.timeout),this._readyState=`closed`,this.uri=e;let n=t.parser||yo;this.encoder=new n.Encoder,this.decoder=new n.Decoder,this._autoConnect=t.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(e){return arguments.length?(this._reconnection=!!e,e||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(e){return e===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=e,this)}reconnectionDelay(e){var t;return e===void 0?this._reconnectionDelay:(this._reconnectionDelay=e,(t=this.backoff)==null||t.setMin(e),this)}randomizationFactor(e){var t;return e===void 0?this._randomizationFactor:(this._randomizationFactor=e,(t=this.backoff)==null||t.setJitter(e),this)}reconnectionDelayMax(e){var t;return e===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=e,(t=this.backoff)==null||t.setMax(e),this)}timeout(e){return arguments.length?(this._timeout=e,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(e){if(~this._readyState.indexOf(`open`))return this;this.engine=new ao(this.uri,this.opts);let t=this.engine,n=this;this._readyState=`opening`,this.skipReconnect=!1;let r=jo(t,`open`,function(){n.onopen(),e&&e()}),i=t=>{this.cleanup(),this._readyState=`closed`,this.emitReserved(`error`,t),e?e(t):this.maybeReconnectOnOpen()},a=jo(t,`error`,i);if(!1!==this._timeout){let e=this._timeout,n=this.setTimeoutFn(()=>{r(),i(Error(`timeout`)),t.close()},e);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}return this.subs.push(r),this.subs.push(a),this}connect(e){return this.open(e)}onopen(){this.cleanup(),this._readyState=`open`,this.emitReserved(`open`);let e=this.engine;this.subs.push(jo(e,`ping`,this.onping.bind(this)),jo(e,`data`,this.ondata.bind(this)),jo(e,`error`,this.onerror.bind(this)),jo(e,`close`,this.onclose.bind(this)),jo(this.decoder,`decoded`,this.ondecoded.bind(this)))}onping(){this.emitReserved(`ping`)}ondata(e){try{this.decoder.add(e)}catch(e){this.onclose(`parse error`,e)}}ondecoded(e){Pa(()=>{this.emitReserved(`packet`,e)},this.setTimeoutFn)}onerror(e){this.emitReserved(`error`,e)}socket(e,t){let n=this.nsps[e];return n?this._autoConnect&&!n.active&&n.connect():(n=new No(this,e,t),this.nsps[e]=n),n}_destroy(e){let t=Object.keys(this.nsps);for(let e of t)if(this.nsps[e].active)return;this._close()}_packet(e){let t=this.encoder.encode(e);for(let n=0;n<t.length;n++)this.engine.write(t[n],e.options)}cleanup(){this.subs.forEach(e=>e()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose(`forced close`)}disconnect(){return this._close()}onclose(e,t){var n;this.cleanup(),(n=this.engine)==null||n.close(),this.backoff.reset(),this._readyState=`closed`,this.emitReserved(`close`,e,t),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;let e=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved(`reconnect_failed`),this._reconnecting=!1;else{let t=this.backoff.duration();this._reconnecting=!0;let n=this.setTimeoutFn(()=>{e.skipReconnect||(this.emitReserved(`reconnect_attempt`,e.backoff.attempts),!e.skipReconnect&&e.open(t=>{t?(e._reconnecting=!1,e.reconnect(),this.emitReserved(`reconnect_error`,t)):e.onreconnect()}))},t);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}}onreconnect(){let e=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved(`reconnect`,e)}},Io={};function Lo(e,t){typeof e==`object`&&(t=e,e=void 0),t||={};let n=oo(e,t.path||`/socket.io`),r=n.source,i=n.id,a=n.path,o=Io[i]&&a in Io[i].nsps,s=t.forceNew||t[`force new connection`]||!1===t.multiplex||o,c;return s?c=new Fo(r,t):(Io[i]||(Io[i]=new Fo(r,t)),c=Io[i]),n.query&&!t.query&&(t.query=n.queryKey),c.socket(n.path,t)}Object.assign(Lo,{Manager:Fo,Socket:No,io:Lo,connect:Lo});function Ro(e,t=600){if(e==null||e===``)return!0;let n=Number(e)*1e3;return!Number.isFinite(n)||Date.now()>=n-t*1e3}var zo=/[̀-ͯ]/g;function Bo(e){return e.toLocaleLowerCase(`vi`).normalize(`NFD`).replace(zo,``).replace(/đ/g,`d`)}function Vo(e){return e.map(([e,t])=>`${Ho(e)}=${Ho(String(t))}`).join(`&`)}function Ho(e){return encodeURIComponent(e).replace(/[!'()~]/g,e=>`%${e.charCodeAt(0).toString(16).toUpperCase()}`).replace(/%20/g,`+`)}var Uo=e=>typeof e==`object`&&!!e&&!Array.isArray(e),Wo=e=>{let t=Uo(e)&&Uo(e.data)?e.data:e;return Uo(t)?t:{}};function Go(e){let t=Wo(e).pageInfo,n=Uo(t)&&typeof t.nextCursor==`string`?t.nextCursor:null;return{nextCursor:n,hasMore:Uo(t)&&t.hasMore===!0&&n!==null}}function Ko(e){let t=Wo(e).items;return Array.isArray(t)?t.filter(Uo):[]}function qo(e,t,n){return`${e}:${t}:${n}`}function Jo(e){return e.flatMap(e=>{let t=String(e.id??``),n=Array.isArray(e.attachments)?e.attachments.filter(Uo):[];return n.length===0?[{...e,sourceMessageId:t}]:n.map((n,r)=>({...e,id:qo(t,String(n.id??``),r),sourceMessageId:t,attachmentId:n.id??null,attachment:n,attachments:[n]}))})}function Yo(e){return{items:Jo(Ko(e)),pageInfo:Go(e)}}var Xo=e=>JSON.stringify({c:e.sourceCursor,s:e.skippedItems}),Zo=e=>{if(!e)return{sourceCursor:null,skippedItems:0};try{let t=JSON.parse(e);if(Uo(t))return{sourceCursor:typeof t.c==`string`?t.c:null,skippedItems:typeof t.s==`number`&&Number.isInteger(t.s)&&t.s>0?t.s:0}}catch{return{sourceCursor:null,skippedItems:0}}return{sourceCursor:null,skippedItems:0}},Qo=30,$o=new Map,es=(e,t)=>{if($o.delete(e),$o.set(e,t),$o.size>Qo){let e=$o.keys().next().value;e!==void 0&&$o.delete(e)}};async function ts({fetchSourcePage:e,cursor:t,limit:n,cacheScope:r}){let{sourceCursor:i,skippedItems:a}=Zo(t),o=[];for(;;){let t=`${r}|${i??``}`,s=(a>0?$o.get(t):void 0)??await e(i);es(t,s);let c=s.items.slice(a),l=n-o.length,u=c.slice(0,l);if(o.push(...u),c.length>u.length)return{items:o,pageInfo:{nextCursor:Xo({sourceCursor:i,skippedItems:a+u.length}),hasMore:!0}};if(!s.pageInfo.hasMore||!s.pageInfo.nextCursor)return{items:o,pageInfo:{nextCursor:null,hasMore:!1}};if(i=s.pageInfo.nextCursor,a=0,o.length>=n)return{items:o,pageInfo:{nextCursor:Xo({sourceCursor:i,skippedItems:0}),hasMore:!0}}}}var ns=class extends Error{constructor(e,t,n){super(e),this.status=t,this.code=n,this.name=`ChatApiError`}},rs={apiBaseUrl:``,getAccessToken:()=>null},is=null;function as(e){rs=e}var ss=(e,t=rs)=>`${t.apiBaseUrl}${e.startsWith(`/`)?e:`/${e}`}`,cs=e=>ss(`/data/docs/${e}`),ls=(e,t)=>e?/^https?:\/\//i.test(e)?e:ss(e):t?cs(t):null;async function us(e,t={},n=rs,r){let i=new Headers(t.headers),a=r??n.getAccessToken(),o=t.auth!==!1,s={...t};delete s.auth,t.body instanceof FormData||i.set(`Content-Type`,`application/json`),o&&a&&i.set(`Authorization`,`Bearer ${a}`);let c=await fetch(ss(e,n),{...s,headers:i}),l=c.headers.get(`content-type`)?.includes(`application/json`)?await c.json():null;if(!c.ok){let e=l;throw new ns(e?.message??`Request failed with status ${c.status}`,c.status,e?.code)}return l}function ds(e){return us(`/users/${e}`)}function fs(e={}){let t=[];e.cursor&&t.push([`cursor`,e.cursor]),e.limit&&t.push([`limit`,String(e.limit)]),e.search&&t.push([`search`,Bo(e.search)]),e.departmentId&&t.push([`departmentId`,e.departmentId]),e.branchId&&t.push([`branchId`,e.branchId]),e.workStatus?.forEach(e=>t.push([`workStatus`,e]));let n=Vo(t);return us(n?`/users?${n}`:`/users`)}function ps(e){return us(`/departments/by-branch/${e}`)}function ms(e={}){let t=[];e.tagId&&t.push([`tagId`,e.tagId]),e.untagged&&t.push([`untagged`,`true`]);let n=Vo(t);return us(n?`/conversations?${n}`:`/conversations`,{method:`GET`,auth:!0})}function hs(){return us(`/tags`)}function gs(e){return us(`/tags`,{method:`POST`,body:JSON.stringify(e)})}function _s(e,t){return us(`/tags/${e}`,{method:`PATCH`,body:JSON.stringify(t)})}function vs(e){return us(`/tags/${e}`,{method:`DELETE`})}function ys(e,t){return us(`/tags/${e}/conversations`,{method:`PUT`,body:JSON.stringify({conversationIds:t})})}function bs(e,t){return us(`/tags/conversations/${e}`,{method:`PUT`,body:JSON.stringify({tagId:t})})}function xs(e=20){return us(`/conversations/recent?limit=${e}`,{method:`GET`,auth:!0})}function Ss(e){return us(`/conversations/${e}`)}function Cs(e){return us(`/conversations`,{method:`POST`,body:JSON.stringify(e)})}function ws(e,t){return us(`/conversations/${e}`,{method:`PATCH`,body:JSON.stringify(t)})}function Ts(e,t){return us(`/conversations/${e}/group-settings`,{method:`PATCH`,body:JSON.stringify(t)})}function Es(e){return us(`/conversations/${e}/invite-link`)}function Ds(e,t){return us(`/conversations/${e}/invite-link`,{method:`PATCH`,body:JSON.stringify({enabled:t})})}function Os(e){return us(`/conversations/${e}/invite-link/refresh`,{method:`POST`})}function ks(e){return us(`/conversations/join/${e}`)}function As(e){return us(`/conversations/join/${e}`,{method:`POST`})}function js(e,t){return us(`/conversations/${e}/pin`,{method:`PATCH`,body:JSON.stringify({pinned:t})})}function Ms(e){return e?.erpNotificationEnabled!==!1}function Ns(e){return e?.erpDirectMentionNotificationEnabled!==!1}function Ps(){return us(`/users/me/settings`)}function Fs(e){return us(`/users/me/settings`,{method:`PATCH`,body:JSON.stringify(e)})}function Is(e,t){return us(`/conversations/${e}/notification-settings`,{method:`PATCH`,body:JSON.stringify(t)})}function Ls(e){return us(`/conversations/${e}`,{method:`DELETE`})}function Rs(e){return us(`/conversations/${e}/clear`,{method:`POST`})}function zs(e,t){return us(`/conversations/${e}/members`,{method:`POST`,body:JSON.stringify({userId:t})})}function Bs(e,t){return us(`/conversations/${e}/members`,{method:`POST`,body:JSON.stringify({userIds:t})})}function Vs(e,t){return us(`/conversations/${e}/members`,{method:`DELETE`,body:JSON.stringify({userIds:t})})}function Lee(e,t={}){let n=[[`limit`,String(t.limit??30)]];return t.cursorPosition!==void 0&&t.cursorPosition!==null&&n.push([`cursorPosition`,String(t.cursorPosition)]),us(`/messages/${e}/system-members?${Vo(n)}`)}function Ree(e,t){return us(`/conversations/${e}/members/${t}`,{method:`DELETE`})}function zee(e){return us(`/conversations/${e}/members/pending`)}function Bee(e,t){return us(`/conversations/${e}/members/approve`,{method:`POST`,body:JSON.stringify({userIds:t})})}function Vee(e,t){return us(`/conversations/${e}/members/reject`,{method:`POST`,body:JSON.stringify({userIds:t})})}function Hee(e,t){return us(`/conversations/${e}/leave`,{method:`PATCH`,body:JSON.stringify({nextOwnerId:t})})}function Uee(e){return us(`/messages/conversation/${e}/latest`)}function Wee(e,t){return us(`/messages/conversation/${e}/${t}`,{method:`DELETE`})}function Hs(e,t={}){let n=[],r=t.beforeSequence!==void 0&&t.beforeSequence!==null,i=t.afterSequence!==void 0&&t.afterSequence!==null;if(r===i)throw Error(`Message history requires exactly one cursor direction`);return r&&n.push([`beforeSequence`,String(t.beforeSequence)]),i&&n.push([`afterSequence`,String(t.afterSequence)]),n.push([`limit`,String(t.limit??20)]),us(`/messages/conversation/${e}?${Vo(n)}`)}function Gee(e,t){return us(`/messages/conversation/${e}/around/${t}`)}function Us(e,t={}){let n=[[`limit`,String(t.limit??30)]];return t.type&&n.push([`type`,t.type]),t.cursorUpdatedAt&&t.cursorUserId&&(n.push([`cursorUpdatedAt`,t.cursorUpdatedAt]),n.push([`cursorUserId`,t.cursorUserId])),us(`/messages/${e}/reactions?${Vo(n)}`)}function Kee(e){return us(`/messages/conversation/${e}/pinned`)}function qee(e,t={}){let n=String(t.q??``).trim();if(!n)throw Error(`Search keyword is required`);let r=[[`q`,n],[`messageLimit`,String(t.messageLimit??20)],[`documentLimit`,String(t.documentLimit??20)]];return t.messageBeforeSequence&&r.push([`messageBeforeSequence`,String(t.messageBeforeSequence)]),t.documentBeforeSequence&&r.push([`documentBeforeSequence`,String(t.documentBeforeSequence)]),t.senderId&&r.push([`senderId`,t.senderId]),t.fromDate&&r.push([`fromDate`,t.fromDate]),t.toDate&&r.push([`toDate`,t.toDate]),us(`/messages/conversation/${e}/search?${Vo(r)}`)}function Ws(e,t){let n=[[`type`,t.type]];return t.month&&n.push([`month`,t.month]),t.from&&n.push([`from`,t.from]),t.to&&n.push([`to`,t.to]),t.senderId&&n.push([`senderId`,t.senderId]),t.cursor&&n.push([`cursor`,t.cursor]),t.limit&&n.push([`limit`,String(t.limit)]),us(`/messages/conversation/${e}/archive?${Vo(n)}`)}async function Gs(e,t){if(t.type===`link`){let n=await Ws(e,t);return{items:Ko(n),pageInfo:Go(n)}}return t.limit?ts({fetchSourcePage:async n=>Yo(await Ws(e,{...t,cursor:n})),cursor:t.cursor,limit:t.limit,cacheScope:[e,t.type,t.senderId??``,t.from??``,t.to??``,t.month??``,t.limit].join(`|`)}):Yo(await Ws(e,t))}async function Jee(e){let t=e.onRefreshToken;if(!t)return e.getAccessToken()??``;if(is?.callback!==t){let n=Promise.resolve().then(t).catch(t=>{throw e.onUnauthorized?.(),t});is={callback:t,promise:n};let r=()=>{is?.promise===n&&(is=null)};n.then(r,r)}return is.promise}async function Ks(e,t,n,r,i){let a=rs,o=n!==void 0&&a.onRefreshToken&&Ro(n)?await Jee(a):a.getAccessToken(),s=new FormData;e&&s.append(`file`,e),s.append(`conversationId`,t),r&&s.append(`asDocument`,`true`),i&&(s.append(`kind`,i.kind),s.append(`latitude`,String(i.latitude)),s.append(`longitude`,String(i.longitude)));let c=await us(`/media/uploads`,{method:`POST`,body:s},a,o??void 0),l=c?.id;if(!l)throw Error(`Not found media-id response`);return{mediaId:l,attachmentUrl:c?.url??null,kind:c?.kind??null,mimeType:c?.mimeType??null,thumbnailUrl:c?.thumbnailUrl??null,durationMs:c?.durationMs??null,width:c?.width??null,height:c?.height??null,response:c}}async function Yee(e,t,n){let{mediaId:r,attachmentUrl:i}=await Ks(e,t,n);return ws(t,{avatarUrl:i??`/data/docs/${r}`})}function qs({from:e,to:t,userId:n,kind:r,search:i}){let a=[[`kind`,r]];return e&&a.push([`from`,e]),t&&a.push([`to`,t]),n&&a.push([`userId`,n]),i?.trim()&&a.push([`search`,i.trim()]),a}function Xee(e){let t=qs(e);return t.push([`page`,String(e.page)],[`pageSize`,String(e.pageSize)]),Vo(t)}function Zee(e){return us(`/stats/conversations/overview?${Vo(qs(e))}`)}function Qee(e){return us(`/stats/conversations/created-trend?${Vo(qs(e))}`)}function $ee(e){return us(`/stats/conversations/top-interactive?${Vo(qs(e))}`)}function ete(e){return us(`/stats/conversations?${Xee(e)}`)}function tte(e){let t=[[`page`,String(e.page)],[`pageSize`,String(e.pageSize)]];return e.userId&&t.push([`userId`,e.userId]),e.departmentId&&t.push([`departmentId`,e.departmentId]),e.branchId&&t.push([`branchId`,e.branchId]),us(`/stats/users/top-interactive?${Vo(t)}`)}function nte(e){return us(`/stats/users/group-breakdown?${Vo([[`userId`,e.userId],[`page`,String(e.page)],[`pageSize`,String(e.pageSize)]])}`)}function rte(e){let t=Vo([[`page`,String(e.page)],[`pageSize`,String(e.pageSize)]]);return us(`/stats/conversations/${e.conversationId}/members?${t}`)}var Js=``,Ys=null,Xs=``,Zs=new Set,Qs=!1,$s=!1;function ite(e){Js=e}function ec(e){let t=Ys;if(!t)return()=>void 0;let n=[],r=(e,r)=>{r&&(t.on(e,r),n.push({event:e,listener:r}))};if(r(`conversation:new`,e.onConversationNew),r(`conversation:deleted`,e.onConversationDeleted),r(`conversation:updated`,e.onConversationUpdated),r(`conversation:pinned`,e.onConversationPinned),r(`conversation:membership:changed`,e.onConversationMembershipChanged),e.onMessageSent&&(r(`message:sent`,e.onMessageSent),r(`message:ack`,e.onMessageSent)),e.onMessageNew&&(r(`message:new`,e.onMessageNew),r(`message:created`,e.onMessageNew)),r(`message:removed`,e.onMessageRemoved),r(`message:reaction:updated`,e.onMessageReactionUpdated),r(`message:pinned`,e.onMessagePinned),r(`conversation:read`,e.onConversationRead),r(`conversation:unread`,e.onConversationUnread),r(`presence:changed`,e.onPresenceChanged),r(`typing:start`,e.onTypingStart),r(`typing:stop`,e.onTypingStop),(e.onConnected||e.onConnectionRestored)&&r(`connect`,()=>{e.onConnected?.(),$s&&e.onConnectionRestored?.()}),r(`disconnect`,e.onConnectionLost),e.onConnectFailed){let t=t=>{e.onConnectFailed?.(t)};r(`connect_error`,t),r(`error`,t),r(`exception`,t)}return()=>{n.forEach(({event:e,listener:n})=>t.off(e,n))}}function tc(e){let t={handlers:e,detach:()=>void 0};return Zs.add(t),t.detach=ec(e),()=>{t.detach(),Zs.delete(t)}}function ate(){Zs.forEach(e=>{e.detach(),e.detach=ec(e.handlers)})}function ote(e,t){let n=Ys?.auth?.token;return Ys&&n===e&&Xs===Js?(t&&tc(t),Ys):(Ys&&oc(),Ys=Lo(Js,{transports:[`websocket`],upgrade:!1,auth:{token:e}}),Xs=Js,Ys.on(`connect`,()=>{$s=Qs,Qs=!0}),ate(),t&&tc(t),Ys)}function ste(){return Ys}function nc(e,t,n){return Ys?.connected?(n?Ys.emit(e,t,n):Ys.emit(e,t),{ok:!0,status:`EMITTED`}):{ok:!1,status:`DISCONNECTED`}}function cte(e,t){return nc(`conversation:create`,e,t)}var rc=new Map;function ic(e,t){if(t){let n=rc.get(e)??new Set;n.add(t),rc.set(e,n)}return nc(`conversation:subscribe`,{conversationId:e})}function lte(e,t){if(t){let n=rc.get(e);if(n?.delete(t),n&&n.size>0)return{ok:!0,status:`RETAINED`};rc.delete(e)}return nc(`conversation:unsubscribe`,{conversationId:e})}function ac(e,t){return nc(`message:send`,e,t)}function ute(e){return nc(`message:reaction:apply`,e)}function dte(e){return nc(`message:reaction:remove`,e)}function fte(e,t){return nc(`message:pin`,e,t)}function pte(e,t){return nc(`message:forward`,e,t)}function mte(e,t){return nc(`conversation:read`,e,t)}function hte(e){return nc(`typing:start`,e)}function gte(e){return nc(`typing:stop`,e)}function oc(){Ys&&=(Ys.removeAllListeners(),Ys.disconnect(),null),Xs=``,Qs=!1,$s=!1}var sc=260,cc=160;function lc({label:e,value:t,options:n,onChange:r,disabled:i}){let[a,o]=(0,d.useState)(!1),[s,c]=(0,d.useState)(``),[l,u]=(0,d.useState)(0),[f,m]=(0,d.useState)(null),h=(0,d.useRef)(null),g=(0,d.useRef)(null),_=(0,d.useRef)(null),v=(0,d.useRef)(!1);(0,d.useEffect)(()=>{_.current?.scrollIntoView({block:`nearest`})},[l]),(0,d.useEffect)(()=>{if(!a)return;let e=e=>{h.current?.contains(e.target)||o(!1)};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[a]);let y=n.find(e=>e.value===t),b=!y||y.value===n[0]?.value,x=()=>{let e=g.current?.getBoundingClientRect();if(!e)return;let t=window.innerHeight-e.bottom,n=e.top,r=t<sc&&n>t?Math.max(8,e.top-sc-6):e.bottom+6,i=Math.max(e.width,cc),a=Math.max(8,Math.min(e.left,window.innerWidth-i-8));m({top:r,left:a,width:e.width})};(0,d.useEffect)(()=>{if(!a)return;let e=()=>x();return window.addEventListener(`scroll`,e,!0),window.addEventListener(`resize`,e),()=>{window.removeEventListener(`scroll`,e,!0),window.removeEventListener(`resize`,e)}},[a]);let S=()=>{c(``);let e=n.findIndex(e=>e.value===t);u(Math.max(e,0))},C=()=>{if(!i){if(v.current){v.current=!1;return}o(e=>{let t=!e;return t&&(x(),S()),t})}},w=e=>{e.target===e.currentTarget&&(i||a||(v.current=!0,x(),S(),o(!0)))},T=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),!i&&o(e=>{let t=!e;return t&&(x(),S()),t}))},E=pa(s.trim()),D=E?n.filter(e=>pa(e.label).includes(E)):n,O=()=>{let e=D[l];e&&(r(e.value),o(!1))};return(0,p.jsxs)(`div`,{className:`filter-pill`,ref:h,children:[(0,p.jsxs)(`div`,{ref:g,className:`filter-pill-trigger${b?``:` is-active`}${i?` is-disabled`:``}`,role:`button`,tabIndex:i?-1:0,"aria-disabled":i||void 0,onClick:C,onFocus:w,onKeyDown:T,children:[(0,p.jsx)(`span`,{className:`filter-pill-trigger-label`,children:b?e:y?.label}),b?(0,p.jsx)(pt,{className:`filter-pill-trigger-chevron`}):(0,p.jsx)(`button`,{type:`button`,className:`filter-pill-trigger-clear`,"aria-label":`Bỏ lọc ${e}`,onClick:e=>{e.stopPropagation(),r(n[0].value)},children:(0,p.jsx)(Ke,{})})]}),a&&f?(0,p.jsxs)(`div`,{className:`filter-pill-menu`,role:`menu`,"aria-label":e,style:{top:f.top,left:f.left,minWidth:Math.max(f.width,cc)},children:[(0,p.jsx)(`input`,{className:`filter-pill-menu-search`,type:`text`,value:s,onChange:e=>{c(e.target.value),u(0)},onKeyDown:e=>{e.key===`ArrowDown`?(e.preventDefault(),u(e=>Math.min(e+1,D.length-1))):e.key===`ArrowUp`?(e.preventDefault(),u(e=>Math.max(e-1,0))):e.key===`Enter`?(e.preventDefault(),O()):e.key===`Escape`&&o(!1)},onClick:e=>e.stopPropagation(),placeholder:`Tìm...`,autoFocus:!0}),D.length===0?(0,p.jsx)(`p`,{className:`filter-pill-menu-empty`,children:`Không tìm thấy`}):D.map((e,n)=>(0,p.jsx)(`button`,{ref:n===l?_:void 0,type:`button`,role:`menuitem`,className:`${e.value===t?`is-active`:``}${n===l?` is-highlighted`:``}`,onMouseEnter:()=>u(n),onClick:()=>{r(e.value),o(!1)},children:e.label},e.value))]}):null]})}var uc=260,dc=6;function fc({label:e,value:t,options:n,onChange:r,disabled:i}){let[a,o]=(0,d.useState)(!1),[s,c]=(0,d.useState)(!1),[l,u]=(0,d.useState)(``),[f,m]=(0,d.useState)(0),[h,g]=(0,d.useState)(null),_=(0,d.useRef)(null),v=(0,d.useRef)(null),y=(0,d.useRef)(null),b=(0,d.useRef)(null),x=(0,d.useRef)(null),S=(0,d.useRef)(null),C=(0,d.useRef)(!1),[w,T]=(0,d.useState)(null);(0,d.useEffect)(()=>{S.current?.scrollIntoView({block:`nearest`})},[f]),(0,d.useEffect)(()=>{if(!a)return;let e=e=>{_.current?.contains(e.target)||o(!1)};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[a]);let E=t.length>0,D=n.filter(e=>t.includes(e.value)),O=D.map(e=>e.value).join(`|`);(0,d.useLayoutEffect)(()=>{if(s){T(null);return}let e=y.current,t=b.current;if(!e||!t||D.length===0){T(null);return}let n=()=>{let n=e.clientWidth,r=x.current?.offsetWidth??0,i=Array.from(t.children),a=0,o=i.length;for(let e=0;e<i.length;e+=1){let t=i[e].offsetWidth,s=a+(e>0?dc:0)+t;if(s+(i.length-(e+1)>0?dc+r:0)>n){o=e;break}a=s}T(o>=i.length?null:Math.max(o,1))};n();let r=new ResizeObserver(n);return r.observe(e),()=>r.disconnect()},[s,O]);let k=()=>{let e=v.current?.getBoundingClientRect();if(!e)return;let t=window.innerHeight-e.bottom,n=e.top,r=t<uc&&n>t?Math.max(8,e.top-uc-6):e.bottom+6;g({top:r,left:e.left})},A=()=>{u(``);let e=n.findIndex(e=>t.includes(e.value));m(Math.max(e,0))},j=()=>{if(!i){if(C.current){C.current=!1;return}o(e=>{let t=!e;return t&&(k(),A()),t})}},M=e=>{e.target===e.currentTarget&&(i||a||(C.current=!0,k(),A(),o(!0)))},N=e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),!i&&o(e=>{let t=!e;return t&&(k(),A()),t}))},P=pa(l.trim()),F=P?n.filter(e=>pa(e.label).includes(P)):n,I=e=>{r(t.includes(e)?t.filter(t=>t!==e):[...t,e])},L=e=>{if(e.key===`ArrowDown`)e.preventDefault(),m(e=>Math.min(e+1,F.length-1));else if(e.key===`ArrowUp`)e.preventDefault(),m(e=>Math.max(e-1,0));else if(e.key===`Enter`){e.preventDefault();let t=F[f];t&&I(t.value)}else e.key===`Escape`&&o(!1)},R=e=>{r(t.filter(t=>t!==e))},ee=s||w===null?D:D.slice(0,w),te=D.length-ee.length;return(0,p.jsxs)(`div`,{className:`multi-select-filter-pill-wrap`,ref:_,children:[(0,p.jsx)(`div`,{ref:v,className:`multi-select-filter-box${E?` is-active`:``}${i?` is-disabled`:``}`,role:`button`,tabIndex:i?-1:0,"aria-disabled":i||void 0,onClick:j,onFocus:M,onKeyDown:N,children:E?(0,p.jsxs)(`div`,{className:`multi-select-filter-tags`,ref:y,children:[(0,p.jsx)(`div`,{className:`multi-select-filter-tags-measure`,"aria-hidden":`true`,ref:b,children:D.map(e=>(0,p.jsxs)(`span`,{className:`multi-select-filter-tag`,children:[e.label,(0,p.jsx)(`button`,{type:`button`,tabIndex:-1,children:`×`})]},e.value))}),(0,p.jsxs)(`span`,{className:`multi-select-filter-tag-more`,"aria-hidden":`true`,ref:x,children:[`+`,D.length]}),ee.map(e=>(0,p.jsxs)(`span`,{className:`multi-select-filter-tag`,children:[e.label,(0,p.jsx)(`button`,{type:`button`,"aria-label":`Bỏ ${e.label}`,onClick:t=>{t.stopPropagation(),R(e.value)},children:`×`})]},e.value)),te>0?(0,p.jsxs)(`button`,{type:`button`,className:`multi-select-filter-tag-more`,onClick:e=>{e.stopPropagation(),c(!0)},children:[`+`,te]}):null]}):(0,p.jsxs)(`div`,{className:`multi-select-filter-box-header`,children:[(0,p.jsx)(`span`,{className:`filter-pill-trigger-label`,children:e}),(0,p.jsx)(pt,{className:`filter-pill-trigger-chevron`})]})}),a&&h?(0,p.jsxs)(`div`,{className:`filter-pill-menu`,role:`menu`,"aria-label":e,style:{top:h.top,left:h.left},children:[(0,p.jsx)(`input`,{className:`filter-pill-menu-search`,type:`text`,value:l,onChange:e=>{u(e.target.value),m(0)},onKeyDown:L,onClick:e=>e.stopPropagation(),placeholder:`Tìm...`,autoFocus:!0}),F.length===0?(0,p.jsx)(`p`,{className:`filter-pill-menu-empty`,children:`Không tìm thấy`}):F.map((e,n)=>{let r=t.includes(e.value);return(0,p.jsxs)(`button`,{ref:n===f?S:void 0,type:`button`,role:`menuitemcheckbox`,"aria-checked":r,className:`${r?`is-active`:``}${n===f?` is-highlighted`:``}`,onMouseEnter:()=>m(n),onClick:()=>I(e.value),children:[r?(0,p.jsx)(Le,{}):null,e.label]},e.value)})]}):null]})}var pc=`data:image/svg+xml,%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3c!--%20Uploaded%20to:%20SVG%20Repo,%20www.svgrepo.com,%20Transformed%20by:%20SVG%20Repo%20Mixer%20Tools%20--%3e%3csvg%20width='800px'%20height='800px'%20viewBox='0%200%201024%201024'%20class='icon'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20fill='%23000000'%3e%3cg%20id='SVGRepo_bgCarrier'%20stroke-width='0'/%3e%3cg%20id='SVGRepo_tracerCarrier'%20stroke-linecap='round'%20stroke-linejoin='round'/%3e%3cg%20id='SVGRepo_iconCarrier'%3e%3cpath%20d='M640%20874.666667l-85.333333%2085.333333h-85.333334l-85.333333-85.333333V448h256v170.666667l-42.666667%2042.666666%2042.666667%2042.666667v42.666667l-42.666667%2042.666666%2042.666667%2042.666667z'%20fill='%23FFA000'/%3e%3cpath%20d='M810.666667%20166.4c-10.666667-38.4-42.666667-66.133333-78.933334-76.8C680.533333%2078.933333%20601.6%2064%20512%2064s-168.533333%2014.933333-219.733333%2025.6C256%20100.266667%20224%20128%20213.333333%20166.4c-10.666667%2036.266667-21.333333%2087.466667-21.333333%20142.933333%200%2055.466667%2010.666667%20106.666667%2021.333333%20142.933334%2010.666667%2038.4%2040.533333%2066.133333%2078.933334%2074.666666%2051.2%2012.8%20130.133333%2027.733333%20219.733333%2027.733334s168.533333-14.933333%20219.733333-25.6c38.4-8.533333%2068.266667-38.4%2078.933334-74.666667s21.333333-87.466667%2021.333333-142.933333c0-57.6-10.666667-108.8-21.333333-145.066667zM618.666667%20277.333333H405.333333c-23.466667%200-42.666667-19.2-42.666666-42.666666V192c0-12.8%2066.133333-21.333333%20149.333333-21.333333s149.333333%208.533333%20149.333333%2021.333333v42.666667c0%2023.466667-19.2%2042.666667-42.666666%2042.666666z'%20fill='%23FFA000'/%3e%3cpath%20d='M490.666667%20554.666667h42.666666v405.333333h-42.666666z'%20fill='%23D68600'/%3e%3c/g%3e%3c/svg%3e`,mc=[];function hc(e){let t=(0,d.useRef)(Symbol(`overlay`));(0,d.useEffect)(()=>{let e=t.current;return mc.push(e),()=>{let t=mc.indexOf(e);t!==-1&&mc.splice(t,1)}},[]),(0,d.useEffect)(()=>{let n=n=>{n.key===`Escape`&&mc.at(-1)===t.current&&(n.stopPropagation(),e())};return document.addEventListener(`keydown`,n,!0),()=>document.removeEventListener(`keydown`,n,!0)},[e])}function gc(e){"@babel/helpers - typeof";return gc=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},gc(e)}function _te(e,t){if(gc(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(gc(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function vte(e){var t=_te(e,`string`);return gc(t)==`symbol`?t:t+``}function _c(e,t,n){return(t=vte(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var yte=class{requestAnimationFrame(e){return requestAnimationFrame(e)}cancelAnimationFrame(e){cancelAnimationFrame(e)}},bte=class{constructor(){_c(this,`_lastHandleId`,0),_c(this,`_lastImmediate`,null)}requestAnimationFrame(e){return this._lastHandleId>=2**53-1&&(this._lastHandleId=0),this._lastHandleId+=1,this._lastImmediate=setImmediate(()=>{e(performance.now())}),this._lastHandleId}cancelAnimationFrame(e){this._lastImmediate&&clearImmediate(this._lastImmediate)}},xte=class{constructor(){_c(this,`_strategy`,void 0),this._strategy=typeof requestAnimationFrame==`function`?new yte:new bte}requestAnimationFrame(e){return this._strategy.requestAnimationFrame(e)}cancelAnimationFrame(e){this._strategy.cancelAnimationFrame(e)}},vc=typeof window<`u`&&window.document!==void 0,yc=new Uint8Array([80,75,3,4]),Ste=[`v`,`ip`,`op`,`layers`,`fr`,`w`,`h`],H,bc=Array(128).fill(void 0);bc.push(void 0,null,!0,!1);function xc(e){return bc[e]}var Sc=bc.length;function Cc(e){Sc===bc.length&&bc.push(bc.length+1);let t=Sc;return Sc=bc[t],bc[t]=e,t}function wc(e,t){try{return e.apply(this,t)}catch(e){H.__wbindgen_export_0(Cc(e))}}var Tc=0,Ec=null;function Dc(){return(Ec===null||Ec.byteLength===0)&&(Ec=new Uint8Array(H.memory.buffer)),Ec}var Oc=typeof TextEncoder<`u`?new TextEncoder(`utf-8`):{encode:()=>{throw Error(`TextEncoder not available`)}},kc=typeof Oc.encodeInto==`function`?function(e,t){return Oc.encodeInto(e,t)}:function(e,t){let n=Oc.encode(e);return t.set(n),{read:e.length,written:n.length}};function Ac(e,t,n){if(n===void 0){let n=Oc.encode(e),r=t(n.length,1)>>>0;return Dc().subarray(r,r+n.length).set(n),Tc=n.length,r}let r=e.length,i=t(r,1)>>>0,a=Dc(),o=0;for(;o<r;o++){let t=e.charCodeAt(o);if(t>127)break;a[i+o]=t}if(o!==r){o!==0&&(e=e.slice(o)),i=n(i,r,r=o+e.length*3,1)>>>0;let t=Dc().subarray(i+o,i+r),a=kc(e,t);o+=a.written,i=n(i,r,o,1)>>>0}return Tc=o,i}var jc=null;function Mc(){return(jc===null||jc.buffer.detached===!0||jc.buffer.detached===void 0&&jc.buffer!==H.memory.buffer)&&(jc=new DataView(H.memory.buffer)),jc}var Nc=typeof TextDecoder<`u`?new TextDecoder(`utf-8`,{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error(`TextDecoder not available`)}};typeof TextDecoder<`u`&&Nc.decode();function Pc(e,t){return e>>>=0,Nc.decode(Dc().subarray(e,e+t))}function Fc(e){e<132||(bc[e]=Sc,Sc=e)}function Ic(e){let t=xc(e);return Fc(e),t}function Lc(e){return e==null}function Rc(e,t){let n=t(e.length*1,1)>>>0;return Dc().set(e,n/1),Tc=e.length,n}function zc(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Rc(t,H.__wbindgen_export_1),a=Tc;return H.register_font(n,r,i,a)!==0}var Bc=null;function Vc(){return(Bc===null||Bc.byteLength===0)&&(Bc=new Float32Array(H.memory.buffer)),Bc}function Hc(e,t){let n=t(e.length*4,4)>>>0;return Vc().set(e,n/4),Tc=e.length,n}function Uc(e,t){let n=t(e.length*4,4)>>>0,r=Mc();for(let t=0;t<e.length;t++)r.setUint32(n+4*t,Cc(e[t]),!0);return Tc=e.length,n}var Wc=Object.freeze({Forward:0,0:`Forward`,Reverse:1,1:`Reverse`,Bounce:2,2:`Bounce`,ReverseBounce:3,3:`ReverseBounce`}),Gc=Object.freeze({Idle:0,0:`Idle`,Playing:1,1:`Playing`,Paused:2,2:`Paused`,Stopped:3,3:`Stopped`,Tweening:4,4:`Tweening`}),Kc=typeof FinalizationRegistry>`u`?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry(e=>H.__wbg_dotlottieplayerwasm_free(e>>>0,1)),qc=class{__destroy_into_raw(){let e=this.__wbg_ptr;return this.__wbg_ptr=0,Kc.unregister(this),e}free(){let e=this.__destroy_into_raw();H.__wbg_dotlottieplayerwasm_free(e,0)}clear_slot(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_clear_slot(this.__wbg_ptr,t,n)!==0}layout_fit(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_layout_fit(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}loop_count(){return H.dotlottieplayerwasm_loop_count(this.__wbg_ptr)>>>0}poll_event(){return Ic(H.dotlottieplayerwasm_poll_event(this.__wbg_ptr))}reset_slot(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_reset_slot(this.__wbg_ptr,t,n)!==0}set_layout(e,t,n){let r=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),i=Tc;return H.dotlottieplayerwasm_set_layout(this.__wbg_ptr,r,i,t,n)!==0}set_marker(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;H.dotlottieplayerwasm_set_marker(this.__wbg_ptr,t,n)}clear_slots(){return H.dotlottieplayerwasm_clear_slots(this.__wbg_ptr)!==0}is_complete(){return H.dotlottieplayerwasm_is_complete(this.__wbg_ptr)!==0}reset_slots(){return H.dotlottieplayerwasm_reset_slots(this.__wbg_ptr)!==0}reset_theme(){return H.dotlottieplayerwasm_reset_theme(this.__wbg_ptr)!==0}segment_end(){return H.dotlottieplayerwasm_segment_end(this.__wbg_ptr)}set_quality(e){return H.dotlottieplayerwasm_set_quality(this.__wbg_ptr,e)!==0}set_segment(e,t){return H.dotlottieplayerwasm_set_segment(this.__wbg_ptr,e,t)!==0}sm_set_seed(e){return H.dotlottieplayerwasm_sm_set_seed(this.__wbg_ptr,e)!==0}static unload_font(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_unload_font(t,n)!==0}animation_id(){try{let n=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_animation_id(n,this.__wbg_ptr);var e=Mc().getInt32(n+0,!0),t=Mc().getInt32(n+4,!0);let r;return e!==0&&(r=Pc(e,t).slice(),H.__wbindgen_export_3(e,t*1,1)),r}finally{H.__wbindgen_add_to_stack_pointer(16)}}audio_volume(){return H.dotlottieplayerwasm_audio_volume(this.__wbg_ptr)}background_a(){return H.dotlottieplayerwasm_background_a(this.__wbg_ptr)}background_b(){return H.dotlottieplayerwasm_background_b(this.__wbg_ptr)}background_g(){return H.dotlottieplayerwasm_background_g(this.__wbg_ptr)}background_r(){return H.dotlottieplayerwasm_background_r(this.__wbg_ptr)}clear_marker(){H.dotlottieplayerwasm_clear_marker(this.__wbg_ptr)}emit_on_loop(){H.dotlottieplayerwasm_emit_on_loop(this.__wbg_ptr)}get_slot_ids(){return Ic(H.dotlottieplayerwasm_get_slot_ids(this.__wbg_ptr))}get_slot_str(e){try{let r=H.__wbindgen_add_to_stack_pointer(-16),i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;H.dotlottieplayerwasm_get_slot_str(r,this.__wbg_ptr,i,a);var t=Mc().getInt32(r+0,!0),n=Mc().getInt32(r+4,!0);let o;return t!==0&&(o=Pc(t,n).slice(),H.__wbindgen_export_3(t,n*1,1)),o}finally{H.__wbindgen_add_to_stack_pointer(16)}}marker_names(){return Ic(H.dotlottieplayerwasm_marker_names(this.__wbg_ptr))}set_autoplay(e){H.dotlottieplayerwasm_set_autoplay(this.__wbg_ptr,e)}set_slot_str(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Ac(t,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_set_slot_str(this.__wbg_ptr,n,r,i,a)!==0}set_viewport(e,t,n,r){return H.dotlottieplayerwasm_set_viewport(this.__wbg_ptr,e,t,n,r)!==0}total_frames(){return H.dotlottieplayerwasm_total_frames(this.__wbg_ptr)}clear_segment(){return H.dotlottieplayerwasm_clear_segment(this.__wbg_ptr)!==0}current_frame(){return H.dotlottieplayerwasm_current_frame(this.__wbg_ptr)}get_slot_type(e){try{let r=H.__wbindgen_add_to_stack_pointer(-16),i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;H.dotlottieplayerwasm_get_slot_type(r,this.__wbg_ptr,i,a);var t=Mc().getInt32(r+0,!0),n=Mc().getInt32(r+4,!0);let o;return t!==0&&(o=Pc(t,n).slice(),H.__wbindgen_export_3(t,n*1,1)),o}finally{H.__wbindgen_add_to_stack_pointer(16)}}get_slots_str(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_get_slots_str(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}get_transform(){return Ic(H.dotlottieplayerwasm_get_transform(this.__wbg_ptr))}segment_start(){return H.dotlottieplayerwasm_segment_start(this.__wbg_ptr)}set_slots_str(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_set_slots_str(this.__wbg_ptr,t,n)!==0}set_text_slot(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Ac(t,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_set_text_slot(this.__wbg_ptr,n,r,i,a)!==0}set_transform(e){let t=Hc(e,H.__wbindgen_export_1),n=Tc;return H.dotlottieplayerwasm_set_transform(this.__wbg_ptr,t,n)!==0}sm_get_inputs(){return Ic(H.dotlottieplayerwasm_sm_get_inputs(this.__wbg_ptr))}sm_poll_event(){return Ic(H.dotlottieplayerwasm_sm_poll_event(this.__wbg_ptr))}sm_post_click(e,t){H.dotlottieplayerwasm_sm_post_click(this.__wbg_ptr,e,t)}animation_size(){return Ic(H.dotlottieplayerwasm_animation_size(this.__wbg_ptr))}current_marker(){try{let n=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_current_marker(n,this.__wbg_ptr);var e=Mc().getInt32(n+0,!0),t=Mc().getInt32(n+4,!0);let r;return e!==0&&(r=Pc(e,t).slice(),H.__wbindgen_export_3(e,t*1,1)),r}finally{H.__wbindgen_add_to_stack_pointer(16)}}layout_align_x(){return H.dotlottieplayerwasm_layout_align_x(this.__wbg_ptr)}layout_align_y(){return H.dotlottieplayerwasm_layout_align_y(this.__wbg_ptr)}load_animation(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_load_animation(this.__wbg_ptr,t,n)!==0}loop_animation(){return H.dotlottieplayerwasm_loop_animation(this.__wbg_ptr)!==0}set_background(e,t,n,r){return H.dotlottieplayerwasm_set_background(this.__wbg_ptr,e,t,n,r)!==0}set_color_slot(e,t,n,r){let i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_set_color_slot(this.__wbg_ptr,i,a,t,n,r)!==0}set_image_slot(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Ac(t,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_set_image_slot(this.__wbg_ptr,n,r,i,a)!==0}set_loop_count(e){H.dotlottieplayerwasm_set_loop_count(this.__wbg_ptr,e)}set_theme_data(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_set_theme_data(this.__wbg_ptr,t,n)!==0}sm_reset_input(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;H.dotlottieplayerwasm_sm_reset_input(this.__wbg_ptr,t,n)}manifest_string(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_manifest_string(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}set_scalar_slot(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;return H.dotlottieplayerwasm_set_scalar_slot(this.__wbg_ptr,n,r,t)!==0}set_vector_slot(e,t,n){let r=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),i=Tc;return H.dotlottieplayerwasm_set_vector_slot(this.__wbg_ptr,r,i,t,n)!==0}setup_sw_target(e,t){return H.dotlottieplayerwasm_setup_sw_target(this.__wbg_ptr,e,t)!==0}get_pixel_buffer(){return Ic(H.dotlottieplayerwasm_get_pixel_buffer(this.__wbg_ptr))}set_audio_volume(e){H.dotlottieplayerwasm_set_audio_volume(this.__wbg_ptr,e)}sm_current_state(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_sm_current_state(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}state_machine_id(){try{let n=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_state_machine_id(n,this.__wbg_ptr);var e=Mc().getInt32(n+0,!0),t=Mc().getInt32(n+4,!0);let r;return e!==0&&(r=Pc(e,t).slice(),H.__wbindgen_export_3(e,t*1,1)),r}finally{H.__wbindgen_add_to_stack_pointer(16)}}get_state_machine(e){try{let r=H.__wbindgen_add_to_stack_pointer(-16),i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;H.dotlottieplayerwasm_get_state_machine(r,this.__wbg_ptr,i,a);var t=Mc().getInt32(r+0,!0),n=Mc().getInt32(r+4,!0);let o;return t!==0&&(o=Pc(t,n).slice(),H.__wbindgen_export_3(t,n*1,1)),o}finally{H.__wbindgen_add_to_stack_pointer(16)}}set_position_slot(e,t,n){let r=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),i=Tc;return H.dotlottieplayerwasm_set_position_slot(this.__wbg_ptr,r,i,t,n)!==0}current_loop_count(){return H.dotlottieplayerwasm_current_loop_count(this.__wbg_ptr)>>>0}set_asset_resolver(e){H.dotlottieplayerwasm_set_asset_resolver(this.__wbg_ptr,Lc(e)?0:Cc(e))}sm_framework_setup(){return Ic(H.dotlottieplayerwasm_sm_framework_setup(this.__wbg_ptr))}sm_post_pointer_up(e,t){H.dotlottieplayerwasm_sm_post_pointer_up(this.__wbg_ptr,e,t)}state_machine_load(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_state_machine_load(this.__wbg_ptr,t,n)!==0}load_dotlottie_data(e){let t=Rc(e,H.__wbindgen_export_1),n=Tc;return H.dotlottieplayerwasm_load_dotlottie_data(this.__wbg_ptr,t,n)!==0}sm_get_string_input(e){try{let r=H.__wbindgen_add_to_stack_pointer(-16),i=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;H.dotlottieplayerwasm_sm_get_string_input(r,this.__wbg_ptr,i,a);var t=Mc().getInt32(r+0,!0),n=Mc().getInt32(r+4,!0);let o;return t!==0&&(o=Pc(t,n).slice(),H.__wbindgen_export_3(t,n*1,1)),o}finally{H.__wbindgen_add_to_stack_pointer(16)}}sm_set_string_input(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Ac(t,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;return H.dotlottieplayerwasm_sm_set_string_input(this.__wbg_ptr,n,r,i,a)!==0}sm_get_boolean_input(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc,r=H.dotlottieplayerwasm_sm_get_boolean_input(this.__wbg_ptr,t,n);return r===16777215?void 0:r!==0}sm_get_numeric_input(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc,r=H.dotlottieplayerwasm_sm_get_numeric_input(this.__wbg_ptr,t,n);return r===4294967297?void 0:r}sm_post_pointer_down(e,t){H.dotlottieplayerwasm_sm_post_pointer_down(this.__wbg_ptr,e,t)}sm_post_pointer_exit(e,t){H.dotlottieplayerwasm_sm_post_pointer_exit(this.__wbg_ptr,e,t)}sm_post_pointer_move(e,t){H.dotlottieplayerwasm_sm_post_pointer_move(this.__wbg_ptr,e,t)}sm_set_boolean_input(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;return H.dotlottieplayerwasm_sm_set_boolean_input(this.__wbg_ptr,n,r,t)!==0}sm_set_numeric_input(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;return H.dotlottieplayerwasm_sm_set_numeric_input(this.__wbg_ptr,n,r,t)!==0}state_machine_unload(){H.dotlottieplayerwasm_state_machine_unload(this.__wbg_ptr)}sm_post_pointer_enter(e,t){H.dotlottieplayerwasm_sm_post_pointer_enter(this.__wbg_ptr,e,t)}load_animation_from_id(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_load_animation_from_id(this.__wbg_ptr,t,n)!==0}sm_poll_internal_event(){return Ic(H.dotlottieplayerwasm_sm_poll_internal_event(this.__wbg_ptr))}use_frame_interpolation(){return H.dotlottieplayerwasm_use_frame_interpolation(this.__wbg_ptr)!==0}reset_current_loop_count(){H.dotlottieplayerwasm_reset_current_loop_count(this.__wbg_ptr)}sm_override_current_state(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;return H.dotlottieplayerwasm_sm_override_current_state(this.__wbg_ptr,n,r,t)!==0}state_machine_load_from_id(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_state_machine_load_from_id(this.__wbg_ptr,t,n)!==0}set_use_frame_interpolation(e){H.dotlottieplayerwasm_set_use_frame_interpolation(this.__wbg_ptr,e)}constructor(){let e=H.dotlottieplayerwasm_new();return this.__wbg_ptr=e>>>0,Kc.register(this,this.__wbg_ptr,this),this}mode(){return H.dotlottieplayerwasm_mode(this.__wbg_ptr)}play(){return H.dotlottieplayerwasm_play(this.__wbg_ptr)!==0}stop(){return H.dotlottieplayerwasm_stop(this.__wbg_ptr)!==0}tick(e){return H.dotlottieplayerwasm_tick(this.__wbg_ptr,e)!==0}pause(){return H.dotlottieplayerwasm_pause(this.__wbg_ptr)!==0}speed(){return H.dotlottieplayerwasm_speed(this.__wbg_ptr)}width(){return H.dotlottieplayerwasm_width(this.__wbg_ptr)>>>0}height(){return H.dotlottieplayerwasm_height(this.__wbg_ptr)>>>0}render(){return H.dotlottieplayerwasm_render(this.__wbg_ptr)!==0}status(){return H.dotlottieplayerwasm_status(this.__wbg_ptr)}markers(){return Ic(H.dotlottieplayerwasm_markers(this.__wbg_ptr))}sm_fire(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_sm_fire(this.__wbg_ptr,t,n)!==0}sm_stop(){return H.dotlottieplayerwasm_sm_stop(this.__wbg_ptr)!==0}sm_tick(e){return H.dotlottieplayerwasm_sm_tick(this.__wbg_ptr,e)!==0}autoplay(){return H.dotlottieplayerwasm_autoplay(this.__wbg_ptr)!==0}duration(){return H.dotlottieplayerwasm_duration(this.__wbg_ptr)}set_loop(e){H.dotlottieplayerwasm_set_loop(this.__wbg_ptr,e)}set_mode(e){H.dotlottieplayerwasm_set_mode(this.__wbg_ptr,e)}sm_start(e,t){let n=Uc(t,H.__wbindgen_export_1),r=Tc;return H.dotlottieplayerwasm_sm_start(this.__wbg_ptr,e,n,r)!==0}theme_id(){try{let n=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_theme_id(n,this.__wbg_ptr);var e=Mc().getInt32(n+0,!0),t=Mc().getInt32(n+4,!0);let r;return e!==0&&(r=Pc(e,t).slice(),H.__wbindgen_export_3(e,t*1,1)),r}finally{H.__wbindgen_add_to_stack_pointer(16)}}load_font(e,t){let n=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc,i=Rc(t,H.__wbindgen_export_1),a=Tc;return H.dotlottieplayerwasm_load_font(this.__wbg_ptr,n,r,i,a)!==0}set_frame(e){return H.dotlottieplayerwasm_set_frame(this.__wbg_ptr,e)!==0}set_speed(e){H.dotlottieplayerwasm_set_speed(this.__wbg_ptr,e)}set_theme(e){let t=Ac(e,H.__wbindgen_export_1,H.__wbindgen_export_2),n=Tc;return H.dotlottieplayerwasm_set_theme(this.__wbg_ptr,t,n)!==0}sm_status(){let e,t;try{let i=H.__wbindgen_add_to_stack_pointer(-16);H.dotlottieplayerwasm_sm_status(i,this.__wbg_ptr);var n=Mc().getInt32(i+0,!0),r=Mc().getInt32(i+4,!0);return e=n,t=r,Pc(n,r)}finally{H.__wbindgen_add_to_stack_pointer(16),H.__wbindgen_export_3(e,t,1)}}};async function Jc(e,t){if(typeof Response==`function`&&e instanceof Response){if(typeof WebAssembly.instantiateStreaming==`function`)try{return await WebAssembly.instantiateStreaming(e,t)}catch(t){if(e.headers.get(`Content-Type`)!=`application/wasm`)console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t);else throw t}let n=await e.arrayBuffer();return await WebAssembly.instantiate(n,t)}{let n=await WebAssembly.instantiate(e,t);return n instanceof WebAssembly.Instance?{instance:n,module:e}:n}}function Yc(){let e={};return e.wbg={},e.wbg.__wbg_buffer_609cc3eee51ed158=function(e){let t=xc(e).buffer;return Cc(t)},e.wbg.__wbg_call_7cccdd69e0791ae2=function(){return wc(function(e,t,n){return Cc(xc(e).call(xc(t),xc(n)))},arguments)},e.wbg.__wbg_createObjectURL_6e98d2f9c7bd9764=function(){return wc(function(e,t){let n=Ac(URL.createObjectURL(xc(t)),H.__wbindgen_export_1,H.__wbindgen_export_2),r=Tc;Mc().setInt32(e+4,r,!0),Mc().setInt32(e+0,n,!0)},arguments)},e.wbg.__wbg_ended_b873fb75d0c13ca7=function(e){return xc(e).ended},e.wbg.__wbg_error_7534b8e9a36f1ab4=function(e,t){let n,r;try{n=e,r=t,console.error(Pc(e,t))}finally{H.__wbindgen_export_3(n,r,1)}},e.wbg.__wbg_length_a446193dc22c12f8=function(e){return xc(e).length},e.wbg.__wbg_new_405e22f390576ce2=function(){return Cc({})},e.wbg.__wbg_new_78feb108b6472713=function(){return Cc([])},e.wbg.__wbg_new_8a6f238a6ece86ea=function(){return Cc(Error())},e.wbg.__wbg_new_a12002a7f91c75be=function(e){return Cc(new Uint8Array(xc(e)))},e.wbg.__wbg_newwithbyteoffsetandlength_d97e637ebe145a9a=function(e,t,n){return Cc(new Uint8Array(xc(e),t>>>0,n>>>0))},e.wbg.__wbg_newwithlength_5a5efe313cfd59f1=function(e){return Cc(new Float32Array(e>>>0))},e.wbg.__wbg_newwithsrc_20307ca7e8762a81=function(){return wc(function(e,t){return Cc(new Audio(Pc(e,t)))},arguments)},e.wbg.__wbg_newwithu8arraysequenceandoptions_068570c487f69127=function(){return wc(function(e,t){return Cc(new Blob(xc(e),xc(t)))},arguments)},e.wbg.__wbg_pause_b74c96d69f769518=function(){return wc(function(e){xc(e).pause()},arguments)},e.wbg.__wbg_play_f6ec5fc4e84b0d26=function(){return wc(function(e){return Cc(xc(e).play())},arguments)},e.wbg.__wbg_push_737cfc8c1432c2c6=function(e,t){return xc(e).push(xc(t))},e.wbg.__wbg_revokeObjectURL_27267efebeb457c7=function(){return wc(function(e,t){URL.revokeObjectURL(Pc(e,t))},arguments)},e.wbg.__wbg_set_65595bdd868b3009=function(e,t,n){xc(e).set(xc(t),n>>>0)},e.wbg.__wbg_set_bb8cecf6a62b9f46=function(){return wc(function(e,t,n){return Reflect.set(xc(e),xc(t),xc(n))},arguments)},e.wbg.__wbg_setcurrentTime_64727eddd3966512=function(e,t){xc(e).currentTime=t},e.wbg.__wbg_setindex_4e73afdcd9bb95cd=function(e,t,n){xc(e)[t>>>0]=n},e.wbg.__wbg_settype_39ed370d3edd403c=function(e,t,n){xc(e).type=Pc(t,n)},e.wbg.__wbg_setvolume_3895e06a030ca4f7=function(e,t){xc(e).volume=t},e.wbg.__wbg_stack_0ed75d68575b0f3c=function(e,t){let n=xc(t).stack,r=Ac(n,H.__wbindgen_export_1,H.__wbindgen_export_2),i=Tc;Mc().setInt32(e+4,i,!0),Mc().setInt32(e+0,r,!0)},e.wbg.__wbindgen_is_null=function(e){return xc(e)===null},e.wbg.__wbindgen_is_undefined=function(e){return xc(e)===void 0},e.wbg.__wbindgen_memory=function(){let e=H.memory;return Cc(e)},e.wbg.__wbindgen_number_new=function(e){return Cc(e)},e.wbg.__wbindgen_object_drop_ref=function(e){Ic(e)},e.wbg.__wbindgen_string_get=function(e,t){let n=xc(t),r=typeof n==`string`?n:void 0;var i=Lc(r)?0:Ac(r,H.__wbindgen_export_1,H.__wbindgen_export_2),a=Tc;Mc().setInt32(e+4,a,!0),Mc().setInt32(e+0,i,!0)},e.wbg.__wbindgen_string_new=function(e,t){return Cc(Pc(e,t))},e.wbg.__wbindgen_throw=function(e,t){throw Error(Pc(e,t))},e}function Xc(e,t){return H=e.exports,Zc.__wbindgen_wasm_module=t,jc=null,Bc=null,Ec=null,H}async function Zc(e){if(H!==void 0)return H;if(e!==void 0&&(Object.getPrototypeOf(e)===Object.prototype?{module_or_path:e}=e:console.warn(`using deprecated parameters for the initialization function; pass a single object instead`)),e===void 0)throw Error(`WASM module URL must be provided via DotLottieWasmLoader or setWasmUrl().`);let t=Yc();(typeof e==`string`||typeof Request==`function`&&e instanceof Request||typeof URL==`function`&&e instanceof URL)&&(e=fetch(e));let{instance:n,module:r}=await Jc(await e,t);return Xc(n,r)}var Qc=class{constructor(){_c(this,`_eventListeners`,new Map)}addEventListener(e,t){let n=this._eventListeners.get(e);n||(n=new Set,this._eventListeners.set(e,n)),n.add(t)}removeEventListener(e,t){let n=this._eventListeners.get(e);n&&(t?(n.delete(t),n.size===0&&this._eventListeners.delete(e)):this._eventListeners.delete(e))}dispatch(e){this._eventListeners.get(e.type)?.forEach(t=>t(e))}removeAllEventListeners(){this._eventListeners.clear()}},$c=class e{static _initializeObserver(){e._observer||=new IntersectionObserver(t=>{t.forEach(t=>{let n=e._observedCanvases.get(t.target);n&&(t.isIntersecting?n.unfreeze():n.freeze())})},{threshold:0})}static observe(t,n){e._initializeObserver(),!e._observedCanvases.has(t)&&(e._observedCanvases.set(t,n),e._observer?.observe(t))}static unobserve(t){e._observer?.unobserve(t),e._observedCanvases.delete(t),e._observedCanvases.size===0&&(e._observer?.disconnect(),e._observer=null)}};_c($c,`_observer`,null),_c($c,`_observedCanvases`,new Map);var el=class e{static _initializeObserver(){e._observer||=new ResizeObserver(t=>{t.forEach(t=>{let n=e._observedCanvases.get(t.target);if(!n)return;let[r,i]=n;clearTimeout(i);let a=setTimeout(()=>{r.resize()},100);e._observedCanvases.set(t.target,[r,a])})})}static observe(t,n){e._initializeObserver(),!e._observedCanvases.has(t)&&(e._observedCanvases.set(t,[n,0]),e._observer?.observe(t))}static unobserve(t){let n=e._observedCanvases.get(t);if(n){let e=n[1];e&&clearTimeout(e)}e._observer?.unobserve(t),e._observedCanvases.delete(t),!e._observedCanvases.size&&e._observer&&(e._observer.disconnect(),e._observer=null)}};_c(el,`_observer`,null),_c(el,`_observedCanvases`,new Map);function tl(e){return/^#([\da-f]{6}|[\da-f]{8})$/iu.test(e)}function nl(e){if(!tl(e))return[0,0,0,0];let t=e.replace(`#`,``);return t=t.length===6?`${t}ff`:t,[parseInt(t.slice(0,2),16)/255,parseInt(t.slice(2,4),16)/255,parseInt(t.slice(4,6),16)/255,parseInt(t.slice(6,8),16)/255]}function rl(e){if(e.byteLength<4)return!1;let t=new Uint8Array(e.slice(0,yc.byteLength));for(let e=0;e<yc.length;e+=1)if(yc[e]!==t[e])return!1;return!0}function il(e){return Ste.every(t=>Object.hasOwn(e,t))}function al(e){return typeof e==`string`?/^\s*\{/u.test(e)&&/\}\s*$/u.test(e):il(e)}function ol(){return 1+((vc?window.devicePixelRatio:1)-1)*.75}function sl(e){let t=e.getBoundingClientRect(),n=window.innerHeight||document.documentElement.clientHeight,r=window.innerWidth||document.documentElement.clientWidth;return!(t.bottom<0||t.top>n||t.right<0||t.left>r)}function cl(e){let t=e.target;if(t instanceof HTMLCanvasElement){let n=t.getBoundingClientRect();if(n.width===0||n.height===0||t.width===0||t.height===0)return null;let r=t.width/n.width,i=t.height/n.height,a=(e.clientX-n.left)*r,o=(e.clientY-n.top)*i;return!Number.isFinite(a)||!Number.isFinite(o)||Number.isNaN(a)||Number.isNaN(o)?null:{x:a,y:o}}return null}function ll(e){return new Promise((t,n)=>{let r=new FileReader;r.onerror=()=>n(r.error??Error(`Failed to read image slot source`)),r.onload=()=>t(r.result),r.readAsDataURL(e)})}async function ul(e){if(!/^https?:\/\//i.test(e))return e;let t=await fetch(e);if(!t.ok)throw Error(`Failed to fetch image slot source from URL: ${e}. ${t.status}: ${t.statusText}`);return ll(await t.blob())}function dl(e){let t=e.replace(`OpenUrl: `,``),n=t.indexOf(` | Target: `),r,i;n===-1?(r=t,i=`_blank`):(r=t.substring(0,n),i=t.substring(n+11)),window.open(r,i)}function fl(e,t,n){let r=null,i=t;async function a(t){await e({module_or_path:t})}async function o(t){let n=await fetch(t);if(!n.ok)throw Error(`fetch ${t} responded with ${n.status} ${n.statusText}`);await e({module_or_path:await n.arrayBuffer()})}return{load(){if(!r){let e=i,t=n;r=(async()=>{let n,i;try{await a(e);return}catch(r){n=r,console.warn(`Primary WASM load failed from ${e}: ${r.message}`),console.warn(`Attempting to load WASM from backup URL: ${t}`)}try{await a(t);return}catch(e){i=e,console.warn(`Backup WASM load failed from ${t}: ${e.message}`)}console.warn(`Retrying WASM load with buffered instantiation`);try{await o(e);return}catch(t){console.warn(`Buffered WASM load from ${e} failed: ${t.message}`)}try{await o(t);return}catch(e){throw console.error(`Primary WASM URL failed: ${n.message}`),console.error(`Backup WASM URL failed: ${i.message}`),console.error(`Buffered fallback failed: ${e.message}`),r=null,Error(`WASM loading failed from all sources.`)}})()}return r},setWasmUrl(e){e!==i&&(i=e,r=null)}}}var pl=null;function ml(){return pl??=fl(Zc,`https://cdn.jsdelivr.net/npm/@lottiefiles/dotlottie-web@0.79.1/dist/dotlottie-player.wasm`,`https://unpkg.com/@lottiefiles/dotlottie-web@0.79.1/dist/dotlottie-player.wasm`),pl}var hl=e=>{switch(e){case`reverse`:return Wc.Reverse;case`bounce`:return Wc.Bounce;case`reverse-bounce`:return Wc.ReverseBounce;default:return Wc.Forward}},gl=e=>{switch(e){case Wc.Reverse:return`reverse`;case Wc.Bounce:return`bounce`;case Wc.ReverseBounce:return`reverse-bounce`;default:return`forward`}},_l=e=>{switch(e){case`contain`:return`contain`;case`cover`:return`cover`;case`fill`:return`fill`;case`fit-height`:return`fit-height`;case`fit-width`:return`fit-width`;case`none`:return`none`;default:return`contain`}},vl=class{constructor(e){_c(this,`_canvas`,null),_c(this,`_pendingLoad`,null),_c(this,`_srcFetchAbort`,null),_c(this,`_context`,null),_c(this,`_eventManager`,void 0),_c(this,`_animationFrameId`,null),_c(this,`_frameManager`,void 0),_c(this,`_boundAnimationLoop`,void 0),_c(this,`_dotLottieCore`,null),_c(this,`_stateMachineId`,``),_c(this,`_stateMachineConfig`,null),_c(this,`_isStateMachineRunning`,!1),_c(this,`_renderConfig`,{}),_c(this,`_isFrozen`,!1),_c(this,`_backgroundColor`,null),_c(this,`_lastFrameTime`,null),_c(this,`_boundOnClick`,null),_c(this,`_boundOnPointerUp`,null),_c(this,`_boundOnPointerDown`,null),_c(this,`_boundOnPointerMove`,null),_c(this,`_boundOnPointerEnter`,null),_c(this,`_boundOnPointerLeave`,null),_c(this,`_bufferMismatchCount`,0),_c(this,`_lastExpectedBufferSize`,0),_c(this,`_cachedImageData`,null),_c(this,`_cachedImageDataBuffer`,null),_c(this,`_cachedImageDataByteOffset`,0),_c(this,`_marker`,``),_c(this,`_segment`,null),this._canvas=e.canvas??null,this._eventManager=new Qc,this._frameManager=new xte,this._boundAnimationLoop=this._animationLoop.bind(this),this._renderConfig={...e.renderConfig,devicePixelRatio:e.renderConfig?.devicePixelRatio||ol(),freezeOnOffscreen:e.renderConfig?.freezeOnOffscreen??!0};let t=null;e.src&&!e.data&&(this._srcFetchAbort=new AbortController,t=this._fetchData(e.src,this._srcFetchAbort.signal),t.catch(()=>{})),this._initWasm().then(()=>{this._dotLottieCore=this._createCore(),this._dotLottieCore.set_autoplay(e.autoplay??!1),this._dotLottieCore.set_loop(e.loop??!1),this._dotLottieCore.set_loop_count(e.loopCount??0),this._dotLottieCore.set_mode(hl(e.mode??`forward`)),this._dotLottieCore.set_speed(e.speed??1),this._dotLottieCore.set_use_frame_interpolation(e.useFrameInterpolation??!0),e.segment&&e.segment.length===2&&(this._segment=[e.segment[0],e.segment[1]],this._dotLottieCore.set_segment(this._segment[0],this._segment[1])),this._marker=e.marker??``,this._marker&&this._dotLottieCore.set_marker(this._marker),this._dotLottieCore.set_layout(e.layout?.fit??`contain`,e.layout?.align?.[0]??.5,e.layout?.align?.[1]??.5),this._applyAssetResolver(e.assetResolver??null),this._stateMachineId=e.stateMachineId??``,this._stateMachineConfig=e.stateMachineConfig??null,this._onCoreCreated(),this._eventManager.dispatch({type:`ready`}),e.data?this._canvas?this._loadFromData(e.data):this._pendingLoad={data:e.data}:e.src&&(this._canvas?this._loadFromSrc(e.src,t):this._pendingLoad={src:e.src,dataPromise:t}),e.backgroundColor&&this.setBackgroundColor(e.backgroundColor)}).catch(e=>{this._srcFetchAbort?.abort(),console.error(`[dotlottie-web] Initialization failed:`,e),this._eventManager.dispatch({type:`loadError`,error:Error(`Failed to load wasm module: ${e}`)})})}async _initWasm(){return ml().load()}_createCore(){return new qc}_onCoreCreated(){}_setupTarget(e,t){return this._dotLottieCore?this._dotLottieCore.setup_sw_target(e,t):!1}_drainPlayerEvents({skipFrame:e=!1}={}){if(this._dotLottieCore)for(;;){let t=this._dotLottieCore.poll_event();if(t==null)break;switch(t.type){case`Load`:setTimeout(()=>this._eventManager.dispatch({type:`load`}),0);break;case`LoadError`:setTimeout(()=>this._eventManager.dispatch({type:`loadError`,error:Error(`failed to load`)}),0);break;case`Play`:queueMicrotask(()=>this._eventManager.dispatch({type:`play`}));break;case`Pause`:queueMicrotask(()=>this._eventManager.dispatch({type:`pause`}));break;case`Stop`:queueMicrotask(()=>this._eventManager.dispatch({type:`stop`}));break;case`Frame`:{let n=t.frameNo??0;e||queueMicrotask(()=>this._eventManager.dispatch({type:`frame`,currentFrame:n}));break}case`Render`:{let n=t.frameNo??0;e||queueMicrotask(()=>this._eventManager.dispatch({type:`render`,currentFrame:n}));break}case`Loop`:{let e=t.loopCount??0;queueMicrotask(()=>this._eventManager.dispatch({type:`loop`,loopCount:e}));break}case`Complete`:queueMicrotask(()=>this._eventManager.dispatch({type:`complete`}))}}}_discardPlayerEvents(){for(;this._dotLottieCore?.poll_event()!=null;);}_drainSmEvents(){if(this._dotLottieCore){for(;;){let e=this._dotLottieCore.sm_poll_event();if(e==null)break;switch(e.type){case`Start`:queueMicrotask(()=>{this._isStateMachineRunning=!0,this._eventManager.dispatch({type:`stateMachineStart`}),this._startAnimationLoop()});break;case`Stop`:queueMicrotask(()=>{this._isStateMachineRunning=!1,this._eventManager.dispatch({type:`stateMachineStop`}),this._dotLottieCore?.status()!==Gc.Playing&&this._stopAnimationLoop()});break;case`CustomEvent`:this._eventManager.dispatch({type:`stateMachineCustomEvent`,eventName:e.message??``});break;case`BooleanInputChange`:this._eventManager.dispatch({type:`stateMachineBooleanInputValueChange`,inputName:e.name??``,newValue:e.newValue,oldValue:e.oldValue});break;case`NumericInputChange`:this._eventManager.dispatch({type:`stateMachineNumericInputValueChange`,inputName:e.name??``,newValue:e.newValue,oldValue:e.oldValue});break;case`StringInputChange`:this._eventManager.dispatch({type:`stateMachineStringInputValueChange`,inputName:e.name??``,newValue:e.newValue,oldValue:e.oldValue});break;case`InputFired`:this._eventManager.dispatch({type:`stateMachineInputFired`,inputName:e.name??``});break;case`Transition`:this._eventManager.dispatch({type:`stateMachineTransition`,fromState:e.previousState??``,toState:e.newState??``});break;case`StateEntered`:this._eventManager.dispatch({type:`stateMachineStateEntered`,state:e.state??``});break;case`StateExit`:this._eventManager.dispatch({type:`stateMachineStateExit`,state:e.state??``});break;case`Error`:this._eventManager.dispatch({type:`stateMachineError`,error:e.message??``})}}for(;;){let e=this._dotLottieCore.sm_poll_internal_event();if(e==null)break;if(e.type===`Message`){let t=e.message??``;vc&&t.startsWith(`OpenUrl: `)?dl(t):this._eventManager.dispatch({type:`stateMachineInternalMessage`,message:t})}}}}_dispatchError(e){console.error(e),this._eventManager.dispatch({type:`loadError`,error:Error(e)})}async _fetchData(e,t=null){let n=await fetch(e,{signal:t});if(!n.ok)throw Error(`Failed to fetch animation data from URL: ${e}. ${n.status}: ${n.statusText}`);let r=await n.arrayBuffer();return rl(r)?r:new TextDecoder().decode(r)}_loadFromData(e){if(this._dotLottieCore===null)return;if(!this._canvas){console.warn(`[dotlottie-web] Cannot load animation without canvas. Call setCanvas() first.`);return}this._syncCanvasSize(),this._setupTarget(this._canvas.width,this._canvas.height);let t=!1;if(typeof e==`string`){if(t=this._dotLottieCore.load_animation(e),!t&&!al(e)){this._discardPlayerEvents(),this._dispatchError(`Invalid Lottie JSON string: The provided string does not conform to the Lottie JSON format.`);return}}else if(e instanceof ArrayBuffer){if(!rl(e)){this._dispatchError(`Invalid dotLottie ArrayBuffer: The provided ArrayBuffer does not conform to the dotLottie format.`);return}t=this._dotLottieCore.load_dotlottie_data(new Uint8Array(e))}else if(typeof e==`object`){if(!al(e)){this._dispatchError(`Invalid Lottie JSON object: The provided object does not conform to the Lottie JSON format.`);return}t=this._dotLottieCore.load_animation(JSON.stringify(e))}else{this._dispatchError(`Unsupported data type for animation data. Expected:
59
59
  - string (Lottie JSON),
60
60
  - ArrayBuffer (dotLottie),
61
61
  - object (Lottie JSON).
package/dist/index.js CHANGED
@@ -4854,24 +4854,24 @@ async function tte(e) {
4854
4854
  }
4855
4855
  return $s.promise;
4856
4856
  }
4857
- async function Sc(e, t, n, r) {
4858
- let i = Qs, a = n !== void 0 && i.onRefreshToken && Ns(n) ? await tte(i) : i.getAccessToken(), o = new FormData();
4859
- o.append("file", e), o.append("conversationId", t), r && o.append("asDocument", "true");
4860
- let s = await ic("/media/uploads", {
4857
+ async function Sc(e, t, n, r, i) {
4858
+ let a = Qs, o = n !== void 0 && a.onRefreshToken && Ns(n) ? await tte(a) : a.getAccessToken(), s = new FormData();
4859
+ e && s.append("file", e), s.append("conversationId", t), r && s.append("asDocument", "true"), i && (s.append("kind", i.kind), s.append("latitude", String(i.latitude)), s.append("longitude", String(i.longitude)));
4860
+ let c = await ic("/media/uploads", {
4861
4861
  method: "POST",
4862
- body: o
4863
- }, i, a ?? void 0), c = s?.id;
4864
- if (!c) throw Error("Not found media-id response");
4862
+ body: s
4863
+ }, a, o ?? void 0), l = c?.id;
4864
+ if (!l) throw Error("Not found media-id response");
4865
4865
  return {
4866
- mediaId: c,
4867
- attachmentUrl: s?.url ?? null,
4868
- kind: s?.kind ?? null,
4869
- mimeType: s?.mimeType ?? null,
4870
- thumbnailUrl: s?.thumbnailUrl ?? null,
4871
- durationMs: s?.durationMs ?? null,
4872
- width: s?.width ?? null,
4873
- height: s?.height ?? null,
4874
- response: s
4866
+ mediaId: l,
4867
+ attachmentUrl: c?.url ?? null,
4868
+ kind: c?.kind ?? null,
4869
+ mimeType: c?.mimeType ?? null,
4870
+ thumbnailUrl: c?.thumbnailUrl ?? null,
4871
+ durationMs: c?.durationMs ?? null,
4872
+ width: c?.width ?? null,
4873
+ height: c?.height ?? null,
4874
+ response: c
4875
4875
  };
4876
4876
  }
4877
4877
  async function nte(e, t, n) {
@@ -111,7 +111,7 @@ export interface MessageReplyPreview {
111
111
  removedAt?: string | null;
112
112
  removedById?: string | null;
113
113
  }
114
- export type MediaKind = 'IMAGE' | 'VIDEO' | 'AUDIO' | 'DOCUMENT';
114
+ export type MediaKind = import('@medipha/chat-core').MediaKind;
115
115
  export interface ChatMessageAttachment {
116
116
  id: string;
117
117
  url: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@medipha/chat",
3
- "version": "1.0.57",
3
+ "version": "1.0.58",
4
4
  "description": "Embeddable Medic-ERP chat module for React applications.",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",