@sisense/sdk-ui 2.10.0 → 2.11.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.
Files changed (102) hide show
  1. package/dist/ai.cjs +15 -15
  2. package/dist/ai.js +408 -401
  3. package/dist/analytics-composer/node.cjs +1 -1
  4. package/dist/analytics-composer/node.js +17 -17
  5. package/dist/analytics-composer.cjs +1 -1
  6. package/dist/analytics-composer.js +6 -6
  7. package/dist/{derive-chart-family-B1on_xkS.cjs → derive-chart-family-BauaWEEc.cjs} +49 -49
  8. package/dist/{derive-chart-family-BllGhqsW.js → derive-chart-family-BhAFg8OE.js} +10056 -9990
  9. package/dist/{dimensions-D-Z9sitz.js → dimensions-Bk74slQe.js} +1 -1
  10. package/dist/{dimensions-BYqdB-Q8.cjs → dimensions-DCxjxuyH.cjs} +1 -1
  11. package/dist/{execute-query-CGLL9vXX.js → execute-query-CxMSGp-J.js} +41 -40
  12. package/dist/{execute-query-CABqVn7C.cjs → execute-query-uQ2s1ZNz.cjs} +1 -1
  13. package/dist/index.cjs +22 -22
  14. package/dist/index.js +11201 -10704
  15. package/dist/index.umd.js +312 -311
  16. package/dist/packages/sdk-ui/src/ai/chart/nlq-chart-widget.d.ts +7 -1
  17. package/dist/packages/sdk-ui/src/app/client-application.d.ts +2 -2
  18. package/dist/packages/sdk-ui/src/calendar-heatmap-chart.d.ts +17 -3
  19. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/constants.d.ts +67 -36
  20. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/data-options/data-options.d.ts +2 -0
  21. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/data.d.ts +1 -0
  22. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/highchart-options-builder/options/extras-options.d.ts +1 -2
  23. 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 +14 -7
  24. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/calendar-heatmap-charts-grid.d.ts +9 -1
  25. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/calendar-heatmap.d.ts +2 -4
  26. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/calendar-pagination/calendar-pagination.d.ts +2 -1
  27. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/helpers/sizing-helpers.d.ts +6 -17
  28. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/renderer/helpers/view-helpers.d.ts +3 -1
  29. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/utils/calendar-utils.d.ts +33 -0
  30. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/utils/index.d.ts +2 -0
  31. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/calendar-heatmap-chart/utils/with-calendar-heatmap-data-coloring.d.ts +17 -0
  32. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/funnel-chart/alerts/index.d.ts +5 -0
  33. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/funnel-chart/data/index.d.ts +21 -0
  34. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/funnel-chart/data-options/index.d.ts +32 -0
  35. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/funnel-chart/design-options/index.d.ts +17 -0
  36. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/funnel-chart/funnel-chart-builder.d.ts +2 -0
  37. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/funnel-chart/highchart-options/highcharts-options-builder.d.ts +2 -0
  38. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/funnel-chart/types.d.ts +12 -0
  39. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/helpers/data-options.d.ts +2 -2
  40. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/sunburst-chart/alerts/index.d.ts +1 -0
  41. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/sunburst-chart/data/index.d.ts +7 -0
  42. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/sunburst-chart/data-options/index.d.ts +11 -0
  43. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/sunburst-chart/design-options/index.d.ts +6 -0
  44. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/sunburst-chart/highchart-options/highcharts-options-builder.d.ts +2 -0
  45. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/sunburst-chart/sunburst-chart-builder.d.ts +2 -0
  46. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/sunburst-chart/types.d.ts +12 -0
  47. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/treemap-chart/alerts/index.d.ts +1 -0
  48. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/treemap-chart/data/index.d.ts +7 -0
  49. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/treemap-chart/data-options/index.d.ts +11 -0
  50. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/treemap-chart/design-options/index.d.ts +6 -0
  51. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/treemap-chart/highchart-options/highcharts-options-builder.d.ts +2 -0
  52. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/treemap-chart/treemap-chart-builder.d.ts +2 -0
  53. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/categoricals/treemap-chart/types.d.ts +12 -0
  54. package/dist/packages/sdk-ui/src/chart/restructured-charts/highchart-based-charts/types.d.ts +1 -1
  55. package/dist/packages/sdk-ui/src/chart/restructured-charts/types.d.ts +9 -8
  56. package/dist/packages/sdk-ui/src/chart-data-options/types.d.ts +3 -3
  57. package/dist/packages/sdk-ui/src/chart-options-processor/cartesian/utils/series-processor.d.ts +19 -0
  58. package/dist/packages/sdk-ui/src/chart-options-processor/chart-options-service.d.ts +3 -3
  59. package/dist/packages/sdk-ui/src/chart-options-processor/series-labels.d.ts +19 -0
  60. package/dist/packages/sdk-ui/src/chart-options-processor/translations/boxplot/boxplot-plot-options.d.ts +2 -2
  61. package/dist/packages/sdk-ui/src/chart-options-processor/translations/design-options.d.ts +26 -4
  62. package/dist/packages/sdk-ui/src/chart-options-processor/translations/funnel-plot-options.d.ts +2 -2
  63. package/dist/packages/sdk-ui/src/chart-options-processor/translations/funnel-series.d.ts +8 -0
  64. package/dist/packages/sdk-ui/src/chart-options-processor/translations/pie-plot-options.d.ts +2 -2
  65. package/dist/packages/sdk-ui/src/chart-options-processor/translations/scatter-series.d.ts +2 -1
  66. package/dist/packages/sdk-ui/src/chart-options-processor/translations/sunburst/sunburst-options.d.ts +78 -0
  67. package/dist/packages/sdk-ui/src/chart-options-processor/translations/tooltip-utils.d.ts +6 -5
  68. package/dist/packages/sdk-ui/src/chart-options-processor/translations/types.d.ts +2 -2
  69. package/dist/packages/sdk-ui/src/chart-options-processor/translations/value-label-section.d.ts +14 -11
  70. package/dist/packages/sdk-ui/src/common/components/modal/modal-context.d.ts +1 -2
  71. package/dist/packages/sdk-ui/src/dashboard/components/jtd-dashboard.d.ts +5 -4
  72. package/dist/packages/sdk-ui/src/dashboard/dashboard-helpers.d.ts +109 -0
  73. package/dist/packages/sdk-ui/src/dashboard/hooks/index.d.ts +7 -0
  74. package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/index.d.ts +20 -5
  75. package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-config-transformers.d.ts +85 -0
  76. package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-filters.d.ts +3 -2
  77. package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-formatters.d.ts +64 -2
  78. package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-handlers.d.ts +4 -5
  79. package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-menu.d.ts +1 -0
  80. package/dist/packages/sdk-ui/src/dashboard/hooks/jtd/jtd-types.d.ts +260 -5
  81. package/dist/packages/sdk-ui/src/dashboard/hooks/use-dashboard-header-toolbar.d.ts +7 -0
  82. package/dist/packages/sdk-ui/src/dashboard/hooks/use-edit-mode-toolbar.d.ts +3 -0
  83. package/dist/packages/sdk-ui/src/dashboard/hooks/use-jtd-widget.d.ts +68 -0
  84. package/dist/packages/sdk-ui/src/dashboard/hooks/use-jtd.d.ts +33 -7
  85. package/dist/packages/sdk-ui/src/dashboard/hooks/use-tabber.d.ts +13 -0
  86. package/dist/packages/sdk-ui/src/dashboard/index.d.ts +1 -0
  87. package/dist/packages/sdk-ui/src/filters/components/filter-editor-popover/utils.d.ts +1 -3
  88. package/dist/packages/sdk-ui/src/index.d.ts +9 -1
  89. package/dist/packages/sdk-ui/src/models/dashboard/translate-dashboard-utils.d.ts +25 -2
  90. package/dist/packages/sdk-ui/src/models/dashboard/types.d.ts +8 -4
  91. package/dist/packages/sdk-ui/src/props.d.ts +0 -6
  92. package/dist/packages/sdk-ui/src/types.d.ts +195 -21
  93. package/dist/packages/sdk-ui/src/utils/create-level-attribute.d.ts +11 -0
  94. package/dist/packages/sdk-ui/src/widget-by-id/translate-widget-style-options.d.ts +9 -0
  95. package/dist/packages/sdk-ui/src/widget-by-id/types.d.ts +45 -72
  96. package/dist/{types-Ds0KtTJF.cjs → types-DhvOgfXa.cjs} +1 -1
  97. package/dist/{types-BRtWk8uC.js → types-Dxieyr4A.js} +1 -1
  98. package/dist/{use-common-filters-D8tEa9zb.js → use-common-filters-DJyYvdev.js} +17387 -16944
  99. package/dist/{use-common-filters-hw1WKPCY.cjs → use-common-filters-Qj9249s0.cjs} +227 -226
  100. package/dist/{widget-composer-DL0xPtlC.js → widget-composer-azihIMsw.js} +3 -3
  101. package/dist/{widget-composer-B7zeAa_D.cjs → widget-composer-omIEhWNL.cjs} +1 -1
  102. package/package.json +11 -16
