@sisense/sdk-ui 1.32.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 +10 -10
- package/dist/ai.js +556 -564
- package/dist/analytics-composer.cjs +1 -1
- package/dist/analytics-composer.js +38 -38
- package/dist/{derive-chart-family-7Fxxf6Sy.cjs → derive-chart-family-B4sA-ao-.cjs} +136 -136
- package/dist/{derive-chart-family-CVwj-7u5.js → derive-chart-family-nTKwlMms.js} +9089 -8909
- package/dist/index.cjs +20 -17
- package/dist/index.js +10226 -7859
- package/dist/packages/sdk-ui/src/ai/ai-context-provider.d.ts +3 -2
- package/dist/packages/sdk-ui/src/ai/api/types.d.ts +11 -3
- package/dist/packages/sdk-ui/src/ai/chart/nlq-chart-widget.d.ts +2 -2
- package/dist/packages/sdk-ui/src/ai/custom-ai-context-provider.d.ts +1 -1
- 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/api/rest-api.d.ts +3 -2
- 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/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 +3 -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/index.d.ts +1 -1
- package/dist/packages/sdk-ui/src/dashboard/types.d.ts +61 -30
- 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/filter-editor-popover/common/input.d.ts +2 -1
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/base.d.ts +10 -6
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/calendar-select/calendar-select.d.ts +1 -4
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/searchable-multi-select.d.ts +1 -4
- package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/common/select/searchable-single-select.d.ts +4 -8
- 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 +2 -1
- 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-get-attribute-stats.d.ts +3 -1
- 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/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 +1 -0
- 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/index.d.ts +0 -1
- package/dist/packages/sdk-ui/src/index.d.ts +1 -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/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/polar-chart.d.ts +2 -2
- 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/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 +7 -0
- package/dist/packages/sdk-ui/src/translation/resources/index.d.ts +14 -0
- package/dist/packages/sdk-ui/src/types.d.ts +151 -0
- package/dist/packages/sdk-ui/src/utils/data-sources-utils.d.ts +8 -0
- package/dist/packages/sdk-ui/src/utils/utility-types.d.ts +6 -2
- package/dist/packages/sdk-ui/src/widgets/drilldown-widget.d.ts +1 -1
- package/dist/{use-common-filters-BanIIIUW.js → use-common-filters--WPkVexd.js} +2938 -2888
- package/dist/{use-common-filters-BeKQ1bKU.cjs → use-common-filters-BNKt9a0z.cjs} +55 -55
- package/dist/{widget-composer-4bEKHitq.js → widget-composer-CobNNZ1e.js} +25 -25
- package/dist/{widget-composer-NDI4zssI.cjs → widget-composer-DPqi_qzU.cjs} +1 -1
- package/package.json +7 -7
- /package/dist/packages/sdk-ui/src/{filters/components → common}/icons/search-icon.d.ts +0 -0
package/dist/packages/sdk-ui/src/filters/components/filters-panel/hooks/use-new-filter-adding.d.ts
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { DataSource, Filter } from '@sisense/sdk-data';
|
|
3
|
+
import { UseNewFilterCreationConfig } from '../types';
|
|
4
|
+
type UseNewFilterCreationParams = {
|
|
5
|
+
defaultDataSource?: DataSource;
|
|
6
|
+
dataSources: DataSource[];
|
|
7
|
+
onFilterCreated: (filter: Filter) => void;
|
|
8
|
+
config?: UseNewFilterCreationConfig;
|
|
9
|
+
};
|
|
10
|
+
type UseNewFilterCreationReturn = {
|
|
11
|
+
NewFilterCreator: () => JSX.Element | null;
|
|
12
|
+
startFilterCreation: (anchorEl: HTMLElement) => void;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* Hook that keeps new filter creation process.
|
|
16
|
+
* Returns a function to start creation a new filter and a component that renders the filter creation popovers.
|
|
17
|
+
*/
|
|
18
|
+
export declare const useNewFilterCreation: ({ dataSources, onFilterCreated, defaultDataSource, config, }: UseNewFilterCreationParams) => UseNewFilterCreationReturn;
|
|
19
|
+
export {};
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import type { FilterEditorConfig } from '../filter-editor-popover/types';
|
|
2
|
+
/**
|
|
3
|
+
* Configuration for the filters panel
|
|
4
|
+
*/
|
|
5
|
+
export interface FiltersPanelConfig {
|
|
6
|
+
/**
|
|
7
|
+
* Configures the available actions within the filters panel.
|
|
8
|
+
*/
|
|
9
|
+
actions?: {
|
|
10
|
+
/**
|
|
11
|
+
* Configuration for adding a new filter.
|
|
12
|
+
*/
|
|
13
|
+
addFilter?: {
|
|
14
|
+
/**
|
|
15
|
+
* Determines whether the possibility to create a new filter is enabled.
|
|
16
|
+
*
|
|
17
|
+
* If not specified, the default value is `false`.
|
|
18
|
+
*/
|
|
19
|
+
enabled?: boolean;
|
|
20
|
+
/** @internal */
|
|
21
|
+
multiSelect?: {
|
|
22
|
+
visible?: boolean;
|
|
23
|
+
};
|
|
24
|
+
};
|
|
25
|
+
/**
|
|
26
|
+
* Configuration for editing an existing filter.
|
|
27
|
+
*/
|
|
28
|
+
editFilter?: {
|
|
29
|
+
/**
|
|
30
|
+
* Determines whether the possibility to edit an existing filter is enabled.
|
|
31
|
+
*
|
|
32
|
+
* If not specified, the default value is `false`.
|
|
33
|
+
*/
|
|
34
|
+
enabled?: boolean;
|
|
35
|
+
/** @internal */
|
|
36
|
+
multiSelect?: {
|
|
37
|
+
visible?: boolean;
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
/**
|
|
41
|
+
* Configuration for deleting a filter.
|
|
42
|
+
*/
|
|
43
|
+
deleteFilter?: {
|
|
44
|
+
/**
|
|
45
|
+
* Determines whether the possibility to delete a filter is enabled.
|
|
46
|
+
*
|
|
47
|
+
* If not specified, the default value is `true`.
|
|
48
|
+
*/
|
|
49
|
+
enabled?: boolean;
|
|
50
|
+
};
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
/** @internal */
|
|
54
|
+
export type UseExistingFilterEditingConfig = FilterEditorConfig & {
|
|
55
|
+
enabled?: boolean;
|
|
56
|
+
};
|
|
57
|
+
/** @internal */
|
|
58
|
+
export type UseNewFilterCreationConfig = FilterEditorConfig & {
|
|
59
|
+
enabled?: boolean;
|
|
60
|
+
};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
export { MenuIcon } from './menu-icon';
|
|
2
2
|
export { PencilIcon } from './pencil-icon';
|
|
3
3
|
export { PlusIcon } from './plus-icon';
|
|
4
|
-
export { SearchIcon } from './search-icon';
|
|
5
4
|
export { TrashIcon } from './trash-icon';
|
|
6
5
|
export { LockIcon } from './lock-icon';
|
|
7
6
|
export { DateIcon } from './date-icon';
|
|
@@ -9,7 +9,7 @@ export { isChartWidgetProps, isPivotTableWidgetProps, isTextWidgetProps, isPlugi
|
|
|
9
9
|
export { type WidgetType, type CartesianWidgetType, type CategoricalWidgetType, type TabularWidgetType, type TextWidgetType, } from './widget-by-id/types';
|
|
10
10
|
export { getChartType } from './widget-by-id/utils';
|
|
11
11
|
export * from './query-execution';
|
|
12
|
-
export { executeQuery } from './query/execute-query';
|
|
12
|
+
export { executeQuery, executePivotQuery } from './query/execute-query';
|
|
13
13
|
export { SisenseContextProvider } from './sisense-context/sisense-context-provider';
|
|
14
14
|
export { DrilldownWidget } from './widgets/drilldown-widget';
|
|
15
15
|
export { processDrilldownSelections } from './widgets/common/use-drilldown-core';
|
|
@@ -16,8 +16,8 @@ import { LineChartProps } from './props';
|
|
|
16
16
|
*
|
|
17
17
|
* Additional Line Chart examples:
|
|
18
18
|
*
|
|
19
|
-
* - [Curved Line Chart](https://www.sisense.com/
|
|
20
|
-
* - [Styled Line Chart](https://www.sisense.com/
|
|
19
|
+
* - [Curved Line Chart](https://www.sisense.com/developers/playground/?example=charts%2Fline-chart-spline)
|
|
20
|
+
* - [Styled Line Chart](https://www.sisense.com/developers/playground/?example=charts%2Fline-chart-styled)
|
|
21
21
|
*
|
|
22
22
|
* @param props - Line chart properties
|
|
23
23
|
* @returns Line Chart component
|
|
@@ -10,8 +10,6 @@ import { AppSettings } from '../../app/settings/settings.js';
|
|
|
10
10
|
* ```tsx
|
|
11
11
|
* <Dashboard {...dashboardModelTranslator.toDashboardProps(dashboardModel)} />
|
|
12
12
|
* ```
|
|
13
|
-
* @group Fusion Assets
|
|
14
|
-
* @fusionEmbed
|
|
15
13
|
*/
|
|
16
14
|
export declare function toDashboardProps(dashboardModel: DashboardModel): DashboardProps;
|
|
17
15
|
/**
|
|
@@ -86,7 +86,7 @@ export type WidgetModelSuccessState = {
|
|
|
86
86
|
*
|
|
87
87
|
* Additional `useGetWidgetModel` examples:
|
|
88
88
|
*
|
|
89
|
-
* - [Modify Chart Type](https://www.sisense.com/
|
|
89
|
+
* - [Modify Chart Type](https://www.sisense.com/developers/playground/?example=fusion-assets%2Fuse-get-widget-model-change-chart-type)
|
|
90
90
|
*
|
|
91
91
|
* @returns Widget load state that contains the status of the execution, the result widget model, or the error if one has occurred
|
|
92
92
|
* @group Fusion Assets
|
|
@@ -17,8 +17,8 @@ import { PieChartProps } from './props';
|
|
|
17
17
|
*
|
|
18
18
|
* Additional Pie Chart examples:
|
|
19
19
|
*
|
|
20
|
-
* - [Donut Pie Chart](https://www.sisense.com/
|
|
21
|
-
* - [Ring Pie Chart](https://www.sisense.com/
|
|
20
|
+
* - [Donut Pie Chart](https://www.sisense.com/developers/playground/?example=charts%2Fpie-chart-donut)
|
|
21
|
+
* - [Ring Pie Chart](https://www.sisense.com/developers/playground/?example=charts%2Fpie-chart-ring)
|
|
22
22
|
*
|
|
23
23
|
* @param props - Pie chart properties
|
|
24
24
|
* @returns Pie Chart component
|
|
@@ -16,8 +16,8 @@ import { PolarChartProps } from './props';
|
|
|
16
16
|
*
|
|
17
17
|
* Additional Polar Chart examples:
|
|
18
18
|
*
|
|
19
|
-
* - [Area Polar Chart](https://www.sisense.com/
|
|
20
|
-
* - [Line Polar Chart](https://www.sisense.com/
|
|
19
|
+
* - [Area Polar Chart](https://www.sisense.com/developers/playground/?example=charts%2Fpolar-chart-area)
|
|
20
|
+
* - [Line Polar Chart](https://www.sisense.com/developers/playground/?example=charts%2Fpolar-chart-line)
|
|
21
21
|
*
|
|
22
22
|
* @param props - Polar chart properties
|
|
23
23
|
* @returns Polar Chart component
|
|
@@ -17,7 +17,7 @@ import { ExecuteQueryParams, ExecuteQueryResult } from './types';
|
|
|
17
17
|
*
|
|
18
18
|
* Additional `useExecuteQuery()` examples:
|
|
19
19
|
*
|
|
20
|
-
* - [Query with Sorting](https://www.sisense.com/
|
|
20
|
+
* - [Query with Sorting](https://www.sisense.com/developers/playground/?example=queries%2Fuse-execute-query-sorting)
|
|
21
21
|
* - [Take Control of Your Data Visualizations]( https://www.sisense.com/blog/take-control-of-your-data-visualizations/) blog post with examples of using the hook to fetch data to display in third-party charts.
|
|
22
22
|
*
|
|
23
23
|
* @returns Query state that contains the status of the query execution, the result data, or the error if any occurred
|
|
@@ -22,7 +22,7 @@ import { ScatterChartProps } from './props';
|
|
|
22
22
|
*
|
|
23
23
|
* Additional Scatter Chart examples:
|
|
24
24
|
*
|
|
25
|
-
* - [Bubble Scatter Chart](https://www.sisense.com/
|
|
25
|
+
* - [Bubble Scatter Chart](https://www.sisense.com/developers/playground/?example=charts/scatter-chart-bubble)
|
|
26
26
|
*
|
|
27
27
|
* @param props - Scatter chart properties
|
|
28
28
|
* @returns Scatter Chart component
|
|
@@ -337,6 +337,13 @@ export declare const translation: {
|
|
|
337
337
|
after: string;
|
|
338
338
|
};
|
|
339
339
|
};
|
|
340
|
+
dataBrowser: {
|
|
341
|
+
addFilter: string;
|
|
342
|
+
selectField: string;
|
|
343
|
+
configureFilter: string;
|
|
344
|
+
noResults: string;
|
|
345
|
+
searchPlaceholder: string;
|
|
346
|
+
};
|
|
340
347
|
pivotTable: {
|
|
341
348
|
grandTotal: string;
|
|
342
349
|
subTotal: string;
|
|
@@ -347,6 +347,13 @@ export declare const resources: {
|
|
|
347
347
|
after: string;
|
|
348
348
|
};
|
|
349
349
|
};
|
|
350
|
+
dataBrowser: {
|
|
351
|
+
addFilter: string;
|
|
352
|
+
selectField: string;
|
|
353
|
+
configureFilter: string;
|
|
354
|
+
noResults: string;
|
|
355
|
+
searchPlaceholder: string;
|
|
356
|
+
};
|
|
350
357
|
pivotTable: {
|
|
351
358
|
grandTotal: string;
|
|
352
359
|
subTotal: string;
|
|
@@ -691,6 +698,13 @@ export declare const resources: {
|
|
|
691
698
|
after: string;
|
|
692
699
|
};
|
|
693
700
|
};
|
|
701
|
+
dataBrowser: {
|
|
702
|
+
addFilter: string;
|
|
703
|
+
selectField: string;
|
|
704
|
+
configureFilter: string;
|
|
705
|
+
noResults: string;
|
|
706
|
+
searchPlaceholder: string;
|
|
707
|
+
};
|
|
694
708
|
pivotTable: {
|
|
695
709
|
grandTotal: string;
|
|
696
710
|
subTotal: string;
|
|
@@ -905,6 +905,18 @@ export interface GeneralThemeSettings {
|
|
|
905
905
|
primaryButtonTextColor?: string;
|
|
906
906
|
/** Hover color for primary buttons */
|
|
907
907
|
primaryButtonHoverColor?: string;
|
|
908
|
+
/**
|
|
909
|
+
* Theme settings for popover
|
|
910
|
+
*
|
|
911
|
+
* @internal
|
|
912
|
+
*/
|
|
913
|
+
popover?: PopoverThemeSettings;
|
|
914
|
+
/**
|
|
915
|
+
* Theme settings for buttons
|
|
916
|
+
*
|
|
917
|
+
* @internal
|
|
918
|
+
*/
|
|
919
|
+
buttons?: ButtonsThemeSettings;
|
|
908
920
|
}
|
|
909
921
|
/** Possible sizes for spacing. */
|
|
910
922
|
export type SpaceSizes = 'None' | 'Large' | 'Medium' | 'Small';
|
|
@@ -965,6 +977,145 @@ export type FilterThemeSettings = {
|
|
|
965
977
|
backgroundColor?: string;
|
|
966
978
|
};
|
|
967
979
|
};
|
|
980
|
+
/**
|
|
981
|
+
* @internal
|
|
982
|
+
*/
|
|
983
|
+
export declare enum ElementStates {
|
|
984
|
+
DEFAULT = "default",
|
|
985
|
+
HOVER = "hover",
|
|
986
|
+
FOCUS = "focus"
|
|
987
|
+
}
|
|
988
|
+
/**
|
|
989
|
+
* Represents state-based color settings for an element.
|
|
990
|
+
*
|
|
991
|
+
* @internal
|
|
992
|
+
*/
|
|
993
|
+
export type ElementStateColors = {
|
|
994
|
+
/** Default color */
|
|
995
|
+
default: string;
|
|
996
|
+
/** Hover state color */
|
|
997
|
+
hover?: string;
|
|
998
|
+
/** Focus state color */
|
|
999
|
+
focus?: string;
|
|
1000
|
+
};
|
|
1001
|
+
/**
|
|
1002
|
+
* Theme settings for input elements.
|
|
1003
|
+
*
|
|
1004
|
+
* @internal
|
|
1005
|
+
*/
|
|
1006
|
+
export type InputThemeSettings = {
|
|
1007
|
+
/** Background color */
|
|
1008
|
+
backgroundColor?: string;
|
|
1009
|
+
/** Text color */
|
|
1010
|
+
textColor?: string;
|
|
1011
|
+
/** Border color */
|
|
1012
|
+
borderColor?: string | ElementStateColors;
|
|
1013
|
+
/** Corner radius */
|
|
1014
|
+
cornerRadius?: number;
|
|
1015
|
+
/** Theme settings for dropdown list */
|
|
1016
|
+
dropdownList?: {
|
|
1017
|
+
/** Background color */
|
|
1018
|
+
backgroundColor?: string;
|
|
1019
|
+
/** Text color */
|
|
1020
|
+
textColor?: string;
|
|
1021
|
+
/** Border color */
|
|
1022
|
+
borderColor?: string;
|
|
1023
|
+
/** Corner radius */
|
|
1024
|
+
cornerRadius?: number;
|
|
1025
|
+
/** Shadow */
|
|
1026
|
+
shadow?: string;
|
|
1027
|
+
/** Theme settings for dropdown list item */
|
|
1028
|
+
item?: {
|
|
1029
|
+
/** Background color */
|
|
1030
|
+
backgroundColor?: string | ElementStateColors;
|
|
1031
|
+
/** Text color */
|
|
1032
|
+
textColor?: string;
|
|
1033
|
+
};
|
|
1034
|
+
};
|
|
1035
|
+
/** Theme settings for datepicker */
|
|
1036
|
+
datepicker?: {
|
|
1037
|
+
/** Background color */
|
|
1038
|
+
backgroundColor?: string;
|
|
1039
|
+
/** Text color */
|
|
1040
|
+
textColor?: string;
|
|
1041
|
+
/** Corner radius */
|
|
1042
|
+
cornerRadius?: number;
|
|
1043
|
+
/** Shadow */
|
|
1044
|
+
shadow?: string;
|
|
1045
|
+
/** Theme settings for datepicker day item */
|
|
1046
|
+
item?: {
|
|
1047
|
+
/** Background color */
|
|
1048
|
+
backgroundColor?: string | ElementStateColors;
|
|
1049
|
+
/** Text color */
|
|
1050
|
+
textColor?: string | ElementStateColors;
|
|
1051
|
+
};
|
|
1052
|
+
};
|
|
1053
|
+
};
|
|
1054
|
+
/**
|
|
1055
|
+
* Theme settings for popover
|
|
1056
|
+
*
|
|
1057
|
+
* @internal
|
|
1058
|
+
*/
|
|
1059
|
+
export type PopoverThemeSettings = {
|
|
1060
|
+
/** Corner radius */
|
|
1061
|
+
cornerRadius?: number;
|
|
1062
|
+
/** Shadow */
|
|
1063
|
+
shadow?: string;
|
|
1064
|
+
/** Theme settings for popover header */
|
|
1065
|
+
header?: {
|
|
1066
|
+
/** Background color */
|
|
1067
|
+
backgroundColor?: string;
|
|
1068
|
+
/** Text color */
|
|
1069
|
+
textColor?: string;
|
|
1070
|
+
};
|
|
1071
|
+
/** Theme settings for popover footer */
|
|
1072
|
+
footer?: {
|
|
1073
|
+
/** Background color */
|
|
1074
|
+
backgroundColor?: string;
|
|
1075
|
+
/** Text color */
|
|
1076
|
+
textColor?: string;
|
|
1077
|
+
};
|
|
1078
|
+
/** Theme settings for popover content */
|
|
1079
|
+
content?: {
|
|
1080
|
+
/** Background color */
|
|
1081
|
+
backgroundColor?: string;
|
|
1082
|
+
/** Text color */
|
|
1083
|
+
textColor?: string;
|
|
1084
|
+
/** Theme settings for clickable list */
|
|
1085
|
+
clickableList?: {
|
|
1086
|
+
/** Theme settings for clickable list item */
|
|
1087
|
+
item?: {
|
|
1088
|
+
/** Text color */
|
|
1089
|
+
textColor?: string;
|
|
1090
|
+
/** Background color */
|
|
1091
|
+
backgroundColor?: string;
|
|
1092
|
+
/** Setting to be applied on hover */
|
|
1093
|
+
hover?: {
|
|
1094
|
+
/** Text color */
|
|
1095
|
+
textColor?: string;
|
|
1096
|
+
/** Background color */
|
|
1097
|
+
backgroundColor?: string;
|
|
1098
|
+
};
|
|
1099
|
+
};
|
|
1100
|
+
};
|
|
1101
|
+
};
|
|
1102
|
+
/** Theme settings for popover input */
|
|
1103
|
+
input?: InputThemeSettings;
|
|
1104
|
+
};
|
|
1105
|
+
/**
|
|
1106
|
+
* Theme settings for buttons
|
|
1107
|
+
*
|
|
1108
|
+
* @internal
|
|
1109
|
+
*/
|
|
1110
|
+
export type ButtonsThemeSettings = {
|
|
1111
|
+
/** Theme settings for cancel button */
|
|
1112
|
+
cancel?: {
|
|
1113
|
+
/** Background color */
|
|
1114
|
+
backgroundColor?: string | ElementStateColors;
|
|
1115
|
+
/** Text color */
|
|
1116
|
+
textColor?: string;
|
|
1117
|
+
};
|
|
1118
|
+
};
|
|
968
1119
|
/** Theme settings defining the look and feel of components. */
|
|
969
1120
|
export interface ThemeSettings {
|
|
970
1121
|
/** Chart theme settings */
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { DataSource } from '@sisense/sdk-data';
|
|
2
|
+
export type DataSourceObject = {
|
|
3
|
+
title: string;
|
|
4
|
+
id: string;
|
|
5
|
+
};
|
|
6
|
+
export declare const toDataSourceObject: (dataSource: DataSource) => DataSourceObject;
|
|
7
|
+
export declare const getDataSourceId: (dataSource: DataSource) => string;
|
|
8
|
+
export declare const getDataSourceTitle: (dataSource: DataSource) => string;
|
|
@@ -44,6 +44,10 @@ export type AnyObject = Record<string, any>;
|
|
|
44
44
|
* Empty object with no properties
|
|
45
45
|
*/
|
|
46
46
|
export type EmptyObject = Record<string, never>;
|
|
47
|
+
/**
|
|
48
|
+
* Any array
|
|
49
|
+
*/
|
|
50
|
+
export type AnyArray = any[];
|
|
47
51
|
/**
|
|
48
52
|
* Allows you to make a property of an object required.
|
|
49
53
|
*
|
|
@@ -60,9 +64,9 @@ export type WithRequiredProp<T, K extends keyof T> = Omit<T, K> & Required<Pick<
|
|
|
60
64
|
/**
|
|
61
65
|
* Universal generic state for hooks that fetch data from the REST API.
|
|
62
66
|
*/
|
|
63
|
-
export type RestApiHookState<DataKey extends string, SuccessDataType extends AnyObject> = RestApiHookSuccessState<DataKey, SuccessDataType> | RestApiHookErrorState<DataKey> | RestApiHookLoadingState<DataKey>;
|
|
67
|
+
export type RestApiHookState<DataKey extends string, SuccessDataType extends AnyObject | AnyArray> = RestApiHookSuccessState<DataKey, SuccessDataType> | RestApiHookErrorState<DataKey> | RestApiHookLoadingState<DataKey>;
|
|
64
68
|
/** Success state of the REST API hook */
|
|
65
|
-
export type RestApiHookSuccessState<DataKey extends string, SuccessDataType extends AnyObject> = {
|
|
69
|
+
export type RestApiHookSuccessState<DataKey extends string, SuccessDataType extends AnyObject | AnyArray> = {
|
|
66
70
|
isLoading: false;
|
|
67
71
|
isError: false;
|
|
68
72
|
isSuccess: true;
|
|
@@ -29,7 +29,7 @@ import { DrilldownWidgetProps } from '../props';
|
|
|
29
29
|
*
|
|
30
30
|
* Additional drilldown examples:
|
|
31
31
|
*
|
|
32
|
-
* - [Detached Breadcrumbs](https://www.sisense.com/
|
|
32
|
+
* - [Detached Breadcrumbs](https://www.sisense.com/developers/playground/?example=use-cases%2Fdrilldown-detached-breadcrumbs)
|
|
33
33
|
*
|
|
34
34
|
* @param props - DrilldownWidget properties
|
|
35
35
|
* @returns DrilldownWidget wrapper component
|