System.register(["./index-legacy.DjPCm-Xr.js","./index-legacy.sLMPZLm9.js","./compact-item-legacy.3e1PWnds.js","./_getTag-legacy.CG1mexpa.js"],(function(e,t){"use strict";var l,i,n,r,c,a,o,s,u,m,p,v,d,f,g,y,I,$,x,S;return{setters:[e=>{l=e.g,i=e.b,n=e.o,r=e.P,c=e.j,a=e.n,o=e.d,s=e.t},e=>{u=e.i,m=e.d,p=e.l},e=>{v=e.c},e=>{d=e.c,f=e.d,g=e.e,y=e.f,I=e.g,$=e.h,x=e.j,S=e.k}],execute:function(){const t=e=>{const{componentCls:t}=e;return{[t]:{display:"inline-flex","&-block":{display:"flex",width:"100%"},"&-vertical":{flexDirection:"column"}}}},h=e=>{const{componentCls:t}=e;return{[t]:{display:"inline-flex","&-rtl":{direction:"rtl"},"&-vertical":{flexDirection:"column"},"&-align":{flexDirection:"column","&-center":{alignItems:"center"},"&-start":{alignItems:"flex-start"},"&-end":{alignItems:"flex-end"},"&-baseline":{alignItems:"baseline"}},[`${t}-item`]:{"&:empty":{display:"none"}}}}},b=e("a",l("Space",(e=>[h(e),t(e)])));var j=Object.prototype.hasOwnProperty;function z(e){if(null==e)return!0;if(d(e)&&(f(e)||"string"==typeof e||"function"==typeof e.splice||g(e)||y(e)||I(e)))return!e.length;var t=$(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(x(e))return!S(e).length;for(var l in e)if(j.call(e,l))return!1;return!0}const C=v(null),D=(e("u",((e,t)=>{const l=C.useInject(),n=u((()=>{if(!l||z(l))return"";const{compactDirection:n,isFirstItem:r,isLastItem:c}=l,a="vertical"===n?"-vertical-":"-";return i({[`${e.value}-compact${a}item`]:!0,[`${e.value}-compact${a}first-item`]:r,[`${e.value}-compact${a}last-item`]:c,[`${e.value}-compact${a}item-rtl`]:"rtl"===t.value})}));return{compactSize:u((()=>null==l?void 0:l.compactSize)),compactDirection:u((()=>null==l?void 0:l.compactDirection)),compactItemClassnames:n}})),e("N",m({name:"NoCompactStyle",setup(e,t){let{slots:l}=t;return C.useProvide(null),()=>{var e;return null===(e=l.default)||void 0===e?void 0:e.call(l)}}})),m({name:"CompactItem",props:{compactSize:String,compactDirection:r.oneOf(s("horizontal","vertical")).def("horizontal"),isFirstItem:n(),isLastItem:n()},setup(e,t){let{slots:l}=t;return C.useProvide(e),()=>{var e;return null===(e=l.default)||void 0===e?void 0:e.call(l)}}}));e("C",m({name:"ASpaceCompact",inheritAttrs:!1,props:{prefixCls:String,size:{type:String},direction:r.oneOf(s("horizontal","vertical")).def("horizontal"),align:r.oneOf(s("start","end","center","baseline")),block:{type:Boolean,default:void 0}},setup(e,t){let{attrs:l,slots:n}=t;const{prefixCls:r,direction:s}=c("space-compact",e),m=C.useInject(),[v,d]=b(r),f=u((()=>i(r.value,d.value,{[`${r.value}-rtl`]:"rtl"===s.value,[`${r.value}-block`]:e.block,[`${r.value}-vertical`]:"vertical"===e.direction})));return()=>{var t;const i=a((null===(t=n.default)||void 0===t?void 0:t.call(n))||[]);return 0===i.length?null:v(p("div",o(o({},l),{},{class:[f.value,l.class]}),[i.map(((t,l)=>{var n;const c=t&&t.key||`${r.value}-item-${l}`,a=!m||z(m);return p(D,{key:c,compactSize:null!==(n=e.size)&&void 0!==n?n:"middle",compactDirection:e.direction,isFirstItem:0===l&&(a||(null==m?void 0:m.isFirstItem)),isLastItem:l===i.length-1&&(a||(null==m?void 0:m.isLastItem))},{default:()=>[t]})}))]))}}}))}}}));
