@datarailsshared/dr_renderer 1.5.107 → 1.5.116
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/package.json +13 -2
- package/src/graph-table-renderer.js +1 -1
- package/src/highcharts_renderer.js +476 -1648
- package/src/index.d.ts +9 -0
- package/src/index.js +8 -0
- package/src/options/builders.js +933 -0
- package/src/options/constants.js +268 -0
- package/src/options/elements.js +377 -0
- package/src/options/helpers.js +34 -0
- package/src/options/index.js +215 -0
- package/src/options/presets.js +388 -0
- package/src/types/graph-table-renderer.d.ts +2 -2
- package/src/types/index.d.ts +11 -1
- package/src/types/options/builders.d.ts +615 -0
- package/src/types/options/constants.d.ts +235 -0
- package/src/types/options/elements.d.ts +456 -0
- package/src/types/options/helpers.d.ts +7 -0
- package/src/types/options/index.d.ts +178 -0
- package/src/types/options/presets.d.ts +98 -0
- package/tests/__snapshots__/suboptions.test.js.snap +5017 -0
- package/tests/options-builder.test.js +1710 -0
- package/tests/suboptions.test.js +322 -0
- package/tsconfig.json +12 -2
- package/tsconfig.tsbuildinfo +1 -7
|
@@ -0,0 +1,615 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Pie tooltip options configuration.
|
|
3
|
+
*/
|
|
4
|
+
export type TooltipPieOptions = {
|
|
5
|
+
/**
|
|
6
|
+
* - Whether tooltips are shown
|
|
7
|
+
*/
|
|
8
|
+
show?: boolean | undefined;
|
|
9
|
+
/**
|
|
10
|
+
* - Show percentage
|
|
11
|
+
*/
|
|
12
|
+
show_percentage?: boolean | undefined;
|
|
13
|
+
/**
|
|
14
|
+
* - Show value
|
|
15
|
+
*/
|
|
16
|
+
show_value?: boolean | undefined;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* Suboption definition structure.
|
|
20
|
+
*/
|
|
21
|
+
export type SuboptionDefinition = {
|
|
22
|
+
/**
|
|
23
|
+
* - CSS class for the category
|
|
24
|
+
*/
|
|
25
|
+
category_class: string;
|
|
26
|
+
/**
|
|
27
|
+
* - Display label for the category
|
|
28
|
+
*/
|
|
29
|
+
category_label: string;
|
|
30
|
+
/**
|
|
31
|
+
* - Type identifier for the category
|
|
32
|
+
*/
|
|
33
|
+
category_type: string;
|
|
34
|
+
/**
|
|
35
|
+
* - UI elements
|
|
36
|
+
*/
|
|
37
|
+
elements?: import("./elements").SuboptionElement[] | undefined;
|
|
38
|
+
/**
|
|
39
|
+
* - Whether category is hidden in UI
|
|
40
|
+
*/
|
|
41
|
+
is_hidden?: boolean | undefined;
|
|
42
|
+
/**
|
|
43
|
+
* - Default value for simple suboptions
|
|
44
|
+
*/
|
|
45
|
+
default_value?: any;
|
|
46
|
+
};
|
|
47
|
+
/**
|
|
48
|
+
* Label options configuration.
|
|
49
|
+
*/
|
|
50
|
+
export type LabelOptions = {
|
|
51
|
+
/**
|
|
52
|
+
* - Whether labels are shown
|
|
53
|
+
*/
|
|
54
|
+
show?: boolean | undefined;
|
|
55
|
+
/**
|
|
56
|
+
* - Whether labels can overlap
|
|
57
|
+
*/
|
|
58
|
+
overlap?: boolean | undefined;
|
|
59
|
+
/**
|
|
60
|
+
* - Whether labels are vertical
|
|
61
|
+
*/
|
|
62
|
+
vertical?: boolean | undefined;
|
|
63
|
+
/**
|
|
64
|
+
* - Font family
|
|
65
|
+
*/
|
|
66
|
+
font_style?: string | undefined;
|
|
67
|
+
/**
|
|
68
|
+
* - Font size
|
|
69
|
+
*/
|
|
70
|
+
font_size?: string | number | undefined;
|
|
71
|
+
/**
|
|
72
|
+
* - Font color
|
|
73
|
+
*/
|
|
74
|
+
font_color?: string | undefined;
|
|
75
|
+
/**
|
|
76
|
+
* - Show value in label
|
|
77
|
+
*/
|
|
78
|
+
show_value?: boolean | undefined;
|
|
79
|
+
/**
|
|
80
|
+
* - Show percentage of x-axis
|
|
81
|
+
*/
|
|
82
|
+
show_out_of_x_axis?: boolean | undefined;
|
|
83
|
+
/**
|
|
84
|
+
* - Show percentage of data series
|
|
85
|
+
*/
|
|
86
|
+
show_out_of_data_series?: boolean | undefined;
|
|
87
|
+
};
|
|
88
|
+
/**
|
|
89
|
+
* Label pie options configuration.
|
|
90
|
+
*/
|
|
91
|
+
export type LabelPieOptions = {
|
|
92
|
+
/**
|
|
93
|
+
* - Whether labels are shown
|
|
94
|
+
*/
|
|
95
|
+
show?: boolean | undefined;
|
|
96
|
+
/**
|
|
97
|
+
* - Whether labels can overlap
|
|
98
|
+
*/
|
|
99
|
+
overlap?: boolean | undefined;
|
|
100
|
+
/**
|
|
101
|
+
* - Use area color for labels
|
|
102
|
+
*/
|
|
103
|
+
use_area_color?: boolean | undefined;
|
|
104
|
+
/**
|
|
105
|
+
* - Font family
|
|
106
|
+
*/
|
|
107
|
+
font_style?: string | undefined;
|
|
108
|
+
/**
|
|
109
|
+
* - Font size
|
|
110
|
+
*/
|
|
111
|
+
font_size?: string | number | undefined;
|
|
112
|
+
/**
|
|
113
|
+
* - Font color
|
|
114
|
+
*/
|
|
115
|
+
font_color?: string | undefined;
|
|
116
|
+
/**
|
|
117
|
+
* - Show value in labels
|
|
118
|
+
*/
|
|
119
|
+
show_value_in_labels?: boolean | undefined;
|
|
120
|
+
/**
|
|
121
|
+
* - Show percentage in labels
|
|
122
|
+
*/
|
|
123
|
+
show_percentage_in_labels?: boolean | undefined;
|
|
124
|
+
};
|
|
125
|
+
/**
|
|
126
|
+
* Tooltip options configuration.
|
|
127
|
+
*/
|
|
128
|
+
export type TooltipOptions = {
|
|
129
|
+
/**
|
|
130
|
+
* - Whether tooltips are shown
|
|
131
|
+
*/
|
|
132
|
+
show?: boolean | undefined;
|
|
133
|
+
/**
|
|
134
|
+
* - Font family
|
|
135
|
+
*/
|
|
136
|
+
font_style?: string | undefined;
|
|
137
|
+
/**
|
|
138
|
+
* - Font size
|
|
139
|
+
*/
|
|
140
|
+
font_size?: string | number | undefined;
|
|
141
|
+
/**
|
|
142
|
+
* - Font color
|
|
143
|
+
*/
|
|
144
|
+
font_color?: string | undefined;
|
|
145
|
+
/**
|
|
146
|
+
* - Show x-axis value
|
|
147
|
+
*/
|
|
148
|
+
show_x_axis?: boolean | undefined;
|
|
149
|
+
/**
|
|
150
|
+
* - Show data series
|
|
151
|
+
*/
|
|
152
|
+
show_data_series?: boolean | undefined;
|
|
153
|
+
/**
|
|
154
|
+
* - Show value
|
|
155
|
+
*/
|
|
156
|
+
show_value?: boolean | undefined;
|
|
157
|
+
/**
|
|
158
|
+
* - Show percentage of x-axis
|
|
159
|
+
*/
|
|
160
|
+
show_out_of_x_axis?: boolean | undefined;
|
|
161
|
+
/**
|
|
162
|
+
* - Show percentage of data series
|
|
163
|
+
*/
|
|
164
|
+
show_out_of_data_series?: boolean | undefined;
|
|
165
|
+
};
|
|
166
|
+
/**
|
|
167
|
+
* Axis options configuration.
|
|
168
|
+
*/
|
|
169
|
+
export type AxisOptions = {
|
|
170
|
+
/**
|
|
171
|
+
* - Auto label Y axis
|
|
172
|
+
*/
|
|
173
|
+
autoylabel?: boolean | undefined;
|
|
174
|
+
/**
|
|
175
|
+
* - Auto label X axis
|
|
176
|
+
*/
|
|
177
|
+
autoxlabel?: boolean | undefined;
|
|
178
|
+
/**
|
|
179
|
+
* - Axis label
|
|
180
|
+
*/
|
|
181
|
+
name?: string | undefined;
|
|
182
|
+
/**
|
|
183
|
+
* - Minimum value
|
|
184
|
+
*/
|
|
185
|
+
min?: number | null | undefined;
|
|
186
|
+
/**
|
|
187
|
+
* - Maximum value
|
|
188
|
+
*/
|
|
189
|
+
max?: number | null | undefined;
|
|
190
|
+
/**
|
|
191
|
+
* - Label step interval
|
|
192
|
+
*/
|
|
193
|
+
label_step?: number | null | undefined;
|
|
194
|
+
/**
|
|
195
|
+
* - Enable x-axis zoom
|
|
196
|
+
*/
|
|
197
|
+
zoom_x?: boolean | undefined;
|
|
198
|
+
};
|
|
199
|
+
/**
|
|
200
|
+
* Feature flag checker callback.
|
|
201
|
+
*/
|
|
202
|
+
export type FeatureChecker = (featureName: string) => boolean;
|
|
203
|
+
/**
|
|
204
|
+
* Label gauge configuration options.
|
|
205
|
+
*/
|
|
206
|
+
export type LabelGaugeConfig = {
|
|
207
|
+
/**
|
|
208
|
+
* - Feature flag checker function
|
|
209
|
+
*/
|
|
210
|
+
hasFeature?: FeatureChecker | undefined;
|
|
211
|
+
/**
|
|
212
|
+
* - Feature flag name
|
|
213
|
+
*/
|
|
214
|
+
ENABLE_GAUGE_DYNAMIC_GOAL?: string | undefined;
|
|
215
|
+
};
|
|
216
|
+
/**
|
|
217
|
+
* Table options configuration.
|
|
218
|
+
*/
|
|
219
|
+
export type TableOptionsConfig = {
|
|
220
|
+
/**
|
|
221
|
+
* - Chart types enum
|
|
222
|
+
*/
|
|
223
|
+
CHART_TYPES?: import("./constants").ChartTypesMap | undefined;
|
|
224
|
+
};
|
|
225
|
+
/**
|
|
226
|
+
* Gauge segment definition.
|
|
227
|
+
*/
|
|
228
|
+
export type GaugeSegment = {
|
|
229
|
+
/**
|
|
230
|
+
* - Start value of segment
|
|
231
|
+
*/
|
|
232
|
+
from: number;
|
|
233
|
+
/**
|
|
234
|
+
* - End value of segment
|
|
235
|
+
*/
|
|
236
|
+
to: number;
|
|
237
|
+
/**
|
|
238
|
+
* - Color of the segment
|
|
239
|
+
*/
|
|
240
|
+
color: string;
|
|
241
|
+
/**
|
|
242
|
+
* - Title of the segment
|
|
243
|
+
*/
|
|
244
|
+
title: string;
|
|
245
|
+
};
|
|
246
|
+
/**
|
|
247
|
+
* Gauge segments configuration.
|
|
248
|
+
*/
|
|
249
|
+
export type GaugeSegmentsConfig = {
|
|
250
|
+
/**
|
|
251
|
+
* - Default segment values
|
|
252
|
+
*/
|
|
253
|
+
defaultSegments?: GaugeSegment[] | undefined;
|
|
254
|
+
};
|
|
255
|
+
/**
|
|
256
|
+
* Disabled condition for standard labels (when no display option is selected).
|
|
257
|
+
* Used by: withLabel, withLabelWithPercentage, withLabelWithPercentagePercentStacked
|
|
258
|
+
* @type {{disabled_str: string, disabled_fn: function(LabelOptions): boolean}}
|
|
259
|
+
*/
|
|
260
|
+
export const LABEL_DISABLED_CONDITION: {
|
|
261
|
+
disabled_str: string;
|
|
262
|
+
disabled_fn: (arg0: LabelOptions) => boolean;
|
|
263
|
+
};
|
|
264
|
+
/**
|
|
265
|
+
* Disabled condition for pie chart labels.
|
|
266
|
+
* @type {{disabled_str: string, disabled_fn: function(LabelPieOptions): boolean}}
|
|
267
|
+
*/
|
|
268
|
+
export const LABEL_PIE_DISABLED_CONDITION: {
|
|
269
|
+
disabled_str: string;
|
|
270
|
+
disabled_fn: (arg0: LabelPieOptions) => boolean;
|
|
271
|
+
};
|
|
272
|
+
/**
|
|
273
|
+
* Disabled condition for standard tooltips (when no display option is selected).
|
|
274
|
+
* @type {{disabled_str: string, disabled_fn: function(TooltipOptions): boolean}}
|
|
275
|
+
*/
|
|
276
|
+
export const TOOLTIP_DISABLED_CONDITION: {
|
|
277
|
+
disabled_str: string;
|
|
278
|
+
disabled_fn: (arg0: TooltipOptions) => boolean;
|
|
279
|
+
};
|
|
280
|
+
/**
|
|
281
|
+
* Pie tooltip options configuration.
|
|
282
|
+
* @typedef {Object} TooltipPieOptions
|
|
283
|
+
* @property {boolean} [show] - Whether tooltips are shown
|
|
284
|
+
* @property {boolean} [show_percentage] - Show percentage
|
|
285
|
+
* @property {boolean} [show_value] - Show value
|
|
286
|
+
*/
|
|
287
|
+
/**
|
|
288
|
+
* Disabled condition for pie chart tooltips.
|
|
289
|
+
* @type {{disabled_str: string, disabled_fn: function(TooltipPieOptions): boolean}}
|
|
290
|
+
*/
|
|
291
|
+
export const TOOLTIP_PIE_DISABLED_CONDITION: {
|
|
292
|
+
disabled_str: string;
|
|
293
|
+
disabled_fn: (arg0: TooltipPieOptions) => boolean;
|
|
294
|
+
};
|
|
295
|
+
/**
|
|
296
|
+
* Show toggle for standard labels with disabled condition.
|
|
297
|
+
* @type {import('./elements').SuboptionElement}
|
|
298
|
+
*/
|
|
299
|
+
export const LABEL_SHOW_TOGGLE: import("./elements").SuboptionElement;
|
|
300
|
+
/**
|
|
301
|
+
* Show toggle for pie labels with disabled condition.
|
|
302
|
+
* @type {import('./elements').SuboptionElement}
|
|
303
|
+
*/
|
|
304
|
+
export const LABEL_PIE_SHOW_TOGGLE: import("./elements").SuboptionElement;
|
|
305
|
+
/**
|
|
306
|
+
* Overlap toggle for labels.
|
|
307
|
+
* @type {import('./elements').SuboptionElement}
|
|
308
|
+
*/
|
|
309
|
+
export const LABEL_OVERLAP_TOGGLE: import("./elements").SuboptionElement;
|
|
310
|
+
/**
|
|
311
|
+
* Show toggle for standard tooltips with disabled condition.
|
|
312
|
+
* @type {import('./elements').SuboptionElement}
|
|
313
|
+
*/
|
|
314
|
+
export const TOOLTIP_SHOW_TOGGLE: import("./elements").SuboptionElement;
|
|
315
|
+
/**
|
|
316
|
+
* Show toggle for pie tooltips with disabled condition.
|
|
317
|
+
* @type {import('./elements').SuboptionElement}
|
|
318
|
+
*/
|
|
319
|
+
export const TOOLTIP_PIE_SHOW_TOGGLE: import("./elements").SuboptionElement;
|
|
320
|
+
/**
|
|
321
|
+
* Show toggle for gauge (no disabled condition).
|
|
322
|
+
* @type {import('./elements').SuboptionElement}
|
|
323
|
+
*/
|
|
324
|
+
export const GAUGE_SHOW_TOGGLE: import("./elements").SuboptionElement;
|
|
325
|
+
/**
|
|
326
|
+
* Suboption definition structure.
|
|
327
|
+
* @typedef {Object} SuboptionDefinition
|
|
328
|
+
* @property {string} category_class - CSS class for the category
|
|
329
|
+
* @property {string} category_label - Display label for the category
|
|
330
|
+
* @property {string} category_type - Type identifier for the category
|
|
331
|
+
* @property {import('./elements').SuboptionElement[]} [elements] - UI elements
|
|
332
|
+
* @property {boolean} [is_hidden] - Whether category is hidden in UI
|
|
333
|
+
* @property {*} [default_value] - Default value for simple suboptions
|
|
334
|
+
*/
|
|
335
|
+
/**
|
|
336
|
+
* Label options configuration.
|
|
337
|
+
* @typedef {Object} LabelOptions
|
|
338
|
+
* @property {boolean} [show] - Whether labels are shown
|
|
339
|
+
* @property {boolean} [overlap] - Whether labels can overlap
|
|
340
|
+
* @property {boolean} [vertical] - Whether labels are vertical
|
|
341
|
+
* @property {string} [font_style] - Font family
|
|
342
|
+
* @property {string|number} [font_size] - Font size
|
|
343
|
+
* @property {string} [font_color] - Font color
|
|
344
|
+
* @property {boolean} [show_value] - Show value in label
|
|
345
|
+
* @property {boolean} [show_out_of_x_axis] - Show percentage of x-axis
|
|
346
|
+
* @property {boolean} [show_out_of_data_series] - Show percentage of data series
|
|
347
|
+
*/
|
|
348
|
+
/**
|
|
349
|
+
* Label pie options configuration.
|
|
350
|
+
* @typedef {Object} LabelPieOptions
|
|
351
|
+
* @property {boolean} [show] - Whether labels are shown
|
|
352
|
+
* @property {boolean} [overlap] - Whether labels can overlap
|
|
353
|
+
* @property {boolean} [use_area_color] - Use area color for labels
|
|
354
|
+
* @property {string} [font_style] - Font family
|
|
355
|
+
* @property {string|number} [font_size] - Font size
|
|
356
|
+
* @property {string} [font_color] - Font color
|
|
357
|
+
* @property {boolean} [show_value_in_labels] - Show value in labels
|
|
358
|
+
* @property {boolean} [show_percentage_in_labels] - Show percentage in labels
|
|
359
|
+
*/
|
|
360
|
+
/**
|
|
361
|
+
* Tooltip options configuration.
|
|
362
|
+
* @typedef {Object} TooltipOptions
|
|
363
|
+
* @property {boolean} [show] - Whether tooltips are shown
|
|
364
|
+
* @property {string} [font_style] - Font family
|
|
365
|
+
* @property {string|number} [font_size] - Font size
|
|
366
|
+
* @property {string} [font_color] - Font color
|
|
367
|
+
* @property {boolean} [show_x_axis] - Show x-axis value
|
|
368
|
+
* @property {boolean} [show_data_series] - Show data series
|
|
369
|
+
* @property {boolean} [show_value] - Show value
|
|
370
|
+
* @property {boolean} [show_out_of_x_axis] - Show percentage of x-axis
|
|
371
|
+
* @property {boolean} [show_out_of_data_series] - Show percentage of data series
|
|
372
|
+
*/
|
|
373
|
+
/**
|
|
374
|
+
* Axis options configuration.
|
|
375
|
+
* @typedef {Object} AxisOptions
|
|
376
|
+
* @property {boolean} [autoylabel] - Auto label Y axis
|
|
377
|
+
* @property {boolean} [autoxlabel] - Auto label X axis
|
|
378
|
+
* @property {string} [name] - Axis label
|
|
379
|
+
* @property {number|null} [min] - Minimum value
|
|
380
|
+
* @property {number|null} [max] - Maximum value
|
|
381
|
+
* @property {number|null} [label_step] - Label step interval
|
|
382
|
+
* @property {boolean} [zoom_x] - Enable x-axis zoom
|
|
383
|
+
*/
|
|
384
|
+
/**
|
|
385
|
+
* Creates a base suboption definition.
|
|
386
|
+
* @param {string} categoryType - The category type identifier
|
|
387
|
+
* @param {string} categoryLabel - Display label
|
|
388
|
+
* @param {import('./elements').SuboptionElement[]} elements - UI elements
|
|
389
|
+
* @param {Object} [options={}] - Additional options
|
|
390
|
+
* @returns {SuboptionDefinition}
|
|
391
|
+
*/
|
|
392
|
+
export function createSuboption(categoryType: string, categoryLabel: string, elements: import("./elements").SuboptionElement[], options?: Object): SuboptionDefinition;
|
|
393
|
+
/**
|
|
394
|
+
* Creates a standard label suboption definition.
|
|
395
|
+
* @returns {SuboptionDefinition}
|
|
396
|
+
*/
|
|
397
|
+
export function withLabel(): SuboptionDefinition;
|
|
398
|
+
/**
|
|
399
|
+
* Creates a label suboption for pie charts.
|
|
400
|
+
* @returns {SuboptionDefinition}
|
|
401
|
+
*/
|
|
402
|
+
export function withLabelPie(): SuboptionDefinition;
|
|
403
|
+
/**
|
|
404
|
+
* Feature flag checker callback.
|
|
405
|
+
* @callback FeatureChecker
|
|
406
|
+
* @param {string} featureName - The feature flag name to check
|
|
407
|
+
* @returns {boolean} Whether the feature is enabled
|
|
408
|
+
*/
|
|
409
|
+
/**
|
|
410
|
+
* Label gauge configuration options.
|
|
411
|
+
* @typedef {Object} LabelGaugeConfig
|
|
412
|
+
* @property {FeatureChecker} [hasFeature] - Feature flag checker function
|
|
413
|
+
* @property {string} [ENABLE_GAUGE_DYNAMIC_GOAL] - Feature flag name
|
|
414
|
+
*/
|
|
415
|
+
/**
|
|
416
|
+
* Creates a label suboption for gauge charts.
|
|
417
|
+
* @param {LabelGaugeConfig} [config={}] - Configuration
|
|
418
|
+
* @returns {SuboptionDefinition}
|
|
419
|
+
*/
|
|
420
|
+
export function withLabelGauge(config?: LabelGaugeConfig): SuboptionDefinition;
|
|
421
|
+
/**
|
|
422
|
+
* Creates a label suboption with percentage options for stacked charts.
|
|
423
|
+
* @returns {SuboptionDefinition}
|
|
424
|
+
*/
|
|
425
|
+
export function withLabelWithPercentage(): SuboptionDefinition;
|
|
426
|
+
/**
|
|
427
|
+
* Creates a label suboption for percent stacked charts (no total options).
|
|
428
|
+
* @returns {SuboptionDefinition}
|
|
429
|
+
*/
|
|
430
|
+
export function withLabelWithPercentagePercentStacked(): SuboptionDefinition;
|
|
431
|
+
/**
|
|
432
|
+
* Creates a standard tooltip suboption definition.
|
|
433
|
+
* @returns {SuboptionDefinition}
|
|
434
|
+
*/
|
|
435
|
+
export function withTooltip(): SuboptionDefinition;
|
|
436
|
+
/**
|
|
437
|
+
* Creates a tooltip suboption for pie charts.
|
|
438
|
+
* @returns {SuboptionDefinition}
|
|
439
|
+
*/
|
|
440
|
+
export function withTooltipPie(): SuboptionDefinition;
|
|
441
|
+
/**
|
|
442
|
+
* Creates a tooltip suboption for gauge charts.
|
|
443
|
+
* @returns {SuboptionDefinition}
|
|
444
|
+
*/
|
|
445
|
+
export function withTooltipGauge(): SuboptionDefinition;
|
|
446
|
+
/**
|
|
447
|
+
* Creates a Y-axis suboption definition.
|
|
448
|
+
* @returns {SuboptionDefinition}
|
|
449
|
+
*/
|
|
450
|
+
export function withAxisY(): SuboptionDefinition;
|
|
451
|
+
/**
|
|
452
|
+
* Creates a Y-axis suboption for percent stacked charts (no min/max).
|
|
453
|
+
* @returns {SuboptionDefinition}
|
|
454
|
+
*/
|
|
455
|
+
export function withAxisYPercentStacked(): SuboptionDefinition;
|
|
456
|
+
/**
|
|
457
|
+
* Creates an X-axis suboption definition.
|
|
458
|
+
* @returns {SuboptionDefinition}
|
|
459
|
+
*/
|
|
460
|
+
export function withAxisX(): SuboptionDefinition;
|
|
461
|
+
/**
|
|
462
|
+
* Table options configuration.
|
|
463
|
+
* @typedef {Object} TableOptionsConfig
|
|
464
|
+
* @property {import('./constants').ChartTypesMap} [CHART_TYPES] - Chart types enum
|
|
465
|
+
*/
|
|
466
|
+
/**
|
|
467
|
+
* Creates a table options suboption definition.
|
|
468
|
+
* @returns {SuboptionDefinition}
|
|
469
|
+
*/
|
|
470
|
+
export function withTableOptions(): SuboptionDefinition;
|
|
471
|
+
/**
|
|
472
|
+
* Creates a table options with transpose for certain chart types.
|
|
473
|
+
* @param {TableOptionsConfig} [config={}] - Configuration
|
|
474
|
+
* @returns {SuboptionDefinition}
|
|
475
|
+
*/
|
|
476
|
+
export function withTableOptionsTranspose(config?: TableOptionsConfig): SuboptionDefinition;
|
|
477
|
+
/**
|
|
478
|
+
* Creates table options for gauge charts (simplified).
|
|
479
|
+
* @returns {SuboptionDefinition}
|
|
480
|
+
*/
|
|
481
|
+
export function withTableOptionsGauge(): SuboptionDefinition;
|
|
482
|
+
/**
|
|
483
|
+
* Creates table design options suboption.
|
|
484
|
+
* @returns {SuboptionDefinition}
|
|
485
|
+
*/
|
|
486
|
+
export function withTableDesignOptions(): SuboptionDefinition;
|
|
487
|
+
/**
|
|
488
|
+
* Creates a chart configuration suboption.
|
|
489
|
+
* @returns {SuboptionDefinition}
|
|
490
|
+
*/
|
|
491
|
+
export function withChart(): SuboptionDefinition;
|
|
492
|
+
/**
|
|
493
|
+
* Creates a chart grid configuration suboption.
|
|
494
|
+
* @returns {SuboptionDefinition}
|
|
495
|
+
*/
|
|
496
|
+
export function withChartGrid(): SuboptionDefinition;
|
|
497
|
+
/**
|
|
498
|
+
* Creates a chart forecast configuration suboption.
|
|
499
|
+
* @returns {SuboptionDefinition}
|
|
500
|
+
*/
|
|
501
|
+
export function withChartForecast(): SuboptionDefinition;
|
|
502
|
+
/**
|
|
503
|
+
* Creates a chart position configuration suboption.
|
|
504
|
+
* @returns {SuboptionDefinition}
|
|
505
|
+
*/
|
|
506
|
+
export function withChartPosition(): SuboptionDefinition;
|
|
507
|
+
/**
|
|
508
|
+
* Creates a widget library suboption (hidden).
|
|
509
|
+
* @returns {SuboptionDefinition}
|
|
510
|
+
*/
|
|
511
|
+
export function withWidgetLibrary(): SuboptionDefinition;
|
|
512
|
+
/**
|
|
513
|
+
* Creates a subtitle suboption.
|
|
514
|
+
* @returns {SuboptionDefinition}
|
|
515
|
+
*/
|
|
516
|
+
export function withSubtitle(): SuboptionDefinition;
|
|
517
|
+
/**
|
|
518
|
+
* Creates a name suboption.
|
|
519
|
+
* @returns {SuboptionDefinition}
|
|
520
|
+
*/
|
|
521
|
+
export function withName(): SuboptionDefinition;
|
|
522
|
+
/**
|
|
523
|
+
* Creates a negative number format suboption.
|
|
524
|
+
* @returns {SuboptionDefinition}
|
|
525
|
+
*/
|
|
526
|
+
export function withNegativeNumberFormat(): SuboptionDefinition;
|
|
527
|
+
/**
|
|
528
|
+
* Creates a value suboption for KPI widgets.
|
|
529
|
+
* @returns {SuboptionDefinition}
|
|
530
|
+
*/
|
|
531
|
+
export function withValue(): SuboptionDefinition;
|
|
532
|
+
/**
|
|
533
|
+
* Creates a range suboption.
|
|
534
|
+
* @returns {SuboptionDefinition}
|
|
535
|
+
*/
|
|
536
|
+
export function withRange(): SuboptionDefinition;
|
|
537
|
+
/**
|
|
538
|
+
* Creates a ticks suboption.
|
|
539
|
+
* @returns {SuboptionDefinition}
|
|
540
|
+
*/
|
|
541
|
+
export function withTicks(): SuboptionDefinition;
|
|
542
|
+
/**
|
|
543
|
+
* Creates a legends position suboption.
|
|
544
|
+
* @returns {SuboptionDefinition}
|
|
545
|
+
*/
|
|
546
|
+
export function withLegends(): SuboptionDefinition;
|
|
547
|
+
/**
|
|
548
|
+
* Creates a delta column (variance) suboption.
|
|
549
|
+
* @returns {SuboptionDefinition}
|
|
550
|
+
*/
|
|
551
|
+
export function withDeltaColumn(): SuboptionDefinition;
|
|
552
|
+
/**
|
|
553
|
+
* Creates a delta column for drill down charts.
|
|
554
|
+
* @returns {SuboptionDefinition}
|
|
555
|
+
*/
|
|
556
|
+
export function withDeltaColumnForDrillDown(): SuboptionDefinition;
|
|
557
|
+
/**
|
|
558
|
+
* Creates an advanced options suboption.
|
|
559
|
+
* @returns {SuboptionDefinition}
|
|
560
|
+
*/
|
|
561
|
+
export function withAdvanced(): SuboptionDefinition;
|
|
562
|
+
/**
|
|
563
|
+
* Creates a total value label suboption for donut charts.
|
|
564
|
+
* @returns {SuboptionDefinition}
|
|
565
|
+
*/
|
|
566
|
+
export function withTotalValueLabelDonut(): SuboptionDefinition;
|
|
567
|
+
/**
|
|
568
|
+
* Creates gauge goal suboption (hidden).
|
|
569
|
+
* @returns {SuboptionDefinition}
|
|
570
|
+
*/
|
|
571
|
+
export function withGaugeGoal(): SuboptionDefinition;
|
|
572
|
+
/**
|
|
573
|
+
* Gauge segment definition.
|
|
574
|
+
* @typedef {Object} GaugeSegment
|
|
575
|
+
* @property {number} from - Start value of segment
|
|
576
|
+
* @property {number} to - End value of segment
|
|
577
|
+
* @property {string} color - Color of the segment
|
|
578
|
+
* @property {string} title - Title of the segment
|
|
579
|
+
*/
|
|
580
|
+
/**
|
|
581
|
+
* Gauge segments configuration.
|
|
582
|
+
* @typedef {Object} GaugeSegmentsConfig
|
|
583
|
+
* @property {GaugeSegment[]} [defaultSegments] - Default segment values
|
|
584
|
+
*/
|
|
585
|
+
/**
|
|
586
|
+
* Creates gauge segments suboption (hidden).
|
|
587
|
+
* @param {GaugeSegmentsConfig} [config={}] - Configuration
|
|
588
|
+
* @returns {SuboptionDefinition}
|
|
589
|
+
*/
|
|
590
|
+
export function withGaugeSegments(config?: GaugeSegmentsConfig): SuboptionDefinition;
|
|
591
|
+
/**
|
|
592
|
+
* Creates gauge is absolute value suboption (hidden).
|
|
593
|
+
* @returns {SuboptionDefinition}
|
|
594
|
+
*/
|
|
595
|
+
export function withGaugeIsAbsolute(): SuboptionDefinition;
|
|
596
|
+
/**
|
|
597
|
+
* Click handler for label value checkboxes.
|
|
598
|
+
* @param {LabelOptions} value - Current option values
|
|
599
|
+
*/
|
|
600
|
+
export function labelValueClickFn(value: LabelOptions): void;
|
|
601
|
+
/**
|
|
602
|
+
* Click handler for pie label checkboxes.
|
|
603
|
+
* @param {LabelPieOptions} value - Current option values
|
|
604
|
+
*/
|
|
605
|
+
export function labelPieClickFn(value: LabelPieOptions): void;
|
|
606
|
+
/**
|
|
607
|
+
* Click handler for tooltip checkboxes.
|
|
608
|
+
* @param {TooltipOptions} value - Current option values
|
|
609
|
+
*/
|
|
610
|
+
export function tooltipClickFn(value: TooltipOptions): void;
|
|
611
|
+
/**
|
|
612
|
+
* Click handler for pie tooltip checkboxes.
|
|
613
|
+
* @param {TooltipPieOptions} value - Current option values
|
|
614
|
+
*/
|
|
615
|
+
export function tooltipPieClickFn(value: TooltipPieOptions): void;
|