import { a3 as m, d1 as d, a5 as s, d2 as u, aG as h, U as $, H as a, ad as l, I as c, ae as r, af as i, a4 as n, am as g, ag as y, ah as C, aj as S, ai as f, aC as w, aD as x, aE as v, d3 as P } from "./56c67d3b.js";
import { useContext as p } from "react";
import "react-dom";
const b = (t) => w`
    width: ${x(t.margin)};	
    height: ${v(t.margin)};	
    margin: ${t.margin};	
    padding: ${t.padding};
    border-radius:${t.radius};
    .ant-progress-text {
      color: ${t.text} !important;
      font-family:${t.fontFamily};
      font-style:${t.fontStyle};
      font-size:${t.textSize} !important;
      font-weight:${t.textWeight};
    }
    .ant-progress-circle-trail {
      stroke: ${t.track};
    }
    .ant-progress-inner .ant-progress-circle-path {
      stroke: ${t.fill} !important;
    }
    &.ant-progress-status-success {
      .ant-progress-inner .ant-progress-circle-path {
        stroke: ${t.success} !important;
      }
      .ant-progress-text {
        color: ${t.success} !important;
      }
    }
  `, V = m(P)`
  ${(t) => t.$animationStyle}
  width: 100%;
  height: 100%;
  padding: 2px;
  .ant-progress-inner {
    width: 100% !important;
    height: 100% !important;
  }

  .ant-progress-circle {
    width: 100%;
    height: 100%;
  }
  ${(t) => t.$style && b(t.$style)}
`;
let o = function() {
  const t = {
    value: d("value", 60),
    // borderRadius property hidden as it's not valid for progress circle
    style: s(u, "style"),
    animationStyle: s(h, "animationStyle")
  };
  return new $(t, (e) => /* @__PURE__ */ a(V, {
    $style: e.style,
    $animationStyle: e.animationStyle,
    percent: Math.round(e.value.value),
    type: "circle"
  })).setPropertyViewFn((e) => /* @__PURE__ */ l(c, {
    children: [/* @__PURE__ */ a(r, {
      name: i.basic,
      children: e.value.propertyView({
        label: n("progress.value"),
        tooltip: n("progress.valueTooltip")
      })
    }), ["logic", "both"].includes(p(g).editorModeStatus) && /* @__PURE__ */ a(r, {
      name: i.interaction,
      children: y(e)
    }), ["layout", "both"].includes(p(g).editorModeStatus) && /* @__PURE__ */ l(c, {
      children: [/* @__PURE__ */ a(r, {
        name: i.style,
        children: e.style.getPropertyView()
      }), /* @__PURE__ */ a(r, {
        name: i.animationStyle,
        hasTooltip: !0,
        children: e.animationStyle.getPropertyView()
      })]
    })]
  })).build();
}();
o = class extends o {
  autoHeight() {
    return !1;
  }
};
const j = C(o, [new S("value", n("progress.valueDesc")), f]);
export {
  j as ProgressCircleComp,
  V as StyledProgressCircle
};
