var OK=Object.defineProperty,DK=Object.defineProperties;var _K=Object.getOwnPropertyDescriptors;var DH=Object.getOwnPropertySymbols;var MK=Object.prototype.hasOwnProperty,BK=Object.prototype.propertyIsEnumerable;var hy=Math.pow,_H=(D,y,C)=>y in D?OK(D,y,{enumerable:!0,configurable:!0,writable:!0,value:C}):D[y]=C,Ci=(D,y)=>{for(var C in y||(y={}))MK.call(y,C)&&_H(D,C,y[C]);if(DH)for(var C of DH(y))BK.call(y,C)&&_H(D,C,y[C]);return D},Ic=(D,y)=>DK(D,_K(y));var zc=(D,y,C)=>new Promise((S,_)=>{var M=Y=>{try{K(C.next(Y))}catch(ye){_(ye)}},z=Y=>{try{K(C.throw(Y))}catch(ye){_(ye)}},K=Y=>Y.done?S(Y.value):Promise.resolve(Y.value).then(M,z);K((C=C.apply(D,y)).next())});import{u as ky,_ as PK}from"./RadioButtonGroup.vue_vue_type_script_setup_true_lang-RC179q1_.js";import{p as Fg,l as Rp,S as RK,aD as MH,k as Y$,K as a9,v as Co,aE as o9,aF as NK,_ as sM,aC as Np,aG as FK,h as i9,a8 as IK,e as zK,r as $K,a0 as LK,aH as HK}from"./entry/index-CT2bBVPU-1724922878694.js";import{z as Bd,at as VK,au as UK,aa as WK,o as lM,a as u9,e as Pi,av as _d,aw as oM,V as s9,ax as sk,ay as jK,az as l9,aA as c9,U as f9,B as qK,T as _g,aB as v9,a5 as GK,aC as nM,b as KK,c as xy,aD as XK,a6 as YK,W as ZK,aE as JK,a0 as QK,as as d9,aF as eX,aG as tX,aH as cM,aI as m9,al as nX}from"./antd-BY-1PcYE.js";import{f as Ea,c as ki,u as mn,d as Ls,h as vk,w as Nu,_ as Ha,a8 as ou,a9 as qa,ah as Bg,a2 as Xu,k as Fa,a0 as $s,$ as ms,F as Z$,ab as Fp,ac as Md,ad as pf,H as fM,G as Ng,a1 as Bp,ae as Ey,af as Ty,ak as dk,al as mk,K as cL,o as fL,aa as Mp,b as rX,m as g9,A as h9,j as aX,Q as oX,y as iX}from"./vue-aEZWZQSa.js";import{b as BH,I as uX,B as sX}from"./index-BRqXDmQx.js";import{c as lX}from"./copyTextToClipboard-BBFF3Y3I.js";import{a as cX,B as fX,u as vX}from"./index-COQSZY7c.js";import{o as dX}from"./onMountedOrActivated-BIJ0U1R1.js";import{r as mX}from"./style-Cslz80qp.js";const PH={prefix:"ant-design",icons:["account-book-filled","account-book-outlined","account-book-twotone","aim-outlined","alert-filled","alert-outlined","alert-twotone","alibaba-outlined","align-center-outlined","align-left-outlined","align-right-outlined","alipay-circle-filled","alipay-circle-outlined","alipay-outlined","alipay-square-filled","aliwangwang-filled","aliwangwang-outlined","aliyun-outlined","amazon-circle-filled","amazon-outlined","amazon-square-filled","android-filled","android-outlined","ant-cloud-outlined","ant-design-outlined","apartment-outlined","api-filled","api-outlined","api-twotone","apple-filled","apple-outlined","appstore-add-outlined","appstore-filled","appstore-outlined","appstore-twotone","area-chart-outlined","arrow-down-outlined","arrow-left-outlined","arrow-right-outlined","arrow-up-outlined","arrows-alt-outlined","audio-filled","audio-muted-outlined","audio-outlined","audio-twotone","audit-outlined","backward-filled","backward-outlined","bank-filled","bank-outlined","bank-twotone","bar-chart-outlined","barcode-outlined","bars-outlined","behance-circle-filled","behance-outlined","behance-square-filled","behance-square-outlined","bell-filled","bell-outlined","bell-twotone","bg-colors-outlined","block-outlined","bold-outlined","book-filled","book-outlined","book-twotone","border-bottom-outlined","border-horizontal-outlined","border-inner-outlined","border-left-outlined","border-outer-outlined","border-outlined","border-right-outlined","border-top-outlined","border-verticle-outlined","borderless-table-outlined","box-plot-filled","box-plot-outlined","box-plot-twotone","branches-outlined","bug-filled","bug-outlined","bug-twotone","build-filled","build-outlined","build-twotone","bulb-filled","bulb-outlined","bulb-twotone","calculator-filled","calculator-outlined","calculator-twotone","calendar-filled","calendar-outlined","calendar-twotone","camera-filled","camera-outlined","camera-twotone","car-filled","car-outlined","car-twotone","caret-down-filled","caret-down-outlined","caret-left-filled","caret-left-outlined","caret-right-filled","caret-right-outlined","caret-up-filled","caret-up-outlined","carry-out-filled","carry-out-outlined","carry-out-twotone","check-circle-filled","check-circle-outlined","check-circle-twotone","check-outlined","check-square-filled","check-square-outlined","check-square-twotone","chrome-filled","chrome-outlined","ci-circle-filled","ci-circle-outlined","ci-circle-twotone","ci-outlined","ci-twotone","clear-outlined","clock-circle-filled","clock-circle-outlined","clock-circle-twotone","close-circle-filled","close-circle-outlined","close-circle-twotone","close-outlined","close-square-filled","close-square-outlined","close-square-twotone","cloud-download-outlined","cloud-filled","cloud-outlined","cloud-server-outlined","cloud-sync-outlined","cloud-twotone","cloud-upload-outlined","cluster-outlined","code-filled","code-outlined","code-sandbox-circle-filled","code-sandbox-outlined","code-sandbox-square-filled","code-twotone","codepen-circle-filled","codepen-circle-outlined","codepen-outlined","codepen-square-filled","coffee-outlined","column-height-outlined","column-width-outlined","comment-outlined","compass-filled","compass-outlined","compass-twotone","compress-outlined","console-sql-outlined","contacts-filled","contacts-outlined","contacts-twotone","container-filled","container-outlined","container-twotone","control-filled","control-outlined","control-twotone","copy-filled","copy-outlined","copy-twotone","copyright-circle-filled","copyright-circle-outlined","copyright-circle-twotone","copyright-outlined","copyright-twotone","credit-card-filled","credit-card-outlined","credit-card-twotone","crown-filled","crown-outlined","crown-twotone","customer-service-filled","customer-service-outlined","customer-service-twotone","dash-outlined","dashboard-filled","dashboard-outlined","dashboard-twotone","database-filled","database-outlined","database-twotone","delete-column-outlined","delete-filled","delete-outlined","delete-row-outlined","delete-twotone","delivered-procedure-outlined","deployment-unit-outlined","desktop-outlined","diff-filled","diff-outlined","diff-twotone","dingding-outlined","dingtalk-circle-filled","dingtalk-outlined","dingtalk-square-filled","disconnect-outlined","dislike-filled","dislike-outlined","dislike-twotone","dollar-circle-filled","dollar-circle-outlined","dollar-circle-twotone","dollar-outlined","dollar-twotone","dot-chart-outlined","double-left-outlined","double-right-outlined","down-circle-filled","down-circle-outlined","down-circle-twotone","down-outlined","down-square-filled","down-square-outlined","down-square-twotone","download-outlined","drag-outlined","dribbble-circle-filled","dribbble-outlined","dribbble-square-filled","dribbble-square-outlined","dropbox-circle-filled","dropbox-outlined","dropbox-square-filled","edit-filled","edit-outlined","edit-twotone","ellipsis-outlined","enter-outlined","environment-filled","environment-outlined","environment-twotone","euro-circle-filled","euro-circle-outlined","euro-circle-twotone","euro-outlined","euro-twotone","exception-outlined","exclamation-circle-filled","exclamation-circle-outlined","exclamation-circle-twotone","exclamation-outlined","expand-alt-outlined","expand-outlined","experiment-filled","experiment-outlined","experiment-twotone","export-outlined","eye-filled","eye-invisible-filled","eye-invisible-outlined","eye-invisible-twotone","eye-outlined","eye-twotone","facebook-filled","facebook-outlined","fall-outlined","fast-backward-filled","fast-backward-outlined","fast-forward-filled","fast-forward-outlined","field-binary-outlined","field-number-outlined","field-string-outlined","field-time-outlined","file-add-filled","file-add-outlined","file-add-twotone","file-done-outlined","file-excel-filled","file-excel-outlined","file-excel-twotone","file-exclamation-filled","file-exclamation-outlined","file-exclamation-twotone","file-filled","file-gif-outlined","file-image-filled","file-image-outlined","file-image-twotone","file-jpg-outlined","file-markdown-filled","file-markdown-outlined","file-markdown-twotone","file-outlined","file-pdf-filled","file-pdf-outlined","file-pdf-twotone","file-ppt-filled","file-ppt-outlined","file-ppt-twotone","file-protect-outlined","file-search-outlined","file-sync-outlined","file-text-filled","file-text-outlined","file-text-twotone","file-twotone","file-unknown-filled","file-unknown-outlined","file-unknown-twotone","file-word-filled","file-word-outlined","file-word-twotone","file-zip-filled","file-zip-outlined","file-zip-twotone","filter-filled","filter-outlined","filter-twotone","fire-filled","fire-outlined","fire-twotone","flag-filled","flag-outlined","flag-twotone","folder-add-filled","folder-add-outlined","folder-add-twotone","folder-filled","folder-open-filled","folder-open-outlined","folder-open-twotone","folder-outlined","folder-twotone","folder-view-outlined","font-colors-outlined","font-size-outlined","fork-outlined","form-outlined","format-painter-filled","format-painter-outlined","forward-filled","forward-outlined","frown-filled","frown-outlined","frown-twotone","fullscreen-exit-outlined","fullscreen-outlined","function-outlined","fund-filled","fund-outlined","fund-projection-screen-outlined","fund-twotone","fund-view-outlined","funnel-plot-filled","funnel-plot-outlined","funnel-plot-twotone","gateway-outlined","gif-outlined","gift-filled","gift-outlined","gift-twotone","github-filled","github-outlined","gitlab-filled","gitlab-outlined","global-outlined","gold-filled","gold-outlined","gold-twotone","golden-filled","google-circle-filled","google-outlined","google-plus-circle-filled","google-plus-outlined","google-plus-square-filled","google-square-filled","group-outlined","hdd-filled","hdd-outlined","hdd-twotone","heart-filled","heart-outlined","heart-twotone","heat-map-outlined","highlight-filled","highlight-outlined","highlight-twotone","history-outlined","home-filled","home-outlined","home-twotone","hourglass-filled","hourglass-outlined","hourglass-twotone","html5-filled","html5-outlined","html5-twotone","idcard-filled","idcard-outlined","idcard-twotone","ie-circle-filled","ie-outlined","ie-square-filled","import-outlined","inbox-outlined","info-circle-filled","info-circle-outlined","info-circle-twotone","info-outlined","insert-row-above-outlined","insert-row-below-outlined","insert-row-left-outlined","insert-row-right-outlined","instagram-filled","instagram-outlined","insurance-filled","insurance-outlined","insurance-twotone","interaction-filled","interaction-outlined","interaction-twotone","issues-close-outlined","italic-outlined","key-outlined","laptop-outlined","layout-filled","layout-outlined","layout-twotone","left-circle-filled","left-circle-outlined","left-circle-twotone","left-outlined","left-square-filled","left-square-outlined","left-square-twotone","like-filled","like-outlined","like-twotone","line-chart-outlined","line-height-outlined","line-outlined","link-outlined","linkedin-filled","linkedin-outlined","loading-3-quarters-outlined","loading-outlined","lock-filled","lock-outlined","lock-twotone","login-outlined","logout-outlined","mac-command-filled","mac-command-outlined","mail-filled","mail-outlined","mail-twotone","man-outlined","medicine-box-filled","medicine-box-outlined","medicine-box-twotone","medium-circle-filled","medium-outlined","medium-square-filled","medium-workmark-outlined","meh-filled","meh-outlined","meh-twotone","menu-fold-outlined","menu-outlined","menu-unfold-outlined","merge-cells-outlined","message-filled","message-outlined","message-twotone","minus-circle-filled","minus-circle-outlined","minus-circle-twotone","minus-outlined","minus-square-filled","minus-square-outlined","minus-square-twotone","mobile-filled","mobile-outlined","mobile-twotone","money-collect-filled","money-collect-outlined","money-collect-twotone","monitor-outlined","more-outlined","node-collapse-outlined","node-expand-outlined","node-index-outlined","notification-filled","notification-outlined","notification-twotone","number-outlined","one-to-one-outlined","ordered-list-outlined","paper-clip-outlined","partition-outlined","pause-circle-filled","pause-circle-outlined","pause-circle-twotone","pause-outlined","pay-circle-filled","pay-circle-outlined","percentage-outlined","phone-filled","phone-outlined","phone-twotone","pic-center-outlined","pic-left-outlined","pic-right-outlined","picture-filled","picture-outlined","picture-twotone","pie-chart-filled","pie-chart-outlined","pie-chart-twotone","play-circle-filled","play-circle-outlined","play-circle-twotone","play-square-filled","play-square-outlined","play-square-twotone","plus-circle-filled","plus-circle-outlined","plus-circle-twotone","plus-outlined","plus-square-filled","plus-square-outlined","plus-square-twotone","pound-circle-filled","pound-circle-outlined","pound-circle-twotone","pound-outlined","poweroff-outlined","printer-filled","printer-outlined","printer-twotone","profile-filled","profile-outlined","profile-twotone","project-filled","project-outlined","project-twotone","property-safety-filled","property-safety-outlined","property-safety-twotone","pull-request-outlined","pushpin-filled","pushpin-outlined","pushpin-twotone","qq-circle-filled","qq-outlined","qq-square-filled","qrcode-outlined","question-circle-filled","question-circle-outlined","question-circle-twotone","question-outlined","radar-chart-outlined","radius-bottomleft-outlined","radius-bottomright-outlined","radius-setting-outlined","radius-upleft-outlined","radius-upright-outlined","read-filled","read-outlined","reconciliation-filled","reconciliation-outlined","reconciliation-twotone","red-envelope-filled","red-envelope-outlined","red-envelope-twotone","reddit-circle-filled","reddit-outlined","reddit-square-filled","redo-outlined","reload-outlined","rest-filled","rest-outlined","rest-twotone","retweet-outlined","right-circle-filled","right-circle-outlined","right-circle-twotone","right-outlined","right-square-filled","right-square-outlined","right-square-twotone","rise-outlined","robot-filled","robot-outlined","rocket-filled","rocket-outlined","rocket-twotone","rollback-outlined","rotate-left-outlined","rotate-right-outlined","safety-certificate-filled","safety-certificate-outlined","safety-certificate-twotone","safety-outlined","save-filled","save-outlined","save-twotone","scan-outlined","schedule-filled","schedule-outlined","schedule-twotone","scissor-outlined","search-outlined","security-scan-filled","security-scan-outlined","security-scan-twotone","select-outlined","send-outlined","setting-filled","setting-outlined","setting-twotone","shake-outlined","share-alt-outlined","shop-filled","shop-outlined","shop-twotone","shopping-cart-outlined","shopping-filled","shopping-outlined","shopping-twotone","shrink-outlined","signal-filled","sisternode-outlined","sketch-circle-filled","sketch-outlined","sketch-square-filled","skin-filled","skin-outlined","skin-twotone","skype-filled","skype-outlined","slack-circle-filled","slack-outlined","slack-square-filled","slack-square-outlined","sliders-filled","sliders-outlined","sliders-twotone","small-dash-outlined","smile-filled","smile-outlined","smile-twotone","snippets-filled","snippets-outlined","snippets-twotone","solution-outlined","sort-ascending-outlined","sort-descending-outlined","sound-filled","sound-outlined","sound-twotone","split-cells-outlined","star-filled","star-outlined","star-twotone","step-backward-filled","step-backward-outlined","step-forward-filled","step-forward-outlined","stock-outlined","stop-filled","stop-outlined","stop-twotone","strikethrough-outlined","subnode-outlined","swap-left-outlined","swap-outlined","swap-right-outlined","switcher-filled","switcher-outlined","switcher-twotone","sync-outlined","table-outlined","tablet-filled","tablet-outlined","tablet-twotone","tag-filled","tag-outlined","tag-twotone","tags-filled","tags-outlined","tags-twotone","taobao-circle-filled","taobao-circle-outlined","taobao-outlined","taobao-square-filled","team-outlined","thunderbolt-filled","thunderbolt-outlined","thunderbolt-twotone","to-top-outlined","tool-filled","tool-outlined","tool-twotone","trademark-circle-filled","trademark-circle-outlined","trademark-circle-twotone","trademark-outlined","transaction-outlined","translation-outlined","trophy-filled","trophy-outlined","trophy-twotone","twitter-circle-filled","twitter-outlined","twitter-square-filled","underline-outlined","undo-outlined","ungroup-outlined","unlock-filled","unlock-outlined","unlock-twotone","unordered-list-outlined","up-circle-filled","up-circle-outlined","up-circle-twotone","up-outlined","up-square-filled","up-square-outlined","up-square-twotone","upload-outlined","usb-filled","usb-outlined","usb-twotone","user-add-outlined","user-delete-outlined","user-outlined","user-switch-outlined","usergroup-add-outlined","usergroup-delete-outlined","verified-outlined","vertical-align-bottom-outlined","vertical-align-middle-outlined","vertical-align-top-outlined","vertical-left-outlined","vertical-right-outlined","video-camera-add-outlined","video-camera-filled","video-camera-outlined","video-camera-twotone","wallet-filled","wallet-outlined","wallet-twotone","warning-filled","warning-outlined","warning-twotone","wechat-filled","wechat-outlined","weibo-circle-filled","weibo-circle-outlined","weibo-outlined","weibo-square-filled","weibo-square-outlined","whats-app-outlined","wifi-outlined","windows-filled","windows-outlined","woman-outlined","yahoo-filled","yahoo-outlined","youtube-filled","youtube-outlined","yuque-filled","yuque-outlined","zhihu-circle-filled","zhihu-outlined","zhihu-square-filled","zoom-in-outlined","zoom-out-outlined"]};function gX(D,y,C){const S=(y-1)*Number(C);return S+Number(C)>=D.length?D.slice(S,D.length):D.slice(S,S+Number(C))}function hX(D,y){const C=Ea(1),S=Ea(y),_=ki(()=>gX(mn(D),mn(C),mn(S))),M=ki(()=>mn(D).length);function z(Y){C.value=Y}function K(Y){S.value=Y}return{setCurrentPage:z,getTotal:M,setPageSize:K,getPaginationList:_}}const pX=["icon-download-count","icon-dynamic-avatar-1","icon-dynamic-avatar-2","icon-dynamic-avatar-3","icon-dynamic-avatar-4","icon-dynamic-avatar-5","icon-dynamic-avatar-6","icon-moon","icon-sun","icon-test","icon-total-sales","icon-transaction","icon-visit-count"],bX={class:"flex justify-between"},yX={key:0},wX={class:"flex flex-wrap px-2"},CX=["onClick","title"],xX={key:0,class:"flex py-2 items-center justify-center"},SX={key:1,class:"p-5"},kX={key:0,class:"cursor-pointer px-2 py-1 flex items-center"},EX=Ls({inheritAttrs:!1,__name:"IconPicker",props:{value:{default:""},width:{default:"100%"},pageSize:{default:140},copy:{type:Boolean,default:!1},mode:{default:"iconify"},allowClear:{type:Boolean,default:!0},readonly:{type:Boolean,default:!1}},emits:["change","update:value"],setup(D,{emit:y}){function C(){const Be=PH.prefix;return PH.icons.map(gt=>`${Be}:${gt}`)}function S(){return pX.map(Be=>Be.replace("icon-",""))}const _=D,M=y,z=_.mode==="svg",K=z?S():C(),Y=Ea(""),ye=Ea(!1),Q=Ea(K),W=Ea(),ve=()=>{W.value&&W.value.click()},{t:he}=Rp(),{prefixCls:be}=Fg("icon-picker"),ae=a9(Te,100),{getPaginationList:Ae,getTotal:Ye,setCurrentPage:Ve}=hX(Q,_.pageSize);vk(()=>{Y.value=_.value}),Nu(()=>Y.value,Be=>{M("update:value",Be),M("change",Be)});function L(Be){Ve(Be)}function _e(Be){Y.value=Be,_.copy&&lX(Be,he("component.icon.copy"))}function Te(Be){const gt=Be.target.value;if(!gt){Ve(1),Q.value=K;return}Q.value=K.filter(Se=>Se.includes(gt))}return(Be,gt)=>(Ha(),ou(mn(Bd),{style:Bg({width:Be.width}),placeholder:mn(he)("component.icon.placeholder"),class:Xu(mn(be)),value:Y.value,"onUpdate:value":gt[1]||(gt[1]=Se=>Y.value=Se),onClick:ve,allowClear:_.allowClear,readonly:_.readonly},{addonAfter:qa(()=>[Fa(mn(WK),{placement:"bottomLeft",trigger:"click",modelValue:ye.value,"onUpdate:modelValue":gt[0]||(gt[0]=Se=>ye.value=Se),overlayClassName:`${mn(be)}-popover`},{title:qa(()=>[$s("div",bX,[Fa(mn(Bd),{placeholder:mn(he)("component.icon.search"),onChange:mn(ae),allowClear:""},null,8,["placeholder","onChange"])])]),content:qa(()=>[mn(Ae).length?(Ha(),ms("div",yX,[Fa(mn(RK),{class:"border border-solid border-t-0"},{default:qa(()=>[$s("ul",wX,[(Ha(!0),ms(Z$,null,Fp(mn(Ae),Se=>(Ha(),ms("li",{key:Se,class:Xu([Y.value===Se?"border border-primary":"","p-2 w-1/8 cursor-pointer mr-1 mt-1 flex justify-center items-center border border-solid hover:border-primary"]),onClick:je=>_e(Se),title:Se},[z?(Ha(),ou(MH,{key:0,name:Se},null,8,["name"])):(Ha(),ou(Y$,{key:1,icon:Se},null,8,["icon"]))],10,CX))),128))])]),_:1}),mn(Ye)>=Be.pageSize?(Ha(),ms("div",xX,[Fa(mn(VK),{showLessItems:"",size:"small",pageSize:Be.pageSize,total:mn(Ye),onChange:L},null,8,["pageSize","total"])])):Md("",!0)])):(Ha(),ms("div",SX,[Fa(mn(UK))]))]),default:qa(()=>[$s("div",{ref_key:"trigger",ref:W},[z&&Y.value?(Ha(),ms("span",kX,[Fa(MH,{name:Y.value},null,8,["name"])])):(Ha(),ou(Y$,{key:1,icon:Y.value||"ion:apps-outline",class:"cursor-pointer px-2 py-1"},null,8,["icon"]))],512)]),_:1},8,["modelValue","overlayClassName"])]),_:1},8,["style","placeholder","class","value","allowClear","readonly"]))}}),TX=Ls({name:"ApiRadioGroup",__name:"ApiRadioGroup",props:{api:{type:Function,default:null},params:{type:[Object,String],default:()=>({})},value:{type:[String,Number,Boolean]},isBtn:{type:[Boolean],default:!1},numberToString:Co.bool,resultField:Co.string.def(""),labelField:Co.string.def("label"),valueField:Co.string.def("value"),immediate:Co.bool.def(!0),beforeFetch:{type:Function,default:null},afterFetch:{type:Function,default:null}},emits:["options-change","change","update:value"],setup(D,{emit:y}){const C=D,S=y,_=Ea([]),M=Ea(!1),z=Ea([]),K=o9(),[Y]=ky(C,"value","change",z),ye=ki(()=>{const{labelField:he,valueField:be,numberToString:ae}=C;return mn(_).reduce((Ae,Ye)=>{if(Ye){const Ve=Ye[be];Ae.push(Ci({label:Ye[he],value:ae?`${Ve}`:Ve},lM(Ye,[he,be])))}return Ae},[])});Nu(()=>C.params,(he,be)=>{u9(he,be)||Q()},{deep:!0,immediate:C.immediate});function Q(){return zc(this,null,function*(){let{api:he,beforeFetch:be,afterFetch:ae,params:Ae,resultField:Ye}=C;if(!(!he||!Pi(he))){_.value=[];try{M.value=!0,be&&Pi(be)&&(Ae=(yield be(Ae))||Ae);let Ve=yield he(Ae);if(ae&&Pi(ae)&&(Ve=(yield ae(Ve))||Ve),Array.isArray(Ve)){_.value=Ve,W();return}Ye&&(_.value=_d(Ve,Ye)||[]),W()}catch(Ve){}finally{M.value=!1}}})}function W(){S("options-change",mn(ye))}function ve(...he){z.value=he}return(he,be)=>(Ha(),ou(mn(oM).Group,pf(mn(K),{value:mn(Y),"onUpdate:value":be[0]||(be[0]=ae=>fM(Y)?Y.value=ae:null),"button-style":"solid"}),{default:qa(()=>[(Ha(!0),ms(Z$,null,Fp(ye.value,ae=>(Ha(),ms(Z$,{key:`${ae.value}`},[C.isBtn?(Ha(),ou(mn(oM).Button,{key:0,value:ae.value,disabled:ae.disabled,onClick:Ae=>ve(ae)},{default:qa(()=>[Ng(Bp(ae.label),1)]),_:2},1032,["value","disabled","onClick"])):(Ha(),ou(mn(oM),{key:1,value:ae.value,disabled:ae.disabled,onClick:Ae=>ve(ae)},{default:qa(()=>[Ng(Bp(ae.label),1)]),_:2},1032,["value","disabled","onClick"]))],64))),128))]),_:1},16,["value"]))}}),AX=Ls({name:"ApiSelect",inheritAttrs:!1,__name:"ApiSelect",props:{value:{type:[Array,Object,String,Number]},numberToString:Co.bool,api:{type:Function,default:null},params:Co.any.def({}),resultField:Co.string.def(""),labelField:Co.string.def("label"),valueField:Co.string.def("value"),immediate:Co.bool.def(!0),alwaysLoad:Co.bool.def(!1),options:{type:Array,default:[]},beforeFetch:{type:Function,default:null},afterFetch:{type:Function,default:null}},emits:["options-change","change","update:value"],setup(D,{emit:y}){const C=D,S=y,_=Ea([]),M=Ea(!1),z=Ea(!1),K=Ea([]),{t:Y}=Rp(),[ye]=ky(C,"value","change",K),Q=ki(()=>{const{labelField:ae,valueField:Ae,numberToString:Ye}=C;let Ve=mn(_).reduce((L,_e)=>{if(_e){const Te=_d(_e,Ae);L.push(Ic(Ci({},lM(_e,[ae,Ae])),{label:_d(_e,ae),value:Ye?`${Te}`:Te}))}return L},[]);return Ve.length>0?Ve:C.options});Nu(()=>ye.value,ae=>{S("update:value",ae)}),Nu(()=>C.params,(ae,Ae)=>{u9(ae,Ae)||W()},{deep:!0,immediate:C.immediate});function W(){return zc(this,null,function*(){let{api:ae,beforeFetch:Ae,afterFetch:Ye,params:Ve,resultField:L}=C;if(!(!ae||!Pi(ae)||M.value)){_.value=[];try{M.value=!0,Ae&&Pi(Ae)&&(Ve=(yield Ae(Ve))||Ve);let _e=yield ae(Ve);if(Ye&&Pi(Ye)&&(_e=(yield Ye(_e))||_e),z.value=!0,Array.isArray(_e)){_.value=_e,he();return}L&&(_.value=_d(_e,L)||[]),he()}catch(_e){z.value=!1}finally{M.value=!1}}})}function ve(ae){return zc(this,null,function*(){ae&&(C.alwaysLoad?yield W():!C.immediate&&!mn(z)&&(yield W()))})}function he(){S("options-change",mn(Q))}function be(ae,...Ae){K.value=Ae}return(ae,Ae)=>(Ha(),ou(mn(s9),pf({onDropdownVisibleChange:ve},ae.$attrs,{onChange:be,options:Q.value,value:mn(ye),"onUpdate:value":Ae[0]||(Ae[0]=Ye=>fM(ye)?ye.value=Ye:null)}),Ey({_:2},[Fp(Object.keys(ae.$slots),Ye=>({name:Ye,fn:qa(Ve=>[Ty(ae.$slots,Ye,dk(mk(Ve||{})))])})),M.value?{name:"suffixIcon",fn:qa(()=>[Fa(mn(sk),{spin:""})]),key:"0"}:void 0,M.value?{name:"notFoundContent",fn:qa(()=>[$s("span",null,[Fa(mn(sk),{spin:"",class:"mr-1"}),Ng(" "+Bp(mn(Y)("component.form.apiSelectNotFound")),1)])]),key:"1"}:void 0]),1040,["options","value"]))}}),OX=Ls({name:"ApiTree",__name:"ApiTree",props:{api:{type:Function},params:{type:Object},immediate:{type:Boolean,default:!0},resultField:{type:String,default:""},beforeFetch:{type:Function,default:null},afterFetch:{type:Function,default:null},value:{type:Array}},emits:["options-change","change","update:value"],setup(D,{emit:y}){const C=D,S=y,_=cL(),M=Ea([]),z=Ea(!1),K=Ea(!1),Y=Ea([]),[ye]=ky(C,"value","change",Y),Q=ki(()=>Ci(Ci({},C.api?{treeData:mn(M)}:{}),_));Nu(()=>ye.value,ve=>{S("update:value",ve)}),Nu(()=>C.params,()=>{!mn(z)&&W()},{deep:!0}),Nu(()=>C.immediate,ve=>{ve&&!z.value&&W()}),fL(()=>{C.immediate&&W()});function W(){return zc(this,null,function*(){let{api:ve,beforeFetch:he,afterFetch:be,params:ae,resultField:Ae}=C;if(!ve||!Pi(ve))return;K.value=!0,M.value=[];let Ye;try{he&&Pi(he)&&(ae=(yield he(ae))||ae),Ye=yield ve(ae),be&&Pi(be)&&(Ye=(yield be(Ye))||Ye)}catch(Ve){}K.value=!1,Ye&&(Ae&&(Ye=_d(Ye,Ae)||[]),M.value=Ye||[],z.value=!0,S("options-change",M.value))})}return(ve,he)=>(Ha(),ou(mn(jK),pf(Q.value,{selectedKeys:mn(ye),"onUpdate:selectedKeys":he[0]||(he[0]=be=>fM(ye)?ye.value=be:null)}),Ey({_:2},[Fp(Object.keys(ve.$slots),be=>({name:be,fn:qa(ae=>[Ty(ve.$slots,be,dk(mk(ae||{})))])}))]),1040,["selectedKeys"]))}}),DX=Ls({name:"ApiTreeSelect",__name:"ApiTreeSelect",props:{api:{type:Function},params:{type:Object},immediate:{type:Boolean,default:!0},async:{type:Boolean,default:!1},resultField:Co.string.def(""),labelField:Co.string.def("title"),valueField:Co.string.def("value"),childrenField:Co.string.def("children"),beforeFetch:{type:Function,default:null},afterFetch:{type:Function,default:null}},emits:["options-change","change","load-data"],setup(D,{emit:y}){const C=D,S=y,_=cL(),M=Ea([]),z=Ea(!1),K=Ea(!1),Y=ki(()=>Ci(Ci({},C.api?{treeData:mn(M)}:{}),_)),ye={children:C.childrenField,value:C.valueField,label:C.labelField};function Q(...he){S("change",...he)}Nu(()=>C.params,()=>{!mn(z)&&ve()},{deep:!0}),Nu(()=>C.immediate,he=>{he&&!z.value&&ve()}),fL(()=>{C.immediate&&ve()});function W(he){return new Promise(be=>{if(NK(he.children)&&he.children.length>0){be();return}S("load-data",{treeData:M,treeNode:he,resolve:be})})}function ve(){return zc(this,null,function*(){let{api:he,beforeFetch:be,afterFetch:ae,params:Ae,resultField:Ye}=C;if(!he||!Pi(he)||K.value)return;K.value=!0,M.value=[];let Ve;try{be&&Pi(be)&&(Ae=(yield be(Ae))||Ae),Ve=yield he(Ae),ae&&Pi(ae)&&(Ve=(yield ae(Ve))||Ve)}catch(L){}K.value=!1,Ve&&(Ye&&(Ve=_d(Ve,Ye)||[]),M.value=Ve||[],z.value=!0,S("options-change",M.value))})}return(he,be)=>(Ha(),ou(mn(l9),pf(Y.value,{onChange:Q,"field-names":ye,"load-data":D.async?W:void 0}),Ey({_:2},[Fp(Object.keys(he.$slots),ae=>({name:ae,fn:qa(Ae=>[Ty(he.$slots,ae,dk(mk(Ae||{})))])})),K.value?{name:"suffixIcon",fn:qa(()=>[Fa(mn(sk),{spin:""})]),key:"0"}:void 0]),1040,["load-data"]))}}),_X=Ls({name:"ApiCascader",__name:"ApiCascader",props:{value:{type:Array},api:{type:Function,default:null},numberToString:Co.bool,resultField:Co.string.def(""),labelField:Co.string.def("label"),valueField:Co.string.def("value"),childrenField:Co.string.def("children"),apiParamKey:Co.string.def("parentCode"),immediate:Co.bool.def(!0),initFetchParams:{type:Object,default:()=>({})},isLeaf:{type:Function,default:null},displayRenderArray:{type:Array},beforeFetch:{type:Function,default:null},afterFetch:{type:Function,default:null}},emits:["change","defaultChange"],setup(D,{emit:y}){const C=D,S=y,_=Ea([]),M=Ea([]),z=Ea(!1),K=Ea([]),Y=Ea(!0),{t:ye}=Rp(),[Q]=ky(C,"value","change",K);Nu(_,Ae=>{const Ye=W(Ae);M.value=Ye},{deep:!0});function W(Ae){const{labelField:Ye,valueField:Ve,numberToString:L,childrenField:_e,isLeaf:Te}=C;return Ae.reduce((Be,gt)=>{if(gt){const Se=gt[Ve],je=Ic(Ci({},lM(gt,[Ye,Ve])),{label:gt[Ye],value:L?`${Se}`:Se,isLeaf:Te&&typeof Te=="function"?Te(gt):!1}),Ze=Reflect.get(gt,_e);Ze&&Reflect.set(je,_e,W(Ze)),Be.push(je)}return Be},[])}function ve(){return zc(this,null,function*(){let{api:Ae,beforeFetch:Ye,initFetchParams:Ve,afterFetch:L,resultField:_e}=C;if(!(!Ae||!Pi(Ae))){_.value=[],z.value=!0;try{Ye&&Pi(Ye)&&(Ve=(yield Ye(Ve))||Ve);let Te=yield Ae(Ve);if(L&&Pi(L)&&(Te=(yield L(Te))||Te),Array.isArray(Te)){_.value=Te;return}_e&&(_.value=_d(Te,_e)||[])}catch(Te){}finally{z.value=!1}}})}const he=Ae=>zc(this,null,function*(){const Ye=Ae[Ae.length-1];Ye.loading=!0;let{api:Ve,beforeFetch:L,afterFetch:_e,resultField:Te,apiParamKey:Be}=C;if(!(!Ve||!Pi(Ve)))try{let gt={[Be]:Reflect.get(Ye,"value")};L&&Pi(L)&&(gt=(yield L(gt))||gt);let Se=yield Ve(gt);if(_e&&Pi(_e)&&(Se=(yield _e(Se))||Se),Array.isArray(Se)){const je=W(Se);Ye.children=je;return}if(Te){const je=W(_d(Se,Te)||[]);Ye.children=je}}catch(gt){}finally{Ye.loading=!1}});Nu(()=>C.immediate,()=>{C.immediate&&ve()},{immediate:!0}),Nu(()=>C.initFetchParams,()=>{!mn(Y)&&ve()},{deep:!0});function be(Ae,Ye){K.value=Ye,S("defaultChange",Ae,Ye)}const ae=({labels:Ae,selectedOptions:Ye})=>mn(K).length===(Ye==null?void 0:Ye.length)?Ae.join(" / "):C.displayRenderArray?C.displayRenderArray.join(" / "):"";return(Ae,Ye)=>(Ha(),ou(mn(c9),{value:mn(Q),"onUpdate:value":Ye[0]||(Ye[0]=Ve=>fM(Q)?Q.value=Ve:null),options:M.value,"load-data":he,"change-on-select":"",onChange:be,displayRender:ae},Ey({_:2},[z.value?{name:"suffixIcon",fn:qa(()=>[Fa(mn(sk),{spin:""})]),key:"0"}:void 0,z.value?{name:"notFoundContent",fn:qa(()=>[$s("span",null,[Fa(mn(sk),{spin:"",class:"mr-1"}),Ng(" "+Bp(mn(ye)("component.form.apiSelectNotFound")),1)])]),key:"1"}:void 0]),1032,["value","options"]))}}),MX=Ls({name:"ApiTransfer",__name:"ApiTransfer",props:{value:{type:Array},api:{type:Function,default:null},params:{type:Object},dataSource:{type:Array},immediate:Co.bool.def(!0),alwaysLoad:Co.bool.def(!1),beforeFetch:{type:Function,default:null},afterFetch:{type:Function,default:null},resultField:Co.string.def(""),labelField:Co.string.def("title"),valueField:Co.string.def("key"),showSearch:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},filterOption:{type:Function},selectedKeys:{type:Array},showSelectAll:{type:Boolean,default:!1},targetKeys:{type:Array}},emits:["options-change","change"],setup(D,{emit:y}){const C=D,S=y,_=Ea([]),M=Ea([]),z=ki(()=>{const{labelField:W,valueField:ve}=C;return mn(_).reduce((he,be)=>(be&&he.push(Ic(Ci({},lM(be,[W,ve])),{title:be[W],key:be[ve]})),he),[])}),K=ki(()=>Array.isArray(C.value)?C.value:Array.isArray(C.targetKeys)?C.targetKeys:[]);function Y(W,ve,he){M.value=W,S("change",W)}vk(()=>{C.immediate&&!C.alwaysLoad&&ye()}),Nu(()=>C.params,()=>{ye()},{deep:!0});function ye(){return zc(this,null,function*(){let{api:W,beforeFetch:ve,afterFetch:he,params:be,resultField:ae,dataSource:Ae}=C;if(!W||!Pi(W)){Array.isArray(Ae)&&(_.value=Ae);return}_.value=[];try{ve&&Pi(ve)&&(be=(yield ve(be))||be);let Ye=yield W(be);if(he&&Pi(he)&&(Ye=(yield he(Ye))||Ye),Array.isArray(Ye)){_.value=Ye,Q();return}ae&&(_.value=_d(Ye,ae)||[]),Q()}catch(Ye){}})}function Q(){S("options-change",mn(z))}return(W,ve)=>(Ha(),ou(mn(f9),{"data-source":z.value,"filter-option":D.filterOption,render:he=>he.title,showSelectAll:D.showSelectAll,selectedKeys:D.selectedKeys,targetKeys:K.value,showSearch:D.showSearch,disabled:D.disabled,onChange:Y},null,8,["data-source","filter-option","render","showSelectAll","selectedKeys","targetKeys","showSearch","disabled"]))}});function BX(D){const y=D.split(","),S=y[0].match(/:(.*?);/)[1],_=window.atob(y[1]);let M=_.length;const z=new Uint8Array(M);for(;M--;)z[M]=_.charCodeAt(M);return new Blob([z],{type:S})}const J$=(D,y)=>D.push.apply(D,y),Sy=D=>D.sort((y,C)=>y.i-C.i||y.j-C.j),RH=D=>{const y={};let C=1;return D.forEach(S=>{y[S]=C,C+=1}),y};var PX={4:[[1,2],[2,3]],5:[[1,3],[2,3],[2,4]],6:[[1,2],[2,4],[4,5]],7:[[1,3],[2,3],[4,5],[4,6]],8:[[2,4],[4,6]]};const NH=2050,FH=1e3,RX=PX,NX=10,FX=1e4,p9=10,b9=50,y9=20,w9=/^[A-Z\xbf-\xdf][^A-Z\xbf-\xdf]+$/,IX=/^[^A-Z\xbf-\xdf]+[A-Z\xbf-\xdf]$/,zX=/^[A-Z\xbf-\xdf]+$/,C9=/^[^a-z\xdf-\xff]+$/,$X=/^[a-z\xdf-\xff]+$/,LX=/^[^A-Z\xbf-\xdf]+$/,HX=/[a-z\xdf-\xff]/,VX=/[A-Z\xbf-\xdf]/,UX=/[^A-Za-z\xbf-\xdf]/gi,WX=/^\d+$/,vL=new Date().getFullYear(),jX={recentYear:/19\d\d|200\d|201\d|202\d/g},x9=[" ",",",";",":","|","/","\\","_",".","-"],qX=x9.length;class GX{match({password:y}){const C=[...this.getMatchesWithoutSeparator(y),...this.getMatchesWithSeparator(y)],S=this.filterNoise(C);return Sy(S)}getMatchesWithSeparator(y){const C=[],S=/^(\d{1,4})([\s/\\_.-])(\d{1,2})\2(\d{1,4})$/;for(let _=0;_<=Math.abs(y.length-6);_+=1)for(let M=_+5;M<=_+9&&!(M>=y.length);M+=1){const z=y.slice(_,+M+1||9e9),K=S.exec(z);if(K!=null){const Y=this.mapIntegersToDayMonthYear([parseInt(K[1],10),parseInt(K[3],10),parseInt(K[4],10)]);Y!=null&&C.push({pattern:"date",token:z,i:_,j:M,separator:K[2],year:Y.year,month:Y.month,day:Y.day})}}return C}getMatchesWithoutSeparator(y){const C=[],S=/^\d{4,8}$/,_=M=>Math.abs(M.year-vL);for(let M=0;M<=Math.abs(y.length-4);M+=1)for(let z=M+3;z<=M+7&&!(z>=y.length);z+=1){const K=y.slice(M,+z+1||9e9);if(S.exec(K)){const Y=[],ye=K.length;if(RX[ye].forEach(([W,ve])=>{const he=this.mapIntegersToDayMonthYear([parseInt(K.slice(0,W),10),parseInt(K.slice(W,ve),10),parseInt(K.slice(ve),10)]);he!=null&&Y.push(he)}),Y.length>0){let W=Y[0],ve=_(Y[0]);Y.slice(1).forEach(he=>{const be=_(he);be{let S=!1;const _=y.length;for(let M=0;M<_;M+=1){const z=y[M];if(C!==z&&z.i<=C.i&&z.j>=C.j){S=!0;break}}return!S})}mapIntegersToDayMonthYear(y){if(y[1]>31||y[1]<=0)return null;let C=0,S=0,_=0;for(let M=0,z=y.length;M99&&KNH)return null;K>31&&(S+=1),K>12&&(C+=1),K<=0&&(_+=1)}return S>=2||C===3||_>=2?null:this.getDayMonth(y)}getDayMonth(y){const C=[[y[2],y.slice(0,2)],[y[0],y.slice(1,3)]],S=C.length;for(let _=0;_=1&&M<=31&&z>=1&&z<=12)return{day:M,month:z}}return null}twoToFourDigitYear(y){return y>99?y:y>50?y+1900:y+2e3}}const Dd=new Uint32Array(65536),KX=(D,y)=>{const C=D.length,S=y.length,_=1<{const C=y.length,S=D.length,_=[],M=[],z=Math.ceil(C/32),K=Math.ceil(S/32);for(let be=0;be>>Ve&1,Te=_[Ve/32|0]>>>Ve&1,Be=L|be,gt=((L|Te)&ae)+ae^ae|L|Te;let Se=be|~(gt|ae),je=ae>Se>>>31^_e&&(M[Ve/32|0]^=1<>>31^Te&&(_[Ve/32|0]^=1<>>be&1,Ye=_[be/32|0]>>>be&1,Ve=ae|ye,L=((ae|Ye)&Q)+Q^Q|ae|Ye;let _e=ye|~(L|Q),Te=Q&L;he+=_e>>>S-1&1,he-=Te>>>S-1&1,_e>>>31^Ae&&(M[be/32|0]^=1<>>31^Ye&&(_[be/32|0]^=1<{if(D.length{const S=D.length<=y.length,_=D.length<=C;return S||_?Math.ceil(D.length/4):C},JX=(D,y,C)=>{let S=0;const _=Object.keys(y).find(M=>{const z=ZX(D,M,C);if(Math.abs(D.length-M.length)>z)return!1;const K=YX(D,M),Y=K<=z;return Y&&(S=K),Y});return _?{levenshteinDistance:S,levenshteinDistanceEntry:_}:{}};var IH={a:["4","@"],b:["8"],c:["(","{","[","<"],d:["6","|)"],e:["3"],f:["#"],g:["6","9","&"],h:["#","|-|"],i:["1","!","|"],k:["<","|<"],l:["!","1","|","7"],m:["^^","nn","2n","/\\\\/\\\\"],n:["//"],o:["0","()"],q:["9"],u:["|_|"],s:["$","5"],t:["+","7"],v:["<",">","/"],w:["^/","uu","vv","2u","2v","\\\\/\\\\/"],x:["%","><"],z:["2"]},q$={warnings:{straightRow:"straightRow",keyPattern:"keyPattern",simpleRepeat:"simpleRepeat",extendedRepeat:"extendedRepeat",sequences:"sequences",recentYears:"recentYears",dates:"dates",topTen:"topTen",topHundred:"topHundred",common:"common",similarToCommon:"similarToCommon",wordByItself:"wordByItself",namesByThemselves:"namesByThemselves",commonNames:"commonNames",userInputs:"userInputs",pwned:"pwned"},suggestions:{l33t:"l33t",reverseWords:"reverseWords",allUppercase:"allUppercase",capitalization:"capitalization",dates:"dates",recentYears:"recentYears",associatedYears:"associatedYears",sequences:"sequences",repeated:"repeated",longerKeyboardPattern:"longerKeyboardPattern",anotherWord:"anotherWord",useWords:"useWords",noNeed:"noNeed",pwned:"pwned"},timeEstimation:{ltSecond:"ltSecond",second:"second",seconds:"seconds",minute:"minute",minutes:"minutes",hour:"hour",hours:"hours",day:"day",days:"days",month:"month",months:"months",year:"year",years:"years",centuries:"centuries"}};class lk{constructor(y=[]){this.parents=y,this.children=new Map}addSub(y,...C){const S=y.charAt(0);this.children.has(S)||this.children.set(S,new lk([...this.parents,S]));let _=this.children.get(S);for(let M=1;M(Object.entries(D).forEach(([C,S])=>{S.forEach(_=>{y.addSub(_,C)})}),y);class QX{constructor(){this.matchers={},this.l33tTable=IH,this.trieNodeRoot=zH(IH,new lk),this.dictionary={userInputs:[]},this.rankedDictionaries={},this.rankedDictionariesMaxWordSize={},this.translations=q$,this.graphs={},this.useLevenshteinDistance=!1,this.levenshteinThreshold=2,this.l33tMaxSubstitutions=100,this.maxLength=256,this.setRankedDictionaries()}setOptions(y={}){y.l33tTable&&(this.l33tTable=y.l33tTable,this.trieNodeRoot=zH(y.l33tTable,new lk)),y.dictionary&&(this.dictionary=y.dictionary,this.setRankedDictionaries()),y.translations&&this.setTranslations(y.translations),y.graphs&&(this.graphs=y.graphs),y.useLevenshteinDistance!==void 0&&(this.useLevenshteinDistance=y.useLevenshteinDistance),y.levenshteinThreshold!==void 0&&(this.levenshteinThreshold=y.levenshteinThreshold),y.l33tMaxSubstitutions!==void 0&&(this.l33tMaxSubstitutions=y.l33tMaxSubstitutions),y.maxLength!==void 0&&(this.maxLength=y.maxLength)}setTranslations(y){if(this.checkCustomTranslations(y))this.translations=y;else throw new Error("Invalid translations object fallback to keys")}checkCustomTranslations(y){let C=!0;return Object.keys(q$).forEach(S=>{if(S in y){const _=S;Object.keys(q$[_]).forEach(M=>{M in y[_]||(C=!1)})}else C=!1}),C}setRankedDictionaries(){const y={},C={};Object.keys(this.dictionary).forEach(S=>{y[S]=RH(this.dictionary[S]),C[S]=this.getRankedDictionariesMaxWordSize(this.dictionary[S])}),this.rankedDictionaries=y,this.rankedDictionariesMaxWordSize=C}getRankedDictionariesMaxWordSize(y){const C=y.map(S=>typeof S!="string"?S.toString().length:S.length);return C.length===0?0:C.reduce((S,_)=>Math.max(S,_),-1/0)}buildSanitizedRankedDictionary(y){const C=[];return y.forEach(S=>{const _=typeof S;(_==="string"||_==="number"||_==="boolean")&&C.push(S.toString().toLowerCase())}),RH(C)}extendUserInputsDictionary(y){this.dictionary.userInputs||(this.dictionary.userInputs=[]);const C=[...this.dictionary.userInputs,...y];this.rankedDictionaries.userInputs=this.buildSanitizedRankedDictionary(C),this.rankedDictionariesMaxWordSize.userInputs=this.getRankedDictionariesMaxWordSize(C)}addMatcher(y,C){this.matchers[y]||(this.matchers[y]=C)}}const sa=new QX;class eY{constructor(y){this.defaultMatch=y}match({password:y}){const C=y.split("").reverse().join("");return this.defaultMatch({password:C}).map(S=>Ic(Ci({},S),{token:S.token.split("").reverse().join(""),reversed:!0,i:y.length-1-S.j,j:y.length-1-S.i}))}}class tY{constructor({substr:y,limit:C,trieRoot:S}){this.buffer=[],this.finalPasswords=[],this.substr=y,this.limit=C,this.trieRoot=S}getAllPossibleSubsAtIndex(y){const C=[];let S=this.trieRoot;for(let _=y;_=this.limit)return;if(S===this.substr.length){y===C&&this.finalPasswords.push({password:this.buffer.join(""),changes:M});return}const Y=[...this.getAllPossibleSubsAtIndex(S)];let ye=!1;for(let Q=S+Y.length-1;Q>=S;Q-=1){const W=Y[Q-S];if(W.isTerminal()){if(z===W.parents.join("")&&K>=3)continue;ye=!0;const ve=W.subs;for(const he of ve){this.buffer.push(he);const be=M.concat({i:_,letter:he,substitution:W.parents.join("")});if(this.helper({onlyFullSub:y,isFullSub:C,index:Q+1,subIndex:_+he.length,changes:be,lastSubLetter:W.parents.join(""),consecutiveSubCount:z===W.parents.join("")?K+1:1}),this.buffer.pop(),this.finalPasswords.length>=this.limit)return}}}if(!y||!ye){const Q=this.substr.charAt(S);this.buffer.push(Q),this.helper({onlyFullSub:y,isFullSub:C&&!ye,index:S+1,subIndex:_+1,changes:M,lastSubLetter:z,consecutiveSubCount:K}),this.buffer.pop()}}getAll(){return this.helper({onlyFullSub:!0,isFullSub:!0,index:0,subIndex:0,changes:[],lastSubLetter:void 0,consecutiveSubCount:0}),this.helper({onlyFullSub:!1,isFullSub:!0,index:0,subIndex:0,changes:[],lastSubLetter:void 0,consecutiveSubCount:0}),this.finalPasswords}}const nY=(D,y,C)=>new tY({substr:D,limit:y,trieRoot:C}).getAll(),rY=(D,y,C)=>{const _=D.changes.filter(ye=>ye.iye-Q.letter.length+Q.substitution.length,y),M=D.changes.filter(ye=>ye.i>=y&&ye.i<=C),z=M.reduce((ye,Q)=>ye-Q.letter.length+Q.substitution.length,C-y+_),K=[],Y=[];return M.forEach(ye=>{K.findIndex(W=>W.letter===ye.letter&&W.substitution===ye.substitution)<0&&(K.push({letter:ye.letter,substitution:ye.substitution}),Y.push(`${ye.substitution} -> ${ye.letter}`))}),{i:_,j:z,subs:K,subDisplay:Y.join(", ")}};class aY{constructor(y){this.defaultMatch=y}isAlreadyIncluded(y,C){return y.some(S=>Object.entries(S).every(([_,M])=>_==="subs"||M===C[_]))}match({password:y}){const C=[],S=nY(y,sa.l33tMaxSubstitutions,sa.trieNodeRoot);let _=!1,M=!0;return S.forEach(z=>{if(_)return;const K=this.defaultMatch({password:z.password,useLevenshtein:M});M=!1,K.forEach(Y=>{_||(_=Y.i===0&&Y.j===y.length-1);const ye=rY(z,Y.i,Y.j),Q=y.slice(ye.i,+ye.j+1||9e9),W=Ci(Ic(Ci({},Y),{l33t:!0,token:Q}),ye),ve=this.isAlreadyIncluded(C,W);Q.toLowerCase()!==Y.matchedWord&&!ve&&C.push(W)})}),C.filter(z=>z.token.length>1)}}class oY{constructor(){this.l33t=new aY(this.defaultMatch),this.reverse=new eY(this.defaultMatch)}match({password:y}){const C=[...this.defaultMatch({password:y}),...this.reverse.match({password:y}),...this.l33t.match({password:y})];return Sy(C)}defaultMatch({password:y,useLevenshtein:C=!0}){const S=[],_=y.length,M=y.toLowerCase();return Object.keys(sa.rankedDictionaries).forEach(z=>{const K=sa.rankedDictionaries[z],Y=sa.rankedDictionariesMaxWordSize[z],ye=Math.min(Y,_);for(let Q=0;Q<_;Q+=1){const W=Math.min(Q+ye,_);for(let ve=Q;ve{const M=C[_];M.lastIndex=0;let z;for(;z=M.exec(y);)if(z){const K=z[0];S.push({pattern:"regex",token:K,i:z.index,j:z.index+z[0].length-1,regexName:_,regexMatch:z})}}),Sy(S)}}var Ip={nCk(D,y){let C=D;if(y>C)return 0;if(y===0)return 1;let S=1;for(let _=1;_<=y;_+=1)S*=C,S/=_,C-=1;return S},log10(D){return D===0?0:Math.log(D)/Math.log(10)},log2(D){return Math.log(D)/Math.log(2)},factorial(D){let y=1;for(let C=2;C<=D;C+=1)y*=C;return y}},uY=({token:D})=>{let y=hy(NX,D.length);y===Number.POSITIVE_INFINITY&&(y=Number.MAX_VALUE);let C;return D.length===1?C=p9+1:C=b9+1,Math.max(y,C)},sY=({year:D,separator:y})=>{let S=Math.max(Math.abs(D-vL),y9)*365;return y&&(S*=4),S};const lY=D=>{const y=D.split(""),C=y.filter(z=>z.match(VX)).length,S=y.filter(z=>z.match(HX)).length;let _=0;const M=Math.min(C,S);for(let z=1;z<=M;z+=1)_+=Ip.nCk(C+S,z);return _};var cY=D=>{const y=D.replace(UX,"");if(y.match(LX)||y.toLowerCase()===y)return 1;const C=[w9,IX,C9],S=C.length;for(let _=0;_{let C=0,S=D.indexOf(y);for(;S>=0;)C+=1,S=D.indexOf(y,S+y.length);return C},fY=({sub:D,token:y})=>{const C=y.toLowerCase(),S=$H(C,D.substitution),_=$H(C,D.letter);return{subbedCount:S,unsubbedCount:_}};var vY=({l33t:D,subs:y,token:C})=>{if(!D)return 1;let S=1;return y.forEach(_=>{const{subbedCount:M,unsubbedCount:z}=fY({sub:_,token:C});if(M===0||z===0)S*=2;else{const K=Math.min(z,M);let Y=0;for(let ye=1;ye<=K;ye+=1)Y+=Ip.nCk(z+M,ye);S*=Y}}),S},dY=({rank:D,reversed:y,l33t:C,subs:S,token:_,dictionaryName:M})=>{const z=D,K=cY(_),Y=vY({l33t:C,subs:S,token:_}),ye=y&&2||1;let Q;return M==="diceware"?Q=hy(6,5)/2:Q=z*K*Y*ye,{baseGuesses:z,uppercaseVariations:K,l33tVariations:Y,calculation:Q}},mY=({regexName:D,regexMatch:y,token:C})=>{const S={alphaLower:26,alphaUpper:26,alpha:52,alphanumeric:62,digits:10,symbols:33};if(D in S)return hy(S[D],C.length);switch(D){case"recentYear":return Math.max(Math.abs(parseInt(y[0],10)-vL),y9)}return 0},gY=({baseGuesses:D,repeatCount:y})=>D*y,hY=({token:D,ascending:y})=>{const C=D.charAt(0);let S=0;return["a","A","z","Z","0","1","9"].includes(C)?S=4:C.match(/\d/)?S=10:S=26,y||(S*=2),S*D.length};const pY=D=>{let y=0;return Object.keys(D).forEach(C=>{const S=D[C];y+=S.filter(_=>!!_).length}),y/=Object.entries(D).length,y},bY=({token:D,graph:y,turns:C})=>{const S=Object.keys(sa.graphs[y]).length,_=pY(sa.graphs[y]);let M=0;const z=D.length;for(let K=2;K<=z;K+=1){const Y=Math.min(C,K-1);for(let ye=1;ye<=Y;ye+=1)M+=Ip.nCk(K-1,ye-1)*S*hy(_,ye)}return M};var yY=({graph:D,token:y,shiftedCount:C,turns:S})=>{let _=bY({token:y,graph:D,turns:S});if(C){const M=y.length-C;if(C===0||M===0)_*=2;else{let z=0;for(let K=1;K<=Math.min(C,M);K+=1)z+=Ip.nCk(C+M,K);_*=z}}return Math.round(_)},wY=()=>qX;const CY=(D,y)=>{let C=1;return D.token.lengthLH[D]?LH[D](y):sa.matchers[D]&&"scoring"in sa.matchers[D]?sa.matchers[D].scoring(y):0;var SY=(D,y)=>{const C={};if("guesses"in D&&D.guesses!=null)return D;const S=CY(D,y),_=xY(D.pattern,D);let M=0;typeof _=="number"?M=_:D.pattern==="dictionary"&&(M=_.calculation,C.baseGuesses=_.baseGuesses,C.uppercaseVariations=_.uppercaseVariations,C.l33tVariations=_.l33tVariations);const z=Math.max(M,S);return Ic(Ci(Ci({},D),C),{guesses:z,guessesLog10:Ip.log10(z)})};const fc={password:"",optimal:{},excludeAdditive:!1,separatorRegex:void 0,fillArray(D,y){const C=[];for(let S=0;S1&&(_*=this.optimal.pi[S.i-1][y-1]);let M=Ip.factorial(y)*_;this.excludeAdditive||(M+=hy(FX,y-1));let z=!1;Object.keys(this.optimal.g[C]).forEach(K=>{const Y=this.optimal.g[C][K];parseInt(K,10)<=y&&Y<=M&&(z=!0)}),z||(this.optimal.g[C][y]=M,this.optimal.m[C][y]=S,this.optimal.pi[C][y]=_)},bruteforceUpdate(D){let y=this.makeBruteforceMatch(0,D);this.update(y,1);for(let C=1;C<=D;C+=1){y=this.makeBruteforceMatch(C,D);const S=this.optimal.m[C-1];Object.keys(S).forEach(_=>{S[_].pattern!=="bruteforce"&&this.update(y,parseInt(_,10)+1)})}},unwind(D){const y=[];let C=D-1,S=0,_=1/0;const M=this.optimal.g[C];for(M&&Object.keys(M).forEach(z=>{const K=M[z];K<_&&(S=parseInt(z,10),_=K)});C>=0;){const z=this.optimal.m[C][S];y.unshift(z),C=z.i-1,S-=1}return y}};var Q$={mostGuessableMatchSequence(D,y,C=!1){fc.password=D,fc.excludeAdditive=C;const S=D.length;let _=fc.fillArray(S,"array");y.forEach(Y=>{_[Y.j].push(Y)}),_=_.map(Y=>Y.sort((ye,Q)=>ye.i-Q.i)),fc.optimal={m:fc.fillArray(S,"object"),pi:fc.fillArray(S,"object"),g:fc.fillArray(S,"object")};for(let Y=0;Y{ye.i>0?Object.keys(fc.optimal.m[ye.i-1]).forEach(Q=>{fc.update(ye,parseInt(Q,10)+1)}):fc.update(ye,1)}),fc.bruteforceUpdate(Y);const M=fc.unwind(S),z=M.length,K=this.getGuesses(D,z);return{password:D,guesses:K,guessesLog10:Ip.log10(K),sequence:M}},getGuesses(D,y){const C=D.length;let S=0;return D.length===0?S=1:S=fc.optimal.g[C-1][y],S}};class kY{match({password:y,omniMatch:C}){const S=[];let _=0;for(;_z instanceof Promise)?Promise.all(S):S}normalizeMatch(y,C,S,_){const M={pattern:"repeat",i:S.index,j:C,token:S[0],baseToken:y,baseGuesses:0,repeatCount:S[0].length/y.length};return _ instanceof Promise?_.then(z=>Ic(Ci({},M),{baseGuesses:z})):Ic(Ci({},M),{baseGuesses:_})}getGreedyMatch(y,C){const S=/(.+)\1+/g;return S.lastIndex=C,S.exec(y)}getLazyMatch(y,C){const S=/(.+?)\1+/g;return S.lastIndex=C,S.exec(y)}setMatchToken(y,C){const S=/^(.+?)\1+$/;let _,M="";if(C&&y[0].length>C[0].length){_=y;const z=S.exec(_[0]);z&&(M=z[1])}else _=C,_&&(M=_[1]);return{match:_,baseToken:M}}getBaseGuesses(y,C){const S=C.match(y);return S instanceof Promise?S.then(M=>Q$.mostGuessableMatchSequence(y,M).guesses):Q$.mostGuessableMatchSequence(y,S).guesses}}class EY{constructor(){this.MAX_DELTA=5}match({password:y}){const C=[];if(y.length===1)return[];let S=0,_=null;const M=y.length;for(let z=1;z1||Math.abs(S)===1){const z=Math.abs(S);if(z>0&&z<=this.MAX_DELTA){const K=_.slice(y,+C+1||9e9),{sequenceName:Y,sequenceSpace:ye}=this.getSequence(K);return M.push({pattern:"sequence",i:y,j:C,token:_.slice(y,+C+1||9e9),sequenceName:Y,sequenceSpace:ye,ascending:S>0})}}return null}getSequence(y){let C="unicode",S=26;return $X.test(y)?(C="lower",S=26):zX.test(y)?(C="upper",S=26):WX.test(y)&&(C="digits",S=10),{sequenceName:C,sequenceSpace:S}}}class TY{constructor(){this.SHIFTED_RX=/[~!@#$%^&*()_+QWERTYUIOP{}|ASDFGHJKL:"ZXCVBNM<>?]/}match({password:y}){const C=[];return Object.keys(sa.graphs).forEach(S=>{const _=sa.graphs[S];J$(C,this.helper(y,_,S))}),Sy(C)}checkIfShifted(y,C,S){return!y.includes("keypad")&&this.SHIFTED_RX.test(C.charAt(S))?1:0}helper(y,C,S){let _;const M=[];let z=0;const K=y.length;for(;z2&&M.push({pattern:"spatial",i:z,j:Y-1,token:y.slice(z,Y),graph:S,turns:Q,shiftedCount:_}),z=Y;break}}}return M}}const AY=new RegExp(`[${x9.join("")}]`);class iM{static getMostUsedSeparatorChar(y){const C=[...y.split("").filter(_=>AY.test(_)).reduce((_,M)=>{const z=_.get(M);return z?_.set(M,z+1):_.set(M,1),_},new Map).entries()].sort(([_,M],[z,K])=>K-M);if(!C.length)return;const S=C[0];if(!(S[1]<2))return S[0]}static getSeparatorRegex(y){return new RegExp(`([^${y} ])(${y})(?!${y})`,"g")}match({password:y}){const C=[];if(y.length===0)return C;const S=iM.getMostUsedSeparatorChar(y);if(S===void 0)return C;const _=iM.getSeparatorRegex(S);for(const M of y.matchAll(_)){if(M.index===void 0)continue;const z=M.index+1;C.push({pattern:"separator",token:S,i:z,j:z})}return C}}class OY{constructor(){this.matchers={date:GX,dictionary:oY,regex:iY,repeat:kY,sequence:EY,spatial:TY,separator:iM}}match(y){const C=[],S=[];return[...Object.keys(this.matchers),...Object.keys(sa.matchers)].forEach(M=>{if(!this.matchers[M]&&!sa.matchers[M])return;const z=this.matchers[M]?this.matchers[M]:sa.matchers[M].Matching,Y=new z().match({password:y,omniMatch:this});Y instanceof Promise?(Y.then(ye=>{J$(C,ye)}),S.push(Y)):J$(C,Y)}),S.length>0?new Promise((M,z)=>{Promise.all(S).then(()=>{M(Sy(C))}).catch(K=>{z(K)})}):Sy(C)}}const S9=1,k9=S9*60,E9=k9*60,T9=E9*24,A9=T9*31,O9=A9*12,DY=O9*100,G$={second:S9,minute:k9,hour:E9,day:T9,month:A9,year:O9,century:DY};class _Y{translate(y,C){let S=y;C!==void 0&&C!==1&&(S+="s");const{timeEstimation:_}=sa.translations;return _[S].replace("{base}",`${C}`)}estimateAttackTimes(y){const C={onlineThrottling100PerHour:y/.027777777777777776,onlineNoThrottling10PerSecond:y/10,offlineSlowHashing1e4PerSecond:y/1e4,offlineFastHashing1e10PerSecond:y/1e10},S={onlineThrottling100PerHour:"",onlineNoThrottling10PerSecond:"",offlineSlowHashing1e4PerSecond:"",offlineFastHashing1e10PerSecond:""};return Object.keys(C).forEach(_=>{const M=C[_];S[_]=this.displayTime(M)}),{crackTimesSeconds:C,crackTimesDisplay:S,score:this.guessesToScore(y)}}guessesToScore(y){return y<1005?0:y<1000005?1:y<100000005?2:y<1e10+5?3:4}displayTime(y){let C="centuries",S;const _=Object.keys(G$),M=_.findIndex(z=>y-1&&(C=_[M-1],M!==0?S=Math.round(y/G$[C]):C="ltSecond"),this.translate(C,S)}}var MY=()=>null,BY=()=>({warning:sa.translations.warnings.dates,suggestions:[sa.translations.suggestions.dates]});const PY=(D,y)=>{let C=null;return y&&!D.l33t&&!D.reversed?D.rank<=10?C=sa.translations.warnings.topTen:D.rank<=100?C=sa.translations.warnings.topHundred:C=sa.translations.warnings.common:D.guessesLog10<=4&&(C=sa.translations.warnings.similarToCommon),C},RY=(D,y)=>{let C=null;return y&&(C=sa.translations.warnings.wordByItself),C},NY=(D,y)=>y?sa.translations.warnings.namesByThemselves:sa.translations.warnings.commonNames,FY=(D,y)=>{let C=null;const S=D.dictionaryName,_=S==="lastnames"||S.toLowerCase().includes("firstnames");return S==="passwords"?C=PY(D,y):S.includes("wikipedia")?C=RY(D,y):_?C=NY(D,y):S==="userInputs"&&(C=sa.translations.warnings.userInputs),C};var IY=(D,y)=>{const C=FY(D,y),S=[],_=D.token;return _.match(w9)?S.push(sa.translations.suggestions.capitalization):_.match(C9)&&_.toLowerCase()!==_&&S.push(sa.translations.suggestions.allUppercase),D.reversed&&D.token.length>=4&&S.push(sa.translations.suggestions.reverseWords),D.l33t&&S.push(sa.translations.suggestions.l33t),{warning:C,suggestions:S}},zY=D=>D.regexName==="recentYear"?{warning:sa.translations.warnings.recentYears,suggestions:[sa.translations.suggestions.recentYears,sa.translations.suggestions.associatedYears]}:{warning:null,suggestions:[]},$Y=D=>{let y=sa.translations.warnings.extendedRepeat;return D.baseToken.length===1&&(y=sa.translations.warnings.simpleRepeat),{warning:y,suggestions:[sa.translations.suggestions.repeated]}},LY=()=>({warning:sa.translations.warnings.sequences,suggestions:[sa.translations.suggestions.sequences]}),HY=D=>{let y=sa.translations.warnings.keyPattern;return D.turns===1&&(y=sa.translations.warnings.straightRow),{warning:y,suggestions:[sa.translations.suggestions.longerKeyboardPattern]}},VY=()=>null;const HH={warning:null,suggestions:[]};class UY{constructor(){this.matchers={bruteforce:MY,date:BY,dictionary:IY,regex:zY,repeat:$Y,sequence:LY,spatial:HY,separator:VY},this.defaultFeedback={warning:null,suggestions:[]},this.setDefaultSuggestions()}setDefaultSuggestions(){this.defaultFeedback.suggestions.push(sa.translations.suggestions.useWords,sa.translations.suggestions.noNeed)}getFeedback(y,C){if(C.length===0)return this.defaultFeedback;if(y>2)return HH;const S=sa.translations.suggestions.anotherWord,_=this.getLongestMatch(C);let M=this.getMatchFeedback(_,C.length===1);return M!=null?M.suggestions.unshift(S):M={warning:null,suggestions:[S]},M}getLongestMatch(y){let C=y[0];return y.slice(1).forEach(_=>{_.token.length>C.token.length&&(C=_)}),C}getMatchFeedback(y,C){return this.matchers[y.pattern]?this.matchers[y.pattern](y,C):sa.matchers[y.pattern]&&"feedback"in sa.matchers[y.pattern]?sa.matchers[y.pattern].feedback(y,C):HH}}const D9=()=>new Date().getTime(),WY=(D,y,C)=>{const S=new UY,_=new _Y,M=Q$.mostGuessableMatchSequence(y,D),z=D9()-C,K=_.estimateAttackTimes(M.guesses);return Ic(Ci(Ci({calcTime:z},M),K),{feedback:S.getFeedback(K.score,M.sequence)})},jY=(D,y)=>new OY().match(D),qY=(D,y)=>{const C=D9(),S=jY(D);if(S instanceof Promise)throw new Error("You are using a Promised matcher, please use `zxcvbnAsync` for it.");return WY(S,D,C)},GY=["data-score"],KY=Ls({name:"StrengthMeter",__name:"StrengthMeter",props:{value:Co.string,showInput:Co.bool.def(!0),disabled:Co.bool},emits:["score-change","change"],setup(D,{emit:y}){const C=D,S=y,_=Ea(""),{prefixCls:M}=Fg("strength-meter"),z=ki(()=>{const{disabled:Y}=C;if(Y)return-1;const Q=mn(_)?qY(mn(_)).score:-1;return S("score-change",Q),Q});function K(Y){S("change",Y.target.value),_.value=Y.target.value}return vk(()=>{_.value=C.value||""}),Nu(()=>mn(_),Y=>{S("change",Y)}),(Y,ye)=>(Ha(),ms("div",{class:Xu([mn(M),"relative"])},[D.showInput?(Ha(),ou(mn(Bd).Password,pf({key:0},Y.$attrs,{allowClear:"",value:_.value,onChange:K,disabled:D.disabled}),Ey({_:2},[Fp(Object.keys(Y.$slots),Q=>({name:Q,fn:qa(W=>[Ty(Y.$slots,Q,dk(mk(W||{})),void 0,!0)])}))]),1040,["value","disabled"])):Md("",!0),$s("div",{class:Xu(`${mn(M)}-bar`)},[$s("div",{class:Xu(`${mn(M)}-bar--fill`),"data-score":z.value},null,10,GY)],2)],2))}}),XY=sM(KY,[["__scopeId","data-v-a884d127"]]),YY=Np(XY);function ZY(D){const y=Ea(D),C=Ea(!1);let S;function _(){S&&window.clearInterval(S)}function M(){C.value=!1,_(),S=null}function z(){mn(C)||S||(C.value=!0,S=setInterval(()=>{mn(y)===1?(M(),y.value=D):y.value-=1},1e3))}function K(){y.value=D,M()}function Y(){K(),z()}return FK(()=>{K()}),{start:z,reset:K,restart:Y,clear:_,stop:M,currentCount:y,isStart:C}}const _9=Ls({name:"CountButton",__name:"CountButton",props:{value:{type:[Object,Number,String,Array]},count:{type:Number,default:60},beforeStartFunc:{type:Function,default:null}},setup(D){const y=D,{t:C}=Rp(),S=Ea(!1),{currentCount:_,isStart:M,start:z,reset:K}=ZY(y.count),Y=ki(()=>mn(M)?C("component.countdown.sendText",[mn(_)]):C("component.countdown.normalText"));vk(()=>{y.value===void 0&&K()});function ye(){return zc(this,null,function*(){const{beforeStartFunc:Q}=y;if(Q&&Pi(Q)){S.value=!0;try{(yield Q())&&z()}finally{S.value=!1}}else z()})}return(Q,W)=>(Ha(),ou(mn(qK),pf(Q.$attrs,{disabled:mn(M),onClick:ye,loading:S.value}),{default:qa(()=>[Ng(Bp(Y.value),1)]),_:1},16,["disabled","loading"]))}}),JY=Ls({name:"CountDownInput",inheritAttrs:!1,__name:"CountdownInput",props:{value:{type:String},size:{type:String,validator:D=>["default","large","small"].includes(D)},count:{type:Number,default:60},sendCodeApi:{type:Function,default:null}},setup(D){const y=D,{prefixCls:C}=Fg("countdown-input"),[S]=ky(y);return(_,M)=>{const z=Mp("a-input");return Ha(),ou(z,pf(_.$attrs,{class:mn(C),size:D.size,value:mn(S)}),Ey({addonAfter:qa(()=>[Fa(_9,{size:D.size,count:D.count,value:mn(S),beforeStartFunc:D.sendCodeApi},null,8,["size","count","value","beforeStartFunc"])]),_:2},[Fp(Object.keys(_.$slots).filter(K=>K!=="addonAfter"),K=>({name:K,fn:qa(Y=>[Ty(_.$slots,K,dk(mk(Y||{})))])}))]),1040,["class","size","value"])}}}),QY=Np(JY);Np(_9);/*! * Cropper.js v1.6.2 * https://fengyuanchen.github.io/cropperjs * * Copyright 2015-present Chen Fengyuan * Released under the MIT license * * Date: 2024-04-21T07:43:05.335Z */function VH(D,y){var C=Object.keys(D);if(Object.getOwnPropertySymbols){var S=Object.getOwnPropertySymbols(D);y&&(S=S.filter(function(_){return Object.getOwnPropertyDescriptor(D,_).enumerable})),C.push.apply(C,S)}return C}function M9(D){for(var y=1;yD.length)&&(y=D.length);for(var C=0,S=new Array(y);C
',pZ=Number.isNaN||Sv.isNaN;function Za(D){return typeof D=="number"&&!pZ(D)}var t9=function(y){return y>0&&y<1/0};function K$(D){return typeof D=="undefined"}function Pp(D){return eL(D)==="object"&&D!==null}var bZ=Object.prototype.hasOwnProperty;function by(D){if(!Pp(D))return!1;try{var y=D.constructor,C=y.prototype;return y&&C&&bZ.call(C,"isPrototypeOf")}catch(S){return!1}}function Sl(D){return typeof D=="function"}var yZ=Array.prototype.slice;function H9(D){return Array.from?Array.from(D):yZ.call(D)}function gu(D,y){return D&&Sl(y)&&(Array.isArray(D)||Za(D.length)?H9(D).forEach(function(C,S){y.call(D,C,S,D)}):Pp(D)&&Object.keys(D).forEach(function(C){y.call(D,D[C],C,D)})),D}var Si=Object.assign||function(y){for(var C=arguments.length,S=new Array(C>1?C-1:0),_=1;_0&&S.forEach(function(M){Pp(M)&&Object.keys(M).forEach(function(z){y[z]=M[z]})}),y},wZ=/\.\d*(?:0|9){12}\d*$/;function wy(D){var y=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1e11;return wZ.test(D)?Math.round(D*y)/y:D}var CZ=/^width|height|left|top|marginLeft|marginTop$/;function Pg(D,y){var C=D.style;gu(y,function(S,_){CZ.test(_)&&Za(S)&&(S="".concat(S,"px")),C[_]=S})}function xZ(D,y){return D.classList?D.classList.contains(y):D.className.indexOf(y)>-1}function Ku(D,y){if(y){if(Za(D.length)){gu(D,function(S){Ku(S,y)});return}if(D.classList){D.classList.add(y);return}var C=D.className.trim();C?C.indexOf(y)<0&&(D.className="".concat(C," ").concat(y)):D.className=y}}function xv(D,y){if(y){if(Za(D.length)){gu(D,function(C){xv(C,y)});return}if(D.classList){D.classList.remove(y);return}D.className.indexOf(y)>=0&&(D.className=D.className.replace(y,""))}}function yy(D,y,C){if(y){if(Za(D.length)){gu(D,function(S){yy(S,y,C)});return}C?Ku(D,y):xv(D,y)}}var SZ=/([a-z\d])([A-Z])/g;function pL(D){return D.replace(SZ,"$1-$2").toLowerCase()}function lL(D,y){return Pp(D[y])?D[y]:D.dataset?D.dataset[y]:D.getAttribute("data-".concat(pL(y)))}function fk(D,y,C){Pp(C)?D[y]=C:D.dataset?D.dataset[y]=C:D.setAttribute("data-".concat(pL(y)),C)}function kZ(D,y){if(Pp(D[y]))try{delete D[y]}catch(C){D[y]=void 0}else if(D.dataset)try{delete D.dataset[y]}catch(C){D.dataset[y]=void 0}else D.removeAttribute("data-".concat(pL(y)))}var V9=/\s\s*/,U9=function(){var D=!1;if(vM){var y=!1,C=function(){},S=Object.defineProperty({},"once",{get:function(){return D=!0,y},set:function(M){y=M}});Sv.addEventListener("test",C,S),Sv.removeEventListener("test",C,S)}return D}();function hf(D,y,C){var S=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},_=C;y.trim().split(V9).forEach(function(M){if(!U9){var z=D.listeners;z&&z[M]&&z[M][C]&&(_=z[M][C],delete z[M][C],Object.keys(z[M]).length===0&&delete z[M],Object.keys(z).length===0&&delete D.listeners)}D.removeEventListener(M,_,S)})}function $c(D,y,C){var S=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},_=C;y.trim().split(V9).forEach(function(M){if(S.once&&!U9){var z=D.listeners,K=z===void 0?{}:z;_=function(){delete K[M][C],D.removeEventListener(M,_,S);for(var ye=arguments.length,Q=new Array(ye),W=0;WMath.abs(C)&&(C=ve)})}),C}function aM(D,y){var C=D.pageX,S=D.pageY,_={endX:C,endY:S};return y?_:M9({startX:C,startY:S},_)}function AZ(D){var y=0,C=0,S=0;return gu(D,function(_){var M=_.startX,z=_.startY;y+=M,C+=z,S+=1}),y/=S,C/=S,{pageX:y,pageY:C}}function Rg(D){var y=D.aspectRatio,C=D.height,S=D.width,_=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"contain",M=t9(S),z=t9(C);if(M&&z){var K=C*y;_==="contain"&&K>S||_==="cover"&&K90?{width:Y,height:K}:{width:K,height:Y}}function DZ(D,y,C,S){var _=y.aspectRatio,M=y.naturalWidth,z=y.naturalHeight,K=y.rotate,Y=K===void 0?0:K,ye=y.scaleX,Q=ye===void 0?1:ye,W=y.scaleY,ve=W===void 0?1:W,he=C.aspectRatio,be=C.naturalWidth,ae=C.naturalHeight,Ae=S.fillColor,Ye=Ae===void 0?"transparent":Ae,Ve=S.imageSmoothingEnabled,L=Ve===void 0?!0:Ve,_e=S.imageSmoothingQuality,Te=_e===void 0?"low":_e,Be=S.maxWidth,gt=Be===void 0?1/0:Be,Se=S.maxHeight,je=Se===void 0?1/0:Se,Ze=S.minWidth,it=Ze===void 0?0:Ze,G=S.minHeight,xe=G===void 0?0:G,ct=document.createElement("canvas"),Tn=ct.getContext("2d"),bt=Rg({aspectRatio:he,width:gt,height:je}),er=Rg({aspectRatio:he,width:it,height:xe},"cover"),Er=Math.min(bt.width,Math.max(er.width,be)),A=Math.min(bt.height,Math.max(er.height,ae)),Ht=Rg({aspectRatio:_,width:gt,height:je}),Kt=Rg({aspectRatio:_,width:it,height:xe},"cover"),Rn=Math.min(Ht.width,Math.max(Kt.width,M)),et=Math.min(Ht.height,Math.max(Kt.height,z)),nn=[-Rn/2,-et/2,Rn,et];return ct.width=wy(Er),ct.height=wy(A),Tn.fillStyle=Ye,Tn.fillRect(0,0,Er,A),Tn.save(),Tn.translate(Er/2,A/2),Tn.rotate(Y*Math.PI/180),Tn.scale(Q,ve),Tn.imageSmoothingEnabled=L,Tn.imageSmoothingQuality=Te,Tn.drawImage.apply(Tn,[D].concat(P9(nn.map(function(tn){return Math.floor(wy(tn))})))),Tn.restore(),ct}var j9=String.fromCharCode;function _Z(D,y,C){var S="";C+=y;for(var _=y;_0;)C.push(j9.apply(null,H9(_.subarray(0,S)))),_=_.subarray(S);return"data:".concat(y,";base64,").concat(btoa(C.join("")))}function RZ(D){var y=new DataView(D),C;try{var S,_,M;if(y.getUint8(0)===255&&y.getUint8(1)===216)for(var z=y.byteLength,K=2;K+1=8&&(M=ye+W)}}}if(M){var ve=y.getUint16(M,S),he,be;for(be=0;be=0?M:$9),height:Math.max(S.offsetHeight,z>=0?z:L9)};this.containerData=K,Pg(_,{width:K.width,height:K.height}),Ku(y,kl),xv(_,kl)},initCanvas:function(){var y=this.containerData,C=this.imageData,S=this.options.viewMode,_=Math.abs(C.rotate)%180===90,M=_?C.naturalHeight:C.naturalWidth,z=_?C.naturalWidth:C.naturalHeight,K=M/z,Y=y.width,ye=y.height;y.height*K>y.width?S===3?Y=y.height*K:ye=y.width/K:S===3?ye=y.width/K:Y=y.height*K;var Q={aspectRatio:K,naturalWidth:M,naturalHeight:z,width:Y,height:ye};this.canvasData=Q,this.limited=S===1||S===2,this.limitCanvas(!0,!0),Q.width=Math.min(Math.max(Q.width,Q.minWidth),Q.maxWidth),Q.height=Math.min(Math.max(Q.height,Q.minHeight),Q.maxHeight),Q.left=(y.width-Q.width)/2,Q.top=(y.height-Q.height)/2,Q.oldLeft=Q.left,Q.oldTop=Q.top,this.initialCanvasData=Si({},Q)},limitCanvas:function(y,C){var S=this.options,_=this.containerData,M=this.canvasData,z=this.cropBoxData,K=S.viewMode,Y=M.aspectRatio,ye=this.cropped&&z;if(y){var Q=Number(S.minCanvasWidth)||0,W=Number(S.minCanvasHeight)||0;K>1?(Q=Math.max(Q,_.width),W=Math.max(W,_.height),K===3&&(W*Y>Q?Q=W*Y:W=Q/Y)):K>0&&(Q?Q=Math.max(Q,ye?z.width:0):W?W=Math.max(W,ye?z.height:0):ye&&(Q=z.width,W=z.height,W*Y>Q?Q=W*Y:W=Q/Y));var ve=Rg({aspectRatio:Y,width:Q,height:W});Q=ve.width,W=ve.height,M.minWidth=Q,M.minHeight=W,M.maxWidth=1/0,M.maxHeight=1/0}if(C)if(K>(ye?0:1)){var he=_.width-M.width,be=_.height-M.height;M.minLeft=Math.min(0,he),M.minTop=Math.min(0,be),M.maxLeft=Math.max(0,he),M.maxTop=Math.max(0,be),ye&&this.limited&&(M.minLeft=Math.min(z.left,z.left+(z.width-M.width)),M.minTop=Math.min(z.top,z.top+(z.height-M.height)),M.maxLeft=z.left,M.maxTop=z.top,K===2&&(M.width>=_.width&&(M.minLeft=Math.min(0,he),M.maxLeft=Math.max(0,he)),M.height>=_.height&&(M.minTop=Math.min(0,be),M.maxTop=Math.max(0,be))))}else M.minLeft=-M.width,M.minTop=-M.height,M.maxLeft=_.width,M.maxTop=_.height},renderCanvas:function(y,C){var S=this.canvasData,_=this.imageData;if(C){var M=OZ({width:_.naturalWidth*Math.abs(_.scaleX||1),height:_.naturalHeight*Math.abs(_.scaleY||1),degree:_.rotate||0}),z=M.width,K=M.height,Y=S.width*(z/S.naturalWidth),ye=S.height*(K/S.naturalHeight);S.left-=(Y-S.width)/2,S.top-=(ye-S.height)/2,S.width=Y,S.height=ye,S.aspectRatio=z/K,S.naturalWidth=z,S.naturalHeight=K,this.limitCanvas(!0,!1)}(S.width>S.maxWidth||S.widthS.maxHeight||S.heightC.width?M.height=M.width/S:M.width=M.height*S),this.cropBoxData=M,this.limitCropBox(!0,!0),M.width=Math.min(Math.max(M.width,M.minWidth),M.maxWidth),M.height=Math.min(Math.max(M.height,M.minHeight),M.maxHeight),M.width=Math.max(M.minWidth,M.width*_),M.height=Math.max(M.minHeight,M.height*_),M.left=C.left+(C.width-M.width)/2,M.top=C.top+(C.height-M.height)/2,M.oldLeft=M.left,M.oldTop=M.top,this.initialCropBoxData=Si({},M)},limitCropBox:function(y,C){var S=this.options,_=this.containerData,M=this.canvasData,z=this.cropBoxData,K=this.limited,Y=S.aspectRatio;if(y){var ye=Number(S.minCropBoxWidth)||0,Q=Number(S.minCropBoxHeight)||0,W=K?Math.min(_.width,M.width,M.width+M.left,_.width-M.left):_.width,ve=K?Math.min(_.height,M.height,M.height+M.top,_.height-M.top):_.height;ye=Math.min(ye,_.width),Q=Math.min(Q,_.height),Y&&(ye&&Q?Q*Y>ye?Q=ye/Y:ye=Q*Y:ye?Q=ye/Y:Q&&(ye=Q*Y),ve*Y>W?ve=W/Y:W=ve*Y),z.minWidth=Math.min(ye,W),z.minHeight=Math.min(Q,ve),z.maxWidth=W,z.maxHeight=ve}C&&(K?(z.minLeft=Math.max(0,M.left),z.minTop=Math.max(0,M.top),z.maxLeft=Math.min(_.width,M.left+M.width)-z.width,z.maxTop=Math.min(_.height,M.top+M.height)-z.height):(z.minLeft=0,z.minTop=0,z.maxLeft=_.width-z.width,z.maxTop=_.height-z.height))},renderCropBox:function(){var y=this.options,C=this.containerData,S=this.cropBoxData;(S.width>S.maxWidth||S.widthS.maxHeight||S.height=C.width&&S.height>=C.height?N9:gL),Pg(this.cropBox,Si({width:S.width,height:S.height},uk({translateX:S.left,translateY:S.top}))),this.cropped&&this.limited&&this.limitCanvas(!0,!0),this.disabled||this.output()},output:function(){this.preview(),Cy(this.element,aL,this.getData())}},IZ={initPreview:function(){var y=this.element,C=this.crossOrigin,S=this.options.preview,_=C?this.crossOriginUrl:this.url,M=y.alt||"The image to preview",z=document.createElement("img");if(C&&(z.crossOrigin=C),z.src=_,z.alt=M,this.viewBox.appendChild(z),this.viewBoxImage=z,!!S){var K=S;typeof S=="string"?K=y.ownerDocument.querySelectorAll(S):S.querySelector&&(K=[S]),this.previews=K,gu(K,function(Y){var ye=document.createElement("img");fk(Y,rM,{width:Y.offsetWidth,height:Y.offsetHeight,html:Y.innerHTML}),C&&(ye.crossOrigin=C),ye.src=_,ye.alt=M,ye.style.cssText='display:block;width:100%;height:auto;min-width:0!important;min-height:0!important;max-width:none!important;max-height:none!important;image-orientation:0deg!important;"',Y.innerHTML="",Y.appendChild(ye)})}},resetPreview:function(){gu(this.previews,function(y){var C=lL(y,rM);Pg(y,{width:C.width,height:C.height}),y.innerHTML=C.html,kZ(y,rM)})},preview:function(){var y=this.imageData,C=this.canvasData,S=this.cropBoxData,_=S.width,M=S.height,z=y.width,K=y.height,Y=S.left-C.left-y.left,ye=S.top-C.top-y.top;!this.cropped||this.disabled||(Pg(this.viewBoxImage,Si({width:z,height:K},uk(Si({translateX:-Y,translateY:-ye},y)))),gu(this.previews,function(Q){var W=lL(Q,rM),ve=W.width,he=W.height,be=ve,ae=he,Ae=1;_&&(Ae=ve/_,ae=M*Ae),M&&ae>he&&(Ae=he/M,be=_*Ae,ae=he),Pg(Q,{width:be,height:ae}),Pg(Q.getElementsByTagName("img")[0],Si({width:z*Ae,height:K*Ae},uk(Si({translateX:-Y*Ae,translateY:-ye*Ae},y))))}))}},zZ={bind:function(){var y=this.element,C=this.options,S=this.cropper;Sl(C.cropstart)&&$c(y,uL,C.cropstart),Sl(C.cropmove)&&$c(y,iL,C.cropmove),Sl(C.cropend)&&$c(y,oL,C.cropend),Sl(C.crop)&&$c(y,aL,C.crop),Sl(C.zoom)&&$c(y,sL,C.zoom),$c(S,GH,this.onCropStart=this.cropStart.bind(this)),C.zoomable&&C.zoomOnWheel&&$c(S,JH,this.onWheel=this.wheel.bind(this),{passive:!1,capture:!0}),C.toggleDragModeOnDblclick&&$c(S,qH,this.onDblclick=this.dblclick.bind(this)),$c(y.ownerDocument,KH,this.onCropMove=this.cropMove.bind(this)),$c(y.ownerDocument,XH,this.onCropEnd=this.cropEnd.bind(this)),C.responsive&&$c(window,ZH,this.onResize=this.resize.bind(this))},unbind:function(){var y=this.element,C=this.options,S=this.cropper;Sl(C.cropstart)&&hf(y,uL,C.cropstart),Sl(C.cropmove)&&hf(y,iL,C.cropmove),Sl(C.cropend)&&hf(y,oL,C.cropend),Sl(C.crop)&&hf(y,aL,C.crop),Sl(C.zoom)&&hf(y,sL,C.zoom),hf(S,GH,this.onCropStart),C.zoomable&&C.zoomOnWheel&&hf(S,JH,this.onWheel,{passive:!1,capture:!0}),C.toggleDragModeOnDblclick&&hf(S,qH,this.onDblclick),hf(y.ownerDocument,KH,this.onCropMove),hf(y.ownerDocument,XH,this.onCropEnd),C.responsive&&hf(window,ZH,this.onResize)}},$Z={resize:function(){if(!this.disabled){var y=this.options,C=this.container,S=this.containerData,_=C.offsetWidth/S.width,M=C.offsetHeight/S.height,z=Math.abs(_-1)>Math.abs(M-1)?_:M;if(z!==1){var K,Y;y.restore&&(K=this.getCanvasData(),Y=this.getCropBoxData()),this.render(),y.restore&&(this.setCanvasData(gu(K,function(ye,Q){K[Q]=ye*z})),this.setCropBoxData(gu(Y,function(ye,Q){Y[Q]=ye*z})))}}},dblclick:function(){this.disabled||this.options.dragMode===z9||this.setDragMode(xZ(this.dragBox,nL)?I9:hL)},wheel:function(y){var C=this,S=Number(this.options.wheelZoomRatio)||.1,_=1;this.disabled||(y.preventDefault(),!this.wheeling&&(this.wheeling=!0,setTimeout(function(){C.wheeling=!1},50),y.deltaY?_=y.deltaY>0?1:-1:y.wheelDelta?_=-y.wheelDelta/120:y.detail&&(_=y.detail>0?1:-1),this.zoom(-_*S,y)))},cropStart:function(y){var C=y.buttons,S=y.button;if(!(this.disabled||(y.type==="mousedown"||y.type==="pointerdown"&&y.pointerType==="mouse")&&(Za(C)&&C!==1||Za(S)&&S!==0||y.ctrlKey))){var _=this.options,M=this.pointers,z;y.changedTouches?gu(y.changedTouches,function(K){M[K.identifier]=aM(K)}):M[y.pointerId||0]=aM(y),Object.keys(M).length>1&&_.zoomable&&_.zoomOnTouch?z=F9:z=lL(y.target,ck),vZ.test(z)&&Cy(this.element,uL,{originalEvent:y,action:z})!==!1&&(y.preventDefault(),this.action=z,this.cropping=!1,z===R9&&(this.cropping=!0,Ku(this.dragBox,uM)))}},cropMove:function(y){var C=this.action;if(!(this.disabled||!C)){var S=this.pointers;y.preventDefault(),Cy(this.element,iL,{originalEvent:y,action:C})!==!1&&(y.changedTouches?gu(y.changedTouches,function(_){Si(S[_.identifier]||{},aM(_,!0))}):Si(S[y.pointerId||0]||{},aM(y,!0)),this.change(y))}},cropEnd:function(y){if(!this.disabled){var C=this.action,S=this.pointers;y.changedTouches?gu(y.changedTouches,function(_){delete S[_.identifier]}):delete S[y.pointerId||0],C&&(y.preventDefault(),Object.keys(S).length||(this.action=""),this.cropping&&(this.cropping=!1,yy(this.dragBox,uM,this.cropped&&this.options.modal)),Cy(this.element,oL,{originalEvent:y,action:C}))}}},LZ={change:function(y){var C=this.options,S=this.canvasData,_=this.containerData,M=this.cropBoxData,z=this.pointers,K=this.action,Y=C.aspectRatio,ye=M.left,Q=M.top,W=M.width,ve=M.height,he=ye+W,be=Q+ve,ae=0,Ae=0,Ye=_.width,Ve=_.height,L=!0,_e;!Y&&y.shiftKey&&(Y=W&&ve?W/ve:1),this.limited&&(ae=M.minLeft,Ae=M.minTop,Ye=ae+Math.min(_.width,S.width,S.left+S.width),Ve=Ae+Math.min(_.height,S.height,S.top+S.height));var Te=z[Object.keys(z)[0]],Be={x:Te.endX-Te.startX,y:Te.endY-Te.startY},gt=function(je){switch(je){case Op:he+Be.x>Ye&&(Be.x=Ye-he);break;case Dp:ye+Be.xVe&&(Be.y=Ve-be);break}};switch(K){case gL:ye+=Be.x,Q+=Be.y;break;case Op:if(Be.x>=0&&(he>=Ye||Y&&(Q<=Ae||be>=Ve))){L=!1;break}gt(Op),W+=Be.x,W<0&&(K=Dp,W=-W,ye-=W),Y&&(ve=W/Y,Q+=(M.height-ve)/2);break;case Mg:if(Be.y<=0&&(Q<=Ae||Y&&(ye<=ae||he>=Ye))){L=!1;break}gt(Mg),ve-=Be.y,Q+=Be.y,ve<0&&(K=py,ve=-ve,Q-=ve),Y&&(W=ve*Y,ye+=(M.width-W)/2);break;case Dp:if(Be.x<=0&&(ye<=ae||Y&&(Q<=Ae||be>=Ve))){L=!1;break}gt(Dp),W-=Be.x,ye+=Be.x,W<0&&(K=Op,W=-W,ye-=W),Y&&(ve=W/Y,Q+=(M.height-ve)/2);break;case py:if(Be.y>=0&&(be>=Ve||Y&&(ye<=ae||he>=Ye))){L=!1;break}gt(py),ve+=Be.y,ve<0&&(K=Mg,ve=-ve,Q-=ve),Y&&(W=ve*Y,ye+=(M.width-W)/2);break;case rk:if(Y){if(Be.y<=0&&(Q<=Ae||he>=Ye)){L=!1;break}gt(Mg),ve-=Be.y,Q+=Be.y,W=ve*Y}else gt(Mg),gt(Op),Be.x>=0?heAe&&(ve-=Be.y,Q+=Be.y):(ve-=Be.y,Q+=Be.y);W<0&&ve<0?(K=ik,ve=-ve,W=-W,Q-=ve,ye-=W):W<0?(K=ak,W=-W,ye-=W):ve<0&&(K=ok,ve=-ve,Q-=ve);break;case ak:if(Y){if(Be.y<=0&&(Q<=Ae||ye<=ae)){L=!1;break}gt(Mg),ve-=Be.y,Q+=Be.y,W=ve*Y,ye+=M.width-W}else gt(Mg),gt(Dp),Be.x<=0?ye>ae?(W-=Be.x,ye+=Be.x):Be.y<=0&&Q<=Ae&&(L=!1):(W-=Be.x,ye+=Be.x),Be.y<=0?Q>Ae&&(ve-=Be.y,Q+=Be.y):(ve-=Be.y,Q+=Be.y);W<0&&ve<0?(K=ok,ve=-ve,W=-W,Q-=ve,ye-=W):W<0?(K=rk,W=-W,ye-=W):ve<0&&(K=ik,ve=-ve,Q-=ve);break;case ik:if(Y){if(Be.x<=0&&(ye<=ae||be>=Ve)){L=!1;break}gt(Dp),W-=Be.x,ye+=Be.x,ve=W/Y}else gt(py),gt(Dp),Be.x<=0?ye>ae?(W-=Be.x,ye+=Be.x):Be.y>=0&&be>=Ve&&(L=!1):(W-=Be.x,ye+=Be.x),Be.y>=0?be=0&&(he>=Ye||be>=Ve)){L=!1;break}gt(Op),W+=Be.x,ve=W/Y}else gt(py),gt(Op),Be.x>=0?he=0&&be>=Ve&&(L=!1):W+=Be.x,Be.y>=0?be0?K=Be.y>0?ok:rk:Be.x<0&&(ye-=W,K=Be.y>0?ik:ak),Be.y<0&&(Q-=ve),this.cropped||(xv(this.cropBox,kl),this.cropped=!0,this.limited&&this.limitCropBox(!0,!0));break}L&&(M.width=W,M.height=ve,M.left=ye,M.top=Q,this.action=K,this.renderCropBox()),gu(z,function(Se){Se.startX=Se.endX,Se.startY=Se.endY})}},HZ={crop:function(){return this.ready&&!this.cropped&&!this.disabled&&(this.cropped=!0,this.limitCropBox(!0,!0),this.options.modal&&Ku(this.dragBox,uM),xv(this.cropBox,kl),this.setCropBoxData(this.initialCropBoxData)),this},reset:function(){return this.ready&&!this.disabled&&(this.imageData=Si({},this.initialImageData),this.canvasData=Si({},this.initialCanvasData),this.cropBoxData=Si({},this.initialCropBoxData),this.renderCanvas(),this.cropped&&this.renderCropBox()),this},clear:function(){return this.cropped&&!this.disabled&&(Si(this.cropBoxData,{left:0,top:0,width:0,height:0}),this.cropped=!1,this.renderCropBox(),this.limitCanvas(!0,!0),this.renderCanvas(),xv(this.dragBox,uM),Ku(this.cropBox,kl)),this},replace:function(y){var C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return!this.disabled&&y&&(this.isImg&&(this.element.src=y),C?(this.url=y,this.image.src=y,this.ready&&(this.viewBoxImage.src=y,gu(this.previews,function(S){S.getElementsByTagName("img")[0].src=y}))):(this.isImg&&(this.replaced=!0),this.options.data=null,this.uncreate(),this.load(y))),this},enable:function(){return this.ready&&this.disabled&&(this.disabled=!1,xv(this.cropper,WH)),this},disable:function(){return this.ready&&!this.disabled&&(this.disabled=!0,Ku(this.cropper,WH)),this},destroy:function(){var y=this.element;return y[xi]?(y[xi]=void 0,this.isImg&&this.replaced&&(y.src=this.originalUrl),this.uncreate(),this):this},move:function(y){var C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:y,S=this.canvasData,_=S.left,M=S.top;return this.moveTo(K$(y)?y:_+Number(y),K$(C)?C:M+Number(C))},moveTo:function(y){var C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:y,S=this.canvasData,_=!1;return y=Number(y),C=Number(C),this.ready&&!this.disabled&&this.options.movable&&(Za(y)&&(S.left=y,_=!0),Za(C)&&(S.top=C,_=!0),_&&this.renderCanvas(!0)),this},zoom:function(y,C){var S=this.canvasData;return y=Number(y),y<0?y=1/(1-y):y=1+y,this.zoomTo(S.width*y/S.naturalWidth,null,C)},zoomTo:function(y,C,S){var _=this.options,M=this.canvasData,z=M.width,K=M.height,Y=M.naturalWidth,ye=M.naturalHeight;if(y=Number(y),y>=0&&this.ready&&!this.disabled&&_.zoomable){var Q=Y*y,W=ye*y;if(Cy(this.element,sL,{ratio:y,oldRatio:z/Y,originalEvent:S})===!1)return this;if(S){var ve=this.pointers,he=W9(this.cropper),be=ve&&Object.keys(ve).length?AZ(ve):{pageX:S.pageX,pageY:S.pageY};M.left-=(Q-z)*((be.pageX-he.left-M.left)/z),M.top-=(W-K)*((be.pageY-he.top-M.top)/K)}else by(C)&&Za(C.x)&&Za(C.y)?(M.left-=(Q-z)*((C.x-M.left)/z),M.top-=(W-K)*((C.y-M.top)/K)):(M.left-=(Q-z)/2,M.top-=(W-K)/2);M.width=Q,M.height=W,this.renderCanvas(!0)}return this},rotate:function(y){return this.rotateTo((this.imageData.rotate||0)+Number(y))},rotateTo:function(y){return y=Number(y),Za(y)&&this.ready&&!this.disabled&&this.options.rotatable&&(this.imageData.rotate=y%360,this.renderCanvas(!0,!0)),this},scaleX:function(y){var C=this.imageData.scaleY;return this.scale(y,Za(C)?C:1)},scaleY:function(y){var C=this.imageData.scaleX;return this.scale(Za(C)?C:1,y)},scale:function(y){var C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:y,S=this.imageData,_=!1;return y=Number(y),C=Number(C),this.ready&&!this.disabled&&this.options.scalable&&(Za(y)&&(S.scaleX=y,_=!0),Za(C)&&(S.scaleY=C,_=!0),_&&this.renderCanvas(!0,!0)),this},getData:function(){var y=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,C=this.options,S=this.imageData,_=this.canvasData,M=this.cropBoxData,z;if(this.ready&&this.cropped){z={x:M.left-_.left,y:M.top-_.top,width:M.width,height:M.height};var K=S.width/S.naturalWidth;if(gu(z,function(Q,W){z[W]=Q/K}),y){var Y=Math.round(z.y+z.height),ye=Math.round(z.x+z.width);z.x=Math.round(z.x),z.y=Math.round(z.y),z.width=ye-z.x,z.height=Y-z.y}}else z={x:0,y:0,width:0,height:0};return C.rotatable&&(z.rotate=S.rotate||0),C.scalable&&(z.scaleX=S.scaleX||1,z.scaleY=S.scaleY||1),z},setData:function(y){var C=this.options,S=this.imageData,_=this.canvasData,M={};if(this.ready&&!this.disabled&&by(y)){var z=!1;C.rotatable&&Za(y.rotate)&&y.rotate!==S.rotate&&(S.rotate=y.rotate,z=!0),C.scalable&&(Za(y.scaleX)&&y.scaleX!==S.scaleX&&(S.scaleX=y.scaleX,z=!0),Za(y.scaleY)&&y.scaleY!==S.scaleY&&(S.scaleY=y.scaleY,z=!0)),z&&this.renderCanvas(!0,!0);var K=S.width/S.naturalWidth;Za(y.x)&&(M.left=y.x*K+_.left),Za(y.y)&&(M.top=y.y*K+_.top),Za(y.width)&&(M.width=y.width*K),Za(y.height)&&(M.height=y.height*K),this.setCropBoxData(M)}return this},getContainerData:function(){return this.ready?Si({},this.containerData):{}},getImageData:function(){return this.sized?Si({},this.imageData):{}},getCanvasData:function(){var y=this.canvasData,C={};return this.ready&&gu(["left","top","width","height","naturalWidth","naturalHeight"],function(S){C[S]=y[S]}),C},setCanvasData:function(y){var C=this.canvasData,S=C.aspectRatio;return this.ready&&!this.disabled&&by(y)&&(Za(y.left)&&(C.left=y.left),Za(y.top)&&(C.top=y.top),Za(y.width)?(C.width=y.width,C.height=y.width/S):Za(y.height)&&(C.height=y.height,C.width=y.height*S),this.renderCanvas(!0)),this},getCropBoxData:function(){var y=this.cropBoxData,C;return this.ready&&this.cropped&&(C={left:y.left,top:y.top,width:y.width,height:y.height}),C||{}},setCropBoxData:function(y){var C=this.cropBoxData,S=this.options.aspectRatio,_,M;return this.ready&&this.cropped&&!this.disabled&&by(y)&&(Za(y.left)&&(C.left=y.left),Za(y.top)&&(C.top=y.top),Za(y.width)&&y.width!==C.width&&(_=!0,C.width=y.width),Za(y.height)&&y.height!==C.height&&(M=!0,C.height=y.height),S&&(_?C.height=C.width/S:M&&(C.width=C.height*S)),this.renderCropBox()),this},getCroppedCanvas:function(){var y=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!this.ready||!window.HTMLCanvasElement)return null;var C=this.canvasData,S=DZ(this.image,this.imageData,C,y);if(!this.cropped)return S;var _=this.getData(y.rounded),M=_.x,z=_.y,K=_.width,Y=_.height,ye=S.width/Math.floor(C.naturalWidth);ye!==1&&(M*=ye,z*=ye,K*=ye,Y*=ye);var Q=K/Y,W=Rg({aspectRatio:Q,width:y.maxWidth||1/0,height:y.maxHeight||1/0}),ve=Rg({aspectRatio:Q,width:y.minWidth||0,height:y.minHeight||0},"cover"),he=Rg({aspectRatio:Q,width:y.width||(ye!==1?S.width:K),height:y.height||(ye!==1?S.height:Y)}),be=he.width,ae=he.height;be=Math.min(W.width,Math.max(ve.width,be)),ae=Math.min(W.height,Math.max(ve.height,ae));var Ae=document.createElement("canvas"),Ye=Ae.getContext("2d");Ae.width=wy(be),Ae.height=wy(ae),Ye.fillStyle=y.fillColor||"transparent",Ye.fillRect(0,0,be,ae);var Ve=y.imageSmoothingEnabled,L=Ve===void 0?!0:Ve,_e=y.imageSmoothingQuality;Ye.imageSmoothingEnabled=L,_e&&(Ye.imageSmoothingQuality=_e);var Te=S.width,Be=S.height,gt=M,Se=z,je,Ze,it,G,xe,ct;gt<=-K||gt>Te?(gt=0,je=0,it=0,xe=0):gt<=0?(it=-gt,gt=0,je=Math.min(Te,K+gt),xe=je):gt<=Te&&(it=0,je=Math.min(K,Te-gt),xe=je),je<=0||Se<=-Y||Se>Be?(Se=0,Ze=0,G=0,ct=0):Se<=0?(G=-Se,Se=0,Ze=Math.min(Be,Y+Se),ct=Ze):Se<=Be&&(G=0,Ze=Math.min(Y,Be-Se),ct=Ze);var Tn=[gt,Se,je,Ze];if(xe>0&&ct>0){var bt=be/K;Tn.push(it*bt,G*bt,xe*bt,ct*bt)}return Ye.drawImage.apply(Ye,[S].concat(P9(Tn.map(function(er){return Math.floor(wy(er))})))),Ae},setAspectRatio:function(y){var C=this.options;return!this.disabled&&!K$(y)&&(C.aspectRatio=Math.max(0,y)||NaN,this.ready&&(this.initCropBox(),this.cropped&&this.renderCropBox())),this},setDragMode:function(y){var C=this.options,S=this.dragBox,_=this.face;if(this.ready&&!this.disabled){var M=y===hL,z=C.movable&&y===I9;y=M||z?y:z9,C.dragMode=y,fk(S,ck,y),yy(S,nL,M),yy(S,rL,z),C.cropBoxMovable||(fk(_,ck,y),yy(_,nL,M),yy(_,rL,z))}return this}},VZ=Sv.Cropper,q9=function(){function D(y){var C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(tZ(this,D),!y||!gZ.test(y.tagName))throw new Error("The first argument is required and must be an or element.");this.element=y,this.options=Si({},e9,by(C)&&C),this.cropped=!1,this.disabled=!1,this.pointers={},this.ready=!1,this.reloading=!1,this.replaced=!1,this.sized=!1,this.sizing=!1,this.init()}return nZ(D,[{key:"init",value:function(){var C=this.element,S=C.tagName.toLowerCase(),_;if(!C[xi]){if(C[xi]=this,S==="img"){if(this.isImg=!0,_=C.getAttribute("src")||"",this.originalUrl=_,!_)return;_=C.src}else S==="canvas"&&window.HTMLCanvasElement&&(_=C.toDataURL());this.load(_)}}},{key:"load",value:function(C){var S=this;if(C){this.url=C,this.imageData={};var _=this.element,M=this.options;if(!M.rotatable&&!M.scalable&&(M.checkOrientation=!1),!M.checkOrientation||!window.ArrayBuffer){this.clone();return}if(dZ.test(C)){mZ.test(C)?this.read(BZ(C)):this.clone();return}var z=new XMLHttpRequest,K=this.clone.bind(this);this.reloading=!0,this.xhr=z,z.onabort=K,z.onerror=K,z.ontimeout=K,z.onprogress=function(){z.getResponseHeader("content-type")!==QH&&z.abort()},z.onload=function(){S.read(z.response)},z.onloadend=function(){S.reloading=!1,S.xhr=null},M.checkCrossOrigin&&n9(C)&&_.crossOrigin&&(C=r9(C)),z.open("GET",C,!0),z.responseType="arraybuffer",z.withCredentials=_.crossOrigin==="use-credentials",z.send()}}},{key:"read",value:function(C){var S=this.options,_=this.imageData,M=RZ(C),z=0,K=1,Y=1;if(M>1){this.url=PZ(C,QH);var ye=NZ(M);z=ye.rotate,K=ye.scaleX,Y=ye.scaleY}S.rotatable&&(_.rotate=z),S.scalable&&(_.scaleX=K,_.scaleY=Y),this.clone()}},{key:"clone",value:function(){var C=this.element,S=this.url,_=C.crossOrigin,M=S;this.options.checkCrossOrigin&&n9(S)&&(_||(_="anonymous"),M=r9(S)),this.crossOrigin=_,this.crossOriginUrl=M;var z=document.createElement("img");_&&(z.crossOrigin=_),z.src=M||S,z.alt=C.alt||"The image to crop",this.image=z,z.onload=this.start.bind(this),z.onerror=this.stop.bind(this),Ku(z,jH),C.parentNode.insertBefore(z,C.nextSibling)}},{key:"start",value:function(){var C=this,S=this.image;S.onload=null,S.onerror=null,this.sizing=!0;var _=Sv.navigator&&/(?:iPad|iPhone|iPod).*?AppleWebKit/i.test(Sv.navigator.userAgent),M=function(ye,Q){Si(C.imageData,{naturalWidth:ye,naturalHeight:Q,aspectRatio:ye/Q}),C.initialImageData=Si({},C.imageData),C.sizing=!1,C.sized=!0,C.build()};if(S.naturalWidth&&!_){M(S.naturalWidth,S.naturalHeight);return}var z=document.createElement("img"),K=document.body||document.documentElement;this.sizingImage=z,z.onload=function(){M(z.width,z.height),_||K.removeChild(z)},z.src=S.src,_||(z.style.cssText="left:0;max-height:none!important;max-width:none!important;min-height:0!important;min-width:0!important;opacity:0;position:absolute;top:0;z-index:-1;",K.appendChild(z))}},{key:"stop",value:function(){var C=this.image;C.onload=null,C.onerror=null,C.parentNode.removeChild(C),this.image=null}},{key:"build",value:function(){if(!(!this.sized||this.ready)){var C=this.element,S=this.options,_=this.image,M=C.parentNode,z=document.createElement("div");z.innerHTML=hZ;var K=z.querySelector(".".concat(xi,"-container")),Y=K.querySelector(".".concat(xi,"-canvas")),ye=K.querySelector(".".concat(xi,"-drag-box")),Q=K.querySelector(".".concat(xi,"-crop-box")),W=Q.querySelector(".".concat(xi,"-face"));this.container=M,this.cropper=K,this.canvas=Y,this.dragBox=ye,this.cropBox=Q,this.viewBox=K.querySelector(".".concat(xi,"-view-box")),this.face=W,Y.appendChild(_),Ku(C,kl),M.insertBefore(K,C.nextSibling),xv(_,jH),this.initPreview(),this.bind(),S.initialAspectRatio=Math.max(0,S.initialAspectRatio)||NaN,S.aspectRatio=Math.max(0,S.aspectRatio)||NaN,S.viewMode=Math.max(0,Math.min(3,Math.round(S.viewMode)))||0,Ku(Q,kl),S.guides||Ku(Q.getElementsByClassName("".concat(xi,"-dashed")),kl),S.center||Ku(Q.getElementsByClassName("".concat(xi,"-center")),kl),S.background&&Ku(K,"".concat(xi,"-bg")),S.highlight||Ku(W,sZ),S.cropBoxMovable&&(Ku(W,rL),fk(W,ck,gL)),S.cropBoxResizable||(Ku(Q.getElementsByClassName("".concat(xi,"-line")),kl),Ku(Q.getElementsByClassName("".concat(xi,"-point")),kl)),this.render(),this.ready=!0,this.setDragMode(S.dragMode),S.autoCrop&&this.crop(),this.setData(S.data),Sl(S.ready)&&$c(C,YH,S.ready,{once:!0}),Cy(C,YH)}}},{key:"unbuild",value:function(){if(this.ready){this.ready=!1,this.unbind(),this.resetPreview();var C=this.cropper.parentNode;C&&C.removeChild(this.cropper),xv(this.element,kl)}}},{key:"uncreate",value:function(){this.ready?(this.unbuild(),this.ready=!1,this.cropped=!1):this.sizing?(this.sizingImage.onload=null,this.sizing=!1,this.sized=!1):this.reloading?(this.xhr.onabort=null,this.xhr.abort()):this.image&&this.stop()}}],[{key:"noConflict",value:function(){return window.Cropper=VZ,D}},{key:"setDefaults",value:function(C){Si(e9,by(C)&&C)}}])}();Si(q9.prototype,FZ,IZ,zZ,$Z,LZ,HZ);const UZ=["src","alt","crossorigin"],G9=Ls({name:"CropperImage",__name:"Cropper",props:{src:{type:String,required:!0},alt:{type:String},circled:{type:Boolean,default:!1},realTimePreview:{type:Boolean,default:!0},height:{type:[String,Number],default:"360px"},crossorigin:{type:String,default:void 0},imageStyle:{type:Object,default:()=>({})},options:{type:Object,default:()=>({})}},emits:["cropend","ready","cropendError"],setup(D,{emit:y}){const C={aspectRatio:1,zoomable:!0,zoomOnTouch:!0,zoomOnWheel:!0,cropBoxMovable:!0,cropBoxResizable:!0,toggleDragModeOnDblclick:!0,autoCrop:!0,background:!0,highlight:!0,center:!0,responsive:!0,restore:!0,checkCrossOrigin:!0,checkOrientation:!0,scalable:!0,modal:!0,guides:!0,movable:!0,rotatable:!0},S=D,_=y,M=o9(),z=Ea(),K=Ea(),Y=Ea(!1),{prefixCls:ye}=Fg("cropper-image"),Q=a9(ae,80),W=ki(()=>Ci({height:S.height,maxWidth:"100%"},S.imageStyle)),ve=ki(()=>[ye,M.class,{[`${ye}--circled`]:S.circled}]),he=ki(()=>({height:`${S.height}`.replace(/px/,"")+"px"}));fL(be),rX(()=>{var Ve;(Ve=K.value)==null||Ve.destroy()});function be(){return zc(this,null,function*(){const Ve=mn(z);Ve&&(K.value=new q9(Ve,Ci(Ic(Ci({},C),{ready:()=>{Y.value=!0,ae(),_("ready",K.value)},crop(){Q()},zoom(){Q()},cropmove(){Q()}}),S.options)))})}function ae(){S.realTimePreview&&Ae()}function Ae(){if(!K.value)return;let Ve=K.value.getData();(S.circled?Ye():K.value.getCroppedCanvas()).toBlob(_e=>{if(!_e)return;let Te=new FileReader;Te.readAsDataURL(_e),Te.onloadend=Be=>{var gt,Se;_("cropend",{imgBase64:(Se=(gt=Be.target)==null?void 0:gt.result)!=null?Se:"",imgInfo:Ve})},Te.onerror=()=>{_("cropendError")}},"image/png")}function Ye(){const Ve=K.value.getCroppedCanvas(),L=document.createElement("canvas"),_e=L.getContext("2d"),Te=Ve.width,Be=Ve.height;return L.width=Te,L.height=Be,_e.imageSmoothingEnabled=!0,_e.drawImage(Ve,0,0,Te,Be),_e.globalCompositeOperation="destination-in",_e.beginPath(),_e.arc(Te/2,Be/2,Math.min(Te,Be)/2,0,2*Math.PI,!0),_e.fill(),L}return(Ve,L)=>(Ha(),ms("div",{class:Xu(ve.value),style:Bg(he.value)},[g9($s("img",{ref_key:"imgElRef",ref:z,src:D.src,alt:D.alt,crossorigin:D.crossorigin,style:Bg(W.value)},null,12,UZ),[[h9,Y.value]])],6))}}),WZ=["src","alt"],jZ=Ls({name:"CropperModal",__name:"CropperModal",props:{circled:{type:Boolean,default:!0},uploadApi:{type:Function},src:{type:String},size:{type:Number}},emits:["uploadSuccess","uploadError","register"],setup(D,{emit:y}){const C=D,S=y;let _="";const M=Ea(C.src||""),z=Ea(""),K=Ea();let Y=1,ye=1;const{prefixCls:Q}=Fg("cropper-am"),[W,{closeModal:ve,setModalProps:he}]=cX(),{t:be}=Rp();function ae(_e){if(C.size&&_e.size>1024*1024*C.size)return S("uploadError",{msg:be("component.cropper.imageTooBig")}),!1;const Te=new FileReader;return Te.readAsDataURL(_e),M.value="",z.value="",Te.onload=function(Be){var gt,Se;M.value=(Se=(gt=Be.target)==null?void 0:gt.result)!=null?Se:"",_=_e.name},!1}function Ae({imgBase64:_e}){z.value=_e}function Ye(_e){K.value=_e}function Ve(_e,Te){var Be,gt;_e==="scaleX"&&(Y=Te=Y===-1?1:-1),_e==="scaleY"&&(ye=Te=ye===-1?1:-1),(gt=(Be=K==null?void 0:K.value)==null?void 0:Be[_e])==null||gt.call(Be,Te)}function L(){return zc(this,null,function*(){const _e=C.uploadApi;if(_e&&Pi(_e)){const Te=BX(z.value);try{he({confirmLoading:!0});const Be=yield _e({name:"file",file:Te,filename:_});S("uploadSuccess",{source:z.value,data:Be.url}),ve()}finally{he({confirmLoading:!1})}}})}return(_e,Te)=>{const Be=Mp("a-button");return Ha(),ou(mn(fX),pf(_e.$attrs,{onRegister:mn(W),title:mn(be)("component.cropper.modalTitle"),width:"800px",canFullscreen:!1,onOk:L,okText:mn(be)("component.cropper.okText")}),{default:qa(()=>[$s("div",{class:Xu(mn(Q))},[$s("div",{class:Xu(`${mn(Q)}-left`)},[$s("div",{class:Xu(`${mn(Q)}-cropper`)},[M.value?(Ha(),ou(G9,{key:0,src:M.value,height:"300px",circled:D.circled,onCropend:Ae,onReady:Ye},null,8,["src","circled"])):Md("",!0)],2),$s("div",{class:Xu(`${mn(Q)}-toolbar`)},[Fa(mn(v9),{fileList:[],accept:"image/*",beforeUpload:ae},{default:qa(()=>[Fa(mn(_g),{title:mn(be)("component.cropper.selectImage"),placement:"bottom"},{default:qa(()=>[Fa(Be,{size:"small",preIcon:"ant-design:upload-outlined",type:"primary"})]),_:1},8,["title"])]),_:1}),Fa(mn(GK),null,{default:qa(()=>[Fa(mn(_g),{title:mn(be)("component.cropper.btn_reset"),placement:"bottom"},{default:qa(()=>[Fa(Be,{type:"primary",preIcon:"ant-design:reload-outlined",size:"small",disabled:!M.value,onClick:Te[0]||(Te[0]=gt=>Ve("reset"))},null,8,["disabled"])]),_:1},8,["title"]),Fa(mn(_g),{title:mn(be)("component.cropper.btn_rotate_left"),placement:"bottom"},{default:qa(()=>[Fa(Be,{type:"primary",preIcon:"ant-design:rotate-left-outlined",size:"small",disabled:!M.value,onClick:Te[1]||(Te[1]=gt=>Ve("rotate",-45))},null,8,["disabled"])]),_:1},8,["title"]),Fa(mn(_g),{title:mn(be)("component.cropper.btn_rotate_right"),placement:"bottom"},{default:qa(()=>[Fa(Be,{type:"primary",preIcon:"ant-design:rotate-right-outlined",size:"small",disabled:!M.value,onClick:Te[2]||(Te[2]=gt=>Ve("rotate",45))},null,8,["disabled"])]),_:1},8,["title"]),Fa(mn(_g),{title:mn(be)("component.cropper.btn_scale_x"),placement:"bottom"},{default:qa(()=>[Fa(Be,{type:"primary",preIcon:"vaadin:arrows-long-h",size:"small",disabled:!M.value,onClick:Te[3]||(Te[3]=gt=>Ve("scaleX"))},null,8,["disabled"])]),_:1},8,["title"]),Fa(mn(_g),{title:mn(be)("component.cropper.btn_scale_y"),placement:"bottom"},{default:qa(()=>[Fa(Be,{type:"primary",preIcon:"vaadin:arrows-long-v",size:"small",disabled:!M.value,onClick:Te[4]||(Te[4]=gt=>Ve("scaleY"))},null,8,["disabled"])]),_:1},8,["title"]),Fa(mn(_g),{title:mn(be)("component.cropper.btn_zoom_in"),placement:"bottom"},{default:qa(()=>[Fa(Be,{type:"primary",preIcon:"ant-design:zoom-in-outlined",size:"small",disabled:!M.value,onClick:Te[5]||(Te[5]=gt=>Ve("zoom",.1))},null,8,["disabled"])]),_:1},8,["title"]),Fa(mn(_g),{title:mn(be)("component.cropper.btn_zoom_out"),placement:"bottom"},{default:qa(()=>[Fa(Be,{type:"primary",preIcon:"ant-design:zoom-out-outlined",size:"small",disabled:!M.value,onClick:Te[6]||(Te[6]=gt=>Ve("zoom",-.1))},null,8,["disabled"])]),_:1},8,["title"])]),_:1})],2)],2),$s("div",{class:Xu(`${mn(Q)}-right`)},[$s("div",{class:Xu(`${mn(Q)}-preview`)},[z.value?(Ha(),ms("img",{key:0,src:z.value,alt:mn(be)("component.cropper.preview")},null,8,WZ)):Md("",!0)],2),z.value?(Ha(),ms("div",{key:0,class:Xu(`${mn(Q)}-group`)},[Fa(mn(nM),{src:z.value,size:"large"},null,8,["src"]),Fa(mn(nM),{src:z.value,size:48},null,8,["src"]),Fa(mn(nM),{src:z.value,size:64},null,8,["src"]),Fa(mn(nM),{src:z.value,size:80},null,8,["src"])],2)):Md("",!0)],2)],2)]),_:1},16,["onRegister","title","okText"])}}}),qZ=["src"],GZ=Ls({name:"CropperAvatar",__name:"CropperAvatar",props:{width:{type:[String,Number],default:"200px"},value:{type:String},showBtn:{type:Boolean,default:!0},btnProps:{type:Object},btnText:{type:String,default:""},uploadApi:{type:Function},size:{type:Number,default:5}},emits:["update:value","change"],setup(D,{expose:y,emit:C}){const S=D,_=C,M=Ea(S.value||""),{prefixCls:z}=Fg("cropper-avatar"),[K,{openModal:Y,closeModal:ye}]=vX(),{createMessage:Q}=i9(),{t:W}=Rp(),ve=ki(()=>[z]),he=ki(()=>`${S.width}`.replace(/px/,"")+"px"),be=ki(()=>parseInt(`${S.width}`.replace(/px/,""))/2+"px"),ae=ki(()=>({width:mn(he)})),Ae=ki(()=>({width:mn(he),height:mn(he)}));vk(()=>{M.value=S.value||""}),Nu(()=>M.value,Ve=>{_("update:value",Ve)});function Ye({source:Ve,data:L}){M.value=Ve,_("change",{source:Ve,data:L}),Q.success(W("component.cropper.uploadSuccess"))}return y({openModal:Y.bind(null,!0),closeModal:ye}),(Ve,L)=>{const _e=Mp("a-button");return Ha(),ms("div",{class:Xu(ve.value),style:Bg(ae.value)},[$s("div",{class:Xu(`${mn(z)}-image-wrapper`),style:Bg(Ae.value),onClick:L[0]||(L[0]=Te=>mn(Y)())},[$s("div",{class:Xu(`${mn(z)}-image-mask`),style:Bg(Ae.value)},[Fa(Y$,{icon:"ant-design:cloud-upload-outlined",size:be.value,style:Bg(Ae.value),color:"#d6d6d6"},null,8,["size","style"])],6),M.value?(Ha(),ms("img",{key:0,src:M.value,alt:"avatar"},null,8,qZ)):Md("",!0)],6),D.showBtn?(Ha(),ou(_e,pf({key:0,class:`${mn(z)}-upload-btn`,onClick:mn(Y)},D.btnProps),{default:qa(()=>[Ng(Bp(D.btnText?D.btnText:mn(W)("component.cropper.selectImage")),1)]),_:1},16,["class","onClick"])):Md("",!0),Fa(jZ,{onRegister:mn(K),onUploadSuccess:Ye,uploadApi:D.uploadApi,src:M.value,size:D.size},null,8,["onRegister","uploadApi","src","size"])],6)}}}),KZ=sM(GZ,[["__scopeId","data-v-5bf52be3"]]);Np(G9);const XZ=Np(KZ);var K9={exports:{}};(function(D){(function(){var y=function(e){if(e===null)return"null";if(e===void 0)return"undefined";var n=typeof e;return n==="object"&&(Array.prototype.isPrototypeOf(e)||e.constructor&&e.constructor.name==="Array")?"array":n==="object"&&(String.prototype.isPrototypeOf(e)||e.constructor&&e.constructor.name==="String")?"string":n},C=function(e){return["undefined","boolean","number","string","function","xml","null"].indexOf(e)!==-1},S=function(e,n){var a=Array.prototype.slice.call(e);return a.sort(n)},_=function(e,n){return M(function(a,i){return e.eq(n(a),n(i))})},M=function(e){return{eq:e}},z=M(function(e,n){return e===n}),K=z,Y=function(e){return M(function(n,a){if(n.length!==a.length)return!1;for(var i=n.length,s=0;s-1},ft=function(e,n){for(var a=0,i=e.length;a=0;a--){var i=e[a];n(i,a)}},jn=function(e,n){for(var a=[],i=[],s=0,l=e.length;s=0&&n=n.length&&e.substr(a,a+n.length)===n},ut=function(e,n){return R(e,n)?oe(e,n.length):e},At=function(e,n){return e.indexOf(n)!==-1},R=function(e,n){return pe(e,n,0)},Z=function(e){return function(n){return n.replace(e,"")}},me=Z(/^\s+|\s+$/g),Me=Z(/^\s+/g),Qe=Z(/\s+$/g),rt=function(e){return e.length>0},ln=function(e){return!rt(e)},On=/.*?version\/\ ?([0-9]+)\.([0-9]+).*/,ir=function(e){return function(n){return At(n,e)}},fr=[{name:"Edge",versionRegexes:[/.*?edge\/ ?([0-9]+)\.([0-9]+)$/],search:function(e){return At(e,"edge/")&&At(e,"chrome")&&At(e,"safari")&&At(e,"applewebkit")}},{name:"Chrome",brand:"Chromium",versionRegexes:[/.*?chrome\/([0-9]+)\.([0-9]+).*/,On],search:function(e){return At(e,"chrome")&&!At(e,"chromeframe")}},{name:"IE",versionRegexes:[/.*?msie\ ?([0-9]+)\.([0-9]+).*/,/.*?rv:([0-9]+)\.([0-9]+).*/],search:function(e){return At(e,"msie")||At(e,"trident")}},{name:"Opera",versionRegexes:[On,/.*?opera\/([0-9]+)\.([0-9]+).*/],search:ir("opera")},{name:"Firefox",versionRegexes:[/.*?firefox\/\ ?([0-9]+)\.([0-9]+).*/],search:ir("firefox")},{name:"Safari",versionRegexes:[On,/.*?cpu os ([0-9]+)_([0-9]+).*/],search:function(e){return(At(e,"safari")||At(e,"mobile/"))&&At(e,"applewebkit")}}],mr=[{name:"Windows",search:ir("win"),versionRegexes:[/.*?windows\ nt\ ?([0-9]+)\.([0-9]+).*/]},{name:"iOS",search:function(e){return At(e,"iphone")||At(e,"ipad")},versionRegexes:[/.*?version\/\ ?([0-9]+)\.([0-9]+).*/,/.*cpu os ([0-9]+)_([0-9]+).*/,/.*cpu iphone os ([0-9]+)_([0-9]+).*/]},{name:"Android",search:ir("android"),versionRegexes:[/.*?android\ ?([0-9]+)\.([0-9]+).*/]},{name:"OSX",search:ir("mac os x"),versionRegexes:[/.*?mac\ os\ x\ ?([0-9]+)_([0-9]+).*/]},{name:"Linux",search:ir("linux"),versionRegexes:[]},{name:"Solaris",search:ir("sunos"),versionRegexes:[]},{name:"FreeBSD",search:ir("freebsd"),versionRegexes:[]},{name:"ChromeOS",search:ir("cros"),versionRegexes:[/.*?chrome\/([0-9]+)\.([0-9]+).*/]}],Tr={browsers:xe(fr),oses:xe(mr)},ia="Edge",eo="Chrome",ko="IE",Ri="Opera",Ti="Firefox",to="Safari",hu=function(){return iu({current:void 0,version:Re.unknown()})},iu=function(e){var n=e.current,a=e.version,i=function(s){return function(){return n===s}};return{current:n,version:a,isEdge:i(ia),isChrome:i(eo),isIE:i(ko),isOpera:i(Ri),isFirefox:i(Ti),isSafari:i(to)}},Qo={unknown:hu,nu:iu,edge:xe(ia),chrome:xe(eo),ie:xe(ko),opera:xe(Ri),firefox:xe(Ti),safari:xe(to)},Eo="Windows",Fu="iOS",J="Android",Oe="Linux",tt="OSX",_t="Solaris",kn="FreeBSD",$n="ChromeOS",rr=function(){return Yr({current:void 0,version:Re.unknown()})},Yr=function(e){var n=e.current,a=e.version,i=function(s){return function(){return n===s}};return{current:n,version:a,isWindows:i(Eo),isiOS:i(Fu),isAndroid:i(J),isOSX:i(tt),isLinux:i(Oe),isSolaris:i(_t),isFreeBSD:i(kn),isChromeOS:i($n)}},U={unknown:rr,nu:Yr,windows:xe(Eo),ios:xe(Fu),android:xe(J),linux:xe(Oe),osx:xe(tt),solaris:xe(_t),freebsd:xe(kn),chromeos:xe($n)},ke=function(e,n,a){var i=Tr.browsers(),s=Tr.oses(),l=n.bind(function(g){return ce(i,g)}).orThunk(function(){return dn(i,e)}).fold(Qo.unknown,Qo.nu),v=Mn(s,e).fold(U.unknown,U.nu),m=oo(v,l,e,a);return{browser:l,os:v,deviceType:m}},Le={detect:ke},mt=function(e){return window.matchMedia(e).matches},Pt=So(function(){return Le.detect(navigator.userAgent,X.from(navigator.userAgentData),mt)}),Dn=function(){return Pt()},Jn=navigator.userAgent,ea=Dn(),Pr=ea.browser,va=ea.os,Ra=ea.deviceType,Ui=/WebKit/.test(Jn)&&!Pr.isEdge(),Yu="FormData"in window&&"FileReader"in window&&"URL"in window&&!!URL.createObjectURL,cr=Jn.indexOf("Windows Phone")!==-1,an={opera:Pr.isOpera(),webkit:Ui,ie:Pr.isIE()||Pr.isEdge()?Pr.version.major:!1,gecko:Pr.isFirefox(),mac:va.isOSX()||va.isiOS(),iOS:Ra.isiPad()||Ra.isiPhone(),android:va.isAndroid(),contentEditable:!0,transparentSrc:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",caretAfter:!0,range:window.getSelection&&"Range"in window,documentMode:Pr.isIE()?document.documentMode||7:10,fileApi:Yu,ceFalse:!0,cacheSuffix:null,container:null,experimentalShadowDom:!1,canHaveCSP:!Pr.isIE(),desktop:Ra.isDesktop(),windowsPhone:cr,browser:{current:Pr.current,version:Pr.version,isChrome:Pr.isChrome,isEdge:Pr.isEdge,isFirefox:Pr.isFirefox,isIE:Pr.isIE,isOpera:Pr.isOpera,isSafari:Pr.isSafari},os:{current:va.current,version:va.version,isAndroid:va.isAndroid,isChromeOS:va.isChromeOS,isFreeBSD:va.isFreeBSD,isiOS:va.isiOS,isLinux:va.isLinux,isOSX:va.isOSX,isSolaris:va.isSolaris,isWindows:va.isWindows},deviceType:{isDesktop:Ra.isDesktop,isiPad:Ra.isiPad,isiPhone:Ra.isiPhone,isPhone:Ra.isPhone,isTablet:Ra.isTablet,isTouch:Ra.isTouch,isWebView:Ra.isWebView}},pa=/^\s*|\s*$/g,yo=function(e){return e==null?"":(""+e).replace(pa,"")},qo=function(e,n){return n?n==="array"&&Va(e)?!0:typeof e===n:e!==void 0},gs=function(e,n,a){var i;for(e=e||[],n=n||",",typeof e=="string"&&(e=e.split(n)),a=a||{},i=e.length;i--;)a[e[i]]={};return a},hs=xr,Hs=function(e,n,a){var i=this,s,l,v,m=0;e=/^((static) )?([\w.]+)(:([\w.]+))?/.exec(e);var g=e[3].match(/(^|\.)(\w+)$/i)[2],E=i.createNS(e[3].replace(/\.\w+$/,""),a);if(!E[g]){if(e[2]==="static"){E[g]=n,this.onCreate&&this.onCreate(e[2],e[3],E[g]);return}n[g]||(n[g]=function(){},m=1),E[g]=n[g],i.extend(E[g].prototype,n),e[5]&&(s=i.resolve(e[5]).prototype,l=e[5].match(/\.(\w+)$/i)[1],v=E[g],m?E[g]=function(){return s[l].apply(this,arguments)}:E[g]=function(){return this.parent=s[l],v.apply(this,arguments)},E[g].prototype[g]=E[g],i.each(s,function(N,F){E[g].prototype[F]=s[F]}),i.each(n,function(N,F){s[F]?E[g].prototype[F]=function(){return this.parent=s[F],N.apply(this,arguments)}:F!==g&&(E[g].prototype[F]=N)})),i.each(n.static,function(N,F){E[g][F]=N})}},_a=function(e){for(var n=[],a=1;a1)throw new Error("HTML must have a single root node");return Zu(i.childNodes[0])},Lo=function(e,n){var a=n||document,i=a.createElement(e);return Zu(i)},El=function(e,n){var a=n||document,i=a.createTextNode(e);return Zu(i)},Zu=function(e){if(e==null)throw new Error("Node cannot be null or undefined");return{dom:e}},B=function(e,n,a){return X.from(e.dom.elementFromPoint(n,a)).map(Zu)},w={fromHtml:ps,fromTag:Lo,fromText:El,fromDom:Zu,fromPoint:B},h=function(e,n){var a=[],i=function(l){return a.push(l),n(l)},s=n(e);do s=s.bind(i);while(s.isSome());return a},T=function(e,n,a){return(e.compareDocumentPosition(n)&a)!==0},H=function(e,n){return T(e,n,Node.DOCUMENT_POSITION_CONTAINED_BY)},ue=8,He=9,Nt=11,Kn=1,vr=3,wn=function(e,n){var a=e.dom;if(a.nodeType!==Kn)return!1;var i=a;if(i.matches!==void 0)return i.matches(n);if(i.msMatchesSelector!==void 0)return i.msMatchesSelector(n);if(i.webkitMatchesSelector!==void 0)return i.webkitMatchesSelector(n);if(i.mozMatchesSelector!==void 0)return i.mozMatchesSelector(n);throw new Error("Browser lacks native selectors")},qn=function(e){return e.nodeType!==Kn&&e.nodeType!==He&&e.nodeType!==Nt||e.childElementCount===0},Rr=function(e,n){var a=n===void 0?document:n.dom;return qn(a)?[]:zt(a.querySelectorAll(e),w.fromDom)},Wr=function(e,n){var a=n===void 0?document:n.dom;return qn(a)?X.none():X.from(a.querySelector(e)).map(w.fromDom)},Sr=function(e,n){return e.dom===n.dom},Ua=function(e,n){var a=e.dom,i=n.dom;return a===i?!1:a.contains(i)},wr=function(e,n){return H(e.dom,n.dom)},Aa=function(e,n){return Dn().browser.isIE()?wr(e,n):Ua(e,n)};typeof window!="undefined"||Function("return this;")();var Sa=function(e){var n=e.dom.nodeName;return n.toLowerCase()},ji=function(e){return e.dom.nodeType},qr=function(e){return function(n){return ji(n)===e}},Pd=function(e){return ji(e)===ue||Sa(e)==="#comment"},vo=qr(Kn),Ho=qr(vr),zp=qr(He),Ai=qr(Nt),Ig=function(e){return function(n){return vo(n)&&Sa(n)===e}},Rd=function(e){return w.fromDom(e.dom.ownerDocument)},Mr=function(e){return zp(e)?e:Rd(e)},Tl=function(e){return w.fromDom(Mr(e).dom.documentElement)},vc=function(e){return w.fromDom(Mr(e).dom.defaultView)},Fo=function(e){return X.from(e.dom.parentNode).map(w.fromDom)},$p=function(e,n){for(var a=Se(n)?n:Kt,i=e.dom,s=[];i.parentNode!==null&&i.parentNode!==void 0;){var l=i.parentNode,v=w.fromDom(l);if(s.push(v),a(v)===!0)break;i=l}return s},Oi=function(e){var n=function(a){return Ce(a,function(i){return!Sr(e,i)})};return Fo(e).map(pu).map(n).getOr([])},Lc=function(e){return X.from(e.dom.previousSibling).map(w.fromDom)},bf=function(e){return X.from(e.dom.nextSibling).map(w.fromDom)},Ia=function(e){return Vt(h(e,Lc))},Hc=function(e){return h(e,bf)},pu=function(e){return zt(e.dom.childNodes,w.fromDom)},Vc=function(e,n){var a=e.dom.childNodes;return X.from(a[n]).map(w.fromDom)},ti=function(e){return Vc(e,0)},bs=function(e){return Vc(e,e.dom.childNodes.length-1)},Lp=function(e){return e.dom.childNodes.length},Uc=function(e){var n=e.dom.head;if(n==null)throw new Error("Head is not available yet");return w.fromDom(n)},Ka=function(e){return Ai(e)&>(e.dom.host)},yf=Se(Element.prototype.attachShadow)&&Se(Node.prototype.getRootNode),Wc=xe(yf),bu=yf?function(e){return w.fromDom(e.dom.getRootNode())}:Mr,jc=function(e){return Ka(e)?e:Uc(Mr(e))},Nd=function(e){var n=bu(e);return Ka(n)?X.some(n):X.none()},Hp=function(e){return w.fromDom(e.dom.host)},uu=function(e){if(Wc()&>(e.target)){var n=w.fromDom(e.target);if(vo(n)&&dc(n)&&e.composed&&e.composedPath){var a=e.composedPath();if(a)return Xt(a)}}return X.from(e.target)},dc=function(e){return gt(e.dom.shadowRoot)},Us=function(e,n){var a=Fo(e);a.each(function(i){i.dom.insertBefore(n.dom,e.dom)})},wf=function(e,n){var a=bf(e);a.fold(function(){var i=Fo(e);i.each(function(s){Ni(s,n)})},function(i){Us(i,n)})},zg=function(e,n){var a=ti(e);a.fold(function(){Ni(e,n)},function(i){e.dom.insertBefore(n.dom,i.dom)})},Ni=function(e,n){e.dom.appendChild(n.dom)},Fd=function(e,n){Us(e,n),Ni(n,e)},Ay=function(e,n){vt(n,function(a){Us(e,a)})},Id=function(e,n){vt(n,function(a){Ni(e,a)})},$g=function(e){e.dom.textContent="",vt(pu(e),function(n){Io(n)})},Io=function(e){var n=e.dom;n.parentNode!==null&&n.parentNode.removeChild(n)},zd=function(e){var n=pu(e);n.length>0&&Ay(e,n),Io(e)},kv=function(e){var n=Ho(e)?e.dom.parentNode:e.dom;if(n==null||n.ownerDocument===null)return!1;var a=n.ownerDocument;return Nd(w.fromDom(n)).fold(function(){return a.body.contains(n)},G(kv,Hp))},qi=function(e,n){var a=function(i,s){return qi(e+i,n+s)};return{left:e,top:n,translate:a}},qc=qi,Oy=function(e){var n=e.getBoundingClientRect();return qc(n.left,n.top)},Gc=function(e,n){return e!==void 0?e:n!==void 0?n:0},$d=function(e){var n=e.dom.ownerDocument,a=n.body,i=n.defaultView,s=n.documentElement;if(a===e.dom)return qc(a.offsetLeft,a.offsetTop);var l=Gc(i==null?void 0:i.pageYOffset,s.scrollTop),v=Gc(i==null?void 0:i.pageXOffset,s.scrollLeft),m=Gc(s.clientTop,a.clientTop),g=Gc(s.clientLeft,a.clientLeft);return ys(e).translate(v-g,l-m)},ys=function(e){var n=e.dom,a=n.ownerDocument,i=a.body;return i===n?qc(i.offsetLeft,i.offsetTop):kv(e)?Oy(n):qc(0,0)},Lg=function(e){var n=e!==void 0?e.dom:document,a=n.body.scrollLeft||n.documentElement.scrollLeft,i=n.body.scrollTop||n.documentElement.scrollTop;return qc(a,i)},ws=function(e,n,a){var i=a!==void 0?a.dom:document,s=i.defaultView;s&&s.scrollTo(e,n)},Ld=function(e,n){var a=Dn().browser.isSafari();a&&Se(e.dom.scrollIntoViewIfNeeded)?e.dom.scrollIntoViewIfNeeded(!1):e.dom.scrollIntoView(n)},Dy=function(e){var n=e===void 0?window:e;return Dn().browser.isFirefox()?X.none():X.from(n.visualViewport)},Hg=function(e,n,a,i){return{x:e,y:n,width:a,height:i,right:e+a,bottom:n+i}},Ev=function(e){var n=e===void 0?window:e,a=n.document,i=Lg(w.fromDom(a));return Dy(n).fold(function(){var s=n.document.documentElement,l=s.clientWidth,v=s.clientHeight;return Hg(i.left,i.top,l,v)},function(s){return Hg(Math.max(s.pageLeft,i.left),Math.max(s.pageTop,i.top),s.width,s.height)})},Cf=function(e){return function(n){return!!n&&n.nodeType===e}},Hd=function(e){return!!e&&!Object.getPrototypeOf(e)},Br=Cf(1),Cs=function(e){var n=e.map(function(a){return a.toLowerCase()});return function(a){if(a&&a.nodeName){var i=a.nodeName.toLowerCase();return We(n,i)}return!1}},Vd=function(e,n){var a=n.toLowerCase().split(" ");return function(i){if(Br(i))for(var s=0;s0})},Up=function(e){var n={},a=e.dom;if(mo(a))for(var i=0;i=e.length&&a(i)}};e.length===0?a([]):vt(e,function(v,m){v.get(l(m))})})},wM=function(e){return yM(e,Iy.nu)},qd=function(e){var n=function(F){return qd(e)},a=function(F){return qd(e)},i=function(F){return qd(F(e))},s=function(F){return qd(e)},l=function(F){F(e)},v=function(F){return F(e)},m=function(F,$){return $(e)},g=function(F){return F(e)},E=function(F){return F(e)},N=function(){return X.some(e)};return{isValue:Rn,isError:Kt,getOr:xe(e),getOrThunk:xe(e),getOrDie:xe(e),or:n,orThunk:a,fold:m,map:i,mapError:s,each:l,bind:v,exists:g,forall:E,toOptional:N}},jg=function(e){var n=function(E){return E()},a=function(){return Er(String(e))()},i=ct,s=function(E){return E()},l=function(E){return jg(e)},v=function(E){return jg(E(e))},m=function(E){return jg(e)},g=function(E,N){return E(e)};return{isValue:Kt,isError:Rn,getOr:ct,getOrThunk:n,getOrDie:a,or:i,orThunk:s,fold:g,map:l,mapError:v,each:Ze,bind:m,exists:Kt,forall:Rn,toOptional:X.none}},yk=function(e,n){return e.fold(function(){return jg(n)},qd)},wk={value:qd,error:jg,fromOption:yk},Ss=function(e){if(!Ve(e))throw new Error("cases must be an array");if(e.length===0)throw new Error("there must be at least one case");var n=[],a={};return vt(e,function(i,s){var l=$t(i);if(l.length!==1)throw new Error("one and only one name per case");var v=l[0],m=i[v];if(a[v]!==void 0)throw new Error("duplicate key detected:"+v);if(v==="cata")throw new Error("cannot have a case named cata (sorry)");if(!Ve(m))throw new Error("case arguments must be an array");n.push(v),a[v]=function(){for(var g=[],E=0;E0?ge(qe.fail.map(Yc)):we(qe.pass.map(Yc))})},ne=function(ie){var we=Tt._addCacheSuffix(ie);Ar(i,we).each(function(ge){var Je=--ge.count;Je===0&&(delete i[we],E(ge.id))})},re=function(ie){vt(ie,function(we){ne(we)})};return{load:F,loadAll:ee,unload:ne,unloadAll:re,_setReferrerPolicy:m}},To=function(){var e=new WeakMap,n=function(a,i){var s=bu(a),l=s.dom;return X.from(e.get(l)).getOrThunk(function(){var v=Sk(l,i);return e.set(l,v),v})};return{forElement:n}},Dl=To(),Wa=function(){function e(n,a){this.node=n,this.rootNode=a,this.current=this.current.bind(this),this.next=this.next.bind(this),this.prev=this.prev.bind(this),this.prev2=this.prev2.bind(this)}return e.prototype.current=function(){return this.node},e.prototype.next=function(n){return this.node=this.findSibling(this.node,"firstChild","nextSibling",n),this.node},e.prototype.prev=function(n){return this.node=this.findSibling(this.node,"lastChild","previousSibling",n),this.node},e.prototype.prev2=function(n){return this.node=this.findPreviousNode(this.node,"lastChild","previousSibling",n),this.node},e.prototype.findSibling=function(n,a,i,s){var l,v;if(n){if(!s&&n[a])return n[a];if(n!==this.rootNode){if(l=n[i],l)return l;for(v=n.parentNode;v&&v!==this.rootNode;v=v.parentNode)if(l=v[i],l)return l}}},e.prototype.findPreviousNode=function(n,a,i,s){var l,v,m;if(n){if(l=n[i],this.rootNode&&l===this.rootNode)return;if(l){if(!s){for(m=l[a];m;m=m[a])if(!m[a])return m}return l}if(v=n.parentNode,v&&v!==this.rootNode)return v}},e}(),Xd=["article","aside","details","div","dt","figcaption","footer","form","fieldset","header","hgroup","html","main","nav","section","summary","body","p","dl","multicol","dd","figure","address","center","blockquote","h1","h2","h3","h4","h5","h6","listing","xmp","pre","plaintext","menu","dir","ul","ol","li","hr","table","tbody","thead","tfoot","th","tr","td","caption"],Ws=["td","th"],xM=["thead","tbody","tfoot"],hi=["h1","h2","h3","h4","h5","h6","p","div","address","pre","form","blockquote","center","dir","fieldset","header","footer","article","section","hgroup","aside","nav","figure"],$u=["h1","h2","h3","h4","h5","h6"],kk=["li","dd","dt"],jt=["ul","ol","dl"],Ju=["pre","script","textarea","style"],xf=function(e){var n;return function(a){return n=n||Bt(e,Rn),xr(n,Sa(a))}},Or=xf($u),js=xf(Xd),SM=function(e){return Sa(e)==="table"},cu=function(e){return vo(e)&&!js(e)},Yd=function(e){return vo(e)&&Sa(e)==="br"},Zc=xf(hi),qp=xf(jt),yu=xf(kk),Oa=xf(xM),_l=xf(Ws),Kg=xf(Ju),no=function(e,n,a){return Av(e,n,a).isSome()},Ov="\uFEFF",Qu=" ",ks=function(e){return e===Ov},kM=function(e){return e.replace(/\uFEFF/g,"")},$e=Ov,es=ks,ts=kM,Zd=Br,qs=Wn,Ao=function(e){return qs(e)&&(e=e.parentNode),Zd(e)&&e.hasAttribute("data-mce-caret")},Xa=function(e){return qs(e)&&es(e.data)},Gs=function(e){return Ao(e)||Xa(e)},Xg=function(e){return e.firstChild!==e.lastChild||!za(e.firstChild)},Hy=function(e,n){var a=e.ownerDocument,i=a.createTextNode($e),s=e.parentNode;if(n){var l=e.previousSibling;if(qs(l)){if(Gs(l))return l;if(Kp(l))return l.splitText(l.data.length-1)}s.insertBefore(i,e)}else{var l=e.nextSibling;if(qs(l)){if(Gs(l))return l;if(Gp(l))return l.splitText(1),l}e.nextSibling?s.insertBefore(i,e.nextSibling):s.appendChild(i)}return i},Cr=function(e){var n=e.container();return Wn(n)?n.data.charAt(e.offset())===$e||e.isAtStart()&&Xa(n.previousSibling):!1},Vy=function(e){var n=e.container();return Wn(n)?n.data.charAt(e.offset()-1)===$e||e.isAtEnd()&&Xa(n.nextSibling):!1},Ks=function(){var e=document.createElement("br");return e.setAttribute("data-mce-bogus","1"),e},EM=function(e,n,a){var i=n.ownerDocument,s=i.createElement(e);s.setAttribute("data-mce-caret",a?"before":"after"),s.setAttribute("data-mce-bogus","all"),s.appendChild(Ks());var l=n.parentNode;return a?l.insertBefore(s,n):n.nextSibling?l.insertBefore(s,n.nextSibling):l.appendChild(s),s},Gp=function(e){return qs(e)&&e.data[0]===$e},Kp=function(e){return qs(e)&&e.data[e.data.length-1]===$e},TM=function(e){var n=e.getElementsByTagName("br"),a=n[n.length-1];Kc(a)&&a.parentNode.removeChild(a)},Uy=function(e){return e&&e.hasAttribute("data-mce-caret")?(TM(e),e.removeAttribute("data-mce-caret"),e.removeAttribute("data-mce-bogus"),e.removeAttribute("style"),e.removeAttribute("_moz_abspos"),e):null},gc=function(e){return Ao(e.startContainer)},Dv=ul,AM=so,OM=za,DM=Wn,Ek=Cs(["script","style","textarea"]),Wy=Cs(["img","input","textarea","hr","iframe","video","audio","object","embed"]),jy=Cs(["table"]),Tk=Gs,hc=function(e){return Tk(e)?!1:DM(e)?!Ek(e.parentNode):Wy(e)||OM(e)||jy(e)||qy(e)},Jd=function(e){return Br(e)&&e.getAttribute("unselectable")==="true"},qy=function(e){return Jd(e)===!1&&AM(e)},_M=function(e,n){for(e=e.parentNode;e&&e!==n;e=e.parentNode){if(qy(e))return!1;if(Dv(e))return!0}return!0},MM=function(e){return qy(e)?pn(Jt(e.getElementsByTagName("*")),function(n,a){return n||Dv(a)},!1)!==!0:!1},BM=function(e){return Wy(e)||MM(e)},ni=function(e,n){return hc(e)&&_M(e,n)},Jc=/^[ \t\r\n]*$/,Ml=function(e){return Jc.test(e)},Yg=function(e,n){var a=w.fromDom(n),i=w.fromDom(e);return no(i,"pre,code",bt(Sr,a))},Ak=function(e,n){return Wn(e)&&Ml(e.data)&&Yg(e,n)===!1},sl=function(e){return Br(e)&&e.nodeName==="A"&&!e.hasAttribute("href")&&(e.hasAttribute("name")||e.hasAttribute("id"))},_v=function(e,n){return hc(e)&&Ak(e,n)===!1||sl(e)||Gy(e)},Gy=Ud("data-mce-bookmark"),Ky=Ud("data-mce-bogus"),Sf=_y("data-mce-bogus","all"),kf=function(e,n){var a=0;if(_v(e,e))return!1;var i=e.firstChild;if(!i)return!0;var s=new Wa(i,e);do{if(n){if(Sf(i)){i=s.next(!0);continue}if(Ky(i)){i=s.next();continue}}if(za(i)){a++,i=s.next();continue}if(_v(i,e))return!1;i=s.next()}while(i);return a<=1},Fi=function(e,n){return n===void 0&&(n=!0),kf(e.dom,n)},Xp=function(e){return e.nodeName.toLowerCase()==="span"},Ok=function(e,n){return gt(e)&&(_v(e,n)||cu(w.fromDom(e)))},Qd=function(e,n){var a=new Wa(e,n).prev(!1),i=new Wa(e,n).next(!1),s=Te(a)||Ok(a,n),l=Te(i)||Ok(i,n);return s&&l},em=function(e){return Xp(e)&&e.getAttribute("data-mce-type")==="bookmark"},Zg=function(e,n){return Wn(e)&&e.data.length>0&&Qd(e,n)},PM=function(e){return Br(e)?e.childNodes.length>0:!1},Jg=function(e){return jr(e)||Vg(e)},Xy=function(e,n,a){var i=a||n;if(Br(n)&&em(n))return n;for(var s=n.childNodes,l=s.length-1;l>=0;l--)Xy(e,s[l],i);if(Br(n)){var v=n.childNodes;v.length===1&&em(v[0])&&n.parentNode.insertBefore(v[0],n)}return!Jg(n)&&!_v(n,i)&&!PM(n)&&!Zg(n,i)&&e.remove(n),n},RM=Tt.makeMap,Oo=/[&<>\"\u0060\u007E-\uD7FF\uE000-\uFFEF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Yp=/[<>&\u007E-\uD7FF\uE000-\uFFEF]|[\uD800-\uDBFF][\uDC00-\uDFFF]/g,tm=/[<>&\"\']/g,Yy=/&#([a-z0-9]+);?|&([a-z0-9]+);/gi,Zy={128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"},Xs={'"':""","'":"'","<":"<",">":">","&":"&","`":"`"},Es={"<":"<",">":">","&":"&",""":'"',"'":"'"},Qg=function(e){var n=w.fromTag("div").dom;return n.innerHTML=e,n.textContent||n.innerText||e},nm=function(e,n){var a,i,s,l={};if(e){for(e=e.split(","),n=n||10,a=0;a1?"&#"+((a.charCodeAt(0)-55296)*1024+(a.charCodeAt(1)-56320)+65536)+";":Xs[a]||"&#"+a.charCodeAt(0)+";"})},ew=function(e,n,a){return a=a||Jy,e.replace(n?Oo:Yp,function(i){return Xs[i]||a[i]||i})},NM=function(e,n){var a=nm(n)||Jy,i=function(v,m){return v.replace(m?Oo:Yp,function(g){return Xs[g]!==void 0?Xs[g]:a[g]!==void 0?a[g]:g.length>1?"&#"+((g.charCodeAt(0)-55296)*1024+(g.charCodeAt(1)-56320)+65536)+";":"&#"+g.charCodeAt(0)+";"})},s=function(v,m){return ew(v,m,a)},l=RM(e.replace(/\+/g,","));return l.named&&l.numeric?i:l.named?n?s:ew:l.numeric?th:eh},tw=function(e){return e.replace(Yy,function(n,a){return a?(a.charAt(0).toLowerCase()==="x"?a=parseInt(a.substr(1),16):a=parseInt(a,10),a>65535?(a-=65536,String.fromCharCode(55296+(a>>10),56320+(a&1023))):Zy[a]||String.fromCharCode(a)):Es[n]||Jy[n]||Qg(n)})},Bl={encodeRaw:eh,encodeAllRaw:Qy,encodeNumeric:th,encodeNamed:ew,getEncodeFunc:NM,decode:tw},Ts={},nh={},Pl=Tt.makeMap,Ki=Tt.each,Zp=Tt.extend,Jp=Tt.explode,Dk=Tt.inArray,Ii=function(e,n){return e=Tt.trim(e),e?e.split(n||" "):[]},nw=function(e,n){var a=Pl(e," ",Pl(e.toUpperCase()," "));return Zp(a,n)},Qp=function(e){return nw("td th li dt dd figcaption caption details summary",e.getTextBlockElements())},da=function(e){var n={},a,i,s,l,v,m,g=function(N,F,$){var ee,ne,re,ie=function(ge,Je){var qe={},De,nt;for(De=0,nt=ge.length;De