@@ -1,5 +1,6 @@
1
1
  import { DashboardProps } from './types';
2
2
  import { Filter, FilterRelations } from '@sisense/sdk-data';
3
+ import type { JumpToDashboardConfig } from './hooks/jtd/jtd-types';
3
4
  /**
4
5
  * Creates a new dashboard instance with its filters replaced by a new set of filters.
5
6
  *
@@ -107,3 +108,111 @@ export declare const removeFilter: (dashboard: DashboardProps, filterToRemove: F
107
108
  * @returns A new dashboard instance with the specified filters removed.
108
109
  */
109
110
  export declare const removeFilters: (dashboard: DashboardProps, filtersToRemove: Filter[]) => DashboardProps;
111
+ /**
112
+ * Creates a new `DashboardProps` instance with JTD (Jump To Dashboard) configuration applied to a single widget.
113
+ *
114
+ * Jump To Dashboard (JTD) allows users to navigate from one dashboard to another when interacting with widgets,
115
+ * such as clicking on chart data points or using context menus. This function applies JTD configuration to a specific
116
+ * widget in a dashboard, enabling jump-to-dashboard functionality.
117
+ *
118
+ * This function does not modify the original dashboard; instead, it returns a new `DashboardProps` instance with the JTD
119
+ * configuration applied. If the specified widget does not exist in the dashboard, the function returns the original
120
+ * `DashboardProps` unchanged and logs a warning to the console.
121
+ *
122
+ * @example
123
+ * Apply JTD configuration to a dashboard widget.
124
+ * ```ts
125
+ * const jtdConfig: JumpToDashboardConfig = {
126
+ * targets: [{ id: 'dashboardId1', caption: 'Analytics Dashboard' }],
127
+ * interaction: {
128
+ * triggerMethod: 'rightclick',
129
+ * contextMenuCaption: 'Jump to Analytics'
130
+ * }
131
+ * };
132
+ *
133
+ * const updatedDashboard = dashboardHelpers.applyJtdConfig(dashboard, 'widgetId3', jtdConfig);
134
+ * ```
135
+ *
136
+ * @param dashboard - The original dashboard to modify. Must be a valid `DashboardProps` object containing the target widget.
137
+ * @param widgetOid - The unique identifier (OID) of the widget to apply JTD configuration to. Must match an existing widget ID in the dashboard.
138
+ * @param config - The JTD configuration to apply.
139
+ *
140
+ * @returns A new `DashboardProps` instance with the JTD configuration applied to the specified widget. If the widget doesn't exist, returns the original dashboard unchanged.
141
+ *
142
+ * @group Dashboard Utilities
143
+ */
144
+ export declare const applyJtdConfig: (dashboard: DashboardProps, widgetOid: string, config: JumpToDashboardConfig) => DashboardProps;
145
+ /**
146
+ * Creates a new `DashboardProps` instance with JTD (Jump To Dashboard) configurations applied to multiple widgets in a single operation.
147
+ *
148
+ * Jump To Dashboard (JTD) allows users to navigate from one dashboard to another when interacting with widgets.
149
+ * This function efficiently applies JTD configurations to multiple widgets in a single operation.
150
+ *
151
+ * This function does not modify the original dashboard; instead, it returns a new `DashboardProps` instance with all valid
152
+ * JTD configurations applied. Configurations for non-existent widgets are automatically filtered out, and warnings
153
+ * are logged to the console for invalid widget OIDs.
154
+ *
155
+ * @example
156
+ * Apply a variety of Jump To Dashboard configuration options to multiple widgets in a single operation.
157
+ * ```ts
158
+ * import { dashboardHelpers } from '@sisense/sdk-ui';
159
+ *
160
+ * const dashboard: DashboardProps = {
161
+ * title: 'Executive Dashboard',
162
+ * widgets: [
163
+ * { id: 'widgetId1', widgetType: 'chart', chartType: 'column', dataOptions: {...} },
164
+ * { id: 'widgetId2', widgetType: 'chart', chartType: 'pie', dataOptions: {...} },
165
+ * { id: 'widgetId3', widgetType: 'table', dataOptions: {...} }
166
+ * ]
167
+ * };
168
+ *
169
+ * const jtdConfigs = {
170
+ * 'widgetId1': {
171
+ * enabled: true,
172
+ * targets: [{ id: 'dashboardId1', caption: 'Sales Breakdown' }],
173
+ * interaction: {
174
+ * triggerMethod: 'rightclick'
175
+ * }
176
+ * },
177
+ * 'widgetId2': {
178
+ * targets: [{ id: 'dashboardId2', caption: 'Revenue Analysis' }],
179
+ * interaction: {
180
+ * triggerMethod: 'click',
181
+ * contextMenuCaption: 'Analyze Revenue'
182
+ * }
183
+ * },
184
+ * 'widgetId3': {
185
+ * enabled: true,
186
+ * targets: [
187
+ * { id: 'dashboardId3', caption: 'Customer Details' },
188
+ * { id: 'dashboardId4', caption: 'Product Analytics' }
189
+ * ],
190
+ * interaction: {
191
+ * triggerMethod: 'rightclick'
192
+ * }
193
+ * }
194
+ * };
195
+ *
196
+ * const updatedDashboard = dashboardHelpers.applyJtdConfigs(dashboard, jtdConfigs);
197
+ * ```
198
+ *
199
+ * @example Error handling
200
+ * Batch apply JTD configurations with error handling.
201
+ * ```ts
202
+ * const configsWithInvalidWidget = {
203
+ * 'widgetId1': { targets: [{ id: 'dashboardId1', caption: 'Target' }] },
204
+ * 'invalidWidgetId': { targets: [{ id: 'dashboardId2', caption: 'Other' }] } // Will be filtered out
205
+ * };
206
+ *
207
+ * const result = dashboardHelpers.applyJtdConfigs(dashboard, configsWithInvalidWidget);
208
+ * // Console warning: "Widgets with OIDs [invalidWidgetId] not found in dashboard..."
209
+ * // Only 'widgetId1' gets the JTD configuration applied
210
+ * ```
211
+ *
212
+ * @param dashboard - The original dashboard to modify. Must be a valid `DashboardProps` object with widgets to configure.
213
+ * @param jtdConfigs - An object mapping widget OIDs (keys) to their respective JTD configurations (values).
214
+ * @returns A new `DashboardProps` instance with all valid JTD configurations applied to their respective widgets. Invalid widget configurations are skipped and warnings are logged.
215
+ *
216
+ * @group Dashboard Utilities
217
+ */
218
+ export declare const applyJtdConfigs: (dashboard: DashboardProps, jtdConfigs: Record<string, JumpToDashboardConfig>) => DashboardProps;
@@ -0,0 +1,7 @@
1
+ export { type JumpToDashboardConfig, type JumpToDashboardConfigForPivot, type JtdTarget, type TriggerMethod, } from './jtd';
2
+ /**
3
+ * Internal JTD hook for dashboard composition
4
+ * @internal
5
+ */
6
+ export { useJtdInternal } from './use-jtd';
7
+ export { useJtdWidget } from './use-jtd-widget';
@@ -1,5 +1,20 @@
1
- export { getFiltersFromDataPoint, getFormulaContextFilters, filterByAllowedDimensions, handleFormulaDuplicateFilters, mergeJtdFilters, } from './jtd-filters';
2
- export { getJtdClickHandler, getJtdClickHandlerForMultiplePoints, handleDataPointClick, handleTextWidgetClick, } from './jtd-handlers';
3
- export { getJumpToDashboardMenuItem, getJumpToDashboardMenuItemForMultiplePoints, } from './jtd-menu';
4
- export { addPointerCursorToChart, applyClickNavigationForChart, applyClickNavigationForText, applyClickNavigationForPivot, applyRightClickNavigation, applyRightClickNavigationForPivot, applyPivotLinkStyling, addJtdIconToHeader, } from './jtd-widget-transforms';
5
- export { type JtdCoreData, type JtdContext, type JtdActions, type JtdClickHandlerData, type JtdWidgetTransformConfig, type JtdDataPointClickEvent, type JtdMenuItem, } from './jtd-types';
1
+ /**
2
+ * Jump To Dashboard configuration for regular widgets
3
+ * @group Dashboards
4
+ */
5
+ export { type JumpToDashboardConfig } from './jtd-types';
6
+ /**
7
+ * Jump To Dashboard configuration for pivot widgets
8
+ * @group Dashboards
9
+ */
10
+ export { type JumpToDashboardConfigForPivot } from './jtd-types';
11
+ /**
12
+ * Target dashboard configuration for Jump To Dashboard
13
+ * @group Dashboards
14
+ */
15
+ export { type JtdTarget } from './jtd-types';
16
+ /**
17
+ * Trigger method for Jump To Dashboard interactions
18
+ * @group Dashboards
19
+ */
20
+ export { type TriggerMethod } from './jtd-types';
@@ -0,0 +1,85 @@
1
+ import { WidgetProps } from '../../../props';
2
+ import type { JtdConfig, JtdTarget, JumpToDashboardConfig, JumpToDashboardConfigForPivot, PivotDimId } from './jtd-types';
3
+ import type { Attribute, Dimension, Measure } from '@sisense/sdk-data';
4
+ import { PivotTableDataOptions } from '../../../index-typedoc';
5
+ import type { Panel } from '../../../widget-by-id/types';
6
+ /**
7
+ * Transform legacy JtdConfig to new JumpToDashboardConfig format
8
+ *
9
+ * @param jtdConfig - The legacy JTD configuration
10
+ * @returns Transformed Jump To Dashboard configuration
11
+ * @internal
12
+ */
13
+ export declare const transformJtdConfigToJumpToDashboardConfig: (jtdConfig: JtdConfig) => JumpToDashboardConfig;
14
+ export declare const isPivotJumpToDashboardConfig: (config: JumpToDashboardConfig | JumpToDashboardConfigForPivot) => config is JumpToDashboardConfigForPivot;
15
+ /**
16
+ * Transform common part of public JumpToDashboardConfig to inner JtdConfig format
17
+ *
18
+ * @param jumpConfig - The new Jump To Dashboard configuration
19
+ * @returns Transformed legacy JTD configuration
20
+ * @internal
21
+ */
22
+ export declare const transformJumpToDashboardConfigToJtdConfigCommon: (jumpConfig: JumpToDashboardConfig | JumpToDashboardConfigForPivot) => Omit<JtdConfig, 'jumpTargets'>;
23
+ export declare const transformJumpToDashboardConfigToJtdConfigForPivot: (jumpConfig: JumpToDashboardConfigForPivot, dataOptions: PivotTableDataOptions) => JtdConfig;
24
+ /**
25
+ * Type guard to check if a config is a JumpToDashboardConfig
26
+ *
27
+ * @param config - The configuration to check
28
+ * @returns True if the config is a JumpToDashboardConfig
29
+ * @internal
30
+ */
31
+ export declare const isJumpToDashboardConfig: (config: JtdConfig | JumpToDashboardConfig | JumpToDashboardConfigForPivot) => config is JumpToDashboardConfig | JumpToDashboardConfigForPivot;
32
+ /**
33
+ * Normalize configuration to JumpToDashboardConfig format
34
+ * Accepts both legacy JtdConfig and new JumpToDashboardConfig
35
+ *
36
+ * @internal
37
+ * @param config - Either JtdConfig or JumpToDashboardConfig
38
+ * @returns Normalized JumpToDashboardConfig
39
+ */
40
+ export declare const normalizeToJumpToDashboardConfig: (config: JtdConfig | JumpToDashboardConfig) => JumpToDashboardConfig;
41
+ /**
42
+ * Normalize configuration to legacy JtdConfig format
43
+ * Accepts both legacy JtdConfig and new JumpToDashboardConfig
44
+ *
45
+ * @internal
46
+ * @param config - Either JtdConfig or JumpToDashboardConfig
47
+ * @returns Normalized JtdConfig
48
+ */
49
+ export declare const normalizeToJtdConfig: (config: JtdConfig | JumpToDashboardConfig | JumpToDashboardConfigForPivot, widgetProps: WidgetProps) => JtdConfig;
50
+ /**
51
+ * Enhanced matching strategy that considers location, expression, level, and other properties
52
+ * @param dimension - The dimension or measure object
53
+ * @param panels - Constructed panels with PanelItems
54
+ * @returns PivotDimId like "columns.0", "rows.1", "values.0"
55
+ * @internal
56
+ */
57
+ export declare const dimensionToPivotDimId: (dimension: Attribute | Measure | {
58
+ dimension: Attribute;
59
+ location: 'row' | 'column' | 'value';
60
+ }, panels: Panel[]) => PivotDimId | null;
61
+ /**
62
+ * Convert PivotDimId back to Dimension/Measure using widget structure
63
+ * @param pivotDimId - PivotDimId like "columns.0", "rows.1", "values.0"
64
+ * @param widgetStructure - Widget structure with rows/columns/values arrays
65
+ * @returns The dimension or measure object, or null if not found
66
+ * @internal
67
+ */
68
+ export declare const pivotDimIdToDimension: (pivotDimId: PivotDimId, widgetStructure: {
69
+ rows?: Array<Dimension | Measure>;
70
+ columns?: Array<Dimension | Measure>;
71
+ values?: Array<Dimension | Measure>;
72
+ }) => Dimension | Measure | null;
73
+ /**
74
+ * Convert Map-based pivot targets to array-based pivot targets (for internal JtdConfig)
75
+ * @param targetsMap - Map of dimensions/measures to targets
76
+ * @param panels - Widget metadata panels (source of truth for dimension positions)
77
+ * @returns Array of targets with pivotDimensions
78
+ * @internal
79
+ */
80
+ export declare const mapTargetsToArrayTargets: (targetsMap: Map<Attribute | {
81
+ dimension: Attribute;
82
+ location: 'row' | 'column' | 'value';
83
+ } | Measure, JtdTarget[]>, panels: Panel[]) => Array<JtdTarget & {
84
+ pivotDimensions?: PivotDimId[];
85
+ }>;
@@ -1,9 +1,9 @@
1
1
  import { type Filter } from '@sisense/sdk-data';
