You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
paopao-ce/web/dist/assets/Upload.efe3adfd.js

383 lines
41 KiB

import{br as q,h as t,n as $,l as f,o as C,d as A,s as R,bd as E,N as j,bs as re,bt as ie,bu as ne,bv as oe,u as ae,q as G,bw as be,v as J,y as le,e as ye,i as W,be as Y,L as we,bx as se,r as M,aK as xe,bl as Ce,J as V,by as Re,ax as ke,w as Be,bm as Pe,m as I,bz as Q,at as $e,bA as Le,f as Te,t as D,g as Se,A as ze,bB as De,aa as _e,R as Ie,aF as Oe,k as ee}from"./index.f480f018.js";var Fe=q("attach",t("svg",{viewBox:"0 0 16 16",version:"1.1",xmlns:"http://www.w3.org/2000/svg"},t("g",{stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},t("g",{fill:"currentColor","fill-rule":"nonzero"},t("path",{d:"M3.25735931,8.70710678 L7.85355339,4.1109127 C8.82986412,3.13460197 10.4127766,3.13460197 11.3890873,4.1109127 C12.365398,5.08722343 12.365398,6.67013588 11.3890873,7.64644661 L6.08578644,12.9497475 C5.69526215,13.3402718 5.06209717,13.3402718 4.67157288,12.9497475 C4.28104858,12.5592232 4.28104858,11.9260582 4.67157288,11.5355339 L9.97487373,6.23223305 C10.1701359,6.0369709 10.1701359,5.72038841 9.97487373,5.52512627 C9.77961159,5.32986412 9.4630291,5.32986412 9.26776695,5.52512627 L3.96446609,10.8284271 C3.18341751,11.6094757 3.18341751,12.8758057 3.96446609,13.6568542 C4.74551468,14.4379028 6.01184464,14.4379028 6.79289322,13.6568542 L12.0961941,8.35355339 C13.4630291,6.98671837 13.4630291,4.77064094 12.0961941,3.40380592 C10.7293591,2.0369709 8.51328163,2.0369709 7.14644661,3.40380592 L2.55025253,8 C2.35499039,8.19526215 2.35499039,8.51184464 2.55025253,8.70710678 C2.74551468,8.90236893 3.06209717,8.90236893 3.25735931,8.70710678 Z"}))))),je=q("trash",t("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},t("path",{d:"M432,144,403.33,419.74A32,32,0,0,1,371.55,448H140.46a32,32,0,0,1-31.78-28.26L80,144",style:"fill: none; stroke: currentcolor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 32px;"}),t("rect",{x:"32",y:"64",width:"448",height:"80",rx:"16",ry:"16",style:"fill: none; stroke: currentcolor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 32px;"}),t("line",{x1:"312",y1:"240",x2:"200",y2:"352",style:"fill: none; stroke: currentcolor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 32px;"}),t("line",{x1:"312",y1:"352",x2:"200",y2:"240",style:"fill: none; stroke: currentcolor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 32px;"}))),Ue=q("download",t("svg",{viewBox:"0 0 16 16",version:"1.1",xmlns:"http://www.w3.org/2000/svg"},t("g",{stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},t("g",{fill:"currentColor","fill-rule":"nonzero"},t("path",{d:"M3.5,13 L12.5,13 C12.7761424,13 13,13.2238576 13,13.5 C13,13.7454599 12.8231248,13.9496084 12.5898756,13.9919443 L12.5,14 L3.5,14 C3.22385763,14 3,13.7761424 3,13.5 C3,13.2545401 3.17687516,13.0503916 3.41012437,13.0080557 L3.5,13 L12.5,13 L3.5,13 Z M7.91012437,1.00805567 L8,1 C8.24545989,1 8.44960837,1.17687516 8.49194433,1.41012437 L8.5,1.5 L8.5,10.292 L11.1819805,7.6109127 C11.3555469,7.43734635 11.6249713,7.4180612 11.8198394,7.55305725 L11.8890873,7.6109127 C12.0626536,7.78447906 12.0819388,8.05390346 11.9469427,8.2487716 L11.8890873,8.31801948 L8.35355339,11.8535534 C8.17998704,12.0271197 7.91056264,12.0464049 7.7156945,11.9114088 L7.64644661,11.8535534 L4.1109127,8.31801948 C3.91565056,8.12275734 3.91565056,7.80617485 4.1109127,7.6109127 C4.28447906,7.43734635 4.55390346,7.4180612 4.7487716,7.55305725 L4.81801948,7.6109127 L7.5,10.292 L7.5,1.5 C7.5,1.25454011 7.67687516,1.05039163 7.91012437,1.00805567 L8,1 L7.91012437,1.00805567 Z"}))))),Ae=q("cancel",t("svg",{viewBox:"0 0 16 16",version:"1.1",xmlns:"http://www.w3.org/2000/svg"},t("g",{stroke:"none","stroke-width":"1",fill:"none","fill-rule":"evenodd"},t("g",{fill:"currentColor","fill-rule":"nonzero"},t("path",{d:"M2.58859116,2.7156945 L2.64644661,2.64644661 C2.82001296,2.47288026 3.08943736,2.45359511 3.2843055,2.58859116 L3.35355339,2.64644661 L8,7.293 L12.6464466,2.64644661 C12.8417088,2.45118446 13.1582912,2.45118446 13.3535534,2.64644661 C13.5488155,2.84170876 13.5488155,3.15829124 13.3535534,3.35355339 L8.707,8 L13
color: var(--n-icon-color);
transition: color .3s var(--n-bezier);
`),C("line",`
width: 100%;
display: block;
`,[f("progress-content",`
display: flex;
align-items: center;
`,[f("progress-graph",{flex:1})]),f("progress-custom-content",{marginLeft:"14px"}),f("progress-icon",`
width: 30px;
padding-left: 14px;
height: var(--n-icon-size-line);
line-height: var(--n-icon-size-line);
font-size: var(--n-icon-size-line);
`,[C("as-text",`
color: var(--n-text-color-line-outer);
text-align: center;
width: 40px;
font-size: var(--n-font-size);
padding-left: 4px;
transition: color .3s var(--n-bezier);
`)])]),C("circle, dashboard",{width:"120px"},[f("progress-custom-content",`
position: absolute;
left: 50%;
top: 50%;
transform: translateX(-50%) translateY(-50%);
display: flex;
align-items: center;
justify-content: center;
`),f("progress-text",`
position: absolute;
left: 50%;
top: 50%;
transform: translateX(-50%) translateY(-50%);
display: flex;
align-items: center;
color: inherit;
font-size: var(--n-font-size-circle);
color: var(--n-text-color-circle);
font-weight: var(--n-font-weight-circle);
transition: color .3s var(--n-bezier);
white-space: nowrap;
`),f("progress-icon",`
position: absolute;
left: 50%;
top: 50%;
transform: translateX(-50%) translateY(-50%);
display: flex;
align-items: center;
color: var(--n-icon-color);
font-size: var(--n-icon-size-circle);
`)]),C("multiple-circle",`
width: 200px;
color: inherit;
`,[f("progress-text",`
font-weight: var(--n-font-weight-circle);
color: var(--n-text-color-circle);
position: absolute;
left: 50%;
top: 50%;
transform: translateX(-50%) translateY(-50%);
display: flex;
align-items: center;
justify-content: center;
transition: color .3s var(--n-bezier);
`)]),f("progress-content",{position:"relative"}),f("progress-graph",{position:"relative"},[f("progress-graph-circle",[$("svg",{verticalAlign:"bottom"}),f("progress-graph-circle-fill",`
stroke: var(--n-fill-color);
transition:
opacity .3s var(--n-bezier),
stroke .3s var(--n-bezier),
stroke-dasharray .3s var(--n-bezier);
`,[C("empty",{opacity:0})]),f("progress-graph-circle-rail",`
transition: stroke .3s var(--n-bezier);
overflow: hidden;
stroke: var(--n-rail-color);
`)]),f("progress-graph-line",[C("indicator-inside",[f("progress-graph-line-rail",`
height: 16px;
line-height: 16px;
border-radius: 10px;
`,[f("progress-graph-line-fill",`
height: inherit;
border-radius: 10px;
`),f("progress-graph-line-indicator",`
background: #0000;
white-space: nowrap;
text-align: right;
margin-left: 14px;
margin-right: 14px;
height: inherit;
font-size: 12px;
color: var(--n-text-color-line-inner);
transition: color .3s var(--n-bezier);
`)])]),C("indicator-inside-label",`
height: 16px;
display: flex;
align-items: center;
`,[f("progress-graph-line-rail",`
flex: 1;
transition: background-color .3s var(--n-bezier);
`),f("progress-graph-line-indicator",`
background: var(--n-fill-color);
font-size: 12px;
transform: translateZ(0);
display: flex;
vertical-align: middle;
height: 16px;
line-height: 16px;
padding: 0 10px;
border-radius: 10px;
position: absolute;
white-space: nowrap;
color: var(--n-text-color-line-inner);
transition:
right .2s var(--n-bezier),
color .3s var(--n-bezier),
background-color .3s var(--n-bezier);
`)]),f("progress-graph-line-rail",`
position: relative;
overflow: hidden;
height: var(--n-rail-height);
border-radius: 5px;
background-color: var(--n-rail-color);
transition: background-color .3s var(--n-bezier);
`,[f("progress-graph-line-fill",`
background: var(--n-fill-color);
position: relative;
border-radius: 5px;
height: inherit;
width: 100%;
max-width: 0%;
transition:
background-color .3s var(--n-bezier),
max-width .2s var(--n-bezier);
`,[C("processing",[$("&::after",`
content: "";
background-image: var(--n-line-bg-processing);
animation: progress-processing-animation 2s var(--n-bezier) infinite;
`)])])])])])]),$("@keyframes progress-processing-animation",`
0% {
position: absolute;
left: 0;
top: 0;
bottom: 0;
right: 100%;
opacity: 1;
}
66% {
position: absolute;
left: 0;
top: 0;
bottom: 0;
right: 0;
opacity: 0;
}
100% {
position: absolute;
left: 0;
top: 0;
bottom: 0;
right: 0;
opacity: 0;
}
`)]);const He={success:t(re,null),error:t(ie,null),warning:t(ne,null),info:t(oe,null)};var Me=A({name:"ProgressLine",props:{clsPrefix:{type:String,required:!0},percentage:{type:Number,default:0},railColor:String,railStyle:[String,Object],fillColor:String,status:{type:String,required:!0},indicatorPlacement:{type:String,required:!0},indicatorTextColor:String,unit:{type:String,default:"%"},processing:{type:Boolean,required:!0},showIndicator:{type:Boolean,required:!0},height:[String,Number],railBorderRadius:[String,Number],fillBorderRadius:[String,Number]},setup(e,{slots:n}){const i=R(()=>E(e.height)),r=R(()=>e.railBorderRadius!==void 0?E(e.railBorderRadius):e.height!==void 0?E(e.height,{c:.5}):""),l=R(()=>e.fillBorderRadius!==void 0?E(e.fillBorderRadius):e.railBorderRadius!==void 0?E(e.railBorderRadius):e.height!==void 0?E(e.height,{c:.5}):"");return()=>{const{indicatorPlacement:o,railColor:c,railStyle:g,percentage:s,unit:d,indicatorTextColor:a,status:u,showIndicator:b,fillColor:h,processing:k,clsPrefix:y}=e;return t("div",{class:`${y}-progress-content`,role:"none"},t("div",{class:`${y}-progress-graph`,"aria-hidden":!0},t("div",{class:[`${y}-progress-graph-line`,{[`${y}-progress-graph-line--indicator-${o}`]:!0}]},t("div",{class:`${y}-progress-graph-line-rail`,style:[{backgroundColor:c,height:i.value,borderRadius:r.value},g]},t("div",{class:[`${y}-progress-graph-line-fill`,k&&`${y}-progress-graph-line-fill--processing`],style:{maxWidth:`${e.percentage}%`,backgroundColor:h,height:i.value,lineHeight:i.value,borderRadius:l.value}},o==="inside"?t("div",{class:`${y}-progress-graph-line-indicator`},s,d):null)))),b&&o==="outside"?t("div",null,n.default?t("div",{class:`${y}-progress-custom-content`,style:{color:a},role:"none"},n.default()):u==="default"?t("div",{role:"none",class:`${y}-progress-icon ${y}-progress-icon--as-text`,style:{color:a}},s,d):t("div",{class:`${y}-progress-icon`,"aria-hidden":!0},t(j,{clsPrefix:y},{default:()=>He[u]}))):null)}}});const qe={success:t(re,null),error:t(ie,null),warning:t(ne,null),info:t(oe,null)};var We=A({name:"ProgressCircle",props:{clsPrefix:{type:String,required:!0},status:{type:String,required:!0},strokeWidth:{type:Number,required:!0},fillColor:String,railColor:String,railStyle:[String,Object],percentage:{type:Number,default:0},offsetDegree:{type:Number,default:0},showIndicator:{type:Boolean,required:!0},indicatorTextColor:String,unit:String,viewBoxWidth:{type:Number,required:!0},gapDegree:{type:Number,required:!0},gapOffsetDegree:{type:Number,default:0}},setup(e,{slots:n}){function i(r,l,o){const{gapDegree:c,viewBoxWidth:g}=e,s=50,d=0,a=s,u=0,b=2*s,h=`M 55,55 m ${d},${a}
a ${s},${s} 0 1 1 ${u},${-b}
a ${s},${s} 0 1 1 ${-u},${b}`,k=Math.PI*2*s,y={stroke:o,strokeDasharray:`${r/100*(k-c)}px ${g*8}px`,strokeDashoffset:`-${c/2+Math.PI/3.6*l}px`};return{pathString:h,pathStyle:y}}return()=>{const{fillColor:r,railColor:l,strokeWidth:o,offsetDegree:c,status:g,percentage:s,showIndicator:d,indicatorTextColor:a,unit:u,gapOffsetDegree:b,clsPrefix:h}=e,{pathString:k,pathStyle:y}=i(100,0,l),{pathString:B,pathStyle:w}=i(s,c,r);return t("div",{class:`${h}-progress-content`,role:"none"},t("div",{class:`${h}-progress-graph`,"aria-hidden":!0},t("div",{class:`${h}-progress-graph-circle`,style:{transform:b?`rotate(${b}deg)`:void 0}},t("svg",{viewBox:"0 0 110 110"},t("g",null,t("path",{class:`${h}-progress-graph-circle-rail`,d:k,"stroke-width":o,"stroke-linecap":"round",fill:"none",style:y})),t("g",null,t("path",{class:[`${h}-progress-graph-circle-fill`,s===0&&`${h}-progress-graph-circle-fill--empty`],d:B,"stroke-width":o,"stroke-linecap":"round",fill:"none",style:w}))))),d?t("div",null,n.default?t("div",{class:`${h}-progress-custom-content`,role:"none"},n.default()):g!=="default"?t("div",{class:`${h}-progress-icon`,"aria-hidden":!0},t(j,{clsPrefix:h},{default:()=>qe[g]})):t("div",{class:`${h}-progress-text`,style:{color:a},role:"none"},t("span",{class:`${h}-progress-text__percentage`},s),t("span",{class:`${h}-progress-text__unit`},u))):null)}}});function te(e,n,i=100){return`m ${i/2} ${i/2-e} a ${e} ${e} 0 1 1 0 ${2*e} a ${e} ${e} 0 1 1 0 -${2*e}`}var Xe=A({name:"ProgressMultipleCircle",props:{clsPrefix:{type:String,required:!0},viewBoxWidth:{type:Number,required:!0},percentage:{type:Array,default:[0]},strokeWidth:{type:Number,required:!0},circleGap:{type:Number,required:!0},showIndicator:{type:Boolean,required:!0},fillColor:{type:Array,default:()=>[]},railColor:{type:Array,default:()=>[]},railStyle:{type:Array,default:()=>[]}},setup(e,{slots:n}){const i=R(()=>e.percentage.map((l,o)=>`${Math.PI*l/100*(e.viewBoxWidth/2-e.strokeWidth/2*(1+2*o)-e.circleGap*o)*2}, ${e.viewBoxWidth*8}`));return()=>{const{viewBoxWidth:r,strokeWidth:l,circleGap:o,showIndicator:c,fillColor:g,railColor:s,railStyle:d,percentage:a,clsPrefix:u}=e;return t("div",{class:`${u}-progress-content`,role:"none"},t("div",{class:`${u}-progress-graph`,"aria-hidden":!0},t("div",{class:`${u}-progress-graph-circle`},t("svg",{viewBox:`0 0 ${r} ${r}`},a.map((b,h)=>t("g",{key:h},t("path",{class:`${u}-progress-graph-circle-rail`,d:te(r/2-l/2*(1+2*h)-o*h,l,r),"stroke-width":l,"stroke-linecap":"round",fill:"none",style:[{strokeDashoffset:0,stroke:s[h]},d[h]]}),t("path",{class:[`${u}-progress-graph-circle-fill`,b===0&&`${u}-progress-graph-circle-fill--empty`],d:te(r/2-l/2*(1+2*h)-o*h,l,r),"stroke-width":l,"stroke-linecap":"round",fill:"none",style:{strokeDasharray:i.value[h],strokeDashoffset:0,stroke:g[h]}})))))),c&&n.default?t("div",null,t("div",{class:`${u}-progress-text`},n.default())):null)}}});const Ve=Object.assign(Object.assign({},G.props),{processing:Boolean,type:{type:String,default:"line"},gapDegree:Number,gapOffsetDegree:Number,status:{type:String,default:"default"},railColor:[String,Array],railStyle:[String,Array],color:[String,Array],viewBoxWidth:{type:Number,default:100},strokeWidth:{type:Number,default:7},percentage:[Number,Array],unit:{type:String,default:"%"},showIndicator:{type:Boolean,default:!0},indicatorPosition:{type:String,default:"outside"},indicatorPlacement:{type:String,default:"outside"},indicatorTextColor:String,circleGap:{type:Number,default:1},height:Number,borderRadius:[String,Number],fillBorderRadius:[String,Number],offsetDegree:Number});var Ge=A({name:"Progress",props:Ve,setup(e){const n=R(()=>e.indicatorPlacement||e.indicatorPosition),i=R(()=>{if(e.gapDegree||e.gapDegree===0)return e.gapDegree;if(e.type==="dashboard")return 75}),{mergedClsPrefixRef:r,inlineThemeDisabled:l}=ae(e),o=G("Progress","-progress",Ee,be,e,r),c=R(()=>{const{status:s}=e,{common:{cubicBezierEaseInOut:d},self:{fontSize:a,fontSizeCircle:u,railColor:b,railHeight:h,iconSizeCircle:k,iconSizeLine:y,textColorCircle:B,textColorLineInner:w,textColorLineOuter:x,lineBgProcessing:O,font
display: block;
`)]),C("drag-over",[f("upload-dragger",`
border: var(--n-dragger-border-hover);
`)])]),f("upload-dragger",`
cursor: pointer;
box-sizing: border-box;
width: 100%;
text-align: center;
border-radius: var(--n-border-radius);
padding: 24px;
opacity: 1;
transition:
opacity .3s var(--n-bezier),
border-color .3s var(--n-bezier),
background-color .3s var(--n-bezier);
background-color: var(--n-dragger-color);
border: var(--n-dragger-border);
`,[$("&:hover",`
border: var(--n-dragger-border-hover);
`),C("disabled",`
opacity: var(--n-item-disabled-opacity);
cursor: not-allowed;
`)]),f("upload-trigger",`
display: inline-block;
box-sizing: border-box;
opacity: 1;
transition: opacity .3s var(--n-bezier);
`,[$("+",[f("upload-file-list","margin-top: 8px;")]),C("disabled",`
opacity: var(--n-item-disabled-opacity);
cursor: not-allowed;
`),C("image-card",`
width: 96px;
height: 96px;
`,[f("base-icon",`
font-size: 24px;
`),f("upload-dragger",`
padding: 0;
height: 100%;
width: 100%;
display: flex;
align-items: center;
justify-content: center;
`)])]),f("upload-file-list",`
line-height: var(--n-line-height);
opacity: 1;
transition: opacity .3s var(--n-bezier);
`,[C("disabled",`
opacity: var(--n-item-disabled-opacity);
cursor: not-allowed;
`,[f("upload-file","cursor: not-allowed;")]),C("grid",`
display: grid;
grid-template-columns: repeat(auto-fill, 96px);
grid-gap: 8px;
margin-top: 0;
`),f("upload-file",`
display: block;
box-sizing: border-box;
cursor: default;
padding: 0px 12px 0 6px;
transition: background-color .3s var(--n-bezier);
border-radius: var(--n-border-radius);
`,[Q(),f("progress",[Q({foldPadding:!0})]),$("&:hover",`
background-color: var(--n-item-color-hover);
`,[f("upload-file-info",[I("action",`
opacity: 1;
`)])]),C("image-type",`
border-radius: var(--n-border-radius);
text-decoration: underline;
text-decoration-color: #0000;
`,[f("upload-file-info",`
padding-top: 0px;
padding-bottom: 0px;
width: 100%;
height: 100%;
display: flex;
justify-content: space-between;
align-items: center;
padding: 6px 0;
`,[f("progress",`
padding: 2px 0;
margin-bottom: 0;
`),I("name",`
padding: 0 8px;
`),I("thumbnail",`
width: 32px;
height: 32px;
font-size: 28px;
display: flex;
justify-content: center;
align-items: center;
`,[$("img",`
width: 100%;
`)])])]),C("text-type",[f("progress",`
box-sizing: border-box;
padding-bottom: 6px;
margin-bottom: 6px;
`)]),C("image-card-type",`
position: relative;
width: 96px;
height: 96px;
border: var(--n-item-border-image-card);
border-radius: var(--n-border-radius);
padding: 0;
display: flex;
align-items: center;
justify-content: center;
transition: border-color .3s var(--n-bezier), background-color .3s var(--n-bezier);
border-radius: var(--n-border-radius);
`,[f("progress",`
position: absolute;
left: 8px;
bottom: 8px;
right: 8px;
width: unset;
`),f("upload-file-info",`
padding: 0;
width: 100%;
height: 100%;
`,[I("thumbnail",`
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
font-size: 36px;
`,[$("img",`
width: 100%;
`)])]),$("&::before",`
position: absolute;
z-index: 1;
left: 0;
right: 0;
top: 0;
bottom: 0;
border-radius: inherit;
opacity: 0;
transition: opacity .2s var(--n-bezier);
content: "";
`),$("&:hover",[$("&::before","opacity: 1;"),f("upload-file-info",[I("thumbnail","opacity: .12;")])])]),C("error-status",[$("&:hover",`
background-color: var(--n-item-color-hover-error);
`),f("upload-file-info",[I("name","color: var(--n-item-text-color-error);"),I("thumbnail","color: var(--n-item-text-color-error);")]),C("image-card-type",`
border: var(--n-item-border-image-card-error);
`)]),C("with-url",`
cursor: pointer;
`,[f("upload-file-info",[I("name",`
color: var(--n-item-text-color-success);
text-decoration-color: var(--n-item-text-color-success);
`,[$("a",`
text-decoration: underline;
`)])])]),f("upload-file-info",`
position: relative;
padding-top: 6px;
padding-bottom: 6px;
display: flex;
flex-wrap: nowrap;
`,[I("thumbnail",`
font-size: 18px;
opacity: 1;
transition: opacity .2s var(--n-bezier);
color: var(--n-item-icon-color);
`,[f("base-icon",`
margin-right: 2px;
vertical-align: middle;
transition: color .3s var(--n-bezier);
`)]),I("action",`
padding-top: inherit;
padding-bottom: inherit;
position: absolute;
right: 0;
top: 0;
bottom: 0;
width: 80px;
display: flex;
align-items: center;
transition: opacity .2s var(--n-bezier);
justify-content: flex-end;
opacity: 0;
`,[f("button",[$("&:not(:last-child)",{marginRight:"4px"}),f("base-icon",[$("svg",[$e()])])]),C("image-type",`
position: relative;
max-width: 80px;
width: auto;
`),C("image-card-type",`
z-index: 2;
position: absolute;
width: 100%;
height: 100%;
left: 0;
right: 0;
bottom: 0;
top: 0;
display: flex;
justify-content: center;
align-items: center;
`)]),I("name",`
color: var(--n-item-text-color);
flex: 1;
display: flex;
justify-content: center;
text-overflow: ellipsis;
overflow: hidden;
flex-direction: column;
text-decoration-color: #0000;
font-size: var(--n-font-size);
transition:
color .3s var(--n-bezier),
text-decoration-color .3s var(--n-bezier);
`,[$("a",`
color: inherit;
text-decoration: underline;
`)])])])]),f("upload-file-input",`
display: block;
width: 0;
height: 0;
opacity: 0;
`)]),Z=globalThis&&globalThis.__awaiter||function(e,n,i,r){function l(o){return o instanceof i?o:new i(function(c){c(o)})}return new(i||(i=Promise))(function(o,c){function g(a){try{d(r.next(a))}catch(u){c(u)}}function s(a){try{d(r.throw(a))}catch(u){c(u)}}function d(a){a.done?o(a.value):l(a.value).then(g,s)}d((r=r.apply(e,n||[])).next())})};function st(e,n,i){const{doChange:r,XhrMap:l}=e;let o=0;function c(s){var d;let a=Object.assign({},n,{status:"error",percentage:o});l.delete(n.id),a=((d=e.onError)===null||d===void 0?void 0:d.call(e,{file:a,event:s}))||a,r(a,s)}function g(s){var d;if(i.status<200||i.status>=300){c(s);return}let a=Object.assign({},n,{status:"finished",percentage:o,file:null});l.delete(n.id),a=((d=e.onFinish)===null||d===void 0?void 0:d.call(e,{file:a,event:s}))||a,r(a,s)}return{handleXHRLoad:g,handleXHRError:c,handleXHRAbort(s){const d=Object.assign({},n,{status:"removed",file:null,percentage:o});l.delete(n.id),r(d,s)},handleXHRProgress(s){const d=Object.assign({},n,{status:"uploading"});if(s.lengthComputable){const a=Math.ceil(s.loaded/s.total*100);d.percentage=a,o=a}r(d,s)}}}function dt(e){const{inst:n,file:i,data:r,headers:l,withCredentials:o,action:c,customRequest:g}=e,{doChange:s}=e.inst;let d=0;g({file:i,data:r,headers:l,withCredentials:o,action:c,onProgress(a){const u=Object.assign({},i,{status:"uploading"}),b=a.percent;u.percentage=b,d=b,s(u)},onFinish(){var a;let u=Object.assign({},i,{status:"finished",percentage:d,file:null});u=((a=n.onFinish)===null||a===void 0?void 0:a.call(n,{file:u}))||u,s(u)},onError(){var a;let u=Object.assign({},i,{status:"error",percentage:d});u=((a=n.onError)===null||a===void 0?void 0:a.call(n,{file:u}))||u,s(u)}})}function ct(e,n,i){const r=st(e,n,i);i.onabort=r.handleXHRAbort,i.onerror=r.handleXHRError,i.onload=r.handleXHRLoad,i.upload&&(i.upload.onprogress=r.handleXHRProgress)}function ge(e,n){return typeof e=="function"?e({file:n}):e||{}}function ut(e,n,i){const r=ge(n,i);!r||Object.keys(r).forEach(l=>{e.setRequestHeader(l,r[l])})}function gt(e,n,i){const r=ge(n,i);!r||Object.keys(r).forEach(l=>{e.append(l,r[l])})}function ft(e,n,i,{method:r,action:l,withCredentials:o,headers:c,data:g}){const s=new XMLHttpRequest;e.XhrMap.set(i.id,s),s.withCredentials=o;const d=new FormData;if(gt(d,g,i),d.append(n,i.file),ct(e,i,s),l!==void 0){s.open(r.toUpperCase(),l),ut(s,c,i),s.send(d);const a=Object.assign({},i,{status:"uploading"});e.doChange(a)}}const pt=Object.assign(Object.assign({},G.props),{name:{type:String,default:"file"},accept:String,action:String,customRequest:Function,method:{type:String,default:"POST"},multiple:Boolean,showFileList:{type:Boolean,default:!0},data:[Object,Function],headers:[Object,Function],withCredentials:Boolean,disabled:{type:Boolean,default:void 0},onChange:Function,onRemove:Function,onFinish:Function,onError:Function,onBeforeUpload:Function,onDownload:Function,defaultUpload:{type:Boolean,default:!0},fileList:Array,"onUpdate:fileList":[Function,Array],onUpdateFileList:[Function,Array],fileListStyle:[String,Object],defaultFileList:{type:Array,default:()=>[]},showCancelButton:{type:Boolean,default:!0},showRemoveButton:{type:Boolean,default:!0},showDownloadButton:Boolean,showRetryButton:{type:Boolean,default:!0},showPreviewButton:{type:Boolean,default:!0},listType:{type:String,default:"text"},onPreview:Function,createThumbnailUrl:Function,abstract:Boolean,max:Number,showTrigger:{type:Boolean,default:!0},imageGroupProps:Object,inputProps:Object});var mt=A({name:"Upload",props:pt,setup(e){e.abstract&&e.listType==="image-card"&&Y("upload","when the list-type is image-card, abstract is not supported.");const{mergedClsPrefixRef:n,inlineThemeDisabled:i}=ae(e),r=G("Upload","-upload",lt,Le,e,n),l=Te(e),o=R(()=>{const{max:m}=e;return m!==void 0?b.value.length>=m:!1}),c=M(e.defaultFileList),g=D(e,"fileList"),s=M(null),d={value:!1},a=M(!1),u=new Map,b=Se(g,c);function h(){var m;(m=s.value)===null||m===void 0||m.click()}function k(m){const P=m.target;B(P.files,m),P.value=""}function y(m){const{"onUpdate:fileList":P,onUpdateFileList:S}=e;P&&ee(P,m),S&&ee(S,m