import { computed as T, ref as S, watch as We, onMounted as Ge, openBlock as n, createElementBlock as i, normalizeClass as Ce, normalizeStyle as I, createBlock as V, createCommentVNode as y, unref as c, createSlots as Ve, withCtx as D, renderSlot as j, normalizeProps as Z, guardReactiveProps as q, createVNode as Ue, createElementVNode as u, Fragment as _, renderList as m, toDisplayString as P, createTextVNode as Ee, nextTick as He, pushScopeId as Ze, popScopeId as qe } from "vue";
import { u as Xe, c as Fe, t as Re, a as Ye, p as Q, b as Je, d as Ke, o as Qe, e as ee, g as ie, l as U, m as Me, f as z, X as et, s as g, h as te, i as le, j as Pe, k as O, n as oe, q as tt, r as lt } from "./index-Cm2_6s9o.js";
import { _ as ot } from "./Title-Coit3NcT.js";
import { u as st, U as at } from "./usePrinter-Cx8U1e30.js";
import nt from "./vue-ui-skeleton-BUS6A44x.js";
import { D as rt } from "./DataTable-NGi-FgLM.js";
import ut from "./vue-ui-accordion-CxrNF8BI.js";
import { u as Se } from "./useNestedProp-BYPZJNhi.js";
import { _ as it } from "./PackageVersion-CTMY4zeY.js";
import { P as dt } from "./PenAndPaper-DJ_d10S-.js";
import { _ as ct } from "./_plugin-vue_export-helper-CHgC5LLL.js";
const se = (E) => (Ze("data-v-558e9734"), E = E(), qe(), E), ht = ["id"], vt = {
  key: 1,
  style: "width:100%;background:transparent"
}, ft = ["xmlns", "viewBox"], pt = ["id"], yt = ["stop-color"], kt = ["stop-color"], gt = ["id"], $t = ["stop-color"], _t = ["stop-color"], mt = ["id"], xt = ["stop-color"], bt = ["stop-color"], wt = ["id"], Ct = ["stop-color"], Ft = ["stop-color"], Mt = ["stop-color"], Pt = { key: 0 }, St = ["id"], jt = ["stop-color"], Tt = ["stop-color"], zt = ["id"], Dt = ["stop-color"], Nt = ["stop-color"], Bt = ["id"], It = ["stop-color"], Ot = ["stop-color"], At = ["id"], Lt = /* @__PURE__ */ se(() => /* @__PURE__ */ u("stop", {
  offset: "0%",
  "stop-color": "#FFFFFF"
}, null, -1)), Wt = /* @__PURE__ */ se(() => /* @__PURE__ */ u("stop", {
  offset: "100%",
  "stop-color": "#FFFFFF33"
}, null, -1)), Gt = [
  Lt,
  Wt
], Vt = ["x", "y", "font-size", "font-weight", "fill"], Ut = ["x", "y"], Et = ["d", "stroke"], Ht = ["d", "stroke"], Zt = { key: 3 }, qt = { key: 0 }, Xt = ["stroke-dasharray", "d", "stroke", "stroke-width"], Rt = ["stroke-dasharray", "d", "stroke", "stroke-width"], Yt = ["stroke-dasharray", "d", "stroke", "stroke-width"], Jt = ["stroke-dasharray", "d", "stroke", "stroke-width"], Kt = { key: 1 }, Qt = ["d", "stroke", "stroke-width", "fill"], el = ["d", "stroke", "stroke-width", "fill"], tl = ["d", "stroke", "stroke-width", "fill"], ll = { key: 2 }, ol = ["d", "fill", "onMouseenter", "onClick"], sl = ["d", "fill", "onMouseenter", "onClick"], al = ["d", "fill", "onMouseenter", "onClick"], nl = ["d", "onMouseenter", "onClick"], rl = ["d"], ul = ["d", "stroke"], il = ["onClick"], dl = ["stroke", "d"], cl = ["cx", "cy", "fill", "stroke"], hl = ["x", "y", "width", "height"], vl = { key: 1 }, fl = ["d", "stroke"], pl = ["d", "fill", "stroke"], yl = ["id"], kl = ["stop-color"], gl = /* @__PURE__ */ se(() => /* @__PURE__ */ u("stop", {
  offset: "77%",
  "stop-color": "#FFFFFF20"
}, null, -1)), $l = ["stop-color"], _l = ["cx", "cy", "fill"], ml = ["cx", "cy", "fill"], xl = { key: 0 }, bl = ["text-anchor", "x", "y", "fill", "font-size"], wl = ["text-anchor", "x", "y", "fill", "font-size"], Cl = { key: 2 }, Fl = ["d", "fill", "stroke"], Ml = { key: 4 }, Pl = { key: 0 }, Sl = ["stroke-dasharray", "d", "stroke", "stroke-width"], jl = ["stroke-dasharray", "d", "stroke", "stroke-width"], Tl = ["stroke-dasharray", "d", "stroke", "stroke-width"], zl = ["stroke-dasharray", "d", "stroke", "stroke-width"], Dl = ["d", "stroke", "stroke-width", "fill"], Nl = ["d", "stroke", "stroke-width", "fill"], Bl = { key: 1 }, Il = ["onClick"], Ol = ["id"], Al = ["stop-color"], Ll = ["stop-color"], Wl = ["id"], Gl = ["stop-color"], Vl = ["stop-color"], Ul = ["stop-color"], El = ["stop-color"], Hl = ["stop-color"], Zl = ["onMouseenter", "onClick", "d", "fill"], ql = ["onMouseenter", "onClick", "d"], Xl = ["onMouseenter", "onClick", "d", "fill"], Rl = ["onClick"], Yl = ["stroke", "d"], Jl = ["cx", "cy", "fill", "stroke"], Kl = ["x", "y", "width", "height"], Ql = { key: 1 }, eo = ["d", "stroke"], to = ["d", "fill", "stroke"], lo = ["id"], oo = ["stop-color"], so = /* @__PURE__ */ se(() => /* @__PURE__ */ u("stop", {
  offset: "77%",
  "stop-color": "#FFFFFF20"
}, null, -1)), ao = ["stop-color"], no = ["cx", "cy", "fill"], ro = ["cx", "cy", "fill"], uo = { key: 0 }, io = ["text-anchor", "x", "y", "fill", "font-size"], co = ["text-anchor", "x", "y", "fill", "font-size"], ho = { key: 2 }, vo = ["d", "fill", "stroke"], fo = {
  key: 4,
  class: "vue-data-ui-watermark"
}, po = {
  key: 6,
  ref: "source",
  dir: "auto"
}, yo = ["innerHTML"], ko = {
  __name: "vue-ui-3d-bar",
  props: {
    config: {
      type: Object,
      default() {
        return {};
      }
    },
    dataset: {
      type: Object,
      default() {
        return {};
      }
    }
  },
  emits: ["selectDatapoint"],
  setup(E, { expose: je, emit: X }) {
    const $ = E, { vue_ui_3d_bar: Te } = Xe(), R = T(() => !!$.dataset && Object.keys($.dataset).length), x = S(Fe()), ze = S(null), ae = S(null), A = S(!1), de = S(0), ce = S(0), t = T({
      get: () => he(),
      set: (a) => a
    });
    function he() {
      const a = Se({
        userConfig: $.config,
        defaultConfig: Te
      });
      return a.theme ? {
        ...Se({
          userConfig: Re.vue_ui_3d_bar[a.theme] || $.config,
          defaultConfig: a
        }),
        customPalette: Ye[a.theme] || Q
      } : a;
    }
    We(() => $.config, (a) => {
      t.value = he(), ke(), de.value += 1, ce.value += 1;
    }, { deep: !0 });
    const { isPrinting: ve, isImaging: fe, generatePdf: pe, generateImage: ye } = st({
      elementId: `3d_bar_${x.value}`,
      fileName: t.value.style.chart.title.text || "vue-ui-3d-bar"
    }), De = T(() => Je(t.value.customPalette)), Y = S({
      showTable: t.value.table.show
    }), F = T(() => $.dataset.series && $.dataset.series.length), o = T(() => ({
      height: t.value.style.chart.box.dimensions.height,
      width: t.value.style.chart.box.dimensions.width,
      absoluteWidth: t.value.style.chart.box.dimensions.width * (F.value ? 2 : 1),
      top: t.value.style.chart.box.dimensions.top,
      bottom: t.value.style.chart.box.dimensions.bottom,
      left: t.value.style.chart.box.dimensions.left,
      right: t.value.style.chart.box.dimensions.right,
      perspective: t.value.style.chart.box.dimensions.perspective
    })), C = T(() => {
      if (F.value) {
        const a = $.dataset.series.map((l) => l.value || 0).reduce((l, r) => l + r, 0), s = $.dataset.series.map((l, r) => ({
          ...l,
          id: Fe(),
          proportion: (l.value || 0) / a,
          color: Ke(l.color) || De.value[r] || Q[r] || Q[r % Q.length],
          breakdown: l.breakdown ? l.breakdown.sort((d, k) => k.value - d.value) : null
        })).sort((l, r) => r.value - l.value), e = [];
        let h = 0;
        for (let l = 0; l < s.length; l += 1)
          e.push({
            ...s[l],
            fill: Ne(h, s[l].proportion, s[l].breakdown, s[l].color)
          }), h += s[l].proportion;
        return e;
      }
      return null;
    }), N = T(() => ({
      right: `M${o.value.width / 2},${o.value.top} ${o.value.width - o.value.right}, ${o.value.top + o.value.perspective} ${o.value.width - o.value.right},${o.value.height - o.value.bottom - o.value.perspective} ${o.value.width / 2},${o.value.height - o.value.bottom}`,
      left: `M${o.value.width / 2},${o.value.top} ${o.value.left},${o.value.top + o.value.perspective} ${o.value.left},${o.value.height - o.value.bottom - o.value.perspective} ${o.value.width / 2},${o.value.height - o.value.bottom}`,
      side: `M${o.value.width / 2},${o.value.height - o.value.bottom} ${o.value.width / 2},${o.value.top + o.value.perspective * 2}`,
      topSides: `M${o.value.left},${o.value.top + o.value.perspective} ${o.value.width / 2},${o.value.top + o.value.perspective * 2} ${o.value.width - o.value.right},${o.value.top + o.value.perspective}`,
      tubeTop: `M${o.value.left},${o.value.top + o.value.perspective} C ${o.value.left},${o.value.top - o.value.perspective / 3} ${o.value.width - o.value.right},${o.value.top - o.value.perspective / 3} ${o.value.width - o.value.right},${o.value.top + o.value.perspective} C ${o.value.width - o.value.right},${o.value.top + o.value.perspective * 2.3} ${o.value.left},${o.value.top + o.value.perspective * 2.3} ${o.value.left},${o.value.top + o.value.perspective}`,
      tubeLeft: `M${o.value.left},${o.value.top + o.value.perspective} ${o.value.left},${o.value.height - o.value.bottom - o.value.perspective}`,
      tubeRight: `M${o.value.width - o.value.right},${o.value.top + o.value.perspective} ${o.value.width - o.value.right},${o.value.height - o.value.bottom - o.value.perspective}`,
      tubeBottom: `M${o.value.width - o.value.right},${o.value.height - o.value.bottom - o.value.perspective} C ${o.value.width - o.value.right},${o.value.height} ${o.value.left},${o.value.height} ${o.value.left},${o.value.height - o.value.bottom - o.value.perspective}`
    })), W = S(t.value.style.chart.animation.use ? 0 : $.dataset.percentage);
    Ge(() => {
      ke();
      let a = 0, s = t.value.style.chart.animation.speed, e = 5e-3 * t.value.style.chart.animation.acceleration;
      function h() {
        W.value += s + a, a += e, W.value < $.dataset.percentage ? requestAnimationFrame(h) : W.value = $.dataset.percentage;
      }
      t.value.style.chart.animation.use && (W.value = 0, h());
    });
    function ke() {
      Qe($.dataset) ? ee({
        componentName: "VueUi3dBar",
        type: "dataset"
      }) : $.dataset.series ? $.dataset.series.forEach((a, s) => {
        ie({
          datasetObject: a,
          requiredAttributes: ["name", "value"]
        }).forEach((e) => {
          ee({
            componentName: "VueUi3dBar",
            type: "datasetSerieAttribute",
            property: e,
            index: s
          });
        }), a.breakdown && a.breakdown.forEach((e, h) => {
          ie({
            datasetObject: e,
            requiredAttributes: ["name", "value"]
          }).forEach((l) => {
            ee({
              componentName: "VueUi3dBar",
              type: "datasetSerieAttribute",
              property: l,
              index: `${s} - ${h}`
            });
          });
        });
      }) : ie({
        datasetObject: $.dataset,
        requiredAttributes: ["percentage"]
      }).forEach((a) => {
        ee({
          componentName: "VueUi3dBar",
          type: "datasetAttribute",
          property: a
        });
      });
    }
    function Ne(a, s, e, h) {
      const l = o.value.height - o.value.bottom - o.value.top - o.value.perspective * 2, { width: r, height: d, bottom: k, right: w, left: f, perspective: p } = o.value, v = k + l * a, ue = d - v - p - l * s / 2, Oe = ue > o.value.height / 2 ? "top" : "bottom", me = 64, Ae = !!e;
      let xe = null, be = null;
      return Ae && (e = e.map((we, Le) => ({
        ...we,
        value: we.value || 0,
        color: U(h, Le / e.length)
      })), xe = Me(
        { series: e },
        r + o.value.absoluteWidth / 4 - 14,
        Oe === "top" ? ue - me : ue + me,
        28,
        28,
        1.99999,
        2,
        1,
        360,
        105.25,
        14
      ), be = Me(
        { series: e },
        r - w + 20,
        d - v - p - l * s / 2,
        6,
        6,
        1.99999,
        2,
        1,
        360,
        105.25,
        6
      )), {
        donut: xe,
        miniDonut: be,
        sidePointer: {
          x: r - w,
          y: d - v - p - l * s / 2,
          topY: d - v - p - l * s,
          height: l * s
        },
        apexBottom: { y: d - v, x: r / 2 },
        apexTop: { y: d - v - l * s, x: r / 2 },
        right: `M${r / 2},${d - v} ${r / 2},${d - v - l * s} ${r - w},${d - v - p - l * s} ${r - w},${d - v - p}Z`,
        left: `M${r / 2},${d - v} ${r / 2},${d - v - l * s} ${f}, ${d - v - p - l * s} ${f},${d - v - p}Z`,
        liningTop: `M${f},${d - v - p - l * s} ${r / 2},${d - v - l * s} ${r - w},${d - v - p - l * s}`,
        liningTopShade: `M${f},${d - v - p - l * s - 0.5} ${r / 2},${d - v - l * s - 0.5} ${r - w},${d - v - p - l * s - 0.5}`,
        top: `M${r / 2},${d - v - l * s} ${f},${d - v - p - l * s} ${r / 2},${d - v - p * 2 - l * s} ${r - w},${d - v - p - l * s} Z`,
        tubeTop: `M${f},${d - v - l * s - p} C ${f},${d - v - l * s - p * 2.5} ${r - w},${d - v - l * s - p * 2.5} ${r - w},${d - v - l * s - p} C ${r - w},${d - v - l * s + p / 2} ${f},${d - v - l * s + p / 2} ${f},${d - v - l * s - p}`,
        bottomTubeTop: `M ${r - w - 0.5},${d - v - p} C ${r - w - 0.5},${d - v + p / 2} ${f},${d - v + p / 2} ${f + 0.5},${d - v - p}`,
        tubeBody: `M
        ${f},${d - v - l * s - p} 
        C ${f},${d - v - l * s + p / 2} 
        ${r - w},${d - v - l * s + p / 2} 
        ${r - w},${d - v - l * s - p} 
        L${r - w},${d - v - p}
        C 
        ${r - w},${d - v + p / 2}
        ${f},${d - v + p / 2}
        ${f},${d - v - p}Z`
      };
    }
    const H = T(() => {
      const a = W.value / 100, s = o.value.height - o.value.bottom - o.value.top - o.value.perspective * 2, { width: e, height: h, bottom: l, right: r, left: d, perspective: k } = o.value, f = l + s * 0;
      return {
        right: `M${e / 2},${h - f} ${e / 2},${h - f - s * a} ${e - r},${h - f - k - s * a} ${e - r},${h - f - k}Z`,
        left: `M${e / 2},${h - f} ${e / 2},${h - f - s * a} ${d}, ${h - f - k - s * a} ${d},${h - f - k}Z`,
        top: `M${e / 2},${h - f - s * a} ${d},${h - f - k - s * a} ${e / 2},${h - f - k * 2 - s * a} ${e - r},${h - f - k - s * a} Z`,
        tubeTop: `M${d},${h - f - s * a - k} C ${d},${h - f - s * a - k * 2.5} ${e - r},${h - f - s * a - k * 2.5} ${e - r},${h - f - s * a - k} C ${e - r},${h - f - s * a + k / 2} ${d},${h - f - s * a + k / 2} ${d},${h - f - s * a - k}`,
        tubeBody: `M
        ${d},${h - f - s * a - k} 
        C ${d},${h - f - s * a + k / 2} 
        ${e - r},${h - f - s * a + k / 2} 
        ${e - r},${h - f - s * a - k} 
        L${e - r},${h - k * 1.5}
        C 
        ${e - r},${h}
        ${d},${h}
        ${d},${h - f - k}Z`
      };
    }), b = S(null);
    function M(a, s = !1) {
      X("selectDatapoint", a), s || (b.value = a.id), s && A.value && (A.value = !1), s && !A.value && (A.value = !0);
    }
    function L() {
      A.value || (b.value = null);
    }
    function G(a, s, e = !1) {
      const h = $.dataset.series.map((d) => d.value || 0).reduce((d, k) => d + k, 0), l = isNaN(a.value / h) ? 0 : a.value / h * 100, r = isNaN(a.value / ge(s)) ? 0 : a.value / ge(s) * 100;
      return e ? r : l.toFixed(0) + "%";
    }
    function ge(a) {
      return [...a].map((s) => s.value).reduce((s, e) => s + e, 0);
    }
    const ne = S(!1);
    function Be(a) {
      ne.value = a;
    }
    function Ie() {
      return F.value ? C.value : $.dataset.percentage;
    }
    const B = T(() => {
      if (F.value) {
        const a = C.value.flatMap((e) => e.breakdown && e.breakdown.length ? [{ name: e.name, color: e.color }, ...e.breakdown.map((h, l) => ({
          name: h.name,
          color: U(e.color, l / e.breakdown.length)
        }))] : {
          name: e.name,
          color: e.color
        }), s = C.value.flatMap((e) => e.breakdown && e.breakdown.length ? [e.value, ...e.breakdown.map((h) => h.value)] : e.value);
        return { head: a, body: s };
      } else
        return null;
    });
    function $e() {
      if (!F.value) {
        console.warn("VueUi3dBar : CSV download is only available in stack mode (providing dataset.series instead of dataset.percentage)");
        return;
      }
      He(() => {
        const a = C.value.map((l) => l.value).reduce((l, r) => l + r, 0), s = B.value.head.map((l, r) => [[
          l.name
        ], [B.value.body[r]], [isNaN(B.value.body[r] / a) ? "-" : B.value.body[r] / a * 100]]), e = [[t.value.style.chart.title.text], [t.value.style.chart.title.subtitle.text], [[""], ["val"], ["%"]]].concat(s), h = tt(e);
        lt({ csvContent: h, title: t.value.style.chart.title.text || "vue-ui-3d-bar" });
      });
    }
    const J = T(() => {
      const a = C.value.map((r) => r.value).reduce((r, d) => r + d, 0), s = [
        ' <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M18 16v2a1 1 0 0 1 -1 1h-11l6 -7l-6 -7h11a1 1 0 0 1 1 1v2" /></svg>',
        z({ p: t.value.style.chart.legend.prefix, v: a, s: t.value.style.chart.legend.suffix, r: t.value.table.td.roundingValue }),
        "100%"
      ], e = B.value.head.map((r, d) => {
        const k = z({ p: t.value.style.chart.legend.prefix, v: B.value.body[d], s: t.value.style.chart.legend.suffix, r: t.value.table.td.roundingValue });
        return [
          {
            color: r.color,
            name: r.name
          },
          k,
          isNaN(B.value.body[d] / a) ? "-" : z({
            v: B.value.body[d] / a * 100,
            s: "%",
            r: t.value.table.td.roundingPercentage
          })
        ];
      }), h = {
        th: {
          backgroundColor: t.value.table.th.backgroundColor,
          color: t.value.table.th.color,
          outline: t.value.table.th.outline
        },
        td: {
          backgroundColor: t.value.table.td.backgroundColor,
          color: t.value.table.td.color,
          outline: t.value.table.td.outline
        },
        breakpoint: t.value.table.responsiveBreakpoint,
        shape: t.value.style.shape === "tube" ? "circle" : "square"
      };
      return {
        colNames: [
          t.value.table.columnNames.series,
          t.value.table.columnNames.value,
          t.value.table.columnNames.percentage
        ],
        head: s,
        body: e,
        config: h
      };
    });
    function _e() {
      Y.value.showTable = !Y.value.showTable;
    }
    const K = S(!1);
    function re() {
      K.value = !K.value;
    }
    return je({
      generateCsv: $e,
      generatePdf: pe,
      generateImage: ye,
      getData: Ie,
      toggleTable: _e,
      toggleAnnotator: re
    }), (a, s) => (n(), i("div", {
      ref_key: "bar3dChart",
      ref: ae,
      class: Ce("vue-ui-3d-bar"),
      style: I(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`),
      id: `3d_bar_${x.value}`
    }, [
      t.value.userOptions.buttons.annotator ? (n(), V(dt, {
        key: 0,
        parent: ae.value,
        backgroundColor: t.value.style.chart.backgroundColor,
        color: t.value.style.chart.color,
        active: K.value,
        onClose: re
      }, null, 8, ["parent", "backgroundColor", "color", "active"])) : y("", !0),
      t.value.style.chart.title.text ? (n(), i("div", vt, [
        (n(), V(ot, {
          key: `title_${de.value}`,
          config: {
            title: {
              cy: "3dBar-div-title",
              ...t.value.style.chart.title
            },
            subtitle: {
              cy: "3dBar-div-subtitle",
              ...t.value.style.chart.title.subtitle
            }
          }
        }, null, 8, ["config"]))
      ])) : y("", !0),
      t.value.userOptions.show && R.value ? (n(), V(at, {
        key: 2,
        ref_key: "details",
        ref: ze,
        backgroundColor: t.value.style.chart.backgroundColor,
        color: t.value.style.chart.color,
        isPrinting: c(ve),
        isImaging: c(fe),
        uid: x.value,
        hasPdf: t.value.userOptions.buttons.pdf,
        hasTable: !!F.value && t.value.userOptions.buttons.table,
        hasXls: !!F.value && t.value.userOptions.buttons.csv,
        hasImg: t.value.userOptions.buttons.img,
        hasFullscreen: t.value.userOptions.buttons.fullscreen,
        titles: { ...t.value.userOptions.buttonTitles },
        chartElement: ae.value,
        position: t.value.userOptions.position,
        hasAnnotator: t.value.userOptions.buttons.annotator,
        isAnnotation: K.value,
        onToggleFullscreen: Be,
        onGeneratePdf: c(pe),
        onGenerateCsv: $e,
        onGenerateImage: c(ye),
        onToggleTable: _e,
        onToggleAnnotator: re
      }, Ve({ _: 2 }, [
        a.$slots.optionPdf ? {
          name: "optionPdf",
          fn: D(() => [
            j(a.$slots, "optionPdf", {}, void 0, !0)
          ]),
          key: "0"
        } : void 0,
        a.$slots.optionCsv ? {
          name: "optionCsv",
          fn: D(() => [
            j(a.$slots, "optionCsv", {}, void 0, !0)
          ]),
          key: "1"
        } : void 0,
        a.$slots.optionImg ? {
          name: "optionImg",
          fn: D(() => [
            j(a.$slots, "optionImg", {}, void 0, !0)
          ]),
          key: "2"
        } : void 0,
        a.$slots.optionTable ? {
          name: "optionTable",
          fn: D(() => [
            j(a.$slots, "optionTable", {}, void 0, !0)
          ]),
          key: "3"
        } : void 0,
        a.$slots.optionFullscreen ? {
          name: "optionFullscreen",
          fn: D(({ toggleFullscreen: e, isFullscreen: h }) => [
            j(a.$slots, "optionFullscreen", Z(q({ toggleFullscreen: e, isFullscreen: h })), void 0, !0)
          ]),
          key: "4"
        } : void 0,
        a.$slots.optionAnnotator ? {
          name: "optionAnnotator",
          fn: D(({ toggleAnnotator: e, isAnnotator: h }) => [
            j(a.$slots, "optionAnnotator", Z(q({ toggleAnnotator: e, isAnnotator: h })), void 0, !0)
          ]),
          key: "5"
        } : void 0
      ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasTable", "hasXls", "hasImg", "hasFullscreen", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "onGeneratePdf", "onGenerateImage"])) : y("", !0),
      R.value ? (n(), i("svg", {
        key: 3,
        xmlns: c(et),
        class: Ce({ "vue-data-ui-fullscreen--on": ne.value, "vue-data-ui-fulscreen--off": !ne.value }),
        viewBox: `0 0 ${o.value.absoluteWidth} ${o.value.height}`,
        style: I(`max-width:100%; overflow: visible; background:transparent;color:${t.value.style.chart.color}`)
      }, [
        Ue(it),
        u("defs", null, [
          u("radialGradient", {
            id: `gradient_top${x.value}`
          }, [
            u("stop", {
              offset: "0%",
              "stop-color": c(g)(t.value.style.chart.backgroundColor, 0)
            }, null, 8, yt),
            u("stop", {
              offset: "100%",
              "stop-color": t.value.style.chart.bar.color
            }, null, 8, kt)
          ], 8, pt),
          u("radialGradient", {
            id: `gradient_left${x.value}`
          }, [
            u("stop", {
              offset: "0%",
              "stop-color": c(g)(t.value.style.chart.backgroundColor, 0)
            }, null, 8, $t),
            u("stop", {
              offset: "100%",
              "stop-color": c(g)(t.value.style.chart.bar.color, 20)
            }, null, 8, _t)
          ], 8, gt),
          u("radialGradient", {
            id: `gradient_right${x.value}`
          }, [
            u("stop", {
              offset: "0%",
              "stop-color": c(g)(t.value.style.chart.backgroundColor, 0)
            }, null, 8, xt),
            u("stop", {
              offset: "100%",
              "stop-color": c(g)(t.value.style.chart.bar.color, 20)
            }, null, 8, bt)
          ], 8, mt),
          u("linearGradient", {
            id: `gradient_tube_body${x.value}`,
            x1: "0%",
            y1: "0%",
            x2: "100%",
            y2: "0%"
          }, [
            u("stop", {
              offset: "0%",
              "stop-color": `${t.value.style.chart.bar.color}`
            }, null, 8, Ct),
            u("stop", {
              offset: "75%",
              "stop-color": c(g)(t.value.style.chart.backgroundColor, 0)
            }, null, 8, Ft),
            u("stop", {
              offset: "100%",
              "stop-color": c(g)(t.value.style.chart.bar.color, 40)
            }, null, 8, Mt)
          ], 8, wt)
        ]),
        F.value ? (n(), i("defs", Pt, [
          (n(!0), i(_, null, m(C.value, (e) => (n(), i("radialGradient", {
            id: `grad_top_${e.id}`
          }, [
            u("stop", {
              offset: "0%",
              "stop-color": c(g)(c(U)(e.color, 0.5), 80)
            }, null, 8, jt),
            u("stop", {
              offset: "100%",
              "stop-color": e.color
            }, null, 8, Tt)
          ], 8, St))), 256)),
          (n(!0), i(_, null, m(C.value, (e) => (n(), i("linearGradient", {
            id: `grad_left_${e.id}`
          }, [
            u("stop", {
              offset: "0%",
              "stop-color": c(g)(e.color, 80)
            }, null, 8, Dt),
            u("stop", {
              offset: "100%",
              "stop-color": c(g)(c(te)(e.color, 0.5), 100)
            }, null, 8, Nt)
          ], 8, zt))), 256)),
          (n(!0), i(_, null, m(C.value, (e) => (n(), i("linearGradient", {
            id: `grad_right_${e.id}`
          }, [
            u("stop", {
              offset: "2%",
              "stop-color": c(g)(c(U)(e.color, 0.5), 100)
            }, null, 8, It),
            u("stop", {
              offset: "100%",
              "stop-color": c(g)(e.color, 80)
            }, null, 8, Ot)
          ], 8, Bt))), 256)),
          u("linearGradient", {
            x1: "0%",
            y1: "0%",
            x2: "0%",
            y2: "100%",
            id: `vertical_line_${x.value}`
          }, Gt, 8, At)
        ])) : y("", !0),
        t.value.style.chart.dataLabel.show && ![null, void 0].includes($.dataset.percentage) && [null, void 0].includes($.dataset.series) ? (n(), i("text", {
          key: 1,
          x: o.value.width / 2,
          y: o.value.top - t.value.style.chart.dataLabel.fontSize / 2,
          "font-size": t.value.style.chart.dataLabel.fontSize,
          "font-weight": t.value.style.chart.dataLabel.bold ? "bold" : "normal",
          fill: t.value.style.chart.dataLabel.color,
          "text-anchor": "middle"
        }, P(c(z)({
          v: W.value,
          s: "%",
          r: t.value.style.chart.dataLabel.rounding
        })), 9, Vt)) : y("", !0),
        A.value ? (n(), i("g", {
          key: 2,
          onClick: s[0] || (s[0] = (e) => {
            A.value = !1, b.value = null;
          }),
          "data-html2canvas-ignore": "",
          style: { cursor: "pointer" }
        }, [
          u("rect", {
            x: o.value.width / 2 - 6,
            y: o.value.top - 20,
            height: 12,
            width: 12,
            fill: "transparent"
          }, null, 8, Ut),
          u("path", {
            d: `M${o.value.width / 2 - 6},${o.value.top - 20} ${o.value.width / 2 + 6},${o.value.top - 9}`,
            stroke: t.value.style.chart.color,
            "stroke-linecap": "round",
            "stroke-width": "1"
          }, null, 8, Et),
          u("path", {
            d: `M${o.value.width / 2 + 6},${o.value.top - 20} ${o.value.width / 2 - 6},${o.value.top - 9}`,
            stroke: t.value.style.chart.color,
            "stroke-linecap": "round",
            "stroke-width": "1"
          }, null, 8, Ht)
        ])) : y("", !0),
        !t.value.style.shape || t.value.style.shape === "bar" ? (n(), i("g", Zt, [
          F.value ? y("", !0) : (n(), i("g", qt, [
            u("path", {
              "stroke-dasharray": t.value.style.chart.box.strokeDasharray,
              d: N.value.right,
              stroke: t.value.style.chart.box.stroke,
              "stroke-width": t.value.style.chart.box.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: "none"
            }, null, 8, Xt),
            u("path", {
              "stroke-dasharray": t.value.style.chart.box.strokeDasharray,
              d: N.value.left,
              stroke: t.value.style.chart.box.stroke,
              "stroke-width": t.value.style.chart.box.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: "none"
            }, null, 8, Rt),
            u("path", {
              "stroke-dasharray": t.value.style.chart.box.strokeDasharray,
              d: N.value.side,
              stroke: t.value.style.chart.box.stroke,
              "stroke-width": t.value.style.chart.box.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: "none"
            }, null, 8, Yt),
            u("path", {
              "stroke-dasharray": t.value.style.chart.box.strokeDasharray,
              d: N.value.topSides,
              stroke: t.value.style.chart.box.stroke,
              "stroke-width": t.value.style.chart.box.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: "none"
            }, null, 8, Jt)
          ])),
          F.value ? y("", !0) : (n(), i("g", Kt, [
            u("path", {
              d: H.value.right,
              stroke: t.value.style.chart.bar.stroke,
              "stroke-width": t.value.style.chart.bar.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: `url(#gradient_right${x.value})`
            }, null, 8, Qt),
            u("path", {
              d: H.value.left,
              stroke: t.value.style.chart.bar.stroke,
              "stroke-width": t.value.style.chart.bar.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: `url(#gradient_left${x.value})`
            }, null, 8, el),
            u("path", {
              d: H.value.top,
              stroke: t.value.style.chart.bar.stroke,
              "stroke-width": t.value.style.chart.bar.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: `url(#gradient_top${x.value})`
            }, null, 8, tl)
          ])),
          F.value ? (n(), i("g", ll, [
            (n(!0), i(_, null, m(C.value, (e, h) => (n(), i("g", {
              style: I(`opacity:${b.value ? b.value === e.id ? 1 : 0.3 : 1}`),
              class: "vue-ui-3d-bar-stack"
            }, [
              u("path", {
                d: e.fill.right,
                fill: `url(#grad_right_${e.id})`,
                onMouseenter: (l) => M(e),
                onClick: (l) => M(e, !0),
                onMouseout: L
              }, null, 40, ol),
              u("path", {
                d: e.fill.left,
                fill: `url(#grad_left_${e.id})`,
                onMouseenter: (l) => M(e),
                onClick: (l) => M(e, !0),
                onMouseout: L
              }, null, 40, sl),
              u("path", {
                d: e.fill.top,
                fill: `url(#grad_top_${e.id})`,
                onMouseenter: (l) => M(e),
                onClick: (l) => M(e, !0),
                onMouseout: L
              }, null, 40, al),
              u("path", {
                d: e.fill.liningTop,
                stroke: "#FFFFFF",
                "stroke-width": "0.5",
                "stroke-linecap": "round",
                fill: "none",
                onMouseenter: (l) => M(e),
                onClick: (l) => M(e, !0),
                onMouseout: L
              }, null, 40, nl),
              u("path", {
                d: `M ${e.fill.apexTop.x},${e.fill.apexTop.y} ${e.fill.apexBottom.x},${e.fill.apexBottom.y}`,
                stroke: "#FFFFFF",
                "stroke-width": "0.5",
                "stroke-linecap": "round"
              }, null, 8, rl)
            ], 4))), 256)),
            (n(!0), i(_, null, m(C.value, (e, h) => (n(), i("g", null, [
              h !== C.value.length - 1 ? (n(), i("path", {
                key: 0,
                d: e.fill.liningTopShade,
                stroke: t.value.style.chart.bar.shadeColor,
                "stroke-width": "0.5",
                "stroke-linecap": "round",
                fill: "none",
                style: { "pointer-events": "none" }
              }, null, 8, ul)) : y("", !0)
            ]))), 256)),
            (n(!0), i(_, null, m(C.value, (e, h) => (n(), i("g", {
              style: I(`opacity:${b.value ? b.value === e.id ? 1 : 0 : e.proportion * 100 > t.value.style.chart.legend.hideUnderPercentage ? 1 : 0}`),
              onClick: (l) => X("selectDatapoint", e)
            }, [
              u("path", {
                stroke: t.value.style.chart.color,
                "stroke-dasharray": "1",
                "stroke-width": "0.5",
                "stroke-linecap": "round",
                d: `M${e.fill.sidePointer.x},${e.fill.sidePointer.y} ${e.fill.sidePointer.x + 20},${e.fill.sidePointer.y}`
              }, null, 8, dl),
              !e.fill.miniDonut || b.value ? (n(), i("circle", {
                key: 0,
                cx: e.fill.sidePointer.x + 20,
                cy: e.fill.sidePointer.y,
                r: 2,
                fill: e.color,
                stroke: t.value.style.chart.backgroundColor
              }, null, 8, cl)) : y("", !0),
              (n(), i("foreignObject", {
                x: e.fill.sidePointer.x + 30,
                y: e.fill.sidePointer.y - t.value.style.chart.legend.fontSize,
                width: o.value.absoluteWidth / 2 - 12,
                height: t.value.style.chart.legend.fontSize * 2,
                style: { overflow: "visible", position: "relative" }
              }, [
                t.value.style.chart.legend.showDefault ? (n(), i("div", {
                  key: 0,
                  style: I(`height: 100%; width: 100%; display: flex; flex-direction: row; flex-wrap: wrap; align-items:center;justify-content: flex-start; font-size:${t.value.style.chart.legend.fontSize}px; text-align:left; line-height: ${t.value.style.chart.legend.fontSize}px; color:${t.value.style.chart.legend.color}`)
                }, P(e.name) + ": " + P(c(z)({ v: e.proportion * 100, s: "%", r: t.value.style.chart.legend.roundingPercentage })) + " (" + P(c(le)(
                  t.value.style.chart.dataLabel.formatter,
                  e.value,
                  c(z)({
                    p: t.value.style.chart.legend.prefix,
                    v: e.value,
                    s: t.value.style.chart.legend.suffix,
                    r: t.value.style.chart.legend.roundingValue
                  }),
                  { datapoint: e, seriesIndex: h }
                )) + ") ", 5)) : y("", !0),
                j(a.$slots, "legend", Z(q({ datapoint: e, config: t.value, dataset: C.value })), void 0, !0)
              ], 8, hl)),
              e.fill.donut && b.value === e.id ? (n(), i("g", vl, [
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("g", null, [
                  G(l, e.fill.donut, !0) > 6 ? (n(), i("path", {
                    key: 0,
                    d: c(Pe)(l, { x: l.cx, y: l.cy }, 0, 8, !1, !0, 10),
                    stroke: l.color,
                    class: "vue-ui-donut-arc-path",
                    "stroke-width": "0.5",
                    "stroke-linecap": "round",
                    "stroke-linejoin": "round",
                    fill: "none"
                  }, null, 8, fl)) : y("", !0)
                ]))), 256)),
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("path", {
                  class: "vue-ui-donut-arc-path",
                  d: l.arcSlice,
                  fill: `${l.color}`,
                  stroke: t.value.style.chart.backgroundColor,
                  "stroke-width": 1
                }, null, 8, pl))), 256)),
                u("defs", null, [
                  u("radialGradient", {
                    id: `hollow_gradient_${x.value}`
                  }, [
                    u("stop", {
                      offset: "0%",
                      "stop-color": c(g)(t.value.style.chart.backgroundColor, 0)
                    }, null, 8, kl),
                    gl,
                    u("stop", {
                      offset: "100%",
                      "stop-color": c(g)(t.value.style.chart.backgroundColor, 0)
                    }, null, 8, $l)
                  ], 8, yl)
                ]),
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("circle", {
                  class: "vue-ui-donut-arc-path",
                  cx: l.cx,
                  cy: l.cy,
                  r: 28,
                  fill: `url(#hollow_gradient_${x.value})`
                }, null, 8, _l))), 256)),
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("circle", {
                  class: "vue-ui-donut-arc-path",
                  cx: l.cx,
                  cy: l.cy,
                  r: 14,
                  fill: t.value.style.chart.backgroundColor
                }, null, 8, ml))), 256)),
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("g", null, [
                  G(l, e.fill.donut, !0) > 6 ? (n(), i("g", xl, [
                    u("text", {
                      "text-anchor": c(O)(l, !0, 0).anchor,
                      x: c(O)(l, !0, 2).x,
                      y: c(oe)(l, 12, 12),
                      fill: t.value.style.chart.legend.color,
                      "font-size": t.value.style.chart.legend.fontSize / 1.5
                    }, P(G(l, e.fill.donut)) + " (" + P(c(le)(
                      t.value.style.chart.dataLabel.formatter,
                      l.value,
                      c(z)({
                        p: t.value.style.chart.legend.prefix,
                        v: l.value,
                        s: t.value.style.chart.legend.suffix,
                        r: t.value.style.chart.legend.roundingValue
                      }),
                      { datapoint: l, seriesIndex: r }
                    )) + ") ", 9, bl),
                    u("text", {
                      "text-anchor": c(O)(l).anchor,
                      x: c(O)(l, !0, 2).x,
                      y: c(oe)(l, 12, 12) + t.value.style.chart.legend.fontSize / 1.5,
                      fill: t.value.style.chart.legend.color,
                      "font-size": t.value.style.chart.legend.fontSize / 1.5
                    }, P(l.name), 9, wl)
                  ])) : y("", !0)
                ]))), 256))
              ])) : y("", !0),
              e.fill.miniDonut && !b.value ? (n(), i("g", Cl, [
                (n(!0), i(_, null, m(e.fill.miniDonut, (l, r) => (n(), i("path", {
                  class: "vue-ui-donut-arc-path",
                  d: l.arcSlice,
                  fill: `${l.color}`,
                  stroke: t.value.style.chart.backgroundColor,
                  "stroke-width": 0.5
                }, null, 8, Fl))), 256))
              ])) : y("", !0)
            ], 12, il))), 256))
          ])) : y("", !0)
        ])) : y("", !0),
        t.value.style.shape === "tube" ? (n(), i("g", Ml, [
          F.value ? y("", !0) : (n(), i("g", Pl, [
            u("path", {
              "stroke-dasharray": t.value.style.chart.box.strokeDasharray,
              d: N.value.tubeTop,
              stroke: t.value.style.chart.box.stroke,
              "stroke-width": t.value.style.chart.box.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: "none"
            }, null, 8, Sl),
            u("path", {
              "stroke-dasharray": t.value.style.chart.box.strokeDasharray,
              d: N.value.tubeLeft,
              stroke: t.value.style.chart.box.stroke,
              "stroke-width": t.value.style.chart.box.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: "none"
            }, null, 8, jl),
            u("path", {
              "stroke-dasharray": t.value.style.chart.box.strokeDasharray,
              d: N.value.tubeRight,
              stroke: t.value.style.chart.box.stroke,
              "stroke-width": t.value.style.chart.box.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: "none"
            }, null, 8, Tl),
            u("path", {
              "stroke-dasharray": t.value.style.chart.box.strokeDasharray,
              d: N.value.tubeBottom,
              stroke: t.value.style.chart.box.stroke,
              "stroke-width": t.value.style.chart.box.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: "none"
            }, null, 8, zl),
            u("path", {
              d: H.value.tubeTop,
              stroke: t.value.style.chart.bar.stroke,
              "stroke-width": t.value.style.chart.bar.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: `url(#gradient_top${x.value})`
            }, null, 8, Dl),
            u("path", {
              d: H.value.tubeBody,
              stroke: t.value.style.chart.bar.stroke,
              "stroke-width": t.value.style.chart.bar.strokeWidth,
              "stroke-linejoin": "round",
              "stroke-linecap": "round",
              fill: `url(#gradient_tube_body${x.value})`
            }, null, 8, Nl)
          ])),
          F.value ? (n(), i("g", Bl, [
            (n(!0), i(_, null, m(C.value, (e, h) => (n(), i("g", {
              style: I(`opacity:${b.value ? b.value === e.id ? 1 : 0.3 : 1}`),
              class: "vue-ui-3d-bar-stack",
              onClick: (l) => X("selectDatapoint", e)
            }, [
              u("defs", null, [
                u("radialGradient", {
                  id: `gradient_tube_top_${e.id}`,
                  fx: "10%",
                  cy: "55%"
                }, [
                  u("stop", {
                    offset: "0%",
                    "stop-color": c(g)(c(U)(e.color, 0.5), 80)
                  }, null, 8, Al),
                  u("stop", {
                    offset: "100%",
                    "stop-color": c(g)(c(te)(e.color, 0.1), 80)
                  }, null, 8, Ll)
                ], 8, Ol),
                u("linearGradient", {
                  id: `gradient_tube_body_${e.id}`,
                  x1: "0%",
                  y1: "0%",
                  x2: "100%",
                  y2: "0%"
                }, [
                  u("stop", {
                    offset: "0%",
                    "stop-color": `${e.color}`
                  }, null, 8, Gl),
                  u("stop", {
                    offset: "10%",
                    "stop-color": c(g)(c(te)(e.color, 0.7), 100)
                  }, null, 8, Vl),
                  u("stop", {
                    offset: "25%",
                    "stop-color": c(g)(c(te)(e.color, 0.5), 100)
                  }, null, 8, Ul),
                  u("stop", {
                    offset: "75%",
                    "stop-color": c(g)(e.color, 80)
                  }, null, 8, El),
                  u("stop", {
                    offset: "100%",
                    "stop-color": c(g)(c(U)(e.color, 0.7), 100)
                  }, null, 8, Hl)
                ], 8, Wl)
              ]),
              u("path", {
                onMouseenter: (l) => M(e),
                onClick: (l) => M(e, !0),
                onMouseout: L,
                d: e.fill.tubeBody,
                stroke: "#FFFFFF",
                "stroke-width": 0.5,
                "stroke-linejoin": "round",
                "stroke-linecap": "round",
                fill: `url(#gradient_tube_body_${e.id})`
              }, null, 40, Zl),
              h > 0 ? (n(), i("path", {
                key: 0,
                onMouseenter: (l) => M(e),
                onClick: (l) => M(e, !0),
                onMouseout: L,
                d: e.fill.bottomTubeTop,
                stroke: "#000000",
                "stroke-width": 0.5,
                "stroke-linejoin": "round",
                "stroke-linecap": "round",
                fill: "none"
              }, null, 40, ql)) : y("", !0),
              u("path", {
                onMouseenter: (l) => M(e),
                onClick: (l) => M(e, !0),
                onMouseout: L,
                d: e.fill.tubeTop,
                stroke: "#FFFFFF",
                "stroke-width": 0.5,
                "stroke-linejoin": "round",
                "stroke-linecap": "round",
                fill: `url(#gradient_tube_top_${e.id})`
              }, null, 40, Xl)
            ], 12, Il))), 256)),
            (n(!0), i(_, null, m(C.value, (e, h) => (n(), i("g", {
              style: I(`opacity:${b.value ? b.value === e.id ? 1 : 0 : e.proportion * 100 > t.value.style.chart.legend.hideUnderPercentage ? 1 : 0}`),
              onClick: (l) => X("selectDatapoint", e)
            }, [
              u("path", {
                stroke: t.value.style.chart.color,
                "stroke-dasharray": "1",
                "stroke-width": "0.5",
                "stroke-linecap": "round",
                d: `M${e.fill.sidePointer.x},${e.fill.sidePointer.y} ${e.fill.sidePointer.x + 20},${e.fill.sidePointer.y}`
              }, null, 8, Yl),
              !e.fill.miniDonut || b.value ? (n(), i("circle", {
                key: 0,
                cx: e.fill.sidePointer.x + 20,
                cy: e.fill.sidePointer.y,
                r: 2,
                fill: e.color,
                stroke: t.value.style.chart.backgroundColor
              }, null, 8, Jl)) : y("", !0),
              (n(), i("foreignObject", {
                x: e.fill.sidePointer.x + 30,
                y: e.fill.sidePointer.y - t.value.style.chart.legend.fontSize,
                width: o.value.absoluteWidth / 2 - 12,
                height: t.value.style.chart.legend.fontSize * 2,
                style: { overflow: "visible", position: "relative" }
              }, [
                t.value.style.chart.legend.showDefault ? (n(), i("div", {
                  key: 0,
                  style: I(`height: 100%; width: 100%; display: flex; flex-direction: row; flex-wrap: wrap; align-items:center;justify-content: flex-start; font-size:${t.value.style.chart.legend.fontSize}px; text-align:left; line-height: ${t.value.style.chart.legend.fontSize}px; color:${t.value.style.chart.legend.color}`)
                }, P(e.name) + ": " + P(c(z)({ v: e.proportion * 100, s: "%", r: t.value.style.chart.legend.roundingPercentage })) + " (" + P(c(le)(
                  t.value.style.chart.dataLabel.formatter,
                  e.value,
                  c(z)({
                    p: t.value.style.chart.legend.prefix,
                    v: e.value,
                    s: t.value.style.chart.legend.suffix,
                    r: t.value.style.chart.legend.roundingValue
                  }),
                  { datapoint: e, seriesIndex: h }
                )) + ") ", 5)) : y("", !0),
                j(a.$slots, "legend", Z(q({ datapoint: e, config: t.value, dataset: C.value })), void 0, !0)
              ], 8, Kl)),
              e.fill.donut && b.value === e.id ? (n(), i("g", Ql, [
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("g", null, [
                  G(l, e.fill.donut, !0) > 6 ? (n(), i("path", {
                    key: 0,
                    d: c(Pe)(l, { x: l.cx, y: l.cy }, 0, 8, !1, !0, 10),
                    stroke: l.color,
                    class: "vue-ui-donut-arc-path",
                    "stroke-width": "0.5",
                    "stroke-linecap": "round",
                    "stroke-linejoin": "round",
                    fill: "none"
                  }, null, 8, eo)) : y("", !0)
                ]))), 256)),
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("path", {
                  class: "vue-ui-donut-arc-path",
                  d: l.arcSlice,
                  fill: `${l.color}`,
                  stroke: t.value.style.chart.backgroundColor,
                  "stroke-width": 1
                }, null, 8, to))), 256)),
                u("defs", null, [
                  u("radialGradient", {
                    id: `hollow_gradient_${x.value}`
                  }, [
                    u("stop", {
                      offset: "0%",
                      "stop-color": c(g)(t.value.style.chart.backgroundColor, 0)
                    }, null, 8, oo),
                    so,
                    u("stop", {
                      offset: "100%",
                      "stop-color": c(g)(t.value.style.chart.backgroundColor, 0)
                    }, null, 8, ao)
                  ], 8, lo)
                ]),
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("circle", {
                  class: "vue-ui-donut-arc-path",
                  cx: l.cx,
                  cy: l.cy,
                  r: 28,
                  fill: `url(#hollow_gradient_${x.value})`
                }, null, 8, no))), 256)),
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("circle", {
                  class: "vue-ui-donut-arc-path",
                  cx: l.cx,
                  cy: l.cy,
                  r: 14,
                  fill: t.value.style.chart.backgroundColor
                }, null, 8, ro))), 256)),
                (n(!0), i(_, null, m(e.fill.donut, (l, r) => (n(), i("g", null, [
                  G(l, e.fill.donut, !0) > 6 ? (n(), i("g", uo, [
                    u("text", {
                      "text-anchor": c(O)(l, !0, 0).anchor,
                      x: c(O)(l, !0, 2).x,
                      y: c(oe)(l, 12, 12),
                      fill: t.value.style.chart.legend.color,
                      "font-size": t.value.style.chart.legend.fontSize / 1.5
                    }, P(G(l, e.fill.donut)) + " (" + P(c(le)(
                      t.value.style.chart.dataLabel.formatter,
                      l.value,
                      c(z)({
                        p: t.value.style.chart.legend.prefix,
                        v: l.value,
                        s: t.value.style.chart.legend.suffix,
                        r: t.value.style.chart.legend.roundingValue
                      }),
                      { datapoint: l, seriesIndex: r }
                    )) + ") ", 9, io),
                    u("text", {
                      "text-anchor": c(O)(l).anchor,
                      x: c(O)(l, !0, 2).x,
                      y: c(oe)(l, 12, 12) + t.value.style.chart.legend.fontSize / 1.5,
                      fill: t.value.style.chart.legend.color,
                      "font-size": t.value.style.chart.legend.fontSize / 1.5
                    }, P(l.name), 9, co)
                  ])) : y("", !0)
                ]))), 256))
              ])) : y("", !0),
              e.fill.miniDonut && !b.value ? (n(), i("g", ho, [
                (n(!0), i(_, null, m(e.fill.miniDonut, (l, r) => (n(), i("path", {
                  class: "vue-ui-donut-arc-path",
                  d: l.arcSlice,
                  fill: `${l.color}`,
                  stroke: t.value.style.chart.backgroundColor,
                  "stroke-width": 0.5
                }, null, 8, vo))), 256))
              ])) : y("", !0)
            ], 12, Rl))), 256))
          ])) : y("", !0)
        ])) : y("", !0),
        j(a.$slots, "svg", { svg: o.value }, void 0, !0)
      ], 14, ft)) : y("", !0),
      a.$slots.watermark ? (n(), i("div", fo, [
        j(a.$slots, "watermark", Z(q({ isPrinting: c(ve) || c(fe) })), void 0, !0)
      ])) : y("", !0),
      R.value ? y("", !0) : (n(), V(nt, {
        key: 5,
        config: {
          type: "bar3d",
          style: {
            backgroundColor: t.value.style.chart.backgroundColor,
            bar3d: {
              color: "#CCCCCC"
            }
          }
        }
      }, null, 8, ["config"])),
      a.$slots.source ? (n(), i("div", po, [
        j(a.$slots, "source", {}, void 0, !0)
      ], 512)) : y("", !0),
      R.value && F.value ? (n(), V(ut, {
        key: 7,
        hideDetails: "",
        config: {
          open: Y.value.showTable,
          maxHeight: 1e4,
          body: {
            backgroundColor: t.value.style.chart.backgroundColor,
            color: t.value.style.chart.color
          },
          head: {
            backgroundColor: t.value.style.chart.backgroundColor,
            color: t.value.style.chart.color
          }
        }
      }, {
        content: D(() => [
          (n(), V(rt, {
            key: `table_${ce.value}`,
            colNames: J.value.colNames,
            head: J.value.head,
            body: J.value.body,
            config: J.value.config,
            title: `${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text ? ` : ${t.value.style.chart.title.subtitle.text}` : ""}`,
            onClose: s[1] || (s[1] = (e) => Y.value.showTable = !1)
          }, {
            th: D(({ th: e }) => [
              u("div", {
                innerHTML: e,
                style: { display: "flex", "align-items": "center" }
              }, null, 8, yo)
            ]),
            td: D(({ td: e }) => [
              Ee(P(e.name || e), 1)
            ]),
            _: 1
          }, 8, ["colNames", "head", "body", "config", "title"]))
        ]),
        _: 1
      }, 8, ["config"])) : y("", !0)
    ], 12, ht));
  }
}, So = /* @__PURE__ */ ct(ko, [["__scopeId", "data-v-558e9734"]]);
export {
  So as default
};