2
2
  import { WidgetProps } from '../../../props.js';
3
3
  import { DataPoint, ScatterDataPoint } from '../../../types';
4
- import { JtdConfig } from '../../../widget-by-id/types';
4
+ import { JtdConfig } from './jtd-types';
5
5
  /**
6
- * Jump to Dashboard (JTD) Filter Merging Logic:
6
+ * Jump To Dashboard (JTD) Filter Merging Logic:
7
7
  *
8
8
  * When a user clicks on a datapoint to open a JTD modal, multiple types of filters are merged:
9
9
  *
@@ -57,6 +57,7 @@ import { JtdConfig } from '../../../widget-by-id/types';
57
57
  * @param clickedWidget - The clicked widget
58
58
  * @param jtdConfig - The JTD configuration
59
59
  * @returns Array of formula context filters
60
+ * @internal
60
61
  */
61
62
  export declare const getFormulaContextFilters: (clickedWidget: WidgetProps, jtdConfig: JtdConfig) => Filter[];
62
63
  /**
@@ -1,5 +1,67 @@
1
1
  import type { CustomDataCellFormatter, CustomHeaderCellFormatter } from '../../../pivot-table/formatters/types';
2
- import { JtdConfig } from '../../../widget-by-id/types';
2
+ import { JtdConfig, JtdTarget } from './jtd-types';
3
+ import { PivotTableDataPoint } from '../../../types';
4
+ /**
5
+ * Check if a formatter cell ID is actionable for JTD
6
+ * Used by hyperlink formatters with cell IDs like "rows.0", "columns.1", "values.2"
7
+ *
8
+ * @param jtdConfig - The JTD configuration
9
+ * @param cellId - The cell ID from formatters (e.g., "rows.0")
10
+ * @returns Object with actionable status and matching target
11
+ * @internal
12
+ */
13
+ export declare function getPivotFormatterCellActionability(jtdConfig: JtdConfig, cellId: string): {
14
+ isActionable: boolean;
15
+ matchingTarget?: JtdTarget;
16
+ };
17
+ /**
18
+ * Check if a click handler pivot point is actionable for JTD
19
+ * Used by click handlers with pivot data points containing custom dimension IDs
20
+ *
21
+ * @param jtdConfig - The JTD configuration
22
+ * @param pivotPoint - The pivot data point from click handlers
23
+ * @returns Object with actionable status and matching target
24
+ * @internal
25
+ */
26
+ export declare function isPivotClickHandlerActionable(jtdConfig: JtdConfig, pivotPoint: PivotTableDataPoint): {
27
+ isActionable: boolean;
28
+ matchingTarget?: JtdTarget;
29
+ };
30
+ /**
31
+ * Find all actionable jump targets for a pivot point (for right-click menus)
32
+ * Used by right-click handlers that need to show multiple targets
33
+ *
34
+ * @param jtdConfig - The JTD configuration
35
+ * @param pivotPoint - The pivot data point from click handlers
36
+ * @returns Object with actionable status and all matching targets
37
+ * @internal
38
+ *
39
+ * @example
40
+ * ```typescript
41
+ * // Usage in right-click menu handler for pivot tables
42
+ * const onPivotRightClick = (pivotPoint: PivotTableDataPoint) => {
43
+ * const { isActionable, matchingTargets } = findAllActionablePivotTargets(jtdConfig, pivotPoint);
44
+ *
45
+ * if (!isActionable) {
46
+ * return; // No menu - headers are not clickable or no valid targets
47
+ * }
48
+ *
49
+ * // Only valid targets are returned:
50
+ * // - Targets with matching pivot dimensions for this cell
51
+ * // - NEVER targets with non-matching pivot dimensions
52
+ * const menuItems = matchingTargets.map(target => ({
53
+ * caption: target.caption,
54
+ * onClick: () => handleJumpToDashboard(target, pivotPoint)
55
+ * }));
56
+ *
57
+ * openContextMenu({ items: menuItems });
58
+ * };
59
+ * ```
60
+ */
61
+ export declare function getPivotTargetActionability(jtdConfig: JtdConfig, pivotPoint: PivotTableDataPoint): {
62
+ isActionable: boolean;
63
+ matchingTargets: JtdTarget[];
64
+ };
3
65
  /**
4
66
  * Creates a data cell formatter that applies hyperlink styling for JTD navigation
5
67
  *
@@ -12,7 +74,7 @@ export declare function createJtdHyperlinkDataCellFormatter(hyperlinkColor: stri
12
74
  * Creates a header cell formatter that applies hyperlink styling for JTD navigation
13
75
  *
14
76
  * @param hyperlinkColor - The color to use for hyperlink text (uses theme's hyperlinkColor or defaults to DEFAULT_HYPERLINK_COLOR)
15
- * @param jtdConfig - JTD configuration containing drill targets
77
+ * @param jtdConfig - JTD configuration containing jump targets
16
78
  * @returns A header cell formatter that applies hyperlink styling to matching header cells
17
79
  */
