@gooddata/sdk-ui-charts 11.57.0-alpha.5 → 11.57.0-alpha.7

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.
@@ -1 +1 @@
1
- {"version":3,"file":"referenceResolver.d.ts","sourceRoot":"","sources":["../../../../../src/highcharts/chartTypes/_chartCreators/customTooltip/referenceResolver.ts"],"names":[],"mappings":"AAEA;;;;;;GAMG;AAEH,OAAO,EAAE,KAAK,WAAW,EAAuB,MAAM,qBAAqB,CAAC;AAE5E,OAAO,EACH,KAAK,wBAAwB,EAKhC,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAE,KAAK,6BAA6B,EAAE,MAAM,4BAA4B,CAAC;AAEhF,OAAO,EAAE,KAAK,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAEjE;;;;;;;;;;;GAWG;AACH,wBAAgB,0BAA0B,CACtC,KAAK,EAAE,6BAA6B,EACpC,UAAU,EAAE,WAAW,GAAG,SAAS,EACnC,iBAAiB,EAAE,kBAAkB,GAAG,SAAS,GAClD,wBAAwB,CA0C1B"}
1
+ {"version":3,"file":"referenceResolver.d.ts","sourceRoot":"","sources":["../../../../../src/highcharts/chartTypes/_chartCreators/customTooltip/referenceResolver.ts"],"names":[],"mappings":"AAEA;;;;;;GAMG;AAEH,OAAO,EAAE,KAAK,WAAW,EAA+C,MAAM,qBAAqB,CAAC;AAEpG,OAAO,EACH,KAAK,wBAAwB,EAMhC,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAE,KAAK,6BAA6B,EAAE,MAAM,4BAA4B,CAAC;AAEhF,OAAO,EAAE,KAAK,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AAEjE;;;;;;;;;;;GAWG;AACH,wBAAgB,0BAA0B,CACtC,KAAK,EAAE,6BAA6B,EACpC,UAAU,EAAE,WAAW,GAAG,SAAS,EACnC,iBAAiB,EAAE,kBAAkB,GAAG,SAAS,GAClD,wBAAwB,CAgD1B"}
@@ -6,9 +6,9 @@
6
6
  * shape (`IResolvedReferenceValues`) live in @gooddata/sdk-ui-vis-commons; this
7
7
  * file builds the lookup from a hovered Highcharts point's drill intersection.
8
8
  */
9
- import { isMeasureDescriptor } from "@gooddata/sdk-model";
9
+ import { isComputedAttributeRef, isMeasureDescriptor } from "@gooddata/sdk-model";
10
10
  import { isDrillIntersectionAttributeItem } from "@gooddata/sdk-ui";
