@blukavantui/charts-community 1.0.1 → 1.2.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/LICENSE.txt +0 -2
- package/README.md +75 -70
- package/dist/bar.js +1 -1
- package/dist/browser/charts-community.css +1 -1
- package/dist/browser/charts-community.js +17 -17
- package/dist/build-audit.json +129 -84
- package/dist/catalogue-runtime.d.ts +13 -1
- package/dist/chunk-2GUWWKHW.js +1 -0
- package/dist/chunk-3PITHTEO.js +1 -0
- package/dist/chunk-4B5MQ6GZ.js +1 -0
- package/dist/chunk-4EQMOBBN.js +1 -0
- package/dist/chunk-4WDZUJDS.js +1 -0
- package/dist/chunk-5NUOOMHV.js +1 -0
- package/dist/chunk-7OCMRHIH.js +1 -0
- package/dist/chunk-CF5Q2DDP.js +1 -0
- package/dist/chunk-EITBQBN2.js +1 -0
- package/dist/chunk-FXNKAHRG.js +1 -0
- package/dist/chunk-IDMAFTWV.js +1 -0
- package/dist/chunk-ILTENI35.js +1 -0
- package/dist/chunk-KRMM7EWI.js +1 -0
- package/dist/chunk-LUUPBBD4.js +1 -0
- package/dist/chunk-MR5VITXX.js +1 -0
- package/dist/chunk-NASBRHIW.js +1 -0
- package/dist/chunk-NXDBBMF5.js +1 -0
- package/dist/chunk-OQ6MP7PY.js +1 -0
- package/dist/{chunk-QETOF22L.js → chunk-RC2TCMJF.js} +1 -1
- package/dist/{chunk-MSZ5J5WG.js → chunk-RXOGAN23.js} +1 -1
- package/dist/chunk-UGXWOWAG.js +2 -0
- package/dist/chunk-UO2KNHTU.js +2 -0
- package/dist/chunk-UQMMBG26.js +3 -0
- package/dist/chunk-VTJ4XPRV.js +1 -0
- package/dist/chunk-WJ3UHH6J.js +1 -0
- package/dist/chunk-XLJUSNGV.js +1 -0
- package/dist/doughnut.js +1 -1
- package/dist/heatmap.js +1 -1
- package/dist/index.js +1 -1
- package/dist/line.js +1 -1
- package/dist/motion/bar.css +1 -0
- package/dist/motion/bar.d.ts +8 -0
- package/dist/motion/bar.js +1 -0
- package/dist/motion/doughnut.css +1 -0
- package/dist/motion/doughnut.d.ts +8 -0
- package/dist/motion/doughnut.js +1 -0
- package/dist/motion/heatmap.css +1 -0
- package/dist/motion/heatmap.d.ts +7 -0
- package/dist/motion/heatmap.js +1 -0
- package/dist/motion/line.css +1 -0
- package/dist/motion/line.d.ts +8 -0
- package/dist/motion/line.js +1 -0
- package/dist/motion/pie.css +1 -0
- package/dist/motion/pie.d.ts +8 -0
- package/dist/motion/pie.js +1 -0
- package/dist/motion/radar.css +1 -0
- package/dist/motion/radar.d.ts +8 -0
- package/dist/motion/radar.js +1 -0
- package/dist/motion/scatter.css +1 -0
- package/dist/motion/scatter.d.ts +8 -0
- package/dist/motion/scatter.js +1 -0
- package/dist/motion/sparkline.d.ts +7 -0
- package/dist/motion/sparkline.js +1 -0
- package/dist/motion-collection.d.ts +7 -0
- package/dist/motion-community.d.ts +40 -0
- package/dist/motion-policy.d.ts +14 -0
- package/dist/motion.css +1 -0
- package/dist/motion.d.ts +40 -0
- package/dist/motion.js +1 -0
- package/dist/pie.js +1 -1
- package/dist/radar.js +1 -1
- package/dist/scatter.js +1 -1
- package/dist/sparkline.js +1 -1
- package/dist/styles.css +8 -0
- package/dist/web-api.json +162 -2
- package/dist/web-motion-sparkline.d.ts +4 -0
- package/edition.json +1 -1
- package/package.json +40 -33
- package/src/catalogue-runtime.ts +49 -5
- package/src/motion/bar.ts +15 -0
- package/src/motion/doughnut.ts +14 -0
- package/src/motion/heatmap.ts +14 -0
- package/src/motion/line.ts +15 -0
- package/src/motion/pie.ts +14 -0
- package/src/motion/radar.ts +15 -0
- package/src/motion/scatter.ts +15 -0
- package/src/motion/sparkline.ts +10 -0
- package/src/motion-collection.ts +20 -0
- package/src/motion-community.ts +22 -0
- package/src/motion-policy.ts +36 -0
- package/src/web-motion-sparkline.ts +37 -0
- package/dist/chunk-5NXLEMCV.js +0 -3
- package/dist/chunk-FHHQWCUO.js +0 -1
- package/dist/chunk-FZ7J7BEC.js +0 -1
- package/dist/chunk-JNSBTZUP.js +0 -2
- package/dist/chunk-KCW3WN5P.js +0 -1
- package/dist/chunk-QBKO4AG7.js +0 -1
- package/dist/chunk-QFXXWRD5.js +0 -1
- package/dist/chunk-YJKEV5J7.js +0 -2
- package/scripts/build.mjs +0 -31
- package/tsconfig.json +0 -16
package/dist/build-audit.json
CHANGED
|
@@ -1,16 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"sources": [
|
|
3
|
-
"src/
|
|
3
|
+
"src/motion-collection.ts",
|
|
4
|
+
"src/motion-policy.ts",
|
|
5
|
+
"src/sparkline-runtime/runtime.js",
|
|
4
6
|
"src/limits.ts",
|
|
5
|
-
"src/
|
|
6
|
-
"src/
|
|
7
|
+
"src/colors.ts",
|
|
8
|
+
"src/sparkline-validation.ts",
|
|
9
|
+
"src/sparkline.ts",
|
|
10
|
+
"src/web-motion-sparkline.ts",
|
|
11
|
+
"src/motion/sparkline.ts",
|
|
7
12
|
"src/model.ts",
|
|
8
|
-
"src/
|
|
9
|
-
"src/builders/line.ts",
|
|
13
|
+
"src/validation.ts",
|
|
10
14
|
"src/options.ts",
|
|
11
15
|
"src/state-announcement.ts",
|
|
12
16
|
"src/loading-state.ts",
|
|
13
17
|
"src/messages.ts",
|
|
18
|
+
"src/catalogue-model.ts",
|
|
14
19
|
"src/legend-model.ts",
|
|
15
20
|
"src/legend.css",
|
|
16
21
|
"src/legend.ts",
|
|
@@ -22,143 +27,183 @@
|
|
|
22
27
|
"src/map-resources.ts",
|
|
23
28
|
"src/charts.css",
|
|
24
29
|
"src/catalogue-runtime.ts",
|
|
25
|
-
"src/
|
|
30
|
+
"src/accessibility.ts",
|
|
31
|
+
"src/builders/line.ts",
|
|
32
|
+
"src/motion/line.ts",
|
|
26
33
|
"src/builders/bar.ts",
|
|
27
|
-
"src/bar.ts",
|
|
34
|
+
"src/motion/bar.ts",
|
|
28
35
|
"src/builders/pie.ts",
|
|
29
|
-
"src/pie.ts",
|
|
36
|
+
"src/motion/pie.ts",
|
|
30
37
|
"src/builders/doughnut.ts",
|
|
31
|
-
"src/doughnut.ts",
|
|
38
|
+
"src/motion/doughnut.ts",
|
|
32
39
|
"src/builders/scatter.ts",
|
|
33
|
-
"src/scatter.ts",
|
|
40
|
+
"src/motion/scatter.ts",
|
|
34
41
|
"src/builders/radar.ts",
|
|
35
|
-
"src/radar.ts",
|
|
42
|
+
"src/motion/radar.ts",
|
|
36
43
|
"src/builders/heatmap.ts",
|
|
44
|
+
"src/motion/heatmap.ts",
|
|
45
|
+
"src/motion-community.ts",
|
|
46
|
+
"src/line.ts",
|
|
47
|
+
"src/bar.ts",
|
|
48
|
+
"src/pie.ts",
|
|
49
|
+
"src/doughnut.ts",
|
|
50
|
+
"src/scatter.ts",
|
|
51
|
+
"src/radar.ts",
|
|
37
52
|
"src/runtime.ts",
|
|
38
53
|
"src/heatmap.ts",
|
|
39
|
-
"src/sparkline-runtime/runtime.js",
|
|
40
|
-
"src/sparkline-validation.ts",
|
|
41
|
-
"src/sparkline.ts",
|
|
42
54
|
"src/community.ts"
|
|
43
55
|
],
|
|
44
56
|
"outputs": [
|
|
57
|
+
"packages/community/dist/radar.js",
|
|
45
58
|
"packages/community/dist/heatmap.js",
|
|
59
|
+
"packages/community/dist/motion/heatmap.js",
|
|
46
60
|
"packages/community/dist/index.js",
|
|
47
|
-
"packages/community/dist/chunk-
|
|
61
|
+
"packages/community/dist/chunk-XLJUSNGV.js",
|
|
62
|
+
"packages/community/dist/chunk-KRMM7EWI.js",
|
|
48
63
|
"packages/community/dist/sparkline.js",
|
|
49
|
-
"packages/community/dist/chunk-MSZ5J5WG.js",
|
|
50
64
|
"packages/community/dist/line.js",
|
|
51
|
-
"packages/community/dist/chunk-
|
|
65
|
+
"packages/community/dist/chunk-7OCMRHIH.js",
|
|
52
66
|
"packages/community/dist/bar.js",
|
|
53
|
-
"packages/community/dist/chunk-
|
|
67
|
+
"packages/community/dist/chunk-IDMAFTWV.js",
|
|
54
68
|
"packages/community/dist/pie.js",
|
|
55
|
-
"packages/community/dist/chunk-
|
|
69
|
+
"packages/community/dist/chunk-OQ6MP7PY.js",
|
|
56
70
|
"packages/community/dist/doughnut.js",
|
|
57
|
-
"packages/community/dist/chunk-
|
|
71
|
+
"packages/community/dist/chunk-LUUPBBD4.js",
|
|
58
72
|
"packages/community/dist/scatter.js",
|
|
59
|
-
"packages/community/dist/chunk-
|
|
60
|
-
"packages/community/dist/
|
|
61
|
-
"packages/community/dist/chunk-
|
|
62
|
-
"packages/community/dist/chunk-
|
|
63
|
-
"packages/community/dist/
|
|
73
|
+
"packages/community/dist/chunk-FXNKAHRG.js",
|
|
74
|
+
"packages/community/dist/motion.js",
|
|
75
|
+
"packages/community/dist/chunk-2GUWWKHW.js",
|
|
76
|
+
"packages/community/dist/chunk-ILTENI35.js",
|
|
77
|
+
"packages/community/dist/motion/sparkline.js",
|
|
78
|
+
"packages/community/dist/chunk-5NUOOMHV.js",
|
|
79
|
+
"packages/community/dist/chunk-RXOGAN23.js",
|
|
80
|
+
"packages/community/dist/motion/line.js",
|
|
81
|
+
"packages/community/dist/chunk-4WDZUJDS.js",
|
|
82
|
+
"packages/community/dist/chunk-WJ3UHH6J.js",
|
|
83
|
+
"packages/community/dist/motion/bar.js",
|
|
84
|
+
"packages/community/dist/chunk-4B5MQ6GZ.js",
|
|
85
|
+
"packages/community/dist/chunk-EITBQBN2.js",
|
|
86
|
+
"packages/community/dist/motion/pie.js",
|
|
87
|
+
"packages/community/dist/chunk-4EQMOBBN.js",
|
|
88
|
+
"packages/community/dist/chunk-UO2KNHTU.js",
|
|
89
|
+
"packages/community/dist/motion/doughnut.js",
|
|
90
|
+
"packages/community/dist/chunk-NASBRHIW.js",
|
|
91
|
+
"packages/community/dist/chunk-UQMMBG26.js",
|
|
92
|
+
"packages/community/dist/motion/scatter.js",
|
|
93
|
+
"packages/community/dist/chunk-CF5Q2DDP.js",
|
|
94
|
+
"packages/community/dist/chunk-NXDBBMF5.js",
|
|
95
|
+
"packages/community/dist/motion/radar.js",
|
|
96
|
+
"packages/community/dist/chunk-VTJ4XPRV.js",
|
|
97
|
+
"packages/community/dist/chunk-UGXWOWAG.js",
|
|
98
|
+
"packages/community/dist/chunk-MR5VITXX.js",
|
|
99
|
+
"packages/community/dist/chunk-3PITHTEO.js",
|
|
100
|
+
"packages/community/dist/chunk-RC2TCMJF.js",
|
|
101
|
+
"packages/community/dist/radar.css",
|
|
64
102
|
"packages/community/dist/heatmap.css",
|
|
103
|
+
"packages/community/dist/motion/heatmap.css",
|
|
65
104
|
"packages/community/dist/index.css",
|
|
66
105
|
"packages/community/dist/line.css",
|
|
67
106
|
"packages/community/dist/bar.css",
|
|
68
107
|
"packages/community/dist/pie.css",
|
|
69
108
|
"packages/community/dist/doughnut.css",
|
|
70
109
|
"packages/community/dist/scatter.css",
|
|
71
|
-
"packages/community/dist/
|
|
110
|
+
"packages/community/dist/motion.css",
|
|
111
|
+
"packages/community/dist/motion/line.css",
|
|
112
|
+
"packages/community/dist/motion/bar.css",
|
|
113
|
+
"packages/community/dist/motion/pie.css",
|
|
114
|
+
"packages/community/dist/motion/doughnut.css",
|
|
115
|
+
"packages/community/dist/motion/scatter.css",
|
|
116
|
+
"packages/community/dist/motion/radar.css"
|
|
72
117
|
],
|
|
73
118
|
"engineInputs": [
|
|
74
|
-
"node_modules/echarts/lib/chart/helper/createRenderPlanner.js",
|
|
75
|
-
"node_modules/echarts/lib/chart/custom/customSeriesRegister.js",
|
|
76
|
-
"node_modules/echarts/lib/chart/helper/createSeriesData.js",
|
|
77
|
-
"node_modules/echarts/lib/chart/line/LineSeries.js",
|
|
78
|
-
"node_modules/echarts/lib/chart/helper/labelHelper.js",
|
|
79
|
-
"node_modules/echarts/lib/chart/helper/Symbol.js",
|
|
80
|
-
"node_modules/echarts/lib/chart/helper/SymbolDraw.js",
|
|
81
|
-
"node_modules/echarts/lib/chart/line/helper.js",
|
|
82
|
-
"node_modules/echarts/lib/chart/line/lineAnimationDiff.js",
|
|
83
|
-
"node_modules/echarts/lib/chart/line/poly.js",
|
|
84
|
-
"node_modules/echarts/lib/chart/helper/createClipPathFromCoordSys.js",
|
|
85
|
-
"node_modules/echarts/lib/chart/line/LineView.js",
|
|
86
|
-
"node_modules/echarts/lib/chart/line/install.js",
|
|
87
|
-
"node_modules/echarts/lib/chart/helper/axisSnippets.js",
|
|
88
|
-
"node_modules/echarts/lib/chart/bar/BaseBarSeries.js",
|
|
89
|
-
"node_modules/echarts/lib/chart/bar/BarSeries.js",
|
|
90
|
-
"node_modules/echarts/lib/chart/helper/sectorHelper.js",
|
|
91
|
-
"node_modules/echarts/lib/chart/bar/BarView.js",
|
|
92
|
-
"node_modules/echarts/lib/chart/bar/install.js",
|
|
93
|
-
"node_modules/echarts/lib/chart/helper/createSeriesDataSimply.js",
|
|
94
|
-
"node_modules/echarts/lib/chart/pie/PieSeries.js",
|
|
95
|
-
"node_modules/echarts/lib/chart/pie/labelLayout.js",
|
|
96
|
-
"node_modules/echarts/lib/chart/pie/pieLayout.js",
|
|
97
|
-
"node_modules/echarts/lib/chart/pie/PieView.js",
|
|
98
|
-
"node_modules/echarts/lib/chart/pie/install.js",
|
|
99
|
-
"node_modules/echarts/lib/chart/scatter/ScatterSeries.js",
|
|
100
|
-
"node_modules/echarts/lib/chart/helper/LargeSymbolDraw.js",
|
|
101
|
-
"node_modules/echarts/lib/chart/scatter/ScatterView.js",
|
|
102
|
-
"node_modules/echarts/lib/chart/scatter/install.js",
|
|
103
|
-
"node_modules/echarts/lib/chart/radar/backwardCompat.js",
|
|
104
|
-
"node_modules/echarts/lib/chart/radar/RadarSeries.js",
|
|
105
|
-
"node_modules/echarts/lib/chart/radar/RadarView.js",
|
|
106
|
-
"node_modules/echarts/lib/chart/radar/radarLayout.js",
|
|
107
|
-
"node_modules/echarts/lib/chart/radar/install.js",
|
|
108
|
-
"node_modules/echarts/lib/chart/heatmap/HeatmapLayer.js",
|
|
109
|
-
"node_modules/echarts/lib/chart/heatmap/HeatmapView.js",
|
|
110
|
-
"node_modules/echarts/lib/chart/heatmap/HeatmapSeries.js",
|
|
111
|
-
"node_modules/echarts/lib/chart/heatmap/install.js"
|
|
119
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/createRenderPlanner.js",
|
|
120
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/custom/customSeriesRegister.js",
|
|
121
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/createSeriesData.js",
|
|
122
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/line/LineSeries.js",
|
|
123
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/labelHelper.js",
|
|
124
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/Symbol.js",
|
|
125
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/SymbolDraw.js",
|
|
126
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/line/helper.js",
|
|
127
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/line/lineAnimationDiff.js",
|
|
128
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/line/poly.js",
|
|
129
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/createClipPathFromCoordSys.js",
|
|
130
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/line/LineView.js",
|
|
131
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/line/install.js",
|
|
132
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/axisSnippets.js",
|
|
133
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/bar/BaseBarSeries.js",
|
|
134
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/bar/BarSeries.js",
|
|
135
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/sectorHelper.js",
|
|
136
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/bar/BarView.js",
|
|
137
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/bar/install.js",
|
|
138
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/createSeriesDataSimply.js",
|
|
139
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/pie/PieSeries.js",
|
|
140
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/pie/labelLayout.js",
|
|
141
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/pie/pieLayout.js",
|
|
142
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/pie/PieView.js",
|
|
143
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/pie/install.js",
|
|
144
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/scatter/ScatterSeries.js",
|
|
145
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/helper/LargeSymbolDraw.js",
|
|
146
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/scatter/ScatterView.js",
|
|
147
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/scatter/install.js",
|
|
148
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/radar/backwardCompat.js",
|
|
149
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/radar/RadarSeries.js",
|
|
150
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/radar/RadarView.js",
|
|
151
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/radar/radarLayout.js",
|
|
152
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/radar/install.js",
|
|
153
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/heatmap/HeatmapLayer.js",
|
|
154
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/heatmap/HeatmapView.js",
|
|
155
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/heatmap/HeatmapSeries.js",
|
|
156
|
+
"../../../../../bluui-charts/node_modules/echarts/lib/chart/heatmap/install.js"
|
|
112
157
|
],
|
|
113
158
|
"sizes": {
|
|
114
159
|
"index": {
|
|
115
|
-
"bytes":
|
|
116
|
-
"gzipBytes":
|
|
160
|
+
"bytes": 94571,
|
|
161
|
+
"gzipBytes": 38879,
|
|
117
162
|
"externalDependencies": "ECharts and Community Chip/Skeleton; engine cost is measured separately by consumer bundles."
|
|
118
163
|
},
|
|
119
164
|
"sparkline": {
|
|
120
|
-
"bytes":
|
|
121
|
-
"gzipBytes":
|
|
165
|
+
"bytes": 14038,
|
|
166
|
+
"gzipBytes": 6194,
|
|
122
167
|
"externalDependencies": "ECharts and Community Chip/Skeleton; engine cost is measured separately by consumer bundles."
|
|
123
168
|
},
|
|
124
169
|
"line": {
|
|
125
|
-
"bytes":
|
|
126
|
-
"gzipBytes":
|
|
170
|
+
"bytes": 61160,
|
|
171
|
+
"gzipBytes": 22878,
|
|
127
172
|
"externalDependencies": "ECharts and Community Chip/Skeleton; engine cost is measured separately by consumer bundles."
|
|
128
173
|
},
|
|
129
174
|
"bar": {
|
|
130
|
-
"bytes":
|
|
131
|
-
"gzipBytes":
|
|
175
|
+
"bytes": 60733,
|
|
176
|
+
"gzipBytes": 22708,
|
|
132
177
|
"externalDependencies": "ECharts and Community Chip/Skeleton; engine cost is measured separately by consumer bundles."
|
|
133
178
|
},
|
|
134
179
|
"pie": {
|
|
135
|
-
"bytes":
|
|
136
|
-
"gzipBytes":
|
|
180
|
+
"bytes": 60538,
|
|
181
|
+
"gzipBytes": 22738,
|
|
137
182
|
"externalDependencies": "ECharts and Community Chip/Skeleton; engine cost is measured separately by consumer bundles."
|
|
138
183
|
},
|
|
139
184
|
"doughnut": {
|
|
140
|
-
"bytes":
|
|
141
|
-
"gzipBytes":
|
|
185
|
+
"bytes": 61084,
|
|
186
|
+
"gzipBytes": 23016,
|
|
142
187
|
"externalDependencies": "ECharts and Community Chip/Skeleton; engine cost is measured separately by consumer bundles."
|
|
143
188
|
},
|
|
144
189
|
"scatter": {
|
|
145
|
-
"bytes":
|
|
146
|
-
"gzipBytes":
|
|
190
|
+
"bytes": 60259,
|
|
191
|
+
"gzipBytes": 22534,
|
|
147
192
|
"externalDependencies": "ECharts and Community Chip/Skeleton; engine cost is measured separately by consumer bundles."
|
|
148
193
|
},
|
|
149
194
|
"radar": {
|
|
150
|
-
"bytes":
|
|
151
|
-
"gzipBytes":
|
|
195
|
+
"bytes": 61088,
|
|
196
|
+
"gzipBytes": 22885,
|
|
152
197
|
"externalDependencies": "ECharts and Community Chip/Skeleton; engine cost is measured separately by consumer bundles."
|
|
153
198
|
},
|
|
154
199
|
"heatmap": {
|
|
155
|
-
"bytes":
|
|
156
|
-
"gzipBytes":
|
|
200
|
+
"bytes": 59659,
|
|
201
|
+
"gzipBytes": 22207,
|
|
157
202
|
"externalDependencies": "ECharts and Community Chip/Skeleton; engine cost is measured separately by consumer bundles."
|
|
158
203
|
},
|
|
159
204
|
"browser": {
|
|
160
|
-
"bytes":
|
|
161
|
-
"gzipBytes":
|
|
205
|
+
"bytes": 734449,
|
|
206
|
+
"gzipBytes": 250664
|
|
162
207
|
}
|
|
163
208
|
}
|
|
164
209
|
}
|
|
@@ -5,7 +5,19 @@ import { themeTokens } from './options.ts';
|
|
|
5
5
|
import { type RuntimeKind, type RuntimeOptions } from './chart-state.ts';
|
|
6
6
|
import './charts.css';
|
|
7
7
|
type Builder = (o: any, t: ReturnType<typeof themeTokens>, mapName?: string, reducedMotion?: boolean, width?: number) => echarts.EChartsCoreOption;
|
|
8
|
+
/** Internal opt-in web presentation. Ordinary/native factories omit this policy. */
|
|
9
|
+
export interface ChartPresentation {
|
|
10
|
+
/** Native integration can opt in/out without replacing the chart. */
|
|
11
|
+
enabled?(): boolean;
|
|
12
|
+
mode(host: HTMLElement): 'full' | 'reduced' | 'off';
|
|
13
|
+
timing?(): {
|
|
14
|
+
duration?: number;
|
|
15
|
+
easing?: string;
|
|
16
|
+
curve?: string;
|
|
17
|
+
};
|
|
18
|
+
subscribe(host: HTMLElement, refresh: () => void): () => void;
|
|
19
|
+
}
|
|
8
20
|
export declare function createCatalogueChart<K extends CatalogueKind>(host: HTMLElement, kind: K, initial: OptionsByKind[K], events: ChartEvents<ChartPoint>, build: Builder): ChartInstance<OptionsByKind[K]>;
|
|
9
21
|
/** One lifecycle for all ECharts families. Sparkline deliberately stays independent. */
|
|
10
|
-
export declare function createChartRuntime<O extends RuntimeOptions, P = ChartPoint>(host: HTMLElement, kind: RuntimeKind, initial: O, events: ChartEvents<P>, build: Builder): ChartInstance<O>;
|
|
22
|
+
export declare function createChartRuntime<O extends RuntimeOptions, P = ChartPoint>(host: HTMLElement, kind: RuntimeKind, initial: O, events: ChartEvents<P>, build: Builder, presentation?: ChartPresentation): ChartInstance<O>;
|
|
11
23
|
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e}from"./chunk-ILTENI35.js";import{g as o}from"./chunk-MR5VITXX.js";import{a as t}from"./chunk-3PITHTEO.js";import{use as f}from"echarts/core";import{HeatmapChart as u}from"echarts/charts";import{GridComponent as C,VisualMapComponent as H}from"echarts/components";function S(a,m,n,p={},i={}){return t(a,n,i,(r,s)=>(f([u,C,H]),o(s,"heatmap",m,p,e,r)))}export{S as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{createComponentMotionState as l,validateComponentMotion as m}from"@blukavantui/community/motion/settings";import{motionEasings as f}from"@blukavantui/community/motion";var p={standard:"cubicOut","ease-in":"cubicIn","ease-out":"cubicOut","ease-in-out":"cubicInOut",linear:"linear",spring:"backOut"};function y(s,c){let n=new Set,r={mode(e){return s.mode==="off"||e.closest('[data-blu-motion="off"], .blu-motion-off')?"off":s.mode==="reduced"||e.closest('[data-blu-motion="reduced"]')?"reduced":"full"},timing(){let e=c?.settings;return{duration:e?.duration,easing:e?.easing?p[e.easing]:void 0,curve:e?.easing?f[e.easing]:void 0}},subscribe(e,i){let a=r.mode(e),t=()=>{a=r.mode(e),i()};n.add(t);let d=new MutationObserver(()=>{r.mode(e)!==a&&t()});for(let o=e;o;o=o.parentElement)d.observe(o,{attributes:!0,attributeFilter:["data-blu-motion","class"]});return()=>{n.delete(t),d.disconnect()}},notify(){for(let e of n)e()}};return r}function M(s,c,n,r){m(n);let e=document.createElement("div");e.className="blu-chart-motion-scope",s.append(e);let i=l(e,c,n),a=y(c,i),t;try{t=r(a,e)}catch(u){throw i.destroy(),e.remove(),u}let d=t.destroy.bind(t),o=!1;return t.destroy=()=>{o||(o=!0,d(),i.destroy(),e.remove())},Object.assign(t,{setMotion(u={}){if(o)throw Error("Chart motion is destroyed.");i.update(u),a.notify()}})}export{M as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as r}from"./chunk-EITBQBN2.js";import{g as o}from"./chunk-MR5VITXX.js";import{a as t}from"./chunk-3PITHTEO.js";import{use as C}from"echarts/core";import{BarChart as f}from"echarts/charts";import{GridComponent as u}from"echarts/components";function l(n,i,e,m={},a={}){return t(n,e,a,(p,s)=>(C([f,u]),o(s,"bar",i,m,r,p)))}export{l as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as r}from"./chunk-UO2KNHTU.js";import{g as o}from"./chunk-MR5VITXX.js";import{a as t}from"./chunk-3PITHTEO.js";import{use as u}from"echarts/core";import{PieChart as C}from"echarts/charts";function M(i,e,n,m={},p={}){return t(i,n,p,(a,s)=>(u([C]),o(s,"pie",e,m,r,a)))}export{M as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as n}from"./chunk-WJ3UHH6J.js";import{g as o}from"./chunk-MR5VITXX.js";import{a as t}from"./chunk-3PITHTEO.js";import{use as C}from"echarts/core";import{LineChart as f}from"echarts/charts";import{GridComponent as u}from"echarts/components";function S(r,i,e,m={},p={}){return t(r,e,p,(a,s)=>(C([f,u]),o(s,"line",i,m,n,a)))}export{S as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as v,b}from"./chunk-RXOGAN23.js";import{a as S}from"./chunk-3PITHTEO.js";function g(o,u,m,r){let i=structuredClone(u),a=!1,s=!1,l=()=>{if(r.enabled?.()===!1)return{...i};let e=i.Animation??(i.AnimateGlow===!1?"Off":"Once");return{...i,Animation:r.mode(o)!=="full"||e==="Once"&&r.timing?.().duration===0?"Off":e}};function c(){if(r.enabled?.()===!1||l().Animation!=="Once")return;let e=r.timing?.();for(let n of t.element.querySelectorAll("animateMotion")){e?.duration!==void 0&&n.setAttribute("dur",e.duration/1e3+"s");let k=e?.curve?.match(/^cubic-bezier\((.+)\)$/)?.[1];k?(n.setAttribute("calcMode","spline"),n.setAttribute("keyTimes","0;1"),n.setAttribute("keySplines",k.split(",").map(A=>Math.max(0,Math.min(1,Number(A)))).join(" "))):e?.curve==="linear"&&n.setAttribute("calcMode","linear")}}let t=b(o,l(),m),p=t.update,M=t.destroy,f=e=>{if(!(e.target instanceof Element)||!e.target.closest(".blu-sparkline__pause"))return;let n=t.element.querySelector("svg");n?.animationsPaused&&(s=n.animationsPaused())};t.element.addEventListener("click",f);let d=()=>{let e=t.element.querySelector("svg");s&&e?.animationsPaused&&!e.animationsPaused()&&t.element.querySelector(".blu-sparkline__pause")?.click()};c();let y=r.subscribe(o,()=>{p(l()),c(),d()});return t.update=e=>{if(a)throw Error("Component is destroyed.");let n={...i,...structuredClone(e)};v(n),e.Animation!==void 0&&e.Animation!==i.Animation&&(s=!1),i=n,p(l()),c(),d()},t.destroy=()=>{a||(a=!0,y(),t.element.removeEventListener("click",f),M())},t}function L(o,u,m,r={},i={}){return S(o,m,i,(a,s)=>g(s,u,r,a))}export{L as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as o}from"./chunk-WJ3UHH6J.js";import{f as t}from"./chunk-MR5VITXX.js";import{use as n}from"echarts/core";import{LineChart as p}from"echarts/charts";import{GridComponent as a}from"echarts/components";function f(r,e,i={}){return n([p,a]),t(r,"line",e,i,o)}export{f as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as r}from"./chunk-NXDBBMF5.js";import{g as o}from"./chunk-MR5VITXX.js";import{a as t}from"./chunk-3PITHTEO.js";import{use as c}from"echarts/core";import{ScatterChart as C}from"echarts/charts";import{GridComponent as f}from"echarts/components";function l(e,n,i,m={},a={}){return t(e,i,a,(p,s)=>(c([C,f]),o(s,"scatter",n,m,r,p)))}export{l as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as s,d as l,e as C,h as L,j as x,k as O,l as $,m as w,n as f}from"./chunk-MR5VITXX.js";import{i as k,k as u}from"./chunk-RC2TCMJF.js";function Q(p,t,F,T=!1,N=640){let o=p,v=C("bar",p),g=(e,a)=>o.ShowPatterns?$(e,a):void 0,m=t.palette,i=(e,a)=>L(t.forcedColors?t.text:k(e,m[a%m.length],t.dark,t.read),t.surface,3.2),z=(e,a,r)=>f(i(a,r),t.surface,o.SelectedKey===e),P=(e,a)=>v.find(r=>r.Key===e&&(!a||r.SeriesKey===a)),K={data:["line","radar","bar","polar"].includes("bar")?o.Series.map(e=>e.Label):["pie","doughnut","nightingale","funnel"].includes("bar")?[...new Set(o.Items.map(e=>e.Label))]:[],show:o.ShowLegend,type:"scroll",top:6,left:10,right:10,itemWidth:24,itemHeight:12,selectedMode:!1,pageTextStyle:{color:t.muted},pageIconColor:t.text,textStyle:{color:t.muted,fontSize:11}},A={show:o.ShowLabels,color:u(t.surface),fontSize:11,backgroundColor:t.surface,padding:[2,3],borderRadius:2},D={show:o.ShowTooltip,confine:!0,enterable:!0,backgroundColor:t.surface,borderColor:t.border,textStyle:{color:t.text,fontSize:12},formatter:e=>{let a=e.data?.point;if(!a)return`${l(e.name||"")}${e.value==null||Number.isNaN(e.value)?" \xB7 No data":""}`;let r=a.Date?`<br/>${l(a.Date)}<br/><strong>${l(s(a.Value,o))}</strong>`:a.X!==void 0?`<br/>${l(o.XLabel||"X")}: ${a.X}<br/>${l(o.YLabel||"Y")}: ${a.Y}${a.Size===void 0?"":`<br/>Size: ${a.Size}`}`:`<br/><strong>${l(s(a.Value,o))}</strong>`;return`${l(a.SeriesName?`${a.SeriesName} \xB7 ${a.Label}`:a.Label)}${r}${e.data?.conversion?`<br/>${l(e.data.conversion)}`:""}`}},V={backgroundColor:t.surface,color:m.map((e,a)=>i(e,a)),animation:!!o.EnableAnimation&&!T,animationDuration:300,animationDurationUpdate:150,textStyle:{fontFamily:"Inter,system-ui,sans-serif",color:t.text},aria:{enabled:!0,description:`${o.Title}. ${o.Description||""} Exact values and keyboard selection are in the data table.`},tooltip:D},d={axisLine:{show:!1},axisTick:{show:!1},axisLabel:{color:t.muted,fontSize:10,hideOverlap:!0},splitLine:{lineStyle:{color:t.border,type:"dashed"}}},n=p,c=n.Stacking==="Percent",S={...d,type:"category",data:n.Categories.map(e=>e.Label),axisLabel:{...d.axisLabel,width:Math.min(140,N*.2),overflow:"truncate"},splitLine:{show:!1}},h={...d,type:"value",max:c?1:void 0,axisLabel:{...d.axisLabel,formatter:e=>c?`${Math.round(e*100)}%`:s(e,o,!0)}},b=!!n.Stacking&&n.Stacking!=="None",M=n.Series.map((e,a)=>({id:e.Key,name:e.Label,type:"bar",coordinateSystem:"cartesian2d",stack:n.Stacking&&n.Stacking!=="None"?"total":void 0,smooth:n.LineStyle==="Smooth",step:n.LineStyle==="Step"?"middle":!1,connectNulls:!1,areaStyle:n.ShowArea?{opacity:.1}:void 0,barMaxWidth:38,symbol:x(a),symbolSize:8,itemStyle:{...f(i(e.Color,a),t.surface),decal:g(a,i(e.Color,a))},lineStyle:{width:2.5,color:i(e.Color,a),type:O(a)},label:{...A,color:b?u(i(e.Color,a)):u(t.surface),backgroundColor:b?i(e.Color,a):t.surface,position:b?"inside":n.Orientation==="Horizontal"?"right":"top",formatter:r=>c?`${Math.round(Number(r.value)*100)}%`:s(r.data.point.Value,o,!0)},labelLayout:{hideOverlap:!0},emphasis:{focus:"none",scale:!1},blur:{itemStyle:{opacity:1},lineStyle:{opacity:1},label:{opacity:1}},data:e.Values.map((r,y)=>({value:r===null?null:c?r/(n.Series.reduce((H,E)=>H+(E.Values[y]||0),0)||1):r,point:P(n.Categories[y].Key,e.Key),itemStyle:{...z(n.Categories[y].Key,e.Color,a),decal:g(a,i(e.Color,a))},emphasis:{itemStyle:w(i(e.Color,a))}}))}));return{...V,legend:K,grid:{left:14,right:22,top:o.ShowLegend?48:20,bottom:16,containLabel:!0},xAxis:n.Orientation==="Horizontal"?h:S,yAxis:n.Orientation==="Horizontal"?{...S,inverse:!0}:h,series:M}}export{Q as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as r}from"./chunk-NXDBBMF5.js";import{f as t}from"./chunk-MR5VITXX.js";import{use as p}from"echarts/core";import{ScatterChart as i}from"echarts/charts";import{GridComponent as n}from"echarts/components";function y(o,e,a={}){return p([i,n]),t(o,"scatter",e,a,r)}export{y as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as r}from"./chunk-EITBQBN2.js";import{f as t}from"./chunk-MR5VITXX.js";import{use as p}from"echarts/core";import{BarChart as i}from"echarts/charts";import{GridComponent as n}from"echarts/components";function f(o,a,e={}){return p([i,n]),t(o,"bar",a,e,r)}export{f as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as u,b as f,c as h,d as s,h as d,i as x,m as C,n as y}from"./chunk-MR5VITXX.js";import{f as m,h as p,j as l,k as b}from"./chunk-RC2TCMJF.js";function g(e,t){return{backgroundColor:t.surface,animation:e.EnableAnimation&&!matchMedia("(prefers-reduced-motion: reduce)").matches,animationDuration:350,animationDurationUpdate:180,textStyle:{fontFamily:"Inter, system-ui, sans-serif",color:t.text},aria:{enabled:!0,description:`${e.Title}. ${e.Description||""} Exact values and keyboard selections are available in the chart data table.`},tooltip:{show:e.ShowTooltip,confine:!0,enterable:!0,backgroundColor:t.surface,borderColor:t.border,textStyle:{color:t.text,fontSize:12},extraCssText:"border-radius:8px;box-shadow:0 8px 28px #0002;"}}}function c(e){return{axisLine:{show:!1},axisTick:{show:!1},axisLabel:{color:e.muted,fontSize:11}}}function D(e,t){let{min:a,max:n}=h(e),S=p(m(e.ColorScale)?e.ColorScale:"Purple",t.dark,t.read),T=t.forcedColors?t.text:e.ColorScale==="Automatic"?t.palette[0]:e.ColorScale==="Teal"?"#126e5b":S.solid,i=e.ColorScale==="Diverging"&&!t.forcedColors?[d("#ba5943",t.surface,9),d(t.surface,t.surface),d("#6850bf",t.surface,9)]:x(T,t.surface);return{...g(e,t),grid:{left:12,right:12,top:16,bottom:e.ShowLegend?62:12,containLabel:!0},tooltip:{...g(e,t).tooltip,formatter:r=>{let o=f(e,r.dataIndex);return`${s(o.YLabel)} \xB7 ${s(o.XLabel)}<br/><strong>${s(u(o.Value,e))}</strong>`}},xAxis:{...c(t),type:"category",data:e.XCategories.map(r=>r.Label),axisLabel:{...c(t).axisLabel,hideOverlap:!0,width:120,overflow:"truncate"}},yAxis:{...c(t),type:"category",inverse:!0,data:e.YCategories.map(r=>r.Label),axisLabel:{...c(t).axisLabel,width:80,overflow:"truncate"}},visualMap:{show:e.ShowLegend,min:a,max:n,calculable:!1,orient:"horizontal",left:"center",bottom:6,itemWidth:9,itemHeight:130,text:["Higher","Lower"],textGap:9,textStyle:{color:t.muted,fontSize:10},inRange:{color:i}},series:[{type:"heatmap",data:e.Cells.map(r=>({name:r.Key,value:[e.XCategories.findIndex(o=>o.Key===r.XKey),e.YCategories.findIndex(o=>o.Key===r.YKey),r.Value??"-"],itemStyle:{...y(l(i,((r.Value??a)-a)/(n-a)),t.surface,e.SelectedKey===r.Key),borderRadius:4},label:{color:b(l(i,((r.Value??a)-a)/(n-a)))},emphasis:{itemStyle:C(l(i,((r.Value??a)-a)/(n-a)))}})),label:{show:e.ShowLabels,fontSize:10,formatter:r=>u(e.Cells[r.dataIndex].Value,e,!0)},emphasis:{itemStyle:{borderColor:t.text,borderWidth:2,borderType:"solid"}}}]}}export{D as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as p}from"./chunk-ILTENI35.js";import{g as o}from"./chunk-MR5VITXX.js";import{use as i}from"echarts/core";import{HeatmapChart as s}from"echarts/charts";import{GridComponent as h,VisualMapComponent as C}from"echarts/components";function r(t,e,a,n,m){return o(t,e,a,n,m)}function d(t,e,a={}){return i([s,h,C]),r(t,"heatmap",e,a,p)}export{d as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as o}from"./chunk-UQMMBG26.js";import{f as t}from"./chunk-MR5VITXX.js";import{use as p}from"echarts/core";import{PieChart as i}from"echarts/charts";function s(r,e,n={}){return p([i]),t(r,"doughnut",e,n,o)}export{s as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as H,b as ue,c as B,d as j,e as ot,f as it,g as pe,j as Le,k as Ie}from"./chunk-RC2TCMJF.js";import*as Ne from"echarts/core";import{LabelLayout as Ht,LegacyGridContainLabel as Dt}from"echarts/features";import{TooltipComponent as zt,AriaComponent as Gt,GraphicComponent as Ft}from"echarts/components";import{SVGRenderer as Ut}from"echarts/renderers";var lt={Title:"Chart",Description:"",Height:320,ValueFormat:"Number",CurrencyCode:"USD",Locale:"en-US",UseCustomPrecision:!1,DecimalPlaces:2,AccessibleLabel:"",ExtendedClass:"",ResetKey:"",Messages:{},ShowHeader:!0,ShowToolbar:!0,ShowLegend:!0,LegendStyle:"Standard",LegendPosition:"Top",LegendShowValues:!0,LegendShowPercentages:!1,ShowTooltip:!0,ShowLabels:!1,ShowDataTable:!0,ShowPatterns:!1,EnableSelection:!0,EnableAnimation:!0,IsLoading:!1,EmptyMessage:"No data to display",SelectedKey:null,ExportFootnote:"BluKavantUI Charts"};function ee(n,a,e=!1){return n===null?a.Messages?.NoData??"No data":new Intl.NumberFormat(a.Locale||"en-US",{style:a.ValueFormat==="Currency"?"currency":a.ValueFormat==="Percent"?"percent":"decimal",currency:a.CurrencyCode||"USD",notation:e?"compact":"standard",...e?{maximumFractionDigits:1}:a.UseCustomPrecision?{minimumFractionDigits:a.DecimalPlaces??2,maximumFractionDigits:a.DecimalPlaces??2}:a.ValueFormat==="Currency"?{}:{maximumFractionDigits:12}}).format(n)}function st(n,a){return n===null?"No data":a??String(n)}function ct(n,a,e=0){let t=n.Categories[a],i=n.Series[e];return t&&i?{Key:t.Key,CategoryLabel:t.Label,SeriesKey:i.Key,SeriesName:i.Name,Value:i.Values[a]}:null}function dt(n,a){let e=n.Cells[a];return e?{...e,XLabel:n.XCategories.find(t=>t.Key===e.XKey).Label,YLabel:n.YCategories.find(t=>t.Key===e.YKey).Label}:null}function Wt(n){let a=0,e=0;for(let t of n.Cells)t.Value!==null&&(a=Math.min(a,t.Value),e=Math.max(e,t.Value));return a=n.MinValue??a,e=n.MaxValue??e,a>=e&&(n.MaxValue!==void 0?a=e-1:e=a+1),{min:a,max:e}}function c(n,a){if(!n)throw new Error(a)}function he(n,a){B(n,a);let e=new Set;for(let t of n)c(t&&j(t.Key)&&t.Key.length>0&&j(t.Label),`${a} require a non-empty Key and a Label within the text limit.`),c(!e.has(t.Key),`${a} contain a duplicate key: ${t.Key}.`),e.add(t.Key);return e}function ye(n){return n===null||ue(n)}function Ke(n){c(n.Height===void 0||Number.isFinite(n.Height)&&n.Height>=160&&n.Height<=1e3,"Height must be between 160 and 1000 pixels."),c(n.ValueFormat===void 0||["Currency","Number","Percent"].includes(n.ValueFormat),"Invalid ValueFormat.");for(let a of["UseCustomPrecision","ShowHeader","ShowToolbar","ShowLegend","LegendShowValues","LegendShowPercentages","ShowTooltip","ShowLabels","ShowDataTable","ShowPatterns","EnableSelection","EnableAnimation","IsLoading"])c(n[a]===void 0||typeof n[a]=="boolean",`${a} must be a boolean.`);for(let a of["AccessibleLabel","ExtendedClass","ResetKey","Title","Description","EmptyMessage","ExportFootnote","Locale","CurrencyCode"])c(n[a]===void 0||j(n[a]),`${a} must be text within the text limit.`);c(n.LegendStyle===void 0||["Standard","ValueList","Compact","SummaryCards"].includes(n.LegendStyle),"Invalid LegendStyle."),c(n.LegendPosition===void 0||["Top","Left","Right","Bottom"].includes(n.LegendPosition),"Invalid LegendPosition."),c(n.DecimalPlaces===void 0||Number.isInteger(n.DecimalPlaces)&&n.DecimalPlaces>=0&&n.DecimalPlaces<=12,"DecimalPlaces must be an integer from 0 to 12."),c(n.Messages===void 0||!!n.Messages&&typeof n.Messages=="object"&&!Array.isArray(n.Messages)&&Object.keys(n.Messages).length<=100&&Object.values(n.Messages).every(j),"Messages must contain plain text translations."),new Intl.NumberFormat(n.Locale||"en-US",n.ValueFormat==="Currency"?{style:"currency",currency:n.CurrencyCode||"USD"}:{})}function ut(n){Ke(n);let a=he(n.Categories,"Categories");c(n.SelectedKey==null||a.has(n.SelectedKey),"SelectedKey must match a category."),c(n.BarLayout===void 0||["Stacked","Grouped"].includes(n.BarLayout),"Invalid BarLayout."),c(n.SmoothLines===void 0||typeof n.SmoothLines=="boolean","SmoothLines must be a boolean."),B(n.Series,"Series"),c(n.Categories.length*n.Series.length<=H.observations,"Too many chart observations. Aggregate the data first.");let e=new Set;for(let t of n.Series)c(t&&j(t.Key)&&t.Key.length&&!e.has(t.Key),"Each series needs a unique, non-empty Key."),e.add(t.Key),c(j(t.Name)&&["Bar","Line"].includes(t.Type),"Each series needs a Name and a Bar or Line Type."),c(Array.isArray(t.Values)&&t.Values.length===n.Categories.length,`${t.Key}: Values must match the category count.`),c(t.Values.every(ye),`${t.Key}: Values must be finite numbers or null.`),c(t.Color===void 0||pe(t.Color),"Series Color must be a ComponentColor or hex color."),c(t.IsDashed===void 0||typeof t.IsDashed=="boolean","IsDashed must be a boolean.")}function pt(n){Ke(n);let a=he(n.XCategories,"XCategories"),e=he(n.YCategories,"YCategories");B(n.Cells,"Cells"),c(a.size*e.size<=H.observations,"Too many heatmap positions. Aggregate the data first.");let t=new Set,i=new Set;for(let r of n.Cells){c(r&&typeof r.Key=="string"&&r.Key.length&&!t.has(r.Key),"Each cell needs a unique, non-empty Key."),c(a.has(r.XKey)&&e.has(r.YKey),`${r.Key}: XKey and YKey must match category keys.`);let o=JSON.stringify([r.XKey,r.YKey]);c(!i.has(o),"Only one cell may occupy each X/Y position."),c(ye(r.Value),`${r.Key}: Value must be a finite number or null.`),i.add(o),t.add(r.Key)}c(n.SelectedKey==null||t.has(n.SelectedKey),"SelectedKey must match a cell."),c(n.ColorScale===void 0||it(n.ColorScale)||["Automatic","Teal","Diverging"].includes(n.ColorScale),"Invalid ColorScale."),c(n.MinValue===void 0||Number.isFinite(n.MinValue),"MinValue must be finite."),c(n.MaxValue===void 0||Number.isFinite(n.MaxValue),"MaxValue must be finite."),c(n.MinValue===void 0||n.MaxValue===void 0||n.MinValue<n.MaxValue,"MinValue must be less than MaxValue.")}function f(n){return n.replace(/[&<>"']/g,a=>({"&":"&","<":"<",">":">",'"':""","'":"'"})[a])}function He(n){let a=getComputedStyle(n),e=(r,o)=>a.getPropertyValue(r).trim()||o,t=document.documentElement.dataset.bluuiTheme==="dark",i=matchMedia("(forced-colors: active)").matches;if(i){let r=document.createElement("span");r.style.cssText="position:absolute;visibility:hidden;color:Canvas;background-color:CanvasText;forced-color-adjust:none",n.append(r);let o=getComputedStyle(r),p=o.color,d=o.backgroundColor;return r.remove(),{surface:p,text:d,muted:d,border:d,dark:t,forcedColors:i,read:()=>"",palette:Array(8).fill(d)}}return{forcedColors:i,surface:e("--bluui-surface","#fff"),text:e("--bluui-text","#182230"),muted:e("--bluui-text-muted","#667085"),border:e("--bluui-border","#e3e5ed"),dark:t,read:r=>a.getPropertyValue(r),palette:ot(t)}}function ht(n){let a="",e=0;return{update(t){if(t===a)return;let i=!a;if(a=t,window.clearTimeout(e),i){n.textContent=t;return}n.textContent="",e=window.setTimeout(()=>{n.isConnected&&(n.textContent=t)},150)},destroy(){window.clearTimeout(e)}}}import{createSkeleton as De}from"@blukavantui/community/skeleton";import"@blukavantui/community/skeleton.css";function gt(n){let a=document.createElement("div");a.className="blu-chart__skeleton",a.setAttribute("aria-hidden","true");let e=document.createElement("div");e.className="blu-chart__skeleton-key";let t=document.createElement("div"),i=document.createElement("div");e.append(t,i);let r=document.createElement("div");r.className="blu-chart__skeleton-plot",a.append(e,r);let o=document.createElement("span");o.className="blu-chart__state-message",n.replaceChildren(a,o);let p=[De(t,{Shape:"Text",Width:"88px",Height:"12px",IsAnimated:!1}),De(i,{Shape:"Text",Width:"64px",Height:"12px",IsAnimated:!1}),De(r,{Shape:"Rectangle",Width:"100%",Height:"100%",IsAnimated:!1})],d=!1;return{update(l,w,h,_){n.hidden=!l&&!w,n.classList.toggle("blu-chart__state--loading",l),a.hidden=!l,o.textContent=h;let x=l&&_;x!==d&&(d=x,p.forEach(y=>y.update({IsAnimated:x})))},destroy(){p.forEach(l=>l.destroy())}}}import{createChip as Vt}from"@blukavantui/community/chip";import"@blukavantui/community/chip.css";function oe(n,a,e,t={}){return(n.Messages?.[a]??e).replace(/\{(\w+)\}/g,(i,r)=>t[r]??i)}function q(n,a,e="Label"){B(n,a);let t=new Set;for(let i of n)c(i&&j(i.Key)&&i.Key.length&&!t.has(i.Key),`${a} require unique, non-empty keys.`),c(!e||j(i[e]),`${i.Key}: ${e} must be text within the text limit.`),c(i.Color===void 0||pe(i.Color),`${i.Key}: Color must be a shared ComponentColor or hex color.`),t.add(i.Key);return t}var J=ue;function Me(n){return n===null||J(n)&&n>=0}function z(n,a,e){c(n[a]===void 0||e.includes(n[a]),`Invalid ${a}. Choose ${e.join(", ")}.`)}function Ee(n){c(n?.type==="FeatureCollection"&&Array.isArray(n.features)&&n.features.length>0,"GeoJSON must be a non-empty FeatureCollection."),B(n.features,"Map features",H.mapFeatures);let a=0,e=new Set;n.features.forEach(t=>{c(t?.type==="Feature"&&typeof t.properties?.name=="string"&&t.properties.name.length&&!e.has(t.properties.name),"Each map feature needs a unique properties.name region key."),e.add(t.properties.name),c(["Polygon","MultiPolygon"].includes(t.geometry?.type),"Map geometry must be Polygon or MultiPolygon.");let i=t.geometry.type==="Polygon"?[t.geometry.coordinates]:t.geometry.coordinates;c(Array.isArray(i)&&i.length>0,"Map polygons must contain coordinates.");for(let r of i){c(Array.isArray(r)&&r.length>0,"Each polygon needs rings.");for(let o of r)c(Array.isArray(o)&&o.length>=4,"Each polygon ring needs at least four coordinates."),a+=o.length,c(a<=H.mapCoordinates,"Map has too many coordinates. Use a simplified boundary file."),o.forEach(p=>c(Array.isArray(p)&&p.length>=2&&J(p[0])&&J(p[1])&&Math.abs(p[0])<=180&&Math.abs(p[1])<=90,"Map coordinates must be longitude/latitude in degrees.")),c(o[0][0]===o.at(-1)[0]&&o[0][1]===o.at(-1)[1],"Polygon rings must close.")}})}function ze(n){return typeof n=="string"&&/^\d{4}-\d{2}-\d{2}$/.test(n)&&Number.isFinite(Date.parse(n+"T00:00:00Z"))&&new Date(n+"T00:00:00Z").toISOString().slice(0,10)===n}function mt(n,a){Ke(a),"Series"in a&&(B(a.Series,"Series"),B(a.Categories,"Categories"),c(a.Series.length*a.Categories.length<=H.observations,"Too many chart observations. Aggregate the data first."));for(let e of["ShowArea","Nested","Bubble","Drilldown","ShowConversion","Roam"])c(a[e]===void 0||typeof a[e]=="boolean",`${e} must be a boolean.`);if(n==="radar"){let e=a;he(e.Categories,"Categories"),c(e.Categories.length===0||e.Categories.length>=3&&e.Categories.length<=12,"Radar needs 3\u201312 categories, or an empty array for an empty state."),q(e.Series,"Series"),e.Categories.forEach(t=>c(t.Max===void 0||J(t.Max)&&t.Max>0,`${t.Key}: Max must be a positive number.`)),e.Series.forEach(t=>{c(Array.isArray(t.Values)&&t.Values.length===e.Categories.length&&t.Values.every(Me),`${t.Key}: Values must match categories and contain non-negative numbers or null.`),t.Values.forEach((i,r)=>c(i===null||e.Categories[r].Max===void 0||i<=e.Categories[r].Max,`${t.Key}: Value exceeds ${e.Categories[r].Label} Max.`))}),z(e,"GridShape",["Polygon","Circle"]),c(e.SplitNumber===void 0||Number.isInteger(e.SplitNumber)&&e.SplitNumber>=2&&e.SplitNumber<=8,"SplitNumber must be an integer from 2 to 8."),c(e.ShowAxisBounds===void 0||typeof e.ShowAxisBounds=="boolean","ShowAxisBounds must be Boolean.")}else if(["line","bar","polar"].includes(n)){let e=a;he(e.Categories,"Categories"),q(e.Series,"Series"),e.Series.forEach(t=>{c(Array.isArray(t.Values)&&t.Values.length===e.Categories.length&&t.Values.every(ye),`${t.Key}: Values must match categories and contain finite numbers or null.`),e.Stacking==="Percent"&&c(t.Values.every(i=>i===null||i>=0),"Percentage stacks require non-negative values.")}),z(e,"Orientation",["Vertical","Horizontal"]),z(e,"Stacking",["None","Stacked","Percent"]),z(e,"LineStyle",["Straight","Smooth","Step"]),z(e,"PolarType",["Bar","Line"])}else if(["pie","doughnut","nightingale","funnel"].includes(n)){let e=a;if(q(e.Items,"Items"),e.Items.forEach(t=>c(Me(t.Value),`${t.Key}: Value must be non-negative or null.`)),n!=="funnel"){let t=q(e.Rings||[],"Rings");e.Items.forEach(i=>c(!i.RingKey||t.has(i.RingKey),`${i.Key}: RingKey must match a ring.`)),e.Nested&&(c(t.size>0,"Nested charts need Rings."),e.Items.forEach(i=>c(i.RingKey&&t.has(i.RingKey),`${i.Key}: nested items need RingKey.`))),z(e,"Shape",["Full","Half"]),z(e,"LabelPosition",["Outside","Inside"]),z(e,"RoseMode",["Area","Radius"]),c(e.InnerRadius===void 0||J(e.InnerRadius)&&e.InnerRadius>=0&&e.InnerRadius<=75,"InnerRadius must be 0\u201375 percent."),c(e.CenterLabel===void 0||typeof e.CenterLabel=="string","CenterLabel must be text.")}else z(a,"Sort",["Input","Descending","Ascending"])}else if(n==="calendar-heatmap"){let e=a;c(ze(e.RangeStart)&&ze(e.RangeEnd),"RangeStart and RangeEnd must be real dates in YYYY-MM-DD format.");let t=(Date.parse(e.RangeEnd)-Date.parse(e.RangeStart))/864e5;c(t>=0&&t<=365,"Choose a calendar range of 1\u2013366 days."),q(e.Items,"Items");let i=new Set;e.Items.forEach(r=>{c(ze(r.Date),`${r.Key}: Date must be a real YYYY-MM-DD date.`),c(r.Date>=e.RangeStart&&r.Date<=e.RangeEnd,`${r.Key}: Date must be within the calendar range.`),c(!i.has(r.Date),"Use one item per date. Aggregate observations before passing the data."),c(Me(r.Value),`${r.Key}: Value must be non-negative or null.`),i.add(r.Date)}),z(e,"FirstDay",["Monday","Sunday"]),c(e.ColorScale===void 0||e.ColorScale==="Automatic"||pe(e.ColorScale),"Invalid ColorScale.");for(let r of["ShowMonthLabels","ShowDayLabels"])c(e[r]===void 0||typeof e[r]=="boolean",`${r} must be a boolean.`)}else if(n==="scatter"){let e=a;q(e.Points,"Points"),e.Points.forEach(t=>{c(J(t.X)&&J(t.Y),`${t.Key}: X and Y must be finite numbers.`),c(t.Size===void 0||J(t.Size)&&t.Size>=0,`${t.Key}: Size must be non-negative.`),c(t.Group===void 0||typeof t.Group=="string","Group must be text.")});for(let t of["XLabel","YLabel"])c(e[t]===void 0||typeof e[t]=="string",`${t} must be text.`)}else if(n==="treemap"){let e=a,t=q(e.Nodes,"Nodes");e.Nodes.forEach(o=>{c(o.ParentKey===null||typeof o.ParentKey=="string"&&t.has(o.ParentKey),`${o.Key}: ParentKey must be null or match a node.`),c(Me(o.Value),`${o.Key}: Value must be non-negative or null.`)});let i=Te(e.Nodes),r=new Set(e.Nodes.map(o=>o.ParentKey));e.Nodes.forEach(o=>{r.has(o.Key)&&o.Value!==null&&c(i.get(o.Key)!==null&&Math.abs(i.get(o.Key)-o.Value)<1e-6,`${o.Key}: branch Value must equal its leaf total, or use null to calculate it.`)})}else if(n==="sankey"){let e=a,t=q(e.Nodes,"Nodes");q(e.Links,"Links",""),B(e.Nodes,"Flow nodes",H.flowNodes),B(e.Links,"Flow links",H.flowLinks);let i=new Map(e.Nodes.map(l=>[l.Key,[]]));e.Links.forEach(l=>{c(t.has(l.SourceKey)&&t.has(l.TargetKey),`${l.Key}: link endpoints must match node keys.`),c(J(l.Value)&&l.Value>=0,`${l.Key}: Value must be non-negative.`),i.get(l.SourceKey).push(l.TargetKey)});let r=new Map,o=new Map;for(let l of e.Links)r.set(l.TargetKey,(r.get(l.TargetKey)||0)+l.Value),o.set(l.SourceKey,(o.get(l.SourceKey)||0)+l.Value);c([...r.values(),...o.values()].every(ue),"Flow totals exceed the supported numeric range.");let p=new Map(e.Nodes.map(l=>[l.Key,0]));e.Links.forEach(l=>p.set(l.TargetKey,p.get(l.TargetKey)+1));let d=[...p].filter(([,l])=>!l).map(([l])=>l);for(let l=0;l<d.length;l++)for(let w of i.get(d[l])){let h=p.get(w)-1;p.set(w,h),h||d.push(w)}c(d.length===t.size,"Sankey links cannot contain cycles."),z(e,"Orientation",["Horizontal","Vertical"]),z(e,"NodeAlign",["Justify","Left","Right"]),c(e.Links.every(l=>!t.has(l.Key)),"Link keys must be distinct from node keys.")}else{let e=a;q(e.Regions,"Regions"),q(e.Locations,"Locations"),e.Regions.forEach(t=>c(ye(t.Value),`${t.Key}: Value must be finite or null.`)),e.Locations.forEach(t=>{c(J(t.Longitude)&&Math.abs(t.Longitude)<=180&&J(t.Latitude)&&Math.abs(t.Latitude)<=90,`${t.Key}: invalid longitude/latitude.`),c(J(t.Value)&&t.Value>=0,`${t.Key}: Value must be non-negative.`)}),c(e.Locations.every(t=>!e.Regions.some(i=>i.Key===t.Key)),"Location and region keys must be distinct."),z(e,"Map",["World","US","Custom"]),z(e,"MapView",["Mainland","Full"]),c(e.MapURL===void 0||j(e.MapURL)&&!!e.MapURL,"MapURL must be non-empty text."),c(!e.MapURL||!e.GeoJSON,"Supply either MapURL or GeoJSON, not both."),c(!e.MapURL||e.Map==="Custom","MapURL requires Map Custom."),z(e,"MapMode",["Regions","Locations","Combined"]),c(e.ColorScale===void 0||e.ColorScale==="Automatic"||pe(e.ColorScale),"Invalid ColorScale."),e.GeoJSON!==void 0&&Ee(e.GeoJSON),e.Map==="Custom"&&(c(e.GeoJSON||e.MapURL,"Custom maps need GeoJSON or MapURL."),e.GeoJSON&&ge(e,e.GeoJSON))}c(a.SelectedKey==null||Ge(n,a).some(e=>e.Key===a.SelectedKey),"SelectedKey must match an input key.")}function ge(n,a){let e=new Set(a.features.map(t=>t.properties.name));n.Regions.forEach(t=>c(e.has(t.Key),`Region ${t.Key} does not exist in this map. Use its properties.name key.`))}function Te(n){B(n,"Tree nodes",H.treeNodes);let a=new Map,e=new Map;for(let i of n){let r=a.get(i.ParentKey)||[];r.push(i),a.set(i.ParentKey,r)}let t=(a.get(null)||[]).map(i=>({n:i,depth:1}));for(let i=0;i<t.length;i++){let{n:r,depth:o}=t[i];c(o<=H.treeDepth,"Tree exceeds maximum depth.");for(let p of a.get(r.Key)||[])t.push({n:p,depth:o+1});c(t.length<=n.length,"Tree nodes cannot contain cycles.")}c(t.length===n.length,"Tree nodes cannot contain cycles or disconnected parents.");for(let i=t.length-1;i>=0;i--){let r=t[i].n,o=a.get(r.Key)||[],p=o.map(l=>e.get(l.Key)).filter(l=>l!=null),d=o.length?p.length?p.reduce((l,w)=>l+w,0):null:r.Value;c(d===null||ue(d),"Tree total exceeds the supported numeric range."),e.set(r.Key,d)}return e}function Ge(n,a){if(n==="radar"){let t=a;return t.Series.flatMap(i=>t.Categories.map((r,o)=>({Key:i.Key,Label:r.Label,Value:i.Values[o],CategoryKey:r.Key,SeriesKey:i.Key,SeriesName:i.Label})))}if(["line","bar","polar"].includes(n)){let t=a;return t.Series.flatMap(i=>t.Categories.map((r,o)=>({Key:r.Key,Label:r.Label,Value:i.Values[o],SeriesKey:i.Key,SeriesName:i.Label})))}if(["pie","doughnut","nightingale","funnel"].includes(n))return a.Items.map(t=>({Key:t.Key,Label:t.Label,Value:t.Value,RingKey:t.RingKey}));if(n==="calendar-heatmap")return a.Items.map(t=>({...t}));if(n==="scatter")return a.Points.map(t=>({...t,Value:t.Y}));if(n==="treemap"){let t=a,i=Te(t.Nodes);return t.Nodes.map(r=>({Key:r.Key,Label:r.Label,Value:i.get(r.Key),ParentKey:r.ParentKey}))}if(n==="sankey"){let t=a;return[...t.Nodes.map(i=>({Key:i.Key,Label:i.Label,PointType:"Node",Value:Math.max(t.Links.filter(r=>r.SourceKey===i.Key).reduce((r,o)=>r+o.Value,0),t.Links.filter(r=>r.TargetKey===i.Key).reduce((r,o)=>r+o.Value,0))})),...t.Links.map(i=>({Key:i.Key,Label:`${t.Nodes.find(r=>r.Key===i.SourceKey)?.Label} \u2192 ${t.Nodes.find(r=>r.Key===i.TargetKey)?.Label}`,Value:i.Value,SourceKey:i.SourceKey,TargetKey:i.TargetKey,PointType:"Link"}))]}let e=a;return[...e.Regions.map(t=>({...t,PointType:"Region"})),...e.Locations.map(t=>({...t,PointType:"Location"}))]}function bt(n,a,e,t){let i=e.series||[],r=[],o=(h,_,x={})=>oe(a,h,_,x),p=(h,_)=>h?.itemStyle?.color||h?.itemStyle?.areaColor||_?.itemStyle?.color||_?.lineStyle?.color||t.palette[0],d=(h,_,x,y,C,T,g,m,$)=>r.push({id:T,label:C,color:p(h,_),value:ee(g,a),compactValue:ee(g,a,!0),detail:m,percent:$,targets:[{seriesIndex:x,dataIndex:y}]});if(a.Series)a.Series.forEach((h,_)=>{let x=i[_],y=h.Values.flatMap((g,m)=>g===null?[]:[{v:g,i:m}]),C=y.at(-1),T=n==="radar";r.push({id:h.Key,label:h.Label||h.Name,color:x?.lineStyle?.color||p(null,x),line:x?.type==="line"||T,symbol:x?.symbol,dash:x?.lineStyle?.type,value:T?`${y.length} / ${a.Categories.length}`:ee(C?.v??null,a),compactValue:T?void 0:ee(C?.v??null,a,!0),detail:T?o("MeasuresReported","Measures reported"):C?o("Latest","Latest \xB7 {label}",{label:a.Categories[C.i].Label}):o("LatestValue","Latest value"),targets:[{seriesIndex:_}]})});else if(["pie","doughnut","nightingale","funnel"].includes(n))i.forEach((h,_)=>{let x=h.data.reduce((C,T)=>C+(T.value??0),0),y=a.Nested?a.Rings?.[_]?.Label:void 0;h.data.forEach((C,T)=>d(C,h,_,T,C.name,C.point.Key,C.value,y,n!=="funnel"&&C.value!==null&&x>0?C.value/x:void 0))});else if(n==="scatter")i.forEach((h,_)=>r.push({id:h.name,label:h.name,color:p(null,h),symbol:h.symbol,value:String(h.data.length),detail:o("Observations","Observations"),targets:[{seriesIndex:_}]}));else if(n==="treemap"){let h=Te(a.Nodes),_=a.Nodes.filter(g=>g.ParentKey===null),x=_.reduce((g,m)=>g+(h.get(m.Key)??0),0),y=new Map,C=1,T=g=>g.forEach(m=>{y.set(m.id,C++),T(m.children||[])});T(i[0].data),_.forEach((g,m)=>{let $=h.get(g.Key);d(i[0].data[m],i[0],0,y.get(g.Key),g.Label,g.Key,$,o("TopLevelGroup","Top-level group"),x>0&&$!==null?$/x:void 0)})}else n==="sankey"&&a.Nodes.forEach((h,_)=>{let x=a.Links.filter(C=>C.TargetKey===h.Key).reduce((C,T)=>C+T.Value,0),y=a.Links.filter(C=>C.SourceKey===h.Key).reduce((C,T)=>C+T.Value,0);d(i[0].data[_],i[0],0,_,h.Label,h.Key,Math.max(x,y),o("NodeThroughput","Node throughput"))});let l=Array.isArray(e.visualMap)?e.visualMap[0]:e.visualMap,w=l?{label:n==="geo-map"?o("RegionValue","Region value"):n==="calendar-heatmap"?o("DailyValue","Daily value"):o("CellValue","Cell value"),min:l.min,max:l.max,colors:[...l.inRange.color]}:void 0;return n==="geo-map"?i.forEach((h,_)=>h.data.forEach((x,y)=>{(h.type==="scatter"||a.Regions.find(C=>C.Key===x.point.Key)?.Color)&&d(x,h,_,y,x.point.Label,x.point.Key,x.point.Value,h.type==="scatter"?o("LocationValue","Location \xB7 size = value"):o("CustomRegionColor","Custom region color"))})):n==="calendar-heatmap"&&i[0]?.data.forEach((h,_)=>{a.Items.find(x=>x.Key===h.point.Key)?.Color&&d(h,i[0],0,_,h.point.Label,h.point.Key,h.point.Value,o("CustomDayColor","Custom day color"))}),{entries:r,scale:w,note:n==="scatter"&&a.Bubble?o("BubbleSize","Bubble size represents Size."):void 0}}function Fe(n,a){return{value:a.LegendShowValues===!1?"":n.compactValue||n.value||"",detail:a.LegendShowValues===!1?"":n.detail||"",percent:a.LegendShowPercentages&&n.percent!==void 0?new Intl.NumberFormat(a.Locale||"en-US",{style:"percent",maximumFractionDigits:1}).format(n.percent):""}}function yt(n){let a=f(n.color),e=n.symbol||"rect",t=e.startsWith("empty"),i=e.replace(/^empty/,"").toLowerCase(),r=t?"none":a,o=n.dash==="dashed"?"5 3":n.dash==="dotted"?"2 3":"",p=i.includes("diamond")?'<path d="M14 2 20 8 14 14 8 8Z"':i.includes("triangle")||i==="arrow"?'<path d="M14 2 20 13 8 13Z"':i.includes("circle")||i==="pin"?'<circle cx="14" cy="8" r="4"':'<rect x="9" y="3" width="10" height="10" rx="2"';return`<svg viewBox="${n.line?"0 0 28 16":"6 0 16 16"}" width="${n.line?28:16}" height="16" aria-hidden="true">${n.line?`<path d="M1 8H27" fill="none" stroke="${a}" stroke-width="2" stroke-dasharray="${o}"/>`:""}${p} fill="${r}" stroke="${a}" stroke-width="1.5"/></svg>`}function ft(n,a,e){let t=n.querySelector(".blu-chart__stage"),i=document.createElement("div");i.className="blu-chart__body",t.before(i),i.append(t);let r=document.createElement("div");r.className="blu-chart__legend",r.setAttribute("role","group"),r.setAttribute("aria-label","Chart legend"),i.append(r);let o=null,p={entries:[]},d={},l="",w=[],h=n.querySelector(".blu-chart__status");function _(g){let m=Fe(g,d);return`<span class="blu-chart__legend-heading"><span class="blu-chart__legend-marker">${yt(g)}</span><span class="blu-chart__legend-text blu-chart__legend-label">${f(g.label)}</span><span class="blu-chart__legend-text blu-chart__legend-check" aria-hidden="true">\u2713</span></span>${m.value||m.percent?`<span class="blu-chart__legend-numbers">${m.value?`<span class="blu-chart__legend-text blu-chart__legend-value">${f(m.value)}</span>`:""}${m.percent?`<span class="blu-chart__legend-text blu-chart__legend-percent">${f(m.percent)}</span>`:""}</span>`:""}${m.detail?`<span class="blu-chart__legend-text blu-chart__legend-detail">${f(m.detail)}</span>`:""}${d.LegendStyle==="ValueList"?`<span class="blu-chart__legend-track" aria-hidden="true"><span style="width:${g.percent===void 0?100:Math.max(0,Math.min(100,g.percent*100))}%;background:${f(g.color)}"></span></span>`:""}`}function x(g,m){let $=Fe(m,d);g.dataset.legendKey=m.id,g.setAttribute("aria-label",`${oe(d,"Highlight","Highlight {label}",{label:m.label})}${$.detail?" \xB7 "+$.detail:""}${$.value?": "+m.value:""}${$.percent?" \xB7 "+$.percent:""}`),g.innerHTML=_(m)}function y(){a.dispatchAction({type:"downplay"}),p.entries.find(m=>m.id===o)?.targets.forEach(m=>a.dispatchAction({type:"highlight",...m})),w.forEach(m=>{m.instance.update({IsSelected:m.entry.id===o}),x(m.host.querySelector("button"),m.entry)}),r.querySelectorAll("[data-legend-key]").forEach(m=>m.setAttribute("aria-pressed",String(m.dataset.legendKey===o)))}function C(g){o=o===g?null:g,y(),h.textContent=o?oe(d,"Highlighting","Highlighting {label}. Activate again to clear.",{label:p.entries.find(m=>m.id===o).label}):oe(d,"HighlightCleared","Legend highlight cleared.")}function T(){w.splice(0).forEach(g=>g.instance.destroy())}return{prepare(g,m){d=g,r.setAttribute("aria-label",oe(g,"Legend","Chart legend"));let $=g.LegendPosition||"Top",W=n.clientWidth<520&&["Left","Right"].includes($)?"Bottom":$;i.dataset.legendPosition=W,r.hidden=g.ShowLegend===!1||m,i.classList.toggle("blu-chart__body--no-legend",r.hidden),r.dataset.style=g.LegendStyle||"Standard",r.hidden&&(o=null)},render(g,m,$){p=bt(e,g,m,$),p.entries.some(D=>D.id===o)||(o=null),!p.entries.length&&!p.scale&&(r.hidden=!0,i.classList.add("blu-chart__body--no-legend"));let W=Math.max(1,Math.min(4,Math.floor((r.clientWidth-30)/150))),R=Math.ceil(p.entries.length/Math.ceil(p.entries.length/W))||1;r.style.setProperty("--legend-columns",String(R));let F=JSON.stringify([p,g.LegendStyle,g.LegendShowValues,g.LegendShowPercentages,g.Messages,$.surface,$.text]);if(F!==l){let D=r.contains(document.activeElement)?document.activeElement.dataset.legendKey:void 0;l=F,T(),r.innerHTML=`${p.scale?`<div class="blu-chart__legend-scale"><span class="blu-chart__legend-text blu-chart__legend-scale-title">${f(p.scale.label)}</span><div class="blu-chart__legend-gradient" style="background:linear-gradient(90deg,${p.scale.colors.map(f).join(",")})" aria-hidden="true"></div><div class="blu-chart__legend-range"><span class="blu-chart__legend-text">${f(ee(p.scale.min,g))}</span><span class="blu-chart__legend-text">${f(ee(p.scale.max,g))}</span></div></div>`:""}<div class="blu-chart__legend-items"></div>${p.note?`<span class="blu-chart__legend-text blu-chart__legend-note">${f(p.note)}</span>`:""}`;let k=r.querySelector(".blu-chart__legend-items");p.entries.forEach(V=>{if(g.LegendStyle==="Compact"){let P=document.createElement("div");P.className="blu-chart__legend-chip-host",k.append(P);let Z=Vt(P,{Label:V.label,Color:"Secondary",IsSelectable:!0,IsSelected:V.id===o,ExtendedClass:"blu-chart__legend-chip"},{SelectionChanged:()=>C(V.id)});w.push({entry:V,host:P,instance:Z})}else{let P=document.createElement("button");P.type="button",P.className="blu-chart__legend-entry",x(P,V),P.onclick=()=>C(V.id),k.append(P)}}),y(),D&&[...r.querySelectorAll("[data-legend-key]")].find(V=>V.dataset.legendKey===D)?.focus({preventScroll:!0})}else y()},exportLayout(){return{body:i,stage:t,legend:r,model:p}},reset(){o=null},destroy(){T(),r.replaceChildren()}}}function xt(n){let{body:a,legend:e,model:t}=n;if(e.hidden)return"";let i=a.getBoundingClientRect(),r=[],o=d=>{let l=d.getBoundingClientRect();return{x:l.x-i.x,y:l.y-i.y,w:l.width,h:l.height}};for(let d of e.querySelectorAll(".blu-chart__legend-entry,.blu-chart__legend-chip,.blu-chart__legend-scale")){let l=o(d),w=getComputedStyle(d);r.push(`<rect x="${l.x}" y="${l.y}" width="${l.w}" height="${l.h}" rx="${Math.min(parseFloat(w.borderRadius)||0,l.w/2,l.h/2)}" fill="${f(w.backgroundColor)}" stroke="${parseFloat(w.borderWidth)>0?f(w.borderColor):"none"}" stroke-width="${parseFloat(w.borderWidth)||0}"/>`)}for(let d of e.querySelectorAll(".blu-chart__legend-marker svg")){let l=o(d);r.push(`<svg x="${l.x}" y="${l.y}" width="${l.w}" height="${l.h}" viewBox="${f(d.getAttribute("viewBox")||"0 0 28 16")}">${d.innerHTML}</svg>`)}let p=e.querySelector(".blu-chart__legend-gradient");if(p&&t.scale){let d=o(p);r.push(`<defs><linearGradient id="blu-export-legend-scale">${t.scale.colors.map((l,w)=>`<stop offset="${w/(t.scale.colors.length-1)*100}%" stop-color="${f(l)}"/>`).join("")}</linearGradient></defs><rect x="${d.x}" y="${d.y}" width="${d.w}" height="${d.h}" rx="4" fill="url(#blu-export-legend-scale)"/>`)}for(let d of e.querySelectorAll(".blu-chart__legend-track,.blu-chart__legend-track>span")){let l=o(d);l.w&&l.h&&r.push(`<rect x="${l.x}" y="${l.y}" width="${l.w}" height="${l.h}" rx="2" fill="${f(getComputedStyle(d).backgroundColor)}"/>`)}for(let d of e.querySelectorAll(".blu-chart__legend-text")){let l=d.firstChild;if(!l||l.nodeType!==Node.TEXT_NODE)continue;let w=getComputedStyle(d);if(!d.getClientRects().length||w.visibility==="hidden")continue;let h=parseFloat(w.fontSize),_=document.createRange(),x=[];for(let y=0;y<l.textContent.length;y++){_.setStart(l,y),_.setEnd(l,y+1);let C=_.getBoundingClientRect(),T=x.at(-1);T&&Math.abs(T.y-C.y)<1?T.text+=l.textContent[y]:x.push({x:C.x,y:C.y,text:l.textContent[y]})}for(let y of x)r.push(`<text x="${y.x-i.x}" y="${y.y-i.y+h*.86}" font-size="${h}" font-weight="${w.fontWeight}" fill="${f(w.color)}"${w.textDecorationLine.includes("underline")?' text-decoration="underline"':""}>${f(y.text)}</text>`)}return r.join("")}async function fe(n,a,e,t){a?.aborted&&(n.catch(()=>{}),a.throwIfAborted());let i,r=()=>{};try{return await Promise.race([n,new Promise((o,p)=>{r=()=>p(a?.reason??new DOMException("Operation aborted.","AbortError")),a?.addEventListener("abort",r,{once:!0}),i=setTimeout(()=>p(new Error(t)),e)})])}finally{clearTimeout(i),a?.removeEventListener("abort",r)}}function kt(n,a){let e=URL.createObjectURL(n),t=document.createElement("a");t.href=e,t.download=a,document.body.append(t),t.click(),t.remove(),setTimeout(()=>URL.revokeObjectURL(e),1e3)}function _t(n,a){let e=[];for(let t of n.split(/\s+/))!e.length||e[e.length-1].length+t.length>a?e.push(t):e[e.length-1]+=` ${t}`;return e.slice(0,4)}async function Ct(n,a,e,t,i,r,o,p,d){d?.throwIfAborted();let l=p?.body.clientWidth||n.getWidth(),w=p?.body.getBoundingClientRect().height||n.getHeight(),h=p?.body.getBoundingClientRect(),_=p?.stage.getBoundingClientRect(),x=h&&_?_.x-h.x:0,y=h&&_?_.y-h.y:0;if(l<=0||n.getHeight()<=0)throw new Error("Show the chart before downloading it.");let C=_t(a.Title||"Chart",Math.max(16,Math.floor((l-32)/10))),T=_t(a.Description||"",Math.max(24,Math.floor((l-32)/6))),g=C.length*22+T.length*15+24,m=w+g+32,$=C.map((D,k)=>`<text x="16" y="${26+k*22}" font-size="17" font-weight="600" fill="${r}">${f(D)}</text>`).join(""),W=T.map((D,k)=>`<text x="16" y="${28+C.length*22+k*15}" font-size="11" fill="${o}">${f(D)}</text>`).join(""),R=`<svg xmlns="http://www.w3.org/2000/svg" width="${l}" height="${m}" viewBox="0 0 ${l} ${m}" role="img" aria-labelledby="chart-title chart-description"><title id="chart-title">${f(a.Title||"Chart")}</title><desc id="chart-description">${f(a.Description||"Chart visualization. Exact values are available in the source chart data table.")}</desc><rect width="100%" height="100%" fill="${i}"/><g font-family="Inter,system-ui,sans-serif">${$}${W}<g transform="translate(0 ${g})"><g transform="translate(${x} ${y})">${n.renderToSVGString()}</g>${p?xt(p):""}</g><text x="16" y="${m-12}" fill="${o}" font-size="9">${f(a.ExportFootnote||"BluKavantUI")}</text></g></svg>`,F=new Blob([R],{type:"image/svg+xml"});if(e==="png"){if(l*2>16384||m*2>16384||l*m*4>32e6)throw new Error("This chart is too large for PNG. Use SVG or reduce the displayed data.");let D=URL.createObjectURL(F);try{let k=new Image;k.src=D,await fe(k.decode(),d,15e3,"PNG decoding timed out. Try SVG."),d?.throwIfAborted();let V=document.createElement("canvas");V.width=Math.ceil(l*2),V.height=Math.ceil(m*2);let P=V.getContext("2d");if(!P)throw new Error("PNG export is unavailable. Try SVG.");P.drawImage(k,0,0,V.width,V.height),F=await fe(new Promise((Z,_e)=>V.toBlob(Y=>Y?Z(Y):_e(new Error("PNG export failed. Try SVG.")),"image/png")),d,15e3,"PNG encoding timed out. Try SVG.")}finally{URL.revokeObjectURL(D)}}d?.throwIfAborted(),kt(F,t)}function Oe(n,a){n==="mixed"?ut(a):n==="heatmap"?pt(a):mt(n,a)}function $e(n,a){if(n==="mixed"){let e=a;return e.Series.flatMap((t,i)=>e.Categories.map((r,o)=>({...ct(e,o,i),Label:r.Label,CategoryKey:r.Key})))}return n==="heatmap"?a.Cells.map((e,t)=>{let i=dt(a,t);return{...i,Label:`${i.YLabel}, ${i.XLabel}`}}):Ge(n,a)}function Re(n,a){return JSON.stringify([n,a.Key,a.SeriesKey||"",a.CategoryKey||"",a.RingKey||"",a.PointType||""])}function St(n,a,e){let t={...a,...structuredClone(e)};Oe(n,{...t,SelectedKey:null});let r=t.SelectedKey!=null&&!$e(n,t).some(o=>o.Key===t.SelectedKey)&&(!Object.hasOwn(e,"SelectedKey")||e.SelectedKey===a.SelectedKey);return r&&(t.SelectedKey=null),Oe(n,t),{next:t,cleared:r}}function wt(n,a){let e=[];return(n?.series||[]).forEach((t,i)=>{if(t.type==="treemap"){let r=1,o=p=>p.forEach(d=>{let l=r++;d.id===a&&e.push({seriesIndex:i,dataIndex:l}),o(d.children||[])});o(t.data||[])}else(t.data||[]).forEach((r,o)=>{r?.point?.Key===a&&e.push({seriesIndex:i,dataIndex:o,...t.type==="sankey"?{dataType:"node"}:{}})});(t.links||[]).forEach((r,o)=>{r?.point?.Key===a&&e.push({seriesIndex:i,dataIndex:o,dataType:"edge"})})}),e}function vt(n,a,e){return n.Messages?.[a]??e}import{registerMap as Pt}from"echarts/core";var Ue={World:new URL("./maps/world.geojson",import.meta.url).href,US:new URL("./maps/us-states.geojson",import.meta.url).href};async function Lt(n,a){let e=new AbortController,t=()=>e.abort(a?.reason);a?.addEventListener("abort",t,{once:!0}),a?.aborted&&t();try{return await fe((async()=>{let i=new URL(n,typeof location>"u"?"http://localhost/":location.href);if(!["http:","https:"].includes(i.protocol)||i.username||i.password)throw new Error("Map URL must be an HTTP resource without embedded credentials.");let r=await fetch(i.href,{signal:e.signal,credentials:"same-origin"});if(!r.ok)throw new Error(`Map resource failed (${r.status}).`);if(Number(r.headers.get("Content-Length"))>H.mapBytes)throw new Error("Map resource exceeds the size limit.");let o="";if(r.body){let d=r.body.getReader(),l=new TextDecoder,w=0;try{for(;;){let h=await d.read();if(h.done)break;if(w+=h.value.length,w>H.mapBytes)throw new Error("Map resource exceeds the size limit.");o+=l.decode(h.value,{stream:!0})}o+=l.decode()}finally{await d.cancel().catch(()=>{})}}else if(o=await r.text(),new TextEncoder().encode(o).length>H.mapBytes)throw new Error("Map resource exceeds the size limit.");e.signal.throwIfAborted();let p=JSON.parse(o);return Ee(p),p})(),e.signal,1e4,"Map resource timed out. Retry the update.")}finally{e.abort(),a?.removeEventListener("abort",t)}}function It(n=Pt,a=16){let e=[];return{acquire(t){let i=JSON.stringify(t);if(new TextEncoder().encode(i).length>H.mapBytes)throw new Error("Map resource exceeds the size limit.");let r=e.find(d=>d.refs>0&&d.signature===i);if(!r){if(r=e.find(d=>!d.refs),!r){if(e.length>=a)throw new Error("Too many different maps are active.");r={name:`blu-charts-map-v1-${e.length}`,signature:"",refs:0},e.push(r)}n(r.name,t),r.signature=i}r.refs++;let o=!1,p=r;return{name:r.name,release(){o||(o=!0,--p.refs||(p.signature="",n(p.name,{type:"FeatureCollection",features:[]})))}}},stats(){return{slots:e.length,active:e.filter(t=>t.refs>0).length}}}}var Be=It();async function Kt(n,a){let e=n.Map==="Custom"?n.GeoJSON??await Lt(n.MapURL,a):await Lt(n.Map==="US"?Ue.US:Ue.World,a);return a.throwIfAborted(),Ee(e),ge(n,e),e}function mn(n,a,e,t,i){return Bt(n,a,e,t,i)}function Bt(n,a,e,t,i,r){let o={...lt,...structuredClone(e)},p=o,d=(s,...u)=>{if(!l)try{s?.(...u)}catch(b){console.error("Chart event handler failed.",b)}},l=!1,w=!1,h=0,_=0,x=0,y=!1,C=!1,T="",g="",m=()=>{},$,W;try{Oe(a,o)}catch(s){throw d(t.Error,{Message:String(s.message),Code:"InvalidData"}),s}let R,F,D,k,V,P="",Z,_e=new AbortController,Y,Ae="treemapRootToNode",G=document.createElement("section");G.className="blu-chart",G.innerHTML='<div class="blu-chart__heading"><div><h3></h3><p></p></div><div class="blu-chart__export"><select aria-label="Chart download format"><option value="png">PNG image</option><option value="svg">SVG vector</option></select><button type="button" aria-label="Download chart">\u2193 <span>Download</span></button></div></div><div class="blu-chart__stage"><div class="blu-chart__plot" role="img"></div><div class="blu-chart__state" aria-hidden="true" hidden></div></div><p class="blu-chart__missing-note" hidden></p><div class="blu-chart__navigation" role="group" aria-label="Chart navigation" hidden></div><details class="blu-chart__data"><summary>View data & keyboard selections</summary><label class="blu-chart__patterns"><input type="checkbox"><span>Use fill patterns</span></label><div class="blu-chart__table" tabindex="0" role="region"></div></details><div class="blu-chart__state-announcement" role="status" aria-live="polite" aria-atomic="true"></div><div class="blu-chart__status" role="status" aria-live="polite"></div>',n.append(G);let A=s=>G.querySelector(s),U=A(".blu-chart__plot"),te=A(".blu-chart__table"),ie=A(".blu-chart__status"),Q=A(".blu-chart__navigation"),je=gt(A(".blu-chart__state")),qe=ht(A(".blu-chart__state-announcement")),le=A(".blu-chart__export button"),Ce=A(".blu-chart__patterns input"),se=matchMedia("(prefers-reduced-motion: reduce)"),Ve=matchMedia("(forced-colors: active)"),Ye=matchMedia("(prefers-color-scheme: dark)"),ae=()=>$e(a,o),Se=()=>ae().some(s=>s.Value!==null),N=(s,u)=>vt(o,s,u);function we(){if(l)throw new Error("This chart has been destroyed.")}function me(s,u="InvalidData",b=""){l||(ie.textContent=s instanceof Error?s.message:String(s),d(t.Error,{Message:ie.textContent,Code:u,RequestId:b}),Xe("Error"))}function Xe(s){s!==T&&(T=s,d(t.StateChange,{State:s,Revision:h}))}function Tt(s){if(R?.dispatchAction({type:"downplay"}),!(!s||y||o.IsLoading)){if(a==="mixed"){let u=o,b=u.Categories.findIndex(S=>S.Key===s);b>=0&&u.Series.forEach((S,E)=>R?.dispatchAction({type:"highlight",seriesIndex:E,dataIndex:b}));return}if(a==="heatmap"){let u=o.Cells.findIndex(b=>b.Key===s);u>=0&&R?.dispatchAction({type:"highlight",seriesIndex:0,dataIndex:u});return}for(let u of wt(D,s))R?.dispatchAction({type:"highlight",...u})}}function Ot(){if(!(R||U.clientWidth<=0||U.clientHeight<=0)){Ne.use([Ht,Dt,zt,Gt,Ft,Ut]),R=Ne.init(U,void 0,{renderer:"svg"}),F=ft(G,R,a),R.on("click","series",s=>{let u=s.data?.point;if(a==="mixed"){let b=o;u=ae().find(S=>S.Key===b.Categories[s.dataIndex]?.Key&&S.SeriesKey===b.Series[s.seriesIndex]?.Key)}a==="heatmap"&&(u=ae()[s.dataIndex]),u&&Ze(u,"Chart")});for(let[s,u]of[["treemaproottonode","treemapRootToNode"],["treemapzoomtonode","treemapZoomToNode"]])R.on(s,b=>{Y=b.targetNodeId||b.targetNode?.getId?.(),Ae=u})}}function be(s){return s.Value===null?N("NoData","No data"):st(s.Value,o.__valueText?.[Re(a,s)])}function We(s){cancelAnimationFrame(x),x=requestAnimationFrame(()=>{if(l||!G.isConnected)return;let u=document.activeElement;if(u!==document.body&&u!==te&&u?.dataset.point!==s)return;([...te.querySelectorAll("[data-point]")].find(S=>S.dataset.point===s)||te).focus({preventScroll:!0})})}function $t(){let s=ae(),u=document.activeElement,b=u&&te.contains(u)?u.dataset.point:void 0,S=(O,v)=>o.EnableSelection&&O.Value!==null?`<button type="button" data-point="${f(Re(a,O))}" aria-label="${f(`${O.Label}${O.SeriesName?", "+O.SeriesName:""}: ${be(O)}`)}" aria-pressed="${o.SelectedKey===O.Key}">${f(v)}</button>`:f(v),E="",K="";if(a==="mixed"){let O=o,v=new Map(s.map(L=>[JSON.stringify([L.Key,L.SeriesKey]),L]));E=`<tr><th scope="col">${f(N("Category","Category"))}</th>${O.Series.map(L=>`<th scope="col">${f(L.Name)}</th>`).join("")}</tr>`,K=O.Categories.map(L=>`<tr><th scope="row">${f(L.Label)}</th>${O.Series.map(M=>{let I=v.get(JSON.stringify([L.Key,M.Key]));return`<td>${S(I,be(I))}</td>`}).join("")}</tr>`).join("")}else if(a==="heatmap"){let O=o,v=new Map(s.map(L=>[JSON.stringify([L.XKey,L.YKey]),L]));E=`<tr><th scope="col">${f(N("Category","Category"))}</th>${O.XCategories.map(L=>`<th scope="col">${f(L.Label)}</th>`).join("")}</tr>`,K=O.YCategories.map(L=>`<tr><th scope="row">${f(L.Label)}</th>${O.XCategories.map(M=>{let I=v.get(JSON.stringify([M.Key,L.Key]));return`<td>${I?S(I,be(I)):f(N("NoData","No data"))}</td>`}).join("")}</tr>`).join("")}else{let O=["Key","Label","Date","Value","CategoryKey","SeriesKey","RingKey","ParentKey","X","Y","Size","Group","SourceKey","TargetKey","Longitude","Latitude","PointType"].filter(v=>s.some(L=>L[v]!==void 0));E=`<tr>${O.map(v=>`<th scope="col">${f(N(v,v))}</th>`).join("")}</tr>`,K=s.map(v=>`<tr>${O.map(L=>{let M=v[L],I=L==="Value"?be(v):M===null?"null":String(M??"");return`<td>${L==="Label"?S(v,I):f(I)}</td>`}).join("")}</tr>`).join("")}te.setAttribute("aria-label",`${o.Title} ${N("Values","values")}`),te.innerHTML=`<table><caption>${f(o.Title||"Chart")} \u2014 ${f(N("ExactValues","original values"))}</caption><thead>${E}</thead><tbody>${K}</tbody></table>`,b&&We(b)}function ne(s=!1){if($&&(r?.enabled?.()===!1||!o.EnableAnimation||r?.mode(n)!==W)&&($.cancel(),$=void 0),l)return;let u=y||!!o.IsLoading,b=!Se(),S=!!g&&!u;if(G.className=`blu-chart ${o.ExtendedClass||""}`,G.setAttribute("aria-label",o.AccessibleLabel||o.Title||"Chart"),A("h3").textContent=o.Title||"Chart",A(".blu-chart__heading p").textContent=o.Description||"",A(".blu-chart__heading").hidden=!o.ShowHeader&&!o.ShowToolbar,A("h3").parentElement.hidden=!o.ShowHeader,A(".blu-chart__export").hidden=!o.ShowToolbar,le.querySelector("span").textContent=N("Download","Download"),le.setAttribute("aria-label",N("DownloadChart","Download chart")),A("select").setAttribute("aria-label",N("DownloadFormat","Chart download format")),A('option[value="png"]').textContent=N("PNG","PNG image"),A('option[value="svg"]').textContent=N("SVG","SVG vector"),Q.setAttribute("aria-label",N("Navigation","Chart navigation")),A(".blu-chart__patterns").hidden=!["mixed","line","radar","bar","polar","pie","doughnut","nightingale","treemap","sankey","funnel"].includes(a),A(".blu-chart__patterns span").textContent=N("Patterns",a==="line"||a==="radar"?"Use fill patterns (with Area fill)":"Use fill patterns"),Ce.checked=!!o.ShowPatterns,A(".blu-chart__data").hidden=u||b,A(".blu-chart__data").classList.toggle("blu-chart__data--compact",!o.ShowDataTable),A(".blu-chart__data summary").textContent=o.ShowDataTable?N("ViewData","View data & keyboard selections"):N("ExploreData","Explore chart data"),U.style.height=`${o.Height}px`,U.style.visibility=u||b?"hidden":"visible",U.setAttribute("aria-busy",String(u)),a==="calendar-heatmap"){let v=o,L=Math.ceil(((Date.parse(v.RangeEnd)-Date.parse(v.RangeStart))/864e5+7)/7);U.style.minWidth=`${Math.max(300,L*12+56)}px`;let M=A(".blu-chart__stage");M.style.overflowX="auto",M.tabIndex=0,M.setAttribute("role","region"),M.setAttribute("aria-label",N("CalendarScroll","Calendar plot; scroll horizontally for more dates"))}let E=u?N("Loading",y?"Loading map\u2026":"Loading chart\u2026"):o.EmptyMessage||"No data to display";je.update(u,b,E,!!o.EnableAnimation&&!se.matches&&(!r||r.enabled?.()===!1||r.mode(n)==="full")),qe.update(S?g:!u&&!b?N("Ready","Chart ready."):E),le.disabled=w||u||b||S,Q.hidden=u||b||S||!(a==="geo-map"&&o.Roam!==!1||a==="treemap"&&o.Drilldown),a==="geo-map"&&!Q.children.length&&(Q.innerHTML=["in","out","left","right","up","down","reset","full"].map(v=>`<button type="button" data-nav="${v}"></button>`).join("")),a==="treemap"&&!Q.children.length&&(Q.innerHTML='<button type="button" data-nav="reset"></button>');let K={in:"Zoom in",out:"Zoom out",left:"Pan left",right:"Pan right",up:"Pan up",down:"Pan down",reset:a==="treemap"?"Show entire tree":"Reset map",full:"Show full map"};if(Q.querySelectorAll("[data-nav]").forEach(v=>{v.textContent=N("Map_"+v.dataset.nav,K[v.dataset.nav])}),Ot(),s&&F?.reset(),F?.prepare(o,u||b),R&&!y&&(a!=="geo-map"||k)){let v=!s&&R.getOption()?.geo?.[0],L=He(G),M=i({...o,ShowLegend:!1},L,k?.name,se.matches,U.clientWidth);if(delete M.legend,M.aria={...M.aria,description:`${o.Title}. ${o.Description||""} ${N("DataAlternative","Original values and keyboard selection are in the data table.")}`},M.geo&&v&&(M.geo.zoom=v.zoom,v.center&&(M.geo.center=v.center)),r&&r.enabled?.()!==!1){let I=r.timing?.();M.animation=!!o.EnableAnimation&&!se.matches&&r.mode(n)==="full"&&I?.duration!==0&&!u&&!b,M.animationDuration=I?.duration??750,M.animationDurationUpdate=I?.duration??650,M.animationEasing=M.animationEasingUpdate=I?.easing??"cubicInOut",M.series?.forEach((de,Nt)=>{de.id??=JSON.stringify([a,de.type,de.name||(a==="geo-map"?de.type:Nt)]);let rt=(re,At)=>{if(!re||typeof re!="object"||re.id!=null)return;let Pe=re.point?.Key??(a==="mixed"?o.Categories[At]?.Key:re.name);Pe!=null&&(re.id=a==="sankey"?String(Pe):JSON.stringify([Pe,re.point?.SeriesKey||""]))};de.data?.forEach(rt),de.links?.forEach(rt)}),a==="geo-map"&&!M.visualMap&&(M.visualMap=[]),!M.animation&&D?.animation&&R.clear()}R.resize(),R.setOption(M,r&&r.enabled?.()!==!1?{notMerge:!!s,replaceMerge:a==="geo-map"?["series","visualMap"]:["series"]}:{notMerge:!0}),D=M,s&&(Y=void 0),a==="treemap"&&Y&&ae().some(I=>I.Key===Y)&&R.dispatchAction({type:Ae,seriesIndex:0,targetNodeId:Y}),F?.render(o,M,L)}let O=A(".blu-chart__missing-note");if(a==="radar"){let v=o.Series.filter(L=>L.Values.some(M=>M===null));O.hidden=!v.length||u||b,O.textContent=`${v.map(L=>L.Label).join(", ")}: ${N("IncompleteRadar","incomplete profile. Available measurements remain in the data table; missing values are not drawn as zero.")}`}$t(),Ve.matches&&!u&&!b&&(A(".blu-chart__data").open=!0),R&&!y&&!S&&!C&&(a!=="geo-map"||k)&&(C=!0,d(t.Ready)),l||Xe(u?"Loading":S?"Error":b?"Empty":"Ready")}function ve(s,u,b=k,S=V,E=P){let K={options:o,map:k,geometry:V,geometryKey:P,resourceError:g};o=s,k=b,V=S,P=E;try{g="",ie.textContent="",ne(K.options.ResetKey!==s.ResetKey||K.geometryKey!==E)}catch(O){o=K.options,k=K.map,V=K.geometry,P=K.geometryKey,g=K.resourceError,p=o;try{ne()}catch{}throw b!==K.map&&b?.release(),O}if(r&&r.enabled?.()!==!1&&["heatmap","calendar-heatmap","sankey"].includes(a)&&K.options!==s&&JSON.stringify($e(a,K.options))!==JSON.stringify(ae())){$?.cancel(),$=void 0;let O=r.mode(n),v=r.timing?.();if(o.EnableAnimation&&O!=="off"&&!o.IsLoading&&Se()&&v?.duration!==0){let L=O==="reduced"||se.matches?Math.min(v?.duration??200,200):v?.duration??650;W=O,$=U.animate([{opacity:.35},{opacity:1}],{duration:L,easing:v?.curve||"ease-in-out"})}}K.map!==b&&K.map?.release(),u&&d(t.SelectionChange,{Key:null,Reason:"DataChanged"})}function ke(s,u=!1){let b=++h;if(Z?.abort(),y=!1,p=s,a!=="geo-map"){ve(s,u);return}let S=s,E=JSON.stringify([S.Map||"World",S.MapURL||"",S.GeoJSON||null]);if(V&&E===P){ge(S,V),ve(s,u);return}if(S.Map==="Custom"&&S.GeoJSON){ge(S,S.GeoJSON);let K=Be.acquire(S.GeoJSON);ve(s,u,K,S.GeoJSON,E);return}y=!0,Z=new AbortController,ne(),Kt(S,Z.signal).then(K=>{if(l||b!==h)return;y=!1;let O=Be.acquire(K);ve(s,u,O,K,E)}).catch(K=>{l||b!==h||(y=!1,p=o,g=K instanceof Error?K.message:String(K),ne(),me(K,"ResourceLoadFailed"))})}function Ze(s,u){if(l||y||o.IsLoading||s.Value===null&&!(a==="radar"&&s.PointType==="Series"))return;let b={...structuredClone(s),ValueText:s.Value===null?"":be(s)},S=!!o.EnableSelection,E=o.SelectedKey===s.Key?null:s.Key;if(S){let K={...o,SelectedKey:E};if(a==="treemap"&&u==="Table"&&K.Drilldown&&(Y=s.Key,Ae="treemapRootToNode"),ke(K),l)return;ie.textContent=E?`${N("Selected","Selected")} ${s.Label}.`:N("SelectionCleared","Selection cleared.")}d(t.PointClick,b,u),S&&!l&&d(t.SelectionChange,{Key:E,Reason:"User"})}te.onclick=s=>{let u=s.target.closest("[data-point]"),b=u?.dataset.point,S=u&&ae().find(E=>Re(a,E)===b);S&&(Ze(S,"Table"),!l&&G.isConnected&&(document.activeElement===document.body||G.contains(document.activeElement))&&We(b))},Ce.onchange=()=>{ce.update({ShowPatterns:Ce.checked}),d(t.PatternsChange,{ShowPatterns:Ce.checked})},Q.onclick=s=>{let u=s.target.closest("[data-nav]")?.dataset.nav;if(!(!u||!R)){if(u==="full"){ce.update({MapView:"Full",ResetKey:crypto.randomUUID()});return}if(u==="reset"){Y=void 0,ne(!0);return}R.dispatchAction({type:"geoRoam",componentType:"geo",geoIndex:0,dx:u==="left"?-60:u==="right"?60:0,dy:u==="up"?-60:u==="down"?60:0,zoom:u==="in"?1.3:u==="out"?1/1.3:1,originX:U.clientWidth/2,originY:U.clientHeight/2}),ie.textContent=N("Map_"+u,Rt(u))}};function Rt(s){return`Map view changed: ${s}.`}let X=()=>{try{ne()}catch(s){me(s,"RenderFailed")}},Qe=s=>{s.key==="Escape"&&R?.dispatchAction({type:"hideTip"})},et=0,tt=0,at=new ResizeObserver(()=>{let s=U.clientWidth,u=U.clientHeight;s===et&&u===tt||(et=s,tt=u,cancelAnimationFrame(_),_=requestAnimationFrame(()=>{!l&&s>0&&u>0&&X()}))}),nt=new MutationObserver(X);nt.observe(document.documentElement,{attributes:!0,attributeFilter:["data-bluui-theme"]}),se.addEventListener("change",X),Ve.addEventListener("change",X),Ye.addEventListener("change",X),document.addEventListener("keydown",Qe);let ce={update(s){we();try{let{next:u,cleared:b}=St(a,p,s);ke(u,b)}catch(u){if(!y){p=o;try{ne()}catch{}}throw me(u,/SelectedKey/.test(u.message)?"InvalidSelection":"InvalidData"),u}},resize(){we(),X()},setSelection(s){ce.update({SelectedKey:s})},highlight(s){we(),Tt(s)},async download(s="png",u=`blukavant-${a}.${s}`,b=crypto.randomUUID()){we();let S=!1;try{if(!["png","svg"].includes(s))throw new Error("Choose PNG or SVG.");if(w)throw new Error("ExportBusy");if(!R||y||g||o.IsLoading||!Se())throw new Error("Wait for a visible chart with valid data before downloading.");w=!0,S=!0,le.disabled=!0;let E=He(G);await Ct(R,o,s,u,E.surface,E.text,E.muted,F?.exportLayout(),_e.signal),l||(ie.textContent=N("ExportStarted","Chart download started."),d(t.ExportStarted,{Format:s,FileName:u,RequestId:b}),d(t.ExportComplete,{Format:s,FileName:u}))}catch(E){throw l||me(E,E instanceof Error&&E.message==="ExportBusy"?"ExportBusy":"ExportFailed",b),E}finally{S&&(w=!1,l||(le.disabled=y||!!g||!!o.IsLoading||!Se()))}},destroy(){l||(l=!0,$?.cancel(),m(),h++,Z?.abort(),_e.abort(),cancelAnimationFrame(_),cancelAnimationFrame(x),at.disconnect(),nt.disconnect(),se.removeEventListener("change",X),Ve.removeEventListener("change",X),Ye.removeEventListener("change",X),document.removeEventListener("keydown",Qe),qe.destroy(),je.destroy(),F?.destroy(),R?.dispose(),k?.release(),G.remove())}};le.onclick=()=>{ce.download(A("select").value).catch(()=>{})},at.observe(G);try{ke(o),m=r?.subscribe(n,X)||(()=>{})}catch(s){throw me(s),ce.destroy(),s}return ce}var Jt=3.2;function Je(n){if(n.startsWith("#")){let e=n.slice(1);return e.length<=4&&(e=e.split("").map(t=>t+t).join("")),[0,2,4].map(t=>parseInt(e.slice(t,t+2),16)).concat(e.length===8?parseInt(e.slice(6),16)/255:1)}let a=n.match(/[\d.]+/g)?.map(Number);return a&&a.length>=3?[...a.slice(0,3),a[3]??1]:[24,34,48,1]}function jt(n){return`rgb(${n.slice(0,3).map(a=>Math.round(a)).join(",")})`}function qt(n,a){let e=Je(n),t=Je(a);return jt(e.slice(0,3).map((i,r)=>i*e[3]+t[r]*(1-e[3])))}function Mt(n){let a=Je(n).slice(0,3).map(e=>{let t=e/255;return t<=.04045?t/12.92:((t+.055)/1.055)**2.4});return a[0]*.2126+a[1]*.7152+a[2]*.0722}function xe(n,a){let e=Mt(n),t=Mt(a);return(Math.max(e,t)+.05)/(Math.min(e,t)+.05)}function Et(n,a,e=Jt){let t=qt(n,a);if(xe(t,a)>=e)return t;let i=xe("#000",a)>=xe("#fff",a)?"#000":"#fff",r=Math.min(e,xe(i,a)),o=0,p=1;for(let d=0;d<20;d++){let l=(o+p)/2;xe(Le([t,i],l),a)>=r?p=l:o=l}return Le([t,i],p)}function fn(n,a){let e=Et(n,a,9);return[Et(Le([a,e],.12),a),e]}var xn=n=>["circle","diamond","triangle","rect","roundRect","pin","arrow","emptyCircle","emptyDiamond","emptyTriangle","emptyRect","emptyRoundRect"][n%12],_n=n=>["solid","dashed","dotted"][(n+Math.floor(n/12))%3];function Yt(n,a){let e=[{symbol:"rect",symbolSize:0,dashArrayX:[1,0],dashArrayY:[1,8],rotation:0},{symbol:"rect",symbolSize:1,dashArrayX:[1,0],dashArrayY:[1,8],rotation:Math.PI/4},{symbol:"circle",symbolSize:1,dashArrayX:[2,7],dashArrayY:[2,7],rotation:0},{symbol:"rect",symbolSize:1,dashArrayX:[1,0],dashArrayY:[1,8],rotation:-Math.PI/4},{symbol:"rect",symbolSize:1,dashArrayX:[1,0],dashArrayY:[1,6],rotation:0},{symbol:"rect",symbolSize:1,dashArrayX:[3,5],dashArrayY:[3,5],rotation:Math.PI/4},{symbol:"triangle",symbolSize:1,dashArrayX:[4,6],dashArrayY:[4,6],rotation:0},{symbol:"diamond",symbolSize:1,dashArrayX:[4,6],dashArrayY:[4,6],rotation:0},{symbol:"rect",symbolSize:1,dashArrayX:[1,0],dashArrayY:[1,3,1,7],rotation:Math.PI/4},{symbol:"circle",symbolSize:1,dashArrayX:[2,3],dashArrayY:[2,3],rotation:0},{symbol:"rect",symbolSize:1,dashArrayX:[1,0],dashArrayY:[3,4],rotation:-Math.PI/4},{symbol:"rect",symbolSize:1,dashArrayX:[4,4],dashArrayY:[1,5],rotation:0}];return{...e[n%e.length],color:Ie(a),backgroundColor:"none"}}function Xt(n){return{color:n,borderColor:Ie(n),borderWidth:2,borderType:"solid"}}function Cn(n,a,e=!1,t){return{color:n,opacity:1,borderColor:a,borderWidth:1.5,borderType:"solid",...e?Xt(n):{},...t===void 0?{}:{decal:Yt(t,n)}}}function Sn(n,a,e=8){return({labelRect:t})=>({hideOverlap:!0,dx:Math.max(0,8-t.x)+Math.min(0,n-8-t.x-t.width),dy:Math.max(0,e-t.y)+Math.min(0,a-8-t.y-t.height)})}export{ee as a,dt as b,Wt as c,f as d,Ge as e,mn as f,Bt as g,Et as h,fn as i,xn as j,_n as k,Yt as l,Xt as m,Cn as n,Sn as o};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as r}from"./chunk-UQMMBG26.js";import{g as o}from"./chunk-MR5VITXX.js";import{a as t}from"./chunk-3PITHTEO.js";import{use as s}from"echarts/core";import{PieChart as C}from"echarts/charts";function y(i,n,e,m={},a={}){return t(i,e,a,(p,u)=>(s([C]),o(u,"doughnut",n,m,r,p)))}export{y as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as p,d as r,e as f,h as S,j as h,l as g,m as C,n as L,o as x}from"./chunk-MR5VITXX.js";import{i as b,k as y}from"./chunk-RC2TCMJF.js";function B(m,o,G,O=!1,d=640){let i="scatter",a=m,$=f(i,m),K=(e,t)=>a.ShowPatterns?g(e,t):void 0,c=o.palette,l=(e,t)=>S(o.forcedColors?o.text:b(e,c[t%c.length],o.dark,o.read),o.surface,i==="line"||i==="radar"||i==="polar"&&a.PolarType==="Line"?4.5:3.2),v=(e,t,n)=>L(l(t,n),o.surface,a.SelectedKey===e),w=(e,t)=>$.find(n=>n.Key===e&&(!t||n.SeriesKey===t)),k={data:["line","radar","bar","polar"].includes(i)?a.Series.map(e=>e.Label):i==="scatter"?[...new Set(a.Points.map(e=>e.Group||"Observations"))]:["pie","doughnut","nightingale","funnel"].includes(i)?[...new Set(a.Items.map(e=>e.Label))]:[],show:a.ShowLegend,type:"scroll",top:6,left:10,right:10,itemWidth:24,itemHeight:12,selectedMode:!1,pageTextStyle:{color:o.muted},pageIconColor:o.text,textStyle:{color:o.muted,fontSize:11}},T={show:a.ShowLabels,color:y(o.surface),fontSize:11,backgroundColor:o.surface,padding:[2,3],borderRadius:2},z={show:a.ShowTooltip,confine:!0,enterable:!0,backgroundColor:o.surface,borderColor:o.border,textStyle:{color:o.text,fontSize:12},formatter:e=>{let t=e.data?.point;if(!t)return`${r(e.name||"")}${e.value==null||Number.isNaN(e.value)?" \xB7 No data":""}`;let n=t.Date?`<br/>${r(t.Date)}<br/><strong>${r(p(t.Value,a))}</strong>`:t.X!==void 0?`<br/>${r(a.XLabel||"X")}: ${t.X}<br/>${r(a.YLabel||"Y")}: ${t.Y}${t.Size===void 0?"":`<br/>Size: ${t.Size}`}`:`<br/><strong>${r(p(t.Value,a))}</strong>`;return`${r(t.SeriesName?`${t.SeriesName} \xB7 ${t.Label}`:t.Label)}${n}${e.data?.conversion?`<br/>${r(e.data.conversion)}`:""}`}},P={backgroundColor:o.surface,color:c.map((e,t)=>l(e,t)),animation:!!a.EnableAnimation&&!O,animationDuration:300,animationDurationUpdate:150,textStyle:{fontFamily:"Inter,system-ui,sans-serif",color:o.text},aria:{enabled:!0,description:`${a.Title}. ${a.Description||""} Exact values and keyboard selection are in the data table.`},tooltip:z},u={axisLine:{show:!1},axisTick:{show:!1},axisLabel:{color:o.muted,fontSize:10,hideOverlap:!0},splitLine:{lineStyle:{color:o.border,type:"dashed"}}},s=m,N=[...new Set(s.Points.map(e=>e.Group||"Observations"))],D=Math.max(1,...s.Points.map(e=>e.Size||0));return{...P,legend:k,grid:{left:20,right:30,top:a.ShowLegend?50:30,bottom:36,containLabel:!0},xAxis:{...u,type:"value",name:s.XLabel||"X",nameLocation:"middle",nameGap:30},yAxis:{...u,type:"value",name:s.YLabel||"Y"},series:N.map((e,t)=>({type:"scatter",name:e,symbol:h(t),itemStyle:{color:l(s.Points.find(n=>(n.Group||"Observations")===e)?.Color,t)},label:{...T,width:Math.min(140,d*.25),overflow:"truncate",position:"top",formatter:"{b}"},labelLayout:x(d,a.Height||320,a.ShowLegend?38:8),symbolSize:(n,X)=>s.Bubble?8+36*Math.sqrt((X.data.point.Size??1)/D):12,emphasis:{focus:"none",scale:!1},blur:{itemStyle:{opacity:1},lineStyle:{opacity:1},label:{opacity:1}},data:s.Points.filter(n=>(n.Group||"Observations")===e).map(n=>({name:n.Label,value:[n.X,n.Y],point:w(n.Key),itemStyle:v(n.Key,n.Color,t),emphasis:{itemStyle:C(l(n.Color,t))}}))}))}}export{B as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as r}from"./chunk-UO2KNHTU.js";import{f as t}from"./chunk-MR5VITXX.js";import{use as p}from"echarts/core";import{PieChart as a}from"echarts/charts";function h(e,o,i={}){return p([a]),t(e,"pie",o,i,r)}export{h as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function p(e){return e?["#a16aff","#00cfff","#ff2b91","#ff8a00","#36e377","#e13dff","#4285ff","#ff4056"]:["#7020ff","#0094ff","#ff006e","#ff6a00","#00b94f","#c000ff","#004fff","#ff1738"]}var u=["Default","Primary","Secondary","Success","Processing","Warning","Error","Danger","Magenta","Red","Volcano","Orange","Gold","Lime","Green","Cyan","Blue","GeekBlue","Purple"],l={Default:[["#f5f5f5","#000000","#1d1d1d"],["#272727","rgba(255, 255, 255, 0.95)","#dfdfdf"]],Primary:[["#eef2ff","#4f46e5","#4338ca"],["#282445","#8070ed","#b6acff"]],Secondary:[["#e2e8f0","#475569","#334155"],["#2b3240","#526077","#d6dce5"]],Success:[["#f6ffed","#52c41a","#2d6c0e"],["#162312","#49aa19","#73be4e"]],Processing:[["#e6f4ff","#2681ff","#1054b5"],["#111a2c","#145ec6","#78a7eb"]],Warning:[["#fffbe6","#faad14","#7d560a"],["#2b2111","#d89614","#dda535"]],Error:[["#fff2f0","#ff4d4f","#a33133"],["#2c1618","#dc4446","#ea8d8e"]],Danger:[["#fff2f0","#ff4d4f","#a33133"],["#2c1618","#dc4446","#ea8d8e"]],Magenta:[["#fff0f6","#ed409e","#a9196d"],["#291321","#cf3a8c","#e984b9"]],Red:[["#fff1f0","#e4202a","#b4111e"],["#2a1215","#cd1f28","#f08485"]],Volcano:[["#fff2e8","#fa541c","#aa2d0a"],["#2b1611","#d84a1b","#ed8e68"]],Orange:[["#fff7e6","#fa8c16","#904905"],["#2b1d11","#d87a16","#e89b3e"]],Gold:[["#fffbe6","#faad14","#835404"],["#2b2111","#d89614","#e8b339"]],Lime:[["#fcffe6","#a0d911","#486803"],["#1f2611","#8bbb11","#a9d134"]],Green:[["#f6ffed","#52c41a","#276d09"],["#162312","#49aa19","#6bbf3b"]],Cyan:[["#e6fffb","#13c2c2","#06686c"],["#112123","#13a8a8","#33bcb7"]],Blue:[["#e6f4ff","#2681ff","#0851c8"],["#111a2c","#145ec6","#6fa8ee"]],GeekBlue:[["#f0f5ff","#2f54eb","#1d39c4"],["#131629","#2b4acb","#89a0ea"]],Purple:[["#f9f0ff","#722ed1","#531dab"],["#1a1325","#642ab5","#b593df"]]},
|
|
1
|
+
var s=Object.freeze({records:1e4,observations:1e4,treeNodes:2e3,treeDepth:64,flowNodes:1e3,flowLinks:5e3,mapFeatures:5e3,mapCoordinates:25e4,mapBytes:8e6,text:1e4});function p(e){return typeof e=="number"&&Number.isFinite(e)&&Math.abs(e)<=Number.MAX_SAFE_INTEGER}function g(e,n,f=s.records){if(!Array.isArray(e)||e.length>f)throw new Error(`${n} must be a list with at most ${f} records.`)}function C(e){return typeof e=="string"&&e.length<=s.text}function x(e){return e?["#a16aff","#00cfff","#ff2b91","#ff8a00","#36e377","#e13dff","#4285ff","#ff4056"]:["#7020ff","#0094ff","#ff006e","#ff6a00","#00b94f","#c000ff","#004fff","#ff1738"]}var u=["Default","Primary","Secondary","Success","Processing","Warning","Error","Danger","Magenta","Red","Volcano","Orange","Gold","Lime","Green","Cyan","Blue","GeekBlue","Purple"],l={Default:[["#f5f5f5","#000000","#1d1d1d"],["#272727","rgba(255, 255, 255, 0.95)","#dfdfdf"]],Primary:[["#eef2ff","#4f46e5","#4338ca"],["#282445","#8070ed","#b6acff"]],Secondary:[["#e2e8f0","#475569","#334155"],["#2b3240","#526077","#d6dce5"]],Success:[["#f6ffed","#52c41a","#2d6c0e"],["#162312","#49aa19","#73be4e"]],Processing:[["#e6f4ff","#2681ff","#1054b5"],["#111a2c","#145ec6","#78a7eb"]],Warning:[["#fffbe6","#faad14","#7d560a"],["#2b2111","#d89614","#dda535"]],Error:[["#fff2f0","#ff4d4f","#a33133"],["#2c1618","#dc4446","#ea8d8e"]],Danger:[["#fff2f0","#ff4d4f","#a33133"],["#2c1618","#dc4446","#ea8d8e"]],Magenta:[["#fff0f6","#ed409e","#a9196d"],["#291321","#cf3a8c","#e984b9"]],Red:[["#fff1f0","#e4202a","#b4111e"],["#2a1215","#cd1f28","#f08485"]],Volcano:[["#fff2e8","#fa541c","#aa2d0a"],["#2b1611","#d84a1b","#ed8e68"]],Orange:[["#fff7e6","#fa8c16","#904905"],["#2b1d11","#d87a16","#e89b3e"]],Gold:[["#fffbe6","#faad14","#835404"],["#2b2111","#d89614","#e8b339"]],Lime:[["#fcffe6","#a0d911","#486803"],["#1f2611","#8bbb11","#a9d134"]],Green:[["#f6ffed","#52c41a","#276d09"],["#162312","#49aa19","#6bbf3b"]],Cyan:[["#e6fffb","#13c2c2","#06686c"],["#112123","#13a8a8","#33bcb7"]],Blue:[["#e6f4ff","#2681ff","#0851c8"],["#111a2c","#145ec6","#6fa8ee"]],GeekBlue:[["#f0f5ff","#2f54eb","#1d39c4"],["#131629","#2b4acb","#89a0ea"]],Purple:[["#f9f0ff","#722ed1","#531dab"],["#1a1325","#642ab5","#b593df"]]},i=e=>typeof e=="string"&&u.includes(e),y=e=>i(e)||typeof e=="string"&&/^#(?:[\da-f]{3}|[\da-f]{4}|[\da-f]{6}|[\da-f]{8})$/i.test(e);function m(e,n,f=()=>""){let t=l[e][n?1:0],r=e.toLowerCase();return{soft:f(`--bluui-color-${r}-soft`).trim()||t[0],solid:f(`--bluui-color-${r}-solid`).trim()||t[1],text:f(`--bluui-color-${r}-text`).trim()||t[2]}}function k(e,n,f,t){return i(e)?m(e,f,t).solid:e||n}function o(e){if(e.startsWith("rgb"))return e.match(/[\d.]+/g).slice(0,3).map(Number);let n=e.slice(1),f=n.length<5?n.slice(0,3).split("").map(t=>t+t).join(""):n.slice(0,6);return[0,2,4].map(t=>parseInt(f.slice(t,t+2),16))}function w(e,n){let f=Math.max(0,Math.min(1,n))*(e.length-1),t=Math.min(Math.floor(f),e.length-2),r=f-t,c=o(e[t]),d=o(e[t+1]);return`rgb(${c.map((a,b)=>Math.round(a+(d[b]-a)*r)).join(",")})`}function M(e){let n=o(e).map(t=>{let r=t/255;return r<=.04045?r/12.92:((r+.055)/1.055)**2.4}),f=n[0]*.2126+n[1]*.7152+n[2]*.0722;return(f+.05)/.0656>=4.5?"#182230":1.05/(f+.05)>=4.5?"#fff":"#000"}export{s as a,p as b,g as c,C as d,x as e,i as f,y as g,m as h,k as i,w as j,M as k};
|