@scality/core-ui 0.162.0 → 0.164.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/barchartv2/Barchart.component.d.ts +9 -3
- package/dist/components/barchartv2/Barchart.component.d.ts.map +1 -1
- package/dist/components/barchartv2/Barchart.component.js +22 -5
- package/dist/components/barchartv2/utils.d.ts +26 -3
- package/dist/components/barchartv2/utils.d.ts.map +1 -1
- package/dist/components/barchartv2/utils.js +76 -22
- package/dist/components/chartlegend/ChartLegend.d.ts +8 -0
- package/dist/components/chartlegend/ChartLegend.d.ts.map +1 -0
- package/dist/components/chartlegend/ChartLegend.js +65 -0
- package/dist/components/chartlegend/ChartLegendWrapper.d.ts +17 -0
- package/dist/components/chartlegend/ChartLegendWrapper.d.ts.map +1 -0
- package/dist/components/chartlegend/ChartLegendWrapper.js +50 -0
- package/dist/components/date/FormattedDateTime.d.ts +3 -1
- package/dist/components/date/FormattedDateTime.d.ts.map +1 -1
- package/dist/components/date/FormattedDateTime.js +19 -1
- package/dist/components/date/FormattedDateTime.spec.js +12 -0
- package/dist/components/icon/Icon.component.d.ts +5 -5
- package/dist/components/icon/Icon.component.d.ts.map +1 -1
- package/dist/components/icon/Icon.component.js +33 -31
- package/dist/components/linetimeseriechart/linetimeseriechart.component.d.ts +33 -0
- package/dist/components/linetimeseriechart/linetimeseriechart.component.d.ts.map +1 -0
- package/dist/components/linetimeseriechart/linetimeseriechart.component.js +249 -0
- package/dist/components/selectv2/Selectv2.component.d.ts.map +1 -1
- package/dist/components/selectv2/Selectv2.component.js +11 -6
- package/dist/components/steppers/Stepper.component.d.ts.map +1 -1
- package/dist/components/steppers/Stepper.component.js +9 -8
- package/dist/components/toast/ToastProvider.d.ts.map +1 -1
- package/dist/components/toast/ToastProvider.js +4 -5
- package/dist/components/vegachartv2/SyncedCursorCharts.d.ts.map +1 -1
- package/dist/components/vegachartv2/SyncedCursorCharts.js +3 -5
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/next.d.ts +2 -0
- package/dist/next.d.ts.map +1 -1
- package/dist/next.js +2 -0
- package/dist/style/theme.d.ts +1 -0
- package/dist/style/theme.d.ts.map +1 -1
- package/dist/style/theme.js +28 -0
- package/package.json +2 -2
- package/src/lib/components/accordion/Accordion.test.tsx +8 -16
- package/src/lib/components/barchartv2/Barchart.component.test.tsx +117 -111
- package/src/lib/components/barchartv2/Barchart.component.tsx +54 -7
- package/src/lib/components/barchartv2/utils.test.ts +127 -2
- package/src/lib/components/barchartv2/utils.ts +103 -19
- package/src/lib/components/chartlegend/ChartLegend.tsx +113 -0
- package/src/lib/components/chartlegend/ChartLegendWrapper.tsx +85 -0
- package/src/lib/components/date/FormattedDateTime.spec.tsx +24 -0
- package/src/lib/components/date/FormattedDateTime.tsx +36 -2
- package/src/lib/components/healthselectorv2/HealthSelector.component.test.tsx +10 -10
- package/src/lib/components/icon/Icon.component.tsx +48 -60
- package/src/lib/components/infomessage/InfoMessageUtils.test.tsx +0 -1
- package/src/lib/components/inlineinput/InlineInput.test.tsx +28 -22
- package/src/lib/components/inputlist/InputList.test.tsx +22 -21
- package/src/lib/components/linetemporalchart/ChartUtil.test.ts +5 -4
- package/src/lib/components/linetimeseriechart/linetimeseriechart.component.tsx +502 -0
- package/src/lib/components/searchinput/SearchInput.test.tsx +3 -7
- package/src/lib/components/selectv2/Selectv2.component.tsx +13 -5
- package/src/lib/components/selectv2/selectv2.test.tsx +70 -61
- package/src/lib/components/steppers/Stepper.component.tsx +10 -8
- package/src/lib/components/tablev2/TableSync.test.tsx +8 -12
- package/src/lib/components/tablev2/TableUtils.test.ts +6 -3
- package/src/lib/components/tablev2/Tablev2.test.tsx +38 -40
- package/src/lib/components/toast/ToastProvider.tsx +14 -6
- package/src/lib/components/toggle/Toggle.test.tsx +1 -1
- package/src/lib/components/vegachartv2/SyncedCursorCharts.tsx +5 -7
- package/src/lib/index.ts +1 -0
- package/src/lib/next.ts +2 -0
- package/src/lib/style/theme.ts +29 -0
- package/stories/BarChart/barchart.stories.tsx +387 -129
- package/stories/format.mdx +4 -2
- package/stories/linetimeseriechart.stories.tsx +485 -0
- package/tsconfig.json +0 -1
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { jsx as _jsx
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
|
3
3
|
import { useEffect, useState, } from 'react';
|
|
4
|
-
import { useQuery } from 'react-query';
|
|
5
4
|
import styled, { css } from 'styled-components';
|
|
6
5
|
import { Loader } from '../loader/Loader.component';
|
|
7
6
|
import { RemoteGroup, RemoteUser } from './CustomsIcons';
|
|
7
|
+
// Module-level cache for imported icons
|
|
8
|
+
const iconCache = {};
|
|
8
9
|
export const iconTable = {
|
|
9
10
|
Account: 'fas faWallet',
|
|
10
11
|
Backend: 'fas faNetworkWired',
|
|
@@ -132,8 +133,8 @@ export const iconTable = {
|
|
|
132
133
|
Mail: 'fas faEnvelope',
|
|
133
134
|
};
|
|
134
135
|
export const customIcons = {
|
|
135
|
-
'Remote-user': ({ ariaLabel, color, size }) => (_jsx(RemoteUser, { ariaLabel: ariaLabel, color: color, size: size })),
|
|
136
|
-
'Remote-group': ({ ariaLabel, color, size }) => (_jsx(RemoteGroup, { ariaLabel: ariaLabel, color: color, size: size })),
|
|
136
|
+
'Remote-user': ({ 'aria-label': ariaLabel, color, size }) => (_jsx(RemoteUser, { ariaLabel: ariaLabel, color: color, size: size })),
|
|
137
|
+
'Remote-group': ({ 'aria-label': ariaLabel, color, size }) => (_jsx(RemoteGroup, { ariaLabel: ariaLabel, color: color, size: size })),
|
|
137
138
|
};
|
|
138
139
|
const IconStyled = styled(FontAwesomeIcon) `
|
|
139
140
|
${(props) => {
|
|
@@ -189,36 +190,37 @@ export const IconWrapper = styled.div `
|
|
|
189
190
|
align-items: center;
|
|
190
191
|
border-radius: 100%;
|
|
191
192
|
`;
|
|
192
|
-
function NonWrappedIcon({ name, size = '1x', color
|
|
193
|
+
function NonWrappedIcon({ name, size = '1x', color, ariaLabel = '', title, ...rest }) {
|
|
194
|
+
var _a;
|
|
193
195
|
const iconInfo = iconTable[name] || customIcons[name];
|
|
194
196
|
if (!iconInfo)
|
|
195
197
|
throw new Error(`${name}: is not a valid icon.`);
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
return (
|
|
198
|
+
// Loaded fortawesome icon if not a custom icon
|
|
199
|
+
const [icon, setIcon] = useState();
|
|
200
|
+
useEffect(() => {
|
|
201
|
+
if (customIcons[name]) {
|
|
202
|
+
return;
|
|
203
|
+
}
|
|
204
|
+
const [iconType, iconClass] = iconInfo.split(' ');
|
|
205
|
+
const fontAwesomeType = iconType === 'far' ? 'free-regular-svg-icons' : 'free-solid-svg-icons';
|
|
206
|
+
const cacheKey = `${fontAwesomeType}/${iconClass}`;
|
|
207
|
+
if (iconCache[cacheKey]) {
|
|
208
|
+
setIcon(iconCache[cacheKey]);
|
|
209
|
+
return () => setIcon(undefined);
|
|
210
|
+
}
|
|
211
|
+
// Handle FontAwesome icons with dynamic import
|
|
212
|
+
import(`@fortawesome/${fontAwesomeType}/${iconClass}.js`)
|
|
213
|
+
.then((module) => {
|
|
214
|
+
setIcon(module[iconClass]);
|
|
215
|
+
iconCache[cacheKey] = module[iconClass];
|
|
216
|
+
});
|
|
217
|
+
return () => setIcon(undefined);
|
|
218
|
+
}, [name, iconInfo]);
|
|
219
|
+
if (!icon && !customIcons[name]) {
|
|
220
|
+
return (_jsx(DelayedFallback, { "aria-label": `${name} ${ariaLabel}`, children: _jsx(Loader, { size: "base" }) }));
|
|
221
|
+
}
|
|
222
|
+
const IconComponent = (_a = customIcons[name]) !== null && _a !== void 0 ? _a : IconStyled;
|
|
223
|
+
return (_jsx(IconComponent, { color: color, icon: icon, size: size, title: title, "aria-label": `${name} ${ariaLabel}`, ...rest }));
|
|
222
224
|
}
|
|
223
225
|
function Icon({ withWrapper, ...props }) {
|
|
224
226
|
if (withWrapper) {
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export type Serie = {
|
|
2
|
+
resource: string;
|
|
3
|
+
data: [number, string | null][];
|
|
4
|
+
getTooltipLabel: (metricPrefix?: string, resource?: string) => string;
|
|
5
|
+
metricPrefix?: string;
|
|
6
|
+
isLineDashed?: boolean;
|
|
7
|
+
};
|
|
8
|
+
type NonSymmetricalChartSerie = {
|
|
9
|
+
yAxisType?: 'default' | 'percentage';
|
|
10
|
+
series: Serie[];
|
|
11
|
+
};
|
|
12
|
+
type SymmetricalChartSerie = {
|
|
13
|
+
yAxisType: 'symmetrical';
|
|
14
|
+
series: {
|
|
15
|
+
above: Serie[];
|
|
16
|
+
below: Serie[];
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
export type LineChartProps = (NonSymmetricalChartSerie | SymmetricalChartSerie) & {
|
|
20
|
+
title: string;
|
|
21
|
+
height: number;
|
|
22
|
+
startingTimeStamp: number;
|
|
23
|
+
unitRange?: {
|
|
24
|
+
threshold: number;
|
|
25
|
+
label: string;
|
|
26
|
+
}[];
|
|
27
|
+
isLoading?: boolean;
|
|
28
|
+
yAxisTitle?: string;
|
|
29
|
+
helpText?: string;
|
|
30
|
+
};
|
|
31
|
+
export declare function LineTimeSerieChart({ series, title, height, startingTimeStamp, unitRange, isLoading, yAxisType, yAxisTitle, helpText, ...rest }: LineChartProps): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
export {};
|
|
33
|
+
//# sourceMappingURL=linetimeseriechart.component.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"linetimeseriechart.component.d.ts","sourceRoot":"","sources":["../../../src/lib/components/linetimeseriechart/linetimeseriechart.component.tsx"],"names":[],"mappings":"AA2FA,MAAM,MAAM,KAAK,GAAG;IAElB,QAAQ,EAAE,MAAM,CAAC;IAEjB,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,EAAE,CAAC;IAEhC,eAAe,EAAE,CAAC,YAAY,CAAC,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,KAAK,MAAM,CAAC;IAEtE,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB,CAAC;AAEF,KAAK,wBAAwB,GAAG;IAC9B,SAAS,CAAC,EAAE,SAAS,GAAG,YAAY,CAAC;IACrC,MAAM,EAAE,KAAK,EAAE,CAAC;CACjB,CAAC;AAGF,KAAK,qBAAqB,GAAG;IAC3B,SAAS,EAAE,aAAa,CAAC;IACzB,MAAM,EAAE;QACN,KAAK,EAAE,KAAK,EAAE,CAAC;QACf,KAAK,EAAE,KAAK,EAAE,CAAC;KAChB,CAAC;CACH,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG,CACzB,wBAAwB,GACxB,qBAAqB,CACxB,GAAG;IACF,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,iBAAiB,EAAE,MAAM,CAAC;IAC1B,SAAS,CAAC,EAAE;QACV,SAAS,EAAE,MAAM,CAAC;QAClB,KAAK,EAAE,MAAM,CAAC;KACf,EAAE,CAAC;IACJ,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAiEF,wBAAgB,kBAAkB,CAAC,EACjC,MAAM,EACN,KAAK,EACL,MAAM,EACN,iBAAiB,EACjB,SAAS,EACT,SAAiB,EACjB,SAAqB,EACrB,UAAU,EACV,QAAQ,EACR,GAAG,IAAI,EACR,EAAE,cAAc,2CAqShB"}
|
|
@@ -0,0 +1,249 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Line, LineChart, ReferenceLine, ResponsiveContainer, Tooltip, XAxis, YAxis, CartesianGrid, } from 'recharts';
|
|
3
|
+
import { useMemo, useRef } from 'react';
|
|
4
|
+
import { useTheme } from 'styled-components';
|
|
5
|
+
import { useMetricsTimeSpan } from '../linetemporalchart/MetricTimespanProvider';
|
|
6
|
+
import { addMissingDataPoint } from '../linetemporalchart/ChartUtil';
|
|
7
|
+
import styled from 'styled-components';
|
|
8
|
+
import { fontSize, fontWeight } from '../../style/theme';
|
|
9
|
+
import { useChartLegend } from '../chartlegend/ChartLegendWrapper';
|
|
10
|
+
import { ChartTitleText, SmallerText } from '../text/Text.component';
|
|
11
|
+
import { Loader } from '../loader/Loader.component';
|
|
12
|
+
import { spacing } from '../../spacing';
|
|
13
|
+
import { getUnitLabel } from '../linetemporalchart/ChartUtil';
|
|
14
|
+
import { Icon } from '../icon/Icon.component';
|
|
15
|
+
import { Tooltip as TooltipComponent } from '../tooltip/Tooltip.component';
|
|
16
|
+
import { DAY_MONTH_ABBREVIATED_HOUR_MINUTE, FormattedDateTime, } from '../date/FormattedDateTime';
|
|
17
|
+
const LineTemporalChartWrapper = styled.div `
|
|
18
|
+
display: flex;
|
|
19
|
+
flex-direction: column;
|
|
20
|
+
justify-content: flex-start;
|
|
21
|
+
flex: 1;
|
|
22
|
+
`;
|
|
23
|
+
const ChartHeader = styled.div `
|
|
24
|
+
display: flex;
|
|
25
|
+
align-items: center;
|
|
26
|
+
`;
|
|
27
|
+
const TooltipContainer = styled.div `
|
|
28
|
+
background-color: ${(props) => props.theme.backgroundLevel1};
|
|
29
|
+
padding: ${spacing.r8};
|
|
30
|
+
border: 1px solid ${(props) => props.theme.border};
|
|
31
|
+
border-radius: 4px;
|
|
32
|
+
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
|
33
|
+
max-width: 250px;
|
|
34
|
+
`;
|
|
35
|
+
const TooltipTime = styled.div `
|
|
36
|
+
margin-bottom: ${spacing.r8};
|
|
37
|
+
color: ${(props) => props.theme.textPrimary};
|
|
38
|
+
font-size: ${fontSize.smaller};
|
|
39
|
+
font-weight: ${fontWeight.bold};
|
|
40
|
+
text-align: center;
|
|
41
|
+
`;
|
|
42
|
+
const TooltipValue = styled.div `
|
|
43
|
+
font-size: ${fontSize.smaller};
|
|
44
|
+
margin-top: 4px;
|
|
45
|
+
color: ${(props) => props.theme.textSecondary};
|
|
46
|
+
display: flex;
|
|
47
|
+
align-items: flex-start;
|
|
48
|
+
`;
|
|
49
|
+
const TooltipLegend = styled.div `
|
|
50
|
+
width: 12px;
|
|
51
|
+
height: 3px;
|
|
52
|
+
background-color: ${(props) => props.color};
|
|
53
|
+
margin-right: 8px;
|
|
54
|
+
flex-shrink: 0;
|
|
55
|
+
margin-top: 8px;
|
|
56
|
+
`;
|
|
57
|
+
const TooltipContent = styled.div `
|
|
58
|
+
display: flex;
|
|
59
|
+
min-width: 0;
|
|
60
|
+
flex: 1;
|
|
61
|
+
`;
|
|
62
|
+
const TooltipName = styled.div `
|
|
63
|
+
margin-right: 4px;
|
|
64
|
+
word-wrap: break-word;
|
|
65
|
+
word-break: break-word;
|
|
66
|
+
justify-content: flex-start;
|
|
67
|
+
`;
|
|
68
|
+
const TooltipInstanceValue = styled.div `
|
|
69
|
+
justify-content: flex-end;
|
|
70
|
+
`;
|
|
71
|
+
const CustomTooltip = ({ active, payload, label, unitLabel, }) => {
|
|
72
|
+
if (!active || !payload || !payload.length || !label)
|
|
73
|
+
return null;
|
|
74
|
+
// We can't use the default itemSorter method because it's a custom tooltip.
|
|
75
|
+
// Sort the payload here instead
|
|
76
|
+
const sortedPayload = [...payload].sort((a, b) => {
|
|
77
|
+
const aValue = Number(a.value);
|
|
78
|
+
const bValue = Number(b.value);
|
|
79
|
+
if (aValue >= 0 && bValue >= 0) {
|
|
80
|
+
return bValue - aValue; // Higher positive values first
|
|
81
|
+
}
|
|
82
|
+
if (aValue < 0 && bValue < 0) {
|
|
83
|
+
return bValue - aValue; // Lower negative values first
|
|
84
|
+
}
|
|
85
|
+
return bValue - aValue; // Positives before negatives
|
|
86
|
+
});
|
|
87
|
+
return (_jsxs(TooltipContainer, { children: [_jsx(TooltipTime, { children: _jsx(FormattedDateTime, { format: "day-month-abbreviated-hour-minute-second", value: new Date(label) }) }), sortedPayload.map((entry, index) => (_jsxs(TooltipValue, { children: [_jsx(TooltipLegend, { color: entry.color }), _jsxs(TooltipContent, { children: [_jsx(TooltipName, { children: entry.name }), _jsx(TooltipInstanceValue, { children: isNaN(Number(entry.value))
|
|
88
|
+
? '-'
|
|
89
|
+
: `${Number(entry.value).toFixed(2)}${unitLabel}` })] })] }, index)))] }));
|
|
90
|
+
};
|
|
91
|
+
const isSymmetricalSeries = (series) => {
|
|
92
|
+
return 'above' in series && 'below' in series;
|
|
93
|
+
};
|
|
94
|
+
export function LineTimeSerieChart({ series, title, height, startingTimeStamp, unitRange, isLoading = false, yAxisType = 'default', yAxisTitle, helpText, ...rest }) {
|
|
95
|
+
const theme = useTheme();
|
|
96
|
+
const { frequency, duration } = useMetricsTimeSpan();
|
|
97
|
+
const { getColor } = useChartLegend();
|
|
98
|
+
const chartRef = useRef(null);
|
|
99
|
+
const chartData = useMemo(() => {
|
|
100
|
+
// 1. Add missing data points
|
|
101
|
+
const normalizedSeries = yAxisType === 'symmetrical' && isSymmetricalSeries(series)
|
|
102
|
+
? {
|
|
103
|
+
above: series.above.map((line) => ({
|
|
104
|
+
...line,
|
|
105
|
+
data: addMissingDataPoint(line.data, startingTimeStamp, duration, frequency),
|
|
106
|
+
})),
|
|
107
|
+
// Convert positive values to negative values
|
|
108
|
+
below: series.below.map((line) => ({
|
|
109
|
+
...line,
|
|
110
|
+
data: addMissingDataPoint(line.data, startingTimeStamp, duration, frequency).map(([timestamp, value]) => [timestamp, value === null ? null : `-${Number(value)}`]),
|
|
111
|
+
})),
|
|
112
|
+
}
|
|
113
|
+
: series.map((line) => ({
|
|
114
|
+
...line,
|
|
115
|
+
data: addMissingDataPoint(line.data, startingTimeStamp, duration, frequency),
|
|
116
|
+
}));
|
|
117
|
+
// 2. Convert directly to Recharts format
|
|
118
|
+
// Initialize an object to hold data points by timestamp
|
|
119
|
+
const dataPointsByTime = {};
|
|
120
|
+
const seriesToProcess = yAxisType === 'symmetrical' && isSymmetricalSeries(normalizedSeries)
|
|
121
|
+
? [...normalizedSeries.above, ...normalizedSeries.below]
|
|
122
|
+
: normalizedSeries;
|
|
123
|
+
seriesToProcess.forEach((serie) => {
|
|
124
|
+
const label = serie.getTooltipLabel(serie.metricPrefix, serie.resource);
|
|
125
|
+
serie.data.forEach((point) => {
|
|
126
|
+
const timestamp = typeof point[0] === 'number' ? point[0] * 1000 : Number(point[0]);
|
|
127
|
+
const value = point[1];
|
|
128
|
+
// Initialize this timestamp if it doesn't exist
|
|
129
|
+
if (!dataPointsByTime[timestamp]) {
|
|
130
|
+
dataPointsByTime[timestamp] = { timestamp };
|
|
131
|
+
}
|
|
132
|
+
// Add this metric's value to the data point, and convert the value to a number if it's a string
|
|
133
|
+
dataPointsByTime[timestamp][label] =
|
|
134
|
+
typeof value === 'string' ? Number(value) : value;
|
|
135
|
+
});
|
|
136
|
+
});
|
|
137
|
+
// Convert object to array for Recharts
|
|
138
|
+
return Object.values(dataPointsByTime).sort((a, b) => a.timestamp - b.timestamp);
|
|
139
|
+
}, [series, startingTimeStamp, duration, frequency, yAxisType]);
|
|
140
|
+
// Calculate 5 perfectly evenly spaced ticks
|
|
141
|
+
const xAxisTicks = useMemo(() => {
|
|
142
|
+
if (!chartData || chartData.length === 0)
|
|
143
|
+
return [];
|
|
144
|
+
const timestamps = chartData.map((d) => d.timestamp);
|
|
145
|
+
const minTimestamp = Math.min(...timestamps);
|
|
146
|
+
const maxTimestamp = Math.max(...timestamps);
|
|
147
|
+
// Calculate 5 perfectly evenly spaced ticks
|
|
148
|
+
const timeRange = maxTimestamp - minTimestamp;
|
|
149
|
+
const interval = timeRange / 4; // 4 intervals create 5 points
|
|
150
|
+
const exactEvenTicks = [
|
|
151
|
+
minTimestamp,
|
|
152
|
+
minTimestamp + interval,
|
|
153
|
+
minTimestamp + interval * 2,
|
|
154
|
+
minTimestamp + interval * 3,
|
|
155
|
+
maxTimestamp,
|
|
156
|
+
];
|
|
157
|
+
// Return perfectly even ticks (guaranteed to be evenly divided)
|
|
158
|
+
return exactEvenTicks;
|
|
159
|
+
}, [chartData]);
|
|
160
|
+
// 3. Transform the data base on the valuebase
|
|
161
|
+
const { topValue, unitLabel, rechartsData } = useMemo(() => {
|
|
162
|
+
if (yAxisType === 'percentage')
|
|
163
|
+
return {
|
|
164
|
+
topValue: 100,
|
|
165
|
+
unitLabel: '%',
|
|
166
|
+
rechartsData: chartData,
|
|
167
|
+
};
|
|
168
|
+
const values = chartData.flatMap((dataPoint) => Object.entries(dataPoint)
|
|
169
|
+
.filter(([key]) => key !== 'timestamp')
|
|
170
|
+
.map(([_, value]) => {
|
|
171
|
+
const num = typeof value === 'string' ? Number(value) : (value !== null && value !== void 0 ? value : Infinity);
|
|
172
|
+
return !isNaN(num) && num !== null ? num : null;
|
|
173
|
+
})
|
|
174
|
+
.filter((value) => value !== null));
|
|
175
|
+
const top = Math.abs(Math.max(...values));
|
|
176
|
+
const bottom = Math.abs(Math.min(...values));
|
|
177
|
+
const maxValue = Math.max(top, bottom);
|
|
178
|
+
const { valueBase, unitLabel } = getUnitLabel(unitRange !== null && unitRange !== void 0 ? unitRange : [], maxValue);
|
|
179
|
+
const topValue = Math.ceil(maxValue / valueBase / 10) * 10;
|
|
180
|
+
const rechartsData = chartData.map((dataPoint) => {
|
|
181
|
+
const normalizedDataPoint = { ...dataPoint };
|
|
182
|
+
Object.entries(dataPoint).forEach(([key, value]) => {
|
|
183
|
+
if (key !== 'timestamp' && typeof value === 'number') {
|
|
184
|
+
normalizedDataPoint[key] = value / valueBase;
|
|
185
|
+
}
|
|
186
|
+
});
|
|
187
|
+
return normalizedDataPoint;
|
|
188
|
+
});
|
|
189
|
+
return { topValue, unitLabel, rechartsData };
|
|
190
|
+
}, [chartData, yAxisType, unitRange]);
|
|
191
|
+
// Group series by resource and create color mapping
|
|
192
|
+
const { colorMapping, groupedSeries } = useMemo(() => {
|
|
193
|
+
const mapping = {};
|
|
194
|
+
const allSeries = isSymmetricalSeries(series)
|
|
195
|
+
? [...series.above, ...series.below]
|
|
196
|
+
: series;
|
|
197
|
+
// Group series by resource
|
|
198
|
+
const groups = allSeries.reduce((acc, serie) => {
|
|
199
|
+
const key = serie.resource;
|
|
200
|
+
if (!acc[key]) {
|
|
201
|
+
acc[key] = [];
|
|
202
|
+
}
|
|
203
|
+
acc[key].push(serie);
|
|
204
|
+
return acc;
|
|
205
|
+
}, {});
|
|
206
|
+
// Get colors from the ChartLegend context
|
|
207
|
+
Object.keys(groups).forEach((resource) => {
|
|
208
|
+
const color = getColor(resource);
|
|
209
|
+
if (color) {
|
|
210
|
+
mapping[resource] = color;
|
|
211
|
+
}
|
|
212
|
+
else {
|
|
213
|
+
console.warn(`Color not defined for resource: ${resource}`);
|
|
214
|
+
}
|
|
215
|
+
});
|
|
216
|
+
return {
|
|
217
|
+
colorMapping: mapping,
|
|
218
|
+
groupedSeries: groups,
|
|
219
|
+
};
|
|
220
|
+
}, [series, getColor]);
|
|
221
|
+
// Format time for display the tick in the x axis
|
|
222
|
+
const formatTime = useMemo(() => (timestamp) => {
|
|
223
|
+
const date = new Date(timestamp);
|
|
224
|
+
return DAY_MONTH_ABBREVIATED_HOUR_MINUTE.format(date).replace(',', '');
|
|
225
|
+
}, []);
|
|
226
|
+
return (_jsxs(LineTemporalChartWrapper, { children: [_jsxs(ChartHeader, { children: [_jsxs(ChartTitleText, { children: [title, " ", unitLabel && `(${unitLabel})`] }), helpText && (_jsx(TooltipComponent, { placement: 'right', overlay: _jsx(SmallerText, { children: helpText }), children: _jsx(Icon, { name: "Info", color: theme.buttonSecondary }) })), isLoading && _jsx(Loader, {})] }), _jsx(ResponsiveContainer, { width: "100%", height: height, children: _jsxs(LineChart, { data: rechartsData, ref: chartRef, margin: { top: 0, right: 0, bottom: 0, left: 0 }, "aria-label": `Time series chart for ${title}`, children: [_jsx(CartesianGrid, { vertical: true, horizontal: true, verticalPoints: [0], horizontalPoints: [0], stroke: theme.border, fill: theme.backgroundLevel4, strokeWidth: 1 }), _jsx(XAxis, { dataKey: "timestamp", type: "number", domain: ['dataMin', 'dataMax'], ticks: xAxisTicks, tickFormatter: formatTime, tickCount: 5, tick: {
|
|
227
|
+
fill: theme.textSecondary,
|
|
228
|
+
fontSize: fontSize.smaller,
|
|
229
|
+
}, axisLine: { stroke: theme.border } }), _jsx(YAxis, { orientation: "right", allowDataOverflow: false, label: {
|
|
230
|
+
value: yAxisTitle,
|
|
231
|
+
angle: 90,
|
|
232
|
+
position: 'insideRight',
|
|
233
|
+
style: {
|
|
234
|
+
textAnchor: 'middle',
|
|
235
|
+
fill: theme.textSecondary,
|
|
236
|
+
fontSize: fontSize.smaller,
|
|
237
|
+
},
|
|
238
|
+
}, domain: yAxisType === 'percentage'
|
|
239
|
+
? [0, 100]
|
|
240
|
+
: yAxisType === 'symmetrical'
|
|
241
|
+
? [-topValue, topValue]
|
|
242
|
+
: [0, topValue], axisLine: { stroke: theme.border }, tick: {
|
|
243
|
+
fill: theme.textSecondary,
|
|
244
|
+
fontSize: fontSize.smaller,
|
|
245
|
+
}, tickFormatter: (value) => Math.round(value).toString() }), _jsx(Tooltip, { content: _jsx(CustomTooltip, { unitLabel: unitLabel }) }), yAxisType === 'symmetrical' && (_jsx(ReferenceLine, { y: 0, stroke: theme.border })), Object.entries(groupedSeries).map(([resource, resourceSeries]) => resourceSeries.map((serie, serieIndex) => {
|
|
246
|
+
const label = serie.getTooltipLabel(serie.metricPrefix, serie.resource);
|
|
247
|
+
return (_jsx(Line, { type: "monotone", dataKey: label, stroke: colorMapping[resource], dot: false }, `${title}-${resource}-${serieIndex}`));
|
|
248
|
+
}))] }) })] }));
|
|
249
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Selectv2.component.d.ts","sourceRoot":"","sources":["../../../src/lib/components/selectv2/Selectv2.component.tsx"],"names":[],"mappings":"AAAA,OAAO,EAOL,yBAAyB,EACzB,aAAa,EAEb,SAAS,
|
|
1
|
+
{"version":3,"file":"Selectv2.component.d.ts","sourceRoot":"","sources":["../../../src/lib/components/selectv2/Selectv2.component.tsx"],"names":[],"mappings":"AAAA,OAAO,EAOL,yBAAyB,EACzB,aAAa,EAEb,SAAS,EAIV,MAAM,OAAO,CAAC;AAEf,OAAO,EAEL,aAAa,EACb,cAAc,EAEf,MAAM,cAAc,CAAC;AAQtB,OAAO,WAAW,MAAM,yBAAyB,CAAC;AAKlD,MAAM,MAAM,WAAW,GAAG;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,cAAc,CAAC,EAAE,SAAS,CAAC;CAC5B,CAAC;AAkBF,wBAAgB,MAAM,CAAC,EACrB,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,IAAI,EACJ,cAAc,EACd,GAAG,IAAI,EACR,EAAE,WAAW,GAAG,GAAG,CAAC,OAAO,CA0B3B;AAuOD,MAAM,WAAW,SAAS,CACxB,UAAU,SAAS,cAAc,EACjC,OAAO,SAAS,OAAO,EACvB,SAAS,SAAS,aAAa,CAAC,UAAU,CAAC;IAE3C,MAAM,EAAE,WAAW,CAAC,UAAU,EAAE,OAAO,EAAE,SAAS,CAAC,GAAG,IAAI,CAAC;IAC3D,KAAK,EAAE,MAAM,IAA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as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { createContext, useContext, useState, useEffect, useRef, forwardRef, useImperativeHandle, } from 'react';
|
|
2
|
+
import { createContext, useContext, useState, useEffect, useRef, forwardRef, useImperativeHandle, useMemo, useCallback, } from 'react';
|
|
3
3
|
import { ScrollbarWrapper, Tooltip } from '../../index';
|
|
4
4
|
import { components, } from 'react-select';
|
|
5
5
|
import { Icon } from '../icon/Icon.component';
|
|
@@ -284,19 +284,24 @@ function SelectBox({ placeholder = 'Select...', disabled = false, value, onChang
|
|
|
284
284
|
}
|
|
285
285
|
const SelectWithOptionContext = forwardRef((props, ref) => {
|
|
286
286
|
const [options, setOptions] = useState({});
|
|
287
|
-
const register = (option) => {
|
|
287
|
+
const register = useCallback((option) => {
|
|
288
288
|
setOptions((prevOptions) => ({
|
|
289
289
|
...prevOptions,
|
|
290
290
|
[option.value]: option,
|
|
291
291
|
}));
|
|
292
|
-
};
|
|
293
|
-
const unregister = (value) => {
|
|
292
|
+
}, []);
|
|
293
|
+
const unregister = useCallback((value) => {
|
|
294
294
|
setOptions((prevOptions) => {
|
|
295
295
|
const { [value]: _, ...rest } = prevOptions;
|
|
296
296
|
return rest;
|
|
297
297
|
});
|
|
298
|
-
};
|
|
299
|
-
|
|
298
|
+
}, []);
|
|
299
|
+
const contextValue = useMemo(() => ({
|
|
300
|
+
options,
|
|
301
|
+
register,
|
|
302
|
+
unregister
|
|
303
|
+
}), [options, register, unregister]);
|
|
304
|
+
return (_jsx(OptionContext.Provider, { value: contextValue, children: _jsxs(_Fragment, { children: [_jsx(SelectBox, { ...props, selectRef: ref }), props.children] }) }));
|
|
300
305
|
});
|
|
301
306
|
SelectWithOptionContext.displayName = 'Select';
|
|
302
307
|
SelectWithOptionContext.Option = Option;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Stepper.component.d.ts","sourceRoot":"","sources":["../../../src/lib/components/steppers/Stepper.component.tsx"],"names":[],"mappings":"AAIA,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,CAAC;IAC/C,IAAI,EAAE,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,CAAC;CAChD;AACD,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,MAAM;QACd,cAAc,EAAE,KAAK,CAAC,OAAO,CAAC,kBAAkB,GAAG,IAAI,CAAC,CAAC;KAC1D;CACF;AAMD,eAAO,MAAM,UAAU,EAAE,UASxB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"Stepper.component.d.ts","sourceRoot":"","sources":["../../../src/lib/components/steppers/Stepper.component.tsx"],"names":[],"mappings":"AAIA,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,CAAC;IAC/C,IAAI,EAAE,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,KAAK,IAAI,CAAC;CAChD;AACD,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,MAAM;QACd,cAAc,EAAE,KAAK,CAAC,OAAO,CAAC,kBAAkB,GAAG,IAAI,CAAC,CAAC;KAC1D;CACF;AAMD,eAAO,MAAM,UAAU,EAAE,UASxB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,OAkCrB,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
/// <reference path="./Stepper.component.d.ts" />
|
|
3
|
-
import { createContext, useContext, useState } from 'react';
|
|
3
|
+
import { createContext, useContext, useState, useCallback, useMemo } from 'react';
|
|
4
4
|
import { Steppers } from './Steppers.component';
|
|
5
5
|
import { Box } from '../box/Box';
|
|
6
6
|
if (!window.StepperContext) {
|
|
@@ -17,15 +17,16 @@ export const useStepper = (index, steps) => {
|
|
|
17
17
|
};
|
|
18
18
|
export const Stepper = ({ steps }) => {
|
|
19
19
|
const [stepProps, setStepProps] = useState({ step: 0, props: {} });
|
|
20
|
-
const next = (props) => {
|
|
21
|
-
setStepProps({ step:
|
|
22
|
-
};
|
|
23
|
-
const prev = (props) => {
|
|
24
|
-
setStepProps({ step:
|
|
25
|
-
};
|
|
20
|
+
const next = useCallback((props) => {
|
|
21
|
+
setStepProps(current => ({ step: current.step + 1, props }));
|
|
22
|
+
}, []);
|
|
23
|
+
const prev = useCallback((props) => {
|
|
24
|
+
setStepProps(current => ({ step: current.step - 1, props }));
|
|
25
|
+
}, []);
|
|
26
26
|
const { Component } = steps[stepProps.step];
|
|
27
27
|
const StepperContext = window.StepperContext;
|
|
28
|
-
|
|
28
|
+
const stepperValue = useMemo(() => ({ next, prev }), [next, prev]);
|
|
29
|
+
return (_jsx(StepperContext.Provider, { value: stepperValue, children: _jsxs(Box, { display: "flex", gap: 32, flex: 1, height: "100%", children: [_jsx(Steppers, { activeStep: stepProps.step, steps: steps.map((step) => {
|
|
29
30
|
return {
|
|
30
31
|
title: step.label,
|
|
31
32
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ToastProvider.d.ts","sourceRoot":"","sources":["../../../src/lib/components/toast/ToastProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,
|
|
1
|
+
{"version":3,"file":"ToastProvider.d.ts","sourceRoot":"","sources":["../../../src/lib/components/toast/ToastProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAA6D,MAAM,OAAO,CAAC;AAC7F,OAAO,EAAS,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAEtD,MAAM,MAAM,iBAAiB,GAAG,IAAI,CAAC,UAAU,EAAE,SAAS,CAAC,CAAC;AAE5D,MAAM,WAAW,gBAAgB;IAC/B,SAAS,EAAE,CAAC,UAAU,EAAE,iBAAiB,KAAK,IAAI,CAAC;CACpD;AAED,eAAO,MAAM,YAAY,uDAExB,CAAC;AAEF,UAAU,kBAAkB;IAC1B,QAAQ,EAAE,SAAS,CAAC;CACrB;AAED,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAClC,KAAK,CAAC,iBAAiB,CAAC,kBAAkB,CAAC,CAsB5C,CAAC;AAEF,eAAO,MAAM,QAAQ,wBAOpB,CAAC"}
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { createContext, useContext, useState } from 'react';
|
|
2
|
+
import { createContext, useCallback, useContext, useMemo, useState } from 'react';
|
|
3
3
|
import { Toast } from './Toast.component';
|
|
4
4
|
export const ToastContext = createContext(undefined);
|
|
5
5
|
export const ToastProvider = ({ children }) => {
|
|
6
6
|
const [toastProps, setToastProps] = useState(null);
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
};
|
|
10
|
-
return (_jsxs(ToastContext.Provider, { value: { showToast }, children: [children, toastProps && (_jsx(Toast, { ...toastProps, onClose: () => setToastProps(null) }))] }));
|
|
7
|
+
const toastCtxValue = useMemo(() => ({ showToast: setToastProps }), []);
|
|
8
|
+
const closeToast = useCallback(() => setToastProps(null), []);
|
|
9
|
+
return (_jsxs(ToastContext.Provider, { value: toastCtxValue, children: [children, toastProps && (_jsx(Toast, { ...toastProps, onClose: closeToast }))] }));
|
|
11
10
|
};
|
|
12
11
|
export const useToast = () => {
|
|
13
12
|
const context = useContext(ToastContext);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SyncedCursorCharts.d.ts","sourceRoot":"","sources":["../../../src/lib/components/vegachartv2/SyncedCursorCharts.tsx"],"names":[],"mappings":"AACA,eAAO,MAAM,yBAAyB;aAC3B,MAAM;gBACH,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI;SACxB,CAAC;AAChB,eAAO,MAAM,UAAU,QAAO;IAC5B,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CACvC,GAAG,IAQH,CAAC;AACF,wBAAgB,kBAAkB,CAAC,EAAE,QAAQ,EAAE,EAAE;IAAE,QAAQ,EAAE,GAAG,CAAC,OAAO,CAAA;CAAE,
|
|
1
|
+
{"version":3,"file":"SyncedCursorCharts.d.ts","sourceRoot":"","sources":["../../../src/lib/components/vegachartv2/SyncedCursorCharts.tsx"],"names":[],"mappings":"AACA,eAAO,MAAM,yBAAyB;aAC3B,MAAM;gBACH,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI;SACxB,CAAC;AAChB,eAAO,MAAM,UAAU,QAAO;IAC5B,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CACvC,GAAG,IAQH,CAAC;AACF,wBAAgB,kBAAkB,CAAC,EAAE,QAAQ,EAAE,EAAE;IAAE,QAAQ,EAAE,GAAG,CAAC,OAAO,CAAA;CAAE,2CAUzE"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { useState, createContext, useContext } from 'react';
|
|
2
|
+
import { useState, createContext, useContext, useMemo } from 'react';
|
|
3
3
|
export const SyncedCursorChartsContext = createContext(null);
|
|
4
4
|
export const useCursorX = () => {
|
|
5
5
|
const contextValue = useContext(SyncedCursorChartsContext);
|
|
@@ -10,8 +10,6 @@ export const useCursorX = () => {
|
|
|
10
10
|
};
|
|
11
11
|
export function SyncedCursorCharts({ children }) {
|
|
12
12
|
const [cursorX, setCursorX] = useState(0);
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
setCursorX,
|
|
16
|
-
}, children: children }));
|
|
13
|
+
const contextValue = useMemo(() => ({ cursorX, setCursorX }), [cursorX]);
|
|
14
|
+
return (_jsx(SyncedCursorChartsContext.Provider, { value: contextValue, children: children }));
|
|
17
15
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -61,4 +61,5 @@ export { InfoMessage } from './components/infomessage/InfoMessage.component';
|
|
|
61
61
|
export { InputList } from './components/inputlist/InputList.component';
|
|
62
62
|
export { InlineInput } from './components/inlineinput/InlineInput';
|
|
63
63
|
export { UnsuccessfulResult } from './components/UnsuccessfulResult.component';
|
|
64
|
+
export { LineTimeSerieChart } from './components/linetimeseriechart/linetimeseriechart.component';
|
|
64
65
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/lib/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,sCAAsC,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAE,MAAM,8CAA8C,CAAC;AAC1E,OAAO,EAAE,MAAM,EAAE,MAAM,sCAAsC,CAAC;AAC9D,OAAO,EAAE,QAAQ,EAAE,MAAM,0CAA0C,CAAC;AACpE,OAAO,EAAE,KAAK,EAAE,MAAM,oCAAoC,CAAC;AAC3D,OAAO,EAAE,QAAQ,EAAE,MAAM,0CAA0C,CAAC;AACpE,OAAO,EACL,WAAW,EACX,eAAe,EACf,cAAc,EACd,cAAc,EACd,cAAc,EACd,WAAW,EACX,cAAc,EACd,WAAW,EACX,MAAM,GACP,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,MAAM,EAAE,MAAM,sCAAsC,CAAC;AAC9D,OAAO,EAAE,MAAM,EAAE,MAAM,sCAAsC,CAAC;AAC9D,OAAO,EAAE,KAAK,EAAE,MAAM,oCAAoC,CAAC;AAC3D,OAAO,EAAE,MAAM,EAAE,MAAM,sCAAsC,CAAC;AAC9D,OAAO,EAAE,aAAa,EAAE,MAAM,oDAAoD,CAAC;AACnF,OAAO,EAAE,WAAW,EAAE,MAAM,gDAAgD,CAAC;AAC7E,OAAO,EAAE,MAAM,EAAE,MAAM,sCAAsC,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MAAM,4CAA4C,CAAC;AACvE,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC;AACnE,OAAO,EAAE,kBAAkB,EAAE,MAAM,2CAA2C,CAAC;AAC/E,OAAO,EAAE,kBAAkB,EAAE,MAAM,8DAA8D,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -61,3 +61,4 @@ export { InfoMessage } from './components/infomessage/InfoMessage.component';
|
|
|
61
61
|
export { InputList } from './components/inputlist/InputList.component';
|
|
62
62
|
export { InlineInput } from './components/inlineinput/InlineInput';
|
|
63
63
|
export { UnsuccessfulResult } from './components/UnsuccessfulResult.component';
|
|
64
|
+
export { LineTimeSerieChart } from './components/linetimeseriechart/linetimeseriechart.component';
|
package/dist/next.d.ts
CHANGED
|
@@ -14,4 +14,6 @@ export { Box } from './components/box/Box';
|
|
|
14
14
|
export { Input } from './components/inputv2/inputv2';
|
|
15
15
|
export { Accordion } from './components/accordion/Accordion.component';
|
|
16
16
|
export { Barchart, BarchartSortFn, BarchartTooltipFn, } from './components/barchartv2/Barchart.component';
|
|
17
|
+
export { ChartLegendWrapper } from './components/chartlegend/ChartLegendWrapper';
|
|
18
|
+
export { ChartLegend } from './components/chartlegend/ChartLegend';
|
|
17
19
|
//# sourceMappingURL=next.d.ts.map
|
package/dist/next.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"next.d.ts","sourceRoot":"","sources":["../src/lib/next.ts"],"names":[],"mappings":"AAAA,OAAO,2CAA2C,CAAC;AACnD,OAAO,aAAa,CAAC;AACrB,OAAO,EAAE,MAAM,EAAE,MAAM,0CAA0C,CAAC;AAClE,OAAO,EAAE,UAAU,EAAE,MAAM,4CAA4C,CAAC;AACxE,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,MAAM,sCAAsC,CAAC;AACjE,OAAO,EAAE,KAAK,EAAE,MAAM,wCAAwC,CAAC;AAC/D,OAAO,EAAE,iBAAiB,EAAE,MAAM,4DAA4D,CAAC;A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C,OAAO,EAAE,KAAK,EAAE,MAAM,8BAA8B,CAAC;AACrD,OAAO,EAAE,SAAS,EAAE,MAAM,4CAA4C,CAAC;AACvE,OAAO,EACL,QAAQ,EACR,cAAc,EACd,iBAAiB,GAClB,MAAM,4CAA4C,CAAC;AACpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,6CAA6C,CAAC;AACjF,OAAO,EAAE,WAAW,EAAE,MAAM,sCAAsC,CAAC"}
|
package/dist/next.js
CHANGED
|
@@ -14,3 +14,5 @@ export { Box } from './components/box/Box';
|
|
|
14
14
|
export { Input } from './components/inputv2/inputv2';
|
|
15
15
|
export { Accordion } from './components/accordion/Accordion.component';
|
|
16
16
|
export { Barchart, } from './components/barchartv2/Barchart.component';
|
|
17
|
+
export { ChartLegendWrapper } from './components/chartlegend/ChartLegendWrapper';
|
|
18
|
+
export { ChartLegend } from './components/chartlegend/ChartLegend';
|
package/dist/style/theme.d.ts
CHANGED
|
@@ -176,4 +176,5 @@ export declare const navbarHeight = "3rem";
|
|
|
176
176
|
export declare const navbarItemWidth = "4.286rem";
|
|
177
177
|
export declare const sidebarItemHeight: string;
|
|
178
178
|
export declare const sidebarWidth: string;
|
|
179
|
+
export declare const lineTimeSeriesColorRange: string[];
|
|
179
180
|
//# sourceMappingURL=theme.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/lib/style/theme.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/lib/style/theme.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,OAAO,YAAY,CAAC;AACjC,eAAO,MAAM,IAAI,YAAY,CAAC;AAC9B,eAAO,MAAM,SAAS,YAAY,CAAC;AACnC,eAAO,MAAM,IAAI,YAAY,CAAC;AAC9B,eAAO,MAAM,IAAI,YAAY,CAAC;AAC9B,eAAO,MAAM,UAAU,YAAY,CAAC;AACpC,eAAO,MAAM,O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EF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,OAAO;;;;;;CAMnB,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;CAenB,CAAC;AAEF,eAAO,MAAM,OAAO;;;;;;;;CAQnB,CAAC;AACF,eAAO,MAAM,MAAM;;;;;;;;;;CAUlB,CAAC;AAEF,eAAO,MAAM,YAAY,SAAS,CAAC;AACnC,eAAO,MAAM,eAAe,aAAa,CAAC;AAE1C,eAAO,MAAM,iBAAiB,QAAe,CAAC;AAC9C,eAAO,MAAM,YAAY,QAAe,CAAC;AAGzC,eAAO,MAAM,wBAAwB,UAyBpC,CAAC"}
|
package/dist/style/theme.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { lighten, darken } from 'polished';
|
|
1
2
|
//== Colors
|
|
2
3
|
export const hotPink = '#E40046';
|
|
3
4
|
export const pink = '#EB4962';
|
|
@@ -249,3 +250,30 @@ export const navbarItemWidth = '4.286rem';
|
|
|
249
250
|
//sidebar
|
|
250
251
|
export const sidebarItemHeight = spacing.sp40;
|
|
251
252
|
export const sidebarWidth = spacing.sp40;
|
|
253
|
+
// We use 8 main color from the palette and decline them (lighter/ darker) when we have more than 8 datasets
|
|
254
|
+
export const lineTimeSeriesColorRange = [
|
|
255
|
+
lineColor1,
|
|
256
|
+
lineColor2,
|
|
257
|
+
lineColor3,
|
|
258
|
+
lineColor4,
|
|
259
|
+
lineColor5,
|
|
260
|
+
lineColor6,
|
|
261
|
+
lineColor7,
|
|
262
|
+
lineColor8,
|
|
263
|
+
lighten(0.3, lineColor1),
|
|
264
|
+
lighten(0.3, lineColor2),
|
|
265
|
+
lighten(0.3, lineColor3),
|
|
266
|
+
lighten(0.3, lineColor4),
|
|
267
|
+
lighten(0.3, lineColor5),
|
|
268
|
+
lighten(0.3, lineColor6),
|
|
269
|
+
lighten(0.3, lineColor7),
|
|
270
|
+
lighten(0.3, lineColor8),
|
|
271
|
+
darken(0.2, lineColor1),
|
|
272
|
+
darken(0.2, lineColor2),
|
|
273
|
+
darken(0.2, lineColor3),
|
|
274
|
+
darken(0.2, lineColor4),
|
|
275
|
+
darken(0.3, lineColor5),
|
|
276
|
+
darken(0.3, lineColor6),
|
|
277
|
+
darken(0.3, lineColor7),
|
|
278
|
+
darken(0.3, lineColor8),
|
|
279
|
+
];
|