index-legacy-74efda96.js 106 KB

1
  1. System.register(["./teacherIcon-legacy-3eeb62c3.js","./maleIcon-legacy-f2aee668.js","./index-legacy-b931071b.js","./index-legacy-ae43a749.js","./api-legacy-fd15d757.js"],(function(e,t){"use strict";var n,o,a,r,i,s,l,d,c,u,h,f,g,p,m,v,b,w,y,_,k,C,x,A,P,T,I,R,S,B,M,j,E,D,L,N,F,O,z,U,K,W,q,H,G,V,Q,$,Y,X,Z,J,ee,te,ne,oe,ae,re,ie,se,le,de,ce,ue,he,fe,ge,pe,me,ve,be,we,ye,_e,ke,Ce,xe,Ae,Pe,Te,Ie,Re,Se,Be,Me,je,Ee,De,Le,Ne,Fe,Oe,ze,Ue,Ke,We,qe,He,Ge,Ve,Qe,$e,Ye=document.createElement("style");return Ye.textContent="._listWrap_jkgts_1{min-height:41.92708vw;padding:1.66667vw;background-color:#fff;border-radius:1.04167vw}._listWrap_jkgts_1 ._customTabs_jkgts_7 .n-tabs-tab--active{font-size:.9375vw!important;font-weight:600!important;color:#131415!important}._listWrap_jkgts_1 ._customTabs_jkgts_7 .n-tabs-tab{font-size:.9375vw;padding:.41667vw 0!important;font-weight:400;min-width:2.60417vw;color:#8b8d98}._listWrap_jkgts_1 ._customTabs_jkgts_7 .n-tabs-tab:hover{color:#198cfe!important}._listWrap_jkgts_1 ._customTabs_jkgts_7 .n-tabs-bar{width:2.60417vw!important;height:.26042vw!important;background:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAAAKCAYAAABCHPt+AAAAAXNSR0IArs4c6QAAAO5JREFUWEftl00KwjAQhd/rLVqv4VbwAnoYfzaKGxE3th5GLyC49RztLTKSajEW+0OTlUw2oSFvGL6XZibEe8RnmdBgDWIsInG1rnM3AZIFBA+JcCoWvLcpXM7lvpqOdi1OZQPiAJHyW8dQAjQAdsWKx18Rmjl/dLSOweAGSDQ0DdW5BGgQYVr/U7o5v3RMUrkIZKZQwxEgeM1XnLsR+3C2OiaZ5FozwplhI9maki+ZfBnSg7PVqSFhvSij+RmiV1ZwS7yurO5iEzzfPw/oWdQtnVEmWyPYa6fle1ba295mzk7bW6WgD8PhZoR8GD4BToyflz19IOIAAAAASUVORK5CYII=) no-repeat;background-size:2.60417vw .26042vw}._infoWrap_jkgts_28{height:100%;padding-top:5.20833vw;display:flex;flex-direction:column;align-items:center}._infoWrap_jkgts_28 ._teacherInfoWrap_jkgts_35{display:flex;flex-direction:column;align-items:center}._infoWrap_jkgts_28 ._teacherInfoWrap_jkgts_35 ._teacherHeadWrap_jkgts_40{position:relative;width:236Px;height:132Px}._infoWrap_jkgts_28 ._teacherInfoWrap_jkgts_35 ._teacherHeadWrap_jkgts_40 ._headerD_jkgts_45{width:100%;height:100%}._infoWrap_jkgts_28 ._teacherInfoWrap_jkgts_35 ._teacherHeadWrap_jkgts_40 ._defultHeade_jkgts_49{width:116Px;height:116Px;overflow:hidden;border-radius:50%;position:absolute;top:8Px;left:60Px}._infoWrap_jkgts_28 ._teacherInfoWrap_jkgts_35 ._teacherHeadWrap_jkgts_40 ._changeHead_jkgts_58{background-color:rgba(0,0,0,.7);display:flex;justify-content:center;align-items:center;font-size:.83333vw;color:#fff;font-weight:600;transition:opacity .3s;cursor:pointer}._infoWrap_jkgts_28 ._teacherInfoWrap_jkgts_35 ._teacherHeadWrap_jkgts_40 ._uploadFile_jkgts_69{position:absolute;left:0;right:0;top:0;bottom:0;opacity:0}._infoWrap_jkgts_28 ._teacherInfoWrap_jkgts_35 ._headerInfo_jkgts_77 ._headerTitle_jkgts_77{font-size:1.14583vw;font-weight:600;color:#131415;line-height:1.45833vw;letter-spacing:1px;margin:.9375vw 0 .41667vw;text-align:center;display:flex;flex-direction:row;justify-content:center;align-items:center}._infoWrap_jkgts_28 ._teacherInfoWrap_jkgts_35 ._headerInfo_jkgts_77 ._headerTitle_jkgts_77 ._sexIcon_jkgts_90{width:.625vw;height:1.09375vw;margin-left:.26042vw}._infoWrap_jkgts_28 ._teacherInfoWrap_jkgts_35 ._headerInfo_jkgts_77 ._headerSubTitle_jkgts_95{font-size:.83333vw;font-weight:400;color:#707a92;line-height:1.04167vw}._infoWrap_jkgts_28 ._setInfo_jkgts_101{margin-top:3.33333vw;width:61.04167vw}._infoWrap_jkgts_28 ._setInfo_jkgts_101 .n-form-item-label{font-size:.78125vw;color:rgba(0,0,0,.8)}._infoWrap_jkgts_28 ._setInfo_jkgts_101 .n-input{height:2.60417vw;border-radius:8Px}._infoWrap_jkgts_28 ._setInfo_jkgts_101 .n-input .n-input__input-el{height:100%}._infoWrap_jkgts_28 ._setInfo_jkgts_101 .n-input.n-input--disabled{background-color:#f5f6fa;color:#959598}._infoWrap_jkgts_28 ._setInfo_jkgts_101 .n-base-selection{border-radius:8Px}._infoWrap_jkgts_28 ._setInfo_jkgts_101 .n-base-selection .n-base-selection-label{height:2.60417vw}._infoWrap_jkgts_28 ._setInfo_jkgts_101 .n-base-selection.n-base-selection--disabled .n-base-selection-label{background-color:#f5f6fa;color:#959598}._btnList_jkgts_130{width:100%;padding:1.04167vw 0;margin-top:1.5625vw}._btnList_jkgts_130 ._btn_jkgts_130{width:7.5vw;height:2.34375vw;border-radius:.41667vw;font-size:.9375vw;font-weight:600!important;margin-right:1.25vw}.option.n-base-select-option{justify-content:center}.option.n-base-select-option.n-base-select-option--pending:before{background-color:#198cfe!important}.option.n-base-select-option.n-base-select-option--pending .n-base-select-option__content{color:#fff!important;text-align:center}._changePwdModal_jkgts_153{border-radius:.83333vw}._changePwdModal_jkgts_153 ._wrap_jkgts_156{padding:.625vw 0}._changePwdModal_jkgts_153 ._wrap_jkgts_156 .n-input{border-radius:.41667vw}._changePwdModal_jkgts_153 ._wrap_jkgts_156 .n-input .n-input__input-el{height:53Px}._changePwdModal_jkgts_153 ._wrap_jkgts_156 .n-button.n-button--disabled{background:#aaa}._changePwdModal_jkgts_153 ._sendMsg_jkgts_168{height:2.76042vw;min-width:5.625vw}._changePwdModal_jkgts_153 ._pwdIcon_jkgts_172{width:1.25vw;height:1.25vw;cursor:pointer}._changePwdModal_jkgts_153 ._submitBtm_jkgts_177{width:45%;height:2.44792vw}._logo_sn7fs_1{position:relative;width:100Px;height:100Px;border-radius:50%;overflow:hidden}._logo_sn7fs_1 ._changeHead_sn7fs_8{position:absolute;left:0;right:0;top:0;bottom:0;background-color:rgba(0,0,0,.7);display:flex;justify-content:center;align-items:center;font-size:.83333vw;color:#fff;font-weight:600;transition:opacity .3s;border-radius:50%;cursor:pointer;opacity:0}._logo_sn7fs_1 ._changeHead_sn7fs_8:hover{opacity:1}._logo_sn7fs_1 ._uploadFile_sn7fs_29{position:absolute;left:0;right:0;top:0;bottom:0;opacity:0}._formWrap_sn7fs_37 .n-input{min-width:14.79167vw;height:2.60417vw;border-radius:8Px}._formWrap_sn7fs_37 .n-input .n-input__input-el{height:100%}._formWrap_sn7fs_37 .n-input.n-input--disabled{background-color:#f5f6fa;color:#959598}._formWrap_sn7fs_37 .n-base-selection{height:2.60417vw;min-width:14.79167vw;border-radius:8Px}._formWrap_sn7fs_37 .n-base-selection .n-base-selection-label{height:100%}._formWrap_sn7fs_37 .n-base-selection.n-base-selection--disabled .n-base-selection-label{background-color:#f5f6fa;color:#959598}._schoolInfo_sn7fs_61 .n-form-item .n-form-item-label{color:#777}._schoolInfo_sn7fs_61 .n-button{border-radius:.41667vw}._schoolInfo_sn7fs_61 .n-data-table .n-data-table-th{background:#F7F7F8;color:#717172!important;border:none;min-height:54Px;font-size:15Px}._schoolInfo_sn7fs_61 .n-data-table.n-data-table--bordered .n-data-table-wrapper{border:none}._schoolInfo_sn7fs_61 .n-data-table-tr .n-data-table-td .n-button__content,._schoolInfo_sn7fs_61 .n-data-table .n-data-table-td{font-weight:700;font-size:15Px}._schoolInfo_sn7fs_61 .n-input{height:2.60417vw;border-radius:8Px}._schoolInfo_sn7fs_61 .n-input .n-input__input-el{height:100%}._schoolInfo_sn7fs_61 .n-input.n-input--disabled{background-color:#f5f6fa;color:#959598}._schoolInfo_sn7fs_61 .n-base-selection{border-radius:8Px}._schoolInfo_sn7fs_61 .n-base-selection .n-base-selection-label{height:2.60417vw}._schoolInfo_sn7fs_61 .n-base-selection.n-base-selection--disabled .n-base-selection-label{background-color:#f5f6fa;color:#959598}._schoolInfo_sn7fs_61 ._errorBtn_sn7fs_103 .n-button__content{color:#ff4d4f}._addTeacher_sn7fs_106{padding:0;border-radius:16Px;overflow:hidden;min-width:456Px}._addTeacher_sn7fs_106 .n-dialog__close{transform:translateY(3Px)}._addTeacher_sn7fs_106 .n-dialog__title{min-height:70Px;justify-content:center;background:#F5F6FA}._addTeacher_sn7fs_106 .n-form{padding:20Px 0}._addTeacher_sn7fs_106 .n-input{height:2.60417vw;border-radius:8Px}._addTeacher_sn7fs_106 .n-input .n-input__input-el{height:100%}._addTeacher_sn7fs_106 .n-input.n-input--disabled{background-color:#f5f6fa;color:#959598}._addTeacher_sn7fs_106 .n-base-selection{border-radius:8Px}._addTeacher_sn7fs_106 .n-base-selection .n-base-selection-label{height:2.60417vw}._addTeacher_sn7fs_106 .n-base-selection.n-base-selection--disabled .n-base-selection-label{background-color:#f5f6fa;color:#959598}._addTeacher_sn7fs_106 .n-form-item-blank{padding-right:30Px}._addTeacher_sn7fs_106 .genderBtn{min-width:84Px;min-height:37Px;border-radius:8Px}._addTeacher_sn7fs_106 .n-form-item-label{color:#777;padding:0;font-size:18Px}._addTeacher_sn7fs_106 .n-form-item-label__text{height:2.60417vw;display:flex;align-items:center;justify-content:center}._addTeacher_sn7fs_106 .nalert{padding:0 30Px}._addTeacher_sn7fs_106 .nalert .n-alert{background:#FFE8E8;text-align:center}._addTeacher_sn7fs_106 .nalert .n-alert-body .n-alert-body__content{color:#ea4132}._addTeacher_sn7fs_106 .actionBtn{width:156Px;height:47Px;font-size:18Px}._btnList_sn7fs_178{width:100%}._btnList_sn7fs_178 ._btn_sn7fs_178{width:7.5vw;border-radius:.41667vw;font-size:.9375vw;font-weight:600!important;margin-right:1.25vw}\n",document.head.appendChild(Ye),{setters:[e=>{n=e.d},e=>{o=e.m,a=e.f},e=>{r=e.co,i=e.cp,s=e.d,l=e.cq,d=e.bq,c=e.r,u=e.aQ,h=e.as,f=e.T,g=e.cr,p=e.cs,m=e.ct,v=e.cu,b=e.cv,w=e.cw,y=e.cx,_=e.cy,k=e.ay,C=e.$,x=e.cz,A=e.cA,P=e.cB,T=e.cC,I=e.cD,R=e.l,S=e.cE,B=e.cF,M=e.cG,j=e.cH,E=e.cI,D=e.bR,L=e.cJ,N=e.cK,F=e.cn,O=e.cL,z=e.cM,U=e.cN,K=e.cO,W=e.cP,q=e.cQ,H=e.cR,G=e.cS,V=e.cT,Q=e.cU,$=e.cV,Y=e.ci,X=e.cW,Z=e.cX,J=e.cY,ee=e.aB,te=e.w,ne=e.b0,oe=e.cZ,ae=e.c_,re=e.c$,ie=e.d0,se=e.d1,le=e.d2,de=e.d3,ce=e.d4,ue=e.d5,he=e.d6,fe=e.d7,ge=e.aK,pe=e.u,me=e.b,ve=e.P,be=e.c,we=e.e,ye=e.f,_e=e.N,ke=e.g,Ce=e.h,xe=e.i,Ae=e.j,Pe=e.B,Te=e.k,Ie=e.F,Re=e.cc,Se=e.q,Be=e.o,Me=e.ca,je=e.cb,Ee=e.C,De=e.z,Le=e.d8,Ne=e.a3,Fe=e.a_,Oe=e.a4,ze=e.y,Ue=e.d9,Ke=e.bW,We=e.x,qe=e.A,He=e.m,Ge=e.n},e=>{Ve=e.U},e=>{Qe=e.u,$e=e.s}],execute:function(){const Ye=r("base-menu-mask","\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n bottom: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n text-align: center;\n padding: 14px;\n overflow: hidden;\n",[i()]),Xe=s({name:"BaseMenuMask",props:{clsPrefix:{type:String,required:!0}},setup(e){l("-base-menu-mask",Ye,d(e,"clsPrefix"));const t=c(null);let n=null;const o=c(!1);u((()=>{null!==n&&window.clearTimeout(n)}));const a={showOnce(e,a=1500){n&&window.clearTimeout(n),o.value=!0,t.value=e,n=window.setTimeout((()=>{o.value=!1,t.value=null}),a)}};return Object.assign({message:t,show:o},a)},render(){return h(f,{name:"fade-in-transition"},{default:()=>this.show?h("div",{class:`${this.clsPrefix}-base-menu-mask`},this.message):null})}}),Ze=g({name:"Cascader",common:p,peers:{InternalSelectMenu:m,InternalSelection:v,Scrollbar:b,Checkbox:w,Empty:y},self:e=>{const{borderRadius:t,boxShadow2:n,popoverColor:o,textColor2:a,textColor3:r,primaryColor:i,textColorDisabled:s,dividerColor:l,hoverColor:d,fontSizeMedium:c,heightMedium:u}=e;return{menuBorderRadius:t,menuColor:o,menuBoxShadow:n,menuDividerColor:l,menuHeight:"calc(var(--n-option-height) * 6.6)",optionArrowColor:r,optionHeight:u,optionFontSize:c,optionColorHover:d,optionTextColor:a,optionTextColorActive:i,optionTextColorDisabled:s,optionCheckMarkColor:i,loadingColor:i,columnWidth:"180px"}}});function Je(e){return e?e.map((e=>e.rawNode)):null}function et(e,t,n){const o=[];for(;e;)o.push(e.rawNode[n]),e=e.parent;return o.reverse().join(t)}const tt=_("n-cascader"),nt=s({name:"NCascaderOption",props:{tmNode:{type:Object,required:!0}},setup(e){const{expandTriggerRef:t,remoteRef:n,multipleRef:o,mergedValueRef:a,checkedKeysRef:r,indeterminateKeysRef:i,hoverKeyPathRef:s,keyboardKeyRef:l,loadingKeySetRef:d,cascadeRef:c,mergedCheckStrategyRef:u,onLoadRef:h,mergedClsPrefixRef:f,mergedThemeRef:g,labelFieldRef:p,showCheckboxRef:m,updateHoverKey:v,updateKeyboardKey:b,addLoadingKey:w,deleteLoadingKey:y,closeMenu:_,doCheck:A,doUncheck:P,renderLabelRef:T}=k(tt),I=C((()=>e.tmNode.key)),R=C((()=>{const{value:e}=t,{value:o}=n;return!o&&"hover"===e})),B=C((()=>{if(R.value)return K})),M=C((()=>{if(R.value)return W})),j=x((()=>{const{value:e}=o;return e?r.value.includes(I.value):a.value===I.value})),E=x((()=>!!o.value&&i.value.includes(I.value))),D=x((()=>s.value.includes(I.value))),L=x((()=>{const{value:e}=l;return null!==e&&e===I.value})),N=x((()=>!!n.value&&d.value.has(I.value))),F=C((()=>e.tmNode.isLeaf)),O=C((()=>e.tmNode.disabled)),z=C((()=>e.tmNode.rawNode[p.value])),U=C((()=>e.tmNode.shallowLoaded));function K(){if(!R.value||O.value)return;const{value:e}=I;v(e),b(e)}function W(){R.value&&K()}function q(){const{value:e}=o,{value:t}=I;e?E.value||j.value?P(t):A(t):(A(t),_(!0))}return{checkStrategy:u,multiple:o,cascade:c,checked:j,indeterminate:E,hoverPending:D,keyboardPending:L,isLoading:N,showCheckbox:m,isLeaf:F,disabled:O,label:z,mergedClsPrefix:f,mergedTheme:g,handleClick:function(t){if(O.value)return;const{value:o}=n,{value:a}=d,{value:r}=h,{value:i}=I,{value:s}=F,{value:l}=U;S(t,"checkbox")||(o&&!l&&!a.has(i)&&r&&(w(i),r(e.tmNode.rawNode).then((()=>{y(i)})).catch((()=>{y(i)}))),v(i),b(i)),s&&q()},handleCheckboxUpdateValue:function(){const{value:e}=F;e||q()},mergedHandleMouseEnter:B,mergedHandleMouseMove:M,renderLabel:T}},render(){const{mergedClsPrefix:e,renderLabel:t}=this;return h("div",{class:[`${e}-cascader-option`,{[`${e}-cascader-option--pending`]:this.keyboardPending||this.hoverPending,[`${e}-cascader-option--disabled`]:this.disabled,[`${e}-cascader-option--show-prefix`]:this.showCheckbox}],onMouseenter:this.mergedHandleMouseEnter,onMousemove:this.mergedHandleMouseMove,onClick:this.handleClick},this.showCheckbox?h("div",{class:`${e}-cascader-option__prefix`},h(R,{focusable:!1,"data-checkbox":!0,disabled:this.disabled,checked:this.checked,indeterminate:this.indeterminate,theme:this.mergedTheme.peers.Checkbox,themeOverrides:this.mergedTheme.peerOverrides.Checkbox,onUpdateChecked:this.handleCheckboxUpdateValue})):null,h("span",{class:`${e}-cascader-option__label`},t?t(this.tmNode.rawNode,this.checked):this.label),h("div",{class:`${e}-cascader-option__suffix`},h("div",{class:`${e}-cascader-option-icon-placeholder`},this.isLeaf?"child"!==this.checkStrategy||this.multiple&&this.cascade?null:h(f,{name:"fade-in-scale-up-transition"},{default:()=>this.checked?h(P,{clsPrefix:e,class:`${e}-cascader-option-icon ${e}-cascader-option-icon--checkmark`},{default:()=>h(I,null)}):null}):h(A,{clsPrefix:e,scale:.85,strokeWidth:24,show:this.isLoading,class:`${e}-cascader-option-icon`},{default:()=>h(P,{clsPrefix:e,key:"arrow",class:`${e}-cascader-option-icon ${e}-cascader-option-icon--arrow`},{default:()=>h(T,null)})}))))}}),ot=s({name:"CascaderSubmenu",props:{depth:{type:Number,required:!0},tmNodes:{type:Array,required:!0}},setup(){const{virtualScrollRef:e,mergedClsPrefixRef:t,mergedThemeRef:n,optionHeightRef:o}=k(tt),a=c(null),r=c(null),i={scroll(t,n){var o,i;e.value?null===(o=r.value)||void 0===o||o.scrollTo({index:t}):null===(i=a.value)||void 0===i||i.scrollTo({index:t,elSize:n})}};return Object.assign({mergedClsPrefix:t,mergedTheme:n,scrollbarInstRef:a,vlInstRef:r,virtualScroll:e,itemSize:C((()=>B(o.value))),handleVlScroll:()=>{var e;null===(e=a.value)||void 0===e||e.sync()},getVlContainer:()=>{var e;return null===(e=r.value)||void 0===e?void 0:e.listElRef},getVlContent:()=>{var e;return null===(e=r.value)||void 0===e?void 0:e.itemsElRef}},i)},render(){const{mergedClsPrefix:e,mergedTheme:t,virtualScroll:n}=this;return h("div",{class:[n&&`${e}-cascader-submenu--virtual`,`${e}-cascader-submenu`]},h(M,{ref:"scrollbarInstRef",theme:t.peers.Scrollbar,themeOverrides:t.peerOverrides.Scrollbar,container:n?this.getVlContainer:void 0,content:n?this.getVlContent:void 0},{default:()=>n?h(j,{items:this.tmNodes,itemSize:this.itemSize,onScroll:this.handleVlScroll,showScrollbar:!1,ref:"vlInstRef"},{default:({item:e})=>h(nt,{key:e.key,tmNode:e})}):this.tmNodes.map((e=>h(nt,{key:e.key,tmNode:e})))}))}}),at=s({name:"NCascaderMenu",props:{value:[String,Number,Array],placement:{type:String,default:"bottom-start"},show:Boolean,menuModel:{type:Array,required:!0},loading:Boolean,onFocus:{type:Function,required:!0},onBlur:{type:Function,required:!0},onKeydown:{type:Function,required:!0},onMousedown:{type:Function,required:!0},onTabout:{type:Function,required:!0}},setup(e){const{localeRef:t,isMountedRef:n,mergedClsPrefixRef:o,syncCascaderMenuPosition:a,handleCascaderMenuClickOutside:r,mergedThemeRef:i}=k(tt),s=[],l=c(null),d=c(null);E(d,(function(){a()}));const u={scroll(e,t,n){const o=s[e];o&&o.scroll(t,n)},showErrorMessage:function(e){var n;const{value:{loadingRequiredMessage:o}}=t;null===(n=l.value)||void 0===n||n.showOnce(o(e))}};return Object.assign({isMounted:n,mergedClsPrefix:o,selfElRef:d,submenuInstRefs:s,maskInstRef:l,mergedTheme:i,handleFocusin:function(t){const{value:n}=d;n&&(n.contains(t.relatedTarget)||e.onFocus(t))},handleFocusout:function(t){const{value:n}=d;n&&(n.contains(t.relatedTarget)||e.onBlur(t))},handleClickOutside:function(e){r(e)}},u)},render(){const{submenuInstRefs:e,mergedClsPrefix:t,mergedTheme:n}=this;return h(f,{name:"fade-in-scale-up-transition",appear:this.isMounted},{default:()=>this.show?D(h("div",{tabindex:"0",ref:"selfElRef",class:`${t}-cascader-menu`,onMousedown:this.onMousedown,onFocusin:this.handleFocusin,onFocusout:this.handleFocusout,onKeydown:this.onKeydown},this.menuModel[0].length?h("div",{class:`${t}-cascader-submenu-wrapper`},this.menuModel.map(((t,n)=>h(ot,{ref:t=>{t&&(e[n]=t)},key:n,tmNodes:t,depth:n+1}))),h(Xe,{clsPrefix:t,ref:"maskInstRef"})):h("div",{class:`${t}-cascader-menu__empty`},N(this.$slots.empty,(()=>[h(F,{theme:n.peers.Empty,themeOverrides:n.peerOverrides.Empty})]))),O(this.$slots.action,(e=>e&&h("div",{class:`${t}-cascader-menu-action`,"data-action":!0},e))),h(z,{onFocus:this.onTabout})),[[L,this.handleClickOutside,void 0,{capture:!0}]]):null})}}),rt=s({name:"NCascaderSelectMenu",props:{value:{type:[String,Number,Array],default:null},show:Boolean,pattern:{type:String,default:""},multiple:Boolean,tmNodes:{type:Array,default:()=>[]},filter:Function,labelField:{type:String,required:!0},separator:{type:String,required:!0}},setup(e){const{isMountedRef:t,mergedValueRef:n,mergedClsPrefixRef:o,mergedThemeRef:a,mergedCheckStrategyRef:r,slots:i,syncSelectMenuPosition:s,closeMenu:l,handleSelectMenuClickOutside:d,doUncheck:u,doCheck:h,clearPattern:f}=k(tt),g=c(null),p=C((()=>function(e,t,n,o){const a=[],r=[];return function e(i){for(const s of i){if(s.disabled)continue;const{rawNode:i}=s;r.push(i),!s.isLeaf&&t||a.push({label:et(s,o,n),value:s.key,rawNode:s.rawNode,path:Array.from(r)}),!s.isLeaf&&s.children&&e(s.children),r.pop()}}(e),a}(e.tmNodes,"child"===r.value,e.labelField,e.separator))),m=C((()=>{const{filter:t}=e;if(t)return t;const{labelField:n}=e;return(e,t,o)=>o.some((t=>t[n]&&~t[n].indexOf(e)))})),v=C((()=>{const{pattern:t}=e,{value:n}=m;return(t?p.value.filter((e=>n(t,e.rawNode,e.path))):p.value).map((e=>({value:e.value,label:e.label})))})),b=C((()=>U(v.value,K("value","children"))));function w(t){if(e.multiple){const{value:e}=n;Array.isArray(e)?e.includes(t.key)?u(t.key):h(t.key):null===e&&h(t.key),f()}else h(t.key),l(!0)}const y={prev:function(){var e;null===(e=g.value)||void 0===e||e.prev()},next:function(){var e;null===(e=g.value)||void 0===e||e.next()},enter:function(){var e;if(g){const t=null===(e=g.value)||void 0===e?void 0:e.getPendingTmNode();return t&&w(t),!0}return!1}};return Object.assign({isMounted:t,mergedTheme:a,mergedClsPrefix:o,menuInstRef:g,selectTreeMate:b,handleResize:function(){s()},handleToggle:function(e){w(e)},handleClickOutside:function(e){d(e)},cascaderSlots:i},y)},render(){const{mergedClsPrefix:e,isMounted:t,mergedTheme:n,cascaderSlots:o}=this;return h(f,{name:"fade-in-scale-up-transition",appear:t},{default:()=>this.show?D(h(W,{ref:"menuInstRef",onResize:this.handleResize,clsPrefix:e,class:`${e}-cascader-menu`,autoPending:!0,themeOverrides:n.peerOverrides.InternalSelectMenu,theme:n.peers.InternalSelectMenu,treeMate:this.selectTreeMate,multiple:this.multiple,value:this.value,onToggle:this.handleToggle},{empty:()=>N(o["not-found"],(()=>[]))}),[[L,this.handleClickOutside,void 0,{capture:!0}]]):null})}}),it=q([r("cascader-menu","\n outline: none;\n position: relative;\n margin: 4px 0;\n display: flex;\n flex-flow: column nowrap;\n border-radius: var(--n-menu-border-radius);\n overflow: hidden;\n box-shadow: var(--n-menu-box-shadow);\n color: var(--n-option-text-color);\n background-color: var(--n-menu-color);\n ",[H({transformOrigin:"inherit",duration:"0.2s"}),G("empty","\n display: flex;\n padding: 12px 32px;\n flex: 1;\n justify-content: center;\n "),r("scrollbar",{width:"100%"}),r("base-menu-mask",{backgroundColor:"var(--n-menu-mask-color)"}),r("base-loading",{color:"var(--n-loading-color)"}),r("cascader-submenu-wrapper","\n position: relative;\n display: flex;\n flex-wrap: nowrap;\n "),r("cascader-submenu","\n height: var(--n-menu-height);\n min-width: var(--n-column-width);\n position: relative;\n ",[V("virtual","\n width: var(--n-column-width);\n "),r("scrollbar-content",{position:"relative"}),q("&:first-child","\n border-top-left-radius: var(--n-menu-border-radius);\n border-bottom-left-radius: var(--n-menu-border-radius);\n "),q("&:last-child","\n border-top-right-radius: var(--n-menu-border-radius);\n border-bottom-right-radius: var(--n-menu-border-radius);\n "),q("&:not(:first-child)","\n border-left: 1px solid var(--n-menu-divider-color);\n ")]),r("cascader-menu-action","\n box-sizing: border-box;\n padding: 8px;\n border-top: 1px solid var(--n-menu-divider-color);\n "),r("cascader-option","\n height: var(--n-option-height);\n line-height: var(--n-option-height);\n font-size: var(--n-option-font-size);\n padding: 0 0 0 18px;\n box-sizing: border-box;\n min-width: 182px;\n background-color: #0000;\n display: flex;\n align-items: center;\n white-space: nowrap;\n position: relative;\n cursor: pointer;\n transition:\n background-color .2s var(--n-bezier),\n color 0.2s var(--n-bezier);\n ",[V("show-prefix",{paddingLeft:0}),G("label","\n flex: 1 0 0;\n overflow: hidden;\n text-overflow: ellipsis;\n "),G("prefix",{width:"32px",display:"flex",alignItems:"center",justifyContent:"center"}),G("suffix",{width:"32px",display:"flex",alignItems:"center",justifyContent:"center"}),r("cascader-option-icon-placeholder",{lineHeight:0,position:"relative",width:"16px",height:"16px",fontSize:"16px"},[r("cascader-option-icon",[V("checkmark",{color:"var(--n-option-check-mark-color)"},[H({originalTransition:"background-color .3s var(--n-bezier), box-shadow .3s var(--n-bezier)"})]),V("arrow",{color:"var(--n-option-arrow-color)"})])]),V("selected",{color:"var(--n-option-text-color-active)"}),V("active",{color:"var(--n-option-text-color-active)",backgroundColor:"var(--n-option-color-hover)"}),V("pending",{backgroundColor:"var(--n-option-color-hover)"}),q("&:hover",{backgroundColor:"var(--n-option-color-hover)"}),V("disabled","\n color: var(--n-option-text-color-disabled);\n background-color: #0000;\n cursor: not-allowed;\n ",[r("cascader-option-icon",[V("arrow",{color:"var(--n-option-text-color-disabled)"})])])])]),r("cascader","\n z-index: auto;\n position: relative;\n width: 100%;\n ")]),st=Object.assign(Object.assign({},$.props),{allowCheckingNotLoaded:Boolean,to:J.propTo,bordered:{type:Boolean,default:void 0},options:{type:Array,default:()=>[]},value:[String,Number,Array],defaultValue:{type:[String,Number,Array],default:null},placeholder:String,multiple:Boolean,size:String,filterable:Boolean,disabled:{type:Boolean,default:void 0},disabledField:{type:String,default:"disabled"},expandTrigger:{type:String,default:"click"},clearable:Boolean,clearFilterAfterSelect:{type:Boolean,default:!0},remote:Boolean,onLoad:Function,separator:{type:String,default:" / "},filter:Function,placement:{type:String,default:"bottom-start"},cascade:{type:Boolean,default:!0},leafOnly:Boolean,showPath:{type:Boolean,default:!0},show:{type:Boolean,default:void 0},maxTagCount:[String,Number],menuProps:Object,filterMenuProps:Object,virtualScroll:{type:Boolean,default:!0},checkStrategy:{type:String,default:"all"},valueField:{type:String,default:"value"},labelField:{type:String,default:"label"},childrenField:{type:String,default:"children"},renderLabel:Function,status:String,"onUpdate:value":[Function,Array],onUpdateValue:[Function,Array],"onUpdate:show":[Function,Array],onUpdateShow:[Function,Array],onBlur:Function,onFocus:Function,onChange:[Function,Array]}),lt=s({name:"Cascader",props:st,setup(e,{slots:t}){const{mergedBorderedRef:n,mergedClsPrefixRef:o,namespaceRef:a,inlineThemeDisabled:r}=Q(e),i=$("Cascader","-cascader",it,Ze,e,o),{localeRef:s}=Y("Cascader"),l=c(e.defaultValue),u=C((()=>e.value)),h=X(u,l),f=C((()=>e.leafOnly?"child":e.checkStrategy)),g=c(""),p=Z(e),{mergedSizeRef:m,mergedDisabledRef:v,mergedStatusRef:b}=p,w=c(null),y=c(null),_=c(null),k=c(null),x=c(null),A=c(new Set),P=c(null),T=c(null),I=J(e),R=c(!1),M=e=>{A.value.add(e)},j=e=>{A.value.delete(e)},E=C((()=>{const{valueField:t,childrenField:n,disabledField:o}=e;return U(e.options,{getDisabled:e=>e[o],getKey:e=>e[t],getChildren:e=>e[n]})})),D=C((()=>{const{cascade:t,multiple:n}=e;return n&&Array.isArray(h.value)?E.value.getCheckedKeys(h.value,{cascade:t,allowNotLoaded:e.allowCheckingNotLoaded}):{checkedKeys:[],indeterminateKeys:[]}})),L=C((()=>D.value.checkedKeys)),N=C((()=>D.value.indeterminateKeys)),F=C((()=>{const{treeNodePath:e,treeNode:t}=E.value.getPath(x.value);let n;return null===t?n=[E.value.treeNodes]:(n=e.map((e=>e.siblings)),t.isLeaf||A.value.has(t.key)||!t.children||n.push(t.children)),n})),O=C((()=>{const{keyPath:e}=E.value.getPath(x.value);return e})),z=C((()=>i.value.self.optionHeight));function K(t){const{onUpdateShow:n,"onUpdate:show":o}=e;n&&fe(n,t),o&&fe(o,t),de.value=t}function W(t,n,o){const{onUpdateValue:a,"onUpdate:value":r,onChange:i}=e,{nTriggerFormInput:s,nTriggerFormChange:d}=p;a&&fe(a,t,n,o),r&&fe(r,t,n,o),i&&fe(i,t,n,o),l.value=t,s(),d()}function q(e){k.value=e}function H(e){x.value=e}function G(e){const{value:{getNode:t}}=E;return e.map((e=>{var n;return(null===(n=t(e))||void 0===n?void 0:n.rawNode)||null}))}function V(t){var n;const{cascade:o,multiple:a,filterable:r}=e,{value:{check:i,getNode:s,getPath:l}}=E;if(a)try{const{checkedKeys:n}=i(t,D.value.checkedKeys,{cascade:o,checkStrategy:f.value,allowNotLoaded:e.allowCheckingNotLoaded});W(n,G(n),n.map((e=>{var t;return Je(null===(t=l(e))||void 0===t?void 0:t.treeNodePath)}))),r&&_e(),k.value=t,x.value=t}catch(d){if(!(d instanceof ce))throw d;if(w.value){const n=s(t);null!==n&&w.value.showErrorMessage(n.rawNode[e.labelField])}}else if("child"===f.value){const e=s(t);if(!(null==e?void 0:e.isLeaf))return!1;W(t,e.rawNode,Je(l(t).treeNodePath))}else{const e=s(t);W(t,(null==e?void 0:e.rawNode)||null,Je(null===(n=l(t))||void 0===n?void 0:n.treeNodePath))}return!0}function ie(t){const{cascade:n,multiple:o}=e;if(o){const{value:{uncheck:o,getNode:a,getPath:r}}=E,{checkedKeys:i}=o(t,D.value.checkedKeys,{cascade:n,checkStrategy:f.value,allowNotLoaded:e.allowCheckingNotLoaded});W(i,i.map((e=>{var t;return(null===(t=a(e))||void 0===t?void 0:t.rawNode)||null})),i.map((e=>{var t;return Je(null===(t=r(e))||void 0===t?void 0:t.treeNodePath)}))),k.value=t,x.value=t}}ee(e.options)&&te(e.options,((e,t)=>{e!==t&&(x.value=null,k.value=null)}));const se=C((()=>{if(e.multiple){const{showPath:t,separator:n,labelField:o,cascade:a}=e,{getCheckedKeys:r,getNode:i}=E.value;return r(L.value,{cascade:a,checkStrategy:f.value,allowNotLoaded:e.allowCheckingNotLoaded}).checkedKeys.map((e=>{const a=i(e);return null===a?{label:String(e),value:e}:{label:t?et(a,n,o):a.rawNode[o],value:a.key}}))}return[]})),le=C((()=>{const{multiple:t,showPath:n,separator:o,labelField:a}=e,{value:r}=h;if(t||Array.isArray(r))return null;{const{getNode:e}=E.value;if(null===r)return null;const t=e(r);return null===t?{label:String(r),value:r}:{label:n?et(t,o,a):t.rawNode[a],value:t.key}}})),de=c(!1),pe=d(e,"show"),me=X(pe,de),ve=C((()=>{const{placeholder:t}=e;return void 0!==t?t:s.value.placeholder})),be=C((()=>!(!e.filterable||!g.value)));function we(t){const{onBlur:n}=e,{nTriggerFormBlur:o}=p;n&&fe(n,t),o()}function ye(t){const{onFocus:n}=e,{nTriggerFormFocus:o}=p;n&&fe(n,t),o()}function _e(){var e;null===(e=_.value)||void 0===e||e.focusInput()}function ke(){v.value||(g.value="",K(!0),e.filterable&&_e())}function Ce(e=!1){var t;e&&(null===(t=_.value)||void 0===t||t.focus()),K(!1),g.value=""}function xe(e){var t;be.value||me.value&&((null===(t=_.value)||void 0===t?void 0:t.$el.contains(ue(e)))||Ce())}function Ae(){e.clearFilterAfterSelect&&(g.value="")}function Pe(t){var n,o,a;const{value:r}=k,{value:i}=E;switch(t){case"prev":if(null!==r){const e=i.getPrev(r,{loop:!0});null!==e&&(q(e.key),null===(n=w.value)||void 0===n||n.scroll(e.level,e.index,B(z.value)))}break;case"next":if(null===r){const e=i.getFirstAvailableNode();null!==e&&(q(e.key),null===(o=w.value)||void 0===o||o.scroll(e.level,e.index,B(z.value)))}else{const e=i.getNext(r,{loop:!0});null!==e&&(q(e.key),null===(a=w.value)||void 0===a||a.scroll(e.level,e.index,B(z.value)))}break;case"child":if(null!==r){const t=i.getNode(r);if(null!==t)if(t.shallowLoaded){const e=i.getChild(r);null!==e&&(H(r),q(e.key))}else{const{value:n}=A;if(!n.has(r)){M(r),H(r);const{onLoad:n}=e;n&&n(t.rawNode).then((()=>{j(r)})).catch((()=>{j(r)}))}}}break;case"parent":if(null!==r){const e=i.getParent(r);if(null!==e){q(e.key);const t=e.getParent();H(null===t?null:t.key)}}}}function Te(t){var n,o;switch(t.key){case" ":case"ArrowDown":case"ArrowUp":if(e.filterable&&me.value)break;t.preventDefault()}if(!S(t,"action"))switch(t.key){case" ":if(e.filterable)return;case"Enter":if(me.value){const{value:t}=be,{value:n}=k;if(t)y.value&&y.value.enter()&&Ae();else if(null!==n)if(L.value.includes(n)||N.value.includes(n))ie(n);else{const t=V(n);!e.multiple&&t&&Ce(!0)}}else ke();break;case"ArrowUp":t.preventDefault(),me.value&&(be.value?null===(n=y.value)||void 0===n||n.prev():Pe("prev"));break;case"ArrowDown":t.preventDefault(),me.value?be.value?null===(o=y.value)||void 0===o||o.next():Pe("next"):ke();break;case"ArrowLeft":t.preventDefault(),me.value&&!be.value&&Pe("parent");break;case"ArrowRight":t.preventDefault(),me.value&&!be.value&&Pe("child");break;case"Escape":me.value&&(he(t),Ce(!0))}}function Ie(){var e;null===(e=P.value)||void 0===e||e.syncPosition()}function Re(){var e;null===(e=T.value)||void 0===e||e.syncPosition()}te(me,(t=>{if(!t)return;if(e.multiple)return;const{value:n}=h;Array.isArray(n)||null===n?(k.value=null,x.value=null):(k.value=n,x.value=n,ge((()=>{var e;if(!me.value)return;const{value:t}=x;if(null!==h.value){const n=E.value.getNode(t);n&&(null===(e=w.value)||void 0===e||e.scroll(n.level,n.index,B(z.value)))}})))}),{immediate:!0});const Se=C((()=>!(!e.multiple||!e.cascade)||"child"!==f.value));ne(tt,{slots:t,mergedClsPrefixRef:o,mergedThemeRef:i,mergedValueRef:h,checkedKeysRef:L,indeterminateKeysRef:N,hoverKeyPathRef:O,mergedCheckStrategyRef:f,showCheckboxRef:Se,cascadeRef:d(e,"cascade"),multipleRef:d(e,"multiple"),keyboardKeyRef:k,hoverKeyRef:x,remoteRef:d(e,"remote"),loadingKeySetRef:A,expandTriggerRef:d(e,"expandTrigger"),isMountedRef:oe(),onLoadRef:d(e,"onLoad"),virtualScrollRef:d(e,"virtualScroll"),optionHeightRef:z,localeRef:s,labelFieldRef:d(e,"labelField"),renderLabelRef:d(e,"renderLabel"),syncCascaderMenuPosition:Re,syncSelectMenuPosition:Ie,updateKeyboardKey:q,updateHoverKey:H,addLoadingKey:M,deleteLoadingKey:j,doCheck:V,doUncheck:ie,closeMenu:Ce,handleSelectMenuClickOutside:function(e){be.value&&xe(e)},handleCascaderMenuClickOutside:xe,clearPattern:Ae});const Be={focus:()=>{var e;null===(e=_.value)||void 0===e||e.focus()},blur:()=>{var e;null===(e=_.value)||void 0===e||e.blur()},getCheckedData:()=>{if(Se.value){const e=L.value;return{keys:e,options:G(e)}}return{keys:[],options:[]}},getIndeterminateData:()=>{if(Se.value){const e=N.value;return{keys:e,options:G(e)}}return{keys:[],options:[]}}},Me=C((()=>{const{self:{optionArrowColor:e,optionTextColor:t,optionTextColorActive:n,optionTextColorDisabled:o,optionCheckMarkColor:a,menuColor:r,menuBoxShadow:s,menuDividerColor:l,menuBorderRadius:d,menuHeight:c,optionColorHover:u,optionHeight:h,optionFontSize:f,loadingColor:g,columnWidth:p},common:{cubicBezierEaseInOut:m}}=i.value;return{"--n-bezier":m,"--n-menu-border-radius":d,"--n-menu-box-shadow":s,"--n-menu-height":c,"--n-column-width":p,"--n-menu-color":r,"--n-menu-divider-color":l,"--n-option-height":h,"--n-option-font-size":f,"--n-option-text-color":t,"--n-option-text-color-disabled":o,"--n-option-text-color-active":n,"--n-option-color-hover":u,"--n-option-check-mark-color":a,"--n-option-arrow-color":e,"--n-menu-mask-color":ae(r,{alpha:.75}),"--n-loading-color":g}})),je=r?re("cascader",void 0,Me,e):void 0;return Object.assign(Object.assign({},Be),{handleTriggerResize:function(){me.value&&(be.value?Ie():Re())},mergedStatus:b,selectMenuFollowerRef:P,cascaderMenuFollowerRef:T,triggerInstRef:_,selectMenuInstRef:y,cascaderMenuInstRef:w,mergedBordered:n,mergedClsPrefix:o,namespace:a,mergedValue:h,mergedShow:me,showSelectMenu:be,pattern:g,treeMate:E,mergedSize:m,mergedDisabled:v,localizedPlaceholder:ve,selectedOption:le,selectedOptions:se,adjustedTo:I,menuModel:F,handleMenuTabout:function(){Ce(!0)},handleMenuFocus:function(e){var t;(null===(t=_.value)||void 0===t?void 0:t.$el.contains(e.relatedTarget))||(R.value=!0,ye(e))},handleMenuBlur:function(e){var t;(null===(t=_.value)||void 0===t?void 0:t.$el.contains(e.relatedTarget))||(R.value=!1,we(e))},handleMenuKeydown:function(e){Te(e)},handleMenuMousedown:function(t){S(t,"action")||e.multiple&&e.filter&&(t.preventDefault(),_e())},handleTriggerFocus:function(e){var t;(null===(t=w.value)||void 0===t?void 0:t.$el.contains(e.relatedTarget))||(R.value=!0,ye(e))},handleTriggerBlur:function(e){var t;(null===(t=w.value)||void 0===t?void 0:t.$el.contains(e.relatedTarget))||(R.value=!1,we(e),Ce())},handleTriggerClick:function(){e.filterable?ke():me.value?Ce(!0):ke()},handleClear:function(t){t.stopPropagation(),e.multiple?W([],[],[]):W(null,null,null)},handleDeleteOption:function(t){const{multiple:n}=e,{value:o}=h;n&&Array.isArray(o)&&void 0!==t.value?ie(t.value):W(null,null,null)},handlePatternInput:function(e){g.value=e.target.value},handleKeydown:Te,focused:R,optionHeight:z,mergedTheme:i,cssVars:r?void 0:Me,themeClass:null==je?void 0:je.themeClass,onRender:null==je?void 0:je.onRender})},render(){const{mergedClsPrefix:e}=this;return h("div",{class:`${e}-cascader`},h(ie,null,{default:()=>[h(se,null,{default:()=>h(le,{onResize:this.handleTriggerResize,ref:"triggerInstRef",status:this.mergedStatus,clsPrefix:e,maxTagCount:this.maxTagCount,bordered:this.mergedBordered,size:this.mergedSize,theme:this.mergedTheme.peers.InternalSelection,themeOverrides:this.mergedTheme.peerOverrides.InternalSelection,active:this.mergedShow,pattern:this.pattern,placeholder:this.localizedPlaceholder,selectedOption:this.selectedOption,selectedOptions:this.selectedOptions,multiple:this.multiple,filterable:this.filterable,clearable:this.clearable,disabled:this.mergedDisabled,focused:this.focused,onFocus:this.handleTriggerFocus,onBlur:this.handleTriggerBlur,onClick:this.handleTriggerClick,onClear:this.handleClear,onDeleteOption:this.handleDeleteOption,onPatternInput:this.handlePatternInput,onKeydown:this.handleKeydown},{arrow:()=>{var e,t;return null===(t=(e=this.$slots).arrow)||void 0===t?void 0:t.call(e)}})}),h(de,{key:"cascaderMenu",ref:"cascaderMenuFollowerRef",show:this.mergedShow&&!this.showSelectMenu,containerClass:this.namespace,placement:this.placement,width:this.options.length?void 0:"target",teleportDisabled:this.adjustedTo===J.tdkey,to:this.adjustedTo},{default:()=>{var e;null===(e=this.onRender)||void 0===e||e.call(this);const{menuProps:t}=this;return h(at,Object.assign({},t,{ref:"cascaderMenuInstRef",class:[this.themeClass,null==t?void 0:t.class],value:this.mergedValue,show:this.mergedShow&&!this.showSelectMenu,menuModel:this.menuModel,style:[this.cssVars,null==t?void 0:t.style],onFocus:this.handleMenuFocus,onBlur:this.handleMenuBlur,onKeydown:this.handleMenuKeydown,onMousedown:this.handleMenuMousedown,onTabout:this.handleMenuTabout}),{action:()=>{var e,t;return null===(t=(e=this.$slots).action)||void 0===t?void 0:t.call(e)},empty:()=>{var e,t;return null===(t=(e=this.$slots).empty)||void 0===t?void 0:t.call(e)}})}}),h(de,{key:"selectMenu",ref:"selectMenuFollowerRef",show:this.mergedShow&&this.showSelectMenu,containerClass:this.namespace,width:"target",placement:this.placement,to:this.adjustedTo,teleportDisabled:this.adjustedTo===J.tdkey},{default:()=>{var e;null===(e=this.onRender)||void 0===e||e.call(this);const{filterMenuProps:t}=this;return h(rt,Object.assign({},t,{ref:"selectMenuInstRef",class:[this.themeClass,null==t?void 0:t.class],value:this.mergedValue,show:this.mergedShow&&this.showSelectMenu,pattern:this.pattern,multiple:this.multiple,tmNodes:this.treeMate.treeNodes,filter:this.filter,labelField:this.labelField,separator:this.separator,style:[this.cssVars,null==t?void 0:t.style]}))}})]}))}}),dt={listWrap:"_listWrap_jkgts_1",customTabs:"_customTabs_jkgts_7",infoWrap:"_infoWrap_jkgts_28",teacherInfoWrap:"_teacherInfoWrap_jkgts_35",teacherHeadWrap:"_teacherHeadWrap_jkgts_40",headerD:"_headerD_jkgts_45",defultHeade:"_defultHeade_jkgts_49",changeHead:"_changeHead_jkgts_58",uploadFile:"_uploadFile_jkgts_69",headerInfo:"_headerInfo_jkgts_77",headerTitle:"_headerTitle_jkgts_77",sexIcon:"_sexIcon_jkgts_90",headerSubTitle:"_headerSubTitle_jkgts_95",setInfo:"_setInfo_jkgts_101",btnList:"_btnList_jkgts_130",btn:"_btn_jkgts_130",changePwdModal:"_changePwdModal_jkgts_153",wrap:"_wrap_jkgts_156",sendMsg:"_sendMsg_jkgts_168",pwdIcon:"_pwdIcon_jkgts_172",submitBtm:"_submitBtm_jkgts_177"},ct=""+new URL("headerD-220e6507.png",t.meta.url).href,ut=s({name:"forgotPassword",emits:["close"],setup(e,{emit:t}){pe();const n=c(),o=me(),a=c(!1);ve.BASE_LOGIN_NAME;const r=c(!1),i=be(),s=we({mobile:"",password:"",code:"",isCaptcha:!0}),l=c(!1),d=c(60),u=async()=>(n.value.validate((async e=>{if(!e){o.loading("修改中..."),a.value=!0;try{return await Qe({...s,clientType:"TEACHER"}),o.success("修改成功"),a.value=!1,t("close"),setTimeout((()=>{i.logout(),history.go(0)}),500),!1}catch(n){return a.value=!1,o.error(n.msg),!1}}})),!1),h=()=>{if(l.value)return;l.value=!0;const e=setInterval((()=>{d.value--,console.log(d.value),d.value<=0&&(l.value=!1,clearInterval(e))}),1e3)};return()=>ye(Ie,null,[ye("div",{class:dt.wrap},[ye(_e,{ref:n,"label-placement":"left",size:"large",model:s},{default:()=>[ye(ke,{path:"mobile",rule:[{key:"a",required:!0,message:"请输入手机号",trigger:"blur"},{key:"a",pattern:/^1[3456789]\d{9}$/,message:"手机号格式不正确",trigger:"blur"}]},{default:()=>[ye(Ce,{maxlength:11,value:s.mobile,"onUpdate:value":e=>s.mobile=e,placeholder:"请输入手机号"},null)]}),ye(ke,{path:"code",rule:[{required:!0,message:"请输入验证码",trigger:"blur"}]},{default:()=>[ye(xe,null,{default:()=>[ye(Ce,{value:s.code,"onUpdate:value":e=>s.code=e,type:"text",maxlength:6,placeholder:"请输入验证码",inputProps:{autocomplete:"off"},class:dt.sendInput},null),ye(Ae,{type:"primary",class:dt.sendMsg,disabled:l.value,bordered:!1,onClick:()=>{n.value?.validate((e=>{e||(h(),$e({clientId:"cooleshow-teacher",mobile:s.mobile,type:"PASSWORD"}))}),(e=>"a"===e.key))}},{default:()=>[l.value?d.value:"发送短信"]})]})]}),ye(ke,{path:"password",rule:[{required:!0,message:"请输入密码",trigger:"blur"},{pattern:/^(?![0-9]+$)(?![a-zA-Z]+$)[0-9A-Za-z]{6,20}$/,message:"密码为6-20位数字和字母组合",trigger:"blur"}]},{default:()=>[ye(Ce,{value:s.password,"onUpdate:value":e=>s.password=e,type:"password",showPasswordOn:"click",placeholder:"请输入密码",inputProps:{autocomplete:"off"},class:[r.value?"":dt["no-pwd"]]},{"password-visible-icon":()=>ye("img",{src:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAAAXNSR0IArs4c6QAABPZJREFUaEPtWN1vG0UQn7kYny1hFQgEqASRQYhS4GnPMbFTxaCmkJC0UAiipPwDPECfykcr4QcKqE8pD/wDhBY1fLQkbVBA4EDsxL67J0pbhEhUkAoKFVDZKD7ncoM2nKPrcT5/Nq0l7+Puzuz8ZmZ/M7sITT6wye2HFoBrHcFWBFoRqNMDrRSq04F1izcsApFIpEPTtGcQMQIADxHRZgDYZFp4GREvAsAZIkqJovhJKpVaqtt6gPrqQHd39y0rKyvDRPQcIvYSUVslRiHiKhHNIOJxn893fHZ29q9K5Jz21BSBWCzmy2az+wDgNYuXa7XhMgC8GwgERhOJRL5aJVUBiMfjwuTk5F4AeIuI7qr2MLf9iPgrABwcHBwci8fjRqW6KwYQjUY35/P5jwBgWynliCgDwMeIeE4QhAu6rl/gez0eT6dhGJ1E9AAAPEtEIRcd34qiuCeZTPI7U3ZUBECSpD4i+hAAbnPQeAkA3gOAo6qq/lz2RABgjN0LAC8AwMsAcKuDzB+IOKIoypfl9LkC4CkzMTERB4ADACDYlGmIeISI3lZVledx1YMxtgkR3yCiVwBAtCngaXRoaGgo7pZSJQH09/eLS0tLxwDgabtliHja6/W+lEql1lLEPoaHh9sWFxcfAYB7zLWFYDA4Pz4+vuq0PxKJdBYKhfeJaMBh/bOOjo49U1NTWsUsFI1GA/l8/gQAPGYVMunvgKIohxGR7AoZYzcg4j4i2u+QGpcQ8TARjaqqumKXJSKUJOlVROQEYafjr30+31PJZDL7P2faJ7jxmqZ9RURdtrWLbW1tz2cyme+cPGGmw0ki6nXLJUScIaJdpdKuq6tr2+rqKicLXgitI+3z+frsIK5IIZPfTwPAozbP/yCK4o5SzGDS6ykieqKSi4CIX8iyPOAURS7PGU/TtGkietCm75tAIDBgrRfrAMy8/ZSIdtqE5r1e75Nzc3N/ljKOMcYZhbOUdfD2IcEniCjmUPBGVFU9Wkonr/KFQuEUAPC7tD4Q8fNgMLi7eJ/WATDGjpi0Zt0/HwgE+hKJRM7Ns5IkyUQkFffwemCmyW98jjF2JyLy9Frnf0RUFEUpWQ+4XCwWuzGbzXIqvQIEp21VVTlz/dcLhUKhvYZhfGAz8nu/399brk9hjHEe541Z0RmGx+PZkk6nf7LqC4fD9+m6ft5Cx5wEOlRV5XWk5Ojp6bl5eXl5BgAetm4SBOFFWZbH1g5ljJ0FAF4l1wYv64jYJcvy727K+Vo4HGa6risW2R8VRdniJCdJ0nkiur+45vF4pHQ6rZY7w4xg2ta+nFNVdWtTAAiFQncQUaYkgKZPITONHC9xe3v79unp6X+qvMQZRNxVTEEzBU5Ya0tDLzE3zo1G/X7/gNtlDoVCI4ZhjNlA/s2LFp/bEBo1acuXy+WmzAPX7UHEM6IoPn5dF7KitbW2ErFY7KZcLsfT5Kq0EoiYEUVxu2srYQWRz+dPOrQUOhEdvIrN3H5EPFRXM1cE0dTtdBEEv9gLCwtvujxoRononTofNK8TEf8gaOyDxsoojLEdAMBZptSTklPwsevuSWkFUc2jXhCEs4j4i/VRT0R3G4ax9Zo86otAmvpbxRqNpv3YsrcTTfu16NQXhcPh23Vd391Un7vl+viNWK/oZ24jDKn1jBaAWj3XKLlWBBrlyVr1tCJQq+caJdf0EfgXo04MXg/L95wAAAAASUVORK5CYII=",class:dt.pwdIcon},null),"password-invisible-icon":()=>ye("img",{src:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAAAXNSR0IArs4c6QAABT5JREFUaEPtV3+IVFUU/s59M+5Es0G/SKLUTAtCi+beGdddNrE/FoqECC0Lgqgg0FSChPrDUmIpSCqiH5AUSf4TFFG7QQTVlK068+7dIk0qcw2MsiSUjdbdnZ134gxvlrfj7K7zYwthLizszHvnnO875zvn3CGc54fOc/xoEfi/K9iqQKsCDWagJaEGE9iweasCDaewQQetCjSYwIbNWxVoOIUNOpisQE9Pz4XDw8MLEonEkWw2O9Gg3zkx11rHiWiZ53lHc7ncsAQpEchkMqZYLH4OoJ2IjsXj8Z79+/f/PCco6nRqjFnMzIJxIYARIlptrc2XCBhj3mPmNQDmASgAOE1E3dbaH+uM11Szjo6ORYVCYR+AywDEBSMRfWStXVsioLXexcz3E1FbGFlI/KOUutP3/S+biqZGZ8aYm5n5EwAXh+DFwzgRfWCtXV8msICIvmHmiwDEwhhFAAxgs3Pu9RrjNuV1Y8zaIAj2KKU8Zi7jkuSeAtDpnDs62cQrVqy4oVgs7mXm9ghTASIGbwPY6JyT/+f8MDNlMpltQRBsA6DCvzKWv4ioy1o7NNnEZURa62sBfAZgPoCynEBEowAOAlhfNpwrFitXrrxkfHz8TQC3RTEAGAPwRzweX3XgwIFfyvHPWmRaa2mUj5n5pkhPlHTHzKyUeiqZTL4wF6NWa30fgFcBXFAJnoi+SiaTd2ez2dPR5FXdxOvWrZs3NDR0mIgWMbMXNWDmMSKS8omkvmhGJYwxywC8xMy3VMgXzBwQ0an29vYlleDPklBEStK0D4Zj9SyMRFRklv4uyWqHtfZDIip9UcsxxnQxs+i8B4AsTxmR1Y7I5/tYLLa6vMBmktBrAB6qAB+EzTzZF6ED+V7InFRKvcvMfQC+nq7Zt2/frvr6+tIAbieie5h5CQDxUQlchoVMnahChMShRCKxemBg4O+qBLTW1cDLON1ERDLKniWiGDMnqqRpPJwWsmSOM/OvAI5KZZj5GgBXA7hK9M3MExX9VXInw4KZh4loi3xk5ncATEpY5KuUOtjW1nZrmcQkQ631JgA7KzJfJKIN1to3JEAmk7l0YmKiVyn1MDNLlqoRmdIy4S6RUTjtCYHL8+cBPOecG5EPxpj1zLwnSgKATMRXnHNbp/RAKpXKEtGqSJQp4KPRu7q6rhwdHX2EiB4NgiBJRHIFqfkQ0QQzHwfwYiwW212p7xlI5JxzHVMIaK2fBPB0KANSSm3wfX/XTKjkdgjgt/COUn5VtCqyk+rOIyKZJCIvJiLFzEK2XJGT1torZhsAxph7QzkJYbmRPuace3kKAWmw/v7+x2X+A9jtnPt0tpQaY65n5h8i750horcADIbLUBaigD5BRL8DWApgS6SHhNSN1tpDs8XSWi8nojVKqe/y+Xz/tFNoNkfR58aYrcy8I1w8pUee5y3O5/PHqvmRLVsoFP4s7xYiOgOg11rbW0vc6LsN/aRMpVI+EZmyQ2Y+Mjg4eN1MYFKp1AARdUbeOeScW/6fE+ju7r58ZGTkRETPo0qpnb7vy2Ka9mitN8ukiVSNY7HYglwuJ2O35lN3BTKZzB3FYvH9yNgNlFIdvu/7M6Ho7OxcODY2NnkZkwXped5dUV3XwqJuAtJUAL4NKyBT57C1Vi6As14pjDH7giBIhff8olJqqe/7Mk5rPnUTkEjpdPqBIAiekM2rlNqYz+d/OhcE6XR6fhAEz8h29jyvN5/P7z0Xu2rvNESg3qDNtGsRaGY26/HVqkA9WWumTasCzcxmPb5aFagna820aVWgmdmsx9e/6msHT1UYKgkAAAAASUVORK5CYII=",class:dt.pwdIcon},null)})]})]})]),ye(Pe,{justify:"space-around",style:{width:"100%"},wrap:!1,wrapItem:!1},{default:()=>[ye(Ae,{class:[dt.submitBtm,dt.submitForgoBtm],onClick:()=>t("close"),size:"large",round:!0,disabled:a.value},{default:()=>[Te("取消")]}),ye(Ae,{class:[dt.submitBtm,dt.submitForgoBtm],type:"primary",onClick:u,size:"large",round:!0,disabled:a.value},{default:()=>[Te("确认修改")]})]})])}}),ht=()=>Re.get("/edu-app/open/sysArea/queryAllProvince"),ft=s({name:"setting-personInfo",setup(){const e=me(),t=be(),r=we({sexs:[{label:"男",value:1,class:"option"},{label:"女",value:0,class:"option"}],areaList:[]}),i=c(),s=we({provinceCode:"",cityCode:"",regionCode:"",nickname:t.info.nickname,phone:t.info.phone,gender:t.info.gender,schoolId:t.info.schoolInfos?.[0]?.id,tenantId:t.info.schoolInfos?.[0]?.tenantId,id:t.info.id,avatar:t.info.avatar}),l=we({disabled:!0,openChangePwd:!1,uploadShow:!0});return Se((()=>{(async()=>{const e=await ht();200===e?.code&&(r.areaList=e.data)})()})),()=>ye("div",{class:dt.infoWrap},[ye("div",{class:dt.teacherInfoWrap},[ye("div",{class:dt.teacherHeadWrap},[ye(Be,{previewDisabled:!0,class:dt.headerD,src:ct},null),ye(Be,{previewDisabled:!0,class:dt.defultHeade,src:s.avatar||n},null),ye("div",{style:{display:l.disabled?"none":""},class:[dt.defultHeade,dt.changeHead]},[Te("修改头像"),l.uploadShow&&ye(Ve,{class:[dt.uploadFile],cropper:!0,"onUpdate:fileList":e=>{s.avatar=e,l.uploadShow=!1,setTimeout((()=>{l.uploadShow=!0}),100)}},null)])]),ye("div",{class:dt.headerInfo},[ye("p",{class:dt.headerTitle},[t.info.nickname,ye(Be,{previewDisabled:!0,class:dt.sexIcon,src:t.info.gender?o:a},null)]),ye("p",{class:dt.headerSubTitle},[t.info.schoolInfos?.[0]?.name,Te(" | 音乐老师")])])]),ye("div",{class:dt.setInfo},[ye(_e,{ref:i,model:s,disabled:l.disabled},{default:()=>[ye(Me,{cols:3,"x-gap":"100"},{default:()=>[ye(je,null,{default:()=>[ye(ke,{label:"姓名",path:"nickname",rule:{required:!0,message:"请填写老师姓名",trigger:"blur"}},{default:()=>[ye(Ce,{bordered:!l.disabled,placeholder:"请填写老师姓名",value:s.nickname,"onUpdate:value":e=>s.nickname=e},null)]})]}),ye(je,null,{default:()=>[ye(ke,{label:"手机号",path:"phone",rule:[{required:!0,message:"请填写老师手机号",trigger:"blur"},{pattern:/^1[3456789]\d{9}$/,message:"手机号格式不正确",trigger:"blur"}]},{default:()=>[ye(Ce,{bordered:!l.disabled,placeholder:"请填写老师手机号",value:s.phone,"onUpdate:value":e=>s.phone=e},null)]})]}),ye(je,null,{default:()=>[ye(ke,{label:"性别",path:"sex"},{default:()=>[ye(Ee,{bordered:!l.disabled,class:dt.select,showArrow:!l.disabled,placeholder:"请选择性别",options:r.sexs,value:s.gender,"onUpdate:value":e=>s.gender=e},null)]})]})]}),ye(ke,{label:"城区",style:{maxWidth:"30%"}},{default:()=>[ye(lt,{bordered:!l.disabled,options:r.areaList,labelField:"name",valueField:"code",childrenField:"areas",checkStrategy:"child",expandTrigger:"hover",defaultValue:t.info.regionCode||t.info.cityCode,"onUpdate:value":(e,t,n)=>{s.provinceCode=n[0]?.code,s.cityCode=n[1]?.code,s.regionCode=n[2]?.code}},null)]})]})]),l.disabled?ye(Pe,{class:dt.btnList,align:"center",justify:"end"},{default:()=>[ye(Ae,{class:dt.btn,color:"#198cfe",onClick:()=>l.openChangePwd=!0},{default:()=>[Te("修改密码")]}),ye(Ae,{class:dt.btn,color:"#f24433",onClick:()=>l.disabled=!1},{default:()=>[Te("修改信息")]})]}):ye(Pe,{class:dt.btnList,align:"center",justify:"end"},{default:()=>[ye(Ae,{class:dt.btn,onClick:()=>l.disabled=!0},{default:()=>[Te("取消")]}),ye(Ae,{class:dt.btn,type:"primary",onClick:()=>{i.value.validate((async n=>{n||(await Le(s),console.log(s),t.getInfo(),l.disabled=!0,e.success("修改成功"))}))}},{default:()=>[Te("完成")]})]}),ye(De,{class:dt.changePwdModal,show:l.openChangePwd,"onUpdate:show":e=>l.openChangePwd=e,preset:"dialog",showIcon:!1,title:"修改密码"},{default:()=>[ye(ut,{onClose:()=>{l.openChangePwd=!1}},null)]})])}}),gt="_logo_sn7fs_1",pt="_changeHead_sn7fs_8",mt="_uploadFile_sn7fs_29",vt="_formWrap_sn7fs_37",bt="_schoolInfo_sn7fs_61",wt="_errorBtn_sn7fs_103",yt="_addTeacher_sn7fs_106",_t="_btnList_sn7fs_178",kt="_btn_sn7fs_178",Ct={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",viewBox:"0 0 512 512"},xt=[Oe("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"32",d:"M256 112v288"},null,-1),Oe("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"32",d:"M400 256H112"},null,-1)],At=s({name:"Add",render:function(e,t){return Fe(),Ne("svg",Ct,xt)}}),Pt=s({name:"teacher-operation",emits:["close"],props:{areaList:{type:Array,default:()=>[]}},setup(e,{emit:t}){const n=be(),o=we({provinceCode:"",cityCode:"",regionCode:"",tenantId:n.info.schoolInfos?.[0]?.tenantId,phone:null,schoolId:n.info.schoolInfos?.[0]?.id,nickname:null,gender:1}),a=c(!1),r=c(),i=me(),s=async()=>{r.value.validate((async e=>{if(!e){try{a.value=!0,await(n={...o},Re.post("/edu-app/teacher/add",{data:n})),i.success("添加成功")}catch(r){console.log(r)}var n;setTimeout((()=>{a.value=!1,t("close")}),100)}}))};return()=>ye("div",null,[ye(_e,{model:o,ref:r,showRequireMark:!1,"label-placement":"left","label-width":"126"},{default:()=>[ye(ke,{label:"老师姓名",path:"nickname",rule:[{required:!0,message:"请输入老师姓名"}]},{default:()=>[ye(Ce,{value:o.nickname,"onUpdate:value":e=>o.nickname=e,placeholder:"请输入老师姓名",clearable:!0,maxlength:14},null)]}),ye(ke,{label:"老师性别",path:"gender",rule:[{required:!0,message:"请选择老师性别"}]},{default:()=>[ye(Pe,null,{default:()=>[ye(ze("n-button"),{class:"genderBtn",type:o.gender?"info":void 0,tertiary:!o.gender,onClick:()=>{o.gender=1}},{default:()=>[Te("男")]}),ye(ze("n-button"),{class:"genderBtn",type:o.gender?void 0:"info",tertiary:!!o.gender,onClick:()=>{o.gender=0}},{default:()=>[Te("女")]})]})]}),ye(ke,{label:"城区"},{default:()=>[ye(lt,{to:"body",placeholder:"请选择城区",options:e.areaList,labelField:"name",valueField:"code",childrenField:"areas",checkStrategy:"child",expandTrigger:"hover","onUpdate:value":(e,t,n)=>{o.provinceCode=n[0]?.code,o.cityCode=n[1]?.code,o.regionCode=n[2]?.code}},null)]}),ye(ke,{label:"手机号",path:"phone",rule:[{required:!0,message:"手机号码",trigger:"blur"},{pattern:/^((13[0-9])|(14(0|[5-7]|9))|(15([0-3]|[5-9]))|(16(2|[5-7]))|(17[0-8])|(18[0-9])|(19([0-3]|[5-9])))\d{8}$/,message:"请输入正确的手机号",trigger:"blur"}]},{default:()=>[ye(Ce,{maxlength:11,value:o.phone,"onUpdate:value":e=>o.phone=e,placeholder:"请输入手机号",clearable:!0},null)]}),ye("div",{class:"nalert"},[ye(Ue,{type:"error",showIcon:!1,bordered:!1},{default:()=>[Te("默认密码为ktyq+手机号后四位")]})])]}),ye(Pe,{style:{padding:"20px 0 32px 0"},justify:"center"},{default:()=>[ye(Ae,{class:"actionBtn",round:!0,type:"default",onClick:()=>t("close")},{default:()=>[Te("取消")]}),ye(Ae,{class:"actionBtn",round:!0,type:"primary",onClick:()=>s(),loading:a.value},{default:()=>[Te("确定")]})]})])}});function Tt(e){if("string"!=typeof e)throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}function It(e,t){for(var n,o="",a=0,r=-1,i=0,s=0;s<=e.length;++s){if(s<e.length)n=e.charCodeAt(s);else{if(47===n)break;n=47}if(47===n){if(r===s-1||1===i);else if(r!==s-1&&2===i){if(o.length<2||2!==a||46!==o.charCodeAt(o.length-1)||46!==o.charCodeAt(o.length-2))if(o.length>2){var l=o.lastIndexOf("/");if(l!==o.length-1){-1===l?(o="",a=0):a=(o=o.slice(0,l)).length-1-o.lastIndexOf("/"),r=s,i=0;continue}}else if(2===o.length||1===o.length){o="",a=0,r=s,i=0;continue}t&&(o.length>0?o+="/..":o="..",a=2)}else o.length>0?o+="/"+e.slice(r+1,s):o=e.slice(r+1,s),a=s-r-1;r=s,i=0}else 46===n&&-1!==i?++i:i=-1}return o}var Rt={resolve:function(){for(var e,t="",n=!1,o=arguments.length-1;o>=-1&&!n;o--){var a;o>=0?a=arguments[o]:(void 0===e&&(e=process.cwd()),a=e),Tt(a),0!==a.length&&(t=a+"/"+t,n=47===a.charCodeAt(0))}return t=It(t,!n),n?t.length>0?"/"+t:"/":t.length>0?t:"."},normalize:function(e){if(Tt(e),0===e.length)return".";var t=47===e.charCodeAt(0),n=47===e.charCodeAt(e.length-1);return 0!==(e=It(e,!t)).length||t||(e="."),e.length>0&&n&&(e+="/"),t?"/"+e:e},isAbsolute:function(e){return Tt(e),e.length>0&&47===e.charCodeAt(0)},join:function(){if(0===arguments.length)return".";for(var e,t=0;t<arguments.length;++t){var n=arguments[t];Tt(n),n.length>0&&(void 0===e?e=n:e+="/"+n)}return void 0===e?".":Rt.normalize(e)},relative:function(e,t){if(Tt(e),Tt(t),e===t)return"";if((e=Rt.resolve(e))===(t=Rt.resolve(t)))return"";for(var n=1;n<e.length&&47===e.charCodeAt(n);++n);for(var o=e.length,a=o-n,r=1;r<t.length&&47===t.charCodeAt(r);++r);for(var i=t.length-r,s=a<i?a:i,l=-1,d=0;d<=s;++d){if(d===s){if(i>s){if(47===t.charCodeAt(r+d))return t.slice(r+d+1);if(0===d)return t.slice(r+d)}else a>s&&(47===e.charCodeAt(n+d)?l=d:0===d&&(l=0));break}var c=e.charCodeAt(n+d);if(c!==t.charCodeAt(r+d))break;47===c&&(l=d)}var u="";for(d=n+l+1;d<=o;++d)d!==o&&47!==e.charCodeAt(d)||(0===u.length?u+="..":u+="/..");return u.length>0?u+t.slice(r+l):(r+=l,47===t.charCodeAt(r)&&++r,t.slice(r))},_makeLong:function(e){return e},dirname:function(e){if(Tt(e),0===e.length)return".";for(var t=e.charCodeAt(0),n=47===t,o=-1,a=!0,r=e.length-1;r>=1;--r)if(47===(t=e.charCodeAt(r))){if(!a){o=r;break}}else a=!1;return-1===o?n?"/":".":n&&1===o?"//":e.slice(0,o)},basename:function(e,t){if(void 0!==t&&"string"!=typeof t)throw new TypeError('"ext" argument must be a string');Tt(e);var n,o=0,a=-1,r=!0;if(void 0!==t&&t.length>0&&t.length<=e.length){if(t.length===e.length&&t===e)return"";var i=t.length-1,s=-1;for(n=e.length-1;n>=0;--n){var l=e.charCodeAt(n);if(47===l){if(!r){o=n+1;break}}else-1===s&&(r=!1,s=n+1),i>=0&&(l===t.charCodeAt(i)?-1==--i&&(a=n):(i=-1,a=s))}return o===a?a=s:-1===a&&(a=e.length),e.slice(o,a)}for(n=e.length-1;n>=0;--n)if(47===e.charCodeAt(n)){if(!r){o=n+1;break}}else-1===a&&(r=!1,a=n+1);return-1===a?"":e.slice(o,a)},extname:function(e){Tt(e);for(var t=-1,n=0,o=-1,a=!0,r=0,i=e.length-1;i>=0;--i){var s=e.charCodeAt(i);if(47!==s)-1===o&&(a=!1,o=i+1),46===s?-1===t?t=i:1!==r&&(r=1):-1!==t&&(r=-1);else if(!a){n=i+1;break}}return-1===t||-1===o||0===r||1===r&&t===o-1&&t===n+1?"":e.slice(t,o)},format:function(e){if(null===e||"object"!=typeof e)throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof e);return function(e,t){var n=t.dir||t.root,o=t.base||(t.name||"")+(t.ext||"");return n?n===t.root?n+o:n+e+o:o}("/",e)},parse:function(e){Tt(e);var t={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return t;var n,o=e.charCodeAt(0),a=47===o;a?(t.root="/",n=1):n=0;for(var r=-1,i=0,s=-1,l=!0,d=e.length-1,c=0;d>=n;--d)if(47!==(o=e.charCodeAt(d)))-1===s&&(l=!1,s=d+1),46===o?-1===r?r=d:1!==c&&(c=1):-1!==r&&(c=-1);else if(!l){i=d+1;break}return-1===r||-1===s||0===c||1===c&&r===s-1&&r===i+1?-1!==s&&(t.base=t.name=0===i&&a?e.slice(1,s):e.slice(i,s)):(0===i&&a?(t.name=e.slice(1,r),t.base=e.slice(1,s)):(t.name=e.slice(i,r),t.base=e.slice(i,s)),t.ext=e.slice(r,s)),i>0?t.dir=e.slice(0,i-1):a&&(t.dir="/"),t},sep:"/",delimiter:":",win32:null,posix:null};Rt.posix=Rt;const St=Rt.extname,Bt=Rt.basename;class Mt{constructor(){let e="undefined"==typeof global,t="image/png",n="image/jpeg",o="image/jpeg",a="image/webp",r="application/pdf",i="image/svg+xml";Object.assign(this,{toMime:this.toMime.bind(this),fromMime:this.fromMime.bind(this),expected:e?'"png", "jpg", or "webp"':'"png", "jpg", "pdf", or "svg"',formats:e?{png:t,jpg:n,jpeg:o,webp:a}:{png:t,jpg:n,jpeg:o,pdf:r,svg:i},mimes:e?{[t]:"png",[n]:"jpg",[a]:"webp"}:{[t]:"png",[n]:"jpg",[r]:"pdf",[i]:"svg"}})}toMime(e){return this.formats[(e||"").replace(/^\./,"").toLowerCase()]}fromMime(e){return this.mimes[e]}}class jt{static for(e){return(new jt).append(e).get()}constructor(){this.crc=-1}get(){return~this.crc}append(e){for(var t=0|this.crc,n=this.table,o=0,a=0|e.length;o<a;o++)t=t>>>8^n[255&(t^e[o])];return this.crc=t,this}}function Et(e){let t=new Uint8Array(e),n=new DataView(t.buffer),o={array:t,view:n,size:e,set8:(e,t)=>(n.setUint8(e,t),o),set16:(e,t)=>(n.setUint16(e,t,!0),o),set32:(e,t)=>(n.setUint32(e,t,!0),o),bytes:(e,n)=>(t.set(n,e),o)};return o}jt.prototype.table=(()=>{var e,t,n,o=[];for(e=0;e<256;e++){for(n=e,t=0;t<8;t++)n=1&n?n>>>1^3988292384:n>>>1;o[e]=n}return o})();class Dt{constructor(e){let t=new Date;Object.assign(this,{directory:e,offset:0,files:[],time:(t.getHours()<<6|t.getMinutes())<<5|t.getSeconds()/2,date:(t.getFullYear()-1980<<4|t.getMonth()+1)<<5|t.getDate()}),this.add(e)}async add(e,t){let n=!t,o=Dt.encoder.encode(`${this.directory}/${n?"":e}`),a=new Uint8Array(n?0:await t.arrayBuffer()),r=30+o.length,i=r+a.length,{offset:s}=this,l=Et(26).set32(0,134742036).set16(6,this.time).set16(8,this.date).set32(10,jt.for(a)).set32(14,a.length).set32(18,a.length).set16(22,o.length);s+=r;let d=Et(r+a.length+16).set32(0,67324752).bytes(4,l.array).bytes(30,o).bytes(r,a);s+=a.length,d.set32(i,134695760).bytes(i+4,l.array.slice(10,22)),s+=16,this.files.push({offset:s,folder:n,name:o,header:l,payload:d}),this.offset=s}toBuffer(){let e=this.files.reduce(((e,{name:t})=>46+t.length+e),0),t=Et(e+22),n=0;for(var{offset:o,name:a,header:r,folder:i}of this.files)t.set32(n,33639248).set16(n+4,20).bytes(n+6,r.array).set8(n+38,i?16:0).set32(n+42,o).bytes(n+46,a),n+=46+a.length;t.set32(n,101010256).set16(n+8,this.files.length).set16(n+10,this.files.length).set32(n+12,e).set32(n+16,this.offset);let s=new Uint8Array(this.offset+t.size),l=0;for(var{payload:d}of this.files)s.set(d.array,l),l+=d.size;return s.set(t.array,l),s}get blob(){return new Blob([this.toBuffer()],{type:"application/zip"})}}Dt.encoder=new TextEncoder;const Lt=(e,t,n,o)=>{if(o){let{width:t,height:n}=e,a=Object.assign(document.createElement("canvas"),{width:t,height:n}),r=a.getContext("2d");r.fillStyle=o,r.fillRect(0,0,t,n),r.drawImage(e,0,0),e=a}return new Promise(((o,a)=>e.toBlob(o,t,n)))},Nt=(e,t)=>{const n=window.URL.createObjectURL(t),o=document.createElement("a");o.style.display="none",o.href=n,o.setAttribute("download",e),void 0===o.download&&o.setAttribute("target","_blank"),document.body.appendChild(o),o.click(),document.body.removeChild(o),setTimeout((()=>window.URL.revokeObjectURL(n)),100)},Ft={asBuffer:(...e)=>Lt(...e).then((e=>e.arrayBuffer())),asDownload:async(e,t,n,o,a)=>{Nt(a,await Lt(e,t,n,o))},asZipDownload:async(e,t,n,o,a,r,i)=>{let s=Bt(a,".zip")||"archive",l=new Dt(s);await Promise.all(e.map((async(e,a)=>{let s=(e=>r.replace("{}",String(e+1).padStart(i,"0")))(a);await l.add(s,await Lt(e,t,n,o))}))),Nt(`${s}.zip`,l.blob)},atScale:(e,t,n)=>e.map((e=>{if(1==t&&!n)return e.canvas;let o=document.createElement("canvas"),a=o.getContext("2d"),r=e.canvas?e.canvas:e;return o.width=r.width*t,o.height=r.height*t,n&&(a.fillStyle=n,a.fillRect(0,0,o.width,o.height)),a.scale(t,t),a.drawImage(r,0,0),o})),options:function(e,{filename:t="",extension:n="",format:o,page:a,quality:r,matte:i,density:s,outline:l,archive:d}={}){var{fromMime:c,toMime:u,expected:h}=new Mt,f=(d=d||"canvas",o||n.replace(/@\d+x$/i,"")||St(t)),g=(o=c(u(f)||f),u(o)),p=e.length;if(!f)throw new Error("Cannot determine image format (use a filename extension or 'format' argument)");if(!o)throw new Error(`Unsupported file format "${f}" (expected ${h})`);if(!p)throw new RangeError("Canvas has no associated contexts (try calling getContext or newPage first)");let m,v,b=t.replace(/{(\d*)}/g,((e,t)=>(v=!0,t=parseInt(t,10),m=isFinite(t)?t:isFinite(m)?m:-1,"{}"))),w=a>0?a-1:a<0?p+a:void 0;if(isFinite(w)&&w<0||w>=p)throw new RangeError(1==p?`Canvas only has a ‘page 1’ (${w} is out of bounds)`:`Canvas has pages 1–${p} (${w} is out of bounds)`);if(e=isFinite(w)?[e[w]]:v||"pdf"==o?e:e.slice(-1),void 0===r)r=.92;else if("number"!=typeof r||!isFinite(r)||r<0||r>1)throw new TypeError("The quality option must be an number in the 0.0–1.0 range");if(void 0===s){let e=(n||Bt(t,f)).match(/@(\d+)x$/i);s=e?parseInt(e[1],10):1}else if("number"!=typeof s||!Number.isInteger(s)||s<1)throw new TypeError("The density option must be a non-negative integer");return void 0===l?l=!0:"svg"==o&&(l=!!l),{filename:t,pattern:b,format:o,mime:g,pages:e,padding:m,quality:r,matte:i,density:s,outline:l,archive:d}}},{asBuffer:Ot,asDownload:zt,asZipDownload:Ut,atScale:Kt,options:Wt}=Ft,qt=Symbol.for("toDataURL"),{CanvasRenderingContext2D:Ht,CanvasGradient:Gt,CanvasPattern:Vt,Image:Qt,ImageData:$t,Path2D:Yt,DOMMatrix:Xt,DOMRect:Zt,DOMPoint:Jt}=window,en={Canvas:class{constructor(e,t){let n=document.createElement("canvas"),o=[];for(var[a,r]of(Object.defineProperty(n,"async",{value:!0,writable:!1,enumerable:!0}),Object.entries({png:()=>Ot(n,"image/png"),jpg:()=>Ot(n,"image/jpeg"),pages:()=>o.concat(n).map((e=>e.getContext("2d")))})))Object.defineProperty(n,a,{get:r});return Object.assign(n,{width:e,height:t,newPage(...e){var{width:t,height:a}=n,r=Object.assign(document.createElement("canvas"),{width:t,height:a});r.getContext("2d").drawImage(n,0,0),o.push(r);var[t,a]=e.length?e:[t,a];return Object.assign(n,{width:t,height:a}).getContext("2d")},saveAs(e,t){t="number"==typeof t?{quality:t}:t;let n=Wt(this.pages,{filename:e,...t}),{pattern:o,padding:a,mime:r,quality:i,matte:s,density:l,archive:d}=n,c=Kt(n.pages,l);return null==a?zt(c[0],r,i,s,e):Ut(c,r,i,s,d,o,a)},toBuffer(e="png",t={}){t="number"==typeof t?{quality:t}:t;let n=Wt(this.pages,{extension:e,...t}),{mime:o,quality:a,matte:r,pages:i,density:s}=n,l=Kt(i,s,r)[0];return Ot(l,o,a,r)},[qt]:n.toDataURL.bind(n),toDataURL(e="png",t={}){t="number"==typeof t?{quality:t}:t;let o=Wt(this.pages,{extension:e,...t}),{mime:a,quality:r,matte:i,pages:s,density:l}=o,d=Kt(s,l,i)[0],c=d[d===n?qt:"toDataURL"](a,r);return Promise.resolve(c)}})}},loadImage:e=>new Promise(((t,n)=>Object.assign(new Qt,{crossOrigin:"Anonymous",onload:t,onerror:n,src:e}))),CanvasRenderingContext2D:Ht,CanvasGradient:Gt,CanvasPattern:Vt,Image:Qt,ImageData:$t,Path2D:Yt,DOMMatrix:Xt,DOMRect:Zt,DOMPoint:Jt},tn=(e,t,n={},o=n)=>{if(Array.isArray(t))t.forEach((t=>tn(e,t,n,o)));else if("function"==typeof t)t(e,n,o,tn);else{const a=Object.keys(t)[0];Array.isArray(t[a])?(o[a]={},tn(e,t[a],n,o[a])):o[a]=t[a](e,n,o,tn)}return n},nn=(e,t)=>(n,o,a,r)=>{t(n,o,a)&&r(n,e,o,a)},on=(e=0)=>t=>t.data[t.pos+e],an=e=>t=>t.data.subarray(t.pos,t.pos+=e),rn=e=>t=>t.data.subarray(t.pos,t.pos+e),sn=e=>t=>Array.from(an(e)(t)).map((e=>String.fromCharCode(e))).join(""),ln=e=>t=>{const n=an(2)(t);return e?(n[1]<<8)+n[0]:(n[0]<<8)+n[1]},dn=(e,t)=>(n,o,a)=>{const r="function"==typeof t?t(n,o,a):t,i=an(e),s=new Array(r);for(var l=0;l<r;l++)s[l]=i(n);return s},cn=e=>t=>{const n=(e=>e.data[e.pos++])(t),o=new Array(8);for(var a=0;a<8;a++)o[7-a]=!!(n&1<<a);return Object.keys(e).reduce(((t,n)=>{const a=e[n];return a.length?t[n]=((e,t,n)=>{for(var o=0,a=0;a<n;a++)o+=e[t+a]&&2**(n-a-1);return o})(o,a.index,a.length):t[n]=o[a.index],t}),{})};var un={blocks:e=>{const t=[],n=e.data.length;for(var o=0,a=(e=>e.data[e.pos++])(e);0!==a&&a;a=(e=>e.data[e.pos++])(e)){if(e.pos+a>=n){const a=n-e.pos;t.push(an(a)(e)),o+=a;break}t.push(an(a)(e)),o+=a}const r=new Uint8Array(o);for(var i=0,s=0;s<t.length;s++)r.set(t[s],i),i+=t[s].length;return r}};const hn=nn({gce:[{codes:an(2)},{byteSize:e=>e.data[e.pos++]},{extras:cn({future:{index:0,length:3},disposal:{index:3,length:3},userInput:{index:6},transparentColorGiven:{index:7}})},{delay:ln(!0)},{transparentColorIndex:e=>e.data[e.pos++]},{terminator:e=>e.data[e.pos++]}]},(e=>{var t=rn(2)(e);return 33===t[0]&&249===t[1]})),fn=nn({image:[{code:e=>e.data[e.pos++]},{descriptor:[{left:ln(!0)},{top:ln(!0)},{width:ln(!0)},{height:ln(!0)},{lct:cn({exists:{index:0},interlaced:{index:1},sort:{index:2},future:{index:3,length:2},size:{index:5,length:3}})}]},nn({lct:dn(3,((e,t,n)=>Math.pow(2,n.descriptor.lct.size+1)))},((e,t,n)=>n.descriptor.lct.exists)),{data:[{minCodeSize:e=>e.data[e.pos++]},un]}]},(e=>44===on()(e))),gn=nn({text:[{codes:an(2)},{blockSize:e=>e.data[e.pos++]},{preData:(e,t,n)=>an(n.text.blockSize)(e)},un]},(e=>{var t=rn(2)(e);return 33===t[0]&&1===t[1]})),pn=nn({application:[{codes:an(2)},{blockSize:e=>e.data[e.pos++]},{id:(e,t,n)=>sn(n.blockSize)(e)},un]},(e=>{var t=rn(2)(e);return 33===t[0]&&255===t[1]})),mn=nn({comment:[{codes:an(2)},un]},(e=>{var t=rn(2)(e);return 33===t[0]&&254===t[1]})),vn=[{header:[{signature:sn(3)},{version:sn(3)}]},{lsd:[{width:ln(!0)},{height:ln(!0)},{gct:cn({exists:{index:0},resolution:{index:1,length:3},sort:{index:4},size:{index:5,length:3}})},{backgroundColorIndex:e=>e.data[e.pos++]},{pixelAspectRatio:e=>e.data[e.pos++]}]},nn({gct:dn(3,((e,t)=>Math.pow(2,t.lsd.gct.size+1)))},((e,t)=>t.lsd.gct.exists)),{frames:((e,t)=>(n,o,a,r)=>{const i=[];let s=n.pos;for(;t(n,o,a);){const t={};if(r(n,e,o,t),n.pos===s)break;s=n.pos,i.push(t)}return i})([hn,pn,mn,fn,gn],(e=>{var t=on()(e);return 33===t||44===t}))}],bn=(e,t,n)=>{if(!e.image)return void console.warn("gif frame does not have associated image.");const{image:o}=e,a=o.descriptor.width*o.descriptor.height;var r=((e,t,n)=>{const o=4096,a=n;var r,i,s,l,d,c,u,h,f,g;const p=new Array(n),m=new Array(o),v=new Array(o),b=new Array(4097);for(d=1+(i=1<<(g=e)),r=i+2,u=-1,s=(1<<(l=g+1))-1,h=0;h<i;h++)m[h]=0,v[h]=h;var w,y,_,k,C,x;for(w=y=_=k=C=x=0,f=0;f<a;){if(0===k){if(y<l){w+=t[x]<<y,y+=8,x++;continue}if(h=w&s,w>>=l,y-=l,h>r||h==d)break;if(h==i){s=(1<<(l=g+1))-1,r=i+2,u=-1;continue}if(-1==u){b[k++]=v[h],u=h,_=h;continue}for(c=h,h==r&&(b[k++]=_,h=u);h>i;)b[k++]=v[h],h=m[h];_=255&v[h],b[k++]=_,r<o&&(m[r]=u,v[r]=_,0==(++r&s)&&r<o&&(l++,s+=r)),u=c}k--,p[C++]=b[k],f++}for(f=C;f<a;f++)p[f]=0;return p})(o.data.minCodeSize,o.data.blocks,a);o.descriptor.lct.interlaced&&(r=((e,t)=>{const n=new Array(e.length),o=e.length/t,a=function(o,a){const r=e.slice(a*t,(a+1)*t);n.splice.apply(n,[o*t,t].concat(r))},r=[0,4,2,1],i=[8,8,4,2];for(var s=0,l=0;l<4;l++)for(var d=r[l];d<o;d+=i[l])a(d,s),s++;return n})(r,o.descriptor.width));const i={pixels:r,dims:{top:e.image.descriptor.top,left:e.image.descriptor.left,width:e.image.descriptor.width,height:e.image.descriptor.height}};return o.descriptor.lct&&o.descriptor.lct.exists?i.colorTable=o.lct:i.colorTable=t,e.gce&&(i.delay=10*(e.gce.delay||10),i.disposalType=e.gce.extras.disposal,e.gce.extras.transparentColorGiven&&(i.transparentIndex=e.gce.transparentColorIndex)),n&&(i.patch=(e=>{const t=e.pixels.length,n=new Uint8ClampedArray(4*t);for(var o=0;o<t;o++){const t=4*o,a=e.pixels[o],r=e.colorTable[a];n[t]=r[0],n[t+1]=r[1],n[t+2]=r[2],n[t+3]=a!==e.transparentIndex?255:0}return n})(i)),i};function wn(e){var t=encodeURI(e).toString().replace(/\%[0-9a-fA-F]{2}/g,"a");return t.length+(t.length!=Number(e)?3:0)}class yn{constructor(e){this.mode=Cn.MODE_8BIT_BYTE,this.parsedData=[],this.data=e;const t=[];for(let n=0,o=this.data.length;n<o;n++){const e=[],o=this.data.charCodeAt(n);o>65536?(e[0]=240|(1835008&o)>>>18,e[1]=128|(258048&o)>>>12,e[2]=128|(4032&o)>>>6,e[3]=128|63&o):o>2048?(e[0]=224|(61440&o)>>>12,e[1]=128|(4032&o)>>>6,e[2]=128|63&o):o>128?(e[0]=192|(1984&o)>>>6,e[1]=128|63&o):e[0]=o,t.push(e)}this.parsedData=Array.prototype.concat.apply([],t),this.parsedData.length!=this.data.length&&(this.parsedData.unshift(191),this.parsedData.unshift(187),this.parsedData.unshift(239))}getLength(){return this.parsedData.length}write(e){for(let t=0,n=this.parsedData.length;t<n;t++)e.put(this.parsedData[t],8)}}class _n{constructor(e=-1,t=kn.L){this.moduleCount=0,this.dataList=[],this.typeNumber=e,this.errorCorrectLevel=t,this.moduleCount=0,this.dataList=[]}addData(e){if(this.typeNumber<=0)this.typeNumber=function(e,t){for(var n=1,o=wn(e),a=0,r=Sn.length;a<r;a++){var i=0;switch(t){case kn.L:i=Sn[a][0];break;case kn.M:i=Sn[a][1];break;case kn.Q:i=Sn[a][2];break;case kn.H:i=Sn[a][3]}if(o<=i)break;n++}if(n>Sn.length)throw new Error("Too long data");return n}(e,this.errorCorrectLevel);else{if(this.typeNumber>40)throw new Error(`Invalid QR version: ${this.typeNumber}`);if(!function(e,t,n){const o=wn(t),a=e-1;let r=0;switch(n){case kn.L:r=Sn[a][0];break;case kn.M:r=Sn[a][1];break;case kn.Q:r=Sn[a][2];break;case kn.H:r=Sn[a][3]}return o<=r}(this.typeNumber,e,this.errorCorrectLevel))throw new Error(`Data is too long for QR version: ${this.typeNumber}`)}const t=new yn(e);this.dataList.push(t),this.dataCache=void 0}isDark(e,t){if(e<0||this.moduleCount<=e||t<0||this.moduleCount<=t)throw new Error(`${e},${t}`);return this.modules[e][t]}getModuleCount(){return this.moduleCount}make(){this.makeImpl(!1,this.getBestMaskPattern())}makeImpl(e,t){this.moduleCount=4*this.typeNumber+17,this.modules=new Array(this.moduleCount);for(let n=0;n<this.moduleCount;n++){this.modules[n]=new Array(this.moduleCount);for(let e=0;e<this.moduleCount;e++)this.modules[n][e]=null}this.setupPositionProbePattern(0,0),this.setupPositionProbePattern(this.moduleCount-7,0),this.setupPositionProbePattern(0,this.moduleCount-7),this.setupPositionAdjustPattern(),this.setupTimingPattern(),this.setupTypeInfo(e,t),this.typeNumber>=7&&this.setupTypeNumber(e),null==this.dataCache&&(this.dataCache=_n.createData(this.typeNumber,this.errorCorrectLevel,this.dataList)),this.mapData(this.dataCache,t)}setupPositionProbePattern(e,t){for(let n=-1;n<=7;n++)if(!(e+n<=-1||this.moduleCount<=e+n))for(let o=-1;o<=7;o++)t+o<=-1||this.moduleCount<=t+o||(this.modules[e+n][t+o]=0<=n&&n<=6&&(0==o||6==o)||0<=o&&o<=6&&(0==n||6==n)||2<=n&&n<=4&&2<=o&&o<=4)}getBestMaskPattern(){if(Number.isInteger(this.maskPattern)&&Object.values(xn).includes(this.maskPattern))return this.maskPattern;let e=0,t=0;for(let n=0;n<8;n++){this.makeImpl(!0,n);const o=An.getLostPoint(this);(0==n||e>o)&&(e=o,t=n)}return t}setupTimingPattern(){for(let e=8;e<this.moduleCount-8;e++)null==this.modules[e][6]&&(this.modules[e][6]=e%2==0);for(let e=8;e<this.moduleCount-8;e++)null==this.modules[6][e]&&(this.modules[6][e]=e%2==0)}setupPositionAdjustPattern(){const e=An.getPatternPosition(this.typeNumber);for(let t=0;t<e.length;t++)for(let n=0;n<e.length;n++){const o=e[t],a=e[n];if(null==this.modules[o][a])for(let e=-2;e<=2;e++)for(let t=-2;t<=2;t++)this.modules[o+e][a+t]=-2==e||2==e||-2==t||2==t||0==e&&0==t}}setupTypeNumber(e){const t=An.getBCHTypeNumber(this.typeNumber);for(var n=0;n<18;n++){var o=!e&&1==(t>>n&1);this.modules[Math.floor(n/3)][n%3+this.moduleCount-8-3]=o}for(n=0;n<18;n++)o=!e&&1==(t>>n&1),this.modules[n%3+this.moduleCount-8-3][Math.floor(n/3)]=o}setupTypeInfo(e,t){const n=this.errorCorrectLevel<<3|t,o=An.getBCHTypeInfo(n);for(var a=0;a<15;a++){var r=!e&&1==(o>>a&1);a<6?this.modules[a][8]=r:a<8?this.modules[a+1][8]=r:this.modules[this.moduleCount-15+a][8]=r}for(a=0;a<15;a++)r=!e&&1==(o>>a&1),a<8?this.modules[8][this.moduleCount-a-1]=r:a<9?this.modules[8][15-a-1+1]=r:this.modules[8][15-a-1]=r;this.modules[this.moduleCount-8][8]=!e}mapData(e,t){let n=-1,o=this.moduleCount-1,a=7,r=0;for(let i=this.moduleCount-1;i>0;i-=2)for(6==i&&i--;;){for(let n=0;n<2;n++)if(null==this.modules[o][i-n]){let s=!1;r<e.length&&(s=1==(e[r]>>>a&1)),An.getMask(t,o,i-n)&&(s=!s),this.modules[o][i-n]=s,a--,-1==a&&(r++,a=7)}if(o+=n,o<0||this.moduleCount<=o){o-=n,n=-n;break}}}static createData(e,t,n){const o=In.getRSBlocks(e,t),a=new Rn;for(var r=0;r<n.length;r++){const t=n[r];a.put(t.mode,4),a.put(t.getLength(),An.getLengthInBits(t.mode,e)),t.write(a)}let i=0;for(r=0;r<o.length;r++)i+=o[r].dataCount;if(a.getLengthInBits()>8*i)throw new Error(`code length overflow. (${a.getLengthInBits()}>${8*i})`);for(a.getLengthInBits()+4<=8*i&&a.put(0,4);a.getLengthInBits()%8!=0;)a.putBit(!1);for(;!(a.getLengthInBits()>=8*i||(a.put(_n.PAD0,8),a.getLengthInBits()>=8*i));)a.put(_n.PAD1,8);return _n.createBytes(a,o)}static createBytes(e,t){let n=0,o=0,a=0;const r=new Array(t.length),i=new Array(t.length);for(var s=0;s<t.length;s++){const d=t[s].dataCount,c=t[s].totalCount-d;o=Math.max(o,d),a=Math.max(a,c),r[s]=new Array(d);for(var l=0;l<r[s].length;l++)r[s][l]=255&e.buffer[l+n];n+=d;const u=An.getErrorCorrectPolynomial(c),h=new Tn(r[s],u.getLength()-1).mod(u);for(i[s]=new Array(u.getLength()-1),l=0;l<i[s].length;l++){const e=l+h.getLength()-i[s].length;i[s][l]=e>=0?h.get(e):0}}let d=0;for(l=0;l<t.length;l++)d+=t[l].totalCount;const c=new Array(d);let u=0;for(l=0;l<o;l++)for(s=0;s<t.length;s++)l<r[s].length&&(c[u++]=r[s][l]);for(l=0;l<a;l++)for(s=0;s<t.length;s++)l<i[s].length&&(c[u++]=i[s][l]);return c}}_n.PAD0=236,_n.PAD1=17;const kn={L:1,M:0,Q:3,H:2},Cn={MODE_NUMBER:1,MODE_ALPHA_NUM:2,MODE_8BIT_BYTE:4,MODE_KANJI:8},xn={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};class An{static getBCHTypeInfo(e){let t=e<<10;for(;An.getBCHDigit(t)-An.getBCHDigit(An.G15)>=0;)t^=An.G15<<An.getBCHDigit(t)-An.getBCHDigit(An.G15);return(e<<10|t)^An.G15_MASK}static getBCHTypeNumber(e){let t=e<<12;for(;An.getBCHDigit(t)-An.getBCHDigit(An.G18)>=0;)t^=An.G18<<An.getBCHDigit(t)-An.getBCHDigit(An.G18);return e<<12|t}static getBCHDigit(e){let t=0;for(;0!=e;)t++,e>>>=1;return t}static getPatternPosition(e){return An.PATTERN_POSITION_TABLE[e-1]}static getMask(e,t,n){switch(e){case xn.PATTERN000:return(t+n)%2==0;case xn.PATTERN001:return t%2==0;case xn.PATTERN010:return n%3==0;case xn.PATTERN011:return(t+n)%3==0;case xn.PATTERN100:return(Math.floor(t/2)+Math.floor(n/3))%2==0;case xn.PATTERN101:return t*n%2+t*n%3==0;case xn.PATTERN110:return(t*n%2+t*n%3)%2==0;case xn.PATTERN111:return(t*n%3+(t+n)%2)%2==0;default:throw new Error(`bad maskPattern:${e}`)}}static getErrorCorrectPolynomial(e){let t=new Tn([1],0);for(let n=0;n<e;n++)t=t.multiply(new Tn([1,Pn.gexp(n)],0));return t}static getLengthInBits(e,t){if(1<=t&&t<10)switch(e){case Cn.MODE_NUMBER:return 10;case Cn.MODE_ALPHA_NUM:return 9;case Cn.MODE_8BIT_BYTE:case Cn.MODE_KANJI:return 8;default:throw new Error(`mode:${e}`)}else if(t<27)switch(e){case Cn.MODE_NUMBER:return 12;case Cn.MODE_ALPHA_NUM:return 11;case Cn.MODE_8BIT_BYTE:return 16;case Cn.MODE_KANJI:return 10;default:throw new Error(`mode:${e}`)}else{if(!(t<41))throw new Error(`type:${t}`);switch(e){case Cn.MODE_NUMBER:return 14;case Cn.MODE_ALPHA_NUM:return 13;case Cn.MODE_8BIT_BYTE:return 16;case Cn.MODE_KANJI:return 12;default:throw new Error(`mode:${e}`)}}}static getLostPoint(e){const t=e.getModuleCount();let n=0;for(var o=0;o<t;o++)for(var a=0;a<t;a++){let r=0;const i=e.isDark(o,a);for(let n=-1;n<=1;n++)if(!(o+n<0||t<=o+n))for(let s=-1;s<=1;s++)a+s<0||t<=a+s||0==n&&0==s||i==e.isDark(o+n,a+s)&&r++;r>5&&(n+=3+r-5)}for(o=0;o<t-1;o++)for(a=0;a<t-1;a++){let t=0;e.isDark(o,a)&&t++,e.isDark(o+1,a)&&t++,e.isDark(o,a+1)&&t++,e.isDark(o+1,a+1)&&t++,0!=t&&4!=t||(n+=3)}for(o=0;o<t;o++)for(a=0;a<t-6;a++)e.isDark(o,a)&&!e.isDark(o,a+1)&&e.isDark(o,a+2)&&e.isDark(o,a+3)&&e.isDark(o,a+4)&&!e.isDark(o,a+5)&&e.isDark(o,a+6)&&(n+=40);for(a=0;a<t;a++)for(o=0;o<t-6;o++)e.isDark(o,a)&&!e.isDark(o+1,a)&&e.isDark(o+2,a)&&e.isDark(o+3,a)&&e.isDark(o+4,a)&&!e.isDark(o+5,a)&&e.isDark(o+6,a)&&(n+=40);let r=0;for(a=0;a<t;a++)for(o=0;o<t;o++)e.isDark(o,a)&&r++;return n+=Math.abs(100*r/t/t-50)/5*10,n}}An.PATTERN_POSITION_TABLE=[[],[6,18],[6,22],[6,26],[6,30],[6,34],[6,22,38],[6,24,42],[6,26,46],[6,28,50],[6,30,54],[6,32,58],[6,34,62],[6,26,46,66],[6,26,48,70],[6,26,50,74],[6,30,54,78],[6,30,56,82],[6,30,58,86],[6,34,62,90],[6,28,50,72,94],[6,26,50,74,98],[6,30,54,78,102],[6,28,54,80,106],[6,32,58,84,110],[6,30,58,86,114],[6,34,62,90,118],[6,26,50,74,98,122],[6,30,54,78,102,126],[6,26,52,78,104,130],[6,30,56,82,108,134],[6,34,60,86,112,138],[6,30,58,86,114,142],[6,34,62,90,118,146],[6,30,54,78,102,126,150],[6,24,50,76,102,128,154],[6,28,54,80,106,132,158],[6,32,58,84,110,136,162],[6,26,54,82,110,138,166],[6,30,58,86,114,142,170]],An.G15=1335,An.G18=7973,An.G15_MASK=21522;class Pn{static glog(e){if(e<1)throw new Error(`glog(${e})`);return Pn.LOG_TABLE[e]}static gexp(e){for(;e<0;)e+=255;for(;e>=256;)e-=255;return Pn.EXP_TABLE[e]}}Pn.EXP_TABLE=new Array(256),Pn.LOG_TABLE=new Array(256),Pn._constructor=function(){for(var e=0;e<8;e++)Pn.EXP_TABLE[e]=1<<e;for(e=8;e<256;e++)Pn.EXP_TABLE[e]=Pn.EXP_TABLE[e-4]^Pn.EXP_TABLE[e-5]^Pn.EXP_TABLE[e-6]^Pn.EXP_TABLE[e-8];for(e=0;e<255;e++)Pn.LOG_TABLE[Pn.EXP_TABLE[e]]=e}();class Tn{constructor(e,t){if(null==e.length)throw new Error(`${e.length}/${t}`);let n=0;for(;n<e.length&&0==e[n];)n++;this.num=new Array(e.length-n+t);for(let o=0;o<e.length-n;o++)this.num[o]=e[o+n]}get(e){return this.num[e]}getLength(){return this.num.length}multiply(e){const t=new Array(this.getLength()+e.getLength()-1);for(let n=0;n<this.getLength();n++)for(let o=0;o<e.getLength();o++)t[n+o]^=Pn.gexp(Pn.glog(this.get(n))+Pn.glog(e.get(o)));return new Tn(t,0)}mod(e){if(this.getLength()-e.getLength()<0)return this;const t=Pn.glog(this.get(0))-Pn.glog(e.get(0)),n=new Array(this.getLength());for(var o=0;o<this.getLength();o++)n[o]=this.get(o);for(o=0;o<e.getLength();o++)n[o]^=Pn.gexp(Pn.glog(e.get(o))+t);return new Tn(n,0).mod(e)}}class In{constructor(e,t){this.totalCount=e,this.dataCount=t}static getRSBlocks(e,t){const n=In.getRsBlockTable(e,t);if(null==n)throw new Error(`bad rs block @ typeNumber:${e}/errorCorrectLevel:${t}`);const o=n.length/3,a=[];for(let r=0;r<o;r++){const e=n[3*r+0],t=n[3*r+1],o=n[3*r+2];for(let n=0;n<e;n++)a.push(new In(t,o))}return a}static getRsBlockTable(e,t){switch(t){case kn.L:return In.RS_BLOCK_TABLE[4*(e-1)+0];case kn.M:return In.RS_BLOCK_TABLE[4*(e-1)+1];case kn.Q:return In.RS_BLOCK_TABLE[4*(e-1)+2];case kn.H:return In.RS_BLOCK_TABLE[4*(e-1)+3];default:return}}}In.RS_BLOCK_TABLE=[[1,26,19],[1,26,16],[1,26,13],[1,26,9],[1,44,34],[1,44,28],[1,44,22],[1,44,16],[1,70,55],[1,70,44],[2,35,17],[2,35,13],[1,100,80],[2,50,32],[2,50,24],[4,25,9],[1,134,108],[2,67,43],[2,33,15,2,34,16],[2,33,11,2,34,12],[2,86,68],[4,43,27],[4,43,19],[4,43,15],[2,98,78],[4,49,31],[2,32,14,4,33,15],[4,39,13,1,40,14],[2,121,97],[2,60,38,2,61,39],[4,40,18,2,41,19],[4,40,14,2,41,15],[2,146,116],[3,58,36,2,59,37],[4,36,16,4,37,17],[4,36,12,4,37,13],[2,86,68,2,87,69],[4,69,43,1,70,44],[6,43,19,2,44,20],[6,43,15,2,44,16],[4,101,81],[1,80,50,4,81,51],[4,50,22,4,51,23],[3,36,12,8,37,13],[2,116,92,2,117,93],[6,58,36,2,59,37],[4,46,20,6,47,21],[7,42,14,4,43,15],[4,133,107],[8,59,37,1,60,38],[8,44,20,4,45,21],[12,33,11,4,34,12],[3,145,115,1,146,116],[4,64,40,5,65,41],[11,36,16,5,37,17],[11,36,12,5,37,13],[5,109,87,1,110,88],[5,65,41,5,66,42],[5,54,24,7,55,25],[11,36,12],[5,122,98,1,123,99],[7,73,45,3,74,46],[15,43,19,2,44,20],[3,45,15,13,46,16],[1,135,107,5,136,108],[10,74,46,1,75,47],[1,50,22,15,51,23],[2,42,14,17,43,15],[5,150,120,1,151,121],[9,69,43,4,70,44],[17,50,22,1,51,23],[2,42,14,19,43,15],[3,141,113,4,142,114],[3,70,44,11,71,45],[17,47,21,4,48,22],[9,39,13,16,40,14],[3,135,107,5,136,108],[3,67,41,13,68,42],[15,54,24,5,55,25],[15,43,15,10,44,16],[4,144,116,4,145,117],[17,68,42],[17,50,22,6,51,23],[19,46,16,6,47,17],[2,139,111,7,140,112],[17,74,46],[7,54,24,16,55,25],[34,37,13],[4,151,121,5,152,122],[4,75,47,14,76,48],[11,54,24,14,55,25],[16,45,15,14,46,16],[6,147,117,4,148,118],[6,73,45,14,74,46],[11,54,24,16,55,25],[30,46,16,2,47,17],[8,132,106,4,133,107],[8,75,47,13,76,48],[7,54,24,22,55,25],[22,45,15,13,46,16],[10,142,114,2,143,115],[19,74,46,4,75,47],[28,50,22,6,51,23],[33,46,16,4,47,17],[8,152,122,4,153,123],[22,73,45,3,74,46],[8,53,23,26,54,24],[12,45,15,28,46,16],[3,147,117,10,148,118],[3,73,45,23,74,46],[4,54,24,31,55,25],[11,45,15,31,46,16],[7,146,116,7,147,117],[21,73,45,7,74,46],[1,53,23,37,54,24],[19,45,15,26,46,16],[5,145,115,10,146,116],[19,75,47,10,76,48],[15,54,24,25,55,25],[23,45,15,25,46,16],[13,145,115,3,146,116],[2,74,46,29,75,47],[42,54,24,1,55,25],[23,45,15,28,46,16],[17,145,115],[10,74,46,23,75,47],[10,54,24,35,55,25],[19,45,15,35,46,16],[17,145,115,1,146,116],[14,74,46,21,75,47],[29,54,24,19,55,25],[11,45,15,46,46,16],[13,145,115,6,146,116],[14,74,46,23,75,47],[44,54,24,7,55,25],[59,46,16,1,47,17],[12,151,121,7,152,122],[12,75,47,26,76,48],[39,54,24,14,55,25],[22,45,15,41,46,16],[6,151,121,14,152,122],[6,75,47,34,76,48],[46,54,24,10,55,25],[2,45,15,64,46,16],[17,152,122,4,153,123],[29,74,46,14,75,47],[49,54,24,10,55,25],[24,45,15,46,46,16],[4,152,122,18,153,123],[13,74,46,32,75,47],[48,54,24,14,55,25],[42,45,15,32,46,16],[20,147,117,4,148,118],[40,75,47,7,76,48],[43,54,24,22,55,25],[10,45,15,67,46,16],[19,148,118,6,149,119],[18,75,47,31,76,48],[34,54,24,34,55,25],[20,45,15,61,46,16]];class Rn{constructor(){this.buffer=[],this.length=0}get(e){const t=Math.floor(e/8);return 1==(this.buffer[t]>>>7-e%8&1)}put(e,t){for(let n=0;n<t;n++)this.putBit(1==(e>>>t-n-1&1))}getLengthInBits(){return this.length}putBit(e){const t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}}const Sn=[[17,14,11,7],[32,26,20,14],[53,42,32,24],[78,62,46,34],[106,84,60,44],[134,106,74,58],[154,122,86,64],[192,152,108,84],[230,180,130,98],[271,213,151,119],[321,251,177,137],[367,287,203,155],[425,331,241,177],[458,362,258,194],[520,412,292,220],[586,450,322,250],[644,504,364,280],[718,560,394,310],[792,624,442,338],[858,666,482,382],[929,711,509,403],[1003,779,565,439],[1091,857,611,461],[1171,911,661,511],[1273,997,715,535],[1367,1059,751,593],[1465,1125,805,625],[1528,1190,868,658],[1628,1264,908,698],[1732,1370,982,742],[1840,1452,1030,790],[1952,1538,1112,842],[2068,1628,1168,898],[2188,1722,1228,958],[2303,1809,1283,983],[2431,1911,1351,1051],[2563,1989,1423,1093],[2699,2099,1499,1139],[2809,2213,1579,1219],[2953,2331,1663,1273]];var Bn=256,Mn=1024,jn=1<<18;function En(e,t){var n,o,a,r,i;function s(e,t,o,a,r){n[t][0]-=e*(n[t][0]-o)/Mn,n[t][1]-=e*(n[t][1]-a)/Mn,n[t][2]-=e*(n[t][2]-r)/Mn}function l(e,t,o,a,r){for(var s,l,d=Math.abs(t-e),c=Math.min(t+e,Bn),u=t+1,h=t-1,f=1;u<c||h>d;)l=i[f++],u<c&&((s=n[u++])[0]-=l*(s[0]-o)/jn,s[1]-=l*(s[1]-a)/jn,s[2]-=l*(s[2]-r)/jn),h>d&&((s=n[h--])[0]-=l*(s[0]-o)/jn,s[1]-=l*(s[1]-a)/jn,s[2]-=l*(s[2]-r)/jn)}function d(e,t,o){var i,s,l,d,c,u=~(1<<31),h=u,f=-1,g=f;for(i=0;i<Bn;i++)s=n[i],(l=Math.abs(s[0]-e)+Math.abs(s[1]-t)+Math.abs(s[2]-o))<u&&(u=l,f=i),(d=l-(a[i]>>12))<h&&(h=d,g=i),c=r[i]>>10,r[i]-=c,a[i]+=c<<10;return r[f]+=64,a[f]-=65536,g}this.buildColormap=function(){!function(){var e,t;for(n=[],o=new Int32Array(256),a=new Int32Array(Bn),r=new Int32Array(Bn),i=new Int32Array(32),e=0;e<Bn;e++)t=(e<<12)/Bn,n[e]=new Float64Array([t,t,t,0]),r[e]=256,a[e]=0}(),function(){var n,o,a,r,c,u,h=e.length,f=30+(t-1)/3,g=h/(3*t),p=~~(g/100),m=Mn,v=2048,b=v>>6;for(b<=1&&(b=0),n=0;n<b;n++)i[n]=m*(256*(b*b-n*n)/(b*b));h<1509?(t=1,o=3):o=h%499!=0?1497:h%491!=0?1473:h%487!=0?1461:1509;var w=0;for(n=0;n<g;)if(s(m,u=d(a=(255&e[w])<<4,r=(255&e[w+1])<<4,c=(255&e[w+2])<<4),a,r,c),0!==b&&l(b,u,a,r,c),(w+=o)>=h&&(w-=h),0===p&&(p=1),++n%p==0)for(m-=m/f,(b=(v-=v/30)>>6)<=1&&(b=0),u=0;u<b;u++)i[u]=m*(256*(b*b-u*u)/(b*b))}(),function(){for(var e=0;e<Bn;e++)n[e][0]>>=4,n[e][1]>>=4,n[e][2]>>=4,n[e][3]=e}(),function(){var e,t,a,r,i,s,l=0,d=0;for(e=0;e<Bn;e++){for(i=e,s=(a=n[e])[1],t=e+1;t<Bn;t++)(r=n[t])[1]<s&&(i=t,s=r[1]);if(r=n[i],e!=i&&(t=r[0],r[0]=a[0],a[0]=t,t=r[1],r[1]=a[1],a[1]=t,t=r[2],r[2]=a[2],a[2]=t,t=r[3],r[3]=a[3],a[3]=t),s!=l){for(o[l]=d+e>>1,t=l+1;t<s;t++)o[t]=e;l=s,d=e}}for(o[l]=d+255>>1,t=l+1;t<256;t++)o[t]=255}()},this.getColormap=function(){for(var e=[],t=[],o=0;o<Bn;o++)t[n[o][3]]=o;for(var a=0,r=0;r<Bn;r++){var i=t[r];e[a++]=n[i][0],e[a++]=n[i][1],e[a++]=n[i][2]}return e},this.lookupRGB=function(e,t,a){for(var r,i,s,l=1e3,d=-1,c=o[t],u=c-1;c<Bn||u>=0;)c<Bn&&((s=(i=n[c])[1]-t)>=l?c=Bn:(c++,s<0&&(s=-s),(r=i[0]-e)<0&&(r=-r),(s+=r)<l&&((r=i[2]-a)<0&&(r=-r),(s+=r)<l&&(l=s,d=i[3])))),u>=0&&((s=t-(i=n[u])[1])>=l?u=-1:(u--,s<0&&(s=-s),(r=i[0]-e)<0&&(r=-r),(s+=r)<l&&((r=i[2]-a)<0&&(r=-r),(s+=r)<l&&(l=s,d=i[3]))));return d}}var Dn=5003,Ln=[0,1,3,7,15,31,63,127,255,511,1023,2047,4095,8191,16383,32767,65535];function Nn(e,t,n,o){var a,r,i,s,l,d,c,u,h,f=Math.max(2,o),g=new Uint8Array(256),p=new Int32Array(Dn),m=new Int32Array(Dn),v=0,b=0,w=!1;function y(e,t){g[r++]=e,r>=254&&C(t)}function _(e){k(Dn),b=l+2,w=!0,P(l,e)}function k(e){for(var t=0;t<e;++t)p[t]=-1}function C(e){r>0&&(e.writeByte(r),e.writeBytes(g,0,r),r=0)}function x(e){return(1<<e)-1}function A(){return 0===c?-1:(--c,255&n[u++])}function P(e,t){for(a&=Ln[v],v>0?a|=e<<v:a=e,v+=h;v>=8;)y(255&a,t),a>>=8,v-=8;if((b>i||w)&&(w?(i=x(h=s),w=!1):(++h,i=12==h?4096:x(h))),e==d){for(;v>0;)y(255&a,t),a>>=8,v-=8;C(t)}}this.encode=function(n){n.writeByte(f),c=e*t,u=0,function(e,t){var n,o,a,c,u,f,g;for(w=!1,i=x(h=s=e),d=1+(l=1<<e-1),b=l+2,r=0,c=A(),g=0,n=Dn;n<65536;n*=2)++g;g=8-g,k(f=Dn),P(l,t);e:for(;-1!=(o=A());)if(n=(o<<12)+c,p[a=o<<g^c]!==n){if(p[a]>=0){u=f-a,0===a&&(u=1);do{if((a-=u)<0&&(a+=f),p[a]===n){c=m[a];continue e}}while(p[a]>=0)}P(c,t),c=o,b<4096?(m[a]=b++,p[a]=n):_(t)}else c=m[a];P(c,t),P(d,t)}(f+1,n),n.writeByte(0)}}function Fn(){this.page=-1,this.pages=[],this.newPage()}Fn.pageSize=4096,Fn.charMap={};for(var On=0;On<256;On++)Fn.charMap[On]=String.fromCharCode(On);function zn(e,t){this.width=~~e,this.height=~~t,this.transparent=null,this.transIndex=0,this.repeat=-1,this.delay=0,this.image=null,this.pixels=null,this.indexedPixels=null,this.colorDepth=null,this.colorTab=null,this.neuQuant=null,this.usedEntry=new Array,this.palSize=7,this.dispose=-1,this.firstFrame=!0,this.sample=10,this.dither=!1,this.globalPalette=!1,this.out=new Fn}Fn.prototype.newPage=function(){this.pages[++this.page]=new Uint8Array(Fn.pageSize),this.cursor=0},Fn.prototype.getData=function(){for(var e="",t=0;t<this.pages.length;t++)for(var n=0;n<Fn.pageSize;n++)e+=Fn.charMap[this.pages[t][n]];return e},Fn.prototype.toFlattenUint8Array=function(){const e=[];for(var t=0;t<this.pages.length;t++)if(t===this.pages.length-1){const n=Uint8Array.from(this.pages[t].slice(0,this.cursor));e.push(n)}else e.push(this.pages[t]);const n=new Uint8Array(e.reduce(((e,t)=>e+t.length),0));return e.reduce(((e,t)=>(n.set(t,e),e+t.length)),0),n},Fn.prototype.writeByte=function(e){this.cursor>=Fn.pageSize&&this.newPage(),this.pages[this.page][this.cursor++]=e},Fn.prototype.writeUTFBytes=function(e){for(var t=e.length,n=0;n<t;n++)this.writeByte(e.charCodeAt(n))},Fn.prototype.writeBytes=function(e,t,n){for(var o=n||e.length,a=t||0;a<o;a++)this.writeByte(e[a])},zn.prototype.setDelay=function(e){this.delay=Math.round(e/10)},zn.prototype.setFrameRate=function(e){this.delay=Math.round(100/e)},zn.prototype.setDispose=function(e){e>=0&&(this.dispose=e)},zn.prototype.setRepeat=function(e){this.repeat=e},zn.prototype.setTransparent=function(e){this.transparent=e},zn.prototype.addFrame=function(e){this.image=e,this.colorTab=this.globalPalette&&this.globalPalette.slice?this.globalPalette:null,this.getImagePixels(),this.analyzePixels(),!0===this.globalPalette&&(this.globalPalette=this.colorTab),this.firstFrame&&(this.writeHeader(),this.writeLSD(),this.writePalette(),this.repeat>=0&&this.writeNetscapeExt()),this.writeGraphicCtrlExt(),this.writeImageDesc(),this.firstFrame||this.globalPalette||this.writePalette(),this.writePixels(),this.firstFrame=!1},zn.prototype.finish=function(){this.out.writeByte(59)},zn.prototype.setQuality=function(e){e<1&&(e=1),this.sample=e},zn.prototype.setDither=function(e){!0===e&&(e="FloydSteinberg"),this.dither=e},zn.prototype.setGlobalPalette=function(e){this.globalPalette=e},zn.prototype.getGlobalPalette=function(){return this.globalPalette&&this.globalPalette.slice&&this.globalPalette.slice(0)||this.globalPalette},zn.prototype.writeHeader=function(){this.out.writeUTFBytes("GIF89a")},zn.prototype.analyzePixels=function(){this.colorTab||(this.neuQuant=new En(this.pixels,this.sample),this.neuQuant.buildColormap(),this.colorTab=this.neuQuant.getColormap()),this.dither?this.ditherPixels(this.dither.replace("-serpentine",""),null!==this.dither.match(/-serpentine/)):this.indexPixels(),this.pixels=null,this.colorDepth=8,this.palSize=7,null!==this.transparent&&(this.transIndex=this.findClosest(this.transparent,!0))},zn.prototype.indexPixels=function(e){var t=this.pixels.length/3;this.indexedPixels=new Uint8Array(t);for(var n=0,o=0;o<t;o++){var a=this.findClosestRGB(255&this.pixels[n++],255&this.pixels[n++],255&this.pixels[n++]);this.usedEntry[a]=!0,this.indexedPixels[o]=a}},zn.prototype.ditherPixels=function(e,t){var n={FalseFloydSteinberg:[[3/8,1,0],[3/8,0,1],[2/8,1,1]],FloydSteinberg:[[7/16,1,0],[3/16,-1,1],[5/16,0,1],[1/16,1,1]],Stucki:[[8/42,1,0],[4/42,2,0],[2/42,-2,1],[4/42,-1,1],[8/42,0,1],[4/42,1,1],[2/42,2,1],[1/42,-2,2],[2/42,-1,2],[4/42,0,2],[2/42,1,2],[1/42,2,2]],Atkinson:[[1/8,1,0],[1/8,2,0],[1/8,-1,1],[1/8,0,1],[1/8,1,1],[1/8,0,2]]};if(!e||!n[e])throw"Unknown dithering kernel: "+e;var o=n[e],a=0,r=this.height,i=this.width,s=this.pixels,l=t?-1:1;this.indexedPixels=new Uint8Array(this.pixels.length/3);for(var d=0;d<r;d++){t&&(l*=-1);for(var c=1==l?0:i-1,u=1==l?i:0;c!==u;c+=l){var h=3*(a=d*i+c),f=s[h],g=s[h+1],p=s[h+2];h=this.findClosestRGB(f,g,p),this.usedEntry[h]=!0,this.indexedPixels[a]=h,h*=3;for(var m=f-this.colorTab[h],v=g-this.colorTab[h+1],b=p-this.colorTab[h+2],w=1==l?0:o.length-1,y=1==l?o.length:0;w!==y;w+=l){var _=o[w][1],k=o[w][2];if(_+c>=0&&_+c<i&&k+d>=0&&k+d<r){var C=o[w][0];h=a+_+k*i,s[h*=3]=Math.max(0,Math.min(255,s[h]+m*C)),s[h+1]=Math.max(0,Math.min(255,s[h+1]+v*C)),s[h+2]=Math.max(0,Math.min(255,s[h+2]+b*C))}}}}},zn.prototype.findClosest=function(e,t){return this.findClosestRGB((16711680&e)>>16,(65280&e)>>8,255&e,t)},zn.prototype.findClosestRGB=function(e,t,n,o){if(null===this.colorTab)return-1;if(this.neuQuant&&!o)return this.neuQuant.lookupRGB(e,t,n);for(var a=0,r=16777216,i=this.colorTab.length,s=0,l=0;s<i;l++){var d=e-(255&this.colorTab[s++]),c=t-(255&this.colorTab[s++]),u=n-(255&this.colorTab[s++]),h=d*d+c*c+u*u;(!o||this.usedEntry[l])&&h<r&&(r=h,a=l)}return a},zn.prototype.getImagePixels=function(){var e=this.width,t=this.height;this.pixels=new Uint8Array(e*t*3);for(var n=this.image,o=0,a=0,r=0;r<t;r++)for(var i=0;i<e;i++)this.pixels[a++]=n[o++],this.pixels[a++]=n[o++],this.pixels[a++]=n[o++],o++},zn.prototype.writeGraphicCtrlExt=function(){var e,t;this.out.writeByte(33),this.out.writeByte(249),this.out.writeByte(4),null===this.transparent?(e=0,t=0):(e=1,t=2),this.dispose>=0&&(t=7&this.dispose),t<<=2,this.out.writeByte(0|t|e),this.writeShort(this.delay),this.out.writeByte(this.transIndex),this.out.writeByte(0)},zn.prototype.writeImageDesc=function(){this.out.writeByte(44),this.writeShort(0),this.writeShort(0),this.writeShort(this.width),this.writeShort(this.height),this.firstFrame||this.globalPalette?this.out.writeByte(0):this.out.writeByte(128|this.palSize)},zn.prototype.writeLSD=function(){this.writeShort(this.width),this.writeShort(this.height),this.out.writeByte(240|this.palSize),this.out.writeByte(0),this.out.writeByte(0)},zn.prototype.writeNetscapeExt=function(){this.out.writeByte(33),this.out.writeByte(255),this.out.writeByte(11),this.out.writeUTFBytes("NETSCAPE2.0"),this.out.writeByte(3),this.out.writeByte(1),this.writeShort(this.repeat),this.out.writeByte(0)},zn.prototype.writePalette=function(){this.out.writeBytes(this.colorTab);for(var e=768-this.colorTab.length,t=0;t<e;t++)this.out.writeByte(0)},zn.prototype.writeShort=function(e){this.out.writeByte(255&e),this.out.writeByte(e>>8&255)},zn.prototype.writePixels=function(){new Nn(this.width,this.height,this.indexedPixels,this.colorDepth).encode(this.out)},zn.prototype.stream=function(){return this.out};var Un=globalThis&&globalThis.__awaiter||function(e,t,n,o){return new(n||(n=Promise))((function(a,r){function i(e){try{l(o.next(e))}catch(t){r(t)}}function s(e){try{l(o.throw(e))}catch(t){r(t)}}function l(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(i,s)}l((o=o.apply(e,t||[])).next())}))};const{Canvas:Kn}=en,Wn=.4;function qn(e){if(e)return new Promise((function(n,o){if("data"==e.slice(0,4)){let a=new Image;return a.onload=function(){n(a),t(a)},a.onerror=function(){o("Image load error"),t(a)},void(a.src=e)}let a=new Image;a.setAttribute("crossOrigin","Anonymous"),a.onload=function(){n(a)},a.onerror=function(){o("Image load error")},a.src=e}));function t(e){e.onload=null,e.onerror=null}}class Hn{constructor(e){const t=Object.assign({},e);if(Object.keys(Hn.defaultOptions).forEach((e=>{e in t||Object.defineProperty(t,e,{value:Hn.defaultOptions[e],enumerable:!0,writable:!0})})),t.components?"object"==typeof t.components&&Object.keys(Hn.defaultComponentOptions).forEach((e=>{e in t.components?Object.defineProperty(t.components,e,{value:Object.assign(Object.assign({},Hn.defaultComponentOptions[e]),t.components[e]),enumerable:!0,writable:!0}):Object.defineProperty(t.components,e,{value:Hn.defaultComponentOptions[e],enumerable:!0,writable:!0})})):t.components=Hn.defaultComponentOptions,null!==t.dotScale&&void 0!==t.dotScale){if(t.dotScale<=0||t.dotScale>1)throw new Error("dotScale should be in range (0, 1].");t.components.data.scale=t.dotScale,t.components.timing.scale=t.dotScale,t.components.alignment.scale=t.dotScale}this.options=t,this.canvas=new Kn(e.size,e.size),this.canvasContext=this.canvas.getContext("2d"),this.qrCode=new _n(-1,this.options.correctLevel),Number.isInteger(this.options.maskPattern)&&(this.qrCode.maskPattern=this.options.maskPattern),Number.isInteger(this.options.version)&&(this.qrCode.typeNumber=this.options.version),this.qrCode.addData(this.options.text),this.qrCode.make()}draw(){return new Promise((e=>this._draw().then(e)))}_clear(){this.canvasContext.clearRect(0,0,this.canvas.width,this.canvas.height)}static _prepareRoundedCornerClip(e,t,n,o,a,r){e.beginPath(),e.moveTo(t,n),e.arcTo(t+o,n,t+o,n+a,r),e.arcTo(t+o,n+a,t,n+a,r),e.arcTo(t,n+a,t,n,r),e.arcTo(t,n,t+o,n,r),e.closePath()}static _getAverageRGB(e){const t={r:0,g:0,b:0};let n,o,a=-4;const r={r:0,g:0,b:0};let i=0;o=e.naturalHeight||e.height,n=e.naturalWidth||e.width;const s=new Kn(n,o).getContext("2d");if(!s)return t;let l;s.drawImage(e,0,0);try{l=s.getImageData(0,0,n,o)}catch(d){return t}for(;(a+=20)<l.data.length;)l.data[a]>200||l.data[a+1]>200||l.data[a+2]>200||(++i,r.r+=l.data[a],r.g+=l.data[a+1],r.b+=l.data[a+2]);return r.r=~~(r.r/i),r.g=~~(r.g/i),r.b=~~(r.b/i),r}static _drawDot(e,t,n,o,a=0,r=1){e.fillRect((t+a)*o,(n+a)*o,r*o,r*o)}static _drawAlignProtector(e,t,n,o){e.clearRect((t-2)*o,(n-2)*o,5*o,5*o),e.fillRect((t-2)*o,(n-2)*o,5*o,5*o)}static _drawAlign(e,t,n,o,a=0,r=1,i,s){const l=e.fillStyle;e.fillStyle=i,new Array(4).fill(0).map(((i,s)=>{Hn._drawDot(e,t-2+s,n-2,o,a,r),Hn._drawDot(e,t+2,n-2+s,o,a,r),Hn._drawDot(e,t+2-s,n+2,o,a,r),Hn._drawDot(e,t-2,n+2-s,o,a,r)})),Hn._drawDot(e,t,n,o,a,r),s||(e.fillStyle="rgba(255, 255, 255, 0.6)",new Array(2).fill(0).map(((i,s)=>{Hn._drawDot(e,t-1+s,n-1,o,a,r),Hn._drawDot(e,t+1,n-1+s,o,a,r),Hn._drawDot(e,t+1-s,n+1,o,a,r),Hn._drawDot(e,t-1,n+1-s,o,a,r)}))),e.fillStyle=l}_draw(){var e,t,n,o,a,r,i,s,l,d,c,u,h,f,g,p,m,v,b;return Un(this,void 0,void 0,(function*(){const w=null===(e=this.qrCode)||void 0===e?void 0:e.moduleCount,y=this.options.size;let _=this.options.margin;(_<0||2*_>=y)&&(_=0);const k=Math.ceil(_),C=y-2*_,x=this.options.whiteMargin,A=this.options.backgroundDimming,P=Math.ceil(C/w),T=P*w,I=T+2*k,R=new Kn(I,I),S=R.getContext("2d");this._clear(),S.save(),S.translate(k,k);const B=new Kn(I,I),M=B.getContext("2d");let j=null,E=[];if(this.options.gifBackground){const e=(e=>{const t=new Uint8Array(e);return tn({data:t,pos:0},vn)})(this.options.gifBackground);if(j=e,L=!0,E=(D=e).frames.filter((e=>e.image)).map((e=>bn(e,D.gct,L))),this.options.autoColor){let e=0,t=0,n=0,o=0;for(let a=0;a<E[0].colorTable.length;a++){const r=E[0].colorTable[a];r[0]>200||r[1]>200||r[2]>200||0===r[0]&&0===r[1]&&0===r[2]||(o++,e+=r[0],t+=r[1],n+=r[2])}e=~~(e/o),t=~~(t/o),n=~~(n/o),this.options.colorDark=`rgb(${e},${t},${n})`}}else if(this.options.backgroundImage){const e=yield qn(this.options.backgroundImage);if(this.options.autoColor){const t=Hn._getAverageRGB(e);this.options.colorDark=`rgb(${t.r},${t.g},${t.b})`}M.drawImage(e,0,0,e.width,e.height,0,0,I,I),M.rect(0,0,I,I),M.fillStyle=A,M.fill()}else M.rect(0,0,I,I),M.fillStyle=this.options.colorLight,M.fill();var D,L;const N=An.getPatternPosition(this.qrCode.typeNumber),F=(null===(n=null===(t=this.options.components)||void 0===t?void 0:t.data)||void 0===n?void 0:n.scale)||Wn,O=.5*(1-F);for(let e=0;e<w;e++)for(let t=0;t<w;t++){const n=this.qrCode.isDark(e,t),o=t<8&&(e<8||e>=w-8)||t>=w-8&&e<8;let a=o||6==e&&t>=8&&t<=w-8||6==t&&e>=8&&e<=w-8;for(let s=1;s<N.length-1;s++)a=a||e>=N[s]-2&&e<=N[s]+2&&t>=N[s]-2&&t<=N[s]+2;const r=t*P+(a?0:O*P),i=e*P+(a?0:O*P);S.strokeStyle=n?this.options.colorDark:this.options.colorLight,S.lineWidth=.5,S.fillStyle=n?this.options.colorDark:this.options.colorLight,0===N.length?a||S.fillRect(r,i,(a?1:F)*P,(a?1:F)*P):a||t<w-4&&t>=w-4-5&&e<w-4&&e>=w-4-5||S.fillRect(r,i,(a?1:F)*P,(a?1:F)*P)}const z=N[N.length-1],U=this.options.colorLight;if(S.fillStyle=U,S.fillRect(0,0,8*P,8*P),S.fillRect(0,(w-8)*P,8*P,8*P),S.fillRect((w-8)*P,0,8*P,8*P),(null===(a=null===(o=this.options.components)||void 0===o?void 0:o.timing)||void 0===a?void 0:a.protectors)&&(S.fillRect(8*P,6*P,(w-8-8)*P,P),S.fillRect(6*P,8*P,P,(w-8-8)*P)),(null===(i=null===(r=this.options.components)||void 0===r?void 0:r.cornerAlignment)||void 0===i?void 0:i.protectors)&&Hn._drawAlignProtector(S,z,z,P),null===(l=null===(s=this.options.components)||void 0===s?void 0:s.alignment)||void 0===l?void 0:l.protectors)for(let e=0;e<N.length;e++)for(let t=0;t<N.length;t++){const n=N[t],o=N[e];(6!==n||6!==o&&o!==z)&&(6!==o||6!==n&&n!==z)&&(n===z&&o===z||Hn._drawAlignProtector(S,n,o,P))}S.fillStyle=this.options.colorDark,S.fillRect(0,0,7*P,P),S.fillRect((w-7)*P,0,7*P,P),S.fillRect(0,6*P,7*P,P),S.fillRect((w-7)*P,6*P,7*P,P),S.fillRect(0,(w-7)*P,7*P,P),S.fillRect(0,(w-7+6)*P,7*P,P),S.fillRect(0,0,P,7*P),S.fillRect(6*P,0,P,7*P),S.fillRect((w-7)*P,0,P,7*P),S.fillRect((w-7+6)*P,0,P,7*P),S.fillRect(0,(w-7)*P,P,7*P),S.fillRect(6*P,(w-7)*P,P,7*P),S.fillRect(2*P,2*P,3*P,3*P),S.fillRect((w-7+2)*P,2*P,3*P,3*P),S.fillRect(2*P,(w-7+2)*P,3*P,3*P);const K=(null===(c=null===(d=this.options.components)||void 0===d?void 0:d.timing)||void 0===c?void 0:c.scale)||Wn,W=.5*(1-K);for(let e=0;e<w-8;e+=2)Hn._drawDot(S,8+e,6,P,W,K),Hn._drawDot(S,6,8+e,P,W,K);const q=(null===(h=null===(u=this.options.components)||void 0===u?void 0:u.cornerAlignment)||void 0===h?void 0:h.scale)||Wn,H=.5*(1-q);Hn._drawAlign(S,z,z,P,H,q,this.options.colorDark,(null===(g=null===(f=this.options.components)||void 0===f?void 0:f.cornerAlignment)||void 0===g?void 0:g.protectors)||!1);const G=(null===(m=null===(p=this.options.components)||void 0===p?void 0:p.alignment)||void 0===m?void 0:m.scale)||Wn,V=.5*(1-G);for(let e=0;e<N.length;e++)for(let t=0;t<N.length;t++){const n=N[t],o=N[e];(6!==n||6!==o&&o!==z)&&(6!==o||6!==n&&n!==z)&&(n===z&&o===z||Hn._drawAlign(S,n,o,P,V,G,this.options.colorDark,(null===(b=null===(v=this.options.components)||void 0===v?void 0:v.alignment)||void 0===b?void 0:b.protectors)||!1))}if(x&&(S.fillStyle=this.options.backgroundColor,S.fillRect(-k,-k,I,k),S.fillRect(-k,T,I,k),S.fillRect(T,-k,k,I),S.fillRect(-k,-k,k,I)),this.options.logoImage){const e=yield qn(this.options.logoImage);let t=this.options.logoScale,n=this.options.logoMargin,o=this.options.logoCornerRadius;(t<=0||t>=1)&&(t=.2),n<0&&(n=0),o<0&&(o=0);const a=T*t,r=.5*(I-a),i=r;S.restore(),S.fillStyle=this.options.logoBackgroundColor,S.save(),Hn._prepareRoundedCornerClip(S,r-n,i-n,a+2*n,a+2*n,o+n),S.clip();const s=S.globalCompositeOperation;S.globalCompositeOperation="destination-out",S.fill(),S.globalCompositeOperation=s,S.restore(),S.save(),Hn._prepareRoundedCornerClip(S,r,i,a,a,o),S.clip(),S.drawImage(e,r,i,a,a),S.restore(),S.save(),S.translate(k,k)}if(j){let e,t,n,o,a,r;if(E.forEach((function(i){e||(e=new zn(y,y),e.setDelay(i.delay),e.setRepeat(0));const{width:s,height:l}=i.dims;t||(t=new Kn(s,l),n=t.getContext("2d"),n.rect(0,0,t.width,t.height),n.fillStyle="#ffffff",n.fill()),o&&r&&s===o.width&&l===o.height||(o=new Kn(s,l),a=o.getContext("2d"),r=a.createImageData(s,l)),r.data.set(i.patch),a.putImageData(r,0,0),n.drawImage(o.getContext("2d").canvas,i.dims.left,i.dims.top);const d=new Kn(I,I),c=d.getContext("2d");c.drawImage(t.getContext("2d").canvas,0,0,I,I),c.rect(0,0,I,I),c.fillStyle=A,c.fill(),c.drawImage(R.getContext("2d").canvas,0,0,I,I);const u=new Kn(y,y),h=u.getContext("2d");h.drawImage(d.getContext("2d").canvas,0,0,y,y),e.addFrame(h.getImageData(0,0,u.width,u.height).data)})),!e)throw new Error("No frames.");if(e.finish(),Gn(this.canvas)){const t=e.stream().toFlattenUint8Array().reduce(((e,t)=>e+String.fromCharCode(t)),"");return Promise.resolve(`data:image/gif;base64,${window.btoa(t)}`)}return Promise.resolve(Buffer.from(e.stream().toFlattenUint8Array()))}{M.drawImage(R.getContext("2d").canvas,0,0,I,I),S.drawImage(B.getContext("2d").canvas,-k,-k,I,I);const e=new Kn(y,y);e.getContext("2d").drawImage(R.getContext("2d").canvas,0,0,y,y),this.canvas=e;const t=this.options.gifBackground?"gif":"png";return Gn(this.canvas)?Promise.resolve(this.canvas.toDataURL(t)):Promise.resolve(this.canvas.toBuffer(t))}}))}}function Gn(e){try{return e instanceof HTMLElement}catch(t){return"object"==typeof e&&1===e.nodeType&&"object"==typeof e.style&&"object"==typeof e.ownerDocument}}Hn.CorrectLevel=kn,Hn.defaultComponentOptions={data:{scale:.4},timing:{scale:.5,protectors:!1},alignment:{scale:.5,protectors:!1},cornerAlignment:{scale:.5,protectors:!0}},Hn.defaultOptions={text:"",size:400,margin:20,colorDark:"#000000",colorLight:"rgba(255, 255, 255, 0.6)",correctLevel:kn.M,backgroundImage:void 0,backgroundDimming:"rgba(0,0,0,0)",logoImage:void 0,logoScale:.2,logoMargin:4,logoCornerRadius:8,whiteMargin:!0,components:Hn.defaultComponentOptions,autoColor:!0,logoBackgroundColor:"#ffffff",backgroundColor:"#ffffff"};const Vn=s({name:"TheQrCode",props:{text:{type:String,required:!0},qid:{type:String},correctLevel:{type:Number,default:0},size:{type:Number,default:220},margin:{type:Number,default:20},colorDark:{type:String,default:"#000000"},colorLight:{type:String,default:"#FFFFFF"},bgSrc:{type:String,default:void 0},background:{type:String,default:"rgba(0,0,0,0)"},backgroundDimming:{type:String,default:"rgba(0,0,0,0)"},logoSrc:{type:String,default:void 0},logoBackgroundColor:{type:String,default:"rgba(255,255,255,1)"},gifBgSrc:{type:String,default:void 0},logoScale:{type:Number,default:.2},logoMargin:{type:Number,default:0},logoCornerRadius:{type:Number,default:8},whiteMargin:{type:[Boolean,String],default:!0},dotScale:{type:Number,default:1},autoColor:{type:[Boolean,String],default:!0},binarize:{type:[Boolean,String],default:!1},binarizeThreshold:{type:Number,default:128},callback:{type:Function,default:function(){}},bindElement:{type:Boolean,default:!0},backgroundColor:{type:String,default:"#FFFFFF"},components:{default:function(){return{data:{scale:1},timing:{scale:1,protectors:!1},alignment:{scale:1,protectors:!1},cornerAlignment:{scale:1,protectors:!0}}}}},data:()=>({imgUrl:""}),watch:{$props:{deep:!0,handler(){this.main()}}},mounted(){this.main()},methods:{async main(){if(this.gifBgSrc){const t=await(e=this.gifBgSrc,new Promise((t=>{const n=new XMLHttpRequest;n.responseType="blob",n.onload=function(){const e=new FileReader;e.onloadend=function(){t(e.result)},e.readAsArrayBuffer(n.response)},n.open("GET",e),n.send()}))),n=this.logoSrc;return void this.render(void 0,n,t)}var e;const t=this.bgSrc,n=this.logoSrc;this.render(t,n)},async render(e,t,n){console.log(e,t,n),new Hn({gifBackground:n,text:this.text,size:this.size}).draw().then((e=>{console.log("🚀 ~ dataUri:",e),this.imgUrl=e,this.callback&&this.callback(e,this.qid)}))}},render(){return ye(Ie,null,[this.bindElement&&this.imgUrl&&ye("img",{style:"display: inline-block",src:this.imgUrl},null)])}}),Qn=s({name:"school-info",setup(){const e=be(),t=we({areaList:[]}),n=we({name:e.info.schoolInfos?.[0]?.name,logo:e.info.schoolInfos?.[0]?.logo||e.info.avatar,provinceCode:e.info.schoolInfos?.[0]?.provinceCode||"",cityCode:e.info.schoolInfos?.[0]?.cityCode||"",regionCode:e.info.schoolInfos?.[0]?.regionCode||""}),o=we({loading:!1,schoolLoading:!0,dataList:[],disabled:!0,modal:!1,qrModal:!1}),a=async()=>{o.loading=!0;const t=await(n={schoolId:e.info.schoolInfos?.[0]?.id,page:1,rows:1e3},Re.post("/edu-app/teacher/page",{data:n}));var n;o.loading=!1,200===t?.code&&Array.isArray(t?.data?.rows)&&(o.dataList=t.data.rows)};Se((()=>{(async()=>{const e=await ht();200===e?.code&&(t.areaList=e.data)})(),a()}));const r=Ke(),i=me(),s=e=>{const t="LOCKED"===e.status?"解冻":"冻结";r.warning({title:"温馨提示",content:`是否${t}"${e.nickname}"?`,positiveText:"确定",negativeText:"取消",onPositiveClick:async()=>{var n;await(n={ids:[e.id],status:"LOCKED"===e.status?"ACTIVATION":"LOCKED"},Re.post("/edu-app/teacher/updateStatus",{data:n})),a(),i.success(t+"成功")}})},l=e=>{r.warning({title:"警告",content:`重置"${e.nickname}"的密码,是否继续?`,positiveText:"确定",negativeText:"取消",onPositiveClick:async()=>{var t;await(t={userId:e.id,password:"ktyq"+e.phone.substr(7),clientType:"TEACHER"},Re.post("/edu-app/user/resetPassword",{data:t,requestType:"form"})),i.success("重置成功")}})},d=c(),u=()=>{d.value?.validate((async t=>{var a;t||(o.schoolLoading=!1,await(a={...e.info.schoolInfos?.[0],...n},Re.post("/edu-app/school/update",{data:a})),o.schoolLoading=!0,i.success("修改成功"),o.disabled=!0)}))},h=()=>{const t=`tenantId=${e.info.schoolInfos?.[0]?.tenantId}&schoolId=${e.info.schoolInfos?.[0]?.id}&schoolName=${e.info.schoolInfos?.[0]?.name}`,n=`${location.origin}/classroom-app/#/teaher-register?`+t;return console.log(n),n};return()=>ye("div",{class:bt},[ye(Pe,{wrapItem:!1,align:"center"},{default:()=>[ye("div",{class:gt},[ye(Be,{previewDisabled:!1,width:100,height:100,src:n.logo},null),ye("div",{style:{display:o.disabled?"none":""},class:pt},[Te("修改头像"),o.schoolLoading&&ye(Ve,{class:[mt],cropper:!0,"onUpdate:fileList":e=>{n.logo=e}},null)])]),ye(_e,{ref:d,class:vt,model:n,style:{paddingTop:"30px",paddingLeft:"80px"},disabled:o.disabled},{default:()=>[ye(Pe,{size:100},{default:()=>[ye(ke,{label:"学校名称",path:"name",showRequireMark:!1,rule:[{required:!0,message:"请填写学校名称",trigger:"blur"}]},{default:()=>[ye(Ce,{bordered:!o.disabled,maxlength:20,value:n.name,"onUpdate:value":e=>n.name=e},null)]}),ye(ke,{label:"城区"},{default:()=>[ye(lt,{placeholder:"请选择城区",bordered:!o.disabled,options:t.areaList,labelField:"name",valueField:"code",childrenField:"areas",checkStrategy:"child",expandTrigger:"hover",defaultValue:e.info.schoolInfos?.[0]?.regionCode||e.info.schoolInfos?.[0]?.cityCode,"onUpdate:value":(e,t,o)=>{n.provinceCode=o[0]?.code,n.cityCode=o[1]?.code,n.regionCode=o[2]?.code}},null)]}),ye(ke,null,{default:()=>[o.disabled?ye(Pe,{class:_t,align:"center",justify:"end"},{default:()=>[ye(Ae,{class:kt,color:"#f24433",onClick:()=>o.disabled=!1},{default:()=>[Te("修改信息")]})]}):ye(Pe,{class:_t,align:"center",justify:"end"},{default:()=>[ye(Ae,{class:kt,onClick:()=>o.disabled=!0},{default:()=>[Te("取消")]}),ye(Ae,{class:kt,loading:!o.schoolLoading,type:"primary",onClick:()=>u()},{default:()=>[Te("完成")]})]})]})]})]})]}),ye(Pe,{style:{padding:"32px 0"}},{default:()=>[ye(Ae,{type:"primary",renderIcon:()=>ye(We,{component:ye(At,null,null)},null),onClick:()=>o.modal=!0},{default:()=>[Te("添加老师")]}),ye(Ae,{type:"primary",onClick:()=>o.qrModal=!0},{default:()=>[Te("老师注册二维码")]})]}),ye(qe,{loading:o.loading,columns:[{title:"老师姓名",key:"nickname"},{title:"手机号码",key:"phone"},{title:"性别",key:"questionTypeCode",render:e=>ye("div",null,[e.gender?"男":"女"])},{title:"状态",key:"statusName",render:e=>ye("div",null,["ACTIVATION"===e.status?ye(Ae,{text:!0},{default:()=>[e.statusName]}):ye(Ae,{class:wt,text:!0},{default:()=>[e.statusName]})])},{title:"操作",key:"titleImg",render:e=>ye(Pe,null,{default:()=>[ye(Ae,{type:"primary",quaternary:!0,size:"small",onClick:()=>l(e)},{default:()=>[Te("重置密码")]}),"ACTIVATION"===e.status?ye(Ae,{type:"primary",quaternary:!0,size:"small",onClick:()=>s(e)},{default:()=>[Te("冻结")]}):ye(Ae,{class:wt,quaternary:!0,size:"small",onClick:()=>s(e)},{default:()=>[Te("解冻")]})]})}],data:o.dataList},null),ye(De,{class:yt,show:o.modal,"onUpdate:show":e=>o.modal=e,title:"添加老师",preset:"dialog",showIcon:!1},{default:()=>[ye(Pt,{areaList:t.areaList,onClose:()=>{o.modal=!1,a()}},null)]}),ye(De,{show:o.qrModal,"onUpdate:show":e=>o.qrModal=e,title:"二维码",preset:"dialog",showIcon:!1},{default:()=>[ye("div",{style:{textAlign:"center"}},[ye(Vn,{text:h(),size:300},null)])]})])}});e("default",s({name:"base-setting",setup(e,{emit:t,attrs:n}){const o=c("person"),a=be();return()=>ye("div",{class:dt.listWrap},[ye(He,{class:dt.customTabs,value:o.value,"onUpdate:value":e=>o.value=e,size:"large",animated:!0,"pane-wrapper-style":"margin: 0 -4px","pane-style":"padding-left: 4px; padding-right: 4px; box-sizing: border-box;"},{default:()=>[ye(Ge,{name:"person",tab:"个人信息"},{default:()=>[ye(ft,null,null)]}),a.info.isSuperAdmin&&ye(Ge,{name:"school",tab:"学校设置"},{default:()=>[ye(Qn,null,null)]})]})])}}))}}}));