11
- import { labelKey, labelReference, measureReference, metricKey, } from "@gooddata/sdk-ui-vis-commons";
11
+ import { computedAttributeKey, labelKey, labelReference, measureReference, metricKey, } from "@gooddata/sdk-ui-vis-commons";
12
12
  /**
13
13
  * Builds resolved values from the hovered point's drill intersection.
14
14
  *
@@ -28,15 +28,21 @@ export function resolveReferencesFromPoint(point, separators, identifierMapping)
28
28
  for (const element of intersection) {
29
29
  const { header } = element;
30
30
  if (isDrillIntersectionAttributeItem(header)) {
31
- // Attribute element — resolve {label/id}
31
+ // Attribute element — resolve {label/id}, or {computed_attribute/id} when the
32
+ // descriptor ref says so. A computed attribute has no labels: its fabricated display
33
+ // form carries its own ref, which the backend types honestly for exactly this reason.
34
+ // Publishing it under its own key keeps it apart from a label of the same identifier.
35
+ const buildKey = isComputedAttributeRef(header.attributeHeader.ref)
36
+ ? computedAttributeKey
37
+ : labelKey;
32
38
  const displayFormId = header.attributeHeader.identifier;
33
39
  const attributeId = header.attributeHeader.formOf.identifier;
34
40
  const displayValue = header.attributeHeaderItem.formattedName ?? header.attributeHeaderItem.name ?? undefined;
35
41
  const status = labelReference(displayValue);
36
42
  // Register under both display form and attribute identifiers
37
- values[labelKey(displayFormId)] = status;
43
+ values[buildKey(displayFormId)] = status;
38
44
  if (attributeId !== displayFormId) {
39
- values[labelKey(attributeId)] = status;
45
+ values[buildKey(attributeId)] = status;
40
46
  }
41
47
  }
42
48
  else if (isMeasureDescriptor(header)) {
@@ -25,6 +25,6 @@ export function buildChartReferenceLookup(dataView, identifierMapping, separator
25
25
  for (const [localId, mapping] of Object.entries(identifierMapping.measures)) {
26
26
  measureIdMap[localId] = mapping.ldmId;
27
27
  }
28
- const meta = { measureIdMap, labelCountMap: {}, labelIdMap: {} };
28
+ const meta = { measureIdMap, labelCountMap: {}, attributeKeyMap: {} };
29
29
  return buildLookupTable(dataView, meta, separators);
30
30
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gooddata/sdk-ui-charts",
3
- "version": "11.57.0-alpha.5",
3
+ "version": "11.57.0-alpha.7",
4
4
  "description": "GoodData.UI SDK - Charts",
5
5
  "license": "LicenseRef-LICENSE",
6
6
  "author": "GoodData Corporation",
@@ -69,13 +69,13 @@
69
69
  "ts-invariant": "0.10.3",
70
70
  "tslib": "2.8.1",
71
71
  "uuid": "11.1.1",
72
- "@gooddata/sdk-backend-spi": "11.57.0-alpha.5",
73
- "@gooddata/sdk-ui-theme-provider": "11.57.0-alpha.5",
74
- "@gooddata/sdk-ui": "11.57.0-alpha.5",
75
- "@gooddata/sdk-model": "11.57.0-alpha.5",
76
- "@gooddata/sdk-ui-kit": "11.57.0-alpha.5",
77
- "@gooddata/util": "11.57.0-alpha.5",
78
- "@gooddata/sdk-ui-vis-commons": "11.57.0-alpha.5"
72
+ "@gooddata/sdk-backend-spi": "11.57.0-alpha.7",
73
+ "@gooddata/sdk-model": "11.57.0-alpha.7",
74
+ "@gooddata/sdk-ui": "11.57.0-alpha.7",
75
+ "@gooddata/sdk-ui-kit": "11.57.0-alpha.7",
76
+ "@gooddata/sdk-ui-theme-provider": "11.57.0-alpha.7",
77
+ "@gooddata/sdk-ui-vis-commons": "11.57.0-alpha.7",
78
+ "@gooddata/util": "11.57.0-alpha.7"
79
79
  },
80
80
  "devDependencies": {
81
81
  "@microsoft/api-documenter": "7.30.10",
@@ -104,23 +104,23 @@
104
104
  "full-icu": "1.6.0",
105
105
  "happy-dom": "20.12.0",
106
106
  "npm-run-all": "4.1.5",
107
- "oxfmt": "0.66.0",
108
- "oxlint": "1.82.0",
107
+ "oxfmt": "0.68.0",
108
+ "oxlint": "1.83.0",
109
109
  "oxlint-plugin-eslint": "1.82.0",
110
110
  "oxlint-tsgolint": "7.0.2001",
111
111
  "raf": "3.4.1",
112
112
  "react": "19.1.1",
113
113
  "react-dom": "19.1.1",
114
- "sass": "1.104.0",
114
+ "sass": "1.104.1",
115
115
  "stylelint": "16.26.1",
116
116
  "typescript": "7.0.2",
117
117
  "vitest": "4.1.8",
118
118
  "vitest-dom": "0.1.1",
119
- "@gooddata/sdk-backend-mockingbird": "11.57.0-alpha.5",
120
- "@gooddata/eslint-config": "11.57.0-alpha.5",
121
- "@gooddata/stylelint-config": "11.57.0-alpha.5",
122
- "@gooddata/oxlint-config": "11.57.0-alpha.5",
123
- "@gooddata/reference-workspace": "11.57.0-alpha.5"
119
+ "@gooddata/oxlint-config": "11.57.0-alpha.7",
120
+ "@gooddata/eslint-config": "11.57.0-alpha.7",
121
+ "@gooddata/reference-workspace": "11.57.0-alpha.7",
122
+ "@gooddata/stylelint-config": "11.57.0-alpha.7",
123
+ "@gooddata/sdk-backend-mockingbird": "11.57.0-alpha.7"
124
124
  },
125
125
  "peerDependencies": {
126
126
  "react": "^18.0.0 || ^19.0.0",