18
80
  export declare function createJtdHyperlinkHeaderCellFormatter(hyperlinkColor: string, jtdConfig: JtdConfig): CustomHeaderCellFormatter;
@@ -1,13 +1,12 @@
1
1
  import { type Filter } from '@sisense/sdk-data';
2
2
  import { WidgetProps } from '../../../props.js';
3
3
  import { PivotTableDataPoint, DataPoint } from '../../../types';
4
- import { JtdConfig } from '../../../widget-by-id/types';
4
+ import { JtdActions, JtdClickHandlerData, JtdConfig, JtdContext, JtdCoreData, JtdDataPointClickEvent } from './jtd-types';
5
5
  import { OpenModalFn } from '../../../common/components/modal/modal-context';
6
- import { JtdCoreData, JtdContext, JtdActions, JtdClickHandlerData, JtdDataPointClickEvent } from './jtd-types';
7
6
  /**
8
7
  * Get the JTD click handler for a specific data point of the specific widget
9
8
  *
10
- * @param data - Core data with drill target (config, drill target, widget props, point)
9
+ * @param data - Core data with jump target (config, jump target, widget props, point)
11
10
  * @param context - Context data (filters)
12
11
  * @param actions - Action functions
13
12
  * @returns The JTD click handler
@@ -17,7 +16,7 @@ export declare const getJtdClickHandler: (data: JtdClickHandlerData, context: Jt
17
16
  /**
18
17
  * Get the JTD click handler for multiple data points
19
18
  *
20
- * @param data - Core data with drill target (config, drill target, widget props, points)
19
+ * @param data - Core data with jump target (config, jump target, widget props, points)
21
20
  * @param context - Context data (filters)
22
21
  * @param actions - Action functions
23
22
  * @returns The JTD click handler
@@ -45,7 +44,7 @@ export declare const convertPivotToDataPoint: (pivotPoint: PivotTableDataPoint)
45
44
  /**
46
45
  * Handle pivot table data point click
47
46
  *
48
- * @param data - Core data with drill target (config, drill target, widget props, pivot point)
47
+ * @param data - Core data with jump target (config, jump target, widget props, pivot point)
49
48
  * @param context - Context data (filters)
50
49
  * @param actions - Action functions
51
50
  * @param eventData - Event-related data
@@ -1,4 +1,5 @@
1
1
  import { JtdCoreData, JtdContext, JtdActions } from './jtd-types';
2
+ export declare const jumpToDashboardMenuId = "jump-to-dashboard-menu";
2
3
  /**
3
4
  * Get the JTD menu item for a specific data point of the specific widget
4
5
  *
@@ -1,7 +1,7 @@
1
- import { type Filter } from '@sisense/sdk-data';
1
+ import { Attribute, Measure, type Filter } from '@sisense/sdk-data';
2
2
  import { WidgetProps } from '../../../props.js';
3
3
  import { DataPoint } from '../../../types';
4
- import { JtdConfig, JtdDrillTarget } from '../../../widget-by-id/types';
4
+ import { DashboardConfig, DashboardProps } from '../../../dashboard/types';
5
5
  import { OpenModalFn } from '../../../common/components/modal/modal-context';
6
6
  import { OpenMenuFn } from '../../../common/components/menu/types.js';
7
7
  /**
@@ -44,6 +44,8 @@ export interface JtdContext {
44
44
  dashboardFilters: Filter[];
45
45
  /** The original widget filters */
