drizzle-cube 0.8.0 → 0.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/adapters/ActivityGridChart.config-DXUUgx0N.cjs +1 -0
- package/dist/adapters/ActivityGridChart.config-Dyozu3VW.js +2 -0
- package/dist/adapters/AreaChart.config-Di5odBXp.cjs +1 -0
- package/dist/adapters/AreaChart.config-KEaXP_4K.js +2 -0
- package/dist/adapters/BarChart.config-B-hBHykR.cjs +1 -0
- package/dist/adapters/BarChart.config-C5sqbn0A.js +2 -0
- package/dist/adapters/BoxPlotChart.config-B1R4Br7L.js +2 -0
- package/dist/adapters/BoxPlotChart.config-C82Fhd3c.cjs +1 -0
- package/dist/adapters/BubbleChart.config-CoBxmmfp.js +2 -0
- package/dist/adapters/BubbleChart.config-DfOnNjL-.cjs +1 -0
- package/dist/adapters/CandlestickChart.config-C5ggV_3j.cjs +1 -0
- package/dist/adapters/CandlestickChart.config-ZaJpWVuL.js +2 -0
- package/dist/adapters/DataTable.config-Cx2_ACdY.cjs +1 -0
- package/dist/adapters/DataTable.config-DkAgD-iz.js +2 -0
- package/dist/adapters/FunnelChart.config-CvzcECUB.js +2 -0
- package/dist/adapters/FunnelChart.config-DVH7IFnb.cjs +1 -0
- package/dist/adapters/GaugeChart.config-Csx8rt8o.cjs +1 -0
- package/dist/adapters/GaugeChart.config-DEmrNgMa.js +2 -0
- package/dist/adapters/HeatMapChart.config-BfD_dpP7.js +2 -0
- package/dist/adapters/HeatMapChart.config-D_jlyPJL.cjs +1 -0
- package/dist/adapters/KpiDelta.config-CVBdUL_n.cjs +1 -0
- package/dist/adapters/KpiDelta.config-D4dCXOxl.js +2 -0
- package/dist/adapters/KpiNumber.config-BK5pgIKz.cjs +1 -0
- package/dist/adapters/KpiNumber.config-D6XqjZrm.js +2 -0
- package/dist/adapters/KpiText.config-ChphMwG5.js +2 -0
- package/dist/adapters/KpiText.config-fO1wc6FH.cjs +1 -0
- package/dist/adapters/LineChart.config-CXJrgz1s.js +2 -0
- package/dist/adapters/LineChart.config-Cg_h-SiJ.cjs +1 -0
- package/dist/adapters/MarkdownChart.config-ByPjX-4O.cjs +1 -0
- package/dist/adapters/MarkdownChart.config-Df2yY9AT.js +2 -0
- package/dist/adapters/MeasureProfileChart.config-BBWGIteF.cjs +1 -0
- package/dist/adapters/MeasureProfileChart.config-C9OFbN9Z.js +2 -0
- package/dist/adapters/PieChart.config-C6jJj6xm.js +2 -0
- package/dist/adapters/PieChart.config-CmCw_8eN.cjs +1 -0
- package/dist/adapters/ProportionBarChart.config-B9NEyFEe.js +2 -0
- package/dist/adapters/ProportionBarChart.config-C3GAVPWn.cjs +1 -0
- package/dist/adapters/RadarChart.config-5AMwEqUJ.cjs +1 -0
- package/dist/adapters/RadarChart.config-Ct_b7IM5.js +2 -0
- package/dist/adapters/RadialBarChart.config-Bp-Sl0cm.js +2 -0
- package/dist/adapters/RadialBarChart.config-D14yoexI.cjs +1 -0
- package/dist/adapters/RecordsTable.config-D2-qmG06.cjs +1 -0
- package/dist/adapters/RecordsTable.config-DIwoqZCU.js +2 -0
- package/dist/adapters/RetentionCombinedChart.config-BWHipi5M.cjs +1 -0
- package/dist/adapters/RetentionCombinedChart.config-D40UgTcl.js +2 -0
- package/dist/adapters/RetentionHeatmap.config-GlnSLrjn.js +2 -0
- package/dist/adapters/RetentionHeatmap.config-MlhZf26c.cjs +1 -0
- package/dist/adapters/SankeyChart.config-Bf1_NHiv.js +2 -0
- package/dist/adapters/SankeyChart.config-BoYf6BFE.cjs +1 -0
- package/dist/adapters/ScatterChart.config-CV2rdGJp.js +2 -0
- package/dist/adapters/ScatterChart.config-DywduGF3.cjs +1 -0
- package/dist/adapters/SunburstChart.config-CrqiE1UZ.js +2 -0
- package/dist/adapters/SunburstChart.config-D5tbF_GJ.cjs +1 -0
- package/dist/adapters/TreeMapChart.config-BJ8HnZU0.cjs +1 -0
- package/dist/adapters/TreeMapChart.config-DxgIqIIj.js +2 -0
- package/dist/adapters/WaterfallChart.config-Cns8fLFu.js +2 -0
- package/dist/adapters/WaterfallChart.config-D_kdL9SN.cjs +1 -0
- package/dist/adapters/compiler-BxZHh0UD.cjs +166 -0
- package/dist/adapters/{compiler-CQJ5GOwF.js → compiler-CBGD_4Et.js} +1160 -1861
- package/dist/adapters/core/index.cjs +1 -1
- package/dist/adapters/core/index.js +1 -1
- package/dist/adapters/{core-DgTGXxDu.cjs → core-CIGuwGuI.cjs} +1 -1
- package/dist/adapters/{core-DXkuSUBg.js → core-DAAnqPyN.js} +3 -3
- package/dist/adapters/express/index.cjs +1 -1
- package/dist/adapters/express/index.js +5 -5
- package/dist/adapters/fastify/index.cjs +1 -1
- package/dist/adapters/fastify/index.js +23 -23
- package/dist/{server/google-eKAc20al.js → adapters/google-DRY7jnOh.js} +46 -28
- package/dist/adapters/{google-BhvizbFR.cjs → google-PsZzwedr.cjs} +2 -2
- package/dist/adapters/{handler-DrRT6c14.cjs → handler-BcYTw6zB.cjs} +12 -12
- package/dist/adapters/{handler-CphYSZRh.js → handler-eA0VJDHj.js} +334 -237
- package/dist/adapters/hono/index.cjs +1 -1
- package/dist/adapters/hono/index.js +4 -4
- package/dist/adapters/mcp-tools.cjs +1 -1
- package/dist/adapters/mcp-tools.js +2 -2
- package/dist/adapters/mcp-transport-BpG44Fvn.js +730 -0
- package/dist/adapters/mcp-transport-CDxZXpc-.cjs +42 -0
- package/dist/adapters/nextjs/index.cjs +1 -1
- package/dist/adapters/nextjs/index.js +5 -5
- package/dist/adapters/{openai-D-VMcPao.js → openai-BZ48ioYp.js} +1 -1
- package/dist/adapters/{openai-CSzWluuv.cjs → openai-Bw1j-OiP.cjs} +1 -1
- package/dist/adapters/{openai-CI9vGKSf.cjs → openai-CLjyL5_J.cjs} +2 -2
- package/dist/adapters/{openai-CBrN4nxl.js → openai-CYYjUG_3.js} +3 -3
- package/dist/adapters/{utils-DkmShl5f.js → utils-BagURNRb.js} +1947 -1122
- package/dist/adapters/utils-BiKIg2tk.cjs +128 -0
- package/dist/adapters/utils.cjs +1 -1
- package/dist/adapters/utils.d.ts +17 -3
- package/dist/adapters/utils.js +1 -1
- package/dist/cjs/adapters/utils.d.ts +17 -3
- package/dist/cjs/client/charts/chartConfigRegistry.d.ts +7 -0
- package/dist/cjs/client/charts/chartConfigs.d.ts +17 -1
- package/dist/cjs/client/client/CubeClient.d.ts +11 -1
- package/dist/cjs/client/components/AnalysisBuilder/AnalysisDisplayConfigPanel.d.ts +4 -2
- package/dist/cjs/client/components/AnalysisBuilder/ColumnFormatsEditor.d.ts +10 -0
- package/dist/cjs/client/components/AnalysisBuilder/DisplayOptionControl.d.ts +3 -2
- package/dist/cjs/client/components/AnalysisBuilder/utils/queryUtils.d.ts +7 -1
- package/dist/cjs/client/components/analyticsPortlet/PortletChart.d.ts +2 -1
- package/dist/cjs/client/components/analyticsPortlet/PortletChartView.d.ts +4 -1
- package/dist/cjs/client/components/analyticsPortlet/usePortletDeadMembers.d.ts +24 -0
- package/dist/cjs/client/components/analyticsPortlet/usePortletPagination.d.ts +21 -0
- package/dist/cjs/client/components/charts/RecordsTable.config.d.ts +10 -0
- package/dist/cjs/client/components/charts/RecordsTable.d.ts +4 -0
- package/dist/cjs/client/components/charts/recordsTableHooks.d.ts +68 -0
- package/dist/cjs/client/icons/types.d.ts +1 -0
- package/dist/cjs/client/index.d.ts +2 -2
- package/dist/cjs/client/types.d.ts +92 -1
- package/dist/cjs/client/utils/recordsTableUtils.d.ts +71 -0
- package/dist/cjs/client/utils/rowLinkUtils.d.ts +35 -0
- package/dist/cjs/server/agent/chart-validation.d.ts +1 -1
- package/dist/cjs/server/ai/chart-schema.d.ts +117 -0
- package/dist/cjs/server/ai/discovery-helpers.d.ts +14 -0
- package/dist/cjs/server/ai/discovery.d.ts +6 -0
- package/dist/cjs/server/ai/query-schema.d.ts +1 -1
- package/dist/cjs/server/attribute-dimensions.d.ts +11 -8
- package/dist/cjs/server/builders/group-by-builder.d.ts +15 -0
- package/dist/cjs/server/compiler.d.ts +3 -4
- package/dist/cjs/server/executor.d.ts +15 -0
- package/dist/cjs/server/index.d.ts +2 -0
- package/dist/cjs/server/query-handlers.d.ts +1 -0
- package/dist/cjs/server/query-validator.d.ts +36 -4
- package/dist/cjs/server/types/core.d.ts +5 -0
- package/dist/cjs/server/types/cube.d.ts +12 -0
- package/dist/cjs/server/types/query.d.ts +8 -0
- package/dist/cli/index.cjs +130 -52
- package/dist/client/charts/chartConfigRegistry.d.ts +7 -0
- package/dist/client/charts/chartConfigs.d.ts +17 -1
- package/dist/client/charts.js +13 -13
- package/dist/client/chunks/{DashboardEditModal-9An5EDAz.js → DashboardEditModal-_ZDMwaGX.js} +1653 -1188
- package/dist/client/chunks/DashboardEditModal-_ZDMwaGX.js.map +1 -0
- package/dist/client/chunks/{ProportionBarChart-BVcbGY2C.js → ProportionBarChart-qfpAWhIg.js} +3 -3
- package/dist/client/chunks/{ProportionBarChart-BVcbGY2C.js.map → ProportionBarChart-qfpAWhIg.js.map} +1 -1
- package/dist/client/chunks/RecordsTable-KmJy94xN.js +556 -0
- package/dist/client/chunks/RecordsTable-KmJy94xN.js.map +1 -0
- package/dist/client/chunks/{RetentionCombinedChart-D68Rvdi-.js → RetentionCombinedChart-C7X6aj97.js} +3 -3
- package/dist/client/chunks/{RetentionCombinedChart-D68Rvdi-.js.map → RetentionCombinedChart-C7X6aj97.js.map} +1 -1
- package/dist/client/chunks/{RetentionHeatmap-CE7BAjrB.js → RetentionHeatmap-PpRpiqR_.js} +2 -2
- package/dist/client/chunks/{RetentionHeatmap-CE7BAjrB.js.map → RetentionHeatmap-PpRpiqR_.js.map} +1 -1
- package/dist/client/chunks/{analysis-builder-D1pYvvwc.js → analysis-builder-DaqyOjLX.js} +169 -168
- package/dist/client/chunks/{analysis-builder-D1pYvvwc.js.map → analysis-builder-DaqyOjLX.js.map} +1 -1
- package/dist/client/chunks/{analysis-builder-shared-BQvwUc6z.js → analysis-builder-shared-ow9KAHDP.js} +965 -954
- package/dist/client/chunks/analysis-builder-shared-ow9KAHDP.js.map +1 -0
- package/dist/client/chunks/{chart-activity-grid-DvD_4wJz.js → chart-activity-grid-DO82rrbW.js} +137 -84
- package/dist/client/chunks/chart-activity-grid-DO82rrbW.js.map +1 -0
- package/dist/client/chunks/{chart-area-DPp3hSOK.js → chart-area-9SBeG0GM.js} +21 -21
- package/dist/client/chunks/{chart-area-DPp3hSOK.js.map → chart-area-9SBeG0GM.js.map} +1 -1
- package/dist/client/chunks/{chart-bar-Od3pOyZ0.js → chart-bar-tfgmLK2D.js} +5 -5
- package/dist/client/chunks/{chart-bar-Od3pOyZ0.js.map → chart-bar-tfgmLK2D.js.map} +1 -1
- package/dist/client/chunks/{chart-box-plot-l0iFn2n2.js → chart-box-plot-BuYW6j6g.js} +2 -2
- package/dist/client/chunks/{chart-box-plot-l0iFn2n2.js.map → chart-box-plot-BuYW6j6g.js.map} +1 -1
- package/dist/client/chunks/{chart-bubble-Dl0RcP8N.js → chart-bubble-BNmonWqW.js} +2 -2
- package/dist/client/chunks/{chart-bubble-Dl0RcP8N.js.map → chart-bubble-BNmonWqW.js.map} +1 -1
- package/dist/client/chunks/{chart-candlestick-DZMqbscF.js → chart-candlestick-BYeWNkKl.js} +2 -2
- package/dist/client/chunks/{chart-candlestick-DZMqbscF.js.map → chart-candlestick-BYeWNkKl.js.map} +1 -1
- package/dist/client/chunks/{chart-data-table-DgiNBOWf.js → chart-data-table-C_oHiK6N.js} +1094 -1029
- package/dist/client/chunks/chart-data-table-C_oHiK6N.js.map +1 -0
- package/dist/client/chunks/{chart-funnel-YLZlyN1X.js → chart-funnel-B_CWC3cL.js} +2 -2
- package/dist/client/chunks/{chart-funnel-YLZlyN1X.js.map → chart-funnel-B_CWC3cL.js.map} +1 -1
- package/dist/client/chunks/{chart-gauge-BsqE2wwF.js → chart-gauge-D7VxwPnx.js} +3 -3
- package/dist/client/chunks/{chart-gauge-BsqE2wwF.js.map → chart-gauge-D7VxwPnx.js.map} +1 -1
- package/dist/client/chunks/{chart-heat-map-BsND8RM_.js → chart-heat-map-q7Vf_dog.js} +3 -3
- package/dist/client/chunks/{chart-heat-map-BsND8RM_.js.map → chart-heat-map-q7Vf_dog.js.map} +1 -1
- package/dist/client/chunks/{chart-kpi-delta-m0azuva-.js → chart-kpi-delta-PEuA3iGs.js} +3 -3
- package/dist/client/chunks/{chart-kpi-delta-m0azuva-.js.map → chart-kpi-delta-PEuA3iGs.js.map} +1 -1
- package/dist/client/chunks/{chart-kpi-number-6JS15SqF.js → chart-kpi-number-DlxrO6Pq.js} +5 -5
- package/dist/client/chunks/{chart-kpi-number-6JS15SqF.js.map → chart-kpi-number-DlxrO6Pq.js.map} +1 -1
- package/dist/client/chunks/{chart-kpi-text-BqX8p8Jn.js → chart-kpi-text-Cx6cJu2s.js} +3 -3
- package/dist/client/chunks/{chart-kpi-text-BqX8p8Jn.js.map → chart-kpi-text-Cx6cJu2s.js.map} +1 -1
- package/dist/client/chunks/{chart-line-NCmpxBfE.js → chart-line-pDe25JzB.js} +3 -3
- package/dist/client/chunks/{chart-line-NCmpxBfE.js.map → chart-line-pDe25JzB.js.map} +1 -1
- package/dist/client/chunks/{chart-markdown-ZOobqiiX.js → chart-markdown-CRY15yp0.js} +2 -2
- package/dist/client/chunks/{chart-markdown-ZOobqiiX.js.map → chart-markdown-CRY15yp0.js.map} +1 -1
- package/dist/client/chunks/{chart-measure-profile-CBAZaicJ.js → chart-measure-profile-DyQ-vvuC.js} +3 -3
- package/dist/client/chunks/{chart-measure-profile-CBAZaicJ.js.map → chart-measure-profile-DyQ-vvuC.js.map} +1 -1
- package/dist/client/chunks/{chart-pie-ChrasEI8.js → chart-pie-ZrnBycy1.js} +15 -15
- package/dist/client/chunks/{chart-pie-ChrasEI8.js.map → chart-pie-ZrnBycy1.js.map} +1 -1
- package/dist/client/chunks/{chart-radar-CxSVF7yL.js → chart-radar-BXbnYMUJ.js} +13 -13
- package/dist/client/chunks/{chart-radar-CxSVF7yL.js.map → chart-radar-BXbnYMUJ.js.map} +1 -1
- package/dist/client/chunks/{chart-radial-bar--SN0Wph0.js → chart-radial-bar-CYxH3ryh.js} +3 -3
- package/dist/client/chunks/{chart-radial-bar--SN0Wph0.js.map → chart-radial-bar-CYxH3ryh.js.map} +1 -1
- package/dist/client/chunks/{chart-sankey-CDOSGg9r.js → chart-sankey-C9R_TDDh.js} +2 -2
- package/dist/client/chunks/{chart-sankey-CDOSGg9r.js.map → chart-sankey-C9R_TDDh.js.map} +1 -1
- package/dist/client/chunks/{chart-scatter-DgcEF-kI.js → chart-scatter-DrwRkzzl.js} +3 -3
- package/dist/client/chunks/{chart-scatter-DgcEF-kI.js.map → chart-scatter-DrwRkzzl.js.map} +1 -1
- package/dist/client/chunks/{chart-sunburst-MB-jlGBm.js → chart-sunburst-Bs1yqIPp.js} +3 -3
- package/dist/client/chunks/{chart-sunburst-MB-jlGBm.js.map → chart-sunburst-Bs1yqIPp.js.map} +1 -1
- package/dist/client/chunks/{chart-tree-map-DeDXveVd.js → chart-tree-map-BNjHhhVq.js} +3 -3
- package/dist/client/chunks/{chart-tree-map-DeDXveVd.js.map → chart-tree-map-BNjHhhVq.js.map} +1 -1
- package/dist/client/chunks/{chart-waterfall-ur4vkO1j.js → chart-waterfall-CyoC0uLT.js} +3 -3
- package/dist/client/chunks/{chart-waterfall-ur4vkO1j.js.map → chart-waterfall-CyoC0uLT.js.map} +1 -1
- package/dist/client/chunks/charts-core-DCQ7od_L.js +190 -0
- package/dist/client/chunks/charts-core-DCQ7od_L.js.map +1 -0
- package/dist/client/chunks/charts-loader-Bya_zDIA.js +86 -0
- package/dist/client/chunks/charts-loader-Bya_zDIA.js.map +1 -0
- package/dist/client/chunks/{en-US-BE6VoG0o.js → en-US-HP6FHuNy.js} +3 -1
- package/dist/client/chunks/{en-US-BE6VoG0o.js.map → en-US-HP6FHuNy.js.map} +1 -1
- package/dist/client/chunks/{nl-NL-CMXHDBr0.js → nl-NL-CEdoCz6Q.js} +51 -1
- package/dist/client/chunks/nl-NL-CEdoCz6Q.js.map +1 -0
- package/dist/client/chunks/{schema-visualization-BEbFtUIL.js → schema-visualization-DfXxFBIY.js} +3 -3
- package/dist/client/chunks/{schema-visualization-BEbFtUIL.js.map → schema-visualization-DfXxFBIY.js.map} +1 -1
- package/dist/client/chunks/{useDirtyStateTracking-CSDg96Rw.js → useDirtyStateTracking-BFJHiiVK.js} +15 -15
- package/dist/client/chunks/{useDirtyStateTracking-CSDg96Rw.js.map → useDirtyStateTracking-BFJHiiVK.js.map} +1 -1
- package/dist/client/chunks/{useExplainAI-BnkoZ-zS.js → useExplainAI-_C4WQE5I.js} +16 -16
- package/dist/client/chunks/{useExplainAI-BnkoZ-zS.js.map → useExplainAI-_C4WQE5I.js.map} +1 -1
- package/dist/client/chunks/{vendor-BmJDaduD.js → vendor-Gb3lH0cc.js} +49 -49
- package/dist/client/chunks/{vendor-BmJDaduD.js.map → vendor-Gb3lH0cc.js.map} +1 -1
- package/dist/client/client/CubeClient.d.ts +11 -1
- package/dist/client/components/AnalysisBuilder/AnalysisDisplayConfigPanel.d.ts +4 -2
- package/dist/client/components/AnalysisBuilder/ColumnFormatsEditor.d.ts +10 -0
- package/dist/client/components/AnalysisBuilder/DisplayOptionControl.d.ts +3 -2
- package/dist/client/components/AnalysisBuilder/utils/queryUtils.d.ts +7 -1
- package/dist/client/components/analyticsPortlet/PortletChart.d.ts +2 -1
- package/dist/client/components/analyticsPortlet/PortletChartView.d.ts +4 -1
- package/dist/client/components/analyticsPortlet/usePortletDeadMembers.d.ts +24 -0
- package/dist/client/components/analyticsPortlet/usePortletPagination.d.ts +21 -0
- package/dist/client/components/charts/RecordsTable.config.d.ts +10 -0
- package/dist/client/components/charts/RecordsTable.d.ts +4 -0
- package/dist/client/components/charts/recordsTableHooks.d.ts +68 -0
- package/dist/client/components.js +1 -1
- package/dist/client/hooks.js +3 -3
- package/dist/client/icons/types.d.ts +1 -0
- package/dist/client/icons.js +2 -2
- package/dist/client/index.d.ts +2 -2
- package/dist/client/index.js +213 -213
- package/dist/client/providers.js +1 -1
- package/dist/client/schema.js +1 -1
- package/dist/client/styles.css +1 -1
- package/dist/client/types.d.ts +92 -1
- package/dist/client/utils/recordsTableUtils.d.ts +71 -0
- package/dist/client/utils/rowLinkUtils.d.ts +35 -0
- package/dist/client/utils.js +14 -14
- package/dist/client-bundle-stats.html +1 -1
- package/dist/mcp-app/mcp-app.html +107 -107
- package/dist/server/agent/chart-validation.d.ts +1 -1
- package/dist/server/ai/chart-schema.d.ts +117 -0
- package/dist/server/ai/discovery-helpers.d.ts +14 -0
- package/dist/server/ai/discovery.d.ts +6 -0
- package/dist/server/ai/query-schema.d.ts +1 -1
- package/dist/server/attribute-dimensions.d.ts +11 -8
- package/dist/server/builders/group-by-builder.d.ts +15 -0
- package/dist/server/compiler.d.ts +3 -4
- package/dist/server/executor.d.ts +15 -0
- package/dist/{adapters/google-eKAc20al.js → server/google-DRY7jnOh.js} +46 -28
- package/dist/server/{google-BhvizbFR.cjs → google-PsZzwedr.cjs} +2 -2
- package/dist/server/index.cjs +34 -34
- package/dist/server/index.d.ts +2 -0
- package/dist/server/index.js +1755 -1445
- package/dist/server/query-handlers.d.ts +1 -0
- package/dist/server/query-validator.d.ts +36 -4
- package/dist/server/types/core.d.ts +5 -0
- package/dist/server/types/cube.d.ts +12 -0
- package/dist/server/types/query.d.ts +8 -0
- package/package.json +1 -1
- package/dist/adapters/ActivityGridChart.config-BQhBE_Mr.js +0 -2
- package/dist/adapters/ActivityGridChart.config-C3tSuOGV.cjs +0 -1
- package/dist/adapters/AreaChart.config-3cme8HyQ.js +0 -2
- package/dist/adapters/AreaChart.config-BSxrT52Z.cjs +0 -1
- package/dist/adapters/BarChart.config-BKS8IecE.cjs +0 -1
- package/dist/adapters/BarChart.config-lt_7PdIi.js +0 -2
- package/dist/adapters/BoxPlotChart.config-B7qvRnrF.cjs +0 -1
- package/dist/adapters/BoxPlotChart.config-Dv6ECj2j.js +0 -2
- package/dist/adapters/BubbleChart.config-BrIH7OAy.cjs +0 -1
- package/dist/adapters/BubbleChart.config-Fhotb7Pg.js +0 -2
- package/dist/adapters/CandlestickChart.config-CWH41FmF.cjs +0 -1
- package/dist/adapters/CandlestickChart.config-RPtXuxsX.js +0 -2
- package/dist/adapters/DataTable.config-71L0GzlT.js +0 -2
- package/dist/adapters/DataTable.config-BsOMQq3J.cjs +0 -1
- package/dist/adapters/FunnelChart.config-Cqte9C04.cjs +0 -1
- package/dist/adapters/FunnelChart.config-DJtwWeNz.js +0 -2
- package/dist/adapters/GaugeChart.config-WkwZ9VdS.cjs +0 -1
- package/dist/adapters/GaugeChart.config-vpVQlP5B.js +0 -2
- package/dist/adapters/HeatMapChart.config-DcmkDl07.cjs +0 -1
- package/dist/adapters/HeatMapChart.config-DsmMgGxJ.js +0 -2
- package/dist/adapters/KpiDelta.config-DVy561BH.js +0 -2
- package/dist/adapters/KpiDelta.config-dpqwLHNE.cjs +0 -1
- package/dist/adapters/KpiNumber.config-927l8nq8.js +0 -2
- package/dist/adapters/KpiNumber.config-BqFBMfPf.cjs +0 -1
- package/dist/adapters/KpiText.config-C-fZXuHq.cjs +0 -1
- package/dist/adapters/KpiText.config-CWoXuhMA.js +0 -2
- package/dist/adapters/LineChart.config-DTp7pqOY.js +0 -2
- package/dist/adapters/LineChart.config-DUGvSjcH.cjs +0 -1
- package/dist/adapters/MarkdownChart.config-23Dmv2Ty.cjs +0 -1
- package/dist/adapters/MarkdownChart.config-Cb2TnS0I.js +0 -2
- package/dist/adapters/MeasureProfileChart.config-B2qbWdhy.cjs +0 -1
- package/dist/adapters/MeasureProfileChart.config-CvBCeI5b.js +0 -2
- package/dist/adapters/PieChart.config-BzJb13QA.js +0 -2
- package/dist/adapters/PieChart.config-plCn5Ehr.cjs +0 -1
- package/dist/adapters/ProportionBarChart.config-1r-_moBH.cjs +0 -1
- package/dist/adapters/ProportionBarChart.config-CN6TtHTp.js +0 -2
- package/dist/adapters/RadarChart.config-BYhdj9M7.js +0 -2
- package/dist/adapters/RadarChart.config-CeUMP-1g.cjs +0 -1
- package/dist/adapters/RadialBarChart.config-B88yXNsq.cjs +0 -1
- package/dist/adapters/RadialBarChart.config-ZMK9HMoh.js +0 -2
- package/dist/adapters/RetentionCombinedChart.config-B5yvgUHM.cjs +0 -1
- package/dist/adapters/RetentionCombinedChart.config-Dd-YMdK8.js +0 -2
- package/dist/adapters/RetentionHeatmap.config-BYzDleoV.cjs +0 -1
- package/dist/adapters/RetentionHeatmap.config-Dvj7yTB0.js +0 -2
- package/dist/adapters/SankeyChart.config-CPFRmgFb.cjs +0 -1
- package/dist/adapters/SankeyChart.config-ClgqXM1N.js +0 -2
- package/dist/adapters/ScatterChart.config-CvJiqPa5.cjs +0 -1
- package/dist/adapters/ScatterChart.config-DLZ3rYMq.js +0 -2
- package/dist/adapters/SunburstChart.config-C_1V5hoQ.cjs +0 -1
- package/dist/adapters/SunburstChart.config-FNU75NCg.js +0 -2
- package/dist/adapters/TreeMapChart.config-CprZk_YF.js +0 -2
- package/dist/adapters/TreeMapChart.config-DNwd0ge9.cjs +0 -1
- package/dist/adapters/WaterfallChart.config-BBhcN_Fh.cjs +0 -1
- package/dist/adapters/WaterfallChart.config-H7s6SSV3.js +0 -2
- package/dist/adapters/compiler-BaLO10VN.cjs +0 -166
- package/dist/adapters/mcp-transport-BGkSz-ZT.cjs +0 -40
- package/dist/adapters/mcp-transport-fJud19xz.js +0 -606
- package/dist/adapters/utils-BY0-KFyI.cjs +0 -128
- package/dist/client/chunks/DashboardEditModal-9An5EDAz.js.map +0 -1
- package/dist/client/chunks/analysis-builder-shared-BQvwUc6z.js.map +0 -1
- package/dist/client/chunks/chart-activity-grid-DvD_4wJz.js.map +0 -1
- package/dist/client/chunks/chart-data-table-DgiNBOWf.js.map +0 -1
- package/dist/client/chunks/charts-core-BAH5pkSB.js +0 -215
- package/dist/client/chunks/charts-core-BAH5pkSB.js.map +0 -1
- package/dist/client/chunks/charts-loader-eToV8je7.js +0 -85
- package/dist/client/chunks/charts-loader-eToV8je7.js.map +0 -1
- package/dist/client/chunks/nl-NL-CMXHDBr0.js.map +0 -1
package/dist/adapters/utils.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./utils-
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("./utils-BiKIg2tk.cjs");exports.buildTransformedQuery=e.t,exports.calculateQueryComplexity=e.n,exports.formatCubeResponse=e.r,exports.formatErrorResponse=e.i,exports.formatMetaResponse=e.a,exports.formatSqlResponse=e.o,exports.formatSqlString=e.S,exports.generateRequestId=e.s,exports.getDatabaseType=e.c,exports.handleBatchRequest=e.l,exports.handleDiscover=e.p,exports.handleDryRun=e.u,exports.handleLoad=e.m,exports.handleSuggest=e.d,exports.handleValidate=e.f,exports.normalizeQueryFields=e.h;
|
package/dist/adapters/utils.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { SemanticLayerCompiler, SemanticQuery, SecurityContext, QuerySuggestion, AIValidationResult } from '../server/index.js';
|
|
1
|
+
import { SemanticLayerCompiler, SemanticQuery, SecurityContext, QuerySuggestion, AIValidationResult, QueryValidationIssue } from '../server/index.js';
|
|
2
2
|
import { normalizeQueryFields } from '../server/query-handlers.js';
|
|
3
3
|
import { MCPPromptResolver, MCPResourceResolver, MCPInstructionsResolver } from './mcp-transport.js';
|
|
4
4
|
export { handleDiscover, handleLoad } from '../server/query-handlers.js';
|
|
@@ -45,9 +45,11 @@ export declare function formatCubeResponse(query: SemanticQuery, result: {
|
|
|
45
45
|
measures?: string[];
|
|
46
46
|
suggestion?: string;
|
|
47
47
|
}>;
|
|
48
|
+
total?: number;
|
|
48
49
|
}, semanticLayer: SemanticLayerCompiler): {
|
|
49
50
|
queryType: string;
|
|
50
51
|
results: {
|
|
52
|
+
total?: number | undefined;
|
|
51
53
|
warnings?: {
|
|
52
54
|
code: string;
|
|
53
55
|
message: string;
|
|
@@ -86,6 +88,7 @@ export declare function formatCubeResponse(query: SemanticQuery, result: {
|
|
|
86
88
|
order?: Record<string, "asc" | "desc">;
|
|
87
89
|
fillMissingDatesValue?: number | null;
|
|
88
90
|
ungrouped?: boolean;
|
|
91
|
+
total?: boolean;
|
|
89
92
|
funnel?: import('../server/index.js').FunnelQueryConfig;
|
|
90
93
|
flow?: import('../server/types/flow.js').FlowQueryConfig;
|
|
91
94
|
retention?: import('../server/index.js').RetentionQueryConfig;
|
|
@@ -167,9 +170,16 @@ export declare function formatMetaResponse(metadata: any): {
|
|
|
167
170
|
};
|
|
168
171
|
};
|
|
169
172
|
/**
|
|
170
|
-
* Standard error response format
|
|
173
|
+
* Standard error response format.
|
|
174
|
+
*
|
|
175
|
+
* `issues` is additive: the `error` string keeps its exact shape for existing
|
|
176
|
+
* clients, while a caller that needs to act on a *particular* unknown member —
|
|
177
|
+
* a dashboard dropping the column for a deleted attribute, say — has something
|
|
178
|
+
* structured to read. Splitting the joined string back apart is not reliable,
|
|
179
|
+
* since the per-field hints contain the same separator.
|
|
171
180
|
*/
|
|
172
|
-
export declare function formatErrorResponse(error: string | Error, status?: number): {
|
|
181
|
+
export declare function formatErrorResponse(error: string | Error, status?: number, issues?: QueryValidationIssue[]): {
|
|
182
|
+
issues?: QueryValidationIssue[] | undefined;
|
|
173
183
|
error: string;
|
|
174
184
|
status: number;
|
|
175
185
|
};
|
|
@@ -197,6 +207,7 @@ export declare function handleBatchRequest(queries: SemanticQuery[], securityCon
|
|
|
197
207
|
results: ({
|
|
198
208
|
queryType: string;
|
|
199
209
|
results: {
|
|
210
|
+
total?: number | undefined;
|
|
200
211
|
warnings?: {
|
|
201
212
|
code: string;
|
|
202
213
|
message: string;
|
|
@@ -235,6 +246,7 @@ export declare function handleBatchRequest(queries: SemanticQuery[], securityCon
|
|
|
235
246
|
order?: Record<string, "asc" | "desc">;
|
|
236
247
|
fillMissingDatesValue?: number | null;
|
|
237
248
|
ungrouped?: boolean;
|
|
249
|
+
total?: boolean;
|
|
238
250
|
funnel?: import('../server/index.js').FunnelQueryConfig;
|
|
239
251
|
flow?: import('../server/types/flow.js').FlowQueryConfig;
|
|
240
252
|
retention?: import('../server/index.js').RetentionQueryConfig;
|
|
@@ -242,10 +254,12 @@ export declare function handleBatchRequest(queries: SemanticQuery[], securityCon
|
|
|
242
254
|
slowQuery: boolean;
|
|
243
255
|
success: boolean;
|
|
244
256
|
error?: undefined;
|
|
257
|
+
issues?: undefined;
|
|
245
258
|
query?: undefined;
|
|
246
259
|
} | {
|
|
247
260
|
success: boolean;
|
|
248
261
|
error: string;
|
|
262
|
+
issues: QueryValidationIssue[] | undefined;
|
|
249
263
|
query: SemanticQuery;
|
|
250
264
|
})[];
|
|
251
265
|
}>;
|
package/dist/adapters/utils.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { S as e, a as t, c as n, d as r, f as i, h as a, i as o, l as s, m as c, n as l, o as u, p as d, r as f, s as p, t as m, u as h } from "./utils-
|
|
1
|
+
import { S as e, a as t, c as n, d as r, f as i, h as a, i as o, l as s, m as c, n as l, o as u, p as d, r as f, s as p, t as m, u as h } from "./utils-BagURNRb.js";
|
|
2
2
|
export { m as buildTransformedQuery, l as calculateQueryComplexity, f as formatCubeResponse, o as formatErrorResponse, t as formatMetaResponse, u as formatSqlResponse, e as formatSqlString, p as generateRequestId, n as getDatabaseType, s as handleBatchRequest, d as handleDiscover, h as handleDryRun, c as handleLoad, r as handleSuggest, i as handleValidate, a as normalizeQueryFields };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { SemanticLayerCompiler, SemanticQuery, SecurityContext, QuerySuggestion, AIValidationResult } from '../server/index.js';
|
|
1
|
+
import { SemanticLayerCompiler, SemanticQuery, SecurityContext, QuerySuggestion, AIValidationResult, QueryValidationIssue } from '../server/index.js';
|
|
2
2
|
import { normalizeQueryFields } from '../server/query-handlers.js';
|
|
3
3
|
import { MCPPromptResolver, MCPResourceResolver, MCPInstructionsResolver } from './mcp-transport.js';
|
|
4
4
|
export { handleDiscover, handleLoad } from '../server/query-handlers.js';
|
|
@@ -45,9 +45,11 @@ export declare function formatCubeResponse(query: SemanticQuery, result: {
|
|
|
45
45
|
measures?: string[];
|
|
46
46
|
suggestion?: string;
|
|
47
47
|
}>;
|
|
48
|
+
total?: number;
|
|
48
49
|
}, semanticLayer: SemanticLayerCompiler): {
|
|
49
50
|
queryType: string;
|
|
50
51
|
results: {
|
|
52
|
+
total?: number | undefined;
|
|
51
53
|
warnings?: {
|
|
52
54
|
code: string;
|
|
53
55
|
message: string;
|
|
@@ -86,6 +88,7 @@ export declare function formatCubeResponse(query: SemanticQuery, result: {
|
|
|
86
88
|
order?: Record<string, "asc" | "desc">;
|
|
87
89
|
fillMissingDatesValue?: number | null;
|
|
88
90
|
ungrouped?: boolean;
|
|
91
|
+
total?: boolean;
|
|
89
92
|
funnel?: import('../server/index.js').FunnelQueryConfig;
|
|
90
93
|
flow?: import('../server/types/flow.js').FlowQueryConfig;
|
|
91
94
|
retention?: import('../server/index.js').RetentionQueryConfig;
|
|
@@ -167,9 +170,16 @@ export declare function formatMetaResponse(metadata: any): {
|
|
|
167
170
|
};
|
|
168
171
|
};
|
|
169
172
|
/**
|
|
170
|
-
* Standard error response format
|
|
173
|
+
* Standard error response format.
|
|
174
|
+
*
|
|
175
|
+
* `issues` is additive: the `error` string keeps its exact shape for existing
|
|
176
|
+
* clients, while a caller that needs to act on a *particular* unknown member —
|
|
177
|
+
* a dashboard dropping the column for a deleted attribute, say — has something
|
|
178
|
+
* structured to read. Splitting the joined string back apart is not reliable,
|
|
179
|
+
* since the per-field hints contain the same separator.
|
|
171
180
|
*/
|
|
172
|
-
export declare function formatErrorResponse(error: string | Error, status?: number): {
|
|
181
|
+
export declare function formatErrorResponse(error: string | Error, status?: number, issues?: QueryValidationIssue[]): {
|
|
182
|
+
issues?: QueryValidationIssue[] | undefined;
|
|
173
183
|
error: string;
|
|
174
184
|
status: number;
|
|
175
185
|
};
|
|
@@ -197,6 +207,7 @@ export declare function handleBatchRequest(queries: SemanticQuery[], securityCon
|
|
|
197
207
|
results: ({
|
|
198
208
|
queryType: string;
|
|
199
209
|
results: {
|
|
210
|
+
total?: number | undefined;
|
|
200
211
|
warnings?: {
|
|
201
212
|
code: string;
|
|
202
213
|
message: string;
|
|
@@ -235,6 +246,7 @@ export declare function handleBatchRequest(queries: SemanticQuery[], securityCon
|
|
|
235
246
|
order?: Record<string, "asc" | "desc">;
|
|
236
247
|
fillMissingDatesValue?: number | null;
|
|
237
248
|
ungrouped?: boolean;
|
|
249
|
+
total?: boolean;
|
|
238
250
|
funnel?: import('../server/index.js').FunnelQueryConfig;
|
|
239
251
|
flow?: import('../server/types/flow.js').FlowQueryConfig;
|
|
240
252
|
retention?: import('../server/index.js').RetentionQueryConfig;
|
|
@@ -242,10 +254,12 @@ export declare function handleBatchRequest(queries: SemanticQuery[], securityCon
|
|
|
242
254
|
slowQuery: boolean;
|
|
243
255
|
success: boolean;
|
|
244
256
|
error?: undefined;
|
|
257
|
+
issues?: undefined;
|
|
245
258
|
query?: undefined;
|
|
246
259
|
} | {
|
|
247
260
|
success: boolean;
|
|
248
261
|
error: string;
|
|
262
|
+
issues: QueryValidationIssue[] | undefined;
|
|
249
263
|
query: SemanticQuery;
|
|
250
264
|
})[];
|
|
251
265
|
}>;
|
|
@@ -7,6 +7,13 @@ import { ChartTypeConfig, ChartConfigRegistry } from './chartConfigs.js';
|
|
|
7
7
|
* stay here in full because the server agent reads them synchronously.
|
|
8
8
|
*/
|
|
9
9
|
export declare const chartConfigRegistry: ChartConfigRegistry;
|
|
10
|
+
/**
|
|
11
|
+
* Whether a chart lists records rather than aggregates, and so needs an
|
|
12
|
+
* `ungrouped` query.
|
|
13
|
+
*
|
|
14
|
+
* Reads the eager registry so the query builders need no chart-type switch.
|
|
15
|
+
*/
|
|
16
|
+
export declare function isRecordGrainChart(chartType: string): boolean;
|
|
10
17
|
/**
|
|
11
18
|
* Register a custom chart config into the registry.
|
|
12
19
|
* Used by the chart plugin system.
|
|
@@ -18,6 +18,13 @@ export interface AxisDropZoneConfig {
|
|
|
18
18
|
emptyText?: string;
|
|
19
19
|
/** Enable L/R axis toggle for items in this drop zone (for dual Y-axis support) */
|
|
20
20
|
enableDualAxis?: boolean;
|
|
21
|
+
/**
|
|
22
|
+
* Keep this zone out of automatic chart-config inference (the agent's
|
|
23
|
+
* `inferChartConfig`). For zones whose meaning is subtractive or opt-in — the
|
|
24
|
+
* records table's hidden columns being the case in point — filling them from
|
|
25
|
+
* the query changes what renders rather than completing a partial config.
|
|
26
|
+
*/
|
|
27
|
+
excludeFromInference?: boolean;
|
|
21
28
|
}
|
|
22
29
|
/**
|
|
23
30
|
* Configuration for a single display option
|
|
@@ -28,7 +35,7 @@ export interface DisplayOptionConfig {
|
|
|
28
35
|
/** Display label for the option */
|
|
29
36
|
label: string;
|
|
30
37
|
/** Type of input control to render */
|
|
31
|
-
type: 'boolean' | 'string' | 'number' | 'select' | 'color' | 'paletteColor' | 'axisFormat' | 'stringArray' | 'buttonGroup' | 'thresholdBands';
|
|
38
|
+
type: 'boolean' | 'string' | 'number' | 'select' | 'color' | 'paletteColor' | 'axisFormat' | 'stringArray' | 'buttonGroup' | 'thresholdBands' | 'columnFormats' | 'rowLink';
|
|
32
39
|
/** Default value for the option */
|
|
33
40
|
defaultValue?: any;
|
|
34
41
|
/** Placeholder text for string/number inputs */
|
|
@@ -125,6 +132,15 @@ export interface ChartTypeConfig {
|
|
|
125
132
|
* Omit to mean "always available".
|
|
126
133
|
*/
|
|
127
134
|
isAvailable?: (ctx: ChartAvailabilityContext) => ChartAvailability;
|
|
135
|
+
/**
|
|
136
|
+
* This chart lists individual records rather than aggregates, so the query
|
|
137
|
+
* built for it must be `ungrouped`.
|
|
138
|
+
*
|
|
139
|
+
* Declared here rather than switched on a chart type inside the query
|
|
140
|
+
* builders, and read from the eager registry so those stay data-driven — and
|
|
141
|
+
* so a custom chart can opt in through the same flag.
|
|
142
|
+
*/
|
|
143
|
+
recordGrain?: boolean;
|
|
128
144
|
}
|
|
129
145
|
/**
|
|
130
146
|
* Registry of all chart type configurations
|
|
@@ -1,4 +1,14 @@
|
|
|
1
|
-
import { CubeQuery, CubeApiOptions, CubeResultSet, ExplainResult, ExplainOptions } from '../types.js';
|
|
1
|
+
import { CubeQuery, CubeApiOptions, CubeResultSet, CubeValidationIssue, ExplainResult, ExplainOptions } from '../types.js';
|
|
2
|
+
/**
|
|
3
|
+
* A failed query, carrying the server's structured validation detail when it
|
|
4
|
+
* sent any. A caller can then react to one dead member — dropping a column for
|
|
5
|
+
* a deleted attribute, say — instead of only seeing prose.
|
|
6
|
+
*/
|
|
7
|
+
export declare class CubeQueryError extends Error {
|
|
8
|
+
readonly status?: number;
|
|
9
|
+
readonly issues?: CubeValidationIssue[];
|
|
10
|
+
constructor(message: string, status?: number, issues?: CubeValidationIssue[]);
|
|
11
|
+
}
|
|
2
12
|
export declare class CubeClient {
|
|
3
13
|
private apiUrl;
|
|
4
14
|
private headers;
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import { ChartType, ChartDisplayConfig, ColorPalette } from '../../types.js';
|
|
1
|
+
import { ChartAxisConfig, ChartType, ChartDisplayConfig, ColorPalette } from '../../types.js';
|
|
2
2
|
interface AnalysisDisplayConfigPanelProps {
|
|
3
3
|
chartType: ChartType;
|
|
4
4
|
displayConfig: ChartDisplayConfig;
|
|
5
5
|
colorPalette?: ColorPalette;
|
|
6
|
+
/** Passed to options that are keyed by field, such as the records table's column formats. */
|
|
7
|
+
chartConfig?: ChartAxisConfig;
|
|
6
8
|
onDisplayConfigChange: (config: ChartDisplayConfig) => void;
|
|
7
9
|
/** Keys to exclude from displayOptionsConfig rendering (e.g., ['content'] when content is managed elsewhere) */
|
|
8
10
|
excludeKeys?: string[];
|
|
9
11
|
}
|
|
10
|
-
export default function AnalysisDisplayConfigPanel({ chartType, displayConfig, colorPalette, onDisplayConfigChange, excludeKeys, }: AnalysisDisplayConfigPanelProps): import("react").JSX.Element;
|
|
12
|
+
export default function AnalysisDisplayConfigPanel({ chartType, displayConfig, colorPalette, chartConfig, onDisplayConfigChange, excludeKeys, }: AnalysisDisplayConfigPanelProps): import("react").JSX.Element;
|
|
11
13
|
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ChartAxisConfig, ColorPalette, ColumnFormatConfig } from '../../types.js';
|
|
2
|
+
interface ColumnFormatsEditorProps {
|
|
3
|
+
value: Record<string, ColumnFormatConfig>;
|
|
4
|
+
chartConfig?: ChartAxisConfig;
|
|
5
|
+
colorPalette?: ColorPalette;
|
|
6
|
+
onChange: (value: Record<string, ColumnFormatConfig> | undefined) => void;
|
|
7
|
+
t: (key: string, params?: Record<string, string | number>) => string;
|
|
8
|
+
}
|
|
9
|
+
export default function ColumnFormatsEditor({ value, chartConfig, colorPalette, onChange, t }: ColumnFormatsEditorProps): import("react").JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { ChartDisplayConfig, ColorPalette } from '../../types.js';
|
|
1
|
+
import { ChartAxisConfig, ChartDisplayConfig, ColorPalette } from '../../types.js';
|
|
2
2
|
import { DisplayOptionConfig } from '../../charts/chartConfigs.js';
|
|
3
3
|
interface DisplayOptionControlProps {
|
|
4
4
|
option: DisplayOptionConfig;
|
|
5
5
|
displayConfig: ChartDisplayConfig;
|
|
6
6
|
colorPalette?: ColorPalette;
|
|
7
|
+
chartConfig?: ChartAxisConfig;
|
|
7
8
|
onDisplayConfigChange: (config: ChartDisplayConfig) => void;
|
|
8
9
|
}
|
|
9
|
-
export default function DisplayOptionControl({ option, displayConfig, colorPalette, onDisplayConfigChange, }: DisplayOptionControlProps): import("react").JSX.Element | null;
|
|
10
|
+
export default function DisplayOptionControl({ option, displayConfig, colorPalette, chartConfig, onDisplayConfigChange, }: DisplayOptionControlProps): import("react").JSX.Element | null;
|
|
10
11
|
export {};
|
|
@@ -4,7 +4,13 @@ import { MetricItem, BreakdownItem } from '../types.js';
|
|
|
4
4
|
* Convert metrics and breakdowns to CubeQuery format
|
|
5
5
|
* Handles comparison mode by building compareDateRange for time dimensions
|
|
6
6
|
*/
|
|
7
|
-
export declare function buildCubeQuery(metrics: MetricItem[], breakdowns: BreakdownItem[], filters: Filter[], order?: Record<string, 'asc' | 'desc'>, preserveComparisonFilters?: boolean, limit?: number
|
|
7
|
+
export declare function buildCubeQuery(metrics: MetricItem[], breakdowns: BreakdownItem[], filters: Filter[], order?: Record<string, 'asc' | 'desc'>, preserveComparisonFilters?: boolean, limit?: number,
|
|
8
|
+
/**
|
|
9
|
+
* Record-grain charts list rows rather than aggregates — see
|
|
10
|
+
* `ChartTypeConfig.recordGrain`. Without this, editing a records-table
|
|
11
|
+
* portlet in the builder silently rebuilds its query as a grouped one.
|
|
12
|
+
*/
|
|
13
|
+
ungrouped?: boolean): CubeQuery;
|
|
8
14
|
/**
|
|
9
15
|
* Check if a query has any content
|
|
10
16
|
*/
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ChartAxisConfig, ChartDisplayConfig, ChartType, CubeQuery } from '../../types.js';
|
|
1
|
+
import { ChartAxisConfig, ChartDisplayConfig, ChartPagination, ChartType, CubeQuery } from '../../types.js';
|
|
2
2
|
import { FlowChartData } from '../../types/flow.js';
|
|
3
3
|
import { RetentionChartData } from '../../types/retention.js';
|
|
4
4
|
import { ColorPalette } from '../../utils/colorPalettes.js';
|
|
@@ -22,6 +22,7 @@ export interface PortletChartProps {
|
|
|
22
22
|
chartConfig?: ChartAxisConfig;
|
|
23
23
|
displayConfig?: ChartDisplayConfig;
|
|
24
24
|
activeQuery: CubeQuery | null;
|
|
25
|
+
pagination?: ChartPagination;
|
|
25
26
|
colorPalette?: ColorPalette;
|
|
26
27
|
drillEnabled: boolean;
|
|
27
28
|
currentChartConfig?: ChartAxisConfig | null;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ChartAxisConfig, ChartDisplayConfig, ChartType, CubeQuery } from '../../types.js';
|
|
1
|
+
import { ChartAxisConfig, ChartDisplayConfig, ChartPagination, ChartType, CubeQuery } from '../../types.js';
|
|
2
2
|
import { FlowChartData } from '../../types/flow.js';
|
|
3
3
|
import { RetentionChartData } from '../../types/retention.js';
|
|
4
4
|
import { ColorPalette } from '../../utils/colorPalettes.js';
|
|
@@ -26,6 +26,9 @@ export interface PortletChartViewProps {
|
|
|
26
26
|
flowChartData: FlowChartData | null;
|
|
27
27
|
retentionChartData: RetentionChartData | null;
|
|
28
28
|
activeQuery: CubeQuery | null;
|
|
29
|
+
pagination?: ChartPagination;
|
|
30
|
+
/** Members dropped because the model no longer has them; surfaced as a note. */
|
|
31
|
+
droppedMembers?: string[];
|
|
29
32
|
drill: DrillInteraction;
|
|
30
33
|
isDrillEnabled: boolean;
|
|
31
34
|
onNavigateBack: () => void;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { CubeQuery } from '../../types.js';
|
|
2
|
+
export interface UsePortletDeadMembersParams {
|
|
3
|
+
queryObject: CubeQuery | null;
|
|
4
|
+
/** The error from the last attempt, if it failed. */
|
|
5
|
+
error: unknown;
|
|
6
|
+
}
|
|
7
|
+
export interface UsePortletDeadMembersResult {
|
|
8
|
+
/** The query with dead members removed — the original when there are none. */
|
|
9
|
+
query: CubeQuery | null;
|
|
10
|
+
/** Members dropped so far, for the note shown above the chart. */
|
|
11
|
+
droppedMembers: string[];
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Pull the prunable members out of a failed query, or `null` when the failure
|
|
15
|
+
* is not one we may recover from.
|
|
16
|
+
*
|
|
17
|
+
* A single unknown *filter* member makes the whole error unrecoverable, even
|
|
18
|
+
* alongside prunable ones: re-running without the dead columns would still
|
|
19
|
+
* carry the dead filter.
|
|
20
|
+
*/
|
|
21
|
+
export declare function prunableMembers(error: unknown): string[] | null;
|
|
22
|
+
/** Remove members from everything that projects or orders by them. */
|
|
23
|
+
export declare function withoutMembers(query: CubeQuery, members: string[]): CubeQuery;
|
|
24
|
+
export declare function usePortletDeadMembers({ queryObject, error }: UsePortletDeadMembersParams): UsePortletDeadMembersResult;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { ChartPagination, ChartType, CubeQuery } from '../../types.js';
|
|
2
|
+
/** Fixed page sizes, matching the records table's own `pageSize` option. */
|
|
3
|
+
export declare const PAGE_SIZE_OPTIONS: number[];
|
|
4
|
+
export interface UsePortletPaginationParams {
|
|
5
|
+
chartType: ChartType;
|
|
6
|
+
/** The query to paginate — the drilled query when one is active, else the base query. */
|
|
7
|
+
activeQuery: CubeQuery | null;
|
|
8
|
+
/** Authored page size from the portlet's display config. */
|
|
9
|
+
pageSize?: number;
|
|
10
|
+
}
|
|
11
|
+
export interface UsePortletPaginationResult {
|
|
12
|
+
/** `activeQuery` with limit/offset/order/total merged in, or it unchanged when paging is off. */
|
|
13
|
+
paginatedQuery: CubeQuery | null;
|
|
14
|
+
/**
|
|
15
|
+
* Passed to the chart as `ChartProps.pagination`; undefined when paging is
|
|
16
|
+
* off. `total` is left unset here — it arrives with the response, so the
|
|
17
|
+
* caller fills it in from the result set.
|
|
18
|
+
*/
|
|
19
|
+
pagination?: Omit<ChartPagination, 'total'>;
|
|
20
|
+
}
|
|
21
|
+
export declare function usePortletPagination({ chartType, activeQuery, pageSize: authoredPageSize }: UsePortletPaginationParams): UsePortletPaginationResult;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ChartTypeConfig } from '../../charts/chartConfigs.js';
|
|
2
|
+
/**
|
|
3
|
+
* Configuration for the records table.
|
|
4
|
+
*
|
|
5
|
+
* Eager metadata (`label`, `description`, `useCase`, `isAvailable`) lives in the
|
|
6
|
+
* unified `chartRegistry` entry — see `src/client/charts/chartRegistry.ts`. This
|
|
7
|
+
* file owns the lazy-loaded shape: drop zones, display options, clickable
|
|
8
|
+
* elements, validation.
|
|
9
|
+
*/
|
|
10
|
+
export declare const recordsTableConfig: ChartTypeConfig;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ChartProps } from '../../types.js';
|
|
3
|
+
declare const RecordsTable: React.MemoExoticComponent<({ data, chartConfig, displayConfig, queryObject, colorPalette, height, onDataPointClick, drillEnabled, pagination }: ChartProps) => React.JSX.Element>;
|
|
4
|
+
export default RecordsTable;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { ChartAxisConfig, ChartPagination, CubeQuery } from '../../types.js';
|
|
3
|
+
export declare const DEFAULT_PAGE_SIZE = 25;
|
|
4
|
+
/**
|
|
5
|
+
* Which columns to render, in which order.
|
|
6
|
+
*
|
|
7
|
+
* The author's arrangement comes from the Columns drop zone; a viewer can drag
|
|
8
|
+
* a header on top of it, and that order is remembered per column set. It is
|
|
9
|
+
* *reconciled* rather than substituted, so a column the author adds later still
|
|
10
|
+
* appears instead of being swallowed by a stale local order.
|
|
11
|
+
*/
|
|
12
|
+
export declare function useRecordsColumns(params: {
|
|
13
|
+
rows: Record<string, unknown>[];
|
|
14
|
+
chartConfig?: ChartAxisConfig;
|
|
15
|
+
queryObject?: CubeQuery;
|
|
16
|
+
}): {
|
|
17
|
+
columns: string[];
|
|
18
|
+
storageKey: string;
|
|
19
|
+
draggedColumn: string | null;
|
|
20
|
+
didDragRef: React.MutableRefObject<boolean>;
|
|
21
|
+
startColumnDrag: (column: string) => void;
|
|
22
|
+
endColumnDrag: () => void;
|
|
23
|
+
dropColumn: (target: string) => void;
|
|
24
|
+
};
|
|
25
|
+
/**
|
|
26
|
+
* Drag-resizable column widths, remembered per column set.
|
|
27
|
+
*
|
|
28
|
+
* A chart has no portlet id and no write path back to `displayConfig`, so an
|
|
29
|
+
* authored `columnWidths` acts as the default a viewer's own drags layer over —
|
|
30
|
+
* the same arrangement the data browser uses.
|
|
31
|
+
*/
|
|
32
|
+
export declare function useColumnWidths(params: {
|
|
33
|
+
columns: string[];
|
|
34
|
+
storageKey: string;
|
|
35
|
+
authored?: Record<string, number>;
|
|
36
|
+
}): {
|
|
37
|
+
columnWidths: Record<string, number>;
|
|
38
|
+
totalWidth: number | undefined;
|
|
39
|
+
tableRef: React.RefObject<HTMLTableElement>;
|
|
40
|
+
didResizeRef: React.MutableRefObject<boolean>;
|
|
41
|
+
startResize: (event: React.MouseEvent, column: string) => void;
|
|
42
|
+
};
|
|
43
|
+
/**
|
|
44
|
+
* Sorting and paging, server-side when the host offers it.
|
|
45
|
+
*
|
|
46
|
+
* With a `pagination` prop the host re-queries, so both must go through it:
|
|
47
|
+
* sorting only the loaded page would put the wrong rows on page 1. Without one
|
|
48
|
+
* — the AnalysisBuilder preview, the notebook, plugin hosts — the table sorts
|
|
49
|
+
* and pages over the rows it already has.
|
|
50
|
+
*/
|
|
51
|
+
export declare function useRecordsPaging(params: {
|
|
52
|
+
rows: Record<string, unknown>[];
|
|
53
|
+
pagination?: ChartPagination;
|
|
54
|
+
authoredPageSize?: number;
|
|
55
|
+
}): {
|
|
56
|
+
sort: {
|
|
57
|
+
column: string;
|
|
58
|
+
direction: "asc" | "desc";
|
|
59
|
+
} | null;
|
|
60
|
+
toggleSort: (column: string) => void;
|
|
61
|
+
visibleRows: Record<string, unknown>[];
|
|
62
|
+
page: number;
|
|
63
|
+
pageSize: number;
|
|
64
|
+
pageCount: number;
|
|
65
|
+
rowCount: number;
|
|
66
|
+
goToPage: (next: number) => void;
|
|
67
|
+
showPager: boolean;
|
|
68
|
+
};
|
|
@@ -80,6 +80,7 @@ export interface IconRegistry {
|
|
|
80
80
|
chartRadialBar: IconDefinition;
|
|
81
81
|
chartTreemap: IconDefinition;
|
|
82
82
|
chartTable: IconDefinition;
|
|
83
|
+
chartRecordsTable: IconDefinition;
|
|
83
84
|
chartActivityGrid: IconDefinition;
|
|
84
85
|
chartKpiNumber: IconDefinition;
|
|
85
86
|
chartKpiDelta: IconDefinition;
|
|
@@ -33,7 +33,7 @@ useCubeFeatures } from './providers/CubeProvider.js';
|
|
|
33
33
|
export { ScrollContainerProvider, useScrollContainer } from './providers/ScrollContainerContext.js';
|
|
34
34
|
export { useCubeFieldLabel } from './hooks/useCubeFieldLabel.js';
|
|
35
35
|
export { createCubeClient } from './client/CubeClient.js';
|
|
36
|
-
export { CubeClient } from './client/CubeClient.js';
|
|
36
|
+
export { CubeClient, CubeQueryError } from './client/CubeClient.js';
|
|
37
37
|
export { useCubeMetaQuery, useCubeLoadQuery, useCubeQuery, useMultiCubeLoadQuery, useDryRunQuery, useMultiDryRunQueries, useDryRunQueries, useExplainQuery, createExplainQueryKey, useExplainAI, useFunnelQuery, createFunnelQueryKey, useFlowQuery, createFlowQueryKey, } from './hooks/queries/index.js';
|
|
38
38
|
export type { UseCubeMetaQueryOptions, UseCubeMetaQueryResult, UseCubeLoadQueryOptions, UseCubeLoadQueryResult, UseMultiCubeLoadQueryOptions, UseMultiCubeLoadQueryResult, DebugDataEntry, UseExplainQueryOptions, UseExplainQueryResult, UseExplainAIOptions, UseExplainAIResult, UseFlowQueryOptions, UseFlowQueryResult, } from './hooks/queries/index.js';
|
|
39
39
|
export { useAnalysisBuilder } from './hooks/useAnalysisBuilderHook.js';
|
|
@@ -55,7 +55,7 @@ export { useTheme } from './hooks/useTheme.js';
|
|
|
55
55
|
export { useScrollDetection } from './hooks/useScrollDetection.js';
|
|
56
56
|
export { useElementVisibility } from './hooks/useElementVisibility.js';
|
|
57
57
|
export { useDrillInteraction } from './hooks/useDrillInteraction.js';
|
|
58
|
-
export type { PortletConfig, ChartType, BuiltInChartType, ChartAxisConfig, ChartDisplayConfig, ChartProps, ColorPalette, CubeQuery, CubeQueryOptions, CubeApiOptions, DashboardConfig, PortletGroup, PortletGroupCell, FeaturesConfig, XlsExportFeatureConfig, ThumbnailFeatureConfig, MultiQueryConfig, QueryMergeStrategy, FunnelBindingKey, FunnelBindingKeyMapping, FunnelStep, FunnelConfig, FunnelStepResult, FunnelExecutionResult, FunnelChartData, FunnelValidationError, FunnelValidationResult, UseFunnelQueryOptions, UseFunnelQueryResult, ServerFlowQuery, FlowQueryConfig, FlowChartData, FlowSliceState, SankeyNode, SankeyLink, FlowStartingStep, FlowResultRow, } from './types.js';
|
|
58
|
+
export type { PortletConfig, ChartType, BuiltInChartType, ChartAxisConfig, ChartDisplayConfig, ChartProps, ColorPalette, CubeQuery, CubeQueryOptions, CubeApiOptions, CubeValidationIssue, ChartPagination, ColumnFormatConfig, ColumnFormatKind, RowLinkConfig, DashboardConfig, PortletGroup, PortletGroupCell, FeaturesConfig, XlsExportFeatureConfig, ThumbnailFeatureConfig, MultiQueryConfig, QueryMergeStrategy, FunnelBindingKey, FunnelBindingKeyMapping, FunnelStep, FunnelConfig, FunnelStepResult, FunnelExecutionResult, FunnelChartData, FunnelValidationError, FunnelValidationResult, UseFunnelQueryOptions, UseFunnelQueryResult, ServerFlowQuery, FlowQueryConfig, FlowChartData, FlowSliceState, SankeyNode, SankeyLink, FlowStartingStep, FlowResultRow, } from './types.js';
|
|
59
59
|
export { isQueryConfig, isFunnelConfig, isFlowConfig, isRetentionConfig, isMultiQuery, isSingleQuery, isValidAnalysisConfig, createDefaultQueryConfig, createDefaultFunnelConfig, createDefaultFlowConfig, createDefaultRetentionConfig, createDefaultConfig, isValidAnalysisWorkspace, createDefaultWorkspace } from './types/analysisConfig.js';
|
|
60
60
|
export type { AnalysisConfig, QueryAnalysisConfig, FunnelAnalysisConfig, FlowAnalysisConfig, RetentionAnalysisConfig, AnalysisWorkspace } from './types/analysisConfig.js';
|
|
61
61
|
export { isMultiQueryConfig, isServerFunnelQuery, isServerFlowQuery, isSankeyData } from './types.js';
|
|
@@ -71,7 +71,7 @@ export interface CubeMeta {
|
|
|
71
71
|
}
|
|
72
72
|
export type FieldLabelMap = Record<string, string>;
|
|
73
73
|
export type { ColorPalette } from './utils/colorPalettes.js';
|
|
74
|
-
export type BuiltInChartType = 'line' | 'bar' | 'pie' | 'table' | 'area' | 'scatter' | 'radar' | 'radialBar' | 'treemap' | 'bubble' | 'activityGrid' | 'kpiNumber' | 'kpiDelta' | 'kpiText' | 'markdown' | 'funnel' | 'sankey' | 'sunburst' | 'heatmap' | 'retentionHeatmap' | 'retentionCombined' | 'boxPlot' | 'waterfall' | 'candlestick' | 'proportionBar' | 'measureProfile' | 'gauge';
|
|
74
|
+
export type BuiltInChartType = 'line' | 'bar' | 'pie' | 'table' | 'area' | 'scatter' | 'radar' | 'radialBar' | 'treemap' | 'bubble' | 'activityGrid' | 'kpiNumber' | 'kpiDelta' | 'kpiText' | 'markdown' | 'funnel' | 'sankey' | 'sunburst' | 'heatmap' | 'retentionHeatmap' | 'retentionCombined' | 'boxPlot' | 'waterfall' | 'candlestick' | 'proportionBar' | 'measureProfile' | 'gauge' | 'recordsTable';
|
|
75
75
|
export type ChartType = BuiltInChartType | (string & {});
|
|
76
76
|
export interface AxisFormatConfig {
|
|
77
77
|
label?: string;
|
|
@@ -80,6 +80,7 @@ export interface AxisFormatConfig {
|
|
|
80
80
|
decimals?: number;
|
|
81
81
|
customPrefix?: string;
|
|
82
82
|
customSuffix?: string;
|
|
83
|
+
currencyCode?: string;
|
|
83
84
|
}
|
|
84
85
|
export interface ChartAxisConfig {
|
|
85
86
|
xAxis?: string[];
|
|
@@ -89,10 +90,49 @@ export interface ChartAxisConfig {
|
|
|
89
90
|
colorField?: string;
|
|
90
91
|
dateField?: string[];
|
|
91
92
|
valueField?: string[];
|
|
93
|
+
columns?: string[];
|
|
94
|
+
hiddenColumns?: string[];
|
|
92
95
|
x?: string;
|
|
93
96
|
y?: string[];
|
|
94
97
|
yAxisAssignment?: Record<string, 'left' | 'right'>;
|
|
95
98
|
}
|
|
99
|
+
/**
|
|
100
|
+
* How a records-table column renders its value. Chosen per column in the chart
|
|
101
|
+
* editor — never inferred from the data, so the same field can be a badge in one
|
|
102
|
+
* dashboard and plain text in another.
|
|
103
|
+
*/
|
|
104
|
+
export type ColumnFormatKind = 'text' | 'number' | 'date' | 'badge' | 'progress';
|
|
105
|
+
export interface ColumnFormatConfig {
|
|
106
|
+
kind: ColumnFormatKind;
|
|
107
|
+
/** Numeric formatting for `kind: 'number'` — reuses the shared axis formatter. */
|
|
108
|
+
numberFormat?: AxisFormatConfig;
|
|
109
|
+
/** Granularity for `kind: 'date'`. */
|
|
110
|
+
dateGranularity?: TimeGranularity;
|
|
111
|
+
/**
|
|
112
|
+
* Value → palette colour index for `kind: 'badge'`. Values with no mapping
|
|
113
|
+
* render neutral rather than being assigned a guessed colour.
|
|
114
|
+
*/
|
|
115
|
+
badgeColors?: Array<{
|
|
116
|
+
value: string;
|
|
117
|
+
colorIndex: number;
|
|
118
|
+
}>;
|
|
119
|
+
/** Bounds for `kind: 'progress'` (default 0-100). Values are clamped. */
|
|
120
|
+
progressMin?: number;
|
|
121
|
+
progressMax?: number;
|
|
122
|
+
/** How a `kind: 'progress'` cell draws: a full-width bar, or a compact ring for narrow columns. */
|
|
123
|
+
progressStyle?: 'bar' | 'circle';
|
|
124
|
+
/** Header override; falls back to the field's metadata title. */
|
|
125
|
+
label?: string;
|
|
126
|
+
align?: 'left' | 'right';
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Row-level click-through for the records table. Tokens of the form
|
|
130
|
+
* `{Cube.field}` are substituted from the row, including hidden columns.
|
|
131
|
+
*/
|
|
132
|
+
export interface RowLinkConfig {
|
|
133
|
+
urlTemplate: string;
|
|
134
|
+
target?: 'self' | 'blank';
|
|
135
|
+
}
|
|
96
136
|
export interface ThresholdBand {
|
|
97
137
|
value: number;
|
|
98
138
|
color: string;
|
|
@@ -119,6 +159,10 @@ export interface ChartDisplayConfig {
|
|
|
119
159
|
sortSegments?: boolean;
|
|
120
160
|
fitToWidth?: boolean;
|
|
121
161
|
pivotTimeDimension?: boolean;
|
|
162
|
+
columnFormats?: Record<string, ColumnFormatConfig>;
|
|
163
|
+
columnWidths?: Record<string, number>;
|
|
164
|
+
rowLink?: RowLinkConfig;
|
|
165
|
+
pageSize?: number;
|
|
122
166
|
target?: string;
|
|
123
167
|
template?: string;
|
|
124
168
|
prefix?: string;
|
|
@@ -353,6 +397,12 @@ export interface CubeQuery {
|
|
|
353
397
|
segments?: string[];
|
|
354
398
|
/** When true, returns raw row-level data without GROUP BY or aggregation */
|
|
355
399
|
ungrouped?: boolean;
|
|
400
|
+
/**
|
|
401
|
+
* Ask the server for the number of rows the query would return with no
|
|
402
|
+
* limit/offset, read back via `CubeResultSet.totalCount()`. Costs a second
|
|
403
|
+
* round trip, so only paginated views set it.
|
|
404
|
+
*/
|
|
405
|
+
total?: boolean;
|
|
356
406
|
}
|
|
357
407
|
/**
|
|
358
408
|
* Merge strategy for combining multiple query results
|
|
@@ -389,6 +439,17 @@ export interface CubeApiOptions {
|
|
|
389
439
|
headers?: Record<string, string>;
|
|
390
440
|
credentials?: 'include' | 'omit' | 'same-origin';
|
|
391
441
|
}
|
|
442
|
+
/**
|
|
443
|
+
* An unknown member the server rejected, mirroring the server's
|
|
444
|
+
* `QueryValidationIssue`. `source` is what decides the response: a projected
|
|
445
|
+
* member can be dropped and the query re-run, whereas dropping a filter would
|
|
446
|
+
* widen the result set and must stay an error.
|
|
447
|
+
*/
|
|
448
|
+
export interface CubeValidationIssue {
|
|
449
|
+
source: 'measure' | 'dimension' | 'timeDimension' | 'filter';
|
|
450
|
+
member: string;
|
|
451
|
+
message: string;
|
|
452
|
+
}
|
|
392
453
|
export interface CubeResultSet {
|
|
393
454
|
rawData(): any[];
|
|
394
455
|
tablePivot(): any[];
|
|
@@ -401,6 +462,8 @@ export interface CubeResultSet {
|
|
|
401
462
|
ttlMs: number;
|
|
402
463
|
ttlRemainingMs: number;
|
|
403
464
|
} | undefined;
|
|
465
|
+
/** Rows the query would return without limit/offset — only when `total: true` was asked for. */
|
|
466
|
+
totalCount?(): number | undefined;
|
|
404
467
|
}
|
|
405
468
|
export interface AnalyticsPortletProps {
|
|
406
469
|
query: string;
|
|
@@ -464,6 +527,34 @@ export interface ChartProps {
|
|
|
464
527
|
onDataPointClick?: (event: import('./types/drill.js').ChartDataPointClickEvent) => void;
|
|
465
528
|
/** Whether drill-down is enabled (shows pointer cursor on clickable elements) */
|
|
466
529
|
drillEnabled?: boolean;
|
|
530
|
+
/**
|
|
531
|
+
* Server-side pagination, supplied by hosts that can re-query (the dashboard
|
|
532
|
+
* portlet). Absent in the AnalysisBuilder preview, the notebook and plugin
|
|
533
|
+
* hosts, where a chart pages and sorts over the rows it already has.
|
|
534
|
+
*/
|
|
535
|
+
pagination?: ChartPagination;
|
|
536
|
+
}
|
|
537
|
+
/**
|
|
538
|
+
* Paging and sorting state a host drives on the chart's behalf.
|
|
539
|
+
*
|
|
540
|
+
* Sort lives here rather than in the chart because with server-side paging a
|
|
541
|
+
* header click has to re-order the whole result set: sorting only the loaded
|
|
542
|
+
* page would put the wrong rows on page 1.
|
|
543
|
+
*/
|
|
544
|
+
export interface ChartPagination {
|
|
545
|
+
page: number;
|
|
546
|
+
pageSize: number;
|
|
547
|
+
pageSizeOptions: number[];
|
|
548
|
+
/** Total matching rows, once the server has reported one. */
|
|
549
|
+
total?: number;
|
|
550
|
+
sort?: {
|
|
551
|
+
column: string;
|
|
552
|
+
direction: 'asc' | 'desc';
|
|
553
|
+
};
|
|
554
|
+
setPage: (page: number) => void;
|
|
555
|
+
setPageSize: (pageSize: number) => void;
|
|
556
|
+
/** Cycles the column asc → desc → unsorted, resetting to the first page. */
|
|
557
|
+
toggleSort: (column: string) => void;
|
|
467
558
|
}
|
|
468
559
|
export interface ThumbnailFeatureConfig {
|
|
469
560
|
enabled: boolean;
|