import "../../../../../../node_modules/.pnpm/vue@3.3.4/node_modules/vue/dist/vue.runtime.esm-bundler.mjs";
import { defineComponent, openBlock, createElementBlock, createElementVNode as createBaseVNode, Fragment, renderList } 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";
import { normalizeClass, normalizeStyle } from "../../../../../../node_modules/.pnpm/@vue_shared@3.3.4/node_modules/@vue/shared/dist/shared.esm-bundler.mjs";
const _hoisted_1 = ["width", "height"];
const _hoisted_2 = ["fill", "points"];
const _hoisted_3 = ["width", "height"];
const _hoisted_4 = ["fill"];
const _sfc_main = /* @__PURE__ */ defineComponent({
  __name: "index",
  props: {
    chartConfig: {
      type: Object,
      required: true
    }
  },
  setup(__props) {
    const props = __props;
    const border = ["left-top", "right-top", "left-bottom", "right-bottom"];
    const { w, h } = toRefs(props.chartConfig.attr);
    const { colors, backgroundColor } = toRefs(props.chartConfig.option);
    return (_ctx, _cache) => {
      return openBlock(), createElementBlock("div", {
        class: "go-border-box",
        style: normalizeStyle(`box-shadow: inset 0 0 25px 3px ${unref(colors)[0]}`)
      }, [
        (openBlock(), createElementBlock("svg", {
          width: unref(w),
          height: unref(h)
        }, [
          createBaseVNode("polygon", {
            fill: unref(backgroundColor),
            points: `
        4, 0 ${unref(w) - 4}, 0 ${unref(w)}, 4 ${unref(w)}, ${unref(h) - 4} ${unref(w) - 4}, ${unref(h)}
        4, ${unref(h)} 0, ${unref(h) - 4} 0, 4
      `
          }, null, 8, _hoisted_2)
        ], 8, _hoisted_1)),
        (openBlock(), createElementBlock(Fragment, null, renderList(border, (item) => {
          return createBaseVNode("svg", {
            width: unref(w),
            height: unref(h),
            key: item,
            class: normalizeClass(`border-item ${item}`)
          }, [
            createBaseVNode("polygon", {
              fill: unref(colors)[1],
              points: "40, 0 5, 0 0, 5 0, 16 3, 19 3, 7 7, 3 35, 3"
            }, null, 8, _hoisted_4)
          ], 10, _hoisted_3);
        }), 64))
      ], 4);
    };
  }
});
export {
  _sfc_main as default
};
