@restio/ui 0.2.1 → 0.2.2-20261120112131
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 +51 -7
- package/dist/core.cjs +1 -0
- package/dist/core.d.ts +992 -0
- package/dist/core.js +36 -0
- package/dist/data.cjs +1 -0
- package/dist/data.d.ts +1465 -0
- package/dist/data.js +24 -0
- package/dist/experimental.cjs +2 -0
- package/dist/experimental.d.ts +660 -0
- package/dist/experimental.js +1365 -0
- package/dist/framework.cjs +1 -0
- package/dist/framework.d.ts +761 -0
- package/dist/framework.js +34 -0
- package/dist/index.cjs +1 -0
- package/dist/index.d.ts +3282 -151
- package/dist/index.js +99 -0
- package/dist/src-C-0-H5TG.cjs +159 -0
- package/dist/{restio-ui.es.js → src-DzNRRdGD.js} +37175 -36673
- package/dist/ui.css +1 -1
- package/package.json +65 -43
- 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 -1
- package/dist/assets/svg/chart-bar-stacked.svg +0 -1
- package/dist/assets/svg/chart-bar.svg +0 -1
- package/dist/assets/svg/chart-candlestick.svg +0 -1
- package/dist/assets/svg/chart-gantt.svg +0 -1
- package/dist/assets/svg/chart-line.svg +0 -1
- package/dist/assets/svg/chart-pie.svg +0 -1
- package/dist/assets/svg/chart-sankey.svg +0 -1
- 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/file-plus.svg +0 -1
- package/dist/assets/svg/filter.svg +0 -1
- package/dist/assets/svg/form.svg +0 -1
- 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 -1
- 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/open-center.svg +0 -1
- package/dist/assets/svg/open-dialog.svg +0 -29
- 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/square-half.svg +0 -1
- package/dist/assets/svg/table.svg +0 -1
- package/dist/assets/svg/terminal.svg +0 -1
- package/dist/assets/svg/timer.svg +0 -1
- package/dist/assets/svg/transaction.svg +0 -1
- package/dist/assets/svg/vertical-expand.svg +0 -1
- package/dist/assets/svg/wallet.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 -22
- package/dist/components/anchored-overlay/anchored-overlay.d.ts +0 -4
- package/dist/components/anchored-overlay/anchored-overlay.test.d.ts +0 -0
- package/dist/components/anchored-overlay/stories/anchored-overlay-example.stories.d.ts +0 -6
- package/dist/components/banner/banner-types.d.ts +0 -12
- package/dist/components/banner/banner.d.ts +0 -4
- package/dist/components/banner/banner.stories.d.ts +0 -11
- package/dist/components/button/button-types.d.ts +0 -12
- package/dist/components/button/button.d.ts +0 -3
- package/dist/components/button/stories/button-example.stories.d.ts +0 -8
- package/dist/components/button/stories/button.stories.d.ts +0 -8
- package/dist/components/button-dropdown/button-dropdown-types.d.ts +0 -19
- package/dist/components/button-dropdown/button-dropdown.d.ts +0 -7
- package/dist/components/button-dropdown/button-dropdown.test.d.ts +0 -0
- package/dist/components/button-dropdown/stories/button-dropdown.stories.d.ts +0 -10
- package/dist/components/button-group/button-group-types.d.ts +0 -15
- package/dist/components/button-group/button-group.d.ts +0 -3
- package/dist/components/button-group/button-group.stories.d.ts +0 -7
- package/dist/components/button-group/button-group.test.d.ts +0 -1
- package/dist/components/checkbox/checkbox-types.d.ts +0 -15
- package/dist/components/checkbox/checkbox.d.ts +0 -3
- package/dist/components/checkbox/checkbox.test.d.ts +0 -0
- package/dist/components/checkbox/stories/checkbox-example.stories.d.ts +0 -7
- package/dist/components/checkbox/stories/checkbox.stories.d.ts +0 -6
- package/dist/components/checkbox-group/checkbox-group-types.d.ts +0 -27
- package/dist/components/checkbox-group/checkbox-group.d.ts +0 -7
- package/dist/components/checkbox-group/checkbox-group.test.d.ts +0 -0
- package/dist/components/checkbox-group/stories/checkbox-group-example.stories.d.ts +0 -6
- package/dist/components/checkbox-group/stories/checkbox-group.stories.d.ts +0 -10
- package/dist/components/code-block/code-block.d.ts +0 -7
- package/dist/components/file-upload/file-upload-types.d.ts +0 -36
- package/dist/components/file-upload/file-upload-utils.d.ts +0 -1
- package/dist/components/file-upload/file-upload.d.ts +0 -3
- package/dist/components/file-upload/file-upload.test.d.ts +0 -1
- package/dist/components/file-upload/stories/file-upload.stories.d.ts +0 -8
- package/dist/components/input/date/date-calendar.d.ts +0 -3
- package/dist/components/input/date/date-input-field.d.ts +0 -8
- package/dist/components/input/date/date-picker.d.ts +0 -7
- package/dist/components/input/date/date-range-input-field.d.ts +0 -8
- package/dist/components/input/date/date-range-picker.d.ts +0 -8
- package/dist/components/input/date/date-shortcuts.d.ts +0 -3
- package/dist/components/input/date/date-types.d.ts +0 -52
- package/dist/components/input/date/date-utils.d.ts +0 -34
- package/dist/components/input/date/stories/date.stories.d.ts +0 -5
- package/dist/components/input/date/use-digit-input.d.ts +0 -18
- package/dist/components/input/input-types.d.ts +0 -27
- package/dist/components/input/input.d.ts +0 -3
- package/dist/components/input/number/input-number-types.d.ts +0 -7
- package/dist/components/input/number/input-number.d.ts +0 -3
- package/dist/components/input/number/input-number.stories.d.ts +0 -6
- package/dist/components/input/text/input-text-types.d.ts +0 -6
- package/dist/components/input/text/input-text.d.ts +0 -3
- package/dist/components/input/text/stories/input-text.stories.d.ts +0 -9
- package/dist/components/kbd/kbd-types.d.ts +0 -6
- package/dist/components/kbd/kbd.d.ts +0 -4
- package/dist/components/kbd/kbd.stories.d.ts +0 -9
- package/dist/components/kbd-group/kbd-group-types.d.ts +0 -14
- package/dist/components/kbd-group/kbd-group.d.ts +0 -4
- package/dist/components/kbd-group/kbd-group.stories.d.ts +0 -10
- package/dist/components/list/list-types.d.ts +0 -37
- package/dist/components/list/list-utils.d.ts +0 -46
- package/dist/components/list/list.d.ts +0 -2
- package/dist/components/list/list.stories.d.ts +0 -12
- package/dist/components/list/list.test.d.ts +0 -0
- package/dist/components/menu/anchored-navigation-menu.d.ts +0 -18
- package/dist/components/menu/menu-assets.d.ts +0 -2
- package/dist/components/menu/menu-types.d.ts +0 -21
- package/dist/components/menu/menu.d.ts +0 -8
- package/dist/components/menu/stories/anchored-navigation-menu.stories.d.ts +0 -7
- package/dist/components/otp/otp-types.d.ts +0 -29
- package/dist/components/otp/otp-utils.d.ts +0 -14
- package/dist/components/otp/otp.d.ts +0 -3
- package/dist/components/otp/otp.stories.d.ts +0 -145
- package/dist/components/progress-bar/progress-bar-types.d.ts +0 -25
- package/dist/components/progress-bar/progress-bar.d.ts +0 -6
- package/dist/components/progress-bar/progress-bar.test.d.ts +0 -1
- package/dist/components/progress-bar/stories/progress-bar-example.stories.d.ts +0 -8
- package/dist/components/progress-bar/stories/progress-bar.stories.d.ts +0 -10
- package/dist/components/radio/radio-types.d.ts +0 -13
- package/dist/components/radio/radio.d.ts +0 -7
- package/dist/components/radio/radio.test.d.ts +0 -0
- package/dist/components/radio/stories/radio-example.stories.d.ts +0 -7
- package/dist/components/radio/stories/radio.stories.d.ts +0 -6
- package/dist/components/radio-group/radio-group-types.d.ts +0 -29
- package/dist/components/radio-group/radio-group.d.ts +0 -7
- package/dist/components/radio-group/radio-group.test.d.ts +0 -0
- package/dist/components/radio-group/stories/radio-group-example.stories.d.ts +0 -6
- package/dist/components/radio-group/stories/radio-group.stories.d.ts +0 -10
- package/dist/components/select/select-switch.d.ts +0 -26
- package/dist/components/select/select-types.d.ts +0 -35
- package/dist/components/select/select.d.ts +0 -4
- package/dist/components/select/select.stories.d.ts +0 -20
- package/dist/components/select/select.test.d.ts +0 -0
- package/dist/components/select/templates/grid-template.d.ts +0 -7
- package/dist/components/select/templates/list-template.d.ts +0 -7
- package/dist/components/select/templates/preview-dialog-template.d.ts +0 -9
- package/dist/components/select/templates/select-template-types.d.ts +0 -12
- package/dist/components/selection-grid/selection-grid-types.d.ts +0 -19
- package/dist/components/selection-grid/selection-grid.d.ts +0 -7
- package/dist/components/selection-grid/stories/selection-grid-example.stories.d.ts +0 -7
- package/dist/components/selection-grid/stories/selection-grid.stories.d.ts +0 -10
- package/dist/components/tag/tag-types.d.ts +0 -9
- package/dist/components/tag/tag.d.ts +0 -3
- package/dist/components/tag/tag.stories.d.ts +0 -12
- package/dist/components/textarea/textarea-types.d.ts +0 -54
- package/dist/components/textarea/textarea.d.ts +0 -3
- package/dist/components/textarea/textarea.stories.d.ts +0 -25
- package/dist/components/toast-group/toast-group-types.d.ts +0 -5
- package/dist/components/toast-group/toast-group.d.ts +0 -4
- package/dist/components/toast-group/toast-group.stories.d.ts +0 -6
- package/dist/components/typography/typography-types.d.ts +0 -58
- package/dist/components/typography/typography.d.ts +0 -3
- package/dist/components/typography/typography.stories.d.ts +0 -10
- package/dist/custom-components/chat/chat-types.d.ts +0 -18
- package/dist/custom-components/chat/chat.d.ts +0 -2
- package/dist/custom-components/chat/chat.stories.d.ts +0 -7
- package/dist/custom-components/layout/layout-renderers.d.ts +0 -8
- package/dist/custom-components/layout/layout-types.d.ts +0 -53
- package/dist/custom-components/layout/layout-utils.d.ts +0 -3
- package/dist/custom-components/layout/layout-utils.test.d.ts +0 -1
- package/dist/custom-components/layout/layout.d.ts +0 -7
- package/dist/custom-components/layout/layout.stories.d.ts +0 -7
- package/dist/custom-components/layout/layout.test.d.ts +0 -1
- package/dist/custom-components/markdown/components/img/zoomable-image.d.ts +0 -4
- package/dist/custom-components/markdown/markdown-types.d.ts +0 -28
- package/dist/custom-components/markdown/markdown-utils.d.ts +0 -1
- package/dist/custom-components/markdown/markdown.d.ts +0 -3
- package/dist/custom-components/markdown/markdown.stories.d.ts +0 -6
- package/dist/custom-components/mindmap/index.d.ts +0 -2
- package/dist/custom-components/mindmap/mind-tree-types.d.ts +0 -93
- package/dist/custom-components/mindmap/mind-tree.d.ts +0 -3
- package/dist/custom-components/mindmap/reingold-tilford-algorithm.d.ts +0 -64
- package/dist/custom-components/mindmap/stories/mind-tree.stories.d.ts +0 -11
- package/dist/custom-components/shortcut-tooltip/shortcut-tooltip-types.d.ts +0 -59
- package/dist/custom-components/shortcut-tooltip/shortcut-tooltip.d.ts +0 -17
- package/dist/custom-components/shortcut-tooltip/stories/shortcut-tooltip.stories.d.ts +0 -10
- package/dist/custom-components/timeline/skeleton/timeline-skeleton.d.ts +0 -6
- package/dist/custom-components/timeline/timeline-types.d.ts +0 -45
- package/dist/custom-components/timeline/timeline.d.ts +0 -19
- package/dist/custom-components/timeline/timeline.stories.d.ts +0 -8
- package/dist/custom-components/workflow/layout/workflow-edge.d.ts +0 -3
- package/dist/custom-components/workflow/layout/workflow-layout-types.d.ts +0 -73
- package/dist/custom-components/workflow/layout/workflow-layout.d.ts +0 -37
- package/dist/custom-components/workflow/node/workflow-node.d.ts +0 -3
- package/dist/custom-components/workflow/panel/workflow-panel-types.d.ts +0 -17
- package/dist/custom-components/workflow/panel/workflow-panel.d.ts +0 -3
- package/dist/custom-components/workflow/stories/workflow-overlay.stories.d.ts +0 -7
- package/dist/custom-components/workflow/stories/workflow-toolbar.stories.d.ts +0 -6
- package/dist/custom-components/workflow/stories/workflow.stories.d.ts +0 -7
- package/dist/custom-components/workflow/toolbar/workflow-toolbar-types.d.ts +0 -23
- package/dist/custom-components/workflow/toolbar/workflow-toolbar.d.ts +0 -3
- package/dist/custom-components/workflow/utils/workflow-validation.d.ts +0 -47
- package/dist/custom-components/workflow/workflow-types.d.ts +0 -203
- package/dist/custom-components/workflow/workflow.d.ts +0 -6
- package/dist/data-components/assets/cell-types-asset.d.ts +0 -38
- package/dist/data-components/assets/data-components-asset.d.ts +0 -13
- package/dist/data-components/assets/finance-asset.d.ts +0 -15
- package/dist/data-components/calendar/calendar-types.d.ts +0 -30
- package/dist/data-components/calendar/calendar-utils.d.ts +0 -5
- package/dist/data-components/calendar/calendar.d.ts +0 -4
- package/dist/data-components/calendar/stories/calendar.stories.d.ts +0 -22
- package/dist/data-components/card/card-types.d.ts +0 -20
- package/dist/data-components/card/card.d.ts +0 -10
- package/dist/data-components/card/stories/card.stories.d.ts +0 -13
- package/dist/data-components/card-list/card-list-types.d.ts +0 -21
- package/dist/data-components/card-list/card-list.d.ts +0 -9
- package/dist/data-components/card-list/models/ecommerce.d.ts +0 -12
- package/dist/data-components/card-list/stories/card-list.stories.d.ts +0 -29
- package/dist/data-components/cell/cell-registry.d.ts +0 -28
- package/dist/data-components/cell/cell-types.d.ts +0 -39
- package/dist/data-components/cell/cell-utils.d.ts +0 -21
- package/dist/data-components/cell/cell.d.ts +0 -2
- package/dist/data-components/cell/colors-editor/colors-editor-types.d.ts +0 -15
- package/dist/data-components/cell/colors-editor/colors-editor.d.ts +0 -7
- package/dist/data-components/cell/stories/cell-all-examples.stories.d.ts +0 -13
- package/dist/data-components/cell/test/cell-utils.test.d.ts +0 -1
- package/dist/data-components/cell/test/cell.test.d.ts +0 -0
- package/dist/data-components/chart/chart-series-edit/chart-series-edit-types.d.ts +0 -22
- package/dist/data-components/chart/chart-series-edit/chart-series-edit.d.ts +0 -9
- package/dist/data-components/chart/chart-tooltip/chart-tooltip-types.d.ts +0 -13
- package/dist/data-components/chart/chart-tooltip/chart-tooltip.d.ts +0 -6
- package/dist/data-components/chart/chart-types.d.ts +0 -106
- package/dist/data-components/chart/chart-utils.d.ts +0 -27
- package/dist/data-components/chart/chart.d.ts +0 -4
- package/dist/data-components/chart/chart.stories.d.ts +0 -15
- package/dist/data-components/chart/geo/geoChart.d.ts +0 -10
- package/dist/data-components/chart/sankey/sankeyChart.d.ts +0 -37
- package/dist/data-components/data-component-configurator/data-component-configurator-types.d.ts +0 -35
- package/dist/data-components/data-component-configurator/data-component-configurator.d.ts +0 -17
- package/dist/data-components/data-component-types.d.ts +0 -10
- package/dist/data-components/data-component-utils.d.ts +0 -27
- package/dist/data-components/data-structure/data-structure.d.ts +0 -50
- package/dist/data-components/data-structure/stories-assets.d.ts +0 -86
- package/dist/data-components/filter/filter-engine.d.ts +0 -14
- package/dist/data-components/filter/filter-types.d.ts +0 -40
- package/dist/data-components/filter/filter-utils.d.ts +0 -43
- package/dist/data-components/form/form-types.d.ts +0 -67
- package/dist/data-components/form/form.d.ts +0 -3
- package/dist/data-components/form/form.test.d.ts +0 -0
- package/dist/data-components/form/stories/form-advanced-cells.stories.d.ts +0 -15
- package/dist/data-components/form/stories/form-complex.stories.d.ts +0 -7
- package/dist/data-components/form/stories/form-dynamic.stories.d.ts +0 -20
- package/dist/data-components/form/stories/form-validation-examples.stories.d.ts +0 -7
- package/dist/data-components/form/stories/form.stories.d.ts +0 -17
- package/dist/data-components/gantt/ai-assistant/gantt-ai-executor.d.ts +0 -8
- package/dist/data-components/gantt/ai-assistant/gantt-ai-panel.d.ts +0 -11
- package/dist/data-components/gantt/ai-assistant/gantt-ai-schema.d.ts +0 -6
- package/dist/data-components/gantt/ai-assistant/gantt-ai-tools.d.ts +0 -2
- package/dist/data-components/gantt/arrows/gantt-arrows.d.ts +0 -20
- package/dist/data-components/gantt/gantt-context.d.ts +0 -12
- package/dist/data-components/gantt/gantt-types.d.ts +0 -101
- package/dist/data-components/gantt/gantt-utils.d.ts +0 -60
- package/dist/data-components/gantt/gantt.d.ts +0 -3
- package/dist/data-components/gantt/hooks/useGanttDrag.d.ts +0 -14
- package/dist/data-components/gantt/hooks/useGanttTimeline.d.ts +0 -17
- package/dist/data-components/gantt/sidebar/gantt-sidebar-types.d.ts +0 -9
- package/dist/data-components/gantt/sidebar/gantt-sidebar.d.ts +0 -2
- package/dist/data-components/gantt/stories/gantt-stories-utils.d.ts +0 -12
- package/dist/data-components/gantt/stories/gantt.stories.d.ts +0 -20
- package/dist/data-components/kpi/kpi-types.d.ts +0 -17
- package/dist/data-components/kpi/kpi.d.ts +0 -5
- package/dist/data-components/layout/card-layout-presets.d.ts +0 -12
- package/dist/data-components/layout/finance/finance-layouts.d.ts +0 -18
- package/dist/data-components/layout/finance/kpi-layout-presets.d.ts +0 -35
- package/dist/data-components/layout/finance/stories/finance-card-list.stories.d.ts +0 -16
- package/dist/data-components/switcher/prop-form/prop-form-adapter.d.ts +0 -9
- package/dist/data-components/switcher/prop-form/prop-form-types.d.ts +0 -16
- package/dist/data-components/switcher/prop-form/prop-form.d.ts +0 -6
- package/dist/data-components/switcher/prop-schema/prop-schema-types.d.ts +0 -58
- package/dist/data-components/switcher/prop-schema/prop-schema-utils.d.ts +0 -14
- package/dist/data-components/switcher/prop-schema/prop-schema.d.ts +0 -43
- package/dist/data-components/switcher/switcher-types.d.ts +0 -59
- package/dist/data-components/switcher/switcher.d.ts +0 -12
- package/dist/data-components/switcher/switcher.stories.d.ts +0 -7
- package/dist/data-components/table-grid/aggregation/aggregation-utils.d.ts +0 -8
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-executor.d.ts +0 -8
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-mock.d.ts +0 -12
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-panel-types.d.ts +0 -13
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-panel.d.ts +0 -2
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-schema.d.ts +0 -3
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-tools.d.ts +0 -5
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-types.d.ts +0 -93
- package/dist/data-components/table-grid/ai-assistant/ai-assistant-validator.d.ts +0 -4
- package/dist/data-components/table-grid/ai-assistant/table-grid-ai.stories.d.ts +0 -9
- package/dist/data-components/table-grid/editability/table-grid-editability.stories.d.ts +0 -7
- package/dist/data-components/table-grid/external-functionalities/import/csv/autoDetect.d.ts +0 -6
- package/dist/data-components/table-grid/external-functionalities/import/csv/createDataStructureFromFile.d.ts +0 -8
- package/dist/data-components/table-grid/external-functionalities/import/csv/csvToObj.d.ts +0 -5
- package/dist/data-components/table-grid/external-functionalities/import/csv/detectDelimeter.d.ts +0 -5
- package/dist/data-components/table-grid/external-functionalities/import/csv/index.d.ts +0 -6
- package/dist/data-components/table-grid/external-functionalities/import/csv/inferColumns.d.ts +0 -5
- package/dist/data-components/table-grid/external-functionalities/import/csv/parseDelimeted.d.ts +0 -6
- package/dist/data-components/table-grid/external-functionalities/import/table-grid-import.stories.d.ts +0 -6
- package/dist/data-components/table-grid/footer/table-grid-footer-types.d.ts +0 -4
- package/dist/data-components/table-grid/footer/table-grid-footer.d.ts +0 -2
- package/dist/data-components/table-grid/formula/evaluator.d.ts +0 -10
- package/dist/data-components/table-grid/formula/formula-builder-types.d.ts +0 -7
- package/dist/data-components/table-grid/formula/formula-builder.d.ts +0 -2
- package/dist/data-components/table-grid/formula/formula.test.d.ts +0 -1
- package/dist/data-components/table-grid/formula/index.d.ts +0 -11
- package/dist/data-components/table-grid/formula/parser.d.ts +0 -23
- package/dist/data-components/table-grid/formula/table-grid-formula.stories.d.ts +0 -9
- package/dist/data-components/table-grid/formula/tokenizer.d.ts +0 -15
- package/dist/data-components/table-grid/formula/types.d.ts +0 -38
- package/dist/data-components/table-grid/grouping/grouping.d.ts +0 -14
- package/dist/data-components/table-grid/grouping/table-grid-grouping.stories.d.ts +0 -7
- package/dist/data-components/table-grid/header/grouping/group-panel-types.d.ts +0 -6
- package/dist/data-components/table-grid/header/grouping/group-panel.d.ts +0 -3
- package/dist/data-components/table-grid/header/table-grid-column-menu.d.ts +0 -9
- package/dist/data-components/table-grid/header/table-grid-header-types.d.ts +0 -5
- package/dist/data-components/table-grid/header/table-grid-header.d.ts +0 -3
- package/dist/data-components/table-grid/hooks/use-table.d.ts +0 -2
- package/dist/data-components/table-grid/pinning/pinning-utils.d.ts +0 -20
- package/dist/data-components/table-grid/pinning/table-grid-pinning.stories.d.ts +0 -17
- package/dist/data-components/table-grid/pivot/pivot-config-panel-types.d.ts +0 -16
- package/dist/data-components/table-grid/pivot/pivot-config-panel.d.ts +0 -3
- package/dist/data-components/table-grid/pivot/pivot-table.d.ts +0 -7
- package/dist/data-components/table-grid/pivot/pivot-types.d.ts +0 -52
- package/dist/data-components/table-grid/pivot/pivot-utils.d.ts +0 -13
- package/dist/data-components/table-grid/pivot/table-grid-pivot.stories.d.ts +0 -15
- package/dist/data-components/table-grid/row/table-grid-row-types.d.ts +0 -10
- package/dist/data-components/table-grid/row/table-grid-row-utils.d.ts +0 -13
- package/dist/data-components/table-grid/row/table-grid-row.d.ts +0 -2
- package/dist/data-components/table-grid/selection/selection-types.d.ts +0 -2
- package/dist/data-components/table-grid/selection/selection-utils.d.ts +0 -48
- package/dist/data-components/table-grid/selection/table-grid-selection.stories.d.ts +0 -9
- package/dist/data-components/table-grid/sidebar/table-grid-sidebar-types.d.ts +0 -27
- package/dist/data-components/table-grid/sidebar/table-grid-sidebar.d.ts +0 -2
- package/dist/data-components/table-grid/sidebar/table-grid-sidebar.stories.d.ts +0 -10
- package/dist/data-components/table-grid/sorting/sorting.d.ts +0 -7
- package/dist/data-components/table-grid/sorting/table-grid-sorting-groups.stories.d.ts +0 -5
- package/dist/data-components/table-grid/sorting/table-grid-sorting.stories.d.ts +0 -6
- package/dist/data-components/table-grid/stories/table-grid-columns.stories.d.ts +0 -8
- package/dist/data-components/table-grid/stories/table-grid-states.stories.d.ts +0 -8
- package/dist/data-components/table-grid/table-context/table-context-types.d.ts +0 -16
- package/dist/data-components/table-grid/table-context/table-context.d.ts +0 -2
- package/dist/data-components/table-grid/table-grid-context.d.ts +0 -3
- package/dist/data-components/table-grid/table-grid-features.stories.d.ts +0 -11
- package/dist/data-components/table-grid/table-grid-panels.d.ts +0 -21
- package/dist/data-components/table-grid/table-grid-types.d.ts +0 -246
- package/dist/data-components/table-grid/table-grid.d.ts +0 -10
- package/dist/data-components/table-grid/table-grid.stories.d.ts +0 -14
- package/dist/data-components/table-grid/table-utils.d.ts +0 -17
- package/dist/data-components/ui-layer/ui-layer-types.d.ts +0 -81
- package/dist/data-components/ui-layer/ui-layer-utils.d.ts +0 -12
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap-types.d.ts +0 -14
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap-utils.d.ts +0 -11
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap.d.ts +0 -3
- package/dist/experimental-components/contribution-heatmap/contribution-heatmap.stories.d.ts +0 -9
- package/dist/experimental-components/dashboard-builder/builder-canvas-hooks.d.ts +0 -46
- package/dist/experimental-components/dashboard-builder/builder-canvas.d.ts +0 -33
- package/dist/experimental-components/dashboard-builder/dashboard-builder-hooks.d.ts +0 -23
- package/dist/experimental-components/dashboard-builder/dashboard-builder-types.d.ts +0 -173
- package/dist/experimental-components/dashboard-builder/dashboard-builder-utils.d.ts +0 -37
- package/dist/experimental-components/dashboard-builder/dashboard-builder.d.ts +0 -13
- package/dist/experimental-components/dashboard-builder/dashboard-builder.stories.d.ts +0 -8
- package/dist/experimental-components/dashboard-builder/widget-configurator.d.ts +0 -25
- package/dist/experimental-components/dashboard-builder/widget-palette.d.ts +0 -19
- package/dist/experimental-components/filter-builder/filter-builder-types.d.ts +0 -11
- package/dist/experimental-components/filter-builder/filter-builder.d.ts +0 -11
- package/dist/experimental-components/filter-builder/filter-builder.stories.d.ts +0 -15
- package/dist/framework-components/appbar/appbar-assets.d.ts +0 -1
- package/dist/framework-components/appbar/appbar-types.d.ts +0 -18
- package/dist/framework-components/appbar/appbar.d.ts +0 -8
- package/dist/framework-components/appbar/appbar.stories.d.ts +0 -6
- package/dist/framework-components/blank-slate/blank-slate-types.d.ts +0 -31
- package/dist/framework-components/blank-slate/blank-slate.d.ts +0 -10
- package/dist/framework-components/blank-slate/blank-slate.stories.d.ts +0 -9
- package/dist/framework-components/breadcrumbs/breadcrumbs-types.d.ts +0 -13
- package/dist/framework-components/breadcrumbs/breadcrumbs.d.ts +0 -3
- package/dist/framework-components/breadcrumbs/breadcrumbs.stories.d.ts +0 -7
- package/dist/framework-components/dashboard/dashboard-context.d.ts +0 -11
- package/dist/framework-components/dashboard/dashboard-real-world.stories.d.ts +0 -6
- package/dist/framework-components/dashboard/dashboard-types.d.ts +0 -47
- package/dist/framework-components/dashboard/dashboard-widget-actions.d.ts +0 -0
- package/dist/framework-components/dashboard/dashboard-widget-types.d.ts +0 -85
- package/dist/framework-components/dashboard/dashboard-widget.d.ts +0 -17
- package/dist/framework-components/dashboard/dashboard.d.ts +0 -15
- package/dist/framework-components/dashboard/dashboard.stories.d.ts +0 -7
- package/dist/framework-components/dashboard/data-engine/aggregation-engine.d.ts +0 -10
- package/dist/framework-components/dashboard/data-engine/data-engine-client.d.ts +0 -46
- package/dist/framework-components/dashboard/data-engine/data-engine-types.d.ts +0 -118
- package/dist/framework-components/dashboard/data-engine/data-engine.d.ts +0 -86
- package/dist/framework-components/dashboard/data-engine/data-engine.test.d.ts +0 -1
- package/dist/framework-components/dashboard/data-engine/data-engine.worker.d.ts +0 -1
- package/dist/framework-components/dashboard/data-engine/field-inference.d.ts +0 -9
- package/dist/framework-components/dashboard/data-engine/filter-adapter.d.ts +0 -11
- package/dist/framework-components/dashboard/data-engine/index.d.ts +0 -7
- package/dist/framework-components/dashboard/data-engine/join-engine.d.ts +0 -16
- package/dist/framework-components/drawer/drawer-types.d.ts +0 -6
- package/dist/framework-components/drawer/drawer.d.ts +0 -4
- package/dist/framework-components/scaffold/scaffold-context.d.ts +0 -3
- package/dist/framework-components/scaffold/scaffold-types.d.ts +0 -17
- package/dist/framework-components/scaffold/scaffold.d.ts +0 -6
- package/dist/framework-components/scaffold/scaffold.stories.d.ts +0 -7
- package/dist/framework-components/scaffold/scaffold.test.d.ts +0 -0
- package/dist/framework-components/section/section-types.d.ts +0 -15
- package/dist/framework-components/section/section.d.ts +0 -8
- package/dist/framework-components/section/section.stories.d.ts +0 -6
- package/dist/framework-components/sidebar/sidebar-assets.d.ts +0 -1
- package/dist/framework-components/sidebar/sidebar-context.d.ts +0 -3
- package/dist/framework-components/sidebar/sidebar-logo/sidebar-logo-types.d.ts +0 -5
- package/dist/framework-components/sidebar/sidebar-logo/sidebar-logo.d.ts +0 -2
- package/dist/framework-components/sidebar/sidebar-types.d.ts +0 -12
- package/dist/framework-components/sidebar/sidebar.d.ts +0 -16
- package/dist/framework-components/sidebar/sidebar.stories.d.ts +0 -6
- package/dist/framework-components/stepper/stepper-types.d.ts +0 -13
- package/dist/framework-components/stepper/stepper.d.ts +0 -8
- package/dist/framework-components/stepper/stepper.stories.d.ts +0 -7
- package/dist/hooks/useDynamicVirtualList.d.ts +0 -75
- package/dist/hooks/useEscapeClose.d.ts +0 -2
- package/dist/hooks/useFixedVirtualList.d.ts +0 -34
- package/dist/hooks/useOverlayAnimation.d.ts +0 -17
- package/dist/hooks/useShortcut.d.ts +0 -19
- package/dist/hooks/useTour/stories/useTour.stories.d.ts +0 -24
- package/dist/hooks/useTour/useTour-context-internal.d.ts +0 -6
- package/dist/hooks/useTour/useTour-context.d.ts +0 -9
- package/dist/hooks/useTour/useTour-types.d.ts +0 -191
- package/dist/hooks/useTour/useTour.d.ts +0 -2
- package/dist/providers/ai-assistant/ai-assistant-prompts.d.ts +0 -7
- package/dist/providers/ai-assistant/ai-assistant-types.d.ts +0 -77
- package/dist/providers/ai-assistant/ai-assistant-validator.d.ts +0 -22
- package/dist/providers/ai-assistant/ai-chat-panel-types.d.ts +0 -24
- package/dist/providers/ai-assistant/ai-chat-panel.d.ts +0 -2
- package/dist/providers/shortcut/shortcut-context.d.ts +0 -6
- package/dist/providers/shortcut/shortcut-provider.d.ts +0 -34
- package/dist/providers/stories/theme-provider.stories.d.ts +0 -6
- package/dist/providers/theme/index.d.ts +0 -3
- package/dist/providers/theme/theme-provider-types.d.ts +0 -5
- package/dist/providers/theme/themeProvider.d.ts +0 -9
- package/dist/restio-ui.cjs.js +0 -201
- package/dist/types/global-types.d.ts +0 -51
- package/dist/types/storybook-types.d.ts +0 -1
- package/dist/utility-components/avatar/avatar-types.d.ts +0 -15
- package/dist/utility-components/avatar/avatar.d.ts +0 -4
- package/dist/utility-components/avatar/avatar.stories.d.ts +0 -8
- package/dist/utility-components/chip/chip-types.d.ts +0 -16
- package/dist/utility-components/chip/chip.d.ts +0 -3
- package/dist/utility-components/chip/chip.stories.d.ts +0 -10
- package/dist/utility-components/helper-text/helper-text-types.d.ts +0 -19
- package/dist/utility-components/helper-text/helper-text.d.ts +0 -2
- package/dist/utility-components/helper-text/helper-text.stories.d.ts +0 -10
- package/dist/utility-components/helper-text/helper-text.test.d.ts +0 -1
- package/dist/utility-components/icon/icon-assets.d.ts +0 -1
- package/dist/utility-components/icon/icon-types.d.ts +0 -23
- package/dist/utility-components/icon/icon.d.ts +0 -3
- package/dist/utility-components/icon/stories/icon.stories.d.ts +0 -10
- package/dist/utility-components/label/label-types.d.ts +0 -18
- package/dist/utility-components/label/label.d.ts +0 -2
- package/dist/utility-components/label/label.test.d.ts +0 -1
- package/dist/utility-components/overlay-panel/overlay-panel-footer/overlay-panel-footer-types.d.ts +0 -6
- package/dist/utility-components/overlay-panel/overlay-panel-footer/overlay-panel-footer.d.ts +0 -4
- package/dist/utility-components/overlay-panel/overlay-panel-header/overlay-panel-header-types.d.ts +0 -12
- package/dist/utility-components/overlay-panel/overlay-panel-header/overlay-panel-header.d.ts +0 -4
- package/dist/utility-components/overlay-panel/overlay-panel-types.d.ts +0 -65
- package/dist/utility-components/overlay-panel/overlay-panel.d.ts +0 -3
- package/dist/utility-components/overlay-panel/overlay-panel.stories.d.ts +0 -13
- package/dist/utility-components/overlay-panel/use-focus-trap.d.ts +0 -7
- package/dist/utility-components/skeleton/skeleton-types.d.ts +0 -6
- package/dist/utility-components/skeleton/skeleton.d.ts +0 -3
- package/dist/utility-components/skeleton/stories/skeleton.stories.d.ts +0 -9
- package/dist/utility-components/stack/stack-types.d.ts +0 -10
- package/dist/utility-components/stack/stack.d.ts +0 -7
- package/dist/utility-components/stack/stack.stories.d.ts +0 -4
- package/dist/utility-components/toast/toast-types.d.ts +0 -8
- package/dist/utility-components/toast/toast.d.ts +0 -4
- package/dist/utility-components/toast/toast.stories.d.ts +0 -8
- package/dist/utils/general.d.ts +0 -8
- package/dist/utils/shortcut-utils.d.ts +0 -43
- package/dist/vitest.setup.d.ts +0 -0
|
@@ -0,0 +1,1365 @@
|
|
|
1
|
+
import { A as We, B as ge, D as Ee, E as pe, Et as _e, Ft as Pe, Gt as ae, I as Fe, It as ce, Jt as ve, Lt as Oe, Mt as he, N as Te, O as fe, Rt as Be, T as Ae, Ut as Q, Vt as $e, Xt as Le, Y as Ge, Yt as He, f as Ve, mt as Ne, nt as Ye, pt as Xe, q as Ke, rt as Se, u as qe, w as Je, wt as Qe, z as Ue, zt as xe } from "./src-DzNRRdGD.js";
|
|
2
|
+
import { useCallback as y, useEffect as te, useMemo as q, useRef as ne, useState as k } from "react";
|
|
3
|
+
import { createPortal as Ze } from "react-dom";
|
|
4
|
+
var er = { "rst-pip-container": "_rst-pip-container_63eby_1" }, e = He(), Nr = ({ pipWindow: r, className: s, children: i, ...a }) => {
|
|
5
|
+
if (!r) return null;
|
|
6
|
+
const b = [er["rst-pip-container"], s].filter(Boolean).join(" ");
|
|
7
|
+
return Ze(/* @__PURE__ */ (0, e.jsx)("div", {
|
|
8
|
+
className: b,
|
|
9
|
+
...a,
|
|
10
|
+
children: i
|
|
11
|
+
}), r.document.body);
|
|
12
|
+
};
|
|
13
|
+
function Me() {
|
|
14
|
+
return globalThis.documentPictureInPicture;
|
|
15
|
+
}
|
|
16
|
+
function rr() {
|
|
17
|
+
return Me() !== void 0;
|
|
18
|
+
}
|
|
19
|
+
function sr(r, s = document) {
|
|
20
|
+
for (const i of Array.from(s.querySelectorAll('style, link[rel="stylesheet"]'))) r.head.appendChild(i.cloneNode(!0));
|
|
21
|
+
for (const { name: i, value: a } of Array.from(s.documentElement.attributes)) r.documentElement.setAttribute(i, a);
|
|
22
|
+
for (const { name: i, value: a } of Array.from(s.body.attributes)) r.body.setAttribute(i, a);
|
|
23
|
+
}
|
|
24
|
+
function ar(r) {
|
|
25
|
+
const s = r.createElement("style");
|
|
26
|
+
s.textContent = [
|
|
27
|
+
"html, body { height: 100%; margin: 0; }",
|
|
28
|
+
"body {",
|
|
29
|
+
" background-color: var(--rst-backgroundColor-default);",
|
|
30
|
+
" color: var(--rst-fontColor-main);",
|
|
31
|
+
" font: var(--rst-font-body);",
|
|
32
|
+
"}"
|
|
33
|
+
].join(`
|
|
34
|
+
`), r.head.appendChild(s);
|
|
35
|
+
}
|
|
36
|
+
function Sr({ width: r, height: s, copyStyles: i = !0 } = {}) {
|
|
37
|
+
const [a, b] = k(null), [h, g] = k(null), j = ne(null), N = y(async () => {
|
|
38
|
+
const _ = Me();
|
|
39
|
+
if (!(!_ || j.current)) {
|
|
40
|
+
g(null);
|
|
41
|
+
try {
|
|
42
|
+
const p = await _.requestWindow({
|
|
43
|
+
width: r,
|
|
44
|
+
height: s
|
|
45
|
+
});
|
|
46
|
+
j.current = p, i && sr(p.document), ar(p.document), p.addEventListener("pagehide", () => {
|
|
47
|
+
j.current = null, b(null);
|
|
48
|
+
}), b(p);
|
|
49
|
+
} catch (p) {
|
|
50
|
+
g(p instanceof Error ? `${p.name}: ${p.message}` : String(p));
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}, [
|
|
54
|
+
r,
|
|
55
|
+
s,
|
|
56
|
+
i
|
|
57
|
+
]), c = y(() => {
|
|
58
|
+
j.current?.close();
|
|
59
|
+
}, []);
|
|
60
|
+
return te(() => () => j.current?.close(), []), {
|
|
61
|
+
pipWindow: a,
|
|
62
|
+
error: h,
|
|
63
|
+
isOpen: a !== null,
|
|
64
|
+
isSupported: rr(),
|
|
65
|
+
open: N,
|
|
66
|
+
close: c
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
var Mr = 1;
|
|
70
|
+
function tr(r, s) {
|
|
71
|
+
const i = r.col + r.w, a = r.row + r.h, b = s.col + s.w, h = s.row + s.h;
|
|
72
|
+
return r.col < b && i > s.col && r.row < h && a > s.row;
|
|
73
|
+
}
|
|
74
|
+
function we(r) {
|
|
75
|
+
return r.col >= 1 && r.col + r.w - 1 <= 12 && r.row >= 1 && r.row + r.h - 1 <= 30;
|
|
76
|
+
}
|
|
77
|
+
function be(r, s, i) {
|
|
78
|
+
for (const a of s)
|
|
79
|
+
if (a.id !== i && tr(r, a.position))
|
|
80
|
+
return a.id;
|
|
81
|
+
return null;
|
|
82
|
+
}
|
|
83
|
+
function De(r, s, i) {
|
|
84
|
+
for (let h = 1; h <= 30 - s + 1; h++) for (let g = 1; g <= 12 - r + 1; g++) {
|
|
85
|
+
const j = {
|
|
86
|
+
col: g,
|
|
87
|
+
row: h,
|
|
88
|
+
w: r,
|
|
89
|
+
h: s
|
|
90
|
+
};
|
|
91
|
+
if (!be(j, i)) return j;
|
|
92
|
+
}
|
|
93
|
+
return {
|
|
94
|
+
col: 1,
|
|
95
|
+
row: i.reduce((h, g) => Math.max(h, g.position.row + g.position.h), 1),
|
|
96
|
+
w: r,
|
|
97
|
+
h: s
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
function dr(r, s) {
|
|
101
|
+
const i = {};
|
|
102
|
+
for (const a of r) {
|
|
103
|
+
const b = s[a.dataSourceId];
|
|
104
|
+
if (!b) continue;
|
|
105
|
+
const h = b.data ?? [], g = h.length > 0 ? Object.keys(h[0]) : [], j = Ne(g), N = a.columns ?? j, c = Se(N), _ = /* @__PURE__ */ new Set(), p = [];
|
|
106
|
+
for (const v of c) _.has(v.id) || (_.add(v.id), p.push(v));
|
|
107
|
+
i[a.dataSourceId] = p;
|
|
108
|
+
}
|
|
109
|
+
return i;
|
|
110
|
+
}
|
|
111
|
+
var ye = 0;
|
|
112
|
+
function je() {
|
|
113
|
+
return ye += 1, `widget-${Date.now()}-${ye}`;
|
|
114
|
+
}
|
|
115
|
+
function Ce() {
|
|
116
|
+
return {
|
|
117
|
+
version: 1,
|
|
118
|
+
name: "Untitled Dashboard",
|
|
119
|
+
filters: null,
|
|
120
|
+
widgets: []
|
|
121
|
+
};
|
|
122
|
+
}
|
|
123
|
+
function ir(r, s) {
|
|
124
|
+
const [i, a] = k(r ?? Ce), [b, h] = k(null), [g, j] = k(s ? "view" : "edit"), N = ne(!1), c = y(() => {
|
|
125
|
+
N.current = !0;
|
|
126
|
+
}, []), _ = y((o, f, W) => {
|
|
127
|
+
a((d) => {
|
|
128
|
+
const C = {
|
|
129
|
+
id: je(),
|
|
130
|
+
title: `New ${o}`,
|
|
131
|
+
componentType: o,
|
|
132
|
+
dataSourceId: f,
|
|
133
|
+
position: W
|
|
134
|
+
};
|
|
135
|
+
return {
|
|
136
|
+
...d,
|
|
137
|
+
widgets: [...d.widgets, C]
|
|
138
|
+
};
|
|
139
|
+
}), c();
|
|
140
|
+
}, [c]), p = y((o) => {
|
|
141
|
+
a((f) => {
|
|
142
|
+
const W = De(6, 3, f.widgets), d = {
|
|
143
|
+
id: je(),
|
|
144
|
+
position: W,
|
|
145
|
+
...o.widget
|
|
146
|
+
};
|
|
147
|
+
return {
|
|
148
|
+
...f,
|
|
149
|
+
widgets: [...f.widgets, d]
|
|
150
|
+
};
|
|
151
|
+
}), c();
|
|
152
|
+
}, [c]), v = y((o) => {
|
|
153
|
+
a((f) => ({
|
|
154
|
+
...f,
|
|
155
|
+
widgets: f.widgets.filter((W) => W.id !== o)
|
|
156
|
+
})), h((f) => f === o ? null : f), c();
|
|
157
|
+
}, [c]), I = y((o, f) => {
|
|
158
|
+
a((W) => ({
|
|
159
|
+
...W,
|
|
160
|
+
widgets: W.widgets.map((d) => {
|
|
161
|
+
if (d.id !== o) return d;
|
|
162
|
+
const C = {
|
|
163
|
+
...d,
|
|
164
|
+
...f
|
|
165
|
+
};
|
|
166
|
+
if (f.dataSourceId && f.dataSourceId !== d.dataSourceId) {
|
|
167
|
+
const F = fe[d.componentType] ?? [];
|
|
168
|
+
C.columns = void 0, C.componentProps = pe(F), C.filters = void 0, C.uiConfig = void 0;
|
|
169
|
+
}
|
|
170
|
+
return C;
|
|
171
|
+
})
|
|
172
|
+
})), c();
|
|
173
|
+
}, [c]), l = y((o, f) => {
|
|
174
|
+
I(o, { position: f });
|
|
175
|
+
}, [I]), P = y((o) => {
|
|
176
|
+
h(o);
|
|
177
|
+
}, []), L = i.widgets.find((o) => o.id === b) ?? null, T = y((o) => {
|
|
178
|
+
a((f) => ({
|
|
179
|
+
...f,
|
|
180
|
+
name: o
|
|
181
|
+
})), c();
|
|
182
|
+
}, [c]), t = y((o) => {
|
|
183
|
+
a((f) => ({
|
|
184
|
+
...f,
|
|
185
|
+
filters: typeof o == "function" ? o(f.filters) : o
|
|
186
|
+
})), c();
|
|
187
|
+
}, [c]), u = y((o) => {
|
|
188
|
+
a(o ?? Ce()), h(null), N.current = !1;
|
|
189
|
+
}, []), D = y((o) => {
|
|
190
|
+
a(o), h(null), N.current = !1;
|
|
191
|
+
}, []);
|
|
192
|
+
return {
|
|
193
|
+
state: {
|
|
194
|
+
config: i,
|
|
195
|
+
selectedWidgetId: b,
|
|
196
|
+
isDirty: N.current
|
|
197
|
+
},
|
|
198
|
+
mode: g,
|
|
199
|
+
setMode: j,
|
|
200
|
+
addWidget: _,
|
|
201
|
+
addPrebuiltWidget: p,
|
|
202
|
+
removeWidget: v,
|
|
203
|
+
updateWidget: I,
|
|
204
|
+
moveWidget: l,
|
|
205
|
+
selectWidget: P,
|
|
206
|
+
selectedWidget: L,
|
|
207
|
+
setName: T,
|
|
208
|
+
setFilters: t,
|
|
209
|
+
resetConfig: u,
|
|
210
|
+
loadConfig: D
|
|
211
|
+
};
|
|
212
|
+
}
|
|
213
|
+
var n = {
|
|
214
|
+
"rst-dashboard-builder": "_rst-dashboard-builder_19ws7_2",
|
|
215
|
+
"rst-dashboard-builder-sidebar": "_rst-dashboard-builder-sidebar_19ws7_18",
|
|
216
|
+
"rst-dashboard-builder-sidebar-header": "_rst-dashboard-builder-sidebar-header_19ws7_28",
|
|
217
|
+
"rst-dashboard-builder-sidebar-list": "_rst-dashboard-builder-sidebar-list_19ws7_33",
|
|
218
|
+
"rst-dashboard-builder-widget-type-item": "_rst-dashboard-builder-widget-type-item_19ws7_40",
|
|
219
|
+
"rst-dashboard-builder-widget-type-label": "_rst-dashboard-builder-widget-type-label_19ws7_59",
|
|
220
|
+
"rst-dashboard-builder-widget-type-desc": "_rst-dashboard-builder-widget-type-desc_19ws7_63",
|
|
221
|
+
"rst-dashboard-builder-main": "_rst-dashboard-builder-main_19ws7_69",
|
|
222
|
+
"rst-dashboard-builder-toolbar": "_rst-dashboard-builder-toolbar_19ws7_77",
|
|
223
|
+
"rst-dashboard-builder-toolbar-left": "_rst-dashboard-builder-toolbar-left_19ws7_87",
|
|
224
|
+
"rst-dashboard-builder-toolbar-right": "_rst-dashboard-builder-toolbar-right_19ws7_93",
|
|
225
|
+
"rst-dashboard-builder-name-input": "_rst-dashboard-builder-name-input_19ws7_99",
|
|
226
|
+
"rst-dashboard-builder-name-display": "_rst-dashboard-builder-name-display_19ws7_115",
|
|
227
|
+
"rst-dashboard-builder-view": "_rst-dashboard-builder-view_19ws7_122",
|
|
228
|
+
"rst-dashboard-widget": "_rst-dashboard-widget_19ws7_146",
|
|
229
|
+
"rst-switcher": "_rst-switcher_19ws7_170",
|
|
230
|
+
"rst-dashboard-builder-canvas": "_rst-dashboard-builder-canvas_19ws7_183",
|
|
231
|
+
"rst-dashboard-builder-grid": "_rst-dashboard-builder-grid_19ws7_191",
|
|
232
|
+
"rst-dashboard-builder-grid-cell": "_rst-dashboard-builder-grid-cell_19ws7_201",
|
|
233
|
+
"rst-dashboard-builder-grid-cell-view": "_rst-dashboard-builder-grid-cell-view_19ws7_213",
|
|
234
|
+
"rst-dashboard-builder-grid-empty": "_rst-dashboard-builder-grid-empty_19ws7_219",
|
|
235
|
+
"rst-dashboard-builder-widget": "_rst-dashboard-builder-widget_19ws7_40",
|
|
236
|
+
"rst-dashboard-builder-widget-view": "_rst-dashboard-builder-widget-view_19ws7_290",
|
|
237
|
+
"rst-dashboard-builder-widget-selected": "_rst-dashboard-builder-widget-selected_19ws7_298",
|
|
238
|
+
"rst-dashboard-builder-widget-dragging": "_rst-dashboard-builder-widget-dragging_19ws7_304",
|
|
239
|
+
"rst-dashboard-builder-widget-collision": "_rst-dashboard-builder-widget-collision_19ws7_310",
|
|
240
|
+
"rst-dashboard-builder-resize-handle-n": "_rst-dashboard-builder-resize-handle-n_19ws7_317",
|
|
241
|
+
"rst-dashboard-builder-resize-handle-s": "_rst-dashboard-builder-resize-handle-s_19ws7_318",
|
|
242
|
+
"rst-dashboard-builder-resize-handle-e": "_rst-dashboard-builder-resize-handle-e_19ws7_319",
|
|
243
|
+
"rst-dashboard-builder-resize-handle-w": "_rst-dashboard-builder-resize-handle-w_19ws7_320",
|
|
244
|
+
"rst-dashboard-builder-resize-handle-ne": "_rst-dashboard-builder-resize-handle-ne_19ws7_321",
|
|
245
|
+
"rst-dashboard-builder-resize-handle-nw": "_rst-dashboard-builder-resize-handle-nw_19ws7_322",
|
|
246
|
+
"rst-dashboard-builder-resize-handle-se": "_rst-dashboard-builder-resize-handle-se_19ws7_323",
|
|
247
|
+
"rst-dashboard-builder-resize-handle-sw": "_rst-dashboard-builder-resize-handle-sw_19ws7_324",
|
|
248
|
+
"rst-dashboard-builder-filter-body": "_rst-dashboard-builder-filter-body_19ws7_540",
|
|
249
|
+
"rst-dashboard-builder-filter-tabs": "_rst-dashboard-builder-filter-tabs_19ws7_548",
|
|
250
|
+
"rst-dashboard-builder-configurator": "_rst-dashboard-builder-configurator_19ws7_557",
|
|
251
|
+
"rst-dashboard-builder-configurator-header": "_rst-dashboard-builder-configurator-header_19ws7_567",
|
|
252
|
+
"rst-dashboard-builder-configurator-body": "_rst-dashboard-builder-configurator-body_19ws7_575",
|
|
253
|
+
"rst-dashboard-builder-configurator-empty": "_rst-dashboard-builder-configurator-empty_19ws7_582",
|
|
254
|
+
"rst-dashboard-builder-configurator-divider": "_rst-dashboard-builder-configurator-divider_19ws7_593",
|
|
255
|
+
"rst-dashboard-builder-field": "_rst-dashboard-builder-field_19ws7_599",
|
|
256
|
+
"rst-dashboard-builder-field-label": "_rst-dashboard-builder-field-label_19ws7_605",
|
|
257
|
+
"rst-dashboard-builder-checkbox-row": "_rst-dashboard-builder-checkbox-row_19ws7_611",
|
|
258
|
+
"rst-dashboard-builder-checkbox-label": "_rst-dashboard-builder-checkbox-label_19ws7_618",
|
|
259
|
+
"rst-dashboard-builder-drag-ghost": "_rst-dashboard-builder-drag-ghost_19ws7_624",
|
|
260
|
+
"rst-dashboard-builder-drop-zone": "_rst-dashboard-builder-drop-zone_19ws7_638",
|
|
261
|
+
"rst-dashboard-builder-add-widget-item": "_rst-dashboard-builder-add-widget-item_19ws7_646",
|
|
262
|
+
"rst-dashboard-builder-add-widget-item-label": "_rst-dashboard-builder-add-widget-item-label_19ws7_667",
|
|
263
|
+
"rst-dashboard-builder-add-widget-item-desc": "_rst-dashboard-builder-add-widget-item-desc_19ws7_673",
|
|
264
|
+
"rst-dashboard-builder-template-wrapper": "_rst-dashboard-builder-template-wrapper_19ws7_679",
|
|
265
|
+
"rst-dashboard-builder-template-picker": "_rst-dashboard-builder-template-picker_19ws7_683",
|
|
266
|
+
"rst-dashboard-builder-template-picker-header": "_rst-dashboard-builder-template-picker-header_19ws7_697",
|
|
267
|
+
"rst-dashboard-builder-template-item": "_rst-dashboard-builder-template-item_19ws7_705",
|
|
268
|
+
"rst-dashboard-builder-template-item-name": "_rst-dashboard-builder-template-item-name_19ws7_727",
|
|
269
|
+
"rst-dashboard-builder-template-item-desc": "_rst-dashboard-builder-template-item-desc_19ws7_733"
|
|
270
|
+
}, ee = 12, ie = 30, me = 12;
|
|
271
|
+
function nr({ widgets: r, onMoveWidget: s, onAddWidget: i, onChange: a }) {
|
|
272
|
+
const b = ne(null), [h, g] = k(null), [j, N] = k(null), [c, _] = k(null), [p, v] = k(null), [I, l] = k(!1), [P, L] = k(null), [T, t] = k(null), [u, D] = k(null), [o, f] = k(null), [W, d] = k(!1), C = y(() => b.current ? {
|
|
273
|
+
colWidth: (b.current.getBoundingClientRect().width - 132) / ee,
|
|
274
|
+
rowHeight: 92
|
|
275
|
+
} : null, []), F = y((w, S) => {
|
|
276
|
+
if (!b.current) return {
|
|
277
|
+
col: 1,
|
|
278
|
+
row: 1
|
|
279
|
+
};
|
|
280
|
+
const R = b.current.getBoundingClientRect(), z = (R.width - 132) / ee;
|
|
281
|
+
return {
|
|
282
|
+
col: Math.max(1, Math.min(ee, Math.round((w - R.left) / (z + me)) + 1)),
|
|
283
|
+
row: Math.max(1, Math.min(ie, Math.round((S - R.top) / 92) + 1))
|
|
284
|
+
};
|
|
285
|
+
}, []), U = y((w) => {
|
|
286
|
+
if (w.preventDefault(), w.dataTransfer.types.includes("application/widget-type")) {
|
|
287
|
+
w.dataTransfer.dropEffect = "copy";
|
|
288
|
+
return;
|
|
289
|
+
}
|
|
290
|
+
if (w.dataTransfer.types.includes("application/move-widget") && h && j && c) {
|
|
291
|
+
w.dataTransfer.dropEffect = "move";
|
|
292
|
+
const S = r.find((E) => E.id === h);
|
|
293
|
+
if (!S) return;
|
|
294
|
+
const R = C();
|
|
295
|
+
if (!R) return;
|
|
296
|
+
const z = w.clientX - j.x, G = w.clientY - j.y, oe = Math.round(z / (R.colWidth + me)), Y = Math.round(G / R.rowHeight), H = {
|
|
297
|
+
col: Math.max(1, Math.min(ee - S.position.w + 1, c.col + oe)),
|
|
298
|
+
row: Math.max(1, Math.min(ie - S.position.h + 1, c.row + Y)),
|
|
299
|
+
w: S.position.w,
|
|
300
|
+
h: S.position.h
|
|
301
|
+
};
|
|
302
|
+
v(H);
|
|
303
|
+
const B = be(H, r, h);
|
|
304
|
+
l(B !== null);
|
|
305
|
+
}
|
|
306
|
+
}, [
|
|
307
|
+
h,
|
|
308
|
+
j,
|
|
309
|
+
c,
|
|
310
|
+
C,
|
|
311
|
+
r
|
|
312
|
+
]), Z = y((w) => {
|
|
313
|
+
w.preventDefault();
|
|
314
|
+
const S = w.dataTransfer.getData("application/widget-type");
|
|
315
|
+
if (S) {
|
|
316
|
+
const { col: R, row: z } = F(w.clientX, w.clientY), G = {
|
|
317
|
+
col: R,
|
|
318
|
+
row: z,
|
|
319
|
+
w: 4,
|
|
320
|
+
h: 3
|
|
321
|
+
};
|
|
322
|
+
if (R + 4 - 1 > ee && (G.col = 9), z + 3 - 1 > ie && (G.row = 28), be(G, r)) return;
|
|
323
|
+
i(S, "", G), a();
|
|
324
|
+
return;
|
|
325
|
+
}
|
|
326
|
+
h && p && (!I && we(p) && (s(h, p), a()), g(null), N(null), _(null), v(null), l(!1));
|
|
327
|
+
}, [
|
|
328
|
+
F,
|
|
329
|
+
r,
|
|
330
|
+
i,
|
|
331
|
+
a,
|
|
332
|
+
h,
|
|
333
|
+
p,
|
|
334
|
+
I,
|
|
335
|
+
s
|
|
336
|
+
]), re = y((w, S) => {
|
|
337
|
+
w.stopPropagation(), w.dataTransfer.setData("application/move-widget", S.id), w.dataTransfer.effectAllowed = "move", g(S.id), N({
|
|
338
|
+
x: w.clientX,
|
|
339
|
+
y: w.clientY
|
|
340
|
+
}), _({ ...S.position }), v({ ...S.position }), l(!1);
|
|
341
|
+
}, []), de = y(() => {
|
|
342
|
+
g(null), N(null), _(null), v(null), l(!1);
|
|
343
|
+
}, []), x = y((w, S, R) => {
|
|
344
|
+
w.stopPropagation(), w.preventDefault(), L(S.id), t(R), D({ ...S.position }), f({
|
|
345
|
+
x: w.clientX,
|
|
346
|
+
y: w.clientY
|
|
347
|
+
}), d(!1);
|
|
348
|
+
}, []);
|
|
349
|
+
return te(() => {
|
|
350
|
+
if (!P || !T || !u || !o) return;
|
|
351
|
+
const w = (R) => {
|
|
352
|
+
if (!r.find((M) => M.id === P)) return;
|
|
353
|
+
const z = C();
|
|
354
|
+
if (!z) return;
|
|
355
|
+
const G = R.clientX - o.x, oe = R.clientY - o.y, Y = Math.round(G / (z.colWidth + me)), H = Math.round(oe / z.rowHeight), B = u.col, E = u.row, X = u.w, K = u.h;
|
|
356
|
+
let O = { ...u };
|
|
357
|
+
switch (T) {
|
|
358
|
+
case "e": {
|
|
359
|
+
const M = Math.max(1, Math.min(ee - B + 1, X + Y));
|
|
360
|
+
O = {
|
|
361
|
+
...O,
|
|
362
|
+
w: M
|
|
363
|
+
};
|
|
364
|
+
break;
|
|
365
|
+
}
|
|
366
|
+
case "w": {
|
|
367
|
+
const M = Math.max(1, Math.min(B + X - 1, B + Y)), A = B + X - M;
|
|
368
|
+
O = {
|
|
369
|
+
...u,
|
|
370
|
+
col: M,
|
|
371
|
+
w: Math.max(1, A)
|
|
372
|
+
};
|
|
373
|
+
break;
|
|
374
|
+
}
|
|
375
|
+
case "s": {
|
|
376
|
+
const M = Math.max(1, Math.min(ie - E + 1, K + H));
|
|
377
|
+
O = {
|
|
378
|
+
...u,
|
|
379
|
+
h: M
|
|
380
|
+
};
|
|
381
|
+
break;
|
|
382
|
+
}
|
|
383
|
+
case "n": {
|
|
384
|
+
const M = Math.max(1, Math.min(E + K - 1, E + H)), A = E + K - M;
|
|
385
|
+
O = {
|
|
386
|
+
...u,
|
|
387
|
+
row: M,
|
|
388
|
+
h: Math.max(1, A)
|
|
389
|
+
};
|
|
390
|
+
break;
|
|
391
|
+
}
|
|
392
|
+
case "se": {
|
|
393
|
+
const M = Math.max(1, Math.min(ee - B + 1, X + Y)), A = Math.max(1, Math.min(ie - E + 1, K + H));
|
|
394
|
+
O = {
|
|
395
|
+
...u,
|
|
396
|
+
w: M,
|
|
397
|
+
h: A
|
|
398
|
+
};
|
|
399
|
+
break;
|
|
400
|
+
}
|
|
401
|
+
case "sw": {
|
|
402
|
+
const M = Math.max(1, Math.min(B + X - 1, B + Y)), A = B + X - M, m = Math.max(1, Math.min(ie - E + 1, K + H));
|
|
403
|
+
O = {
|
|
404
|
+
...u,
|
|
405
|
+
col: M,
|
|
406
|
+
w: Math.max(1, A),
|
|
407
|
+
h: m
|
|
408
|
+
};
|
|
409
|
+
break;
|
|
410
|
+
}
|
|
411
|
+
case "ne": {
|
|
412
|
+
const M = Math.max(1, Math.min(E + K - 1, E + H)), A = E + K - M, m = Math.max(1, Math.min(ee - B + 1, X + Y));
|
|
413
|
+
O = {
|
|
414
|
+
...u,
|
|
415
|
+
row: M,
|
|
416
|
+
h: Math.max(1, A),
|
|
417
|
+
w: m
|
|
418
|
+
};
|
|
419
|
+
break;
|
|
420
|
+
}
|
|
421
|
+
case "nw": {
|
|
422
|
+
const M = Math.max(1, Math.min(B + X - 1, B + Y)), A = Math.max(1, Math.min(E + K - 1, E + H)), m = B + X - M, $ = E + K - A;
|
|
423
|
+
O = {
|
|
424
|
+
col: M,
|
|
425
|
+
row: A,
|
|
426
|
+
w: Math.max(1, m),
|
|
427
|
+
h: Math.max(1, $)
|
|
428
|
+
};
|
|
429
|
+
break;
|
|
430
|
+
}
|
|
431
|
+
}
|
|
432
|
+
v(O), g(P);
|
|
433
|
+
const le = be(O, r, P);
|
|
434
|
+
d(le !== null), l(le !== null);
|
|
435
|
+
}, S = () => {
|
|
436
|
+
r.find((R) => R.id === P) && p && !W && we(p) && (s(P, p), a()), L(null), t(null), D(null), f(null), d(!1), g(null), N(null), _(null), v(null), l(!1);
|
|
437
|
+
};
|
|
438
|
+
return document.addEventListener("mousemove", w), document.addEventListener("mouseup", S), () => {
|
|
439
|
+
document.removeEventListener("mousemove", w), document.removeEventListener("mouseup", S);
|
|
440
|
+
};
|
|
441
|
+
}, [
|
|
442
|
+
P,
|
|
443
|
+
T,
|
|
444
|
+
u,
|
|
445
|
+
o,
|
|
446
|
+
r,
|
|
447
|
+
p,
|
|
448
|
+
W,
|
|
449
|
+
C,
|
|
450
|
+
s,
|
|
451
|
+
a
|
|
452
|
+
]), {
|
|
453
|
+
gridRef: b,
|
|
454
|
+
draggingWidgetId: h,
|
|
455
|
+
dragPreviewPos: p,
|
|
456
|
+
hasCollision: I,
|
|
457
|
+
resizeCollision: W,
|
|
458
|
+
handleDragOver: U,
|
|
459
|
+
handleDrop: Z,
|
|
460
|
+
handleWidgetDragStart: re,
|
|
461
|
+
handleWidgetDragEnd: de,
|
|
462
|
+
handleResizeStart: x,
|
|
463
|
+
pixelToGrid: F
|
|
464
|
+
};
|
|
465
|
+
}
|
|
466
|
+
var or = 12, lr = 20, ze = ({ widgets: r, selectedWidgetId: s, dataSources: i, onSelectWidget: a, onMoveWidget: b, onRemoveWidget: h, onAddWidget: g, onChange: j, getWidgetActions: N, mode: c = "edit" }) => {
|
|
467
|
+
const _ = c === "view", { gridRef: p, draggingWidgetId: v, dragPreviewPos: I, hasCollision: l, handleDragOver: P, handleDrop: L, handleWidgetDragStart: T, handleWidgetDragEnd: t, handleResizeStart: u } = nr({
|
|
468
|
+
widgets: r,
|
|
469
|
+
onMoveWidget: b,
|
|
470
|
+
onAddWidget: g,
|
|
471
|
+
onChange: j
|
|
472
|
+
}), D = y((d, C) => {
|
|
473
|
+
d.stopPropagation(), a(C);
|
|
474
|
+
}, [a]), o = y(() => {
|
|
475
|
+
a(null);
|
|
476
|
+
}, [a]), f = y((d) => {
|
|
477
|
+
const C = i[d.dataSourceId]?.data ?? [], F = C.length > 0 ? Object.keys(C[0]) : [];
|
|
478
|
+
return {
|
|
479
|
+
data: C,
|
|
480
|
+
columns: d.columns ?? Ne(F)
|
|
481
|
+
};
|
|
482
|
+
}, [i]), W = [];
|
|
483
|
+
for (let d = 1; d <= lr; d++) for (let C = 1; C <= or; C++) {
|
|
484
|
+
const F = _ ? n["rst-dashboard-builder-grid-cell-view"] : n["rst-dashboard-builder-grid-cell"];
|
|
485
|
+
W.push(/* @__PURE__ */ (0, e.jsx)("div", {
|
|
486
|
+
className: F,
|
|
487
|
+
style: {
|
|
488
|
+
gridColumn: C,
|
|
489
|
+
gridRow: d
|
|
490
|
+
}
|
|
491
|
+
}, `cell-${d}-${C}`));
|
|
492
|
+
}
|
|
493
|
+
return /* @__PURE__ */ (0, e.jsx)("div", {
|
|
494
|
+
className: n["rst-dashboard-builder-canvas"],
|
|
495
|
+
onClick: o,
|
|
496
|
+
children: /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
497
|
+
ref: p,
|
|
498
|
+
className: n["rst-dashboard-builder-grid"],
|
|
499
|
+
onDragOver: P,
|
|
500
|
+
onDrop: L,
|
|
501
|
+
children: [
|
|
502
|
+
W,
|
|
503
|
+
r.length === 0 && /* @__PURE__ */ (0, e.jsx)("div", {
|
|
504
|
+
className: n["rst-dashboard-builder-grid-empty"],
|
|
505
|
+
children: "Drag a widget from the palette to get started"
|
|
506
|
+
}),
|
|
507
|
+
r.map((d) => {
|
|
508
|
+
const C = !_ && d.id === s, F = !_ && d.id === v, U = f(d), Z = F && I ? I : d.position, re = F && l, de = [
|
|
509
|
+
n["rst-dashboard-builder-widget"],
|
|
510
|
+
_ ? n["rst-dashboard-builder-widget-view"] : "",
|
|
511
|
+
C ? n["rst-dashboard-builder-widget-selected"] : "",
|
|
512
|
+
F ? n["rst-dashboard-builder-widget-dragging"] : "",
|
|
513
|
+
re ? n["rst-dashboard-builder-widget-collision"] : ""
|
|
514
|
+
].filter(Boolean).join(" ");
|
|
515
|
+
return /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
516
|
+
className: de,
|
|
517
|
+
style: {
|
|
518
|
+
gridColumn: `${Z.col} / span ${Z.w}`,
|
|
519
|
+
gridRow: `${Z.row} / span ${Z.h}`
|
|
520
|
+
},
|
|
521
|
+
draggable: !_,
|
|
522
|
+
..._ ? {} : {
|
|
523
|
+
onDragStart: (x) => T(x, d),
|
|
524
|
+
onDragEnd: t,
|
|
525
|
+
onClick: (x) => D(x, d.id),
|
|
526
|
+
role: "button",
|
|
527
|
+
tabIndex: 0,
|
|
528
|
+
"aria-label": `Widget: ${d.title}`,
|
|
529
|
+
onKeyDown: (x) => {
|
|
530
|
+
(x.key === "Enter" || x.key === " ") && (x.preventDefault(), a(d.id)), (x.key === "Delete" || x.key === "Backspace") && (x.preventDefault(), h(d.id), j());
|
|
531
|
+
}
|
|
532
|
+
},
|
|
533
|
+
children: [/* @__PURE__ */ (0, e.jsx)(qe, {
|
|
534
|
+
id: d.id,
|
|
535
|
+
dataSourceId: d.dataSourceId,
|
|
536
|
+
title: d.title,
|
|
537
|
+
subtitle: d.subtitle,
|
|
538
|
+
icon: d.icon,
|
|
539
|
+
data: U.data,
|
|
540
|
+
columns: U.columns,
|
|
541
|
+
enableExport: N?.(d).enableExport ?? !0,
|
|
542
|
+
enableScreenshot: N?.(d).enableScreenshot ?? !1,
|
|
543
|
+
enableExpand: N?.(d).enableExpand ?? !0,
|
|
544
|
+
enableFilter: N?.(d).enableFilter ?? !1,
|
|
545
|
+
fieldOptions: Se(U.columns),
|
|
546
|
+
children: ({ data: x }) => /* @__PURE__ */ (0, e.jsx)(Je, {
|
|
547
|
+
data: x,
|
|
548
|
+
columns: U.columns,
|
|
549
|
+
activeComponent: d.componentType,
|
|
550
|
+
componentProps: d.componentProps,
|
|
551
|
+
showConfigurator: !1
|
|
552
|
+
})
|
|
553
|
+
}), !_ && C && /* @__PURE__ */ (0, e.jsxs)(e.Fragment, { children: [
|
|
554
|
+
/* @__PURE__ */ (0, e.jsx)("div", {
|
|
555
|
+
className: n["rst-dashboard-builder-resize-handle-n"],
|
|
556
|
+
onMouseDown: (x) => u(x, d, "n")
|
|
557
|
+
}),
|
|
558
|
+
/* @__PURE__ */ (0, e.jsx)("div", {
|
|
559
|
+
className: n["rst-dashboard-builder-resize-handle-s"],
|
|
560
|
+
onMouseDown: (x) => u(x, d, "s")
|
|
561
|
+
}),
|
|
562
|
+
/* @__PURE__ */ (0, e.jsx)("div", {
|
|
563
|
+
className: n["rst-dashboard-builder-resize-handle-e"],
|
|
564
|
+
onMouseDown: (x) => u(x, d, "e")
|
|
565
|
+
}),
|
|
566
|
+
/* @__PURE__ */ (0, e.jsx)("div", {
|
|
567
|
+
className: n["rst-dashboard-builder-resize-handle-w"],
|
|
568
|
+
onMouseDown: (x) => u(x, d, "w")
|
|
569
|
+
}),
|
|
570
|
+
/* @__PURE__ */ (0, e.jsx)("div", {
|
|
571
|
+
className: n["rst-dashboard-builder-resize-handle-ne"],
|
|
572
|
+
onMouseDown: (x) => u(x, d, "ne")
|
|
573
|
+
}),
|
|
574
|
+
/* @__PURE__ */ (0, e.jsx)("div", {
|
|
575
|
+
className: n["rst-dashboard-builder-resize-handle-nw"],
|
|
576
|
+
onMouseDown: (x) => u(x, d, "nw")
|
|
577
|
+
}),
|
|
578
|
+
/* @__PURE__ */ (0, e.jsx)("div", {
|
|
579
|
+
className: n["rst-dashboard-builder-resize-handle-se"],
|
|
580
|
+
onMouseDown: (x) => u(x, d, "se")
|
|
581
|
+
}),
|
|
582
|
+
/* @__PURE__ */ (0, e.jsx)("div", {
|
|
583
|
+
className: n["rst-dashboard-builder-resize-handle-sw"],
|
|
584
|
+
onMouseDown: (x) => u(x, d, "sw")
|
|
585
|
+
})
|
|
586
|
+
] })]
|
|
587
|
+
}, `${d.id}::${d.dataSourceId}`);
|
|
588
|
+
})
|
|
589
|
+
]
|
|
590
|
+
})
|
|
591
|
+
});
|
|
592
|
+
};
|
|
593
|
+
ze.displayName = "BuilderCanvas";
|
|
594
|
+
var cr = [
|
|
595
|
+
{
|
|
596
|
+
type: "table-grid",
|
|
597
|
+
label: "Table",
|
|
598
|
+
icon: "table",
|
|
599
|
+
description: "Sortable, filterable data table"
|
|
600
|
+
},
|
|
601
|
+
{
|
|
602
|
+
type: "chart",
|
|
603
|
+
label: "Chart",
|
|
604
|
+
icon: "chart",
|
|
605
|
+
description: "Bar, line, pie charts"
|
|
606
|
+
},
|
|
607
|
+
{
|
|
608
|
+
type: "calendar",
|
|
609
|
+
label: "Calendar",
|
|
610
|
+
icon: "calendar",
|
|
611
|
+
description: "Calendar view of events"
|
|
612
|
+
},
|
|
613
|
+
{
|
|
614
|
+
type: "card-list",
|
|
615
|
+
label: "Card List",
|
|
616
|
+
icon: "list",
|
|
617
|
+
description: "Visual card layout"
|
|
618
|
+
},
|
|
619
|
+
{
|
|
620
|
+
type: "form",
|
|
621
|
+
label: "Form",
|
|
622
|
+
icon: "form",
|
|
623
|
+
description: "Editable form from schema"
|
|
624
|
+
},
|
|
625
|
+
{
|
|
626
|
+
type: "gantt",
|
|
627
|
+
label: "Gantt",
|
|
628
|
+
icon: "chart-gantt",
|
|
629
|
+
description: "Project timeline view"
|
|
630
|
+
},
|
|
631
|
+
{
|
|
632
|
+
type: "kpi",
|
|
633
|
+
label: "KPI",
|
|
634
|
+
icon: "chart",
|
|
635
|
+
description: "Single-metric KPI card"
|
|
636
|
+
}
|
|
637
|
+
], ke = ({ widget: r, dataSources: s, onUpdate: i, onRemove: a, onClose: b, onAddWidget: h, prebuiltSections: g, onAddPrebuiltSection: j }) => {
|
|
638
|
+
const N = Object.values(s).map((t) => ({
|
|
639
|
+
value: t.id,
|
|
640
|
+
label: t.name
|
|
641
|
+
})), c = q(() => [{
|
|
642
|
+
value: "",
|
|
643
|
+
id: "none"
|
|
644
|
+
}, ...Object.keys(Le).map((t) => ({
|
|
645
|
+
value: t,
|
|
646
|
+
leadingVisual: t
|
|
647
|
+
}))], []), _ = r?.dataSourceId, p = q(() => {
|
|
648
|
+
if (!_) return [];
|
|
649
|
+
const t = s[_];
|
|
650
|
+
return t ? t.fields.map((u) => ({
|
|
651
|
+
id: u.id,
|
|
652
|
+
header: u.name,
|
|
653
|
+
accessorKey: u.id
|
|
654
|
+
})) : [];
|
|
655
|
+
}, [_, s]), v = q(() => fe[r?.componentType ?? "table-grid"] ?? [], [r?.componentType]), I = q(() => r?.componentProps ?? pe(v), [r?.componentProps, v]), l = y((t, u) => {
|
|
656
|
+
i({ [t]: u });
|
|
657
|
+
}, [i]), P = y((t) => {
|
|
658
|
+
const u = fe[t] ?? [];
|
|
659
|
+
i({
|
|
660
|
+
componentType: t,
|
|
661
|
+
componentProps: pe(u)
|
|
662
|
+
});
|
|
663
|
+
}, [i]), L = y((t, u) => {
|
|
664
|
+
i({ componentProps: {
|
|
665
|
+
...I,
|
|
666
|
+
[t]: u
|
|
667
|
+
} });
|
|
668
|
+
}, [I, i]), T = q(() => !g || g.length === 0 ? [] : g.filter((t) => t.version === 1), [g]);
|
|
669
|
+
return r ? /* @__PURE__ */ (0, e.jsxs)("aside", {
|
|
670
|
+
className: n["rst-dashboard-builder-configurator"],
|
|
671
|
+
"aria-label": "Widget configurator",
|
|
672
|
+
children: [/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
673
|
+
className: n["rst-dashboard-builder-configurator-header"],
|
|
674
|
+
children: [/* @__PURE__ */ (0, e.jsx)(ae, {
|
|
675
|
+
variant: "heading",
|
|
676
|
+
children: "Configure"
|
|
677
|
+
}), /* @__PURE__ */ (0, e.jsx)(Q, {
|
|
678
|
+
variant: "invisible",
|
|
679
|
+
size: "small",
|
|
680
|
+
leadingVisual: "close",
|
|
681
|
+
onClick: b,
|
|
682
|
+
"aria-label": "Close configurator"
|
|
683
|
+
})]
|
|
684
|
+
}), /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
685
|
+
className: n["rst-dashboard-builder-configurator-body"],
|
|
686
|
+
children: [
|
|
687
|
+
/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
688
|
+
className: n["rst-dashboard-builder-field"],
|
|
689
|
+
children: [/* @__PURE__ */ (0, e.jsx)("label", {
|
|
690
|
+
className: n["rst-dashboard-builder-field-label"],
|
|
691
|
+
children: "Title"
|
|
692
|
+
}), /* @__PURE__ */ (0, e.jsx)(xe, {
|
|
693
|
+
value: r.title,
|
|
694
|
+
onChange: (t) => l("title", t ?? ""),
|
|
695
|
+
placeholder: "Widget title"
|
|
696
|
+
})]
|
|
697
|
+
}),
|
|
698
|
+
/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
699
|
+
className: n["rst-dashboard-builder-field"],
|
|
700
|
+
children: [/* @__PURE__ */ (0, e.jsx)("label", {
|
|
701
|
+
className: n["rst-dashboard-builder-field-label"],
|
|
702
|
+
children: "Subtitle"
|
|
703
|
+
}), /* @__PURE__ */ (0, e.jsx)(xe, {
|
|
704
|
+
value: r.subtitle ?? "",
|
|
705
|
+
onChange: (t) => l("subtitle", t || void 0),
|
|
706
|
+
placeholder: "Optional subtitle"
|
|
707
|
+
})]
|
|
708
|
+
}),
|
|
709
|
+
/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
710
|
+
className: n["rst-dashboard-builder-field"],
|
|
711
|
+
children: [/* @__PURE__ */ (0, e.jsx)("label", {
|
|
712
|
+
className: n["rst-dashboard-builder-field-label"],
|
|
713
|
+
children: "Icon"
|
|
714
|
+
}), /* @__PURE__ */ (0, e.jsx)(_e, {
|
|
715
|
+
value: r.icon ?? "",
|
|
716
|
+
onChange: (t) => l("icon", t || void 0),
|
|
717
|
+
options: c,
|
|
718
|
+
renderList: ({ options: t, value: u, onChange: D, onClose: o }) => /* @__PURE__ */ (0, e.jsx)(Be, {
|
|
719
|
+
options: t,
|
|
720
|
+
activeIndex: [typeof u == "string" ? u : ""],
|
|
721
|
+
onClick: (f) => {
|
|
722
|
+
D(f.value), o();
|
|
723
|
+
},
|
|
724
|
+
showFilter: !0
|
|
725
|
+
})
|
|
726
|
+
})]
|
|
727
|
+
}),
|
|
728
|
+
/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
729
|
+
className: n["rst-dashboard-builder-field"],
|
|
730
|
+
children: [/* @__PURE__ */ (0, e.jsx)("label", {
|
|
731
|
+
className: n["rst-dashboard-builder-field-label"],
|
|
732
|
+
children: "Data Source"
|
|
733
|
+
}), /* @__PURE__ */ (0, e.jsx)(_e, {
|
|
734
|
+
value: r.dataSourceId,
|
|
735
|
+
onChange: (t) => l("dataSourceId", t),
|
|
736
|
+
options: N
|
|
737
|
+
})]
|
|
738
|
+
}),
|
|
739
|
+
r.dataSourceId && s[r.dataSourceId] && /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
740
|
+
className: n["rst-dashboard-builder-field"],
|
|
741
|
+
children: [/* @__PURE__ */ (0, e.jsx)("label", {
|
|
742
|
+
className: n["rst-dashboard-builder-field-label"],
|
|
743
|
+
children: "Columns"
|
|
744
|
+
}), /* @__PURE__ */ (0, e.jsx)(Pe, {
|
|
745
|
+
options: s[r.dataSourceId].fields.map((t) => ({
|
|
746
|
+
value: t.id,
|
|
747
|
+
label: t.name
|
|
748
|
+
})),
|
|
749
|
+
value: r.columns?.map((t) => t.id).filter(Boolean) ?? s[r.dataSourceId].fields.map((t) => t.id),
|
|
750
|
+
onChange: (t) => {
|
|
751
|
+
const u = s[r.dataSourceId], D = t.map((o) => u.fields.find((f) => f.id === o)).filter(Boolean).map((o) => ({
|
|
752
|
+
id: o.id,
|
|
753
|
+
header: o.name,
|
|
754
|
+
accessorKey: o.id
|
|
755
|
+
}));
|
|
756
|
+
i({ columns: D.length === u.fields.length ? void 0 : D });
|
|
757
|
+
}
|
|
758
|
+
})]
|
|
759
|
+
}),
|
|
760
|
+
/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
761
|
+
className: n["rst-dashboard-builder-field"],
|
|
762
|
+
children: [
|
|
763
|
+
/* @__PURE__ */ (0, e.jsx)("label", {
|
|
764
|
+
className: n["rst-dashboard-builder-field-label"],
|
|
765
|
+
children: "Actions"
|
|
766
|
+
}),
|
|
767
|
+
/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
768
|
+
className: n["rst-dashboard-builder-checkbox-row"],
|
|
769
|
+
children: [/* @__PURE__ */ (0, e.jsx)(ce, {
|
|
770
|
+
checked: r.enableExport ?? !0,
|
|
771
|
+
onChange: (t) => l("enableExport", t)
|
|
772
|
+
}), /* @__PURE__ */ (0, e.jsx)("span", {
|
|
773
|
+
className: n["rst-dashboard-builder-checkbox-label"],
|
|
774
|
+
children: "Export CSV"
|
|
775
|
+
})]
|
|
776
|
+
}),
|
|
777
|
+
/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
778
|
+
className: n["rst-dashboard-builder-checkbox-row"],
|
|
779
|
+
children: [/* @__PURE__ */ (0, e.jsx)(ce, {
|
|
780
|
+
checked: r.enableScreenshot ?? !1,
|
|
781
|
+
onChange: (t) => l("enableScreenshot", t)
|
|
782
|
+
}), /* @__PURE__ */ (0, e.jsx)("span", {
|
|
783
|
+
className: n["rst-dashboard-builder-checkbox-label"],
|
|
784
|
+
children: "Screenshot"
|
|
785
|
+
})]
|
|
786
|
+
}),
|
|
787
|
+
/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
788
|
+
className: n["rst-dashboard-builder-checkbox-row"],
|
|
789
|
+
children: [/* @__PURE__ */ (0, e.jsx)(ce, {
|
|
790
|
+
checked: r.enableExpand ?? !0,
|
|
791
|
+
onChange: (t) => l("enableExpand", t)
|
|
792
|
+
}), /* @__PURE__ */ (0, e.jsx)("span", {
|
|
793
|
+
className: n["rst-dashboard-builder-checkbox-label"],
|
|
794
|
+
children: "Expand"
|
|
795
|
+
})]
|
|
796
|
+
}),
|
|
797
|
+
/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
798
|
+
className: n["rst-dashboard-builder-checkbox-row"],
|
|
799
|
+
children: [/* @__PURE__ */ (0, e.jsx)(ce, {
|
|
800
|
+
checked: r.enableFilter ?? !0,
|
|
801
|
+
onChange: (t) => l("enableFilter", t)
|
|
802
|
+
}), /* @__PURE__ */ (0, e.jsx)("span", {
|
|
803
|
+
className: n["rst-dashboard-builder-checkbox-label"],
|
|
804
|
+
children: "Filter"
|
|
805
|
+
})]
|
|
806
|
+
})
|
|
807
|
+
]
|
|
808
|
+
}),
|
|
809
|
+
/* @__PURE__ */ (0, e.jsx)("div", { className: n["rst-dashboard-builder-configurator-divider"] }),
|
|
810
|
+
/* @__PURE__ */ (0, e.jsx)(Ae, {
|
|
811
|
+
schema: v,
|
|
812
|
+
values: I,
|
|
813
|
+
onChange: L,
|
|
814
|
+
columns: p,
|
|
815
|
+
scope: "all",
|
|
816
|
+
componentId: r.componentType,
|
|
817
|
+
onComponentChange: P,
|
|
818
|
+
componentMetaList: Ee
|
|
819
|
+
}, r.dataSourceId ?? "no-ds"),
|
|
820
|
+
/* @__PURE__ */ (0, e.jsx)("div", { className: n["rst-dashboard-builder-configurator-divider"] }),
|
|
821
|
+
/* @__PURE__ */ (0, e.jsx)(Q, {
|
|
822
|
+
variant: "danger",
|
|
823
|
+
size: "small",
|
|
824
|
+
value: "Remove widget",
|
|
825
|
+
leadingVisual: "trash",
|
|
826
|
+
onClick: a
|
|
827
|
+
})
|
|
828
|
+
]
|
|
829
|
+
})]
|
|
830
|
+
}) : /* @__PURE__ */ (0, e.jsxs)("aside", {
|
|
831
|
+
className: n["rst-dashboard-builder-configurator"],
|
|
832
|
+
"aria-label": "Add widget",
|
|
833
|
+
children: [/* @__PURE__ */ (0, e.jsx)("div", {
|
|
834
|
+
className: n["rst-dashboard-builder-configurator-header"],
|
|
835
|
+
children: /* @__PURE__ */ (0, e.jsx)(ae, {
|
|
836
|
+
variant: "heading",
|
|
837
|
+
children: "Add Widget"
|
|
838
|
+
})
|
|
839
|
+
}), /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
840
|
+
className: n["rst-dashboard-builder-configurator-body"],
|
|
841
|
+
children: [cr.map((t) => /* @__PURE__ */ (0, e.jsxs)("button", {
|
|
842
|
+
className: n["rst-dashboard-builder-add-widget-item"],
|
|
843
|
+
onClick: () => h(t.type),
|
|
844
|
+
children: [/* @__PURE__ */ (0, e.jsx)(ve, { src: t.icon }), /* @__PURE__ */ (0, e.jsxs)("div", { children: [/* @__PURE__ */ (0, e.jsx)("div", {
|
|
845
|
+
className: n["rst-dashboard-builder-add-widget-item-label"],
|
|
846
|
+
children: t.label
|
|
847
|
+
}), /* @__PURE__ */ (0, e.jsx)("div", {
|
|
848
|
+
className: n["rst-dashboard-builder-add-widget-item-desc"],
|
|
849
|
+
children: t.description
|
|
850
|
+
})] })]
|
|
851
|
+
}, t.type)), T.length > 0 && /* @__PURE__ */ (0, e.jsxs)(e.Fragment, { children: [
|
|
852
|
+
/* @__PURE__ */ (0, e.jsx)("div", { className: n["rst-dashboard-builder-configurator-divider"] }),
|
|
853
|
+
/* @__PURE__ */ (0, e.jsx)(ae, {
|
|
854
|
+
variant: "heading",
|
|
855
|
+
children: "Pre-built Sections"
|
|
856
|
+
}),
|
|
857
|
+
T.map((t) => /* @__PURE__ */ (0, e.jsxs)("button", {
|
|
858
|
+
className: n["rst-dashboard-builder-add-widget-item"],
|
|
859
|
+
onClick: () => j?.(t),
|
|
860
|
+
children: [/* @__PURE__ */ (0, e.jsx)(ve, { src: "layout" }), /* @__PURE__ */ (0, e.jsxs)("div", { children: [/* @__PURE__ */ (0, e.jsx)("div", {
|
|
861
|
+
className: n["rst-dashboard-builder-add-widget-item-label"],
|
|
862
|
+
children: t.name
|
|
863
|
+
}), /* @__PURE__ */ (0, e.jsx)("div", {
|
|
864
|
+
className: n["rst-dashboard-builder-add-widget-item-desc"],
|
|
865
|
+
children: t.description
|
|
866
|
+
})] })]
|
|
867
|
+
}, t.name))
|
|
868
|
+
] })]
|
|
869
|
+
})]
|
|
870
|
+
});
|
|
871
|
+
};
|
|
872
|
+
ke.displayName = "WidgetConfigurator";
|
|
873
|
+
var ur = ({ dataSources: r, initialConfig: s, templates: i, prebuiltSections: a, onSave: b, onChange: h, widgetActionDefaults: g, readOnly: j, className: N }) => {
|
|
874
|
+
const { state: c, mode: _, setMode: p, addWidget: v, addPrebuiltWidget: I, removeWidget: l, updateWidget: P, moveWidget: L, selectWidget: T, selectedWidget: t, setName: u, setFilters: D, loadConfig: o } = ir(s, j), [f, W] = k(!1), [d, C] = k("dialog"), [F, U] = k(null), [Z, re] = k(null), [de, x] = k(!1), [w, S] = k(null), R = q(() => dr(c.config.widgets, r), [c.config.widgets, r]), z = _ === "view", G = z ? Z : c.config.filters;
|
|
875
|
+
te(() => {
|
|
876
|
+
f && S(G);
|
|
877
|
+
}, [f]);
|
|
878
|
+
const oe = y(() => {
|
|
879
|
+
z ? re(w) : D(w), W(!1);
|
|
880
|
+
}, [
|
|
881
|
+
w,
|
|
882
|
+
z,
|
|
883
|
+
D
|
|
884
|
+
]);
|
|
885
|
+
te(() => {
|
|
886
|
+
z && !de && (re(c.config.filters), x(!0)), z || x(!1);
|
|
887
|
+
}, [
|
|
888
|
+
z,
|
|
889
|
+
de,
|
|
890
|
+
c.config.filters
|
|
891
|
+
]);
|
|
892
|
+
const Y = ne(h);
|
|
893
|
+
Y.current = h;
|
|
894
|
+
const H = y((m, $) => {
|
|
895
|
+
(z ? re : D)((se) => ({
|
|
896
|
+
...se ?? {},
|
|
897
|
+
[m]: $
|
|
898
|
+
}));
|
|
899
|
+
}, [z, D]), B = q(() => ({
|
|
900
|
+
filters: G,
|
|
901
|
+
onFilterChange: H
|
|
902
|
+
}), [G, H]), E = q(() => !i || i.length === 0 ? [] : i.filter((m) => m.version === 1), [i]), X = q(() => E.map((m) => ({
|
|
903
|
+
value: m.name,
|
|
904
|
+
id: m.name,
|
|
905
|
+
description: m.description
|
|
906
|
+
})), [E]), K = y((m) => {
|
|
907
|
+
const $ = E.find((J) => J.name === m);
|
|
908
|
+
if (!$) return;
|
|
909
|
+
const se = {
|
|
910
|
+
version: 1,
|
|
911
|
+
...$.config
|
|
912
|
+
};
|
|
913
|
+
o(se);
|
|
914
|
+
}, [E, o]), O = q(() => ({
|
|
915
|
+
enableExport: g?.enableExport ?? !0,
|
|
916
|
+
enableScreenshot: g?.enableScreenshot ?? !1,
|
|
917
|
+
enableExpand: g?.enableExpand ?? !0,
|
|
918
|
+
enableFilter: g?.enableFilter ?? !0
|
|
919
|
+
}), [g]), le = y((m) => ({
|
|
920
|
+
enableExport: m.enableExport ?? O.enableExport,
|
|
921
|
+
enableScreenshot: m.enableScreenshot ?? O.enableScreenshot,
|
|
922
|
+
enableExpand: m.enableExpand ?? O.enableExpand,
|
|
923
|
+
enableFilter: m.enableFilter ?? O.enableFilter
|
|
924
|
+
}), [O]);
|
|
925
|
+
te(() => {
|
|
926
|
+
Y.current?.(c.config);
|
|
927
|
+
}, [c.config]);
|
|
928
|
+
const M = [n["rst-dashboard-builder"], N].filter(Boolean).join(" "), A = y(() => {
|
|
929
|
+
b(c.config);
|
|
930
|
+
}, [c.config, b]);
|
|
931
|
+
return /* @__PURE__ */ (0, e.jsx)("div", {
|
|
932
|
+
className: M,
|
|
933
|
+
children: /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
934
|
+
className: n["rst-dashboard-builder-main"],
|
|
935
|
+
children: [/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
936
|
+
className: n["rst-dashboard-builder-toolbar"],
|
|
937
|
+
children: [/* @__PURE__ */ (0, e.jsxs)("div", {
|
|
938
|
+
className: n["rst-dashboard-builder-toolbar-left"],
|
|
939
|
+
children: [z ? /* @__PURE__ */ (0, e.jsx)("span", {
|
|
940
|
+
className: n["rst-dashboard-builder-name-display"],
|
|
941
|
+
children: c.config.name
|
|
942
|
+
}) : /* @__PURE__ */ (0, e.jsx)("input", {
|
|
943
|
+
className: n["rst-dashboard-builder-name-input"],
|
|
944
|
+
type: "text",
|
|
945
|
+
value: c.config.name,
|
|
946
|
+
onChange: (m) => u(m.target.value),
|
|
947
|
+
placeholder: "Dashboard name",
|
|
948
|
+
"aria-label": "Dashboard name"
|
|
949
|
+
}), Object.keys(R).length > 0 && /* @__PURE__ */ (0, e.jsx)(Q, {
|
|
950
|
+
variant: "invisible",
|
|
951
|
+
size: "small",
|
|
952
|
+
leadingVisual: "filter",
|
|
953
|
+
onClick: () => W((m) => !m),
|
|
954
|
+
"aria-label": "Toggle filter panel",
|
|
955
|
+
"aria-pressed": f
|
|
956
|
+
})]
|
|
957
|
+
}), /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
958
|
+
className: n["rst-dashboard-builder-toolbar-right"],
|
|
959
|
+
children: [
|
|
960
|
+
E.length > 0 && !z && /* @__PURE__ */ (0, e.jsx)(Oe, {
|
|
961
|
+
options: X,
|
|
962
|
+
onChange: K,
|
|
963
|
+
placeholder: "Load Template",
|
|
964
|
+
size: "small"
|
|
965
|
+
}),
|
|
966
|
+
!j && /* @__PURE__ */ (0, e.jsx)($e, {
|
|
967
|
+
value: _,
|
|
968
|
+
options: [{ value: "edit" }, { value: "view" }],
|
|
969
|
+
onChange: (m) => p(m)
|
|
970
|
+
}),
|
|
971
|
+
!z && /* @__PURE__ */ (0, e.jsx)(Q, {
|
|
972
|
+
variant: "primary",
|
|
973
|
+
size: "small",
|
|
974
|
+
value: "Save",
|
|
975
|
+
onClick: A
|
|
976
|
+
})
|
|
977
|
+
]
|
|
978
|
+
})]
|
|
979
|
+
}), /* @__PURE__ */ (0, e.jsx)(Ve, {
|
|
980
|
+
value: B,
|
|
981
|
+
children: /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
982
|
+
style: {
|
|
983
|
+
display: "flex",
|
|
984
|
+
flex: 1,
|
|
985
|
+
overflow: "hidden"
|
|
986
|
+
},
|
|
987
|
+
children: [
|
|
988
|
+
/* @__PURE__ */ (0, e.jsx)(ze, {
|
|
989
|
+
mode: _,
|
|
990
|
+
widgets: c.config.widgets,
|
|
991
|
+
selectedWidgetId: c.selectedWidgetId,
|
|
992
|
+
dataSources: r,
|
|
993
|
+
onSelectWidget: T,
|
|
994
|
+
onMoveWidget: L,
|
|
995
|
+
onRemoveWidget: l,
|
|
996
|
+
onAddWidget: v,
|
|
997
|
+
onChange: () => {
|
|
998
|
+
},
|
|
999
|
+
getWidgetActions: le
|
|
1000
|
+
}),
|
|
1001
|
+
f && Object.keys(R).length > 0 && /* @__PURE__ */ (0, e.jsxs)(he, {
|
|
1002
|
+
open: f,
|
|
1003
|
+
variant: d,
|
|
1004
|
+
position: d === "dialog" ? "center" : "right",
|
|
1005
|
+
onClose: () => W(!1),
|
|
1006
|
+
closeOnEscape: !0,
|
|
1007
|
+
closeOnClickOutside: d === "dialog",
|
|
1008
|
+
width: d === "sidepanel" ? 360 : void 0,
|
|
1009
|
+
maxWidth: d === "dialog" ? 640 : void 0,
|
|
1010
|
+
maxHeight: d === "dialog" ? "80vh" : void 0,
|
|
1011
|
+
"aria-label": "Dashboard filters",
|
|
1012
|
+
children: [
|
|
1013
|
+
/* @__PURE__ */ (0, e.jsx)(he.Header, {
|
|
1014
|
+
title: "Filters",
|
|
1015
|
+
onClose: () => W(!1),
|
|
1016
|
+
actions: /* @__PURE__ */ (0, e.jsx)(Q, {
|
|
1017
|
+
variant: "invisible",
|
|
1018
|
+
size: "small",
|
|
1019
|
+
leadingVisual: d === "dialog" ? "square-half" : "open-center",
|
|
1020
|
+
onClick: () => C((m) => m === "dialog" ? "sidepanel" : "dialog"),
|
|
1021
|
+
"aria-label": d === "dialog" ? "Switch to side panel" : "Switch to dialog"
|
|
1022
|
+
})
|
|
1023
|
+
}),
|
|
1024
|
+
/* @__PURE__ */ (0, e.jsx)("div", {
|
|
1025
|
+
className: n["rst-dashboard-builder-filter-body"],
|
|
1026
|
+
children: (() => {
|
|
1027
|
+
const m = Object.keys(R);
|
|
1028
|
+
if (m.length === 0) return /* @__PURE__ */ (0, e.jsx)("div", {
|
|
1029
|
+
style: { padding: "var(--rst-space-default)" },
|
|
1030
|
+
children: "No data sources to filter."
|
|
1031
|
+
});
|
|
1032
|
+
const $ = F && m.includes(F) ? F : m[0], se = w?.[$] ?? Ye();
|
|
1033
|
+
return /* @__PURE__ */ (0, e.jsxs)(e.Fragment, { children: [/* @__PURE__ */ (0, e.jsx)("div", {
|
|
1034
|
+
className: n["rst-dashboard-builder-filter-tabs"],
|
|
1035
|
+
children: m.map((J) => /* @__PURE__ */ (0, e.jsx)(Q, {
|
|
1036
|
+
value: J,
|
|
1037
|
+
variant: J === $ ? "base" : "invisible",
|
|
1038
|
+
size: "small",
|
|
1039
|
+
onClick: () => U(J),
|
|
1040
|
+
children: J
|
|
1041
|
+
}, J))
|
|
1042
|
+
}), /* @__PURE__ */ (0, e.jsx)(Ge, {
|
|
1043
|
+
filters: se,
|
|
1044
|
+
onChange: (J) => S((Ie) => ({
|
|
1045
|
+
...Ie ?? {},
|
|
1046
|
+
[$]: J.filters.length === 0 ? null : J
|
|
1047
|
+
})),
|
|
1048
|
+
fieldOptions: R[$]
|
|
1049
|
+
})] });
|
|
1050
|
+
})()
|
|
1051
|
+
}),
|
|
1052
|
+
/* @__PURE__ */ (0, e.jsxs)(he.Footer, { children: [/* @__PURE__ */ (0, e.jsx)(Q, {
|
|
1053
|
+
variant: "invisible",
|
|
1054
|
+
size: "small",
|
|
1055
|
+
value: "Clear",
|
|
1056
|
+
onClick: () => S({})
|
|
1057
|
+
}), /* @__PURE__ */ (0, e.jsx)(Q, {
|
|
1058
|
+
variant: "primary",
|
|
1059
|
+
size: "small",
|
|
1060
|
+
value: "Apply",
|
|
1061
|
+
onClick: oe
|
|
1062
|
+
})] })
|
|
1063
|
+
]
|
|
1064
|
+
}),
|
|
1065
|
+
!z && /* @__PURE__ */ (0, e.jsx)(ke, {
|
|
1066
|
+
widget: t,
|
|
1067
|
+
dataSources: r,
|
|
1068
|
+
onUpdate: (m) => {
|
|
1069
|
+
t && P(t.id, m);
|
|
1070
|
+
},
|
|
1071
|
+
onRemove: () => {
|
|
1072
|
+
t && l(t.id);
|
|
1073
|
+
},
|
|
1074
|
+
onClose: () => T(null),
|
|
1075
|
+
onAddWidget: (m) => {
|
|
1076
|
+
const $ = Object.values(r)[0], se = De(6, 3, c.config.widgets);
|
|
1077
|
+
v(m, $?.id ?? "", se);
|
|
1078
|
+
},
|
|
1079
|
+
prebuiltSections: a,
|
|
1080
|
+
onAddPrebuiltSection: (m) => {
|
|
1081
|
+
I(m);
|
|
1082
|
+
}
|
|
1083
|
+
})
|
|
1084
|
+
]
|
|
1085
|
+
})
|
|
1086
|
+
})]
|
|
1087
|
+
})
|
|
1088
|
+
});
|
|
1089
|
+
};
|
|
1090
|
+
ur.displayName = "DashboardBuilder";
|
|
1091
|
+
var ue = {
|
|
1092
|
+
"rst-border-beam": "_rst-border-beam_4g5sg_1",
|
|
1093
|
+
"rst-border-beam-effect": "_rst-border-beam-effect_4g5sg_7",
|
|
1094
|
+
"rst-border-beam-ring": "_rst-border-beam-ring_4g5sg_15",
|
|
1095
|
+
"rst-border-beam-spin": "_rst-border-beam-spin_4g5sg_27",
|
|
1096
|
+
"rst-border-beam-travel": "_rst-border-beam-travel_4g5sg_1"
|
|
1097
|
+
};
|
|
1098
|
+
function br(r) {
|
|
1099
|
+
return [...r].filter((s) => s.color).map((s) => ({
|
|
1100
|
+
...s,
|
|
1101
|
+
percent: Math.min(100, Math.max(0, s.percent))
|
|
1102
|
+
})).sort((s, i) => s.percent - i.percent);
|
|
1103
|
+
}
|
|
1104
|
+
function hr(r, s, i, a) {
|
|
1105
|
+
const b = 360 / Math.max(1, a), h = 2 * (s + i);
|
|
1106
|
+
return h <= 0 || r <= 0 ? Math.min(90, b) : Math.min(r / h * 360, b);
|
|
1107
|
+
}
|
|
1108
|
+
function mr(r, s) {
|
|
1109
|
+
const i = Math.max(0, Math.min(s, 360)), a = br(r);
|
|
1110
|
+
return `conic-gradient(from 0deg, ${a.length ? a.map((b) => `${b.color} ${b.percent / 100 * i}deg`).join(", ") : "var(--rst-borderColor-focus) 0deg"}, transparent ${i}deg, transparent 360deg)`;
|
|
1111
|
+
}
|
|
1112
|
+
var pr = [
|
|
1113
|
+
{
|
|
1114
|
+
color: "transparent",
|
|
1115
|
+
percent: 0
|
|
1116
|
+
},
|
|
1117
|
+
{
|
|
1118
|
+
color: "var(--rst-borderColor-primary-default)",
|
|
1119
|
+
percent: 70
|
|
1120
|
+
},
|
|
1121
|
+
{
|
|
1122
|
+
color: "var(--rst-borderColor-focus)",
|
|
1123
|
+
percent: 100
|
|
1124
|
+
}
|
|
1125
|
+
], fr = ({ children: r, color: s = pr, count: i = 1, duration: a = 6, lineWidth: b = 1, outset: h = 0, inset: g = 0, size: j = 120, className: N, style: c, ..._ }) => {
|
|
1126
|
+
const p = ne(null), [v, I] = k({
|
|
1127
|
+
radius: "",
|
|
1128
|
+
width: 0,
|
|
1129
|
+
height: 0
|
|
1130
|
+
});
|
|
1131
|
+
te(() => {
|
|
1132
|
+
const D = p.current?.firstElementChild;
|
|
1133
|
+
if (!D || typeof ResizeObserver > "u") return;
|
|
1134
|
+
const o = new ResizeObserver(() => {
|
|
1135
|
+
I({
|
|
1136
|
+
radius: getComputedStyle(D).borderTopLeftRadius,
|
|
1137
|
+
width: D.clientWidth,
|
|
1138
|
+
height: D.clientHeight
|
|
1139
|
+
});
|
|
1140
|
+
});
|
|
1141
|
+
return o.observe(D), () => o.disconnect();
|
|
1142
|
+
}, []);
|
|
1143
|
+
const l = Math.max(1, Math.floor(i)), P = q(() => mr(s, hr(j, v.width, v.height, l)), [
|
|
1144
|
+
s,
|
|
1145
|
+
j,
|
|
1146
|
+
v.width,
|
|
1147
|
+
v.height,
|
|
1148
|
+
l
|
|
1149
|
+
]), L = 360 / l, T = Math.hypot(v.width + 2 * h, v.height + 2 * h), t = [ue["rst-border-beam"], N].filter(Boolean).join(" "), u = {
|
|
1150
|
+
"--rst-border-beam-gradient": P,
|
|
1151
|
+
"--rst-border-beam-duration": `${a}s`,
|
|
1152
|
+
"--rst-border-beam-line-width": `${b}px`,
|
|
1153
|
+
"--rst-border-beam-outset": `${h}px`,
|
|
1154
|
+
"--rst-border-beam-inset": `${g}px`,
|
|
1155
|
+
...T > 0 ? { "--rst-border-beam-diagonal": `${T}px` } : {},
|
|
1156
|
+
...v.radius ? { "--rst-border-beam-radius": v.radius } : {},
|
|
1157
|
+
...c
|
|
1158
|
+
};
|
|
1159
|
+
return /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
1160
|
+
ref: p,
|
|
1161
|
+
className: t,
|
|
1162
|
+
style: u,
|
|
1163
|
+
..._,
|
|
1164
|
+
children: [r, /* @__PURE__ */ (0, e.jsx)("span", {
|
|
1165
|
+
className: ue["rst-border-beam-effect"],
|
|
1166
|
+
"aria-hidden": "true",
|
|
1167
|
+
children: /* @__PURE__ */ (0, e.jsx)("span", {
|
|
1168
|
+
className: ue["rst-border-beam-ring"],
|
|
1169
|
+
children: Array.from({ length: l }, (D, o) => /* @__PURE__ */ (0, e.jsx)("span", {
|
|
1170
|
+
className: ue["rst-border-beam-spin"],
|
|
1171
|
+
style: { "--rst-border-beam-offset": `${o * L}deg` }
|
|
1172
|
+
}, o))
|
|
1173
|
+
})
|
|
1174
|
+
})]
|
|
1175
|
+
});
|
|
1176
|
+
};
|
|
1177
|
+
fr.displayName = "BorderBeam";
|
|
1178
|
+
function gr(r) {
|
|
1179
|
+
return r.filter((s) => s.type === "text").map((s) => s.text).join(" ").trim();
|
|
1180
|
+
}
|
|
1181
|
+
function _r(r) {
|
|
1182
|
+
return r.data ?? [];
|
|
1183
|
+
}
|
|
1184
|
+
function Re(r, s) {
|
|
1185
|
+
return r.events?.includes(s) ?? !1;
|
|
1186
|
+
}
|
|
1187
|
+
function vr({ block: r, onBlockEvent: s }) {
|
|
1188
|
+
const i = _r(r), a = r.props ?? {};
|
|
1189
|
+
if (r.component === "form") return /* @__PURE__ */ (0, e.jsx)(xr, {
|
|
1190
|
+
block: r,
|
|
1191
|
+
onBlockEvent: s
|
|
1192
|
+
});
|
|
1193
|
+
if (r.component === "chart") {
|
|
1194
|
+
const b = a.height ?? 16;
|
|
1195
|
+
return /* @__PURE__ */ (0, e.jsx)(Xe, {
|
|
1196
|
+
data: i,
|
|
1197
|
+
columns: r.columns,
|
|
1198
|
+
type: a.type ?? "bar",
|
|
1199
|
+
xAxisColumn: a.xAxisColumn,
|
|
1200
|
+
yAxisColumns: a.yAxisColumns,
|
|
1201
|
+
series: a.series,
|
|
1202
|
+
title: a.title,
|
|
1203
|
+
subtitle: a.subtitle,
|
|
1204
|
+
showLegend: a.showLegend,
|
|
1205
|
+
showGrid: a.showGrid,
|
|
1206
|
+
height: b
|
|
1207
|
+
});
|
|
1208
|
+
}
|
|
1209
|
+
return r.component === "kpi" ? /* @__PURE__ */ (0, e.jsx)(Fe, {
|
|
1210
|
+
data: i[0] ?? {},
|
|
1211
|
+
columns: r.columns,
|
|
1212
|
+
layout: We(a.layout)
|
|
1213
|
+
}) : r.component === "card-list" ? /* @__PURE__ */ (0, e.jsx)(Ue, {
|
|
1214
|
+
data: i,
|
|
1215
|
+
columns: r.columns,
|
|
1216
|
+
layout: Te(a.layout),
|
|
1217
|
+
onCardClick: Re(r, "action") ? (b) => s?.({
|
|
1218
|
+
blockId: r.id,
|
|
1219
|
+
component: "card-list",
|
|
1220
|
+
event: "action",
|
|
1221
|
+
handler: r.handler,
|
|
1222
|
+
values: b
|
|
1223
|
+
}) : void 0
|
|
1224
|
+
}) : /* @__PURE__ */ (0, e.jsx)(Ke, {
|
|
1225
|
+
data: i,
|
|
1226
|
+
columns: r.columns,
|
|
1227
|
+
enableSorting: a.enableSorting !== !1,
|
|
1228
|
+
enableSelection: a.enableSelection === !0,
|
|
1229
|
+
showGrid: a.showGrid ?? "horizontal",
|
|
1230
|
+
columnSizing: "fixed",
|
|
1231
|
+
enableVirtualization: a.enableVirtualization !== !1
|
|
1232
|
+
});
|
|
1233
|
+
}
|
|
1234
|
+
function xr({ block: r, onBlockEvent: s }) {
|
|
1235
|
+
const [i, a] = k(!1);
|
|
1236
|
+
return Re(r, "submit") ? /* @__PURE__ */ (0, e.jsx)(ge, {
|
|
1237
|
+
data: r.data ?? [{}],
|
|
1238
|
+
columns: r.columns,
|
|
1239
|
+
labelAlign: "top",
|
|
1240
|
+
onSubmit: async (b) => {
|
|
1241
|
+
a(!0);
|
|
1242
|
+
try {
|
|
1243
|
+
await s?.({
|
|
1244
|
+
blockId: r.id,
|
|
1245
|
+
component: "form",
|
|
1246
|
+
event: "submit",
|
|
1247
|
+
handler: r.handler,
|
|
1248
|
+
values: b
|
|
1249
|
+
});
|
|
1250
|
+
} finally {
|
|
1251
|
+
a(!1);
|
|
1252
|
+
}
|
|
1253
|
+
},
|
|
1254
|
+
actions: [{
|
|
1255
|
+
type: "submit",
|
|
1256
|
+
variant: "primary",
|
|
1257
|
+
value: "Submit",
|
|
1258
|
+
loading: i,
|
|
1259
|
+
disabled: i
|
|
1260
|
+
}, {
|
|
1261
|
+
type: "reset",
|
|
1262
|
+
variant: "invisible",
|
|
1263
|
+
value: "Reset",
|
|
1264
|
+
disabled: i
|
|
1265
|
+
}]
|
|
1266
|
+
}) : /* @__PURE__ */ (0, e.jsx)(ge, {
|
|
1267
|
+
data: r.data ?? [{}],
|
|
1268
|
+
columns: r.columns
|
|
1269
|
+
});
|
|
1270
|
+
}
|
|
1271
|
+
var V = {
|
|
1272
|
+
"rst-chat": "_rst-chat_12syz_1",
|
|
1273
|
+
"rst-chat-empty": "_rst-chat-empty_12syz_9",
|
|
1274
|
+
"rst-chat-messages": "_rst-chat-messages_12syz_19",
|
|
1275
|
+
"rst-chat-message": "_rst-chat-message_12syz_19",
|
|
1276
|
+
"rst-chat-message-user": "_rst-chat-message-user_12syz_33",
|
|
1277
|
+
"rst-chat-message-assistant": "_rst-chat-message-assistant_12syz_37",
|
|
1278
|
+
"rst-chat-bubble": "_rst-chat-bubble_12syz_41",
|
|
1279
|
+
"rst-chat-bubble-user": "_rst-chat-bubble-user_12syz_51",
|
|
1280
|
+
"rst-chat-bubble-assistant": "_rst-chat-bubble-assistant_12syz_56",
|
|
1281
|
+
"rst-chat-text": "_rst-chat-text_12syz_63",
|
|
1282
|
+
"rst-chat-block": "_rst-chat-block_12syz_68",
|
|
1283
|
+
"rst-chat-block-title": "_rst-chat-block-title_12syz_76",
|
|
1284
|
+
"rst-chat-processing": "_rst-chat-processing_12syz_80",
|
|
1285
|
+
"rst-chat-composer": "_rst-chat-composer_12syz_84"
|
|
1286
|
+
};
|
|
1287
|
+
function Dr({ messages: r, isProcessing: s = !1, inputValue: i, onInputChange: a, onSubmit: b, onKeyDown: h, onBlockEvent: g, emptyStateText: j = "Ask a question to get started.", inputPlaceholder: N = "Ask something...", className: c, renderBlock: _ }) {
|
|
1288
|
+
const p = ne(null);
|
|
1289
|
+
te(() => {
|
|
1290
|
+
const l = p.current;
|
|
1291
|
+
l && (l.scrollTop = l.scrollHeight);
|
|
1292
|
+
}, [r, s]);
|
|
1293
|
+
const v = s || i.trim().length === 0, I = (l, P) => l.type === "text" ? /* @__PURE__ */ (0, e.jsx)(ae, {
|
|
1294
|
+
variant: "body",
|
|
1295
|
+
className: V["rst-chat-text"],
|
|
1296
|
+
children: l.text
|
|
1297
|
+
}, P) : /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
1298
|
+
className: V["rst-chat-block"],
|
|
1299
|
+
children: [l.block.meta?.title && /* @__PURE__ */ (0, e.jsx)(ae, {
|
|
1300
|
+
variant: "label",
|
|
1301
|
+
className: V["rst-chat-block-title"],
|
|
1302
|
+
children: l.block.meta.title
|
|
1303
|
+
}), _ ? _(l.block) : /* @__PURE__ */ (0, e.jsx)(vr, {
|
|
1304
|
+
block: l.block,
|
|
1305
|
+
onBlockEvent: g
|
|
1306
|
+
})]
|
|
1307
|
+
}, l.block.id);
|
|
1308
|
+
return /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
1309
|
+
className: [V["rst-chat"], c].filter(Boolean).join(" "),
|
|
1310
|
+
children: [r.length === 0 ? /* @__PURE__ */ (0, e.jsx)("div", {
|
|
1311
|
+
className: V["rst-chat-empty"],
|
|
1312
|
+
children: /* @__PURE__ */ (0, e.jsx)(ae, {
|
|
1313
|
+
variant: "body",
|
|
1314
|
+
children: j
|
|
1315
|
+
})
|
|
1316
|
+
}) : /* @__PURE__ */ (0, e.jsxs)("div", {
|
|
1317
|
+
ref: p,
|
|
1318
|
+
className: V["rst-chat-messages"],
|
|
1319
|
+
role: "log",
|
|
1320
|
+
"aria-live": "polite",
|
|
1321
|
+
children: [r.map((l) => /* @__PURE__ */ (0, e.jsx)("article", {
|
|
1322
|
+
className: [V["rst-chat-message"], V[`rst-chat-message-${l.role}`]].join(" "),
|
|
1323
|
+
"aria-label": `${l.role === "user" ? "You" : "Assistant"}: ${gr(l.parts)}`,
|
|
1324
|
+
children: /* @__PURE__ */ (0, e.jsx)("div", {
|
|
1325
|
+
className: [V["rst-chat-bubble"], V[`rst-chat-bubble-${l.role}`]].join(" "),
|
|
1326
|
+
children: l.parts.map(I)
|
|
1327
|
+
})
|
|
1328
|
+
}, l.id)), s && /* @__PURE__ */ (0, e.jsx)("div", {
|
|
1329
|
+
className: V["rst-chat-processing"],
|
|
1330
|
+
children: /* @__PURE__ */ (0, e.jsx)(ae, {
|
|
1331
|
+
variant: "caption",
|
|
1332
|
+
children: "Working..."
|
|
1333
|
+
})
|
|
1334
|
+
})]
|
|
1335
|
+
}), /* @__PURE__ */ (0, e.jsxs)("form", {
|
|
1336
|
+
className: V["rst-chat-composer"],
|
|
1337
|
+
onSubmit: (l) => {
|
|
1338
|
+
l.preventDefault(), v || b();
|
|
1339
|
+
},
|
|
1340
|
+
children: [/* @__PURE__ */ (0, e.jsx)(Qe, {
|
|
1341
|
+
value: i,
|
|
1342
|
+
onChange: a,
|
|
1343
|
+
onKeyDown: h,
|
|
1344
|
+
placeholder: N,
|
|
1345
|
+
ariaLabel: "Message",
|
|
1346
|
+
rows: 1,
|
|
1347
|
+
disabled: s
|
|
1348
|
+
}), /* @__PURE__ */ (0, e.jsx)(Q, {
|
|
1349
|
+
type: "submit",
|
|
1350
|
+
variant: "primary",
|
|
1351
|
+
value: "Send",
|
|
1352
|
+
leadingVisual: "send",
|
|
1353
|
+
disabled: v
|
|
1354
|
+
})]
|
|
1355
|
+
})]
|
|
1356
|
+
});
|
|
1357
|
+
}
|
|
1358
|
+
export {
|
|
1359
|
+
fr as BorderBeam,
|
|
1360
|
+
Dr as ChatSurface,
|
|
1361
|
+
Mr as DASHBOARD_CONFIG_VERSION,
|
|
1362
|
+
ur as DashboardBuilder,
|
|
1363
|
+
Nr as PipContainer,
|
|
1364
|
+
Sr as usePip
|
|
1365
|
+
};
|