import { j as o } from "../../../../../../../_virtual/jsx-runtime.js";
import a from "./enum.js";
import { FieldTitle as m } from "../field-factory.js";
import { ColorElementPreviewPill as c } from "./color.js";
function p(t) {
  const { currentValue: e, onChange: l, schema: n, title: s, description: d } = t, i = (r) => l({ ...e, ...r });
  return /* @__PURE__ */ o.jsxs("div", { className: "flex justify-between flex-1 gap-1 flex-wrap", children: [
    /* @__PURE__ */ o.jsx(m, { title: s, description: d }),
    /* @__PURE__ */ o.jsxs("div", { className: "flex-1 gap-3 flex items-center justify-end", children: [
      e?.width && e.width !== "border-0" && /* @__PURE__ */ o.jsx(
        c,
        {
          elementColorType: "border",
          onChange: (r) => {
            i({ color: r || void 0 });
          },
          color: e?.color,
          hideColorLabel: !0
        }
      ),
      /* @__PURE__ */ o.jsx(
        a,
        {
          ...t,
          title: void 0,
          schema: n.properties.width,
          currentValue: e?.width,
          onChange: (r) => i({ width: r }),
          noFieldGrow: !0
        }
      )
    ] })
  ] });
}
export {
  p as default
};
//# sourceMappingURL=border.js.map
