const e=require("../_util/type.js"),t=require("../_util/props-util/index.js"),n=require("../config-provider/hooks/useConfigInject.js"),r=require("./style/index.js");let i=require("vue");var a=()=>({prefixCls:String,type:{type:String,default:`horizontal`},dashed:{type:Boolean,default:!1},orientation:{type:String,default:`center`},plain:{type:Boolean,default:!1},orientationMargin:[String,Number]}),o=(0,i.defineComponent)({name:`ADivider`,inheritAttrs:!1,compatConfig:{MODE:3},props:a(),setup(e,{slots:a,attrs:o}){let{prefixCls:s,direction:c}=n.default(`divider`,e),[l,u]=r.default(s),d=(0,i.computed)(()=>e.orientation===`left`&&e.orientationMargin!=null),f=(0,i.computed)(()=>e.orientation===`right`&&e.orientationMargin!=null),p=(0,i.computed)(()=>{let{type:t,dashed:n,plain:r}=e,i=s.value;return{[i]:!0,[u.value]:!!u.value,[`${i}-${t}`]:!0,[`${i}-dashed`]:!!n,[`${i}-plain`]:!!r,[`${i}-rtl`]:c.value===`rtl`,[`${i}-no-default-orientation-margin-left`]:d.value,[`${i}-no-default-orientation-margin-right`]:f.value}}),m=(0,i.computed)(()=>{let t=typeof e.orientationMargin==`number`?`${e.orientationMargin}px`:e.orientationMargin;return{...d.value&&{marginLeft:t},...f.value&&{marginRight:t}}}),h=(0,i.computed)(()=>e.orientation.length>0?`-${e.orientation}`:e.orientation);return()=>{let e=t.flattenChildren(a.default?.());return l((0,i.createVNode)(`div`,{...o,class:[p.value,e.length?`${s.value}-with-text ${s.value}-with-text${h.value}`:``,o.class],role:`separator`},[e.length?(0,i.createVNode)(`span`,{class:`${s.value}-inner-text`,style:m.value},[e]):null]))}}}),s=e.withInstall(o);exports.default=s,exports.dividerProps=a;