generaltranslation 8.1.1 → 8.1.3

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,5 +1,21 @@
1
1
  import { DataFormat } from '../jsx/content';
2
2
  import { FileFormat, FileReference } from './file';
3
+ /**
4
+ * Metadata stored alongside GTJSON file entries.
5
+ * Keys correspond to the entry id/hash in the GTJSON body.
6
+ */
7
+ export type GTJsonFormatMetadata = Record<string, {
8
+ context?: string;
9
+ id?: string;
10
+ domain?: string;
11
+ maxChars?: number;
12
+ dataFormat?: 'JSX' | 'ICU';
13
+ requestVersion?: number;
14
+ approved_at?: string | null;
15
+ approved_by?: string | null;
16
+ hash?: string;
17
+ filePaths?: string[];
18
+ }>;
3
19
  export type FileUpload = {
4
20
  branchId?: string;
5
21
  incomingBranchId?: string;
@@ -9,6 +25,7 @@ export type FileUpload = {
9
25
  fileFormat: FileFormat;
10
26
  dataFormat?: DataFormat;
11
27
  locale: string;
28
+ formatMetadata?: GTJsonFormatMetadata;
12
29
  versionId?: string;
13
30
  fileId?: string;
14
31
  };
package/dist/types.d.ts CHANGED
@@ -425,6 +425,7 @@ type Metadata = {
425
425
  id?: string;
426
426
  sourceLocale?: string;
427
427
  actionType?: 'standard' | 'fast' | string;
428
+ filePaths?: string[];
428
429
  [key: string]: any;
429
430
  };
430
431
  type FormatVariables = Record<string, string | number | boolean | null | undefined | Date>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "generaltranslation",
3
- "version": "8.1.1",
3
+ "version": "8.1.3",
4
4
  "description": "A language toolkit for AI developers",
5
5
  "main": "dist/index.cjs.min.cjs",
6
6
  "module": "dist/index.esm.min.mjs",