index-3f432935.js 47 KB

12345
  1. <<<<<<<< HEAD:dist/assets/index-acb8d9e7.js
  2. import{aP as vt,am as se,m as ft,K as B,r as C,e as Q,l as ue,an as H,ay as je,cj as He,O as en,L as A,aV as pt,a as we,c7 as tn,d as q,f as S,ck as nn,ax as ht,by as an,Z as on,cl as ln,au as rn,x as sn,a4 as un,aj as cn,__tla as dn}from"./index-d75b4e4d.js";let gt,mt,vn=Promise.all([(()=>{try{return dn}catch{}})()]).then(async()=>{function bt(){}const ye=Object.assign,xe=typeof window<"u",Ce=e=>e!==null&&typeof e=="object",K=e=>e!=null,$e=e=>typeof e=="function",Pe=e=>typeof e=="number"||/^\d+(\.\d+)?$/.test(e);function Ne(e,t){const a=t.split(".");let o=e;return a.forEach(s=>{var n;o=Ce(o)&&(n=o[s])!=null?n:""}),o}function We(e,t,a){return t.reduce((o,s)=>(a&&e[s]===void 0||(o[s]=e[s]),o),{})}const M=[Number,String],j={type:Boolean,default:!0},ke=e=>({type:e,required:!0}),P=e=>({type:M,default:e}),ce=e=>({type:String,default:e});var ee=typeof window<"u";function ae(e){return ee?requestAnimationFrame(e):-1}function Fe(e){ee&&cancelAnimationFrame(e)}function oe(e){ae(()=>ae(e))}var Ze=(e,t)=>({top:0,left:0,right:e,bottom:t,width:e,height:t}),U=e=>{const t=we(e);if(t===window){const a=t.innerWidth,o=t.innerHeight;return Ze(a,o)}return t!=null&&t.getBoundingClientRect?t.getBoundingClientRect():Ze(0,0)};function _e(e){const t=vt(e,null);if(t){const a=se(),{link:o,unlink:s,internalChildren:n}=t;return o(a),ft(()=>s(a)),{parent:t,index:B(()=>n.indexOf(a))}}return{parent:null,index:C(-1)}}var de,Se,De=(e,t)=>{const a=e.indexOf(t);return a===-1?e.findIndex(o=>t.key!==void 0&&t.key!==null&&o.type===t.type&&o.key===t.key):a};function wt(e,t,a){const o=function(n){const u=[],l=i=>{Array.isArray(i)&&i.forEach(g=>{var d;tn(g)&&(u.push(g),(d=g.component)!=null&&d.subTree&&(u.push(g.component.subTree),l(g.component.subTree.children)),g.children&&l(g.children))})};return l(n),u}(e.subTree.children);a.sort((n,u)=>De(o,n.vnode)-De(o,u.vnode));const s=a.map(n=>n.proxy);t.sort((n,u)=>s.indexOf(n)-s.indexOf(u))}function Ve(e){const t=Q([]),a=Q([]),o=se();return{children:t,linkChildren:s=>{pt(e,Object.assign({link:n=>{n.proxy&&(a.push(n),t.push(n.proxy),wt(o,t,a))},unlink:n=>{const u=a.indexOf(n);t.splice(u,1),a.splice(u,1)},children:t,internalChildren:a},s))}}}function Te(e){let t;ue(()=>{e(),H(()=>{t=!0})}),je(()=>{t&&e()})}function Ie(e,t,a={}){if(!ee)return;const{target:o=window,passive:s=!1,capture:n=!1}=a;let u,l=!1;const i=v=>{if(l)return;const f=we(v);f&&!u&&(f.addEventListener(e,t,{capture:n,passive:s}),u=!0)},g=v=>{if(l)return;const f=we(v);f&&u&&(f.removeEventListener(e,t,n),u=!1)};let d;return ft(()=>g(o)),He(()=>g(o)),Te(()=>i(o)),en(o)&&(d=A(o,(v,f)=>{g(f),i(v)})),()=>{d==null||d(),g(o),l=!0}}var ve,yt=/scroll|auto|overlay/i,qe=ee?window:void 0;function xt(e){return e.tagName!=="HTML"&&e.tagName!=="BODY"&&e.nodeType===1}function Ke(e,t=qe){const a=C();return ue(()=>{e.value&&(a.value=function(o,s=qe){let n=o;for(;n&&n!==s&&xt(n);){const{overflowY:u}=window.getComputedStyle(n);if(yt.test(u))return n;n=n.parentNode}return s}(e.value,t))}),a}function Be(e){const t="scrollTop"in e?e.scrollTop:e.pageYOffset;return Math.max(t,0)}function ze(e,t){"scrollTop"in e?e.scrollTop=t:e.scrollTo(e.scrollX,t)}function Ue(e,t){if(e===window)return 0;const a=t?Be(t):window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0;return U(e).top+a}xe&&/ios|iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase());function le(e){const t=we(e);if(!t)return!1;const a=window.getComputedStyle(t),o=a.display==="none",s=t.offsetParent===null&&a.position!=="fixed";return o||s}const{width:fe,height:Oe}=function(){if(!de&&(de=C(0),Se=C(0),ee)){const e=()=>{de.value=window.innerWidth,Se.value=window.innerHeight};e(),window.addEventListener("resize",e,{passive:!0}),window.addEventListener("orientationchange",e,{passive:!0})}return{width:de,height:Se}}();function Z(e){if(K(e))return Pe(e)?`${e}px`:String(e)}let Re;function Ct(e){return+(e=e.replace(/rem/g,""))*function(){if(!Re){const t=document.documentElement,a=t.style.fontSize||window.getComputedStyle(t).fontSize;Re=parseFloat(a)}return Re}()}function Ge(e){if(typeof e=="number")return e;if(xe){if(e.includes("rem"))return Ct(e);if(e.includes("vw"))return function(t){return+(t=t.replace(/vw/g,""))*fe.value/100}(e);if(e.includes("vh"))return function(t){return+(t=t.replace(/vh/g,""))*Oe.value/100}(e)}return parseFloat(e)}const $t=/-(\w)/g,Je=e=>e.replace($t,(t,a)=>a.toUpperCase()),Ae=(e,t,a)=>Math.min(Math.max(e,t),a),{hasOwnProperty:kt}=Object.prototype;function Qe(e,t){return Object.keys(t).forEach(a=>{(function(o,s,n){const u=s[n];K(u)&&(kt.call(o,n)&&Ce(u)?o[n]=Qe(Object(o[n]),u):o[n]=u)})(e,t,a)}),e}const et=C("zh-CN"),tt=Q({"zh-CN":{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:(e,t)=>`${e}\u5E74${t}\u6708`,rangePrompt:e=>`\u6700\u591A\u9009\u62E9 ${e} \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:e=>`${e}\u6298`,condition:e=>`\u6EE1${e}\u5143\u53EF\u7528`},vanCouponCell:{title:"\u4F18\u60E0\u5238",count:e=>`${e}\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"}}});var St={messages:()=>tt[et.value],use(e,t){et.value=e,this.add({[e]:t})},add(e={}){Qe(tt,e)}};function Tt(e){const t=Je(e)+".";return(a,...o)=>{const s=St.messages(),n=Ne(s,t+a)||Ne(s,a);return $e(n)?n(...o):n}}function Ee(e,t){return t?typeof t=="string"?` ${e}--${t}`:Array.isArray(t)?t.reduce((a,o)=>a+Ee(e,o),""):Object.keys(t).reduce((a,o)=>a+(t[o]?Ee(e,o):""),""):""}function It(e){return(t,a)=>(t&&typeof t!="string"&&(a=t,t=""),`${t=t?`${e}__${t}`:e}${Ee(t,a)}`)}function _(e){const t=`van-${e}`;return[t,It(t),Tt(t)]}function Bt(e,{args:t=[],done:a,canceled:o,error:s}){if(e){const u=e.apply(null,t);Ce(n=u)&&$e(n.then)&&$e(n.catch)?u.then(l=>{l?a():o&&o()}).catch(s||bt):u?a():o&&o()}else a();var n}function te(e){return e.install=t=>{const{name:a}=e;a&&(t.component(a,e),t.component(Je(`-${a}`),e))},e}const zt=Symbol();function nt(e){const t=vt(zt,null);t&&A(t,a=>{a&&e()})}function ie(e){const t=se();t&&ye(t.proxy,e)}const Ot={to:[String,Object],url:String,replace:Boolean},[Rt,at]=_("badge"),At=te(q({name:Rt,props:{dot:Boolean,max:M,tag:ce("div"),color:String,offset:Array,content:M,showZero:j,position:ce("top-right")},setup(e,{slots:t}){const a=()=>{if(t.content)return!0;const{content:l,showZero:i}=e;return K(l)&&l!==""&&(i||l!==0&&l!=="0")},o=()=>{const{dot:l,max:i,content:g}=e;if(!l&&a())return t.content?t.content():K(i)&&Pe(g)&&+g>+i?`${i}+`:g},s=l=>l.startsWith("-")?l.replace("-",""):`-${l}`,n=B(()=>{const l={background:e.color};if(e.offset){const[i,g]=e.offset,{position:d}=e,[v,f]=d.split("-");t.default?(l[v]=typeof g=="number"?Z(v==="top"?g:-g):v==="top"?Z(g):s(g),l[f]=typeof i=="number"?Z(f==="left"?i:-i):f==="left"?Z(i):s(i)):(l.marginTop=Z(g),l.marginLeft=Z(i))}return l}),u=()=>{if(a()||e.dot)return S("div",{class:at([e.position,{dot:e.dot,fixed:!!t.default}]),style:n.value},[o()])};return()=>{if(t.default){const{tag:l}=e;return S(l,{class:at("wrapper")},{default:()=>[t.default(),u()]})}return u()}}}));let Et=0;function ot(){const e=se(),{name:t="unknown"}=(e==null?void 0:e.type)||{};return`${t}-${++Et}`}function lt(e,t){if(!xe||!window.IntersectionObserver)return;const a=new IntersectionObserver(s=>{t(s[0].intersectionRatio>0)},{root:document.body}),o=()=>{e.value&&a.unobserve(e.value)};He(o),ht(o),Te(()=>{e.value&&a.observe(e.value)})}const[Lt,Mt]=_("sticky");var Xt=q({name:Lt,props:{zIndex:M,position:ce("top"),container:Object,offsetTop:P(0),offsetBottom:P(0)},emits:["scroll","change"],setup(e,{emit:t,slots:a}){const o=C(),s=Ke(o),n=Q({fixed:!1,width:0,height:0,transform:0}),u=C(!1),l=B(()=>Ge(e.position==="top"?e.offsetTop:e.offsetBottom)),i=B(()=>{if(u.value)return;const{fixed:v,height:f,width:m}=n;return v?{width:`${m}px`,height:`${f}px`}:void 0}),g=B(()=>{if(!n.fixed||u.value)return;const v=ye(function(f){const m={};return f!==void 0&&(m.zIndex=+f),m}(e.zIndex),{width:`${n.width}px`,height:`${n.height}px`,[e.position]:`${l.value}px`});return n.transform&&(v.transform=`translate3d(0, ${n.transform}px, 0)`),v}),d=()=>{if(!o.value||le(o))return;const{container:v,position:f}=e,m=U(o),N=Be(window);if(n.width=m.width,n.height=m.height,f==="top")if(v){const R=U(v),w=R.bottom-l.value-n.height;n.fixed=l.value>m.top&&R.bottom>0,n.transform=w<0?w:0}else n.fixed=l.value>m.top;else{const{clientHeight:R}=document.documentElement;if(v){const w=U(v),W=R-w.top-l.value-n.height;n.fixed=R-l.value<m.bottom&&R>w.top,n.transform=W<0?-W:0}else n.fixed=R-l.value<m.bottom}(R=>{t("scroll",{scrollTop:R,isFixed:n.fixed})})(N)};return A(()=>n.fixed,v=>t("change",v)),Ie("scroll",d,{target:s,passive:!0}),lt(o,d),A([fe,Oe],()=>{o.value&&!le(o)&&n.fixed&&(u.value=!0,H(()=>{const v=U(o);n.width=v.width,n.height=v.height,u.value=!1}))}),()=>{var v;return S("div",{ref:o,style:i.value},[S("div",{class:Mt({fixed:n.fixed&&!u.value}),style:g.value},[(v=a.default)==null?void 0:v.call(a)])])}}});const Yt=te(Xt),[it,pe]=_("swipe"),jt={loop:j,width:M,height:M,vertical:Boolean,autoplay:P(0),duration:P(500),touchable:j,lazyRender:Boolean,initialSwipe:P(0),indicatorColor:String,showIndicators:j,stopPropagation:j},rt=Symbol(it);var Ht=q({name:it,props:jt,emits:["change","dragStart","dragEnd"],setup(e,{emit:t,slots:a}){const o=C(),s=C(),n=Q({rect:null,width:0,height:0,offset:0,active:0,swiping:!1});let u=!1;const l=function(){const h=C(0),$=C(0),x=C(0),r=C(0),c=C(0),p=C(0),b=C(""),y=C(!0),z=()=>{x.value=0,r.value=0,c.value=0,p.value=0,b.value="",y.value=!0};return{move:T=>{const k=T.touches[0];var O,X;x.value=(k.clientX<0?0:k.clientX)-h.value,r.value=k.clientY-$.value,c.value=Math.abs(x.value),p.value=Math.abs(r.value),(!b.value||c.value<10&&p.value<10)&&(b.value=(O=c.value)>(X=p.value)?"horizontal":X>O?"vertical":""),y.value&&(c.value>5||p.value>5)&&(y.value=!1)},start:T=>{z(),h.value=T.touches[0].clientX,$.value=T.touches[0].clientY},reset:z,startX:h,startY:$,deltaX:x,deltaY:r,offsetX:c,offsetY:p,direction:b,isVertical:()=>b.value==="vertical",isHorizontal:()=>b.value==="horizontal",isTap:y}}(),{children:i,linkChildren:g}=Ve(rt),d=B(()=>i.length),v=B(()=>n[e.vertical?"height":"width"]),f=B(()=>e.vertical?l.deltaY.value:l.deltaX.value),m=B(()=>n.rect?(e.vertical?n.rect.height:n.rect.width)-v.value*d.value:0),N=B(()=>v.value?Math.ceil(Math.abs(m.value)/v.value):d.value),R=B(()=>d.value*v.value),w=B(()=>(n.active+d.value)%d.value),W=B(()=>{const h=e.vertical?"vertical":"horizontal";return l.direction.value===h}),I=B(()=>{const h={transitionDuration:`${n.swiping?0:e.duration}ms`,transform:`translate${e.vertical?"Y":"X"}(${+n.offset.toFixed(2)}px)`};if(v.value){const $=e.vertical?"height":"width",x=e.vertical?"width":"height";h[$]=`${R.value}px`,h[x]=e[x]?`${e[x]}px`:""}return h}),D=(h,$=0)=>{let x=h*v.value;e.loop||(x=Math.min(x,-m.value));let r=$-x;return e.loop||(r=Ae(r,m.value,0)),r},L=({pace:h=0,offset:$=0,emitChange:x})=>{if(d.value<=1)return;const{active:r}=n,c=(b=>{const{active:y}=n;return b?e.loop?Ae(y+b,-1,d.value):Ae(y+b,0,N.value):y})(h),p=D(c,$);if(e.loop){if(i[0]&&p!==m.value){const b=p<m.value;i[0].setOffset(b?R.value:0)}if(i[d.value-1]&&p!==0){const b=p>0;i[d.value-1].setOffset(b?-R.value:0)}}n.active=c,n.offset=p,x&&c!==r&&t("change",w.value)},F=()=>{n.swiping=!0,n.active<=-1?L({pace:d.value}):n.active>=d.value&&L({pace:-d.value})},re=()=>{F(),l.reset(),oe(()=>{n.swiping=!1,L({pace:1,emitChange:!0})})};let ne;const V=()=>clearTimeout(ne),Y=()=>{V(),+e.autoplay>0&&d.value>1&&(ne=setTimeout(()=>{re(),Y()},+e.autoplay))},E=(h=+e.initialSwipe)=>{if(!o.value)return;const $=()=>{var x,r;if(!le(o)){const c={width:o.value.offsetWidth,height:o.value.offsetHeight};n.rect=c,n.width=+((x=e.width)!=null?x:c.width),n.height=+((r=e.height)!=null?r:c.height)}d.value&&(h=Math.min(d.value-1,h))===-1&&(h=d.value-1),n.active=h,n.swiping=!0,n.offset=D(h),i.forEach(c=>{c.setOffset(0)}),Y()};le(o)?H().then($):$()},G=()=>E(n.active);let J;const ge=h=>{!e.touchable||h.touches.length>1||(l.start(h),u=!1,J=Date.now(),V(),F())},me=()=>{if(!e.touchable||!n.swiping)return;const h=Date.now()-J,$=f.value/h;if((Math.abs($)>.25||Math.abs(f.value)>v.value/2)&&W.value){const x=e.vertical?l.offsetY.value:l.offsetX.value;let r=0;r=e.loop?x>0?f.value>0?-1:1:0:-Math[f.value>0?"ceil":"floor"](f.value/v.value),L({pace:r,emitChange:!0})}else f.value&&L({pace:0});u=!1,n.swiping=!1,t("dragEnd",{index:w.value}),Y()},Me=(h,$)=>{const x=$===w.value,r=x?{backgroundColor:e.indicatorColor}:void 0;return S("i",{style:r,class:pe("indicator",{active:x})},null)};return ie({prev:()=>{F(),l.reset(),oe(()=>{n.swiping=!1,L({pace:-1,emitChange:!0})})},next:re,state:n,resize:G,swipeTo:(h,$={})=>{F(),l.reset(),oe(()=>{let x;x=e.loop&&h===d.value?n.active===0?0:h:h%d.value,$.immediate?oe(()=>{n.swiping=!1}):n.swiping=!1,L({pace:x-n.active,emitChange:!0})})}}),g({size:v,props:e,count:d,activeIndicator:w}),A(()=>e.initialSwipe,h=>E(+h)),A(d,()=>E(n.active)),A(()=>e.autoplay,Y),A([fe,Oe,()=>e.width,()=>e.height],G),A(function(){if(!ve&&(ve=C("visible"),ee)){const h=()=>{ve.value=document.hidden?"hidden":"visible"};h(),window.addEventListener("visibilitychange",h)}return ve}(),h=>{h==="visible"?Y():V()}),ue(E),je(()=>E(n.active)),nt(()=>E(n.active)),He(V),ht(V),Ie("touchmove",h=>{e.touchable&&n.swiping&&(l.move(h),W.value)&&(!e.loop&&(n.active===0&&f.value>0||n.active===d.value-1&&f.value<0)||(function($,x){(typeof $.cancelable!="boolean"||$.cancelable)&&$.preventDefault(),x&&(r=>{r.stopPropagation()})($)}(h,e.stopPropagation),L({offset:f.value}),u||(t("dragStart",{index:w.value}),u=!0)))},{target:s}),()=>{var h;return S("div",{ref:o,class:pe()},[S("div",{ref:s,style:I.value,class:pe("track",{vertical:e.vertical}),onTouchstartPassive:ge,onTouchend:me,onTouchcancel:me},[(h=a.default)==null?void 0:h.call(a)]),a.indicator?a.indicator({active:w.value,total:d.value}):e.showIndicators&&d.value>1?S("div",{class:pe("indicators",{vertical:e.vertical})},[Array(d.value).fill("").map(Me)]):void 0])}}});const Pt=te(Ht),[Nt,st]=_("tabs");var Wt=q({name:Nt,props:{count:ke(Number),inited:Boolean,animated:Boolean,duration:ke(M),swipeable:Boolean,lazyRender:Boolean,currentIndex:ke(Number)},emits:["change"],setup(e,{emit:t,slots:a}){const o=C(),s=l=>t("change",l),n=()=>{var l;const i=(l=a.default)==null?void 0:l.call(a);return e.animated||e.swipeable?S(Pt,{ref:o,loop:!1,class:st("track"),duration:1e3*+e.duration,touchable:e.swipeable,lazyRender:e.lazyRender,showIndicators:!1,onChange:s},{default:()=>[i]}):i},u=l=>{const i=o.value;i&&i.state.active!==l&&i.swipeTo(l,{immediate:!e.inited})};return A(()=>e.currentIndex,u),ue(()=>{u(e.currentIndex)}),ie({swipeRef:o}),()=>S("div",{class:st("content",{animated:e.animated||e.swipeable})},[n()])}});const[ut,he]=_("tabs"),Ft={type:ce("line"),color:String,border:Boolean,sticky:Boolean,shrink:Boolean,active:P(0),duration:P(.3),animated:Boolean,ellipsis:j,swipeable:Boolean,scrollspy:Boolean,offsetTop:P(0),background:String,lazyRender:j,showHeader:j,lineWidth:M,lineHeight:M,beforeChange:Function,swipeThreshold:P(5),titleActiveColor:String,titleInactiveColor:String},ct=Symbol(ut);var Zt=q({name:ut,props:Ft,emits:["change","scroll","rendered","clickTab","update:active"],setup(e,{emit:t,slots:a}){let o,s,n,u,l;const i=C(),g=C(),d=C(),v=C(),f=ot(),m=Ke(i),[N,R]=function(){const r=C([]),c=[];return nn(()=>{r.value=[]}),[r,p=>(c[p]||(c[p]=b=>{r.value[p]=b}),c[p])]}(),{children:w,linkChildren:W}=Ve(ct),I=Q({inited:!1,position:"",lineStyle:{},currentIndex:-1}),D=B(()=>w.length>+e.swipeThreshold||!e.ellipsis||e.shrink),L=B(()=>({borderColor:e.color,background:e.background})),F=(r,c)=>{var p;return(p=r.name)!=null?p:c},re=B(()=>{const r=w[I.currentIndex];if(r)return F(r,I.currentIndex)}),ne=B(()=>Ge(e.offsetTop)),V=B(()=>e.sticky?ne.value+o:0),Y=r=>{const c=g.value,p=N.value;if(!(D.value&&c&&p&&p[I.currentIndex]))return;const b=p[I.currentIndex].$el,y=b.offsetLeft-(c.offsetWidth-b.offsetWidth)/2;u&&u(),u=function(z,T,k){let O,X=0;const Xe=z.scrollLeft,be=k===0?1:Math.round(1e3*k/16);return function Ye(){z.scrollLeft+=(T-Xe)/be,++X<be&&(O=ae(Ye))}(),function(){Fe(O)}}(c,y,r?0:+e.duration)},E=()=>{const r=I.inited;H(()=>{const c=N.value;if(!c||!c[I.currentIndex]||e.type!=="line"||le(i.value))return;const p=c[I.currentIndex].$el,{lineWidth:b,lineHeight:y}=e,z=p.offsetLeft+p.offsetWidth/2,T={width:Z(b),backgroundColor:e.color,transform:`translateX(${z}px) translateX(-50%)`};if(r&&(T.transitionDuration=`${e.duration}s`),K(y)){const k=Z(y);T.height=k,T.borderRadius=k}I.lineStyle=T})},G=(r,c)=>{const p=(k=>{const O=k<I.currentIndex?-1:1;for(;k>=0&&k<w.length;){if(!w[k].disabled)return k;k+=O}})(r);if(!K(p))return;const b=w[p],y=F(b,p),z=I.currentIndex!==null;var T;I.currentIndex!==p&&(I.currentIndex=p,c||Y(),E()),y!==e.active&&(t("update:active",y),z&&t("change",y,b.title)),n&&!e.scrollspy&&(T=Math.ceil(Ue(i.value)-ne.value),ze(window,T),ze(document.body,T))},J=(r,c)=>{const p=w.find((y,z)=>F(y,z)===r),b=p?w.indexOf(p):0;G(b,c)},ge=(r=!1)=>{if(e.scrollspy){const c=w[I.currentIndex].$el;if(c&&m.value){const p=Ue(c,m.value)-V.value;s=!0,l&&l(),l=function(b,y,z,T){let k,O=Be(b);const X=O<y,Xe=z===0?1:Math.round(1e3*z/16),be=(y-O)/Xe;return function Ye(){O+=be,(X&&O>y||!X&&O<y)&&(O=y),ze(b,O),X&&O<y||!X&&O>y?k=ae(Ye):T&&(k=ae(T))}(),function(){Fe(k)}}(m.value,p,r?0:+e.duration,()=>{s=!1})}}},me=(r,c,p)=>{const{title:b,disabled:y}=w[c],z=F(w[c],c);y||(Bt(e.beforeChange,{args:[z],done:()=>{G(c),ge()}}),function({to:T,url:k,replace:O,$router:X}){T&&X?X[O?"replace":"push"](T):k&&(O?location.replace(k):location.href=k)}(r)),t("clickTab",{name:z,title:b,event:p,disabled:y})},Me=r=>{n=r.isFixed,t("scroll",r)},h=()=>{if(e.type==="line"&&w.length)return S("div",{class:he("line"),style:I.lineStyle},null)},$=()=>{var r,c,p;const{type:b,border:y,sticky:z}=e,T=[S("div",{ref:z?void 0:d,class:[he("wrap"),{"van-hairline--top-bottom":b==="line"&&y}]},[S("div",{ref:g,role:"tablist",class:he("nav",[b,{shrink:e.shrink,complete:D.value}]),style:L.value,"aria-orientation":"horizontal"},[(r=a["nav-left"])==null?void 0:r.call(a),w.map(k=>k.renderTitle(me)),h(),(c=a["nav-right"])==null?void 0:c.call(a)])]),(p=a["nav-bottom"])==null?void 0:p.call(a)];return z?S("div",{ref:d},[T]):T},x=()=>{E(),H(()=>{var r,c;Y(!0),(c=(r=v.value)==null?void 0:r.swipeRef.value)==null||c.resize()})};return A(()=>[e.color,e.duration,e.lineWidth,e.lineHeight],E),A(fe,x),A(()=>e.active,r=>{r!==re.value&&J(r)}),A(()=>w.length,()=>{I.inited&&(J(e.active),E(),H(()=>{Y(!0)}))}),ie({resize:x,scrollTo:r=>{H(()=>{J(r),ge(!0)})}}),je(E),nt(E),Te(()=>{J(e.active,!0),H(()=>{I.inited=!0,d.value&&(o=U(d.value).height),Y(!0)})}),lt(i,E),Ie("scroll",()=>{if(e.scrollspy&&!s){const r=(()=>{for(let c=0;c<w.length;c++){const{top:p}=U(w[c].$el);if(p>V.value)return c===0?0:c-1}return w.length-1})();G(r)}},{target:m,passive:!0}),W({id:f,props:e,setLine:E,scrollable:D,onRendered:(r,c)=>t("rendered",r,c),currentName:re,setTitleRefs:R,scrollIntoView:Y}),()=>S("div",{ref:i,class:he([e.type])},[e.showHeader?e.sticky?S(Yt,{container:i.value,offsetTop:ne.value,onScroll:Me},{default:()=>[$()]}):$():null,S(Wt,{ref:v,count:w.length,inited:I.inited,animated:e.animated,duration:e.duration,swipeable:e.swipeable,lazyRender:e.lazyRender,currentIndex:I.currentIndex,onChange:G},{default:()=>{var r;return[(r=a.default)==null?void 0:r.call(a)]}})])}});const _t=Symbol(),[Dt,dt]=_("tab"),Vt=q({name:Dt,props:{id:String,dot:Boolean,type:String,color:String,title:String,badge:M,shrink:Boolean,isActive:Boolean,disabled:Boolean,controls:String,scrollable:Boolean,activeColor:String,inactiveColor:String,showZeroBadge:j},setup(e,{slots:t}){const a=B(()=>{const s={},{type:n,color:u,disabled:l,isActive:i,activeColor:g,inactiveColor:d}=e;u&&n==="card"&&(s.borderColor=u,l||(i?s.backgroundColor=u:s.color=u));const v=i?g:d;return v&&(s.color=v),s}),o=()=>{const s=S("span",{class:dt("text",{ellipsis:!e.scrollable})},[t.title?t.title():e.title]);return e.dot||K(e.badge)&&e.badge!==""?S(At,{dot:e.dot,content:e.badge,showZero:e.showZeroBadge},{default:()=>[s]}):s};return()=>S("div",{id:e.id,role:"tab",class:[dt([e.type,{grow:e.scrollable&&!e.shrink,shrink:e.shrink,active:e.isActive,disabled:e.disabled}])],style:a.value,tabindex:e.disabled?void 0:e.isActive?0:-1,"aria-selected":e.isActive,"aria-disabled":e.disabled||void 0,"aria-controls":e.controls},[o()])}}),[qt,Kt]=_("swipe-item");var Ut=q({name:qt,setup(e,{slots:t}){let a;const o=Q({offset:0,inited:!1,mounted:!1}),{parent:s,index:n}=_e(rt);if(!s)return void console.error("[Vant] <SwipeItem> must be a child component of <Swipe>.");const u=B(()=>{const i={},{vertical:g}=s.props;return s.size.value&&(i[g?"height":"width"]=`${s.size.value}px`),o.offset&&(i.transform=`translate${g?"Y":"X"}(${o.offset}px)`),i}),l=B(()=>{const{loop:i,lazyRender:g}=s.props;if(!g||a)return!0;if(!o.mounted)return!1;const d=s.activeIndicator.value,v=s.count.value-1,f=d===0&&i?v:d-1,m=d===v&&i?0:d+1;return a=n.value===d||n.value===f||n.value===m,a});return ue(()=>{H(()=>{o.mounted=!0})}),ie({setOffset:i=>{o.offset=i}}),()=>{var i;return S("div",{class:Kt(),style:u.value},[l.value?(i=t.default)==null?void 0:i.call(t):null])}}});const Gt=te(Ut),[Jt,Le]=_("tab");var Qt=q({name:Jt,props:ye({},Ot,{dot:Boolean,name:M,badge:M,title:String,disabled:Boolean,titleClass:null,titleStyle:[String,Object],showZeroBadge:j}),setup(e,{slots:t}){const a=ot(),o=C(!1),s=se(),{parent:n,index:u}=_e(ct);if(!n)return void console.error("[Vant] <Tab> must be a child component of <Tabs>.");const l=()=>{var f;return(f=e.name)!=null?f:u.value},i=B(()=>{const f=l()===n.currentName.value;return f&&!o.value&&(o.value=!0,n.props.lazyRender&&H(()=>{n.onRendered(l(),e.title)})),f}),g=C(""),d=C("");an(()=>{const{titleClass:f,titleStyle:m}=e;g.value=f?on(f):"",d.value=m&&typeof m!="string"?ln(rn(m)):m});const v=C(!i.value);return A(i,f=>{f?v.value=!1:oe(()=>{v.value=!0})}),A(()=>e.title,()=>{n.setLine(),n.scrollIntoView()}),pt(_t,i),ie({id:a,renderTitle:f=>S(Vt,cn({key:a,id:`${n.id}-${u.value}`,ref:n.setTitleRefs(u.value),style:d.value,class:g.value,isActive:i.value,controls:a,scrollable:n.scrollable.value,activeColor:n.props.titleActiveColor,inactiveColor:n.props.titleInactiveColor,onClick:m=>f(s.proxy,u.value,m)},We(n.props,["type","color","shrink"]),We(e,["dot","badge","title","disabled","showZeroBadge"])),{title:t.title})}),()=>{var f;const m=`${n.id}-${u.value}`,{animated:N,swipeable:R,scrollspy:w,lazyRender:W}=n.props;if(!t.default&&!N)return;const I=w||i.value;if(N||R)return S(Gt,{id:a,role:"tabpanel",class:Le("panel-wrapper",{inactive:v.value}),tabindex:i.value?0:-1,"aria-hidden":!i.value,"aria-labelledby":m},{default:()=>{var L;return[S("div",{class:Le("panel")},[(L=t.default)==null?void 0:L.call(t)])]}});const D=o.value||w||!W?(f=t.default)==null?void 0:f.call(t):null;return sn(S("div",{id:a,role:"tabpanel",class:Le("panel"),tabindex:I?0:-1,"aria-labelledby":m},[D]),[[un,I]])}}});gt=te(Qt),mt=te(Zt)});export{gt as T,vn as __tla,mt as a};
  3. ========
  4. import{aP as vt,am as se,m as ft,K as B,r as C,e as Q,l as ue,an as H,ay as je,cj as He,O as en,L as A,aV as pt,a as we,c7 as tn,d as q,f as S,ck as nn,ax as ht,by as an,Z as on,cl as ln,au as rn,x as sn,a4 as un,aj as cn,__tla as dn}from"./index-c9fff140.js";let gt,mt,vn=Promise.all([(()=>{try{return dn}catch{}})()]).then(async()=>{function bt(){}const ye=Object.assign,xe=typeof window<"u",Ce=e=>e!==null&&typeof e=="object",K=e=>e!=null,$e=e=>typeof e=="function",Pe=e=>typeof e=="number"||/^\d+(\.\d+)?$/.test(e);function Ne(e,t){const a=t.split(".");let o=e;return a.forEach(s=>{var n;o=Ce(o)&&(n=o[s])!=null?n:""}),o}function We(e,t,a){return t.reduce((o,s)=>(a&&e[s]===void 0||(o[s]=e[s]),o),{})}const M=[Number,String],j={type:Boolean,default:!0},ke=e=>({type:e,required:!0}),P=e=>({type:M,default:e}),ce=e=>({type:String,default:e});var ee=typeof window<"u";function ae(e){return ee?requestAnimationFrame(e):-1}function Fe(e){ee&&cancelAnimationFrame(e)}function oe(e){ae(()=>ae(e))}var Ze=(e,t)=>({top:0,left:0,right:e,bottom:t,width:e,height:t}),U=e=>{const t=we(e);if(t===window){const a=t.innerWidth,o=t.innerHeight;return Ze(a,o)}return t!=null&&t.getBoundingClientRect?t.getBoundingClientRect():Ze(0,0)};function _e(e){const t=vt(e,null);if(t){const a=se(),{link:o,unlink:s,internalChildren:n}=t;return o(a),ft(()=>s(a)),{parent:t,index:B(()=>n.indexOf(a))}}return{parent:null,index:C(-1)}}var de,Se,De=(e,t)=>{const a=e.indexOf(t);return a===-1?e.findIndex(o=>t.key!==void 0&&t.key!==null&&o.type===t.type&&o.key===t.key):a};function wt(e,t,a){const o=function(n){const u=[],l=i=>{Array.isArray(i)&&i.forEach(g=>{var d;tn(g)&&(u.push(g),(d=g.component)!=null&&d.subTree&&(u.push(g.component.subTree),l(g.component.subTree.children)),g.children&&l(g.children))})};return l(n),u}(e.subTree.children);a.sort((n,u)=>De(o,n.vnode)-De(o,u.vnode));const s=a.map(n=>n.proxy);t.sort((n,u)=>s.indexOf(n)-s.indexOf(u))}function Ve(e){const t=Q([]),a=Q([]),o=se();return{children:t,linkChildren:s=>{pt(e,Object.assign({link:n=>{n.proxy&&(a.push(n),t.push(n.proxy),wt(o,t,a))},unlink:n=>{const u=a.indexOf(n);t.splice(u,1),a.splice(u,1)},children:t,internalChildren:a},s))}}}function Te(e){let t;ue(()=>{e(),H(()=>{t=!0})}),je(()=>{t&&e()})}function Ie(e,t,a={}){if(!ee)return;const{target:o=window,passive:s=!1,capture:n=!1}=a;let u,l=!1;const i=v=>{if(l)return;const f=we(v);f&&!u&&(f.addEventListener(e,t,{capture:n,passive:s}),u=!0)},g=v=>{if(l)return;const f=we(v);f&&u&&(f.removeEventListener(e,t,n),u=!1)};let d;return ft(()=>g(o)),He(()=>g(o)),Te(()=>i(o)),en(o)&&(d=A(o,(v,f)=>{g(f),i(v)})),()=>{d==null||d(),g(o),l=!0}}var ve,yt=/scroll|auto|overlay/i,qe=ee?window:void 0;function xt(e){return e.tagName!=="HTML"&&e.tagName!=="BODY"&&e.nodeType===1}function Ke(e,t=qe){const a=C();return ue(()=>{e.value&&(a.value=function(o,s=qe){let n=o;for(;n&&n!==s&&xt(n);){const{overflowY:u}=window.getComputedStyle(n);if(yt.test(u))return n;n=n.parentNode}return s}(e.value,t))}),a}function Be(e){const t="scrollTop"in e?e.scrollTop:e.pageYOffset;return Math.max(t,0)}function ze(e,t){"scrollTop"in e?e.scrollTop=t:e.scrollTo(e.scrollX,t)}function Ue(e,t){if(e===window)return 0;const a=t?Be(t):window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0;return U(e).top+a}xe&&/ios|iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase());function le(e){const t=we(e);if(!t)return!1;const a=window.getComputedStyle(t),o=a.display==="none",s=t.offsetParent===null&&a.position!=="fixed";return o||s}const{width:fe,height:Oe}=function(){if(!de&&(de=C(0),Se=C(0),ee)){const e=()=>{de.value=window.innerWidth,Se.value=window.innerHeight};e(),window.addEventListener("resize",e,{passive:!0}),window.addEventListener("orientationchange",e,{passive:!0})}return{width:de,height:Se}}();function Z(e){if(K(e))return Pe(e)?`${e}px`:String(e)}let Re;function Ct(e){return+(e=e.replace(/rem/g,""))*function(){if(!Re){const t=document.documentElement,a=t.style.fontSize||window.getComputedStyle(t).fontSize;Re=parseFloat(a)}return Re}()}function Ge(e){if(typeof e=="number")return e;if(xe){if(e.includes("rem"))return Ct(e);if(e.includes("vw"))return function(t){return+(t=t.replace(/vw/g,""))*fe.value/100}(e);if(e.includes("vh"))return function(t){return+(t=t.replace(/vh/g,""))*Oe.value/100}(e)}return parseFloat(e)}const $t=/-(\w)/g,Je=e=>e.replace($t,(t,a)=>a.toUpperCase()),Ae=(e,t,a)=>Math.min(Math.max(e,t),a),{hasOwnProperty:kt}=Object.prototype;function Qe(e,t){return Object.keys(t).forEach(a=>{(function(o,s,n){const u=s[n];K(u)&&(kt.call(o,n)&&Ce(u)?o[n]=Qe(Object(o[n]),u):o[n]=u)})(e,t,a)}),e}const et=C("zh-CN"),tt=Q({"zh-CN":{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:(e,t)=>`${e}\u5E74${t}\u6708`,rangePrompt:e=>`\u6700\u591A\u9009\u62E9 ${e} \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:e=>`${e}\u6298`,condition:e=>`\u6EE1${e}\u5143\u53EF\u7528`},vanCouponCell:{title:"\u4F18\u60E0\u5238",count:e=>`${e}\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"}}});var St={messages:()=>tt[et.value],use(e,t){et.value=e,this.add({[e]:t})},add(e={}){Qe(tt,e)}};function Tt(e){const t=Je(e)+".";return(a,...o)=>{const s=St.messages(),n=Ne(s,t+a)||Ne(s,a);return $e(n)?n(...o):n}}function Ee(e,t){return t?typeof t=="string"?` ${e}--${t}`:Array.isArray(t)?t.reduce((a,o)=>a+Ee(e,o),""):Object.keys(t).reduce((a,o)=>a+(t[o]?Ee(e,o):""),""):""}function It(e){return(t,a)=>(t&&typeof t!="string"&&(a=t,t=""),`${t=t?`${e}__${t}`:e}${Ee(t,a)}`)}function _(e){const t=`van-${e}`;return[t,It(t),Tt(t)]}function Bt(e,{args:t=[],done:a,canceled:o,error:s}){if(e){const u=e.apply(null,t);Ce(n=u)&&$e(n.then)&&$e(n.catch)?u.then(l=>{l?a():o&&o()}).catch(s||bt):u?a():o&&o()}else a();var n}function te(e){return e.install=t=>{const{name:a}=e;a&&(t.component(a,e),t.component(Je(`-${a}`),e))},e}const zt=Symbol();function nt(e){const t=vt(zt,null);t&&A(t,a=>{a&&e()})}function ie(e){const t=se();t&&ye(t.proxy,e)}const Ot={to:[String,Object],url:String,replace:Boolean},[Rt,at]=_("badge"),At=te(q({name:Rt,props:{dot:Boolean,max:M,tag:ce("div"),color:String,offset:Array,content:M,showZero:j,position:ce("top-right")},setup(e,{slots:t}){const a=()=>{if(t.content)return!0;const{content:l,showZero:i}=e;return K(l)&&l!==""&&(i||l!==0&&l!=="0")},o=()=>{const{dot:l,max:i,content:g}=e;if(!l&&a())return t.content?t.content():K(i)&&Pe(g)&&+g>+i?`${i}+`:g},s=l=>l.startsWith("-")?l.replace("-",""):`-${l}`,n=B(()=>{const l={background:e.color};if(e.offset){const[i,g]=e.offset,{position:d}=e,[v,f]=d.split("-");t.default?(l[v]=typeof g=="number"?Z(v==="top"?g:-g):v==="top"?Z(g):s(g),l[f]=typeof i=="number"?Z(f==="left"?i:-i):f==="left"?Z(i):s(i)):(l.marginTop=Z(g),l.marginLeft=Z(i))}return l}),u=()=>{if(a()||e.dot)return S("div",{class:at([e.position,{dot:e.dot,fixed:!!t.default}]),style:n.value},[o()])};return()=>{if(t.default){const{tag:l}=e;return S(l,{class:at("wrapper")},{default:()=>[t.default(),u()]})}return u()}}}));let Et=0;function ot(){const e=se(),{name:t="unknown"}=(e==null?void 0:e.type)||{};return`${t}-${++Et}`}function lt(e,t){if(!xe||!window.IntersectionObserver)return;const a=new IntersectionObserver(s=>{t(s[0].intersectionRatio>0)},{root:document.body}),o=()=>{e.value&&a.unobserve(e.value)};He(o),ht(o),Te(()=>{e.value&&a.observe(e.value)})}const[Lt,Mt]=_("sticky");var Xt=q({name:Lt,props:{zIndex:M,position:ce("top"),container:Object,offsetTop:P(0),offsetBottom:P(0)},emits:["scroll","change"],setup(e,{emit:t,slots:a}){const o=C(),s=Ke(o),n=Q({fixed:!1,width:0,height:0,transform:0}),u=C(!1),l=B(()=>Ge(e.position==="top"?e.offsetTop:e.offsetBottom)),i=B(()=>{if(u.value)return;const{fixed:v,height:f,width:m}=n;return v?{width:`${m}px`,height:`${f}px`}:void 0}),g=B(()=>{if(!n.fixed||u.value)return;const v=ye(function(f){const m={};return f!==void 0&&(m.zIndex=+f),m}(e.zIndex),{width:`${n.width}px`,height:`${n.height}px`,[e.position]:`${l.value}px`});return n.transform&&(v.transform=`translate3d(0, ${n.transform}px, 0)`),v}),d=()=>{if(!o.value||le(o))return;const{container:v,position:f}=e,m=U(o),N=Be(window);if(n.width=m.width,n.height=m.height,f==="top")if(v){const R=U(v),w=R.bottom-l.value-n.height;n.fixed=l.value>m.top&&R.bottom>0,n.transform=w<0?w:0}else n.fixed=l.value>m.top;else{const{clientHeight:R}=document.documentElement;if(v){const w=U(v),W=R-w.top-l.value-n.height;n.fixed=R-l.value<m.bottom&&R>w.top,n.transform=W<0?-W:0}else n.fixed=R-l.value<m.bottom}(R=>{t("scroll",{scrollTop:R,isFixed:n.fixed})})(N)};return A(()=>n.fixed,v=>t("change",v)),Ie("scroll",d,{target:s,passive:!0}),lt(o,d),A([fe,Oe],()=>{o.value&&!le(o)&&n.fixed&&(u.value=!0,H(()=>{const v=U(o);n.width=v.width,n.height=v.height,u.value=!1}))}),()=>{var v;return S("div",{ref:o,style:i.value},[S("div",{class:Mt({fixed:n.fixed&&!u.value}),style:g.value},[(v=a.default)==null?void 0:v.call(a)])])}}});const Yt=te(Xt),[it,pe]=_("swipe"),jt={loop:j,width:M,height:M,vertical:Boolean,autoplay:P(0),duration:P(500),touchable:j,lazyRender:Boolean,initialSwipe:P(0),indicatorColor:String,showIndicators:j,stopPropagation:j},rt=Symbol(it);var Ht=q({name:it,props:jt,emits:["change","dragStart","dragEnd"],setup(e,{emit:t,slots:a}){const o=C(),s=C(),n=Q({rect:null,width:0,height:0,offset:0,active:0,swiping:!1});let u=!1;const l=function(){const h=C(0),$=C(0),x=C(0),r=C(0),c=C(0),p=C(0),b=C(""),y=C(!0),z=()=>{x.value=0,r.value=0,c.value=0,p.value=0,b.value="",y.value=!0};return{move:T=>{const k=T.touches[0];var O,X;x.value=(k.clientX<0?0:k.clientX)-h.value,r.value=k.clientY-$.value,c.value=Math.abs(x.value),p.value=Math.abs(r.value),(!b.value||c.value<10&&p.value<10)&&(b.value=(O=c.value)>(X=p.value)?"horizontal":X>O?"vertical":""),y.value&&(c.value>5||p.value>5)&&(y.value=!1)},start:T=>{z(),h.value=T.touches[0].clientX,$.value=T.touches[0].clientY},reset:z,startX:h,startY:$,deltaX:x,deltaY:r,offsetX:c,offsetY:p,direction:b,isVertical:()=>b.value==="vertical",isHorizontal:()=>b.value==="horizontal",isTap:y}}(),{children:i,linkChildren:g}=Ve(rt),d=B(()=>i.length),v=B(()=>n[e.vertical?"height":"width"]),f=B(()=>e.vertical?l.deltaY.value:l.deltaX.value),m=B(()=>n.rect?(e.vertical?n.rect.height:n.rect.width)-v.value*d.value:0),N=B(()=>v.value?Math.ceil(Math.abs(m.value)/v.value):d.value),R=B(()=>d.value*v.value),w=B(()=>(n.active+d.value)%d.value),W=B(()=>{const h=e.vertical?"vertical":"horizontal";return l.direction.value===h}),I=B(()=>{const h={transitionDuration:`${n.swiping?0:e.duration}ms`,transform:`translate${e.vertical?"Y":"X"}(${+n.offset.toFixed(2)}px)`};if(v.value){const $=e.vertical?"height":"width",x=e.vertical?"width":"height";h[$]=`${R.value}px`,h[x]=e[x]?`${e[x]}px`:""}return h}),D=(h,$=0)=>{let x=h*v.value;e.loop||(x=Math.min(x,-m.value));let r=$-x;return e.loop||(r=Ae(r,m.value,0)),r},L=({pace:h=0,offset:$=0,emitChange:x})=>{if(d.value<=1)return;const{active:r}=n,c=(b=>{const{active:y}=n;return b?e.loop?Ae(y+b,-1,d.value):Ae(y+b,0,N.value):y})(h),p=D(c,$);if(e.loop){if(i[0]&&p!==m.value){const b=p<m.value;i[0].setOffset(b?R.value:0)}if(i[d.value-1]&&p!==0){const b=p>0;i[d.value-1].setOffset(b?-R.value:0)}}n.active=c,n.offset=p,x&&c!==r&&t("change",w.value)},F=()=>{n.swiping=!0,n.active<=-1?L({pace:d.value}):n.active>=d.value&&L({pace:-d.value})},re=()=>{F(),l.reset(),oe(()=>{n.swiping=!1,L({pace:1,emitChange:!0})})};let ne;const V=()=>clearTimeout(ne),Y=()=>{V(),+e.autoplay>0&&d.value>1&&(ne=setTimeout(()=>{re(),Y()},+e.autoplay))},E=(h=+e.initialSwipe)=>{if(!o.value)return;const $=()=>{var x,r;if(!le(o)){const c={width:o.value.offsetWidth,height:o.value.offsetHeight};n.rect=c,n.width=+((x=e.width)!=null?x:c.width),n.height=+((r=e.height)!=null?r:c.height)}d.value&&(h=Math.min(d.value-1,h))===-1&&(h=d.value-1),n.active=h,n.swiping=!0,n.offset=D(h),i.forEach(c=>{c.setOffset(0)}),Y()};le(o)?H().then($):$()},G=()=>E(n.active);let J;const ge=h=>{!e.touchable||h.touches.length>1||(l.start(h),u=!1,J=Date.now(),V(),F())},me=()=>{if(!e.touchable||!n.swiping)return;const h=Date.now()-J,$=f.value/h;if((Math.abs($)>.25||Math.abs(f.value)>v.value/2)&&W.value){const x=e.vertical?l.offsetY.value:l.offsetX.value;let r=0;r=e.loop?x>0?f.value>0?-1:1:0:-Math[f.value>0?"ceil":"floor"](f.value/v.value),L({pace:r,emitChange:!0})}else f.value&&L({pace:0});u=!1,n.swiping=!1,t("dragEnd",{index:w.value}),Y()},Me=(h,$)=>{const x=$===w.value,r=x?{backgroundColor:e.indicatorColor}:void 0;return S("i",{style:r,class:pe("indicator",{active:x})},null)};return ie({prev:()=>{F(),l.reset(),oe(()=>{n.swiping=!1,L({pace:-1,emitChange:!0})})},next:re,state:n,resize:G,swipeTo:(h,$={})=>{F(),l.reset(),oe(()=>{let x;x=e.loop&&h===d.value?n.active===0?0:h:h%d.value,$.immediate?oe(()=>{n.swiping=!1}):n.swiping=!1,L({pace:x-n.active,emitChange:!0})})}}),g({size:v,props:e,count:d,activeIndicator:w}),A(()=>e.initialSwipe,h=>E(+h)),A(d,()=>E(n.active)),A(()=>e.autoplay,Y),A([fe,Oe,()=>e.width,()=>e.height],G),A(function(){if(!ve&&(ve=C("visible"),ee)){const h=()=>{ve.value=document.hidden?"hidden":"visible"};h(),window.addEventListener("visibilitychange",h)}return ve}(),h=>{h==="visible"?Y():V()}),ue(E),je(()=>E(n.active)),nt(()=>E(n.active)),He(V),ht(V),Ie("touchmove",h=>{e.touchable&&n.swiping&&(l.move(h),W.value)&&(!e.loop&&(n.active===0&&f.value>0||n.active===d.value-1&&f.value<0)||(function($,x){(typeof $.cancelable!="boolean"||$.cancelable)&&$.preventDefault(),x&&(r=>{r.stopPropagation()})($)}(h,e.stopPropagation),L({offset:f.value}),u||(t("dragStart",{index:w.value}),u=!0)))},{target:s}),()=>{var h;return S("div",{ref:o,class:pe()},[S("div",{ref:s,style:I.value,class:pe("track",{vertical:e.vertical}),onTouchstartPassive:ge,onTouchend:me,onTouchcancel:me},[(h=a.default)==null?void 0:h.call(a)]),a.indicator?a.indicator({active:w.value,total:d.value}):e.showIndicators&&d.value>1?S("div",{class:pe("indicators",{vertical:e.vertical})},[Array(d.value).fill("").map(Me)]):void 0])}}});const Pt=te(Ht),[Nt,st]=_("tabs");var Wt=q({name:Nt,props:{count:ke(Number),inited:Boolean,animated:Boolean,duration:ke(M),swipeable:Boolean,lazyRender:Boolean,currentIndex:ke(Number)},emits:["change"],setup(e,{emit:t,slots:a}){const o=C(),s=l=>t("change",l),n=()=>{var l;const i=(l=a.default)==null?void 0:l.call(a);return e.animated||e.swipeable?S(Pt,{ref:o,loop:!1,class:st("track"),duration:1e3*+e.duration,touchable:e.swipeable,lazyRender:e.lazyRender,showIndicators:!1,onChange:s},{default:()=>[i]}):i},u=l=>{const i=o.value;i&&i.state.active!==l&&i.swipeTo(l,{immediate:!e.inited})};return A(()=>e.currentIndex,u),ue(()=>{u(e.currentIndex)}),ie({swipeRef:o}),()=>S("div",{class:st("content",{animated:e.animated||e.swipeable})},[n()])}});const[ut,he]=_("tabs"),Ft={type:ce("line"),color:String,border:Boolean,sticky:Boolean,shrink:Boolean,active:P(0),duration:P(.3),animated:Boolean,ellipsis:j,swipeable:Boolean,scrollspy:Boolean,offsetTop:P(0),background:String,lazyRender:j,showHeader:j,lineWidth:M,lineHeight:M,beforeChange:Function,swipeThreshold:P(5),titleActiveColor:String,titleInactiveColor:String},ct=Symbol(ut);var Zt=q({name:ut,props:Ft,emits:["change","scroll","rendered","clickTab","update:active"],setup(e,{emit:t,slots:a}){let o,s,n,u,l;const i=C(),g=C(),d=C(),v=C(),f=ot(),m=Ke(i),[N,R]=function(){const r=C([]),c=[];return nn(()=>{r.value=[]}),[r,p=>(c[p]||(c[p]=b=>{r.value[p]=b}),c[p])]}(),{children:w,linkChildren:W}=Ve(ct),I=Q({inited:!1,position:"",lineStyle:{},currentIndex:-1}),D=B(()=>w.length>+e.swipeThreshold||!e.ellipsis||e.shrink),L=B(()=>({borderColor:e.color,background:e.background})),F=(r,c)=>{var p;return(p=r.name)!=null?p:c},re=B(()=>{const r=w[I.currentIndex];if(r)return F(r,I.currentIndex)}),ne=B(()=>Ge(e.offsetTop)),V=B(()=>e.sticky?ne.value+o:0),Y=r=>{const c=g.value,p=N.value;if(!(D.value&&c&&p&&p[I.currentIndex]))return;const b=p[I.currentIndex].$el,y=b.offsetLeft-(c.offsetWidth-b.offsetWidth)/2;u&&u(),u=function(z,T,k){let O,X=0;const Xe=z.scrollLeft,be=k===0?1:Math.round(1e3*k/16);return function Ye(){z.scrollLeft+=(T-Xe)/be,++X<be&&(O=ae(Ye))}(),function(){Fe(O)}}(c,y,r?0:+e.duration)},E=()=>{const r=I.inited;H(()=>{const c=N.value;if(!c||!c[I.currentIndex]||e.type!=="line"||le(i.value))return;const p=c[I.currentIndex].$el,{lineWidth:b,lineHeight:y}=e,z=p.offsetLeft+p.offsetWidth/2,T={width:Z(b),backgroundColor:e.color,transform:`translateX(${z}px) translateX(-50%)`};if(r&&(T.transitionDuration=`${e.duration}s`),K(y)){const k=Z(y);T.height=k,T.borderRadius=k}I.lineStyle=T})},G=(r,c)=>{const p=(k=>{const O=k<I.currentIndex?-1:1;for(;k>=0&&k<w.length;){if(!w[k].disabled)return k;k+=O}})(r);if(!K(p))return;const b=w[p],y=F(b,p),z=I.currentIndex!==null;var T;I.currentIndex!==p&&(I.currentIndex=p,c||Y(),E()),y!==e.active&&(t("update:active",y),z&&t("change",y,b.title)),n&&!e.scrollspy&&(T=Math.ceil(Ue(i.value)-ne.value),ze(window,T),ze(document.body,T))},J=(r,c)=>{const p=w.find((y,z)=>F(y,z)===r),b=p?w.indexOf(p):0;G(b,c)},ge=(r=!1)=>{if(e.scrollspy){const c=w[I.currentIndex].$el;if(c&&m.value){const p=Ue(c,m.value)-V.value;s=!0,l&&l(),l=function(b,y,z,T){let k,O=Be(b);const X=O<y,Xe=z===0?1:Math.round(1e3*z/16),be=(y-O)/Xe;return function Ye(){O+=be,(X&&O>y||!X&&O<y)&&(O=y),ze(b,O),X&&O<y||!X&&O>y?k=ae(Ye):T&&(k=ae(T))}(),function(){Fe(k)}}(m.value,p,r?0:+e.duration,()=>{s=!1})}}},me=(r,c,p)=>{const{title:b,disabled:y}=w[c],z=F(w[c],c);y||(Bt(e.beforeChange,{args:[z],done:()=>{G(c),ge()}}),function({to:T,url:k,replace:O,$router:X}){T&&X?X[O?"replace":"push"](T):k&&(O?location.replace(k):location.href=k)}(r)),t("clickTab",{name:z,title:b,event:p,disabled:y})},Me=r=>{n=r.isFixed,t("scroll",r)},h=()=>{if(e.type==="line"&&w.length)return S("div",{class:he("line"),style:I.lineStyle},null)},$=()=>{var r,c,p;const{type:b,border:y,sticky:z}=e,T=[S("div",{ref:z?void 0:d,class:[he("wrap"),{"van-hairline--top-bottom":b==="line"&&y}]},[S("div",{ref:g,role:"tablist",class:he("nav",[b,{shrink:e.shrink,complete:D.value}]),style:L.value,"aria-orientation":"horizontal"},[(r=a["nav-left"])==null?void 0:r.call(a),w.map(k=>k.renderTitle(me)),h(),(c=a["nav-right"])==null?void 0:c.call(a)])]),(p=a["nav-bottom"])==null?void 0:p.call(a)];return z?S("div",{ref:d},[T]):T},x=()=>{E(),H(()=>{var r,c;Y(!0),(c=(r=v.value)==null?void 0:r.swipeRef.value)==null||c.resize()})};return A(()=>[e.color,e.duration,e.lineWidth,e.lineHeight],E),A(fe,x),A(()=>e.active,r=>{r!==re.value&&J(r)}),A(()=>w.length,()=>{I.inited&&(J(e.active),E(),H(()=>{Y(!0)}))}),ie({resize:x,scrollTo:r=>{H(()=>{J(r),ge(!0)})}}),je(E),nt(E),Te(()=>{J(e.active,!0),H(()=>{I.inited=!0,d.value&&(o=U(d.value).height),Y(!0)})}),lt(i,E),Ie("scroll",()=>{if(e.scrollspy&&!s){const r=(()=>{for(let c=0;c<w.length;c++){const{top:p}=U(w[c].$el);if(p>V.value)return c===0?0:c-1}return w.length-1})();G(r)}},{target:m,passive:!0}),W({id:f,props:e,setLine:E,scrollable:D,onRendered:(r,c)=>t("rendered",r,c),currentName:re,setTitleRefs:R,scrollIntoView:Y}),()=>S("div",{ref:i,class:he([e.type])},[e.showHeader?e.sticky?S(Yt,{container:i.value,offsetTop:ne.value,onScroll:Me},{default:()=>[$()]}):$():null,S(Wt,{ref:v,count:w.length,inited:I.inited,animated:e.animated,duration:e.duration,swipeable:e.swipeable,lazyRender:e.lazyRender,currentIndex:I.currentIndex,onChange:G},{default:()=>{var r;return[(r=a.default)==null?void 0:r.call(a)]}})])}});const _t=Symbol(),[Dt,dt]=_("tab"),Vt=q({name:Dt,props:{id:String,dot:Boolean,type:String,color:String,title:String,badge:M,shrink:Boolean,isActive:Boolean,disabled:Boolean,controls:String,scrollable:Boolean,activeColor:String,inactiveColor:String,showZeroBadge:j},setup(e,{slots:t}){const a=B(()=>{const s={},{type:n,color:u,disabled:l,isActive:i,activeColor:g,inactiveColor:d}=e;u&&n==="card"&&(s.borderColor=u,l||(i?s.backgroundColor=u:s.color=u));const v=i?g:d;return v&&(s.color=v),s}),o=()=>{const s=S("span",{class:dt("text",{ellipsis:!e.scrollable})},[t.title?t.title():e.title]);return e.dot||K(e.badge)&&e.badge!==""?S(At,{dot:e.dot,content:e.badge,showZero:e.showZeroBadge},{default:()=>[s]}):s};return()=>S("div",{id:e.id,role:"tab",class:[dt([e.type,{grow:e.scrollable&&!e.shrink,shrink:e.shrink,active:e.isActive,disabled:e.disabled}])],style:a.value,tabindex:e.disabled?void 0:e.isActive?0:-1,"aria-selected":e.isActive,"aria-disabled":e.disabled||void 0,"aria-controls":e.controls},[o()])}}),[qt,Kt]=_("swipe-item");var Ut=q({name:qt,setup(e,{slots:t}){let a;const o=Q({offset:0,inited:!1,mounted:!1}),{parent:s,index:n}=_e(rt);if(!s)return void console.error("[Vant] <SwipeItem> must be a child component of <Swipe>.");const u=B(()=>{const i={},{vertical:g}=s.props;return s.size.value&&(i[g?"height":"width"]=`${s.size.value}px`),o.offset&&(i.transform=`translate${g?"Y":"X"}(${o.offset}px)`),i}),l=B(()=>{const{loop:i,lazyRender:g}=s.props;if(!g||a)return!0;if(!o.mounted)return!1;const d=s.activeIndicator.value,v=s.count.value-1,f=d===0&&i?v:d-1,m=d===v&&i?0:d+1;return a=n.value===d||n.value===f||n.value===m,a});return ue(()=>{H(()=>{o.mounted=!0})}),ie({setOffset:i=>{o.offset=i}}),()=>{var i;return S("div",{class:Kt(),style:u.value},[l.value?(i=t.default)==null?void 0:i.call(t):null])}}});const Gt=te(Ut),[Jt,Le]=_("tab");var Qt=q({name:Jt,props:ye({},Ot,{dot:Boolean,name:M,badge:M,title:String,disabled:Boolean,titleClass:null,titleStyle:[String,Object],showZeroBadge:j}),setup(e,{slots:t}){const a=ot(),o=C(!1),s=se(),{parent:n,index:u}=_e(ct);if(!n)return void console.error("[Vant] <Tab> must be a child component of <Tabs>.");const l=()=>{var f;return(f=e.name)!=null?f:u.value},i=B(()=>{const f=l()===n.currentName.value;return f&&!o.value&&(o.value=!0,n.props.lazyRender&&H(()=>{n.onRendered(l(),e.title)})),f}),g=C(""),d=C("");an(()=>{const{titleClass:f,titleStyle:m}=e;g.value=f?on(f):"",d.value=m&&typeof m!="string"?ln(rn(m)):m});const v=C(!i.value);return A(i,f=>{f?v.value=!1:oe(()=>{v.value=!0})}),A(()=>e.title,()=>{n.setLine(),n.scrollIntoView()}),pt(_t,i),ie({id:a,renderTitle:f=>S(Vt,cn({key:a,id:`${n.id}-${u.value}`,ref:n.setTitleRefs(u.value),style:d.value,class:g.value,isActive:i.value,controls:a,scrollable:n.scrollable.value,activeColor:n.props.titleActiveColor,inactiveColor:n.props.titleInactiveColor,onClick:m=>f(s.proxy,u.value,m)},We(n.props,["type","color","shrink"]),We(e,["dot","badge","title","disabled","showZeroBadge"])),{title:t.title})}),()=>{var f;const m=`${n.id}-${u.value}`,{animated:N,swipeable:R,scrollspy:w,lazyRender:W}=n.props;if(!t.default&&!N)return;const I=w||i.value;if(N||R)return S(Gt,{id:a,role:"tabpanel",class:Le("panel-wrapper",{inactive:v.value}),tabindex:i.value?0:-1,"aria-hidden":!i.value,"aria-labelledby":m},{default:()=>{var L;return[S("div",{class:Le("panel")},[(L=t.default)==null?void 0:L.call(t)])]}});const D=o.value||w||!W?(f=t.default)==null?void 0:f.call(t):null;return sn(S("div",{id:a,role:"tabpanel",class:Le("panel"),tabindex:I?0:-1,"aria-labelledby":m},[D]),[[un,I]])}}});gt=te(Qt),mt=te(Zt)});export{gt as T,vn as __tla,mt as a};
  5. >>>>>>>> 2589804fb89eb98fd6498c1ee41a354dcce32af3:dist/assets/index-3f432935.js