@sisense/sdk-ui 2.28.0 → 2.30.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 +57 -57
- package/dist/ai.js +767 -797
- package/dist/analytics-composer/node.cjs +1 -1
- package/dist/analytics-composer/node.js +1310 -1230
- package/dist/analytics-composer.cjs +7 -7
- package/dist/analytics-composer.js +19 -18
- package/dist/apply-styled-options-to-query-BK1NnV4P.js +6453 -0
- package/dist/apply-styled-options-to-query-Dl8vVNxo.cjs +1 -0
- package/dist/{index-C77YCBVd.js → index-DCYw3JUB.js} +29 -7
- package/dist/index-DTvxJdqZ.cjs +1 -0
- package/dist/index.cjs +611 -518
- package/dist/index.js +26556 -24829
- package/dist/index.umd.js +952 -829
- package/dist/packages/sdk-ui/src/domains/dashboarding/common-filters/utils.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/dashboarding/components/dashboard-container.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/dashboarding/components/dashboard-header-config.d.ts +127 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/components/dashboard-header-targets.d.ts +30 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/components/dashboard-header-title.d.ts +20 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/components/dashboard-header.d.ts +10 -1
- package/dist/packages/sdk-ui/src/domains/dashboarding/constants.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-helpers.d.ts +21 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/get-dashboard-model.d.ts +7 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/translate-dashboard-utils.d.ts +45 -3
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/use-dashboard-model/dashboard-model-reducer/persist-dashboard-model-middleware.d.ts +10 -1
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/use-dashboard-model/dashboard-model-reducer/types.d.ts +36 -1
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-model/use-dashboard-model/dashboard-model-reducer/utils.d.ts +2 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-module/dashboard-module.d.ts +34 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/dashboard-module/types.d.ts +58 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/hooks/duplicate-widget/use-duplicate-widget-menu-item.d.ts +7 -0
- package/dist/packages/sdk-ui/src/domains/dashboarding/hooks/use-dashboard-header-menu-item.d.ts +9 -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 +26 -1
- 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 +18 -7
- package/dist/packages/sdk-ui/src/domains/dashboarding/utils.d.ts +9 -0
- package/dist/packages/sdk-ui/src/domains/data-browser/add-measure-popover/add-measure-data-browser.d.ts +11 -0
- package/dist/packages/sdk-ui/src/domains/data-browser/add-measure-popover/add-measure-popover.d.ts +14 -0
- package/dist/packages/sdk-ui/src/domains/data-browser/add-measure-popover/measure-ranking-title.d.ts +21 -0
- package/dist/packages/sdk-ui/src/domains/data-browser/add-measure-popover/measures.d.ts +13 -0
- package/dist/packages/sdk-ui/src/domains/filters/components/criteria-filter-tile/criteria-filter-menu.d.ts +2 -1
- package/dist/packages/sdk-ui/src/domains/filters/components/criteria-filter-tile/criteria-filter-operations.d.ts +1 -0
- package/dist/packages/sdk-ui/src/domains/filters/components/filter-editor-popover/filter-editor-context.d.ts +1 -0
- package/dist/packages/sdk-ui/src/domains/filters/components/filter-editor-popover/filter-editor-popover.d.ts +2 -1
- package/dist/packages/sdk-ui/src/domains/filters/components/filter-editor-popover/filter-editor.d.ts +2 -1
- package/dist/packages/sdk-ui/src/domains/filters/components/filter-editor-popover/sections/numeric-condition-section/types.d.ts +5 -0
- package/dist/packages/sdk-ui/src/domains/filters/components/filter-editor-popover/sections/ranking-condition/index.d.ts +3 -0
- package/dist/packages/sdk-ui/src/domains/filters/components/filter-editor-popover/sections/ranking-condition/ranking-condition-controls.d.ts +33 -0
- package/dist/packages/sdk-ui/src/domains/filters/components/filter-editor-popover/sections/ranking-condition/ranking-condition-utils.d.ts +13 -0
- package/dist/packages/sdk-ui/src/domains/filters/components/filters-panel/hooks/use-existing-filter-editing.d.ts +2 -1
- package/dist/packages/sdk-ui/src/domains/narrative/components/narrative-collapsible.d.ts +22 -4
- package/dist/packages/sdk-ui/src/domains/narrative/components/narrative-top-slot-shell.d.ts +2 -0
- package/dist/packages/sdk-ui/src/domains/narrative/components/narrative-trigger-button.d.ts +17 -0
- package/dist/packages/sdk-ui/src/domains/narrative/components/widget-narrative-interactive.d.ts +20 -2
- package/dist/packages/sdk-ui/src/domains/narrative/components/widget-narrative.d.ts +11 -9
- package/dist/packages/sdk-ui/src/domains/narrative/core/build-narrative-request.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/narrative/core/get-narrative-dimensions-and-measures.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/narrative/core/get-widget-narrative-from-widget-props.d.ts +18 -0
- package/dist/packages/sdk-ui/src/domains/narrative/core/to-nlg-api-verbosity.d.ts +7 -0
- package/dist/packages/sdk-ui/src/domains/narrative/core/widget-narrative-options.d.ts +101 -23
- package/dist/packages/sdk-ui/src/domains/narrative/core/widget-props-to-narrative-params.d.ts +35 -32
- package/dist/packages/sdk-ui/src/domains/narrative/hooks/use-get-widget-narrative.d.ts +11 -22
- package/dist/packages/sdk-ui/src/domains/narrative/hooks/use-line-height.d.ts +10 -0
- package/dist/packages/sdk-ui/src/domains/narrative/hooks/use-widget-narrative-state.d.ts +8 -9
- package/dist/packages/sdk-ui/src/domains/query-execution/core/execute-query.d.ts +34 -1
- package/dist/packages/sdk-ui/src/domains/query-execution/hooks/use-execute-excel-query/excel-export/build-jaql-excel-export.d.ts +13 -5
- package/dist/packages/sdk-ui/src/domains/query-execution/hooks/use-execute-excel-query/excel-export/build-xlsx-export-payload.d.ts +5 -0
- package/dist/packages/sdk-ui/src/domains/query-execution/hooks/use-execute-query-by-widget-id/use-execute-query-by-widget-id.d.ts +2 -1
- package/dist/packages/sdk-ui/src/domains/query-execution/types.d.ts +55 -3
- package/dist/packages/sdk-ui/src/domains/shared/header/header-item-size.d.ts +30 -0
- package/dist/packages/sdk-ui/src/domains/shared/header/header-items-renderer.d.ts +19 -0
- package/dist/packages/sdk-ui/src/domains/shared/header/header-spacer-item.d.ts +9 -0
- package/dist/packages/sdk-ui/src/domains/shared/header/index.d.ts +6 -0
- package/dist/packages/sdk-ui/src/domains/shared/header/resolve-header-items.d.ts +17 -0
- package/dist/packages/sdk-ui/src/domains/shared/header/types.d.ts +98 -0
- package/dist/packages/sdk-ui/src/domains/shared/header/use-resolved-header-items.d.ts +10 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/areamap-chart/data/areamap-data.d.ts +3 -1
- 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/cartesians/helpers/data.d.ts +3 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/cartesians/stackable/streamgraph-chart/helpers/chart-data.d.ts +3 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/categoricals/helpers/data.d.ts +3 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/categoricals/sunburst-chart/data/index.d.ts +3 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/categoricals/treemap-chart/data/index.d.ts +3 -1
- 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 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/alerts/index.d.ts +5 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/data/index.d.ts +22 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/data-options/index.d.ts +33 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/design-options/index.d.ts +21 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/highchart-options/highcharts-options-builder.d.ts +3 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/sankey-chart-builder.d.ts +3 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/sankey-node-colors.d.ts +10 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/types.d.ts +38 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/types.d.ts +2 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/types.d.ts +12 -9
- package/dist/packages/sdk-ui/src/domains/visualizations/components/pivot-table/formatters/data-cell-formatters/data-cell-value-formatter.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/components/pivot-table/formatters/header-cell-formatters/header-cell-value-formatter.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/components/pivot-table/hooks/use-pivot-data-loading.d.ts +1 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/pivot-table/resolve-pivot-container-size.d.ts +28 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/sankey-chart.d.ts +30 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/components/table/pure-table/helpers/format-numbers.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data/cartesian-data.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data/categorical-data.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data/chart-data-service.d.ts +1 -1
- 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/scatter-data.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data/types.d.ts +2 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data-options/apply-styled-options-to-query.d.ts +4 -4
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data-options/types.d.ts +74 -30
- 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/chart-options-service.d.ts +3 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/tooltip.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/design-options.d.ts +10 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/funnel-plot-options.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/number-format-config.d.ts +12 -0
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/pie-plot-options.d.ts +2 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/sunburst/sunburst-levels.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/sunburst/sunburst-options.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/treemap/treemap-tooltip.d.ts +2 -2
- package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/types.d.ts +12 -3
- 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 +8 -1
- package/dist/packages/sdk-ui/src/domains/widgets/components/chart-widget/use-chart-widget-excel-download.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/widgets/components/chart-widget/use-chart-widget-narrative.d.ts +28 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/custom-widget/types.d.ts +11 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/custom-widget/use-custom-widget-excel-download.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/widgets/components/pivot-table-widget/pivot-table-widget.d.ts +15 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/pivot-table-widget/types.d.ts +7 -1
- package/dist/packages/sdk-ui/src/domains/widgets/components/pivot-table-widget/use-pivot-widget-excel-download.d.ts +1 -1
- package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-widget-style-options/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-widget-style-options/tabber.d.ts +17 -1
- package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-widget-style-options/to-widget-dto-style.d.ts +41 -2
- package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-widget-style-options/widget-narrative-style.d.ts +31 -0
- package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/types.d.ts +36 -1
- package/dist/packages/sdk-ui/src/domains/widgets/helpers/excel-export-map-dimensions-measures.d.ts +17 -2
- package/dist/packages/sdk-ui/src/domains/widgets/helpers/number-format-config-to-numeric-mask.d.ts +5 -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/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-container/widget-container.d.ts +7 -1
- package/dist/packages/sdk-ui/src/domains/widgets/shared/widget-style-utils.d.ts +29 -0
- 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.d.ts +6 -1
- package/dist/packages/sdk-ui/src/infra/api/narrative/narrative-endpoints.d.ts +2 -2
- package/dist/packages/sdk-ui/src/infra/api/rest-api.d.ts +2 -1
- package/dist/packages/sdk-ui/src/infra/app/settings/settings.d.ts +1 -7
- 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 +32 -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/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/types.d.ts +34 -6
- package/dist/packages/sdk-ui/src/infra/plugins/widget-plugins/types.d.ts +219 -49
- package/dist/packages/sdk-ui/src/infra/plugins/widget-plugins/widget-plugin-registry.d.ts +3 -3
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/de-de.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/en-us.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/es-ar.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/es-es.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/fr-fr.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/it-it.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/ja-jp.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/ko-kr.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/nl-nl.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/pt-br.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/ru-ru.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/tr-tr.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/zh-cn.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/en.d.ts +22 -0
- package/dist/packages/sdk-ui/src/infra/translation/resources/index.d.ts +44 -0
- package/dist/packages/sdk-ui/src/modules/ai/common/collapsible.d.ts +38 -2
- package/dist/packages/sdk-ui/src/modules/ai/get-nlg-insights-from-widget.d.ts +4 -13
- package/dist/packages/sdk-ui/src/modules/ai/index.d.ts +1 -1
- 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/index.d.ts +3 -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 -2
- 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/process-measured-value.d.ts +14 -0
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/types.d.ts +70 -9
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/helpers/to-widget-props.d.ts +3 -3
- package/dist/packages/sdk-ui/src/modules/analytics-composer/nlq-v3-translator/widget/helpers/translate-envelope-widget-from-json.d.ts +2 -3
- package/dist/packages/sdk-ui/src/modules/analytics-composer/types.d.ts +1 -18
- package/dist/packages/sdk-ui/src/props.d.ts +55 -2
- package/dist/packages/sdk-ui/src/public-api/alpha.d.ts +6 -1
- package/dist/packages/sdk-ui/src/public-api/beta.d.ts +6 -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 +3 -1
- package/dist/packages/sdk-ui/src/public-api/sisense-internal.d.ts +5 -3
- 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 +78 -6
- package/dist/{use-hover-B6VmMb06.js → quota-notification-DqabeDbO.js} +24790 -22993
- package/dist/quota-notification-gYE6PTWA.cjs +750 -0
- package/dist/translations/de-de.cjs +1 -1
- package/dist/translations/de-de.js +27 -5
- 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 +27 -5
- package/dist/translations/es-es.cjs +1 -1
- package/dist/translations/es-es.js +27 -5
- package/dist/translations/fr-fr.cjs +1 -1
- package/dist/translations/fr-fr.js +27 -5
- package/dist/translations/it-it.cjs +1 -1
- package/dist/translations/it-it.js +29 -7
- package/dist/translations/ja-jp.cjs +1 -1
- package/dist/translations/ja-jp.js +27 -5
- package/dist/translations/ko-kr.cjs +1 -1
- package/dist/translations/ko-kr.js +27 -5
- package/dist/translations/nl-nl.cjs +1 -1
- package/dist/translations/nl-nl.js +29 -7
- package/dist/translations/pt-br.cjs +1 -1
- package/dist/translations/pt-br.js +27 -5
- package/dist/translations/ru-ru.cjs +1 -1
- package/dist/translations/ru-ru.js +27 -5
- package/dist/translations/tr-tr.cjs +1 -1
- package/dist/translations/tr-tr.js +27 -5
- package/dist/translations/zh-cn.cjs +1 -1
- package/dist/translations/zh-cn.js +27 -5
- package/dist/{types-CzgBH2kL.cjs → types-DSNnndG6.cjs} +1 -1
- package/dist/types-DecTaxy7.js +74 -0
- package/dist/{utils-BwGnDoB0.cjs → utils-Cpeyj9TN.cjs} +52 -52
- package/dist/{utils-CsV-iYtb.js → utils-L-HO2pCd.js} +2521 -2469
- package/dist/{widget-composer-C72Io-3c.cjs → widget-composer-CyWQaInf.cjs} +1 -1
- package/dist/{widget-composer-Bv_OVu1o.js → widget-composer-u6NMLm1C.js} +3 -3
- package/package.json +9 -8
- package/dist/apply-styled-options-to-query-23D9br-S.cjs +0 -1
- package/dist/apply-styled-options-to-query-BagjzMqm.js +0 -5992
- package/dist/dimensions-Bn1EaWiP.js +0 -204
- package/dist/dimensions-D8r34WRI.cjs +0 -1
- package/dist/index-C9G8giSk.cjs +0 -1
- package/dist/packages/sdk-ui/src/domains/dashboarding/hooks/use-dashboard-header-toolbar.d.ts +0 -25
- 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-D3fPN43o.js +0 -74
- package/dist/use-hover-CaSOzp0i.cjs +0 -720
|
@@ -1,14 +1,38 @@
|
|
|
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';
|
|
6
7
|
/**
|
|
7
|
-
*
|
|
8
|
+
* Declares a widget plugin for registration with the Compose SDK.
|
|
8
9
|
*
|
|
9
|
-
* @
|
|
10
|
+
* Pass an instance to the `plugins` prop on {@link SisenseContextProvider} to register a custom
|
|
11
|
+
* visualization that appears in the dashboard widget picker.
|
|
12
|
+
*
|
|
13
|
+
* @typeParam Props - Props type for the custom visualization component, extending {@link CustomVisualizationProps}.
|
|
14
|
+
* @group Plugin System
|
|
15
|
+
* @example
|
|
16
|
+
* ```tsx
|
|
17
|
+
* import { WidgetPlugin, CustomVisualization } from '@sisense/sdk-ui';
|
|
18
|
+
*
|
|
19
|
+
* const MyChart: CustomVisualization = ({ dataOptions }) => <div>{String(dataOptions)}</div>;
|
|
20
|
+
*
|
|
21
|
+
* const myPlugin: WidgetPlugin = {
|
|
22
|
+
* name: 'my-widget-plugin',
|
|
23
|
+
* version: '1.0.0',
|
|
24
|
+
* requiredApiVersion: '^2.9.0',
|
|
25
|
+
* pluginType: 'widget',
|
|
26
|
+
* customWidget: {
|
|
27
|
+
* name: 'my-widget',
|
|
28
|
+
* displayName: 'My Widget',
|
|
29
|
+
* visualization: { Component: MyChart },
|
|
30
|
+
* },
|
|
31
|
+
* };
|
|
32
|
+
* ```
|
|
33
|
+
* @beta
|
|
10
34
|
*/
|
|
11
|
-
export interface WidgetPlugin<Props extends CustomVisualizationProps = CustomVisualizationProps> extends BasePluginInfo {
|
|
35
|
+
export interface WidgetPlugin<Props extends CustomVisualizationProps<any, any, any, any> = CustomVisualizationProps> extends BasePluginInfo {
|
|
12
36
|
/**
|
|
13
37
|
* The type of plugin
|
|
14
38
|
*/
|
|
@@ -146,40 +170,46 @@ export interface WidgetPlugin<Props extends CustomVisualizationProps = CustomVis
|
|
|
146
170
|
*/
|
|
147
171
|
export type AnyWidgetPlugin = WidgetPlugin<any>;
|
|
148
172
|
/**
|
|
149
|
-
*
|
|
150
|
-
*
|
|
151
|
-
* @typeParam DataOptions - The shape of data options for this custom visualization
|
|
152
|
-
* @typeParam StyleOptions - The shape of style options for this custom visualization
|
|
153
|
-
* @typeParam DataPoint - The shape of data points for event handlers
|
|
173
|
+
* Defines props passed to a user-defined custom visualization component.
|
|
154
174
|
*
|
|
175
|
+
* @typeParam DataOptions - The shape of data options for this custom visualization.
|
|
176
|
+
* @typeParam StyleOptions - The shape of style options for this custom visualization.
|
|
177
|
+
* @typeParam DataPoint - The shape of data points passed to event handlers.
|
|
178
|
+
* @typeParam CustomOptions - The shape of arbitrary plugin-specific state (not data- or style-related).
|
|
179
|
+
* @group Plugin System
|
|
155
180
|
* @example
|
|
156
181
|
* ```tsx
|
|
157
|
-
* import {
|
|
182
|
+
* import {
|
|
183
|
+
* CustomVisualization,
|
|
184
|
+
* CustomVisualizationProps,
|
|
185
|
+
* CustomVisualizationDataPoint,
|
|
186
|
+
* StyledColumn,
|
|
187
|
+
* StyledMeasureColumn,
|
|
188
|
+
* DataPointEntry,
|
|
189
|
+
* GenericDataOptions,
|
|
190
|
+
* } from '@sisense/sdk-ui';
|
|
158
191
|
*
|
|
159
192
|
* interface MyDataOptions extends GenericDataOptions {
|
|
160
193
|
* category: StyledColumn[];
|
|
161
194
|
* value: StyledMeasureColumn[];
|
|
162
195
|
* }
|
|
163
196
|
*
|
|
164
|
-
* interface MyDataPoint extends
|
|
197
|
+
* interface MyDataPoint extends CustomVisualizationDataPoint {
|
|
165
198
|
* entries: {
|
|
166
199
|
* category: DataPointEntry[];
|
|
167
200
|
* value: DataPointEntry[];
|
|
168
201
|
* };
|
|
169
202
|
* }
|
|
170
203
|
*
|
|
171
|
-
* type
|
|
204
|
+
* type MyChartProps = CustomVisualizationProps<MyDataOptions, {}, MyDataPoint>;
|
|
172
205
|
*
|
|
173
|
-
* const
|
|
174
|
-
*
|
|
175
|
-
* // ... implementation based on props
|
|
176
|
-
* return <div>My New Awesome Chart</div>;
|
|
206
|
+
* const MyChart: CustomVisualization<MyChartProps> = ({ dataOptions, onDataPointClick }) => {
|
|
207
|
+
* return <div>My Chart</div>;
|
|
177
208
|
* };
|
|
178
209
|
* ```
|
|
179
|
-
*
|
|
180
|
-
* @sisenseInternal
|
|
210
|
+
* @beta
|
|
181
211
|
*/
|
|
182
|
-
export interface CustomVisualizationProps<DataOptions = GenericDataOptions, StyleOptions = CustomVisualizationStyleOptions, DataPoint extends AbstractDataPointWithEntries = AbstractDataPointWithEntries
|
|
212
|
+
export interface CustomVisualizationProps<DataOptions = GenericDataOptions, StyleOptions = CustomVisualizationStyleOptions, DataPoint extends AbstractDataPointWithEntries = AbstractDataPointWithEntries, CustomOptions = Record<string, unknown>> extends CustomVisualizationEventProps<DataPoint> {
|
|
183
213
|
/** Data source for the custom visualization */
|
|
184
214
|
dataSource?: DataSource;
|
|
185
215
|
/** Data options defining what data to display */
|
|
@@ -190,28 +220,107 @@ export interface CustomVisualizationProps<DataOptions = GenericDataOptions, Styl
|
|
|
190
220
|
filters?: Filter[] | FilterRelations;
|
|
191
221
|
/** Highlight filters for interactive highlighting */
|
|
192
222
|
highlights?: Filter[];
|
|
223
|
+
/**
|
|
224
|
+
* Arbitrary plugin-specific options that is not data- or style-related.
|
|
225
|
+
*
|
|
226
|
+
* @sisenseInternal
|
|
227
|
+
*/
|
|
228
|
+
customOptions?: CustomOptions;
|
|
229
|
+
/**
|
|
230
|
+
* Emit a partial state update to be persisted through the dashboard
|
|
231
|
+
* persistence layer. Injected by the dashboard when the widget lives inside a
|
|
232
|
+
* Dashboard component; `undefined` in standalone use or read-only mode — always
|
|
233
|
+
* call it with optional chaining.
|
|
234
|
+
*
|
|
235
|
+
* @example
|
|
236
|
+
* ```tsx
|
|
237
|
+
* onChange?.({ customOptions: { lastPage: 3 } });
|
|
238
|
+
* ```
|
|
239
|
+
*
|
|
240
|
+
* @sisenseInternal
|
|
241
|
+
*/
|
|
242
|
+
onChange?: (update: VisualizationStateUpdate<StyleOptions, CustomOptions>) => void;
|
|
193
243
|
}
|
|
194
244
|
/**
|
|
195
|
-
*
|
|
245
|
+
* Partial persistable state a custom visualization can push back to the
|
|
246
|
+
* persistence layer. Carries the same props vocabulary the plugin already reads
|
|
247
|
+
* from.
|
|
248
|
+
*
|
|
249
|
+
* Both fields are deeply partial and are deep-merged into the current widget
|
|
250
|
+
* state: nested plain objects merge recursively at any depth, so a plugin
|
|
251
|
+
* passes only the leaf values that changed — e.g.
|
|
252
|
+
* `{ styleOptions: { pagination: { currentPage: 3 } } }` updates `currentPage`
|
|
253
|
+
* while preserving the sibling `pagination` keys. Arrays and primitives are
|
|
254
|
+
* replaced wholesale (last-write-wins). Keys cannot be deleted via merge —
|
|
255
|
+
* overwrite with an explicit value (e.g. `null`) instead.
|
|
196
256
|
*
|
|
197
257
|
* @sisenseInternal
|
|
198
258
|
*/
|
|
259
|
+
export type VisualizationStateUpdate<StyleOptions = CustomVisualizationStyleOptions, CustomOptions = Record<string, unknown>> = {
|
|
260
|
+
styleOptions?: DeepPartial<StyleOptions>;
|
|
261
|
+
customOptions?: DeepPartial<CustomOptions>;
|
|
262
|
+
};
|
|
263
|
+
/**
|
|
264
|
+
* Defines style options for a custom visualization.
|
|
265
|
+
*
|
|
266
|
+
* Extend this interface to add plugin-specific style properties passed via `styleOptions`.
|
|
267
|
+
*
|
|
268
|
+
* @group Plugin System
|
|
269
|
+
* @example
|
|
270
|
+
* ```ts
|
|
271
|
+
* interface MyWidgetStyleOptions extends CustomVisualizationStyleOptions {
|
|
272
|
+
* backgroundColor?: string;
|
|
273
|
+
* fontSize?: number;
|
|
274
|
+
* }
|
|
275
|
+
* ```
|
|
276
|
+
* @beta
|
|
277
|
+
*/
|
|
199
278
|
export interface CustomVisualizationStyleOptions extends AnyObject {
|
|
200
279
|
}
|
|
201
280
|
/**
|
|
202
|
-
*
|
|
203
|
-
*
|
|
281
|
+
* Defines a user-defined custom visualization component.
|
|
282
|
+
* Can be any visual representation of data — chart, table, map, etc.
|
|
204
283
|
*
|
|
205
|
-
* @typeParam Props - The props type for the custom visualization component
|
|
206
|
-
* @
|
|
284
|
+
* @typeParam Props - The props type for the custom visualization component, extending {@link CustomVisualizationProps}.
|
|
285
|
+
* @param props - Props injected by the dashboard, including `dataOptions`, `styleOptions`, `filters`, and event handlers.
|
|
286
|
+
* @returns A React node representing the rendered visualization.
|
|
287
|
+
* @group Plugin System
|
|
288
|
+
* @example
|
|
289
|
+
* ```tsx
|
|
290
|
+
* import { CustomVisualization, CustomVisualizationProps } from '@sisense/sdk-ui';
|
|
291
|
+
*
|
|
292
|
+
* const MyChart: CustomVisualization<CustomVisualizationProps> = ({ dataOptions, styleOptions }) => {
|
|
293
|
+
* return <div className="my-chart">{JSON.stringify(dataOptions)}</div>;
|
|
294
|
+
* };
|
|
295
|
+
* ```
|
|
296
|
+
* @beta
|
|
207
297
|
*/
|
|
208
298
|
export type CustomVisualization<Props = CustomVisualizationProps> = (props: Props) => ReactNode;
|
|
209
299
|
/**
|
|
210
|
-
*
|
|
300
|
+
* A custom visualization with erased prop types, used for heterogeneous storage
|
|
301
|
+
* at registry/context boundaries. Each concrete visualization specializes
|
|
302
|
+
* {@link CustomVisualizationProps} differently (and may require extra props such
|
|
303
|
+
* as a widget `id`), so the registry cannot know each exact shape — the prop
|
|
304
|
+
* type is intentionally erased here. Do not consume prop types from this alias.
|
|
211
305
|
*
|
|
212
|
-
* @typeParam DataPoint - The shape of data points for this custom visualization
|
|
213
306
|
* @sisenseInternal
|
|
214
307
|
*/
|
|
308
|
+
export type AnyCustomVisualization = CustomVisualization<any>;
|
|
309
|
+
/**
|
|
310
|
+
* Defines event handler props for a custom visualization component.
|
|
311
|
+
*
|
|
312
|
+
* Included automatically via {@link CustomVisualizationProps}. Extend to add custom event props.
|
|
313
|
+
*
|
|
314
|
+
* @typeParam DataPoint - The shape of data points for this custom visualization.
|
|
315
|
+
* @group Plugin System
|
|
316
|
+
* @example
|
|
317
|
+
* ```tsx
|
|
318
|
+
* interface MyEventProps extends CustomVisualizationEventProps<MyDataPoint> {
|
|
319
|
+
* onCustomAction?: (id: string) => void;
|
|
320
|
+
* }
|
|
321
|
+
* ```
|
|
322
|
+
* @beta
|
|
323
|
+
*/
|
|
215
324
|
export interface CustomVisualizationEventProps<DataPoint extends AbstractDataPointWithEntries = AbstractDataPointWithEntries> {
|
|
216
325
|
/**
|
|
217
326
|
* Click handler callback for a data point
|
|
@@ -233,28 +342,35 @@ export interface CustomVisualizationEventProps<DataPoint extends AbstractDataPoi
|
|
|
233
342
|
onDataPointsSelected?: CustomVisualizationDataPointsEventHandler<DataPoint>;
|
|
234
343
|
}
|
|
235
344
|
/**
|
|
236
|
-
*
|
|
345
|
+
* Defines an event handler for a data point click in a custom visualization.
|
|
237
346
|
*
|
|
238
|
-
* @typeParam T - The shape of the data point
|
|
347
|
+
* @typeParam T - The shape of the data point.
|
|
348
|
+
* @group Plugin System
|
|
239
349
|
* @example
|
|
240
350
|
* ```tsx
|
|
241
351
|
* const handleClick: CustomVisualizationDataPointEventHandler<MyChartDataPoint> = (point, event) => {
|
|
242
|
-
* console.log('Clicked:', point.
|
|
352
|
+
* console.log('Clicked:', point.entries.category[0].value);
|
|
243
353
|
* };
|
|
244
354
|
* ```
|
|
245
|
-
*
|
|
246
|
-
* @sisenseInternal
|
|
355
|
+
* @beta
|
|
247
356
|
*/
|
|
248
|
-
export type CustomVisualizationDataPointEventHandler<T extends AbstractDataPointWithEntries = AbstractDataPointWithEntries> = (
|
|
357
|
+
export type CustomVisualizationDataPointEventHandler<T extends AbstractDataPointWithEntries = AbstractDataPointWithEntries> = (
|
|
358
|
+
/** Data point that was clicked. */
|
|
359
|
+
point: CustomVisualizationDataPoint<T>,
|
|
360
|
+
/** Native browser pointer or mouse event. */
|
|
361
|
+
nativeEvent: PointerEvent | MouseEvent) => void;
|
|
249
362
|
/**
|
|
250
363
|
* Represents a single data point in a custom visualization.
|
|
251
364
|
*
|
|
252
|
-
*
|
|
253
|
-
*
|
|
254
|
-
* specific entries for categories, values, or other dimensions used in the widget.
|
|
365
|
+
* Extend `AbstractDataPointWithEntries` to define typed entries for your widget's data options.
|
|
366
|
+
* Instances are passed to event handlers such as `onDataPointClick`.
|
|
255
367
|
*
|
|
368
|
+
* @typeParam T - The concrete data point shape, extending {@link AbstractDataPointWithEntries}.
|
|
369
|
+
* @group Plugin System
|
|
256
370
|
* @example
|
|
257
|
-
* ```
|
|
371
|
+
* ```ts
|
|
372
|
+
* import { CustomVisualizationDataPoint, DataPointEntry } from '@sisense/sdk-ui';
|
|
373
|
+
*
|
|
258
374
|
* interface MyChartDataPoint extends CustomVisualizationDataPoint {
|
|
259
375
|
* entries: {
|
|
260
376
|
* category: DataPointEntry[];
|
|
@@ -266,15 +382,25 @@ export type CustomVisualizationDataPointEventHandler<T extends AbstractDataPoint
|
|
|
266
382
|
* console.log('Clicked category:', point.entries.category[0].value);
|
|
267
383
|
* };
|
|
268
384
|
* ```
|
|
269
|
-
*
|
|
270
|
-
* @sisenseInternal
|
|
385
|
+
* @beta
|
|
271
386
|
*/
|
|
272
387
|
export type CustomVisualizationDataPoint<T extends AbstractDataPointWithEntries = AbstractDataPointWithEntries> = T;
|
|
273
388
|
/**
|
|
274
|
-
*
|
|
389
|
+
* Defines an event handler for a data point context-menu event in a custom visualization.
|
|
275
390
|
*
|
|
276
|
-
* @typeParam T - The shape of the data point
|
|
277
|
-
* @
|
|
391
|
+
* @typeParam T - The shape of the data point.
|
|
392
|
+
* @group Plugin System
|
|
393
|
+
* @example
|
|
394
|
+
* ```tsx
|
|
395
|
+
* const handleContextMenu: CustomVisualizationDataPointContextMenuHandler<MyChartDataPoint> = (
|
|
396
|
+
* point,
|
|
397
|
+
* event,
|
|
398
|
+
* ) => {
|
|
399
|
+
* event.preventDefault();
|
|
400
|
+
* showContextMenu({ x: event.clientX, y: event.clientY, point });
|
|
401
|
+
* };
|
|
402
|
+
* ```
|
|
403
|
+
* @beta
|
|
278
404
|
*/
|
|
279
405
|
export type CustomVisualizationDataPointContextMenuHandler<T extends AbstractDataPointWithEntries = AbstractDataPointWithEntries> = (
|
|
280
406
|
/** Data point that triggered the context menu */
|
|
@@ -282,17 +408,20 @@ point: CustomVisualizationDataPoint<T>,
|
|
|
282
408
|
/** Native browser event */
|
|
283
409
|
nativeEvent: MouseEvent) => void;
|
|
284
410
|
/**
|
|
285
|
-
*
|
|
411
|
+
* Defines an event handler for multi-point selection in a custom visualization.
|
|
286
412
|
*
|
|
287
|
-
* @typeParam T - The shape of the data point
|
|
413
|
+
* @typeParam T - The shape of the data point.
|
|
414
|
+
* @group Plugin System
|
|
288
415
|
* @example
|
|
289
416
|
* ```tsx
|
|
290
|
-
* const handleSelect: CustomVisualizationDataPointsEventHandler<MyChartDataPoint> = (
|
|
417
|
+
* const handleSelect: CustomVisualizationDataPointsEventHandler<MyChartDataPoint> = (
|
|
418
|
+
* points,
|
|
419
|
+
* event,
|
|
420
|
+
* ) => {
|
|
291
421
|
* console.log('Selected:', points.length, 'points');
|
|
292
422
|
* };
|
|
293
423
|
* ```
|
|
294
|
-
*
|
|
295
|
-
* @sisenseInternal
|
|
424
|
+
* @beta
|
|
296
425
|
*/
|
|
297
426
|
export type CustomVisualizationDataPointsEventHandler<T extends AbstractDataPointWithEntries = AbstractDataPointWithEntries> = (
|
|
298
427
|
/** Data points that were selected */
|
|
@@ -300,17 +429,58 @@ points: CustomVisualizationDataPoint<T>[],
|
|
|
300
429
|
/** Native browser event */
|
|
301
430
|
nativeEvent: MouseEvent) => void;
|
|
302
431
|
/**
|
|
303
|
-
*
|
|
432
|
+
* Defines props passed to a custom design panel component.
|
|
304
433
|
*
|
|
305
|
-
* @
|
|
434
|
+
* @typeParam StyleOptions - The shape of style options managed by this design panel, extending {@link CustomVisualizationStyleOptions}.
|
|
435
|
+
* @group Plugin System
|
|
436
|
+
* @example
|
|
437
|
+
* ```tsx
|
|
438
|
+
* import { DesignPanel, DesignPanelProps } from '@sisense/sdk-ui';
|
|
439
|
+
*
|
|
440
|
+
* interface MyStyleOptions extends CustomVisualizationStyleOptions {
|
|
441
|
+
* color?: string;
|
|
442
|
+
* }
|
|
443
|
+
*
|
|
444
|
+
* const MyDesignPanel: DesignPanel<MyStyleOptions> = ({ styleOptions, onChange }) => (
|
|
445
|
+
* <input
|
|
446
|
+
* type="color"
|
|
447
|
+
* value={styleOptions.color ?? '#000000'}
|
|
448
|
+
* onChange={(e) => onChange({ ...styleOptions, color: e.target.value })}
|
|
449
|
+
* />
|
|
450
|
+
* );
|
|
451
|
+
* ```
|
|
452
|
+
* @beta
|
|
306
453
|
*/
|
|
307
454
|
export interface DesignPanelProps<StyleOptions = CustomVisualizationStyleOptions> {
|
|
455
|
+
/** Current style options managed by the design panel. */
|
|
308
456
|
styleOptions: StyleOptions;
|
|
457
|
+
/** Callback invoked when the user changes a style option. */
|
|
309
458
|
onChange: (styleOptions: StyleOptions) => void;
|
|
310
459
|
}
|
|
311
460
|
/**
|
|
312
|
-
*
|
|
461
|
+
* Defines a design panel component for a custom widget.
|
|
313
462
|
*
|
|
314
|
-
*
|
|
463
|
+
* Renders inside the widget's style/design settings pane and receives the current
|
|
464
|
+
* `styleOptions` and an `onChange` callback to persist style changes.
|
|
465
|
+
*
|
|
466
|
+
* @typeParam StyleOptions - The shape of style options managed by this design panel, extending {@link CustomVisualizationStyleOptions}.
|
|
467
|
+
* @group Plugin System
|
|
468
|
+
* @example
|
|
469
|
+
* ```tsx
|
|
470
|
+
* import { DesignPanel, CustomVisualizationStyleOptions } from '@sisense/sdk-ui';
|
|
471
|
+
*
|
|
472
|
+
* interface MyStyleOptions extends CustomVisualizationStyleOptions {
|
|
473
|
+
* color?: string;
|
|
474
|
+
* }
|
|
475
|
+
*
|
|
476
|
+
* const MyDesignPanel: DesignPanel<MyStyleOptions> = ({ styleOptions, onChange }) => (
|
|
477
|
+
* <input
|
|
478
|
+
* type="color"
|
|
479
|
+
* value={styleOptions.color ?? '#000000'}
|
|
480
|
+
* onChange={(e) => onChange({ ...styleOptions, color: e.target.value })}
|
|
481
|
+
* />
|
|
482
|
+
* );
|
|
483
|
+
* ```
|
|
484
|
+
* @beta
|
|
315
485
|
*/
|
|
316
486
|
export type DesignPanel<StyleOptions = CustomVisualizationStyleOptions> = FunctionComponent<DesignPanelProps<StyleOptions>>;
|
|
@@ -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.
|
|
@@ -256,6 +256,8 @@ declare const _default: {
|
|
|
256
256
|
yes: string;
|
|
257
257
|
no: string;
|
|
258
258
|
seeMore: string;
|
|
259
|
+
generateNarrative: string;
|
|
260
|
+
hideNarrative: string;
|
|
259
261
|
};
|
|
260
262
|
disclaimer: {
|
|
261
263
|
poweredByAi: string;
|
|
@@ -309,6 +311,8 @@ declare const _default: {
|
|
|
309
311
|
from: string;
|
|
310
312
|
to: string;
|
|
311
313
|
includeCurrent: string;
|
|
314
|
+
rankedBy: string;
|
|
315
|
+
selectField: string;
|
|
312
316
|
};
|
|
313
317
|
placeholders: {
|
|
314
318
|
selectFromList: string;
|
|
@@ -333,6 +337,8 @@ declare const _default: {
|
|
|
333
337
|
greaterThan: string;
|
|
334
338
|
greaterThanOrEqual: string;
|
|
335
339
|
isWithin: string;
|
|
340
|
+
top: string;
|
|
341
|
+
bottom: string;
|
|
336
342
|
};
|
|
337
343
|
validationErrors: {
|
|
338
344
|
invalidNumber: string;
|
|
@@ -427,6 +433,11 @@ declare const _default: {
|
|
|
427
433
|
table: {
|
|
428
434
|
label: string;
|
|
429
435
|
};
|
|
436
|
+
sankey: {
|
|
437
|
+
alerts: {
|
|
438
|
+
tooManyStages: string;
|
|
439
|
+
};
|
|
440
|
+
};
|
|
430
441
|
};
|
|
431
442
|
loadingOverlay: {
|
|
432
443
|
label: string;
|
|
@@ -452,6 +463,17 @@ declare const _default: {
|
|
|
452
463
|
median: string;
|
|
453
464
|
variance: string;
|
|
454
465
|
};
|
|
466
|
+
measuresAgg: {
|
|
467
|
+
countDistinct: string;
|
|
468
|
+
count: string;
|
|
469
|
+
sum: string;
|
|
470
|
+
average: string;
|
|
471
|
+
min: string;
|
|
472
|
+
max: string;
|
|
473
|
+
median: string;
|
|
474
|
+
variance: string;
|
|
475
|
+
stdev: string;
|
|
476
|
+
};
|
|
455
477
|
};
|
|
456
478
|
}[];
|
|
457
479
|
export default _default;
|
|
@@ -256,6 +256,8 @@ declare const _default: {
|
|
|
256
256
|
yes: string;
|
|
257
257
|
no: string;
|
|
258
258
|
seeMore: string;
|
|
259
|
+
generateNarrative: string;
|
|
260
|
+
hideNarrative: string;
|
|
259
261
|
};
|
|
260
262
|
disclaimer: {
|
|
261
263
|
poweredByAi: string;
|
|
@@ -309,6 +311,8 @@ declare const _default: {
|
|
|
309
311
|
from: string;
|
|
310
312
|
to: string;
|
|
311
313
|
includeCurrent: string;
|
|
314
|
+
rankedBy: string;
|
|
315
|
+
selectField: string;
|
|
312
316
|
};
|
|
313
317
|
placeholders: {
|
|
314
318
|
selectFromList: string;
|
|
@@ -333,6 +337,8 @@ declare const _default: {
|
|
|
333
337
|
greaterThan: string;
|
|
334
338
|
greaterThanOrEqual: string;
|
|
335
339
|
isWithin: string;
|
|
340
|
+
top: string;
|
|
341
|
+
bottom: string;
|
|
336
342
|
};
|
|
337
343
|
validationErrors: {
|
|
338
344
|
invalidNumber: string;
|
|
@@ -427,6 +433,11 @@ declare const _default: {
|
|
|
427
433
|
table: {
|
|
428
434
|
label: string;
|
|
429
435
|
};
|
|
436
|
+
sankey: {
|
|
437
|
+
alerts: {
|
|
438
|
+
tooManyStages: string;
|
|
439
|
+
};
|
|
440
|
+
};
|
|
430
441
|
};
|
|
431
442
|
loadingOverlay: {
|
|
432
443
|
label: string;
|
|
@@ -452,6 +463,17 @@ declare const _default: {
|
|
|
452
463
|
median: string;
|
|
453
464
|
variance: string;
|
|
454
465
|
};
|
|
466
|
+
measuresAgg: {
|
|
467
|
+
countDistinct: string;
|
|
468
|
+
count: string;
|
|
469
|
+
sum: string;
|
|
470
|
+
average: string;
|
|
471
|
+
min: string;
|
|
472
|
+
max: string;
|
|
473
|
+
median: string;
|
|
474
|
+
variance: string;
|
|
475
|
+
stdev: string;
|
|
476
|
+
};
|
|
455
477
|
};
|
|
456
478
|
}[];
|
|
457
479
|
export default _default;
|
|
@@ -256,6 +256,8 @@ declare const _default: {
|
|
|
256
256
|
yes: string;
|
|
257
257
|
no: string;
|
|
258
258
|
seeMore: string;
|
|
259
|
+
generateNarrative: string;
|
|
260
|
+
hideNarrative: string;
|
|
259
261
|
};
|
|
260
262
|
disclaimer: {
|
|
261
263
|
poweredByAi: string;
|
|
@@ -309,6 +311,8 @@ declare const _default: {
|
|
|
309
311
|
from: string;
|
|
310
312
|
to: string;
|
|
311
313
|
includeCurrent: string;
|
|
314
|
+
rankedBy: string;
|
|
315
|
+
selectField: string;
|
|
312
316
|
};
|
|
313
317
|
placeholders: {
|
|
314
318
|
selectFromList: string;
|
|
@@ -333,6 +337,8 @@ declare const _default: {
|
|
|
333
337
|
greaterThan: string;
|
|
334
338
|
greaterThanOrEqual: string;
|
|
335
339
|
isWithin: string;
|
|
340
|
+
top: string;
|
|
341
|
+
bottom: string;
|
|
336
342
|
};
|
|
337
343
|
validationErrors: {
|
|
338
344
|
invalidNumber: string;
|
|
@@ -427,6 +433,11 @@ declare const _default: {
|
|
|
427
433
|
table: {
|
|
428
434
|
label: string;
|
|
429
435
|
};
|
|
436
|
+
sankey: {
|
|
437
|
+
alerts: {
|
|
438
|
+
tooManyStages: string;
|
|
439
|
+
};
|
|
440
|
+
};
|
|
430
441
|
};
|
|
431
442
|
loadingOverlay: {
|
|
432
443
|
label: string;
|
|
@@ -452,6 +463,17 @@ declare const _default: {
|
|
|
452
463
|
median: string;
|
|
453
464
|
variance: string;
|
|
454
465
|
};
|
|
466
|
+
measuresAgg: {
|
|
467
|
+
countDistinct: string;
|
|
468
|
+
count: string;
|
|
469
|
+
sum: string;
|
|
470
|
+
average: string;
|
|
471
|
+
min: string;
|
|
472
|
+
max: string;
|
|
473
|
+
median: string;
|
|
474
|
+
variance: string;
|
|
475
|
+
stdev: string;
|
|
476
|
+
};
|
|
455
477
|
};
|
|
456
478
|
}[];
|
|
457
479
|
export default _default;
|
|
@@ -256,6 +256,8 @@ declare const _default: {
|
|
|
256
256
|
yes: string;
|
|
257
257
|
no: string;
|
|
258
258
|
seeMore: string;
|
|
259
|
+
generateNarrative: string;
|
|
260
|
+
hideNarrative: string;
|
|
259
261
|
};
|
|
260
262
|
disclaimer: {
|
|
261
263
|
poweredByAi: string;
|
|
@@ -309,6 +311,8 @@ declare const _default: {
|
|
|
309
311
|
from: string;
|
|
310
312
|
to: string;
|
|
311
313
|
includeCurrent: string;
|
|
314
|
+
rankedBy: string;
|
|
315
|
+
selectField: string;
|
|
312
316
|
};
|
|
313
317
|
placeholders: {
|
|
314
318
|
selectFromList: string;
|
|
@@ -333,6 +337,8 @@ declare const _default: {
|
|
|
333
337
|
greaterThan: string;
|
|
334
338
|
greaterThanOrEqual: string;
|
|
335
339
|
isWithin: string;
|
|
340
|
+
top: string;
|
|
341
|
+
bottom: string;
|
|
336
342
|
};
|
|
337
343
|
validationErrors: {
|
|
338
344
|
invalidNumber: string;
|
|
@@ -427,6 +433,11 @@ declare const _default: {
|
|
|
427
433
|
table: {
|
|
428
434
|
label: string;
|
|
429
435
|
};
|
|
436
|
+
sankey: {
|
|
437
|
+
alerts: {
|
|
438
|
+
tooManyStages: string;
|
|
439
|
+
};
|
|
440
|
+
};
|
|
430
441
|
};
|
|
431
442
|
loadingOverlay: {
|
|
432
443
|
label: string;
|
|
@@ -452,6 +463,17 @@ declare const _default: {
|
|
|
452
463
|
median: string;
|
|
453
464
|
variance: string;
|
|
454
465
|
};
|
|
466
|
+
measuresAgg: {
|
|
467
|
+
countDistinct: string;
|
|
468
|
+
count: string;
|
|
469
|
+
sum: string;
|
|
470
|
+
average: string;
|
|
471
|
+
min: string;
|
|
472
|
+
max: string;
|
|
473
|
+
median: string;
|
|
474
|
+
variance: string;
|
|
475
|
+
stdev: string;
|
|
476
|
+
};
|
|
455
477
|
};
|
|
456
478
|
}[];
|
|
457
479
|
export default _default;
|
|
@@ -256,6 +256,8 @@ declare const _default: {
|
|
|
256
256
|
yes: string;
|
|
257
257
|
no: string;
|
|
258
258
|
seeMore: string;
|
|
259
|
+
generateNarrative: string;
|
|
260
|
+
hideNarrative: string;
|
|
259
261
|
};
|
|
260
262
|
disclaimer: {
|
|
261
263
|
poweredByAi: string;
|
|
@@ -309,6 +311,8 @@ declare const _default: {
|
|
|
309
311
|
from: string;
|
|
310
312
|
to: string;
|
|
311
313
|
includeCurrent: string;
|
|
314
|
+
rankedBy: string;
|
|
315
|
+
selectField: string;
|
|
312
316
|
};
|
|
313
317
|
placeholders: {
|
|
314
318
|
selectFromList: string;
|
|
@@ -333,6 +337,8 @@ declare const _default: {
|
|
|
333
337
|
greaterThan: string;
|
|
334
338
|
greaterThanOrEqual: string;
|
|
335
339
|
isWithin: string;
|
|
340
|
+
top: string;
|
|
341
|
+
bottom: string;
|
|
336
342
|
};
|
|
337
343
|
validationErrors: {
|
|
338
344
|
invalidNumber: string;
|
|
@@ -427,6 +433,11 @@ declare const _default: {
|
|
|
427
433
|
table: {
|
|
428
434
|
label: string;
|
|
429
435
|
};
|
|
436
|
+
sankey: {
|
|
437
|
+
alerts: {
|
|
438
|
+
tooManyStages: string;
|
|
439
|
+
};
|
|
440
|
+
};
|
|
430
441
|
};
|
|
431
442
|
loadingOverlay: {
|
|
432
443
|
label: string;
|
|
@@ -452,6 +463,17 @@ declare const _default: {
|
|
|
452
463
|
median: string;
|
|
453
464
|
variance: string;
|
|
454
465
|
};
|
|
466
|
+
measuresAgg: {
|
|
467
|
+
countDistinct: string;
|
|
468
|
+
count: string;
|
|
469
|
+
sum: string;
|
|
470
|
+
average: string;
|
|
471
|
+
min: string;
|
|
472
|
+
max: string;
|
|
473
|
+
median: string;
|
|
474
|
+
variance: string;
|
|
475
|
+
stdev: string;
|
|
476
|
+
};
|
|
455
477
|
};
|
|
456
478
|
}[];
|
|
457
479
|
export default _default;
|