@undp/data-viz 2.2.0 → 2.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/WaterfallChart.cjs.map +1 -1
- package/dist/WaterfallChart.d.ts +8 -9
- package/dist/WaterfallChart.js.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +8 -3162
- package/dist/index.js +112 -130
- package/dist/index.js.map +1 -1
- package/package.json +4 -16
- package/dist/getSchema.cjs +0 -2
- package/dist/getSchema.cjs.map +0 -1
- package/dist/getSchema.d.ts +0 -3258
- package/dist/getSchema.js +0 -1137
- package/dist/getSchema.js.map +0 -1
- package/dist/validateSchema.cjs +0 -2
- package/dist/validateSchema.cjs.map +0 -1
- package/dist/validateSchema.d.ts +0 -66
- package/dist/validateSchema.js +0 -109
- package/dist/validateSchema.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -1,201 +1,183 @@
|
|
|
1
|
-
import { GroupedBarGraph as e, SimpleBarGraph as
|
|
2
|
-
import { C as
|
|
3
|
-
import { DonutChart as
|
|
4
|
-
import { DumbbellChart as
|
|
5
|
-
import { BeeSwarmChart as
|
|
1
|
+
import { GroupedBarGraph as e, SimpleBarGraph as t, StackedBarGraph as a } from "./BarGraph.js";
|
|
2
|
+
import { C as m } from "./index-D5ihtaJJ.js";
|
|
3
|
+
import { DonutChart as x } from "./DonutChart.js";
|
|
4
|
+
import { DumbbellChart as h } from "./DumbbellChart.js";
|
|
5
|
+
import { BeeSwarmChart as i } from "./BeeSwarmChart.js";
|
|
6
6
|
import { DualAxisLineChart as d } from "./DualAxisLineChart.js";
|
|
7
|
-
import { LineChartWithConfidenceInterval as
|
|
8
|
-
import { SimpleLineChart as
|
|
9
|
-
import { MultiLineChart as
|
|
7
|
+
import { LineChartWithConfidenceInterval as g } from "./LineChartWithConfidenceInterval.js";
|
|
8
|
+
import { SimpleLineChart as D } from "./SimpleLineChart.js";
|
|
9
|
+
import { MultiLineChart as c } from "./MultiLineChart.js";
|
|
10
10
|
import { MultiLineAltChart as b } from "./MultiLineAltChart.js";
|
|
11
11
|
import { DifferenceLineChart as M } from "./DifferenceLineChart.js";
|
|
12
12
|
import { SparkLine as B } from "./SparkLine.js";
|
|
13
13
|
import { BiVariateChoroplethMap as P } from "./BiVariateChoroplethMap.js";
|
|
14
|
-
import { ChoroplethMap as
|
|
14
|
+
import { ChoroplethMap as y } from "./ChoroplethMap.js";
|
|
15
15
|
import { DotDensityMap as H } from "./DotDensityMap.js";
|
|
16
|
-
import { HybridMap as
|
|
17
|
-
import { ThreeDGlobe as
|
|
18
|
-
import { GeoHubMap as
|
|
19
|
-
import { GeoHubCompareMaps as
|
|
20
|
-
import { GeoHubMapWithLayerSelection as
|
|
21
|
-
import { ScatterPlot as
|
|
16
|
+
import { HybridMap as w } from "./HybridMap.js";
|
|
17
|
+
import { ThreeDGlobe as W } from "./ThreeDGlobe.js";
|
|
18
|
+
import { GeoHubMap as V } from "./GeoHubMap.js";
|
|
19
|
+
import { GeoHubCompareMaps as U } from "./GeoHubCompareMaps.js";
|
|
20
|
+
import { GeoHubMapWithLayerSelection as J } from "./GeoHubMapWithLayerSelection.js";
|
|
21
|
+
import { ScatterPlot as Q } from "./ScatterPlot.js";
|
|
22
22
|
import { SlopeChart as j } from "./SlopeChart.js";
|
|
23
23
|
import { BulletChart as K } from "./BulletChart.js";
|
|
24
24
|
import { AreaChart as Y } from "./AreaChart.js";
|
|
25
25
|
import { BasicStatCard as _ } from "./BasicStatCard.js";
|
|
26
26
|
import { StatCardFromData as rr } from "./StatCardFromData.js";
|
|
27
27
|
import { TreeMapGraph as er } from "./TreeMapGraph.js";
|
|
28
|
-
import { UnitChart as
|
|
29
|
-
import { HeatMap as
|
|
30
|
-
import { DataTable as
|
|
31
|
-
import { DataCards as
|
|
32
|
-
import { StripChart as
|
|
28
|
+
import { UnitChart as ar } from "./UnitChart.js";
|
|
29
|
+
import { HeatMap as mr } from "./HeatMap.js";
|
|
30
|
+
import { DataTable as xr } from "./DataTable.js";
|
|
31
|
+
import { DataCards as hr } from "./DataCards.js";
|
|
32
|
+
import { StripChart as ir } from "./StripChart.js";
|
|
33
33
|
import { ParetoChart as dr } from "./ParetoChart.js";
|
|
34
|
-
import { ButterflyChart as
|
|
35
|
-
import { Histogram as
|
|
36
|
-
import { WaterfallChart as
|
|
34
|
+
import { ButterflyChart as gr } from "./ButterflyChart.js";
|
|
35
|
+
import { Histogram as Dr } from "./Histogram.js";
|
|
36
|
+
import { WaterfallChart as cr } from "./WaterfallChart.js";
|
|
37
37
|
import { SankeyChart as br } from "./SankeyChart.js";
|
|
38
38
|
import { RadarChart as Mr } from "./RadarChart.js";
|
|
39
39
|
import { MultiGraphDashboard as Br } from "./MultiGraphDashboard.js";
|
|
40
40
|
import { PerformanceIntensiveMultiGraphDashboard as Pr } from "./PerformanceIntensiveMultiGraphDashboard.js";
|
|
41
|
-
import { MultiGraphDashboardWideToLongFormat as
|
|
41
|
+
import { MultiGraphDashboardWideToLongFormat as yr } from "./MultiGraphDashboardWideToLongFormat.js";
|
|
42
42
|
import { SingleGraphDashboard as Hr } from "./SingleGraphDashboard.js";
|
|
43
|
-
import { SingleGraphDashboardGeoHubMaps as
|
|
44
|
-
import { SingleGraphDashboardThreeDGraphs as
|
|
45
|
-
import { GriddedGraphs as
|
|
46
|
-
import { ScrollStory as
|
|
47
|
-
import { PerformanceIntensiveScrollStory as
|
|
48
|
-
import { MultiGraphDashboardFromConfig as
|
|
43
|
+
import { SingleGraphDashboardGeoHubMaps as wr } from "./SingleGraphDashboardGeoHubMaps.js";
|
|
44
|
+
import { SingleGraphDashboardThreeDGraphs as Wr } from "./SingleGraphDashboardThreeDGraphs.js";
|
|
45
|
+
import { GriddedGraphs as Vr } from "./GriddedGraphs.js";
|
|
46
|
+
import { ScrollStory as Ur } from "./ScrollStory.js";
|
|
47
|
+
import { PerformanceIntensiveScrollStory as Jr } from "./PerformanceIntensiveScrollStory.js";
|
|
48
|
+
import { MultiGraphDashboardFromConfig as Qr } from "./MultiGraphDashboardFromConfig.js";
|
|
49
49
|
import { PerformanceIntensiveMultiGraphDashboardFromConfig as jr } from "./PerformanceIntensiveMultiGraphDashboardFromConfig.js";
|
|
50
50
|
import { MultiGraphDashboardWideToLongFormatFromConfig as Kr } from "./MultiGraphDashboardWideToLongFormatFromConfig.js";
|
|
51
51
|
import { SingleGraphDashboardFromConfig as Yr } from "./SingleGraphDashboardFromConfig.js";
|
|
52
52
|
import { SingleGraphDashboardGeoHubMapsFromConfig as _r } from "./SingleGraphDashboardGeoHubMapsFromConfig.js";
|
|
53
53
|
import { SingleGraphDashboardThreeDGraphsFromConfig as ro } from "./SingleGraphDashboardThreeDGraphsFromConfig.js";
|
|
54
54
|
import { GriddedGraphsFromConfig as eo } from "./GriddedGraphsFromConfig.js";
|
|
55
|
-
import { ExcelDownloadButton as
|
|
56
|
-
import { ImageDownloadButton as
|
|
57
|
-
import { SVGDownloadButton as
|
|
58
|
-
import { CsvDownloadButton as
|
|
59
|
-
import { CopyTextButton as
|
|
60
|
-
import { Colors as
|
|
61
|
-
import { ColorLegend as
|
|
62
|
-
import { ColorLegendWithMouseOver as
|
|
63
|
-
import { LinearColorLegend as
|
|
55
|
+
import { ExcelDownloadButton as ao } from "./ExcelDownloadButton.js";
|
|
56
|
+
import { ImageDownloadButton as mo } from "./ImageDownloadButton.js";
|
|
57
|
+
import { SVGDownloadButton as xo } from "./SVGDownloadButton.js";
|
|
58
|
+
import { CsvDownloadButton as ho } from "./CsvDownloadButton.js";
|
|
59
|
+
import { CopyTextButton as io } from "./CopyTextButton.js";
|
|
60
|
+
import { Colors as Co } from "./Colors.js";
|
|
61
|
+
import { ColorLegend as uo } from "./ColorLegend.js";
|
|
62
|
+
import { ColorLegendWithMouseOver as Go } from "./ColorLegendWithMouseOver.js";
|
|
63
|
+
import { LinearColorLegend as So } from "./LinearColorLegend.js";
|
|
64
64
|
import { ThresholdColorLegendWithMouseOver as Fo } from "./ThresholdColorLegendWithMouseOver.js";
|
|
65
65
|
import { GraphFooter as Lo } from "./GraphFooter.js";
|
|
66
66
|
import { GraphHeader as To } from "./GraphHeader.js";
|
|
67
|
-
import { FootNote as
|
|
68
|
-
import { GraphDescription as
|
|
69
|
-
import { GraphTitle as
|
|
70
|
-
import { S as
|
|
71
|
-
import { c as
|
|
72
|
-
import { g as
|
|
73
|
-
import { n as
|
|
67
|
+
import { FootNote as Ao } from "./FootNote.js";
|
|
68
|
+
import { GraphDescription as vo } from "./GraphDescription.js";
|
|
69
|
+
import { GraphTitle as ko } from "./GraphTitle.js";
|
|
70
|
+
import { S as Io } from "./Source-F8EYCYkV.js";
|
|
71
|
+
import { c as Oo } from "./checkIfNullOrUndefined-DmfiKkNw.js";
|
|
72
|
+
import { g as No, a as Uo, b as Eo, c as Jo, r as qo } from "./removeOutliers-BqW0sPqj.js";
|
|
73
|
+
import { n as Ro } from "./numberFormattingFunction-14YCbkN2.js";
|
|
74
74
|
import { g as zo } from "./getTextColorBasedOnBgColor-CDY808zi.js";
|
|
75
75
|
import { g as Xo } from "./getJenks-DTCcQSDi.js";
|
|
76
76
|
import { i as Zo } from "./imageDownload-Diofs_vY.js";
|
|
77
77
|
import { s as $o } from "./svgDownload-BAoarWNt.js";
|
|
78
78
|
import { e as oe } from "./excelDownload-BEC1AyQW.js";
|
|
79
|
-
import { g as
|
|
80
|
-
import { g as
|
|
81
|
-
import { b as fe, d as
|
|
82
|
-
import { t as de, a as
|
|
83
|
-
import { t as
|
|
84
|
-
import {
|
|
85
|
-
import { getDashboardJSONSchema as Fe, getDashboardWideToLongFormatJSONSchema as Me, getDataFiltersSchema as Le, getDataSchema as Be, getDataSelectionSchema as Te, getDataSettingsSchema as Pe, getDataTransformSchema as ve, getFiltersSchema as Ae, getGraphDataConfigurationSchema as ye, getGriddedGraphJSONSchema as He, getReadableHeaderSchema as Oe, getSettingsSchema as ke, getSingleGraphJSONSchema as we } from "./getSchema.js";
|
|
86
|
-
import { g as We } from "./getGraphList-Bpd3PVmF.js";
|
|
79
|
+
import { g as te } from "./getUniqValue-DsqSii6M.js";
|
|
80
|
+
import { g as pe } from "./getCentroidCoordinates-s0OOUjLF.js";
|
|
81
|
+
import { b as fe, d as xe, f as ne, c as he, a as se, t as ie } from "./fetchAndParseData-BAXhgTDM.js";
|
|
82
|
+
import { t as de, a as Ce } from "./transformDataForAggregation-wdPf8bNt.js";
|
|
83
|
+
import { t as ue } from "./transformDataForGraphFromFile-dt9sHTVy.js";
|
|
84
|
+
import { g as Ge } from "./getGraphList-Bpd3PVmF.js";
|
|
87
85
|
export {
|
|
88
86
|
Y as AreaChart,
|
|
89
87
|
_ as BasicStatCard,
|
|
90
|
-
|
|
88
|
+
i as BeeSwarmChart,
|
|
91
89
|
P as BiVariateChoroplethMap,
|
|
92
90
|
K as BulletChart,
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
91
|
+
gr as ButterflyChart,
|
|
92
|
+
y as ChoroplethMap,
|
|
93
|
+
m as CirclePackingGraph,
|
|
94
|
+
uo as ColorLegend,
|
|
95
|
+
Go as ColorLegendWithMouseOver,
|
|
96
|
+
Co as Colors,
|
|
97
|
+
io as CopyTextButton,
|
|
98
|
+
ho as CsvDownloadButton,
|
|
99
|
+
hr as DataCards,
|
|
100
|
+
xr as DataTable,
|
|
103
101
|
M as DifferenceLineChart,
|
|
104
|
-
|
|
102
|
+
x as DonutChart,
|
|
105
103
|
H as DotDensityMap,
|
|
106
104
|
d as DualAxisLineChart,
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
105
|
+
h as DumbbellChart,
|
|
106
|
+
ao as ExcelDownloadButton,
|
|
107
|
+
Ao as FootNote,
|
|
108
|
+
U as GeoHubCompareMaps,
|
|
109
|
+
V as GeoHubMap,
|
|
110
|
+
J as GeoHubMapWithLayerSelection,
|
|
111
|
+
vo as GraphDescription,
|
|
114
112
|
Lo as GraphFooter,
|
|
115
113
|
To as GraphHeader,
|
|
116
|
-
|
|
117
|
-
|
|
114
|
+
ko as GraphTitle,
|
|
115
|
+
Vr as GriddedGraphs,
|
|
118
116
|
eo as GriddedGraphsFromConfig,
|
|
119
117
|
e as GroupedBarGraph,
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
118
|
+
mr as HeatMap,
|
|
119
|
+
Dr as Histogram,
|
|
120
|
+
w as HybridMap,
|
|
121
|
+
mo as ImageDownloadButton,
|
|
122
|
+
g as LineChartWithConfidenceInterval,
|
|
123
|
+
So as LinearColorLegend,
|
|
126
124
|
Br as MultiGraphDashboard,
|
|
127
|
-
|
|
128
|
-
|
|
125
|
+
Qr as MultiGraphDashboardFromConfig,
|
|
126
|
+
yr as MultiGraphDashboardWideToLongFormat,
|
|
129
127
|
Kr as MultiGraphDashboardWideToLongFormatFromConfig,
|
|
130
128
|
b as MultiLineAltChart,
|
|
131
|
-
|
|
129
|
+
c as MultiLineChart,
|
|
132
130
|
dr as ParetoChart,
|
|
133
131
|
Pr as PerformanceIntensiveMultiGraphDashboard,
|
|
134
132
|
jr as PerformanceIntensiveMultiGraphDashboardFromConfig,
|
|
135
|
-
|
|
133
|
+
Jr as PerformanceIntensiveScrollStory,
|
|
136
134
|
Mr as RadarChart,
|
|
137
|
-
|
|
135
|
+
xo as SVGDownloadButton,
|
|
138
136
|
br as SankeyChart,
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
137
|
+
Q as ScatterPlot,
|
|
138
|
+
Ur as ScrollStory,
|
|
139
|
+
t as SimpleBarGraph,
|
|
140
|
+
D as SimpleLineChart,
|
|
143
141
|
Hr as SingleGraphDashboard,
|
|
144
142
|
Yr as SingleGraphDashboardFromConfig,
|
|
145
|
-
|
|
143
|
+
wr as SingleGraphDashboardGeoHubMaps,
|
|
146
144
|
_r as SingleGraphDashboardGeoHubMapsFromConfig,
|
|
147
|
-
|
|
145
|
+
Wr as SingleGraphDashboardThreeDGraphs,
|
|
148
146
|
ro as SingleGraphDashboardThreeDGraphsFromConfig,
|
|
149
147
|
j as SlopeChart,
|
|
150
|
-
|
|
148
|
+
Io as Source,
|
|
151
149
|
B as SparkLine,
|
|
152
|
-
|
|
150
|
+
a as StackedBarGraph,
|
|
153
151
|
rr as StatCardFromData,
|
|
154
|
-
|
|
155
|
-
|
|
152
|
+
ir as StripChart,
|
|
153
|
+
W as ThreeDGlobe,
|
|
156
154
|
Fo as ThresholdColorLegendWithMouseOver,
|
|
157
155
|
er as TreeMapGraph,
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
156
|
+
ar as UnitChart,
|
|
157
|
+
cr as WaterfallChart,
|
|
158
|
+
Oo as checkIfNullOrUndefined,
|
|
161
159
|
oe as excelDownload,
|
|
162
160
|
fe as fetchAndParseCSV,
|
|
163
|
-
|
|
161
|
+
xe as fetchAndParseCSVFromTextBlob,
|
|
164
162
|
ne as fetchAndParseJSON,
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
Fe as getDashboardJSONSchema,
|
|
171
|
-
Me as getDashboardWideToLongFormatJSONSchema,
|
|
172
|
-
Le as getDataFiltersSchema,
|
|
173
|
-
Be as getDataSchema,
|
|
174
|
-
Te as getDataSelectionSchema,
|
|
175
|
-
Pe as getDataSettingsSchema,
|
|
176
|
-
ve as getDataTransformSchema,
|
|
177
|
-
Ae as getFiltersSchema,
|
|
178
|
-
ye as getGraphDataConfigurationSchema,
|
|
179
|
-
He as getGriddedGraphJSONSchema,
|
|
163
|
+
he as fetchAndParseMultipleDataSources,
|
|
164
|
+
se as fetchAndTransformDataFromAPI,
|
|
165
|
+
No as generateEmbedLink,
|
|
166
|
+
Uo as generateIframeCode,
|
|
167
|
+
pe as getCentroidCoordinates,
|
|
180
168
|
Xo as getJenks,
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
Oe as getReadableHeaderSchema,
|
|
184
|
-
ke as getSettingsSchema,
|
|
185
|
-
we as getSingleGraphJSONSchema,
|
|
169
|
+
Eo as getPercentileValue,
|
|
170
|
+
Jo as getQueryParamsFromLink,
|
|
186
171
|
zo as getTextColorBasedOnBgColor,
|
|
187
|
-
|
|
188
|
-
|
|
172
|
+
te as getUniqValue,
|
|
173
|
+
Ge as graphList,
|
|
189
174
|
Zo as imageDownload,
|
|
190
|
-
|
|
191
|
-
|
|
175
|
+
Ro as numberFormattingFunction,
|
|
176
|
+
qo as removeOutliers,
|
|
192
177
|
$o as svgDownload,
|
|
193
|
-
|
|
178
|
+
ie as transformColumnsToArray,
|
|
194
179
|
de as transformDataForAggregation,
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
De as validateConfigSchema,
|
|
198
|
-
Ge as validateDataSchema,
|
|
199
|
-
ue as validateSettingsSchema
|
|
180
|
+
Ce as transformDataForGraph,
|
|
181
|
+
ue as transformDataForGraphFromFile
|
|
200
182
|
};
|
|
201
183
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@undp/data-viz",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.1",
|
|
4
4
|
"main": "./dist/index.cjs",
|
|
5
5
|
"module": "./dist/index.js",
|
|
6
6
|
"browser": "./dist/index.umd.js",
|
|
@@ -387,16 +387,6 @@
|
|
|
387
387
|
"import": "./dist/transformData.js",
|
|
388
388
|
"require": "./dist/transformData.cjs"
|
|
389
389
|
},
|
|
390
|
-
"./validateSchema": {
|
|
391
|
-
"types": "./dist/validateSchema.d.ts",
|
|
392
|
-
"import": "./dist/validateSchema.js",
|
|
393
|
-
"require": "./dist/validateSchema.cjs"
|
|
394
|
-
},
|
|
395
|
-
"./getSchema": {
|
|
396
|
-
"types": "./dist/getSchema.d.ts",
|
|
397
|
-
"import": "./dist/getSchema.js",
|
|
398
|
-
"require": "./dist/getSchema.cjs"
|
|
399
|
-
},
|
|
400
390
|
"./Types": {
|
|
401
391
|
"types": "./dist/Types.d.ts",
|
|
402
392
|
"import": "./dist/Types.js",
|
|
@@ -476,7 +466,6 @@
|
|
|
476
466
|
"@dnd-kit/core": "^6.3.1",
|
|
477
467
|
"@dnd-kit/modifiers": "^9.0.0",
|
|
478
468
|
"@undp/design-system-react": "^1.5.5",
|
|
479
|
-
"ajv": "^8.17.1",
|
|
480
469
|
"dom-to-svg": "^0.12.2",
|
|
481
470
|
"file-saver": "^2.0.5",
|
|
482
471
|
"handlebars": "^4.7.8",
|
|
@@ -543,9 +532,6 @@
|
|
|
543
532
|
},
|
|
544
533
|
"handlebars": {
|
|
545
534
|
"optional": true
|
|
546
|
-
},
|
|
547
|
-
"ajv": {
|
|
548
|
-
"optional": true
|
|
549
535
|
}
|
|
550
536
|
},
|
|
551
537
|
"optionalDependencies": {
|
|
@@ -591,8 +577,8 @@
|
|
|
591
577
|
"@types/three": "^0.180.0",
|
|
592
578
|
"@typescript-eslint/eslint-plugin": "^8.42.0",
|
|
593
579
|
"@typescript-eslint/parser": "^8.42.0",
|
|
580
|
+
"@undp/design-system-react": "^1.5.5",
|
|
594
581
|
"@vitejs/plugin-react": "^5.0.2",
|
|
595
|
-
"ajv": "^8.17.1",
|
|
596
582
|
"autoprefixer": "^10.4.21",
|
|
597
583
|
"dom-to-svg": "^0.12.2",
|
|
598
584
|
"eslint": "^9.34.0",
|
|
@@ -614,7 +600,9 @@
|
|
|
614
600
|
"pmtiles": "^4.3.2",
|
|
615
601
|
"postcss": "^8.5.6",
|
|
616
602
|
"prettier": "^3.6.2",
|
|
603
|
+
"react": "^19.2.3",
|
|
617
604
|
"react-docgen-typescript": "^2.4.0",
|
|
605
|
+
"react-dom": "^19.2.3",
|
|
618
606
|
"react-globe.gl": "^2.37.0",
|
|
619
607
|
"rimraf": "^6.0.1",
|
|
620
608
|
"rollup-plugin-visualizer": "^6.0.3",
|
package/dist/getSchema.cjs
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./getGraphList-DQ24IzAn.cjs"),y="https://raw.githubusercontent.com/UNDP-Data/undp-viz-library-schemas/refs/heads/main/";function S(e){if(i.graphList.filter(t=>t.geoHubMapPresentation).map(t=>t.graphID).indexOf(e)!==-1)return null;switch(e){case"dataTable":return"dataSchema/dataTableDataSchema.json";case"dataCards":return"dataSchema/dataTableDataSchema.json";case"barChart":return"dataSchema/barGraphDataSchema.json";case"stackedBarChart":return"dataSchema/stackedBarGraphDataSchema.json";case"groupedBarChart":return"dataSchema/groupedBarGraphDataSchema.json";case"lineChart":return"dataSchema/lineChartDataSchema.json";case"dualAxisLineChart":return"dataSchema/dualAxisLineChartDataSchema.json";case"differenceLineChart":return"dataSchema/differenceLineChartDataSchema.json";case"multiLineChart":return"dataSchema/multiLineChartDataSchema.json";case"multiLineAltChart":return"dataSchema/multiLineAltChartDataSchema.json";case"stackedAreaChart":return"dataSchema/areaChartDataSchema.json";case"choroplethMap":return"dataSchema/choroplethMapDataSchema.json";case"threeDGlobe":return"dataSchema/choroplethMapDataSchema.json";case"bulletChart":return"dataSchema/bulletChartDataSchema.json";case"biVariateChoroplethMap":return"dataSchema/biVariateChoroplethMapDataSchema.json";case"dotDensityMap":return"dataSchema/dotDensityMapDataSchema.json";case"donutChart":return"dataSchema/donutChartDataSchema.json";case"slopeChart":return"dataSchema/slopeChartDataSchema.json";case"scatterPlot":return"dataSchema/scatterPlotDataSchema.json";case"dumbbellChart":return"dataSchema/dumbbellChartDataSchema.json";case"treeMap":return"dataSchema/treeMapDataSchema.json";case"circlePacking":return"dataSchema/circlePackingDataSchema.json";case"heatMap":return"dataSchema/heatMapDataSchema.json";case"stripChart":return"dataSchema/stripChartDataSchema.json";case"beeSwarmChart":return"dataSchema/beeSwarmChartDataSchema.json";case"butterflyChart":return"dataSchema/butterflyChartDataSchema.json";case"histogram":return"dataSchema/histogramDataSchema.json";case"sparkLine":return"dataSchema/lineChartDataSchema.json";case"paretoChart":return"dataSchema/paretoChartDataSchema.json";case"statCard":return"dataSchema/statCardDataSchema.json";case"unitChart":return"dataSchema/unitChartDataSchema.json";case"sankeyChart":return"dataSchema/sankeyChartDataSchema.json";case"lineChartWithConfidenceInterval":return"dataSchema/lineChartWithConfidenceIntervalDataSchema.json";case"hybridMap":return"dataSchema/hybridMapDataSchema.json";case"radarChart":return"dataSchema/radarChartDataSchema.json";case"waterfallChart":return"dataSchema/waterfallChartDataSchema.json";default:return console.error("Unknown chart type:",e),null}}function b(e){switch(e){case"barChart":return"settingsSchema/simpleBarChartSettingsSchema.json";case"stackedBarChart":return"settingsSchema/stackedBarChartSettingsSchema.json";case"groupedBarChart":return"settingsSchema/groupedBarChartSettingsSchema.json";case"lineChart":return"settingsSchema/lineChartSettingsSchema.json";case"dualAxisLineChart":return"settingsSchema/dualAxisLineChartSettingsSchema.json";case"multiLineChart":return"settingsSchema/multiLineChartSettingsSchema.json";case"multiLineAltChart":return"settingsSchema/multiLineAltChartSettingsSchema.json";case"differenceLineChart":return"settingsSchema/differenceLineChartSettingsSchema.json";case"stackedAreaChart":return"settingsSchema/stackedAreaChartSettingsSchema.json";case"choroplethMap":return"settingsSchema/choroplethMapSettingsSchema.json";case"threeDGlobe":return"settingsSchema/threeDGlobeSettingsSchema.json";case"bulletChart":return"settingsSchema/bulletChartSettingsSchema.json";case"biVariateChoroplethMap":return"settingsSchema/biVariateChoroplethMapSettingsSchema.json";case"dotDensityMap":return"settingsSchema/dotDensityMapSettingsSchema.json";case"donutChart":return"settingsSchema/donutChartSettingsSchema.json";case"slopeChart":return"settingsSchema/slopeChartSettingsSchema.json";case"scatterPlot":return"settingsSchema/scatterPlotSettingsSchema.json";case"dumbbellChart":return"settingsSchema/dumbbellChartSettingsSchema.json";case"treeMap":return"settingsSchema/treeMapSettingsSchema.json";case"circlePacking":return"settingsSchema/circlePackingSettingsSchema.json";case"heatMap":return"settingsSchema/heatMapSettingsSchema.json";case"stripChart":return"settingsSchema/stripChartSettingsSchema.json";case"beeSwarmChart":return"settingsSchema/beeSwarmChartSettingsSchema.json";case"butterflyChart":return"settingsSchema/butterflyChartSettingsSchema.json";case"histogram":return"settingsSchema/histogramSettingsSchema.json";case"sparkLine":return"settingsSchema/sparkLineSettingsSchema.json";case"paretoChart":return"settingsSchema/paretoChartSettingsSchema.json";case"dataTable":return"settingsSchema/dataTableSettingsSchema.json";case"statCard":return"settingsSchema/statCardSettingsSchema.json";case"geoHubCompareMap":return"settingsSchema/geoHubCompareMapSettingsSchema.json";case"geoHubMap":return"settingsSchema/geoHubMapSettingsSchema.json";case"geoHubMapWithLayerSelection":return"settingsSchema/geoHubMapWithLayerSelectionSettingsSchema.json";case"unitChart":return"settingsSchema/unitChartSettingsSchema.json";case"sankeyChart":return"settingsSchema/sankeyChartSettingsSchema.json";case"lineChartWithConfidenceInterval":return"settingsSchema/lineChartWithConfidenceIntervalSettingsSchema.json";case"dataCards":return"settingsSchema/dataCardListSettingsSchema.json";case"allGraphs":return"settingsSchema/SettingsSchema.json";case"radarChart":return"settingsSchema/radarChartSettingsSchema.json";case"hybridMap":return"settingsSchema/hybridMapSettingsSchema.json";case"waterfallChart":return"settingsSchema/waterfallChartSettingsSchema.json";default:return console.error("Unknown chart type:",e),null}}async function j(e){const t=await fetch(`${y}${S(e)}`);if(!t.ok)throw new Error(`Response status: ${t.status}`);return await t.json()}async function l(e){const t=await fetch(`${y}${b(e)}`);if(!t.ok)throw new Error(`Response status: ${t.status}`);return await t.json()}function C(e){switch(e){case"barChart":return["label","size","color","date"];case"waterfallChart":return["label","size","color"];case"hybridMap":return["lat","long","x","id","radius","label","date"];case"bulletChart":return["label","size","target","qualitativeRange","date"];case"treeMap":return["label","size","color"];case"circlePacking":return["label","size","color"];case"butterflyChart":return["label","leftBar","rightBar","date"];case"groupedBarChart":return["label","size","date"];case"stackedBarChart":return["label","size","date"];case"dumbbellChart":return["x","label","date"];case"donutChart":return["size","label"];case"histogram":return["value"];case"choroplethMap":return["x","id","date"];case"threeDGlobe":return["x","id"];case"biVariateChoroplethMap":return["x","y","id","date"];case"lineChart":return["date","y"];case"multiLineChart":return["date","y"];case"multiLineAltChart":return["date","y","label","color"];case"radarChart":return["values","label","color"];case"stackedAreaChart":return["date","y"];case"scatterPlot":return["x","y","radius","color","label","date"];case"dualAxisLineChart":return["date","y1","y2"];case"paretoChart":return["label","bar","line"];case"dotDensityMap":return["lat","long","radius","color","label","date"];case"slopeChart":return["y1","y2","color","label"];case"heatMap":return["row","column","value"];case"beeSwarmChart":return["label","position","radius","color"];case"stripChart":return["label","position","color"];case"statCard":return["value"];case"sankeyChart":return["source","target","value"];case"differenceLineChart":return["date","y1","y2"];case"unitChart":return["label","value"];case"sparkLine":return["date","y"];case"lineChartWithConfidenceInterval":return["date","y","yMin","yMax"];case"dashboardWideToLong":return["label","size","color","value"];case"dashboard":return["label","radius","size","row","y1","y","rightBar","position","leftBar","x","bar","line","y2","column","date","value","color","long","lat","id","source","target","yMin","yMax"];default:return["label","radius","size","row","y1","y","rightBar","position","leftBar","x","bar","line","y2","column","date","value","color","long","lat","id","source","target","yMin","yMax"]}}function n(e){return!e||e.length===0?{}:{enum:e}}const m=e=>({items:{properties:{column:{type:"string",...n(e)},delimiter:{type:"string"}},type:"object",required:["column"]},type:"array"}),o=e=>({properties:{columnsToArray:m(e),data:{},dataURL:{oneOf:[{type:"string"},{type:"array",items:{type:"object",properties:{fileType:{enum:["csv","json","api"],type:"string"},apiHeaders:{},dataTransformation:{type:"string"},idColumnName:{type:"string"},dataURL:{type:"string"},delimiter:{type:"string"},columnsToArray:m()},required:["dataURL","idColumnName"]}}]},delimiter:{type:"string"},fileType:{enum:["csv","json","api"],type:"string"},apiHeaders:{},dataTransformation:{type:"string"},idColumnTitle:{type:"string"}},type:"object"}),c=e=>({type:"array",items:{type:"object",properties:{value:{type:"string",...n(e)},label:{type:"string"}},required:["value","label"]}}),p=e=>({items:{properties:{clearable:{type:"boolean"},allowSelectAll:{type:"boolean"},width:{type:"string"},excludeValues:{items:{type:"string"},type:"array"},column:{type:"string",...n(e)},defaultValue:{anyOf:[{items:{oneOf:[{type:"string"},{type:"number"}]},type:"array"},{type:"string"},{type:"number"}]},label:{type:"string"},ui:{type:"string",enum:["select","radio"]},singleSelect:{type:"boolean"}},required:["column"],type:"object"},type:"array"}),g=async e=>{const t=await l("allGraphs");return{type:"array",items:{type:"object",properties:{chartConfigId:{type:"string"},label:{type:"string"},width:{type:"string"},allowedColumnIds:{type:"array",items:{type:"object",properties:{value:{type:"string",...n(e)},label:{type:"string"},graphSettings:t},required:["value","label"]},minItems:1},ui:{type:"string",enum:["select","radio"]}},required:["chartConfigId","allowedColumnIds"]}}},s=e=>({type:"array",items:{type:"object",properties:{column:{type:"string",...n(e)},includeValues:{type:"array",items:{oneOf:[{type:"string"},{type:"number"},{type:"boolean"},{type:"null"}]}},excludeValues:{type:"array",items:{oneOf:[{type:"string"},{type:"number"},{type:"boolean"},{type:"null"}]}}},required:["column"]}}),d=e=>({type:"object",properties:{keyColumn:{type:"string",...n(e)},aggregationColumnsSetting:{type:"array",items:{type:"object",properties:{column:{type:"string",...n(e)},aggregationMethod:{type:"string",enum:["sum","average","min","max"]}},required:["column"]}}},required:["keyColumn"]}),h=(e,t)=>({type:"array",items:{type:"object",properties:{columnId:{oneOf:[{type:"string",...n(e)},{type:"array",items:{type:"string",...n(e)}}]},chartConfigId:{type:"string",...n(C(t))}},required:["columnId","chartConfigId"]}}),u=async(e,t)=>{const a=await l("allGraphs");return{type:"array",items:{type:"object",properties:{chartConfigId:{type:"string"},label:{type:"string"},width:{type:"string"},options:{type:"array",items:{type:"object",properties:{dataConfiguration:h(e,t),label:{type:"string"},graphSettings:a},required:["dataConfiguration","label"]},minItems:1},defaultValue:{type:"array",items:{type:"object",properties:{dataConfiguration:h(e,t),label:{type:"string"},graphSettings:a},required:["dataConfiguration","label"]},minItems:1},ui:{type:"string",enum:["select","radio"]}},required:["chartConfigId","options"]}}},f=async(e,t)=>{const a=await l(t||"allGraphs");return t&&i.graphList.filter(r=>r.geoHubMapPresentation).map(r=>r.graphID).indexOf(t)!==-1?{type:"object",properties:{graphSettings:a,graphType:{type:"string",enum:i.graphList.filter(r=>r.geoHubMapPresentation).map(r=>r.graphID)},debugMode:{type:"boolean"},theme:{type:"string",enum:["dark","light"]},uiMode:{type:"string",enum:["light","normal"]},classNames:{type:"object"},highlightDataPointSettings:{type:"object",properties:{column:{type:"string"},label:{type:"string"},defaultValues:{oneOf:[{type:"array",items:{type:"string"}},{type:"array",items:{type:"number"}}]},excludeValues:{type:"array",items:{type:"string"}},allowSelectAll:{type:"boolean"},width:{type:"string"}},required:["column"]},styles:{type:"object"}},required:["graphType"]}:t==="dataTable"||t==="dataCards"?{type:"object",properties:{graphSettings:a,dataSettings:o(e),filters:p(e),noOfFiltersPerRow:{type:"number"},graphType:{type:"string",enum:["dataTable","dataCards"]},dataTransform:d(e),dataFilters:s(e),readableHeader:c(e),dataSelectionOptions:g(e),advancedDataSelectionOptions:u(e,t),debugMode:{type:"boolean"},theme:{type:"string",enum:["dark","light"]},uiMode:{type:"string",enum:["light","normal"]},classNames:{type:"object"},highlightDataPointSettings:{type:"object",properties:{column:{type:"string"},label:{type:"string"},defaultValues:{oneOf:[{type:"array",items:{type:"string"}},{type:"array",items:{type:"number"}}]},excludeValues:{type:"array",items:{type:"string"}},allowSelectAll:{type:"boolean"},width:{type:"string"}},required:["column"]},styles:{type:"object"}},required:["dataSettings","graphType"]}:{type:"object",properties:{graphSettings:a,dataSettings:o(e),filters:p(e),classNames:{type:"object"},styles:{type:"object"},graphType:{type:"string",enum:i.graphList.map(r=>r.graphID)},noOfFiltersPerRow:{type:"number"},dataTransform:d(e),dataFilters:s(e),graphDataConfiguration:h(e,t),readableHeader:c(e),dataSelectionOptions:g(e),advancedDataSelectionOptions:u(e,t),debugMode:{type:"boolean"},theme:{type:"string",enum:["dark","light"]},highlightDataPointSettings:{type:"object",properties:{column:{type:"string"},label:{type:"string"},defaultValues:{oneOf:[{type:"array",items:{type:"string"}},{type:"array",items:{type:"number"}}]},excludeValues:{type:"array",items:{type:"string"}},allowSelectAll:{type:"boolean"},width:{type:"string"}},required:["column"]},uiMode:{type:"string",enum:["light","normal"]}},required:t?["dataSettings","graphType","graphDataConfiguration"]:["graphType"]}},D=async(e,t)=>{const a=await l(t||"allGraphs");return t==="dataTable"||t==="dataCards"?{type:"object",properties:{graphSettings:a,dataSettings:o(e),filters:p(e),classNames:{type:"object"},styles:{type:"object"},noOfFiltersPerRow:{type:"number"},graphType:{type:"string",enum:["dataTable","dataCards"]},uiMode:{type:"string",enum:["light","normal"]},dataTransform:d(e),dataFilters:s(e),noOfColumns:{type:"number"},columnGridBy:{type:"string"},showCommonColorScale:{type:"boolean"},minGraphHeight:{type:"number"},minGraphWidth:{type:"number"},readableHeader:c(e),dataSelectionOptions:g(e),advancedDataSelectionOptions:u(e,t),debugMode:{type:"boolean"},theme:{type:"string",enum:["dark","light"]}},required:["columnGridBy","dataSettings","graphType"]}:{type:"object",properties:{graphSettings:a,dataSettings:o(e),filters:p(e),classNames:{type:"object"},styles:{type:"object"},noOfFiltersPerRow:{type:"number"},graphType:{type:"string",enum:i.graphList.filter(r=>r.availableInGriddedGraph!==!1).map(r=>r.graphID)},uiMode:{type:"string",enum:["light","normal"]},dataTransform:d(e),dataFilters:s(e),graphDataConfiguration:h(e,t),noOfColumns:{type:"number"},columnGridBy:{type:"string"},showCommonColorScale:{type:"boolean"},minGraphHeight:{type:"number"},minGraphWidth:{type:"number"},readableHeader:c(e),dataSelectionOptions:g(e),advancedDataSelectionOptions:u(e,t),debugMode:{type:"boolean"},theme:{type:"string",enum:["dark","light"]}},required:t?["columnGridBy","dataSettings","graphType","graphDataConfiguration"]:["columnGridBy","dataSettings","graphType"]}},M=async e=>{const t=await l("allGraphs");return{properties:{dashboardID:{type:"string"},graphClassNames:{type:"object"},graphStyles:{type:"object"},dashboardLayout:{properties:{backgroundColor:{type:["string","boolean"]},description:{type:"string"},language:{enum:["ar","en","he"],type:"string"},padding:{type:"string"},title:{type:"string"},rows:{items:{properties:{columns:{items:{properties:{columnWidth:{type:"number"},dataFilters:s(),dataTransform:d(),graphDataConfiguration:h(void 0,"dashboard"),graphType:{enum:i.graphList.map(a=>a.graphID),type:"string"},settings:t,dataSelectionOptions:g(),advancedDataSelectionOptions:u(),attachedFilter:{type:"string",...n(e)}},type:"object",required:["graphType"]},type:"array"},height:{type:"number"}},type:"object",required:["columns"]},type:"array"}},type:"object",required:["rows"]},dataSettings:o(e),filters:p(e),noOfFiltersPerRow:{type:"number"},uiMode:{type:"string",enum:["light","normal"]},filterPosition:{type:"string",enum:["top","side"]},readableHeader:c(e),dataFilters:s(e),debugMode:{type:"boolean"},theme:{type:"string",enum:["dark","light"]},graphBackgroundColor:{oneOf:[{type:"string"},{type:"boolean"}]}},type:"object",required:["dashboardLayout","dataSettings"]}},w=async()=>{const e=await l("allGraphs");return{properties:{dashboardID:{type:"string"},graphClassNames:{type:"object"},graphStyles:{type:"object"},dashboardLayout:{properties:{backgroundColor:{type:["string","boolean"]},description:{type:"string"},language:{enum:["ar","en","he"],type:"string"},padding:{type:"string"},dropdownLabel:{type:"string"},title:{type:"string"},rows:{items:{properties:{columns:{items:{properties:{columnWidth:{type:"number"},dataFilters:s(),graphDataConfiguration:h(void 0,"dashboardWideToLong"),graphType:{enum:i.graphList.filter(t=>t.availableInWideToLongFormat).map(t=>t.graphID),type:"string"},settings:e},type:"object",required:["graphType"]},type:"array"},height:{type:"number"}},type:"object",required:["columns"]},type:"array"}},type:"object",required:["rows"]},dataSettings:{properties:{...o().properties,keyColumn:{type:"string"}},required:["keyColumn"],type:"object"},uiMode:{type:"string",enum:["light","normal"]},dataFilters:s(),readableHeader:c(),debugMode:{type:"boolean"},theme:{type:"string",enum:["dark","light"]},graphBackgroundColor:{oneOf:[{type:"string"},{type:"boolean"}]}},type:"object",required:["dashboardLayout","dataSettings"]}};exports.getAdvancedDataSelectionSchema=u;exports.getColumnsToArraySchema=m;exports.getDashboardJSONSchema=M;exports.getDashboardWideToLongFormatJSONSchema=w;exports.getDataFiltersSchema=s;exports.getDataSchema=j;exports.getDataSchemaLink=S;exports.getDataSelectionSchema=g;exports.getDataSettingsSchema=o;exports.getDataTransformSchema=d;exports.getFiltersSchema=p;exports.getGraphConfigChartConfigIdEnum=C;exports.getGraphDataConfigurationSchema=h;exports.getGriddedGraphJSONSchema=D;exports.getReadableHeaderSchema=c;exports.getSettingsSchema=l;exports.getSettingsSchemaLink=b;exports.getSingleGraphJSONSchema=f;
|
|
2
|
-
//# sourceMappingURL=getSchema.cjs.map
|
package/dist/getSchema.cjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"getSchema.cjs","sources":["../src/Schemas/getSchema.ts"],"sourcesContent":["import { GeoHubGraphType, GraphType, ThreeDGraphType } from '@/Types';\r\nimport { graphList } from '@/Utils/getGraphList';\r\n\r\nconst BASE_URL =\r\n 'https://raw.githubusercontent.com/UNDP-Data/undp-viz-library-schemas/refs/heads/main/';\r\n\r\nexport function getDataSchemaLink(graph: GraphType | ThreeDGraphType | GeoHubGraphType) {\r\n if (\r\n graphList\r\n .filter(el => el.geoHubMapPresentation)\r\n .map(el => el.graphID)\r\n .indexOf(graph) !== -1\r\n )\r\n return null;\r\n\r\n switch (graph) {\r\n case 'dataTable':\r\n return 'dataSchema/dataTableDataSchema.json';\r\n case 'dataCards':\r\n return 'dataSchema/dataTableDataSchema.json';\r\n case 'barChart':\r\n return 'dataSchema/barGraphDataSchema.json';\r\n case 'stackedBarChart':\r\n return 'dataSchema/stackedBarGraphDataSchema.json';\r\n case 'groupedBarChart':\r\n return 'dataSchema/groupedBarGraphDataSchema.json';\r\n case 'lineChart':\r\n return 'dataSchema/lineChartDataSchema.json';\r\n case 'dualAxisLineChart':\r\n return 'dataSchema/dualAxisLineChartDataSchema.json';\r\n case 'differenceLineChart':\r\n return 'dataSchema/differenceLineChartDataSchema.json';\r\n case 'multiLineChart':\r\n return 'dataSchema/multiLineChartDataSchema.json';\r\n case 'multiLineAltChart':\r\n return 'dataSchema/multiLineAltChartDataSchema.json';\r\n case 'stackedAreaChart':\r\n return 'dataSchema/areaChartDataSchema.json';\r\n case 'choroplethMap':\r\n return 'dataSchema/choroplethMapDataSchema.json';\r\n case 'threeDGlobe':\r\n return 'dataSchema/choroplethMapDataSchema.json';\r\n case 'bulletChart':\r\n return 'dataSchema/bulletChartDataSchema.json';\r\n case 'biVariateChoroplethMap':\r\n return 'dataSchema/biVariateChoroplethMapDataSchema.json';\r\n case 'dotDensityMap':\r\n return 'dataSchema/dotDensityMapDataSchema.json';\r\n case 'donutChart':\r\n return 'dataSchema/donutChartDataSchema.json';\r\n case 'slopeChart':\r\n return 'dataSchema/slopeChartDataSchema.json';\r\n case 'scatterPlot':\r\n return 'dataSchema/scatterPlotDataSchema.json';\r\n case 'dumbbellChart':\r\n return 'dataSchema/dumbbellChartDataSchema.json';\r\n case 'treeMap':\r\n return 'dataSchema/treeMapDataSchema.json';\r\n case 'circlePacking':\r\n return 'dataSchema/circlePackingDataSchema.json';\r\n case 'heatMap':\r\n return 'dataSchema/heatMapDataSchema.json';\r\n case 'stripChart':\r\n return 'dataSchema/stripChartDataSchema.json';\r\n case 'beeSwarmChart':\r\n return 'dataSchema/beeSwarmChartDataSchema.json';\r\n case 'butterflyChart':\r\n return 'dataSchema/butterflyChartDataSchema.json';\r\n case 'histogram':\r\n return 'dataSchema/histogramDataSchema.json';\r\n case 'sparkLine':\r\n return 'dataSchema/lineChartDataSchema.json';\r\n case 'paretoChart':\r\n return 'dataSchema/paretoChartDataSchema.json';\r\n case 'statCard':\r\n return 'dataSchema/statCardDataSchema.json';\r\n case 'unitChart':\r\n return 'dataSchema/unitChartDataSchema.json';\r\n case 'sankeyChart':\r\n return 'dataSchema/sankeyChartDataSchema.json';\r\n case 'lineChartWithConfidenceInterval':\r\n return 'dataSchema/lineChartWithConfidenceIntervalDataSchema.json';\r\n case 'hybridMap':\r\n return 'dataSchema/hybridMapDataSchema.json';\r\n case 'radarChart':\r\n return 'dataSchema/radarChartDataSchema.json';\r\n case 'waterfallChart':\r\n return 'dataSchema/waterfallChartDataSchema.json';\r\n default:\r\n console.error('Unknown chart type:', graph);\r\n return null;\r\n }\r\n}\r\n\r\nexport function getSettingsSchemaLink(\r\n graph: GraphType | ThreeDGraphType | GeoHubGraphType | 'allGraphs',\r\n) {\r\n switch (graph) {\r\n case 'barChart':\r\n return 'settingsSchema/simpleBarChartSettingsSchema.json';\r\n case 'stackedBarChart':\r\n return 'settingsSchema/stackedBarChartSettingsSchema.json';\r\n case 'groupedBarChart':\r\n return 'settingsSchema/groupedBarChartSettingsSchema.json';\r\n case 'lineChart':\r\n return 'settingsSchema/lineChartSettingsSchema.json';\r\n case 'dualAxisLineChart':\r\n return 'settingsSchema/dualAxisLineChartSettingsSchema.json';\r\n case 'multiLineChart':\r\n return 'settingsSchema/multiLineChartSettingsSchema.json';\r\n case 'multiLineAltChart':\r\n return 'settingsSchema/multiLineAltChartSettingsSchema.json';\r\n case 'differenceLineChart':\r\n return 'settingsSchema/differenceLineChartSettingsSchema.json';\r\n case 'stackedAreaChart':\r\n return 'settingsSchema/stackedAreaChartSettingsSchema.json';\r\n case 'choroplethMap':\r\n return 'settingsSchema/choroplethMapSettingsSchema.json';\r\n case 'threeDGlobe':\r\n return 'settingsSchema/threeDGlobeSettingsSchema.json';\r\n case 'bulletChart':\r\n return 'settingsSchema/bulletChartSettingsSchema.json';\r\n case 'biVariateChoroplethMap':\r\n return 'settingsSchema/biVariateChoroplethMapSettingsSchema.json';\r\n case 'dotDensityMap':\r\n return 'settingsSchema/dotDensityMapSettingsSchema.json';\r\n case 'donutChart':\r\n return 'settingsSchema/donutChartSettingsSchema.json';\r\n case 'slopeChart':\r\n return 'settingsSchema/slopeChartSettingsSchema.json';\r\n case 'scatterPlot':\r\n return 'settingsSchema/scatterPlotSettingsSchema.json';\r\n case 'dumbbellChart':\r\n return 'settingsSchema/dumbbellChartSettingsSchema.json';\r\n case 'treeMap':\r\n return 'settingsSchema/treeMapSettingsSchema.json';\r\n case 'circlePacking':\r\n return 'settingsSchema/circlePackingSettingsSchema.json';\r\n case 'heatMap':\r\n return 'settingsSchema/heatMapSettingsSchema.json';\r\n case 'stripChart':\r\n return 'settingsSchema/stripChartSettingsSchema.json';\r\n case 'beeSwarmChart':\r\n return 'settingsSchema/beeSwarmChartSettingsSchema.json';\r\n case 'butterflyChart':\r\n return 'settingsSchema/butterflyChartSettingsSchema.json';\r\n case 'histogram':\r\n return 'settingsSchema/histogramSettingsSchema.json';\r\n case 'sparkLine':\r\n return 'settingsSchema/sparkLineSettingsSchema.json';\r\n case 'paretoChart':\r\n return 'settingsSchema/paretoChartSettingsSchema.json';\r\n case 'dataTable':\r\n return 'settingsSchema/dataTableSettingsSchema.json';\r\n case 'statCard':\r\n return 'settingsSchema/statCardSettingsSchema.json';\r\n case 'geoHubCompareMap':\r\n return 'settingsSchema/geoHubCompareMapSettingsSchema.json';\r\n case 'geoHubMap':\r\n return 'settingsSchema/geoHubMapSettingsSchema.json';\r\n case 'geoHubMapWithLayerSelection':\r\n return 'settingsSchema/geoHubMapWithLayerSelectionSettingsSchema.json';\r\n case 'unitChart':\r\n return 'settingsSchema/unitChartSettingsSchema.json';\r\n case 'sankeyChart':\r\n return 'settingsSchema/sankeyChartSettingsSchema.json';\r\n case 'lineChartWithConfidenceInterval':\r\n return 'settingsSchema/lineChartWithConfidenceIntervalSettingsSchema.json';\r\n case 'dataCards':\r\n return 'settingsSchema/dataCardListSettingsSchema.json';\r\n case 'allGraphs':\r\n return 'settingsSchema/SettingsSchema.json';\r\n case 'radarChart':\r\n return 'settingsSchema/radarChartSettingsSchema.json';\r\n case 'hybridMap':\r\n return 'settingsSchema/hybridMapSettingsSchema.json';\r\n case 'waterfallChart':\r\n return 'settingsSchema/waterfallChartSettingsSchema.json';\r\n default:\r\n console.error('Unknown chart type:', graph);\r\n return null;\r\n }\r\n}\r\n\r\nexport async function getDataSchema(graph: GraphType) {\r\n const response = await fetch(`${BASE_URL}${getDataSchemaLink(graph)}`);\r\n if (!response.ok) {\r\n throw new Error(`Response status: ${response.status}`);\r\n }\r\n const json = await response.json();\r\n return json;\r\n}\r\n\r\nexport async function getSettingsSchema(graph: GraphType | 'allGraphs') {\r\n const response = await fetch(`${BASE_URL}${getSettingsSchemaLink(graph)}`);\r\n if (!response.ok) {\r\n throw new Error(`Response status: ${response.status}`);\r\n }\r\n const json = await response.json();\r\n return json;\r\n}\r\n\r\nexport function getGraphConfigChartConfigIdEnum(\r\n chartType?: GraphType | ThreeDGraphType | 'dashboardWideToLong' | 'dashboard',\r\n) {\r\n switch (chartType) {\r\n case 'barChart':\r\n return ['label', 'size', 'color', 'date'];\r\n case 'waterfallChart':\r\n return ['label', 'size', 'color'];\r\n case 'hybridMap':\r\n return ['lat', 'long', 'x', 'id', 'radius', 'label', 'date'];\r\n case 'bulletChart':\r\n return ['label', 'size', 'target', 'qualitativeRange', 'date'];\r\n case 'treeMap':\r\n return ['label', 'size', 'color'];\r\n case 'circlePacking':\r\n return ['label', 'size', 'color'];\r\n case 'butterflyChart':\r\n return ['label', 'leftBar', 'rightBar', 'date'];\r\n case 'groupedBarChart':\r\n return ['label', 'size', 'date'];\r\n case 'stackedBarChart':\r\n return ['label', 'size', 'date'];\r\n case 'dumbbellChart':\r\n return ['x', 'label', 'date'];\r\n case 'donutChart':\r\n return ['size', 'label'];\r\n case 'histogram':\r\n return ['value'];\r\n case 'choroplethMap':\r\n return ['x', 'id', 'date'];\r\n case 'threeDGlobe':\r\n return ['x', 'id'];\r\n case 'biVariateChoroplethMap':\r\n return ['x', 'y', 'id', 'date'];\r\n case 'lineChart':\r\n return ['date', 'y'];\r\n case 'multiLineChart':\r\n return ['date', 'y'];\r\n case 'multiLineAltChart':\r\n return ['date', 'y', 'label', 'color'];\r\n case 'radarChart':\r\n return ['values', 'label', 'color'];\r\n case 'stackedAreaChart':\r\n return ['date', 'y'];\r\n case 'scatterPlot':\r\n return ['x', 'y', 'radius', 'color', 'label', 'date'];\r\n case 'dualAxisLineChart':\r\n return ['date', 'y1', 'y2'];\r\n case 'paretoChart':\r\n return ['label', 'bar', 'line'];\r\n case 'dotDensityMap':\r\n return ['lat', 'long', 'radius', 'color', 'label', 'date'];\r\n case 'slopeChart':\r\n return ['y1', 'y2', 'color', 'label'];\r\n case 'heatMap':\r\n return ['row', 'column', 'value'];\r\n case 'beeSwarmChart':\r\n return ['label', 'position', 'radius', 'color'];\r\n case 'stripChart':\r\n return ['label', 'position', 'color'];\r\n case 'statCard':\r\n return ['value'];\r\n case 'sankeyChart':\r\n return ['source', 'target', 'value'];\r\n case 'differenceLineChart':\r\n return ['date', 'y1', 'y2'];\r\n case 'unitChart':\r\n return ['label', 'value'];\r\n case 'sparkLine':\r\n return ['date', 'y'];\r\n case 'lineChartWithConfidenceInterval':\r\n return ['date', 'y', 'yMin', 'yMax'];\r\n case 'dashboardWideToLong':\r\n return ['label', 'size', 'color', 'value'];\r\n case 'dashboard':\r\n return [\r\n 'label',\r\n 'radius',\r\n 'size',\r\n 'row',\r\n 'y1',\r\n 'y',\r\n 'rightBar',\r\n 'position',\r\n 'leftBar',\r\n 'x',\r\n 'bar',\r\n 'line',\r\n 'y2',\r\n 'column',\r\n 'date',\r\n 'value',\r\n 'color',\r\n 'long',\r\n 'lat',\r\n 'id',\r\n 'source',\r\n 'target',\r\n 'yMin',\r\n 'yMax',\r\n ];\r\n default:\r\n return [\r\n 'label',\r\n 'radius',\r\n 'size',\r\n 'row',\r\n 'y1',\r\n 'y',\r\n 'rightBar',\r\n 'position',\r\n 'leftBar',\r\n 'x',\r\n 'bar',\r\n 'line',\r\n 'y2',\r\n 'column',\r\n 'date',\r\n 'value',\r\n 'color',\r\n 'long',\r\n 'lat',\r\n 'id',\r\n 'source',\r\n 'target',\r\n 'yMin',\r\n 'yMax',\r\n ];\r\n }\r\n}\r\n\r\nfunction getColumnEnum(columns?: string[]) {\r\n if (!columns || columns.length === 0) return {};\r\n return { enum: columns };\r\n}\r\nexport const getColumnsToArraySchema = (columnList?: string[]) => ({\r\n items: {\r\n properties: {\r\n column: {\r\n type: 'string',\r\n ...getColumnEnum(columnList),\r\n },\r\n delimiter: { type: 'string' },\r\n },\r\n type: 'object',\r\n required: ['column'],\r\n },\r\n type: 'array',\r\n});\r\n\r\nexport const getDataSettingsSchema = (columnList?: string[]) => ({\r\n properties: {\r\n columnsToArray: getColumnsToArraySchema(columnList),\r\n data: {},\r\n dataURL: {\r\n oneOf: [\r\n { type: 'string' },\r\n {\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n fileType: {\r\n enum: ['csv', 'json', 'api'],\r\n type: 'string',\r\n },\r\n apiHeaders: {},\r\n dataTransformation: { type: 'string' },\r\n idColumnName: { type: 'string' },\r\n dataURL: { type: 'string' },\r\n delimiter: { type: 'string' },\r\n columnsToArray: getColumnsToArraySchema(),\r\n },\r\n required: ['dataURL', 'idColumnName'],\r\n },\r\n },\r\n ],\r\n },\r\n delimiter: { type: 'string' },\r\n fileType: {\r\n enum: ['csv', 'json', 'api'],\r\n type: 'string',\r\n },\r\n apiHeaders: {},\r\n dataTransformation: { type: 'string' },\r\n idColumnTitle: { type: 'string' },\r\n },\r\n type: 'object',\r\n});\r\n\r\nexport const getReadableHeaderSchema = (columnList?: string[]) => ({\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n value: { type: 'string', ...getColumnEnum(columnList) },\r\n label: { type: 'string' },\r\n },\r\n required: ['value', 'label'],\r\n },\r\n});\r\n\r\nexport const getFiltersSchema = (columnList?: string[]) => ({\r\n items: {\r\n properties: {\r\n clearable: { type: 'boolean' },\r\n allowSelectAll: { type: 'boolean' },\r\n width: { type: 'string' },\r\n excludeValues: {\r\n items: { type: 'string' },\r\n type: 'array',\r\n },\r\n column: {\r\n type: 'string',\r\n ...getColumnEnum(columnList),\r\n },\r\n defaultValue: {\r\n anyOf: [\r\n {\r\n items: { oneOf: [{ type: 'string' }, { type: 'number' }] },\r\n type: 'array',\r\n },\r\n { type: 'string' },\r\n { type: 'number' },\r\n ],\r\n },\r\n label: { type: 'string' },\r\n ui: { type: 'string', enum: ['select', 'radio'] },\r\n singleSelect: { type: 'boolean' },\r\n },\r\n required: ['column'],\r\n type: 'object',\r\n },\r\n type: 'array',\r\n});\r\n\r\nexport const getDataSelectionSchema = async (columnList?: string[]) => {\r\n const settingsSchema = await getSettingsSchema('allGraphs');\r\n return {\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n chartConfigId: { type: 'string' },\r\n label: { type: 'string' },\r\n width: { type: 'string' },\r\n allowedColumnIds: {\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n value: { type: 'string', ...getColumnEnum(columnList) },\r\n label: { type: 'string' },\r\n graphSettings: settingsSchema,\r\n },\r\n required: ['value', 'label'],\r\n },\r\n minItems: 1,\r\n },\r\n ui: { type: 'string', enum: ['select', 'radio'] },\r\n },\r\n required: ['chartConfigId', 'allowedColumnIds'],\r\n },\r\n };\r\n};\r\n\r\nexport const getDataFiltersSchema = (columnList?: string[]) => ({\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n column: { type: 'string', ...getColumnEnum(columnList) },\r\n includeValues: {\r\n type: 'array',\r\n items: {\r\n oneOf: [{ type: 'string' }, { type: 'number' }, { type: 'boolean' }, { type: 'null' }],\r\n },\r\n },\r\n excludeValues: {\r\n type: 'array',\r\n items: {\r\n oneOf: [{ type: 'string' }, { type: 'number' }, { type: 'boolean' }, { type: 'null' }],\r\n },\r\n },\r\n },\r\n required: ['column'],\r\n },\r\n});\r\n\r\nexport const getDataTransformSchema = (columnList?: string[]) => ({\r\n type: 'object',\r\n properties: {\r\n keyColumn: { type: 'string', ...getColumnEnum(columnList) },\r\n aggregationColumnsSetting: {\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n column: { type: 'string', ...getColumnEnum(columnList) },\r\n aggregationMethod: {\r\n type: 'string',\r\n enum: ['sum', 'average', 'min', 'max'],\r\n },\r\n },\r\n required: ['column'],\r\n },\r\n },\r\n },\r\n required: ['keyColumn'],\r\n});\r\n\r\nexport const getGraphDataConfigurationSchema = (\r\n columnList?: string[],\r\n graphType?: GraphType | 'dashboard' | 'dashboardWideToLong',\r\n) => ({\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n columnId: {\r\n oneOf: [\r\n { type: 'string', ...getColumnEnum(columnList) },\r\n {\r\n type: 'array',\r\n items: { type: 'string', ...getColumnEnum(columnList) },\r\n },\r\n ],\r\n },\r\n chartConfigId: {\r\n type: 'string',\r\n ...getColumnEnum(getGraphConfigChartConfigIdEnum(graphType)),\r\n },\r\n },\r\n required: ['columnId', 'chartConfigId'],\r\n },\r\n});\r\n\r\nexport const getAdvancedDataSelectionSchema = async (\r\n columnList?: string[],\r\n graphType?: GraphType,\r\n) => {\r\n const settingsSchema = await getSettingsSchema('allGraphs');\r\n return {\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n chartConfigId: { type: 'string' },\r\n label: { type: 'string' },\r\n width: { type: 'string' },\r\n options: {\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n dataConfiguration: getGraphDataConfigurationSchema(columnList, graphType),\r\n label: { type: 'string' },\r\n graphSettings: settingsSchema,\r\n },\r\n required: ['dataConfiguration', 'label'],\r\n },\r\n minItems: 1,\r\n },\r\n defaultValue: {\r\n type: 'array',\r\n items: {\r\n type: 'object',\r\n properties: {\r\n dataConfiguration: getGraphDataConfigurationSchema(columnList, graphType),\r\n label: { type: 'string' },\r\n graphSettings: settingsSchema,\r\n },\r\n required: ['dataConfiguration', 'label'],\r\n },\r\n minItems: 1,\r\n },\r\n ui: { type: 'string', enum: ['select', 'radio'] },\r\n },\r\n required: ['chartConfigId', 'options'],\r\n },\r\n };\r\n};\r\n\r\nexport const getSingleGraphJSONSchema = async (columnList?: string[], graphType?: GraphType) => {\r\n const settingsSchema = await getSettingsSchema(graphType || 'allGraphs');\r\n if (\r\n graphType &&\r\n graphList\r\n .filter(el => el.geoHubMapPresentation)\r\n .map(el => el.graphID)\r\n .indexOf(graphType) !== -1\r\n )\r\n return {\r\n type: 'object',\r\n properties: {\r\n graphSettings: settingsSchema,\r\n graphType: {\r\n type: 'string',\r\n enum: graphList.filter(el => el.geoHubMapPresentation).map(el => el.graphID),\r\n },\r\n debugMode: { type: 'boolean' },\r\n theme: { type: 'string', enum: ['dark', 'light'] },\r\n uiMode: {\r\n type: 'string',\r\n enum: ['light', 'normal'],\r\n },\r\n classNames: { type: 'object' },\r\n highlightDataPointSettings: {\r\n type: 'object',\r\n properties: {\r\n column: { type: 'string' },\r\n label: { type: 'string' },\r\n defaultValues: {\r\n oneOf: [\r\n {\r\n type: 'array',\r\n items: { type: 'string' },\r\n },\r\n {\r\n type: 'array',\r\n items: { type: 'number' },\r\n },\r\n ],\r\n },\r\n excludeValues: {\r\n type: 'array',\r\n items: { type: 'string' },\r\n },\r\n allowSelectAll: { type: 'boolean' },\r\n width: { type: 'string' },\r\n },\r\n required: ['column'],\r\n },\r\n styles: { type: 'object' },\r\n },\r\n required: ['graphType'],\r\n };\r\n if (graphType === 'dataTable' || graphType === 'dataCards')\r\n return {\r\n type: 'object',\r\n properties: {\r\n graphSettings: settingsSchema,\r\n dataSettings: getDataSettingsSchema(columnList),\r\n filters: getFiltersSchema(columnList),\r\n noOfFiltersPerRow: { type: 'number' },\r\n graphType: {\r\n type: 'string',\r\n enum: ['dataTable', 'dataCards'],\r\n },\r\n dataTransform: getDataTransformSchema(columnList),\r\n dataFilters: getDataFiltersSchema(columnList),\r\n readableHeader: getReadableHeaderSchema(columnList),\r\n dataSelectionOptions: getDataSelectionSchema(columnList),\r\n advancedDataSelectionOptions: getAdvancedDataSelectionSchema(columnList, graphType),\r\n debugMode: { type: 'boolean' },\r\n theme: { type: 'string', enum: ['dark', 'light'] },\r\n uiMode: {\r\n type: 'string',\r\n enum: ['light', 'normal'],\r\n },\r\n classNames: { type: 'object' },\r\n highlightDataPointSettings: {\r\n type: 'object',\r\n properties: {\r\n column: { type: 'string' },\r\n label: { type: 'string' },\r\n defaultValues: {\r\n oneOf: [\r\n {\r\n type: 'array',\r\n items: { type: 'string' },\r\n },\r\n {\r\n type: 'array',\r\n items: { type: 'number' },\r\n },\r\n ],\r\n },\r\n excludeValues: {\r\n type: 'array',\r\n items: { type: 'string' },\r\n },\r\n allowSelectAll: { type: 'boolean' },\r\n width: { type: 'string' },\r\n },\r\n required: ['column'],\r\n },\r\n styles: { type: 'object' },\r\n },\r\n required: ['dataSettings', 'graphType'],\r\n };\r\n return {\r\n type: 'object',\r\n properties: {\r\n graphSettings: settingsSchema,\r\n dataSettings: getDataSettingsSchema(columnList),\r\n filters: getFiltersSchema(columnList),\r\n classNames: { type: 'object' },\r\n styles: { type: 'object' },\r\n graphType: {\r\n type: 'string',\r\n enum: graphList.map(el => el.graphID),\r\n },\r\n noOfFiltersPerRow: { type: 'number' },\r\n dataTransform: getDataTransformSchema(columnList),\r\n dataFilters: getDataFiltersSchema(columnList),\r\n graphDataConfiguration: getGraphDataConfigurationSchema(columnList, graphType),\r\n readableHeader: getReadableHeaderSchema(columnList),\r\n dataSelectionOptions: getDataSelectionSchema(columnList),\r\n advancedDataSelectionOptions: getAdvancedDataSelectionSchema(columnList, graphType),\r\n debugMode: { type: 'boolean' },\r\n theme: { type: 'string', enum: ['dark', 'light'] },\r\n highlightDataPointSettings: {\r\n type: 'object',\r\n properties: {\r\n column: { type: 'string' },\r\n label: { type: 'string' },\r\n defaultValues: {\r\n oneOf: [\r\n {\r\n type: 'array',\r\n items: { type: 'string' },\r\n },\r\n {\r\n type: 'array',\r\n items: { type: 'number' },\r\n },\r\n ],\r\n },\r\n excludeValues: {\r\n type: 'array',\r\n items: { type: 'string' },\r\n },\r\n allowSelectAll: { type: 'boolean' },\r\n width: { type: 'string' },\r\n },\r\n required: ['column'],\r\n },\r\n uiMode: {\r\n type: 'string',\r\n enum: ['light', 'normal'],\r\n },\r\n },\r\n required: !graphType ? ['graphType'] : ['dataSettings', 'graphType', 'graphDataConfiguration'],\r\n };\r\n};\r\n\r\nexport const getGriddedGraphJSONSchema = async (columnList?: string[], graphType?: GraphType) => {\r\n const settingsSchema = await getSettingsSchema(graphType || 'allGraphs');\r\n if (graphType === 'dataTable' || graphType === 'dataCards')\r\n return {\r\n type: 'object',\r\n properties: {\r\n graphSettings: settingsSchema,\r\n dataSettings: getDataSettingsSchema(columnList),\r\n filters: getFiltersSchema(columnList),\r\n classNames: { type: 'object' },\r\n styles: { type: 'object' },\r\n noOfFiltersPerRow: { type: 'number' },\r\n graphType: {\r\n type: 'string',\r\n enum: ['dataTable', 'dataCards'],\r\n },\r\n uiMode: {\r\n type: 'string',\r\n enum: ['light', 'normal'],\r\n },\r\n dataTransform: getDataTransformSchema(columnList),\r\n dataFilters: getDataFiltersSchema(columnList),\r\n noOfColumns: { type: 'number' },\r\n columnGridBy: { type: 'string' },\r\n showCommonColorScale: { type: 'boolean' },\r\n minGraphHeight: { type: 'number' },\r\n minGraphWidth: { type: 'number' },\r\n readableHeader: getReadableHeaderSchema(columnList),\r\n dataSelectionOptions: getDataSelectionSchema(columnList),\r\n advancedDataSelectionOptions: getAdvancedDataSelectionSchema(columnList, graphType),\r\n debugMode: { type: 'boolean' },\r\n theme: { type: 'string', enum: ['dark', 'light'] },\r\n },\r\n required: ['columnGridBy', 'dataSettings', 'graphType'],\r\n };\r\n return {\r\n type: 'object',\r\n properties: {\r\n graphSettings: settingsSchema,\r\n dataSettings: getDataSettingsSchema(columnList),\r\n filters: getFiltersSchema(columnList),\r\n classNames: { type: 'object' },\r\n styles: { type: 'object' },\r\n noOfFiltersPerRow: { type: 'number' },\r\n graphType: {\r\n type: 'string',\r\n enum: graphList.filter(el => el.availableInGriddedGraph !== false).map(el => el.graphID),\r\n },\r\n uiMode: {\r\n type: 'string',\r\n enum: ['light', 'normal'],\r\n },\r\n dataTransform: getDataTransformSchema(columnList),\r\n dataFilters: getDataFiltersSchema(columnList),\r\n graphDataConfiguration: getGraphDataConfigurationSchema(columnList, graphType),\r\n noOfColumns: { type: 'number' },\r\n columnGridBy: { type: 'string' },\r\n showCommonColorScale: { type: 'boolean' },\r\n minGraphHeight: { type: 'number' },\r\n minGraphWidth: { type: 'number' },\r\n readableHeader: getReadableHeaderSchema(columnList),\r\n dataSelectionOptions: getDataSelectionSchema(columnList),\r\n advancedDataSelectionOptions: getAdvancedDataSelectionSchema(columnList, graphType),\r\n debugMode: { type: 'boolean' },\r\n theme: { type: 'string', enum: ['dark', 'light'] },\r\n },\r\n required: !graphType\r\n ? ['columnGridBy', 'dataSettings', 'graphType']\r\n : ['columnGridBy', 'dataSettings', 'graphType', 'graphDataConfiguration'],\r\n };\r\n};\r\n\r\nexport const getDashboardJSONSchema = async (columnList?: string[]) => {\r\n const settingsSchema = await getSettingsSchema('allGraphs');\r\n return {\r\n properties: {\r\n dashboardID: { type: 'string' },\r\n graphClassNames: { type: 'object' },\r\n graphStyles: { type: 'object' },\r\n dashboardLayout: {\r\n properties: {\r\n backgroundColor: { type: ['string', 'boolean'] },\r\n description: { type: 'string' },\r\n language: {\r\n enum: ['ar', 'en', 'he'],\r\n type: 'string',\r\n },\r\n padding: { type: 'string' },\r\n title: { type: 'string' },\r\n rows: {\r\n items: {\r\n properties: {\r\n columns: {\r\n items: {\r\n properties: {\r\n columnWidth: { type: 'number' },\r\n dataFilters: getDataFiltersSchema(),\r\n dataTransform: getDataTransformSchema(),\r\n graphDataConfiguration: getGraphDataConfigurationSchema(\r\n undefined,\r\n 'dashboard',\r\n ),\r\n graphType: {\r\n enum: graphList.map(el => el.graphID),\r\n type: 'string',\r\n },\r\n settings: settingsSchema,\r\n dataSelectionOptions: getDataSelectionSchema(),\r\n advancedDataSelectionOptions: getAdvancedDataSelectionSchema(),\r\n attachedFilter: {\r\n type: 'string',\r\n ...getColumnEnum(columnList),\r\n },\r\n },\r\n type: 'object',\r\n required: ['graphType'],\r\n },\r\n type: 'array',\r\n },\r\n height: { type: 'number' },\r\n },\r\n type: 'object',\r\n required: ['columns'],\r\n },\r\n type: 'array',\r\n },\r\n },\r\n type: 'object',\r\n required: ['rows'],\r\n },\r\n dataSettings: getDataSettingsSchema(columnList),\r\n filters: getFiltersSchema(columnList),\r\n noOfFiltersPerRow: { type: 'number' },\r\n uiMode: {\r\n type: 'string',\r\n enum: ['light', 'normal'],\r\n },\r\n filterPosition: { type: 'string', enum: ['top', 'side'] },\r\n readableHeader: getReadableHeaderSchema(columnList),\r\n dataFilters: getDataFiltersSchema(columnList),\r\n debugMode: { type: 'boolean' },\r\n theme: { type: 'string', enum: ['dark', 'light'] },\r\n graphBackgroundColor: { oneOf: [{ type: 'string' }, { type: 'boolean' }] },\r\n },\r\n type: 'object',\r\n required: ['dashboardLayout', 'dataSettings'],\r\n };\r\n};\r\n\r\nexport const getDashboardWideToLongFormatJSONSchema = async () => {\r\n const settingsSchema = await getSettingsSchema('allGraphs');\r\n return {\r\n properties: {\r\n dashboardID: { type: 'string' },\r\n graphClassNames: { type: 'object' },\r\n graphStyles: { type: 'object' },\r\n dashboardLayout: {\r\n properties: {\r\n backgroundColor: { type: ['string', 'boolean'] },\r\n description: { type: 'string' },\r\n language: {\r\n enum: ['ar', 'en', 'he'],\r\n type: 'string',\r\n },\r\n padding: { type: 'string' },\r\n dropdownLabel: { type: 'string' },\r\n title: { type: 'string' },\r\n rows: {\r\n items: {\r\n properties: {\r\n columns: {\r\n items: {\r\n properties: {\r\n columnWidth: { type: 'number' },\r\n dataFilters: getDataFiltersSchema(),\r\n graphDataConfiguration: getGraphDataConfigurationSchema(\r\n undefined,\r\n 'dashboardWideToLong',\r\n ),\r\n graphType: {\r\n enum: graphList\r\n .filter(el => el.availableInWideToLongFormat)\r\n .map(el => el.graphID),\r\n type: 'string',\r\n },\r\n settings: settingsSchema,\r\n },\r\n type: 'object',\r\n required: ['graphType'],\r\n },\r\n type: 'array',\r\n },\r\n height: { type: 'number' },\r\n },\r\n type: 'object',\r\n required: ['columns'],\r\n },\r\n type: 'array',\r\n },\r\n },\r\n type: 'object',\r\n required: ['rows'],\r\n },\r\n dataSettings: {\r\n properties: {\r\n ...getDataSettingsSchema().properties,\r\n keyColumn: { type: 'string' },\r\n },\r\n required: ['keyColumn'],\r\n type: 'object',\r\n },\r\n uiMode: {\r\n type: 'string',\r\n enum: ['light', 'normal'],\r\n },\r\n dataFilters: getDataFiltersSchema(),\r\n readableHeader: getReadableHeaderSchema(),\r\n debugMode: { type: 'boolean' },\r\n theme: { type: 'string', enum: ['dark', 'light'] },\r\n graphBackgroundColor: { oneOf: [{ type: 'string' }, { type: 'boolean' }] },\r\n },\r\n type: 'object',\r\n required: ['dashboardLayout', 'dataSettings'],\r\n };\r\n};\r\n"],"names":["BASE_URL","getDataSchemaLink","graph","graphList","filter","el","geoHubMapPresentation","map","graphID","indexOf","console","error","getSettingsSchemaLink","getDataSchema","response","fetch","ok","Error","status","json","getSettingsSchema","getGraphConfigChartConfigIdEnum","chartType","getColumnEnum","columns","length","enum","getColumnsToArraySchema","columnList","items","properties","column","type","delimiter","required","getDataSettingsSchema","columnsToArray","data","dataURL","oneOf","fileType","apiHeaders","dataTransformation","idColumnName","idColumnTitle","getReadableHeaderSchema","value","label","getFiltersSchema","clearable","allowSelectAll","width","excludeValues","defaultValue","anyOf","ui","singleSelect","getDataSelectionSchema","settingsSchema","chartConfigId","allowedColumnIds","graphSettings","minItems","getDataFiltersSchema","includeValues","getDataTransformSchema","keyColumn","aggregationColumnsSetting","aggregationMethod","getGraphDataConfigurationSchema","graphType","columnId","getAdvancedDataSelectionSchema","options","dataConfiguration","getSingleGraphJSONSchema","debugMode","theme","uiMode","classNames","highlightDataPointSettings","defaultValues","styles","dataSettings","filters","noOfFiltersPerRow","dataTransform","dataFilters","readableHeader","dataSelectionOptions","advancedDataSelectionOptions","graphDataConfiguration","getGriddedGraphJSONSchema","noOfColumns","columnGridBy","showCommonColorScale","minGraphHeight","minGraphWidth","availableInGriddedGraph","getDashboardJSONSchema","dashboardID","graphClassNames","graphStyles","dashboardLayout","backgroundColor","description","language","padding","title","rows","columnWidth","undefined","settings","attachedFilter","height","filterPosition","graphBackgroundColor","getDashboardWideToLongFormatJSONSchema","dropdownLabel","availableInWideToLongFormat"],"mappings":"+HAGMA,EACJ,wFAEK,SAASC,EAAkBC,EAAsD,CACtF,GACEC,EAAAA,UACGC,OAAOC,GAAMA,EAAGC,qBAAqB,EACrCC,IAAIF,GAAMA,EAAGG,OAAO,EACpBC,QAAQP,CAAK,IAAM,GAEtB,OAAO,KAET,OAAQA,EAAAA,CACN,IAAK,YACH,MAAO,sCACT,IAAK,YACH,MAAO,sCACT,IAAK,WACH,MAAO,qCACT,IAAK,kBACH,MAAO,4CACT,IAAK,kBACH,MAAO,4CACT,IAAK,YACH,MAAO,sCACT,IAAK,oBACH,MAAO,8CACT,IAAK,sBACH,MAAO,gDACT,IAAK,iBACH,MAAO,2CACT,IAAK,oBACH,MAAO,8CACT,IAAK,mBACH,MAAO,sCACT,IAAK,gBACH,MAAO,0CACT,IAAK,cACH,MAAO,0CACT,IAAK,cACH,MAAO,wCACT,IAAK,yBACH,MAAO,mDACT,IAAK,gBACH,MAAO,0CACT,IAAK,aACH,MAAO,uCACT,IAAK,aACH,MAAO,uCACT,IAAK,cACH,MAAO,wCACT,IAAK,gBACH,MAAO,0CACT,IAAK,UACH,MAAO,oCACT,IAAK,gBACH,MAAO,0CACT,IAAK,UACH,MAAO,oCACT,IAAK,aACH,MAAO,uCACT,IAAK,gBACH,MAAO,0CACT,IAAK,iBACH,MAAO,2CACT,IAAK,YACH,MAAO,sCACT,IAAK,YACH,MAAO,sCACT,IAAK,cACH,MAAO,wCACT,IAAK,WACH,MAAO,qCACT,IAAK,YACH,MAAO,sCACT,IAAK,cACH,MAAO,wCACT,IAAK,kCACH,MAAO,4DACT,IAAK,YACH,MAAO,sCACT,IAAK,aACH,MAAO,uCACT,IAAK,iBACH,MAAO,2CACT,QACEQ,eAAQC,MAAM,sBAAuBT,CAAK,EACnC,IAAA,CAEb,CAEO,SAASU,EACdV,EACA,CACA,OAAQA,EAAAA,CACN,IAAK,WACH,MAAO,mDACT,IAAK,kBACH,MAAO,oDACT,IAAK,kBACH,MAAO,oDACT,IAAK,YACH,MAAO,8CACT,IAAK,oBACH,MAAO,sDACT,IAAK,iBACH,MAAO,mDACT,IAAK,oBACH,MAAO,sDACT,IAAK,sBACH,MAAO,wDACT,IAAK,mBACH,MAAO,qDACT,IAAK,gBACH,MAAO,kDACT,IAAK,cACH,MAAO,gDACT,IAAK,cACH,MAAO,gDACT,IAAK,yBACH,MAAO,2DACT,IAAK,gBACH,MAAO,kDACT,IAAK,aACH,MAAO,+CACT,IAAK,aACH,MAAO,+CACT,IAAK,cACH,MAAO,gDACT,IAAK,gBACH,MAAO,kDACT,IAAK,UACH,MAAO,4CACT,IAAK,gBACH,MAAO,kDACT,IAAK,UACH,MAAO,4CACT,IAAK,aACH,MAAO,+CACT,IAAK,gBACH,MAAO,kDACT,IAAK,iBACH,MAAO,mDACT,IAAK,YACH,MAAO,8CACT,IAAK,YACH,MAAO,8CACT,IAAK,cACH,MAAO,gDACT,IAAK,YACH,MAAO,8CACT,IAAK,WACH,MAAO,6CACT,IAAK,mBACH,MAAO,qDACT,IAAK,YACH,MAAO,8CACT,IAAK,8BACH,MAAO,gEACT,IAAK,YACH,MA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