ss-component-new 1.1.641 → 1.1.643
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{array-VzXJcPjW.js → array-B8lWuPWk.js} +1 -1
- package/dist/{crypto-CRbcEKIz.cjs → crypto-DNSUM6-T.cjs} +11 -11
- package/dist/{crypto-BRyGpjGR.js → crypto-v3jAna0Y.js} +510 -383
- package/dist/index-B1zrlvmA.cjs +1 -0
- package/dist/{index-CmiV5XIf.cjs → index-B3Uwh6Xf.cjs} +1 -1
- package/dist/{index-C1wsQvWA.js → index-B3z_K4tN.js} +6 -6
- package/dist/{index-BSq1_igb.js → index-B98K3NQ_.js} +5 -5
- package/dist/{index-t5gEjDaU.cjs → index-BGU26U8N.cjs} +1 -1
- package/dist/index-BJOfcIfK.cjs +1 -0
- package/dist/{index-eFEWH0CT.cjs → index-BV7GMSHu.cjs} +1 -1
- package/dist/{index-CgBJhDgc.js → index-BXkdOTkd.js} +6 -6
- package/dist/index-BdSJGJAj.cjs +1 -0
- package/dist/index-BgOWcpJo.cjs +1 -0
- package/dist/index-BgjQ12lw.cjs +1 -0
- package/dist/index-Bjsc84L1.js +1357 -0
- package/dist/index-BtbXPos3.cjs +1 -0
- package/dist/index-C0YmHmRc.js +3295 -0
- package/dist/{index-B9JN6GiA.js → index-C90tv0Xl.js} +9 -10
- package/dist/index-CHDQYj9k.cjs +7 -0
- package/dist/{index-D-u3BBde.cjs → index-CUE8dRo3.cjs} +1 -1
- package/dist/{index-BdC8VdZV.js → index-Ce6cmWoK.js} +1 -1
- package/dist/{index-COe0AKmG.js → index-Cf8HSIB7.js} +9 -9
- package/dist/{index-DivndMew.js → index-CoO_L719.js} +1 -1
- package/dist/{index-Dtsb5A9W.cjs → index-Cq5FEQ8T.cjs} +1 -1
- package/dist/{index-bxA-k3D8.js → index-CstZeLoO.js} +4 -4
- package/dist/{index-BDUZPFuu.js → index-CzRn17aQ.js} +3 -3
- package/dist/{index-h3FJuBkM.js → index-D9rKJ22p.js} +24 -25
- package/dist/{index-BSItzZL7.cjs → index-DDZUeSoG.cjs} +1 -1
- package/dist/{index-BShB-8d9.js → index-DJq9wJbj.js} +6 -6
- package/dist/index-DYLTl0bA.cjs +4207 -0
- package/dist/{index-DIojadyo.js → index-DZOOs3JX.js} +5 -5
- package/dist/{index-DDkuhF7W.js → index-DaCmhrZN.js} +5 -5
- package/dist/{index-CZVc3Or_.cjs → index-DamR6g_M.cjs} +1 -1
- package/dist/{index-Crd7Dg0j.js → index-Dc9ujwGk.js} +1 -1
- package/dist/{index-BgVieMmq.js → index-DkuHB0rR.js} +6 -6
- package/dist/{index-PoFKTn5c.js → index-DnROsSAu.js} +1 -1
- package/dist/{index-DIEuoEuZ.js → index-Dv0m3N6o.js} +13688 -8591
- package/dist/{index-DKUyEy-O.cjs → index-H7RfjeN4.cjs} +1 -1
- package/dist/{index--7CXDWhp.js → index-S9mHFIiJ.js} +5 -6
- package/dist/{index-BMLnk4tK.js → index-TImrSuqA.js} +7 -7
- package/dist/{index-qJTvlSE4.cjs → index-Wq7SUf3w.cjs} +1 -1
- package/dist/{index-B3pzeaEn.cjs → index-XoLdZvmA.cjs} +1 -1
- package/dist/{index-BqT6FOpQ.cjs → index-j-6MQx0k.cjs} +1 -1
- package/dist/{index-CPIuib6Z.js → index-j_-9sdsj.js} +5 -5
- package/dist/{index--YE0I3eJ.cjs → index-yP9dxTXr.cjs} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-BSHKpL3U.cjs → index.vue_vue_type_script_setup_true_lang-DPRs_TEM.cjs} +1 -1
- package/dist/{index.vue_vue_type_script_setup_true_lang-zFnpYkL9.js → index.vue_vue_type_script_setup_true_lang-DmZ8M3M2.js} +2 -2
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-Ds2Sv3Xv.js → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CLRx6Pr7.js} +6287 -6287
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CsM4kD2l.cjs → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-G9Ly6LrV.cjs} +100 -100
- package/dist/{index.vue_vue_type_style_index_0_scoped_248ffa0f_lang-Cj4SDzVh.js → index.vue_vue_type_style_index_0_scoped_248ffa0f_lang-Bx59UssX.js} +9761 -10107
- package/dist/{index.vue_vue_type_style_index_0_scoped_248ffa0f_lang-CBmEjZ1W.cjs → index.vue_vue_type_style_index_0_scoped_248ffa0f_lang-Cx257lrG.cjs} +13 -13
- package/dist/index.vue_vue_type_style_index_0_scoped_c8f6ea20_lang-BxhCfpJ1.cjs +1 -0
- package/dist/{index.vue_vue_type_style_index_0_scoped_c8f6ea20_lang-CZw5zzDj.js → index.vue_vue_type_style_index_0_scoped_c8f6ea20_lang-DnzbmtTR.js} +8 -8
- package/dist/{main-CuzsZxGq.js → main-B3z7cAFc.js} +5 -5
- package/dist/{main-Cm90V52F.cjs → main-Bytk3eJi.cjs} +1 -1
- package/dist/{menu-wif0xsml.js → menu-EkyEcRhA.js} +16 -16
- package/dist/{modelComp-CJ4sMWBs.js → modelComp-DocJQ-pY.js} +1 -1
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +1 -1
- package/dist/ss-component.js +9 -9
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +9 -9
- package/dist/{threeModel-B-xHjjGT.js → threeModel-8fmYfsGI.js} +62 -62
- package/dist/{threeModel-Bf9c_DS5.cjs → threeModel-DUi0i12h.cjs} +1 -1
- package/package.json +1 -1
- package/dist/index-1CHqDeCV.js +0 -1366
- package/dist/index-B4pwTIJ4.cjs +0 -1
- package/dist/index-BHxSsIXo.js +0 -2511
- package/dist/index-BK43_N9M.cjs +0 -1
- package/dist/index-B_G9Phpw.cjs +0 -1
- package/dist/index-BnN2rNsF.cjs +0 -1
- package/dist/index-CDe14QVc.cjs +0 -1
- package/dist/index-CLvHw6UB.cjs +0 -1
- package/dist/index-D8krRZ2d.cjs +0 -4207
- package/dist/index-DgSqC47C.cjs +0 -1
- package/dist/index-DiRkx0Jd.js +0 -4693
- package/dist/index-MSj62TUk.cjs +0 -7
- package/dist/index-xG5ojf2o.cjs +0 -1
- package/dist/index-zwRivr5J.js +0 -791
- package/dist/index.vue_vue_type_style_index_0_scoped_c8f6ea20_lang-CtgbucH4.cjs +0 -1
- package/dist/login-C7jVTvUQ.cjs +0 -1
- package/dist/login-wUTWXQ7u.js +0 -129
- package/dist/obj/model.mtl +0 -42
- package/dist/obj/model.obj +0 -26110
- package/public/obj/model.mtl +0 -42
- package/public/obj/model.obj +0 -26110
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
import { onMounted as f, resolveComponent as h, createElementBlock as C, openBlock as g, createVNode as y } from "vue";
|
|
2
|
-
import "./index-
|
|
3
|
-
import "./menu-
|
|
4
|
-
import "./array-
|
|
2
|
+
import "./index-Dv0m3N6o.js";
|
|
3
|
+
import "./menu-EkyEcRhA.js";
|
|
4
|
+
import "./array-B8lWuPWk.js";
|
|
5
5
|
import { _ as B } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
6
|
-
import "./index.vue_vue_type_style_index_0_scoped_c8f6ea20_lang-
|
|
7
|
-
import "./index.vue_vue_type_style_index_0_scoped_248ffa0f_lang-
|
|
8
|
-
import "./
|
|
6
|
+
import "./index.vue_vue_type_style_index_0_scoped_c8f6ea20_lang-DnzbmtTR.js";
|
|
7
|
+
import "./index.vue_vue_type_style_index_0_scoped_248ffa0f_lang-Bx59UssX.js";
|
|
8
|
+
import "./crypto-v3jAna0Y.js";
|
|
9
9
|
import "./index-BHtNKL1L.js";
|
|
10
|
-
import "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-
|
|
11
|
-
import "./index-DIEuoEuZ.js";
|
|
10
|
+
import "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CLRx6Pr7.js";
|
|
12
11
|
import "vue-router";
|
|
13
12
|
const v = {
|
|
14
13
|
__name: "index",
|
|
@@ -81,7 +80,7 @@ const v = {
|
|
|
81
80
|
]);
|
|
82
81
|
};
|
|
83
82
|
}
|
|
84
|
-
},
|
|
83
|
+
}, F = /* @__PURE__ */ B(v, [["__scopeId", "data-v-6765fe0e"]]);
|
|
85
84
|
export {
|
|
86
|
-
|
|
85
|
+
F as default
|
|
87
86
|
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";const o=require("vue"),i=require("./menu-CcabvNj6.cjs"),G=require("./crypto-DNSUM6-T.cjs"),oo=require("./modelComp-MsmKaqKZ.cjs");function Wt(e){return e}function ro(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var so=800,ao=16,lo=Date.now;function io(e){var t=0,n=0;return function(){var r=lo(),s=ao-(r-n);if(n=r,s>0){if(++t>=so)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function uo(e){return function(){return e}}var co=i.defineProperty?function(e,t){return i.defineProperty(e,"toString",{configurable:!0,enumerable:!1,value:uo(t),writable:!0})}:Wt,jt=io(co),Bt=Math.max;function Yt(e,t,n){return t=Bt(t===void 0?e.length-1:t,0),function(){for(var r=arguments,s=-1,a=Bt(r.length-t,0),l=Array(a);++s<a;)l[s]=r[t+s];s=-1;for(var u=Array(t+1);++s<t;)u[s]=r[s];return u[t]=n(l),ro(e,this,u)}}var At=i.Symbol?i.Symbol.isConcatSpreadable:void 0;function fo(e){return i.isArray(e)||i.isArguments(e)||!!(At&&e&&e[At])}function Xe(e,t,n,r,s){var a=-1,l=e.length;for(n||(n=fo),s||(s=[]);++a<l;){var u=e[a];t>0&&n(u)?t>1?Xe(u,t-1,n,r,s):i.arrayPush(s,u):r||(s[s.length]=u)}return s}function Gt(e){var t=e==null?0:e.length;return t?Xe(e,1):[]}function qt(e){return jt(Yt(e,void 0,Gt),e+"")}function po(e,t){return e!=null&&t in Object(e)}function ho(e,t,n){t=i.castPath(t,e);for(var r=-1,s=t.length,a=!1;++r<s;){var l=i.toKey(t[r]);if(!(a=e!=null&&n(e,l)))break;e=e[l]}return a||++r!=s?a:(s=e==null?0:e.length,!!s&&i.isLength(s)&&i.isIndex(l,s)&&(i.isArray(e)||i.isArguments(e)))}function Xt(e,t){return e!=null&&ho(e,t,po)}function vo(e,t,n){for(var r=-1,s=t.length,a={};++r<s;){var l=t[r],u=i.baseGet(e,l);n(u,l)&&i.baseSet(a,i.castPath(l,e),u)}return a}function go(e,t){return vo(e,t,function(n,r){return Xt(e,r)})}var Jt=qt(function(e,t){return e==null?{}:go(e,t)});const Te="update:modelValue",Ue="change",We="input";function mo(e,t,n,r){const s=n-t;return e/=r/2,e<1?s/2*e*e*e+t:s/2*((e-=2)*e*e+2)+t}const Qt=e=>i.isClient?window.requestAnimationFrame(e):setTimeout(e,16),Zt=e=>i.isClient?window.cancelAnimationFrame(e):clearTimeout(e),yo=(e,t)=>{if(!i.isClient)return!1;const n={undefined:"overflow",true:"overflow-y",false:"overflow-x"}[String(t)],r=i.getStyle(e,n);return["scroll","auto","overlay"].some(s=>r.includes(s))},bo=(e,t)=>{if(!i.isClient)return;let n=e;for(;n;){if([window,document,document.documentElement].includes(n))return window;if(yo(n,t))return n;n=n.parentNode}return n};let be;const en=e=>{var t;if(!i.isClient)return 0;if(be!==void 0)return be;const n=document.createElement("div");n.className=`${e}-scrollbar__wrap`,n.style.visibility="hidden",n.style.width="100px",n.style.position="absolute",n.style.top="-9999px",document.body.appendChild(n);const r=n.offsetWidth;n.style.overflow="scroll";const s=document.createElement("div");s.style.width="100%",n.appendChild(s);const a=s.offsetWidth;return(t=n.parentNode)==null||t.removeChild(n),be=r-a,be};function Eo(e,t){if(!i.isClient)return;if(!t){e.scrollTop=0;return}const n=[];let r=t.offsetParent;for(;r!==null&&e!==r&&e.contains(r);)n.push(r),r=r.offsetParent;const s=t.offsetTop+n.reduce((d,f)=>d+f.offsetTop,0),a=s+t.offsetHeight,l=e.scrollTop,u=l+e.clientHeight;s<l?e.scrollTop=s:a>u&&(e.scrollTop=a-e.clientHeight)}function Co(e,t,n,r,s){const a=Date.now();let l;const u=()=>{const f=Date.now()-a,v=mo(f>r?r:f,t,n,r);i.isWindow(e)?e.scrollTo(window.pageXOffset,v):e.scrollTop=v,f<r?l=Qt(u):i.isFunction$1(s)&&s()};return u(),()=>{l&&Zt(l)}}const So=(e,t)=>i.isWindow(t)?e.ownerDocument.documentElement:t,wo=e=>i.isWindow(e)?window.scrollY:e.scrollTop,tn=()=>i.isClient&&/firefox/i.test(window.navigator.userAgent);let M;const ko={height:"0",visibility:"hidden",overflow:tn()?"":"hidden",position:"absolute","z-index":"-1000",top:"0",right:"0"},To=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing"];function Bo(e){const t=window.getComputedStyle(e),n=t.getPropertyValue("box-sizing"),r=Number.parseFloat(t.getPropertyValue("padding-bottom"))+Number.parseFloat(t.getPropertyValue("padding-top")),s=Number.parseFloat(t.getPropertyValue("border-bottom-width"))+Number.parseFloat(t.getPropertyValue("border-top-width"));return{contextStyle:To.map(l=>[l,t.getPropertyValue(l)]),paddingSize:r,borderSize:s,boxSizing:n}}function Nt(e,t=1,n){var r;M||(M=document.createElement("textarea"),document.body.appendChild(M));const{paddingSize:s,borderSize:a,boxSizing:l,contextStyle:u}=Bo(e);u.forEach(([h,C])=>M==null?void 0:M.style.setProperty(h,C)),Object.entries(ko).forEach(([h,C])=>M==null?void 0:M.style.setProperty(h,C,"important")),M.value=e.value||e.placeholder||"";let d=M.scrollHeight;const f={};l==="border-box"?d=d+a:l==="content-box"&&(d=d-s),M.value="";const v=M.scrollHeight-s;if(i.isNumber(t)){let h=v*t;l==="border-box"&&(h=h+s+a),d=Math.max(h,d),f.minHeight=`${h}px`}if(i.isNumber(n)){let h=v*n;l==="border-box"&&(h=h+s+a),d=Math.min(h,d)}return f.height=`${d}px`,(r=M.parentNode)==null||r.removeChild(M),M=void 0,f}const Ao=i.buildProps({ariaLabel:String,ariaOrientation:{type:String,values:["horizontal","vertical","undefined"]},ariaControls:String}),nn=e=>Jt(Ao,e),on=i.buildProps({id:{type:String,default:void 0},size:i.useSizeProp,disabled:Boolean,modelValue:{type:i.definePropType([String,Number,Object]),default:""},maxlength:{type:[String,Number]},minlength:{type:[String,Number]},type:{type:String,default:"text"},resize:{type:String,values:["none","both","horizontal","vertical"]},autosize:{type:i.definePropType([Boolean,Object]),default:!1},autocomplete:{type:String,default:"off"},formatter:{type:Function},parser:{type:Function},placeholder:{type:String},form:{type:String},readonly:Boolean,clearable:Boolean,showPassword:Boolean,showWordLimit:Boolean,suffixIcon:{type:i.iconPropType},prefixIcon:{type:i.iconPropType},containerRole:{type:String,default:void 0},tabindex:{type:[String,Number],default:0},validateEvent:{type:Boolean,default:!0},inputStyle:{type:i.definePropType([Object,Array,String]),default:()=>i.mutable({})},autofocus:Boolean,rows:{type:Number,default:2},...nn(["ariaLabel"])}),No={[Te]:e=>i.isString(e),input:e=>i.isString(e),change:e=>i.isString(e),focus:e=>e instanceof FocusEvent,blur:e=>e instanceof FocusEvent,clear:()=>!0,mouseleave:e=>e instanceof MouseEvent,mouseenter:e=>e instanceof MouseEvent,keydown:e=>e instanceof Event,compositionstart:e=>e instanceof CompositionEvent,compositionupdate:e=>e instanceof CompositionEvent,compositionend:e=>e instanceof CompositionEvent},Io=["class","style"],Mo=/^on[A-Z]/,rn=(e={})=>{const{excludeListeners:t=!1,excludeKeys:n}=e,r=o.computed(()=>((n==null?void 0:n.value)||[]).concat(Io)),s=o.getCurrentInstance();return s?o.computed(()=>{var a;return i.fromPairs(Object.entries((a=s.proxy)==null?void 0:a.$attrs).filter(([l])=>!r.value.includes(l)&&!(t&&Mo.test(l))))}):(i.debugWarn("use-attrs","getCurrentInstance() returned null. useAttrs() must be called at the top of a setup function"),o.computed(()=>({})))},je={prefix:Math.floor(Math.random()*1e4),current:0},xo=Symbol("elIdInjection"),sn=()=>o.getCurrentInstance()?o.inject(xo,je):je,Be=e=>{const t=sn();!i.isClient&&t===je&&i.debugWarn("IdInjection",`Looks like you are using server rendering, you must provide a id provider to ensure the hydration process to be succeed
|
|
2
|
+
usage: app.provide(ID_INJECTION_KEY, {
|
|
3
|
+
prefix: number,
|
|
4
|
+
current: number,
|
|
5
|
+
})`);const n=i.useGetDerivedNamespace();return i.computedEager(()=>o.unref(e)||`${n.value}-id-${t.prefix}-${t.current++}`)},Me=Symbol("formContextKey"),Je=Symbol("formItemContextKey"),Qe=()=>{const e=o.inject(Me,void 0),t=o.inject(Je,void 0);return{form:e,formItem:t}},an=(e,{formItemContext:t,disableIdGeneration:n,disableIdManagement:r})=>{n||(n=o.ref(!1)),r||(r=o.ref(!1));const s=o.ref();let a;const l=o.computed(()=>{var u;return!!(!(e.label||e.ariaLabel)&&t&&t.inputIds&&((u=t.inputIds)==null?void 0:u.length)<=1)});return o.onMounted(()=>{a=o.watch([o.toRef(e,"id"),n],([u,d])=>{const f=u??(d?void 0:Be().value);f!==s.value&&(t!=null&&t.removeInputId&&(s.value&&t.removeInputId(s.value),!(r!=null&&r.value)&&!d&&f&&t.addInputId(f)),s.value=f)},{immediate:!0})}),o.onUnmounted(()=>{a&&a(),t!=null&&t.removeInputId&&s.value&&t.removeInputId(s.value)}),{isLabeledByFormItem:l,inputId:s}},ln=e=>{const t=o.getCurrentInstance();return o.computed(()=>{var n,r;return(r=(n=t==null?void 0:t.proxy)==null?void 0:n.$props)==null?void 0:r[e]})},Ze=(e,t={})=>{const n=o.ref(void 0),r=t.prop?n:ln("size"),s=t.global?n:i.useGlobalSize(),a=t.form?{size:void 0}:o.inject(Me,void 0),l=t.formItem?{size:void 0}:o.inject(Je,void 0);return o.computed(()=>r.value||o.unref(e)||(l==null?void 0:l.size)||(a==null?void 0:a.size)||s.value||"")},ge=e=>{const t=ln("disabled"),n=o.inject(Me,void 0);return o.computed(()=>t.value||o.unref(e)||(n==null?void 0:n.disabled)||!1)},Po='a[href],button:not([disabled]),button:not([hidden]),:not([tabindex="-1"]),input:not([disabled]),input:not([type="hidden"]),select:not([disabled]),textarea:not([disabled])',Ro=e=>process.env.NODE_ENV==="test"?!0:getComputedStyle(e).position==="fixed"?!1:e.offsetParent!==null,It=e=>Array.from(e.querySelectorAll(Po)).filter(t=>xe(t)&&Ro(t)),xe=e=>{if(e.tabIndex>0||e.tabIndex===0&&e.getAttribute("tabIndex")!==null)return!0;if(e.tabIndex<0||e.hasAttribute("disabled")||e.getAttribute("aria-disabled")==="true")return!1;switch(e.nodeName){case"A":return!!e.href&&e.rel!=="ignore";case"INPUT":return!(e.type==="hidden"||e.type==="file");case"BUTTON":case"SELECT":case"TEXTAREA":return!0;default:return!1}},Vo=function(e,t,...n){let r;t.includes("mouse")||t.includes("click")?r="MouseEvents":t.includes("key")?r="KeyboardEvent":r="HTMLEvents";const s=document.createEvent(r);return s.initEvent(t,...n),e.dispatchEvent(s),e},un=e=>!e.getAttribute("aria-owns"),Fo=(e,t,n)=>{const{parentNode:r}=e;if(!r)return null;const s=r.querySelectorAll(n),a=Array.prototype.indexOf.call(s,e);return s[a+t]||null},Oo=e=>{e&&(e.focus(),!un(e)&&e.click())};function cn(e,{beforeFocus:t,afterFocus:n,beforeBlur:r,afterBlur:s}={}){const a=o.getCurrentInstance(),{emit:l}=a,u=o.shallowRef(),d=ge(),f=o.ref(!1),v=b=>{i.isFunction$1(t)&&t(b)||f.value||(f.value=!0,l("focus",b),n==null||n())},h=b=>{var c;i.isFunction$1(r)&&r(b)||b.relatedTarget&&((c=u.value)!=null&&c.contains(b.relatedTarget))||(f.value=!1,l("blur",b),s==null||s())},C=b=>{var c,y;(c=u.value)!=null&&c.contains(document.activeElement)&&u.value!==document.activeElement||xe(b.target)||d.value||(y=e.value)==null||y.focus()};return o.watch([u,d],([b,c])=>{b&&(c?b.removeAttribute("tabindex"):b.setAttribute("tabindex","-1"))}),i.useEventListener(u,"focus",v,!0),i.useEventListener(u,"blur",h,!0),i.useEventListener(u,"click",C,!0),process.env.NODE_ENV==="test"&&o.onMounted(()=>{const b=i.isElement(e.value)?e.value:document.querySelector("input,textarea");b&&(i.useEventListener(b,"focus",v,!0),i.useEventListener(b,"blur",h,!0))}),{isFocused:f,wrapperRef:u,handleFocus:v,handleBlur:h}}const Lo=e=>/([\uAC00-\uD7AF\u3130-\u318F])+/gi.test(e);function fn({afterComposition:e,emit:t}){const n=o.ref(!1),r=u=>{t==null||t("compositionstart",u),n.value=!0},s=u=>{var d;t==null||t("compositionupdate",u);const f=(d=u.target)==null?void 0:d.value,v=f[f.length-1]||"";n.value=!Lo(v)},a=u=>{t==null||t("compositionend",u),n.value&&(n.value=!1,o.nextTick(()=>e(u)))};return{isComposing:n,handleComposition:u=>{u.type==="compositionend"?a(u):s(u)},handleCompositionStart:r,handleCompositionUpdate:s,handleCompositionEnd:a}}function Do(e){let t;function n(){if(e.value==null)return;const{selectionStart:s,selectionEnd:a,value:l}=e.value;if(s==null||a==null)return;const u=l.slice(0,Math.max(0,s)),d=l.slice(Math.max(0,a));t={selectionStart:s,selectionEnd:a,value:l,beforeTxt:u,afterTxt:d}}function r(){if(e.value==null||t==null)return;const{value:s}=e.value,{beforeTxt:a,afterTxt:l,selectionStart:u}=t;if(a==null||l==null||u==null)return;let d=s.length;if(s.endsWith(l))d=s.length-l.length;else if(s.startsWith(a))d=a.length;else{const f=a[u-1],v=s.indexOf(f,u-1);v!==-1&&(d=v+1)}e.value.setSelectionRange(d,d)}return[n,r]}const dn="ElInput",zo=o.defineComponent({name:dn,inheritAttrs:!1}),$o=o.defineComponent({...zo,props:on,emits:No,setup(e,{expose:t,emit:n}){const r=e,s=o.useAttrs(),a=rn(),l=o.useSlots(),u=o.computed(()=>[r.type==="textarea"?y.b():c.b(),c.m(C.value),c.is("disabled",b.value),c.is("exceed",Gn.value),{[c.b("group")]:l.prepend||l.append,[c.m("prefix")]:l.prefix||r.prefixIcon,[c.m("suffix")]:l.suffix||r.suffixIcon||r.clearable||r.showPassword,[c.bm("suffix","password-clear")]:N.value&&Q.value,[c.b("hidden")]:r.type==="hidden"},s.class]),d=o.computed(()=>[c.e("wrapper"),c.is("focus",V.value)]),{form:f,formItem:v}=Qe(),{inputId:h}=an(r,{formItemContext:v}),C=Ze(),b=ge(),c=i.useNamespace("input"),y=i.useNamespace("textarea"),g=o.shallowRef(),m=o.shallowRef(),E=o.ref(!1),T=o.ref(!1),O=o.ref(),P=o.shallowRef(r.inputStyle),R=o.computed(()=>g.value||m.value),{wrapperRef:I,isFocused:V,handleFocus:D,handleBlur:j}=cn(R,{beforeFocus(){return b.value},afterBlur(){var p;r.validateEvent&&((p=v==null?void 0:v.validate)==null||p.call(v,"blur").catch(S=>i.debugWarn(S)))}}),_=o.computed(()=>{var p;return(p=f==null?void 0:f.statusIcon)!=null?p:!1}),B=o.computed(()=>(v==null?void 0:v.validateState)||""),me=o.computed(()=>B.value&&i.ValidateComponentsMap[B.value]),ye=o.computed(()=>T.value?i.view_default:i.hide_default),Oe=o.computed(()=>[s.style]),w=o.computed(()=>[r.inputStyle,P.value,{resize:r.resize}]),k=o.computed(()=>i.isNil(r.modelValue)?"":String(r.modelValue)),N=o.computed(()=>r.clearable&&!b.value&&!r.readonly&&!!k.value&&(V.value||E.value)),Q=o.computed(()=>r.showPassword&&!b.value&&!!k.value),Z=o.computed(()=>r.showWordLimit&&!!r.maxlength&&(r.type==="text"||r.type==="textarea")&&!b.value&&!r.readonly&&!r.showPassword),Le=o.computed(()=>k.value.length),Gn=o.computed(()=>!!Z.value&&Le.value>Number(r.maxlength)),qn=o.computed(()=>!!l.suffix||!!r.suffixIcon||N.value||r.showPassword||Z.value||!!B.value&&_.value),[vt,gt]=Do(g);i.useResizeObserver(m,p=>{if(Xn(),!Z.value||r.resize!=="both")return;const S=p[0],{width:ee}=S.contentRect;O.value={right:`calc(100% - ${ee+15+6}px)`}});const le=()=>{const{type:p,autosize:S}=r;if(!(!i.isClient||p!=="textarea"||!m.value))if(S){const ee=i.isObject$1(S)?S.minRows:void 0,kt=i.isObject$1(S)?S.maxRows:void 0,Tt=Nt(m.value,ee,kt);P.value={overflowY:"hidden",...Tt},o.nextTick(()=>{m.value.offsetHeight,P.value=Tt})}else P.value={minHeight:Nt(m.value).minHeight}},Xn=(p=>{let S=!1;return()=>{var ee;if(S||!r.autosize)return;((ee=m.value)==null?void 0:ee.offsetParent)===null||(p(),S=!0)}})(le),ie=()=>{const p=R.value,S=r.formatter?r.formatter(k.value):k.value;!p||p.value===S||(p.value=S)},De=async p=>{vt();let{value:S}=p.target;if(r.formatter&&r.parser&&(S=r.parser(S)),!yt.value){if(S===k.value){ie();return}n(Te,S),n(We,S),await o.nextTick(),ie(),gt()}},mt=p=>{let{value:S}=p.target;r.formatter&&r.parser&&(S=r.parser(S)),n(Ue,S)},{isComposing:yt,handleCompositionStart:bt,handleCompositionUpdate:Et,handleCompositionEnd:Ct}=fn({emit:n,afterComposition:De}),Jn=()=>{vt(),T.value=!T.value,setTimeout(gt)},Qn=()=>{var p;return(p=R.value)==null?void 0:p.focus()},Zn=()=>{var p;return(p=R.value)==null?void 0:p.blur()},eo=p=>{E.value=!1,n("mouseleave",p)},to=p=>{E.value=!0,n("mouseenter",p)},St=p=>{n("keydown",p)},no=()=>{var p;(p=R.value)==null||p.select()},wt=()=>{n(Te,""),n(Ue,""),n("clear"),n(We,"")};return o.watch(()=>r.modelValue,()=>{var p;o.nextTick(()=>le()),r.validateEvent&&((p=v==null?void 0:v.validate)==null||p.call(v,"change").catch(S=>i.debugWarn(S)))}),o.watch(k,()=>ie()),o.watch(()=>r.type,async()=>{await o.nextTick(),ie(),le()}),o.onMounted(()=>{!r.formatter&&r.parser&&i.debugWarn(dn,"If you set the parser, you also need to set the formatter."),ie(),o.nextTick(le)}),t({input:g,textarea:m,ref:R,textareaStyle:w,autosize:o.toRef(r,"autosize"),isComposing:yt,focus:Qn,blur:Zn,select:no,clear:wt,resizeTextarea:le}),(p,S)=>(o.openBlock(),o.createElementBlock("div",{class:o.normalizeClass([o.unref(u),{[o.unref(c).bm("group","append")]:p.$slots.append,[o.unref(c).bm("group","prepend")]:p.$slots.prepend}]),style:o.normalizeStyle(o.unref(Oe)),onMouseenter:to,onMouseleave:eo},[o.createCommentVNode(" input "),p.type!=="textarea"?(o.openBlock(),o.createElementBlock(o.Fragment,{key:0},[o.createCommentVNode(" prepend slot "),p.$slots.prepend?(o.openBlock(),o.createElementBlock("div",{key:0,class:o.normalizeClass(o.unref(c).be("group","prepend"))},[o.renderSlot(p.$slots,"prepend")],2)):o.createCommentVNode("v-if",!0),o.createElementVNode("div",{ref_key:"wrapperRef",ref:I,class:o.normalizeClass(o.unref(d))},[o.createCommentVNode(" prefix slot "),p.$slots.prefix||p.prefixIcon?(o.openBlock(),o.createElementBlock("span",{key:0,class:o.normalizeClass(o.unref(c).e("prefix"))},[o.createElementVNode("span",{class:o.normalizeClass(o.unref(c).e("prefix-inner"))},[o.renderSlot(p.$slots,"prefix"),p.prefixIcon?(o.openBlock(),o.createBlock(o.unref(i.ElIcon),{key:0,class:o.normalizeClass(o.unref(c).e("icon"))},{default:o.withCtx(()=>[(o.openBlock(),o.createBlock(o.resolveDynamicComponent(p.prefixIcon)))]),_:1},8,["class"])):o.createCommentVNode("v-if",!0)],2)],2)):o.createCommentVNode("v-if",!0),o.createElementVNode("input",o.mergeProps({id:o.unref(h),ref_key:"input",ref:g,class:o.unref(c).e("inner")},o.unref(a),{minlength:p.minlength,maxlength:p.maxlength,type:p.showPassword?T.value?"text":"password":p.type,disabled:o.unref(b),readonly:p.readonly,autocomplete:p.autocomplete,tabindex:p.tabindex,"aria-label":p.ariaLabel,placeholder:p.placeholder,style:p.inputStyle,form:p.form,autofocus:p.autofocus,role:p.containerRole,onCompositionstart:o.unref(bt),onCompositionupdate:o.unref(Et),onCompositionend:o.unref(Ct),onInput:De,onChange:mt,onKeydown:St}),null,16,["id","minlength","maxlength","type","disabled","readonly","autocomplete","tabindex","aria-label","placeholder","form","autofocus","role","onCompositionstart","onCompositionupdate","onCompositionend"]),o.createCommentVNode(" suffix slot "),o.unref(qn)?(o.openBlock(),o.createElementBlock("span",{key:1,class:o.normalizeClass(o.unref(c).e("suffix"))},[o.createElementVNode("span",{class:o.normalizeClass(o.unref(c).e("suffix-inner"))},[!o.unref(N)||!o.unref(Q)||!o.unref(Z)?(o.openBlock(),o.createElementBlock(o.Fragment,{key:0},[o.renderSlot(p.$slots,"suffix"),p.suffixIcon?(o.openBlock(),o.createBlock(o.unref(i.ElIcon),{key:0,class:o.normalizeClass(o.unref(c).e("icon"))},{default:o.withCtx(()=>[(o.openBlock(),o.createBlock(o.resolveDynamicComponent(p.suffixIcon)))]),_:1},8,["class"])):o.createCommentVNode("v-if",!0)],64)):o.createCommentVNode("v-if",!0),o.unref(N)?(o.openBlock(),o.createBlock(o.unref(i.ElIcon),{key:1,class:o.normalizeClass([o.unref(c).e("icon"),o.unref(c).e("clear")]),onMousedown:o.withModifiers(o.unref(i.NOOP),["prevent"]),onClick:wt},{default:o.withCtx(()=>[o.createVNode(o.unref(i.circle_close_default))]),_:1},8,["class","onMousedown"])):o.createCommentVNode("v-if",!0),o.unref(Q)?(o.openBlock(),o.createBlock(o.unref(i.ElIcon),{key:2,class:o.normalizeClass([o.unref(c).e("icon"),o.unref(c).e("password")]),onClick:Jn},{default:o.withCtx(()=>[(o.openBlock(),o.createBlock(o.resolveDynamicComponent(o.unref(ye))))]),_:1},8,["class"])):o.createCommentVNode("v-if",!0),o.unref(Z)?(o.openBlock(),o.createElementBlock("span",{key:3,class:o.normalizeClass(o.unref(c).e("count"))},[o.createElementVNode("span",{class:o.normalizeClass(o.unref(c).e("count-inner"))},o.toDisplayString(o.unref(Le))+" / "+o.toDisplayString(p.maxlength),3)],2)):o.createCommentVNode("v-if",!0),o.unref(B)&&o.unref(me)&&o.unref(_)?(o.openBlock(),o.createBlock(o.unref(i.ElIcon),{key:4,class:o.normalizeClass([o.unref(c).e("icon"),o.unref(c).e("validateIcon"),o.unref(c).is("loading",o.unref(B)==="validating")])},{default:o.withCtx(()=>[(o.openBlock(),o.createBlock(o.resolveDynamicComponent(o.unref(me))))]),_:1},8,["class"])):o.createCommentVNode("v-if",!0)],2)],2)):o.createCommentVNode("v-if",!0)],2),o.createCommentVNode(" append slot "),p.$slots.append?(o.openBlock(),o.createElementBlock("div",{key:1,class:o.normalizeClass(o.unref(c).be("group","append"))},[o.renderSlot(p.$slots,"append")],2)):o.createCommentVNode("v-if",!0)],64)):(o.openBlock(),o.createElementBlock(o.Fragment,{key:1},[o.createCommentVNode(" textarea "),o.createElementVNode("textarea",o.mergeProps({id:o.unref(h),ref_key:"textarea",ref:m,class:[o.unref(y).e("inner"),o.unref(c).is("focus",o.unref(V))]},o.unref(a),{minlength:p.minlength,maxlength:p.maxlength,tabindex:p.tabindex,disabled:o.unref(b),readonly:p.readonly,autocomplete:p.autocomplete,style:o.unref(w),"aria-label":p.ariaLabel,placeholder:p.placeholder,form:p.form,autofocus:p.autofocus,rows:p.rows,role:p.containerRole,onCompositionstart:o.unref(bt),onCompositionupdate:o.unref(Et),onCompositionend:o.unref(Ct),onInput:De,onFocus:o.unref(D),onBlur:o.unref(j),onChange:mt,onKeydown:St}),null,16,["id","minlength","maxlength","tabindex","disabled","readonly","autocomplete","aria-label","placeholder","form","autofocus","rows","role","onCompositionstart","onCompositionupdate","onCompositionend","onFocus","onBlur"]),o.unref(Z)?(o.openBlock(),o.createElementBlock("span",{key:0,style:o.normalizeStyle(O.value),class:o.normalizeClass(o.unref(c).e("count"))},o.toDisplayString(o.unref(Le))+" / "+o.toDisplayString(p.maxlength),7)):o.createCommentVNode("v-if",!0)],64))],38))}});var _o=i._export_sfc($o,[["__file","input.vue"]]);const pn=i.withInstall(_o),ze="focus-trap.focus-after-trapped",$e="focus-trap.focus-after-released",Ho="focus-trap.focusout-prevented",Mt={cancelable:!0,bubbles:!1},Ko={cancelable:!0,bubbles:!1},xt="focusAfterTrapped",Pt="focusAfterReleased",hn=Symbol("elFocusTrap"),et=o.ref(),Pe=o.ref(0),tt=o.ref(0);let Ee=0;const vn=e=>{const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const s=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||s?NodeFilter.FILTER_SKIP:r.tabIndex>=0||r===document.activeElement?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t},Rt=(e,t)=>{for(const n of e)if(!Uo(n,t))return n},Uo=(e,t)=>{if(process.env.NODE_ENV==="test")return!1;if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1},Wo=e=>{const t=vn(e),n=Rt(t,e),r=Rt(t.reverse(),e);return[n,r]},jo=e=>e instanceof HTMLInputElement&&"select"in e,$=(e,t)=>{if(e&&e.focus){const n=document.activeElement;let r=!1;i.isElement(e)&&!xe(e)&&!e.getAttribute("tabindex")&&(e.setAttribute("tabindex","-1"),r=!0),e.focus({preventScroll:!0}),tt.value=window.performance.now(),e!==n&&jo(e)&&t&&e.select(),i.isElement(e)&&r&&e.removeAttribute("tabindex")}};function Vt(e,t){const n=[...e],r=e.indexOf(t);return r!==-1&&n.splice(r,1),n}const Yo=()=>{let e=[];return{push:r=>{const s=e[0];s&&r!==s&&s.pause(),e=Vt(e,r),e.unshift(r)},remove:r=>{var s,a;e=Vt(e,r),(a=(s=e[0])==null?void 0:s.resume)==null||a.call(s)}}},Go=(e,t=!1)=>{const n=document.activeElement;for(const r of e)if($(r,t),document.activeElement!==n)return},Ft=Yo(),qo=()=>Pe.value>tt.value,Ce=()=>{et.value="pointer",Pe.value=window.performance.now()},Ot=()=>{et.value="keyboard",Pe.value=window.performance.now()},Xo=()=>(o.onMounted(()=>{Ee===0&&(document.addEventListener("mousedown",Ce),document.addEventListener("touchstart",Ce),document.addEventListener("keydown",Ot)),Ee++}),o.onBeforeUnmount(()=>{Ee--,Ee<=0&&(document.removeEventListener("mousedown",Ce),document.removeEventListener("touchstart",Ce),document.removeEventListener("keydown",Ot))}),{focusReason:et,lastUserFocusTimestamp:Pe,lastAutomatedFocusTimestamp:tt}),Se=e=>new CustomEvent(Ho,{...Ko,detail:e});let te=[];const Lt=e=>{e.code===i.EVENT_CODE.esc&&te.forEach(t=>t(e))},Jo=e=>{o.onMounted(()=>{te.length===0&&document.addEventListener("keydown",Lt),i.isClient&&te.push(e)}),o.onBeforeUnmount(()=>{te=te.filter(t=>t!==e),te.length===0&&i.isClient&&document.removeEventListener("keydown",Lt)})},Qo=o.defineComponent({name:"ElFocusTrap",inheritAttrs:!1,props:{loop:Boolean,trapped:Boolean,focusTrapEl:Object,focusStartEl:{type:[Object,String],default:"first"}},emits:[xt,Pt,"focusin","focusout","focusout-prevented","release-requested"],setup(e,{emit:t}){const n=o.ref();let r,s;const{focusReason:a}=Xo();Jo(c=>{e.trapped&&!l.paused&&t("release-requested",c)});const l={paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}},u=c=>{if(!e.loop&&!e.trapped||l.paused)return;const{code:y,altKey:g,ctrlKey:m,metaKey:E,currentTarget:T,shiftKey:O}=c,{loop:P}=e,R=y===i.EVENT_CODE.tab&&!g&&!m&&!E,I=document.activeElement;if(R&&I){const V=T,[D,j]=Wo(V);if(D&&j){if(!O&&I===j){const B=Se({focusReason:a.value});t("focusout-prevented",B),B.defaultPrevented||(c.preventDefault(),P&&$(D,!0))}else if(O&&[D,V].includes(I)){const B=Se({focusReason:a.value});t("focusout-prevented",B),B.defaultPrevented||(c.preventDefault(),P&&$(j,!0))}}else if(I===V){const B=Se({focusReason:a.value});t("focusout-prevented",B),B.defaultPrevented||c.preventDefault()}}};o.provide(hn,{focusTrapRef:n,onKeydown:u}),o.watch(()=>e.focusTrapEl,c=>{c&&(n.value=c)},{immediate:!0}),o.watch([n],([c],[y])=>{c&&(c.addEventListener("keydown",u),c.addEventListener("focusin",v),c.addEventListener("focusout",h)),y&&(y.removeEventListener("keydown",u),y.removeEventListener("focusin",v),y.removeEventListener("focusout",h))});const d=c=>{t(xt,c)},f=c=>t(Pt,c),v=c=>{const y=o.unref(n);if(!y)return;const g=c.target,m=c.relatedTarget,E=g&&y.contains(g);e.trapped||m&&y.contains(m)||(r=m),E&&t("focusin",c),!l.paused&&e.trapped&&(E?s=g:$(s,!0))},h=c=>{const y=o.unref(n);if(!(l.paused||!y))if(e.trapped){const g=c.relatedTarget;!i.isNil(g)&&!y.contains(g)&&setTimeout(()=>{if(!l.paused&&e.trapped){const m=Se({focusReason:a.value});t("focusout-prevented",m),m.defaultPrevented||$(s,!0)}},0)}else{const g=c.target;g&&y.contains(g)||t("focusout",c)}};async function C(){await o.nextTick();const c=o.unref(n);if(c){Ft.push(l);const y=c.contains(document.activeElement)?r:document.activeElement;if(r=y,!c.contains(y)){const m=new Event(ze,Mt);c.addEventListener(ze,d),c.dispatchEvent(m),m.defaultPrevented||o.nextTick(()=>{let E=e.focusStartEl;i.isString(E)||($(E),document.activeElement!==E&&(E="first")),E==="first"&&Go(vn(c),!0),(document.activeElement===y||E==="container")&&$(c)})}}}function b(){const c=o.unref(n);if(c){c.removeEventListener(ze,d);const y=new CustomEvent($e,{...Mt,detail:{focusReason:a.value}});c.addEventListener($e,f),c.dispatchEvent(y),!y.defaultPrevented&&(a.value=="keyboard"||!qo()||c.contains(document.activeElement))&&$(r??document.body),c.removeEventListener($e,f),Ft.remove(l)}}return o.onMounted(()=>{e.trapped&&C(),o.watch(()=>e.trapped,c=>{c?C():b()})}),o.onBeforeUnmount(()=>{e.trapped&&b(),n.value&&(n.value.removeEventListener("keydown",u),n.value.removeEventListener("focusin",v),n.value.removeEventListener("focusout",h),n.value=void 0)}),{onKeydown:u}}});function Zo(e,t,n,r,s,a){return o.renderSlot(e.$slots,"default",{handleKeydown:e.onKeydown})}var gn=i._export_sfc(Qo,[["render",Zo],["__file","focus-trap.vue"]]);const mn=Symbol("buttonGroupContextKey"),yn=({from:e,replacement:t,scope:n,version:r,ref:s,type:a="API"},l)=>{o.watch(()=>o.unref(l),u=>{u&&i.debugWarn(n,`[${a}] ${e} is about to be deprecated in version ${r}, please use ${t} instead.
|
|
6
|
+
For more detail, please visit: ${s}
|
|
7
|
+
`)},{immediate:!0})},er=(e,t)=>{yn({from:"type.text",replacement:"link",version:"3.0.0",scope:"props",ref:"https://element-plus.org/en-US/component/button.html#button-attributes"},o.computed(()=>e.type==="text"));const n=o.inject(mn,void 0),r=i.useGlobalConfig("button"),{form:s}=Qe(),a=Ze(o.computed(()=>n==null?void 0:n.size)),l=ge(),u=o.ref(),d=o.useSlots(),f=o.computed(()=>{var g;return e.type||(n==null?void 0:n.type)||((g=r.value)==null?void 0:g.type)||""}),v=o.computed(()=>{var g,m,E;return(E=(m=e.autoInsertSpace)!=null?m:(g=r.value)==null?void 0:g.autoInsertSpace)!=null?E:!1}),h=o.computed(()=>{var g,m,E;return(E=(m=e.plain)!=null?m:(g=r.value)==null?void 0:g.plain)!=null?E:!1}),C=o.computed(()=>{var g,m,E;return(E=(m=e.round)!=null?m:(g=r.value)==null?void 0:g.round)!=null?E:!1}),b=o.computed(()=>e.tag==="button"?{ariaDisabled:l.value||e.loading,disabled:l.value||e.loading,autofocus:e.autofocus,type:e.nativeType}:{}),c=o.computed(()=>{var g;const m=(g=d.default)==null?void 0:g.call(d);if(v.value&&(m==null?void 0:m.length)===1){const E=m[0];if((E==null?void 0:E.type)===o.Text){const T=E.children;return new RegExp("^\\p{Unified_Ideograph}{2}$","u").test(T.trim())}}return!1});return{_disabled:l,_size:a,_type:f,_ref:u,_props:b,_plain:h,_round:C,shouldAddSpace:c,handleClick:g=>{if(l.value||e.loading){g.stopPropagation();return}e.nativeType==="reset"&&(s==null||s.resetFields()),t("click",g)}}},bn=["default","primary","success","warning","info","danger","text",""],tr=["button","submit","reset"],Ye=i.buildProps({size:i.useSizeProp,disabled:Boolean,type:{type:String,values:bn,default:""},icon:{type:i.iconPropType},nativeType:{type:String,values:tr,default:"button"},loading:Boolean,loadingIcon:{type:i.iconPropType,default:()=>i.loading_default},plain:{type:Boolean,default:void 0},text:Boolean,link:Boolean,bg:Boolean,autofocus:Boolean,round:{type:Boolean,default:void 0},circle:Boolean,color:String,dark:Boolean,autoInsertSpace:{type:Boolean,default:void 0},tag:{type:i.definePropType([String,Object]),default:"button"}}),nr={click:e=>e instanceof MouseEvent};function A(e,t){or(e)&&(e="100%");var n=rr(e);return e=t===360?e:Math.min(t,Math.max(0,parseFloat(e))),n&&(e=parseInt(String(e*t),10)/100),Math.abs(e-t)<1e-6?1:(t===360?e=(e<0?e%t+t:e%t)/parseFloat(String(t)):e=e%t/parseFloat(String(t)),e)}function we(e){return Math.min(1,Math.max(0,e))}function or(e){return typeof e=="string"&&e.indexOf(".")!==-1&&parseFloat(e)===1}function rr(e){return typeof e=="string"&&e.indexOf("%")!==-1}function En(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function ke(e){return e<=1?"".concat(Number(e)*100,"%"):e}function q(e){return e.length===1?"0"+e:String(e)}function sr(e,t,n){return{r:A(e,255)*255,g:A(t,255)*255,b:A(n,255)*255}}function Dt(e,t,n){e=A(e,255),t=A(t,255),n=A(n,255);var r=Math.max(e,t,n),s=Math.min(e,t,n),a=0,l=0,u=(r+s)/2;if(r===s)l=0,a=0;else{var d=r-s;switch(l=u>.5?d/(2-r-s):d/(r+s),r){case e:a=(t-n)/d+(t<n?6:0);break;case t:a=(n-e)/d+2;break;case n:a=(e-t)/d+4;break}a/=6}return{h:a,s:l,l:u}}function _e(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*(6*n):n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function ar(e,t,n){var r,s,a;if(e=A(e,360),t=A(t,100),n=A(n,100),t===0)s=n,a=n,r=n;else{var l=n<.5?n*(1+t):n+t-n*t,u=2*n-l;r=_e(u,l,e+1/3),s=_e(u,l,e),a=_e(u,l,e-1/3)}return{r:r*255,g:s*255,b:a*255}}function zt(e,t,n){e=A(e,255),t=A(t,255),n=A(n,255);var r=Math.max(e,t,n),s=Math.min(e,t,n),a=0,l=r,u=r-s,d=r===0?0:u/r;if(r===s)a=0;else{switch(r){case e:a=(t-n)/u+(t<n?6:0);break;case t:a=(n-e)/u+2;break;case n:a=(e-t)/u+4;break}a/=6}return{h:a,s:d,v:l}}function lr(e,t,n){e=A(e,360)*6,t=A(t,100),n=A(n,100);var r=Math.floor(e),s=e-r,a=n*(1-t),l=n*(1-s*t),u=n*(1-(1-s)*t),d=r%6,f=[n,l,a,a,u,n][d],v=[u,n,n,l,a,a][d],h=[a,a,u,n,n,l][d];return{r:f*255,g:v*255,b:h*255}}function $t(e,t,n,r){var s=[q(Math.round(e).toString(16)),q(Math.round(t).toString(16)),q(Math.round(n).toString(16))];return r&&s[0].startsWith(s[0].charAt(1))&&s[1].startsWith(s[1].charAt(1))&&s[2].startsWith(s[2].charAt(1))?s[0].charAt(0)+s[1].charAt(0)+s[2].charAt(0):s.join("")}function ir(e,t,n,r,s){var a=[q(Math.round(e).toString(16)),q(Math.round(t).toString(16)),q(Math.round(n).toString(16)),q(ur(r))];return s&&a[0].startsWith(a[0].charAt(1))&&a[1].startsWith(a[1].charAt(1))&&a[2].startsWith(a[2].charAt(1))&&a[3].startsWith(a[3].charAt(1))?a[0].charAt(0)+a[1].charAt(0)+a[2].charAt(0)+a[3].charAt(0):a.join("")}function ur(e){return Math.round(parseFloat(e)*255).toString(16)}function _t(e){return x(e)/255}function x(e){return parseInt(e,16)}function cr(e){return{r:e>>16,g:(e&65280)>>8,b:e&255}}var Ge={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};function fr(e){var t={r:0,g:0,b:0},n=1,r=null,s=null,a=null,l=!1,u=!1;return typeof e=="string"&&(e=hr(e)),typeof e=="object"&&(z(e.r)&&z(e.g)&&z(e.b)?(t=sr(e.r,e.g,e.b),l=!0,u=String(e.r).substr(-1)==="%"?"prgb":"rgb"):z(e.h)&&z(e.s)&&z(e.v)?(r=ke(e.s),s=ke(e.v),t=lr(e.h,r,s),l=!0,u="hsv"):z(e.h)&&z(e.s)&&z(e.l)&&(r=ke(e.s),a=ke(e.l),t=ar(e.h,r,a),l=!0,u="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(n=e.a)),n=En(n),{ok:l,format:e.format||u,r:Math.min(255,Math.max(t.r,0)),g:Math.min(255,Math.max(t.g,0)),b:Math.min(255,Math.max(t.b,0)),a:n}}var dr="[-\\+]?\\d+%?",pr="[-\\+]?\\d*\\.\\d+%?",W="(?:".concat(pr,")|(?:").concat(dr,")"),He="[\\s|\\(]+(".concat(W,")[,|\\s]+(").concat(W,")[,|\\s]+(").concat(W,")\\s*\\)?"),Ke="[\\s|\\(]+(".concat(W,")[,|\\s]+(").concat(W,")[,|\\s]+(").concat(W,")[,|\\s]+(").concat(W,")\\s*\\)?"),L={CSS_UNIT:new RegExp(W),rgb:new RegExp("rgb"+He),rgba:new RegExp("rgba"+Ke),hsl:new RegExp("hsl"+He),hsla:new RegExp("hsla"+Ke),hsv:new RegExp("hsv"+He),hsva:new RegExp("hsva"+Ke),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function hr(e){if(e=e.trim().toLowerCase(),e.length===0)return!1;var t=!1;if(Ge[e])e=Ge[e],t=!0;else if(e==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var n=L.rgb.exec(e);return n?{r:n[1],g:n[2],b:n[3]}:(n=L.rgba.exec(e),n?{r:n[1],g:n[2],b:n[3],a:n[4]}:(n=L.hsl.exec(e),n?{h:n[1],s:n[2],l:n[3]}:(n=L.hsla.exec(e),n?{h:n[1],s:n[2],l:n[3],a:n[4]}:(n=L.hsv.exec(e),n?{h:n[1],s:n[2],v:n[3]}:(n=L.hsva.exec(e),n?{h:n[1],s:n[2],v:n[3],a:n[4]}:(n=L.hex8.exec(e),n?{r:x(n[1]),g:x(n[2]),b:x(n[3]),a:_t(n[4]),format:t?"name":"hex8"}:(n=L.hex6.exec(e),n?{r:x(n[1]),g:x(n[2]),b:x(n[3]),format:t?"name":"hex"}:(n=L.hex4.exec(e),n?{r:x(n[1]+n[1]),g:x(n[2]+n[2]),b:x(n[3]+n[3]),a:_t(n[4]+n[4]),format:t?"name":"hex8"}:(n=L.hex3.exec(e),n?{r:x(n[1]+n[1]),g:x(n[2]+n[2]),b:x(n[3]+n[3]),format:t?"name":"hex"}:!1)))))))))}function z(e){return!!L.CSS_UNIT.exec(String(e))}var Cn=function(){function e(t,n){t===void 0&&(t=""),n===void 0&&(n={});var r;if(t instanceof e)return t;typeof t=="number"&&(t=cr(t)),this.originalInput=t;var s=fr(t);this.originalInput=t,this.r=s.r,this.g=s.g,this.b=s.b,this.a=s.a,this.roundA=Math.round(100*this.a)/100,this.format=(r=n.format)!==null&&r!==void 0?r:s.format,this.gradientType=n.gradientType,this.r<1&&(this.r=Math.round(this.r)),this.g<1&&(this.g=Math.round(this.g)),this.b<1&&(this.b=Math.round(this.b)),this.isValid=s.ok}return e.prototype.isDark=function(){return this.getBrightness()<128},e.prototype.isLight=function(){return!this.isDark()},e.prototype.getBrightness=function(){var t=this.toRgb();return(t.r*299+t.g*587+t.b*114)/1e3},e.prototype.getLuminance=function(){var t=this.toRgb(),n,r,s,a=t.r/255,l=t.g/255,u=t.b/255;return a<=.03928?n=a/12.92:n=Math.pow((a+.055)/1.055,2.4),l<=.03928?r=l/12.92:r=Math.pow((l+.055)/1.055,2.4),u<=.03928?s=u/12.92:s=Math.pow((u+.055)/1.055,2.4),.2126*n+.7152*r+.0722*s},e.prototype.getAlpha=function(){return this.a},e.prototype.setAlpha=function(t){return this.a=En(t),this.roundA=Math.round(100*this.a)/100,this},e.prototype.isMonochrome=function(){var t=this.toHsl().s;return t===0},e.prototype.toHsv=function(){var t=zt(this.r,this.g,this.b);return{h:t.h*360,s:t.s,v:t.v,a:this.a}},e.prototype.toHsvString=function(){var t=zt(this.r,this.g,this.b),n=Math.round(t.h*360),r=Math.round(t.s*100),s=Math.round(t.v*100);return this.a===1?"hsv(".concat(n,", ").concat(r,"%, ").concat(s,"%)"):"hsva(".concat(n,", ").concat(r,"%, ").concat(s,"%, ").concat(this.roundA,")")},e.prototype.toHsl=function(){var t=Dt(this.r,this.g,this.b);return{h:t.h*360,s:t.s,l:t.l,a:this.a}},e.prototype.toHslString=function(){var t=Dt(this.r,this.g,this.b),n=Math.round(t.h*360),r=Math.round(t.s*100),s=Math.round(t.l*100);return this.a===1?"hsl(".concat(n,", ").concat(r,"%, ").concat(s,"%)"):"hsla(".concat(n,", ").concat(r,"%, ").concat(s,"%, ").concat(this.roundA,")")},e.prototype.toHex=function(t){return t===void 0&&(t=!1),$t(this.r,this.g,this.b,t)},e.prototype.toHexString=function(t){return t===void 0&&(t=!1),"#"+this.toHex(t)},e.prototype.toHex8=function(t){return t===void 0&&(t=!1),ir(this.r,this.g,this.b,this.a,t)},e.prototype.toHex8String=function(t){return t===void 0&&(t=!1),"#"+this.toHex8(t)},e.prototype.toHexShortString=function(t){return t===void 0&&(t=!1),this.a===1?this.toHexString(t):this.toHex8String(t)},e.prototype.toRgb=function(){return{r:Math.round(this.r),g:Math.round(this.g),b:Math.round(this.b),a:this.a}},e.prototype.toRgbString=function(){var t=Math.round(this.r),n=Math.round(this.g),r=Math.round(this.b);return this.a===1?"rgb(".concat(t,", ").concat(n,", ").concat(r,")"):"rgba(".concat(t,", ").concat(n,", ").concat(r,", ").concat(this.roundA,")")},e.prototype.toPercentageRgb=function(){var t=function(n){return"".concat(Math.round(A(n,255)*100),"%")};return{r:t(this.r),g:t(this.g),b:t(this.b),a:this.a}},e.prototype.toPercentageRgbString=function(){var t=function(n){return Math.round(A(n,255)*100)};return this.a===1?"rgb(".concat(t(this.r),"%, ").concat(t(this.g),"%, ").concat(t(this.b),"%)"):"rgba(".concat(t(this.r),"%, ").concat(t(this.g),"%, ").concat(t(this.b),"%, ").concat(this.roundA,")")},e.prototype.toName=function(){if(this.a===0)return"transparent";if(this.a<1)return!1;for(var t="#"+$t(this.r,this.g,this.b,!1),n=0,r=Object.entries(Ge);n<r.length;n++){var s=r[n],a=s[0],l=s[1];if(t===l)return a}return!1},e.prototype.toString=function(t){var n=!!t;t=t??this.format;var r=!1,s=this.a<1&&this.a>=0,a=!n&&s&&(t.startsWith("hex")||t==="name");return a?t==="name"&&this.a===0?this.toName():this.toRgbString():(t==="rgb"&&(r=this.toRgbString()),t==="prgb"&&(r=this.toPercentageRgbString()),(t==="hex"||t==="hex6")&&(r=this.toHexString()),t==="hex3"&&(r=this.toHexString(!0)),t==="hex4"&&(r=this.toHex8String(!0)),t==="hex8"&&(r=this.toHex8String()),t==="name"&&(r=this.toName()),t==="hsl"&&(r=this.toHslString()),t==="hsv"&&(r=this.toHsvString()),r||this.toHexString())},e.prototype.toNumber=function(){return(Math.round(this.r)<<16)+(Math.round(this.g)<<8)+Math.round(this.b)},e.prototype.clone=function(){return new e(this.toString())},e.prototype.lighten=function(t){t===void 0&&(t=10);var n=this.toHsl();return n.l+=t/100,n.l=we(n.l),new e(n)},e.prototype.brighten=function(t){t===void 0&&(t=10);var n=this.toRgb();return n.r=Math.max(0,Math.min(255,n.r-Math.round(255*-(t/100)))),n.g=Math.max(0,Math.min(255,n.g-Math.round(255*-(t/100)))),n.b=Math.max(0,Math.min(255,n.b-Math.round(255*-(t/100)))),new e(n)},e.prototype.darken=function(t){t===void 0&&(t=10);var n=this.toHsl();return n.l-=t/100,n.l=we(n.l),new e(n)},e.prototype.tint=function(t){return t===void 0&&(t=10),this.mix("white",t)},e.prototype.shade=function(t){return t===void 0&&(t=10),this.mix("black",t)},e.prototype.desaturate=function(t){t===void 0&&(t=10);var n=this.toHsl();return n.s-=t/100,n.s=we(n.s),new e(n)},e.prototype.saturate=function(t){t===void 0&&(t=10);var n=this.toHsl();return n.s+=t/100,n.s=we(n.s),new e(n)},e.prototype.greyscale=function(){return this.desaturate(100)},e.prototype.spin=function(t){var n=this.toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,new e(n)},e.prototype.mix=function(t,n){n===void 0&&(n=50);var r=this.toRgb(),s=new e(t).toRgb(),a=n/100,l={r:(s.r-r.r)*a+r.r,g:(s.g-r.g)*a+r.g,b:(s.b-r.b)*a+r.b,a:(s.a-r.a)*a+r.a};return new e(l)},e.prototype.analogous=function(t,n){t===void 0&&(t=6),n===void 0&&(n=30);var r=this.toHsl(),s=360/n,a=[this];for(r.h=(r.h-(s*t>>1)+720)%360;--t;)r.h=(r.h+s)%360,a.push(new e(r));return a},e.prototype.complement=function(){var t=this.toHsl();return t.h=(t.h+180)%360,new e(t)},e.prototype.monochromatic=function(t){t===void 0&&(t=6);for(var n=this.toHsv(),r=n.h,s=n.s,a=n.v,l=[],u=1/t;t--;)l.push(new e({h:r,s,v:a})),a=(a+u)%1;return l},e.prototype.splitcomplement=function(){var t=this.toHsl(),n=t.h;return[this,new e({h:(n+72)%360,s:t.s,l:t.l}),new e({h:(n+216)%360,s:t.s,l:t.l})]},e.prototype.onBackground=function(t){var n=this.toRgb(),r=new e(t).toRgb(),s=n.a+r.a*(1-n.a);return new e({r:(n.r*n.a+r.r*r.a*(1-n.a))/s,g:(n.g*n.a+r.g*r.a*(1-n.a))/s,b:(n.b*n.a+r.b*r.a*(1-n.a))/s,a:s})},e.prototype.triad=function(){return this.polyad(3)},e.prototype.tetrad=function(){return this.polyad(4)},e.prototype.polyad=function(t){for(var n=this.toHsl(),r=n.h,s=[this],a=360/t,l=1;l<t;l++)s.push(new e({h:(r+l*a)%360,s:n.s,l:n.l}));return s},e.prototype.equals=function(t){return this.toRgbString()===new e(t).toRgbString()},e}();function H(e,t=20){return e.mix("#141414",t).toString()}function vr(e){const t=ge(),n=i.useNamespace("button");return o.computed(()=>{let r={},s=e.color;if(s){const a=s.match(/var\((.*?)\)/);a&&(s=window.getComputedStyle(window.document.documentElement).getPropertyValue(a[1]));const l=new Cn(s),u=e.dark?l.tint(20).toString():H(l,20);if(e.plain)r=n.cssVarBlock({"bg-color":e.dark?H(l,90):l.tint(90).toString(),"text-color":s,"border-color":e.dark?H(l,50):l.tint(50).toString(),"hover-text-color":`var(${n.cssVarName("color-white")})`,"hover-bg-color":s,"hover-border-color":s,"active-bg-color":u,"active-text-color":`var(${n.cssVarName("color-white")})`,"active-border-color":u}),t.value&&(r[n.cssVarBlockName("disabled-bg-color")]=e.dark?H(l,90):l.tint(90).toString(),r[n.cssVarBlockName("disabled-text-color")]=e.dark?H(l,50):l.tint(50).toString(),r[n.cssVarBlockName("disabled-border-color")]=e.dark?H(l,80):l.tint(80).toString());else{const d=e.dark?H(l,30):l.tint(30).toString(),f=l.isDark()?`var(${n.cssVarName("color-white")})`:`var(${n.cssVarName("color-black")})`;if(r=n.cssVarBlock({"bg-color":s,"text-color":f,"border-color":s,"hover-bg-color":d,"hover-text-color":f,"hover-border-color":d,"active-bg-color":u,"active-border-color":u}),t.value){const v=e.dark?H(l,50):l.tint(50).toString();r[n.cssVarBlockName("disabled-bg-color")]=v,r[n.cssVarBlockName("disabled-text-color")]=e.dark?"rgba(255, 255, 255, 0.5)":`var(${n.cssVarName("color-white")})`,r[n.cssVarBlockName("disabled-border-color")]=v}}}return r})}const gr=o.defineComponent({name:"ElButton"}),mr=o.defineComponent({...gr,props:Ye,emits:nr,setup(e,{expose:t,emit:n}){const r=e,s=vr(r),a=i.useNamespace("button"),{_ref:l,_size:u,_type:d,_disabled:f,_props:v,_plain:h,_round:C,shouldAddSpace:b,handleClick:c}=er(r,n),y=o.computed(()=>[a.b(),a.m(d.value),a.m(u.value),a.is("disabled",f.value),a.is("loading",r.loading),a.is("plain",h.value),a.is("round",C.value),a.is("circle",r.circle),a.is("text",r.text),a.is("link",r.link),a.is("has-bg",r.bg)]);return t({ref:l,size:u,type:d,disabled:f,shouldAddSpace:b}),(g,m)=>(o.openBlock(),o.createBlock(o.resolveDynamicComponent(g.tag),o.mergeProps({ref_key:"_ref",ref:l},o.unref(v),{class:o.unref(y),style:o.unref(s),onClick:o.unref(c)}),{default:o.withCtx(()=>[g.loading?(o.openBlock(),o.createElementBlock(o.Fragment,{key:0},[g.$slots.loading?o.renderSlot(g.$slots,"loading",{key:0}):(o.openBlock(),o.createBlock(o.unref(i.ElIcon),{key:1,class:o.normalizeClass(o.unref(a).is("loading"))},{default:o.withCtx(()=>[(o.openBlock(),o.createBlock(o.resolveDynamicComponent(g.loadingIcon)))]),_:1},8,["class"]))],64)):g.icon||g.$slots.icon?(o.openBlock(),o.createBlock(o.unref(i.ElIcon),{key:1},{default:o.withCtx(()=>[g.icon?(o.openBlock(),o.createBlock(o.resolveDynamicComponent(g.icon),{key:0})):o.renderSlot(g.$slots,"icon",{key:1})]),_:3})):o.createCommentVNode("v-if",!0),g.$slots.default?(o.openBlock(),o.createElementBlock("span",{key:2,class:o.normalizeClass({[o.unref(a).em("text","expand")]:o.unref(b)})},[o.renderSlot(g.$slots,"default")],2)):o.createCommentVNode("v-if",!0)]),_:3},16,["class","style","onClick"]))}});var yr=i._export_sfc(mr,[["__file","button.vue"]]);const br={size:Ye.size,type:Ye.type},Er=o.defineComponent({name:"ElButtonGroup"}),Cr=o.defineComponent({...Er,props:br,setup(e){const t=e;o.provide(mn,o.reactive({size:o.toRef(t,"size"),type:o.toRef(t,"type")}));const n=i.useNamespace("button");return(r,s)=>(o.openBlock(),o.createElementBlock("div",{class:o.normalizeClass(o.unref(n).b("group"))},[o.renderSlot(r.$slots,"default")],2))}});var Sn=i._export_sfc(Cr,[["__file","button-group.vue"]]);const wn=i.withInstall(yr,{ButtonGroup:Sn}),Sr=i.withNoopInstall(Sn),wr="utils/vue/vnode";var ce=(e=>(e[e.TEXT=1]="TEXT",e[e.CLASS=2]="CLASS",e[e.STYLE=4]="STYLE",e[e.PROPS=8]="PROPS",e[e.FULL_PROPS=16]="FULL_PROPS",e[e.HYDRATE_EVENTS=32]="HYDRATE_EVENTS",e[e.STABLE_FRAGMENT=64]="STABLE_FRAGMENT",e[e.KEYED_FRAGMENT=128]="KEYED_FRAGMENT",e[e.UNKEYED_FRAGMENT=256]="UNKEYED_FRAGMENT",e[e.NEED_PATCH=512]="NEED_PATCH",e[e.DYNAMIC_SLOTS=1024]="DYNAMIC_SLOTS",e[e.HOISTED=-1]="HOISTED",e[e.BAIL=-2]="BAIL",e))(ce||{});function kn(e){return o.isVNode(e)&&e.type===o.Fragment}function kr(e){return o.isVNode(e)&&e.type===o.Comment}function Tr(e){return o.isVNode(e)&&!kn(e)&&!kr(e)}const Br=e=>{if(!o.isVNode(e))return i.debugWarn(wr,"[getNormalizedProps] must be a VNode"),{};const t=e.props||{},n=(o.isVNode(e.type)?e.type.props:void 0)||{},r={};return Object.keys(n).forEach(s=>{i.hasOwn(n[s],"default")&&(r[s]=n[s].default)}),Object.keys(t).forEach(s=>{r[i.camelize(s)]=t[s]}),r},Ar=e=>{if(!i.isArray$1(e)||e.length>1)throw new Error("expect to receive a single Vue element child");return e[0]},ue=e=>{const t=i.isArray$1(e)?e:[e],n=[];return t.forEach(r=>{var s;i.isArray$1(r)?n.push(...ue(r)):o.isVNode(r)&&((s=r.component)!=null&&s.subTree)?n.push(r,...ue(r.component.subTree)):o.isVNode(r)&&i.isArray$1(r.children)?n.push(...ue(r.children)):o.isVNode(r)&&r.shapeFlag===2?n.push(...ue(r.type())):n.push(r)}),n},nt=e=>{if(!e)return{onClick:i.NOOP,onMousedown:i.NOOP,onMouseup:i.NOOP};let t=!1,n=!1;return{onClick:l=>{t&&n&&e(l),t=n=!1},onMousedown:l=>{t=l.target===l.currentTarget},onMouseup:l=>{n=l.target===l.currentTarget}}},Nr=i.buildProps({mask:{type:Boolean,default:!0},customMaskEvent:Boolean,overlayClass:{type:i.definePropType([String,Array,Object])},zIndex:{type:i.definePropType([String,Number])}}),Ir={click:e=>e instanceof MouseEvent},Mr="overlay";var xr=o.defineComponent({name:"ElOverlay",props:Nr,emits:Ir,setup(e,{slots:t,emit:n}){const r=i.useNamespace(Mr),s=d=>{n("click",d)},{onClick:a,onMousedown:l,onMouseup:u}=nt(e.customMaskEvent?void 0:s);return()=>e.mask?o.createVNode("div",{class:[r.b(),e.overlayClass],style:{zIndex:e.zIndex},onClick:a,onMousedown:l,onMouseup:u},[o.renderSlot(t,"default")],ce.STYLE|ce.CLASS|ce.PROPS,["onClick","onMouseup","onMousedown"]):o.h("div",{class:e.overlayClass,style:{zIndex:e.zIndex,position:"fixed",top:"0px",right:"0px",bottom:"0px",left:"0px"}},[o.renderSlot(t,"default")])}});const Tn=xr,Bn=(e,t,n,r)=>{const s={offsetX:0,offsetY:0},a=(h,C)=>{if(e.value){const{offsetX:b,offsetY:c}=s,y=e.value.getBoundingClientRect(),g=y.left,m=y.top,E=y.width,T=y.height,O=document.documentElement.clientWidth,P=document.documentElement.clientHeight,R=-g+b,I=-m+c,V=O-g-E+b,D=P-m-(T<P?T:0)+c;r!=null&&r.value||(h=Math.min(Math.max(h,R),V),C=Math.min(Math.max(C,I),D)),s.offsetX=h,s.offsetY=C,e.value.style.transform=`translate(${i.addUnit(h)}, ${i.addUnit(C)})`}},l=h=>{const C=h.clientX,b=h.clientY,{offsetX:c,offsetY:y}=s,g=E=>{const T=c+E.clientX-C,O=y+E.clientY-b;a(T,O)},m=()=>{document.removeEventListener("mousemove",g),document.removeEventListener("mouseup",m)};document.addEventListener("mousemove",g),document.addEventListener("mouseup",m)},u=()=>{t.value&&e.value&&(t.value.addEventListener("mousedown",l),window.addEventListener("resize",v))},d=()=>{t.value&&e.value&&(t.value.removeEventListener("mousedown",l),window.removeEventListener("resize",v))},f=()=>{s.offsetX=0,s.offsetY=0,e.value&&(e.value.style.transform="")},v=()=>{const{offsetX:h,offsetY:C}=s;a(h,C)};return o.onMounted(()=>{o.watchEffect(()=>{n.value?u():d()})}),o.onBeforeUnmount(()=>{d()}),{resetPosition:f,updatePosition:v}},An=(e,t={})=>{o.isRef(e)||i.throwError("[useLockscreen]","You need to pass a ref param to this function");const n=t.ns||i.useNamespace("popup"),r=o.computed(()=>n.bm("parent","hidden"));if(!i.isClient||i.hasClass(document.body,r.value))return;let s=0,a=!1,l="0";const u=()=>{setTimeout(()=>{typeof document>"u"||a&&document&&(document.body.style.width=l,i.removeClass(document.body,r.value))},200)};o.watch(e,d=>{if(!d){u();return}a=!i.hasClass(document.body,r.value),a&&(l=document.body.style.width,i.addClass(document.body,r.value)),s=en(n.namespace.value);const f=document.documentElement.clientHeight<document.body.scrollHeight,v=i.getStyle(document.body,"overflowY");s>0&&(f||v==="scroll")&&a&&(document.body.style.width=`calc(100% - ${s}px)`)}),o.onScopeDispose(()=>u())},Nn=e=>["",...i.componentSizes].includes(e),qe="_trap-focus-children",X=[],Ht=e=>{var t;if(X.length===0)return;const n=X[X.length-1][qe];if(n.length>0&&e.code===i.EVENT_CODE.tab){if(n.length===1){e.preventDefault(),document.activeElement!==n[0]&&n[0].focus();return}const r=e.shiftKey,s=e.target===n[0],a=e.target===n[n.length-1];if(s&&r&&(e.preventDefault(),n[n.length-1].focus()),a&&!r&&(e.preventDefault(),n[0].focus()),process.env.NODE_ENV==="test"){const l=n.indexOf(e.target);l!==-1&&((t=n[r?l-1:l+1])==null||t.focus())}}},Pr={beforeMount(e){e[qe]=It(e),X.push(e),X.length<=1&&document.addEventListener("keydown",Ht)},updated(e){o.nextTick(()=>{e[qe]=It(e)})},unmounted(){X.shift(),X.length===0&&document.removeEventListener("keydown",Ht)}},Rr=o.defineComponent({name:"ElMessageBox",directives:{TrapFocus:Pr},components:{ElButton:wn,ElFocusTrap:gn,ElInput:pn,ElOverlay:Tn,ElIcon:i.ElIcon,...i.TypeComponents},inheritAttrs:!1,props:{buttonSize:{type:String,validator:Nn},modal:{type:Boolean,default:!0},lockScroll:{type:Boolean,default:!0},showClose:{type:Boolean,default:!0},closeOnClickModal:{type:Boolean,default:!0},closeOnPressEscape:{type:Boolean,default:!0},closeOnHashChange:{type:Boolean,default:!0},center:Boolean,draggable:Boolean,overflow:Boolean,roundButton:{default:!1,type:Boolean},container:{type:String,default:"body"},boxType:{type:String,default:""}},emits:["vanish","action"],setup(e,{emit:t}){const{locale:n,zIndex:r,ns:s,size:a}=i.useGlobalComponentSettings("message-box",o.computed(()=>e.buttonSize)),{t:l}=n,{nextZIndex:u}=r,d=o.ref(!1),f=o.reactive({autofocus:!0,beforeClose:null,callback:null,cancelButtonText:"",cancelButtonClass:"",confirmButtonText:"",confirmButtonClass:"",customClass:"",customStyle:{},dangerouslyUseHTMLString:!1,distinguishCancelAndClose:!1,icon:"",closeIcon:"",inputPattern:null,inputPlaceholder:"",inputType:"text",inputValue:"",inputValidator:void 0,inputErrorMessage:"",message:"",modalFade:!0,modalClass:"",showCancelButton:!1,showConfirmButton:!0,type:"",title:void 0,showInput:!1,action:"",confirmButtonLoading:!1,cancelButtonLoading:!1,confirmButtonLoadingIcon:o.markRaw(i.loading_default),cancelButtonLoadingIcon:o.markRaw(i.loading_default),confirmButtonDisabled:!1,editorErrorMessage:"",validateError:!1,zIndex:u()}),v=o.computed(()=>{const w=f.type;return{[s.bm("icon",w)]:w&&i.TypeComponentsMap[w]}}),h=Be(),C=Be(),b=o.computed(()=>{const w=f.type;return f.icon||w&&i.TypeComponentsMap[w]||""}),c=o.computed(()=>!!f.message),y=o.ref(),g=o.ref(),m=o.ref(),E=o.ref(),T=o.ref(),O=o.computed(()=>f.confirmButtonClass);o.watch(()=>f.inputValue,async w=>{await o.nextTick(),e.boxType==="prompt"&&w&&B()},{immediate:!0}),o.watch(()=>d.value,w=>{var k,N;w&&(e.boxType!=="prompt"&&(f.autofocus?m.value=(N=(k=T.value)==null?void 0:k.$el)!=null?N:y.value:m.value=y.value),f.zIndex=u()),e.boxType==="prompt"&&(w?o.nextTick().then(()=>{var Q;E.value&&E.value.$el&&(f.autofocus?m.value=(Q=me())!=null?Q:y.value:m.value=y.value)}):(f.editorErrorMessage="",f.validateError=!1))});const P=o.computed(()=>e.draggable),R=o.computed(()=>e.overflow);Bn(y,g,P,R),o.onMounted(async()=>{await o.nextTick(),e.closeOnHashChange&&window.addEventListener("hashchange",I)}),o.onBeforeUnmount(()=>{e.closeOnHashChange&&window.removeEventListener("hashchange",I)});function I(){d.value&&(d.value=!1,o.nextTick(()=>{f.action&&t("action",f.action)}))}const V=()=>{e.closeOnClickModal&&_(f.distinguishCancelAndClose?"close":"cancel")},D=nt(V),j=w=>{if(f.inputType!=="textarea")return w.preventDefault(),_("confirm")},_=w=>{var k;e.boxType==="prompt"&&w==="confirm"&&!B()||(f.action=w,f.beforeClose?(k=f.beforeClose)==null||k.call(f,w,f,I):I())},B=()=>{if(e.boxType==="prompt"){const w=f.inputPattern;if(w&&!w.test(f.inputValue||""))return f.editorErrorMessage=f.inputErrorMessage||l("el.messagebox.error"),f.validateError=!0,!1;const k=f.inputValidator;if(i.isFunction$1(k)){const N=k(f.inputValue);if(N===!1)return f.editorErrorMessage=f.inputErrorMessage||l("el.messagebox.error"),f.validateError=!0,!1;if(i.isString(N))return f.editorErrorMessage=N,f.validateError=!0,!1}}return f.editorErrorMessage="",f.validateError=!1,!0},me=()=>{var w,k;const N=(w=E.value)==null?void 0:w.$refs;return(k=N==null?void 0:N.input)!=null?k:N==null?void 0:N.textarea},ye=()=>{_("close")},Oe=()=>{e.closeOnPressEscape&&ye()};return e.lockScroll&&An(d),{...o.toRefs(f),ns:s,overlayEvent:D,visible:d,hasMessage:c,typeClass:v,contentId:h,inputId:C,btnSize:a,iconComponent:b,confirmButtonClasses:O,rootRef:y,focusStartRef:m,headerRef:g,inputRef:E,confirmRef:T,doClose:I,handleClose:ye,onCloseRequested:Oe,handleWrapperClick:V,handleInputEnter:j,handleAction:_,t:l}}});function Vr(e,t,n,r,s,a){const l=o.resolveComponent("el-icon"),u=o.resolveComponent("el-input"),d=o.resolveComponent("el-button"),f=o.resolveComponent("el-focus-trap"),v=o.resolveComponent("el-overlay");return o.openBlock(),o.createBlock(o.Transition,{name:"fade-in-linear",onAfterLeave:h=>e.$emit("vanish"),persisted:""},{default:o.withCtx(()=>[o.withDirectives(o.createVNode(v,{"z-index":e.zIndex,"overlay-class":[e.ns.is("message-box"),e.modalClass],mask:e.modal},{default:o.withCtx(()=>[o.createElementVNode("div",{role:"dialog","aria-label":e.title,"aria-modal":"true","aria-describedby":e.showInput?void 0:e.contentId,class:o.normalizeClass(`${e.ns.namespace.value}-overlay-message-box`),onClick:e.overlayEvent.onClick,onMousedown:e.overlayEvent.onMousedown,onMouseup:e.overlayEvent.onMouseup},[o.createVNode(f,{loop:"",trapped:e.visible,"focus-trap-el":e.rootRef,"focus-start-el":e.focusStartRef,onReleaseRequested:e.onCloseRequested},{default:o.withCtx(()=>[o.createElementVNode("div",{ref:"rootRef",class:o.normalizeClass([e.ns.b(),e.customClass,e.ns.is("draggable",e.draggable),{[e.ns.m("center")]:e.center}]),style:o.normalizeStyle(e.customStyle),tabindex:"-1",onClick:o.withModifiers(()=>{},["stop"])},[e.title!==null&&e.title!==void 0?(o.openBlock(),o.createElementBlock("div",{key:0,ref:"headerRef",class:o.normalizeClass([e.ns.e("header"),{"show-close":e.showClose}])},[o.createElementVNode("div",{class:o.normalizeClass(e.ns.e("title"))},[e.iconComponent&&e.center?(o.openBlock(),o.createBlock(l,{key:0,class:o.normalizeClass([e.ns.e("status"),e.typeClass])},{default:o.withCtx(()=>[(o.openBlock(),o.createBlock(o.resolveDynamicComponent(e.iconComponent)))]),_:1},8,["class"])):o.createCommentVNode("v-if",!0),o.createElementVNode("span",null,o.toDisplayString(e.title),1)],2),e.showClose?(o.openBlock(),o.createElementBlock("button",{key:0,type:"button",class:o.normalizeClass(e.ns.e("headerbtn")),"aria-label":e.t("el.messagebox.close"),onClick:h=>e.handleAction(e.distinguishCancelAndClose?"close":"cancel"),onKeydown:o.withKeys(o.withModifiers(h=>e.handleAction(e.distinguishCancelAndClose?"close":"cancel"),["prevent"]),["enter"])},[o.createVNode(l,{class:o.normalizeClass(e.ns.e("close"))},{default:o.withCtx(()=>[(o.openBlock(),o.createBlock(o.resolveDynamicComponent(e.closeIcon||"close")))]),_:1},8,["class"])],42,["aria-label","onClick","onKeydown"])):o.createCommentVNode("v-if",!0)],2)):o.createCommentVNode("v-if",!0),o.createElementVNode("div",{id:e.contentId,class:o.normalizeClass(e.ns.e("content"))},[o.createElementVNode("div",{class:o.normalizeClass(e.ns.e("container"))},[e.iconComponent&&!e.center&&e.hasMessage?(o.openBlock(),o.createBlock(l,{key:0,class:o.normalizeClass([e.ns.e("status"),e.typeClass])},{default:o.withCtx(()=>[(o.openBlock(),o.createBlock(o.resolveDynamicComponent(e.iconComponent)))]),_:1},8,["class"])):o.createCommentVNode("v-if",!0),e.hasMessage?(o.openBlock(),o.createElementBlock("div",{key:1,class:o.normalizeClass(e.ns.e("message"))},[o.renderSlot(e.$slots,"default",{},()=>[e.dangerouslyUseHTMLString?(o.openBlock(),o.createBlock(o.resolveDynamicComponent(e.showInput?"label":"p"),{key:1,for:e.showInput?e.inputId:void 0,innerHTML:e.message},null,8,["for","innerHTML"])):(o.openBlock(),o.createBlock(o.resolveDynamicComponent(e.showInput?"label":"p"),{key:0,for:e.showInput?e.inputId:void 0},{default:o.withCtx(()=>[o.createTextVNode(o.toDisplayString(e.dangerouslyUseHTMLString?"":e.message),1)]),_:1},8,["for"]))])],2)):o.createCommentVNode("v-if",!0)],2),o.withDirectives(o.createElementVNode("div",{class:o.normalizeClass(e.ns.e("input"))},[o.createVNode(u,{id:e.inputId,ref:"inputRef",modelValue:e.inputValue,"onUpdate:modelValue":h=>e.inputValue=h,type:e.inputType,placeholder:e.inputPlaceholder,"aria-invalid":e.validateError,class:o.normalizeClass({invalid:e.validateError}),onKeydown:o.withKeys(e.handleInputEnter,["enter"])},null,8,["id","modelValue","onUpdate:modelValue","type","placeholder","aria-invalid","class","onKeydown"]),o.createElementVNode("div",{class:o.normalizeClass(e.ns.e("errormsg")),style:o.normalizeStyle({visibility:e.editorErrorMessage?"visible":"hidden"})},o.toDisplayString(e.editorErrorMessage),7)],2),[[o.vShow,e.showInput]])],10,["id"]),o.createElementVNode("div",{class:o.normalizeClass(e.ns.e("btns"))},[e.showCancelButton?(o.openBlock(),o.createBlock(d,{key:0,loading:e.cancelButtonLoading,"loading-icon":e.cancelButtonLoadingIcon,class:o.normalizeClass([e.cancelButtonClass]),round:e.roundButton,size:e.btnSize,onClick:h=>e.handleAction("cancel"),onKeydown:o.withKeys(o.withModifiers(h=>e.handleAction("cancel"),["prevent"]),["enter"])},{default:o.withCtx(()=>[o.createTextVNode(o.toDisplayString(e.cancelButtonText||e.t("el.messagebox.cancel")),1)]),_:1},8,["loading","loading-icon","class","round","size","onClick","onKeydown"])):o.createCommentVNode("v-if",!0),o.withDirectives(o.createVNode(d,{ref:"confirmRef",type:"primary",loading:e.confirmButtonLoading,"loading-icon":e.confirmButtonLoadingIcon,class:o.normalizeClass([e.confirmButtonClasses]),round:e.roundButton,disabled:e.confirmButtonDisabled,size:e.btnSize,onClick:h=>e.handleAction("confirm"),onKeydown:o.withKeys(o.withModifiers(h=>e.handleAction("confirm"),["prevent"]),["enter"])},{default:o.withCtx(()=>[o.createTextVNode(o.toDisplayString(e.confirmButtonText||e.t("el.messagebox.confirm")),1)]),_:1},8,["loading","loading-icon","class","round","disabled","size","onClick","onKeydown"]),[[o.vShow,e.showConfirmButton]])],2)],14,["onClick"])]),_:3},8,["trapped","focus-trap-el","focus-start-el","onReleaseRequested"])],42,["aria-label","aria-describedby","onClick","onMousedown","onMouseup"])]),_:3},8,["z-index","overlay-class","mask"]),[[o.vShow,e.visible]])]),_:3},8,["onAfterLeave"])}var Fr=i._export_sfc(Rr,[["render",Vr],["__file","index.vue"]]);const pe=new Map,Or=e=>{let t=document.body;return e.appendTo&&(i.isString(e.appendTo)&&(t=document.querySelector(e.appendTo)),i.isElement(e.appendTo)&&(t=e.appendTo),i.isElement(t)||(i.debugWarn("ElMessageBox","the appendTo option is not an HTMLElement. Falling back to document.body."),t=document.body)),t},Lr=(e,t,n=null)=>{const r=o.createVNode(Fr,e,i.isFunction$1(e.message)||o.isVNode(e.message)?{default:i.isFunction$1(e.message)?e.message:()=>e.message}:null);return r.appContext=n,o.render(r,t),Or(e).appendChild(t.firstElementChild),r.component},Dr=()=>document.createElement("div"),zr=(e,t)=>{const n=Dr();e.onVanish=()=>{o.render(null,n),pe.delete(s)},e.onAction=a=>{const l=pe.get(s);let u;e.showInput?u={value:s.inputValue,action:a}:u=a,e.callback?e.callback(u,r.proxy):a==="cancel"||a==="close"?e.distinguishCancelAndClose&&a!=="cancel"?l.reject("close"):l.reject("cancel"):l.resolve(u)};const r=Lr(e,n,t),s=r.proxy;for(const a in e)i.hasOwn(e,a)&&!i.hasOwn(s.$props,a)&&(a==="closeIcon"&&i.isObject$1(e[a])?s[a]=o.markRaw(e[a]):s[a]=e[a]);return s.visible=!0,s};function ae(e,t=null){if(!i.isClient)return Promise.reject();let n;return i.isString(e)||o.isVNode(e)?e={message:e}:n=e.callback,new Promise((r,s)=>{const a=zr(e,t??ae._context);pe.set(a,{options:e,callback:n,resolve:r,reject:s})})}const $r=["alert","confirm","prompt"],_r={alert:{closeOnPressEscape:!1,closeOnClickModal:!1},confirm:{showCancelButton:!0},prompt:{showCancelButton:!0,showInput:!0}};$r.forEach(e=>{ae[e]=Hr(e)});function Hr(e){return(t,n,r,s)=>{let a="";return i.isObject$1(n)?(r=n,a=""):i.isUndefined(n)?a="":a=n,ae(Object.assign({title:a,message:t,type:"",..._r[e]},r,{boxType:e}),s)}}ae.close=()=>{pe.forEach((e,t)=>{t.doClose()}),pe.clear()};ae._context=null;const K=ae;K.install=e=>{K._context=e._context,e.config.globalProperties.$msgbox=K,e.config.globalProperties.$messageBox=K,e.config.globalProperties.$alert=K.alert,e.config.globalProperties.$confirm=K.confirm,e.config.globalProperties.$prompt=K.prompt};const In=K,ot=i.defineStore("authorityState",{state:()=>({routerPageStructures:[]}),actions:{setRouterPageStructure(e){this.routerPageStructures=e}}}),Kr=i.useMenuState(i.pinia),{activeMenuPath:Y}=i.storeToRefs(Kr),Mn=G.useLoginState(i.pinia),{structureData:Ur}=i.storeToRefs(Mn),Wr=ot(i.pinia),{routerPageStructures:jr}=i.storeToRefs(Wr),xn=oo.useModelComp(i.pinia),Yr=o.ref([{label:"角色名称",value:"",name:"roleName"}]),Gr=o.ref([{label:"查询"},{label:"重置"}]),Kt=o.reactive({isFilter:!1,filterForm:{}}),qr=o.ref(!1),Xr=e=>{Kt.isFilter=!0,Kt.filterForm=e},Pn=o.ref([]),Rn=o.ref([]),Vn=o.ref(""),Jr=o.computed(()=>{var t,n,r,s,a;const e=(t=jr.value)==null?void 0:t.find(l=>{var u;return((u=l==null?void 0:l.comp)==null?void 0:u.toUpperCase())==="TABLE"});if(e){Vn.value=e.name,Rn.value=(s=(r=(n=e==null?void 0:e.compData)==null?void 0:n.find(u=>(u==null?void 0:u.key)==="header"))==null?void 0:r.contents)==null?void 0:s.filter(u=>(u==null?void 0:u.label)!=="操作");const l=(a=e==null?void 0:e.compData)==null?void 0:a.map(u=>{if((u==null?void 0:u.key)==="rowButton"){let d=[];return de.value?d=[...u==null?void 0:u.contents,{label:"授权"}]:d=u==null?void 0:u.contents,{...u,contents:d}}return u});return Ln(l),l}return[]}),Qr=e=>{ft(e.singleContent,e.buttonName,Ve.value)},ne=o.ref({}),rt=o.ref(),fe=async(e,t,n)=>{var r,s;try{const a=await e(t);return((r=a==null?void 0:a.data)==null?void 0:r.code)===200?(n!=="查询"&&await Mn.setLogRecordAsync({type:n,data:t},Y.value),a.data.result||((s=a==null?void 0:a.data)==null?void 0:s.code)===200):null}catch(a){i.ElMessage.error(a)}},Zr=(e,t)=>{const n=new Map(t.map(s=>[s.path,s.checkedButtons]));function r(s){var l,u;const a=(l=s==null?void 0:s.path)!=null&&l.startsWith("/")?(u=s==null?void 0:s.path)==null?void 0:u.substring(1):s==null?void 0:s.path;n.has(a)&&(s.checkedButtons=n.get(a)),s.children&&s.children.length>0&&s.children.forEach(r)}e.forEach(r)},Fn=e=>e==null?void 0:e.map(t=>{var r;const n={...t,checkedButtons:[]};return n.children&&((r=n.children)==null?void 0:r.length)>0&&(n.children=Fn(n.children)),n}),st=e=>{for(const t in e)if(Array.isArray(e[t]))return t;return""},On=e=>{const t=[];let n=0;for(;n<e.length;)if(typeof e[n]=="string"){const r={title:e[n]};n+1<e.length&&Array.isArray(e[n+1])?(r.children=On(e[n+1]),n+=2):n+=1,t.push(r)}return t},at=e=>{const t=[];let n=0;for(;n<(e==null?void 0:e.length);){const r={title:e==null?void 0:e[n]};n+1<(e==null?void 0:e.length)&&Array.isArray(e==null?void 0:e[n+1])?(r.children=On(e==null?void 0:e[n+1]),n+=2):n+=1,t.push(r)}return t},Re=(e,t="",n=new Map)=>e==null?void 0:e.map(r=>{const s=t?`${t}/${r.title}`:r.title;if(n.has(s))return n.get(s);const a={...r,path:s};return r.children&&r.children.length>0&&(a.children=Re(r.children,s,n)),n.set(s,a),a}),lt=(e,t)=>e.reduce((n,r)=>{const s=r[t];return n[s]||(n[s]=[]),n[s].push(r),n},{}),it=e=>{const t=[];function n(r,s){!r.children||r.children.length===0?t.push({...r,parentPath:s||""}):r.children.forEach(a=>n(a,r.path||s))}return e.forEach(r=>n(r,"")),t},ut=e=>Object.entries(e).map(([n,r])=>({path:n,checkedButtons:r==null?void 0:r.map(s=>s==null?void 0:s.path)})),es=e=>Object.prototype.toString.call(e)==="[object Object]"&&e!==null,ts=e=>{const t={},n=Array.isArray(e)?e==null?void 0:e.filter(r=>{var s;return!(es(r)&&((s=Object.keys(r))!=null&&s.includes("id")))}):null;return n&&(n==null||n.forEach((r,s)=>{if(s<=0)return;const a=`a${s}`;t[a]=r})),t},oe=o.ref(""),Ln=e=>{var s;const t=e==null?void 0:e.find(a=>(a==null?void 0:a.key)==="tableContents");if(!t)return"";const n=(s=t==null?void 0:t.contents)==null?void 0:s[0],r=ts(n);oe.value=st(r)},ns=e=>{if(!Array.isArray(e))return!1;for(let t of e){if(typeof t!="object"||t===null||typeof t.path!="string"||!Array.isArray(t.checkedButtons))return!1;for(let n of t.checkedButtons)if(typeof n!="string")return!1}return!0},os=e=>{const t=[];for(const n in e)e[n].forEach(s=>{var d,f;const a=(d=s.path)!=null&&d.startsWith("/")?(f=s.path)==null?void 0:f.substring(1):s.path,l=a==null?void 0:a.split("/");let u=t;l.forEach(v=>{let h=u.find(C=>C.title===v);h||(h={title:v,path:s.path,children:[]},u.push(h)),u=h.children})});return t},rs=e=>{const t={};return e.forEach(n=>{const{path:r,checkedButtons:s}=n,a=r,l=s.map(u=>({title:u.split("/").pop()||"",path:u,parentPath:a}));t[a]=l}),t},Dn=e=>{let t=[];for(const n of e){let r=[n.title];if(n.children&&Array.isArray(n.children)){let s=Dn(n.children);s.length>0&&r.push(s)}t.push(r)}return t},ss=e=>{const t=[];for(const n of e){if(!Array.isArray(n)||n.length!==2)continue;const[r,s]=n,a=zn(s),l=t.indexOf(r);l===-1?t.push(r,a):t[l+1]=$n(t[l+1],a)}return t},zn=e=>{const t=[];for(const n of e)if(Array.isArray(n)){if(n.length===1&&typeof n[0]=="string")t.push(n[0]);else if(n.length===2&&typeof n[0]=="string"){const[r,s]=n;t.push(r,zn(s))}}return t},$n=(e,t)=>{const n=[...e];let r=0;for(;r<t.length;){const s=t[r];if(typeof s=="string"){const a=n.indexOf(s);a===-1?n.push(s,t[r+1]):n[a+1]=$n(n[a+1],t[r+1]),r+=2}else n.push(s),r+=1}return n},as=async(e,t)=>{var n,r;if(ne.value=i.cloneDeep(t),xn.setRefreshCurStructure(!1),(n=re.value)==null||n.splice(0),e==="授权"){if(!oe.value){i.ElMessage.error("请正确定义角色权限");return}const s=ns(ne.value[oe.value]);let a;if(s)a=ne.value[oe.value];else{const u=at(ne.value[oe.value]),d=Re(u),f=it(d),v=lt(f,"parentPath");a=ut(v)}if(!a||!Array.isArray(a)){i.ElMessage.error("权限数据处理出错了,请联系管理员");return}J.title=`【${t.a0}】授权`,J.show=!0,await o.nextTick();const l=a==null?void 0:a.map(u=>u==null?void 0:u.path);(r=rt.value)==null||r.setCheckedKeys(l),Zr(he.value,a)}},ls=()=>{J.show=!1},Ae=o.ref(),is=async e=>{const t=await fe(i.getInsofDataApi,{key:{systemKey:sessionStorage.getItem("systemKey"),type:"data",pageKey:e}},"查询"),n=t==null?void 0:t.map(r=>{var s;return{id:r.id,tableData:(s=r==null?void 0:r.value)==null?void 0:s.tableData}});return n==null?void 0:n.map(r=>{var s;if(Array.isArray(r==null?void 0:r.tableData)){let a={id:r.id};return(s=r==null?void 0:r.tableData)==null||s.forEach((l,u)=>{a[`a${u}`]=l}),a}else return{...r.tableData,id:r.id}})},ct=(e,t)=>{let n={};return t==null||t.forEach((r,s)=>{r.label&&e&&(n[r.label]=(e==null?void 0:e[`a${s}`])??null)}),n},ft=(e,t,n)=>{var a,l,u,d;const r=i.cloneDeep(e);r!=null&&r.id&&delete r.id;const s=ct(r,Rn.value);t==="新增"?fe(i.createInsofDataApi,{key:{type:"data",systemKey:sessionStorage.getItem("systemKey"),pageKey:(a=Y.value)!=null&&a.startsWith("/")?(l=Y.value)==null?void 0:l.substring(1):Y.value,tableId:n},value:{tableData:s}},t).then(f=>{Ae.value={...e,newId:f},t&&f&&i.ElMessage.success(t+"成功")}):t==="编辑"?fe(i.updateInsofDataApi,{id:e.id,key:{type:"data",systemKey:sessionStorage.getItem("systemKey"),pageKey:(u=Y.value)!=null&&u.startsWith("/")?(d=Y.value)==null?void 0:d.substring(1):Y.value,tableId:n},value:{tableData:s}},t).then(f=>{t&&f&&i.ElMessage.success(t+"成功"),J.show=!1}):t==="删除"&&fe(i.deleteInsofDataApi,{id:e.id},t).then(f=>{t&&f&&i.ElMessage.success(t+"成功")}),xn.setRefreshCurStructure(!0)},_n=e=>{let t=[];return e==null||e.forEach(n=>{var r;if(n.checkedButtons&&((r=n.checkedButtons)==null?void 0:r.length)>0){const s={path:n.path,checkedButtons:n.checkedButtons};t=t.concat(s)}n.children&&(t=t.concat(_n(n.children)))}),t},us=()=>{const e=_n(he.value),t=rs(e),n=os(t),r=Dn(n),s=ss(r);Ae.value={...ne.value,[oe.value]:s},o.nextTick(()=>{ft(Ae.value,"编辑",Ve.value)})},J=o.reactive({show:!1,title:"角色授权",width:"35%",draggable:!0}),cs=({isPenultimate:e},t)=>{var n,r;return console.log("isPenultimate",e,t),((r=(n=t==null?void 0:t.data)==null?void 0:n.renderButtons)==null?void 0:r.length)>0?"is-penultimate":""},Ve=o.ref(0),Hn=async e=>{var r,s,a,l,u;let t;const n=await i.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),type:"structure",pageKey:e!=null&&e.startsWith("/")?e==null?void 0:e.substring(1):e}});return((r=n==null?void 0:n.data)==null?void 0:r.code)===200&&(s=n==null?void 0:n.data)!=null&&s.result&&((a=n==null?void 0:n.data)==null?void 0:a.result.length)>0&&(t=(u=(l=n==null?void 0:n.data.result)==null?void 0:l[0])==null?void 0:u.id,Ve.value=t),t},he=o.ref([]),fs=o.ref([{path:"资源管理",buttons:["查询","新增","编辑","删除"]},{path:"资源管理/人员",buttons:["查询","新增","编辑","删除"]}]),ds=(e,t)=>{var n;e.checkedButtons=t?(n=e.renderButtons)==null?void 0:n.map(r=>r.path):[]},re=o.ref([]),ps=(e,t)=>{var n,r,s;t.checkedButtons=e,((n=t.checkedButtons)==null?void 0:n.length)===((r=t.renderButtons)==null?void 0:r.length)?re.value.push(t.path):(e==null?void 0:e.length)===0&&(re.value=(s=re.value)==null?void 0:s.filter(a=>a!==t.path))};o.watch(()=>re.value.length,()=>{var e;(e=rt.value)==null||e.setCheckedKeys([...re.value])});o.watch(()=>J.show,e=>{e||(he.value=Fn(he.value))});const Kn=o.computed(()=>{var n;const e=(n=i.cloneDeep(Ur.value))==null?void 0:n.filter(r=>{var s,a;return((a=(s=r==null?void 0:r.key)==null?void 0:s.pageKey)==null?void 0:a.toUpperCase())!=="MENU"});return e==null?void 0:e.map(r=>{var l,u,d,f,v,h,C,b;const s=/button/i;let a=(d=(u=(l=r==null?void 0:r.value)==null?void 0:l.pageData)==null?void 0:u.compData)==null?void 0:d.filter(c=>s.test(c==null?void 0:c.key));return a=Array.from(new Set(a==null?void 0:a.flatMap(c=>c.contents.map(y=>y.label)))),{path:(v=(f=r==null?void 0:r.key)==null?void 0:f.pageKey)!=null&&v.startsWith("/")?(C=(h=r==null?void 0:r.key)==null?void 0:h.pageKey)==null?void 0:C.substring(1):(b=r==null?void 0:r.key)==null?void 0:b.pageKey,buttons:a}})}),hs=o.ref([]),vs=e=>{const n=[e==null?void 0:e.find(r=>(r==null?void 0:r.title)==="平台管理")].flatMap(r=>r==null?void 0:r.children);return n==null?void 0:n.map(r=>{var s,a;return{path:(s=r==null?void 0:r.path)!=null&&s.startsWith("/")?(a=r==null?void 0:r.path)==null?void 0:a.substring(1):r.path,buttons:["新增","查看","编辑","删除"]}})},Ut=(e,t)=>{var n;if(e.carryData){if(e.path==="系统管理/个人中心"){const r=["基本信息","上传头像","签名","修改密码"];return r==null?void 0:r.map(s=>{var a,l;return{title:s,path:(a=e==null?void 0:e.path)!=null&&a.startsWith("/")?((l=e==null?void 0:e.path)==null?void 0:l.substring(1))+"/"+s:e.path+"/"+s}})}return(n=t==null?void 0:t.buttons)==null?void 0:n.map(r=>{var s,a;return{title:r,path:(s=e==null?void 0:e.path)!=null&&s.startsWith("/")?((a=e==null?void 0:e.path)==null?void 0:a.substring(1))+"/"+r:e.path+"/"+r}})}return[]},Un=(e,t)=>{if(Array.isArray(e))return e==null?void 0:e.map(n=>{var a,l;const r=(a=n==null?void 0:n.path)!=null&&a.startsWith("/")?(l=n==null?void 0:n.path)==null?void 0:l.substring(1):n==null?void 0:n.path,s=t==null?void 0:t.find(u=>(u==null?void 0:u.path)===r);return n.children&&n.children.length>0?{...n,renderButtons:Ut(n,s),checkedButtons:[],children:Un(n.children,Kn.value)}:{...n,renderButtons:Ut(n,s),checkedButtons:[]}})},gs={comp:"Group",name:"/系统管理/角色管理",compData:[{key:"groupContents",contents:[{comp:"Table",compData:Pn.value,name:""}]}]},ms=Object.freeze(Object.defineProperty({__proto__:null,addButtonsToTree:Un,addPathToTree:Re,authorizeDialog:J,buttonValue:Gr,changedRow:Ae,clickRow:ne,clickRowButton:as,clickSubmitAuthority:us,closeAuthorizeDialog:ls,compName:Vn,convertArrayToTree:at,convertIndexToLabel:ct,customNodeClass:cs,getActivePageStructureId:Hn,getAuthorityKey:Ln,getFirstArrayProperty:st,getLeafNodesRecursive:it,getPageDataAsync:is,groupByField:lt,handleAddSysMenusButtons:vs,handleItemDataChange:Qr,handleNodeBtnChange:ps,handleNodeCheckChange:ds,handleQueryChange:Xr,handleRowAuthorityRender:ut,handleSubmitAsync:fe,isPageDataExist:qr,menuData:he,menusButtons:fs,pageData:Pn,pageDataFiltered:Jr,queryFormData:Yr,structureButtons:Kn,structureId:Ve,submitTableAsyncByVerify:ft,tempRolePageData:gs,tempSysMenus:hs,treeRef:rt},Symbol.toStringTag,{value:"Module"})),Wn=G.useLoginState(i.pinia),{superAdminInfo:ys,cryptoInfo:F}=i.storeToRefs(Wn),bs=i.useMenuState(i.pinia),{activeMenuPath:U}=i.storeToRefs(bs),ve="123456",Es=ot(i.pinia),{routerPageStructures:Cs}=i.storeToRefs(Es),dt=o.ref(0),Ss=o.ref([{label:"用户名称",value:"",name:"userName"}]),de=o.computed(()=>{const e=sessionStorage.getItem("isSuperAdmin");return e?JSON.parse(e):!1}),ws=e=>{console.log("handleQueryChange",e)},pt=o.ref([]),jn=o.ref(""),Ne=o.computed(()=>{var t,n,r,s,a;const e=(t=Cs.value)==null?void 0:t.find(l=>{var u;return((u=l==null?void 0:l.comp)==null?void 0:u.toUpperCase())==="TABLE"});if(e){jn.value=e.name,pt.value=(s=(r=(n=e==null?void 0:e.compData)==null?void 0:n.find(u=>(u==null?void 0:u.key)==="header"))==null?void 0:r.contents)==null?void 0:s.filter(u=>(u==null?void 0:u.label)!=="操作");const l=(a=e==null?void 0:e.compData)==null?void 0:a.map(u=>{if((u==null?void 0:u.key)==="rowButton"){const d=[...u==null?void 0:u.contents,{label:"重置密码"}];return{...u,contents:d}}return u});return console.log(245,l),l}return[]}),ks=e=>{Fe(e.singleContent,e.buttonName,dt.value)},Ie=o.ref(),Ts=e=>{console.log("onDoubleClick",e)},Bs=(e,t)=>{e==="重置密码"&&In.confirm(`该操作将会重置【${t==null?void 0:t.account}】的密码,确认重置?`,"警告",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{Ie.value={...t,password:ve},Fe(Ie.value,e,dt.value)}).catch(()=>{i.ElMessage.info("取消重置")})},Yn=()=>{ht(U.value).then(e=>{var n;const t=Array.isArray(e)&&(e==null?void 0:e.filter(r=>(r==null?void 0:r.account)!==ys.value.account));Ne.value=(n=Ne.value)==null?void 0:n.map(r=>r.key==="tableContents"?{...r,contents:t==null?void 0:t.map(s=>{var a;return{...s,password:G.decryptData(s==null?void 0:s.password,(a=F==null?void 0:F.value)==null?void 0:a.privateKey)}})}:r)})},se=async(e,t,n)=>{var r,s;try{const a=await e(t);return((r=a==null?void 0:a.data)==null?void 0:r.code)===200?(n!=="查询"&&await Wn.setLogRecordAsync({type:n,data:t},U.value),a.data.result||((s=a==null?void 0:a.data)==null?void 0:s.code)===200):null}catch(a){i.ElMessage.error(a)}},Fe=(e,t,n)=>{var a,l,u,d,f,v;const r=i.cloneDeep(e);r!=null&&r.id&&delete r.id;const s=ct(r,pt.value);G.isEncryptAvailable()&&s&&(!s.password&&de.value?s.password=G.encryptData(ve,(a=F==null?void 0:F.value)==null?void 0:a.publicKey):s.password&&de.value&&(s.password=G.encryptData(s==null?void 0:s.password,(l=F==null?void 0:F.value)==null?void 0:l.publicKey))),t==="新增"?se(i.createInsofDataApi,{key:{type:"data",layer:s==null?void 0:s.layer,systemKey:sessionStorage.getItem("systemKey"),pageKey:(u=U.value)!=null&&u.startsWith("/")?(d=U.value)==null?void 0:d.substring(1):U.value,tableId:n},value:{tableData:s}},t).then(h=>{var C;Ie.value={...e,newId:h,password:de.value?G.decryptData((e==null?void 0:e.password)??ve,(C=F==null?void 0:F.value)==null?void 0:C.privateKey):e==null?void 0:e.password},t&&h&&i.ElMessage.success(t+"成功")}):t==="编辑"||t==="重置密码"?se(i.updateInsofDataApi,{id:e.id,key:{type:"data",layer:s==null?void 0:s.layer,systemKey:sessionStorage.getItem("systemKey"),pageKey:(f=U.value)!=null&&f.startsWith("/")?(v=U.value)==null?void 0:v.substring(1):U.value,tableId:n},value:{tableData:s}},t).then(()=>{t==="重置密码"&&Yn(),t&&i.ElMessage.success(t+"成功"),J.show=!1}):t==="删除"&&se(i.deleteInsofDataApi,{id:e.id},t).then(()=>{t&&i.ElMessage.success(t+"成功")})},ht=async e=>{const t=await se(i.getInsofDataApi,{key:{systemKey:sessionStorage.getItem("systemKey"),type:"data",pageKey:e}},"查询"),n=t==null?void 0:t.map(r=>{var s,a;return{id:r.id,layer:(s=r.key)==null?void 0:s.layer,tableData:(a=r==null?void 0:r.value)==null?void 0:a.tableData}});return n==null?void 0:n.map(r=>{var s;if(!Array.isArray(r==null?void 0:r.tableData))return{...r.tableData,layer:(s=r.key)==null?void 0:s.layer,id:r.id}})},As={comp:"Group",name:"/系统管理/用户管理",compData:[{key:"groupContents",contents:[{comp:"Table",compData:Ne.value,name:""}]}]},Ns=Object.freeze(Object.defineProperty({__proto__:null,changedRow:Ie,clickRowButton:Bs,columns:pt,compName:jn,getPageDataAsync:ht,handleItemDataChange:ks,handleQueryChange:ws,handleSubmitAsync:se,loginUserIsSuper:de,onDoubleClick:Ts,pageData:Ne,queryFormData:Ss,refreshUserTableData:Yn,resetPassword:ve,structureId:dt,submitTableAsyncByVerify:Fe,tempUserPageData:As},Symbol.toStringTag,{value:"Module"}));exports.CHANGE_EVENT=Ue;exports.ElButton=wn;exports.ElButtonGroup=Sr;exports.ElFocusTrap=gn;exports.ElInput=pn;exports.ElMessageBox=In;exports.ElOverlay=Tn;exports.FOCUS_TRAP_INJECTION_KEY=hn;exports.INPUT_EVENT=We;exports.PatchFlags=ce;exports.State=Ns;exports.State$1=ms;exports.TinyColor=Cn;exports.UPDATE_MODEL_EVENT=Te;exports.addPathToTree=Re;exports.animateScrollTo=Co;exports.baseFlatten=Xe;exports.buttonTypes=bn;exports.cAF=Zt;exports.convertArrayToTree=at;exports.ensureOnlyChild=Ar;exports.flatRest=qt;exports.flattedChildren=ue;exports.flatten=Gt;exports.focusNode=Oo;exports.formContextKey=Me;exports.formItemContextKey=Je;exports.getActivePageStructureId=Hn;exports.getFirstArrayProperty=st;exports.getLeafNodesRecursive=it;exports.getNormalizedProps=Br;exports.getPageDataAsync=ht;exports.getScrollBarWidth=en;exports.getScrollContainer=bo;exports.getScrollElement=So;exports.getScrollTop=wo;exports.getSibling=Fo;exports.groupByField=lt;exports.handleRowAuthorityRender=ut;exports.handleSubmitAsync=se;exports.hasIn=Xt;exports.identity=Wt;exports.inputProps=on;exports.isFirefox=tn;exports.isFocusable=xe;exports.isFragment=kn;exports.isLeaf=un;exports.isValidComponentSize=Nn;exports.isValidElementNode=Tr;exports.overRest=Yt;exports.pick=Jt;exports.rAF=Qt;exports.resetPassword=ve;exports.scrollIntoView=Eo;exports.setToString=jt;exports.submitTableAsyncByVerify=Fe;exports.triggerEvent=Vo;exports.tryFocus=$;exports.useAriaProps=nn;exports.useAttrs=rn;exports.useAuthorityState=ot;exports.useComposition=fn;exports.useDeprecated=yn;exports.useDraggable=Bn;exports.useFocusController=cn;exports.useFormDisabled=ge;exports.useFormItem=Qe;exports.useFormItemInputId=an;exports.useFormSize=Ze;exports.useId=Be;exports.useIdInjection=sn;exports.useLockscreen=An;exports.useSameTarget=nt;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index.vue_vue_type_script_setup_true_lang-DPRs_TEM.cjs");exports.default=e._sfc_main;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { ref as $, resolveComponent as F, createBlock as G, openBlock as C, createCommentVNode as ee, defineComponent as mt, onMounted as It, withCtx as R, createVNode as K, createElementVNode as J, createElementBlock as B, Fragment as we, renderList as be, createTextVNode as Et, toDisplayString as ze, watch as st, normalizeStyle as Le, unref as Yt, createSlots as Kt, resolveDynamicComponent as r2, normalizeClass as Cl, nextTick as h0, renderSlot as he, normalizeProps as Ta, guardReactiveProps as Aa, mergeProps as _2, computed as ce, watchEffect as z0, onUnmounted as Wi, h as bo, reactive as Ol, onBeforeUnmount as Pa, toRefs as za } from "vue";
|
|
2
2
|
import { S as xo } from "./index-BHtNKL1L.js";
|
|
3
|
-
import { d as yo,
|
|
3
|
+
import { d as yo, C as So, D as Ea, W as Va, X as Ba, Y as La } from "./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CLRx6Pr7.js";
|
|
4
4
|
import { _ as Ce } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
5
|
-
import { n as Ra, o as Ia, c as ft, b as Gi, p as Ha, E as Ml, u as Na, s as $a,
|
|
6
|
-
import { u as Ua } from "./modelComp-
|
|
7
|
-
import { _ as qa } from "./index.vue_vue_type_script_setup_true_lang-
|
|
5
|
+
import { n as Ra, o as Ia, c as ft, b as Gi, p as Ha, E as Ml, u as Na, s as $a, bT as Wa, c5 as Ga, b2 as Fa, aG as ja } from "./menu-EkyEcRhA.js";
|
|
6
|
+
import { u as Ua } from "./modelComp-DocJQ-pY.js";
|
|
7
|
+
import { _ as qa } from "./index.vue_vue_type_script_setup_true_lang-DmZ8M3M2.js";
|
|
8
8
|
var Ya = "[object Number]";
|
|
9
9
|
function _o(n) {
|
|
10
10
|
return typeof n == "number" || Ra(n) && Ia(n) == Ya;
|
|
@@ -21635,12 +21635,12 @@ export {
|
|
|
21635
21635
|
Mu as c,
|
|
21636
21636
|
Ru as d,
|
|
21637
21637
|
ku as e,
|
|
21638
|
-
|
|
21638
|
+
Ma as f,
|
|
21639
21639
|
hu as g,
|
|
21640
|
-
|
|
21641
|
-
|
|
21642
|
-
|
|
21643
|
-
|
|
21640
|
+
ju as h,
|
|
21641
|
+
Fm as i,
|
|
21642
|
+
Ka as j,
|
|
21643
|
+
vo as k,
|
|
21644
21644
|
rv as l,
|
|
21645
21645
|
hv as m,
|
|
21646
21646
|
fi as s,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ref as Sp, onMounted as Ab, watch as vL, onUnmounted as cL, createElementBlock as Mb, openBlock as Ib, createVNode as pL } from "vue";
|
|
2
2
|
import { _ as Lb } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
3
|
-
import { c as Ki } from "./menu-
|
|
3
|
+
import { c as Ki } from "./menu-EkyEcRhA.js";
|
|
4
4
|
/*! *****************************************************************************
|
|
5
5
|
Copyright (c) Microsoft Corporation.
|
|
6
6
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),g=require("./index-
|
|
1
|
+
"use strict";const e=require("vue"),g=require("./index-DYLTl0bA.cjs"),c=require("./menu-CcabvNj6.cjs"),B=require("./modelComp-MsmKaqKZ.cjs");require("./array-B_wsE8_t.cjs");const y=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),T=require("./index-C31XRLFj.cjs"),F=require("./index-BGU26U8N.cjs"),O=require("./index-CHDQYj9k.cjs"),R={class:"type-select"},b=["onClick"],L={class:"list-icon"},U={__name:"index",setup(V){const u=B.useModelComp(c.pinia),{itemData:r}=c.storeToRefs(u),C=_=>{const d=c.cloneDeep(r.value);d.push({comp:_.comp,name:_.name,compData:[]}),u.setItemData(d)};return(_,d)=>{const i=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",R,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(g.slotContent),(f,v)=>(e.openBlock(),e.createElementBlock("div",{class:"type-list",key:v},[e.createElementVNode("div",{class:"list-content",onClick:k=>C(f)},[e.createElementVNode("div",L,[e.createVNode(i,{name:f.icon},null,8,["name"])]),e.createElementVNode("div",null,e.toDisplayString(f.name),1)],8,b)]))),128))])}}},z=y._export_sfc(U,[["__scopeId","data-v-1f87163f"]]),H={class:"fill-content"},j={class:"operate-content"},A={class:"collapse-title-content"},G={class:"collapse-title-item"},J={key:1},K=["onClick"],P={class:"icon-content"},Q={key:0,class:"edit-content"},W=["onClick"],X={class:"comp-child"},Y={__name:"index",setup(V){const u=B.useModelComp(c.pinia),{itemData:r,originalData:C}=c.storeToRefs(u),_=e.ref([]);e.ref([]);const d=e.ref([]),i=e.ref([]),f=s=>{var n;let a=(n=c.cloneDeep(i.value))==null?void 0:n.map((t,o)=>(s===o&&(t.content=!0),t));i.value=a},v=s=>{var n;let a=(n=c.cloneDeep(i.value))==null?void 0:n.map((t,o)=>(s===o&&(t.content=!1),t));i.value=a,_.value=c.cloneDeep(r.value)},k=(s,a)=>{var h;let n=(h=c.cloneDeep(i.value))==null?void 0:h.map((l,m)=>(s===m&&(l.content=!1),l));i.value=n;const t=c.cloneDeep(r.value),o=t==null?void 0:t.filter((l,m)=>(m===s&&(l.name=a),l));u.setOriginalData(o),u.setItemData(o)};e.watch(()=>r.value,()=>{var s,a,n;!r.value||((s=r.value)==null?void 0:s.length)===0?_.value=[]:_.value=(a=c.cloneDeep(r.value))==null?void 0:a.filter(t=>(t==null?void 0:t.comp)!=="methodButton"),d.value=_.value,i.value=(n=c.cloneDeep(d.value))==null?void 0:n.map((t,o)=>({id:o,content:!1}))},{deep:!0,immediate:!0});const S=s=>g.getComponent(s),M=(s,a,n)=>{var o,h;if(!s)return;let t=c.cloneDeep(r.value);t=(o=t==null?void 0:t.map((l,m)=>(m===n&&(l.compData=s),l)))==null?void 0:o.filter(l=>(l==null?void 0:l.comp)!=="methodButton"),i.value=(h=c.cloneDeep(t))==null?void 0:h.map((l,m)=>({id:m,content:!1})),u.setOriginalData(t),u.setItemData(t)},q=s=>{O.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const a=c.cloneDeep(r.value),n=a==null?void 0:a.filter((t,o)=>o!==s);u.setOriginalData(n),u.setItemData(n),c.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(s,a)=>{const n=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",H,[a[1]||(a[1]=e.createElementVNode("div",{class:"fill-operate"},e.toDisplayString("操作栏"),-1)),e.createElementVNode("div",j,[e.createVNode(T.default,{class:"collapse-content",collapseContents:_.value},{title:e.withCtx(({item:t,index:o})=>{var h,l,m,D,E,N,w,x,$,I;return[e.createElementVNode("div",A,[e.createElementVNode("div",G,[(l=(h=i.value)==null?void 0:h.find(p=>p.id===o))!=null&&l.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:"collapse-title",style:e.normalizeStyle({marginRight:t.name&&t.name!==""?"8px":"0px"})},e.toDisplayString(t.name),5)),(D=(m=i.value)==null?void 0:m.find(p=>p.id===o))!=null&&D.content?(e.openBlock(),e.createElementBlock("div",J,[e.createVNode(F._sfc_main$2,{modelValue:t.name,"onUpdate:modelValue":p=>t.name=p,onClick:a[0]||(a[0]=e.withModifiers(()=>{},["stop"]))},null,8,["modelValue","onUpdate:modelValue"])])):e.createCommentVNode("",!0),(N=(E=i.value)==null?void 0:E.find(p=>p.id===o))!=null&&N.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:2,onClick:e.withModifiers(p=>f(o),["stop"]),class:"icon-content"},[e.createVNode(n,{name:"Edit",style:{width:"16px",height:"16px"}})],8,K))]),e.createElementVNode("div",P,[(x=(w=i.value)==null?void 0:w.find(p=>p.id===o))!=null&&x.content?(e.openBlock(),e.createElementBlock("div",Q,[e.createVNode(n,{name:"Cancel",style:{width:"16px",height:"16px"},class:"icon-content",onClick:e.withModifiers(p=>v(o),["stop"])},null,8,["onClick"]),e.createVNode(n,{name:"Save",onClick:e.withModifiers(p=>k(o,t.name),["stop"]),style:{width:"16px",height:"16px",fill:"var(--ssComponent-primary-color)"},class:"icon-content"},null,8,["onClick"])])):e.createCommentVNode("",!0),(I=($=i.value)==null?void 0:$.find(p=>p.id===o))!=null&&I.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,onClick:e.withModifiers(p=>q(o),["stop"]),class:"icon-content"},[e.createVNode(n,{name:"Delete",style:{width:"16px",height:"16px"}})],8,W))])])]}),content:e.withCtx(({item:t,index:o})=>{var h,l;return[e.createElementVNode("div",X,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(S(t.comp+"Operate")),{itemContents:t==null?void 0:t.compData,originalItemContents:(l=(h=d.value)==null?void 0:h.find((m,D)=>D===o))==null?void 0:l.compData,onChange:m=>M(m,t,o)},null,40,["itemContents","originalItemContents","onChange"]))])]}),_:1},8,["collapseContents"])])])}}},Z=y._export_sfc(Y,[["__scopeId","data-v-27bd1564"]]),ee={key:0,class:"show-content"},te={style:{display:"flex"}},oe={__name:"index",setup(V){const u=B.useModelComp(c.pinia),{itemData:r}=c.storeToRefs(u),C=e.ref([]);e.watch(()=>r.value,()=>{var d;!r.value||((d=r.value)==null?void 0:d.length)===0?C.value=[]:C.value=c.cloneDeep(r.value)},{deep:!0,immediate:!0});const _=d=>g.getComponent(d);return(d,i)=>{var f;return((f=C.value)==null?void 0:f.length)>0?(e.openBlock(),e.createElementBlock("div",ee,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.value,(v,k)=>(e.openBlock(),e.createElementBlock("div",{class:"item-content",key:k},[e.createElementVNode("div",te,e.toDisplayString(v.name),1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_(v.comp)),{itemData:v==null?void 0:v.compData,childItemData:v==null?void 0:v.itemChildData,key:k},null,8,["itemData","childItemData"]))]))),128))])):e.createCommentVNode("",!0)}}},ne=y._export_sfc(oe,[["__scopeId","data-v-bfa22d29"]]);exports.modelFill=Z;exports.modelSelect=z;exports.modelShow=ne;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ref as l, watch as b } from "vue";
|
|
2
|
-
import { g as y, s as m } from "./menu-
|
|
3
|
-
import {
|
|
4
|
-
import { u as
|
|
5
|
-
const
|
|
2
|
+
import { g as y, s as m } from "./menu-EkyEcRhA.js";
|
|
3
|
+
import { ae as d, ac as g } from "./index-C0YmHmRc.js";
|
|
4
|
+
import { u as D } from "./modelComp-DocJQ-pY.js";
|
|
5
|
+
const f = D(), { itemData: h } = m(f), c = l(0), k = l([
|
|
6
6
|
{
|
|
7
7
|
label: "机构名称",
|
|
8
8
|
value: "",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ref as n, watch as b } from "vue";
|
|
2
|
-
import { g as y, s as d } from "./menu-
|
|
3
|
-
import {
|
|
4
|
-
import { u as D } from "./modelComp-
|
|
2
|
+
import { g as y, s as d } from "./menu-EkyEcRhA.js";
|
|
3
|
+
import { ae as g, ac as m } from "./index-C0YmHmRc.js";
|
|
4
|
+
import { u as D } from "./modelComp-DocJQ-pY.js";
|
|
5
5
|
const f = D(), { itemData: i } = d(f), c = n(0), h = n([
|
|
6
6
|
{
|
|
7
7
|
label: "机构名称",
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import { ref as c, reactive as k, computed as K, defineComponent as Z, onMounted as G, resolveDirective as Q, createElementBlock as
|
|
2
|
-
import { s as
|
|
3
|
-
import { u as L } from "./
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { e as ue, j as de } from "./index-COe0AKmG.js";
|
|
1
|
+
import { ref as c, reactive as k, computed as K, defineComponent as Z, onMounted as G, resolveDirective as Q, createElementBlock as U, openBlock as _, createElementVNode as b, withDirectives as X, createVNode as S, unref as D, createBlock as Y } from "vue";
|
|
2
|
+
import { s as E, bR as ee, bS as te, bT as ae, g as P, u as se, p as V, bM as re, E as B } from "./menu-EkyEcRhA.js";
|
|
3
|
+
import { u as L, e as ne, d as oe } from "./crypto-v3jAna0Y.js";
|
|
4
|
+
import { s as le, a as ie } from "./index-j_-9sdsj.js";
|
|
5
|
+
import { e as ue, f as de } from "./index-Cf8HSIB7.js";
|
|
7
6
|
import { _ as pe } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
8
|
-
const $ = L(V), { loginUserInfo: i, cryptoInfo: m } =
|
|
7
|
+
const $ = L(V), { loginUserInfo: i, cryptoInfo: m } = E($), ge = se(V), { activeMenuPath: h } = E(ge), I = c(0);
|
|
9
8
|
var R, N, M, x;
|
|
10
9
|
const ce = c([
|
|
11
10
|
{
|
|
@@ -48,7 +47,7 @@ const ce = c([
|
|
|
48
47
|
type: "buttonUpload",
|
|
49
48
|
disabled: !1
|
|
50
49
|
}
|
|
51
|
-
]), F = c(!1),
|
|
50
|
+
]), F = c(!1), q = K(() => {
|
|
52
51
|
var t;
|
|
53
52
|
const s = sessionStorage.getItem("authority"), e = JSON.parse(s || "");
|
|
54
53
|
return Array.isArray(e) ? (F.value = !(e != null && e.includes(`${h.value}/上传头像`)), (t = T.value) == null ? void 0 : t.map((r) => ({
|
|
@@ -62,13 +61,13 @@ const ce = c([
|
|
|
62
61
|
},
|
|
63
62
|
{
|
|
64
63
|
key: "signTypeList",
|
|
65
|
-
contents:
|
|
64
|
+
contents: q.value
|
|
66
65
|
}
|
|
67
66
|
]), ye = (s) => {
|
|
68
67
|
w.dialogShow = s.label === "电子签名";
|
|
69
|
-
},
|
|
68
|
+
}, O = () => {
|
|
70
69
|
w.dialogShow = !1;
|
|
71
|
-
},
|
|
70
|
+
}, W = async (s) => {
|
|
72
71
|
var t, r, n, o, a, l, d, p, g;
|
|
73
72
|
const e = await P({
|
|
74
73
|
id: s,
|
|
@@ -86,7 +85,7 @@ const ce = c([
|
|
|
86
85
|
};
|
|
87
86
|
$.setLoginUserInfo(f);
|
|
88
87
|
}
|
|
89
|
-
},
|
|
88
|
+
}, j = async (s) => {
|
|
90
89
|
var e, t, r;
|
|
91
90
|
try {
|
|
92
91
|
const n = await re({
|
|
@@ -101,7 +100,7 @@ const ce = c([
|
|
|
101
100
|
tableData: s
|
|
102
101
|
}
|
|
103
102
|
});
|
|
104
|
-
((t = n == null ? void 0 : n.data) == null ? void 0 : t.code) === 200 && (
|
|
103
|
+
((t = n == null ? void 0 : n.data) == null ? void 0 : t.code) === 200 && (O(), B.success("修改成功"), await W((r = i.value) == null ? void 0 : r.id), v.value = !1);
|
|
105
104
|
} catch {
|
|
106
105
|
B.error("修改响应失败"), v.value = !1;
|
|
107
106
|
}
|
|
@@ -113,7 +112,7 @@ const ce = c([
|
|
|
113
112
|
// password: encryptData(loginUserInfo.value?.password, cryptoInfo?.publicKey),
|
|
114
113
|
[s]: e
|
|
115
114
|
};
|
|
116
|
-
v.value = !0, await
|
|
115
|
+
v.value = !0, await j(t);
|
|
117
116
|
}, y = k({
|
|
118
117
|
baseCols: [],
|
|
119
118
|
otherCols: []
|
|
@@ -178,7 +177,7 @@ const ce = c([
|
|
|
178
177
|
...i.value,
|
|
179
178
|
...s,
|
|
180
179
|
status: ((l = i.value) == null ? void 0 : l.status) ?? "启用"
|
|
181
|
-
}), v.value = !0, await
|
|
180
|
+
}), v.value = !0, await j(t);
|
|
182
181
|
}, A = () => {
|
|
183
182
|
const s = {
|
|
184
183
|
base: [
|
|
@@ -271,7 +270,7 @@ const ce = c([
|
|
|
271
270
|
];
|
|
272
271
|
}, Ae = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
273
272
|
__proto__: null,
|
|
274
|
-
beforeSignDestroy:
|
|
273
|
+
beforeSignDestroy: O,
|
|
275
274
|
changeFormTrigger: _e,
|
|
276
275
|
clickFormButton: fe,
|
|
277
276
|
clickSignButton: ye,
|
|
@@ -279,28 +278,28 @@ const ce = c([
|
|
|
279
278
|
getUserTableHeadersAsync: Ce,
|
|
280
279
|
itemData: be,
|
|
281
280
|
loading: v,
|
|
282
|
-
refreshLoginUserInfoAsync:
|
|
281
|
+
refreshLoginUserInfoAsync: W,
|
|
283
282
|
rowContents: ce,
|
|
284
283
|
signPadInfo: w,
|
|
285
|
-
signTypes:
|
|
284
|
+
signTypes: q,
|
|
286
285
|
submitImageAsync: ve,
|
|
287
286
|
tabKey: I,
|
|
288
287
|
tabsContents: z,
|
|
289
288
|
tempSignTypes: T,
|
|
290
289
|
uploadDisabled: F
|
|
291
|
-
}, Symbol.toStringTag, { value: "Module" })), Ie = { class: "personal-wrapper" }, Te = { class: "personal-box left" }, ke = { class: "base-avatar" },
|
|
290
|
+
}, Symbol.toStringTag, { value: "Module" })), Ie = { class: "personal-wrapper" }, Te = { class: "personal-box left" }, ke = { class: "base-avatar" }, Ee = { class: "center-avatar" }, Ue = { class: "base-info" }, Be = { class: "base-signature" }, Re = { class: "personal-box right" }, Ne = /* @__PURE__ */ Z({
|
|
292
291
|
__name: "index",
|
|
293
292
|
setup(s) {
|
|
294
|
-
const e = k({ ...Ae }), t = L(), { loginUserInfo: r } =
|
|
293
|
+
const e = k({ ...Ae }), t = L(), { loginUserInfo: r } = E(t);
|
|
295
294
|
return G(() => {
|
|
296
295
|
var n;
|
|
297
296
|
e.getUserTableHeadersAsync(), e.refreshLoginUserInfoAsync((n = r == null ? void 0 : r.value) == null ? void 0 : n.id), I.value++;
|
|
298
297
|
}), (n, o) => {
|
|
299
298
|
const a = Q("loading");
|
|
300
|
-
return _(),
|
|
299
|
+
return _(), U("div", Ie, [
|
|
301
300
|
b("div", Te, [
|
|
302
301
|
b("div", ke, [
|
|
303
|
-
X((_(),
|
|
302
|
+
X((_(), U("div", Ee, [
|
|
304
303
|
S(le, {
|
|
305
304
|
disabled: e.uploadDisabled,
|
|
306
305
|
userInfo: D(r),
|
|
@@ -310,7 +309,7 @@ const ce = c([
|
|
|
310
309
|
[a, e.loading]
|
|
311
310
|
])
|
|
312
311
|
]),
|
|
313
|
-
b("div",
|
|
312
|
+
b("div", Ue, [
|
|
314
313
|
S(ue, {
|
|
315
314
|
rowContents: e.rowContents,
|
|
316
315
|
isEnableWrap: !1,
|
|
@@ -339,7 +338,7 @@ const ce = c([
|
|
|
339
338
|
]);
|
|
340
339
|
};
|
|
341
340
|
}
|
|
342
|
-
}),
|
|
341
|
+
}), $e = /* @__PURE__ */ pe(Ne, [["__scopeId", "data-v-a55e627c"]]);
|
|
343
342
|
export {
|
|
344
|
-
|
|
343
|
+
$e as default
|
|
345
344
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),I=require("./index.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
"use strict";const e=require("vue"),I=require("./index.vue_vue_type_script_setup_true_lang-DPRs_TEM.cjs"),y=require("./index-BGU26U8N.cjs"),C=require("./menu-CcabvNj6.cjs"),x=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),k=require("./index-BpPyaNFa.cjs"),A={class:"avatar-model-wrap"},N=e.defineComponent({__name:"index",props:{disabled:{type:Boolean,default:!1},avatarUrl:{type:String,default:""},userInfo:{type:Object,default:{}}},emits:["submitImage","deleteImage"],setup(i,{emit:w}){const u=i,c=w,h=e.computed(()=>"http://139.196.154.85:20013"),p=e.ref(""),d=e.ref(""),_=e.ref();e.watch(()=>{var o;return(o=u.userInfo)==null?void 0:o.avatarUrl},o=>{d.value=o},{immediate:!0});const S=async()=>{if(!(u!=null&&u.disabled))try{const o=await y.downloadAvatarApi({url:p.value});if(o.status!==200)throw new Error(`HTTP error! status: ${o.status}`);const f=new Blob([o.data],{type:o.headers["content-type"]});_.value=f}catch(o){throw new Error(o)}},B=async o=>{var f,g,t,n,l;try{const r=await y.uploadAvatarApi(o);((f=r==null?void 0:r.data)==null?void 0:f.code)===200&&(d.value=h.value+"/"+((t=(g=r.data)==null?void 0:g.result)==null?void 0:t.url),p.value=(l=(n=r.data)==null?void 0:n.result)==null?void 0:l.url,c("submitImage",d.value))}catch(r){C.ElMessage.error(r)}},b=async()=>{try{if(!d.value)return}catch(o){C.ElMessage.error(o)}};return(o,f)=>{var g,t,n;return e.openBlock(),e.createElementBlock("div",A,[e.createVNode(I._sfc_main,{avatarUrl:d.value,avatarBlob:_.value,onClickAvatar:S,onSubmitImage:B,onDeleteImage:b},{avatarDefault:e.withCtx(()=>{var l;return[e.createTextVNode(e.toDisplayString(((l=i.userInfo)==null?void 0:l.account)??"未知"),1)]}),_:1},8,["avatarUrl","avatarBlob"]),e.createElementVNode("span",null,e.toDisplayString((g=i.userInfo)!=null&&g.userName?(t=i.userInfo)==null?void 0:t.userName:(n=i.userInfo)==null?void 0:n.account),1)])}}}),V=x._export_sfc(N,[["__scopeId","data-v-bcb7a17f"]]),E=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}}},emits:["clickSignButton","clickSubmitSign","beforeDestroy"],setup(i,{emit:w}){const u=i,c=e.ref({}),h=e.ref([]),p=w,d=t=>{c.value.dialogShow=(t==null?void 0:t.label)==="电子签名",p("clickSignButton",t)},_=()=>{c.value.dialogShow=!1,p("beforeDestroy")},S=e.computed(()=>"http://139.196.154.85:20013"),B=t=>{var a;const n=t.split(","),l=(a=n==null?void 0:n[0])==null?void 0:a.match(/:(.*?);/)[1],r=atob(n[1]);let s=r.length;const v=new Uint8Array(s);for(;s--;)v[s]=r.charCodeAt(s);return new Blob([v],{type:l})},b=async t=>{var n,l,r;try{const s=await y.uploadAvatarApi(t);((n=s==null?void 0:s.data)==null?void 0:n.code)===200&&p("clickSubmitSign",S.value+"/"+((r=(l=s.data)==null?void 0:l.result)==null?void 0:r.url))}catch(s){C.ElMessage.error(s)}},o=e.ref(""),f=t=>{o.value=t,c.value.dialogShow=!1;const n=new FormData,l=B(t);n.append("file",l,"image.png"),b(n)},g=t=>{const n=new FormData;n.append("file",t==null?void 0:t.file),b(n)};return e.watch(()=>u==null?void 0:u.itemData,t=>{var l,r,s,v;o.value="",(l=c.value)!=null&&l.dialogShow&&(c.value.dialogShow=!1);const n=(r=t==null?void 0:t.find(a=>(a==null?void 0:a.key)==="signConfig"))==null?void 0:r.contents;n&&Object.keys(n).forEach(a=>{(n[a]===void 0||n[a]===null||n[a]==="")&&delete n[a]}),c.value=(s=t==null?void 0:t.find(a=>(a==null?void 0:a.key)==="signConfig"))==null?void 0:s.contents,h.value=(v=t==null?void 0:t.find(a=>(a==null?void 0:a.key)==="signTypeList"))==null?void 0:v.contents},{immediate:!0}),(t,n)=>{const l=e.resolveComponent("el-empty"),r=e.resolveComponent("el-image"),s=e.resolveComponent("el-button"),v=e.resolveComponent("el-upload");return e.openBlock(),e.createBlock(y.Signature,{signPadInfo:c.value,onBeforeDestroy:_,onClickSubmitSign:f},{signatureRender:e.withCtx(()=>{var a,m;return[e.createElementVNode("div",{class:"signature-render",style:e.normalizeStyle({width:`${(a=c.value)==null?void 0:a.signPadWidth}%`})},[e.createVNode(r,{src:o.value?o.value:(m=i.userInfo)==null?void 0:m.signature,fit:"contain"},{error:e.withCtx(()=>[e.createVNode(l,{"image-size":60,description:" "},{image:e.withCtx(()=>[e.createVNode(k.SvgIcon,{name:"emptyImg"})]),_:1})]),_:1},8,["src"])],4)]}),signatureTypes:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,a=>{var m;return e.openBlock(),e.createElementBlock("div",{key:a.label,class:"signature-button"},[(m=a.label)!=null&&m.includes("上传")?(e.openBlock(),e.createBlock(v,{key:0,ref_for:!0,ref:"uploadRef","http-request":g,"show-file-list":!1},{trigger:e.withCtx(()=>[e.createVNode(s,{disabled:a.disabled,id:"themeButton"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.label),1)]),icon:e.withCtx(()=>[e.createVNode(k.SvgIcon,{name:a.icon??""},null,8,["name"])]),_:2},1032,["disabled"])]),_:2},1536)):(e.openBlock(),e.createBlock(s,{key:1,id:"themeButton",disabled:a.disabled,onClick:T=>d(a)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.label),1)]),icon:e.withCtx(()=>[e.createVNode(k.SvgIcon,{name:a.icon??""},null,8,["name"])]),_:2},1032,["disabled","onClick"]))])}),128))]),_:1},8,["signPadInfo"])}}}),U=x._export_sfc(E,[["__scopeId","data-v-b9bd887d"]]);exports.ssAvatar=V;exports.ssSignature=U;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { defineComponent as y, ref as C, onMounted as _, createElementBlock as c, openBlock as g, createVNode as v } from "vue";
|
|
2
|
-
import { u as h, p as k, s as x, c as m, g as M } from "./menu-
|
|
3
|
-
import {
|
|
4
|
-
import { a as T, d as S, f as w } from "./index-
|
|
2
|
+
import { u as h, p as k, s as x, c as m, g as M } from "./menu-EkyEcRhA.js";
|
|
3
|
+
import { q as D } from "./index-Dv0m3N6o.js";
|
|
4
|
+
import { a as T, d as S, f as w } from "./index-Dc9ujwGk.js";
|
|
5
5
|
import { _ as B } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
6
|
-
const N = { class: "menu-content" },
|
|
6
|
+
const N = { class: "menu-content" }, q = /* @__PURE__ */ y({
|
|
7
7
|
__name: "index",
|
|
8
|
-
setup(
|
|
8
|
+
setup(E) {
|
|
9
9
|
const p = h(k), { menus: b } = x(p), u = C([]), f = async () => {
|
|
10
10
|
var o, l, t, a;
|
|
11
11
|
const e = await M({
|
|
@@ -91,7 +91,7 @@ const N = { class: "menu-content" }, E = /* @__PURE__ */ y({
|
|
|
91
91
|
}, null, 8, ["itemData"])
|
|
92
92
|
]));
|
|
93
93
|
}
|
|
94
|
-
}), O = /* @__PURE__ */ B(
|
|
94
|
+
}), O = /* @__PURE__ */ B(q, [["__scopeId", "data-v-26f5cadc"]]);
|
|
95
95
|
export {
|
|
96
96
|
O as default
|
|
97
97
|
};
|