UNPKG

xc-workflow-ui

Version:

基于vant二次封装工作流组件库

1 lines 72.9 kB
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(require("vue"),require("lamejs")):"function"==typeof define&&define.amd?define(["vue"],e):"object"==typeof exports?exports["xc-workflow-ui"]=e(require("vue"),require("lamejs")):t["xc-workflow-ui"]=e(t.Vue,t.lamejs)}(self,((t,e)=>(()=>{"use strict";var i={6568:t=>{function e(){return e=Object.assign?Object.assign.bind():function(t){for(var e,i=1;i<arguments.length;i++)for(var n in e=arguments[i])Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t},e.apply(this,arguments)}var i=["attrs","props","domProps"],n=["class","style","directives"],r=["on","nativeOn"],o=function(t,e){return function(){t&&t.apply(this,arguments),e&&e.apply(this,arguments)}};t.exports=function(t){return t.reduce((function(t,a){for(var s in a)if(t[s])if(-1!==i.indexOf(s))t[s]=e({},t[s],a[s]);else if(-1!==n.indexOf(s)){var l=t[s]instanceof Array?t[s]:[t[s]],c=a[s]instanceof Array?a[s]:[a[s]];t[s]=[].concat(l,c)}else if(-1!==r.indexOf(s))for(var u in a[s])if(t[s][u]){var h=t[s][u]instanceof Array?t[s][u]:[t[s][u]],f=a[s][u]instanceof Array?a[s][u]:[a[s][u]];t[s][u]=[].concat(h,f)}else t[s][u]=a[s][u];else if("hook"===s)for(var d in a[s])t[s][d]=t[s][d]?o(t[s][d],a[s][d]):a[s][d];else t[s]=a[s];else t[s]=a[s];return t}),{})}},8219:(t,e,i)=>{function n(t){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n(t)}function r(t,e){for(var i=0;i<e.length;i++){var r=e[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,(o=r.key,a=void 0,a=function(t,e){if("object"!==n(t)||null===t)return t;var i=t[Symbol.toPrimitive];if(void 0!==i){var r=i.call(t,e||"default");if("object"!==n(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(o,"string"),"symbol"===n(a)?a:String(a)),r)}var o,a}function o(t,e,i){!function(t,e){if(e.has(t))throw new TypeError("Cannot initialize the same private elements twice on an object")}(t,e),e.set(t,i)}function a(t,e){return function(t,e){if(e.get)return e.get.call(t);return e.value}(t,l(t,e,"get"))}function s(t,e,i){return function(t,e,i){if(e.set)e.set.call(t,i);else{if(!e.writable)throw new TypeError("attempted to set read only private field");e.value=i}}(t,l(t,e,"set"),i),i}function l(t,e,i){if(!e.has(t))throw new TypeError("attempted to "+i+" private field on non-instance");return e.get(t)}i.d(e,{Q:()=>h});var c=new WeakMap,u=new WeakMap,h=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),o(this,c,{writable:!0,value:void 0}),o(this,u,{writable:!0,value:function(t,e){var i=t.data,n=t.code,r=t.success,o=t.msg,a=!0;return 200===n&&r||(a=!a),!a&&console.warn(o||"response parse error while using default response handle!"),a?i:e}})}var e,i,n;return e=t,(i=[{key:"registerCustomHandle",value:function(t){var e=!1;return"function"==typeof t&&(e=!0,s(this,c,t)),e}},{key:"handleResponse",value:function(t,e){return"function"==typeof a(this,c)?a(this,c).call(this,t):a(this,u).call(this,t,e)}}])&&r(e.prototype,i),n&&r(e,n),Object.defineProperty(e,"prototype",{writable:!1}),t}()},4592:(t,e,i)=>{i.d(e,{Ih:()=>r,TD:()=>n,an:()=>o,u7:()=>s,xd:()=>a});var n=function(t){return function(e){e.component(t.name,t)}},r=function(t){return{type:String,required:arguments.length>1&&void 0!==arguments[1]&&arguments[1],default:t||""}},o=function(t){return{type:Number,required:arguments.length>1&&void 0!==arguments[1]&&arguments[1],default:t||0}},a=function(t){return{type:Boolean,required:arguments.length>1&&void 0!==arguments[1]&&arguments[1],default:t||!1}},s=function(t){return{type:Array,required:arguments.length>1&&void 0!==arguments[1]&&arguments[1],default:t||[]}}},5891:(t,e,i)=>{i.d(e,{ml:()=>r});i(4130);var n=new RegExp("[`~!@#$^&*(){}':;',\\[\\]《》/?~!@#¥……&*()|{}【】‘;:”“'。,、?]"),r=function(t){return n.test(t)}},4054:(t,e,i)=>{i.d(e,{o:()=>n});var n={prop:"text",event:"change"}},3456:(t,e,i)=>{i.d(e,{w2:()=>c});var n=i(4592);function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function o(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,n)}return i}function a(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?o(Object(i),!0).forEach((function(e){s(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):o(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}function s(t,e,i){return(e=function(t){var e=function(t,e){if("object"!==r(t)||null===t)return t;var i=t[Symbol.toPrimitive];if(void 0!==i){var n=i.call(t,e||"default");if("object"!==r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"===r(e)?e:String(e)}(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var l={required:(0,n.xd)(),placeholder:(0,n.Ih)(),label:(0,n.Ih)(),border:(0,n.xd)(!0),rules:(0,n.u7)(),name:(0,n.Ih)(),dictCode:(0,n.Ih)(),defaultValue:(0,n.Ih)(),editable:(0,n.xd)(!0,!1),text:[String,Number]},c=(a(a({},l),{},{maxLength:(0,n.an)(200),rows:(0,n.an)(3),showWordLimit:(0,n.xd)(),visible:(0,n.xd)(),type:(0,n.Ih)(),min:(0,n.an)(-1/0),max:(0,n.an)(1/0),storageKey:(0,n.Ih)(""),fromStorage:(0,n.xd)(!1),readonly:(0,n.xd)(!1)}),a(a({},l),{},{linkComponents:(0,n.Ih)(),refer:(0,n.Ih)(),description:(0,n.Ih)(),hideSearch:(0,n.xd)()}),a(a({},l),{},{selectCount:(0,n.an)()}),a(a({},l),{},{accept:(0,n.Ih)("*"),breakChar:(0,n.Ih)(","),visible:(0,n.xd)(),maxSize:(0,n.an)(5242880),id:[String,Number],maxCount:{type:[String,Number],default:9},text:[String,Array]}));a(a({},l),{},{type:(0,n.Ih)("date"),title:(0,n.Ih)(),format:(0,n.Ih)(),visible:(0,n.xd)(),linkComponents:(0,n.Ih)(""),calcType:(0,n.Ih)("")}),a(a({},l),{},{title:(0,n.Ih)(),parentId:(0,n.Ih)(),refer:(0,n.Ih)(),companion:(0,n.Ih)(),visible:(0,n.xd)(),selectType:(0,n.xd)(),queryParam:(0,n.Ih)(),regionId:(0,n.Ih)()}),a(a({},l),{},{latfield:(0,n.Ih)("wd"),lngfield:(0,n.Ih)("jd"),visible:(0,n.xd)(),jd:(0,n.Ih)(),wd:(0,n.Ih)(),mode:(0,n.Ih)("locate"),category:(0,n.Ih)("cateNode"),subcategory:(0,n.Ih)("subCategory"),outGridTip:(0,n.Ih)("")}),a(a({},l),{},{companion:(0,n.Ih)(),visible:(0,n.xd)()}),a(a({},l),{},{visible:(0,n.xd)()})},2391:()=>{},2293:()=>{},6018:()=>{},8010:()=>{},1383:()=>{},5388:()=>{},6799:()=>{},677:()=>{},6629:()=>{},2254:()=>{},9415:()=>{},9233:(t,e,i)=>{i.d(e,{Z:()=>m});var n=i(9592),r=i(6568),o=i.n(r),a=i(5976),s=i(8546),l=i(6122),c=i(7692),u=i(806),h=i(1392),f=(0,a.d)("cell"),d=f[0],v=f[1];function p(t,e,i,n){var r,a=e.icon,u=e.size,f=e.title,d=e.label,p=e.value,m=e.isLink,g=i.title||(0,s.Xq)(f);function y(){if(i.label||(0,s.Xq)(d))return t("div",{class:[v("label"),e.labelClass]},[i.label?i.label():d])}var b=null!=(r=e.clickable)?r:m,w={clickable:b,center:e.center,required:e.required,borderless:!e.border};return u&&(w[u]=u),t("div",o()([{class:v(w),attrs:{role:b?"button":null,tabindex:b?0:null},on:{click:function(t){(0,l.j8)(n,"click",t),(0,c.fz)(n)}}},(0,l.ED)(n)]),[i.icon?i.icon():a?t(h.Z,{class:v("left-icon"),attrs:{name:a,classPrefix:e.iconPrefix}}):void 0,function(){if(g)return t("div",{class:[v("title"),e.titleClass],style:e.titleStyle},[i.title?i.title():t("span",[f]),y()])}(),function(){if(i.default||(0,s.Xq)(p))return t("div",{class:[v("value",{alone:!g}),e.valueClass]},[i.default?i.default():t("span",[p])])}(),function(){var n=i["right-icon"];if(n)return n();if(m){var r=e.arrowDirection;return t(h.Z,{class:v("right-icon"),attrs:{name:r?"arrow-"+r:"arrow"}})}}(),null==i.extra?void 0:i.extra()])}p.props=(0,n.Z)({},u.T,c.g2);const m=d(p)},806:(t,e,i)=>{i.d(e,{T:()=>n});var n={icon:String,size:String,center:Boolean,isLink:Boolean,required:Boolean,iconPrefix:String,titleStyle:null,titleClass:null,valueClass:null,labelClass:null,title:[Number,String],value:[Number,String],label:[Number,String],arrowDirection:String,border:{type:Boolean,default:!0},clickable:{type:Boolean,default:null}}},7132:(t,e,i)=>{i.d(e,{Z:()=>b});var n=i(6568),r=i.n(n),o=i(9592),a=i(8546);var s=i(1750),l=!a.sk&&/ios|iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase());var c=i(8169),u=i(5566),h=i(5976),f=i(216),d=i(1392),v=i(9233),p=i(806),m=(0,h.d)("field"),g=m[0],y=m[1];const b=g({inheritAttrs:!1,provide:function(){return{vanField:this}},inject:{vanForm:{default:null}},props:(0,o.Z)({},p.T,{name:String,rules:Array,disabled:{type:Boolean,default:null},readonly:{type:Boolean,default:null},autosize:[Boolean,Object],leftIcon:String,rightIcon:String,clearable:Boolean,formatter:Function,maxlength:[Number,String],labelWidth:[Number,String],labelClass:null,labelAlign:String,inputAlign:String,placeholder:String,errorMessage:String,errorMessageAlign:String,showWordLimit:Boolean,value:{type:[Number,String],default:""},type:{type:String,default:"text"},error:{type:Boolean,default:null},colon:{type:Boolean,default:null},clearTrigger:{type:String,default:"focus"},formatTrigger:{type:String,default:"onChange"}}),data:function(){return{focused:!1,validateFailed:!1,validateMessage:""}},watch:{value:function(){this.updateValue(this.value),this.resetValidation(),this.validateWithTrigger("onChange"),this.$nextTick(this.adjustSize)}},mounted:function(){this.updateValue(this.value,this.formatTrigger),this.$nextTick(this.adjustSize),this.vanForm&&this.vanForm.addField(this)},beforeDestroy:function(){this.vanForm&&this.vanForm.removeField(this)},computed:{showClear:function(){var t=this.getProp("readonly");if(this.clearable&&!t){var e=(0,a.Xq)(this.value)&&""!==this.value,i="always"===this.clearTrigger||"focus"===this.clearTrigger&&this.focused;return e&&i}},showError:function(){return null!==this.error?this.error:!!(this.vanForm&&this.vanForm.showError&&this.validateFailed)||void 0},listeners:function(){return(0,o.Z)({},this.$listeners,{blur:this.onBlur,focus:this.onFocus,input:this.onInput,click:this.onClickInput,keypress:this.onKeypress})},labelStyle:function(){var t=this.getProp("labelWidth");if(t)return{width:(0,f.N)(t)}},formValue:function(){return this.children&&(this.$scopedSlots.input||this.$slots.input)?this.children.value:this.value}},methods:{focus:function(){this.$refs.input&&this.$refs.input.focus()},blur:function(){this.$refs.input&&this.$refs.input.blur()},runValidator:function(t,e){return new Promise((function(i){var n=e.validator(t,e);if((0,a.tI)(n))return n.then(i);i(n)}))},isEmptyValue:function(t){return Array.isArray(t)?!t.length:0!==t&&!t},runSyncRule:function(t,e){return(!e.required||!this.isEmptyValue(t))&&!(e.pattern&&!e.pattern.test(t))},getRuleMessage:function(t,e){var i=e.message;return(0,a.mf)(i)?i(t,e):i},runRules:function(t){var e=this;return t.reduce((function(t,i){return t.then((function(){if(!e.validateFailed){var t=e.formValue;return i.formatter&&(t=i.formatter(t,i)),e.runSyncRule(t,i)?i.validator?e.runValidator(t,i).then((function(n){!1===n&&(e.validateFailed=!0,e.validateMessage=e.getRuleMessage(t,i))})):void 0:(e.validateFailed=!0,void(e.validateMessage=e.getRuleMessage(t,i)))}}))}),Promise.resolve())},validate:function(t){var e=this;return void 0===t&&(t=this.rules),new Promise((function(i){t||i(),e.resetValidation(),e.runRules(t).then((function(){e.validateFailed?i({name:e.name,message:e.validateMessage}):i()}))}))},validateWithTrigger:function(t){if(this.vanForm&&this.rules){var e=this.vanForm.validateTrigger===t,i=this.rules.filter((function(i){return i.trigger?i.trigger===t:e}));i.length&&this.validate(i)}},resetValidation:function(){this.validateFailed&&(this.validateFailed=!1,this.validateMessage="")},updateValue:function(t,e){void 0===e&&(e="onChange"),t=(0,a.Xq)(t)?String(t):"";var i=this.maxlength;if((0,a.Xq)(i)&&t.length>i&&(t=this.value&&this.value.length===+i?this.value:t.slice(0,i)),"number"===this.type||"digit"===this.type){var n="number"===this.type;t=(0,c.uf)(t,n,n)}this.formatter&&e===this.formatTrigger&&(t=this.formatter(t));var r=this.$refs.input;r&&t!==r.value&&(r.value=t),t!==this.value&&this.$emit("input",t)},onInput:function(t){t.target.composing||this.updateValue(t.target.value)},onFocus:function(t){this.focused=!0,this.$emit("focus",t),this.$nextTick(this.adjustSize),this.getProp("readonly")&&this.blur()},onBlur:function(t){this.getProp("readonly")||(this.focused=!1,this.updateValue(this.value,"onBlur"),this.$emit("blur",t),this.validateWithTrigger("onBlur"),this.$nextTick(this.adjustSize),l&&(0,s.kn)((0,s.oD)()))},onClick:function(t){this.$emit("click",t)},onClickInput:function(t){this.$emit("click-input",t)},onClickLeftIcon:function(t){this.$emit("click-left-icon",t)},onClickRightIcon:function(t){this.$emit("click-right-icon",t)},onClear:function(t){(0,u.PF)(t),this.$emit("input",""),this.$emit("clear",t)},onKeypress:function(t){13===t.keyCode&&(this.getProp("submitOnEnter")||"textarea"===this.type||(0,u.PF)(t),"search"===this.type&&this.blur());this.$emit("keypress",t)},adjustSize:function(){var t=this.$refs.input;if("textarea"===this.type&&this.autosize&&t){var e=(0,s.oD)();t.style.height="auto";var i=t.scrollHeight;if((0,a.Kn)(this.autosize)){var n=this.autosize,r=n.maxHeight,o=n.minHeight;r&&(i=Math.min(i,r)),o&&(i=Math.max(i,o))}i&&(t.style.height=i+"px",(0,s.kn)(e))}},genInput:function(){var t=this.$createElement,e=this.type,i=this.getProp("disabled"),n=this.getProp("readonly"),a=this.slots("input"),s=this.getProp("inputAlign");if(a)return t("div",{class:y("control",[s,"custom"]),on:{click:this.onClickInput}},[a]);var l={ref:"input",class:y("control",s),domProps:{value:this.value},attrs:(0,o.Z)({},this.$attrs,{name:this.name,disabled:i,readonly:n,placeholder:this.placeholder}),on:this.listeners,directives:[{name:"model",value:this.value}]};if("textarea"===e)return t("textarea",r()([{},l]));var c,u=e;return"number"===e&&(u="text",c="decimal"),"digit"===e&&(u="tel",c="numeric"),t("input",r()([{attrs:{type:u,inputmode:c}},l]))},genLeftIcon:function(){var t=this.$createElement;if(this.slots("left-icon")||this.leftIcon)return t("div",{class:y("left-icon"),on:{click:this.onClickLeftIcon}},[this.slots("left-icon")||t(d.Z,{attrs:{name:this.leftIcon,classPrefix:this.iconPrefix}})])},genRightIcon:function(){var t=this.$createElement,e=this.slots;if(e("right-icon")||this.rightIcon)return t("div",{class:y("right-icon"),on:{click:this.onClickRightIcon}},[e("right-icon")||t(d.Z,{attrs:{name:this.rightIcon,classPrefix:this.iconPrefix}})])},genWordLimit:function(){var t=this.$createElement;if(this.showWordLimit&&this.maxlength){var e=(this.value||"").length;return t("div",{class:y("word-limit")},[t("span",{class:y("word-num")},[e]),"/",this.maxlength])}},genMessage:function(){var t=this.$createElement;if(!this.vanForm||!1!==this.vanForm.showErrorMessage){var e=this.errorMessage||this.validateMessage;if(e){var i=this.getProp("errorMessageAlign");return t("div",{class:y("error-message",i)},[e])}}},getProp:function(t){return(0,a.Xq)(this[t])?this[t]:this.vanForm&&(0,a.Xq)(this.vanForm[t])?this.vanForm[t]:void 0},genLabel:function(){var t=this.$createElement,e=this.getProp("colon")?":":"";return this.slots("label")?[this.slots("label"),e]:this.label?t("span",[this.label+e]):void 0}},render:function(){var t,e=arguments[0],i=this.slots,n=this.getProp("disabled"),r=this.getProp("labelAlign"),o={icon:this.genLeftIcon},a=this.genLabel();a&&(o.title=function(){return a});var s=this.slots("extra");return s&&(o.extra=function(){return s}),e(v.Z,{attrs:{icon:this.leftIcon,size:this.size,center:this.center,border:this.border,isLink:this.isLink,required:this.required,clickable:this.clickable,titleStyle:this.labelStyle,valueClass:y("value"),titleClass:[y("label",r),this.labelClass],arrowDirection:this.arrowDirection},scopedSlots:o,class:y((t={error:this.showError,disabled:n},t["label-"+r]=r,t["min-height"]="textarea"===this.type&&!this.autosize,t)),on:{click:this.onClick}},[e("div",{class:y("body")},[this.genInput(),this.showClear&&e(d.Z,{attrs:{name:"clear"},class:y("clear"),on:{touchstart:this.onClear}}),this.genRightIcon(),i("button")&&e("div",{class:y("button")},[i("button")])]),this.genWordLimit(),this.genMessage()])}})},8735:(t,e,i)=>{i(6629),i(1383),i(2293),i(2391)},1392:(t,e,i)=>{i.d(e,{Z:()=>v});var n=i(6568),r=i.n(n),o=i(5976),a=i(216),s=i(6122),l=i(7937),c=(0,o.d)("icon"),u=c[0],h=c[1];var f={medel:"medal","medel-o":"medal-o","calender-o":"calendar-o"};function d(t,e,i,n){var o,c=function(t){return t&&f[t]||t}(e.name),u=function(t){return!!t&&-1!==t.indexOf("/")}(c);return t(e.tag,r()([{class:[e.classPrefix,u?"":e.classPrefix+"-"+c],style:{color:e.color,fontSize:(0,a.N)(e.size)}},(0,s.ED)(n,!0)]),[i.default&&i.default(),u&&t("img",{class:h("image"),attrs:{src:c}}),t(l.Z,{attrs:{dot:e.dot,info:null!=(o=e.badge)?o:e.info}})])}d.props={dot:Boolean,name:String,size:[Number,String],info:[Number,String],badge:[Number,String],color:String,tag:{type:String,default:"i"},classPrefix:{type:String,default:h()}};const v=u(d)},3307:(t,e,i)=>{i(6629),i(1383),i(2293)},2685:(t,e,i)=>{i.d(e,{Z:()=>Z});var n=i(9592),r=i(1895),o=i.n(r),a=i(5976),s=(0,a.d)("image-preview"),l=s[0],c=s[1],u=i(9339),h=i(4611),f=i(9045),d=i(1392),v=i(591),p=i(5566),m=i(2036),g=i(8169),y=i(9345),b=(0,a.d)("swipe"),w=b[0],S=b[1];const x=w({mixins:[h.D,(0,y.G)("vanSwipe"),(0,f.X)((function(t,e){t(window,"resize",this.resize,!0),t(window,"orientationchange",this.resize,!0),t(window,"visibilitychange",this.onVisibilityChange),e?this.initialize():this.clear()}))],props:{width:[Number,String],height:[Number,String],autoplay:[Number,String],vertical:Boolean,lazyRender:Boolean,indicatorColor:String,loop:{type:Boolean,default:!0},duration:{type:[Number,String],default:500},touchable:{type:Boolean,default:!0},initialSwipe:{type:[Number,String],default:0},showIndicators:{type:Boolean,default:!0},stopPropagation:{type:Boolean,default:!0}},data:function(){return{rect:null,offset:0,active:0,deltaX:0,deltaY:0,swiping:!1,computedWidth:0,computedHeight:0}},watch:{children:function(){this.initialize()},initialSwipe:function(){this.initialize()},autoplay:function(t){t>0?this.autoPlay():this.clear()}},computed:{count:function(){return this.children.length},maxCount:function(){return Math.ceil(Math.abs(this.minOffset)/this.size)},delta:function(){return this.vertical?this.deltaY:this.deltaX},size:function(){return this[this.vertical?"computedHeight":"computedWidth"]},trackSize:function(){return this.count*this.size},activeIndicator:function(){return(this.active+this.count)%this.count},isCorrectDirection:function(){var t=this.vertical?"vertical":"horizontal";return this.direction===t},trackStyle:function(){var t={transitionDuration:(this.swiping?0:this.duration)+"ms",transform:"translate"+(this.vertical?"Y":"X")+"("+this.offset+"px)"};if(this.size){var e=this.vertical?"height":"width",i=this.vertical?"width":"height";t[e]=this.trackSize+"px",t[i]=this[i]?this[i]+"px":""}return t},indicatorStyle:function(){return{backgroundColor:this.indicatorColor}},minOffset:function(){return(this.vertical?this.rect.height:this.rect.width)-this.size*this.count}},mounted:function(){this.bindTouchEvent(this.$refs.track)},methods:{initialize:function(t){if(void 0===t&&(t=+this.initialSwipe),this.$el&&!(0,v.x)(this.$el)){clearTimeout(this.timer);var e={width:this.$el.offsetWidth,height:this.$el.offsetHeight};this.rect=e,this.swiping=!0,this.active=t,this.computedWidth=+this.width||e.width,this.computedHeight=+this.height||e.height,this.offset=this.getTargetOffset(t),this.children.forEach((function(t){t.offset=0})),this.autoPlay()}},resize:function(){this.initialize(this.activeIndicator)},onVisibilityChange:function(){document.hidden?this.clear():this.autoPlay()},onTouchStart:function(t){this.touchable&&(this.clear(),this.touchStartTime=Date.now(),this.touchStart(t),this.correctPosition())},onTouchMove:function(t){this.touchable&&this.swiping&&(this.touchMove(t),this.isCorrectDirection&&((0,p.PF)(t,this.stopPropagation),this.move({offset:this.delta})))},onTouchEnd:function(){if(this.touchable&&this.swiping){var t=this.size,e=this.delta,i=e/(Date.now()-this.touchStartTime);if((Math.abs(i)>.25||Math.abs(e)>t/2)&&this.isCorrectDirection){var n=this.vertical?this.offsetY:this.offsetX,r=0;r=this.loop?n>0?e>0?-1:1:0:-Math[e>0?"ceil":"floor"](e/t),this.move({pace:r,emitChange:!0})}else e&&this.move({pace:0});this.swiping=!1,this.autoPlay()}},getTargetActive:function(t){var e=this.active,i=this.count,n=this.maxCount;return t?this.loop?(0,g.w6)(e+t,-1,i):(0,g.w6)(e+t,0,n):e},getTargetOffset:function(t,e){void 0===e&&(e=0);var i=t*this.size;this.loop||(i=Math.min(i,-this.minOffset));var n=e-i;return this.loop||(n=(0,g.w6)(n,this.minOffset,0)),n},move:function(t){var e=t.pace,i=void 0===e?0:e,n=t.offset,r=void 0===n?0:n,o=t.emitChange,a=this.loop,s=this.count,l=this.active,c=this.children,u=this.trackSize,h=this.minOffset;if(!(s<=1)){var f=this.getTargetActive(i),d=this.getTargetOffset(f,r);if(a){if(c[0]&&d!==h){var v=d<h;c[0].offset=v?u:0}if(c[s-1]&&0!==d){var p=d>0;c[s-1].offset=p?-u:0}}this.active=f,this.offset=d,o&&f!==l&&this.$emit("change",this.activeIndicator)}},prev:function(){var t=this;this.correctPosition(),this.resetTouchStatus(),(0,m.d1)((function(){t.swiping=!1,t.move({pace:-1,emitChange:!0})}))},next:function(){var t=this;this.correctPosition(),this.resetTouchStatus(),(0,m.d1)((function(){t.swiping=!1,t.move({pace:1,emitChange:!0})}))},swipeTo:function(t,e){var i=this;void 0===e&&(e={}),this.correctPosition(),this.resetTouchStatus(),(0,m.d1)((function(){var n;n=i.loop&&t===i.count?0===i.active?0:t:t%i.count,e.immediate?(0,m.d1)((function(){i.swiping=!1})):i.swiping=!1,i.move({pace:n-i.active,emitChange:!0})}))},correctPosition:function(){this.swiping=!0,this.active<=-1&&this.move({pace:this.count}),this.active>=this.count&&this.move({pace:-this.count})},clear:function(){clearTimeout(this.timer)},autoPlay:function(){var t=this,e=this.autoplay;e>0&&this.count>1&&(this.clear(),this.timer=setTimeout((function(){t.next(),t.autoPlay()}),e))},genIndicator:function(){var t=this,e=this.$createElement,i=this.count,n=this.activeIndicator,r=this.slots("indicator");return r||(this.showIndicators&&i>1?e("div",{class:S("indicators",{vertical:this.vertical})},[Array.apply(void 0,Array(i)).map((function(i,r){return e("i",{class:S("indicator",{active:r===n}),style:r===n?t.indicatorStyle:null})}))]):void 0)}},render:function(){var t=arguments[0];return t("div",{class:S()},[t("div",{ref:"track",style:this.trackStyle,class:S("track",{vertical:this.vertical})},[this.slots()]),this.genIndicator()])}});var k=i(4951),C=i(3432),$=(0,a.d)("swipe-item"),P=$[0],I=$[1];const O=P({mixins:[(0,y.j)("vanSwipe")],data:function(){return{offset:0,inited:!1,mounted:!1}},mounted:function(){var t=this;this.$nextTick((function(){t.mounted=!0}))},computed:{style:function(){var t={},e=this.parent,i=e.size,n=e.vertical;return i&&(t[n?"height":"width"]=i+"px"),this.offset&&(t.transform="translate"+(n?"Y":"X")+"("+this.offset+"px)"),t},shouldRender:function(){var t=this.index,e=this.inited,i=this.parent,n=this.mounted;if(!i.lazyRender||e)return!0;if(!n)return!1;var r=i.activeIndicator,o=i.count-1,a=0===r&&i.loop?o:r-1,s=r===o&&i.loop?0:r+1,l=t===r||t===a||t===s;return l&&(this.inited=!0),l}},render:function(){return(0,arguments[0])("div",{class:I(),style:this.style,on:(0,n.Z)({},this.$listeners)},[this.shouldRender&&this.slots()])}});function L(t){return Math.sqrt(Math.pow(t[0].clientX-t[1].clientX,2)+Math.pow(t[0].clientY-t[1].clientY,2))}const T={mixins:[h.D],props:{src:String,show:Boolean,active:Number,minZoom:[Number,String],maxZoom:[Number,String],rootWidth:Number,rootHeight:Number},data:function(){return{scale:1,moveX:0,moveY:0,moving:!1,zooming:!1,imageRatio:0,displayWidth:0,displayHeight:0}},computed:{vertical:function(){var t=this.rootWidth,e=this.rootHeight/t;return this.imageRatio>e},imageStyle:function(){var t=this.scale,e={transitionDuration:this.zooming||this.moving?"0s":".3s"};if(1!==t){var i=this.moveX/t,n=this.moveY/t;e.transform="scale("+t+", "+t+") translate("+i+"px, "+n+"px)"}return e},maxMoveX:function(){if(this.imageRatio){var t=this.vertical?this.rootHeight/this.imageRatio:this.rootWidth;return Math.max(0,(this.scale*t-this.rootWidth)/2)}return 0},maxMoveY:function(){if(this.imageRatio){var t=this.vertical?this.rootHeight:this.rootWidth*this.imageRatio;return Math.max(0,(this.scale*t-this.rootHeight)/2)}return 0}},watch:{active:"resetScale",show:function(t){t||this.resetScale()}},mounted:function(){this.bindTouchEvent(this.$el)},methods:{resetScale:function(){this.setScale(1),this.moveX=0,this.moveY=0},setScale:function(t){(t=(0,g.w6)(t,+this.minZoom,+this.maxZoom))!==this.scale&&(this.scale=t,this.$emit("scale",{scale:this.scale,index:this.active}))},toggleScale:function(){var t=this.scale>1?1:2;this.setScale(t),this.moveX=0,this.moveY=0},onTouchStart:function(t){var e=t.touches,i=this.offsetX,n=void 0===i?0:i;this.touchStart(t),this.touchStartTime=new Date,this.fingerNum=e.length,this.startMoveX=this.moveX,this.startMoveY=this.moveY,this.moving=1===this.fingerNum&&1!==this.scale,this.zooming=2===this.fingerNum&&!n,this.zooming&&(this.startScale=this.scale,this.startDistance=L(t.touches))},onTouchMove:function(t){var e=t.touches;if(this.touchMove(t),(this.moving||this.zooming)&&(0,p.PF)(t,!0),this.moving){var i=this.deltaX+this.startMoveX,n=this.deltaY+this.startMoveY;this.moveX=(0,g.w6)(i,-this.maxMoveX,this.maxMoveX),this.moveY=(0,g.w6)(n,-this.maxMoveY,this.maxMoveY)}if(this.zooming&&2===e.length){var r=L(e),o=this.startScale*r/this.startDistance;this.setScale(o)}},onTouchEnd:function(t){var e=!1;(this.moving||this.zooming)&&(e=!0,this.moving&&this.startMoveX===this.moveX&&this.startMoveY===this.moveY&&(e=!1),t.touches.length||(this.zooming&&(this.moveX=(0,g.w6)(this.moveX,-this.maxMoveX,this.maxMoveX),this.moveY=(0,g.w6)(this.moveY,-this.maxMoveY,this.maxMoveY),this.zooming=!1),this.moving=!1,this.startMoveX=0,this.startMoveY=0,this.startScale=1,this.scale<1&&this.resetScale())),(0,p.PF)(t,e),this.checkTap(),this.resetTouchStatus()},checkTap:function(){var t=this;if(!(this.fingerNum>1)){var e=this.offsetX,i=void 0===e?0:e,n=this.offsetY,r=void 0===n?0:n,o=new Date-this.touchStartTime;i<5&&r<5&&o<250&&(this.doubleTapTimer?(clearTimeout(this.doubleTapTimer),this.doubleTapTimer=null,this.toggleScale()):this.doubleTapTimer=setTimeout((function(){t.$emit("close"),t.doubleTapTimer=null}),250))}},onLoad:function(t){var e=t.target,i=e.naturalWidth,n=e.naturalHeight;this.imageRatio=n/i}},render:function(){var t=arguments[0],e={loading:function(){return t(C.Z,{attrs:{type:"spinner"}})}};return t(O,{class:c("swipe-item")},[t(k.Z,{attrs:{src:this.src,fit:"contain"},class:c("image",{vertical:this.vertical}),style:this.imageStyle,scopedSlots:e,on:{load:this.onLoad}})])}},E=l({mixins:[h.D,(0,u.e)({skipToggleEvent:!0}),(0,f.X)((function(t){t(window,"resize",this.resize,!0),t(window,"orientationchange",this.resize,!0)}))],props:{className:null,closeable:Boolean,asyncClose:Boolean,overlayStyle:Object,showIndicators:Boolean,images:{type:Array,default:function(){return[]}},loop:{type:Boolean,default:!0},overlay:{type:Boolean,default:!0},minZoom:{type:[Number,String],default:1/3},maxZoom:{type:[Number,String],default:3},transition:{type:String,default:"van-fade"},showIndex:{type:Boolean,default:!0},swipeDuration:{type:[Number,String],default:300},startPosition:{type:[Number,String],default:0},overlayClass:{type:String,default:c("overlay")},closeIcon:{type:String,default:"clear"},closeOnPopstate:{type:Boolean,default:!0},closeIconPosition:{type:String,default:"top-right"}},data:function(){return{active:0,rootWidth:0,rootHeight:0,doubleClickTimer:null}},mounted:function(){this.resize()},watch:{startPosition:"setActive",value:function(t){var e=this;t?(this.setActive(+this.startPosition),this.$nextTick((function(){e.resize(),e.$refs.swipe.swipeTo(+e.startPosition,{immediate:!0})}))):this.$emit("close",{index:this.active,url:this.images[this.active]})}},methods:{resize:function(){if(this.$el&&this.$el.getBoundingClientRect){var t=this.$el.getBoundingClientRect();this.rootWidth=t.width,this.rootHeight=t.height}},emitClose:function(){this.asyncClose||this.$emit("input",!1)},emitScale:function(t){this.$emit("scale",t)},setActive:function(t){t!==this.active&&(this.active=t,this.$emit("change",t))},genIndex:function(){var t=this.$createElement;if(this.showIndex)return t("div",{class:c("index")},[this.slots("index",{index:this.active})||this.active+1+" / "+this.images.length])},genCover:function(){var t=this.$createElement,e=this.slots("cover");if(e)return t("div",{class:c("cover")},[e])},genImages:function(){var t=this,e=this.$createElement;return e(x,{ref:"swipe",attrs:{lazyRender:!0,loop:this.loop,duration:this.swipeDuration,initialSwipe:this.startPosition,showIndicators:this.showIndicators,indicatorColor:"white"},class:c("swipe"),on:{change:this.setActive}},[this.images.map((function(i){return e(T,{attrs:{src:i,show:t.value,active:t.active,maxZoom:t.maxZoom,minZoom:t.minZoom,rootWidth:t.rootWidth,rootHeight:t.rootHeight},on:{scale:t.emitScale,close:t.emitClose}})}))])},genClose:function(){var t=this.$createElement;if(this.closeable)return t(d.Z,{attrs:{role:"button",name:this.closeIcon},class:c("close-icon",this.closeIconPosition),on:{click:this.emitClose}})},onClosed:function(){this.$emit("closed")},swipeTo:function(t,e){this.$refs.swipe&&this.$refs.swipe.swipeTo(t,e)}},render:function(){var t=arguments[0];return t("transition",{attrs:{name:this.transition},on:{afterLeave:this.onClosed}},[this.shouldRender?t("div",{directives:[{name:"show",value:this.value}],class:[c(),this.className]},[this.genClose(),this.genImages(),this.genIndex(),this.genCover()]):null])}});var z,j=i(8546),N={loop:!0,value:!0,images:[],maxZoom:3,minZoom:1/3,onClose:null,onChange:null,className:"",showIndex:!0,closeable:!1,closeIcon:"clear",asyncClose:!1,transition:"van-fade",getContainer:"body",overlayStyle:null,startPosition:0,swipeDuration:300,showIndicators:!1,closeOnPopstate:!0,closeIconPosition:"top-right"},A=function(){z=new(o().extend(E))({el:document.createElement("div")}),document.body.appendChild(z.$el),z.$on("change",(function(t){z.onChange&&z.onChange(t)})),z.$on("scale",(function(t){z.onScale&&z.onScale(t)}))},M=function(t,e){if(void 0===e&&(e=0),!j.sk){z||A();var i=Array.isArray(t)?{images:t,startPosition:e}:t;return(0,n.Z)(z,N,i),z.$once("input",(function(t){z.value=t})),z.$once("closed",(function(){z.images=[]})),i.onClose&&(z.$off("close"),z.$once("close",i.onClose)),z}};M.Component=E,M.install=function(){o().use(E)};const Z=M},4951:(t,e,i)=>{i.d(e,{Z:()=>f});var n=i(6568),r=i.n(n),o=i(5976),a=i(8546),s=i(216),l=i(1392),c=(0,o.d)("image"),u=c[0],h=c[1];const f=u({props:{src:String,fit:String,alt:String,round:Boolean,width:[Number,String],height:[Number,String],radius:[Number,String],lazyLoad:Boolean,iconPrefix:String,showError:{type:Boolean,default:!0},showLoading:{type:Boolean,default:!0},errorIcon:{type:String,default:"photo-fail"},loadingIcon:{type:String,default:"photo"}},data:function(){return{loading:!0,error:!1}},watch:{src:function(){this.loading=!0,this.error=!1}},computed:{style:function(){var t={};return(0,a.Xq)(this.width)&&(t.width=(0,s.N)(this.width)),(0,a.Xq)(this.height)&&(t.height=(0,s.N)(this.height)),(0,a.Xq)(this.radius)&&(t.overflow="hidden",t.borderRadius=(0,s.N)(this.radius)),t}},created:function(){var t=this.$Lazyload;t&&a._f&&(t.$on("loaded",this.onLazyLoaded),t.$on("error",this.onLazyLoadError))},beforeDestroy:function(){var t=this.$Lazyload;t&&(t.$off("loaded",this.onLazyLoaded),t.$off("error",this.onLazyLoadError))},methods:{onLoad:function(t){this.loading=!1,this.$emit("load",t)},onLazyLoaded:function(t){t.el===this.$refs.image&&this.loading&&this.onLoad()},onLazyLoadError:function(t){t.el!==this.$refs.image||this.error||this.onError()},onError:function(t){this.error=!0,this.loading=!1,this.$emit("error",t)},onClick:function(t){this.$emit("click",t)},genPlaceholder:function(){var t=this.$createElement;return this.loading&&this.showLoading?t("div",{class:h("loading")},[this.slots("loading")||t(l.Z,{attrs:{name:this.loadingIcon,classPrefix:this.iconPrefix},class:h("loading-icon")})]):this.error&&this.showError?t("div",{class:h("error")},[this.slots("error")||t(l.Z,{attrs:{name:this.errorIcon,classPrefix:this.iconPrefix},class:h("error-icon")})]):void 0},genImage:function(){var t=this.$createElement,e={class:h("img"),attrs:{alt:this.alt},style:{objectFit:this.fit}};if(!this.error)return this.lazyLoad?t("img",r()([{ref:"image",directives:[{name:"lazy",value:this.src}]},e])):t("img",r()([{attrs:{src:this.src},on:{load:this.onLoad,error:this.onError}},e]))}},render:function(){return(0,arguments[0])("div",{class:h({round:this.round}),style:this.style,on:{click:this.onClick}},[this.genImage(),this.genPlaceholder(),this.slots()])}})},7937:(t,e,i)=>{i.d(e,{Z:()=>f});var n=i(6568),r=i.n(n),o=i(5976),a=i(8546),s=i(6122),l=(0,o.d)("info"),c=l[0],u=l[1];function h(t,e,i,n){var o=e.dot,l=e.info,c=(0,a.Xq)(l)&&""!==l;if(o||c)return t("div",r()([{class:u({dot:o})},(0,s.ED)(n,!0)]),[o?"":e.info])}h.props={dot:Boolean,info:[Number,String]};const f=c(h)},3432:(t,e,i)=>{i.d(e,{Z:()=>v});var n=i(6568),r=i.n(n),o=i(5976),a=i(216),s=i(6122),l=(0,o.d)("loading"),c=l[0],u=l[1];function h(t,e){if("spinner"===e.type){for(var i=[],n=0;n<12;n++)i.push(t("i"));return i}return t("svg",{class:u("circular"),attrs:{viewBox:"25 25 50 50"}},[t("circle",{attrs:{cx:"50",cy:"50",r:"20",fill:"none"}})])}function f(t,e,i){if(i.default){var n,r={fontSize:(0,a.N)(e.textSize),color:null!=(n=e.textColor)?n:e.color};return t("span",{class:u("text"),style:r},[i.default()])}}function d(t,e,i,n){var o=e.color,l=e.size,c=e.type,d={color:o};if(l){var v=(0,a.N)(l);d.width=v,d.height=v}return t("div",r()([{class:u([c,{vertical:e.vertical}])},(0,s.ED)(n,!0)]),[t("span",{class:u("spinner",c),style:d},[h(t,e)]),f(t,e,i)])}d.props={color:String,size:[Number,String],vertical:Boolean,textSize:[Number,String],textColor:String,type:{type:String,default:"circular"}};const v=c(d)},9045:(t,e,i)=>{i.d(e,{X:()=>o});var n=i(5566),r=0;function o(t){var e="binded_"+r++;function i(){this[e]||(t.call(this,n.on,!0),this[e]=!0)}function o(){this[e]&&(t.call(this,n.S1,!1),this[e]=!1)}return{mounted:i,activated:i,deactivated:o,beforeDestroy:o}}},2098:(t,e,i)=>{i.d(e,{f:()=>n});var n={inject:{vanField:{default:null}},watch:{value:function(){var t=this.vanField;t&&(t.resetValidation(),t.validateWithTrigger("onChange"))}},created:function(){var t=this.vanField;t&&!t.children&&(t.children=this)}}},9339:(t,e,i)=>{i.d(e,{e:()=>I});var n={zIndex:2e3,lockCount:0,stack:[],find:function(t){return this.stack.filter((function(e){return e.vm===t}))[0]},remove:function(t){var e=this.find(t);if(e){e.vm=null,e.overlay=null;var i=this.stack.indexOf(e);this.stack.splice(i,1)}}},r=i(9592),o=i(6568),a=i.n(o),s=i(5976),l=i(8546),c=i(6122),u=i(5566),h=(0,s.d)("overlay"),f=h[0],d=h[1];function v(t){(0,u.PF)(t,!0)}function p(t,e,i,n){var o=(0,r.Z)({zIndex:e.zIndex},e.customStyle);return(0,l.Xq)(e.duration)&&(o.animationDuration=e.duration+"s"),t("transition",{attrs:{name:"van-fade"}},[t("div",a()([{directives:[{name:"show",value:e.show}],style:o,class:[d(),e.className],on:{touchmove:e.lockScroll?v:l.ZT}},(0,c.ED)(n,!0)]),[null==i.default?void 0:i.default()])])}p.props={show:Boolean,zIndex:[Number,String],duration:[Number,String],className:null,customStyle:Object,lockScroll:{type:Boolean,default:!0}};const m=f(p);var g=i(4042),y={className:"",customStyle:{}};function b(t){return(0,c.LI)(m,{on:{click:function(){t.$emit("click-overlay"),t.closeOnClickOverlay&&(t.onClickOverlay?t.onClickOverlay():t.close())}}})}function w(t){var e=n.find(t);if(e){var i=t.$el,o=e.config,a=e.overlay;i&&i.parentNode&&i.parentNode.insertBefore(a.$el,i),(0,r.Z)(a,y,o,{show:!0})}}function S(t){var e=n.find(t);e&&(e.overlay.show=!1)}var x=i(1750),k=i(4611);function C(t){var e=void 0===t?{}:t,i=e.ref,n=e.afterPortal;return{props:{getContainer:[String,Function]},watch:{getContainer:"portal"},mounted:function(){this.getContainer&&this.portal()},methods:{portal:function(){var t,e,r=this.getContainer,o=i?this.$refs[i]:this.$el;r?t="string"==typeof(e=r)?document.querySelector(e):e():this.$parent&&(t=this.$parent.$el),t&&t!==o.parentNode&&t.appendChild(o),n&&n.call(this)}}}}var $={mixins:[(0,i(9045).X)((function(t,e){this.handlePopstate(e&&this.closeOnPopstate)}))],props:{closeOnPopstate:Boolean},data:function(){return{bindStatus:!1}},watch:{closeOnPopstate:function(t){this.handlePopstate(t)}},methods:{onPopstate:function(){this.close(),this.shouldReopen=!1},handlePopstate:function(t){this.$isServer||this.bindStatus!==t&&(this.bindStatus=t,(t?u.on:u.S1)(window,"popstate",this.onPopstate))}}},P={transitionAppear:Boolean,value:Boolean,overlay:Boolean,overlayStyle:Object,overlayClass:String,closeOnClickOverlay:Boolean,zIndex:[Number,String],lockScroll:{type:Boolean,default:!0},lazyRender:{type:Boolean,default:!0}};function I(t){return void 0===t&&(t={}),{mixins:[k.D,$,C({afterPortal:function(){this.overlay&&w()}})],provide:function(){return{vanPopup:this}},props:P,data:function(){return this.onReopenCallback=[],{inited:this.value}},computed:{shouldRender:function(){return this.inited||!this.lazyRender}},watch:{value:function(e){var i=e?"open":"close";this.inited=this.inited||this.value,this[i](),t.skipToggleEvent||this.$emit(i)},overlay:"renderOverlay"},mounted:function(){this.value&&this.open()},activated:function(){this.shouldReopen&&(this.$emit("input",!0),this.shouldReopen=!1)},beforeDestroy:function(){var t,e;t=this,(e=n.find(t))&&((0,g.Z)(e.overlay.$el),n.remove(t)),this.opened&&this.removeLock(),this.getContainer&&(0,g.Z)(this.$el)},deactivated:function(){this.value&&(this.close(),this.shouldReopen=!0)},methods:{open:function(){this.$isServer||this.opened||(void 0!==this.zIndex&&(n.zIndex=this.zIndex),this.opened=!0,this.renderOverlay(),this.addLock(),this.onReopenCallback.forEach((function(t){t()})))},addLock:function(){this.lockScroll&&((0,u.on)(document,"touchstart",this.touchStart),(0,u.on)(document,"touchmove",this.onTouchMove),n.lockCount||document.body.classList.add("van-overflow-hidden"),n.lockCount++)},removeLock:function(){this.lockScroll&&n.lockCount&&(n.lockCount--,(0,u.S1)(document,"touchstart",this.touchStart),(0,u.S1)(document,"touchmove",this.onTouchMove),n.lockCount||document.body.classList.remove("van-overflow-hidden"))},close:function(){this.opened&&(S(this),this.opened=!1,this.removeLock(),this.$emit("input",!1))},onTouchMove:function(t){this.touchMove(t);var e=this.deltaY>0?"10":"01",i=(0,x.Ob)(t.target,this.$el),n=i.scrollHeight,r=i.offsetHeight,o=i.scrollTop,a="11";0===o?a=r>=n?"00":"01":o+r>=n&&(a="10"),"11"===a||"vertical"!==this.direction||parseInt(a,2)&parseInt(e,2)||(0,u.PF)(t,!0)},renderOverlay:function(){var t=this;!this.$isServer&&this.value&&this.$nextTick((function(){t.updateZIndex(t.overlay?1:0),t.overlay?function(t,e){var i=n.find(t);if(i)i.config=e;else{var r=b(t);n.stack.push({vm:t,config:e,overlay:r})}w(t)}(t,{zIndex:n.zIndex++,duration:t.duration,className:t.overlayClass,customStyle:t.overlayStyle}):S(t)}))},updateZIndex:function(t){void 0===t&&(t=0),this.$el.style.zIndex=++n.zIndex+t},onReopen:function(t){this.onReopenCallback.push(t)}}}}},9345:(t,e,i)=>{i.d(e,{G:()=>o,j:()=>r});var n=i(1150);function r(t,e){var i,r;void 0===e&&(e={});var o=e.indexKey||"index";return{inject:(i={},i[t]={default:null},i),computed:(r={parent:function(){return this.disableBindRelation?null:this[t]}},r[o]=function(){return this.bindRelation(),this.parent?this.parent.children.indexOf(this):null},r),watch:{disableBindRelation:function(t){t||this.bindRelation()}},mounted:function(){this.bindRelation()},beforeDestroy:function(){var t=this;this.parent&&(this.parent.children=this.parent.children.filter((function(e){return e!==t})))},methods:{bindRelation:function(){if(this.parent&&-1===this.parent.children.indexOf(this)){var t=[].concat(this.parent.children,[this]);(0,n.e)(t,this.parent),this.parent.children=t}}}}}function o(t){return{provide:function(){var e;return(e={})[t]=this,e},data:function(){return{children:[]}}}}},4611:(t,e,i)=>{i.d(e,{D:()=>r});var n=i(5566);var r={data:function(){return{direction:""}},methods:{touchStart:function(t){this.resetTouchStatus(),this.startX=t.touches[0].clientX,this.startY=t.touches[0].clientY},touchMove:function(t){var e=t.touches[0];this.deltaX=e.clientX<0?0:e.clientX-this.startX,this.deltaY=e.clientY-this.startY,this.offsetX=Math.abs(this.deltaX),this.offsetY=Math.abs(this.deltaY);var i,n;(!this.direction||this.offsetX<10&&this.offsetY<10)&&(this.direction=(i=this.offsetX,n=this.offsetY,i>n?"horizontal":n>i?"vertical":""))},resetTouchStatus:function(){this.direction="",this.deltaX=0,this.deltaY=0,this.offsetX=0,this.offsetY=0},bindTouchEvent:function(t){var e=this.onTouchStart,i=this.onTouchMove,r=this.onTouchEnd;(0,n.on)(t,"touchstart",e),(0,n.on)(t,"touchmove",i),r&&((0,n.on)(t,"touchend",r),(0,n.on)(t,"touchcancel",r))}}}},6689:(t,e,i)=>{i.d(e,{Z:()=>$});var n=i(9592),r=i(1895),o=i.n(r),a=i(5976),s=i(8546),l=0;var c=i(9339),u=i(1392),h=i(3432),f=(0,a.d)("toast"),d=f[0],v=f[1];const p=d({mixins:[(0,c.e)()],props:{icon:String,className:null,iconPrefix:String,loadingType:String,forbidClick:Boolean,closeOnClick:Boolean,message:[Number,String],type:{type:String,default:"text"},position:{type:String,default:"middle"},transition:{type:String,default:"van-fade"},lockScroll:{type:Boolean,default:!1}},data:function(){return{clickable:!1}},mounted:function(){this.toggleClickable()},destroyed:function(){this.toggleClickable()},watch:{value:"toggleClickable",forbidClick:"toggleClickable"},methods:{onClick:function(){this.closeOnClick&&this.close()},toggleClickable:function(){var t=this.value&&this.forbidClick;this.clickable!==t&&(this.clickable=t,t?(l||document.body.classList.add("van-toast--unclickable"),l++):--l||document.body.classList.remove("van-toast--unclickable"))},onAfterEnter:function(){this.$emit("opened"),this.onOpened&&this.onOpened()},onAfterLeave:function(){this.$emit("closed")},genIcon:function(){var t=this.$createElement,e=this.icon,i=this.type,n=this.iconPrefix,r=this.loadingType;return e||"success"===i||"fail"===i?t(u.Z,{class:v("icon"),attrs:{classPrefix:n,name:e||i}}):"loading"===i?t(h.Z,{class:v("loading"),attrs:{type:r}}):void 0},genMessage:function(){var t=this.$createElement,e=this.type,i=this.message;if((0,s.Xq)(i)&&""!==i)return"html"===e?t("div",{class:v("text"),domProps:{innerHTML:i}}):t("div",{class:v("text")},[i])}},render:function(){var t,e=arguments[0];return e("transition",{attrs:{name:this.transition},on:{afterEnter:this.onAfterEnter,afterLeave:this.onAfterLeave}},[e("div",{directives:[{name:"show",value:this.value}],class:[v([this.position,(t={},t[this.type]=!this.icon,t)]),this.className],on:{click:this.onClick}},[this.genIcon(),this.genMessage()])])}});var m=i(4042),g={icon:"",type:"text",mask:!1,value:!0,message:"",className:"",overlay:!1,onClose:null,onOpened:null,duration:2e3,iconPrefix:void 0,position:"middle",transition:"van-fade",forbidClick:!1,loadingType:void 0,getContainer:"body",overlayStyle:null,closeOnClick:!1,closeOnClickOverlay:!1},y={},b=[],w=!1,S=(0,n.Z)({},g);function x(t){return(0,s.Kn)(t)?t:{message:t}}function k(){if(s.sk)return{};if(!(b=b.filter((function(t){return!t.$el.parentNode||(e=t.$el,document.body.contains(e));var e}))).length||w){var t=new(o().extend(p))({el:document.createElement("div")});t.$on("input",(function(e){t.value=e})),b.push(t)}return b[b.length-1]}function C(t){void 0===t&&(t={});var e=k();return e.value&&e.updateZIndex(),t=x(t),(t=(0,n.Z)({},S,y[t.type||S.type],t)).clear=function(){e.value=!1,t.onClose&&(t.onClose(),t.onClose=null),w&&!s.sk&&e.$on("closed",(function(){clearTimeout(e.timer),b=b.filter((function(t){return t!==e})),(0,m.Z)(e.$el),e.$destroy()}))},(0,n.Z)(e,function(t){return(0,n.Z)({},t,{overlay:t.mask||t.overlay,mask:void 0,duration:void 0})}(t)),clearTimeout(e.timer),t.duration>0&&(e.timer=setTimeout((function(){e.clear()}),t.duration)),e}["loading","success","fail"].forEach((function(t){var e;C[t]=(e=t,function(t){return C((0,n.Z)({type:e},x(t)))})})),C.clear=function(t){b.length&&(t?(b.forEach((function(t){t.clear()})),b=[]):w?b.shift().clear():b[0].clear())},C.setDefaultOptions=function(t,e){"string"==typeof t?y[t]=e:(0,n.Z)(S,t)},C.resetDefaultOptions=function(t){"string"==typeof t?y[t]=null:(S=(0,n.Z)({},g),y={})},C.allowMultiple=function(t){void 0===t&&(t=!0),w=t},C.install=function(){o().use(p)},o().prototype.$toast=C;const $=C},2742:(t,e,i)=>{i(6629),i(6799),i(1383),i(2293),i(677),i(5388)},5976:(t,e,i)=>{function n(t,e){return e?"string"==typeof e?" "+t+"--"+e:Array.isArray(e)?e.reduce((function(e,i){return e+n(t,i)}),""):Object.keys(e).reduce((function(i,r){return i+(e[r]?n(t,r):"")}),""):""}function r(t){return function(e,i){return e&&"string"!=typeof e&&(i=e,e=""),""+(e=e?t+"__"+e:t)+n(e,i)}}i.d(e,{d:()=>b});var o=i(8546),a=i(4873),s={methods:{slots:function(t,e){void 0===t&&(t="default");var i=this.$slots,n=this.$scopedSlots[t];return n?n(e):i[t]}}},l=i(1895),c=i.n(l);function u(t){var e=this.name;t.component(e,this),t.component((0,a._)("-"+e),this)}function h(t){return{functional:!0,props:t.props,model:t.model,render:function(e,i){return t(e,i.props,function(t){var e=t.scopedSlots||t.data.scopedSlots||{},i=t.slots();return Object.keys(i).forEach((function(t){e[t]||(e[t]=function(){return i[t]})})),e}(i),i)}}}function f(t){return function(e){return(0,o.mf)(e)&&(e=h(e)),e.functional||(e.mixins=e.mixins||[],e.mixins.push(s)),e.name=t,e.install=u,e}}var d=Object.prototype.hasOwnProperty;function v(t,e){return Object.keys(e).forEach((function(i){!function(t,e,i){var n=e[i];(0,o.Xq)(n)&&(d.call(t,i)&&(0,o.Kn)(n)?t[i]=v(Object(t[i]),e[i]):t[i]=n)}(t,e,i)})),t}var p=c().prototype,m=c().util.defineReactive;m(p,"$vantLang","zh-CN"),m(p,"$vantMessages",{"zh-CN":{name:"姓名",tel:"电话",save:"保存",confirm:"确认",cancel:"取消",delete:"删除",complete:"完成",loading:"加载中...",telEmpty:"请填写电话",nameEmpty:"请填写姓名",nameInvalid:"请输入正确的姓名",confirmDelete:"确定要删除吗",telInvalid:"请输入正确的手机号",vanCalendar:{end:"结束",start:"开始",title:"日期选择",confirm:"确定",startEnd:"开始/结束",weekdays:["日","一","二","三","四","五","六"],monthTitle:function(t,e){return t+"年"+e+"月"},rangePrompt:function(t){return"选择天数不能超过 "+t+" 天"}},vanCascader:{select:"请选择"},vanContactCard:{addText:"添加联系人"},vanContactList:{addText:"新建联系人"},vanPagination:{prev:"上一页",next:"下一页"},vanPullRefresh:{pulling:"下拉即可刷新...",loosing:"释放即可刷新..."},vanSubmitBar:{label:"合计:"},vanCoupon:{unlimited:"无使用门槛",discount:function(t){return t+"折"},condition:function(t){return"满"+t+"元可用"}},vanCouponCell:{title:"优惠券",tips:"暂无可用",count:function(t){return t+"张可用"}},vanCouponList:{empty:"暂无优惠券",exchange:"兑换",close:"不使用优惠券",enable:"可用",disabled:"不可用",placeholder:"请输入优惠码"},vanAddressEdit:{area:"地区",postal:"邮政编码",areaEmpty:"请选择地区",addressEmpty:"请填写详细地址",postalEmpty:"邮政编码格式不正确",defaultAddress:"设为默认收货地址",telPlaceholder:"收货人手机号",namePlaceholder:"收货人姓名",areaPlaceholder:"选择省 / 市 / 区"},vanAddressEditDetail:{label:"详细地址",placeholder:"街道门牌、楼层房间号等信息"},vanAddressList:{add:"新增地址"}}});const g={messages:function(){return p.$vantMessages[p.$vantLang]},use:function(t,e){var i;p.$vantLang=t,this.add(((i={})[t]=e,i))},add:function(t){void 0===t&&(t={}),v(p.$vantMessages,t)}};function y(t){var e=(0,a._)(t)+".";return function(t){for(var i=g.messages(),n=(0,o.U2)(i,e+t)||(0,o.U2)(i,t),r=arguments.length,a=new Array(r>1?r-1:0),s=1;s<r;s++)a[s-1]=arguments[s];return(0,o.mf)(n)?n.apply(void 0,a):n}}function b(t){return[f(t="van-"+t),r(t),y(t)]}},5566:(t,e,i)=>{i.d(e,{PF:()=>l,S1:()=>s,on:()=>a});var n=i(8546),r=!1;if(!n.sk)try{var o={};Object.defineProperty(o,"passive",{get:function(){r=!0}}),window.addEventListener("test-passive",null,o)}catch(t){}function a(t,e,i,o){void 0===o&&(o=!1),n.sk||t.addEventListener(e,i,!!r&&{capture:!1,passive:o})}function s(t,e,i){n.sk||t.removeEventListener(e,i)}function l(t,e){("boolean"!=typeof t.cancelable||t.cancelable)&&t.preventDefault(),e&&function(t){t.stopPropagation()}(t)}},4042:(t,e,i)=>{function n(t){var e=t.parentNode;e&&e.removeChild(t)}i.d(e,{Z:()=>n})},2036:(t,e,i)=>{i.d(e,{d1:()=>l});var n=i(8546),r=Date.now();var o=n.sk?i.g:window,a=o.requestAnimationFrame||function(t){var e=Date.now(),i=Math.max(0,16-(e-r)),n=setTimeout(t,i);return r=e+i,n};o.cancelAnimationFrame||o.clearTimeout;function s(t){return a.call(o,t)}function l(t){s((function(){s(t)}))}},1750:(t,e,i)=>{i.d(e,{Ob:()=>r,kn:()=>s,oD:()=>a});var n=/scroll|auto|overlay/i;function r(t,e){void 0===e&&(e=window);for(var i=t;i&&"HTML"!==i.tagName&&"BODY"!==i.tagName&&1===i.nodeType&&i!==e;){var r=window.getComputedStyle(i).overflowY;if(n.test(r))return i;i=i.parentNode}return e}function o(t,e){"scrollTop"in t?t.scrollTop=e:t.scrollTo(t.scrollX,e)}function a(){return window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0}function s(t){o(window,t),o(document.body,t)}},591:(t,e,i)=>{function n(t){var e=window.getComputedStyle(t),i="none"===e.display,n=null===t.offsetParent&&"fixed"!==e.position;return i||n}i.d(e,{x:()=>n})},8169:(t,e,i)=>{function n(t,e,i){return Math.min(Math.max(t,e),i)}function r(t,e,i){var n=t.indexOf(e),r="";return-1===n?t:"-"===e&&0!==n?t.slice(0,n):("."===e&&t.match(/^(\.|-\.)/)&&(r=n?"-0":"0"),r+t.slice(0,n+1)+t.slice(n).replace(i,""))}function o(t,e,i){void 0===e&&(e=!0),void 0===i