@hybridcore/ui 1.6.2 → 1.6.4
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/LinearGradient-DiRq5YcI.js +93 -0
- package/dist/components/charts/chart-wrapper/index.js +41 -40
- package/dist/components/charts/chart-wrapper/logic.js +14 -12
- package/dist/components/charts/heatmap/logic.js +155 -242
- package/dist/components/metric-card/MetricChart.js +65 -50
- package/dist/components/metric-card/helpers.js +18 -0
- package/dist/components/metric-card/index.js +83 -73
- package/dist/components/metric-card/logic.js +64 -76
- package/dist/components/metric-card/styled.js +125 -137
- package/dist/components/sortable-list/index.js +1992 -346
- package/dist/main.d.ts +53 -21
- package/dist/main.js +97 -95
- package/package.json +5 -2
package/dist/main.d.ts
CHANGED
|
@@ -52,6 +52,7 @@ import { TabsProps as TabsProps_2 } from '@mui/material';
|
|
|
52
52
|
import { Theme } from '@mui/material';
|
|
53
53
|
import { ThemeOptions } from '@mui/material';
|
|
54
54
|
import { ThemeProvider } from '@mui/material';
|
|
55
|
+
import { TypographyProps } from '@mui/material';
|
|
55
56
|
|
|
56
57
|
export declare const Access: <T extends string>(props: AccessProps<T>) => JSX_2.Element | null;
|
|
57
58
|
|
|
@@ -247,6 +248,12 @@ export declare interface ChartProps {
|
|
|
247
248
|
initDelay?: number;
|
|
248
249
|
interval?: string;
|
|
249
250
|
baseInterval?: BaseInterval;
|
|
251
|
+
/**
|
|
252
|
+
* When `true`, the chart is still waiting on its async config/data. The wrapper
|
|
253
|
+
* holds back rendering (and the "missing config" validation error) until this
|
|
254
|
+
* clears, so a misconfiguration only surfaces once the data has settled.
|
|
255
|
+
*/
|
|
256
|
+
loading?: boolean;
|
|
250
257
|
/**
|
|
251
258
|
* Color palette used for series. Defaults to the lib's built-in viridis-cool
|
|
252
259
|
* palette. Pass `theme.palette.viridisCool` (or any sequential palette) from
|
|
@@ -336,13 +343,13 @@ declare interface ConditionalWrapperProps {
|
|
|
336
343
|
*/
|
|
337
344
|
condition: boolean;
|
|
338
345
|
/**
|
|
339
|
-
* @param children React.
|
|
346
|
+
* @param children React.ReactNode
|
|
340
347
|
*/
|
|
341
|
-
wrapper(children: default_2.
|
|
348
|
+
wrapper(children: default_2.ReactNode): default_2.ReactNode;
|
|
342
349
|
/**
|
|
343
350
|
* Child components to wrap
|
|
344
351
|
*/
|
|
345
|
-
children: default_2.
|
|
352
|
+
children: default_2.ReactNode;
|
|
346
353
|
}
|
|
347
354
|
|
|
348
355
|
declare function confirm_2(title: string, description: string, options?: OptionsType): Promise<unknown>;
|
|
@@ -607,6 +614,19 @@ export declare interface DurationSelectProps {
|
|
|
607
614
|
|
|
608
615
|
export declare type DurationSelectValue = "24 Hours" | "7 Days" | "30 Days";
|
|
609
616
|
|
|
617
|
+
export declare const EditableText: (props: EditableTextProps) => JSX_2.Element;
|
|
618
|
+
|
|
619
|
+
export declare type EditableTextComponentOverride<Theme = unknown> = {
|
|
620
|
+
defaultProps?: Partial<EditableTextProps>;
|
|
621
|
+
styleOverrides?: ComponentsOverrides<Theme>["HCEditableText"];
|
|
622
|
+
};
|
|
623
|
+
|
|
624
|
+
export declare interface EditableTextProps extends TypographyProps {
|
|
625
|
+
text?: string;
|
|
626
|
+
placeholder?: string;
|
|
627
|
+
onChange?(text: string | null): void;
|
|
628
|
+
}
|
|
629
|
+
|
|
610
630
|
export declare const FlexCol: StyledComponent<BoxOwnProps<Theme> & Omit<Omit<DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
611
631
|
ref?: ((instance: HTMLDivElement | null) => void | DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | RefObject<HTMLDivElement> | null | undefined;
|
|
612
632
|
}, keyof BoxOwnProps<Theme>> & MUIStyledCommonProps<Theme>, {}, {}>;
|
|
@@ -1110,6 +1130,15 @@ export declare interface MetricCardProps {
|
|
|
1110
1130
|
variant?: MetricVariant;
|
|
1111
1131
|
loading?: boolean;
|
|
1112
1132
|
|
|
1133
|
+
// "overlay" (default) = chart bleeds behind the value; "panel" = value/badge on the
|
|
1134
|
+
// left, chart inset on the right, wrapped in a nested card.
|
|
1135
|
+
layout?: MetricLayout;
|
|
1136
|
+
|
|
1137
|
+
// Rendered verbatim around the formatted number, e.g. valuePrefix "€ " → "€ 1,577",
|
|
1138
|
+
// valueSuffix " kg" → "1,577 kg". Include any spacing in the string itself.
|
|
1139
|
+
valuePrefix?: string;
|
|
1140
|
+
valueSuffix?: string;
|
|
1141
|
+
|
|
1113
1142
|
showChange?: boolean;
|
|
1114
1143
|
changeType?: MetricChangeType;
|
|
1115
1144
|
|
|
@@ -1144,6 +1173,8 @@ export declare type MetricIconPosition =
|
|
|
1144
1173
|
| "bottom-left"
|
|
1145
1174
|
| "bottom-right";
|
|
1146
1175
|
|
|
1176
|
+
declare type MetricLayout = "overlay" | "panel";
|
|
1177
|
+
|
|
1147
1178
|
export declare type MetricTrend = "up" | "down" | "neutral";
|
|
1148
1179
|
|
|
1149
1180
|
export declare type MetricVariant =
|
|
@@ -2867,6 +2898,22 @@ declare module "@mui/material/styles" {
|
|
|
2867
2898
|
|
|
2868
2899
|
|
|
2869
2900
|
|
|
2901
|
+
declare module "@mui/material/styles" {
|
|
2902
|
+
interface ComponentNameToClassKey {
|
|
2903
|
+
HCEditableText: "root";
|
|
2904
|
+
}
|
|
2905
|
+
|
|
2906
|
+
interface ComponentsPropsList {
|
|
2907
|
+
HCEditableText: Partial<EditableTextProps>;
|
|
2908
|
+
}
|
|
2909
|
+
|
|
2910
|
+
interface Components<Theme = unknown> {
|
|
2911
|
+
HCEditableText?: EditableTextComponentOverride<Theme>;
|
|
2912
|
+
}
|
|
2913
|
+
}
|
|
2914
|
+
|
|
2915
|
+
|
|
2916
|
+
|
|
2870
2917
|
declare module "@mui/material/styles" {
|
|
2871
2918
|
interface ComponentNameToClassKey {
|
|
2872
2919
|
HCGeometryPicker:
|
|
@@ -3160,11 +3207,12 @@ declare module "@mui/material/styles" {
|
|
|
3160
3207
|
| "label"
|
|
3161
3208
|
| "value"
|
|
3162
3209
|
| "trendContainer"
|
|
3163
|
-
| "trendValue"
|
|
3164
3210
|
| "description"
|
|
3165
3211
|
| "icon"
|
|
3166
3212
|
| "cornerIcon"
|
|
3167
|
-
| "chart"
|
|
3213
|
+
| "chart"
|
|
3214
|
+
| "panel"
|
|
3215
|
+
| "sideChart";
|
|
3168
3216
|
}
|
|
3169
3217
|
|
|
3170
3218
|
interface ComponentsPropsList {
|
|
@@ -3652,22 +3700,6 @@ declare module "@mui/material/styles" {
|
|
|
3652
3700
|
}
|
|
3653
3701
|
}
|
|
3654
3702
|
|
|
3655
|
-
|
|
3656
|
-
|
|
3657
|
-
declare module "@mui/material/styles" {
|
|
3658
|
-
interface ComponentNameToClassKey {
|
|
3659
|
-
HCEditableText: "root";
|
|
3660
|
-
}
|
|
3661
|
-
|
|
3662
|
-
interface ComponentsPropsList {
|
|
3663
|
-
HCEditableText: Partial<EditableTextProps>;
|
|
3664
|
-
}
|
|
3665
|
-
|
|
3666
|
-
interface Components<Theme = unknown> {
|
|
3667
|
-
HCEditableText?: EditableTextComponentOverride<Theme>;
|
|
3668
|
-
}
|
|
3669
|
-
}
|
|
3670
|
-
|
|
3671
3703
|
declare namespace AUTH {
|
|
3672
3704
|
type ModuleType =
|
|
3673
3705
|
| "UI"
|
package/dist/main.js
CHANGED
|
@@ -11,8 +11,8 @@ import { DrillDownTreemap as u } from "./components/charts/drill-down-treemap/in
|
|
|
11
11
|
import { DrillDownVoronoiTreemap as I } from "./components/charts/drill-down-voronoi-treemap/index.js";
|
|
12
12
|
import { Heatmap as y } from "./components/charts/heatmap/index.js";
|
|
13
13
|
import { HighlightLineChart as F } from "./components/charts/highlighting-line-data/index.js";
|
|
14
|
-
import { LineChart as
|
|
15
|
-
import { LogaritmicScale as
|
|
14
|
+
import { LineChart as k } from "./components/charts/line/index.js";
|
|
15
|
+
import { LogaritmicScale as R } from "./components/charts/logaritmic-scale/index.js";
|
|
16
16
|
import { MultipleValueAxes as v } from "./components/charts/multiple-value-axes/index.js";
|
|
17
17
|
import { NestedPie as E } from "./components/charts/nested-pie/index.js";
|
|
18
18
|
import { PackedCircles as H } from "./components/charts/packed-circles/index.js";
|
|
@@ -37,52 +37,53 @@ import { A as hr, D as ur } from "./index-e9xTIYWt.js";
|
|
|
37
37
|
import { DEFAULT_RELATIVE_PRESET_LABELS as Ir } from "./components/date-picker-with-custom-range/logic.js";
|
|
38
38
|
import { DateTimePicker as yr } from "./components/date-time-picker/index.js";
|
|
39
39
|
import { Divider as Fr } from "./components/divider/index.js";
|
|
40
|
-
import { DateRangePicker as
|
|
41
|
-
import { DocumentViewer as
|
|
40
|
+
import { DateRangePicker as kr } from "./components/date-range-picker/index.js";
|
|
41
|
+
import { DocumentViewer as Rr } from "./components/document-viewer/index.js";
|
|
42
42
|
import { DurationSelect as vr } from "./components/duration-select/index.js";
|
|
43
|
-
import {
|
|
44
|
-
import {
|
|
45
|
-
import {
|
|
46
|
-
import {
|
|
47
|
-
import {
|
|
48
|
-
import {
|
|
49
|
-
import {
|
|
50
|
-
import {
|
|
51
|
-
import {
|
|
52
|
-
import {
|
|
53
|
-
import {
|
|
54
|
-
import {
|
|
55
|
-
import {
|
|
56
|
-
import {
|
|
57
|
-
import {
|
|
58
|
-
import {
|
|
59
|
-
import {
|
|
60
|
-
import {
|
|
61
|
-
import {
|
|
62
|
-
import {
|
|
63
|
-
import {
|
|
64
|
-
import {
|
|
65
|
-
import {
|
|
66
|
-
import {
|
|
67
|
-
import {
|
|
68
|
-
import {
|
|
69
|
-
import {
|
|
70
|
-
import {
|
|
71
|
-
import {
|
|
72
|
-
import {
|
|
73
|
-
import {
|
|
74
|
-
import {
|
|
75
|
-
import {
|
|
76
|
-
import {
|
|
77
|
-
import {
|
|
78
|
-
import {
|
|
79
|
-
import {
|
|
80
|
-
import {
|
|
81
|
-
import {
|
|
82
|
-
import {
|
|
83
|
-
import {
|
|
84
|
-
import {
|
|
85
|
-
import {
|
|
43
|
+
import { EditableText as Er } from "./components/editable-text/index.js";
|
|
44
|
+
import { GeometryPicker as Hr } from "./components/geometry-picker/index.js";
|
|
45
|
+
import { Geometry as Wr } from "./components/geometry-picker/geometry/index.js";
|
|
46
|
+
import { Parser as Or } from "./components/geometry-picker/parser/index.js";
|
|
47
|
+
import { HeatMap as Nr } from "./components/heat-map/index.js";
|
|
48
|
+
import { IconButton as zr } from "./components/icon-button/index.js";
|
|
49
|
+
import { InstanceForm as Yr } from "./components/instance-form/index.js";
|
|
50
|
+
import { InstanceHierarchyTable as Jr } from "./components/instance-hierarchy-table/index.js";
|
|
51
|
+
import { InstanceTable as Qr } from "./components/instance-table/index.js";
|
|
52
|
+
import { InstanceVariableList as $r } from "./components/instance-variable-list/index.js";
|
|
53
|
+
import { LinearIndicator as oo } from "./components/linear-indicator/index.js";
|
|
54
|
+
import { Loading as to } from "./components/loading/index.js";
|
|
55
|
+
import { Map as mo } from "./components/map/index.js";
|
|
56
|
+
import { MetricCard as xo } from "./components/metric-card/index.js";
|
|
57
|
+
import { ObjectProfileCard as io } from "./components/object-profile-card/index.js";
|
|
58
|
+
import { PaginatedList as no } from "./components/paginated-list/index.js";
|
|
59
|
+
import { PhoneInput as so } from "./components/phone-input/index.js";
|
|
60
|
+
import { Placeholder as Po } from "./components/placeholder/index.js";
|
|
61
|
+
import { PositionalTooltip as Do } from "./components/positional-tooltip/index.js";
|
|
62
|
+
import { PrrMap as ho } from "./components/prr-map/index.js";
|
|
63
|
+
import { RangeSelector as So } from "./components/range-selector/index.js";
|
|
64
|
+
import { RasterGridMap as go } from "./components/raster-grid-map/index.js";
|
|
65
|
+
import { SearchInput as Ao } from "./components/search-input/index.js";
|
|
66
|
+
import { ScrollDrag as bo } from "./components/scroll-drag/index.js";
|
|
67
|
+
import { SimplePivotTable as Mo } from "./components/simple-pivot-table/index.js";
|
|
68
|
+
import { SortableList as Vo } from "./components/sortable-list/index.js";
|
|
69
|
+
import { StatsBox as wo } from "./components/stats-box/index.js";
|
|
70
|
+
import { StaticText as Go } from "./components/static-text/index.js";
|
|
71
|
+
import { Tabs as Bo } from "./components/tabs/index.js";
|
|
72
|
+
import { TextOverflow as _o } from "./components/text-overflow/index.js";
|
|
73
|
+
import { TemplateFilters as Uo } from "./components/template-filters/index.js";
|
|
74
|
+
import { TemplateForm as jo } from "./components/template-form/index.js";
|
|
75
|
+
import { TemplatePropertyFilters as Xo } from "./components/template-property-filters/index.js";
|
|
76
|
+
import { Property as qo } from "./components/template-property-filters/property.js";
|
|
77
|
+
import { TimelineWidget as Ko } from "./components/timeline/index.js";
|
|
78
|
+
import { ToggleViewButton as Zo } from "./components/toggle-view-button/index.js";
|
|
79
|
+
import { TreeSelect as re } from "./components/tree-select/index.js";
|
|
80
|
+
import { TreeViewFilter as ee } from "./components/treeview-filter/index.js";
|
|
81
|
+
import { Uploader as pe } from "./components/uploader/index.js";
|
|
82
|
+
import { VisuallyHiddenInput as ae } from "./components/visually-hidden-input/styled.js";
|
|
83
|
+
import { Widget as fe } from "./components/widget/styled.js";
|
|
84
|
+
import { FlexCol as le } from "./components/flex-col/index.js";
|
|
85
|
+
import { FlexRow as ce } from "./components/flex-row/index.js";
|
|
86
|
+
import { notify as de, removeNotification as Ce } from "./components/notification/store.js";
|
|
86
87
|
export {
|
|
87
88
|
x as Access,
|
|
88
89
|
i as AccessUtils,
|
|
@@ -103,74 +104,75 @@ export {
|
|
|
103
104
|
cr as DataGrid,
|
|
104
105
|
dr as DataMap,
|
|
105
106
|
ur as DatePickerWithCustomRange,
|
|
106
|
-
|
|
107
|
+
kr as DateRangePicker,
|
|
107
108
|
yr as DateTimePicker,
|
|
108
109
|
Pr as DisseminationList,
|
|
109
110
|
Fr as Divider,
|
|
110
|
-
|
|
111
|
+
Rr as DocumentViewer,
|
|
111
112
|
u as DrillDownTreemap,
|
|
112
113
|
I as DrillDownVoronoiTreemap,
|
|
113
114
|
vr as DurationSelect,
|
|
114
|
-
|
|
115
|
-
le as
|
|
116
|
-
|
|
117
|
-
Wr as
|
|
118
|
-
|
|
115
|
+
Er as EditableText,
|
|
116
|
+
le as FlexCol,
|
|
117
|
+
ce as FlexRow,
|
|
118
|
+
Wr as GeometryDraw,
|
|
119
|
+
Or as GeometryParser,
|
|
120
|
+
Hr as GeometryPicker,
|
|
119
121
|
ar as HCNotificationProvider,
|
|
120
|
-
|
|
122
|
+
Nr as HeatMap,
|
|
121
123
|
y as Heatmap,
|
|
122
124
|
F as HighlightLineChart,
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
125
|
+
zr as IconButton,
|
|
126
|
+
Yr as InstanceForm,
|
|
127
|
+
Jr as InstanceHierarchyTable,
|
|
128
|
+
Qr as InstanceTable,
|
|
129
|
+
$r as InstanceVariableList,
|
|
130
|
+
k as LineChart,
|
|
131
|
+
oo as LinearIndicator,
|
|
132
|
+
to as Loading,
|
|
131
133
|
m as LocalizationProvider,
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
134
|
+
R as LogaritmicScale,
|
|
135
|
+
mo as Map,
|
|
136
|
+
xo as MetricCard,
|
|
135
137
|
v as MultipleValueAxes,
|
|
136
138
|
E as NestedPie,
|
|
137
|
-
|
|
139
|
+
io as ObjectProfileCard,
|
|
138
140
|
H as PackedCircles,
|
|
139
|
-
|
|
140
|
-
|
|
141
|
+
no as PaginatedList,
|
|
142
|
+
so as PhoneInput,
|
|
141
143
|
W as PieChart,
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
144
|
+
Po as Placeholder,
|
|
145
|
+
Do as PositionalTooltip,
|
|
146
|
+
qo as PropertyFilterInput,
|
|
147
|
+
ho as PrrMap,
|
|
148
|
+
So as RangeSelector,
|
|
149
|
+
go as RasterGridMap,
|
|
150
|
+
bo as ScrollDrag,
|
|
151
|
+
Ao as SearchInput,
|
|
150
152
|
Dr as SecurityLevel,
|
|
151
|
-
|
|
152
|
-
|
|
153
|
+
Mo as SimplePivotTable,
|
|
154
|
+
Vo as SortableList,
|
|
153
155
|
O as StackedAreaRadar,
|
|
154
156
|
N as StackedColumnChart,
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
157
|
+
Go as StaticText,
|
|
158
|
+
wo as StatsBox,
|
|
159
|
+
Bo as Tabs,
|
|
160
|
+
Uo as TemplateFilters,
|
|
161
|
+
jo as TemplateForm,
|
|
162
|
+
Xo as TemplatePropertyFilters,
|
|
163
|
+
_o as TextOverflow,
|
|
162
164
|
e as ThemeProvider,
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
165
|
+
Ko as TimelineWidget,
|
|
166
|
+
Zo as ToggleViewButton,
|
|
167
|
+
re as TreeSelect,
|
|
168
|
+
ee as TreeViewFilter,
|
|
169
|
+
pe as Uploader,
|
|
170
|
+
ae as VisuallyHiddenInput,
|
|
171
|
+
fe as Widget,
|
|
170
172
|
z as XYChart,
|
|
171
173
|
tr as alert,
|
|
172
174
|
pr as confirm,
|
|
173
175
|
t as createTheme,
|
|
174
|
-
|
|
175
|
-
|
|
176
|
+
de as notify,
|
|
177
|
+
Ce as removeNotification
|
|
176
178
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hybridcore/ui",
|
|
3
3
|
"description": "Hybrid Core UI Library",
|
|
4
|
-
"version": "1.6.
|
|
4
|
+
"version": "1.6.4",
|
|
5
5
|
"author": "Hybrid Core",
|
|
6
6
|
"license": "ISC",
|
|
7
7
|
"type": "module",
|
|
@@ -55,7 +55,8 @@
|
|
|
55
55
|
"react-number-format": "^5.3.4",
|
|
56
56
|
"react-phone-number-input": "^3.3.7",
|
|
57
57
|
"react-select": "^5.8.0",
|
|
58
|
-
"react-sortablejs": "^6.1.4"
|
|
58
|
+
"react-sortablejs": "^6.1.4",
|
|
59
|
+
"sortablejs": "^1"
|
|
59
60
|
},
|
|
60
61
|
"dependencies": {
|
|
61
62
|
"@amcharts/amcharts5": "^5.14.4",
|
|
@@ -98,6 +99,7 @@
|
|
|
98
99
|
"@types/react": "^18.3.10",
|
|
99
100
|
"@types/react-color": "^3.0.12",
|
|
100
101
|
"@types/react-dom": "^18.3.0",
|
|
102
|
+
"@types/sortablejs": "^1",
|
|
101
103
|
"@types/terraformer__wkt": "^2",
|
|
102
104
|
"@vitejs/plugin-react": "^4.3.2",
|
|
103
105
|
"@wojtekmaj/react-daterange-picker": "^5.5.0",
|
|
@@ -123,6 +125,7 @@
|
|
|
123
125
|
"react-phone-number-input": "^3.3.7",
|
|
124
126
|
"react-select": "^5.8.0",
|
|
125
127
|
"react-sortablejs": "^6.1.4",
|
|
128
|
+
"sortablejs": "^1",
|
|
126
129
|
"storybook": "^8.3.5",
|
|
127
130
|
"typescript": "^5.5.3",
|
|
128
131
|
"typescript-eslint": "^8.7.0",
|