@alfadocs/ui-kit-debug 0.35.0 → 0.37.0
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/_chunks/{ar-CEpIJtcO.js → ar-D1RwVZFj.js} +2 -2
- package/dist/_chunks/{ar-CEpIJtcO.js.map → ar-D1RwVZFj.js.map} +1 -1
- package/dist/_chunks/bmi-calculator-DQD5_nE-.js +214 -0
- package/dist/_chunks/bmi-calculator-DQD5_nE-.js.map +1 -0
- package/dist/_chunks/{booking-eM0y0NIR.js → booking-DqXsd1Mv.js} +4 -4
- package/dist/_chunks/{booking-eM0y0NIR.js.map → booking-DqXsd1Mv.js.map} +1 -1
- package/dist/_chunks/chart-DnHvmiDX.js +312 -0
- package/dist/_chunks/chart-DnHvmiDX.js.map +1 -0
- package/dist/_chunks/{date-picker-B94HAV4A.js → date-picker-CXFpu-qY.js} +2 -2
- package/dist/_chunks/{date-picker-B94HAV4A.js.map → date-picker-CXFpu-qY.js.map} +1 -1
- package/dist/_chunks/{date-range-picker-D8CHNYQT.js → date-range-picker-I-q5rifj.js} +3 -3
- package/dist/_chunks/{date-range-picker-D8CHNYQT.js.map → date-range-picker-I-q5rifj.js.map} +1 -1
- package/dist/_chunks/{date-time-picker-D1GEzf8p.js → date-time-picker-CqpGPlcH.js} +2 -2
- package/dist/_chunks/{date-time-picker-D1GEzf8p.js.map → date-time-picker-CqpGPlcH.js.map} +1 -1
- package/dist/_chunks/{de-Dfbeau59.js → de-HTQ4b4-J.js} +2 -2
- package/dist/_chunks/{de-Dfbeau59.js.map → de-HTQ4b4-J.js.map} +1 -1
- package/dist/_chunks/due-date-calculator-kf9U_g7O.js +173 -0
- package/dist/_chunks/due-date-calculator-kf9U_g7O.js.map +1 -0
- package/dist/_chunks/{editable-currency-cell-renderer-CZcVWBPo.js → editable-currency-cell-renderer-DnjwZNZP.js} +2 -2
- package/dist/_chunks/{editable-currency-cell-renderer-CZcVWBPo.js.map → editable-currency-cell-renderer-DnjwZNZP.js.map} +1 -1
- package/dist/_chunks/{el-Dro3J7CP.js → el-Dr1pjuDq.js} +2 -2
- package/dist/_chunks/{el-Dro3J7CP.js.map → el-Dr1pjuDq.js.map} +1 -1
- package/dist/_chunks/{es-Dvg8u70B.js → es-CvyTjLS0.js} +2 -2
- package/dist/_chunks/{es-Dvg8u70B.js.map → es-CvyTjLS0.js.map} +1 -1
- package/dist/_chunks/{fr-VOGjBSPP.js → fr-CS7aqaFR.js} +2 -2
- package/dist/_chunks/{fr-VOGjBSPP.js.map → fr-CS7aqaFR.js.map} +1 -1
- package/dist/_chunks/{hi-BSDxWU_y.js → hi-3uy8KpsH.js} +2 -2
- package/dist/_chunks/{hi-BSDxWU_y.js.map → hi-3uy8KpsH.js.map} +1 -1
- package/dist/_chunks/{isSameWeek-Dfzu29cW.js → isSameWeek-DRpMibi9.js} +2 -2
- package/dist/_chunks/{isSameWeek-Dfzu29cW.js.map → isSameWeek-DRpMibi9.js.map} +1 -1
- package/dist/_chunks/{it-CuonvcI_.js → it-B_RF5VSw.js} +3 -3
- package/dist/_chunks/{it-CuonvcI_.js.map → it-B_RF5VSw.js.map} +1 -1
- package/dist/_chunks/{ja-DO57gIOT.js → ja-C1mEYy35.js} +2 -2
- package/dist/_chunks/{ja-DO57gIOT.js.map → ja-C1mEYy35.js.map} +1 -1
- package/dist/_chunks/marketplace-app-shell-DXHxy9dj.js +295 -0
- package/dist/_chunks/marketplace-app-shell-DXHxy9dj.js.map +1 -0
- package/dist/_chunks/{nl-DjPaaWaW.js → nl-Dl7lO2t3.js} +2 -2
- package/dist/_chunks/{nl-DjPaaWaW.js.map → nl-Dl7lO2t3.js.map} +1 -1
- package/dist/_chunks/patient-search-CBq62kmL.js.map +1 -1
- package/dist/_chunks/payment-form-D5rgnZu7.js.map +1 -1
- package/dist/_chunks/{pl-Cl4lOx2N.js → pl-Dgsogljx.js} +3 -3
- package/dist/_chunks/{pl-Cl4lOx2N.js.map → pl-Dgsogljx.js.map} +1 -1
- package/dist/_chunks/practice-results-BFM_lyUs.js.map +1 -1
- package/dist/_chunks/{pt-D7qO5CzD.js → pt-Dm2JF4bc.js} +2 -2
- package/dist/_chunks/{pt-D7qO5CzD.js.map → pt-Dm2JF4bc.js.map} +1 -1
- package/dist/_chunks/{react-day-picker-DsjfS7uI.js → react-day-picker-DYDdR8Vv.js} +22 -22
- package/dist/_chunks/{react-day-picker-DsjfS7uI.js.map → react-day-picker-DYDdR8Vv.js.map} +1 -1
- package/dist/_chunks/{ro-CP2-VJ_O.js → ro-BXFZ_xIX.js} +2 -2
- package/dist/_chunks/{ro-CP2-VJ_O.js.map → ro-BXFZ_xIX.js.map} +1 -1
- package/dist/_chunks/{ru-RPn9_Lpq.js → ru-BPQkNRRV.js} +3 -3
- package/dist/_chunks/{ru-RPn9_Lpq.js.map → ru-BPQkNRRV.js.map} +1 -1
- package/dist/_chunks/{sq-AQvefouo.js → sq-ChTlGFcJ.js} +2 -2
- package/dist/_chunks/{sq-AQvefouo.js.map → sq-ChTlGFcJ.js.map} +1 -1
- package/dist/_chunks/subDays-D-WYRpdW.js +8 -0
- package/dist/_chunks/{subDays-CANHP9hz.js.map → subDays-D-WYRpdW.js.map} +1 -1
- package/dist/_chunks/{sv-zkx9eBtD.js → sv-Do_gs6ir.js} +2 -2
- package/dist/_chunks/{sv-zkx9eBtD.js.map → sv-Do_gs6ir.js.map} +1 -1
- package/dist/_chunks/tooth-scheme-CxlsLjfN.js.map +1 -1
- package/dist/_chunks/{tr-Dmr412Ac.js → tr-da_UnkYH.js} +2 -2
- package/dist/_chunks/{tr-Dmr412Ac.js.map → tr-da_UnkYH.js.map} +1 -1
- package/dist/_chunks/use-password-requirements-DsgduV1x.js.map +1 -1
- package/dist/_chunks/{zh-CN-DxVt64Zk.js → zh-CN-C9qi5oak.js} +3 -3
- package/dist/_chunks/{zh-CN-DxVt64Zk.js.map → zh-CN-C9qi5oak.js.map} +1 -1
- package/dist/agent-catalog.json +1 -1
- package/dist/components/bmi-calculator/bmi-calculator.d.ts +24 -0
- package/dist/components/bmi-calculator/bmi-calculator.d.ts.map +1 -0
- package/dist/components/bmi-calculator/bmi.d.ts +37 -0
- package/dist/components/bmi-calculator/bmi.d.ts.map +1 -0
- package/dist/components/bmi-calculator/index.d.ts +4 -0
- package/dist/components/bmi-calculator/index.d.ts.map +1 -0
- package/dist/components/bmi-calculator/index.js +14 -0
- package/dist/components/bmi-calculator/index.js.map +1 -0
- package/dist/components/booking/index.js +1 -1
- package/dist/components/chart/chart.d.ts +7 -0
- package/dist/components/chart/chart.d.ts.map +1 -1
- package/dist/components/chart/index.js +1 -1
- package/dist/components/data-table/index.js +1 -1
- package/dist/components/date-picker/index.js +1 -1
- package/dist/components/date-range-picker/index.js +1 -1
- package/dist/components/date-time-picker/index.js +1 -1
- package/dist/components/due-date-calculator/due-date-calculator.d.ts +18 -0
- package/dist/components/due-date-calculator/due-date-calculator.d.ts.map +1 -0
- package/dist/components/due-date-calculator/gestation.d.ts +44 -0
- package/dist/components/due-date-calculator/gestation.d.ts.map +1 -0
- package/dist/components/due-date-calculator/index.d.ts +4 -0
- package/dist/components/due-date-calculator/index.d.ts.map +1 -0
- package/dist/components/due-date-calculator/index.js +10 -0
- package/dist/components/due-date-calculator/index.js.map +1 -0
- package/dist/components/index.d.ts +3 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/password-input/password-input.d.ts.map +1 -1
- package/dist/components/payment-form/payment-form.d.ts.map +1 -1
- package/dist/components/skeleton/skeleton.d.ts +1 -1
- package/dist/components/tooth-scheme/tooth-scheme.d.ts.map +1 -1
- package/dist/i18n/locales/ar.d.ts +64 -0
- package/dist/i18n/locales/ar.d.ts.map +1 -1
- package/dist/i18n/locales/ar.js +58 -0
- package/dist/i18n/locales/ar.js.map +1 -1
- package/dist/i18n/locales/de.d.ts +64 -0
- package/dist/i18n/locales/de.d.ts.map +1 -1
- package/dist/i18n/locales/de.js +58 -0
- package/dist/i18n/locales/de.js.map +1 -1
- package/dist/i18n/locales/el.d.ts +64 -0
- package/dist/i18n/locales/el.d.ts.map +1 -1
- package/dist/i18n/locales/el.js +58 -0
- package/dist/i18n/locales/el.js.map +1 -1
- package/dist/i18n/locales/en.d.ts +64 -0
- package/dist/i18n/locales/en.d.ts.map +1 -1
- package/dist/i18n/locales/en.js +58 -0
- package/dist/i18n/locales/en.js.map +1 -1
- package/dist/i18n/locales/es.d.ts +64 -0
- package/dist/i18n/locales/es.d.ts.map +1 -1
- package/dist/i18n/locales/es.js +58 -0
- package/dist/i18n/locales/es.js.map +1 -1
- package/dist/i18n/locales/fr.d.ts +64 -0
- package/dist/i18n/locales/fr.d.ts.map +1 -1
- package/dist/i18n/locales/fr.js +58 -0
- package/dist/i18n/locales/fr.js.map +1 -1
- package/dist/i18n/locales/hi.d.ts +64 -0
- package/dist/i18n/locales/hi.d.ts.map +1 -1
- package/dist/i18n/locales/hi.js +58 -0
- package/dist/i18n/locales/hi.js.map +1 -1
- package/dist/i18n/locales/it.d.ts +64 -0
- package/dist/i18n/locales/it.d.ts.map +1 -1
- package/dist/i18n/locales/it.js +58 -0
- package/dist/i18n/locales/it.js.map +1 -1
- package/dist/i18n/locales/ja.d.ts +64 -0
- package/dist/i18n/locales/ja.d.ts.map +1 -1
- package/dist/i18n/locales/ja.js +58 -0
- package/dist/i18n/locales/ja.js.map +1 -1
- package/dist/i18n/locales/nl.d.ts +64 -0
- package/dist/i18n/locales/nl.d.ts.map +1 -1
- package/dist/i18n/locales/nl.js +58 -0
- package/dist/i18n/locales/nl.js.map +1 -1
- package/dist/i18n/locales/pl.d.ts +64 -0
- package/dist/i18n/locales/pl.d.ts.map +1 -1
- package/dist/i18n/locales/pl.js +58 -0
- package/dist/i18n/locales/pl.js.map +1 -1
- package/dist/i18n/locales/pt.d.ts +64 -0
- package/dist/i18n/locales/pt.d.ts.map +1 -1
- package/dist/i18n/locales/pt.js +58 -0
- package/dist/i18n/locales/pt.js.map +1 -1
- package/dist/i18n/locales/ro.d.ts +64 -0
- package/dist/i18n/locales/ro.d.ts.map +1 -1
- package/dist/i18n/locales/ro.js +58 -0
- package/dist/i18n/locales/ro.js.map +1 -1
- package/dist/i18n/locales/ru.d.ts +64 -0
- package/dist/i18n/locales/ru.d.ts.map +1 -1
- package/dist/i18n/locales/ru.js +58 -0
- package/dist/i18n/locales/ru.js.map +1 -1
- package/dist/i18n/locales/sq.d.ts +64 -0
- package/dist/i18n/locales/sq.d.ts.map +1 -1
- package/dist/i18n/locales/sq.js +58 -0
- package/dist/i18n/locales/sq.js.map +1 -1
- package/dist/i18n/locales/sv.d.ts +64 -0
- package/dist/i18n/locales/sv.d.ts.map +1 -1
- package/dist/i18n/locales/sv.js +58 -0
- package/dist/i18n/locales/sv.js.map +1 -1
- package/dist/i18n/locales/tr.d.ts +64 -0
- package/dist/i18n/locales/tr.d.ts.map +1 -1
- package/dist/i18n/locales/tr.js +58 -0
- package/dist/i18n/locales/tr.js.map +1 -1
- package/dist/i18n/locales/zh.d.ts +64 -0
- package/dist/i18n/locales/zh.d.ts.map +1 -1
- package/dist/i18n/locales/zh.js +58 -0
- package/dist/i18n/locales/zh.js.map +1 -1
- package/dist/index.js +543 -600
- package/dist/index.js.map +1 -1
- package/dist/locales/ar.json +64 -0
- package/dist/locales/de.json +64 -0
- package/dist/locales/el.json +64 -0
- package/dist/locales/en.json +64 -0
- package/dist/locales/es.json +64 -0
- package/dist/locales/fr.json +64 -0
- package/dist/locales/hi.json +64 -0
- package/dist/locales/it.json +64 -0
- package/dist/locales/ja.json +64 -0
- package/dist/locales/nl.json +64 -0
- package/dist/locales/pl.json +64 -0
- package/dist/locales/pt.json +64 -0
- package/dist/locales/ro.json +64 -0
- package/dist/locales/ru.json +64 -0
- package/dist/locales/sq.json +64 -0
- package/dist/locales/sv.json +64 -0
- package/dist/locales/tr.json +64 -0
- package/dist/locales/zh.json +64 -0
- package/dist/patterns/marketplace-app-shell/index.d.ts +3 -0
- package/dist/patterns/marketplace-app-shell/index.d.ts.map +1 -0
- package/dist/patterns/marketplace-app-shell/index.js +6 -0
- package/dist/patterns/marketplace-app-shell/index.js.map +1 -0
- package/dist/patterns/marketplace-app-shell/marketplace-app-shell.d.ts +111 -0
- package/dist/patterns/marketplace-app-shell/marketplace-app-shell.d.ts.map +1 -0
- package/dist/tokens.css +1 -1
- package/package.json +19 -7
- package/dist/_chunks/chart-DLkVn_ex.js +0 -292
- package/dist/_chunks/chart-DLkVn_ex.js.map +0 -1
- package/dist/_chunks/subDays-CANHP9hz.js +0 -8
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alfadocs/ui-kit-debug",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.37.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "AlfaDocs shared design system — tokens, components, patterns, and translations for platform, booking, and alfascribe. (debug build — identical runtime to @alfadocs/ui-kit, ships source maps for symbolication).",
|
|
6
6
|
"license": "BUSL-1.1",
|
|
@@ -91,6 +91,10 @@
|
|
|
91
91
|
"types": "./dist/components/benefit-card/index.d.ts",
|
|
92
92
|
"import": "./dist/components/benefit-card/index.js"
|
|
93
93
|
},
|
|
94
|
+
"./bmi-calculator": {
|
|
95
|
+
"types": "./dist/components/bmi-calculator/index.d.ts",
|
|
96
|
+
"import": "./dist/components/bmi-calculator/index.js"
|
|
97
|
+
},
|
|
94
98
|
"./booking": {
|
|
95
99
|
"types": "./dist/components/booking/index.d.ts",
|
|
96
100
|
"import": "./dist/components/booking/index.js"
|
|
@@ -195,6 +199,10 @@
|
|
|
195
199
|
"types": "./dist/components/dropdown-menu/index.d.ts",
|
|
196
200
|
"import": "./dist/components/dropdown-menu/index.js"
|
|
197
201
|
},
|
|
202
|
+
"./due-date-calculator": {
|
|
203
|
+
"types": "./dist/components/due-date-calculator/index.d.ts",
|
|
204
|
+
"import": "./dist/components/due-date-calculator/index.js"
|
|
205
|
+
},
|
|
198
206
|
"./email-input": {
|
|
199
207
|
"types": "./dist/components/email-input/index.d.ts",
|
|
200
208
|
"import": "./dist/components/email-input/index.js"
|
|
@@ -527,6 +535,10 @@
|
|
|
527
535
|
"types": "./dist/patterns/alia-assistant/index.d.ts",
|
|
528
536
|
"import": "./dist/patterns/alia-assistant/index.js"
|
|
529
537
|
},
|
|
538
|
+
"./patterns/marketplace-app-shell": {
|
|
539
|
+
"types": "./dist/patterns/marketplace-app-shell/index.d.ts",
|
|
540
|
+
"import": "./dist/patterns/marketplace-app-shell/index.js"
|
|
541
|
+
},
|
|
530
542
|
"./patterns/patient-shell": {
|
|
531
543
|
"types": "./dist/patterns/patient-shell/index.d.ts",
|
|
532
544
|
"import": "./dist/patterns/patient-shell/index.js"
|
|
@@ -603,9 +615,9 @@
|
|
|
603
615
|
"i18next": "^26.0.4",
|
|
604
616
|
"libphonenumber-js": "^1.12.41",
|
|
605
617
|
"pdfjs-dist": "^5.6.205",
|
|
606
|
-
"react": "^18.2.0 || ^
|
|
618
|
+
"react": "^18.2.0 || ^19.0.0",
|
|
607
619
|
"react-apexcharts": "^2.0.0",
|
|
608
|
-
"react-dom": "^18.2.0 || ^
|
|
620
|
+
"react-dom": "^18.2.0 || ^19.0.0",
|
|
609
621
|
"react-i18next": "^17.0.3",
|
|
610
622
|
"signature_pad": "^5.1.3",
|
|
611
623
|
"tiptap-markdown": "^0.9.0"
|
|
@@ -782,8 +794,8 @@
|
|
|
782
794
|
"@tiptap/starter-kit": "^3.22.3",
|
|
783
795
|
"@types/dompurify": "^3.0.5",
|
|
784
796
|
"@types/google.maps": "^3.58.1",
|
|
785
|
-
"@types/react": "^
|
|
786
|
-
"@types/react-dom": "^
|
|
797
|
+
"@types/react": "^19.2.0",
|
|
798
|
+
"@types/react-dom": "^19.2.0",
|
|
787
799
|
"@types/validator": "^13.15.10",
|
|
788
800
|
"@vis.gl/react-google-maps": "^1.5.5",
|
|
789
801
|
"@vitejs/plugin-react": "^4.7.0",
|
|
@@ -807,9 +819,9 @@
|
|
|
807
819
|
"playwright": "^1.59.1",
|
|
808
820
|
"postcss": "^8.5.9",
|
|
809
821
|
"prettier": "^3.8.3",
|
|
810
|
-
"react": "^
|
|
822
|
+
"react": "^19.2.0",
|
|
811
823
|
"react-apexcharts": "^2.0.0",
|
|
812
|
-
"react-dom": "^
|
|
824
|
+
"react-dom": "^19.2.0",
|
|
813
825
|
"react-i18next": "^17.0.3",
|
|
814
826
|
"remark-gfm": "^4.0.1",
|
|
815
827
|
"signature_pad": "^5.1.3",
|
|
@@ -1,292 +0,0 @@
|
|
|
1
|
-
import { jsxs as b, jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as J, useId as K, useMemo as i, useRef as Q, useState as O, useEffect as E, useImperativeHandle as X } from "react";
|
|
3
|
-
import { c as tt } from "./index-D2ZczOXr.js";
|
|
4
|
-
import { useTranslation as et } from "react-i18next";
|
|
5
|
-
import ot from "react-apexcharts";
|
|
6
|
-
import N from "apexcharts";
|
|
7
|
-
import { u as rt, g as P } from "./apexcharts-theme-BJigns_V.js";
|
|
8
|
-
import { u as at } from "./use-prefers-reduced-motion-BMwIQRjB.js";
|
|
9
|
-
import { u as nt } from "./registry-nPAVE19X.js";
|
|
10
|
-
const st = {
|
|
11
|
-
id: "chart",
|
|
12
|
-
capabilities: [],
|
|
13
|
-
state: {},
|
|
14
|
-
actions: {
|
|
15
|
-
update_series: {
|
|
16
|
-
safety: "read",
|
|
17
|
-
argsType: "series",
|
|
18
|
-
description: "Replace the chart series without remounting.",
|
|
19
|
-
invoke: (a, l) => {
|
|
20
|
-
a.updateSeries(l.series);
|
|
21
|
-
}
|
|
22
|
-
},
|
|
23
|
-
export_png: {
|
|
24
|
-
safety: "read",
|
|
25
|
-
description: "Return a PNG data URI of the chart for export or screenshotting.",
|
|
26
|
-
invoke: (a) => a.dataURI()
|
|
27
|
-
}
|
|
28
|
-
},
|
|
29
|
-
domHooks: {
|
|
30
|
-
root: { attr: "data-component", value: "chart" },
|
|
31
|
-
instanceId: {
|
|
32
|
-
attr: "data-component-id",
|
|
33
|
-
sourceProp: "id",
|
|
34
|
-
description: "Sourced from the id prop."
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
}, it = tt("ds:relative ds:block ds:w-full", {
|
|
38
|
-
variants: {
|
|
39
|
-
density: {
|
|
40
|
-
compact: "ds:min-h-[var(--chart-min-height-compact)]",
|
|
41
|
-
comfortable: "ds:min-h-[var(--chart-min-height-comfortable)]"
|
|
42
|
-
}
|
|
43
|
-
},
|
|
44
|
-
defaultVariants: { density: "comfortable" }
|
|
45
|
-
}), ct = [
|
|
46
|
-
"verticalLines",
|
|
47
|
-
"horizontalLines",
|
|
48
|
-
"slantedLines",
|
|
49
|
-
"squares",
|
|
50
|
-
"circles"
|
|
51
|
-
], lt = ["line", "bar", "area"], dt = ["pie", "donut", "radialBar"];
|
|
52
|
-
function g(a) {
|
|
53
|
-
return dt.includes(a);
|
|
54
|
-
}
|
|
55
|
-
function mt(a) {
|
|
56
|
-
return lt.includes(a);
|
|
57
|
-
}
|
|
58
|
-
function ut(a, l) {
|
|
59
|
-
return g(l) ? [
|
|
60
|
-
{
|
|
61
|
-
name: "",
|
|
62
|
-
data: a
|
|
63
|
-
}
|
|
64
|
-
] : a;
|
|
65
|
-
}
|
|
66
|
-
const ht = J(
|
|
67
|
-
({
|
|
68
|
-
title: a,
|
|
69
|
-
id: l,
|
|
70
|
-
type: r,
|
|
71
|
-
series: u,
|
|
72
|
-
categories: p,
|
|
73
|
-
labels: f,
|
|
74
|
-
height: $,
|
|
75
|
-
width: k,
|
|
76
|
-
patterns: I = !1,
|
|
77
|
-
toolbar: v = !1,
|
|
78
|
-
locale: G,
|
|
79
|
-
density: H,
|
|
80
|
-
className: V
|
|
81
|
-
}, _) => {
|
|
82
|
-
const { t: o, i18n: F } = et(), C = K(), d = i(
|
|
83
|
-
() => `chart-${C.replace(/[^a-zA-Z0-9-_]/g, "")}`,
|
|
84
|
-
[C]
|
|
85
|
-
), T = `${d}-summary`, x = Q(null), [w, M] = O(0);
|
|
86
|
-
rt(x);
|
|
87
|
-
const m = G ?? F.language ?? "en", [A, U] = O(
|
|
88
|
-
() => {
|
|
89
|
-
try {
|
|
90
|
-
return P();
|
|
91
|
-
} catch {
|
|
92
|
-
return {};
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
);
|
|
96
|
-
E(() => {
|
|
97
|
-
if (typeof document > "u") return;
|
|
98
|
-
let t;
|
|
99
|
-
const e = new MutationObserver(() => {
|
|
100
|
-
clearTimeout(t), t = setTimeout(() => {
|
|
101
|
-
try {
|
|
102
|
-
U(P());
|
|
103
|
-
} catch {
|
|
104
|
-
}
|
|
105
|
-
}, 50);
|
|
106
|
-
});
|
|
107
|
-
return e.observe(document.documentElement, {
|
|
108
|
-
attributes: !0,
|
|
109
|
-
attributeFilter: ["class"]
|
|
110
|
-
}), () => {
|
|
111
|
-
clearTimeout(t), e.disconnect();
|
|
112
|
-
};
|
|
113
|
-
}, []), E(() => {
|
|
114
|
-
const t = x.current;
|
|
115
|
-
if (!t || typeof ResizeObserver > "u") return;
|
|
116
|
-
const e = new ResizeObserver((n) => {
|
|
117
|
-
const c = n[0];
|
|
118
|
-
c && M(Math.floor(c.contentRect.width));
|
|
119
|
-
});
|
|
120
|
-
return e.observe(t), () => e.disconnect();
|
|
121
|
-
}, []);
|
|
122
|
-
const y = i(
|
|
123
|
-
() => ({
|
|
124
|
-
async dataURI() {
|
|
125
|
-
const t = N.getChartByID(d);
|
|
126
|
-
return t ? (await t.dataURI()).imgURI : "";
|
|
127
|
-
},
|
|
128
|
-
updateSeries(t) {
|
|
129
|
-
const e = N.getChartByID(d);
|
|
130
|
-
e && (g(r), e.updateSeries(t));
|
|
131
|
-
}
|
|
132
|
-
}),
|
|
133
|
-
[d, r]
|
|
134
|
-
);
|
|
135
|
-
X(_, () => y, [y]), nt(st, y, l);
|
|
136
|
-
const R = typeof document < "u" && document.documentElement.dir === "rtl", z = i(
|
|
137
|
-
() => ut(u, r),
|
|
138
|
-
[u, r]
|
|
139
|
-
), h = i(
|
|
140
|
-
() => new Intl.NumberFormat(m),
|
|
141
|
-
[m]
|
|
142
|
-
), L = i(
|
|
143
|
-
() => ({
|
|
144
|
-
name: m,
|
|
145
|
-
options: {
|
|
146
|
-
toolbar: {
|
|
147
|
-
download: o("chart.toolbar.download"),
|
|
148
|
-
selection: o("chart.toolbar.selection"),
|
|
149
|
-
selectionZoom: o("chart.toolbar.selectionZoom"),
|
|
150
|
-
zoomIn: o("chart.toolbar.zoomIn"),
|
|
151
|
-
zoomOut: o("chart.toolbar.zoomOut"),
|
|
152
|
-
pan: o("chart.toolbar.pan"),
|
|
153
|
-
reset: o("chart.toolbar.reset"),
|
|
154
|
-
exportToSVG: o("chart.toolbar.exportToSVG"),
|
|
155
|
-
exportToPNG: o("chart.toolbar.exportToPNG"),
|
|
156
|
-
exportToCSV: o("chart.toolbar.exportToCSV")
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
}),
|
|
160
|
-
[m, o]
|
|
161
|
-
), S = at(), D = i(() => {
|
|
162
|
-
const t = A, e = {
|
|
163
|
-
...t,
|
|
164
|
-
chart: {
|
|
165
|
-
...t.chart,
|
|
166
|
-
id: d,
|
|
167
|
-
toolbar: { show: v },
|
|
168
|
-
zoom: { enabled: v },
|
|
169
|
-
animations: {
|
|
170
|
-
enabled: !S,
|
|
171
|
-
dynamicAnimation: { enabled: !S }
|
|
172
|
-
},
|
|
173
|
-
locales: [L],
|
|
174
|
-
defaultLocale: m,
|
|
175
|
-
parentHeightOffset: 0
|
|
176
|
-
},
|
|
177
|
-
labels: f,
|
|
178
|
-
legend: {
|
|
179
|
-
...t.legend,
|
|
180
|
-
position: "bottom",
|
|
181
|
-
// ApexCharts legend.horizontalAlign is a physical prop mapped internally
|
|
182
|
-
// to the chart's own text flow. For RTL we flip via `yaxis.opposite`
|
|
183
|
-
// and ApexCharts' own `direction: 'rtl'` handling; legend stays anchored
|
|
184
|
-
// to the inline-start by asking for 'left' on LTR and 'right' on RTL.
|
|
185
|
-
horizontalAlign: R ? "right" : "left",
|
|
186
|
-
fontFamily: "inherit"
|
|
187
|
-
},
|
|
188
|
-
tooltip: {
|
|
189
|
-
...t.tooltip,
|
|
190
|
-
y: {
|
|
191
|
-
formatter: (n) => h.format(n)
|
|
192
|
-
}
|
|
193
|
-
},
|
|
194
|
-
noData: {
|
|
195
|
-
text: o("chart.noData")
|
|
196
|
-
}
|
|
197
|
-
};
|
|
198
|
-
return mt(r) && (e.xaxis = {
|
|
199
|
-
...t.xaxis,
|
|
200
|
-
categories: p ?? []
|
|
201
|
-
}, e.yaxis = {
|
|
202
|
-
...t.yaxis,
|
|
203
|
-
opposite: R,
|
|
204
|
-
labels: {
|
|
205
|
-
formatter: (n) => h.format(n)
|
|
206
|
-
}
|
|
207
|
-
}, e.stroke = {
|
|
208
|
-
curve: "smooth",
|
|
209
|
-
width: r === "bar" ? 0 : 2
|
|
210
|
-
}, e.dataLabels = { enabled: !1 }), I ? e.fill = {
|
|
211
|
-
type: "pattern",
|
|
212
|
-
opacity: r === "area" ? 0.3 : 1,
|
|
213
|
-
pattern: {
|
|
214
|
-
style: [...ct],
|
|
215
|
-
strokeWidth: 2
|
|
216
|
-
}
|
|
217
|
-
} : r === "area" && (e.fill = {
|
|
218
|
-
type: "gradient",
|
|
219
|
-
opacity: 0.3
|
|
220
|
-
}), e;
|
|
221
|
-
}, [
|
|
222
|
-
A,
|
|
223
|
-
d,
|
|
224
|
-
v,
|
|
225
|
-
S,
|
|
226
|
-
L,
|
|
227
|
-
m,
|
|
228
|
-
f,
|
|
229
|
-
h,
|
|
230
|
-
o,
|
|
231
|
-
r,
|
|
232
|
-
p,
|
|
233
|
-
R,
|
|
234
|
-
I
|
|
235
|
-
]), W = k ?? (w > 0 ? w : "100%"), B = $ ?? 320, Y = i(() => {
|
|
236
|
-
const t = g(r) ? f ?? [] : p ?? [], e = z;
|
|
237
|
-
return /* @__PURE__ */ b("table", { id: T, className: "ds:sr-only", children: [
|
|
238
|
-
/* @__PURE__ */ s("caption", { children: a }),
|
|
239
|
-
/* @__PURE__ */ s("thead", { children: /* @__PURE__ */ b("tr", { children: [
|
|
240
|
-
/* @__PURE__ */ s("th", { scope: "col", children: o("chart.table.series") }),
|
|
241
|
-
t.map((n, c) => /* @__PURE__ */ s("th", { scope: "col", children: n }, `${n}-${c}`))
|
|
242
|
-
] }) }),
|
|
243
|
-
/* @__PURE__ */ s("tbody", { children: e.map((n, c) => /* @__PURE__ */ b("tr", { children: [
|
|
244
|
-
/* @__PURE__ */ s("th", { scope: "row", children: n.name || o("chart.table.value") }),
|
|
245
|
-
n.data.map((j, q) => /* @__PURE__ */ s("td", { children: h.format(j) }, `${c}-${q}`))
|
|
246
|
-
] }, `${n.name}-${c}`)) })
|
|
247
|
-
] });
|
|
248
|
-
}, [
|
|
249
|
-
r,
|
|
250
|
-
z,
|
|
251
|
-
f,
|
|
252
|
-
p,
|
|
253
|
-
T,
|
|
254
|
-
a,
|
|
255
|
-
o,
|
|
256
|
-
h
|
|
257
|
-
]), Z = i(() => (g(r), u), [u, r]);
|
|
258
|
-
return /* @__PURE__ */ b(
|
|
259
|
-
"div",
|
|
260
|
-
{
|
|
261
|
-
ref: x,
|
|
262
|
-
role: "img",
|
|
263
|
-
"aria-label": a,
|
|
264
|
-
"aria-describedby": T,
|
|
265
|
-
className: it({ density: H, className: V }),
|
|
266
|
-
"data-component": "chart",
|
|
267
|
-
"data-component-id": l,
|
|
268
|
-
children: [
|
|
269
|
-
Y,
|
|
270
|
-
/* @__PURE__ */ s(
|
|
271
|
-
ot,
|
|
272
|
-
{
|
|
273
|
-
type: r,
|
|
274
|
-
series: Z,
|
|
275
|
-
options: D,
|
|
276
|
-
width: W,
|
|
277
|
-
height: B,
|
|
278
|
-
"aria-hidden": "true"
|
|
279
|
-
}
|
|
280
|
-
)
|
|
281
|
-
]
|
|
282
|
-
}
|
|
283
|
-
);
|
|
284
|
-
}
|
|
285
|
-
);
|
|
286
|
-
ht.displayName = "Chart";
|
|
287
|
-
export {
|
|
288
|
-
ht as C,
|
|
289
|
-
it as a,
|
|
290
|
-
st as c
|
|
291
|
-
};
|
|
292
|
-
//# sourceMappingURL=chart-DLkVn_ex.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"chart-DLkVn_ex.js","sources":["../../src/components/chart/chart.agent.ts","../../src/components/chart/chart.tsx"],"sourcesContent":["import type { AgentAdapter } from '../../agent/types';\nimport type { ChartHandle } from './chart';\n\nexport const chartAgent: AgentAdapter<ChartHandle> = {\n id: 'chart',\n capabilities: [],\n state: {},\n actions: {\n update_series: {\n safety: 'read',\n argsType: 'series',\n description: 'Replace the chart series without remounting.',\n invoke: (\n handle,\n args: { series: Parameters<ChartHandle['updateSeries']>[0] },\n ) => {\n handle.updateSeries(args.series);\n },\n },\n export_png: {\n safety: 'read',\n description:\n 'Return a PNG data URI of the chart for export or screenshotting.',\n invoke: (handle) => handle.dataURI(),\n },\n },\n domHooks: {\n root: { attr: 'data-component', value: 'chart' },\n instanceId: {\n attr: 'data-component-id',\n sourceProp: 'id',\n description: 'Sourced from the id prop.',\n },\n },\n};\n","/* ------------------------------------------------------------------ */\n/* Chart — thin, typed wrapper over ApexCharts (react-apexcharts). */\n/* */\n/* - All chrome, colours, and fonts flow from */\n/* `src/tokens/apexcharts-theme.ts` — never hex literals in user */\n/* code. A MutationObserver on `<html class>` re-reads the bridge so */\n/* theme changes repaint without remount. */\n/* - A ResizeObserver on the wrapper keeps the chart responsive */\n/* without listening on `window.resize`. */\n/* - Accessibility: the wrapper carries `role=\"img\"` + `aria-label` */\n/* (required `title` prop) + `aria-describedby` pointing at a */\n/* visually-hidden `<table>` that mirrors series × categories. */\n/* - Colour-blind users: `patterns` prop flips `fill.type` to pattern */\n/* using ApexCharts' built-in pattern presets. */\n/* - Numbers format via `Intl.NumberFormat(locale)` — no hand-rolled */\n/* `toFixed()`. */\n/* ------------------------------------------------------------------ */\n\nimport {\n forwardRef,\n useEffect,\n useId,\n useImperativeHandle,\n useMemo,\n useRef,\n useState,\n} from 'react';\nimport { cva, type VariantProps } from 'class-variance-authority';\nimport { useTranslation } from 'react-i18next';\nimport ReactApexChart from 'react-apexcharts';\nimport ApexCharts from 'apexcharts';\nimport { getApexChartsTheme } from '../../tokens/apexcharts-theme';\nimport { usePrefersReducedMotion } from '../../hooks';\nimport { useNeutraliseHiddenFocus } from '../_shared/use-neutralize-hidden-focus';\nimport { useAgentRegistration } from '../../agent/registry';\nimport { chartAgent } from './chart.agent';\n\n/* ------------------------------------------------------------------ */\n/* CVA */\n/* ------------------------------------------------------------------ */\n\nconst chartVariants = cva('ds:relative ds:block ds:w-full', {\n variants: {\n density: {\n compact: 'ds:min-h-[var(--chart-min-height-compact)]',\n comfortable: 'ds:min-h-[var(--chart-min-height-comfortable)]',\n },\n },\n defaultVariants: { density: 'comfortable' },\n});\n\n/* ------------------------------------------------------------------ */\n/* Public types */\n/* ------------------------------------------------------------------ */\n\nexport type ChartType = 'line' | 'bar' | 'pie' | 'donut' | 'area' | 'radialBar';\n\nexport interface ChartSeries {\n name: string;\n data: number[];\n}\n\nexport interface ChartProps extends VariantProps<typeof chartVariants> {\n /** Required — drives aria-label and sr-only table caption. */\n title: string;\n /** Opaque instance id — emitted as `data-component-id` for the agent registry. */\n id?: string;\n /** Chart visual type. */\n type: ChartType;\n /**\n * For `line` / `bar` / `area`: an array of `ChartSeries`.\n * For `pie` / `donut` / `radialBar`: an array of numbers matched to `labels`.\n */\n series: ChartSeries[] | number[];\n /** Category axis labels (line / bar / area). */\n categories?: string[];\n /** Slice labels (pie / donut / radialBar). */\n labels?: string[];\n /** Height override. Defaults to 320px. */\n height?: number | string;\n /** Width override. Defaults to 100% of container. */\n width?: number | string;\n /** Opt-in pattern fills for colour-blind users. */\n patterns?: boolean;\n /** Show the ApexCharts toolbar. Defaults to false. */\n toolbar?: boolean;\n /** Locale override — defaults to the active i18next language. */\n locale?: string;\n /** Extra class names on the wrapper. */\n className?: string;\n}\n\nexport interface ChartHandle {\n /** Returns a PNG data URI for the chart. */\n dataURI: () => Promise<string>;\n /** Updates series without remounting. */\n updateSeries: (next: ChartProps['series']) => void;\n}\n\n/* ------------------------------------------------------------------ */\n/* Constants */\n/* ------------------------------------------------------------------ */\n\nconst PATTERN_STYLES = [\n 'verticalLines',\n 'horizontalLines',\n 'slantedLines',\n 'squares',\n 'circles',\n] as const;\n\n/** Types where `categories` belong on an x-axis. */\nconst CATEGORICAL_TYPES: ReadonlyArray<ChartType> = ['line', 'bar', 'area'];\n\n/** Types where `series` is a flat `number[]` paired with `labels`. */\nconst SLICE_TYPES: ReadonlyArray<ChartType> = ['pie', 'donut', 'radialBar'];\n\n/* ------------------------------------------------------------------ */\n/* Helpers */\n/* ------------------------------------------------------------------ */\n\nfunction isSliceType(type: ChartType): boolean {\n return SLICE_TYPES.includes(type);\n}\n\nfunction isCategoricalType(type: ChartType): boolean {\n return CATEGORICAL_TYPES.includes(type);\n}\n\n/** Coerce `series` into `ChartSeries[]` for shared logic (table, aria). */\nfunction normaliseSeries(\n series: ChartSeries[] | number[],\n type: ChartType,\n): ChartSeries[] {\n if (isSliceType(type)) {\n const nums = series as number[];\n return [\n {\n name: '',\n data: nums,\n },\n ];\n }\n return series as ChartSeries[];\n}\n\n/* ------------------------------------------------------------------ */\n/* Chart component */\n/* ------------------------------------------------------------------ */\n\nexport const Chart = forwardRef<ChartHandle, ChartProps>(\n (\n {\n title,\n id,\n type,\n series,\n categories,\n labels,\n height,\n width,\n patterns = false,\n toolbar = false,\n locale: localeProp,\n density,\n className,\n },\n ref,\n ) => {\n const { t, i18n } = useTranslation();\n const rawId = useId();\n const chartId = useMemo(\n () => `chart-${rawId.replace(/[^a-zA-Z0-9-_]/g, '')}`,\n [rawId],\n );\n const summaryId = `${chartId}-summary`;\n\n const wrapperRef = useRef<HTMLDivElement>(null);\n const [containerWidth, setContainerWidth] = useState(0);\n\n /* ApexCharts injects focusable canvases inside the `aria-hidden` */\n /* chart wrapper. Neutralise their tabindex so axe's */\n /* `aria-hidden-focus` rule passes. Same hook used in Sparkline. */\n useNeutraliseHiddenFocus(wrapperRef);\n\n const locale = localeProp ?? i18n.language ?? 'en';\n\n /* ---- dev warning if title missing ------------------------------ */\n if (import.meta.env.DEV && !title) {\n console.warn(\n 'Chart: `title` prop is required. It drives aria-label and the screen-reader summary table.',\n );\n }\n\n /* ---- theme-reactive state -------------------------------------- */\n const [themeOptions, setThemeOptions] = useState<ApexCharts.ApexOptions>(\n () => {\n try {\n return getApexChartsTheme();\n } catch {\n return {};\n }\n },\n );\n\n /* ---- MutationObserver: re-read theme on class change ------------ */\n useEffect(() => {\n if (typeof document === 'undefined') return undefined;\n let timer: ReturnType<typeof setTimeout>;\n const observer = new MutationObserver(() => {\n clearTimeout(timer);\n timer = setTimeout(() => {\n try {\n setThemeOptions(getApexChartsTheme());\n } catch {\n /* no-op in non-browser environments */\n }\n }, 50);\n });\n observer.observe(document.documentElement, {\n attributes: true,\n attributeFilter: ['class'],\n });\n return () => {\n clearTimeout(timer);\n observer.disconnect();\n };\n }, []);\n\n /* ---- ResizeObserver: track container width --------------------- */\n useEffect(() => {\n const el = wrapperRef.current;\n if (!el || typeof ResizeObserver === 'undefined') return undefined;\n const ro = new ResizeObserver((entries) => {\n const entry = entries[0];\n if (entry) setContainerWidth(Math.floor(entry.contentRect.width));\n });\n ro.observe(el);\n return () => ro.disconnect();\n }, []);\n\n /* ---- imperative handle ----------------------------------------- */\n const agentHandle = useMemo<ChartHandle>(\n () => ({\n async dataURI(): Promise<string> {\n const instance = ApexCharts.getChartByID(chartId);\n if (!instance) return '';\n const result = await instance.dataURI();\n return (result as { imgURI: string }).imgURI;\n },\n updateSeries(next) {\n const instance = ApexCharts.getChartByID(chartId);\n if (!instance) return;\n if (isSliceType(type)) {\n instance.updateSeries(next as number[]);\n } else {\n instance.updateSeries(next as ChartSeries[]);\n }\n },\n }),\n [chartId, type],\n );\n useImperativeHandle(ref, () => agentHandle, [agentHandle]);\n useAgentRegistration(chartAgent, agentHandle, id);\n\n /* ---- RTL detection --------------------------------------------- */\n const isRtl =\n typeof document !== 'undefined' && document.documentElement.dir === 'rtl';\n\n /* ---- normalised series for sr-only table ----------------------- */\n const tableSeries = useMemo(\n () => normaliseSeries(series, type),\n [series, type],\n );\n\n /* ---- Intl formatter -------------------------------------------- */\n const numberFormatter = useMemo(\n () => new Intl.NumberFormat(locale),\n [locale],\n );\n\n /* ---- toolbar localisation -------------------------------------- */\n const toolbarLocale = useMemo(\n () => ({\n name: locale,\n options: {\n toolbar: {\n download: t('chart.toolbar.download'),\n selection: t('chart.toolbar.selection'),\n selectionZoom: t('chart.toolbar.selectionZoom'),\n zoomIn: t('chart.toolbar.zoomIn'),\n zoomOut: t('chart.toolbar.zoomOut'),\n pan: t('chart.toolbar.pan'),\n reset: t('chart.toolbar.reset'),\n exportToSVG: t('chart.toolbar.exportToSVG'),\n exportToPNG: t('chart.toolbar.exportToPNG'),\n exportToCSV: t('chart.toolbar.exportToCSV'),\n },\n },\n }),\n [locale, t],\n );\n\n /* ---- build ApexOptions ----------------------------------------- */\n const reducedMotion = usePrefersReducedMotion();\n\n const chartOptions: ApexCharts.ApexOptions = useMemo(() => {\n const base = themeOptions;\n\n const options: ApexCharts.ApexOptions = {\n ...base,\n chart: {\n ...base.chart,\n id: chartId,\n toolbar: { show: toolbar },\n zoom: { enabled: toolbar },\n animations: {\n enabled: !reducedMotion,\n dynamicAnimation: { enabled: !reducedMotion },\n },\n locales: [toolbarLocale],\n defaultLocale: locale,\n parentHeightOffset: 0,\n },\n labels: labels,\n legend: {\n ...base.legend,\n position: 'bottom',\n // ApexCharts legend.horizontalAlign is a physical prop mapped internally\n // to the chart's own text flow. For RTL we flip via `yaxis.opposite`\n // and ApexCharts' own `direction: 'rtl'` handling; legend stays anchored\n // to the inline-start by asking for 'left' on LTR and 'right' on RTL.\n horizontalAlign: isRtl ? 'right' : 'left',\n fontFamily: 'inherit',\n },\n tooltip: {\n ...base.tooltip,\n y: {\n formatter: (value: number) => numberFormatter.format(value),\n },\n },\n noData: {\n text: t('chart.noData'),\n },\n };\n\n if (isCategoricalType(type)) {\n options.xaxis = {\n ...base.xaxis,\n categories: categories ?? [],\n };\n options.yaxis = {\n ...base.yaxis,\n opposite: isRtl,\n labels: {\n formatter: (value: number) => numberFormatter.format(value),\n },\n };\n options.stroke = {\n curve: 'smooth',\n width: type === 'bar' ? 0 : 2,\n };\n options.dataLabels = { enabled: false };\n }\n\n if (patterns) {\n options.fill = {\n type: 'pattern',\n opacity: type === 'area' ? 0.3 : 1,\n pattern: {\n style: [...PATTERN_STYLES],\n strokeWidth: 2,\n },\n };\n } else if (type === 'area') {\n options.fill = {\n type: 'gradient',\n opacity: 0.3,\n };\n }\n\n return options;\n }, [\n themeOptions,\n chartId,\n toolbar,\n reducedMotion,\n toolbarLocale,\n locale,\n labels,\n numberFormatter,\n t,\n type,\n categories,\n isRtl,\n patterns,\n ]);\n\n /* ---- resolved dimensions --------------------------------------- */\n const resolvedWidth =\n width ?? (containerWidth > 0 ? containerWidth : '100%');\n const resolvedHeight = height ?? 320;\n\n /* ---- sr-only data table --------------------------------------- */\n const srTable = useMemo(() => {\n const columnLabels = isSliceType(type)\n ? (labels ?? [])\n : (categories ?? []);\n const rows = tableSeries;\n return (\n <table id={summaryId} className=\"ds:sr-only\">\n <caption>{title}</caption>\n <thead>\n <tr>\n <th scope=\"col\">{t('chart.table.series')}</th>\n {columnLabels.map((col, i) => (\n <th key={`${col}-${i}`} scope=\"col\">\n {col}\n </th>\n ))}\n </tr>\n </thead>\n <tbody>\n {rows.map((row, rowIndex) => (\n <tr key={`${row.name}-${rowIndex}`}>\n <th scope=\"row\">{row.name || t('chart.table.value')}</th>\n {row.data.map((value, colIndex) => (\n <td key={`${rowIndex}-${colIndex}`}>\n {numberFormatter.format(value)}\n </td>\n ))}\n </tr>\n ))}\n </tbody>\n </table>\n );\n }, [\n type,\n tableSeries,\n labels,\n categories,\n summaryId,\n title,\n t,\n numberFormatter,\n ]);\n\n /* ---- ApexCharts `series` prop shape ----------------------------- */\n const apexSeries = useMemo(() => {\n if (isSliceType(type)) {\n return series as number[];\n }\n return series as ChartSeries[];\n }, [series, type]);\n\n return (\n <div\n ref={wrapperRef}\n role=\"img\"\n aria-label={title}\n aria-describedby={summaryId}\n className={chartVariants({ density, className })}\n data-component=\"chart\"\n data-component-id={id}\n >\n {srTable}\n <ReactApexChart\n type={type}\n series={apexSeries as ApexCharts.ApexOptions['series']}\n options={chartOptions}\n width={resolvedWidth}\n height={resolvedHeight}\n aria-hidden=\"true\"\n />\n </div>\n );\n },\n);\n\nChart.displayName = 'Chart';\n\n/* ------------------------------------------------------------------ */\n/* Re-export internal helper for downstream theming (kept narrow). */\n/* ------------------------------------------------------------------ */\n\nexport { chartVariants };\n"],"names":["chartAgent","handle","args","chartVariants","cva","PATTERN_STYLES","CATEGORICAL_TYPES","SLICE_TYPES","isSliceType","type","isCategoricalType","normaliseSeries","series","Chart","forwardRef","title","id","categories","labels","height","width","patterns","toolbar","localeProp","density","className","ref","t","i18n","useTranslation","rawId","useId","chartId","useMemo","summaryId","wrapperRef","useRef","containerWidth","setContainerWidth","useState","useNeutraliseHiddenFocus","locale","themeOptions","setThemeOptions","getApexChartsTheme","useEffect","timer","observer","el","ro","entries","entry","agentHandle","instance","ApexCharts","next","useImperativeHandle","useAgentRegistration","isRtl","tableSeries","numberFormatter","toolbarLocale","reducedMotion","usePrefersReducedMotion","chartOptions","base","options","value","resolvedWidth","resolvedHeight","srTable","columnLabels","rows","jsx","jsxs","col","i","row","rowIndex","colIndex","apexSeries","ReactApexChart"],"mappings":";;;;;;;;;AAGO,MAAMA,KAAwC;AAAA,EACnD,IAAI;AAAA,EACJ,cAAc,CAAA;AAAA,EACd,OAAO,CAAA;AAAA,EACP,SAAS;AAAA,IACP,eAAe;AAAA,MACb,QAAQ;AAAA,MACR,UAAU;AAAA,MACV,aAAa;AAAA,MACb,QAAQ,CACNC,GACAC,MACG;AACH,QAAAD,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