vue-data-ui 3.0.15 → 3.0.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{Arrow-DGSYU08F.js → Arrow-2m4QUjO1.js} +1 -1
- package/dist/{BaseDraggableDialog-C8qz7ExB.js → BaseDraggableDialog-B9_MqiHf.js} +2 -2
- package/dist/{BaseIcon-BA3j_Lwf.js → BaseIcon-Bft3p4YZ.js} +1 -1
- package/dist/{ColorPicker-sW0pMaCb.js → ColorPicker-CFmP2-kT.js} +2 -2
- package/dist/{DataTable-Co-fVzdq.js → DataTable-B8bUYWje.js} +2 -2
- package/dist/{Legend-NBffBBnn.js → Legend-BC_Vfqu2.js} +2 -2
- package/dist/{NonSvgPenAndPaper-CWsUFLND.js → NonSvgPenAndPaper-DBqeprd5.js} +3 -3
- package/dist/{PackageVersion-DkN4tXY6.js → PackageVersion-_w0xowp7.js} +1 -1
- package/dist/{PenAndPaper-C5tGS7J9.js → PenAndPaper-po3CVKgg.js} +3 -3
- package/dist/{Shape-Bgg7Nwsz.js → Shape-DjoPWWXB.js} +1 -1
- package/dist/{Slicer-DzsOD_6h.js → Slicer-DiY7teI5.js} +2 -2
- package/dist/{SparkTooltip-Cfx3n0pP.js → SparkTooltip-Bmi9DZjU.js} +1 -1
- package/dist/{Title-Cdu-aDOL.js → Title-BPJFXPqj.js} +1 -1
- package/dist/{Tooltip-mB2Rs1Vj.js → Tooltip-D3UP_KRp.js} +1 -1
- package/dist/{UserOptions-BMoiHEKE.js → UserOptions-DdYkyse5.js} +2 -2
- package/dist/{dom-to-png-DzfS79Op.js → dom-to-png-DtiwYxUm.js} +1 -1
- package/dist/{img-7sjXtnNU.js → img-BcDuLrCf.js} +1 -1
- package/dist/{index-CjmWQAkv.js → index-B4_21v5Q.js} +1 -1
- package/dist/{pdf-BepSOa2A.js → pdf-f1KdvFCG.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/useAutoSizeLabelsInsideViewbox-JloznL_Z.js +55 -0
- package/dist/{useNestedProp-DFYUwW_F.js → useNestedProp-QY6GAO56.js} +1 -1
- package/dist/{usePrinter-BD_X6xEq.js → usePrinter-DXg-TLno.js} +2 -2
- package/dist/{vue-data-ui-BHC_kJCP.js → vue-data-ui-C1lQq89L.js} +64 -64
- package/dist/vue-data-ui.js +1 -1
- package/dist/{vue-ui-3d-bar-CvM_pNPs.js → vue-ui-3d-bar-GPa0n1Na.js} +6 -6
- package/dist/{vue-ui-accordion-BOmbEAe4.js → vue-ui-accordion-Cm0GFoyO.js} +3 -3
- package/dist/{vue-ui-age-pyramid-2GEKVOIu.js → vue-ui-age-pyramid-BiuqFUjQ.js} +6 -6
- package/dist/{vue-ui-annotator-ULK7i_cb.js → vue-ui-annotator-Cu77nEsg.js} +2 -2
- package/dist/{vue-ui-bullet-CtrrTkUl.js → vue-ui-bullet-DCZRTMF3.js} +7 -7
- package/dist/{vue-ui-candlestick-C8_qIKhP.js → vue-ui-candlestick-CK4ZQCoS.js} +7 -7
- package/dist/{vue-ui-carousel-table-C5-I9TDG.js → vue-ui-carousel-table-BMX069tk.js} +4 -4
- package/dist/{vue-ui-chestnut-DbGjz6NE.js → vue-ui-chestnut-CumQ_OwM.js} +5 -5
- package/dist/{vue-ui-chord-DSav5VH4.js → vue-ui-chord-CnDAQRox.js} +8 -8
- package/dist/{vue-ui-circle-pack-Ost-SfPy.js → vue-ui-circle-pack-LRUvETqv.js} +6 -6
- package/dist/{vue-ui-cursor-CvvBIdhO.js → vue-ui-cursor-5ejzpcwi.js} +2 -2
- package/dist/{vue-ui-dashboard-B6jTz1V8.js → vue-ui-dashboard-BMXkQUPo.js} +62 -62
- package/dist/{vue-ui-digits-DW4j5hMp.js → vue-ui-digits-BE5qaKSD.js} +2 -2
- package/dist/{vue-ui-donut-evolution-3Kg_0Aq8.js → vue-ui-donut-evolution-GwETb89E.js} +8 -8
- package/dist/{vue-ui-donut-CQgVEHBd.js → vue-ui-donut-ijFJJJN-.js} +8 -8
- package/dist/{vue-ui-dumbbell-B0RA0uh4.js → vue-ui-dumbbell-BfWcfzf1.js} +7 -7
- package/dist/{vue-ui-flow-mfN9qv9u.js → vue-ui-flow-CnWmfjCg.js} +7 -7
- package/dist/{vue-ui-funnel-By1EE6eQ.js → vue-ui-funnel-pbjhIRxa.js} +6 -6
- package/dist/{vue-ui-galaxy-DUnLy7nU.js → vue-ui-galaxy-BwJQATqg.js} +5 -5
- package/dist/{vue-ui-gauge-B9s5assa.js → vue-ui-gauge-Db1kBMB5.js} +7 -7
- package/dist/{vue-ui-gizmo-D5nFPB5S.js → vue-ui-gizmo-B2MK3kNu.js} +3 -3
- package/dist/{vue-ui-heatmap-B99sMjxs.js → vue-ui-heatmap-DzosM9FC.js} +7 -7
- package/dist/{vue-ui-history-plot-BcnKJSTL.js → vue-ui-history-plot-DjsbhNge.js} +7 -7
- package/dist/{vue-ui-kpi-BoiQMCdn.js → vue-ui-kpi-DsjqKIk3.js} +3 -3
- package/dist/{vue-ui-mini-loader-Fd0upr6u.js → vue-ui-mini-loader-V95wKdrX.js} +2 -2
- package/dist/{vue-ui-molecule-C8U7G10y.js → vue-ui-molecule-fWZehftJ.js} +5 -5
- package/dist/{vue-ui-mood-radar-83Su_aAf.js → vue-ui-mood-radar-Be7_3zk-.js} +7 -7
- package/dist/{vue-ui-nested-donuts-BT9ZqiqC.js → vue-ui-nested-donuts-BZVwjwbV.js} +7 -7
- package/dist/{vue-ui-onion-9JIdWtsY.js → vue-ui-onion-D5xI6lqf.js} +8 -8
- package/dist/{vue-ui-parallel-coordinate-plot-C1FjeIr0.js → vue-ui-parallel-coordinate-plot-lvN8TJoP.js} +8 -8
- package/dist/{vue-ui-quadrant-3WUBK3nJ.js → vue-ui-quadrant-oIj8WgFV.js} +8 -8
- package/dist/{vue-ui-quick-chart-DY43gV8A.js → vue-ui-quick-chart-D3W1R-rS.js} +6 -6
- package/dist/{vue-ui-radar-C4KMiQ_0.js → vue-ui-radar-U0-KtuOL.js} +8 -8
- package/dist/{vue-ui-rating-BvD7AC9t.js → vue-ui-rating-zZ7S-F3M.js} +2 -2
- package/dist/{vue-ui-relation-circle-CkJugcvo.js → vue-ui-relation-circle-ClVYiLT0.js} +203 -194
- package/dist/{vue-ui-ridgeline-BWWwyiku.js → vue-ui-ridgeline-B5asZPEM.js} +8 -8
- package/dist/{vue-ui-rings--RHm1WPt.js → vue-ui-rings-BC7C9Ddv.js} +8 -8
- package/dist/{vue-ui-scatter-BlJi3Vto.js → vue-ui-scatter-BkeeijYJ.js} +8 -8
- package/dist/{vue-ui-skeleton-BpaC2poA.js → vue-ui-skeleton-AR0HdHtM.js} +3 -3
- package/dist/{vue-ui-smiley-DFQ-eGPr.js → vue-ui-smiley-rQvdkrPe.js} +2 -2
- package/dist/{vue-ui-spark-trend-DBvs77p7.js → vue-ui-spark-trend-DSVR33oG.js} +3 -3
- package/dist/{vue-ui-sparkbar-5-xCacnj.js → vue-ui-sparkbar-CKZXbK1C.js} +3 -3
- package/dist/{vue-ui-sparkgauge-B_Hahm_m.js → vue-ui-sparkgauge-EwpOnFEG.js} +3 -3
- package/dist/{vue-ui-sparkhistogram-CE3o-lRl.js → vue-ui-sparkhistogram-BBx8FdxL.js} +4 -4
- package/dist/{vue-ui-sparkline-RzY__SHu.js → vue-ui-sparkline-CTNKMXdK.js} +3 -3
- package/dist/{vue-ui-sparkstackbar-mf1_NIVO.js → vue-ui-sparkstackbar-C9_ZJC6R.js} +3 -3
- package/dist/{vue-ui-stackbar-e0_-TwRA.js → vue-ui-stackbar-DEGEn2og.js} +9 -9
- package/dist/{vue-ui-strip-plot-DNF_a6tQ.js → vue-ui-strip-plot-D7zJ6Gxu.js} +7 -7
- package/dist/{vue-ui-table-DyRQD9Jx.js → vue-ui-table-BufIOIej.js} +3 -3
- package/dist/{vue-ui-table-heatmap-D0khMn8L.js → vue-ui-table-heatmap-CWWF6Z0K.js} +5 -5
- package/dist/{vue-ui-table-sparkline-CrEJ_BYI.js → vue-ui-table-sparkline-B7-kRYU6.js} +4 -4
- package/dist/{vue-ui-thermometer-WWlRC1pG.js → vue-ui-thermometer-BeaRRFu9.js} +7 -7
- package/dist/{vue-ui-timer-DFrFvU8Z.js → vue-ui-timer-Cu1ZPPkY.js} +5 -5
- package/dist/{vue-ui-tiremarks-BcGXDBHM.js → vue-ui-tiremarks-CxBGQKpR.js} +6 -6
- package/dist/{vue-ui-treemap-CISOrlRD.js → vue-ui-treemap-Dqy78tXh.js} +8 -8
- package/dist/{vue-ui-vertical-bar-BIGQJhXk.js → vue-ui-vertical-bar-lkihrVqN.js} +9 -9
- package/dist/{vue-ui-waffle-ZR7fefhR.js → vue-ui-waffle-CcvE03gZ.js} +8 -8
- package/dist/{vue-ui-wheel-DRp9k9JL.js → vue-ui-wheel-BOpUQEYr.js} +6 -6
- package/dist/{vue-ui-word-cloud-jlqVnKu7.js → vue-ui-word-cloud-CM90pBoN.js} +6 -6
- package/dist/{vue-ui-world-PWs6PTyh.js → vue-ui-world-dogTux1Y.js} +6 -6
- package/dist/{vue-ui-xy-D9GnZXb-.js → vue-ui-xy-BKPfZiSg.js} +9 -9
- package/dist/{vue-ui-xy-canvas-JxDjG7z8.js → vue-ui-xy-canvas-2abeQ6mF.js} +8 -8
- package/package.json +1 -1
- package/dist/useAutoSizeLabelsInsideViewbox-iRzr0rIq.js +0 -81
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { useCssVars as wo, computed as x, ref as b, onMounted as ol, onBeforeUnmount as nl, watch as dt, nextTick as Yt, onUpdated as So, createElementBlock as r, openBlock as u, createElementVNode as p, createCommentVNode as f, renderSlot as J, normalizeStyle as L, createVNode as al, withDirectives as Ql, unref as v, Fragment as g, renderList as C, normalizeClass as Ve, withKeys as Fa, vModelText as Ha, toDisplayString as le, defineAsyncComponent as Mt, useSlots as _o, getCurrentInstance as $o, toRefs as Lo, watchEffect as Va, createBlock as Ge, createSlots as Mo, withCtx as xe, normalizeProps as Ct, guardReactiveProps as At, mergeProps as Tl, Teleport as Co, vModelCheckbox as Ao, createTextVNode as zo } from "vue";
|
|
2
|
-
import { c as Pl, V as Fl, U as Hl, y as Ol, X as To, F as tt, u as Io, f as Kl, t as No, a4 as je, d as Ro, D as yl, ac as Dt, e as Po, p as Oo, ad as Il, a9 as Y, ae as Fo, h as V, af as Ba, ag as Ea, ah as Ho, ai as Wa, aj as Da, k as Se, ak as Vo, z as Bo, _ as Xa, R as vt, i as Ue, x as Xt, s as et, a7 as j, L as Eo, al as Nl, I as Wo, am as zt, C as qe, a as Do, b as Xo, o as Ya, v as Yo, w as Go, E as ll } from "./index-
|
|
2
|
+
import { c as Pl, V as Fl, U as Hl, y as Ol, X as To, F as tt, u as Io, f as Kl, t as No, a4 as je, d as Ro, D as yl, ac as Dt, e as Po, p as Oo, ad as Il, a9 as Y, ae as Fo, h as V, af as Ba, ag as Ea, ah as Ho, ai as Wa, aj as Da, k as Se, ak as Vo, z as Bo, _ as Xa, R as vt, i as Ue, x as Xt, s as et, a7 as j, L as Eo, al as Nl, I as Wo, am as zt, C as qe, a as Do, b as Xo, o as Ya, v as Yo, w as Go, E as ll } from "./index-B4_21v5Q.js";
|
|
3
3
|
import { t as jl, u as Uo } from "./useResponsive-DfdjqQps.js";
|
|
4
|
-
import { u as qo } from "./usePrinter-
|
|
4
|
+
import { u as qo } from "./usePrinter-DXg-TLno.js";
|
|
5
5
|
import { u as Zo, B as Ko } from "./useLoading-D7YHNtLX.js";
|
|
6
|
-
import { u as Jl } from "./useNestedProp-
|
|
6
|
+
import { u as Jl } from "./useNestedProp-QY6GAO56.js";
|
|
7
7
|
import { u as Ga, a as Jo, l as Qo } from "./useTimeLabels-4la0yDx0.js";
|
|
8
8
|
import { u as jo } from "./useTimeLabelCollider-CIsgDrl9.js";
|
|
9
|
-
import en from "./img-
|
|
10
|
-
import tn from "./Title-
|
|
11
|
-
import { S as ln } from "./Slicer-
|
|
12
|
-
import { _ as Rl } from "./Shape-
|
|
13
|
-
import an from "./BaseIcon-
|
|
9
|
+
import en from "./img-BcDuLrCf.js";
|
|
10
|
+
import tn from "./Title-BPJFXPqj.js";
|
|
11
|
+
import { S as ln } from "./Slicer-DiY7teI5.js";
|
|
12
|
+
import { _ as Rl } from "./Shape-DjoPWWXB.js";
|
|
13
|
+
import an from "./BaseIcon-Bft3p4YZ.js";
|
|
14
14
|
import { _ as Ua } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
15
15
|
const on = {
|
|
16
16
|
class: "vue-data-ui-slicer-labels",
|
|
@@ -768,7 +768,7 @@ const on = {
|
|
|
768
768
|
},
|
|
769
769
|
emits: ["selectTimeLabel", "selectX", "selectLegend"],
|
|
770
770
|
setup(R, { expose: Vl, emit: Bl }) {
|
|
771
|
-
const d = R, Be = Mt(() => import("./DataTable-
|
|
771
|
+
const d = R, Be = Mt(() => import("./DataTable-B8bUYWje.js")), ie = Mt(() => import("./Tooltip-D3UP_KRp.js")), re = Mt(() => import("./UserOptions-DdYkyse5.js")), Tt = Mt(() => import("./BaseIcon-Bft3p4YZ.js")), ul = Mt(() => import("./vue-ui-table-sparkline-B7-kRYU6.js")), Gt = Mt(() => import("./vue-ui-accordion-Cm0GFoyO.js")), Ut = Mt(() => import("./PackageVersion-_w0xowp7.js")), yt = Mt(() => import("./PenAndPaper-po3CVKgg.js")), lt = Bl, sl = _o(), Ze = $o(), { vue_ui_xy: il } = Io(), me = b(null), be = b(null), Ne = b(null), at = b(null), It = b(null), Nt = b(null), El = b(null), Ee = b(null), qt = b(null), ht = b(null), Rt = b(null), q = b(null), ot = b(null), Zt = b(0), P = b(null), rl = b(!0), ge = b(600), ae = b(1e3), nt = b("0 0 1000 600"), Pt = b({ x: 0, y: 0 }), oe = b({ line: "line", bar: "bar", plot: "plot" }), pe = b(!1), ye = b(!1), ft = b(!1), mt = b(null), ce = b([]), G = b(Pl()), Kt = b(0), cl = b(0), vl = b(0), kt = b(!0), Ot = b(0), F = b(null), Jt = b(!1), dl = b(!0), Qt = b(!0), _e = b(null), We = b({}), Re = b(null), Ke = b(!1), _ = b(null), ut = x(() => ({
|
|
772
772
|
height: ge.value,
|
|
773
773
|
width: ae.value
|
|
774
774
|
}));
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { defineAsyncComponent as ee, ref as d, computed as L, useSlots as Ga, onMounted as sa, watch as N, nextTick as na, shallowRef as ze, onBeforeUnmount as Za, createElementBlock as ie, openBlock as S, unref as p, normalizeClass as ja, normalizeStyle as ae, createCommentVNode as H, createElementVNode as B, createBlock as R, createSlots as qa, withCtx as x, renderSlot as k, normalizeProps as V, guardReactiveProps as G, createVNode as Ja, Teleport as Ka, toDisplayString as ia, createTextVNode as Qa } from "vue";
|
|
2
|
-
import { u as el, c as al, a as ll, p as Z, b as tl, C as pe, d as ol, D as $e, k as le, i as te, e as va, a4 as rl, G as ul, ae as sl, o as nl, f as il, y as ca, v as vl, w as cl, z as dl, s as ve, l as hl } from "./index-
|
|
2
|
+
import { u as el, c as al, a as ll, p as Z, b as tl, C as pe, d as ol, D as $e, k as le, i as te, e as va, a4 as rl, G as ul, ae as sl, o as nl, f as il, y as ca, v as vl, w as cl, z as dl, s as ve, l as hl } from "./index-B4_21v5Q.js";
|
|
3
3
|
import { d as yl, t as fl, u as gl, c as pl, a as da, l as C, r as Ie, b as P, p as ha } from "./useResponsive-DfdjqQps.js";
|
|
4
|
-
import { u as ya } from "./useNestedProp-
|
|
5
|
-
import { u as ml } from "./usePrinter-
|
|
4
|
+
import { u as ya } from "./useNestedProp-QY6GAO56.js";
|
|
5
|
+
import { u as ml } from "./usePrinter-DXg-TLno.js";
|
|
6
6
|
import { u as bl } from "./useUserOptionState-BIvW1Kz7.js";
|
|
7
7
|
import { u as xl } from "./useChartAccessibility-9icAAmYg.js";
|
|
8
|
-
import Ll from "./Legend-
|
|
9
|
-
import kl from "./Title-
|
|
10
|
-
import { S as Cl } from "./Slicer-
|
|
8
|
+
import Ll from "./Legend-BC_Vfqu2.js";
|
|
9
|
+
import kl from "./Title-BPJFXPqj.js";
|
|
10
|
+
import { S as Cl } from "./Slicer-DiY7teI5.js";
|
|
11
11
|
import { u as wl } from "./useTimeLabels-4la0yDx0.js";
|
|
12
|
-
import Sl from "./img-
|
|
12
|
+
import Sl from "./img-BcDuLrCf.js";
|
|
13
13
|
import { _ as zl } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
14
14
|
const $l = ["id"], Il = ["id"], Ml = ["id"], Tl = ["onClick"], Ol = {
|
|
15
15
|
key: 3,
|
|
@@ -32,7 +32,7 @@ const $l = ["id"], Il = ["id"], Ml = ["id"], Tl = ["onClick"], Ol = {
|
|
|
32
32
|
},
|
|
33
33
|
emits: ["selectLegend"],
|
|
34
34
|
setup(Me, { expose: fa, emit: ga }) {
|
|
35
|
-
const pa = ee(() => import("./vue-ui-accordion-
|
|
35
|
+
const pa = ee(() => import("./vue-ui-accordion-Cm0GFoyO.js")), ma = ee(() => import("./DataTable-B8bUYWje.js")), ba = ee(() => import("./NonSvgPenAndPaper-DBqeprd5.js")), xa = ee(() => import("./vue-ui-skeleton-AR0HdHtM.js")), La = ee(() => import("./Tooltip-D3UP_KRp.js")), ka = ee(() => import("./UserOptions-DdYkyse5.js")), { vue_ui_xy_canvas: Ca } = el(), g = Me, Y = d(al()), F = d(null), oe = d(null), n = d(null), y = d(1), E = d(1), ce = d(!1), c = d(null), de = d(""), Te = d(null), $ = d([]), j = d(1), _ = d(!0), q = d(!0), me = d(null), Oe = d(0), Re = d(0), he = d(!1), Pe = d(null), Fe = d(null), Ee = d(null), Ae = d(null), be = d(0), xe = d(0), Le = d(0), M = d(null), De = d(!1), ke = L(() => !!g.dataset && g.dataset.length), wa = ga, Sa = Ga();
|
|
36
36
|
sa(() => {
|
|
37
37
|
Sa["chart-background"] && console.warn("VueUiXyCanvas does not support the #chart-background slot.");
|
|
38
38
|
});
|
package/package.json
CHANGED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
import { a1 as K } from "./index-CjmWQAkv.js";
|
|
2
|
-
function q({
|
|
3
|
-
svgRef: S,
|
|
4
|
-
fontSize: A,
|
|
5
|
-
minFontSize: z,
|
|
6
|
-
sizeRef: b,
|
|
7
|
-
labelClass: B,
|
|
8
|
-
labelTypes: m = []
|
|
9
|
-
}) {
|
|
10
|
-
let y = null;
|
|
11
|
-
function g(e) {
|
|
12
|
-
let n = e[0];
|
|
13
|
-
for (let t = 1; t < e.length; t += 1) e[t] < n && (n = e[t]);
|
|
14
|
-
return n;
|
|
15
|
-
}
|
|
16
|
-
function w(e) {
|
|
17
|
-
let n = e[0];
|
|
18
|
-
for (let t = 1; t < e.length; t += 1) e[t] > n && (n = e[t]);
|
|
19
|
-
return n;
|
|
20
|
-
}
|
|
21
|
-
function F(e) {
|
|
22
|
-
const n = e.ownerSVGElement;
|
|
23
|
-
if (!n) return { x: 0, y: 0, width: 0, height: 0 };
|
|
24
|
-
const t = e.getBBox(), o = e.getCTM(), s = [
|
|
25
|
-
{ x: t.x, y: t.y },
|
|
26
|
-
{ x: t.x + t.width, y: t.y },
|
|
27
|
-
{ x: t.x, y: t.y + t.height },
|
|
28
|
-
{ x: t.x + t.width, y: t.y + t.height }
|
|
29
|
-
].map((c) => {
|
|
30
|
-
const a = n.createSVGPoint();
|
|
31
|
-
a.x = c.x, a.y = c.y;
|
|
32
|
-
const l = o ? a.matrixTransform(o) : a;
|
|
33
|
-
return { x: l.x, y: l.y };
|
|
34
|
-
}), u = s.map((c) => c.x), r = s.map((c) => c.y), i = g(u), h = w(u), f = g(r), x = w(r);
|
|
35
|
-
return { x: i, y: f, width: h - i, height: x - f };
|
|
36
|
-
}
|
|
37
|
-
function O(e, n, t = 1) {
|
|
38
|
-
const { x: o, y: s, width: u, height: r } = F(e), i = o >= n.x + t, h = o + u <= n.x + n.width - t, f = s >= n.y + t, x = s + r <= n.y + n.height - t;
|
|
39
|
-
return i && h && f && x;
|
|
40
|
-
}
|
|
41
|
-
function d(e, n, t, o, s = 120, u = 1) {
|
|
42
|
-
let r = t, i = 0;
|
|
43
|
-
for (; i < s && (e.setAttribute("font-size", r), !(O(e, n, u) || r <= o)); )
|
|
44
|
-
r -= 0.5, i += 1;
|
|
45
|
-
return r < o ? o : r;
|
|
46
|
-
}
|
|
47
|
-
function p() {
|
|
48
|
-
const e = S.value;
|
|
49
|
-
if (!e) return;
|
|
50
|
-
const [n, t, o, s] = e.getAttribute("viewBox").split(" ").map(Number), u = { x: n, y: t, width: o, height: s };
|
|
51
|
-
m.length || (m = [
|
|
52
|
-
{
|
|
53
|
-
selector: B,
|
|
54
|
-
baseSize: A,
|
|
55
|
-
minSize: z,
|
|
56
|
-
sizeRef: b
|
|
57
|
-
}
|
|
58
|
-
]), m.map((i) => e.querySelectorAll(i.selector).length).reduce((i, h) => i + h, 0) !== 0 && m.forEach(({ selector: i, baseSize: h, minSize: f, sizeRef: x }) => {
|
|
59
|
-
e.querySelectorAll(i).forEach((c) => {
|
|
60
|
-
const a = K({
|
|
61
|
-
el: c,
|
|
62
|
-
bounds: u,
|
|
63
|
-
currentFontSize: h,
|
|
64
|
-
minFontSize: f,
|
|
65
|
-
attempts: 200,
|
|
66
|
-
padding: 1
|
|
67
|
-
}), l = d(c, u, a, f, 120, 1);
|
|
68
|
-
c.setAttribute("font-size", l), x.value = l;
|
|
69
|
-
});
|
|
70
|
-
});
|
|
71
|
-
}
|
|
72
|
-
function v() {
|
|
73
|
-
y && cancelAnimationFrame(y), y = requestAnimationFrame(() => {
|
|
74
|
-
y = null, p();
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
return { autoSizeLabels: v };
|
|
78
|
-
}
|
|
79
|
-
export {
|
|
80
|
-
q as u
|
|
81
|
-
};
|