import{k as P,m as W,o as j,D as d,F as T,ay as D,r as c,c as H}from"./createLucideIcon-BcINIXoS.js";const G=t=>{const{componentCls:e}=t;return{[e]:{"&-horizontal":{[`&${e}`]:{"&-sm":{marginBlock:t.marginXS},"&-md":{marginBlock:t.margin}}}}}},A=t=>{const{componentCls:e,sizePaddingEdgeHorizontal:o,colorSplit:r,lineWidth:n,textPaddingInline:g,orientationMargin:l,verticalMarginInline:s}=t;return{[e]:Object.assign(Object.assign({},j(t)),{borderBlockStart:`${d(n)} solid ${r}`,"&-vertical":{position:"relative",top:"-0.06em",display:"inline-block",height:"0.9em",marginInline:s,marginBlock:0,verticalAlign:"middle",borderTop:0,borderInlineStart:`${d(n)} solid ${r}`},"&-horizontal":{display:"flex",clear:"both",width:"100%",minWidth:"100%",margin:`${d(t.marginLG)} 0`},[`&-horizontal${e}-with-text`]:{display:"flex",alignItems:"center",margin:`${d(t.dividerHorizontalWithTextGutterMargin)} 0`,color:t.colorTextHeading,fontWeight:500,fontSize:t.fontSizeLG,whiteSpace:"nowrap",textAlign:"center",borderBlockStart:`0 ${r}`,"&::before, &::after":{position:"relative",width:"50%",borderBlockStart:`${d(n)} solid transparent`,borderBlockStartColor:"inherit",borderBlockEnd:0,transform:"translateY(50%)",content:"''"}},[`&-horizontal${e}-with-text-start`]:{"&::before":{width:`calc(${l} * 100%)`},"&::after":{width:`calc(100% - ${l} * 100%)`}},[`&-horizontal${e}-with-text-end`]:{"&::before":{width:`calc(100% - ${l} * 100%)`},"&::after":{width:`calc(${l} * 100%)`}},[`${e}-inner-text`]:{display:"inline-block",paddingBlock:0,paddingInline:g},"&-dashed":{background:"none",borderColor:r,borderStyle:"dashed",borderWidth:`${d(n)} 0 0`},[`&-horizontal${e}-with-text${e}-dashed`]:{"&::before, &::after":{borderStyle:"dashed none none"}},[`&-vertical${e}-dashed`]:{borderInlineStartWidth:n,borderInlineEnd:0,borderBlockStart:0,borderBlockEnd:0},"&-dotted":{background:"none",borderColor:r,borderStyle:"dotted",borderWidth:`${d(n)} 0 0`},[`&-horizontal${e}-with-text${e}-dotted`]:{"&::before, &::after":{borderStyle:"dotted none none"}},[`&-vertical${e}-dotted`]:{borderInlineStartWidth:n,borderInlineEnd:0,borderBlockStart:0,borderBlockEnd:0},[`&-plain${e}-with-text`]:{color:t.colorText,fontWeight:"normal",fontSize:t.fontSize},[`&-horizontal${e}-with-text-start${e}-no-default-orientation-margin-start`]:{"&::before":{width:0},"&::after":{width:"100%"},[`${e}-inner-text`]:{paddingInlineStart:o}},[`&-horizontal${e}-with-text-end${e}-no-default-orientation-margin-end`]:{"&::before":{width:"100%"},"&::after":{width:0},[`${e}-inner-text`]:{paddingInlineEnd:o}}})}},F=t=>({textPaddingInline:"1em",orientationMargin:.05,verticalMarginInline:t.marginXS}),L=P("Divider",t=>{const e=W(t,{dividerHorizontalWithTextGutterMargin:t.margin,sizePaddingEdgeHorizontal:0});return[A(e),G(e)]},F,{unitless:{orientationMargin:!0}});var V=function(t,e){var o={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(o[r]=t[r]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,r=Object.getOwnPropertySymbols(t);n<r.length;n++)e.indexOf(r[n])<0&&Object.prototype.propertyIsEnumerable.call(t,r[n])&&(o[r[n]]=t[r[n]]);return o};const X={small:"sm",middle:"md"},Y=t=>{const{getPrefixCls:e,direction:o,className:r,style:n}=T("divider"),{prefixCls:g,type:l="horizontal",orientation:s="center",orientationMargin:a,className:x,rootClassName:y,children:h,dashed:z,variant:f="solid",plain:v,style:w,size:C}=t,I=V(t,["prefixCls","type","orientation","orientationMargin","className","rootClassName","children","dashed","variant","plain","style","size"]),i=e("divider",g),[O,M,E]=L(i),B=D(C),b=X[B],$=!!h,m=c.useMemo(()=>s==="left"?o==="rtl"?"end":"start":s==="right"?o==="rtl"?"start":"end":s,[o,s]),p=m==="start"&&a!=null,S=m==="end"&&a!=null,N=H(i,r,M,E,`${i}-${l}`,{[`${i}-with-text`]:$,[`${i}-with-text-${m}`]:$,[`${i}-dashed`]:!!z,[`${i}-${f}`]:f!=="solid",[`${i}-plain`]:!!v,[`${i}-rtl`]:o==="rtl",[`${i}-no-default-orientation-margin-start`]:p,[`${i}-no-default-orientation-margin-end`]:S,[`${i}-${b}`]:!!b},x,y),u=c.useMemo(()=>typeof a=="number"?a:/^\d+$/.test(a)?Number(a):a,[a]),k={marginInlineStart:p?u:void 0,marginInlineEnd:S?u:void 0};return O(c.createElement("div",Object.assign({className:N,style:Object.assign(Object.assign({},n),w)},I,{role:"separator"}),h&&l!=="vertical"&&c.createElement("span",{className:`${i}-inner-text`,style:k},h)))};export{Y as D};
