@mobileaction/action-kit 1.57.0 → 1.57.1

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.
@@ -0,0 +1,227 @@
1
+ import { g as Ct } from "./index-bTz35Vhl.js";
2
+ function _t(W, R) {
3
+ for (var X = 0; X < R.length; X++) {
4
+ const F = R[X];
5
+ if (typeof F != "string" && !Array.isArray(F)) {
6
+ for (const Y in F)
7
+ if (Y !== "default" && !(Y in W)) {
8
+ const _ = Object.getOwnPropertyDescriptor(F, Y);
9
+ _ && Object.defineProperty(W, Y, _.get ? _ : {
10
+ enumerable: !0,
11
+ get: () => F[Y]
12
+ });
13
+ }
14
+ }
15
+ }
16
+ return Object.freeze(Object.defineProperty(W, Symbol.toStringTag, { value: "Module" }));
17
+ }
18
+ var B = { exports: {} }, Dt = B.exports, nt;
19
+ function Wt() {
20
+ return nt || (nt = 1, function(W, R) {
21
+ /**
22
+ * Highcharts JS v12.5.0 (2026-01-12)
23
+ * @module highcharts/modules/wordcloud
24
+ * @requires highcharts
25
+ *
26
+ * (c) 2016-2026 Highsoft AS
27
+ * Authors: Jon Arild Nygard
28
+ *
29
+ * A commercial license may be required depending on use.
30
+ * See www.highcharts.com/license
31
+ */
32
+ (function(X, F) {
33
+ W.exports = F(X._Highcharts, X._Highcharts.SeriesRegistry);
34
+ })("u" < typeof window ? Dt : window, (X, F) => (() => {
35
+ var Y = { 512: (t) => {
36
+ t.exports = F;
37
+ }, 944: (t) => {
38
+ t.exports = X;
39
+ } }, _ = {};
40
+ function b(t) {
41
+ var e = _[t];
42
+ if (e !== void 0) return e.exports;
43
+ var o = _[t] = { exports: {} };
44
+ return Y[t](o, o.exports, b), o.exports;
45
+ }
46
+ b.n = (t) => {
47
+ var e = t && t.__esModule ? () => t.default : () => t;
48
+ return b.d(e, { a: e }), e;
49
+ }, b.d = (t, e) => {
50
+ for (var o in e) b.o(e, o) && !b.o(t, o) && Object.defineProperty(t, o, { enumerable: !0, get: e[o] });
51
+ }, b.o = (t, e) => Object.prototype.hasOwnProperty.call(t, e);
52
+ var k = {};
53
+ b.d(k, { default: () => Yt });
54
+ var st = b(944), C = b.n(st);
55
+ let ht = function(t, e) {
56
+ let { animatableAttribs: o, onComplete: i, css: r, renderer: n } = e, a = t.series && t.series.chart.hasRendered ? void 0 : t.series && t.series.options.animation, l = t.graphic;
57
+ if (e.attribs = { ...e.attribs, class: t.getClassName() }, t.shouldDraw()) l || (t.graphic = l = n.text(), l.add(e.group)), r && l.css(r), l.attr(e.attribs).animate(o, !e.isNew && a, i);
58
+ else if (l) {
59
+ let m = () => {
60
+ t.graphic = l = l && l.destroy(), typeof i == "function" && i();
61
+ };
62
+ Object.keys(o).length ? l.animate(o, void 0, () => m()) : m();
63
+ }
64
+ };
65
+ var dt = b(512), E = b.n(dt);
66
+ let { column: { prototype: { pointClass: ut } } } = E().seriesTypes, { extend: pt } = C();
67
+ class U extends ut {
68
+ isValid() {
69
+ return !0;
70
+ }
71
+ }
72
+ pt(U.prototype, { weight: 1 });
73
+ let { deg2rad: ct } = C(), { extend: gt, find: q, isNumber: v, isObject: H, merge: ft } = C();
74
+ function mt(t, e) {
75
+ return !(e.left > t.right || e.right < t.left || e.top > t.bottom || e.bottom < t.top);
76
+ }
77
+ function $(t) {
78
+ let e = t.axes || [];
79
+ return e.length || (e = [], t.concat([t[0]]).reduce((o, i) => {
80
+ let r, n, a = (r = i[0] - o[0], [[-(n = i[1] - o[1]), r], [n, -r]])[0];
81
+ return q(e, (l) => l[0] === a[0] && l[1] === a[1]) || e.push(a), i;
82
+ }), t.axes = e), e;
83
+ }
84
+ function I(t, e) {
85
+ let o = t.map((i) => {
86
+ let r = i[0], n = i[1];
87
+ return r * e[0] + n * e[1];
88
+ });
89
+ return { min: Math.min.apply(this, o), max: Math.max.apply(this, o) };
90
+ }
91
+ function G(t, e) {
92
+ let o = $(t), i = $(e);
93
+ return !q(o.concat(i), (r) => {
94
+ let n, a;
95
+ return n = I(t, r), (a = I(e, r)).min > n.max || a.max < n.min;
96
+ });
97
+ }
98
+ function J(t, e) {
99
+ let o = 4 * t, i = Math.ceil((Math.sqrt(o) - 1) / 2), r = 2 * i + 1, n = Math.pow(r, 2), a = !1;
100
+ return r -= 1, t <= 1e4 && (typeof a == "boolean" && o >= n - r && (a = { x: i - (n - o), y: -i }), n -= r, typeof a == "boolean" && o >= n - r && (a = { x: -i, y: -i + (n - o) }), n -= r, typeof a == "boolean" && (a = o >= n - r ? { x: -i + (n - o), y: i } : { x: i, y: i - (n - o - r) }), a.x *= 5, a.y *= 5), a;
101
+ }
102
+ function K(t, e) {
103
+ let o = Math.pow(10, v(e) ? e : 14);
104
+ return Math.round(t * o) / o;
105
+ }
106
+ function Q(t, e) {
107
+ let o = t[0], i = t[1], r = -(ct * e), n = Math.cos(r), a = Math.sin(r);
108
+ return [K(o * n - i * a), K(o * a + i * n)];
109
+ }
110
+ function Z(t, e, o) {
111
+ let i = Q([t[0] - e[0], t[1] - e[1]], o);
112
+ return [i[0] + e[0], i[1] + e[1]];
113
+ }
114
+ let { noop: N } = C(), { column: tt } = E().seriesTypes, { extend: j, isArray: xt, isNumber: D, isObject: et, merge: yt } = C(), { archimedeanSpiral: bt, extendPlayingField: ot, getBoundingBoxFromPolygon: Mt, getPlayingField: wt, getPolygon: St, getRandomPosition: it, getRotation: L, getScale: Pt, getSpiral: Ft, intersectionTesting: rt, isPolygonsColliding: vt, rectangularSpiral: At, rotate2DToOrigin: Xt, rotate2DToPoint: zt, squareSpiral: Ot, updateFieldBoundaries: Tt } = { archimedeanSpiral: function(t, e) {
115
+ let o = e.field, i = o.width * o.width + o.height * o.height, r = 0.8 * t, n = !1;
116
+ return t <= 1e4 && (Math.min(Math.abs((n = { x: r * Math.cos(r), y: r * Math.sin(r) }).x), Math.abs(n.y)) < i || (n = !1)), n;
117
+ }, extendPlayingField: function(t, e) {
118
+ let o, i, r, n, a, l;
119
+ return H(t) && H(e) ? (o = e.bottom - e.top, i = e.right - e.left, a = i * (r = t.ratioX) > o * (n = t.ratioY) ? i : o, l = ft(t, { width: t.width + a * r * 2, height: t.height + a * n * 2 })) : l = t, l;
120
+ }, getBoundingBoxFromPolygon: function(t) {
121
+ return t.reduce(function(e, o) {
122
+ let i = o[0], r = o[1];
123
+ return e.left = Math.min(i, e.left), e.right = Math.max(i, e.right), e.bottom = Math.max(r, e.bottom), e.top = Math.min(r, e.top), e;
124
+ }, { left: Number.MAX_VALUE, right: -Number.MAX_VALUE, bottom: -Number.MAX_VALUE, top: Number.MAX_VALUE });
125
+ }, getPlayingField: function(t, e, o) {
126
+ let i = o.reduce(function(l, m) {
127
+ let u = m.dimensions, d = Math.max(u.width, u.height);
128
+ return l.maxHeight = Math.max(l.maxHeight, u.height), l.maxWidth = Math.max(l.maxWidth, u.width), l.area += d * d, l;
129
+ }, { maxHeight: 0, maxWidth: 0, area: 0 }), r = Math.max(i.maxHeight, i.maxWidth, 0.85 * Math.sqrt(i.area)), n = t > e ? t / e : 1, a = e > t ? e / t : 1;
130
+ return { width: r * n, height: r * a, ratioX: n, ratioY: a };
131
+ }, getPolygon: function(t, e, o, i, r) {
132
+ let n = [t, e], a = t - o / 2, l = t + o / 2, m = e - i / 2, u = e + i / 2;
133
+ return [[a, m], [l, m], [l, u], [a, u]].map(function(d) {
134
+ return Z(d, n, -r);
135
+ });
136
+ }, getRandomPosition: function(t) {
137
+ return Math.round(t * (Math.random() + 0.5) / 2);
138
+ }, getRotation: function(t, e, o, i) {
139
+ let r = !1, n;
140
+ return v(t) && v(e) && v(o) && v(i) && t > 0 && e > -1 && i > o && (n = (i - o) / (t - 1 || 1), r = o + e % t * n), r;
141
+ }, getScale: function(t, e, o) {
142
+ let i = 2 * Math.max(Math.abs(o.top), Math.abs(o.bottom)), r = 2 * Math.max(Math.abs(o.left), Math.abs(o.right));
143
+ return Math.min(r > 0 ? 1 / r * t : 1, i > 0 ? 1 / i * e : 1);
144
+ }, getSpiral: function(t, e) {
145
+ let o = [];
146
+ for (let i = 1; i < 1e4; i++) o.push(t(i, e));
147
+ return (i) => i <= 1e4 && o[i - 1];
148
+ }, intersectionTesting: function(t, e) {
149
+ let o, i, r, n, a, l, m = e.placed, u = e.field, d = e.rectangle, P = e.polygon, z = e.spiral, x = t.rect = gt({}, d), w = 1, p = { x: 0, y: 0 };
150
+ for (t.polygon = P, t.rotation = e.rotation; p !== !1 && (o = t.rect, i = t.polygon, r = t.lastCollidedWith, n = function(g) {
151
+ let s = mt(o, g.rect);
152
+ return s && (t.rotation % 90 || g.rotation % 90) && (s = G(i, g.polygon)), s;
153
+ }, a = !1, r && !(a = n(r)) && delete t.lastCollidedWith, !a && (a = !!q(m, function(g) {
154
+ let s = n(g);
155
+ return s && (t.lastCollidedWith = g), s;
156
+ })), a || !((l = { left: -(u.width / 2), right: u.width / 2, top: -(u.height / 2), bottom: u.height / 2 }).left < x.left && l.right > x.right && l.top < x.top && l.bottom > x.bottom)); ) H(p = z(w)) && (x.left = d.left + p.x, x.right = d.right + p.x, x.top = d.top + p.y, x.bottom = d.bottom + p.y, t.polygon = function(g, s, S) {
157
+ return S.map(function(h) {
158
+ return [h[0] + g, h[1] + s];
159
+ });
160
+ }(p.x, p.y, P)), w++;
161
+ return p;
162
+ }, isPolygonsColliding: G, rectangularSpiral: function(t, e) {
163
+ let o = J(t), i = e.field;
164
+ return o && (o.x *= i.ratioX, o.y *= i.ratioY), o;
165
+ }, rotate2DToOrigin: Q, rotate2DToPoint: Z, squareSpiral: J, updateFieldBoundaries: function(t, e) {
166
+ return (!v(t.left) || t.left > e.left) && (t.left = e.left), (!v(t.right) || t.right < e.right) && (t.right = e.right), (!v(t.top) || t.top > e.top) && (t.top = e.top), (!v(t.bottom) || t.bottom < e.bottom) && (t.bottom = e.bottom), t;
167
+ } };
168
+ class V extends tt {
169
+ pointAttribs(e, o) {
170
+ let i = C().seriesTypes.column.prototype.pointAttribs.call(this, e, o);
171
+ return delete i.stroke, delete i["stroke-width"], i;
172
+ }
173
+ deriveFontSize(e, o, i) {
174
+ let r = D(e) ? e : 0, n = D(o) ? o : 1;
175
+ return Math.floor(Math.max(D(i) ? i : 1, r * n));
176
+ }
177
+ drawPoints() {
178
+ if (this.zooming || this.defaultScale && this.group.scaleX !== this.defaultScale) return;
179
+ let e = this.hasRendered, o = this.xAxis, i = this.yAxis, r = this.chart, n = this.group, a = this.options, l = a.animation, m = a.allowExtendPlayingField, u = r.renderer, d = [], P = this.placementStrategy[a.placementStrategy], z = a.rotation, x = this.points.map(function(h) {
180
+ return h.weight;
181
+ }), w = Math.max.apply(null, x), p = this.points.concat().sort((h, O) => O.weight - h.weight), g = u.text().add(n), s;
182
+ for (let h of (this.group.attr({ scaleX: 1, scaleY: 1 }), p)) {
183
+ let O = 1 / w * h.weight, A = j({ fontSize: this.deriveFontSize(O, a.maxFontSize, a.minFontSize) + "px" }, a.style);
184
+ g.css(A).attr({ x: 0, y: 0, text: h.name });
185
+ let c = g.getBBox(!0);
186
+ h.dimensions = { height: c.height, width: c.width };
187
+ }
188
+ s = wt(o.len, i.len, p);
189
+ let S = Ft(this.spirals[a.spiral], { field: s });
190
+ for (let h of p) {
191
+ let O = 1 / w * h.weight, A = j({ fontSize: this.deriveFontSize(O, a.maxFontSize, a.minFontSize) + "px" }, a.style), c = P(h, { data: p, field: s, placed: d, rotation: z }), f = j(this.pointAttribs(h, h.selected && "select"), { align: "center", "alignment-baseline": "middle", "dominant-baseline": "middle", x: c.x, y: c.y, text: h.name, rotation: D(c.rotation) ? c.rotation : void 0 }), T = St(c.x, c.y, h.dimensions.width, h.dimensions.height, c.rotation), y = Mt(T), M = rt(h, { rectangle: y, polygon: T, field: s, placed: d, spiral: S, rotation: c.rotation }), at;
192
+ !M && m && (s = ot(s, y), M = rt(h, { rectangle: y, polygon: T, field: s, placed: d, spiral: S, rotation: c.rotation })), et(M) ? (f.x = (f.x || 0) + M.x, f.y = (f.y || 0) + M.y, y.left += M.x, y.right += M.x, y.top += M.y, y.bottom += M.y, s = Tt(s, y), d.push(h), h.isNull = !1, h.isInside = !0) : h.isNull = !0, l && (at = { x: f.x, y: f.y }, e ? (delete f.x, delete f.y) : (f.x = 0, f.y = 0)), ht(h, { animatableAttribs: at, attribs: f, css: A, group: n, renderer: u });
193
+ }
194
+ g = g.destroy(), this.defaultScale = Pt(o.len, i.len, s), this.field = s, this.group.attr({ scaleX: this.defaultScale, scaleY: this.defaultScale });
195
+ }
196
+ hasData() {
197
+ return et(this) && this.visible === !0 && xt(this.points) && this.points.length > 0;
198
+ }
199
+ getPlotBox(e) {
200
+ let { chart: o, group: i, zooming: r } = this, { plotSizeX: n = 0, plotSizeY: a = 0, inverted: l } = o, m = this[l ? "yAxis" : "xAxis"], u = this[l ? "xAxis" : "yAxis"], d = m ? m.len : o.plotWidth, P = u ? u.len : o.plotHeight, z = m ? m.left : o.plotLeft, x = u ? u.top : o.plotTop, w = this.field, p = 0, g = 0, s = z + d / 2, S = x + P / 2, h = s, O = S, A = this.defaultScale || 1, c = 0, f = 0;
201
+ if (w && (c = 2 * Math.max(Math.abs(w.top), Math.abs(w.bottom)), f = 2 * Math.max(Math.abs(w.left), Math.abs(w.right))), l && ([f, c] = [c, f]), i && r) {
202
+ let T = z + Math.max(f * (A = Math.max(r.scale, this.defaultScale || 1)), d) / 2, y = x + Math.max(c * A, P) / 2, M = A - (i.scaleX || 1);
203
+ p = M * ((n - f) / 2 + r.zoomX * n - d / 2), g = M * ((a - c) / 2 + r.zoomY * a - P / 2), e === "series" && (r.x = Math.max(0, Math.min(1 - r.width, r.x + r.panX / r.scale)), p += r.panX * n, r.panX = 0, r.y = Math.max(0, Math.min(1 - r.height, r.y + r.panY / r.scale)), g += r.panY * a, r.panY = 0), D(i.translateX) && D(i.translateY) && (h = i.translateX, O = i.translateY), s = h - p, (S = O - g) > y ? S = y : S < 2 * x + P - y && (S = 2 * x + P - y), s > T ? s = T : s < 2 * z + d - T && (s = 2 * z + d - T);
204
+ }
205
+ return { translateX: s, translateY: S, scaleX: A, scaleY: A };
206
+ }
207
+ }
208
+ V.defaultOptions = yt(tt.defaultOptions, { allowExtendPlayingField: !0, animation: { duration: 500 }, borderWidth: 0, clip: !1, colorByPoint: !0, cropThreshold: 1 / 0, minFontSize: 1, maxFontSize: 25, placementStrategy: "center", rotation: { from: 0, orientations: 2, to: 90 }, showInLegend: !1, spiral: "rectangular", style: { fontFamily: "sans-serif", fontWeight: "900", whiteSpace: "nowrap" }, tooltip: { followPointer: !0, pointFormat: '<span style="color:{point.color}">●</span> {series.name}: <b>{point.weight}</b><br/>' } }), j(V.prototype, { animate: N, animateDrilldown: N, animateDrillupFrom: N, isCartesian: !1, pointClass: U, setClip: N, placementStrategy: { random: function(t, e) {
209
+ let o = e.field, i = e.rotation;
210
+ return { x: it(o.width) - o.width / 2, y: it(o.height) - o.height / 2, rotation: L(i.orientations, t.index, i.from, i.to) };
211
+ }, center: function(t, e) {
212
+ let o = e.rotation;
213
+ return { x: 0, y: 0, rotation: L(o.orientations, t.index, o.from, o.to) };
214
+ } }, pointArrayMap: ["weight"], spirals: { archimedean: bt, rectangular: At, square: Ot }, utils: { extendPlayingField: ot, getRotation: L, isPolygonsColliding: vt, rotate2DToOrigin: Xt, rotate2DToPoint: zt } }), E().registerSeriesType("wordcloud", V);
215
+ let Yt = C();
216
+ return k.default;
217
+ })());
218
+ }(B)), B.exports;
219
+ }
220
+ var lt = Wt();
221
+ const Nt = /* @__PURE__ */ Ct(lt), Bt = /* @__PURE__ */ _t({
222
+ __proto__: null,
223
+ default: Nt
224
+ }, [lt]);
225
+ export {
226
+ Bt as w
227
+ };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@mobileaction/action-kit",
3
3
  "type": "module",
