diff --git a/dist/assets/index-DxZltc9L.js b/dist/assets/index-B4bX57Cn.js similarity index 99% rename from dist/assets/index-DxZltc9L.js rename to dist/assets/index-B4bX57Cn.js index 1000089..ed78799 100644 --- a/dist/assets/index-DxZltc9L.js +++ b/dist/assets/index-B4bX57Cn.js @@ -2372,7 +2372,7 @@ width: 0; height: 0; opacity: 0; - `)]),Gk=N({name:`UploadDragger`,__UPLOAD_DRAGGER__:!0,setup(e,{slots:t}){let n=M(Uk,null);return n||lp(`upload-dragger`,"`n-upload-dragger` must be placed inside `n-upload`."),()=>{let{mergedClsPrefixRef:{value:e},mergedDisabledRef:{value:r},maxReachedRef:{value:i}}=n;return V(`div`,{class:[`${e}-upload-dragger`,(r||i)&&`${e}-upload-dragger--disabled`]},t)}}});function Kk(){return V(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 28 28`},V(`g`,{fill:`none`},V(`path`,{d:`M21.75 3A3.25 3.25 0 0 1 25 6.25v15.5A3.25 3.25 0 0 1 21.75 25H6.25A3.25 3.25 0 0 1 3 21.75V6.25A3.25 3.25 0 0 1 6.25 3h15.5zm.583 20.4l-7.807-7.68a.75.75 0 0 0-.968-.07l-.084.07l-7.808 7.68c.183.065.38.1.584.1h15.5c.204 0 .4-.035.583-.1l-7.807-7.68l7.807 7.68zM21.75 4.5H6.25A1.75 1.75 0 0 0 4.5 6.25v15.5c0 .208.036.408.103.593l7.82-7.692a2.25 2.25 0 0 1 3.026-.117l.129.117l7.82 7.692c.066-.185.102-.385.102-.593V6.25a1.75 1.75 0 0 0-1.75-1.75zm-3.25 3a2.5 2.5 0 1 1 0 5a2.5 2.5 0 0 1 0-5zm0 1.5a1 1 0 1 0 0 2a1 1 0 0 0 0-2z`,fill:`currentColor`})))}function qk(){return V(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 28 28`},V(`g`,{fill:`none`},V(`path`,{d:`M6.4 2A2.4 2.4 0 0 0 4 4.4v19.2A2.4 2.4 0 0 0 6.4 26h15.2a2.4 2.4 0 0 0 2.4-2.4V11.578c0-.729-.29-1.428-.805-1.944l-6.931-6.931A2.4 2.4 0 0 0 14.567 2H6.4zm-.9 2.4a.9.9 0 0 1 .9-.9H14V10a2 2 0 0 0 2 2h6.5v11.6a.9.9 0 0 1-.9.9H6.4a.9.9 0 0 1-.9-.9V4.4zm16.44 6.1H16a.5.5 0 0 1-.5-.5V4.06l6.44 6.44z`,fill:`currentColor`})))}var Jk=N({name:`UploadProgress`,props:{show:Boolean,percentage:{type:Number,required:!0},status:{type:String,required:!0}},setup(){return{mergedTheme:M(Uk).mergedThemeRef}},render(){return V(Ux,null,{default:()=>this.show?V(Sk,{type:`line`,showIndicator:!1,percentage:this.percentage,status:this.status,height:2,theme:this.mergedTheme.peers.Progress,themeOverrides:this.mergedTheme.peerOverrides.Progress}):null})}}),Yk=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};function Xk(e){return e.includes(`image/`)}function Zk(e=``){let t=e.split(`/`),n=t[t.length-1].split(/#|\?/)[0];return(/\.[^./\\]*$/.exec(n)||[``])[0]}var Qk=/(webp|svg|png|gif|jpg|jpeg|jfif|bmp|dpg|ico)$/i,$k=e=>{if(e.type)return Xk(e.type);let t=Zk(e.name||``);if(Qk.test(t))return!0;let n=e.thumbnailUrl||e.url||``,r=Zk(n);return!!(/^data:image\//.test(n)||Qk.test(r))};function eA(e){return Yk(this,void 0,void 0,function*(){return yield new Promise(t=>{if(!e.type||!Xk(e.type)){t(``);return}t(window.URL.createObjectURL(e))})})}var tA=Au&&window.FileReader&&window.File;function nA(e){return e.isDirectory}function rA(e){return e.isFile}function iA(e,t){return Yk(this,void 0,void 0,function*(){let n=[];function r(e){return Yk(this,void 0,void 0,function*(){for(let i of e)if(i){if(t&&nA(i)){let e=i.createReader(),t=[],n;try{do n=yield new Promise((t,n)=>{e.readEntries(t,n)}),t=t.concat(n);while(n.length>0)}catch(e){cp(`upload`,`error happens when handling directory upload`,e)}yield r(t)}else if(rA(i))try{let e=yield new Promise((e,t)=>{i.file(e,t)});n.push({file:e,entry:i,source:`dnd`})}catch(e){cp(`upload`,`error happens when handling file upload`,e)}}})}return yield r(e),n})}function aA(e){let{id:t,name:n,percentage:r,status:i,url:a,file:o,thumbnailUrl:s,type:c,fullPath:l,batchId:u}=e;return{id:t,name:n,percentage:r??null,status:i,url:a??null,file:o??null,thumbnailUrl:s??null,type:c??null,fullPath:l??null,batchId:u??null}}function oA(e,t,n){return e=e.toLowerCase(),t=t.toLocaleLowerCase(),n=n.toLocaleLowerCase(),n.split(`,`).map(e=>e.trim()).filter(Boolean).some(n=>{if(n.startsWith(`.`)){if(e.endsWith(n))return!0}else if(n.includes(`/`)){let[e,r]=t.split(`/`),[i,a]=n.split(`/`);if((i===`*`||e&&i&&i===e)&&(a===`*`||r&&a&&a===r))return!0}else return!0;return!1})}var sA=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})},cA={paddingMedium:`0 3px`,heightMedium:`24px`,iconSizeMedium:`18px`},lA=N({name:`UploadFile`,props:{clsPrefix:{type:String,required:!0},file:{type:Object,required:!0},listType:{type:String,required:!0},index:{type:Number,required:!0}},setup(e){let t=M(Uk),n=O(null),r=O(``),i=B(()=>{let{file:t}=e;return t.status===`finished`?`success`:t.status===`error`?`error`:`info`}),a=B(()=>{let{file:t}=e;if(t.status===`error`)return`error`}),o=B(()=>{let{file:t}=e;return t.status===`uploading`}),s=B(()=>{if(!t.showCancelButtonRef.value)return!1;let{file:n}=e;return[`uploading`,`pending`,`error`].includes(n.status)}),c=B(()=>{if(!t.showRemoveButtonRef.value)return!1;let{file:n}=e;return[`finished`].includes(n.status)}),l=B(()=>{if(!t.showDownloadButtonRef.value)return!1;let{file:n}=e;return[`finished`].includes(n.status)}),u=B(()=>{if(!t.showRetryButtonRef.value)return!1;let{file:n}=e;return[`error`].includes(n.status)}),d=$l(()=>r.value||e.file.thumbnailUrl||e.file.url),f=B(()=>{if(!t.showPreviewButtonRef.value)return!1;let{file:{status:n},listType:r}=e;return[`finished`].includes(n)&&d.value&&r===`image-card`});function p(){return sA(this,void 0,void 0,function*(){let n=t.onRetryRef.value;n&&(yield n({file:e.file}))===!1||t.submit({fileId:e.file.id})})}function m(t){t.preventDefault();let{file:n}=e;[`finished`,`pending`,`error`].includes(n.status)?g(n):[`uploading`].includes(n.status)?v(n):sp(`upload`,`The button clicked type is unknown.`)}function h(t){t.preventDefault(),_(e.file)}function g(n){let{xhrMap:r,doChange:i,onRemoveRef:{value:a},mergedFileListRef:{value:o}}=t;Promise.resolve(a?a({file:Object.assign({},n),fileList:o,index:e.index}):!0).then(e=>{if(e===!1)return;let t=Object.assign({},n,{status:`removed`});r.delete(n.id),i(t,void 0,{remove:!0})})}function _(e){let{onDownloadRef:{value:n},customDownloadRef:{value:r}}=t;Promise.resolve(n?n(Object.assign({},e)):!0).then(t=>{t!==!1&&(r?r(Object.assign({},e)):np(e.url,e.name))})}function v(e){let{xhrMap:n}=t;n.get(e.id)?.abort(),g(Object.assign({},e))}function y(r){let{onPreviewRef:{value:i}}=t;if(i)i(e.file,{event:r});else if(e.listType===`image-card`){let{value:e}=n;if(!e)return;e.showPreview()}}let b=()=>sA(this,void 0,void 0,function*(){let{listType:n}=e;n!==`image`&&n!==`image-card`||t.shouldUseThumbnailUrlRef.value(e.file)&&(r.value=yield t.getFileThumbnailUrlResolver(e.file))});return Jn(()=>{b()}),{mergedTheme:t.mergedThemeRef,progressStatus:i,buttonType:a,showProgress:o,disabled:t.mergedDisabledRef,showCancelButton:s,showRemoveButton:c,showDownloadButton:l,showRetryButton:u,showPreviewButton:f,mergedThumbnailUrl:d,shouldUseThumbnailUrl:t.shouldUseThumbnailUrlRef,renderIcon:t.renderIconRef,imageRef:n,handleRemoveOrCancelClick:m,handleDownloadClick:h,handleRetryClick:p,handlePreviewClick:y}},render(){let{clsPrefix:e,mergedTheme:t,listType:n,file:r,renderIcon:i}=this,a,o=n===`image`;a=o||n===`image-card`?!this.shouldUseThumbnailUrl(r)||!this.mergedThumbnailUrl?V(`span`,{class:`${e}-upload-file-info__thumbnail`},i?i(r):$k(r)?V(lx,{clsPrefix:e},{default:Kk}):V(lx,{clsPrefix:e},{default:qk})):V(`a`,{rel:`noopener noreferer`,target:`_blank`,href:r.url||void 0,class:`${e}-upload-file-info__thumbnail`,onClick:this.handlePreviewClick},n===`image-card`?V(uk,{src:this.mergedThumbnailUrl||void 0,previewSrc:r.url||void 0,alt:r.name,ref:`imageRef`}):V(`img`,{src:this.mergedThumbnailUrl||void 0,alt:r.name})):V(`span`,{class:`${e}-upload-file-info__thumbnail`},i?i(r):V(lx,{clsPrefix:e},{default:()=>V(hx,null)}));let s=V(Jk,{show:this.showProgress,percentage:r.percentage||0,status:this.progressStatus}),c=n===`text`||n===`image`;return V(`div`,{class:[`${e}-upload-file`,`${e}-upload-file--${this.progressStatus}-status`,r.url&&r.status!==`error`&&n!==`image-card`&&`${e}-upload-file--with-url`,`${e}-upload-file--${n}-type`]},V(`div`,{class:`${e}-upload-file-info`},a,V(`div`,{class:`${e}-upload-file-info__name`},c&&(r.url&&r.status!==`error`?V(`a`,{rel:`noopener noreferer`,target:`_blank`,href:r.url||void 0,onClick:this.handlePreviewClick},r.name):V(`span`,{onClick:this.handlePreviewClick},r.name)),o&&s),V(`div`,{class:[`${e}-upload-file-info__action`,`${e}-upload-file-info__action--${n}-type`]},this.showPreviewButton?V(nT,{key:`preview`,quaternary:!0,type:this.buttonType,onClick:this.handlePreviewClick,theme:t.peers.Button,themeOverrides:t.peerOverrides.Button,builtinThemeOverrides:cA},{icon:()=>V(lx,{clsPrefix:e},{default:()=>V(wx,null)})}):null,(this.showRemoveButton||this.showCancelButton)&&!this.disabled&&V(nT,{key:`cancelOrTrash`,theme:t.peers.Button,themeOverrides:t.peerOverrides.Button,quaternary:!0,builtinThemeOverrides:cA,type:this.buttonType,onClick:this.handleRemoveOrCancelClick},{icon:()=>V(ux,null,{default:()=>this.showRemoveButton?V(lx,{clsPrefix:e,key:`trash`},{default:()=>V(Nx,null)}):V(lx,{clsPrefix:e,key:`cancel`},{default:()=>V(gx,null)})})}),this.showRetryButton&&!this.disabled&&V(nT,{key:`retry`,quaternary:!0,type:this.buttonType,onClick:this.handleRetryClick,theme:t.peers.Button,themeOverrides:t.peerOverrides.Button,builtinThemeOverrides:cA},{icon:()=>V(lx,{clsPrefix:e},{default:()=>V(kx,null)})}),this.showDownloadButton?V(nT,{key:`download`,quaternary:!0,type:this.buttonType,onClick:this.handleDownloadClick,theme:t.peers.Button,themeOverrides:t.peerOverrides.Button,builtinThemeOverrides:cA},{icon:()=>V(lx,{clsPrefix:e},{default:()=>V(xx,null)})}):null)),!o&&s)}}),uA=N({name:`UploadTrigger`,props:{abstract:Boolean},slots:Object,setup(e,{slots:t}){let n=M(Uk,null);n||lp(`upload-trigger`,"`n-upload-trigger` must be placed inside `n-upload`.");let{mergedClsPrefixRef:r,mergedDisabledRef:i,maxReachedRef:a,listTypeRef:o,dragOverRef:s,openOpenFileDialog:c,draggerInsideRef:l,handleFileAddition:u,mergedDirectoryDndRef:d,triggerClassRef:f,triggerStyleRef:p}=n,m=B(()=>o.value===`image-card`);function h(){i.value||a.value||c()}function g(e){e.preventDefault(),s.value=!0}function _(e){e.preventDefault(),s.value=!0}function v(e){e.preventDefault(),s.value=!1}function y(e){if(e.preventDefault(),!l.value||i.value||a.value){s.value=!1;return}let t=e.dataTransfer?.items;t?.length?iA(Array.from(t).map(e=>e.webkitGetAsEntry()),d.value).then(e=>{u(e)}).finally(()=>{s.value=!1}):s.value=!1}return()=>{let{value:n}=r;return e.abstract?t.default?.call(t,{handleClick:h,handleDrop:y,handleDragOver:g,handleDragEnter:_,handleDragLeave:v}):V(`div`,{class:[`${n}-upload-trigger`,(i.value||a.value)&&`${n}-upload-trigger--disabled`,m.value&&`${n}-upload-trigger--image-card`,f.value],style:p.value,onClick:h,onDrop:y,onDragover:g,onDragenter:_,onDragleave:v},m.value?V(Gk,null,{default:()=>bp(t.default,()=>[V(lx,{clsPrefix:n},{default:()=>V(dx,null)})])}):t)}}}),dA=N({name:`UploadFileList`,setup(e,{slots:t}){let n=M(Uk,null);n||lp(`upload-file-list`,"`n-upload-file-list` must be placed inside `n-upload`.");let{abstractRef:r,mergedClsPrefixRef:i,listTypeRef:a,mergedFileListRef:o,fileListClassRef:s,fileListStyleRef:c,cssVarsRef:l,themeClassRef:u,maxReachedRef:d,showTriggerRef:f,imageGroupPropsRef:p}=n,m=B(()=>a.value===`image-card`),h=()=>o.value.map((e,t)=>V(lA,{clsPrefix:i.value,key:e.id,file:e,index:t,listType:a.value})),g=()=>m.value?V(sk,Object.assign({},p.value),{default:h}):V(Ux,{group:!0},{default:h});return()=>{let{value:e}=i,{value:n}=r;return V(`div`,{class:[`${e}-upload-file-list`,m.value&&`${e}-upload-file-list--grid`,n?u?.value:void 0,s.value],style:[n&&l?l.value:``,c.value]},g(),f.value&&!d.value&&m.value&&V(uA,null,t))}}}),fA=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};function pA(e,t,n){let{doChange:r,xhrMap:i}=e,a=0;function o(n){let o=Object.assign({},t,{status:`error`,percentage:a});i.delete(t.id),o=aA(e.onError?.call(e,{file:o,event:n})||o),r(o,n)}function s(s){if(e.isErrorState){if(e.isErrorState(n)){o(s);return}}else if(n.status<200||n.status>=300){o(s);return}let c=Object.assign({},t,{status:`finished`,percentage:a});i.delete(t.id),c=aA(e.onFinish?.call(e,{file:c,event:s})||c),r(c,s)}return{handleXHRLoad:s,handleXHRError:o,handleXHRAbort(e){let n=Object.assign({},t,{status:`removed`,file:null,percentage:a});i.delete(t.id),r(n,e)},handleXHRProgress(e){let n=Object.assign({},t,{status:`uploading`});if(e.lengthComputable){let t=Math.ceil(e.loaded/e.total*100);n.percentage=t,a=t}r(n,e)}}}function mA(e){let{inst:t,file:n,data:r,headers:i,withCredentials:a,action:o,customRequest:s}=e,{doChange:c}=e.inst,l=0;s({file:n,data:r,headers:i,withCredentials:a,action:o,onProgress(e){let t=Object.assign({},n,{status:`uploading`}),r=e.percent;t.percentage=r,l=r,c(t)},onFinish(){let e=Object.assign({},n,{status:`finished`,percentage:l});e=aA(t.onFinish?.call(t,{file:e})||e),c(e)},onError(){let e=Object.assign({},n,{status:`error`,percentage:l});e=aA(t.onError?.call(t,{file:e})||e),c(e)}})}function hA(e,t,n){let r=pA(e,t,n);n.onabort=r.handleXHRAbort,n.onerror=r.handleXHRError,n.onload=r.handleXHRLoad,n.upload&&(n.upload.onprogress=r.handleXHRProgress)}function gA(e,t){return typeof e==`function`?e({file:t}):e||{}}function _A(e,t,n){let r=gA(t,n);r&&Object.keys(r).forEach(t=>{e.setRequestHeader(t,r[t])})}function vA(e,t,n){let r=gA(t,n);r&&Object.keys(r).forEach(t=>{e.append(t,r[t])})}function yA(e,t,n,{method:r,action:i,withCredentials:a,responseType:o,headers:s,data:c}){let l=new XMLHttpRequest;l.responseType=o,e.xhrMap.set(n.id,l),l.withCredentials=a;let u=new FormData;if(vA(u,c,n),n.file!==null&&u.append(t,n.file),hA(e,n,l),i!==void 0){l.open(r.toUpperCase(),i),_A(l,s,n),l.send(u);let t=Object.assign({},n,{status:`uploading`});e.doChange(t)}}var bA=N({name:`Upload`,props:Object.assign(Object.assign({},X.props),{name:{type:String,default:`file`},accept:String,action:String,customRequest:Function,directory:Boolean,directoryDnd:{type:Boolean,default:void 0},method:{type:String,default:`POST`},multiple:Boolean,showFileList:{type:Boolean,default:!0},data:[Object,Function],headers:[Object,Function],withCredentials:Boolean,responseType:{type:String,default:``},disabled:{type:Boolean,default:void 0},onChange:Function,onRemove:Function,onFinish:Function,onError:Function,onRetry:Function,onBeforeUpload:Function,isErrorState:Function,onDownload:Function,customDownload:Function,defaultUpload:{type:Boolean,default:!0},fileList:Array,"onUpdate:fileList":[Function,Array],onUpdateFileList:[Function,Array],fileListClass:String,fileListStyle:[String,Object],defaultFileList:{type:Array,default:()=>[]},showCancelButton:{type:Boolean,default:!0},showRemoveButton:{type:Boolean,default:!0},showDownloadButton:Boolean,showRetryButton:{type:Boolean,default:!0},showPreviewButton:{type:Boolean,default:!0},listType:{type:String,default:`text`},onPreview:Function,shouldUseThumbnailUrl:{type:Function,default:e=>tA?$k(e):!1},createThumbnailUrl:Function,abstract:Boolean,max:Number,showTrigger:{type:Boolean,default:!0},imageGroupProps:Object,inputProps:Object,triggerClass:String,triggerStyle:[String,Object],renderIcon:Function}),setup(e){e.abstract&&e.listType===`image-card`&&lp(`upload`,`when the list-type is image-card, abstract is not supported.`);let{mergedClsPrefixRef:t,inlineThemeDisabled:n,mergedRtlRef:r}=Ep(e),i=X(`Upload`,`-upload`,Wk,VO,e,t),a=ex(`Upload`,r,t),o=kp(e),s=O(e.defaultFileList),c=A(e,`fileList`),l=O(null),u={value:!1},d=O(!1),f=new Map,p=hu(c,s),m=B(()=>p.value.map(aA)),h=B(()=>{let{max:t}=e;return t===void 0?!1:m.value.length>=t});function g(){var e;(e=l.value)==null||e.click()}function _(e){let t=e.target;x(t.files?Array.from(t.files).map(e=>({file:e,entry:null,source:`input`})):null,e),t.value=``}function v(t){let{"onUpdate:fileList":n,onUpdateFileList:r}=e;n&&Y(n,t),r&&Y(r,t),s.value=t}let y=B(()=>e.multiple||e.directory),b=(t,n,r={append:!1,remove:!1})=>{let{append:i,remove:a}=r,o=Array.from(m.value),s=o.findIndex(e=>e.id===t.id);if(i||a||~s){i?o.push(t):a?o.splice(s,1):o.splice(s,1,t);let{onChange:r}=e;r&&r({file:t,fileList:o,event:n}),v(o)}};function x(t,n){if(!t||t.length===0)return;let{onBeforeUpload:r}=e;t=y.value?t:[t[0]];let{max:i,accept:a}=e;t=t.filter(({file:e,source:t})=>t===`dnd`&&a?.trim()?oA(e.name,e.type,a):!0),i&&(t=t.slice(0,i-m.value.length));let o=Hl();Promise.all(t.map(e=>fA(this,[e],void 0,function*({file:e,entry:t}){let n={id:Hl(),batchId:o,name:e.name,status:`pending`,percentage:0,file:e,url:null,type:e.type,thumbnailUrl:null,fullPath:t?.fullPath??`/${e.webkitRelativePath||e.name}`};return!r||(yield r({file:n,fileList:m.value}))!==!1?n:null}))).then(e=>fA(this,void 0,void 0,function*(){let t=Promise.resolve();e.forEach(e=>{t=t.then(An).then(()=>{e&&b(e,n,{append:!0})})}),yield t})).then(()=>{e.defaultUpload&&S()})}function S({fileId:t,retry:n=!1}={}){let{method:r,action:i,withCredentials:a,headers:o,data:s,name:c}=e,l=t===void 0?m.value:m.value.filter(e=>e.id===t),u=n||t!==void 0;l.forEach(t=>{let{status:n}=t;(n===`pending`||n===`error`&&u)&&(e.customRequest?mA({inst:{doChange:b,xhrMap:f,onFinish:e.onFinish,onError:e.onError},file:t,action:i,withCredentials:a,headers:o,data:s,customRequest:e.customRequest}):yA({doChange:b,xhrMap:f,onFinish:e.onFinish,onError:e.onError,isErrorState:e.isErrorState},c,t,{method:r,action:i,withCredentials:a,responseType:e.responseType,headers:o,data:s}))})}function C(t){if(t.thumbnailUrl)return t.thumbnailUrl;let{createThumbnailUrl:n}=e;return n?n(t.file,t)??(t.url||``):t.url?t.url:t.file?eA(t.file):``}let w=B(()=>{let{common:{cubicBezierEaseInOut:e},self:{draggerColor:t,draggerBorder:n,draggerBorderHover:r,itemColorHover:a,itemColorHoverError:o,itemTextColorError:s,itemTextColorSuccess:c,itemTextColor:l,itemIconColor:u,itemDisabledOpacity:d,lineHeight:f,borderRadius:p,fontSize:m,itemBorderImageCardError:h,itemBorderImageCard:g}}=i.value;return{"--n-bezier":e,"--n-border-radius":p,"--n-dragger-border":n,"--n-dragger-border-hover":r,"--n-dragger-color":t,"--n-font-size":m,"--n-item-color-hover":a,"--n-item-color-hover-error":o,"--n-item-disabled-opacity":d,"--n-item-icon-color":u,"--n-item-text-color":l,"--n-item-text-color-error":s,"--n-item-text-color-success":c,"--n-line-height":f,"--n-item-border-image-card-error":h,"--n-item-border-image-card":g}}),T=n?Dp(`upload`,void 0,w,e):void 0;Wn(Uk,{mergedClsPrefixRef:t,mergedThemeRef:i,showCancelButtonRef:A(e,`showCancelButton`),showDownloadButtonRef:A(e,`showDownloadButton`),showRemoveButtonRef:A(e,`showRemoveButton`),showRetryButtonRef:A(e,`showRetryButton`),onRemoveRef:A(e,`onRemove`),onDownloadRef:A(e,`onDownload`),customDownloadRef:A(e,`customDownload`),mergedFileListRef:m,triggerClassRef:A(e,`triggerClass`),triggerStyleRef:A(e,`triggerStyle`),shouldUseThumbnailUrlRef:A(e,`shouldUseThumbnailUrl`),renderIconRef:A(e,`renderIcon`),xhrMap:f,submit:S,doChange:b,showPreviewButtonRef:A(e,`showPreviewButton`),onPreviewRef:A(e,`onPreview`),getFileThumbnailUrlResolver:C,listTypeRef:A(e,`listType`),dragOverRef:d,openOpenFileDialog:g,draggerInsideRef:u,handleFileAddition:x,mergedDisabledRef:o.mergedDisabledRef,maxReachedRef:h,fileListClassRef:A(e,`fileListClass`),fileListStyleRef:A(e,`fileListStyle`),abstractRef:A(e,`abstract`),acceptRef:A(e,`accept`),cssVarsRef:n?void 0:w,themeClassRef:T?.themeClass,onRender:T?.onRender,showTriggerRef:A(e,`showTrigger`),imageGroupPropsRef:A(e,`imageGroupProps`),mergedDirectoryDndRef:B(()=>e.directoryDnd??e.directory),onRetryRef:A(e,`onRetry`)});let ee={clear:()=>{s.value=[]},submit:S,openOpenFileDialog:g};return Object.assign({mergedClsPrefix:t,draggerInsideRef:u,rtlEnabled:a,inputElRef:l,mergedTheme:i,dragOver:d,mergedMultiple:y,cssVars:n?void 0:w,themeClass:T?.themeClass,onRender:T?.onRender,handleFileInputChange:_},ee)},render(){let{draggerInsideRef:e,mergedClsPrefix:t,$slots:n,directory:r,onRender:i}=this;n.default&&!this.abstract&&n.default()[0]?.type?.__UPLOAD_DRAGGER__&&(e.value=!0);let a=V(`input`,Object.assign({},this.inputProps,{ref:`inputElRef`,type:`file`,class:`${t}-upload-file-input`,accept:this.accept,multiple:this.mergedMultiple,onChange:this.handleFileInputChange,webkitdirectory:r||void 0,directory:r||void 0}));return this.abstract?V(P,null,n.default?.call(n),V(ur,{to:`body`},a)):(i?.(),V(`div`,{class:[`${t}-upload`,this.rtlEnabled&&`${t}-upload--rtl`,e.value&&`${t}-upload--dragger-inside`,this.dragOver&&`${t}-upload--drag-over`,this.themeClass],style:this.cssVars},a,this.showTrigger&&this.listType!==`image-card`&&V(uA,null,n),this.showFileList&&V(dA,null,n)))}}),xA={name:`dark`,common:Q,Alert:qC,Anchor:iw,AutoComplete:Dw,Avatar:zw,AvatarGroup:Vw,BackTop:Uw,Badge:Ww,Breadcrumb:qw,Button:eT,ButtonGroup:jD,Calendar:dT,Card:hT,Carousel:ST,Cascader:OT,Checkbox:ET,Code:PT,Collapse:IT,CollapseTransition:RT,ColorPicker:BT,DataTable:oE,DatePicker:hE,Descriptions:vE,Dialog:CE,Divider:iD,Drawer:oD,Dropdown:XT,DynamicInput:cD,DynamicTags:wD,Element:TD,Empty:QS,Ellipsis:tE,Equation:{name:`Equation`,common:Q,self:()=>({})},Flex:DD,Form:PD,GradientText:FD,Heatmap:KO,Icon:lE,IconWrapper:JO,Image:YO,Input:lw,InputNumber:ID,InputOtp:RD,LegacyTransfer:fk,Layout:zD,List:HD,LoadingBar:zE,Log:UD,Menu:qD,Mention:WD,Message:GE,Modal:jE,Notification:nD,PageHeader:XD,Pagination:qT,Popconfirm:$D,Popover:gC,Popselect:HT,Progress:nO,QrCode:Ck,Radio:rE,Rate:rO,Result:oO,Row:BD,Scrollbar:uS,Select:WT,Skeleton:wk,Slider:cO,Space:vD,Spin:uO,Statistic:fO,Steps:hO,Switch:_O,Table:SO,Tabs:EO,Tag:jC,Thing:OO,TimePicker:fE,Timeline:AO,Tooltip:QT,Transfer:MO,Tree:PO,TreeSelect:FO,Typography:zO,Upload:HO,Watermark:UO,Split:Tk,FloatButton:WO,FloatButtonGroup:{name:`FloatButtonGroup`,common:Q,self(e){let{popoverColor:t,dividerColor:n,borderRadius:r}=e;return{color:t,buttonBorderColor:n,borderRadiusSquare:r,boxShadow:`0 2px 8px 0px rgba(0, 0, 0, .12)`}}},Marquee:mk},SA=typeof document<`u`;function CA(e){return typeof e==`object`||`displayName`in e||`props`in e||`__vccOpts`in e}function wA(e){return e.__esModule||e[Symbol.toStringTag]===`Module`||e.default&&CA(e.default)}var TA=Object.assign;function EA(e,t){let n={};for(let r in t){let i=t[r];n[r]=OA(i)?i.map(e):e(i)}return n}var DA=()=>{},OA=Array.isArray;function kA(e,t){let n={};for(let r in e)n[r]=r in t?t[r]:e[r];return n}var AA=Symbol(``);function jA(e,t){return TA(Error(),{type:e,[AA]:!0},t)}function MA(e,t){return e instanceof Error&&AA in e&&(t==null||!!(e.type&t))}var NA=Symbol(``),PA=Symbol(``),FA=Symbol(``),IA=Symbol(``),LA=Symbol(``);function RA(){return M(FA)}function zA(e){return M(IA)}var BA=/#/g,VA=/&/g,HA=/\//g,UA=/=/g,WA=/\?/g,GA=/\+/g,KA=/%5B/g,qA=/%5D/g,JA=/%5E/g,YA=/%60/g,XA=/%7B/g,ZA=/%7C/g,QA=/%7D/g,$A=/%20/g;function ej(e){return e==null?``:encodeURI(``+e).replace(ZA,`|`).replace(KA,`[`).replace(qA,`]`)}function tj(e){return ej(e).replace(XA,`{`).replace(QA,`}`).replace(JA,`^`)}function nj(e){return ej(e).replace(GA,`%2B`).replace($A,`+`).replace(BA,`%23`).replace(VA,`%26`).replace(YA,"`").replace(XA,`{`).replace(QA,`}`).replace(JA,`^`)}function rj(e){return nj(e).replace(UA,`%3D`)}function ij(e){return ej(e).replace(BA,`%23`).replace(WA,`%3F`)}function aj(e){return ij(e).replace(HA,`%2F`)}function oj(e){if(e==null)return null;try{return decodeURIComponent(``+e)}catch{}return``+e}var sj=/\/$/,cj=e=>e.replace(sj,``);function lj(e,t,n=`/`){let r,i={},a=``,o=``,s=t.indexOf(`#`),c=t.indexOf(`?`);return c=s>=0&&c>s?-1:c,c>=0&&(r=t.slice(0,c),a=t.slice(c,s>0?s:t.length),i=e(a.slice(1))),s>=0&&(r||=t.slice(0,s),o=t.slice(s,t.length)),r=_j(r??t,n),{fullPath:r+a+o,path:r,query:i,hash:oj(o)}}function uj(e,t){let n=t.query?e(t.query):``;return t.path+(n&&`?`)+n+(t.hash||``)}function dj(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||`/`}function fj(e,t,n){let r=t.matched.length-1,i=n.matched.length-1;return r>-1&&r===i&&pj(t.matched[r],n.matched[i])&&mj(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function pj(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function mj(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var n in e)if(!hj(e[n],t[n]))return!1;return!0}function hj(e,t){return OA(e)?gj(e,t):OA(t)?gj(t,e):(e&&e.valueOf())===(t&&t.valueOf())}function gj(e,t){return OA(t)?e.length===t.length&&e.every((e,n)=>e===t[n]):e.length===1&&e[0]===t}function _j(e,t){if(e.startsWith(`/`))return e;if(!e)return t;let n=t.split(`/`),r=e.split(`/`),i=r[r.length-1];(i===`..`||i===`.`)&&r.push(``);let a=n.length-1,o,s;for(o=0;o1&&a--;else break;return n.slice(0,a).join(`/`)+`/`+r.slice(o).join(`/`)}var vj={path:`/`,name:void 0,params:{},query:{},hash:``,fullPath:`/`,matched:[],meta:{},redirectedFrom:void 0};function yj(e){if(!e)if(SA){let t=document.querySelector(`base`);e=t&&t.getAttribute(`href`)||`/`,e=e.replace(/^\w+:\/\/[^/]+/,``)}else e=`/`;return e[0]!==`/`&&e[0]!==`#`&&(e=`/`+e),cj(e)}var bj=/^[^#]+#/;function xj(e,t){return e.replace(bj,`#`)+t}function Sj(e,t){let n=document.documentElement.getBoundingClientRect(),r=e.getBoundingClientRect();return{behavior:t.behavior,left:r.left-n.left-(t.left||0),top:r.top-n.top-(t.top||0)}}var Cj=()=>({left:window.scrollX,top:window.scrollY});function wj(e){let t;if(`el`in e){let n=e.el,r=typeof n==`string`&&n.startsWith(`#`),i=typeof n==`string`?r?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!i)return;t=Sj(i,e)}else t=e;`scrollBehavior`in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left==null?window.scrollX:t.left,t.top==null?window.scrollY:t.top)}function Tj(e,t){return(history.state?history.state.position-t:-1)+e}var Ej=new Map;function Dj(e,t){Ej.set(e,t)}function Oj(e){let t=Ej.get(e);return Ej.delete(e),t}function kj(e){return typeof e==`string`||e&&typeof e==`object`}function Aj(e){return typeof e==`string`||typeof e==`symbol`}function jj(e){let t={};if(e===``||e===`?`)return t;let n=(e[0]===`?`?e.slice(1):e).split(`&`);for(let e=0;ee&&nj(e)):[r&&nj(r)]).forEach(e=>{e!==void 0&&(t+=(t.length?`&`:``)+n,e!=null&&(t+=`=`+e))})}return t}function Nj(e){let t={};for(let n in e){let r=e[n];r!==void 0&&(t[n]=OA(r)?r.map(e=>e==null?null:``+e):r==null?r:``+r)}return t}function Pj(){let e=[];function t(t){return e.push(t),()=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function Fj(e,t,n,r,i,a=e=>e()){let o=r&&(r.enterCallbacks[i]=r.enterCallbacks[i]||[]);return()=>new Promise((s,c)=>{let l=e=>{e===!1?c(jA(4,{from:n,to:t})):e instanceof Error?c(e):kj(e)?c(jA(2,{from:t,to:e})):(o&&r.enterCallbacks[i]===o&&typeof e==`function`&&o.push(e),s())},u=a(()=>e.call(r&&r.instances[i],t,n,l)),d=Promise.resolve(u);e.length<3&&(d=d.then(l)),d.catch(e=>c(e))})}function Ij(e,t,n,r,i=e=>e()){let a=[];for(let o of e)for(let e in o.components){let s=o.components[e];if(!(t!==`beforeRouteEnter`&&!o.instances[e]))if(CA(s)){let c=(s.__vccOpts||s)[t];c&&a.push(Fj(c,n,r,o,e,i))}else{let c=s();a.push(()=>c.then(a=>{if(!a)throw Error(`Couldn't resolve component "${e}" at "${o.path}"`);let s=wA(a)?a.default:a;o.mods[e]=a,o.components[e]=s;let c=(s.__vccOpts||s)[t];return c&&Fj(c,n,r,o,e,i)()}))}}return a}function Lj(e,t){let n=[],r=[],i=[],a=Math.max(t.matched.length,e.matched.length);for(let o=0;opj(e,a))?r.push(a):n.push(a));let s=e.matched[o];s&&(t.matched.find(e=>pj(e,s))||i.push(s))}return[n,r,i]}var Rj=()=>location.protocol+`//`+location.host;function zj(e,t){let{pathname:n,search:r,hash:i}=t,a=e.indexOf(`#`);if(a>-1){let t=i.includes(e.slice(a))?e.slice(a).length:1,n=i.slice(t);return n[0]!==`/`&&(n=`/`+n),dj(n,``)}return dj(n,e)+r+i}function Bj(e,t,n,r){let i=[],a=[],o=null,s=({state:a})=>{let s=zj(e,location),c=n.value,l=t.value,u=0;if(a){if(n.value=s,t.value=a,o&&o===c){o=null;return}u=l?a.position-l.position:0}else r(s);i.forEach(e=>{e(n.value,c,{delta:u,type:`pop`,direction:u?u>0?`forward`:`back`:``})})};function c(){o=n.value}function l(e){i.push(e);let t=()=>{let t=i.indexOf(e);t>-1&&i.splice(t,1)};return a.push(t),t}function u(){if(document.visibilityState===`hidden`){let{history:e}=window;if(!e.state)return;e.replaceState(TA({},e.state,{scroll:Cj()}),``)}}function d(){for(let e of a)e();a=[],window.removeEventListener(`popstate`,s),window.removeEventListener(`pagehide`,u),document.removeEventListener(`visibilitychange`,u)}return window.addEventListener(`popstate`,s),window.addEventListener(`pagehide`,u),document.addEventListener(`visibilitychange`,u),{pauseListeners:c,listen:l,destroy:d}}function Vj(e,t,n,r=!1,i=!1){return{back:e,current:t,forward:n,replaced:r,position:window.history.length,scroll:i?Cj():null}}function Hj(e){let{history:t,location:n}=window,r={value:zj(e,n)},i={value:t.state};i.value||a(r.value,{back:null,current:r.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function a(r,a,o){let s=e.indexOf(`#`),c=s>-1?(n.host&&document.querySelector(`base`)?e:e.slice(s))+r:Rj()+e+r;try{t[o?`replaceState`:`pushState`](a,``,c),i.value=a}catch(e){console.error(e),n[o?`replace`:`assign`](c)}}function o(e,n){a(e,TA({},t.state,Vj(i.value.back,e,i.value.forward,!0),n,{position:i.value.position}),!0),r.value=e}function s(e,n){let o=TA({},i.value,t.state,{forward:e,scroll:Cj()});a(o.current,o,!0),a(e,TA({},Vj(r.value,e,null),{position:o.position+1},n),!1),r.value=e}return{location:r,state:i,push:s,replace:o}}function Uj(e){e=yj(e);let t=Hj(e),n=Bj(e,t.state,t.location,t.replace);function r(e,t=!0){t||n.pauseListeners(),history.go(e)}let i=TA({location:``,base:e,go:r,createHref:xj.bind(null,e)},t,n);return Object.defineProperty(i,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(i,"state",{enumerable:!0,get:()=>t.state.value}),i}var Wj={type:0,value:``},Gj=/[a-zA-Z0-9_]/;function Kj(e){if(!e)return[[]];if(e===`/`)return[[Wj]];if(!e.startsWith(`/`))throw Error(`Invalid path "${e}"`);function t(e){throw Error(`ERR (${n})/"${l}": ${e}`)}let n=0,r=n,i=[],a;function o(){a&&i.push(a),a=[]}let s=0,c,l=``,u=``;function d(){l&&=(n===0?a.push({type:0,value:l}):n===1||n===2||n===3?(a.length>1&&(c===`*`||c===`+`)&&t(`A repeatable param (${l}) must be alone in its segment. eg: '/:ids+.`),a.push({type:1,value:l,regexp:u,repeatable:c===`*`||c===`+`,optional:c===`*`||c===`?`})):t(`Invalid state to consume buffer`),``)}function f(){l+=c}for(;st.length?t.length===1&&t[0]===80?1:-1:0}function Qj(e,t){let n=0,r=e.score,i=t.score;for(;n0&&t[t.length-1]<0}var eM={strict:!1,end:!0,sensitive:!1};function tM(e,t,n){let r=TA(Xj(Kj(e.path),n),{record:e,parent:t,children:[],alias:[]});return t&&!r.record.aliasOf==!t.record.aliasOf&&t.children.push(r),r}function nM(e,t){let n=[],r=new Map;t=kA(eM,t);function i(e){return r.get(e)}function a(e,n,r){let i=!r,s=iM(e);s.aliasOf=r&&r.record;let l=kA(t,e),u=[s];if(`alias`in e){let t=typeof e.alias==`string`?[e.alias]:e.alias;for(let e of t)u.push(iM(TA({},s,{components:r?r.record.components:s.components,path:e,aliasOf:r?r.record:s})))}let d,f;for(let t of u){let{path:u}=t;if(n&&u[0]!==`/`){let e=n.record.path,r=e[e.length-1]===`/`?``:`/`;t.path=n.record.path+(u&&r+u)}if(d=tM(t,n,l),r?r.alias.push(d):(f||=d,f!==d&&f.alias.push(d),i&&e.name&&!oM(d)&&o(e.name)),uM(d)&&c(d),s.children){let e=s.children;for(let t=0;t{o(f)}:DA}function o(e){if(Aj(e)){let t=r.get(e);t&&(r.delete(e),n.splice(n.indexOf(t),1),t.children.forEach(o),t.alias.forEach(o))}else{let t=n.indexOf(e);t>-1&&(n.splice(t,1),e.record.name&&r.delete(e.record.name),e.children.forEach(o),e.alias.forEach(o))}}function s(){return n}function c(e){let t=cM(e,n);n.splice(t,0,e),e.record.name&&!oM(e)&&r.set(e.record.name,e)}function l(e,t){let i,a={},o,s;if(`name`in e&&e.name){if(i=r.get(e.name),!i)throw jA(1,{location:e});s=i.record.name,a=TA(rM(t.params,i.keys.filter(e=>!e.optional).concat(i.parent?i.parent.keys.filter(e=>e.optional):[]).map(e=>e.name)),e.params&&rM(e.params,i.keys.map(e=>e.name))),o=i.stringify(a)}else if(e.path!=null)o=e.path,i=n.find(e=>e.re.test(o)),i&&(a=i.parse(o),s=i.record.name,i.keys.forEach(e=>{e.optional&&!a[e.name]&&delete a[e.name]}));else{if(i=t.name?r.get(t.name):n.find(e=>e.re.test(t.path)),!i)throw jA(1,{location:e,currentLocation:t});s=i.record.name,a=TA({},t.params,e.params),o=i.stringify(a)}let c=[],l=i;for(;l;)c.unshift(l.record),l=l.parent;return{name:s,path:o,params:a,matched:c,meta:sM(c)}}e.forEach(e=>a(e));function u(){n.length=0,r.clear()}return{addRoute:a,resolve:l,removeRoute:o,clearRoutes:u,getRoutes:s,getRecordMatcher:i}}function rM(e,t){let n={};for(let r of t)r in e&&(n[r]=e[r]);return n}function iM(e){let t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:aM(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:`components`in e?e.components||null:e.component&&{default:e.component}};return Object.defineProperty(t,"mods",{value:{}}),t}function aM(e){let t={},n=e.props||!1;if(`component`in e)t.default=n;else for(let r in e.components)t[r]=typeof n==`object`?n[r]:n;return t}function oM(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function sM(e){return e.reduce((e,t)=>TA(e,t.meta),{})}function cM(e,t){let n=0,r=t.length;for(;n!==r;){let i=n+r>>1;Qj(e,t[i])<0?r=i:n=i+1}let i=lM(e);return i&&(r=t.lastIndexOf(i,r-1)),r}function lM(e){let t=e;for(;t=t.parent;)if(uM(t)&&Qj(e,t)===0)return t}function uM({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function dM(e){let t=M(FA),n=M(IA),r=B(()=>{let n=k(e.to);return t.resolve(n)}),i=B(()=>{let{matched:e}=r.value,{length:t}=e,i=e[t-1],a=n.matched;if(!i||!a.length)return-1;let o=a.findIndex(pj.bind(null,i));if(o>-1)return o;let s=gM(e[t-2]);return t>1&&gM(i)===s&&a[a.length-1].path!==s?a.findIndex(pj.bind(null,e[t-2])):o}),a=B(()=>i.value>-1&&hM(n.params,r.value.params)),o=B(()=>i.value>-1&&i.value===n.matched.length-1&&mj(n.params,r.value.params));function s(n={}){if(mM(n)){let n=t[k(e.replace)?`replace`:`push`](k(e.to)).catch(DA);return e.viewTransition&&typeof document<`u`&&`startViewTransition`in document&&document.startViewTransition(()=>n),n}return Promise.resolve()}return{route:r,href:B(()=>r.value.href),isActive:a,isExactActive:o,navigate:s}}function fM(e){return e.length===1?e[0]:e}var pM=N({name:`RouterLink`,compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:`page`},viewTransition:Boolean},useLink:dM,setup(e,{slots:t}){let n=Ht(dM(e)),{options:r}=M(FA),i=B(()=>({[_M(e.activeClass,r.linkActiveClass,`router-link-active`)]:n.isActive,[_M(e.exactActiveClass,r.linkExactActiveClass,`router-link-exact-active`)]:n.isExactActive}));return()=>{let r=t.default&&fM(t.default(n));return e.custom?r:V(`a`,{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:i.value},r)}}});function mM(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){let t=e.currentTarget.getAttribute(`target`);if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function hM(e,t){for(let n in t){let r=t[n],i=e[n];if(typeof r==`string`){if(r!==i)return!1}else if(!OA(i)||i.length!==r.length||r.some((e,t)=>e.valueOf()!==i[t].valueOf()))return!1}return!0}function gM(e){return e?e.aliasOf?e.aliasOf.path:e.path:``}var _M=(e,t,n)=>e??t??n,vM=N({name:`RouterView`,inheritAttrs:!1,props:{name:{type:String,default:`default`},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){let r=M(LA),i=B(()=>e.route||r.value),a=M(PA,0),o=B(()=>{let e=k(a),{matched:t}=i.value,n;for(;(n=t[e])&&!n.components;)e++;return e}),s=B(()=>i.value.matched[o.value]);Wn(PA,B(()=>o.value+1)),Wn(NA,s),Wn(LA,i);let c=O();return Yn(()=>[c.value,s.value,e.name],([e,t,n],[r,i,a])=>{t&&(t.instances[n]=e,i&&i!==t&&e&&e===r&&(t.leaveGuards.size||(t.leaveGuards=i.leaveGuards),t.updateGuards.size||(t.updateGuards=i.updateGuards))),e&&t&&(!i||!pj(t,i)||!r)&&(t.enterCallbacks[n]||[]).forEach(t=>t(e))},{flush:`post`}),()=>{let r=i.value,a=e.name,o=s.value,l=o&&o.components[a];if(!l)return yM(n.default,{Component:l,route:r});let u=o.props[a],d=V(l,TA({},u?u===!0?r.params:typeof u==`function`?u(r):u:null,t,{onVnodeUnmounted:e=>{e.component.isUnmounted&&(o.instances[a]=null)},ref:c}));return yM(n.default,{Component:d,route:r})||d}}});function yM(e,t){if(!e)return null;let n=e(t);return n.length===1?n[0]:n}var bM=vM;function xM(e){let t=nM(e.routes,e),n=e.parseQuery||jj,r=e.stringifyQuery||Mj,i=e.history,a=Pj(),o=Pj(),s=Pj(),c=tn(vj),l=vj;SA&&e.scrollBehavior&&`scrollRestoration`in history&&(history.scrollRestoration=`manual`);let u=EA.bind(null,e=>``+e),d=EA.bind(null,aj),f=EA.bind(null,oj);function p(e,n){let r,i;return Aj(e)?(r=t.getRecordMatcher(e),i=n):i=e,t.addRoute(i,r)}function m(e){let n=t.getRecordMatcher(e);n&&t.removeRoute(n)}function h(){return t.getRoutes().map(e=>e.record)}function g(e){return!!t.getRecordMatcher(e)}function _(e,a){if(a=TA({},a||c.value),typeof e==`string`){let r=lj(n,e,a.path),o=t.resolve({path:r.path},a),s=i.createHref(r.fullPath);return TA(r,o,{params:f(o.params),redirectedFrom:void 0,href:s})}let o;if(e.path!=null)o=TA({},e,{path:lj(n,e.path,a.path).path});else{let t=TA({},e.params);for(let e in t)t[e]??delete t[e];o=TA({},e,{params:d(t)}),a.params=d(a.params)}let s=t.resolve(o,a),l=e.hash||``;s.params=u(f(s.params));let p=uj(r,TA({},e,{hash:tj(l),path:s.path})),m=i.createHref(p);return TA({fullPath:p,hash:l,query:r===Mj?Nj(e.query):e.query||{}},s,{redirectedFrom:void 0,href:m})}function v(e){return typeof e==`string`?lj(n,e,c.value.path):TA({},e)}function y(e,t){if(l!==e)return jA(8,{from:t,to:e})}function b(e){return C(e)}function x(e){return b(TA(v(e),{replace:!0}))}function S(e,t){let n=e.matched[e.matched.length-1];if(n&&n.redirect){let{redirect:r}=n,i=typeof r==`function`?r(e,t):r;return typeof i==`string`&&(i=i.includes(`?`)||i.includes(`#`)?i=v(i):{path:i},i.params={}),TA({query:e.query,hash:e.hash,params:i.path==null?e.params:{}},i)}}function C(e,t){let n=l=_(e),i=c.value,a=e.state,o=e.force,s=e.replace===!0,u=S(n,i);if(u)return C(TA(v(u),{state:typeof u==`object`?TA({},a,u.state):a,force:o,replace:s}),t||n);let d=n;d.redirectedFrom=t;let f;return!o&&fj(r,i,n)&&(f=jA(16,{to:d,from:i}),le(i,i,!0,!1)),(f?Promise.resolve(f):ee(d,i)).catch(e=>MA(e)?MA(e,2)?e:ce(e):oe(e,d,i)).then(e=>{if(e){if(MA(e,2))return C(TA({replace:s},v(e.to),{state:typeof e.to==`object`?TA({},a,e.to.state):a,force:o}),t||d)}else e=D(d,i,!0,s,a);return E(d,i,e),e})}function w(e,t){let n=y(e,t);return n?Promise.reject(n):Promise.resolve()}function T(e){let t=fe.values().next().value;return t&&typeof t.runWithContext==`function`?t.runWithContext(e):e()}function ee(e,t){let n,[r,i,s]=Lj(e,t);n=Ij(r.reverse(),`beforeRouteLeave`,e,t);for(let i of r)i.leaveGuards.forEach(r=>{n.push(Fj(r,e,t))});let c=w.bind(null,e,t);return n.push(c),me(n).then(()=>{n=[];for(let r of a.list())n.push(Fj(r,e,t));return n.push(c),me(n)}).then(()=>{n=Ij(i,`beforeRouteUpdate`,e,t);for(let r of i)r.updateGuards.forEach(r=>{n.push(Fj(r,e,t))});return n.push(c),me(n)}).then(()=>{n=[];for(let r of s)if(r.beforeEnter)if(OA(r.beforeEnter))for(let i of r.beforeEnter)n.push(Fj(i,e,t));else n.push(Fj(r.beforeEnter,e,t));return n.push(c),me(n)}).then(()=>(e.matched.forEach(e=>e.enterCallbacks={}),n=Ij(s,`beforeRouteEnter`,e,t,T),n.push(c),me(n))).then(()=>{n=[];for(let r of o.list())n.push(Fj(r,e,t));return n.push(c),me(n)}).catch(e=>MA(e,8)?e:Promise.reject(e))}function E(e,t,n){s.list().forEach(r=>T(()=>r(e,t,n)))}function D(e,t,n,r,a){let o=y(e,t);if(o)return o;let s=t===vj,l=SA?history.state:{};n&&(r||s?i.replace(e.fullPath,TA({scroll:s&&l&&l.scroll},a)):i.push(e.fullPath,a)),c.value=e,le(e,t,n,s),ce()}let te;function ne(){te||=i.listen((e,t,n)=>{if(!pe.listening)return;let r=_(e),a=S(r,pe.currentRoute.value);if(a){C(TA(a,{replace:!0,force:!0}),r).catch(DA);return}l=r;let o=c.value;SA&&Dj(Tj(o.fullPath,n.delta),Cj()),ee(r,o).catch(e=>MA(e,12)?e:MA(e,2)?(C(TA(v(e.to),{force:!0}),r).then(e=>{MA(e,20)&&!n.delta&&n.type===`pop`&&i.go(-1,!1)}).catch(DA),Promise.reject()):(n.delta&&i.go(-n.delta,!1),oe(e,r,o))).then(e=>{e||=D(r,o,!1),e&&(n.delta&&!MA(e,8)?i.go(-n.delta,!1):n.type===`pop`&&MA(e,20)&&i.go(-1,!1)),E(r,o,e)}).catch(DA)})}let re=Pj(),ie=Pj(),ae;function oe(e,t,n){ce(e);let r=ie.list();return r.length?r.forEach(r=>r(e,t,n)):console.error(e),Promise.reject(e)}function se(){return ae&&c.value!==vj?Promise.resolve():new Promise((e,t)=>{re.add([e,t])})}function ce(e){return ae||(ae=!e,ne(),re.list().forEach(([t,n])=>e?n(e):t()),re.reset()),e}function le(t,n,r,i){let{scrollBehavior:a}=e;if(!SA||!a)return Promise.resolve();let o=!r&&Oj(Tj(t.fullPath,0))||(i||!r)&&history.state&&history.state.scroll||null;return An().then(()=>a(t,n,o)).then(e=>e&&wj(e)).catch(e=>oe(e,t,n))}let ue=e=>i.go(e),de,fe=new Set,pe={currentRoute:c,listening:!0,addRoute:p,removeRoute:m,clearRoutes:t.clearRoutes,hasRoute:g,getRoutes:h,resolve:_,options:e,push:b,replace:x,go:ue,back:()=>ue(-1),forward:()=>ue(1),beforeEach:a.add,beforeResolve:o.add,afterEach:s.add,onError:ie.add,isReady:se,install(e){e.component(`RouterLink`,pM),e.component(`RouterView`,bM),e.config.globalProperties.$router=pe,Object.defineProperty(e.config.globalProperties,"$route",{enumerable:!0,get:()=>k(c)}),SA&&!de&&c.value===vj&&(de=!0,b(i.location).catch(e=>{}));let t={};for(let e in vj)Object.defineProperty(t,e,{get:()=>c.value[e],enumerable:!0});e.provide(FA,pe),e.provide(IA,Ut(t)),e.provide(LA,c);let n=e.unmount;fe.add(e),e.unmount=function(){fe.delete(e),fe.size<1&&(l=vj,te&&te(),te=null,c.value=vj,de=!1,ae=!1),n()}}};function me(e){return e.reduce((e,t)=>e.then(()=>T(t)),Promise.resolve())}return pe}var SM=N({__name:`App`,setup(e){return(e,t)=>(F(),Ca(k(VT),{theme:k(xA)},{default:j(()=>[R(k(QE),null,{default:j(()=>[R(k(bM))]),_:1})]),_:1},8,[`theme`]))}});function CM(e){return{Ping(t){let n=[],r=`api/test/ping`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`Ping`})},Echo(t){let n=[];t.text&&n.push(`text=${encodeURIComponent(t.text.toString())}`);let r=`api/test/echo`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`POST`,body:null},{service:`EveningDetectiveServer`,method:`Echo`})},Signup(t){let n=JSON.stringify(t),r=[],i=`api/auth/signup`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`Signup`})},RefreshPassword(t){let n=JSON.stringify(t),r=[],i=`api/auth/refresh-password`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`RefreshPassword`})},Login(t){let n=JSON.stringify(t),r=[],i=`api/auth/login`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`Login`})},Refresh(t){let n=JSON.stringify(t),r=[],i=`api/auth/refresh`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`Refresh`})},GetUsers(t){let n=[],r=`api/users`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetUsers`})},GetUserById(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/users/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetUserById`})},GetMe(t){let n=[],r=`api/users/me`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetMe`})},AddUserRole(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/users/${t.id}/role/add`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`AddUserRole`})},DeleteUserRole(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/users/${t.id}/role/delete`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`DeleteUserRole`})},GetPermissions(t){let n=[],r=`api/ui/permissions`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetPermissions`})},UploadFile(t){let n=JSON.stringify(t),r=[],i=`api/files/upload`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`UploadFile`})},DownloadFile(t){if(!t.filename)throw Error(`missing required field request.filename`);let n=`api/files/${t.filename}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`DownloadFile`})},AddScenario(t){let n=JSON.stringify(t),r=[],i=`api/scenario`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`AddScenario`})},GetMyScenarios(t){let n=[],r=`api/my-scenarios`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetMyScenarios`})},GetScenariosCatalog(t){let n=[],r=`api/catalog`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetScenariosCatalog`})},GetFullScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}/full`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetFullScenario`})},GetScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetScenario`})},UpdateScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`UpdateScenario`})},PublicScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}/public`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`PublicScenario`})},DraftScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}/draft`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`DraftScenario`})},DeleteScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteScenario`})},AddScenarioPlace(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}/places`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`AddScenarioPlace`})},UpdateScenarioPlace(t){if(!t.id)throw Error(`missing required field request.id`);if(!t.code)throw Error(`missing required field request.code`);let n=`api/scenarios/${t.id}/places/${t.code}`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`UpdateScenarioPlace`})},DeleteScenarioPlace(t){if(!t.id)throw Error(`missing required field request.id`);if(!t.code)throw Error(`missing required field request.code`);let n=`api/scenarios/${t.id}/places/${t.code}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteScenarioPlace`})},AddGame(t){let n=JSON.stringify(t),r=[],i=`api/games`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`AddGame`})},GetGames(t){let n=[],r=`api/games`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetGames`})},GetGame(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/games/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetGame`})},UpdateGame(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/games/${t.id}`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`UpdateGame`})},DeleteGame(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/games/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteGame`})},AddTeam(t){let n=JSON.stringify(t),r=[],i=`api/teams`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`AddTeam`})},UpdateTeam(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`UpdateTeam`})},DeleteTeam(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteTeam`})},GiveTeamApplications(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}/applications`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`GiveTeamApplications`})},GetTeamStory(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}/story`,r=[];t.password&&r.push(`password=${encodeURIComponent(t.password.toString())}`);let i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetTeamStory`})},AddTeamAction(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}/actions`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`AddTeamAction`})},DeleteLastTeamAction(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}/last-actions`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteLastTeamAction`})}}}function wM(e){return CM(TM(e))}function TM(e){return async t=>{let n=`${EM()}/${t.path}`,r={"Content-Type":`application/json`},i=e?.();i&&(r.Authorization=`Bearer ${i}`);let a=await fetch(n,{method:t.method,headers:r,body:t.body});if(a.status==401)throw Error(`unauthorized`);return await a.json()}}function EM(){return`http://192.168.1.111:8090`}var DM=fc(`auth`,()=>{let e=O(null),t=O(null),n=O(null),r=O(!1),i=O(null),a=B(()=>!!e.value),o=B(()=>n.value?.username||``),s=B(()=>n.value?.roles||[]);function c(){let n=localStorage.getItem(`accessToken`),r=localStorage.getItem(`refreshToken`);n&&(e.value=n,t.value=r,u())}function l(){return e.value}async function u(){if(e.value)try{let e=await wM(l).GetMe({});if(e.error){i.value=e.error;return}e.user&&(n.value=e.user)}catch(e){console.error(`Failed to fetch user:`,e),e instanceof Error&&e.message.includes(`401`)&&await h()}}async function d(n,a){r.value=!0,i.value=null;try{let r=await wM(l).Login({email:n,password:a});return r.error?(i.value=r.error,!1):r.accessToken?(e.value=r.accessToken,t.value=r.refreshToken||null,localStorage.setItem(`accessToken`,r.accessToken),r.refreshToken&&localStorage.setItem(`refreshToken`,r.refreshToken),await u(),!0):!1}catch(e){return i.value=e instanceof Error?e.message:`Login failed`,!1}finally{r.value=!1}}async function f(){if(!t.value)return!1;try{let n=await wM(l).Refresh({refreshToken:t.value});return n.error||!n.accessToken?!1:(e.value=n.accessToken,t.value=n.refreshToken||null,localStorage.setItem(`accessToken`,n.accessToken),n.refreshToken&&localStorage.setItem(`refreshToken`,n.refreshToken),!0)}catch{return!1}}async function p(e,t){r.value=!0,i.value=null;try{let n=await wM(l).Signup({username:e,email:t});return n.error?(i.value=n.error,!1):!0}catch(e){return i.value=e instanceof Error?e.message:`Signup failed`,!1}finally{r.value=!1}}async function m(e){r.value=!0,i.value=null;try{let t=await wM(l).RefreshPassword({email:e});return t.error?(i.value=t.error,!1):!0}catch(e){return i.value=e instanceof Error?e.message:`Password reset failed`,!1}finally{r.value=!1}}async function h(){e.value=null,t.value=null,n.value=null,i.value=null,localStorage.removeItem(`accessToken`),localStorage.removeItem(`refreshToken`)}function g(e){return s.value.includes(e)}function _(e){return e.some(e=>s.value.includes(e))}return{accessToken:e,refreshToken:t,user:n,isLoading:r,error:i,isAuthenticated:a,username:o,userRoles:s,initFromStorage:c,getToken:l,login:d,signup:p,refreshPassword:m,logout:h,fetchUser:u,refreshTokenAction:f,hasRole:g,hasAnyRole:_}});function OM(){let e=DM();return kM(e.refreshTokenAction,e.getToken)}function kM(e,t){return CM(AM(e,TM(t)))}function AM(e,t){return async n=>{try{return await t(n)}catch{return await e(),await t(n)}}}var jM={xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,viewBox:`0 0 24 24`},MM=N({name:`LockOutlined`,render:function(e,t){return F(),I(`svg`,jM,t[0]||=[L(`path`,{d:`M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zM9 6c0-1.66 1.34-3 3-3s3 1.34 3 3v2H9V6zm9 14H6V10h12v10zm-6-3c1.1 0 2-.9 2-2s-.9-2-2-2s-2 .9-2 2s.9 2 2 2z`,fill:`currentColor`},null,-1)])}}),NM={xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,viewBox:`0 0 24 24`},PM=N({name:`MenuOutlined`,render:function(e,t){return F(),I(`svg`,NM,t[0]||=[L(`path`,{d:`M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z`,fill:`currentColor`},null,-1)])}});function FM(e){let t=0;for(let n=0;n{let r=FM(t);if(!r){e.forEach(e=>{n.push((e&&e+` `)+t)});return}else if(r===1){e.forEach(e=>{n.push(t.replace(`&`,e))});return}let i=[t];for(;r--;){let t=[];i.forEach(n=>{e.forEach(e=>{t.push(n.replace(`&`,e))})}),i=t}i.forEach(e=>n.push(e))}),n}function zM(e,t){let n=[];return t.split(IM).forEach(t=>{e.forEach(e=>{n.push((e&&e+` `)+t)})}),n}function BM(e){let t=[``];return e.forEach(e=>{e&&=e.trim(),e&&(t=e.includes(`&`)?RM(t,e):zM(t,e))}),t.join(`, `).replace(LM,` `)}var VM=/[A-Z]/g;function HM(e){return e.replace(VM,e=>`-`+e.toLowerCase())}function UM(e,t=` `){return typeof e==`object`&&e?` { + `)]),Gk=N({name:`UploadDragger`,__UPLOAD_DRAGGER__:!0,setup(e,{slots:t}){let n=M(Uk,null);return n||lp(`upload-dragger`,"`n-upload-dragger` must be placed inside `n-upload`."),()=>{let{mergedClsPrefixRef:{value:e},mergedDisabledRef:{value:r},maxReachedRef:{value:i}}=n;return V(`div`,{class:[`${e}-upload-dragger`,(r||i)&&`${e}-upload-dragger--disabled`]},t)}}});function Kk(){return V(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 28 28`},V(`g`,{fill:`none`},V(`path`,{d:`M21.75 3A3.25 3.25 0 0 1 25 6.25v15.5A3.25 3.25 0 0 1 21.75 25H6.25A3.25 3.25 0 0 1 3 21.75V6.25A3.25 3.25 0 0 1 6.25 3h15.5zm.583 20.4l-7.807-7.68a.75.75 0 0 0-.968-.07l-.084.07l-7.808 7.68c.183.065.38.1.584.1h15.5c.204 0 .4-.035.583-.1l-7.807-7.68l7.807 7.68zM21.75 4.5H6.25A1.75 1.75 0 0 0 4.5 6.25v15.5c0 .208.036.408.103.593l7.82-7.692a2.25 2.25 0 0 1 3.026-.117l.129.117l7.82 7.692c.066-.185.102-.385.102-.593V6.25a1.75 1.75 0 0 0-1.75-1.75zm-3.25 3a2.5 2.5 0 1 1 0 5a2.5 2.5 0 0 1 0-5zm0 1.5a1 1 0 1 0 0 2a1 1 0 0 0 0-2z`,fill:`currentColor`})))}function qk(){return V(`svg`,{xmlns:`http://www.w3.org/2000/svg`,viewBox:`0 0 28 28`},V(`g`,{fill:`none`},V(`path`,{d:`M6.4 2A2.4 2.4 0 0 0 4 4.4v19.2A2.4 2.4 0 0 0 6.4 26h15.2a2.4 2.4 0 0 0 2.4-2.4V11.578c0-.729-.29-1.428-.805-1.944l-6.931-6.931A2.4 2.4 0 0 0 14.567 2H6.4zm-.9 2.4a.9.9 0 0 1 .9-.9H14V10a2 2 0 0 0 2 2h6.5v11.6a.9.9 0 0 1-.9.9H6.4a.9.9 0 0 1-.9-.9V4.4zm16.44 6.1H16a.5.5 0 0 1-.5-.5V4.06l6.44 6.44z`,fill:`currentColor`})))}var Jk=N({name:`UploadProgress`,props:{show:Boolean,percentage:{type:Number,required:!0},status:{type:String,required:!0}},setup(){return{mergedTheme:M(Uk).mergedThemeRef}},render(){return V(Ux,null,{default:()=>this.show?V(Sk,{type:`line`,showIndicator:!1,percentage:this.percentage,status:this.status,height:2,theme:this.mergedTheme.peers.Progress,themeOverrides:this.mergedTheme.peerOverrides.Progress}):null})}}),Yk=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};function Xk(e){return e.includes(`image/`)}function Zk(e=``){let t=e.split(`/`),n=t[t.length-1].split(/#|\?/)[0];return(/\.[^./\\]*$/.exec(n)||[``])[0]}var Qk=/(webp|svg|png|gif|jpg|jpeg|jfif|bmp|dpg|ico)$/i,$k=e=>{if(e.type)return Xk(e.type);let t=Zk(e.name||``);if(Qk.test(t))return!0;let n=e.thumbnailUrl||e.url||``,r=Zk(n);return!!(/^data:image\//.test(n)||Qk.test(r))};function eA(e){return Yk(this,void 0,void 0,function*(){return yield new Promise(t=>{if(!e.type||!Xk(e.type)){t(``);return}t(window.URL.createObjectURL(e))})})}var tA=Au&&window.FileReader&&window.File;function nA(e){return e.isDirectory}function rA(e){return e.isFile}function iA(e,t){return Yk(this,void 0,void 0,function*(){let n=[];function r(e){return Yk(this,void 0,void 0,function*(){for(let i of e)if(i){if(t&&nA(i)){let e=i.createReader(),t=[],n;try{do n=yield new Promise((t,n)=>{e.readEntries(t,n)}),t=t.concat(n);while(n.length>0)}catch(e){cp(`upload`,`error happens when handling directory upload`,e)}yield r(t)}else if(rA(i))try{let e=yield new Promise((e,t)=>{i.file(e,t)});n.push({file:e,entry:i,source:`dnd`})}catch(e){cp(`upload`,`error happens when handling file upload`,e)}}})}return yield r(e),n})}function aA(e){let{id:t,name:n,percentage:r,status:i,url:a,file:o,thumbnailUrl:s,type:c,fullPath:l,batchId:u}=e;return{id:t,name:n,percentage:r??null,status:i,url:a??null,file:o??null,thumbnailUrl:s??null,type:c??null,fullPath:l??null,batchId:u??null}}function oA(e,t,n){return e=e.toLowerCase(),t=t.toLocaleLowerCase(),n=n.toLocaleLowerCase(),n.split(`,`).map(e=>e.trim()).filter(Boolean).some(n=>{if(n.startsWith(`.`)){if(e.endsWith(n))return!0}else if(n.includes(`/`)){let[e,r]=t.split(`/`),[i,a]=n.split(`/`);if((i===`*`||e&&i&&i===e)&&(a===`*`||r&&a&&a===r))return!0}else return!0;return!1})}var sA=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})},cA={paddingMedium:`0 3px`,heightMedium:`24px`,iconSizeMedium:`18px`},lA=N({name:`UploadFile`,props:{clsPrefix:{type:String,required:!0},file:{type:Object,required:!0},listType:{type:String,required:!0},index:{type:Number,required:!0}},setup(e){let t=M(Uk),n=O(null),r=O(``),i=B(()=>{let{file:t}=e;return t.status===`finished`?`success`:t.status===`error`?`error`:`info`}),a=B(()=>{let{file:t}=e;if(t.status===`error`)return`error`}),o=B(()=>{let{file:t}=e;return t.status===`uploading`}),s=B(()=>{if(!t.showCancelButtonRef.value)return!1;let{file:n}=e;return[`uploading`,`pending`,`error`].includes(n.status)}),c=B(()=>{if(!t.showRemoveButtonRef.value)return!1;let{file:n}=e;return[`finished`].includes(n.status)}),l=B(()=>{if(!t.showDownloadButtonRef.value)return!1;let{file:n}=e;return[`finished`].includes(n.status)}),u=B(()=>{if(!t.showRetryButtonRef.value)return!1;let{file:n}=e;return[`error`].includes(n.status)}),d=$l(()=>r.value||e.file.thumbnailUrl||e.file.url),f=B(()=>{if(!t.showPreviewButtonRef.value)return!1;let{file:{status:n},listType:r}=e;return[`finished`].includes(n)&&d.value&&r===`image-card`});function p(){return sA(this,void 0,void 0,function*(){let n=t.onRetryRef.value;n&&(yield n({file:e.file}))===!1||t.submit({fileId:e.file.id})})}function m(t){t.preventDefault();let{file:n}=e;[`finished`,`pending`,`error`].includes(n.status)?g(n):[`uploading`].includes(n.status)?v(n):sp(`upload`,`The button clicked type is unknown.`)}function h(t){t.preventDefault(),_(e.file)}function g(n){let{xhrMap:r,doChange:i,onRemoveRef:{value:a},mergedFileListRef:{value:o}}=t;Promise.resolve(a?a({file:Object.assign({},n),fileList:o,index:e.index}):!0).then(e=>{if(e===!1)return;let t=Object.assign({},n,{status:`removed`});r.delete(n.id),i(t,void 0,{remove:!0})})}function _(e){let{onDownloadRef:{value:n},customDownloadRef:{value:r}}=t;Promise.resolve(n?n(Object.assign({},e)):!0).then(t=>{t!==!1&&(r?r(Object.assign({},e)):np(e.url,e.name))})}function v(e){let{xhrMap:n}=t;n.get(e.id)?.abort(),g(Object.assign({},e))}function y(r){let{onPreviewRef:{value:i}}=t;if(i)i(e.file,{event:r});else if(e.listType===`image-card`){let{value:e}=n;if(!e)return;e.showPreview()}}let b=()=>sA(this,void 0,void 0,function*(){let{listType:n}=e;n!==`image`&&n!==`image-card`||t.shouldUseThumbnailUrlRef.value(e.file)&&(r.value=yield t.getFileThumbnailUrlResolver(e.file))});return Jn(()=>{b()}),{mergedTheme:t.mergedThemeRef,progressStatus:i,buttonType:a,showProgress:o,disabled:t.mergedDisabledRef,showCancelButton:s,showRemoveButton:c,showDownloadButton:l,showRetryButton:u,showPreviewButton:f,mergedThumbnailUrl:d,shouldUseThumbnailUrl:t.shouldUseThumbnailUrlRef,renderIcon:t.renderIconRef,imageRef:n,handleRemoveOrCancelClick:m,handleDownloadClick:h,handleRetryClick:p,handlePreviewClick:y}},render(){let{clsPrefix:e,mergedTheme:t,listType:n,file:r,renderIcon:i}=this,a,o=n===`image`;a=o||n===`image-card`?!this.shouldUseThumbnailUrl(r)||!this.mergedThumbnailUrl?V(`span`,{class:`${e}-upload-file-info__thumbnail`},i?i(r):$k(r)?V(lx,{clsPrefix:e},{default:Kk}):V(lx,{clsPrefix:e},{default:qk})):V(`a`,{rel:`noopener noreferer`,target:`_blank`,href:r.url||void 0,class:`${e}-upload-file-info__thumbnail`,onClick:this.handlePreviewClick},n===`image-card`?V(uk,{src:this.mergedThumbnailUrl||void 0,previewSrc:r.url||void 0,alt:r.name,ref:`imageRef`}):V(`img`,{src:this.mergedThumbnailUrl||void 0,alt:r.name})):V(`span`,{class:`${e}-upload-file-info__thumbnail`},i?i(r):V(lx,{clsPrefix:e},{default:()=>V(hx,null)}));let s=V(Jk,{show:this.showProgress,percentage:r.percentage||0,status:this.progressStatus}),c=n===`text`||n===`image`;return V(`div`,{class:[`${e}-upload-file`,`${e}-upload-file--${this.progressStatus}-status`,r.url&&r.status!==`error`&&n!==`image-card`&&`${e}-upload-file--with-url`,`${e}-upload-file--${n}-type`]},V(`div`,{class:`${e}-upload-file-info`},a,V(`div`,{class:`${e}-upload-file-info__name`},c&&(r.url&&r.status!==`error`?V(`a`,{rel:`noopener noreferer`,target:`_blank`,href:r.url||void 0,onClick:this.handlePreviewClick},r.name):V(`span`,{onClick:this.handlePreviewClick},r.name)),o&&s),V(`div`,{class:[`${e}-upload-file-info__action`,`${e}-upload-file-info__action--${n}-type`]},this.showPreviewButton?V(nT,{key:`preview`,quaternary:!0,type:this.buttonType,onClick:this.handlePreviewClick,theme:t.peers.Button,themeOverrides:t.peerOverrides.Button,builtinThemeOverrides:cA},{icon:()=>V(lx,{clsPrefix:e},{default:()=>V(wx,null)})}):null,(this.showRemoveButton||this.showCancelButton)&&!this.disabled&&V(nT,{key:`cancelOrTrash`,theme:t.peers.Button,themeOverrides:t.peerOverrides.Button,quaternary:!0,builtinThemeOverrides:cA,type:this.buttonType,onClick:this.handleRemoveOrCancelClick},{icon:()=>V(ux,null,{default:()=>this.showRemoveButton?V(lx,{clsPrefix:e,key:`trash`},{default:()=>V(Nx,null)}):V(lx,{clsPrefix:e,key:`cancel`},{default:()=>V(gx,null)})})}),this.showRetryButton&&!this.disabled&&V(nT,{key:`retry`,quaternary:!0,type:this.buttonType,onClick:this.handleRetryClick,theme:t.peers.Button,themeOverrides:t.peerOverrides.Button,builtinThemeOverrides:cA},{icon:()=>V(lx,{clsPrefix:e},{default:()=>V(kx,null)})}),this.showDownloadButton?V(nT,{key:`download`,quaternary:!0,type:this.buttonType,onClick:this.handleDownloadClick,theme:t.peers.Button,themeOverrides:t.peerOverrides.Button,builtinThemeOverrides:cA},{icon:()=>V(lx,{clsPrefix:e},{default:()=>V(xx,null)})}):null)),!o&&s)}}),uA=N({name:`UploadTrigger`,props:{abstract:Boolean},slots:Object,setup(e,{slots:t}){let n=M(Uk,null);n||lp(`upload-trigger`,"`n-upload-trigger` must be placed inside `n-upload`.");let{mergedClsPrefixRef:r,mergedDisabledRef:i,maxReachedRef:a,listTypeRef:o,dragOverRef:s,openOpenFileDialog:c,draggerInsideRef:l,handleFileAddition:u,mergedDirectoryDndRef:d,triggerClassRef:f,triggerStyleRef:p}=n,m=B(()=>o.value===`image-card`);function h(){i.value||a.value||c()}function g(e){e.preventDefault(),s.value=!0}function _(e){e.preventDefault(),s.value=!0}function v(e){e.preventDefault(),s.value=!1}function y(e){if(e.preventDefault(),!l.value||i.value||a.value){s.value=!1;return}let t=e.dataTransfer?.items;t?.length?iA(Array.from(t).map(e=>e.webkitGetAsEntry()),d.value).then(e=>{u(e)}).finally(()=>{s.value=!1}):s.value=!1}return()=>{let{value:n}=r;return e.abstract?t.default?.call(t,{handleClick:h,handleDrop:y,handleDragOver:g,handleDragEnter:_,handleDragLeave:v}):V(`div`,{class:[`${n}-upload-trigger`,(i.value||a.value)&&`${n}-upload-trigger--disabled`,m.value&&`${n}-upload-trigger--image-card`,f.value],style:p.value,onClick:h,onDrop:y,onDragover:g,onDragenter:_,onDragleave:v},m.value?V(Gk,null,{default:()=>bp(t.default,()=>[V(lx,{clsPrefix:n},{default:()=>V(dx,null)})])}):t)}}}),dA=N({name:`UploadFileList`,setup(e,{slots:t}){let n=M(Uk,null);n||lp(`upload-file-list`,"`n-upload-file-list` must be placed inside `n-upload`.");let{abstractRef:r,mergedClsPrefixRef:i,listTypeRef:a,mergedFileListRef:o,fileListClassRef:s,fileListStyleRef:c,cssVarsRef:l,themeClassRef:u,maxReachedRef:d,showTriggerRef:f,imageGroupPropsRef:p}=n,m=B(()=>a.value===`image-card`),h=()=>o.value.map((e,t)=>V(lA,{clsPrefix:i.value,key:e.id,file:e,index:t,listType:a.value})),g=()=>m.value?V(sk,Object.assign({},p.value),{default:h}):V(Ux,{group:!0},{default:h});return()=>{let{value:e}=i,{value:n}=r;return V(`div`,{class:[`${e}-upload-file-list`,m.value&&`${e}-upload-file-list--grid`,n?u?.value:void 0,s.value],style:[n&&l?l.value:``,c.value]},g(),f.value&&!d.value&&m.value&&V(uA,null,t))}}}),fA=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};function pA(e,t,n){let{doChange:r,xhrMap:i}=e,a=0;function o(n){let o=Object.assign({},t,{status:`error`,percentage:a});i.delete(t.id),o=aA(e.onError?.call(e,{file:o,event:n})||o),r(o,n)}function s(s){if(e.isErrorState){if(e.isErrorState(n)){o(s);return}}else if(n.status<200||n.status>=300){o(s);return}let c=Object.assign({},t,{status:`finished`,percentage:a});i.delete(t.id),c=aA(e.onFinish?.call(e,{file:c,event:s})||c),r(c,s)}return{handleXHRLoad:s,handleXHRError:o,handleXHRAbort(e){let n=Object.assign({},t,{status:`removed`,file:null,percentage:a});i.delete(t.id),r(n,e)},handleXHRProgress(e){let n=Object.assign({},t,{status:`uploading`});if(e.lengthComputable){let t=Math.ceil(e.loaded/e.total*100);n.percentage=t,a=t}r(n,e)}}}function mA(e){let{inst:t,file:n,data:r,headers:i,withCredentials:a,action:o,customRequest:s}=e,{doChange:c}=e.inst,l=0;s({file:n,data:r,headers:i,withCredentials:a,action:o,onProgress(e){let t=Object.assign({},n,{status:`uploading`}),r=e.percent;t.percentage=r,l=r,c(t)},onFinish(){let e=Object.assign({},n,{status:`finished`,percentage:l});e=aA(t.onFinish?.call(t,{file:e})||e),c(e)},onError(){let e=Object.assign({},n,{status:`error`,percentage:l});e=aA(t.onError?.call(t,{file:e})||e),c(e)}})}function hA(e,t,n){let r=pA(e,t,n);n.onabort=r.handleXHRAbort,n.onerror=r.handleXHRError,n.onload=r.handleXHRLoad,n.upload&&(n.upload.onprogress=r.handleXHRProgress)}function gA(e,t){return typeof e==`function`?e({file:t}):e||{}}function _A(e,t,n){let r=gA(t,n);r&&Object.keys(r).forEach(t=>{e.setRequestHeader(t,r[t])})}function vA(e,t,n){let r=gA(t,n);r&&Object.keys(r).forEach(t=>{e.append(t,r[t])})}function yA(e,t,n,{method:r,action:i,withCredentials:a,responseType:o,headers:s,data:c}){let l=new XMLHttpRequest;l.responseType=o,e.xhrMap.set(n.id,l),l.withCredentials=a;let u=new FormData;if(vA(u,c,n),n.file!==null&&u.append(t,n.file),hA(e,n,l),i!==void 0){l.open(r.toUpperCase(),i),_A(l,s,n),l.send(u);let t=Object.assign({},n,{status:`uploading`});e.doChange(t)}}var bA=N({name:`Upload`,props:Object.assign(Object.assign({},X.props),{name:{type:String,default:`file`},accept:String,action:String,customRequest:Function,directory:Boolean,directoryDnd:{type:Boolean,default:void 0},method:{type:String,default:`POST`},multiple:Boolean,showFileList:{type:Boolean,default:!0},data:[Object,Function],headers:[Object,Function],withCredentials:Boolean,responseType:{type:String,default:``},disabled:{type:Boolean,default:void 0},onChange:Function,onRemove:Function,onFinish:Function,onError:Function,onRetry:Function,onBeforeUpload:Function,isErrorState:Function,onDownload:Function,customDownload:Function,defaultUpload:{type:Boolean,default:!0},fileList:Array,"onUpdate:fileList":[Function,Array],onUpdateFileList:[Function,Array],fileListClass:String,fileListStyle:[String,Object],defaultFileList:{type:Array,default:()=>[]},showCancelButton:{type:Boolean,default:!0},showRemoveButton:{type:Boolean,default:!0},showDownloadButton:Boolean,showRetryButton:{type:Boolean,default:!0},showPreviewButton:{type:Boolean,default:!0},listType:{type:String,default:`text`},onPreview:Function,shouldUseThumbnailUrl:{type:Function,default:e=>tA?$k(e):!1},createThumbnailUrl:Function,abstract:Boolean,max:Number,showTrigger:{type:Boolean,default:!0},imageGroupProps:Object,inputProps:Object,triggerClass:String,triggerStyle:[String,Object],renderIcon:Function}),setup(e){e.abstract&&e.listType===`image-card`&&lp(`upload`,`when the list-type is image-card, abstract is not supported.`);let{mergedClsPrefixRef:t,inlineThemeDisabled:n,mergedRtlRef:r}=Ep(e),i=X(`Upload`,`-upload`,Wk,VO,e,t),a=ex(`Upload`,r,t),o=kp(e),s=O(e.defaultFileList),c=A(e,`fileList`),l=O(null),u={value:!1},d=O(!1),f=new Map,p=hu(c,s),m=B(()=>p.value.map(aA)),h=B(()=>{let{max:t}=e;return t===void 0?!1:m.value.length>=t});function g(){var e;(e=l.value)==null||e.click()}function _(e){let t=e.target;x(t.files?Array.from(t.files).map(e=>({file:e,entry:null,source:`input`})):null,e),t.value=``}function v(t){let{"onUpdate:fileList":n,onUpdateFileList:r}=e;n&&Y(n,t),r&&Y(r,t),s.value=t}let y=B(()=>e.multiple||e.directory),b=(t,n,r={append:!1,remove:!1})=>{let{append:i,remove:a}=r,o=Array.from(m.value),s=o.findIndex(e=>e.id===t.id);if(i||a||~s){i?o.push(t):a?o.splice(s,1):o.splice(s,1,t);let{onChange:r}=e;r&&r({file:t,fileList:o,event:n}),v(o)}};function x(t,n){if(!t||t.length===0)return;let{onBeforeUpload:r}=e;t=y.value?t:[t[0]];let{max:i,accept:a}=e;t=t.filter(({file:e,source:t})=>t===`dnd`&&a?.trim()?oA(e.name,e.type,a):!0),i&&(t=t.slice(0,i-m.value.length));let o=Hl();Promise.all(t.map(e=>fA(this,[e],void 0,function*({file:e,entry:t}){let n={id:Hl(),batchId:o,name:e.name,status:`pending`,percentage:0,file:e,url:null,type:e.type,thumbnailUrl:null,fullPath:t?.fullPath??`/${e.webkitRelativePath||e.name}`};return!r||(yield r({file:n,fileList:m.value}))!==!1?n:null}))).then(e=>fA(this,void 0,void 0,function*(){let t=Promise.resolve();e.forEach(e=>{t=t.then(An).then(()=>{e&&b(e,n,{append:!0})})}),yield t})).then(()=>{e.defaultUpload&&S()})}function S({fileId:t,retry:n=!1}={}){let{method:r,action:i,withCredentials:a,headers:o,data:s,name:c}=e,l=t===void 0?m.value:m.value.filter(e=>e.id===t),u=n||t!==void 0;l.forEach(t=>{let{status:n}=t;(n===`pending`||n===`error`&&u)&&(e.customRequest?mA({inst:{doChange:b,xhrMap:f,onFinish:e.onFinish,onError:e.onError},file:t,action:i,withCredentials:a,headers:o,data:s,customRequest:e.customRequest}):yA({doChange:b,xhrMap:f,onFinish:e.onFinish,onError:e.onError,isErrorState:e.isErrorState},c,t,{method:r,action:i,withCredentials:a,responseType:e.responseType,headers:o,data:s}))})}function C(t){if(t.thumbnailUrl)return t.thumbnailUrl;let{createThumbnailUrl:n}=e;return n?n(t.file,t)??(t.url||``):t.url?t.url:t.file?eA(t.file):``}let w=B(()=>{let{common:{cubicBezierEaseInOut:e},self:{draggerColor:t,draggerBorder:n,draggerBorderHover:r,itemColorHover:a,itemColorHoverError:o,itemTextColorError:s,itemTextColorSuccess:c,itemTextColor:l,itemIconColor:u,itemDisabledOpacity:d,lineHeight:f,borderRadius:p,fontSize:m,itemBorderImageCardError:h,itemBorderImageCard:g}}=i.value;return{"--n-bezier":e,"--n-border-radius":p,"--n-dragger-border":n,"--n-dragger-border-hover":r,"--n-dragger-color":t,"--n-font-size":m,"--n-item-color-hover":a,"--n-item-color-hover-error":o,"--n-item-disabled-opacity":d,"--n-item-icon-color":u,"--n-item-text-color":l,"--n-item-text-color-error":s,"--n-item-text-color-success":c,"--n-line-height":f,"--n-item-border-image-card-error":h,"--n-item-border-image-card":g}}),T=n?Dp(`upload`,void 0,w,e):void 0;Wn(Uk,{mergedClsPrefixRef:t,mergedThemeRef:i,showCancelButtonRef:A(e,`showCancelButton`),showDownloadButtonRef:A(e,`showDownloadButton`),showRemoveButtonRef:A(e,`showRemoveButton`),showRetryButtonRef:A(e,`showRetryButton`),onRemoveRef:A(e,`onRemove`),onDownloadRef:A(e,`onDownload`),customDownloadRef:A(e,`customDownload`),mergedFileListRef:m,triggerClassRef:A(e,`triggerClass`),triggerStyleRef:A(e,`triggerStyle`),shouldUseThumbnailUrlRef:A(e,`shouldUseThumbnailUrl`),renderIconRef:A(e,`renderIcon`),xhrMap:f,submit:S,doChange:b,showPreviewButtonRef:A(e,`showPreviewButton`),onPreviewRef:A(e,`onPreview`),getFileThumbnailUrlResolver:C,listTypeRef:A(e,`listType`),dragOverRef:d,openOpenFileDialog:g,draggerInsideRef:u,handleFileAddition:x,mergedDisabledRef:o.mergedDisabledRef,maxReachedRef:h,fileListClassRef:A(e,`fileListClass`),fileListStyleRef:A(e,`fileListStyle`),abstractRef:A(e,`abstract`),acceptRef:A(e,`accept`),cssVarsRef:n?void 0:w,themeClassRef:T?.themeClass,onRender:T?.onRender,showTriggerRef:A(e,`showTrigger`),imageGroupPropsRef:A(e,`imageGroupProps`),mergedDirectoryDndRef:B(()=>e.directoryDnd??e.directory),onRetryRef:A(e,`onRetry`)});let ee={clear:()=>{s.value=[]},submit:S,openOpenFileDialog:g};return Object.assign({mergedClsPrefix:t,draggerInsideRef:u,rtlEnabled:a,inputElRef:l,mergedTheme:i,dragOver:d,mergedMultiple:y,cssVars:n?void 0:w,themeClass:T?.themeClass,onRender:T?.onRender,handleFileInputChange:_},ee)},render(){let{draggerInsideRef:e,mergedClsPrefix:t,$slots:n,directory:r,onRender:i}=this;n.default&&!this.abstract&&n.default()[0]?.type?.__UPLOAD_DRAGGER__&&(e.value=!0);let a=V(`input`,Object.assign({},this.inputProps,{ref:`inputElRef`,type:`file`,class:`${t}-upload-file-input`,accept:this.accept,multiple:this.mergedMultiple,onChange:this.handleFileInputChange,webkitdirectory:r||void 0,directory:r||void 0}));return this.abstract?V(P,null,n.default?.call(n),V(ur,{to:`body`},a)):(i?.(),V(`div`,{class:[`${t}-upload`,this.rtlEnabled&&`${t}-upload--rtl`,e.value&&`${t}-upload--dragger-inside`,this.dragOver&&`${t}-upload--drag-over`,this.themeClass],style:this.cssVars},a,this.showTrigger&&this.listType!==`image-card`&&V(uA,null,n),this.showFileList&&V(dA,null,n)))}}),xA={name:`dark`,common:Q,Alert:qC,Anchor:iw,AutoComplete:Dw,Avatar:zw,AvatarGroup:Vw,BackTop:Uw,Badge:Ww,Breadcrumb:qw,Button:eT,ButtonGroup:jD,Calendar:dT,Card:hT,Carousel:ST,Cascader:OT,Checkbox:ET,Code:PT,Collapse:IT,CollapseTransition:RT,ColorPicker:BT,DataTable:oE,DatePicker:hE,Descriptions:vE,Dialog:CE,Divider:iD,Drawer:oD,Dropdown:XT,DynamicInput:cD,DynamicTags:wD,Element:TD,Empty:QS,Ellipsis:tE,Equation:{name:`Equation`,common:Q,self:()=>({})},Flex:DD,Form:PD,GradientText:FD,Heatmap:KO,Icon:lE,IconWrapper:JO,Image:YO,Input:lw,InputNumber:ID,InputOtp:RD,LegacyTransfer:fk,Layout:zD,List:HD,LoadingBar:zE,Log:UD,Menu:qD,Mention:WD,Message:GE,Modal:jE,Notification:nD,PageHeader:XD,Pagination:qT,Popconfirm:$D,Popover:gC,Popselect:HT,Progress:nO,QrCode:Ck,Radio:rE,Rate:rO,Result:oO,Row:BD,Scrollbar:uS,Select:WT,Skeleton:wk,Slider:cO,Space:vD,Spin:uO,Statistic:fO,Steps:hO,Switch:_O,Table:SO,Tabs:EO,Tag:jC,Thing:OO,TimePicker:fE,Timeline:AO,Tooltip:QT,Transfer:MO,Tree:PO,TreeSelect:FO,Typography:zO,Upload:HO,Watermark:UO,Split:Tk,FloatButton:WO,FloatButtonGroup:{name:`FloatButtonGroup`,common:Q,self(e){let{popoverColor:t,dividerColor:n,borderRadius:r}=e;return{color:t,buttonBorderColor:n,borderRadiusSquare:r,boxShadow:`0 2px 8px 0px rgba(0, 0, 0, .12)`}}},Marquee:mk},SA=typeof document<`u`;function CA(e){return typeof e==`object`||`displayName`in e||`props`in e||`__vccOpts`in e}function wA(e){return e.__esModule||e[Symbol.toStringTag]===`Module`||e.default&&CA(e.default)}var TA=Object.assign;function EA(e,t){let n={};for(let r in t){let i=t[r];n[r]=OA(i)?i.map(e):e(i)}return n}var DA=()=>{},OA=Array.isArray;function kA(e,t){let n={};for(let r in e)n[r]=r in t?t[r]:e[r];return n}var AA=Symbol(``);function jA(e,t){return TA(Error(),{type:e,[AA]:!0},t)}function MA(e,t){return e instanceof Error&&AA in e&&(t==null||!!(e.type&t))}var NA=Symbol(``),PA=Symbol(``),FA=Symbol(``),IA=Symbol(``),LA=Symbol(``);function RA(){return M(FA)}function zA(e){return M(IA)}var BA=/#/g,VA=/&/g,HA=/\//g,UA=/=/g,WA=/\?/g,GA=/\+/g,KA=/%5B/g,qA=/%5D/g,JA=/%5E/g,YA=/%60/g,XA=/%7B/g,ZA=/%7C/g,QA=/%7D/g,$A=/%20/g;function ej(e){return e==null?``:encodeURI(``+e).replace(ZA,`|`).replace(KA,`[`).replace(qA,`]`)}function tj(e){return ej(e).replace(XA,`{`).replace(QA,`}`).replace(JA,`^`)}function nj(e){return ej(e).replace(GA,`%2B`).replace($A,`+`).replace(BA,`%23`).replace(VA,`%26`).replace(YA,"`").replace(XA,`{`).replace(QA,`}`).replace(JA,`^`)}function rj(e){return nj(e).replace(UA,`%3D`)}function ij(e){return ej(e).replace(BA,`%23`).replace(WA,`%3F`)}function aj(e){return ij(e).replace(HA,`%2F`)}function oj(e){if(e==null)return null;try{return decodeURIComponent(``+e)}catch{}return``+e}var sj=/\/$/,cj=e=>e.replace(sj,``);function lj(e,t,n=`/`){let r,i={},a=``,o=``,s=t.indexOf(`#`),c=t.indexOf(`?`);return c=s>=0&&c>s?-1:c,c>=0&&(r=t.slice(0,c),a=t.slice(c,s>0?s:t.length),i=e(a.slice(1))),s>=0&&(r||=t.slice(0,s),o=t.slice(s,t.length)),r=_j(r??t,n),{fullPath:r+a+o,path:r,query:i,hash:oj(o)}}function uj(e,t){let n=t.query?e(t.query):``;return t.path+(n&&`?`)+n+(t.hash||``)}function dj(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||`/`}function fj(e,t,n){let r=t.matched.length-1,i=n.matched.length-1;return r>-1&&r===i&&pj(t.matched[r],n.matched[i])&&mj(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function pj(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function mj(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var n in e)if(!hj(e[n],t[n]))return!1;return!0}function hj(e,t){return OA(e)?gj(e,t):OA(t)?gj(t,e):(e&&e.valueOf())===(t&&t.valueOf())}function gj(e,t){return OA(t)?e.length===t.length&&e.every((e,n)=>e===t[n]):e.length===1&&e[0]===t}function _j(e,t){if(e.startsWith(`/`))return e;if(!e)return t;let n=t.split(`/`),r=e.split(`/`),i=r[r.length-1];(i===`..`||i===`.`)&&r.push(``);let a=n.length-1,o,s;for(o=0;o1&&a--;else break;return n.slice(0,a).join(`/`)+`/`+r.slice(o).join(`/`)}var vj={path:`/`,name:void 0,params:{},query:{},hash:``,fullPath:`/`,matched:[],meta:{},redirectedFrom:void 0};function yj(e){if(!e)if(SA){let t=document.querySelector(`base`);e=t&&t.getAttribute(`href`)||`/`,e=e.replace(/^\w+:\/\/[^/]+/,``)}else e=`/`;return e[0]!==`/`&&e[0]!==`#`&&(e=`/`+e),cj(e)}var bj=/^[^#]+#/;function xj(e,t){return e.replace(bj,`#`)+t}function Sj(e,t){let n=document.documentElement.getBoundingClientRect(),r=e.getBoundingClientRect();return{behavior:t.behavior,left:r.left-n.left-(t.left||0),top:r.top-n.top-(t.top||0)}}var Cj=()=>({left:window.scrollX,top:window.scrollY});function wj(e){let t;if(`el`in e){let n=e.el,r=typeof n==`string`&&n.startsWith(`#`),i=typeof n==`string`?r?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!i)return;t=Sj(i,e)}else t=e;`scrollBehavior`in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left==null?window.scrollX:t.left,t.top==null?window.scrollY:t.top)}function Tj(e,t){return(history.state?history.state.position-t:-1)+e}var Ej=new Map;function Dj(e,t){Ej.set(e,t)}function Oj(e){let t=Ej.get(e);return Ej.delete(e),t}function kj(e){return typeof e==`string`||e&&typeof e==`object`}function Aj(e){return typeof e==`string`||typeof e==`symbol`}function jj(e){let t={};if(e===``||e===`?`)return t;let n=(e[0]===`?`?e.slice(1):e).split(`&`);for(let e=0;ee&&nj(e)):[r&&nj(r)]).forEach(e=>{e!==void 0&&(t+=(t.length?`&`:``)+n,e!=null&&(t+=`=`+e))})}return t}function Nj(e){let t={};for(let n in e){let r=e[n];r!==void 0&&(t[n]=OA(r)?r.map(e=>e==null?null:``+e):r==null?r:``+r)}return t}function Pj(){let e=[];function t(t){return e.push(t),()=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function Fj(e,t,n,r,i,a=e=>e()){let o=r&&(r.enterCallbacks[i]=r.enterCallbacks[i]||[]);return()=>new Promise((s,c)=>{let l=e=>{e===!1?c(jA(4,{from:n,to:t})):e instanceof Error?c(e):kj(e)?c(jA(2,{from:t,to:e})):(o&&r.enterCallbacks[i]===o&&typeof e==`function`&&o.push(e),s())},u=a(()=>e.call(r&&r.instances[i],t,n,l)),d=Promise.resolve(u);e.length<3&&(d=d.then(l)),d.catch(e=>c(e))})}function Ij(e,t,n,r,i=e=>e()){let a=[];for(let o of e)for(let e in o.components){let s=o.components[e];if(!(t!==`beforeRouteEnter`&&!o.instances[e]))if(CA(s)){let c=(s.__vccOpts||s)[t];c&&a.push(Fj(c,n,r,o,e,i))}else{let c=s();a.push(()=>c.then(a=>{if(!a)throw Error(`Couldn't resolve component "${e}" at "${o.path}"`);let s=wA(a)?a.default:a;o.mods[e]=a,o.components[e]=s;let c=(s.__vccOpts||s)[t];return c&&Fj(c,n,r,o,e,i)()}))}}return a}function Lj(e,t){let n=[],r=[],i=[],a=Math.max(t.matched.length,e.matched.length);for(let o=0;opj(e,a))?r.push(a):n.push(a));let s=e.matched[o];s&&(t.matched.find(e=>pj(e,s))||i.push(s))}return[n,r,i]}var Rj=()=>location.protocol+`//`+location.host;function zj(e,t){let{pathname:n,search:r,hash:i}=t,a=e.indexOf(`#`);if(a>-1){let t=i.includes(e.slice(a))?e.slice(a).length:1,n=i.slice(t);return n[0]!==`/`&&(n=`/`+n),dj(n,``)}return dj(n,e)+r+i}function Bj(e,t,n,r){let i=[],a=[],o=null,s=({state:a})=>{let s=zj(e,location),c=n.value,l=t.value,u=0;if(a){if(n.value=s,t.value=a,o&&o===c){o=null;return}u=l?a.position-l.position:0}else r(s);i.forEach(e=>{e(n.value,c,{delta:u,type:`pop`,direction:u?u>0?`forward`:`back`:``})})};function c(){o=n.value}function l(e){i.push(e);let t=()=>{let t=i.indexOf(e);t>-1&&i.splice(t,1)};return a.push(t),t}function u(){if(document.visibilityState===`hidden`){let{history:e}=window;if(!e.state)return;e.replaceState(TA({},e.state,{scroll:Cj()}),``)}}function d(){for(let e of a)e();a=[],window.removeEventListener(`popstate`,s),window.removeEventListener(`pagehide`,u),document.removeEventListener(`visibilitychange`,u)}return window.addEventListener(`popstate`,s),window.addEventListener(`pagehide`,u),document.addEventListener(`visibilitychange`,u),{pauseListeners:c,listen:l,destroy:d}}function Vj(e,t,n,r=!1,i=!1){return{back:e,current:t,forward:n,replaced:r,position:window.history.length,scroll:i?Cj():null}}function Hj(e){let{history:t,location:n}=window,r={value:zj(e,n)},i={value:t.state};i.value||a(r.value,{back:null,current:r.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function a(r,a,o){let s=e.indexOf(`#`),c=s>-1?(n.host&&document.querySelector(`base`)?e:e.slice(s))+r:Rj()+e+r;try{t[o?`replaceState`:`pushState`](a,``,c),i.value=a}catch(e){console.error(e),n[o?`replace`:`assign`](c)}}function o(e,n){a(e,TA({},t.state,Vj(i.value.back,e,i.value.forward,!0),n,{position:i.value.position}),!0),r.value=e}function s(e,n){let o=TA({},i.value,t.state,{forward:e,scroll:Cj()});a(o.current,o,!0),a(e,TA({},Vj(r.value,e,null),{position:o.position+1},n),!1),r.value=e}return{location:r,state:i,push:s,replace:o}}function Uj(e){e=yj(e);let t=Hj(e),n=Bj(e,t.state,t.location,t.replace);function r(e,t=!0){t||n.pauseListeners(),history.go(e)}let i=TA({location:``,base:e,go:r,createHref:xj.bind(null,e)},t,n);return Object.defineProperty(i,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(i,"state",{enumerable:!0,get:()=>t.state.value}),i}var Wj={type:0,value:``},Gj=/[a-zA-Z0-9_]/;function Kj(e){if(!e)return[[]];if(e===`/`)return[[Wj]];if(!e.startsWith(`/`))throw Error(`Invalid path "${e}"`);function t(e){throw Error(`ERR (${n})/"${l}": ${e}`)}let n=0,r=n,i=[],a;function o(){a&&i.push(a),a=[]}let s=0,c,l=``,u=``;function d(){l&&=(n===0?a.push({type:0,value:l}):n===1||n===2||n===3?(a.length>1&&(c===`*`||c===`+`)&&t(`A repeatable param (${l}) must be alone in its segment. eg: '/:ids+.`),a.push({type:1,value:l,regexp:u,repeatable:c===`*`||c===`+`,optional:c===`*`||c===`?`})):t(`Invalid state to consume buffer`),``)}function f(){l+=c}for(;st.length?t.length===1&&t[0]===80?1:-1:0}function Qj(e,t){let n=0,r=e.score,i=t.score;for(;n0&&t[t.length-1]<0}var eM={strict:!1,end:!0,sensitive:!1};function tM(e,t,n){let r=TA(Xj(Kj(e.path),n),{record:e,parent:t,children:[],alias:[]});return t&&!r.record.aliasOf==!t.record.aliasOf&&t.children.push(r),r}function nM(e,t){let n=[],r=new Map;t=kA(eM,t);function i(e){return r.get(e)}function a(e,n,r){let i=!r,s=iM(e);s.aliasOf=r&&r.record;let l=kA(t,e),u=[s];if(`alias`in e){let t=typeof e.alias==`string`?[e.alias]:e.alias;for(let e of t)u.push(iM(TA({},s,{components:r?r.record.components:s.components,path:e,aliasOf:r?r.record:s})))}let d,f;for(let t of u){let{path:u}=t;if(n&&u[0]!==`/`){let e=n.record.path,r=e[e.length-1]===`/`?``:`/`;t.path=n.record.path+(u&&r+u)}if(d=tM(t,n,l),r?r.alias.push(d):(f||=d,f!==d&&f.alias.push(d),i&&e.name&&!oM(d)&&o(e.name)),uM(d)&&c(d),s.children){let e=s.children;for(let t=0;t{o(f)}:DA}function o(e){if(Aj(e)){let t=r.get(e);t&&(r.delete(e),n.splice(n.indexOf(t),1),t.children.forEach(o),t.alias.forEach(o))}else{let t=n.indexOf(e);t>-1&&(n.splice(t,1),e.record.name&&r.delete(e.record.name),e.children.forEach(o),e.alias.forEach(o))}}function s(){return n}function c(e){let t=cM(e,n);n.splice(t,0,e),e.record.name&&!oM(e)&&r.set(e.record.name,e)}function l(e,t){let i,a={},o,s;if(`name`in e&&e.name){if(i=r.get(e.name),!i)throw jA(1,{location:e});s=i.record.name,a=TA(rM(t.params,i.keys.filter(e=>!e.optional).concat(i.parent?i.parent.keys.filter(e=>e.optional):[]).map(e=>e.name)),e.params&&rM(e.params,i.keys.map(e=>e.name))),o=i.stringify(a)}else if(e.path!=null)o=e.path,i=n.find(e=>e.re.test(o)),i&&(a=i.parse(o),s=i.record.name,i.keys.forEach(e=>{e.optional&&!a[e.name]&&delete a[e.name]}));else{if(i=t.name?r.get(t.name):n.find(e=>e.re.test(t.path)),!i)throw jA(1,{location:e,currentLocation:t});s=i.record.name,a=TA({},t.params,e.params),o=i.stringify(a)}let c=[],l=i;for(;l;)c.unshift(l.record),l=l.parent;return{name:s,path:o,params:a,matched:c,meta:sM(c)}}e.forEach(e=>a(e));function u(){n.length=0,r.clear()}return{addRoute:a,resolve:l,removeRoute:o,clearRoutes:u,getRoutes:s,getRecordMatcher:i}}function rM(e,t){let n={};for(let r of t)r in e&&(n[r]=e[r]);return n}function iM(e){let t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:aM(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:`components`in e?e.components||null:e.component&&{default:e.component}};return Object.defineProperty(t,"mods",{value:{}}),t}function aM(e){let t={},n=e.props||!1;if(`component`in e)t.default=n;else for(let r in e.components)t[r]=typeof n==`object`?n[r]:n;return t}function oM(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function sM(e){return e.reduce((e,t)=>TA(e,t.meta),{})}function cM(e,t){let n=0,r=t.length;for(;n!==r;){let i=n+r>>1;Qj(e,t[i])<0?r=i:n=i+1}let i=lM(e);return i&&(r=t.lastIndexOf(i,r-1)),r}function lM(e){let t=e;for(;t=t.parent;)if(uM(t)&&Qj(e,t)===0)return t}function uM({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function dM(e){let t=M(FA),n=M(IA),r=B(()=>{let n=k(e.to);return t.resolve(n)}),i=B(()=>{let{matched:e}=r.value,{length:t}=e,i=e[t-1],a=n.matched;if(!i||!a.length)return-1;let o=a.findIndex(pj.bind(null,i));if(o>-1)return o;let s=gM(e[t-2]);return t>1&&gM(i)===s&&a[a.length-1].path!==s?a.findIndex(pj.bind(null,e[t-2])):o}),a=B(()=>i.value>-1&&hM(n.params,r.value.params)),o=B(()=>i.value>-1&&i.value===n.matched.length-1&&mj(n.params,r.value.params));function s(n={}){if(mM(n)){let n=t[k(e.replace)?`replace`:`push`](k(e.to)).catch(DA);return e.viewTransition&&typeof document<`u`&&`startViewTransition`in document&&document.startViewTransition(()=>n),n}return Promise.resolve()}return{route:r,href:B(()=>r.value.href),isActive:a,isExactActive:o,navigate:s}}function fM(e){return e.length===1?e[0]:e}var pM=N({name:`RouterLink`,compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:`page`},viewTransition:Boolean},useLink:dM,setup(e,{slots:t}){let n=Ht(dM(e)),{options:r}=M(FA),i=B(()=>({[_M(e.activeClass,r.linkActiveClass,`router-link-active`)]:n.isActive,[_M(e.exactActiveClass,r.linkExactActiveClass,`router-link-exact-active`)]:n.isExactActive}));return()=>{let r=t.default&&fM(t.default(n));return e.custom?r:V(`a`,{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:i.value},r)}}});function mM(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){let t=e.currentTarget.getAttribute(`target`);if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function hM(e,t){for(let n in t){let r=t[n],i=e[n];if(typeof r==`string`){if(r!==i)return!1}else if(!OA(i)||i.length!==r.length||r.some((e,t)=>e.valueOf()!==i[t].valueOf()))return!1}return!0}function gM(e){return e?e.aliasOf?e.aliasOf.path:e.path:``}var _M=(e,t,n)=>e??t??n,vM=N({name:`RouterView`,inheritAttrs:!1,props:{name:{type:String,default:`default`},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){let r=M(LA),i=B(()=>e.route||r.value),a=M(PA,0),o=B(()=>{let e=k(a),{matched:t}=i.value,n;for(;(n=t[e])&&!n.components;)e++;return e}),s=B(()=>i.value.matched[o.value]);Wn(PA,B(()=>o.value+1)),Wn(NA,s),Wn(LA,i);let c=O();return Yn(()=>[c.value,s.value,e.name],([e,t,n],[r,i,a])=>{t&&(t.instances[n]=e,i&&i!==t&&e&&e===r&&(t.leaveGuards.size||(t.leaveGuards=i.leaveGuards),t.updateGuards.size||(t.updateGuards=i.updateGuards))),e&&t&&(!i||!pj(t,i)||!r)&&(t.enterCallbacks[n]||[]).forEach(t=>t(e))},{flush:`post`}),()=>{let r=i.value,a=e.name,o=s.value,l=o&&o.components[a];if(!l)return yM(n.default,{Component:l,route:r});let u=o.props[a],d=V(l,TA({},u?u===!0?r.params:typeof u==`function`?u(r):u:null,t,{onVnodeUnmounted:e=>{e.component.isUnmounted&&(o.instances[a]=null)},ref:c}));return yM(n.default,{Component:d,route:r})||d}}});function yM(e,t){if(!e)return null;let n=e(t);return n.length===1?n[0]:n}var bM=vM;function xM(e){let t=nM(e.routes,e),n=e.parseQuery||jj,r=e.stringifyQuery||Mj,i=e.history,a=Pj(),o=Pj(),s=Pj(),c=tn(vj),l=vj;SA&&e.scrollBehavior&&`scrollRestoration`in history&&(history.scrollRestoration=`manual`);let u=EA.bind(null,e=>``+e),d=EA.bind(null,aj),f=EA.bind(null,oj);function p(e,n){let r,i;return Aj(e)?(r=t.getRecordMatcher(e),i=n):i=e,t.addRoute(i,r)}function m(e){let n=t.getRecordMatcher(e);n&&t.removeRoute(n)}function h(){return t.getRoutes().map(e=>e.record)}function g(e){return!!t.getRecordMatcher(e)}function _(e,a){if(a=TA({},a||c.value),typeof e==`string`){let r=lj(n,e,a.path),o=t.resolve({path:r.path},a),s=i.createHref(r.fullPath);return TA(r,o,{params:f(o.params),redirectedFrom:void 0,href:s})}let o;if(e.path!=null)o=TA({},e,{path:lj(n,e.path,a.path).path});else{let t=TA({},e.params);for(let e in t)t[e]??delete t[e];o=TA({},e,{params:d(t)}),a.params=d(a.params)}let s=t.resolve(o,a),l=e.hash||``;s.params=u(f(s.params));let p=uj(r,TA({},e,{hash:tj(l),path:s.path})),m=i.createHref(p);return TA({fullPath:p,hash:l,query:r===Mj?Nj(e.query):e.query||{}},s,{redirectedFrom:void 0,href:m})}function v(e){return typeof e==`string`?lj(n,e,c.value.path):TA({},e)}function y(e,t){if(l!==e)return jA(8,{from:t,to:e})}function b(e){return C(e)}function x(e){return b(TA(v(e),{replace:!0}))}function S(e,t){let n=e.matched[e.matched.length-1];if(n&&n.redirect){let{redirect:r}=n,i=typeof r==`function`?r(e,t):r;return typeof i==`string`&&(i=i.includes(`?`)||i.includes(`#`)?i=v(i):{path:i},i.params={}),TA({query:e.query,hash:e.hash,params:i.path==null?e.params:{}},i)}}function C(e,t){let n=l=_(e),i=c.value,a=e.state,o=e.force,s=e.replace===!0,u=S(n,i);if(u)return C(TA(v(u),{state:typeof u==`object`?TA({},a,u.state):a,force:o,replace:s}),t||n);let d=n;d.redirectedFrom=t;let f;return!o&&fj(r,i,n)&&(f=jA(16,{to:d,from:i}),le(i,i,!0,!1)),(f?Promise.resolve(f):ee(d,i)).catch(e=>MA(e)?MA(e,2)?e:ce(e):oe(e,d,i)).then(e=>{if(e){if(MA(e,2))return C(TA({replace:s},v(e.to),{state:typeof e.to==`object`?TA({},a,e.to.state):a,force:o}),t||d)}else e=D(d,i,!0,s,a);return E(d,i,e),e})}function w(e,t){let n=y(e,t);return n?Promise.reject(n):Promise.resolve()}function T(e){let t=fe.values().next().value;return t&&typeof t.runWithContext==`function`?t.runWithContext(e):e()}function ee(e,t){let n,[r,i,s]=Lj(e,t);n=Ij(r.reverse(),`beforeRouteLeave`,e,t);for(let i of r)i.leaveGuards.forEach(r=>{n.push(Fj(r,e,t))});let c=w.bind(null,e,t);return n.push(c),me(n).then(()=>{n=[];for(let r of a.list())n.push(Fj(r,e,t));return n.push(c),me(n)}).then(()=>{n=Ij(i,`beforeRouteUpdate`,e,t);for(let r of i)r.updateGuards.forEach(r=>{n.push(Fj(r,e,t))});return n.push(c),me(n)}).then(()=>{n=[];for(let r of s)if(r.beforeEnter)if(OA(r.beforeEnter))for(let i of r.beforeEnter)n.push(Fj(i,e,t));else n.push(Fj(r.beforeEnter,e,t));return n.push(c),me(n)}).then(()=>(e.matched.forEach(e=>e.enterCallbacks={}),n=Ij(s,`beforeRouteEnter`,e,t,T),n.push(c),me(n))).then(()=>{n=[];for(let r of o.list())n.push(Fj(r,e,t));return n.push(c),me(n)}).catch(e=>MA(e,8)?e:Promise.reject(e))}function E(e,t,n){s.list().forEach(r=>T(()=>r(e,t,n)))}function D(e,t,n,r,a){let o=y(e,t);if(o)return o;let s=t===vj,l=SA?history.state:{};n&&(r||s?i.replace(e.fullPath,TA({scroll:s&&l&&l.scroll},a)):i.push(e.fullPath,a)),c.value=e,le(e,t,n,s),ce()}let te;function ne(){te||=i.listen((e,t,n)=>{if(!pe.listening)return;let r=_(e),a=S(r,pe.currentRoute.value);if(a){C(TA(a,{replace:!0,force:!0}),r).catch(DA);return}l=r;let o=c.value;SA&&Dj(Tj(o.fullPath,n.delta),Cj()),ee(r,o).catch(e=>MA(e,12)?e:MA(e,2)?(C(TA(v(e.to),{force:!0}),r).then(e=>{MA(e,20)&&!n.delta&&n.type===`pop`&&i.go(-1,!1)}).catch(DA),Promise.reject()):(n.delta&&i.go(-n.delta,!1),oe(e,r,o))).then(e=>{e||=D(r,o,!1),e&&(n.delta&&!MA(e,8)?i.go(-n.delta,!1):n.type===`pop`&&MA(e,20)&&i.go(-1,!1)),E(r,o,e)}).catch(DA)})}let re=Pj(),ie=Pj(),ae;function oe(e,t,n){ce(e);let r=ie.list();return r.length?r.forEach(r=>r(e,t,n)):console.error(e),Promise.reject(e)}function se(){return ae&&c.value!==vj?Promise.resolve():new Promise((e,t)=>{re.add([e,t])})}function ce(e){return ae||(ae=!e,ne(),re.list().forEach(([t,n])=>e?n(e):t()),re.reset()),e}function le(t,n,r,i){let{scrollBehavior:a}=e;if(!SA||!a)return Promise.resolve();let o=!r&&Oj(Tj(t.fullPath,0))||(i||!r)&&history.state&&history.state.scroll||null;return An().then(()=>a(t,n,o)).then(e=>e&&wj(e)).catch(e=>oe(e,t,n))}let ue=e=>i.go(e),de,fe=new Set,pe={currentRoute:c,listening:!0,addRoute:p,removeRoute:m,clearRoutes:t.clearRoutes,hasRoute:g,getRoutes:h,resolve:_,options:e,push:b,replace:x,go:ue,back:()=>ue(-1),forward:()=>ue(1),beforeEach:a.add,beforeResolve:o.add,afterEach:s.add,onError:ie.add,isReady:se,install(e){e.component(`RouterLink`,pM),e.component(`RouterView`,bM),e.config.globalProperties.$router=pe,Object.defineProperty(e.config.globalProperties,"$route",{enumerable:!0,get:()=>k(c)}),SA&&!de&&c.value===vj&&(de=!0,b(i.location).catch(e=>{}));let t={};for(let e in vj)Object.defineProperty(t,e,{get:()=>c.value[e],enumerable:!0});e.provide(FA,pe),e.provide(IA,Ut(t)),e.provide(LA,c);let n=e.unmount;fe.add(e),e.unmount=function(){fe.delete(e),fe.size<1&&(l=vj,te&&te(),te=null,c.value=vj,de=!1,ae=!1),n()}}};function me(e){return e.reduce((e,t)=>e.then(()=>T(t)),Promise.resolve())}return pe}var SM=N({__name:`App`,setup(e){return(e,t)=>(F(),Ca(k(VT),{theme:k(xA)},{default:j(()=>[R(k(QE),null,{default:j(()=>[R(k(bM))]),_:1})]),_:1},8,[`theme`]))}});function CM(e){return{Ping(t){let n=[],r=`api/test/ping`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`Ping`})},Echo(t){let n=[];t.text&&n.push(`text=${encodeURIComponent(t.text.toString())}`);let r=`api/test/echo`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`POST`,body:null},{service:`EveningDetectiveServer`,method:`Echo`})},Signup(t){let n=JSON.stringify(t),r=[],i=`api/auth/signup`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`Signup`})},RefreshPassword(t){let n=JSON.stringify(t),r=[],i=`api/auth/refresh-password`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`RefreshPassword`})},Login(t){let n=JSON.stringify(t),r=[],i=`api/auth/login`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`Login`})},Refresh(t){let n=JSON.stringify(t),r=[],i=`api/auth/refresh`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`Refresh`})},GetUsers(t){let n=[],r=`api/users`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetUsers`})},GetUserById(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/users/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetUserById`})},GetMe(t){let n=[],r=`api/users/me`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetMe`})},AddUserRole(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/users/${t.id}/role/add`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`AddUserRole`})},DeleteUserRole(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/users/${t.id}/role/delete`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`DeleteUserRole`})},GetPermissions(t){let n=[],r=`api/ui/permissions`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetPermissions`})},UploadFile(t){let n=JSON.stringify(t),r=[],i=`api/files/upload`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`UploadFile`})},DownloadFile(t){if(!t.filename)throw Error(`missing required field request.filename`);let n=`api/files/${t.filename}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`DownloadFile`})},AddScenario(t){let n=JSON.stringify(t),r=[],i=`api/scenario`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`AddScenario`})},GetMyScenarios(t){let n=[],r=`api/my-scenarios`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetMyScenarios`})},GetScenariosCatalog(t){let n=[],r=`api/catalog`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetScenariosCatalog`})},GetFullScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}/full`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetFullScenario`})},GetScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetScenario`})},UpdateScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`UpdateScenario`})},PublicScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}/public`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`PublicScenario`})},DraftScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}/draft`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`DraftScenario`})},DeleteScenario(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteScenario`})},AddScenarioPlace(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/scenarios/${t.id}/places`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`AddScenarioPlace`})},UpdateScenarioPlace(t){if(!t.id)throw Error(`missing required field request.id`);if(!t.code)throw Error(`missing required field request.code`);let n=`api/scenarios/${t.id}/places/${t.code}`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`UpdateScenarioPlace`})},DeleteScenarioPlace(t){if(!t.id)throw Error(`missing required field request.id`);if(!t.code)throw Error(`missing required field request.code`);let n=`api/scenarios/${t.id}/places/${t.code}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteScenarioPlace`})},AddGame(t){let n=JSON.stringify(t),r=[],i=`api/games`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`AddGame`})},GetGames(t){let n=[],r=`api/games`;return n.length>0&&(r+=`?${n.join(`&`)}`),e({path:r,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetGames`})},GetGame(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/games/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetGame`})},UpdateGame(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/games/${t.id}`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`UpdateGame`})},DeleteGame(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/games/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteGame`})},AddTeam(t){let n=JSON.stringify(t),r=[],i=`api/teams`;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`POST`,body:n},{service:`EveningDetectiveServer`,method:`AddTeam`})},UpdateTeam(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`PUT`,body:r},{service:`EveningDetectiveServer`,method:`UpdateTeam`})},DeleteTeam(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteTeam`})},GiveTeamApplications(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}/applications`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`GiveTeamApplications`})},GetTeamStory(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}/story`,r=[];t.password&&r.push(`password=${encodeURIComponent(t.password.toString())}`);let i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`GET`,body:null},{service:`EveningDetectiveServer`,method:`GetTeamStory`})},AddTeamAction(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}/actions`,r=JSON.stringify(t),i=[],a=n;return i.length>0&&(a+=`?${i.join(`&`)}`),e({path:a,method:`POST`,body:r},{service:`EveningDetectiveServer`,method:`AddTeamAction`})},DeleteLastTeamAction(t){if(!t.id)throw Error(`missing required field request.id`);let n=`api/teams/${t.id}/last-actions`,r=[],i=n;return r.length>0&&(i+=`?${r.join(`&`)}`),e({path:i,method:`DELETE`,body:null},{service:`EveningDetectiveServer`,method:`DeleteLastTeamAction`})}}}function wM(e){return CM(TM(e))}function TM(e){return async t=>{let n=`${EM()}/${t.path}`,r={"Content-Type":`application/json`},i=e?.();i&&(r.Authorization=`Bearer ${i}`);let a=await fetch(n,{method:t.method,headers:r,body:t.body});if(a.status==401)throw Error(`unauthorized`);return await a.json()}}function EM(){return`https://evening-detective.crabs-games.art`}var DM=fc(`auth`,()=>{let e=O(null),t=O(null),n=O(null),r=O(!1),i=O(null),a=B(()=>!!e.value),o=B(()=>n.value?.username||``),s=B(()=>n.value?.roles||[]);function c(){let n=localStorage.getItem(`accessToken`),r=localStorage.getItem(`refreshToken`);n&&(e.value=n,t.value=r,u())}function l(){return e.value}async function u(){if(e.value)try{let e=await wM(l).GetMe({});if(e.error){i.value=e.error;return}e.user&&(n.value=e.user)}catch(e){console.error(`Failed to fetch user:`,e),e instanceof Error&&e.message.includes(`401`)&&await h()}}async function d(n,a){r.value=!0,i.value=null;try{let r=await wM(l).Login({email:n,password:a});return r.error?(i.value=r.error,!1):r.accessToken?(e.value=r.accessToken,t.value=r.refreshToken||null,localStorage.setItem(`accessToken`,r.accessToken),r.refreshToken&&localStorage.setItem(`refreshToken`,r.refreshToken),await u(),!0):!1}catch(e){return i.value=e instanceof Error?e.message:`Login failed`,!1}finally{r.value=!1}}async function f(){if(!t.value)return!1;try{let n=await wM(l).Refresh({refreshToken:t.value});return n.error||!n.accessToken?!1:(e.value=n.accessToken,t.value=n.refreshToken||null,localStorage.setItem(`accessToken`,n.accessToken),n.refreshToken&&localStorage.setItem(`refreshToken`,n.refreshToken),!0)}catch{return!1}}async function p(e,t){r.value=!0,i.value=null;try{let n=await wM(l).Signup({username:e,email:t});return n.error?(i.value=n.error,!1):!0}catch(e){return i.value=e instanceof Error?e.message:`Signup failed`,!1}finally{r.value=!1}}async function m(e){r.value=!0,i.value=null;try{let t=await wM(l).RefreshPassword({email:e});return t.error?(i.value=t.error,!1):!0}catch(e){return i.value=e instanceof Error?e.message:`Password reset failed`,!1}finally{r.value=!1}}async function h(){e.value=null,t.value=null,n.value=null,i.value=null,localStorage.removeItem(`accessToken`),localStorage.removeItem(`refreshToken`)}function g(e){return s.value.includes(e)}function _(e){return e.some(e=>s.value.includes(e))}return{accessToken:e,refreshToken:t,user:n,isLoading:r,error:i,isAuthenticated:a,username:o,userRoles:s,initFromStorage:c,getToken:l,login:d,signup:p,refreshPassword:m,logout:h,fetchUser:u,refreshTokenAction:f,hasRole:g,hasAnyRole:_}});function OM(){let e=DM();return kM(e.refreshTokenAction,e.getToken)}function kM(e,t){return CM(AM(e,TM(t)))}function AM(e,t){return async n=>{try{return await t(n)}catch{return await e(),await t(n)}}}var jM={xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,viewBox:`0 0 24 24`},MM=N({name:`LockOutlined`,render:function(e,t){return F(),I(`svg`,jM,t[0]||=[L(`path`,{d:`M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zM9 6c0-1.66 1.34-3 3-3s3 1.34 3 3v2H9V6zm9 14H6V10h12v10zm-6-3c1.1 0 2-.9 2-2s-.9-2-2-2s-2 .9-2 2s.9 2 2 2z`,fill:`currentColor`},null,-1)])}}),NM={xmlns:`http://www.w3.org/2000/svg`,"xmlns:xlink":`http://www.w3.org/1999/xlink`,viewBox:`0 0 24 24`},PM=N({name:`MenuOutlined`,render:function(e,t){return F(),I(`svg`,NM,t[0]||=[L(`path`,{d:`M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z`,fill:`currentColor`},null,-1)])}});function FM(e){let t=0;for(let n=0;n{let r=FM(t);if(!r){e.forEach(e=>{n.push((e&&e+` `)+t)});return}else if(r===1){e.forEach(e=>{n.push(t.replace(`&`,e))});return}let i=[t];for(;r--;){let t=[];i.forEach(n=>{e.forEach(e=>{t.push(n.replace(`&`,e))})}),i=t}i.forEach(e=>n.push(e))}),n}function zM(e,t){let n=[];return t.split(IM).forEach(t=>{e.forEach(e=>{n.push((e&&e+` `)+t)})}),n}function BM(e){let t=[``];return e.forEach(e=>{e&&=e.trim(),e&&(t=e.includes(`&`)?RM(t,e):zM(t,e))}),t.join(`, `).replace(LM,` `)}var VM=/[A-Z]/g;function HM(e){return e.replace(VM,e=>`-`+e.toLowerCase())}function UM(e,t=` `){return typeof e==`object`&&e?` { `+Object.entries(e).map(e=>t+` ${HM(e[0])}: ${e[1]};`).join(` `)+` `+t+`}`:`: ${e};`}function WM(e,t,n){return typeof e==`function`?e({context:t.context,props:n}):e}function GM(e,t,n,r){if(!t)return``;let i=WM(t,n,r);if(!i)return``;if(typeof i==`string`)return`${e} {\n${i}\n}`;let a=Object.keys(i);if(a.length===0)return n.config.keepEmptyBlock?e+` { diff --git a/dist/index.html b/dist/index.html index f80c499..adfadd0 100644 --- a/dist/index.html +++ b/dist/index.html @@ -5,7 +5,7 @@ Вечерний детектив - +