import { computed as h, onMounted as Le, ref as u, watch as Fe, openBlock as o, createElementBlock as n, normalizeClass as E, normalizeStyle as V, unref as i, createBlock as $, createCommentVNode as c, createSlots as Ie, withCtx as d, renderSlot as v, normalizeProps as O, guardReactiveProps as N, createVNode as ie, createElementVNode as _, Fragment as ce, renderList as ve, createTextVNode as de, toDisplayString as M, nextTick as Ae } from "vue";
import { u as Ee, o as Ve, e as he, g as Me, c as pe, t as De, a as Be, p as D, b as Ge, d as ze, J as ye, M as Ue, f as k, X as We, i as ge, x as fe, y as He, q as Xe, r as je } from "./index-MWHrTFPq.js";
import { L as Re } from "./Legend-CUhyETYn.js";
import { _ as Ye } from "./Title-C7EOYmwp.js";
import { _ as qe } from "./Tooltip-Bip4kr-u.js";
import { D as Je } from "./DataTable-DtvVWOjy.js";
import { u as Ke, U as Qe } from "./usePrinter-CEEgHfhF.js";
import Ze from "./vue-ui-skeleton-Bo8ydREb.js";
import et from "./vue-ui-accordion-BnV2tlGp.js";
import { u as be } from "./useNestedProp-CTDeT4KA.js";
import { _ as tt } from "./PackageVersion-CBKqLhAX.js";
import { P as lt } from "./PenAndPaper-DtLD2Sq6.js";
import { u as at } from "./useUserOptionState-BIvW1Kz7.js";
import { _ as ot } from "./_plugin-vue_export-helper-CHgC5LLL.js";
const st = ["id"], rt = {
  key: 1,
  ref: "noTitle",
  class: "vue-data-ui-no-title-space",
  style: "height:36px; width: 100%;background:transparent"
}, ut = {
  key: 2,
  style: "width:100%;background:transparent;padding-bottom:24px"
}, nt = ["xmlns", "viewBox"], it = ["width", "height"], ct = ["id"], vt = ["stdDeviation"], dt = ["d", "stroke", "stroke-width"], ht = ["d", "stroke", "stroke-width"], pt = ["filter"], yt = ["d", "stroke", "stroke-width"], gt = ["d", "stroke-width", "onMouseenter", "onClick"], ft = {
  key: 5,
  class: "vue-data-ui-watermark"
}, bt = ["onClick"], mt = { key: 0 }, kt = { key: 1 }, Ct = {
  key: 8,
  ref: "source",
  dir: "auto"
}, wt = ["innerHTML"], $t = {
  __name: "vue-ui-galaxy",
  props: {
    config: {
      type: Object,
      default() {
        return {};
      }
    },
    dataset: {
      type: Array,
      default() {
        return [];
      }
    }
  },
  emits: ["selectLegend", "selectDatapoint"],
  setup(me, { expose: ke, emit: X }) {
    const y = me, { vue_ui_galaxy: Ce } = Ee(), L = h(() => !!y.dataset && y.dataset.length);
    Le(() => {
      j();
    });
    function j() {
      Ve(y.dataset) ? he({
        componentName: "VueUiGalaxy",
        type: "dataset"
      }) : y.dataset.forEach((t, a) => {
        Me({
          datasetObject: t,
          requiredAttributes: ["name", "values"]
        }).forEach((l) => {
          he({
            componentName: "VueUiGalaxy",
            type: "datasetSerieAttribute",
            property: l,
            index: a
          });
        });
      });
    }
    const T = u(pe()), F = u(null), we = u(null), B = u(!1), G = u(""), g = u(null), R = u(0), Y = u(0), q = u(0), J = u(0), e = h({
      get: () => Z(),
      set: (t) => t
    }), { userOptionsVisible: z, setUserOptionsVisibility: K, keepUserOptionState: Q } = at({ config: e.value });
    function Z() {
      const t = be({
        userConfig: y.config,
        defaultConfig: Ce
      });
      return t.theme ? {
        ...be({
          userConfig: De.vue_ui_galaxy[t.theme] || y.config,
          defaultConfig: t
        }),
        customPalette: Be[t.theme] || D
      } : t;
    }
    Fe(() => y.config, (t) => {
      e.value = Z(), z.value = !e.value.showOnChartHover, j(), Y.value += 1, q.value += 1, J.value += 1;
    }, { deep: !0 });
    const { isPrinting: ee, isImaging: te, generatePdf: le, generateImage: ae } = Ke({
      elementId: `galaxy_${T.value}`,
      fileName: e.value.style.chart.title.text || "vue-ui-galaxy"
    }), $e = h(() => e.value.userOptions.show && !e.value.style.chart.title.text), xe = h(() => Ge(e.value.customPalette)), b = u({
      dataLabels: {
        show: e.value.style.chart.layout.labels.dataLabels.show
      },
      showTable: e.value.table.show,
      showTooltip: e.value.style.chart.tooltip.show
    }), P = u({
      height: 180,
      // or 250 if non fibo
      width: 250
    }), p = u([]);
    function U(t) {
      p.value.includes(t.id) ? p.value = p.value.filter((a) => a !== t.id) : p.value.push(t.id), X("selectLegend", S.value.map((a) => ({
        name: a.name,
        color: a.color,
        value: a.value
      })));
    }
    const C = h(() => y.dataset.map((t, a) => ({
      name: t.name,
      color: ze(t.color) || xe.value[a] || D[a] || D[a % D.length],
      value: t.values ? ye(t.values).reduce((l, s) => l + s, 0) : 0,
      absoluteValues: ye(t.values),
      id: pe(),
      seriesIndex: a
    })).sort((t, a) => a.value - t.value));
    function _e() {
      return C.value.map((t) => ({
        name: t.name,
        color: t.color,
        value: t.value
      }));
    }
    const f = h(() => C.value.filter((t) => !p.value.includes(t.id)).map((t) => t.value).reduce((t, a) => t + a, 0)), Te = u(190), oe = h(() => C.value.filter((t) => !p.value.includes(t.id))), S = h(() => {
      const t = [];
      for (let a = 0; a < oe.value.length; a += 1) {
        const l = oe.value[a];
        let s = l.value / f.value * Te.value;
        a > 0 && t.length && (s += t[a - 1].points), t.push({
          points: s,
          ...l,
          seriesIndex: a,
          proportion: l.value / f.value,
          path: Ue({
            points: s,
            startX: 115 + e.value.style.chart.layout.arcs.offsetX,
            startY: 90 + e.value.style.chart.layout.arcs.offsetY
          })
        });
      }
      return t.filter((a, l) => !p.value.includes(a.id)).toSorted((a, l) => l.points - a.points);
    }), x = u(!1);
    function Pe(t) {
      x.value = t, R.value += 1;
    }
    const W = u(null);
    function Se({ datapoint: t, _relativeIndex: a, seriesIndex: l, show: s = !1 }) {
      W.value = {
        datapoint: t,
        seriesIndex: l,
        series: C.value,
        config: e.value
      }, B.value = s, g.value = t.id;
      let r = "";
      const w = e.value.style.chart.tooltip.customFormat;
      fe(w) && He(() => w({
        seriesIndex: l,
        datapoint: t,
        series: C.value,
        config: e.value
      })) ? G.value = w({
        seriesIndex: l,
        datapoint: t,
        series: C.value,
        config: e.value
      }) : (r += `<div style="width:100%;text-align:center;border-bottom:1px solid ${e.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${t.name}</div>`, r += `<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="none" fill="${t.color}"/></svg>`, e.value.style.chart.tooltip.showValue && (r += `<b>${ge(
        e.value.style.chart.layout.labels.dataLabels.formatter,
        t.value,
        k({
          p: e.value.style.chart.layout.labels.dataLabels.prefix,
          v: t.value,
          s: e.value.style.chart.layout.labels.dataLabels.suffix,
          r: e.value.style.chart.tooltip.roundingValue
        }),
        { datapoint: t, seriesIndex: l }
      )}</b>`), e.value.style.chart.tooltip.showPercentage && (e.value.style.chart.tooltip.showValue ? r += `<span>(${k({
        v: t.proportion * 100,
        s: "%",
        r: e.value.style.chart.tooltip.roundingPercentage
      })})</span></div>` : r += `<b>${k({
        v: t.proportion * 100,
        s: "%",
        r: e.value.style.chart.tooltip.roundingPercentage
      })}</b></div>`), G.value = `<div>${r}</div>`);
    }
    const se = h(() => C.value.map((t, a) => ({
      ...t,
      proportion: (t.value || 0) / y.dataset.map((l) => (l.values || []).reduce((s, r) => s + r, 0)).reduce((l, s) => l + s, 0),
      opacity: p.value.includes(t.id) ? 0.5 : 1,
      shape: t.shape || "circle",
      segregate: () => U(t),
      isSegregated: p.value.includes(t.id)
    }))), Oe = h(() => ({
      cy: "galaxy-div-legend",
      backgroundColor: e.value.style.chart.legend.backgroundColor,
      color: e.value.style.chart.legend.color,
      fontSize: e.value.style.chart.legend.fontSize,
      paddingBottom: 12,
      fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
    })), m = h(() => {
      const t = S.value.map((l) => ({
        name: l.name,
        color: l.color
      })), a = S.value.map((l) => l.value);
      return { head: t, body: a };
    });
    function re() {
      Ae(() => {
        const t = m.value.head.map((s, r) => [[
          s.name
        ], [m.value.body[r]], [isNaN(m.value.body[r] / f.value) ? "-" : m.value.body[r] / f.value * 100]]), a = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [[""], ["val"], ["%"]]].concat(t), l = Xe(a);
        je({ csvContent: l, title: e.value.style.chart.title.text || "vue-ui-galaxy" });
      });
    }
    const I = h(() => {
      const t = [
        ' <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>',
        k({ p: e.value.style.chart.layout.labels.dataLabels.prefix, v: f.value, s: e.value.style.chart.layout.labels.dataLabels.suffix, r: e.value.table.td.roundingValue }),
        "100%"
      ], a = m.value.head.map((r, w) => {
        const Ne = k({ p: e.value.style.chart.layout.labels.dataLabels.prefix, v: m.value.body[w], s: e.value.style.chart.layout.labels.dataLabels.suffix, r: e.value.table.td.roundingValue });
        return [
          {
            color: r.color,
            name: r.name
          },
          Ne,
          isNaN(m.value.body[w] / f.value) ? "-" : k({
            v: m.value.body[w] / f.value * 100,
            s: "%",
            r: e.value.table.td.roundingPercentage
          })
        ];
      }), l = {
        th: {
          backgroundColor: e.value.table.th.backgroundColor,
          color: e.value.table.th.color,
          outline: e.value.table.th.outline
        },
        td: {
          backgroundColor: e.value.table.td.backgroundColor,
          color: e.value.table.td.color,
          outline: e.value.table.td.outline
        },
        breakpoint: e.value.table.responsiveBreakpoint
      };
      return {
        colNames: [
          e.value.table.columnNames.series,
          e.value.table.columnNames.value,
          e.value.table.columnNames.percentage
        ],
        head: t,
        body: a,
        config: l
      };
    });
    function ue() {
      b.value.showTable = !b.value.showTable;
    }
    function ne() {
      b.value.showTooltip = !b.value.showTooltip;
    }
    const A = u(!1);
    function H() {
      A.value = !A.value;
    }
    return ke({
      getData: _e,
      generatePdf: le,
      generateCsv: re,
      generateImage: ae,
      toggleTable: ue,
      toggleTooltip: ne,
      toggleAnnotator: H
    }), (t, a) => (o(), n("div", {
      ref_key: "galaxyChart",
      ref: F,
      class: E(`vue-ui-galaxy ${x.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${e.value.useCssAnimation ? "" : "vue-ui-dna"}`),
      style: V(`font-family:${e.value.style.fontFamily};width:100%; text-align:center;${e.value.style.chart.title.text ? "" : "padding-top:36px"};background:${e.value.style.chart.backgroundColor}`),
      id: `galaxy_${T.value}`,
      onMouseenter: a[3] || (a[3] = () => i(K)(!0)),
      onMouseleave: a[4] || (a[4] = () => i(K)(!1))
    }, [
      e.value.userOptions.buttons.annotator ? (o(), $(lt, {
        key: 0,
        parent: F.value,
        backgroundColor: e.value.style.chart.backgroundColor,
        color: e.value.style.chart.color,
        active: A.value,
        onClose: H
      }, null, 8, ["parent", "backgroundColor", "color", "active"])) : c("", !0),
      $e.value ? (o(), n("div", rt, null, 512)) : c("", !0),
      e.value.style.chart.title.text ? (o(), n("div", ut, [
        (o(), $(Ye, {
          key: `title_${Y.value}`,
          config: {
            title: {
              cy: "galaxy-div-title",
              ...e.value.style.chart.title
            },
            subtitle: {
              cy: "galaxy-div-subtitle",
              ...e.value.style.chart.title.subtitle
            }
          }
        }, null, 8, ["config"]))
      ])) : c("", !0),
      e.value.userOptions.show && L.value && (i(Q) || i(z)) ? (o(), $(Qe, {
        ref_key: "details",
        ref: we,
        key: `user_option_${R.value}`,
        backgroundColor: e.value.style.chart.backgroundColor,
        color: e.value.style.chart.color,
        isPrinting: i(ee),
        isImaging: i(te),
        uid: T.value,
        hasTooltip: e.value.userOptions.buttons.tooltip && e.value.style.chart.tooltip.show,
        hasPdf: e.value.userOptions.buttons.pdf,
        hasXls: e.value.userOptions.buttons.csv,
        hasImg: e.value.userOptions.buttons.img,
        hasTable: e.value.userOptions.buttons.table,
        hasFullscreen: e.value.userOptions.buttons.fullscreen,
        isTooltip: b.value.showTooltip,
        isFullscreen: x.value,
        titles: { ...e.value.userOptions.buttonTitles },
        chartElement: F.value,
        position: e.value.userOptions.position,
        hasAnnotator: e.value.userOptions.buttons.annotator,
        isAnnotation: A.value,
        onToggleFullscreen: Pe,
        onGeneratePdf: i(le),
        onGenerateCsv: re,
        onGenerateImage: i(ae),
        onToggleTable: ue,
        onToggleTooltip: ne,
        onToggleAnnotator: H,
        style: V({
          visibility: i(Q) ? i(z) ? "visible" : "hidden" : "visible"
        })
      }, Ie({ _: 2 }, [
        t.$slots.optionTooltip ? {
          name: "optionTooltip",
          fn: d(() => [
            v(t.$slots, "optionTooltip", {}, void 0, !0)
          ]),
          key: "0"
        } : void 0,
        t.$slots.optionPdf ? {
          name: "optionPdf",
          fn: d(() => [
            v(t.$slots, "optionPdf", {}, void 0, !0)
          ]),
          key: "1"
        } : void 0,
        t.$slots.optionCsv ? {
          name: "optionCsv",
          fn: d(() => [
            v(t.$slots, "optionCsv", {}, void 0, !0)
          ]),
          key: "2"
        } : void 0,
        t.$slots.optionImg ? {
          name: "optionImg",
          fn: d(() => [
            v(t.$slots, "optionImg", {}, void 0, !0)
          ]),
          key: "3"
        } : void 0,
        t.$slots.optionTable ? {
          name: "optionTable",
          fn: d(() => [
            v(t.$slots, "optionTable", {}, void 0, !0)
          ]),
          key: "4"
        } : void 0,
        t.$slots.optionFullscreen ? {
          name: "optionFullscreen",
          fn: d(({ toggleFullscreen: l, isFullscreen: s }) => [
            v(t.$slots, "optionFullscreen", O(N({ toggleFullscreen: l, isFullscreen: s })), void 0, !0)
          ]),
          key: "5"
        } : void 0,
        t.$slots.optionAnnotator ? {
          name: "optionAnnotator",
          fn: d(({ toggleAnnotator: l, isAnnotator: s }) => [
            v(t.$slots, "optionAnnotator", O(N({ toggleAnnotator: l, isAnnotator: s })), void 0, !0)
          ]),
          key: "6"
        } : void 0
      ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasTooltip", "hasPdf", "hasXls", "hasImg", "hasTable", "hasFullscreen", "isTooltip", "isFullscreen", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "onGeneratePdf", "onGenerateImage", "style"])) : c("", !0),
      L.value ? (o(), n("svg", {
        key: 4,
        xmlns: i(We),
        class: E({ "vue-data-ui-fullscreen--on": x.value, "vue-data-ui-fulscreen--off": !x.value }),
        viewBox: `0 0 ${P.value.width} ${P.value.height}`,
        style: V(`max-width:100%; overflow: visible; background:transparent;color:${e.value.style.chart.color}`)
      }, [
        ie(tt),
        t.$slots["chart-background"] ? (o(), n("foreignObject", {
          key: 0,
          x: 0,
          y: 0,
          width: P.value.width,
          height: P.value.height,
          style: {
            pointerEvents: "none"
          }
        }, [
          v(t.$slots, "chart-background", {}, void 0, !0)
        ], 8, it)) : c("", !0),
        _("defs", null, [
          _("filter", {
            id: `blur_${T.value}`,
            x: "-50%",
            y: "-50%",
            width: "200%",
            height: "200%"
          }, [
            _("feGaussianBlur", {
              in: "SourceGraphic",
              stdDeviation: 100 / e.value.style.chart.layout.arcs.gradient.intensity
            }, null, 8, vt)
          ], 8, ct)
        ]),
        (o(!0), n(ce, null, ve(S.value, (l) => (o(), n("g", null, [
          l.value ? (o(), n("path", {
            key: 0,
            d: l.path,
            fill: "none",
            stroke: e.value.style.chart.backgroundColor,
            "stroke-width": (e.value.style.chart.layout.arcs.strokeWidth + e.value.style.chart.layout.arcs.borderWidth) * (g.value === l.id && e.value.style.chart.layout.arcs.hoverEffect.show ? e.value.style.chart.layout.arcs.hoverEffect.multiplicator : 1),
            "stroke-linecap": "round"
          }, null, 8, dt)) : c("", !0),
          l.value ? (o(), n("path", {
            key: 1,
            d: l.path,
            fill: "none",
            stroke: l.color,
            "stroke-width": e.value.style.chart.layout.arcs.strokeWidth * (g.value === l.id && e.value.style.chart.layout.arcs.hoverEffect.show ? e.value.style.chart.layout.arcs.hoverEffect.multiplicator : 1),
            "stroke-linecap": "round",
            class: E(`${g.value && g.value !== l.id && e.value.useBlurOnHover ? "vue-ui-galaxy-blur" : ""}`)
          }, null, 10, ht)) : c("", !0),
          l.value && e.value.style.chart.layout.arcs.gradient.show ? (o(), n("g", {
            key: 2,
            filter: `url(#blur_${T.value})`
          }, [
            _("path", {
              d: l.path,
              fill: "none",
              stroke: e.value.style.chart.layout.arcs.gradient.color,
              "stroke-width": e.value.style.chart.layout.arcs.strokeWidth / 2 * (g.value === l.id && e.value.style.chart.layout.arcs.hoverEffect.show ? e.value.style.chart.layout.arcs.hoverEffect.multiplicator : 1),
              "stroke-linecap": "round",
              class: E(`vue-ui-galaxy-gradient ${g.value && g.value !== l.id && e.value.useBlurOnHover ? "vue-ui-galaxy-blur" : ""}`)
            }, null, 10, yt)
          ], 8, pt)) : c("", !0)
        ]))), 256)),
        (o(!0), n(ce, null, ve(S.value, (l, s) => (o(), n("g", null, [
          l.value ? (o(), n("path", {
            key: 0,
            d: l.path,
            fill: "none",
            stroke: "transparent",
            "stroke-width": e.value.style.chart.layout.arcs.strokeWidth + e.value.style.chart.layout.arcs.borderWidth,
            "stroke-linecap": "round",
            onMouseenter: (r) => Se({
              datapoint: l,
              relativeIndex: s,
              seriesIndex: l.seriesIndex,
              show: !0
            }),
            onMouseleave: a[0] || (a[0] = (r) => {
              B.value = !1, g.value = null;
            }),
            onClick: (r) => X("selectDatapoint", l)
          }, null, 40, gt)) : c("", !0)
        ]))), 256)),
        v(t.$slots, "svg", { svg: P.value }, void 0, !0)
      ], 14, nt)) : c("", !0),
      t.$slots.watermark ? (o(), n("div", ft, [
        v(t.$slots, "watermark", O(N({ isPrinting: i(ee) || i(te) })), void 0, !0)
      ])) : c("", !0),
      L.value ? c("", !0) : (o(), $(Ze, {
        key: 6,
        config: {
          type: "galaxy",
          style: {
            backgroundColor: e.value.style.chart.backgroundColor,
            galaxy: {
              color: "#CCCCCC"
            }
          }
        }
      }, null, 8, ["config"])),
      e.value.style.chart.legend.show ? (o(), $(Re, {
        key: `legend_${J.value}`,
        legendSet: se.value,
        config: Oe.value,
        onClickMarker: a[1] || (a[1] = ({ legend: l }) => U(l))
      }, {
        item: d(({ legend: l, index: s }) => [
          _("div", {
            onClick: (r) => U(l),
            style: V(`opacity:${p.value.includes(l.id) ? 0.5 : 1}`)
          }, [
            de(M(l.name) + ": " + M(i(ge)(
              e.value.style.chart.layout.labels.dataLabels.formatter,
              l.value,
              i(k)({
                p: e.value.style.chart.layout.labels.dataLabels.prefix,
                v: l.value,
                s: e.value.style.chart.layout.labels.dataLabels.suffix,
                r: e.value.style.chart.legend.roundingValue
              }),
              { datapoint: l, seriesIndex: s }
            )) + " ", 1),
            p.value.includes(l.id) ? (o(), n("span", kt, " ( - % ) ")) : (o(), n("span", mt, " (" + M(isNaN(l.value / f.value) ? "-" : i(k)({
              v: l.value / f.value * 100,
              s: "%",
              r: e.value.style.chart.legend.roundingPercentage
            })) + ") ", 1))
          ], 12, bt)
        ]),
        _: 1
      }, 8, ["legendSet", "config"])) : c("", !0),
      v(t.$slots, "legend", { legend: se.value }, void 0, !0),
      t.$slots.source ? (o(), n("div", Ct, [
        v(t.$slots, "source", {}, void 0, !0)
      ], 512)) : c("", !0),
      ie(qe, {
        show: b.value.showTooltip && B.value,
        backgroundColor: e.value.style.chart.tooltip.backgroundColor,
        color: e.value.style.chart.tooltip.color,
        borderRadius: e.value.style.chart.tooltip.borderRadius,
        borderColor: e.value.style.chart.tooltip.borderColor,
        borderWidth: e.value.style.chart.tooltip.borderWidth,
        fontSize: e.value.style.chart.tooltip.fontSize,
        backgroundOpacity: e.value.style.chart.tooltip.backgroundOpacity,
        position: e.value.style.chart.tooltip.position,
        offsetY: e.value.style.chart.tooltip.offsetY,
        parent: F.value,
        content: G.value,
        isFullscreen: x.value,
        isCustom: i(fe)(e.value.style.chart.tooltip.customFormat)
      }, {
        "tooltip-before": d(() => [
          v(t.$slots, "tooltip-before", O(N({ ...W.value })), void 0, !0)
        ]),
        "tooltip-after": d(() => [
          v(t.$slots, "tooltip-after", O(N({ ...W.value })), void 0, !0)
        ]),
        _: 3
      }, 8, ["show", "backgroundColor", "color", "borderRadius", "borderColor", "borderWidth", "fontSize", "backgroundOpacity", "position", "offsetY", "parent", "content", "isFullscreen", "isCustom"]),
      L.value ? (o(), $(et, {
        key: 9,
        hideDetails: "",
        config: {
          open: b.value.showTable,
          maxHeight: 1e4,
          body: {
            backgroundColor: e.value.style.chart.backgroundColor,
            color: e.value.style.chart.color
          },
          head: {
            backgroundColor: e.value.style.chart.backgroundColor,
            color: e.value.style.chart.color
          }
        }
      }, {
        content: d(() => [
          (o(), $(Je, {
            key: `table_${q.value}`,
            colNames: I.value.colNames,
            head: I.value.head,
            body: I.value.body,
            config: I.value.config,
            title: `${e.value.style.chart.title.text}${e.value.style.chart.title.subtitle.text ? ` : ${e.value.style.chart.title.subtitle.text}` : ""}`,
            onClose: a[2] || (a[2] = (l) => b.value.showTable = !1)
          }, {
            th: d(({ th: l }) => [
              _("div", {
                innerHTML: l,
                style: { display: "flex", "align-items": "center" }
              }, null, 8, wt)
            ]),
            td: d(({ td: l }) => [
              de(M(l.name || l), 1)
            ]),
            _: 1
          }, 8, ["colNames", "head", "body", "config", "title"]))
        ]),
        _: 1
      }, 8, ["config"])) : c("", !0)
    ], 46, st));
  }
}, Dt = /* @__PURE__ */ ot($t, [["__scopeId", "data-v-ce1544eb"]]);
export {
  Dt as default
};
