@sisense/sdk-ui 1.31.0 → 1.33.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 +22 -423
- package/dist/ai.js +1827 -1781
- package/dist/analytics-composer.cjs +54 -54
- package/dist/analytics-composer.js +546 -525
- package/dist/derive-chart-family-B4sA-ao-.cjs +758 -0
- package/dist/derive-chart-family-nTKwlMms.js +101063 -0
- package/dist/index.cjs +30 -858
- package/dist/index.js +14249 -10959
- package/dist/packages/sdk-ui/src/ai/ai-context-provider.d.ts +3 -2
- package/dist/packages/sdk-ui/src/ai/api/chat-rest-api.d.ts +1 -3
- package/dist/packages/sdk-ui/src/ai/api/types.d.ts +12 -3
- package/dist/packages/sdk-ui/src/ai/chart/nlq-chart-widget.d.ts +2 -2
- package/dist/packages/sdk-ui/src/ai/chatbot.d.ts +2 -2
- package/dist/packages/sdk-ui/src/ai/custom-ai-context-provider.d.ts +13 -0
- package/dist/packages/sdk-ui/src/ai/index.d.ts +7 -4
- package/dist/packages/sdk-ui/src/ai/use-get-nlg-insights.d.ts +2 -0
- package/dist/packages/sdk-ui/src/ai/use-get-nlq-result.d.ts +12 -5
- package/dist/packages/sdk-ui/src/ai/use-get-query-recommendations.d.ts +8 -4
- package/dist/packages/sdk-ui/src/ai/use-last-nlq-response-from-history.d.ts +8 -0
- package/dist/packages/sdk-ui/src/ai/use-last-nlq-response.d.ts +1 -2
- package/dist/packages/sdk-ui/src/analytics-composer/common/constants.d.ts +1 -0
- package/dist/packages/sdk-ui/src/api/rest-api.d.ts +12 -1
- package/dist/packages/sdk-ui/src/app/client-application.d.ts +15 -0
- package/dist/packages/sdk-ui/src/area-chart.d.ts +2 -2
- package/dist/packages/sdk-ui/src/bar-chart.d.ts +2 -2
- package/dist/packages/sdk-ui/src/chart/helpers/get-load-data-function.d.ts +16 -0
- package/dist/packages/sdk-ui/src/chart/helpers/use-chart-data-preparation.d.ts +17 -0
- package/dist/packages/sdk-ui/src/chart/helpers/use-synced-data.d.ts +3 -1
- package/dist/packages/sdk-ui/src/chart/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/areamap-chart-builder.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/data/areamap-data.d.ts +4 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/data/geo-data-coloring-function.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/data/index.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/data-options/data-options.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/data-options/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/design-options/design-options.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/design-options/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/{charts/map-charts/areamap → chart/restructured-charts/areamap-chart/renderer}/areamap-map.d.ts +2 -2
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/renderer/areamap-utils.d.ts +12 -0
- package/dist/packages/sdk-ui/src/{charts/map-charts/areamap → chart/restructured-charts/areamap-chart/renderer}/areamap.d.ts +5 -5
- package/dist/packages/sdk-ui/src/{charts/map-charts/areamap → chart/restructured-charts/areamap-chart/renderer}/feature-styles-dictionary.d.ts +2 -2
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/renderer/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/{charts/map-charts/areamap → chart/restructured-charts/areamap-chart/renderer}/use-geo-json.d.ts +1 -1
- package/dist/packages/sdk-ui/src/chart/restructured-charts/areamap-chart/types.d.ts +35 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/bar-chart/bar-chart-builder.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/chart-builder-factory.d.ts +3 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/column-chart/column-chart-builder.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/helpers/cartesians/data-options.d.ts +27 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/helpers/cartesians/data.d.ts +4 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/helpers/cartesians/stackable/design-options.d.ts +5 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/helpers/data-loading.d.ts +12 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/types.d.ts +100 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/utils.d.ts +3 -0
- package/dist/packages/sdk-ui/src/chart-data/types.d.ts +3 -29
- package/dist/packages/sdk-ui/src/chart-options-processor/style-to-design-options-translator/prepare-design-options.d.ts +6 -3
- package/dist/packages/sdk-ui/src/chart-options-processor/style-to-design-options-translator/translate-to-highcharts-options.d.ts +9 -8
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/design-options.d.ts +1 -7
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/tooltip-utils.d.ts +2 -3
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/types.d.ts +2 -1
- package/dist/packages/sdk-ui/src/column-chart.d.ts +2 -2
- package/dist/packages/sdk-ui/src/common/components/grouped-items-browser/group-header.d.ts +10 -0
- package/dist/packages/sdk-ui/src/common/components/grouped-items-browser/group.d.ts +10 -0
- package/dist/packages/sdk-ui/src/common/components/grouped-items-browser/grouped-items-browser.d.ts +6 -0
- package/dist/packages/sdk-ui/src/common/components/grouped-items-browser/item-row.d.ts +15 -0
- package/dist/packages/sdk-ui/src/common/components/grouped-items-browser/types.d.ts +40 -0
- package/dist/packages/sdk-ui/src/common/components/loading-dots.d.ts +1 -1
- package/dist/packages/sdk-ui/src/common/components/popover.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/components/radio.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/helpers/hooks/index.d.ts +4 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/helpers/hooks/use-data-accumulation.d.ts +7 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/helpers/hooks/use-get-load-more-function.d.ts +4 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/helpers/hooks/use-load-data-from-internal-hook.d.ts +16 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/helpers/hooks/use-manage-slice-to-load.d.ts +10 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/helpers/utils/calculate-if-all-items-loaded.d.ts +2 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/helpers/utils/get-hook-state-result.d.ts +9 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/helpers/utils/index.d.ts +2 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/types.d.ts +27 -0
- package/dist/packages/sdk-ui/src/common/hooks/decorators/with-lazy-loading/with-lazy-loading.d.ts +7 -0
- package/dist/packages/sdk-ui/src/common/hooks/fusion-endpoints/use-get-data-source-fields.d.ts +17 -0
- package/dist/packages/sdk-ui/src/common/hooks/use-defaults.d.ts +9 -0
- package/dist/packages/sdk-ui/src/common/hooks/use-last-defined.d.ts +6 -0
- package/dist/packages/sdk-ui/src/common/icons/approval-icon.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/icons/arrow-icon.d.ts +3 -0
- package/dist/packages/sdk-ui/src/common/icons/breadcrumbs-arrows-arrow-icon.d.ts +3 -0
- package/dist/packages/sdk-ui/src/common/icons/close-icon.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/icons/date-attribute-icon.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/icons/elasticube-icon.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/icons/numeric-attribute-icon.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/icons/plus-icon.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/icons/table-icon.d.ts +1 -0
- package/dist/packages/sdk-ui/src/common/icons/text-attribute-icon.d.ts +1 -0
- package/dist/packages/sdk-ui/src/dashboard/components/content-panel.d.ts +8 -1
- package/dist/packages/sdk-ui/src/dashboard/components/dashboard-container.d.ts +1 -1
- package/dist/packages/sdk-ui/src/dashboard/constants.d.ts +4 -0
- package/dist/packages/sdk-ui/src/dashboard/dashboard-helpers.d.ts +6 -6
- package/dist/packages/sdk-ui/src/dashboard/hooks/use-tabber.d.ts +18 -0
- package/dist/packages/sdk-ui/src/dashboard/hooks/use-widgets-layout.d.ts +14 -0
- package/dist/packages/sdk-ui/src/dashboard/index.d.ts +1 -1
- package/dist/packages/sdk-ui/src/dashboard/types.d.ts +68 -32
- package/dist/packages/sdk-ui/src/dashboard/use-composed-dashboard.d.ts +7 -2
- package/dist/packages/sdk-ui/src/data-browser/add-filter-popover/add-filter-data-browser.d.ts +9 -0
- package/dist/packages/sdk-ui/src/data-browser/add-filter-popover/add-filter-popover.d.ts +14 -0
- package/dist/packages/sdk-ui/src/data-browser/add-filter-popover/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/data-browser/add-filter-popover/popover-header.d.ts +12 -0
- package/dist/packages/sdk-ui/src/data-browser/data-source-selector/data-source-selector.d.ts +7 -0
- package/dist/packages/sdk-ui/src/data-browser/data-source-selector/use-data-source-selection.d.ts +5 -0
- package/dist/packages/sdk-ui/src/data-browser/dimensions-browser/dimensions-browser.d.ts +6 -0
- package/dist/packages/sdk-ui/src/data-browser/dimensions-browser/types.d.ts +74 -0
- package/dist/packages/sdk-ui/src/data-browser/search-input/search-input.d.ts +5 -0
- package/dist/packages/sdk-ui/src/filters/components/common/checkbox.d.ts +1 -0
- package/dist/packages/sdk-ui/src/filters/components/criteria-filter-tile/criteria-filter-tile.d.ts +1 -1
- package/dist/packages/sdk-ui/src/filters/components/date-filter/date-filter/calendar-date-selector.d.ts +8 -7
- package/dist/packages/sdk-ui/src/filters/components/date-filter/date-filter/date-range-calculator.d.ts +1 -1
- package/dist/packages/sdk-ui/src/filters/components/date-filter/date-range-filter-tile/date-range-filter-tile.d.ts +3 -0
- package/dist/packages/sdk-ui/src/filters/components/date-filter/relative-date-filter-tile/relative-date-filter-tile.d.ts +1 -1
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/input.d.ts +5 -2
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/search-input.d.ts +4 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/base.d.ts +11 -7
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/calendar-select/calendar-select.d.ts +24 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/calendar-select/index.d.ts +2 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/calendar-select/types.d.ts +14 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/calendar-select/utils.d.ts +5 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/members-list-select.d.ts +11 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/searchable-multi-select.d.ts +3 -4
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/searchable-single-select.d.ts +17 -4
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/single-select.d.ts +3 -2
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/selectable-section.d.ts +2 -1
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/filter-editor-container.d.ts +2 -1
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/filter-editor-context.d.ts +13 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/filter-editor-datetime.d.ts +9 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/filter-editor-numerical.d.ts +2 -1
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/filter-editor-popover.d.ts +6 -2
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/filter-editor-textual.d.ts +2 -1
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/filter-editor.d.ts +6 -2
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/hooks/use-datetime-formatter.d.ts +2 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/hooks/use-get-attribute-stats.d.ts +4 -2
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/common/granularities.d.ts +8 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/datetime-condition-section/condition-forms/datetime-exclude-condition-form.d.ts +11 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/datetime-condition-section/condition-forms/datetime-is-within-condition-form.d.ts +10 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/datetime-condition-section/datetime-condition-section.d.ts +12 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/datetime-condition-section/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/datetime-members-section.d.ts +12 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/datetime-range-section.d.ts +11 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/datetime-relative-section.d.ts +9 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/members-section.d.ts +0 -5
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/not-supported-section.d.ts +6 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/numeric-condition-section/numeric-condition-section.d.ts +1 -6
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/text-condition-section.d.ts +1 -3
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/types.d.ts +4 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/sections/utils.d.ts +5 -2
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/types.d.ts +5 -0
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/utils.d.ts +13 -1
- package/dist/packages/sdk-ui/src/filters/components/filter-tile-container.d.ts +7 -0
- package/dist/packages/sdk-ui/src/filters/components/filters-panel/constants.d.ts +6 -0
- package/dist/packages/sdk-ui/src/filters/components/filters-panel/filters-panel-header.d.ts +6 -0
- package/dist/packages/sdk-ui/src/filters/components/filters-panel/filters-panel.d.ts +5 -2
- package/dist/packages/sdk-ui/src/filters/components/filters-panel/hooks/use-existing-filter-editing.d.ts +19 -0
- package/dist/packages/sdk-ui/src/filters/components/filters-panel/hooks/use-new-filter-adding.d.ts +19 -0
- package/dist/packages/sdk-ui/src/filters/components/filters-panel/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/filters/components/filters-panel/types.d.ts +60 -0
- package/dist/packages/sdk-ui/src/filters/components/icons/date-icon.d.ts +1 -1
- package/dist/packages/sdk-ui/src/filters/components/icons/index.d.ts +0 -1
- package/dist/packages/sdk-ui/src/filters/components/member-filter-tile/member-filter-tile.d.ts +1 -1
- package/dist/packages/sdk-ui/src/filters/hooks/use-get-filter-members.d.ts +3 -2
- package/dist/packages/sdk-ui/src/index.d.ts +2 -1
- package/dist/packages/sdk-ui/src/line-chart.d.ts +2 -2
- package/dist/packages/sdk-ui/src/models/dashboard/dashboard-model-translator.d.ts +0 -2
- package/dist/packages/sdk-ui/src/models/dashboard/dashboard-model.d.ts +7 -1
- package/dist/packages/sdk-ui/src/models/dashboard/translate-dashboard-utils.d.ts +2 -1
- package/dist/packages/sdk-ui/src/models/dashboard/types.d.ts +9 -1
- package/dist/packages/sdk-ui/src/models/widget/use-get-widget-model.d.ts +1 -1
- package/dist/packages/sdk-ui/src/pie-chart.d.ts +2 -2
- package/dist/packages/sdk-ui/src/pivot-table/formatters/header-cell-formatters/header-cell-value-formatter.d.ts +1 -1
- package/dist/packages/sdk-ui/src/plugins-provider/custom-plugins-provider.d.ts +8 -8
- package/dist/packages/sdk-ui/src/plugins-provider/plugins-context.d.ts +6 -6
- package/dist/packages/sdk-ui/src/plugins-provider/plugins-provider.d.ts +3 -3
- package/dist/packages/sdk-ui/src/plugins-provider/types.d.ts +2 -1
- package/dist/packages/sdk-ui/src/polar-chart.d.ts +2 -2
- package/dist/packages/sdk-ui/src/props.d.ts +35 -15
- package/dist/packages/sdk-ui/src/query-execution/use-execute-query.d.ts +1 -1
- package/dist/packages/sdk-ui/src/scatter-chart.d.ts +1 -1
- package/dist/packages/sdk-ui/src/sisense-chart/sisense-chart.d.ts +1 -16
- package/dist/packages/sdk-ui/src/sisense-chart/types.d.ts +16 -1
- package/dist/packages/sdk-ui/src/theme-provider/use-theme-settings.d.ts +1 -1
- package/dist/packages/sdk-ui/src/theme-provider/utils.d.ts +5 -0
- package/dist/packages/sdk-ui/src/translation/resources/en.d.ts +47 -0
- package/dist/packages/sdk-ui/src/translation/resources/index.d.ts +94 -0
- package/dist/packages/sdk-ui/src/types.d.ts +203 -1
- package/dist/packages/sdk-ui/src/utils/data-sources-utils.d.ts +8 -0
- package/dist/packages/sdk-ui/src/utils/generate-attribute-name.d.ts +2 -0
- package/dist/packages/sdk-ui/src/utils/utility-types.d.ts +38 -0
- package/dist/packages/sdk-ui/src/widget-by-id/translate-dashboard-filters.d.ts +1 -0
- package/dist/packages/sdk-ui/src/widget-by-id/translate-widget-style-options.d.ts +16 -5
- package/dist/packages/sdk-ui/src/widgets/drilldown-widget.d.ts +1 -1
- package/dist/packages/sdk-ui/src/widgets/tabber-widget.d.ts +35 -0
- package/dist/use-common-filters--WPkVexd.js +28459 -0
- package/dist/use-common-filters-BNKt9a0z.cjs +271 -0
- package/dist/{widget-composer-BrQ6SrZ6.js → widget-composer-CobNNZ1e.js} +239 -233
- package/dist/widget-composer-DPqi_qzU.cjs +316 -0
- package/package.json +10 -9
- package/dist/derive-chart-family-D3iN--j2.js +0 -44430
- package/dist/derive-chart-family-Tt7cIUck.cjs +0 -271
- package/dist/packages/sdk-ui/src/ai/use-get-data-source-fields.d.ts +0 -12
- package/dist/packages/sdk-ui/src/chart-data/areamap-data.d.ts +0 -4
- package/dist/packages/sdk-ui/src/chart-data/data-coloring/geo-data-coloring-function.d.ts +0 -2
- package/dist/packages/sdk-ui/src/chart-options-processor/style-to-design-options-translator/translate-to-areamap-options.d.ts +0 -3
- package/dist/packages/sdk-ui/src/charts/map-charts/areamap/areamap-utils.d.ts +0 -11
- package/dist/use-common-filters-CHBXz5rL.js +0 -83439
- package/dist/use-common-filters-Dd-gOMfB.cjs +0 -916
- package/dist/widget-composer-BHf4pbvI.cjs +0 -311
- /package/dist/packages/sdk-ui/src/{charts/map-charts/areamap → chart/restructured-charts/areamap-chart/renderer}/alternative-country-names-dictionary.d.ts +0 -0
- /package/dist/packages/sdk-ui/src/{filters/components → common}/icons/search-icon.d.ts +0 -0
|
@@ -10,7 +10,7 @@ import { Filter, FilterRelations } from '@sisense/sdk-data';
|
|
|
10
10
|
* ```ts
|
|
11
11
|
* const existingDashboard: DashboardProps = {...}
|
|
12
12
|
* const newFilters: Filter[] = [{...}, {...}, ...];
|
|
13
|
-
* const updatedDashboard = replaceFilters(existingDashboard, newFilters);
|
|
13
|
+
* const updatedDashboard = dashboardHelpers.replaceFilters(existingDashboard, newFilters);
|
|
14
14
|
* ```
|
|
15
15
|
* @param dashboard - The original dashboard (`DashboardProps`) whose filters are to be replaced.
|
|
16
16
|
* @param newFilters - An array of new filters or filter relations to set on the dashboard.
|
|
@@ -27,7 +27,7 @@ export declare const replaceFilters: (dashboard: DashboardProps, newFilters: Fil
|
|
|
27
27
|
* ```ts
|
|
28
28
|
* const existingDashboard: DashboardProps = {...};
|
|
29
29
|
* const newFilter: Filter = {...};
|
|
30
|
-
* const updatedDashboard = addFilter(existingDashboard, newFilter);
|
|
30
|
+
* const updatedDashboard = dashboardHelpers.addFilter(existingDashboard, newFilter);
|
|
31
31
|
* ```
|
|
32
32
|
* @param dashboard - The original dashboard (`DashboardProps`) to which the filter will be added.
|
|
33
33
|
* @param newFilter - The filter to add to the dashboard.
|
|
@@ -44,7 +44,7 @@ export declare const addFilter: (dashboard: DashboardProps, newFilter: Filter) =
|
|
|
44
44
|
* ```ts
|
|
45
45
|
* const existingDashboard: DashboardProps = {...};
|
|
46
46
|
* const newFilters: Filter[] = [{...}, {...}, ...];
|
|
47
|
-
* const updatedDashboard = addFilters(existingDashboard, newFilters);
|
|
47
|
+
* const updatedDashboard = dashboardHelpers.addFilters(existingDashboard, newFilters);
|
|
48
48
|
* ```
|
|
49
49
|
* @param dashboard - The original dashboard (`DashboardProps`) to which the filters will be added.
|
|
50
50
|
* @param newFilters - An array of filters to add to the dashboard.
|
|
@@ -63,7 +63,7 @@ export declare const addFilters: (dashboard: DashboardProps, newFilters: Filter[
|
|
|
63
63
|
* const existingDashboard: DashboardProps = {...};
|
|
64
64
|
* const filterToReplace: Filter = {...};
|
|
65
65
|
* const newFilter: Filter = {...};
|
|
66
|
-
* const updatedDashboard = replaceFilter(existingDashboard, filterToReplace, newFilter);
|
|
66
|
+
* const updatedDashboard = dashboardHelpers.replaceFilter(existingDashboard, filterToReplace, newFilter);
|
|
67
67
|
* ```
|
|
68
68
|
* @param dashboard - The original dashboard (`DashboardProps`) containing the filter to be replaced.
|
|
69
69
|
* @param filterToReplace - The existing filter to be replaced.
|
|
@@ -94,7 +94,7 @@ export declare const modifyFilter: (dashboard: DashboardProps, filterToModify: F
|
|
|
94
94
|
* ```ts
|
|
95
95
|
* const existingDashboard: DashboardProps = {...};
|
|
96
96
|
* const filterToRemove: Filter = {...};
|
|
97
|
-
* const updatedDashboard = removeFilter(existingDashboard, filterToRemove);
|
|
97
|
+
* const updatedDashboard = dashboardHelpers.removeFilter(existingDashboard, filterToRemove);
|
|
98
98
|
* ```
|
|
99
99
|
* @param dashboard - The original dashboard (`DashboardProps`) from which to remove the filter.
|
|
100
100
|
* @param filterToRemove - The filter to be removed.
|
|
@@ -112,7 +112,7 @@ export declare const removeFilter: (dashboard: DashboardProps, filterToRemove: F
|
|
|
112
112
|
* ```ts
|
|
113
113
|
* const existingDashboard: DashboardProps = {...};
|
|
114
114
|
* const filtersToRemove: Filter[] = [{...}, {...}, ...];
|
|
115
|
-
* const updatedDashboard = removeFilters(existingDashboard, filtersToRemove);
|
|
115
|
+
* const updatedDashboard = dashboardHelpers.removeFilters(existingDashboard, filtersToRemove);
|
|
116
116
|
* ```
|
|
117
117
|
* @param dashboard - The original dashboard (`DashboardProps`) from which the specified filters are removed.
|
|
118
118
|
* @param filtersToRemove - An array of filters to remove.
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { WidgetProps } from '../../props';
|
|
2
|
+
import { WidgetPanelLayoutManager } from '../../dashboard/hooks/use-widgets-layout';
|
|
3
|
+
import { TabberTab } from '../../types';
|
|
4
|
+
import { TabbersOptions, WidgetsPanelColumnLayout } from '../../models';
|
|
5
|
+
export type UseTabber = ({ widgets, config, }: {
|
|
6
|
+
widgets: WidgetProps[];
|
|
7
|
+
config?: TabbersOptions | undefined;
|
|
8
|
+
}) => {
|
|
9
|
+
layoutManager: WidgetPanelLayoutManager;
|
|
10
|
+
widgets: WidgetProps[];
|
|
11
|
+
};
|
|
12
|
+
export type SingleTabberConfig = {
|
|
13
|
+
tabs: TabberTab[];
|
|
14
|
+
activeTab: number;
|
|
15
|
+
};
|
|
16
|
+
export declare const isTabberWidget: (widget: WidgetProps) => boolean;
|
|
17
|
+
export declare const modifyLayout: (tabbersOptions: TabbersOptions, tabberState: Record<string, number>) => (layout: WidgetsPanelColumnLayout) => WidgetsPanelColumnLayout;
|
|
18
|
+
export declare const useTabber: UseTabber;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { WidgetsPanelLayout } from '../../models';
|
|
2
|
+
export type WidgetPanelLayoutManager = {
|
|
3
|
+
manageLayout: (layout: WidgetsPanelLayout) => WidgetsPanelLayout;
|
|
4
|
+
name: string;
|
|
5
|
+
};
|
|
6
|
+
type UseWidgetPanelLayoutManagement = ({ layout, layoutManagers, }: {
|
|
7
|
+
layout: WidgetsPanelLayout;
|
|
8
|
+
layoutManagers: WidgetPanelLayoutManager[];
|
|
9
|
+
}) => {
|
|
10
|
+
layout: WidgetsPanelLayout;
|
|
11
|
+
setLayout: (newLayout: WidgetsPanelLayout) => void;
|
|
12
|
+
};
|
|
13
|
+
export declare const useWidgetsLayoutManagement: UseWidgetPanelLayoutManagement;
|
|
14
|
+
export {};
|
|
@@ -2,4 +2,4 @@ export { DashboardById } from './dashboard-by-id';
|
|
|
2
2
|
export { Dashboard } from './dashboard';
|
|
3
3
|
export { useComposedDashboard, type ComposableDashboardProps, type UseComposedDashboardOptions, } from './use-composed-dashboard';
|
|
4
4
|
export { useDashboardTheme, type DashboardThemeParams } from './use-dashboard-theme';
|
|
5
|
-
export type { DashboardByIdProps, DashboardProps, DashboardLayoutOptions, DashboardStyleOptions, DashboardConfig, } from './types';
|
|
5
|
+
export type { DashboardByIdProps, DashboardProps, DashboardLayoutOptions, DashboardStyleOptions, DashboardConfig, DashboardByIdConfig, DashboardFiltersPanelConfig, } from './types';
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { DashboardStyleOptions, WidgetsOptions, WidgetsPanelLayout } from '../models';
|
|
1
|
+
import { DashboardStyleOptions, TabbersOptions, WidgetsOptions, WidgetsPanelLayout } from '../models';
|
|
2
2
|
import { WidgetProps } from '../props';
|
|
3
3
|
import { DashboardChangeAction } from '../dashboard/dashboard';
|
|
4
4
|
import { DataSource, Filter, FilterRelations } from '@sisense/sdk-data';
|
|
5
|
+
import { FiltersPanelConfig } from '../filters/components/filters-panel/types';
|
|
5
6
|
export type { DashboardStyleOptions, WidgetsPanelColumnLayout } from '../models';
|
|
6
7
|
/**
|
|
7
|
-
* Props
|
|
8
|
+
* Props of the {@link DashboardById} component.
|
|
8
9
|
*/
|
|
9
10
|
export interface DashboardByIdProps {
|
|
10
11
|
/**
|
|
@@ -12,18 +13,9 @@ export interface DashboardByIdProps {
|
|
|
12
13
|
*/
|
|
13
14
|
dashboardOid: string;
|
|
14
15
|
/**
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
* If not specified, the default value is `false`.
|
|
18
|
-
*
|
|
19
|
-
* Limitations:
|
|
20
|
-
* - WAT authentication does not support persistence.
|
|
21
|
-
* - As an alpha feature, currently only changes to dashboard filters are persisted.
|
|
22
|
-
* @alpha
|
|
16
|
+
* The configuration for the dashboard
|
|
23
17
|
*/
|
|
24
|
-
|
|
25
|
-
/** @internal */
|
|
26
|
-
enableFilterEditor?: boolean;
|
|
18
|
+
config?: DashboardByIdConfig;
|
|
27
19
|
}
|
|
28
20
|
/**
|
|
29
21
|
* Props for the DashboardContainer component
|
|
@@ -42,34 +34,77 @@ export interface DashboardContainerProps {
|
|
|
42
34
|
* @internal
|
|
43
35
|
*/
|
|
44
36
|
onChange?: (action: DashboardChangeAction) => void;
|
|
45
|
-
|
|
46
|
-
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Dashboard filters panel configuration
|
|
40
|
+
*/
|
|
41
|
+
export interface DashboardFiltersPanelConfig extends FiltersPanelConfig {
|
|
42
|
+
/**
|
|
43
|
+
* Determines whether the filters panel is visible.
|
|
44
|
+
*
|
|
45
|
+
* If not specified, the default value is `true`.
|
|
46
|
+
*/
|
|
47
|
+
visible?: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Boolean flag that controls the initial "collapsed" state of the filters panel.
|
|
50
|
+
*
|
|
51
|
+
* If not specified, the default value is `false`.
|
|
52
|
+
*/
|
|
53
|
+
collapsedInitially?: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* Setting this to `true` will use the isCollapsed state from local storage, if available, and store any changes to local storage.
|
|
56
|
+
* This state is shared across all dashboards.
|
|
57
|
+
* This state has a higher priority than `collapsedInitially` when enabled.
|
|
58
|
+
*/
|
|
59
|
+
persistCollapsedStateToLocalStorage?: boolean;
|
|
47
60
|
}
|
|
48
61
|
/**
|
|
49
62
|
* Dashboard configuration
|
|
50
|
-
*
|
|
51
|
-
* @internal
|
|
52
63
|
*/
|
|
53
64
|
export interface DashboardConfig {
|
|
54
|
-
|
|
55
|
-
|
|
65
|
+
/**
|
|
66
|
+
* Configuration for the filters panel
|
|
67
|
+
*/
|
|
68
|
+
filtersPanel?: DashboardFiltersPanelConfig;
|
|
69
|
+
/**
|
|
70
|
+
* Configuration for the toolbar
|
|
71
|
+
*/
|
|
72
|
+
toolbar?: {
|
|
56
73
|
/**
|
|
57
|
-
*
|
|
74
|
+
* Determines whether the toolbar is visible.
|
|
58
75
|
*
|
|
59
76
|
* If not specified, the default value is `false`.
|
|
60
77
|
*/
|
|
61
|
-
|
|
78
|
+
visible: boolean;
|
|
79
|
+
};
|
|
80
|
+
/**
|
|
81
|
+
* Configuration for the widgets panel
|
|
82
|
+
*/
|
|
83
|
+
widgetsPanel?: {
|
|
62
84
|
/**
|
|
63
|
-
*
|
|
64
|
-
*
|
|
65
|
-
*
|
|
85
|
+
* If true adjust layout based on available width of widgets panel.
|
|
86
|
+
*
|
|
87
|
+
* If not specified, the default value is `false`.
|
|
66
88
|
*/
|
|
67
|
-
|
|
68
|
-
};
|
|
69
|
-
toolbar?: {
|
|
70
|
-
isVisible: boolean;
|
|
89
|
+
responsive?: boolean;
|
|
71
90
|
};
|
|
72
91
|
}
|
|
92
|
+
/**
|
|
93
|
+
* Dashboard configuration
|
|
94
|
+
*/
|
|
95
|
+
export interface DashboardByIdConfig extends DashboardConfig {
|
|
96
|
+
/**
|
|
97
|
+
* Boolean flag indicating whether changes to the embedded dashboard should be saved to the dashboard in Fusion.
|
|
98
|
+
*
|
|
99
|
+
* If not specified, the default value is `false`.
|
|
100
|
+
*
|
|
101
|
+
* Limitations:
|
|
102
|
+
* - WAT authentication does not support persistence.
|
|
103
|
+
* - As an alpha feature, currently only changes to dashboard filters are persisted.
|
|
104
|
+
* @alpha
|
|
105
|
+
*/
|
|
106
|
+
persist?: boolean;
|
|
107
|
+
}
|
|
73
108
|
/**
|
|
74
109
|
* Dashboard layout options
|
|
75
110
|
*/
|
|
@@ -92,8 +127,6 @@ export interface DashboardProps {
|
|
|
92
127
|
layoutOptions?: DashboardLayoutOptions;
|
|
93
128
|
/**
|
|
94
129
|
* The configuration for the dashboard
|
|
95
|
-
*
|
|
96
|
-
* @internal
|
|
97
130
|
*/
|
|
98
131
|
config?: DashboardConfig;
|
|
99
132
|
/** The widgets to render in the dashboard */
|
|
@@ -104,6 +137,11 @@ export interface DashboardProps {
|
|
|
104
137
|
defaultDataSource?: DataSource;
|
|
105
138
|
/** The options for each of the widgets */
|
|
106
139
|
widgetsOptions?: WidgetsOptions;
|
|
140
|
+
/**
|
|
141
|
+
* The Tabber widgets configurations as a single dashboard config
|
|
142
|
+
* @internal
|
|
143
|
+
* */
|
|
144
|
+
tabbersOptions?: TabbersOptions;
|
|
107
145
|
/** The style options for the dashboard */
|
|
108
146
|
styleOptions?: DashboardStyleOptions;
|
|
109
147
|
/**
|
|
@@ -112,8 +150,6 @@ export interface DashboardProps {
|
|
|
112
150
|
* @internal
|
|
113
151
|
*/
|
|
114
152
|
onChange?: (action: DashboardChangeAction) => void;
|
|
115
|
-
/** @internal */
|
|
116
|
-
enableFilterEditor?: boolean;
|
|
117
153
|
}
|
|
118
154
|
/**
|
|
119
155
|
* Props for the Dashboard Header component
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { DashboardProps } from './types.js';
|
|
1
|
+
import { DashboardLayoutOptions, DashboardProps } from './types.js';
|
|
2
2
|
import { Filter, FilterRelations } from '@sisense/sdk-data';
|
|
3
|
-
|
|
3
|
+
import { WidgetsPanelLayout } from '../models';
|
|
4
|
+
export type ComposableDashboardProps = Pick<DashboardProps, 'filters' | 'widgets' | 'widgetsOptions' | 'layoutOptions' | 'tabbersOptions'>;
|
|
4
5
|
export type UseComposedDashboardOptions = {
|
|
5
6
|
/**
|
|
6
7
|
* @internal
|
|
@@ -16,6 +17,8 @@ export type UseComposedDashboardOptions = {
|
|
|
16
17
|
export declare function useComposedDashboardInternal<D extends ComposableDashboardProps | DashboardProps>(initialDashboard: D, { onFiltersChange }?: UseComposedDashboardOptions): {
|
|
17
18
|
dashboard: D;
|
|
18
19
|
setFilters: (filters: Filter[] | FilterRelations) => void;
|
|
20
|
+
setWidgetsLayout: (newLayout: WidgetsPanelLayout) => void;
|
|
21
|
+
layoutOptions: DashboardLayoutOptions;
|
|
19
22
|
};
|
|
20
23
|
/**
|
|
21
24
|
* React hook that takes in separate dashboard elements and
|
|
@@ -27,4 +30,6 @@ export declare function useComposedDashboardInternal<D extends ComposableDashboa
|
|
|
27
30
|
export declare const useComposedDashboard: <D extends DashboardProps | ComposableDashboardProps>(args_0: D, args_1?: UseComposedDashboardOptions | undefined) => {
|
|
28
31
|
dashboard: D;
|
|
29
32
|
setFilters: (filters: Filter[] | FilterRelations) => void;
|
|
33
|
+
setWidgetsLayout: (newLayout: WidgetsPanelLayout) => void;
|
|
34
|
+
layoutOptions: DashboardLayoutOptions;
|
|
30
35
|
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { DataSource } from '@sisense/sdk-data';
|
|
2
|
+
import { AttributiveElement } from '../dimensions-browser/types.js';
|
|
3
|
+
type AddFilterDataBrowserProps = {
|
|
4
|
+
dataSources: DataSource[];
|
|
5
|
+
initialDataSource: DataSource;
|
|
6
|
+
onAttributeClick: (attribute: AttributiveElement) => void;
|
|
7
|
+
};
|
|
8
|
+
export declare const AddFilterDataBrowser: (props: AddFilterDataBrowserProps) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { DataSource, Filter } from '@sisense/sdk-data';
|
|
2
|
+
type AddFilterPopoverProps = {
|
|
3
|
+
anchorEl: HTMLElement;
|
|
4
|
+
isOpen: boolean;
|
|
5
|
+
onClose?: () => void;
|
|
6
|
+
dataSources: DataSource[];
|
|
7
|
+
initialDataSource: DataSource;
|
|
8
|
+
onFilterCreated: (filter: Filter) => void;
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* A popover with "data browser" that allows users to select a data source and an attribute to create a filter.
|
|
12
|
+
*/
|
|
13
|
+
export declare const AddFilterPopover: ({ anchorEl, isOpen, onClose, dataSources, initialDataSource, onFilterCreated, }: AddFilterPopoverProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './add-filter-popover';
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/** A header for the popover with a title and a flow path. */
|
|
2
|
+
export declare const PopoverHeader: (props: PopoverHeaderProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
type PopoverHeaderProps = {
|
|
4
|
+
title: string;
|
|
5
|
+
flowPath: FlowStep[];
|
|
6
|
+
onClose?: () => void;
|
|
7
|
+
};
|
|
8
|
+
type FlowStep = {
|
|
9
|
+
title: string;
|
|
10
|
+
isCurrentStep: boolean;
|
|
11
|
+
};
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { DataSource } from '@sisense/sdk-data';
|
|
2
|
+
export type DataSourceSelectorProps = {
|
|
3
|
+
dataSources: DataSource[];
|
|
4
|
+
selectedDataSource: DataSource;
|
|
5
|
+
onChange: (dataSource: DataSource) => void;
|
|
6
|
+
};
|
|
7
|
+
export declare function DataSourceSelector({ dataSources, selectedDataSource, onChange, }: DataSourceSelectorProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Attribute, DateDimension, Dimension } from '@sisense/sdk-data';
|
|
3
|
+
/**
|
|
4
|
+
* Properties for the `DimensionsBrowser` component.
|
|
5
|
+
*/
|
|
6
|
+
export type DimensionsBrowserProps = {
|
|
7
|
+
/**
|
|
8
|
+
* List of dimensions to be displayed.
|
|
9
|
+
*/
|
|
10
|
+
dimensions: Dimension[];
|
|
11
|
+
/**
|
|
12
|
+
* Action to be performed when an attribute is clicked.
|
|
13
|
+
*/
|
|
14
|
+
attributeActionConfig?: AttributeActionConfig;
|
|
15
|
+
/**
|
|
16
|
+
* Config for secondary action to be performed on an attribute.
|
|
17
|
+
*/
|
|
18
|
+
attributeSecondaryActionConfig?: AttributeSecondaryActionConfig;
|
|
19
|
+
/**
|
|
20
|
+
* Config for secondary action to be performed on a dimension.
|
|
21
|
+
*/
|
|
22
|
+
dimensionSecondaryActionConfig?: DimensionSecondaryActionConfig;
|
|
23
|
+
/**
|
|
24
|
+
* Callback to be executed when the user scrolls to the bottom of the list.
|
|
25
|
+
*/
|
|
26
|
+
onScrolledToBottom?: () => void;
|
|
27
|
+
/**
|
|
28
|
+
* Flag indicating whether the component is in a loading state.
|
|
29
|
+
* If `true`, a loading spinner will be displayed.
|
|
30
|
+
*/
|
|
31
|
+
isLoading?: boolean;
|
|
32
|
+
};
|
|
33
|
+
/**
|
|
34
|
+
* Attribute-like element.
|
|
35
|
+
* In the context of the `DimensionsBrowser`, both `Attribute` and inner `DateDimension`
|
|
36
|
+
* of the parent `Dimension` mean the same level of item.
|
|
37
|
+
*/
|
|
38
|
+
export type AttributiveElement = Attribute | DateDimension;
|
|
39
|
+
/**
|
|
40
|
+
* Config for an action to be performed when an attribute is clicked.
|
|
41
|
+
*/
|
|
42
|
+
export type AttributeActionConfig = {
|
|
43
|
+
onClick(this: void, attribute: AttributiveElement): void;
|
|
44
|
+
};
|
|
45
|
+
/**
|
|
46
|
+
* Config for secondary action to be performed on an attribute.
|
|
47
|
+
*/
|
|
48
|
+
export type AttributeSecondaryActionConfig = {
|
|
49
|
+
/**
|
|
50
|
+
* Icon (or any UI component) to be displayed on the secondary action button.
|
|
51
|
+
*/
|
|
52
|
+
SecondaryActionButtonIcon: React.ComponentType<{
|
|
53
|
+
attribute: AttributiveElement;
|
|
54
|
+
}>;
|
|
55
|
+
/**
|
|
56
|
+
* Callback to be executed when the secondary action button is clicked.
|
|
57
|
+
*/
|
|
58
|
+
onClick(this: void, attribute: AttributiveElement): void;
|
|
59
|
+
};
|
|
60
|
+
/**
|
|
61
|
+
* Config for secondary action to be performed on a dimension.
|
|
62
|
+
*/
|
|
63
|
+
export type DimensionSecondaryActionConfig = {
|
|
64
|
+
/**
|
|
65
|
+
* Icon (or any UI component) to be displayed on the secondary action button.
|
|
66
|
+
*/
|
|
67
|
+
SecondaryActionButtonIcon: React.ComponentType<{
|
|
68
|
+
dimension: Dimension;
|
|
69
|
+
}>;
|
|
70
|
+
/**
|
|
71
|
+
* Callback to be executed when the secondary action button is clicked.
|
|
72
|
+
*/
|
|
73
|
+
onClick(this: void, dimension: Dimension): void;
|
|
74
|
+
};
|
|
@@ -4,6 +4,7 @@ type CheckboxProps = {
|
|
|
4
4
|
isLabelInactive?: boolean;
|
|
5
5
|
wrapperClassName?: string;
|
|
6
6
|
indeterminate?: boolean;
|
|
7
|
+
labelProps?: React.HTMLProps<HTMLLabelElement>;
|
|
7
8
|
} & InputHTMLAttributes<HTMLInputElement>;
|
|
8
9
|
export declare const Checkbox: FunctionComponent<CheckboxProps>;
|
|
9
10
|
export {};
|
package/dist/packages/sdk-ui/src/filters/components/criteria-filter-tile/criteria-filter-tile.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import { FilterTileDesignOptions } from '../filter-tile-container.js';
|
|
|
3
3
|
import { Filter, Measure } from '@sisense/sdk-data';
|
|
4
4
|
import { FilterVariant } from '../common/filter-utils.js';
|
|
5
5
|
/**
|
|
6
|
-
* Props
|
|
6
|
+
* Props of the {@link CriteriaFilterTile} component.
|
|
7
7
|
*/
|
|
8
8
|
export interface CriteriaFilterTileProps {
|
|
9
9
|
/** Title for the filter tile, which is rendered into the header */
|
|
@@ -1,21 +1,22 @@
|
|
|
1
1
|
import dayjs from 'dayjs';
|
|
2
|
-
export type SelectorMode = 'fromSelector' | 'toSelector' | 'pointSelector';
|
|
2
|
+
export type SelectorMode = 'fromSelector' | 'toSelector' | 'pointSelector' | 'multiPointsSelector';
|
|
3
3
|
export type DateRangeLimits = {
|
|
4
4
|
maxDate?: dayjs.Dayjs;
|
|
5
5
|
minDate?: dayjs.Dayjs;
|
|
6
6
|
};
|
|
7
|
-
type DayjsDateRange = {
|
|
7
|
+
export type DayjsDateRange = {
|
|
8
8
|
from: dayjs.Dayjs;
|
|
9
9
|
to: dayjs.Dayjs;
|
|
10
10
|
};
|
|
11
11
|
export type CalendarDateSelectorProps = {
|
|
12
12
|
selectorMode: SelectorMode;
|
|
13
13
|
limit?: DateRangeLimits;
|
|
14
|
+
selectedDate?: dayjs.Dayjs;
|
|
15
|
+
selectedDates?: dayjs.Dayjs[];
|
|
16
|
+
selectedDateRange?: Partial<DayjsDateRange>;
|
|
17
|
+
onDateChanged?: (selectedDate: dayjs.Dayjs) => void;
|
|
18
|
+
onDatesChanged?: (selectedDates: dayjs.Dayjs[]) => void;
|
|
14
19
|
onDateRangeChanged?: (dateRange: DayjsDateRange) => void;
|
|
15
20
|
onSelectorModeChanged?: (newSelectorMode: SelectorMode) => void;
|
|
16
|
-
selectedDateRange?: DayjsDateRange;
|
|
17
|
-
onDateChanged?: (selectedDate: dayjs.Dayjs) => void;
|
|
18
|
-
selectedDate?: dayjs.Dayjs;
|
|
19
21
|
};
|
|
20
|
-
export declare function CalendarDateSelector({
|
|
21
|
-
export {};
|
|
22
|
+
export declare function CalendarDateSelector({ selectorMode, limit, selectedDate, selectedDates, selectedDateRange, onDateChanged, onDatesChanged, onDateRangeChanged, onSelectorModeChanged, }: CalendarDateSelectorProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -4,5 +4,5 @@ type DayjsDateRange = {
|
|
|
4
4
|
from: dayjs.Dayjs;
|
|
5
5
|
to: dayjs.Dayjs;
|
|
6
6
|
};
|
|
7
|
-
export declare function calculateNewDateRange(
|
|
7
|
+
export declare function calculateNewDateRange(existingDateRange: Partial<DayjsDateRange>, newSelectedDate: dayjs.Dayjs, selectorMode: SelectorMode): DayjsDateRange;
|
|
8
8
|
export {};
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { LevelAttribute, DataSource, Filter } from '@sisense/sdk-data';
|
|
3
3
|
import { FilterTileDesignOptions } from '../../filter-tile-container';
|
|
4
|
+
/**
|
|
5
|
+
* Props of the {@link DateRangeFilterTile} component.
|
|
6
|
+
*/
|
|
4
7
|
export interface DateRangeFilterTileProps {
|
|
5
8
|
/**
|
|
6
9
|
* Filter tile title
|
|
@@ -3,7 +3,7 @@ import { Filter } from '@sisense/sdk-data';
|
|
|
3
3
|
import { FilterVariant } from '../../common/index.js';
|
|
4
4
|
import { FilterTileDesignOptions } from '../../filter-tile-container.js';
|
|
5
5
|
/**
|
|
6
|
-
* Props
|
|
6
|
+
* Props of the {@link RelativeDateFilterTile} component.
|
|
7
7
|
*/
|
|
8
8
|
export interface RelativeDateFilterTileProps {
|
|
9
9
|
/**Filter tile title */
|
|
@@ -1,10 +1,13 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { DetailedHTMLProps, InputHTMLAttributes } from 'react';
|
|
2
|
+
import { Themable } from '../../../../theme-provider/types';
|
|
2
3
|
export declare const BaseInput: import("@emotion/styled").StyledComponent<{
|
|
3
4
|
theme?: import("@emotion/react").Theme | undefined;
|
|
4
5
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
5
|
-
}, DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, {}>;
|
|
6
|
+
} & Themable, DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, {}>;
|
|
6
7
|
type InputProps = DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement> & {
|
|
7
8
|
error?: boolean | string;
|
|
9
|
+
wrapperStyle?: React.CSSProperties;
|
|
10
|
+
inputRef?: (input: HTMLInputElement) => void;
|
|
8
11
|
};
|
|
9
12
|
/** @internal */
|
|
10
13
|
export declare function Input(props: InputProps): import("react/jsx-runtime").JSX.Element;
|
package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/search-input.d.ts
CHANGED
|
@@ -2,7 +2,11 @@ import { CSSProperties } from 'react';
|
|
|
2
2
|
type SearchInputProps = {
|
|
3
3
|
placeholder?: string;
|
|
4
4
|
onChange?: (e: React.ChangeEvent<HTMLInputElement>) => void;
|
|
5
|
+
value?: string;
|
|
5
6
|
style?: CSSProperties;
|
|
7
|
+
inputStyle?: CSSProperties;
|
|
8
|
+
inputRef?: (input: HTMLInputElement) => void;
|
|
9
|
+
className?: string;
|
|
6
10
|
};
|
|
7
11
|
export declare const SearchInput: (props: SearchInputProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
12
|
export {};
|
package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/base.d.ts
CHANGED
|
@@ -1,20 +1,24 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { Focusable } from './types';
|
|
3
|
-
|
|
3
|
+
import { Themable } from '../../../../../theme-provider/types';
|
|
4
|
+
export declare const SelectField: import("@emotion/styled").StyledComponent<{
|
|
4
5
|
theme?: import("@emotion/react").Theme | undefined;
|
|
5
6
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
6
|
-
} & Focusable, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
7
|
+
} & Focusable & Themable, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
7
8
|
export declare const SelectItemContainer: import("@emotion/styled").StyledComponent<{
|
|
8
9
|
theme?: import("@emotion/react").Theme | undefined;
|
|
9
10
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
10
|
-
} & {
|
|
11
|
-
background?: string | undefined;
|
|
12
|
-
color?: string | undefined;
|
|
13
|
-
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
11
|
+
} & Themable, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
14
12
|
export declare const SelectLabel: import("@emotion/styled").StyledComponent<{
|
|
15
13
|
theme?: import("@emotion/react").Theme | undefined;
|
|
16
14
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
17
|
-
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
15
|
+
} & Themable, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
16
|
+
export declare const DropdownSelectLabel: import("@emotion/styled").StyledComponent<{
|
|
17
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
18
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
19
|
+
} & Themable & import("react").ClassAttributes<HTMLSpanElement> & import("react").HTMLAttributes<HTMLSpanElement> & {
|
|
20
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
21
|
+
}, {}, {}>;
|
|
18
22
|
export declare const SelectIconContainer: import("@emotion/styled").StyledComponent<{
|
|
19
23
|
theme?: import("@emotion/react").Theme | undefined;
|
|
20
24
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { CalendarRangeValue, CalendarSelectLimits, CalendarSelectTypes } from './types';
|
|
2
|
+
type BaseCalendarSelectProps = {
|
|
3
|
+
limits?: CalendarSelectLimits;
|
|
4
|
+
placeholder?: string;
|
|
5
|
+
width?: number | string;
|
|
6
|
+
};
|
|
7
|
+
type CalendarSingleSelectProps = BaseCalendarSelectProps & {
|
|
8
|
+
type: CalendarSelectTypes.SINGLE_SELECT;
|
|
9
|
+
value?: Date;
|
|
10
|
+
onChange?: (value: Date) => void;
|
|
11
|
+
};
|
|
12
|
+
type CalendarMultiSelectProps = BaseCalendarSelectProps & {
|
|
13
|
+
type: CalendarSelectTypes.MULTI_SELECT;
|
|
14
|
+
value?: Date[];
|
|
15
|
+
onChange?: (value: Date[]) => void;
|
|
16
|
+
};
|
|
17
|
+
type CalendarRangeSelectProps = BaseCalendarSelectProps & {
|
|
18
|
+
type: CalendarSelectTypes.RANGE_FROM_SELECT | CalendarSelectTypes.RANGE_TO_SELECT;
|
|
19
|
+
value?: CalendarRangeValue;
|
|
20
|
+
onChange?: (value: CalendarRangeValue) => void;
|
|
21
|
+
};
|
|
22
|
+
type CalendarSelectProps = CalendarSingleSelectProps | CalendarMultiSelectProps | CalendarRangeSelectProps;
|
|
23
|
+
export declare function CalendarSelect(props: CalendarSelectProps): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export declare enum CalendarSelectTypes {
|
|
2
|
+
SINGLE_SELECT = "single-select",
|
|
3
|
+
MULTI_SELECT = "multi-select",
|
|
4
|
+
RANGE_FROM_SELECT = "range-from-select",
|
|
5
|
+
RANGE_TO_SELECT = "range-to-select"
|
|
6
|
+
}
|
|
7
|
+
export type CalendarRangeValue = {
|
|
8
|
+
from?: Date;
|
|
9
|
+
to?: Date;
|
|
10
|
+
};
|
|
11
|
+
export type CalendarSelectLimits = {
|
|
12
|
+
minDate?: Date;
|
|
13
|
+
maxDate?: Date;
|
|
14
|
+
};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { DatetimeFormatter } from '../../../hooks/use-datetime-formatter';
|
|
2
|
+
import { CalendarSelectTypes } from './types';
|
|
3
|
+
import { SelectorMode } from '../../../../../../filters/components/date-filter/date-filter/calendar-date-selector';
|
|
4
|
+
export declare function getCalendarSelectedItemsDisplayValue(values: Date[], formatter: DatetimeFormatter): string | undefined;
|
|
5
|
+
export declare function getCalendarDateSelectorMode(type: CalendarSelectTypes): SelectorMode;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Attribute } from '@sisense/sdk-data';
|
|
2
|
+
type MembersListSelectProps = {
|
|
3
|
+
attribute: Attribute;
|
|
4
|
+
selectedMembers: string[];
|
|
5
|
+
onChange: (values: string[]) => void;
|
|
6
|
+
multiSelect?: boolean;
|
|
7
|
+
showSearch?: boolean;
|
|
8
|
+
width?: number | string;
|
|
9
|
+
};
|
|
10
|
+
export declare const MembersListSelect: ({ attribute, multiSelect, onChange, selectedMembers, showSearch, width, }: MembersListSelectProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export {};
|