@divami-artefacts/ai-design-system 1.0.53 → 1.0.55
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/ai-design-system.css +1 -1
- package/dist/canvas/canvasUtils.d.ts +6 -3
- package/dist/canvas/useCanvasInteraction.d.ts +5 -2
- package/dist/canvas/useContainerWidth.d.ts +1 -0
- package/dist/components/areaLineChart/AreaLineChart.d.ts +1 -1
- package/dist/components/areaLineChart/types.d.ts +1 -1
- package/dist/components/balanceScaleChart/BalanceScaleChart.d.ts +1 -1
- package/dist/components/balanceScaleChart/types.d.ts +5 -2
- package/dist/components/common/ChartEmptyState.d.ts +2 -2
- package/dist/components/common/ToggleButton.d.ts +2 -2
- package/dist/components/dotMatrixChart/DotMatrixChart.d.ts +1 -1
- package/dist/components/dotMatrixChart/types.d.ts +1 -1
- package/dist/components/horizontalBarChart/HorizontalBarChart.d.ts +1 -1
- package/dist/components/horizontalBarChart/types.d.ts +4 -1
- package/dist/components/hubAndSpokeRadialChart/HubAndSpokeRadialChart.d.ts +1 -1
- package/dist/components/hubAndSpokeRadialChart/types.d.ts +1 -1
- package/dist/components/multiMetricConstellationChart/MultiMetricConstellationChart.d.ts +1 -1
- package/dist/components/multiMetricConstellationChart/types.d.ts +1 -1
- package/dist/components/multiSegmentHorizontalBarChart/MultiSegmentHorizontalBarChart.d.ts +1 -1
- package/dist/components/multiSegmentHorizontalBarChart/types.d.ts +1 -1
- package/dist/components/progressRaceChart/ProgressRaceChart.d.ts +1 -1
- package/dist/components/progressRaceChart/types.d.ts +5 -2
- package/dist/components/proportionalBandChart/ProportionalBandChart.d.ts +1 -1
- package/dist/components/proportionalBandChart/types.d.ts +3 -2
- package/dist/components/radialFanTreeChart/RadialFanTreeChart.d.ts +1 -1
- package/dist/components/radialFanTreeChart/types.d.ts +10 -2
- package/dist/components/rankedCardLeaderboard/RankedCardLeaderboard.d.ts +1 -1
- package/dist/components/rankedCardLeaderboard/types.d.ts +3 -2
- package/dist/components/segmentedSplitBarChart/SegmentedSplitBarChart.d.ts +1 -1
- package/dist/components/segmentedSplitBarChart/types.d.ts +5 -2
- package/dist/components/semiCircularGaugeChart/SemiCircularGaugeChart.d.ts +1 -1
- package/dist/components/semiCircularGaugeChart/types.d.ts +11 -1
- package/dist/components/stackedHorizontalBarChart/StackedHorizontalBarChart.d.ts +1 -1
- package/dist/components/stackedHorizontalBarChart/types.d.ts +5 -2
- package/dist/components/trend/Trend.d.ts +1 -1
- package/dist/components/trend/types.d.ts +3 -1
- package/dist/components/visualizationGroup/VisualizationGroup.d.ts +2 -0
- package/dist/components/visualizationRenderer/VisualizationRenderer.d.ts +1 -1
- package/dist/components/weeklyFlow/WeeklyFlow.d.ts +1 -1
- package/dist/components/weeklyFlow/types.d.ts +3 -2
- package/dist/constants.d.ts +37 -0
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +1457 -1018
- package/dist/pages/interactiveDemo/InteractiveDemoPage.d.ts +1 -0
- package/dist/pages/interactiveDemo/styles.d.ts +2 -0
- package/dist/types/index.d.ts +60 -20
- package/package.json +21 -21
- package/dist/components/constants.d.ts +0 -6
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function InteractiveDemoPage(): import("react/jsx-runtime").JSX.Element;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
+
import { CHART_TYPE } from '../constants';
|
|
2
3
|
export type VisualizationFrameProps = {
|
|
3
4
|
className?: string;
|
|
4
5
|
};
|
|
@@ -100,89 +101,121 @@ export type ChartFrameProps = {
|
|
|
100
101
|
className?: string;
|
|
101
102
|
};
|
|
102
103
|
export type BaseVisualizationConfig = {
|
|
103
|
-
type:
|
|
104
|
+
type: typeof CHART_TYPE.LINE | typeof CHART_TYPE.AREA | typeof CHART_TYPE.BAR | typeof CHART_TYPE.PIE | typeof CHART_TYPE.DONUT | typeof CHART_TYPE.SANKEY;
|
|
104
105
|
rows: VizRow[];
|
|
105
106
|
} | {
|
|
106
|
-
type:
|
|
107
|
+
type: typeof CHART_TYPE.FLOW;
|
|
107
108
|
selectedEntity?: string | null;
|
|
108
109
|
} | {
|
|
109
|
-
type:
|
|
110
|
+
type: typeof CHART_TYPE.TREND;
|
|
110
111
|
points: PointPair[];
|
|
111
112
|
} | {
|
|
112
|
-
type:
|
|
113
|
+
type: typeof CHART_TYPE.MINI_BARS;
|
|
113
114
|
rows: MiniBarRow[];
|
|
114
115
|
} | {
|
|
115
|
-
type:
|
|
116
|
+
type: typeof CHART_TYPE.STACKED_HORIZONTAL_BAR;
|
|
116
117
|
data: ContractData;
|
|
117
118
|
items?: never;
|
|
119
|
+
dataByEntity?: Record<string, ContractData>;
|
|
118
120
|
} | {
|
|
119
|
-
type:
|
|
121
|
+
type: typeof CHART_TYPE.STACKED_HORIZONTAL_BAR;
|
|
120
122
|
items: ContractorRow[];
|
|
121
123
|
data?: never;
|
|
124
|
+
dataByEntity?: Record<string, ContractData>;
|
|
122
125
|
} | {
|
|
123
|
-
type:
|
|
126
|
+
type: typeof CHART_TYPE.MULTI_METRIC_CONSTELLATION;
|
|
124
127
|
items: ContractorRow[];
|
|
125
128
|
} | {
|
|
126
|
-
type:
|
|
129
|
+
type: typeof CHART_TYPE.PROGRESS_RACE;
|
|
127
130
|
items: ContractorRow[];
|
|
131
|
+
itemsByEntity?: Record<string, ContractorRow[]>;
|
|
128
132
|
} | {
|
|
129
|
-
type:
|
|
133
|
+
type: typeof CHART_TYPE.HUB_AND_SPOKE_RADIAL;
|
|
130
134
|
segments: EWStatusRow[];
|
|
131
135
|
title?: string;
|
|
132
136
|
unitLabel?: string;
|
|
133
137
|
} | {
|
|
134
|
-
type:
|
|
138
|
+
type: typeof CHART_TYPE.DOT_MATRIX;
|
|
135
139
|
items: EWCategoryRow[];
|
|
136
140
|
title?: string;
|
|
137
141
|
} | {
|
|
138
|
-
type:
|
|
142
|
+
type: typeof CHART_TYPE.RANKED_CARD_LEADERBOARD;
|
|
139
143
|
items: EWOpenContractorRow[];
|
|
140
144
|
title?: string;
|
|
141
145
|
} | {
|
|
142
|
-
type:
|
|
146
|
+
type: typeof CHART_TYPE.PROPORTIONAL_BAND;
|
|
143
147
|
severities: EWSeverityRow[];
|
|
144
148
|
title?: string;
|
|
145
149
|
} | {
|
|
146
|
-
type:
|
|
150
|
+
type: typeof CHART_TYPE.RADIAL_FAN_TREE;
|
|
147
151
|
total: number;
|
|
148
152
|
totalLabel?: string;
|
|
149
153
|
items: NCEContractorRow[];
|
|
154
|
+
dataByEntity?: Record<string, {
|
|
155
|
+
total: number;
|
|
156
|
+
totalLabel?: string;
|
|
157
|
+
items: NCEContractorRow[];
|
|
158
|
+
}>;
|
|
150
159
|
} | {
|
|
151
|
-
type:
|
|
160
|
+
type: typeof CHART_TYPE.SEMI_CIRCULAR_GAUGE;
|
|
152
161
|
confirmed: number;
|
|
153
162
|
total: number;
|
|
154
163
|
label?: string;
|
|
164
|
+
gaugeByEntity?: Record<string, {
|
|
165
|
+
confirmed: number;
|
|
166
|
+
total: number;
|
|
167
|
+
}>;
|
|
168
|
+
subentity?: SubentityItem[];
|
|
155
169
|
} | {
|
|
156
|
-
type:
|
|
170
|
+
type: typeof CHART_TYPE.SEGMENTED_SPLIT_BAR;
|
|
157
171
|
items: VariationRow[];
|
|
158
172
|
labelA?: string;
|
|
159
173
|
labelB?: string;
|
|
160
174
|
unit?: string;
|
|
175
|
+
itemsByEntity?: Record<string, VariationRow[]>;
|
|
161
176
|
} | {
|
|
162
|
-
type:
|
|
177
|
+
type: typeof CHART_TYPE.BALANCE_SCALE;
|
|
163
178
|
left: QuotationSide;
|
|
164
179
|
right: QuotationSide;
|
|
165
180
|
leftTitle?: string;
|
|
166
181
|
rightTitle?: string;
|
|
167
182
|
unit?: string;
|
|
183
|
+
dataByEntity?: Record<string, QuotationSummary>;
|
|
168
184
|
} | {
|
|
169
|
-
type:
|
|
185
|
+
type: typeof CHART_TYPE.AREA_LINE;
|
|
170
186
|
points: QuotationTrendPoint[];
|
|
171
187
|
} | {
|
|
172
|
-
type:
|
|
188
|
+
type: typeof CHART_TYPE.TREND_VIEW;
|
|
173
189
|
points: QuotationTrendPoint[];
|
|
190
|
+
pointsByEntity?: Record<string, QuotationTrendPoint[]>;
|
|
174
191
|
} | {
|
|
175
|
-
type:
|
|
192
|
+
type: typeof CHART_TYPE.WEEKLY_FLOW;
|
|
176
193
|
items: ContractorRow[];
|
|
177
194
|
} | {
|
|
178
|
-
type:
|
|
195
|
+
type: typeof CHART_TYPE.HORIZONTAL_BAR;
|
|
179
196
|
rows: HorizontalBarRow[];
|
|
180
197
|
valuePrefix?: string;
|
|
181
198
|
};
|
|
199
|
+
export type SubentityItem = Record<string, unknown>;
|
|
200
|
+
export type RadialFanSubentity = {
|
|
201
|
+
total: number;
|
|
202
|
+
totalLabel: string;
|
|
203
|
+
items: SubentityItem[];
|
|
204
|
+
};
|
|
205
|
+
export type SubentityPayload = SubentityItem[] | RadialFanSubentity;
|
|
182
206
|
export type VisualizationRendererProps = {
|
|
183
207
|
config: BaseVisualizationConfig;
|
|
184
208
|
className?: string;
|
|
185
209
|
colorOffset?: number;
|
|
210
|
+
onItemClick?: (id: string, label: string, subentity?: SubentityPayload) => void;
|
|
211
|
+
selectedId?: string;
|
|
212
|
+
listenerItems?: SubentityPayload;
|
|
213
|
+
};
|
|
214
|
+
export type VisualizationGroupProps = {
|
|
215
|
+
items: BaseVisualizationConfig[];
|
|
216
|
+
colorOffset?: number;
|
|
217
|
+
title?: string;
|
|
218
|
+
'data-testid'?: string;
|
|
186
219
|
};
|
|
187
220
|
export type ContractorRow = {
|
|
188
221
|
id: string;
|
|
@@ -195,6 +228,7 @@ export type ContractorRow = {
|
|
|
195
228
|
baseLabel?: string;
|
|
196
229
|
variationLabel?: string;
|
|
197
230
|
totalLabel?: string;
|
|
231
|
+
subentity?: SubentityPayload;
|
|
198
232
|
};
|
|
199
233
|
export type ContractData = {
|
|
200
234
|
items: (ContractorRow | number | null)[];
|
|
@@ -216,6 +250,7 @@ export type EWCategoryRow = {
|
|
|
216
250
|
export type EWSeverityRow = {
|
|
217
251
|
severity: string;
|
|
218
252
|
count: number;
|
|
253
|
+
subentity?: SubentityItem[];
|
|
219
254
|
};
|
|
220
255
|
export type EWOpenContractorRow = {
|
|
221
256
|
id: string;
|
|
@@ -223,6 +258,7 @@ export type EWOpenContractorRow = {
|
|
|
223
258
|
abbreviation?: string;
|
|
224
259
|
count?: number;
|
|
225
260
|
label?: string;
|
|
261
|
+
subentity?: SubentityItem[];
|
|
226
262
|
};
|
|
227
263
|
export type NCEContractorRow = {
|
|
228
264
|
id: string;
|
|
@@ -230,6 +266,7 @@ export type NCEContractorRow = {
|
|
|
230
266
|
abbreviation?: string;
|
|
231
267
|
count?: number;
|
|
232
268
|
label?: string;
|
|
269
|
+
subentity?: SubentityItem[];
|
|
233
270
|
};
|
|
234
271
|
export type NCECompensationData = {
|
|
235
272
|
total: number;
|
|
@@ -242,11 +279,13 @@ export type VariationRow = {
|
|
|
242
279
|
abbreviation?: string;
|
|
243
280
|
implemented?: number;
|
|
244
281
|
unimplemented?: number;
|
|
282
|
+
subentity?: SubentityItem[];
|
|
245
283
|
};
|
|
246
284
|
export type QuotationSide = {
|
|
247
285
|
value: number;
|
|
248
286
|
count: number;
|
|
249
287
|
label: string;
|
|
288
|
+
subentity?: SubentityItem[];
|
|
250
289
|
};
|
|
251
290
|
export type QuotationSummary = {
|
|
252
291
|
left: QuotationSide;
|
|
@@ -364,6 +403,7 @@ export type HorizontalBarRow = {
|
|
|
364
403
|
name: string;
|
|
365
404
|
value: number;
|
|
366
405
|
valueLabel?: string;
|
|
406
|
+
subentity?: SubentityItem[];
|
|
367
407
|
};
|
|
368
408
|
export type DualSegmentBarRow = {
|
|
369
409
|
id: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@divami-artefacts/ai-design-system",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.55",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -33,25 +33,25 @@
|
|
|
33
33
|
"react-dom": ">=18.0.0"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
|
-
"@eslint/js": "
|
|
37
|
-
"@testing-library/jest-dom": "
|
|
38
|
-
"@testing-library/react": "
|
|
39
|
-
"@types/jest": "
|
|
40
|
-
"@types/node": "
|
|
41
|
-
"@types/react": "
|
|
42
|
-
"@types/react-dom": "
|
|
43
|
-
"@vitejs/plugin-react": "
|
|
44
|
-
"eslint": "
|
|
45
|
-
"eslint-plugin-react-hooks": "
|
|
46
|
-
"eslint-plugin-react-refresh": "
|
|
47
|
-
"globals": "
|
|
48
|
-
"jest": "
|
|
49
|
-
"react": "
|
|
50
|
-
"react-dom": "
|
|
51
|
-
"ts-jest": "
|
|
52
|
-
"typescript": "
|
|
53
|
-
"typescript-eslint": "
|
|
54
|
-
"vite": "
|
|
55
|
-
"vite-plugin-dts": "
|
|
36
|
+
"@eslint/js": "9.39.4",
|
|
37
|
+
"@testing-library/jest-dom": "6.9.1",
|
|
38
|
+
"@testing-library/react": "16.3.2",
|
|
39
|
+
"@types/jest": "30.0.0",
|
|
40
|
+
"@types/node": "24.12.0",
|
|
41
|
+
"@types/react": "19.2.14",
|
|
42
|
+
"@types/react-dom": "19.2.3",
|
|
43
|
+
"@vitejs/plugin-react": "6.0.1",
|
|
44
|
+
"eslint": "9.39.4",
|
|
45
|
+
"eslint-plugin-react-hooks": "7.0.1",
|
|
46
|
+
"eslint-plugin-react-refresh": "0.5.2",
|
|
47
|
+
"globals": "17.4.0",
|
|
48
|
+
"jest": "30.3.0",
|
|
49
|
+
"react": "19.2.4",
|
|
50
|
+
"react-dom": "19.2.4",
|
|
51
|
+
"ts-jest": "29.4.9",
|
|
52
|
+
"typescript": "5.9.3",
|
|
53
|
+
"typescript-eslint": "8.57.0",
|
|
54
|
+
"vite": "8.0.1",
|
|
55
|
+
"vite-plugin-dts": "4.5.4"
|
|
56
56
|
}
|
|
57
57
|
}
|