@xlui/xux-ui 0.2.1 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.css +1 -1
- package/dist/index.js +22 -22
- package/dist/index.mjs +989 -927
- package/package.json +1 -1
- package/src/components/Card/index.vue +44 -11
- package/src/components/Switch/index.vue +234 -0
- package/src/index.ts +1 -0
package/dist/index.js
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),We=/^[a-z0-9]+(-[a-z0-9]+)*$/,ye=(t,l,o,n="")=>{const a=t.split(":");if(t.slice(0,1)==="@"){if(a.length<2||a.length>3)return null;n=a.shift().slice(1)}if(a.length>3||!a.length)return null;if(a.length>1){const i=a.pop(),r=a.pop(),d={provider:a.length>0?a[0]:n,prefix:r,name:i};return l&&!me(d)?null:d}const s=a[0],c=s.split("-");if(c.length>1){const i={provider:n,prefix:c.shift(),name:c.join("-")};return l&&!me(i)?null:i}if(o&&n===""){const i={provider:n,prefix:"",name:s};return l&&!me(i,o)?null:i}return null},me=(t,l)=>t?!!((l&&t.prefix===""||t.prefix)&&t.name):!1,Re=Object.freeze({left:0,top:0,width:16,height:16}),ve=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),we=Object.freeze({...Re,...ve}),Se=Object.freeze({...we,body:"",hidden:!1});function Ct(t,l){const o={};!t.hFlip!=!l.hFlip&&(o.hFlip=!0),!t.vFlip!=!l.vFlip&&(o.vFlip=!0);const n=((t.rotate||0)+(l.rotate||0))%4;return n&&(o.rotate=n),o}function De(t,l){const o=Ct(t,l);for(const n in Se)n in ve?n in t&&!(n in o)&&(o[n]=ve[n]):n in l?o[n]=l[n]:n in t&&(o[n]=t[n]);return o}function kt(t,l){const o=t.icons,n=t.aliases||Object.create(null),a=Object.create(null);function s(c){if(o[c])return a[c]=[];if(!(c in a)){a[c]=null;const i=n[c]&&n[c].parent,r=i&&s(i);r&&(a[c]=[i].concat(r))}return a[c]}return Object.keys(o).concat(Object.keys(n)).forEach(s),a}function St(t,l,o){const n=t.icons,a=t.aliases||Object.create(null);let s={};function c(i){s=De(n[i]||a[i],s)}return c(l),o.forEach(c),De(t,s)}function Ge(t,l){const o=[];if(typeof t!="object"||typeof t.icons!="object")return o;t.not_found instanceof Array&&t.not_found.forEach(a=>{l(a,null),o.push(a)});const n=kt(t);for(const a in n){const s=n[a];s&&(l(a,St(t,a,s)),o.push(a))}return o}const xt={provider:"",aliases:{},not_found:{},...Re};function Ce(t,l){for(const o in l)if(o in t&&typeof t[o]!=typeof l[o])return!1;return!0}function Ue(t){if(typeof t!="object"||t===null)return null;const l=t;if(typeof l.prefix!="string"||!t.icons||typeof t.icons!="object"||!Ce(t,xt))return null;const o=l.icons;for(const a in o){const s=o[a];if(!a||typeof s.body!="string"||!Ce(s,Se))return null}const n=l.aliases||Object.create(null);for(const a in n){const s=n[a],c=s.parent;if(!a||typeof c!="string"||!o[c]&&!n[c]||!Ce(s,Se))return null}return l}const Ae=Object.create(null);function Et(t,l){return{provider:t,prefix:l,icons:Object.create(null),missing:new Set}}function ie(t,l){const o=Ae[t]||(Ae[t]=Object.create(null));return o[l]||(o[l]=Et(t,l))}function Ke(t,l){return Ue(l)?Ge(l,(o,n)=>{n?t.icons[o]=n:t.missing.add(o)}):[]}function $t(t,l,o){try{if(typeof o.body=="string")return t.icons[l]={...o},!0}catch{}return!1}let fe=!1;function qe(t){return typeof t=="boolean"&&(fe=t),fe}function Mt(t){const l=typeof t=="string"?ye(t,!0,fe):t;if(l){const o=ie(l.provider,l.prefix),n=l.name;return o.icons[n]||(o.missing.has(n)?null:void 0)}}function Pt(t,l){const o=ye(t,!0,fe);if(!o)return!1;const n=ie(o.provider,o.prefix);return l?$t(n,o.name,l):(n.missing.add(o.name),!0)}function Bt(t,l){if(typeof t!="object")return!1;if(typeof l!="string"&&(l=t.provider||""),fe&&!l&&!t.prefix){let a=!1;return Ue(t)&&(t.prefix="",Ge(t,(s,c)=>{Pt(s,c)&&(a=!0)})),a}const o=t.prefix;if(!me({prefix:o,name:"a"}))return!1;const n=ie(l,o);return!!Ke(n,t)}const Ze=Object.freeze({width:null,height:null}),Qe=Object.freeze({...Ze,...ve}),jt=/(-?[0-9.]*[0-9]+[0-9.]*)/g,Vt=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function Te(t,l,o){if(l===1)return t;if(o=o||100,typeof t=="number")return Math.ceil(t*l*o)/o;if(typeof t!="string")return t;const n=t.split(jt);if(n===null||!n.length)return t;const a=[];let s=n.shift(),c=Vt.test(s);for(;;){if(c){const i=parseFloat(s);isNaN(i)?a.push(s):a.push(Math.ceil(i*l*o)/o)}else a.push(s);if(s=n.shift(),s===void 0)return a.join("");c=!c}}function Nt(t,l="defs"){let o="";const n=t.indexOf("<"+l);for(;n>=0;){const a=t.indexOf(">",n),s=t.indexOf("</"+l);if(a===-1||s===-1)break;const c=t.indexOf(">",s);if(c===-1)break;o+=t.slice(a+1,s).trim(),t=t.slice(0,n).trim()+t.slice(c+1)}return{defs:o,content:t}}function Dt(t,l){return t?"<defs>"+t+"</defs>"+l:l}function At(t,l,o){const n=Nt(t);return Dt(n.defs,l+n.content+o)}const Tt=t=>t==="unset"||t==="undefined"||t==="none";function zt(t,l){const o={...we,...t},n={...Qe,...l},a={left:o.left,top:o.top,width:o.width,height:o.height};let s=o.body;[o,n].forEach(u=>{const f=[],y=u.hFlip,k=u.vFlip;let w=u.rotate;y?k?w+=2:(f.push("translate("+(a.width+a.left).toString()+" "+(0-a.top).toString()+")"),f.push("scale(-1 1)"),a.top=a.left=0):k&&(f.push("translate("+(0-a.left).toString()+" "+(a.height+a.top).toString()+")"),f.push("scale(1 -1)"),a.top=a.left=0);let S;switch(w<0&&(w-=Math.floor(w/4)*4),w=w%4,w){case 1:S=a.height/2+a.top,f.unshift("rotate(90 "+S.toString()+" "+S.toString()+")");break;case 2:f.unshift("rotate(180 "+(a.width/2+a.left).toString()+" "+(a.height/2+a.top).toString()+")");break;case 3:S=a.width/2+a.left,f.unshift("rotate(-90 "+S.toString()+" "+S.toString()+")");break}w%2===1&&(a.left!==a.top&&(S=a.left,a.left=a.top,a.top=S),a.width!==a.height&&(S=a.width,a.width=a.height,a.height=S)),f.length&&(s=At(s,'<g transform="'+f.join(" ")+'">',"</g>"))});const c=n.width,i=n.height,r=a.width,d=a.height;let g,p;c===null?(p=i===null?"1em":i==="auto"?d:i,g=Te(p,r/d)):(g=c==="auto"?r:c,p=i===null?Te(g,d/r):i==="auto"?d:i);const v={},h=(u,f)=>{Tt(f)||(v[u]=f.toString())};h("width",g),h("height",p);const x=[a.left,a.top,r,d];return v.viewBox=x.join(" "),{attributes:v,viewBox:x,body:s}}const It=/\sid="(\S+)"/g,Ot="IconifyId"+Date.now().toString(16)+(Math.random()*16777216|0).toString(16);let Lt=0;function Yt(t,l=Ot){const o=[];let n;for(;n=It.exec(t);)o.push(n[1]);if(!o.length)return t;const a="suffix"+(Math.random()*16777216|Date.now()).toString(16);return o.forEach(s=>{const c=typeof l=="function"?l(s):l+(Lt++).toString(),i=s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");t=t.replace(new RegExp('([#;"])('+i+')([")]|\\.[a-z])',"g"),"$1"+c+a+"$3")}),t=t.replace(new RegExp(a,"g"),""),t}const xe=Object.create(null);function _t(t,l){xe[t]=l}function Ee(t){return xe[t]||xe[""]}function Pe(t){let l;if(typeof t.resources=="string")l=[t.resources];else if(l=t.resources,!(l instanceof Array)||!l.length)return null;return{resources:l,path:t.path||"/",maxURL:t.maxURL||500,rotate:t.rotate||750,timeout:t.timeout||5e3,random:t.random===!0,index:t.index||0,dataAfterTimeout:t.dataAfterTimeout!==!1}}const Be=Object.create(null),de=["https://api.simplesvg.com","https://api.unisvg.com"],he=[];for(;de.length>0;)de.length===1||Math.random()>.5?he.push(de.shift()):he.push(de.pop());Be[""]=Pe({resources:["https://api.iconify.design"].concat(he)});function Xt(t,l){const o=Pe(l);return o===null?!1:(Be[t]=o,!0)}function je(t){return Be[t]}const Ft=()=>{let t;try{if(t=fetch,typeof t=="function")return t}catch{}};let ze=Ft();function Ht(t,l){const o=je(t);if(!o)return 0;let n;if(!o.maxURL)n=0;else{let a=0;o.resources.forEach(c=>{a=Math.max(a,c.length)});const s=l+".json?icons=";n=o.maxURL-a-o.path.length-s.length}return n}function Wt(t){return t===404}const Rt=(t,l,o)=>{const n=[],a=Ht(t,l),s="icons";let c={type:s,provider:t,prefix:l,icons:[]},i=0;return o.forEach((r,d)=>{i+=r.length+1,i>=a&&d>0&&(n.push(c),c={type:s,provider:t,prefix:l,icons:[]},i=r.length),c.icons.push(r)}),n.push(c),n};function Gt(t){if(typeof t=="string"){const l=je(t);if(l)return l.path}return"/"}const Ut=(t,l,o)=>{if(!ze){o("abort",424);return}let n=Gt(l.provider);switch(l.type){case"icons":{const s=l.prefix,i=l.icons.join(","),r=new URLSearchParams({icons:i});n+=s+".json?"+r.toString();break}case"custom":{const s=l.uri;n+=s.slice(0,1)==="/"?s.slice(1):s;break}default:o("abort",400);return}let a=503;ze(t+n).then(s=>{const c=s.status;if(c!==200){setTimeout(()=>{o(Wt(c)?"abort":"next",c)});return}return a=501,s.json()}).then(s=>{if(typeof s!="object"||s===null){setTimeout(()=>{s===404?o("abort",s):o("next",a)});return}setTimeout(()=>{o("success",s)})}).catch(()=>{o("next",a)})},Kt={prepare:Rt,send:Ut};function qt(t){const l={loaded:[],missing:[],pending:[]},o=Object.create(null);t.sort((a,s)=>a.provider!==s.provider?a.provider.localeCompare(s.provider):a.prefix!==s.prefix?a.prefix.localeCompare(s.prefix):a.name.localeCompare(s.name));let n={provider:"",prefix:"",name:""};return t.forEach(a=>{if(n.name===a.name&&n.prefix===a.prefix&&n.provider===a.provider)return;n=a;const s=a.provider,c=a.prefix,i=a.name,r=o[s]||(o[s]=Object.create(null)),d=r[c]||(r[c]=ie(s,c));let g;i in d.icons?g=l.loaded:c===""||d.missing.has(i)?g=l.missing:g=l.pending;const p={provider:s,prefix:c,name:i};g.push(p)}),l}function Je(t,l){t.forEach(o=>{const n=o.loaderCallbacks;n&&(o.loaderCallbacks=n.filter(a=>a.id!==l))})}function Zt(t){t.pendingCallbacksFlag||(t.pendingCallbacksFlag=!0,setTimeout(()=>{t.pendingCallbacksFlag=!1;const l=t.loaderCallbacks?t.loaderCallbacks.slice(0):[];if(!l.length)return;let o=!1;const n=t.provider,a=t.prefix;l.forEach(s=>{const c=s.icons,i=c.pending.length;c.pending=c.pending.filter(r=>{if(r.prefix!==a)return!0;const d=r.name;if(t.icons[d])c.loaded.push({provider:n,prefix:a,name:d});else if(t.missing.has(d))c.missing.push({provider:n,prefix:a,name:d});else return o=!0,!0;return!1}),c.pending.length!==i&&(o||Je([t],s.id),s.callback(c.loaded.slice(0),c.missing.slice(0),c.pending.slice(0),s.abort))})}))}let Qt=0;function Jt(t,l,o){const n=Qt++,a=Je.bind(null,o,n);if(!l.pending.length)return a;const s={id:n,icons:l,callback:t,abort:a};return o.forEach(c=>{(c.loaderCallbacks||(c.loaderCallbacks=[])).push(s)}),a}function en(t,l=!0,o=!1){const n=[];return t.forEach(a=>{const s=typeof a=="string"?ye(a,l,o):a;s&&n.push(s)}),n}var tn={resources:[],index:0,timeout:2e3,rotate:750,random:!1,dataAfterTimeout:!1};function nn(t,l,o,n){const a=t.resources.length,s=t.random?Math.floor(Math.random()*a):t.index;let c;if(t.random){let P=t.resources.slice(0);for(c=[];P.length>1;){const B=Math.floor(Math.random()*P.length);c.push(P[B]),P=P.slice(0,B).concat(P.slice(B+1))}c=c.concat(P)}else c=t.resources.slice(s).concat(t.resources.slice(0,s));const i=Date.now();let r="pending",d=0,g,p=null,v=[],h=[];typeof n=="function"&&h.push(n);function x(){p&&(clearTimeout(p),p=null)}function u(){r==="pending"&&(r="aborted"),x(),v.forEach(P=>{P.status==="pending"&&(P.status="aborted")}),v=[]}function f(P,B){B&&(h=[]),typeof P=="function"&&h.push(P)}function y(){return{startTime:i,payload:l,status:r,queriesSent:d,queriesPending:v.length,subscribe:f,abort:u}}function k(){r="failed",h.forEach(P=>{P(void 0,g)})}function w(){v.forEach(P=>{P.status==="pending"&&(P.status="aborted")}),v=[]}function S(P,B,m){const E=B!=="success";switch(v=v.filter(b=>b!==P),r){case"pending":break;case"failed":if(E||!t.dataAfterTimeout)return;break;default:return}if(B==="abort"){g=m,k();return}if(E){g=m,v.length||(c.length?D():k());return}if(x(),w(),!t.random){const b=t.resources.indexOf(P.resource);b!==-1&&b!==t.index&&(t.index=b)}r="completed",h.forEach(b=>{b(m)})}function D(){if(r!=="pending")return;x();const P=c.shift();if(P===void 0){if(v.length){p=setTimeout(()=>{x(),r==="pending"&&(w(),k())},t.timeout);return}k();return}const B={status:"pending",resource:P,callback:(m,E)=>{S(B,m,E)}};v.push(B),d++,p=setTimeout(D,t.rotate),o(P,l,B.callback)}return setTimeout(D),y}function et(t){const l={...tn,...t};let o=[];function n(){o=o.filter(i=>i().status==="pending")}function a(i,r,d){const g=nn(l,i,r,(p,v)=>{n(),d&&d(p,v)});return o.push(g),g}function s(i){return o.find(r=>i(r))||null}return{query:a,find:s,setIndex:i=>{l.index=i},getIndex:()=>l.index,cleanup:n}}function Ie(){}const ke=Object.create(null);function on(t){if(!ke[t]){const l=je(t);if(!l)return;const o=et(l),n={config:l,redundancy:o};ke[t]=n}return ke[t]}function an(t,l,o){let n,a;if(typeof t=="string"){const s=Ee(t);if(!s)return o(void 0,424),Ie;a=s.send;const c=on(t);c&&(n=c.redundancy)}else{const s=Pe(t);if(s){n=et(s);const c=t.resources?t.resources[0]:"",i=Ee(c);i&&(a=i.send)}}return!n||!a?(o(void 0,424),Ie):n.query(l,a,o)().abort}function Oe(){}function ln(t){t.iconsLoaderFlag||(t.iconsLoaderFlag=!0,setTimeout(()=>{t.iconsLoaderFlag=!1,Zt(t)}))}function sn(t){const l=[],o=[];return t.forEach(n=>{(n.match(We)?l:o).push(n)}),{valid:l,invalid:o}}function ge(t,l,o){function n(){const a=t.pendingIcons;l.forEach(s=>{a&&a.delete(s),t.icons[s]||t.missing.add(s)})}if(o&&typeof o=="object")try{if(!Ke(t,o).length){n();return}}catch(a){console.error(a)}n(),ln(t)}function Le(t,l){t instanceof Promise?t.then(o=>{l(o)}).catch(()=>{l(null)}):l(t)}function cn(t,l){t.iconsToLoad?t.iconsToLoad=t.iconsToLoad.concat(l).sort():t.iconsToLoad=l,t.iconsQueueFlag||(t.iconsQueueFlag=!0,setTimeout(()=>{t.iconsQueueFlag=!1;const{provider:o,prefix:n}=t,a=t.iconsToLoad;if(delete t.iconsToLoad,!a||!a.length)return;const s=t.loadIcon;if(t.loadIcons&&(a.length>1||!s)){Le(t.loadIcons(a,n,o),g=>{ge(t,a,g)});return}if(s){a.forEach(g=>{const p=s(g,n,o);Le(p,v=>{const h=v?{prefix:n,icons:{[g]:v}}:null;ge(t,[g],h)})});return}const{valid:c,invalid:i}=sn(a);if(i.length&&ge(t,i,null),!c.length)return;const r=n.match(We)?Ee(o):null;if(!r){ge(t,c,null);return}r.prepare(o,n,c).forEach(g=>{an(o,g,p=>{ge(t,g.icons,p)})})}))}const rn=(t,l)=>{const o=en(t,!0,qe()),n=qt(o);if(!n.pending.length){let r=!0;return l&&setTimeout(()=>{r&&l(n.loaded,n.missing,n.pending,Oe)}),()=>{r=!1}}const a=Object.create(null),s=[];let c,i;return n.pending.forEach(r=>{const{provider:d,prefix:g}=r;if(g===i&&d===c)return;c=d,i=g,s.push(ie(d,g));const p=a[d]||(a[d]=Object.create(null));p[g]||(p[g]=[])}),n.pending.forEach(r=>{const{provider:d,prefix:g,name:p}=r,v=ie(d,g),h=v.pendingIcons||(v.pendingIcons=new Set);h.has(p)||(h.add(p),a[d][g].push(p))}),s.forEach(r=>{const d=a[r.provider][r.prefix];d.length&&cn(r,d)}),l?Jt(l,n,s):Oe};function dn(t,l){const o={...t};for(const n in l){const a=l[n],s=typeof a;n in Ze?(a===null||a&&(s==="string"||s==="number"))&&(o[n]=a):s===typeof o[n]&&(o[n]=n==="rotate"?a%4:a)}return o}const gn=/[\s,]+/;function fn(t,l){l.split(gn).forEach(o=>{switch(o.trim()){case"horizontal":t.hFlip=!0;break;case"vertical":t.vFlip=!0;break}})}function un(t,l=0){const o=t.replace(/^-?[0-9.]*/,"");function n(a){for(;a<0;)a+=4;return a%4}if(o===""){const a=parseInt(t);return isNaN(a)?0:n(a)}else if(o!==t){let a=0;switch(o){case"%":a=25;break;case"deg":a=90}if(a){let s=parseFloat(t.slice(0,t.length-o.length));return isNaN(s)?0:(s=s/a,s%1===0?n(s):0)}}return l}function mn(t,l){let o=t.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const n in l)o+=" "+n+'="'+l[n]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+o+">"+t+"</svg>"}function hn(t){return t.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}function pn(t){return"data:image/svg+xml,"+hn(t)}function vn(t){return'url("'+pn(t)+'")'}const Ye={...Qe,inline:!1},yn={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":!0,role:"img"},wn={display:"inline-block"},$e={backgroundColor:"currentColor"},tt={backgroundColor:"transparent"},_e={Image:"var(--svg)",Repeat:"no-repeat",Size:"100% 100%"},Xe={webkitMask:$e,mask:$e,background:tt};for(const t in Xe){const l=Xe[t];for(const o in _e)l[t+o]=_e[o]}const pe={};["horizontal","vertical"].forEach(t=>{const l=t.slice(0,1)+"Flip";pe[t+"-flip"]=l,pe[t.slice(0,1)+"-flip"]=l,pe[t+"Flip"]=l});function Fe(t){return t+(t.match(/^[-0-9.]+$/)?"px":"")}const He=(t,l)=>{const o=dn(Ye,l),n={...yn},a=l.mode||"svg",s={},c=l.style,i=typeof c=="object"&&!(c instanceof Array)?c:{};for(let u in l){const f=l[u];if(f!==void 0)switch(u){case"icon":case"style":case"onLoad":case"mode":case"ssr":break;case"inline":case"hFlip":case"vFlip":o[u]=f===!0||f==="true"||f===1;break;case"flip":typeof f=="string"&&fn(o,f);break;case"color":s.color=f;break;case"rotate":typeof f=="string"?o[u]=un(f):typeof f=="number"&&(o[u]=f);break;case"ariaHidden":case"aria-hidden":f!==!0&&f!=="true"&&delete n["aria-hidden"];break;default:{const y=pe[u];y?(f===!0||f==="true"||f===1)&&(o[y]=!0):Ye[u]===void 0&&(n[u]=f)}}}const r=zt(t,o),d=r.attributes;if(o.inline&&(s.verticalAlign="-0.125em"),a==="svg"){n.style={...s,...i},Object.assign(n,d);let u=0,f=l.id;return typeof f=="string"&&(f=f.replace(/-/g,"_")),n.innerHTML=Yt(r.body,f?()=>f+"ID"+u++:"iconifyVue"),e.h("svg",n)}const{body:g,width:p,height:v}=t,h=a==="mask"||(a==="bg"?!1:g.indexOf("currentColor")!==-1),x=mn(g,{...d,width:p+"",height:v+""});return n.style={...s,"--svg":vn(x),width:Fe(d.width),height:Fe(d.height),...wn,...h?$e:tt,...i},e.h("span",n)};qe(!0);_t("",Kt);if(typeof document<"u"&&typeof window<"u"){const t=window;if(t.IconifyPreload!==void 0){const l=t.IconifyPreload,o="Invalid IconifyPreload syntax.";typeof l=="object"&&l!==null&&(l instanceof Array?l:[l]).forEach(n=>{try{(typeof n!="object"||n===null||n instanceof Array||typeof n.icons!="object"||typeof n.prefix!="string"||!Bt(n))&&console.error(o)}catch{console.error(o)}})}if(t.IconifyProviders!==void 0){const l=t.IconifyProviders;if(typeof l=="object"&&l!==null)for(let o in l){const n="IconifyProviders["+o+"] is invalid.";try{const a=l[o];if(typeof a!="object"||!a||a.resources===void 0)continue;Xt(o,a)||console.error(n)}catch{console.error(n)}}}}const bn={...we,body:""},K=e.defineComponent({inheritAttrs:!1,data(){return{_name:"",_loadingIcon:null,iconMounted:!1,counter:0}},mounted(){this.iconMounted=!0},unmounted(){this.abortLoading()},methods:{abortLoading(){this._loadingIcon&&(this._loadingIcon.abort(),this._loadingIcon=null)},getIcon(t,l,o){if(typeof t=="object"&&t!==null&&typeof t.body=="string")return this._name="",this.abortLoading(),{data:t};let n;if(typeof t!="string"||(n=ye(t,!1,!0))===null)return this.abortLoading(),null;let a=Mt(n);if(!a)return(!this._loadingIcon||this._loadingIcon.name!==t)&&(this.abortLoading(),this._name="",a!==null&&(this._loadingIcon={name:t,abort:rn([n],()=>{this.counter++})})),null;if(this.abortLoading(),this._name!==t&&(this._name=t,l&&l(t)),o){a=Object.assign({},a);const c=o(a.body,n.name,n.prefix,n.provider);typeof c=="string"&&(a.body=c)}const s=["iconify"];return n.prefix!==""&&s.push("iconify--"+n.prefix),n.provider!==""&&s.push("iconify--"+n.provider),{data:a,classes:s}}},render(){this.counter;const t=this.$attrs,l=this.iconMounted||t.ssr?this.getIcon(t.icon,t.onLoad,t.customise):null;if(!l)return He(bn,t);let o=t;return l.classes&&(o={...t,class:(typeof t.class=="string"?t.class+" ":"")+l.classes.join(" ")}),He({...we,...l.data},o)}}),Cn=["disabled"],kn={key:0,class:"x-btn-icon"},Sn={key:1,class:"x-btn-loading"},xn={class:"x-btn-content"},En={key:2,class:"x-btn-icon"},$n=e.defineComponent({__name:"index",props:{type:{default:"default"},size:{default:"medium"},icon:{},iconRight:{},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},block:{type:Boolean,default:!1},round:{type:Boolean,default:!1},ghost:{type:Boolean,default:!1}},emits:["click"],setup(t,{emit:l}){const o=t,n=l,a=e.ref(),s=e.ref([]);let c=0;const i=e.computed(()=>["x-btn",`x-btn-${o.type}`,`x-btn-${o.size}`,{"x-btn-disabled":o.disabled,"x-btn-loading":o.loading,"x-btn-block":o.block,"x-btn-round":o.round,"x-btn-ghost":o.ghost}]);function r(g){!o.disabled&&!o.loading&&n("click",g)}function d(g){if(o.disabled||o.loading)return;const p=a.value;if(!p)return;const v=p.getBoundingClientRect(),h={id:c++,style:{left:`${g.clientX-v.left}px`,top:`${g.clientY-v.top}px`}};s.value.push(h),setTimeout(()=>{const x=s.value.findIndex(u=>u.id===h.id);x>-1&&s.value.splice(x,1)},600)}return(g,p)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(i.value),disabled:t.disabled||t.loading,onClick:r,onMousedown:d,ref_key:"buttonRef",ref:a},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,v=>(e.openBlock(),e.createElementBlock("span",{key:v.id,class:"x-btn-ripple",style:e.normalizeStyle(v.style)},null,4))),128)),t.icon&&!t.loading?(e.openBlock(),e.createElementBlock("span",kn,[e.createVNode(e.unref(K),{icon:t.icon},null,8,["icon"])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("span",Sn,[e.createVNode(e.unref(K),{icon:"eos-icons:loading"})])):e.createCommentVNode("",!0),e.createElementVNode("span",xn,[e.renderSlot(g.$slots,"default",{},void 0,!0)]),t.iconRight&&!t.loading?(e.openBlock(),e.createElementBlock("span",En,[e.createVNode(e.unref(K),{icon:t.iconRight},null,8,["icon"])])):e.createCommentVNode("",!0)],42,Cn))}}),Z=(t,l)=>{const o=t.__vccOpts||t;for(const[n,a]of l)o[n]=a;return o},Me=Z($n,[["__scopeId","data-v-4ae56e67"]]),Mn={class:"x-card-container"},Pn=["onClick"],Bn={class:"relative p-2"},jn=["src","alt"],Vn={key:0,class:"absolute top-3 left-3"},Nn={class:"label-badge"},Dn={class:"product-info p-5 ml-5"},An={class:"text-sm lg:text-base text-gray-700 leading-relaxed line-clamp-2 mb-3"},Tn={class:"flex items-center justify-between gap-2"},zn={class:"text-base lg:text-lg font-bold text-[var(--x-color-primary)]"},In={key:0,class:"bi bi-heart text-gray-500"},On={key:1,class:"bi bi-heart-fill text-[#FE374F]"},Ln=["onClick"],Yn={class:"relative flex-shrink-0 p-2"},_n={class:"aspect-square bg-gray-100 rounded-lg overflow-hidden"},Xn=["src","alt"],Fn={key:0,class:"absolute top-3 left-3"},Hn={class:"label-badge"},Wn={class:"flex-1 flex flex-col justify-between product-info p-5 ml-5"},Rn={class:"text-sm lg:text-base text-gray-700 font-medium line-clamp-2 leading-relaxed mb-3"},Gn={class:"flex items-center justify-between gap-2 mt-auto"},Un={class:"text-base lg:text-lg font-bold text-[var(--x-color-primary)]"},Kn=e.defineComponent({__name:"index",props:{layout:{default:"grid"},products:{default:()=>[]},useMockData:{type:Boolean,default:!0},columns:{default:4}},emits:["productClick","like"],setup(t,{emit:l}){const o=t,n=l,a=[{id:"1",name:"北欧风简约陶瓷花瓶",image:"https://images.unsplash.com/photo-1578500494198-246f612d3b3d?w=400",price:"¥299",label:"热卖",isWish:!1},{id:"2",name:"手工编织棉麻抱枕套",image:"https://images.unsplash.com/photo-1584100936595-c0654b55a2e2?w=400",price:"¥89",label:"新品",isWish:!0},{id:"3",name:"实木原木置物架收纳架",image:"https://images.unsplash.com/photo-1595428774223-ef52624120d2?w=400",price:"¥459",label:"",isWish:!1},{id:"4",name:"ins风格桌面装饰摆件",image:"https://images.unsplash.com/photo-1513506003901-1e6a229e2d15?w=400",price:"¥129",label:"特价",isWish:!1},{id:"5",name:"现代简约台灯护眼学习灯",image:"https://images.unsplash.com/photo-1507473885765-e6ed057f782c?w=400",price:"¥399",label:"",isWish:!0},{id:"6",name:"北欧风格装饰画挂画",image:"https://images.unsplash.com/photo-1561214115-f2f134cc4912?w=400",price:"¥199",label:"热卖",isWish:!1},{id:"7",name:"多功能收纳盒桌面整理",image:"https://images.unsplash.com/photo-1586023492125-27b2c045efd7?w=400",price:"¥68",label:"",isWish:!1},{id:"8",name:"创意陶瓷马克杯咖啡杯",image:"https://images.unsplash.com/photo-1514228742587-6b1558fcca3d?w=400",price:"¥59",label:"新品",isWish:!1},{id:"9",name:"手工玻璃花瓶透明花器",image:"https://images.unsplash.com/photo-1523293182086-7651a899d37f?w=400",price:"¥179",label:"",isWish:!0},{id:"10",name:"日式和风招财猫摆件",image:"https://images.unsplash.com/photo-1615529182904-14819c35db37?w=400",price:"¥149",label:"热卖",isWish:!1},{id:"11",name:"北欧风木质挂钟客厅",image:"https://images.unsplash.com/photo-1563861826100-9cb868fdbe1c?w=400",price:"¥259",label:"",isWish:!1},{id:"12",name:"现代简约落地花架",image:"https://images.unsplash.com/photo-1545127398-14699f92334b?w=400",price:"¥329",label:"特价",isWish:!1}],s=e.ref([]),c=e.computed(()=>o.products&&o.products.length>0?o.products:s.value),i=e.computed(()=>{const p=Math.min(Math.max(o.columns||4,1),4),v={1:"grid-cols-1",2:"grid-cols-1 md:grid-cols-2",3:"grid-cols-1 md:grid-cols-2 lg:grid-cols-3",4:"grid-cols-2 md:grid-cols-3 lg:grid-cols-4"};return v[p]||v[4]}),r=e.computed(()=>{const p=Math.min(Math.max(o.columns||4,1),4),v={1:"columns-1",2:"columns-1 md:columns-2",3:"columns-2 md:columns-2 lg:columns-3",4:"columns-2 sm:columns-2 md:columns-3 lg:columns-4"};return v[p]||v[4]});e.onMounted(()=>{o.useMockData&&(!o.products||o.products.length===0)&&(s.value=a)});const d=p=>{n("productClick",p)},g=p=>{p.isWish=!p.isWish,n("like",p)};return(p,v)=>(e.openBlock(),e.createElementBlock("div",Mn,[t.layout==="masonry"?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["masonry-layout",r.value,"gap-4 sm:gap-6"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,h=>(e.openBlock(),e.createElementBlock("div",{key:h.id+"-masonry",class:"mb-4 sm:mb-6 break-inside-avoid group cursor-pointer product-card",onClick:x=>d(h.id)},[e.createElementVNode("div",Bn,[e.createElementVNode("img",{src:h.image,alt:h.name,loading:"lazy",class:"w-full h-auto rounded-lg bg-gray-100 object-cover transition-transform duration-300 group-hover:scale-[1.01]"},null,8,jn),h.label?(e.openBlock(),e.createElementBlock("div",Vn,[e.createElementVNode("span",Nn,e.toDisplayString(h.label),1)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",Dn,[e.createElementVNode("h3",An,e.toDisplayString(h.name),1),e.createElementVNode("div",Tn,[e.createElementVNode("span",zn,e.toDisplayString(h.price),1),e.createVNode(Me,{onClick:e.withModifiers(x=>g(h),["stop"]),type:"text",size:"small",class:"like-button !min-w-0 !p-1"},{default:e.withCtx(()=>[h.isWish?(e.openBlock(),e.createElementBlock("i",On)):(e.openBlock(),e.createElementBlock("i",In))]),_:2},1032,["onClick"])])])],8,Pn))),128))],2)):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["grid",i.value,"gap-4 lg:gap-6"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,h=>(e.openBlock(),e.createElementBlock("div",{key:h.id+"-grid",class:"h-full"},[e.createElementVNode("div",{class:"group cursor-pointer product-card h-full flex flex-col",onClick:x=>d(h.id)},[e.createElementVNode("div",Yn,[e.createElementVNode("div",_n,[e.createElementVNode("img",{src:h.image,alt:h.name,class:"w-full h-full object-cover group-hover:scale-105 transition-transform duration-300",loading:"lazy"},null,8,Xn)]),h.label?(e.openBlock(),e.createElementBlock("div",Fn,[e.createElementVNode("span",Hn,e.toDisplayString(h.label),1)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",Wn,[e.createElementVNode("h3",Rn,e.toDisplayString(h.name),1),e.createElementVNode("div",Gn,[e.createElementVNode("span",Un,e.toDisplayString(h.price),1),e.createVNode(Me,{onClick:e.withModifiers(x=>g(h),["stop"]),type:"text",size:"small",class:"like-button !min-w-0 !p-1"},{default:e.withCtx(()=>[h.isWish?(e.openBlock(),e.createBlock(e.unref(K),{key:1,icon:"bi:heart-fill",class:"bi bi-heart-fill text-[#FE374F]"})):(e.openBlock(),e.createBlock(e.unref(K),{key:0,icon:"bi:heart",class:"bi bi-heart text-gray-500"}))]),_:2},1032,["onClick"])])])],8,Ln)]))),128))],2))]))}}),qn=Z(Kn,[["__scopeId","data-v-aec5fd31"]]),Zn=[{name:"Afghanistan",code:"AF",flagEmoji:"🇦🇫",flagSvg:"https://flagcdn.com/af.svg",flagPng:"https://flagcdn.com/w40/af.png",phoneCode:"+93",phonelengthMAX:10},{name:"Åland Islands",code:"AX",flagEmoji:"🇦🇽",flagSvg:"https://flagcdn.com/ax.svg",flagPng:"https://flagcdn.com/w40/ax.png",phoneCode:"+358",phonelengthMAX:10},{name:"Albania",code:"AL",flagEmoji:"🇦🇱",flagSvg:"https://flagcdn.com/al.svg",flagPng:"https://flagcdn.com/w40/al.png",phoneCode:"+355",phonelengthMAX:10},{name:"Algeria",code:"DZ",flagEmoji:"🇩🇿",flagSvg:"https://flagcdn.com/dz.svg",flagPng:"https://flagcdn.com/w40/dz.png",phoneCode:"+213",phonelengthMAX:10},{name:"American Samoa",code:"AS",flagEmoji:"🇦🇸",flagSvg:"https://flagcdn.com/as.svg",flagPng:"https://flagcdn.com/w40/as.png",phoneCode:"+1684",phonelengthMAX:10},{name:"Andorra",code:"AD",flagEmoji:"🇦🇩",flagSvg:"https://flagcdn.com/ad.svg",flagPng:"https://flagcdn.com/w40/ad.png",phoneCode:"+376",phonelengthMAX:10},{name:"Angola",code:"AO",flagEmoji:"🇦🇴",flagSvg:"https://flagcdn.com/ao.svg",flagPng:"https://flagcdn.com/w40/ao.png",phoneCode:"+244",phonelengthMAX:10},{name:"Anguilla",code:"AI",flagEmoji:"🇦🇮",flagSvg:"https://flagcdn.com/ai.svg",flagPng:"https://flagcdn.com/w40/ai.png",phoneCode:"+1264",phonelengthMAX:10},{name:"Antarctica",code:"AQ",flagEmoji:"🇦🇶",flagSvg:"https://flagcdn.com/aq.svg",flagPng:"https://flagcdn.com/w40/aq.png",phoneCode:"+672",phonelengthMAX:10},{name:"Antigua and Barbuda",code:"AG",flagEmoji:"🇦🇬",flagSvg:"https://flagcdn.com/ag.svg",flagPng:"https://flagcdn.com/w40/ag.png",phoneCode:"+1268",phonelengthMAX:10},{name:"Argentina",code:"AR",flagEmoji:"🇦🇷",flagSvg:"https://flagcdn.com/ar.svg",flagPng:"https://flagcdn.com/w40/ar.png",phoneCode:"+54",phonelengthMAX:10},{name:"Armenia",code:"AM",flagEmoji:"🇦🇲",flagSvg:"https://flagcdn.com/am.svg",flagPng:"https://flagcdn.com/w40/am.png",phoneCode:"+374",phonelengthMAX:10},{name:"Aruba",code:"AW",flagEmoji:"🇦🇼",flagSvg:"https://flagcdn.com/aw.svg",flagPng:"https://flagcdn.com/w40/aw.png",phoneCode:"+297",phonelengthMAX:10},{name:"Australia",code:"AU",flagEmoji:"🇦🇺",flagSvg:"https://flagcdn.com/au.svg",flagPng:"https://flagcdn.com/w40/au.png",phoneCode:"+61",phonelengthMAX:10},{name:"Austria",code:"AT",flagEmoji:"🇦🇹",flagSvg:"https://flagcdn.com/at.svg",flagPng:"https://flagcdn.com/w40/at.png",phoneCode:"+43",phonelengthMAX:10},{name:"Azerbaijan",code:"AZ",flagEmoji:"🇦🇿",flagSvg:"https://flagcdn.com/az.svg",flagPng:"https://flagcdn.com/w40/az.png",phoneCode:"+994",phonelengthMAX:10},{name:"Bahamas",code:"BS",flagEmoji:"🇧🇸",flagSvg:"https://flagcdn.com/bs.svg",flagPng:"https://flagcdn.com/w40/bs.png",phoneCode:"+1242",phonelengthMAX:10},{name:"Bahrain",code:"BH",flagEmoji:"🇧🇭",flagSvg:"https://flagcdn.com/bh.svg",flagPng:"https://flagcdn.com/w40/bh.png",phoneCode:"+973",phonelengthMAX:10},{name:"Bangladesh",code:"BD",flagEmoji:"🇧🇩",flagSvg:"https://flagcdn.com/bd.svg",flagPng:"https://flagcdn.com/w40/bd.png",phoneCode:"+880",phonelengthMAX:10},{name:"Barbados",code:"BB",flagEmoji:"🇧🇧",flagSvg:"https://flagcdn.com/bb.svg",flagPng:"https://flagcdn.com/w40/bb.png",phoneCode:"+1246",phonelengthMAX:10},{name:"Belarus",code:"BY",flagEmoji:"🇧🇾",flagSvg:"https://flagcdn.com/by.svg",flagPng:"https://flagcdn.com/w40/by.png",phoneCode:"+375",phonelengthMAX:10},{name:"Belgium",code:"BE",flagEmoji:"🇧🇪",flagSvg:"https://flagcdn.com/be.svg",flagPng:"https://flagcdn.com/w40/be.png",phoneCode:"+32",phonelengthMAX:10},{name:"Belize",code:"BZ",flagEmoji:"🇧🇿",flagSvg:"https://flagcdn.com/bz.svg",flagPng:"https://flagcdn.com/w40/bz.png",phoneCode:"+501",phonelengthMAX:10},{name:"Benin",code:"BJ",flagEmoji:"🇧🇯",flagSvg:"https://flagcdn.com/bj.svg",flagPng:"https://flagcdn.com/w40/bj.png",phoneCode:"+229",phonelengthMAX:10},{name:"Bermuda",code:"BM",flagEmoji:"🇧🇲",flagSvg:"https://flagcdn.com/bm.svg",flagPng:"https://flagcdn.com/w40/bm.png",phoneCode:"+1441",phonelengthMAX:10},{name:"Bhutan",code:"BT",flagEmoji:"🇧🇹",flagSvg:"https://flagcdn.com/bt.svg",flagPng:"https://flagcdn.com/w40/bt.png",phoneCode:"+975",phonelengthMAX:10},{name:"Bolivia (Plurinational State of)",code:"BO",flagEmoji:"🇧🇴",flagSvg:"https://flagcdn.com/bo.svg",flagPng:"https://flagcdn.com/w40/bo.png",phoneCode:"+591",phonelengthMAX:10},{name:"Bonaire, Sint Eustatius and Saba",code:"BQ",flagEmoji:"🇧🇶",flagSvg:"https://flagcdn.com/bq.svg",flagPng:"https://flagcdn.com/w40/bq.png",phoneCode:"+5997",phonelengthMAX:10},{name:"Bosnia and Herzegovina",code:"BA",flagEmoji:"🇧🇦",flagSvg:"https://flagcdn.com/ba.svg",flagPng:"https://flagcdn.com/w40/ba.png",phoneCode:"+387",phonelengthMAX:10},{name:"Botswana",code:"BW",flagEmoji:"🇧🇼",flagSvg:"https://flagcdn.com/bw.svg",flagPng:"https://flagcdn.com/w40/bw.png",phoneCode:"+267",phonelengthMAX:10},{name:"Bouvet Island",code:"BV",flagEmoji:"🇧🇻",flagSvg:"https://flagcdn.com/bv.svg",flagPng:"https://flagcdn.com/w40/bv.png",phoneCode:"+55",phonelengthMAX:10},{name:"Brazil",code:"BR",flagEmoji:"🇧🇷",flagSvg:"https://flagcdn.com/br.svg",flagPng:"https://flagcdn.com/w40/br.png",phoneCode:"+55",phonelengthMAX:10},{name:"British Indian Ocean Territory",code:"IO",flagEmoji:"🇮🇴",flagSvg:"https://flagcdn.com/io.svg",flagPng:"https://flagcdn.com/w40/io.png",phoneCode:"+246",phonelengthMAX:10},{name:"Brunei Darussalam",code:"BN",flagEmoji:"🇧🇳",flagSvg:"https://flagcdn.com/bn.svg",flagPng:"https://flagcdn.com/w40/bn.png",phoneCode:"+673",phonelengthMAX:10},{name:"Bulgaria",code:"BG",flagEmoji:"🇧🇬",flagSvg:"https://flagcdn.com/bg.svg",flagPng:"https://flagcdn.com/w40/bg.png",phoneCode:"+359",phonelengthMAX:10},{name:"Burkina Faso",code:"BF",flagEmoji:"🇧🇫",flagSvg:"https://flagcdn.com/bf.svg",flagPng:"https://flagcdn.com/w40/bf.png",phoneCode:"+226",phonelengthMAX:10},{name:"Burundi",code:"BI",flagEmoji:"🇧🇮",flagSvg:"https://flagcdn.com/bi.svg",flagPng:"https://flagcdn.com/w40/bi.png",phoneCode:"+257",phonelengthMAX:10},{name:"Cabo Verde",code:"CV",flagEmoji:"🇨🇻",flagSvg:"https://flagcdn.com/cv.svg",flagPng:"https://flagcdn.com/w40/cv.png",phoneCode:"+238",phonelengthMAX:10},{name:"Cambodia",code:"KH",flagEmoji:"🇰🇭",flagSvg:"https://flagcdn.com/kh.svg",flagPng:"https://flagcdn.com/w40/kh.png",phoneCode:"+855",phonelengthMAX:10},{name:"Cameroon",code:"CM",flagEmoji:"🇨🇲",flagSvg:"https://flagcdn.com/cm.svg",flagPng:"https://flagcdn.com/w40/cm.png",phoneCode:"+237",phonelengthMAX:10},{name:"Canada",code:"CA",flagEmoji:"🇨🇦",flagSvg:"https://flagcdn.com/ca.svg",flagPng:"https://flagcdn.com/w40/ca.png",phoneCode:"+1",phonelengthMAX:10},{name:"Cayman Islands",code:"KY",flagEmoji:"🇰🇾",flagSvg:"https://flagcdn.com/ky.svg",flagPng:"https://flagcdn.com/w40/ky.png",phoneCode:"+1345",phonelengthMAX:10},{name:"Central African Republic",code:"CF",flagEmoji:"🇨🇫",flagSvg:"https://flagcdn.com/cf.svg",flagPng:"https://flagcdn.com/w40/cf.png",phoneCode:"+236",phonelengthMAX:10},{name:"Chad",code:"TD",flagEmoji:"🇹🇩",flagSvg:"https://flagcdn.com/td.svg",flagPng:"https://flagcdn.com/w40/td.png",phoneCode:"+235",phonelengthMAX:10},{name:"Chile",code:"CL",flagEmoji:"🇨🇱",flagSvg:"https://flagcdn.com/cl.svg",flagPng:"https://flagcdn.com/w40/cl.png",phoneCode:"+56",phonelengthMAX:10},{name:"China",code:"CN",flagEmoji:"🇨🇳",flagSvg:"https://flagcdn.com/cn.svg",flagPng:"https://flagcdn.com/w40/cn.png",phoneCode:"+86",phonelengthMAX:11},{name:"Christmas Island",code:"CX",flagEmoji:"🇨🇽",flagSvg:"https://flagcdn.com/cx.svg",flagPng:"https://flagcdn.com/w40/cx.png",phoneCode:"+61",phonelengthMAX:10},{name:"Cocos (Keeling) Islands",code:"CC",flagEmoji:"🇨🇨",flagSvg:"https://flagcdn.com/cc.svg",flagPng:"https://flagcdn.com/w40/cc.png",phoneCode:"+61",phonelengthMAX:10},{name:"Colombia",code:"CO",flagEmoji:"🇨🇴",flagSvg:"https://flagcdn.com/co.svg",flagPng:"https://flagcdn.com/w40/co.png",phoneCode:"+57",phonelengthMAX:10},{name:"Comoros",code:"KM",flagEmoji:"🇰🇲",flagSvg:"https://flagcdn.com/km.svg",flagPng:"https://flagcdn.com/w40/km.png",phoneCode:"+269",phonelengthMAX:10},{name:"Congo",code:"CG",flagEmoji:"🇨🇬",flagSvg:"https://flagcdn.com/cg.svg",flagPng:"https://flagcdn.com/w40/cg.png",phoneCode:"+242",phonelengthMAX:10},{name:"Congo, Democratic Republic of the",code:"CD",flagEmoji:"🇨🇩",flagSvg:"https://flagcdn.com/cd.svg",flagPng:"https://flagcdn.com/w40/cd.png",phoneCode:"+243",phonelengthMAX:10},{name:"Cook Islands",code:"CK",flagEmoji:"🇨🇰",flagSvg:"https://flagcdn.com/ck.svg",flagPng:"https://flagcdn.com/w40/ck.png",phoneCode:"+682",phonelengthMAX:10},{name:"Costa Rica",code:"CR",flagEmoji:"🇨🇷",flagSvg:"https://flagcdn.com/cr.svg",flagPng:"https://flagcdn.com/w40/cr.png",phoneCode:"+506",phonelengthMAX:10},{name:"Croatia",code:"HR",flagEmoji:"🇭🇷",flagSvg:"https://flagcdn.com/hr.svg",flagPng:"https://flagcdn.com/w40/hr.png",phoneCode:"+385",phonelengthMAX:10},{name:"Cuba",code:"CU",flagEmoji:"🇨🇺",flagSvg:"https://flagcdn.com/cu.svg",flagPng:"https://flagcdn.com/w40/cu.png",phoneCode:"+53",phonelengthMAX:10},{name:"Curaçao",code:"CW",flagEmoji:"🇨🇼",flagSvg:"https://flagcdn.com/cw.svg",flagPng:"https://flagcdn.com/w40/cw.png",phoneCode:"+5999",phonelengthMAX:10},{name:"Cyprus",code:"CY",flagEmoji:"🇨🇾",flagSvg:"https://flagcdn.com/cy.svg",flagPng:"https://flagcdn.com/w40/cy.png",phoneCode:"+357",phonelengthMAX:10},{name:"Czechia",code:"CZ",flagEmoji:"🇨🇿",flagSvg:"https://flagcdn.com/cz.svg",flagPng:"https://flagcdn.com/w40/cz.png",phoneCode:"+420",phonelengthMAX:10},{name:"Denmark",code:"DK",flagEmoji:"🇩🇰",flagSvg:"https://flagcdn.com/dk.svg",flagPng:"https://flagcdn.com/w40/dk.png",phoneCode:"+45",phonelengthMAX:10},{name:"Djibouti",code:"DJ",flagEmoji:"🇩🇯",flagSvg:"https://flagcdn.com/dj.svg",flagPng:"https://flagcdn.com/w40/dj.png",phoneCode:"+253",phonelengthMAX:10},{name:"Dominica",code:"DM",flagEmoji:"🇩🇲",flagSvg:"https://flagcdn.com/dm.svg",flagPng:"https://flagcdn.com/w40/dm.png",phoneCode:"+1767",phonelengthMAX:10},{name:"Dominican Republic",code:"DO",flagEmoji:"🇩🇴",flagSvg:"https://flagcdn.com/do.svg",flagPng:"https://flagcdn.com/w40/do.png",phoneCode:"+1809",phonelengthMAX:10},{name:"Ecuador",code:"EC",flagEmoji:"🇪🇨",flagSvg:"https://flagcdn.com/ec.svg",flagPng:"https://flagcdn.com/w40/ec.png",phoneCode:"+593",phonelengthMAX:10},{name:"Egypt",code:"EG",flagEmoji:"🇪🇬",flagSvg:"https://flagcdn.com/eg.svg",flagPng:"https://flagcdn.com/w40/eg.png",phoneCode:"+20",phonelengthMAX:10},{name:"El Salvador",code:"SV",flagEmoji:"🇸🇻",flagSvg:"https://flagcdn.com/sv.svg",flagPng:"https://flagcdn.com/w40/sv.png",phoneCode:"+503",phonelengthMAX:10},{name:"Equatorial Guinea",code:"GQ",flagEmoji:"🇬🇶",flagSvg:"https://flagcdn.com/gq.svg",flagPng:"https://flagcdn.com/w40/gq.png",phoneCode:"+240",phonelengthMAX:10},{name:"Eritrea",code:"ER",flagEmoji:"🇪🇷",flagSvg:"https://flagcdn.com/er.svg",flagPng:"https://flagcdn.com/w40/er.png",phoneCode:"+291",phonelengthMAX:10},{name:"Estonia",code:"EE",flagEmoji:"🇪🇪",flagSvg:"https://flagcdn.com/ee.svg",flagPng:"https://flagcdn.com/w40/ee.png",phoneCode:"+372",phonelengthMAX:10},{name:"Eswatini",code:"SZ",flagEmoji:"🇸🇿",flagSvg:"https://flagcdn.com/sz.svg",flagPng:"https://flagcdn.com/w40/sz.png",phoneCode:"+268",phonelengthMAX:10},{name:"Ethiopia",code:"ET",flagEmoji:"🇪🇹",flagSvg:"https://flagcdn.com/et.svg",flagPng:"https://flagcdn.com/w40/et.png",phoneCode:"+251",phonelengthMAX:10},{name:"Falkland Islands (Malvinas)",code:"FK",flagEmoji:"🇫🇰",flagSvg:"https://flagcdn.com/fk.svg",flagPng:"https://flagcdn.com/w40/fk.png",phoneCode:"+500",phonelengthMAX:10},{name:"Faroe Islands",code:"FO",flagEmoji:"🇫🇴",flagSvg:"https://flagcdn.com/fo.svg",flagPng:"https://flagcdn.com/w40/fo.png",phoneCode:"+298",phonelengthMAX:10},{name:"Fiji",code:"FJ",flagEmoji:"🇫🇯",flagSvg:"https://flagcdn.com/fj.svg",flagPng:"https://flagcdn.com/w40/fj.png",phoneCode:"+679",phonelengthMAX:10},{name:"Finland",code:"FI",flagEmoji:"🇫🇮",flagSvg:"https://flagcdn.com/fi.svg",flagPng:"https://flagcdn.com/w40/fi.png",phoneCode:"+358",phonelengthMAX:10},{name:"France",code:"FR",flagEmoji:"🇫🇷",flagSvg:"https://flagcdn.com/fr.svg",flagPng:"https://flagcdn.com/w40/fr.png",phoneCode:"+33",phonelengthMAX:10},{name:"French Guiana",code:"GF",flagEmoji:"🇬🇫",flagSvg:"https://flagcdn.com/gf.svg",flagPng:"https://flagcdn.com/w40/gf.png",phoneCode:"+594",phonelengthMAX:10},{name:"French Polynesia",code:"PF",flagEmoji:"🇵🇫",flagSvg:"https://flagcdn.com/pf.svg",flagPng:"https://flagcdn.com/w40/pf.png",phoneCode:"+689",phonelengthMAX:10},{name:"French Southern Territories",code:"TF",flagEmoji:"🇹🇫",flagSvg:"https://flagcdn.com/tf.svg",flagPng:"https://flagcdn.com/w40/tf.png",phoneCode:"+262",phonelengthMAX:10},{name:"Gabon",code:"GA",flagEmoji:"🇬🇦",flagSvg:"https://flagcdn.com/ga.svg",flagPng:"https://flagcdn.com/w40/ga.png",phoneCode:"+241",phonelengthMAX:10},{name:"Gambia",code:"GM",flagEmoji:"🇬🇲",flagSvg:"https://flagcdn.com/gm.svg",flagPng:"https://flagcdn.com/w40/gm.png",phoneCode:"+220",phonelengthMAX:10},{name:"Georgia",code:"GE",flagEmoji:"🇬🇪",flagSvg:"https://flagcdn.com/ge.svg",flagPng:"https://flagcdn.com/w40/ge.png",phoneCode:"+995",phonelengthMAX:10},{name:"Germany",code:"DE",flagEmoji:"🇩🇪",flagSvg:"https://flagcdn.com/de.svg",flagPng:"https://flagcdn.com/w40/de.png",phoneCode:"+49",phonelengthMAX:10},{name:"Ghana",code:"GH",flagEmoji:"🇬🇭",flagSvg:"https://flagcdn.com/gh.svg",flagPng:"https://flagcdn.com/w40/gh.png",phoneCode:"+233",phonelengthMAX:10},{name:"Gibraltar",code:"GI",flagEmoji:"🇬🇮",flagSvg:"https://flagcdn.com/gi.svg",flagPng:"https://flagcdn.com/w40/gi.png",phoneCode:"+350",phonelengthMAX:10},{name:"Greece",code:"GR",flagEmoji:"🇬🇷",flagSvg:"https://flagcdn.com/gr.svg",flagPng:"https://flagcdn.com/w40/gr.png",phoneCode:"+30",phonelengthMAX:10},{name:"Greenland",code:"GL",flagEmoji:"🇬🇱",flagSvg:"https://flagcdn.com/gl.svg",flagPng:"https://flagcdn.com/w40/gl.png",phoneCode:"+299",phonelengthMAX:10},{name:"Grenada",code:"GD",flagEmoji:"🇬🇩",flagSvg:"https://flagcdn.com/gd.svg",flagPng:"https://flagcdn.com/w40/gd.png",phoneCode:"+1473",phonelengthMAX:10},{name:"Guadeloupe",code:"GP",flagEmoji:"🇬🇵",flagSvg:"https://flagcdn.com/gp.svg",flagPng:"https://flagcdn.com/w40/gp.png",phoneCode:"+590",phonelengthMAX:10},{name:"Guam",code:"GU",flagEmoji:"🇬🇺",flagSvg:"https://flagcdn.com/gu.svg",flagPng:"https://flagcdn.com/w40/gu.png",phoneCode:"+1671",phonelengthMAX:10},{name:"Guatemala",code:"GT",flagEmoji:"🇬🇹",flagSvg:"https://flagcdn.com/gt.svg",flagPng:"https://flagcdn.com/w40/gt.png",phoneCode:"+502",phonelengthMAX:10},{name:"Guernsey",code:"GG",flagEmoji:"🇬🇬",flagSvg:"https://flagcdn.com/gg.svg",flagPng:"https://flagcdn.com/w40/gg.png",phoneCode:"+44",phonelengthMAX:10},{name:"Guinea",code:"GN",flagEmoji:"🇬🇳",flagSvg:"https://flagcdn.com/gn.svg",flagPng:"https://flagcdn.com/w40/gn.png",phoneCode:"+224",phonelengthMAX:10},{name:"Guinea-Bissau",code:"GW",flagEmoji:"🇬🇼",flagSvg:"https://flagcdn.com/gw.svg",flagPng:"https://flagcdn.com/w40/gw.png",phoneCode:"+245",phonelengthMAX:10},{name:"Guyana",code:"GY",flagEmoji:"🇬🇾",flagSvg:"https://flagcdn.com/gy.svg",flagPng:"https://flagcdn.com/w40/gy.png",phoneCode:"+592",phonelengthMAX:10},{name:"Haiti",code:"HT",flagEmoji:"🇭🇹",flagSvg:"https://flagcdn.com/ht.svg",flagPng:"https://flagcdn.com/w40/ht.png",phoneCode:"+509",phonelengthMAX:10},{name:"Heard Island and McDonald Islands",code:"HM",flagEmoji:"🇭🇲",flagSvg:"https://flagcdn.com/hm.svg",flagPng:"https://flagcdn.com/w40/hm.png",phoneCode:"+672"},{name:"Holy See",code:"VA",flagEmoji:"🇻🇦",flagSvg:"https://flagcdn.com/va.svg",flagPng:"https://flagcdn.com/w40/va.png",phoneCode:"+39"},{name:"Honduras",code:"HN",flagEmoji:"🇭🇳",flagSvg:"https://flagcdn.com/hn.svg",flagPng:"https://flagcdn.com/w40/hn.png",phoneCode:"+504"},{name:"Hong Kong",code:"HK",flagEmoji:"🇭🇰",flagSvg:"https://flagcdn.com/hk.svg",flagPng:"https://flagcdn.com/w40/hk.png",phoneCode:"+852"},{name:"Hungary",code:"HU",flagEmoji:"🇭🇺",flagSvg:"https://flagcdn.com/hu.svg",flagPng:"https://flagcdn.com/w40/hu.png",phoneCode:"+36"},{name:"Iceland",code:"IS",flagEmoji:"🇮🇸",flagSvg:"https://flagcdn.com/is.svg",flagPng:"https://flagcdn.com/w40/is.png",phoneCode:"+354"},{name:"India",code:"IN",flagEmoji:"🇮🇳",flagSvg:"https://flagcdn.com/in.svg",flagPng:"https://flagcdn.com/w40/in.png",phoneCode:"+91"},{name:"Indonesia",code:"ID",flagEmoji:"🇮🇩",flagSvg:"https://flagcdn.com/id.svg",flagPng:"https://flagcdn.com/w40/id.png",phoneCode:"+62"},{name:"Iran (Islamic Republic of)",code:"IR",flagEmoji:"🇮🇷",flagSvg:"https://flagcdn.com/ir.svg",flagPng:"https://flagcdn.com/w40/ir.png",phoneCode:"+98"},{name:"Iraq",code:"IQ",flagEmoji:"🇮🇶",flagSvg:"https://flagcdn.com/iq.svg",flagPng:"https://flagcdn.com/w40/iq.png",phoneCode:"+964"},{name:"Ireland",code:"IE",flagEmoji:"🇮🇪",flagSvg:"https://flagcdn.com/ie.svg",flagPng:"https://flagcdn.com/w40/ie.png",phoneCode:"+353"},{name:"Isle of Man",code:"IM",flagEmoji:"🇮🇲",flagSvg:"https://flagcdn.com/im.svg",flagPng:"https://flagcdn.com/w40/im.png",phoneCode:"+44"},{name:"Israel",code:"IL",flagEmoji:"🇮🇱",flagSvg:"https://flagcdn.com/il.svg",flagPng:"https://flagcdn.com/w40/il.png",phoneCode:"+972"},{name:"Italy",code:"IT",flagEmoji:"🇮🇹",flagSvg:"https://flagcdn.com/it.svg",flagPng:"https://flagcdn.com/w40/it.png",phoneCode:"+39"},{name:"Jamaica",code:"JM",flagEmoji:"🇯🇲",flagSvg:"https://flagcdn.com/jm.svg",flagPng:"https://flagcdn.com/w40/jm.png",phoneCode:"+1876"},{name:"Japan",code:"JP",flagEmoji:"🇯🇵",flagSvg:"https://flagcdn.com/jp.svg",flagPng:"https://flagcdn.com/w40/jp.png",phoneCode:"+81"},{name:"Jersey",code:"JE",flagEmoji:"🇯🇪",flagSvg:"https://flagcdn.com/je.svg",flagPng:"https://flagcdn.com/w40/je.png",phoneCode:"+44"},{name:"Jordan",code:"JO",flagEmoji:"🇯🇴",flagSvg:"https://flagcdn.com/jo.svg",flagPng:"https://flagcdn.com/w40/jo.png",phoneCode:"+962"},{name:"Kazakhstan",code:"KZ",flagEmoji:"🇰🇿",flagSvg:"https://flagcdn.com/kz.svg",flagPng:"https://flagcdn.com/w40/kz.png",phoneCode:"+7"},{name:"Kenya",code:"KE",flagEmoji:"🇰🇪",flagSvg:"https://flagcdn.com/ke.svg",flagPng:"https://flagcdn.com/w40/ke.png",phoneCode:"+254"},{name:"Kiribati",code:"KI",flagEmoji:"🇰🇮",flagSvg:"https://flagcdn.com/ki.svg",flagPng:"https://flagcdn.com/w40/ki.png",phoneCode:"+686"},{name:"Korea (Democratic People's Republic of)",code:"KP",flagEmoji:"🇰🇵",flagSvg:"https://flagcdn.com/kp.svg",flagPng:"https://flagcdn.com/w40/kp.png",phoneCode:"+850"},{name:"Korea, Republic of",code:"KR",flagEmoji:"🇰🇷",flagSvg:"https://flagcdn.com/kr.svg",flagPng:"https://flagcdn.com/w40/kr.png",phoneCode:"+82"},{name:"Kuwait",code:"KW",flagEmoji:"🇰🇼",flagSvg:"https://flagcdn.com/kw.svg",flagPng:"https://flagcdn.com/w40/kw.png",phoneCode:"+965"},{name:"Kyrgyzstan",code:"KG",flagEmoji:"🇰🇬",flagSvg:"https://flagcdn.com/kg.svg",flagPng:"https://flagcdn.com/w40/kg.png",phoneCode:"+996"},{name:"Lao People's Democratic Republic",code:"LA",flagEmoji:"🇱🇦",flagSvg:"https://flagcdn.com/la.svg",flagPng:"https://flagcdn.com/w40/la.png",phoneCode:"+856"},{name:"Latvia",code:"LV",flagEmoji:"🇱🇻",flagSvg:"https://flagcdn.com/lv.svg",flagPng:"https://flagcdn.com/w40/lv.png",phoneCode:"+371"},{name:"Lebanon",code:"LB",flagEmoji:"🇱🇧",flagSvg:"https://flagcdn.com/lb.svg",flagPng:"https://flagcdn.com/w40/lb.png",phoneCode:"+961"},{name:"Lesotho",code:"LS",flagEmoji:"🇱🇸",flagSvg:"https://flagcdn.com/ls.svg",flagPng:"https://flagcdn.com/w40/ls.png",phoneCode:"+266"},{name:"Liberia",code:"LR",flagEmoji:"🇱🇷",flagSvg:"https://flagcdn.com/lr.svg",flagPng:"https://flagcdn.com/w40/lr.png",phoneCode:"+231"},{name:"Libya",code:"LY",flagEmoji:"🇱🇾",flagSvg:"https://flagcdn.com/ly.svg",flagPng:"https://flagcdn.com/w40/ly.png",phoneCode:"+218"},{name:"Liechtenstein",code:"LI",flagEmoji:"🇱🇮",flagSvg:"https://flagcdn.com/li.svg",flagPng:"https://flagcdn.com/w40/li.png",phoneCode:"+423"},{name:"Lithuania",code:"LT",flagEmoji:"🇱🇹",flagSvg:"https://flagcdn.com/lt.svg",flagPng:"https://flagcdn.com/w40/lt.png",phoneCode:"+370"},{name:"Luxembourg",code:"LU",flagEmoji:"🇱🇺",flagSvg:"https://flagcdn.com/lu.svg",flagPng:"https://flagcdn.com/w40/lu.png",phoneCode:"+352"},{name:"Macao",code:"MO",flagEmoji:"🇲🇴",flagSvg:"https://flagcdn.com/mo.svg",flagPng:"https://flagcdn.com/w40/mo.png",phoneCode:"+853"},{name:"Madagascar",code:"MG",flagEmoji:"🇲🇬",flagSvg:"https://flagcdn.com/mg.svg",flagPng:"https://flagcdn.com/w40/mg.png",phoneCode:"+261"},{name:"Malawi",code:"MW",flagEmoji:"🇲🇼",flagSvg:"https://flagcdn.com/mw.svg",flagPng:"https://flagcdn.com/w40/mw.png",phoneCode:"+265"},{name:"Malaysia",code:"MY",flagEmoji:"🇲🇾",flagSvg:"https://flagcdn.com/my.svg",flagPng:"https://flagcdn.com/w40/my.png",phoneCode:"+60"},{name:"Maldives",code:"MV",flagEmoji:"🇲🇻",flagSvg:"https://flagcdn.com/mv.svg",flagPng:"https://flagcdn.com/w40/mv.png",phoneCode:"+960"},{name:"Mali",code:"ML",flagEmoji:"🇲🇱",flagSvg:"https://flagcdn.com/ml.svg",flagPng:"https://flagcdn.com/w40/ml.png",phoneCode:"+223"},{name:"Malta",code:"MT",flagEmoji:"🇲🇹",flagSvg:"https://flagcdn.com/mt.svg",flagPng:"https://flagcdn.com/w40/mt.png",phoneCode:"+356"},{name:"Marshall Islands",code:"MH",flagEmoji:"🇲🇭",flagSvg:"https://flagcdn.com/mh.svg",flagPng:"https://flagcdn.com/w40/mh.png",phoneCode:"+692"},{name:"Martinique",code:"MQ",flagEmoji:"🇲🇶",flagSvg:"https://flagcdn.com/mq.svg",flagPng:"https://flagcdn.com/w40/mq.png",phoneCode:"+596"},{name:"Mauritania",code:"MR",flagEmoji:"🇲🇷",flagSvg:"https://flagcdn.com/mr.svg",flagPng:"https://flagcdn.com/w40/mr.png",phoneCode:"+222"},{name:"Mauritius",code:"MU",flagEmoji:"🇲🇺",flagSvg:"https://flagcdn.com/mu.svg",flagPng:"https://flagcdn.com/w40/mu.png",phoneCode:"+230"},{name:"Mayotte",code:"YT",flagEmoji:"🇾🇹",flagSvg:"https://flagcdn.com/yt.svg",flagPng:"https://flagcdn.com/w40/yt.png",phoneCode:"+262"},{name:"Mexico",code:"MX",flagEmoji:"🇲🇽",flagSvg:"https://flagcdn.com/mx.svg",flagPng:"https://flagcdn.com/w40/mx.png",phoneCode:"+52"},{name:"Micronesia (Federated States of)",code:"FM",flagEmoji:"🇫🇲",flagSvg:"https://flagcdn.com/fm.svg",flagPng:"https://flagcdn.com/w40/fm.png",phoneCode:"+691"},{name:"Moldova, Republic of",code:"MD",flagEmoji:"🇲🇩",flagSvg:"https://flagcdn.com/md.svg",flagPng:"https://flagcdn.com/w40/md.png",phoneCode:"+373"},{name:"Monaco",code:"MC",flagEmoji:"🇲🇨",flagSvg:"https://flagcdn.com/mc.svg",flagPng:"https://flagcdn.com/w40/mc.png",phoneCode:"+377",phonelengthMAX:10},{name:"Mongolia",code:"MN",flagEmoji:"🇲🇳",flagSvg:"https://flagcdn.com/mn.svg",flagPng:"https://flagcdn.com/w40/mn.png",phoneCode:"+976"},{name:"Montenegro",code:"ME",flagEmoji:"🇲🇪",flagSvg:"https://flagcdn.com/me.svg",flagPng:"https://flagcdn.com/w40/me.png",phoneCode:"+382"},{name:"Montserrat",code:"MS",flagEmoji:"🇲🇸",flagSvg:"https://flagcdn.com/ms.svg",flagPng:"https://flagcdn.com/w40/ms.png",phoneCode:"+1664"},{name:"Morocco",code:"MA",flagEmoji:"🇲🇦",flagSvg:"https://flagcdn.com/ma.svg",flagPng:"https://flagcdn.com/w40/ma.png",phoneCode:"+212"},{name:"Mozambique",code:"MZ",flagEmoji:"🇲🇿",flagSvg:"https://flagcdn.com/mz.svg",flagPng:"https://flagcdn.com/w40/mz.png",phoneCode:"+258"},{name:"Myanmar",code:"MM",flagEmoji:"🇲🇲",flagSvg:"https://flagcdn.com/mm.svg",flagPng:"https://flagcdn.com/w40/mm.png",phoneCode:"+95"},{name:"Namibia",code:"NA",flagEmoji:"🇳🇦",flagSvg:"https://flagcdn.com/na.svg",flagPng:"https://flagcdn.com/w40/na.png",phoneCode:"+264"},{name:"Nauru",code:"NR",flagEmoji:"🇳🇷",flagSvg:"https://flagcdn.com/nr.svg",flagPng:"https://flagcdn.com/w40/nr.png",phoneCode:"+674"},{name:"Nepal",code:"NP",flagEmoji:"🇳🇵",flagSvg:"https://flagcdn.com/np.svg",flagPng:"https://flagcdn.com/w40/np.png",phoneCode:"+977"},{name:"Netherlands",code:"NL",flagEmoji:"🇳🇱",flagSvg:"https://flagcdn.com/nl.svg",flagPng:"https://flagcdn.com/w40/nl.png",phoneCode:"+31"},{name:"New Caledonia",code:"NC",flagEmoji:"🇳🇨",flagSvg:"https://flagcdn.com/nc.svg",flagPng:"https://flagcdn.com/w40/nc.png",phoneCode:"+687"},{name:"New Zealand",code:"NZ",flagEmoji:"🇳🇿",flagSvg:"https://flagcdn.com/nz.svg",flagPng:"https://flagcdn.com/w40/nz.png",phoneCode:"+64"},{name:"Nicaragua",code:"NI",flagEmoji:"🇳🇮",flagSvg:"https://flagcdn.com/ni.svg",flagPng:"https://flagcdn.com/w40/ni.png",phoneCode:"+505"},{name:"Niger",code:"NE",flagEmoji:"🇳🇪",flagSvg:"https://flagcdn.com/ne.svg",flagPng:"https://flagcdn.com/w40/ne.png",phoneCode:"+227"},{name:"Nigeria",code:"NG",flagEmoji:"🇳🇬",flagSvg:"https://flagcdn.com/ng.svg",flagPng:"https://flagcdn.com/w40/ng.png",phoneCode:"+234"},{name:"Niue",code:"NU",flagEmoji:"🇳🇺",flagSvg:"https://flagcdn.com/nu.svg",flagPng:"https://flagcdn.com/w40/nu.png",phoneCode:"+683"},{name:"Norfolk Island",code:"NF",flagEmoji:"🇳🇫",flagSvg:"https://flagcdn.com/nf.svg",flagPng:"https://flagcdn.com/w40/nf.png",phoneCode:"+672"},{name:"North Macedonia",code:"MK",flagEmoji:"🇲🇰",flagSvg:"https://flagcdn.com/mk.svg",flagPng:"https://flagcdn.com/w40/mk.png",phoneCode:"+389"},{name:"Northern Mariana Islands",code:"MP",flagEmoji:"🇲🇵",flagSvg:"https://flagcdn.com/mp.svg",flagPng:"https://flagcdn.com/w40/mp.png",phoneCode:"+1670"},{name:"Norway",code:"NO",flagEmoji:"🇳🇴",flagSvg:"https://flagcdn.com/no.svg",flagPng:"https://flagcdn.com/w40/no.png",phoneCode:"+47"},{name:"Oman",code:"OM",flagEmoji:"🇴🇲",flagSvg:"https://flagcdn.com/om.svg",flagPng:"https://flagcdn.com/w40/om.png",phoneCode:"+968"},{name:"Pakistan",code:"PK",flagEmoji:"🇵🇰",flagSvg:"https://flagcdn.com/pk.svg",flagPng:"https://flagcdn.com/w40/pk.png",phoneCode:"+92"},{name:"Palau",code:"PW",flagEmoji:"🇵🇼",flagSvg:"https://flagcdn.com/pw.svg",flagPng:"https://flagcdn.com/w40/pw.png",phoneCode:"+680"},{name:"Palestine, State of",code:"PS",flagEmoji:"🇵🇸",flagSvg:"https://flagcdn.com/ps.svg",flagPng:"https://flagcdn.com/w40/ps.png",phoneCode:"+970"},{name:"Panama",code:"PA",flagEmoji:"🇵🇦",flagSvg:"https://flagcdn.com/pa.svg",flagPng:"https://flagcdn.com/w40/pa.png",phoneCode:"+507"},{name:"Papua New Guinea",code:"PG",flagEmoji:"🇵🇬",flagSvg:"https://flagcdn.com/pg.svg",flagPng:"https://flagcdn.com/w40/pg.png",phoneCode:"+675"},{name:"Paraguay",code:"PY",flagEmoji:"🇵🇾",flagSvg:"https://flagcdn.com/py.svg",flagPng:"https://flagcdn.com/w40/py.png",phoneCode:"+595"},{name:"Peru",code:"PE",flagEmoji:"🇵🇪",flagSvg:"https://flagcdn.com/pe.svg",flagPng:"https://flagcdn.com/w40/pe.png",phoneCode:"+51"},{name:"Philippines",code:"PH",flagEmoji:"🇵🇭",flagSvg:"https://flagcdn.com/ph.svg",flagPng:"https://flagcdn.com/w40/ph.png",phoneCode:"+63"},{name:"Pitcairn",code:"PN",flagEmoji:"🇵🇳",flagSvg:"https://flagcdn.com/pn.svg",flagPng:"https://flagcdn.com/w40/pn.png",phoneCode:"+64"},{name:"Poland",code:"PL",flagEmoji:"🇵🇱",flagSvg:"https://flagcdn.com/pl.svg",flagPng:"https://flagcdn.com/w40/pl.png",phoneCode:"+48"},{name:"Portugal",code:"PT",flagEmoji:"🇵🇹",flagSvg:"https://flagcdn.com/pt.svg",flagPng:"https://flagcdn.com/w40/pt.png",phoneCode:"+351"},{name:"Puerto Rico",code:"PR",flagEmoji:"🇵🇷",flagSvg:"https://flagcdn.com/pr.svg",flagPng:"https://flagcdn.com/w40/pr.png",phoneCode:"+1787"},{name:"Qatar",code:"QA",flagEmoji:"🇶🇦",flagSvg:"https://flagcdn.com/qa.svg",flagPng:"https://flagcdn.com/w40/qa.png",phoneCode:"+974"},{name:"Réunion",code:"RE",flagEmoji:"🇷🇪",flagSvg:"https://flagcdn.com/re.svg",flagPng:"https://flagcdn.com/w40/re.png",phoneCode:"+262"},{name:"Romania",code:"RO",flagEmoji:"🇷🇴",flagSvg:"https://flagcdn.com/ro.svg",flagPng:"https://flagcdn.com/w40/ro.png",phoneCode:"+40"},{name:"Russian Federation",code:"RU",flagEmoji:"🇷🇺",flagSvg:"https://flagcdn.com/ru.svg",flagPng:"https://flagcdn.com/w40/ru.png",phoneCode:"+7"},{name:"Rwanda",code:"RW",flagEmoji:"🇷🇼",flagSvg:"https://flagcdn.com/rw.svg",flagPng:"https://flagcdn.com/w40/rw.png",phoneCode:"+250"},{name:"Saint Barthélemy",code:"BL",flagEmoji:"🇧🇱",flagSvg:"https://flagcdn.com/bl.svg",flagPng:"https://flagcdn.com/w40/bl.png",phoneCode:"+590"},{name:"Saint Helena, Ascension and Tristan da Cunha",code:"SH",flagEmoji:"🇸🇭",flagSvg:"https://flagcdn.com/sh.svg",flagPng:"https://flagcdn.com/w40/sh.png",phoneCode:"+290"},{name:"Saint Kitts and Nevis",code:"KN",flagEmoji:"🇰🇳",flagSvg:"https://flagcdn.com/kn.svg",flagPng:"https://flagcdn.com/w40/kn.png",phoneCode:"+1869"},{name:"Saint Lucia",code:"LC",flagEmoji:"🇱🇨",flagSvg:"https://flagcdn.com/lc.svg",flagPng:"https://flagcdn.com/w40/lc.png",phoneCode:"+1758"},{name:"Saint Martin (French part)",code:"MF",flagEmoji:"🇲🇫",flagSvg:"https://flagcdn.com/mf.svg",flagPng:"https://flagcdn.com/w40/mf.png",phoneCode:"+590"},{name:"Saint Pierre and Miquelon",code:"PM",flagEmoji:"🇵🇲",flagSvg:"https://flagcdn.com/pm.svg",flagPng:"https://flagcdn.com/w40/pm.png",phoneCode:"+508"},{name:"Saint Vincent and the Grenadines",code:"VC",flagEmoji:"🇻🇨",flagSvg:"https://flagcdn.com/vc.svg",flagPng:"https://flagcdn.com/w40/vc.png",phoneCode:"+1784"},{name:"Samoa",code:"WS",flagEmoji:"🇼🇸",flagSvg:"https://flagcdn.com/ws.svg",flagPng:"https://flagcdn.com/w40/ws.png",phoneCode:"+685"},{name:"San Marino",code:"SM",flagEmoji:"🇸🇲",flagSvg:"https://flagcdn.com/sm.svg",flagPng:"https://flagcdn.com/w40/sm.png",phoneCode:"+378"},{name:"Sao Tome and Principe",code:"ST",flagEmoji:"🇸🇹",flagSvg:"https://flagcdn.com/st.svg",flagPng:"https://flagcdn.com/w40/st.png",phoneCode:"+239"},{name:"Saudi Arabia",code:"SA",flagEmoji:"🇸🇦",flagSvg:"https://flagcdn.com/sa.svg",flagPng:"https://flagcdn.com/w40/sa.png",phoneCode:"+966"},{name:"Senegal",code:"SN",flagEmoji:"🇸🇳",flagSvg:"https://flagcdn.com/sn.svg",flagPng:"https://flagcdn.com/w40/sn.png",phoneCode:"+221"},{name:"Serbia",code:"RS",flagEmoji:"🇷🇸",flagSvg:"https://flagcdn.com/rs.svg",flagPng:"https://flagcdn.com/w40/rs.png",phoneCode:"+381"},{name:"Seychelles",code:"SC",flagEmoji:"🇸🇨",flagSvg:"https://flagcdn.com/sc.svg",flagPng:"https://flagcdn.com/w40/sc.png",phoneCode:"+248"},{name:"Sierra Leone",code:"SL",flagEmoji:"🇸🇱",flagSvg:"https://flagcdn.com/sl.svg",flagPng:"https://flagcdn.com/w40/sl.png",phoneCode:"+232"},{name:"Singapore",code:"SG",flagEmoji:"🇸🇬",flagSvg:"https://flagcdn.com/sg.svg",flagPng:"https://flagcdn.com/w40/sg.png",phoneCode:"+65"},{name:"Sint Maarten (Dutch part)",code:"SX",flagEmoji:"🇸🇽",flagSvg:"https://flagcdn.com/sx.svg",flagPng:"https://flagcdn.com/w40/sx.png",phoneCode:"+1721"},{name:"Slovakia",code:"SK",flagEmoji:"🇸🇰",flagSvg:"https://flagcdn.com/sk.svg",flagPng:"https://flagcdn.com/w40/sk.png",phoneCode:"+421"},{name:"Slovenia",code:"SI",flagEmoji:"🇸🇮",flagSvg:"https://flagcdn.com/si.svg",flagPng:"https://flagcdn.com/w40/si.png",phoneCode:"+386"},{name:"Solomon Islands",code:"SB",flagEmoji:"🇸🇧",flagSvg:"https://flagcdn.com/sb.svg",flagPng:"https://flagcdn.com/w40/sb.png",phoneCode:"+677"},{name:"Somalia",code:"SO",flagEmoji:"🇸🇴",flagSvg:"https://flagcdn.com/so.svg",flagPng:"https://flagcdn.com/w40/so.png",phoneCode:"+252"},{name:"South Africa",code:"ZA",flagEmoji:"🇿🇦",flagSvg:"https://flagcdn.com/za.svg",flagPng:"https://flagcdn.com/w40/za.png",phoneCode:"+27"},{name:"South Georgia and the South Sandwich Islands",code:"GS",flagEmoji:"🇬🇸",flagSvg:"https://flagcdn.com/gs.svg",flagPng:"https://flagcdn.com/w40/gs.png",phoneCode:"+500"},{name:"South Sudan",code:"SS",flagEmoji:"🇸🇸",flagSvg:"https://flagcdn.com/ss.svg",flagPng:"https://flagcdn.com/w40/ss.png",phoneCode:"+211"},{name:"Spain",code:"ES",flagEmoji:"🇪🇸",flagSvg:"https://flagcdn.com/es.svg",flagPng:"https://flagcdn.com/w40/es.png",phoneCode:"+34"},{name:"Sri Lanka",code:"LK",flagEmoji:"🇱🇰",flagSvg:"https://flagcdn.com/lk.svg",flagPng:"https://flagcdn.com/w40/lk.png",phoneCode:"+94"},{name:"Sudan",code:"SD",flagEmoji:"🇸🇩",flagSvg:"https://flagcdn.com/sd.svg",flagPng:"https://flagcdn.com/w40/sd.png",phoneCode:"+249"},{name:"Suriname",code:"SR",flagEmoji:"🇸🇷",flagSvg:"https://flagcdn.com/sr.svg",flagPng:"https://flagcdn.com/w40/sr.png",phoneCode:"+597"},{name:"Svalbard and Jan Mayen",code:"SJ",flagEmoji:"🇸🇯",flagSvg:"https://flagcdn.com/sj.svg",flagPng:"https://flagcdn.com/w40/sj.png",phoneCode:"+47"},{name:"Sweden",code:"SE",flagEmoji:"🇸🇪",flagSvg:"https://flagcdn.com/se.svg",flagPng:"https://flagcdn.com/w40/se.png",phoneCode:"+46"},{name:"Switzerland",code:"CH",flagEmoji:"🇨🇭",flagSvg:"https://flagcdn.com/ch.svg",flagPng:"https://flagcdn.com/w40/ch.png",phoneCode:"+41"},{name:"Syrian Arab Republic",code:"SY",flagEmoji:"🇸🇾",flagSvg:"https://flagcdn.com/sy.svg",flagPng:"https://flagcdn.com/w40/sy.png",phoneCode:"+963"},{name:"Taiwan, Province of China",code:"TW",flagEmoji:"🇹🇼",flagSvg:"https://flagcdn.com/tw.svg",flagPng:"https://flagcdn.com/w40/tw.png",phoneCode:"+886"},{name:"Tajikistan",code:"TJ",flagEmoji:"🇹🇯",flagSvg:"https://flagcdn.com/tj.svg",flagPng:"https://flagcdn.com/w40/tj.png",phoneCode:"+992"},{name:"Tanzania, United Republic of",code:"TZ",flagEmoji:"🇹🇿",flagSvg:"https://flagcdn.com/tz.svg",flagPng:"https://flagcdn.com/w40/tz.png",phoneCode:"+255"},{name:"Thailand",code:"TH",flagEmoji:"🇹🇭",flagSvg:"https://flagcdn.com/th.svg",flagPng:"https://flagcdn.com/w40/th.png",phoneCode:"+66"},{name:"Timor-Leste",code:"TL",flagEmoji:"🇹🇱",flagSvg:"https://flagcdn.com/tl.svg",flagPng:"https://flagcdn.com/w40/tl.png",phoneCode:"+670"},{name:"Togo",code:"TG",flagEmoji:"🇹🇬",flagSvg:"https://flagcdn.com/tg.svg",flagPng:"https://flagcdn.com/w40/tg.png",phoneCode:"+228"},{name:"Tokelau",code:"TK",flagEmoji:"🇹🇰",flagSvg:"https://flagcdn.com/tk.svg",flagPng:"https://flagcdn.com/w40/tk.png",phoneCode:"+690"},{name:"Tonga",code:"TO",flagEmoji:"🇹🇴",flagSvg:"https://flagcdn.com/to.svg",flagPng:"https://flagcdn.com/w40/to.png",phoneCode:"+676"},{name:"Trinidad and Tobago",code:"TT",flagEmoji:"🇹🇹",flagSvg:"https://flagcdn.com/tt.svg",flagPng:"https://flagcdn.com/w40/tt.png",phoneCode:"+1868"},{name:"Tunisia",code:"TN",flagEmoji:"🇹🇳",flagSvg:"https://flagcdn.com/tn.svg",flagPng:"https://flagcdn.com/w40/tn.png",phoneCode:"+216"},{name:"Turkey",code:"TR",flagEmoji:"🇹🇷",flagSvg:"https://flagcdn.com/tr.svg",flagPng:"https://flagcdn.com/w40/tr.png",phoneCode:"+90"},{name:"Turkmenistan",code:"TM",flagEmoji:"🇹🇲",flagSvg:"https://flagcdn.com/tm.svg",flagPng:"https://flagcdn.com/w40/tm.png",phoneCode:"+993"},{name:"Turks and Caicos Islands",code:"TC",flagEmoji:"🇹🇨",flagSvg:"https://flagcdn.com/tc.svg",flagPng:"https://flagcdn.com/w40/tc.png",phoneCode:"+1649"},{name:"Tuvalu",code:"TV",flagEmoji:"🇹🇻",flagSvg:"https://flagcdn.com/tv.svg",flagPng:"https://flagcdn.com/w40/tv.png",phoneCode:"+688"},{name:"Uganda",code:"UG",flagEmoji:"🇺🇬",flagSvg:"https://flagcdn.com/ug.svg",flagPng:"https://flagcdn.com/w40/ug.png",phoneCode:"+256"},{name:"Ukraine",code:"UA",flagEmoji:"🇺🇦",flagSvg:"https://flagcdn.com/ua.svg",flagPng:"https://flagcdn.com/w40/ua.png",phoneCode:"+380"},{name:"United Arab Emirates",code:"AE",flagEmoji:"🇦🇪",flagSvg:"https://flagcdn.com/ae.svg",flagPng:"https://flagcdn.com/w40/ae.png",phoneCode:"+971"},{name:"United Kingdom of Great Britain and Northern Ireland",code:"GB",flagEmoji:"🇬🇧",flagSvg:"https://flagcdn.com/gb.svg",flagPng:"https://flagcdn.com/w40/gb.png",phoneCode:"+44"},{name:"United States",code:"US",flagEmoji:"🇺🇸",flagSvg:"https://flagcdn.com/us.svg",flagPng:"https://flagcdn.com/w40/us.png",phoneCode:"+1"},{name:"United States Minor Outlying Islands",code:"UM",flagEmoji:"🇺🇲",flagSvg:"https://flagcdn.com/um.svg",flagPng:"https://flagcdn.com/w40/um.png",phoneCode:"+1"},{name:"Uruguay",code:"UY",flagEmoji:"🇺🇾",flagSvg:"https://flagcdn.com/uy.svg",flagPng:"https://flagcdn.com/w40/uy.png",phoneCode:"+598"},{name:"Uzbekistan",code:"UZ",flagEmoji:"🇺🇿",flagSvg:"https://flagcdn.com/uz.svg",flagPng:"https://flagcdn.com/w40/uz.png",phoneCode:"+998"},{name:"Vanuatu",code:"VU",flagEmoji:"🇻🇺",flagSvg:"https://flagcdn.com/vu.svg",flagPng:"https://flagcdn.com/w40/vu.png",phoneCode:"+678"},{name:"Venezuela (Bolivarian Republic of)",code:"VE",flagEmoji:"🇻🇪",flagSvg:"https://flagcdn.com/ve.svg",flagPng:"https://flagcdn.com/w40/ve.png",phoneCode:"+58"},{name:"Viet Nam",code:"VN",flagEmoji:"🇻🇳",flagSvg:"https://flagcdn.com/vn.svg",flagPng:"https://flagcdn.com/w40/vn.png",phoneCode:"+84"},{name:"Virgin Islands (British)",code:"VG",flagEmoji:"🇻🇬",flagSvg:"https://flagcdn.com/vg.svg",flagPng:"https://flagcdn.com/w40/vg.png",phoneCode:"+1284"},{name:"Virgin Islands (U.S.)",code:"VI",flagEmoji:"🇻🇮",flagSvg:"https://flagcdn.com/vi.svg",flagPng:"https://flagcdn.com/w40/vi.png",phoneCode:"+1340"},{name:"Wallis and Futuna",code:"WF",flagEmoji:"🇼🇫",flagSvg:"https://flagcdn.com/wf.svg",flagPng:"https://flagcdn.com/w40/wf.png",phoneCode:"+681"},{name:"Western Sahara",code:"EH",flagEmoji:"🇪🇭",flagSvg:"https://flagcdn.com/eh.svg",flagPng:"https://flagcdn.com/w40/eh.png",phoneCode:"+212"},{name:"Yemen",code:"YE",flagEmoji:"🇾🇪",flagSvg:"https://flagcdn.com/ye.svg",flagPng:"https://flagcdn.com/w40/ye.png",phoneCode:"+967"},{name:"Zambia",code:"ZM",flagEmoji:"🇿🇲",flagSvg:"https://flagcdn.com/zm.svg",flagPng:"https://flagcdn.com/w40/zm.png",phoneCode:"+260"},{name:"Zimbabwe",code:"ZW",flagEmoji:"🇿🇼",flagSvg:"https://flagcdn.com/zw.svg",flagPng:"https://flagcdn.com/w40/zw.png",phoneCode:"+263"}],Qn=["tabindex"],Jn={class:"flex items-center gap-2"},eo=["src","alt"],to={key:0,class:"absolute z-[9999] w-full mt-1 bg-white border border-gray-300 rounded-md shadow-lg max-h-60 overflow-y-auto",style:{position:"absolute"}},no=["onClick"],oo=["src","alt","onError"],ao=e.defineComponent({__name:"index",props:{modelValue:{default:""},placeholder:{default:""},disabled:{type:Boolean,default:!1},required:{type:Boolean,default:!1},customClass:{default:""},autoDetectFromIp:{type:Boolean,default:!0},returnType:{default:"name"},priorityCountries:{default:()=>["US","CA","GB","DE","FR","JP","CN","AU"]},ipDetectUrl:{default:"https://ipinfo.io/json"},ipDetectMethod:{default:"GET"},ipDetectHeaders:{},ipDetectResponseParser:{}},emits:["update:modelValue","change","ip-detect-start","ip-detect-success","ip-detect-error"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(!1),c=e.ref(Zn),i=e.computed(()=>n.modelValue?c.value.find(u=>n.returnType==="code"?u.code===n.modelValue:u.name===n.modelValue):null),r=e.computed(()=>{const u=c.value.filter(w=>n.priorityCountries.includes(w.code)),f=c.value.filter(w=>!n.priorityCountries.includes(w.code)),y=u.sort((w,S)=>{const D=n.priorityCountries.indexOf(w.code),P=n.priorityCountries.indexOf(S.code);return D-P}),k=f.sort((w,S)=>w.name.localeCompare(S.name));return[...y,...k]}),d=()=>{n.disabled||(s.value=!s.value)},g=()=>{s.value=!1},p=u=>{if(u){const f=n.returnType==="code"?u.code:u.name;a("update:modelValue",f),a("change",f,u)}else a("update:modelValue","");g()},v=(u,f)=>{const y=u.target;f&&y.src===f.flagSvg?y.src=f.flagPng:i.value&&y.src===i.value.flagSvg&&(y.src=i.value.flagPng)},h=async()=>{if(!(!n.autoDetectFromIp||n.modelValue)){a("ip-detect-start");try{const u={method:n.ipDetectMethod,headers:{"Content-Type":"application/json",...n.ipDetectHeaders}},f=await fetch(n.ipDetectUrl,u);if(!f.ok)throw new Error(`HTTP error! status: ${f.status}`);const y=await f.json();let k;if(n.ipDetectResponseParser?k=n.ipDetectResponseParser(y):k=y.country||y.countryCode||y.country_code||"",k=k.toUpperCase(),!k)throw new Error("Country code not found in response");console.log("Auto-detected country from IP:",k),a("ip-detect-success",k);const w=c.value.find(S=>S.code===k);if(w){const S=n.returnType==="code"?w.code:w.name;a("update:modelValue",S),a("change",S,w)}else console.warn("Detected country code not found in country list:",k)}catch(u){const f=u instanceof Error?u:new Error(String(u));console.warn("Failed to detect country from IP:",f),a("ip-detect-error",f)}}},x=e.ref();return e.onMounted(async()=>{await e.nextTick(),n.autoDetectFromIp&&!n.modelValue&&await h();const u=f=>{x.value&&!x.value.contains(f.target)&&g()};document.addEventListener("click",u),e.onUnmounted(()=>{document.removeEventListener("click",u)})}),l({detectCountryFromIp:h,allCountries:e.readonly(c),sortedCountries:e.readonly(r)}),(u,f)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:x,class:"country-select-container relative"},[e.createElementVNode("div",{onClick:d,class:e.normalizeClass(["w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-[#1a1a1a] focus:border-[#1a1a1a] transition-colors duration-200 cursor-pointer bg-white flex items-center justify-between",t.customClass,{"opacity-60 cursor-not-allowed":t.disabled}]),tabindex:t.disabled?-1:0,onKeydown:[e.withKeys(d,["enter"]),e.withKeys(d,["space"]),e.withKeys(g,["escape"])]},[e.createElementVNode("div",Jn,[i.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:i.value.flagSvg,alt:i.value.name,class:"w-5 h-4 object-cover rounded-sm",onError:v},null,40,eo)):e.createCommentVNode("",!0),e.createElementVNode("span",{class:e.normalizeClass({"text-gray-500":!i.value&&t.placeholder})},e.toDisplayString(i.value?i.value.name:t.placeholder||"选择国家"),3)]),(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["w-5 h-5 text-gray-400 transition-transform duration-200",{"rotate-180":s.value}]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...f[0]||(f[0]=[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M19 9l-7 7-7-7"},null,-1)])],2))],42,Qn),s.value&&!t.disabled?(e.openBlock(),e.createElementBlock("div",to,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,y=>{var k;return e.openBlock(),e.createElementBlock("div",{key:y.code,onClick:w=>p(y),class:e.normalizeClass(["px-3 py-2 hover:bg-gray-50 cursor-pointer flex items-center gap-2 transition-colors",{"bg-gray-100":((k=i.value)==null?void 0:k.code)===y.code}])},[e.createElementVNode("img",{src:y.flagSvg,alt:y.name,class:"w-5 h-4 object-cover rounded-sm flex-shrink-0",onError:w=>v(w,y)},null,40,oo),e.createElementVNode("span",null,e.toDisplayString(y.name),1)],10,no)}),128))])):e.createCommentVNode("",!0),s.value&&!t.disabled?(e.openBlock(),e.createElementBlock("div",{key:1,class:"fixed inset-0 z-[9998]",onClick:g})):e.createCommentVNode("",!0)],512))}}),lo=Z(ao,[["__scopeId","data-v-08b31f1b"]]),so=["tabindex","aria-expanded","aria-labelledby"],co={class:"flex items-center gap-2 min-h-0 flex-1"},io={key:0,class:"text-gray-500"},ro={key:1,class:"flex flex-wrap gap-1"},go={key:0,class:"text-gray-900"},fo=["onClick"],uo={key:0,class:"absolute z-[9999] w-full mt-2 bg-white rounded-xl shadow-xl border border-gray-100/50 max-h-60 overflow-auto backdrop-blur-sm",role:"listbox"},mo={key:0,class:"p-3 border-b border-gray-50/80"},ho={class:"py-1"},po={key:0,class:"px-4 py-3 text-sm text-gray-400 text-center"},vo=["onClick","onKeydown","aria-selected"],yo={class:"flex items-center gap-3"},wo={key:0,class:"flex items-center"},bo={key:0,class:"bi bi-check text-[#1a1a1a] text-xs"},Co={key:1,class:"flex items-center"},ko={key:0,class:"w-1.5 h-1.5 bg-white rounded-full"},So={class:"flex-1"},xo=e.defineComponent({__name:"index",props:{modelValue:{},options:{},placeholder:{default:"请选择..."},multiple:{type:Boolean,default:!1},searchable:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},labelKey:{default:"label"},valueKey:{default:"value"},noOptionsText:{default:"暂无选项"},clearable:{type:Boolean,default:!1},borderless:{type:Boolean,default:!1},width:{default:"200px"}},emits:["update:modelValue","change","open","close"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(!1),c=e.ref(""),i=e.ref(),r=e.ref(),d=e.computed(()=>!n.searchable||!c.value?n.options:n.options.filter(m=>x(m).toLowerCase().includes(c.value.toLowerCase()))),g=e.computed(()=>n.multiple?null:n.options.find(m=>u(m)===n.modelValue)||null),p=e.computed(()=>n.multiple?Array.isArray(n.modelValue)?n.options.filter(m=>n.modelValue.includes(u(m))):[]:[]),v=e.computed(()=>n.multiple?p.value.length>0:g.value!==null),h=e.computed(()=>`select-label-${Math.random().toString(36).substr(2,9)}`),x=m=>typeof m=="object"?m[n.labelKey]:m,u=m=>typeof m=="object"?m[n.valueKey]:m,f=m=>{const E=u(m);return n.multiple?Array.isArray(n.modelValue)&&n.modelValue.includes(E):n.modelValue===E},y=m=>{if(m.disabled)return;const E=u(m);if(n.multiple){const b=Array.isArray(n.modelValue)?[...n.modelValue]:[],j=b.indexOf(E);j>-1?b.splice(j,1):b.push(E),a("update:modelValue",b),a("change",b)}else a("update:modelValue",E),a("change",E),D()},k=m=>{if(!n.multiple)return;const E=u(m),b=Array.isArray(n.modelValue)?[...n.modelValue]:[],j=b.indexOf(E);j>-1&&(b.splice(j,1),a("update:modelValue",b),a("change",b))},w=()=>{n.disabled||(s.value?D():S())},S=()=>{s.value=!0,a("open"),e.nextTick(()=>{n.searchable&&r.value&&r.value.focus()})},D=()=>{s.value=!1,c.value="",a("close")},P=m=>{i.value&&!i.value.contains(m.target)&&D()},B=m=>{if(!s.value)return;const E=d.value,b=E.findIndex(j=>f(j));switch(m.key){case"ArrowDown":m.preventDefault();break;case"ArrowUp":m.preventDefault();break;case"Enter":case" ":m.preventDefault(),b>=0&&E[b]&&y(E[b]);break}};return e.onMounted(()=>{document.addEventListener("click",P),document.addEventListener("keydown",B)}),e.onUnmounted(()=>{document.removeEventListener("click",P),document.removeEventListener("keydown",B)}),l({open:S,close:D,toggle:w}),(m,E)=>(e.openBlock(),e.createElementBlock("div",{class:"relative",style:e.normalizeStyle({width:t.width}),ref_key:"selectContainer",ref:i},[e.createElementVNode("div",{onClick:w,onKeydown:[e.withKeys(w,["enter"]),e.withKeys(w,["space"]),e.withKeys(D,["escape"])],class:e.normalizeClass(["flex items-center justify-between w-full px-4 py-1.5 text-sm bg-white rounded-md cursor-pointer transition-all duration-200 border ","focus:outline-none focus:ring-2 focus:ring-[#1a1a1a]/50 focus:ring-offset-1",{"shadow-sm hover:shadow-md border border-gray-200/60 hover:border-gray-300/80":!t.disabled&&!t.borderless,"shadow-sm hover:shadow-md":!t.disabled&&t.borderless,"bg-gray-50/50 cursor-not-allowed border border-gray-100":t.disabled,"ring-1 ring-[#1a1a1a]/50 border-[#1a1a1a]/50 shadow-md":s.value&&!t.borderless,"ring-1 ring-[#1a1a1a]/50 shadow-md":s.value&&t.borderless}]),tabindex:t.disabled?-1:0,role:"combobox","aria-expanded":s.value,"aria-haspopup":!0,"aria-labelledby":h.value},[e.createElementVNode("div",co,[t.placeholder&&!v.value?(e.openBlock(),e.createElementBlock("span",io,e.toDisplayString(t.placeholder),1)):(e.openBlock(),e.createElementBlock("div",ro,[t.multiple?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(p.value,b=>(e.openBlock(),e.createElementBlock("span",{key:u(b),class:"inline-flex items-center gap-1.5 px-2.5 py-1 text-xs bg-[#FFF] text-[#1a1a1a] rounded-full border border-[#1a1a1a]/50"},[e.createTextVNode(e.toDisplayString(x(b))+" ",1),e.createElementVNode("button",{onClick:e.withModifiers(j=>k(b),["stop"]),class:"rounded-full p-0.5 transition-colors duration-150",type:"button"},[...E[1]||(E[1]=[e.createElementVNode("i",{class:"bi bi-x text-xs text-[#1a1a1a]"},null,-1)])],8,fo)]))),128)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[g.value?(e.openBlock(),e.createElementBlock("span",go,e.toDisplayString(x(g.value)),1)):e.createCommentVNode("",!0)],64))]))]),e.createElementVNode("i",{class:e.normalizeClass(["bi text-gray-400 transition-transform duration-200 text-lg",{"bi-chevron-down":!s.value,"bi-chevron-up":s.value}])},null,2)],42,so),e.createVNode(e.Transition,{"enter-active-class":"transition ease-out duration-200","enter-from-class":"opacity-0 scale-95","enter-to-class":"opacity-100 scale-100","leave-active-class":"transition ease-in duration-150","leave-from-class":"opacity-100 scale-100","leave-to-class":"opacity-0 scale-95"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",uo,[t.searchable?(e.openBlock(),e.createElementBlock("div",mo,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchInput",ref:r,"onUpdate:modelValue":E[0]||(E[0]=b=>c.value=b),type:"text",class:"w-full px-3 py-2 text-sm bg-gray-50/50 border border-gray-200/60 rounded-lg focus:outline-none focus:ring-1 focus:ring-[#1a1a1a]/50 focus:border-[#1a1a1a]/50 transition-all duration-200",placeholder:"搜索...",onKeydown:e.withKeys(D,["escape"])},null,544),[[e.vModelText,c.value]])])):e.createCommentVNode("",!0),e.createElementVNode("div",ho,[d.value.length===0?(e.openBlock(),e.createElementBlock("div",po,e.toDisplayString(t.noOptionsText),1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,b=>(e.openBlock(),e.createElementBlock("div",{key:u(b),onClick:j=>y(b),onKeydown:[e.withKeys(j=>y(b),["enter"]),e.withKeys(j=>y(b),["space"])],class:e.normalizeClass(["px-4 py-3 text-sm cursor-pointer transition-all duration-150",{"bg-[#f2f2f2] text-[#1a1a1a] font-medium":f(b),"hover:bg-[#f2f2f2] text-gray-700":!f(b)}]),role:"option","aria-selected":f(b),tabindex:0},[e.createElementVNode("div",yo,[t.multiple?(e.openBlock(),e.createElementBlock("div",wo,[e.createElementVNode("div",{class:e.normalizeClass(["w-4 h-4 rounded border flex items-center justify-center transition-all duration-150",{"border-[#1a1a1a] text-white":f(b),"border-gray-300 bg-white":!f(b)}])},[f(b)?(e.openBlock(),e.createElementBlock("i",bo)):e.createCommentVNode("",!0)],2)])):(e.openBlock(),e.createElementBlock("div",Co,[e.createElementVNode("div",{class:e.normalizeClass(["w-4 h-4 rounded-full border-2 flex items-center justify-center transition-all duration-150",{"border-[#1a1a1a] bg-[#1a1a1a]":f(b),"border-gray-300 bg-white":!f(b)}])},[f(b)?(e.openBlock(),e.createElementBlock("div",ko)):e.createCommentVNode("",!0)],2)])),e.createElementVNode("span",So,e.toDisplayString(x(b)),1)])],42,vo))),128))])])):e.createCommentVNode("",!0)]),_:1})],4))}}),Eo=Z(xo,[["__scopeId","data-v-1f7381d8"]]),$o=["type","value","placeholder","disabled","readonly","required","maxlength","minlength","autocomplete"],Mo={key:2,class:"x-input-count"},Po=e.defineComponent({__name:"index",props:{modelValue:{},type:{default:"text"},placeholder:{default:""},label:{default:""},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},required:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},showWordLimit:{type:Boolean,default:!1},maxlength:{},minlength:{},autocomplete:{default:"off"},error:{type:Boolean,default:!1},width:{default:"100%"}},emits:["update:modelValue","input","change","blur","focus","clear","keydown","keyup"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(),c=e.ref(!1),i=e.computed(()=>!!n.label),r=e.computed(()=>{const S=n.modelValue;return S!=null&&S!==""}),d=e.computed(()=>String(n.modelValue||"").length),g=S=>{const P=S.target.value;a("update:modelValue",P),a("input",P,S)},p=S=>{const P=S.target.value;a("change",P,S)},v=S=>{c.value=!1,a("blur",S)},h=S=>{c.value=!0,a("focus",S)},x=S=>{a("keydown",S)},u=S=>{a("keyup",S)},f=()=>{var S;a("update:modelValue",""),a("clear"),(S=s.value)==null||S.focus()};return l({focus:()=>{var S;(S=s.value)==null||S.focus()},blur:()=>{var S;(S=s.value)==null||S.blur()},select:()=>{var S;(S=s.value)==null||S.select()},ref:s}),(S,D)=>(e.openBlock(),e.createElementBlock("div",{class:"x-input-group",style:e.normalizeStyle({width:t.width})},[e.createElementVNode("input",{ref_key:"inputRef",ref:s,type:t.type,value:t.modelValue,placeholder:i.value?"":t.placeholder,disabled:t.disabled,readonly:t.readonly,required:t.required,maxlength:t.maxlength,minlength:t.minlength,autocomplete:t.autocomplete,class:e.normalizeClass(["x-input",{"x-input--disabled":t.disabled,"x-input--error":t.error,"x-input--clearable":t.clearable&&t.modelValue,"x-input--with-label":i.value}]),onInput:g,onBlur:v,onFocus:h,onKeydown:x,onKeyup:u,onChange:p},null,42,$o),t.label?(e.openBlock(),e.createElementBlock("label",{key:0,class:e.normalizeClass(["x-input-label",{"x-input-label--active":c.value||r.value,"x-input-label--error":t.error}])},e.toDisplayString(t.label),3)):e.createCommentVNode("",!0),t.clearable&&t.modelValue&&!t.disabled?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"x-input-clear",onClick:f,onMousedown:D[0]||(D[0]=e.withModifiers(()=>{},["prevent"]))},[e.createVNode(e.unref(K),{icon:"bi:x-circle"})],32)):e.createCommentVNode("",!0),t.showWordLimit&&t.maxlength?(e.openBlock(),e.createElementBlock("div",Mo,e.toDisplayString(d.value)+" / "+e.toDisplayString(t.maxlength),1)):e.createCommentVNode("",!0)],4))}}),Bo=Z(Po,[["__scopeId","data-v-d7d149e3"]]),jo={class:"x-checkboxes"},Vo=["onClick"],No={class:"checkbox-wrapper"},Do=["checked","disabled","onChange"],Ao={class:"checkbox-custom"},To={key:0,class:"check-icon",viewBox:"0 0 24 24"},zo={class:"option-label"},Io=e.defineComponent({__name:"index",props:{options:{},modelValue:{default:()=>[]},placeholder:{default:"请选择选项"},maxSelections:{default:0},disabled:{type:Boolean,default:!1},layout:{default:"vertical"},columns:{default:3}},emits:["update:modelValue","change"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=p=>n.modelValue&&n.modelValue.includes(p),c=p=>{if(n.disabled)return;const v=n.options.find(u=>u.value===p);if(v!=null&&v.disabled)return;const h=[...n.modelValue],x=h.indexOf(p);if(x>-1)h.splice(x,1);else{if(n.maxSelections>0&&h.length>=n.maxSelections)return;h.push(p)}a("update:modelValue",h),a("change",h)},i=p=>{!n.disabled&&!p.disabled&&c(p.value)};return l({clearAll:()=>{n.disabled||(a("update:modelValue",[]),a("change",[]))},selectAll:()=>{if(n.disabled)return;const v=n.options.filter(h=>!h.disabled).map(h=>h.value);n.maxSelections>0?(a("update:modelValue",v.slice(0,n.maxSelections)),a("change",v.slice(0,n.maxSelections))):(a("update:modelValue",v),a("change",v))},removeOption:p=>{c(p)}}),(p,v)=>(e.openBlock(),e.createElementBlock("div",jo,[e.createElementVNode("div",{class:e.normalizeClass(["options-container",[`options-container--${t.layout}`,{"options-container--disabled":t.disabled}]]),style:e.normalizeStyle(t.layout==="grid"?{gridTemplateColumns:`repeat(${t.columns}, 1fr)`}:{})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,h=>(e.openBlock(),e.createElementBlock("div",{key:h.value,class:e.normalizeClass(["option-item",{"option-selected":s(h.value),"option-disabled":t.disabled||h.disabled}]),onClick:x=>i(h)},[e.createElementVNode("div",No,[e.createElementVNode("input",{type:"checkbox",checked:s(h.value),disabled:t.disabled||h.disabled,onChange:e.withModifiers(x=>c(h.value),["stop"]),class:"checkbox-input"},null,40,Do),e.createElementVNode("div",Ao,[s(h.value)?(e.openBlock(),e.createElementBlock("svg",To,[...v[0]||(v[0]=[e.createElementVNode("path",{d:"M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"},null,-1)])])):e.createCommentVNode("",!0)])]),e.createElementVNode("span",zo,e.toDisplayString(h.label),1)],10,Vo))),128))],6)]))}}),Oo=Z(Io,[["__scopeId","data-v-05984fcf"]]),Lo=["onClick","disabled","aria-expanded","aria-controls"],Yo={class:"accordion-title"},_o={class:"accordion-icon"},Xo=["id"],Fo={class:"accordion-body"},Ho=e.defineComponent({__name:"index",props:{items:{},allowMultiple:{type:Boolean,default:!1},defaultOpen:{default:()=>[]},bordered:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1}},emits:["change","item-click"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(new Set(n.defaultOpen)),c=e.ref({}),i=e.ref({}),r=(u,f)=>{u&&(i.value[f]=u,e.nextTick(()=>{const y=u.querySelector(".accordion-body");y&&(c.value[f]=y.scrollHeight)}))},d=u=>{var y;if(n.disabled||(y=n.items[u])!=null&&y.disabled)return;const f=s.value.has(u);n.allowMultiple?f?s.value.delete(u):s.value.add(u):f?s.value.clear():(s.value.clear(),s.value.add(u)),a("item-click",u,!f),a("change",Array.from(s.value))},g=u=>s.value.has(u);return e.watch(()=>n.defaultOpen,u=>{s.value=new Set(u)},{deep:!0}),e.watch(()=>n.items,()=>{e.nextTick(()=>{Object.keys(i.value).forEach(u=>{const f=parseInt(u),y=i.value[f];if(y){const k=y.querySelector(".accordion-body");k&&(c.value[f]=k.scrollHeight)}})})},{deep:!0}),l({openItem:u=>{var f;!n.disabled&&!((f=n.items[u])!=null&&f.disabled)&&(s.value.has(u)||(n.allowMultiple||s.value.clear(),s.value.add(u),a("change",Array.from(s.value))))},closeItem:u=>{s.value.has(u)&&(s.value.delete(u),a("change",Array.from(s.value)))},openAll:()=>{n.allowMultiple&&!n.disabled&&(n.items.forEach((u,f)=>{u.disabled||s.value.add(f)}),a("change",Array.from(s.value)))},closeAll:()=>{s.value.clear(),a("change",[])},toggle:d}),(u,f)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["accordion-container",{"accordion-container--bordered":t.bordered}])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(y,k)=>(e.openBlock(),e.createElementBlock("div",{key:y.id||k,class:e.normalizeClass(["accordion-item",{"is-open":g(k),"is-disabled":t.disabled||y.disabled}])},[e.createElementVNode("button",{onClick:w=>d(k),class:"accordion-header",disabled:t.disabled||y.disabled,"aria-expanded":g(k),"aria-controls":`accordion-content-${k}`},[e.createElementVNode("span",Yo,e.toDisplayString(y.title),1),e.createElementVNode("div",_o,[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["accordion-arrow",{"accordion-arrow--rotate":g(k)}]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",strokeWidth:"2"},[...f[0]||(f[0]=[e.createElementVNode("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19 9l-7 7-7-7"},null,-1)])],2))])],8,Lo),e.createElementVNode("div",{id:`accordion-content-${k}`,class:"accordion-content",style:e.normalizeStyle({maxHeight:g(k)?`${c.value[k]}px`:"0px"}),ref_for:!0,ref:w=>r(w,k)},[e.createElementVNode("div",Fo,e.toDisplayString(y.content),1)],12,Xo)],2))),128))],2))}}),Wo=Z(Ho,[["__scopeId","data-v-c5fef037"]]),Ro={class:"thumbnail-container-wrapper relative"},Go=["onMouseenter","onClick"],Uo=["src","alt"],Ko={class:"thumbnail-index"},qo=e.defineComponent({__name:"index",props:{images:{default:()=>[]},modelValue:{default:0},autoScroll:{type:Boolean,default:!0},showIndex:{type:Boolean,default:!0}},emits:["update:modelValue","change","hover"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(n.modelValue),c=e.ref(null),i=e.ref([]),r=e.ref(!1),d=e.ref(!1),g=e.ref(0),p=e.ref(!1),v=e.ref(!1),h=()=>{D()},x=(m,E)=>{m&&m instanceof HTMLElement&&(i.value[E]=m)},u=m=>{a("hover",m)},f=()=>{},y=m=>{s.value=m,a("update:modelValue",m),a("change",m),n.autoScroll&&e.nextTick(()=>{S(m),setTimeout(()=>{D()},300)})},k=()=>{if(!c.value)return;const m=c.value,E=m.clientWidth*.8;m.scrollBy({left:-E,behavior:"smooth"})},w=()=>{if(!c.value)return;const m=c.value,E=m.clientWidth*.8;m.scrollBy({left:E,behavior:"smooth"})},S=m=>{if(!c.value||i.value.length===0)return;const E=c.value,b=i.value[m];if(!b)return;const j=2,A=b.offsetWidth+8;let V=0;m>=j&&(V=(m-j)*A);const N=E.scrollWidth-E.clientWidth;V=Math.max(0,Math.min(V,N)),E.scrollTo({left:V,behavior:"smooth"})},D=()=>{if(!c.value)return;const m=c.value,E=m.scrollLeft,b=m.scrollWidth-m.clientWidth;r.value=E>0,d.value=E<b,b>0?g.value=E/b*100:g.value=0;const j=P();p.value=n.images.length>j&&r.value,v.value=n.images.length>j&&d.value},P=()=>{var _;if(!c.value||i.value.length===0)return 4;const E=c.value.clientWidth-32,L=(((_=i.value[0])==null?void 0:_.offsetWidth)||80)+12;return Math.floor(E/L)},B=m=>{m>=0&&m<n.images.length&&y(m)};return e.watch(()=>n.modelValue,m=>{m!==void 0&&m!==s.value&&(s.value=m,n.autoScroll&&e.nextTick(()=>{S(m)}))}),e.watch(()=>n.images,()=>{e.nextTick(()=>{D()})},{deep:!0}),e.onMounted(()=>{e.nextTick(()=>{D()})}),l({setCurrentIndex:B,scrollLeft:k,scrollRight:w,updateScrollState:D}),(m,E)=>(e.openBlock(),e.createElementBlock("div",Ro,[p.value?(e.openBlock(),e.createElementBlock("button",{key:0,onClick:k,class:"scroll-arrow scroll-arrow-left","aria-label":"向左滚动"},[...E[1]||(E[1]=[e.createElementVNode("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"},[e.createElementVNode("path",{d:"M15 18l-6-6 6-6"})],-1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"thumbnailContainer",ref:c,onScroll:h,class:"thumbnail-scroll-container"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.images,(b,j)=>(e.openBlock(),e.createElementBlock("div",{key:j,ref_for:!0,ref:L=>x(L,j),onMouseenter:L=>u(j),onMouseleave:E[0]||(E[0]=L=>f()),onClick:L=>y(j),class:e.normalizeClass(["thumbnail-item",{"thumbnail-item--active":s.value===j,"thumbnail-item--inactive":s.value!==j}])},[e.createElementVNode("img",{src:b,alt:`缩略图 ${j+1}`,class:e.normalizeClass(["thumbnail-image",{"thumbnail-image--active":s.value===j,"thumbnail-image--inactive":s.value!==j}])},null,10,Uo),e.createElementVNode("div",Ko,e.toDisplayString(j+1),1)],42,Go))),128))],544),v.value?(e.openBlock(),e.createElementBlock("button",{key:1,onClick:w,class:"scroll-arrow scroll-arrow-right","aria-label":"向右滚动"},[...E[2]||(E[2]=[e.createElementVNode("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"},[e.createElementVNode("path",{d:"M9 18l6-6-6-6"})],-1)])])):e.createCommentVNode("",!0)]))}}),Zo=Z(qo,[["__scopeId","data-v-809b97a6"]]),Qo=e.defineComponent({__name:"index",props:{width:{default:"100%"},height:{default:"1rem"},shape:{default:"rectangle"},animated:{type:Boolean,default:!0},loading:{type:Boolean,default:!0},class:{default:""},style:{default:()=>({})}},setup(t){const l=t,o=e.computed(()=>typeof l.width=="string"?l.width.includes("%")||l.width.includes("px")||l.width.includes("rem")?"":`w-${l.width}`:""),n=e.computed(()=>typeof l.height=="string"?l.height.includes("%")||l.height.includes("px")||l.height.includes("rem")?"":`h-${l.height}`:""),a=e.computed(()=>{switch(l.shape){case"circle":return"rounded-full";case"rounded":return"rounded-lg";default:return"rounded"}}),s=e.computed(()=>l.class),c=e.computed(()=>{const i={...l.style};return typeof l.width=="string"&&(l.width.includes("%")||l.width.includes("px")||l.width.includes("rem"))?i.width=l.width:typeof l.width=="number"&&(i.width=`${l.width}px`),typeof l.height=="string"&&(l.height.includes("%")||l.height.includes("px")||l.height.includes("rem"))?i.height=l.height:typeof l.height=="number"&&(i.height=`${l.height}px`),i});return(i,r)=>t.loading?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["bg-gray-200",[o.value,n.value,a.value,s.value,{"animate-pulse":t.animated}]]),style:e.normalizeStyle(c.value)},null,6)):e.renderSlot(i.$slots,"default",{key:1},void 0,!0)}}),Jo=Z(Qo,[["__scopeId","data-v-db4a4465"]]),ea={key:0,class:"modal-header"},ta={class:"modal-title"},na={class:"modal-body"},oa={key:1,class:"modal-footer"},aa={key:0,class:"loading-spinner"},la=e.defineComponent({__name:"index",props:{visible:{type:Boolean,default:!1},title:{default:"提示"},width:{},size:{default:"medium"},fullscreen:{type:Boolean,default:!1},showHeader:{type:Boolean,default:!0},showFooter:{type:Boolean,default:!0},showClose:{type:Boolean,default:!0},showCancel:{type:Boolean,default:!0},showConfirm:{type:Boolean,default:!0},cancelText:{default:"取消"},confirmText:{default:"确定"},confirmLoading:{type:Boolean,default:!1},maskClosable:{type:Boolean,default:!0},escClosable:{type:Boolean,default:!0}},emits:["update:visible","close","cancel","confirm","opened","closed"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=()=>{a("update:visible",!1),a("close")},c=()=>{a("cancel"),a("update:visible",!1)},i=()=>{a("confirm")},r=()=>{n.maskClosable&&s()},d=g=>{g.key==="Escape"&&n.escClosable&&n.visible&&s()};return e.watch(()=>n.visible,g=>{g?(document.addEventListener("keydown",d),document.body.style.overflow="hidden",a("opened")):(document.removeEventListener("keydown",d),document.body.style.overflow="",a("closed"))}),l({close:s}),(g,p)=>{const v=e.resolveComponent("XButton");return e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{"enter-active-class":"transition-opacity duration-300","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition-opacity duration-300","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:e.withCtx(()=>[t.visible?(e.openBlock(),e.createElementBlock("div",{key:0,class:"modal-mask",onClick:r},[e.createVNode(e.Transition,{"enter-active-class":"transition-all duration-300","enter-from-class":"opacity-0 scale-95","enter-to-class":"opacity-100 scale-100","leave-active-class":"transition-all duration-300","leave-from-class":"opacity-100 scale-100","leave-to-class":"opacity-0 scale-95"},{default:e.withCtx(()=>[t.visible?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["modal-container",[`modal-container--${t.size}`,{"modal-container--fullscreen":t.fullscreen}]]),style:e.normalizeStyle({width:t.width}),onClick:p[0]||(p[0]=e.withModifiers(()=>{},["stop"]))},[t.showHeader?(e.openBlock(),e.createElementBlock("div",ea,[e.renderSlot(g.$slots,"header",{},()=>[e.createElementVNode("h3",ta,e.toDisplayString(t.title),1)],!0),t.showClose?(e.openBlock(),e.createBlock(v,{key:0,size:"small",class:"modal-close",icon:"mdi:close",onClick:s,"aria-label":"关闭"},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:close"})]),_:1})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",na,[e.renderSlot(g.$slots,"default",{},void 0,!0)]),t.showFooter?(e.openBlock(),e.createElementBlock("div",oa,[e.renderSlot(g.$slots,"footer",{},()=>[t.showCancel?(e.openBlock(),e.createBlock(v,{key:0,size:"small",ghost:"",type:"danger",onClick:c},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.cancelText),1)]),_:1})):e.createCommentVNode("",!0),t.showConfirm?(e.openBlock(),e.createBlock(v,{key:1,size:"small",ghost:"",type:"primary",onClick:i,disabled:t.confirmLoading},{default:e.withCtx(()=>[t.confirmLoading?(e.openBlock(),e.createElementBlock("span",aa)):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(t.confirmText),1)]),_:1},8,["disabled"])):e.createCommentVNode("",!0)],!0)])):e.createCommentVNode("",!0)],6)):e.createCommentVNode("",!0)]),_:3})])):e.createCommentVNode("",!0)]),_:3})])}}}),sa=Z(la,[["__scopeId","data-v-6b874658"]]),ca={class:"x-tooltip-trigger"},ia={class:"tooltip-label"},ra={class:"tooltip-text"},da={class:"tooltip-hover-text"},ga=e.defineComponent({__name:"index",props:{content:{},placement:{default:"top"},variant:{default:"basic"},label:{default:"Hover"},hoverText:{default:""}},setup(t){return(l,o)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([t.variant==="basic"?"x-tooltip-wrapper":"x-tooltip-rich-wrapper",t.variant==="rich"&&`rich-${t.placement}`])},[t.variant==="basic"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",ca,[e.renderSlot(l.$slots,"default",{},void 0,!0)]),e.createElementVNode("div",{class:e.normalizeClass(["x-tooltip",`tooltip-${t.placement}`])},[e.createTextVNode(e.toDisplayString(t.content)+" ",1),e.createElementVNode("div",{class:e.normalizeClass(["tooltip-arrow",`arrow-${t.placement}`])},null,2)],2)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("span",ia,e.toDisplayString(t.label),1),e.createElementVNode("span",ra,e.toDisplayString(t.content),1),e.createElementVNode("span",da,e.toDisplayString(t.hoverText||t.label),1)],64))],2))}}),fa=Z(ga,[["__scopeId","data-v-6d3b782b"]]),ua={class:"rating"},ma=["title","onClick"],ha=["name","value","disabled","checked"],pa={key:0,class:"score-text"},va={key:1,class:"score-value"},ya=e.defineComponent({__name:"index",props:{modelValue:{default:0},maxStars:{default:5},size:{default:"medium"},disabled:{type:Boolean,default:!1},showText:{type:Boolean,default:!1},showValue:{type:Boolean,default:!1},texts:{default:()=>["极差","差","一般","好","极好"]},allowHalf:{type:Boolean,default:!1},color:{default:"#ffc73a"}},emits:["update:modelValue","change"],setup(t,{emit:l}){e.useCssVars(r=>({v45ed3bbe:r.color}));const o=t,n=l,a=e.computed(()=>Math.random().toString(36).substr(2,9)),s=r=>{o.disabled||(n("update:modelValue",r),n("change",r))},c=r=>o.texts&&o.texts[r-1]?`${r}星 - ${o.texts[r-1]}`:`${r}星`,i=()=>o.modelValue===0?"未评分":o.texts&&o.texts[o.modelValue-1]?o.texts[o.modelValue-1]:`${o.modelValue}星`;return(r,d)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["x-score",[`score-${t.size}`,{"score-disabled":t.disabled}]])},[e.createElementVNode("div",ua,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.maxStars,g=>(e.openBlock(),e.createElementBlock("label",{key:g,class:e.normalizeClass({"star-filled":g<=t.modelValue}),title:c(g),onClick:p=>s(g)},[e.createElementVNode("input",{type:"radio",name:`star-radio-${a.value}`,value:g,disabled:t.disabled,checked:t.modelValue===g,style:{display:"none"}},null,8,ha),d[0]||(d[0]=e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[e.createElementVNode("path",{pathLength:"360",d:"M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z"})],-1))],10,ma))),128))]),t.showText?(e.openBlock(),e.createElementBlock("div",pa,e.toDisplayString(i()),1)):e.createCommentVNode("",!0),t.showValue?(e.openBlock(),e.createElementBlock("div",va,e.toDisplayString(t.modelValue)+"/"+e.toDisplayString(t.maxStars),1)):e.createCommentVNode("",!0)],2))}}),wa=Z(ya,[["__scopeId","data-v-3cdb1a2c"]]),ba=["name","value","disabled","checked","onChange"],Ca={key:0,class:"radio-button"},ka={class:"radio-content"},Sa={key:0,class:"radio-icon"},xa={class:"radio-text"},Ea={class:"radio-label"},$a={key:0,class:"radio-description"},Ma={key:1,class:"payment-method-container"},Pa={class:"payment-content"},Ba={class:"payment-icon"},ja={class:"payment-label"},Va=["name","value","disabled","checked","onChange"],Na=e.defineComponent({__name:"index",props:{modelValue:{default:""},options:{default:()=>[]},size:{default:"medium"},disabled:{type:Boolean,default:!1},showIcon:{type:Boolean,default:!1},name:{default:"radio-group"},direction:{default:"vertical"},variant:{default:"standard"},mode:{default:"default"}},emits:["update:modelValue","change"],setup(t,{emit:l}){const o=t,n=l,a=[{value:"google",label:"Google Pay",icon:"logos:google-pay"},{value:"apple",label:"Apple Pay",icon:"logos:apple-pay"},{value:"paypal",label:"Paypal",icon:"logos:paypal"},{value:"visa",label:"Credit Card",icon:"logos:visa"}],s=c=>{o.disabled||(n("update:modelValue",c),n("change",c))};return(c,i)=>t.variant==="standard"?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["x-radio-group",[`radio-${t.size}`,`radio-${t.direction}`,`radio-${t.mode}`,{"radio-disabled":t.disabled}]])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,r=>(e.openBlock(),e.createElementBlock("label",{key:r.value,class:e.normalizeClass(["x-radio-item",[{"radio-item-checked":t.modelValue===r.value},{"radio-item-disabled":t.disabled||r.disabled}]])},[e.createElementVNode("input",{type:"radio",name:t.name,value:r.value,disabled:t.disabled||r.disabled,checked:t.modelValue===r.value,onChange:d=>s(r.value),class:"radio-input"},null,40,ba),t.mode==="default"?(e.openBlock(),e.createElementBlock("div",Ca,[...i[0]||(i[0]=[e.createElementVNode("div",{class:"radio-button-inner"},null,-1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",ka,[r.icon||t.showIcon?(e.openBlock(),e.createElementBlock("div",Sa,[e.renderSlot(c.$slots,"icon",{option:r},()=>[r.icon?(e.openBlock(),e.createBlock(e.unref(K),{key:0,icon:r.icon},null,8,["icon"])):e.createCommentVNode("",!0)],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",xa,[e.createElementVNode("div",Ea,e.toDisplayString(r.label),1),r.description?(e.openBlock(),e.createElementBlock("div",$a,e.toDisplayString(r.description),1)):e.createCommentVNode("",!0)]),e.renderSlot(c.$slots,"content",{option:r},void 0,!0)])],2))),128))],2)):(e.openBlock(),e.createElementBlock("div",Ma,[i[1]||(i[1]=e.createElementVNode("p",{class:"payment-title"},"Payment method",-1)),i[2]||(i[2]=e.createElementVNode("p",{class:"payment-subtitle"},[e.createTextVNode(" This component is made by using "),e.createElementVNode("span",{class:"payment-highlight"},"`:has() pseudo-class`")],-1)),(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(a,r=>e.createElementVNode("label",{key:r.value,class:e.normalizeClass(["payment-option",{"payment-option-checked":t.modelValue===r.value}])},[e.createElementVNode("div",Pa,[e.createElementVNode("div",Ba,[e.createVNode(e.unref(K),{icon:r.icon},null,8,["icon"])]),e.createElementVNode("p",ja,e.toDisplayString(r.label),1)]),e.createElementVNode("input",{type:"radio",name:t.name,value:r.value,disabled:t.disabled,checked:t.modelValue===r.value,onChange:d=>s(r.value),class:"payment-input"},null,40,Va)],2)),64))]))}}),Da=Z(Na,[["__scopeId","data-v-0b609d3b"]]);var J=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ee(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var nt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o=1e3,n=6e4,a=36e5,s="millisecond",c="second",i="minute",r="hour",d="day",g="week",p="month",v="quarter",h="year",x="date",u="Invalid Date",f=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,k={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(A){var V=["th","st","nd","rd"],N=A%100;return"["+A+(V[(N-20)%10]||V[N]||V[0])+"]"}},w=function(A,V,N){var z=String(A);return!z||z.length>=V?A:""+Array(V+1-z.length).join(N)+A},S={s:w,z:function(A){var V=-A.utcOffset(),N=Math.abs(V),z=Math.floor(N/60),C=N%60;return(V<=0?"+":"-")+w(z,2,"0")+":"+w(C,2,"0")},m:function A(V,N){if(V.date()<N.date())return-A(N,V);var z=12*(N.year()-V.year())+(N.month()-V.month()),C=V.clone().add(z,p),$=N-C<0,I=V.clone().add(z+($?-1:1),p);return+(-(z+(N-C)/($?C-I:I-C))||0)},a:function(A){return A<0?Math.ceil(A)||0:Math.floor(A)},p:function(A){return{M:p,y:h,w:g,d,D:x,h:r,m:i,s:c,ms:s,Q:v}[A]||String(A||"").toLowerCase().replace(/s$/,"")},u:function(A){return A===void 0}},D="en",P={};P[D]=k;var B="$isDayjsObject",m=function(A){return A instanceof L||!(!A||!A[B])},E=function A(V,N,z){var C;if(!V)return D;if(typeof V=="string"){var $=V.toLowerCase();P[$]&&(C=$),N&&(P[$]=N,C=$);var I=V.split("-");if(!C&&I.length>1)return A(I[0])}else{var O=V.name;P[O]=V,C=O}return!z&&C&&(D=C),C||!z&&D},b=function(A,V){if(m(A))return A.clone();var N=typeof V=="object"?V:{};return N.date=A,N.args=arguments,new L(N)},j=S;j.l=E,j.i=m,j.w=function(A,V){return b(A,{locale:V.$L,utc:V.$u,x:V.$x,$offset:V.$offset})};var L=function(){function A(N){this.$L=E(N.locale,null,!0),this.parse(N),this.$x=this.$x||N.x||{},this[B]=!0}var V=A.prototype;return V.parse=function(N){this.$d=function(z){var C=z.date,$=z.utc;if(C===null)return new Date(NaN);if(j.u(C))return new Date;if(C instanceof Date)return new Date(C);if(typeof C=="string"&&!/Z$/i.test(C)){var I=C.match(f);if(I){var O=I[2]-1||0,X=(I[7]||"0").substring(0,3);return $?new Date(Date.UTC(I[1],O,I[3]||1,I[4]||0,I[5]||0,I[6]||0,X)):new Date(I[1],O,I[3]||1,I[4]||0,I[5]||0,I[6]||0,X)}}return new Date(C)}(N),this.init()},V.init=function(){var N=this.$d;this.$y=N.getFullYear(),this.$M=N.getMonth(),this.$D=N.getDate(),this.$W=N.getDay(),this.$H=N.getHours(),this.$m=N.getMinutes(),this.$s=N.getSeconds(),this.$ms=N.getMilliseconds()},V.$utils=function(){return j},V.isValid=function(){return this.$d.toString()!==u},V.isSame=function(N,z){var C=b(N);return this.startOf(z)<=C&&C<=this.endOf(z)},V.isAfter=function(N,z){return b(N)<this.startOf(z)},V.isBefore=function(N,z){return this.endOf(z)<b(N)},V.$g=function(N,z,C){return j.u(N)?this[z]:this.set(C,N)},V.unix=function(){return Math.floor(this.valueOf()/1e3)},V.valueOf=function(){return this.$d.getTime()},V.startOf=function(N,z){var C=this,$=!!j.u(z)||z,I=j.p(N),O=function(G,R){var q=j.w(C.$u?Date.UTC(C.$y,R,G):new Date(C.$y,R,G),C);return $?q:q.endOf(d)},X=function(G,R){return j.w(C.toDate()[G].apply(C.toDate("s"),($?[0,0,0,0]:[23,59,59,999]).slice(R)),C)},H=this.$W,M=this.$M,T=this.$D,Y="set"+(this.$u?"UTC":"");switch(I){case h:return $?O(1,0):O(31,11);case p:return $?O(1,M):O(0,M+1);case g:var W=this.$locale().weekStart||0,U=(H<W?H+7:H)-W;return O($?T-U:T+(6-U),M);case d:case x:return X(Y+"Hours",0);case r:return X(Y+"Minutes",1);case i:return X(Y+"Seconds",2);case c:return X(Y+"Milliseconds",3);default:return this.clone()}},V.endOf=function(N){return this.startOf(N,!1)},V.$set=function(N,z){var C,$=j.p(N),I="set"+(this.$u?"UTC":""),O=(C={},C[d]=I+"Date",C[x]=I+"Date",C[p]=I+"Month",C[h]=I+"FullYear",C[r]=I+"Hours",C[i]=I+"Minutes",C[c]=I+"Seconds",C[s]=I+"Milliseconds",C)[$],X=$===d?this.$D+(z-this.$W):z;if($===p||$===h){var H=this.clone().set(x,1);H.$d[O](X),H.init(),this.$d=H.set(x,Math.min(this.$D,H.daysInMonth())).$d}else O&&this.$d[O](X);return this.init(),this},V.set=function(N,z){return this.clone().$set(N,z)},V.get=function(N){return this[j.p(N)]()},V.add=function(N,z){var C,$=this;N=Number(N);var I=j.p(z),O=function(M){var T=b($);return j.w(T.date(T.date()+Math.round(M*N)),$)};if(I===p)return this.set(p,this.$M+N);if(I===h)return this.set(h,this.$y+N);if(I===d)return O(1);if(I===g)return O(7);var X=(C={},C[i]=n,C[r]=a,C[c]=o,C)[I]||1,H=this.$d.getTime()+N*X;return j.w(H,this)},V.subtract=function(N,z){return this.add(-1*N,z)},V.format=function(N){var z=this,C=this.$locale();if(!this.isValid())return C.invalidDate||u;var $=N||"YYYY-MM-DDTHH:mm:ssZ",I=j.z(this),O=this.$H,X=this.$m,H=this.$M,M=C.weekdays,T=C.months,Y=C.meridiem,W=function(R,q,Q,te){return R&&(R[q]||R(z,$))||Q[q].slice(0,te)},U=function(R){return j.s(O%12||12,R,"0")},G=Y||function(R,q,Q){var te=R<12?"AM":"PM";return Q?te.toLowerCase():te};return $.replace(y,function(R,q){return q||function(Q){switch(Q){case"YY":return String(z.$y).slice(-2);case"YYYY":return j.s(z.$y,4,"0");case"M":return H+1;case"MM":return j.s(H+1,2,"0");case"MMM":return W(C.monthsShort,H,T,3);case"MMMM":return W(T,H);case"D":return z.$D;case"DD":return j.s(z.$D,2,"0");case"d":return String(z.$W);case"dd":return W(C.weekdaysMin,z.$W,M,2);case"ddd":return W(C.weekdaysShort,z.$W,M,3);case"dddd":return M[z.$W];case"H":return String(O);case"HH":return j.s(O,2,"0");case"h":return U(1);case"hh":return U(2);case"a":return G(O,X,!0);case"A":return G(O,X,!1);case"m":return String(X);case"mm":return j.s(X,2,"0");case"s":return String(z.$s);case"ss":return j.s(z.$s,2,"0");case"SSS":return j.s(z.$ms,3,"0");case"Z":return I}return null}(R)||I.replace(":","")})},V.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},V.diff=function(N,z,C){var $,I=this,O=j.p(z),X=b(N),H=(X.utcOffset()-this.utcOffset())*n,M=this-X,T=function(){return j.m(I,X)};switch(O){case h:$=T()/12;break;case p:$=T();break;case v:$=T()/3;break;case g:$=(M-H)/6048e5;break;case d:$=(M-H)/864e5;break;case r:$=M/a;break;case i:$=M/n;break;case c:$=M/o;break;default:$=M}return C?$:j.a($)},V.daysInMonth=function(){return this.endOf(p).$D},V.$locale=function(){return P[this.$L]},V.locale=function(N,z){if(!N)return this.$L;var C=this.clone(),$=E(N,z,!0);return $&&(C.$L=$),C},V.clone=function(){return j.w(this.$d,this)},V.toDate=function(){return new Date(this.valueOf())},V.toJSON=function(){return this.isValid()?this.toISOString():null},V.toISOString=function(){return this.$d.toISOString()},V.toString=function(){return this.$d.toUTCString()},A}(),_=L.prototype;return b.prototype=_,[["$ms",s],["$s",c],["$m",i],["$H",r],["$W",d],["$M",p],["$y",h],["$D",x]].forEach(function(A){_[A[1]]=function(V){return this.$g(V,A[0],A[1])}}),b.extend=function(A,V){return A.$i||(A(V,L,b),A.$i=!0),b},b.locale=E,b.isDayjs=m,b.unix=function(A){return b(1e3*A)},b.en=P[D],b.Ls=P,b.p={},b})})(nt);var ot=nt.exports;const F=ee(ot);var at={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o="minute",n=/[+-]\d\d(?::?\d\d)?/g,a=/([+-]|\d\d)/g;return function(s,c,i){var r=c.prototype;i.utc=function(u){var f={date:u,utc:!0,args:arguments};return new c(f)},r.utc=function(u){var f=i(this.toDate(),{locale:this.$L,utc:!0});return u?f.add(this.utcOffset(),o):f},r.local=function(){return i(this.toDate(),{locale:this.$L,utc:!1})};var d=r.parse;r.parse=function(u){u.utc&&(this.$u=!0),this.$utils().u(u.$offset)||(this.$offset=u.$offset),d.call(this,u)};var g=r.init;r.init=function(){if(this.$u){var u=this.$d;this.$y=u.getUTCFullYear(),this.$M=u.getUTCMonth(),this.$D=u.getUTCDate(),this.$W=u.getUTCDay(),this.$H=u.getUTCHours(),this.$m=u.getUTCMinutes(),this.$s=u.getUTCSeconds(),this.$ms=u.getUTCMilliseconds()}else g.call(this)};var p=r.utcOffset;r.utcOffset=function(u,f){var y=this.$utils().u;if(y(u))return this.$u?0:y(this.$offset)?p.call(this):this.$offset;if(typeof u=="string"&&(u=function(D){D===void 0&&(D="");var P=D.match(n);if(!P)return null;var B=(""+P[0]).match(a)||["-",0,0],m=B[0],E=60*+B[1]+ +B[2];return E===0?0:m==="+"?E:-E}(u),u===null))return this;var k=Math.abs(u)<=16?60*u:u;if(k===0)return this.utc(f);var w=this.clone();if(f)return w.$offset=k,w.$u=!1,w;var S=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return(w=this.local().add(k+S,o)).$offset=k,w.$x.$localOffset=S,w};var v=r.format;r.format=function(u){var f=u||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return v.call(this,f)},r.valueOf=function(){var u=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*u},r.isUTC=function(){return!!this.$u},r.toISOString=function(){return this.toDate().toISOString()},r.toString=function(){return this.toDate().toUTCString()};var h=r.toDate;r.toDate=function(u){return u==="s"&&this.$offset?i(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():h.call(this)};var x=r.diff;r.diff=function(u,f,y){if(u&&this.$u===u.$u)return x.call(this,u,f,y);var k=this.local(),w=i(u).local();return x.call(k,w,f,y)}}})})(at);var Aa=at.exports;const Ta=ee(Aa);var lt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o={year:0,month:1,day:2,hour:3,minute:4,second:5},n={};return function(a,s,c){var i,r=function(v,h,x){x===void 0&&(x={});var u=new Date(v),f=function(y,k){k===void 0&&(k={});var w=k.timeZoneName||"short",S=y+"|"+w,D=n[S];return D||(D=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:y,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:w}),n[S]=D),D}(h,x);return f.formatToParts(u)},d=function(v,h){for(var x=r(v,h),u=[],f=0;f<x.length;f+=1){var y=x[f],k=y.type,w=y.value,S=o[k];S>=0&&(u[S]=parseInt(w,10))}var D=u[3],P=D===24?0:D,B=u[0]+"-"+u[1]+"-"+u[2]+" "+P+":"+u[4]+":"+u[5]+":000",m=+v;return(c.utc(B).valueOf()-(m-=m%1e3))/6e4},g=s.prototype;g.tz=function(v,h){v===void 0&&(v=i);var x,u=this.utcOffset(),f=this.toDate(),y=f.toLocaleString("en-US",{timeZone:v}),k=Math.round((f-new Date(y))/1e3/60),w=15*-Math.round(f.getTimezoneOffset()/15)-k;if(!Number(w))x=this.utcOffset(0,h);else if(x=c(y,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(w,!0),h){var S=x.utcOffset();x=x.add(u-S,"minute")}return x.$x.$timezone=v,x},g.offsetName=function(v){var h=this.$x.$timezone||c.tz.guess(),x=r(this.valueOf(),h,{timeZoneName:v}).find(function(u){return u.type.toLowerCase()==="timezonename"});return x&&x.value};var p=g.startOf;g.startOf=function(v,h){if(!this.$x||!this.$x.$timezone)return p.call(this,v,h);var x=c(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return p.call(x,v,h).tz(this.$x.$timezone,!0)},c.tz=function(v,h,x){var u=x&&h,f=x||h||i,y=d(+c(),f);if(typeof v!="string")return c(v).tz(f);var k=function(P,B,m){var E=P-60*B*1e3,b=d(E,m);if(B===b)return[E,B];var j=d(E-=60*(b-B)*1e3,m);return b===j?[E,b]:[P-60*Math.min(b,j)*1e3,Math.max(b,j)]}(c.utc(v,u).valueOf(),y,f),w=k[0],S=k[1],D=c(w).utcOffset(S);return D.$x.$timezone=f,D},c.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},c.tz.setDefault=function(v){i=v}}})})(lt);var za=lt.exports;const Ia=ee(za);var st={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n,a){o=o||{};var s=n.prototype,c={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function i(d,g,p,v){return s.fromToBase(d,g,p,v)}a.en.relativeTime=c,s.fromToBase=function(d,g,p,v,h){for(var x,u,f,y=p.$locale().relativeTime||c,k=o.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],w=k.length,S=0;S<w;S+=1){var D=k[S];D.d&&(x=v?a(d).diff(p,D.d,!0):p.diff(d,D.d,!0));var P=(o.rounding||Math.round)(Math.abs(x));if(f=x>0,P<=D.r||!D.r){P<=1&&S>0&&(D=k[S-1]);var B=y[D.l];h&&(P=h(""+P)),u=typeof B=="string"?B.replace("%d",P):B(P,g,D.l,f);break}}if(g)return u;var m=f?y.future:y.past;return typeof m=="function"?m(u):m.replace("%s",u)},s.to=function(d,g){return i(d,g,this,!0)},s.from=function(d,g){return i(d,g,this)};var r=function(d){return d.$u?a.utc():a()};s.toNow=function(d){return this.to(r(this),d)},s.fromNow=function(d){return this.from(r(this),d)}}})})(st);var Oa=st.exports;const La=ee(Oa);var ct={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o,n,a=1e3,s=6e4,c=36e5,i=864e5,r=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,d=31536e6,g=2628e6,p=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,v={years:d,months:g,days:i,hours:c,minutes:s,seconds:a,milliseconds:1,weeks:6048e5},h=function(P){return P instanceof S},x=function(P,B,m){return new S(P,m,B.$l)},u=function(P){return n.p(P)+"s"},f=function(P){return P<0},y=function(P){return f(P)?Math.ceil(P):Math.floor(P)},k=function(P){return Math.abs(P)},w=function(P,B){return P?f(P)?{negative:!0,format:""+k(P)+B}:{negative:!1,format:""+P+B}:{negative:!1,format:""}},S=function(){function P(m,E,b){var j=this;if(this.$d={},this.$l=b,m===void 0&&(this.$ms=0,this.parseFromMilliseconds()),E)return x(m*v[u(E)],this);if(typeof m=="number")return this.$ms=m,this.parseFromMilliseconds(),this;if(typeof m=="object")return Object.keys(m).forEach(function(A){j.$d[u(A)]=m[A]}),this.calMilliseconds(),this;if(typeof m=="string"){var L=m.match(p);if(L){var _=L.slice(2).map(function(A){return A!=null?Number(A):0});return this.$d.years=_[0],this.$d.months=_[1],this.$d.weeks=_[2],this.$d.days=_[3],this.$d.hours=_[4],this.$d.minutes=_[5],this.$d.seconds=_[6],this.calMilliseconds(),this}}return this}var B=P.prototype;return B.calMilliseconds=function(){var m=this;this.$ms=Object.keys(this.$d).reduce(function(E,b){return E+(m.$d[b]||0)*v[b]},0)},B.parseFromMilliseconds=function(){var m=this.$ms;this.$d.years=y(m/d),m%=d,this.$d.months=y(m/g),m%=g,this.$d.days=y(m/i),m%=i,this.$d.hours=y(m/c),m%=c,this.$d.minutes=y(m/s),m%=s,this.$d.seconds=y(m/a),m%=a,this.$d.milliseconds=m},B.toISOString=function(){var m=w(this.$d.years,"Y"),E=w(this.$d.months,"M"),b=+this.$d.days||0;this.$d.weeks&&(b+=7*this.$d.weeks);var j=w(b,"D"),L=w(this.$d.hours,"H"),_=w(this.$d.minutes,"M"),A=this.$d.seconds||0;this.$d.milliseconds&&(A+=this.$d.milliseconds/1e3,A=Math.round(1e3*A)/1e3);var V=w(A,"S"),N=m.negative||E.negative||j.negative||L.negative||_.negative||V.negative,z=L.format||_.format||V.format?"T":"",C=(N?"-":"")+"P"+m.format+E.format+j.format+z+L.format+_.format+V.format;return C==="P"||C==="-P"?"P0D":C},B.toJSON=function(){return this.toISOString()},B.format=function(m){var E=m||"YYYY-MM-DDTHH:mm:ss",b={Y:this.$d.years,YY:n.s(this.$d.years,2,"0"),YYYY:n.s(this.$d.years,4,"0"),M:this.$d.months,MM:n.s(this.$d.months,2,"0"),D:this.$d.days,DD:n.s(this.$d.days,2,"0"),H:this.$d.hours,HH:n.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:n.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:n.s(this.$d.seconds,2,"0"),SSS:n.s(this.$d.milliseconds,3,"0")};return E.replace(r,function(j,L){return L||String(b[j])})},B.as=function(m){return this.$ms/v[u(m)]},B.get=function(m){var E=this.$ms,b=u(m);return b==="milliseconds"?E%=1e3:E=b==="weeks"?y(E/v[b]):this.$d[b],E||0},B.add=function(m,E,b){var j;return j=E?m*v[u(E)]:h(m)?m.$ms:x(m,this).$ms,x(this.$ms+j*(b?-1:1),this)},B.subtract=function(m,E){return this.add(m,E,!0)},B.locale=function(m){var E=this.clone();return E.$l=m,E},B.clone=function(){return x(this.$ms,this)},B.humanize=function(m){return o().add(this.$ms,"ms").locale(this.$l).fromNow(!m)},B.valueOf=function(){return this.asMilliseconds()},B.milliseconds=function(){return this.get("milliseconds")},B.asMilliseconds=function(){return this.as("milliseconds")},B.seconds=function(){return this.get("seconds")},B.asSeconds=function(){return this.as("seconds")},B.minutes=function(){return this.get("minutes")},B.asMinutes=function(){return this.as("minutes")},B.hours=function(){return this.get("hours")},B.asHours=function(){return this.as("hours")},B.days=function(){return this.get("days")},B.asDays=function(){return this.as("days")},B.weeks=function(){return this.get("weeks")},B.asWeeks=function(){return this.as("weeks")},B.months=function(){return this.get("months")},B.asMonths=function(){return this.as("months")},B.years=function(){return this.get("years")},B.asYears=function(){return this.as("years")},P}(),D=function(P,B,m){return P.add(B.years()*m,"y").add(B.months()*m,"M").add(B.days()*m,"d").add(B.hours()*m,"h").add(B.minutes()*m,"m").add(B.seconds()*m,"s").add(B.milliseconds()*m,"ms")};return function(P,B,m){o=m,n=m().$utils(),m.duration=function(j,L){var _=m.locale();return x(j,{$l:_},L)},m.isDuration=h;var E=B.prototype.add,b=B.prototype.subtract;B.prototype.add=function(j,L){return h(j)?D(this,j,1):E.bind(this)(j,L)},B.prototype.subtract=function(j,L){return h(j)?D(this,j,-1):b.bind(this)(j,L)}}})})(ct);var Ya=ct.exports;const _a=ee(Ya);var it={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n){n.prototype.isSameOrAfter=function(a,s){return this.isSame(a,s)||this.isAfter(a,s)}}})})(it);var Xa=it.exports;const Fa=ee(Xa);var rt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n){n.prototype.isSameOrBefore=function(a,s){return this.isSame(a,s)||this.isBefore(a,s)}}})})(rt);var Ha=rt.exports;const Wa=ee(Ha);var dt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n,a){n.prototype.isBetween=function(s,c,i,r){var d=a(s),g=a(c),p=(r=r||"()")[0]==="(",v=r[1]===")";return(p?this.isAfter(d,i):!this.isBefore(d,i))&&(v?this.isBefore(g,i):!this.isAfter(g,i))||(p?this.isBefore(d,i):!this.isAfter(d,i))&&(v?this.isAfter(g,i):!this.isBefore(g,i))}}})})(dt);var Ra=dt.exports;const Ga=ee(Ra);var gt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o="week",n="year";return function(a,s,c){var i=s.prototype;i.week=function(r){if(r===void 0&&(r=null),r!==null)return this.add(7*(r-this.week()),"day");var d=this.$locale().yearStart||1;if(this.month()===11&&this.date()>25){var g=c(this).startOf(n).add(1,n).date(d),p=c(this).endOf(o);if(g.isBefore(p))return 1}var v=c(this).startOf(n).date(d).startOf(o).subtract(1,"millisecond"),h=this.diff(v,o,!0);return h<0?c(this).startOf("week").week():Math.ceil(h)},i.weeks=function(r){return r===void 0&&(r=null),this.week(r)}}})})(gt);var Ua=gt.exports;const Ka=ee(Ua);var ft={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o="day";return function(n,a,s){var c=function(d){return d.add(4-d.isoWeekday(),o)},i=a.prototype;i.isoWeekYear=function(){return c(this).year()},i.isoWeek=function(d){if(!this.$utils().u(d))return this.add(7*(d-this.isoWeek()),o);var g,p,v,h,x=c(this),u=(g=this.isoWeekYear(),p=this.$u,v=(p?s.utc:s)().year(g).startOf("year"),h=4-v.isoWeekday(),v.isoWeekday()>4&&(h+=7),v.add(h,o));return x.diff(u,"week")+1},i.isoWeekday=function(d){return this.$utils().u(d)?this.day()||7:this.day(this.day()%7?d:d-7)};var r=i.startOf;i.startOf=function(d,g){var p=this.$utils(),v=!!p.u(g)||g;return p.p(d)==="isoweek"?v?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):r.bind(this)(d,g)}}})})(ft);var qa=ft.exports;const Za=ee(qa);var ut={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},n=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,a=/\d/,s=/\d\d/,c=/\d\d?/,i=/\d*[^-_:/,()\s\d]+/,r={},d=function(f){return(f=+f)+(f>68?1900:2e3)},g=function(f){return function(y){this[f]=+y}},p=[/[+-]\d\d:?(\d\d)?|Z/,function(f){(this.zone||(this.zone={})).offset=function(y){if(!y||y==="Z")return 0;var k=y.match(/([+-]|\d\d)/g),w=60*k[1]+(+k[2]||0);return w===0?0:k[0]==="+"?-w:w}(f)}],v=function(f){var y=r[f];return y&&(y.indexOf?y:y.s.concat(y.f))},h=function(f,y){var k,w=r.meridiem;if(w){for(var S=1;S<=24;S+=1)if(f.indexOf(w(S,0,y))>-1){k=S>12;break}}else k=f===(y?"pm":"PM");return k},x={A:[i,function(f){this.afternoon=h(f,!1)}],a:[i,function(f){this.afternoon=h(f,!0)}],Q:[a,function(f){this.month=3*(f-1)+1}],S:[a,function(f){this.milliseconds=100*+f}],SS:[s,function(f){this.milliseconds=10*+f}],SSS:[/\d{3}/,function(f){this.milliseconds=+f}],s:[c,g("seconds")],ss:[c,g("seconds")],m:[c,g("minutes")],mm:[c,g("minutes")],H:[c,g("hours")],h:[c,g("hours")],HH:[c,g("hours")],hh:[c,g("hours")],D:[c,g("day")],DD:[s,g("day")],Do:[i,function(f){var y=r.ordinal,k=f.match(/\d+/);if(this.day=k[0],y)for(var w=1;w<=31;w+=1)y(w).replace(/\[|\]/g,"")===f&&(this.day=w)}],w:[c,g("week")],ww:[s,g("week")],M:[c,g("month")],MM:[s,g("month")],MMM:[i,function(f){var y=v("months"),k=(v("monthsShort")||y.map(function(w){return w.slice(0,3)})).indexOf(f)+1;if(k<1)throw new Error;this.month=k%12||k}],MMMM:[i,function(f){var y=v("months").indexOf(f)+1;if(y<1)throw new Error;this.month=y%12||y}],Y:[/[+-]?\d+/,g("year")],YY:[s,function(f){this.year=d(f)}],YYYY:[/\d{4}/,g("year")],Z:p,ZZ:p};function u(f){var y,k;y=f,k=r&&r.formats;for(var w=(f=y.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(b,j,L){var _=L&&L.toUpperCase();return j||k[L]||o[L]||k[_].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(A,V,N){return V||N.slice(1)})})).match(n),S=w.length,D=0;D<S;D+=1){var P=w[D],B=x[P],m=B&&B[0],E=B&&B[1];w[D]=E?{regex:m,parser:E}:P.replace(/^\[|\]$/g,"")}return function(b){for(var j={},L=0,_=0;L<S;L+=1){var A=w[L];if(typeof A=="string")_+=A.length;else{var V=A.regex,N=A.parser,z=b.slice(_),C=V.exec(z)[0];N.call(j,C),b=b.replace(C,"")}}return function($){var I=$.afternoon;if(I!==void 0){var O=$.hours;I?O<12&&($.hours+=12):O===12&&($.hours=0),delete $.afternoon}}(j),j}}return function(f,y,k){k.p.customParseFormat=!0,f&&f.parseTwoDigitYear&&(d=f.parseTwoDigitYear);var w=y.prototype,S=w.parse;w.parse=function(D){var P=D.date,B=D.utc,m=D.args;this.$u=B;var E=m[1];if(typeof E=="string"){var b=m[2]===!0,j=m[3]===!0,L=b||j,_=m[2];j&&(_=m[2]),r=this.$locale(),!b&&_&&(r=k.Ls[_]),this.$d=function(z,C,$,I){try{if(["x","X"].indexOf(C)>-1)return new Date((C==="X"?1e3:1)*z);var O=u(C)(z),X=O.year,H=O.month,M=O.day,T=O.hours,Y=O.minutes,W=O.seconds,U=O.milliseconds,G=O.zone,R=O.week,q=new Date,Q=M||(X||H?1:q.getDate()),te=X||q.getFullYear(),ne=0;X&&!H||(ne=H>0?H-1:q.getMonth());var oe,le=T||0,re=Y||0,se=W||0,ce=U||0;return G?new Date(Date.UTC(te,ne,Q,le,re,se,ce+60*G.offset*1e3)):$?new Date(Date.UTC(te,ne,Q,le,re,se,ce)):(oe=new Date(te,ne,Q,le,re,se,ce),R&&(oe=I(oe).week(R).toDate()),oe)}catch{return new Date("")}}(P,E,B,k),this.init(),_&&_!==!0&&(this.$L=this.locale(_).$L),L&&P!=this.format(E)&&(this.$d=new Date("")),r={}}else if(E instanceof Array)for(var A=E.length,V=1;V<=A;V+=1){m[1]=E[V-1];var N=k.apply(this,m);if(N.isValid()){this.$d=N.$d,this.$L=N.$L,this.init();break}V===A&&(this.$d=new Date(""))}else S.call(this,D)}}})})(ut);var Qa=ut.exports;const Ja=ee(Qa);var mt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n){var a=n.prototype,s=a.format;a.format=function(c){var i=this,r=this.$locale();if(!this.isValid())return s.bind(this)(c);var d=this.$utils(),g=(c||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,function(p){switch(p){case"Q":return Math.ceil((i.$M+1)/3);case"Do":return r.ordinal(i.$D);case"gggg":return i.weekYear();case"GGGG":return i.isoWeekYear();case"wo":return r.ordinal(i.week(),"W");case"w":case"ww":return d.s(i.week(),p==="w"?1:2,"0");case"W":case"WW":return d.s(i.isoWeek(),p==="W"?1:2,"0");case"k":case"kk":return d.s(String(i.$H===0?24:i.$H),p==="k"?1:2,"0");case"X":return Math.floor(i.$d.getTime()/1e3);case"x":return i.$d.getTime();case"z":return"["+i.offsetName()+"]";case"zzz":return"["+i.offsetName("long")+"]";default:return p}});return s.bind(this)(g)}}})})(mt);var el=mt.exports;const tl=ee(el);var nl={exports:{}};(function(t,l){(function(o,n){t.exports=n(ot)})(J,function(o){function n(c){return c&&typeof c=="object"&&"default"in c?c:{default:c}}var a=n(o),s={name:"zh-cn",weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"周日_周一_周二_周三_周四_周五_周六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),ordinal:function(c,i){return i==="W"?c+"周":c+"日"},weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日Ah点mm分",LLLL:"YYYY年M月D日ddddAh点mm分",l:"YYYY/M/D",ll:"YYYY年M月D日",lll:"YYYY年M月D日 HH:mm",llll:"YYYY年M月D日dddd HH:mm"},relativeTime:{future:"%s内",past:"%s前",s:"几秒",m:"1 分钟",mm:"%d 分钟",h:"1 小时",hh:"%d 小时",d:"1 天",dd:"%d 天",M:"1 个月",MM:"%d 个月",y:"1 年",yy:"%d 年"},meridiem:function(c,i){var r=100*c+i;return r<600?"凌晨":r<900?"早上":r<1100?"上午":r<1300?"中午":r<1800?"下午":"晚上"}};return a.default.locale(s,null,!0),s})})(nl);F.extend(Ta);F.extend(Ia);F.extend(La);F.extend(_a);F.extend(Fa);F.extend(Wa);F.extend(Ga);F.extend(Ka);F.extend(Za);F.extend(Ja);F.extend(tl);function Ve(t={}){const{timezone:l="Asia/Shanghai",locale:o="zh-cn",defaultFormat:n="YYYY-MM-DD HH:mm:ss",parseStrict:a=!1,weekStart:s}=t;F.locale(o);const c=M=>(M==null?F():F(M)).tz(l).locale(o),i=(M,T)=>T?F(M,T,a).tz(l).locale(o):c(M),r=M=>i(M).utc(),d=M=>F(M).utc().tz(l).locale(o),g=e.ref(c()),p=()=>{g.value=c()},v=()=>c(),h=(M,T=n)=>i(M).format(T),x=(M,T)=>i(M,T),u=M=>i(M),f=(M,T,Y)=>i(M).isSame(i(T),Y),y=(M,T,Y)=>i(M).isAfter(i(T),Y),k=(M,T,Y)=>i(M).isBefore(i(T),Y),w=(M,T,Y)=>i(M).isSameOrAfter(i(T),Y),S=(M,T,Y)=>i(M).isSameOrBefore(i(T),Y),D=(M,T,Y,W,U)=>i(M).isBetween(i(T),i(Y),W,U),P=(M,T,Y)=>i(M).add(T,Y),B=(M,T,Y)=>i(M).subtract(T,Y),m=(M,T,Y,W)=>i(M).diff(i(T),Y,W),E=(M,T)=>i(M).startOf(T),b=(M,T)=>i(M).endOf(T),j=M=>i(M).from(c()),L=M=>i(M).to(c()),_=(M,T)=>i(M).from(i(T)),A=(M,T)=>i(M).to(i(T)),V=(M,T=c(),Y="millisecond")=>{const W=i(M).diff(i(T),"millisecond");return F.duration(Math.abs(W)).humanize()},N=M=>{const T=F.duration(M),Y=Math.floor(T.asDays()),W=T.hours(),U=T.minutes(),G=T.seconds();return{days:Y,hours:W,minutes:U,seconds:G}},z=(M,T,Y,W,U)=>{var ce;const G=c().year(M).month(T).date(1),R=G.startOf("month");G.endOf("month");const q=typeof s=="number"?s:((ce=F.Ls[o])==null?void 0:ce.weekStart)??0,Q=R.startOf("week").add(q,"day"),te=Q.isAfter(R)?Q.subtract(7,"day"):Q,ne=Y?i(Y):null,oe=W?i(W).startOf("day"):null,le=U?i(U).endOf("day"):null,re=c(),se=[];for(let ue=0;ue<42;ue++){const ae=te.add(ue,"day"),vt=ae.month()===T,yt=ae.isSame(re,"day"),wt=ne?ae.isSame(ne,"day"):!1,Ne=ae.day(),bt=Ne===0||Ne===6;let be=!1;oe&&ae.isBefore(oe,"day")&&(be=!0),le&&ae.isAfter(le,"day")&&(be=!0),se.push({date:ae,isCurrentMonth:vt,isToday:yt,isSelected:wt,isDisabled:be,isWeekend:bt})}return se},C=(M,T)=>{const Y=c().year(M).month(T).date(1),W=Y.endOf("month"),U=W.date(),G=Y.day(),R=W.day(),q=Math.ceil((G+U)/7);return{firstDay:Y,lastDay:W,daysInMonth:U,firstWeekday:G,lastWeekday:R,weeksInMonth:q}},$=()=>{const M=c();return{today:{start:M.startOf("day"),end:M.endOf("day")},yesterday:{start:M.subtract(1,"day").startOf("day"),end:M.subtract(1,"day").endOf("day")},thisWeek:{start:M.startOf("week"),end:M.endOf("week")},lastWeek:{start:M.subtract(1,"week").startOf("week"),end:M.subtract(1,"week").endOf("week")},thisMonth:{start:M.startOf("month"),end:M.endOf("month")},lastMonth:{start:M.subtract(1,"month").startOf("month"),end:M.subtract(1,"month").endOf("month")},thisYear:{start:M.startOf("year"),end:M.endOf("year")},lastYear:{start:M.subtract(1,"year").startOf("year"),end:M.subtract(1,"year").endOf("year")}}},I=(M,T)=>T?F(M,T,a).isValid():F(M).isValid(),O=(M,T)=>i(M).get(T),X=(M,T,Y)=>i(M).set(T,Y),H={date:"YYYY-MM-DD",time:"HH:mm:ss",datetime:"YYYY-MM-DD HH:mm:ss",dateTime:"YYYY-MM-DD HH:mm",month:"YYYY-MM",year:"YYYY",timestamp:"X",iso:"YYYY-MM-DDTHH:mm:ssZ"};return{now:e.computed(()=>g.value),updateNow:p,getCurrent:v,format:h,parse:x,create:u,isSame:f,isAfter:y,isBefore:k,isSameOrAfter:w,isSameOrBefore:S,isBetween:D,add:P,subtract:B,diff:m,startOf:E,endOf:b,fromNow:j,toNow:L,from:_,to:A,humanizeDiff:V,formatParts:N,getCalendarDates:z,getMonthInfo:C,getTimeRanges:$,isValid:I,getUnit:O,setUnit:X,formats:H,dayjs:M=>i(M),toUTC:r,fromUTC:d}}function ol(t={start:null,end:null},l="Asia/Shanghai"){const o=r=>(r==null?F():F(r)).tz(l),n=e.ref({start:t.start?o(t.start):null,end:t.end?o(t.end):null}),a=(r,d)=>{n.value={start:r?o(r):null,end:d?o(d):null}},s=()=>{n.value={start:null,end:null}},c=e.computed(()=>{const{start:r,end:d}=n.value;return!r||!d?!1:r.isBefore(d)||r.isSame(d)}),i=e.computed(()=>{if(!c.value)return null;const r=n.value.end.diff(n.value.start);return{ms:r,days:Math.floor(F.duration(r).asDays())}});return{range:e.computed(()=>n.value),setRange:a,clearRange:s,isValidRange:c,rangeDuration:i}}function al(t,l="Asia/Shanghai"){const o=g=>(g==null?F():F(g)).tz(l),n=e.ref(o(t)),a=e.ref(o()),s=e.ref(!1),c=e.computed(()=>{const g=n.value.diff(a.value);return g<=0?(s.value=!0,F.duration(0)):F.duration(g)}),i=()=>{a.value=o()},r=(g="HH:mm:ss")=>{if(s.value)return"00:00:00";const p=c.value,v=Math.floor(p.asHours()),h=p.minutes(),x=p.seconds();return g.replace("HH",String(v).padStart(2,"0")).replace("mm",String(h).padStart(2,"0")).replace("ss",String(x).padStart(2,"0"))},d=e.computed(()=>{const g=c.value;return{days:Math.floor(g.asDays()),hours:g.hours(),minutes:g.minutes(),seconds:g.seconds(),milliseconds:g.milliseconds()}});return{target:e.computed(()=>n.value),now:e.computed(()=>a.value),duration:e.computed(()=>c.value),parts:d,isExpired:e.computed(()=>s.value),updateNow:i,formatDuration:r}}const ll=["value","placeholder","disabled"],sl={class:"datetime-icon"},cl={class:"datetime-header"},il={class:"datetime-title"},rl={key:0,class:"datetime-mode-switch"},dl={key:1,class:"datetime-date-picker"},gl={class:"date-navigation"},fl={class:"current-month"},ul={class:"month-year"},ml={class:"weekdays"},hl={class:"date-grid"},pl=["onClick"],vl={key:2,class:"datetime-time-picker"},yl={class:"time-inputs"},wl={class:"time-input-group"},bl=["value"],Cl={class:"time-input-group"},kl=["value"],Sl={key:0,class:"time-separator"},xl={key:1,class:"time-input-group"},El=["value"],$l={class:"time-sliders"},Ml={class:"time-slider-group"},Pl=["value"],Bl={class:"slider-value"},jl={class:"time-slider-group"},Vl=["value"],Nl={class:"slider-value"},Dl={key:0,class:"time-slider-group"},Al=["value"],Tl={class:"slider-value"},zl={class:"datetime-footer"},Il=e.defineComponent({__name:"index",props:{modelValue:{default:null},mode:{default:"datetime"},size:{default:"medium"},disabled:{type:Boolean,default:!1},placeholder:{default:"请选择日期时间"},title:{default:"选择日期时间"},showSeconds:{type:Boolean,default:!1},minDate:{},maxDate:{},dateFormat:{default:"YYYY-MM-DD"},timeFormat:{default:"24"},showToday:{type:Boolean,default:!0},showClear:{type:Boolean,default:!0},locale:{default:"zh-CN"}},emits:["update:modelValue","change","open","close"],setup(t,{emit:l}){const o=t,n=l,a=e.ref(!1),s=e.ref("date"),c=e.ref(new Date().getFullYear()),i=e.ref(new Date().getMonth()),r=e.ref(null),d=e.ref(0),g=e.ref(0),p=e.ref(0),v=e.ref(!1),h=e.ref("panel-bottom"),x=e.ref(),{format:u,create:f,getCalendarDates:y,formats:k}=Ve({timezone:"Asia/Shanghai",locale:"zh-cn"}),w=e.computed(()=>o.locale==="zh-CN"?["日","一","二","三","四","五","六"]:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]),S=e.computed(()=>{if(!r.value)return"";const C=f(r.value),$=o.showSeconds?`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}:${p.value.toString().padStart(2,"0")}`:`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}`;return o.mode==="date"?u(C,k.date):o.mode==="time"?$:`${u(C,k.date)} ${$}`}),D=e.computed(()=>o.mode==="date"?"mdi:calendar":o.mode==="time"?"mdi:clock":"mdi:calendar-clock"),P=e.computed(()=>{const C=r.value?f(r.value):void 0,$=o.minDate?f(o.minDate):void 0,I=o.maxDate?f(o.maxDate):void 0;return y(c.value,i.value,C,$,I)}),B=()=>{o.disabled||(a.value=!a.value,a.value?(N(),n("open")):n("close"))},m=()=>{a.value=!1,n("close")},E=()=>{i.value===0?(i.value=11,c.value--):i.value--},b=()=>{i.value===11?(i.value=0,c.value++):i.value++},j=C=>{C.isDisabled||(r.value=C.date.toDate(),o.mode==="date"&&_())},L=()=>{d.value=Math.max(0,Math.min(23,d.value)),g.value=Math.max(0,Math.min(59,g.value)),p.value=Math.max(0,Math.min(59,p.value))},_=()=>{if(o.mode==="date"&&r.value){const C=f(r.value),$=u(C,o.dateFormat);n("update:modelValue",$),n("change",$)}else if(o.mode==="time"){const C=o.showSeconds?`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}:${p.value.toString().padStart(2,"0")}`:`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}`;n("update:modelValue",C),n("change",C)}else if(o.mode==="datetime"&&r.value){const C=f(r.value).hour(d.value).minute(g.value).second(p.value).millisecond(0),$=o.showSeconds?`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}:${p.value.toString().padStart(2,"0")}`:`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}`,I=`${u(C,o.dateFormat)} ${$}`;n("update:modelValue",I),n("change",I)}m()},A=()=>{r.value=null,d.value=0,g.value=0,p.value=0,n("update:modelValue",null),n("change",null),m()},V=()=>{v.value=window.innerWidth<=768},N=()=>{if(!x.value)return;const C=x.value.getBoundingClientRect(),I=window.innerHeight-C.bottom,O=C.top;I>=400||I>O?h.value="panel-bottom":h.value="panel-top"};e.watch(()=>o.modelValue,C=>{if(C){const $=f(C);r.value=$.toDate(),d.value=$.hour(),g.value=$.minute(),p.value=$.second(),c.value=$.year(),i.value=$.month()}else r.value=null,d.value=0,g.value=0,p.value=0},{immediate:!0}),e.watch(()=>o.mode,C=>{C==="datetime"?s.value="date":s.value=C},{immediate:!0});const z=C=>{var $;a.value&&!(($=C.target)!=null&&$.closest(".x-datetime-picker"))&&m()};return e.onMounted(()=>{V(),window.addEventListener("resize",V),document.addEventListener("click",z)}),e.onUnmounted(()=>{window.removeEventListener("resize",V),document.removeEventListener("click",z)}),(C,$)=>{const I=e.resolveComponent("XButton");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["x-datetime-picker",[`datetime-${t.size}`,{"datetime-disabled":t.disabled}]])},[e.createElementVNode("div",{class:"datetime-input-wrapper",onClick:B},[e.createElementVNode("input",{ref_key:"inputRef",ref:x,type:"text",value:S.value,placeholder:t.placeholder,disabled:t.disabled,readonly:"",class:"datetime-input"},null,8,ll),e.createElementVNode("div",sl,[e.createVNode(e.unref(K),{icon:D.value},null,8,["icon"])])]),a.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["datetime-panel",h.value])},[e.createElementVNode("div",cl,[e.createElementVNode("div",il,e.toDisplayString(t.title),1),e.createVNode(I,{icon:"mdi:close",size:"small",onClick:m},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:close"})]),_:1})]),t.mode==="datetime"?(e.openBlock(),e.createElementBlock("div",rl,[e.createVNode(I,{size:"small",class:e.normalizeClass({active:s.value==="date"}),icon:"mdi:calendar",onClick:$[0]||($[0]=O=>s.value="date")},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:calendar"}),$[2]||($[2]=e.createElementVNode("span",null,"日期",-1))]),_:1},8,["class"]),e.createVNode(I,{size:"small",icon:"mdi:clock",class:e.normalizeClass({active:s.value==="time"}),onClick:$[1]||($[1]=O=>s.value="time")},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:clock"}),$[3]||($[3]=e.createElementVNode("span",null,"时间",-1))]),_:1},8,["class"])])):e.createCommentVNode("",!0),s.value==="date"||t.mode==="date"?(e.openBlock(),e.createElementBlock("div",dl,[e.createElementVNode("div",gl,[e.createVNode(I,{size:"small",onClick:E},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:chevron-left"})]),_:1}),e.createElementVNode("div",fl,[e.createElementVNode("span",ul,e.toDisplayString(c.value)+"年"+e.toDisplayString(i.value+1)+"月",1)]),e.createVNode(I,{size:"small",onClick:b},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:chevron-right"})]),_:1})]),e.createElementVNode("div",ml,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,O=>(e.openBlock(),e.createElementBlock("div",{key:O,class:"weekday"},e.toDisplayString(O),1))),128))]),e.createElementVNode("div",hl,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(P.value,O=>(e.openBlock(),e.createElementBlock("div",{key:O.date.format("YYYY-MM-DD"),class:e.normalizeClass(["date-cell",{"date-other-month":!O.isCurrentMonth,"date-today":O.isToday,"date-selected":O.isSelected,"date-disabled":O.isDisabled}]),onClick:X=>j(O)},e.toDisplayString(O.date.date()),11,pl))),128))])])):e.createCommentVNode("",!0),s.value==="time"||t.mode==="time"?(e.openBlock(),e.createElementBlock("div",vl,[e.createElementVNode("div",yl,[e.createElementVNode("div",wl,[$[4]||($[4]=e.createElementVNode("label",{class:"time-label"},"时",-1)),e.createElementVNode("input",{value:d.value,type:"number",min:"0",max:"23",class:"time-input",onChange:L},null,40,bl)]),$[7]||($[7]=e.createElementVNode("div",{class:"time-separator"},":",-1)),e.createElementVNode("div",Cl,[$[5]||($[5]=e.createElementVNode("label",{class:"time-label"},"分",-1)),e.createElementVNode("input",{value:g.value,type:"number",min:"0",max:"59",class:"time-input",onChange:L},null,40,kl)]),t.showSeconds?(e.openBlock(),e.createElementBlock("div",Sl,":")):e.createCommentVNode("",!0),t.showSeconds?(e.openBlock(),e.createElementBlock("div",xl,[$[6]||($[6]=e.createElementVNode("label",{class:"time-label"},"秒",-1)),e.createElementVNode("input",{value:p.value,type:"number",min:"0",max:"59",class:"time-input",onChange:L},null,40,El)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",$l,[e.createElementVNode("div",Ml,[$[8]||($[8]=e.createElementVNode("label",{class:"slider-label"},"小时",-1)),e.createElementVNode("input",{value:d.value,type:"range",min:"0",max:"23",class:"time-slider",onInput:L},null,40,Pl),e.createElementVNode("span",Bl,e.toDisplayString(d.value.toString().padStart(2,"0")),1)]),e.createElementVNode("div",jl,[$[9]||($[9]=e.createElementVNode("label",{class:"slider-label"},"分钟",-1)),e.createElementVNode("input",{value:g.value,type:"range",min:"0",max:"59",class:"time-slider",onInput:L},null,40,Vl),e.createElementVNode("span",Nl,e.toDisplayString(g.value.toString().padStart(2,"0")),1)]),t.showSeconds?(e.openBlock(),e.createElementBlock("div",Dl,[$[10]||($[10]=e.createElementVNode("label",{class:"slider-label"},"秒钟",-1)),e.createElementVNode("input",{value:p.value,type:"range",min:"0",max:"59",step:"1",class:"time-slider",onInput:L},null,40,Al),e.createElementVNode("span",Tl,e.toDisplayString(p.value.toString().padStart(2,"0")),1)])):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),e.createElementVNode("div",zl,[e.createVNode(I,{size:"small",ghost:"",type:"danger",onClick:A},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:delete"}),$[11]||($[11]=e.createElementVNode("span",null,"清空",-1))]),_:1}),e.createVNode(I,{size:"small",ghost:"",type:"primary",onClick:_},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:check"}),$[12]||($[12]=e.createElementVNode("span",null,"确定",-1))]),_:1})])],2)):e.createCommentVNode("",!0)],2)}}}),Ol=Z(Il,[["__scopeId","data-v-44868cc1"]]),ht=()=>{const t=()=>{let d=document.getElementById("xl-message-container");return d||(d=document.createElement("div"),d.id="xl-message-container",d.style.cssText=`
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),We=/^[a-z0-9]+(-[a-z0-9]+)*$/,ye=(t,l,o,n="")=>{const a=t.split(":");if(t.slice(0,1)==="@"){if(a.length<2||a.length>3)return null;n=a.shift().slice(1)}if(a.length>3||!a.length)return null;if(a.length>1){const i=a.pop(),r=a.pop(),d={provider:a.length>0?a[0]:n,prefix:r,name:i};return l&&!me(d)?null:d}const s=a[0],c=s.split("-");if(c.length>1){const i={provider:n,prefix:c.shift(),name:c.join("-")};return l&&!me(i)?null:i}if(o&&n===""){const i={provider:n,prefix:"",name:s};return l&&!me(i,o)?null:i}return null},me=(t,l)=>t?!!((l&&t.prefix===""||t.prefix)&&t.name):!1,Re=Object.freeze({left:0,top:0,width:16,height:16}),ve=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),we=Object.freeze({...Re,...ve}),Se=Object.freeze({...we,body:"",hidden:!1});function Ct(t,l){const o={};!t.hFlip!=!l.hFlip&&(o.hFlip=!0),!t.vFlip!=!l.vFlip&&(o.vFlip=!0);const n=((t.rotate||0)+(l.rotate||0))%4;return n&&(o.rotate=n),o}function De(t,l){const o=Ct(t,l);for(const n in Se)n in ve?n in t&&!(n in o)&&(o[n]=ve[n]):n in l?o[n]=l[n]:n in t&&(o[n]=t[n]);return o}function kt(t,l){const o=t.icons,n=t.aliases||Object.create(null),a=Object.create(null);function s(c){if(o[c])return a[c]=[];if(!(c in a)){a[c]=null;const i=n[c]&&n[c].parent,r=i&&s(i);r&&(a[c]=[i].concat(r))}return a[c]}return Object.keys(o).concat(Object.keys(n)).forEach(s),a}function St(t,l,o){const n=t.icons,a=t.aliases||Object.create(null);let s={};function c(i){s=De(n[i]||a[i],s)}return c(l),o.forEach(c),De(t,s)}function Ge(t,l){const o=[];if(typeof t!="object"||typeof t.icons!="object")return o;t.not_found instanceof Array&&t.not_found.forEach(a=>{l(a,null),o.push(a)});const n=kt(t);for(const a in n){const s=n[a];s&&(l(a,St(t,a,s)),o.push(a))}return o}const xt={provider:"",aliases:{},not_found:{},...Re};function Ce(t,l){for(const o in l)if(o in t&&typeof t[o]!=typeof l[o])return!1;return!0}function Ue(t){if(typeof t!="object"||t===null)return null;const l=t;if(typeof l.prefix!="string"||!t.icons||typeof t.icons!="object"||!Ce(t,xt))return null;const o=l.icons;for(const a in o){const s=o[a];if(!a||typeof s.body!="string"||!Ce(s,Se))return null}const n=l.aliases||Object.create(null);for(const a in n){const s=n[a],c=s.parent;if(!a||typeof c!="string"||!o[c]&&!n[c]||!Ce(s,Se))return null}return l}const Ae=Object.create(null);function Et(t,l){return{provider:t,prefix:l,icons:Object.create(null),missing:new Set}}function ie(t,l){const o=Ae[t]||(Ae[t]=Object.create(null));return o[l]||(o[l]=Et(t,l))}function Ke(t,l){return Ue(l)?Ge(l,(o,n)=>{n?t.icons[o]=n:t.missing.add(o)}):[]}function $t(t,l,o){try{if(typeof o.body=="string")return t.icons[l]={...o},!0}catch{}return!1}let fe=!1;function qe(t){return typeof t=="boolean"&&(fe=t),fe}function Mt(t){const l=typeof t=="string"?ye(t,!0,fe):t;if(l){const o=ie(l.provider,l.prefix),n=l.name;return o.icons[n]||(o.missing.has(n)?null:void 0)}}function Bt(t,l){const o=ye(t,!0,fe);if(!o)return!1;const n=ie(o.provider,o.prefix);return l?$t(n,o.name,l):(n.missing.add(o.name),!0)}function Pt(t,l){if(typeof t!="object")return!1;if(typeof l!="string"&&(l=t.provider||""),fe&&!l&&!t.prefix){let a=!1;return Ue(t)&&(t.prefix="",Ge(t,(s,c)=>{Bt(s,c)&&(a=!0)})),a}const o=t.prefix;if(!me({prefix:o,name:"a"}))return!1;const n=ie(l,o);return!!Ke(n,t)}const Ze=Object.freeze({width:null,height:null}),Qe=Object.freeze({...Ze,...ve}),jt=/(-?[0-9.]*[0-9]+[0-9.]*)/g,Vt=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function Te(t,l,o){if(l===1)return t;if(o=o||100,typeof t=="number")return Math.ceil(t*l*o)/o;if(typeof t!="string")return t;const n=t.split(jt);if(n===null||!n.length)return t;const a=[];let s=n.shift(),c=Vt.test(s);for(;;){if(c){const i=parseFloat(s);isNaN(i)?a.push(s):a.push(Math.ceil(i*l*o)/o)}else a.push(s);if(s=n.shift(),s===void 0)return a.join("");c=!c}}function Nt(t,l="defs"){let o="";const n=t.indexOf("<"+l);for(;n>=0;){const a=t.indexOf(">",n),s=t.indexOf("</"+l);if(a===-1||s===-1)break;const c=t.indexOf(">",s);if(c===-1)break;o+=t.slice(a+1,s).trim(),t=t.slice(0,n).trim()+t.slice(c+1)}return{defs:o,content:t}}function Dt(t,l){return t?"<defs>"+t+"</defs>"+l:l}function At(t,l,o){const n=Nt(t);return Dt(n.defs,l+n.content+o)}const Tt=t=>t==="unset"||t==="undefined"||t==="none";function zt(t,l){const o={...we,...t},n={...Qe,...l},a={left:o.left,top:o.top,width:o.width,height:o.height};let s=o.body;[o,n].forEach(u=>{const f=[],y=u.hFlip,S=u.vFlip;let w=u.rotate;y?S?w+=2:(f.push("translate("+(a.width+a.left).toString()+" "+(0-a.top).toString()+")"),f.push("scale(-1 1)"),a.top=a.left=0):S&&(f.push("translate("+(0-a.left).toString()+" "+(a.height+a.top).toString()+")"),f.push("scale(1 -1)"),a.top=a.left=0);let x;switch(w<0&&(w-=Math.floor(w/4)*4),w=w%4,w){case 1:x=a.height/2+a.top,f.unshift("rotate(90 "+x.toString()+" "+x.toString()+")");break;case 2:f.unshift("rotate(180 "+(a.width/2+a.left).toString()+" "+(a.height/2+a.top).toString()+")");break;case 3:x=a.width/2+a.left,f.unshift("rotate(-90 "+x.toString()+" "+x.toString()+")");break}w%2===1&&(a.left!==a.top&&(x=a.left,a.left=a.top,a.top=x),a.width!==a.height&&(x=a.width,a.width=a.height,a.height=x)),f.length&&(s=At(s,'<g transform="'+f.join(" ")+'">',"</g>"))});const c=n.width,i=n.height,r=a.width,d=a.height;let g,p;c===null?(p=i===null?"1em":i==="auto"?d:i,g=Te(p,r/d)):(g=c==="auto"?r:c,p=i===null?Te(g,d/r):i==="auto"?d:i);const v={},m=(u,f)=>{Tt(f)||(v[u]=f.toString())};m("width",g),m("height",p);const k=[a.left,a.top,r,d];return v.viewBox=k.join(" "),{attributes:v,viewBox:k,body:s}}const It=/\sid="(\S+)"/g,Ot="IconifyId"+Date.now().toString(16)+(Math.random()*16777216|0).toString(16);let Lt=0;function Yt(t,l=Ot){const o=[];let n;for(;n=It.exec(t);)o.push(n[1]);if(!o.length)return t;const a="suffix"+(Math.random()*16777216|Date.now()).toString(16);return o.forEach(s=>{const c=typeof l=="function"?l(s):l+(Lt++).toString(),i=s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");t=t.replace(new RegExp('([#;"])('+i+')([")]|\\.[a-z])',"g"),"$1"+c+a+"$3")}),t=t.replace(new RegExp(a,"g"),""),t}const xe=Object.create(null);function _t(t,l){xe[t]=l}function Ee(t){return xe[t]||xe[""]}function Be(t){let l;if(typeof t.resources=="string")l=[t.resources];else if(l=t.resources,!(l instanceof Array)||!l.length)return null;return{resources:l,path:t.path||"/",maxURL:t.maxURL||500,rotate:t.rotate||750,timeout:t.timeout||5e3,random:t.random===!0,index:t.index||0,dataAfterTimeout:t.dataAfterTimeout!==!1}}const Pe=Object.create(null),de=["https://api.simplesvg.com","https://api.unisvg.com"],he=[];for(;de.length>0;)de.length===1||Math.random()>.5?he.push(de.shift()):he.push(de.pop());Pe[""]=Be({resources:["https://api.iconify.design"].concat(he)});function Xt(t,l){const o=Be(l);return o===null?!1:(Pe[t]=o,!0)}function je(t){return Pe[t]}const Ft=()=>{let t;try{if(t=fetch,typeof t=="function")return t}catch{}};let ze=Ft();function Ht(t,l){const o=je(t);if(!o)return 0;let n;if(!o.maxURL)n=0;else{let a=0;o.resources.forEach(c=>{a=Math.max(a,c.length)});const s=l+".json?icons=";n=o.maxURL-a-o.path.length-s.length}return n}function Wt(t){return t===404}const Rt=(t,l,o)=>{const n=[],a=Ht(t,l),s="icons";let c={type:s,provider:t,prefix:l,icons:[]},i=0;return o.forEach((r,d)=>{i+=r.length+1,i>=a&&d>0&&(n.push(c),c={type:s,provider:t,prefix:l,icons:[]},i=r.length),c.icons.push(r)}),n.push(c),n};function Gt(t){if(typeof t=="string"){const l=je(t);if(l)return l.path}return"/"}const Ut=(t,l,o)=>{if(!ze){o("abort",424);return}let n=Gt(l.provider);switch(l.type){case"icons":{const s=l.prefix,i=l.icons.join(","),r=new URLSearchParams({icons:i});n+=s+".json?"+r.toString();break}case"custom":{const s=l.uri;n+=s.slice(0,1)==="/"?s.slice(1):s;break}default:o("abort",400);return}let a=503;ze(t+n).then(s=>{const c=s.status;if(c!==200){setTimeout(()=>{o(Wt(c)?"abort":"next",c)});return}return a=501,s.json()}).then(s=>{if(typeof s!="object"||s===null){setTimeout(()=>{s===404?o("abort",s):o("next",a)});return}setTimeout(()=>{o("success",s)})}).catch(()=>{o("next",a)})},Kt={prepare:Rt,send:Ut};function qt(t){const l={loaded:[],missing:[],pending:[]},o=Object.create(null);t.sort((a,s)=>a.provider!==s.provider?a.provider.localeCompare(s.provider):a.prefix!==s.prefix?a.prefix.localeCompare(s.prefix):a.name.localeCompare(s.name));let n={provider:"",prefix:"",name:""};return t.forEach(a=>{if(n.name===a.name&&n.prefix===a.prefix&&n.provider===a.provider)return;n=a;const s=a.provider,c=a.prefix,i=a.name,r=o[s]||(o[s]=Object.create(null)),d=r[c]||(r[c]=ie(s,c));let g;i in d.icons?g=l.loaded:c===""||d.missing.has(i)?g=l.missing:g=l.pending;const p={provider:s,prefix:c,name:i};g.push(p)}),l}function Je(t,l){t.forEach(o=>{const n=o.loaderCallbacks;n&&(o.loaderCallbacks=n.filter(a=>a.id!==l))})}function Zt(t){t.pendingCallbacksFlag||(t.pendingCallbacksFlag=!0,setTimeout(()=>{t.pendingCallbacksFlag=!1;const l=t.loaderCallbacks?t.loaderCallbacks.slice(0):[];if(!l.length)return;let o=!1;const n=t.provider,a=t.prefix;l.forEach(s=>{const c=s.icons,i=c.pending.length;c.pending=c.pending.filter(r=>{if(r.prefix!==a)return!0;const d=r.name;if(t.icons[d])c.loaded.push({provider:n,prefix:a,name:d});else if(t.missing.has(d))c.missing.push({provider:n,prefix:a,name:d});else return o=!0,!0;return!1}),c.pending.length!==i&&(o||Je([t],s.id),s.callback(c.loaded.slice(0),c.missing.slice(0),c.pending.slice(0),s.abort))})}))}let Qt=0;function Jt(t,l,o){const n=Qt++,a=Je.bind(null,o,n);if(!l.pending.length)return a;const s={id:n,icons:l,callback:t,abort:a};return o.forEach(c=>{(c.loaderCallbacks||(c.loaderCallbacks=[])).push(s)}),a}function en(t,l=!0,o=!1){const n=[];return t.forEach(a=>{const s=typeof a=="string"?ye(a,l,o):a;s&&n.push(s)}),n}var tn={resources:[],index:0,timeout:2e3,rotate:750,random:!1,dataAfterTimeout:!1};function nn(t,l,o,n){const a=t.resources.length,s=t.random?Math.floor(Math.random()*a):t.index;let c;if(t.random){let B=t.resources.slice(0);for(c=[];B.length>1;){const P=Math.floor(Math.random()*B.length);c.push(B[P]),B=B.slice(0,P).concat(B.slice(P+1))}c=c.concat(B)}else c=t.resources.slice(s).concat(t.resources.slice(0,s));const i=Date.now();let r="pending",d=0,g,p=null,v=[],m=[];typeof n=="function"&&m.push(n);function k(){p&&(clearTimeout(p),p=null)}function u(){r==="pending"&&(r="aborted"),k(),v.forEach(B=>{B.status==="pending"&&(B.status="aborted")}),v=[]}function f(B,P){P&&(m=[]),typeof B=="function"&&m.push(B)}function y(){return{startTime:i,payload:l,status:r,queriesSent:d,queriesPending:v.length,subscribe:f,abort:u}}function S(){r="failed",m.forEach(B=>{B(void 0,g)})}function w(){v.forEach(B=>{B.status==="pending"&&(B.status="aborted")}),v=[]}function x(B,P,h){const E=P!=="success";switch(v=v.filter(b=>b!==B),r){case"pending":break;case"failed":if(E||!t.dataAfterTimeout)return;break;default:return}if(P==="abort"){g=h,S();return}if(E){g=h,v.length||(c.length?D():S());return}if(k(),w(),!t.random){const b=t.resources.indexOf(B.resource);b!==-1&&b!==t.index&&(t.index=b)}r="completed",m.forEach(b=>{b(h)})}function D(){if(r!=="pending")return;k();const B=c.shift();if(B===void 0){if(v.length){p=setTimeout(()=>{k(),r==="pending"&&(w(),S())},t.timeout);return}S();return}const P={status:"pending",resource:B,callback:(h,E)=>{x(P,h,E)}};v.push(P),d++,p=setTimeout(D,t.rotate),o(B,l,P.callback)}return setTimeout(D),y}function et(t){const l={...tn,...t};let o=[];function n(){o=o.filter(i=>i().status==="pending")}function a(i,r,d){const g=nn(l,i,r,(p,v)=>{n(),d&&d(p,v)});return o.push(g),g}function s(i){return o.find(r=>i(r))||null}return{query:a,find:s,setIndex:i=>{l.index=i},getIndex:()=>l.index,cleanup:n}}function Ie(){}const ke=Object.create(null);function on(t){if(!ke[t]){const l=je(t);if(!l)return;const o=et(l),n={config:l,redundancy:o};ke[t]=n}return ke[t]}function an(t,l,o){let n,a;if(typeof t=="string"){const s=Ee(t);if(!s)return o(void 0,424),Ie;a=s.send;const c=on(t);c&&(n=c.redundancy)}else{const s=Be(t);if(s){n=et(s);const c=t.resources?t.resources[0]:"",i=Ee(c);i&&(a=i.send)}}return!n||!a?(o(void 0,424),Ie):n.query(l,a,o)().abort}function Oe(){}function ln(t){t.iconsLoaderFlag||(t.iconsLoaderFlag=!0,setTimeout(()=>{t.iconsLoaderFlag=!1,Zt(t)}))}function sn(t){const l=[],o=[];return t.forEach(n=>{(n.match(We)?l:o).push(n)}),{valid:l,invalid:o}}function ge(t,l,o){function n(){const a=t.pendingIcons;l.forEach(s=>{a&&a.delete(s),t.icons[s]||t.missing.add(s)})}if(o&&typeof o=="object")try{if(!Ke(t,o).length){n();return}}catch(a){console.error(a)}n(),ln(t)}function Le(t,l){t instanceof Promise?t.then(o=>{l(o)}).catch(()=>{l(null)}):l(t)}function cn(t,l){t.iconsToLoad?t.iconsToLoad=t.iconsToLoad.concat(l).sort():t.iconsToLoad=l,t.iconsQueueFlag||(t.iconsQueueFlag=!0,setTimeout(()=>{t.iconsQueueFlag=!1;const{provider:o,prefix:n}=t,a=t.iconsToLoad;if(delete t.iconsToLoad,!a||!a.length)return;const s=t.loadIcon;if(t.loadIcons&&(a.length>1||!s)){Le(t.loadIcons(a,n,o),g=>{ge(t,a,g)});return}if(s){a.forEach(g=>{const p=s(g,n,o);Le(p,v=>{const m=v?{prefix:n,icons:{[g]:v}}:null;ge(t,[g],m)})});return}const{valid:c,invalid:i}=sn(a);if(i.length&&ge(t,i,null),!c.length)return;const r=n.match(We)?Ee(o):null;if(!r){ge(t,c,null);return}r.prepare(o,n,c).forEach(g=>{an(o,g,p=>{ge(t,g.icons,p)})})}))}const rn=(t,l)=>{const o=en(t,!0,qe()),n=qt(o);if(!n.pending.length){let r=!0;return l&&setTimeout(()=>{r&&l(n.loaded,n.missing,n.pending,Oe)}),()=>{r=!1}}const a=Object.create(null),s=[];let c,i;return n.pending.forEach(r=>{const{provider:d,prefix:g}=r;if(g===i&&d===c)return;c=d,i=g,s.push(ie(d,g));const p=a[d]||(a[d]=Object.create(null));p[g]||(p[g]=[])}),n.pending.forEach(r=>{const{provider:d,prefix:g,name:p}=r,v=ie(d,g),m=v.pendingIcons||(v.pendingIcons=new Set);m.has(p)||(m.add(p),a[d][g].push(p))}),s.forEach(r=>{const d=a[r.provider][r.prefix];d.length&&cn(r,d)}),l?Jt(l,n,s):Oe};function dn(t,l){const o={...t};for(const n in l){const a=l[n],s=typeof a;n in Ze?(a===null||a&&(s==="string"||s==="number"))&&(o[n]=a):s===typeof o[n]&&(o[n]=n==="rotate"?a%4:a)}return o}const gn=/[\s,]+/;function fn(t,l){l.split(gn).forEach(o=>{switch(o.trim()){case"horizontal":t.hFlip=!0;break;case"vertical":t.vFlip=!0;break}})}function un(t,l=0){const o=t.replace(/^-?[0-9.]*/,"");function n(a){for(;a<0;)a+=4;return a%4}if(o===""){const a=parseInt(t);return isNaN(a)?0:n(a)}else if(o!==t){let a=0;switch(o){case"%":a=25;break;case"deg":a=90}if(a){let s=parseFloat(t.slice(0,t.length-o.length));return isNaN(s)?0:(s=s/a,s%1===0?n(s):0)}}return l}function mn(t,l){let o=t.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const n in l)o+=" "+n+'="'+l[n]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+o+">"+t+"</svg>"}function hn(t){return t.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}function pn(t){return"data:image/svg+xml,"+hn(t)}function vn(t){return'url("'+pn(t)+'")'}const Ye={...Qe,inline:!1},yn={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":!0,role:"img"},wn={display:"inline-block"},$e={backgroundColor:"currentColor"},tt={backgroundColor:"transparent"},_e={Image:"var(--svg)",Repeat:"no-repeat",Size:"100% 100%"},Xe={webkitMask:$e,mask:$e,background:tt};for(const t in Xe){const l=Xe[t];for(const o in _e)l[t+o]=_e[o]}const pe={};["horizontal","vertical"].forEach(t=>{const l=t.slice(0,1)+"Flip";pe[t+"-flip"]=l,pe[t.slice(0,1)+"-flip"]=l,pe[t+"Flip"]=l});function Fe(t){return t+(t.match(/^[-0-9.]+$/)?"px":"")}const He=(t,l)=>{const o=dn(Ye,l),n={...yn},a=l.mode||"svg",s={},c=l.style,i=typeof c=="object"&&!(c instanceof Array)?c:{};for(let u in l){const f=l[u];if(f!==void 0)switch(u){case"icon":case"style":case"onLoad":case"mode":case"ssr":break;case"inline":case"hFlip":case"vFlip":o[u]=f===!0||f==="true"||f===1;break;case"flip":typeof f=="string"&&fn(o,f);break;case"color":s.color=f;break;case"rotate":typeof f=="string"?o[u]=un(f):typeof f=="number"&&(o[u]=f);break;case"ariaHidden":case"aria-hidden":f!==!0&&f!=="true"&&delete n["aria-hidden"];break;default:{const y=pe[u];y?(f===!0||f==="true"||f===1)&&(o[y]=!0):Ye[u]===void 0&&(n[u]=f)}}}const r=zt(t,o),d=r.attributes;if(o.inline&&(s.verticalAlign="-0.125em"),a==="svg"){n.style={...s,...i},Object.assign(n,d);let u=0,f=l.id;return typeof f=="string"&&(f=f.replace(/-/g,"_")),n.innerHTML=Yt(r.body,f?()=>f+"ID"+u++:"iconifyVue"),e.h("svg",n)}const{body:g,width:p,height:v}=t,m=a==="mask"||(a==="bg"?!1:g.indexOf("currentColor")!==-1),k=mn(g,{...d,width:p+"",height:v+""});return n.style={...s,"--svg":vn(k),width:Fe(d.width),height:Fe(d.height),...wn,...m?$e:tt,...i},e.h("span",n)};qe(!0);_t("",Kt);if(typeof document<"u"&&typeof window<"u"){const t=window;if(t.IconifyPreload!==void 0){const l=t.IconifyPreload,o="Invalid IconifyPreload syntax.";typeof l=="object"&&l!==null&&(l instanceof Array?l:[l]).forEach(n=>{try{(typeof n!="object"||n===null||n instanceof Array||typeof n.icons!="object"||typeof n.prefix!="string"||!Pt(n))&&console.error(o)}catch{console.error(o)}})}if(t.IconifyProviders!==void 0){const l=t.IconifyProviders;if(typeof l=="object"&&l!==null)for(let o in l){const n="IconifyProviders["+o+"] is invalid.";try{const a=l[o];if(typeof a!="object"||!a||a.resources===void 0)continue;Xt(o,a)||console.error(n)}catch{console.error(n)}}}}const bn={...we,body:""},K=e.defineComponent({inheritAttrs:!1,data(){return{_name:"",_loadingIcon:null,iconMounted:!1,counter:0}},mounted(){this.iconMounted=!0},unmounted(){this.abortLoading()},methods:{abortLoading(){this._loadingIcon&&(this._loadingIcon.abort(),this._loadingIcon=null)},getIcon(t,l,o){if(typeof t=="object"&&t!==null&&typeof t.body=="string")return this._name="",this.abortLoading(),{data:t};let n;if(typeof t!="string"||(n=ye(t,!1,!0))===null)return this.abortLoading(),null;let a=Mt(n);if(!a)return(!this._loadingIcon||this._loadingIcon.name!==t)&&(this.abortLoading(),this._name="",a!==null&&(this._loadingIcon={name:t,abort:rn([n],()=>{this.counter++})})),null;if(this.abortLoading(),this._name!==t&&(this._name=t,l&&l(t)),o){a=Object.assign({},a);const c=o(a.body,n.name,n.prefix,n.provider);typeof c=="string"&&(a.body=c)}const s=["iconify"];return n.prefix!==""&&s.push("iconify--"+n.prefix),n.provider!==""&&s.push("iconify--"+n.provider),{data:a,classes:s}}},render(){this.counter;const t=this.$attrs,l=this.iconMounted||t.ssr?this.getIcon(t.icon,t.onLoad,t.customise):null;if(!l)return He(bn,t);let o=t;return l.classes&&(o={...t,class:(typeof t.class=="string"?t.class+" ":"")+l.classes.join(" ")}),He({...we,...l.data},o)}}),Cn=["disabled"],kn={key:0,class:"x-btn-icon"},Sn={key:1,class:"x-btn-loading"},xn={class:"x-btn-content"},En={key:2,class:"x-btn-icon"},$n=e.defineComponent({__name:"index",props:{type:{default:"default"},size:{default:"medium"},icon:{},iconRight:{},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},block:{type:Boolean,default:!1},round:{type:Boolean,default:!1},ghost:{type:Boolean,default:!1}},emits:["click"],setup(t,{emit:l}){const o=t,n=l,a=e.ref(),s=e.ref([]);let c=0;const i=e.computed(()=>["x-btn",`x-btn-${o.type}`,`x-btn-${o.size}`,{"x-btn-disabled":o.disabled,"x-btn-loading":o.loading,"x-btn-block":o.block,"x-btn-round":o.round,"x-btn-ghost":o.ghost}]);function r(g){!o.disabled&&!o.loading&&n("click",g)}function d(g){if(o.disabled||o.loading)return;const p=a.value;if(!p)return;const v=p.getBoundingClientRect(),m={id:c++,style:{left:`${g.clientX-v.left}px`,top:`${g.clientY-v.top}px`}};s.value.push(m),setTimeout(()=>{const k=s.value.findIndex(u=>u.id===m.id);k>-1&&s.value.splice(k,1)},600)}return(g,p)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(i.value),disabled:t.disabled||t.loading,onClick:r,onMousedown:d,ref_key:"buttonRef",ref:a},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,v=>(e.openBlock(),e.createElementBlock("span",{key:v.id,class:"x-btn-ripple",style:e.normalizeStyle(v.style)},null,4))),128)),t.icon&&!t.loading?(e.openBlock(),e.createElementBlock("span",kn,[e.createVNode(e.unref(K),{icon:t.icon},null,8,["icon"])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("span",Sn,[e.createVNode(e.unref(K),{icon:"eos-icons:loading"})])):e.createCommentVNode("",!0),e.createElementVNode("span",xn,[e.renderSlot(g.$slots,"default",{},void 0,!0)]),t.iconRight&&!t.loading?(e.openBlock(),e.createElementBlock("span",En,[e.createVNode(e.unref(K),{icon:t.iconRight},null,8,["icon"])])):e.createCommentVNode("",!0)],42,Cn))}}),Z=(t,l)=>{const o=t.__vccOpts||t;for(const[n,a]of l)o[n]=a;return o},Me=Z($n,[["__scopeId","data-v-4ae56e67"]]),Mn={class:"x-card-container"},Bn=["onClick"],Pn={class:"relative p-2"},jn={class:"image-container relative overflow-hidden rounded-lg bg-gray-100"},Vn=["src","alt"],Nn={key:0,class:"absolute top-3 left-3"},Dn={class:"label-badge"},An={class:"product-info p-5 ml-5"},Tn={class:"text-sm lg:text-base text-gray-700 leading-relaxed line-clamp-2 mb-3"},zn={class:"flex items-center justify-between gap-2"},In={class:"text-base lg:text-lg font-bold text-[var(--x-color-primary)]"},On={key:0,class:"bi bi-heart text-gray-500"},Ln={key:1,class:"bi bi-heart-fill text-[#FE374F]"},Yn=["onClick"],_n={class:"relative flex-shrink-0 p-2"},Xn={class:"image-container aspect-square bg-gray-100 rounded-lg overflow-hidden relative"},Fn=["src","alt"],Hn={key:0,class:"absolute top-3 left-3"},Wn={class:"label-badge"},Rn={class:"flex-1 flex flex-col justify-between product-info p-5 ml-5"},Gn={class:"text-sm lg:text-base text-gray-700 font-medium line-clamp-2 leading-relaxed mb-3"},Un={class:"flex items-center justify-between gap-2 mt-auto"},Kn={class:"text-base lg:text-lg font-bold text-[var(--x-color-primary)]"},qn=e.defineComponent({__name:"index",props:{layout:{default:"grid"},products:{default:()=>[]},useMockData:{type:Boolean,default:!0},columns:{default:4}},emits:["productClick","like"],setup(t,{emit:l}){const o=t,n=l,a=[{id:"1",name:"北欧风简约陶瓷花瓶",image:"https://images.unsplash.com/photo-1578500494198-246f612d3b3d?w=400",price:"¥299",label:"热卖",isWish:!1},{id:"2",name:"手工编织棉麻抱枕套",image:"https://images.unsplash.com/photo-1584100936595-c0654b55a2e2?w=400",price:"¥89",label:"新品",isWish:!0},{id:"3",name:"实木原木置物架收纳架",image:"https://images.unsplash.com/photo-1595428774223-ef52624120d2?w=400",price:"¥459",label:"",isWish:!1},{id:"4",name:"ins风格桌面装饰摆件",image:"https://images.unsplash.com/photo-1513506003901-1e6a229e2d15?w=400",price:"¥129",label:"特价",isWish:!1},{id:"5",name:"现代简约台灯护眼学习灯",image:"https://images.unsplash.com/photo-1507473885765-e6ed057f782c?w=400",price:"¥399",label:"",isWish:!0},{id:"6",name:"北欧风格装饰画挂画",image:"https://images.unsplash.com/photo-1561214115-f2f134cc4912?w=400",price:"¥199",label:"热卖",isWish:!1},{id:"7",name:"多功能收纳盒桌面整理",image:"https://images.unsplash.com/photo-1586023492125-27b2c045efd7?w=400",price:"¥68",label:"",isWish:!1},{id:"8",name:"创意陶瓷马克杯咖啡杯",image:"https://images.unsplash.com/photo-1514228742587-6b1558fcca3d?w=400",price:"¥59",label:"新品",isWish:!1},{id:"9",name:"手工玻璃花瓶透明花器",image:"https://images.unsplash.com/photo-1523293182086-7651a899d37f?w=400",price:"¥179",label:"",isWish:!0},{id:"10",name:"日式和风招财猫摆件",image:"https://images.unsplash.com/photo-1615529182904-14819c35db37?w=400",price:"¥149",label:"热卖",isWish:!1},{id:"11",name:"北欧风木质挂钟客厅",image:"https://images.unsplash.com/photo-1563861826100-9cb868fdbe1c?w=400",price:"¥259",label:"",isWish:!1},{id:"12",name:"现代简约落地花架",image:"https://images.unsplash.com/photo-1545127398-14699f92334b?w=400",price:"¥329",label:"特价",isWish:!1}],s=e.ref([]),c=e.computed(()=>o.products&&o.products.length>0?o.products:s.value),i=e.computed(()=>{const p=Math.min(Math.max(o.columns||4,1),4),v={1:"grid-cols-1",2:"grid-cols-1 md:grid-cols-2",3:"grid-cols-1 md:grid-cols-2 lg:grid-cols-3",4:"grid-cols-2 md:grid-cols-3 lg:grid-cols-4"};return v[p]||v[4]}),r=e.computed(()=>{const p=Math.min(Math.max(o.columns||4,1),4),v={1:"columns-1",2:"columns-1 md:columns-2",3:"columns-2 md:columns-2 lg:columns-3",4:"columns-2 sm:columns-2 md:columns-3 lg:columns-4"};return v[p]||v[4]});e.onMounted(()=>{o.useMockData&&(!o.products||o.products.length===0)&&(s.value=a)});const d=p=>{n("productClick",p)},g=p=>{p.isWish=!p.isWish,n("like",p)};return(p,v)=>(e.openBlock(),e.createElementBlock("div",Mn,[t.layout==="masonry"?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["masonry-layout",r.value,"gap-4 sm:gap-6"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,m=>(e.openBlock(),e.createElementBlock("div",{key:m.id+"-masonry",class:"mb-4 sm:mb-6 break-inside-avoid group cursor-pointer product-card",onClick:k=>d(m.id)},[e.createElementVNode("div",Pn,[e.createElementVNode("div",jn,[e.createElementVNode("img",{src:m.image,alt:m.name,loading:"lazy",class:"w-full h-auto object-cover transition-transform duration-300 group-hover:scale-[1.01]"},null,8,Vn),v[0]||(v[0]=e.createElementVNode("div",{class:"light-effect"},null,-1))]),m.label?(e.openBlock(),e.createElementBlock("div",Nn,[e.createElementVNode("span",Dn,e.toDisplayString(m.label),1)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",An,[e.createElementVNode("h3",Tn,e.toDisplayString(m.name),1),e.createElementVNode("div",zn,[e.createElementVNode("span",In,e.toDisplayString(m.price),1),e.createVNode(Me,{onClick:e.withModifiers(k=>g(m),["stop"]),type:"text",size:"small",class:"like-button !min-w-0 !p-1"},{default:e.withCtx(()=>[m.isWish?(e.openBlock(),e.createElementBlock("i",Ln)):(e.openBlock(),e.createElementBlock("i",On))]),_:2},1032,["onClick"])])])],8,Bn))),128))],2)):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["grid",i.value,"gap-4 lg:gap-6"])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,m=>(e.openBlock(),e.createElementBlock("div",{key:m.id+"-grid",class:"h-full"},[e.createElementVNode("div",{class:"py-2 px-2 group cursor-pointer product-card h-full flex flex-col",onClick:k=>d(m.id)},[e.createElementVNode("div",_n,[e.createElementVNode("div",Xn,[e.createElementVNode("img",{src:m.image,alt:m.name,class:"w-full h-full object-cover transition-transform duration-300",loading:"lazy"},null,8,Fn),v[1]||(v[1]=e.createElementVNode("div",{class:"light-effect"},null,-1))]),m.label?(e.openBlock(),e.createElementBlock("div",Hn,[e.createElementVNode("span",Wn,e.toDisplayString(m.label),1)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",Rn,[e.createElementVNode("h3",Gn,e.toDisplayString(m.name),1),e.createElementVNode("div",Un,[e.createElementVNode("span",Kn,e.toDisplayString(m.price),1),e.createVNode(Me,{onClick:e.withModifiers(k=>g(m),["stop"]),type:"text",size:"small",class:"like-button !min-w-0 !p-1"},{default:e.withCtx(()=>[m.isWish?(e.openBlock(),e.createBlock(e.unref(K),{key:1,icon:"bi:heart-fill",class:"bi bi-heart-fill text-[#FE374F] text-lg"})):(e.openBlock(),e.createBlock(e.unref(K),{key:0,icon:"bi:heart",class:"bi bi-heart text-gray-500 text-lg"}))]),_:2},1032,["onClick"])])])],8,Yn)]))),128))],2))]))}}),Zn=Z(qn,[["__scopeId","data-v-9eac2a47"]]),Qn=[{name:"Afghanistan",code:"AF",flagEmoji:"🇦🇫",flagSvg:"https://flagcdn.com/af.svg",flagPng:"https://flagcdn.com/w40/af.png",phoneCode:"+93",phonelengthMAX:10},{name:"Åland Islands",code:"AX",flagEmoji:"🇦🇽",flagSvg:"https://flagcdn.com/ax.svg",flagPng:"https://flagcdn.com/w40/ax.png",phoneCode:"+358",phonelengthMAX:10},{name:"Albania",code:"AL",flagEmoji:"🇦🇱",flagSvg:"https://flagcdn.com/al.svg",flagPng:"https://flagcdn.com/w40/al.png",phoneCode:"+355",phonelengthMAX:10},{name:"Algeria",code:"DZ",flagEmoji:"🇩🇿",flagSvg:"https://flagcdn.com/dz.svg",flagPng:"https://flagcdn.com/w40/dz.png",phoneCode:"+213",phonelengthMAX:10},{name:"American Samoa",code:"AS",flagEmoji:"🇦🇸",flagSvg:"https://flagcdn.com/as.svg",flagPng:"https://flagcdn.com/w40/as.png",phoneCode:"+1684",phonelengthMAX:10},{name:"Andorra",code:"AD",flagEmoji:"🇦🇩",flagSvg:"https://flagcdn.com/ad.svg",flagPng:"https://flagcdn.com/w40/ad.png",phoneCode:"+376",phonelengthMAX:10},{name:"Angola",code:"AO",flagEmoji:"🇦🇴",flagSvg:"https://flagcdn.com/ao.svg",flagPng:"https://flagcdn.com/w40/ao.png",phoneCode:"+244",phonelengthMAX:10},{name:"Anguilla",code:"AI",flagEmoji:"🇦🇮",flagSvg:"https://flagcdn.com/ai.svg",flagPng:"https://flagcdn.com/w40/ai.png",phoneCode:"+1264",phonelengthMAX:10},{name:"Antarctica",code:"AQ",flagEmoji:"🇦🇶",flagSvg:"https://flagcdn.com/aq.svg",flagPng:"https://flagcdn.com/w40/aq.png",phoneCode:"+672",phonelengthMAX:10},{name:"Antigua and Barbuda",code:"AG",flagEmoji:"🇦🇬",flagSvg:"https://flagcdn.com/ag.svg",flagPng:"https://flagcdn.com/w40/ag.png",phoneCode:"+1268",phonelengthMAX:10},{name:"Argentina",code:"AR",flagEmoji:"🇦🇷",flagSvg:"https://flagcdn.com/ar.svg",flagPng:"https://flagcdn.com/w40/ar.png",phoneCode:"+54",phonelengthMAX:10},{name:"Armenia",code:"AM",flagEmoji:"🇦🇲",flagSvg:"https://flagcdn.com/am.svg",flagPng:"https://flagcdn.com/w40/am.png",phoneCode:"+374",phonelengthMAX:10},{name:"Aruba",code:"AW",flagEmoji:"🇦🇼",flagSvg:"https://flagcdn.com/aw.svg",flagPng:"https://flagcdn.com/w40/aw.png",phoneCode:"+297",phonelengthMAX:10},{name:"Australia",code:"AU",flagEmoji:"🇦🇺",flagSvg:"https://flagcdn.com/au.svg",flagPng:"https://flagcdn.com/w40/au.png",phoneCode:"+61",phonelengthMAX:10},{name:"Austria",code:"AT",flagEmoji:"🇦🇹",flagSvg:"https://flagcdn.com/at.svg",flagPng:"https://flagcdn.com/w40/at.png",phoneCode:"+43",phonelengthMAX:10},{name:"Azerbaijan",code:"AZ",flagEmoji:"🇦🇿",flagSvg:"https://flagcdn.com/az.svg",flagPng:"https://flagcdn.com/w40/az.png",phoneCode:"+994",phonelengthMAX:10},{name:"Bahamas",code:"BS",flagEmoji:"🇧🇸",flagSvg:"https://flagcdn.com/bs.svg",flagPng:"https://flagcdn.com/w40/bs.png",phoneCode:"+1242",phonelengthMAX:10},{name:"Bahrain",code:"BH",flagEmoji:"🇧🇭",flagSvg:"https://flagcdn.com/bh.svg",flagPng:"https://flagcdn.com/w40/bh.png",phoneCode:"+973",phonelengthMAX:10},{name:"Bangladesh",code:"BD",flagEmoji:"🇧🇩",flagSvg:"https://flagcdn.com/bd.svg",flagPng:"https://flagcdn.com/w40/bd.png",phoneCode:"+880",phonelengthMAX:10},{name:"Barbados",code:"BB",flagEmoji:"🇧🇧",flagSvg:"https://flagcdn.com/bb.svg",flagPng:"https://flagcdn.com/w40/bb.png",phoneCode:"+1246",phonelengthMAX:10},{name:"Belarus",code:"BY",flagEmoji:"🇧🇾",flagSvg:"https://flagcdn.com/by.svg",flagPng:"https://flagcdn.com/w40/by.png",phoneCode:"+375",phonelengthMAX:10},{name:"Belgium",code:"BE",flagEmoji:"🇧🇪",flagSvg:"https://flagcdn.com/be.svg",flagPng:"https://flagcdn.com/w40/be.png",phoneCode:"+32",phonelengthMAX:10},{name:"Belize",code:"BZ",flagEmoji:"🇧🇿",flagSvg:"https://flagcdn.com/bz.svg",flagPng:"https://flagcdn.com/w40/bz.png",phoneCode:"+501",phonelengthMAX:10},{name:"Benin",code:"BJ",flagEmoji:"🇧🇯",flagSvg:"https://flagcdn.com/bj.svg",flagPng:"https://flagcdn.com/w40/bj.png",phoneCode:"+229",phonelengthMAX:10},{name:"Bermuda",code:"BM",flagEmoji:"🇧🇲",flagSvg:"https://flagcdn.com/bm.svg",flagPng:"https://flagcdn.com/w40/bm.png",phoneCode:"+1441",phonelengthMAX:10},{name:"Bhutan",code:"BT",flagEmoji:"🇧🇹",flagSvg:"https://flagcdn.com/bt.svg",flagPng:"https://flagcdn.com/w40/bt.png",phoneCode:"+975",phonelengthMAX:10},{name:"Bolivia (Plurinational State of)",code:"BO",flagEmoji:"🇧🇴",flagSvg:"https://flagcdn.com/bo.svg",flagPng:"https://flagcdn.com/w40/bo.png",phoneCode:"+591",phonelengthMAX:10},{name:"Bonaire, Sint Eustatius and Saba",code:"BQ",flagEmoji:"🇧🇶",flagSvg:"https://flagcdn.com/bq.svg",flagPng:"https://flagcdn.com/w40/bq.png",phoneCode:"+5997",phonelengthMAX:10},{name:"Bosnia and Herzegovina",code:"BA",flagEmoji:"🇧🇦",flagSvg:"https://flagcdn.com/ba.svg",flagPng:"https://flagcdn.com/w40/ba.png",phoneCode:"+387",phonelengthMAX:10},{name:"Botswana",code:"BW",flagEmoji:"🇧🇼",flagSvg:"https://flagcdn.com/bw.svg",flagPng:"https://flagcdn.com/w40/bw.png",phoneCode:"+267",phonelengthMAX:10},{name:"Bouvet Island",code:"BV",flagEmoji:"🇧🇻",flagSvg:"https://flagcdn.com/bv.svg",flagPng:"https://flagcdn.com/w40/bv.png",phoneCode:"+55",phonelengthMAX:10},{name:"Brazil",code:"BR",flagEmoji:"🇧🇷",flagSvg:"https://flagcdn.com/br.svg",flagPng:"https://flagcdn.com/w40/br.png",phoneCode:"+55",phonelengthMAX:10},{name:"British Indian Ocean Territory",code:"IO",flagEmoji:"🇮🇴",flagSvg:"https://flagcdn.com/io.svg",flagPng:"https://flagcdn.com/w40/io.png",phoneCode:"+246",phonelengthMAX:10},{name:"Brunei Darussalam",code:"BN",flagEmoji:"🇧🇳",flagSvg:"https://flagcdn.com/bn.svg",flagPng:"https://flagcdn.com/w40/bn.png",phoneCode:"+673",phonelengthMAX:10},{name:"Bulgaria",code:"BG",flagEmoji:"🇧🇬",flagSvg:"https://flagcdn.com/bg.svg",flagPng:"https://flagcdn.com/w40/bg.png",phoneCode:"+359",phonelengthMAX:10},{name:"Burkina Faso",code:"BF",flagEmoji:"🇧🇫",flagSvg:"https://flagcdn.com/bf.svg",flagPng:"https://flagcdn.com/w40/bf.png",phoneCode:"+226",phonelengthMAX:10},{name:"Burundi",code:"BI",flagEmoji:"🇧🇮",flagSvg:"https://flagcdn.com/bi.svg",flagPng:"https://flagcdn.com/w40/bi.png",phoneCode:"+257",phonelengthMAX:10},{name:"Cabo Verde",code:"CV",flagEmoji:"🇨🇻",flagSvg:"https://flagcdn.com/cv.svg",flagPng:"https://flagcdn.com/w40/cv.png",phoneCode:"+238",phonelengthMAX:10},{name:"Cambodia",code:"KH",flagEmoji:"🇰🇭",flagSvg:"https://flagcdn.com/kh.svg",flagPng:"https://flagcdn.com/w40/kh.png",phoneCode:"+855",phonelengthMAX:10},{name:"Cameroon",code:"CM",flagEmoji:"🇨🇲",flagSvg:"https://flagcdn.com/cm.svg",flagPng:"https://flagcdn.com/w40/cm.png",phoneCode:"+237",phonelengthMAX:10},{name:"Canada",code:"CA",flagEmoji:"🇨🇦",flagSvg:"https://flagcdn.com/ca.svg",flagPng:"https://flagcdn.com/w40/ca.png",phoneCode:"+1",phonelengthMAX:10},{name:"Cayman Islands",code:"KY",flagEmoji:"🇰🇾",flagSvg:"https://flagcdn.com/ky.svg",flagPng:"https://flagcdn.com/w40/ky.png",phoneCode:"+1345",phonelengthMAX:10},{name:"Central African Republic",code:"CF",flagEmoji:"🇨🇫",flagSvg:"https://flagcdn.com/cf.svg",flagPng:"https://flagcdn.com/w40/cf.png",phoneCode:"+236",phonelengthMAX:10},{name:"Chad",code:"TD",flagEmoji:"🇹🇩",flagSvg:"https://flagcdn.com/td.svg",flagPng:"https://flagcdn.com/w40/td.png",phoneCode:"+235",phonelengthMAX:10},{name:"Chile",code:"CL",flagEmoji:"🇨🇱",flagSvg:"https://flagcdn.com/cl.svg",flagPng:"https://flagcdn.com/w40/cl.png",phoneCode:"+56",phonelengthMAX:10},{name:"China",code:"CN",flagEmoji:"🇨🇳",flagSvg:"https://flagcdn.com/cn.svg",flagPng:"https://flagcdn.com/w40/cn.png",phoneCode:"+86",phonelengthMAX:11},{name:"Christmas Island",code:"CX",flagEmoji:"🇨🇽",flagSvg:"https://flagcdn.com/cx.svg",flagPng:"https://flagcdn.com/w40/cx.png",phoneCode:"+61",phonelengthMAX:10},{name:"Cocos (Keeling) Islands",code:"CC",flagEmoji:"🇨🇨",flagSvg:"https://flagcdn.com/cc.svg",flagPng:"https://flagcdn.com/w40/cc.png",phoneCode:"+61",phonelengthMAX:10},{name:"Colombia",code:"CO",flagEmoji:"🇨🇴",flagSvg:"https://flagcdn.com/co.svg",flagPng:"https://flagcdn.com/w40/co.png",phoneCode:"+57",phonelengthMAX:10},{name:"Comoros",code:"KM",flagEmoji:"🇰🇲",flagSvg:"https://flagcdn.com/km.svg",flagPng:"https://flagcdn.com/w40/km.png",phoneCode:"+269",phonelengthMAX:10},{name:"Congo",code:"CG",flagEmoji:"🇨🇬",flagSvg:"https://flagcdn.com/cg.svg",flagPng:"https://flagcdn.com/w40/cg.png",phoneCode:"+242",phonelengthMAX:10},{name:"Congo, Democratic Republic of the",code:"CD",flagEmoji:"🇨🇩",flagSvg:"https://flagcdn.com/cd.svg",flagPng:"https://flagcdn.com/w40/cd.png",phoneCode:"+243",phonelengthMAX:10},{name:"Cook Islands",code:"CK",flagEmoji:"🇨🇰",flagSvg:"https://flagcdn.com/ck.svg",flagPng:"https://flagcdn.com/w40/ck.png",phoneCode:"+682",phonelengthMAX:10},{name:"Costa Rica",code:"CR",flagEmoji:"🇨🇷",flagSvg:"https://flagcdn.com/cr.svg",flagPng:"https://flagcdn.com/w40/cr.png",phoneCode:"+506",phonelengthMAX:10},{name:"Croatia",code:"HR",flagEmoji:"🇭🇷",flagSvg:"https://flagcdn.com/hr.svg",flagPng:"https://flagcdn.com/w40/hr.png",phoneCode:"+385",phonelengthMAX:10},{name:"Cuba",code:"CU",flagEmoji:"🇨🇺",flagSvg:"https://flagcdn.com/cu.svg",flagPng:"https://flagcdn.com/w40/cu.png",phoneCode:"+53",phonelengthMAX:10},{name:"Curaçao",code:"CW",flagEmoji:"🇨🇼",flagSvg:"https://flagcdn.com/cw.svg",flagPng:"https://flagcdn.com/w40/cw.png",phoneCode:"+5999",phonelengthMAX:10},{name:"Cyprus",code:"CY",flagEmoji:"🇨🇾",flagSvg:"https://flagcdn.com/cy.svg",flagPng:"https://flagcdn.com/w40/cy.png",phoneCode:"+357",phonelengthMAX:10},{name:"Czechia",code:"CZ",flagEmoji:"🇨🇿",flagSvg:"https://flagcdn.com/cz.svg",flagPng:"https://flagcdn.com/w40/cz.png",phoneCode:"+420",phonelengthMAX:10},{name:"Denmark",code:"DK",flagEmoji:"🇩🇰",flagSvg:"https://flagcdn.com/dk.svg",flagPng:"https://flagcdn.com/w40/dk.png",phoneCode:"+45",phonelengthMAX:10},{name:"Djibouti",code:"DJ",flagEmoji:"🇩🇯",flagSvg:"https://flagcdn.com/dj.svg",flagPng:"https://flagcdn.com/w40/dj.png",phoneCode:"+253",phonelengthMAX:10},{name:"Dominica",code:"DM",flagEmoji:"🇩🇲",flagSvg:"https://flagcdn.com/dm.svg",flagPng:"https://flagcdn.com/w40/dm.png",phoneCode:"+1767",phonelengthMAX:10},{name:"Dominican Republic",code:"DO",flagEmoji:"🇩🇴",flagSvg:"https://flagcdn.com/do.svg",flagPng:"https://flagcdn.com/w40/do.png",phoneCode:"+1809",phonelengthMAX:10},{name:"Ecuador",code:"EC",flagEmoji:"🇪🇨",flagSvg:"https://flagcdn.com/ec.svg",flagPng:"https://flagcdn.com/w40/ec.png",phoneCode:"+593",phonelengthMAX:10},{name:"Egypt",code:"EG",flagEmoji:"🇪🇬",flagSvg:"https://flagcdn.com/eg.svg",flagPng:"https://flagcdn.com/w40/eg.png",phoneCode:"+20",phonelengthMAX:10},{name:"El Salvador",code:"SV",flagEmoji:"🇸🇻",flagSvg:"https://flagcdn.com/sv.svg",flagPng:"https://flagcdn.com/w40/sv.png",phoneCode:"+503",phonelengthMAX:10},{name:"Equatorial Guinea",code:"GQ",flagEmoji:"🇬🇶",flagSvg:"https://flagcdn.com/gq.svg",flagPng:"https://flagcdn.com/w40/gq.png",phoneCode:"+240",phonelengthMAX:10},{name:"Eritrea",code:"ER",flagEmoji:"🇪🇷",flagSvg:"https://flagcdn.com/er.svg",flagPng:"https://flagcdn.com/w40/er.png",phoneCode:"+291",phonelengthMAX:10},{name:"Estonia",code:"EE",flagEmoji:"🇪🇪",flagSvg:"https://flagcdn.com/ee.svg",flagPng:"https://flagcdn.com/w40/ee.png",phoneCode:"+372",phonelengthMAX:10},{name:"Eswatini",code:"SZ",flagEmoji:"🇸🇿",flagSvg:"https://flagcdn.com/sz.svg",flagPng:"https://flagcdn.com/w40/sz.png",phoneCode:"+268",phonelengthMAX:10},{name:"Ethiopia",code:"ET",flagEmoji:"🇪🇹",flagSvg:"https://flagcdn.com/et.svg",flagPng:"https://flagcdn.com/w40/et.png",phoneCode:"+251",phonelengthMAX:10},{name:"Falkland Islands (Malvinas)",code:"FK",flagEmoji:"🇫🇰",flagSvg:"https://flagcdn.com/fk.svg",flagPng:"https://flagcdn.com/w40/fk.png",phoneCode:"+500",phonelengthMAX:10},{name:"Faroe Islands",code:"FO",flagEmoji:"🇫🇴",flagSvg:"https://flagcdn.com/fo.svg",flagPng:"https://flagcdn.com/w40/fo.png",phoneCode:"+298",phonelengthMAX:10},{name:"Fiji",code:"FJ",flagEmoji:"🇫🇯",flagSvg:"https://flagcdn.com/fj.svg",flagPng:"https://flagcdn.com/w40/fj.png",phoneCode:"+679",phonelengthMAX:10},{name:"Finland",code:"FI",flagEmoji:"🇫🇮",flagSvg:"https://flagcdn.com/fi.svg",flagPng:"https://flagcdn.com/w40/fi.png",phoneCode:"+358",phonelengthMAX:10},{name:"France",code:"FR",flagEmoji:"🇫🇷",flagSvg:"https://flagcdn.com/fr.svg",flagPng:"https://flagcdn.com/w40/fr.png",phoneCode:"+33",phonelengthMAX:10},{name:"French Guiana",code:"GF",flagEmoji:"🇬🇫",flagSvg:"https://flagcdn.com/gf.svg",flagPng:"https://flagcdn.com/w40/gf.png",phoneCode:"+594",phonelengthMAX:10},{name:"French Polynesia",code:"PF",flagEmoji:"🇵🇫",flagSvg:"https://flagcdn.com/pf.svg",flagPng:"https://flagcdn.com/w40/pf.png",phoneCode:"+689",phonelengthMAX:10},{name:"French Southern Territories",code:"TF",flagEmoji:"🇹🇫",flagSvg:"https://flagcdn.com/tf.svg",flagPng:"https://flagcdn.com/w40/tf.png",phoneCode:"+262",phonelengthMAX:10},{name:"Gabon",code:"GA",flagEmoji:"🇬🇦",flagSvg:"https://flagcdn.com/ga.svg",flagPng:"https://flagcdn.com/w40/ga.png",phoneCode:"+241",phonelengthMAX:10},{name:"Gambia",code:"GM",flagEmoji:"🇬🇲",flagSvg:"https://flagcdn.com/gm.svg",flagPng:"https://flagcdn.com/w40/gm.png",phoneCode:"+220",phonelengthMAX:10},{name:"Georgia",code:"GE",flagEmoji:"🇬🇪",flagSvg:"https://flagcdn.com/ge.svg",flagPng:"https://flagcdn.com/w40/ge.png",phoneCode:"+995",phonelengthMAX:10},{name:"Germany",code:"DE",flagEmoji:"🇩🇪",flagSvg:"https://flagcdn.com/de.svg",flagPng:"https://flagcdn.com/w40/de.png",phoneCode:"+49",phonelengthMAX:10},{name:"Ghana",code:"GH",flagEmoji:"🇬🇭",flagSvg:"https://flagcdn.com/gh.svg",flagPng:"https://flagcdn.com/w40/gh.png",phoneCode:"+233",phonelengthMAX:10},{name:"Gibraltar",code:"GI",flagEmoji:"🇬🇮",flagSvg:"https://flagcdn.com/gi.svg",flagPng:"https://flagcdn.com/w40/gi.png",phoneCode:"+350",phonelengthMAX:10},{name:"Greece",code:"GR",flagEmoji:"🇬🇷",flagSvg:"https://flagcdn.com/gr.svg",flagPng:"https://flagcdn.com/w40/gr.png",phoneCode:"+30",phonelengthMAX:10},{name:"Greenland",code:"GL",flagEmoji:"🇬🇱",flagSvg:"https://flagcdn.com/gl.svg",flagPng:"https://flagcdn.com/w40/gl.png",phoneCode:"+299",phonelengthMAX:10},{name:"Grenada",code:"GD",flagEmoji:"🇬🇩",flagSvg:"https://flagcdn.com/gd.svg",flagPng:"https://flagcdn.com/w40/gd.png",phoneCode:"+1473",phonelengthMAX:10},{name:"Guadeloupe",code:"GP",flagEmoji:"🇬🇵",flagSvg:"https://flagcdn.com/gp.svg",flagPng:"https://flagcdn.com/w40/gp.png",phoneCode:"+590",phonelengthMAX:10},{name:"Guam",code:"GU",flagEmoji:"🇬🇺",flagSvg:"https://flagcdn.com/gu.svg",flagPng:"https://flagcdn.com/w40/gu.png",phoneCode:"+1671",phonelengthMAX:10},{name:"Guatemala",code:"GT",flagEmoji:"🇬🇹",flagSvg:"https://flagcdn.com/gt.svg",flagPng:"https://flagcdn.com/w40/gt.png",phoneCode:"+502",phonelengthMAX:10},{name:"Guernsey",code:"GG",flagEmoji:"🇬🇬",flagSvg:"https://flagcdn.com/gg.svg",flagPng:"https://flagcdn.com/w40/gg.png",phoneCode:"+44",phonelengthMAX:10},{name:"Guinea",code:"GN",flagEmoji:"🇬🇳",flagSvg:"https://flagcdn.com/gn.svg",flagPng:"https://flagcdn.com/w40/gn.png",phoneCode:"+224",phonelengthMAX:10},{name:"Guinea-Bissau",code:"GW",flagEmoji:"🇬🇼",flagSvg:"https://flagcdn.com/gw.svg",flagPng:"https://flagcdn.com/w40/gw.png",phoneCode:"+245",phonelengthMAX:10},{name:"Guyana",code:"GY",flagEmoji:"🇬🇾",flagSvg:"https://flagcdn.com/gy.svg",flagPng:"https://flagcdn.com/w40/gy.png",phoneCode:"+592",phonelengthMAX:10},{name:"Haiti",code:"HT",flagEmoji:"🇭🇹",flagSvg:"https://flagcdn.com/ht.svg",flagPng:"https://flagcdn.com/w40/ht.png",phoneCode:"+509",phonelengthMAX:10},{name:"Heard Island and McDonald Islands",code:"HM",flagEmoji:"🇭🇲",flagSvg:"https://flagcdn.com/hm.svg",flagPng:"https://flagcdn.com/w40/hm.png",phoneCode:"+672"},{name:"Holy See",code:"VA",flagEmoji:"🇻🇦",flagSvg:"https://flagcdn.com/va.svg",flagPng:"https://flagcdn.com/w40/va.png",phoneCode:"+39"},{name:"Honduras",code:"HN",flagEmoji:"🇭🇳",flagSvg:"https://flagcdn.com/hn.svg",flagPng:"https://flagcdn.com/w40/hn.png",phoneCode:"+504"},{name:"Hong Kong",code:"HK",flagEmoji:"🇭🇰",flagSvg:"https://flagcdn.com/hk.svg",flagPng:"https://flagcdn.com/w40/hk.png",phoneCode:"+852"},{name:"Hungary",code:"HU",flagEmoji:"🇭🇺",flagSvg:"https://flagcdn.com/hu.svg",flagPng:"https://flagcdn.com/w40/hu.png",phoneCode:"+36"},{name:"Iceland",code:"IS",flagEmoji:"🇮🇸",flagSvg:"https://flagcdn.com/is.svg",flagPng:"https://flagcdn.com/w40/is.png",phoneCode:"+354"},{name:"India",code:"IN",flagEmoji:"🇮🇳",flagSvg:"https://flagcdn.com/in.svg",flagPng:"https://flagcdn.com/w40/in.png",phoneCode:"+91"},{name:"Indonesia",code:"ID",flagEmoji:"🇮🇩",flagSvg:"https://flagcdn.com/id.svg",flagPng:"https://flagcdn.com/w40/id.png",phoneCode:"+62"},{name:"Iran (Islamic Republic of)",code:"IR",flagEmoji:"🇮🇷",flagSvg:"https://flagcdn.com/ir.svg",flagPng:"https://flagcdn.com/w40/ir.png",phoneCode:"+98"},{name:"Iraq",code:"IQ",flagEmoji:"🇮🇶",flagSvg:"https://flagcdn.com/iq.svg",flagPng:"https://flagcdn.com/w40/iq.png",phoneCode:"+964"},{name:"Ireland",code:"IE",flagEmoji:"🇮🇪",flagSvg:"https://flagcdn.com/ie.svg",flagPng:"https://flagcdn.com/w40/ie.png",phoneCode:"+353"},{name:"Isle of Man",code:"IM",flagEmoji:"🇮🇲",flagSvg:"https://flagcdn.com/im.svg",flagPng:"https://flagcdn.com/w40/im.png",phoneCode:"+44"},{name:"Israel",code:"IL",flagEmoji:"🇮🇱",flagSvg:"https://flagcdn.com/il.svg",flagPng:"https://flagcdn.com/w40/il.png",phoneCode:"+972"},{name:"Italy",code:"IT",flagEmoji:"🇮🇹",flagSvg:"https://flagcdn.com/it.svg",flagPng:"https://flagcdn.com/w40/it.png",phoneCode:"+39"},{name:"Jamaica",code:"JM",flagEmoji:"🇯🇲",flagSvg:"https://flagcdn.com/jm.svg",flagPng:"https://flagcdn.com/w40/jm.png",phoneCode:"+1876"},{name:"Japan",code:"JP",flagEmoji:"🇯🇵",flagSvg:"https://flagcdn.com/jp.svg",flagPng:"https://flagcdn.com/w40/jp.png",phoneCode:"+81"},{name:"Jersey",code:"JE",flagEmoji:"🇯🇪",flagSvg:"https://flagcdn.com/je.svg",flagPng:"https://flagcdn.com/w40/je.png",phoneCode:"+44"},{name:"Jordan",code:"JO",flagEmoji:"🇯🇴",flagSvg:"https://flagcdn.com/jo.svg",flagPng:"https://flagcdn.com/w40/jo.png",phoneCode:"+962"},{name:"Kazakhstan",code:"KZ",flagEmoji:"🇰🇿",flagSvg:"https://flagcdn.com/kz.svg",flagPng:"https://flagcdn.com/w40/kz.png",phoneCode:"+7"},{name:"Kenya",code:"KE",flagEmoji:"🇰🇪",flagSvg:"https://flagcdn.com/ke.svg",flagPng:"https://flagcdn.com/w40/ke.png",phoneCode:"+254"},{name:"Kiribati",code:"KI",flagEmoji:"🇰🇮",flagSvg:"https://flagcdn.com/ki.svg",flagPng:"https://flagcdn.com/w40/ki.png",phoneCode:"+686"},{name:"Korea (Democratic People's Republic of)",code:"KP",flagEmoji:"🇰🇵",flagSvg:"https://flagcdn.com/kp.svg",flagPng:"https://flagcdn.com/w40/kp.png",phoneCode:"+850"},{name:"Korea, Republic of",code:"KR",flagEmoji:"🇰🇷",flagSvg:"https://flagcdn.com/kr.svg",flagPng:"https://flagcdn.com/w40/kr.png",phoneCode:"+82"},{name:"Kuwait",code:"KW",flagEmoji:"🇰🇼",flagSvg:"https://flagcdn.com/kw.svg",flagPng:"https://flagcdn.com/w40/kw.png",phoneCode:"+965"},{name:"Kyrgyzstan",code:"KG",flagEmoji:"🇰🇬",flagSvg:"https://flagcdn.com/kg.svg",flagPng:"https://flagcdn.com/w40/kg.png",phoneCode:"+996"},{name:"Lao People's Democratic Republic",code:"LA",flagEmoji:"🇱🇦",flagSvg:"https://flagcdn.com/la.svg",flagPng:"https://flagcdn.com/w40/la.png",phoneCode:"+856"},{name:"Latvia",code:"LV",flagEmoji:"🇱🇻",flagSvg:"https://flagcdn.com/lv.svg",flagPng:"https://flagcdn.com/w40/lv.png",phoneCode:"+371"},{name:"Lebanon",code:"LB",flagEmoji:"🇱🇧",flagSvg:"https://flagcdn.com/lb.svg",flagPng:"https://flagcdn.com/w40/lb.png",phoneCode:"+961"},{name:"Lesotho",code:"LS",flagEmoji:"🇱🇸",flagSvg:"https://flagcdn.com/ls.svg",flagPng:"https://flagcdn.com/w40/ls.png",phoneCode:"+266"},{name:"Liberia",code:"LR",flagEmoji:"🇱🇷",flagSvg:"https://flagcdn.com/lr.svg",flagPng:"https://flagcdn.com/w40/lr.png",phoneCode:"+231"},{name:"Libya",code:"LY",flagEmoji:"🇱🇾",flagSvg:"https://flagcdn.com/ly.svg",flagPng:"https://flagcdn.com/w40/ly.png",phoneCode:"+218"},{name:"Liechtenstein",code:"LI",flagEmoji:"🇱🇮",flagSvg:"https://flagcdn.com/li.svg",flagPng:"https://flagcdn.com/w40/li.png",phoneCode:"+423"},{name:"Lithuania",code:"LT",flagEmoji:"🇱🇹",flagSvg:"https://flagcdn.com/lt.svg",flagPng:"https://flagcdn.com/w40/lt.png",phoneCode:"+370"},{name:"Luxembourg",code:"LU",flagEmoji:"🇱🇺",flagSvg:"https://flagcdn.com/lu.svg",flagPng:"https://flagcdn.com/w40/lu.png",phoneCode:"+352"},{name:"Macao",code:"MO",flagEmoji:"🇲🇴",flagSvg:"https://flagcdn.com/mo.svg",flagPng:"https://flagcdn.com/w40/mo.png",phoneCode:"+853"},{name:"Madagascar",code:"MG",flagEmoji:"🇲🇬",flagSvg:"https://flagcdn.com/mg.svg",flagPng:"https://flagcdn.com/w40/mg.png",phoneCode:"+261"},{name:"Malawi",code:"MW",flagEmoji:"🇲🇼",flagSvg:"https://flagcdn.com/mw.svg",flagPng:"https://flagcdn.com/w40/mw.png",phoneCode:"+265"},{name:"Malaysia",code:"MY",flagEmoji:"🇲🇾",flagSvg:"https://flagcdn.com/my.svg",flagPng:"https://flagcdn.com/w40/my.png",phoneCode:"+60"},{name:"Maldives",code:"MV",flagEmoji:"🇲🇻",flagSvg:"https://flagcdn.com/mv.svg",flagPng:"https://flagcdn.com/w40/mv.png",phoneCode:"+960"},{name:"Mali",code:"ML",flagEmoji:"🇲🇱",flagSvg:"https://flagcdn.com/ml.svg",flagPng:"https://flagcdn.com/w40/ml.png",phoneCode:"+223"},{name:"Malta",code:"MT",flagEmoji:"🇲🇹",flagSvg:"https://flagcdn.com/mt.svg",flagPng:"https://flagcdn.com/w40/mt.png",phoneCode:"+356"},{name:"Marshall Islands",code:"MH",flagEmoji:"🇲🇭",flagSvg:"https://flagcdn.com/mh.svg",flagPng:"https://flagcdn.com/w40/mh.png",phoneCode:"+692"},{name:"Martinique",code:"MQ",flagEmoji:"🇲🇶",flagSvg:"https://flagcdn.com/mq.svg",flagPng:"https://flagcdn.com/w40/mq.png",phoneCode:"+596"},{name:"Mauritania",code:"MR",flagEmoji:"🇲🇷",flagSvg:"https://flagcdn.com/mr.svg",flagPng:"https://flagcdn.com/w40/mr.png",phoneCode:"+222"},{name:"Mauritius",code:"MU",flagEmoji:"🇲🇺",flagSvg:"https://flagcdn.com/mu.svg",flagPng:"https://flagcdn.com/w40/mu.png",phoneCode:"+230"},{name:"Mayotte",code:"YT",flagEmoji:"🇾🇹",flagSvg:"https://flagcdn.com/yt.svg",flagPng:"https://flagcdn.com/w40/yt.png",phoneCode:"+262"},{name:"Mexico",code:"MX",flagEmoji:"🇲🇽",flagSvg:"https://flagcdn.com/mx.svg",flagPng:"https://flagcdn.com/w40/mx.png",phoneCode:"+52"},{name:"Micronesia (Federated States of)",code:"FM",flagEmoji:"🇫🇲",flagSvg:"https://flagcdn.com/fm.svg",flagPng:"https://flagcdn.com/w40/fm.png",phoneCode:"+691"},{name:"Moldova, Republic of",code:"MD",flagEmoji:"🇲🇩",flagSvg:"https://flagcdn.com/md.svg",flagPng:"https://flagcdn.com/w40/md.png",phoneCode:"+373"},{name:"Monaco",code:"MC",flagEmoji:"🇲🇨",flagSvg:"https://flagcdn.com/mc.svg",flagPng:"https://flagcdn.com/w40/mc.png",phoneCode:"+377",phonelengthMAX:10},{name:"Mongolia",code:"MN",flagEmoji:"🇲🇳",flagSvg:"https://flagcdn.com/mn.svg",flagPng:"https://flagcdn.com/w40/mn.png",phoneCode:"+976"},{name:"Montenegro",code:"ME",flagEmoji:"🇲🇪",flagSvg:"https://flagcdn.com/me.svg",flagPng:"https://flagcdn.com/w40/me.png",phoneCode:"+382"},{name:"Montserrat",code:"MS",flagEmoji:"🇲🇸",flagSvg:"https://flagcdn.com/ms.svg",flagPng:"https://flagcdn.com/w40/ms.png",phoneCode:"+1664"},{name:"Morocco",code:"MA",flagEmoji:"🇲🇦",flagSvg:"https://flagcdn.com/ma.svg",flagPng:"https://flagcdn.com/w40/ma.png",phoneCode:"+212"},{name:"Mozambique",code:"MZ",flagEmoji:"🇲🇿",flagSvg:"https://flagcdn.com/mz.svg",flagPng:"https://flagcdn.com/w40/mz.png",phoneCode:"+258"},{name:"Myanmar",code:"MM",flagEmoji:"🇲🇲",flagSvg:"https://flagcdn.com/mm.svg",flagPng:"https://flagcdn.com/w40/mm.png",phoneCode:"+95"},{name:"Namibia",code:"NA",flagEmoji:"🇳🇦",flagSvg:"https://flagcdn.com/na.svg",flagPng:"https://flagcdn.com/w40/na.png",phoneCode:"+264"},{name:"Nauru",code:"NR",flagEmoji:"🇳🇷",flagSvg:"https://flagcdn.com/nr.svg",flagPng:"https://flagcdn.com/w40/nr.png",phoneCode:"+674"},{name:"Nepal",code:"NP",flagEmoji:"🇳🇵",flagSvg:"https://flagcdn.com/np.svg",flagPng:"https://flagcdn.com/w40/np.png",phoneCode:"+977"},{name:"Netherlands",code:"NL",flagEmoji:"🇳🇱",flagSvg:"https://flagcdn.com/nl.svg",flagPng:"https://flagcdn.com/w40/nl.png",phoneCode:"+31"},{name:"New Caledonia",code:"NC",flagEmoji:"🇳🇨",flagSvg:"https://flagcdn.com/nc.svg",flagPng:"https://flagcdn.com/w40/nc.png",phoneCode:"+687"},{name:"New Zealand",code:"NZ",flagEmoji:"🇳🇿",flagSvg:"https://flagcdn.com/nz.svg",flagPng:"https://flagcdn.com/w40/nz.png",phoneCode:"+64"},{name:"Nicaragua",code:"NI",flagEmoji:"🇳🇮",flagSvg:"https://flagcdn.com/ni.svg",flagPng:"https://flagcdn.com/w40/ni.png",phoneCode:"+505"},{name:"Niger",code:"NE",flagEmoji:"🇳🇪",flagSvg:"https://flagcdn.com/ne.svg",flagPng:"https://flagcdn.com/w40/ne.png",phoneCode:"+227"},{name:"Nigeria",code:"NG",flagEmoji:"🇳🇬",flagSvg:"https://flagcdn.com/ng.svg",flagPng:"https://flagcdn.com/w40/ng.png",phoneCode:"+234"},{name:"Niue",code:"NU",flagEmoji:"🇳🇺",flagSvg:"https://flagcdn.com/nu.svg",flagPng:"https://flagcdn.com/w40/nu.png",phoneCode:"+683"},{name:"Norfolk Island",code:"NF",flagEmoji:"🇳🇫",flagSvg:"https://flagcdn.com/nf.svg",flagPng:"https://flagcdn.com/w40/nf.png",phoneCode:"+672"},{name:"North Macedonia",code:"MK",flagEmoji:"🇲🇰",flagSvg:"https://flagcdn.com/mk.svg",flagPng:"https://flagcdn.com/w40/mk.png",phoneCode:"+389"},{name:"Northern Mariana Islands",code:"MP",flagEmoji:"🇲🇵",flagSvg:"https://flagcdn.com/mp.svg",flagPng:"https://flagcdn.com/w40/mp.png",phoneCode:"+1670"},{name:"Norway",code:"NO",flagEmoji:"🇳🇴",flagSvg:"https://flagcdn.com/no.svg",flagPng:"https://flagcdn.com/w40/no.png",phoneCode:"+47"},{name:"Oman",code:"OM",flagEmoji:"🇴🇲",flagSvg:"https://flagcdn.com/om.svg",flagPng:"https://flagcdn.com/w40/om.png",phoneCode:"+968"},{name:"Pakistan",code:"PK",flagEmoji:"🇵🇰",flagSvg:"https://flagcdn.com/pk.svg",flagPng:"https://flagcdn.com/w40/pk.png",phoneCode:"+92"},{name:"Palau",code:"PW",flagEmoji:"🇵🇼",flagSvg:"https://flagcdn.com/pw.svg",flagPng:"https://flagcdn.com/w40/pw.png",phoneCode:"+680"},{name:"Palestine, State of",code:"PS",flagEmoji:"🇵🇸",flagSvg:"https://flagcdn.com/ps.svg",flagPng:"https://flagcdn.com/w40/ps.png",phoneCode:"+970"},{name:"Panama",code:"PA",flagEmoji:"🇵🇦",flagSvg:"https://flagcdn.com/pa.svg",flagPng:"https://flagcdn.com/w40/pa.png",phoneCode:"+507"},{name:"Papua New Guinea",code:"PG",flagEmoji:"🇵🇬",flagSvg:"https://flagcdn.com/pg.svg",flagPng:"https://flagcdn.com/w40/pg.png",phoneCode:"+675"},{name:"Paraguay",code:"PY",flagEmoji:"🇵🇾",flagSvg:"https://flagcdn.com/py.svg",flagPng:"https://flagcdn.com/w40/py.png",phoneCode:"+595"},{name:"Peru",code:"PE",flagEmoji:"🇵🇪",flagSvg:"https://flagcdn.com/pe.svg",flagPng:"https://flagcdn.com/w40/pe.png",phoneCode:"+51"},{name:"Philippines",code:"PH",flagEmoji:"🇵🇭",flagSvg:"https://flagcdn.com/ph.svg",flagPng:"https://flagcdn.com/w40/ph.png",phoneCode:"+63"},{name:"Pitcairn",code:"PN",flagEmoji:"🇵🇳",flagSvg:"https://flagcdn.com/pn.svg",flagPng:"https://flagcdn.com/w40/pn.png",phoneCode:"+64"},{name:"Poland",code:"PL",flagEmoji:"🇵🇱",flagSvg:"https://flagcdn.com/pl.svg",flagPng:"https://flagcdn.com/w40/pl.png",phoneCode:"+48"},{name:"Portugal",code:"PT",flagEmoji:"🇵🇹",flagSvg:"https://flagcdn.com/pt.svg",flagPng:"https://flagcdn.com/w40/pt.png",phoneCode:"+351"},{name:"Puerto Rico",code:"PR",flagEmoji:"🇵🇷",flagSvg:"https://flagcdn.com/pr.svg",flagPng:"https://flagcdn.com/w40/pr.png",phoneCode:"+1787"},{name:"Qatar",code:"QA",flagEmoji:"🇶🇦",flagSvg:"https://flagcdn.com/qa.svg",flagPng:"https://flagcdn.com/w40/qa.png",phoneCode:"+974"},{name:"Réunion",code:"RE",flagEmoji:"🇷🇪",flagSvg:"https://flagcdn.com/re.svg",flagPng:"https://flagcdn.com/w40/re.png",phoneCode:"+262"},{name:"Romania",code:"RO",flagEmoji:"🇷🇴",flagSvg:"https://flagcdn.com/ro.svg",flagPng:"https://flagcdn.com/w40/ro.png",phoneCode:"+40"},{name:"Russian Federation",code:"RU",flagEmoji:"🇷🇺",flagSvg:"https://flagcdn.com/ru.svg",flagPng:"https://flagcdn.com/w40/ru.png",phoneCode:"+7"},{name:"Rwanda",code:"RW",flagEmoji:"🇷🇼",flagSvg:"https://flagcdn.com/rw.svg",flagPng:"https://flagcdn.com/w40/rw.png",phoneCode:"+250"},{name:"Saint Barthélemy",code:"BL",flagEmoji:"🇧🇱",flagSvg:"https://flagcdn.com/bl.svg",flagPng:"https://flagcdn.com/w40/bl.png",phoneCode:"+590"},{name:"Saint Helena, Ascension and Tristan da Cunha",code:"SH",flagEmoji:"🇸🇭",flagSvg:"https://flagcdn.com/sh.svg",flagPng:"https://flagcdn.com/w40/sh.png",phoneCode:"+290"},{name:"Saint Kitts and Nevis",code:"KN",flagEmoji:"🇰🇳",flagSvg:"https://flagcdn.com/kn.svg",flagPng:"https://flagcdn.com/w40/kn.png",phoneCode:"+1869"},{name:"Saint Lucia",code:"LC",flagEmoji:"🇱🇨",flagSvg:"https://flagcdn.com/lc.svg",flagPng:"https://flagcdn.com/w40/lc.png",phoneCode:"+1758"},{name:"Saint Martin (French part)",code:"MF",flagEmoji:"🇲🇫",flagSvg:"https://flagcdn.com/mf.svg",flagPng:"https://flagcdn.com/w40/mf.png",phoneCode:"+590"},{name:"Saint Pierre and Miquelon",code:"PM",flagEmoji:"🇵🇲",flagSvg:"https://flagcdn.com/pm.svg",flagPng:"https://flagcdn.com/w40/pm.png",phoneCode:"+508"},{name:"Saint Vincent and the Grenadines",code:"VC",flagEmoji:"🇻🇨",flagSvg:"https://flagcdn.com/vc.svg",flagPng:"https://flagcdn.com/w40/vc.png",phoneCode:"+1784"},{name:"Samoa",code:"WS",flagEmoji:"🇼🇸",flagSvg:"https://flagcdn.com/ws.svg",flagPng:"https://flagcdn.com/w40/ws.png",phoneCode:"+685"},{name:"San Marino",code:"SM",flagEmoji:"🇸🇲",flagSvg:"https://flagcdn.com/sm.svg",flagPng:"https://flagcdn.com/w40/sm.png",phoneCode:"+378"},{name:"Sao Tome and Principe",code:"ST",flagEmoji:"🇸🇹",flagSvg:"https://flagcdn.com/st.svg",flagPng:"https://flagcdn.com/w40/st.png",phoneCode:"+239"},{name:"Saudi Arabia",code:"SA",flagEmoji:"🇸🇦",flagSvg:"https://flagcdn.com/sa.svg",flagPng:"https://flagcdn.com/w40/sa.png",phoneCode:"+966"},{name:"Senegal",code:"SN",flagEmoji:"🇸🇳",flagSvg:"https://flagcdn.com/sn.svg",flagPng:"https://flagcdn.com/w40/sn.png",phoneCode:"+221"},{name:"Serbia",code:"RS",flagEmoji:"🇷🇸",flagSvg:"https://flagcdn.com/rs.svg",flagPng:"https://flagcdn.com/w40/rs.png",phoneCode:"+381"},{name:"Seychelles",code:"SC",flagEmoji:"🇸🇨",flagSvg:"https://flagcdn.com/sc.svg",flagPng:"https://flagcdn.com/w40/sc.png",phoneCode:"+248"},{name:"Sierra Leone",code:"SL",flagEmoji:"🇸🇱",flagSvg:"https://flagcdn.com/sl.svg",flagPng:"https://flagcdn.com/w40/sl.png",phoneCode:"+232"},{name:"Singapore",code:"SG",flagEmoji:"🇸🇬",flagSvg:"https://flagcdn.com/sg.svg",flagPng:"https://flagcdn.com/w40/sg.png",phoneCode:"+65"},{name:"Sint Maarten (Dutch part)",code:"SX",flagEmoji:"🇸🇽",flagSvg:"https://flagcdn.com/sx.svg",flagPng:"https://flagcdn.com/w40/sx.png",phoneCode:"+1721"},{name:"Slovakia",code:"SK",flagEmoji:"🇸🇰",flagSvg:"https://flagcdn.com/sk.svg",flagPng:"https://flagcdn.com/w40/sk.png",phoneCode:"+421"},{name:"Slovenia",code:"SI",flagEmoji:"🇸🇮",flagSvg:"https://flagcdn.com/si.svg",flagPng:"https://flagcdn.com/w40/si.png",phoneCode:"+386"},{name:"Solomon Islands",code:"SB",flagEmoji:"🇸🇧",flagSvg:"https://flagcdn.com/sb.svg",flagPng:"https://flagcdn.com/w40/sb.png",phoneCode:"+677"},{name:"Somalia",code:"SO",flagEmoji:"🇸🇴",flagSvg:"https://flagcdn.com/so.svg",flagPng:"https://flagcdn.com/w40/so.png",phoneCode:"+252"},{name:"South Africa",code:"ZA",flagEmoji:"🇿🇦",flagSvg:"https://flagcdn.com/za.svg",flagPng:"https://flagcdn.com/w40/za.png",phoneCode:"+27"},{name:"South Georgia and the South Sandwich Islands",code:"GS",flagEmoji:"🇬🇸",flagSvg:"https://flagcdn.com/gs.svg",flagPng:"https://flagcdn.com/w40/gs.png",phoneCode:"+500"},{name:"South Sudan",code:"SS",flagEmoji:"🇸🇸",flagSvg:"https://flagcdn.com/ss.svg",flagPng:"https://flagcdn.com/w40/ss.png",phoneCode:"+211"},{name:"Spain",code:"ES",flagEmoji:"🇪🇸",flagSvg:"https://flagcdn.com/es.svg",flagPng:"https://flagcdn.com/w40/es.png",phoneCode:"+34"},{name:"Sri Lanka",code:"LK",flagEmoji:"🇱🇰",flagSvg:"https://flagcdn.com/lk.svg",flagPng:"https://flagcdn.com/w40/lk.png",phoneCode:"+94"},{name:"Sudan",code:"SD",flagEmoji:"🇸🇩",flagSvg:"https://flagcdn.com/sd.svg",flagPng:"https://flagcdn.com/w40/sd.png",phoneCode:"+249"},{name:"Suriname",code:"SR",flagEmoji:"🇸🇷",flagSvg:"https://flagcdn.com/sr.svg",flagPng:"https://flagcdn.com/w40/sr.png",phoneCode:"+597"},{name:"Svalbard and Jan Mayen",code:"SJ",flagEmoji:"🇸🇯",flagSvg:"https://flagcdn.com/sj.svg",flagPng:"https://flagcdn.com/w40/sj.png",phoneCode:"+47"},{name:"Sweden",code:"SE",flagEmoji:"🇸🇪",flagSvg:"https://flagcdn.com/se.svg",flagPng:"https://flagcdn.com/w40/se.png",phoneCode:"+46"},{name:"Switzerland",code:"CH",flagEmoji:"🇨🇭",flagSvg:"https://flagcdn.com/ch.svg",flagPng:"https://flagcdn.com/w40/ch.png",phoneCode:"+41"},{name:"Syrian Arab Republic",code:"SY",flagEmoji:"🇸🇾",flagSvg:"https://flagcdn.com/sy.svg",flagPng:"https://flagcdn.com/w40/sy.png",phoneCode:"+963"},{name:"Taiwan, Province of China",code:"TW",flagEmoji:"🇹🇼",flagSvg:"https://flagcdn.com/tw.svg",flagPng:"https://flagcdn.com/w40/tw.png",phoneCode:"+886"},{name:"Tajikistan",code:"TJ",flagEmoji:"🇹🇯",flagSvg:"https://flagcdn.com/tj.svg",flagPng:"https://flagcdn.com/w40/tj.png",phoneCode:"+992"},{name:"Tanzania, United Republic of",code:"TZ",flagEmoji:"🇹🇿",flagSvg:"https://flagcdn.com/tz.svg",flagPng:"https://flagcdn.com/w40/tz.png",phoneCode:"+255"},{name:"Thailand",code:"TH",flagEmoji:"🇹🇭",flagSvg:"https://flagcdn.com/th.svg",flagPng:"https://flagcdn.com/w40/th.png",phoneCode:"+66"},{name:"Timor-Leste",code:"TL",flagEmoji:"🇹🇱",flagSvg:"https://flagcdn.com/tl.svg",flagPng:"https://flagcdn.com/w40/tl.png",phoneCode:"+670"},{name:"Togo",code:"TG",flagEmoji:"🇹🇬",flagSvg:"https://flagcdn.com/tg.svg",flagPng:"https://flagcdn.com/w40/tg.png",phoneCode:"+228"},{name:"Tokelau",code:"TK",flagEmoji:"🇹🇰",flagSvg:"https://flagcdn.com/tk.svg",flagPng:"https://flagcdn.com/w40/tk.png",phoneCode:"+690"},{name:"Tonga",code:"TO",flagEmoji:"🇹🇴",flagSvg:"https://flagcdn.com/to.svg",flagPng:"https://flagcdn.com/w40/to.png",phoneCode:"+676"},{name:"Trinidad and Tobago",code:"TT",flagEmoji:"🇹🇹",flagSvg:"https://flagcdn.com/tt.svg",flagPng:"https://flagcdn.com/w40/tt.png",phoneCode:"+1868"},{name:"Tunisia",code:"TN",flagEmoji:"🇹🇳",flagSvg:"https://flagcdn.com/tn.svg",flagPng:"https://flagcdn.com/w40/tn.png",phoneCode:"+216"},{name:"Turkey",code:"TR",flagEmoji:"🇹🇷",flagSvg:"https://flagcdn.com/tr.svg",flagPng:"https://flagcdn.com/w40/tr.png",phoneCode:"+90"},{name:"Turkmenistan",code:"TM",flagEmoji:"🇹🇲",flagSvg:"https://flagcdn.com/tm.svg",flagPng:"https://flagcdn.com/w40/tm.png",phoneCode:"+993"},{name:"Turks and Caicos Islands",code:"TC",flagEmoji:"🇹🇨",flagSvg:"https://flagcdn.com/tc.svg",flagPng:"https://flagcdn.com/w40/tc.png",phoneCode:"+1649"},{name:"Tuvalu",code:"TV",flagEmoji:"🇹🇻",flagSvg:"https://flagcdn.com/tv.svg",flagPng:"https://flagcdn.com/w40/tv.png",phoneCode:"+688"},{name:"Uganda",code:"UG",flagEmoji:"🇺🇬",flagSvg:"https://flagcdn.com/ug.svg",flagPng:"https://flagcdn.com/w40/ug.png",phoneCode:"+256"},{name:"Ukraine",code:"UA",flagEmoji:"🇺🇦",flagSvg:"https://flagcdn.com/ua.svg",flagPng:"https://flagcdn.com/w40/ua.png",phoneCode:"+380"},{name:"United Arab Emirates",code:"AE",flagEmoji:"🇦🇪",flagSvg:"https://flagcdn.com/ae.svg",flagPng:"https://flagcdn.com/w40/ae.png",phoneCode:"+971"},{name:"United Kingdom of Great Britain and Northern Ireland",code:"GB",flagEmoji:"🇬🇧",flagSvg:"https://flagcdn.com/gb.svg",flagPng:"https://flagcdn.com/w40/gb.png",phoneCode:"+44"},{name:"United States",code:"US",flagEmoji:"🇺🇸",flagSvg:"https://flagcdn.com/us.svg",flagPng:"https://flagcdn.com/w40/us.png",phoneCode:"+1"},{name:"United States Minor Outlying Islands",code:"UM",flagEmoji:"🇺🇲",flagSvg:"https://flagcdn.com/um.svg",flagPng:"https://flagcdn.com/w40/um.png",phoneCode:"+1"},{name:"Uruguay",code:"UY",flagEmoji:"🇺🇾",flagSvg:"https://flagcdn.com/uy.svg",flagPng:"https://flagcdn.com/w40/uy.png",phoneCode:"+598"},{name:"Uzbekistan",code:"UZ",flagEmoji:"🇺🇿",flagSvg:"https://flagcdn.com/uz.svg",flagPng:"https://flagcdn.com/w40/uz.png",phoneCode:"+998"},{name:"Vanuatu",code:"VU",flagEmoji:"🇻🇺",flagSvg:"https://flagcdn.com/vu.svg",flagPng:"https://flagcdn.com/w40/vu.png",phoneCode:"+678"},{name:"Venezuela (Bolivarian Republic of)",code:"VE",flagEmoji:"🇻🇪",flagSvg:"https://flagcdn.com/ve.svg",flagPng:"https://flagcdn.com/w40/ve.png",phoneCode:"+58"},{name:"Viet Nam",code:"VN",flagEmoji:"🇻🇳",flagSvg:"https://flagcdn.com/vn.svg",flagPng:"https://flagcdn.com/w40/vn.png",phoneCode:"+84"},{name:"Virgin Islands (British)",code:"VG",flagEmoji:"🇻🇬",flagSvg:"https://flagcdn.com/vg.svg",flagPng:"https://flagcdn.com/w40/vg.png",phoneCode:"+1284"},{name:"Virgin Islands (U.S.)",code:"VI",flagEmoji:"🇻🇮",flagSvg:"https://flagcdn.com/vi.svg",flagPng:"https://flagcdn.com/w40/vi.png",phoneCode:"+1340"},{name:"Wallis and Futuna",code:"WF",flagEmoji:"🇼🇫",flagSvg:"https://flagcdn.com/wf.svg",flagPng:"https://flagcdn.com/w40/wf.png",phoneCode:"+681"},{name:"Western Sahara",code:"EH",flagEmoji:"🇪🇭",flagSvg:"https://flagcdn.com/eh.svg",flagPng:"https://flagcdn.com/w40/eh.png",phoneCode:"+212"},{name:"Yemen",code:"YE",flagEmoji:"🇾🇪",flagSvg:"https://flagcdn.com/ye.svg",flagPng:"https://flagcdn.com/w40/ye.png",phoneCode:"+967"},{name:"Zambia",code:"ZM",flagEmoji:"🇿🇲",flagSvg:"https://flagcdn.com/zm.svg",flagPng:"https://flagcdn.com/w40/zm.png",phoneCode:"+260"},{name:"Zimbabwe",code:"ZW",flagEmoji:"🇿🇼",flagSvg:"https://flagcdn.com/zw.svg",flagPng:"https://flagcdn.com/w40/zw.png",phoneCode:"+263"}],Jn=["tabindex"],eo={class:"flex items-center gap-2"},to=["src","alt"],no={key:0,class:"absolute z-[9999] w-full mt-1 bg-white border border-gray-300 rounded-md shadow-lg max-h-60 overflow-y-auto",style:{position:"absolute"}},oo=["onClick"],ao=["src","alt","onError"],lo=e.defineComponent({__name:"index",props:{modelValue:{default:""},placeholder:{default:""},disabled:{type:Boolean,default:!1},required:{type:Boolean,default:!1},customClass:{default:""},autoDetectFromIp:{type:Boolean,default:!0},returnType:{default:"name"},priorityCountries:{default:()=>["US","CA","GB","DE","FR","JP","CN","AU"]},ipDetectUrl:{default:"https://ipinfo.io/json"},ipDetectMethod:{default:"GET"},ipDetectHeaders:{},ipDetectResponseParser:{}},emits:["update:modelValue","change","ip-detect-start","ip-detect-success","ip-detect-error"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(!1),c=e.ref(Qn),i=e.computed(()=>n.modelValue?c.value.find(u=>n.returnType==="code"?u.code===n.modelValue:u.name===n.modelValue):null),r=e.computed(()=>{const u=c.value.filter(w=>n.priorityCountries.includes(w.code)),f=c.value.filter(w=>!n.priorityCountries.includes(w.code)),y=u.sort((w,x)=>{const D=n.priorityCountries.indexOf(w.code),B=n.priorityCountries.indexOf(x.code);return D-B}),S=f.sort((w,x)=>w.name.localeCompare(x.name));return[...y,...S]}),d=()=>{n.disabled||(s.value=!s.value)},g=()=>{s.value=!1},p=u=>{if(u){const f=n.returnType==="code"?u.code:u.name;a("update:modelValue",f),a("change",f,u)}else a("update:modelValue","");g()},v=(u,f)=>{const y=u.target;f&&y.src===f.flagSvg?y.src=f.flagPng:i.value&&y.src===i.value.flagSvg&&(y.src=i.value.flagPng)},m=async()=>{if(!(!n.autoDetectFromIp||n.modelValue)){a("ip-detect-start");try{const u={method:n.ipDetectMethod,headers:{"Content-Type":"application/json",...n.ipDetectHeaders}},f=await fetch(n.ipDetectUrl,u);if(!f.ok)throw new Error(`HTTP error! status: ${f.status}`);const y=await f.json();let S;if(n.ipDetectResponseParser?S=n.ipDetectResponseParser(y):S=y.country||y.countryCode||y.country_code||"",S=S.toUpperCase(),!S)throw new Error("Country code not found in response");console.log("Auto-detected country from IP:",S),a("ip-detect-success",S);const w=c.value.find(x=>x.code===S);if(w){const x=n.returnType==="code"?w.code:w.name;a("update:modelValue",x),a("change",x,w)}else console.warn("Detected country code not found in country list:",S)}catch(u){const f=u instanceof Error?u:new Error(String(u));console.warn("Failed to detect country from IP:",f),a("ip-detect-error",f)}}},k=e.ref();return e.onMounted(async()=>{await e.nextTick(),n.autoDetectFromIp&&!n.modelValue&&await m();const u=f=>{k.value&&!k.value.contains(f.target)&&g()};document.addEventListener("click",u),e.onUnmounted(()=>{document.removeEventListener("click",u)})}),l({detectCountryFromIp:m,allCountries:e.readonly(c),sortedCountries:e.readonly(r)}),(u,f)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:k,class:"country-select-container relative"},[e.createElementVNode("div",{onClick:d,class:e.normalizeClass(["w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-[#1a1a1a] focus:border-[#1a1a1a] transition-colors duration-200 cursor-pointer bg-white flex items-center justify-between",t.customClass,{"opacity-60 cursor-not-allowed":t.disabled}]),tabindex:t.disabled?-1:0,onKeydown:[e.withKeys(d,["enter"]),e.withKeys(d,["space"]),e.withKeys(g,["escape"])]},[e.createElementVNode("div",eo,[i.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:i.value.flagSvg,alt:i.value.name,class:"w-5 h-4 object-cover rounded-sm",onError:v},null,40,to)):e.createCommentVNode("",!0),e.createElementVNode("span",{class:e.normalizeClass({"text-gray-500":!i.value&&t.placeholder})},e.toDisplayString(i.value?i.value.name:t.placeholder||"选择国家"),3)]),(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["w-5 h-5 text-gray-400 transition-transform duration-200",{"rotate-180":s.value}]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...f[0]||(f[0]=[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M19 9l-7 7-7-7"},null,-1)])],2))],42,Jn),s.value&&!t.disabled?(e.openBlock(),e.createElementBlock("div",no,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,y=>{var S;return e.openBlock(),e.createElementBlock("div",{key:y.code,onClick:w=>p(y),class:e.normalizeClass(["px-3 py-2 hover:bg-gray-50 cursor-pointer flex items-center gap-2 transition-colors",{"bg-gray-100":((S=i.value)==null?void 0:S.code)===y.code}])},[e.createElementVNode("img",{src:y.flagSvg,alt:y.name,class:"w-5 h-4 object-cover rounded-sm flex-shrink-0",onError:w=>v(w,y)},null,40,ao),e.createElementVNode("span",null,e.toDisplayString(y.name),1)],10,oo)}),128))])):e.createCommentVNode("",!0),s.value&&!t.disabled?(e.openBlock(),e.createElementBlock("div",{key:1,class:"fixed inset-0 z-[9998]",onClick:g})):e.createCommentVNode("",!0)],512))}}),so=Z(lo,[["__scopeId","data-v-08b31f1b"]]),co=["tabindex","aria-expanded","aria-labelledby"],io={class:"flex items-center gap-2 min-h-0 flex-1"},ro={key:0,class:"text-gray-500"},go={key:1,class:"flex flex-wrap gap-1"},fo={key:0,class:"text-gray-900"},uo=["onClick"],mo={key:0,class:"absolute z-[9999] w-full mt-2 bg-white rounded-xl shadow-xl border border-gray-100/50 max-h-60 overflow-auto backdrop-blur-sm",role:"listbox"},ho={key:0,class:"p-3 border-b border-gray-50/80"},po={class:"py-1"},vo={key:0,class:"px-4 py-3 text-sm text-gray-400 text-center"},yo=["onClick","onKeydown","aria-selected"],wo={class:"flex items-center gap-3"},bo={key:0,class:"flex items-center"},Co={key:0,class:"bi bi-check text-[#1a1a1a] text-xs"},ko={key:1,class:"flex items-center"},So={key:0,class:"w-1.5 h-1.5 bg-white rounded-full"},xo={class:"flex-1"},Eo=e.defineComponent({__name:"index",props:{modelValue:{},options:{},placeholder:{default:"请选择..."},multiple:{type:Boolean,default:!1},searchable:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},labelKey:{default:"label"},valueKey:{default:"value"},noOptionsText:{default:"暂无选项"},clearable:{type:Boolean,default:!1},borderless:{type:Boolean,default:!1},width:{default:"200px"}},emits:["update:modelValue","change","open","close"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(!1),c=e.ref(""),i=e.ref(),r=e.ref(),d=e.computed(()=>!n.searchable||!c.value?n.options:n.options.filter(h=>k(h).toLowerCase().includes(c.value.toLowerCase()))),g=e.computed(()=>n.multiple?null:n.options.find(h=>u(h)===n.modelValue)||null),p=e.computed(()=>n.multiple?Array.isArray(n.modelValue)?n.options.filter(h=>n.modelValue.includes(u(h))):[]:[]),v=e.computed(()=>n.multiple?p.value.length>0:g.value!==null),m=e.computed(()=>`select-label-${Math.random().toString(36).substr(2,9)}`),k=h=>typeof h=="object"?h[n.labelKey]:h,u=h=>typeof h=="object"?h[n.valueKey]:h,f=h=>{const E=u(h);return n.multiple?Array.isArray(n.modelValue)&&n.modelValue.includes(E):n.modelValue===E},y=h=>{if(h.disabled)return;const E=u(h);if(n.multiple){const b=Array.isArray(n.modelValue)?[...n.modelValue]:[],j=b.indexOf(E);j>-1?b.splice(j,1):b.push(E),a("update:modelValue",b),a("change",b)}else a("update:modelValue",E),a("change",E),D()},S=h=>{if(!n.multiple)return;const E=u(h),b=Array.isArray(n.modelValue)?[...n.modelValue]:[],j=b.indexOf(E);j>-1&&(b.splice(j,1),a("update:modelValue",b),a("change",b))},w=()=>{n.disabled||(s.value?D():x())},x=()=>{s.value=!0,a("open"),e.nextTick(()=>{n.searchable&&r.value&&r.value.focus()})},D=()=>{s.value=!1,c.value="",a("close")},B=h=>{i.value&&!i.value.contains(h.target)&&D()},P=h=>{if(!s.value)return;const E=d.value,b=E.findIndex(j=>f(j));switch(h.key){case"ArrowDown":h.preventDefault();break;case"ArrowUp":h.preventDefault();break;case"Enter":case" ":h.preventDefault(),b>=0&&E[b]&&y(E[b]);break}};return e.onMounted(()=>{document.addEventListener("click",B),document.addEventListener("keydown",P)}),e.onUnmounted(()=>{document.removeEventListener("click",B),document.removeEventListener("keydown",P)}),l({open:x,close:D,toggle:w}),(h,E)=>(e.openBlock(),e.createElementBlock("div",{class:"relative",style:e.normalizeStyle({width:t.width}),ref_key:"selectContainer",ref:i},[e.createElementVNode("div",{onClick:w,onKeydown:[e.withKeys(w,["enter"]),e.withKeys(w,["space"]),e.withKeys(D,["escape"])],class:e.normalizeClass(["flex items-center justify-between w-full px-4 py-1.5 text-sm bg-white rounded-md cursor-pointer transition-all duration-200 border ","focus:outline-none focus:ring-2 focus:ring-[#1a1a1a]/50 focus:ring-offset-1",{"shadow-sm hover:shadow-md border border-gray-200/60 hover:border-gray-300/80":!t.disabled&&!t.borderless,"shadow-sm hover:shadow-md":!t.disabled&&t.borderless,"bg-gray-50/50 cursor-not-allowed border border-gray-100":t.disabled,"ring-1 ring-[#1a1a1a]/50 border-[#1a1a1a]/50 shadow-md":s.value&&!t.borderless,"ring-1 ring-[#1a1a1a]/50 shadow-md":s.value&&t.borderless}]),tabindex:t.disabled?-1:0,role:"combobox","aria-expanded":s.value,"aria-haspopup":!0,"aria-labelledby":m.value},[e.createElementVNode("div",io,[t.placeholder&&!v.value?(e.openBlock(),e.createElementBlock("span",ro,e.toDisplayString(t.placeholder),1)):(e.openBlock(),e.createElementBlock("div",go,[t.multiple?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(p.value,b=>(e.openBlock(),e.createElementBlock("span",{key:u(b),class:"inline-flex items-center gap-1.5 px-2.5 py-1 text-xs bg-[#FFF] text-[#1a1a1a] rounded-full border border-[#1a1a1a]/50"},[e.createTextVNode(e.toDisplayString(k(b))+" ",1),e.createElementVNode("button",{onClick:e.withModifiers(j=>S(b),["stop"]),class:"rounded-full p-0.5 transition-colors duration-150",type:"button"},[...E[1]||(E[1]=[e.createElementVNode("i",{class:"bi bi-x text-xs text-[#1a1a1a]"},null,-1)])],8,uo)]))),128)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[g.value?(e.openBlock(),e.createElementBlock("span",fo,e.toDisplayString(k(g.value)),1)):e.createCommentVNode("",!0)],64))]))]),e.createElementVNode("i",{class:e.normalizeClass(["bi text-gray-400 transition-transform duration-200 text-lg",{"bi-chevron-down":!s.value,"bi-chevron-up":s.value}])},null,2)],42,co),e.createVNode(e.Transition,{"enter-active-class":"transition ease-out duration-200","enter-from-class":"opacity-0 scale-95","enter-to-class":"opacity-100 scale-100","leave-active-class":"transition ease-in duration-150","leave-from-class":"opacity-100 scale-100","leave-to-class":"opacity-0 scale-95"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",mo,[t.searchable?(e.openBlock(),e.createElementBlock("div",ho,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchInput",ref:r,"onUpdate:modelValue":E[0]||(E[0]=b=>c.value=b),type:"text",class:"w-full px-3 py-2 text-sm bg-gray-50/50 border border-gray-200/60 rounded-lg focus:outline-none focus:ring-1 focus:ring-[#1a1a1a]/50 focus:border-[#1a1a1a]/50 transition-all duration-200",placeholder:"搜索...",onKeydown:e.withKeys(D,["escape"])},null,544),[[e.vModelText,c.value]])])):e.createCommentVNode("",!0),e.createElementVNode("div",po,[d.value.length===0?(e.openBlock(),e.createElementBlock("div",vo,e.toDisplayString(t.noOptionsText),1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,b=>(e.openBlock(),e.createElementBlock("div",{key:u(b),onClick:j=>y(b),onKeydown:[e.withKeys(j=>y(b),["enter"]),e.withKeys(j=>y(b),["space"])],class:e.normalizeClass(["px-4 py-3 text-sm cursor-pointer transition-all duration-150",{"bg-[#f2f2f2] text-[#1a1a1a] font-medium":f(b),"hover:bg-[#f2f2f2] text-gray-700":!f(b)}]),role:"option","aria-selected":f(b),tabindex:0},[e.createElementVNode("div",wo,[t.multiple?(e.openBlock(),e.createElementBlock("div",bo,[e.createElementVNode("div",{class:e.normalizeClass(["w-4 h-4 rounded border flex items-center justify-center transition-all duration-150",{"border-[#1a1a1a] text-white":f(b),"border-gray-300 bg-white":!f(b)}])},[f(b)?(e.openBlock(),e.createElementBlock("i",Co)):e.createCommentVNode("",!0)],2)])):(e.openBlock(),e.createElementBlock("div",ko,[e.createElementVNode("div",{class:e.normalizeClass(["w-4 h-4 rounded-full border-2 flex items-center justify-center transition-all duration-150",{"border-[#1a1a1a] bg-[#1a1a1a]":f(b),"border-gray-300 bg-white":!f(b)}])},[f(b)?(e.openBlock(),e.createElementBlock("div",So)):e.createCommentVNode("",!0)],2)])),e.createElementVNode("span",xo,e.toDisplayString(k(b)),1)])],42,yo))),128))])])):e.createCommentVNode("",!0)]),_:1})],4))}}),$o=Z(Eo,[["__scopeId","data-v-1f7381d8"]]),Mo=["type","value","placeholder","disabled","readonly","required","maxlength","minlength","autocomplete"],Bo={key:2,class:"x-input-count"},Po=e.defineComponent({__name:"index",props:{modelValue:{},type:{default:"text"},placeholder:{default:""},label:{default:""},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},required:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},showWordLimit:{type:Boolean,default:!1},maxlength:{},minlength:{},autocomplete:{default:"off"},error:{type:Boolean,default:!1},width:{default:"100%"}},emits:["update:modelValue","input","change","blur","focus","clear","keydown","keyup"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(),c=e.ref(!1),i=e.computed(()=>!!n.label),r=e.computed(()=>{const x=n.modelValue;return x!=null&&x!==""}),d=e.computed(()=>String(n.modelValue||"").length),g=x=>{const B=x.target.value;a("update:modelValue",B),a("input",B,x)},p=x=>{const B=x.target.value;a("change",B,x)},v=x=>{c.value=!1,a("blur",x)},m=x=>{c.value=!0,a("focus",x)},k=x=>{a("keydown",x)},u=x=>{a("keyup",x)},f=()=>{var x;a("update:modelValue",""),a("clear"),(x=s.value)==null||x.focus()};return l({focus:()=>{var x;(x=s.value)==null||x.focus()},blur:()=>{var x;(x=s.value)==null||x.blur()},select:()=>{var x;(x=s.value)==null||x.select()},ref:s}),(x,D)=>(e.openBlock(),e.createElementBlock("div",{class:"x-input-group",style:e.normalizeStyle({width:t.width})},[e.createElementVNode("input",{ref_key:"inputRef",ref:s,type:t.type,value:t.modelValue,placeholder:i.value?"":t.placeholder,disabled:t.disabled,readonly:t.readonly,required:t.required,maxlength:t.maxlength,minlength:t.minlength,autocomplete:t.autocomplete,class:e.normalizeClass(["x-input",{"x-input--disabled":t.disabled,"x-input--error":t.error,"x-input--clearable":t.clearable&&t.modelValue,"x-input--with-label":i.value}]),onInput:g,onBlur:v,onFocus:m,onKeydown:k,onKeyup:u,onChange:p},null,42,Mo),t.label?(e.openBlock(),e.createElementBlock("label",{key:0,class:e.normalizeClass(["x-input-label",{"x-input-label--active":c.value||r.value,"x-input-label--error":t.error}])},e.toDisplayString(t.label),3)):e.createCommentVNode("",!0),t.clearable&&t.modelValue&&!t.disabled?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"x-input-clear",onClick:f,onMousedown:D[0]||(D[0]=e.withModifiers(()=>{},["prevent"]))},[e.createVNode(e.unref(K),{icon:"bi:x-circle"})],32)):e.createCommentVNode("",!0),t.showWordLimit&&t.maxlength?(e.openBlock(),e.createElementBlock("div",Bo,e.toDisplayString(d.value)+" / "+e.toDisplayString(t.maxlength),1)):e.createCommentVNode("",!0)],4))}}),jo=Z(Po,[["__scopeId","data-v-d7d149e3"]]),Vo={class:"x-checkboxes"},No=["onClick"],Do={class:"checkbox-wrapper"},Ao=["checked","disabled","onChange"],To={class:"checkbox-custom"},zo={key:0,class:"check-icon",viewBox:"0 0 24 24"},Io={class:"option-label"},Oo=e.defineComponent({__name:"index",props:{options:{},modelValue:{default:()=>[]},placeholder:{default:"请选择选项"},maxSelections:{default:0},disabled:{type:Boolean,default:!1},layout:{default:"vertical"},columns:{default:3}},emits:["update:modelValue","change"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=p=>n.modelValue&&n.modelValue.includes(p),c=p=>{if(n.disabled)return;const v=n.options.find(u=>u.value===p);if(v!=null&&v.disabled)return;const m=[...n.modelValue],k=m.indexOf(p);if(k>-1)m.splice(k,1);else{if(n.maxSelections>0&&m.length>=n.maxSelections)return;m.push(p)}a("update:modelValue",m),a("change",m)},i=p=>{!n.disabled&&!p.disabled&&c(p.value)};return l({clearAll:()=>{n.disabled||(a("update:modelValue",[]),a("change",[]))},selectAll:()=>{if(n.disabled)return;const v=n.options.filter(m=>!m.disabled).map(m=>m.value);n.maxSelections>0?(a("update:modelValue",v.slice(0,n.maxSelections)),a("change",v.slice(0,n.maxSelections))):(a("update:modelValue",v),a("change",v))},removeOption:p=>{c(p)}}),(p,v)=>(e.openBlock(),e.createElementBlock("div",Vo,[e.createElementVNode("div",{class:e.normalizeClass(["options-container",[`options-container--${t.layout}`,{"options-container--disabled":t.disabled}]]),style:e.normalizeStyle(t.layout==="grid"?{gridTemplateColumns:`repeat(${t.columns}, 1fr)`}:{})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,m=>(e.openBlock(),e.createElementBlock("div",{key:m.value,class:e.normalizeClass(["option-item",{"option-selected":s(m.value),"option-disabled":t.disabled||m.disabled}]),onClick:k=>i(m)},[e.createElementVNode("div",Do,[e.createElementVNode("input",{type:"checkbox",checked:s(m.value),disabled:t.disabled||m.disabled,onChange:e.withModifiers(k=>c(m.value),["stop"]),class:"checkbox-input"},null,40,Ao),e.createElementVNode("div",To,[s(m.value)?(e.openBlock(),e.createElementBlock("svg",zo,[...v[0]||(v[0]=[e.createElementVNode("path",{d:"M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"},null,-1)])])):e.createCommentVNode("",!0)])]),e.createElementVNode("span",Io,e.toDisplayString(m.label),1)],10,No))),128))],6)]))}}),Lo=Z(Oo,[["__scopeId","data-v-05984fcf"]]),Yo=["onClick","disabled","aria-expanded","aria-controls"],_o={class:"accordion-title"},Xo={class:"accordion-icon"},Fo=["id"],Ho={class:"accordion-body"},Wo=e.defineComponent({__name:"index",props:{items:{},allowMultiple:{type:Boolean,default:!1},defaultOpen:{default:()=>[]},bordered:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1}},emits:["change","item-click"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(new Set(n.defaultOpen)),c=e.ref({}),i=e.ref({}),r=(u,f)=>{u&&(i.value[f]=u,e.nextTick(()=>{const y=u.querySelector(".accordion-body");y&&(c.value[f]=y.scrollHeight)}))},d=u=>{var y;if(n.disabled||(y=n.items[u])!=null&&y.disabled)return;const f=s.value.has(u);n.allowMultiple?f?s.value.delete(u):s.value.add(u):f?s.value.clear():(s.value.clear(),s.value.add(u)),a("item-click",u,!f),a("change",Array.from(s.value))},g=u=>s.value.has(u);return e.watch(()=>n.defaultOpen,u=>{s.value=new Set(u)},{deep:!0}),e.watch(()=>n.items,()=>{e.nextTick(()=>{Object.keys(i.value).forEach(u=>{const f=parseInt(u),y=i.value[f];if(y){const S=y.querySelector(".accordion-body");S&&(c.value[f]=S.scrollHeight)}})})},{deep:!0}),l({openItem:u=>{var f;!n.disabled&&!((f=n.items[u])!=null&&f.disabled)&&(s.value.has(u)||(n.allowMultiple||s.value.clear(),s.value.add(u),a("change",Array.from(s.value))))},closeItem:u=>{s.value.has(u)&&(s.value.delete(u),a("change",Array.from(s.value)))},openAll:()=>{n.allowMultiple&&!n.disabled&&(n.items.forEach((u,f)=>{u.disabled||s.value.add(f)}),a("change",Array.from(s.value)))},closeAll:()=>{s.value.clear(),a("change",[])},toggle:d}),(u,f)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["accordion-container",{"accordion-container--bordered":t.bordered}])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(y,S)=>(e.openBlock(),e.createElementBlock("div",{key:y.id||S,class:e.normalizeClass(["accordion-item",{"is-open":g(S),"is-disabled":t.disabled||y.disabled}])},[e.createElementVNode("button",{onClick:w=>d(S),class:"accordion-header",disabled:t.disabled||y.disabled,"aria-expanded":g(S),"aria-controls":`accordion-content-${S}`},[e.createElementVNode("span",_o,e.toDisplayString(y.title),1),e.createElementVNode("div",Xo,[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["accordion-arrow",{"accordion-arrow--rotate":g(S)}]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",strokeWidth:"2"},[...f[0]||(f[0]=[e.createElementVNode("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19 9l-7 7-7-7"},null,-1)])],2))])],8,Yo),e.createElementVNode("div",{id:`accordion-content-${S}`,class:"accordion-content",style:e.normalizeStyle({maxHeight:g(S)?`${c.value[S]}px`:"0px"}),ref_for:!0,ref:w=>r(w,S)},[e.createElementVNode("div",Ho,e.toDisplayString(y.content),1)],12,Fo)],2))),128))],2))}}),Ro=Z(Wo,[["__scopeId","data-v-c5fef037"]]),Go={class:"thumbnail-container-wrapper relative"},Uo=["onMouseenter","onClick"],Ko=["src","alt"],qo={class:"thumbnail-index"},Zo=e.defineComponent({__name:"index",props:{images:{default:()=>[]},modelValue:{default:0},autoScroll:{type:Boolean,default:!0},showIndex:{type:Boolean,default:!0}},emits:["update:modelValue","change","hover"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=e.ref(n.modelValue),c=e.ref(null),i=e.ref([]),r=e.ref(!1),d=e.ref(!1),g=e.ref(0),p=e.ref(!1),v=e.ref(!1),m=()=>{D()},k=(h,E)=>{h&&h instanceof HTMLElement&&(i.value[E]=h)},u=h=>{a("hover",h)},f=()=>{},y=h=>{s.value=h,a("update:modelValue",h),a("change",h),n.autoScroll&&e.nextTick(()=>{x(h),setTimeout(()=>{D()},300)})},S=()=>{if(!c.value)return;const h=c.value,E=h.clientWidth*.8;h.scrollBy({left:-E,behavior:"smooth"})},w=()=>{if(!c.value)return;const h=c.value,E=h.clientWidth*.8;h.scrollBy({left:E,behavior:"smooth"})},x=h=>{if(!c.value||i.value.length===0)return;const E=c.value,b=i.value[h];if(!b)return;const j=2,A=b.offsetWidth+8;let V=0;h>=j&&(V=(h-j)*A);const N=E.scrollWidth-E.clientWidth;V=Math.max(0,Math.min(V,N)),E.scrollTo({left:V,behavior:"smooth"})},D=()=>{if(!c.value)return;const h=c.value,E=h.scrollLeft,b=h.scrollWidth-h.clientWidth;r.value=E>0,d.value=E<b,b>0?g.value=E/b*100:g.value=0;const j=B();p.value=n.images.length>j&&r.value,v.value=n.images.length>j&&d.value},B=()=>{var _;if(!c.value||i.value.length===0)return 4;const E=c.value.clientWidth-32,L=(((_=i.value[0])==null?void 0:_.offsetWidth)||80)+12;return Math.floor(E/L)},P=h=>{h>=0&&h<n.images.length&&y(h)};return e.watch(()=>n.modelValue,h=>{h!==void 0&&h!==s.value&&(s.value=h,n.autoScroll&&e.nextTick(()=>{x(h)}))}),e.watch(()=>n.images,()=>{e.nextTick(()=>{D()})},{deep:!0}),e.onMounted(()=>{e.nextTick(()=>{D()})}),l({setCurrentIndex:P,scrollLeft:S,scrollRight:w,updateScrollState:D}),(h,E)=>(e.openBlock(),e.createElementBlock("div",Go,[p.value?(e.openBlock(),e.createElementBlock("button",{key:0,onClick:S,class:"scroll-arrow scroll-arrow-left","aria-label":"向左滚动"},[...E[1]||(E[1]=[e.createElementVNode("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"},[e.createElementVNode("path",{d:"M15 18l-6-6 6-6"})],-1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"thumbnailContainer",ref:c,onScroll:m,class:"thumbnail-scroll-container"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.images,(b,j)=>(e.openBlock(),e.createElementBlock("div",{key:j,ref_for:!0,ref:L=>k(L,j),onMouseenter:L=>u(j),onMouseleave:E[0]||(E[0]=L=>f()),onClick:L=>y(j),class:e.normalizeClass(["thumbnail-item",{"thumbnail-item--active":s.value===j,"thumbnail-item--inactive":s.value!==j}])},[e.createElementVNode("img",{src:b,alt:`缩略图 ${j+1}`,class:e.normalizeClass(["thumbnail-image",{"thumbnail-image--active":s.value===j,"thumbnail-image--inactive":s.value!==j}])},null,10,Ko),e.createElementVNode("div",qo,e.toDisplayString(j+1),1)],42,Uo))),128))],544),v.value?(e.openBlock(),e.createElementBlock("button",{key:1,onClick:w,class:"scroll-arrow scroll-arrow-right","aria-label":"向右滚动"},[...E[2]||(E[2]=[e.createElementVNode("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2"},[e.createElementVNode("path",{d:"M9 18l6-6-6-6"})],-1)])])):e.createCommentVNode("",!0)]))}}),Qo=Z(Zo,[["__scopeId","data-v-809b97a6"]]),Jo=e.defineComponent({__name:"index",props:{width:{default:"100%"},height:{default:"1rem"},shape:{default:"rectangle"},animated:{type:Boolean,default:!0},loading:{type:Boolean,default:!0},class:{default:""},style:{default:()=>({})}},setup(t){const l=t,o=e.computed(()=>typeof l.width=="string"?l.width.includes("%")||l.width.includes("px")||l.width.includes("rem")?"":`w-${l.width}`:""),n=e.computed(()=>typeof l.height=="string"?l.height.includes("%")||l.height.includes("px")||l.height.includes("rem")?"":`h-${l.height}`:""),a=e.computed(()=>{switch(l.shape){case"circle":return"rounded-full";case"rounded":return"rounded-lg";default:return"rounded"}}),s=e.computed(()=>l.class),c=e.computed(()=>{const i={...l.style};return typeof l.width=="string"&&(l.width.includes("%")||l.width.includes("px")||l.width.includes("rem"))?i.width=l.width:typeof l.width=="number"&&(i.width=`${l.width}px`),typeof l.height=="string"&&(l.height.includes("%")||l.height.includes("px")||l.height.includes("rem"))?i.height=l.height:typeof l.height=="number"&&(i.height=`${l.height}px`),i});return(i,r)=>t.loading?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["bg-gray-200",[o.value,n.value,a.value,s.value,{"animate-pulse":t.animated}]]),style:e.normalizeStyle(c.value)},null,6)):e.renderSlot(i.$slots,"default",{key:1},void 0,!0)}}),ea=Z(Jo,[["__scopeId","data-v-db4a4465"]]),ta={key:0,class:"modal-header"},na={class:"modal-title"},oa={class:"modal-body"},aa={key:1,class:"modal-footer"},la={key:0,class:"loading-spinner"},sa=e.defineComponent({__name:"index",props:{visible:{type:Boolean,default:!1},title:{default:"提示"},width:{},size:{default:"medium"},fullscreen:{type:Boolean,default:!1},showHeader:{type:Boolean,default:!0},showFooter:{type:Boolean,default:!0},showClose:{type:Boolean,default:!0},showCancel:{type:Boolean,default:!0},showConfirm:{type:Boolean,default:!0},cancelText:{default:"取消"},confirmText:{default:"确定"},confirmLoading:{type:Boolean,default:!1},maskClosable:{type:Boolean,default:!0},escClosable:{type:Boolean,default:!0}},emits:["update:visible","close","cancel","confirm","opened","closed"],setup(t,{expose:l,emit:o}){const n=t,a=o,s=()=>{a("update:visible",!1),a("close")},c=()=>{a("cancel"),a("update:visible",!1)},i=()=>{a("confirm")},r=()=>{n.maskClosable&&s()},d=g=>{g.key==="Escape"&&n.escClosable&&n.visible&&s()};return e.watch(()=>n.visible,g=>{g?(document.addEventListener("keydown",d),document.body.style.overflow="hidden",a("opened")):(document.removeEventListener("keydown",d),document.body.style.overflow="",a("closed"))}),l({close:s}),(g,p)=>{const v=e.resolveComponent("XButton");return e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{"enter-active-class":"transition-opacity duration-300","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition-opacity duration-300","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:e.withCtx(()=>[t.visible?(e.openBlock(),e.createElementBlock("div",{key:0,class:"modal-mask",onClick:r},[e.createVNode(e.Transition,{"enter-active-class":"transition-all duration-300","enter-from-class":"opacity-0 scale-95","enter-to-class":"opacity-100 scale-100","leave-active-class":"transition-all duration-300","leave-from-class":"opacity-100 scale-100","leave-to-class":"opacity-0 scale-95"},{default:e.withCtx(()=>[t.visible?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["modal-container",[`modal-container--${t.size}`,{"modal-container--fullscreen":t.fullscreen}]]),style:e.normalizeStyle({width:t.width}),onClick:p[0]||(p[0]=e.withModifiers(()=>{},["stop"]))},[t.showHeader?(e.openBlock(),e.createElementBlock("div",ta,[e.renderSlot(g.$slots,"header",{},()=>[e.createElementVNode("h3",na,e.toDisplayString(t.title),1)],!0),t.showClose?(e.openBlock(),e.createBlock(v,{key:0,size:"small",class:"modal-close",icon:"mdi:close",onClick:s,"aria-label":"关闭"},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:close"})]),_:1})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",oa,[e.renderSlot(g.$slots,"default",{},void 0,!0)]),t.showFooter?(e.openBlock(),e.createElementBlock("div",aa,[e.renderSlot(g.$slots,"footer",{},()=>[t.showCancel?(e.openBlock(),e.createBlock(v,{key:0,size:"small",ghost:"",type:"danger",onClick:c},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.cancelText),1)]),_:1})):e.createCommentVNode("",!0),t.showConfirm?(e.openBlock(),e.createBlock(v,{key:1,size:"small",ghost:"",type:"primary",onClick:i,disabled:t.confirmLoading},{default:e.withCtx(()=>[t.confirmLoading?(e.openBlock(),e.createElementBlock("span",la)):e.createCommentVNode("",!0),e.createTextVNode(" "+e.toDisplayString(t.confirmText),1)]),_:1},8,["disabled"])):e.createCommentVNode("",!0)],!0)])):e.createCommentVNode("",!0)],6)):e.createCommentVNode("",!0)]),_:3})])):e.createCommentVNode("",!0)]),_:3})])}}}),ca=Z(sa,[["__scopeId","data-v-6b874658"]]),ia={class:"x-tooltip-trigger"},ra={class:"tooltip-label"},da={class:"tooltip-text"},ga={class:"tooltip-hover-text"},fa=e.defineComponent({__name:"index",props:{content:{},placement:{default:"top"},variant:{default:"basic"},label:{default:"Hover"},hoverText:{default:""}},setup(t){return(l,o)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass([t.variant==="basic"?"x-tooltip-wrapper":"x-tooltip-rich-wrapper",t.variant==="rich"&&`rich-${t.placement}`])},[t.variant==="basic"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",ia,[e.renderSlot(l.$slots,"default",{},void 0,!0)]),e.createElementVNode("div",{class:e.normalizeClass(["x-tooltip",`tooltip-${t.placement}`])},[e.createTextVNode(e.toDisplayString(t.content)+" ",1),e.createElementVNode("div",{class:e.normalizeClass(["tooltip-arrow",`arrow-${t.placement}`])},null,2)],2)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("span",ra,e.toDisplayString(t.label),1),e.createElementVNode("span",da,e.toDisplayString(t.content),1),e.createElementVNode("span",ga,e.toDisplayString(t.hoverText||t.label),1)],64))],2))}}),ua=Z(fa,[["__scopeId","data-v-6d3b782b"]]),ma=["id","checked","disabled"],ha=["for"],pa=e.defineComponent({__name:"index",props:{modelValue:{type:Boolean},disabled:{type:Boolean,default:!1},size:{default:"medium"},color:{default:"#0974f1"},shadowColor:{default:"#0974f1"},thumbColor:{default:"#ffffff"}},emits:["update:modelValue"],setup(t,{emit:l}){const o=t,n=l,a=e.computed(()=>`switch-${Math.random().toString(36).substr(2,9)}`),s=e.computed(()=>{const d=o.color||"#0974f1",g=o.shadowColor||d,p=o.thumbColor||"#ffffff",v=i(d,.9),m=i(d,.2);return{"--switch-color":d,"--switch-color-rgb":c(d),"--switch-shadow-color":g,"--switch-shadow-color-rgb":c(g),"--switch-thumb-color":p,"--switch-bg-color":v,"--switch-active-color":m}}),c=d=>{const g=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(d);if(g){const p=parseInt(g[1],16),v=parseInt(g[2],16),m=parseInt(g[3],16);return`${p}, ${v}, ${m}`}return"9, 117, 241"},i=(d,g)=>{const p=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(d);if(p){const v=parseInt(p[1],16),m=parseInt(p[2],16),k=parseInt(p[3],16),u=Math.round(v+(255-v)*g),f=Math.round(m+(255-m)*g),y=Math.round(k+(255-k)*g);return`#${u.toString(16).padStart(2,"0")}${f.toString(16).padStart(2,"0")}${y.toString(16).padStart(2,"0")}`}return"#e5e7eb"},r=()=>{o.disabled||n("update:modelValue",!o.modelValue)};return(d,g)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["switch",[`size-${t.size}`,{disabled:t.disabled}]]),style:e.normalizeStyle(s.value)},[e.createElementVNode("input",{id:a.value,checked:t.modelValue,onChange:r,disabled:t.disabled,type:"checkbox"},null,40,ma),e.createElementVNode("label",{for:a.value,class:"slider"},null,8,ha)],6))}}),va=Z(pa,[["__scopeId","data-v-a20eb3cf"]]),ya={class:"rating"},wa=["title","onClick"],ba=["name","value","disabled","checked"],Ca={key:0,class:"score-text"},ka={key:1,class:"score-value"},Sa=e.defineComponent({__name:"index",props:{modelValue:{default:0},maxStars:{default:5},size:{default:"medium"},disabled:{type:Boolean,default:!1},showText:{type:Boolean,default:!1},showValue:{type:Boolean,default:!1},texts:{default:()=>["极差","差","一般","好","极好"]},allowHalf:{type:Boolean,default:!1},color:{default:"#ffc73a"}},emits:["update:modelValue","change"],setup(t,{emit:l}){e.useCssVars(r=>({v45ed3bbe:r.color}));const o=t,n=l,a=e.computed(()=>Math.random().toString(36).substr(2,9)),s=r=>{o.disabled||(n("update:modelValue",r),n("change",r))},c=r=>o.texts&&o.texts[r-1]?`${r}星 - ${o.texts[r-1]}`:`${r}星`,i=()=>o.modelValue===0?"未评分":o.texts&&o.texts[o.modelValue-1]?o.texts[o.modelValue-1]:`${o.modelValue}星`;return(r,d)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["x-score",[`score-${t.size}`,{"score-disabled":t.disabled}]])},[e.createElementVNode("div",ya,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.maxStars,g=>(e.openBlock(),e.createElementBlock("label",{key:g,class:e.normalizeClass({"star-filled":g<=t.modelValue}),title:c(g),onClick:p=>s(g)},[e.createElementVNode("input",{type:"radio",name:`star-radio-${a.value}`,value:g,disabled:t.disabled,checked:t.modelValue===g,style:{display:"none"}},null,8,ba),d[0]||(d[0]=e.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},[e.createElementVNode("path",{pathLength:"360",d:"M12,17.27L18.18,21L16.54,13.97L22,9.24L14.81,8.62L12,2L9.19,8.62L2,9.24L7.45,13.97L5.82,21L12,17.27Z"})],-1))],10,wa))),128))]),t.showText?(e.openBlock(),e.createElementBlock("div",Ca,e.toDisplayString(i()),1)):e.createCommentVNode("",!0),t.showValue?(e.openBlock(),e.createElementBlock("div",ka,e.toDisplayString(t.modelValue)+"/"+e.toDisplayString(t.maxStars),1)):e.createCommentVNode("",!0)],2))}}),xa=Z(Sa,[["__scopeId","data-v-3cdb1a2c"]]),Ea=["name","value","disabled","checked","onChange"],$a={key:0,class:"radio-button"},Ma={class:"radio-content"},Ba={key:0,class:"radio-icon"},Pa={class:"radio-text"},ja={class:"radio-label"},Va={key:0,class:"radio-description"},Na={key:1,class:"payment-method-container"},Da={class:"payment-content"},Aa={class:"payment-icon"},Ta={class:"payment-label"},za=["name","value","disabled","checked","onChange"],Ia=e.defineComponent({__name:"index",props:{modelValue:{default:""},options:{default:()=>[]},size:{default:"medium"},disabled:{type:Boolean,default:!1},showIcon:{type:Boolean,default:!1},name:{default:"radio-group"},direction:{default:"vertical"},variant:{default:"standard"},mode:{default:"default"}},emits:["update:modelValue","change"],setup(t,{emit:l}){const o=t,n=l,a=[{value:"google",label:"Google Pay",icon:"logos:google-pay"},{value:"apple",label:"Apple Pay",icon:"logos:apple-pay"},{value:"paypal",label:"Paypal",icon:"logos:paypal"},{value:"visa",label:"Credit Card",icon:"logos:visa"}],s=c=>{o.disabled||(n("update:modelValue",c),n("change",c))};return(c,i)=>t.variant==="standard"?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["x-radio-group",[`radio-${t.size}`,`radio-${t.direction}`,`radio-${t.mode}`,{"radio-disabled":t.disabled}]])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,r=>(e.openBlock(),e.createElementBlock("label",{key:r.value,class:e.normalizeClass(["x-radio-item",[{"radio-item-checked":t.modelValue===r.value},{"radio-item-disabled":t.disabled||r.disabled}]])},[e.createElementVNode("input",{type:"radio",name:t.name,value:r.value,disabled:t.disabled||r.disabled,checked:t.modelValue===r.value,onChange:d=>s(r.value),class:"radio-input"},null,40,Ea),t.mode==="default"?(e.openBlock(),e.createElementBlock("div",$a,[...i[0]||(i[0]=[e.createElementVNode("div",{class:"radio-button-inner"},null,-1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",Ma,[r.icon||t.showIcon?(e.openBlock(),e.createElementBlock("div",Ba,[e.renderSlot(c.$slots,"icon",{option:r},()=>[r.icon?(e.openBlock(),e.createBlock(e.unref(K),{key:0,icon:r.icon},null,8,["icon"])):e.createCommentVNode("",!0)],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Pa,[e.createElementVNode("div",ja,e.toDisplayString(r.label),1),r.description?(e.openBlock(),e.createElementBlock("div",Va,e.toDisplayString(r.description),1)):e.createCommentVNode("",!0)]),e.renderSlot(c.$slots,"content",{option:r},void 0,!0)])],2))),128))],2)):(e.openBlock(),e.createElementBlock("div",Na,[i[1]||(i[1]=e.createElementVNode("p",{class:"payment-title"},"Payment method",-1)),i[2]||(i[2]=e.createElementVNode("p",{class:"payment-subtitle"},[e.createTextVNode(" This component is made by using "),e.createElementVNode("span",{class:"payment-highlight"},"`:has() pseudo-class`")],-1)),(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(a,r=>e.createElementVNode("label",{key:r.value,class:e.normalizeClass(["payment-option",{"payment-option-checked":t.modelValue===r.value}])},[e.createElementVNode("div",Da,[e.createElementVNode("div",Aa,[e.createVNode(e.unref(K),{icon:r.icon},null,8,["icon"])]),e.createElementVNode("p",Ta,e.toDisplayString(r.label),1)]),e.createElementVNode("input",{type:"radio",name:t.name,value:r.value,disabled:t.disabled,checked:t.modelValue===r.value,onChange:d=>s(r.value),class:"payment-input"},null,40,za)],2)),64))]))}}),Oa=Z(Ia,[["__scopeId","data-v-0b609d3b"]]);var J=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ee(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var nt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o=1e3,n=6e4,a=36e5,s="millisecond",c="second",i="minute",r="hour",d="day",g="week",p="month",v="quarter",m="year",k="date",u="Invalid Date",f=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,S={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(A){var V=["th","st","nd","rd"],N=A%100;return"["+A+(V[(N-20)%10]||V[N]||V[0])+"]"}},w=function(A,V,N){var z=String(A);return!z||z.length>=V?A:""+Array(V+1-z.length).join(N)+A},x={s:w,z:function(A){var V=-A.utcOffset(),N=Math.abs(V),z=Math.floor(N/60),C=N%60;return(V<=0?"+":"-")+w(z,2,"0")+":"+w(C,2,"0")},m:function A(V,N){if(V.date()<N.date())return-A(N,V);var z=12*(N.year()-V.year())+(N.month()-V.month()),C=V.clone().add(z,p),$=N-C<0,I=V.clone().add(z+($?-1:1),p);return+(-(z+(N-C)/($?C-I:I-C))||0)},a:function(A){return A<0?Math.ceil(A)||0:Math.floor(A)},p:function(A){return{M:p,y:m,w:g,d,D:k,h:r,m:i,s:c,ms:s,Q:v}[A]||String(A||"").toLowerCase().replace(/s$/,"")},u:function(A){return A===void 0}},D="en",B={};B[D]=S;var P="$isDayjsObject",h=function(A){return A instanceof L||!(!A||!A[P])},E=function A(V,N,z){var C;if(!V)return D;if(typeof V=="string"){var $=V.toLowerCase();B[$]&&(C=$),N&&(B[$]=N,C=$);var I=V.split("-");if(!C&&I.length>1)return A(I[0])}else{var O=V.name;B[O]=V,C=O}return!z&&C&&(D=C),C||!z&&D},b=function(A,V){if(h(A))return A.clone();var N=typeof V=="object"?V:{};return N.date=A,N.args=arguments,new L(N)},j=x;j.l=E,j.i=h,j.w=function(A,V){return b(A,{locale:V.$L,utc:V.$u,x:V.$x,$offset:V.$offset})};var L=function(){function A(N){this.$L=E(N.locale,null,!0),this.parse(N),this.$x=this.$x||N.x||{},this[P]=!0}var V=A.prototype;return V.parse=function(N){this.$d=function(z){var C=z.date,$=z.utc;if(C===null)return new Date(NaN);if(j.u(C))return new Date;if(C instanceof Date)return new Date(C);if(typeof C=="string"&&!/Z$/i.test(C)){var I=C.match(f);if(I){var O=I[2]-1||0,X=(I[7]||"0").substring(0,3);return $?new Date(Date.UTC(I[1],O,I[3]||1,I[4]||0,I[5]||0,I[6]||0,X)):new Date(I[1],O,I[3]||1,I[4]||0,I[5]||0,I[6]||0,X)}}return new Date(C)}(N),this.init()},V.init=function(){var N=this.$d;this.$y=N.getFullYear(),this.$M=N.getMonth(),this.$D=N.getDate(),this.$W=N.getDay(),this.$H=N.getHours(),this.$m=N.getMinutes(),this.$s=N.getSeconds(),this.$ms=N.getMilliseconds()},V.$utils=function(){return j},V.isValid=function(){return this.$d.toString()!==u},V.isSame=function(N,z){var C=b(N);return this.startOf(z)<=C&&C<=this.endOf(z)},V.isAfter=function(N,z){return b(N)<this.startOf(z)},V.isBefore=function(N,z){return this.endOf(z)<b(N)},V.$g=function(N,z,C){return j.u(N)?this[z]:this.set(C,N)},V.unix=function(){return Math.floor(this.valueOf()/1e3)},V.valueOf=function(){return this.$d.getTime()},V.startOf=function(N,z){var C=this,$=!!j.u(z)||z,I=j.p(N),O=function(G,R){var q=j.w(C.$u?Date.UTC(C.$y,R,G):new Date(C.$y,R,G),C);return $?q:q.endOf(d)},X=function(G,R){return j.w(C.toDate()[G].apply(C.toDate("s"),($?[0,0,0,0]:[23,59,59,999]).slice(R)),C)},H=this.$W,M=this.$M,T=this.$D,Y="set"+(this.$u?"UTC":"");switch(I){case m:return $?O(1,0):O(31,11);case p:return $?O(1,M):O(0,M+1);case g:var W=this.$locale().weekStart||0,U=(H<W?H+7:H)-W;return O($?T-U:T+(6-U),M);case d:case k:return X(Y+"Hours",0);case r:return X(Y+"Minutes",1);case i:return X(Y+"Seconds",2);case c:return X(Y+"Milliseconds",3);default:return this.clone()}},V.endOf=function(N){return this.startOf(N,!1)},V.$set=function(N,z){var C,$=j.p(N),I="set"+(this.$u?"UTC":""),O=(C={},C[d]=I+"Date",C[k]=I+"Date",C[p]=I+"Month",C[m]=I+"FullYear",C[r]=I+"Hours",C[i]=I+"Minutes",C[c]=I+"Seconds",C[s]=I+"Milliseconds",C)[$],X=$===d?this.$D+(z-this.$W):z;if($===p||$===m){var H=this.clone().set(k,1);H.$d[O](X),H.init(),this.$d=H.set(k,Math.min(this.$D,H.daysInMonth())).$d}else O&&this.$d[O](X);return this.init(),this},V.set=function(N,z){return this.clone().$set(N,z)},V.get=function(N){return this[j.p(N)]()},V.add=function(N,z){var C,$=this;N=Number(N);var I=j.p(z),O=function(M){var T=b($);return j.w(T.date(T.date()+Math.round(M*N)),$)};if(I===p)return this.set(p,this.$M+N);if(I===m)return this.set(m,this.$y+N);if(I===d)return O(1);if(I===g)return O(7);var X=(C={},C[i]=n,C[r]=a,C[c]=o,C)[I]||1,H=this.$d.getTime()+N*X;return j.w(H,this)},V.subtract=function(N,z){return this.add(-1*N,z)},V.format=function(N){var z=this,C=this.$locale();if(!this.isValid())return C.invalidDate||u;var $=N||"YYYY-MM-DDTHH:mm:ssZ",I=j.z(this),O=this.$H,X=this.$m,H=this.$M,M=C.weekdays,T=C.months,Y=C.meridiem,W=function(R,q,Q,te){return R&&(R[q]||R(z,$))||Q[q].slice(0,te)},U=function(R){return j.s(O%12||12,R,"0")},G=Y||function(R,q,Q){var te=R<12?"AM":"PM";return Q?te.toLowerCase():te};return $.replace(y,function(R,q){return q||function(Q){switch(Q){case"YY":return String(z.$y).slice(-2);case"YYYY":return j.s(z.$y,4,"0");case"M":return H+1;case"MM":return j.s(H+1,2,"0");case"MMM":return W(C.monthsShort,H,T,3);case"MMMM":return W(T,H);case"D":return z.$D;case"DD":return j.s(z.$D,2,"0");case"d":return String(z.$W);case"dd":return W(C.weekdaysMin,z.$W,M,2);case"ddd":return W(C.weekdaysShort,z.$W,M,3);case"dddd":return M[z.$W];case"H":return String(O);case"HH":return j.s(O,2,"0");case"h":return U(1);case"hh":return U(2);case"a":return G(O,X,!0);case"A":return G(O,X,!1);case"m":return String(X);case"mm":return j.s(X,2,"0");case"s":return String(z.$s);case"ss":return j.s(z.$s,2,"0");case"SSS":return j.s(z.$ms,3,"0");case"Z":return I}return null}(R)||I.replace(":","")})},V.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},V.diff=function(N,z,C){var $,I=this,O=j.p(z),X=b(N),H=(X.utcOffset()-this.utcOffset())*n,M=this-X,T=function(){return j.m(I,X)};switch(O){case m:$=T()/12;break;case p:$=T();break;case v:$=T()/3;break;case g:$=(M-H)/6048e5;break;case d:$=(M-H)/864e5;break;case r:$=M/a;break;case i:$=M/n;break;case c:$=M/o;break;default:$=M}return C?$:j.a($)},V.daysInMonth=function(){return this.endOf(p).$D},V.$locale=function(){return B[this.$L]},V.locale=function(N,z){if(!N)return this.$L;var C=this.clone(),$=E(N,z,!0);return $&&(C.$L=$),C},V.clone=function(){return j.w(this.$d,this)},V.toDate=function(){return new Date(this.valueOf())},V.toJSON=function(){return this.isValid()?this.toISOString():null},V.toISOString=function(){return this.$d.toISOString()},V.toString=function(){return this.$d.toUTCString()},A}(),_=L.prototype;return b.prototype=_,[["$ms",s],["$s",c],["$m",i],["$H",r],["$W",d],["$M",p],["$y",m],["$D",k]].forEach(function(A){_[A[1]]=function(V){return this.$g(V,A[0],A[1])}}),b.extend=function(A,V){return A.$i||(A(V,L,b),A.$i=!0),b},b.locale=E,b.isDayjs=h,b.unix=function(A){return b(1e3*A)},b.en=B[D],b.Ls=B,b.p={},b})})(nt);var ot=nt.exports;const F=ee(ot);var at={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o="minute",n=/[+-]\d\d(?::?\d\d)?/g,a=/([+-]|\d\d)/g;return function(s,c,i){var r=c.prototype;i.utc=function(u){var f={date:u,utc:!0,args:arguments};return new c(f)},r.utc=function(u){var f=i(this.toDate(),{locale:this.$L,utc:!0});return u?f.add(this.utcOffset(),o):f},r.local=function(){return i(this.toDate(),{locale:this.$L,utc:!1})};var d=r.parse;r.parse=function(u){u.utc&&(this.$u=!0),this.$utils().u(u.$offset)||(this.$offset=u.$offset),d.call(this,u)};var g=r.init;r.init=function(){if(this.$u){var u=this.$d;this.$y=u.getUTCFullYear(),this.$M=u.getUTCMonth(),this.$D=u.getUTCDate(),this.$W=u.getUTCDay(),this.$H=u.getUTCHours(),this.$m=u.getUTCMinutes(),this.$s=u.getUTCSeconds(),this.$ms=u.getUTCMilliseconds()}else g.call(this)};var p=r.utcOffset;r.utcOffset=function(u,f){var y=this.$utils().u;if(y(u))return this.$u?0:y(this.$offset)?p.call(this):this.$offset;if(typeof u=="string"&&(u=function(D){D===void 0&&(D="");var B=D.match(n);if(!B)return null;var P=(""+B[0]).match(a)||["-",0,0],h=P[0],E=60*+P[1]+ +P[2];return E===0?0:h==="+"?E:-E}(u),u===null))return this;var S=Math.abs(u)<=16?60*u:u;if(S===0)return this.utc(f);var w=this.clone();if(f)return w.$offset=S,w.$u=!1,w;var x=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return(w=this.local().add(S+x,o)).$offset=S,w.$x.$localOffset=x,w};var v=r.format;r.format=function(u){var f=u||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return v.call(this,f)},r.valueOf=function(){var u=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*u},r.isUTC=function(){return!!this.$u},r.toISOString=function(){return this.toDate().toISOString()},r.toString=function(){return this.toDate().toUTCString()};var m=r.toDate;r.toDate=function(u){return u==="s"&&this.$offset?i(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():m.call(this)};var k=r.diff;r.diff=function(u,f,y){if(u&&this.$u===u.$u)return k.call(this,u,f,y);var S=this.local(),w=i(u).local();return k.call(S,w,f,y)}}})})(at);var La=at.exports;const Ya=ee(La);var lt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o={year:0,month:1,day:2,hour:3,minute:4,second:5},n={};return function(a,s,c){var i,r=function(v,m,k){k===void 0&&(k={});var u=new Date(v),f=function(y,S){S===void 0&&(S={});var w=S.timeZoneName||"short",x=y+"|"+w,D=n[x];return D||(D=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:y,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:w}),n[x]=D),D}(m,k);return f.formatToParts(u)},d=function(v,m){for(var k=r(v,m),u=[],f=0;f<k.length;f+=1){var y=k[f],S=y.type,w=y.value,x=o[S];x>=0&&(u[x]=parseInt(w,10))}var D=u[3],B=D===24?0:D,P=u[0]+"-"+u[1]+"-"+u[2]+" "+B+":"+u[4]+":"+u[5]+":000",h=+v;return(c.utc(P).valueOf()-(h-=h%1e3))/6e4},g=s.prototype;g.tz=function(v,m){v===void 0&&(v=i);var k,u=this.utcOffset(),f=this.toDate(),y=f.toLocaleString("en-US",{timeZone:v}),S=Math.round((f-new Date(y))/1e3/60),w=15*-Math.round(f.getTimezoneOffset()/15)-S;if(!Number(w))k=this.utcOffset(0,m);else if(k=c(y,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(w,!0),m){var x=k.utcOffset();k=k.add(u-x,"minute")}return k.$x.$timezone=v,k},g.offsetName=function(v){var m=this.$x.$timezone||c.tz.guess(),k=r(this.valueOf(),m,{timeZoneName:v}).find(function(u){return u.type.toLowerCase()==="timezonename"});return k&&k.value};var p=g.startOf;g.startOf=function(v,m){if(!this.$x||!this.$x.$timezone)return p.call(this,v,m);var k=c(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return p.call(k,v,m).tz(this.$x.$timezone,!0)},c.tz=function(v,m,k){var u=k&&m,f=k||m||i,y=d(+c(),f);if(typeof v!="string")return c(v).tz(f);var S=function(B,P,h){var E=B-60*P*1e3,b=d(E,h);if(P===b)return[E,P];var j=d(E-=60*(b-P)*1e3,h);return b===j?[E,b]:[B-60*Math.min(b,j)*1e3,Math.max(b,j)]}(c.utc(v,u).valueOf(),y,f),w=S[0],x=S[1],D=c(w).utcOffset(x);return D.$x.$timezone=f,D},c.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},c.tz.setDefault=function(v){i=v}}})})(lt);var _a=lt.exports;const Xa=ee(_a);var st={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n,a){o=o||{};var s=n.prototype,c={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function i(d,g,p,v){return s.fromToBase(d,g,p,v)}a.en.relativeTime=c,s.fromToBase=function(d,g,p,v,m){for(var k,u,f,y=p.$locale().relativeTime||c,S=o.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],w=S.length,x=0;x<w;x+=1){var D=S[x];D.d&&(k=v?a(d).diff(p,D.d,!0):p.diff(d,D.d,!0));var B=(o.rounding||Math.round)(Math.abs(k));if(f=k>0,B<=D.r||!D.r){B<=1&&x>0&&(D=S[x-1]);var P=y[D.l];m&&(B=m(""+B)),u=typeof P=="string"?P.replace("%d",B):P(B,g,D.l,f);break}}if(g)return u;var h=f?y.future:y.past;return typeof h=="function"?h(u):h.replace("%s",u)},s.to=function(d,g){return i(d,g,this,!0)},s.from=function(d,g){return i(d,g,this)};var r=function(d){return d.$u?a.utc():a()};s.toNow=function(d){return this.to(r(this),d)},s.fromNow=function(d){return this.from(r(this),d)}}})})(st);var Fa=st.exports;const Ha=ee(Fa);var ct={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o,n,a=1e3,s=6e4,c=36e5,i=864e5,r=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,d=31536e6,g=2628e6,p=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,v={years:d,months:g,days:i,hours:c,minutes:s,seconds:a,milliseconds:1,weeks:6048e5},m=function(B){return B instanceof x},k=function(B,P,h){return new x(B,h,P.$l)},u=function(B){return n.p(B)+"s"},f=function(B){return B<0},y=function(B){return f(B)?Math.ceil(B):Math.floor(B)},S=function(B){return Math.abs(B)},w=function(B,P){return B?f(B)?{negative:!0,format:""+S(B)+P}:{negative:!1,format:""+B+P}:{negative:!1,format:""}},x=function(){function B(h,E,b){var j=this;if(this.$d={},this.$l=b,h===void 0&&(this.$ms=0,this.parseFromMilliseconds()),E)return k(h*v[u(E)],this);if(typeof h=="number")return this.$ms=h,this.parseFromMilliseconds(),this;if(typeof h=="object")return Object.keys(h).forEach(function(A){j.$d[u(A)]=h[A]}),this.calMilliseconds(),this;if(typeof h=="string"){var L=h.match(p);if(L){var _=L.slice(2).map(function(A){return A!=null?Number(A):0});return this.$d.years=_[0],this.$d.months=_[1],this.$d.weeks=_[2],this.$d.days=_[3],this.$d.hours=_[4],this.$d.minutes=_[5],this.$d.seconds=_[6],this.calMilliseconds(),this}}return this}var P=B.prototype;return P.calMilliseconds=function(){var h=this;this.$ms=Object.keys(this.$d).reduce(function(E,b){return E+(h.$d[b]||0)*v[b]},0)},P.parseFromMilliseconds=function(){var h=this.$ms;this.$d.years=y(h/d),h%=d,this.$d.months=y(h/g),h%=g,this.$d.days=y(h/i),h%=i,this.$d.hours=y(h/c),h%=c,this.$d.minutes=y(h/s),h%=s,this.$d.seconds=y(h/a),h%=a,this.$d.milliseconds=h},P.toISOString=function(){var h=w(this.$d.years,"Y"),E=w(this.$d.months,"M"),b=+this.$d.days||0;this.$d.weeks&&(b+=7*this.$d.weeks);var j=w(b,"D"),L=w(this.$d.hours,"H"),_=w(this.$d.minutes,"M"),A=this.$d.seconds||0;this.$d.milliseconds&&(A+=this.$d.milliseconds/1e3,A=Math.round(1e3*A)/1e3);var V=w(A,"S"),N=h.negative||E.negative||j.negative||L.negative||_.negative||V.negative,z=L.format||_.format||V.format?"T":"",C=(N?"-":"")+"P"+h.format+E.format+j.format+z+L.format+_.format+V.format;return C==="P"||C==="-P"?"P0D":C},P.toJSON=function(){return this.toISOString()},P.format=function(h){var E=h||"YYYY-MM-DDTHH:mm:ss",b={Y:this.$d.years,YY:n.s(this.$d.years,2,"0"),YYYY:n.s(this.$d.years,4,"0"),M:this.$d.months,MM:n.s(this.$d.months,2,"0"),D:this.$d.days,DD:n.s(this.$d.days,2,"0"),H:this.$d.hours,HH:n.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:n.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:n.s(this.$d.seconds,2,"0"),SSS:n.s(this.$d.milliseconds,3,"0")};return E.replace(r,function(j,L){return L||String(b[j])})},P.as=function(h){return this.$ms/v[u(h)]},P.get=function(h){var E=this.$ms,b=u(h);return b==="milliseconds"?E%=1e3:E=b==="weeks"?y(E/v[b]):this.$d[b],E||0},P.add=function(h,E,b){var j;return j=E?h*v[u(E)]:m(h)?h.$ms:k(h,this).$ms,k(this.$ms+j*(b?-1:1),this)},P.subtract=function(h,E){return this.add(h,E,!0)},P.locale=function(h){var E=this.clone();return E.$l=h,E},P.clone=function(){return k(this.$ms,this)},P.humanize=function(h){return o().add(this.$ms,"ms").locale(this.$l).fromNow(!h)},P.valueOf=function(){return this.asMilliseconds()},P.milliseconds=function(){return this.get("milliseconds")},P.asMilliseconds=function(){return this.as("milliseconds")},P.seconds=function(){return this.get("seconds")},P.asSeconds=function(){return this.as("seconds")},P.minutes=function(){return this.get("minutes")},P.asMinutes=function(){return this.as("minutes")},P.hours=function(){return this.get("hours")},P.asHours=function(){return this.as("hours")},P.days=function(){return this.get("days")},P.asDays=function(){return this.as("days")},P.weeks=function(){return this.get("weeks")},P.asWeeks=function(){return this.as("weeks")},P.months=function(){return this.get("months")},P.asMonths=function(){return this.as("months")},P.years=function(){return this.get("years")},P.asYears=function(){return this.as("years")},B}(),D=function(B,P,h){return B.add(P.years()*h,"y").add(P.months()*h,"M").add(P.days()*h,"d").add(P.hours()*h,"h").add(P.minutes()*h,"m").add(P.seconds()*h,"s").add(P.milliseconds()*h,"ms")};return function(B,P,h){o=h,n=h().$utils(),h.duration=function(j,L){var _=h.locale();return k(j,{$l:_},L)},h.isDuration=m;var E=P.prototype.add,b=P.prototype.subtract;P.prototype.add=function(j,L){return m(j)?D(this,j,1):E.bind(this)(j,L)},P.prototype.subtract=function(j,L){return m(j)?D(this,j,-1):b.bind(this)(j,L)}}})})(ct);var Wa=ct.exports;const Ra=ee(Wa);var it={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n){n.prototype.isSameOrAfter=function(a,s){return this.isSame(a,s)||this.isAfter(a,s)}}})})(it);var Ga=it.exports;const Ua=ee(Ga);var rt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n){n.prototype.isSameOrBefore=function(a,s){return this.isSame(a,s)||this.isBefore(a,s)}}})})(rt);var Ka=rt.exports;const qa=ee(Ka);var dt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n,a){n.prototype.isBetween=function(s,c,i,r){var d=a(s),g=a(c),p=(r=r||"()")[0]==="(",v=r[1]===")";return(p?this.isAfter(d,i):!this.isBefore(d,i))&&(v?this.isBefore(g,i):!this.isAfter(g,i))||(p?this.isBefore(d,i):!this.isAfter(d,i))&&(v?this.isAfter(g,i):!this.isBefore(g,i))}}})})(dt);var Za=dt.exports;const Qa=ee(Za);var gt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o="week",n="year";return function(a,s,c){var i=s.prototype;i.week=function(r){if(r===void 0&&(r=null),r!==null)return this.add(7*(r-this.week()),"day");var d=this.$locale().yearStart||1;if(this.month()===11&&this.date()>25){var g=c(this).startOf(n).add(1,n).date(d),p=c(this).endOf(o);if(g.isBefore(p))return 1}var v=c(this).startOf(n).date(d).startOf(o).subtract(1,"millisecond"),m=this.diff(v,o,!0);return m<0?c(this).startOf("week").week():Math.ceil(m)},i.weeks=function(r){return r===void 0&&(r=null),this.week(r)}}})})(gt);var Ja=gt.exports;const el=ee(Ja);var ft={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o="day";return function(n,a,s){var c=function(d){return d.add(4-d.isoWeekday(),o)},i=a.prototype;i.isoWeekYear=function(){return c(this).year()},i.isoWeek=function(d){if(!this.$utils().u(d))return this.add(7*(d-this.isoWeek()),o);var g,p,v,m,k=c(this),u=(g=this.isoWeekYear(),p=this.$u,v=(p?s.utc:s)().year(g).startOf("year"),m=4-v.isoWeekday(),v.isoWeekday()>4&&(m+=7),v.add(m,o));return k.diff(u,"week")+1},i.isoWeekday=function(d){return this.$utils().u(d)?this.day()||7:this.day(this.day()%7?d:d-7)};var r=i.startOf;i.startOf=function(d,g){var p=this.$utils(),v=!!p.u(g)||g;return p.p(d)==="isoweek"?v?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):r.bind(this)(d,g)}}})})(ft);var tl=ft.exports;const nl=ee(tl);var ut={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){var o={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},n=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,a=/\d/,s=/\d\d/,c=/\d\d?/,i=/\d*[^-_:/,()\s\d]+/,r={},d=function(f){return(f=+f)+(f>68?1900:2e3)},g=function(f){return function(y){this[f]=+y}},p=[/[+-]\d\d:?(\d\d)?|Z/,function(f){(this.zone||(this.zone={})).offset=function(y){if(!y||y==="Z")return 0;var S=y.match(/([+-]|\d\d)/g),w=60*S[1]+(+S[2]||0);return w===0?0:S[0]==="+"?-w:w}(f)}],v=function(f){var y=r[f];return y&&(y.indexOf?y:y.s.concat(y.f))},m=function(f,y){var S,w=r.meridiem;if(w){for(var x=1;x<=24;x+=1)if(f.indexOf(w(x,0,y))>-1){S=x>12;break}}else S=f===(y?"pm":"PM");return S},k={A:[i,function(f){this.afternoon=m(f,!1)}],a:[i,function(f){this.afternoon=m(f,!0)}],Q:[a,function(f){this.month=3*(f-1)+1}],S:[a,function(f){this.milliseconds=100*+f}],SS:[s,function(f){this.milliseconds=10*+f}],SSS:[/\d{3}/,function(f){this.milliseconds=+f}],s:[c,g("seconds")],ss:[c,g("seconds")],m:[c,g("minutes")],mm:[c,g("minutes")],H:[c,g("hours")],h:[c,g("hours")],HH:[c,g("hours")],hh:[c,g("hours")],D:[c,g("day")],DD:[s,g("day")],Do:[i,function(f){var y=r.ordinal,S=f.match(/\d+/);if(this.day=S[0],y)for(var w=1;w<=31;w+=1)y(w).replace(/\[|\]/g,"")===f&&(this.day=w)}],w:[c,g("week")],ww:[s,g("week")],M:[c,g("month")],MM:[s,g("month")],MMM:[i,function(f){var y=v("months"),S=(v("monthsShort")||y.map(function(w){return w.slice(0,3)})).indexOf(f)+1;if(S<1)throw new Error;this.month=S%12||S}],MMMM:[i,function(f){var y=v("months").indexOf(f)+1;if(y<1)throw new Error;this.month=y%12||y}],Y:[/[+-]?\d+/,g("year")],YY:[s,function(f){this.year=d(f)}],YYYY:[/\d{4}/,g("year")],Z:p,ZZ:p};function u(f){var y,S;y=f,S=r&&r.formats;for(var w=(f=y.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(b,j,L){var _=L&&L.toUpperCase();return j||S[L]||o[L]||S[_].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(A,V,N){return V||N.slice(1)})})).match(n),x=w.length,D=0;D<x;D+=1){var B=w[D],P=k[B],h=P&&P[0],E=P&&P[1];w[D]=E?{regex:h,parser:E}:B.replace(/^\[|\]$/g,"")}return function(b){for(var j={},L=0,_=0;L<x;L+=1){var A=w[L];if(typeof A=="string")_+=A.length;else{var V=A.regex,N=A.parser,z=b.slice(_),C=V.exec(z)[0];N.call(j,C),b=b.replace(C,"")}}return function($){var I=$.afternoon;if(I!==void 0){var O=$.hours;I?O<12&&($.hours+=12):O===12&&($.hours=0),delete $.afternoon}}(j),j}}return function(f,y,S){S.p.customParseFormat=!0,f&&f.parseTwoDigitYear&&(d=f.parseTwoDigitYear);var w=y.prototype,x=w.parse;w.parse=function(D){var B=D.date,P=D.utc,h=D.args;this.$u=P;var E=h[1];if(typeof E=="string"){var b=h[2]===!0,j=h[3]===!0,L=b||j,_=h[2];j&&(_=h[2]),r=this.$locale(),!b&&_&&(r=S.Ls[_]),this.$d=function(z,C,$,I){try{if(["x","X"].indexOf(C)>-1)return new Date((C==="X"?1e3:1)*z);var O=u(C)(z),X=O.year,H=O.month,M=O.day,T=O.hours,Y=O.minutes,W=O.seconds,U=O.milliseconds,G=O.zone,R=O.week,q=new Date,Q=M||(X||H?1:q.getDate()),te=X||q.getFullYear(),ne=0;X&&!H||(ne=H>0?H-1:q.getMonth());var oe,le=T||0,re=Y||0,se=W||0,ce=U||0;return G?new Date(Date.UTC(te,ne,Q,le,re,se,ce+60*G.offset*1e3)):$?new Date(Date.UTC(te,ne,Q,le,re,se,ce)):(oe=new Date(te,ne,Q,le,re,se,ce),R&&(oe=I(oe).week(R).toDate()),oe)}catch{return new Date("")}}(B,E,P,S),this.init(),_&&_!==!0&&(this.$L=this.locale(_).$L),L&&B!=this.format(E)&&(this.$d=new Date("")),r={}}else if(E instanceof Array)for(var A=E.length,V=1;V<=A;V+=1){h[1]=E[V-1];var N=S.apply(this,h);if(N.isValid()){this.$d=N.$d,this.$L=N.$L,this.init();break}V===A&&(this.$d=new Date(""))}else x.call(this,D)}}})})(ut);var ol=ut.exports;const al=ee(ol);var mt={exports:{}};(function(t,l){(function(o,n){t.exports=n()})(J,function(){return function(o,n){var a=n.prototype,s=a.format;a.format=function(c){var i=this,r=this.$locale();if(!this.isValid())return s.bind(this)(c);var d=this.$utils(),g=(c||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,function(p){switch(p){case"Q":return Math.ceil((i.$M+1)/3);case"Do":return r.ordinal(i.$D);case"gggg":return i.weekYear();case"GGGG":return i.isoWeekYear();case"wo":return r.ordinal(i.week(),"W");case"w":case"ww":return d.s(i.week(),p==="w"?1:2,"0");case"W":case"WW":return d.s(i.isoWeek(),p==="W"?1:2,"0");case"k":case"kk":return d.s(String(i.$H===0?24:i.$H),p==="k"?1:2,"0");case"X":return Math.floor(i.$d.getTime()/1e3);case"x":return i.$d.getTime();case"z":return"["+i.offsetName()+"]";case"zzz":return"["+i.offsetName("long")+"]";default:return p}});return s.bind(this)(g)}}})})(mt);var ll=mt.exports;const sl=ee(ll);var cl={exports:{}};(function(t,l){(function(o,n){t.exports=n(ot)})(J,function(o){function n(c){return c&&typeof c=="object"&&"default"in c?c:{default:c}}var a=n(o),s={name:"zh-cn",weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"周日_周一_周二_周三_周四_周五_周六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),ordinal:function(c,i){return i==="W"?c+"周":c+"日"},weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日Ah点mm分",LLLL:"YYYY年M月D日ddddAh点mm分",l:"YYYY/M/D",ll:"YYYY年M月D日",lll:"YYYY年M月D日 HH:mm",llll:"YYYY年M月D日dddd HH:mm"},relativeTime:{future:"%s内",past:"%s前",s:"几秒",m:"1 分钟",mm:"%d 分钟",h:"1 小时",hh:"%d 小时",d:"1 天",dd:"%d 天",M:"1 个月",MM:"%d 个月",y:"1 年",yy:"%d 年"},meridiem:function(c,i){var r=100*c+i;return r<600?"凌晨":r<900?"早上":r<1100?"上午":r<1300?"中午":r<1800?"下午":"晚上"}};return a.default.locale(s,null,!0),s})})(cl);F.extend(Ya);F.extend(Xa);F.extend(Ha);F.extend(Ra);F.extend(Ua);F.extend(qa);F.extend(Qa);F.extend(el);F.extend(nl);F.extend(al);F.extend(sl);function Ve(t={}){const{timezone:l="Asia/Shanghai",locale:o="zh-cn",defaultFormat:n="YYYY-MM-DD HH:mm:ss",parseStrict:a=!1,weekStart:s}=t;F.locale(o);const c=M=>(M==null?F():F(M)).tz(l).locale(o),i=(M,T)=>T?F(M,T,a).tz(l).locale(o):c(M),r=M=>i(M).utc(),d=M=>F(M).utc().tz(l).locale(o),g=e.ref(c()),p=()=>{g.value=c()},v=()=>c(),m=(M,T=n)=>i(M).format(T),k=(M,T)=>i(M,T),u=M=>i(M),f=(M,T,Y)=>i(M).isSame(i(T),Y),y=(M,T,Y)=>i(M).isAfter(i(T),Y),S=(M,T,Y)=>i(M).isBefore(i(T),Y),w=(M,T,Y)=>i(M).isSameOrAfter(i(T),Y),x=(M,T,Y)=>i(M).isSameOrBefore(i(T),Y),D=(M,T,Y,W,U)=>i(M).isBetween(i(T),i(Y),W,U),B=(M,T,Y)=>i(M).add(T,Y),P=(M,T,Y)=>i(M).subtract(T,Y),h=(M,T,Y,W)=>i(M).diff(i(T),Y,W),E=(M,T)=>i(M).startOf(T),b=(M,T)=>i(M).endOf(T),j=M=>i(M).from(c()),L=M=>i(M).to(c()),_=(M,T)=>i(M).from(i(T)),A=(M,T)=>i(M).to(i(T)),V=(M,T=c(),Y="millisecond")=>{const W=i(M).diff(i(T),"millisecond");return F.duration(Math.abs(W)).humanize()},N=M=>{const T=F.duration(M),Y=Math.floor(T.asDays()),W=T.hours(),U=T.minutes(),G=T.seconds();return{days:Y,hours:W,minutes:U,seconds:G}},z=(M,T,Y,W,U)=>{var ce;const G=c().year(M).month(T).date(1),R=G.startOf("month");G.endOf("month");const q=typeof s=="number"?s:((ce=F.Ls[o])==null?void 0:ce.weekStart)??0,Q=R.startOf("week").add(q,"day"),te=Q.isAfter(R)?Q.subtract(7,"day"):Q,ne=Y?i(Y):null,oe=W?i(W).startOf("day"):null,le=U?i(U).endOf("day"):null,re=c(),se=[];for(let ue=0;ue<42;ue++){const ae=te.add(ue,"day"),vt=ae.month()===T,yt=ae.isSame(re,"day"),wt=ne?ae.isSame(ne,"day"):!1,Ne=ae.day(),bt=Ne===0||Ne===6;let be=!1;oe&&ae.isBefore(oe,"day")&&(be=!0),le&&ae.isAfter(le,"day")&&(be=!0),se.push({date:ae,isCurrentMonth:vt,isToday:yt,isSelected:wt,isDisabled:be,isWeekend:bt})}return se},C=(M,T)=>{const Y=c().year(M).month(T).date(1),W=Y.endOf("month"),U=W.date(),G=Y.day(),R=W.day(),q=Math.ceil((G+U)/7);return{firstDay:Y,lastDay:W,daysInMonth:U,firstWeekday:G,lastWeekday:R,weeksInMonth:q}},$=()=>{const M=c();return{today:{start:M.startOf("day"),end:M.endOf("day")},yesterday:{start:M.subtract(1,"day").startOf("day"),end:M.subtract(1,"day").endOf("day")},thisWeek:{start:M.startOf("week"),end:M.endOf("week")},lastWeek:{start:M.subtract(1,"week").startOf("week"),end:M.subtract(1,"week").endOf("week")},thisMonth:{start:M.startOf("month"),end:M.endOf("month")},lastMonth:{start:M.subtract(1,"month").startOf("month"),end:M.subtract(1,"month").endOf("month")},thisYear:{start:M.startOf("year"),end:M.endOf("year")},lastYear:{start:M.subtract(1,"year").startOf("year"),end:M.subtract(1,"year").endOf("year")}}},I=(M,T)=>T?F(M,T,a).isValid():F(M).isValid(),O=(M,T)=>i(M).get(T),X=(M,T,Y)=>i(M).set(T,Y),H={date:"YYYY-MM-DD",time:"HH:mm:ss",datetime:"YYYY-MM-DD HH:mm:ss",dateTime:"YYYY-MM-DD HH:mm",month:"YYYY-MM",year:"YYYY",timestamp:"X",iso:"YYYY-MM-DDTHH:mm:ssZ"};return{now:e.computed(()=>g.value),updateNow:p,getCurrent:v,format:m,parse:k,create:u,isSame:f,isAfter:y,isBefore:S,isSameOrAfter:w,isSameOrBefore:x,isBetween:D,add:B,subtract:P,diff:h,startOf:E,endOf:b,fromNow:j,toNow:L,from:_,to:A,humanizeDiff:V,formatParts:N,getCalendarDates:z,getMonthInfo:C,getTimeRanges:$,isValid:I,getUnit:O,setUnit:X,formats:H,dayjs:M=>i(M),toUTC:r,fromUTC:d}}function il(t={start:null,end:null},l="Asia/Shanghai"){const o=r=>(r==null?F():F(r)).tz(l),n=e.ref({start:t.start?o(t.start):null,end:t.end?o(t.end):null}),a=(r,d)=>{n.value={start:r?o(r):null,end:d?o(d):null}},s=()=>{n.value={start:null,end:null}},c=e.computed(()=>{const{start:r,end:d}=n.value;return!r||!d?!1:r.isBefore(d)||r.isSame(d)}),i=e.computed(()=>{if(!c.value)return null;const r=n.value.end.diff(n.value.start);return{ms:r,days:Math.floor(F.duration(r).asDays())}});return{range:e.computed(()=>n.value),setRange:a,clearRange:s,isValidRange:c,rangeDuration:i}}function rl(t,l="Asia/Shanghai"){const o=g=>(g==null?F():F(g)).tz(l),n=e.ref(o(t)),a=e.ref(o()),s=e.ref(!1),c=e.computed(()=>{const g=n.value.diff(a.value);return g<=0?(s.value=!0,F.duration(0)):F.duration(g)}),i=()=>{a.value=o()},r=(g="HH:mm:ss")=>{if(s.value)return"00:00:00";const p=c.value,v=Math.floor(p.asHours()),m=p.minutes(),k=p.seconds();return g.replace("HH",String(v).padStart(2,"0")).replace("mm",String(m).padStart(2,"0")).replace("ss",String(k).padStart(2,"0"))},d=e.computed(()=>{const g=c.value;return{days:Math.floor(g.asDays()),hours:g.hours(),minutes:g.minutes(),seconds:g.seconds(),milliseconds:g.milliseconds()}});return{target:e.computed(()=>n.value),now:e.computed(()=>a.value),duration:e.computed(()=>c.value),parts:d,isExpired:e.computed(()=>s.value),updateNow:i,formatDuration:r}}const dl=["value","placeholder","disabled"],gl={class:"datetime-icon"},fl={class:"datetime-header"},ul={class:"datetime-title"},ml={key:0,class:"datetime-mode-switch"},hl={key:1,class:"datetime-date-picker"},pl={class:"date-navigation"},vl={class:"current-month"},yl={class:"month-year"},wl={class:"weekdays"},bl={class:"date-grid"},Cl=["onClick"],kl={key:2,class:"datetime-time-picker"},Sl={class:"time-inputs"},xl={class:"time-input-group"},El=["value"],$l={class:"time-input-group"},Ml=["value"],Bl={key:0,class:"time-separator"},Pl={key:1,class:"time-input-group"},jl=["value"],Vl={class:"time-sliders"},Nl={class:"time-slider-group"},Dl=["value"],Al={class:"slider-value"},Tl={class:"time-slider-group"},zl=["value"],Il={class:"slider-value"},Ol={key:0,class:"time-slider-group"},Ll=["value"],Yl={class:"slider-value"},_l={class:"datetime-footer"},Xl=e.defineComponent({__name:"index",props:{modelValue:{default:null},mode:{default:"datetime"},size:{default:"medium"},disabled:{type:Boolean,default:!1},placeholder:{default:"请选择日期时间"},title:{default:"选择日期时间"},showSeconds:{type:Boolean,default:!1},minDate:{},maxDate:{},dateFormat:{default:"YYYY-MM-DD"},timeFormat:{default:"24"},showToday:{type:Boolean,default:!0},showClear:{type:Boolean,default:!0},locale:{default:"zh-CN"}},emits:["update:modelValue","change","open","close"],setup(t,{emit:l}){const o=t,n=l,a=e.ref(!1),s=e.ref("date"),c=e.ref(new Date().getFullYear()),i=e.ref(new Date().getMonth()),r=e.ref(null),d=e.ref(0),g=e.ref(0),p=e.ref(0),v=e.ref(!1),m=e.ref("panel-bottom"),k=e.ref(),{format:u,create:f,getCalendarDates:y,formats:S}=Ve({timezone:"Asia/Shanghai",locale:"zh-cn"}),w=e.computed(()=>o.locale==="zh-CN"?["日","一","二","三","四","五","六"]:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]),x=e.computed(()=>{if(!r.value)return"";const C=f(r.value),$=o.showSeconds?`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}:${p.value.toString().padStart(2,"0")}`:`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}`;return o.mode==="date"?u(C,S.date):o.mode==="time"?$:`${u(C,S.date)} ${$}`}),D=e.computed(()=>o.mode==="date"?"mdi:calendar":o.mode==="time"?"mdi:clock":"mdi:calendar-clock"),B=e.computed(()=>{const C=r.value?f(r.value):void 0,$=o.minDate?f(o.minDate):void 0,I=o.maxDate?f(o.maxDate):void 0;return y(c.value,i.value,C,$,I)}),P=()=>{o.disabled||(a.value=!a.value,a.value?(N(),n("open")):n("close"))},h=()=>{a.value=!1,n("close")},E=()=>{i.value===0?(i.value=11,c.value--):i.value--},b=()=>{i.value===11?(i.value=0,c.value++):i.value++},j=C=>{C.isDisabled||(r.value=C.date.toDate(),o.mode==="date"&&_())},L=()=>{d.value=Math.max(0,Math.min(23,d.value)),g.value=Math.max(0,Math.min(59,g.value)),p.value=Math.max(0,Math.min(59,p.value))},_=()=>{if(o.mode==="date"&&r.value){const C=f(r.value),$=u(C,o.dateFormat);n("update:modelValue",$),n("change",$)}else if(o.mode==="time"){const C=o.showSeconds?`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}:${p.value.toString().padStart(2,"0")}`:`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}`;n("update:modelValue",C),n("change",C)}else if(o.mode==="datetime"&&r.value){const C=f(r.value).hour(d.value).minute(g.value).second(p.value).millisecond(0),$=o.showSeconds?`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}:${p.value.toString().padStart(2,"0")}`:`${d.value.toString().padStart(2,"0")}:${g.value.toString().padStart(2,"0")}`,I=`${u(C,o.dateFormat)} ${$}`;n("update:modelValue",I),n("change",I)}h()},A=()=>{r.value=null,d.value=0,g.value=0,p.value=0,n("update:modelValue",null),n("change",null),h()},V=()=>{v.value=window.innerWidth<=768},N=()=>{if(!k.value)return;const C=k.value.getBoundingClientRect(),I=window.innerHeight-C.bottom,O=C.top;I>=400||I>O?m.value="panel-bottom":m.value="panel-top"};e.watch(()=>o.modelValue,C=>{if(C){const $=f(C);r.value=$.toDate(),d.value=$.hour(),g.value=$.minute(),p.value=$.second(),c.value=$.year(),i.value=$.month()}else r.value=null,d.value=0,g.value=0,p.value=0},{immediate:!0}),e.watch(()=>o.mode,C=>{C==="datetime"?s.value="date":s.value=C},{immediate:!0});const z=C=>{var $;a.value&&!(($=C.target)!=null&&$.closest(".x-datetime-picker"))&&h()};return e.onMounted(()=>{V(),window.addEventListener("resize",V),document.addEventListener("click",z)}),e.onUnmounted(()=>{window.removeEventListener("resize",V),document.removeEventListener("click",z)}),(C,$)=>{const I=e.resolveComponent("XButton");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["x-datetime-picker",[`datetime-${t.size}`,{"datetime-disabled":t.disabled}]])},[e.createElementVNode("div",{class:"datetime-input-wrapper",onClick:P},[e.createElementVNode("input",{ref_key:"inputRef",ref:k,type:"text",value:x.value,placeholder:t.placeholder,disabled:t.disabled,readonly:"",class:"datetime-input"},null,8,dl),e.createElementVNode("div",gl,[e.createVNode(e.unref(K),{icon:D.value},null,8,["icon"])])]),a.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["datetime-panel",m.value])},[e.createElementVNode("div",fl,[e.createElementVNode("div",ul,e.toDisplayString(t.title),1),e.createVNode(I,{icon:"mdi:close",size:"small",onClick:h},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:close"})]),_:1})]),t.mode==="datetime"?(e.openBlock(),e.createElementBlock("div",ml,[e.createVNode(I,{size:"small",class:e.normalizeClass({active:s.value==="date"}),icon:"mdi:calendar",onClick:$[0]||($[0]=O=>s.value="date")},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:calendar"}),$[2]||($[2]=e.createElementVNode("span",null,"日期",-1))]),_:1},8,["class"]),e.createVNode(I,{size:"small",icon:"mdi:clock",class:e.normalizeClass({active:s.value==="time"}),onClick:$[1]||($[1]=O=>s.value="time")},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:clock"}),$[3]||($[3]=e.createElementVNode("span",null,"时间",-1))]),_:1},8,["class"])])):e.createCommentVNode("",!0),s.value==="date"||t.mode==="date"?(e.openBlock(),e.createElementBlock("div",hl,[e.createElementVNode("div",pl,[e.createVNode(I,{size:"small",onClick:E},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:chevron-left"})]),_:1}),e.createElementVNode("div",vl,[e.createElementVNode("span",yl,e.toDisplayString(c.value)+"年"+e.toDisplayString(i.value+1)+"月",1)]),e.createVNode(I,{size:"small",onClick:b},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:chevron-right"})]),_:1})]),e.createElementVNode("div",wl,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,O=>(e.openBlock(),e.createElementBlock("div",{key:O,class:"weekday"},e.toDisplayString(O),1))),128))]),e.createElementVNode("div",bl,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,O=>(e.openBlock(),e.createElementBlock("div",{key:O.date.format("YYYY-MM-DD"),class:e.normalizeClass(["date-cell",{"date-other-month":!O.isCurrentMonth,"date-today":O.isToday,"date-selected":O.isSelected,"date-disabled":O.isDisabled}]),onClick:X=>j(O)},e.toDisplayString(O.date.date()),11,Cl))),128))])])):e.createCommentVNode("",!0),s.value==="time"||t.mode==="time"?(e.openBlock(),e.createElementBlock("div",kl,[e.createElementVNode("div",Sl,[e.createElementVNode("div",xl,[$[4]||($[4]=e.createElementVNode("label",{class:"time-label"},"时",-1)),e.createElementVNode("input",{value:d.value,type:"number",min:"0",max:"23",class:"time-input",onChange:L},null,40,El)]),$[7]||($[7]=e.createElementVNode("div",{class:"time-separator"},":",-1)),e.createElementVNode("div",$l,[$[5]||($[5]=e.createElementVNode("label",{class:"time-label"},"分",-1)),e.createElementVNode("input",{value:g.value,type:"number",min:"0",max:"59",class:"time-input",onChange:L},null,40,Ml)]),t.showSeconds?(e.openBlock(),e.createElementBlock("div",Bl,":")):e.createCommentVNode("",!0),t.showSeconds?(e.openBlock(),e.createElementBlock("div",Pl,[$[6]||($[6]=e.createElementVNode("label",{class:"time-label"},"秒",-1)),e.createElementVNode("input",{value:p.value,type:"number",min:"0",max:"59",class:"time-input",onChange:L},null,40,jl)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",Vl,[e.createElementVNode("div",Nl,[$[8]||($[8]=e.createElementVNode("label",{class:"slider-label"},"小时",-1)),e.createElementVNode("input",{value:d.value,type:"range",min:"0",max:"23",class:"time-slider",onInput:L},null,40,Dl),e.createElementVNode("span",Al,e.toDisplayString(d.value.toString().padStart(2,"0")),1)]),e.createElementVNode("div",Tl,[$[9]||($[9]=e.createElementVNode("label",{class:"slider-label"},"分钟",-1)),e.createElementVNode("input",{value:g.value,type:"range",min:"0",max:"59",class:"time-slider",onInput:L},null,40,zl),e.createElementVNode("span",Il,e.toDisplayString(g.value.toString().padStart(2,"0")),1)]),t.showSeconds?(e.openBlock(),e.createElementBlock("div",Ol,[$[10]||($[10]=e.createElementVNode("label",{class:"slider-label"},"秒钟",-1)),e.createElementVNode("input",{value:p.value,type:"range",min:"0",max:"59",step:"1",class:"time-slider",onInput:L},null,40,Ll),e.createElementVNode("span",Yl,e.toDisplayString(p.value.toString().padStart(2,"0")),1)])):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),e.createElementVNode("div",_l,[e.createVNode(I,{size:"small",ghost:"",type:"danger",onClick:A},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:delete"}),$[11]||($[11]=e.createElementVNode("span",null,"清空",-1))]),_:1}),e.createVNode(I,{size:"small",ghost:"",type:"primary",onClick:_},{default:e.withCtx(()=>[e.createVNode(e.unref(K),{icon:"mdi:check"}),$[12]||($[12]=e.createElementVNode("span",null,"确定",-1))]),_:1})])],2)):e.createCommentVNode("",!0)],2)}}}),Fl=Z(Xl,[["__scopeId","data-v-44868cc1"]]),ht=()=>{const t=()=>{let d=document.getElementById("xl-message-container");return d||(d=document.createElement("div"),d.id="xl-message-container",d.style.cssText=`
|
2
2
|
position: fixed;
|
3
3
|
top: 20px;
|
4
4
|
right: 20px;
|
@@ -6,10 +6,10 @@
|
|
6
6
|
display: flex;
|
7
7
|
flex-direction: column;
|
8
8
|
gap: 10px;
|
9
|
-
`,document.body.appendChild(d)),d},l=d=>{const g={success:{bgColor:"#f0fdf4",borderColor:"#86efac",textColor:"#166534",iconColor:"#22c55e",iconSvg:'<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/></svg>'},error:{bgColor:"#fef2f2",borderColor:"#fca5a5",textColor:"#991b1b",iconColor:"#ef4444",iconSvg:'<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"/></svg>'},warning:{bgColor:"#fefce8",borderColor:"#fde047",textColor:"#854d0e",iconColor:"#eab308",iconSvg:'<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/></svg>'},info:{bgColor:"#f8fafc",borderColor:"#cbd5e1",textColor:"#1e293b",iconColor:"#64748b",iconSvg:'<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"/></svg>'}};return g[d]||g.info},o=d=>{const g=t(),p=d.type||"info",v=d.duration!==void 0?d.duration:3e3,
|
10
|
-
background-color: ${
|
11
|
-
border: 1px solid ${
|
12
|
-
color: ${
|
9
|
+
`,document.body.appendChild(d)),d},l=d=>{const g={success:{bgColor:"#f0fdf4",borderColor:"#86efac",textColor:"#166534",iconColor:"#22c55e",iconSvg:'<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/></svg>'},error:{bgColor:"#fef2f2",borderColor:"#fca5a5",textColor:"#991b1b",iconColor:"#ef4444",iconSvg:'<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"/></svg>'},warning:{bgColor:"#fefce8",borderColor:"#fde047",textColor:"#854d0e",iconColor:"#eab308",iconSvg:'<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/></svg>'},info:{bgColor:"#f8fafc",borderColor:"#cbd5e1",textColor:"#1e293b",iconColor:"#64748b",iconSvg:'<svg width="20" height="20" viewBox="0 0 24 24" fill="currentColor"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"/></svg>'}};return g[d]||g.info},o=d=>{const g=t(),p=d.type||"info",v=d.duration!==void 0?d.duration:3e3,m=l(p),k=`xl-msg-${Date.now()}-${Math.random().toString(36).substr(2,9)}`,u=document.createElement("div");u.id=k,u.style.cssText=`
|
10
|
+
background-color: ${m.bgColor};
|
11
|
+
border: 1px solid ${m.borderColor};
|
12
|
+
color: ${m.textColor};
|
13
13
|
border-radius: 12px;
|
14
14
|
padding: 16px;
|
15
15
|
box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
|
@@ -20,27 +20,27 @@
|
|
20
20
|
pointer-events: auto;
|
21
21
|
`,u.innerHTML=`
|
22
22
|
<div style="display: flex; align-items: flex-start; gap: 12px;">
|
23
|
-
<div style="flex-shrink: 0; color: ${
|
24
|
-
${
|
23
|
+
<div style="flex-shrink: 0; color: ${m.iconColor}; margin-top: 2px;">
|
24
|
+
${m.iconSvg}
|
25
25
|
</div>
|
26
26
|
<div style="flex: 1; min-width: 0;">
|
27
|
-
<div style="font-size: 14px; font-weight: 500; line-height: 1.5; color: ${
|
27
|
+
<div style="font-size: 14px; font-weight: 500; line-height: 1.5; color: ${m.textColor};">
|
28
28
|
${d.title}
|
29
29
|
</div>
|
30
|
-
${d.content?`<div style="margin-top: 4px; font-size: 13px; line-height: 1.5; color: ${
|
30
|
+
${d.content?`<div style="margin-top: 4px; font-size: 13px; line-height: 1.5; color: ${m.textColor}; opacity: 0.8;">${d.content}</div>`:""}
|
31
31
|
</div>
|
32
32
|
<button
|
33
|
-
style="flex-shrink: 0; background: none; border: none; padding: 4px; cursor: pointer; color: ${
|
33
|
+
style="flex-shrink: 0; background: none; border: none; padding: 4px; cursor: pointer; color: ${m.textColor}; opacity: 0.5; border-radius: 4px; transition: all 0.15s; display: flex; align-items: center; justify-content: center;"
|
34
34
|
onmouseover="this.style.opacity='1'; this.style.backgroundColor='rgba(0,0,0,0.05)';"
|
35
35
|
onmouseout="this.style.opacity='0.5'; this.style.backgroundColor='transparent';"
|
36
|
-
onclick="document.getElementById('${
|
36
|
+
onclick="document.getElementById('${k}')?.remove()"
|
37
37
|
>
|
38
38
|
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round">
|
39
39
|
<path d="M18 6L6 18M6 6l12 12"/>
|
40
40
|
</svg>
|
41
41
|
</button>
|
42
42
|
</div>
|
43
|
-
`,g.appendChild(u),requestAnimationFrame(()=>{requestAnimationFrame(()=>{u.style.transform="translateX(0)",u.style.opacity="1"})}),v>0&&setTimeout(()=>{n(
|
43
|
+
`,g.appendChild(u),requestAnimationFrame(()=>{requestAnimationFrame(()=>{u.style.transform="translateX(0)",u.style.opacity="1"})}),v>0&&setTimeout(()=>{n(k)},v)},n=d=>{const g=document.getElementById(d);g&&(g.style.transform="translateX(100%)",g.style.opacity="0",setTimeout(()=>{g.parentNode&&g.parentNode.removeChild(g)},300))};return{show:o,confirm:d=>{const g=d.type||"info",p=l(g),v=`xl-confirm-${Date.now()}`,m=document.createElement("div");m.id=v,m.style.cssText=`
|
44
44
|
position: fixed;
|
45
45
|
inset: 0;
|
46
46
|
z-index: 9999;
|
@@ -51,7 +51,7 @@
|
|
51
51
|
opacity: 0;
|
52
52
|
transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
|
53
53
|
backdrop-filter: blur(4px);
|
54
|
-
`;const
|
54
|
+
`;const k=`
|
55
55
|
<div class="xl-confirm-dialog" style="
|
56
56
|
background-color: white;
|
57
57
|
border-radius: 12px;
|
@@ -125,7 +125,7 @@
|
|
125
125
|
</div>
|
126
126
|
</div>
|
127
127
|
</div>
|
128
|
-
`;
|
128
|
+
`;m.innerHTML=k,document.body.appendChild(m),requestAnimationFrame(()=>{m.style.opacity="1";const w=m.querySelector(".xl-confirm-dialog");w&&requestAnimationFrame(()=>{w.style.transform="scale(1)",w.style.opacity="1"})});const u=m.querySelector(".xl-confirm-ok"),f=m.querySelector(".xl-confirm-cancel"),y=()=>{const w=m.querySelector(".xl-confirm-dialog");w&&(w.style.transform="scale(0.95)",w.style.opacity="0"),m.style.opacity="0",setTimeout(()=>{m.parentNode&&m.parentNode.removeChild(m)},300)};u==null||u.addEventListener("click",()=>{var w;(w=d.onConfirm)==null||w.call(d),y()}),f==null||f.addEventListener("click",()=>{var w;(w=d.onCancel)==null||w.call(d),y()}),m.addEventListener("click",w=>{var x;w.target===m&&((x=d.onCancel)==null||x.call(d),y())});const S=w=>{var x;w.key==="Escape"&&((x=d.onCancel)==null||x.call(d),y(),document.removeEventListener("keydown",S))};document.addEventListener("keydown",S)},success:(d,g,p)=>{o({title:d,content:g,type:"success",duration:p})},error:(d,g,p)=>{o({title:d,content:g,type:"error",duration:p})},warning:(d,g,p)=>{o({title:d,content:g,type:"warning",duration:p})},info:(d,g,p)=>{o({title:d,content:g,type:"info",duration:p})},remove:n}},pt=()=>{const t=()=>{let r=document.getElementById("xl-alert-container");return r||(r=document.createElement("div"),r.id="xl-alert-container",r.style.cssText=`
|
129
129
|
position: fixed;
|
130
130
|
top: 5%;
|
131
131
|
left: 50%;
|
@@ -144,10 +144,10 @@
|
|
144
144
|
<path d="M13 16h-1v-4h1m0-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" stroke-width="2" stroke-linejoin="round" stroke-linecap="round"></path>
|
145
145
|
</svg>`},info:{bgColor:"rgb(239, 246, 255)",darkBgColor:"rgb(30, 58, 138)",borderColor:"rgb(147, 197, 253)",darkBorderColor:"rgb(29, 78, 216)",textColor:"rgb(30, 64, 175)",darkTextColor:"rgb(191, 219, 254)",iconColor:"rgb(59, 130, 246)",iconSvg:`<svg stroke="currentColor" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
146
146
|
<path d="M13 16h-1v-4h1m0-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" stroke-width="2" stroke-linejoin="round" stroke-linecap="round"></path>
|
147
|
-
</svg>`}};return d[r]||d.info},o=()=>window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,n=r=>{const d=t(),g=r.type||"info",p=r.duration!==void 0?r.duration:5e3,v=r.closable!==void 0?r.closable:!0,
|
148
|
-
background-color: ${
|
149
|
-
border-left: 4px solid ${
|
150
|
-
color: ${
|
147
|
+
</svg>`}};return d[r]||d.info},o=()=>window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches,n=r=>{const d=t(),g=r.type||"info",p=r.duration!==void 0?r.duration:5e3,v=r.closable!==void 0?r.closable:!0,m=l(g),k=o(),u=`xl-alert-${Date.now()}-${Math.random().toString(36).substr(2,9)}`,f=document.createElement("div");f.id=u,f.setAttribute("role","alert"),f.style.cssText=`
|
148
|
+
background-color: ${k?m.darkBgColor:m.bgColor};
|
149
|
+
border-left: 4px solid ${k?m.darkBorderColor:m.borderColor};
|
150
|
+
color: ${k?m.darkTextColor:m.textColor};
|
151
151
|
padding: 16px;
|
152
152
|
border-radius: 12px;
|
153
153
|
display: flex;
|
@@ -158,8 +158,8 @@
|
|
158
158
|
opacity: 0;
|
159
159
|
position: relative;
|
160
160
|
`;let y=`
|
161
|
-
<div style="color: ${
|
162
|
-
${
|
161
|
+
<div style="color: ${m.iconColor}; width: 20px; height: 20px; flex-shrink: 0; margin-right: 12px;">
|
162
|
+
${m.iconSvg}
|
163
163
|
</div>
|
164
164
|
<div style="flex: 1;">
|
165
165
|
${r.title?`<p style="font-weight: 600; font-size: 14px; margin-bottom: 4px;">${r.title}</p>`:""}
|
@@ -171,7 +171,7 @@
|
|
171
171
|
style="
|
172
172
|
background: transparent;
|
173
173
|
border: none;
|
174
|
-
color: ${
|
174
|
+
color: ${k?m.darkTextColor:m.textColor};
|
175
175
|
cursor: pointer;
|
176
176
|
padding: 4px;
|
177
177
|
margin-left: 8px;
|
@@ -192,4 +192,4 @@
|
|
192
192
|
<line x1="6" y1="6" x2="18" y2="18"></line>
|
193
193
|
</svg>
|
194
194
|
</button>
|
195
|
-
`),f.innerHTML=y;const
|
195
|
+
`),f.innerHTML=y;const S=()=>{f.style.transform="scale(0.8)",f.style.opacity="0",setTimeout(()=>{f.parentNode&&d.removeChild(f),d.children.length===0&&document.body.removeChild(d)},300)};if(v){const w=f.querySelector(".xl-alert-close");w&&w.addEventListener("click",S)}return d.appendChild(f),setTimeout(()=>{f.style.transform="scale(1)",f.style.opacity="1"},10),p>0&&setTimeout(S,p),{close:S}};return{show:n,success:(r,d)=>n({content:r,type:"success",...d}),error:(r,d)=>n({content:r,type:"error",...d}),warning:(r,d)=>n({content:r,type:"warning",...d}),info:(r,d)=>n({content:r,type:"info",...d})}};exports.XAccordion=Ro;exports.XButton=Me;exports.XCard=Zn;exports.XCheckboxes=Lo;exports.XCountrySelect=so;exports.XDateTimePicker=Fl;exports.XInput=jo;exports.XModal=ca;exports.XRadio=Oa;exports.XScore=xa;exports.XSelect=$o;exports.XSkeleton=ea;exports.XSwitch=va;exports.XThumbnailContainer=Qo;exports.XTooltips=ua;exports.useAlert=pt;exports.useCountdown=rl;exports.useDateRange=il;exports.useDateTime=Ve;exports.useDateTimeDefault=Ve;exports.useMsg=ht;exports.xlAlert=pt;exports.xlMsg=ht;
|