@slotted/react 0.1.0-beta.36 → 0.1.0-beta.37
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/calendar-D8FhdXWc.js +537 -0
- package/dist/calendar.js +1 -1
- package/dist/{cascader-DqrFX3Ob.js → cascader-CivJ76VR.js} +1 -1
- package/dist/cascader.js +1 -1
- package/dist/{chart-BaNN4AQj.js → chart-DwXqQZjQ.js} +234 -233
- package/dist/chart.js +1 -1
- package/dist/{checkbox-ruvmi9cK.js → checkbox-D3E4gzMe.js} +3 -3
- package/dist/{checkbox-group-Ben6o9Ze.js → checkbox-group-Dg5YN3fx.js} +2 -2
- package/dist/checkbox-group.js +1 -1
- package/dist/checkbox.js +1 -1
- package/dist/{collapsible-D97FQrzs.js → collapsible-CT4_3aXm.js} +1 -0
- package/dist/collapsible.js +1 -1
- package/dist/{color-picker-DhKW6Uyc.js → color-picker-CaLcV-63.js} +2 -2
- package/dist/color-picker.js +1 -1
- package/dist/{column-manager-D2PXs80l.js → column-manager-BBGczWQe.js} +2 -2
- package/dist/column-manager.js +1 -1
- package/dist/{combobox-BIi7grOR.js → combobox-C2qlkTw6.js} +1 -1
- package/dist/combobox.js +1 -1
- package/dist/{currency-field-CAO2ZolW.js → currency-field-BO2P6FPd.js} +1 -1
- package/dist/currency-field.js +1 -1
- package/dist/{data-grid-DOMm7-ew.js → data-grid-C5YmAqdN.js} +15 -15
- package/dist/data-grid.js +1 -1
- package/dist/{data-list-DgXGmRQx.js → data-list-DovwQEMt.js} +1 -1
- package/dist/data-list.js +1 -1
- package/dist/{date-field-BEdt1xDF.js → date-field-CxubN_3u.js} +1 -1
- package/dist/date-field.js +1 -1
- package/dist/{date-picker-CQDvE1nB.js → date-picker-DQbj3FON.js} +3 -3
- package/dist/date-picker.js +1 -1
- package/dist/{date-range-picker-B28tj1yV.js → date-range-picker-B16hMhJf.js} +3 -3
- package/dist/date-range-picker.js +1 -1
- package/dist/{datetime-field-2tsqzWVH.js → datetime-field-GMIqBuTa.js} +1 -1
- package/dist/datetime-field.js +1 -1
- package/dist/{datetime-picker-CXLvcFxV.js → datetime-picker-C9pxH7Xf.js} +3 -3
- package/dist/datetime-picker.js +1 -1
- package/dist/{datetime-range-picker-BAXiRa2S.js → datetime-range-picker-Cmn7o_Qv.js} +3 -3
- package/dist/datetime-range-picker.js +1 -1
- package/dist/{detail-panel-DEZewVVV.js → detail-panel-DLgRhEFO.js} +3 -3
- package/dist/detail-panel.js +1 -1
- package/dist/docs/button.json +1 -1
- package/dist/docs/button.md +1 -1
- package/dist/docs/calendar.json +22 -0
- package/dist/docs/calendar.md +4 -1
- package/dist/docs/chart.json +1 -1
- package/dist/docs/chart.md +1 -1
- package/dist/docs/collapsible.json +2 -1
- package/dist/docs/collapsible.md +1 -1
- package/dist/docs/floating-panel.json +22 -4
- package/dist/docs/floating-panel.md +6 -4
- package/dist/docs/message.json +7 -0
- package/dist/docs/message.md +1 -0
- package/dist/docs/page.json +7 -0
- package/dist/docs/page.md +1 -0
- package/dist/docs/section.json +10 -2
- package/dist/docs/section.md +2 -1
- package/dist/docs/skills/theme-app/SKILL.md +1 -1
- package/dist/docs/table.json +16 -4
- package/dist/docs/table.md +5 -3
- package/dist/{entity-picker-D1MwJyvr.js → entity-picker-CwfA1wr_.js} +2 -2
- package/dist/entity-picker.js +1 -1
- package/dist/{event-calendar-CM302ec0.js → event-calendar-biSTH0yK.js} +1 -1
- package/dist/event-calendar.js +1 -1
- package/dist/{field-group-DQI8pfDT.js → field-group-7zV68b3d.js} +1 -1
- package/dist/field-group.js +1 -1
- package/dist/{field-BjF0c0U9.js → field-vOVzvq5t.js} +27 -27
- package/dist/field.js +1 -1
- package/dist/{filter-bar-CDEpYvq4.js → filter-bar-Cfwk-3Eu.js} +8 -8
- package/dist/filter-bar.js +1 -1
- package/dist/floating-panel-Dp6S4GgU.js +163 -0
- package/dist/floating-panel.js +1 -1
- package/dist/import-export-center-BH1bNw_E.js +867 -0
- package/dist/import-export-center.js +1 -1
- package/dist/index.js +94 -94
- package/dist/{listbox-BGJ2fEDO.js → listbox-CWU3DiEt.js} +1 -1
- package/dist/listbox.js +1 -1
- package/dist/{markdown-CfPMPahy.js → markdown-x59MHBAa.js} +1 -1
- package/dist/markdown.js +1 -1
- package/dist/{message-j4-apGnW.js → message-CdcUyh3g.js} +6 -5
- package/dist/message.js +1 -1
- package/dist/{multi-select-DSSDlWVZ.js → multi-select-DEd_92BC.js} +1 -1
- package/dist/multi-select.js +1 -1
- package/dist/{number-field-DzOcs9uG.js → number-field-BJKoidAE.js} +1 -1
- package/dist/number-field.js +1 -1
- package/dist/{otp-input-ult9fNdj.js → otp-input-Czz9Z6dQ.js} +1 -1
- package/dist/otp-input.js +1 -1
- package/dist/{prompt-composer-CUuAuR4h.js → prompt-composer-Lsfcz_i9.js} +1 -1
- package/dist/prompt-composer.js +1 -1
- package/dist/{radio-group-doL7tde1.js → radio-group-_ZRUgcI5.js} +2 -2
- package/dist/radio-group.js +1 -1
- package/dist/{rating-BtrkTAi0.js → rating-C6AkIIUi.js} +1 -1
- package/dist/rating.js +1 -1
- package/dist/{saved-views-fg5PoMgv.js → saved-views-BvRFgSdg.js} +2 -2
- package/dist/saved-views.js +1 -1
- package/dist/{section-OdQoVBnl.js → section-CQPQf6RU.js} +15 -2
- package/dist/section.js +2 -2
- package/dist/{segmented-control-CuwEdrZS.js → segmented-control-D52GeOlS.js} +2 -2
- package/dist/segmented-control.js +1 -1
- package/dist/{select-C85IKiKk.js → select-BkUuIVBK.js} +1 -1
- package/dist/select.js +1 -1
- package/dist/{slider-yhqotDtS.js → slider-DQqQ0skr.js} +1 -1
- package/dist/slider.js +1 -1
- package/dist/styles/app-shell.css +1 -1
- package/dist/styles/button.css +1 -1
- package/dist/styles/calendar.css +3 -1
- package/dist/styles/cascader.css +3 -3
- package/dist/styles/chart.css +2 -2
- package/dist/styles/checkbox-group.css +2 -2
- package/dist/styles/checkbox.css +2 -2
- package/dist/styles/collapsible.css +1 -1
- package/dist/styles/color-picker.css +2 -2
- package/dist/styles/column-manager.css +3 -3
- package/dist/styles/combobox.css +2 -2
- package/dist/styles/currency-field.css +2 -2
- package/dist/styles/dashboard-grid.css +2 -2
- package/dist/styles/data-grid.css +2 -2
- package/dist/styles/data-list.css +3 -3
- package/dist/styles/date-field.css +2 -2
- package/dist/styles/date-picker.css +3 -3
- package/dist/styles/date-range-picker.css +3 -3
- package/dist/styles/datetime-field.css +2 -2
- package/dist/styles/datetime-picker.css +3 -3
- package/dist/styles/datetime-range-picker.css +3 -3
- package/dist/styles/detail-panel.css +2 -2
- package/dist/styles/entity-picker.css +2 -2
- package/dist/styles/event-calendar.css +2 -2
- package/dist/styles/field-group.css +2 -2
- package/dist/styles/field.css +2 -2
- package/dist/styles/filter-bar.css +4 -4
- package/dist/styles/floating-panel.css +1 -1
- package/dist/styles/import-export-center.css +3 -3
- package/dist/styles/index.css +13 -13
- package/dist/styles/listbox.css +2 -2
- package/dist/styles/markdown.css +1 -1
- package/dist/styles/message.css +1 -1
- package/dist/styles/multi-select.css +2 -2
- package/dist/styles/notification-center.css +1 -1
- package/dist/styles/number-field.css +2 -2
- package/dist/styles/otp-input.css +2 -2
- package/dist/styles/page-header.css +1 -1
- package/dist/styles/page.css +1 -1
- package/dist/styles/prompt-composer.css +2 -2
- package/dist/styles/radio-group.css +2 -2
- package/dist/styles/rating.css +2 -2
- package/dist/styles/saved-views.css +3 -3
- package/dist/styles/section.css +1 -1
- package/dist/styles/segmented-control.css +2 -2
- package/dist/styles/select.css +2 -2
- package/dist/styles/side-navigation.css +1 -1
- package/dist/styles/slider.css +2 -2
- package/dist/styles/split-button.css +1 -1
- package/dist/styles/switch.css +2 -2
- package/dist/styles/table.css +3 -3
- package/dist/styles/tags-input.css +2 -2
- package/dist/styles/text-field.css +2 -2
- package/dist/styles/textarea.css +2 -2
- package/dist/styles/time-field.css +2 -2
- package/dist/styles/time-picker.css +2 -2
- package/dist/styles/time-range-picker.css +2 -2
- package/dist/styles/toggle-group.css +2 -2
- package/dist/styles/top-navigation.css +1 -1
- package/dist/styles/tour.css +1 -1
- package/dist/styles/transfer.css +3 -3
- package/dist/styles/upload.css +2 -2
- package/dist/styles/wizard.css +1 -1
- package/dist/styles.css +1 -1
- package/dist/{switch-C5WjteaS.js → switch-C2krbZHI.js} +1 -1
- package/dist/switch.js +1 -1
- package/dist/{table-D8-WlkFz.js → table-CnXBp9j9.js} +357 -344
- package/dist/table.js +2 -2
- package/dist/{tags-input-_cYR2JSK.js → tags-input-O87zTh7h.js} +1 -1
- package/dist/tags-input.js +1 -1
- package/dist/{text-field-DEm3MEe2.js → text-field-Cnjc7LB5.js} +1 -1
- package/dist/text-field.js +1 -1
- package/dist/{textarea-BRRn55L2.js → textarea-DcA7jwOM.js} +1 -1
- package/dist/textarea.js +1 -1
- package/dist/{time-field-C9dFaZOx.js → time-field-BanhrUvf.js} +1 -1
- package/dist/time-field.js +1 -1
- package/dist/{time-picker-Cw9NezUE.js → time-picker-B4-GsO24.js} +2 -2
- package/dist/time-picker.js +1 -1
- package/dist/{time-range-picker-DmmUqGjV.js → time-range-picker-DVOWN8PF.js} +2 -2
- package/dist/time-range-picker.js +1 -1
- package/dist/{toggle-group-DiKxYOwh.js → toggle-group-D7GQyNQP.js} +1 -1
- package/dist/toggle-group.js +1 -1
- package/dist/{transfer-CuNCXEoR.js → transfer-CuLlF_nY.js} +5 -5
- package/dist/transfer.js +1 -1
- package/dist/types/button/button.types.d.ts +2 -1
- package/dist/types/button/button.types.d.ts.map +1 -1
- package/dist/types/calendar/calendar-day-button.d.ts +12 -0
- package/dist/types/calendar/calendar-day-button.d.ts.map +1 -0
- package/dist/types/calendar/calendar-header.d.ts +20 -0
- package/dist/types/calendar/calendar-header.d.ts.map +1 -0
- package/dist/types/calendar/calendar.d.ts +1 -1
- package/dist/types/calendar/calendar.d.ts.map +1 -1
- package/dist/types/calendar/calendar.types.d.ts +14 -0
- package/dist/types/calendar/calendar.types.d.ts.map +1 -1
- package/dist/types/chart/chart.d.ts.map +1 -1
- package/dist/types/collapsible/collapsible-parts.d.ts +1 -1
- package/dist/types/collapsible/collapsible-parts.d.ts.map +1 -1
- package/dist/types/collapsible/collapsible.types.d.ts +1 -0
- package/dist/types/collapsible/collapsible.types.d.ts.map +1 -1
- package/dist/types/floating-panel/floating-panel.d.ts +1 -1
- package/dist/types/floating-panel/floating-panel.d.ts.map +1 -1
- package/dist/types/floating-panel/floating-panel.types.d.ts +6 -2
- package/dist/types/floating-panel/floating-panel.types.d.ts.map +1 -1
- package/dist/types/message/message-parts.d.ts +4 -3
- package/dist/types/message/message-parts.d.ts.map +1 -1
- package/dist/types/message/message.types.d.ts +6 -0
- package/dist/types/message/message.types.d.ts.map +1 -1
- package/dist/types/section/index.d.ts +1 -1
- package/dist/types/section/index.d.ts.map +1 -1
- package/dist/types/section/section-parts.d.ts +6 -0
- package/dist/types/section/section-parts.d.ts.map +1 -1
- package/dist/types/table/index.d.ts +2 -2
- package/dist/types/table/index.d.ts.map +1 -1
- package/dist/types/table/table-parts.d.ts +7 -1
- package/dist/types/table/table-parts.d.ts.map +1 -1
- package/dist/types/table/table.d.ts.map +1 -1
- package/dist/types/table/table.types.d.ts +8 -3
- package/dist/types/table/table.types.d.ts.map +1 -1
- package/dist/{upload-Bpjlax3i.js → upload-DggJrkQ7.js} +1 -1
- package/dist/upload.js +1 -1
- package/package.json +6 -6
- package/dist/calendar-CjVx7amB.js +0 -511
- package/dist/floating-panel-84VLZdhL.js +0 -166
- package/dist/import-export-center-DdANj0_T.js +0 -867
|
@@ -11,39 +11,39 @@ import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
|
|
|
11
11
|
import { collapseState as se } from "@slotted/core/overflow";
|
|
12
12
|
import { chartMessages as ce } from "@slotted/core/i18n";
|
|
13
13
|
import { getLiveAnnouncer as le } from "@slotted/core/live-announcer";
|
|
14
|
-
import { FULL_ZOOM as
|
|
15
|
-
import { mountChartEngine as
|
|
14
|
+
import { FULL_ZOOM as _, TOOLTIP_DOCK_WIDTH as ue, cachedChartTheme as de, categoryIndex as fe, chartKeyAction as pe, chartTable as me, chartToCsv as he, createChartModel as ge, createLatestAnnouncer as _e, createRangeDrag as ve, defaultTrigger as ye, describeChart as be, describePoint as xe, describeRange as Se, describeZoom as Ce, firstPoint as we, isDrawn as v, isFullZoom as Te, observeChartTheme as Ee, placeLayer as De, placeTooltip as Oe, pointText as ke, readChartTheme as Ae, sameTheme as je, seriesOf as y, toggleHidden as Me, tooltipContext as Ne, trackModality as Pe } from "@slotted/core/chart";
|
|
15
|
+
import { mountChartEngine as Fe, preloadChartEngine as Ie } from "@slotted/core/chart-echarts";
|
|
16
16
|
//#region src/chart/chart-defaults.tsx
|
|
17
|
-
var
|
|
18
|
-
function
|
|
19
|
-
return ne(
|
|
17
|
+
var b = l({});
|
|
18
|
+
function Le() {
|
|
19
|
+
return ne(b);
|
|
20
20
|
}
|
|
21
|
-
function
|
|
22
|
-
let n =
|
|
21
|
+
function Re({ children: e, ...t }) {
|
|
22
|
+
let n = Le(), r = { ...n };
|
|
23
23
|
for (let [e, n] of Object.entries(t)) n !== void 0 && (r[e] = n);
|
|
24
24
|
return r.tooltip = {
|
|
25
25
|
...n.tooltip,
|
|
26
26
|
...t.tooltip
|
|
27
|
-
}, /* @__PURE__ */ h(
|
|
27
|
+
}, /* @__PURE__ */ h(b.Provider, {
|
|
28
28
|
value: r,
|
|
29
29
|
children: e
|
|
30
30
|
});
|
|
31
31
|
}
|
|
32
32
|
//#endregion
|
|
33
33
|
//#region src/chart/chart.tsx
|
|
34
|
-
var
|
|
35
|
-
function
|
|
34
|
+
var ze = Object.freeze([]), Be = (e, t) => e === t || e !== null && t !== null && e.series === t.series && e.key === t.key, Ve = (e, t) => e.length === t.length && e.every((e, n) => e === t[n]), He = (e, t) => e.start === t.start && e.end === t.end, Ue = (e, t) => e === t || e !== null && t !== null && e.from === t.from && e.to === t.to, We = (e) => typeof e == "object" && !!e && Object.getPrototypeOf(e) === Object.prototype;
|
|
35
|
+
function x(e, t) {
|
|
36
36
|
if (Object.is(e, t)) return !0;
|
|
37
|
-
if (Array.isArray(e)) return Array.isArray(t) && e.length === t.length && e.every((e, n) =>
|
|
38
|
-
if (!
|
|
37
|
+
if (Array.isArray(e)) return Array.isArray(t) && e.length === t.length && e.every((e, n) => x(e, t[n]));
|
|
38
|
+
if (!We(e) || !We(t)) return !1;
|
|
39
39
|
let n = Object.keys(e);
|
|
40
|
-
return n.length === Object.keys(t).length && n.every((n) => Object.hasOwn(t, n) &&
|
|
40
|
+
return n.length === Object.keys(t).length && n.every((n) => Object.hasOwn(t, n) && x(e[n], t[n]));
|
|
41
41
|
}
|
|
42
|
-
function
|
|
42
|
+
function Ge(e) {
|
|
43
43
|
let t = f(e);
|
|
44
|
-
return
|
|
44
|
+
return x(t.current, e) || (t.current = e), t.current;
|
|
45
45
|
}
|
|
46
|
-
function
|
|
46
|
+
function S(e, t, n, r) {
|
|
47
47
|
let [i, a] = p(t), o = e === void 0 ? i : e, s = f({
|
|
48
48
|
controlled: e,
|
|
49
49
|
value: o,
|
|
@@ -63,37 +63,37 @@ function x(e, t, n, r) {
|
|
|
63
63
|
}).request(e, t, n) && a(e);
|
|
64
64
|
}, [r])];
|
|
65
65
|
}
|
|
66
|
-
var
|
|
66
|
+
var Ke = {
|
|
67
67
|
crosshair: null,
|
|
68
68
|
markers: [],
|
|
69
69
|
tooltip: null,
|
|
70
70
|
docked: !1
|
|
71
71
|
};
|
|
72
|
-
function
|
|
72
|
+
function qe(e) {
|
|
73
73
|
try {
|
|
74
74
|
return e.matches(":focus-visible");
|
|
75
75
|
} catch {
|
|
76
76
|
return !1;
|
|
77
77
|
}
|
|
78
78
|
}
|
|
79
|
-
function
|
|
79
|
+
function Je(e) {
|
|
80
80
|
for (let t = e.length - 1; t >= 0; --t) if (e[t] !== null) return t;
|
|
81
81
|
return -1;
|
|
82
82
|
}
|
|
83
|
-
function
|
|
83
|
+
function Ye(e) {
|
|
84
84
|
return e.type === "slot" ? { "data-slot": String(e.slot) } : e.type === "tone" ? { "data-tone": e.tone } : { "data-overflow": "" };
|
|
85
85
|
}
|
|
86
|
-
function
|
|
86
|
+
function Xe(e) {
|
|
87
87
|
return Object.fromEntries(Object.entries(e).map(([e, t]) => [e, `${t}px`]));
|
|
88
88
|
}
|
|
89
|
-
function
|
|
89
|
+
function Ze(e, t = !0) {
|
|
90
90
|
let n = f(null), r = f(null), [i, a] = p(!1), o = (i) => {
|
|
91
91
|
let o = i.newState === "open";
|
|
92
92
|
a(o);
|
|
93
93
|
let s = r.current, c = n.current;
|
|
94
94
|
if (s && c) {
|
|
95
95
|
if (o) {
|
|
96
|
-
let n = s.getBoundingClientRect(), r =
|
|
96
|
+
let n = s.getBoundingClientRect(), r = De({
|
|
97
97
|
anchor: c.getBoundingClientRect(),
|
|
98
98
|
size: {
|
|
99
99
|
width: n.width,
|
|
@@ -130,18 +130,18 @@ function Qe(e, t = !0) {
|
|
|
130
130
|
}
|
|
131
131
|
};
|
|
132
132
|
}
|
|
133
|
-
function
|
|
133
|
+
function C() {
|
|
134
134
|
let e = f(null), t = f(null);
|
|
135
135
|
return d(() => {
|
|
136
136
|
if (!e.current) return;
|
|
137
|
-
let n =
|
|
137
|
+
let n = Pe(e.current);
|
|
138
138
|
return t.current = n, () => n.destroy();
|
|
139
139
|
}, []), [e, () => t.current?.read() ?? "programmatic"];
|
|
140
140
|
}
|
|
141
|
-
function
|
|
141
|
+
function Qe(e, t) {
|
|
142
142
|
typeof e == "function" ? e(t) : e && typeof e == "object" && (e.current = t);
|
|
143
143
|
}
|
|
144
|
-
function
|
|
144
|
+
function $e({ context: e, model: t, totalLabel: n, indicator: r }) {
|
|
145
145
|
return /* @__PURE__ */ g(m, { children: [
|
|
146
146
|
/* @__PURE__ */ h("div", {
|
|
147
147
|
"data-part": "tooltip-title",
|
|
@@ -154,12 +154,12 @@ function et({ context: e, model: t, totalLabel: n, indicator: r }) {
|
|
|
154
154
|
children: e
|
|
155
155
|
}, e)),
|
|
156
156
|
e.items.map((n) => {
|
|
157
|
-
let i =
|
|
157
|
+
let i = y(t, n.series), a = r === "line" || n.kind === "line" ? "line" : n.kind === "scatter" ? "scatter" : "bar";
|
|
158
158
|
return /* @__PURE__ */ u("div", {
|
|
159
159
|
"data-part": "tooltip-item",
|
|
160
160
|
"data-part-tooltip-item": "",
|
|
161
161
|
...e.items.length > 1 && n.current ? { "data-current": "" } : {},
|
|
162
|
-
...
|
|
162
|
+
...Ye(n.color),
|
|
163
163
|
key: `${n.series}-${n.label}`
|
|
164
164
|
}, r === "none" ? null : /* @__PURE__ */ h("span", {
|
|
165
165
|
"data-kind": a,
|
|
@@ -187,45 +187,45 @@ function et({ context: e, model: t, totalLabel: n, indicator: r }) {
|
|
|
187
187
|
}) : null
|
|
188
188
|
] });
|
|
189
189
|
}
|
|
190
|
-
function
|
|
191
|
-
let { data: l, series: ne, x:
|
|
192
|
-
size:
|
|
193
|
-
variant:
|
|
194
|
-
palette:
|
|
195
|
-
toolbar:
|
|
196
|
-
renderer:
|
|
197
|
-
grid:
|
|
198
|
-
legendOverflow:
|
|
199
|
-
animate:
|
|
190
|
+
function w(c) {
|
|
191
|
+
let { data: l, series: ne, x: De, y: Pe, orientation: Ie, stackMode: b, annotations: Re, recordKey: We, locale: x, title: C, description: w, help: T, actions: ot, messages: st, size: ct, variant: lt, palette: ut, toolbar: dt, grid: ft, texture: pt, renderer: mt, sampling: ht, animate: gt, legend: _t, legendInteractive: vt, legendValues: yt, legendOverflow: bt, trigger: xt, tooltip: St, zoomable: E, selectable: Ct, rangeSelectable: D, loading: wt, error: Tt, onRetry: Et, hidden: Dt, defaultHidden: Ot, onHiddenChange: kt, activePoint: At, defaultActivePoint: jt, onActivePointChange: Mt, selection: Nt, defaultSelection: Pt, onSelectionChange: Ft, range: It, defaultRange: Lt, onRangeChange: Rt, zoom: zt, defaultZoom: Bt, onZoomChange: Vt, tableOpen: Ht, defaultTableOpen: Ut, onTableOpenChange: Wt, fullscreen: Gt, defaultFullscreen: Kt, onFullscreenChange: qt, renderTooltip: Jt, renderLegendItem: Yt, renderCenter: Xt, renderEmpty: Zt, renderError: Qt, render: $t, extendOption: en, handleRef: tn, ref: nn, ...rn } = c, O = Le(), k = re(), A = t(ce, st), an = e(), j = {
|
|
192
|
+
size: ct ?? O.size ?? "md",
|
|
193
|
+
variant: lt ?? O.variant ?? "plain",
|
|
194
|
+
palette: ut ?? O.palette ?? "categorical",
|
|
195
|
+
toolbar: dt ?? O.toolbar ?? "visible",
|
|
196
|
+
renderer: mt ?? O.renderer ?? "auto",
|
|
197
|
+
grid: ft ?? O.grid,
|
|
198
|
+
legendOverflow: bt ?? O.legendOverflow ?? "collapse",
|
|
199
|
+
animate: gt ?? O.animate ?? !0,
|
|
200
200
|
tooltip: {
|
|
201
|
-
...
|
|
202
|
-
...
|
|
201
|
+
...O.tooltip,
|
|
202
|
+
...St
|
|
203
203
|
}
|
|
204
|
-
}, [
|
|
204
|
+
}, [on, sn] = S(Dt, Ot ?? ze, kt, Ve), [M, N] = S(At, jt ?? null, Mt, Be), [P, cn] = S(Nt, Pt ?? null, Ft, Be), [ln, un] = S(It, Lt ?? null, Rt, Ue), [dn, F] = S(zt, Bt ?? _, Vt, He), [I, fn] = S(Ht, Ut ?? !1, Wt, Object.is), [L, pn] = S(Gt, Kt ?? !1, qt, Object.is), mn = Ge(ne), hn = Ge(De), gn = Ge(Pe), _n = Ge(Re), vn = oe(() => ({
|
|
205
205
|
data: l,
|
|
206
206
|
series: mn,
|
|
207
207
|
x: hn,
|
|
208
208
|
y: gn,
|
|
209
|
-
orientation:
|
|
210
|
-
stackMode:
|
|
209
|
+
orientation: Ie,
|
|
210
|
+
stackMode: b,
|
|
211
211
|
annotations: _n,
|
|
212
|
-
recordKey:
|
|
213
|
-
locale:
|
|
212
|
+
recordKey: We,
|
|
213
|
+
locale: x ?? an
|
|
214
214
|
}), [
|
|
215
215
|
l,
|
|
216
216
|
mn,
|
|
217
217
|
hn,
|
|
218
218
|
gn,
|
|
219
|
-
|
|
220
|
-
|
|
219
|
+
Ie,
|
|
220
|
+
b,
|
|
221
221
|
_n,
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
222
|
+
We,
|
|
223
|
+
x,
|
|
224
|
+
an
|
|
225
225
|
]), yn = oe(() => {
|
|
226
226
|
try {
|
|
227
227
|
return {
|
|
228
|
-
model:
|
|
228
|
+
model: ge(vn, { hidden: on }),
|
|
229
229
|
failure: null
|
|
230
230
|
};
|
|
231
231
|
} catch (e) {
|
|
@@ -234,21 +234,21 @@ function C(c) {
|
|
|
234
234
|
failure: e
|
|
235
235
|
};
|
|
236
236
|
}
|
|
237
|
-
}, [vn,
|
|
237
|
+
}, [vn, on]), R = yn.model, [bn, xn] = p(null), z = !!Tt || yn.failure !== null || bn !== null, B = !!wt, V = !(!R || B || z || R.empty), H = !(!R || B || z || R.empty === "no-data"), U = R ? xt ?? ye(R) : "none", W = f(null), G = f(null), Sn = f(null), Cn = f(null), wn = f(null), K = f(null), [Tn, En] = p(null), [q, Dn] = p(Ke), On = oe(() => _e((e) => le().announce(e)), []), kn = (e) => le().announce(e);
|
|
238
238
|
d(() => {
|
|
239
239
|
let e = G.current;
|
|
240
240
|
if (!e) return;
|
|
241
|
-
let t = e.ownerDocument.defaultView, n = (e) => En((t) =>
|
|
241
|
+
let t = e.ownerDocument.defaultView, n = (e) => En((t) => je(t, e) ? t : e), r = () => n(Ae(e)), i = de(e), a = 0;
|
|
242
242
|
i ? n(i) : t && (a = t.requestAnimationFrame(() => {
|
|
243
243
|
a = 0, r();
|
|
244
244
|
}));
|
|
245
|
-
let o =
|
|
245
|
+
let o = Ee(e, r);
|
|
246
246
|
return () => {
|
|
247
247
|
o(), a && t?.cancelAnimationFrame(a);
|
|
248
248
|
};
|
|
249
249
|
}, [
|
|
250
|
-
|
|
251
|
-
|
|
250
|
+
j.palette,
|
|
251
|
+
j.variant,
|
|
252
252
|
L
|
|
253
253
|
]);
|
|
254
254
|
let J = f({
|
|
@@ -260,7 +260,7 @@ function C(c) {
|
|
|
260
260
|
d(() => {
|
|
261
261
|
let e = Sn.current;
|
|
262
262
|
if (!e) return;
|
|
263
|
-
let t =
|
|
263
|
+
let t = Fe(e, {
|
|
264
264
|
onPointer: (e, t) => J.current.onPointer(e, t),
|
|
265
265
|
onPress: (e, t) => J.current.onPress(e, t),
|
|
266
266
|
onZoom: (e, t) => J.current.onZoom(e, t),
|
|
@@ -274,45 +274,45 @@ function C(c) {
|
|
|
274
274
|
K.current && Tn && R && V && K.current.update({
|
|
275
275
|
model: R,
|
|
276
276
|
theme: Tn,
|
|
277
|
-
selection:
|
|
278
|
-
zoom:
|
|
279
|
-
zoomable: !!
|
|
280
|
-
range:
|
|
281
|
-
rangeSelectable: !!
|
|
282
|
-
grid:
|
|
283
|
-
texture: !!
|
|
284
|
-
renderer:
|
|
285
|
-
sampling:
|
|
277
|
+
selection: P,
|
|
278
|
+
zoom: dn,
|
|
279
|
+
zoomable: !!E,
|
|
280
|
+
range: D ? ln : null,
|
|
281
|
+
rangeSelectable: !!D,
|
|
282
|
+
grid: j.grid,
|
|
283
|
+
texture: !!pt,
|
|
284
|
+
renderer: j.renderer,
|
|
285
|
+
sampling: ht,
|
|
286
286
|
trigger: U,
|
|
287
|
-
animate:
|
|
288
|
-
extendOption:
|
|
287
|
+
animate: j.animate,
|
|
288
|
+
extendOption: en
|
|
289
289
|
});
|
|
290
290
|
}, [
|
|
291
291
|
R,
|
|
292
292
|
Tn,
|
|
293
293
|
V,
|
|
294
|
-
M,
|
|
295
294
|
P,
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
295
|
+
dn,
|
|
296
|
+
E,
|
|
297
|
+
ln,
|
|
298
|
+
D,
|
|
299
|
+
j.grid,
|
|
300
|
+
pt,
|
|
301
|
+
j.renderer,
|
|
302
|
+
ht,
|
|
303
303
|
U,
|
|
304
|
-
|
|
305
|
-
|
|
304
|
+
j.animate,
|
|
305
|
+
en
|
|
306
306
|
]);
|
|
307
307
|
let An = () => {
|
|
308
308
|
let e = K.current, t = G.current;
|
|
309
309
|
if (!e || !t || !R || !V || I) {
|
|
310
|
-
Dn(
|
|
310
|
+
Dn(Ke);
|
|
311
311
|
return;
|
|
312
312
|
}
|
|
313
313
|
let n = [];
|
|
314
|
-
if (
|
|
315
|
-
let t =
|
|
314
|
+
if (P && v(R, P) && R.shape === "cartesian") {
|
|
315
|
+
let t = y(R, P.series), r = e.locate(P);
|
|
316
316
|
t && t.kind !== "bar" && r && n.push({
|
|
317
317
|
key: `selected-${t.id}`,
|
|
318
318
|
color: t.color,
|
|
@@ -321,9 +321,9 @@ function C(c) {
|
|
|
321
321
|
current: !1
|
|
322
322
|
});
|
|
323
323
|
}
|
|
324
|
-
R.shape === "pie" && e.emphasize(
|
|
325
|
-
let r =
|
|
326
|
-
if (!
|
|
324
|
+
R.shape === "pie" && e.emphasize(M && v(R, M) ? M.key : null);
|
|
325
|
+
let r = M && v(R, M) ? e.locate(M) : null;
|
|
326
|
+
if (!M || !r) {
|
|
327
327
|
Dn({
|
|
328
328
|
crosshair: null,
|
|
329
329
|
markers: n,
|
|
@@ -337,39 +337,39 @@ function C(c) {
|
|
|
337
337
|
isBand: i && R.xType === "category"
|
|
338
338
|
} : null;
|
|
339
339
|
if (R.shape === "cartesian") {
|
|
340
|
-
let t =
|
|
340
|
+
let t = fe(R, M.key), r = U === "axis" ? R.series.filter((e) => e.visible && e.kind !== "bar" && e.values[t] !== null) : [y(R, M.series)].filter((e) => !!(e && e.kind !== "bar"));
|
|
341
341
|
for (let t of r) {
|
|
342
342
|
let r = e.locate({
|
|
343
343
|
series: t.id,
|
|
344
|
-
key:
|
|
344
|
+
key: M.key
|
|
345
345
|
});
|
|
346
346
|
r && n.push({
|
|
347
347
|
key: t.id,
|
|
348
348
|
color: t.color,
|
|
349
349
|
at: r,
|
|
350
350
|
selected: !1,
|
|
351
|
-
current: t.id ===
|
|
351
|
+
current: t.id === M.series
|
|
352
352
|
});
|
|
353
353
|
}
|
|
354
354
|
}
|
|
355
|
-
let o = U === "none" ? null :
|
|
355
|
+
let o = U === "none" ? null : Ne(R, M, {
|
|
356
356
|
trigger: U,
|
|
357
|
-
sort:
|
|
358
|
-
total:
|
|
359
|
-
totalLabel:
|
|
357
|
+
sort: j.tooltip.sort,
|
|
358
|
+
total: j.tooltip.total,
|
|
359
|
+
totalLabel: A("total")
|
|
360
360
|
});
|
|
361
361
|
Dn({
|
|
362
362
|
crosshair: a,
|
|
363
363
|
markers: n,
|
|
364
364
|
tooltip: o,
|
|
365
|
-
docked: t.clientWidth <
|
|
365
|
+
docked: t.clientWidth < ue
|
|
366
366
|
});
|
|
367
367
|
};
|
|
368
368
|
ae(() => {
|
|
369
369
|
An();
|
|
370
370
|
}, [
|
|
371
|
-
A,
|
|
372
371
|
M,
|
|
372
|
+
P,
|
|
373
373
|
R,
|
|
374
374
|
V,
|
|
375
375
|
I,
|
|
@@ -379,14 +379,14 @@ function C(c) {
|
|
|
379
379
|
ae(() => {
|
|
380
380
|
let e = Cn.current, t = G.current;
|
|
381
381
|
if (!e || !t) return;
|
|
382
|
-
if (!q.tooltip || !
|
|
382
|
+
if (!q.tooltip || !M) {
|
|
383
383
|
jn.current = !1;
|
|
384
384
|
return;
|
|
385
385
|
}
|
|
386
|
-
let n = K.current?.locate(
|
|
386
|
+
let n = K.current?.locate(M);
|
|
387
387
|
if (!n) return;
|
|
388
388
|
jn.current || (e.style.transition = "none");
|
|
389
|
-
let r =
|
|
389
|
+
let r = Oe({
|
|
390
390
|
anchor: {
|
|
391
391
|
x: n.x,
|
|
392
392
|
y: n.y
|
|
@@ -402,49 +402,50 @@ function C(c) {
|
|
|
402
402
|
dir: W.current && getComputedStyle(W.current).direction === "rtl" ? "rtl" : "ltr"
|
|
403
403
|
});
|
|
404
404
|
e.style.setProperty("--slotted-chart-x", `${r.x}px`), e.style.setProperty("--slotted-chart-y", `${r.y}px`), jn.current || requestAnimationFrame(() => e.style.transition = ""), jn.current = !0;
|
|
405
|
-
}, [q,
|
|
406
|
-
let Mn = oe(
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
405
|
+
}, [q, M]);
|
|
406
|
+
let Mn = oe(ve, []), Nn = (e) => {
|
|
407
|
+
let t = e.pointerType === "touch";
|
|
408
|
+
if (!D || e.button !== 0 || e.shiftKey || !Mn.press(t)) return;
|
|
409
|
+
let n = e.currentTarget.ownerDocument.defaultView, r = (e) => {
|
|
410
|
+
n?.removeEventListener("pointerup", r), n?.removeEventListener("pointercancel", r), e.type === "pointercancel" ? Mn.cancel() : Mn.release() && ln && (un(null, "pointer", e), t && N(null, "pointer", e));
|
|
410
411
|
};
|
|
411
|
-
|
|
412
|
+
n?.addEventListener("pointerup", r), n?.addEventListener("pointercancel", r);
|
|
412
413
|
};
|
|
413
414
|
J.current = {
|
|
414
415
|
onPointer: (e, t) => {
|
|
415
|
-
let n =
|
|
416
|
-
n &&
|
|
416
|
+
let n = D && R ? Mn.point(R, e?.key ?? null) : void 0;
|
|
417
|
+
n && un(n, "pointer", t), e ? N(e, "pointer", t) : (!G.current || !qe(G.current)) && N(null, "pointer", t);
|
|
417
418
|
},
|
|
418
419
|
onPress: (e, t) => {
|
|
419
|
-
|
|
420
|
+
Ct && e && cn(Be(P, e) ? null : e, "pointer", t);
|
|
420
421
|
},
|
|
421
422
|
onZoom: (e, t) => F(e, "pointer", t),
|
|
422
423
|
onRender: () => An()
|
|
423
424
|
};
|
|
424
425
|
let Pn = (e) => {
|
|
425
426
|
if (!R || !V || I) return;
|
|
426
|
-
let t =
|
|
427
|
-
active:
|
|
428
|
-
selection:
|
|
429
|
-
zoom:
|
|
430
|
-
zoomable: !!
|
|
431
|
-
selectable: !!
|
|
432
|
-
range:
|
|
433
|
-
rangeSelectable: !!
|
|
427
|
+
let t = pe(R, {
|
|
428
|
+
active: M,
|
|
429
|
+
selection: P,
|
|
430
|
+
zoom: dn,
|
|
431
|
+
zoomable: !!E,
|
|
432
|
+
selectable: !!Ct,
|
|
433
|
+
range: ln,
|
|
434
|
+
rangeSelectable: !!D
|
|
434
435
|
}, e.key, e.shiftKey);
|
|
435
436
|
if (t !== null) {
|
|
436
437
|
e.preventDefault();
|
|
437
|
-
for (let n of t) n.type === "active" ? (
|
|
438
|
+
for (let n of t) n.type === "active" ? (N(n.point, n.reason, e.nativeEvent), n.point ? On.say(xe(R, n.point, P, A)) : On.cancel()) : n.type === "select" ? (cn(n.point, "keyboard", e.nativeEvent), n.point && On.say(xe(R, n.point, n.point, A))) : n.type === "range" ? (un(n.range, n.reason, e.nativeEvent), kn(Se(R, n.range, A))) : (F(n.zoom, n.reason, e.nativeEvent), kn(Ce(R, n.zoom, A)));
|
|
438
439
|
}
|
|
439
440
|
}, Fn = te((e) => e === null ? void 0 : s(e).destroy, []), In = (e) => {
|
|
440
|
-
if (!R || !V || I ||
|
|
441
|
-
let t =
|
|
442
|
-
t && (
|
|
441
|
+
if (!R || !V || I || M || !qe(e.currentTarget)) return;
|
|
442
|
+
let t = we(R);
|
|
443
|
+
t && (N(t, "keyboard", e.nativeEvent), On.say(xe(R, t, P, A)));
|
|
443
444
|
}, Ln = (e, t) => {
|
|
444
445
|
let n = !L;
|
|
445
446
|
pn(n, e, t);
|
|
446
447
|
let r = W.current;
|
|
447
|
-
r && (n &&
|
|
448
|
+
r && (n && Gt === void 0 && document.fullscreenEnabled && e !== "programmatic" && r.requestFullscreen?.().catch(() => {}), !n && document.fullscreenElement === r && document.exitFullscreen().catch(() => {}));
|
|
448
449
|
};
|
|
449
450
|
d(() => {
|
|
450
451
|
let e = W.current;
|
|
@@ -460,11 +461,11 @@ function C(c) {
|
|
|
460
461
|
!L && e && document.fullscreenElement === e && document.exitFullscreen().catch(() => {});
|
|
461
462
|
}, [L]);
|
|
462
463
|
let zn = (e) => {
|
|
463
|
-
|
|
464
|
-
}, [Y, Bn] = p([]), Vn = f(/* @__PURE__ */ new Map()), [Hn, Un] = p(null), Wn =
|
|
464
|
+
rn.onKeyDown?.(e), !e.defaultPrevented && e.key === "Escape" && L && (e.preventDefault(), Ln("escape", e.nativeEvent));
|
|
465
|
+
}, [Y, Bn] = p([]), Vn = f(/* @__PURE__ */ new Map()), [Hn, Un] = p(null), Wn = vt ?? !0, X = R?.legend ?? [], Gn = () => {
|
|
465
466
|
let e = wn.current;
|
|
466
467
|
if (!e || !R) return;
|
|
467
|
-
if (
|
|
468
|
+
if (j.legendOverflow === "wrap") {
|
|
468
469
|
Bn((e) => e.length ? [] : e);
|
|
469
470
|
return;
|
|
470
471
|
}
|
|
@@ -485,9 +486,9 @@ function C(c) {
|
|
|
485
486
|
Gn();
|
|
486
487
|
}, [
|
|
487
488
|
X,
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
489
|
+
j.legendOverflow,
|
|
490
|
+
yt,
|
|
491
|
+
M
|
|
491
492
|
]), d(() => {
|
|
492
493
|
let e = wn.current;
|
|
493
494
|
if (!e || typeof ResizeObserver > "u") return;
|
|
@@ -497,16 +498,16 @@ function C(c) {
|
|
|
497
498
|
let Kn = f(Gn);
|
|
498
499
|
Kn.current = Gn;
|
|
499
500
|
let qn = (e, t, n, r) => {
|
|
500
|
-
let i = X.map((e) => e.key), a =
|
|
501
|
-
Un(e.key),
|
|
502
|
-
}, Z =
|
|
501
|
+
let i = X.map((e) => e.key), a = Me(i, on, e.key, t);
|
|
502
|
+
Un(e.key), sn(a, n, r), kn(A(a.includes(e.key) ? "hidden" : "shown", { series: e.label }));
|
|
503
|
+
}, Z = M && R && v(R, M) ? M.key : null, Jn = (e) => {
|
|
503
504
|
if (!R) return "";
|
|
504
|
-
let t = R.shape === "pie" ? R.series[0] :
|
|
505
|
+
let t = R.shape === "pie" ? R.series[0] : y(R, e.key);
|
|
505
506
|
if (!t) return "";
|
|
506
|
-
let n = R.shape === "pie" ?
|
|
507
|
-
return n >= 0 ?
|
|
508
|
-
}, Yn =
|
|
509
|
-
let r = R?.shape === "pie" ? R.series[0] : R ?
|
|
507
|
+
let n = R.shape === "pie" ? fe(R, e.key) : Z ? fe(R, Z) : Je(t.values);
|
|
508
|
+
return n >= 0 ? ke(t, n) : "";
|
|
509
|
+
}, Yn = Ze("start"), Xn = X.filter((e, t) => !Y.includes(t)).map((e) => e.key), Zn = Hn && Xn.includes(Hn) ? Hn : Xn[0] ?? null, Qn = (e, t, n) => {
|
|
510
|
+
let r = R?.shape === "pie" ? R.series[0] : R ? y(R, e.key) : void 0, i = R?.shape === "pie" ? e.key === Z : M?.series === e.key && Z !== null, o = !n && Y.includes(t), s = /* @__PURE__ */ g(m, { children: [
|
|
510
511
|
/* @__PURE__ */ h("span", {
|
|
511
512
|
"data-kind": e.kind === "area" || e.kind === "bar" || e.kind === "pie" || e.kind === "range" ? "bar" : e.kind,
|
|
512
513
|
"data-part": "legend-marker",
|
|
@@ -519,7 +520,7 @@ function C(c) {
|
|
|
519
520
|
title: e.label,
|
|
520
521
|
children: e.label
|
|
521
522
|
}),
|
|
522
|
-
|
|
523
|
+
yt ? /* @__PURE__ */ h("span", {
|
|
523
524
|
"data-part": "legend-value",
|
|
524
525
|
"data-part-legend-value": "",
|
|
525
526
|
children: Jn(e)
|
|
@@ -528,12 +529,12 @@ function C(c) {
|
|
|
528
529
|
"data-part": "legend-item",
|
|
529
530
|
...a("part", "legend-item"),
|
|
530
531
|
"data-key": e.key,
|
|
531
|
-
...
|
|
532
|
+
...Ye(e.color),
|
|
532
533
|
...i ? { "data-current": "" } : {},
|
|
533
534
|
hidden: o,
|
|
534
535
|
onPointerEnter: () => e.visible && K.current?.emphasize(e.key),
|
|
535
536
|
onPointerLeave: () => K.current?.emphasize(null)
|
|
536
|
-
}, l = Wn ? /* @__PURE__ */ u(
|
|
537
|
+
}, l = Wn ? /* @__PURE__ */ u(et, {
|
|
537
538
|
...c,
|
|
538
539
|
entry: e,
|
|
539
540
|
focused: n || Zn === e.key,
|
|
@@ -548,7 +549,7 @@ function C(c) {
|
|
|
548
549
|
key: `${n ? "layer" : "row"}-${e.key}`,
|
|
549
550
|
role: "listitem"
|
|
550
551
|
}, s);
|
|
551
|
-
return
|
|
552
|
+
return Yt ? /* @__PURE__ */ h(ee, { children: Yt(e, c, l) }, `${n ? "layer" : "row"}-${e.key}`) : l;
|
|
552
553
|
}, $n = (e) => {
|
|
553
554
|
let t = e.target;
|
|
554
555
|
if (t.closest("[data-part=\"menu\"]")) return;
|
|
@@ -556,79 +557,79 @@ function C(c) {
|
|
|
556
557
|
if (r === -1) return;
|
|
557
558
|
let i = W.current ? getComputedStyle(W.current).direction === "rtl" : !1, a = e.key === "ArrowRight" ? i ? -1 : 1 : e.key === "ArrowLeft" ? i ? 1 : -1 : 0, o;
|
|
558
559
|
a && (o = n[(r + a + n.length) % n.length]), e.key === "Home" && (o = n[0]), e.key === "End" && (o = n[n.length - 1]), o && (e.preventDefault(), Un(o.dataset.key ?? "__more"), o.focus());
|
|
559
|
-
}, Q =
|
|
560
|
+
}, Q = Ze("end"), er = Ze("start", !1), tr = (e, t) => {
|
|
560
561
|
let n = document.createElement("a");
|
|
561
562
|
n.href = t, n.download = e, document.body.append(n), n.click(), n.remove();
|
|
562
|
-
}, nr = typeof
|
|
563
|
-
ie(
|
|
563
|
+
}, nr = typeof C == "string" ? C : "chart";
|
|
564
|
+
ie(tn, () => ({
|
|
564
565
|
focus: () => G.current?.focus(),
|
|
565
|
-
resetZoom: () => F(
|
|
566
|
+
resetZoom: () => F(_, "programmatic"),
|
|
566
567
|
toDataURL: () => K.current?.toDataURL() ?? null,
|
|
567
|
-
toCsv: () => R ?
|
|
568
|
+
toCsv: () => R ? he(R, A) : ""
|
|
568
569
|
}), [
|
|
569
570
|
R,
|
|
570
|
-
|
|
571
|
+
A,
|
|
571
572
|
F
|
|
572
573
|
]);
|
|
573
|
-
let rr = B ?
|
|
574
|
-
xn(null),
|
|
575
|
-
}, lr =
|
|
574
|
+
let rr = B ? A("loading") : z ? A("error") : R ? be(R, A) : "", ir = `${k}-title`, ar = `${k}-description`, or = `${k}-summary`, sr = vn.series.some((e) => e.kind === "pie") ? "pie" : vn.series.every((e) => e.kind === "line" || e.kind === "area" || e.kind === "range") ? "line" : "bar", $ = I && H && R ? me(R, A) : null, cr = () => {
|
|
575
|
+
xn(null), Et?.();
|
|
576
|
+
}, lr = C !== void 0 || w !== void 0 || ot !== void 0 || j.toolbar !== "none" ? /* @__PURE__ */ g("figcaption", {
|
|
576
577
|
"data-part": "header",
|
|
577
578
|
"data-part-header": "",
|
|
578
579
|
children: [
|
|
579
|
-
/* @__PURE__ */ g("div", { children: [/* @__PURE__ */ g("div", { children: [
|
|
580
|
+
/* @__PURE__ */ g("div", { children: [/* @__PURE__ */ g("div", { children: [C === void 0 ? null : /* @__PURE__ */ h("span", {
|
|
580
581
|
"data-part": "title",
|
|
581
582
|
"data-part-title": "",
|
|
582
583
|
id: ir,
|
|
583
|
-
children:
|
|
584
|
-
}),
|
|
584
|
+
children: C
|
|
585
|
+
}), T === void 0 ? null : /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ h("button", {
|
|
585
586
|
...o(er.controlProps, "part", "help"),
|
|
586
|
-
"aria-controls": `${
|
|
587
|
-
"aria-label":
|
|
587
|
+
"aria-controls": `${k}-help`,
|
|
588
|
+
"aria-label": A("help"),
|
|
588
589
|
type: "button",
|
|
589
590
|
children: /* @__PURE__ */ h(r, { children: /* @__PURE__ */ h(n, { name: "circle-info" }) })
|
|
590
591
|
}), /* @__PURE__ */ h("div", {
|
|
591
592
|
...o(er.layerProps, "part", "help-content"),
|
|
592
|
-
id: `${
|
|
593
|
+
id: `${k}-help`,
|
|
593
594
|
role: "note",
|
|
594
|
-
children:
|
|
595
|
-
})] })] }),
|
|
595
|
+
children: T
|
|
596
|
+
})] })] }), w === void 0 ? null : /* @__PURE__ */ h("span", {
|
|
596
597
|
"data-part": "description",
|
|
597
598
|
"data-part-description": "",
|
|
598
599
|
id: ar,
|
|
599
|
-
children:
|
|
600
|
+
children: w
|
|
600
601
|
})] }),
|
|
601
|
-
|
|
602
|
+
ot === void 0 ? null : /* @__PURE__ */ h("div", {
|
|
602
603
|
"data-part": "actions",
|
|
603
604
|
"data-part-actions": "",
|
|
604
|
-
children:
|
|
605
|
+
children: ot
|
|
605
606
|
}),
|
|
606
|
-
|
|
607
|
+
j.toolbar === "none" ? null : /* @__PURE__ */ g("div", {
|
|
607
608
|
"aria-hidden": !H || void 0,
|
|
608
|
-
"aria-label": H ?
|
|
609
|
+
"aria-label": H ? A("toolbar") : void 0,
|
|
609
610
|
"data-part": "toolbar",
|
|
610
611
|
"data-part-toolbar": "",
|
|
611
612
|
"data-waiting": H ? void 0 : "",
|
|
612
613
|
inert: !H,
|
|
613
614
|
role: H ? "toolbar" : void 0,
|
|
614
615
|
children: [
|
|
615
|
-
R &&
|
|
616
|
-
label:
|
|
616
|
+
R && E && !Te(dn) && R.shape === "cartesian" ? /* @__PURE__ */ h(tt, {
|
|
617
|
+
label: A("resetZoom"),
|
|
617
618
|
onPress: (e, t) => {
|
|
618
|
-
F(
|
|
619
|
+
F(_, "clear", t), kn(Ce(R, _, A)), G.current?.focus();
|
|
619
620
|
},
|
|
620
621
|
glyph: "rotate-ccw",
|
|
621
622
|
part: "zoom-reset"
|
|
622
623
|
}) : null,
|
|
623
|
-
/* @__PURE__ */ h(
|
|
624
|
-
label:
|
|
624
|
+
/* @__PURE__ */ h(tt, {
|
|
625
|
+
label: A("tableView"),
|
|
625
626
|
onPress: (e, t) => fn(!I, e, t),
|
|
626
627
|
glyph: "file-spreadsheet",
|
|
627
628
|
part: "view-toggle",
|
|
628
629
|
pressed: I
|
|
629
630
|
}),
|
|
630
|
-
/* @__PURE__ */ h(
|
|
631
|
-
label:
|
|
631
|
+
/* @__PURE__ */ h(tt, {
|
|
632
|
+
label: A(L ? "exitFullscreen" : "fullscreen"),
|
|
632
633
|
glyph: L ? "minimize" : "maximize",
|
|
633
634
|
onPress: (e, t) => Ln(e, t),
|
|
634
635
|
part: "fullscreen-toggle"
|
|
@@ -636,40 +637,40 @@ function C(c) {
|
|
|
636
637
|
/* @__PURE__ */ h("button", {
|
|
637
638
|
...o(Q.controlProps, "part", "menu-trigger"),
|
|
638
639
|
"aria-haspopup": "menu",
|
|
639
|
-
"aria-label":
|
|
640
|
-
title:
|
|
640
|
+
"aria-label": A("more"),
|
|
641
|
+
title: A("more"),
|
|
641
642
|
type: "button",
|
|
642
643
|
children: /* @__PURE__ */ h(r, { children: /* @__PURE__ */ h(n, { name: "ellipsis" }) })
|
|
643
644
|
}),
|
|
644
645
|
/* @__PURE__ */ g("div", {
|
|
645
646
|
...o(Q.layerProps, "part", "menu"),
|
|
646
|
-
"aria-label":
|
|
647
|
+
"aria-label": A("more"),
|
|
647
648
|
role: "menu",
|
|
648
649
|
children: [
|
|
649
|
-
/* @__PURE__ */ h(
|
|
650
|
+
/* @__PURE__ */ h(nt, {
|
|
650
651
|
action: "view",
|
|
651
|
-
label:
|
|
652
|
+
label: A("tableView"),
|
|
652
653
|
onPress: (e, t) => {
|
|
653
654
|
Q.close(), fn(!I, e, t);
|
|
654
655
|
}
|
|
655
656
|
}),
|
|
656
|
-
/* @__PURE__ */ h(
|
|
657
|
+
/* @__PURE__ */ h(nt, {
|
|
657
658
|
action: "fullscreen",
|
|
658
|
-
label:
|
|
659
|
+
label: A(L ? "exitFullscreen" : "fullscreen"),
|
|
659
660
|
onPress: (e, t) => {
|
|
660
661
|
Q.close(), Ln(e, t);
|
|
661
662
|
}
|
|
662
663
|
}),
|
|
663
|
-
/* @__PURE__ */ h(
|
|
664
|
+
/* @__PURE__ */ h(nt, {
|
|
664
665
|
action: "csv",
|
|
665
|
-
label:
|
|
666
|
+
label: A("downloadCsv"),
|
|
666
667
|
onPress: () => {
|
|
667
|
-
Q.close(), R && tr(`${nr}.csv`, `data:text/csv;charset=utf-8,${encodeURIComponent(
|
|
668
|
+
Q.close(), R && tr(`${nr}.csv`, `data:text/csv;charset=utf-8,${encodeURIComponent(he(R, A))}`);
|
|
668
669
|
}
|
|
669
670
|
}),
|
|
670
|
-
/* @__PURE__ */ h(
|
|
671
|
+
/* @__PURE__ */ h(nt, {
|
|
671
672
|
action: "image",
|
|
672
|
-
label:
|
|
673
|
+
label: A("downloadImage"),
|
|
673
674
|
onPress: () => {
|
|
674
675
|
Q.close();
|
|
675
676
|
let e = K.current?.toDataURL();
|
|
@@ -681,31 +682,31 @@ function C(c) {
|
|
|
681
682
|
]
|
|
682
683
|
})
|
|
683
684
|
]
|
|
684
|
-
}) : null, ur =
|
|
685
|
-
"aria-label": B && (!R || R.shape === "pie") ? void 0 :
|
|
685
|
+
}) : null, ur = _t === !1 ? null : /* @__PURE__ */ h("div", {
|
|
686
|
+
"aria-label": B && (!R || R.shape === "pie") ? void 0 : A("legend"),
|
|
686
687
|
"data-part": "legend",
|
|
687
688
|
"data-part-legend": "",
|
|
688
689
|
onKeyDown: $n,
|
|
689
690
|
ref: wn,
|
|
690
691
|
role: B && (!R || R.shape === "pie") ? void 0 : Wn ? "toolbar" : "list",
|
|
691
692
|
children: B && (!R || R.shape === "pie") ? /* @__PURE__ */ g(m, { children: [
|
|
692
|
-
/* @__PURE__ */ h(
|
|
693
|
-
/* @__PURE__ */ h(
|
|
694
|
-
/* @__PURE__ */ h(
|
|
693
|
+
/* @__PURE__ */ h(rt, {}),
|
|
694
|
+
/* @__PURE__ */ h(rt, {}),
|
|
695
|
+
/* @__PURE__ */ h(rt, {})
|
|
695
696
|
] }) : /* @__PURE__ */ g(m, { children: [
|
|
696
697
|
X.map((e, t) => Qn(e, t, !1)),
|
|
697
698
|
/* @__PURE__ */ h("button", {
|
|
698
699
|
...o(Yn.controlProps, "part", "legend-more"),
|
|
699
700
|
"aria-haspopup": "true",
|
|
700
|
-
"aria-label":
|
|
701
|
+
"aria-label": A("legendMore", { series: new Intl.ListFormat(x ?? an, { type: "unit" }).format(Y.map((e) => X[e]?.label ?? "")) }),
|
|
701
702
|
hidden: Y.length === 0,
|
|
702
703
|
tabIndex: Zn === null ? 0 : -1,
|
|
703
704
|
type: "button",
|
|
704
|
-
children:
|
|
705
|
+
children: A("moreSeries", { count: Y.length })
|
|
705
706
|
}),
|
|
706
707
|
/* @__PURE__ */ h("div", {
|
|
707
708
|
...o(Yn.layerProps, "part", "menu"),
|
|
708
|
-
"aria-label":
|
|
709
|
+
"aria-label": A("legend"),
|
|
709
710
|
role: "group",
|
|
710
711
|
children: Y.map((e) => {
|
|
711
712
|
let t = X[e];
|
|
@@ -714,32 +715,32 @@ function C(c) {
|
|
|
714
715
|
})
|
|
715
716
|
] })
|
|
716
717
|
}), dr = i({
|
|
717
|
-
...
|
|
718
|
+
...rn,
|
|
718
719
|
"data-ui": "chart",
|
|
719
720
|
"data-part": "root",
|
|
720
|
-
"data-size":
|
|
721
|
-
"data-variant":
|
|
722
|
-
"data-palette":
|
|
723
|
-
"data-toolbar":
|
|
724
|
-
"data-legend-overflow":
|
|
721
|
+
"data-size": j.size,
|
|
722
|
+
"data-variant": j.variant,
|
|
723
|
+
"data-palette": j.palette,
|
|
724
|
+
"data-toolbar": j.toolbar,
|
|
725
|
+
"data-legend-overflow": j.legendOverflow,
|
|
725
726
|
...B ? { "data-loading": "" } : {},
|
|
726
727
|
...L ? { "data-fullscreen": "" } : {},
|
|
727
728
|
onKeyDown: zn,
|
|
728
729
|
ref: (e) => {
|
|
729
|
-
W.current = e,
|
|
730
|
+
W.current = e, Qe(nn, e);
|
|
730
731
|
},
|
|
731
732
|
children: /* @__PURE__ */ g(m, { children: [
|
|
732
733
|
lr,
|
|
733
734
|
ur,
|
|
734
735
|
/* @__PURE__ */ g("div", {
|
|
735
736
|
"aria-busy": B || void 0,
|
|
736
|
-
"aria-describedby":
|
|
737
|
-
"aria-label":
|
|
738
|
-
"aria-labelledby":
|
|
739
|
-
"aria-roledescription":
|
|
737
|
+
"aria-describedby": w === void 0 ? or : `${ar} ${or}`,
|
|
738
|
+
"aria-label": C === void 0 ? rn["aria-label"] ?? A("roledescription") : void 0,
|
|
739
|
+
"aria-labelledby": C === void 0 ? void 0 : ir,
|
|
740
|
+
"aria-roledescription": A("roledescription"),
|
|
740
741
|
"data-part": "plot",
|
|
741
742
|
"data-part-plot": "",
|
|
742
|
-
onBlur: (e) =>
|
|
743
|
+
onBlur: (e) => N(null, "blur", e.nativeEvent),
|
|
743
744
|
onFocus: In,
|
|
744
745
|
onKeyDown: Pn,
|
|
745
746
|
onPointerDown: Nn,
|
|
@@ -753,7 +754,7 @@ function C(c) {
|
|
|
753
754
|
hidden: !q.crosshair,
|
|
754
755
|
...q.crosshair?.isBand ? { "data-band": "" } : {},
|
|
755
756
|
"data-orientation": R?.orientation ?? "vertical",
|
|
756
|
-
style: q.crosshair ?
|
|
757
|
+
style: q.crosshair ? Xe({
|
|
757
758
|
"--slotted-chart-x": q.crosshair.x,
|
|
758
759
|
"--slotted-chart-y": q.crosshair.y,
|
|
759
760
|
"--slotted-chart-band-start": q.crosshair.band.start,
|
|
@@ -773,10 +774,10 @@ function C(c) {
|
|
|
773
774
|
"aria-hidden": "true",
|
|
774
775
|
"data-part": "marker",
|
|
775
776
|
"data-part-marker": "",
|
|
776
|
-
...
|
|
777
|
+
...Ye(e.color),
|
|
777
778
|
...e.selected ? { "data-selected": "" } : {},
|
|
778
779
|
...e.current ? { "data-current": "" } : {},
|
|
779
|
-
style:
|
|
780
|
+
style: Xe({
|
|
780
781
|
"--slotted-chart-x": e.at.x,
|
|
781
782
|
"--slotted-chart-y": e.at.y
|
|
782
783
|
})
|
|
@@ -788,9 +789,9 @@ function C(c) {
|
|
|
788
789
|
ref: Cn,
|
|
789
790
|
...q.tooltip ? { "data-open": "" } : {},
|
|
790
791
|
...q.docked ? { "data-docked": "" } : {},
|
|
791
|
-
children: q.tooltip && R ?
|
|
792
|
+
children: q.tooltip && R ? Jt?.(q.tooltip, R) ?? /* @__PURE__ */ h($e, {
|
|
792
793
|
context: q.tooltip,
|
|
793
|
-
indicator:
|
|
794
|
+
indicator: j.tooltip.indicator,
|
|
794
795
|
model: R
|
|
795
796
|
}) : null
|
|
796
797
|
}),
|
|
@@ -798,18 +799,18 @@ function C(c) {
|
|
|
798
799
|
"aria-hidden": "true",
|
|
799
800
|
"data-part": "center",
|
|
800
801
|
"data-part-center": "",
|
|
801
|
-
children:
|
|
802
|
+
children: Xt?.(R) ?? /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ h("span", {
|
|
802
803
|
"data-part": "center-value",
|
|
803
804
|
"data-part-center-value": "",
|
|
804
805
|
children: R.series[0].format(R.total)
|
|
805
806
|
}), /* @__PURE__ */ h("span", {
|
|
806
807
|
"data-part": "center-label",
|
|
807
808
|
"data-part-center-label": "",
|
|
808
|
-
children:
|
|
809
|
+
children: A("total")
|
|
809
810
|
})] })
|
|
810
811
|
}) : null,
|
|
811
812
|
$ ? /* @__PURE__ */ h("div", {
|
|
812
|
-
"aria-labelledby":
|
|
813
|
+
"aria-labelledby": C === void 0 ? void 0 : ir,
|
|
813
814
|
"data-part": "table-region",
|
|
814
815
|
"data-part-table-region": "",
|
|
815
816
|
ref: Fn,
|
|
@@ -819,14 +820,14 @@ function C(c) {
|
|
|
819
820
|
"data-part": "table",
|
|
820
821
|
"data-part-table": "",
|
|
821
822
|
children: [
|
|
822
|
-
/* @__PURE__ */ h("caption", { children: $.omitted ? typeof
|
|
823
|
-
title:
|
|
823
|
+
/* @__PURE__ */ h("caption", { children: $.omitted ? typeof C == "string" ? A("truncatedCaption", {
|
|
824
|
+
title: C,
|
|
824
825
|
shown: $.rows.length,
|
|
825
826
|
count: $.rows.length + $.omitted
|
|
826
|
-
}) :
|
|
827
|
+
}) : A("truncated", {
|
|
827
828
|
shown: $.rows.length,
|
|
828
829
|
count: $.rows.length + $.omitted
|
|
829
|
-
}) : typeof
|
|
830
|
+
}) : typeof C == "string" ? C : null }),
|
|
830
831
|
/* @__PURE__ */ h("thead", { children: /* @__PURE__ */ h("tr", { children: $.columns.map((e, t) => /* @__PURE__ */ u("th", {
|
|
831
832
|
...t > 0 ? { "data-numeric": "" } : {},
|
|
832
833
|
key: e.key,
|
|
@@ -845,25 +846,25 @@ function C(c) {
|
|
|
845
846
|
]
|
|
846
847
|
})
|
|
847
848
|
}) : null,
|
|
848
|
-
B ? /* @__PURE__ */ h(
|
|
849
|
+
B ? /* @__PURE__ */ h(it, { kind: sr }) : null,
|
|
849
850
|
!B && z ? /* @__PURE__ */ h("div", {
|
|
850
851
|
"data-part": "error",
|
|
851
852
|
"data-part-error": "",
|
|
852
|
-
children:
|
|
853
|
-
action:
|
|
853
|
+
children: Qt?.() ?? /* @__PURE__ */ h(at, {
|
|
854
|
+
action: Et || bn ? A("retry") : void 0,
|
|
854
855
|
onAction: cr,
|
|
855
856
|
status: "error",
|
|
856
|
-
text:
|
|
857
|
+
text: A("error")
|
|
857
858
|
})
|
|
858
859
|
}) : null,
|
|
859
860
|
!B && !z && R?.empty ? /* @__PURE__ */ h("div", {
|
|
860
861
|
"data-part": "empty",
|
|
861
862
|
"data-part-empty": "",
|
|
862
|
-
children:
|
|
863
|
-
action: R.empty === "all-hidden" ?
|
|
864
|
-
onAction: (e) =>
|
|
863
|
+
children: Zt?.(R.empty) ?? /* @__PURE__ */ h(at, {
|
|
864
|
+
action: R.empty === "all-hidden" ? A("showAll") : void 0,
|
|
865
|
+
onAction: (e) => sn(ze, "pointer", e),
|
|
865
866
|
status: R.empty === "all-hidden" ? "no-results" : "empty",
|
|
866
|
-
text: R.empty === "all-hidden" ?
|
|
867
|
+
text: R.empty === "all-hidden" ? A("allHidden") : A("noData")
|
|
867
868
|
})
|
|
868
869
|
}) : null,
|
|
869
870
|
/* @__PURE__ */ h("p", {
|
|
@@ -876,10 +877,10 @@ function C(c) {
|
|
|
876
877
|
})
|
|
877
878
|
] })
|
|
878
879
|
});
|
|
879
|
-
return
|
|
880
|
+
return $t ? $t(dr) : /* @__PURE__ */ h("figure", { ...dr });
|
|
880
881
|
}
|
|
881
|
-
function
|
|
882
|
-
let [s, c] =
|
|
882
|
+
function et({ children: e, entry: t, focused: n, onActivate: r, onFocusEntry: i, onBlurEntry: a, ...o }) {
|
|
883
|
+
let [s, c] = C();
|
|
883
884
|
return /* @__PURE__ */ h("button", {
|
|
884
885
|
...o,
|
|
885
886
|
"aria-pressed": t.visible,
|
|
@@ -896,8 +897,8 @@ function tt({ children: e, entry: t, focused: n, onActivate: r, onFocusEntry: i,
|
|
|
896
897
|
children: e
|
|
897
898
|
});
|
|
898
899
|
}
|
|
899
|
-
function
|
|
900
|
-
let [c, ee] =
|
|
900
|
+
function tt({ glyph: e, label: t, onPress: i, part: o, pressed: s }) {
|
|
901
|
+
let [c, ee] = C();
|
|
901
902
|
return /* @__PURE__ */ h("button", {
|
|
902
903
|
"aria-label": t,
|
|
903
904
|
...s === void 0 ? {} : {
|
|
@@ -913,8 +914,8 @@ function nt({ glyph: e, label: t, onPress: i, part: o, pressed: s }) {
|
|
|
913
914
|
children: /* @__PURE__ */ h(r, { children: /* @__PURE__ */ h(n, { name: e }) })
|
|
914
915
|
});
|
|
915
916
|
}
|
|
916
|
-
function
|
|
917
|
-
let [r, i] =
|
|
917
|
+
function nt({ action: e, label: t, onPress: n }) {
|
|
918
|
+
let [r, i] = C();
|
|
918
919
|
return /* @__PURE__ */ h("button", {
|
|
919
920
|
"data-action": e,
|
|
920
921
|
"data-part": "menu-item",
|
|
@@ -926,7 +927,7 @@ function rt({ action: e, label: t, onPress: n }) {
|
|
|
926
927
|
children: t
|
|
927
928
|
});
|
|
928
929
|
}
|
|
929
|
-
function
|
|
930
|
+
function T({ shape: e = "block" }) {
|
|
930
931
|
return /* @__PURE__ */ h("span", {
|
|
931
932
|
"aria-hidden": "true",
|
|
932
933
|
"data-animation": "shimmer",
|
|
@@ -939,11 +940,11 @@ function w({ shape: e = "block" }) {
|
|
|
939
940
|
"data-ui-skeleton": ""
|
|
940
941
|
});
|
|
941
942
|
}
|
|
942
|
-
function
|
|
943
|
-
return /* @__PURE__ */ h(
|
|
943
|
+
function rt() {
|
|
944
|
+
return /* @__PURE__ */ h(T, {});
|
|
944
945
|
}
|
|
945
|
-
function
|
|
946
|
-
let t = (e) => Array.from({ length: e }, (e, t) => /* @__PURE__ */ h(
|
|
946
|
+
function it({ kind: e }) {
|
|
947
|
+
let t = (e) => Array.from({ length: e }, (e, t) => /* @__PURE__ */ h(T, {}, t));
|
|
947
948
|
return /* @__PURE__ */ h("div", {
|
|
948
949
|
"aria-hidden": "true",
|
|
949
950
|
"data-kind": e,
|
|
@@ -956,7 +957,7 @@ function at({ kind: e }) {
|
|
|
956
957
|
"data-part-region": "",
|
|
957
958
|
"data-ui": "skeleton",
|
|
958
959
|
"data-ui-skeleton": "",
|
|
959
|
-
children: e === "pie" ? /* @__PURE__ */ h(
|
|
960
|
+
children: e === "pie" ? /* @__PURE__ */ h(T, { shape: "circle" }) : /* @__PURE__ */ g(m, { children: [
|
|
960
961
|
/* @__PURE__ */ h("div", {
|
|
961
962
|
"data-skeleton": "y",
|
|
962
963
|
children: t(5)
|
|
@@ -973,7 +974,7 @@ function at({ kind: e }) {
|
|
|
973
974
|
})
|
|
974
975
|
});
|
|
975
976
|
}
|
|
976
|
-
function
|
|
977
|
+
function at({ action: e, onAction: t, status: n, text: r }) {
|
|
977
978
|
return /* @__PURE__ */ g("section", {
|
|
978
979
|
"data-align": "center",
|
|
979
980
|
"data-live": "polite",
|
|
@@ -1023,4 +1024,4 @@ function ot({ action: e, onAction: t, status: n, text: r }) {
|
|
|
1023
1024
|
});
|
|
1024
1025
|
}
|
|
1025
1026
|
//#endregion
|
|
1026
|
-
export {
|
|
1027
|
+
export { Le as a, Re as i, w as n, $e as r, Ie as t };
|