@gooddata/sdk-code-convertors 11.35.0-alpha.5 → 11.35.0-alpha.6

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 (63) hide show
  1. package/esm/configs/areaChart.d.ts +22 -9
  2. package/esm/configs/areaChart.js +13 -4
  3. package/esm/configs/barChart.d.ts +22 -9
  4. package/esm/configs/barChart.js +13 -4
  5. package/esm/configs/bubbleChart.d.ts +22 -9
  6. package/esm/configs/bubbleChart.js +13 -4
  7. package/esm/configs/bulletChart.d.ts +22 -9
  8. package/esm/configs/bulletChart.js +13 -4
  9. package/esm/configs/columnChart.d.ts +22 -9
  10. package/esm/configs/columnChart.js +13 -4
  11. package/esm/configs/comboChart.d.ts +22 -9
  12. package/esm/configs/comboChart.js +13 -4
  13. package/esm/configs/dependencyWheelChart.d.ts +22 -9
  14. package/esm/configs/dependencyWheelChart.js +13 -4
  15. package/esm/configs/donutChart.d.ts +22 -9
  16. package/esm/configs/donutChart.js +13 -4
  17. package/esm/configs/funnelChart.d.ts +22 -9
  18. package/esm/configs/funnelChart.js +13 -4
  19. package/esm/configs/geoAreaChart.d.ts +22 -9
  20. package/esm/configs/geoAreaChart.js +13 -4
  21. package/esm/configs/geoChart.d.ts +22 -9
  22. package/esm/configs/geoChart.js +13 -4
  23. package/esm/configs/headlineChart.d.ts +22 -9
  24. package/esm/configs/headlineChart.js +13 -4
  25. package/esm/configs/heatmapChart.d.ts +22 -9
  26. package/esm/configs/heatmapChart.js +13 -4
  27. package/esm/configs/lineChart.d.ts +22 -9
  28. package/esm/configs/lineChart.js +13 -4
  29. package/esm/configs/pieChart.d.ts +22 -9
  30. package/esm/configs/pieChart.js +13 -4
  31. package/esm/configs/pyramidChart.d.ts +22 -9
  32. package/esm/configs/pyramidChart.js +13 -4
  33. package/esm/configs/repeaterChart.d.ts +25 -10
  34. package/esm/configs/repeaterChart.js +15 -5
  35. package/esm/configs/sankeyChart.d.ts +22 -9
  36. package/esm/configs/sankeyChart.js +13 -4
  37. package/esm/configs/scatterChart.d.ts +22 -9
  38. package/esm/configs/scatterChart.js +13 -4
  39. package/esm/configs/table.d.ts +22 -9
  40. package/esm/configs/table.js +13 -4
  41. package/esm/configs/treemapChart.d.ts +22 -9
  42. package/esm/configs/treemapChart.js +13 -4
  43. package/esm/configs/types.d.ts +28 -0
  44. package/esm/configs/utils.d.ts +1 -0
  45. package/esm/configs/waterfallChart.d.ts +22 -9
  46. package/esm/configs/waterfallChart.js +13 -4
  47. package/esm/conts.d.ts +8 -0
  48. package/esm/conts.js +8 -0
  49. package/esm/from/declarativeDashboardToYaml.d.ts +9 -0
  50. package/esm/from/declarativeDashboardToYaml.js +7 -0
  51. package/esm/from/declarativeVisualisationToYaml.d.ts +47 -17
  52. package/esm/from/declarativeVisualisationToYaml.js +19 -0
  53. package/esm/index.d.ts +27 -27
  54. package/esm/index.js +23 -23
  55. package/esm/sdk-code-convertors.d.ts +2107 -1647
  56. package/esm/to/yamlDashboardToDeclarative.d.ts +18 -5
  57. package/esm/to/yamlDashboardToDeclarative.js +5 -0
  58. package/esm/to/yamlDatasetToDeclarative.d.ts +4 -0
  59. package/esm/to/yamlDatasetToDeclarative.js +4 -0
  60. package/esm/to/yamlVisualisationToDeclarative.d.ts +7 -2
  61. package/esm/to/yamlVisualisationToDeclarative.js +5 -0
  62. package/esm/utils/sharedUtils.d.ts +1 -0
  63. package/package.json +7 -7
