@carto/ps-react-ui 4.3.0-widgets.0 → 5.0.0-widgets.2
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.js +25 -23
- package/dist/components.js.map +1 -1
- package/dist/error-zHOU_QIB.js +38 -0
- package/dist/error-zHOU_QIB.js.map +1 -0
- package/dist/exports-Cr43OCul.js +51 -0
- package/dist/exports-Cr43OCul.js.map +1 -0
- package/dist/{lasso-tool-BC-rsMMW.js → lasso-tool-CYn3ivf-.js} +165 -183
- package/dist/lasso-tool-CYn3ivf-.js.map +1 -0
- package/dist/no-data-Cz80hEWj.js +61 -0
- package/dist/no-data-Cz80hEWj.js.map +1 -0
- package/dist/options-D9wflre6.js +49 -0
- package/dist/options-D9wflre6.js.map +1 -0
- package/dist/row-C_m1ovHv.js +35 -0
- package/dist/row-C_m1ovHv.js.map +1 -0
- package/dist/series-6xp-KQ0S.js +91 -0
- package/dist/series-6xp-KQ0S.js.map +1 -0
- package/dist/{smart-tooltip-BSlcAkBM.js → smart-tooltip-BEtBaIdz.js} +2 -2
- package/dist/{smart-tooltip-BSlcAkBM.js.map → smart-tooltip-BEtBaIdz.js.map} +1 -1
- package/dist/styles-dOu_pRNb.js +77 -0
- package/dist/styles-dOu_pRNb.js.map +1 -0
- package/dist/tooltip-BDnrRKrp.js +25 -0
- package/dist/tooltip-BDnrRKrp.js.map +1 -0
- package/dist/types/hooks/index.d.ts +2 -0
- package/dist/types/hooks/use-debounce.d.ts +19 -0
- package/dist/types/hooks/use-widget-ref.d.ts +17 -0
- package/dist/types/widgets/_shared/chart-config/config-factory.d.ts +5 -11
- package/dist/types/widgets/_shared/chart-config/option-builders.d.ts +3 -8
- package/dist/types/widgets/actions/change-column/change-column-icon.d.ts +1 -0
- package/dist/types/widgets/actions/change-column/change-column.d.ts +16 -0
- package/dist/types/widgets/actions/change-column/sortable-column-item.d.ts +9 -0
- package/dist/types/widgets/actions/change-column/types.d.ts +19 -0
- package/dist/types/widgets/actions/download/download.d.ts +1 -1
- package/dist/types/widgets/actions/download/exports.d.ts +1 -1
- package/dist/types/widgets/actions/download/types.d.ts +3 -11
- package/dist/types/widgets/actions/fullscreen/fullscreen.d.ts +1 -1
- package/dist/types/widgets/actions/fullscreen/styles.d.ts +6 -0
- package/dist/types/widgets/actions/fullscreen/types.d.ts +8 -9
- package/dist/types/widgets/actions/index.d.ts +14 -1
- package/dist/types/widgets/actions/lock-selection/lock-selection.d.ts +19 -0
- package/dist/types/widgets/actions/lock-selection/types.d.ts +38 -0
- package/dist/types/widgets/actions/relative-data/relative-data.d.ts +18 -0
- package/dist/types/widgets/actions/relative-data/style.d.ts +8 -0
- package/dist/types/widgets/actions/relative-data/types.d.ts +27 -0
- package/dist/types/widgets/actions/relative-data/utils.d.ts +9 -0
- package/dist/types/widgets/actions/relative-data/utils.test.d.ts +1 -0
- package/dist/types/widgets/actions/searcher/searcher-toggle.d.ts +18 -0
- package/dist/types/widgets/actions/searcher/searcher.d.ts +21 -0
- package/dist/types/widgets/actions/searcher/types.d.ts +64 -0
- package/dist/types/widgets/actions/shared/styles.d.ts +11 -0
- package/dist/types/widgets/actions/stack-toggle/grouped-bar-chart-icon.d.ts +1 -0
- package/dist/types/widgets/actions/stack-toggle/stack-toggle.d.ts +16 -0
- package/dist/types/widgets/actions/stack-toggle/types.d.ts +25 -0
- package/dist/types/widgets/actions/zoom-toggle/index.d.ts +2 -0
- package/dist/types/widgets/actions/zoom-toggle/style.d.ts +13 -0
- package/dist/types/widgets/actions/zoom-toggle/types.d.ts +41 -0
- package/dist/types/widgets/actions/zoom-toggle/zoom-toggle.d.ts +18 -0
- package/dist/types/widgets/bar/config.d.ts +5 -4
- package/dist/types/widgets/bar/index.d.ts +2 -2
- package/dist/types/widgets/bar/types.d.ts +6 -12
- package/dist/types/widgets/category/category-ui.d.ts +2 -0
- package/dist/types/widgets/category/components/category-bar.d.ts +7 -0
- package/dist/types/widgets/category/components/category-legend.d.ts +6 -0
- package/dist/types/widgets/category/components/category-row-multi.d.ts +11 -0
- package/dist/types/widgets/category/components/category-row-other.d.ts +6 -0
- package/dist/types/widgets/category/components/category-row-single.d.ts +11 -0
- package/dist/types/widgets/category/components/index.d.ts +10 -0
- package/dist/types/widgets/category/config.d.ts +15 -0
- package/dist/types/widgets/category/index.d.ts +6 -0
- package/dist/types/widgets/category/skeleton.d.ts +1 -0
- package/dist/types/widgets/category/style.d.ts +121 -0
- package/dist/types/widgets/category/types.d.ts +33 -0
- package/dist/types/widgets/echart/echart-ui.d.ts +1 -1
- package/dist/types/widgets/echart/index.d.ts +2 -2
- package/dist/types/widgets/echart/options.d.ts +2 -3
- package/dist/types/widgets/echart/types.d.ts +11 -10
- package/dist/types/widgets/echart/utils.d.ts +22 -16
- package/dist/types/widgets/error/error.d.ts +2 -0
- package/dist/types/widgets/error/index.d.ts +2 -0
- package/dist/types/widgets/error/types.d.ts +12 -0
- package/dist/types/widgets/formula/components/row.d.ts +1 -1
- package/dist/types/widgets/formula/config.d.ts +4 -2
- package/dist/types/widgets/formula/index.d.ts +2 -1
- package/dist/types/widgets/formula/types.d.ts +6 -18
- package/dist/types/widgets/histogram/config.d.ts +5 -4
- package/dist/types/widgets/histogram/index.d.ts +2 -2
- package/dist/types/widgets/histogram/types.d.ts +6 -12
- package/dist/types/widgets/index.d.ts +6 -4
- package/dist/types/widgets/markdown/config.d.ts +4 -2
- package/dist/types/widgets/markdown/index.d.ts +2 -2
- package/dist/types/widgets/markdown/markdown-ui.d.ts +1 -1
- package/dist/types/widgets/markdown/types.d.ts +6 -16
- package/dist/types/widgets/no-data/index.d.ts +2 -0
- package/dist/types/widgets/no-data/no-data.d.ts +35 -0
- package/dist/types/widgets/no-data/style.d.ts +6 -0
- package/dist/types/widgets/no-data/types.d.ts +67 -0
- package/dist/types/widgets/note/note.d.ts +1 -1
- package/dist/types/widgets/note/style.d.ts +12 -1
- package/dist/types/widgets/note/types.d.ts +4 -3
- package/dist/types/widgets/pie/config.d.ts +5 -4
- package/dist/types/widgets/pie/index.d.ts +2 -2
- package/dist/types/widgets/pie/types.d.ts +6 -12
- package/dist/types/widgets/range/config.d.ts +6 -2
- package/dist/types/widgets/range/index.d.ts +2 -1
- package/dist/types/widgets/range/types.d.ts +6 -17
- package/dist/types/widgets/root/index.d.ts +2 -1
- package/dist/types/widgets/root/root.d.ts +1 -1
- package/dist/types/widgets/root/types.d.ts +6 -12
- package/dist/types/widgets/root/utils.d.ts +1 -0
- package/dist/types/widgets/scatterplot/config.d.ts +5 -4
- package/dist/types/widgets/scatterplot/index.d.ts +2 -2
- package/dist/types/widgets/scatterplot/types.d.ts +6 -12
- package/dist/types/widgets/selection-summary/index.d.ts +2 -0
- package/dist/types/widgets/selection-summary/selection-summary.d.ts +2 -0
- package/dist/types/widgets/selection-summary/style.d.ts +9 -0
- package/dist/types/widgets/selection-summary/types.d.ts +13 -0
- package/dist/types/widgets/spread/config.d.ts +10 -2
- package/dist/types/widgets/spread/index.d.ts +2 -1
- package/dist/types/widgets/spread/types.d.ts +6 -18
- package/dist/types/widgets/stores/index.d.ts +2 -0
- package/dist/types/widgets/stores/types.d.ts +179 -12
- package/dist/types/widgets/stores/widget-store.d.ts +2 -27
- package/dist/types/widgets/subheader/index.d.ts +2 -0
- package/dist/types/widgets/subheader/style.d.ts +19 -0
- package/dist/types/widgets/subheader/subheader.d.ts +2 -0
- package/dist/types/widgets/subheader/types.d.ts +10 -0
- package/dist/types/widgets/table/components/cell-header.d.ts +5 -0
- package/dist/types/widgets/table/components/cell.d.ts +16 -0
- package/dist/types/widgets/table/components/index.d.ts +4 -0
- package/dist/types/widgets/table/components/pagination-actions.d.ts +5 -0
- package/dist/types/widgets/table/components/pagination.d.ts +5 -0
- package/dist/types/widgets/table/components/row.d.ts +5 -0
- package/dist/types/widgets/table/config.d.ts +11 -0
- package/dist/types/widgets/table/helpers.d.ts +38 -0
- package/dist/types/widgets/table/helpers.test.d.ts +1 -0
- package/dist/types/widgets/table/hooks/index.d.ts +6 -0
- package/dist/types/widgets/table/hooks/use-pagination.d.ts +45 -0
- package/dist/types/widgets/table/hooks/use-pagination.test.d.ts +1 -0
- package/dist/types/widgets/table/hooks/use-selection.d.ts +32 -0
- package/dist/types/widgets/table/hooks/use-selection.test.d.ts +1 -0
- package/dist/types/widgets/table/hooks/use-sort.d.ts +29 -0
- package/dist/types/widgets/table/hooks/use-sort.test.d.ts +1 -0
- package/dist/types/widgets/table/index.d.ts +13 -0
- package/dist/types/widgets/table/serializer.d.ts +16 -0
- package/dist/types/widgets/table/skeleton.d.ts +10 -0
- package/dist/types/widgets/table/style.d.ts +33 -0
- package/dist/types/widgets/table/table-ui.d.ts +32 -0
- package/dist/types/widgets/table/types.d.ts +201 -0
- package/dist/types/widgets/timeseries/config.d.ts +5 -4
- package/dist/types/widgets/timeseries/index.d.ts +2 -2
- package/dist/types/widgets/timeseries/types.d.ts +6 -12
- package/dist/types/widgets/toolbar-actions/index.d.ts +2 -0
- package/dist/types/widgets/toolbar-actions/styles.d.ts +37 -0
- package/dist/types/widgets/toolbar-actions/toolbar-actions.d.ts +8 -0
- package/dist/types/widgets/toolbar-actions/types.d.ts +45 -0
- package/dist/types/widgets/wrapper/index.d.ts +2 -2
- package/dist/types/widgets/wrapper/styles.d.ts +6 -0
- package/dist/types/widgets/wrapper/types.d.ts +7 -5
- package/dist/types/widgets/wrapper/wrapper-ui.d.ts +1 -1
- package/dist/types/widgets/wrapper/wrapper.d.ts +1 -1
- package/dist/utils-Dv5Z47UQ.js +144 -0
- package/dist/utils-Dv5Z47UQ.js.map +1 -0
- package/dist/widget-store-DNyVElxd.js +190 -0
- package/dist/widget-store-DNyVElxd.js.map +1 -0
- package/dist/widgets/actions.js +826 -6
- package/dist/widgets/actions.js.map +1 -1
- package/dist/widgets/bar.js +189 -4
- package/dist/widgets/bar.js.map +1 -1
- package/dist/widgets/category.js +460 -0
- package/dist/widgets/category.js.map +1 -0
- package/dist/widgets/echart.js +120 -8
- package/dist/widgets/echart.js.map +1 -1
- package/dist/widgets/error.js +5 -0
- package/dist/widgets/error.js.map +1 -0
- package/dist/widgets/formula.js +117 -20
- package/dist/widgets/formula.js.map +1 -1
- package/dist/widgets/histogram.js +172 -4
- package/dist/widgets/histogram.js.map +1 -1
- package/dist/widgets/markdown.js +127 -0
- package/dist/widgets/markdown.js.map +1 -0
- package/dist/widgets/no-data.js +5 -0
- package/dist/widgets/no-data.js.map +1 -0
- package/dist/widgets/note.js +121 -2
- package/dist/widgets/note.js.map +1 -1
- package/dist/widgets/pie.js +213 -4
- package/dist/widgets/pie.js.map +1 -1
- package/dist/widgets/range.js +210 -12
- package/dist/widgets/range.js.map +1 -1
- package/dist/widgets/root.js +65 -2
- package/dist/widgets/root.js.map +1 -1
- package/dist/widgets/scatterplot.js +219 -4
- package/dist/widgets/scatterplot.js.map +1 -1
- package/dist/widgets/selection-summary.js +40 -0
- package/dist/widgets/selection-summary.js.map +1 -0
- package/dist/widgets/skeleton-loader.js +21 -2
- package/dist/widgets/skeleton-loader.js.map +1 -1
- package/dist/widgets/spread.js +162 -17
- package/dist/widgets/spread.js.map +1 -1
- package/dist/widgets/stores.js +5 -0
- package/dist/widgets/stores.js.map +1 -0
- package/dist/widgets/subheader.js +52 -0
- package/dist/widgets/subheader.js.map +1 -0
- package/dist/widgets/table.js +691 -0
- package/dist/widgets/table.js.map +1 -0
- package/dist/widgets/timeseries.js +171 -4
- package/dist/widgets/timeseries.js.map +1 -1
- package/dist/widgets/toolbar-actions.js +6106 -0
- package/dist/widgets/toolbar-actions.js.map +1 -0
- package/dist/widgets/wrapper.js +292 -6
- package/dist/widgets/wrapper.js.map +1 -1
- package/dist/widgets.js +6 -83
- package/dist/widgets.js.map +1 -1
- package/package.json +46 -6
- package/dist/const-BLV7Tvte.js +0 -758
- package/dist/const-BLV7Tvte.js.map +0 -1
- package/dist/download-KroQ0SWg.js +0 -195
- package/dist/download-KroQ0SWg.js.map +0 -1
- package/dist/echart-CqfROFu3.js +0 -214
- package/dist/echart-CqfROFu3.js.map +0 -1
- package/dist/formula-ui-ChzvMEOG.js +0 -52
- package/dist/formula-ui-ChzvMEOG.js.map +0 -1
- package/dist/lasso-tool-BC-rsMMW.js.map +0 -1
- package/dist/markdown-n_tOtoiT.js +0 -27
- package/dist/markdown-n_tOtoiT.js.map +0 -1
- package/dist/markdown-ui-BBrzzd7Y.js +0 -62
- package/dist/markdown-ui-BBrzzd7Y.js.map +0 -1
- package/dist/note-DF-n70TX.js +0 -101
- package/dist/note-DF-n70TX.js.map +0 -1
- package/dist/range-ui-CtUX11Xm.js +0 -146
- package/dist/range-ui-CtUX11Xm.js.map +0 -1
- package/dist/root-L_WZnJY5.js +0 -46
- package/dist/root-L_WZnJY5.js.map +0 -1
- package/dist/row-DQaSxmDV.js +0 -18
- package/dist/row-DQaSxmDV.js.map +0 -1
- package/dist/series-CsyEPq-X.js +0 -83
- package/dist/series-CsyEPq-X.js.map +0 -1
- package/dist/skeleton-BSPcEvfq.js +0 -27
- package/dist/skeleton-BSPcEvfq.js.map +0 -1
- package/dist/skeleton-C4rOYTy-.js +0 -78
- package/dist/skeleton-C4rOYTy-.js.map +0 -1
- package/dist/skeleton-C9Jqc241.js +0 -82
- package/dist/skeleton-C9Jqc241.js.map +0 -1
- package/dist/skeleton-D-zHBBIw.js +0 -64
- package/dist/skeleton-D-zHBBIw.js.map +0 -1
- package/dist/skeleton-DMP-IwaJ.js +0 -109
- package/dist/skeleton-DMP-IwaJ.js.map +0 -1
- package/dist/skeleton-DRorqowB.js +0 -22
- package/dist/skeleton-DRorqowB.js.map +0 -1
- package/dist/skeleton-DsZhv-AH.js +0 -89
- package/dist/skeleton-DsZhv-AH.js.map +0 -1
- package/dist/skeleton-Dx3FCer0.js +0 -13
- package/dist/skeleton-Dx3FCer0.js.map +0 -1
- package/dist/skeleton-QVDdb1c2.js +0 -21
- package/dist/skeleton-QVDdb1c2.js.map +0 -1
- package/dist/skeleton-loader-DWC1-EAx.js +0 -23
- package/dist/skeleton-loader-DWC1-EAx.js.map +0 -1
- package/dist/spread-ui-BjzH190y.js +0 -82
- package/dist/spread-ui-BjzH190y.js.map +0 -1
- package/dist/style-BGeCtQkP.js +0 -19
- package/dist/style-BGeCtQkP.js.map +0 -1
- package/dist/style-C7v1iwqD.js +0 -34
- package/dist/style-C7v1iwqD.js.map +0 -1
- package/dist/styles-cohnxh9F.js +0 -23
- package/dist/styles-cohnxh9F.js.map +0 -1
- package/dist/types/widgets/config-loader/index.d.ts +0 -2
- package/dist/types/widgets/config-loader/types.d.ts +0 -12
- package/dist/types/widgets/config-loader/use-config.d.ts +0 -5
- package/dist/types/widgets/widget/const.d.ts +0 -2
- package/dist/types/widgets/widget/types.d.ts +0 -47
- package/dist/types/widgets/widget/widget.d.ts +0 -2
- package/dist/use-config-BYEOiIcu.js +0 -43
- package/dist/use-config-BYEOiIcu.js.map +0 -1
- package/dist/widget-store-yDO2ul8g.js +0 -44
- package/dist/widget-store-yDO2ul8g.js.map +0 -1
- package/dist/widgets/config-loader.js +0 -5
- package/dist/widgets/config-loader.js.map +0 -1
- package/dist/wrapper-57csMybC.js +0 -265
- package/dist/wrapper-57csMybC.js.map +0 -1
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { NoDataProps } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* NoData wrapper component that displays empty state UI when widget has no data
|
|
4
|
+
*
|
|
5
|
+
* Integrates with widget store to check loading/fetching state and data availability.
|
|
6
|
+
* Works in conjunction with SkeletonLoader for complete loading/empty state handling.
|
|
7
|
+
*
|
|
8
|
+
* @example Basic usage
|
|
9
|
+
* ```tsx
|
|
10
|
+
* <NoData id="my-widget">
|
|
11
|
+
* <WidgetContent id="my-widget" />
|
|
12
|
+
* </NoData>
|
|
13
|
+
* ```
|
|
14
|
+
*
|
|
15
|
+
* @example With SkeletonLoader
|
|
16
|
+
* ```tsx
|
|
17
|
+
* <SkeletonLoader id="my-widget" Skeleton={MySkeleton}>
|
|
18
|
+
* <NoData id="my-widget">
|
|
19
|
+
* <WidgetContent id="my-widget" />
|
|
20
|
+
* </NoData>
|
|
21
|
+
* </SkeletonLoader>
|
|
22
|
+
* ```
|
|
23
|
+
*
|
|
24
|
+
* @example With custom messages
|
|
25
|
+
* ```tsx
|
|
26
|
+
* <NoData
|
|
27
|
+
* id="my-widget"
|
|
28
|
+
* title="No results found"
|
|
29
|
+
* description="Try adjusting your filters"
|
|
30
|
+
* >
|
|
31
|
+
* <WidgetContent id="my-widget" />
|
|
32
|
+
* </NoData>
|
|
33
|
+
* ```
|
|
34
|
+
*/
|
|
35
|
+
export declare function NoData({ id, children, title, description, isEmpty, }: NoDataProps): string | number | bigint | boolean | Iterable<import('react').ReactNode> | Promise<string | number | bigint | boolean | import('react').ReactPortal | import('react').ReactElement<unknown, string | import('react').JSXElementConstructor<any>> | Iterable<import('react').ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { WidgetState } from '../stores/types';
|
|
3
|
+
/**
|
|
4
|
+
* Props for the NoData wrapper component
|
|
5
|
+
*
|
|
6
|
+
* @example Basic usage
|
|
7
|
+
* ```tsx
|
|
8
|
+
* <NoData id="my-widget">
|
|
9
|
+
* <WidgetContent id="my-widget" />
|
|
10
|
+
* </NoData>
|
|
11
|
+
* ```
|
|
12
|
+
*
|
|
13
|
+
* @example With custom messages
|
|
14
|
+
* ```tsx
|
|
15
|
+
* <NoData
|
|
16
|
+
* id="my-widget"
|
|
17
|
+
* title="No results found"
|
|
18
|
+
* description="Try adjusting your filters"
|
|
19
|
+
* >
|
|
20
|
+
* <WidgetContent id="my-widget" />
|
|
21
|
+
* </NoData>
|
|
22
|
+
* ```
|
|
23
|
+
*
|
|
24
|
+
* @example With custom isEmpty logic
|
|
25
|
+
* ```tsx
|
|
26
|
+
* <NoData
|
|
27
|
+
* id="my-widget"
|
|
28
|
+
* isEmpty={(data) => {
|
|
29
|
+
* const d = data as CustomData
|
|
30
|
+
* return !d?.items?.length
|
|
31
|
+
* }}
|
|
32
|
+
* >
|
|
33
|
+
* <WidgetContent id="my-widget" />
|
|
34
|
+
* </NoData>
|
|
35
|
+
* ```
|
|
36
|
+
*/
|
|
37
|
+
export interface NoDataProps {
|
|
38
|
+
/**
|
|
39
|
+
* Widget ID to fetch state from store
|
|
40
|
+
*/
|
|
41
|
+
id: WidgetState['id'];
|
|
42
|
+
/**
|
|
43
|
+
* Children to render when data is available
|
|
44
|
+
*/
|
|
45
|
+
children: ReactNode;
|
|
46
|
+
/**
|
|
47
|
+
* Optional custom title for empty state
|
|
48
|
+
* @default "No data available"
|
|
49
|
+
*/
|
|
50
|
+
title?: string;
|
|
51
|
+
/**
|
|
52
|
+
* Optional custom description for empty state
|
|
53
|
+
* @default "There are no results for the combination of filters applied to your data. Try tweaking your filters, or zoom and pan the map to adjust filters"
|
|
54
|
+
*/
|
|
55
|
+
description?: string;
|
|
56
|
+
/**
|
|
57
|
+
* Optional custom function to determine if data is empty
|
|
58
|
+
* If not provided, uses default isEmpty logic that handles:
|
|
59
|
+
* - null/undefined → empty
|
|
60
|
+
* - [] (empty array) → empty
|
|
61
|
+
* - [[]] (nested empty arrays) → empty
|
|
62
|
+
* - {} (empty object) → empty
|
|
63
|
+
* - Primitives → not empty
|
|
64
|
+
* - Arrays/objects with content → not empty
|
|
65
|
+
*/
|
|
66
|
+
isEmpty?: (data: unknown) => boolean;
|
|
67
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { NoteProps } from './types';
|
|
2
|
-
export declare function Note({
|
|
2
|
+
export declare function Note({ children, labels }: NoteProps): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -2,8 +2,8 @@ import { Theme } from '@mui/material';
|
|
|
2
2
|
export declare const styles: {
|
|
3
3
|
root: {
|
|
4
4
|
typography: string;
|
|
5
|
-
marginBlockStart: ({ spacing }: Theme) => string;
|
|
6
5
|
color: (theme: Theme) => string;
|
|
6
|
+
marginBlockStart: ({ spacing }: Theme) => string;
|
|
7
7
|
};
|
|
8
8
|
clamped: {
|
|
9
9
|
display: "-webkit-box";
|
|
@@ -14,4 +14,15 @@ export declare const styles: {
|
|
|
14
14
|
expanded: {
|
|
15
15
|
display: "block";
|
|
16
16
|
};
|
|
17
|
+
linkButton: {
|
|
18
|
+
padding: number;
|
|
19
|
+
minWidth: string;
|
|
20
|
+
textTransform: "none";
|
|
21
|
+
typography: string;
|
|
22
|
+
fontWeight: number;
|
|
23
|
+
textDecoration: string;
|
|
24
|
+
'&:hover': {
|
|
25
|
+
backgroundColor: "transparent";
|
|
26
|
+
};
|
|
27
|
+
};
|
|
17
28
|
};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export
|
|
1
|
+
import { MarkdownComponentProps } from '../markdown';
|
|
2
|
+
export interface NoteProps {
|
|
3
|
+
children: MarkdownComponentProps['children'];
|
|
3
4
|
labels?: {
|
|
4
5
|
showMore?: string;
|
|
5
6
|
showLess?: string;
|
|
6
7
|
};
|
|
7
|
-
}
|
|
8
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { PieConfig } from './types';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import { PieConfig, PieWidgetConfig, PieWidgetData } from './types';
|
|
2
|
+
import { DownloadItem } from '../actions';
|
|
3
|
+
import { ConfigProps } from '../root/types';
|
|
4
|
+
export declare function pieDownloadConfig({ refUI, }: ConfigProps): DownloadItem<PieWidgetData>[];
|
|
5
|
+
export declare function pieConfig(props: PieConfig): PieWidgetConfig;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export type {
|
|
2
|
-
export { pieConfig } from './config';
|
|
1
|
+
export type { PieWidgetData, PieWidgetState, PieWidgetConfig, PieConfig, } from './types';
|
|
2
|
+
export { pieConfig, pieDownloadConfig } from './config';
|
|
3
3
|
export { PieSkeleton } from './skeleton';
|
|
@@ -1,15 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
export interface PieProps extends BaseWidgetProps<PieWidgetConfig> {
|
|
5
|
-
type: 'pie';
|
|
6
|
-
data: PieWidgetData | undefined;
|
|
7
|
-
}
|
|
1
|
+
import { EchartWidgetData, EchartWidgetState } from '../echart';
|
|
2
|
+
import { EchartWidgetOptionProps, EchartWidgetProps } from '../echart/types';
|
|
3
|
+
import { ConfigProps } from '../root';
|
|
8
4
|
export type PieWidgetData = EchartWidgetData;
|
|
9
5
|
export type PieWidgetState = EchartWidgetState;
|
|
10
|
-
export type PieWidgetConfig =
|
|
11
|
-
type:
|
|
6
|
+
export type PieWidgetConfig = EchartWidgetProps & {
|
|
7
|
+
type: 'pie';
|
|
12
8
|
};
|
|
13
|
-
export
|
|
14
|
-
data?: PieWidgetData;
|
|
15
|
-
}
|
|
9
|
+
export type PieConfig = ConfigProps & EchartWidgetOptionProps<PieWidgetData>;
|
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export
|
|
1
|
+
import { RangeWidgetConfig } from './types';
|
|
2
|
+
export interface RangeConfigProps {
|
|
3
|
+
formatter?: (value: number) => string;
|
|
4
|
+
onChange?: (value: number[], index: number) => void;
|
|
5
|
+
}
|
|
6
|
+
export declare function rangeConfig(): RangeWidgetConfig;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { RangeUI } from './range-ui';
|
|
2
2
|
export { RangeSkeleton } from './skeleton';
|
|
3
|
+
export { rangeConfig } from './config';
|
|
3
4
|
export { RangeItem } from './components/range-item';
|
|
4
|
-
export type { RangeWidgetState, RangeUIProps, RangeDataItem, RangeWidgetData, RangeItemProps, } from './types';
|
|
5
|
+
export type { RangeWidgetState, RangeWidgetConfig, RangeDownloadConfig, RangeUIProps, RangeDataItem, RangeWidgetData, RangeItemProps, } from './types';
|
|
5
6
|
export { sanitizeRangeDataItem, sanitizeRangeDataItems } from './serializer';
|
|
@@ -1,14 +1,7 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { BaseWidgetState, WidgetsStoreProps } from '../stores/types';
|
|
3
|
-
import { DownloadState } from '../actions';
|
|
4
|
-
import { DownloadConfigProps } from '../actions/download/types';
|
|
5
3
|
import { WrapperState } from '../wrapper/types';
|
|
6
|
-
import {
|
|
7
|
-
import { BaseConfig } from '../config-loader';
|
|
8
|
-
export interface RangeProps extends BaseWidgetProps<RangeWidgetConfig> {
|
|
9
|
-
type: 'range';
|
|
10
|
-
data: RangeWidgetData | undefined;
|
|
11
|
-
}
|
|
4
|
+
import { DownloadItem } from '../actions/download/types';
|
|
12
5
|
export interface RangeUIProps {
|
|
13
6
|
id: WidgetsStoreProps['id'];
|
|
14
7
|
}
|
|
@@ -30,15 +23,11 @@ export interface RangeItemProps {
|
|
|
30
23
|
index: number;
|
|
31
24
|
}
|
|
32
25
|
export type RangeWidgetData = RangeDataItem[];
|
|
33
|
-
export type RangeWidgetState = BaseWidgetState<WrapperState<
|
|
26
|
+
export type RangeWidgetState = BaseWidgetState<WrapperState<RangeWidgetConfig>> & {
|
|
27
|
+
data: RangeWidgetData;
|
|
28
|
+
};
|
|
29
|
+
export interface RangeWidgetConfig {
|
|
34
30
|
formatter?: (value: number) => string;
|
|
35
31
|
onChange?: (value: number[], index: number) => void;
|
|
36
|
-
}, RangeWidgetData>>>;
|
|
37
|
-
export type RangeWidgetConfig = BaseConfig & DownloadConfigProps<RangeWidgetData> & {
|
|
38
|
-
type: RangeProps['type'];
|
|
39
|
-
formatter?: RangeWidgetState['formatter'];
|
|
40
|
-
onChange?: RangeWidgetState['onChange'];
|
|
41
|
-
};
|
|
42
|
-
export interface RangeConfig extends Omit<BaseConfig, 'data'> {
|
|
43
|
-
data?: RangeWidgetData;
|
|
44
32
|
}
|
|
33
|
+
export type RangeDownloadConfig = DownloadItem<RangeWidgetData>[];
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { RootProps } from './types';
|
|
2
|
-
export declare function Root(props: RootProps): import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
export declare function Root<T>(props: RootProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,15 +1,9 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export interface RootProps {
|
|
5
|
-
id: WidgetsStoreProps['id'];
|
|
6
|
-
type: WidgetsStoreProps['type'];
|
|
2
|
+
import { WidgetsStoreProps, WidgetState } from '../stores/types';
|
|
3
|
+
export interface RootProps<T> extends WidgetsStoreProps {
|
|
7
4
|
children: ReactNode;
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
collapsed?: WrapperUIProps['collapsed'];
|
|
13
|
-
collapsible?: WrapperUIProps['disabled'];
|
|
14
|
-
disabled?: WrapperUIProps['disabled'];
|
|
5
|
+
config?: T;
|
|
6
|
+
}
|
|
7
|
+
export interface ConfigProps {
|
|
8
|
+
refUI?: WidgetState['refUI'];
|
|
15
9
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function mergeWidgetConfig<T>(...options: [T | undefined, T | undefined]): T;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { ScatterplotConfig, ScatterplotWidgetData } from './types';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import { ScatterplotConfig, ScatterplotWidgetConfig, ScatterplotWidgetData } from './types';
|
|
2
|
+
import { DownloadItem } from '../actions';
|
|
3
|
+
import { ConfigProps } from '../root/types';
|
|
4
|
+
export declare function scatterplotDownloadConfig({ refUI, }: ConfigProps): DownloadItem<ScatterplotWidgetData>[];
|
|
5
|
+
export declare function scatterplotConfig(props: ScatterplotConfig): ScatterplotWidgetConfig;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export type {
|
|
2
|
-
export { scatterplotConfig } from './config';
|
|
1
|
+
export type { ScatterplotWidgetData, ScatterplotWidgetState, ScatterplotWidgetConfig, ScatterplotConfig, } from './types';
|
|
2
|
+
export { scatterplotConfig, scatterplotDownloadConfig } from './config';
|
|
3
3
|
export { ScatterplotSkeleton } from './skeleton';
|
|
@@ -1,15 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
export interface ScatterplotProps extends BaseWidgetProps<ScatterplotWidgetConfig> {
|
|
5
|
-
type: 'scatterplot';
|
|
6
|
-
data: ScatterplotWidgetData | undefined;
|
|
7
|
-
}
|
|
1
|
+
import { EchartWidgetState } from '../echart';
|
|
2
|
+
import { EchartWidgetOptionProps, EchartWidgetProps } from '../echart/types';
|
|
3
|
+
import { ConfigProps } from '../root';
|
|
8
4
|
export type ScatterplotWidgetData = [number, number][][];
|
|
9
5
|
export type ScatterplotWidgetState = EchartWidgetState;
|
|
10
|
-
export type ScatterplotWidgetConfig =
|
|
11
|
-
type:
|
|
6
|
+
export type ScatterplotWidgetConfig = EchartWidgetProps & {
|
|
7
|
+
type: 'scatterplot';
|
|
12
8
|
};
|
|
13
|
-
export
|
|
14
|
-
data?: ScatterplotWidgetData;
|
|
15
|
-
}
|
|
9
|
+
export type ScatterplotConfig = ConfigProps & EchartWidgetOptionProps<ScatterplotWidgetData>;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export interface SelectedProps {
|
|
2
|
+
selections: number;
|
|
3
|
+
onClear?: () => void;
|
|
4
|
+
labels?: Partial<SelectionSummaryLabels>;
|
|
5
|
+
}
|
|
6
|
+
export interface SelectionSummaryLabels {
|
|
7
|
+
/** Label for "All selected" state */
|
|
8
|
+
allSelected: string;
|
|
9
|
+
/** Label for number of selections */
|
|
10
|
+
selections: (count: number) => string;
|
|
11
|
+
/** Label for clear button */
|
|
12
|
+
clear: string;
|
|
13
|
+
}
|
|
@@ -1,2 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { DownloadItem } from '../actions';
|
|
2
|
+
import { ConfigProps } from '../root/types';
|
|
3
|
+
import { SpreadWidgetConfig, SpreadWidgetData } from './types';
|
|
4
|
+
import { SeriesConfig } from '../formula/types';
|
|
5
|
+
export interface SpreadConfigProps {
|
|
6
|
+
formatter?: (value: number) => string;
|
|
7
|
+
series?: SeriesConfig[];
|
|
8
|
+
}
|
|
9
|
+
export declare function spreadDownloadConfig({ refUI, }: ConfigProps): DownloadItem<SpreadWidgetData>[];
|
|
10
|
+
export declare function spreadConfig(): SpreadWidgetConfig;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
export { SpreadUI } from './spread-ui';
|
|
2
2
|
export { SpreadSkeleton } from './skeleton';
|
|
3
|
+
export { spreadConfig, spreadDownloadConfig } from './config';
|
|
3
4
|
export { MinValue } from './components/min-value';
|
|
4
5
|
export { MaxValue } from './components/max-value';
|
|
5
6
|
export { Separator } from './components/separator';
|
|
6
7
|
export { Item, Row, Prefix, Suffix, Series } from '../formula';
|
|
7
|
-
export type { RowProps, ValueProps, SpreadWidgetState, ItemProps, SpreadDataItem, SpreadUIProps, } from './types';
|
|
8
|
+
export type { RowProps, ValueProps, SpreadWidgetState, SpreadWidgetConfig, SpreadWidgetData, SpreadDownloadConfig, ItemProps, SpreadDataItem, SpreadUIProps, } from './types';
|
|
8
9
|
export type { SeriesConfig } from '../formula/types';
|
|
@@ -1,16 +1,9 @@
|
|
|
1
1
|
import { TypographyProps } from '@mui/material';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
3
|
import { BaseWidgetState, WidgetsStoreProps } from '../stores/types';
|
|
4
|
-
import { DownloadState } from '../actions';
|
|
5
|
-
import { DownloadConfigProps } from '../actions/download/types';
|
|
6
4
|
import { WrapperState } from '../wrapper/types';
|
|
7
|
-
import {
|
|
8
|
-
import { BaseConfig } from '../config-loader';
|
|
5
|
+
import { DownloadItem } from '../actions/download/types';
|
|
9
6
|
import { SeriesConfig } from '../formula/types';
|
|
10
|
-
export interface SpreadProps extends BaseWidgetProps<SpreadWidgetConfig> {
|
|
11
|
-
type: 'spread';
|
|
12
|
-
data: SpreadWidgetData | undefined;
|
|
13
|
-
}
|
|
14
7
|
export interface SpreadUIProps {
|
|
15
8
|
id: WidgetsStoreProps['id'];
|
|
16
9
|
}
|
|
@@ -37,16 +30,11 @@ export interface ItemProps {
|
|
|
37
30
|
TypographyProps?: TypographyProps;
|
|
38
31
|
}
|
|
39
32
|
export type SpreadWidgetData = SpreadDataItem[];
|
|
40
|
-
export type SpreadWidgetState = BaseWidgetState<WrapperState<
|
|
33
|
+
export type SpreadWidgetState = BaseWidgetState<WrapperState<SpreadWidgetConfig> & {
|
|
34
|
+
data: SpreadWidgetData;
|
|
35
|
+
}>;
|
|
36
|
+
export interface SpreadWidgetConfig {
|
|
41
37
|
formatter?: (value: number) => string;
|
|
42
38
|
series?: SeriesConfig[];
|
|
43
|
-
}, SpreadWidgetData>>>;
|
|
44
|
-
export type SpreadWidgetConfig = BaseConfig & DownloadConfigProps<SpreadWidgetData> & {
|
|
45
|
-
type: SpreadProps['type'];
|
|
46
|
-
formatter?: SpreadWidgetState['formatter'];
|
|
47
|
-
series?: SeriesConfig[];
|
|
48
|
-
};
|
|
49
|
-
export interface SpreadConfig extends Omit<BaseConfig, 'data'> {
|
|
50
|
-
data?: SpreadWidgetData;
|
|
51
|
-
series?: SeriesConfig[];
|
|
52
39
|
}
|
|
40
|
+
export type SpreadDownloadConfig = DownloadItem<SpreadWidgetData>[];
|