@sisense/sdk-ui 2.27.0 → 2.29.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ai.cjs +1 -1
- package/dist/ai.js +5 -5
- package/dist/analytics-composer/node.cjs +1 -1
- package/dist/analytics-composer/node.js +1693 -1339
- package/dist/analytics-composer.cjs +73 -73
- package/dist/analytics-composer.js +23 -17
- package/dist/apply-styled-options-to-query-CaP4IMrQ.js +6379 -0
- package/dist/apply-styled-options-to-query-D5D8pRl2.cjs +1 -0
- package/dist/{index-D7mHzfx0.js → index-C77YCBVd.js} +4 -1
- package/dist/{index-BX9p-XrU.cjs → index-C9G8giSk.cjs} +1 -1
- package/dist/index.cjs +406 -406
- package/dist/index.js +23197 -22359
- package/dist/index.umd.js +719 -720
- package/dist/packages/sdk-ui/src/domains/dashboarding/components/editable-layout/const.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/dashboard-model-translator.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/get-dashboard-model.d.ts +9 -2
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/get-dashboard-models.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/translate-dashboard-utils.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/use-dashboard-model/dashboard-model-reducer/persist-dashboard-model-middleware.d.ts +12 -3
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/use-dashboard-model/dashboard-model-reducer/types.d.ts +29 -1
- package/dist/packages/sdk-ui/src/domains/dashboarding/hooks/use-widget-excel-download.d.ts +23 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/hooks/use-widget-updates-persistence.d.ts +27 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/persistence/deep-merge.d.ts +17 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/persistence/types.d.ts +15 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/persistence/update-types.d.ts +51 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/types.d.ts +13 -0
- package/dist/packages/sdk-ui/src/domains/query-execution/hooks/use-execute-excel-query/excel-export/build-jaql-excel-export.d.ts +48 -0
- package/dist/packages/sdk-ui/src/domains/query-execution/hooks/use-execute-excel-query/excel-export/build-xlsx-export-payload.d.ts +33 -0
- package/dist/packages/sdk-ui/src/domains/query-execution/hooks/use-execute-excel-query/excel-query-state-reducer.d.ts +2 -0
- package/dist/packages/sdk-ui/src/domains/query-execution/hooks/use-execute-excel-query/use-excel-query-params-changed.d.ts +8 -0
- package/dist/packages/sdk-ui/src/domains/query-execution/hooks/use-execute-excel-query/use-execute-excel-query.d.ts +8 -0
- package/dist/packages/sdk-ui/src/domains/query-execution/index.d.ts +2 -1
- package/dist/packages/sdk-ui/src/domains/query-execution/types.d.ts +97 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/components/scattermap/utils/map.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/data.d.ts +0 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/utils/with-calendar-heatmap-data-coloring.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/highcharts-based-chart-renderer/build-highchart-options.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/types.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/components/pivot-table/formatters/data-cell-formatters/data-cell-color-formatter.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/components/pivot-table/helpers/prepare-pivot-styling-props.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/components/pivot-table/hooks/use-render-pivot.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/components/table/pure-table/helpers/get-cell-styles.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/components/table/pure-table/types.d.ts +3 -3
- package/dist/packages/sdk-ui/src/domains/visualizations/components/table/styles/get-custom-pagination-styles.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data/filter-and-aggregate-chart-data.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data-options/types.d.ts +27 -23
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data-options/utils.d.ts +4 -4
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/boxplot-chart-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/cartesian/cartesian-chart-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/cartesian/utils/axis/axis-builders.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/cartesian/utils/axis/axis-settings.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/cartesian/utils/axis/axis-transformers.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/cartesian/utils/series-processor.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/category-chart-options/category-chart-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/category-chart-options/funnel-chart-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/category-chart-options/pie-chart-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/category-chart-options/sunburst-chart-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/category-chart-options/treemap-chart-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/chart-options-service.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/common-highcharts-option-service.d.ts +3 -3
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/range-chart-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/scatter-chart-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/theme-option-service.d.ts +3 -3
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/funnel-series.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/pie-plot-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/pie-series.d.ts +4 -4
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/scatter-series.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/sunburst/sunburst-levels.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/sunburst/sunburst-options.d.ts +3 -3
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/sunburst/sunburst-series.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/treemap/treemap-labels.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/treemap/treemap-options.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/treemap/treemap-series.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/query-definition/filter-to-readable-label.d.ts +14 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/core/query-definition/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/core/query-definition/query-definition.d.ts +5 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/core/query-definition/query-pill.d.ts +5 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/core/query-definition/truncate-pill-label.d.ts +10 -0
- package/dist/packages/sdk-ui/src/domains/widgets/change-events.d.ts +6 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/chart-widget/types.d.ts +9 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/chart-widget/use-chart-widget-excel-download.d.ts +18 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/custom-widget/types.d.ts +20 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/custom-widget/use-custom-widget-excel-download.d.ts +16 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/pivot-table-widget/pivot-table-widget.d.ts +15 -1
- package/dist/packages/sdk-ui/src/domains/widgets/components/pivot-table-widget/types.d.ts +9 -2
- package/dist/packages/sdk-ui/src/domains/widgets/components/pivot-table-widget/use-pivot-widget-excel-download.d.ts +18 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/widget/types.d.ts +13 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-widget-style-options/to-widget-dto-style.d.ts +43 -4
- package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/types.d.ts +6 -0
- package/dist/packages/sdk-ui/src/domains/widgets/helpers/download-blob-as-file.d.ts +14 -0
- package/dist/packages/sdk-ui/src/domains/widgets/helpers/excel-export-map-dimensions-measures.d.ts +18 -0
- package/dist/packages/sdk-ui/src/domains/widgets/helpers/index.d.ts +2 -0
- package/dist/packages/sdk-ui/src/domains/widgets/hooks/use-excel-query-file-loader.d.ts +13 -0
- package/dist/packages/sdk-ui/src/domains/widgets/hooks/use-track-widget-init.d.ts +44 -0
- package/dist/packages/sdk-ui/src/domains/widgets/hooks/use-with-excel-download-menu-item.d.ts +21 -0
- package/dist/packages/sdk-ui/src/domains/widgets/hooks/widget-entity-id.d.ts +30 -0
- package/dist/packages/sdk-ui/src/domains/widgets/hooks/widget-tracking-adapters.d.ts +41 -0
- package/dist/packages/sdk-ui/src/domains/widgets/shared/widget-style-utils.d.ts +31 -2
- package/dist/packages/sdk-ui/src/domains/widgets/widget-model/get-widget-model.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/widgets/widget-model/widget-model-translator/to-widget-dto-panels.d.ts +29 -1
- package/dist/packages/sdk-ui/src/domains/widgets/widget-model/widget-model-translator/widget-model-translator.d.ts +3 -3
- package/dist/packages/sdk-ui/src/infra/api/rest-api.d.ts +9 -1
- package/dist/packages/sdk-ui/src/infra/app/settings/settings.d.ts +24 -11
- package/dist/packages/sdk-ui/src/infra/app/settings/types/features.d.ts +1 -9
- package/dist/packages/sdk-ui/src/infra/app/types.d.ts +14 -0
- package/dist/packages/sdk-ui/src/infra/contexts/sisense-context/sisense-context-provider.d.ts +1 -1
- package/dist/packages/sdk-ui/src/infra/contexts/theme-provider/custom-theme-provider.d.ts +2 -2
- package/dist/packages/sdk-ui/src/infra/contexts/theme-provider/default-theme-settings.d.ts +2 -2
- package/dist/packages/sdk-ui/src/infra/contexts/theme-provider/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/infra/contexts/theme-provider/theme-context.d.ts +3 -3
- package/dist/packages/sdk-ui/src/infra/contexts/theme-provider/types.d.ts +2 -2
- package/dist/packages/sdk-ui/src/infra/contexts/theme-provider/use-theme-settings.d.ts +2 -2
- package/dist/packages/sdk-ui/src/infra/contexts/theme-provider/use-theme.d.ts +14 -0
- package/dist/packages/sdk-ui/src/infra/formatting/format-data-set.d.ts +21 -0
- package/dist/packages/sdk-ui/src/infra/formatting/format-date.d.ts +67 -0
- package/dist/packages/sdk-ui/src/infra/formatting/format-number.d.ts +24 -0
- package/dist/packages/sdk-ui/src/infra/formatting/index.d.ts +5 -0
- package/dist/packages/sdk-ui/src/infra/modules/build-module-graph.d.ts +31 -0
- package/dist/packages/sdk-ui/src/infra/modules/build-module-registry.d.ts +31 -0
- package/dist/packages/sdk-ui/src/infra/modules/core-module-providers-tree.d.ts +11 -0
- package/dist/packages/sdk-ui/src/infra/modules/core-module.d.ts +26 -0
- package/dist/packages/sdk-ui/src/infra/modules/index.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/modules/module-provider.d.ts +17 -0
- package/dist/packages/sdk-ui/src/infra/modules/modules-context.d.ts +20 -0
- package/dist/packages/sdk-ui/src/infra/modules/types.d.ts +79 -0
- package/dist/packages/sdk-ui/src/infra/plugins/widget-plugins/types.d.ts +52 -2
- package/dist/packages/sdk-ui/src/infra/plugins/widget-plugins/widget-plugin-registry.d.ts +3 -3
- package/dist/packages/sdk-ui/src/infra/themes/legacy-design-settings.d.ts +4 -4
- package/dist/packages/sdk-ui/src/infra/themes/theme-loader.d.ts +4 -4
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/de-de.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/en-us.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/es-ar.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/es-es.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/fr-fr.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/it-it.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/ja-jp.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/ko-kr.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/nl-nl.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/pt-br.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/ru-ru.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/tr-tr.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/zh-cn.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/en.d.ts +3 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/index.d.ts +6 -0
- package/dist/packages/sdk-ui/src/modules/ai/ai-disclaimer.d.ts +2 -2
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/constructs/dimensions/get-dimension-name.d.ts +9 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/constructs/dimensions/translate-dimensions-to-json.d.ts +4 -3
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/constructs/filters/get-filter-name.d.ts +10 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/constructs/filters/translate-filters-to-json.d.ts +3 -3
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/constructs/get-query-element-summary.d.ts +23 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/constructs/measures/get-measure-name.d.ts +10 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/constructs/measures/translate-measures-to-json.d.ts +4 -3
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/dashboard/translate-dashboard-from-json.d.ts +17 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/dashboard/translate-dashboard-to-json.d.ts +15 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/index.d.ts +7 -1
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/query/translate-query-from-json.d.ts +1 -1
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/query/translate-query-to-json.d.ts +4 -3
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/shared/data-options/adapters.d.ts +3 -5
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/shared/data-options/index.d.ts +1 -1
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/shared/expression/custom-formula/process-custom-formula.d.ts +2 -1
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/shared/expression/factory-function-processors.d.ts +0 -1
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/shared/expression/filter-processors.d.ts +8 -4
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/shared/utils/error-path.d.ts +37 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/shared/utils/translation-helpers.d.ts +36 -3
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/types.d.ts +197 -7
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/helpers/index.d.ts +6 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/helpers/to-widget-props.d.ts +27 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/helpers/translate-custom-widget-filters-from-json.d.ts +12 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/helpers/translate-envelope-widget-from-json.d.ts +19 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/helpers/validate-widget-json.d.ts +8 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/helpers/widget-id.d.ts +17 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/translate-widget-from-json.d.ts +19 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/translate-widget-to-json.d.ts +18 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/types.d.ts +7 -23
- package/dist/packages/sdk-ui/src/modules/analytics-composer/widget/chart-options/get-widget-options.d.ts +12 -0
- package/dist/packages/sdk-ui/src/props.d.ts +20 -2
- package/dist/packages/sdk-ui/src/public-api/alpha.d.ts +3 -0
- package/dist/packages/sdk-ui/src/public-api/internal.d.ts +1 -1
- package/dist/packages/sdk-ui/src/public-api/public.d.ts +5 -2
- package/dist/packages/sdk-ui/src/public-api/sisense-internal.d.ts +2 -2
- package/dist/packages/sdk-ui/src/shared/components/loading-indicator.d.ts +2 -2
- package/dist/packages/sdk-ui/src/shared/components/loading-overlay.d.ts +1 -0
- package/dist/packages/sdk-ui/src/shared/hooks/use-element-height.d.ts +19 -0
- package/dist/packages/sdk-ui/src/shared/hooks/use-synced-state.d.ts +23 -2
- package/dist/packages/sdk-ui/src/shared/utils/filter-relations.d.ts +8 -0
- package/dist/packages/sdk-ui/src/shared/utils/gradient.d.ts +5 -0
- package/dist/packages/sdk-ui/src/types.d.ts +217 -1
- package/dist/translations/de-de.cjs +1 -1
- package/dist/translations/de-de.js +5 -2
- package/dist/translations/en-us.cjs +1 -1
- package/dist/translations/en-us.js +1 -1
- package/dist/translations/es-ar.cjs +1 -1
- package/dist/translations/es-ar.js +5 -2
- package/dist/translations/es-es.cjs +1 -1
- package/dist/translations/es-es.js +5 -2
- package/dist/translations/fr-fr.cjs +1 -1
- package/dist/translations/fr-fr.js +5 -2
- package/dist/translations/it-it.cjs +1 -1
- package/dist/translations/it-it.js +5 -2
- package/dist/translations/ja-jp.cjs +1 -1
- package/dist/translations/ja-jp.js +5 -2
- package/dist/translations/ko-kr.cjs +1 -1
- package/dist/translations/ko-kr.js +5 -2
- package/dist/translations/nl-nl.cjs +1 -1
- package/dist/translations/nl-nl.js +5 -2
- package/dist/translations/pt-br.cjs +1 -1
- package/dist/translations/pt-br.js +5 -2
- package/dist/translations/ru-ru.cjs +1 -1
- package/dist/translations/ru-ru.js +5 -2
- package/dist/translations/tr-tr.cjs +1 -1
- package/dist/translations/tr-tr.js +5 -2
- package/dist/translations/zh-cn.cjs +1 -1
- package/dist/translations/zh-cn.js +5 -2
- package/dist/types-7YG0uOzO.js +74 -0
- package/dist/{types-Cq47e5cy.cjs → types-DlYJ_DZ0.cjs} +1 -1
- package/dist/{use-hover-D_mBUhp9.cjs → use-hover-CANskYrn.cjs} +129 -130
- package/dist/{use-hover-CkmV6eu9.js → use-hover-Dju4Dcv3.js} +13079 -12635
- package/dist/{utils-Db3U6oHa.js → utils-BKRpWUGm.js} +1063 -1060
- package/dist/{utils-DM5vp1gw.cjs → utils-C4PIba42.cjs} +10 -10
- package/dist/{widget-composer-CZ0_bPXK.cjs → widget-composer-BXEyx308.cjs} +7 -7
- package/dist/{widget-composer-BiGVKN49.js → widget-composer-DRDw1oBF.js} +258 -206
- package/package.json +11 -8
- package/dist/apply-styled-options-to-query-BzMAmDnD.js +0 -5979
- package/dist/apply-styled-options-to-query-k10gkPCG.cjs +0 -1
- package/dist/dimensions-C3WSSE5j.js +0 -204
- package/dist/dimensions-huCJK0y6.cjs +0 -1
- package/dist/packages/sdk-ui/src/domains/dashboarding/hooks/use-widget-scroll-persistence.d.ts +0 -16
- package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/with-navigator-scroll-save.d.ts +0 -10
- package/dist/types-CzqDZ83C.js +0 -74
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { ComponentType, ReactNode } from 'react';
|
|
2
|
+
import type { ApiContract, ApiField, Module } from './types.js';
|
|
3
|
+
type ProviderComponent = ComponentType<{
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
}>;
|
|
6
|
+
/**
|
|
7
|
+
* API declaration for the `core` module.
|
|
8
|
+
*/
|
|
9
|
+
export interface CoreModuleApiDefinition {
|
|
10
|
+
/** Root-level React providers mounted by `SisenseContextProvider`. */
|
|
11
|
+
providers: ApiField<ProviderComponent[], ProviderComponent[]>;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* API contract for contributing to the `core` module.
|
|
15
|
+
*/
|
|
16
|
+
export type CoreModuleApi = ApiContract<CoreModuleApiDefinition>;
|
|
17
|
+
export declare const CORE_MODULE_NAME = "core";
|
|
18
|
+
/**
|
|
19
|
+
* The `core` module.
|
|
20
|
+
* Always registered automatically by `ModuleProvider`; consumers do not need to list it in the `modules` prop.
|
|
21
|
+
*
|
|
22
|
+
* Owns the `providers` registry — other modules contribute root-level React
|
|
23
|
+
* providers there, which `CoreModuleProvidersTree` mounts inside `SisenseContextProvider`.
|
|
24
|
+
*/
|
|
25
|
+
export declare const CoreModule: Module<CoreModuleApiDefinition>;
|
|
26
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type FunctionComponent, type PropsWithChildren } from 'react';
|
|
2
|
+
import type { Module } from './types.js';
|
|
3
|
+
/**
|
|
4
|
+
* Props for `ModuleProvider`.
|
|
5
|
+
*/
|
|
6
|
+
export interface ModuleProviderProps {
|
|
7
|
+
/**
|
|
8
|
+
* Modules to register.
|
|
9
|
+
*
|
|
10
|
+
* `CoreModule` is registered automatically; consumers do not need to list it.
|
|
11
|
+
*/
|
|
12
|
+
modules?: ReadonlyArray<Module>;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Registers the given modules and makes the API registry available to the children.
|
|
16
|
+
*/
|
|
17
|
+
export declare const ModuleProvider: FunctionComponent<PropsWithChildren<ModuleProviderProps>>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { ModulesApiRegistry } from './build-module-registry.js';
|
|
3
|
+
import type { Module, RegistryOf } from './types.js';
|
|
4
|
+
/**
|
|
5
|
+
* Modules API registry context.
|
|
6
|
+
*/
|
|
7
|
+
export declare const ModulesContext: import("react").Context<ModulesApiRegistry | null>;
|
|
8
|
+
/**
|
|
9
|
+
* Gives access to the API registry for a given module and field.
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```ts
|
|
13
|
+
* const chartBuilders = useModuleApiRegistry(VisualizationsModule, 'chartBuilders');
|
|
14
|
+
* ```
|
|
15
|
+
* @throws if used outside a `ModuleProvider`.
|
|
16
|
+
* @throws if `module` was not registered in the enclosing provider.
|
|
17
|
+
*
|
|
18
|
+
* @alpha
|
|
19
|
+
*/
|
|
20
|
+
export declare const useModuleApiRegistry: <TSchema, K extends keyof TSchema & string>(module: Module<TSchema>, field: K) => RegistryOf<TSchema, K>;
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Producer-side declaration of a single API field on a module.
|
|
3
|
+
*/
|
|
4
|
+
export interface ApiField<TValue, TRegistry> {
|
|
5
|
+
/** Creates the per-registration registry holding contributions for this field. */
|
|
6
|
+
createRegistry: () => TRegistry;
|
|
7
|
+
/** Writes a contribution into the registry. Invoked once per contributor. */
|
|
8
|
+
register: (value: TValue, registry: TRegistry, fromModule: Module) => void;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* The shape of a producer module's `api` property — a record of `ApiField` declarations.
|
|
12
|
+
* Each module declares its own concrete schema (e.g. `CoreModuleApiDefinition`);
|
|
13
|
+
*/
|
|
14
|
+
export type ApiSchema = Record<string, ApiField<any, any>>;
|
|
15
|
+
/**
|
|
16
|
+
* Module definition
|
|
17
|
+
*
|
|
18
|
+
* @alpha
|
|
19
|
+
*/
|
|
20
|
+
export interface Module<TSchema = any> {
|
|
21
|
+
/** Unique module identifier, e.g. `'dashboard'`. */
|
|
22
|
+
name: string;
|
|
23
|
+
/** Module version */
|
|
24
|
+
version: string;
|
|
25
|
+
/**
|
|
26
|
+
* Modules this module integrates with.
|
|
27
|
+
* - `'name'` → hard requirement.
|
|
28
|
+
* - `{ name }` → hard requirement.
|
|
29
|
+
* - `{ name, optional: true }` → soft; contributions to it are dropped if absent.
|
|
30
|
+
* - `{ ..., requiredVersion: '^2.0.0' }` → optional semver range constraint.
|
|
31
|
+
*/
|
|
32
|
+
requires?: ReadonlyArray<ModuleRequirement>;
|
|
33
|
+
/** Modules this one ships as part of its own feature */
|
|
34
|
+
includes?: ReadonlyArray<Module>;
|
|
35
|
+
/**
|
|
36
|
+
* Declarative contributions to other modules, keyed by target module name.
|
|
37
|
+
*/
|
|
38
|
+
integrations?: Record<string, unknown>;
|
|
39
|
+
/** Producer-side API declaration; defines registries other modules contribute to. */
|
|
40
|
+
api?: TSchema;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Hard or soft requirement on another module, optionally version-constrained.
|
|
44
|
+
*
|
|
45
|
+
* @alpha
|
|
46
|
+
*/
|
|
47
|
+
export type ModuleRequirement = string | {
|
|
48
|
+
name: string;
|
|
49
|
+
/** If true, the requirement may be missing and contributions to it are dropped. */
|
|
50
|
+
optional?: boolean;
|
|
51
|
+
/**
|
|
52
|
+
* Semver range the registered target's `version` must satisfy
|
|
53
|
+
* (e.g. `'^2.0.0'`). Mismatches throw at boot unless `optional`.
|
|
54
|
+
*/
|
|
55
|
+
requiredVersion?: string;
|
|
56
|
+
};
|
|
57
|
+
/**
|
|
58
|
+
* Resolves the registry type owned by a producer module's API field — the
|
|
59
|
+
* value `useModuleApiRegistry(module, field)` returns.
|
|
60
|
+
*/
|
|
61
|
+
export type RegistryOf<TSchema, K extends keyof TSchema> = TSchema[K] extends ApiField<any, infer R> ? R : never;
|
|
62
|
+
/**
|
|
63
|
+
* Resolves the contribution value type a consumer must supply for a producer's API field.
|
|
64
|
+
*/
|
|
65
|
+
export type ValueOf<TSchema, K extends keyof TSchema> = TSchema[K] extends ApiField<infer V, any> ? V : never;
|
|
66
|
+
/**
|
|
67
|
+
* Derives the consumer-facing `*ModuleApi` contract from a producer schema.
|
|
68
|
+
* Each field becomes optional and typed as its contribution value.
|
|
69
|
+
*
|
|
70
|
+
* @example
|
|
71
|
+
* ```ts
|
|
72
|
+
* export type CoreModuleApi = ApiContract<CoreModuleApiDefinition>;
|
|
73
|
+
* // → { providers?: ComponentType<{ children: ReactNode }>[] }
|
|
74
|
+
* ```
|
|
75
|
+
* @alpha
|
|
76
|
+
*/
|
|
77
|
+
export type ApiContract<TSchema> = {
|
|
78
|
+
[K in keyof TSchema]?: ValueOf<TSchema, K>;
|
|
79
|
+
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { FunctionComponent, ReactNode } from 'react';
|
|
2
2
|
import type { DataSource, Filter, FilterRelations } from '@sisense/sdk-data';
|
|
3
|
+
import type { DeepPartial } from 'ts-essentials';
|
|
3
4
|
import { AnyObject } from '../../../shared/utils/utility-types';
|
|
4
5
|
import type { AbstractDataPointWithEntries, GenericDataOptions } from '../../../types';
|
|
5
6
|
import type { BasePluginInfo } from '../types';
|
|
@@ -8,7 +9,7 @@ import type { BasePluginInfo } from '../types';
|
|
|
8
9
|
*
|
|
9
10
|
* @sisenseInternal
|
|
10
11
|
*/
|
|
11
|
-
export interface WidgetPlugin<Props extends CustomVisualizationProps = CustomVisualizationProps> extends BasePluginInfo {
|
|
12
|
+
export interface WidgetPlugin<Props extends CustomVisualizationProps<any, any, any, any> = CustomVisualizationProps> extends BasePluginInfo {
|
|
12
13
|
/**
|
|
13
14
|
* The type of plugin
|
|
14
15
|
*/
|
|
@@ -179,7 +180,7 @@ export type AnyWidgetPlugin = WidgetPlugin<any>;
|
|
|
179
180
|
*
|
|
180
181
|
* @sisenseInternal
|
|
181
182
|
*/
|
|
182
|
-
export interface CustomVisualizationProps<DataOptions = GenericDataOptions, StyleOptions = CustomVisualizationStyleOptions, DataPoint extends AbstractDataPointWithEntries = AbstractDataPointWithEntries
|
|
183
|
+
export interface CustomVisualizationProps<DataOptions = GenericDataOptions, StyleOptions = CustomVisualizationStyleOptions, DataPoint extends AbstractDataPointWithEntries = AbstractDataPointWithEntries, CustomOptions = Record<string, unknown>> extends CustomVisualizationEventProps<DataPoint> {
|
|
183
184
|
/** Data source for the custom visualization */
|
|
184
185
|
dataSource?: DataSource;
|
|
185
186
|
/** Data options defining what data to display */
|
|
@@ -190,7 +191,46 @@ export interface CustomVisualizationProps<DataOptions = GenericDataOptions, Styl
|
|
|
190
191
|
filters?: Filter[] | FilterRelations;
|
|
191
192
|
/** Highlight filters for interactive highlighting */
|
|
192
193
|
highlights?: Filter[];
|
|
194
|
+
/**
|
|
195
|
+
* Arbitrary plugin-specific options that is not data- or style-related.
|
|
196
|
+
*
|
|
197
|
+
* @sisenseInternal
|
|
198
|
+
*/
|
|
199
|
+
customOptions?: CustomOptions;
|
|
200
|
+
/**
|
|
201
|
+
* Emit a partial state update to be persisted through the dashboard
|
|
202
|
+
* persistence layer. Injected by the dashboard when the widget lives inside a
|
|
203
|
+
* Dashboard component; `undefined` in standalone use or read-only mode — always
|
|
204
|
+
* call it with optional chaining.
|
|
205
|
+
*
|
|
206
|
+
* @example
|
|
207
|
+
* ```tsx
|
|
208
|
+
* onChange?.({ customOptions: { lastPage: 3 } });
|
|
209
|
+
* ```
|
|
210
|
+
*
|
|
211
|
+
* @sisenseInternal
|
|
212
|
+
*/
|
|
213
|
+
onChange?: (update: VisualizationStateUpdate<StyleOptions, CustomOptions>) => void;
|
|
193
214
|
}
|
|
215
|
+
/**
|
|
216
|
+
* Partial persistable state a custom visualization can push back to the
|
|
217
|
+
* persistence layer. Carries the same props vocabulary the plugin already reads
|
|
218
|
+
* from.
|
|
219
|
+
*
|
|
220
|
+
* Both fields are deeply partial and are deep-merged into the current widget
|
|
221
|
+
* state: nested plain objects merge recursively at any depth, so a plugin
|
|
222
|
+
* passes only the leaf values that changed — e.g.
|
|
223
|
+
* `{ styleOptions: { pagination: { currentPage: 3 } } }` updates `currentPage`
|
|
224
|
+
* while preserving the sibling `pagination` keys. Arrays and primitives are
|
|
225
|
+
* replaced wholesale (last-write-wins). Keys cannot be deleted via merge —
|
|
226
|
+
* overwrite with an explicit value (e.g. `null`) instead.
|
|
227
|
+
*
|
|
228
|
+
* @sisenseInternal
|
|
229
|
+
*/
|
|
230
|
+
export type VisualizationStateUpdate<StyleOptions = CustomVisualizationStyleOptions, CustomOptions = Record<string, unknown>> = {
|
|
231
|
+
styleOptions?: DeepPartial<StyleOptions>;
|
|
232
|
+
customOptions?: DeepPartial<CustomOptions>;
|
|
233
|
+
};
|
|
194
234
|
/**
|
|
195
235
|
* Style options for a custom visualization.
|
|
196
236
|
*
|
|
@@ -206,6 +246,16 @@ export interface CustomVisualizationStyleOptions extends AnyObject {
|
|
|
206
246
|
* @sisenseInternal
|
|
207
247
|
*/
|
|
208
248
|
export type CustomVisualization<Props = CustomVisualizationProps> = (props: Props) => ReactNode;
|
|
249
|
+
/**
|
|
250
|
+
* A custom visualization with erased prop types, used for heterogeneous storage
|
|
251
|
+
* at registry/context boundaries. Each concrete visualization specializes
|
|
252
|
+
* {@link CustomVisualizationProps} differently (and may require extra props such
|
|
253
|
+
* as a widget `id`), so the registry cannot know each exact shape — the prop
|
|
254
|
+
* type is intentionally erased here. Do not consume prop types from this alias.
|
|
255
|
+
*
|
|
256
|
+
* @sisenseInternal
|
|
257
|
+
*/
|
|
258
|
+
export type AnyCustomVisualization = CustomVisualization<any>;
|
|
209
259
|
/**
|
|
210
260
|
* Event props for custom visualizations with generic data point type.
|
|
211
261
|
*
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { AnyCustomVisualization } from './types.js';
|
|
2
2
|
/**
|
|
3
3
|
* Central widget registration and lookup.
|
|
4
4
|
* Plugin-sourced entries take priority over legacy-sourced entries.
|
|
@@ -12,7 +12,7 @@ export declare class WidgetPluginRegistry {
|
|
|
12
12
|
* Plugin-sourced entries take priority over legacy-sourced entries.
|
|
13
13
|
* Within the same source, first-write-wins (no silent overwrites).
|
|
14
14
|
*/
|
|
15
|
-
register(widgetTypeName: string, component:
|
|
15
|
+
register(widgetTypeName: string, component: AnyCustomVisualization, source?: 'plugin' | 'legacy'): void;
|
|
16
16
|
/**
|
|
17
17
|
* Unregister a widget by type name and source.
|
|
18
18
|
* Only removes the entry if it matches the given source.
|
|
@@ -23,7 +23,7 @@ export declare class WidgetPluginRegistry {
|
|
|
23
23
|
* When `source` is provided, returns the component only if the entry matches that source.
|
|
24
24
|
* When omitted, returns the component for any source (plugin takes priority over legacy).
|
|
25
25
|
*/
|
|
26
|
-
getComponent(widgetTypeName: string, source?: 'plugin' | 'legacy'):
|
|
26
|
+
getComponent(widgetTypeName: string, source?: 'plugin' | 'legacy'): AnyCustomVisualization | undefined;
|
|
27
27
|
/**
|
|
28
28
|
* Check if a widget is registered.
|
|
29
29
|
* When `source` is provided, returns true only if an entry exists for that source.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CompleteThemeSettingsInternal, ThemeOid } from '../../types.js';
|
|
2
2
|
/**
|
|
3
|
-
* Legacy analog of
|
|
3
|
+
* Legacy analog of CompleteThemeSettingsInternal used in Sisense UI.
|
|
4
4
|
*/
|
|
5
5
|
export type LegacyDesignSettings = {
|
|
6
6
|
oid: ThemeOid;
|
|
@@ -88,11 +88,11 @@ export declare const LEGACY_DESIGN_TYPES: {
|
|
|
88
88
|
dark: string;
|
|
89
89
|
};
|
|
90
90
|
/**
|
|
91
|
-
* Converts legacy (used in Sisense UI) design settings and
|
|
91
|
+
* Converts legacy (used in Sisense UI) design settings and its palette object to CompleteThemeSettingsInternal.
|
|
92
92
|
*
|
|
93
93
|
* @param legacyDesignSettings - legacy design settings.
|
|
94
94
|
* @param legacyPalette - legacy palette object.
|
|
95
95
|
* @returns
|
|
96
96
|
*/
|
|
97
|
-
export declare function convertToThemeSettings(legacyDesignSettings: LegacyDesignSettings, legacyPalette: LegacyPalette, domainUrl: string):
|
|
97
|
+
export declare function convertToThemeSettings(legacyDesignSettings: LegacyDesignSettings, legacyPalette: LegacyPalette, domainUrl: string): CompleteThemeSettingsInternal;
|
|
98
98
|
export declare function getPaletteName(legacyDesignSettings: LegacyDesignSettings): string;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import type { HttpClient } from '@sisense/sdk-rest-client';
|
|
2
|
-
import type {
|
|
2
|
+
import type { CompleteThemeSettingsInternal, ThemeOid } from '../../types';
|
|
3
3
|
import { type LegacyPalette } from './legacy-design-settings';
|
|
4
4
|
/**
|
|
5
|
-
* Fetches theme settings from the Sisense instance and converts them to
|
|
5
|
+
* Fetches theme settings from the Sisense instance and converts them to CompleteThemeSettingsInternal.
|
|
6
6
|
*
|
|
7
7
|
* @param themeOid - Theme oid.
|
|
8
8
|
* @param httpClient - Sisense REST API client.
|
|
9
|
-
* @returns
|
|
9
|
+
* @returns CompleteThemeSettingsInternal from server.
|
|
10
10
|
* @internal
|
|
11
11
|
*/
|
|
12
|
-
export declare function getThemeSettingsByOid(themeOid: ThemeOid, httpClient: Pick<HttpClient, 'get' | 'url'>): Promise<
|
|
12
|
+
export declare function getThemeSettingsByOid(themeOid: ThemeOid, httpClient: Pick<HttpClient, 'get' | 'url'>): Promise<CompleteThemeSettingsInternal>;
|
|
13
13
|
export declare function getLegacyPalette(paletteName: string, httpClient: Pick<HttpClient, 'get'>): Promise<LegacyPalette>;
|
|
@@ -232,6 +232,9 @@ export declare const resources: {
|
|
|
232
232
|
distributeEqualWidth: string;
|
|
233
233
|
download: string;
|
|
234
234
|
csvFile: string;
|
|
235
|
+
excelFile: string;
|
|
236
|
+
repeatRowsRecommended: string;
|
|
237
|
+
mergeRows: string;
|
|
235
238
|
};
|
|
236
239
|
};
|
|
237
240
|
customWidgets: {
|
|
@@ -681,6 +684,9 @@ export declare const resources: {
|
|
|
681
684
|
distributeEqualWidth: string;
|
|
682
685
|
download: string;
|
|
683
686
|
csvFile: string;
|
|
687
|
+
excelFile: string;
|
|
688
|
+
repeatRowsRecommended: string;
|
|
689
|
+
mergeRows: string;
|
|
684
690
|
};
|
|
685
691
|
};
|
|
686
692
|
customWidgets: {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CompleteThemeSettingsInternal } from '../..';
|
|
2
2
|
export default function AiDisclaimer({ theme }: {
|
|
3
|
-
theme:
|
|
3
|
+
theme: CompleteThemeSettingsInternal;
|
|
4
4
|
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Returns the dimensional attribute path with the `DM.` module prefix removed.
|
|
3
|
+
*
|
|
4
|
+
* @param dimensionString - NLQ dimension reference (e.g. `DM.Commerce.Date.Years`)
|
|
5
|
+
* @returns Path without `DM.` (e.g. `Commerce.Date.Years`)
|
|
6
|
+
*
|
|
7
|
+
* @internal
|
|
8
|
+
*/
|
|
9
|
+
export declare function getDimensionName(dimensionString: string): string;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { Attribute
|
|
1
|
+
import { Attribute } from '@sisense/sdk-data';
|
|
2
2
|
import type { SortDirection } from '@sisense/sdk-data';
|
|
3
3
|
import { NlqTranslationResult } from '../../../types.js';
|
|
4
|
+
import { type DimensionItemJSON } from '../../types.js';
|
|
4
5
|
/** Runtime StyledColumn: wrapper with column and optional CategoryStyle (from chart dataOptions) */
|
|
5
6
|
type StyledColumn = {
|
|
6
7
|
column: Attribute;
|
|
@@ -15,8 +16,8 @@ type StyledColumn = {
|
|
|
15
16
|
* properties; otherwise outputs composeCode string.
|
|
16
17
|
*
|
|
17
18
|
* @param dimensions - Array of CSDK Attribute or StyledColumn objects
|
|
18
|
-
* @returns NlqTranslationResult
|
|
19
|
+
* @returns NlqTranslationResult with dimension items in NLQ JSON format
|
|
19
20
|
* @internal
|
|
20
21
|
*/
|
|
21
|
-
export declare function translateDimensionsToJSON(dimensions: (Attribute | StyledColumn)[]): NlqTranslationResult<
|
|
22
|
+
export declare function translateDimensionsToJSON(dimensions: (Attribute | StyledColumn)[]): NlqTranslationResult<DimensionItemJSON[]>;
|
|
22
23
|
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { FunctionCall } from '../../types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Extracts a human-readable label from a filter FunctionCall.
|
|
4
|
+
*
|
|
5
|
+
* @param call - Filter factory function call
|
|
6
|
+
* @returns Attribute name, measure name, or function suffix for logical combinators
|
|
7
|
+
*
|
|
8
|
+
* @internal
|
|
9
|
+
*/
|
|
10
|
+
export declare function getFilterName(call: FunctionCall): string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Filter, FilterRelations,
|
|
1
|
+
import { Filter, FilterRelations, type FunctionCall } from '@sisense/sdk-data';
|
|
2
2
|
import { NlqTranslationResult } from '../../../types.js';
|
|
3
3
|
/**
|
|
4
4
|
* Translates CSDK Filter array or FilterRelations to NLQ JSON format (FunctionCall array).
|
|
@@ -10,7 +10,7 @@ import { NlqTranslationResult } from '../../../types.js';
|
|
|
10
10
|
* @returns NlqTranslationResult<FunctionCall[]> with array of FunctionCall objects or structured errors
|
|
11
11
|
* @internal
|
|
12
12
|
*/
|
|
13
|
-
export declare function translateFiltersToJSON(filters: Filter[] | FilterRelations | undefined): NlqTranslationResult<
|
|
13
|
+
export declare function translateFiltersToJSON(filters: Filter[] | FilterRelations | undefined): NlqTranslationResult<FunctionCall[]>;
|
|
14
14
|
/**
|
|
15
15
|
* Translates CSDK Filter array to NLQ JSON format (FunctionCall array).
|
|
16
16
|
*
|
|
@@ -22,4 +22,4 @@ export declare function translateFiltersToJSON(filters: Filter[] | FilterRelatio
|
|
|
22
22
|
* @returns NlqTranslationResult<FunctionCall[]> with array of FunctionCall objects or structured errors
|
|
23
23
|
* @internal
|
|
24
24
|
*/
|
|
25
|
-
export declare function translateHighlightsToJSON(highlights: Filter[] | undefined): NlqTranslationResult<
|
|
25
|
+
export declare function translateHighlightsToJSON(highlights: Filter[] | undefined): NlqTranslationResult<FunctionCall[]>;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { type ElementSummary, type QueryElementItemJSON } from '../types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Options for {@link getQueryElementSummary}.
|
|
4
|
+
*
|
|
5
|
+
* @internal
|
|
6
|
+
*/
|
|
7
|
+
export type GetQueryElementSummaryOptions = {
|
|
8
|
+
/**
|
|
9
|
+
* Distinguishes filter vs highlight when `item` is a `filterFactory.*` call.
|
|
10
|
+
* Ignored for dimensions and measures. Defaults to `'filter'`.
|
|
11
|
+
*/
|
|
12
|
+
readonly role?: 'filter' | 'highlight';
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* Derives a human-readable name and element kind from a query JSON item.
|
|
16
|
+
*
|
|
17
|
+
* @param item - Dimension, measure, filter, or highlight JSON entry
|
|
18
|
+
* @param options - When `item` is a filter/highlight `FunctionCall`, `role` selects the returned kind
|
|
19
|
+
* @returns Summary with display name and type, or `null` when `item` is not a recognized shape
|
|
20
|
+
*
|
|
21
|
+
* @internal
|
|
22
|
+
*/
|
|
23
|
+
export declare function getQueryElementSummary(item: QueryElementItemJSON, options?: GetQueryElementSummaryOptions): ElementSummary | null;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { FunctionCall } from '../../types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Extracts a human-readable name from a measure FunctionCall.
|
|
4
|
+
*
|
|
5
|
+
* @param call - Measure factory function call
|
|
6
|
+
* @returns Display name for LLM / UI labels
|
|
7
|
+
*
|
|
8
|
+
* @internal
|
|
9
|
+
*/
|
|
10
|
+
export declare function getMeasureName(call: FunctionCall): string;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Measure } from '@sisense/sdk-data';
|
|
2
2
|
import type { SortDirection } from '@sisense/sdk-data';
|
|
3
3
|
import { NlqTranslationResult } from '../../../types.js';
|
|
4
|
+
import type { MeasureItemJSON } from '../../types.js';
|
|
4
5
|
/** Runtime StyledMeasureColumn: wrapper with column and optional style (from chart dataOptions) */
|
|
5
6
|
type StyledMeasureColumn = {
|
|
6
7
|
column: Measure;
|
|
@@ -15,8 +16,8 @@ type StyledMeasureColumn = {
|
|
|
15
16
|
* otherwise outputs the parsed FunctionCall.
|
|
16
17
|
*
|
|
17
18
|
* @param measures - Array of CSDK Measure or StyledMeasureColumn objects
|
|
18
|
-
* @returns NlqTranslationResult
|
|
19
|
+
* @returns NlqTranslationResult with measure items in NLQ JSON format
|
|
19
20
|
* @internal
|
|
20
21
|
*/
|
|
21
|
-
export declare function translateMeasuresToJSON(measures: (Measure | StyledMeasureColumn)[]): NlqTranslationResult<
|
|
22
|
+
export declare function translateMeasuresToJSON(measures: (Measure | StyledMeasureColumn)[]): NlqTranslationResult<MeasureItemJSON[]>;
|
|
22
23
|
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { DashboardProps } from '../../../../domains/dashboarding/types.js';
|
|
2
|
+
import type { NlqTranslationResult } from '../../types.js';
|
|
3
|
+
import type { DashboardInput } from '../types.js';
|
|
4
|
+
/**
|
|
5
|
+
* Translates NLQ DashboardJSON format to CSDK DashboardProps.
|
|
6
|
+
* Direction: JSON → CSDK
|
|
7
|
+
*
|
|
8
|
+
* Translates each widget using `translateWidgetFromJSON` (which requires each widget JSON to
|
|
9
|
+
* have an `id`). Dashboard-level filters are translated using the shared filter translator.
|
|
10
|
+
*
|
|
11
|
+
* Translation fails if any widget or filter translation fails.
|
|
12
|
+
*
|
|
13
|
+
* @param input - DashboardInput containing dashboardJSON and data schema context
|
|
14
|
+
* @returns NlqTranslationResult with DashboardProps or errors
|
|
15
|
+
* @internal
|
|
16
|
+
*/
|
|
17
|
+
export declare const translateDashboardFromJSON: (input: DashboardInput) => NlqTranslationResult<DashboardProps>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { DashboardProps } from '../../../../domains/dashboarding/types.js';
|
|
2
|
+
import type { NlqTranslationResult } from '../../types.js';
|
|
3
|
+
import type { DashboardJSON } from '../types.js';
|
|
4
|
+
/**
|
|
5
|
+
* Translates CSDK DashboardProps to NLQ DashboardJSON format.
|
|
6
|
+
* Direction: CSDK → JSON
|
|
7
|
+
*
|
|
8
|
+
* Translates each widget using `translateWidgetToJSON` and dashboard-level filters using
|
|
9
|
+
* the shared filter translator. Translation fails if any widget or filter translation fails.
|
|
10
|
+
*
|
|
11
|
+
* @param dashboardProps - Dashboard props to serialize
|
|
12
|
+
* @returns NlqTranslationResult with DashboardJSON or errors
|
|
13
|
+
* @internal
|
|
14
|
+
*/
|
|
15
|
+
export declare const translateDashboardToJSON: (dashboardProps: DashboardProps) => NlqTranslationResult<DashboardJSON>;
|