import { b9 as y, ca as c, cb as h, ba as $, bv as b, cc as g, bB as m, cd as x, bA as u, U as f, V as i, P as a, bh as d, bi as r, bj as o, a0 as t, bg as l, bl as p, c1 as w, bo as n, bG as v, ce as C } from "./684d2f28.js";
import { useContext as s } from "react";
import "react-dom";
const S = y(C)`
  margin-top: 3.5px;
  .ant-divider-inner-text {
    height: 32px;
    display: flex;
    align-items: center;
    font-size: ${(e) => e.$style.textSize};
    font-weight: ${(e) => e.$style.textWeight};
    font-family: ${(e) => e.$style.fontFamily};
    text-transform:${(e) => e.$style.textTransform};
    text-decoration:${(e) => e.$style.textDecoration};
    font-style:${(e) => e.$style.fontStyle}
  }
  min-width: 0;	
  width: ${(e) => c(e.$style.margin)};	
  min-height: ${(e) => h(e.$style.margin)};	
  margin: ${(e) => e.$style.margin};	
  padding: ${(e) => e.$style.padding};
  
  border-top: ${(e) => e.$style.borderWidth ? e.$style.borderWidth : "1px"} ${(e) => e.dashed ? "dashed" : "solid"} ${(e) => e.$style.color};

  .ant-divider-inner-text::before, .ant-divider-inner-text::after {
    border-block-start: ${(e) => e.$style.borderWidth ? e.$style.borderWidth : "1px"} ${(e) => e.dashed ? "dashed" : "solid"} ${(e) => e.$style.color} !important;
    border-block-start-color: inherit;
    border-block-end: 0;
  }

  &.ant-divider-horizontal.ant-divider-with-text {
    margin: 0;
    border-top-color: ${(e) => e.$style.color};
    color: ${(e) => e.$style.text};
  }
`, V = {
  title: $,
  dashed: b,
  align: g(),
  style: m(x)
};
function D(e) {
  return e && e.hasOwnProperty("color") ? {
    ...e,
    style: {
      color: e.color,
      text: ""
    }
  } : e;
}
const j = u(new f(V, (e) => /* @__PURE__ */ i(S, {
  orientation: e.align,
  dashed: e.dashed,
  $style: e.style,
  children: e.title
})).setPropertyViewFn((e) => /* @__PURE__ */ a(d, {
  children: [/* @__PURE__ */ i(r, {
    name: o.basic,
    children: e.title.propertyView({
      label: t("divider.title")
    })
  }), ["logic", "both"].includes(s(l).editorModeStatus) && /* @__PURE__ */ i(r, {
    name: o.interaction,
    children: p(e)
  }), ["layout", "both"].includes(s(l).editorModeStatus) && /* @__PURE__ */ a(d, {
    children: [/* @__PURE__ */ i(r, {
      name: o.layout,
      children: !w.isEmpty(e.title.getView()) && e.align.propertyView({
        label: t("divider.align"),
        radioButton: !0
      })
    }), /* @__PURE__ */ a(r, {
      name: o.style,
      children: [e.dashed.propertyView({
        label: t("divider.dashed")
      }), e.style.getPropertyView()]
    })]
  })]
})).setExposeStateConfigs([new n("dashed", t("divider.dashedDesc")), new n("title", t("divider.titleDesc")), new n("align", t("divider.alignDesc")), v]).build(), D);
export {
  j as DividerComp
};
