@vipl520/dk-ui 1.0.5 → 1.0.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,4 +1,4 @@
1
- import Jr from"axios";import{ElLoading as $d,ElMessage as wt,ElButton as Va,ElMessageBox as Qr,ElNotification as Ra}from"element-plus";import Vd,{ref as z,reactive as Oe,nextTick as vt,defineComponent as Y,resolveComponent as C,openBlock as F,createElementBlock as I,Fragment as Z,createVNode as x,withCtx as S,createTextVNode as Q,createElementVNode as k,toDisplayString as ce,markRaw as Pa,watch as le,onMounted as Ft,normalizeClass as xe,createBlock as U,createCommentVNode as $,unref as H,computed as we,normalizeStyle as ne,renderSlot as ut,resolveDynamicComponent as Hn,useSlots as Rd,useAttrs as Pd,mergeProps as nt,createSlots as Bn,resolveDirective as Tn,renderList as de,withModifiers as On,withDirectives as Me,vShow as ho,vModelText as or,TransitionGroup as jd,h as rr,inject as In,toRefs as Zr,getCurrentInstance as Nd,provide as lr,toRef as Md,withKeys as Ld,normalizeProps as ja,guardReactiveProps as Na,warn as zd}from"vue";import{useEventListener as Ud,useElementSize as Wn,useWindowSize as Hd}from"@vueuse/core";import Ma from"@tinymce/tinymce-vue";import{Icon as Wd,disableCache as Gd,listIcons as Yd}from"@iconify/vue";import*as La from"@element-plus/icons-vue";import{Search as za,CircleClose as Xd}from"@element-plus/icons-vue";import ar from"@vant/icons";import ir from"@form-create/element-ui";import Kd,{DraggableContainer as Jd}from"vue3-draggable-resizable";const Ua=t=>t!==null&&typeof t=="object",Qd=t=>t!=null,Zd=t=>typeof t=="function";function Ha(t,e){const n=e.split(".");let o=t;return n.forEach(r=>{var a;o=Ua(o)&&(a=o[r])!=null?a:""}),o}const qd=/-(\w)/g,ec=t=>t.replace(qd,(e,n)=>n.toUpperCase()),{hasOwnProperty:tc}=Object.prototype;function nc(t,e,n){const o=e[n];Qd(o)&&(!tc.call(t,n)||!Ua(o)?t[n]=o:t[n]=Wa(Object(t[n]),o))}function Wa(t,e){return Object.keys(e).forEach(n=>{nc(t,e,n)}),t}var oc={name:"\u59D3\u540D",tel:"\u7535\u8BDD",save:"\u4FDD\u5B58",clear:"\u6E05\u7A7A",cancel:"\u53D6\u6D88",confirm:"\u786E\u8BA4",delete:"\u5220\u9664",loading:"\u52A0\u8F7D\u4E2D...",noCoupon:"\u6682\u65E0\u4F18\u60E0\u5238",nameEmpty:"\u8BF7\u586B\u5199\u59D3\u540D",addContact:"\u6DFB\u52A0\u8054\u7CFB\u4EBA",telInvalid:"\u8BF7\u586B\u5199\u6B63\u786E\u7684\u7535\u8BDD",vanCalendar:{end:"\u7ED3\u675F",start:"\u5F00\u59CB",title:"\u65E5\u671F\u9009\u62E9",weekdays:["\u65E5","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D"],monthTitle:(t,e)=>`${t}\u5E74${e}\u6708`,rangePrompt:t=>`\u6700\u591A\u9009\u62E9 ${t} \u5929`},vanCascader:{select:"\u8BF7\u9009\u62E9"},vanPagination:{prev:"\u4E0A\u4E00\u9875",next:"\u4E0B\u4E00\u9875"},vanPullRefresh:{pulling:"\u4E0B\u62C9\u5373\u53EF\u5237\u65B0...",loosing:"\u91CA\u653E\u5373\u53EF\u5237\u65B0..."},vanSubmitBar:{label:"\u5408\u8BA1:"},vanCoupon:{unlimited:"\u65E0\u95E8\u69DB",discount:t=>`${t}\u6298`,condition:t=>`\u6EE1${t}\u5143\u53EF\u7528`},vanCouponCell:{title:"\u4F18\u60E0\u5238",count:t=>`${t}\u5F20\u53EF\u7528`},vanCouponList:{exchange:"\u5151\u6362",close:"\u4E0D\u4F7F\u7528",enable:"\u53EF\u7528",disabled:"\u4E0D\u53EF\u7528",placeholder:"\u8F93\u5165\u4F18\u60E0\u7801"},vanAddressEdit:{area:"\u5730\u533A",areaEmpty:"\u8BF7\u9009\u62E9\u5730\u533A",addressEmpty:"\u8BF7\u586B\u5199\u8BE6\u7EC6\u5730\u5740",addressDetail:"\u8BE6\u7EC6\u5730\u5740",defaultAddress:"\u8BBE\u4E3A\u9ED8\u8BA4\u6536\u8D27\u5730\u5740"},vanAddressList:{add:"\u65B0\u589E\u5730\u5740"}};const Ga=z("zh-CN"),Ya=Oe({"zh-CN":oc}),rc={messages(){return Ya[Ga.value]},use(t,e){Ga.value=t,this.add({[t]:e})},add(t={}){Wa(Ya,t)}};var lc=rc;function ac(t){const e=ec(t)+".";return(n,...o)=>{const r=lc.messages(),a=Ha(r,e+n)||Ha(r,n);return Zd(a)?a(...o):a}}function qr(t,e){return e?typeof e=="string"?` ${t}--${e}`:Array.isArray(e)?e.reduce((n,o)=>n+qr(t,o),""):Object.keys(e).reduce((n,o)=>n+(e[o]?qr(t,o):""),""):""}function ic(t){return(e,n)=>(e&&typeof e!="string"&&(n=e,e=""),e=e?`${t}__${e}`:t,`${e}${qr(e,n)}`)}function yt(t){const e=`dk-${t}`;return[e,ic(e),ac(e)]}const Gn={ApiUrl:"https://independence.heiduoke.cn",AccessToken:"3c388087-0f14-4f8d-8463-9fc9932ce2f6",Plaid:16,AddonName:"demo_wx",ProjectType:"addon"};function uc(t){Object.assign(Gn,t)}function go(){return Gn}const sc=Object.prototype.toString,el=(t,e)=>sc.call(t)===`[object ${e}]`,dc=t=>typeof t<"u",tl=t=>!dc(t),Xa=t=>t!==null&&el(t,"Object"),nl=t=>el(t,"Number"),cc=t=>el(t,"String"),ol=t=>t&&Array.isArray(t),vo=new Map,bn={target:null,count:0};function Ka(t){const{url:e,method:n,params:o}=t;let{data:r}=t;return typeof r=="string"&&(r=JSON.parse(r)),[e,n,JSON.stringify(o),JSON.stringify(r)].join("&")}function fc(t){const e=Ka(t);t.cancelToken=t.cancelToken||new Jr.CancelToken(n=>{vo.has(e)||vo.set(e,n)})}function rl(t){const e=Ka(t);vo.has(e)&&(vo.get(e)(e),vo.delete(e))}function Ja(t){t.loading&&bn.count>0&&bn.count--,bn.count===0&&(bn.target.close(),bn.target=null)}function pc(t){if(Jr.isCancel(t))return console.warn("\u8BF7\u6C42\u7684\u91CD\u590D\u8BF7\u6C42\uFF1A"+t.message);let e="";if(t&&t.response)switch(t.response.status){case 302:e="\u63A5\u53E3\u91CD\u5B9A\u5411\u4E86\uFF01";break;case 400:e="\u53C2\u6570\u4E0D\u6B63\u786E\uFF01";break;case 401:e="\u60A8\u672A\u767B\u5F55\uFF0C\u6216\u8005\u767B\u5F55\u5DF2\u7ECF\u8D85\u65F6\uFF0C\u8BF7\u5148\u767B\u5F55\uFF01";break;case 403:e="\u60A8\u6CA1\u6709\u6743\u9650\u64CD\u4F5C\uFF01";break;case 404:e=`\u8BF7\u6C42\u5730\u5740\u51FA\u9519: ${t.response.config.url}`;break;case 408:e="\u8BF7\u6C42\u8D85\u65F6\uFF01";break;case 409:e="\u7CFB\u7EDF\u5DF2\u5B58\u5728\u76F8\u540C\u6570\u636E\uFF01";break;case 500:e="\u670D\u52A1\u5668\u5185\u90E8\u9519\u8BEF\uFF01";break;case 501:e="\u670D\u52A1\u672A\u5B9E\u73B0\uFF01";break;case 502:e="\u7F51\u5173\u9519\u8BEF\uFF01";break;case 503:e="\u670D\u52A1\u4E0D\u53EF\u7528\uFF01";break;case 504:e="\u670D\u52A1\u6682\u65F6\u65E0\u6CD5\u8BBF\u95EE\uFF0C\u8BF7\u7A0D\u540E\u518D\u8BD5\uFF01";break;case 505:e="HTTP\u7248\u672C\u4E0D\u53D7\u652F\u6301\uFF01";break;default:e="\u5F02\u5E38\u95EE\u9898\uFF0C\u8BF7\u8054\u7CFB\u7BA1\u7406\u5458\uFF01";break}t.message.includes("timeout")&&(e="\u7F51\u7EDC\u8BF7\u6C42\u8D85\u65F6\uFF01"),t.message.includes("Network")&&(e=window.navigator.onLine?"\u670D\u52A1\u7AEF\u5F02\u5E38\uFF01":"\u60A8\u65AD\u7F51\u4E86\uFF01"),wt({type:"error",message:e})}const ot=(t,e,n)=>{const o=Jr.create({...t,baseURL:go().ApiUrl}),r=Object.assign({repeat_request_cancel:!0,loading:!1,reduct_data_format:!0,error_message_show:!0,code_success_show:!1,code_error_show:!1},e);return o.interceptors.request.use(a=>(rl(a),r.repeat_request_cancel&&fc(a),r.loading&&(bn.count++,bn.count===1&&(bn.target=$d.service(n))),a.headers["Access-Token"]=go().AccessToken,a.headers["Project-Type"]=go().ProjectType,a.headers.addon=go().AddonName,a.headers.Plaid=go().Plaid,a.params=a.params||{},a.params._ajax=1,a),a=>(console.log("error",a),Promise.reject(a))),o.interceptors.response.use(a=>{rl(a.config),r.loading&&Ja(r);const l=a.data,i=l.code;if(i===0)return r.code_success_show&&wt.success(l.msg),l;switch(r.code_error_show&&wt.error(l.msg),i){case-1:return Promise.reject(l);case 401:break;default:return Promise.reject(a.data||{msg:"\u672A\u77E5\u9519\u8BEF"})}return l},a=>(console.log("error",a),a.config&&rl(a.config),r.error_message_show&&pc(a),r.loading&&Ja(r),Promise.reject(a))),o.request(t)},ll=t=>{const e={file:0,image:1,audio:2,video:3};return typeof t=="number"||/^\d+$/.test(t)?parseInt(t,10):e[t]},mc=t=>{const e={0:"\u6587\u4EF6\u9009\u62E9",1:"\u9009\u62E9\u56FE\u7247",2:"\u9009\u62E9\u97F3\u9891",3:"\u9009\u62E9\u89C6\u9891"},n=ll(t);return e[n]||"\u6587\u4EF6\u9009\u62E9"};function ke(t){return t.install=e=>{const{name:n}=t;n&&e.component(n,t)},t}const Yn={get(t,e="localStorage"){const n=this.getStorage(e);return n?n.getItem(t):null},set(t,e,n="localStorage"){const o=this.getStorage(n);o&&o.setItem(t,e)},remove(t,e="localStorage"){const n=this.getStorage(e);n&&n.removeItem(t)},clear(t="localStorage"){const e=this.getStorage(t);e&&e.clear()},getStorage(t){return t==="localStorage"&&typeof localStorage<"u"?localStorage:t==="sessionStorage"&&typeof sessionStorage<"u"?sessionStorage:null}};function ur(t){return t.replace(t[0],t[0].toLocaleUpperCase())}const Qa=(t,e=["px","%","rem","em"])=>{const n=/(\d+)(\D+)/,o=t.match(n);let r={number:0,unit:""};return o&&(r={number:parseInt(o[1],10),unit:e.includes(o[2])?o[2]:e[0]}),r};for(let t=0;t<=15;t++)t.toString(16);const hc=(t,e="_blank")=>{e=="_blank"?window.open(t):window.location.href=t},gc=(t,e="yyyy-mm-dd hh:MM:ss")=>{t||(t=Number(new Date)),t.toString().length===10&&(t=+t*1e3);const n=new Date(t);let o;const r={"y+":n.getFullYear().toString(),"m+":(n.getMonth()+1).toString(),"d+":n.getDate().toString(),"h+":n.getHours().toString(),"M+":n.getMinutes().toString(),"s+":n.getSeconds().toString()};for(const a in r)o=new RegExp("("+a+")").exec(e),o&&(e=e.replace(o[1],o[1].length==1?r[a]:vc(r[a],o[1].length,"0")));return e},vc=(t,e,n=" ")=>{if(t.length>=e)return t;const o=e-t.length;let r=Math.ceil(o/n.length);for(;r>>=1;)n+=n,r===1&&(n+=n);return n.slice(0,o)+t},al=(t,e,n)=>{for(const o in t)if(t[o][e]==n)return o;return!1},il=(t,e,n=-1)=>{for(const o in t){if(typeof n=="number"&&n++,n==e)return t[o];if(t[o].children&&(n=il(t[o].children,e,n),typeof n!="number"))return n}return n};class yc{el;constructor(e){this.el=e,this.handleWheelEvent()}handleWheelEvent(){let e="";"onmousewheel"in this.el?e="mousewheel":"onwheel"in this.el?e="wheel":"attachEvent"in window?e="onmousewheel":e="DOMMouseScroll",this.el.addEventListener(e,this.scroll,{passive:!0})}scroll=e=>{this.el.clientWidth>=this.el.scrollWidth||(this.el.scrollLeft+=e.deltaY?e.deltaY:e.detail&&e.detail!==0?e.detail:-e.wheelDelta)}}function Za(t,e){let n=null;return function(...o){clearTimeout(n),n=setTimeout(()=>{t.apply(this,o)},e)}}function bc(t){Sc(t),Dc(t),xc(t),Ec(t)}function Ec(t){t.directive("tableLateralDrag",{created(e){new yc(e.querySelector(".el-table__body-wrapper .el-scrollbar .el-scrollbar__wrap"))}})}function xc(t){t.directive("blur",{mounted(e){Ud(e,"focus",()=>e.blur())}})}function Dc(t){t.directive("zoom",{mounted(e,n){if(!n.value)return!1;const o=cc(n.value)?[n.value,".el-dialog__body",!1,!0]:n.value;o[1]=o[1]?o[1]:".el-dialog__body",o[2]=typeof o[2]>"u"?!1:o[2],o[3]=typeof o[3]>"u"?!0:o[3],vt(()=>{const r=document.querySelector(o[1]),a=document.querySelector(o[0]),l=document.createElement("div");l.className="zoom-handle",l.onmouseenter=()=>{l.onmousedown=i=>{const u=i.clientX,s=i.clientY,p=r.offsetWidth,f=r.offsetHeight,d=a.offsetWidth,v=a.offsetHeight;document.onmousemove=D=>{D.preventDefault();const m=p+(D.clientX-u)*2,c=f+(D.clientY-s);if(r.style.width=`${m}px`,r.style.height=`${c}px`,o[2]){const b=v+(D.clientY-s);a.style.height=`${b}px`}if(o[3]){const b=d+(D.clientX-u)*2;a.style.width=`${b}px`}},document.onmouseup=function(){document.onmousemove=null,document.onmouseup=null}}},a.appendChild(l)})}})}function Sc(t){t.directive("drag",{mounted(e,n){if(!n.value)return!1;const o=document.querySelector(n.value[0]),r=document.querySelector(n.value[1]);if(!r||!o)return!1;r.onmouseover=()=>r.style.cursor="move";function a(i,u){const s=u==="pc"?i.clientX-r.offsetLeft:i.touches[0].clientX-r.offsetLeft,p=u==="pc"?i.clientY-r.offsetTop:i.touches[0].clientY-r.offsetTop,f=document.body.clientWidth,d=document.body.clientHeight||document.documentElement.clientHeight,v=o.offsetWidth,D=o.offsetHeight,m=o.offsetLeft,c=f-o.offsetLeft-v,b=o.offsetTop,h=d-o.offsetTop-D;let E=getComputedStyle(o).left,g=getComputedStyle(o).top;return E=+E.replace(/\px/g,""),g=+g.replace(/\px/g,""),{disX:s,disY:p,minDragDomLeft:m,maxDragDomLeft:c,minDragDomTop:b,maxDragDomTop:h,styL:E,styT:g}}function l(i,u,s){const{disX:p,disY:f,minDragDomLeft:d,maxDragDomLeft:v,minDragDomTop:D,maxDragDomTop:m,styL:c,styT:b}=s;let h=u==="pc"?i.clientX-p:i.touches[0].clientX-p,E=u==="pc"?i.clientY-f:i.touches[0].clientY-f;-h>d?h=-d:h>v&&(h=v),-E>D?E=-D:E>m&&(E=m),o.style.cssText+=`;left:${h+c}px;top:${E+b}px;`}r.onmousedown=i=>{const u=a(i,"pc");document.onmousemove=s=>{l(s,"pc",u)},document.onmouseup=()=>{document.onmousemove=null,document.onmouseup=null}},r.ontouchstart=i=>{const u=a(i,"app");document.ontouchmove=s=>{l(s,"app",u)},document.ontouchend=()=>{document.ontouchmove=null,document.ontouchend=null}}}})}const Xn=t=>({type:String,default:t}),qa={type:Xn(""),test:{default:"\u6D4B\u8BD5\u6D4B\u8BD5",type:String}},wc={class:"mr-10px"},Fc=Y({name:"DkTest"});var Cc=Y({...Fc,props:qa,setup(t){return yt("test"),(e,n)=>{const o=C("el-button"),r=C("van-button");return F(),I(Z,null,[x(o,{class:"dk-test"},{default:S(()=>[Q("Test")]),_:1}),x(r,null,{default:S(()=>[Q("vant")]),_:1}),k("div",wc,ce(e.test),1)],64)}}}),ee=(t,e)=>{const n=t.__vccOpts||t;for(const[o,r]of e)n[o]=r;return n},Ac=ee(Cc,[["__file","E:\\project\\monster-admin\\system\\dkgs-ui_test\\dk-ui-all\\packages\\dk-ui\\src\\test\\src\\test.vue"]]);const ei=ke(Ac);function kc(t,e){return{}.hasOwnProperty.call(t,e)}function yo(t,e,n){t[e]=n}function ul(t){return sl({},{value:t},void 0).value}function sl(t,e={},n=!1){let o=!1;for(const r in e)if(Object.prototype.hasOwnProperty.call(e,r)){let a=e[r];if((o=Array.isArray(a))||Xa(a)){const l=t[r]===void 0;if(o)o=!1,l&&yo(t,r,[]);else if(a._clone&&n)if(n)a=a.getRule(),l&&yo(t,r,{});else{yo(t,r,a._clone());continue}else l&&yo(t,r,{});t[r]=sl(t[r],a,n)}else yo(t,r,a),tl(a)||(tl(a.__json)||(t[r].__json=a.__json),tl(a.__origin)||(t[r].__origin=a.__origin))}return n!==void 0&&Array.isArray(t)?t.filter(r=>!r||!r.__ctrl):t}function _c(t,e,n){t[e]=n}const Bc=Object.assign||function(t){for(let e=1;e<arguments.length;e++){const n=arguments[e];for(const o in n)Object.prototype.hasOwnProperty.call(n,o)&&_c(t,o,n[o])}return t};function Tc(...t){return Bc.apply(this,t)}var Oc=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Ic(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function $c(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var n=function o(){return this instanceof o?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};n.prototype=e.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(t).forEach(function(o){var r=Object.getOwnPropertyDescriptor(t,o);Object.defineProperty(n,o,r.get?r:{enumerable:!0,get:function(){return t[o]}})}),n}var ti={exports:{}};/**!
1
+ import"uno.css";import Jr from"axios";import{ElLoading as $d,ElMessage as wt,ElButton as Va,ElMessageBox as Qr,ElNotification as Ra}from"element-plus";import Vd,{ref as z,reactive as Oe,nextTick as vt,defineComponent as Y,resolveComponent as C,openBlock as F,createElementBlock as I,Fragment as Z,createVNode as x,withCtx as S,createTextVNode as Q,createElementVNode as k,toDisplayString as ce,markRaw as Pa,watch as le,onMounted as Ft,normalizeClass as xe,createBlock as U,createCommentVNode as $,unref as H,computed as we,normalizeStyle as ne,renderSlot as ut,resolveDynamicComponent as Hn,useSlots as Rd,useAttrs as Pd,mergeProps as nt,createSlots as Bn,resolveDirective as Tn,renderList as de,withModifiers as On,withDirectives as Me,vShow as ho,vModelText as or,TransitionGroup as jd,h as rr,inject as In,toRefs as Zr,getCurrentInstance as Nd,provide as lr,toRef as Md,withKeys as Ld,normalizeProps as ja,guardReactiveProps as Na,warn as zd}from"vue";import{useEventListener as Ud,useElementSize as Wn,useWindowSize as Hd}from"@vueuse/core";import Ma from"@tinymce/tinymce-vue";import{Icon as Wd,disableCache as Gd,listIcons as Yd}from"@iconify/vue";import*as La from"@element-plus/icons-vue";import{Search as za,CircleClose as Xd}from"@element-plus/icons-vue";import ar from"@vant/icons";import ir from"@form-create/element-ui";import Kd,{DraggableContainer as Jd}from"vue3-draggable-resizable";const Ua=t=>t!==null&&typeof t=="object",Qd=t=>t!=null,Zd=t=>typeof t=="function";function Ha(t,e){const n=e.split(".");let o=t;return n.forEach(r=>{var a;o=Ua(o)&&(a=o[r])!=null?a:""}),o}const qd=/-(\w)/g,ec=t=>t.replace(qd,(e,n)=>n.toUpperCase()),{hasOwnProperty:tc}=Object.prototype;function nc(t,e,n){const o=e[n];Qd(o)&&(!tc.call(t,n)||!Ua(o)?t[n]=o:t[n]=Wa(Object(t[n]),o))}function Wa(t,e){return Object.keys(e).forEach(n=>{nc(t,e,n)}),t}var oc={name:"\u59D3\u540D",tel:"\u7535\u8BDD",save:"\u4FDD\u5B58",clear:"\u6E05\u7A7A",cancel:"\u53D6\u6D88",confirm:"\u786E\u8BA4",delete:"\u5220\u9664",loading:"\u52A0\u8F7D\u4E2D...",noCoupon:"\u6682\u65E0\u4F18\u60E0\u5238",nameEmpty:"\u8BF7\u586B\u5199\u59D3\u540D",addContact:"\u6DFB\u52A0\u8054\u7CFB\u4EBA",telInvalid:"\u8BF7\u586B\u5199\u6B63\u786E\u7684\u7535\u8BDD",vanCalendar:{end:"\u7ED3\u675F",start:"\u5F00\u59CB",title:"\u65E5\u671F\u9009\u62E9",weekdays:["\u65E5","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D"],monthTitle:(t,e)=>`${t}\u5E74${e}\u6708`,rangePrompt:t=>`\u6700\u591A\u9009\u62E9 ${t} \u5929`},vanCascader:{select:"\u8BF7\u9009\u62E9"},vanPagination:{prev:"\u4E0A\u4E00\u9875",next:"\u4E0B\u4E00\u9875"},vanPullRefresh:{pulling:"\u4E0B\u62C9\u5373\u53EF\u5237\u65B0...",loosing:"\u91CA\u653E\u5373\u53EF\u5237\u65B0..."},vanSubmitBar:{label:"\u5408\u8BA1:"},vanCoupon:{unlimited:"\u65E0\u95E8\u69DB",discount:t=>`${t}\u6298`,condition:t=>`\u6EE1${t}\u5143\u53EF\u7528`},vanCouponCell:{title:"\u4F18\u60E0\u5238",count:t=>`${t}\u5F20\u53EF\u7528`},vanCouponList:{exchange:"\u5151\u6362",close:"\u4E0D\u4F7F\u7528",enable:"\u53EF\u7528",disabled:"\u4E0D\u53EF\u7528",placeholder:"\u8F93\u5165\u4F18\u60E0\u7801"},vanAddressEdit:{area:"\u5730\u533A",areaEmpty:"\u8BF7\u9009\u62E9\u5730\u533A",addressEmpty:"\u8BF7\u586B\u5199\u8BE6\u7EC6\u5730\u5740",addressDetail:"\u8BE6\u7EC6\u5730\u5740",defaultAddress:"\u8BBE\u4E3A\u9ED8\u8BA4\u6536\u8D27\u5730\u5740"},vanAddressList:{add:"\u65B0\u589E\u5730\u5740"}};const Ga=z("zh-CN"),Ya=Oe({"zh-CN":oc}),rc={messages(){return Ya[Ga.value]},use(t,e){Ga.value=t,this.add({[t]:e})},add(t={}){Wa(Ya,t)}};var lc=rc;function ac(t){const e=ec(t)+".";return(n,...o)=>{const r=lc.messages(),a=Ha(r,e+n)||Ha(r,n);return Zd(a)?a(...o):a}}function qr(t,e){return e?typeof e=="string"?` ${t}--${e}`:Array.isArray(e)?e.reduce((n,o)=>n+qr(t,o),""):Object.keys(e).reduce((n,o)=>n+(e[o]?qr(t,o):""),""):""}function ic(t){return(e,n)=>(e&&typeof e!="string"&&(n=e,e=""),e=e?`${t}__${e}`:t,`${e}${qr(e,n)}`)}function yt(t){const e=`dk-${t}`;return[e,ic(e),ac(e)]}const Gn={ApiUrl:"https://independence.heiduoke.cn",AccessToken:"3c388087-0f14-4f8d-8463-9fc9932ce2f6",Plaid:16,AddonName:"demo_wx",ProjectType:"addon"};function uc(t){Object.assign(Gn,t)}function go(){return Gn}const sc=Object.prototype.toString,el=(t,e)=>sc.call(t)===`[object ${e}]`,dc=t=>typeof t<"u",tl=t=>!dc(t),Xa=t=>t!==null&&el(t,"Object"),nl=t=>el(t,"Number"),cc=t=>el(t,"String"),ol=t=>t&&Array.isArray(t),vo=new Map,bn={target:null,count:0};function Ka(t){const{url:e,method:n,params:o}=t;let{data:r}=t;return typeof r=="string"&&(r=JSON.parse(r)),[e,n,JSON.stringify(o),JSON.stringify(r)].join("&")}function fc(t){const e=Ka(t);t.cancelToken=t.cancelToken||new Jr.CancelToken(n=>{vo.has(e)||vo.set(e,n)})}function rl(t){const e=Ka(t);vo.has(e)&&(vo.get(e)(e),vo.delete(e))}function Ja(t){t.loading&&bn.count>0&&bn.count--,bn.count===0&&(bn.target.close(),bn.target=null)}function pc(t){if(Jr.isCancel(t))return console.warn("\u8BF7\u6C42\u7684\u91CD\u590D\u8BF7\u6C42\uFF1A"+t.message);let e="";if(t&&t.response)switch(t.response.status){case 302:e="\u63A5\u53E3\u91CD\u5B9A\u5411\u4E86\uFF01";break;case 400:e="\u53C2\u6570\u4E0D\u6B63\u786E\uFF01";break;case 401:e="\u60A8\u672A\u767B\u5F55\uFF0C\u6216\u8005\u767B\u5F55\u5DF2\u7ECF\u8D85\u65F6\uFF0C\u8BF7\u5148\u767B\u5F55\uFF01";break;case 403:e="\u60A8\u6CA1\u6709\u6743\u9650\u64CD\u4F5C\uFF01";break;case 404:e=`\u8BF7\u6C42\u5730\u5740\u51FA\u9519: ${t.response.config.url}`;break;case 408:e="\u8BF7\u6C42\u8D85\u65F6\uFF01";break;case 409:e="\u7CFB\u7EDF\u5DF2\u5B58\u5728\u76F8\u540C\u6570\u636E\uFF01";break;case 500:e="\u670D\u52A1\u5668\u5185\u90E8\u9519\u8BEF\uFF01";break;case 501:e="\u670D\u52A1\u672A\u5B9E\u73B0\uFF01";break;case 502:e="\u7F51\u5173\u9519\u8BEF\uFF01";break;case 503:e="\u670D\u52A1\u4E0D\u53EF\u7528\uFF01";break;case 504:e="\u670D\u52A1\u6682\u65F6\u65E0\u6CD5\u8BBF\u95EE\uFF0C\u8BF7\u7A0D\u540E\u518D\u8BD5\uFF01";break;case 505:e="HTTP\u7248\u672C\u4E0D\u53D7\u652F\u6301\uFF01";break;default:e="\u5F02\u5E38\u95EE\u9898\uFF0C\u8BF7\u8054\u7CFB\u7BA1\u7406\u5458\uFF01";break}t.message.includes("timeout")&&(e="\u7F51\u7EDC\u8BF7\u6C42\u8D85\u65F6\uFF01"),t.message.includes("Network")&&(e=window.navigator.onLine?"\u670D\u52A1\u7AEF\u5F02\u5E38\uFF01":"\u60A8\u65AD\u7F51\u4E86\uFF01"),wt({type:"error",message:e})}const ot=(t,e,n)=>{const o=Jr.create({...t,baseURL:go().ApiUrl}),r=Object.assign({repeat_request_cancel:!0,loading:!1,reduct_data_format:!0,error_message_show:!0,code_success_show:!1,code_error_show:!1},e);return o.interceptors.request.use(a=>(rl(a),r.repeat_request_cancel&&fc(a),r.loading&&(bn.count++,bn.count===1&&(bn.target=$d.service(n))),a.headers["Access-Token"]=go().AccessToken,a.headers["Project-Type"]=go().ProjectType,a.headers.addon=go().AddonName,a.headers.Plaid=go().Plaid,a.params=a.params||{},a.params._ajax=1,a),a=>(console.log("error",a),Promise.reject(a))),o.interceptors.response.use(a=>{rl(a.config),r.loading&&Ja(r);const l=a.data,i=l.code;if(i===0)return r.code_success_show&&wt.success(l.msg),l;switch(r.code_error_show&&wt.error(l.msg),i){case-1:return Promise.reject(l);case 401:break;default:return Promise.reject(a.data||{msg:"\u672A\u77E5\u9519\u8BEF"})}return l},a=>(console.log("error",a),a.config&&rl(a.config),r.error_message_show&&pc(a),r.loading&&Ja(r),Promise.reject(a))),o.request(t)},ll=t=>{const e={file:0,image:1,audio:2,video:3};return typeof t=="number"||/^\d+$/.test(t)?parseInt(t,10):e[t]},mc=t=>{const e={0:"\u6587\u4EF6\u9009\u62E9",1:"\u9009\u62E9\u56FE\u7247",2:"\u9009\u62E9\u97F3\u9891",3:"\u9009\u62E9\u89C6\u9891"},n=ll(t);return e[n]||"\u6587\u4EF6\u9009\u62E9"};function ke(t){return t.install=e=>{const{name:n}=t;n&&e.component(n,t)},t}const Yn={get(t,e="localStorage"){const n=this.getStorage(e);return n?n.getItem(t):null},set(t,e,n="localStorage"){const o=this.getStorage(n);o&&o.setItem(t,e)},remove(t,e="localStorage"){const n=this.getStorage(e);n&&n.removeItem(t)},clear(t="localStorage"){const e=this.getStorage(t);e&&e.clear()},getStorage(t){return t==="localStorage"&&typeof localStorage<"u"?localStorage:t==="sessionStorage"&&typeof sessionStorage<"u"?sessionStorage:null}};function ur(t){return t.replace(t[0],t[0].toLocaleUpperCase())}const Qa=(t,e=["px","%","rem","em"])=>{const n=/(\d+)(\D+)/,o=t.match(n);let r={number:0,unit:""};return o&&(r={number:parseInt(o[1],10),unit:e.includes(o[2])?o[2]:e[0]}),r};for(let t=0;t<=15;t++)t.toString(16);const hc=(t,e="_blank")=>{e=="_blank"?window.open(t):window.location.href=t},gc=(t,e="yyyy-mm-dd hh:MM:ss")=>{t||(t=Number(new Date)),t.toString().length===10&&(t=+t*1e3);const n=new Date(t);let o;const r={"y+":n.getFullYear().toString(),"m+":(n.getMonth()+1).toString(),"d+":n.getDate().toString(),"h+":n.getHours().toString(),"M+":n.getMinutes().toString(),"s+":n.getSeconds().toString()};for(const a in r)o=new RegExp("("+a+")").exec(e),o&&(e=e.replace(o[1],o[1].length==1?r[a]:vc(r[a],o[1].length,"0")));return e},vc=(t,e,n=" ")=>{if(t.length>=e)return t;const o=e-t.length;let r=Math.ceil(o/n.length);for(;r>>=1;)n+=n,r===1&&(n+=n);return n.slice(0,o)+t},al=(t,e,n)=>{for(const o in t)if(t[o][e]==n)return o;return!1},il=(t,e,n=-1)=>{for(const o in t){if(typeof n=="number"&&n++,n==e)return t[o];if(t[o].children&&(n=il(t[o].children,e,n),typeof n!="number"))return n}return n};class yc{el;constructor(e){this.el=e,this.handleWheelEvent()}handleWheelEvent(){let e="";"onmousewheel"in this.el?e="mousewheel":"onwheel"in this.el?e="wheel":"attachEvent"in window?e="onmousewheel":e="DOMMouseScroll",this.el.addEventListener(e,this.scroll,{passive:!0})}scroll=e=>{this.el.clientWidth>=this.el.scrollWidth||(this.el.scrollLeft+=e.deltaY?e.deltaY:e.detail&&e.detail!==0?e.detail:-e.wheelDelta)}}function Za(t,e){let n=null;return function(...o){clearTimeout(n),n=setTimeout(()=>{t.apply(this,o)},e)}}function bc(t){Sc(t),Dc(t),xc(t),Ec(t)}function Ec(t){t.directive("tableLateralDrag",{created(e){new yc(e.querySelector(".el-table__body-wrapper .el-scrollbar .el-scrollbar__wrap"))}})}function xc(t){t.directive("blur",{mounted(e){Ud(e,"focus",()=>e.blur())}})}function Dc(t){t.directive("zoom",{mounted(e,n){if(!n.value)return!1;const o=cc(n.value)?[n.value,".el-dialog__body",!1,!0]:n.value;o[1]=o[1]?o[1]:".el-dialog__body",o[2]=typeof o[2]>"u"?!1:o[2],o[3]=typeof o[3]>"u"?!0:o[3],vt(()=>{const r=document.querySelector(o[1]),a=document.querySelector(o[0]),l=document.createElement("div");l.className="zoom-handle",l.onmouseenter=()=>{l.onmousedown=i=>{const u=i.clientX,s=i.clientY,p=r.offsetWidth,f=r.offsetHeight,d=a.offsetWidth,v=a.offsetHeight;document.onmousemove=D=>{D.preventDefault();const m=p+(D.clientX-u)*2,c=f+(D.clientY-s);if(r.style.width=`${m}px`,r.style.height=`${c}px`,o[2]){const b=v+(D.clientY-s);a.style.height=`${b}px`}if(o[3]){const b=d+(D.clientX-u)*2;a.style.width=`${b}px`}},document.onmouseup=function(){document.onmousemove=null,document.onmouseup=null}}},a.appendChild(l)})}})}function Sc(t){t.directive("drag",{mounted(e,n){if(!n.value)return!1;const o=document.querySelector(n.value[0]),r=document.querySelector(n.value[1]);if(!r||!o)return!1;r.onmouseover=()=>r.style.cursor="move";function a(i,u){const s=u==="pc"?i.clientX-r.offsetLeft:i.touches[0].clientX-r.offsetLeft,p=u==="pc"?i.clientY-r.offsetTop:i.touches[0].clientY-r.offsetTop,f=document.body.clientWidth,d=document.body.clientHeight||document.documentElement.clientHeight,v=o.offsetWidth,D=o.offsetHeight,m=o.offsetLeft,c=f-o.offsetLeft-v,b=o.offsetTop,h=d-o.offsetTop-D;let E=getComputedStyle(o).left,g=getComputedStyle(o).top;return E=+E.replace(/\px/g,""),g=+g.replace(/\px/g,""),{disX:s,disY:p,minDragDomLeft:m,maxDragDomLeft:c,minDragDomTop:b,maxDragDomTop:h,styL:E,styT:g}}function l(i,u,s){const{disX:p,disY:f,minDragDomLeft:d,maxDragDomLeft:v,minDragDomTop:D,maxDragDomTop:m,styL:c,styT:b}=s;let h=u==="pc"?i.clientX-p:i.touches[0].clientX-p,E=u==="pc"?i.clientY-f:i.touches[0].clientY-f;-h>d?h=-d:h>v&&(h=v),-E>D?E=-D:E>m&&(E=m),o.style.cssText+=`;left:${h+c}px;top:${E+b}px;`}r.onmousedown=i=>{const u=a(i,"pc");document.onmousemove=s=>{l(s,"pc",u)},document.onmouseup=()=>{document.onmousemove=null,document.onmouseup=null}},r.ontouchstart=i=>{const u=a(i,"app");document.ontouchmove=s=>{l(s,"app",u)},document.ontouchend=()=>{document.ontouchmove=null,document.ontouchend=null}}}})}const Xn=t=>({type:String,default:t}),qa={type:Xn(""),test:{default:"\u6D4B\u8BD5\u6D4B\u8BD5",type:String}},wc={class:"mr-10px"},Fc=Y({name:"DkTest"});var Cc=Y({...Fc,props:qa,setup(t){return yt("test"),(e,n)=>{const o=C("el-button"),r=C("van-button");return F(),I(Z,null,[x(o,{class:"dk-test"},{default:S(()=>[Q("Test")]),_:1}),x(r,null,{default:S(()=>[Q("vant")]),_:1}),k("div",wc,ce(e.test),1)],64)}}}),ee=(t,e)=>{const n=t.__vccOpts||t;for(const[o,r]of e)n[o]=r;return n},Ac=ee(Cc,[["__file","E:\\project\\monster-admin\\system\\dkgs-ui_test\\dk-ui-all\\packages\\dk-ui\\src\\test\\src\\test.vue"]]);const ei=ke(Ac);function kc(t,e){return{}.hasOwnProperty.call(t,e)}function yo(t,e,n){t[e]=n}function ul(t){return sl({},{value:t},void 0).value}function sl(t,e={},n=!1){let o=!1;for(const r in e)if(Object.prototype.hasOwnProperty.call(e,r)){let a=e[r];if((o=Array.isArray(a))||Xa(a)){const l=t[r]===void 0;if(o)o=!1,l&&yo(t,r,[]);else if(a._clone&&n)if(n)a=a.getRule(),l&&yo(t,r,{});else{yo(t,r,a._clone());continue}else l&&yo(t,r,{});t[r]=sl(t[r],a,n)}else yo(t,r,a),tl(a)||(tl(a.__json)||(t[r].__json=a.__json),tl(a.__origin)||(t[r].__origin=a.__origin))}return n!==void 0&&Array.isArray(t)?t.filter(r=>!r||!r.__ctrl):t}function _c(t,e,n){t[e]=n}const Bc=Object.assign||function(t){for(let e=1;e<arguments.length;e++){const n=arguments[e];for(const o in n)Object.prototype.hasOwnProperty.call(n,o)&&_c(t,o,n[o])}return t};function Tc(...t){return Bc.apply(this,t)}var Oc=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Ic(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function $c(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var n=function o(){return this instanceof o?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};n.prototype=e.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(t).forEach(function(o){var r=Object.getOwnPropertyDescriptor(t,o);Object.defineProperty(n,o,r.get?r:{enumerable:!0,get:function(){return t[o]}})}),n}var ti={exports:{}};/**!
2
2
  * Sortable 1.14.0
3
3
  * @author RubaXa <trash@rubaxa.org>
4
4
  * @author owenm <owen23355@gmail.com>