4
- "version": "1.57.0",
4
+ "version": "1.57.1",
5
5
  "description": "UI Component library for Mobile Action.",
6
6
  "author": "MobileAction",
7
7
  "license": "MIT",
@@ -62,7 +62,7 @@
62
62
  "ant-design-vue": "3.2.16",
63
63
  "dayjs": "^1.11.10",
64
64
  "floating-vue": "^5.2.2",
65
- "highcharts": "^12.3.0",
65
+ "highcharts": "^12.5.0",
66
66
  "lottie-web": "^5.12.2",
67
67
  "vue": "^3.5.12",
68
68
  "vue-virtual-scroller": "^2.0.0-beta.8",
@@ -1,327 +0,0 @@
1
- import { g as Ge } from "./index-C8r4OcCO.js";
2
- function ze(G, le) {
3
- for (var R = 0; R < le.length; R++) {
4
- const k = le[R];
5
- if (typeof k != "string" && !Array.isArray(k)) {
6
- for (const M in k)
7
- if (M !== "default" && !(M in G)) {
8
- const P = Object.getOwnPropertyDescriptor(k, M);
9
- P && Object.defineProperty(G, M, P.get ? P : {
10
- enumerable: !0,
11
- get: () => k[M]
12
- });
13
- }
14
- }
15
- }
16
- return Object.freeze(Object.defineProperty(G, Symbol.toStringTag, { value: "Module" }));
17
- }
18
- var ie = { exports: {} }, Ye = ie.exports, we;
19
- function Ze() {
20
- return we || (we = 1, function(G, le) {
21
- /**
22
- * Highcharts JS v12.3.0 (2025-06-21)
23
- * @module highcharts/modules/export-data
24
- * @requires highcharts
25
- * @requires highcharts/modules/exporting
26
- *
27
- * Export data module
28
- *
29
- * (c) 2010-2025 Torstein Honsi
30
- *
31
- * License: www.highcharts.com/license
32
- */
33
- (function(R, k) {
34
- G.exports = k(R._Highcharts, R._Highcharts.AST, R._Highcharts.Chart);
35
- })(typeof window > "u" ? Ye : window, (R, k, M) => (() => {
36
- var P, ve = { 660: (r) => {
37
- r.exports = k;
38
- }, 944: (r) => {
39
- r.exports = R;
40
- }, 960: (r) => {
41
- r.exports = M;
42
- } }, ue = {};
43
- function T(r) {
44
- var g = ue[r];
45
- if (g !== void 0) return g.exports;
46
- var y = ue[r] = { exports: {} };
47
- return ve[r](y, y.exports, T), y.exports;
48
- }
49
- T.n = (r) => {
50
- var g = r && r.__esModule ? () => r.default : () => r;
51
- return T.d(g, { a: g }), g;
52
- }, T.d = (r, g) => {
53
- for (var y in g) T.o(g, y) && !T.o(r, y) && Object.defineProperty(r, y, { enumerable: !0, get: g[y] });
54
- }, T.o = (r, g) => Object.prototype.hasOwnProperty.call(r, g);
55
- var ge = {};
56
- T.d(ge, { default: () => Ie });
57
- var Te = T(944), j = T.n(Te);
58
- let { isSafari: Se, win: S, win: { document: se } } = j(), { error: Qe } = j(), fe = S.URL || S.webkitURL || S;
59
- function xe(r) {
60
- let g = r.replace(/filename=.*;/, "").match(/data:([^;]*)(;base64)?,([A-Z+\d\/]+)/i);
61
- if (g && g.length > 3 && S.atob && S.ArrayBuffer && S.Uint8Array && S.Blob && fe.createObjectURL) {
62
- let y = S.atob(g[3]), A = new S.ArrayBuffer(y.length), K = new S.Uint8Array(A);
63
- for (let q = 0; q < K.length; ++q) K[q] = y.charCodeAt(q);
64
- return fe.createObjectURL(new S.Blob([K], { type: g[1] }));
65
- }
66
- }
67
- let de = { dataURLtoBlob: xe, downloadURL: function(r, g) {
68
- let y = S.navigator, A = se.createElement("a");
69
- if (typeof r != "string" && !(r instanceof String) && y.msSaveOrOpenBlob) return void y.msSaveOrOpenBlob(r, g);
70
- if (r = "" + r, y.userAgent.length > 1e3) throw Error("Input too long");
71
- let K = /Edge\/\d+/.test(y.userAgent);
72
- if ((Se && typeof r == "string" && r.indexOf("data:application/pdf") === 0 || K || r.length > 2e6) && !(r = xe(r) || "")) throw Error("Failed to convert to blob");
73
- if (A.download !== void 0) A.href = r, A.download = g, se.body.appendChild(A), A.click(), se.body.removeChild(A);
74
- else try {
75
- if (!S.open(r, "chart")) throw Error("Failed to open window");
76
- } catch {
77
- S.location.href = r;
78
- }
79
- } };
80
- var Le = T(660), ce = T.n(Le), Ee = T(960), Ce = T.n(Ee);
81
- let Ae = { exporting: { csv: { annotations: { itemDelimiter: "; ", join: !1 }, columnHeaderFormatter: null, dateFormat: "%Y-%m-%d %H:%M:%S", decimalPoint: null, itemDelimiter: null, lineDelimiter: `
82
- ` }, menuItemDefinitions: { downloadCSV: { textKey: "downloadCSV", onclick: function() {
83
- this.exporting?.downloadCSV();
84
- } }, downloadXLS: { textKey: "downloadXLS", onclick: function() {
85
- this.exporting?.downloadXLS();
86
- } }, viewData: { textKey: "viewData", onclick: function() {
87
- this.exporting?.wrapLoading(this.exporting.toggleDataTable);
88
- } } }, showTable: !1, useMultiLevelHeaders: !0, useRowspanHeaders: !0, showExportInProgress: !0 }, lang: { downloadCSV: "Download CSV", downloadXLS: "Download XLS", exportData: { annotationHeader: "Annotations", categoryHeader: "Category", categoryDatetimeHeader: "DateTime" }, viewData: "View data table", hideData: "Hide data table", exportInProgress: "Exporting..." } }, { getOptions: Oe, setOptions: Re } = j(), { downloadURL: me } = de, { composed: ke, doc: Ve, win: V } = j(), { addEvent: pe, defined: Ne, extend: be, find: He, fireEvent: te, isNumber: Ue, pick: $, pushUnique: Fe } = j();
89
- (function(r) {
90
- function g() {
91
- this.wrapLoading(() => {
92
- let n = this.getCSV(!0);
93
- me(A(n, "text/csv") || "data:text/csv,\uFEFF" + encodeURIComponent(n), this.getFilename() + ".csv");
94
- });
95
- }
96
- function y() {
97
- this.wrapLoading(() => {
98
- let n = '<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>Ark1</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--><style>td{border:none;font-family: Calibri, sans-serif;} .number{mso-number-format:"0.00";} .text{ mso-number-format:"@";}</style><meta name=ProgId content=Excel.Sheet><meta charset=UTF-8></head><body>' + this.getTable(!0) + "</body></html>";
99
- me(A(n, "application/vnd.ms-excel") || "data:application/vnd.ms-excel;base64," + V.btoa(unescape(encodeURIComponent(n))), this.getFilename() + ".xls");
100
- });
101
- }
102
- function A(n, l) {
103
- let i = V.navigator, a = V.URL || V.webkitURL || V;
104
- try {
105
- if (i.msSaveOrOpenBlob && V.MSBlobBuilder) {
106
- let t = new V.MSBlobBuilder();
107
- return t.append(n), t.getBlob("image/svg+xml");
108
- }
109
- return a.createObjectURL(new V.Blob(["\uFEFF" + n], { type: l }));
110
- } catch {
111
- }
112
- }
113
- function K(n) {
114
- let l = "", i = this.getDataRows(), a = this.options?.csv, t = $(a?.decimalPoint, a?.itemDelimiter !== "," && n ? 1.1.toLocaleString()[1] : "."), s = $(a?.itemDelimiter, t === "," ? ";" : ","), h = a?.lineDelimiter;
115
- return i.forEach((c, o) => {
116
- let d = "", w = c.length;
117
- for (; w--; ) typeof (d = c[w]) == "string" && (d = `"${d}"`), typeof d == "number" && t !== "." && (d = d.toString().replace(".", t)), c[w] = d;
118
- c.length = i.length ? i[0].length : 0, l += c.join(s), o < i.length - 1 && (l += h);
119
- }), l;
120
- }
121
- function q(n) {
122
- let l, i, a = this.chart, t = a.hasParallelCoordinates, s = a.time, h = this.options?.csv || {}, c = a.xAxis, o = {}, d = [], w = [], z = [], X = a.options.lang.exportData, H = X?.categoryHeader, Y = X?.categoryDatetimeHeader, Z = function(e, f, D) {
123
- if (h.columnHeaderFormatter) {
124
- let v = h.columnHeaderFormatter(e, f, D);
125
- if (v !== !1) return v;
126
- }
127
- return !e && H ? H : !e.bindAxes && Y && H ? e.options.title && e.options.title.text || (e.dateTime ? Y : H) : n ? { columnTitle: ((D || 0) > 1 ? f : e.name) || "", topLevelColumnTitle: e.name } : e.name + ((D || 0) > 1 ? " (" + f + ")" : "");
128
- }, m = function(e, f, D) {
129
- let v = {}, J = {};
130
- return f.forEach(function(F) {
131
- let W = (e.keyToAxis && e.keyToAxis[F] || F) + "Axis", B = Ue(D) ? e.chart[W][D] : e[W];
132
- v[F] = B && B.categories || [], J[F] = B && B.dateTime;
133
- }), { categoryMap: v, dateTimeValueAxisMap: J };
134
- }, u = function(e, f) {
135
- let D = e.pointArrayMap || ["y"];
136
- return e.data.some((v) => v.y !== void 0 && v.name) && f && !f.categories && e.exportKey !== "name" ? ["x", ...D] : D;
137
- }, x = [], L, p, E, C = 0, U, N;
138
- for (U in a.series.forEach(function(e) {
139
- let f = e.options.keys, D = e.xAxis, v = f || u(e, D), J = v.length, F = !e.requireSorting && {}, W = c.indexOf(D), B = m(e, v), ye, O;
140
- if (e.options.includeInDataExport !== !1 && !e.options.isInternal && e.visible !== !1) {
141
- for (He(x, function(he) {
142
- return he[0] === W;
143
- }) || x.push([W, C]), O = 0; O < J; ) E = Z(e, v[O], v.length), z.push(E.columnTitle || E), n && w.push(E.topLevelColumnTitle || E), O++;
144
- ye = { chart: e.chart, autoIncrement: e.autoIncrement, options: e.options, pointArrayMap: e.pointArrayMap, index: e.index }, e.options.data?.forEach(function(he, ae) {
145
- let b, oe, ne, Q = { series: ye };
146
- t && (B = m(e, v, ae)), e.pointClass.prototype.applyOptions.apply(Q, [he]);
147
- let re = e.data[ae] && e.data[ae].name;
148
- if (b = (Q.x ?? "") + "," + re, O = 0, (!D || e.exportKey === "name" || !t && D && D.hasNames && re) && (b = re), F && (F[b] && (b += "|" + ae), F[b] = !0), o[b]) {
149
- let I = `${b},${o[b].pointers[e.index]}`, ee = b;
150
- o[b].pointers[e.index] && (o[I] || (o[I] = [], o[I].xValues = [], o[I].pointers = []), b = I), o[ee].pointers[e.index] += 1;
151
- } else {
152
- o[b] = [], o[b].xValues = [];
153
- let I = [];
154
- for (let ee = 0; ee < e.chart.series.length; ee++) I[ee] = 0;
155
- o[b].pointers = I, o[b].pointers[e.index] = 1;
156
- }
157
- for (o[b].x = Q.x, o[b].name = re, o[b].xValues[W] = Q.x; O < J; ) oe = v[O], ne = e.pointClass.prototype.getNestedProperty.apply(Q, [oe]), o[b][C + O] = $(B.categoryMap[oe][ne], B.dateTimeValueAxisMap[oe] ? s.dateFormat(h.dateFormat, ne) : null, ne), O++;
158
- }), C += O;
159
- }
160
- }), o) Object.hasOwnProperty.call(o, U) && d.push(o[U]);
161
- for (p = n ? [w, z] : [z], C = x.length; C--; ) l = x[C][0], i = x[C][1], L = c[l], d.sort(function(e, f) {
162
- return e.xValues[l] - f.xValues[l];
163
- }), N = Z(L), p[0].splice(i, 0, N), n && p[1] && p[1].splice(i, 0, N), d.forEach(function(e) {
164
- let f = e.name;
165
- L && !Ne(f) && (L.dateTime ? (e.x instanceof Date && (e.x = e.x.getTime()), f = s.dateFormat(h.dateFormat, e.x)) : f = L.categories ? $(L.names[e.x], L.categories[e.x], e.x) : e.x), e.splice(i, 0, f);
166
- });
167
- return te(a, "exportData", { dataRows: p = p.concat(d) }), p;
168
- }
169
- function Me(n) {
170
- let l = (i) => {
171
- if (!i.tagName || i.tagName === "#text") return i.textContent || "";
172
- let a = i.attributes, t = `<${i.tagName}`;
173
- return a && Object.keys(a).forEach((s) => {
174
- let h = a[s];
175
- t += ` ${s}="${h}"`;
176
- }), t += ">", t += i.textContent || "", (i.children || []).forEach((s) => {
177
- t += l(s);
178
- }), t += `</${i.tagName}>`;
179
- };
180
- return l(this.getTableAST(n));
181
- }
182
- function Pe(n) {
183
- let l = 0, i = [], a = this, t = a.chart, s = t.options, h = n ? 1.1.toLocaleString()[1] : ".", c = $(a.options.useMultiLevelHeaders, !0), o = a.getDataRows(c), d = c ? o.shift() : null, w = o.shift(), z = function(m, u) {
184
- let x = m.length;
185
- if (u.length !== x) return !1;
186
- for (; x--; ) if (m[x] !== u[x]) return !1;
187
- return !0;
188
- }, X = function(m, u, x, L) {
189
- let p = $(L, ""), E = "highcharts-text" + (u ? " " + u : "");
190
- return typeof p == "number" ? (p = p.toString(), h === "," && (p = p.replace(".", h)), E = "highcharts-number") : L || (E = "highcharts-empty"), { tagName: m, attributes: x = be({ class: E }, x), textContent: p };
191
- }, { tableCaption: H } = a.options || {};
192
- H !== !1 && i.push({ tagName: "caption", attributes: { class: "highcharts-table-caption" }, textContent: typeof H == "string" ? H : s.title?.text || s.lang.chartTitle });
193
- for (let m = 0, u = o.length; m < u; ++m) o[m].length > l && (l = o[m].length);
194
- i.push(function(m, u, x) {
195
- let L = [], p = 0, E = x || u && u.length, C, U = 0, N;
196
- if (c && m && u && !z(m, u)) {
197
- let e = [];
198
- for (; p < E; ++p) if ((C = m[p]) === m[p + 1]) ++U;
199
- else if (U) e.push(X("th", "highcharts-table-topheading", { scope: "col", colspan: U + 1 }, C)), U = 0;
200
- else {
201
- C === u[p] ? a.options.useRowspanHeaders ? (N = 2, delete u[p]) : (N = 1, u[p] = "") : N = 1;
202
- let f = X("th", "highcharts-table-topheading", { scope: "col" }, C);
203
- N > 1 && f.attributes && (f.attributes.valign = "top", f.attributes.rowspan = N), e.push(f);
204
- }
205
- L.push({ tagName: "tr", children: e });
206
- }
207
- if (u) {
208
- let e = [];
209
- for (p = 0, E = u.length; p < E; ++p) u[p] !== void 0 && e.push(X("th", null, { scope: "col" }, u[p]));
210
- L.push({ tagName: "tr", children: e });
211
- }
212
- return { tagName: "thead", children: L };
213
- }(d, w || [], Math.max(l, w?.length || 0)));
214
- let Y = [];
215
- o.forEach(function(m) {
216
- let u = [];
217
- for (let x = 0; x < l; x++) u.push(X(x ? "td" : "th", null, x ? {} : { scope: "row" }, m[x]));
218
- Y.push({ tagName: "tr", children: u });
219
- }), i.push({ tagName: "tbody", children: Y });
220
- let Z = { tree: { tagName: "table", id: `highcharts-data-table-${t.index}`, children: i } };
221
- return te(t, "afterGetTableAST", Z), Z.tree;
222
- }
223
- function je() {
224
- this.toggleDataTable(!1);
225
- }
226
- function $e(n) {
227
- let l = this.chart, i = (n = $(n, !this.isDataTableVisible)) && !this.dataTableDiv;
228
- if (i && (this.dataTableDiv = Ve.createElement("div"), this.dataTableDiv.className = "highcharts-data-table", l.renderTo.parentNode.insertBefore(this.dataTableDiv, l.renderTo.nextSibling)), this.dataTableDiv) {
229
- let c = this.dataTableDiv.style, o = c.display;
230
- c.display = n ? "block" : "none", n ? (this.dataTableDiv.innerHTML = ce().emptyHTML, new (ce())([this.getTableAST()]).addToDOM(this.dataTableDiv), te(l, "afterViewData", { element: this.dataTableDiv, wasHidden: i || o !== c.display })) : te(l, "afterHideData");
231
- }
232
- this.isDataTableVisible = n;
233
- let a = this.divElements, t = this.options, s = t.buttons?.contextButton.menuItems, h = l.options.lang;
234
- if (t && t.menuItemDefinitions && h && h.viewData && h.hideData && s && a) {
235
- let c = a[s.indexOf("viewData")];
236
- c && ce().setElementHTML(c, this.isDataTableVisible ? h.hideData : h.viewData);
237
- }
238
- }
239
- function _e() {
240
- this.toggleDataTable(!0);
241
- }
242
- function Ke(n) {
243
- let l = this.chart, i = !!this.options.showExportInProgress, a = V.requestAnimationFrame || setTimeout;
244
- a(() => {
245
- i && l.showLoading(l.options.lang.exportInProgress), a(() => {
246
- try {
247
- n.call(this);
248
- } finally {
249
- i && l.hideLoading();
250
- }
251
- });
252
- });
253
- }
254
- function Xe() {
255
- let n = this.exporting, l = n?.dataTableDiv, i = (t, s) => t.children[s].textContent, a = (t, s) => (h, c) => {
256
- let o, d;
257
- return o = i(s ? h : c, t), d = i(s ? c : h, t), o === "" || d === "" || isNaN(o) || isNaN(d) ? o.toString().localeCompare(d) : o - d;
258
- };
259
- if (l && n.options.allowTableSorting) {
260
- let t = l.querySelector("thead tr");
261
- t && t.childNodes.forEach((s) => {
262
- let h = l.querySelector("tbody");
263
- s.addEventListener("click", function() {
264
- let c = [...l.querySelectorAll("tr:not(thead tr)")], o = [...s.parentNode.children];
265
- n && (c.sort(a(o.indexOf(s), n.ascendingOrderInTable = !n.ascendingOrderInTable)).forEach((d) => {
266
- h?.appendChild(d);
267
- }), o.forEach((d) => {
268
- ["highcharts-sort-ascending", "highcharts-sort-descending"].forEach((w) => {
269
- d.classList.contains(w) && d.classList.remove(w);
270
- });
271
- }), s.classList.add(n.ascendingOrderInTable ? "highcharts-sort-ascending" : "highcharts-sort-descending"));
272
- });
273
- });
274
- }
275
- }
276
- function qe() {
277
- this.options?.exporting?.showTable && !this.options.chart.forExport && this.exporting?.viewData();
278
- }
279
- function We() {
280
- this.exporting?.dataTableDiv?.remove();
281
- }
282
- r.compose = function(n, l, i) {
283
- if (!Fe(ke, "ExportData")) return;
284
- be(Ce().prototype, { downloadCSV: function() {
285
- return this.exporting?.downloadCSV();
286
- }, downloadXLS: function() {
287
- return this.exporting?.downloadXLS();
288
- }, getCSV: function(t) {
289
- return this.exporting?.getCSV(t);
290
- }, getDataRows: function(t) {
291
- return this.exporting?.getDataRows(t);
292
- }, getTable: function(t) {
293
- return this.exporting?.getTable(t);
294
- }, getTableAST: function(t) {
295
- return this.exporting?.getTableAST(t);
296
- }, hideData: function() {
297
- return this.exporting?.hideData();
298
- }, toggleDataTable: function(t) {
299
- return this.exporting?.toggleDataTable(t);
300
- }, viewData: function() {
301
- return this.exporting?.viewData();
302
- } });
303
- let a = l.prototype;
304
- if (!a.downloadCSV) {
305
- pe(n, "afterViewData", Xe), pe(n, "render", qe), pe(n, "destroy", We), a.downloadCSV = g, a.downloadXLS = y, a.getCSV = K, a.getDataRows = q, a.getTable = Me, a.getTableAST = Pe, a.hideData = je, a.toggleDataTable = $e, a.wrapLoading = Ke, a.viewData = _e, Re(Ae);
306
- let t = Oe().exporting?.buttons?.contextButton?.menuItems;
307
- t && t.push("separator", "downloadCSV", "downloadXLS", "viewData");
308
- let { arearange: s, gantt: h, map: c, mapbubble: o, treemap: d, xrange: w } = i.types;
309
- s && (s.prototype.keyToAxis = { low: "y", high: "y" }), h && (h.prototype.exportKey = "name", h.prototype.keyToAxis = { start: "x", end: "x" }), c && (c.prototype.exportKey = "name"), o && (o.prototype.exportKey = "name"), d && (d.prototype.exportKey = "name"), w && (w.prototype.keyToAxis = { x2: "x" });
310
- }
311
- };
312
- })(P || (P = {}));
313
- let Be = P, _ = j();
314
- _.dataURLtoBlob = _.dataURLtoBlob || de.dataURLtoBlob, _.downloadURL = _.downloadURL || de.downloadURL, Be.compose(_.Chart, _.Exporting, _.Series);
315
- let Ie = j();
316
- return ge.default;
317
- })());
318
- }(ie)), ie.exports;
319
- }
320
- var De = Ze();
321
- const Je = /* @__PURE__ */ Ge(De), tt = /* @__PURE__ */ ze({
322
- __proto__: null,
323
- default: Je
324
- }, [De]);
325
- export {
326
- tt as e
327
- };