@sisense/sdk-ui 2.9.0 → 2.10.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 +31 -31
- package/dist/ai.js +27 -27
- package/dist/analytics-composer/node.cjs +3 -1
- package/dist/analytics-composer/node.js +514 -378
- package/dist/analytics-composer.cjs +1 -1
- package/dist/analytics-composer.js +6 -6
- package/dist/derive-chart-family-B1on_xkS.cjs +170 -0
- package/dist/derive-chart-family-BllGhqsW.js +29469 -0
- package/dist/{dimensions-CVJeJ8mi.cjs → dimensions-BYqdB-Q8.cjs} +1 -1
- package/dist/{dimensions-B2jz151s.js → dimensions-D-Z9sitz.js} +1 -1
- package/dist/execute-query-CABqVn7C.cjs +1 -0
- package/dist/{execute-query-agpyzZz6.js → execute-query-CGLL9vXX.js} +269 -247
- package/dist/index.cjs +25 -26
- package/dist/index.js +7945 -7469
- package/dist/index.umd.js +383 -374
- package/dist/packages/sdk-ui/src/analytics-composer/new-nlq-translator/common.d.ts +14 -0
- package/dist/packages/sdk-ui/src/analytics-composer/new-nlq-translator/translate-dimensions.d.ts +2 -2
- package/dist/packages/sdk-ui/src/analytics-composer/new-nlq-translator/translate-filters.d.ts +5 -5
- package/dist/packages/sdk-ui/src/analytics-composer/new-nlq-translator/translate-measures.d.ts +3 -3
- package/dist/packages/sdk-ui/src/analytics-composer/types.d.ts +12 -0
- package/dist/packages/sdk-ui/src/calendar-heatmap-chart.d.ts +12 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/calendar-heatmap-chart-builder.d.ts +8 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/constants.d.ts +87 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/data-options/data-options.d.ts +54 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/data-options/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/data.d.ts +33 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/design-options.d.ts +22 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/highcharts-options-builder.d.ts +8 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/axes-options.d.ts +12 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/chart-options.d.ts +9 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/extras-options.d.ts +9 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/index.d.ts +7 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/legend-options.d.ts +8 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/plot-options.d.ts +9 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/series-options/calendar-data-generator.d.ts +35 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/series-options/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/series-options/series-options.d.ts +9 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/tooltip-options.d.ts +9 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/calendar-heatmap-charts-grid.d.ts +26 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/calendar-heatmap.d.ts +17 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/calendar-pagination/calendar-pagination.d.ts +30 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/calendar-pagination/helpers.d.ts +3 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/calendar-pagination/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/helpers/data-helpers.d.ts +4 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/helpers/sizing-helpers.d.ts +25 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/helpers/view-helpers.d.ts +14 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/hooks/index.d.ts +4 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/hooks/use-calendar-heatmap-chart-options.d.ts +55 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/hooks/use-calendar-heatmap-navigation.d.ts +33 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/index.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/types.d.ts +13 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/cartesians/helpers/data-options.d.ts +5 -1
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/cartesians/helpers/highchart-options/legend.d.ts +3 -2
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/helpers/data-options.d.ts +22 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/helpers/data.d.ts +13 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/pie-chart/alerts/index.d.ts +5 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/pie-chart/data/index.d.ts +15 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/pie-chart/data-options/index.d.ts +32 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/pie-chart/design-options/index.d.ts +17 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/pie-chart/highchart-options/highcharts-options-builder.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/pie-chart/pie-chart-builder.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/pie-chart/types.d.ts +12 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/highcharts-based-chart-renderer/highcharts-based-chart-renderer.d.ts +2 -4
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/highcharts-based-chart-renderer/use-extra-config.d.ts +2 -0
- package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/types.d.ts +1 -1
- package/dist/packages/sdk-ui/src/chart/restructured-charts/types.d.ts +10 -9
- package/dist/packages/sdk-ui/src/chart-data/types.d.ts +2 -1
- package/dist/packages/sdk-ui/src/chart-data-options/translate-data-options.d.ts +2 -1
- package/dist/packages/sdk-ui/src/chart-data-options/types.d.ts +19 -2
- package/dist/packages/sdk-ui/src/chart-data-options/utils.d.ts +4 -4
- package/dist/packages/sdk-ui/src/chart-data-options/validate-data-options/validate-categorical-data-options.d.ts +14 -0
- package/dist/packages/sdk-ui/src/chart-options-processor/cartesian/utils/series-processor.d.ts +4 -1
- package/dist/packages/sdk-ui/src/chart-options-processor/{category-chart-options.d.ts → category-chart-options/category-chart-options.d.ts} +9 -5
- package/dist/packages/sdk-ui/src/chart-options-processor/category-chart-options/funnel-chart-options.d.ts +15 -0
- package/dist/packages/sdk-ui/src/chart-options-processor/category-chart-options/pie-chart-options.d.ts +15 -0
- package/dist/packages/sdk-ui/src/chart-options-processor/category-chart-options/sunburst-chart-options.d.ts +17 -0
- package/dist/packages/sdk-ui/src/chart-options-processor/category-chart-options/treemap-chart-options.d.ts +17 -0
- package/dist/packages/sdk-ui/src/chart-options-processor/chart-options-service.d.ts +26 -0
- package/dist/packages/sdk-ui/src/chart-options-processor/scatter-chart-options.d.ts +3 -3
- package/dist/packages/sdk-ui/src/chart-options-processor/style-to-design-options-translator/translate-to-highcharts-options.d.ts +1 -3
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/axis-section.d.ts +6 -0
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/design-options.d.ts +18 -4
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/legend-section.d.ts +28 -14
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/pie-series.d.ts +34 -6
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/tooltip-utils.d.ts +5 -0
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/translations-to-highcharts.d.ts +1 -1
- package/dist/packages/sdk-ui/src/chart-options-processor/translations/types.d.ts +50 -6
- package/dist/packages/sdk-ui/src/common/formatters/create-date-formatter.d.ts +10 -0
- package/dist/packages/sdk-ui/src/common/hooks/useDateFormatter.d.ts +7 -0
- package/dist/packages/sdk-ui/src/common/icons/double-arrow-end-icon.d.ts +6 -0
- package/dist/packages/sdk-ui/src/dashboard/components/editable-layout/utils.d.ts +0 -19
- package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/index.d.ts +1 -1
- package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-filters.d.ts +12 -1
- package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-formatters.d.ts +18 -0
- package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-handlers.d.ts +23 -0
- package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-widget-transforms.d.ts +29 -0
- package/dist/packages/sdk-ui/src/index.d.ts +1 -0
- package/dist/packages/sdk-ui/src/models/dashboard/translate-dashboard-utils.d.ts +1 -0
- package/dist/packages/sdk-ui/src/pivot-table/formatters/header-cell-formatters/header-cell-value-formatter.d.ts +2 -1
- package/dist/packages/sdk-ui/src/pivot-table/formatters/types.d.ts +0 -1
- package/dist/packages/sdk-ui/src/polar-chart.d.ts +1 -1
- package/dist/packages/sdk-ui/src/props.d.ts +72 -7
- package/dist/packages/sdk-ui/src/sisense-chart/types.d.ts +2 -2
- package/dist/packages/sdk-ui/src/theme-provider/default-theme-settings.d.ts +1 -0
- package/dist/packages/sdk-ui/src/translation/resources/en.d.ts +11 -0
- package/dist/packages/sdk-ui/src/translation/resources/index.d.ts +22 -0
- package/dist/packages/sdk-ui/src/types.d.ts +254 -16
- package/dist/packages/sdk-ui/src/utils/combine-handlers.d.ts +19 -0
- package/dist/packages/sdk-ui/src/utils/utility-types/transformer.d.ts +8 -0
- package/dist/packages/sdk-ui/src/widget-by-id/types.d.ts +4 -6
- package/dist/{types-BYUVZb6u.js → types-BRtWk8uC.js} +1 -1
- package/dist/{types-QUSMO7gF.cjs → types-Ds0KtTJF.cjs} +1 -1
- package/dist/use-common-filters-D8tEa9zb.js +91245 -0
- package/dist/use-common-filters-hw1WKPCY.cjs +844 -0
- package/dist/{widget-composer-CGp5yOny.cjs → widget-composer-B7zeAa_D.cjs} +1 -1
- package/dist/{widget-composer-BG4HonVl.js → widget-composer-DL0xPtlC.js} +3 -3
- package/package.json +9 -9
- package/dist/derive-chart-family-BLG1sO1D.js +0 -86946
- package/dist/derive-chart-family-QPmz5DJ3.cjs +0 -656
- package/dist/execute-query-Cp3se7Yb.cjs +0 -1
- package/dist/packages/sdk-ui/src/utils/__development-utils__/highcharts-options-builder-collector.d.ts +0 -61
- package/dist/packages/sdk-ui/src/utils/__development-utils__/input-output-collector.d.ts +0 -125
- package/dist/use-common-filters-DmdADAhl.cjs +0 -350
- package/dist/use-common-filters-wo5IRF5u.js +0 -31972
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { CalendarHeatmapChartDataOptionsInternal } from '../../../../../../chart-data-options/types';
|
|
2
|
+
import { CalendarHeatmapChartDesignOptions } from '../../../../../../chart-options-processor/translations/design-options';
|
|
3
|
+
import { BeforeRenderHandler } from '../../../../../../props';
|
|
4
|
+
import { MonthInfo } from '../helpers/view-helpers.js';
|
|
5
|
+
import { CalendarSize } from '../helpers/sizing-helpers.js';
|
|
6
|
+
import { CalendarHeatmapViewType } from '../../../../../../types.js';
|
|
7
|
+
import { HighchartsOptionsInternal } from '../../../../../../chart-options-processor/chart-options-service';
|
|
8
|
+
import { CalendarHeatmapChartData } from '../../data.js';
|
|
9
|
+
import { CalendarHeatmapChartEventProps } from '../../../../../../props.jsx';
|
|
10
|
+
export interface UseCalendarHeatmapChartOptionsParams {
|
|
11
|
+
chartData: CalendarHeatmapChartData;
|
|
12
|
+
dataOptions: CalendarHeatmapChartDataOptionsInternal;
|
|
13
|
+
designOptions: CalendarHeatmapChartDesignOptions;
|
|
14
|
+
availableMonths: MonthInfo[];
|
|
15
|
+
currentViewIndex: number;
|
|
16
|
+
viewType: CalendarHeatmapViewType;
|
|
17
|
+
chartSize: CalendarSize;
|
|
18
|
+
eventHandlers: Pick<CalendarHeatmapChartEventProps, 'onDataPointClick' | 'onDataPointContextMenu' | 'onDataPointsSelected'>;
|
|
19
|
+
onBeforeRender?: BeforeRenderHandler;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Custom hook for generating Highcharts options for calendar heatmap charts.
|
|
23
|
+
*
|
|
24
|
+
* Transforms chart data, design options, and event handlers into Highcharts configuration
|
|
25
|
+
* objects for each month in the current view. Each month gets its own chart instance
|
|
26
|
+
* with filtered data and appropriate sizing.
|
|
27
|
+
*
|
|
28
|
+
* @param params - Configuration object containing all required parameters
|
|
29
|
+
* @param params.chartData - The complete calendar heatmap chart data
|
|
30
|
+
* @param params.dataOptions - Internal data options configuration
|
|
31
|
+
* @param params.designOptions - Design and styling options for the chart
|
|
32
|
+
* @param params.availableMonths - Array of all available months
|
|
33
|
+
* @param params.currentViewIndex - Current view index
|
|
34
|
+
* @param params.viewType - View type that determines how many months to display
|
|
35
|
+
* @param params.chartSizes - Array of size configurations for each chart
|
|
36
|
+
* @param params.eventHandlers - Event handlers for data point interactions
|
|
37
|
+
* @param params.onBeforeRender - Optional callback executed before chart rendering
|
|
38
|
+
* @returns Array of Highcharts options objects, one for each month in the current view
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* ```typescript
|
|
42
|
+
* const chartOptionsPerMonth = useCalendarHeatmapChartOptions({
|
|
43
|
+
* chartData,
|
|
44
|
+
* dataOptions,
|
|
45
|
+
* designOptions,
|
|
46
|
+
* availableMonths,
|
|
47
|
+
* currentViewIndex,
|
|
48
|
+
* viewType,
|
|
49
|
+
* chartSize,
|
|
50
|
+
* eventHandlers: { onDataPointClick: handleClick },
|
|
51
|
+
* onBeforeRender
|
|
52
|
+
* });
|
|
53
|
+
* ```
|
|
54
|
+
*/
|
|
55
|
+
export declare function useCalendarHeatmapChartOptions({ chartData, dataOptions, designOptions, availableMonths, currentViewIndex, viewType, chartSize, eventHandlers, onBeforeRender, }: UseCalendarHeatmapChartOptionsParams): HighchartsOptionsInternal[];
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { MonthInfo } from '../helpers/view-helpers.js';
|
|
2
|
+
import { CalendarHeatmapViewType } from '../../../../../../types.js';
|
|
3
|
+
export interface CalendarHeatmapNavigationResult {
|
|
4
|
+
currentViewIndex: number;
|
|
5
|
+
setCurrentViewIndex: (index: number) => void;
|
|
6
|
+
goToFirstView: () => void;
|
|
7
|
+
goToPreviousView: () => void;
|
|
8
|
+
goToNextView: () => void;
|
|
9
|
+
goToLastView: () => void;
|
|
10
|
+
goToPreviousGroup: () => void;
|
|
11
|
+
goToNextGroup: () => void;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Custom hook for managing calendar navigation state and actions.
|
|
15
|
+
*
|
|
16
|
+
* Provides navigation functionality for calendar views including:
|
|
17
|
+
* - Basic view navigation (first, previous, next, last) - moves by 1 month
|
|
18
|
+
* - Group-level navigation - jumps by viewType amount (1, 3, 6, or 12 months)
|
|
19
|
+
* - Current view index management
|
|
20
|
+
*
|
|
21
|
+
* @param availableMonths - Array of all available months
|
|
22
|
+
* @param viewType - The current view type that determines jump size
|
|
23
|
+
* @returns Navigation state and action functions
|
|
24
|
+
*
|
|
25
|
+
* @example
|
|
26
|
+
* ```typescript
|
|
27
|
+
* const { currentViewIndex, goToNextView, goToPreviousGroup } = useCalendarNavigation(
|
|
28
|
+
* availableMonths,
|
|
29
|
+
* viewType
|
|
30
|
+
* );
|
|
31
|
+
* ```
|
|
32
|
+
*/
|
|
33
|
+
export declare function useCalendarHeatmapNavigation(availableMonths: MonthInfo[], viewType: CalendarHeatmapViewType): CalendarHeatmapNavigationResult;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Enum representing different view types for calendar heatmap charts
|
|
3
|
+
*/
|
|
4
|
+
export declare enum ViewType {
|
|
5
|
+
/** Single month view showing one month at a time */
|
|
6
|
+
MONTH = "month",
|
|
7
|
+
/** Quarter view showing 3 months at a time */
|
|
8
|
+
QUARTER = "quarter",
|
|
9
|
+
/** Half-year view showing 6 months at a time */
|
|
10
|
+
HALF_YEAR = "half-year",
|
|
11
|
+
/** Year view showing 12 months at a time */
|
|
12
|
+
YEAR = "year"
|
|
13
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CartesianChartDataOptionsInternal, ChartDataOptions, ChartDataOptionsInternal } from '../../../../../chart-data-options/types';
|
|
2
2
|
import { CartesianChartDataOptions } from '../../../../../types';
|
|
3
|
-
import { Attribute, Measure } from '@sisense/sdk-data';
|
|
3
|
+
import { Attribute, CalculatedMeasureColumn, Column, Measure, MeasureColumn } from '@sisense/sdk-data';
|
|
4
4
|
/**
|
|
5
5
|
* Translates the data options for cartesian charts to internal format.
|
|
6
6
|
*/
|
|
@@ -21,6 +21,10 @@ export declare function isCartesianChartDataOptions(dataOptions: ChartDataOption
|
|
|
21
21
|
* Checks if the internal data options are correct for cartesian charts.
|
|
22
22
|
*/
|
|
23
23
|
export declare function isCartesianChartDataOptionsInternal(dataOptions: ChartDataOptionsInternal): dataOptions is CartesianChartDataOptionsInternal;
|
|
24
|
+
/**
|
|
25
|
+
* Checks if the column is an attribute column.
|
|
26
|
+
*/
|
|
27
|
+
export declare function isAttributeColumn(column: MeasureColumn | CalculatedMeasureColumn | Column): column is Column;
|
|
24
28
|
/**
|
|
25
29
|
* Checks if the chart should have Y2 axis.
|
|
26
30
|
*/
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { LegendSettings } from '../../../../../../chart-options-processor/translations/legend-section';
|
|
2
|
+
import type { LegendOptions } from '../../../../../../types';
|
|
3
|
+
export declare const getBasicCartesianLegend: (legend?: LegendOptions) => LegendSettings;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Attribute, Measure } from '@sisense/sdk-data';
|
|
2
|
+
import { ChartDataOptions, CategoricalChartDataOptions, CategoricalChartDataOptionsInternal } from '../../../../../chart-data-options/types';
|
|
3
|
+
/**
|
|
4
|
+
* Translates categorical chart data options to internal format.
|
|
5
|
+
*/
|
|
6
|
+
export declare function translateCategoricalDataOptionsToInternal(dataOptions: CategoricalChartDataOptions): CategoricalChartDataOptionsInternal;
|
|
7
|
+
/**
|
|
8
|
+
* Gets attributes from categorical chart data options.
|
|
9
|
+
*/
|
|
10
|
+
export declare function getCategoricalAttributes(internalDataOptions: CategoricalChartDataOptionsInternal): Attribute[];
|
|
11
|
+
/**
|
|
12
|
+
* Gets measures from categorical chart data options.
|
|
13
|
+
*/
|
|
14
|
+
export declare function getCategoricalMeasures(internalDataOptions: CategoricalChartDataOptionsInternal): Measure[];
|
|
15
|
+
/**
|
|
16
|
+
* Type guard to check if data options are categorical chart data options.
|
|
17
|
+
*/
|
|
18
|
+
export declare function isCategoricalChartDataOptions(dataOptions: ChartDataOptions): dataOptions is CategoricalChartDataOptions;
|
|
19
|
+
/**
|
|
20
|
+
* Type guard to check if internal data options are categorical chart data options.
|
|
21
|
+
*/
|
|
22
|
+
export declare function isCategoricalChartDataOptionsInternal(dataOptions: any): dataOptions is CategoricalChartDataOptionsInternal;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { DataTable } from '../../../../../chart-data-processor/table-processor';
|
|
2
|
+
import { loadDataBySingleQuery } from '../../../helpers/data-loading';
|
|
3
|
+
import { CategoricalChartDataOptionsInternal } from '../../../../../chart-data-options/types';
|
|
4
|
+
import { CategoricalChartData } from '../../../../../chart-data/types';
|
|
5
|
+
/**
|
|
6
|
+
* Default data loading function for categorical charts.
|
|
7
|
+
* Uses single query execution which is appropriate for most categorical charts.
|
|
8
|
+
*/
|
|
9
|
+
export declare const loadCategoricalData: typeof loadDataBySingleQuery;
|
|
10
|
+
/**
|
|
11
|
+
* Transforms data table to categorical chart data.
|
|
12
|
+
*/
|
|
13
|
+
export declare function getCategoricalChartDataFromTable(dataOptions: CategoricalChartDataOptionsInternal, dataTable: DataTable): CategoricalChartData;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { DataTable } from '../../../../../../chart-data-processor/table-processor';
|
|
2
|
+
import { PieChartData, PieChartDataOptionsInternal } from '../types';
|
|
3
|
+
/**
|
|
4
|
+
* Data translators for pie charts.
|
|
5
|
+
*/
|
|
6
|
+
export declare const dataTranslators: {
|
|
7
|
+
/**
|
|
8
|
+
* Loads data for pie charts using the default categorical data loading approach.
|
|
9
|
+
*/
|
|
10
|
+
loadData: typeof import("../../../../helpers/data-loading").loadDataBySingleQuery;
|
|
11
|
+
/**
|
|
12
|
+
* Transforms data table to pie chart data.
|
|
13
|
+
*/
|
|
14
|
+
getChartData: (dataOptions: PieChartDataOptionsInternal, dataTable: DataTable) => PieChartData;
|
|
15
|
+
};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { Attribute, Measure } from '@sisense/sdk-data';
|
|
2
|
+
import { ChartDataOptions, ChartDataOptionsInternal } from '../../../../../../chart-data-options/types';
|
|
3
|
+
import { PieChartDataOptions, PieChartDataOptionsInternal } from '../types';
|
|
4
|
+
/**
|
|
5
|
+
* Data options translators for pie charts.
|
|
6
|
+
*/
|
|
7
|
+
export declare const dataOptionsTranslators: {
|
|
8
|
+
/**
|
|
9
|
+
* Translates pie chart data options to internal format.
|
|
10
|
+
*/
|
|
11
|
+
translateDataOptionsToInternal: (dataOptions: PieChartDataOptions) => PieChartDataOptionsInternal;
|
|
12
|
+
/**
|
|
13
|
+
* Gets attributes from pie chart data options.
|
|
14
|
+
*/
|
|
15
|
+
getAttributes: (internalDataOptions: PieChartDataOptionsInternal) => Attribute[];
|
|
16
|
+
/**
|
|
17
|
+
* Gets measures from pie chart data options.
|
|
18
|
+
*/
|
|
19
|
+
getMeasures: (internalDataOptions: PieChartDataOptionsInternal) => Measure[];
|
|
20
|
+
/**
|
|
21
|
+
* Validates and cleans pie chart data options.
|
|
22
|
+
*/
|
|
23
|
+
validateAndCleanDataOptions: (dataOptions: PieChartDataOptions) => PieChartDataOptions;
|
|
24
|
+
/**
|
|
25
|
+
* Type guard to check if data options are pie chart data options.
|
|
26
|
+
*/
|
|
27
|
+
isCorrectDataOptions: (dataOptions: ChartDataOptions) => dataOptions is import('../../../../../../chart-data-options/types').CategoricalChartDataOptions;
|
|
28
|
+
/**
|
|
29
|
+
* Type guard to check if internal data options are pie chart data options.
|
|
30
|
+
*/
|
|
31
|
+
isCorrectDataOptionsInternal: (dataOptions: ChartDataOptionsInternal) => dataOptions is import('../../../../../../chart-data-options/types').CategoricalChartDataOptionsInternal;
|
|
32
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { ChartStyleOptions } from '../../../../../../types';
|
|
2
|
+
import { PieChartStyleOptions, PieChartDesignOptions } from '../types';
|
|
3
|
+
/**
|
|
4
|
+
* Translates style options to design options for pie charts.
|
|
5
|
+
*/
|
|
6
|
+
export declare function translateStyleOptionsToDesignOptions(styleOptions: PieChartStyleOptions): PieChartDesignOptions;
|
|
7
|
+
/**
|
|
8
|
+
* Checks if the style options are correct for pie charts.
|
|
9
|
+
*/
|
|
10
|
+
export declare function isCorrectStyleOptions(styleOptions: ChartStyleOptions): styleOptions is PieChartStyleOptions;
|
|
11
|
+
/**
|
|
12
|
+
* Design options translators for pie charts.
|
|
13
|
+
*/
|
|
14
|
+
export declare const designOptionsTranslators: {
|
|
15
|
+
translateStyleOptionsToDesignOptions: typeof translateStyleOptionsToDesignOptions;
|
|
16
|
+
isCorrectStyleOptions: typeof isCorrectStyleOptions;
|
|
17
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { CategoricalChartData } from '../../../../../chart-data/types';
|
|
2
|
+
import { CategoricalChartDataOptions, CategoricalChartDataOptionsInternal } from '../../../../../chart-data-options/types';
|
|
3
|
+
import { PieStyleOptions } from '../../../../../types';
|
|
4
|
+
import { PieChartDesignOptions as PieDesignOptions } from '../../../../../chart-options-processor/translations/design-options';
|
|
5
|
+
/**
|
|
6
|
+
* Pie chart specific type aliases for better readability.
|
|
7
|
+
*/
|
|
8
|
+
export type PieChartData = CategoricalChartData;
|
|
9
|
+
export type PieChartDataOptions = CategoricalChartDataOptions;
|
|
10
|
+
export type PieChartDataOptionsInternal = CategoricalChartDataOptionsInternal;
|
|
11
|
+
export type PieChartStyleOptions = PieStyleOptions;
|
|
12
|
+
export type PieChartDesignOptions = PieDesignOptions;
|
|
@@ -4,18 +4,16 @@ import { TypedChartData, TypedDataOptionsInternal, TypedDesignOptions } from '..
|
|
|
4
4
|
import { SisenseChartDataPointEventHandler, SisenseChartDataPointsEventHandler } from '../../../../sisense-chart/types';
|
|
5
5
|
import { BeforeRenderHandler } from '../../../../props';
|
|
6
6
|
import { ChartRendererProps } from '../../../../chart/types';
|
|
7
|
+
import { ContainerSize } from '../../../../dynamic-size-container/dynamic-size-container.js';
|
|
7
8
|
export type HighchartsBasedChartRendererProps<CT extends HighchartBasedChartTypes> = {
|
|
8
9
|
chartData: TypedChartData<CT>;
|
|
9
10
|
dataOptions: TypedDataOptionsInternal<CT>;
|
|
10
11
|
designOptions: TypedDesignOptions<CT>;
|
|
12
|
+
size: ContainerSize;
|
|
11
13
|
onDataPointClick?: SisenseChartDataPointEventHandler;
|
|
12
14
|
onDataPointContextMenu?: SisenseChartDataPointEventHandler;
|
|
13
15
|
onDataPointsSelected?: SisenseChartDataPointsEventHandler;
|
|
14
16
|
onBeforeRender?: BeforeRenderHandler;
|
|
15
|
-
size?: {
|
|
16
|
-
width?: number;
|
|
17
|
-
height?: number;
|
|
18
|
-
};
|
|
19
17
|
};
|
|
20
18
|
/**
|
|
21
19
|
* Creates a specific highcharts based chart renderer component
|
package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/types.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { HighchartsOptionsInternal } from '../../../chart-options-processor/char
|
|
|
2
2
|
import { CompleteThemeSettings } from '../../../index-typedoc';
|
|
3
3
|
import { TFunction } from '@sisense/sdk-common';
|
|
4
4
|
import { TypedChartData, TypedDataOptionsInternal, TypedDesignOptions } from '../types';
|
|
5
|
-
export type HighchartBasedChartTypes = 'column' | 'bar' | 'line' | 'area' | 'polar';
|
|
5
|
+
export type HighchartBasedChartTypes = 'column' | 'bar' | 'line' | 'area' | 'polar' | 'pie' | 'calendar-heatmap';
|
|
6
6
|
export type HighchartsOptionsBuilder<CT extends HighchartBasedChartTypes> = {
|
|
7
7
|
getChart: (ctx: BuildContext<CT>) => HighchartsOptionsInternal['chart'];
|
|
8
8
|
getSeries: (ctx: BuildContext<CT>) => HighchartsOptionsInternal['series'];
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { Attribute, Measure, QueryResultData } from '@sisense/sdk-data';
|
|
3
3
|
import { QueryDescription, QueryExecutionConfig } from '@sisense/sdk-query-client';
|
|
4
|
-
import type { AreaStyleOptions, AreamapStyleOptions, ChartDataOptions, ChartStyleOptions, LineStyleOptions, PolarStyleOptions, ScattermapStyleOptions, StackableStyleOptions } from '../../types';
|
|
4
|
+
import type { AreaStyleOptions, AreamapStyleOptions, CalendarHeatmapStyleOptions, ChartDataOptions, ChartStyleOptions, LineStyleOptions, PieStyleOptions, PolarStyleOptions, ScattermapStyleOptions, StackableStyleOptions } from '../../types';
|
|
5
5
|
import type { ChartRendererProps } from '../../chart';
|
|
6
|
-
import type { CartesianChartData, ScattermapChartData } from '../../chart-data/types';
|
|
7
|
-
import { AreamapChartDataOptions, AreamapChartDataOptionsInternal, CartesianChartDataOptions, CartesianChartDataOptionsInternal, ChartDataOptionsInternal, ScattermapChartDataOptions, ScattermapChartDataOptionsInternal } from '../../chart-data-options/types';
|
|
6
|
+
import type { CartesianChartData, CategoricalChartData, ScattermapChartData } from '../../chart-data/types';
|
|
7
|
+
import { AreamapChartDataOptions, AreamapChartDataOptionsInternal, CalendarHeatmapChartDataOptions, CalendarHeatmapChartDataOptionsInternal, CartesianChartDataOptions, CartesianChartDataOptionsInternal, CategoricalChartDataOptions, CategoricalChartDataOptionsInternal, ChartDataOptionsInternal, ScattermapChartDataOptions, ScattermapChartDataOptionsInternal } from '../../chart-data-options/types';
|
|
8
8
|
import { DesignOptions } from '../../chart-options-processor/translations/types';
|
|
9
9
|
import { DataTable } from '../../chart-data-processor/table-processor';
|
|
10
10
|
import { ClientApplication } from '../../app/client-application';
|
|
@@ -12,19 +12,20 @@ import { AreamapProps } from '../../chart/restructured-charts/areamap-chart/rend
|
|
|
12
12
|
import { ScattermapProps } from '../../charts/map-charts/scattermap/scattermap';
|
|
13
13
|
import { AreamapData } from './areamap-chart/types';
|
|
14
14
|
import { HighchartsBasedChartRendererProps } from './highchart-based-charts/highcharts-based-chart-renderer/highcharts-based-chart-renderer';
|
|
15
|
-
|
|
16
|
-
export type
|
|
17
|
-
export type
|
|
18
|
-
export type
|
|
15
|
+
import { CalendarHeatmapChartData } from './highchart-based-charts/calendar-heatmap-chart/data';
|
|
16
|
+
export type SupportedChartType = 'areamap' | 'column' | 'bar' | 'line' | 'area' | 'polar' | 'pie' | 'calendar-heatmap';
|
|
17
|
+
export type TypedChartDataOptions<CT extends SupportedChartType> = CT extends 'areamap' ? AreamapChartDataOptions : CT extends 'scattermap' ? ScattermapChartDataOptions : CT extends 'pie' ? CategoricalChartDataOptions : CT extends 'column' | 'bar' | 'line' | 'area' | 'polar' ? CartesianChartDataOptions : CT extends 'calendar-heatmap' ? CalendarHeatmapChartDataOptions : never;
|
|
18
|
+
export type TypedDataOptionsInternal<CT extends SupportedChartType> = CT extends 'areamap' ? AreamapChartDataOptionsInternal : CT extends 'scattermap' ? ScattermapChartDataOptionsInternal : CT extends 'pie' ? CategoricalChartDataOptionsInternal : CT extends 'column' | 'bar' | 'line' | 'area' | 'polar' ? CartesianChartDataOptionsInternal : CT extends 'calendar-heatmap' ? CalendarHeatmapChartDataOptionsInternal : never;
|
|
19
|
+
export type TypedChartStyleOptions<CT extends SupportedChartType> = CT extends 'areamap' ? AreamapStyleOptions : CT extends 'scattermap' ? ScattermapStyleOptions : CT extends 'pie' ? PieStyleOptions : CT extends 'column' | 'bar' ? StackableStyleOptions : CT extends 'line' ? LineStyleOptions : CT extends 'area' ? AreaStyleOptions : CT extends 'polar' ? PolarStyleOptions : CT extends 'calendar-heatmap' ? CalendarHeatmapStyleOptions : never;
|
|
19
20
|
export type TypedDesignOptions<CT extends SupportedChartType> = DesignOptions<CT>;
|
|
20
|
-
export type TypedChartData<CT extends SupportedChartType> = CT extends 'areamap' ? AreamapData : CT extends 'scattermap' ? ScattermapChartData : CT extends 'column' | 'bar' | 'line' | 'area' | 'polar' ? CartesianChartData : never;
|
|
21
|
+
export type TypedChartData<CT extends SupportedChartType> = CT extends 'areamap' ? AreamapData : CT extends 'scattermap' ? ScattermapChartData : CT extends 'pie' ? CategoricalChartData : CT extends 'column' | 'bar' | 'line' | 'area' | 'polar' ? CartesianChartData : CT extends 'calendar-heatmap' ? CalendarHeatmapChartData : never;
|
|
21
22
|
export type TypedLoadDataFunction<CT extends SupportedChartType> = (options: {
|
|
22
23
|
app: ClientApplication;
|
|
23
24
|
chartDataOptionsInternal: TypedDataOptionsInternal<CT>;
|
|
24
25
|
queryDescription: QueryDescription;
|
|
25
26
|
executionConfig?: QueryExecutionConfig;
|
|
26
27
|
}) => Promise<QueryResultData>;
|
|
27
|
-
export type TypedChartRendererProps<CT extends SupportedChartType> = CT extends 'areamap' ? AreamapProps : CT extends 'scattermap' ? ScattermapProps : CT extends 'column' | 'bar' | 'line' | 'area' | 'polar' ? HighchartsBasedChartRendererProps<CT> : never;
|
|
28
|
+
export type TypedChartRendererProps<CT extends SupportedChartType> = CT extends 'areamap' ? AreamapProps : CT extends 'scattermap' ? ScattermapProps : CT extends 'column' | 'bar' | 'line' | 'area' | 'polar' | 'pie' | 'calendar-heatmap' ? HighchartsBasedChartRendererProps<CT> : never;
|
|
28
29
|
/**
|
|
29
30
|
* Chart builder interface.
|
|
30
31
|
*/
|
|
@@ -3,6 +3,7 @@ import { IndicatorChartType } from '../chart-options-processor/translations/type
|
|
|
3
3
|
import { ComparableData, Value } from '../chart-data-processor/table-processor';
|
|
4
4
|
import { Coordinates } from '../charts/map-charts/scattermap/types';
|
|
5
5
|
import { AreamapData } from '../chart/restructured-charts/areamap-chart/types';
|
|
6
|
+
import { CalendarHeatmapChartData } from '../chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/data';
|
|
6
7
|
export type CategoricalXValues = {
|
|
7
8
|
key: string;
|
|
8
9
|
xValues: string[];
|
|
@@ -140,5 +141,5 @@ export type BoxplotChartData = {
|
|
|
140
141
|
*
|
|
141
142
|
* @internal
|
|
142
143
|
*/
|
|
143
|
-
export type ChartData = CartesianChartData | CategoricalChartData | ScatterChartData | IndicatorChartData | BoxplotChartData | AreamapData | ScattermapChartData | RangeChartData;
|
|
144
|
+
export type ChartData = CartesianChartData | CategoricalChartData | ScatterChartData | IndicatorChartData | BoxplotChartData | AreamapData | ScattermapChartData | RangeChartData | CalendarHeatmapChartData;
|
|
144
145
|
export {};
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { Attribute, Measure } from '@sisense/sdk-data';
|
|
2
2
|
import { ChartType } from '../types';
|
|
3
|
-
import { ChartDataOptions, ChartDataOptionsInternal, TableDataOptionsInternal, TableDataOptions, PivotTableDataOptions, PivotTableDataOptionsInternal } from './types';
|
|
3
|
+
import { ChartDataOptions, CategoricalChartDataOptions, CategoricalChartDataOptionsInternal, ChartDataOptionsInternal, TableDataOptionsInternal, TableDataOptions, PivotTableDataOptions, PivotTableDataOptionsInternal } from './types';
|
|
4
4
|
export declare function translateChartDataOptions(chartType: ChartType, dataOptions: ChartDataOptions): ChartDataOptionsInternal;
|
|
5
|
+
export declare const translateCategoricalChartDataOptions: (categorical: CategoricalChartDataOptions) => CategoricalChartDataOptionsInternal;
|
|
5
6
|
export declare function getAttributes(dataOptions: ChartDataOptionsInternal, chartType: ChartType): Attribute[];
|
|
6
7
|
export declare function getMeasures(dataOptions: ChartDataOptionsInternal, chartType: ChartType): Measure[];
|
|
7
8
|
export declare function translateTableDataOptions(dataOptions: TableDataOptions): TableDataOptionsInternal;
|
|
@@ -372,6 +372,18 @@ export interface AreamapChartDataOptions {
|
|
|
372
372
|
/** Measure column (or measure) encoded by the color of the countries (or states) on the map. */
|
|
373
373
|
color?: [MeasureColumn | CalculatedMeasureColumn | StyledMeasureColumn];
|
|
374
374
|
}
|
|
375
|
+
/**
|
|
376
|
+
* Configuration for how to query aggregate data and assign data
|
|
377
|
+
* to a Calendar Heatmap chart.
|
|
378
|
+
*
|
|
379
|
+
* @alpha
|
|
380
|
+
*/
|
|
381
|
+
export interface CalendarHeatmapChartDataOptions {
|
|
382
|
+
/** Date column representing dates on the calendar heatmap. */
|
|
383
|
+
date: Column | StyledColumn;
|
|
384
|
+
/** Measure column (or measure) assigned to the calendar cells. */
|
|
385
|
+
value: MeasureColumn | CalculatedMeasureColumn | StyledMeasureColumn;
|
|
386
|
+
}
|
|
375
387
|
/**
|
|
376
388
|
* Configuration for how to query data and assign data to Table.
|
|
377
389
|
*/
|
|
@@ -555,7 +567,7 @@ export type ChartDataOptions = RegularChartDataOptions | TabularChartDataOptions
|
|
|
555
567
|
/**
|
|
556
568
|
* Configuration for how to query aggregate data and assigning data to chart encodings of regular charts.
|
|
557
569
|
*/
|
|
558
|
-
export type RegularChartDataOptions = CartesianChartDataOptions | CategoricalChartDataOptions | ScatterChartDataOptions | IndicatorChartDataOptions | BoxplotChartDataOptions | BoxplotChartCustomDataOptions | AreamapChartDataOptions | ScattermapChartDataOptions | RangeChartDataOptions;
|
|
570
|
+
export type RegularChartDataOptions = CartesianChartDataOptions | CategoricalChartDataOptions | ScatterChartDataOptions | IndicatorChartDataOptions | BoxplotChartDataOptions | BoxplotChartCustomDataOptions | AreamapChartDataOptions | ScattermapChartDataOptions | RangeChartDataOptions | CalendarHeatmapChartDataOptions;
|
|
559
571
|
/** @internal */
|
|
560
572
|
export interface CartesianChartDataOptionsInternal {
|
|
561
573
|
x: StyledColumn[];
|
|
@@ -629,7 +641,7 @@ export interface PivotTableDataOptionsInternal {
|
|
|
629
641
|
grandTotals?: PivotGrandTotals;
|
|
630
642
|
}
|
|
631
643
|
/** @internal */
|
|
632
|
-
export type ChartDataOptionsInternal = CartesianChartDataOptionsInternal | CategoricalChartDataOptionsInternal | ScatterChartDataOptionsInternal | IndicatorChartDataOptionsInternal | BoxplotChartDataOptionsInternal | AreamapChartDataOptionsInternal | ScattermapChartDataOptionsInternal | RangeChartDataOptionsInternal;
|
|
644
|
+
export type ChartDataOptionsInternal = CartesianChartDataOptionsInternal | CategoricalChartDataOptionsInternal | ScatterChartDataOptionsInternal | IndicatorChartDataOptionsInternal | BoxplotChartDataOptionsInternal | AreamapChartDataOptionsInternal | ScattermapChartDataOptionsInternal | RangeChartDataOptionsInternal | CalendarHeatmapChartDataOptionsInternal;
|
|
633
645
|
/** @internal */
|
|
634
646
|
export type IndicatorChartDataOptionsInternal = {
|
|
635
647
|
value?: StyledMeasureColumn[];
|
|
@@ -654,3 +666,8 @@ export type AreamapChartDataOptionsInternal = {
|
|
|
654
666
|
geo: StyledColumn;
|
|
655
667
|
color?: StyledMeasureColumn;
|
|
656
668
|
};
|
|
669
|
+
/** @internal */
|
|
670
|
+
export type CalendarHeatmapChartDataOptionsInternal = {
|
|
671
|
+
date: StyledColumn;
|
|
672
|
+
value: StyledMeasureColumn;
|
|
673
|
+
};
|
|
@@ -41,7 +41,7 @@ export declare function isMeasureColumn(arg: AnyColumn): arg is MeasureColumn |
|
|
|
41
41
|
* @param name - The name of the column.
|
|
42
42
|
* @returns The title of the column.
|
|
43
43
|
*/
|
|
44
|
-
export declare const getDataOptionTitle: (
|
|
44
|
+
export declare const getDataOptionTitle: (styledColumn: StyledColumn | StyledMeasureColumn) => string;
|
|
45
45
|
export declare const getDataOptionGranularity: ({ column, granularity }: StyledColumn) => string;
|
|
46
46
|
/** @internal */
|
|
47
47
|
export declare const translateColumnToAttribute: (c: Column | StyledColumn) => Attribute;
|
|
@@ -60,7 +60,7 @@ export declare function isStyledColumn(targetColumn: AnyColumn): targetColumn is
|
|
|
60
60
|
* @internal
|
|
61
61
|
*/
|
|
62
62
|
export declare function isCategoryStyle(category: Column | CategoryStyle): category is CategoryStyle;
|
|
63
|
-
export declare function normalizeColumn(targetColumn: Column | StyledColumn): StyledColumn;
|
|
64
|
-
export declare function normalizeMeasureColumn(targetColumn: MeasureColumn | CalculatedMeasureColumn | StyledMeasureColumn): StyledMeasureColumn;
|
|
65
|
-
export declare function normalizeAnyColumn(targetColumn: AnyColumn): StyledColumn | StyledMeasureColumn;
|
|
63
|
+
export declare function normalizeColumn(targetColumn: Column | StyledColumn, defaultStyle?: CategoryStyle): StyledColumn;
|
|
64
|
+
export declare function normalizeMeasureColumn(targetColumn: MeasureColumn | CalculatedMeasureColumn | StyledMeasureColumn, defaultStyle?: ValueStyle): StyledMeasureColumn;
|
|
65
|
+
export declare function normalizeAnyColumn(targetColumn: AnyColumn, defaultStyle?: CategoryStyle | ValueStyle): StyledColumn | StyledMeasureColumn;
|
|
66
66
|
export {};
|
|
@@ -1,3 +1,17 @@
|
|
|
1
1
|
import { CategoricalChartType } from '../../types';
|
|
2
2
|
import { CategoricalChartDataOptions } from '../types';
|
|
3
3
|
export declare function validateCategoricalChartDataOptions(chartType: CategoricalChartType, dataOptions: CategoricalChartDataOptions): CategoricalChartDataOptions;
|
|
4
|
+
/**
|
|
5
|
+
* Creates a transformer that limits the number of categories in chart data options.
|
|
6
|
+
*
|
|
7
|
+
* @param maxCategories - Maximum allowed number of categories
|
|
8
|
+
* @returns Transformer function that limits categories
|
|
9
|
+
*/
|
|
10
|
+
export declare function withCategoryLimitation(maxCategories: number): (dataOptions: CategoricalChartDataOptions) => CategoricalChartDataOptions;
|
|
11
|
+
/**
|
|
12
|
+
* Creates a transformer that limits the number of values in chart data options.
|
|
13
|
+
*
|
|
14
|
+
* @param maxValues - Maximum allowed number of values
|
|
15
|
+
* @returns Transformer function that limits values
|
|
16
|
+
*/
|
|
17
|
+
export declare function withValueLimitation(maxValues: number): (dataOptions: CategoricalChartDataOptions) => CategoricalChartDataOptions;
|
package/dist/packages/sdk-ui/src/chart-options-processor/cartesian/utils/series-processor.d.ts
CHANGED
|
@@ -33,12 +33,15 @@ interface SeriesProcessingConfig {
|
|
|
33
33
|
* Process and format series data for the chart
|
|
34
34
|
*/
|
|
35
35
|
export declare function processSeries(config: SeriesProcessingConfig): {
|
|
36
|
+
shadow?: boolean | undefined;
|
|
37
|
+
linecap?: string | undefined;
|
|
38
|
+
dashStyle?: import("../../../types").DashStyle | undefined;
|
|
39
|
+
lineWidth?: number | undefined;
|
|
36
40
|
dataLabels: {
|
|
37
41
|
formatter: (this: import("../../tooltip").HighchartsDataPointContext) => string;
|
|
38
42
|
};
|
|
39
43
|
connectNulls: boolean;
|
|
40
44
|
marker: import("../../translations/marker-section").MarkerSettings;
|
|
41
|
-
lineWidth: number;
|
|
42
45
|
type?: string | undefined;
|
|
43
46
|
showInNavigator: boolean;
|
|
44
47
|
stickyTracking: boolean;
|
|
@@ -1,9 +1,13 @@
|
|
|
1
|
-
import { ChartDesignOptions } from '
|
|
2
|
-
import { ChartType, OptionsWithAlerts, CompleteThemeSettings } from '
|
|
3
|
-
import { CategoricalChartData } from '
|
|
4
|
-
import { HighchartsOptionsInternal } from '
|
|
5
|
-
import { ChartDataOptionsInternal } from '
|
|
1
|
+
import { ChartDesignOptions } from '../translations/types';
|
|
2
|
+
import { ChartType, OptionsWithAlerts, CompleteThemeSettings } from '../../types';
|
|
3
|
+
import { CategoricalChartData } from '../../chart-data/types';
|
|
4
|
+
import { HighchartsOptionsInternal } from '../chart-options-service';
|
|
5
|
+
import { ChartDataOptionsInternal } from '../../chart-data-options/types';
|
|
6
6
|
import { TFunction } from '@sisense/sdk-common';
|
|
7
|
+
export { getPieChartOptions } from './pie-chart-options';
|
|
8
|
+
export { getFunnelChartOptions } from './funnel-chart-options';
|
|
9
|
+
export { getTreemapChartOptions } from './treemap-chart-options';
|
|
10
|
+
export { getSunburstChartOptions } from './sunburst-chart-options';
|
|
7
11
|
/**
|
|
8
12
|
* Convert intermediate chart data, data options, and design options
|
|
9
13
|
* into pure highcharts config data.
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { FunnelChartDesignOptions } from '../translations/design-options';
|
|
2
|
+
import { OptionsWithAlerts, CompleteThemeSettings } from '../../types';
|
|
3
|
+
import { CategoricalChartData } from '../../chart-data/types';
|
|
4
|
+
import { HighchartsOptionsInternal } from '../chart-options-service';
|
|
5
|
+
import { CategoricalChartDataOptionsInternal } from '../../chart-data-options/types';
|
|
6
|
+
/**
|
|
7
|
+
* Convert intermediate chart data, data options, and design options
|
|
8
|
+
* into pure highcharts config data for funnel charts.
|
|
9
|
+
*
|
|
10
|
+
* @param chartData - the data for the chart in an intermediate format
|
|
11
|
+
* @param chartDesignOptions - funnel chart specific design options
|
|
12
|
+
* @param dataOptions - chart data options
|
|
13
|
+
* @param themeSettings - theme settings
|
|
14
|
+
*/
|
|
15
|
+
export declare const getFunnelChartOptions: (chartData: CategoricalChartData, chartDesignOptions: FunnelChartDesignOptions, dataOptions: CategoricalChartDataOptionsInternal, themeSettings?: CompleteThemeSettings) => OptionsWithAlerts<HighchartsOptionsInternal>;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { PieChartDesignOptions } from '../translations/design-options';
|
|
2
|
+
import { OptionsWithAlerts, CompleteThemeSettings } from '../../types';
|
|
3
|
+
import { CategoricalChartData } from '../../chart-data/types';
|
|
4
|
+
import { HighchartsOptionsInternal } from '../chart-options-service';
|
|
5
|
+
import { CategoricalChartDataOptionsInternal } from '../../chart-data-options/types';
|
|
6
|
+
/**
|
|
7
|
+
* Convert intermediate chart data, data options, and design options
|
|
8
|
+
* into pure highcharts config data for pie charts.
|
|
9
|
+
*
|
|
10
|
+
* @param chartData - the data for the chart in an intermediate format
|
|
11
|
+
* @param chartDesignOptions - pie chart specific design options
|
|
12
|
+
* @param dataOptions - chart data options
|
|
13
|
+
* @param themeSettings - theme settings
|
|
14
|
+
*/
|
|
15
|
+
export declare const getPieChartOptions: (chartData: CategoricalChartData, chartDesignOptions: PieChartDesignOptions, dataOptions: CategoricalChartDataOptionsInternal, themeSettings?: CompleteThemeSettings) => OptionsWithAlerts<HighchartsOptionsInternal>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { TreemapChartDesignOptions } from '../translations/design-options';
|
|
2
|
+
import { OptionsWithAlerts, CompleteThemeSettings } from '../../types';
|
|
3
|
+
import { CategoricalChartData } from '../../chart-data/types';
|
|
4
|
+
import { HighchartsOptionsInternal } from '../chart-options-service';
|
|
5
|
+
import { CategoricalChartDataOptionsInternal } from '../../chart-data-options/types';
|
|
6
|
+
import { TFunction } from '@sisense/sdk-common';
|
|
7
|
+
/**
|
|
8
|
+
* Convert intermediate chart data, data options, and design options
|
|
9
|
+
* into pure highcharts config data for sunburst charts.
|
|
10
|
+
*
|
|
11
|
+
* @param chartData - the data for the chart in an intermediate format
|
|
12
|
+
* @param chartDesignOptions - sunburst chart specific design options
|
|
13
|
+
* @param dataOptions - chart data options
|
|
14
|
+
* @param translate - translation function
|
|
15
|
+
* @param themeSettings - theme settings
|
|
16
|
+
*/
|
|
17
|
+
export declare const getSunburstChartOptions: (chartData: CategoricalChartData, chartDesignOptions: TreemapChartDesignOptions, dataOptions: CategoricalChartDataOptionsInternal, translate: TFunction, themeSettings?: CompleteThemeSettings) => OptionsWithAlerts<HighchartsOptionsInternal>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { TreemapChartDesignOptions } from '../translations/design-options';
|
|
2
|
+
import { OptionsWithAlerts, CompleteThemeSettings } from '../../types';
|
|
3
|
+
import { CategoricalChartData } from '../../chart-data/types';
|
|
4
|
+
import { HighchartsOptionsInternal } from '../chart-options-service';
|
|
5
|
+
import { CategoricalChartDataOptionsInternal } from '../../chart-data-options/types';
|
|
6
|
+
import { TFunction } from '@sisense/sdk-common';
|
|
7
|
+
/**
|
|
8
|
+
* Convert intermediate chart data, data options, and design options
|
|
9
|
+
* into pure highcharts config data for treemap charts.
|
|
10
|
+
*
|
|
11
|
+
* @param chartData - the data for the chart in an intermediate format
|
|
12
|
+
* @param chartDesignOptions - treemap chart specific design options
|
|
13
|
+
* @param dataOptions - chart data options
|
|
14
|
+
* @param translate - translation function
|
|
15
|
+
* @param themeSettings - theme settings
|
|
16
|
+
*/
|
|
17
|
+
export declare const getTreemapChartOptions: (chartData: CategoricalChartData, chartDesignOptions: TreemapChartDesignOptions, dataOptions: CategoricalChartDataOptionsInternal, translate: TFunction, themeSettings?: CompleteThemeSettings) => OptionsWithAlerts<HighchartsOptionsInternal>;
|