@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
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Input/Output Collection Decorator for Runtime Test Data Generation
|
|
3
|
-
*
|
|
4
|
-
* This module provides a decorator that collects unique input/output snapshots
|
|
5
|
-
* of function calls during runtime. This is useful for generating unit test data
|
|
6
|
-
* from actual application usage.
|
|
7
|
-
*
|
|
8
|
-
* Usage:
|
|
9
|
-
* 1. Wrap your function with the decorator:
|
|
10
|
-
* ```ts
|
|
11
|
-
* // With configuration:
|
|
12
|
-
* const myFunction = withInputOutputCollection({ maxSnapshots: 100 })(originalFunction);
|
|
13
|
-
*
|
|
14
|
-
* // With custom function name:
|
|
15
|
-
* const myFunction = withInputOutputCollection({
|
|
16
|
-
* maxSnapshots: 100,
|
|
17
|
-
* functionName: 'myCustomName'
|
|
18
|
-
* })(originalFunction);
|
|
19
|
-
*
|
|
20
|
-
|
|
21
|
-
* ```
|
|
22
|
-
*
|
|
23
|
-
* 2. Run your application and exercise the function with various inputs
|
|
24
|
-
*
|
|
25
|
-
* 3. In the browser console (development only), call:
|
|
26
|
-
* - `printCollectedInfo()` - to view all collected data
|
|
27
|
-
* - `getCollectedData()` - to get data programmatically
|
|
28
|
-
* - `exportCollectedDataAsJson()` - to export as JSON string with function serialization
|
|
29
|
-
* - `parseCollectedDataFromJson(jsonString)` - to parse exported JSON and get function placeholders
|
|
30
|
-
* - `clearCollectedData()` - to clear collected data
|
|
31
|
-
* - `cleanup()` - to completely clean up the collector
|
|
32
|
-
*
|
|
33
|
-
* Features:
|
|
34
|
-
* - Intelligent deduplication prevents collecting identical input/output pairs
|
|
35
|
-
* - Robust deep equality checking handles functions, dates, and complex objects
|
|
36
|
-
* - Statistics tracking shows total calls vs unique snapshots
|
|
37
|
-
* - Configurable maximum number of snapshots
|
|
38
|
-
* - Deep cloning of inputs and outputs to avoid reference issues
|
|
39
|
-
* - Proper function serialization for unit test generation
|
|
40
|
-
* - Browser console integration for easy access (development only)
|
|
41
|
-
* - Automatic cleanup when no collected data remains
|
|
42
|
-
*/
|
|
43
|
-
interface CollectedData {
|
|
44
|
-
id: string;
|
|
45
|
-
timestamp: number;
|
|
46
|
-
args: any[];
|
|
47
|
-
result: any;
|
|
48
|
-
}
|
|
49
|
-
interface CollectionStore {
|
|
50
|
-
functionName: string;
|
|
51
|
-
data: CollectedData[];
|
|
52
|
-
totalCalls: number;
|
|
53
|
-
duplicateSkips: number;
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* Decorator that collects unique input/output snapshots for a function during runtime.
|
|
57
|
-
* Useful for generating unit test data from actual application usage.
|
|
58
|
-
*
|
|
59
|
-
* Uses currying pattern: withInputOutputCollection(config)(functionToDecorate)
|
|
60
|
-
*
|
|
61
|
-
* @param options - Configuration options for the collector
|
|
62
|
-
* @returns Function that takes the function to decorate and returns the decorated function
|
|
63
|
-
*/
|
|
64
|
-
export declare function withInputOutputCollection<TFunction extends (...args: any[]) => any>(options?: {
|
|
65
|
-
/** Maximum number of unique snapshots to collect (default: 100) */
|
|
66
|
-
maxSnapshots?: number;
|
|
67
|
-
/** Custom equality function for comparing arguments (default: deep equality) */
|
|
68
|
-
equalityFn?: (a: any[], b: any[]) => boolean;
|
|
69
|
-
/** Optional custom function name (defaults to function.name) */
|
|
70
|
-
functionName?: string;
|
|
71
|
-
}): (originalFunction: TFunction) => TFunction;
|
|
72
|
-
/**
|
|
73
|
-
* Prints all collected input/output data to the console.
|
|
74
|
-
* This function is attached to the window object for easy access in the browser.
|
|
75
|
-
*/
|
|
76
|
-
export declare function printCollectedInfo(): void;
|
|
77
|
-
/**
|
|
78
|
-
* Returns all collected data as a serializable object.
|
|
79
|
-
* Useful for exporting test data programmatically.
|
|
80
|
-
*/
|
|
81
|
-
export declare function getCollectedData(): Record<string, CollectionStore>;
|
|
82
|
-
/**
|
|
83
|
-
* Clears all collected data.
|
|
84
|
-
* Useful for resetting the collection state.
|
|
85
|
-
* Removes window utilities if no data remains.
|
|
86
|
-
*/
|
|
87
|
-
export declare function clearCollectedData(functionName?: string): void;
|
|
88
|
-
/**
|
|
89
|
-
* Completely cleans up the input/output collector.
|
|
90
|
-
* Clears all data and removes window utilities.
|
|
91
|
-
* Useful for cleanup in test environments or when the collector is no longer needed.
|
|
92
|
-
*/
|
|
93
|
-
export declare function cleanup(): void;
|
|
94
|
-
/**
|
|
95
|
-
* Exports collected data as JSON string with proper function serialization.
|
|
96
|
-
* Functions are represented as `[[Function - {functionName}]]` strings for easy replacement in unit tests.
|
|
97
|
-
*
|
|
98
|
-
* Example output:
|
|
99
|
-
* ```json
|
|
100
|
-
* {
|
|
101
|
-
* "buildHighchartsOptions": {
|
|
102
|
-
* "functionName": "buildHighchartsOptions",
|
|
103
|
-
* "data": [{
|
|
104
|
-
* "args": [{ "onBeforeRender": "[[Function - customRenderer]]" }],
|
|
105
|
-
* "result": { "chart": { "type": "line" } }
|
|
106
|
-
* }]
|
|
107
|
-
* }
|
|
108
|
-
* }
|
|
109
|
-
* ```
|
|
110
|
-
*
|
|
111
|
-
* Useful for saving test data to files.
|
|
112
|
-
*/
|
|
113
|
-
export declare function exportCollectedDataAsJson(): string;
|
|
114
|
-
/**
|
|
115
|
-
* Parses JSON data exported by exportCollectedDataAsJson and provides a function map for mocking.
|
|
116
|
-
* This is a utility function for unit tests to easily replace function placeholders with mocks.
|
|
117
|
-
*
|
|
118
|
-
* @param jsonData - The JSON string exported by exportCollectedDataAsJson
|
|
119
|
-
* @returns Object containing parsed data and a list of function placeholders found
|
|
120
|
-
*/
|
|
121
|
-
export declare function parseCollectedDataFromJson(jsonData: string): {
|
|
122
|
-
data: Record<string, CollectionStore>;
|
|
123
|
-
functionPlaceholders: string[];
|
|
124
|
-
};
|
|
125
|
-
export {};
|