1234567891011121314151617181920212223242526 |
- import{_ as O,c,I as K,k as _t,i as Ft,b as Rt,a as Tt,s as z,d as ee,o as Y,e as Fe,f as N,g as P,h as pe,p as De,j as X,l as R,F as ge,m as D,r as W,n as jt,q as re,u as At,T as ut,t as dt,v as pt,w as ft,K as Re,x as he,C as Lt,y as Et,z as Mt,A as Ut,B as ye,D as gt,E as me,G as ce,H as mt,J as kt,L as Bt,M as Nt,N as vt,O as ht,P as zt,Q as Ht,R as Wt,S as Xt,U as Vt,V as ze,W as Gt,X as _e,Y as qt,Z as yt,$ as bt,a0 as Yt,a1 as Jt,a2 as Qt,a3 as Zt,a4 as Kt,a5 as en,a6 as tn,a7 as nn,a8 as ae,a9 as rn,aa as on,ab as ie,ac as q,ad as He,ae as an,af as ln,ag as sn,ah as le,ai as We,aj as Ce}from"./index-C_PlwN-f.js";const cn=`accept acceptcharset accesskey action allowfullscreen allowtransparency
- alt async autocomplete autofocus autoplay capture cellpadding cellspacing challenge
- charset checked classid classname colspan cols content contenteditable contextmenu
- controls coords crossorigin data datetime default defer dir disabled download draggable
- enctype form formaction formenctype formmethod formnovalidate formtarget frameborder
- headers height hidden high href hreflang htmlfor for httpequiv icon id inputmode integrity
- is keyparams keytype kind label lang list loop low manifest marginheight marginwidth max maxlength media
- mediagroup method min minlength multiple muted name novalidate nonce open
- optimum pattern placeholder poster preload radiogroup readonly rel required
- reversed role rowspan rows sandbox scope scoped scrolling seamless selected
- shape size sizes span spellcheck src srcdoc srclang srcset start step style
- summary tabindex target title type usemap value width wmode wrap`,un=`onCopy onCut onPaste onCompositionend onCompositionstart onCompositionupdate onKeydown
- onKeypress onKeyup onFocus onBlur onChange onInput onSubmit onClick onContextmenu onDoubleclick onDblclick
- onDrag onDragend onDragenter onDragexit onDragleave onDragover onDragstart onDrop onMousedown
- onMouseenter onMouseleave onMousemove onMouseout onMouseover onMouseup onSelect onTouchcancel
- onTouchend onTouchmove onTouchstart onTouchstartPassive onTouchmovePassive onScroll onWheel onAbort onCanplay onCanplaythrough
- onDurationchange onEmptied onEncrypted onEnded onError onLoadeddata onLoadedmetadata
- onLoadstart onPause onPlay onPlaying onProgress onRatechange onSeeked onSeeking onStalled onSuspend onTimeupdate onVolumechange onWaiting onLoad onError`,Xe=`${cn} ${un}`.split(/[\s\n]+/),dn="aria-",pn="data-";function Ve(e,t){return e.indexOf(t)===0}function fn(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n;t===!1?n={aria:!0,data:!0,attr:!0}:t===!0?n={aria:!0}:n=O({},t);const r={};return Object.keys(e).forEach(o=>{(n.aria&&(o==="role"||Ve(o,dn))||n.data&&Ve(o,pn)||n.attr&&(Xe.includes(o)||Xe.includes(o.toLowerCase())))&&(r[o]=e[o])}),r}var gn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"};function Ge(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),r.forEach(function(o){mn(e,o,n[o])})}return e}function mn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Te=function(t,n){var r=Ge({},t,n.attrs);return c(K,Ge({},r,{icon:gn}),null)};Te.displayName="CheckOutlined";Te.inheritAttrs=!1;function vn(e,t,n,r){for(var o=-1,i=e==null?0:e.length;++o<i;){var a=e[o];t(r,a,n(a),e)}return r}function hn(e){return function(t,n,r){for(var o=-1,i=Object(t),a=r(t),l=a.length;l--;){var u=a[++o];if(n(i[u],u,i)===!1)break}return t}}var yn=hn();function bn(e,t){return e&&yn(e,t,_t)}function wn(e,t){return function(n,r){if(n==null)return n;if(!Ft(n))return e(n,r);for(var o=n.length,i=-1,a=Object(n);++i<o&&r(a[i],i,a)!==!1;);return n}}var $n=wn(bn);function Cn(e,t,n,r){return $n(e,function(o,i,a){t(r,o,n(o),a)}),r}function Sn(e,t){return function(n,r){var o=Tt(n)?vn:Cn,i=t?t():{};return o(n,e,Rt(r),i)}}var On=Sn(function(e,t,n){e[n?0:1].push(t)},function(){return[[],[]]});const xn=["normal","exception","active","success"],be=()=>({prefixCls:String,type:z(),percent:Number,format:P(),status:z(),showInfo:N(),strokeWidth:Number,strokeLinecap:z(),strokeColor:Fe(),trailColor:String,width:Number,success:Y(),gapDegree:Number,gapPosition:z(),size:ee([String,Number,Array]),steps:Number,successPercent:Number,title:String,progressStatus:z()});function te(e){return!e||e<0?0:e>100?100:e}function ve(e){let{success:t,successPercent:n}=e,r=n;return t&&"progress"in t&&(pe(!1,"Progress","`success.progress` is deprecated. Please use `success.percent` instead."),r=t.progress),t&&"percent"in t&&(r=t.percent),r}function Pn(e){let{percent:t,success:n,successPercent:r}=e;const o=te(ve({success:n,successPercent:r}));return[o,te(te(t)-o)]}function In(e){let{success:t={},strokeColor:n}=e;const{strokeColor:r}=t;return[r||De.green,n||null]}const we=(e,t,n)=>{var r,o,i,a;let l=-1,u=-1;if(t==="step"){const p=n.steps,d=n.strokeWidth;typeof e=="string"||typeof e>"u"?(l=e==="small"?2:14,u=d??8):typeof e=="number"?[l,u]=[e,e]:[l=14,u=8]=e,l*=p}else if(t==="line"){const p=n==null?void 0:n.strokeWidth;typeof e=="string"||typeof e>"u"?u=p||(e==="small"?6:8):typeof e=="number"?[l,u]=[e,e]:[l=-1,u=8]=e}else(t==="circle"||t==="dashboard")&&(typeof e=="string"||typeof e>"u"?[l,u]=e==="small"?[60,60]:[120,120]:typeof e=="number"?[l,u]=[e,e]:(l=(o=(r=e[0])!==null&&r!==void 0?r:e[1])!==null&&o!==void 0?o:120,u=(a=(i=e[0])!==null&&i!==void 0?i:e[1])!==null&&a!==void 0?a:120));return{width:l,height:u}};var Dn=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const _n=()=>O(O({},be()),{strokeColor:Fe(),direction:z()}),Fn=e=>{let t=[];return Object.keys(e).forEach(n=>{const r=parseFloat(n.replace(/%/g,""));isNaN(r)||t.push({key:r,value:e[n]})}),t=t.sort((n,r)=>n.key-r.key),t.map(n=>{let{key:r,value:o}=n;return`${o} ${r}%`}).join(", ")},Rn=(e,t)=>{const{from:n=De.blue,to:r=De.blue,direction:o=t==="rtl"?"to left":"to right"}=e,i=Dn(e,["from","to","direction"]);if(Object.keys(i).length!==0){const a=Fn(i);return{backgroundImage:`linear-gradient(${o}, ${a})`}}return{backgroundImage:`linear-gradient(${o}, ${n}, ${r})`}},Tn=X({compatConfig:{MODE:3},name:"ProgressLine",inheritAttrs:!1,props:_n(),setup(e,t){let{slots:n,attrs:r}=t;const o=R(()=>{const{strokeColor:m,direction:_}=e;return m&&typeof m!="string"?Rn(m,_):{backgroundColor:m}}),i=R(()=>e.strokeLinecap==="square"||e.strokeLinecap==="butt"?0:void 0),a=R(()=>e.trailColor?{backgroundColor:e.trailColor}:void 0),l=R(()=>{var m;return(m=e.size)!==null&&m!==void 0?m:[-1,e.strokeWidth||(e.size==="small"?6:8)]}),u=R(()=>we(l.value,"line",{strokeWidth:e.strokeWidth})),p=R(()=>{const{percent:m}=e;return O({width:`${te(m)}%`,height:`${u.value.height}px`,borderRadius:i.value},o.value)}),d=R(()=>ve(e)),I=R(()=>{const{success:m}=e;return{width:`${te(d.value)}%`,height:`${u.value.height}px`,borderRadius:i.value,backgroundColor:m==null?void 0:m.strokeColor}}),b={width:u.value.width<0?"100%":u.value.width,height:`${u.value.height}px`};return()=>{var m;return c(ge,null,[c("div",D(D({},r),{},{class:[`${e.prefixCls}-outer`,r.class],style:[r.style,b]}),[c("div",{class:`${e.prefixCls}-inner`,style:a.value},[c("div",{class:`${e.prefixCls}-bg`,style:p.value},null),d.value!==void 0?c("div",{class:`${e.prefixCls}-success-bg`,style:I.value},null):null])]),(m=n.default)===null||m===void 0?void 0:m.call(n)])}}}),jn={percent:0,prefixCls:"vc-progress",strokeColor:"#2db7f5",strokeLinecap:"round",strokeWidth:1,trailColor:"#D9D9D9",trailWidth:1},An=e=>{const t=W(null);return jt(()=>{const n=Date.now();let r=!1;e.value.forEach(o=>{const i=(o==null?void 0:o.$el)||o;if(!i)return;r=!0;const a=i.style;a.transitionDuration=".3s, .3s, .3s, .06s",t.value&&n-t.value<100&&(a.transitionDuration="0s, 0s")}),r&&(t.value=Date.now())}),e},Ln={gapDegree:Number,gapPosition:{type:String},percent:{type:[Array,Number]},prefixCls:String,strokeColor:{type:[Object,String,Array]},strokeLinecap:{type:String},strokeWidth:Number,trailColor:String,trailWidth:Number,transition:String};var En=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let qe=0;function Ye(e){return+e.replace("%","")}function Je(e){return Array.isArray(e)?e:[e]}function Qe(e,t,n,r){let o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0,i=arguments.length>5?arguments[5]:void 0;const a=50-r/2;let l=0,u=-a,p=0,d=-2*a;switch(i){case"left":l=-a,u=0,p=2*a,d=0;break;case"right":l=a,u=0,p=-2*a,d=0;break;case"bottom":u=a,d=2*a;break}const I=`M 50,50 m ${l},${u}
- a ${a},${a} 0 1 1 ${p},${-d}
- a ${a},${a} 0 1 1 ${-p},${d}`,b=Math.PI*2*a,m={stroke:n,strokeDasharray:`${t/100*(b-o)}px ${b}px`,strokeDashoffset:`-${o/2+e/100*(b-o)}px`,transition:"stroke-dashoffset .3s ease 0s, stroke-dasharray .3s ease 0s, stroke .3s, stroke-width .06s ease .3s, opacity .3s ease 0s"};return{pathString:I,pathStyle:m}}const Mn=X({compatConfig:{MODE:3},name:"VCCircle",props:re(Ln,jn),setup(e){qe+=1;const t=W(qe),n=R(()=>Je(e.percent)),r=R(()=>Je(e.strokeColor)),[o,i]=At();An(i);const a=()=>{const{prefixCls:l,strokeWidth:u,strokeLinecap:p,gapDegree:d,gapPosition:I}=e;let b=0;return n.value.map((m,_)=>{const s=r.value[_]||r.value[r.value.length-1],h=Object.prototype.toString.call(s)==="[object Object]"?`url(#${l}-gradient-${t.value})`:"",{pathString:F,pathStyle:f}=Qe(b,m,s,u,d,I);b+=m;const y={key:_,d:F,stroke:h,"stroke-linecap":p,"stroke-width":u,opacity:m===0?0:1,"fill-opacity":"0",class:`${l}-circle-path`,style:f};return c("path",D({ref:o(_)},y),null)})};return()=>{const{prefixCls:l,strokeWidth:u,trailWidth:p,gapDegree:d,gapPosition:I,trailColor:b,strokeLinecap:m,strokeColor:_}=e,s=En(e,["prefixCls","strokeWidth","trailWidth","gapDegree","gapPosition","trailColor","strokeLinecap","strokeColor"]),{pathString:h,pathStyle:F}=Qe(0,100,b,u,d,I);delete s.percent;const f=r.value.find(v=>Object.prototype.toString.call(v)==="[object Object]"),y={d:h,stroke:b,"stroke-linecap":m,"stroke-width":p||u,"fill-opacity":"0",class:`${l}-circle-trail`,style:F};return c("svg",D({class:`${l}-circle`,viewBox:"0 0 100 100"},s),[f&&c("defs",null,[c("linearGradient",{id:`${l}-gradient-${t.value}`,x1:"100%",y1:"0%",x2:"0%",y2:"0%"},[Object.keys(f).sort((v,S)=>Ye(v)-Ye(S)).map((v,S)=>c("stop",{key:S,offset:v,"stop-color":f[v]},null))])]),c("path",y,null),a().reverse()])}}}),Un=()=>O(O({},be()),{strokeColor:Fe()}),kn=3,Bn=e=>kn/e*100,Nn=X({compatConfig:{MODE:3},name:"ProgressCircle",inheritAttrs:!1,props:re(Un(),{trailColor:null}),setup(e,t){let{slots:n,attrs:r}=t;const o=R(()=>{var s;return(s=e.width)!==null&&s!==void 0?s:120}),i=R(()=>{var s;return(s=e.size)!==null&&s!==void 0?s:[o.value,o.value]}),a=R(()=>we(i.value,"circle")),l=R(()=>{if(e.gapDegree||e.gapDegree===0)return e.gapDegree;if(e.type==="dashboard")return 75}),u=R(()=>({width:`${a.value.width}px`,height:`${a.value.height}px`,fontSize:`${a.value.width*.15+6}px`})),p=R(()=>{var s;return(s=e.strokeWidth)!==null&&s!==void 0?s:Math.max(Bn(a.value.width),6)}),d=R(()=>e.gapPosition||e.type==="dashboard"&&"bottom"||void 0),I=R(()=>Pn(e)),b=R(()=>Object.prototype.toString.call(e.strokeColor)==="[object Object]"),m=R(()=>In({success:e.success,strokeColor:e.strokeColor})),_=R(()=>({[`${e.prefixCls}-inner`]:!0,[`${e.prefixCls}-circle-gradient`]:b.value}));return()=>{var s;const h=c(Mn,{percent:I.value,strokeWidth:p.value,trailWidth:p.value,strokeColor:m.value,strokeLinecap:e.strokeLinecap,trailColor:e.trailColor,prefixCls:e.prefixCls,gapDegree:l.value,gapPosition:d.value},null);return c("div",D(D({},r),{},{class:[_.value,r.class],style:[r.style,u.value]}),[a.value.width<=20?c(ut,null,{default:()=>[c("span",null,[h])],title:n.default}):c(ge,null,[h,(s=n.default)===null||s===void 0?void 0:s.call(n)])])}}}),zn=()=>O(O({},be()),{steps:Number,strokeColor:ee(),trailColor:String}),Hn=X({compatConfig:{MODE:3},name:"Steps",props:zn(),setup(e,t){let{slots:n}=t;const r=R(()=>Math.round(e.steps*((e.percent||0)/100))),o=R(()=>{var l;return(l=e.size)!==null&&l!==void 0?l:[e.size==="small"?2:14,e.strokeWidth||8]}),i=R(()=>we(o.value,"step",{steps:e.steps,strokeWidth:e.strokeWidth||8})),a=R(()=>{const{steps:l,strokeColor:u,trailColor:p,prefixCls:d}=e,I=[];for(let b=0;b<l;b+=1){const m=Array.isArray(u)?u[b]:u,_={[`${d}-steps-item`]:!0,[`${d}-steps-item-active`]:b<=r.value-1};I.push(c("div",{key:b,class:_,style:{backgroundColor:b<=r.value-1?m:p,width:`${i.value.width/l}px`,height:`${i.value.height}px`}},null))}return I});return()=>{var l;return c("div",{class:`${e.prefixCls}-steps-outer`},[a.value,(l=n.default)===null||l===void 0?void 0:l.call(n)])}}}),Wn=new Re("antProgressActive",{"0%":{transform:"translateX(-100%) scaleX(0)",opacity:.1},"20%":{transform:"translateX(-100%) scaleX(0)",opacity:.5},to:{transform:"translateX(0) scaleX(1)",opacity:0}}),Xn=e=>{const{componentCls:t,iconCls:n}=e;return{[t]:O(O({},ft(e)),{display:"inline-block","&-rtl":{direction:"rtl"},"&-line":{position:"relative",width:"100%",fontSize:e.fontSize,marginInlineEnd:e.marginXS,marginBottom:e.marginXS},[`${t}-outer`]:{display:"inline-block",width:"100%"},[`&${t}-show-info`]:{[`${t}-outer`]:{marginInlineEnd:`calc(-2em - ${e.marginXS}px)`,paddingInlineEnd:`calc(2em + ${e.paddingXS}px)`}},[`${t}-inner`]:{position:"relative",display:"inline-block",width:"100%",overflow:"hidden",verticalAlign:"middle",backgroundColor:e.progressRemainingColor,borderRadius:e.progressLineRadius},[`${t}-inner:not(${t}-circle-gradient)`]:{[`${t}-circle-path`]:{stroke:e.colorInfo}},[`${t}-success-bg, ${t}-bg`]:{position:"relative",backgroundColor:e.colorInfo,borderRadius:e.progressLineRadius,transition:`all ${e.motionDurationSlow} ${e.motionEaseInOutCirc}`},[`${t}-success-bg`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,backgroundColor:e.colorSuccess},[`${t}-text`]:{display:"inline-block",width:"2em",marginInlineStart:e.marginXS,color:e.progressInfoTextColor,lineHeight:1,whiteSpace:"nowrap",textAlign:"start",verticalAlign:"middle",wordBreak:"normal",[n]:{fontSize:e.fontSize}},[`&${t}-status-active`]:{[`${t}-bg::before`]:{position:"absolute",inset:0,backgroundColor:e.colorBgContainer,borderRadius:e.progressLineRadius,opacity:0,animationName:Wn,animationDuration:e.progressActiveMotionDuration,animationTimingFunction:e.motionEaseOutQuint,animationIterationCount:"infinite",content:'""'}},[`&${t}-status-exception`]:{[`${t}-bg`]:{backgroundColor:e.colorError},[`${t}-text`]:{color:e.colorError}},[`&${t}-status-exception ${t}-inner:not(${t}-circle-gradient)`]:{[`${t}-circle-path`]:{stroke:e.colorError}},[`&${t}-status-success`]:{[`${t}-bg`]:{backgroundColor:e.colorSuccess},[`${t}-text`]:{color:e.colorSuccess}},[`&${t}-status-success ${t}-inner:not(${t}-circle-gradient)`]:{[`${t}-circle-path`]:{stroke:e.colorSuccess}}})}},Vn=e=>{const{componentCls:t,iconCls:n}=e;return{[t]:{[`${t}-circle-trail`]:{stroke:e.progressRemainingColor},[`&${t}-circle ${t}-inner`]:{position:"relative",lineHeight:1,backgroundColor:"transparent"},[`&${t}-circle ${t}-text`]:{position:"absolute",insetBlockStart:"50%",insetInlineStart:0,width:"100%",margin:0,padding:0,color:e.colorText,lineHeight:1,whiteSpace:"normal",textAlign:"center",transform:"translateY(-50%)",[n]:{fontSize:`${e.fontSize/e.fontSizeSM}em`}},[`${t}-circle&-status-exception`]:{[`${t}-text`]:{color:e.colorError}},[`${t}-circle&-status-success`]:{[`${t}-text`]:{color:e.colorSuccess}}},[`${t}-inline-circle`]:{lineHeight:1,[`${t}-inner`]:{verticalAlign:"bottom"}}}},Gn=e=>{const{componentCls:t}=e;return{[t]:{[`${t}-steps`]:{display:"inline-block","&-outer":{display:"flex",flexDirection:"row",alignItems:"center"},"&-item":{flexShrink:0,minWidth:e.progressStepMinWidth,marginInlineEnd:e.progressStepMarginInlineEnd,backgroundColor:e.progressRemainingColor,transition:`all ${e.motionDurationSlow}`,"&-active":{backgroundColor:e.colorInfo}}}}}},qn=e=>{const{componentCls:t,iconCls:n}=e;return{[t]:{[`${t}-small&-line, ${t}-small&-line ${t}-text ${n}`]:{fontSize:e.fontSizeSM}}}},Yn=dt("Progress",e=>{const t=e.marginXXS/2,n=pt(e,{progressLineRadius:100,progressInfoTextColor:e.colorText,progressDefaultColor:e.colorInfo,progressRemainingColor:e.colorFillSecondary,progressStepMarginInlineEnd:t,progressStepMinWidth:t,progressActiveMotionDuration:"2.4s"});return[Xn(n),Vn(n),Gn(n),qn(n)]});var Jn=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const Qn=X({compatConfig:{MODE:3},name:"AProgress",inheritAttrs:!1,props:re(be(),{type:"line",percent:0,showInfo:!0,trailColor:null,size:"default",strokeLinecap:"round"}),slots:Object,setup(e,t){let{slots:n,attrs:r}=t;const{prefixCls:o,direction:i}=he("progress",e),[a,l]=Yn(o),u=R(()=>Array.isArray(e.strokeColor)?e.strokeColor[0]:e.strokeColor),p=R(()=>{const{percent:_=0}=e,s=ve(e);return parseInt(s!==void 0?s.toString():_.toString(),10)}),d=R(()=>{const{status:_}=e;return!xn.includes(_)&&p.value>=100?"success":_||"normal"}),I=R(()=>{const{type:_,showInfo:s,size:h}=e,F=o.value;return{[F]:!0,[`${F}-inline-circle`]:_==="circle"&&we(h,"circle").width<=20,[`${F}-${_==="dashboard"&&"circle"||_}`]:!0,[`${F}-status-${d.value}`]:!0,[`${F}-show-info`]:s,[`${F}-${h}`]:h,[`${F}-rtl`]:i.value==="rtl",[l.value]:!0}}),b=R(()=>typeof e.strokeColor=="string"||Array.isArray(e.strokeColor)?e.strokeColor:void 0),m=()=>{const{showInfo:_,format:s,type:h,percent:F,title:f}=e,y=ve(e);if(!_)return null;let v;const S=s||(n==null?void 0:n.format)||(L=>`${L}%`),A=h==="line";return s||n!=null&&n.format||d.value!=="exception"&&d.value!=="success"?v=S(te(F),te(y)):d.value==="exception"?v=A?c(Lt,null,null):c(Et,null,null):d.value==="success"&&(v=A?c(Mt,null,null):c(Te,null,null)),c("span",{class:`${o.value}-text`,title:f===void 0&&typeof v=="string"?v:void 0},[v])};return()=>{const{type:_,steps:s,title:h}=e,{class:F}=r,f=Jn(r,["class"]),y=m();let v;return _==="line"?v=s?c(Hn,D(D({},e),{},{strokeColor:b.value,prefixCls:o.value,steps:s}),{default:()=>[y]}):c(Tn,D(D({},e),{},{strokeColor:u.value,prefixCls:o.value,direction:i.value}),{default:()=>[y]}):(_==="circle"||_==="dashboard")&&(v=c(Nn,D(D({},e),{},{prefixCls:o.value,strokeColor:u.value,progressStatus:d.value}),{default:()=>[y]})),a(c("div",D(D({role:"progressbar"},f),{},{class:[I.value,F],title:h}),[v]))}}}),Zn=Ut(Qn);var Kn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"};function Ze(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),r.forEach(function(o){er(e,o,n[o])})}return e}function er(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var je=function(t,n){var r=Ze({},t,n.attrs);return c(K,Ze({},r,{icon:Kn}),null)};je.displayName="DeleteOutlined";je.inheritAttrs=!1;function tr(e,t){const n=`cannot ${e.method} ${e.action} ${t.status}'`,r=new Error(n);return r.status=t.status,r.method=e.method,r.url=e.action,r}function Ke(e){const t=e.responseText||e.response;if(!t)return t;try{return JSON.parse(t)}catch{return t}}function nr(e){const t=new XMLHttpRequest;e.onProgress&&t.upload&&(t.upload.onprogress=function(i){i.total>0&&(i.percent=i.loaded/i.total*100),e.onProgress(i)});const n=new FormData;e.data&&Object.keys(e.data).forEach(o=>{const i=e.data[o];if(Array.isArray(i)){i.forEach(a=>{n.append(`${o}[]`,a)});return}n.append(o,i)}),e.file instanceof Blob?n.append(e.filename,e.file,e.file.name):n.append(e.filename,e.file),t.onerror=function(i){e.onError(i)},t.onload=function(){return t.status<200||t.status>=300?e.onError(tr(e,t),Ke(t)):e.onSuccess(Ke(t),t)},t.open(e.method,e.action,!0),e.withCredentials&&"withCredentials"in t&&(t.withCredentials=!0);const r=e.headers||{};return r["X-Requested-With"]!==null&&t.setRequestHeader("X-Requested-With","XMLHttpRequest"),Object.keys(r).forEach(o=>{r[o]!==null&&t.setRequestHeader(o,r[o])}),t.send(n),{abort(){t.abort()}}}const rr=+new Date;let or=0;function Se(){return`vc-upload-${rr}-${++or}`}const Oe=(e,t)=>{if(e&&t){const n=Array.isArray(t)?t:t.split(","),r=e.name||"",o=e.type||"",i=o.replace(/\/.*$/,"");return n.some(a=>{const l=a.trim();if(/^\*(\/\*)?$/.test(a))return!0;if(l.charAt(0)==="."){const u=r.toLowerCase(),p=l.toLowerCase();let d=[p];return(p===".jpg"||p===".jpeg")&&(d=[".jpg",".jpeg"]),d.some(I=>u.endsWith(I))}return/\/\*$/.test(l)?i===l.replace(/\/.*$/,""):!!(o===l||/^\w+$/.test(l))})}return!0};function ar(e,t){const n=e.createReader();let r=[];function o(){n.readEntries(i=>{const a=Array.prototype.slice.apply(i);r=r.concat(a),!a.length?t(r):o()})}o()}const ir=(e,t,n)=>{const r=(o,i)=>{o.path=i||"",o.isFile?o.file(a=>{n(a)&&(o.fullPath&&!a.webkitRelativePath&&(Object.defineProperties(a,{webkitRelativePath:{writable:!0}}),a.webkitRelativePath=o.fullPath.replace(/^\//,""),Object.defineProperties(a,{webkitRelativePath:{writable:!1}})),t([a]))}):o.isDirectory&&ar(o,a=>{a.forEach(l=>{r(l,`${i}${o.name}/`)})})};e.forEach(o=>{r(o.webkitGetAsEntry())})},wt=()=>({capture:[Boolean,String],multipart:{type:Boolean,default:void 0},name:String,disabled:{type:Boolean,default:void 0},componentTag:String,action:[String,Function],method:String,directory:{type:Boolean,default:void 0},data:[Object,Function],headers:Object,accept:String,multiple:{type:Boolean,default:void 0},onBatchStart:Function,onReject:Function,onStart:Function,onError:Function,onSuccess:Function,onProgress:Function,beforeUpload:Function,customRequest:Function,withCredentials:{type:Boolean,default:void 0},openFileDialogOnClick:{type:Boolean,default:void 0},prefixCls:String,id:String,onMouseenter:Function,onMouseleave:Function,onClick:Function});var lr=function(e,t,n,r){function o(i){return i instanceof n?i:new n(function(a){a(i)})}return new(n||(n=Promise))(function(i,a){function l(d){try{p(r.next(d))}catch(I){a(I)}}function u(d){try{p(r.throw(d))}catch(I){a(I)}}function p(d){d.done?i(d.value):o(d.value).then(l,u)}p((r=r.apply(e,t||[])).next())})},sr=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const cr=X({compatConfig:{MODE:3},name:"AjaxUploader",inheritAttrs:!1,props:wt(),setup(e,t){let{slots:n,attrs:r,expose:o}=t;const i=W(Se()),a={},l=W();let u=!1;const p=(f,y)=>lr(this,void 0,void 0,function*(){const{beforeUpload:v}=e;let S=f;if(v){try{S=yield v(f,y)}catch{S=!1}if(S===!1)return{origin:f,parsedFile:null,action:null,data:null}}const{action:A}=e;let L;typeof A=="function"?L=yield A(f):L=A;const{data:k}=e;let M;typeof k=="function"?M=yield k(f):M=k;const B=(typeof S=="object"||typeof S=="string")&&S?S:f;let g;B instanceof File?g=B:g=new File([B],f.name,{type:f.type});const w=g;return w.uid=f.uid,{origin:f,data:M,parsedFile:w,action:L}}),d=f=>{let{data:y,origin:v,action:S,parsedFile:A}=f;if(!u)return;const{onStart:L,customRequest:k,name:M,headers:B,withCredentials:g,method:w}=e,{uid:$}=v,C=k||nr,x={action:S,filename:M,data:y,file:A,headers:B,withCredentials:g,method:w||"post",onProgress:T=>{const{onProgress:E}=e;E==null||E(T,A)},onSuccess:(T,E)=>{const{onSuccess:j}=e;j==null||j(T,A,E),delete a[$]},onError:(T,E)=>{const{onError:j}=e;j==null||j(T,E,A),delete a[$]}};L(v),a[$]=C(x)},I=()=>{i.value=Se()},b=f=>{if(f){const y=f.uid?f.uid:f;a[y]&&a[y].abort&&a[y].abort(),delete a[y]}else Object.keys(a).forEach(y=>{a[y]&&a[y].abort&&a[y].abort(),delete a[y]})};ye(()=>{u=!0}),gt(()=>{u=!1,b()});const m=f=>{const y=[...f],v=y.map(S=>(S.uid=Se(),p(S,y)));Promise.all(v).then(S=>{const{onBatchStart:A}=e;A==null||A(S.map(L=>{let{origin:k,parsedFile:M}=L;return{file:k,parsedFile:M}})),S.filter(L=>L.parsedFile!==null).forEach(L=>{d(L)})})},_=f=>{const{accept:y,directory:v}=e,{files:S}=f.target,A=[...S].filter(L=>!v||Oe(L,y));m(A),I()},s=f=>{const y=l.value;if(!y)return;const{onClick:v}=e;y.click(),v&&v(f)},h=f=>{f.key==="Enter"&&s(f)},F=f=>{const{multiple:y}=e;if(f.preventDefault(),f.type!=="dragover")if(e.directory)ir(Array.prototype.slice.call(f.dataTransfer.items),m,v=>Oe(v,e.accept));else{const v=On(Array.prototype.slice.call(f.dataTransfer.files),L=>Oe(L,e.accept));let S=v[0];const A=v[1];y===!1&&(S=S.slice(0,1)),m(S),A.length&&e.onReject&&e.onReject(A)}};return o({abort:b}),()=>{var f;const{componentTag:y,prefixCls:v,disabled:S,id:A,multiple:L,accept:k,capture:M,directory:B,openFileDialogOnClick:g,onMouseenter:w,onMouseleave:$}=e,C=sr(e,["componentTag","prefixCls","disabled","id","multiple","accept","capture","directory","openFileDialogOnClick","onMouseenter","onMouseleave"]),x={[v]:!0,[`${v}-disabled`]:S,[r.class]:!!r.class},T=B?{directory:"directory",webkitdirectory:"webkitdirectory"}:{};return c(y,D(D({},S?{}:{onClick:g?s:()=>{},onKeydown:g?h:()=>{},onMouseenter:w,onMouseleave:$,onDrop:F,onDragover:F,tabindex:"0"}),{},{class:x,role:"button",style:r.style}),{default:()=>[c("input",D(D(D({},fn(C,{aria:!0,data:!0})),{},{id:A,type:"file",ref:l,onClick:j=>j.stopPropagation(),onCancel:j=>j.stopPropagation(),key:i.value,style:{display:"none"},accept:k},T),{},{multiple:L,onChange:_},M!=null?{capture:M}:{}),null),(f=n.default)===null||f===void 0?void 0:f.call(n)]})}}});function xe(){}const et=X({compatConfig:{MODE:3},name:"Upload",inheritAttrs:!1,props:re(wt(),{componentTag:"span",prefixCls:"rc-upload",data:{},headers:{},name:"file",multipart:!1,onStart:xe,onError:xe,onSuccess:xe,multiple:!1,beforeUpload:null,customRequest:null,withCredentials:!1,openFileDialogOnClick:!0}),setup(e,t){let{slots:n,attrs:r,expose:o}=t;const i=W();return o({abort:l=>{var u;(u=i.value)===null||u===void 0||u.abort(l)}}),()=>c(cr,D(D(D({},e),r),{},{ref:i}),n)}});var ur={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M779.3 196.6c-94.2-94.2-247.6-94.2-341.7 0l-261 260.8c-1.7 1.7-2.6 4-2.6 6.4s.9 4.7 2.6 6.4l36.9 36.9a9 9 0 0012.7 0l261-260.8c32.4-32.4 75.5-50.2 121.3-50.2s88.9 17.8 121.2 50.2c32.4 32.4 50.2 75.5 50.2 121.2 0 45.8-17.8 88.8-50.2 121.2l-266 265.9-43.1 43.1c-40.3 40.3-105.8 40.3-146.1 0-19.5-19.5-30.2-45.4-30.2-73s10.7-53.5 30.2-73l263.9-263.8c6.7-6.6 15.5-10.3 24.9-10.3h.1c9.4 0 18.1 3.7 24.7 10.3 6.7 6.7 10.3 15.5 10.3 24.9 0 9.3-3.7 18.1-10.3 24.7L372.4 653c-1.7 1.7-2.6 4-2.6 6.4s.9 4.7 2.6 6.4l36.9 36.9a9 9 0 0012.7 0l215.6-215.6c19.9-19.9 30.8-46.3 30.8-74.4s-11-54.6-30.8-74.4c-41.1-41.1-107.9-41-149 0L463 364 224.8 602.1A172.22 172.22 0 00174 724.8c0 46.3 18.1 89.8 50.8 122.5 33.9 33.8 78.3 50.7 122.7 50.7 44.4 0 88.8-16.9 122.6-50.7l309.2-309C824.8 492.7 850 432 850 367.5c.1-64.6-25.1-125.3-70.7-170.9z"}}]},name:"paper-clip",theme:"outlined"};function tt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),r.forEach(function(o){dr(e,o,n[o])})}return e}function dr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ae=function(t,n){var r=tt({},t,n.attrs);return c(K,tt({},r,{icon:ur}),null)};Ae.displayName="PaperClipOutlined";Ae.inheritAttrs=!1;var pr={icon:function(t,n){return{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M928 160H96c-17.7 0-32 14.3-32 32v640c0 17.7 14.3 32 32 32h832c17.7 0 32-14.3 32-32V192c0-17.7-14.3-32-32-32zm-40 632H136v-39.9l138.5-164.3 150.1 178L658.1 489 888 761.6V792zm0-129.8L664.2 396.8c-3.2-3.8-9-3.8-12.2 0L424.6 666.4l-144-170.7c-3.2-3.8-9-3.8-12.2 0L136 652.7V232h752v430.2z",fill:t}},{tag:"path",attrs:{d:"M424.6 765.8l-150.1-178L136 752.1V792h752v-30.4L658.1 489z",fill:n}},{tag:"path",attrs:{d:"M136 652.7l132.4-157c3.2-3.8 9-3.8 12.2 0l144 170.7L652 396.8c3.2-3.8 9-3.8 12.2 0L888 662.2V232H136v420.7zM304 280a88 88 0 110 176 88 88 0 010-176z",fill:n}},{tag:"path",attrs:{d:"M276 368a28 28 0 1056 0 28 28 0 10-56 0z",fill:n}},{tag:"path",attrs:{d:"M304 456a88 88 0 100-176 88 88 0 000 176zm0-116c15.5 0 28 12.5 28 28s-12.5 28-28 28-28-12.5-28-28 12.5-28 28-28z",fill:t}}]}},name:"picture",theme:"twotone"};function nt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),r.forEach(function(o){fr(e,o,n[o])})}return e}function fr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Le=function(t,n){var r=nt({},t,n.attrs);return c(K,nt({},r,{icon:pr}),null)};Le.displayName="PictureTwoTone";Le.inheritAttrs=!1;var gr={icon:function(t,n){return{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M534 352V136H232v752h560V394H576a42 42 0 01-42-42z",fill:n}},{tag:"path",attrs:{d:"M854.6 288.6L639.4 73.4c-6-6-14.1-9.4-22.6-9.4H192c-17.7 0-32 14.3-32 32v832c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V311.3c0-8.5-3.4-16.7-9.4-22.7zM602 137.8L790.2 326H602V137.8zM792 888H232V136h302v216a42 42 0 0042 42h216v494z",fill:t}}]}},name:"file",theme:"twotone"};function rt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),r.forEach(function(o){mr(e,o,n[o])})}return e}function mr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ee=function(t,n){var r=rt({},t,n.attrs);return c(K,rt({},r,{icon:gr}),null)};Ee.displayName="FileTwoTone";Ee.inheritAttrs=!1;function $t(){return{capture:ee([Boolean,String]),type:z(),name:String,defaultFileList:me(),fileList:me(),action:ee([String,Function]),directory:N(),data:ee([Object,Function]),method:z(),headers:Y(),showUploadList:ee([Boolean,Object]),multiple:N(),accept:String,beforeUpload:P(),onChange:P(),"onUpdate:fileList":P(),onDrop:P(),listType:z(),onPreview:P(),onDownload:P(),onReject:P(),onRemove:P(),remove:P(),supportServerRender:N(),disabled:N(),prefixCls:String,customRequest:P(),withCredentials:N(),openFileDialogOnClick:N(),locale:Y(),id:String,previewFile:P(),transformFile:P(),iconRender:P(),isImageUrl:P(),progress:Y(),itemRender:P(),maxCount:Number,height:ee([Number,String]),removeIcon:P(),downloadIcon:P(),previewIcon:P()}}function vr(){return{listType:z(),onPreview:P(),onDownload:P(),onRemove:P(),items:me(),progress:Y(),prefixCls:z(),showRemoveIcon:N(),showDownloadIcon:N(),showPreviewIcon:N(),removeIcon:P(),downloadIcon:P(),previewIcon:P(),locale:Y(void 0),previewFile:P(),iconRender:P(),isImageUrl:P(),appendAction:P(),appendActionVisible:N(),itemRender:P()}}function ue(e){return O(O({},e),{lastModified:e.lastModified,lastModifiedDate:e.lastModifiedDate,name:e.name,size:e.size,type:e.type,uid:e.uid,percent:0,originFileObj:e})}function de(e,t){const n=[...t],r=n.findIndex(o=>{let{uid:i}=o;return i===e.uid});return r===-1?n.push(e):n[r]=e,n}function Pe(e,t){const n=e.uid!==void 0?"uid":"name";return t.filter(r=>r[n]===e[n])[0]}function hr(e,t){const n=e.uid!==void 0?"uid":"name",r=t.filter(o=>o[n]!==e[n]);return r.length===t.length?null:r}const yr=function(){const t=(arguments.length>0&&arguments[0]!==void 0?arguments[0]:"").split("/"),r=t[t.length-1].split(/#|\?/)[0];return(/\.[^./\\]*$/.exec(r)||[""])[0]},Ct=e=>e.indexOf("image/")===0,br=e=>{if(e.type&&!e.thumbUrl)return Ct(e.type);const t=e.thumbUrl||e.url||"",n=yr(t);return/^data:image\//.test(t)||/(webp|svg|png|gif|jpg|jpeg|jfif|bmp|dpg|ico)$/i.test(n)?!0:!(/^data:/.test(t)||n)},Z=200;function wr(e){return new Promise(t=>{if(!e.type||!Ct(e.type)){t("");return}const n=document.createElement("canvas");n.width=Z,n.height=Z,n.style.cssText=`position: fixed; left: 0; top: 0; width: ${Z}px; height: ${Z}px; z-index: 9999; display: none;`,document.body.appendChild(n);const r=n.getContext("2d"),o=new Image;if(o.onload=()=>{const{width:i,height:a}=o;let l=Z,u=Z,p=0,d=0;i>a?(u=a*(Z/i),d=-(u-l)/2):(l=i*(Z/a),p=-(l-u)/2),r.drawImage(o,p,d,l,u);const I=n.toDataURL();document.body.removeChild(n),t(I)},o.crossOrigin="anonymous",e.type.startsWith("image/svg+xml")){const i=new FileReader;i.addEventListener("load",()=>{i.result&&(o.src=i.result)}),i.readAsDataURL(e)}else o.src=window.URL.createObjectURL(e)})}var $r={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M505.7 661a8 8 0 0012.6 0l112-141.7c4.1-5.2.4-12.9-6.3-12.9h-74.1V168c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v338.3H400c-6.7 0-10.4 7.7-6.3 12.9l112 141.8zM878 626h-60c-4.4 0-8 3.6-8 8v154H214V634c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v198c0 17.7 14.3 32 32 32h684c17.7 0 32-14.3 32-32V634c0-4.4-3.6-8-8-8z"}}]},name:"download",theme:"outlined"};function ot(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),r.forEach(function(o){Cr(e,o,n[o])})}return e}function Cr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Me=function(t,n){var r=ot({},t,n.attrs);return c(K,ot({},r,{icon:$r}),null)};Me.displayName="DownloadOutlined";Me.inheritAttrs=!1;const Sr=()=>({prefixCls:String,locale:Y(void 0),file:Y(),items:me(),listType:z(),isImgUrl:P(),showRemoveIcon:N(),showDownloadIcon:N(),showPreviewIcon:N(),removeIcon:P(),downloadIcon:P(),previewIcon:P(),iconRender:P(),actionIconRender:P(),itemRender:P(),onPreview:P(),onClose:P(),onDownload:P(),progress:Y()}),Or=X({compatConfig:{MODE:3},name:"ListItem",inheritAttrs:!1,props:Sr(),setup(e,t){let{slots:n,attrs:r}=t;var o;const i=ce(!1),a=ce();ye(()=>{a.value=setTimeout(()=>{i.value=!0},300)}),gt(()=>{clearTimeout(a.value)});const l=ce((o=e.file)===null||o===void 0?void 0:o.status);mt(()=>{var d;return(d=e.file)===null||d===void 0?void 0:d.status},d=>{d!=="removed"&&(l.value=d)});const{rootPrefixCls:u}=he("upload",e),p=R(()=>kt(`${u.value}-fade`));return()=>{var d,I;const{prefixCls:b,locale:m,listType:_,file:s,items:h,progress:F,iconRender:f=n.iconRender,actionIconRender:y=n.actionIconRender,itemRender:v=n.itemRender,isImgUrl:S,showPreviewIcon:A,showRemoveIcon:L,showDownloadIcon:k,previewIcon:M=n.previewIcon,removeIcon:B=n.removeIcon,downloadIcon:g=n.downloadIcon,onPreview:w,onDownload:$,onClose:C}=e,{class:x,style:T}=r,E=f({file:s});let j=c("div",{class:`${b}-text-icon`},[E]);if(_==="picture"||_==="picture-card")if(l.value==="uploading"||!s.thumbUrl&&!s.url){const H={[`${b}-list-item-thumbnail`]:!0,[`${b}-list-item-file`]:l.value!=="uploading"};j=c("div",{class:H},[E])}else{const H=S!=null&&S(s)?c("img",{src:s.thumbUrl||s.url,alt:s.name,class:`${b}-list-item-image`,crossorigin:s.crossOrigin},null):E,It={[`${b}-list-item-thumbnail`]:!0,[`${b}-list-item-file`]:S&&!S(s)};j=c("a",{class:It,onClick:Dt=>w(s,Dt),href:s.url||s.thumbUrl,target:"_blank",rel:"noopener noreferrer"},[H])}const U={[`${b}-list-item`]:!0,[`${b}-list-item-${l.value}`]:!0},J=typeof s.linkProps=="string"?JSON.parse(s.linkProps):s.linkProps,ne=L?y({customIcon:B?B({file:s}):c(je,null,null),callback:()=>C(s),prefixCls:b,title:m.removeFile}):null,V=k&&l.value==="done"?y({customIcon:g?g({file:s}):c(Me,null,null),callback:()=>$(s),prefixCls:b,title:m.downloadFile}):null,G=_!=="picture-card"&&c("span",{key:"download-delete",class:[`${b}-list-item-actions`,{picture:_==="picture"}]},[V,ne]),Q=`${b}-list-item-name`,oe=s.url?[c("a",D(D({key:"view",target:"_blank",rel:"noopener noreferrer",class:Q,title:s.name},J),{},{href:s.url,onClick:H=>w(s,H)}),[s.name]),G]:[c("span",{key:"view",class:Q,onClick:H=>w(s,H),title:s.name},[s.name]),G],$e={pointerEvents:"none",opacity:.5},St=A?c("a",{href:s.url||s.thumbUrl,target:"_blank",rel:"noopener noreferrer",style:s.url||s.thumbUrl?void 0:$e,onClick:H=>w(s,H),title:m.previewFile},[M?M({file:s}):c(Bt,null,null)]):null,Ot=_==="picture-card"&&l.value!=="uploading"&&c("span",{class:`${b}-list-item-actions`},[St,l.value==="done"&&V,ne]),Be=c("div",{class:U},[j,oe,Ot,i.value&&c(Nt,p.value,{default:()=>[vt(c("div",{class:`${b}-list-item-progress`},["percent"in s?c(Zn,D(D({},F),{},{type:"line",percent:s.percent}),null):null]),[[ht,l.value==="uploading"]])]})]),xt={[`${b}-list-item-container`]:!0,[`${x}`]:!!x},Pt=s.response&&typeof s.response=="string"?s.response:((d=s.error)===null||d===void 0?void 0:d.statusText)||((I=s.error)===null||I===void 0?void 0:I.message)||m.uploadError,Ne=l.value==="error"?c(ut,{title:Pt,getPopupContainer:H=>H.parentNode},{default:()=>[Be]}):Be;return c("div",{class:xt,style:T},[v?v({originNode:Ne,file:s,fileList:h,actions:{download:$.bind(null,s),preview:w.bind(null,s),remove:C.bind(null,s)}}):Ne])}}}),xr=(e,t)=>{let{slots:n}=t;var r;return qt((r=n.default)===null||r===void 0?void 0:r.call(n))[0]},Pr=X({compatConfig:{MODE:3},name:"AUploadList",props:re(vr(),{listType:"text",progress:{strokeWidth:2,showInfo:!1},showRemoveIcon:!0,showDownloadIcon:!1,showPreviewIcon:!0,previewFile:wr,isImageUrl:br,items:[],appendActionVisible:!0}),setup(e,t){let{slots:n,expose:r}=t;const o=ce(!1);ye(()=>{o.value==!0});const i=ce([]);mt(()=>e.items,function(){let s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];i.value=s.slice()},{immediate:!0,deep:!0}),zt(()=>{if(e.listType!=="picture"&&e.listType!=="picture-card")return;let s=!1;(e.items||[]).forEach((h,F)=>{typeof document>"u"||typeof window>"u"||!window.FileReader||!window.File||!(h.originFileObj instanceof File||h.originFileObj instanceof Blob)||h.thumbUrl!==void 0||(h.thumbUrl="",e.previewFile&&e.previewFile(h.originFileObj).then(f=>{const y=f||"";y!==h.thumbUrl&&(i.value[F].thumbUrl=y,s=!0)}))}),s&&Vt(i)});const a=(s,h)=>{if(e.onPreview)return h==null||h.preventDefault(),e.onPreview(s)},l=s=>{typeof e.onDownload=="function"?e.onDownload(s):s.url&&window.open(s.url)},u=s=>{var h;(h=e.onRemove)===null||h===void 0||h.call(e,s)},p=s=>{let{file:h}=s;const F=e.iconRender||n.iconRender;if(F)return F({file:h,listType:e.listType});const f=h.status==="uploading",y=e.isImageUrl&&e.isImageUrl(h)?c(Le,null,null):c(Ee,null,null);let v=f?c(ze,null,null):c(Ae,null,null);return e.listType==="picture"?v=f?c(ze,null,null):y:e.listType==="picture-card"&&(v=f?e.locale.uploading:y),v},d=s=>{const{customIcon:h,callback:F,prefixCls:f,title:y}=s,v={type:"text",size:"small",title:y,onClick:()=>{F()},class:`${f}-list-item-action`};return Gt(h)?c(_e,v,{icon:()=>h}):c(_e,v,{default:()=>[c("span",null,[h])]})};r({handlePreview:a,handleDownload:l});const{prefixCls:I,rootPrefixCls:b}=he("upload",e),m=R(()=>({[`${I.value}-list`]:!0,[`${I.value}-list-${e.listType}`]:!0})),_=R(()=>{const s=O({},Ht(`${b.value}-motion-collapse`));delete s.onAfterAppear,delete s.onAfterEnter,delete s.onAfterLeave;const h=O(O({},Wt(`${I.value}-${e.listType==="picture-card"?"animate-inline":"animate"}`)),{class:m.value,appear:o.value});return e.listType!=="picture-card"?O(O({},s),h):h});return()=>{const{listType:s,locale:h,isImageUrl:F,showPreviewIcon:f,showRemoveIcon:y,showDownloadIcon:v,removeIcon:S,previewIcon:A,downloadIcon:L,progress:k,appendAction:M,itemRender:B,appendActionVisible:g}=e,w=M==null?void 0:M(),$=i.value;return c(Xt,D(D({},_.value),{},{tag:"div"}),{default:()=>[$.map(C=>{const{uid:x}=C;return c(Or,{key:x,locale:h,prefixCls:I.value,file:C,items:$,progress:k,listType:s,isImgUrl:F,showPreviewIcon:f,showRemoveIcon:y,showDownloadIcon:v,onPreview:a,onDownload:l,onClose:u,removeIcon:S,previewIcon:A,downloadIcon:L,itemRender:B},O(O({},n),{iconRender:p,actionIconRender:d}))}),M?vt(c(xr,{key:"__ant_upload_appendAction"},{default:()=>w}),[[ht,!!g]]):null]})}}}),Ir=e=>{const{componentCls:t,iconCls:n}=e;return{[`${t}-wrapper`]:{[`${t}-drag`]:{position:"relative",width:"100%",height:"100%",textAlign:"center",background:e.colorFillAlter,border:`${e.lineWidth}px dashed ${e.colorBorder}`,borderRadius:e.borderRadiusLG,cursor:"pointer",transition:`border-color ${e.motionDurationSlow}`,[t]:{padding:`${e.padding}px 0`},[`${t}-btn`]:{display:"table",width:"100%",height:"100%",outline:"none"},[`${t}-drag-container`]:{display:"table-cell",verticalAlign:"middle"},[`&:not(${t}-disabled):hover`]:{borderColor:e.colorPrimaryHover},[`p${t}-drag-icon`]:{marginBottom:e.margin,[n]:{color:e.colorPrimary,fontSize:e.uploadThumbnailSize}},[`p${t}-text`]:{margin:`0 0 ${e.marginXXS}px`,color:e.colorTextHeading,fontSize:e.fontSizeLG},[`p${t}-hint`]:{color:e.colorTextDescription,fontSize:e.fontSize},[`&${t}-disabled`]:{cursor:"not-allowed",[`p${t}-drag-icon ${n},
- p${t}-text,
- p${t}-hint
- `]:{color:e.colorTextDisabled}}}}}},Dr=e=>{const{componentCls:t,antCls:n,iconCls:r,fontSize:o,lineHeight:i}=e,a=`${t}-list-item`,l=`${a}-actions`,u=`${a}-action`,p=Math.round(o*i);return{[`${t}-wrapper`]:{[`${t}-list`]:O(O({},yt()),{lineHeight:e.lineHeight,[a]:{position:"relative",height:e.lineHeight*o,marginTop:e.marginXS,fontSize:o,display:"flex",alignItems:"center",transition:`background-color ${e.motionDurationSlow}`,"&:hover":{backgroundColor:e.controlItemBgHover},[`${a}-name`]:O(O({},bt),{padding:`0 ${e.paddingXS}px`,lineHeight:i,flex:"auto",transition:`all ${e.motionDurationSlow}`}),[l]:{[u]:{opacity:0},[`${u}${n}-btn-sm`]:{height:p,border:0,lineHeight:1,"> span":{transform:"scale(1)"}},[`
- ${u}:focus,
- &.picture ${u}
- `]:{opacity:1},[r]:{color:e.colorTextDescription,transition:`all ${e.motionDurationSlow}`},[`&:hover ${r}`]:{color:e.colorText}},[`${t}-icon ${r}`]:{color:e.colorTextDescription,fontSize:o},[`${a}-progress`]:{position:"absolute",bottom:-e.uploadProgressOffset,width:"100%",paddingInlineStart:o+e.paddingXS,fontSize:o,lineHeight:0,pointerEvents:"none","> div":{margin:0}}},[`${a}:hover ${u}`]:{opacity:1,color:e.colorText},[`${a}-error`]:{color:e.colorError,[`${a}-name, ${t}-icon ${r}`]:{color:e.colorError},[l]:{[`${r}, ${r}:hover`]:{color:e.colorError},[u]:{opacity:1}}},[`${t}-list-item-container`]:{transition:`opacity ${e.motionDurationSlow}, height ${e.motionDurationSlow}`,"&::before":{display:"table",width:0,height:0,content:'""'}}})}}},at=new Re("uploadAnimateInlineIn",{from:{width:0,height:0,margin:0,padding:0,opacity:0}}),it=new Re("uploadAnimateInlineOut",{to:{width:0,height:0,margin:0,padding:0,opacity:0}}),_r=e=>{const{componentCls:t}=e,n=`${t}-animate-inline`;return[{[`${t}-wrapper`]:{[`${n}-appear, ${n}-enter, ${n}-leave`]:{animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseInOutCirc,animationFillMode:"forwards"},[`${n}-appear, ${n}-enter`]:{animationName:at},[`${n}-leave`]:{animationName:it}}},at,it]},Fr=e=>{const{componentCls:t,iconCls:n,uploadThumbnailSize:r,uploadProgressOffset:o}=e,i=`${t}-list`,a=`${i}-item`;return{[`${t}-wrapper`]:{[`${i}${i}-picture, ${i}${i}-picture-card`]:{[a]:{position:"relative",height:r+e.lineWidth*2+e.paddingXS*2,padding:e.paddingXS,border:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusLG,"&:hover":{background:"transparent"},[`${a}-thumbnail`]:O(O({},bt),{width:r,height:r,lineHeight:`${r+e.paddingSM}px`,textAlign:"center",flex:"none",[n]:{fontSize:e.fontSizeHeading2,color:e.colorPrimary},img:{display:"block",width:"100%",height:"100%",overflow:"hidden"}}),[`${a}-progress`]:{bottom:o,width:`calc(100% - ${e.paddingSM*2}px)`,marginTop:0,paddingInlineStart:r+e.paddingXS}},[`${a}-error`]:{borderColor:e.colorError,[`${a}-thumbnail ${n}`]:{"svg path[fill='#e6f7ff']":{fill:e.colorErrorBg},"svg path[fill='#1890ff']":{fill:e.colorError}}},[`${a}-uploading`]:{borderStyle:"dashed",[`${a}-name`]:{marginBottom:o}}}}}},Rr=e=>{const{componentCls:t,iconCls:n,fontSizeLG:r,colorTextLightSolid:o}=e,i=`${t}-list`,a=`${i}-item`,l=e.uploadPicCardSize;return{[`${t}-wrapper${t}-picture-card-wrapper`]:O(O({},yt()),{display:"inline-block",width:"100%",[`${t}${t}-select`]:{width:l,height:l,marginInlineEnd:e.marginXS,marginBottom:e.marginXS,textAlign:"center",verticalAlign:"top",backgroundColor:e.colorFillAlter,border:`${e.lineWidth}px dashed ${e.colorBorder}`,borderRadius:e.borderRadiusLG,cursor:"pointer",transition:`border-color ${e.motionDurationSlow}`,[`> ${t}`]:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%",textAlign:"center"},[`&:not(${t}-disabled):hover`]:{borderColor:e.colorPrimary}},[`${i}${i}-picture-card`]:{[`${i}-item-container`]:{display:"inline-block",width:l,height:l,marginBlock:`0 ${e.marginXS}px`,marginInline:`0 ${e.marginXS}px`,verticalAlign:"top"},"&::after":{display:"none"},[a]:{height:"100%",margin:0,"&::before":{position:"absolute",zIndex:1,width:`calc(100% - ${e.paddingXS*2}px)`,height:`calc(100% - ${e.paddingXS*2}px)`,backgroundColor:e.colorBgMask,opacity:0,transition:`all ${e.motionDurationSlow}`,content:'" "'}},[`${a}:hover`]:{[`&::before, ${a}-actions`]:{opacity:1}},[`${a}-actions`]:{position:"absolute",insetInlineStart:0,zIndex:10,width:"100%",whiteSpace:"nowrap",textAlign:"center",opacity:0,transition:`all ${e.motionDurationSlow}`,[`${n}-eye, ${n}-download, ${n}-delete`]:{zIndex:10,width:r,margin:`0 ${e.marginXXS}px`,fontSize:r,cursor:"pointer",transition:`all ${e.motionDurationSlow}`}},[`${a}-actions, ${a}-actions:hover`]:{[`${n}-eye, ${n}-download, ${n}-delete`]:{color:new Yt(o).setAlpha(.65).toRgbString(),"&:hover":{color:o}}},[`${a}-thumbnail, ${a}-thumbnail img`]:{position:"static",display:"block",width:"100%",height:"100%",objectFit:"contain"},[`${a}-name`]:{display:"none",textAlign:"center"},[`${a}-file + ${a}-name`]:{position:"absolute",bottom:e.margin,display:"block",width:`calc(100% - ${e.paddingXS*2}px)`},[`${a}-uploading`]:{[`&${a}`]:{backgroundColor:e.colorFillAlter},[`&::before, ${n}-eye, ${n}-download, ${n}-delete`]:{display:"none"}},[`${a}-progress`]:{bottom:e.marginXL,width:`calc(100% - ${e.paddingXS*2}px)`,paddingInlineStart:0}}})}},Tr=e=>{const{componentCls:t}=e;return{[`${t}-rtl`]:{direction:"rtl"}}},jr=e=>{const{componentCls:t,colorTextDisabled:n}=e;return{[`${t}-wrapper`]:O(O({},ft(e)),{[t]:{outline:0,"input[type='file']":{cursor:"pointer"}},[`${t}-select`]:{display:"inline-block"},[`${t}-disabled`]:{color:n,cursor:"not-allowed"}})}},Ar=dt("Upload",e=>{const{fontSizeHeading3:t,fontSize:n,lineHeight:r,lineWidth:o,controlHeightLG:i}=e,a=Math.round(n*r),l=pt(e,{uploadThumbnailSize:t*2,uploadProgressOffset:a/2+o,uploadPicCardSize:i*2.55});return[jr(l),Ir(l),Fr(l),Rr(l),Dr(l),_r(l),Tr(l),Jt(l)]});var Lr=function(e,t,n,r){function o(i){return i instanceof n?i:new n(function(a){a(i)})}return new(n||(n=Promise))(function(i,a){function l(d){try{p(r.next(d))}catch(I){a(I)}}function u(d){try{p(r.throw(d))}catch(I){a(I)}}function p(d){d.done?i(d.value):o(d.value).then(l,u)}p((r=r.apply(e,t||[])).next())})},Er=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const se=`__LIST_IGNORE_${Date.now()}__`,fe=X({compatConfig:{MODE:3},name:"AUpload",inheritAttrs:!1,props:re($t(),{type:"select",multiple:!1,action:"",data:{},accept:"",showUploadList:!0,listType:"text",supportServerRender:!0}),setup(e,t){let{slots:n,attrs:r,expose:o}=t;const i=Qt(),{prefixCls:a,direction:l,disabled:u}=he("upload",e),[p,d]=Ar(a),I=Zt(),b=R(()=>{var g;return(g=u.value)!==null&&g!==void 0?g:I.value}),[m,_]=Kt(e.defaultFileList||[],{value:en(e,"fileList"),postState:g=>{const w=Date.now();return(g??[]).map(($,C)=>(!$.uid&&!Object.isFrozen($)&&($.uid=`__AUTO__${w}_${C}__`),$))}}),s=W("drop"),h=W(null);ye(()=>{pe(e.fileList!==void 0||r.value===void 0,"Upload","`value` is not a valid prop, do you mean `fileList`?"),pe(e.transformFile===void 0,"Upload","`transformFile` is deprecated. Please use `beforeUpload` directly."),pe(e.remove===void 0,"Upload","`remove` props is deprecated. Please use `remove` event.")});const F=(g,w,$)=>{var C,x;let T=[...w];e.maxCount===1?T=T.slice(-1):e.maxCount&&(T=T.slice(0,e.maxCount)),_(T);const E={file:g,fileList:T};$&&(E.event=$),(C=e["onUpdate:fileList"])===null||C===void 0||C.call(e,E.fileList),(x=e.onChange)===null||x===void 0||x.call(e,E),i.onFieldChange()},f=(g,w)=>Lr(this,void 0,void 0,function*(){const{beforeUpload:$,transformFile:C}=e;let x=g;if($){const T=yield $(g,w);if(T===!1)return!1;if(delete g[se],T===se)return Object.defineProperty(g,se,{value:!0,configurable:!0}),!1;typeof T=="object"&&T&&(x=T)}return C&&(x=yield C(x)),x}),y=g=>{const w=g.filter(x=>!x.file[se]);if(!w.length)return;const $=w.map(x=>ue(x.file));let C=[...m.value];$.forEach(x=>{C=de(x,C)}),$.forEach((x,T)=>{let E=x;if(w[T].parsedFile)x.status="uploading";else{const{originFileObj:j}=x;let U;try{U=new File([j],j.name,{type:j.type})}catch{U=new Blob([j],{type:j.type}),U.name=j.name,U.lastModifiedDate=new Date,U.lastModified=new Date().getTime()}U.uid=x.uid,E=U}F(E,C)})},v=(g,w,$)=>{try{typeof g=="string"&&(g=JSON.parse(g))}catch{}if(!Pe(w,m.value))return;const C=ue(w);C.status="done",C.percent=100,C.response=g,C.xhr=$;const x=de(C,m.value);F(C,x)},S=(g,w)=>{if(!Pe(w,m.value))return;const $=ue(w);$.status="uploading",$.percent=g.percent;const C=de($,m.value);F($,C,g)},A=(g,w,$)=>{if(!Pe($,m.value))return;const C=ue($);C.error=g,C.response=w,C.status="error";const x=de(C,m.value);F(C,x)},L=g=>{let w;const $=e.onRemove||e.remove;Promise.resolve(typeof $=="function"?$(g):$).then(C=>{var x,T;if(C===!1)return;const E=hr(g,m.value);E&&(w=O(O({},g),{status:"removed"}),(x=m.value)===null||x===void 0||x.forEach(j=>{const U=w.uid!==void 0?"uid":"name";j[U]===w[U]&&!Object.isFrozen(j)&&(j.status="removed")}),(T=h.value)===null||T===void 0||T.abort(w),F(w,E))})},k=g=>{var w;s.value=g.type,g.type==="drop"&&((w=e.onDrop)===null||w===void 0||w.call(e,g))};o({onBatchStart:y,onSuccess:v,onProgress:S,onError:A,fileList:m,upload:h});const[M]=tn("Upload",nn.Upload,R(()=>e.locale)),B=(g,w)=>{const{removeIcon:$,previewIcon:C,downloadIcon:x,previewFile:T,onPreview:E,onDownload:j,isImageUrl:U,progress:J,itemRender:ne,iconRender:V,showUploadList:G}=e,{showDownloadIcon:Q,showPreviewIcon:oe,showRemoveIcon:$e}=typeof G=="boolean"?{}:G;return G?c(Pr,{prefixCls:a.value,listType:e.listType,items:m.value,previewFile:T,onPreview:E,onDownload:j,onRemove:L,showRemoveIcon:!b.value&&$e,showPreviewIcon:oe,showDownloadIcon:Q,removeIcon:$,previewIcon:C,downloadIcon:x,iconRender:V,locale:M.value,isImageUrl:U,progress:J,itemRender:ne,appendActionVisible:w,appendAction:g},O({},n)):g==null?void 0:g()};return()=>{var g,w,$;const{listType:C,type:x}=e,{class:T,style:E}=r,j=Er(r,["class","style"]),U=O(O(O({onBatchStart:y,onError:A,onProgress:S,onSuccess:v},j),e),{id:(g=e.id)!==null&&g!==void 0?g:i.id.value,prefixCls:a.value,beforeUpload:f,onChange:void 0,disabled:b.value});delete U.remove,(!n.default||b.value)&&delete U.id;const J={[`${a.value}-rtl`]:l.value==="rtl"};if(x==="drag"){const Q=ae(a.value,{[`${a.value}-drag`]:!0,[`${a.value}-drag-uploading`]:m.value.some(oe=>oe.status==="uploading"),[`${a.value}-drag-hover`]:s.value==="dragover",[`${a.value}-disabled`]:b.value,[`${a.value}-rtl`]:l.value==="rtl"},r.class,d.value);return p(c("span",D(D({},r),{},{class:ae(`${a.value}-wrapper`,J,T,d.value)}),[c("div",{class:Q,onDrop:k,onDragover:k,onDragleave:k,style:r.style},[c(et,D(D({},U),{},{ref:h,class:`${a.value}-btn`}),D({default:()=>[c("div",{class:`${a.value}-drag-container`},[(w=n.default)===null||w===void 0?void 0:w.call(n)])]},n))]),B()]))}const ne=ae(a.value,{[`${a.value}-select`]:!0,[`${a.value}-select-${C}`]:!0,[`${a.value}-disabled`]:b.value,[`${a.value}-rtl`]:l.value==="rtl"}),V=rn(($=n.default)===null||$===void 0?void 0:$.call(n)),G=Q=>c("div",{class:ne,style:Q},[c(et,D(D({},U),{},{ref:h}),n)]);return p(C==="picture-card"?c("span",D(D({},r),{},{class:ae(`${a.value}-wrapper`,`${a.value}-picture-card-wrapper`,J,r.class,d.value)}),[B(G,!!(V&&V.length))]):c("span",D(D({},r),{},{class:ae(`${a.value}-wrapper`,J,r.class,d.value)}),[G(V&&V.length?void 0:{display:"none"}),B()]))}}});var lt=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};const Ie=X({compatConfig:{MODE:3},name:"AUploadDragger",inheritAttrs:!1,props:$t(),setup(e,t){let{slots:n,attrs:r}=t;return()=>{const{height:o}=e,i=lt(e,["height"]),{style:a}=r,l=lt(r,["style"]),u=O(O(O({},i),l),{type:"drag",style:O(O({},a),{height:typeof o=="number"?`${o}px`:o})});return c(fe,u,n)}}}),Mr=O(fe,{Dragger:Ie,LIST_IGNORE:se,install(e){return e.component(fe.name,fe),e.component(Ie.name,Ie),e}});var Ur={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"defs",attrs:{},children:[{tag:"style",attrs:{}}]},{tag:"path",attrs:{d:"M931.4 498.9L94.9 79.5c-3.4-1.7-7.3-2.1-11-1.2a15.99 15.99 0 00-11.7 19.3l86.2 352.2c1.3 5.3 5.2 9.6 10.4 11.3l147.7 50.7-147.6 50.7c-5.2 1.8-9.1 6-10.3 11.3L72.2 926.5c-.9 3.7-.5 7.6 1.2 10.9 3.9 7.9 13.5 11.1 21.5 7.2l836.5-417c3.1-1.5 5.6-4.1 7.2-7.1 3.9-8 .7-17.6-7.2-21.6zM170.8 826.3l50.3-205.6 295.2-101.3c2.3-.8 4.2-2.6 5-5 1.4-4.2-.8-8.7-5-10.2L221.1 403 171 198.2l628 314.9-628.2 313.2z"}}]},name:"send",theme:"outlined"};function st(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),r.forEach(function(o){kr(e,o,n[o])})}return e}function kr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ue=function(t,n){var r=st({},t,n.attrs);return c(K,st({},r,{icon:Ur}),null)};Ue.displayName="SendOutlined";Ue.inheritAttrs=!1;var Br={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M400 317.7h73.9V656c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V317.7H624c6.7 0 10.4-7.7 6.3-12.9L518.3 163a8 8 0 00-12.6 0l-112 141.7c-4.1 5.3-.4 13 6.3 13zM878 626h-60c-4.4 0-8 3.6-8 8v154H214V634c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v198c0 17.7 14.3 32 32 32h684c17.7 0 32-14.3 32-32V634c0-4.4-3.6-8-8-8z"}}]},name:"upload",theme:"outlined"};function ct(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable}))),r.forEach(function(o){Nr(e,o,n[o])})}return e}function Nr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var ke=function(t,n){var r=ct({},t,n.attrs);return c(K,ct({},r,{icon:Br}),null)};ke.displayName="UploadOutlined";ke.inheritAttrs=!1;const zr={components:{UploadOutlined:ke,SendOutlined:Ue},setup(){const e=W([{id:1,avatar:"https://via.placeholder.com/40",name:"Alice",lastMessageTime:"10:30 AM"},{id:2,avatar:"https://via.placeholder.com/40",name:"Bob",lastMessageTime:"11:00 AM"}]),t=W([]),n=W(""),r=W(null);return{contacts:e,messages:t,inputMessage:n,selectedContactId:r,selectContact:l=>{r.value=l,t.value=[{id:1,text:"Hello Bob!",sentByUser:!1},{id:2,text:"Hi Alice!",sentByUser:!0}]},sendMessage:()=>{n.value.trim()&&(t.value.push({id:t.value.length+1,text:n.value,sentByUser:!0}),n.value="")},handleFileUpload:l=>(console.log("File uploaded:",l.name),n.value+=` [File: ${l.name}]`,!1)}}},Hr={class:"chat-container"},Wr={class:"sidebar"},Xr={class:"contact-list"},Vr=["onClick"],Gr=["src"],qr={class:"contact-info"},Yr={class:"name"},Jr={class:"timestamp"},Qr={class:"chat-area"},Zr={class:"input-area"};function Kr(e,t,n,r,o,i){const a=ln,l=_e,u=Mr;return le(),ie("div",Hr,[q("div",Wr,[t[1]||(t[1]=q("div",{class:"sidebar-header"},"聊天应用",-1)),q("ul",Xr,[(le(!0),ie(ge,null,He(r.contacts,p=>(le(),ie("li",{key:p.id,class:We({selected:r.selectedContactId===p.id}),onClick:d=>r.selectContact(p.id)},[q("img",{src:p.avatar,alt:"Avatar",class:"avatar"},null,8,Gr),q("div",qr,[q("span",Yr,Ce(p.name),1),q("span",Jr,Ce(p.lastMessageTime),1)])],10,Vr))),128))])]),q("div",Qr,[(le(!0),ie(ge,null,He(r.messages,p=>(le(),ie("div",{class:We(["message-bubble",{sent:p.sentByUser,received:!p.sentByUser}]),key:p.id},Ce(p.text),3))),128))]),q("div",Zr,[c(a,{value:r.inputMessage,"onUpdate:value":t[0]||(t[0]=p=>r.inputMessage=p),placeholder:"Type a message...",class:"message-input",onKeyup:an(r.sendMessage,["enter"])},null,8,["value","onKeyup"]),c(l,{type:"primary",shape:"circle",icon:"send",onClick:r.sendMessage,class:"send-button"},null,8,["onClick"]),c(u,{accept:"*","before-upload":r.handleFileUpload,class:"upload-button"},{default:sn(()=>[c(l,{type:"primary",shape:"circle",icon:"upload"})]),_:1},8,["before-upload"])])])}const to=on(zr,[["render",Kr],["__scopeId","data-v-fa061339"]]);export{to as default};
|