46
46
  originalWidgetFilters: Filter[];
47
+ /** Extra filters to be applied with highest priority */
48
+ extraFilters?: Filter[];
47
49
  }
48
50
  /**
49
51
  * Base interface for JTD action functions
@@ -59,13 +61,13 @@ export interface JtdActions {
59
61
  translate?: (key: string) => string;
60
62
  }
61
63
  /**
62
- * Extended core data for JTD click handlers that includes drill target
64
+ * Extended core data for JTD click handlers that includes jump target
63
65
  *
64
66
  * @internal
65
67
  */
66
68
  export interface JtdClickHandlerData extends JtdCoreData {
67
- /** The drill target */
68
- drillTarget: JtdDrillTarget;
69
+ /** The jump target */
70
+ jumpTarget: JtdTarget;
69
71
  }
70
72
  /**
71
73
  * Configuration for widget transforms, combining config and context
@@ -79,6 +81,8 @@ export interface JtdWidgetTransformConfig {
79
81
  dashboardFilters: Filter[];
80
82
  /** The original widget filters */
81
83
  originalWidgetFilters: Filter[];
84
+ /** Extra filters to be applied with highest priority */
85
+ extraFilters?: Filter[];
82
86
  }
83
87
  /**
84
88
  * Event-related data for handling data point clicks
@@ -91,3 +95,254 @@ export interface JtdDataPointClickEvent {
91
95
  /** Function to get menu item */
