vue-amazing-ui
Version:
An Amazing Vue3 UI Components Library, Using TypeScript.
14 lines • 814 kB
JavaScript
var VueAmazingUI=function(me,e){"use strict";var Vy=Object.defineProperty;var Ny=(me,e,nt)=>e in me?Vy(me,e,{enumerable:!0,configurable:!0,writable:!0,value:nt}):me[e]=nt;var $e=(me,e,nt)=>Ny(me,typeof e!="symbol"?e+"":e,nt);function nt(l,t){md(l)&&(l="100%");const a=hd(l);return l=t===360?l:Math.min(t,Math.max(0,parseFloat(l))),a&&(l=parseInt(String(l*t),10)/100),Math.abs(l-t)<1e-6?1:(t===360?l=(l<0?l%t+t:l%t)/parseFloat(String(t)):l=l%t/parseFloat(String(t)),l)}function en(l){return Math.min(1,Math.max(0,l))}function md(l){return typeof l=="string"&&l.indexOf(".")!==-1&&parseFloat(l)===1}function hd(l){return typeof l=="string"&&l.indexOf("%")!==-1}function wo(l){return l=parseFloat(l),(isNaN(l)||l<0||l>1)&&(l=1),l}function tn(l){return Number(l)<=1?`${Number(l)*100}%`:l}function qa(l){return l.length===1?"0"+l:String(l)}function gd(l,t,a){return{r:nt(l,255)*255,g:nt(t,255)*255,b:nt(a,255)*255}}function ko(l,t,a){l=nt(l,255),t=nt(t,255),a=nt(a,255);const n=Math.max(l,t,a),r=Math.min(l,t,a);let o=0,s=0;const i=(n+r)/2;if(n===r)s=0,o=0;else{const c=n-r;switch(s=i>.5?c/(2-n-r):c/(n+r),n){case l:o=(t-a)/c+(t<a?6:0);break;case t:o=(a-l)/c+2;break;case a:o=(l-t)/c+4;break}o/=6}return{h:o,s,l:i}}function Tn(l,t,a){return a<0&&(a+=1),a>1&&(a-=1),a<.16666666666666666?l+(t-l)*(6*a):a<.5?t:a<.6666666666666666?l+(t-l)*(.6666666666666666-a)*6:l}function yd(l,t,a){let n,r,o;if(l=nt(l,360),t=nt(t,100),a=nt(a,100),t===0)r=a,o=a,n=a;else{const s=a<.5?a*(1+t):a+t-a*t,i=2*a-s;n=Tn(i,s,l+.3333333333333333),r=Tn(i,s,l),o=Tn(i,s,l-.3333333333333333)}return{r:n*255,g:r*255,b:o*255}}function bo(l,t,a){l=nt(l,255),t=nt(t,255),a=nt(a,255);const n=Math.max(l,t,a),r=Math.min(l,t,a);let o=0;const s=n,i=n-r,c=n===0?0:i/n;if(n===r)o=0;else{switch(n){case l:o=(t-a)/i+(t<a?6:0);break;case t:o=(a-l)/i+2;break;case a:o=(l-t)/i+4;break}o/=6}return{h:o,s:c,v:s}}function wd(l,t,a){l=nt(l,360)*6,t=nt(t,100),a=nt(a,100);const n=Math.floor(l),r=l-n,o=a*(1-t),s=a*(1-r*t),i=a*(1-(1-r)*t),c=n%6,d=[a,s,o,o,i,a][c],u=[i,a,a,s,o,o][c],f=[o,o,i,a,a,s][c];return{r:d*255,g:u*255,b:f*255}}function vo(l,t,a,n){const r=[qa(Math.round(l).toString(16)),qa(Math.round(t).toString(16)),qa(Math.round(a).toString(16))];return n&&r[0].startsWith(r[0].charAt(1))&&r[1].startsWith(r[1].charAt(1))&&r[2].startsWith(r[2].charAt(1))?r[0].charAt(0)+r[1].charAt(0)+r[2].charAt(0):r.join("")}function kd(l,t,a,n,r){const o=[qa(Math.round(l).toString(16)),qa(Math.round(t).toString(16)),qa(Math.round(a).toString(16)),qa(vd(n))];return r&&o[0].startsWith(o[0].charAt(1))&&o[1].startsWith(o[1].charAt(1))&&o[2].startsWith(o[2].charAt(1))&&o[3].startsWith(o[3].charAt(1))?o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0)+o[3].charAt(0):o.join("")}function bd(l,t,a,n){const r=l/100,o=t/100,s=a/100,i=n/100,c=255*(1-r)*(1-i),d=255*(1-o)*(1-i),u=255*(1-s)*(1-i);return{r:c,g:d,b:u}}function So(l,t,a){let n=1-l/255,r=1-t/255,o=1-a/255,s=Math.min(n,r,o);return s===1?(n=0,r=0,o=0):(n=(n-s)/(1-s)*100,r=(r-s)/(1-s)*100,o=(o-s)/(1-s)*100),s*=100,{c:Math.round(n),m:Math.round(r),y:Math.round(o),k:Math.round(s)}}function vd(l){return Math.round(parseFloat(l)*255).toString(16)}function Co(l){return At(l)/255}function At(l){return parseInt(l,16)}function Sd(l){return{r:l>>16,g:(l&65280)>>8,b:l&255}}const Vn={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"};function Cd(l){let t={r:0,g:0,b:0},a=1,n=null,r=null,o=null,s=!1,i=!1;return typeof l=="string"&&(l=Bd(l)),typeof l=="object"&&(Lt(l.r)&&Lt(l.g)&&Lt(l.b)?(t=gd(l.r,l.g,l.b),s=!0,i=String(l.r).substr(-1)==="%"?"prgb":"rgb"):Lt(l.h)&&Lt(l.s)&&Lt(l.v)?(n=tn(l.s),r=tn(l.v),t=wd(l.h,n,r),s=!0,i="hsv"):Lt(l.h)&&Lt(l.s)&&Lt(l.l)?(n=tn(l.s),o=tn(l.l),t=yd(l.h,n,o),s=!0,i="hsl"):Lt(l.c)&&Lt(l.m)&&Lt(l.y)&&Lt(l.k)&&(t=bd(l.c,l.m,l.y,l.k),s=!0,i="cmyk"),Object.prototype.hasOwnProperty.call(l,"a")&&(a=l.a)),a=wo(a),{ok:s,format:l.format||i,r:Math.min(255,Math.max(t.r,0)),g:Math.min(255,Math.max(t.g,0)),b:Math.min(255,Math.max(t.b,0)),a}}const Ea="(?:"+"[-\\+]?\\d*\\.\\d+%?"+")|(?:"+"[-\\+]?\\d+%?"+")",Nn="[\\s|\\(]+("+Ea+")[,|\\s]+("+Ea+")[,|\\s]+("+Ea+")\\s*\\)?",an="[\\s|\\(]+("+Ea+")[,|\\s]+("+Ea+")[,|\\s]+("+Ea+")[,|\\s]+("+Ea+")\\s*\\)?",Yt={CSS_UNIT:new RegExp(Ea),rgb:new RegExp("rgb"+Nn),rgba:new RegExp("rgba"+an),hsl:new RegExp("hsl"+Nn),hsla:new RegExp("hsla"+an),hsv:new RegExp("hsv"+Nn),hsva:new RegExp("hsva"+an),cmyk:new RegExp("cmyk"+an),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function Bd(l){if(l=l.trim().toLowerCase(),l.length===0)return!1;let t=!1;if(Vn[l])l=Vn[l],t=!0;else if(l==="transparent")return{r:0,g:0,b:0,a:0,format:"name"};let a=Yt.rgb.exec(l);return a?{r:a[1],g:a[2],b:a[3]}:(a=Yt.rgba.exec(l),a?{r:a[1],g:a[2],b:a[3],a:a[4]}:(a=Yt.hsl.exec(l),a?{h:a[1],s:a[2],l:a[3]}:(a=Yt.hsla.exec(l),a?{h:a[1],s:a[2],l:a[3],a:a[4]}:(a=Yt.hsv.exec(l),a?{h:a[1],s:a[2],v:a[3]}:(a=Yt.hsva.exec(l),a?{h:a[1],s:a[2],v:a[3],a:a[4]}:(a=Yt.cmyk.exec(l),a?{c:a[1],m:a[2],y:a[3],k:a[4]}:(a=Yt.hex8.exec(l),a?{r:At(a[1]),g:At(a[2]),b:At(a[3]),a:Co(a[4]),format:t?"name":"hex8"}:(a=Yt.hex6.exec(l),a?{r:At(a[1]),g:At(a[2]),b:At(a[3]),format:t?"name":"hex"}:(a=Yt.hex4.exec(l),a?{r:At(a[1]+a[1]),g:At(a[2]+a[2]),b:At(a[3]+a[3]),a:Co(a[4]+a[4]),format:t?"name":"hex8"}:(a=Yt.hex3.exec(l),a?{r:At(a[1]+a[1]),g:At(a[2]+a[2]),b:At(a[3]+a[3]),format:t?"name":"hex"}:!1))))))))))}function Lt(l){return typeof l=="number"?!Number.isNaN(l):Yt.CSS_UNIT.test(l)}class Ge{constructor(t="",a={}){if(t instanceof Ge)return t;typeof t=="number"&&(t=Sd(t)),this.originalInput=t;const n=Cd(t);this.originalInput=t,this.r=n.r,this.g=n.g,this.b=n.b,this.a=n.a,this.roundA=Math.round(100*this.a)/100,this.format=a.format??n.format,this.gradientType=a.gradientType,this.r<1&&(this.r=Math.round(this.r)),this.g<1&&(this.g=Math.round(this.g)),this.b<1&&(this.b=Math.round(this.b)),this.isValid=n.ok}isDark(){return this.getBrightness()<128}isLight(){return!this.isDark()}getBrightness(){const t=this.toRgb();return(t.r*299+t.g*587+t.b*114)/1e3}getLuminance(){const t=this.toRgb();let a,n,r;const o=t.r/255,s=t.g/255,i=t.b/255;return o<=.03928?a=o/12.92:a=Math.pow((o+.055)/1.055,2.4),s<=.03928?n=s/12.92:n=Math.pow((s+.055)/1.055,2.4),i<=.03928?r=i/12.92:r=Math.pow((i+.055)/1.055,2.4),.2126*a+.7152*n+.0722*r}getAlpha(){return this.a}setAlpha(t){return this.a=wo(t),this.roundA=Math.round(100*this.a)/100,this}isMonochrome(){const{s:t}=this.toHsl();return t===0}toHsv(){const t=bo(this.r,this.g,this.b);return{h:t.h*360,s:t.s,v:t.v,a:this.a}}toHsvString(){const t=bo(this.r,this.g,this.b),a=Math.round(t.h*360),n=Math.round(t.s*100),r=Math.round(t.v*100);return this.a===1?`hsv(${a}, ${n}%, ${r}%)`:`hsva(${a}, ${n}%, ${r}%, ${this.roundA})`}toHsl(){const t=ko(this.r,this.g,this.b);return{h:t.h*360,s:t.s,l:t.l,a:this.a}}toHslString(){const t=ko(this.r,this.g,this.b),a=Math.round(t.h*360),n=Math.round(t.s*100),r=Math.round(t.l*100);return this.a===1?`hsl(${a}, ${n}%, ${r}%)`:`hsla(${a}, ${n}%, ${r}%, ${this.roundA})`}toHex(t=!1){return vo(this.r,this.g,this.b,t)}toHexString(t=!1){return"#"+this.toHex(t)}toHex8(t=!1){return kd(this.r,this.g,this.b,this.a,t)}toHex8String(t=!1){return"#"+this.toHex8(t)}toHexShortString(t=!1){return this.a===1?this.toHexString(t):this.toHex8String(t)}toRgb(){return{r:Math.round(this.r),g:Math.round(this.g),b:Math.round(this.b),a:this.a}}toRgbString(){const t=Math.round(this.r),a=Math.round(this.g),n=Math.round(this.b);return this.a===1?`rgb(${t}, ${a}, ${n})`:`rgba(${t}, ${a}, ${n}, ${this.roundA})`}toPercentageRgb(){const t=a=>`${Math.round(nt(a,255)*100)}%`;return{r:t(this.r),g:t(this.g),b:t(this.b),a:this.a}}toPercentageRgbString(){const t=a=>Math.round(nt(a,255)*100);return this.a===1?`rgb(${t(this.r)}%, ${t(this.g)}%, ${t(this.b)}%)`:`rgba(${t(this.r)}%, ${t(this.g)}%, ${t(this.b)}%, ${this.roundA})`}toCmyk(){return{...So(this.r,this.g,this.b)}}toCmykString(){const{c:t,m:a,y:n,k:r}=So(this.r,this.g,this.b);return`cmyk(${t}, ${a}, ${n}, ${r})`}toName(){if(this.a===0)return"transparent";if(this.a<1)return!1;const t="#"+vo(this.r,this.g,this.b,!1);for(const[a,n]of Object.entries(Vn))if(t===n)return a;return!1}toString(t){const a=!!t;t=t??this.format;let n=!1;const r=this.a<1&&this.a>=0;return!a&&r&&(t.startsWith("hex")||t==="name")?t==="name"&&this.a===0?this.toName():this.toRgbString():(t==="rgb"&&(n=this.toRgbString()),t==="prgb"&&(n=this.toPercentageRgbString()),(t==="hex"||t==="hex6")&&(n=this.toHexString()),t==="hex3"&&(n=this.toHexString(!0)),t==="hex4"&&(n=this.toHex8String(!0)),t==="hex8"&&(n=this.toHex8String()),t==="name"&&(n=this.toName()),t==="hsl"&&(n=this.toHslString()),t==="hsv"&&(n=this.toHsvString()),t==="cmyk"&&(n=this.toCmykString()),n||this.toHexString())}toNumber(){return(Math.round(this.r)<<16)+(Math.round(this.g)<<8)+Math.round(this.b)}clone(){return new Ge(this.toString())}lighten(t=10){const a=this.toHsl();return a.l+=t/100,a.l=en(a.l),new Ge(a)}brighten(t=10){const a=this.toRgb();return a.r=Math.max(0,Math.min(255,a.r-Math.round(255*-(t/100)))),a.g=Math.max(0,Math.min(255,a.g-Math.round(255*-(t/100)))),a.b=Math.max(0,Math.min(255,a.b-Math.round(255*-(t/100)))),new Ge(a)}darken(t=10){const a=this.toHsl();return a.l-=t/100,a.l=en(a.l),new Ge(a)}tint(t=10){return this.mix("white",t)}shade(t=10){return this.mix("black",t)}desaturate(t=10){const a=this.toHsl();return a.s-=t/100,a.s=en(a.s),new Ge(a)}saturate(t=10){const a=this.toHsl();return a.s+=t/100,a.s=en(a.s),new Ge(a)}greyscale(){return this.desaturate(100)}spin(t){const a=this.toHsl(),n=(a.h+t)%360;return a.h=n<0?360+n:n,new Ge(a)}mix(t,a=50){const n=this.toRgb(),r=new Ge(t).toRgb(),o=a/100,s={r:(r.r-n.r)*o+n.r,g:(r.g-n.g)*o+n.g,b:(r.b-n.b)*o+n.b,a:(r.a-n.a)*o+n.a};return new Ge(s)}analogous(t=6,a=30){const n=this.toHsl(),r=360/a,o=[this];for(n.h=(n.h-(r*t>>1)+720)%360;--t;)n.h=(n.h+r)%360,o.push(new Ge(n));return o}complement(){const t=this.toHsl();return t.h=(t.h+180)%360,new Ge(t)}monochromatic(t=6){const a=this.toHsv(),{h:n}=a,{s:r}=a;let{v:o}=a;const s=[],i=1/t;for(;t--;)s.push(new Ge({h:n,s:r,v:o})),o=(o+i)%1;return s}splitcomplement(){const t=this.toHsl(),{h:a}=t;return[this,new Ge({h:(a+72)%360,s:t.s,l:t.l}),new Ge({h:(a+216)%360,s:t.s,l:t.l})]}onBackground(t){const a=this.toRgb(),n=new Ge(t).toRgb(),r=a.a+n.a*(1-a.a);return new Ge({r:(a.r*a.a+n.r*n.a*(1-a.a))/r,g:(a.g*a.a+n.g*n.a*(1-a.a))/r,b:(a.b*a.a+n.b*n.a*(1-a.a))/r,a:r})}triad(){return this.polyad(3)}tetrad(){return this.polyad(4)}polyad(t){const a=this.toHsl(),{h:n}=a,r=[this],o=360/t;for(let s=1;s<t;s++)r.push(new Ge({h:(n+s*o)%360,s:a.s,l:a.l}));return r}equals(t){const a=new Ge(t);return this.format==="cmyk"||a.format==="cmyk"?this.toCmykString()===a.toCmykString():this.toRgbString()===a.toRgbString()}}function xl(l){"@babel/helpers - typeof";return xl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xl(l)}function Ed(l,t){if(xl(l)!="object"||!l)return l;var a=l[Symbol.toPrimitive];if(a!==void 0){var n=a.call(l,t);if(xl(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(l)}function $d(l){var t=Ed(l,"string");return xl(t)=="symbol"?t:t+""}function Wt(l,t,a){return(t=$d(t))in l?Object.defineProperty(l,t,{value:a,enumerable:!0,configurable:!0,writable:!0}):l[t]=a,l}const mt=Math.round;function xn(l,t){const a=l.replace(/^[^(]*\((.*)/,"$1").replace(/\).*/,"").match(/\d*\.?\d+%?/g)||[],n=a.map(r=>parseFloat(r));for(let r=0;r<3;r+=1)n[r]=t(n[r]||0,a[r]||"",r);return a[3]?n[3]=a[3].includes("%")?n[3]/100:n[3]:n[3]=1,n}const Bo=(l,t,a)=>a===0?l:l/100;function zl(l,t){const a=t||255;return l>a?a:l<0?0:l}class cl{constructor(t){Wt(this,"isValid",!0),Wt(this,"r",0),Wt(this,"g",0),Wt(this,"b",0),Wt(this,"a",1),Wt(this,"_h",void 0),Wt(this,"_s",void 0),Wt(this,"_l",void 0),Wt(this,"_v",void 0),Wt(this,"_max",void 0),Wt(this,"_min",void 0),Wt(this,"_brightness",void 0);function a(n){return n[0]in t&&n[1]in t&&n[2]in t}if(t)if(typeof t=="string"){let r=function(o){return n.startsWith(o)};const n=t.trim();/^#?[A-F\d]{3,8}$/i.test(n)?this.fromHexString(n):r("rgb")?this.fromRgbString(n):r("hsl")?this.fromHslString(n):(r("hsv")||r("hsb"))&&this.fromHsvString(n)}else if(t instanceof cl)this.r=t.r,this.g=t.g,this.b=t.b,this.a=t.a,this._h=t._h,this._s=t._s,this._l=t._l,this._v=t._v;else if(a("rgb"))this.r=zl(t.r),this.g=zl(t.g),this.b=zl(t.b),this.a=typeof t.a=="number"?zl(t.a,1):1;else if(a("hsl"))this.fromHsl(t);else if(a("hsv"))this.fromHsv(t);else throw new Error("@ant-design/fast-color: unsupported input "+JSON.stringify(t))}setR(t){return this._sc("r",t)}setG(t){return this._sc("g",t)}setB(t){return this._sc("b",t)}setA(t){return this._sc("a",t,1)}setHue(t){const a=this.toHsv();return a.h=t,this._c(a)}getLuminance(){function t(o){const s=o/255;return s<=.03928?s/12.92:Math.pow((s+.055)/1.055,2.4)}const a=t(this.r),n=t(this.g),r=t(this.b);return .2126*a+.7152*n+.0722*r}getHue(){if(typeof this._h>"u"){const t=this.getMax()-this.getMin();t===0?this._h=0:this._h=mt(60*(this.r===this.getMax()?(this.g-this.b)/t+(this.g<this.b?6:0):this.g===this.getMax()?(this.b-this.r)/t+2:(this.r-this.g)/t+4))}return this._h}getSaturation(){if(typeof this._s>"u"){const t=this.getMax()-this.getMin();t===0?this._s=0:this._s=t/this.getMax()}return this._s}getLightness(){return typeof this._l>"u"&&(this._l=(this.getMax()+this.getMin())/510),this._l}getValue(){return typeof this._v>"u"&&(this._v=this.getMax()/255),this._v}getBrightness(){return typeof this._brightness>"u"&&(this._brightness=(this.r*299+this.g*587+this.b*114)/1e3),this._brightness}darken(t=10){const a=this.getHue(),n=this.getSaturation();let r=this.getLightness()-t/100;return r<0&&(r=0),this._c({h:a,s:n,l:r,a:this.a})}lighten(t=10){const a=this.getHue(),n=this.getSaturation();let r=this.getLightness()+t/100;return r>1&&(r=1),this._c({h:a,s:n,l:r,a:this.a})}mix(t,a=50){const n=this._c(t),r=a/100,o=i=>(n[i]-this[i])*r+this[i],s={r:mt(o("r")),g:mt(o("g")),b:mt(o("b")),a:mt(o("a")*100)/100};return this._c(s)}tint(t=10){return this.mix({r:255,g:255,b:255,a:1},t)}shade(t=10){return this.mix({r:0,g:0,b:0,a:1},t)}onBackground(t){const a=this._c(t),n=this.a+a.a*(1-this.a),r=o=>mt((this[o]*this.a+a[o]*a.a*(1-this.a))/n);return this._c({r:r("r"),g:r("g"),b:r("b"),a:n})}isDark(){return this.getBrightness()<128}isLight(){return this.getBrightness()>=128}equals(t){return this.r===t.r&&this.g===t.g&&this.b===t.b&&this.a===t.a}clone(){return this._c(this)}toHexString(){let t="#";const a=(this.r||0).toString(16);t+=a.length===2?a:"0"+a;const n=(this.g||0).toString(16);t+=n.length===2?n:"0"+n;const r=(this.b||0).toString(16);if(t+=r.length===2?r:"0"+r,typeof this.a=="number"&&this.a>=0&&this.a<1){const o=mt(this.a*255).toString(16);t+=o.length===2?o:"0"+o}return t}toHsl(){return{h:this.getHue(),s:this.getSaturation(),l:this.getLightness(),a:this.a}}toHslString(){const t=this.getHue(),a=mt(this.getSaturation()*100),n=mt(this.getLightness()*100);return this.a!==1?`hsla(${t},${a}%,${n}%,${this.a})`:`hsl(${t},${a}%,${n}%)`}toHsv(){return{h:this.getHue(),s:this.getSaturation(),v:this.getValue(),a:this.a}}toRgb(){return{r:this.r,g:this.g,b:this.b,a:this.a}}toRgbString(){return this.a!==1?`rgba(${this.r},${this.g},${this.b},${this.a})`:`rgb(${this.r},${this.g},${this.b})`}toString(){return this.toRgbString()}_sc(t,a,n){const r=this.clone();return r[t]=zl(a,n),r}_c(t){return new this.constructor(t)}getMax(){return typeof this._max>"u"&&(this._max=Math.max(this.r,this.g,this.b)),this._max}getMin(){return typeof this._min>"u"&&(this._min=Math.min(this.r,this.g,this.b)),this._min}fromHexString(t){const a=t.replace("#","");function n(r,o){return parseInt(a[r]+a[o||r],16)}a.length<6?(this.r=n(0),this.g=n(1),this.b=n(2),this.a=a[3]?n(3)/255:1):(this.r=n(0,1),this.g=n(2,3),this.b=n(4,5),this.a=a[6]?n(6,7)/255:1)}fromHsl({h:t,s:a,l:n,a:r}){if(this._h=t%360,this._s=a,this._l=n,this.a=typeof r=="number"?r:1,a<=0){const h=mt(n*255);this.r=h,this.g=h,this.b=h}let o=0,s=0,i=0;const c=t/60,d=(1-Math.abs(2*n-1))*a,u=d*(1-Math.abs(c%2-1));c>=0&&c<1?(o=d,s=u):c>=1&&c<2?(o=u,s=d):c>=2&&c<3?(s=d,i=u):c>=3&&c<4?(s=u,i=d):c>=4&&c<5?(o=u,i=d):c>=5&&c<6&&(o=d,i=u);const f=n-d/2;this.r=mt((o+f)*255),this.g=mt((s+f)*255),this.b=mt((i+f)*255)}fromHsv({h:t,s:a,v:n,a:r}){this._h=t%360,this._s=a,this._v=n,this.a=typeof r=="number"?r:1;const o=mt(n*255);if(this.r=o,this.g=o,this.b=o,a<=0)return;const s=t/60,i=Math.floor(s),c=s-i,d=mt(n*(1-a)*255),u=mt(n*(1-a*c)*255),f=mt(n*(1-a*(1-c))*255);switch(i){case 0:this.g=f,this.b=d;break;case 1:this.r=u,this.b=d;break;case 2:this.r=d,this.b=f;break;case 3:this.r=d,this.g=u;break;case 4:this.r=f,this.g=d;break;case 5:default:this.g=d,this.b=u;break}}fromHsvString(t){const a=xn(t,Bo);this.fromHsv({h:a[0],s:a[1],v:a[2],a:a[3]})}fromHslString(t){const a=xn(t,Bo);this.fromHsl({h:a[0],s:a[1],l:a[2],a:a[3]})}fromRgbString(t){const a=xn(t,(n,r)=>r.includes("%")?mt(n/100*255):n);this.r=a[0],this.g=a[1],this.b=a[2],this.a=a[3]}}var ln=2,Eo=.16,Md=.05,Td=.05,Vd=.15,$o=5,Mo=4,Nd=[{index:7,amount:15},{index:6,amount:25},{index:5,amount:30},{index:5,amount:45},{index:5,amount:65},{index:5,amount:85},{index:4,amount:90},{index:3,amount:95},{index:2,amount:97},{index:1,amount:98}];function To(l,t,a){var n;return Math.round(l.h)>=60&&Math.round(l.h)<=240?n=a?Math.round(l.h)-ln*t:Math.round(l.h)+ln*t:n=a?Math.round(l.h)+ln*t:Math.round(l.h)-ln*t,n<0?n+=360:n>=360&&(n-=360),n}function Vo(l,t,a){if(l.h===0&&l.s===0)return l.s;var n;return a?n=l.s-Eo*t:t===Mo?n=l.s+Eo:n=l.s+Md*t,n>1&&(n=1),a&&t===$o&&n>.1&&(n=.1),n<.06&&(n=.06),Math.round(n*100)/100}function No(l,t,a){var n;return a?n=l.v+Td*t:n=l.v-Vd*t,n=Math.max(0,Math.min(1,n)),Math.round(n*100)/100}function zn(l){for(var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=[],n=new cl(l),r=n.toHsv(),o=$o;o>0;o-=1){var s=new cl({h:To(r,o,!0),s:Vo(r,o,!0),v:No(r,o,!0)});a.push(s)}a.push(n);for(var i=1;i<=Mo;i+=1){var c=new cl({h:To(r,i),s:Vo(r,i),v:No(r,i)});a.push(c)}return t.theme==="dark"?Nd.map(function(d){var u=d.index,f=d.amount;return new cl(t.backgroundColor||"#141414").mix(a[u],f).toHexString()}):a.map(function(d){return d.toHexString()})}function xd(l=Date.now(),t="YYYY-MM-DD HH:mm:ss"){try{let a;if(typeof l=="number"||typeof l=="string"){if(a=new Date(l),isNaN(a.getTime()))throw new Error("Invalid date")}else a=l;const n=(o,s=2)=>String(o).padStart(s,"0"),r=o=>{switch(o){case"YYYY":return n(a.getFullYear());case"YY":return n(a.getFullYear()).slice(2,4);case"MM":return n(a.getMonth()+1);case"M":return String(a.getMonth()+1);case"DD":return n(a.getDate());case"D":return String(a.getDate());case"HH":return n(a.getHours());case"H":return String(a.getHours());case"mm":return n(a.getMinutes());case"m":return String(a.getMinutes());case"ss":return n(a.getSeconds());case"s":return String(a.getSeconds());case"SSS":return n(a.getMilliseconds(),3);default:return o}};return t.replace(/(YYYY|YY|M{1,2}|D{1,2}|H{1,2}|m{1,2}|s{1,2}|SSS)/g,r)}catch(a){return console.error("Error formatting date:",a),""}}function Pn(l,t=2,a=",",n=".",r,o){typeof l!="number"&&typeof l!="string"&&console.warn("Expected value to be of type number or string"),typeof t!="number"&&console.warn("Expected precision to be of type number");const s=Number(l);if(isNaN(s)||!isFinite(s))return"";if(s===0)return s.toFixed(t);let i=s.toFixed(t);if(typeof a=="string"&&a!==""){const[c,d]=i.split(".");i=c.replace(/(\d)(?=(\d{3})+$)/g,"$1"+a)+(d?n+d:"")}return(r||"")+i+(o||"")}function na(l,t=0,a=!1){let n=null;function r(s){if(n||(n=s),s-n>=t){try{l()}catch(c){console.error("Error executing rafTimeout function:",c)}a&&(n=s,o.id=requestAnimationFrame(r))}else o.id=requestAnimationFrame(r)}const o={id:requestAnimationFrame(r)};return o}function pt(l){l&&l.id&&typeof l.id=="number"?cancelAnimationFrame(l.id):console.warn("cancelRaf received an invalid id:",l)}function xo(l,t=300){let a=!0;return function(...n){return a&&(l(...n),a=!1,setTimeout(()=>{a=!0},t)),!1}}function ja(l,t=300){let a=null;return function(...n){a&&clearTimeout(a),a=setTimeout(()=>{l(...n)},t)}}function dl(l,t){if(Number.isNaN(l)||Number.isNaN(t))throw new Error("Both num1 and num2 must be valid numbers.");const a=l%1!==0,n=t%1!==0;if(!a&&!n)return l+t;const r=String(l).split(".")[1]??"",o=String(t).split(".")[1]??"",s=Math.max(r.length,o.length),i=Math.pow(10,s),c=l.toFixed(s),d=t.toFixed(s);return(+c.replace(".","")+ +d.replace(".",""))/i}function zo(l,t){if(!l){console.error("无效的 url");return}const a=t||l.split("?")[0].split("/").pop()||"download";try{fetch(l).then(n=>{n.ok?n.blob().then(r=>{const o=URL.createObjectURL(r),s=document.createElement("a");s.href=o,s.download=a,document.body.appendChild(s),s.click(),document.body.removeChild(s),URL.revokeObjectURL(o)}):console.error("请求文件失败,状态码:",n.status)})}catch(n){console.error("文件下载失败:",n)}}function zd(){const l=document.documentElement;l.classList.toggle("dark"),l.classList.contains("dark")?l.style.colorScheme="dark":l.style.colorScheme="light"}function Pd(){const l=e.ref(!1),t=e.getCurrentInstance();return t&&e.onMounted(()=>{l.value=!0},t),l}function Po(l){const t=Pd();return e.computed(()=>(t.value,!!l()))}function Ua(l,t,a){e.onMounted(()=>l.addEventListener(t,a)),e.onUnmounted(()=>l.removeEventListener(t,a))}function ul(l,t,a={}){const n=Po(()=>window&&"MutationObserver"in window),r=e.ref(!1);let o;const s=e.computed(()=>{const f=e.toValue(l);return f?Array.isArray(f)?f.map(h=>e.toValue(h)).filter(h=>h):[f]:[]}),i=()=>{o&&(o.disconnect(),o=void 0)},c=()=>{n.value&&s.value.length&&!r.value&&(o=new MutationObserver(t),s.value.forEach(f=>o.observe(f,a)))};e.watch(()=>s.value,()=>{i(),c()},{immediate:!0,flush:"post"});const d=()=>{r.value=!0,i()},u=()=>{r.value=!1,c()};return e.onBeforeUnmount(()=>i()),{stop:d,start:u}}function Do(l=window,t=0,a,n){const r=e.ref(0),o=e.ref(0),s=e.ref(0),i=e.ref(0),c=e.ref(!1),d=e.ref(!1),u=e.ref(!1),f=e.ref(!1),h=e.ref(!1),w=e.ref(0),y=e.ref(0);function k(M){c.value=!0;const C=M.target.documentElement??M.target;r.value=C.scrollLeft,s.value=C.scrollTop,d.value=r.value<w.value,u.value=r.value>w.value,f.value=s.value<y.value,h.value=s.value>y.value,w.value=r.value,y.value=s.value,m(M),a&&a(M)}const v=xo(k,t);function g(M){c.value&&(c.value=!1,d.value=!1,u.value=!1,f.value=!1,h.value=!1,n&&n(M))}const m=ja(g,t+200),p=e.computed(()=>{const M=e.toValue(l);return M||null});e.watch(()=>p.value,(M,C)=>{var T;if(C&&b(C),M){const B=((T=M==null?void 0:M.document)==null?void 0:T.documentElement)||(M==null?void 0:M.documentElement)||M;o.value=B.scrollWidth-B.clientWidth,i.value=B.scrollHeight-B.clientHeight,B.addEventListener("scroll",v),B.addEventListener("scrollend",m)}},{immediate:!0,flush:"post"});function b(M){var T;const C=((T=M==null?void 0:M.document)==null?void 0:T.documentElement)||(M==null?void 0:M.documentElement)||M;C.removeEventListener("scroll",v),C.removeEventListener("scrollend",m)}return e.onBeforeUnmount(()=>b(p.value)),{x:r,xScrollMax:o,y:s,yScrollMax:i,isScrolling:c,left:d,right:u,top:f,bottom:h}}function Dd(){const l=e.ref(0),t=e.ref(0);let a=performance.now();const n=10,r=o=>{if(t.value++,t.value>=n){const s=o-a;l.value=Math.round(1e3/(s/n)),a=o,t.value=0}requestAnimationFrame(r)};return requestAnimationFrame(r),{fps:l}}function Ad(l){if(!l||typeof l!="string"||l.trim()==="")throw new Error("Invalid mediaQuery parameter. It must be a non-empty string.");const t=e.ref(window&&window.matchMedia(l).matches),a=window.matchMedia(l),n=r=>{t.value=r.matches};return e.onMounted(()=>{a.addEventListener("change",n)}),e.onBeforeUnmount(()=>{a.removeEventListener("change",n)}),{match:t}}function Ut(l,t,a={}){const n=Po(()=>window&&"ResizeObserver"in window);let r;const o=e.ref(!1),s=e.computed(()=>{const f=e.toValue(l);return f?Array.isArray(f)?f.map(h=>e.toValue(h)).filter(h=>h):[f]:[]}),i=()=>{r&&(r.disconnect(),r=void 0)},c=()=>{n.value&&s.value.length&&!o.value&&(r=new ResizeObserver(t),s.value.forEach(f=>r.observe(f,a)))};e.watch(()=>s.value,()=>{i(),c()},{immediate:!0,flush:"post"});const d=()=>{o.value=!0,i()},u=()=>{o.value=!1,c()};return e.onBeforeUnmount(()=>i()),{stop:d,start:u}}function Ie(l="default"){const t=e.useSlots(),a=n=>{var s;const r=(s=t[n])==null?void 0:s.call(t),o=i=>{if(i.type===e.Comment||Array.isArray(i.children)&&!i.children.length)return!1;if(i.type!==e.Text)return!0;if(typeof i.children=="string")return i.children.trim()!==""};return r&&(r!=null&&r.length)?r.some(c=>o(c)):!1};if(Array.isArray(l)){const n=e.reactive({});return l.forEach(r=>{const o=e.computed(()=>a(r));n[r]=o}),n}else return e.computed(()=>a(l))}function He(l){const t=Ld("#1677ff"),a=e.inject("common",e.reactive({colorPalettes:t,shadowColor:_d(t[0])})),n=e.inject("components",null);return n!==null&&l in n&&n[l].colorPalettes.length?e.toRefs(n[l]):e.toRefs(a)}function Ld(l){return zn(l)}function Dn(l){return l>=0&&l<=255}function _d(l,t="#ffffff"){const{r:a,g:n,b:r,a:o}=new Ge(l).toRgb();if(o<1)return l;const{r:s,g:i,b:c}=new Ge(t).toRgb();for(let d=.01;d<=1;d+=.01){const u=Math.round((a-s*(1-d))/d),f=Math.round((n-i*(1-d))/d),h=Math.round((r-c*(1-d))/d);if(Dn(u)&&Dn(f)&&Dn(h))return new Ge({r:u,g:f,b:h,a:Math.round(d*100)/100}).toRgbString()}return new Ge({r:a,g:n,b:r,a:1}).toRgbString()}const Fd={key:0,class:"m-alert-icon"},Rd=["src"],Od={key:1,class:"icon-svg",focusable:"false","data-icon":"info-circle",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",viewBox:"64 64 896 896"},Id={key:2,class:"icon-svg",focusable:"false","data-icon":"check-circle",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",viewBox:"64 64 896 896"},Hd={key:3,class:"icon-svg",focusable:"false","data-icon":"exclamation-circle",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",viewBox:"64 64 896 896"},Yd={key:4,class:"icon-svg",focusable:"false","data-icon":"close-circle",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",viewBox:"64 64 896 896"},Wd={key:1,class:"m-big-icon"},qd=["src"],jd={key:1,class:"icon-svg",focusable:"false","data-icon":"info-circle",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",viewBox:"64 64 896 896"},Ud={key:2,class:"icon-svg",focusable:"false","data-icon":"check-circle",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",viewBox:"64 64 896 896"},Gd={key:3,class:"icon-svg",focusable:"false","data-icon":"exclamation-circle",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",viewBox:"64 64 896 896"},Kd={key:4,class:"icon-svg",focusable:"false","data-icon":"close-circle",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",viewBox:"64 64 896 896"},Xd={class:"m-alert-content"},Qd={class:"alert-message"},Zd={key:0,class:"alert-description"},Jd={key:1,class:"m-alert-actions"},eu=["onKeydown"],tu={key:0},au={key:1,class:"alert-close",focusable:"false","data-icon":"close",width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",viewBox:"64 64 896 896"},lu=e.defineComponent({__name:"Alert",props:{message:{default:void 0},description:{default:void 0},type:{default:"default"},bordered:{type:Boolean,default:!0},closable:{type:Boolean,default:!1},closeText:{default:void 0},icon:{default:void 0},showIcon:{type:Boolean,default:!1},actions:{default:void 0}},emits:["close"],setup(l,{emit:t}){const a=l,n=e.ref(),r=e.ref(!1),{colorPalettes:o}=He("Alert"),s=t,i=Ie(["icon","description","actions"]),c=e.computed(()=>i.icon||a.icon||["success","info","warning","error"].includes(a.type)),d=e.computed(()=>i.description||a.description);async function u(f){n.value.style.maxHeight=`${n.value.offsetHeight}px`,await e.nextTick(),r.value=!0,s("close",f)}return(f,h)=>(e.openBlock(),e.createBlock(e.Transition,{name:"alert-motion","leave-from-class":"alert-motion-leave","leave-active-class":"alert-motion-leave alert-motion-leave-active","leave-to-class":"alert-motion-leave alert-motion-leave-active"},{default:e.withCtx(()=>[r.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"alertRef",ref:n,class:e.normalizeClass(["m-alert",[`alert-${f.type}`,{"alert-borderless":!f.bordered,"alert-width-description":d.value}]]),style:e.normalizeStyle(`
--alert-primary-color: ${e.unref(o)[5]};
--alert-primary-bg-color: ${e.unref(o)[0]};
--alert-primary-border-color: ${e.unref(o)[2]};
--alert-success-color: #52c41a;
--alert-success-bg-color: #f6ffed;
--alert-success-border-color: #b7eb8f;
--alert-warning-color: #faad14;
--alert-warning-bg-color: #fffbe6;
--alert-warning-border-color: #ffe58f;
--alert-error-color: #ff4d4f;
--alert-error-bg-color: #fff2f0;
--alert-error-border-color: #ffccc7;
`)},[f.showIcon&&c.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[d.value?(e.openBlock(),e.createElementBlock("span",Wd,[e.renderSlot(f.$slots,"icon",{},()=>[f.icon?(e.openBlock(),e.createElementBlock("img",{key:0,src:f.icon,class:"big-icon-img"},null,8,qd)):f.type==="info"?(e.openBlock(),e.createElementBlock("svg",jd,h[4]||(h[4]=[e.createElementVNode("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"},null,-1),e.createElementVNode("path",{d:"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z"},null,-1)]))):f.type==="success"?(e.openBlock(),e.createElementBlock("svg",Ud,h[5]||(h[5]=[e.createElementVNode("path",{d:"M699 353h-46.9c-10.2 0-19.9 4.9-25.9 13.3L469 584.3l-71.2-98.8c-6-8.3-15.6-13.3-25.9-13.3H325c-6.5 0-10.3 7.4-6.5 12.7l124.6 172.8a31.8 31.8 0 0051.7 0l210.6-292c3.9-5.3.1-12.7-6.4-12.7z"},null,-1),e.createElementVNode("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"},null,-1)]))):f.type==="warning"?(e.openBlock(),e.createElementBlock("svg",Gd,h[6]||(h[6]=[e.createElementVNode("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"},null,-1),e.createElementVNode("path",{d:"M464 688a48 48 0 1096 0 48 48 0 10-96 0zm24-112h48c4.4 0 8-3.6 8-8V296c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8z"},null,-1)]))):f.type==="error"?(e.openBlock(),e.createElementBlock("svg",Kd,h[7]||(h[7]=[e.createElementVNode("path",{d:"M685.4 354.8c0-4.4-3.6-8-8-8l-66 .3L512 465.6l-99.3-118.4-66.1-.3c-4.4 0-8 3.5-8 8 0 1.9.7 3.7 1.9 5.2l130.1 155L340.5 670a8.32 8.32 0 00-1.9 5.2c0 4.4 3.6 8 8 8l66.1-.3L512 564.4l99.3 118.4 66 .3c4.4 0 8-3.5 8-8 0-1.9-.7-3.7-1.9-5.2L553.5 515l130.1-155c1.2-1.4 1.8-3.3 1.8-5.2z"},null,-1),e.createElementVNode("path",{d:"M512 65C264.6 65 64 265.6 64 513s200.6 448 448 448 448-200.6 448-448S759.4 65 512 65zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"},null,-1)]))):e.createCommentVNode("",!0)],!0)])):(e.openBlock(),e.createElementBlock("span",Fd,[e.renderSlot(f.$slots,"icon",{},()=>[f.icon?(e.openBlock(),e.createElementBlock("img",{key:0,src:f.icon,class:"icon-img"},null,8,Rd)):f.type==="info"?(e.openBlock(),e.createElementBlock("svg",Od,h[0]||(h[0]=[e.createElementVNode("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"},null,-1)]))):f.type==="success"?(e.openBlock(),e.createElementBlock("svg",Id,h[1]||(h[1]=[e.createElementVNode("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"},null,-1)]))):f.type==="warning"?(e.openBlock(),e.createElementBlock("svg",Hd,h[2]||(h[2]=[e.createElementVNode("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"},null,-1)]))):f.type==="error"?(e.openBlock(),e.createElementBlock("svg",Yd,h[3]||(h[3]=[e.createElementVNode("path",{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm165.4 618.2l-66-.3L512 563.4l-99.3 118.4-66.1.3c-4.4 0-8-3.5-8-8 0-1.9.7-3.7 1.9-5.2l130.1-155L340.5 359a8.32 8.32 0 01-1.9-5.2c0-4.4 3.6-8 8-8l66.1.3L512 464.6l99.3-118.4 66-.3c4.4 0 8 3.5 8 8 0 1.9-.7 3.7-1.9 5.2L553.5 514l130 155c1.2 1.5 1.9 3.3 1.9 5.2 0 4.4-3.6 8-8 8z"},null,-1)]))):e.createCommentVNode("",!0)],!0)]))],64)):e.createCommentVNode("",!0),e.createElementVNode("div",Xd,[e.createElementVNode("div",Qd,[e.renderSlot(f.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(f.message),1)],!0)]),d.value?(e.openBlock(),e.createElementBlock("div",Zd,[e.renderSlot(f.$slots,"description",{},()=>[e.createTextVNode(e.toDisplayString(f.description),1)],!0)])):e.createCommentVNode("",!0)]),e.unref(i).actions?(e.openBlock(),e.createElementBlock("div",Jd,[e.renderSlot(f.$slots,"actions",{},void 0,!0)])):e.createCommentVNode("",!0),f.closable?(e.openBlock(),e.createElementBlock("a",{key:2,tabindex:"0",class:"m-alert-close",onClick:u,onKeydown:e.withKeys(e.withModifiers(u,["prevent"]),["enter"])},[e.renderSlot(f.$slots,"closeText",{},()=>[f.closeText?(e.openBlock(),e.createElementBlock("span",tu,e.toDisplayString(f.closeText),1)):(e.openBlock(),e.createElementBlock("svg",au,h[8]||(h[8]=[e.createElementVNode("path",{d:"M563.8 512l262.5-312.9c4.4-5.2.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9A7.95 7.95 0 00203 838h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z"},null,-1)])))],!0)],40,eu)):e.createCommentVNode("",!0)],6))]),_:3}))}}),Te=(l,t)=>{const a=l.__vccOpts||l;for(const[n,r]of t)a[n]=r;return a},nu=Te(lu,[["__scopeId","data-v-922b8af5"]]),Be=l=>{const t=l;return t.install=function(a){a.component(t.__name,l)},l},Ao=Be(nu),ru=["src","alt"],An=Be(Te(e.defineComponent({__name:"Avatar",props:{color:{default:"rgba(0, 0, 0, 0.25)"},shape:{default:"circle"},size:{default:"middle"},src:{default:void 0},alt:{default:void 0},icon:{default:void 0},href:{default:void 0},target:{default:"_self"}},setup(l){const t=l,a=e.ref(window.innerWidth),n=Ie(["default","icon"]),r=e.computed(()=>t.src?!1:!!(n.icon||t.icon)),o=e.computed(()=>{if(typeof t.size=="number")return r.value?{backgroundColor:t.color,width:`${t.size}px`,height:`${t.size}px`,lineHeight:`${t.size}px`,fontSize:`${t.size/2}px`}:{backgroundColor:t.color,width:`${t.size}px`,height:`${t.size}px`,lineHeight:`${t.size}px`,fontSize:"18px"};if(typeof t.size=="object"){let d=32;return a.value>=1600&&t.size.xxl!==void 0?d=t.size.xxl:a.value>=1200&&t.size.xl!==void 0?d=t.size.xl:a.value>=992&&t.size.lg!==void 0?d=t.size.lg:a.value>=768&&t.size.md!==void 0?d=t.size.md:a.value>=576&&t.size.sm!==void 0?d=t.size.sm:a.value<576&&t.size.xs!==void 0&&(d=t.size.xs),{backgroundColor:t.color,width:`${d}px`,height:`${d}px`,lineHeight:`${d}px`,fontSize:`${d/2}px`}}return{backgroundColor:t.color}}),s=e.computed(()=>!t.src&&!r.value?n.default:!1),i=e.computed(()=>{if(typeof t.size=="string")return{transform:"scale(1) translateX(-50%)"};if(typeof t.size=="number"){const d=Math.min(1,Math.max(.022222222222222223,(1+(t.size-9)*1)/45));return{lineHeight:`${t.size}px`,transform:`scale(${d}) translateX(-50%)`}}return{}});Ua(window,"resize",c);function c(){a.value=window.innerWidth}return(d,u)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(d.href?"a":"div"),{class:e.normalizeClass(["m-avatar",[`avatar-${d.shape}`,{[`avatar-${d.size}`]:typeof d.size=="string"&&["small","middle","large"].includes(d.size),"avatar-image":d.src,"avatar-link":d.href}]]),style:e.normalizeStyle(o.value),href:d.href,target:d.target},{default:e.withCtx(()=>[d.src?(e.openBlock(),e.createElementBlock("img",{key:0,class:"image-item",src:d.src,alt:d.alt},null,8,ru)):e.createCommentVNode("",!0),!d.src&&r.value?e.renderSlot(d.$slots,"icon",{key:1},()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(d.icon)))],!0):e.createCommentVNode("",!0),s.value?(e.openBlock(),e.createElementBlock("span",{key:2,class:"string-item",style:e.normalizeStyle(i.value)},[e.renderSlot(d.$slots,"default",{},void 0,!0)],4)):e.createCommentVNode("",!0)]),_:3},8,["class","style","href","target"]))}}),[["__scopeId","data-v-a9ed35a8"]])),Gt=Be(Te(e.defineComponent({__name:"Tooltip",props:{maxWidth:{default:240},content:{default:void 0},contentClass:{default:void 0},contentStyle:{default:()=>({})},tooltip:{default:void 0},tooltipClass:{default:void 0},tooltipStyle:{default:()=>({})},bgColor:{default:"rgba(0, 0, 0, 0.85)"},arrow:{type:Boolean,default:!0},placement:{default:"top"},flip:{type:Boolean,default:!0},trigger:{default:"hover"},keyboard:{type:Boolean,default:!1},transitionDuration:{default:100},showDelay:{default:100},hideDelay:{default:100},show:{type:Boolean,default:!1},showControl:{type:Boolean,default:!1}},emits:["update:show","openChange","animationend"],setup(l,{expose:t,emit:a}){const n=l,r=e.ref(!1),o=e.ref(),s=e.ref(null),i=e.ref(0),c=e.ref(0),d=e.ref("top"),u=e.ref(),f=e.ref(0),h=e.ref(0),w=e.ref(),y=e.ref(),k=e.ref(0),v=e.ref(0),g=e.ref(document.documentElement.clientWidth),m=e.ref(document.documentElement.clientHeight),p=a,b=Ie(["tooltip"]),M=e.computed(()=>typeof n.maxWidth=="number"?`${n.maxWidth}px`:n.maxWidth),C=e.computed(()=>b.tooltip||n.tooltip),T=e.computed(()=>{switch(d.value){case"top":return{transformOrigin:`50% ${i.value}px`,top:`${-i.value}px`,left:`${-c.value}px`};case"bottom":return{transformOrigin:`50% ${n.arrow?-4:-6}px`,bottom:`${-i.value}px`,left:`${-c.value}px`};case"left":return{transformOrigin:`${c.value}px 50%`,top:`${-i.value}px`,left:`${-c.value}px`};case"right":return{transformOrigin:`${n.arrow?-4:-6}px 50%`,top:`${-i.value}px`,right:`${-c.value}px`};default:return{transformOrigin:`50% ${i.value}px`,top:`${-i.value}px`,left:`${-c.value}px`}}});e.watch(()=>[n.placement,n.arrow,n.flip],()=>{x()},{deep:!0}),e.watch(()=>n.show,K=>{K&&!r.value&&Y(),!K&&r.value&&I()},{immediate:!0}),e.onMounted(()=>{E()}),e.onBeforeUnmount(()=>{$()});const B=ul(s,()=>{x()},{subtree:!0,childList:!0,attributes:!0,characterData:!0});Ua(window,"resize",S),Ut([y,u],K=>{if(K.length===1&&K[0].target.className==="tooltip-card"){const{blockSize:N,inlineSize:R}=K[0].borderBoxSize[0];if(N===v.value&&R===k.value)return}x()});function S(){g.value=document.documentElement.clientWidth,m.value=document.documentElement.clientHeight,E(),x()}function E(){var K;$(),s.value=P(((K=u.value)==null?void 0:K.parentElement)??null),s.value&&s.value.addEventListener("scroll",x),s.value===document.documentElement&&B.start()}function $(){s.value&&s.value.removeEventListener("scroll",x),s.value=null,B.stop()}function P(K){const N=R=>{const le=window.getComputedStyle(R);return!!(R.scrollWidth>R.clientWidth&&["scroll","auto"].includes(le.overflowX)||R.scrollHeight>R.clientHeight&&["scroll","auto"].includes(le.overflowY)||(R.scrollWidth>R.clientWidth||R.scrollHeight>R.clientHeight)&&R===document.documentElement)};return K?N(K)?K:P(K.parentElement??null):null}function x(){r.value&&V()}async function V(){await e.nextTick(),f.value=u.value.offsetWidth,h.value=u.value.offsetHeight,k.value=y.value.offsetWidth,v.value=y.value.offsetHeight,n.flip&&(d.value=_()),["top","bottom"].includes(d.value)?(i.value=v.value+(n.arrow?16:6),c.value=(k.value-f.value)/2):(i.value=(v.value-h.value)/2,c.value=k.value+(n.arrow?16:6))}function z(){return s.value&&s.value!==document.documentElement?s.value.getBoundingClientRect():{top:0,left:0,bottom:m.value,right:g.value}}function _(){const{top:K,bottom:N,left:R,right:le}=u.value.getBoundingClientRect(),{top:ge,bottom:J,left:be,right:ee}=z(),j=K-ge-(n.arrow?12:0),D=J-N-(n.arrow?12:0),Q=R-be-(n.arrow?12:0),oe=ee-le-(n.arrow?12:0),se=(k.value-f.value)/2,Me=(v.value-h.value)/2;return ve(n.placement,[]);function ve(Pe,Se){if(Pe==="top"){if(Se.includes("top"))return Se.includes("bottom")?Se.includes("left")?ve("right",Se):ve("left",Se):ve("bottom",Se);if(j<v.value+(n.arrow?4:6)&&Se.length!==3)return ve("bottom",[...Se,"top"]);if(Q>=se&&oe>=se)return"top";if(Se.length!==3){if(Q>=se)return ve("left",["top","bottom","right"]);if(oe>=se)return ve("right",["top","bottom","left"])}}else if(Pe==="bottom"){if(Se.includes("bottom"))return Se.includes("top")?Se.includes("left")?ve("right",Se):ve("left",Se):ve("top",Se);if(D<v.value+(n.arrow?4:6)&&Se.length!==3)return ve("top",[...Se,"bottom"]);if(Q>=se&&oe>=se)return"bottom";if(Se.length!==3){if(Q>=se)return ve("left",["top","bottom","right"]);if(oe>=se)return ve("right",["top","bottom","left"])}}else if(Pe==="left"){if(Se.includes("left"))return Se.includes("right")?Se.includes("top")?ve("bottom",Se):ve("top",Se):ve("right",Se);if(Q<k.value+(n.arrow?4:6)&&Se.length!==3)return ve("right",[...Se,"left"]);if(j>=Me&&D>=Me)return"left";if(Se.length!==3){if(j>=Me)return ve("top",["left","right","bottom"]);if(D>=Me)return ve("bottom",["left","right","top"])}}else if(Pe==="right"){if(Se.includes("right"))return Se.includes("left")?Se.includes("top")?ve("bottom",Se):ve("top",Se):ve("left",Se);if(oe<k.value+(n.arrow?4:6)&&Se.length!==3)return ve("left",[...Se,"right"]);if(j>=Me&&D>=Me)return"right";if(Se.length!==3){if(j>=Me)return ve("top",["left","right","bottom"]);if(D>=Me)return ve("bottom",["left","right","top"])}}return n.placement}}function Y(){o.value&&pt(o.value),r.value||(o.value=na(()=>{r.value=!0,V(),p("update:show",!0),p("openChange",!0),C.value&&n.trigger==="click"&&document.addEventListener("click",U)},n.showDelay))}function I(){o.value&&pt(o.value),r.value&&(o.value=na(()=>{r.value=!1,p("update:show",!1),p("openChange",!1),C.value&&n.trigger==="click"&&document.removeEventListener("click",U)},n.hideDelay))}function Z(){r.value?I():Y()}function U(K){w.value.contains(K.target)||I()}function A(){C.value&&n.trigger==="hover"&&!n.showControl&&Y()}function H(){C.value&&n.trigger==="hover"&&!n.showControl&&I()}function F(){p("animationend",r.value)}function W(){n.trigger==="hover"&&!n.showControl&&Y()}function G(){n.trigger==="hover"&&!n.showControl&&I()}return t({show:Y,hide:I,observeScroll:E}),(K,N)=>(e.openBlock(),e.createElementBlock("div",{class:"m-tooltip-wrap",style:e.normalizeStyle(`--tooltip-max-width: ${M.value}; --tooltip-background-color: ${K.bgColor}; --transition-duration: ${K.transitionDuration}ms;`),onMouseenter:A,onMouseleave:H},[e.createVNode(e.Transition,{name:"zoom","enter-from-class":"zoom-enter","enter-active-class":"zoom-enter","enter-to-class":"zoom-enter zoom-enter-active","leave-from-class":"zoom-leave","leave-active-class":"zoom-leave zoom-leave-active","leave-to-class":"zoom-leave zoom-leave-active",onAnimationend:F},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{ref_key:"tooltipRef",ref:w,class:e.normalizeClass(["m-tooltip-card",{[`tooltip-${d.value}-padding`]:K.arrow}]),style:e.normalizeStyle(T.value),onMouseenter:W,onMouseleave:G,onKeydown:N[0]||(N[0]=e.withKeys(R=>K.trigger==="click"&&K.keyboard&&r.value?I():()=>!1,["esc"]))},[e.createElementVNode("div",{ref_key:"tooltipCardRef",ref:y,class:e.normalizeClass(["tooltip-card",K.tooltipClass]),style:e.normalizeStyle(K.tooltipStyle)},[e.renderSlot(K.$slots,"tooltip",{},()=>[e.createTextVNode(e.toDisplayString(K.tooltip),1)],!0)],6),K.arrow?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["tooltip-arrow",`arrow-${d.value||"top"}`])},null,2)):e.createCommentVNode("",!0)],38),[[e.vShow,C.value&&r.value]])]),_:3}),e.createElementVNode("span",{ref_key:"contentRef",ref:u,class:e.normalizeClass(["tooltip-content",K.contentClass]),style:e.normalizeStyle(K.contentStyle),onClick:N[1]||(N[1]=R=>C.value&&K.trigger==="click"&&!r.value?Y():()=>!1),onKeydown:[N[2]||(N[2]=e.withKeys(R=>C.value&&K.trigger==="click"&&K.keyboard?Z():()=>!1,["enter"])),N[3]||(N[3]=e.withKeys(R=>C.value&&K.trigger==="click"&&K.keyboard&&r.value?I():()=>!1,["esc"]))]},[e.renderSlot(K.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(K.content),1)],!0)],38)],36))}}),[["__scopeId","data-v-afdd9188"]])),ou={key:1,width:"1em",height:"1em",viewBox:"0 0 24 24",version:"1.1",xmlns:"http://www.w3.org/2000/svg",xlinkHref:"http://www.w3.org/1999/xlink"},su={key:0,class:"backtop-description"},Lo=Be(Te(e.defineComponent({__name:"BackTop",props:{icon:{default:void 0},description:{default:void 0},tooltip:{default:void 0},tooltipProps:{default:()=>({})},type:{default:"default"},shape:{default:"circle"},bottom:{default:40},right:{default:40},zIndex:{default:9},visibilityHeight:{default:180},to:{default:"body"},listenTo:{default:void 0}},emits:["click","show"],setup(l,{emit:t}){const a=l,n=e.ref(null),r=e.ref(0),o=e.ref(null),s=e.ref(null),{colorPalettes:i}=He("BackTop"),c=t,d=Ie(["tooltip","icon","description"]),u=e.computed(()=>({bottom:typeof a.bottom=="number"?`${a.bottom}px`:a.bottom,right:typeof a.right=="number"?`${a.right}px`:a.right})),f=e.computed(()=>r.value>=a.visibilityHeight),h=e.computed(()=>d.tooltip||a.tooltip),w=e.computed(()=>d.description||a.description);e.watch(()=>a.to,()=>{m()},{flush:"post"}),e.watch(()=>a.listenTo,()=>{v()},{flush:"post"}),e.watch(f,C=>{c("show",C)}),e.onMounted(()=>{v()}),e.onBeforeUnmount(()=>{var C;g(),(C=n.value)==null||C.remove()});const y=ul(o,()=>{var C;r.value=((C=o.value)==null?void 0:C.scrollTop)??0},{subtree:!0,childList:!0,attributes:!0,characterData:!0});function k(C){r.value=C.target.scrollTop}function v(){g(),a.listenTo===void 0?o.value=b(n.value):typeof a.listenTo=="string"?o.value=document.getElementsByTagName(a.listenTo)[0]:a.listenTo instanceof HTMLElement&&(o.value=a.listenTo),o.value||console.warn("Container of back-top element is not found."),o.value&&o.value.addEventListener("scroll",k),o.value===document.documentElement&&y.start(),m()}function g(){o.value&&o.value.removeEventListener("scroll",k),o.value=null,y.stop()}function m(){var C;typeof a.to=="string"?s.value=document.getElementsByTagName(a.to)[0]:a.to instanceof HTMLElement&&(s.value=a.to),s.value&&((C=s.value)==null||C.appendChild(n.value))}function p(C){return C===document.documentElement?null:C.parentElement}function b(C){if(C===null)return null;const T=p(C);return T===null?null:T===document.documentElement?document.documentElement:(S=