generaltranslation 7.6.0 → 7.6.2

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.
@@ -10,3 +10,30 @@ export type CheckFileTranslationsOptions = {
10
10
  export type CheckFileTranslationsResult = {
11
11
  translations: CompletedFileTranslationData[];
12
12
  };
13
+ export type FileQuery = {
14
+ fileId: string;
15
+ versionId?: string;
16
+ };
17
+ export type FileQueryResult = {
18
+ sourceFile: {
19
+ id: string;
20
+ fileId: string;
21
+ versionId: string;
22
+ sourceLocale: string;
23
+ fileName: string;
24
+ fileFormat: string;
25
+ dataFormat: string | null;
26
+ createdAt: string;
27
+ updatedAt: string;
28
+ approvalRequiredAt: string | null;
29
+ locales: string[];
30
+ };
31
+ translations: {
32
+ locale: string;
33
+ completedAt: string | null;
34
+ approvedAt: string | null;
35
+ publishedAt: string | null;
36
+ createdAt: string | null;
37
+ updatedAt: string | null;
38
+ }[];
39
+ };
@@ -1,5 +1,5 @@
1
1
  import { Entry } from './entry';
2
- export type FileFormat = 'GTJSON' | 'JSON' | 'YAML' | 'MDX' | 'MD' | 'TS' | 'JS';
2
+ export type FileFormat = 'GTJSON' | 'JSON' | 'YAML' | 'MDX' | 'MD' | 'TS' | 'JS' | 'HTML';
3
3
  export type FileMetadata = {
4
4
  filePath: string;
5
5
  fileFormat: FileFormat;
@@ -0,0 +1,7 @@
1
+ export type ProjectData = {
2
+ id: string;
3
+ name: string;
4
+ orgId: string;
5
+ defaultLocale: string;
6
+ currentLocales: string[];
7
+ };
@@ -6,6 +6,8 @@ export type FileUpload = {
6
6
  fileFormat: FileFormat;
7
7
  dataFormat?: DataFormat;
8
8
  locale: string;
9
+ versionId?: string;
10
+ fileId?: string;
9
11
  };
10
12
  export type FileUploadRef = {
11
13
  fileId: string;
@@ -13,6 +15,7 @@ export type FileUploadRef = {
13
15
  fileName: string;
14
16
  fileFormat: FileFormat;
15
17
  dataFormat?: DataFormat;
18
+ locale?: string;
16
19
  };
17
20
  export type UploadData = {
18
21
  data: {
@@ -27,4 +30,9 @@ export type UploadFilesOptions = {
27
30
  modelProvider?: string;
28
31
  timeout?: number;
29
32
  };
33
+ export type UploadFilesResponse = {
34
+ uploadedFiles: FileUploadRef[];
35
+ count: number;
36
+ message: string;
37
+ };
30
38
  export type RequiredUploadFilesOptions = UploadFilesOptions & Required<Pick<UploadFilesOptions, 'sourceLocale'>>;
package/dist/types.d.ts CHANGED
@@ -129,7 +129,7 @@ type TranslationStatusResult = {
129
129
  localesWaitingForApproval: any[];
130
130
  };
131
131
 
132
- type FileFormat = 'GTJSON' | 'JSON' | 'YAML' | 'MDX' | 'MD' | 'TS' | 'JS';
132
+ type FileFormat = 'GTJSON' | 'JSON' | 'YAML' | 'MDX' | 'MD' | 'TS' | 'JS' | 'HTML';
133
133
  type CompletedFileTranslationData = {
134
134
  locale: string;
135
135
  metadata: any;
@@ -0,0 +1,2 @@
1
+ export declare function encode(data: string): string;
2
+ export declare function decode(base64: string): string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "generaltranslation",
3
- "version": "7.6.0",
3
+ "version": "7.6.2",
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",