import{D as N,E as O,d$ as R,az as j,W as P,a0 as U,d as D,O as w,J as y,Q as k,f as d,U as v,G as X,aY as q,aA as G,e0 as J,bq as Q,c0 as V,a7 as z,dL as Y,aj as K}from"./outputWidgets.75a5b0b9.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},t=new Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="f5ccca70-26a9-49da-8403-16c958a13d96",e._sentryDebugIdIdentifier="sentry-dbid-f5ccca70-26a9-49da-8403-16c958a13d96")}catch{}})();const f=(e,t,o)=>{const a=R(o);return{[`${e.componentCls}-${t}`]:{color:e[`color${o}`],background:e[`color${a}Bg`],borderColor:e[`color${a}Border`]}}},Z=e=>j(e,(t,o)=>{let{textColor:a,lightBorderColor:n,lightColor:l,darkColor:r}=o;return{[`${e.componentCls}-${t}`]:{color:a,background:l,borderColor:n,"&-inverse":{color:e.colorTextLightSolid,background:r,borderColor:r}}}}),ee=e=>{const{paddingXXS:t,lineWidth:o,tagPaddingHorizontal:a,componentCls:n}=e,l=a-o,r=t-o;return{[n]:P(P({},U(e)),{display:"inline-block",height:"auto",marginInlineEnd:e.marginXS,paddingInline:l,fontSize:e.tagFontSize,lineHeight:`${e.tagLineHeight}px`,whiteSpace:"nowrap",background:e.tagDefaultBg,border:`${e.lineWidth}px ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,opacity:1,transition:`all ${e.motionDurationMid}`,textAlign:"start",[`&${n}-rtl`]:{direction:"rtl"},"&, a, a:hover":{color:e.tagDefaultColor},[`${n}-close-icon`]:{marginInlineStart:r,color:e.colorTextDescription,fontSize:e.tagIconSize,cursor:"pointer",transition:`all ${e.motionDurationMid}`,"&:hover":{color:e.colorTextHeading}},[`&${n}-has-color`]:{borderColor:"transparent",[`&, a, a:hover, ${e.iconCls}-close, ${e.iconCls}-close:hover`]:{color:e.colorTextLightSolid}},["&-checkable"]:{backgroundColor:"transparent",borderColor:"transparent",cursor:"pointer",[`&:not(${n}-checkable-checked):hover`]:{color:e.colorPrimary,backgroundColor:e.colorFillSecondary},"&:active, &-checked":{color:e.colorTextLightSolid},"&-checked":{backgroundColor:e.colorPrimary,"&:hover":{backgroundColor:e.colorPrimaryHover}},"&:active":{backgroundColor:e.colorPrimaryActive}},["&-hidden"]:{display:"none"},[`> ${e.iconCls} + span, > span + ${e.iconCls}`]:{marginInlineStart:l}})}},A=N("Tag",e=>{const{fontSize:t,lineHeight:o,lineWidth:a,fontSizeIcon:n}=e,l=Math.round(t*o),r=e.fontSizeSM,g=l-a*2,h=e.colorFillAlter,s=e.colorText,c=O(e,{tagFontSize:r,tagLineHeight:g,tagDefaultBg:h,tagDefaultColor:s,tagIconSize:n-2*a,tagPaddingHorizontal:8});return[ee(c),Z(c),f(c,"success","Success"),f(c,"processing","Info"),f(c,"error","Error"),f(c,"warning","Warning")]}),oe=()=>({prefixCls:String,checked:{type:Boolean,default:void 0},onChange:{type:Function},onClick:{type:Function},"onUpdate:checked":Function}),le=D({compatConfig:{MODE:3},name:"ACheckableTag",inheritAttrs:!1,props:oe(),setup(e,t){let{slots:o,emit:a,attrs:n}=t;const{prefixCls:l}=w("tag",e),[r,g]=A(l),h=c=>{const{checked:u}=e;a("update:checked",!u),a("change",!u),a("click",c)},s=y(()=>k(l.value,g.value,{[`${l.value}-checkable`]:!0,[`${l.value}-checkable-checked`]:e.checked}));return()=>{var c;return r(d("span",v(v({},n),{},{class:s.value,onClick:h}),[(c=o.default)===null||c===void 0?void 0:c.call(o)]))}}}),S=le,ae=()=>({prefixCls:String,color:{type:String},closable:{type:Boolean,default:!1},closeIcon:z.any,visible:{type:Boolean,default:void 0},onClose:{type:Function},onClick:Y(),"onUpdate:visible":Function,icon:z.any}),C=D({compatConfig:{MODE:3},name:"ATag",inheritAttrs:!1,props:ae(),slots:Object,setup(e,t){let{slots:o,emit:a,attrs:n}=t;const{prefixCls:l,direction:r}=w("tag",e),[g,h]=A(l),s=X(!0);q(()=>{e.visible!==void 0&&(s.value=e.visible)});const c=i=>{i.stopPropagation(),a("update:visible",!1),a("close",i),!i.defaultPrevented&&e.visible===void 0&&(s.value=!1)},u=y(()=>G(e.color)||J(e.color)),B=y(()=>k(l.value,h.value,{[`${l.value}-${e.color}`]:u.value,[`${l.value}-has-color`]:e.color&&!u.value,[`${l.value}-hidden`]:!s.value,[`${l.value}-rtl`]:r.value==="rtl"})),F=i=>{a("click",i)};return()=>{var i,b,p;const{icon:H=(i=o.icon)===null||i===void 0?void 0:i.call(o),color:m,closeIcon:$=(b=o.closeIcon)===null||b===void 0?void 0:b.call(o),closable:_=!1}=e,M=()=>_?$?d("span",{class:`${l.value}-close-icon`,onClick:c},[$]):d(K,{class:`${l.value}-close-icon`,onClick:c},null):null,E={backgroundColor:m&&!u.value?m:void 0},I=H||null,T=(p=o.default)===null||p===void 0?void 0:p.call(o),W=I?d(Q,null,[I,d("span",null,[T])]):T,L=e.onClick!==void 0,x=d("span",v(v({},n),{},{onClick:F,class:[B.value,n.class],style:[E,n.style]}),[W,M()]);return g(L?d(V,null,{default:()=>[x]}):x)}}});C.CheckableTag=S;C.install=function(e){return e.component(C.name,C),e.component(S.name,S),e};const ce=C;export{ce as A,S as C};
//# sourceMappingURL=index.e24c456b.js.map
