import { computed as m, ref as h, onMounted as He, onBeforeUnmount as Oe, watch as Ie, openBlock as s, createElementBlock as i, normalizeClass as T, normalizeStyle as L, createVNode as ee, createCommentVNode as c, createBlock as U, unref as y, createSlots as De, withCtx as k, renderSlot as _, normalizeProps as te, guardReactiveProps as le, createElementVNode as v, Fragment as S, renderList as X, toDisplayString as x, createTextVNode as Ee, nextTick as Ue } from "vue";
import { u as Ge, c as ze, t as Qe, a as Je, p as ie, o as je, e as R, b as Ze, w as ae, d as Ke, i as A, f as V, X as et, v as tt, R as lt, E as at, x as ut, y as ot, q as st, r as rt } from "./index-CguVaFlt.js";
import { t as it, u as nt } from "./useResponsive-NZB-WLRF.js";
import { _ as vt } from "./Title-DbTGPg4G.js";
import { u as dt, U as ct } from "./usePrinter-ClsMRVJG.js";
import { _ as ht } from "./Tooltip-u79R5W5y.js";
import { _ as Te } from "./Shape-D3yIJobN.js";
import { L as yt } from "./Legend-CsVEDSh6.js";
import { D as bt } from "./DataTable-BwHWRlRZ.js";
import ft from "./vue-ui-skeleton-ChHLL5Hw.js";
import pt from "./vue-ui-accordion-w15FGKRN.js";
import { u as We } from "./useNestedProp-BbEbJmgv.js";
import { _ as gt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
const mt = ["id"], xt = ["xmlns", "viewBox", "id"], $t = ["id"], kt = ["stop-color"], Lt = ["stop-color"], wt = { key: 0 }, qt = ["fill", "x", "y", "height", "width", "stroke-width", "stroke", "rx"], _t = ["x1", "y1", "x2", "y2", "stroke", "stroke-width"], St = ["x1", "y1", "x2", "y2", "stroke", "stroke-width"], Ct = { key: 1 }, zt = ["points", "fill"], Tt = ["points", "fill"], Wt = ["points", "fill"], Xt = ["points", "fill"], Yt = { key: 2 }, Mt = ["y", "fill", "font-size"], Nt = ["x", "y", "fill", "font-size"], At = ["x", "y", "fill", "font-size"], Vt = ["y", "fill", "font-size"], Bt = { key: 3 }, Pt = ["x", "y", "font-size", "fill"], Rt = ["x", "y", "font-size", "fill"], Ft = ["x", "y", "font-size", "fill"], Ht = ["id", "font-size", "transform", "fill"], Ot = ["id", "font-size", "transform", "fill"], It = ["id", "font-size", "transform", "fill"], Dt = { key: 4 }, Et = ["fill", "points"], Ut = ["x", "y", "width", "height"], Gt = ["x", "y", "width", "height"], Qt = ["x", "y", "width", "height"], Jt = ["x", "y", "width", "height"], jt = { key: 0 }, Zt = ["x", "y", "font-size", "fill"], Kt = { key: 0 }, el = ["x", "y", "onMouseover", "onClick"], tl = {
  key: 7,
  class: "vue-ui-dna"
}, ll = ["points", "fill"], al = ["points", "fill"], ul = ["points", "fill"], ol = ["points", "fill"], sl = { key: 8 }, rl = ["x", "y", "font-size", "fill", "font-weight"], il = { key: 9 }, nl = ["x", "y", "fill"], vl = ["x", "y", "fill"], dl = ["x", "y", "fill"], cl = ["x", "y", "fill"], hl = ["stroke", "d"], yl = ["stroke", "d"], bl = {
  key: 3,
  class: "vue-data-ui-watermark"
}, fl = ["onClick"], pl = {
  key: 0,
  height: "14",
  width: "14",
  viewBox: "0 0 20 20"
}, gl = ["innerHTML"], ml = {
  __name: "vue-ui-quadrant",
  props: {
    config: {
      type: Object,
      default() {
        return {};
      }
    },
    dataset: {
      type: Array,
      default() {
        return [];
      }
    }
  },
  emits: ["selectPlot", "selectSide", "selectLegend"],
  setup(Xe, { expose: Ye, emit: ue }) {
    const Y = Xe, { vue_ui_quadrant: Me } = Ge(), G = m(() => !!Y.dataset && Y.dataset.length), z = h(ze()), Ne = h(null), Q = h(!1), oe = h(""), ne = h(0), p = h(!1), F = h(null), ve = h(null), de = h(null), t = m(() => {
      const l = We({
        userConfig: Y.config,
        defaultConfig: Me
      });
      return l.theme ? {
        ...We({
          userConfig: Qe.vue_ui_quadrant[l.theme] || Y.config,
          defaultConfig: l
        }),
        customPalette: Je[l.theme] || ie
      } : l;
    }), J = h(null);
    He(() => {
      if (je(Y.dataset) ? R({
        componentName: "VueUiQuadrant",
        type: "dataset"
      }) : Y.dataset.forEach((l, u) => {
        [null, void 0].includes(l.name) && R({
          componentName: "VueUiQuadrant",
          type: "datasetSerieAttribute",
          property: "name",
          index: u
        }), [null, void 0].includes(l.series) ? R({
          componentName: "VueUiQuadrant",
          type: "datasetSerieAttribute",
          property: "series",
          index: u
        }) : l.series.forEach((a, o) => {
          [null, void 0].includes(a.name) && R({
            componentName: "VueUiQuadrant",
            type: "datasetSerieAttribute",
            property: "name",
            key: "series",
            index: o
          });
        });
      }), t.value.responsive) {
        const l = it(() => {
          const { width: u, height: a } = nt({
            chart: F.value,
            title: t.value.style.chart.title.text ? ve.value : null,
            legend: t.value.style.chart.legend.show ? de.value : null
          });
          g.value = 48, e.value.height = a, e.value.usableHeight = a - g.value * 2, e.value.width = u, e.value.usableWidth = u - g.value * 2, e.value.top = g.value, e.value.left = g.value, e.value.right = u - g.value, e.value.bottom = a - g.value, e.value.centerX = u / 2, e.value.centerY = a - a / 2, e.value.padding = g.value;
        });
        J.value = new ResizeObserver(l), J.value.observe(F.value.parentNode);
      }
    }), Oe(() => {
      J.value && J.value.disconnect();
    });
    const { isPrinting: ce, isImaging: he, generatePdf: ye, generateImage: be } = dt({
      elementId: `vue-ui-quadrant_${z.value}`,
      fileName: t.value.style.chart.title.text || "vue-ui-quadrant"
    }), fe = m(() => Ze(t.value.customPalette)), w = h({
      plotLabels: {
        show: t.value.style.chart.layout.labels.plotLabels.show
      },
      showTable: t.value.table.show,
      showTooltip: t.value.style.chart.tooltip.show
    }), g = h(48), e = h({
      height: t.value.style.chart.height,
      usableHeight: t.value.style.chart.height - g.value * 2,
      width: t.value.style.chart.width,
      usableWidth: t.value.style.chart.width - g.value * 2,
      top: g.value,
      left: g.value,
      right: t.value.style.chart.width - g.value,
      bottom: t.value.style.chart.height - g.value,
      centerX: t.value.style.chart.width / 2,
      centerY: t.value.style.chart.height - t.value.style.chart.height / 2,
      padding: g.value
    }), d = h({
      ...JSON.parse(JSON.stringify(e.value)),
      startX: 0,
      startY: 0
    });
    Ie(() => e.value, (l) => {
      l && (d.value = {
        ...JSON.parse(JSON.stringify(e.value)),
        startX: 0,
        startY: 0
      });
    }, { deep: !0 });
    const n = h(null), B = m(() => {
      switch (n.value) {
        case "TL":
          return {
            x: d.value.startX + d.value.width / 2,
            y: d.value.height,
            text: t.value.style.chart.layout.labels.quadrantLabels.tl.text || "Top Left",
            fontSize: t.value.style.chart.layout.labels.quadrantLabels.tl.fontSize,
            fill: t.value.style.chart.layout.labels.quadrantLabels.tl.color,
            bold: t.value.style.chart.layout.labels.quadrantLabels.tl.bold
          };
        case "TR":
          return {
            x: d.value.startX + d.value.width / 2,
            y: d.value.height,
            text: t.value.style.chart.layout.labels.quadrantLabels.tr.text || "Top Right",
            fontSize: t.value.style.chart.layout.labels.quadrantLabels.tr.fontSize,
            fill: t.value.style.chart.layout.labels.quadrantLabels.tr.color,
            bold: t.value.style.chart.layout.labels.quadrantLabels.tr.bold
          };
        case "BR":
          return {
            x: d.value.startX + d.value.width / 2,
            y: d.value.height * 1.678,
            text: t.value.style.chart.layout.labels.quadrantLabels.br.text || "Bottom Right",
            fontSize: t.value.style.chart.layout.labels.quadrantLabels.br.fontSize,
            fill: t.value.style.chart.layout.labels.quadrantLabels.br.color,
            bold: t.value.style.chart.layout.labels.quadrantLabels.br.bold
          };
        case "BL":
          return {
            x: d.value.startX + d.value.width / 2,
            y: d.value.height * 1.678,
            text: t.value.style.chart.layout.labels.quadrantLabels.bl.text || "Bottom Left",
            fontSize: t.value.style.chart.layout.labels.quadrantLabels.bl.fontSize,
            fill: t.value.style.chart.layout.labels.quadrantLabels.bl.color,
            bold: t.value.style.chart.layout.labels.quadrantLabels.bl.bold
          };
        default:
          return { x: 0, y: 0, text: "", fontSize: 0, fill: "none", bold: !1 };
      }
    }), Ae = h(null), j = h(!1);
    function H({ targetX: l, targetY: u, targetW: a, targetH: o, side: r }) {
      n.value && D(r);
      const b = {
        x: l - d.value.startX,
        y: u - d.value.startY,
        w: a - d.value.width,
        h: o - d.value.height
      }, f = t.value.zoomAnimationFrames;
      let W = 0;
      function Ce() {
        j.value = !0, d.value.startX += b.x / f, d.value.startY += b.y / f, d.value.width += b.w / f, d.value.height += b.h / f, W += 1, W < f ? Ae.value = requestAnimationFrame(Ce) : j.value = !1;
      }
      Ce();
    }
    function M(l) {
      if (!j.value)
        if (p.value && n.value === l)
          H({
            targetX: 0,
            targetY: 0,
            targetW: e.value.width,
            targetH: e.value.height
          }), n.value = null, p.value = !1;
        else {
          switch (n.value = l, l) {
            case "TL":
              H({
                targetX: 0,
                targetY: 0,
                targetW: e.value.width / 2 + e.value.left,
                targetH: e.value.height / 2 + e.value.top,
                side: "tl"
              });
              break;
            case "TR":
              H({
                targetX: e.value.width / 2 - e.value.left,
                targetY: 0,
                targetW: e.value.width / 2 + e.value.left,
                targetH: e.value.height / 2 + e.value.top,
                side: "tr"
              });
              break;
            case "BR":
              H({
                targetX: e.value.width / 2 - e.value.left,
                targetY: e.value.height / 2 - e.value.top,
                targetW: e.value.width / 2 + e.value.left,
                targetH: e.value.height / 2 + e.value.top,
                side: "br"
              });
              break;
            case "BL":
              H({
                targetX: 0,
                targetY: e.value.height / 2 - e.value.top,
                targetW: e.value.width / 2 + e.value.left,
                targetH: e.value.height / 2 + e.value.top,
                side: "bl"
              });
              break;
            default:
              d.value.startX = 0, d.value.startY = 0, d.value.width = e.value.width, d.value.height = e.value.height;
              break;
          }
          p.value = !0;
        }
    }
    const Ve = m(() => {
      const l = t.value.style.chart.layout.grid.graduations.steps, u = e.value.usableWidth / (l * 2), a = e.value.top, o = [];
      for (let r = 0; r < l; r += 1)
        o.push({
          x: e.value.padding + u * r,
          y: a + e.value.usableHeight * (r / l / 2),
          height: e.value.usableHeight * (1 - r / l),
          width: e.value.usableWidth * (1 - r / l),
          opacity: ae[Math.round((r + 1) / l * 20)]
        });
      return o;
    }), q = m(() => {
      let l = t.value.style.chart.layout.grid.xAxis.max, u = t.value.style.chart.layout.grid.xAxis.min, a = t.value.style.chart.layout.grid.yAxis.max, o = t.value.style.chart.layout.grid.yAxis.min;
      return t.value.style.chart.layout.grid.xAxis.auto && (l = Math.max(...P.value.flatMap((r) => r.series.map((b) => b.x))), u = Math.min(...P.value.flatMap((r) => r.series.map((b) => b.x)))), t.value.style.chart.layout.grid.yAxis.auto && (a = Math.max(...P.value.flatMap((r) => r.series.map((b) => b.y))), o = Math.min(...P.value.flatMap((r) => r.series.map((b) => b.y)))), {
        x: {
          max: l,
          min: u
        },
        y: {
          max: a,
          min: o
        }
      };
    }), N = h([]), P = m(() => Y.dataset.map((l, u) => ({
      ...l,
      id: `cat_${u}_${z.value}`,
      color: Ke(l.color) || fe.value[u] || ie[u]
    }))), Be = m(() => P.value.filter((l) => !N.value.includes(l.id))), Pe = m(() => P.value.map((l, u) => ({
      ...l,
      shape: l.shape || "circle",
      series: l.series.map((a) => ({
        ...a,
        x: pe(a.x),
        y: ge(a.y),
        xValue: a.x,
        yValue: a.y,
        quadrantSide: xe({ x: a.x, y: a.y }),
        categoryName: l.name,
        shape: l.shape,
        color: l.color
      }))
    }))), C = m(() => (Y.dataset.forEach((l, u) => {
      l.series.forEach((a, o) => {
        [null, void 0].includes(a.x) && R({
          componentName: "VueUiQuadrant",
          type: "datasetSerieAttribute",
          property: "x",
          key: "series",
          index: o
        }), [null, void 0].includes(a.y) && R({
          componentName: "VueUiQuadrant",
          type: "datasetSerieAttribute",
          property: "y",
          key: "series",
          index: o
        });
      });
    }), Be.value.map((l, u) => ({
      ...l,
      shape: l.shape || "circle",
      color: l.color || fe.value[u] || ie[u],
      series: l.series.map((a) => ({
        ...a,
        x: pe(a.x),
        y: ge(a.y),
        xValue: a.x,
        yValue: a.y,
        quadrantSide: xe({ x: a.x, y: a.y }),
        categoryName: l.name,
        shape: l.shape,
        color: l.color,
        uid: ze()
      }))
    }))));
    function pe(l) {
      if (l >= 0) {
        const u = l / q.value.x.max;
        return e.value.centerX + e.value.usableWidth / 2 * u;
      } else {
        const u = Math.abs(l) / Math.abs(q.value.x.min);
        return e.value.centerX - e.value.usableWidth / 2 * u;
      }
    }
    function ge(l) {
      if (l >= 0) {
        const u = l / q.value.y.max;
        return e.value.centerY + (1 - e.value.usableHeight / 2 * u);
      } else {
        const u = Math.abs(l) / Math.abs(q.value.y.min);
        return e.value.centerY - (1 - e.value.usableHeight / 2 * u);
      }
    }
    const Z = m(() => {
      const l = C.value.flatMap((f) => f.series.map((W) => ({
        x: W.xValue,
        y: W.yValue,
        name: W.name,
        category: W.categoryName,
        quadrantSide: W.quadrantSide,
        sideName: t.value.style.chart.layout.labels.quadrantLabels[W.quadrantSide].text,
        color: f.color,
        shape: f.shape
      }))), u = t.value.style.chart.layout.grid.xAxis.name || "x", a = t.value.style.chart.layout.grid.yAxis.name || "y", o = [t.value.translations.category, t.value.translations.item, u, a, t.value.translations.side], r = l.map((f) => [f.category, f.name, f.x, f.y, f.sideName || f.quadrantSide]), b = l.map((f) => ({
        shape: f.shape,
        color: f.color
      }));
      return { head: o, body: r, itsShapes: b, tableData: l };
    }), K = m(() => {
      const l = Z.value.head, u = Z.value.tableData.map((o) => [
        {
          shape: o.shape,
          color: o.color,
          name: o.category
        },
        o.name,
        A(
          t.value.style.chart.layout.labels.plotLabels.x.formatter,
          o.x,
          V({
            v: o.x,
            r: t.value.style.chart.layout.labels.plotLabels.rounding
          })
        ),
        A(
          t.value.style.chart.layout.labels.plotLabels.y.formatter,
          o.y,
          V({
            v: o.y,
            r: t.value.style.chart.layout.labels.plotLabels.rounding
          })
        ),
        o.sideName || o.quadrantSide
      ]), a = {
        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
      };
      return { head: l, body: u, config: a, colNames: l };
    });
    function se(l) {
      N.value.includes(l) ? N.value = N.value.filter((a) => a !== l) : N.value.push(l);
      const u = Le();
      ue("selectLegend", u);
    }
    const me = m(() => Pe.value.map((l) => ({
      name: l.name,
      shape: l.shape,
      color: l.color,
      id: l.id,
      opacity: N.value.includes(l.id) ? 0.5 : 1,
      segregate: () => se(l.id),
      isSegregated: N.value.includes(l.id)
    }))), Re = m(() => ({
      cy: "quadrant-div-legend",
      backgroundColor: t.value.style.chart.legend.backgroundColor,
      color: t.value.style.chart.legend.color,
      fontSize: t.value.style.chart.legend.fontSize,
      paddingBottom: 12,
      fontWeight: t.value.style.chart.legend.bold ? "bold" : ""
    }));
    function xe(l) {
      switch (!0) {
        case (l.x >= 0 && l.y >= 0):
          return "tr";
        case (l.x >= 0 && l.y < 0):
          return "br";
        case (l.x < 0 && l.y < 0):
          return "bl";
        case (l.x < 0 && l.y >= 0):
          return "tl";
        default:
          return "";
      }
    }
    const O = h(null), I = h(null), re = h(null);
    function $e(l, u, a) {
      O.value = u.uid, I.value = {
        color: l.color,
        shape: l.shape
      }, re.value = {
        datapoint: u,
        seriesIndex: a,
        series: C.value,
        config: t.value
      }, Q.value = !0;
      const o = t.value.style.chart.tooltip.customFormat;
      if (ut(o) && ot(() => o({
        seriesIndex: a,
        datapoint: u,
        series: C.value,
        config: t.value
      })))
        oe.value = o({
          seriesIndex: a,
          datapoint: u,
          series: C.value,
          config: t.value
        });
      else {
        let r = "";
        u.quadrantSide && (r += `<div style="color:${t.value.style.chart.layout.labels.quadrantLabels[u.quadrantSide].color};font-weight:${t.value.style.chart.layout.labels.quadrantLabels[u.quadrantSide].bold ? "bold" : "400"}">${t.value.style.chart.layout.labels.quadrantLabels[u.quadrantSide].text}</div>`), r += `<div>${l.name}</div>`, r += `<div style="padding-bottom:6px;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};margin-bottom:3px">${u.name}</div>`, r += `<div>${t.value.style.chart.layout.grid.xAxis.name ? t.value.style.chart.layout.grid.xAxis.name : "x"}: <b>${A(
          t.value.style.chart.layout.labels.plotLabels.x.formatter,
          u.xValue,
          V({
            v: u.xValue,
            r: t.value.style.chart.tooltip.roundingValue
          }),
          { datapoint: u, category: l, categoryIndex: a }
        )}</b></div>`, r += `<div>${t.value.style.chart.layout.grid.yAxis.name ? t.value.style.chart.layout.grid.yAxis.name : "y"}: <b>${A(
          t.value.style.chart.layout.labels.plotLabels.y.formatter,
          u.yValue,
          V({
            v: u.yValue,
            r: t.value.style.chart.tooltip.roundingValue
          }),
          { datapoint: u, category: l, categoryIndex: a }
        )}</b></div>`, oe.value = `<div style="text-align:left;font-size:${t.value.style.chart.tooltip.fontSize}px">${r}</div>`;
      }
    }
    function ke(l, u) {
      const a = {
        category: l.name,
        shape: l.shape,
        itemName: u.name,
        x: u.xValue,
        y: u.yValue,
        quadrantSide: u.quadrantSide,
        sideName: t.value.style.chart.layout.labels.quadrantLabels[u.quadrantSide].text
      };
      ue("selectPlot", a);
    }
    function D(l) {
      if (!l) return;
      const u = C.value.flatMap((o) => o.series.filter((r) => r.quadrantSide === l).map((r) => ({
        category: r.categoryName,
        itemName: r.name,
        x: r.xValue,
        y: r.yValue
      }))), a = {
        quadrantSide: l,
        sideName: t.value.style.chart.layout.labels.quadrantLabels[l].text,
        items: [...u]
      };
      ue("selectSide", a);
    }
    const $ = m(() => ({
      TL: {
        tl: {
          x: e.value.left + e.value.usableWidth / 4 - 20,
          y: 0,
          fill: t.value.style.chart.layout.labels.quadrantLabels.tl.color
        },
        tr: {
          x: e.value.left + e.value.usableWidth / 4,
          y: 0,
          fill: t.value.style.chart.layout.labels.quadrantLabels.tr.color
        },
        br: {
          x: e.value.left + e.value.usableWidth / 4,
          y: 20,
          fill: t.value.style.chart.layout.labels.quadrantLabels.br.color
        },
        bl: {
          x: e.value.left + e.value.usableWidth / 4 - 20,
          y: 20,
          fill: t.value.style.chart.layout.labels.quadrantLabels.bl.color
        },
        crosshairs: {
          horizontal: `M ${e.value.left + e.value.usableWidth / 4 - 20},20 ${e.value.left + e.value.usableWidth / 4 + 20},20`,
          vertical: `M ${e.value.left + e.value.usableWidth / 4},0 ${e.value.left + e.value.usableWidth / 4},40`
        }
      },
      TR: {
        tl: {
          x: e.value.centerX + e.value.usableWidth / 4 - 20,
          y: 0,
          fill: t.value.style.chart.layout.labels.quadrantLabels.tl.color
        },
        tr: {
          x: e.value.centerX + e.value.usableWidth / 4,
          y: 0,
          fill: t.value.style.chart.layout.labels.quadrantLabels.tr.color
        },
        br: {
          x: e.value.centerX + e.value.usableWidth / 4,
          y: 20,
          fill: t.value.style.chart.layout.labels.quadrantLabels.br.color
        },
        bl: {
          x: e.value.centerX + e.value.usableWidth / 4 - 20,
          y: 20,
          fill: t.value.style.chart.layout.labels.quadrantLabels.bl.color
        },
        crosshairs: {
          horizontal: `M ${e.value.centerX + e.value.usableWidth / 4 - 20},20 ${e.value.centerX + e.value.usableWidth / 4 + 20},20`,
          vertical: `M ${e.value.centerX + e.value.usableWidth / 4},0 ${e.value.centerX + e.value.usableWidth / 4},40`
        }
      },
      BR: {
        tl: {
          x: e.value.centerX + e.value.usableWidth / 4 - 20,
          y: e.value.centerY - 48,
          fill: t.value.style.chart.layout.labels.quadrantLabels.tl.color
        },
        tr: {
          x: e.value.centerX + e.value.usableWidth / 4,
          y: e.value.centerY - 48,
          fill: t.value.style.chart.layout.labels.quadrantLabels.tr.color
        },
        br: {
          x: e.value.centerX + e.value.usableWidth / 4,
          y: e.value.centerY - 28,
          fill: t.value.style.chart.layout.labels.quadrantLabels.br.color
        },
        bl: {
          x: e.value.centerX + e.value.usableWidth / 4 - 20,
          y: e.value.centerY - 28,
          fill: t.value.style.chart.layout.labels.quadrantLabels.bl.color
        },
        crosshairs: {
          horizontal: `M ${e.value.centerX + e.value.usableWidth / 4 - 20},${e.value.centerY - 28} ${e.value.centerX + e.value.usableWidth / 4 + 20},${e.value.centerY - 28}`,
          vertical: `M ${e.value.centerX + e.value.usableWidth / 4},${e.value.centerY - 48} ${e.value.centerX + e.value.usableWidth / 4},${e.value.centerY - 8}`
        }
      },
      BL: {
        tl: {
          x: e.value.left + e.value.usableWidth / 4 - 20,
          y: e.value.centerY - 48,
          fill: t.value.style.chart.layout.labels.quadrantLabels.tl.color
        },
        tr: {
          x: e.value.left + e.value.usableWidth / 4,
          y: e.value.centerY - 48,
          fill: t.value.style.chart.layout.labels.quadrantLabels.tr.color
        },
        br: {
          x: e.value.left + e.value.usableWidth / 4,
          y: e.value.centerY - 28,
          fill: t.value.style.chart.layout.labels.quadrantLabels.br.color
        },
        bl: {
          x: e.value.left + e.value.usableWidth / 4 - 20,
          y: e.value.centerY - 28,
          fill: t.value.style.chart.layout.labels.quadrantLabels.bl.color
        },
        crosshairs: {
          horizontal: `M ${e.value.left + e.value.usableWidth / 4 - 20},${e.value.centerY - 28} ${e.value.left + e.value.usableWidth / 4 + 20},${e.value.centerY - 28}`,
          vertical: `M ${e.value.left + e.value.usableWidth / 4},${e.value.centerY - 48} ${e.value.left + e.value.usableWidth / 4},${e.value.centerY - 8}`
        }
      }
    }));
    function Le() {
      return C.value.map((l) => ({
        color: l.color,
        name: l.name,
        shape: l.shape,
        series: l.series.map((u) => ({
          name: u.name,
          x: u.xValue,
          y: u.yValue,
          quadrantSide: u.quadrantSide,
          sideName: t.value.style.chart.layout.labels.quadrantLabels[u.quadrantSide].text
        }))
      }));
    }
    function we() {
      Ue(() => {
        const l = [[t.value.style.chart.title.text], [t.value.style.chart.title.subtitle.text], [""]], u = Z.value.head, a = Z.value.body, o = l.concat([u]).concat(a), r = st(o);
        rt({ csvContent: r, title: t.value.style.chart.title.text || "vue-ui-quadrant" });
      });
    }
    const E = h(!1);
    function Fe(l) {
      E.value = l, ne.value += 1;
    }
    function qe() {
      w.value.showTable = !w.value.showTable;
    }
    function _e() {
      w.value.plotLabels.show = !w.value.plotLabels.show;
    }
    function Se() {
      w.value.showTooltip = !w.value.showTooltip;
    }
    return Ye({
      getData: Le,
      generatePdf: ye,
      generateCsv: we,
      generateImage: be,
      toggleTable: qe,
      toggleLabels: _e,
      toggleTooltip: Se
    }), (l, u) => (s(), i("div", {
      class: T(`vue-ui-quadrant ${E.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${t.value.useCssAnimation ? "" : "vue-ui-dna"}`),
      ref_key: "quadrantChart",
      ref: F,
      id: `vue-ui-quadrant_${z.value}`,
      style: L(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;${t.value.style.chart.title.text ? "" : "padding-top: 36px"};background:${t.value.style.chart.backgroundColor};${t.value.responsive ? "height: 100%" : ""}`)
    }, [
      t.value.style.chart.title.text ? (s(), i("div", {
        key: 0,
        ref_key: "chartTitle",
        ref: ve,
        style: L(`width:100%;background:${t.value.style.chart.backgroundColor};padding-bottom:12px`)
      }, [
        ee(vt, {
          config: {
            title: {
              cy: "quadrant-title",
              ...t.value.style.chart.title
            },
            subtitle: {
              cy: "quadrant-subtitle",
              ...t.value.style.chart.title.subtitle
            }
          }
        }, null, 8, ["config"])
      ], 4)) : c("", !0),
      t.value.userOptions.show && G.value ? (s(), U(ct, {
        ref_key: "details",
        ref: Ne,
        key: `user_options_${ne.value}`,
        backgroundColor: t.value.style.chart.backgroundColor,
        color: t.value.style.chart.color,
        isImaging: y(he),
        isPrinting: y(ce),
        uid: z.value,
        hasTooltip: t.value.userOptions.buttons.tooltip && t.value.style.chart.tooltip.show,
        hasPdf: t.value.userOptions.buttons.pdf,
        hasImg: t.value.userOptions.buttons.img,
        hasXls: t.value.userOptions.buttons.csv,
        hasTable: t.value.userOptions.buttons.table,
        hasLabel: t.value.userOptions.buttons.labels,
        hasFullscreen: t.value.userOptions.buttons.fullscreen,
        isFullscreen: E.value,
        isTooltip: w.value.showTooltip,
        titles: { ...t.value.userOptions.buttonTitles },
        chartElement: F.value,
        onToggleFullscreen: Fe,
        onGeneratePdf: y(ye),
        onGenerateCsv: we,
        onGenerateImage: y(be),
        onToggleTable: qe,
        onToggleLabels: _e,
        onToggleTooltip: Se
      }, De({ _: 2 }, [
        l.$slots.optionTooltip ? {
          name: "optionTooltip",
          fn: k(() => [
            _(l.$slots, "optionTooltip", {}, void 0, !0)
          ]),
          key: "0"
        } : void 0,
        l.$slots.optionPdf ? {
          name: "optionPdf",
          fn: k(() => [
            _(l.$slots, "optionPdf", {}, void 0, !0)
          ]),
          key: "1"
        } : void 0,
        l.$slots.optionCsv ? {
          name: "optionCsv",
          fn: k(() => [
            _(l.$slots, "optionCsv", {}, void 0, !0)
          ]),
          key: "2"
        } : void 0,
        l.$slots.optionImg ? {
          name: "optionImg",
          fn: k(() => [
            _(l.$slots, "optionImg", {}, void 0, !0)
          ]),
          key: "3"
        } : void 0,
        l.$slots.optionTable ? {
          name: "optionTable",
          fn: k(() => [
            _(l.$slots, "optionTable", {}, void 0, !0)
          ]),
          key: "4"
        } : void 0,
        l.$slots.optionLabels ? {
          name: "optionLabels",
          fn: k(() => [
            _(l.$slots, "optionLabels", {}, void 0, !0)
          ]),
          key: "5"
        } : void 0,
        l.$slots.optionFullscreen ? {
          name: "optionFullscreen",
          fn: k(({ toggleFullscreen: a, isFullscreen: o }) => [
            _(l.$slots, "optionFullscreen", te(le({ toggleFullscreen: a, isFullscreen: o })), void 0, !0)
          ]),
          key: "6"
        } : void 0
      ]), 1032, ["backgroundColor", "color", "isImaging", "isPrinting", "uid", "hasTooltip", "hasPdf", "hasImg", "hasXls", "hasTable", "hasLabel", "hasFullscreen", "isFullscreen", "isTooltip", "titles", "chartElement", "onGeneratePdf", "onGenerateImage"])) : c("", !0),
      G.value ? (s(), i("svg", {
        key: 2,
        xmlns: y(et),
        class: T({ "vue-data-ui-fullscreen--on": E.value, "vue-data-ui-fulscreen--off": !E.value }),
        viewBox: `${d.value.startX} ${d.value.startY} ${d.value.width} ${d.value.height}`,
        style: L(`max-width:100%;overflow:${p.value ? "hidden" : "visible"};background:${t.value.style.chart.backgroundColor};color:${t.value.style.chart.color}`),
        id: `svg_${z.value}`
      }, [
        v("defs", null, [
          (s(!0), i(S, null, X(C.value, (a, o) => (s(), i("radialGradient", {
            cx: "50%",
            cy: "50%",
            r: "50%",
            fx: "50%",
            fy: "50%",
            id: `quadrant_gradient_${z.value}_${o}`
          }, [
            v("stop", {
              offset: "0%",
              "stop-color": `${y(tt)(a.color, 0.05)}${y(ae)[t.value.style.chart.layout.areas.opacity]}`
            }, null, 8, kt),
            v("stop", {
              offset: "100%",
              "stop-color": a.color + y(ae)[t.value.style.chart.layout.areas.opacity]
            }, null, 8, Lt)
          ], 8, $t))), 256))
        ]),
        t.value.style.chart.layout.grid.graduations.show ? (s(), i("g", wt, [
          (s(!0), i(S, null, X(Ve.value, (a) => (s(), i("rect", {
            fill: t.value.style.chart.layout.grid.graduations.fill ? `${t.value.style.chart.layout.grid.graduations.color}${a.opacity}` : "none",
            x: a.x,
            y: a.y,
            height: a.height <= 0 ? 1e-3 : a.height,
            width: a.width <= 0 ? 1e-3 : a.width,
            "stroke-width": t.value.style.chart.layout.grid.graduations.strokeWidth,
            stroke: t.value.style.chart.layout.grid.graduations.stroke,
            rx: t.value.style.chart.layout.grid.graduations.roundingForce
          }, null, 8, qt))), 256))
        ])) : c("", !0),
        v("line", {
          x1: e.value.left,
          y1: e.value.centerY,
          x2: e.value.right,
          y2: e.value.centerY,
          stroke: t.value.style.chart.layout.grid.stroke,
          "stroke-width": t.value.style.chart.layout.grid.strokeWidth
        }, null, 8, _t),
        v("line", {
          x1: e.value.centerX,
          y1: e.value.top,
          x2: e.value.centerX,
          y2: e.value.bottom,
          stroke: t.value.style.chart.layout.grid.stroke,
          "stroke-width": t.value.style.chart.layout.grid.strokeWidth
        }, null, 8, St),
        t.value.style.chart.layout.grid.showArrows ? (s(), i("g", Ct, [
          v("polygon", {
            points: `${e.value.right - 8},${e.value.centerY - 6} ${e.value.right},${e.value.centerY} ${e.value.right - 8},${e.value.centerY + 6}`,
            fill: t.value.style.chart.layout.grid.stroke,
            stroke: "none"
          }, null, 8, zt),
          v("polygon", {
            points: `${e.value.left + 8},${e.value.centerY - 6} ${e.value.left},${e.value.centerY} ${e.value.left + 8},${e.value.centerY + 6}`,
            fill: t.value.style.chart.layout.grid.stroke,
            stroke: "none"
          }, null, 8, Tt),
          v("polygon", {
            points: `${e.value.centerX - 6},${e.value.top + 8} ${e.value.centerX},${e.value.top} ${e.value.centerX + 6},${e.value.top + 8}`,
            fill: t.value.style.chart.layout.grid.stroke,
            stroke: "none"
          }, null, 8, Wt),
          v("polygon", {
            points: `${e.value.centerX - 6},${e.value.bottom - 8} ${e.value.centerX},${e.value.bottom} ${e.value.centerX + 6},${e.value.bottom - 8}`,
            fill: t.value.style.chart.layout.grid.stroke,
            stroke: "none"
          }, null, 8, Xt)
        ])) : c("", !0),
        t.value.style.chart.layout.labels.quadrantLabels.show && !p.value ? (s(), i("g", Yt, [
          t.value.style.chart.layout.labels.quadrantLabels.tl.text ? (s(), i("text", {
            key: 0,
            x: 0,
            y: e.value.top - e.value.padding / 2,
            "text-anchor": "start",
            fill: t.value.style.chart.layout.labels.quadrantLabels.tl.color,
            "font-size": t.value.style.chart.layout.labels.quadrantLabels.tl.fontSize,
            style: L(`font-weight:${t.value.style.chart.layout.labels.quadrantLabels.tl.bold ? "bold" : ""}`),
            onClick: u[0] || (u[0] = (a) => D("tl"))
          }, x(t.value.style.chart.layout.labels.quadrantLabels.tl.text), 13, Mt)) : c("", !0),
          t.value.style.chart.layout.labels.quadrantLabels.tr.text ? (s(), i("text", {
            key: 1,
            x: e.value.width,
            y: e.value.top - e.value.padding / 2,
            "text-anchor": "end",
            fill: t.value.style.chart.layout.labels.quadrantLabels.tr.color,
            "font-size": t.value.style.chart.layout.labels.quadrantLabels.tr.fontSize,
            style: L(`font-weight:${t.value.style.chart.layout.labels.quadrantLabels.tr.bold ? "bold" : ""}`),
            onClick: u[1] || (u[1] = (a) => D("tr"))
          }, x(t.value.style.chart.layout.labels.quadrantLabels.tr.text), 13, Nt)) : c("", !0),
          t.value.style.chart.layout.labels.quadrantLabels.br.text ? (s(), i("text", {
            key: 2,
            x: e.value.width,
            y: e.value.bottom + e.value.padding * 0.7,
            "text-anchor": "end",
            fill: t.value.style.chart.layout.labels.quadrantLabels.br.color,
            "font-size": t.value.style.chart.layout.labels.quadrantLabels.br.fontSize,
            style: L(`font-weight:${t.value.style.chart.layout.labels.quadrantLabels.br.bold ? "bold" : ""}`),
            onClick: u[2] || (u[2] = (a) => D("br"))
          }, x(t.value.style.chart.layout.labels.quadrantLabels.br.text), 13, At)) : c("", !0),
          t.value.style.chart.layout.labels.quadrantLabels.bl.text ? (s(), i("text", {
            key: 3,
            x: 0,
            y: e.value.bottom + e.value.padding * 0.7,
            "text-anchor": "start",
            fill: t.value.style.chart.layout.labels.quadrantLabels.bl.color,
            "font-size": t.value.style.chart.layout.labels.quadrantLabels.bl.fontSize,
            style: L(`font-weight:${t.value.style.chart.layout.labels.quadrantLabels.bl.bold ? "bold" : ""}`),
            onClick: u[3] || (u[3] = (a) => D("bl"))
          }, x(t.value.style.chart.layout.labels.quadrantLabels.bl.text), 13, Vt)) : c("", !0)
        ])) : c("", !0),
        t.value.style.chart.layout.labels.axisLabels.show ? (s(), i("g", Bt, [
          v("text", {
            x: e.value.centerX,
            y: e.value.top - e.value.padding / 6,
            "text-anchor": "middle",
            "font-size": t.value.style.chart.layout.labels.axisLabels.fontSize,
            fill: t.value.style.chart.layout.labels.axisLabels.color.positive
          }, x(y(A)(
            t.value.style.chart.layout.labels.plotLabels.y.formatter,
            q.value.y.max,
            y(V)({
              v: q.value.y.max,
              r: t.value.style.chart.layout.labels.plotLabels.rounding
            })
          )), 9, Pt),
          v("text", {
            x: e.value.centerX,
            y: e.value.top - e.value.padding / 2,
            "text-anchor": "middle",
            "font-size": t.value.style.chart.layout.labels.axisLabels.fontSize,
            fill: t.value.style.chart.layout.labels.axisLabels.color.positive
          }, x(t.value.style.chart.layout.grid.yAxis.name), 9, Rt),
          v("text", {
            x: e.value.centerX,
            y: e.value.bottom + e.value.padding * 0.35,
            "text-anchor": "middle",
            "font-size": t.value.style.chart.layout.labels.axisLabels.fontSize,
            fill: t.value.style.chart.layout.labels.axisLabels.color.negative
          }, x(y(A)(
            t.value.style.chart.layout.labels.plotLabels.y.formatter,
            q.value.y.min,
            y(V)({
              v: q.value.y.min,
              r: t.value.style.chart.layout.labels.plotLabels.rounding
            })
          )), 9, Ft),
          v("text", {
            id: `xLabelMin_${z.value}`,
            "text-anchor": "middle",
            "font-size": t.value.style.chart.layout.labels.axisLabels.fontSize,
            transform: `translate(${e.value.padding - t.value.style.chart.layout.labels.axisLabels.fontSize}, ${e.value.height / 2}), rotate(-90)`,
            fill: t.value.style.chart.layout.labels.axisLabels.color.negative
          }, x(y(A)(
            t.value.style.chart.layout.labels.plotLabels.x.formatter,
            q.value.x.min,
            y(V)({
              v: q.value.x.min,
              r: t.value.style.chart.layout.labels.plotLabels.rounding
            })
          )), 9, Ht),
          v("text", {
            id: `xLabelMax_${z.value}`,
            "text-anchor": "middle",
            "font-size": t.value.style.chart.layout.labels.axisLabels.fontSize,
            transform: `translate(${e.value.width - e.value.padding + t.value.style.chart.layout.labels.axisLabels.fontSize}, ${e.value.height / 2}), rotate(90)`,
            fill: t.value.style.chart.layout.labels.axisLabels.color.positive
          }, x(y(A)(
            t.value.style.chart.layout.labels.plotLabels.x.formatter,
            q.value.x.max,
            y(V)({
              v: q.value.x.max,
              r: t.value.style.chart.layout.labels.plotLabels.rounding
            })
          )), 9, Ot),
          v("text", {
            id: `xLabelMaxName_${z.value}`,
            "text-anchor": "middle",
            "font-size": t.value.style.chart.layout.labels.axisLabels.fontSize,
            transform: `translate(${e.value.width - t.value.style.chart.layout.labels.axisLabels.fontSize}, ${e.value.height / 2}), rotate(90)`,
            fill: t.value.style.chart.layout.labels.axisLabels.color.positive
          }, x(t.value.style.chart.layout.grid.xAxis.name), 9, It)
        ])) : c("", !0),
        t.value.style.chart.layout.areas.show ? (s(), i("g", Dt, [
          (s(!0), i(S, null, X(C.value, (a, o) => (s(), i("g", null, [
            a.series.length > 2 ? (s(), i("polygon", {
              key: 0,
              "data-cy-quadrant-area": "",
              fill: t.value.style.chart.layout.areas.useGradient ? `url(#quadrant_gradient_${z.value}_${o})` : `${a.color}${y(ae)[t.value.style.chart.layout.areas.opacity]}`,
              points: y(lt)(a)
            }, null, 8, Et)) : c("", !0)
          ]))), 256))
        ])) : c("", !0),
        v("g", null, [
          v("rect", {
            onClick: u[4] || (u[4] = (a) => M("TL")),
            x: e.value.left,
            y: e.value.top,
            width: e.value.usableWidth / 2 <= 0 ? 1e-3 : e.value.usableWidth / 2,
            height: e.value.usableHeight / 2 <= 0 ? 1e-3 : e.value.usableHeight / 2,
            fill: "transparent",
            class: T({ "vue-data-ui-zoom-plus": !p.value, "vue-data-ui-zoom-minus": p.value })
          }, null, 10, Ut),
          v("rect", {
            onClick: u[5] || (u[5] = (a) => M("TR")),
            x: e.value.centerX,
            y: e.value.top,
            width: e.value.usableWidth / 2 <= 0 ? 1e-3 : e.value.usableWidth / 2,
            height: e.value.usableHeight / 2 <= 0 ? 1e-3 : e.value.usableHeight / 2,
            fill: "transparent",
            class: T({ "vue-data-ui-zoom-plus": !p.value, "vue-data-ui-zoom-minus": p.value })
          }, null, 10, Gt),
          v("rect", {
            onClick: u[6] || (u[6] = (a) => M("BR")),
            x: e.value.centerX,
            y: e.value.centerY,
            width: e.value.usableWidth / 2 <= 0 ? 1e-3 : e.value.usableWidth / 2,
            height: e.value.usableHeight / 2 <= 0 ? 1e-3 : e.value.usableHeight / 2,
            fill: "transparent",
            class: T({ "vue-data-ui-zoom-plus": !p.value, "vue-data-ui-zoom-minus": p.value })
          }, null, 10, Qt),
          v("rect", {
            onClick: u[7] || (u[7] = (a) => M("BL")),
            x: e.value.left,
            y: e.value.centerY,
            width: e.value.usableWidth / 2 <= 0 ? 1e-3 : e.value.usableWidth / 2,
            height: e.value.usableHeight / 2 <= 0 ? 1e-3 : e.value.usableHeight / 2,
            fill: "transparent",
            class: T({ "vue-data-ui-zoom-plus": !p.value, "vue-data-ui-zoom-minus": p.value })
          }, null, 10, Jt)
        ]),
        t.value.style.chart.layout.labels.plotLabels.showAsTag ? (s(), i(S, { key: 6 }, [
          w.value.plotLabels.show ? (s(), i("g", Kt, [
            (s(!0), i(S, null, X(C.value, (a, o) => (s(), i(S, null, [
              (s(!0), i(S, null, X(a.series, (r) => (s(), i("foreignObject", {
                style: { overflow: "visible" },
                height: "10",
                width: "100",
                x: r.x - 50,
                y: r.y - t.value.style.chart.layout.labels.plotLabels.fontSize,
                onMouseover: (b) => $e(a, r, o),
                onMouseleave: u[9] || (u[9] = (b) => {
                  Q.value = !1, O.value = null, I.value = null;
                }),
                onClick: (b) => ke(a, r)
              }, [
                v("div", {
                  style: L(`color:${y(at)(a.color)};margin: 0 auto; font-size:${t.value.style.chart.layout.labels.plotLabels.fontSize}px; text-align:center;background:${a.color}; padding: 2px 4px; border-radius: 12px; height: ${t.value.style.chart.layout.labels.plotLabels.fontSize * 1.5}px`)
                }, x(r.name), 5)
              ], 40, el))), 256))
            ], 64))), 256))
          ])) : c("", !0)
        ], 64)) : (s(), i(S, { key: 5 }, [
          (s(!0), i(S, null, X(C.value, (a, o) => (s(), i("g", null, [
            (s(!0), i(S, null, X(a.series, (r) => (s(), U(Te, {
              color: a.color,
              isSelected: O.value && r.uid === O.value,
              plot: r,
              radius: t.value.style.chart.layout.plots.radius / (p.value ? 1.5 : 1),
              shape: a.shape,
              stroke: t.value.style.chart.layout.plots.outline ? t.value.style.chart.layout.plots.outlineColor : "none",
              strokeWidth: t.value.style.chart.layout.plots.outlineWidth,
              onMouseover: (b) => $e(a, r, o),
              onMouseleave: u[8] || (u[8] = (b) => {
                Q.value = !1, O.value = null, I.value = null;
              }),
              onClick: (b) => ke(a, r)
            }, null, 8, ["color", "isSelected", "plot", "radius", "shape", "stroke", "strokeWidth", "onMouseover", "onClick"]))), 256))
          ]))), 256)),
          w.value.plotLabels.show ? (s(), i("g", jt, [
            (s(!0), i(S, null, X(C.value, (a) => (s(), i("g", null, [
              (s(!0), i(S, null, X(a.series, (o) => (s(), i("text", {
                x: o.x,
                y: o.y + t.value.style.chart.layout.labels.plotLabels.offsetY + t.value.style.chart.layout.plots.radius,
                "text-anchor": "middle",
                "font-size": t.value.style.chart.layout.labels.plotLabels.fontSize / (p.value ? 1.5 : 1),
                fill: t.value.style.chart.layout.labels.plotLabels.color
              }, x(o.name), 9, Zt))), 256))
            ]))), 256))
          ])) : c("", !0)
        ], 64)),
        p.value ? (s(), i("g", tl, [
          n.value === "TL" ? (s(), i("polygon", {
            key: 0,
            points: `${e.value.left - 1},${e.value.centerY} ${e.value.centerX},${e.value.centerY} ${e.value.centerX},${e.value.top - 1} ${e.value.right},${e.value.top - 1} ${e.value.right},${e.value.bottom} ${e.value.left - 1},${e.value.bottom} ${e.value.left - 1},${e.value.centerY}`,
            fill: t.value.style.chart.backgroundColor,
            style: { opacity: "1" }
          }, null, 8, ll)) : c("", !0),
          n.value === "TR" ? (s(), i("polygon", {
            key: 1,
            points: `${e.value.left},${e.value.top - 1} ${e.value.centerX},${e.value.top - 1} ${e.value.centerX},${e.value.centerY} ${e.value.right + 1},${e.value.centerY} ${e.value.right + 1},${e.value.bottom} ${e.value.left},${e.value.bottom} ${e.value.left},${e.value.top - 1}`,
            fill: t.value.style.chart.backgroundColor,
            style: { opacity: "1" }
          }, null, 8, al)) : c("", !0),
          n.value === "BR" ? (s(), i("polygon", {
            key: 2,
            points: `${e.value.left},${e.value.top} ${e.value.right + 1},${e.value.top} ${e.value.right + 1},${e.value.centerY} ${e.value.centerX},${e.value.centerY} ${e.value.centerX},${e.value.bottom + 1} ${e.value.left},${e.value.bottom + 1} ${e.value.left},${e.value.top}`,
            fill: t.value.style.chart.backgroundColor,
            style: { opacity: "1" }
          }, null, 8, ul)) : c("", !0),
          n.value === "BL" ? (s(), i("polygon", {
            key: 3,
            points: `${e.value.left - 1},${e.value.top} ${e.value.right},${e.value.top} ${e.value.right},${e.value.bottom + 1} ${e.value.centerX},${e.value.bottom + 1} ${e.value.centerX},${e.value.centerY} ${e.value.left - 1},${e.value.centerY} ${e.value.left - 1},${e.value.top}`,
            fill: t.value.style.chart.backgroundColor,
            style: { opacity: "1" }
          }, null, 8, ol)) : c("", !0)
        ])) : c("", !0),
        n.value && !j.value ? (s(), i("g", sl, [
          v("text", {
            x: B.value.x,
            y: B.value.y - B.value.fontSize / 1.5,
            "font-size": B.value.fontSize / 1.5,
            fill: B.value.fill,
            "text-anchor": "middle",
            "font-weight": B.value.bold ? "bold" : "normal"
          }, x(B.value.text), 9, rl)
        ])) : c("", !0),
        p.value && n.value ? (s(), i("g", il, [
          v("rect", {
            x: $.value[n.value].tl.x,
            y: $.value[n.value].tl.y,
            height: "20",
            width: "20",
            fill: $.value[n.value].tl.fill,
            style: L(`cursor: pointer; opacity: ${n.value === "TL" ? 1 : 0.2}`),
            onClick: u[10] || (u[10] = (a) => M("TL")),
            class: T({ "vue-ui-quadrant-mini-map-cell": !0, "vue-ui-quadrant-mini-map-cell-selectable": n.value !== "TL" })
          }, null, 14, nl),
          v("rect", {
            x: $.value[n.value].tr.x,
            y: $.value[n.value].tr.y,
            height: "20",
            width: "20",
            fill: $.value[n.value].tr.fill,
            style: L(`cursor: pointer; opacity: ${n.value === "TR" ? 1 : 0.2}`),
            onClick: u[11] || (u[11] = (a) => M("TR")),
            class: T({ "vue-ui-quadrant-mini-map-cell": !0, "vue-ui-quadrant-mini-map-cell-selectable": n.value !== "TR" })
          }, null, 14, vl),
          v("rect", {
            x: $.value[n.value].br.x,
            y: $.value[n.value].br.y,
            height: "20",
            width: "20",
            fill: $.value[n.value].br.fill,
            style: L(`cursor: pointer; opacity: ${n.value === "BR" ? 1 : 0.2}`),
            onClick: u[12] || (u[12] = (a) => M("BR")),
            class: T({ "vue-ui-quadrant-mini-map-cell": !0, "vue-ui-quadrant-mini-map-cell-selectable": n.value !== "BR" })
          }, null, 14, dl),
          v("rect", {
            x: $.value[n.value].bl.x,
            y: $.value[n.value].bl.y,
            height: "20",
            width: "20",
            fill: $.value[n.value].bl.fill,
            style: L(`cursor: pointer; opacity: ${n.value === "BL" ? 1 : 0.2}`),
            onClick: u[13] || (u[13] = (a) => M("BL")),
            class: T({ "vue-ui-quadrant-mini-map-cell": !0, "vue-ui-quadrant-mini-map-cell-selectable": n.value !== "BL" })
          }, null, 14, cl),
          v("path", {
            class: "vue-ui-quadrant-minimap-crosshairs",
            stroke: t.value.style.chart.backgroundColor,
            "stroke-width": 1,
            d: $.value[n.value].crosshairs.horizontal
          }, null, 8, hl),
          v("path", {
            class: "vue-ui-quadrant-minimap-crosshairs",
            stroke: t.value.style.chart.backgroundColor,
            "stroke-width": 1,
            d: $.value[n.value].crosshairs.vertical
          }, null, 8, yl)
        ])) : c("", !0),
        _(l.$slots, "svg", { svg: e.value }, void 0, !0)
      ], 14, xt)) : c("", !0),
      l.$slots.watermark ? (s(), i("div", bl, [
        _(l.$slots, "watermark", te(le({ isPrinting: y(ce) || y(he) })), void 0, !0)
      ])) : c("", !0),
      G.value ? c("", !0) : (s(), U(ft, {
        key: 4,
        config: {
          type: "quadrant",
          style: {
            backgroundColor: t.value.style.chart.backgroundColor,
            quadrant: {
              grid: {
                color: t.value.style.chart.layout.grid.stroke
              },
              plots: {
                color: t.value.style.chart.layout.grid.stroke,
                radius: 1
              }
            }
          }
        }
      }, null, 8, ["config"])),
      v("div", {
        ref_key: "chartLegend",
        ref: de
      }, [
        t.value.style.chart.legend.show ? (s(), U(yt, {
          key: 0,
          legendSet: me.value,
          config: Re.value,
          onClickMarker: u[14] || (u[14] = ({ legend: a }) => se(a.id))
        }, {
          item: k(({ legend: a }) => [
            v("div", {
              "data-cy-legend-item": "",
              onClick: (o) => se(a.id),
              style: L(`opacity:${N.value.includes(a.id) ? 0.5 : 1}`)
            }, x(a.name), 13, fl)
          ]),
          _: 1
        }, 8, ["legendSet", "config"])) : _(l.$slots, "legend", {
          key: 1,
          legend: me.value
        }, void 0, !0)
      ], 512),
      ee(ht, {
        show: w.value.showTooltip && Q.value,
        backgroundColor: t.value.style.chart.tooltip.backgroundColor,
        color: t.value.style.chart.tooltip.color,
        borderRadius: t.value.style.chart.tooltip.borderRadius,
        borderColor: t.value.style.chart.tooltip.borderColor,
        borderWidth: t.value.style.chart.tooltip.borderWidth,
        fontSize: t.value.style.chart.tooltip.fontSize,
        backgroundOpacity: t.value.style.chart.tooltip.backgroundOpacity,
        position: t.value.style.chart.tooltip.position,
        offsetY: t.value.style.chart.tooltip.offsetY,
        parent: F.value,
        content: oe.value,
        isCustom: t.value.style.chart.tooltip.customFormat && typeof t.value.style.chart.tooltip.customFormat == "function"
      }, {
        "tooltip-before": k(() => [
          _(l.$slots, "tooltip-before", te(le({ ...re.value })), void 0, !0)
        ]),
        "tooltip-after": k(() => [
          _(l.$slots, "tooltip-after", te(le({ ...re.value })), void 0, !0)
        ]),
        default: k(() => [
          t.value.style.chart.tooltip.showShape ? (s(), i("svg", pl, [
            ee(Te, {
              plot: { x: 10, y: 10 },
              shape: I.value.shape,
              color: I.value.color,
              radius: 8,
              stroke: t.value.style.chart.layout.plots.outline ? t.value.style.chart.layout.plots.outlineColor : "none",
              "stroke-width": t.value.style.chart.layout.plots.outlineWidth
            }, null, 8, ["shape", "color", "stroke", "stroke-width"])
          ])) : c("", !0)
        ]),
        _: 3
      }, 8, ["show", "backgroundColor", "color", "borderRadius", "borderColor", "borderWidth", "fontSize", "backgroundOpacity", "position", "offsetY", "parent", "content", "isCustom"]),
      G.value ? (s(), U(pt, {
        key: 5,
        hideDetails: "",
        config: {
          open: w.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: k(() => [
          ee(bt, {
            colNames: K.value.colNames,
            head: K.value.head,
            body: K.value.body,
            config: K.value.config,
            title: `${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text ? ` : ${t.value.style.chart.title.subtitle.text}` : ""}`,
            onClose: u[15] || (u[15] = (a) => w.value.showTable = !1)
          }, {
            th: k(({ th: a }) => [
              Ee(x(a), 1)
            ]),
            td: k(({ td: a }) => [
              v("div", {
                innerHTML: a.name || a
              }, null, 8, gl)
            ]),
            _: 1
          }, 8, ["colNames", "head", "body", "config", "title"])
        ]),
        _: 1
      }, 8, ["config"])) : c("", !0)
    ], 14, mt));
  }
}, Yl = /* @__PURE__ */ gt(ml, [["__scopeId", "data-v-7c808761"]]);
export {
  Yl as default
};