@@ -1,7 +1,8 @@
1
1
  import type { Visualisation } from "@gooddata/sdk-code-schemas/v1";
2
2
  import { type ChartFillType, type ColorMapping, type PatternFillName } from "./types.js";
3
3
  import { type ConfigDefaults, type VisualisationConfig } from "./utils.js";
4
- type DefaultProperties = {
4
+ /** @internal */
5
+ export type DonutChartConfigProperties = {
5
6
  colorMapping: Array<ColorMapping>;
6
7
  dataLabels: {
7
8
  visible: boolean | "auto";
@@ -19,8 +20,12 @@ type DefaultProperties = {
19
20
  disableAlerts: boolean;
20
21
  disableScheduledExports: boolean;
21
22
  };
22
- declare function load(props: VisualisationConfig<DefaultProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
23
- declare function save(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined): {
23
+ /** @internal */
24
+ export declare const DONUT_CHART_DEFAULTS: ConfigDefaults<DonutChartConfigProperties>;
25
+ /** @internal */
26
+ export declare function donutChartLoad(props: VisualisationConfig<DonutChartConfigProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
27
+ /** @internal */
28
+ export declare function donutChartSave(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined): {
24
29
  colorMapping: ColorMapping[] | undefined;
25
30
  dataLabels: {
26
31
  visible: "auto" | boolean | undefined;
@@ -38,9 +43,17 @@ declare function save(_fields: Visualisation["query"]["fields"] | undefined, con
38
43
  disableAlerts: boolean | undefined;
39
44
  disableScheduledExports: boolean | undefined;
40
45
  } | undefined;
41
- export declare const donutChart: {
42
- load: typeof load;
43
- save: typeof save;
44
- DEFAULTS: ConfigDefaults<DefaultProperties>;
45
- };
46
- export {};
46
+ /**
47
+ * @internal
48
+ * @deprecated Use donutChartLoad and donutChartSave instead.
49
+ */
50
+ export interface IDonutChartConfig {
51
+ load: typeof donutChartLoad;
52
+ save: typeof donutChartSave;
53
+ DEFAULTS: ConfigDefaults<DonutChartConfigProperties>;
54
+ }
55
+ /**
56
+ * @internal
57
+ * @deprecated Use donutChartLoad and donutChartSave instead.
58
+ */
59
+ export declare const donutChart: IDonutChartConfig;
@@ -1,6 +1,7 @@
1
1
  // (C) 2023-2026 GoodData Corporation
2
2
  import { loadChartFill, loadColorMapping, saveChartFill, saveColorMapping } from "../utils/configUtils.js";
3
3
  import { getValueOrDefault, loadConfig, saveConfigObject, } from "./utils.js";
4
+ /** @internal */
4
5
  const DEFAULTS = {
5
6
  colorMapping: [],
6
7
  dataLabels: {
@@ -18,7 +19,10 @@ const DEFAULTS = {
18
19
  disableAlerts: false,
19
20
  disableScheduledExports: false,
20
21
  };
21
- function load(props) {
22
+ /** @internal */
23
+ export const DONUT_CHART_DEFAULTS = DEFAULTS;
24
+ /** @internal */
25
+ export function donutChartLoad(props) {
22
26
  return loadConfig(props, (key, value) => {
23
27
  switch (key) {
24
28
  case "colorMapping":
@@ -68,7 +72,8 @@ function load(props) {
68
72
  }
69
73
  });
70
74
  }
71
- function save(_fields, config) {
75
+ /** @internal */
76
+ export function donutChartSave(_fields, config) {
72
77
  if (!config) {
73
78
  return undefined;
74
79
  }
@@ -88,8 +93,12 @@ function save(_fields, config) {
88
93
  disableScheduledExports: getValueOrDefault(config.disable_scheduled_exports, DEFAULTS.disableScheduledExports, "bool"),
89
94
  });
90
95
  }
96
+ /**
97
+ * @internal
98
+ * @deprecated Use donutChartLoad and donutChartSave instead.
99
+ */
91
100
  export const donutChart = {
92
- load,
93
- save,
101
+ load: donutChartLoad,
102
+ save: donutChartSave,
94
103
  DEFAULTS,
95
104
  };
@@ -1,7 +1,8 @@
1
1
  import type { Visualisation } from "@gooddata/sdk-code-schemas/v1";
2
2
  import { type ChartFillType, type ColorMapping, type PatternFillName } from "./types.js";
3
3
  import { type ConfigDefaults, type VisualisationConfig } from "./utils.js";
4
- type DefaultProperties = {
4
+ /** @internal */
5
+ export type FunnelChartConfigProperties = {
5
6
  colorMapping: Array<ColorMapping>;
6
7
  dataLabels: {
7
8
  visible: boolean | "auto";
@@ -19,8 +20,12 @@ type DefaultProperties = {
19
20
  disableAlerts: boolean;
20
21
  disableScheduledExports: boolean;
21
22
  };
22
- declare function load(props: VisualisationConfig<DefaultProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
23
- declare function save(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined): {
23
+ /** @internal */
24
+ export declare const FUNNEL_CHART_DEFAULTS: ConfigDefaults<FunnelChartConfigProperties>;
25
+ /** @internal */
26
+ export declare function funnelChartLoad(props: VisualisationConfig<FunnelChartConfigProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
27
+ /** @internal */
28
+ export declare function funnelChartSave(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined): {
24
29
  colorMapping: ColorMapping[] | undefined;
25
30
  dataLabels: {
26
31
  visible: "auto" | boolean | undefined;
@@ -38,9 +43,17 @@ declare function save(_fields: Visualisation["query"]["fields"] | undefined, con
38
43
  disableAlerts: boolean | undefined;
39
44
  disableScheduledExports: boolean | undefined;
40
45
  } | undefined;
41
- export declare const funnelChart: {
42
- load: typeof load;
43
- save: typeof save;
44
- DEFAULTS: ConfigDefaults<DefaultProperties>;
45
- };
46
- export {};
46
+ /**
47
+ * @internal
48
+ * @deprecated Use funnelChartLoad and funnelChartSave instead.
49
+ */
50
+ export interface IFunnelChartConfig {
51
+ load: typeof funnelChartLoad;
52
+ save: typeof funnelChartSave;
53
+ DEFAULTS: ConfigDefaults<FunnelChartConfigProperties>;
54
+ }
55
+ /**
56
+ * @internal
57
+ * @deprecated Use funnelChartLoad and funnelChartSave instead.
58
+ */
59
+ export declare const funnelChart: IFunnelChartConfig;
@@ -1,6 +1,7 @@
1
1
  // (C) 2023-2026 GoodData Corporation
2
2
  import { loadChartFill, loadColorMapping, saveChartFill, saveColorMapping } from "../utils/configUtils.js";
3
3
  import { getValueOrDefault, loadConfig, saveConfigObject, } from "./utils.js";
4
+ /** @internal */
4
5
  const DEFAULTS = {
5
6
  colorMapping: [],
6
7
  dataLabels: {
@@ -18,7 +19,10 @@ const DEFAULTS = {
18
19
  disableAlerts: false,
19
20
  disableScheduledExports: false,
20
21
  };
21
- function load(props) {
22
+ /** @internal */
23
+ export const FUNNEL_CHART_DEFAULTS = DEFAULTS;
24
+ /** @internal */
25
+ export function funnelChartLoad(props) {
22
26
  return loadConfig(props, (key, value) => {
23
27
  switch (key) {
24
28
  case "colorMapping":
@@ -68,7 +72,8 @@ function load(props) {
68
72
  }
69
73
  });
70
74
  }
71
- function save(_fields, config) {
75
+ /** @internal */
76
+ export function funnelChartSave(_fields, config) {
72
77
  if (!config) {
73
78
  return undefined;
74
79
  }
@@ -88,8 +93,12 @@ function save(_fields, config) {
88
93
  disableScheduledExports: getValueOrDefault(config.disable_scheduled_exports, DEFAULTS.disableScheduledExports, "bool"),
89
94
  });
90
95
  }
96
+ /**
97
+ * @internal
98
+ * @deprecated Use funnelChartLoad and funnelChartSave instead.
99
+ */
91
100
  export const funnelChart = {
92
- load,
93
- save,
101
+ load: funnelChartLoad,
102
+ save: funnelChartSave,
94
103
  DEFAULTS,
95
104
  };
@@ -1,7 +1,8 @@
1
1
  import type { Visualisation } from "@gooddata/sdk-code-schemas/v1";
2
2
  import { type ColorMapping } from "./types.js";
3
3
  import { type ConfigDefaults, type VisualisationConfig } from "./utils.js";
4
- type DefaultProperties = {
4
+ /** @internal */
5
+ export type GeoAreaChartConfigProperties = {
5
6
  colorMapping: Array<ColorMapping>;
6
7
  legend: {
7
8
  enabled: boolean;
@@ -34,8 +35,12 @@ type DefaultProperties = {
34
35
  disableAlerts: boolean;
35
36
  disableScheduledExports: boolean;
36
37
  };
37
- declare function load(props: VisualisationConfig<DefaultProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
38
- declare function save(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined, _positions: Array<{
38
+ /** @internal */
39
+ export declare const GEO_AREA_CHART_DEFAULTS: ConfigDefaults<GeoAreaChartConfigProperties>;
40
+ /** @internal */
41
+ export declare function geoAreaChartLoad(props: VisualisationConfig<GeoAreaChartConfigProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
42
+ /** @internal */
43
+ export declare function geoAreaChartSave(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined, _positions: Array<{
39
44
  longitude: string;
40
45
  latitude: string;
41
46
  }>): {
@@ -71,9 +76,17 @@ declare function save(_fields: Visualisation["query"]["fields"] | undefined, con
71
76
  disableAlerts: boolean | undefined;
72
77
  disableScheduledExports: boolean | undefined;
73
78
  } | undefined;
74
- export declare const geoAreaChart: {
75
- load: typeof load;
76
- save: typeof save;
77
- DEFAULTS: ConfigDefaults<DefaultProperties>;
78
- };
79
- export {};
79
+ /**
80
+ * @internal
81
+ * @deprecated Use geoAreaChartLoad and geoAreaChartSave instead.
82
+ */
83
+ export interface IGeoAreaChartConfig {
84
+ load: typeof geoAreaChartLoad;
85
+ save: typeof geoAreaChartSave;
86
+ DEFAULTS: ConfigDefaults<GeoAreaChartConfigProperties>;
87
+ }
88
+ /**
89
+ * @internal
90
+ * @deprecated Use geoAreaChartLoad and geoAreaChartSave instead.
91
+ */
92
+ export declare const geoAreaChart: IGeoAreaChartConfig;
@@ -1,6 +1,7 @@
1
1
  // (C) 2023-2026 GoodData Corporation
2
2
  import { loadColorMapping, saveColorMapping } from "../utils/configUtils.js";
3
3
  import { getValueOrDefault, loadConfig, saveConfigObject, } from "./utils.js";
4
+ /** @internal */
4
5
  const DEFAULTS = {
5
6
  colorMapping: [],
6
7
  legend: {
@@ -51,7 +52,10 @@ function sanitizeControls(controls) {
51
52
  }
52
53
  return sanitized;
53
54
  }
54
- function load(props) {
55
+ /** @internal */
56
+ export const GEO_AREA_CHART_DEFAULTS = DEFAULTS;
57
+ /** @internal */
58
+ export function geoAreaChartLoad(props) {
55
59
  const sanitizedProps = props.controls ? { controls: sanitizeControls(props.controls) } : props;
56
60
  return loadConfig(sanitizedProps, (key, value) => {
57
61
  switch (key) {
@@ -131,7 +135,8 @@ function load(props) {
131
135
  }
132
136
  });
133
137
  }
134
- function save(_fields, config, _positions) {
138
+ /** @internal */
139
+ export function geoAreaChartSave(_fields, config, _positions) {
135
140
  if (!config) {
136
141
  return undefined;
137
142
  }
@@ -191,8 +196,12 @@ function save(_fields, config, _positions) {
191
196
  disableScheduledExports: getValueOrDefault(config.disable_scheduled_exports, DEFAULTS.disableScheduledExports, "bool"),
192
197
  });
193
198
  }
199
+ /**
200
+ * @internal
201
+ * @deprecated Use geoAreaChartLoad and geoAreaChartSave instead.
202
+ */
194
203
  export const geoAreaChart = {
195
- load,
196
- save,
204
+ load: geoAreaChartLoad,
205
+ save: geoAreaChartSave,
197
206
  DEFAULTS,
198
207
  };
@@ -1,7 +1,8 @@
1
1
  import type { Visualisation } from "@gooddata/sdk-code-schemas/v1";
2
2
  import { type ColorMapping } from "./types.js";
3
3
  import { type ConfigDefaults, type VisualisationConfig } from "./utils.js";
4
- type DefaultProperties = {
4
+ /** @internal */
5
+ export type GeoChartConfigProperties = {
5
6
  colorMapping: Array<ColorMapping>;
6
7
  legend: {
7
8
  enabled: boolean;
@@ -43,17 +44,29 @@ type DefaultProperties = {
43
44
  disableAlerts: boolean;
44
45
  disableScheduledExports: boolean;
45
46
  };
46
- declare function load(props: VisualisationConfig<DefaultProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
47
- declare function save(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined, positions: Array<{
47
+ /** @internal */
48
+ export declare const GEO_CHART_DEFAULTS: ConfigDefaults<GeoChartConfigProperties>;
49
+ /** @internal */
50
+ export declare function geoChartLoad(props: VisualisationConfig<GeoChartConfigProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
51
+ /** @internal */
52
+ export declare function geoChartSave(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined, positions: Array<{
48
53
  longitude: string;
49
54
  latitude: string;
50
55
  }>): {
51
56
  longitude: string;
52
57
  latitude: string;
53
58
  } | undefined;
54
- export declare const geoChart: {
55
- load: typeof load;
56
- save: typeof save;
57
- DEFAULTS: ConfigDefaults<DefaultProperties>;
58
- };
59
- export {};
59
+ /**
60
+ * @internal
61
+ * @deprecated Use geoChartLoad and geoChartSave instead.
62
+ */
63
+ export interface IGeoChartConfig {
64
+ load: typeof geoChartLoad;
65
+ save: typeof geoChartSave;
66
+ DEFAULTS: ConfigDefaults<GeoChartConfigProperties>;
67
+ }
68
+ /**
69
+ * @internal
70
+ * @deprecated Use geoChartLoad and geoChartSave instead.
71
+ */
72
+ export declare const geoChart: IGeoChartConfig;
@@ -1,6 +1,7 @@
1
1
  // (C) 2023-2026 GoodData Corporation
2
2
  import { loadColorMapping, saveColorMapping } from "../utils/configUtils.js";
3
3
  import { getValueOrDefault, loadConfig, saveConfigObject, } from "./utils.js";
4
+ /** @internal */
4
5
  const DEFAULTS = {
5
6
  colorMapping: [],
6
7
  legend: {
@@ -65,7 +66,10 @@ function sanitizeControls(controls) {
65
66
  }
66
67
  return sanitized;
67
68
  }
68
- function load(props) {
69
+ /** @internal */
70
+ export const GEO_CHART_DEFAULTS = DEFAULTS;
71
+ /** @internal */
72
+ export function geoChartLoad(props) {
69
73
  const sanitizedProps = props.controls ? { controls: sanitizeControls(props.controls) } : props;
70
74
  return loadConfig(sanitizedProps, (key, value) => {
71
75
  switch (key) {
@@ -160,7 +164,8 @@ function load(props) {
160
164
  }
161
165
  });
162
166
  }
163
- function save(_fields, config, positions) {
167
+ /** @internal */
168
+ export function geoChartSave(_fields, config, positions) {
164
169
  if (!config) {
165
170
  const pos = positions[0];
166
171
  if (!pos) {
@@ -239,8 +244,12 @@ function save(_fields, config, positions) {
239
244
  latitude: positions[0]?.latitude ?? "",
240
245
  });
241
246
  }
247
+ /**
248
+ * @internal
249
+ * @deprecated Use geoChartLoad and geoChartSave instead.
250
+ */
242
251
  export const geoChart = {
243
- load,
244
- save,
252
+ load: geoChartLoad,
253
+ save: geoChartSave,
245
254
  DEFAULTS,
246
255
  };
@@ -1,7 +1,8 @@
1
1
  import type { Visualisation } from "@gooddata/sdk-code-schemas/v1";
2
2
  import { type ColorMapping } from "./types.js";
3
3
  import { type ConfigDefaults, type VisualisationConfig } from "./utils.js";
4
- type DefaultProperties = {
4
+ /** @internal */
5
+ export type HeadlineChartConfigProperties = {
5
6
  comparison: {
6
7
  enabled: boolean;
7
8
  calculationType: "change" | "change_difference" | "ratio" | "difference";
@@ -25,8 +26,12 @@ type DefaultProperties = {
25
26
  disableAlerts: boolean;
26
27
  disableScheduledExports: boolean;
27
28
  };
28
- declare function load(props: VisualisationConfig<DefaultProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
29
- declare function save(_fields: Visualisation["query"]["fields"] | undefined, config?: Visualisation["config"] | undefined): {
29
+ /** @internal */
30
+ export declare const HEADLINE_CHART_DEFAULTS: ConfigDefaults<HeadlineChartConfigProperties>;
31
+ /** @internal */
32
+ export declare function headlineChartLoad(props: VisualisationConfig<HeadlineChartConfigProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
33
+ /** @internal */
34
+ export declare function headlineChartSave(_fields: Visualisation["query"]["fields"] | undefined, config?: Visualisation["config"] | undefined): {
30
35
  comparison: {
31
36
  calculationType: string | undefined;
32
37
  format: string | undefined;
@@ -80,9 +85,17 @@ declare function save(_fields: Visualisation["query"]["fields"] | undefined, con
80
85
  disableAlerts: boolean | undefined;
81
86
  disableScheduledExports: boolean | undefined;
82
87
  } | undefined;
83
- export declare const headlineChart: {
84
- load: typeof load;
85
- save: typeof save;
86
- DEFAULTS: ConfigDefaults<DefaultProperties>;
87
- };
88
- export {};
88
+ /**
89
+ * @internal
90
+ * @deprecated Use headlineChartLoad and headlineChartSave instead.
91
+ */
92
+ export interface IHeadlineChartConfig {
93
+ load: typeof headlineChartLoad;
94
+ save: typeof headlineChartSave;
95
+ DEFAULTS: ConfigDefaults<HeadlineChartConfigProperties>;
96
+ }
97
+ /**
98
+ * @internal
99
+ * @deprecated Use headlineChartLoad and headlineChartSave instead.
100
+ */
101
+ export declare const headlineChart: IHeadlineChartConfig;
@@ -1,6 +1,7 @@
1
1
  // (C) 2023-2026 GoodData Corporation
2
2
  import { loadColor, saveColor } from "../utils/configUtils.js";
3
3
  import { getValueOrDefault, loadConfig, saveConfigObject, } from "./utils.js";
4
+ /** @internal */
4
5
  const DEFAULTS = {
5
6
  comparison: {
6
7
  calculationType: "ratio",
@@ -25,7 +26,10 @@ const DEFAULTS = {
25
26
  disableAlerts: false,
26
27
  disableScheduledExports: false,
27
28
  };
28
- function load(props) {
29
+ /** @internal */
30
+ export const HEADLINE_CHART_DEFAULTS = DEFAULTS;
31
+ /** @internal */
32
+ export function headlineChartLoad(props) {
29
33
  return loadConfig(props, (key, value) => {
30
34
  switch (key) {
31
35
  case "comparison": {
@@ -90,7 +94,8 @@ function load(props) {
90
94
  }
91
95
  });
92
96
  }
93
- function save(_fields, config = {}) {
97
+ /** @internal */
98
+ export function headlineChartSave(_fields, config = {}) {
94
99
  return saveConfigObject({
95
100
  comparison: saveConfigObject({
96
101
  calculationType: getValueOrDefault(config.comparison_type, DEFAULTS.comparison.calculationType),
@@ -116,8 +121,12 @@ function save(_fields, config = {}) {
116
121
  disableScheduledExports: getValueOrDefault(config.disable_scheduled_exports, DEFAULTS.disableScheduledExports, "bool"),
117
122
  });
118
123
  }
124
+ /**
125
+ * @internal
126
+ * @deprecated Use headlineChartLoad and headlineChartSave instead.
127
+ */
119
128
  export const headlineChart = {
120
- load,
121
- save,
129
+ load: headlineChartLoad,
130
+ save: headlineChartSave,
122
131
  DEFAULTS,
123
132
  };
@@ -1,7 +1,8 @@
1
1
  import type { Visualisation } from "@gooddata/sdk-code-schemas/v1";
2
2
  import { type ColorMapping } from "./types.js";
3
3
  import { type ConfigDefaults, type VisualisationConfig } from "./utils.js";
4
- type DefaultProperties = {
4
+ /** @internal */
5
+ export type HeatmapChartConfigProperties = {
5
6
  colorMapping: Array<ColorMapping>;
6
7
  dataLabels: {
7
8
  visible: boolean | "auto";
@@ -33,8 +34,12 @@ type DefaultProperties = {
33
34
  disableAlerts: boolean;
34
35
  disableScheduledExports: boolean;
35
36
  };
36
- declare function load(props: VisualisationConfig<DefaultProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
37
- declare function save(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined): {
37
+ /** @internal */
38
+ export declare const HEATMAP_CHART_DEFAULTS: ConfigDefaults<HeatmapChartConfigProperties>;
39
+ /** @internal */
40
+ export declare function heatmapChartLoad(props: VisualisationConfig<HeatmapChartConfigProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
41
+ /** @internal */
42
+ export declare function heatmapChartSave(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined): {
38
43
  colorMapping: ColorMapping[] | undefined;
39
44
  dataLabels: {
40
45
  visible: "auto" | boolean | undefined;
@@ -66,9 +71,17 @@ declare function save(_fields: Visualisation["query"]["fields"] | undefined, con
66
71
  disableAlerts: boolean | undefined;
67
72
  disableScheduledExports: boolean | undefined;
68
73
  } | undefined;
69
- export declare const heatmapChart: {
70
- load: typeof load;
71
- save: typeof save;
72
- DEFAULTS: ConfigDefaults<DefaultProperties>;
73
- };
74
- export {};
74
+ /**
75
+ * @internal
76
+ * @deprecated Use heatmapChartLoad and heatmapChartSave instead.
77
+ */
78
+ export interface IHeatmapChartConfig {
79
+ load: typeof heatmapChartLoad;
80
+ save: typeof heatmapChartSave;
81
+ DEFAULTS: ConfigDefaults<HeatmapChartConfigProperties>;
82
+ }
83
+ /**
84
+ * @internal
85
+ * @deprecated Use heatmapChartLoad and heatmapChartSave instead.
86
+ */
87
+ export declare const heatmapChart: IHeatmapChartConfig;
@@ -1,6 +1,7 @@
1
1
  // (C) 2023-2026 GoodData Corporation
2
2
  import { loadColorMapping, saveColorMapping } from "../utils/configUtils.js";
3
3
  import { getValueOrDefault, loadConfig, saveConfigObject, } from "./utils.js";
4
+ /** @internal */
4
5
  const DEFAULTS = {
5
6
  colorMapping: [],
6
7
  dataLabels: {
@@ -33,7 +34,10 @@ const DEFAULTS = {
33
34
  disableAlerts: false,
34
35
  disableScheduledExports: false,
35
36
  };
36
- function load(props) {
37
+ /** @internal */
38
+ export const HEATMAP_CHART_DEFAULTS = DEFAULTS;
39
+ /** @internal */
40
+ export function heatmapChartLoad(props) {
37
41
  return loadConfig(props, (key, value) => {
38
42
  switch (key) {
39
43
  case "colorMapping":
@@ -113,7 +117,8 @@ function load(props) {
113
117
  }
114
118
  });
115
119
  }
116
- function save(_fields, config) {
120
+ /** @internal */
121
+ export function heatmapChartSave(_fields, config) {
117
122
  if (!config) {
118
123
  return undefined;
119
124
  }
@@ -150,8 +155,12 @@ function save(_fields, config) {
150
155
  disableScheduledExports: getValueOrDefault(config.disable_scheduled_exports, DEFAULTS.disableScheduledExports, "bool"),
151
156
  });
152
157
  }
158
+ /**
159
+ * @internal
160
+ * @deprecated Use heatmapChartLoad and heatmapChartSave instead.
161
+ */
153
162
  export const heatmapChart = {
154
- load,
155
- save,
163
+ load: heatmapChartLoad,
164
+ save: heatmapChartSave,
156
165
  DEFAULTS,
157
166
  };
@@ -1,7 +1,8 @@
1
1
  import type { Visualisation } from "@gooddata/sdk-code-schemas/v1";
2
2
  import { type ColorMapping, type PointShapeSymbol } from "./types.js";
3
3
  import { type ConfigDefaults, type VisualisationConfig } from "./utils.js";
4
- type DefaultProperties = {
4
+ /** @internal */
5
+ export type LineChartConfigProperties = {
5
6
  colorMapping: Array<ColorMapping>;
6
7
  continuousLine: {
7
8
  enabled: boolean;
@@ -63,8 +64,12 @@ type DefaultProperties = {
63
64
  thresholdMeasures: string[];
64
65
  thresholdExcludedMeasures: string[];
65
66
  };
66
- declare function load(props: VisualisationConfig<DefaultProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
67
- declare function save(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined): {
67
+ /** @internal */
68
+ export declare const LINE_CHART_DEFAULTS: ConfigDefaults<LineChartConfigProperties>;
69
+ /** @internal */
70
+ export declare function lineChartLoad(props: VisualisationConfig<LineChartConfigProperties>): import("yaml").Pair<import("yaml").Scalar<string>, any> | null;
71
+ /** @internal */
72
+ export declare function lineChartSave(_fields: Visualisation["query"]["fields"] | undefined, config: Visualisation["config"] | undefined): {
68
73
  colorMapping: ColorMapping[] | undefined;
69
74
  continuousLine: {
70
75
  enabled: boolean | undefined;
@@ -126,9 +131,17 @@ declare function save(_fields: Visualisation["query"]["fields"] | undefined, con
126
131
  thresholdMeasures: string[] | undefined;
127
132
  thresholdExcludedMeasures: string[] | undefined;
128
133
  } | undefined;
129
- export declare const lineChart: {
130
- load: typeof load;
131
- save: typeof save;
132
- DEFAULTS: ConfigDefaults<DefaultProperties>;
133
- };
134
- export {};
134
+ /**
135
+ * @internal
136
+ * @deprecated Use lineChartLoad and lineChartSave instead.
137
+ */
138
+ export interface ILineChartConfig {
139
+ load: typeof lineChartLoad;
140
+ save: typeof lineChartSave;
141
+ DEFAULTS: ConfigDefaults<LineChartConfigProperties>;
142
+ }
143
+ /**
144
+ * @internal
145
+ * @deprecated Use lineChartLoad and lineChartSave instead.
146
+ */
147
+ export declare const lineChart: ILineChartConfig;
@@ -1,6 +1,7 @@
1
1
  // (C) 2023-2026 GoodData Corporation
2
2
  import { loadColorMapping, saveColorMapping } from "../utils/configUtils.js";
3
3
  import { getValueOrDefault, loadConfig, saveConfigObject, } from "./utils.js";
4
+ /** @internal */
4
5
  const DEFAULTS = {
5
6
  colorMapping: [],
6
7
  continuousLine: {
@@ -62,7 +63,10 @@ const DEFAULTS = {
62
63
  thresholdMeasures: [],
63
64
  thresholdExcludedMeasures: [],
64
65
  };
65
- function load(props) {
66
+ /** @internal */
67
+ export const LINE_CHART_DEFAULTS = DEFAULTS;
68
+ /** @internal */
69
+ export function lineChartLoad(props) {
66
70
  return loadConfig(props, (key, value) => {
67
71
  switch (key) {
68
72
  case "colorMapping":
@@ -218,7 +222,8 @@ function load(props) {
218
222
  }
219
223
  });
220
224
  }
221
- function save(_fields, config) {
225
+ /** @internal */
226
+ export function lineChartSave(_fields, config) {
222
227
  if (!config) {
223
228
  return undefined;
224
229
  }
@@ -286,8 +291,12 @@ function save(_fields, config) {
286
291
  thresholdExcludedMeasures: getValueOrDefault(config.line_style_excluded_metrics, DEFAULTS.thresholdExcludedMeasures, "array"),
287
292
  });
288
293
  }
294
+ /**
295
+ * @internal
296
+ * @deprecated Use lineChartLoad and lineChartSave instead.
297
+ */
289
298
  export const lineChart = {
290
- load,
291
- save,
299
+ load: lineChartLoad,
300
+ save: lineChartSave,
292
301
  DEFAULTS,
293
302
  };