@fluid-topics/ft-app-context 1.2.43 → 1.2.44

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,6 +1,6 @@
1
1
  var _a;
2
2
  import { ftAppInfoStore } from "../redux-stores/FtAppInfoStore";
3
- import { CacheRegistry, deepEqual, delay, ParametrizedLabelResolver } from "@fluid-topics/ft-wc-utils";
3
+ import { CacheRegistry, CanceledPromiseError, deepEqual, delay, ParametrizedLabelResolver } from "@fluid-topics/ft-wc-utils";
4
4
  import { FtServiceWithCache } from "./FtServiceWithCache";
5
5
  export const clearAfterUnitTest = Symbol("clearAfterUnitTest");
6
6
  export class FtI18nServiceInternalClass extends FtServiceWithCache {
@@ -81,7 +81,9 @@ export class FtI18nServiceInternalClass extends FtServiceWithCache {
81
81
  await this.notify(name);
82
82
  }
83
83
  catch (e) {
84
- console.error(e);
84
+ if (!(e instanceof CanceledPromiseError)) {
85
+ console.error(e);
86
+ }
85
87
  }
86
88
  }
87
89
  }
@@ -13,6 +13,18 @@ interface BlockContent extends RootBlockContent {
13
13
  type: string;
14
14
  name?: string;
15
15
  }
16
+ type DefaultI18nMessages<T> = {
17
+ [key in keyof T]: string;
18
+ };
19
+ type I18nMessageComments<T> = {
20
+ [key in keyof T]: string;
21
+ };
22
+ export interface ExternalComponentI18nContextDefinition<T> {
23
+ name: string;
24
+ comment?: string;
25
+ messages: DefaultI18nMessages<T>;
26
+ comments?: I18nMessageComments<T>;
27
+ }
16
28
  export type FluidTopicsExternalComponentsInfo = {
17
29
  displayName: string;
18
30
  version: string;
@@ -22,6 +34,7 @@ export type FluidTopicsExternalComponentsInfo = {
22
34
  traits?: Array<any>;
23
35
  asType?: (editor: any) => any;
24
36
  blockContent?: RootBlockContent;
37
+ i18nContexts?: Array<ExternalComponentI18nContextDefinition<any>>;
25
38
  };
26
39
  declare global {
27
40
  interface Window {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluid-topics/ft-app-context",
3
- "version": "1.2.43",
3
+ "version": "1.2.44",
4
4
  "description": "Global application context for Fluid Topics integrations",
5
5
  "keywords": [
6
6
  "Lit"
@@ -19,11 +19,11 @@
19
19
  "url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
20
20
  },
21
21
  "dependencies": {
22
- "@fluid-topics/ft-wc-utils": "1.2.43",
22
+ "@fluid-topics/ft-wc-utils": "1.2.44",
23
23
  "lit": "3.1.0"
24
24
  },
25
25
  "devDependencies": {
26
26
  "@fluid-topics/public-api": "1.0.88"
27
27
  },
28
- "gitHead": "889e013d70bd9b29542bd5ae16a574f3de6f1aac"
28
+ "gitHead": "9cbc1788339e7a5d3d4dc94c36ec5a28f31dba6c"
29
29
  }