@gooddata/sdk-ui-pluggable-host 11.47.0-alpha.4 → 11.47.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.
@@ -1 +1 @@
1
- {"version":3,"file":"translations.d.ts","sourceRoot":"","sources":["../../../src/components/lib/translations.ts"],"names":[],"mappings":"AAIA,OAAO,EAIH,KAAK,aAAa,EAGrB,MAAM,kBAAkB,CAAC;AAuC1B,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAK1D,CAAC;AAyBF;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,aAAa,CAAoC,CAAC"}
1
+ {"version":3,"file":"translations.d.ts","sourceRoot":"","sources":["../../../src/components/lib/translations.ts"],"names":[],"mappings":"AAIA,OAAO,EAIH,KAAK,aAAa,EAGrB,MAAM,kBAAkB,CAAC;AA2C1B,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAK1D,CAAC;AA6BF;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,aAAa,CAAoC,CAAC"}
@@ -3,9 +3,12 @@ import { memoize } from "lodash-es";
3
3
  import { DEFAULT_LANGUAGE, DEFAULT_MESSAGES as DEFAULT_MESSAGES_SDK_UI, resolveLocale, resolveMessages as resolveMessagesSdkUi, } from "@gooddata/sdk-ui";
4
4
  import { removeMetadata } from "@gooddata/util";
5
5
  import enUS from "../../translations/en-US.json" with { type: "json" };
6
+ // English (default) messages for this library's own keys, used as the fallback
7
+ // for locales that are missing keys.
8
+ const DEFAULT_OWN_MESSAGES = removeMetadata(enUS);
6
9
  const asyncMessagesMap = {
7
- "en-US": () => Promise.resolve(removeMetadata(enUS)),
8
- "en-US-x-24h": () => Promise.resolve(removeMetadata(enUS)),
10
+ "en-US": () => Promise.resolve(DEFAULT_OWN_MESSAGES),
11
+ "en-US-x-24h": () => Promise.resolve(DEFAULT_OWN_MESSAGES),
9
12
  "de-DE": () => import("../../translations/de-DE.json").then((module) => module.default),
10
13
  "es-ES": () => import("../../translations/es-ES.json").then((module) => module.default),
11
14
  "fr-FR": () => import("../../translations/fr-FR.json").then((module) => module.default),
@@ -36,7 +39,7 @@ const defaultSdkUiMessages = DEFAULT_MESSAGES_SDK_UI[DEFAULT_LANGUAGE];
36
39
  export const DEFAULT_MESSAGES = {
37
40
  [DEFAULT_LANGUAGE]: {
38
41
  ...defaultSdkUiMessages,
39
- ...removeMetadata(enUS), // app messages should override sdk messages
42
+ ...DEFAULT_OWN_MESSAGES, // app messages should override sdk messages
40
43
  },
41
44
  };
42
45
  async function resolveMessagesInternal(locale) {
@@ -46,8 +49,12 @@ async function resolveMessagesInternal(locale) {
46
49
  asyncMessagesMap[validatedLocale](),
47
50
  resolveMessagesSdkUi(validatedLocale),
48
51
  ]);
49
- // app messages should override sdk messages
50
- return { ...sdkUiMessages, ...hostAppMessages };
52
+ // sdk-ui already falls back to English for its own keys; app messages override sdk messages
53
+ return {
54
+ ...DEFAULT_OWN_MESSAGES,
55
+ ...sdkUiMessages,
56
+ ...hostAppMessages,
57
+ };
51
58
  }
52
59
  catch (error) {
53
60
  // Translation chunks are content-hashed and may have been removed by a redeploy
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gooddata/sdk-ui-pluggable-host",
3
- "version": "11.47.0-alpha.4",
3
+ "version": "11.47.0",
4
4
  "description": "GoodData SDK runtime for hosting pluggable applications — registry, loader, routing, platform context, default UI chrome",
5
5
  "license": "MIT",
6
6
  "author": "GoodData Corporation",
@@ -29,20 +29,20 @@
29
29
  "dependencies": {
30
30
  "@module-federation/runtime": "2.6.0",
31
31
  "lodash-es": "^4.17.23",
32
- "@gooddata/sdk-backend-base": "11.47.0-alpha.4",
33
- "@gooddata/sdk-backend-spi": "11.47.0-alpha.4",
34
- "@gooddata/sdk-backend-tiger": "11.47.0-alpha.4",
35
- "@gooddata/sdk-model": "11.47.0-alpha.4",
36
- "@gooddata/sdk-embedding": "11.47.0-alpha.4",
37
- "@gooddata/sdk-pluggable-application-model": "11.47.0-alpha.4",
38
- "@gooddata/sdk-ui": "11.47.0-alpha.4",
39
- "@gooddata/sdk-ui-ext": "11.47.0-alpha.4",
40
- "@gooddata/sdk-ui-gen-ai": "11.47.0-alpha.4",
41
- "@gooddata/sdk-ui-kit": "11.47.0-alpha.4",
42
- "@gooddata/sdk-ui-application-header": "11.47.0-alpha.4",
43
- "@gooddata/sdk-ui-semantic-search": "11.47.0-alpha.4",
44
- "@gooddata/util": "11.47.0-alpha.4",
45
- "@gooddata/sdk-ui-theme-provider": "11.47.0-alpha.4"
32
+ "@gooddata/sdk-backend-base": "11.47.0",
33
+ "@gooddata/sdk-backend-spi": "11.47.0",
34
+ "@gooddata/sdk-backend-tiger": "11.47.0",
35
+ "@gooddata/sdk-model": "11.47.0",
36
+ "@gooddata/sdk-embedding": "11.47.0",
37
+ "@gooddata/sdk-pluggable-application-model": "11.47.0",
38
+ "@gooddata/sdk-ui": "11.47.0",
39
+ "@gooddata/sdk-ui-application-header": "11.47.0",
40
+ "@gooddata/sdk-ui-ext": "11.47.0",
41
+ "@gooddata/sdk-ui-kit": "11.47.0",
42
+ "@gooddata/sdk-ui-semantic-search": "11.47.0",
43
+ "@gooddata/sdk-ui-gen-ai": "11.47.0",
44
+ "@gooddata/sdk-ui-theme-provider": "11.47.0",
45
+ "@gooddata/util": "11.47.0"
46
46
  },
47
47
  "devDependencies": {
48
48
  "@microsoft/api-documenter": "^7.17.0",
@@ -85,8 +85,8 @@
85
85
  "vite": "8.0.16",
86
86
  "vitest": "4.1.8",
87
87
  "vitest-dom": "0.1.1",
88
- "@gooddata/eslint-config": "11.47.0-alpha.4",
89
- "@gooddata/oxlint-config": "11.47.0-alpha.4"
88
+ "@gooddata/eslint-config": "11.47.0",
89
+ "@gooddata/oxlint-config": "11.47.0"
90
90
  },
91
91
  "peerDependencies": {
92
92
  "react": ">=18.3.1",