import "../../../../../../node_modules/.pnpm/vue@3.3.4/node_modules/vue/dist/vue.runtime.esm-bundler.mjs";
import { defineComponent, openBlock, createElementBlock, createElementVNode as createBaseVNode } from "../../../../../../node_modules/.pnpm/@vue_runtime-core@3.3.4/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.mjs";
import { toRefs, unref } from "../../../../../../node_modules/.pnpm/@vue_reactivity@3.3.4/node_modules/@vue/reactivity/dist/reactivity.esm-bundler.mjs";
const _hoisted_1 = { class: "go-border-04" };
const _hoisted_2 = ["width", "height"];
const _hoisted_3 = ["stroke", "points"];
const _hoisted_4 = ["stroke", "points"];
const _hoisted_5 = ["stroke", "points"];
const _sfc_main = /* @__PURE__ */ defineComponent({
  __name: "index",
  props: {
    chartConfig: {
      type: Object,
      required: true
    }
  },
  setup(__props) {
    const props = __props;
    const { w, h } = toRefs(props.chartConfig.attr);
    const { colors, reverse } = toRefs(props.chartConfig.option);
    const xPos = (pos) => {
      if (!reverse.value)
        return pos;
      return w.value - pos;
    };
    return (_ctx, _cache) => {
      return openBlock(), createElementBlock("div", _hoisted_1, [
        (openBlock(), createElementBlock("svg", {
          width: unref(w),
          height: unref(h)
        }, [
          createBaseVNode("polyline", {
            stroke: unref(colors)[0],
            "stroke-width": "2",
            fill: "transparent",
            points: `${xPos(0)}, 0 ${xPos(30)}, ${unref(h) / 2}`
          }, null, 8, _hoisted_3),
          createBaseVNode("polyline", {
            stroke: unref(colors)[0],
            "stroke-width": "2",
            fill: "transparent",
            points: `${xPos(20)}, 0 ${xPos(50)}, ${unref(h) / 2} ${xPos(unref(w))}, ${unref(h) / 2}`
          }, null, 8, _hoisted_4),
          createBaseVNode("polyline", {
            stroke: unref(colors)[1],
            fill: "transparent",
            "stroke-width": "3",
            points: `${xPos(0)}, ${unref(h) - 3}, ${xPos(200)}, ${unref(h) - 3}`
          }, null, 8, _hoisted_5)
        ], 8, _hoisted_2))
      ]);
    };
  }
});
export {
  _sfc_main as default
};
