@carto/ps-react-ui 5.0.0-widgets.9 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/actions-CGJD6q0t.js +1318 -0
- package/dist/actions-CGJD6q0t.js.map +1 -0
- package/dist/actions-yPZwFxSZ.js +1004 -0
- package/dist/actions-yPZwFxSZ.js.map +1 -0
- package/dist/category-DGUDabsi.js +829 -0
- package/dist/category-DGUDabsi.js.map +1 -0
- package/dist/chart-config-B_fdIcD3.js +108 -0
- package/dist/chart-config-B_fdIcD3.js.map +1 -0
- package/dist/chat.js +1642 -0
- package/dist/chat.js.map +1 -0
- package/dist/cjs-CBrZjPCj.js +75 -0
- package/dist/cjs-CBrZjPCj.js.map +1 -0
- package/dist/components-FED-ArwH.js +4053 -0
- package/dist/components-FED-ArwH.js.map +1 -0
- package/dist/components.js +5 -1351
- package/dist/copy-button-TTlZONkX.js +34 -0
- package/dist/copy-button-TTlZONkX.js.map +1 -0
- package/dist/csv-modifiers-D6HGC24b.js +26 -0
- package/dist/csv-modifiers-D6HGC24b.js.map +1 -0
- package/dist/download-DdaK3qgC.js +232 -0
- package/dist/download-DdaK3qgC.js.map +1 -0
- package/dist/echart-BkaV3V5G.js +133 -0
- package/dist/echart-BkaV3V5G.js.map +1 -0
- package/dist/echart-DeBgdOtX.js +250 -0
- package/dist/echart-DeBgdOtX.js.map +1 -0
- package/dist/formatter-wVO81tYk.js +6 -0
- package/dist/formatter-wVO81tYk.js.map +1 -0
- package/dist/formula-YfZmmuYX.js +190 -0
- package/dist/formula-YfZmmuYX.js.map +1 -0
- package/dist/formula-noJzQwKo.js +285 -0
- package/dist/formula-noJzQwKo.js.map +1 -0
- package/dist/hooks-zf5gKZYq.js +22 -0
- package/dist/hooks-zf5gKZYq.js.map +1 -0
- package/dist/legend/stores.js +2 -0
- package/dist/legend.js +2284 -0
- package/dist/legend.js.map +1 -0
- package/dist/markdown-2dfL6Cmb.js +165 -0
- package/dist/markdown-2dfL6Cmb.js.map +1 -0
- package/dist/markdown-content-BWUqwx9F.js +8776 -0
- package/dist/markdown-content-BWUqwx9F.js.map +1 -0
- package/dist/range-BCMAl5xf.js +277 -0
- package/dist/range-BCMAl5xf.js.map +1 -0
- package/dist/rolldown-runtime-B0aSnxlc.js +20 -0
- package/dist/row-CvVGBuy_.js +35 -0
- package/dist/row-CvVGBuy_.js.map +1 -0
- package/dist/shared-resize-observer-BEiP2rQt.js +157 -0
- package/dist/shared-resize-observer-BEiP2rQt.js.map +1 -0
- package/dist/smart-tooltip-CwGHCqab.js +34 -0
- package/dist/smart-tooltip-CwGHCqab.js.map +1 -0
- package/dist/spread-Ccpg9fi0.js +149 -0
- package/dist/spread-Ccpg9fi0.js.map +1 -0
- package/dist/stores-mad-9yFn.js +369 -0
- package/dist/stores-mad-9yFn.js.map +1 -0
- package/dist/stores-tiFePP0A.js +243 -0
- package/dist/stores-tiFePP0A.js.map +1 -0
- package/dist/styles-Y-qGBELO.js +13 -0
- package/dist/styles-Y-qGBELO.js.map +1 -0
- package/dist/table-Bx9Uj3U0.js +440 -0
- package/dist/table-Bx9Uj3U0.js.map +1 -0
- package/dist/tooltip-DJUGNZxY.js +23 -0
- package/dist/tooltip-DJUGNZxY.js.map +1 -0
- package/dist/types/chat/bubbles/chat-agent-message-markdown.d.ts +12 -0
- package/dist/types/chat/bubbles/chat-agent-message.d.ts +9 -0
- package/dist/types/chat/bubbles/chat-error-message.d.ts +2 -0
- package/dist/types/chat/bubbles/chat-suggestion-button.d.ts +2 -0
- package/dist/types/chat/bubbles/chat-user-message.d.ts +2 -0
- package/dist/types/chat/bubbles/index.d.ts +5 -0
- package/dist/types/chat/bubbles/styles.d.ts +88 -0
- package/dist/types/chat/const.d.ts +4 -0
- package/dist/types/chat/containers/chat-content.d.ts +2 -0
- package/dist/types/chat/containers/chat-footer.d.ts +2 -0
- package/dist/types/chat/containers/chat-header.d.ts +2 -0
- package/dist/types/chat/containers/chat-starter.d.ts +2 -0
- package/dist/types/chat/containers/index.d.ts +4 -0
- package/dist/types/chat/containers/styles.d.ts +160 -0
- package/dist/types/chat/feedback/chat-actions-container.d.ts +3 -0
- package/dist/types/chat/feedback/chat-loader.d.ts +2 -0
- package/dist/types/chat/feedback/chat-rating-action.d.ts +2 -0
- package/dist/types/chat/feedback/chat-thinking.d.ts +2 -0
- package/dist/types/chat/feedback/chat-tool-code-area.d.ts +2 -0
- package/dist/types/chat/feedback/chat-tool-full-view-dialog.d.ts +2 -0
- package/dist/types/chat/feedback/chat-tool-group.d.ts +2 -0
- package/dist/types/chat/feedback/chat-tool-trace.d.ts +3 -0
- package/dist/types/chat/feedback/get-tool-label.d.ts +2 -0
- package/dist/types/chat/feedback/index.d.ts +8 -0
- package/dist/types/chat/feedback/styles.d.ts +212 -0
- package/dist/types/chat/index.d.ts +21 -0
- package/dist/types/chat/types.d.ts +214 -0
- package/dist/types/chat/use-typewriter.d.ts +32 -0
- package/dist/types/components/basemaps/basemaps.d.ts +21 -1
- package/dist/types/components/basemaps/const.d.ts +1 -1
- package/dist/types/components/basemaps/group-wrapper.d.ts +1 -1
- package/dist/types/components/basemaps/group.d.ts +2 -2
- package/dist/types/components/basemaps/header.d.ts +2 -2
- package/dist/types/components/common-types.d.ts +49 -0
- package/dist/types/components/copy-button/copy-button.d.ts +2 -0
- package/dist/types/components/copy-button/types.d.ts +6 -0
- package/dist/types/components/geolocation-controls/geolocation-controls.d.ts +12 -1
- package/dist/types/components/index.d.ts +37 -20
- package/dist/types/components/lasso-tool/chip.d.ts +2 -2
- package/dist/types/components/lasso-tool/const.d.ts +2 -2
- package/dist/types/components/lasso-tool/edit-confirm-toolbar.d.ts +26 -0
- package/dist/types/components/lasso-tool/geometry-toolbar.d.ts +49 -0
- package/dist/types/components/lasso-tool/icons.d.ts +22 -5
- package/dist/types/components/lasso-tool/lasso-tool-inline.d.ts +36 -3
- package/dist/types/components/lasso-tool/lasso-tool.d.ts +34 -9
- package/dist/types/components/lasso-tool/layer-filters.d.ts +10 -0
- package/dist/types/components/lasso-tool/message.d.ts +7 -0
- package/dist/types/components/lasso-tool/options-sections.d.ts +28 -0
- package/dist/types/components/lasso-tool/styles.d.ts +24 -2
- package/dist/types/components/lasso-tool/toolbar/actions/accept-action.d.ts +13 -0
- package/dist/types/components/lasso-tool/toolbar/actions/action-menu.d.ts +28 -0
- package/dist/types/components/lasso-tool/toolbar/actions/cancel-action.d.ts +13 -0
- package/dist/types/components/lasso-tool/toolbar/actions/color-action.d.ts +44 -0
- package/dist/types/components/lasso-tool/toolbar/actions/delete-action.d.ts +11 -0
- package/dist/types/components/lasso-tool/toolbar/actions/duplicate-action.d.ts +11 -0
- package/dist/types/components/lasso-tool/toolbar/actions/edit-geometry-action.d.ts +13 -0
- package/dist/types/components/lasso-tool/toolbar/actions/edit-properties-action.d.ts +60 -0
- package/dist/types/components/lasso-tool/toolbar/actions/fill-action.d.ts +26 -0
- package/dist/types/components/lasso-tool/toolbar/actions/intersect-action.d.ts +14 -0
- package/dist/types/components/lasso-tool/toolbar/actions/label-action.d.ts +69 -0
- package/dist/types/components/lasso-tool/toolbar/actions/lock-action.d.ts +17 -0
- package/dist/types/components/lasso-tool/toolbar/actions/redo-action.d.ts +14 -0
- package/dist/types/components/lasso-tool/toolbar/actions/split-action.d.ts +14 -0
- package/dist/types/components/lasso-tool/toolbar/actions/stroke-action.d.ts +27 -0
- package/dist/types/components/lasso-tool/toolbar/actions/subtract-action.d.ts +14 -0
- package/dist/types/components/lasso-tool/toolbar/actions/toggle-type-action.d.ts +19 -0
- package/dist/types/components/lasso-tool/toolbar/actions/undo-action.d.ts +14 -0
- package/dist/types/components/lasso-tool/toolbar/actions/union-action.d.ts +14 -0
- package/dist/types/components/lasso-tool/toolbar/button.d.ts +24 -0
- package/dist/types/components/lasso-tool/toolbar/connected.d.ts +55 -0
- package/dist/types/components/lasso-tool/toolbar/context.d.ts +31 -0
- package/dist/types/components/lasso-tool/toolbar/index.d.ts +41 -0
- package/dist/types/components/lasso-tool/toolbar/styles.d.ts +26 -0
- package/dist/types/components/lasso-tool/toolbar/toolbar.d.ts +30 -0
- package/dist/types/components/lasso-tool/tools-context.d.ts +12 -0
- package/dist/types/components/lasso-tool/types.d.ts +284 -10
- package/dist/types/components/lasso-tool/undo-redo.d.ts +25 -0
- package/dist/types/components/list-data/list-data-skeleton.d.ts +1 -1
- package/dist/types/components/list-data/list-data.d.ts +17 -1
- package/dist/types/components/measurement-tools/const.d.ts +2 -2
- package/dist/types/components/measurement-tools/icons.d.ts +3 -3
- package/dist/types/components/measurement-tools/measurement-tools.d.ts +21 -1
- package/dist/types/components/measurement-tools/styles.d.ts +14 -4
- package/dist/types/components/measurement-tools/types.d.ts +1 -1
- package/dist/types/components/no-data-alert/no-data-alert.d.ts +1 -1
- package/dist/types/components/responsive-drawer/responsive-drawer.d.ts +38 -6
- package/dist/types/components/smart-tooltip/smart-tooltip.d.ts +18 -1
- package/dist/types/components/tooltip/tooltip.d.ts +14 -1
- package/dist/types/components/types.d.ts +1 -1
- package/dist/types/components/zoom-controls/zoom-controls.d.ts +17 -1
- package/dist/types/hooks/index.d.ts +1 -2
- package/dist/types/hooks/use-widget-ref.d.ts +10 -6
- package/dist/types/legend/components/a11y.d.ts +6 -0
- package/dist/types/legend/components/contexts.d.ts +38 -0
- package/dist/types/legend/components/icons.d.ts +12 -0
- package/dist/types/legend/components/index.d.ts +26 -0
- package/dist/types/legend/components/legend-actions/legend-actions.d.ts +25 -0
- package/dist/types/legend/components/legend-actions/styles.d.ts +7 -0
- package/dist/types/legend/components/legend-category/legend-category-ui.d.ts +13 -0
- package/dist/types/legend/components/legend-category/styles.d.ts +52 -0
- package/dist/types/legend/components/legend-config-select/legend-config-select.d.ts +14 -0
- package/dist/types/legend/components/legend-config-select/styles.d.ts +44 -0
- package/dist/types/legend/components/legend-group/legend-group.d.ts +12 -0
- package/dist/types/legend/components/legend-group/styles.d.ts +129 -0
- package/dist/types/legend/components/legend-group-menu/legend-group-menu-items.d.ts +28 -0
- package/dist/types/legend/components/legend-group-menu/legend-group-menu.d.ts +11 -0
- package/dist/types/legend/components/legend-icon/legend-icon-ui.d.ts +10 -0
- package/dist/types/legend/components/legend-icon/styles.d.ts +52 -0
- package/dist/types/legend/components/legend-item/legend-item-ui.d.ts +14 -0
- package/dist/types/legend/components/legend-item/legend-item.d.ts +10 -0
- package/dist/types/{widgets/root/style.d.ts → legend/components/legend-item/styles.d.ts} +2 -3
- package/dist/types/legend/components/legend-opacity/legend-opacity.d.ts +22 -0
- package/dist/types/legend/components/legend-opacity/styles.d.ts +28 -0
- package/dist/types/legend/components/legend-overflow-menu/legend-overflow-menu.d.ts +12 -0
- package/dist/types/legend/components/legend-panel-menu/legend-panel-menu.d.ts +11 -0
- package/dist/types/legend/components/legend-proportion/legend-proportion-ui.d.ts +16 -0
- package/dist/types/legend/components/legend-proportion/styles.d.ts +37 -0
- package/dist/types/legend/components/legend-ramp/legend-ramp-ui.d.ts +20 -0
- package/dist/types/legend/components/legend-ramp/styles.d.ts +53 -0
- package/dist/types/legend/components/legend-row/legend-row.d.ts +16 -0
- package/dist/types/legend/components/legend-row/styles.d.ts +149 -0
- package/dist/types/legend/components/legend-row-menu/legend-row-menu-items.d.ts +12 -0
- package/dist/types/legend/components/legend-row-menu/legend-row-menu.d.ts +12 -0
- package/dist/types/legend/components/legend-row-menu/legend-zoom-to.d.ts +10 -0
- package/dist/types/legend/components/legend-sortable/contexts.d.ts +7 -0
- package/dist/types/legend/components/legend-sortable/legend-sortable.d.ts +11 -0
- package/dist/types/legend/components/legend-sortable/sortable-entity.d.ts +27 -0
- package/dist/types/legend/components/legend-sortable/sortable-ids.d.ts +6 -0
- package/dist/types/legend/components/legend-sortable/styles.d.ts +55 -0
- package/dist/types/legend/components/legend-swatch/legend-swatch.d.ts +26 -0
- package/dist/types/legend/components/legend-visibility-toggle/legend-visibility-toggle.d.ts +35 -0
- package/dist/types/legend/components/legend-visible-layers/legend-visible-layers.d.ts +7 -0
- package/dist/types/legend/components/legend-visible-layers/styles.d.ts +48 -0
- package/dist/types/legend/components/run-async-menu-action.d.ts +7 -0
- package/dist/types/legend/index.d.ts +135 -0
- package/dist/types/legend/provider/index.d.ts +6 -0
- package/dist/types/legend/provider/labels.d.ts +48 -0
- package/dist/types/legend/provider/legend-config-context.d.ts +7 -0
- package/dist/types/legend/provider/legend-provider.d.ts +38 -0
- package/dist/types/legend/stores/index.d.ts +5 -0
- package/dist/types/legend/stores/legend-context.d.ts +4 -0
- package/dist/types/legend/stores/legend-store-registry.d.ts +39 -0
- package/dist/types/legend/stores/selectors.d.ts +64 -0
- package/dist/types/legend/stores/types.d.ts +294 -0
- package/dist/types/widgets/actions/brush-toggle/brush-overlay.d.ts +24 -0
- package/dist/types/widgets/actions/brush-toggle/brush-toggle.d.ts +29 -0
- package/dist/types/widgets/actions/brush-toggle/hit-test.d.ts +19 -0
- package/dist/types/widgets/actions/brush-toggle/style.d.ts +21 -0
- package/dist/types/widgets/actions/brush-toggle/types.d.ts +73 -0
- package/dist/types/widgets/actions/change-column/change-column-icon.d.ts +1 -1
- package/dist/types/widgets/actions/change-column/change-column.d.ts +6 -2
- package/dist/types/widgets/actions/change-column/sortable-column-item.d.ts +2 -2
- package/dist/types/widgets/actions/download/download.d.ts +13 -2
- package/dist/types/widgets/actions/download/exports.d.ts +16 -1
- package/dist/types/widgets/actions/download/types.d.ts +1 -1
- package/dist/types/widgets/actions/fullscreen/fullscreen.d.ts +15 -2
- package/dist/types/widgets/actions/fullscreen/types.d.ts +3 -2
- package/dist/types/widgets/actions/index.d.ts +20 -18
- package/dist/types/widgets/actions/lock-selection/lock-selection.d.ts +2 -2
- package/dist/types/widgets/actions/lock-selection/types.d.ts +10 -10
- package/dist/types/widgets/actions/relative-data/relative-data.d.ts +10 -4
- package/dist/types/widgets/actions/relative-data/types.d.ts +3 -1
- package/dist/types/widgets/actions/relative-data/utils.d.ts +1 -1
- package/dist/types/widgets/actions/searcher/searcher-toggle.d.ts +2 -2
- package/dist/types/widgets/actions/searcher/searcher.d.ts +2 -2
- package/dist/types/widgets/actions/searcher/types.d.ts +2 -2
- package/dist/types/widgets/actions/stack-toggle/grouped-bar-chart-icon.d.ts +1 -1
- package/dist/types/widgets/actions/stack-toggle/stack-toggle.d.ts +5 -4
- package/dist/types/widgets/actions/stack-toggle/types.d.ts +1 -1
- package/dist/types/widgets/actions/zoom-toggle/types.d.ts +1 -1
- package/dist/types/widgets/actions/zoom-toggle/zoom-toggle.d.ts +10 -2
- package/dist/types/widgets/bar/config.d.ts +8 -4
- package/dist/types/widgets/bar/index.d.ts +3 -3
- package/dist/types/widgets/bar/skeleton.d.ts +1 -1
- package/dist/types/widgets/bar/types.d.ts +3 -3
- package/dist/types/widgets/category/category-ui.d.ts +5 -2
- package/dist/types/widgets/category/components/category-bar.d.ts +4 -1
- package/dist/types/widgets/category/components/category-legend.d.ts +5 -2
- package/dist/types/widgets/category/components/category-row-multi.d.ts +6 -2
- package/dist/types/widgets/category/components/category-row-other.d.ts +4 -1
- package/dist/types/widgets/category/components/category-row-single.d.ts +6 -2
- package/dist/types/widgets/category/config.d.ts +16 -12
- package/dist/types/widgets/category/index.d.ts +14 -6
- package/dist/types/widgets/category/skeleton.d.ts +1 -1
- package/dist/types/widgets/category/style.d.ts +1 -1
- package/dist/types/widgets/category/types.d.ts +4 -3
- package/dist/types/widgets/echart/echart-ui.d.ts +9 -2
- package/dist/types/widgets/echart/echart.d.ts +8 -2
- package/dist/types/widgets/echart/index.d.ts +5 -5
- package/dist/types/widgets/echart/options.d.ts +8 -1
- package/dist/types/widgets/echart/shared-resize-observer.d.ts +12 -0
- package/dist/types/widgets/echart/types.d.ts +7 -2
- package/dist/types/widgets/echart/utils.d.ts +57 -9
- package/dist/types/widgets/error/error.d.ts +12 -2
- package/dist/types/widgets/error/index.d.ts +2 -2
- package/dist/types/widgets/error/types.d.ts +9 -1
- package/dist/types/widgets/formula/components/item.d.ts +5 -2
- package/dist/types/widgets/formula/components/prefix.d.ts +5 -2
- package/dist/types/widgets/formula/components/row.d.ts +5 -2
- package/dist/types/widgets/formula/components/series.d.ts +5 -2
- package/dist/types/widgets/formula/components/suffix.d.ts +5 -2
- package/dist/types/widgets/formula/components/value.d.ts +5 -2
- package/dist/types/widgets/formula/config.d.ts +13 -2
- package/dist/types/widgets/formula/formula-ui.d.ts +5 -2
- package/dist/types/widgets/formula/index.d.ts +11 -11
- package/dist/types/widgets/formula/serializer.d.ts +1 -1
- package/dist/types/widgets/formula/skeleton.d.ts +1 -1
- package/dist/types/widgets/formula/types.d.ts +3 -3
- package/dist/types/widgets/histogram/config.d.ts +20 -4
- package/dist/types/widgets/histogram/index.d.ts +4 -3
- package/dist/types/widgets/histogram/skeleton.d.ts +1 -1
- package/dist/types/widgets/histogram/types.d.ts +8 -5
- package/dist/types/widgets/loader/index.d.ts +3 -0
- package/dist/types/widgets/loader/loader.d.ts +24 -0
- package/dist/types/widgets/loader/types.d.ts +9 -0
- package/dist/types/widgets/loader/utils.d.ts +35 -0
- package/dist/types/widgets/markdown/config.d.ts +12 -2
- package/dist/types/widgets/markdown/index.d.ts +5 -5
- package/dist/types/widgets/markdown/markdown-ui.d.ts +9 -2
- package/dist/types/widgets/markdown/markdown.d.ts +5 -2
- package/dist/types/widgets/markdown/skeleton.d.ts +1 -1
- package/dist/types/widgets/markdown/types.d.ts +3 -3
- package/dist/types/widgets/no-data/index.d.ts +2 -2
- package/dist/types/widgets/no-data/no-data.d.ts +5 -4
- package/dist/types/widgets/no-data/types.d.ts +6 -2
- package/dist/types/widgets/note/index.d.ts +2 -2
- package/dist/types/widgets/note/note.d.ts +12 -2
- package/dist/types/widgets/note/types.d.ts +1 -1
- package/dist/types/widgets/pie/config.d.ts +8 -4
- package/dist/types/widgets/pie/index.d.ts +3 -3
- package/dist/types/widgets/pie/skeleton.d.ts +1 -1
- package/dist/types/widgets/pie/types.d.ts +3 -3
- package/dist/types/widgets/range/components/range-item.d.ts +5 -2
- package/dist/types/widgets/range/config.d.ts +6 -5
- package/dist/types/widgets/range/index.d.ts +6 -6
- package/dist/types/widgets/range/range-ui.d.ts +5 -2
- package/dist/types/widgets/range/serializer.d.ts +1 -1
- package/dist/types/widgets/range/skeleton.d.ts +1 -1
- package/dist/types/widgets/range/types.d.ts +3 -3
- package/dist/types/widgets/scatterplot/config.d.ts +8 -4
- package/dist/types/widgets/scatterplot/index.d.ts +3 -3
- package/dist/types/widgets/scatterplot/skeleton.d.ts +1 -1
- package/dist/types/widgets/scatterplot/types.d.ts +3 -3
- package/dist/types/widgets/selection-summary/index.d.ts +2 -2
- package/dist/types/widgets/selection-summary/selection-summary.d.ts +13 -2
- package/dist/types/widgets/skeleton-loader/index.d.ts +2 -2
- package/dist/types/widgets/skeleton-loader/skeleton-loader.d.ts +12 -2
- package/dist/types/widgets/skeleton-loader/types.d.ts +1 -1
- package/dist/types/widgets/spread/components/max-value.d.ts +5 -2
- package/dist/types/widgets/spread/components/min-value.d.ts +5 -2
- package/dist/types/widgets/spread/components/separator.d.ts +5 -2
- package/dist/types/widgets/spread/config.d.ts +14 -8
- package/dist/types/widgets/spread/index.d.ts +9 -9
- package/dist/types/widgets/spread/skeleton.d.ts +1 -1
- package/dist/types/widgets/spread/spread-ui.d.ts +5 -2
- package/dist/types/widgets/spread/types.d.ts +4 -4
- package/dist/types/widgets/stores/index.d.ts +3 -2
- package/dist/types/widgets/stores/types.d.ts +31 -10
- package/dist/types/widgets/stores/use-widget-selector.d.ts +35 -0
- package/dist/types/widgets/stores/widget-store.d.ts +48 -27
- package/dist/types/widgets/subheader/index.d.ts +2 -2
- package/dist/types/widgets/subheader/subheader.d.ts +13 -2
- package/dist/types/widgets/table/components/cell-header.d.ts +2 -2
- package/dist/types/widgets/table/components/cell.d.ts +4 -2
- package/dist/types/widgets/table/components/pagination-actions.d.ts +2 -2
- package/dist/types/widgets/table/components/pagination.d.ts +2 -2
- package/dist/types/widgets/table/components/row.d.ts +2 -2
- package/dist/types/widgets/table/config.d.ts +10 -6
- package/dist/types/widgets/table/hooks/use-pagination.d.ts +12 -4
- package/dist/types/widgets/table/hooks/use-selection.d.ts +12 -3
- package/dist/types/widgets/table/hooks/use-sort.d.ts +12 -4
- package/dist/types/widgets/table/index.d.ts +17 -13
- package/dist/types/widgets/table/serializer.d.ts +1 -1
- package/dist/types/widgets/table/skeleton.d.ts +1 -1
- package/dist/types/widgets/table/table-ui.d.ts +8 -8
- package/dist/types/widgets/table/types.d.ts +5 -5
- package/dist/types/widgets/timeseries/config.d.ts +8 -4
- package/dist/types/widgets/timeseries/index.d.ts +3 -3
- package/dist/types/widgets/timeseries/skeleton.d.ts +1 -1
- package/dist/types/widgets/timeseries/types.d.ts +3 -3
- package/dist/types/widgets/toolbar-actions/index.d.ts +2 -2
- package/dist/types/widgets/toolbar-actions/toolbar-actions.d.ts +13 -4
- package/dist/types/widgets/toolbar-actions/types.d.ts +10 -3
- package/dist/types/widgets/{_shared → utils}/chart-config/config-factory.d.ts +1 -1
- package/dist/types/widgets/utils/chart-config/download-config.d.ts +3 -0
- package/dist/types/widgets/utils/chart-config/index.d.ts +9 -0
- package/dist/types/widgets/utils/chart-config/option-builders.d.ts +142 -0
- package/dist/types/widgets/utils/formatter.d.ts +2 -0
- package/dist/types/widgets/utils/index.d.ts +7 -0
- package/dist/types/widgets/utils/skeleton/index.d.ts +4 -0
- package/dist/types/widgets/wrapper/components/actions.d.ts +5 -2
- package/dist/types/widgets/wrapper/components/options.d.ts +5 -2
- package/dist/types/widgets/wrapper/components/title.d.ts +5 -2
- package/dist/types/widgets/wrapper/index.d.ts +6 -6
- package/dist/types/widgets/wrapper/types.d.ts +1 -1
- package/dist/types/widgets/wrapper/wrapper-ui.d.ts +16 -2
- package/dist/types/widgets/wrapper/wrapper.d.ts +16 -2
- package/dist/types/widgets-v2/actions/brush-toggle/brush-toggle.d.ts +56 -0
- package/dist/types/widgets-v2/actions/brush-toggle/index.d.ts +3 -0
- package/dist/types/widgets-v2/actions/brush-toggle/labels.d.ts +5 -0
- package/dist/types/widgets-v2/actions/brush-toggle/style.d.ts +12 -0
- package/dist/types/widgets-v2/actions/brush-toggle/transforms.d.ts +11 -0
- package/dist/types/widgets-v2/actions/change-column/change-column-icon.d.ts +2 -0
- package/dist/types/widgets-v2/actions/change-column/change-column.d.ts +29 -0
- package/dist/types/widgets-v2/actions/change-column/index.d.ts +3 -0
- package/dist/types/widgets-v2/actions/change-column/labels.d.ts +6 -0
- package/dist/types/widgets-v2/actions/change-column/sortable-column-item.d.ts +14 -0
- package/dist/types/widgets-v2/actions/change-column/style.d.ts +59 -0
- package/dist/types/widgets-v2/actions/change-column/types.d.ts +10 -0
- package/dist/types/widgets-v2/actions/download/constants.d.ts +12 -0
- package/dist/types/widgets-v2/actions/download/csv-item.d.ts +38 -0
- package/dist/types/widgets-v2/actions/download/download.d.ts +18 -0
- package/dist/types/widgets-v2/actions/download/exports.d.ts +37 -0
- package/dist/types/widgets-v2/actions/download/icons.d.ts +18 -0
- package/dist/types/widgets-v2/actions/download/index.d.ts +8 -0
- package/dist/types/widgets-v2/actions/download/labels.d.ts +11 -0
- package/dist/types/widgets-v2/actions/download/png-item.d.ts +24 -0
- package/dist/types/widgets-v2/actions/download/style.d.ts +1 -0
- package/dist/types/widgets-v2/actions/download/types.d.ts +35 -0
- package/dist/types/widgets-v2/actions/fullscreen/fullscreen.d.ts +59 -0
- package/dist/types/widgets-v2/actions/fullscreen/index.d.ts +3 -0
- package/dist/types/widgets-v2/actions/fullscreen/labels.d.ts +5 -0
- package/dist/types/widgets-v2/actions/fullscreen/style.d.ts +48 -0
- package/dist/types/widgets-v2/actions/fullscreen/types.d.ts +14 -0
- package/dist/types/widgets-v2/actions/index.d.ts +10 -0
- package/dist/types/widgets-v2/actions/lock-selection/index.d.ts +3 -0
- package/dist/types/widgets-v2/actions/lock-selection/labels.d.ts +6 -0
- package/dist/types/widgets-v2/actions/lock-selection/lock-selection.d.ts +57 -0
- package/dist/types/widgets-v2/actions/lock-selection/style.d.ts +12 -0
- package/dist/types/widgets-v2/actions/lock-selection/transforms.d.ts +6 -0
- package/dist/types/widgets-v2/actions/relative-data/index.d.ts +3 -0
- package/dist/types/widgets-v2/actions/relative-data/labels.d.ts +5 -0
- package/dist/types/widgets-v2/actions/relative-data/relative-data.d.ts +39 -0
- package/dist/types/widgets-v2/actions/relative-data/style.d.ts +12 -0
- package/dist/types/widgets-v2/actions/relative-data/transforms.d.ts +30 -0
- package/dist/types/widgets-v2/actions/searcher/filter.d.ts +6 -0
- package/dist/types/widgets-v2/actions/searcher/index.d.ts +4 -0
- package/dist/types/widgets-v2/actions/searcher/labels.d.ts +7 -0
- package/dist/types/widgets-v2/actions/searcher/searcher-toggle.d.ts +23 -0
- package/dist/types/widgets-v2/actions/searcher/searcher.d.ts +11 -0
- package/dist/types/widgets-v2/actions/searcher/style.d.ts +16 -0
- package/dist/types/widgets-v2/actions/show-all/index.d.ts +2 -0
- package/dist/types/widgets-v2/actions/show-all/labels.d.ts +5 -0
- package/dist/types/widgets-v2/actions/show-all/show-all.d.ts +33 -0
- package/dist/types/widgets-v2/actions/show-all/style.d.ts +8 -0
- package/dist/types/widgets-v2/actions/stack-toggle/index.d.ts +3 -0
- package/dist/types/widgets-v2/actions/stack-toggle/labels.d.ts +5 -0
- package/dist/types/widgets-v2/actions/stack-toggle/stack-toggle.d.ts +10 -0
- package/dist/types/widgets-v2/actions/stack-toggle/style.d.ts +12 -0
- package/dist/types/widgets-v2/actions/stack-toggle/transforms.d.ts +13 -0
- package/dist/types/widgets-v2/actions/zoom-toggle/index.d.ts +3 -0
- package/dist/types/widgets-v2/actions/zoom-toggle/labels.d.ts +5 -0
- package/dist/types/widgets-v2/actions/zoom-toggle/style.d.ts +12 -0
- package/dist/types/widgets-v2/actions/zoom-toggle/transforms.d.ts +51 -0
- package/dist/types/widgets-v2/actions/zoom-toggle/zoom-toggle.d.ts +35 -0
- package/dist/types/widgets-v2/bar/download.d.ts +24 -0
- package/dist/types/widgets-v2/bar/index.d.ts +4 -0
- package/dist/types/widgets-v2/bar/options.d.ts +43 -0
- package/dist/types/widgets-v2/bar/skeleton.d.ts +6 -0
- package/dist/types/widgets-v2/bar/types.d.ts +46 -0
- package/dist/types/widgets-v2/category/category-ui.d.ts +88 -0
- package/dist/types/widgets-v2/category/category.d.ts +55 -0
- package/dist/types/widgets-v2/category/components/category-bar-stacked.d.ts +28 -0
- package/dist/types/widgets-v2/category/components/category-bar.d.ts +23 -0
- package/dist/types/widgets-v2/category/components/category-legend.d.ts +34 -0
- package/dist/types/widgets-v2/category/components/category-row-multi.d.ts +31 -0
- package/dist/types/widgets-v2/category/components/category-row-other.d.ts +26 -0
- package/dist/types/widgets-v2/category/components/category-row-single.d.ts +28 -0
- package/dist/types/widgets-v2/category/components/category-row-stacked.d.ts +43 -0
- package/dist/types/widgets-v2/category/download.d.ts +16 -0
- package/dist/types/widgets-v2/category/index.d.ts +10 -0
- package/dist/types/widgets-v2/category/skeleton.d.ts +11 -0
- package/dist/types/widgets-v2/category/style.d.ts +193 -0
- package/dist/types/widgets-v2/category/types.d.ts +55 -0
- package/dist/types/widgets-v2/echart/echart-ui.d.ts +44 -0
- package/dist/types/widgets-v2/echart/echart.d.ts +75 -0
- package/dist/types/widgets-v2/echart/edge-label-clamp.d.ts +57 -0
- package/dist/types/widgets-v2/echart/index.d.ts +4 -0
- package/dist/types/widgets-v2/echart/shared-resize-observer.d.ts +5 -0
- package/dist/types/widgets-v2/echart/style.d.ts +6 -0
- package/dist/types/widgets-v2/echart/use-chart-selection.d.ts +57 -0
- package/dist/types/widgets-v2/formula/delta.d.ts +22 -0
- package/dist/types/widgets-v2/formula/download.d.ts +20 -0
- package/dist/types/widgets-v2/formula/formula-ui.d.ts +20 -0
- package/dist/types/widgets-v2/formula/formula.d.ts +8 -0
- package/dist/types/widgets-v2/formula/index.d.ts +11 -0
- package/dist/types/widgets-v2/formula/note.d.ts +11 -0
- package/dist/types/widgets-v2/formula/prefix.d.ts +12 -0
- package/dist/types/widgets-v2/formula/series.d.ts +16 -0
- package/dist/types/widgets-v2/formula/skeleton.d.ts +4 -0
- package/dist/types/widgets-v2/formula/style.d.ts +29 -0
- package/dist/types/widgets-v2/formula/suffix.d.ts +12 -0
- package/dist/types/widgets-v2/formula/types.d.ts +43 -0
- package/dist/types/widgets-v2/formula/value.d.ts +14 -0
- package/dist/types/widgets-v2/histogram/download.d.ts +17 -0
- package/dist/types/widgets-v2/histogram/index.d.ts +5 -0
- package/dist/types/widgets-v2/histogram/options.d.ts +42 -0
- package/dist/types/widgets-v2/histogram/skeleton.d.ts +9 -0
- package/dist/types/widgets-v2/histogram/transforms.d.ts +28 -0
- package/dist/types/widgets-v2/histogram/types.d.ts +60 -0
- package/dist/types/widgets-v2/index.d.ts +109 -0
- package/dist/types/widgets-v2/markdown/download.d.ts +16 -0
- package/dist/types/widgets-v2/markdown/index.d.ts +6 -0
- package/dist/types/widgets-v2/markdown/markdown-content.d.ts +40 -0
- package/dist/types/widgets-v2/markdown/markdown-ui.d.ts +12 -0
- package/dist/types/widgets-v2/markdown/markdown.d.ts +6 -0
- package/dist/types/widgets-v2/markdown/skeleton.d.ts +4 -0
- package/dist/types/widgets-v2/markdown/style.d.ts +61 -0
- package/dist/types/widgets-v2/markdown/types.d.ts +4 -0
- package/dist/types/widgets-v2/note/labels.d.ts +5 -0
- package/dist/types/widgets-v2/note/style.d.ts +26 -0
- package/dist/types/widgets-v2/note/widget-note.d.ts +46 -0
- package/dist/types/widgets-v2/pie/download.d.ts +17 -0
- package/dist/types/widgets-v2/pie/index.d.ts +4 -0
- package/dist/types/widgets-v2/pie/options.d.ts +35 -0
- package/dist/types/widgets-v2/pie/skeleton.d.ts +13 -0
- package/dist/types/widgets-v2/pie/types.d.ts +57 -0
- package/dist/types/widgets-v2/provider/widget-provider.d.ts +32 -0
- package/dist/types/widgets-v2/range/index.d.ts +4 -0
- package/dist/types/widgets-v2/range/range-ui.d.ts +27 -0
- package/dist/types/widgets-v2/range/range.d.ts +24 -0
- package/dist/types/widgets-v2/range/skeleton.d.ts +9 -0
- package/dist/types/widgets-v2/range/style.d.ts +40 -0
- package/dist/types/widgets-v2/range/types.d.ts +37 -0
- package/dist/types/widgets-v2/scatterplot/download.d.ts +16 -0
- package/dist/types/widgets-v2/scatterplot/index.d.ts +5 -0
- package/dist/types/widgets-v2/scatterplot/options.d.ts +42 -0
- package/dist/types/widgets-v2/scatterplot/skeleton.d.ts +12 -0
- package/dist/types/widgets-v2/scatterplot/transforms.d.ts +26 -0
- package/dist/types/widgets-v2/scatterplot/types.d.ts +54 -0
- package/dist/types/widgets-v2/selection-summary/labels.d.ts +11 -0
- package/dist/types/widgets-v2/selection-summary/selection-summary.d.ts +29 -0
- package/dist/types/widgets-v2/selection-summary/style.d.ts +38 -0
- package/dist/types/widgets-v2/spread/band.d.ts +37 -0
- package/dist/types/widgets-v2/spread/download.d.ts +15 -0
- package/dist/types/widgets-v2/spread/index.d.ts +7 -0
- package/dist/types/widgets-v2/spread/separator.d.ts +7 -0
- package/dist/types/widgets-v2/spread/skeleton.d.ts +9 -0
- package/dist/types/widgets-v2/spread/spread-ui.d.ts +18 -0
- package/dist/types/widgets-v2/spread/spread.d.ts +5 -0
- package/dist/types/widgets-v2/spread/types.d.ts +25 -0
- package/dist/types/widgets-v2/state/labels.d.ts +7 -0
- package/dist/types/widgets-v2/state/style.d.ts +19 -0
- package/dist/types/widgets-v2/state/widget-state.d.ts +19 -0
- package/dist/types/widgets-v2/stores/index.d.ts +8 -0
- package/dist/types/widgets-v2/stores/pipeline-middleware.d.ts +5 -0
- package/dist/types/widgets-v2/stores/transforms.d.ts +4 -0
- package/dist/types/widgets-v2/stores/types.d.ts +55 -0
- package/dist/types/widgets-v2/stores/use-echart-instance.d.ts +15 -0
- package/dist/types/widgets-v2/stores/use-transform-enabled.d.ts +17 -0
- package/dist/types/widgets-v2/stores/use-transform.d.ts +12 -0
- package/dist/types/widgets-v2/stores/widget-context.d.ts +2 -0
- package/dist/types/widgets-v2/stores/widget-store-registry.d.ts +74 -0
- package/dist/types/widgets-v2/subheader/style.d.ts +10 -0
- package/dist/types/widgets-v2/subheader/subheader.d.ts +11 -0
- package/dist/types/widgets-v2/table/download.d.ts +18 -0
- package/dist/types/widgets-v2/table/helpers.d.ts +32 -0
- package/dist/types/widgets-v2/table/index.d.ts +8 -0
- package/dist/types/widgets-v2/table/labels.d.ts +22 -0
- package/dist/types/widgets-v2/table/skeleton.d.ts +22 -0
- package/dist/types/widgets-v2/table/style.d.ts +40 -0
- package/dist/types/widgets-v2/table/table-ui.d.ts +44 -0
- package/dist/types/widgets-v2/table/table.d.ts +50 -0
- package/dist/types/widgets-v2/table/transforms.d.ts +15 -0
- package/dist/types/widgets-v2/table/types.d.ts +48 -0
- package/dist/types/widgets-v2/timeseries/download.d.ts +17 -0
- package/dist/types/widgets-v2/timeseries/index.d.ts +5 -0
- package/dist/types/widgets-v2/timeseries/options.d.ts +39 -0
- package/dist/types/widgets-v2/timeseries/skeleton.d.ts +8 -0
- package/dist/types/widgets-v2/timeseries/transforms.d.ts +10 -0
- package/dist/types/widgets-v2/timeseries/types.d.ts +60 -0
- package/dist/types/widgets-v2/toolbox/labels.d.ts +5 -0
- package/dist/types/widgets-v2/toolbox/style.d.ts +30 -0
- package/dist/types/widgets-v2/toolbox/toolbox.d.ts +49 -0
- package/dist/types/widgets-v2/types.d.ts +25 -0
- package/dist/types/widgets-v2/utils/data-zoom-layout.d.ts +11 -0
- package/dist/types/widgets-v2/utils/index.d.ts +3 -0
- package/dist/types/widgets-v2/utils/merge-options.d.ts +12 -0
- package/dist/types/widgets-v2/utils/resolve-theme-color.d.ts +18 -0
- package/dist/types/widgets-v2/wrapper/index.d.ts +4 -0
- package/dist/types/widgets-v2/wrapper/labels.d.ts +6 -0
- package/dist/types/widgets-v2/wrapper/style.d.ts +103 -0
- package/dist/types/widgets-v2/wrapper/widget-actions.d.ts +22 -0
- package/dist/types/widgets-v2/wrapper/widget-content.d.ts +12 -0
- package/dist/types/widgets-v2/wrapper/widget-wrapper.d.ts +56 -0
- package/dist/use-widget-selector-VSPhfhNm.js +12 -0
- package/dist/use-widget-selector-VSPhfhNm.js.map +1 -0
- package/dist/utils-Dr6gf3vD.js +58 -0
- package/dist/utils-Dr6gf3vD.js.map +1 -0
- package/dist/widget-store-BFPKYm4R.js +187 -0
- package/dist/widget-store-BFPKYm4R.js.map +1 -0
- package/dist/widgets/actions.js +2 -837
- package/dist/widgets/bar.js +183 -186
- package/dist/widgets/bar.js.map +1 -1
- package/dist/widgets/category.js +438 -455
- package/dist/widgets/category.js.map +1 -1
- package/dist/widgets/echart.js +3 -123
- package/dist/widgets/error.js +30 -5
- package/dist/widgets/error.js.map +1 -1
- package/dist/widgets/formula.js +3 -125
- package/dist/widgets/histogram.js +185 -167
- package/dist/widgets/histogram.js.map +1 -1
- package/dist/widgets/loader.js +66 -0
- package/dist/widgets/loader.js.map +1 -0
- package/dist/widgets/markdown.js +142 -121
- package/dist/widgets/markdown.js.map +1 -1
- package/dist/widgets/no-data.js +55 -5
- package/dist/widgets/no-data.js.map +1 -1
- package/dist/widgets/note.js +126 -4
- package/dist/widgets/note.js.map +1 -1
- package/dist/widgets/pie.js +244 -208
- package/dist/widgets/pie.js.map +1 -1
- package/dist/widgets/range.js +226 -210
- package/dist/widgets/range.js.map +1 -1
- package/dist/widgets/scatterplot.js +219 -216
- package/dist/widgets/scatterplot.js.map +1 -1
- package/dist/widgets/selection-summary.js +39 -38
- package/dist/widgets/selection-summary.js.map +1 -1
- package/dist/widgets/skeleton-loader.js +23 -23
- package/dist/widgets/skeleton-loader.js.map +1 -1
- package/dist/widgets/spread.js +150 -159
- package/dist/widgets/spread.js.map +1 -1
- package/dist/widgets/stores.js +3 -5
- package/dist/widgets/subheader.js +49 -50
- package/dist/widgets/subheader.js.map +1 -1
- package/dist/widgets/table.js +573 -653
- package/dist/widgets/table.js.map +1 -1
- package/dist/widgets/timeseries.js +175 -170
- package/dist/widgets/timeseries.js.map +1 -1
- package/dist/widgets/toolbar-actions.js +144 -6105
- package/dist/widgets/toolbar-actions.js.map +1 -1
- package/dist/widgets/utils.js +18 -0
- package/dist/widgets/utils.js.map +1 -0
- package/dist/widgets/wrapper.js +265 -287
- package/dist/widgets/wrapper.js.map +1 -1
- package/dist/widgets-v2/actions.js +4 -0
- package/dist/widgets-v2/bar.js +260 -0
- package/dist/widgets-v2/bar.js.map +1 -0
- package/dist/widgets-v2/category.js +2 -0
- package/dist/widgets-v2/echart.js +2 -0
- package/dist/widgets-v2/formula.js +2 -0
- package/dist/widgets-v2/histogram.js +297 -0
- package/dist/widgets-v2/histogram.js.map +1 -0
- package/dist/widgets-v2/markdown.js +3 -0
- package/dist/widgets-v2/pie.js +374 -0
- package/dist/widgets-v2/pie.js.map +1 -0
- package/dist/widgets-v2/range.js +2 -0
- package/dist/widgets-v2/scatterplot.js +330 -0
- package/dist/widgets-v2/scatterplot.js.map +1 -0
- package/dist/widgets-v2/spread.js +2 -0
- package/dist/widgets-v2/stores.js +2 -0
- package/dist/widgets-v2/table.js +2 -0
- package/dist/widgets-v2/timeseries.js +294 -0
- package/dist/widgets-v2/timeseries.js.map +1 -0
- package/dist/widgets-v2/utils.js +2 -0
- package/dist/widgets-v2.js +964 -0
- package/dist/widgets-v2.js.map +1 -0
- package/dist/zoom-toggle-IsF8BnAp.js +163 -0
- package/dist/zoom-toggle-IsF8BnAp.js.map +1 -0
- package/package.json +109 -17
- package/src/chat/bubbles/chat-agent-message-markdown.test.tsx +38 -0
- package/src/chat/bubbles/chat-agent-message-markdown.tsx +34 -0
- package/src/chat/bubbles/chat-agent-message.test.tsx +42 -0
- package/src/chat/bubbles/chat-agent-message.tsx +31 -0
- package/src/chat/bubbles/chat-error-message.test.tsx +40 -0
- package/src/chat/bubbles/chat-error-message.tsx +47 -0
- package/src/chat/bubbles/chat-suggestion-button.test.tsx +24 -0
- package/src/chat/bubbles/chat-suggestion-button.tsx +27 -0
- package/src/chat/bubbles/chat-user-message.test.tsx +27 -0
- package/src/chat/bubbles/chat-user-message.tsx +27 -0
- package/src/chat/bubbles/index.ts +5 -0
- package/src/chat/bubbles/styles.ts +171 -0
- package/src/chat/const.ts +4 -0
- package/src/chat/containers/chat-content.test.tsx +269 -0
- package/src/chat/containers/chat-content.tsx +145 -0
- package/src/chat/containers/chat-footer.test.tsx +93 -0
- package/src/chat/containers/chat-footer.tsx +166 -0
- package/src/chat/containers/chat-header.test.tsx +28 -0
- package/src/chat/containers/chat-header.tsx +29 -0
- package/src/chat/containers/chat-starter.test.tsx +32 -0
- package/src/chat/containers/chat-starter.tsx +75 -0
- package/src/chat/containers/index.ts +4 -0
- package/src/chat/containers/styles.ts +187 -0
- package/src/chat/feedback/chat-actions-container.test.tsx +64 -0
- package/src/chat/feedback/chat-actions-container.tsx +10 -0
- package/src/chat/feedback/chat-loader.test.tsx +10 -0
- package/src/chat/feedback/chat-loader.tsx +31 -0
- package/src/chat/feedback/chat-rating-action.tsx +43 -0
- package/src/chat/feedback/chat-thinking.test.tsx +15 -0
- package/src/chat/feedback/chat-thinking.tsx +23 -0
- package/src/chat/feedback/chat-tool-code-area.test.tsx +23 -0
- package/src/chat/feedback/chat-tool-code-area.tsx +71 -0
- package/src/chat/feedback/chat-tool-full-view-dialog.test.tsx +39 -0
- package/src/chat/feedback/chat-tool-full-view-dialog.tsx +121 -0
- package/src/chat/feedback/chat-tool-group.test.tsx +84 -0
- package/src/chat/feedback/chat-tool-group.tsx +156 -0
- package/src/chat/feedback/chat-tool-trace.test.tsx +81 -0
- package/src/chat/feedback/chat-tool-trace.tsx +192 -0
- package/src/chat/feedback/get-tool-label.test.tsx +91 -0
- package/src/chat/feedback/get-tool-label.ts +13 -0
- package/src/chat/feedback/index.ts +8 -0
- package/src/chat/feedback/styles.ts +239 -0
- package/src/chat/index.ts +62 -0
- package/src/chat/types.ts +247 -0
- package/src/chat/use-typewriter.test.tsx +38 -0
- package/src/chat/use-typewriter.ts +90 -0
- package/src/components/basemaps/basemaps.test.tsx +196 -0
- package/src/components/basemaps/basemaps.tsx +150 -0
- package/src/components/basemaps/const.ts +13 -0
- package/src/components/basemaps/group-wrapper.test.tsx +38 -0
- package/src/components/basemaps/group-wrapper.tsx +28 -0
- package/src/components/basemaps/group.test.tsx +52 -0
- package/src/components/basemaps/group.tsx +42 -0
- package/src/components/basemaps/header.test.tsx +54 -0
- package/src/components/basemaps/header.tsx +36 -0
- package/src/components/basemaps/styles.ts +76 -0
- package/src/components/basemaps/types.ts +30 -0
- package/src/components/common-types.ts +1 -0
- package/src/components/copy-button/copy-button.test.tsx +41 -0
- package/src/components/copy-button/copy-button.tsx +31 -0
- package/src/components/copy-button/types.ts +10 -0
- package/src/components/geolocation-controls/const.ts +6 -0
- package/src/components/geolocation-controls/geolocation-controls.test.tsx +148 -0
- package/src/components/geolocation-controls/geolocation-controls.tsx +126 -0
- package/src/components/geolocation-controls/types.ts +17 -0
- package/src/components/index.ts +163 -0
- package/src/components/lasso-tool/chip.test.tsx +257 -0
- package/src/components/lasso-tool/chip.tsx +66 -0
- package/src/components/lasso-tool/const.tsx +94 -0
- package/src/components/lasso-tool/edit-confirm-toolbar.test.tsx +67 -0
- package/src/components/lasso-tool/edit-confirm-toolbar.tsx +48 -0
- package/src/components/lasso-tool/geometry-toolbar.test.tsx +804 -0
- package/src/components/lasso-tool/geometry-toolbar.tsx +158 -0
- package/src/components/lasso-tool/icons.tsx +193 -0
- package/src/components/lasso-tool/lasso-tool-inline.test.tsx +759 -0
- package/src/components/lasso-tool/lasso-tool-inline.tsx +508 -0
- package/src/components/lasso-tool/lasso-tool.test.tsx +700 -0
- package/src/components/lasso-tool/lasso-tool.tsx +673 -0
- package/src/components/lasso-tool/layer-filters.test.tsx +103 -0
- package/src/components/lasso-tool/layer-filters.tsx +242 -0
- package/src/components/lasso-tool/message.tsx +36 -0
- package/src/components/lasso-tool/options-sections.test.tsx +101 -0
- package/src/components/lasso-tool/options-sections.tsx +104 -0
- package/src/components/lasso-tool/styles.test.ts +26 -0
- package/src/components/lasso-tool/styles.ts +190 -0
- package/src/components/lasso-tool/toolbar/actions/accept-action.tsx +34 -0
- package/src/components/lasso-tool/toolbar/actions/action-menu.tsx +103 -0
- package/src/components/lasso-tool/toolbar/actions/cancel-action.tsx +34 -0
- package/src/components/lasso-tool/toolbar/actions/color-action.tsx +201 -0
- package/src/components/lasso-tool/toolbar/actions/delete-action.tsx +31 -0
- package/src/components/lasso-tool/toolbar/actions/duplicate-action.tsx +30 -0
- package/src/components/lasso-tool/toolbar/actions/edit-geometry-action.tsx +44 -0
- package/src/components/lasso-tool/toolbar/actions/edit-properties-action.tsx +487 -0
- package/src/components/lasso-tool/toolbar/actions/fill-action.tsx +55 -0
- package/src/components/lasso-tool/toolbar/actions/intersect-action.tsx +33 -0
- package/src/components/lasso-tool/toolbar/actions/label-action.tsx +292 -0
- package/src/components/lasso-tool/toolbar/actions/lock-action.tsx +40 -0
- package/src/components/lasso-tool/toolbar/actions/redo-action.tsx +35 -0
- package/src/components/lasso-tool/toolbar/actions/split-action.tsx +33 -0
- package/src/components/lasso-tool/toolbar/actions/stroke-action.tsx +57 -0
- package/src/components/lasso-tool/toolbar/actions/style-actions.test.tsx +212 -0
- package/src/components/lasso-tool/toolbar/actions/subtract-action.tsx +33 -0
- package/src/components/lasso-tool/toolbar/actions/toggle-type-action.tsx +50 -0
- package/src/components/lasso-tool/toolbar/actions/undo-action.tsx +35 -0
- package/src/components/lasso-tool/toolbar/actions/union-action.tsx +40 -0
- package/src/components/lasso-tool/toolbar/button.tsx +62 -0
- package/src/components/lasso-tool/toolbar/connected.tsx +383 -0
- package/src/components/lasso-tool/toolbar/context.tsx +65 -0
- package/src/components/lasso-tool/toolbar/index.ts +70 -0
- package/src/components/lasso-tool/toolbar/styles.ts +42 -0
- package/src/components/lasso-tool/toolbar/toolbar.test.tsx +77 -0
- package/src/components/lasso-tool/toolbar/toolbar.tsx +50 -0
- package/src/components/lasso-tool/tools-context.tsx +47 -0
- package/src/components/lasso-tool/types.ts +384 -0
- package/src/components/lasso-tool/undo-redo.test.tsx +162 -0
- package/src/components/lasso-tool/undo-redo.tsx +55 -0
- package/src/components/list-data/list-data-skeleton.test.tsx +10 -0
- package/src/components/list-data/list-data-skeleton.tsx +40 -0
- package/src/components/list-data/list-data.test.tsx +167 -0
- package/src/components/list-data/list-data.tsx +124 -0
- package/src/components/list-data/styles.ts +37 -0
- package/src/components/list-data/types.ts +25 -0
- package/src/components/measurement-tools/const.tsx +108 -0
- package/src/components/measurement-tools/icons.tsx +54 -0
- package/src/components/measurement-tools/measurement-tools.test.tsx +165 -0
- package/src/components/measurement-tools/measurement-tools.tsx +467 -0
- package/src/components/measurement-tools/styles.ts +92 -0
- package/src/components/measurement-tools/types.ts +77 -0
- package/src/components/no-data-alert/no-data-alert.test.tsx +69 -0
- package/src/components/no-data-alert/no-data-alert.tsx +59 -0
- package/src/components/responsive-drawer/responsive-drawer.test.tsx +415 -0
- package/src/components/responsive-drawer/responsive-drawer.tsx +219 -0
- package/src/components/smart-tooltip/smart-tooltip.test.tsx +168 -0
- package/src/components/smart-tooltip/smart-tooltip.tsx +74 -0
- package/src/components/tooltip/tooltip.test.tsx +86 -0
- package/src/components/tooltip/tooltip.tsx +43 -0
- package/src/components/types.ts +1 -0
- package/src/components/zoom-controls/styles.ts +27 -0
- package/src/components/zoom-controls/types.ts +19 -0
- package/src/components/zoom-controls/zoom-controls.test.tsx +101 -0
- package/src/components/zoom-controls/zoom-controls.tsx +130 -0
- package/src/hooks/index.ts +1 -0
- package/src/hooks/use-skeleton.test.tsx +32 -0
- package/src/hooks/use-skeleton.ts +19 -0
- package/src/hooks/use-widget-ref.ts +34 -0
- package/src/legend/components/a11y.ts +14 -0
- package/src/legend/components/contexts.ts +57 -0
- package/src/legend/components/icons.tsx +22 -0
- package/src/legend/components/index.ts +38 -0
- package/src/legend/components/legend-actions/legend-actions.tsx +58 -0
- package/src/legend/components/legend-actions/styles.ts +9 -0
- package/src/legend/components/legend-category/legend-category-ui.tsx +91 -0
- package/src/legend/components/legend-category/styles.ts +61 -0
- package/src/legend/components/legend-config-select/legend-config-select.tsx +96 -0
- package/src/legend/components/legend-config-select/styles.ts +48 -0
- package/src/legend/components/legend-group/legend-group.test.tsx +297 -0
- package/src/legend/components/legend-group/legend-group.tsx +126 -0
- package/src/legend/components/legend-group/styles.ts +184 -0
- package/src/legend/components/legend-group-menu/legend-group-menu-items.tsx +132 -0
- package/src/legend/components/legend-group-menu/legend-group-menu.tsx +25 -0
- package/src/legend/components/legend-icon/legend-icon-ui.tsx +56 -0
- package/src/legend/components/legend-icon/styles.ts +56 -0
- package/src/legend/components/legend-item/legend-item-ui.test.tsx +362 -0
- package/src/legend/components/legend-item/legend-item-ui.tsx +43 -0
- package/src/legend/components/legend-item/legend-item.tsx +34 -0
- package/src/legend/components/legend-item/styles.ts +11 -0
- package/src/legend/components/legend-opacity/legend-opacity.tsx +152 -0
- package/src/legend/components/legend-opacity/styles.ts +33 -0
- package/src/legend/components/legend-overflow-menu/legend-overflow-menu.tsx +84 -0
- package/src/legend/components/legend-panel-menu/legend-panel-menu.tsx +23 -0
- package/src/legend/components/legend-proportion/legend-proportion-ui.tsx +122 -0
- package/src/legend/components/legend-proportion/styles.ts +43 -0
- package/src/legend/components/legend-ramp/legend-ramp-ui.tsx +160 -0
- package/src/legend/components/legend-ramp/styles.ts +62 -0
- package/src/legend/components/legend-row/legend-row.test.tsx +736 -0
- package/src/legend/components/legend-row/legend-row.tsx +170 -0
- package/src/legend/components/legend-row/styles.ts +219 -0
- package/src/legend/components/legend-row-menu/legend-row-menu-items.tsx +57 -0
- package/src/legend/components/legend-row-menu/legend-row-menu.tsx +30 -0
- package/src/legend/components/legend-row-menu/legend-zoom-to.tsx +43 -0
- package/src/legend/components/legend-sortable/contexts.ts +12 -0
- package/src/legend/components/legend-sortable/legend-sortable.test.tsx +144 -0
- package/src/legend/components/legend-sortable/legend-sortable.tsx +195 -0
- package/src/legend/components/legend-sortable/sortable-entity.tsx +91 -0
- package/src/legend/components/legend-sortable/sortable-ids.ts +17 -0
- package/src/legend/components/legend-sortable/styles.ts +65 -0
- package/src/legend/components/legend-swatch/legend-swatch.test.tsx +109 -0
- package/src/legend/components/legend-swatch/legend-swatch.tsx +237 -0
- package/src/legend/components/legend-visibility-toggle/legend-visibility-toggle.tsx +133 -0
- package/src/legend/components/legend-visible-layers/legend-visible-layers.test.tsx +86 -0
- package/src/legend/components/legend-visible-layers/legend-visible-layers.tsx +135 -0
- package/src/legend/components/legend-visible-layers/styles.ts +60 -0
- package/src/legend/components/run-async-menu-action.ts +20 -0
- package/src/legend/index.ts +176 -0
- package/src/legend/provider/index.ts +6 -0
- package/src/legend/provider/labels.ts +101 -0
- package/src/legend/provider/legend-config-context.ts +15 -0
- package/src/legend/provider/legend-provider.tsx +102 -0
- package/src/legend/stores/index.ts +50 -0
- package/src/legend/stores/legend-context.ts +17 -0
- package/src/legend/stores/legend-store-registry.ts +745 -0
- package/src/legend/stores/legend-store.test.ts +701 -0
- package/src/legend/stores/selectors.ts +127 -0
- package/src/legend/stores/types.ts +359 -0
- package/src/widgets/README.md +277 -0
- package/src/widgets/actions/brush-toggle/brush-overlay.test.tsx +465 -0
- package/src/widgets/actions/brush-toggle/brush-overlay.tsx +408 -0
- package/src/widgets/actions/brush-toggle/brush-toggle.test.tsx +208 -0
- package/src/widgets/actions/brush-toggle/brush-toggle.tsx +133 -0
- package/src/widgets/actions/brush-toggle/hit-test.test.ts +65 -0
- package/src/widgets/actions/brush-toggle/hit-test.ts +45 -0
- package/src/widgets/actions/brush-toggle/style.ts +46 -0
- package/src/widgets/actions/brush-toggle/types.ts +78 -0
- package/src/widgets/actions/change-column/change-column-dnd.test.tsx +193 -0
- package/src/widgets/actions/change-column/change-column-icon.tsx +10 -0
- package/src/widgets/actions/change-column/change-column.test.tsx +290 -0
- package/src/widgets/actions/change-column/change-column.tsx +218 -0
- package/src/widgets/actions/change-column/sortable-column-item.test.tsx +124 -0
- package/src/widgets/actions/change-column/sortable-column-item.tsx +51 -0
- package/src/widgets/actions/change-column/types.ts +20 -0
- package/src/widgets/actions/download/download.test.tsx +326 -0
- package/src/widgets/actions/download/download.tsx +132 -0
- package/src/widgets/actions/download/exports.test.tsx +288 -0
- package/src/widgets/actions/download/exports.tsx +118 -0
- package/src/widgets/actions/download/types.ts +21 -0
- package/src/widgets/actions/fullscreen/fullscreen.test.tsx +269 -0
- package/src/widgets/actions/fullscreen/fullscreen.tsx +98 -0
- package/src/widgets/actions/fullscreen/styles.ts +17 -0
- package/src/widgets/actions/fullscreen/types.ts +32 -0
- package/src/widgets/actions/index.ts +73 -0
- package/src/widgets/actions/lock-selection/lock-selection.test.tsx +198 -0
- package/src/widgets/actions/lock-selection/lock-selection.tsx +128 -0
- package/src/widgets/actions/lock-selection/types.ts +43 -0
- package/src/widgets/actions/relative-data/relative-data.test.tsx +542 -0
- package/src/widgets/actions/relative-data/relative-data.tsx +188 -0
- package/src/widgets/actions/relative-data/types.ts +33 -0
- package/src/widgets/actions/relative-data/utils.test.ts +223 -0
- package/src/widgets/actions/relative-data/utils.ts +58 -0
- package/src/widgets/actions/searcher/searcher-toggle.test.tsx +354 -0
- package/src/widgets/actions/searcher/searcher-toggle.tsx +72 -0
- package/src/widgets/actions/searcher/searcher.tsx +196 -0
- package/src/widgets/actions/searcher/types.ts +72 -0
- package/src/widgets/actions/shared/styles.ts +12 -0
- package/src/widgets/actions/stack-toggle/grouped-bar-chart-icon.tsx +14 -0
- package/src/widgets/actions/stack-toggle/stack-toggle.test.tsx +414 -0
- package/src/widgets/actions/stack-toggle/stack-toggle.tsx +129 -0
- package/src/widgets/actions/stack-toggle/types.ts +29 -0
- package/src/widgets/actions/zoom-toggle/style.ts +14 -0
- package/src/widgets/actions/zoom-toggle/types.ts +44 -0
- package/src/widgets/actions/zoom-toggle/zoom-toggle.test.tsx +322 -0
- package/src/widgets/actions/zoom-toggle/zoom-toggle.tsx +218 -0
- package/src/widgets/bar/config.ts +140 -0
- package/src/widgets/bar/index.ts +9 -0
- package/src/widgets/bar/skeleton.tsx +60 -0
- package/src/widgets/bar/style.ts +33 -0
- package/src/widgets/bar/types.ts +16 -0
- package/src/widgets/category/category-ui.test.tsx +399 -0
- package/src/widgets/category/category-ui.tsx +166 -0
- package/src/widgets/category/components/category-bar.tsx +31 -0
- package/src/widgets/category/components/category-legend.tsx +33 -0
- package/src/widgets/category/components/category-row-multi.tsx +57 -0
- package/src/widgets/category/components/category-row-other.tsx +26 -0
- package/src/widgets/category/components/category-row-single.tsx +54 -0
- package/src/widgets/category/components/category-rows.test.tsx +213 -0
- package/src/widgets/category/config.ts +86 -0
- package/src/widgets/category/index.ts +29 -0
- package/src/widgets/category/skeleton.tsx +24 -0
- package/src/widgets/category/style.ts +134 -0
- package/src/widgets/category/types.ts +41 -0
- package/src/widgets/echart/const.ts +1 -0
- package/src/widgets/echart/echart-ui.test.tsx +526 -0
- package/src/widgets/echart/echart-ui.tsx +78 -0
- package/src/widgets/echart/echart.test.tsx +546 -0
- package/src/widgets/echart/echart.tsx +66 -0
- package/src/widgets/echart/index.ts +16 -0
- package/src/widgets/echart/options.ts +57 -0
- package/src/widgets/echart/shared-resize-observer.ts +45 -0
- package/src/widgets/echart/types.ts +45 -0
- package/src/widgets/echart/utils.test.ts +277 -0
- package/src/widgets/echart/utils.ts +244 -0
- package/src/widgets/error/error.test.tsx +331 -0
- package/src/widgets/error/error.tsx +51 -0
- package/src/widgets/error/index.ts +2 -0
- package/src/widgets/error/types.ts +24 -0
- package/src/widgets/formula/components/item.test.tsx +249 -0
- package/src/widgets/formula/components/item.tsx +21 -0
- package/src/widgets/formula/components/prefix.test.tsx +341 -0
- package/src/widgets/formula/components/prefix.tsx +19 -0
- package/src/widgets/formula/components/row.test.tsx +364 -0
- package/src/widgets/formula/components/row.tsx +24 -0
- package/src/widgets/formula/components/series.tsx +35 -0
- package/src/widgets/formula/components/suffix.test.tsx +383 -0
- package/src/widgets/formula/components/suffix.tsx +29 -0
- package/src/widgets/formula/components/value.test.tsx +329 -0
- package/src/widgets/formula/components/value.tsx +24 -0
- package/src/widgets/formula/config.test.ts +37 -0
- package/src/widgets/formula/config.ts +38 -0
- package/src/widgets/formula/formula-ui.test.tsx +399 -0
- package/src/widgets/formula/formula-ui.tsx +30 -0
- package/src/widgets/formula/index.ts +24 -0
- package/src/widgets/formula/serializer.test.tsx +144 -0
- package/src/widgets/formula/serializer.ts +28 -0
- package/src/widgets/formula/skeleton.tsx +10 -0
- package/src/widgets/formula/style.ts +23 -0
- package/src/widgets/formula/types.ts +50 -0
- package/src/widgets/histogram/config.ts +230 -0
- package/src/widgets/histogram/index.ts +13 -0
- package/src/widgets/histogram/skeleton.tsx +52 -0
- package/src/widgets/histogram/style.ts +8 -0
- package/src/widgets/histogram/types.ts +23 -0
- package/src/widgets/loader/index.ts +4 -0
- package/src/widgets/loader/loader.tsx +92 -0
- package/src/widgets/loader/types.ts +13 -0
- package/src/widgets/loader/utils.test.ts +112 -0
- package/src/widgets/loader/utils.ts +57 -0
- package/src/widgets/markdown/config.ts +28 -0
- package/src/widgets/markdown/index.ts +14 -0
- package/src/widgets/markdown/markdown-ui.test.tsx +341 -0
- package/src/widgets/markdown/markdown-ui.tsx +59 -0
- package/src/widgets/markdown/markdown.tsx +20 -0
- package/src/widgets/markdown/skeleton.tsx +12 -0
- package/src/widgets/markdown/style.ts +28 -0
- package/src/widgets/markdown/types.ts +28 -0
- package/src/widgets/no-data/index.ts +2 -0
- package/src/widgets/no-data/no-data.test.tsx +497 -0
- package/src/widgets/no-data/no-data.tsx +112 -0
- package/src/widgets/no-data/style.ts +18 -0
- package/src/widgets/no-data/types.ts +76 -0
- package/src/widgets/note/index.ts +2 -0
- package/src/widgets/note/note.test.tsx +391 -0
- package/src/widgets/note/note.tsx +124 -0
- package/src/widgets/note/style.ts +29 -0
- package/src/widgets/note/types.ts +9 -0
- package/src/widgets/pie/config.ts +245 -0
- package/src/widgets/pie/index.ts +8 -0
- package/src/widgets/pie/skeleton.tsx +70 -0
- package/src/widgets/pie/style.ts +8 -0
- package/src/widgets/pie/types.ts +16 -0
- package/src/widgets/range/components/range-item.test.tsx +243 -0
- package/src/widgets/range/components/range-item.tsx +214 -0
- package/src/widgets/range/config.ts +10 -0
- package/src/widgets/range/index.ts +16 -0
- package/src/widgets/range/range-ui.test.tsx +203 -0
- package/src/widgets/range/range-ui.tsx +14 -0
- package/src/widgets/range/serializer.test.ts +70 -0
- package/src/widgets/range/serializer.ts +27 -0
- package/src/widgets/range/skeleton.tsx +14 -0
- package/src/widgets/range/style.ts +37 -0
- package/src/widgets/range/types.ts +39 -0
- package/src/widgets/scatterplot/config.ts +136 -0
- package/src/widgets/scatterplot/index.ts +8 -0
- package/src/widgets/scatterplot/skeleton.tsx +59 -0
- package/src/widgets/scatterplot/style.ts +21 -0
- package/src/widgets/scatterplot/types.ts +17 -0
- package/src/widgets/selection-summary/index.ts +6 -0
- package/src/widgets/selection-summary/selection-summary.tsx +57 -0
- package/src/widgets/selection-summary/style.ts +10 -0
- package/src/widgets/selection-summary/types.ts +14 -0
- package/src/widgets/skeleton-loader/index.ts +2 -0
- package/src/widgets/skeleton-loader/skeleton-loader.test.tsx +139 -0
- package/src/widgets/skeleton-loader/skeleton-loader.tsx +35 -0
- package/src/widgets/skeleton-loader/types.ts +8 -0
- package/src/widgets/spread/components/max-value.tsx +29 -0
- package/src/widgets/spread/components/min-value.tsx +29 -0
- package/src/widgets/spread/components/separator.tsx +9 -0
- package/src/widgets/spread/config.ts +39 -0
- package/src/widgets/spread/index.ts +23 -0
- package/src/widgets/spread/skeleton.tsx +10 -0
- package/src/widgets/spread/spread-ui.test.tsx +368 -0
- package/src/widgets/spread/spread-ui.tsx +32 -0
- package/src/widgets/spread/style.ts +22 -0
- package/src/widgets/spread/types.ts +47 -0
- package/src/widgets/stores/index.ts +13 -0
- package/src/widgets/stores/types.ts +203 -0
- package/src/widgets/stores/use-widget-selector.ts +47 -0
- package/src/widgets/stores/widget-store-branches.test.ts +275 -0
- package/src/widgets/stores/widget-store-performance.test.ts +750 -0
- package/src/widgets/stores/widget-store.test.ts +942 -0
- package/src/widgets/stores/widget-store.ts +484 -0
- package/src/widgets/subheader/index.ts +3 -0
- package/src/widgets/subheader/style.ts +20 -0
- package/src/widgets/subheader/subheader.test.tsx +45 -0
- package/src/widgets/subheader/subheader.tsx +35 -0
- package/src/widgets/subheader/types.ts +11 -0
- package/src/widgets/table/components/cell-header.tsx +58 -0
- package/src/widgets/table/components/cell.tsx +82 -0
- package/src/widgets/table/components/pagination-actions.tsx +67 -0
- package/src/widgets/table/components/pagination.tsx +41 -0
- package/src/widgets/table/components/row.tsx +65 -0
- package/src/widgets/table/config.test.ts +65 -0
- package/src/widgets/table/config.ts +75 -0
- package/src/widgets/table/helpers.test.ts +244 -0
- package/src/widgets/table/helpers.ts +107 -0
- package/src/widgets/table/hooks/use-pagination.test.ts +294 -0
- package/src/widgets/table/hooks/use-pagination.ts +148 -0
- package/src/widgets/table/hooks/use-selection.test.ts +504 -0
- package/src/widgets/table/hooks/use-selection.ts +194 -0
- package/src/widgets/table/hooks/use-sort.test.ts +296 -0
- package/src/widgets/table/hooks/use-sort.ts +131 -0
- package/src/widgets/table/index.ts +55 -0
- package/src/widgets/table/serializer.ts +54 -0
- package/src/widgets/table/skeleton.tsx +48 -0
- package/src/widgets/table/style.ts +34 -0
- package/src/widgets/table/table-ui.tsx +64 -0
- package/src/widgets/table/types.ts +223 -0
- package/src/widgets/timeseries/config.ts +136 -0
- package/src/widgets/timeseries/index.ts +8 -0
- package/src/widgets/timeseries/skeleton.tsx +55 -0
- package/src/widgets/timeseries/style.ts +36 -0
- package/src/widgets/timeseries/types.ts +17 -0
- package/src/widgets/toolbar-actions/index.ts +6 -0
- package/src/widgets/toolbar-actions/styles.ts +38 -0
- package/src/widgets/toolbar-actions/toolbar-actions.test.tsx +691 -0
- package/src/widgets/toolbar-actions/toolbar-actions.tsx +145 -0
- package/src/widgets/toolbar-actions/types.ts +60 -0
- package/src/widgets/utils/chart-config/config-factory.ts +67 -0
- package/src/widgets/utils/chart-config/csv-modifiers.ts +56 -0
- package/src/widgets/utils/chart-config/download-config.ts +22 -0
- package/src/widgets/utils/chart-config/index.ts +29 -0
- package/src/widgets/utils/chart-config/option-builders.test.ts +366 -0
- package/src/widgets/utils/chart-config/option-builders.ts +308 -0
- package/src/widgets/utils/formatter.ts +2 -0
- package/src/widgets/utils/index.ts +26 -0
- package/{dist/types/widgets/_shared/skeleton/index.d.ts → src/widgets/utils/skeleton/index.ts} +2 -1
- package/src/widgets/utils/skeleton/styles.ts +20 -0
- package/src/widgets/wrapper/components/actions.test.tsx +105 -0
- package/src/widgets/wrapper/components/actions.tsx +35 -0
- package/src/widgets/wrapper/components/options.test.tsx +331 -0
- package/src/widgets/wrapper/components/options.tsx +81 -0
- package/src/widgets/wrapper/components/title.test.tsx +126 -0
- package/src/widgets/wrapper/components/title.tsx +35 -0
- package/src/widgets/wrapper/index.ts +16 -0
- package/src/widgets/wrapper/styles.ts +98 -0
- package/src/widgets/wrapper/types.ts +55 -0
- package/src/widgets/wrapper/wrapper-ui.test.tsx +232 -0
- package/src/widgets/wrapper/wrapper-ui.tsx +72 -0
- package/src/widgets/wrapper/wrapper.test.tsx +365 -0
- package/src/widgets/wrapper/wrapper.tsx +60 -0
- package/src/widgets-v2/PERFORMANCE.md +189 -0
- package/src/widgets-v2/actions/brush-toggle/brush-toggle.test.tsx +180 -0
- package/src/widgets-v2/actions/brush-toggle/brush-toggle.tsx +154 -0
- package/src/widgets-v2/actions/brush-toggle/index.ts +3 -0
- package/src/widgets-v2/actions/brush-toggle/labels.ts +9 -0
- package/src/widgets-v2/actions/brush-toggle/style.ts +11 -0
- package/src/widgets-v2/actions/brush-toggle/transforms.test.ts +47 -0
- package/src/widgets-v2/actions/brush-toggle/transforms.ts +31 -0
- package/src/widgets-v2/actions/change-column/change-column-icon.tsx +14 -0
- package/src/widgets-v2/actions/change-column/change-column.test.tsx +59 -0
- package/src/widgets-v2/actions/change-column/change-column.tsx +189 -0
- package/src/widgets-v2/actions/change-column/index.ts +7 -0
- package/src/widgets-v2/actions/change-column/labels.ts +11 -0
- package/src/widgets-v2/actions/change-column/sortable-column-item.tsx +63 -0
- package/src/widgets-v2/actions/change-column/style.ts +58 -0
- package/src/widgets-v2/actions/change-column/types.ts +11 -0
- package/src/widgets-v2/actions/download/constants.ts +14 -0
- package/src/widgets-v2/actions/download/csv-item.test.tsx +77 -0
- package/src/widgets-v2/actions/download/csv-item.tsx +71 -0
- package/src/widgets-v2/actions/download/download.test.tsx +327 -0
- package/src/widgets-v2/actions/download/download.tsx +144 -0
- package/src/widgets-v2/actions/download/exports.test.tsx +198 -0
- package/src/widgets-v2/actions/download/exports.ts +115 -0
- package/src/widgets-v2/actions/download/icons.tsx +35 -0
- package/src/widgets-v2/actions/download/index.ts +15 -0
- package/src/widgets-v2/actions/download/labels.ts +16 -0
- package/src/widgets-v2/actions/download/png-item.test.tsx +72 -0
- package/src/widgets-v2/actions/download/png-item.tsx +53 -0
- package/src/widgets-v2/actions/download/style.ts +3 -0
- package/src/widgets-v2/actions/download/types.ts +32 -0
- package/src/widgets-v2/actions/fullscreen/fullscreen.test.tsx +150 -0
- package/src/widgets-v2/actions/fullscreen/fullscreen.tsx +230 -0
- package/src/widgets-v2/actions/fullscreen/index.ts +7 -0
- package/src/widgets-v2/actions/fullscreen/labels.ts +9 -0
- package/src/widgets-v2/actions/fullscreen/style.ts +59 -0
- package/src/widgets-v2/actions/fullscreen/types.ts +15 -0
- package/src/widgets-v2/actions/index.ts +95 -0
- package/src/widgets-v2/actions/lock-selection/index.ts +10 -0
- package/src/widgets-v2/actions/lock-selection/labels.ts +11 -0
- package/src/widgets-v2/actions/lock-selection/lock-selection.test.tsx +301 -0
- package/src/widgets-v2/actions/lock-selection/lock-selection.tsx +188 -0
- package/src/widgets-v2/actions/lock-selection/style.ts +11 -0
- package/src/widgets-v2/actions/lock-selection/transforms.ts +27 -0
- package/src/widgets-v2/actions/relative-data/index.ts +3 -0
- package/src/widgets-v2/actions/relative-data/labels.ts +9 -0
- package/src/widgets-v2/actions/relative-data/relative-data.test.tsx +71 -0
- package/src/widgets-v2/actions/relative-data/relative-data.tsx +107 -0
- package/src/widgets-v2/actions/relative-data/style.ts +11 -0
- package/src/widgets-v2/actions/relative-data/transforms.test.ts +151 -0
- package/src/widgets-v2/actions/relative-data/transforms.ts +70 -0
- package/src/widgets-v2/actions/searcher/filter.ts +28 -0
- package/src/widgets-v2/actions/searcher/index.ts +8 -0
- package/src/widgets-v2/actions/searcher/labels.ts +13 -0
- package/src/widgets-v2/actions/searcher/searcher-toggle.tsx +91 -0
- package/src/widgets-v2/actions/searcher/searcher.test.tsx +92 -0
- package/src/widgets-v2/actions/searcher/searcher.tsx +111 -0
- package/src/widgets-v2/actions/searcher/style.ts +15 -0
- package/src/widgets-v2/actions/show-all/index.ts +7 -0
- package/src/widgets-v2/actions/show-all/labels.ts +8 -0
- package/src/widgets-v2/actions/show-all/show-all.test.tsx +50 -0
- package/src/widgets-v2/actions/show-all/show-all.tsx +72 -0
- package/src/widgets-v2/actions/show-all/style.ts +8 -0
- package/src/widgets-v2/actions/stack-toggle/index.ts +3 -0
- package/src/widgets-v2/actions/stack-toggle/labels.ts +9 -0
- package/src/widgets-v2/actions/stack-toggle/stack-toggle.test.tsx +61 -0
- package/src/widgets-v2/actions/stack-toggle/stack-toggle.tsx +54 -0
- package/src/widgets-v2/actions/stack-toggle/style.ts +11 -0
- package/src/widgets-v2/actions/stack-toggle/transforms.test.ts +43 -0
- package/src/widgets-v2/actions/stack-toggle/transforms.ts +25 -0
- package/src/widgets-v2/actions/zoom-toggle/index.ts +9 -0
- package/src/widgets-v2/actions/zoom-toggle/labels.ts +9 -0
- package/src/widgets-v2/actions/zoom-toggle/style.ts +11 -0
- package/src/widgets-v2/actions/zoom-toggle/transforms.test.ts +148 -0
- package/src/widgets-v2/actions/zoom-toggle/transforms.ts +171 -0
- package/src/widgets-v2/actions/zoom-toggle/zoom-toggle.test.tsx +107 -0
- package/src/widgets-v2/actions/zoom-toggle/zoom-toggle.tsx +106 -0
- package/src/widgets-v2/bar/download.test.tsx +91 -0
- package/src/widgets-v2/bar/download.tsx +60 -0
- package/src/widgets-v2/bar/index.ts +10 -0
- package/src/widgets-v2/bar/options.test.ts +361 -0
- package/src/widgets-v2/bar/options.ts +333 -0
- package/src/widgets-v2/bar/skeleton.test.tsx +19 -0
- package/src/widgets-v2/bar/skeleton.tsx +69 -0
- package/src/widgets-v2/bar/types.ts +51 -0
- package/src/widgets-v2/category/category-ui.test.tsx +909 -0
- package/src/widgets-v2/category/category-ui.tsx +479 -0
- package/src/widgets-v2/category/category.relative-data.test.tsx +107 -0
- package/src/widgets-v2/category/category.stack-toggle.test.tsx +85 -0
- package/src/widgets-v2/category/category.test.tsx +305 -0
- package/src/widgets-v2/category/category.tsx +130 -0
- package/src/widgets-v2/category/components/category-bar-stacked.test.tsx +121 -0
- package/src/widgets-v2/category/components/category-bar-stacked.tsx +73 -0
- package/src/widgets-v2/category/components/category-bar.test.tsx +64 -0
- package/src/widgets-v2/category/components/category-bar.tsx +49 -0
- package/src/widgets-v2/category/components/category-legend.test.tsx +102 -0
- package/src/widgets-v2/category/components/category-legend.tsx +82 -0
- package/src/widgets-v2/category/components/category-row-multi.tsx +86 -0
- package/src/widgets-v2/category/components/category-row-other.test.tsx +57 -0
- package/src/widgets-v2/category/components/category-row-other.tsx +84 -0
- package/src/widgets-v2/category/components/category-row-single.tsx +76 -0
- package/src/widgets-v2/category/components/category-row-stacked.test.tsx +248 -0
- package/src/widgets-v2/category/components/category-row-stacked.tsx +104 -0
- package/src/widgets-v2/category/download.test.ts +80 -0
- package/src/widgets-v2/category/download.ts +50 -0
- package/src/widgets-v2/category/index.ts +32 -0
- package/src/widgets-v2/category/skeleton.test.tsx +26 -0
- package/src/widgets-v2/category/skeleton.tsx +74 -0
- package/src/widgets-v2/category/style.ts +329 -0
- package/src/widgets-v2/category/types.ts +61 -0
- package/src/widgets-v2/echart/echart-ui.test.tsx +327 -0
- package/src/widgets-v2/echart/echart-ui.tsx +232 -0
- package/src/widgets-v2/echart/echart.test.tsx +229 -0
- package/src/widgets-v2/echart/echart.tsx +199 -0
- package/src/widgets-v2/echart/edge-label-clamp.test.ts +198 -0
- package/src/widgets-v2/echart/edge-label-clamp.ts +217 -0
- package/src/widgets-v2/echart/index.ts +22 -0
- package/src/widgets-v2/echart/shared-resize-observer.test.ts +91 -0
- package/src/widgets-v2/echart/shared-resize-observer.ts +56 -0
- package/src/widgets-v2/echart/style.ts +8 -0
- package/src/widgets-v2/echart/use-chart-selection.test.tsx +120 -0
- package/src/widgets-v2/echart/use-chart-selection.ts +121 -0
- package/src/widgets-v2/formula/delta.tsx +61 -0
- package/src/widgets-v2/formula/download.test.tsx +65 -0
- package/src/widgets-v2/formula/download.tsx +63 -0
- package/src/widgets-v2/formula/formula-ui.test.tsx +91 -0
- package/src/widgets-v2/formula/formula-ui.tsx +66 -0
- package/src/widgets-v2/formula/formula.test.tsx +50 -0
- package/src/widgets-v2/formula/formula.tsx +34 -0
- package/src/widgets-v2/formula/index.ts +17 -0
- package/src/widgets-v2/formula/note.tsx +25 -0
- package/src/widgets-v2/formula/prefix.tsx +25 -0
- package/src/widgets-v2/formula/series.tsx +67 -0
- package/src/widgets-v2/formula/skeleton.test.tsx +21 -0
- package/src/widgets-v2/formula/skeleton.tsx +27 -0
- package/src/widgets-v2/formula/style.ts +31 -0
- package/src/widgets-v2/formula/subcomponents.test.tsx +107 -0
- package/src/widgets-v2/formula/suffix.tsx +25 -0
- package/src/widgets-v2/formula/types.ts +48 -0
- package/src/widgets-v2/formula/value.tsx +31 -0
- package/src/widgets-v2/histogram/download.test.ts +94 -0
- package/src/widgets-v2/histogram/download.ts +56 -0
- package/src/widgets-v2/histogram/index.ts +13 -0
- package/src/widgets-v2/histogram/options.test.ts +411 -0
- package/src/widgets-v2/histogram/options.ts +390 -0
- package/src/widgets-v2/histogram/skeleton.test.tsx +16 -0
- package/src/widgets-v2/histogram/skeleton.tsx +70 -0
- package/src/widgets-v2/histogram/transforms.test.ts +81 -0
- package/src/widgets-v2/histogram/transforms.ts +53 -0
- package/src/widgets-v2/histogram/types.ts +64 -0
- package/src/widgets-v2/index.ts +212 -0
- package/src/widgets-v2/markdown/download.test.ts +66 -0
- package/src/widgets-v2/markdown/download.tsx +56 -0
- package/src/widgets-v2/markdown/index.ts +6 -0
- package/src/widgets-v2/markdown/markdown-content.test.tsx +165 -0
- package/src/widgets-v2/markdown/markdown-content.tsx +81 -0
- package/src/widgets-v2/markdown/markdown-ui.test.tsx +75 -0
- package/src/widgets-v2/markdown/markdown-ui.tsx +55 -0
- package/src/widgets-v2/markdown/markdown.test.tsx +39 -0
- package/src/widgets-v2/markdown/markdown.tsx +17 -0
- package/src/widgets-v2/markdown/skeleton.test.tsx +15 -0
- package/src/widgets-v2/markdown/skeleton.tsx +32 -0
- package/src/widgets-v2/markdown/style.ts +53 -0
- package/src/widgets-v2/markdown/types.ts +4 -0
- package/src/widgets-v2/note/labels.ts +9 -0
- package/src/widgets-v2/note/style.ts +26 -0
- package/src/widgets-v2/note/widget-note.test.tsx +158 -0
- package/src/widgets-v2/note/widget-note.tsx +172 -0
- package/src/widgets-v2/pie/download.test.ts +78 -0
- package/src/widgets-v2/pie/download.ts +51 -0
- package/src/widgets-v2/pie/index.ts +10 -0
- package/src/widgets-v2/pie/options.test.ts +930 -0
- package/src/widgets-v2/pie/options.ts +611 -0
- package/src/widgets-v2/pie/skeleton.test.tsx +20 -0
- package/src/widgets-v2/pie/skeleton.tsx +94 -0
- package/src/widgets-v2/pie/types.ts +62 -0
- package/src/widgets-v2/provider/widget-provider.test.tsx +119 -0
- package/src/widgets-v2/provider/widget-provider.tsx +111 -0
- package/src/widgets-v2/range/index.ts +4 -0
- package/src/widgets-v2/range/range-ui.test.tsx +136 -0
- package/src/widgets-v2/range/range-ui.tsx +278 -0
- package/src/widgets-v2/range/range.test.tsx +68 -0
- package/src/widgets-v2/range/range.tsx +52 -0
- package/src/widgets-v2/range/skeleton.test.tsx +17 -0
- package/src/widgets-v2/range/skeleton.tsx +47 -0
- package/src/widgets-v2/range/style.ts +41 -0
- package/src/widgets-v2/range/types.ts +37 -0
- package/src/widgets-v2/scatterplot/download.test.ts +71 -0
- package/src/widgets-v2/scatterplot/download.ts +50 -0
- package/src/widgets-v2/scatterplot/index.ts +14 -0
- package/src/widgets-v2/scatterplot/options.test.ts +411 -0
- package/src/widgets-v2/scatterplot/options.ts +422 -0
- package/src/widgets-v2/scatterplot/skeleton.test.tsx +17 -0
- package/src/widgets-v2/scatterplot/skeleton.tsx +84 -0
- package/src/widgets-v2/scatterplot/transforms.test.ts +134 -0
- package/src/widgets-v2/scatterplot/transforms.ts +61 -0
- package/src/widgets-v2/scatterplot/types.ts +59 -0
- package/src/widgets-v2/selection-summary/labels.ts +15 -0
- package/src/widgets-v2/selection-summary/selection-summary.test.tsx +59 -0
- package/src/widgets-v2/selection-summary/selection-summary.tsx +82 -0
- package/src/widgets-v2/selection-summary/style.ts +38 -0
- package/src/widgets-v2/spread/band.test.ts +46 -0
- package/src/widgets-v2/spread/band.ts +47 -0
- package/src/widgets-v2/spread/download.test.ts +64 -0
- package/src/widgets-v2/spread/download.ts +55 -0
- package/src/widgets-v2/spread/index.ts +11 -0
- package/src/widgets-v2/spread/separator.tsx +11 -0
- package/src/widgets-v2/spread/skeleton.test.tsx +17 -0
- package/src/widgets-v2/spread/skeleton.tsx +38 -0
- package/src/widgets-v2/spread/spread-ui.test.tsx +108 -0
- package/src/widgets-v2/spread/spread-ui.tsx +52 -0
- package/src/widgets-v2/spread/spread.test.tsx +50 -0
- package/src/widgets-v2/spread/spread.tsx +31 -0
- package/src/widgets-v2/spread/types.ts +27 -0
- package/src/widgets-v2/state/labels.test.ts +33 -0
- package/src/widgets-v2/state/labels.ts +20 -0
- package/src/widgets-v2/state/style.ts +25 -0
- package/src/widgets-v2/state/widget-state.test.tsx +294 -0
- package/src/widgets-v2/state/widget-state.tsx +184 -0
- package/src/widgets-v2/stores/index.ts +49 -0
- package/src/widgets-v2/stores/pipeline-middleware.test.ts +187 -0
- package/src/widgets-v2/stores/pipeline-middleware.ts +91 -0
- package/src/widgets-v2/stores/transforms.test.ts +162 -0
- package/src/widgets-v2/stores/transforms.ts +70 -0
- package/src/widgets-v2/stores/types.ts +64 -0
- package/src/widgets-v2/stores/use-echart-instance.test.tsx +91 -0
- package/src/widgets-v2/stores/use-echart-instance.ts +29 -0
- package/src/widgets-v2/stores/use-transform-enabled.test.tsx +127 -0
- package/src/widgets-v2/stores/use-transform-enabled.ts +25 -0
- package/src/widgets-v2/stores/use-transform.test.tsx +262 -0
- package/src/widgets-v2/stores/use-transform.ts +158 -0
- package/src/widgets-v2/stores/widget-context.test.tsx +58 -0
- package/src/widgets-v2/stores/widget-context.ts +15 -0
- package/src/widgets-v2/stores/widget-store-registry.test.ts +292 -0
- package/src/widgets-v2/stores/widget-store-registry.ts +239 -0
- package/src/widgets-v2/subheader/style.ts +12 -0
- package/src/widgets-v2/subheader/subheader.test.tsx +30 -0
- package/src/widgets-v2/subheader/subheader.tsx +16 -0
- package/src/widgets-v2/table/download.test.ts +85 -0
- package/src/widgets-v2/table/download.ts +43 -0
- package/src/widgets-v2/table/helpers.test.ts +233 -0
- package/src/widgets-v2/table/helpers.ts +131 -0
- package/src/widgets-v2/table/index.ts +24 -0
- package/src/widgets-v2/table/labels.tsx +41 -0
- package/src/widgets-v2/table/skeleton.test.tsx +26 -0
- package/src/widgets-v2/table/skeleton.tsx +65 -0
- package/src/widgets-v2/table/style.ts +43 -0
- package/src/widgets-v2/table/table-ui.test.tsx +200 -0
- package/src/widgets-v2/table/table-ui.tsx +364 -0
- package/src/widgets-v2/table/table.test.tsx +119 -0
- package/src/widgets-v2/table/table.tsx +179 -0
- package/src/widgets-v2/table/transforms.test.ts +40 -0
- package/src/widgets-v2/table/transforms.ts +28 -0
- package/src/widgets-v2/table/types.ts +55 -0
- package/src/widgets-v2/test-utils.ts +107 -0
- package/src/widgets-v2/timeseries/download.test.ts +95 -0
- package/src/widgets-v2/timeseries/download.ts +82 -0
- package/src/widgets-v2/timeseries/index.ts +11 -0
- package/src/widgets-v2/timeseries/options.test.ts +399 -0
- package/src/widgets-v2/timeseries/options.ts +342 -0
- package/src/widgets-v2/timeseries/skeleton.test.tsx +13 -0
- package/src/widgets-v2/timeseries/skeleton.tsx +76 -0
- package/src/widgets-v2/timeseries/transforms.test.ts +49 -0
- package/src/widgets-v2/timeseries/transforms.ts +31 -0
- package/src/widgets-v2/timeseries/types.ts +65 -0
- package/src/widgets-v2/toolbox/labels.ts +9 -0
- package/src/widgets-v2/toolbox/style.ts +33 -0
- package/src/widgets-v2/toolbox/toolbox.test.tsx +200 -0
- package/src/widgets-v2/toolbox/toolbox.tsx +309 -0
- package/src/widgets-v2/types.ts +25 -0
- package/src/widgets-v2/utils/data-zoom-layout.ts +26 -0
- package/src/widgets-v2/utils/index.ts +3 -0
- package/src/widgets-v2/utils/merge-options.test.ts +52 -0
- package/src/widgets-v2/utils/merge-options.ts +50 -0
- package/src/widgets-v2/utils/resolve-theme-color.test.ts +43 -0
- package/src/widgets-v2/utils/resolve-theme-color.ts +34 -0
- package/src/widgets-v2/wrapper/index.ts +14 -0
- package/src/widgets-v2/wrapper/labels.ts +11 -0
- package/src/widgets-v2/wrapper/style.ts +128 -0
- package/src/widgets-v2/wrapper/widget-actions.test.tsx +52 -0
- package/src/widgets-v2/wrapper/widget-actions.tsx +43 -0
- package/src/widgets-v2/wrapper/widget-content.test.tsx +27 -0
- package/src/widgets-v2/wrapper/widget-content.tsx +29 -0
- package/src/widgets-v2/wrapper/widget-wrapper.test.tsx +255 -0
- package/src/widgets-v2/wrapper/widget-wrapper.tsx +194 -0
- package/dist/cjs-D9ro6BXv.js +0 -85
- package/dist/cjs-D9ro6BXv.js.map +0 -1
- package/dist/components.js.map +0 -1
- package/dist/error-B2IJ9d2h.js +0 -38
- package/dist/error-B2IJ9d2h.js.map +0 -1
- package/dist/exports-Cr43OCul.js +0 -51
- package/dist/exports-Cr43OCul.js.map +0 -1
- package/dist/lasso-tool-CYn3ivf-.js +0 -534
- package/dist/lasso-tool-CYn3ivf-.js.map +0 -1
- package/dist/markdown-ui-CpNYUPqC.js +0 -68
- package/dist/markdown-ui-CpNYUPqC.js.map +0 -1
- package/dist/no-data-C54XJt13.js +0 -61
- package/dist/no-data-C54XJt13.js.map +0 -1
- package/dist/note-Clng2ej6.js +0 -124
- package/dist/note-Clng2ej6.js.map +0 -1
- package/dist/options-D9wflre6.js +0 -49
- package/dist/options-D9wflre6.js.map +0 -1
- package/dist/row-DLKZN5aF.js +0 -33
- package/dist/row-DLKZN5aF.js.map +0 -1
- package/dist/row-DrHwXNvF.js +0 -35
- package/dist/row-DrHwXNvF.js.map +0 -1
- package/dist/series-Cf1QPZHV.js +0 -83
- package/dist/series-Cf1QPZHV.js.map +0 -1
- package/dist/series-Do02NQUF.js +0 -91
- package/dist/series-Do02NQUF.js.map +0 -1
- package/dist/smart-tooltip-BEtBaIdz.js +0 -39
- package/dist/smart-tooltip-BEtBaIdz.js.map +0 -1
- package/dist/styles-CcC5L2cr.js +0 -77
- package/dist/styles-CcC5L2cr.js.map +0 -1
- package/dist/styles-dOu_pRNb.js +0 -77
- package/dist/styles-dOu_pRNb.js.map +0 -1
- package/dist/tooltip-BDnrRKrp.js +0 -25
- package/dist/tooltip-BDnrRKrp.js.map +0 -1
- package/dist/types/common/common.d.ts +0 -3
- package/dist/types/common/index.d.ts +0 -26
- package/dist/types/common/lasso-tools.d.ts +0 -36
- package/dist/types/common/measurement-tools.d.ts +0 -65
- package/dist/types/hooks/use-debounce.d.ts +0 -19
- package/dist/types/widgets/_shared/chart-config/index.d.ts +0 -7
- package/dist/types/widgets/_shared/chart-config/option-builders.d.ts +0 -34
- package/dist/types/widgets/actions/relative-data/style.d.ts +0 -8
- package/dist/types/widgets/actions/relative-data/utils.test.d.ts +0 -1
- package/dist/types/widgets/actions/zoom-toggle/index.d.ts +0 -2
- package/dist/types/widgets/category/components/index.d.ts +0 -10
- package/dist/types/widgets/index.d.ts +0 -8
- package/dist/types/widgets/range/serializer.test.d.ts +0 -1
- package/dist/types/widgets/root/index.d.ts +0 -3
- package/dist/types/widgets/root/root.d.ts +0 -2
- package/dist/types/widgets/root/types.d.ts +0 -9
- package/dist/types/widgets/root/utils.d.ts +0 -1
- package/dist/types/widgets/stores/widget-store.test.d.ts +0 -1
- package/dist/types/widgets/table/components/index.d.ts +0 -4
- package/dist/types/widgets/table/helpers.test.d.ts +0 -1
- package/dist/types/widgets/table/hooks/index.d.ts +0 -6
- package/dist/types/widgets/table/hooks/use-pagination.test.d.ts +0 -1
- package/dist/types/widgets/table/hooks/use-selection.test.d.ts +0 -1
- package/dist/types/widgets/table/hooks/use-sort.test.d.ts +0 -1
- package/dist/utils-DNtU8q7E.js +0 -144
- package/dist/utils-DNtU8q7E.js.map +0 -1
- package/dist/utils-Dv5Z47UQ.js +0 -144
- package/dist/utils-Dv5Z47UQ.js.map +0 -1
- package/dist/widget-store-CB6Trp_0.js +0 -131
- package/dist/widget-store-CB6Trp_0.js.map +0 -1
- package/dist/widget-store-yDO2ul8g.js +0 -44
- package/dist/widget-store-yDO2ul8g.js.map +0 -1
- package/dist/widgets/actions.js.map +0 -1
- package/dist/widgets/echart.js.map +0 -1
- package/dist/widgets/formula.js.map +0 -1
- package/dist/widgets/root.js +0 -68
- package/dist/widgets/root.js.map +0 -1
- package/dist/widgets/stores.js.map +0 -1
- package/dist/widgets.js +0 -11
- package/dist/widgets.js.map +0 -1
- /package/dist/types/widgets/{_shared → utils}/chart-config/csv-modifiers.d.ts +0 -0
- /package/dist/types/widgets/{_shared → utils}/skeleton/styles.d.ts +0 -0
|
@@ -0,0 +1,440 @@
|
|
|
1
|
+
import { C as e, S as t, T as n, p as r } from "./stores-tiFePP0A.js";
|
|
2
|
+
import { d as i, n as a, t as o } from "./download-DdaK3qgC.js";
|
|
3
|
+
import { c as ee } from "react/compiler-runtime";
|
|
4
|
+
import { Box as s, Checkbox as c, IconButton as l, Skeleton as u, Table as d, TableBody as f, TableCell as p, TableContainer as m, TableHead as h, TablePagination as g, TableRow as _, TableSortLabel as v } from "@mui/material";
|
|
5
|
+
import { Fragment as y, jsx as b, jsxs as x } from "react/jsx-runtime";
|
|
6
|
+
import { FirstPage as S, KeyboardArrowLeft as C, KeyboardArrowRight as w, LastPage as T } from "@mui/icons-material";
|
|
7
|
+
//#region src/widgets-v2/table/labels.tsx
|
|
8
|
+
var E = {
|
|
9
|
+
fontWeight: 600,
|
|
10
|
+
color: "text.primary"
|
|
11
|
+
}, D = {
|
|
12
|
+
selectAll: "Select all rows",
|
|
13
|
+
selectRow: (e) => `Select row ${e}`,
|
|
14
|
+
rowsPerPage: "Rows per page:",
|
|
15
|
+
paginationOf: (e, t, n) => /* @__PURE__ */ x(y, { children: [/* @__PURE__ */ b(s, {
|
|
16
|
+
component: "span",
|
|
17
|
+
sx: E,
|
|
18
|
+
children: `${e}–${t}`
|
|
19
|
+
}), ` of ${n}`] }),
|
|
20
|
+
firstPage: "First page",
|
|
21
|
+
previousPage: "Previous page",
|
|
22
|
+
nextPage: "Next page",
|
|
23
|
+
lastPage: "Last page"
|
|
24
|
+
}, O = 10, k = [
|
|
25
|
+
10,
|
|
26
|
+
25,
|
|
27
|
+
50,
|
|
28
|
+
100
|
|
29
|
+
], A = {
|
|
30
|
+
container: {
|
|
31
|
+
width: "100%",
|
|
32
|
+
overflowX: "auto"
|
|
33
|
+
},
|
|
34
|
+
table: { minWidth: 0 },
|
|
35
|
+
headerCell: {
|
|
36
|
+
fontWeight: 600,
|
|
37
|
+
backgroundColor: "background.paper"
|
|
38
|
+
},
|
|
39
|
+
row: { "&:last-child td, &:last-child th": { border: 0 } },
|
|
40
|
+
rowClickable: { cursor: "pointer" },
|
|
41
|
+
pagination: {
|
|
42
|
+
borderTop: "1px solid",
|
|
43
|
+
borderColor: "divider"
|
|
44
|
+
},
|
|
45
|
+
paginationActions: {
|
|
46
|
+
display: "flex",
|
|
47
|
+
alignItems: "center",
|
|
48
|
+
gap: .25,
|
|
49
|
+
ml: 1
|
|
50
|
+
},
|
|
51
|
+
empty: {
|
|
52
|
+
textAlign: "center",
|
|
53
|
+
color: "text.secondary",
|
|
54
|
+
py: 3
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
//#endregion
|
|
58
|
+
//#region src/widgets-v2/table/table-ui.tsx
|
|
59
|
+
function j(e) {
|
|
60
|
+
let t = ee(82), { columns: n, rows: r, total: i, page: a, pageSize: o, pageSizeOptions: l, sort: u, keyColumn: y, selection: S, selectable: C, onSortChange: w, onPageChange: T, onPageSizeChange: E, onSelectionChange: O, onRowClick: j, onRowHover: M, labels: N, emptyContent: P, size: F } = e, I = l === void 0 ? k : l, L = y === void 0 ? "id" : y, R = C !== void 0 && C;
|
|
61
|
+
process.env.NODE_ENV !== "production" && r.some((e) => e[L] == null) && console.error(`<TableUI>: rows are missing the identity column \`${L}\`. Set the \`keyColumn\` prop to a column present on every row, or add the column to the data.`);
|
|
62
|
+
let z;
|
|
63
|
+
t[0] === N ? z = t[1] : (z = {
|
|
64
|
+
...D,
|
|
65
|
+
...N
|
|
66
|
+
}, t[0] = N, t[1] = z);
|
|
67
|
+
let B = z, re = i > Math.min(...I), ie;
|
|
68
|
+
t[2] === B ? ie = t[3] : (ie = ne(B), t[2] = B, t[3] = ie);
|
|
69
|
+
let ae = ie, V;
|
|
70
|
+
t[4] === S ? V = t[5] : (V = S ?? [], t[4] = S, t[5] = V);
|
|
71
|
+
let oe;
|
|
72
|
+
t[6] === V ? oe = t[7] : (oe = new Set(V), t[6] = V, t[7] = oe);
|
|
73
|
+
let H = oe, se;
|
|
74
|
+
t[8] === L ? se = t[9] : (se = (e, t) => e[L] ?? t, t[8] = L, t[9] = se);
|
|
75
|
+
let U = se, ce;
|
|
76
|
+
t[10] !== U || t[11] !== r ? (ce = r.map(U), t[10] = U, t[11] = r, t[12] = ce) : ce = t[12];
|
|
77
|
+
let W = ce, le;
|
|
78
|
+
t[13] !== W || t[14] !== H ? (le = W.length > 0 && W.every((e) => H.has(e)), t[13] = W, t[14] = H, t[15] = le) : le = t[15];
|
|
79
|
+
let G = le, ue;
|
|
80
|
+
t[16] !== G || t[17] !== W || t[18] !== H ? (ue = !G && W.some((e) => H.has(e)), t[16] = G, t[17] = W, t[18] = H, t[19] = ue) : ue = t[19];
|
|
81
|
+
let de = ue, fe;
|
|
82
|
+
t[20] !== w || t[21] !== u?.columnId || t[22] !== u?.direction ? (fe = (e) => {
|
|
83
|
+
if (!w) return;
|
|
84
|
+
let t = u?.columnId === e && u?.direction === "asc" ? "desc" : "asc";
|
|
85
|
+
w({
|
|
86
|
+
columnId: e,
|
|
87
|
+
direction: t
|
|
88
|
+
});
|
|
89
|
+
}, t[20] = w, t[21] = u?.columnId, t[22] = u?.direction, t[23] = fe) : fe = t[23];
|
|
90
|
+
let K = fe, pe;
|
|
91
|
+
t[24] !== G || t[25] !== O || t[26] !== W || t[27] !== S ? (pe = () => {
|
|
92
|
+
if (O) {
|
|
93
|
+
if (G) O((S ?? []).filter((e) => !W.includes(e)));
|
|
94
|
+
else {
|
|
95
|
+
let e = new Set(S ?? []);
|
|
96
|
+
for (let t of W) e.add(t);
|
|
97
|
+
O([...e]);
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
}, t[24] = G, t[25] = O, t[26] = W, t[27] = S, t[28] = pe) : pe = t[28];
|
|
101
|
+
let me = pe, he;
|
|
102
|
+
t[29] !== O || t[30] !== S ? (he = (e) => {
|
|
103
|
+
if (!O) return;
|
|
104
|
+
let t = new Set(S ?? []);
|
|
105
|
+
t.has(e) ? t.delete(e) : t.add(e), O([...t]);
|
|
106
|
+
}, t[29] = O, t[30] = S, t[31] = he) : he = t[31];
|
|
107
|
+
let ge = he, q;
|
|
108
|
+
t[32] !== B || t[33] !== G || t[34] !== me || t[35] !== R || t[36] !== de ? (q = R ? /* @__PURE__ */ b(p, {
|
|
109
|
+
padding: "checkbox",
|
|
110
|
+
sx: A.headerCell,
|
|
111
|
+
children: /* @__PURE__ */ b(c, {
|
|
112
|
+
checked: G,
|
|
113
|
+
indeterminate: de,
|
|
114
|
+
onChange: me,
|
|
115
|
+
inputProps: { "aria-label": B.selectAll }
|
|
116
|
+
})
|
|
117
|
+
}) : null, t[32] = B, t[33] = G, t[34] = me, t[35] = R, t[36] = de, t[37] = q) : q = t[37];
|
|
118
|
+
let J;
|
|
119
|
+
if (t[38] !== n || t[39] !== K || t[40] !== w || t[41] !== u?.columnId || t[42] !== u?.direction) {
|
|
120
|
+
let e;
|
|
121
|
+
t[44] !== K || t[45] !== w || t[46] !== u?.columnId || t[47] !== u?.direction ? (e = (e) => {
|
|
122
|
+
let t = u?.columnId === e.id, n = t ? u?.direction : void 0;
|
|
123
|
+
return /* @__PURE__ */ b(p, {
|
|
124
|
+
align: e.align,
|
|
125
|
+
sortDirection: n,
|
|
126
|
+
sx: A.headerCell,
|
|
127
|
+
style: e.width == null ? void 0 : { width: e.width },
|
|
128
|
+
children: e.sortable && w ? /* @__PURE__ */ b(v, {
|
|
129
|
+
active: t,
|
|
130
|
+
direction: n ?? "asc",
|
|
131
|
+
onClick: () => K(e.id),
|
|
132
|
+
children: e.label
|
|
133
|
+
}) : e.label
|
|
134
|
+
}, e.id);
|
|
135
|
+
}, t[44] = K, t[45] = w, t[46] = u?.columnId, t[47] = u?.direction, t[48] = e) : e = t[48], J = n.map(e), t[38] = n, t[39] = K, t[40] = w, t[41] = u?.columnId, t[42] = u?.direction, t[43] = J;
|
|
136
|
+
} else J = t[43];
|
|
137
|
+
let Y;
|
|
138
|
+
t[49] !== q || t[50] !== J ? (Y = /* @__PURE__ */ b(h, { children: /* @__PURE__ */ x(_, { children: [q, J] }) }), t[49] = q, t[50] = J, t[51] = Y) : Y = t[51];
|
|
139
|
+
let X;
|
|
140
|
+
t[52] !== B || t[53] !== n || t[54] !== P || t[55] !== ge || t[56] !== j || t[57] !== M || t[58] !== U || t[59] !== r || t[60] !== R || t[61] !== H ? (X = r.length === 0 ? /* @__PURE__ */ b(_, { children: /* @__PURE__ */ b(p, {
|
|
141
|
+
colSpan: n.length + +!!R,
|
|
142
|
+
sx: A.empty,
|
|
143
|
+
children: P ?? null
|
|
144
|
+
}) }) : r.map((e, t) => {
|
|
145
|
+
let r = U(e, t), i = H.has(r);
|
|
146
|
+
return /* @__PURE__ */ x(_, {
|
|
147
|
+
hover: !0,
|
|
148
|
+
selected: i,
|
|
149
|
+
onClick: () => j?.(e),
|
|
150
|
+
onMouseEnter: () => M?.(e),
|
|
151
|
+
onMouseLeave: () => M?.(null),
|
|
152
|
+
sx: {
|
|
153
|
+
...A.row,
|
|
154
|
+
...j ? A.rowClickable : null
|
|
155
|
+
},
|
|
156
|
+
children: [R ? /* @__PURE__ */ b(p, {
|
|
157
|
+
padding: "checkbox",
|
|
158
|
+
children: /* @__PURE__ */ b(c, {
|
|
159
|
+
checked: i,
|
|
160
|
+
onClick: (e) => {
|
|
161
|
+
e.stopPropagation(), ge(r);
|
|
162
|
+
},
|
|
163
|
+
inputProps: { "aria-label": B.selectRow(r) }
|
|
164
|
+
})
|
|
165
|
+
}) : null, n.map((t) => /* @__PURE__ */ b(p, {
|
|
166
|
+
align: t.align,
|
|
167
|
+
children: t.formatter ? t.formatter(e[t.id], e) : te(e[t.id])
|
|
168
|
+
}, t.id))]
|
|
169
|
+
}, r);
|
|
170
|
+
}), t[52] = B, t[53] = n, t[54] = P, t[55] = ge, t[56] = j, t[57] = M, t[58] = U, t[59] = r, t[60] = R, t[61] = H, t[62] = X) : X = t[62];
|
|
171
|
+
let Z;
|
|
172
|
+
t[63] === X ? Z = t[64] : (Z = /* @__PURE__ */ b(f, { children: X }), t[63] = X, t[64] = Z);
|
|
173
|
+
let Q;
|
|
174
|
+
t[65] !== F || t[66] !== Y || t[67] !== Z ? (Q = /* @__PURE__ */ b(m, { children: /* @__PURE__ */ x(d, {
|
|
175
|
+
stickyHeader: !0,
|
|
176
|
+
size: F,
|
|
177
|
+
sx: A.table,
|
|
178
|
+
children: [Y, Z]
|
|
179
|
+
}) }), t[65] = F, t[66] = Y, t[67] = Z, t[68] = Q) : Q = t[68];
|
|
180
|
+
let $;
|
|
181
|
+
t[69] !== ae || t[70] !== B || t[71] !== T || t[72] !== E || t[73] !== a || t[74] !== o || t[75] !== I || t[76] !== re || t[77] !== i ? ($ = re ? /* @__PURE__ */ b(g, {
|
|
182
|
+
component: "div",
|
|
183
|
+
count: i,
|
|
184
|
+
page: a,
|
|
185
|
+
rowsPerPage: o,
|
|
186
|
+
rowsPerPageOptions: [...I],
|
|
187
|
+
onPageChange: (e, t) => T?.(t),
|
|
188
|
+
onRowsPerPageChange: (e) => {
|
|
189
|
+
let t = parseInt(e.target.value, 10);
|
|
190
|
+
E?.(t);
|
|
191
|
+
},
|
|
192
|
+
labelRowsPerPage: B.rowsPerPage,
|
|
193
|
+
labelDisplayedRows: (e) => {
|
|
194
|
+
let { from: t, to: n, count: r } = e;
|
|
195
|
+
return B.paginationOf(t, n, r);
|
|
196
|
+
},
|
|
197
|
+
ActionsComponent: ae,
|
|
198
|
+
sx: A.pagination
|
|
199
|
+
}) : null, t[69] = ae, t[70] = B, t[71] = T, t[72] = E, t[73] = a, t[74] = o, t[75] = I, t[76] = re, t[77] = i, t[78] = $) : $ = t[78];
|
|
200
|
+
let _e;
|
|
201
|
+
return t[79] !== Q || t[80] !== $ ? (_e = /* @__PURE__ */ x(s, {
|
|
202
|
+
sx: A.container,
|
|
203
|
+
children: [Q, $]
|
|
204
|
+
}), t[79] = Q, t[80] = $, t[81] = _e) : _e = t[81], _e;
|
|
205
|
+
}
|
|
206
|
+
function te(e) {
|
|
207
|
+
return e == null ? "" : typeof e == "string" || typeof e == "number" ? e : typeof e == "boolean" ? String(e) : Array.isArray(e) || typeof e == "object" ? JSON.stringify(e) : "";
|
|
208
|
+
}
|
|
209
|
+
function ne(e) {
|
|
210
|
+
return function({ count: t, page: n, rowsPerPage: r, onPageChange: i }) {
|
|
211
|
+
let a = Math.max(0, Math.ceil(t / r) - 1);
|
|
212
|
+
return /* @__PURE__ */ x(s, {
|
|
213
|
+
sx: A.paginationActions,
|
|
214
|
+
children: [
|
|
215
|
+
/* @__PURE__ */ b(l, {
|
|
216
|
+
size: "small",
|
|
217
|
+
onClick: (e) => i(e, 0),
|
|
218
|
+
disabled: n === 0,
|
|
219
|
+
"aria-label": e.firstPage,
|
|
220
|
+
children: /* @__PURE__ */ b(S, { fontSize: "small" })
|
|
221
|
+
}),
|
|
222
|
+
/* @__PURE__ */ b(l, {
|
|
223
|
+
size: "small",
|
|
224
|
+
onClick: (e) => i(e, n - 1),
|
|
225
|
+
disabled: n === 0,
|
|
226
|
+
"aria-label": e.previousPage,
|
|
227
|
+
children: /* @__PURE__ */ b(C, { fontSize: "small" })
|
|
228
|
+
}),
|
|
229
|
+
/* @__PURE__ */ b(l, {
|
|
230
|
+
size: "small",
|
|
231
|
+
onClick: (e) => i(e, n + 1),
|
|
232
|
+
disabled: n >= a,
|
|
233
|
+
"aria-label": e.nextPage,
|
|
234
|
+
children: /* @__PURE__ */ b(w, { fontSize: "small" })
|
|
235
|
+
}),
|
|
236
|
+
/* @__PURE__ */ b(l, {
|
|
237
|
+
size: "small",
|
|
238
|
+
onClick: (e) => i(e, a),
|
|
239
|
+
disabled: n >= a,
|
|
240
|
+
"aria-label": e.lastPage,
|
|
241
|
+
children: /* @__PURE__ */ b(T, { fontSize: "small" })
|
|
242
|
+
})
|
|
243
|
+
]
|
|
244
|
+
});
|
|
245
|
+
};
|
|
246
|
+
}
|
|
247
|
+
//#endregion
|
|
248
|
+
//#region src/widgets-v2/table/helpers.ts
|
|
249
|
+
function M(e, t, n) {
|
|
250
|
+
if (e == null && t == null) return 0;
|
|
251
|
+
if (e == null) return 1;
|
|
252
|
+
if (t == null) return -1;
|
|
253
|
+
let r = 0;
|
|
254
|
+
return typeof e == "string" && typeof t == "string" ? r = e.localeCompare(t) : typeof e == "number" && typeof t == "number" ? r = e - t : typeof e == "boolean" && typeof t == "boolean" ? r = e === t ? 0 : e ? 1 : -1 : (typeof e == "object" || typeof t == "object") && (r = JSON.stringify(e).localeCompare(JSON.stringify(t))), n === "asc" ? r : -r;
|
|
255
|
+
}
|
|
256
|
+
function N(e, t, n) {
|
|
257
|
+
return [...e].sort((e, r) => M(e[t], r[t], n));
|
|
258
|
+
}
|
|
259
|
+
function P(e, t, n) {
|
|
260
|
+
if (n <= 0) return e.slice();
|
|
261
|
+
let r = t * n;
|
|
262
|
+
return e.slice(r, r + n);
|
|
263
|
+
}
|
|
264
|
+
function F(e, t) {
|
|
265
|
+
if (!t || t.length === 0) return e;
|
|
266
|
+
let n = new Map(e.map((e) => [e.id, e])), r = [], i = /* @__PURE__ */ new Set();
|
|
267
|
+
for (let e of t) {
|
|
268
|
+
let t = n.get(e);
|
|
269
|
+
t && !i.has(e) && (r.push(t), i.add(e));
|
|
270
|
+
}
|
|
271
|
+
for (let t of e) i.has(t.id) || r.push(t);
|
|
272
|
+
return r;
|
|
273
|
+
}
|
|
274
|
+
function I(e, t) {
|
|
275
|
+
let n = t.sort?.columnId == null ? e : N(e, t.sort.columnId, t.sort.direction);
|
|
276
|
+
return {
|
|
277
|
+
sorted: n,
|
|
278
|
+
visible: P(n, t.page, t.pageSize)
|
|
279
|
+
};
|
|
280
|
+
}
|
|
281
|
+
function L(e, t) {
|
|
282
|
+
let n = [t.map((e) => R(e.label))];
|
|
283
|
+
for (let r of e) n.push(t.map((e) => z(r[e.id])));
|
|
284
|
+
return i(n);
|
|
285
|
+
}
|
|
286
|
+
function R(e) {
|
|
287
|
+
return typeof e == "string" ? e : typeof e == "number" || typeof e == "boolean" ? String(e) : "";
|
|
288
|
+
}
|
|
289
|
+
function z(e) {
|
|
290
|
+
return e == null ? "" : typeof e == "string" ? e : typeof e == "number" || typeof e == "boolean" ? String(e) : Array.isArray(e) || typeof e == "object" ? JSON.stringify(e) : "";
|
|
291
|
+
}
|
|
292
|
+
//#endregion
|
|
293
|
+
//#region src/widgets-v2/table/table.tsx
|
|
294
|
+
function B(i) {
|
|
295
|
+
let a = ee(59), o, s, c, l, u, d, f, p, m, h, g, _, v;
|
|
296
|
+
a[0] === i ? (o = a[1], s = a[2], c = a[3], l = a[4], u = a[5], d = a[6], f = a[7], p = a[8], m = a[9], h = a[10], g = a[11], _ = a[12], v = a[13]) : ({columns: o, visibleColumns: v, initialPageSize: h, selection: m, onSelectionChange: d, onRowClick: l, onRowHover: u, remote: g, total: p, onSortChange: f, onPageChange: s, onPageSizeChange: c, ..._} = i, a[0] = i, a[1] = o, a[2] = s, a[3] = c, a[4] = l, a[5] = u, a[6] = d, a[7] = f, a[8] = p, a[9] = m, a[10] = h, a[11] = g, a[12] = _, a[13] = v);
|
|
297
|
+
let y = h === void 0 ? 10 : h, x = g !== void 0 && g, S = n(), C = t(S, re), w;
|
|
298
|
+
a[14] === y ? w = a[15] : (w = (e) => ({
|
|
299
|
+
sort: e.sort,
|
|
300
|
+
page: e.page ?? 0,
|
|
301
|
+
pageSize: e.pageSize ?? y,
|
|
302
|
+
columnOrder: e.columnOrder
|
|
303
|
+
}), a[14] = y, a[15] = w);
|
|
304
|
+
let T = e(S, w), E;
|
|
305
|
+
if (a[16] !== o || a[17] !== T.columnOrder || a[18] !== v) {
|
|
306
|
+
let e = F(o, T.columnOrder);
|
|
307
|
+
E = v == null ? e : e.slice(0, v), a[16] = o, a[17] = T.columnOrder, a[18] = v, a[19] = E;
|
|
308
|
+
} else E = a[19];
|
|
309
|
+
let D = E, O;
|
|
310
|
+
bb0: {
|
|
311
|
+
if (x) {
|
|
312
|
+
let e;
|
|
313
|
+
a[20] === C ? e = a[21] : (e = C ?? [], a[20] = C, a[21] = e);
|
|
314
|
+
let t = p ?? 0, n;
|
|
315
|
+
a[22] !== e || a[23] !== t ? (n = {
|
|
316
|
+
rows: e,
|
|
317
|
+
totalRows: t
|
|
318
|
+
}, a[22] = e, a[23] = t, a[24] = n) : n = a[24], O = n;
|
|
319
|
+
break bb0;
|
|
320
|
+
}
|
|
321
|
+
let e;
|
|
322
|
+
a[25] === C ? e = a[26] : (e = C ?? [], a[25] = C, a[26] = e);
|
|
323
|
+
let t;
|
|
324
|
+
a[27] !== e || a[28] !== T.page || a[29] !== T.pageSize || a[30] !== T.sort ? (t = I(e, {
|
|
325
|
+
sort: T.sort,
|
|
326
|
+
page: T.page,
|
|
327
|
+
pageSize: T.pageSize
|
|
328
|
+
}), a[27] = e, a[28] = T.page, a[29] = T.pageSize, a[30] = T.sort, a[31] = t) : t = a[31];
|
|
329
|
+
let { sorted: n, visible: r } = t, i;
|
|
330
|
+
a[32] !== n.length || a[33] !== r ? (i = {
|
|
331
|
+
rows: r,
|
|
332
|
+
totalRows: n.length
|
|
333
|
+
}, a[32] = n.length, a[33] = r, a[34] = i) : i = a[34], O = i;
|
|
334
|
+
}
|
|
335
|
+
let { rows: k, totalRows: A } = O, te;
|
|
336
|
+
a[35] !== S || a[36] !== f ? (te = (e) => {
|
|
337
|
+
r(S).setState({
|
|
338
|
+
sort: e,
|
|
339
|
+
page: 0
|
|
340
|
+
}), f?.(e);
|
|
341
|
+
}, a[35] = S, a[36] = f, a[37] = te) : te = a[37];
|
|
342
|
+
let ne = te, M;
|
|
343
|
+
a[38] !== S || a[39] !== s ? (M = (e) => {
|
|
344
|
+
r(S).setState({ page: e }), s?.(e);
|
|
345
|
+
}, a[38] = S, a[39] = s, a[40] = M) : M = a[40];
|
|
346
|
+
let N = M, P;
|
|
347
|
+
a[41] !== S || a[42] !== c ? (P = (e) => {
|
|
348
|
+
r(S).setState({
|
|
349
|
+
pageSize: e,
|
|
350
|
+
page: 0
|
|
351
|
+
}), c?.(e);
|
|
352
|
+
}, a[41] = S, a[42] = c, a[43] = P) : P = a[43];
|
|
353
|
+
let L = P, R;
|
|
354
|
+
return a[44] !== N || a[45] !== L || a[46] !== ne || a[47] !== l || a[48] !== u || a[49] !== d || a[50] !== D || a[51] !== k || a[52] !== m || a[53] !== A || a[54] !== T.page || a[55] !== T.pageSize || a[56] !== T.sort || a[57] !== _ ? (R = /* @__PURE__ */ b(j, {
|
|
355
|
+
..._,
|
|
356
|
+
columns: D,
|
|
357
|
+
rows: k,
|
|
358
|
+
total: A,
|
|
359
|
+
page: T.page,
|
|
360
|
+
pageSize: T.pageSize,
|
|
361
|
+
sort: T.sort,
|
|
362
|
+
selection: m,
|
|
363
|
+
onSortChange: ne,
|
|
364
|
+
onPageChange: N,
|
|
365
|
+
onPageSizeChange: L,
|
|
366
|
+
onSelectionChange: d,
|
|
367
|
+
onRowClick: l,
|
|
368
|
+
onRowHover: u
|
|
369
|
+
}), a[44] = N, a[45] = L, a[46] = ne, a[47] = l, a[48] = u, a[49] = d, a[50] = D, a[51] = k, a[52] = m, a[53] = A, a[54] = T.page, a[55] = T.pageSize, a[56] = T.sort, a[57] = _, a[58] = R) : R = a[58], R;
|
|
370
|
+
}
|
|
371
|
+
function re(e) {
|
|
372
|
+
return e.data;
|
|
373
|
+
}
|
|
374
|
+
//#endregion
|
|
375
|
+
//#region src/widgets-v2/table/skeleton.tsx
|
|
376
|
+
function ie(e) {
|
|
377
|
+
let t = ee(11), { rows: n, columns: r, size: i } = e, a = n === void 0 ? 5 : n, o = r === void 0 ? 4 : r, c;
|
|
378
|
+
t[0] === o ? c = t[1] : (c = /* @__PURE__ */ b(h, { children: /* @__PURE__ */ b(_, { children: Array.from({ length: o }).map(ae) }) }), t[0] = o, t[1] = c);
|
|
379
|
+
let l;
|
|
380
|
+
t[2] === a ? l = t[3] : (l = Array.from({ length: a }), t[2] = a, t[3] = l);
|
|
381
|
+
let m;
|
|
382
|
+
t[4] !== o || t[5] !== l ? (m = /* @__PURE__ */ b(f, { children: l.map((e, t) => /* @__PURE__ */ b(_, {
|
|
383
|
+
sx: A.row,
|
|
384
|
+
children: Array.from({ length: o }).map((e, n) => /* @__PURE__ */ b(p, { children: /* @__PURE__ */ b(u, {
|
|
385
|
+
variant: "text",
|
|
386
|
+
width: "70%",
|
|
387
|
+
height: 20
|
|
388
|
+
}) }, `cell-${t}-${n}`))
|
|
389
|
+
}, `row-${t}`)) }), t[4] = o, t[5] = l, t[6] = m) : m = t[6];
|
|
390
|
+
let g;
|
|
391
|
+
return t[7] !== i || t[8] !== c || t[9] !== m ? (g = /* @__PURE__ */ b(s, {
|
|
392
|
+
sx: A.container,
|
|
393
|
+
"aria-label": "Table skeleton",
|
|
394
|
+
children: /* @__PURE__ */ x(d, {
|
|
395
|
+
size: i,
|
|
396
|
+
sx: A.table,
|
|
397
|
+
stickyHeader: !0,
|
|
398
|
+
children: [c, m]
|
|
399
|
+
})
|
|
400
|
+
}), t[7] = i, t[8] = c, t[9] = m, t[10] = g) : g = t[10], g;
|
|
401
|
+
}
|
|
402
|
+
function ae(e, t) {
|
|
403
|
+
return /* @__PURE__ */ b(p, {
|
|
404
|
+
sx: A.headerCell,
|
|
405
|
+
children: /* @__PURE__ */ b(u, {
|
|
406
|
+
variant: "text",
|
|
407
|
+
width: "80%",
|
|
408
|
+
height: 24
|
|
409
|
+
})
|
|
410
|
+
}, `head-${t}`);
|
|
411
|
+
}
|
|
412
|
+
//#endregion
|
|
413
|
+
//#region src/widgets-v2/table/download.ts
|
|
414
|
+
function V(e) {
|
|
415
|
+
let t = [];
|
|
416
|
+
return e.getCaptureEl && t.push(a({
|
|
417
|
+
filename: e.filename,
|
|
418
|
+
getCaptureEl: e.getCaptureEl,
|
|
419
|
+
pixelRatio: e.pngPixelRatio,
|
|
420
|
+
backgroundColor: e.pngBackgroundColor
|
|
421
|
+
})), t.push(o({
|
|
422
|
+
filename: e.filename,
|
|
423
|
+
getCsv: () => L(e.getData(), e.columns)
|
|
424
|
+
})), t;
|
|
425
|
+
}
|
|
426
|
+
//#endregion
|
|
427
|
+
//#region src/widgets-v2/table/transforms.ts
|
|
428
|
+
function oe(e, t, n = "id") {
|
|
429
|
+
if (t.length === 0 || !Array.isArray(e)) return e;
|
|
430
|
+
let r = new Set(t);
|
|
431
|
+
return e.filter((e, t) => {
|
|
432
|
+
if (typeof e != "object" || !e) return !1;
|
|
433
|
+
let i = e[n] ?? t;
|
|
434
|
+
return (typeof i == "string" || typeof i == "number") && r.has(i);
|
|
435
|
+
});
|
|
436
|
+
}
|
|
437
|
+
//#endregion
|
|
438
|
+
export { M as a, F as c, j as d, O as f, B as i, N as l, D as m, V as n, I as o, k as p, ie as r, P as s, oe as t, L as u };
|
|
439
|
+
|
|
440
|
+
//# sourceMappingURL=table-Bx9Uj3U0.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"table-Bx9Uj3U0.js","names":["{\n columns,\n rows,\n total,\n page,\n pageSize,\n pageSizeOptions = DEFAULT_TABLE_PAGE_SIZE_OPTIONS,\n sort,\n keyColumn = 'id',\n selection,\n selectable = false,\n onSortChange,\n onPageChange,\n onPageSizeChange,\n onSelectionChange,\n onRowClick,\n onRowHover,\n labels,\n emptyContent,\n size,\n}: TableUIProps<T>","pageSizeOptions = DEFAULT_TABLE_PAGE_SIZE_OPTIONS","keyColumn = 'id'","selectable = false","{ ...DEFAULT_TABLE_LABELS, ...labels }","useMemo(\n () => ({ ...DEFAULT_TABLE_LABELS, ...labels }),\n [labels],\n )","makePaginationActions(_labels)","useMemo(\n () => makePaginationActions(_labels),\n [_labels],\n )","selection ?? []","new Set<string | number>(selection ?? [])","useMemo(\n () => new Set<string | number>(selection ?? []),\n [selection],\n )","(row: T, index: number): string | number =>\n (row[keyColumn] ?? index) as string | number","useCallback(\n (row: T, index: number): string | number =>\n (row[keyColumn] ?? index) as string | number,\n [keyColumn],\n )","rows.map(resolveRowId)","useMemo(() => rows.map(resolveRowId), [rows, resolveRowId])","pageRowIds.length > 0 && pageRowIds.every((id) => selectionSet.has(id))","pageRowIds.length","!allOnPageSelected && pageRowIds.some((id) => selectionSet.has(id))","id","(columnId: string) => {\n if (!onSortChange) return\n const sameCol = sort?.columnId === columnId\n const nextDir: TableSortDirection =\n sameCol && sort?.direction === 'asc' ? 'desc' : 'asc'\n onSortChange({ columnId, direction: nextDir })\n }","columnId","direction","() => {\n if (!onSelectionChange) return\n if (allOnPageSelected) {\n onSelectionChange(\n (selection ?? []).filter((id) => !pageRowIds.includes(id)),\n )\n } else {\n const merged = new Set<string | number>(selection ?? [])\n for (const id of pageRowIds) merged.add(id)\n onSelectionChange([...merged])\n }\n }","(rowId: string | number) => {\n if (!onSelectionChange) return\n const next = new Set<string | number>(selection ?? [])\n if (next.has(rowId)) next.delete(rowId)\n else next.add(rowId)\n onSelectionChange([...next])\n }","selectable ? (\n <TableCell padding='checkbox' sx={styles.headerCell}>\n <Checkbox\n checked={allOnPageSelected}\n indeterminate={someOnPageSelected}\n onChange={handleSelectAllOnPage}\n inputProps={{ 'aria-label': _labels.selectAll }}\n />\n </TableCell>\n ) : null","_labels.selectAll","columns.map((column) => {\n const isSorted = sort?.columnId === column.id\n const direction = isSorted ? sort?.direction : undefined\n return (\n <TableCell\n key={column.id}\n align={column.align}\n sortDirection={direction}\n sx={styles.headerCell}\n style={\n column.width != null ? { width: column.width } : undefined\n }\n >\n {column.sortable && onSortChange ? (\n <TableSortLabel\n active={isSorted}\n direction={direction ?? 'asc'}\n onClick={() => handleSort(column.id)}\n >\n {column.label}\n </TableSortLabel>\n ) : (\n column.label\n )}\n </TableCell>\n )\n })","(column) => {\n const isSorted = sort?.columnId === column.id\n const direction = isSorted ? sort?.direction : undefined\n return (\n <TableCell\n key={column.id}\n align={column.align}\n sortDirection={direction}\n sx={styles.headerCell}\n style={\n column.width != null ? { width: column.width } : undefined\n }\n >\n {column.sortable && onSortChange ? (\n <TableSortLabel\n active={isSorted}\n direction={direction ?? 'asc'}\n onClick={() => handleSort(column.id)}\n >\n {column.label}\n </TableSortLabel>\n ) : (\n column.label\n )}\n </TableCell>\n )\n }","<TableHead>\n <MuiTableRow>\n {selectable ? (\n <TableCell padding='checkbox' sx={styles.headerCell}>\n <Checkbox\n checked={allOnPageSelected}\n indeterminate={someOnPageSelected}\n onChange={handleSelectAllOnPage}\n inputProps={{ 'aria-label': _labels.selectAll }}\n />\n </TableCell>\n ) : null}\n {columns.map((column) => {\n const isSorted = sort?.columnId === column.id\n const direction = isSorted ? sort?.direction : undefined\n return (\n <TableCell\n key={column.id}\n align={column.align}\n sortDirection={direction}\n sx={styles.headerCell}\n style={\n column.width != null ? { width: column.width } : undefined\n }\n >\n {column.sortable && onSortChange ? (\n <TableSortLabel\n active={isSorted}\n direction={direction ?? 'asc'}\n onClick={() => handleSort(column.id)}\n >\n {column.label}\n </TableSortLabel>\n ) : (\n column.label\n )}\n </TableCell>\n )\n })}\n </MuiTableRow>\n </TableHead>","rows.length === 0 ? (\n <MuiTableRow>\n <TableCell\n colSpan={columns.length + (selectable ? 1 : 0)}\n sx={styles.empty}\n >\n {emptyContent ?? null}\n </TableCell>\n </MuiTableRow>\n ) : (\n rows.map((row, index) => {\n const rowId = resolveRowId(row, index)\n const isSelected = selectionSet.has(rowId)\n return (\n <MuiTableRow\n key={rowId}\n hover\n selected={isSelected}\n onClick={() => onRowClick?.(row)}\n onMouseEnter={() => onRowHover?.(row)}\n onMouseLeave={() => onRowHover?.(null)}\n sx={{\n ...styles.row,\n ...(onRowClick ? styles.rowClickable : null),\n }}\n >\n {selectable ? (\n <TableCell padding='checkbox'>\n <Checkbox\n checked={isSelected}\n onClick={(e) => {\n e.stopPropagation()\n handleSelectRow(rowId)\n }}\n inputProps={{\n 'aria-label': _labels.selectRow(rowId),\n }}\n />\n </TableCell>\n ) : null}\n {columns.map((column) => (\n <TableCell key={column.id} align={column.align}>\n {column.formatter\n ? column.formatter(row[column.id], row)\n : stringifyCell(row[column.id])}\n </TableCell>\n ))}\n </MuiTableRow>\n )\n })\n )","columns.length","rows.length","rowId","row","index","column","<TableBody>\n {rows.length === 0 ? (\n <MuiTableRow>\n <TableCell\n colSpan={columns.length + (selectable ? 1 : 0)}\n sx={styles.empty}\n >\n {emptyContent ?? null}\n </TableCell>\n </MuiTableRow>\n ) : (\n rows.map((row, index) => {\n const rowId = resolveRowId(row, index)\n const isSelected = selectionSet.has(rowId)\n return (\n <MuiTableRow\n key={rowId}\n hover\n selected={isSelected}\n onClick={() => onRowClick?.(row)}\n onMouseEnter={() => onRowHover?.(row)}\n onMouseLeave={() => onRowHover?.(null)}\n sx={{\n ...styles.row,\n ...(onRowClick ? styles.rowClickable : null),\n }}\n >\n {selectable ? (\n <TableCell padding='checkbox'>\n <Checkbox\n checked={isSelected}\n onClick={(e) => {\n e.stopPropagation()\n handleSelectRow(rowId)\n }}\n inputProps={{\n 'aria-label': _labels.selectRow(rowId),\n }}\n />\n </TableCell>\n ) : null}\n {columns.map((column) => (\n <TableCell key={column.id} align={column.align}>\n {column.formatter\n ? column.formatter(row[column.id], row)\n : stringifyCell(row[column.id])}\n </TableCell>\n ))}\n </MuiTableRow>\n )\n })\n )}\n </TableBody>","<TableContainer>\n <MuiTable stickyHeader size={size} sx={styles.table}>\n <TableHead>\n <MuiTableRow>\n {selectable ? (\n <TableCell padding='checkbox' sx={styles.headerCell}>\n <Checkbox\n checked={allOnPageSelected}\n indeterminate={someOnPageSelected}\n onChange={handleSelectAllOnPage}\n inputProps={{ 'aria-label': _labels.selectAll }}\n />\n </TableCell>\n ) : null}\n {columns.map((column) => {\n const isSorted = sort?.columnId === column.id\n const direction = isSorted ? sort?.direction : undefined\n return (\n <TableCell\n key={column.id}\n align={column.align}\n sortDirection={direction}\n sx={styles.headerCell}\n style={\n column.width != null ? { width: column.width } : undefined\n }\n >\n {column.sortable && onSortChange ? (\n <TableSortLabel\n active={isSorted}\n direction={direction ?? 'asc'}\n onClick={() => handleSort(column.id)}\n >\n {column.label}\n </TableSortLabel>\n ) : (\n column.label\n )}\n </TableCell>\n )\n })}\n </MuiTableRow>\n </TableHead>\n <TableBody>\n {rows.length === 0 ? (\n <MuiTableRow>\n <TableCell\n colSpan={columns.length + (selectable ? 1 : 0)}\n sx={styles.empty}\n >\n {emptyContent ?? null}\n </TableCell>\n </MuiTableRow>\n ) : (\n rows.map((row, index) => {\n const rowId = resolveRowId(row, index)\n const isSelected = selectionSet.has(rowId)\n return (\n <MuiTableRow\n key={rowId}\n hover\n selected={isSelected}\n onClick={() => onRowClick?.(row)}\n onMouseEnter={() => onRowHover?.(row)}\n onMouseLeave={() => onRowHover?.(null)}\n sx={{\n ...styles.row,\n ...(onRowClick ? styles.rowClickable : null),\n }}\n >\n {selectable ? (\n <TableCell padding='checkbox'>\n <Checkbox\n checked={isSelected}\n onClick={(e) => {\n e.stopPropagation()\n handleSelectRow(rowId)\n }}\n inputProps={{\n 'aria-label': _labels.selectRow(rowId),\n }}\n />\n </TableCell>\n ) : null}\n {columns.map((column) => (\n <TableCell key={column.id} align={column.align}>\n {column.formatter\n ? column.formatter(row[column.id], row)\n : stringifyCell(row[column.id])}\n </TableCell>\n ))}\n </MuiTableRow>\n )\n })\n )}\n </TableBody>\n </MuiTable>\n </TableContainer>","showPagination ? (\n <TablePagination\n component='div'\n count={total}\n page={page}\n rowsPerPage={pageSize}\n rowsPerPageOptions={[...pageSizeOptions]}\n onPageChange={(_, next) => onPageChange?.(next)}\n onRowsPerPageChange={(e) => {\n const next = parseInt(e.target.value, 10)\n onPageSizeChange?.(next)\n }}\n labelRowsPerPage={_labels.rowsPerPage}\n labelDisplayedRows={({ from, to, count }) =>\n _labels.paginationOf(from, to, count)\n }\n ActionsComponent={PaginationActions}\n sx={styles.pagination}\n />\n ) : null","next","e","{ from, to, count }","<Box sx={styles.container}>\n <TableContainer>\n <MuiTable stickyHeader size={size} sx={styles.table}>\n <TableHead>\n <MuiTableRow>\n {selectable ? (\n <TableCell padding='checkbox' sx={styles.headerCell}>\n <Checkbox\n checked={allOnPageSelected}\n indeterminate={someOnPageSelected}\n onChange={handleSelectAllOnPage}\n inputProps={{ 'aria-label': _labels.selectAll }}\n />\n </TableCell>\n ) : null}\n {columns.map((column) => {\n const isSorted = sort?.columnId === column.id\n const direction = isSorted ? sort?.direction : undefined\n return (\n <TableCell\n key={column.id}\n align={column.align}\n sortDirection={direction}\n sx={styles.headerCell}\n style={\n column.width != null ? { width: column.width } : undefined\n }\n >\n {column.sortable && onSortChange ? (\n <TableSortLabel\n active={isSorted}\n direction={direction ?? 'asc'}\n onClick={() => handleSort(column.id)}\n >\n {column.label}\n </TableSortLabel>\n ) : (\n column.label\n )}\n </TableCell>\n )\n })}\n </MuiTableRow>\n </TableHead>\n <TableBody>\n {rows.length === 0 ? (\n <MuiTableRow>\n <TableCell\n colSpan={columns.length + (selectable ? 1 : 0)}\n sx={styles.empty}\n >\n {emptyContent ?? null}\n </TableCell>\n </MuiTableRow>\n ) : (\n rows.map((row, index) => {\n const rowId = resolveRowId(row, index)\n const isSelected = selectionSet.has(rowId)\n return (\n <MuiTableRow\n key={rowId}\n hover\n selected={isSelected}\n onClick={() => onRowClick?.(row)}\n onMouseEnter={() => onRowHover?.(row)}\n onMouseLeave={() => onRowHover?.(null)}\n sx={{\n ...styles.row,\n ...(onRowClick ? styles.rowClickable : null),\n }}\n >\n {selectable ? (\n <TableCell padding='checkbox'>\n <Checkbox\n checked={isSelected}\n onClick={(e) => {\n e.stopPropagation()\n handleSelectRow(rowId)\n }}\n inputProps={{\n 'aria-label': _labels.selectRow(rowId),\n }}\n />\n </TableCell>\n ) : null}\n {columns.map((column) => (\n <TableCell key={column.id} align={column.align}>\n {column.formatter\n ? column.formatter(row[column.id], row)\n : stringifyCell(row[column.id])}\n </TableCell>\n ))}\n </MuiTableRow>\n )\n })\n )}\n </TableBody>\n </MuiTable>\n </TableContainer>\n {showPagination ? (\n <TablePagination\n component='div'\n count={total}\n page={page}\n rowsPerPage={pageSize}\n rowsPerPageOptions={[...pageSizeOptions]}\n onPageChange={(_, next) => onPageChange?.(next)}\n onRowsPerPageChange={(e) => {\n const next = parseInt(e.target.value, 10)\n onPageSizeChange?.(next)\n }}\n labelRowsPerPage={_labels.rowsPerPage}\n labelDisplayedRows={({ from, to, count }) =>\n _labels.paginationOf(from, to, count)\n }\n ActionsComponent={PaginationActions}\n sx={styles.pagination}\n />\n ) : null}\n </Box>","initialPageSize = DEFAULT_TABLE_PAGE_SIZE","remote = false","{\n columns,\n visibleColumns,\n initialPageSize = DEFAULT_TABLE_PAGE_SIZE,\n selection,\n onSelectionChange,\n onRowClick,\n onRowHover,\n remote = false,\n total: remoteTotal,\n onSortChange,\n onPageChange,\n onPageSizeChange,\n ...uiProps\n}: TableProps<T>","(s) => s.data as readonly T[] | undefined","(s) => ({\n sort: s.sort,\n page: s.page ?? 0,\n pageSize: s.pageSize ?? initialPageSize,\n columnOrder: s.columnOrder,\n })","s","visibleColumns == null\n ? reordered\n : reordered.slice(0, visibleColumns)","columnOrder","useMemo(() => {\n const reordered = resolveColumns(columns, ui.columnOrder)\n return visibleColumns == null\n ? reordered\n : reordered.slice(0, visibleColumns)\n }, [columns, ui.columnOrder, visibleColumns])","useMemo(() => {\n if (remote) {\n return {\n rows: data ?? [],\n totalRows: remoteTotal ?? 0,\n }\n }\n const { sorted, visible } = deriveVisibleRows(data ?? [], {\n sort: ui.sort,\n page: ui.page,\n pageSize: ui.pageSize,\n })\n return { rows: visible, totalRows: sorted.length }\n }, [remote, data, remoteTotal, ui.sort, ui.page, ui.pageSize])","data ?? []","{\n rows: data ?? [],\n totalRows: remoteTotal ?? 0,\n }","remoteTotal ?? 0","deriveVisibleRows(data ?? [], {\n sort: ui.sort,\n page: ui.page,\n pageSize: ui.pageSize,\n })","page","pageSize","sort","{ rows: visible, totalRows: sorted.length }","length","(next: TableSortState) => {\n getWidgetStore(id).setState({\n sort: next,\n page: 0,\n } as Partial<TableWidgetState>)\n onSortChange?.(next)\n }","useCallback(\n (next: TableSortState) => {\n getWidgetStore(id).setState({\n sort: next,\n page: 0,\n } as Partial<TableWidgetState>)\n onSortChange?.(next)\n },\n [id, onSortChange],\n )","(page: number) => {\n getWidgetStore(id).setState({ page } as Partial<TableWidgetState>)\n onPageChange?.(page)\n }","useCallback(\n (page: number) => {\n getWidgetStore(id).setState({ page } as Partial<TableWidgetState>)\n onPageChange?.(page)\n },\n [id, onPageChange],\n )","(pageSize: number) => {\n getWidgetStore(id).setState({\n pageSize,\n page: 0,\n } as Partial<TableWidgetState>)\n onPageSizeChange?.(pageSize)\n }","useCallback(\n (pageSize: number) => {\n getWidgetStore(id).setState({\n pageSize,\n page: 0,\n } as Partial<TableWidgetState>)\n onPageSizeChange?.(pageSize)\n },\n [id, onPageSizeChange],\n )","<TableUI\n {...uiProps}\n columns={orderedColumns}\n rows={rows}\n total={totalRows}\n page={ui.page}\n pageSize={ui.pageSize}\n sort={ui.sort}\n selection={selection}\n onSortChange={handleSortChange}\n onPageChange={handlePageChange}\n onPageSizeChange={handlePageSizeChange}\n onSelectionChange={onSelectionChange}\n onRowClick={onRowClick}\n onRowHover={onRowHover}\n />","{\n rows = 5,\n columns = 4,\n size,\n}: TableSkeletonProps","rows = 5","columns = 4","<TableHead>\n <MuiTableRow>\n {Array.from({ length: columns }).map((_, c) => (\n <TableCell key={`head-${c}`} sx={styles.headerCell}>\n <Skeleton variant='text' width='80%' height={24} />\n </TableCell>\n ))}\n </MuiTableRow>\n </TableHead>","(_, c) => (\n <TableCell key={`head-${c}`} sx={styles.headerCell}>\n <Skeleton variant='text' width='80%' height={24} />\n </TableCell>\n )","Array.from({ length: rows })","<TableBody>\n {Array.from({ length: rows }).map((_, r) => (\n <MuiTableRow key={`row-${r}`} sx={styles.row}>\n {Array.from({ length: columns }).map((__, c) => (\n <TableCell key={`cell-${r}-${c}`}>\n <Skeleton variant='text' width='70%' height={20} />\n </TableCell>\n ))}\n </MuiTableRow>\n ))}\n </TableBody>","c","<Box sx={styles.container} aria-label='Table skeleton'>\n <MuiTable size={size} sx={styles.table} stickyHeader>\n <TableHead>\n <MuiTableRow>\n {Array.from({ length: columns }).map((_, c) => (\n <TableCell key={`head-${c}`} sx={styles.headerCell}>\n <Skeleton variant='text' width='80%' height={24} />\n </TableCell>\n ))}\n </MuiTableRow>\n </TableHead>\n <TableBody>\n {Array.from({ length: rows }).map((_, r) => (\n <MuiTableRow key={`row-${r}`} sx={styles.row}>\n {Array.from({ length: columns }).map((__, c) => (\n <TableCell key={`cell-${r}-${c}`}>\n <Skeleton variant='text' width='70%' height={20} />\n </TableCell>\n ))}\n </MuiTableRow>\n ))}\n </TableBody>\n </MuiTable>\n </Box>"],"sources":["../src/widgets-v2/table/labels.tsx","../src/widgets-v2/table/types.ts","../src/widgets-v2/table/style.ts","../src/widgets-v2/table/table-ui.tsx","../src/widgets-v2/table/helpers.ts","../src/widgets-v2/table/table.tsx","../src/widgets-v2/table/skeleton.tsx","../src/widgets-v2/table/download.ts","../src/widgets-v2/table/transforms.ts"],"sourcesContent":["import { Box, type SxProps, type Theme } from '@mui/material'\nimport type { ReactNode } from 'react'\n\nexport interface TableLabels {\n selectAll: string\n selectRow: (rowId: string | number) => string\n rowsPerPage: string\n /**\n * Renders the displayed-rows summary in the pagination footer. Returns\n * a `ReactNode` so the default can emphasise the active range\n * (`from-to`) with a bolder weight while keeping the trailing\n * ` of total` muted. Override to localise wording or restyle.\n */\n paginationOf: (from: number, to: number, total: number) => ReactNode\n /** aria-label for the first-page pagination button. */\n firstPage: string\n /** aria-label for the previous-page pagination button. */\n previousPage: string\n /** aria-label for the next-page pagination button. */\n nextPage: string\n /** aria-label for the last-page pagination button. */\n lastPage: string\n}\n\nconst boldRange: SxProps<Theme> = { fontWeight: 600, color: 'text.primary' }\n\nexport const DEFAULT_TABLE_LABELS: TableLabels = {\n selectAll: 'Select all rows',\n selectRow: (id) => `Select row ${id}`,\n rowsPerPage: 'Rows per page:',\n paginationOf: (from, to, total) => (\n <>\n <Box component='span' sx={boldRange}>{`${from}–${to}`}</Box>\n {` of ${total}`}\n </>\n ),\n firstPage: 'First page',\n previousPage: 'Previous page',\n nextPage: 'Next page',\n lastPage: 'Last page',\n}\n","import type { ReactNode } from 'react'\nimport type { WidgetState } from '../stores'\n\n/**\n * Single row of tabular data.\n *\n * The default row-identity column is `id`. Consumers that don't have a\n * literal `id` field can point `<Table>` / `<TableUI>` at a different\n * column via the `keyColumn` prop; the library reads `row[keyColumn]`\n * for selection lookup, React keys, and aria labels.\n */\nexport interface TableRow extends Record<string, unknown> {\n /**\n * Default row identity. Required when no `keyColumn` is configured.\n * Omit when wiring `keyColumn` to a different column.\n */\n id?: string | number\n}\n\nexport type TableWidgetData = readonly TableRow[]\n\nexport type TableSortDirection = 'asc' | 'desc'\n\nexport interface TableSortState {\n columnId: string | null\n direction: TableSortDirection\n}\n\nexport interface TableColumn {\n /** Unique column identifier; matches the field name on each row. */\n id: string\n /** Header label. */\n label: ReactNode\n align?: 'left' | 'center' | 'right'\n width?: number | string\n sortable?: boolean\n /** Custom cell renderer. Falls back to a string-cast of the raw value. */\n formatter?: (value: unknown, row: TableRow) => ReactNode\n}\n\n/**\n * State extension carrying Table-specific UI state on the per-widget store.\n * Per R12: widget-specific UI state lives in widget-specific extensions of\n * `WidgetState`, not on the base type.\n */\nexport interface TableWidgetState extends WidgetState {\n /** Optional reordered column list driven by ChangeColumn. Falls back to props. */\n columnOrder?: readonly string[]\n sort?: TableSortState\n page: number\n pageSize: number\n}\n\nexport const DEFAULT_TABLE_PAGE_SIZE = 10\nexport const DEFAULT_TABLE_PAGE_SIZE_OPTIONS = [10, 25, 50, 100] as const\n","import type { SxProps, Theme } from '@mui/material'\n\nexport const styles = {\n container: {\n width: '100%',\n overflowX: 'auto',\n },\n\n table: {\n minWidth: 0,\n },\n headerCell: {\n fontWeight: 600,\n backgroundColor: 'background.paper',\n },\n /**\n * Strip the bottom border from the last body row so the body flushes\n * against the pagination border instead of doubling it up. Mirrors v1.\n */\n row: {\n '&:last-child td, &:last-child th': {\n border: 0,\n },\n },\n rowClickable: {\n cursor: 'pointer',\n },\n pagination: {\n borderTop: '1px solid',\n borderColor: 'divider',\n },\n paginationActions: {\n display: 'flex',\n alignItems: 'center',\n gap: 0.25,\n ml: 1,\n },\n empty: {\n textAlign: 'center',\n color: 'text.secondary',\n py: 3,\n },\n} satisfies Record<string, SxProps<Theme>>\n","import { useCallback, useMemo } from 'react'\nimport {\n Box,\n Checkbox,\n IconButton,\n Table as MuiTable,\n TableBody,\n TableCell,\n TableContainer,\n TableHead,\n TablePagination,\n TableRow as MuiTableRow,\n TableSortLabel,\n type TableProps as MuiTableProps,\n} from '@mui/material'\nimport type { TablePaginationActionsProps } from '@mui/material/TablePagination/TablePaginationActions'\nimport { FirstPage as FirstPageIcon } from '@mui/icons-material'\nimport { KeyboardArrowLeft } from '@mui/icons-material'\nimport { KeyboardArrowRight } from '@mui/icons-material'\nimport { LastPage as LastPageIcon } from '@mui/icons-material'\nimport { DEFAULT_TABLE_LABELS, type TableLabels } from './labels'\nimport {\n DEFAULT_TABLE_PAGE_SIZE_OPTIONS,\n type TableColumn,\n type TableRow,\n type TableSortDirection,\n type TableSortState,\n} from './types'\nimport { styles } from './style'\n\nexport interface TableUIProps<T extends TableRow = TableRow> {\n columns: readonly TableColumn[]\n /** Already-paginated, already-sorted rows for the current view. */\n rows: readonly T[]\n /** Total row count (across all pages). Required for pagination footer. */\n total: number\n page: number\n pageSize: number\n pageSizeOptions?: readonly number[]\n sort?: TableSortState\n /**\n * Column name to use as the row identity. Drives selection lookup,\n * React keys, and aria labels. Defaults to `'id'` — point it at\n * another column when your rows don't carry an `id` field.\n */\n keyColumn?: string\n /** Selected row ids. Destination-owned. */\n selection?: readonly (string | number)[]\n selectable?: boolean\n onSortChange?: (next: TableSortState) => void\n onPageChange?: (page: number) => void\n onPageSizeChange?: (pageSize: number) => void\n onSelectionChange?: (next: readonly (string | number)[]) => void\n onRowClick?: (row: T) => void\n onRowHover?: (row: T | null) => void\n labels?: Partial<TableLabels>\n /** Row rendered when `rows` is empty for the current page. */\n emptyContent?: React.ReactNode\n /**\n * Forwarded to MUI's `<Table size>` — `'small'` for compact rows,\n * `'medium'` for the default density. Leave `undefined` (the default)\n * to let MUI's own default kick in.\n */\n size?: MuiTableProps['size']\n}\n\n/**\n * Pure renderer for a paginated, sortable, optionally-selectable table.\n * Has no widget-store coupling — `<Table>` (the bridge) reads from the store\n * and feeds this UI with already-projected data.\n */\nexport function TableUI<T extends TableRow = TableRow>({\n columns,\n rows,\n total,\n page,\n pageSize,\n pageSizeOptions = DEFAULT_TABLE_PAGE_SIZE_OPTIONS,\n sort,\n keyColumn = 'id',\n selection,\n selectable = false,\n onSortChange,\n onPageChange,\n onPageSizeChange,\n onSelectionChange,\n onRowClick,\n onRowHover,\n labels,\n emptyContent,\n size,\n}: TableUIProps<T>) {\n if (process.env.NODE_ENV !== 'production') {\n // Dev-time guard: a nullish identity collapses every row into the\n // same selection-set entry, which manifests as \"click one → all\n // appear selected\". Surface it loudly instead of silently degrading.\n const missing = rows.some((r) => r[keyColumn] == null)\n if (missing) {\n // eslint-disable-next-line no-console\n console.error(\n `<TableUI>: rows are missing the identity column \\`${keyColumn}\\`. ` +\n 'Set the `keyColumn` prop to a column present on every row, or ' +\n 'add the column to the data.',\n )\n }\n }\n const _labels = useMemo(\n () => ({ ...DEFAULT_TABLE_LABELS, ...labels }),\n [labels],\n )\n // Auto-hide the pagination footer when every row already fits in the\n // smallest available page size — the Rows-per-page selector + prev /\n // next buttons would just be inert noise. Consumers force the footer\n // on by passing a smaller `pageSizeOptions[0]` than `total`.\n const minPageSize = Math.min(...pageSizeOptions)\n const showPagination = total > minPageSize\n // Own the `ActionsComponent` slot ourselves so the Meridian theme's\n // `theme.components.MuiTablePagination.defaultProps.ActionsComponent`\n // (which depends on `react-intl`) doesn't leak into the library. The\n // MUI / Meridian style overrides for `MuiIconButton` /\n // `MuiTablePagination` still apply.\n const PaginationActions = useMemo(\n () => makePaginationActions(_labels),\n [_labels],\n )\n const selectionSet = useMemo(\n () => new Set<string | number>(selection ?? []),\n [selection],\n )\n // Resolve each row's identity from `keyColumn`, falling back to the row's\n // index when the cell is nullish. The dev-time guard above surfaces the\n // misconfiguration loudly, but in production we must NOT collapse every\n // nullish-keyed row into the same selection-set entry (that's the\n // \"click one → all selected\" bug) — a per-index fallback keeps ids\n // distinct and React keys stable for a given page.\n const resolveRowId = useCallback(\n (row: T, index: number): string | number =>\n (row[keyColumn] ?? index) as string | number,\n [keyColumn],\n )\n const pageRowIds = useMemo(() => rows.map(resolveRowId), [rows, resolveRowId])\n const allOnPageSelected =\n pageRowIds.length > 0 && pageRowIds.every((id) => selectionSet.has(id))\n const someOnPageSelected =\n !allOnPageSelected && pageRowIds.some((id) => selectionSet.has(id))\n\n const handleSort = (columnId: string) => {\n if (!onSortChange) return\n const sameCol = sort?.columnId === columnId\n const nextDir: TableSortDirection =\n sameCol && sort?.direction === 'asc' ? 'desc' : 'asc'\n onSortChange({ columnId, direction: nextDir })\n }\n\n const handleSelectAllOnPage = () => {\n if (!onSelectionChange) return\n if (allOnPageSelected) {\n onSelectionChange(\n (selection ?? []).filter((id) => !pageRowIds.includes(id)),\n )\n } else {\n const merged = new Set<string | number>(selection ?? [])\n for (const id of pageRowIds) merged.add(id)\n onSelectionChange([...merged])\n }\n }\n\n const handleSelectRow = (rowId: string | number) => {\n if (!onSelectionChange) return\n const next = new Set<string | number>(selection ?? [])\n if (next.has(rowId)) next.delete(rowId)\n else next.add(rowId)\n onSelectionChange([...next])\n }\n\n return (\n <Box sx={styles.container}>\n <TableContainer>\n <MuiTable stickyHeader size={size} sx={styles.table}>\n <TableHead>\n <MuiTableRow>\n {selectable ? (\n <TableCell padding='checkbox' sx={styles.headerCell}>\n <Checkbox\n checked={allOnPageSelected}\n indeterminate={someOnPageSelected}\n onChange={handleSelectAllOnPage}\n inputProps={{ 'aria-label': _labels.selectAll }}\n />\n </TableCell>\n ) : null}\n {columns.map((column) => {\n const isSorted = sort?.columnId === column.id\n const direction = isSorted ? sort?.direction : undefined\n return (\n <TableCell\n key={column.id}\n align={column.align}\n sortDirection={direction}\n sx={styles.headerCell}\n style={\n column.width != null ? { width: column.width } : undefined\n }\n >\n {column.sortable && onSortChange ? (\n <TableSortLabel\n active={isSorted}\n direction={direction ?? 'asc'}\n onClick={() => handleSort(column.id)}\n >\n {column.label}\n </TableSortLabel>\n ) : (\n column.label\n )}\n </TableCell>\n )\n })}\n </MuiTableRow>\n </TableHead>\n <TableBody>\n {rows.length === 0 ? (\n <MuiTableRow>\n <TableCell\n colSpan={columns.length + (selectable ? 1 : 0)}\n sx={styles.empty}\n >\n {emptyContent ?? null}\n </TableCell>\n </MuiTableRow>\n ) : (\n rows.map((row, index) => {\n const rowId = resolveRowId(row, index)\n const isSelected = selectionSet.has(rowId)\n return (\n <MuiTableRow\n key={rowId}\n hover\n selected={isSelected}\n onClick={() => onRowClick?.(row)}\n onMouseEnter={() => onRowHover?.(row)}\n onMouseLeave={() => onRowHover?.(null)}\n sx={{\n ...styles.row,\n ...(onRowClick ? styles.rowClickable : null),\n }}\n >\n {selectable ? (\n <TableCell padding='checkbox'>\n <Checkbox\n checked={isSelected}\n onClick={(e) => {\n e.stopPropagation()\n handleSelectRow(rowId)\n }}\n inputProps={{\n 'aria-label': _labels.selectRow(rowId),\n }}\n />\n </TableCell>\n ) : null}\n {columns.map((column) => (\n <TableCell key={column.id} align={column.align}>\n {column.formatter\n ? column.formatter(row[column.id], row)\n : stringifyCell(row[column.id])}\n </TableCell>\n ))}\n </MuiTableRow>\n )\n })\n )}\n </TableBody>\n </MuiTable>\n </TableContainer>\n {showPagination ? (\n <TablePagination\n component='div'\n count={total}\n page={page}\n rowsPerPage={pageSize}\n rowsPerPageOptions={[...pageSizeOptions]}\n onPageChange={(_, next) => onPageChange?.(next)}\n onRowsPerPageChange={(e) => {\n const next = parseInt(e.target.value, 10)\n onPageSizeChange?.(next)\n }}\n labelRowsPerPage={_labels.rowsPerPage}\n labelDisplayedRows={({ from, to, count }) =>\n _labels.paginationOf(from, to, count)\n }\n ActionsComponent={PaginationActions}\n sx={styles.pagination}\n />\n ) : null}\n </Box>\n )\n}\n\nfunction stringifyCell(value: unknown): React.ReactNode {\n if (value == null) return ''\n if (typeof value === 'string' || typeof value === 'number') return value\n if (typeof value === 'boolean') return String(value)\n if (Array.isArray(value) || typeof value === 'object') {\n return JSON.stringify(value)\n }\n return ''\n}\n\n/**\n * Build the `ActionsComponent` used by `<TablePagination>` — four MUI\n * `IconButton`s for first / previous / next / last. We provide this\n * ourselves so the Meridian theme's `defaultProps.ActionsComponent`\n * (which depends on `react-intl`) is bypassed at the call site without\n * disturbing the rest of the Meridian theme. The factory closes over\n * the merged label set so aria-labels stay consistent with the rest\n * of the table's i18n surface.\n */\nfunction makePaginationActions(labels: TableLabels) {\n return function PaginationActions({\n count,\n page,\n rowsPerPage,\n onPageChange,\n }: TablePaginationActionsProps) {\n const lastPage = Math.max(0, Math.ceil(count / rowsPerPage) - 1)\n return (\n <Box sx={styles.paginationActions}>\n <IconButton\n size='small'\n onClick={(e) => onPageChange(e, 0)}\n disabled={page === 0}\n aria-label={labels.firstPage}\n >\n <FirstPageIcon fontSize='small' />\n </IconButton>\n <IconButton\n size='small'\n onClick={(e) => onPageChange(e, page - 1)}\n disabled={page === 0}\n aria-label={labels.previousPage}\n >\n <KeyboardArrowLeft fontSize='small' />\n </IconButton>\n <IconButton\n size='small'\n onClick={(e) => onPageChange(e, page + 1)}\n disabled={page >= lastPage}\n aria-label={labels.nextPage}\n >\n <KeyboardArrowRight fontSize='small' />\n </IconButton>\n <IconButton\n size='small'\n onClick={(e) => onPageChange(e, lastPage)}\n disabled={page >= lastPage}\n aria-label={labels.lastPage}\n >\n <LastPageIcon fontSize='small' />\n </IconButton>\n </Box>\n )\n }\n}\n","import { toCsvString } from '../actions/download'\nimport type {\n TableColumn,\n TableRow,\n TableSortDirection,\n TableWidgetData,\n} from './types'\n\n/**\n * Compares two values with a consistent ordering across primitive types.\n * Strings use locale comparison; numbers subtract; booleans rank false < true;\n * objects/arrays compare by JSON serialization. Null/undefined sort to the end\n * regardless of direction.\n */\nexport function compareValues(\n a: unknown,\n b: unknown,\n direction: TableSortDirection,\n): number {\n if (a == null && b == null) return 0\n if (a == null) return 1\n if (b == null) return -1\n let cmp = 0\n if (typeof a === 'string' && typeof b === 'string') {\n cmp = a.localeCompare(b)\n } else if (typeof a === 'number' && typeof b === 'number') {\n cmp = a - b\n } else if (typeof a === 'boolean' && typeof b === 'boolean') {\n cmp = a === b ? 0 : a ? 1 : -1\n } else if (typeof a === 'object' || typeof b === 'object') {\n cmp = JSON.stringify(a).localeCompare(JSON.stringify(b))\n }\n return direction === 'asc' ? cmp : -cmp\n}\n\n/** Returns a new array sorted by the named column. Does not mutate the input. */\nexport function sortRows<T extends TableRow>(\n rows: readonly T[],\n columnId: string,\n direction: TableSortDirection,\n): T[] {\n return [...rows].sort((a, b) =>\n compareValues(a[columnId], b[columnId], direction),\n )\n}\n\n/** Returns the slice for the requested page. Out-of-range pages return []. */\nexport function paginateRows<T>(\n rows: readonly T[],\n page: number,\n pageSize: number,\n): T[] {\n if (pageSize <= 0) return rows.slice()\n const start = page * pageSize\n return rows.slice(start, start + pageSize)\n}\n\n/**\n * Resolves the effective column list. When the widget store has a\n * `columnOrder` set (e.g. ChangeColumn was used), the column array is\n * reordered to match. Unknown ids in the order are skipped; columns not\n * present in the order keep their original relative position at the end.\n */\nexport function resolveColumns(\n columns: readonly TableColumn[],\n columnOrder: readonly string[] | undefined,\n): readonly TableColumn[] {\n if (!columnOrder || columnOrder.length === 0) return columns\n const byId = new Map(columns.map((c) => [c.id, c]))\n const ordered: TableColumn[] = []\n const seen = new Set<string>()\n for (const id of columnOrder) {\n const c = byId.get(id)\n if (c && !seen.has(id)) {\n ordered.push(c)\n seen.add(id)\n }\n }\n for (const c of columns) {\n if (!seen.has(c.id)) ordered.push(c)\n }\n return ordered\n}\n\n/** Applies sort and pagination to the input data. Pure. */\nexport function deriveVisibleRows<T extends TableRow>(\n rows: readonly T[],\n options: {\n sort?: { columnId: string | null; direction: TableSortDirection }\n page: number\n pageSize: number\n },\n): { sorted: readonly T[]; visible: T[] } {\n const sorted =\n options.sort?.columnId != null\n ? sortRows(rows, options.sort.columnId, options.sort.direction)\n : rows\n const visible = paginateRows(sorted, options.page, options.pageSize)\n return { sorted, visible }\n}\n\nexport function tableDataToCsv(\n data: TableWidgetData,\n columns: readonly TableColumn[],\n): string {\n // Pre-stringify with the table's own header/cell rules, then delegate the\n // CSV assembly (quoting + spreadsheet formula-injection guard) to the shared\n // `toCsvString` so escaping stays identical to every other widget's export.\n const rows: string[][] = [columns.map((c) => stringifyHeader(c.label))]\n for (const row of data) {\n rows.push(columns.map((c) => stringifyCell(row[c.id])))\n }\n return toCsvString(rows)\n}\n\nfunction stringifyHeader(label: unknown): string {\n if (typeof label === 'string') return label\n if (typeof label === 'number' || typeof label === 'boolean')\n return String(label)\n return ''\n}\n\nfunction stringifyCell(value: unknown): string {\n if (value == null) return ''\n if (typeof value === 'string') return value\n if (typeof value === 'number' || typeof value === 'boolean')\n return String(value)\n if (Array.isArray(value) || typeof value === 'object')\n return JSON.stringify(value)\n return ''\n}\n","import { useCallback, useMemo } from 'react'\nimport {\n getWidgetStore,\n useWidget,\n useWidgetId,\n useWidgetShallow,\n} from '../stores'\nimport { TableUI, type TableUIProps } from './table-ui'\nimport {\n DEFAULT_TABLE_PAGE_SIZE,\n type TableColumn,\n type TableRow,\n type TableSortState,\n type TableWidgetState,\n} from './types'\nimport { deriveVisibleRows, resolveColumns } from './helpers'\n\nexport interface TableProps<T extends TableRow = TableRow> extends Pick<\n TableUIProps<T>,\n | 'pageSizeOptions'\n | 'selectable'\n | 'labels'\n | 'emptyContent'\n | 'size'\n | 'keyColumn'\n> {\n /**\n * Column definitions. Order can be overridden by ChangeColumn via the\n * `columnOrder` field on the extended widget state.\n */\n columns: readonly TableColumn[]\n /**\n * When set, render only the first `visibleColumns` entries **after**\n * applying the user's `columnOrder` from the store. Useful for showing\n * a compact projection while letting consumers (e.g. `Widget.ChangeColumn`)\n * see the full column list. When omitted, every column renders.\n */\n visibleColumns?: number\n /** Initial page size (only on first mount; afterwards lives on the store). */\n initialPageSize?: number\n /** Selected row ids (destination-owned). */\n selection?: readonly (string | number)[]\n onSelectionChange?: (next: readonly (string | number)[]) => void\n onRowClick?: (row: T) => void\n onRowHover?: (row: T | null) => void\n /**\n * When `true`, the bridge stops sorting and paginating locally and\n * renders `data` as-is — the consumer is then responsible for\n * refetching the slice that matches the active `page` / `pageSize` /\n * `sort` from the outbound callbacks below. `total` is required in\n * this mode (the server already knows the full row count; the\n * widget can't infer it from a partial page).\n */\n remote?: boolean\n /**\n * Server-reported total row count. Required when `remote === true`;\n * ignored in local mode (where the bridge derives total from the\n * sorted result of `deriveVisibleRows`).\n */\n total?: number\n /** Fires after the store-level sort write so the consumer can refetch. */\n onSortChange?: (next: TableSortState) => void\n /** Fires after the store-level page write so the consumer can refetch. */\n onPageChange?: (page: number) => void\n /** Fires after the store-level pageSize write so the consumer can refetch. */\n onPageSizeChange?: (pageSize: number) => void\n}\n\n/**\n * Bridge component — reads the widget store's `data`, applies sort + pagination\n * locally, and feeds `<TableUI />`. Sort, page, and pageSize live on the\n * extended widget state ({@link TableWidgetState}).\n */\nexport function Table<T extends TableRow = TableRow>({\n columns,\n visibleColumns,\n initialPageSize = DEFAULT_TABLE_PAGE_SIZE,\n selection,\n onSelectionChange,\n onRowClick,\n onRowHover,\n remote = false,\n total: remoteTotal,\n onSortChange,\n onPageChange,\n onPageSizeChange,\n ...uiProps\n}: TableProps<T>) {\n const id = useWidgetId()\n const data = useWidget(id, (s) => s.data as readonly T[] | undefined)\n const ui = useWidgetShallow<\n {\n sort: TableSortState | undefined\n page: number\n pageSize: number\n columnOrder: readonly string[] | undefined\n },\n TableWidgetState\n >(id, (s) => ({\n sort: s.sort,\n page: s.page ?? 0,\n pageSize: s.pageSize ?? initialPageSize,\n columnOrder: s.columnOrder,\n }))\n\n const orderedColumns = useMemo(() => {\n const reordered = resolveColumns(columns, ui.columnOrder)\n return visibleColumns == null\n ? reordered\n : reordered.slice(0, visibleColumns)\n }, [columns, ui.columnOrder, visibleColumns])\n\n // In remote mode the consumer already paginated / sorted server-side,\n // so pass `data` and `total` straight through. Local mode keeps the\n // bridge-driven sort + slice via `deriveVisibleRows`.\n const { rows, totalRows } = useMemo(() => {\n if (remote) {\n return {\n rows: data ?? [],\n totalRows: remoteTotal ?? 0,\n }\n }\n const { sorted, visible } = deriveVisibleRows(data ?? [], {\n sort: ui.sort,\n page: ui.page,\n pageSize: ui.pageSize,\n })\n return { rows: visible, totalRows: sorted.length }\n }, [remote, data, remoteTotal, ui.sort, ui.page, ui.pageSize])\n\n const handleSortChange = useCallback(\n (next: TableSortState) => {\n getWidgetStore(id).setState({\n sort: next,\n page: 0,\n } as Partial<TableWidgetState>)\n onSortChange?.(next)\n },\n [id, onSortChange],\n )\n\n const handlePageChange = useCallback(\n (page: number) => {\n getWidgetStore(id).setState({ page } as Partial<TableWidgetState>)\n onPageChange?.(page)\n },\n [id, onPageChange],\n )\n\n const handlePageSizeChange = useCallback(\n (pageSize: number) => {\n getWidgetStore(id).setState({\n pageSize,\n page: 0,\n } as Partial<TableWidgetState>)\n onPageSizeChange?.(pageSize)\n },\n [id, onPageSizeChange],\n )\n\n return (\n <TableUI\n {...uiProps}\n columns={orderedColumns}\n rows={rows}\n total={totalRows}\n page={ui.page}\n pageSize={ui.pageSize}\n sort={ui.sort}\n selection={selection}\n onSortChange={handleSortChange}\n onPageChange={handlePageChange}\n onPageSizeChange={handlePageSizeChange}\n onSelectionChange={onSelectionChange}\n onRowClick={onRowClick}\n onRowHover={onRowHover}\n />\n )\n}\n","import {\n Box,\n Skeleton,\n Table as MuiTable,\n TableBody,\n TableCell,\n TableHead,\n TableRow as MuiTableRow,\n type TableProps as MuiTableProps,\n} from '@mui/material'\nimport { styles } from './style'\n\nexport interface TableSkeletonProps {\n /** Number of body rows to render. Defaults to `5` (matches v1). */\n rows?: number\n /** Number of columns to render. Defaults to `4` (matches v1). */\n columns?: number\n /**\n * Forwarded to MUI's `<Table size>` so the loading layout matches the\n * size you'll render in {@link TableUI}. Leave `undefined` (the\n * default) to use MUI's own default density.\n */\n size?: MuiTableProps['size']\n}\n\n/**\n * Loading placeholder for the Table widget. Renders the same MUI table\n * primitives that {@link TableUI} uses so the loading layout (column\n * widths, header band, row density) doesn't shift when data resolves.\n *\n * Mirrors the v1 widget's `<TableSkeleton>` structure with v2's themed\n * `styles.headerCell`.\n */\nexport function TableSkeleton({\n rows = 5,\n columns = 4,\n size,\n}: TableSkeletonProps) {\n return (\n <Box sx={styles.container} aria-label='Table skeleton'>\n <MuiTable size={size} sx={styles.table} stickyHeader>\n <TableHead>\n <MuiTableRow>\n {Array.from({ length: columns }).map((_, c) => (\n <TableCell key={`head-${c}`} sx={styles.headerCell}>\n <Skeleton variant='text' width='80%' height={24} />\n </TableCell>\n ))}\n </MuiTableRow>\n </TableHead>\n <TableBody>\n {Array.from({ length: rows }).map((_, r) => (\n <MuiTableRow key={`row-${r}`} sx={styles.row}>\n {Array.from({ length: columns }).map((__, c) => (\n <TableCell key={`cell-${r}-${c}`}>\n <Skeleton variant='text' width='70%' height={20} />\n </TableCell>\n ))}\n </MuiTableRow>\n ))}\n </TableBody>\n </MuiTable>\n </Box>\n )\n}\n","import {\n buildCsvDownloadItem,\n buildPngDownloadItem,\n type DownloadItem,\n} from '../actions/download'\nimport { tableDataToCsv } from './helpers'\nimport type { TableColumn, TableWidgetData } from './types'\n\n/**\n * Download menu items for the Table widget. Always includes a CSV item\n * that pulls the latest data from the widget store via `getData()` (so\n * locked / sorted / filtered state is honored); headers come from\n * `column.label`, cells from `row[column.id]`. When `getCaptureEl` is\n * supplied, prepends a PNG item that rasterises the captured element via\n * `html2canvas`.\n */\nexport function createTableDownloadConfig(opts: {\n filename: string\n getData: () => TableWidgetData\n columns: readonly TableColumn[]\n getCaptureEl?: () => HTMLElement | null\n pngPixelRatio?: number\n pngBackgroundColor?: string | null\n}): DownloadItem[] {\n const items: DownloadItem[] = []\n if (opts.getCaptureEl) {\n items.push(\n buildPngDownloadItem({\n filename: opts.filename,\n getCaptureEl: opts.getCaptureEl,\n pixelRatio: opts.pngPixelRatio,\n backgroundColor: opts.pngBackgroundColor,\n }),\n )\n }\n items.push(\n buildCsvDownloadItem({\n filename: opts.filename,\n getCsv: () => tableDataToCsv(opts.getData(), opts.columns),\n }),\n )\n return items\n}\n","/**\n * `LockSelection` filter for Table. Data is a FLAT `TableRow[]` (unlike every\n * other widget's `X[][]` series shape) and row identity comes from\n * `row[keyColumn]` (default `'id'`), not `name` — so `filterByLockedItems`\n * doesn't apply here (its outer `.map` treats each row as a \"series\", and a\n * plain row object isn't an array, so it would silently pass everything\n * through unfiltered). Falls back to the row's index when the identity\n * column is nullish, mirroring `TableUI`'s own `resolveRowId`.\n *\n * `keyColumn` arrives as `LockSelection`'s `filterKey`, so pass this by\n * reference: `filterFn={filterTableByLockedRows} filterKey={keyColumn}`.\n * Don't close over it — `filterFn`'s identity is not a pipeline dependency,\n * so a captured key changes without re-running anything.\n */\nexport function filterTableByLockedRows(\n input: unknown,\n lockedItems: readonly (string | number)[],\n keyColumn: string | number = 'id',\n): unknown {\n if (lockedItems.length === 0) return input\n if (!Array.isArray(input)) return input\n const locked = new Set<string | number>(lockedItems)\n return input.filter((row: unknown, index: number): boolean => {\n if (row == null || typeof row !== 'object') return false\n const id = (row as Record<string, unknown>)[keyColumn] ?? index\n return (typeof id === 'string' || typeof id === 'number') && locked.has(id)\n })\n}\n"],"mappings":";;;;;;;AAwBA,IAAM,IAA4B;CAAE,YAAY;CAAK,OAAO;AAAe,GAE9D,IAAoC;CAC/C,WAAW;CACX,YAAY,MAAO,cAAc;CACjC,aAAa;CACb,eAAe,GAAM,GAAI,MACvB,kBAAA,GAAA,EAAA,UAAA,CACE,kBAAC,GAAD;EAAK,WAAU;EAAO,IAAI;EAAY,UAAA,GAAG,EAAK,GAAG;CAAU,CAAA,GAC1D,OAAO,GACR,EAAA,CAAA;CAEJ,WAAW;CACX,cAAc;CACd,UAAU;CACV,UAAU;AACZ,GCaa,IAA0B,IAC1B,IAAkC;CAAC;CAAI;CAAI;CAAI;AAAG,GCpDlD,IAAS;CACpB,WAAW;EACT,OAAO;EACP,WAAW;CACb;CAEA,OAAO,EACL,UAAU,EACZ;CACA,YAAY;EACV,YAAY;EACZ,iBAAiB;CACnB;CAKA,KA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BzB,SAAgB,EAA0B,GAOvB;CACjB,IAAM,IAAwB,CAAC;CAiB/B,OAhBI,EAAK,gBACP,EAAM,KACJ,EAAqB;EACnB,UAAU,EAAK;EACf,cAAc,EAAK;EACnB,YAAY,EAAK;EACjB,iBAAiB,EAAK;CACxB,CAAC,CACH,GAEF,EAAM,KACJ,EAAqB;EACnB,UAAU,EAAK;EACf,cAAc,EAAe,EAAK,QAAQ,GAAG,EAAK,OAAO;CAC3D,CAAC,CACH,GACO;AACT;;;AC5BA,SAAgB,GACd,GACA,GACA,IAA6B,MACpB;CAET,IADI,EAAY,WAAW,KACvB,CAAC,MAAM,QAAQ,CAAK,GAAG,OAAO;CAClC,IAAM,IAAS,IAAI,IAAqB,CAAW;CACnD,OAAO,EAAM,QAAQ,GAAc,MAA2B;EAC5D,IAAmB,OAAO,KAAQ,aAA9B,GAAwC,OAAO;EACnD,IAAM,IAAM,EAAgC,MAAc;EAC1D,QAAQ,OAAO,KAAO,YAAY,OAAO,KAAO,aAAa,EAAO,IAAI,CAAE;CAC5E,CAAC;AACH"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { c as e } from "react/compiler-runtime";
|
|
2
|
+
import { Tooltip as t } from "@mui/material";
|
|
3
|
+
import { jsx as n } from "react/jsx-runtime";
|
|
4
|
+
//#region src/components/tooltip/tooltip.tsx
|
|
5
|
+
var r = 500;
|
|
6
|
+
function i(i) {
|
|
7
|
+
let a = e(10), o, s, c, l;
|
|
8
|
+
a[0] === i ? (o = a[1], s = a[2], c = a[3], l = a[4]) : ({children: o, title: l, enterNextDelay: c, ...s} = i, a[0] = i, a[1] = o, a[2] = s, a[3] = c, a[4] = l);
|
|
9
|
+
let u = c === void 0 ? r : c, d;
|
|
10
|
+
return a[5] !== o || a[6] !== u || a[7] !== s || a[8] !== l ? (d = /* @__PURE__ */ n(t, {
|
|
11
|
+
title: l,
|
|
12
|
+
enterNextDelay: u,
|
|
13
|
+
...s,
|
|
14
|
+
children: o
|
|
15
|
+
}), a[5] = o, a[6] = u, a[7] = s, a[8] = l, a[9] = d) : d = a[9], d;
|
|
16
|
+
}
|
|
17
|
+
function a(e) {
|
|
18
|
+
r = e;
|
|
19
|
+
}
|
|
20
|
+
//#endregion
|
|
21
|
+
export { a as n, i as t };
|
|
22
|
+
|
|
23
|
+
//# sourceMappingURL=tooltip-DJUGNZxY.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tooltip-DJUGNZxY.js","names":["enterNextDelay = tooltipEnterDelay","{\n children,\n title,\n enterNextDelay = tooltipEnterDelay,\n ...props\n}: TooltipProps","<MuiTooltip title={title} enterNextDelay={enterNextDelay} {...props}>\n {children}\n </MuiTooltip>"],"sources":["../src/components/tooltip/tooltip.tsx"],"sourcesContent":["import { Tooltip as MuiTooltip, type TooltipProps } from '@mui/material'\n\nlet tooltipEnterDelay = 500\n\n/**\n * A wrapper around MUI's Tooltip component with enterNextDelay set to 1000ms by default.\n *\n * This component ensures consistent tooltip behavior across the application.\n *\n * @example\n * <Tooltip title=\"This is a tooltip\">\n * <Button>Hover me</Button>\n * </Tooltip>\n */\nexport function Tooltip({\n children,\n title,\n enterNextDelay = tooltipEnterDelay,\n ...props\n}: TooltipProps) {\n return (\n <MuiTooltip title={title} enterNextDelay={enterNextDelay} {...props}>\n {children}\n </MuiTooltip>\n )\n}\n\n/**\n * Sets the global default `enterNextDelay` for all Tooltip components in the application.\n *\n * @param delay - Delay in milliseconds before showing tooltips on subsequent hovers.\n *\n * @example\n * ```tsx\n * import { setTooltipEnterDelay } from '@carto/ps-react-ui/components';\n *\n * // Set global delay to 300ms at app initialization\n * setTooltipEnterDelay(300);\n * ```\n */\nexport function setTooltipEnterDelay(delay: number) {\n tooltipEnterDelay = delay\n}\n"],"mappings":";;;;AAEA,IAAI,IAAoB;AAYxB,SAAgB,EAAA,GAKC;gBAJf,GAGG,GADHA,GADA;CAFsBC,AAAAA,EAAAA,OAAAA,gDACtB,wBAEA,gBAAA,GACA,GAAA,KAJsBA;CAGtB,IAAA,IAAA,MAAA,KAAA,IAAiB,IAAjBD,GAIEE;CADF,OAEK,EAAA,OAAA,KAAA,EAAA,OADuC,KAAA,EAAA,OAAoB,KAAA,EAAA,OAA3C,KAAnB,IAAA,kBAAC,GAAD;EAAmB;EAAuB;EAAgB,GAAI;EAC3D;CACS,CAAA,GADT,EAAA,KAAA,GADuC,EAAA,KAAA,GAAoB,EAAA,KAAA,GAA3C,EAAA,KAAA,yBAAnBA;AAIJ;AAeA,SAAgB,EAAqB,GAAe;CAClD,IAAoB;AACtB"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ChatAgentMessageMarkdownProps } from '../types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Agent reply bubble that renders its (string) children as GitHub-Flavored
|
|
4
|
+
* Markdown through the library's sanitized renderer — raw HTML is skipped and
|
|
5
|
+
* images are stripped, since the content is model output; tables / task lists /
|
|
6
|
+
* strikethrough pick up the bubble's element styling. Composition over
|
|
7
|
+
* `ChatAgentMessage`, which stays a plain styles container.
|
|
8
|
+
*/
|
|
9
|
+
export declare function ChatAgentMessageMarkdown({ children, ...props }: ChatAgentMessageMarkdownProps): import('react').JSX.Element;
|
|
10
|
+
export declare namespace ChatAgentMessageMarkdown {
|
|
11
|
+
var displayName: string;
|
|
12
|
+
}
|