@sqlrooms/mosaic 0.29.0-rc.6 → 0.29.0-rc.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +48 -19
- package/dist/MosaicChart.d.ts +6 -6
- package/dist/MosaicChart.d.ts.map +1 -1
- package/dist/MosaicChart.js +6 -6
- package/dist/MosaicChart.js.map +1 -1
- package/dist/MosaicChartBuilder.d.ts +1 -1
- package/dist/MosaicChartBuilder.d.ts.map +1 -1
- package/dist/MosaicChartBuilder.js +1 -1
- package/dist/MosaicChartBuilder.js.map +1 -1
- package/dist/MosaicColorLegend.d.ts.map +1 -1
- package/dist/MosaicColorLegend.js +0 -1
- package/dist/MosaicColorLegend.js.map +1 -1
- package/dist/VgPlotChart.d.ts.map +1 -1
- package/dist/VgPlotChart.js +6 -3
- package/dist/VgPlotChart.js.map +1 -1
- package/dist/ai/ai.d.ts +103 -0
- package/dist/ai/ai.d.ts.map +1 -0
- package/dist/ai/ai.js +419 -0
- package/dist/ai/ai.js.map +1 -0
- package/dist/ai/data-table-explorer-tool.d.ts +40 -0
- package/dist/ai/data-table-explorer-tool.d.ts.map +1 -0
- package/dist/ai/data-table-explorer-tool.js +75 -0
- package/dist/ai/data-table-explorer-tool.js.map +1 -0
- package/dist/ai/list-panels-tool.d.ts +35 -0
- package/dist/ai/list-panels-tool.d.ts.map +1 -0
- package/dist/ai/list-panels-tool.js.map +1 -0
- package/dist/ai/remove-panel-tool.d.ts +31 -0
- package/dist/ai/remove-panel-tool.d.ts.map +1 -0
- package/dist/ai/remove-panel-tool.js.map +1 -0
- package/dist/ai/tool-helpers.d.ts +34 -0
- package/dist/ai/tool-helpers.d.ts.map +1 -0
- package/dist/ai/tool-helpers.js +93 -0
- package/dist/ai/tool-helpers.js.map +1 -0
- package/dist/ai/tool-schemas.d.ts.map +1 -0
- package/dist/ai/tool-schemas.js.map +1 -0
- package/dist/ai/tool-types.d.ts +26 -0
- package/dist/ai/tool-types.d.ts.map +1 -0
- package/dist/ai/tool-types.js.map +1 -0
- package/dist/ai/tool-validation.d.ts +3 -0
- package/dist/ai/tool-validation.d.ts.map +1 -0
- package/dist/ai/tool-validation.js.map +1 -0
- package/dist/ai.d.ts +2 -99
- package/dist/ai.d.ts.map +1 -1
- package/dist/ai.js +2 -441
- package/dist/ai.js.map +1 -1
- package/dist/chart-builders/ChartBuilderActions.js.map +1 -1
- package/dist/chart-builders/ChartBuilderContent.d.ts +2 -2
- package/dist/chart-builders/ChartBuilderContent.d.ts.map +1 -1
- package/dist/chart-builders/ChartBuilderContent.js.map +1 -1
- package/dist/chart-builders/ChartBuilderContext.d.ts +2 -2
- package/dist/chart-builders/ChartBuilderContext.d.ts.map +1 -1
- package/dist/chart-builders/ChartBuilderContext.js.map +1 -1
- package/dist/chart-builders/ChartBuilderDialog.d.ts +2 -2
- package/dist/chart-builders/ChartBuilderDialog.d.ts.map +1 -1
- package/dist/chart-builders/ChartBuilderDialog.js.map +1 -1
- package/dist/chart-builders/ChartBuilderFields.js +2 -2
- package/dist/chart-builders/ChartBuilderFields.js.map +1 -1
- package/dist/chart-builders/ChartBuilderRoot.d.ts +2 -2
- package/dist/chart-builders/ChartBuilderRoot.d.ts.map +1 -1
- package/dist/chart-builders/ChartBuilderRoot.js.map +1 -1
- package/dist/chart-builders/chartSpecTitle.d.ts +1 -1
- package/dist/chart-builders/chartSpecTitle.d.ts.map +1 -1
- package/dist/chart-builders/chartSpecTitle.js.map +1 -1
- package/dist/chart-builders/chartTypeUtils.d.ts +1 -2
- package/dist/chart-builders/chartTypeUtils.d.ts.map +1 -1
- package/dist/chart-builders/chartTypeUtils.js +0 -1
- package/dist/chart-builders/chartTypeUtils.js.map +1 -1
- package/dist/chart-builders/createChartBuilderStore.d.ts +1 -1
- package/dist/chart-builders/createChartBuilderStore.d.ts.map +1 -1
- package/dist/chart-builders/createChartBuilderStore.js.map +1 -1
- package/dist/charts/MosaicChart.d.ts +12 -0
- package/dist/charts/MosaicChart.d.ts.map +1 -0
- package/dist/charts/MosaicChart.js +13 -0
- package/dist/charts/MosaicChart.js.map +1 -0
- package/dist/charts/MosaicChartError.d.ts +8 -0
- package/dist/charts/MosaicChartError.d.ts.map +1 -0
- package/dist/charts/MosaicChartError.js +5 -0
- package/dist/charts/MosaicChartError.js.map +1 -0
- package/dist/charts/MosaicChartRuntimeIssuePanel.d.ts +7 -0
- package/dist/charts/MosaicChartRuntimeIssuePanel.d.ts.map +1 -0
- package/dist/charts/MosaicChartRuntimeIssuePanel.js +10 -0
- package/dist/charts/MosaicChartRuntimeIssuePanel.js.map +1 -0
- package/dist/charts/MosaicChartSettingsPanel.d.ts +11 -0
- package/dist/charts/MosaicChartSettingsPanel.d.ts.map +1 -0
- package/dist/charts/MosaicChartSettingsPanel.js +21 -0
- package/dist/charts/MosaicChartSettingsPanel.js.map +1 -0
- package/dist/charts/MosaicChartView.d.ts +13 -0
- package/dist/charts/MosaicChartView.d.ts.map +1 -0
- package/dist/charts/MosaicChartView.js +56 -0
- package/dist/charts/MosaicChartView.js.map +1 -0
- package/dist/charts/addChartPanelAction.d.ts.map +1 -0
- package/dist/charts/addChartPanelAction.js.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSettings.d.ts +43 -0
- package/dist/charts/chart-settings/MosaicChartSettings.d.ts.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSettings.js +74 -0
- package/dist/charts/chart-settings/MosaicChartSettings.js.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSettingsContent.d.ts +13 -0
- package/dist/charts/chart-settings/MosaicChartSettingsContent.d.ts.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSettingsContent.js +18 -0
- package/dist/charts/chart-settings/MosaicChartSettingsContent.js.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSettingsContext.d.ts +24 -0
- package/dist/charts/chart-settings/MosaicChartSettingsContext.d.ts.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSettingsContext.js +34 -0
- package/dist/charts/chart-settings/MosaicChartSettingsContext.js.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSettingsPanel.d.ts +14 -0
- package/dist/charts/chart-settings/MosaicChartSettingsPanel.d.ts.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSettingsPanel.js +17 -0
- package/dist/charts/chart-settings/MosaicChartSettingsPanel.js.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSpecViewerPanel.d.ts +9 -0
- package/dist/charts/chart-settings/MosaicChartSpecViewerPanel.d.ts.map +1 -0
- package/dist/charts/chart-settings/MosaicChartSpecViewerPanel.js +11 -0
- package/dist/charts/chart-settings/MosaicChartSpecViewerPanel.js.map +1 -0
- package/dist/charts/chart-settings/MosaicChartTypeSelector.d.ts +9 -0
- package/dist/charts/chart-settings/MosaicChartTypeSelector.d.ts.map +1 -0
- package/dist/charts/chart-settings/MosaicChartTypeSelector.js +16 -0
- package/dist/charts/chart-settings/MosaicChartTypeSelector.js.map +1 -0
- package/dist/charts/chart-types/base-types.d.ts +168 -0
- package/dist/charts/chart-types/base-types.d.ts.map +1 -0
- package/dist/charts/chart-types/base-types.js.map +1 -0
- package/dist/charts/chart-types/box-plot/BoxPlotSettings.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/BoxPlotSettings.js +9 -0
- package/dist/charts/chart-types/box-plot/BoxPlotSettings.js.map +1 -0
- package/dist/charts/chart-types/box-plot/definition.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/definition.js +24 -0
- package/dist/charts/chart-types/box-plot/definition.js.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/BoxPlotClient.d.ts +67 -0
- package/dist/charts/chart-types/box-plot/renderer/BoxPlotClient.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/BoxPlotClient.js +286 -0
- package/dist/charts/chart-types/box-plot/renderer/BoxPlotClient.js.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/BoxPlotErrorBoundary.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/BoxPlotErrorBoundary.js.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/BoxPlotPanelRenderer.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/BoxPlotPanelRenderer.js +118 -0
- package/dist/charts/chart-types/box-plot/renderer/BoxPlotPanelRenderer.js.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/constants.d.ts +24 -0
- package/dist/charts/chart-types/box-plot/renderer/constants.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/constants.js.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/plot.d.ts +14 -0
- package/dist/charts/chart-types/box-plot/renderer/plot.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/plot.js.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/useBoxPlotClient.d.ts +18 -0
- package/dist/charts/chart-types/box-plot/renderer/useBoxPlotClient.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/useBoxPlotClient.js +63 -0
- package/dist/charts/chart-types/box-plot/renderer/useBoxPlotClient.js.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/utils.d.ts +6 -0
- package/dist/charts/chart-types/box-plot/renderer/utils.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/renderer/utils.js.map +1 -0
- package/dist/charts/chart-types/box-plot/schema.d.ts +21 -0
- package/dist/charts/chart-types/box-plot/schema.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/schema.js +16 -0
- package/dist/charts/chart-types/box-plot/schema.js.map +1 -0
- package/dist/charts/chart-types/box-plot/tool.d.ts +40 -0
- package/dist/charts/chart-types/box-plot/tool.d.ts.map +1 -0
- package/dist/charts/chart-types/box-plot/tool.js +67 -0
- package/dist/charts/chart-types/box-plot/tool.js.map +1 -0
- package/dist/charts/chart-types/bubble-chart/BubbleChartSettings.d.ts.map +1 -0
- package/dist/charts/chart-types/bubble-chart/BubbleChartSettings.js +9 -0
- package/dist/charts/chart-types/bubble-chart/BubbleChartSettings.js.map +1 -0
- package/dist/charts/chart-types/bubble-chart/definition.d.ts.map +1 -0
- package/dist/charts/chart-types/bubble-chart/definition.js +24 -0
- package/dist/charts/chart-types/bubble-chart/definition.js.map +1 -0
- package/dist/charts/chart-types/bubble-chart/schema.d.ts.map +1 -0
- package/dist/charts/chart-types/bubble-chart/schema.js.map +1 -0
- package/dist/charts/chart-types/bubble-chart/spec.d.ts.map +1 -0
- package/dist/charts/chart-types/bubble-chart/spec.js +31 -0
- package/dist/charts/chart-types/bubble-chart/spec.js.map +1 -0
- package/dist/charts/chart-types/bubble-chart/tool.d.ts.map +1 -0
- package/dist/charts/chart-types/bubble-chart/tool.js +66 -0
- package/dist/charts/chart-types/bubble-chart/tool.js.map +1 -0
- package/dist/charts/chart-types/chart-config.d.ts +138 -0
- package/dist/charts/chart-types/chart-config.d.ts.map +1 -0
- package/dist/charts/chart-types/chart-config.js +41 -0
- package/dist/charts/chart-types/chart-config.js.map +1 -0
- package/dist/charts/chart-types/count-plot/CountPlotSettings.d.ts.map +1 -0
- package/dist/charts/chart-types/count-plot/CountPlotSettings.js +9 -0
- package/dist/charts/chart-types/count-plot/CountPlotSettings.js.map +1 -0
- package/dist/charts/chart-types/count-plot/definition.d.ts.map +1 -0
- package/dist/charts/chart-types/count-plot/definition.js +19 -0
- package/dist/charts/chart-types/count-plot/definition.js.map +1 -0
- package/dist/charts/chart-types/count-plot/schema.d.ts.map +1 -0
- package/dist/charts/chart-types/count-plot/schema.js.map +1 -0
- package/dist/charts/chart-types/count-plot/spec.d.ts.map +1 -0
- package/dist/charts/chart-types/count-plot/spec.js +49 -0
- package/dist/charts/chart-types/count-plot/spec.js.map +1 -0
- package/dist/charts/chart-types/count-plot/tool.d.ts.map +1 -0
- package/dist/charts/chart-types/count-plot/tool.js +63 -0
- package/dist/charts/chart-types/count-plot/tool.js.map +1 -0
- package/dist/charts/chart-types/createChartTools.d.ts +17 -0
- package/dist/charts/chart-types/createChartTools.d.ts.map +1 -0
- package/dist/charts/chart-types/createChartTools.js +24 -0
- package/dist/charts/chart-types/createChartTools.js.map +1 -0
- package/dist/charts/chart-types/createDefaultChartTypes.d.ts +12 -0
- package/dist/charts/chart-types/createDefaultChartTypes.d.ts.map +1 -0
- package/dist/charts/chart-types/createDefaultChartTypes.js +30 -0
- package/dist/charts/chart-types/createDefaultChartTypes.js.map +1 -0
- package/dist/charts/chart-types/custom-spec/CustomSpecSettings.d.ts.map +1 -0
- package/dist/charts/chart-types/custom-spec/CustomSpecSettings.js +30 -0
- package/dist/charts/chart-types/custom-spec/CustomSpecSettings.js.map +1 -0
- package/dist/charts/chart-types/custom-spec/definition.d.ts.map +1 -0
- package/dist/charts/chart-types/custom-spec/definition.js +22 -0
- package/dist/charts/chart-types/custom-spec/definition.js.map +1 -0
- package/dist/charts/chart-types/custom-spec/schema.d.ts.map +1 -0
- package/dist/charts/chart-types/custom-spec/schema.js.map +1 -0
- package/dist/charts/chart-types/custom-spec/spec.d.ts.map +1 -0
- package/dist/charts/chart-types/custom-spec/spec.js.map +1 -0
- package/dist/charts/chart-types/data-policy-schema.d.ts.map +1 -0
- package/dist/charts/chart-types/data-policy-schema.js.map +1 -0
- package/dist/charts/chart-types/errors.d.ts +7 -0
- package/dist/charts/chart-types/errors.d.ts.map +1 -0
- package/dist/charts/chart-types/errors.js +10 -0
- package/dist/charts/chart-types/errors.js.map +1 -0
- package/dist/charts/chart-types/heatmap/HeatmapSettings.d.ts.map +1 -0
- package/dist/charts/chart-types/heatmap/HeatmapSettings.js +9 -0
- package/dist/charts/chart-types/heatmap/HeatmapSettings.js.map +1 -0
- package/dist/charts/chart-types/heatmap/definition.d.ts.map +1 -0
- package/dist/charts/chart-types/heatmap/definition.js +19 -0
- package/dist/charts/chart-types/heatmap/definition.js.map +1 -0
- package/dist/charts/chart-types/heatmap/schema.d.ts.map +1 -0
- package/dist/charts/chart-types/heatmap/schema.js.map +1 -0
- package/dist/charts/chart-types/heatmap/spec.d.ts.map +1 -0
- package/dist/charts/chart-types/heatmap/spec.js +32 -0
- package/dist/charts/chart-types/heatmap/spec.js.map +1 -0
- package/dist/charts/chart-types/heatmap/tool.d.ts.map +1 -0
- package/dist/charts/chart-types/heatmap/tool.js +67 -0
- package/dist/charts/chart-types/heatmap/tool.js.map +1 -0
- package/dist/charts/chart-types/histogram/HistogramSettings.d.ts.map +1 -0
- package/dist/charts/chart-types/histogram/HistogramSettings.js +11 -0
- package/dist/charts/chart-types/histogram/HistogramSettings.js.map +1 -0
- package/dist/charts/chart-types/histogram/definition.d.ts.map +1 -0
- package/dist/charts/chart-types/histogram/definition.js +19 -0
- package/dist/charts/chart-types/histogram/definition.js.map +1 -0
- package/dist/charts/chart-types/histogram/schema.d.ts.map +1 -0
- package/dist/charts/chart-types/histogram/schema.js.map +1 -0
- package/dist/charts/chart-types/histogram/spec.d.ts.map +1 -0
- package/dist/charts/chart-types/histogram/spec.js +37 -0
- package/dist/charts/chart-types/histogram/spec.js.map +1 -0
- package/dist/charts/chart-types/histogram/tool.d.ts.map +1 -0
- package/dist/charts/chart-types/histogram/tool.js +65 -0
- package/dist/charts/chart-types/histogram/tool.js.map +1 -0
- package/dist/charts/chart-types/index.d.ts +42 -0
- package/dist/charts/chart-types/index.d.ts.map +1 -0
- package/dist/charts/chart-types/index.js +53 -0
- package/dist/charts/chart-types/index.js.map +1 -0
- package/dist/charts/chart-types/line-chart/LineChartSettings.d.ts.map +1 -0
- package/dist/charts/chart-types/line-chart/LineChartSettings.js +24 -0
- package/dist/charts/chart-types/line-chart/LineChartSettings.js.map +1 -0
- package/dist/charts/chart-types/line-chart/definition.d.ts.map +1 -0
- package/dist/charts/chart-types/line-chart/definition.js +26 -0
- package/dist/charts/chart-types/line-chart/definition.js.map +1 -0
- package/dist/charts/chart-types/line-chart/schema.d.ts +70 -0
- package/dist/charts/chart-types/line-chart/schema.d.ts.map +1 -0
- package/dist/charts/chart-types/line-chart/schema.js +29 -0
- package/dist/charts/chart-types/line-chart/schema.js.map +1 -0
- package/dist/charts/chart-types/line-chart/spec.d.ts.map +1 -0
- package/dist/charts/chart-types/line-chart/spec.js +91 -0
- package/dist/charts/chart-types/line-chart/spec.js.map +1 -0
- package/dist/charts/chart-types/line-chart/tool.d.ts.map +1 -0
- package/dist/charts/chart-types/line-chart/tool.js +75 -0
- package/dist/charts/chart-types/line-chart/tool.js.map +1 -0
- package/dist/charts/chart-types/mosaicChartTypes.d.ts +101 -0
- package/dist/charts/chart-types/mosaicChartTypes.d.ts.map +1 -0
- package/dist/charts/chart-types/mosaicChartTypes.js +20 -0
- package/dist/charts/chart-types/mosaicChartTypes.js.map +1 -0
- package/dist/charts/dashboard/MosaicDashboardChartHeaderActions.d.ts +4 -0
- package/dist/charts/dashboard/MosaicDashboardChartHeaderActions.d.ts.map +1 -0
- package/dist/charts/dashboard/MosaicDashboardChartHeaderActions.js +16 -0
- package/dist/charts/dashboard/MosaicDashboardChartHeaderActions.js.map +1 -0
- package/dist/charts/dashboard/MosaicDashboardChartRenderer.d.ts +4 -0
- package/dist/charts/dashboard/MosaicDashboardChartRenderer.d.ts.map +1 -0
- package/dist/charts/dashboard/MosaicDashboardChartRenderer.js +23 -0
- package/dist/charts/dashboard/MosaicDashboardChartRenderer.js.map +1 -0
- package/dist/charts/useBrushSelectionParams.d.ts +3 -0
- package/dist/charts/useBrushSelectionParams.d.ts.map +1 -0
- package/dist/charts/useBrushSelectionParams.js +16 -0
- package/dist/charts/useBrushSelectionParams.js.map +1 -0
- package/dist/charts/useChartDataPolicy.d.ts +5 -0
- package/dist/charts/useChartDataPolicy.d.ts.map +1 -0
- package/dist/charts/useChartDataPolicy.js +17 -0
- package/dist/charts/useChartDataPolicy.js.map +1 -0
- package/dist/charts/useChartRetainer.d.ts +4 -0
- package/dist/charts/useChartRetainer.d.ts.map +1 -0
- package/dist/charts/useChartRetainer.js +18 -0
- package/dist/charts/useChartRetainer.js.map +1 -0
- package/dist/charts/useChartTypeDefinition.d.ts +3 -0
- package/dist/charts/useChartTypeDefinition.d.ts.map +1 -0
- package/dist/charts/useChartTypeDefinition.js.map +1 -0
- package/dist/charts/useMosaicChartRenderContext.d.ts +21 -0
- package/dist/charts/useMosaicChartRenderContext.d.ts.map +1 -0
- package/dist/charts/useMosaicChartRenderContext.js +63 -0
- package/dist/charts/useMosaicChartRenderContext.js.map +1 -0
- package/dist/charts/useParseChartConfig.d.ts +12 -0
- package/dist/charts/useParseChartConfig.d.ts.map +1 -0
- package/dist/charts/useParseChartConfig.js +28 -0
- package/dist/charts/useParseChartConfig.js.map +1 -0
- package/dist/charts/useRuntimeIssueReporter.d.ts +7 -0
- package/dist/charts/useRuntimeIssueReporter.d.ts.map +1 -0
- package/dist/charts/useRuntimeIssueReporter.js +19 -0
- package/dist/charts/useRuntimeIssueReporter.js.map +1 -0
- package/dist/charts/worksheet/ChartBlockHeader.d.ts +15 -0
- package/dist/charts/worksheet/ChartBlockHeader.d.ts.map +1 -0
- package/dist/charts/worksheet/ChartBlockHeader.js +9 -0
- package/dist/charts/worksheet/ChartBlockHeader.js.map +1 -0
- package/dist/charts/worksheet/ChartBlockRenderer.d.ts +4 -0
- package/dist/charts/worksheet/ChartBlockRenderer.d.ts.map +1 -0
- package/dist/charts/worksheet/ChartBlockRenderer.js +47 -0
- package/dist/charts/worksheet/ChartBlockRenderer.js.map +1 -0
- package/dist/charts/worksheet/ChartSelectorEmptyState.d.ts +15 -0
- package/dist/charts/worksheet/ChartSelectorEmptyState.d.ts.map +1 -0
- package/dist/charts/worksheet/ChartSelectorEmptyState.js +10 -0
- package/dist/charts/worksheet/ChartSelectorEmptyState.js.map +1 -0
- package/dist/column-types-utils.d.ts +12 -0
- package/dist/column-types-utils.d.ts.map +1 -0
- package/dist/column-types-utils.js +47 -0
- package/dist/column-types-utils.js.map +1 -0
- package/dist/components/AggregationSelector.d.ts +11 -0
- package/dist/components/AggregationSelector.d.ts.map +1 -0
- package/dist/components/AggregationSelector.js.map +1 -0
- package/dist/components/ColumnSelector.d.ts.map +1 -0
- package/dist/components/ColumnSelector.js +30 -0
- package/dist/components/ColumnSelector.js.map +1 -0
- package/dist/components/ColumnsContext.d.ts +11 -0
- package/dist/components/ColumnsContext.d.ts.map +1 -0
- package/dist/components/ColumnsContext.js +15 -0
- package/dist/components/ColumnsContext.js.map +1 -0
- package/dist/components/DataTableSelector.d.ts +22 -0
- package/dist/components/DataTableSelector.d.ts.map +1 -0
- package/dist/components/DataTableSelector.js +66 -0
- package/dist/components/DataTableSelector.js.map +1 -0
- package/dist/components/Field.d.ts.map +1 -0
- package/dist/components/Field.js.map +1 -0
- package/dist/components/FieldSelectorInput.d.ts +14 -0
- package/dist/components/FieldSelectorInput.d.ts.map +1 -0
- package/dist/components/FieldSelectorInput.js.map +1 -0
- package/dist/components/MultiFieldSelector.d.ts +14 -0
- package/dist/components/MultiFieldSelector.d.ts.map +1 -0
- package/dist/components/MultiFieldSelector.js +53 -0
- package/dist/components/MultiFieldSelector.js.map +1 -0
- package/dist/components/TableSelector.d.ts.map +1 -0
- package/dist/components/TableSelector.js +23 -0
- package/dist/components/TableSelector.js.map +1 -0
- package/dist/components/TemporalGranularitySelector.d.ts +10 -0
- package/dist/components/TemporalGranularitySelector.d.ts.map +1 -0
- package/dist/components/TemporalGranularitySelector.js +37 -0
- package/dist/components/TemporalGranularitySelector.js.map +1 -0
- package/dist/dashboard/DefaultMosaicDashboardBlock.d.ts +4 -0
- package/dist/dashboard/DefaultMosaicDashboardBlock.d.ts.map +1 -0
- package/dist/dashboard/DefaultMosaicDashboardBlock.js +6 -0
- package/dist/dashboard/DefaultMosaicDashboardBlock.js.map +1 -0
- package/dist/dashboard/MosaicDashboard.d.ts +2 -5
- package/dist/dashboard/MosaicDashboard.d.ts.map +1 -1
- package/dist/dashboard/MosaicDashboard.js +4 -6
- package/dist/dashboard/MosaicDashboard.js.map +1 -1
- package/dist/dashboard/MosaicDashboardContext.d.ts +0 -2
- package/dist/dashboard/MosaicDashboardContext.d.ts.map +1 -1
- package/dist/dashboard/MosaicDashboardContext.js.map +1 -1
- package/dist/dashboard/MosaicDashboardSlice.d.ts +30 -75
- package/dist/dashboard/MosaicDashboardSlice.d.ts.map +1 -1
- package/dist/dashboard/MosaicDashboardSlice.js +47 -52
- package/dist/dashboard/MosaicDashboardSlice.js.map +1 -1
- package/dist/dashboard/action-types.d.ts +1 -1
- package/dist/dashboard/action-types.d.ts.map +1 -1
- package/dist/dashboard/action-types.js.map +1 -1
- package/dist/dashboard/core-types.d.ts +2 -8
- package/dist/dashboard/core-types.d.ts.map +1 -1
- package/dist/dashboard/core-types.js +2 -8
- package/dist/dashboard/core-types.js.map +1 -1
- package/dist/dashboard/createDefaultMosaicDashboardPanelRenderers.d.ts +3 -0
- package/dist/dashboard/createDefaultMosaicDashboardPanelRenderers.d.ts.map +1 -0
- package/dist/dashboard/createDefaultMosaicDashboardPanelRenderers.js +11 -0
- package/dist/dashboard/createDefaultMosaicDashboardPanelRenderers.js.map +1 -0
- package/dist/dashboard/createMosaicDashboardBlockDefinition.d.ts +12 -0
- package/dist/dashboard/createMosaicDashboardBlockDefinition.d.ts.map +1 -0
- package/dist/dashboard/createMosaicDashboardBlockDefinition.js +32 -0
- package/dist/dashboard/createMosaicDashboardBlockDefinition.js.map +1 -0
- package/dist/dashboard/dashboard-types.d.ts +12 -54
- package/dist/dashboard/dashboard-types.d.ts.map +1 -1
- package/dist/dashboard/dashboard-types.js +7 -15
- package/dist/dashboard/dashboard-types.js.map +1 -1
- package/dist/dashboard/defaultPanelActions.d.ts.map +1 -1
- package/dist/dashboard/defaultPanelActions.js +3 -5
- package/dist/dashboard/defaultPanelActions.js.map +1 -1
- package/dist/dashboard/panel/MosaicDashboardPanel.d.ts.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanel.js +23 -0
- package/dist/dashboard/panel/MosaicDashboardPanel.js.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanelDragOverlay.d.ts.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanelDragOverlay.js +17 -0
- package/dist/dashboard/panel/MosaicDashboardPanelDragOverlay.js.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanelErrorBoundary.d.ts +17 -0
- package/dist/dashboard/panel/MosaicDashboardPanelErrorBoundary.d.ts.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanelErrorBoundary.js +21 -0
- package/dist/dashboard/panel/MosaicDashboardPanelErrorBoundary.js.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanelHeader.d.ts +13 -0
- package/dist/dashboard/panel/MosaicDashboardPanelHeader.d.ts.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanelHeader.js +30 -0
- package/dist/dashboard/panel/MosaicDashboardPanelHeader.js.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanelLayout.d.ts.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanelLayout.js.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanels.d.ts.map +1 -0
- package/dist/dashboard/panel/MosaicDashboardPanels.js +63 -0
- package/dist/dashboard/panel/MosaicDashboardPanels.js.map +1 -0
- package/dist/dashboard/toolbar/MosaicDashboardAddPanelDropdown.js +1 -1
- package/dist/dashboard/toolbar/MosaicDashboardAddPanelDropdown.js.map +1 -1
- package/dist/dashboard/toolbar/MosaicDashboardToolbar.d.ts.map +1 -1
- package/dist/dashboard/toolbar/MosaicDashboardToolbar.js +13 -4
- package/dist/dashboard/toolbar/MosaicDashboardToolbar.js.map +1 -1
- package/dist/dashboard/useMosaicDashboardAddPanelActionContext.js +1 -1
- package/dist/dashboard/useMosaicDashboardAddPanelActionContext.js.map +1 -1
- package/dist/dashboard/useSelectedOrFirstTable.js +1 -1
- package/dist/dashboard/useSelectedOrFirstTable.js.map +1 -1
- package/dist/data-table-explorer/DataTableExplorer.d.ts +37 -0
- package/dist/data-table-explorer/DataTableExplorer.d.ts.map +1 -0
- package/dist/data-table-explorer/DataTableExplorer.js +67 -0
- package/dist/data-table-explorer/DataTableExplorer.js.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerCategoryClient.d.ts +50 -0
- package/dist/data-table-explorer/DataTableExplorerCategoryClient.d.ts.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerCategoryClient.js +121 -0
- package/dist/data-table-explorer/DataTableExplorerCategoryClient.js.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerCountClient.d.ts +28 -0
- package/dist/data-table-explorer/DataTableExplorerCountClient.d.ts.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerCountClient.js +51 -0
- package/dist/data-table-explorer/DataTableExplorerCountClient.js.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerHeader.d.ts +7 -0
- package/dist/data-table-explorer/DataTableExplorerHeader.d.ts.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerHeader.js +195 -0
- package/dist/data-table-explorer/DataTableExplorerHeader.js.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerHistogramClient.d.ts +69 -0
- package/dist/data-table-explorer/DataTableExplorerHistogramClient.d.ts.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerHistogramClient.js +179 -0
- package/dist/data-table-explorer/DataTableExplorerHistogramClient.js.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerPageClient.d.ts +37 -0
- package/dist/data-table-explorer/DataTableExplorerPageClient.d.ts.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerPageClient.js +65 -0
- package/dist/data-table-explorer/DataTableExplorerPageClient.js.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerRows.d.ts +9 -0
- package/dist/data-table-explorer/DataTableExplorerRows.d.ts.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerRows.js +65 -0
- package/dist/data-table-explorer/DataTableExplorerRows.js.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerStatusBar.d.ts +9 -0
- package/dist/data-table-explorer/DataTableExplorerStatusBar.d.ts.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerStatusBar.js +28 -0
- package/dist/data-table-explorer/DataTableExplorerStatusBar.js.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerUnsupportedSummaryClient.d.ts +24 -0
- package/dist/data-table-explorer/DataTableExplorerUnsupportedSummaryClient.d.ts.map +1 -0
- package/dist/data-table-explorer/DataTableExplorerUnsupportedSummaryClient.js +51 -0
- package/dist/data-table-explorer/DataTableExplorerUnsupportedSummaryClient.js.map +1 -0
- package/dist/data-table-explorer/addDataTableExplorerPanelAction.d.ts +3 -0
- package/dist/data-table-explorer/addDataTableExplorerPanelAction.d.ts.map +1 -0
- package/dist/data-table-explorer/addDataTableExplorerPanelAction.js +9 -0
- package/dist/data-table-explorer/addDataTableExplorerPanelAction.js.map +1 -0
- package/dist/data-table-explorer/createDataTableExplorerStore.d.ts +46 -0
- package/dist/data-table-explorer/createDataTableExplorerStore.d.ts.map +1 -0
- package/dist/data-table-explorer/createDataTableExplorerStore.js +126 -0
- package/dist/data-table-explorer/createDataTableExplorerStore.js.map +1 -0
- package/dist/data-table-explorer/dashboard/MosaicDashboardDataTableExplorerPanelRenderer.d.ts +4 -0
- package/dist/data-table-explorer/dashboard/MosaicDashboardDataTableExplorerPanelRenderer.d.ts.map +1 -0
- package/dist/data-table-explorer/dashboard/MosaicDashboardDataTableExplorerPanelRenderer.js +28 -0
- package/dist/data-table-explorer/dashboard/MosaicDashboardDataTableExplorerPanelRenderer.js.map +1 -0
- package/dist/data-table-explorer/dataTableExplorerController.d.ts +64 -0
- package/dist/data-table-explorer/dataTableExplorerController.d.ts.map +1 -0
- package/dist/data-table-explorer/dataTableExplorerController.js +127 -0
- package/dist/data-table-explorer/dataTableExplorerController.js.map +1 -0
- package/dist/data-table-explorer/layout.d.ts +11 -0
- package/dist/data-table-explorer/layout.d.ts.map +1 -0
- package/dist/data-table-explorer/layout.js +23 -0
- package/dist/data-table-explorer/layout.js.map +1 -0
- package/dist/data-table-explorer/types.d.ts +87 -0
- package/dist/data-table-explorer/types.d.ts.map +1 -0
- package/dist/data-table-explorer/types.js.map +1 -0
- package/dist/data-table-explorer/useDataTableExplorer.d.ts +7 -0
- package/dist/data-table-explorer/useDataTableExplorer.d.ts.map +1 -0
- package/dist/data-table-explorer/useDataTableExplorer.js +358 -0
- package/dist/data-table-explorer/useDataTableExplorer.js.map +1 -0
- package/dist/data-table-explorer/utils.d.ts +61 -0
- package/dist/data-table-explorer/utils.d.ts.map +1 -0
- package/dist/data-table-explorer/utils.js +349 -0
- package/dist/data-table-explorer/utils.js.map +1 -0
- package/dist/data-table-explorer/worksheet/DataTableBlockHeader.d.ts +11 -0
- package/dist/data-table-explorer/worksheet/DataTableBlockHeader.d.ts.map +1 -0
- package/dist/data-table-explorer/worksheet/DataTableBlockHeader.js +7 -0
- package/dist/data-table-explorer/worksheet/DataTableBlockHeader.js.map +1 -0
- package/dist/data-table-explorer/worksheet/DataTableBlockRenderer.d.ts +4 -0
- package/dist/data-table-explorer/worksheet/DataTableBlockRenderer.d.ts.map +1 -0
- package/dist/data-table-explorer/worksheet/DataTableBlockRenderer.js +35 -0
- package/dist/data-table-explorer/worksheet/DataTableBlockRenderer.js.map +1 -0
- package/dist/editor/MosaicChartContainer.d.ts +4 -4
- package/dist/editor/MosaicChartContainer.js +4 -4
- package/dist/editor/MosaicChartContainer.js.map +1 -1
- package/dist/hooks/useDataTable.d.ts +3 -0
- package/dist/hooks/useDataTable.d.ts.map +1 -0
- package/dist/hooks/useDataTable.js +28 -0
- package/dist/hooks/useDataTable.js.map +1 -0
- package/dist/hooks/useTablesWithColumns.d.ts.map +1 -0
- package/dist/hooks/useTablesWithColumns.js +13 -0
- package/dist/hooks/useTablesWithColumns.js.map +1 -0
- package/dist/index.d.ts +42 -32
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +35 -25
- package/dist/index.js.map +1 -1
- package/dist/schemas/common.d.ts +20 -0
- package/dist/schemas/common.d.ts.map +1 -0
- package/dist/schemas/common.js +15 -0
- package/dist/schemas/common.js.map +1 -0
- package/dist/schemas/index.d.ts +2 -0
- package/dist/schemas/index.d.ts.map +1 -0
- package/dist/schemas/index.js +2 -0
- package/dist/schemas/index.js.map +1 -0
- package/dist/useVgPlotChartRender.d.ts.map +1 -1
- package/dist/useVgPlotChartRender.js +17 -7
- package/dist/useVgPlotChartRender.js.map +1 -1
- package/package.json +14 -13
- package/dist/boxplot/BoxPlotClient.d.ts +0 -65
- package/dist/boxplot/BoxPlotClient.d.ts.map +0 -1
- package/dist/boxplot/BoxPlotClient.js +0 -286
- package/dist/boxplot/BoxPlotClient.js.map +0 -1
- package/dist/chart/ChartRuntimeIssuePanel.d.ts +0 -7
- package/dist/chart/ChartRuntimeIssuePanel.d.ts.map +0 -1
- package/dist/chart/ChartRuntimeIssuePanel.js +0 -10
- package/dist/chart/ChartRuntimeIssuePanel.js.map +0 -1
- package/dist/chart/MosaicDashboardChart.d.ts +0 -14
- package/dist/chart/MosaicDashboardChart.d.ts.map +0 -1
- package/dist/chart/MosaicDashboardChart.js +0 -21
- package/dist/chart/MosaicDashboardChart.js.map +0 -1
- package/dist/chart/MosaicDashboardChartContent.d.ts +0 -16
- package/dist/chart/MosaicDashboardChartContent.d.ts.map +0 -1
- package/dist/chart/MosaicDashboardChartContent.js +0 -45
- package/dist/chart/MosaicDashboardChartContent.js.map +0 -1
- package/dist/chart/MosaicDashboardChartHeaderActions.d.ts +0 -4
- package/dist/chart/MosaicDashboardChartHeaderActions.d.ts.map +0 -1
- package/dist/chart/MosaicDashboardChartHeaderActions.js +0 -16
- package/dist/chart/MosaicDashboardChartHeaderActions.js.map +0 -1
- package/dist/chart/MosaicDashboardChartRenderer.d.ts +0 -4
- package/dist/chart/MosaicDashboardChartRenderer.d.ts.map +0 -1
- package/dist/chart/MosaicDashboardChartRenderer.js +0 -31
- package/dist/chart/MosaicDashboardChartRenderer.js.map +0 -1
- package/dist/chart/MosaicDashboardComponentChart.d.ts +0 -18
- package/dist/chart/MosaicDashboardComponentChart.d.ts.map +0 -1
- package/dist/chart/MosaicDashboardComponentChart.js +0 -14
- package/dist/chart/MosaicDashboardComponentChart.js.map +0 -1
- package/dist/chart/MosaicDashboardVgPlotChart.d.ts +0 -14
- package/dist/chart/MosaicDashboardVgPlotChart.d.ts.map +0 -1
- package/dist/chart/MosaicDashboardVgPlotChart.js +0 -10
- package/dist/chart/MosaicDashboardVgPlotChart.js.map +0 -1
- package/dist/chart/MosaicDashboardVgPlotError.d.ts +0 -8
- package/dist/chart/MosaicDashboardVgPlotError.d.ts.map +0 -1
- package/dist/chart/MosaicDashboardVgPlotError.js +0 -11
- package/dist/chart/MosaicDashboardVgPlotError.js.map +0 -1
- package/dist/chart/addChartPanelAction.d.ts.map +0 -1
- package/dist/chart/addChartPanelAction.js.map +0 -1
- package/dist/chart/chart-settings/ChartSettings.d.ts +0 -44
- package/dist/chart/chart-settings/ChartSettings.d.ts.map +0 -1
- package/dist/chart/chart-settings/ChartSettings.js +0 -74
- package/dist/chart/chart-settings/ChartSettings.js.map +0 -1
- package/dist/chart/chart-settings/ChartSettingsContent.d.ts +0 -13
- package/dist/chart/chart-settings/ChartSettingsContent.d.ts.map +0 -1
- package/dist/chart/chart-settings/ChartSettingsContent.js +0 -18
- package/dist/chart/chart-settings/ChartSettingsContent.js.map +0 -1
- package/dist/chart/chart-settings/ChartSettingsContext.d.ts +0 -25
- package/dist/chart/chart-settings/ChartSettingsContext.d.ts.map +0 -1
- package/dist/chart/chart-settings/ChartSettingsContext.js +0 -34
- package/dist/chart/chart-settings/ChartSettingsContext.js.map +0 -1
- package/dist/chart/chart-settings/ChartSettingsPanel.d.ts +0 -14
- package/dist/chart/chart-settings/ChartSettingsPanel.d.ts.map +0 -1
- package/dist/chart/chart-settings/ChartSettingsPanel.js +0 -17
- package/dist/chart/chart-settings/ChartSettingsPanel.js.map +0 -1
- package/dist/chart/chart-settings/ChartSpecViewerPanel.d.ts +0 -9
- package/dist/chart/chart-settings/ChartSpecViewerPanel.d.ts.map +0 -1
- package/dist/chart/chart-settings/ChartSpecViewerPanel.js +0 -11
- package/dist/chart/chart-settings/ChartSpecViewerPanel.js.map +0 -1
- package/dist/chart/chart-settings/ChartTypeSelector.d.ts +0 -9
- package/dist/chart/chart-settings/ChartTypeSelector.d.ts.map +0 -1
- package/dist/chart/chart-settings/ChartTypeSelector.js +0 -16
- package/dist/chart/chart-settings/ChartTypeSelector.js.map +0 -1
- package/dist/chart/chart-settings/useTableColumns.d.ts +0 -3
- package/dist/chart/chart-settings/useTableColumns.d.ts.map +0 -1
- package/dist/chart/chart-settings/useTableColumns.js +0 -12
- package/dist/chart/chart-settings/useTableColumns.js.map +0 -1
- package/dist/chart/useBrushSelectionParams.d.ts +0 -3
- package/dist/chart/useBrushSelectionParams.d.ts.map +0 -1
- package/dist/chart/useBrushSelectionParams.js +0 -16
- package/dist/chart/useBrushSelectionParams.js.map +0 -1
- package/dist/chart/useChartRetainer.d.ts +0 -3
- package/dist/chart/useChartRetainer.d.ts.map +0 -1
- package/dist/chart/useChartRetainer.js +0 -11
- package/dist/chart/useChartRetainer.js.map +0 -1
- package/dist/chart/useGenerateSpec.d.ts +0 -13
- package/dist/chart/useGenerateSpec.d.ts.map +0 -1
- package/dist/chart/useGenerateSpec.js +0 -32
- package/dist/chart/useGenerateSpec.js.map +0 -1
- package/dist/chart-builders/AggregationSelector.d.ts +0 -11
- package/dist/chart-builders/AggregationSelector.d.ts.map +0 -1
- package/dist/chart-builders/AggregationSelector.js.map +0 -1
- package/dist/chart-builders/ColumnSelector.d.ts.map +0 -1
- package/dist/chart-builders/ColumnSelector.js +0 -30
- package/dist/chart-builders/ColumnSelector.js.map +0 -1
- package/dist/chart-builders/ColumnsContext.d.ts +0 -13
- package/dist/chart-builders/ColumnsContext.d.ts.map +0 -1
- package/dist/chart-builders/ColumnsContext.js +0 -15
- package/dist/chart-builders/ColumnsContext.js.map +0 -1
- package/dist/chart-builders/Field.d.ts.map +0 -1
- package/dist/chart-builders/Field.js.map +0 -1
- package/dist/chart-builders/FieldSelectorInput.d.ts +0 -14
- package/dist/chart-builders/FieldSelectorInput.d.ts.map +0 -1
- package/dist/chart-builders/FieldSelectorInput.js.map +0 -1
- package/dist/chart-builders/MultiFieldSelector.d.ts +0 -14
- package/dist/chart-builders/MultiFieldSelector.d.ts.map +0 -1
- package/dist/chart-builders/MultiFieldSelector.js +0 -53
- package/dist/chart-builders/MultiFieldSelector.js.map +0 -1
- package/dist/chart-builders/TableSelector.d.ts.map +0 -1
- package/dist/chart-builders/TableSelector.js +0 -23
- package/dist/chart-builders/TableSelector.js.map +0 -1
- package/dist/chart-builders/TemporalGranularitySelector.d.ts +0 -10
- package/dist/chart-builders/TemporalGranularitySelector.d.ts.map +0 -1
- package/dist/chart-builders/TemporalGranularitySelector.js +0 -37
- package/dist/chart-builders/TemporalGranularitySelector.js.map +0 -1
- package/dist/chart-builders/constants.d.ts +0 -12
- package/dist/chart-builders/constants.d.ts.map +0 -1
- package/dist/chart-builders/constants.js +0 -47
- package/dist/chart-builders/constants.js.map +0 -1
- package/dist/chart-types/base-types.d.ts +0 -168
- package/dist/chart-types/base-types.d.ts.map +0 -1
- package/dist/chart-types/base-types.js.map +0 -1
- package/dist/chart-types/box-plot/BoxPlotSettings.d.ts.map +0 -1
- package/dist/chart-types/box-plot/BoxPlotSettings.js +0 -9
- package/dist/chart-types/box-plot/BoxPlotSettings.js.map +0 -1
- package/dist/chart-types/box-plot/definition.d.ts.map +0 -1
- package/dist/chart-types/box-plot/definition.js +0 -24
- package/dist/chart-types/box-plot/definition.js.map +0 -1
- package/dist/chart-types/box-plot/renderer/BoxPlotErrorBoundary.d.ts.map +0 -1
- package/dist/chart-types/box-plot/renderer/BoxPlotErrorBoundary.js.map +0 -1
- package/dist/chart-types/box-plot/renderer/BoxPlotPanelRenderer.d.ts.map +0 -1
- package/dist/chart-types/box-plot/renderer/BoxPlotPanelRenderer.js +0 -118
- package/dist/chart-types/box-plot/renderer/BoxPlotPanelRenderer.js.map +0 -1
- package/dist/chart-types/box-plot/renderer/constants.d.ts +0 -24
- package/dist/chart-types/box-plot/renderer/constants.d.ts.map +0 -1
- package/dist/chart-types/box-plot/renderer/constants.js.map +0 -1
- package/dist/chart-types/box-plot/renderer/plot.d.ts +0 -14
- package/dist/chart-types/box-plot/renderer/plot.d.ts.map +0 -1
- package/dist/chart-types/box-plot/renderer/plot.js.map +0 -1
- package/dist/chart-types/box-plot/renderer/useBoxPlotClient.d.ts +0 -18
- package/dist/chart-types/box-plot/renderer/useBoxPlotClient.d.ts.map +0 -1
- package/dist/chart-types/box-plot/renderer/useBoxPlotClient.js +0 -56
- package/dist/chart-types/box-plot/renderer/useBoxPlotClient.js.map +0 -1
- package/dist/chart-types/box-plot/renderer/utils.d.ts +0 -6
- package/dist/chart-types/box-plot/renderer/utils.d.ts.map +0 -1
- package/dist/chart-types/box-plot/renderer/utils.js.map +0 -1
- package/dist/chart-types/box-plot/schema.d.ts +0 -21
- package/dist/chart-types/box-plot/schema.d.ts.map +0 -1
- package/dist/chart-types/box-plot/schema.js +0 -13
- package/dist/chart-types/box-plot/schema.js.map +0 -1
- package/dist/chart-types/box-plot/tool.d.ts +0 -40
- package/dist/chart-types/box-plot/tool.d.ts.map +0 -1
- package/dist/chart-types/box-plot/tool.js +0 -67
- package/dist/chart-types/box-plot/tool.js.map +0 -1
- package/dist/chart-types/bubble-chart/BubbleChartSettings.d.ts.map +0 -1
- package/dist/chart-types/bubble-chart/BubbleChartSettings.js +0 -9
- package/dist/chart-types/bubble-chart/BubbleChartSettings.js.map +0 -1
- package/dist/chart-types/bubble-chart/definition.d.ts.map +0 -1
- package/dist/chart-types/bubble-chart/definition.js +0 -24
- package/dist/chart-types/bubble-chart/definition.js.map +0 -1
- package/dist/chart-types/bubble-chart/schema.d.ts.map +0 -1
- package/dist/chart-types/bubble-chart/schema.js.map +0 -1
- package/dist/chart-types/bubble-chart/spec.d.ts.map +0 -1
- package/dist/chart-types/bubble-chart/spec.js +0 -31
- package/dist/chart-types/bubble-chart/spec.js.map +0 -1
- package/dist/chart-types/bubble-chart/tool.d.ts.map +0 -1
- package/dist/chart-types/bubble-chart/tool.js +0 -66
- package/dist/chart-types/bubble-chart/tool.js.map +0 -1
- package/dist/chart-types/chart-config.d.ts +0 -138
- package/dist/chart-types/chart-config.d.ts.map +0 -1
- package/dist/chart-types/chart-config.js +0 -49
- package/dist/chart-types/chart-config.js.map +0 -1
- package/dist/chart-types/count-plot/CountPlotSettings.d.ts.map +0 -1
- package/dist/chart-types/count-plot/CountPlotSettings.js +0 -9
- package/dist/chart-types/count-plot/CountPlotSettings.js.map +0 -1
- package/dist/chart-types/count-plot/definition.d.ts.map +0 -1
- package/dist/chart-types/count-plot/definition.js +0 -19
- package/dist/chart-types/count-plot/definition.js.map +0 -1
- package/dist/chart-types/count-plot/schema.d.ts.map +0 -1
- package/dist/chart-types/count-plot/schema.js.map +0 -1
- package/dist/chart-types/count-plot/spec.d.ts.map +0 -1
- package/dist/chart-types/count-plot/spec.js +0 -49
- package/dist/chart-types/count-plot/spec.js.map +0 -1
- package/dist/chart-types/count-plot/tool.d.ts.map +0 -1
- package/dist/chart-types/count-plot/tool.js +0 -63
- package/dist/chart-types/count-plot/tool.js.map +0 -1
- package/dist/chart-types/custom-spec/CustomSpecSettings.d.ts.map +0 -1
- package/dist/chart-types/custom-spec/CustomSpecSettings.js +0 -30
- package/dist/chart-types/custom-spec/CustomSpecSettings.js.map +0 -1
- package/dist/chart-types/custom-spec/definition.d.ts.map +0 -1
- package/dist/chart-types/custom-spec/definition.js +0 -22
- package/dist/chart-types/custom-spec/definition.js.map +0 -1
- package/dist/chart-types/custom-spec/schema.d.ts.map +0 -1
- package/dist/chart-types/custom-spec/schema.js.map +0 -1
- package/dist/chart-types/custom-spec/spec.d.ts.map +0 -1
- package/dist/chart-types/custom-spec/spec.js.map +0 -1
- package/dist/chart-types/data-policy-schema.d.ts.map +0 -1
- package/dist/chart-types/data-policy-schema.js.map +0 -1
- package/dist/chart-types/errors.d.ts +0 -23
- package/dist/chart-types/errors.d.ts.map +0 -1
- package/dist/chart-types/errors.js +0 -26
- package/dist/chart-types/errors.js.map +0 -1
- package/dist/chart-types/heatmap/HeatmapSettings.d.ts.map +0 -1
- package/dist/chart-types/heatmap/HeatmapSettings.js +0 -9
- package/dist/chart-types/heatmap/HeatmapSettings.js.map +0 -1
- package/dist/chart-types/heatmap/definition.d.ts.map +0 -1
- package/dist/chart-types/heatmap/definition.js +0 -19
- package/dist/chart-types/heatmap/definition.js.map +0 -1
- package/dist/chart-types/heatmap/schema.d.ts.map +0 -1
- package/dist/chart-types/heatmap/schema.js.map +0 -1
- package/dist/chart-types/heatmap/spec.d.ts.map +0 -1
- package/dist/chart-types/heatmap/spec.js +0 -32
- package/dist/chart-types/heatmap/spec.js.map +0 -1
- package/dist/chart-types/heatmap/tool.d.ts.map +0 -1
- package/dist/chart-types/heatmap/tool.js +0 -67
- package/dist/chart-types/heatmap/tool.js.map +0 -1
- package/dist/chart-types/histogram/HistogramSettings.d.ts.map +0 -1
- package/dist/chart-types/histogram/HistogramSettings.js +0 -11
- package/dist/chart-types/histogram/HistogramSettings.js.map +0 -1
- package/dist/chart-types/histogram/definition.d.ts.map +0 -1
- package/dist/chart-types/histogram/definition.js +0 -19
- package/dist/chart-types/histogram/definition.js.map +0 -1
- package/dist/chart-types/histogram/schema.d.ts.map +0 -1
- package/dist/chart-types/histogram/schema.js.map +0 -1
- package/dist/chart-types/histogram/spec.d.ts.map +0 -1
- package/dist/chart-types/histogram/spec.js +0 -37
- package/dist/chart-types/histogram/spec.js.map +0 -1
- package/dist/chart-types/histogram/tool.d.ts.map +0 -1
- package/dist/chart-types/histogram/tool.js +0 -65
- package/dist/chart-types/histogram/tool.js.map +0 -1
- package/dist/chart-types/index.d.ts +0 -157
- package/dist/chart-types/index.d.ts.map +0 -1
- package/dist/chart-types/index.js +0 -106
- package/dist/chart-types/index.js.map +0 -1
- package/dist/chart-types/line-chart/LineChartSettings.d.ts.map +0 -1
- package/dist/chart-types/line-chart/LineChartSettings.js +0 -24
- package/dist/chart-types/line-chart/LineChartSettings.js.map +0 -1
- package/dist/chart-types/line-chart/definition.d.ts.map +0 -1
- package/dist/chart-types/line-chart/definition.js +0 -26
- package/dist/chart-types/line-chart/definition.js.map +0 -1
- package/dist/chart-types/line-chart/schema.d.ts +0 -88
- package/dist/chart-types/line-chart/schema.d.ts.map +0 -1
- package/dist/chart-types/line-chart/schema.js +0 -41
- package/dist/chart-types/line-chart/schema.js.map +0 -1
- package/dist/chart-types/line-chart/spec.d.ts.map +0 -1
- package/dist/chart-types/line-chart/spec.js +0 -91
- package/dist/chart-types/line-chart/spec.js.map +0 -1
- package/dist/chart-types/line-chart/tool.d.ts.map +0 -1
- package/dist/chart-types/line-chart/tool.js +0 -74
- package/dist/chart-types/line-chart/tool.js.map +0 -1
- package/dist/chart-types/list-panels-tool.d.ts +0 -35
- package/dist/chart-types/list-panels-tool.d.ts.map +0 -1
- package/dist/chart-types/list-panels-tool.js.map +0 -1
- package/dist/chart-types/profiler-tool.d.ts +0 -40
- package/dist/chart-types/profiler-tool.d.ts.map +0 -1
- package/dist/chart-types/profiler-tool.js +0 -73
- package/dist/chart-types/profiler-tool.js.map +0 -1
- package/dist/chart-types/remove-panel-tool.d.ts +0 -31
- package/dist/chart-types/remove-panel-tool.d.ts.map +0 -1
- package/dist/chart-types/remove-panel-tool.js.map +0 -1
- package/dist/chart-types/text-panel-tool.d.ts +0 -42
- package/dist/chart-types/text-panel-tool.d.ts.map +0 -1
- package/dist/chart-types/text-panel-tool.js +0 -71
- package/dist/chart-types/text-panel-tool.js.map +0 -1
- package/dist/chart-types/tool-helpers.d.ts +0 -44
- package/dist/chart-types/tool-helpers.d.ts.map +0 -1
- package/dist/chart-types/tool-helpers.js +0 -129
- package/dist/chart-types/tool-helpers.js.map +0 -1
- package/dist/chart-types/tool-schemas.d.ts.map +0 -1
- package/dist/chart-types/tool-schemas.js.map +0 -1
- package/dist/chart-types/tool-types.d.ts +0 -26
- package/dist/chart-types/tool-types.d.ts.map +0 -1
- package/dist/chart-types/tool-types.js.map +0 -1
- package/dist/chart-types/tool-validation.d.ts +0 -3
- package/dist/chart-types/tool-validation.d.ts.map +0 -1
- package/dist/chart-types/tool-validation.js.map +0 -1
- package/dist/chart-types/useChartTypeDefinition.d.ts +0 -3
- package/dist/chart-types/useChartTypeDefinition.d.ts.map +0 -1
- package/dist/chart-types/useChartTypeDefinition.js.map +0 -1
- package/dist/dashboard/DashboardPanelErrorBoundary.d.ts +0 -17
- package/dist/dashboard/DashboardPanelErrorBoundary.d.ts.map +0 -1
- package/dist/dashboard/DashboardPanelErrorBoundary.js +0 -21
- package/dist/dashboard/DashboardPanelErrorBoundary.js.map +0 -1
- package/dist/dashboard/MosaicDashboardEmptyState.d.ts +0 -2
- package/dist/dashboard/MosaicDashboardEmptyState.d.ts.map +0 -1
- package/dist/dashboard/MosaicDashboardEmptyState.js +0 -14
- package/dist/dashboard/MosaicDashboardEmptyState.js.map +0 -1
- package/dist/dashboard/MosaicDashboardPanel.d.ts.map +0 -1
- package/dist/dashboard/MosaicDashboardPanel.js +0 -23
- package/dist/dashboard/MosaicDashboardPanel.js.map +0 -1
- package/dist/dashboard/MosaicDashboardPanelDragOverlay.d.ts.map +0 -1
- package/dist/dashboard/MosaicDashboardPanelDragOverlay.js +0 -17
- package/dist/dashboard/MosaicDashboardPanelDragOverlay.js.map +0 -1
- package/dist/dashboard/MosaicDashboardPanelHeader.d.ts +0 -13
- package/dist/dashboard/MosaicDashboardPanelHeader.d.ts.map +0 -1
- package/dist/dashboard/MosaicDashboardPanelHeader.js +0 -30
- package/dist/dashboard/MosaicDashboardPanelHeader.js.map +0 -1
- package/dist/dashboard/MosaicDashboardPanelLayout.d.ts.map +0 -1
- package/dist/dashboard/MosaicDashboardPanelLayout.js.map +0 -1
- package/dist/dashboard/MosaicDashboardPanels.d.ts.map +0 -1
- package/dist/dashboard/MosaicDashboardPanels.js +0 -54
- package/dist/dashboard/MosaicDashboardPanels.js.map +0 -1
- package/dist/dashboard/defaultPanelRenderers.d.ts +0 -3
- package/dist/dashboard/defaultPanelRenderers.d.ts.map +0 -1
- package/dist/dashboard/defaultPanelRenderers.js +0 -13
- package/dist/dashboard/defaultPanelRenderers.js.map +0 -1
- package/dist/dashboard/initial-state/BuildDashboardManuallyPanel.d.ts +0 -6
- package/dist/dashboard/initial-state/BuildDashboardManuallyPanel.d.ts.map +0 -1
- package/dist/dashboard/initial-state/BuildDashboardManuallyPanel.js +0 -46
- package/dist/dashboard/initial-state/BuildDashboardManuallyPanel.js.map +0 -1
- package/dist/dashboard/initial-state/BuildDashboardWithAIPanel.d.ts +0 -7
- package/dist/dashboard/initial-state/BuildDashboardWithAIPanel.d.ts.map +0 -1
- package/dist/dashboard/initial-state/BuildDashboardWithAIPanel.js +0 -29
- package/dist/dashboard/initial-state/BuildDashboardWithAIPanel.js.map +0 -1
- package/dist/dashboard/initial-state/MosaicDashboardInitialState.d.ts +0 -6
- package/dist/dashboard/initial-state/MosaicDashboardInitialState.d.ts.map +0 -1
- package/dist/dashboard/initial-state/MosaicDashboardInitialState.js +0 -9
- package/dist/dashboard/initial-state/MosaicDashboardInitialState.js.map +0 -1
- package/dist/dashboard/useTablesWithColumns.d.ts.map +0 -1
- package/dist/dashboard/useTablesWithColumns.js +0 -13
- package/dist/dashboard/useTablesWithColumns.js.map +0 -1
- package/dist/profiler/MosaicDashboardProfilerPanelRenderer.d.ts +0 -4
- package/dist/profiler/MosaicDashboardProfilerPanelRenderer.d.ts.map +0 -1
- package/dist/profiler/MosaicDashboardProfilerPanelRenderer.js +0 -32
- package/dist/profiler/MosaicDashboardProfilerPanelRenderer.js.map +0 -1
- package/dist/profiler/MosaicProfiler.d.ts +0 -32
- package/dist/profiler/MosaicProfiler.d.ts.map +0 -1
- package/dist/profiler/MosaicProfiler.js +0 -57
- package/dist/profiler/MosaicProfiler.js.map +0 -1
- package/dist/profiler/MosaicProfilerHeader.d.ts +0 -7
- package/dist/profiler/MosaicProfilerHeader.d.ts.map +0 -1
- package/dist/profiler/MosaicProfilerHeader.js +0 -196
- package/dist/profiler/MosaicProfilerHeader.js.map +0 -1
- package/dist/profiler/MosaicProfilerRows.d.ts +0 -9
- package/dist/profiler/MosaicProfilerRows.d.ts.map +0 -1
- package/dist/profiler/MosaicProfilerRows.js +0 -65
- package/dist/profiler/MosaicProfilerRows.js.map +0 -1
- package/dist/profiler/MosaicProfilerStatusBar.d.ts +0 -9
- package/dist/profiler/MosaicProfilerStatusBar.d.ts.map +0 -1
- package/dist/profiler/MosaicProfilerStatusBar.js +0 -28
- package/dist/profiler/MosaicProfilerStatusBar.js.map +0 -1
- package/dist/profiler/ProfilerCategoryClient.d.ts +0 -50
- package/dist/profiler/ProfilerCategoryClient.d.ts.map +0 -1
- package/dist/profiler/ProfilerCategoryClient.js +0 -121
- package/dist/profiler/ProfilerCategoryClient.js.map +0 -1
- package/dist/profiler/ProfilerCountClient.d.ts +0 -28
- package/dist/profiler/ProfilerCountClient.d.ts.map +0 -1
- package/dist/profiler/ProfilerCountClient.js +0 -51
- package/dist/profiler/ProfilerCountClient.js.map +0 -1
- package/dist/profiler/ProfilerHistogramClient.d.ts +0 -69
- package/dist/profiler/ProfilerHistogramClient.d.ts.map +0 -1
- package/dist/profiler/ProfilerHistogramClient.js +0 -179
- package/dist/profiler/ProfilerHistogramClient.js.map +0 -1
- package/dist/profiler/ProfilerPageClient.d.ts +0 -37
- package/dist/profiler/ProfilerPageClient.d.ts.map +0 -1
- package/dist/profiler/ProfilerPageClient.js +0 -65
- package/dist/profiler/ProfilerPageClient.js.map +0 -1
- package/dist/profiler/ProfilerUnsupportedSummaryClient.d.ts +0 -24
- package/dist/profiler/ProfilerUnsupportedSummaryClient.d.ts.map +0 -1
- package/dist/profiler/ProfilerUnsupportedSummaryClient.js +0 -51
- package/dist/profiler/ProfilerUnsupportedSummaryClient.js.map +0 -1
- package/dist/profiler/addProfilerPanelAction.d.ts +0 -3
- package/dist/profiler/addProfilerPanelAction.d.ts.map +0 -1
- package/dist/profiler/addProfilerPanelAction.js +0 -9
- package/dist/profiler/addProfilerPanelAction.js.map +0 -1
- package/dist/profiler/createProfilerStore.d.ts +0 -45
- package/dist/profiler/createProfilerStore.d.ts.map +0 -1
- package/dist/profiler/createProfilerStore.js +0 -120
- package/dist/profiler/createProfilerStore.js.map +0 -1
- package/dist/profiler/layout.d.ts +0 -7
- package/dist/profiler/layout.d.ts.map +0 -1
- package/dist/profiler/layout.js +0 -13
- package/dist/profiler/layout.js.map +0 -1
- package/dist/profiler/profilerController.d.ts +0 -64
- package/dist/profiler/profilerController.d.ts.map +0 -1
- package/dist/profiler/profilerController.js +0 -123
- package/dist/profiler/profilerController.js.map +0 -1
- package/dist/profiler/types.d.ts +0 -86
- package/dist/profiler/types.d.ts.map +0 -1
- package/dist/profiler/types.js.map +0 -1
- package/dist/profiler/useMosaicProfiler.d.ts +0 -7
- package/dist/profiler/useMosaicProfiler.d.ts.map +0 -1
- package/dist/profiler/useMosaicProfiler.js +0 -339
- package/dist/profiler/useMosaicProfiler.js.map +0 -1
- package/dist/profiler/utils.d.ts +0 -61
- package/dist/profiler/utils.d.ts.map +0 -1
- package/dist/profiler/utils.js +0 -347
- package/dist/profiler/utils.js.map +0 -1
- package/dist/text/MosaicDashboardTextRenderer.d.ts +0 -4
- package/dist/text/MosaicDashboardTextRenderer.d.ts.map +0 -1
- package/dist/text/MosaicDashboardTextRenderer.js +0 -46
- package/dist/text/MosaicDashboardTextRenderer.js.map +0 -1
- package/dist/text/addTextPanelAction.d.ts +0 -3
- package/dist/text/addTextPanelAction.d.ts.map +0 -1
- package/dist/text/addTextPanelAction.js +0 -9
- package/dist/text/addTextPanelAction.js.map +0 -1
- /package/dist/{chart-types → ai}/list-panels-tool.js +0 -0
- /package/dist/{chart-types → ai}/remove-panel-tool.js +0 -0
- /package/dist/{chart-types → ai}/tool-schemas.d.ts +0 -0
- /package/dist/{chart-types → ai}/tool-schemas.js +0 -0
- /package/dist/{chart-types → ai}/tool-types.js +0 -0
- /package/dist/{chart-types → ai}/tool-validation.js +0 -0
- /package/dist/{chart → charts}/addChartPanelAction.d.ts +0 -0
- /package/dist/{chart → charts}/addChartPanelAction.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/base-types.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/box-plot/BoxPlotSettings.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/box-plot/definition.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/box-plot/renderer/BoxPlotErrorBoundary.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/box-plot/renderer/BoxPlotErrorBoundary.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/box-plot/renderer/BoxPlotPanelRenderer.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/box-plot/renderer/constants.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/box-plot/renderer/plot.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/box-plot/renderer/utils.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/bubble-chart/BubbleChartSettings.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/bubble-chart/definition.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/bubble-chart/schema.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/bubble-chart/schema.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/bubble-chart/spec.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/bubble-chart/tool.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/count-plot/CountPlotSettings.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/count-plot/definition.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/count-plot/schema.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/count-plot/schema.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/count-plot/spec.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/count-plot/tool.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/custom-spec/CustomSpecSettings.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/custom-spec/definition.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/custom-spec/schema.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/custom-spec/schema.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/custom-spec/spec.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/custom-spec/spec.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/data-policy-schema.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/data-policy-schema.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/heatmap/HeatmapSettings.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/heatmap/definition.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/heatmap/schema.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/heatmap/schema.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/heatmap/spec.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/heatmap/tool.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/histogram/HistogramSettings.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/histogram/definition.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/histogram/schema.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/histogram/schema.js +0 -0
- /package/dist/{chart-types → charts/chart-types}/histogram/spec.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/histogram/tool.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/line-chart/LineChartSettings.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/line-chart/definition.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/line-chart/spec.d.ts +0 -0
- /package/dist/{chart-types → charts/chart-types}/line-chart/tool.d.ts +0 -0
- /package/dist/{chart-types → charts}/useChartTypeDefinition.js +0 -0
- /package/dist/{chart-builders → components}/AggregationSelector.js +0 -0
- /package/dist/{chart-builders → components}/ColumnSelector.d.ts +0 -0
- /package/dist/{chart-builders → components}/Field.d.ts +0 -0
- /package/dist/{chart-builders → components}/Field.js +0 -0
- /package/dist/{chart-builders → components}/FieldSelectorInput.js +0 -0
- /package/dist/{chart-builders → components}/TableSelector.d.ts +0 -0
- /package/dist/dashboard/{MosaicDashboardPanel.d.ts → panel/MosaicDashboardPanel.d.ts} +0 -0
- /package/dist/dashboard/{MosaicDashboardPanelDragOverlay.d.ts → panel/MosaicDashboardPanelDragOverlay.d.ts} +0 -0
- /package/dist/dashboard/{MosaicDashboardPanelLayout.d.ts → panel/MosaicDashboardPanelLayout.d.ts} +0 -0
- /package/dist/dashboard/{MosaicDashboardPanelLayout.js → panel/MosaicDashboardPanelLayout.js} +0 -0
- /package/dist/dashboard/{MosaicDashboardPanels.d.ts → panel/MosaicDashboardPanels.d.ts} +0 -0
- /package/dist/{profiler → data-table-explorer}/types.js +0 -0
- /package/dist/{dashboard → hooks}/useTablesWithColumns.d.ts +0 -0
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { MosaicClient, type Selection } from '@uwdata/mosaic-core';
|
|
2
|
+
import { type ExprNode, type Query } from '@uwdata/mosaic-sql';
|
|
3
|
+
import type { Table } from 'apache-arrow';
|
|
4
|
+
import type { DataTableExplorerPaginationState, DataTableExplorerSorting } from './types';
|
|
5
|
+
export type DataTableExplorerPageState = {
|
|
6
|
+
datasetId?: string;
|
|
7
|
+
error?: Error;
|
|
8
|
+
isLoading: boolean;
|
|
9
|
+
pageTable?: Table;
|
|
10
|
+
};
|
|
11
|
+
type DataTableExplorerPageClientOptions = {
|
|
12
|
+
columns: string[];
|
|
13
|
+
filter?: ReturnType<Selection['predicate']>;
|
|
14
|
+
onStateChange: (state: DataTableExplorerPageState) => void;
|
|
15
|
+
pagination: DataTableExplorerPaginationState;
|
|
16
|
+
sorting: DataTableExplorerSorting;
|
|
17
|
+
tableName: string;
|
|
18
|
+
};
|
|
19
|
+
export declare class DataTableExplorerPageClient extends MosaicClient {
|
|
20
|
+
private readonly columns;
|
|
21
|
+
private readonly datasetId;
|
|
22
|
+
private error?;
|
|
23
|
+
private readonly filter?;
|
|
24
|
+
private readonly onStateChange;
|
|
25
|
+
private readonly pagination;
|
|
26
|
+
private pageTable?;
|
|
27
|
+
private readonly sorting;
|
|
28
|
+
private readonly tableName;
|
|
29
|
+
constructor(options: DataTableExplorerPageClientOptions);
|
|
30
|
+
get filterStable(): boolean;
|
|
31
|
+
queryPending(): this;
|
|
32
|
+
query(filter?: Array<ExprNode>): Query;
|
|
33
|
+
queryResult(data: unknown): this;
|
|
34
|
+
queryError(error: Error): this;
|
|
35
|
+
}
|
|
36
|
+
export {};
|
|
37
|
+
//# sourceMappingURL=DataTableExplorerPageClient.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DataTableExplorerPageClient.d.ts","sourceRoot":"","sources":["../../src/data-table-explorer/DataTableExplorerPageClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,YAAY,EAAE,KAAK,SAAS,EAAC,MAAM,qBAAqB,CAAC;AACjE,OAAO,EAAC,KAAK,QAAQ,EAAE,KAAK,KAAK,EAAC,MAAM,oBAAoB,CAAC;AAC7D,OAAO,KAAK,EAAC,KAAK,EAAC,MAAM,cAAc,CAAC;AACxC,OAAO,KAAK,EACV,gCAAgC,EAChC,wBAAwB,EACzB,MAAM,SAAS,CAAC;AAMjB,MAAM,MAAM,0BAA0B,GAAG;IACvC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,SAAS,EAAE,OAAO,CAAC;IACnB,SAAS,CAAC,EAAE,KAAK,CAAC;CACnB,CAAC;AAEF,KAAK,kCAAkC,GAAG;IACxC,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,MAAM,CAAC,EAAE,UAAU,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC,CAAC;IAC5C,aAAa,EAAE,CAAC,KAAK,EAAE,0BAA0B,KAAK,IAAI,CAAC;IAC3D,UAAU,EAAE,gCAAgC,CAAC;IAC7C,OAAO,EAAE,wBAAwB,CAAC;IAClC,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,qBAAa,2BAA4B,SAAQ,YAAY;IAC3D,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAW;IACnC,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAS;IACnC,OAAO,CAAC,KAAK,CAAC,CAAQ;IACtB,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAqC;IAC7D,OAAO,CAAC,QAAQ,CAAC,aAAa,CAA8C;IAC5E,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAmC;IAC9D,OAAO,CAAC,SAAS,CAAC,CAAQ;IAC1B,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA2B;IACnD,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAS;gBAEvB,OAAO,EAAE,kCAAkC;IAWvD,IAAa,YAAY,IAAI,OAAO,CAEnC;IAEQ,YAAY,IAAI,IAAI;IAUpB,KAAK,CAAC,MAAM,GAAE,KAAK,CAAC,QAAQ,CAAM,GAAG,KAAK;IAa1C,WAAW,CAAC,IAAI,EAAE,OAAO,GAAG,IAAI;IAWhC,UAAU,CAAC,KAAK,EAAE,KAAK,GAAG,IAAI;CAUxC"}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { MosaicClient } from '@uwdata/mosaic-core';
|
|
2
|
+
import { buildDataTableExplorerBaseQuery, buildDataTableExplorerPageQuery, } from './utils';
|
|
3
|
+
export class DataTableExplorerPageClient extends MosaicClient {
|
|
4
|
+
columns;
|
|
5
|
+
datasetId;
|
|
6
|
+
error;
|
|
7
|
+
filter;
|
|
8
|
+
onStateChange;
|
|
9
|
+
pagination;
|
|
10
|
+
pageTable;
|
|
11
|
+
sorting;
|
|
12
|
+
tableName;
|
|
13
|
+
constructor(options) {
|
|
14
|
+
super();
|
|
15
|
+
this.columns = options.columns;
|
|
16
|
+
this.datasetId = [options.tableName, ...options.columns].join('\u0001');
|
|
17
|
+
this.filter = options.filter ?? [];
|
|
18
|
+
this.onStateChange = options.onStateChange;
|
|
19
|
+
this.pagination = options.pagination;
|
|
20
|
+
this.sorting = options.sorting;
|
|
21
|
+
this.tableName = options.tableName;
|
|
22
|
+
}
|
|
23
|
+
get filterStable() {
|
|
24
|
+
return false;
|
|
25
|
+
}
|
|
26
|
+
queryPending() {
|
|
27
|
+
this.onStateChange({
|
|
28
|
+
datasetId: this.datasetId,
|
|
29
|
+
error: this.error,
|
|
30
|
+
isLoading: true,
|
|
31
|
+
pageTable: this.pageTable,
|
|
32
|
+
});
|
|
33
|
+
return this;
|
|
34
|
+
}
|
|
35
|
+
query(filter = []) {
|
|
36
|
+
const resolvedFilter = this.filter ?? filter;
|
|
37
|
+
return buildDataTableExplorerPageQuery(buildDataTableExplorerBaseQuery({
|
|
38
|
+
columns: this.columns,
|
|
39
|
+
filter: resolvedFilter,
|
|
40
|
+
sorting: this.sorting,
|
|
41
|
+
tableName: this.tableName,
|
|
42
|
+
}), this.pagination);
|
|
43
|
+
}
|
|
44
|
+
queryResult(data) {
|
|
45
|
+
this.error = undefined;
|
|
46
|
+
this.pageTable = data;
|
|
47
|
+
this.onStateChange({
|
|
48
|
+
datasetId: this.datasetId,
|
|
49
|
+
isLoading: false,
|
|
50
|
+
pageTable: this.pageTable,
|
|
51
|
+
});
|
|
52
|
+
return this;
|
|
53
|
+
}
|
|
54
|
+
queryError(error) {
|
|
55
|
+
this.error = error;
|
|
56
|
+
this.onStateChange({
|
|
57
|
+
datasetId: this.datasetId,
|
|
58
|
+
error,
|
|
59
|
+
isLoading: false,
|
|
60
|
+
pageTable: this.pageTable,
|
|
61
|
+
});
|
|
62
|
+
return this;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
//# sourceMappingURL=DataTableExplorerPageClient.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DataTableExplorerPageClient.js","sourceRoot":"","sources":["../../src/data-table-explorer/DataTableExplorerPageClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,YAAY,EAAiB,MAAM,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C9B,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,MAAM,EAAE,cAAc;YACtB,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,SAAS,EAAE,IAAI,CAAC,SAAS;SAC1B,CAAC,EACF,IAAI,CAAC,UAAU,CAChB,CAAC;IACJ,CAAC;IAEQ,WAAW,CAAC,IAAa;QAChC,IAAI,CAAC,KAAK,GAAG,SAAS,CAAC;QACvB,IAAI,CAAC,SAAS,GAAG,IAAa,CAAC;QAC/B,IAAI,CAAC,aAAa,CAAC;YACjB,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,SAAS,EAAE,KAAK;YAChB,SAAS,EAAE,IAAI,CAAC,SAAS;SAC1B,CAAC,CAAC;QACH,OAAO,IAAI,CAAC;IACd,CAAC;IAEQ,UAAU,CAAC,KAAY;QAC9B,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACnB,IAAI,CAAC,aAAa,CAAC;YACjB,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,KAAK;YACL,SAAS,EAAE,KAAK;YAChB,SAAS,EAAE,IAAI,CAAC,SAAS;SAC1B,CAAC,CAAC;QACH,OAAO,IAAI,CAAC;IACd,CAAC;CACF","sourcesContent":["import {MosaicClient, type Selection} from '@uwdata/mosaic-core';\nimport {type ExprNode, type Query} from '@uwdata/mosaic-sql';\nimport type {Table} from 'apache-arrow';\nimport type {\n DataTableExplorerPaginationState,\n DataTableExplorerSorting,\n} from './types';\nimport {\n buildDataTableExplorerBaseQuery,\n buildDataTableExplorerPageQuery,\n} from './utils';\n\nexport type DataTableExplorerPageState = {\n datasetId?: string;\n error?: Error;\n isLoading: boolean;\n pageTable?: Table;\n};\n\ntype DataTableExplorerPageClientOptions = {\n columns: string[];\n filter?: ReturnType<Selection['predicate']>;\n onStateChange: (state: DataTableExplorerPageState) => void;\n pagination: DataTableExplorerPaginationState;\n sorting: DataTableExplorerSorting;\n tableName: string;\n};\n\nexport class DataTableExplorerPageClient extends MosaicClient {\n private readonly columns: string[];\n private readonly datasetId: string;\n private error?: Error;\n private readonly filter?: ReturnType<Selection['predicate']>;\n private readonly onStateChange: (state: DataTableExplorerPageState) => void;\n private readonly pagination: DataTableExplorerPaginationState;\n private pageTable?: Table;\n private readonly sorting: DataTableExplorerSorting;\n private readonly tableName: string;\n\n constructor(options: DataTableExplorerPageClientOptions) {\n super();\n this.columns = options.columns;\n this.datasetId = [options.tableName, ...options.columns].join('\\u0001');\n this.filter = options.filter ?? [];\n this.onStateChange = options.onStateChange;\n this.pagination = options.pagination;\n this.sorting = options.sorting;\n this.tableName = options.tableName;\n }\n\n override get filterStable(): boolean {\n return false;\n }\n\n override queryPending(): this {\n this.onStateChange({\n datasetId: this.datasetId,\n error: this.error,\n isLoading: true,\n pageTable: this.pageTable,\n });\n return this;\n }\n\n override query(filter: Array<ExprNode> = []): Query {\n const resolvedFilter = this.filter ?? filter;\n return buildDataTableExplorerPageQuery(\n buildDataTableExplorerBaseQuery({\n columns: this.columns,\n filter: resolvedFilter,\n sorting: this.sorting,\n tableName: this.tableName,\n }),\n this.pagination,\n );\n }\n\n override queryResult(data: unknown): this {\n this.error = undefined;\n this.pageTable = data as Table;\n this.onStateChange({\n datasetId: this.datasetId,\n isLoading: false,\n pageTable: this.pageTable,\n });\n return this;\n }\n\n override queryError(error: Error): this {\n this.error = error;\n this.onStateChange({\n datasetId: this.datasetId,\n error,\n isLoading: false,\n pageTable: this.pageTable,\n });\n return this;\n }\n}\n"]}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { UseDataTableExplorerReturn } from './types';
|
|
2
|
+
export type DataTableExplorerRowsProps = {
|
|
3
|
+
className?: string;
|
|
4
|
+
explorer: Pick<UseDataTableExplorerReturn, 'columns' | 'pageTable' | 'pagination' | 'tableError'>;
|
|
5
|
+
};
|
|
6
|
+
declare function DataTableExplorerRowsImpl({ className, explorer, }: DataTableExplorerRowsProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
export declare const DataTableExplorerRows: import("react").MemoExoticComponent<typeof DataTableExplorerRowsImpl>;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=DataTableExplorerRows.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DataTableExplorerRows.d.ts","sourceRoot":"","sources":["../../src/data-table-explorer/DataTableExplorerRows.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAC,0BAA0B,EAAC,MAAM,SAAS,CAAC;AAGxD,MAAM,MAAM,0BAA0B,GAAG;IACvC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,IAAI,CACZ,0BAA0B,EAC1B,SAAS,GAAG,WAAW,GAAG,YAAY,GAAG,YAAY,CACtD,CAAC;CACH,CAAC;AA4HF,iBAAS,yBAAyB,CAAC,EACjC,SAAS,EACT,QAAQ,GACT,EAAE,0BAA0B,2CA2C5B;AAoBD,eAAO,MAAM,qBAAqB,uEAWjC,CAAC"}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { ArrowCellValue, isNumericArrowType } from '@sqlrooms/data-table';
|
|
3
|
+
import { cn, TableBody, TableCell, TableRow } from '@sqlrooms/ui';
|
|
4
|
+
import * as arrow from 'apache-arrow';
|
|
5
|
+
import { memo } from 'react';
|
|
6
|
+
import { DATA_TABLE_EXPLORER_DEFAULT_COLUMN_WIDTH_STYLE, DATA_TABLE_EXPLORER_ROW_NUMBER_WIDTH_STYLE, DATA_TABLE_EXPLORER_UNSUPPORTED_COLUMN_WIDTH_STYLE, } from './layout';
|
|
7
|
+
import { isDataTableExplorerUnsupportedSummaryType } from './utils';
|
|
8
|
+
const ROW_NUMBER_CLASS = 'bg-background text-muted-foreground sticky left-0 z-10 border-r px-1 text-center';
|
|
9
|
+
function getColumnWidthStyle(field) {
|
|
10
|
+
return isDataTableExplorerUnsupportedSummaryType(field.type)
|
|
11
|
+
? DATA_TABLE_EXPLORER_UNSUPPORTED_COLUMN_WIDTH_STYLE
|
|
12
|
+
: DATA_TABLE_EXPLORER_DEFAULT_COLUMN_WIDTH_STYLE;
|
|
13
|
+
}
|
|
14
|
+
function formatDataTableExplorerValue(type, value) {
|
|
15
|
+
if (arrow.DataType.isBinary(type) && value instanceof Uint8Array) {
|
|
16
|
+
return `${value.byteLength} bytes`;
|
|
17
|
+
}
|
|
18
|
+
return undefined;
|
|
19
|
+
}
|
|
20
|
+
function SizingRow({ columns, }) {
|
|
21
|
+
return (_jsxs(TableRow, { "aria-hidden": "true", className: "pointer-events-none h-0 border-0 opacity-0 hover:bg-transparent", children: [_jsx(TableCell, { className: "border-r p-0", style: DATA_TABLE_EXPLORER_ROW_NUMBER_WIDTH_STYLE }), columns.map((column) => (_jsx(TableCell, { className: "border-r p-0", style: getColumnWidthStyle(column.field) }, column.name)))] }));
|
|
22
|
+
}
|
|
23
|
+
function EmptyStateRow({ columns, message, tone = 'muted', }) {
|
|
24
|
+
return (_jsxs(TableRow, { children: [_jsx(TableCell, { className: ROW_NUMBER_CLASS, style: DATA_TABLE_EXPLORER_ROW_NUMBER_WIDTH_STYLE }), _jsx(TableCell, { colSpan: Math.max(columns.length, 1), className: cn('max-w-[240px] border-r p-4 align-top font-mono text-xs', tone === 'error'
|
|
25
|
+
? 'text-sm text-red-500'
|
|
26
|
+
: 'text-muted-foreground text-sm'), children: message })] }));
|
|
27
|
+
}
|
|
28
|
+
const DataRow = memo(function DataRow({ columns, pageIndex, pageSize, pageTable, rowIndex, }) {
|
|
29
|
+
return (_jsxs(TableRow, { children: [_jsx(TableCell, { className: ROW_NUMBER_CLASS, style: DATA_TABLE_EXPLORER_ROW_NUMBER_WIDTH_STYLE, children: pageIndex * pageSize + rowIndex + 1 }), columns.map((column) => {
|
|
30
|
+
const vector = pageTable.getChild(column.name);
|
|
31
|
+
const value = vector?.get(rowIndex);
|
|
32
|
+
return (_jsx(TableCell, { className: cn('max-w-[240px] overflow-hidden border-r align-top font-mono text-xs', isNumericArrowType(column.field.type) && 'text-right'), style: getColumnWidthStyle(column.field), children: _jsx("span", { className: "block min-w-0 overflow-hidden text-ellipsis whitespace-nowrap", children: _jsx(ArrowCellValue, { fieldName: column.name, fontSizeClass: "text-xs", formatValue: formatDataTableExplorerValue, type: column.field.type, value: value }) }) }, column.name));
|
|
33
|
+
})] }));
|
|
34
|
+
});
|
|
35
|
+
function DataTableExplorerRowsImpl({ className, explorer, }) {
|
|
36
|
+
if (explorer.tableError) {
|
|
37
|
+
return (_jsxs(TableBody, { className: className, children: [_jsx(SizingRow, { columns: explorer.columns }), _jsx(EmptyStateRow, { columns: explorer.columns, message: explorer.tableError.message, tone: "error" })] }));
|
|
38
|
+
}
|
|
39
|
+
if (!explorer.pageTable || explorer.pageTable.numRows === 0) {
|
|
40
|
+
return (_jsxs(TableBody, { className: className, children: [_jsx(SizingRow, { columns: explorer.columns }), _jsx(EmptyStateRow, { columns: explorer.columns, message: "No rows" })] }));
|
|
41
|
+
}
|
|
42
|
+
const rows = Array.from({ length: explorer.pageTable.numRows }, (_, index) => index);
|
|
43
|
+
const pageTable = explorer.pageTable;
|
|
44
|
+
return (_jsx(TableBody, { className: className, children: rows.map((rowIndex) => (_jsx(DataRow, { columns: explorer.columns, pageIndex: explorer.pagination.pageIndex, pageSize: explorer.pagination.pageSize, pageTable: pageTable, rowIndex: rowIndex }, rowIndex))) }));
|
|
45
|
+
}
|
|
46
|
+
function areRowColumnsEqual(left, right) {
|
|
47
|
+
if (left.length !== right.length) {
|
|
48
|
+
return false;
|
|
49
|
+
}
|
|
50
|
+
return left.every((column, index) => {
|
|
51
|
+
const other = right[index];
|
|
52
|
+
return (column.name === other?.name &&
|
|
53
|
+
column.kind === other.kind &&
|
|
54
|
+
column.field === other.field);
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
export const DataTableExplorerRows = memo(DataTableExplorerRowsImpl, (previous, next) => previous.className === next.className &&
|
|
58
|
+
previous.explorer.pageTable === next.explorer.pageTable &&
|
|
59
|
+
previous.explorer.tableError === next.explorer.tableError &&
|
|
60
|
+
previous.explorer.pagination.pageIndex ===
|
|
61
|
+
next.explorer.pagination.pageIndex &&
|
|
62
|
+
previous.explorer.pagination.pageSize ===
|
|
63
|
+
next.explorer.pagination.pageSize &&
|
|
64
|
+
areRowColumnsEqual(previous.explorer.columns, next.explorer.columns));
|
|
65
|
+
//# sourceMappingURL=DataTableExplorerRows.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DataTableExplorerRows.js","sourceRoot":"","sources":["../../src/data-table-explorer/DataTableExplorerRows.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAC,cAAc,EAAE,kBAAkB,EAAC,MAAM,sBAAsB,CAAC;AACxE,OAAO,EAAC,EAAE,EAAE,SAAS,EAAE,SAAS,EAAE,QAAQ,EAAC,MAAM,cAAc,CAAC;AAChE,OAAO,KAAK,KAAK,MAAM,cAAc,CAAC;AACtC,OAAO,EAAC,IAAI,EAAC,MAAM,OAAO,CAAC;AAC3B,OAAO,EACL,8CAA8C,EAC9C,0CAA0C,EAC1C,kDAAkD,GACnD,MAAM,UAAU,CAAC;AAElB,OAAO,EAAC,yCAAyC,EAAC,MAAM,SAAS,CAAC;AAUlE,MAAM,gBAAgB,GACpB,kFAAkF,CAAC;AAErF,SAAS,mBAAmB,CAAC,KAAkB;IAC7C,OAAO,yCAAyC,CAAC,KAAK,CAAC,IAAI,CAAC;QAC1D,CAAC,CAAC,kDAAkD;QACpD,CAAC,CAAC,8CAA8C,CAAC;AACrD,CAAC;AAED,SAAS,4BAA4B,CAAC,IAAoB,EAAE,KAAc;IACxE,IAAI,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,KAAK,YAAY,UAAU,EAAE,CAAC;QACjE,OAAO,GAAG,KAAK,CAAC,UAAU,QAAQ,CAAC;IACrC,CAAC;IACD,OAAO,SAAS,CAAC;AACnB,CAAC;AAED,SAAS,SAAS,C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E,IAAI,EAAE,EAAE,CACjB,QAAQ,CAAC,SAAS,KAAK,IAAI,CAAC,SAAS;IACrC,QAAQ,CAAC,QAAQ,CAAC,SAAS,KAAK,IAAI,CAAC,QAAQ,CAAC,SAAS;IACvD,QAAQ,CAAC,QAAQ,CAAC,UAAU,KAAK,IAAI,CAAC,QAAQ,CAAC,UAAU;IACzD,QAAQ,CAAC,QAAQ,CAAC,UAAU,CAAC,SAAS;QACpC,IAAI,CAAC,QAAQ,CAAC,UAAU,CAAC,SAAS;IACpC,QAAQ,CAAC,QAAQ,CAAC,UAAU,CAAC,QAAQ;QACnC,IAAI,CAAC,QAAQ,CAAC,UAAU,CAAC,QAAQ;IACnC,kBAAkB,CAAC,QAAQ,CAAC,QAAQ,CAAC,OAAO,EAAE,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,CACvE,CAAC","sourcesContent":["import {ArrowCellValue, isNumericArrowType} from '@sqlrooms/data-table';\nimport {cn, TableBody, TableCell, TableRow} from '@sqlrooms/ui';\nimport * as arrow from 'apache-arrow';\nimport {memo} from 'react';\nimport {\n DATA_TABLE_EXPLORER_DEFAULT_COLUMN_WIDTH_STYLE,\n DATA_TABLE_EXPLORER_ROW_NUMBER_WIDTH_STYLE,\n DATA_TABLE_EXPLORER_UNSUPPORTED_COLUMN_WIDTH_STYLE,\n} from './layout';\nimport type {UseDataTableExplorerReturn} from './types';\nimport {isDataTableExplorerUnsupportedSummaryType} from './utils';\n\nexport type DataTableExplorerRowsProps = {\n className?: string;\n explorer: Pick<\n UseDataTableExplorerReturn,\n 'columns' | 'pageTable' | 'pagination' | 'tableError'\n >;\n};\n\nconst ROW_NUMBER_CLASS =\n 'bg-background text-muted-foreground sticky left-0 z-10 border-r px-1 text-center';\n\nfunction getColumnWidthStyle(field: arrow.Field) {\n return isDataTableExplorerUnsupportedSummaryType(field.type)\n ? DATA_TABLE_EXPLORER_UNSUPPORTED_COLUMN_WIDTH_STYLE\n : DATA_TABLE_EXPLORER_DEFAULT_COLUMN_WIDTH_STYLE;\n}\n\nfunction formatDataTableExplorerValue(type: arrow.DataType, value: unknown) {\n if (arrow.DataType.isBinary(type) && value instanceof Uint8Array) {\n return `${value.byteLength} bytes`;\n }\n return undefined;\n}\n\nfunction SizingRow({\n columns,\n}: {\n columns: UseDataTableExplorerReturn['columns'];\n}) {\n return (\n <TableRow\n aria-hidden=\"true\"\n className=\"pointer-events-none h-0 border-0 opacity-0 hover:bg-transparent\"\n >\n <TableCell\n className=\"border-r p-0\"\n style={DATA_TABLE_EXPLORER_ROW_NUMBER_WIDTH_STYLE}\n />\n {columns.map((column) => (\n <TableCell\n key={column.name}\n className=\"border-r p-0\"\n style={getColumnWidthStyle(column.field)}\n />\n ))}\n </TableRow>\n );\n}\n\nfunction EmptyStateRow({\n columns,\n message,\n tone = 'muted',\n}: {\n columns: UseDataTableExplorerReturn['columns'];\n message: string;\n tone?: 'error' | 'muted';\n}) {\n return (\n <TableRow>\n <TableCell\n className={ROW_NUMBER_CLASS}\n style={DATA_TABLE_EXPLORER_ROW_NUMBER_WIDTH_STYLE}\n />\n <TableCell\n colSpan={Math.max(columns.length, 1)}\n className={cn(\n 'max-w-[240px] border-r p-4 align-top font-mono text-xs',\n tone === 'error'\n ? 'text-sm text-red-500'\n : 'text-muted-foreground text-sm',\n )}\n >\n {message}\n </TableCell>\n </TableRow>\n );\n}\n\ntype DataRowProps = {\n columns: UseDataTableExplorerReturn['columns'];\n pageIndex: number;\n pageSize: number;\n pageTable: NonNullable<UseDataTableExplorerReturn['pageTable']>;\n rowIndex: number;\n};\n\nconst DataRow = memo(function DataRow({\n columns,\n pageIndex,\n pageSize,\n pageTable,\n rowIndex,\n}: DataRowProps) {\n return (\n <TableRow>\n <TableCell\n className={ROW_NUMBER_CLASS}\n style={DATA_TABLE_EXPLORER_ROW_NUMBER_WIDTH_STYLE}\n >\n {pageIndex * pageSize + rowIndex + 1}\n </TableCell>\n {columns.map((column) => {\n const vector = pageTable.getChild(column.name) as arrow.Vector | null;\n const value = vector?.get(rowIndex);\n return (\n <TableCell\n key={column.name}\n className={cn(\n 'max-w-[240px] overflow-hidden border-r align-top font-mono text-xs',\n isNumericArrowType(column.field.type) && 'text-right',\n )}\n style={getColumnWidthStyle(column.field)}\n >\n <span className=\"block min-w-0 overflow-hidden text-ellipsis whitespace-nowrap\">\n <ArrowCellValue\n fieldName={column.name}\n fontSizeClass=\"text-xs\"\n formatValue={formatDataTableExplorerValue}\n type={column.field.type}\n value={value}\n />\n </span>\n </TableCell>\n );\n })}\n </TableRow>\n );\n});\n\nfunction DataTableExplorerRowsImpl({\n className,\n explorer,\n}: DataTableExplorerRowsProps) {\n if (explorer.tableError) {\n return (\n <TableBody className={className}>\n <SizingRow columns={explorer.columns} />\n <EmptyStateRow\n columns={explorer.columns}\n message={explorer.tableError.message}\n tone=\"error\"\n />\n </TableBody>\n );\n }\n\n if (!explorer.pageTable || explorer.pageTable.numRows === 0) {\n return (\n <TableBody className={className}>\n <SizingRow columns={explorer.columns} />\n <EmptyStateRow columns={explorer.columns} message=\"No rows\" />\n </TableBody>\n );\n }\n\n const rows = Array.from(\n {length: explorer.pageTable.numRows},\n (_, index) => index,\n );\n const pageTable = explorer.pageTable;\n\n return (\n <TableBody className={className}>\n {rows.map((rowIndex) => (\n <DataRow\n key={rowIndex}\n columns={explorer.columns}\n pageIndex={explorer.pagination.pageIndex}\n pageSize={explorer.pagination.pageSize}\n pageTable={pageTable}\n rowIndex={rowIndex}\n />\n ))}\n </TableBody>\n );\n}\n\nfunction areRowColumnsEqual(\n left: UseDataTableExplorerReturn['columns'],\n right: UseDataTableExplorerReturn['columns'],\n) {\n if (left.length !== right.length) {\n return false;\n }\n\n return left.every((column, index) => {\n const other = right[index];\n return (\n column.name === other?.name &&\n column.kind === other.kind &&\n column.field === other.field\n );\n });\n}\n\nexport const DataTableExplorerRows = memo(\n DataTableExplorerRowsImpl,\n (previous, next) =>\n previous.className === next.className &&\n previous.explorer.pageTable === next.explorer.pageTable &&\n previous.explorer.tableError === next.explorer.tableError &&\n previous.explorer.pagination.pageIndex ===\n next.explorer.pagination.pageIndex &&\n previous.explorer.pagination.pageSize ===\n next.explorer.pagination.pageSize &&\n areRowColumnsEqual(previous.explorer.columns, next.explorer.columns),\n);\n"]}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { FC, ReactNode } from 'react';
|
|
2
|
+
import type { UseDataTableExplorerReturn } from './types';
|
|
3
|
+
export type DataTableExplorerStatusBarProps = {
|
|
4
|
+
className?: string;
|
|
5
|
+
explorer: Pick<UseDataTableExplorerReturn, 'filteredRowCount' | 'pagination' | 'setPagination' | 'sql' | 'totalRowCount'>;
|
|
6
|
+
renderActions?: (sql: string) => ReactNode;
|
|
7
|
+
};
|
|
8
|
+
export declare const DataTableExplorerStatusBar: FC<DataTableExplorerStatusBarProps>;
|
|
9
|
+
//# sourceMappingURL=DataTableExplorerStatusBar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DataTableExplorerStatusBar.d.ts","sourceRoot":"","sources":["../../src/data-table-explorer/DataTableExplorerStatusBar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,EAAE,EAAE,SAAS,EAAC,MAAM,OAAO,CAAC;AAGzC,OAAO,KAAK,EAAC,0BAA0B,EAAC,MAAM,SAAS,CAAC;AAExD,MAAM,MAAM,+BAA+B,GAAG;IAC5C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,IAAI,CACZ,0BAA0B,EACxB,kBAAkB,GAClB,YAAY,GACZ,eAAe,GACf,KAAK,GACL,eAAe,CAClB,CAAC;IACF,aAAa,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,SAAS,CAAC;CAC5C,CAAC;AAEF,eAAO,MAAM,0BAA0B,EAAE,EAAE,CACzC,+BAA+B,CAyEhC,CAAC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { Button, cn } from '@sqlrooms/ui';
|
|
3
|
+
import { ChevronLeftIcon, ChevronRightIcon } from 'lucide-react';
|
|
4
|
+
export const DataTableExplorerStatusBar = ({ className, explorer, renderActions }) => {
|
|
5
|
+
const actions = renderActions?.(explorer.sql);
|
|
6
|
+
const totalPages = explorer.filteredRowCount !== undefined
|
|
7
|
+
? Math.max(1, Math.ceil(explorer.filteredRowCount / explorer.pagination.pageSize))
|
|
8
|
+
: undefined;
|
|
9
|
+
const canGoPrevious = explorer.pagination.pageIndex > 0;
|
|
10
|
+
const canGoNext = totalPages !== undefined && explorer.pagination.pageIndex < totalPages - 1;
|
|
11
|
+
const showPaginationLabel = totalPages !== undefined;
|
|
12
|
+
return (_jsxs("div", { className: cn('flex items-center justify-between gap-3 border-t px-3 py-2 text-sm', className), children: [_jsxs("div", { className: "flex items-center gap-3", children: [_jsxs("div", { className: "flex items-center gap-1 whitespace-nowrap", children: [_jsx(Button, { variant: "ghost", size: "xs", className: "h-6 w-6 p-0", "aria-label": "Previous page", disabled: !canGoPrevious, onClick: () => {
|
|
13
|
+
explorer.setPagination((prev) => ({
|
|
14
|
+
...prev,
|
|
15
|
+
pageIndex: Math.max(0, prev.pageIndex - 1),
|
|
16
|
+
}));
|
|
17
|
+
}, children: _jsx(ChevronLeftIcon, { size: 14 }) }), showPaginationLabel ? (_jsxs("span", { className: "text-muted-foreground min-w-14 text-center text-[11px]", children: [explorer.pagination.pageIndex + 1, " / ", totalPages] })) : null, _jsx(Button, { variant: "ghost", size: "xs", className: "h-6 w-6 p-0", "aria-label": "Next page", disabled: !canGoNext, onClick: () => {
|
|
18
|
+
explorer.setPagination((prev) => ({
|
|
19
|
+
...prev,
|
|
20
|
+
pageIndex: totalPages === undefined
|
|
21
|
+
? prev.pageIndex
|
|
22
|
+
: Math.min(totalPages - 1, prev.pageIndex + 1),
|
|
23
|
+
}));
|
|
24
|
+
}, children: _jsx(ChevronRightIcon, { size: 14 }) })] }), _jsxs("span", { className: "text-muted-foreground text-xs", children: [explorer.filteredRowCount?.toLocaleString() ?? '0', explorer.totalRowCount !== undefined
|
|
25
|
+
? ` of ${explorer.totalRowCount.toLocaleString()} rows`
|
|
26
|
+
: ' rows'] })] }), actions ? _jsx("div", { children: actions }) : null] }));
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=DataTableExplorerStatusBar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DataTableExplorerStatusBar.js","sourceRoot":"","sources":["../../src/data-table-explorer/DataTableExplorerStatusBar.tsx"],"names":[],"mappings":";AACA,OAAO,EAAC,MAAM,EAAE,EAAE,EAAC,MAAM,cAAc,CAAC;AACxC,OAAO,EAAC,eAAe,EAAE,gBAAgB,EAAC,MAAM,cAAc,CAAC;AAgB/D,MAAM,CAAC,MAAM,0BAA0B,GAEnC,CAAC,EAAC,SAAS,EAAE,QAAQ,EAAE,aAAa,EAAC,EAAE,EAAE;IAC3C,MAAM,OAAO,GAAG,aAAa,EAAE,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC;IAC9C,MAAM,UAAU,GACd,QAAQ,CAAC,gBAAgB,KAAK,SAAS;QACrC,CAAC,CAAC,IAAI,CAAC,GAAG,CACN,CAAC,EACD,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,gBAAgB,GAAG,QAAQ,CAAC,UAAU,CAAC,QAAQ,CAAC,CACpE;QACH,CAAC,CAAC,SAAS,CAAC;IAChB,MAAM,aAAa,GAAG,QAAQ,CAAC,UAAU,CAAC,SAAS,GAAG,CAAC,CAAC;IACxD,MAAM,SAAS,GACb,UAAU,KAAK,SAAS,IAAI,QAAQ,CAAC,UAAU,CAAC,SAAS,GAAG,UAAU,GAAG,CAAC,CAAC;IAC7E,MAAM,mBAAmB,GAAG,UAAU,KAAK,SAAS,CAAC;IAErD,OAAO,CACL,eACE,SAAS,EAAE,EAAE,CACX,oEAAoE,EACpE,SAAS,CACV,aAED,eAAK,SAAS,EAA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EAAE,IAAI,GAAG,EAClD,QAAQ,CAAC,aAAa,KAAK,SAAS;gCACnC,CAAC,CAAC,OAAO,QAAQ,CAAC,aAAa,CAAC,cAAc,EAAE,OAAO;gCACvD,CAAC,CAAC,OAAO,IACN,IACH,EACL,OAAO,CAAC,CAAC,CAAC,wBAAM,OAAO,GAAO,CAAC,CAAC,CAAC,IAAI,IAClC,CACP,CAAC;AACJ,CAAC,CAAC","sourcesContent":["import type {FC, ReactNode} from 'react';\nimport {Button, cn} from '@sqlrooms/ui';\nimport {ChevronLeftIcon, ChevronRightIcon} from 'lucide-react';\nimport type {UseDataTableExplorerReturn} from './types';\n\nexport type DataTableExplorerStatusBarProps = {\n className?: string;\n explorer: Pick<\n UseDataTableExplorerReturn,\n | 'filteredRowCount'\n | 'pagination'\n | 'setPagination'\n | 'sql'\n | 'totalRowCount'\n >;\n renderActions?: (sql: string) => ReactNode;\n};\n\nexport const DataTableExplorerStatusBar: FC<\n DataTableExplorerStatusBarProps\n> = ({className, explorer, renderActions}) => {\n const actions = renderActions?.(explorer.sql);\n const totalPages =\n explorer.filteredRowCount !== undefined\n ? Math.max(\n 1,\n Math.ceil(explorer.filteredRowCount / explorer.pagination.pageSize),\n )\n : undefined;\n const canGoPrevious = explorer.pagination.pageIndex > 0;\n const canGoNext =\n totalPages !== undefined && explorer.pagination.pageIndex < totalPages - 1;\n const showPaginationLabel = totalPages !== undefined;\n\n return (\n <div\n className={cn(\n 'flex items-center justify-between gap-3 border-t px-3 py-2 text-sm',\n className,\n )}\n >\n <div className=\"flex items-center gap-3\">\n <div className=\"flex items-center gap-1 whitespace-nowrap\">\n <Button\n variant=\"ghost\"\n size=\"xs\"\n className=\"h-6 w-6 p-0\"\n aria-label=\"Previous page\"\n disabled={!canGoPrevious}\n onClick={() => {\n explorer.setPagination((prev) => ({\n ...prev,\n pageIndex: Math.max(0, prev.pageIndex - 1),\n }));\n }}\n >\n <ChevronLeftIcon size={14} />\n </Button>\n {showPaginationLabel ? (\n <span className=\"text-muted-foreground min-w-14 text-center text-[11px]\">\n {explorer.pagination.pageIndex + 1} / {totalPages}\n </span>\n ) : null}\n <Button\n variant=\"ghost\"\n size=\"xs\"\n className=\"h-6 w-6 p-0\"\n aria-label=\"Next page\"\n disabled={!canGoNext}\n onClick={() => {\n explorer.setPagination((prev) => ({\n ...prev,\n pageIndex:\n totalPages === undefined\n ? prev.pageIndex\n : Math.min(totalPages - 1, prev.pageIndex + 1),\n }));\n }}\n >\n <ChevronRightIcon size={14} />\n </Button>\n </div>\n <span className=\"text-muted-foreground text-xs\">\n {explorer.filteredRowCount?.toLocaleString() ?? '0'}\n {explorer.totalRowCount !== undefined\n ? ` of ${explorer.totalRowCount.toLocaleString()} rows`\n : ' rows'}\n </span>\n </div>\n {actions ? <div>{actions}</div> : null}\n </div>\n );\n};\n"]}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { MosaicClient, type Selection } from '@uwdata/mosaic-core';
|
|
2
|
+
import { type ExprNode, type Query } from '@uwdata/mosaic-sql';
|
|
3
|
+
import type * as arrow from 'apache-arrow';
|
|
4
|
+
import type { DataTableExplorerUnsupportedSummary } from './types';
|
|
5
|
+
type UnsupportedSummaryClientOptions = {
|
|
6
|
+
field: arrow.Field;
|
|
7
|
+
onStateChange: (summary: DataTableExplorerUnsupportedSummary) => void;
|
|
8
|
+
selection: Selection;
|
|
9
|
+
tableName: string;
|
|
10
|
+
};
|
|
11
|
+
export declare class DataTableExplorerUnsupportedSummaryClient extends MosaicClient {
|
|
12
|
+
private count;
|
|
13
|
+
private readonly field;
|
|
14
|
+
private readonly onStateChange;
|
|
15
|
+
private readonly tableName;
|
|
16
|
+
constructor(options: UnsupportedSummaryClientOptions);
|
|
17
|
+
get filterStable(): boolean;
|
|
18
|
+
queryPending(): this;
|
|
19
|
+
query(filter?: Array<ExprNode>): Query;
|
|
20
|
+
queryResult(data: unknown): this;
|
|
21
|
+
queryError(error: Error): this;
|
|
22
|
+
}
|
|
23
|
+
export {};
|
|
24
|
+
//# sourceMappingURL=DataTableExplorerUnsupportedSummaryClient.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DataTableExplorerUnsupportedSummaryClient.d.ts","sourceRoot":"","sources":["../../src/data-table-explorer/DataTableExplorerUnsupportedSummaryClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,YAAY,EAAE,KAAK,SAAS,EAAC,MAAM,qBAAqB,CAAC;AACjE,OAAO,EAAC,KAAK,QAAQ,EAAE,KAAK,KAAK,EAAC,MAAM,oBAAoB,CAAC;AAC7D,OAAO,KAAK,KAAK,KAAK,MAAM,cAAc,CAAC;AAC3C,OAAO,KAAK,EAAC,mCAAmC,EAAC,MAAM,SAAS,CAAC;AAGjE,KAAK,+BAA+B,GAAG;IACrC,KAAK,EAAE,KAAK,CAAC,KAAK,CAAC;IACnB,aAAa,EAAE,CAAC,OAAO,EAAE,mCAAmC,KAAK,IAAI,CAAC;IACtE,SAAS,EAAE,SAAS,CAAC;IACrB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,qBAAa,yCAA0C,SAAQ,YAAY;IACzE,OAAO,CAAC,KAAK,CAAK;IAClB,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAc;IACpC,OAAO,CAAC,QAAQ,CAAC,aAAa,CAEpB;IACV,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAS;gBAEvB,OAAO,EAAE,+BAA+B;IAOpD,IAAa,YAAY,IAAI,OAAO,CAEnC;IAEQ,YAAY,IAAI,IAAI;IASpB,KAAK,CAAC,MAAM,GAAE,KAAK,CAAC,QAAQ,CAAM,GAAG,KAAK;IAQ1C,WAAW,CAAC,IAAI,EAAE,OAAO,GAAG,IAAI;IAUhC,UAAU,CAAC,KAAK,EAAE,KAAK,GAAG,IAAI;CASxC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { MosaicClient } from '@uwdata/mosaic-core';
|
|
2
|
+
import { buildDistinctCountQuery, readCountData } from './utils';
|
|
3
|
+
export class DataTableExplorerUnsupportedSummaryClient extends MosaicClient {
|
|
4
|
+
count = 0;
|
|
5
|
+
field;
|
|
6
|
+
onStateChange;
|
|
7
|
+
tableName;
|
|
8
|
+
constructor(options) {
|
|
9
|
+
super(options.selection);
|
|
10
|
+
this.field = options.field;
|
|
11
|
+
this.onStateChange = options.onStateChange;
|
|
12
|
+
this.tableName = options.tableName;
|
|
13
|
+
}
|
|
14
|
+
get filterStable() {
|
|
15
|
+
return false;
|
|
16
|
+
}
|
|
17
|
+
queryPending() {
|
|
18
|
+
this.onStateChange({
|
|
19
|
+
isLoading: true,
|
|
20
|
+
kind: 'unsupported',
|
|
21
|
+
label: `${this.count.toLocaleString()} distinct values`,
|
|
22
|
+
});
|
|
23
|
+
return this;
|
|
24
|
+
}
|
|
25
|
+
query(filter = []) {
|
|
26
|
+
return buildDistinctCountQuery({
|
|
27
|
+
fieldName: this.field.name,
|
|
28
|
+
filter,
|
|
29
|
+
tableName: this.tableName,
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
queryResult(data) {
|
|
33
|
+
this.count = readCountData(data) ?? 0;
|
|
34
|
+
this.onStateChange({
|
|
35
|
+
isLoading: false,
|
|
36
|
+
kind: 'unsupported',
|
|
37
|
+
label: `${this.count.toLocaleString()} distinct values`,
|
|
38
|
+
});
|
|
39
|
+
return this;
|
|
40
|
+
}
|
|
41
|
+
queryError(error) {
|
|
42
|
+
this.onStateChange({
|
|
43
|
+
error,
|
|
44
|
+
isLoading: false,
|
|
45
|
+
kind: 'unsupported',
|
|
46
|
+
label: `${this.count.toLocaleString()} distinct values`,
|
|
47
|
+
});
|
|
48
|
+
return this;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=DataTableExplorerUnsupportedSummaryClient.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"DataTableExplorerUnsupportedSummaryClient.js","sourceRoot":"","sources":["../../src/data-table-explorer/Data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AAC;QACH,OAAO,IAAI,CAAC;IACd,CAAC;IAEQ,UAAU,CAAC,KAAY;QAC9B,IAAI,CAAC,aAAa,CAAC;YACjB,KAAK;YACL,SAAS,EAAE,KAAK;YAChB,IAAI,EAAE,aAAa;YACnB,KAAK,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,cAAc,EAAE,kBAAkB;SACxD,CAAC,CAAC;QACH,OAAO,IAAI,CAAC;IACd,CAAC;CACF","sourcesContent":["import {MosaicClient, type Selection} from '@uwdata/mosaic-core';\nimport {type ExprNode, type Query} from '@uwdata/mosaic-sql';\nimport type * as arrow from 'apache-arrow';\nimport type {DataTableExplorerUnsupportedSummary} from './types';\nimport {buildDistinctCountQuery, readCountData} from './utils';\n\ntype UnsupportedSummaryClientOptions = {\n field: arrow.Field;\n onStateChange: (summary: DataTableExplorerUnsupportedSummary) => void;\n selection: Selection;\n tableName: string;\n};\n\nexport class DataTableExplorerUnsupportedSummaryClient extends MosaicClient {\n private count = 0;\n private readonly field: arrow.Field;\n private readonly onStateChange: (\n summary: DataTableExplorerUnsupportedSummary,\n ) => void;\n private readonly tableName: string;\n\n constructor(options: UnsupportedSummaryClientOptions) {\n super(options.selection);\n this.field = options.field;\n this.onStateChange = options.onStateChange;\n this.tableName = options.tableName;\n }\n\n override get filterStable(): boolean {\n return false;\n }\n\n override queryPending(): this {\n this.onStateChange({\n isLoading: true,\n kind: 'unsupported',\n label: `${this.count.toLocaleString()} distinct values`,\n });\n return this;\n }\n\n override query(filter: Array<ExprNode> = []): Query {\n return buildDistinctCountQuery({\n fieldName: this.field.name,\n filter,\n tableName: this.tableName,\n });\n }\n\n override queryResult(data: unknown): this {\n this.count = readCountData(data) ?? 0;\n this.onStateChange({\n isLoading: false,\n kind: 'unsupported',\n label: `${this.count.toLocaleString()} distinct values`,\n });\n return this;\n }\n\n override queryError(error: Error): this {\n this.onStateChange({\n error,\n isLoading: false,\n kind: 'unsupported',\n label: `${this.count.toLocaleString()} distinct values`,\n });\n return this;\n }\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"addDataTableExplorerPanelAction.d.ts","sourceRoot":"","sources":["../../src/data-table-explorer/addDataTableExplorerPanelAction.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,KAAK,6BAA6B,EAAC,MAAM,2BAA2B,CAAC;AAM7E,eAAO,MAAM,+BAA+B,EAAE,6BAK7C,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { TableProperties } from 'lucide-react';
|
|
2
|
+
import { createMosaicDashboardDataTableExplorerPanelConfig, MOSAIC_DASHBOARD_DATA_TABLE_EXPLORER_PANEL_TYPE, } from '../dashboard/MosaicDashboardSlice';
|
|
3
|
+
export const addDataTableExplorerPanelAction = {
|
|
4
|
+
type: MOSAIC_DASHBOARD_DATA_TABLE_EXPLORER_PANEL_TYPE,
|
|
5
|
+
label: 'Data Table',
|
|
6
|
+
icon: TableProperties,
|
|
7
|
+
createPanel: () => createMosaicDashboardDataTableExplorerPanelConfig(),
|
|
8
|
+
};
|
|
9
|
+
//# sourceMappingURL=addDataTableExplorerPanelAction.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"addDataTableExplorerPanelAction.js","sourceRoot":"","sources":["../../src/data-table-explorer/addDataTableExplorerPanelAction.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,eAAe,EAAC,MAAM,cAAc,CAAC;AAE7C,OAAO,EACL,iDAAiD,EACjD,+CAA+C,GAChD,MAAM,mCAAmC,CAAC;AAE3C,MAAM,CAAC,MAAM,+BAA+B,GAAkC;IAC5E,IAAI,EAAE,+CAA+C;IACrD,KAAK,EAAE,YAAY;IACnB,IAAI,EAAE,eAAe;IACrB,WAAW,EAAE,GAAG,EAAE,CAAC,iDAAiD,EAAE;CACvE,CAAC","sourcesContent":["import {TableProperties} from 'lucide-react';\nimport {type MosaicDashboardAddPanelAction} from '../dashboard/action-types';\nimport {\n createMosaicDashboardDataTableExplorerPanelConfig,\n MOSAIC_DASHBOARD_DATA_TABLE_EXPLORER_PANEL_TYPE,\n} from '../dashboard/MosaicDashboardSlice';\n\nexport const addDataTableExplorerPanelAction: MosaicDashboardAddPanelAction = {\n type: MOSAIC_DASHBOARD_DATA_TABLE_EXPLORER_PANEL_TYPE,\n label: 'Data Table',\n icon: TableProperties,\n createPanel: () => createMosaicDashboardDataTableExplorerPanelConfig(),\n};\n"]}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import type * as arrow from 'apache-arrow';
|
|
2
|
+
import type { Dispatch, SetStateAction } from 'react';
|
|
3
|
+
import type { DataTableExplorerCountState } from './DataTableExplorerCountClient';
|
|
4
|
+
import type { DataTableExplorerPageState } from './DataTableExplorerPageClient';
|
|
5
|
+
import type { DataTableExplorerPaginationState, DataTableExplorerSorting, DataTableExplorerSummaryState } from './types';
|
|
6
|
+
export type DataTableExplorerStoreState = {
|
|
7
|
+
filteredCount: DataTableExplorerCountState;
|
|
8
|
+
lastNonEmptyPageTable?: {
|
|
9
|
+
datasetId: string;
|
|
10
|
+
pageTable: arrow.Table;
|
|
11
|
+
};
|
|
12
|
+
page: DataTableExplorerPageState;
|
|
13
|
+
pagination: DataTableExplorerPaginationState;
|
|
14
|
+
schema: {
|
|
15
|
+
error?: Error;
|
|
16
|
+
fields: arrow.Field[];
|
|
17
|
+
isLoading: boolean;
|
|
18
|
+
tableName?: string;
|
|
19
|
+
};
|
|
20
|
+
setFilteredCount: (state: DataTableExplorerCountState) => void;
|
|
21
|
+
setPage: (state: DataTableExplorerPageState) => void;
|
|
22
|
+
setPagination: Dispatch<SetStateAction<DataTableExplorerPaginationState>>;
|
|
23
|
+
setSchemaError: (error?: Error, tableName?: string) => void;
|
|
24
|
+
setSchemaLoading: (isLoading: boolean, tableName?: string) => void;
|
|
25
|
+
setSchemaSuccess: (fields: arrow.Field[], tableName?: string) => void;
|
|
26
|
+
setSorting: Dispatch<SetStateAction<DataTableExplorerSorting>>;
|
|
27
|
+
setSummary: (fieldName: string, summary: DataTableExplorerSummaryState) => void;
|
|
28
|
+
setTotalCount: (state: DataTableExplorerCountState) => void;
|
|
29
|
+
sorting: DataTableExplorerSorting;
|
|
30
|
+
summaries: Record<string, DataTableExplorerSummaryState>;
|
|
31
|
+
syncPageSize: (pageSize: number) => void;
|
|
32
|
+
totalCount: DataTableExplorerCountState;
|
|
33
|
+
clearSummaries: () => void;
|
|
34
|
+
initializeSummaries: (fields: arrow.Field[]) => void;
|
|
35
|
+
resetPageIndex: () => void;
|
|
36
|
+
};
|
|
37
|
+
export type DataTableExplorerStore = ReturnType<typeof createDataTableExplorerStore>;
|
|
38
|
+
/**
|
|
39
|
+
* Creates a dataTableExplorer-local vanilla Zustand store that aggregates schema, row,
|
|
40
|
+
* count, and summary state for a single `useDataTableExplorer()` instance.
|
|
41
|
+
*/
|
|
42
|
+
export declare function createDataTableExplorerStore(options: {
|
|
43
|
+
initialSorting?: DataTableExplorerSorting;
|
|
44
|
+
pageSize: number;
|
|
45
|
+
}): import("zustand").StoreApi<DataTableExplorerStoreState>;
|
|
46
|
+
//# sourceMappingURL=createDataTableExplorerStore.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createDataTableExplorerStore.d.ts","sourceRoot":"","sources":["../../src/data-table-explorer/createDataTableExplorerStore.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,KAAK,KAAK,MAAM,cAAc,CAAC;AAC3C,OAAO,KAAK,EAAC,QAAQ,EAAE,cAAc,EAAC,MAAM,OAAO,CAAC;AAEpD,OAAO,KAAK,EAAC,2BAA2B,EAAC,MAAM,gCAAgC,CAAC;AAChF,OAAO,KAAK,EAAC,0BAA0B,EAAC,MAAM,+BAA+B,CAAC;AAC9E,OAAO,KAAK,EACV,gCAAgC,EAChC,wBAAwB,EACxB,6BAA6B,EAC9B,MAAM,SAAS,CAAC;AAcjB,MAAM,MAAM,2BAA2B,GAAG;IACxC,aAAa,EAAE,2BAA2B,CAAC;IAC3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AAU,EAAE,2BAA2B,CAAC;IACxC,cAAc,EAAE,MAAM,IAAI,CAAC;IAC3B,mBAAmB,EAAE,CAAC,MAAM,EAAE,KAAK,CAAC,KAAK,EAAE,KAAK,IAAI,CAAC;IACrD,cAAc,EAAE,MAAM,IAAI,CAAC;CAC5B,CAAC;AAEF,MAAM,MAAM,sBAAsB,GAAG,UAAU,CAC7C,OAAO,4BAA4B,CACpC,CAAC;AAEF;;;GAGG;AACH,wBAAgB,4BAA4B,CAAC,OAAO,EAAE;IACpD,cAAc,CAAC,EAAE,wBAAwB,CAAC;IAC1C,QAAQ,EAAE,MAAM,CAAC;CAClB,2DA+IA"}
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
import { castDraft, produce } from 'immer';
|
|
2
|
+
import { createStore } from 'zustand/vanilla';
|
|
3
|
+
import { createEmptySummaryState, normalizeDataTableExplorerPagination, } from './utils';
|
|
4
|
+
function resolveSetStateAction(next, previous) {
|
|
5
|
+
// Preserve React-style setter semantics so hook callers can pass either
|
|
6
|
+
// a concrete value or an updater function to the local dataTableExplorer store.
|
|
7
|
+
return typeof next === 'function'
|
|
8
|
+
? next(previous)
|
|
9
|
+
: next;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Creates a dataTableExplorer-local vanilla Zustand store that aggregates schema, row,
|
|
13
|
+
* count, and summary state for a single `useDataTableExplorer()` instance.
|
|
14
|
+
*/
|
|
15
|
+
export function createDataTableExplorerStore(options) {
|
|
16
|
+
const { initialSorting = [], pageSize } = options;
|
|
17
|
+
return createStore((set) => ({
|
|
18
|
+
filteredCount: { isLoading: false },
|
|
19
|
+
lastNonEmptyPageTable: undefined,
|
|
20
|
+
page: { isLoading: false },
|
|
21
|
+
pagination: normalizeDataTableExplorerPagination({ pageIndex: 0, pageSize }),
|
|
22
|
+
schema: {
|
|
23
|
+
fields: [],
|
|
24
|
+
isLoading: false,
|
|
25
|
+
},
|
|
26
|
+
setFilteredCount: (nextState) => {
|
|
27
|
+
set((state) => produce(state, (draft) => {
|
|
28
|
+
draft.filteredCount = nextState;
|
|
29
|
+
}));
|
|
30
|
+
},
|
|
31
|
+
setPage: (nextState) => {
|
|
32
|
+
set((state) => produce(state, (draft) => {
|
|
33
|
+
draft.page = castDraft(nextState);
|
|
34
|
+
if (nextState.datasetId &&
|
|
35
|
+
nextState.pageTable &&
|
|
36
|
+
nextState.pageTable.numRows > 0) {
|
|
37
|
+
draft.lastNonEmptyPageTable = {
|
|
38
|
+
datasetId: nextState.datasetId,
|
|
39
|
+
pageTable: castDraft(nextState.pageTable),
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
}));
|
|
43
|
+
},
|
|
44
|
+
setPagination: (next) => {
|
|
45
|
+
set((state) => produce(state, (draft) => {
|
|
46
|
+
draft.pagination = normalizeDataTableExplorerPagination(resolveSetStateAction(next, state.pagination));
|
|
47
|
+
}));
|
|
48
|
+
},
|
|
49
|
+
setSchemaError: (error, tableName) => {
|
|
50
|
+
set((state) => produce(state, (draft) => {
|
|
51
|
+
draft.schema.error = error;
|
|
52
|
+
draft.schema.isLoading = false;
|
|
53
|
+
draft.schema.tableName = tableName;
|
|
54
|
+
}));
|
|
55
|
+
},
|
|
56
|
+
setSchemaLoading: (isLoading, tableName) => {
|
|
57
|
+
set((state) => produce(state, (draft) => {
|
|
58
|
+
if (tableName !== undefined && draft.schema.tableName !== tableName) {
|
|
59
|
+
draft.schema.fields = [];
|
|
60
|
+
}
|
|
61
|
+
draft.schema.isLoading = isLoading;
|
|
62
|
+
draft.schema.tableName = tableName;
|
|
63
|
+
if (isLoading) {
|
|
64
|
+
draft.schema.error = undefined;
|
|
65
|
+
}
|
|
66
|
+
}));
|
|
67
|
+
},
|
|
68
|
+
setSchemaSuccess: (fields, tableName) => {
|
|
69
|
+
set((state) => produce(state, (draft) => {
|
|
70
|
+
draft.schema.error = undefined;
|
|
71
|
+
draft.schema.fields = fields;
|
|
72
|
+
draft.schema.isLoading = false;
|
|
73
|
+
draft.schema.tableName = tableName;
|
|
74
|
+
}));
|
|
75
|
+
},
|
|
76
|
+
setSorting: (next) => {
|
|
77
|
+
set((state) => produce(state, (draft) => {
|
|
78
|
+
draft.sorting = resolveSetStateAction(next, state.sorting);
|
|
79
|
+
draft.pagination.pageIndex = 0;
|
|
80
|
+
}));
|
|
81
|
+
},
|
|
82
|
+
setSummary: (fieldName, summary) => {
|
|
83
|
+
set((state) => produce(state, (draft) => {
|
|
84
|
+
draft.summaries[fieldName] = summary;
|
|
85
|
+
}));
|
|
86
|
+
},
|
|
87
|
+
setTotalCount: (nextState) => {
|
|
88
|
+
set((state) => produce(state, (draft) => {
|
|
89
|
+
draft.totalCount = nextState;
|
|
90
|
+
}));
|
|
91
|
+
},
|
|
92
|
+
sorting: initialSorting,
|
|
93
|
+
summaries: {},
|
|
94
|
+
syncPageSize: (nextPageSize) => {
|
|
95
|
+
set((state) => produce(state, (draft) => {
|
|
96
|
+
if (draft.pagination.pageSize === nextPageSize) {
|
|
97
|
+
return;
|
|
98
|
+
}
|
|
99
|
+
draft.pagination = normalizeDataTableExplorerPagination({
|
|
100
|
+
pageIndex: 0,
|
|
101
|
+
pageSize: nextPageSize,
|
|
102
|
+
});
|
|
103
|
+
}));
|
|
104
|
+
},
|
|
105
|
+
totalCount: { isLoading: false },
|
|
106
|
+
clearSummaries: () => {
|
|
107
|
+
set((state) => produce(state, (draft) => {
|
|
108
|
+
draft.summaries = {};
|
|
109
|
+
}));
|
|
110
|
+
},
|
|
111
|
+
initializeSummaries: (fields) => {
|
|
112
|
+
set((state) => produce(state, (draft) => {
|
|
113
|
+
draft.summaries = Object.fromEntries(fields.map((field) => [field.name, createEmptySummaryState(field)]));
|
|
114
|
+
}));
|
|
115
|
+
},
|
|
116
|
+
resetPageIndex: () => {
|
|
117
|
+
set((state) => produce(state, (draft) => {
|
|
118
|
+
draft.pagination = normalizeDataTableExplorerPagination({
|
|
119
|
+
...draft.pagination,
|
|
120
|
+
pageIndex: 0,
|
|
121
|
+
});
|
|
122
|
+
}));
|
|
123
|
+
},
|
|
124
|
+
}));
|
|
125
|
+
}
|
|
126
|
+
//# sourceMappingURL=createDataTableExplorerStore.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createDataTableExplorerStore.js","sourceRoot":"","sources":["../../src/data-table-explorer/createDataTableExplorerStore.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,OAAO,EAAC,MAAM,OAAO,CAAC;AAGzC,OAAO,EAAC,WAAW,EAAC,MAAM,iBAAiB,CAAC;AAQ5C,OAAO,EACL,uBAAuB,EACvB,oCAAoC,GACrC,MAAM,SAAS,CAAC;AAEjB,SAAS,qBAAqB,CAAI,IAAuB,EAAE,QAAW;IACpE,wEAAwE;IACxE,gFAAgF;IAChF,OAAO,OAAO,IAAI,KAAK,UAAU;QAC/B,CAAC,CAAE,IAAwB,CAAC,QAAQ,CAAC;QACrC,CAAC,CAAC,IAAI,CAAC;AACX,CAAC;AAyCD;;;GAGG;AACH,MAAM,UAAU,4BAA4B,CAAC,OAG5C;IACC,MAAM,EAAC,cAAc,GAAG,EAAE,EAAE,QAAQ,EAAC,GAAG,OAAO,CAAC;IAEhD,OAAO,WAAW,CAA8B,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC;QACxD,aAAa,EAAE,EAAC,SAAS,EAAE,KAAK,EAAC;QACjC,qBAAqB,EAAE,SAAS;QAChC,IAAI,EAAE,EAAC,SAAS,EAAE,KAAK,EAAC;QACxB,UAAU,EAAE,oCAAoC,CAAC,EAAC,SAAS,EAAE,CAAC,EAAE,QAAQ,EAAC,CAAC;QAC1E,MAAM,EAAE;YACN,MAAM,EAAE,EAAE;YACV,SAAS,EAAE,KAAK;SACjB;QACD,gBAAgB,EAAE,CAAC,SAAS,EAAE,EAAE;YAC9B,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CACZ,OAAO,CAAC,KAAK,EAAE,CAAC,KAAK,EAAE,EAAE;gBACvB,KAAK,CAAC,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,mBAAmB,EAAE,CAAC,MAAM,EAAE,EAAE;YAC9B,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CACZ,OAAO,CAAC,KAAK,EAAE,CAAC,KAAK,EAAE,EAAE;gBACvB,KAAK,CAAC,SAAS,GAAG,MAAM,CAAC,WAAW,CAClC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,KAAK,CAAC,IAAI,EAAE,uBAAuB,CAAC,KAAK,CAAC,CAAC,CAAC,CACpE,CAAC;YACJ,CAAC,CAAC,CACH,CAAC;QACJ,CAAC;QACD,cAAc,EAAE,GAAG,EAAE;YACnB,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CACZ,OAAO,CAAC,KAAK,EAAE,CAAC,KAAK,EAAE,EAAE;gBACvB,KAAK,CAAC,UAAU,GAAG,oCAAoC,CAAC;oBACtD,GAAG,KAAK,CAAC,UAAU;oBACnB,SAAS,EAAE,CAAC;iBACb,CAAC,CAAC;YACL,CAAC,CAAC,CACH,CAAC;QACJ,CAAC;KACF,CAAC,CAAC,CAAC;AACN,CAAC","sourcesContent":["import {castDraft, produce} from 'immer';\nimport type * as arrow from 'apache-arrow';\nimport type {Dispatch, SetStateAction} from 'react';\nimport {createStore} from 'zustand/vanilla';\nimport type {DataTableExplorerCountState} from './DataTableExplorerCountClient';\nimport type {DataTableExplorerPageState} from './DataTableExplorerPageClient';\nimport type {\n DataTableExplorerPaginationState,\n DataTableExplorerSorting,\n DataTableExplorerSummaryState,\n} from './types';\nimport {\n createEmptySummaryState,\n normalizeDataTableExplorerPagination,\n} from './utils';\n\nfunction resolveSetStateAction<T>(next: SetStateAction<T>, previous: T): T {\n // Preserve React-style setter semantics so hook callers can pass either\n // a concrete value or an updater function to the local dataTableExplorer store.\n return typeof next === 'function'\n ? (next as (value: T) => T)(previous)\n : next;\n}\n\nexport type DataTableExplorerStoreState = {\n filteredCount: DataTableExplorerCountState;\n lastNonEmptyPageTable?: {\n datasetId: string;\n pageTable: arrow.Table;\n };\n page: DataTableExplorerPageState;\n pagination: DataTableExplorerPaginationState;\n schema: {\n error?: Error;\n fields: arrow.Field[];\n isLoading: boolean;\n tableName?: string;\n };\n setFilteredCount: (state: DataTableExplorerCountState) => void;\n setPage: (state: DataTableExplorerPageState) => void;\n setPagination: Dispatch<SetStateAction<DataTableExplorerPaginationState>>;\n setSchemaError: (error?: Error, tableName?: string) => void;\n setSchemaLoading: (isLoading: boolean, tableName?: string) => void;\n setSchemaSuccess: (fields: arrow.Field[], tableName?: string) => void;\n setSorting: Dispatch<SetStateAction<DataTableExplorerSorting>>;\n setSummary: (\n fieldName: string,\n summary: DataTableExplorerSummaryState,\n ) => void;\n setTotalCount: (state: DataTableExplorerCountState) => void;\n sorting: DataTableExplorerSorting;\n summaries: Record<string, DataTableExplorerSummaryState>;\n syncPageSize: (pageSize: number) => void;\n totalCount: DataTableExplorerCountState;\n clearSummaries: () => void;\n initializeSummaries: (fields: arrow.Field[]) => void;\n resetPageIndex: () => void;\n};\n\nexport type DataTableExplorerStore = ReturnType<\n typeof createDataTableExplorerStore\n>;\n\n/**\n * Creates a dataTableExplorer-local vanilla Zustand store that aggregates schema, row,\n * count, and summary state for a single `useDataTableExplorer()` instance.\n */\nexport function createDataTableExplorerStore(options: {\n initialSorting?: DataTableExplorerSorting;\n pageSize: number;\n}) {\n const {initialSorting = [], pageSize} = options;\n\n return createStore<DataTableExplorerStoreState>((set) => ({\n filteredCount: {isLoading: false},\n lastNonEmptyPageTable: undefined,\n page: {isLoading: false},\n pagination: normalizeDataTableExplorerPagination({pageIndex: 0, pageSize}),\n schema: {\n fields: [],\n isLoading: false,\n },\n setFilteredCount: (nextState) => {\n set((state) =>\n produce(state, (draft) => {\n draft.filteredCount = nextState;\n }),\n );\n },\n setPage: (nextState) => {\n set((state) =>\n produce(state, (draft) => {\n draft.page = castDraft(nextState);\n if (\n nextState.datasetId &&\n nextState.pageTable &&\n nextState.pageTable.numRows > 0\n ) {\n draft.lastNonEmptyPageTable = {\n datasetId: nextState.datasetId,\n pageTable: castDraft(nextState.pageTable),\n };\n }\n }),\n );\n },\n setPagination: (next) => {\n set((state) =>\n produce(state, (draft) => {\n draft.pagination = normalizeDataTableExplorerPagination(\n resolveSetStateAction(next, state.pagination),\n );\n }),\n );\n },\n setSchemaError: (error, tableName) => {\n set((state) =>\n produce(state, (draft) => {\n draft.schema.error = error;\n draft.schema.isLoading = false;\n draft.schema.tableName = tableName;\n }),\n );\n },\n setSchemaLoading: (isLoading, tableName) => {\n set((state) =>\n produce(state, (draft) => {\n if (tableName !== undefined && draft.schema.tableName !== tableName) {\n draft.schema.fields = [];\n }\n draft.schema.isLoading = isLoading;\n draft.schema.tableName = tableName;\n if (isLoading) {\n draft.schema.error = undefined;\n }\n }),\n );\n },\n setSchemaSuccess: (fields, tableName) => {\n set((state) =>\n produce(state, (draft) => {\n draft.schema.error = undefined;\n draft.schema.fields = fields;\n draft.schema.isLoading = false;\n draft.schema.tableName = tableName;\n }),\n );\n },\n setSorting: (next) => {\n set((state) =>\n produce(state, (draft) => {\n draft.sorting = resolveSetStateAction(next, state.sorting);\n draft.pagination.pageIndex = 0;\n }),\n );\n },\n setSummary: (fieldName, summary) => {\n set((state) =>\n produce(state, (draft) => {\n draft.summaries[fieldName] = summary;\n }),\n );\n },\n setTotalCount: (nextState) => {\n set((state) =>\n produce(state, (draft) => {\n draft.totalCount = nextState;\n }),\n );\n },\n sorting: initialSorting,\n summaries: {},\n syncPageSize: (nextPageSize) => {\n set((state) =>\n produce(state, (draft) => {\n if (draft.pagination.pageSize === nextPageSize) {\n return;\n }\n draft.pagination = normalizeDataTableExplorerPagination({\n pageIndex: 0,\n pageSize: nextPageSize,\n });\n }),\n );\n },\n totalCount: {isLoading: false},\n clearSummaries: () => {\n set((state) =>\n produce(state, (draft) => {\n draft.summaries = {};\n }),\n );\n },\n initializeSummaries: (fields) => {\n set((state) =>\n produce(state, (draft) => {\n draft.summaries = Object.fromEntries(\n fields.map((field) => [field.name, createEmptySummaryState(field)]),\n );\n }),\n );\n },\n resetPageIndex: () => {\n set((state) =>\n produce(state, (draft) => {\n draft.pagination = normalizeDataTableExplorerPagination({\n ...draft.pagination,\n pageIndex: 0,\n });\n }),\n );\n },\n }));\n}\n"]}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { DataTableExplorerPanel } from '../../dashboard/dashboard-types';
|
|
2
|
+
import { type MosaicDashboardPanelRenderer } from '../../dashboard/MosaicDashboardSlice';
|
|
3
|
+
export declare const mosaicDashboardDataTableExplorerPanelRenderer: MosaicDashboardPanelRenderer<DataTableExplorerPanel>;
|
|
4
|
+
//# sourceMappingURL=MosaicDashboardDataTableExplorerPanelRenderer.d.ts.map
|
package/dist/data-table-explorer/dashboard/MosaicDashboardDataTableExplorerPanelRenderer.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MosaicDashboardDataTableExplorerPanelRenderer.d.ts","sourceRoot":"","sources":["../../../src/data-table-explorer/dashboard/MosaicDashboardDataTableExplorerPanelRenderer.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAC,sBAAsB,EAAC,MAAM,iCAAiC,CAAC;AAC5E,OAAO,EACL,KAAK,4BAA4B,EAGlC,MAAM,sCAAsC,CAAC;AAyD9C,eAAO,MAAM,6CAA6C,EAAE,4BAA4B,CAAC,sBAAsB,CAI5G,CAAC"}
|