@ztwoint/z-ui 0.1.115 → 0.1.116
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/chart/chart.d.ts +4 -0
- package/dist/components/chart/chart.js +25 -0
- package/dist/components/chart/index.d.ts +2 -0
- package/dist/components/chart-card/builders/bar-chart-builder.d.ts +3 -0
- package/dist/components/chart-card/builders/bar-chart-builder.js +43 -0
- package/dist/components/chart-card/builders/chart-builder-factory.d.ts +5 -0
- package/dist/components/chart-card/builders/chart-builder-factory.js +23 -0
- package/dist/components/chart-card/builders/line-chart-builder.d.ts +3 -0
- package/dist/components/chart-card/builders/line-chart-builder.js +53 -0
- package/dist/components/chart-card/builders/pie-chart-builder.d.ts +3 -0
- package/dist/components/chart-card/builders/pie-chart-builder.js +71 -0
- package/dist/components/chart-card/chart-card-states.d.ts +10 -0
- package/dist/components/chart-card/chart-card-states.js +93 -0
- package/dist/components/chart-card/chart-card.config.types.d.ts +99 -0
- package/dist/components/chart-card/chart-card.d.ts +2 -0
- package/dist/components/chart-card/chart-card.js +72 -0
- package/dist/components/chart-card/chart-card.types.d.ts +12 -0
- package/dist/components/chart-card/config/colors.d.ts +29 -0
- package/dist/components/chart-card/config/colors.js +49 -0
- package/dist/components/chart-card/config/defaults.d.ts +164 -0
- package/dist/components/chart-card/config/defaults.js +156 -0
- package/dist/components/chart-card/index.d.ts +10 -0
- package/dist/components/chart-card/validators/config-validator.d.ts +7 -0
- package/dist/components/chart-card/validators/config-validator.js +40 -0
- package/dist/components/table/components/cell/avatar-cell.js +5 -2
- package/dist/components/table/table-provider.js +3 -0
- package/dist/components/table-card/table-card.js +11 -8
- package/dist/css/styles/tailwind.css +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +153 -130
- package/dist/types/components/chart/chart.d.ts +4 -0
- package/dist/types/components/chart/index.d.ts +2 -0
- package/dist/types/components/chart-card/builders/bar-chart-builder.d.ts +3 -0
- package/dist/types/components/chart-card/builders/chart-builder-factory.d.ts +5 -0
- package/dist/types/components/chart-card/builders/line-chart-builder.d.ts +3 -0
- package/dist/types/components/chart-card/builders/pie-chart-builder.d.ts +3 -0
- package/dist/types/components/chart-card/chart-card-states.d.ts +10 -0
- package/dist/types/components/chart-card/chart-card.config.types.d.ts +99 -0
- package/dist/types/components/chart-card/chart-card.d.ts +2 -0
- package/dist/types/components/chart-card/chart-card.types.d.ts +12 -0
- package/dist/types/components/chart-card/config/colors.d.ts +29 -0
- package/dist/types/components/chart-card/config/defaults.d.ts +164 -0
- package/dist/types/components/chart-card/index.d.ts +10 -0
- package/dist/types/components/chart-card/validators/config-validator.d.ts +7 -0
- package/dist/types/index.d.ts +2 -0
- package/package.json +3 -1
package/dist/index.d.ts
CHANGED
|
@@ -27,6 +27,8 @@ export * from './components/assets/icons';
|
|
|
27
27
|
export * from './components/segmented-control';
|
|
28
28
|
export * from './components/popover/popover';
|
|
29
29
|
export * from './components/dynamic-table';
|
|
30
|
+
export * from './components/chart';
|
|
31
|
+
export * from './components/chart-card';
|
|
30
32
|
export * from './components/radio-card/radio-card';
|
|
31
33
|
export * from './lib/theme.hook';
|
|
32
34
|
export * from './lib/utils';
|
package/dist/index.js
CHANGED
|
@@ -4,29 +4,29 @@ import { AlertCirclesIcon as m } from "./components/alert/icons/circles-icon.js"
|
|
|
4
4
|
import { Button as x, buttonVariants as i } from "./components/button/button.js";
|
|
5
5
|
import { Z2SideNavBarProvider as Z } from "./components/collapsible-side-nav-bar/side-nav-bar-provider.js";
|
|
6
6
|
import { Z2SideNavBar as s, Z2SidebarVariants as b } from "./components/collapsible-side-nav-bar/side-nav-bar.js";
|
|
7
|
-
import { Z2SideNavBarHeader as
|
|
8
|
-
import { Z2SideNavBarContent as
|
|
7
|
+
import { Z2SideNavBarHeader as S } from "./components/collapsible-side-nav-bar/side-nav-bar-header.js";
|
|
8
|
+
import { Z2SideNavBarContent as I } from "./components/collapsible-side-nav-bar/side-nav-bar-content.js";
|
|
9
9
|
import { Z2SideNavBarFooter as g } from "./components/collapsible-side-nav-bar/side-nav-bar-footer.js";
|
|
10
|
-
import { Z2SideNavBarGroup as
|
|
11
|
-
import { Z2SideNavBarItem as
|
|
12
|
-
import { Z2SideNavBarSeparator as
|
|
13
|
-
import { useZ2SideNavBar as
|
|
10
|
+
import { Z2SideNavBarGroup as v } from "./components/collapsible-side-nav-bar/side-nav-bar-group.js";
|
|
11
|
+
import { Z2SideNavBarItem as h } from "./components/collapsible-side-nav-bar/side-nav-bar-item.js";
|
|
12
|
+
import { Z2SideNavBarSeparator as R } from "./components/collapsible-side-nav-bar/side-nav-bar-separator.js";
|
|
13
|
+
import { useZ2SideNavBar as M } from "./components/collapsible-side-nav-bar/context.js";
|
|
14
14
|
import { Z2Popover as y } from "./components/collapsible-side-nav-bar/popover/popover.js";
|
|
15
15
|
import "react/jsx-runtime";
|
|
16
|
-
import { default as
|
|
17
|
-
import { default as
|
|
18
|
-
import { default as
|
|
19
|
-
import { default as
|
|
16
|
+
import { default as k, default as H } from "./components/assets/icons/sub-nav-indicator.js";
|
|
17
|
+
import { default as O } from "./components/assets/icons/circles-icon.js";
|
|
18
|
+
import { default as _, default as G } from "./components/assets/icons/database-copy.js";
|
|
19
|
+
import { default as V, default as U } from "./components/assets/icons/window-left-copy.js";
|
|
20
20
|
import { default as z, default as J } from "./components/assets/icons/sidebar-left-show-copy.js";
|
|
21
21
|
import { SIDEBAR_WIDTH as Y, SIDEBAR_WIDTH_COLLAPSED as j } from "./components/collapsible-side-nav-bar/constants.js";
|
|
22
22
|
import { CountryFlags as K } from "./components/country-flags/country-flags.js";
|
|
23
23
|
import { Z2Checkbox as oo } from "./components/checkbox/checkbox.js";
|
|
24
24
|
import { Z2Dialog as ro, Z2DialogClose as to, Z2DialogContent as ao, Z2DialogDescription as po, Z2DialogFooter as lo, Z2DialogHeader as no, Z2DialogOverlay as fo, Z2DialogPortal as mo, Z2DialogTitle as xo, Z2DialogTrigger as io } from "./components/dialog/dialog.js";
|
|
25
|
-
import { DropdownContext as Zo, Z2Dropdown as co, Z2DropdownContent as so, Z2DropdownInput as bo, Z2DropdownItem as
|
|
26
|
-
import { Z2DropdownMenu as wo, Z2DropdownMenuCheckboxItem as
|
|
27
|
-
import { FileUploadArea as
|
|
28
|
-
import { DEFAULT_ACCEPT as
|
|
29
|
-
import { Input as
|
|
25
|
+
import { DropdownContext as Zo, Z2Dropdown as co, Z2DropdownContent as so, Z2DropdownInput as bo, Z2DropdownItem as Co, Z2DropdownSub as So, Z2DropdownSubContent as To, Z2DropdownSubItem as Io, Z2DropdownSubTrigger as Do } from "./components/dropdown/z2-dropdown.js";
|
|
26
|
+
import { Z2DropdownMenu as wo, Z2DropdownMenuCheckboxItem as vo, Z2DropdownMenuContent as Bo, Z2DropdownMenuGroup as ho, Z2DropdownMenuItem as Lo, Z2DropdownMenuLabel as Ro, Z2DropdownMenuPortal as Po, Z2DropdownMenuRadioGroup as Mo, Z2DropdownMenuRadioItem as Ao, Z2DropdownMenuSeparator as yo, Z2DropdownMenuShortcut as Eo, Z2DropdownMenuSub as ko, Z2DropdownMenuSubContent as Ho, Z2DropdownMenuSubTrigger as No, Z2DropdownMenuTrigger as Oo } from "./components/dropdown-menu/z2-dropdown-menu.js";
|
|
27
|
+
import { FileUploadArea as _o } from "./components/file-upload-area/file-upload-area.js";
|
|
28
|
+
import { DEFAULT_ACCEPT as Wo } from "./components/file-upload-area/file-upload-area.const.js";
|
|
29
|
+
import { Input as Uo } from "./components/input/input.js";
|
|
30
30
|
import { NavHeader as zo } from "./components/nav-header/nav-header.js";
|
|
31
31
|
import { NavItem as Qo } from "./components/nav-header/nav-item/nav-item.js";
|
|
32
32
|
import { Z2Select as jo, Z2SelectContent as qo, Z2SelectGroup as Ko, Z2SelectItem as $o, Z2SelectLabel as oe, Z2SelectScrollDownButton as ee, Z2SelectScrollUpButton as re, Z2SelectSeparator as te, Z2SelectTrigger as ae, Z2SelectValue as pe } from "./components/select/z2-select.js";
|
|
@@ -34,18 +34,18 @@ import { Z2Stepper as ne } from "./components/stepper/stepper.js";
|
|
|
34
34
|
import { Z2StepperItem as me } from "./components/stepper-item/stepper-item.js";
|
|
35
35
|
import { Z2Tabs as xe, Z2TabsContent as ie, Z2TabsList as ue, Z2TabsTrigger as Ze } from "./components/tab/tab.js";
|
|
36
36
|
import { Table as se, TableProvider as be } from "./components/table/table-provider.js";
|
|
37
|
-
import { TableBody as
|
|
38
|
-
import { extractCellValue as
|
|
37
|
+
import { TableBody as Se } from "./components/table/table.js";
|
|
38
|
+
import { extractCellValue as Ie } from "./components/table/table.utils.js";
|
|
39
39
|
import { DEFAULT_EMPTY_MESSAGE as ge, TABLE_CSS_CLASSES as we } from "./components/table/table.const.js";
|
|
40
|
-
import { TableContext as
|
|
41
|
-
import { TableCell as
|
|
42
|
-
import { NumberCell as
|
|
40
|
+
import { TableContext as Be, useTableContext as he } from "./components/table/table.context.js";
|
|
41
|
+
import { TableCell as Re } from "./components/table/components/table-cell.js";
|
|
42
|
+
import { NumberCell as Me } from "./components/table/components/cell/number-cell.js";
|
|
43
43
|
import { BooleanCell as ye } from "./components/table/components/cell/boolean-cell.js";
|
|
44
|
-
import { LinkCell as
|
|
44
|
+
import { LinkCell as ke } from "./components/table/components/cell/link-cell.js";
|
|
45
45
|
import { DescriptionCell as Ne } from "./components/table/components/cell/description-cell.js";
|
|
46
|
-
import { AvatarCell as
|
|
47
|
-
import { LabelCell as
|
|
48
|
-
import { TableHeader as
|
|
46
|
+
import { AvatarCell as Fe } from "./components/table/components/cell/avatar-cell.js";
|
|
47
|
+
import { LabelCell as Ge } from "./components/table/components/cell/label-cell.js";
|
|
48
|
+
import { TableHeader as Ve } from "./components/table/components/table-header/table-header.js";
|
|
49
49
|
import { default as Xe } from "./components/assets/icons/chevron-down.js";
|
|
50
50
|
import { TableRow as Je } from "./components/table/components/table-row.js";
|
|
51
51
|
import { TableMessageState as Ye } from "./components/table/components/table-message-state.js";
|
|
@@ -61,14 +61,14 @@ import { PaginationQuickJumper as ur } from "./components/table/components/pagin
|
|
|
61
61
|
import "react";
|
|
62
62
|
import { Z2Tooltip as cr } from "./components/tooltip/tooltip.js";
|
|
63
63
|
import { default as br } from "./components/table-card/table-card.js";
|
|
64
|
-
import { Badge as
|
|
64
|
+
import { Badge as Sr, badgeVariants as Tr } from "./components/badge/badge.js";
|
|
65
65
|
import { Avatar as Dr, AvatarWithLabel as gr } from "./components/avatar/avatar.js";
|
|
66
|
-
import { Z2TextPreset as
|
|
67
|
-
import { ColumnReOrder as
|
|
68
|
-
import { default as
|
|
69
|
-
import { Z2Breadcrumb as
|
|
70
|
-
import { Z2RadioGroup as
|
|
71
|
-
import { default as
|
|
66
|
+
import { Z2TextPreset as vr } from "./components/text-preset/text-preset.js";
|
|
67
|
+
import { ColumnReOrder as hr } from "./components/column-reorder/column-reorder.js";
|
|
68
|
+
import { default as Rr } from "./components/tree-checkbox-select/TreeCheckboxSelect.js";
|
|
69
|
+
import { Z2Breadcrumb as Mr, Z2BreadcrumbEllipsis as Ar, Z2BreadcrumbItem as yr, Z2BreadcrumbLink as Er, Z2BreadcrumbList as kr, Z2BreadcrumbPage as Hr, Z2BreadcrumbSeparator as Nr } from "./components/breadcrumb/z2-breadcrumb.js";
|
|
70
|
+
import { Z2RadioGroup as Fr, Z2RadioGroupIndicator as _r, Z2RadioGroupItem as Gr } from "./components/radio/z2-radio.js";
|
|
71
|
+
import { default as Vr } from "./components/assets/icons/apartment-building.js";
|
|
72
72
|
import { Check as Xr } from "./components/assets/icons/check.js";
|
|
73
73
|
import { default as Jr } from "./components/assets/icons/chevron-left.js";
|
|
74
74
|
import { default as Yr } from "./components/assets/icons/chevron-right.js";
|
|
@@ -83,19 +83,19 @@ import { InfoIcon as xt } from "./components/assets/icons/info-icon.js";
|
|
|
83
83
|
import { default as ut } from "./components/assets/icons/left-arrow.js";
|
|
84
84
|
import { default as ct } from "./components/assets/icons/link.js";
|
|
85
85
|
import { default as bt } from "./components/assets/icons/list-tree.js";
|
|
86
|
-
import { default as
|
|
87
|
-
import { Minus as
|
|
86
|
+
import { default as St } from "./components/assets/icons/media-record.js";
|
|
87
|
+
import { Minus as It } from "./components/assets/icons/minus.js";
|
|
88
88
|
import { default as gt } from "./components/assets/icons/octagon-warning-Copy.js";
|
|
89
|
-
import { default as
|
|
90
|
-
import { default as
|
|
91
|
-
import { default as
|
|
92
|
-
import { default as
|
|
89
|
+
import { default as vt } from "./components/assets/icons/pin.js";
|
|
90
|
+
import { default as ht } from "./components/assets/icons/sitemap.js";
|
|
91
|
+
import { default as Rt } from "./components/assets/icons/slider.js";
|
|
92
|
+
import { default as Mt } from "./components/assets/icons/upload.js";
|
|
93
93
|
import { default as yt } from "./components/assets/icons/vector.js";
|
|
94
|
-
import { XMark as
|
|
94
|
+
import { XMark as kt } from "./components/assets/icons/x-mark.js";
|
|
95
95
|
import { default as Nt } from "./components/assets/icons/x.js";
|
|
96
|
-
import { default as
|
|
97
|
-
import { default as
|
|
98
|
-
import { default as
|
|
96
|
+
import { default as Ft } from "./components/assets/icons/z2-icon.js";
|
|
97
|
+
import { default as Gt } from "./components/assets/icons/z2-slash.js";
|
|
98
|
+
import { default as Vt } from "./components/assets/icons/z2data.js";
|
|
99
99
|
import { default as Xt } from "./components/assets/icons/vector_3.js";
|
|
100
100
|
import { default as Jt } from "./components/assets/icons/table-cols-2.js";
|
|
101
101
|
import { default as Yt } from "./components/assets/icons/triangle-warning.js";
|
|
@@ -107,42 +107,53 @@ import { default as pa } from "./components/assets/icons/eraser.js";
|
|
|
107
107
|
import { SegmentedControl as na } from "./components/segmented-control/controller.js";
|
|
108
108
|
import { SegmentedControlItem as ma } from "./components/segmented-control/item.js";
|
|
109
109
|
import { Popover as xa, PopoverAnchor as ia, PopoverContent as ua, PopoverTrigger as Za } from "./components/popover/popover.js";
|
|
110
|
-
import { Z2Table as sa, Z2TableBase as ba, Z2TableBody as
|
|
111
|
-
import { Z2TableContainer as
|
|
112
|
-
import { Z2TablePagination as
|
|
113
|
-
import { Z2TableColumnHeader as
|
|
114
|
-
import {
|
|
115
|
-
import {
|
|
116
|
-
import {
|
|
117
|
-
import {
|
|
118
|
-
import {
|
|
110
|
+
import { Z2Table as sa, Z2TableBase as ba, Z2TableBody as Ca, Z2TableBodyRow as Sa, Z2TableBodyRowCell as Ta, Z2TableBodyRowExpandded as Ia, Z2TableBodyRowSkeleton as Da, Z2TableBodyRowSkeletonCell as ga, Z2TableEmpty as wa, Z2TableHead as va, Z2TableHeadRow as Ba, Z2TableHeadRowCell as ha, Z2TableHeadRowCellResize as La, Z2TableLoader as Ra, Z2TableRowSelect as Pa, Z2TableRowSelectAll as Ma, Z2TableRowSpacer as Aa } from "./components/dynamic-table/z2-table.js";
|
|
111
|
+
import { Z2TableContainer as Ea, Z2TableProvider as ka, Z2TableRoot as Ha, useZ2Table as Na } from "./components/dynamic-table/z2-table-context.js";
|
|
112
|
+
import { Z2TablePagination as Fa } from "./components/dynamic-table/z2-table-pagination.js";
|
|
113
|
+
import { Z2TableColumnHeader as Ga } from "./components/dynamic-table/z2-column-header.js";
|
|
114
|
+
import { Chart as Va } from "./components/chart/chart.js";
|
|
115
|
+
import { ChartCard as Xa } from "./components/chart-card/chart-card.js";
|
|
116
|
+
import { EmptyState as Ja, ErrorState as Qa, LoadingState as Ya } from "./components/chart-card/chart-card-states.js";
|
|
117
|
+
import { COLOR_PALETTES as qa, UI_COLORS as Ka, getThemePalette as $a } from "./components/chart-card/config/colors.js";
|
|
118
|
+
import { validateChartConfig as ep, validateChartData as rp } from "./components/chart-card/validators/config-validator.js";
|
|
119
|
+
import { buildBarChartOptions as ap } from "./components/chart-card/builders/bar-chart-builder.js";
|
|
120
|
+
import { buildLineChartOptions as lp } from "./components/chart-card/builders/line-chart-builder.js";
|
|
121
|
+
import { buildChartOptions as fp, isChartTypeSupported as mp, registeredChartTypes as dp } from "./components/chart-card/builders/chart-builder-factory.js";
|
|
122
|
+
import { Z2RadioCard as ip } from "./components/radio-card/radio-card.js";
|
|
123
|
+
import { useTheme as Zp } from "./lib/theme.hook.js";
|
|
124
|
+
import { cn as sp } from "./lib/utils.js";
|
|
125
|
+
import { Z2PopoverTrigger as Cp } from "./components/collapsible-side-nav-bar/popover/popover-trigger.js";
|
|
126
|
+
import { Z2PopoverContent as Tp } from "./components/collapsible-side-nav-bar/popover/popover-content.js";
|
|
119
127
|
export {
|
|
120
128
|
p as Alert,
|
|
121
129
|
m as AlertCirclesIcon,
|
|
122
130
|
l as AlertDescription,
|
|
123
131
|
n as AlertTitle,
|
|
124
|
-
|
|
132
|
+
Vr as ApartmentBuildingIcon,
|
|
125
133
|
qt as ArrowLeftIcon,
|
|
126
134
|
Dr as Avatar,
|
|
127
|
-
|
|
135
|
+
Fe as AvatarCell,
|
|
128
136
|
gr as AvatarWithLabel,
|
|
129
|
-
|
|
137
|
+
Sr as Badge,
|
|
130
138
|
ye as BooleanCell,
|
|
131
139
|
x as Button,
|
|
140
|
+
qa as COLOR_PALETTES,
|
|
132
141
|
ta as ChainIcon,
|
|
142
|
+
Va as Chart,
|
|
143
|
+
Xa as ChartCard,
|
|
133
144
|
Xr as CheckIcon,
|
|
134
145
|
Xe as ChevronDownIcon,
|
|
135
146
|
Jr as ChevronLeftIcon,
|
|
136
147
|
Yr as ChevronRightIcon,
|
|
137
148
|
qr as CircleCheckFilledIcon,
|
|
138
149
|
$r as CircleCheckIcon,
|
|
139
|
-
|
|
140
|
-
|
|
150
|
+
O as CirclesIcon,
|
|
151
|
+
hr as ColumnReOrder,
|
|
141
152
|
K as CountryFlags,
|
|
142
|
-
|
|
153
|
+
Wo as DEFAULT_ACCEPT,
|
|
143
154
|
ge as DEFAULT_EMPTY_MESSAGE,
|
|
144
|
-
|
|
145
|
-
|
|
155
|
+
_ as DatabaseCopy,
|
|
156
|
+
G as DatabaseCopyIcon,
|
|
146
157
|
ea as DescendingSortingIcon,
|
|
147
158
|
Ne as DescriptionCell,
|
|
148
159
|
et as DotsIcon,
|
|
@@ -150,27 +161,30 @@ export {
|
|
|
150
161
|
pt as DoubleChevronRightIcon,
|
|
151
162
|
nt as DragHandleIcon,
|
|
152
163
|
Zo as DropdownContext,
|
|
164
|
+
Ja as EmptyState,
|
|
153
165
|
pa as EraserIcon,
|
|
154
|
-
|
|
166
|
+
Qa as ErrorState,
|
|
167
|
+
_o as FileUploadArea,
|
|
155
168
|
$t as FilterIcon,
|
|
156
169
|
mt as HomeIcon,
|
|
157
170
|
xt as InfoIcon,
|
|
158
|
-
|
|
159
|
-
|
|
171
|
+
Uo as Input,
|
|
172
|
+
Ge as LabelCell,
|
|
160
173
|
ut as LeftArrowIcon,
|
|
161
|
-
|
|
174
|
+
ke as LinkCell,
|
|
162
175
|
ct as LinkIcon,
|
|
163
176
|
bt as ListTreeIcon,
|
|
177
|
+
Ya as LoadingState,
|
|
164
178
|
mr as MagnifierIcon,
|
|
165
|
-
|
|
166
|
-
|
|
179
|
+
St as MediaRecordIcon,
|
|
180
|
+
It as MinusIcon,
|
|
167
181
|
zo as NavHeader,
|
|
168
182
|
Qo as NavItem,
|
|
169
|
-
|
|
183
|
+
Me as NumberCell,
|
|
170
184
|
gt as OctagonWarningIcon,
|
|
171
185
|
xr as PaginationInfo,
|
|
172
186
|
ur as PaginationQuickJumper,
|
|
173
|
-
|
|
187
|
+
vt as PinIcon,
|
|
174
188
|
xa as Popover,
|
|
175
189
|
ia as PopoverAnchor,
|
|
176
190
|
ua as PopoverContent,
|
|
@@ -181,20 +195,20 @@ export {
|
|
|
181
195
|
ma as SegmentedControlItem,
|
|
182
196
|
z as SidebarLeftShowCopy,
|
|
183
197
|
J as SidebarLeftShowCopyIcon,
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
198
|
+
ht as SitemapIcon,
|
|
199
|
+
Rt as SliderIcon,
|
|
200
|
+
k as SubNavIndicator,
|
|
187
201
|
H as SubNavIndicatorIcon,
|
|
188
202
|
we as TABLE_CSS_CLASSES,
|
|
189
203
|
se as Table,
|
|
190
|
-
|
|
204
|
+
Se as TableBody,
|
|
191
205
|
br as TableCard,
|
|
192
|
-
|
|
206
|
+
Re as TableCell,
|
|
193
207
|
Jt as TableCols2Icon,
|
|
194
|
-
|
|
208
|
+
Be as TableContext,
|
|
195
209
|
pr as TableFooter,
|
|
196
210
|
nr as TableFooterContent,
|
|
197
|
-
|
|
211
|
+
Ve as TableHeader,
|
|
198
212
|
tr as TableHeaderContent,
|
|
199
213
|
er as TableHeaderWrapper,
|
|
200
214
|
qe as TableLoadingState,
|
|
@@ -202,24 +216,25 @@ export {
|
|
|
202
216
|
$e as TablePagination,
|
|
203
217
|
be as TableProvider,
|
|
204
218
|
Je as TableRow,
|
|
205
|
-
|
|
219
|
+
Rr as TreeCheckboxSelect,
|
|
206
220
|
Yt as TriangleWarningIcon,
|
|
207
|
-
|
|
221
|
+
Ka as UI_COLORS,
|
|
222
|
+
Mt as UploadIcon,
|
|
208
223
|
Xt as Vector3Icon,
|
|
209
224
|
yt as VectorIcon,
|
|
210
|
-
|
|
211
|
-
|
|
225
|
+
V as WindowLeftCopy,
|
|
226
|
+
U as WindowLeftCopyIcon,
|
|
212
227
|
Nt as XIcon,
|
|
213
|
-
|
|
214
|
-
|
|
228
|
+
kt as XMarkIcon,
|
|
229
|
+
Mr as Z2Breadcrumb,
|
|
215
230
|
Ar as Z2BreadcrumbEllipsis,
|
|
216
231
|
yr as Z2BreadcrumbItem,
|
|
217
|
-
|
|
218
|
-
|
|
232
|
+
Er as Z2BreadcrumbLink,
|
|
233
|
+
kr as Z2BreadcrumbList,
|
|
219
234
|
Hr as Z2BreadcrumbPage,
|
|
220
235
|
Nr as Z2BreadcrumbSeparator,
|
|
221
236
|
oo as Z2Checkbox,
|
|
222
|
-
|
|
237
|
+
Vt as Z2DataIcon,
|
|
223
238
|
ro as Z2Dialog,
|
|
224
239
|
to as Z2DialogClose,
|
|
225
240
|
ao as Z2DialogContent,
|
|
@@ -233,34 +248,34 @@ export {
|
|
|
233
248
|
co as Z2Dropdown,
|
|
234
249
|
so as Z2DropdownContent,
|
|
235
250
|
bo as Z2DropdownInput,
|
|
236
|
-
|
|
251
|
+
Co as Z2DropdownItem,
|
|
237
252
|
wo as Z2DropdownMenu,
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
253
|
+
vo as Z2DropdownMenuCheckboxItem,
|
|
254
|
+
Bo as Z2DropdownMenuContent,
|
|
255
|
+
ho as Z2DropdownMenuGroup,
|
|
256
|
+
Lo as Z2DropdownMenuItem,
|
|
257
|
+
Ro as Z2DropdownMenuLabel,
|
|
243
258
|
Po as Z2DropdownMenuPortal,
|
|
244
|
-
|
|
259
|
+
Mo as Z2DropdownMenuRadioGroup,
|
|
245
260
|
Ao as Z2DropdownMenuRadioItem,
|
|
246
261
|
yo as Z2DropdownMenuSeparator,
|
|
247
|
-
|
|
248
|
-
|
|
262
|
+
Eo as Z2DropdownMenuShortcut,
|
|
263
|
+
ko as Z2DropdownMenuSub,
|
|
249
264
|
Ho as Z2DropdownMenuSubContent,
|
|
250
265
|
No as Z2DropdownMenuSubTrigger,
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
266
|
+
Oo as Z2DropdownMenuTrigger,
|
|
267
|
+
So as Z2DropdownSub,
|
|
268
|
+
To as Z2DropdownSubContent,
|
|
269
|
+
Io as Z2DropdownSubItem,
|
|
255
270
|
Do as Z2DropdownSubTrigger,
|
|
256
|
-
|
|
271
|
+
Ft as Z2Icon,
|
|
257
272
|
y as Z2Popover,
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
273
|
+
Tp as Z2PopoverContent,
|
|
274
|
+
Cp as Z2PopoverTrigger,
|
|
275
|
+
ip as Z2RadioCard,
|
|
276
|
+
Fr as Z2RadioGroup,
|
|
277
|
+
_r as Z2RadioGroupIndicator,
|
|
278
|
+
Gr as Z2RadioGroupItem,
|
|
264
279
|
jo as Z2Select,
|
|
265
280
|
qo as Z2SelectContent,
|
|
266
281
|
Ko as Z2SelectGroup,
|
|
@@ -272,51 +287,59 @@ export {
|
|
|
272
287
|
ae as Z2SelectTrigger,
|
|
273
288
|
pe as Z2SelectValue,
|
|
274
289
|
s as Z2SideNavBar,
|
|
275
|
-
|
|
290
|
+
I as Z2SideNavBarContent,
|
|
276
291
|
g as Z2SideNavBarFooter,
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
292
|
+
v as Z2SideNavBarGroup,
|
|
293
|
+
S as Z2SideNavBarHeader,
|
|
294
|
+
h as Z2SideNavBarItem,
|
|
280
295
|
Z as Z2SideNavBarProvider,
|
|
281
|
-
|
|
296
|
+
R as Z2SideNavBarSeparator,
|
|
282
297
|
b as Z2SidebarVariants,
|
|
283
|
-
|
|
298
|
+
Gt as Z2SlashIcon,
|
|
284
299
|
ne as Z2Stepper,
|
|
285
300
|
me as Z2StepperItem,
|
|
286
301
|
sa as Z2Table,
|
|
287
302
|
ba as Z2TableBase,
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
303
|
+
Ca as Z2TableBody,
|
|
304
|
+
Sa as Z2TableBodyRow,
|
|
305
|
+
Ta as Z2TableBodyRowCell,
|
|
306
|
+
Ia as Z2TableBodyRowExpandded,
|
|
292
307
|
Da as Z2TableBodyRowSkeleton,
|
|
293
308
|
ga as Z2TableBodyRowSkeletonCell,
|
|
294
|
-
|
|
295
|
-
|
|
309
|
+
Ga as Z2TableColumnHeader,
|
|
310
|
+
Ea as Z2TableContainer,
|
|
296
311
|
wa as Z2TableEmpty,
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
312
|
+
va as Z2TableHead,
|
|
313
|
+
Ba as Z2TableHeadRow,
|
|
314
|
+
ha as Z2TableHeadRowCell,
|
|
315
|
+
La as Z2TableHeadRowCellResize,
|
|
316
|
+
Ra as Z2TableLoader,
|
|
317
|
+
Fa as Z2TablePagination,
|
|
318
|
+
ka as Z2TableProvider,
|
|
304
319
|
Ha as Z2TableRoot,
|
|
305
320
|
Pa as Z2TableRowSelect,
|
|
306
|
-
|
|
321
|
+
Ma as Z2TableRowSelectAll,
|
|
307
322
|
Aa as Z2TableRowSpacer,
|
|
308
323
|
xe as Z2Tabs,
|
|
309
324
|
ie as Z2TabsContent,
|
|
310
325
|
ue as Z2TabsList,
|
|
311
326
|
Ze as Z2TabsTrigger,
|
|
312
|
-
|
|
327
|
+
vr as Z2TextPreset,
|
|
313
328
|
cr as Z2Tooltip,
|
|
314
|
-
|
|
329
|
+
Tr as badgeVariants,
|
|
330
|
+
ap as buildBarChartOptions,
|
|
331
|
+
fp as buildChartOptions,
|
|
332
|
+
lp as buildLineChartOptions,
|
|
315
333
|
i as buttonVariants,
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
334
|
+
sp as cn,
|
|
335
|
+
Ie as extractCellValue,
|
|
336
|
+
$a as getThemePalette,
|
|
337
|
+
mp as isChartTypeSupported,
|
|
338
|
+
dp as registeredChartTypes,
|
|
339
|
+
he as useTableContext,
|
|
340
|
+
Zp as useTheme,
|
|
341
|
+
M as useZ2SideNavBar,
|
|
342
|
+
Na as useZ2Table,
|
|
343
|
+
ep as validateChartConfig,
|
|
344
|
+
rp as validateChartData
|
|
322
345
|
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { EChartsOption } from 'echarts';
|
|
2
|
+
import type { ChartConfig, ChartData, ChartType } from '../chart-card.config.types';
|
|
3
|
+
export declare function buildChartOptions(config: ChartConfig, data: ChartData): EChartsOption;
|
|
4
|
+
export declare function isChartTypeSupported(type: string): type is ChartType;
|
|
5
|
+
export declare const registeredChartTypes: readonly ChartType[];
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare function LoadingState({ height }: {
|
|
2
|
+
height: number;
|
|
3
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
4
|
+
export declare function EmptyState({ height }: {
|
|
5
|
+
height: number;
|
|
6
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare function ErrorState({ height, message }: {
|
|
8
|
+
height: number;
|
|
9
|
+
message: string;
|
|
10
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
export type ChartType = 'line' | 'bar' | 'pie';
|
|
2
|
+
export type LineChartTheme = 'basic' | 'smooth';
|
|
3
|
+
export type BarChartTheme = 'basic' | 'stacked';
|
|
4
|
+
export type PieChartTheme = 'basic' | 'donut';
|
|
5
|
+
export type ChartTheme = LineChartTheme | BarChartTheme | PieChartTheme;
|
|
6
|
+
export interface SeriesStyleConfig {
|
|
7
|
+
color?: string;
|
|
8
|
+
lineWidth?: number;
|
|
9
|
+
pointSize?: number;
|
|
10
|
+
smooth?: boolean;
|
|
11
|
+
barWidth?: number;
|
|
12
|
+
areaStyle?: boolean;
|
|
13
|
+
opacity?: number;
|
|
14
|
+
pieRadius?: [string | number, string | number];
|
|
15
|
+
pieLabelPosition?: 'inside' | 'outside';
|
|
16
|
+
pieLabelRotate?: boolean;
|
|
17
|
+
}
|
|
18
|
+
export interface ChartOptions {
|
|
19
|
+
seriesStyles?: Record<string, SeriesStyleConfig>;
|
|
20
|
+
defaultSeriesStyle?: SeriesStyleConfig;
|
|
21
|
+
title?: {
|
|
22
|
+
show?: boolean;
|
|
23
|
+
position?: 'left' | 'center' | 'right';
|
|
24
|
+
fontSize?: number;
|
|
25
|
+
color?: string;
|
|
26
|
+
};
|
|
27
|
+
legend?: {
|
|
28
|
+
show?: boolean;
|
|
29
|
+
position?: 'top' | 'bottom' | 'left' | 'right';
|
|
30
|
+
align?: 'left' | 'center' | 'right';
|
|
31
|
+
orient?: 'horizontal' | 'vertical';
|
|
32
|
+
};
|
|
33
|
+
tooltip?: {
|
|
34
|
+
show?: boolean;
|
|
35
|
+
trigger?: 'axis' | 'item';
|
|
36
|
+
};
|
|
37
|
+
xAxis?: {
|
|
38
|
+
show?: boolean;
|
|
39
|
+
name?: string;
|
|
40
|
+
nameLocation?: 'start' | 'middle' | 'end';
|
|
41
|
+
gridLines?: boolean;
|
|
42
|
+
labelRotate?: number;
|
|
43
|
+
};
|
|
44
|
+
yAxis?: {
|
|
45
|
+
show?: boolean;
|
|
46
|
+
name?: string;
|
|
47
|
+
nameLocation?: 'start' | 'middle' | 'end';
|
|
48
|
+
min?: number | 'auto';
|
|
49
|
+
max?: number | 'auto';
|
|
50
|
+
gridLines?: boolean;
|
|
51
|
+
};
|
|
52
|
+
grid?: {
|
|
53
|
+
top?: number | string;
|
|
54
|
+
bottom?: number | string;
|
|
55
|
+
left?: number | string;
|
|
56
|
+
right?: number | string;
|
|
57
|
+
};
|
|
58
|
+
animation?: {
|
|
59
|
+
enabled?: boolean;
|
|
60
|
+
duration?: number;
|
|
61
|
+
};
|
|
62
|
+
pie?: {
|
|
63
|
+
center?: [string | number, string | number];
|
|
64
|
+
radius?: [string | number, string | number];
|
|
65
|
+
labelPosition?: 'inside' | 'outside';
|
|
66
|
+
labelRotate?: boolean;
|
|
67
|
+
showLabel?: boolean;
|
|
68
|
+
showLabelLine?: boolean;
|
|
69
|
+
};
|
|
70
|
+
}
|
|
71
|
+
interface BaseChartConfig {
|
|
72
|
+
name: string;
|
|
73
|
+
height?: number;
|
|
74
|
+
width?: string | number;
|
|
75
|
+
ariaLabel?: string;
|
|
76
|
+
options?: ChartOptions;
|
|
77
|
+
}
|
|
78
|
+
export interface LineChartConfig extends BaseChartConfig {
|
|
79
|
+
type: 'line';
|
|
80
|
+
theme: LineChartTheme;
|
|
81
|
+
}
|
|
82
|
+
export interface BarChartConfig extends BaseChartConfig {
|
|
83
|
+
type: 'bar';
|
|
84
|
+
theme: BarChartTheme;
|
|
85
|
+
}
|
|
86
|
+
export interface PieChartConfig extends BaseChartConfig {
|
|
87
|
+
type: 'pie';
|
|
88
|
+
theme: PieChartTheme;
|
|
89
|
+
}
|
|
90
|
+
export type ChartConfig = LineChartConfig | BarChartConfig | PieChartConfig;
|
|
91
|
+
export interface ChartSeries {
|
|
92
|
+
name: string;
|
|
93
|
+
values: number[];
|
|
94
|
+
}
|
|
95
|
+
export interface ChartData {
|
|
96
|
+
labels: string[];
|
|
97
|
+
series: ChartSeries[];
|
|
98
|
+
}
|
|
99
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { CSSProperties } from 'react';
|
|
2
|
+
import type { EChartsReactProps } from 'echarts-for-react';
|
|
3
|
+
import type { ChartConfig, ChartData } from './chart-card.config.types';
|
|
4
|
+
export interface ChartCardProps {
|
|
5
|
+
config: ChartConfig;
|
|
6
|
+
data: ChartData;
|
|
7
|
+
loading?: boolean;
|
|
8
|
+
error?: string;
|
|
9
|
+
className?: string;
|
|
10
|
+
style?: CSSProperties;
|
|
11
|
+
chartProps?: Omit<EChartsReactProps, 'option'>;
|
|
12
|
+
}
|