@restio/ui 0.1.0 → 0.2.1-20260901123418
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/README.md +78 -8
- package/dist/core.cjs +1 -0
- package/dist/core.d.ts +803 -0
- package/dist/core.js +30 -0
- package/dist/data.cjs +1 -0
- package/dist/data.d.ts +1423 -0
- package/dist/data.js +24 -0
- package/dist/experimental.cjs +1 -0
- package/dist/experimental.d.ts +486 -0
- package/dist/experimental.js +1027 -0
- package/dist/framework.cjs +1 -0
- package/dist/framework.d.ts +788 -0
- package/dist/framework.js +31 -0
- package/dist/index.cjs +1 -0
- package/dist/index.d.ts +3124 -132
- package/dist/index.js +90 -0
- package/dist/src-DaTjVaGd.js +39749 -0
- package/dist/src-gB-fpYMb.cjs +156 -0
- package/dist/ui.css +1 -1
- package/package.json +66 -45
- package/dist/assets/svg/alert.svg +0 -1
- package/dist/assets/svg/arrow-down-up.svg +0 -1
- package/dist/assets/svg/arrow-down.svg +0 -1
- package/dist/assets/svg/arrow-left.svg +0 -1
- package/dist/assets/svg/arrow-right.svg +0 -1
- package/dist/assets/svg/arrow-up.svg +0 -1
- package/dist/assets/svg/arrow_drop_down.svg +0 -1
- package/dist/assets/svg/calendar.svg +0 -1
- package/dist/assets/svg/chart-area.svg +0 -9
- package/dist/assets/svg/chart-bar-stacked.svg +0 -9
- package/dist/assets/svg/chart-bar.svg +0 -6
- package/dist/assets/svg/chart-candlestick.svg +0 -17
- package/dist/assets/svg/chart-gantt.svg +0 -9
- package/dist/assets/svg/chart-line.svg +0 -9
- package/dist/assets/svg/chart-pie.svg +0 -9
- package/dist/assets/svg/chart-sankey.svg +0 -18
- package/dist/assets/svg/check.svg +0 -1
- package/dist/assets/svg/chevron-down.svg +0 -1
- package/dist/assets/svg/chevron-right.svg +0 -1
- package/dist/assets/svg/clipboard.svg +0 -1
- package/dist/assets/svg/close.svg +0 -1
- package/dist/assets/svg/copy.svg +0 -1
- package/dist/assets/svg/cursor.svg +0 -1
- package/dist/assets/svg/cut.svg +0 -1
- package/dist/assets/svg/delete.svg +0 -1
- package/dist/assets/svg/discussion.svg +0 -1
- package/dist/assets/svg/dock-left-arrow.svg +0 -1
- package/dist/assets/svg/dock-right-arrow.svg +0 -1
- package/dist/assets/svg/document-outline.svg +0 -1
- package/dist/assets/svg/download.svg +0 -1
- package/dist/assets/svg/drag.svg +0 -1
- package/dist/assets/svg/error.svg +0 -1
- package/dist/assets/svg/expand-right.svg +0 -1
- package/dist/assets/svg/expand.svg +0 -1
- package/dist/assets/svg/eye.svg +0 -1
- package/dist/assets/svg/form.svg +0 -16
- package/dist/assets/svg/fullscreen.svg +0 -1
- package/dist/assets/svg/gear.svg +0 -1
- package/dist/assets/svg/groups.svg +0 -1
- package/dist/assets/svg/help.svg +0 -1
- package/dist/assets/svg/info.svg +0 -1
- package/dist/assets/svg/list.svg +0 -15
- package/dist/assets/svg/logo.svg +0 -9
- package/dist/assets/svg/menu.svg +0 -1
- package/dist/assets/svg/message-bubble-question-mark.svg +0 -1
- package/dist/assets/svg/pencil.svg +0 -1
- package/dist/assets/svg/pie-chart.svg +0 -1
- package/dist/assets/svg/plus.svg +0 -1
- package/dist/assets/svg/restio.svg +0 -5
- package/dist/assets/svg/search.svg +0 -1
- package/dist/assets/svg/send.svg +0 -1
- package/dist/assets/svg/shrink-right.svg +0 -1
- package/dist/assets/svg/sidebar.svg +0 -1
- package/dist/assets/svg/table.svg +0 -18
- package/dist/assets/svg/terminal.svg +0 -1
- package/dist/assets/svg/timer.svg +0 -1
- package/dist/assets/svg/warning.svg +0 -1
- package/dist/assets/svg/zoom-minus.svg +0 -1
- package/dist/assets/svg/zoom-plus.svg +0 -1
- package/dist/components/anchored-overlay/anchored-overlay-types.d.ts +0 -23
- package/dist/components/anchored-overlay/anchored-overlay-types.d.ts.map +0 -1
- package/dist/components/anchored-overlay/anchored-overlay.d.ts +0 -5
- package/dist/components/anchored-overlay/anchored-overlay.d.ts.map +0 -1
- package/dist/components/banner/banner-types.d.ts +0 -13
- package/dist/components/banner/banner-types.d.ts.map +0 -1
- package/dist/components/banner/banner.d.ts +0 -5
- package/dist/components/banner/banner.d.ts.map +0 -1
- package/dist/components/button/button-types.d.ts +0 -12
- package/dist/components/button/button-types.d.ts.map +0 -1
- package/dist/components/button/button.d.ts +0 -4
- package/dist/components/button/button.d.ts.map +0 -1
- package/dist/components/button-dropdown/button-dropdown-types.d.ts +0 -20
- package/dist/components/button-dropdown/button-dropdown-types.d.ts.map +0 -1
- package/dist/components/button-dropdown/button-dropdown.d.ts +0 -8
- package/dist/components/button-dropdown/button-dropdown.d.ts.map +0 -1
- package/dist/components/button-group/button-group-types.d.ts +0 -16
- package/dist/components/button-group/button-group-types.d.ts.map +0 -1
- package/dist/components/button-group/button-group.d.ts +0 -4
- package/dist/components/button-group/button-group.d.ts.map +0 -1
- package/dist/components/checkbox/checkbox-types.d.ts +0 -16
- package/dist/components/checkbox/checkbox-types.d.ts.map +0 -1
- package/dist/components/checkbox/checkbox.d.ts +0 -4
- package/dist/components/checkbox/checkbox.d.ts.map +0 -1
- package/dist/components/checkbox-group/checkbox-group-types.d.ts +0 -28
- package/dist/components/checkbox-group/checkbox-group-types.d.ts.map +0 -1
- package/dist/components/checkbox-group/checkbox-group.d.ts +0 -8
- package/dist/components/checkbox-group/checkbox-group.d.ts.map +0 -1
- package/dist/components/code-block/code-block.d.ts +0 -8
- package/dist/components/code-block/code-block.d.ts.map +0 -1
- package/dist/components/file-upload/file-upload-types.d.ts +0 -37
- package/dist/components/file-upload/file-upload-types.d.ts.map +0 -1
- package/dist/components/file-upload/file-upload-utils.d.ts +0 -2
- package/dist/components/file-upload/file-upload-utils.d.ts.map +0 -1
- package/dist/components/file-upload/file-upload.d.ts +0 -4
- package/dist/components/file-upload/file-upload.d.ts.map +0 -1
- package/dist/components/input/date/date-calendar.d.ts +0 -4
- package/dist/components/input/date/date-calendar.d.ts.map +0 -1
- package/dist/components/input/date/date-input-field.d.ts +0 -9
- package/dist/components/input/date/date-input-field.d.ts.map +0 -1
- package/dist/components/input/date/date-picker.d.ts +0 -8
- package/dist/components/input/date/date-picker.d.ts.map +0 -1
- package/dist/components/input/date/date-range-input-field.d.ts +0 -9
- package/dist/components/input/date/date-range-input-field.d.ts.map +0 -1
- package/dist/components/input/date/date-range-picker.d.ts +0 -9
- package/dist/components/input/date/date-range-picker.d.ts.map +0 -1
- package/dist/components/input/date/date-shortcuts.d.ts +0 -4
- package/dist/components/input/date/date-shortcuts.d.ts.map +0 -1
- package/dist/components/input/date/date-types.d.ts +0 -53
- package/dist/components/input/date/date-types.d.ts.map +0 -1
- package/dist/components/input/date/date-utils.d.ts +0 -51
- package/dist/components/input/date/date-utils.d.ts.map +0 -1
- package/dist/components/input/input-types.d.ts +0 -27
- package/dist/components/input/input-types.d.ts.map +0 -1
- package/dist/components/input/input.d.ts +0 -4
- package/dist/components/input/input.d.ts.map +0 -1
- package/dist/components/input/number/input-number-types.d.ts +0 -8
- package/dist/components/input/number/input-number-types.d.ts.map +0 -1
- package/dist/components/input/number/input-number.d.ts +0 -4
- package/dist/components/input/number/input-number.d.ts.map +0 -1
- package/dist/components/input/text/input-text-types.d.ts +0 -7
- package/dist/components/input/text/input-text-types.d.ts.map +0 -1
- package/dist/components/input/text/input-text.d.ts +0 -4
- package/dist/components/input/text/input-text.d.ts.map +0 -1
- package/dist/components/kbd/kbd-types.d.ts +0 -7
- package/dist/components/kbd/kbd-types.d.ts.map +0 -1
- package/dist/components/kbd/kbd.d.ts +0 -5
- package/dist/components/kbd/kbd.d.ts.map +0 -1
- package/dist/components/kbd-group/kbd-group-types.d.ts +0 -15
- package/dist/components/kbd-group/kbd-group-types.d.ts.map +0 -1
- package/dist/components/kbd-group/kbd-group.d.ts +0 -5
- package/dist/components/kbd-group/kbd-group.d.ts.map +0 -1
- package/dist/components/list/list-types.d.ts +0 -38
- package/dist/components/list/list-types.d.ts.map +0 -1
- package/dist/components/list/list-utils.d.ts +0 -47
- package/dist/components/list/list-utils.d.ts.map +0 -1
- package/dist/components/list/list.d.ts +0 -3
- package/dist/components/list/list.d.ts.map +0 -1
- package/dist/components/menu/anchored-navigation-menu.d.ts +0 -19
- package/dist/components/menu/anchored-navigation-menu.d.ts.map +0 -1
- package/dist/components/menu/menu-assets.d.ts +0 -3
- package/dist/components/menu/menu-assets.d.ts.map +0 -1
- package/dist/components/menu/menu-types.d.ts +0 -22
- package/dist/components/menu/menu-types.d.ts.map +0 -1
- package/dist/components/menu/menu.d.ts +0 -9
- package/dist/components/menu/menu.d.ts.map +0 -1
- package/dist/components/otp/otp-types.d.ts +0 -30
- package/dist/components/otp/otp-types.d.ts.map +0 -1
- package/dist/components/otp/otp-utils.d.ts +0 -15
- package/dist/components/otp/otp-utils.d.ts.map +0 -1
- package/dist/components/otp/otp.d.ts +0 -4
- package/dist/components/otp/otp.d.ts.map +0 -1
- package/dist/components/progress-bar/progress-bar-types.d.ts +0 -20
- package/dist/components/progress-bar/progress-bar-types.d.ts.map +0 -1
- package/dist/components/progress-bar/progress-bar.d.ts +0 -7
- package/dist/components/progress-bar/progress-bar.d.ts.map +0 -1
- package/dist/components/radio/radio-types.d.ts +0 -14
- package/dist/components/radio/radio-types.d.ts.map +0 -1
- package/dist/components/radio/radio.d.ts +0 -8
- package/dist/components/radio/radio.d.ts.map +0 -1
- package/dist/components/radio-group/radio-group-types.d.ts +0 -30
- package/dist/components/radio-group/radio-group-types.d.ts.map +0 -1
- package/dist/components/radio-group/radio-group.d.ts +0 -8
- package/dist/components/radio-group/radio-group.d.ts.map +0 -1
- package/dist/components/select/select-types.d.ts +0 -62
- package/dist/components/select/select-types.d.ts.map +0 -1
- package/dist/components/select/select.d.ts +0 -5
- package/dist/components/select/select.d.ts.map +0 -1
- package/dist/components/selection-grid/selection-grid-types.d.ts +0 -20
- package/dist/components/selection-grid/selection-grid-types.d.ts.map +0 -1
- package/dist/components/selection-grid/selection-grid.d.ts +0 -8
- package/dist/components/selection-grid/selection-grid.d.ts.map +0 -1
- package/dist/components/tag/tag-types.d.ts +0 -9
- package/dist/components/tag/tag-types.d.ts.map +0 -1
- package/dist/components/tag/tag.d.ts +0 -4
- package/dist/components/tag/tag.d.ts.map +0 -1
- package/dist/components/textarea/textarea-types.d.ts +0 -55
- package/dist/components/textarea/textarea-types.d.ts.map +0 -1
- package/dist/components/textarea/textarea.d.ts +0 -4
- package/dist/components/textarea/textarea.d.ts.map +0 -1
- package/dist/components/toast-group/toast-group-types.d.ts +0 -6
- package/dist/components/toast-group/toast-group-types.d.ts.map +0 -1
- package/dist/components/toast-group/toast-group.d.ts +0 -5
- package/dist/components/toast-group/toast-group.d.ts.map +0 -1
- package/dist/components/typography/typography-types.d.ts +0 -59
- package/dist/components/typography/typography-types.d.ts.map +0 -1
- package/dist/components/typography/typography.d.ts +0 -4
- package/dist/components/typography/typography.d.ts.map +0 -1
- package/dist/custom-components/chat/chat-types.d.ts +0 -19
- package/dist/custom-components/chat/chat-types.d.ts.map +0 -1
- package/dist/custom-components/chat/chat.d.ts +0 -3
- package/dist/custom-components/chat/chat.d.ts.map +0 -1
- package/dist/custom-components/layout/layout-renderers.d.ts +0 -9
- package/dist/custom-components/layout/layout-renderers.d.ts.map +0 -1
- package/dist/custom-components/layout/layout-types.d.ts +0 -44
- package/dist/custom-components/layout/layout-types.d.ts.map +0 -1
- package/dist/custom-components/layout/layout.d.ts +0 -13
- package/dist/custom-components/layout/layout.d.ts.map +0 -1
- package/dist/custom-components/markdown/components/img/zoomable-image.d.ts +0 -5
- package/dist/custom-components/markdown/components/img/zoomable-image.d.ts.map +0 -1
- package/dist/custom-components/markdown/markdown-types.d.ts +0 -29
- package/dist/custom-components/markdown/markdown-types.d.ts.map +0 -1
- package/dist/custom-components/markdown/markdown-utils.d.ts +0 -2
- package/dist/custom-components/markdown/markdown-utils.d.ts.map +0 -1
- package/dist/custom-components/markdown/markdown.d.ts +0 -4
- package/dist/custom-components/markdown/markdown.d.ts.map +0 -1
- package/dist/custom-components/mindmap/index.d.ts +0 -3
- package/dist/custom-components/mindmap/index.d.ts.map +0 -1
- package/dist/custom-components/mindmap/mind-tree-types.d.ts +0 -94
- package/dist/custom-components/mindmap/mind-tree-types.d.ts.map +0 -1
- package/dist/custom-components/mindmap/mind-tree.d.ts +0 -3
- package/dist/custom-components/mindmap/mind-tree.d.ts.map +0 -1
- package/dist/custom-components/mindmap/reingold-tilford-algorithm.d.ts +0 -65
- package/dist/custom-components/mindmap/reingold-tilford-algorithm.d.ts.map +0 -1
- package/dist/custom-components/shortcut-tooltip/shortcut-tooltip-types.d.ts +0 -60
- package/dist/custom-components/shortcut-tooltip/shortcut-tooltip-types.d.ts.map +0 -1
- package/dist/custom-components/shortcut-tooltip/shortcut-tooltip.d.ts +0 -18
- package/dist/custom-components/shortcut-tooltip/shortcut-tooltip.d.ts.map +0 -1
- package/dist/custom-components/timeline/skeleton/timeline-skeleton.d.ts +0 -7
- package/dist/custom-components/timeline/skeleton/timeline-skeleton.d.ts.map +0 -1
- package/dist/custom-components/timeline/timeline-types.d.ts +0 -46
- package/dist/custom-components/timeline/timeline-types.d.ts.map +0 -1
- package/dist/custom-components/timeline/timeline.d.ts +0 -20
- package/dist/custom-components/timeline/timeline.d.ts.map +0 -1
- package/dist/custom-components/workflow/layout/workflow-edge.d.ts +0 -3
- package/dist/custom-components/workflow/layout/workflow-edge.d.ts.map +0 -1
- package/dist/custom-components/workflow/layout/workflow-layout-types.d.ts +0 -74
- package/dist/custom-components/workflow/layout/workflow-layout-types.d.ts.map +0 -1
- package/dist/custom-components/workflow/layout/workflow-layout.d.ts +0 -38
- package/dist/custom-components/workflow/layout/workflow-layout.d.ts.map +0 -1
- package/dist/custom-components/workflow/node/workflow-node.d.ts +0 -3
- package/dist/custom-components/workflow/node/workflow-node.d.ts.map +0 -1
- package/dist/custom-components/workflow/panel/workflow-panel-types.d.ts +0 -18
- package/dist/custom-components/workflow/panel/workflow-panel-types.d.ts.map +0 -1
- package/dist/custom-components/workflow/panel/workflow-panel.d.ts +0 -3
- package/dist/custom-components/workflow/panel/workflow-panel.d.ts.map +0 -1
- package/dist/custom-components/workflow/toolbar/workflow-toolbar-types.d.ts +0 -24
- package/dist/custom-components/workflow/toolbar/workflow-toolbar-types.d.ts.map +0 -1
- package/dist/custom-components/workflow/toolbar/workflow-toolbar.d.ts +0 -3
- package/dist/custom-components/workflow/toolbar/workflow-toolbar.d.ts.map +0 -1
- package/dist/custom-components/workflow/utils/workflow-validation.d.ts +0 -48
- package/dist/custom-components/workflow/utils/workflow-validation.d.ts.map +0 -1
- package/dist/custom-components/workflow/workflow-types.d.ts +0 -204
- package/dist/custom-components/workflow/workflow-types.d.ts.map +0 -1
- package/dist/custom-components/workflow/workflow.d.ts +0 -6
- package/dist/custom-components/workflow/workflow.d.ts.map +0 -1
- package/dist/data-components/assets/cell-types-asset.d.ts +0 -39
- package/dist/data-components/assets/cell-types-asset.d.ts.map +0 -1
- package/dist/data-components/assets/data-components-asset.d.ts +0 -14
- package/dist/data-components/assets/data-components-asset.d.ts.map +0 -1
- package/dist/data-components/calendar/calendar-types.d.ts +0 -31
- package/dist/data-components/calendar/calendar-types.d.ts.map +0 -1
- package/dist/data-components/calendar/calendar-utils.d.ts +0 -6
- package/dist/data-components/calendar/calendar-utils.d.ts.map +0 -1
- package/dist/data-components/calendar/calendar.d.ts +0 -4
- package/dist/data-components/calendar/calendar.d.ts.map +0 -1
- package/dist/data-components/card/card-types.d.ts +0 -21
- package/dist/data-components/card/card-types.d.ts.map +0 -1
- package/dist/data-components/card/card.d.ts +0 -10
- package/dist/data-components/card/card.d.ts.map +0 -1
- package/dist/data-components/card-list/card-list-types.d.ts +0 -22
- package/dist/data-components/card-list/card-list-types.d.ts.map +0 -1
- package/dist/data-components/card-list/card-list.d.ts +0 -13
- package/dist/data-components/card-list/card-list.d.ts.map +0 -1
- package/dist/data-components/card-list/models/ecommerce.d.ts +0 -13
- package/dist/data-components/card-list/models/ecommerce.d.ts.map +0 -1
- package/dist/data-components/cell/cell-registry.d.ts +0 -29
- package/dist/data-components/cell/cell-registry.d.ts.map +0 -1
- package/dist/data-components/cell/cell-types.d.ts +0 -36
- package/dist/data-components/cell/cell-types.d.ts.map +0 -1
- package/dist/data-components/cell/cell-utils.d.ts +0 -22
- package/dist/data-components/cell/cell-utils.d.ts.map +0 -1
- package/dist/data-components/cell/cell.d.ts +0 -3
- package/dist/data-components/cell/cell.d.ts.map +0 -1
- package/dist/data-components/chart/chart-tooltip/chart-tooltip-types.d.ts +0 -14
- package/dist/data-components/chart/chart-tooltip/chart-tooltip-types.d.ts.map +0 -1
- package/dist/data-components/chart/chart-tooltip/chart-tooltip.d.ts +0 -7
- package/dist/data-components/chart/chart-tooltip/chart-tooltip.d.ts.map +0 -1
- package/dist/data-components/chart/chart-types.d.ts +0 -88
- package/dist/data-components/chart/chart-types.d.ts.map +0 -1
- package/dist/data-components/chart/chart-utils.d.ts +0 -28
- package/dist/data-components/chart/chart-utils.d.ts.map +0 -1
- package/dist/data-components/chart/chart.d.ts +0 -4
- package/dist/data-components/chart/chart.d.ts.map +0 -1
- package/dist/data-components/chart/geo/geoChart.d.ts +0 -10
- package/dist/data-components/chart/geo/geoChart.d.ts.map +0 -1
- package/dist/data-components/chart/sankey/sankeyChart.d.ts +0 -38
- package/dist/data-components/chart/sankey/sankeyChart.d.ts.map +0 -1
- package/dist/data-components/data-component-configurator/data-component-configurator-types.d.ts +0 -36
- package/dist/data-components/data-component-configurator/data-component-configurator-types.d.ts.map +0 -1
- package/dist/data-components/data-component-configurator/data-component-configurator.d.ts +0 -17
- package/dist/data-components/data-component-configurator/data-component-configurator.d.ts.map +0 -1
- package/dist/data-components/data-component-types.d.ts +0 -11
- package/dist/data-components/data-component-types.d.ts.map +0 -1
- package/dist/data-components/data-component-utils.d.ts +0 -4
- package/dist/data-components/data-component-utils.d.ts.map +0 -1
- package/dist/data-components/data-structure/data-structure-utils.d.ts +0 -16
- package/dist/data-components/data-structure/data-structure-utils.d.ts.map +0 -1
- package/dist/data-components/data-structure/data-structure.d.ts +0 -42
- package/dist/data-components/data-structure/data-structure.d.ts.map +0 -1
- package/dist/data-components/data-structure/stories-assets.d.ts +0 -87
- package/dist/data-components/data-structure/stories-assets.d.ts.map +0 -1
- package/dist/data-components/filter/filter-engine.d.ts +0 -15
- package/dist/data-components/filter/filter-engine.d.ts.map +0 -1
- package/dist/data-components/filter/filter-types.d.ts +0 -41
- package/dist/data-components/filter/filter-types.d.ts.map +0 -1
- package/dist/data-components/filter/filter-utils.d.ts +0 -26
- package/dist/data-components/filter/filter-utils.d.ts.map +0 -1
- package/dist/data-components/form/form-types.d.ts +0 -65
- package/dist/data-components/form/form-types.d.ts.map +0 -1
- package/dist/data-components/form/form.d.ts +0 -3
- package/dist/data-components/form/form.d.ts.map +0 -1
- package/dist/data-components/gantt/ai-assistant/gantt-ai-executor.d.ts +0 -9
- package/dist/data-components/gantt/ai-assistant/gantt-ai-executor.d.ts.map +0 -1
- package/dist/data-components/gantt/ai-assistant/gantt-ai-panel.d.ts +0 -12
- package/dist/data-components/gantt/ai-assistant/gantt-ai-panel.d.ts.map +0 -1
- package/dist/data-components/gantt/ai-assistant/gantt-ai-schema.d.ts +0 -7
- package/dist/data-components/gantt/ai-assistant/gantt-ai-schema.d.ts.map +0 -1
- package/dist/data-components/gantt/ai-assistant/gantt-ai-tools.d.ts +0 -3
- package/dist/data-components/gantt/ai-assistant/gantt-ai-tools.d.ts.map +0 -1
- package/dist/data-components/gantt/arrows/gantt-arrows.d.ts +0 -21
- package/dist/data-components/gantt/arrows/gantt-arrows.d.ts.map +0 -1
- package/dist/data-components/gantt/gantt-context.d.ts +0 -13
- package/dist/data-components/gantt/gantt-context.d.ts.map +0 -1
- package/dist/data-components/gantt/gantt-types.d.ts +0 -102
- package/dist/data-components/gantt/gantt-types.d.ts.map +0 -1
- package/dist/data-components/gantt/gantt-utils.d.ts +0 -61
- package/dist/data-components/gantt/gantt-utils.d.ts.map +0 -1
- package/dist/data-components/gantt/gantt.d.ts +0 -4
- package/dist/data-components/gantt/gantt.d.ts.map +0 -1
- package/dist/data-components/gantt/hooks/useGanttDrag.d.ts +0 -15
- package/dist/data-components/gantt/hooks/useGanttDrag.d.ts.map +0 -1
- package/dist/data-components/gantt/hooks/useGanttTimeline.d.ts +0 -18
- package/dist/data-components/gantt/hooks/useGanttTimeline.d.ts.map +0 -1
- package/dist/data-components/gantt/sidebar/gantt-sidebar-types.d.ts +0 -10
- package/dist/data-components/gantt/sidebar/gantt-sidebar-types.d.ts.map +0 -1
- package/dist/data-components/gantt/sidebar/gantt-sidebar.d.ts +0 -3
- package/dist/data-components/gantt/sidebar/gantt-sidebar.d.ts.map +0 -1
- package/dist/data-components/gantt/stories/gantt-stories-utils.d.ts +0 -13
- package/dist/data-components/gantt/stories/gantt-stories-utils.d.ts.map +0 -1
- package/dist/data-components/switcher/prop-form/prop-form-adapter.d.ts +0 -8
- package/dist/data-components/switcher/prop-form/prop-form-adapter.d.ts.map +0 -1
- package/dist/data-components/switcher/prop-form/prop-form-types.d.ts +0 -17
- package/dist/data-components/switcher/prop-form/prop-form-types.d.ts.map +0 -1
- package/dist/data-components/switcher/prop-form/prop-form.d.ts +0 -6
- package/dist/data-components/switcher/prop-form/prop-form.d.ts.map +0 -1
- package/dist/data-components/switcher/prop-schema/prop-schema-types.d.ts +0 -53
- package/dist/data-components/switcher/prop-schema/prop-schema-types.d.ts.map +0 -1
- package/dist/data-components/switcher/prop-schema/prop-schema-utils.d.ts +0 -15
- package/dist/data-components/switcher/prop-schema/prop-schema-utils.d.ts.map +0 -1
- package/dist/data-components/switcher/prop-schema/prop-schema.d.ts +0 -38
- package/dist/data-components/switcher/prop-schema/prop-schema.d.ts.map +0 -1
- package/dist/data-components/switcher/switcher-types.d.ts +0 -58
- package/dist/data-components/switcher/switcher-types.d.ts.map +0 -1
- package/dist/data-components/switcher/switcher.d.ts +0 -12
- package/dist/data-components/switcher/switcher.d.ts.map +0 -1
- package/dist/data-components/table-grid/aggregation/aggregation-utils.d.ts +0 -9
- package/dist/data-components/table-grid/aggregation/aggregation-utils.d.ts.map +0 -1
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-executor.d.ts +0 -9
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-executor.d.ts.map +0 -1
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-mock.d.ts +0 -13
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-mock.d.ts.map +0 -1
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-panel-types.d.ts +0 -14
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-panel-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-panel.d.ts +0 -3
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-panel.d.ts.map +0 -1
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-schema.d.ts +0 -4
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-schema.d.ts.map +0 -1
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-tools.d.ts +0 -6
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-tools.d.ts.map +0 -1
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-types.d.ts +0 -94
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-validator.d.ts +0 -5
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-validator.d.ts.map +0 -1
- package/dist/data-components/table-grid/external-functionalities/import/csv/autoDetect.d.ts +0 -7
- package/dist/data-components/table-grid/external-functionalities/import/csv/autoDetect.d.ts.map +0 -1
- package/dist/data-components/table-grid/external-functionalities/import/csv/createDataStructureFromFile.d.ts +0 -9
- package/dist/data-components/table-grid/external-functionalities/import/csv/createDataStructureFromFile.d.ts.map +0 -1
- package/dist/data-components/table-grid/external-functionalities/import/csv/csvToObj.d.ts +0 -6
- package/dist/data-components/table-grid/external-functionalities/import/csv/csvToObj.d.ts.map +0 -1
- package/dist/data-components/table-grid/external-functionalities/import/csv/detectDelimeter.d.ts +0 -6
- package/dist/data-components/table-grid/external-functionalities/import/csv/detectDelimeter.d.ts.map +0 -1
- package/dist/data-components/table-grid/external-functionalities/import/csv/index.d.ts +0 -7
- package/dist/data-components/table-grid/external-functionalities/import/csv/index.d.ts.map +0 -1
- package/dist/data-components/table-grid/external-functionalities/import/csv/inferColumns.d.ts +0 -6
- package/dist/data-components/table-grid/external-functionalities/import/csv/inferColumns.d.ts.map +0 -1
- package/dist/data-components/table-grid/external-functionalities/import/csv/parseDelimeted.d.ts +0 -7
- package/dist/data-components/table-grid/external-functionalities/import/csv/parseDelimeted.d.ts.map +0 -1
- package/dist/data-components/table-grid/footer/table-grid-footer-types.d.ts +0 -5
- package/dist/data-components/table-grid/footer/table-grid-footer-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/footer/table-grid-footer.d.ts +0 -3
- package/dist/data-components/table-grid/footer/table-grid-footer.d.ts.map +0 -1
- package/dist/data-components/table-grid/formula/evaluator.d.ts +0 -11
- package/dist/data-components/table-grid/formula/evaluator.d.ts.map +0 -1
- package/dist/data-components/table-grid/formula/formula-builder-types.d.ts +0 -8
- package/dist/data-components/table-grid/formula/formula-builder-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/formula/formula-builder.d.ts +0 -3
- package/dist/data-components/table-grid/formula/formula-builder.d.ts.map +0 -1
- package/dist/data-components/table-grid/formula/formula.test.d.ts +0 -2
- package/dist/data-components/table-grid/formula/formula.test.d.ts.map +0 -1
- package/dist/data-components/table-grid/formula/index.d.ts +0 -12
- package/dist/data-components/table-grid/formula/index.d.ts.map +0 -1
- package/dist/data-components/table-grid/formula/parser.d.ts +0 -24
- package/dist/data-components/table-grid/formula/parser.d.ts.map +0 -1
- package/dist/data-components/table-grid/formula/tokenizer.d.ts +0 -16
- package/dist/data-components/table-grid/formula/tokenizer.d.ts.map +0 -1
- package/dist/data-components/table-grid/formula/types.d.ts +0 -39
- package/dist/data-components/table-grid/formula/types.d.ts.map +0 -1
- package/dist/data-components/table-grid/grouping/grouping.d.ts +0 -15
- package/dist/data-components/table-grid/grouping/grouping.d.ts.map +0 -1
- package/dist/data-components/table-grid/header/grouping/group-panel-types.d.ts +0 -7
- package/dist/data-components/table-grid/header/grouping/group-panel-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/header/grouping/group-panel.d.ts +0 -3
- package/dist/data-components/table-grid/header/grouping/group-panel.d.ts.map +0 -1
- package/dist/data-components/table-grid/header/table-grid-column-menu.d.ts +0 -10
- package/dist/data-components/table-grid/header/table-grid-column-menu.d.ts.map +0 -1
- package/dist/data-components/table-grid/header/table-grid-header-types.d.ts +0 -6
- package/dist/data-components/table-grid/header/table-grid-header-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/header/table-grid-header.d.ts +0 -3
- package/dist/data-components/table-grid/header/table-grid-header.d.ts.map +0 -1
- package/dist/data-components/table-grid/hooks/use-table.d.ts +0 -3
- package/dist/data-components/table-grid/hooks/use-table.d.ts.map +0 -1
- package/dist/data-components/table-grid/pinning/pinning-utils.d.ts +0 -21
- package/dist/data-components/table-grid/pinning/pinning-utils.d.ts.map +0 -1
- package/dist/data-components/table-grid/pivot/pivot-config-panel-types.d.ts +0 -17
- package/dist/data-components/table-grid/pivot/pivot-config-panel-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/pivot/pivot-config-panel.d.ts +0 -3
- package/dist/data-components/table-grid/pivot/pivot-config-panel.d.ts.map +0 -1
- package/dist/data-components/table-grid/pivot/pivot-table.d.ts +0 -8
- package/dist/data-components/table-grid/pivot/pivot-table.d.ts.map +0 -1
- package/dist/data-components/table-grid/pivot/pivot-types.d.ts +0 -53
- package/dist/data-components/table-grid/pivot/pivot-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/pivot/pivot-utils.d.ts +0 -14
- package/dist/data-components/table-grid/pivot/pivot-utils.d.ts.map +0 -1
- package/dist/data-components/table-grid/row/table-grid-row-types.d.ts +0 -11
- package/dist/data-components/table-grid/row/table-grid-row-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/row/table-grid-row-utils.d.ts +0 -17
- package/dist/data-components/table-grid/row/table-grid-row-utils.d.ts.map +0 -1
- package/dist/data-components/table-grid/row/table-grid-row.d.ts +0 -3
- package/dist/data-components/table-grid/row/table-grid-row.d.ts.map +0 -1
- package/dist/data-components/table-grid/selection/selection-types.d.ts +0 -3
- package/dist/data-components/table-grid/selection/selection-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/selection/selection-utils.d.ts +0 -49
- package/dist/data-components/table-grid/selection/selection-utils.d.ts.map +0 -1
- package/dist/data-components/table-grid/sidebar/table-grid-sidebar-types.d.ts +0 -28
- package/dist/data-components/table-grid/sidebar/table-grid-sidebar-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/sidebar/table-grid-sidebar.d.ts +0 -3
- package/dist/data-components/table-grid/sidebar/table-grid-sidebar.d.ts.map +0 -1
- package/dist/data-components/table-grid/sorting/sorting.d.ts +0 -8
- package/dist/data-components/table-grid/sorting/sorting.d.ts.map +0 -1
- package/dist/data-components/table-grid/table-context/table-context-types.d.ts +0 -17
- package/dist/data-components/table-grid/table-context/table-context-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/table-context/table-context.d.ts +0 -3
- package/dist/data-components/table-grid/table-context/table-context.d.ts.map +0 -1
- package/dist/data-components/table-grid/table-grid-context.d.ts +0 -4
- package/dist/data-components/table-grid/table-grid-context.d.ts.map +0 -1
- package/dist/data-components/table-grid/table-grid-panels.d.ts +0 -22
- package/dist/data-components/table-grid/table-grid-panels.d.ts.map +0 -1
- package/dist/data-components/table-grid/table-grid-types.d.ts +0 -247
- package/dist/data-components/table-grid/table-grid-types.d.ts.map +0 -1
- package/dist/data-components/table-grid/table-grid.d.ts +0 -11
- package/dist/data-components/table-grid/table-grid.d.ts.map +0 -1
- package/dist/data-components/table-grid/table-utils.d.ts +0 -18
- package/dist/data-components/table-grid/table-utils.d.ts.map +0 -1
- package/dist/data-components/ui-layer/ui-layer-types.d.ts +0 -82
- package/dist/data-components/ui-layer/ui-layer-types.d.ts.map +0 -1
- package/dist/data-components/ui-layer/ui-layer-utils.d.ts +0 -13
- package/dist/data-components/ui-layer/ui-layer-utils.d.ts.map +0 -1
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap-types.d.ts +0 -15
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap-types.d.ts.map +0 -1
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap-utils.d.ts +0 -12
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap-utils.d.ts.map +0 -1
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap.d.ts +0 -4
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap.d.ts.map +0 -1
- package/dist/experimental-components/dashboard-builder/builder-canvas-hooks.d.ts +0 -47
- package/dist/experimental-components/dashboard-builder/builder-canvas-hooks.d.ts.map +0 -1
- package/dist/experimental-components/dashboard-builder/builder-canvas.d.ts +0 -33
- package/dist/experimental-components/dashboard-builder/builder-canvas.d.ts.map +0 -1
- package/dist/experimental-components/dashboard-builder/dashboard-builder-hooks.d.ts +0 -23
- package/dist/experimental-components/dashboard-builder/dashboard-builder-hooks.d.ts.map +0 -1
- package/dist/experimental-components/dashboard-builder/dashboard-builder-types.d.ts +0 -150
- package/dist/experimental-components/dashboard-builder/dashboard-builder-types.d.ts.map +0 -1
- package/dist/experimental-components/dashboard-builder/dashboard-builder-utils.d.ts +0 -28
- package/dist/experimental-components/dashboard-builder/dashboard-builder-utils.d.ts.map +0 -1
- package/dist/experimental-components/dashboard-builder/dashboard-builder.d.ts +0 -14
- package/dist/experimental-components/dashboard-builder/dashboard-builder.d.ts.map +0 -1
- package/dist/experimental-components/dashboard-builder/widget-configurator.d.ts +0 -24
- package/dist/experimental-components/dashboard-builder/widget-configurator.d.ts.map +0 -1
- package/dist/experimental-components/dashboard-builder/widget-palette.d.ts +0 -20
- package/dist/experimental-components/dashboard-builder/widget-palette.d.ts.map +0 -1
- package/dist/experimental-components/filter-builder/filter-builder-types.d.ts +0 -12
- package/dist/experimental-components/filter-builder/filter-builder-types.d.ts.map +0 -1
- package/dist/experimental-components/filter-builder/filter-builder.d.ts +0 -11
- package/dist/experimental-components/filter-builder/filter-builder.d.ts.map +0 -1
- package/dist/framework-components/appbar/appbar-assets.d.ts +0 -2
- package/dist/framework-components/appbar/appbar-assets.d.ts.map +0 -1
- package/dist/framework-components/appbar/appbar-types.d.ts +0 -19
- package/dist/framework-components/appbar/appbar-types.d.ts.map +0 -1
- package/dist/framework-components/appbar/appbar.d.ts +0 -9
- package/dist/framework-components/appbar/appbar.d.ts.map +0 -1
- package/dist/framework-components/breadcrumbs/breadcrumbs-types.d.ts +0 -14
- package/dist/framework-components/breadcrumbs/breadcrumbs-types.d.ts.map +0 -1
- package/dist/framework-components/breadcrumbs/breadcrumbs.d.ts +0 -4
- package/dist/framework-components/breadcrumbs/breadcrumbs.d.ts.map +0 -1
- package/dist/framework-components/dashboard/dashboard-context.d.ts +0 -12
- package/dist/framework-components/dashboard/dashboard-context.d.ts.map +0 -1
- package/dist/framework-components/dashboard/dashboard-types.d.ts +0 -35
- package/dist/framework-components/dashboard/dashboard-types.d.ts.map +0 -1
- package/dist/framework-components/dashboard/dashboard-widget-actions.d.ts +0 -1
- package/dist/framework-components/dashboard/dashboard-widget-actions.d.ts.map +0 -1
- package/dist/framework-components/dashboard/dashboard-widget-types.d.ts +0 -67
- package/dist/framework-components/dashboard/dashboard-widget-types.d.ts.map +0 -1
- package/dist/framework-components/dashboard/dashboard-widget.d.ts +0 -17
- package/dist/framework-components/dashboard/dashboard-widget.d.ts.map +0 -1
- package/dist/framework-components/dashboard/dashboard.d.ts +0 -11
- package/dist/framework-components/dashboard/dashboard.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/aggregation-engine.d.ts +0 -11
- package/dist/framework-components/dashboard/data-engine/aggregation-engine.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/data-engine-client.d.ts +0 -47
- package/dist/framework-components/dashboard/data-engine/data-engine-client.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/data-engine-types.d.ts +0 -119
- package/dist/framework-components/dashboard/data-engine/data-engine-types.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/data-engine.d.ts +0 -87
- package/dist/framework-components/dashboard/data-engine/data-engine.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/data-engine.test.d.ts +0 -2
- package/dist/framework-components/dashboard/data-engine/data-engine.test.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/data-engine.worker.d.ts +0 -2
- package/dist/framework-components/dashboard/data-engine/data-engine.worker.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/field-inference.d.ts +0 -10
- package/dist/framework-components/dashboard/data-engine/field-inference.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/filter-adapter.d.ts +0 -12
- package/dist/framework-components/dashboard/data-engine/filter-adapter.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/index.d.ts +0 -8
- package/dist/framework-components/dashboard/data-engine/index.d.ts.map +0 -1
- package/dist/framework-components/dashboard/data-engine/join-engine.d.ts +0 -17
- package/dist/framework-components/dashboard/data-engine/join-engine.d.ts.map +0 -1
- package/dist/framework-components/drawer/drawer-types.d.ts +0 -7
- package/dist/framework-components/drawer/drawer-types.d.ts.map +0 -1
- package/dist/framework-components/drawer/drawer.d.ts +0 -5
- package/dist/framework-components/drawer/drawer.d.ts.map +0 -1
- package/dist/framework-components/scaffold/scaffold-context.d.ts +0 -4
- package/dist/framework-components/scaffold/scaffold-context.d.ts.map +0 -1
- package/dist/framework-components/scaffold/scaffold-types.d.ts +0 -18
- package/dist/framework-components/scaffold/scaffold-types.d.ts.map +0 -1
- package/dist/framework-components/scaffold/scaffold.d.ts +0 -7
- package/dist/framework-components/scaffold/scaffold.d.ts.map +0 -1
- package/dist/framework-components/section/section-types.d.ts +0 -14
- package/dist/framework-components/section/section-types.d.ts.map +0 -1
- package/dist/framework-components/section/section.d.ts +0 -9
- package/dist/framework-components/section/section.d.ts.map +0 -1
- package/dist/framework-components/sidebar/sidebar-assets.d.ts +0 -2
- package/dist/framework-components/sidebar/sidebar-assets.d.ts.map +0 -1
- package/dist/framework-components/sidebar/sidebar-context.d.ts +0 -4
- package/dist/framework-components/sidebar/sidebar-context.d.ts.map +0 -1
- package/dist/framework-components/sidebar/sidebar-logo/sidebar-logo-types.d.ts +0 -4
- package/dist/framework-components/sidebar/sidebar-logo/sidebar-logo-types.d.ts.map +0 -1
- package/dist/framework-components/sidebar/sidebar-logo/sidebar-logo.d.ts +0 -3
- package/dist/framework-components/sidebar/sidebar-logo/sidebar-logo.d.ts.map +0 -1
- package/dist/framework-components/sidebar/sidebar-types.d.ts +0 -13
- package/dist/framework-components/sidebar/sidebar-types.d.ts.map +0 -1
- package/dist/framework-components/sidebar/sidebar.d.ts +0 -17
- package/dist/framework-components/sidebar/sidebar.d.ts.map +0 -1
- package/dist/hooks/useDynamicVirtualList.d.ts +0 -76
- package/dist/hooks/useDynamicVirtualList.d.ts.map +0 -1
- package/dist/hooks/useFixedVirtualList.d.ts +0 -35
- package/dist/hooks/useFixedVirtualList.d.ts.map +0 -1
- package/dist/hooks/useShortcut.d.ts +0 -20
- package/dist/hooks/useShortcut.d.ts.map +0 -1
- package/dist/hooks/useTour/useTour-context-internal.d.ts +0 -7
- package/dist/hooks/useTour/useTour-context-internal.d.ts.map +0 -1
- package/dist/hooks/useTour/useTour-context.d.ts +0 -10
- package/dist/hooks/useTour/useTour-context.d.ts.map +0 -1
- package/dist/hooks/useTour/useTour-types.d.ts +0 -192
- package/dist/hooks/useTour/useTour-types.d.ts.map +0 -1
- package/dist/hooks/useTour/useTour.d.ts +0 -3
- package/dist/hooks/useTour/useTour.d.ts.map +0 -1
- package/dist/hooks/useVirtualListScroll.d.ts +0 -41
- package/dist/hooks/useVirtualListScroll.d.ts.map +0 -1
- package/dist/index.d.ts.map +0 -1
- package/dist/providers/ai-assistant/ai-assistant-prompts.d.ts +0 -8
- package/dist/providers/ai-assistant/ai-assistant-prompts.d.ts.map +0 -1
- package/dist/providers/ai-assistant/ai-assistant-types.d.ts +0 -78
- package/dist/providers/ai-assistant/ai-assistant-types.d.ts.map +0 -1
- package/dist/providers/ai-assistant/ai-assistant-validator.d.ts +0 -23
- package/dist/providers/ai-assistant/ai-assistant-validator.d.ts.map +0 -1
- package/dist/providers/ai-assistant/ai-chat-panel-types.d.ts +0 -25
- package/dist/providers/ai-assistant/ai-chat-panel-types.d.ts.map +0 -1
- package/dist/providers/ai-assistant/ai-chat-panel.d.ts +0 -3
- package/dist/providers/ai-assistant/ai-chat-panel.d.ts.map +0 -1
- package/dist/providers/shortcut/shortcut-context.d.ts +0 -7
- package/dist/providers/shortcut/shortcut-context.d.ts.map +0 -1
- package/dist/providers/shortcut/shortcut-provider.d.ts +0 -35
- package/dist/providers/shortcut/shortcut-provider.d.ts.map +0 -1
- package/dist/providers/theme/index.d.ts +0 -4
- package/dist/providers/theme/index.d.ts.map +0 -1
- package/dist/providers/theme/theme-provider-types.d.ts +0 -6
- package/dist/providers/theme/theme-provider-types.d.ts.map +0 -1
- package/dist/providers/theme/themeProvider.d.ts +0 -10
- package/dist/providers/theme/themeProvider.d.ts.map +0 -1
- package/dist/restio-ui.cjs.js +0 -183
- package/dist/restio-ui.es.js +0 -37303
- package/dist/test/vitest.utils.d.ts +0 -1
- package/dist/test/vitest.utils.d.ts.map +0 -1
- package/dist/types/global-types.d.ts +0 -42
- package/dist/types/global-types.d.ts.map +0 -1
- package/dist/types/storybook-types.d.ts +0 -2
- package/dist/types/storybook-types.d.ts.map +0 -1
- package/dist/utility-components/avatar/avatar-types.d.ts +0 -16
- package/dist/utility-components/avatar/avatar-types.d.ts.map +0 -1
- package/dist/utility-components/avatar/avatar.d.ts +0 -5
- package/dist/utility-components/avatar/avatar.d.ts.map +0 -1
- package/dist/utility-components/chip/chip-types.d.ts +0 -17
- package/dist/utility-components/chip/chip-types.d.ts.map +0 -1
- package/dist/utility-components/chip/chip.d.ts +0 -4
- package/dist/utility-components/chip/chip.d.ts.map +0 -1
- package/dist/utility-components/helper-text/helper-text-types.d.ts +0 -20
- package/dist/utility-components/helper-text/helper-text-types.d.ts.map +0 -1
- package/dist/utility-components/helper-text/helper-text.d.ts +0 -3
- package/dist/utility-components/helper-text/helper-text.d.ts.map +0 -1
- package/dist/utility-components/icon/icon-assets.d.ts +0 -2
- package/dist/utility-components/icon/icon-assets.d.ts.map +0 -1
- package/dist/utility-components/icon/icon-types.d.ts +0 -24
- package/dist/utility-components/icon/icon-types.d.ts.map +0 -1
- package/dist/utility-components/icon/icon.d.ts +0 -4
- package/dist/utility-components/icon/icon.d.ts.map +0 -1
- package/dist/utility-components/label/label-types.d.ts +0 -19
- package/dist/utility-components/label/label-types.d.ts.map +0 -1
- package/dist/utility-components/label/label.d.ts +0 -3
- package/dist/utility-components/label/label.d.ts.map +0 -1
- package/dist/utility-components/overlay-panel/overlay-panel-types.d.ts +0 -69
- package/dist/utility-components/overlay-panel/overlay-panel-types.d.ts.map +0 -1
- package/dist/utility-components/overlay-panel/overlay-panel.d.ts +0 -5
- package/dist/utility-components/overlay-panel/overlay-panel.d.ts.map +0 -1
- package/dist/utility-components/overlay-panel/use-focus-trap.d.ts +0 -8
- package/dist/utility-components/overlay-panel/use-focus-trap.d.ts.map +0 -1
- package/dist/utility-components/skeleton/skeleton-types.d.ts +0 -7
- package/dist/utility-components/skeleton/skeleton-types.d.ts.map +0 -1
- package/dist/utility-components/skeleton/skeleton.d.ts +0 -4
- package/dist/utility-components/skeleton/skeleton.d.ts.map +0 -1
- package/dist/utility-components/stack/stack-types.d.ts +0 -9
- package/dist/utility-components/stack/stack-types.d.ts.map +0 -1
- package/dist/utility-components/stack/stack.d.ts +0 -4
- package/dist/utility-components/stack/stack.d.ts.map +0 -1
- package/dist/utility-components/toast/toast-types.d.ts +0 -9
- package/dist/utility-components/toast/toast-types.d.ts.map +0 -1
- package/dist/utility-components/toast/toast.d.ts +0 -5
- package/dist/utility-components/toast/toast.d.ts.map +0 -1
- package/dist/utils/general.d.ts +0 -9
- package/dist/utils/general.d.ts.map +0 -1
- package/dist/utils/shortcut-utils.d.ts +0 -44
- package/dist/utils/shortcut-utils.d.ts.map +0 -1
package/dist/data.js
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { A as s, B as t, C as e, F as r, G as o, H as i, I as n, K as u, L as C, M as c, N as p, O as L, P as d, R as l, U as y, V as P, j as m, k as K, ut as f, w as h, z as F } from "./src-DaTjVaGd.js";
|
|
2
|
+
export {
|
|
3
|
+
t as Calendar,
|
|
4
|
+
y as Card,
|
|
5
|
+
l as CardList,
|
|
6
|
+
o as Cell,
|
|
7
|
+
f as Chart,
|
|
8
|
+
h as DataComponentConfigurator,
|
|
9
|
+
F as Form,
|
|
10
|
+
i as Gantt,
|
|
11
|
+
r as KPI,
|
|
12
|
+
e as Switcher,
|
|
13
|
+
u as TableGrid,
|
|
14
|
+
C as Tree,
|
|
15
|
+
n as TreeCard,
|
|
16
|
+
s as cardLayoutPresetOptions,
|
|
17
|
+
m as cardLayoutWithIcon,
|
|
18
|
+
P as createDataStructureFromFile,
|
|
19
|
+
p as financeKpiLayout,
|
|
20
|
+
d as financeKpiLayoutWithIcon,
|
|
21
|
+
L as kpiLayoutPresetOptions,
|
|
22
|
+
c as resolveCardLayoutPreset,
|
|
23
|
+
K as resolveKpiLayoutPreset
|
|
24
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./src-gB-fpYMb.cjs");let s=require("react");s=l.__toESM(s,1);var xe=1;function pe(r,h){const p=r.col+r.w,b=r.row+r.h,S=h.col+h.w,f=h.row+h.h;return r.col<S&&p>h.col&&r.row<f&&b>h.row}function le(r){return r.col>=1&&r.col+r.w-1<=12&&r.row>=1&&r.row+r.h-1<=30}function de(r,h,p){for(const b of h)if(b.id!==p&&pe(r,b.position))return b.id;return null}function ce(r,h,p){for(let f=1;f<=30-h+1;f++)for(let g=1;g<=12-r+1;g++){const I={col:g,row:f,w:r,h};if(!de(I,p))return I}return{col:1,row:p.reduce((f,g)=>Math.max(f,g.position.row+g.position.h),1),w:r,h}}function fe(r,h){const p={};for(const b of r){const S=h[b.dataSourceId];if(!S)continue;const f=S.data??[],g=l.generateColumnsFromSchema(f.length>0?Object.keys(f[0]):[]),I=l.fieldOptionsFromColumns(b.columns??g),M=new Set,n=[];for(const v of I)M.has(v.id)||(M.add(v.id),n.push(v));p[b.dataSourceId]=n}return p}var ie=0;function oe(){return ie+=1,`widget-${Date.now()}-${ie}`}function ne(){return{version:1,name:"Untitled Dashboard",filters:null,widgets:[]}}function ge(r,h){const[p,b]=(0,s.useState)(r??ne),[S,f]=(0,s.useState)(null),[g,I]=(0,s.useState)(h?"view":"edit"),M=(0,s.useRef)(!1),n=(0,s.useCallback)(()=>{M.current=!0},[]),v=(0,s.useCallback)((i,u,D)=>{b(t=>{const _={id:oe(),title:`New ${i}`,componentType:i,dataSourceId:u,position:D};return{...t,widgets:[...t.widgets,_]}}),n()},[n]),R=(0,s.useCallback)(i=>{b(u=>{const D=ce(6,3,u.widgets),t={id:oe(),position:D,...i.widget};return{...u,widgets:[...u.widgets,t]}}),n()},[n]),W=(0,s.useCallback)(i=>{b(u=>({...u,widgets:u.widgets.filter(D=>D.id!==i)})),f(u=>u===i?null:u),n()},[n]),O=(0,s.useCallback)((i,u)=>{b(D=>({...D,widgets:D.widgets.map(t=>{if(t.id!==i)return t;const _={...t,...u};if(u.dataSourceId&&u.dataSourceId!==t.dataSourceId){const z=l.propSchemaRegistry[t.componentType]??[];_.columns=void 0,_.componentProps=l.buildDefaultPropsFromSchema(z),_.filters=void 0,_.uiConfig=void 0}return _})})),n()},[n]),j=(0,s.useCallback)((i,u)=>{O(i,{position:u})},[O]),B=(0,s.useCallback)(i=>{f(i)},[]),Y=p.widgets.find(i=>i.id===S)??null,H=(0,s.useCallback)(i=>{b(u=>({...u,name:i})),n()},[n]),a=(0,s.useCallback)(i=>{b(u=>({...u,filters:typeof i=="function"?i(u.filters):i})),n()},[n]),o=(0,s.useCallback)(i=>{b(i??ne()),f(null),M.current=!1},[]),P=(0,s.useCallback)(i=>{b(i),f(null),M.current=!1},[]);return{state:{config:p,selectedWidgetId:S,isDirty:M.current},mode:g,setMode:I,addWidget:v,addPrebuiltWidget:R,removeWidget:W,updateWidget:O,moveWidget:j,selectWidget:B,selectedWidget:Y,setName:H,setFilters:a,resetConfig:o,loadConfig:P}}var d={"rst-dashboard-builder":"_rst-dashboard-builder_ukxxh_2","rst-dashboard-builder-sidebar":"_rst-dashboard-builder-sidebar_ukxxh_18","rst-dashboard-builder-sidebar-header":"_rst-dashboard-builder-sidebar-header_ukxxh_28","rst-dashboard-builder-sidebar-list":"_rst-dashboard-builder-sidebar-list_ukxxh_33","rst-dashboard-builder-widget-type-item":"_rst-dashboard-builder-widget-type-item_ukxxh_40","rst-dashboard-builder-widget-type-label":"_rst-dashboard-builder-widget-type-label_ukxxh_59","rst-dashboard-builder-widget-type-desc":"_rst-dashboard-builder-widget-type-desc_ukxxh_63","rst-dashboard-builder-main":"_rst-dashboard-builder-main_ukxxh_69","rst-dashboard-builder-toolbar":"_rst-dashboard-builder-toolbar_ukxxh_77","rst-dashboard-builder-toolbar-left":"_rst-dashboard-builder-toolbar-left_ukxxh_87","rst-dashboard-builder-toolbar-right":"_rst-dashboard-builder-toolbar-right_ukxxh_93","rst-dashboard-builder-name-input":"_rst-dashboard-builder-name-input_ukxxh_99","rst-dashboard-builder-name-display":"_rst-dashboard-builder-name-display_ukxxh_115","rst-dashboard-builder-view":"_rst-dashboard-builder-view_ukxxh_122","rst-dashboard-widget":"_rst-dashboard-widget_ukxxh_146","rst-switcher":"_rst-switcher_ukxxh_170","rst-dashboard-builder-canvas":"_rst-dashboard-builder-canvas_ukxxh_183","rst-dashboard-builder-grid":"_rst-dashboard-builder-grid_ukxxh_191","rst-dashboard-builder-grid-cell":"_rst-dashboard-builder-grid-cell_ukxxh_201","rst-dashboard-builder-grid-cell-view":"_rst-dashboard-builder-grid-cell-view_ukxxh_213","rst-dashboard-builder-grid-empty":"_rst-dashboard-builder-grid-empty_ukxxh_219","rst-dashboard-builder-widget":"_rst-dashboard-builder-widget_ukxxh_40","rst-dashboard-builder-widget-view":"_rst-dashboard-builder-widget-view_ukxxh_290","rst-dashboard-builder-widget-selected":"_rst-dashboard-builder-widget-selected_ukxxh_298","rst-dashboard-builder-widget-dragging":"_rst-dashboard-builder-widget-dragging_ukxxh_304","rst-dashboard-builder-widget-collision":"_rst-dashboard-builder-widget-collision_ukxxh_310","rst-dashboard-builder-resize-handle-n":"_rst-dashboard-builder-resize-handle-n_ukxxh_317","rst-dashboard-builder-resize-handle-s":"_rst-dashboard-builder-resize-handle-s_ukxxh_318","rst-dashboard-builder-resize-handle-e":"_rst-dashboard-builder-resize-handle-e_ukxxh_319","rst-dashboard-builder-resize-handle-w":"_rst-dashboard-builder-resize-handle-w_ukxxh_320","rst-dashboard-builder-resize-handle-ne":"_rst-dashboard-builder-resize-handle-ne_ukxxh_321","rst-dashboard-builder-resize-handle-nw":"_rst-dashboard-builder-resize-handle-nw_ukxxh_322","rst-dashboard-builder-resize-handle-se":"_rst-dashboard-builder-resize-handle-se_ukxxh_323","rst-dashboard-builder-resize-handle-sw":"_rst-dashboard-builder-resize-handle-sw_ukxxh_324","rst-dashboard-builder-filter-body":"_rst-dashboard-builder-filter-body_ukxxh_540","rst-dashboard-builder-filter-tabs":"_rst-dashboard-builder-filter-tabs_ukxxh_548","rst-dashboard-builder-configurator":"_rst-dashboard-builder-configurator_ukxxh_557","rst-dashboard-builder-configurator-header":"_rst-dashboard-builder-configurator-header_ukxxh_567","rst-dashboard-builder-configurator-body":"_rst-dashboard-builder-configurator-body_ukxxh_575","rst-dashboard-builder-configurator-empty":"_rst-dashboard-builder-configurator-empty_ukxxh_582","rst-dashboard-builder-configurator-divider":"_rst-dashboard-builder-configurator-divider_ukxxh_593","rst-dashboard-builder-field":"_rst-dashboard-builder-field_ukxxh_599","rst-dashboard-builder-field-label":"_rst-dashboard-builder-field-label_ukxxh_605","rst-dashboard-builder-checkbox-row":"_rst-dashboard-builder-checkbox-row_ukxxh_611","rst-dashboard-builder-checkbox-label":"_rst-dashboard-builder-checkbox-label_ukxxh_618","rst-dashboard-builder-drag-ghost":"_rst-dashboard-builder-drag-ghost_ukxxh_624","rst-dashboard-builder-drop-zone":"_rst-dashboard-builder-drop-zone_ukxxh_638","rst-dashboard-builder-add-widget-item":"_rst-dashboard-builder-add-widget-item_ukxxh_646","rst-dashboard-builder-add-widget-item-label":"_rst-dashboard-builder-add-widget-item-label_ukxxh_667","rst-dashboard-builder-add-widget-item-desc":"_rst-dashboard-builder-add-widget-item-desc_ukxxh_673","rst-dashboard-builder-template-wrapper":"_rst-dashboard-builder-template-wrapper_ukxxh_679","rst-dashboard-builder-template-picker":"_rst-dashboard-builder-template-picker_ukxxh_683","rst-dashboard-builder-template-picker-header":"_rst-dashboard-builder-template-picker-header_ukxxh_697","rst-dashboard-builder-template-item":"_rst-dashboard-builder-template-item_ukxxh_705","rst-dashboard-builder-template-item-name":"_rst-dashboard-builder-template-item-name_ukxxh_727","rst-dashboard-builder-template-item-desc":"_rst-dashboard-builder-template-item-desc_ukxxh_733"},K=12,ee=30,se=12;function _e({widgets:r,onMoveWidget:h,onAddWidget:p,onChange:b}){const S=(0,s.useRef)(null),[f,g]=(0,s.useState)(null),[I,M]=(0,s.useState)(null),[n,v]=(0,s.useState)(null),[R,W]=(0,s.useState)(null),[O,j]=(0,s.useState)(!1),[B,Y]=(0,s.useState)(null),[H,a]=(0,s.useState)(null),[o,P]=(0,s.useState)(null),[i,u]=(0,s.useState)(null),[D,t]=(0,s.useState)(!1),_=(0,s.useCallback)(()=>S.current?{colWidth:(S.current.getBoundingClientRect().width-se*(K-1))/K,rowHeight:92}:null,[]),z=(0,s.useCallback)((x,k)=>{if(!S.current)return{col:1,row:1};const y=S.current.getBoundingClientRect(),w=(y.width-se*(K-1))/K;return{col:Math.max(1,Math.min(K,Math.round((x-y.left)/(w+se))+1)),row:Math.max(1,Math.min(ee,Math.round((k-y.top)/92)+1))}},[]),J=(0,s.useCallback)(x=>{if(x.preventDefault(),x.dataTransfer.types.includes("application/widget-type")){x.dataTransfer.dropEffect="copy";return}if(x.dataTransfer.types.includes("application/move-widget")&&f&&I&&n){x.dataTransfer.dropEffect="move";const k=r.find(N=>N.id===f);if(!k)return;const y=_();if(!y)return;const w=x.clientX-I.x,L=x.clientY-I.y,ae=Math.round(w/(y.colWidth+se)),V=Math.round(L/y.rowHeight),$={col:Math.max(1,Math.min(K-k.position.w+1,n.col+ae)),row:Math.max(1,Math.min(ee-k.position.h+1,n.row+V)),w:k.position.w,h:k.position.h};W($);const E=de($,r,f);j(E!==null)}},[f,I,n,_,r]),Q=(0,s.useCallback)(x=>{x.preventDefault();const k=x.dataTransfer.getData("application/widget-type");if(k){const{col:y,row:w}=z(x.clientX,x.clientY),L={col:y,row:w,w:4,h:3};if(y+4-1>K&&(L.col=9),w+3-1>ee&&(L.row=28),de(L,r))return;p(k,"",L),b();return}f&&R&&(!O&&le(R)&&(h(f,R),b()),g(null),M(null),v(null),W(null),j(!1))},[z,r,p,b,f,R,O,h]),Z=(0,s.useCallback)((x,k)=>{x.stopPropagation(),x.dataTransfer.setData("application/move-widget",k.id),x.dataTransfer.effectAllowed="move",g(k.id),M({x:x.clientX,y:x.clientY}),v({...k.position}),W({...k.position}),j(!1)},[]),m=(0,s.useCallback)(()=>{g(null),M(null),v(null),W(null),j(!1)},[]),re=(0,s.useCallback)((x,k,y)=>{x.stopPropagation(),x.preventDefault(),Y(k.id),a(y),P({...k.position}),u({x:x.clientX,y:x.clientY}),t(!1)},[]);return(0,s.useEffect)(()=>{if(!B||!H||!o||!i)return;const x=y=>{if(!r.find(C=>C.id===B))return;const w=_();if(!w)return;const L=y.clientX-i.x,ae=y.clientY-i.y,V=Math.round(L/(w.colWidth+se)),$=Math.round(ae/w.rowHeight),E=o.col,N=o.row,A=o.w,X=o.h;let F={...o};switch(H){case"e":{const C=Math.max(1,Math.min(K-E+1,A+V));F={...F,w:C};break}case"w":{const C=Math.max(1,Math.min(E+A-1,E+V)),T=E+A-C;F={...o,col:C,w:Math.max(1,T)};break}case"s":{const C=Math.max(1,Math.min(ee-N+1,X+$));F={...o,h:C};break}case"n":{const C=Math.max(1,Math.min(N+X-1,N+$)),T=N+X-C;F={...o,row:C,h:Math.max(1,T)};break}case"se":{const C=Math.max(1,Math.min(K-E+1,A+V)),T=Math.max(1,Math.min(ee-N+1,X+$));F={...o,w:C,h:T};break}case"sw":{const C=Math.max(1,Math.min(E+A-1,E+V)),T=E+A-C,c=Math.max(1,Math.min(ee-N+1,X+$));F={...o,col:C,w:Math.max(1,T),h:c};break}case"ne":{const C=Math.max(1,Math.min(N+X-1,N+$)),T=N+X-C,c=Math.max(1,Math.min(K-E+1,A+V));F={...o,row:C,h:Math.max(1,T),w:c};break}case"nw":{const C=Math.max(1,Math.min(E+A-1,E+V)),T=Math.max(1,Math.min(N+X-1,N+$)),c=E+A-C,G=N+X-T;F={col:C,row:T,w:Math.max(1,c),h:Math.max(1,G)};break}}W(F),g(B);const te=de(F,r,B);t(te!==null),j(te!==null)},k=()=>{r.find(y=>y.id===B)&&R&&!D&&le(R)&&(h(B,R),b()),Y(null),a(null),P(null),u(null),t(!1),g(null),M(null),v(null),W(null),j(!1)};return document.addEventListener("mousemove",x),document.addEventListener("mouseup",k),()=>{document.removeEventListener("mousemove",x),document.removeEventListener("mouseup",k)}},[B,H,o,i,r,R,D,_,h,b]),{gridRef:S,draggingWidgetId:f,dragPreviewPos:R,hasCollision:O,resizeCollision:D,handleDragOver:J,handleDrop:Q,handleWidgetDragStart:Z,handleWidgetDragEnd:m,handleResizeStart:re,pixelToGrid:z}}var e=l.require_jsx_runtime(),ve=12,ke=20,ue=({widgets:r,selectedWidgetId:h,dataSources:p,onSelectWidget:b,onMoveWidget:S,onRemoveWidget:f,onAddWidget:g,onChange:I,getWidgetActions:M,mode:n="edit"})=>{const v=n==="view",{gridRef:R,draggingWidgetId:W,dragPreviewPos:O,hasCollision:j,handleDragOver:B,handleDrop:Y,handleWidgetDragStart:H,handleWidgetDragEnd:a,handleResizeStart:o}=_e({widgets:r,onMoveWidget:S,onAddWidget:g,onChange:I}),P=(0,s.useCallback)((t,_)=>{t.stopPropagation(),b(_)},[b]),i=(0,s.useCallback)(()=>{b(null)},[b]),u=(0,s.useCallback)(t=>{const _=p[t.dataSourceId]?.data??[],z=_.length>0?Object.keys(_[0]):[];return{data:_,columns:t.columns??l.generateColumnsFromSchema(z)}},[p]),D=[];for(let t=1;t<=ke;t++)for(let _=1;_<=ve;_++){const z=v?d["rst-dashboard-builder-grid-cell-view"]:d["rst-dashboard-builder-grid-cell"];D.push((0,e.jsx)("div",{className:z,style:{gridColumn:_,gridRow:t}},`cell-${t}-${_}`))}return(0,e.jsx)("div",{className:d["rst-dashboard-builder-canvas"],onClick:i,children:(0,e.jsxs)("div",{ref:R,className:d["rst-dashboard-builder-grid"],onDragOver:B,onDrop:Y,children:[D,r.length===0&&(0,e.jsx)("div",{className:d["rst-dashboard-builder-grid-empty"],children:"Drag a widget from the palette to get started"}),r.map(t=>{const _=!v&&t.id===h,z=!v&&t.id===W,J=u(t),Q=z&&O?O:t.position,Z=z&&j;return(0,e.jsxs)("div",{className:[d["rst-dashboard-builder-widget"],v?d["rst-dashboard-builder-widget-view"]:"",_?d["rst-dashboard-builder-widget-selected"]:"",z?d["rst-dashboard-builder-widget-dragging"]:"",Z?d["rst-dashboard-builder-widget-collision"]:""].filter(Boolean).join(" "),style:{gridColumn:`${Q.col} / span ${Q.w}`,gridRow:`${Q.row} / span ${Q.h}`},draggable:!v,...v?{}:{onDragStart:m=>H(m,t),onDragEnd:a,onClick:m=>P(m,t.id),role:"button",tabIndex:0,"aria-label":`Widget: ${t.title}`,onKeyDown:m=>{(m.key==="Enter"||m.key===" ")&&(m.preventDefault(),b(t.id)),(m.key==="Delete"||m.key==="Backspace")&&(m.preventDefault(),f(t.id),I())}},children:[(0,e.jsx)(l.DashboardWidget,{id:t.id,dataSourceId:t.dataSourceId,title:t.title,subtitle:t.subtitle,icon:t.icon,data:J.data,columns:J.columns,enableExport:M?.(t).enableExport??!0,enableScreenshot:M?.(t).enableScreenshot??!1,enableExpand:M?.(t).enableExpand??!0,enableFilter:M?.(t).enableFilter??!1,fieldOptions:l.fieldOptionsFromColumns(J.columns),children:({data:m})=>(0,e.jsx)(l.Switcher,{data:m,columns:J.columns,activeComponent:t.componentType,componentProps:t.componentProps,showConfigurator:!1})}),!v&&_&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)("div",{className:d["rst-dashboard-builder-resize-handle-n"],onMouseDown:m=>o(m,t,"n")}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-resize-handle-s"],onMouseDown:m=>o(m,t,"s")}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-resize-handle-e"],onMouseDown:m=>o(m,t,"e")}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-resize-handle-w"],onMouseDown:m=>o(m,t,"w")}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-resize-handle-ne"],onMouseDown:m=>o(m,t,"ne")}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-resize-handle-nw"],onMouseDown:m=>o(m,t,"nw")}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-resize-handle-se"],onMouseDown:m=>o(m,t,"se")}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-resize-handle-sw"],onMouseDown:m=>o(m,t,"sw")})]})]},`${t.id}::${t.dataSourceId}`)})]})})};ue.displayName="BuilderCanvas";var Ce=[{type:"table-grid",label:"Table",icon:"table",description:"Sortable, filterable data table"},{type:"chart",label:"Chart",icon:"chart",description:"Bar, line, pie charts"},{type:"calendar",label:"Calendar",icon:"calendar",description:"Calendar view of events"},{type:"card-list",label:"Card List",icon:"list",description:"Visual card layout"},{type:"form",label:"Form",icon:"form",description:"Editable form from schema"},{type:"gantt",label:"Gantt",icon:"chart-gantt",description:"Project timeline view"},{type:"kpi",label:"KPI",icon:"chart",description:"Single-metric KPI card"}],be=({widget:r,dataSources:h,onUpdate:p,onRemove:b,onClose:S,onAddWidget:f,prebuiltSections:g,onAddPrebuiltSection:I})=>{const M=Object.values(h).map(a=>({value:a.id,label:a.name})),n=(0,s.useMemo)(()=>[{value:"",id:"none"},...Object.keys(l.svgAssets).map(a=>({value:a,leadingVisual:a}))],[]),v=r?.dataSourceId,R=(0,s.useMemo)(()=>{if(!v)return[];const a=h[v];return a?a.fields.map(o=>({id:o.id,header:o.name,accessorKey:o.id})):[]},[v,h]),W=(0,s.useMemo)(()=>l.propSchemaRegistry[r?.componentType??"table-grid"]??[],[r?.componentType]),O=(0,s.useMemo)(()=>r?.componentProps??l.buildDefaultPropsFromSchema(W),[r?.componentProps,W]),j=(0,s.useCallback)((a,o)=>{p({[a]:o})},[p]),B=(0,s.useCallback)(a=>{p({componentType:a,componentProps:l.buildDefaultPropsFromSchema(l.propSchemaRegistry[a]??[])})},[p]),Y=(0,s.useCallback)((a,o)=>{p({componentProps:{...O,[a]:o}})},[O,p]),H=(0,s.useMemo)(()=>!g||g.length===0?[]:g.filter(a=>a.version===1),[g]);return r?(0,e.jsxs)("aside",{className:d["rst-dashboard-builder-configurator"],"aria-label":"Widget configurator",children:[(0,e.jsxs)("div",{className:d["rst-dashboard-builder-configurator-header"],children:[(0,e.jsx)(l.Typography,{variant:"heading",children:"Configure"}),(0,e.jsx)(l.Button,{variant:"invisible",size:"small",leadingVisual:"close",onClick:S,"aria-label":"Close configurator"})]}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-configurator-body"],children:[(0,e.jsxs)("div",{className:d["rst-dashboard-builder-field"],children:[(0,e.jsx)("label",{className:d["rst-dashboard-builder-field-label"],children:"Title"}),(0,e.jsx)(l.TextInput,{value:r.title,onChange:a=>j("title",a??""),placeholder:"Widget title"})]}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-field"],children:[(0,e.jsx)("label",{className:d["rst-dashboard-builder-field-label"],children:"Subtitle"}),(0,e.jsx)(l.TextInput,{value:r.subtitle??"",onChange:a=>j("subtitle",a||void 0),placeholder:"Optional subtitle"})]}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-field"],children:[(0,e.jsx)("label",{className:d["rst-dashboard-builder-field-label"],children:"Icon"}),(0,e.jsx)(l.Select,{value:r.icon??"",onChange:a=>j("icon",a||void 0),options:n,renderList:({options:a,value:o,onChange:P,onClose:i})=>(0,e.jsx)(l.List,{options:a,activeIndex:[typeof o=="string"?o:""],onClick:u=>{P(u.value),i()},showFilter:!0})})]}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-field"],children:[(0,e.jsx)("label",{className:d["rst-dashboard-builder-field-label"],children:"Data Source"}),(0,e.jsx)(l.Select,{value:r.dataSourceId,onChange:a=>j("dataSourceId",a),options:M})]}),r.dataSourceId&&h[r.dataSourceId]&&(0,e.jsxs)("div",{className:d["rst-dashboard-builder-field"],children:[(0,e.jsx)("label",{className:d["rst-dashboard-builder-field-label"],children:"Columns"}),(0,e.jsx)(l.CheckboxGroup,{options:h[r.dataSourceId].fields.map(a=>({value:a.id,label:a.name})),value:r.columns?.map(a=>a.id).filter(Boolean)??h[r.dataSourceId].fields.map(a=>a.id),onChange:a=>{const o=h[r.dataSourceId],P=a.map(i=>o.fields.find(u=>u.id===i)).filter(Boolean).map(i=>({id:i.id,header:i.name,accessorKey:i.id}));p({columns:P.length===o.fields.length?void 0:P})}})]}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-field"],children:[(0,e.jsx)("label",{className:d["rst-dashboard-builder-field-label"],children:"Actions"}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-checkbox-row"],children:[(0,e.jsx)(l.Checkbox,{checked:r.enableExport??!0,onChange:a=>j("enableExport",a)}),(0,e.jsx)("span",{className:d["rst-dashboard-builder-checkbox-label"],children:"Export CSV"})]}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-checkbox-row"],children:[(0,e.jsx)(l.Checkbox,{checked:r.enableScreenshot??!1,onChange:a=>j("enableScreenshot",a)}),(0,e.jsx)("span",{className:d["rst-dashboard-builder-checkbox-label"],children:"Screenshot"})]}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-checkbox-row"],children:[(0,e.jsx)(l.Checkbox,{checked:r.enableExpand??!0,onChange:a=>j("enableExpand",a)}),(0,e.jsx)("span",{className:d["rst-dashboard-builder-checkbox-label"],children:"Expand"})]}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-checkbox-row"],children:[(0,e.jsx)(l.Checkbox,{checked:r.enableFilter??!0,onChange:a=>j("enableFilter",a)}),(0,e.jsx)("span",{className:d["rst-dashboard-builder-checkbox-label"],children:"Filter"})]})]}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-configurator-divider"]}),(0,e.jsx)(l.DataComponentConfigurator,{schema:W,values:O,onChange:Y,columns:R,scope:"all",componentId:r.componentType,onComponentChange:B,componentMetaList:l.dataComponentMetaList},r.dataSourceId??"no-ds"),(0,e.jsx)("div",{className:d["rst-dashboard-builder-configurator-divider"]}),(0,e.jsx)(l.Button,{variant:"danger",size:"small",value:"Remove widget",leadingVisual:"trash",onClick:b})]})]}):(0,e.jsxs)("aside",{className:d["rst-dashboard-builder-configurator"],"aria-label":"Add widget",children:[(0,e.jsx)("div",{className:d["rst-dashboard-builder-configurator-header"],children:(0,e.jsx)(l.Typography,{variant:"heading",children:"Add Widget"})}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-configurator-body"],children:[Ce.map(a=>(0,e.jsxs)("button",{className:d["rst-dashboard-builder-add-widget-item"],onClick:()=>f(a.type),children:[(0,e.jsx)(l.Icon,{src:a.icon}),(0,e.jsxs)("div",{children:[(0,e.jsx)("div",{className:d["rst-dashboard-builder-add-widget-item-label"],children:a.label}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-add-widget-item-desc"],children:a.description})]})]},a.type)),H.length>0&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)("div",{className:d["rst-dashboard-builder-configurator-divider"]}),(0,e.jsx)(l.Typography,{variant:"heading",children:"Pre-built Sections"}),H.map(a=>(0,e.jsxs)("button",{className:d["rst-dashboard-builder-add-widget-item"],onClick:()=>I?.(a),children:[(0,e.jsx)(l.Icon,{src:"layout"}),(0,e.jsxs)("div",{children:[(0,e.jsx)("div",{className:d["rst-dashboard-builder-add-widget-item-label"],children:a.name}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-add-widget-item-desc"],children:a.description})]})]},a.name))]})]})]})};be.displayName="WidgetConfigurator";var he=({dataSources:r,initialConfig:h,templates:p,prebuiltSections:b,onSave:S,onChange:f,widgetActionDefaults:g,readOnly:I,className:M})=>{const{state:n,mode:v,setMode:R,addWidget:W,addPrebuiltWidget:O,removeWidget:j,updateWidget:B,moveWidget:Y,selectWidget:H,selectedWidget:a,setName:o,setFilters:P,loadConfig:i}=ge(h,I),[u,D]=(0,s.useState)(!1),[t,_]=(0,s.useState)("dialog"),[z,J]=(0,s.useState)(null),[Q,Z]=(0,s.useState)(null),[m,re]=(0,s.useState)(!1),[x,k]=(0,s.useState)(null),y=(0,s.useMemo)(()=>fe(n.config.widgets,r),[n.config.widgets,r]),w=v==="view",L=w?Q:n.config.filters;(0,s.useEffect)(()=>{u&&k(L)},[u]);const ae=(0,s.useCallback)(()=>{w?Z(x):P(x),D(!1)},[x,w,P]);(0,s.useEffect)(()=>{w&&!m&&(Z(n.config.filters),re(!0)),w||re(!1)},[w,m,n.config.filters]);const V=(0,s.useRef)(f);V.current=f;const $=(0,s.useCallback)((c,G)=>{(w?Z:P)(U=>({...U??{},[c]:G}))},[w,P]),E=(0,s.useMemo)(()=>({filters:L,onFilterChange:$}),[L,$]),N=(0,s.useMemo)(()=>!p||p.length===0?[]:p.filter(c=>c.version===1),[p]),A=(0,s.useMemo)(()=>N.map(c=>({value:c.name,id:c.name,description:c.description})),[N]),X=(0,s.useCallback)(c=>{const G=N.find(q=>q.name===c);if(!G)return;const U={version:1,...G.config};i(U)},[N,i]),F=(0,s.useMemo)(()=>({enableExport:g?.enableExport??!0,enableScreenshot:g?.enableScreenshot??!1,enableExpand:g?.enableExpand??!0,enableFilter:g?.enableFilter??!0}),[g]),te=(0,s.useCallback)(c=>({enableExport:c.enableExport??F.enableExport,enableScreenshot:c.enableScreenshot??F.enableScreenshot,enableExpand:c.enableExpand??F.enableExpand,enableFilter:c.enableFilter??F.enableFilter}),[F]);(0,s.useEffect)(()=>{V.current?.(n.config)},[n.config]);const C=[d["rst-dashboard-builder"],M].filter(Boolean).join(" "),T=(0,s.useCallback)(()=>{S(n.config)},[n.config,S]);return(0,e.jsx)("div",{className:C,children:(0,e.jsxs)("div",{className:d["rst-dashboard-builder-main"],children:[(0,e.jsxs)("div",{className:d["rst-dashboard-builder-toolbar"],children:[(0,e.jsxs)("div",{className:d["rst-dashboard-builder-toolbar-left"],children:[w?(0,e.jsx)("span",{className:d["rst-dashboard-builder-name-display"],children:n.config.name}):(0,e.jsx)("input",{className:d["rst-dashboard-builder-name-input"],type:"text",value:n.config.name,onChange:c=>o(c.target.value),placeholder:"Dashboard name","aria-label":"Dashboard name"}),Object.keys(y).length>0&&(0,e.jsx)(l.Button,{variant:"invisible",size:"small",leadingVisual:"filter",onClick:()=>D(c=>!c),"aria-label":"Toggle filter panel","aria-pressed":u})]}),(0,e.jsxs)("div",{className:d["rst-dashboard-builder-toolbar-right"],children:[N.length>0&&!w&&(0,e.jsx)(l.ButtonDropdown,{options:A,onChange:X,placeholder:"Load Template",size:"small"}),!I&&(0,e.jsx)(l.ButtonGroup,{value:v,options:[{value:"edit"},{value:"view"}],onChange:c=>R(c)}),!w&&(0,e.jsx)(l.Button,{variant:"primary",size:"small",value:"Save",onClick:T})]})]}),(0,e.jsx)(l.DashboardContext,{value:E,children:(0,e.jsxs)("div",{style:{display:"flex",flex:1,overflow:"hidden"},children:[(0,e.jsx)(ue,{mode:v,widgets:n.config.widgets,selectedWidgetId:n.selectedWidgetId,dataSources:r,onSelectWidget:H,onMoveWidget:Y,onRemoveWidget:j,onAddWidget:W,onChange:()=>{},getWidgetActions:te}),u&&Object.keys(y).length>0&&(0,e.jsxs)(l.OverlayPanel,{open:u,variant:t,position:t==="dialog"?"center":"right",onClose:()=>D(!1),closeOnEscape:!0,closeOnClickOutside:t==="dialog",width:t==="sidepanel"?360:void 0,maxWidth:t==="dialog"?640:void 0,maxHeight:t==="dialog"?"80vh":void 0,"aria-label":"Dashboard filters",children:[(0,e.jsx)(l.OverlayPanel.Header,{title:"Filters",onClose:()=>D(!1),actions:(0,e.jsx)(l.Button,{variant:"invisible",size:"small",leadingVisual:t==="dialog"?"square-half":"open-center",onClick:()=>_(c=>c==="dialog"?"sidepanel":"dialog"),"aria-label":t==="dialog"?"Switch to side panel":"Switch to dialog"})}),(0,e.jsx)("div",{className:d["rst-dashboard-builder-filter-body"],children:(()=>{const c=Object.keys(y);if(c.length===0)return(0,e.jsx)("div",{style:{padding:"var(--rst-space-default)"},children:"No data sources to filter."});const G=z&&c.includes(z)?z:c[0],U=x?.[G]??l.emptyFilterGroup();return(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)("div",{className:d["rst-dashboard-builder-filter-tabs"],children:c.map(q=>(0,e.jsx)(l.Button,{value:q,variant:q===G?"base":"invisible",size:"small",onClick:()=>J(q),children:q},q))}),(0,e.jsx)(l.FilterBuilder,{filters:U,onChange:q=>k(me=>({...me??{},[G]:q.filters.length===0?null:q})),fieldOptions:y[G]})]})})()}),(0,e.jsxs)(l.OverlayPanel.Footer,{children:[(0,e.jsx)(l.Button,{variant:"invisible",size:"small",value:"Clear",onClick:()=>k({})}),(0,e.jsx)(l.Button,{variant:"primary",size:"small",value:"Apply",onClick:ae})]})]}),!w&&(0,e.jsx)(be,{widget:a,dataSources:r,onUpdate:c=>{a&&B(a.id,c)},onRemove:()=>{a&&j(a.id)},onClose:()=>H(null),onAddWidget:c=>{const G=Object.values(r)[0],U=ce(6,3,n.config.widgets);W(c,G?.id??"",U)},prebuiltSections:b,onAddPrebuiltSection:c=>{O(c)}})]})})]})})};he.displayName="DashboardBuilder";exports.DASHBOARD_CONFIG_VERSION=xe;exports.DashboardBuilder=he;
|
|
@@ -0,0 +1,486 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
/** Interface for an option in a component */
|
|
4
|
+
interface Option {
|
|
5
|
+
value: string;
|
|
6
|
+
/** Human-readable label shown in the UI; falls back to `value` when omitted. */
|
|
7
|
+
label?: string;
|
|
8
|
+
id?: string;
|
|
9
|
+
leadingVisual?: string;
|
|
10
|
+
imageSrc?: string;
|
|
11
|
+
imageAlt?: string;
|
|
12
|
+
description?: string;
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
children?: Option[];
|
|
15
|
+
onClick?: (option: Option) => void;
|
|
16
|
+
}
|
|
17
|
+
/** Sizing values */
|
|
18
|
+
type Size = "extraSmall" | "small" | "default" | "large" | "extraLarge";
|
|
19
|
+
/** State for component */
|
|
20
|
+
type State = "base" | "success" | "warning" | "danger" | "info" | "idle";
|
|
21
|
+
declare const CellType: {
|
|
22
|
+
readonly SELECT: "SELECT";
|
|
23
|
+
readonly MULTI_SELECT: "MULTI_SELECT";
|
|
24
|
+
readonly BUTTON_GROUP: "BUTTON_GROUP";
|
|
25
|
+
readonly TEXT: "TEXT";
|
|
26
|
+
readonly TEXTAREA: "TEXTAREA";
|
|
27
|
+
readonly NUMBER: "NUMBER";
|
|
28
|
+
readonly DATE: "DATE";
|
|
29
|
+
readonly DATE_RANGE: "DATE_RANGE";
|
|
30
|
+
readonly IMAGE: "IMAGE";
|
|
31
|
+
readonly TABLE_GRID: "TABLE_GRID";
|
|
32
|
+
readonly CHART: "CHART";
|
|
33
|
+
readonly CHART_SERIES: "CHART_SERIES";
|
|
34
|
+
readonly PROGRESS: "PROGRESS";
|
|
35
|
+
readonly CHECKBOX_GROUP: "CHECKBOX_GROUP";
|
|
36
|
+
readonly CHECKBOX: "CHECKBOX";
|
|
37
|
+
readonly RADIO_GROUP: "RADIO_GROUP";
|
|
38
|
+
readonly COLORS: "COLORS";
|
|
39
|
+
readonly SPARKLINE: "SPARKLINE";
|
|
40
|
+
readonly BUTTON_DROPDOWN: "BUTTON_DROPDOWN";
|
|
41
|
+
readonly BUTTON: "BUTTON";
|
|
42
|
+
readonly TAG: "TAG";
|
|
43
|
+
};
|
|
44
|
+
type CellType = typeof CellType[keyof typeof CellType];
|
|
45
|
+
|
|
46
|
+
interface DateRange {
|
|
47
|
+
from: Date | undefined;
|
|
48
|
+
to: Date | undefined;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
type FilterColumnType = "string" | "number" | "date" | "boolean";
|
|
52
|
+
type StringOperator = "equals" | "not_equals" | "contains" | "starts_with" | "ends_with" | "in" | "not_in" | "is_null" | "is_not_null";
|
|
53
|
+
type NumberOperator = "equals" | "not_equals" | "greater" | "greater_equals" | "less" | "less_equals" | "in" | "not_in" | "is_null" | "is_not_null";
|
|
54
|
+
type DateOperator = "equals" | "not_equals" | "after" | "after_or_on" | "before" | "before_or_on" | "between" | "is_null" | "is_not_null";
|
|
55
|
+
type BooleanOperator = "is_true" | "is_false" | "is_null" | "is_not_null";
|
|
56
|
+
type FilterOperator = StringOperator | NumberOperator | DateOperator | BooleanOperator;
|
|
57
|
+
type FilterValue = string | string[] | number | number[] | Date | boolean | DateRange | null;
|
|
58
|
+
interface FilterFieldProp {
|
|
59
|
+
/** Matches ColumnDef id or accessorKey (stringified) */
|
|
60
|
+
id: string;
|
|
61
|
+
/** Human-readable label (from ColumnDef.header) */
|
|
62
|
+
label: string;
|
|
63
|
+
/** Column data type used to pick operators and value input */
|
|
64
|
+
type: FilterColumnType;
|
|
65
|
+
/** Available values for `in` / `not_in` operators (from CellType.SELECT / MULTI_SELECT columns) */
|
|
66
|
+
availableOptions?: Option[];
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Per-field read-only flags for a condition. Each flag locks a single
|
|
70
|
+
*/
|
|
71
|
+
interface ConditionReadOnly {
|
|
72
|
+
/** Locks the field selector (first dropdown). */
|
|
73
|
+
field?: boolean;
|
|
74
|
+
/** Locks the operator selector (second dropdown). */
|
|
75
|
+
operator?: boolean;
|
|
76
|
+
/** Locks the value input. */
|
|
77
|
+
value?: boolean;
|
|
78
|
+
/** Hides the delete button. */
|
|
79
|
+
delete?: boolean;
|
|
80
|
+
}
|
|
81
|
+
interface FilterCondition {
|
|
82
|
+
type: "condition";
|
|
83
|
+
field: FilterFieldProp;
|
|
84
|
+
operator: FilterOperator;
|
|
85
|
+
value: FilterValue;
|
|
86
|
+
/** Optional per-field read-only flags (stored on the condition, not global). */
|
|
87
|
+
readOnly?: ConditionReadOnly;
|
|
88
|
+
}
|
|
89
|
+
interface FilterGroup {
|
|
90
|
+
type: "group";
|
|
91
|
+
logic: "and" | "or";
|
|
92
|
+
filters: FilterNode[];
|
|
93
|
+
}
|
|
94
|
+
/** Recursive union — use `node.type` to discriminate */
|
|
95
|
+
type FilterNode = FilterCondition | FilterGroup;
|
|
96
|
+
|
|
97
|
+
interface BaseTypographyProps {
|
|
98
|
+
/**
|
|
99
|
+
* Prefer children when rendering rich/nested content
|
|
100
|
+
*/
|
|
101
|
+
children?: React.ReactNode;
|
|
102
|
+
variant: TypographyVariant;
|
|
103
|
+
/**
|
|
104
|
+
* Flag to indicate if the component is disabled.
|
|
105
|
+
* @optional
|
|
106
|
+
*/
|
|
107
|
+
disabled?: boolean;
|
|
108
|
+
/**
|
|
109
|
+
* Optional color string i can pass to the text
|
|
110
|
+
* @optional
|
|
111
|
+
*/
|
|
112
|
+
color?: string;
|
|
113
|
+
/**
|
|
114
|
+
* Font weight applied to the text.
|
|
115
|
+
* @optional
|
|
116
|
+
*/
|
|
117
|
+
fontWeight?: string | number;
|
|
118
|
+
/**
|
|
119
|
+
* Font style applied to the text.
|
|
120
|
+
* @optional
|
|
121
|
+
*/
|
|
122
|
+
fontStyle?: string;
|
|
123
|
+
/**
|
|
124
|
+
* Text decoration applied to the text.
|
|
125
|
+
* @optional
|
|
126
|
+
*/
|
|
127
|
+
textDecoration?: string;
|
|
128
|
+
}
|
|
129
|
+
type TypographyVariant = "display" | "heading" | "body" | "label" | "code" | "subtitle" | "title" | "caption" | "article-h1" | "article-h2" | "article-h3" | "article-h4" | "article-body" | "article-code" | "article-quote" | "article-caption" | "article-list";
|
|
130
|
+
|
|
131
|
+
interface IconProps {
|
|
132
|
+
/**
|
|
133
|
+
* Icon name for SVG file or URL for image
|
|
134
|
+
*/
|
|
135
|
+
src: string;
|
|
136
|
+
/**
|
|
137
|
+
* Manage disabled state
|
|
138
|
+
*/
|
|
139
|
+
disabled?: boolean;
|
|
140
|
+
/**
|
|
141
|
+
* Manage disabled state
|
|
142
|
+
*/
|
|
143
|
+
state?: State;
|
|
144
|
+
/**
|
|
145
|
+
* Width of the icon
|
|
146
|
+
*/
|
|
147
|
+
width?: string;
|
|
148
|
+
/**
|
|
149
|
+
* Height of the icon
|
|
150
|
+
*/
|
|
151
|
+
height?: string;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
interface ProgressBarProps {
|
|
155
|
+
/** Current progress value */
|
|
156
|
+
value: number;
|
|
157
|
+
/** Minimum value of the range. Defaults to 0. */
|
|
158
|
+
min?: number;
|
|
159
|
+
/** Maximum value of the range. Defaults to 100. */
|
|
160
|
+
max?: number;
|
|
161
|
+
/** Visual variant for color theming */
|
|
162
|
+
variant?: State;
|
|
163
|
+
/** Whether the progress bar is in an indeterminate loading state */
|
|
164
|
+
indeterminate?: boolean;
|
|
165
|
+
/** Whether to show the header with percentage (left) and value (right) above the bar */
|
|
166
|
+
showLabel?: boolean;
|
|
167
|
+
/** Custom label text (overrides the percentage on the left) */
|
|
168
|
+
label?: string;
|
|
169
|
+
/** Custom formatter for the value shown on the right */
|
|
170
|
+
formatValue?: (value: number) => string;
|
|
171
|
+
/** Height of the progress bar */
|
|
172
|
+
height?: number;
|
|
173
|
+
/** Whether the component is disabled */
|
|
174
|
+
disabled?: boolean;
|
|
175
|
+
/** Additional CSS class name */
|
|
176
|
+
className?: string;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
/**
|
|
180
|
+
* Maps each CellType to the component-specific props that can be passed
|
|
181
|
+
* via `uiVariant` in a rule. TypeScript enforces that you only pass props
|
|
182
|
+
* the underlying component actually understands.
|
|
183
|
+
*/
|
|
184
|
+
type CellUIVariantMap = {
|
|
185
|
+
[K in CellType]: K extends "IMAGE" ? Partial<Omit<IconProps, "src">> : K extends "TAG" ? Partial<{
|
|
186
|
+
state: State;
|
|
187
|
+
size: Size;
|
|
188
|
+
}> : K extends "PROGRESS" ? Partial<Pick<ProgressBarProps, "variant" | "showLabel" | "height">> : Partial<Omit<BaseTypographyProps, "children" | "variant">>;
|
|
189
|
+
};
|
|
190
|
+
/**
|
|
191
|
+
* Given a tuple of `DataStructureColumn`, produces a union of
|
|
192
|
+
* `{ columnId: string; cellType: CellType }` entries.
|
|
193
|
+
*/
|
|
194
|
+
type ColumnTypeMap<TData, TColumns extends readonly DataStructureColumn<TData>[]> = {
|
|
195
|
+
[K in keyof TColumns]: TColumns[K] extends DataStructureColumn<TData> ? {
|
|
196
|
+
columnId: TColumns[K]["id"] extends string ? TColumns[K]["id"] : string;
|
|
197
|
+
cellType: TColumns[K]["cellType"] extends CellType ? TColumns[K]["cellType"] : CellType;
|
|
198
|
+
} : never;
|
|
199
|
+
}[number];
|
|
200
|
+
/**
|
|
201
|
+
* Looks up the `cellType` for a given `columnId` from a columns array.
|
|
202
|
+
* Falls back to `CellType` if not found.
|
|
203
|
+
*/
|
|
204
|
+
type LookupCellType<TData, TColumns extends readonly DataStructureColumn<TData>[], TId extends string> = Extract<ColumnTypeMap<TData, TColumns>, {
|
|
205
|
+
columnId: TId;
|
|
206
|
+
}> extends {
|
|
207
|
+
cellType: infer R;
|
|
208
|
+
} ? R extends CellType ? R : CellType : CellType;
|
|
209
|
+
/** Comparison operators for AST-like UI rules */
|
|
210
|
+
type UIRuleOperator = "==" | "!=" | ">" | ">=" | "<" | "<=" | "includes" | "startsWith" | "endsWith" | "isEmpty" | "isNotEmpty";
|
|
211
|
+
/**
|
|
212
|
+
* A single declarative styling rule evaluated against a row.
|
|
213
|
+
* Rules are compiled once into fast evaluators — no runtime functions.
|
|
214
|
+
*
|
|
215
|
+
* When `field` and `op` are omitted, the rule always matches (static styling).
|
|
216
|
+
*
|
|
217
|
+
* @example conditional
|
|
218
|
+
* { field: "price", op: ">", value: 100, uiVariant: { color: "var(--rst-color-success)", fontWeight: "bold" } }
|
|
219
|
+
*
|
|
220
|
+
* @example static (always applies)
|
|
221
|
+
* { uiVariant: { color: "red" } }
|
|
222
|
+
*/
|
|
223
|
+
interface DataStructureUIRule<TData, K extends CellType = CellType> {
|
|
224
|
+
/** Which field to evaluate — omit for a static rule that always matches */
|
|
225
|
+
field?: keyof TData;
|
|
226
|
+
/** Comparison operator — omit for a static rule that always matches */
|
|
227
|
+
op?: UIRuleOperator;
|
|
228
|
+
/** Comparison value (not needed for isEmpty / isNotEmpty) */
|
|
229
|
+
value?: unknown;
|
|
230
|
+
/**
|
|
231
|
+
* Component-specific props forwarded to the underlying renderer.
|
|
232
|
+
* TypeScript enforces the correct props based on the column's `cellType`.
|
|
233
|
+
*/
|
|
234
|
+
uiVariant?: CellUIVariantMap[K];
|
|
235
|
+
}
|
|
236
|
+
/**
|
|
237
|
+
* Per-column UI configuration.
|
|
238
|
+
* Matches a schema column via `columnId` (same as `DataStructureColumn.id` or `accessorKey`).
|
|
239
|
+
*/
|
|
240
|
+
interface DataStructureUIColumn<TData, TColumns extends readonly DataStructureColumn<TData>[] = DataStructureColumn<TData>[], TId extends string = string> {
|
|
241
|
+
/** Matches `DataStructureColumn.id` or `accessorKey` */
|
|
242
|
+
columnId: TId;
|
|
243
|
+
/** Ordered rules — first match wins. Rules without `field`/`op` always match. */
|
|
244
|
+
rules?: DataStructureUIRule<TData, LookupCellType<TData, TColumns, TId>>[];
|
|
245
|
+
}
|
|
246
|
+
/**
|
|
247
|
+
* Top-level UI configuration passed to any data-component.
|
|
248
|
+
* `TColumns` is inferred from the `columns` prop — `cellType` is looked up automatically.
|
|
249
|
+
*/
|
|
250
|
+
interface DataStructureUIConfig<TData, TColumns extends readonly DataStructureColumn<TData>[] = DataStructureColumn<TData>[]> {
|
|
251
|
+
columns?: DataStructureUIColumn<TData, TColumns, string>[];
|
|
252
|
+
/** Container-level styling applied to the component root (e.g. Card state). */
|
|
253
|
+
container?: DataStructureUIContainer;
|
|
254
|
+
}
|
|
255
|
+
/** Container-level UI configuration.*/
|
|
256
|
+
interface DataStructureUIContainer {
|
|
257
|
+
/** Component-specific props forwarded to the container root renderer. */
|
|
258
|
+
uiVariant?: Record<string, unknown>;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
interface DataStructureColumn<TData, TValue = TData[keyof TData]> {
|
|
262
|
+
/** Unique identifier for the column */
|
|
263
|
+
id?: string;
|
|
264
|
+
/** Display header text */
|
|
265
|
+
header?: string;
|
|
266
|
+
/** Simple accessor key for primitive values */
|
|
267
|
+
accessorKey?: keyof TData;
|
|
268
|
+
/** Optional: options for select inputs */
|
|
269
|
+
options?: Option[];
|
|
270
|
+
/** Formula string using column IDs as references */
|
|
271
|
+
formula?: string;
|
|
272
|
+
/** Enable editing for this column */
|
|
273
|
+
enableEditing?: boolean;
|
|
274
|
+
/** Optional: mark field as required */
|
|
275
|
+
required?: boolean;
|
|
276
|
+
/** Disable editing for this column */
|
|
277
|
+
disabled?: boolean;
|
|
278
|
+
/** Function accessor for complex values */
|
|
279
|
+
accessorFn?: (row: TData) => TValue;
|
|
280
|
+
/** Visual representation type for cells with options or specific data types */
|
|
281
|
+
cellType?: CellType;
|
|
282
|
+
/** Helper text shown below the field (e.g. "Opzionale", "Usa +/− per il segno"). */
|
|
283
|
+
helperText?: string;
|
|
284
|
+
/**
|
|
285
|
+
* Generic column-level configuration for the target component.
|
|
286
|
+
* Mirrors the uiConfig pattern: carries the props of the component
|
|
287
|
+
* referenced by `cellType` (e.g. ChartProps for CHART, TableGridProps for TABLE_GRID).
|
|
288
|
+
* `data` and `columns` are excluded — they come from the cell value and schema.
|
|
289
|
+
*/
|
|
290
|
+
columnConfig?: Record<string, unknown>;
|
|
291
|
+
/**
|
|
292
|
+
* Called when an interactive cell (e.g. BUTTON, IMAGE click) fires an action.
|
|
293
|
+
* The cell handler decides when to invoke it; the first argument is the
|
|
294
|
+
* action id (for BUTTON = `option.value`). Works in any data-component
|
|
295
|
+
* that renders Cell in display mode (CardList, TableGrid, …).
|
|
296
|
+
*/
|
|
297
|
+
onCellClick?: (actionId: string, rowData: TData, column: DataStructureColumn<TData, TValue>) => void;
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
/**
|
|
301
|
+
* Current version of the dashboard config schema.
|
|
302
|
+
* Templates with a different version are rejected to avoid incompatibilities.
|
|
303
|
+
*/
|
|
304
|
+
declare const DASHBOARD_CONFIG_VERSION = 1;
|
|
305
|
+
/**
|
|
306
|
+
* A widget type that can be placed on the dashboard canvas.
|
|
307
|
+
*/
|
|
308
|
+
type WidgetComponentType = "table-grid" | "chart" | "calendar" | "form" | "card-list" | "gantt" | "kpi";
|
|
309
|
+
/**
|
|
310
|
+
* Metadata for a widget type shown in the palette.
|
|
311
|
+
*/
|
|
312
|
+
interface WidgetTypeDescriptor {
|
|
313
|
+
type: WidgetComponentType;
|
|
314
|
+
label: string;
|
|
315
|
+
icon: string;
|
|
316
|
+
description: string;
|
|
317
|
+
}
|
|
318
|
+
/**
|
|
319
|
+
* Grid position for a widget on the canvas (desktop-only for now).
|
|
320
|
+
*/
|
|
321
|
+
interface WidgetPosition {
|
|
322
|
+
col: number;
|
|
323
|
+
row: number;
|
|
324
|
+
w: number;
|
|
325
|
+
h: number;
|
|
326
|
+
}
|
|
327
|
+
/**
|
|
328
|
+
* Configuration for a single widget on the dashboard.
|
|
329
|
+
*/
|
|
330
|
+
interface DashboardWidgetConfig {
|
|
331
|
+
/** Unique widget id */
|
|
332
|
+
id: string;
|
|
333
|
+
/** Display title */
|
|
334
|
+
title: string;
|
|
335
|
+
/** Optional subtitle */
|
|
336
|
+
subtitle?: string;
|
|
337
|
+
/** Optional icon name (bundled SVG name) shown before the title in the section header */
|
|
338
|
+
icon?: string;
|
|
339
|
+
/** Which data-component to render */
|
|
340
|
+
componentType: WidgetComponentType;
|
|
341
|
+
/** References a data source exposed by the host application */
|
|
342
|
+
dataSourceId: string;
|
|
343
|
+
/** Column definitions (optional — auto-inferred if omitted) */
|
|
344
|
+
columns?: DataStructureColumn<Record<string, unknown>>[];
|
|
345
|
+
/** Widget-level filters (combined with global filters) */
|
|
346
|
+
filters?: FilterGroup | null;
|
|
347
|
+
/** Conditional styling rules */
|
|
348
|
+
uiConfig?: DataStructureUIConfig<Record<string, unknown>> | null;
|
|
349
|
+
/** Component-specific props (e.g. enableSorting, chart type, calendar view) */
|
|
350
|
+
componentProps?: Record<string, unknown>;
|
|
351
|
+
/** Grid position on the canvas */
|
|
352
|
+
position: WidgetPosition;
|
|
353
|
+
/** Per-widget action toggles. Falls back to global defaults if undefined. */
|
|
354
|
+
enableExport?: boolean;
|
|
355
|
+
enableScreenshot?: boolean;
|
|
356
|
+
enableExpand?: boolean;
|
|
357
|
+
enableFilter?: boolean;
|
|
358
|
+
}
|
|
359
|
+
/**
|
|
360
|
+
* Global defaults for widget actions. Applied to all widgets unless
|
|
361
|
+
* overridden per-widget.
|
|
362
|
+
*/
|
|
363
|
+
interface WidgetActionDefaults {
|
|
364
|
+
/** Show the export CSV button. Default: true. */
|
|
365
|
+
enableExport?: boolean;
|
|
366
|
+
/** Show the screenshot button. Default: false. */
|
|
367
|
+
enableScreenshot?: boolean;
|
|
368
|
+
/** Show the expand/fullscreen button. Default: true. */
|
|
369
|
+
enableExpand?: boolean;
|
|
370
|
+
/** Show the per-widget filter button. Default: false. */
|
|
371
|
+
enableFilter?: boolean;
|
|
372
|
+
}
|
|
373
|
+
/**
|
|
374
|
+
* The full dashboard configuration — what gets saved to DB as JSONB.
|
|
375
|
+
*/
|
|
376
|
+
interface DashboardConfig {
|
|
377
|
+
version: typeof DASHBOARD_CONFIG_VERSION;
|
|
378
|
+
name: string;
|
|
379
|
+
/** Global filters keyed by data source id */
|
|
380
|
+
filters: Record<string, FilterGroup | null> | null;
|
|
381
|
+
/** Widgets placed on the dashboard */
|
|
382
|
+
widgets: DashboardWidgetConfig[];
|
|
383
|
+
}
|
|
384
|
+
/**
|
|
385
|
+
* A pre-built dashboard template that users can load.
|
|
386
|
+
* Templates are JSON files with a version check to avoid incompatibilities.
|
|
387
|
+
*/
|
|
388
|
+
interface DashboardTemplate {
|
|
389
|
+
/** Must match DASHBOARD_CONFIG_VERSION to be loadable */
|
|
390
|
+
version: number;
|
|
391
|
+
/** Human-readable template name */
|
|
392
|
+
name: string;
|
|
393
|
+
/** Short description shown in the template picker */
|
|
394
|
+
description: string;
|
|
395
|
+
/** The dashboard config to load (without the version field, which is at template level) */
|
|
396
|
+
config: Omit<DashboardConfig, "version">;
|
|
397
|
+
}
|
|
398
|
+
/**
|
|
399
|
+
* A pre-built section: a single widget fully pre-configured
|
|
400
|
+
* (data source, columns, title, component type, etc.) that users
|
|
401
|
+
* can click to add to the canvas without manual configuration.
|
|
402
|
+
*
|
|
403
|
+
* Appears in the "Add Widget" panel below the generic widget types.
|
|
404
|
+
*/
|
|
405
|
+
interface PrebuiltSection {
|
|
406
|
+
/** Must match DASHBOARD_CONFIG_VERSION to be loadable */
|
|
407
|
+
version: number;
|
|
408
|
+
/** Human-readable name */
|
|
409
|
+
name: string;
|
|
410
|
+
/** Short description shown in the add-widget panel */
|
|
411
|
+
description: string;
|
|
412
|
+
/** Pre-configured widget (id and position are assigned at creation time) */
|
|
413
|
+
widget: Omit<DashboardWidgetConfig, "id" | "position">;
|
|
414
|
+
}
|
|
415
|
+
/**
|
|
416
|
+
* Field format for display and aggregation.
|
|
417
|
+
*/
|
|
418
|
+
type FieldFormat = "text" | "number" | "currency" | "percentage" | "date" | "datetime" | "boolean";
|
|
419
|
+
/**
|
|
420
|
+
* Describes a single field in a data source.
|
|
421
|
+
*/
|
|
422
|
+
interface DataSourceField {
|
|
423
|
+
id: string;
|
|
424
|
+
name: string;
|
|
425
|
+
format: FieldFormat;
|
|
426
|
+
}
|
|
427
|
+
/**
|
|
428
|
+
* A data source exposed by the host application.
|
|
429
|
+
* `data` is sample/preview data used in the builder.
|
|
430
|
+
*/
|
|
431
|
+
interface DataSourceDefinition {
|
|
432
|
+
id: string;
|
|
433
|
+
name: string;
|
|
434
|
+
fields: DataSourceField[];
|
|
435
|
+
data: Record<string, unknown>[];
|
|
436
|
+
}
|
|
437
|
+
/**
|
|
438
|
+
* Registry of all available data sources, keyed by id.
|
|
439
|
+
*/
|
|
440
|
+
type DataSourceRegistry = Record<string, DataSourceDefinition>;
|
|
441
|
+
/**
|
|
442
|
+
* Props for the DashboardBuilder component.
|
|
443
|
+
*/
|
|
444
|
+
interface DashboardBuilderProps {
|
|
445
|
+
/** Available data sources (provided by the host application) */
|
|
446
|
+
dataSources: DataSourceRegistry;
|
|
447
|
+
/** Initial config to edit (undefined = start from scratch) */
|
|
448
|
+
initialConfig?: DashboardConfig;
|
|
449
|
+
/** Pre-built templates users can load. Only templates with version === DASHBOARD_CONFIG_VERSION are shown. */
|
|
450
|
+
templates?: DashboardTemplate[];
|
|
451
|
+
/** Pre-built single-widget sections users can add to the canvas. Shown in the Add Widget panel. */
|
|
452
|
+
prebuiltSections?: PrebuiltSection[];
|
|
453
|
+
/** Called when the user saves the dashboard */
|
|
454
|
+
onSave: (config: DashboardConfig) => void;
|
|
455
|
+
/** Called on every config change (for live preview) */
|
|
456
|
+
onChange?: (config: DashboardConfig) => void;
|
|
457
|
+
/** Global defaults for widget action buttons (export, screenshot, expand) */
|
|
458
|
+
widgetActionDefaults?: WidgetActionDefaults;
|
|
459
|
+
/** Force read-only (view) mode: hides edit/view toggle and save button, always renders in view mode. */
|
|
460
|
+
readOnly?: boolean;
|
|
461
|
+
/** Additional CSS class name */
|
|
462
|
+
className?: string;
|
|
463
|
+
}
|
|
464
|
+
/**
|
|
465
|
+
* Internal builder state managed by the useDashboardBuilder hook.
|
|
466
|
+
*/
|
|
467
|
+
interface DashboardBuilderState {
|
|
468
|
+
config: DashboardConfig;
|
|
469
|
+
selectedWidgetId: string | null;
|
|
470
|
+
isDirty: boolean;
|
|
471
|
+
}
|
|
472
|
+
|
|
473
|
+
/**
|
|
474
|
+
* DashboardBuilder is a visual, Notion-style dashboard configurator.
|
|
475
|
+
*
|
|
476
|
+
* Two modes:
|
|
477
|
+
* - **Edit**: palette, canvas with drag/resize, configurator panel
|
|
478
|
+
* - **View**: renders the actual Dashboard with real data components
|
|
479
|
+
*
|
|
480
|
+
* The builder produces a `DashboardConfig` object that can be serialized
|
|
481
|
+
* to JSON and saved to a database.
|
|
482
|
+
*/
|
|
483
|
+
declare const DashboardBuilder: React.FC<DashboardBuilderProps>;
|
|
484
|
+
|
|
485
|
+
export { DASHBOARD_CONFIG_VERSION, DashboardBuilder };
|
|
486
|
+
export type { DashboardBuilderProps, DashboardBuilderState, DashboardConfig, DashboardTemplate, DashboardWidgetConfig, DataSourceDefinition, DataSourceField, DataSourceRegistry, FieldFormat, PrebuiltSection, WidgetActionDefaults, WidgetComponentType, WidgetPosition, WidgetTypeDescriptor };
|