import { defineComponent, useCssVars, unref, toRefs, openBlock, createElementBlock, createElementVNode, Fragment, renderList, createStaticVNode, pushScopeId, popScopeId } from "vue";
import "./index.vue_vue_type_style_index_0_scoped_true_lang.mjs";
import _export_sfc from "../../../../_virtual/plugin-vue_export-helper.mjs";
const _withScopeId = (n) => (pushScopeId("data-v-da440d46"), n = n(), popScopeId(), n);
const _hoisted_1 = {
  xmlns: "http://www.w3.org/2000/svg",
  viewBox: `0 0 200 200`
};
const _hoisted_2 = /* @__PURE__ */ createStaticVNode('<filter id="innerShadow" x="-20%" y="-20%" width="140%" height="140%" data-v-da440d46><feGaussianBlur in="SourceGraphic" stdDeviation="3" result="blur" data-v-da440d46></feGaussianBlur><feOffset in="blur" dx="2.5" dy="2.5" data-v-da440d46></feOffset></filter><g data-v-da440d46><circle id="shadow" style="fill:rgba(0, 0, 0, 0.1);" cx="100" cy="100" r="87" filter="url(#innerShadow)" data-v-da440d46></circle><circle id="circle" class="clock-border" cx="100" cy="100" r="80" data-v-da440d46></circle></g>', 2);
const _hoisted_4 = {
  x1: "100",
  y1: "100",
  x2: "100",
  y2: "55",
  style: { "stroke-width": "3px" },
  class: "clock-line"
};
const _hoisted_5 = ["from", "to"];
const _hoisted_6 = {
  x1: "100",
  y1: "100",
  x2: "100",
  y2: "40",
  style: { "stroke-width": "4px" },
  class: "clock-line"
};
const _hoisted_7 = ["from", "to"];
const _hoisted_8 = {
  x1: "100",
  y1: "100",
  x2: "100",
  y2: "30",
  style: { "stroke-width": "2px" },
  class: "clock-line"
};
const _hoisted_9 = ["from", "to"];
const _hoisted_10 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("circle", {
  id: "center",
  style: { "fill": "#128a86", "stroke": "#c1efed", "stroke-width": "2px" },
  cx: "100",
  cy: "100",
  r: "3"
}, null, -1));
const _hoisted_11 = ["transform"];
const __default__ = defineComponent({ name: "EClock" });
const _sfc_main = /* @__PURE__ */ defineComponent({
  ...__default__,
  props: {
    chartConfig: {
      type: Object,
      required: true
    }
  },
  setup(__props) {
    const props = __props;
    useCssVars((_ctx) => ({
      "326d040e": unref(borderColor),
      "30f7df2e": unref(border) + "px",
      "851e31d6": unref(bgColor),
      "64285bcc": unref(color)
    }));
    let { border, color, bgColor, borderColor } = toRefs(props.chartConfig.option);
    const date = new Date();
    const hoursAngle = 360 * date.getHours() / 12 + date.getMinutes() / 2;
    const minuteAngle = 360 * date.getMinutes() / 60;
    const secAngle = 360 * date.getSeconds() / 60;
    return (_ctx, _cache) => {
      return openBlock(), createElementBlock("svg", _hoisted_1, [
        _hoisted_2,
        createElementVNode("g", null, [
          createElementVNode("line", _hoisted_4, [
            createElementVNode("animateTransform", {
              attributeName: "transform",
              attributeType: "XML",
              type: "rotate",
              dur: "43200s",
              repeatCount: "indefinite",
              from: `${hoursAngle} 100 100`,
              to: `${hoursAngle + 360} 100 100`
            }, null, 8, _hoisted_5)
          ]),
          createElementVNode("line", _hoisted_6, [
            createElementVNode("animateTransform", {
              attributeName: "transform",
              attributeType: "XML",
              type: "rotate",
              dur: "3600s",
              repeatCount: "indefinite",
              from: `${minuteAngle} 100 100`,
              to: `${minuteAngle + 360} 100 100`
            }, null, 8, _hoisted_7)
          ]),
          createElementVNode("line", _hoisted_8, [
            createElementVNode("animateTransform", {
              attributeName: "transform",
              attributeType: "XML",
              type: "rotate",
              dur: "60s",
              repeatCount: "indefinite",
              from: `${secAngle} 100 100`,
              to: `${secAngle + 360} 100 100`
            }, null, 8, _hoisted_9)
          ])
        ]),
        _hoisted_10,
        (openBlock(), createElementBlock(Fragment, null, renderList(12, (num) => {
          return createElementVNode("line", {
            x1: "100",
            y1: "30",
            x2: "100",
            y2: "40",
            class: "clock-line",
            transform: `rotate(${(num + 1) * 360 / 12} 100 100)`,
            key: `line_${num + 1}`
          }, null, 8, _hoisted_11);
        }), 64))
      ]);
    };
  }
});
var _EClock = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-da440d46"]]);
export { _EClock as default };