92
96
  getJumpToDashboardMenuItem: (coreData: JtdCoreData, context: JtdContext, actions: Pick<JtdActions, 'openModal' | 'translate'>) => JtdMenuItem;
93
97
  }
98
+ /**
99
+ * Configuration for Jump To Dashboard functionality.
100
+ * Allows users to navigate from a widget to another dashboard with contextual filtering.
101
+ */
102
+ export interface JumpToDashboardConfig {
103
+ /**
104
+ * Whether Jump To Dashboard functionality is enabled
105
+ * @default true
106
+ */
107
+ enabled?: boolean;
108
+ /** List of target dashboards that can be navigated to */
109
+ targets: JtdTarget[];
110
+ /** Configuration for user interaction behavior */
111
+ interaction?: {
112
+ /**
113
+ * How users trigger the jump action
114
+ * Note that not all widgets support both trigger methods
115
+ *
116
+ * @default 'rightclick'
117
+ **/
118
+ triggerMethod?: TriggerMethod;
119
+ /**
120
+ * Caption prefix for jumping action (i.e in context menu)
121
+ * @default 'Jump to'
122
+ */
123
+ captionPrefix?: string;
124
+ /**
125
+ * Whether to show the Jump To Dashboard icon in the toolbar of the source widget
126
+ * @default true
127
+ */
128
+ showIcon?: boolean;
129
+ };
130
+ /**
131
+ * Configuration for the target dashboard display.
132
+ * This configuration will be merged with target dashboard config, having higher priority
133
+ * @default {}
134
+ */
135
+ targetDashboardConfig?: DashboardConfig;
136
+ /** Configuration for filter handling between source and target dashboards */
137
+ filtering?: {
138
+ /**
139
+ * Additional filters to apply to the target dashboard
140
+ *
141
+ * @example
142
+ * const extraFilters = [dashboardProps.filters[0], dashboardProps.widgets[0].filters[0]]
143
+ *
144
+ * @default []
145
+ */
146
+ extraFilters?: Filter[];
147
+ /**
148
+ * Dashboard-level filter dimensions to pass through
149
+ *
150
+ * undefined - include all
151
+ * [] - include nothing
152
+ * [string] - include specific dimensions
153
+ *
154
+ * example: ["[ER.Date (Calendar)]", "[Doctors.Specialty]"]
155
+ * @default undefined
156
+ */
157
+ includeDashboardFilters?: string[];
158
+ /**
159
+ * Widget-level filter dimensions to pass through
160
+ *
161
+ * undefined - include all
162
+ * [] - include nothing
163
+ * [string] - include specific dimensions
164
+ *
165
+ * example: ["[ER.Date (Calendar)]", "[Doctors.Specialty]"]
166
+ * @default undefined
167
+ */
168
+ includeWidgetFilters?: string[];
169
+ /**
170
+ * Whether to merge filters with existing target dashboard filters or replace them
171
+ * @default false
172
+ */
173
+ mergeWithTargetFilters?: boolean;
174
+ };
175
+ /** Configuration for the modal window that will display the target dashboard */
176
+ modal?: {
177
+ /**
178
+ * Width of the modal window
179
+ * @default 85 (when measurementUnit is '%') or 1200 (when measurementUnit is 'px')
180
+ */
181
+ width?: number;
182
+ /**
183
+ * Height of the modal window
184
+ * @default 85 (when measurementUnit is '%') or 800 (when measurementUnit is 'px')
185
+ */
186
+ height?: number;
187
+ /**
188
+ * Unit of measurement for width/height
189
+ * @default 'px'
190
+ */
191
+ measurementUnit?: '%' | 'px';
192
+ };
193
+ }
194
+ /**
195
+ * Configuration for Jump To Dashboard functionality for pivot widgets.
196
+ * Used for pivot widgets, allowing to configure jumping to different dashboard from different dimensions
197
+ * @see {@link JumpToDashboardConfig}
198
+ */
199
+ export interface JumpToDashboardConfigForPivot extends Omit<JumpToDashboardConfig, 'targets'> {
200
+ /**
201
+ * Map of target dashboards for different dimensions/measures
202
+ *
203
+ * @alpha
204
+ * @example
205
+ *
206
+ * const FormulaMeasure = dashboardProps.widgets[0].dataOptions.values[0];
207
+ * const ageRangeAttribute = dashboardProps.widgets[0].dataOptions.rows[1];
208
+ *
209
+ * const targets = new Map([
210
+ * [ageRangeAttribute, [target, target2]],
211
+ * [FormulaMeasure, [target3]],
212
+ * ]);
213
+ *
214
+ */
215
+ targets: Map<Attribute | {
216
+ dimension: Attribute;
217
+ location: 'row' | 'column' | 'value';
218
+ } | Measure, JtdTarget[]>;
219
+ }
220
+ /**
221
+ * Target dashboard for Jump To Dashboard functionality.
222
+ * Supports both dashboard ID reference and in-code dashboard object.
223
+ * @see JumpToDashboardConfig
224
+ * @see DashboardProps
225
+ */
226
+ export type JtdTarget = {
227
+ caption: string;
228
+ id: string;
229
+ } | {
230
+ caption: string;
231
+ dashboard: DashboardProps;
232
+ };
233
+ /**
234
+ * Type guard to check if a jump target contains dashboard props
235
+ * @internal
236
+ */
237
+ export declare const isJumpTargetWithDashboardProps: (target: JtdTarget) => target is {
238
+ caption: string;
239
+ dashboard: DashboardProps;
240
+ };
241
+ /**
242
+ * Type guard to check if a jump target contains dashboard ID
243
+ * @internal
244
+ */
245
+ export declare const isJumpTargetWithId: (target: JtdTarget) => target is {
246
+ caption: string;
247
+ id: string;
248
+ };
249
+ /**
250
+ * @internal
251
+ */
252
+ export type PivotDimType = 'columns' | 'rows' | 'values';
253
+ /**
254
+ * @internal
255
+ */
256
+ export type NonNegativeIntString = Exclude<`${bigint}`, `-${string}`>;
257
+ /**
258
+ * Pivot dimension ID
259
+ * example: "columns.0", "rows.0", "values.0", "columns.1", "rows.1", "values.1", etc.
260
+ * @internal
261
+ */
262
+ export type PivotDimId = `${PivotDimType}.${NonNegativeIntString}`;
263
+ export type JtdTargetDto = {
264
+ caption: string;
265
+ id?: string;
266
+ oid?: string;
267
+ };
268
+ export type JtdPivotTargetDto = JtdTargetDto & {
269
+ pivotDimensions: string[];
270
+ };
271
+ /**
272
+ * Legacy representation of JTD config from Fusion
273
+ * @internal
274
+ */
275
+ export type JtdConfigDto = {
276
+ drilledDashboardPrefix: string;
277
+ drilledDashboardsFolderPrefix: string;
278
+ displayFilterPane: boolean;
279
+ displayDashboardsPane: boolean;
280
+ displayToolbarRow: boolean;
281
+ displayHeaderRow: boolean;
282
+ volatile: boolean;
283
+ hideDrilledDashboards: boolean;
284
+ hideSharedDashboardsForNonOwner: boolean;
285
+ drillToDashboardRightMenuCaption: string;
286
+ drillToDashboardNavigateType: number;
287
+ drillToDashboardNavigateTypePivot: number;
288
+ drillToDashboardNavigateTypeCharts: number;
289
+ drillToDashboardNavigateTypeOthers: number;
290
+ drilledDashboardDisplayType: number;
291
+ dashboardIds: Array<JtdTargetDto | JtdPivotTargetDto>;
292
+ modalWindowResize: boolean;
293
+ modalWindowMeasurement?: 'px' | '%';
294
+ modalWindowWidth?: number;
295
+ modalWindowHeight?: number;
296
+ showFolderNameOnMenuSelection: boolean;
297
+ resetDashFiltersAfterJTD: boolean;
298
+ sameCubeRestriction: boolean;
299
+ showJTDIcon?: boolean;
300
+ sendPieChartMeasureFiltersOnClick: boolean;
301
+ forceZeroInsteadNull: boolean;
302
+ mergeTargetDashboardFilters: boolean;
303
+ drillToDashboardByName: boolean;
304
+ sendBreakByValueFilter: boolean;
305
+ ignoreFiltersSource: boolean;
306
+ sendFormulaFiltersDuplicate?: number | 'none' | undefined;
307
+ enabled?: boolean;
308
+ version?: string;
309
+ includeDashFilterDims?: string[];
310
+ includeWidgetFilterDims?: string[];
311
+ };
312
+ /**
313
+ * Jump To Dashboard action trigger method type
314
+ * click - when user clicks on the widget
315
+ * rightclick - when user right clicks on the widget, opening the context menu
316
+ * @see {@link JumpToDashboardConfig}
317
+ */
318
+ export type TriggerMethod = 'click' | 'rightclick';
319
+ /**
320
+ * @internal
321
+ */
322
+ export type JtdTargetInner = JtdTarget & {
323
+ pivotDimensions?: PivotDimId[];
324
+ };
325
+ /**
326
+ * Internal representation of Jump To Dashboard configuration object.
327
+ * This is the legacy format that includes fields like drilledDashboardPrefix
328
+ * and modalWindowResize that don't have direct equivalents in JumpToDashboardConfig.
329
+ * @internal
330
+ */
331
+ export type JtdConfig = {
332
+ jumpedDashboardPrefix?: string;
333
+ dashboardConfig?: DashboardConfig;
334
+ jumpToDashboardRightMenuCaption?: string;
335
+ navigateType?: TriggerMethod;
336
+ includeDashFilterDims?: string[];
337
+ includeWidgetFilterDims?: string[];
338
+ jumpTargets: Array<JtdTargetInner>;
339
+ modalWindowResize?: boolean;
340
+ modalWindowMeasurement?: 'px' | '%';
341
+ modalWindowWidth?: number;
342
+ modalWindowHeight?: number;
343
+ showJtdIcon?: boolean;
344
+ mergeTargetDashboardFilters?: boolean;
345
+ sendFormulaFiltersDuplicate?: number | 'none' | undefined;
346
+ enabled?: boolean;
347
+ extraFilters?: Filter[];
348
+ };