generaltranslation 8.2.13 → 8.2.15

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.
Files changed (133) hide show
  1. package/CHANGELOG.md +22 -1
  2. package/dist/{ApiError-IYfaOR30.mjs → ApiError-0DxxIHLp.mjs} +1 -1
  3. package/dist/{ApiError-CZ45tkW6.cjs.map → ApiError-0DxxIHLp.mjs.map} +1 -1
  4. package/dist/{ApiError-CZ45tkW6.cjs → ApiError-D-IBuHj6.cjs} +1 -1
  5. package/dist/{ApiError-IYfaOR30.mjs.map → ApiError-D-IBuHj6.cjs.map} +1 -1
  6. package/dist/LocaleConfig.d.ts +1 -59
  7. package/dist/LocaleConfig.js +1 -225
  8. package/dist/{base64-2fu94Klt.cjs → base64-YBGAXkqy.cjs} +74 -1
  9. package/dist/base64-YBGAXkqy.cjs.map +1 -0
  10. package/dist/{base64-DH0STixb.mjs → base64-r7YWJYWt.mjs} +51 -2
  11. package/dist/base64-r7YWJYWt.mjs.map +1 -0
  12. package/dist/core.cjs +9 -8
  13. package/dist/core.d.cts +1 -2
  14. package/dist/core.d.mts +1 -2
  15. package/dist/core.d.ts +1 -128
  16. package/dist/core.js +1 -137
  17. package/dist/core.mjs +2 -2
  18. package/dist/derive/indexVars.d.ts +1 -1
  19. package/dist/errors.cjs +1 -1
  20. package/dist/errors.mjs +1 -1
  21. package/dist/id/types.d.ts +1 -1
  22. package/dist/{id-CyiXsQrY.cjs → id-C2orn1MA.cjs} +2 -2
  23. package/dist/{id-CyiXsQrY.cjs.map → id-C2orn1MA.cjs.map} +1 -1
  24. package/dist/{id-DbD7K-HL.mjs → id-DEaFhGqX.mjs} +2 -2
  25. package/dist/{id-DbD7K-HL.mjs.map → id-DEaFhGqX.mjs.map} +1 -1
  26. package/dist/id.cjs +1 -1
  27. package/dist/id.d.cts +1 -1
  28. package/dist/id.d.mts +1 -1
  29. package/dist/id.mjs +1 -1
  30. package/dist/index.cjs +431 -396
  31. package/dist/index.cjs.map +1 -1
  32. package/dist/index.d.cts +4 -242
  33. package/dist/index.d.mts +4 -242
  34. package/dist/index.d.ts +5 -238
  35. package/dist/index.js +3 -322
  36. package/dist/index.mjs +278 -363
  37. package/dist/index.mjs.map +1 -1
  38. package/dist/internal.cjs +8 -6
  39. package/dist/internal.cjs.map +1 -1
  40. package/dist/internal.d.cts +37 -6
  41. package/dist/internal.d.mts +37 -6
  42. package/dist/internal.d.ts +2 -0
  43. package/dist/internal.js +1 -0
  44. package/dist/internal.mjs +5 -5
  45. package/dist/internal.mjs.map +1 -1
  46. package/dist/{isVariable-B08mggBy.cjs → isVariable-Ba1gLXdB.cjs} +1 -1
  47. package/dist/{isVariable-B08mggBy.cjs.map → isVariable-Ba1gLXdB.cjs.map} +1 -1
  48. package/dist/{isVariable-CYsKFHvR.mjs → isVariable-fAKEB7gF.mjs} +1 -1
  49. package/dist/{isVariable-CYsKFHvR.mjs.map → isVariable-fAKEB7gF.mjs.map} +1 -1
  50. package/dist/locales/getPluralForm.js +2 -2
  51. package/dist/logging/diagnostics.d.ts +18 -0
  52. package/dist/logging/diagnostics.js +64 -0
  53. package/dist/logging/errors.d.ts +1 -1
  54. package/dist/logging/errors.js +64 -11
  55. package/dist/logging/logger.d.ts +0 -3
  56. package/dist/logging/logger.js +0 -3
  57. package/dist/{types-AHtYZIP-.d.mts → types-CdRgQtET.d.cts} +6 -106
  58. package/dist/{types-Bf8_Apq_.d.cts → types-Db2Dn3oN.d.mts} +6 -106
  59. package/dist/types-dir/api/enqueueEntries.d.ts +1 -1
  60. package/dist/types-dir/api/enqueueFiles.d.ts +1 -1
  61. package/dist/types-dir/api/fetchTranslations.d.ts +1 -1
  62. package/dist/types-dir/api/file.d.ts +1 -1
  63. package/dist/types-dir/api/translate.d.ts +1 -1
  64. package/dist/types-dir/api/uploadFiles.d.ts +1 -1
  65. package/dist/types.cjs +7 -16
  66. package/dist/types.d.cts +2 -2
  67. package/dist/types.d.mts +2 -2
  68. package/dist/types.d.ts +10 -13
  69. package/dist/types.js +1 -2
  70. package/dist/types.mjs +1 -15
  71. package/package.json +3 -2
  72. package/dist/IntlCache-CAW8tKhd.cjs +0 -212
  73. package/dist/IntlCache-CAW8tKhd.cjs.map +0 -1
  74. package/dist/IntlCache-WZk0rKvj.mjs +0 -195
  75. package/dist/IntlCache-WZk0rKvj.mjs.map +0 -1
  76. package/dist/base64-2fu94Klt.cjs.map +0 -1
  77. package/dist/base64-DH0STixb.mjs.map +0 -1
  78. package/dist/cache/IntlCache.d.ts +0 -26
  79. package/dist/cache/IntlCache.js +0 -84
  80. package/dist/cache/types.d.ts +0 -32
  81. package/dist/cache/types.js +0 -1
  82. package/dist/core-7RP541eY.cjs +0 -1677
  83. package/dist/core-7RP541eY.cjs.map +0 -1
  84. package/dist/core-I9pWGafA.d.mts +0 -209
  85. package/dist/core-TLJoDpJP.d.cts +0 -209
  86. package/dist/core-isLphYAZ.mjs +0 -1498
  87. package/dist/core-isLphYAZ.mjs.map +0 -1
  88. package/dist/errors/formattingErrors.d.ts +0 -1
  89. package/dist/errors/formattingErrors.js +0 -3
  90. package/dist/formatting/custom-formats/CutoffFormat/CutoffFormat.d.ts +0 -59
  91. package/dist/formatting/custom-formats/CutoffFormat/CutoffFormat.js +0 -147
  92. package/dist/formatting/custom-formats/CutoffFormat/constants.d.ts +0 -4
  93. package/dist/formatting/custom-formats/CutoffFormat/constants.js +0 -30
  94. package/dist/formatting/custom-formats/CutoffFormat/types.d.ts +0 -48
  95. package/dist/formatting/custom-formats/CutoffFormat/types.js +0 -2
  96. package/dist/formatting/format.d.ts +0 -1
  97. package/dist/formatting/format.js +0 -257
  98. package/dist/locales/customLocaleMapping.d.ts +0 -11
  99. package/dist/locales/customLocaleMapping.js +0 -23
  100. package/dist/locales/determineLocale.d.ts +0 -1
  101. package/dist/locales/determineLocale.js +0 -72
  102. package/dist/locales/getLocaleDirection.d.ts +0 -1
  103. package/dist/locales/getLocaleDirection.js +0 -89
  104. package/dist/locales/getLocaleEmoji.d.ts +0 -2
  105. package/dist/locales/getLocaleEmoji.js +0 -319
  106. package/dist/locales/getLocaleName.d.ts +0 -1
  107. package/dist/locales/getLocaleName.js +0 -45
  108. package/dist/locales/getLocaleProperties.d.ts +0 -32
  109. package/dist/locales/getLocaleProperties.js +0 -220
  110. package/dist/locales/getRegionProperties.d.ts +0 -7
  111. package/dist/locales/getRegionProperties.js +0 -61
  112. package/dist/locales/isSameDialect.d.ts +0 -1
  113. package/dist/locales/isSameDialect.js +0 -41
  114. package/dist/locales/isSameLanguage.d.ts +0 -1
  115. package/dist/locales/isSameLanguage.js +0 -20
  116. package/dist/locales/isSupersetLocale.d.ts +0 -1
  117. package/dist/locales/isSupersetLocale.js +0 -22
  118. package/dist/locales/isValidLocale.d.ts +0 -1
  119. package/dist/locales/isValidLocale.js +0 -75
  120. package/dist/locales/requiresTranslation.d.ts +0 -1
  121. package/dist/locales/requiresTranslation.js +0 -32
  122. package/dist/locales/resolveAliasLocale.d.ts +0 -8
  123. package/dist/locales/resolveAliasLocale.js +0 -21
  124. package/dist/locales/resolveCanonicalLocale.d.ts +0 -8
  125. package/dist/locales/resolveCanonicalLocale.js +0 -13
  126. package/dist/logging/warnings.d.ts +0 -2
  127. package/dist/logging/warnings.js +0 -2
  128. package/dist/types-dir/jsx/content.d.ts +0 -61
  129. package/dist/types-dir/jsx/content.js +0 -11
  130. package/dist/types-dir/jsx/variables.d.ts +0 -9
  131. package/dist/types-dir/jsx/variables.js +0 -1
  132. package/dist/types.cjs.map +0 -1
  133. package/dist/types.mjs.map +0 -1
@@ -0,0 +1,64 @@
1
+ function ensureSentence(text) {
2
+ var trimmed = text.trim();
3
+ if (!trimmed)
4
+ return '';
5
+ return /[.!?)]$/.test(trimmed) ? trimmed : "".concat(trimmed, ".");
6
+ }
7
+ function stripSentence(text) {
8
+ var trimmed = text.trim();
9
+ var end = trimmed.length;
10
+ while (end > 0) {
11
+ var char = trimmed[end - 1];
12
+ if (char !== '.' && char !== '!' && char !== '?')
13
+ break;
14
+ end -= 1;
15
+ }
16
+ return trimmed.slice(0, end);
17
+ }
18
+ function lowercaseFirstWord(text) {
19
+ return text.replace(/^[A-Z][a-z]/, function (match) { return match.toLowerCase(); });
20
+ }
21
+ function formatDetails(details) {
22
+ if (!details)
23
+ return '';
24
+ var detailText = Array.isArray(details) ? details.join(', ') : details;
25
+ if (!detailText.trim())
26
+ return '';
27
+ return ensureSentence("Details: ".concat(detailText));
28
+ }
29
+ export function formatDiagnosticErrorDetails(error) {
30
+ if (error == null)
31
+ return undefined;
32
+ return String(error);
33
+ }
34
+ export function createDiagnosticMessage(_a) {
35
+ var source = _a.source, severity = _a.severity, whatHappened = _a.whatHappened, reassurance = _a.reassurance, why = _a.why, fix = _a.fix, wayOut = _a.wayOut, details = _a.details, docsUrl = _a.docsUrl;
36
+ var prefix = source
37
+ ? severity
38
+ ? "".concat(source, " ").concat(severity, ":")
39
+ : "".concat(source, ":")
40
+ : severity
41
+ ? "".concat(severity, ":")
42
+ : '';
43
+ var whatAndWhy = why
44
+ ? "".concat(stripSentence(whatHappened), " because ").concat(lowercaseFirstWord(stripSentence(why)))
45
+ : whatHappened;
46
+ var shouldCombineWayOut = !!fix && !!wayOut && /^[a-z]/.test(stripSentence(wayOut));
47
+ var fixAndWayOut = shouldCombineWayOut
48
+ ? "".concat(stripSentence(fix), ", or ").concat(lowercaseFirstWord(stripSentence(wayOut)))
49
+ : fix;
50
+ var messageParts = [
51
+ whatAndWhy,
52
+ reassurance,
53
+ fixAndWayOut,
54
+ shouldCombineWayOut ? undefined : wayOut,
55
+ formatDetails(details),
56
+ ]
57
+ .filter(function (part) { return !!part; })
58
+ .map(ensureSentence);
59
+ if (docsUrl) {
60
+ messageParts.push("Learn more: ".concat(docsUrl));
61
+ }
62
+ var message = messageParts.join(' ');
63
+ return prefix ? "".concat(prefix, " ").concat(message) : message;
64
+ }
@@ -1,7 +1,7 @@
1
1
  export declare const translationTimeoutError: (timeout: number) => string;
2
2
  export declare const translationRequestFailedError: (error: string) => string;
3
3
  export declare const apiError: (status: number, statusText: string, error: string) => string;
4
- export declare const invalidAuthError = "GT Error: Invalid authentication.";
4
+ export declare const invalidAuthError: string;
5
5
  export declare const noTargetLocaleProvidedError: (functionName: string) => string;
6
6
  export declare const noSourceLocaleProvidedError: (functionName: string) => string;
7
7
  export declare const noProjectIdProvidedError: (functionName: string) => string;
@@ -1,29 +1,82 @@
1
- var GT_ERROR_PREFIX = 'GT Error:';
1
+ import { createDiagnosticMessage } from './diagnostics';
2
+ var GT_SOURCE = 'GT';
2
3
  export var translationTimeoutError = function (timeout) {
3
- return "".concat(GT_ERROR_PREFIX, " Translation request timed out after ").concat(timeout, "ms.");
4
+ return createDiagnosticMessage({
5
+ source: GT_SOURCE,
6
+ severity: 'Error',
7
+ whatHappened: "Translation request timed out after ".concat(timeout, "ms"),
8
+ fix: 'Try again, or increase the request timeout if the source content is large',
9
+ });
4
10
  };
5
11
  export var translationRequestFailedError = function (error) {
6
- return "".concat(GT_ERROR_PREFIX, " Translation request failed. Error: ").concat(error);
12
+ return createDiagnosticMessage({
13
+ source: GT_SOURCE,
14
+ severity: 'Error',
15
+ whatHappened: 'Translation request could not be completed',
16
+ fix: 'Check your network connection and translation credentials, then try again',
17
+ details: error,
18
+ });
7
19
  };
8
20
  export var apiError = function (status, statusText, error) {
9
- return "".concat(GT_ERROR_PREFIX, " API returned error status. Status: ").concat(status, ", Status Text: ").concat(statusText, ", Error: ").concat(error);
21
+ return createDiagnosticMessage({
22
+ source: GT_SOURCE,
23
+ severity: 'Error',
24
+ whatHappened: "The translation API returned ".concat(status, " ").concat(statusText),
25
+ fix: 'Check the request configuration and try again',
26
+ details: error,
27
+ });
10
28
  };
11
- export var invalidAuthError = "".concat(GT_ERROR_PREFIX, " Invalid authentication.");
29
+ export var invalidAuthError = createDiagnosticMessage({
30
+ source: GT_SOURCE,
31
+ severity: 'Error',
32
+ whatHappened: 'Authentication failed',
33
+ fix: 'Check that your API key and project ID are correct',
34
+ });
12
35
  export var noTargetLocaleProvidedError = function (functionName) {
13
- return "".concat(GT_ERROR_PREFIX, " Cannot call `").concat(functionName, "` without a specified locale. Either pass a locale to the `").concat(functionName, "` function or specify a targetLocale in the GT constructor.");
36
+ return createDiagnosticMessage({
37
+ source: GT_SOURCE,
38
+ severity: 'Error',
39
+ whatHappened: "Cannot call `".concat(functionName, "` without a specified locale"),
40
+ fix: "Pass a locale to `".concat(functionName, "` or specify targetLocale in the GT constructor"),
41
+ });
14
42
  };
15
43
  export var noSourceLocaleProvidedError = function (functionName) {
16
- return "".concat(GT_ERROR_PREFIX, " Cannot call `").concat(functionName, "` without a specified locale. Either pass a locale to the `").concat(functionName, "` function or specify a sourceLocale in the GT constructor.");
44
+ return createDiagnosticMessage({
45
+ source: GT_SOURCE,
46
+ severity: 'Error',
47
+ whatHappened: "Cannot call `".concat(functionName, "` without a specified locale"),
48
+ fix: "Pass a locale to `".concat(functionName, "` or specify sourceLocale in the GT constructor"),
49
+ });
17
50
  };
18
51
  export var noProjectIdProvidedError = function (functionName) {
19
- return "".concat(GT_ERROR_PREFIX, " Cannot call `").concat(functionName, "` without a specified project ID. Either pass a project ID to the `").concat(functionName, "` function or specify a projectId in the GT constructor.");
52
+ return createDiagnosticMessage({
53
+ source: GT_SOURCE,
54
+ severity: 'Error',
55
+ whatHappened: "Cannot call `".concat(functionName, "` without a specified project ID"),
56
+ fix: "Pass a project ID to `".concat(functionName, "` or specify projectId in the GT constructor"),
57
+ });
20
58
  };
21
59
  export var noApiKeyProvidedError = function (functionName) {
22
- return "".concat(GT_ERROR_PREFIX, " Cannot call `").concat(functionName, "` without a specified API key. Either pass an API key to the `").concat(functionName, "` function or specify an apiKey in the GT constructor.");
60
+ return createDiagnosticMessage({
61
+ source: GT_SOURCE,
62
+ severity: 'Error',
63
+ whatHappened: "Cannot call `".concat(functionName, "` without a specified API key"),
64
+ fix: "Pass an API key to `".concat(functionName, "` or specify apiKey in the GT constructor"),
65
+ });
23
66
  };
24
67
  export var invalidLocaleError = function (locale) {
25
- return "".concat(GT_ERROR_PREFIX, " Invalid locale: ").concat(locale, ".");
68
+ return createDiagnosticMessage({
69
+ source: GT_SOURCE,
70
+ severity: 'Error',
71
+ whatHappened: "Locale \"".concat(locale, "\" is not valid"),
72
+ fix: 'Use a valid BCP 47 locale code or add a custom mapping',
73
+ });
26
74
  };
27
75
  export var invalidLocalesError = function (locales) {
28
- return "".concat(GT_ERROR_PREFIX, " Invalid locales: ").concat(locales.join(', '), ".");
76
+ return createDiagnosticMessage({
77
+ source: GT_SOURCE,
78
+ severity: 'Error',
79
+ whatHappened: "These locales are not valid: ".concat(locales.join(', ')),
80
+ fix: 'Use valid BCP 47 locale codes or add custom mappings',
81
+ });
29
82
  };
@@ -114,8 +114,5 @@ export declare const info: (message: string, context?: string, metadata?: LogMet
114
114
  export declare const warn: (message: string, context?: string, metadata?: LogMetadata) => void;
115
115
  export declare const error: (message: string, context?: string, metadata?: LogMetadata) => void;
116
116
  export declare const fetchLogger: ContextLogger;
117
- export declare const validationLogger: ContextLogger;
118
- export declare const formattingLogger: ContextLogger;
119
- export declare const localeLogger: ContextLogger;
120
117
  export declare const gtInstanceLogger: ContextLogger;
121
118
  export { Logger as GTLogger };
@@ -251,9 +251,6 @@ export var warn = function (message, context, metadata) { return defaultLogger.w
251
251
  export var error = function (message, context, metadata) { return defaultLogger.error(message, context, metadata); };
252
252
  // Create context-specific loggers for different parts of the system
253
253
  export var fetchLogger = defaultLogger.child('fetch');
254
- export var validationLogger = defaultLogger.child('validation');
255
- export var formattingLogger = defaultLogger.child('formatting');
256
- export var localeLogger = defaultLogger.child('locale');
257
254
  export var gtInstanceLogger = defaultLogger.child('GT instance');
258
255
  // Export types and classes
259
256
  export { Logger as GTLogger };
@@ -1,104 +1,5 @@
1
- //#region src/locales/customLocaleMapping.d.ts
2
- type CustomMapping = Record<string, string | Partial<LocaleProperties>>;
3
- //#endregion
4
- //#region src/locales/getLocaleProperties.d.ts
5
- type LocaleProperties = {
6
- code: string;
7
- name: string;
8
- nativeName: string;
9
- languageCode: string;
10
- languageName: string;
11
- nativeLanguageName: string;
12
- nameWithRegionCode: string;
13
- nativeNameWithRegionCode: string;
14
- regionCode: string;
15
- regionName: string;
16
- nativeRegionName: string;
17
- scriptCode: string;
18
- scriptName: string;
19
- nativeScriptName: string;
20
- maximizedCode: string;
21
- maximizedName: string;
22
- nativeMaximizedName: string;
23
- minimizedCode: string;
24
- minimizedName: string;
25
- nativeMinimizedName: string;
26
- emoji: string;
27
- };
28
- //#endregion
29
- //#region src/types-dir/jsx/variables.d.ts
30
- type VariableType = 'v' | 'n' | 'd' | 'c' | 'rt';
31
- /**
32
- * Variables are used to store the variable name and type.
33
- */
34
- type Variable = {
35
- k: string;
36
- i?: number;
37
- v?: VariableType;
38
- };
39
- //#endregion
40
- //#region src/types-dir/jsx/content.d.ts
41
- /**
42
- * Map of data-_gt properties to their corresponding React props
43
- */
44
- declare const HTML_CONTENT_PROPS: {
45
- readonly pl: "placeholder";
46
- readonly ti: "title";
47
- readonly alt: "alt";
48
- readonly arl: "aria-label";
49
- readonly arb: "aria-labelledby";
50
- readonly ard: "aria-describedby";
51
- };
52
- type HtmlContentPropKeysRecord = Partial<Record<keyof typeof HTML_CONTENT_PROPS, string>>;
53
- type HtmlContentPropValuesRecord = Partial<Record<(typeof HTML_CONTENT_PROPS)[keyof typeof HTML_CONTENT_PROPS], string>>;
54
- /**
55
- * GTProp is an internal property used to contain data for translating and rendering elements.
56
- * note, transformations are only read on the server side if they are 'plural' or 'branch'
57
- */
58
- type GTProp = {
59
- b?: Record<string, JsxChildren>;
60
- t?: 'p' | 'b';
61
- } & HtmlContentPropKeysRecord;
62
- type JsxElement = {
63
- t?: string;
64
- i?: number;
65
- d?: GTProp;
66
- c?: JsxChildren;
67
- };
68
- type JsxChild = string | JsxElement | Variable;
69
- /**
70
- * The format of the string content
71
- */
72
- type StringFormat = 'ICU' | 'I18NEXT' | 'STRING';
73
- /**
74
- * The format of the content.
75
- */
76
- type DataFormat = 'JSX' | StringFormat;
77
- /**
78
- * String format content.
79
- */
80
- type StringContent = IcuMessage | StringMessage | I18nextMessage;
81
- /**
82
- * A content type representing JSX, ICU, and I18next messages.
83
- */
84
- type Content = JsxChildren | StringContent;
85
- /**
86
- * A content type representing JSX elements.
87
- */
88
- type JsxChildren = JsxChild | JsxChild[];
89
- /**
90
- * A content type representing ICU messages.
91
- */
92
- type IcuMessage = string;
93
- /**
94
- * A content type representing I18next messages.
95
- */
96
- type I18nextMessage = string;
97
- /**
98
- * A content type representing plain strings.
99
- */
100
- type StringMessage = string;
101
- //#endregion
1
+ import { Content, Content as Content$1, CustomMapping as CustomMapping$1, CustomRegionMapping as CustomRegionMapping$1, CutoffFormatOptions as CutoffFormatOptions$1, DataFormat, DataFormat as DataFormat$1, FormatVariables as FormatVariables$1, GTProp, HTML_CONTENT_PROPS, HtmlContentPropKeysRecord, HtmlContentPropValuesRecord, I18nextMessage, I18nextMessage as I18nextMessage$1, IcuMessage, IcuMessage as IcuMessage$1, JsxChild, JsxChildren, JsxChildren as JsxChildren$1, JsxElement, LocaleProperties as LocaleProperties$1, StringContent, StringFormat as StringFormat$1, StringMessage, StringMessage as StringMessage$1, Variable, Variable as Variable$1, VariableType } from "@generaltranslation/format/types";
2
+
102
3
  //#region src/types-dir/api/entry.d.ts
103
4
  /**
104
5
  * ActionType is the type of action to perform on the request.
@@ -119,7 +20,7 @@ type EntryMetadata = {
119
20
  hash?: string;
120
21
  context?: string;
121
22
  maxChars?: number;
122
- dataFormat?: DataFormat;
23
+ dataFormat?: DataFormat$1;
123
24
  actionType?: ActionType;
124
25
  };
125
26
  type RuntimeTranslateManyOptions = {
@@ -135,7 +36,7 @@ type TranslateOptions = RuntimeTranslateManyOptions & {
135
36
  * Can be a plain string or an object with source and entry metadata fields.
136
37
  */
137
38
  type TranslateManyEntry = string | {
138
- source: Content;
39
+ source: Content$1;
139
40
  metadata?: EntryMetadata;
140
41
  };
141
42
  //#endregion
@@ -682,7 +583,6 @@ type Metadata = {
682
583
  filePaths?: string[];
683
584
  [key: string]: unknown;
684
585
  };
685
- type FormatVariables = Record<string, string | number | boolean | null | undefined | Date>;
686
586
  /**
687
587
  * @deprecated This type is deprecated and will be removed in a future version.
688
588
  */
@@ -763,5 +663,5 @@ type TranslationRequestConfig = {
763
663
  apiKey?: string;
764
664
  };
765
665
  //#endregion
766
- export { FileReference as $, BranchDataResult as A, StringContent as At, FileUpload as B, ProcessMovesOptions as C, HtmlContentPropKeysRecord as Ct, FileDataQuery as D, JsxChild as Dt, OrphanedFile as E, IcuMessage as Et, DownloadFileOptions as F, LocaleProperties as Ft, FetchTranslationsOptions as G, UploadFilesResponse as H, PublishFileEntry as I, CustomMapping as It, DownloadFileBatchOptions as J, FetchTranslationsResult as K, PublishFilesResult as L, TranslationError as M, StringMessage as Mt, TranslationResult as N, Variable as Nt, FileDataResult as O, JsxChildren as Ot, TranslationResultReference as P, VariableType as Pt, FileFormat as Q, EnqueueEntriesOptions as R, MoveResult as S, HTML_CONTENT_PROPS as St, GetOrphanedFilesResult as T, I18nextMessage as Tt, CreateTagOptions as U, UploadFilesOptions as V, CreateTagResult as W, DownloadFileBatchResult as X, DownloadFileBatchRequest as Y, DownloadedFile as Z, AwaitJobsResult as _, TranslateManyEntry as _t, Metadata as a, CheckFileTranslationsOptions as at, JobStatus as b, DataFormat as bt, Update as c, FileTranslationQuery as ct, Transformation as d, JsonValue as dt, FileReferenceIds as et, TransformationPrefix as f, TranslationStatusResult as ft, AwaitJobsOptions as g, RuntimeTranslateManyOptions as gt, SubmitUserEditDiffsPayload as h, EntryMetadata as ht, JsxTranslationResult as i, Updates as it, TranslateManyResult as j, StringFormat as jt, BranchQuery as k, JsxElement as kt, _Content as l, JsonObject as lt, SubmitUserEditDiff as m, ActionType as mt, FormatVariables as n, EnqueueFilesOptions as nt, Request as o, FileQuery as ot, VariableTransformationSuffix as p, HashMetadata as pt, RetrievedTranslations as q, IcuTranslationResult as r, EnqueueFilesResult as rt, TranslationRequestConfig as s, FileQueryResult as st, ContentTranslationResult as t, FileToUpload as tt, InjectionType as u, JsonPrimitive as ut, JobResult as v, TranslateOptions as vt, ProcessMovesResponse as w, HtmlContentPropValuesRecord as wt, MoveMapping as x, GTProp as xt, CheckJobStatusResult as y, Content as yt, EnqueueEntriesResult as z };
767
- //# sourceMappingURL=types-AHtYZIP-.d.mts.map
666
+ export { TranslationResult as $, InjectionType as A, JsonPrimitive as At, JobStatus as B, StringFormat$1 as C, EnqueueFilesResult as Ct, Variable$1 as D, FileQueryResult as Dt, Update as E, FileQuery as Et, SubmitUserEditDiffsPayload as F, EntryMetadata as Ft, GetOrphanedFilesResult as G, MoveResult as H, AwaitJobsOptions as I, RuntimeTranslateManyOptions as It, FileDataResult as J, OrphanedFile as K, AwaitJobsResult as L, TranslateManyEntry as Lt, TransformationPrefix as M, TranslationStatusResult as Mt, VariableTransformationSuffix as N, HashMetadata as Nt, VariableType as O, FileTranslationQuery as Ot, SubmitUserEditDiff as P, ActionType as Pt, TranslationError as Q, JobResult as R, TranslateOptions as Rt, StringContent as S, EnqueueFilesOptions as St, TranslationRequestConfig as T, CheckFileTranslationsOptions as Tt, ProcessMovesOptions as U, MoveMapping as V, ProcessMovesResponse as W, BranchDataResult as X, BranchQuery as Y, TranslateManyResult as Z, JsxElement as _, DownloadedFile as _t, CutoffFormatOptions$1 as a, EnqueueEntriesResult as at, Metadata as b, FileReferenceIds as bt, GTProp as c, UploadFilesResponse as ct, HtmlContentPropValuesRecord as d, FetchTranslationsOptions as dt, TranslationResultReference as et, I18nextMessage$1 as f, FetchTranslationsResult as ft, JsxChildren$1 as g, DownloadFileBatchResult as gt, JsxChild as h, DownloadFileBatchRequest as ht, CustomRegionMapping$1 as i, EnqueueEntriesOptions as it, Transformation as j, JsonValue as jt, _Content as k, JsonObject as kt, HTML_CONTENT_PROPS as l, CreateTagOptions as lt, IcuTranslationResult as m, DownloadFileBatchOptions as mt, ContentTranslationResult as n, PublishFileEntry as nt, DataFormat$1 as o, FileUpload as ot, IcuMessage$1 as p, RetrievedTranslations as pt, FileDataQuery as q, CustomMapping$1 as r, PublishFilesResult as rt, FormatVariables$1 as s, UploadFilesOptions as st, Content$1 as t, DownloadFileOptions as tt, HtmlContentPropKeysRecord as u, CreateTagResult as ut, JsxTranslationResult as v, FileFormat as vt, StringMessage$1 as w, Updates as wt, Request as x, FileToUpload as xt, LocaleProperties$1 as y, FileReference as yt, CheckJobStatusResult as z };
667
+ //# sourceMappingURL=types-CdRgQtET.d.cts.map
@@ -1,104 +1,5 @@
1
- //#region src/locales/customLocaleMapping.d.ts
2
- type CustomMapping = Record<string, string | Partial<LocaleProperties>>;
3
- //#endregion
4
- //#region src/locales/getLocaleProperties.d.ts
5
- type LocaleProperties = {
6
- code: string;
7
- name: string;
8
- nativeName: string;
9
- languageCode: string;
10
- languageName: string;
11
- nativeLanguageName: string;
12
- nameWithRegionCode: string;
13
- nativeNameWithRegionCode: string;
14
- regionCode: string;
15
- regionName: string;
16
- nativeRegionName: string;
17
- scriptCode: string;
18
- scriptName: string;
19
- nativeScriptName: string;
20
- maximizedCode: string;
21
- maximizedName: string;
22
- nativeMaximizedName: string;
23
- minimizedCode: string;
24
- minimizedName: string;
25
- nativeMinimizedName: string;
26
- emoji: string;
27
- };
28
- //#endregion
29
- //#region src/types-dir/jsx/variables.d.ts
30
- type VariableType = 'v' | 'n' | 'd' | 'c' | 'rt';
31
- /**
32
- * Variables are used to store the variable name and type.
33
- */
34
- type Variable = {
35
- k: string;
36
- i?: number;
37
- v?: VariableType;
38
- };
39
- //#endregion
40
- //#region src/types-dir/jsx/content.d.ts
41
- /**
42
- * Map of data-_gt properties to their corresponding React props
43
- */
44
- declare const HTML_CONTENT_PROPS: {
45
- readonly pl: "placeholder";
46
- readonly ti: "title";
47
- readonly alt: "alt";
48
- readonly arl: "aria-label";
49
- readonly arb: "aria-labelledby";
50
- readonly ard: "aria-describedby";
51
- };
52
- type HtmlContentPropKeysRecord = Partial<Record<keyof typeof HTML_CONTENT_PROPS, string>>;
53
- type HtmlContentPropValuesRecord = Partial<Record<(typeof HTML_CONTENT_PROPS)[keyof typeof HTML_CONTENT_PROPS], string>>;
54
- /**
55
- * GTProp is an internal property used to contain data for translating and rendering elements.
56
- * note, transformations are only read on the server side if they are 'plural' or 'branch'
57
- */
58
- type GTProp = {
59
- b?: Record<string, JsxChildren>;
60
- t?: 'p' | 'b';
61
- } & HtmlContentPropKeysRecord;
62
- type JsxElement = {
63
- t?: string;
64
- i?: number;
65
- d?: GTProp;
66
- c?: JsxChildren;
67
- };
68
- type JsxChild = string | JsxElement | Variable;
69
- /**
70
- * The format of the string content
71
- */
72
- type StringFormat = 'ICU' | 'I18NEXT' | 'STRING';
73
- /**
74
- * The format of the content.
75
- */
76
- type DataFormat = 'JSX' | StringFormat;
77
- /**
78
- * String format content.
79
- */
80
- type StringContent = IcuMessage | StringMessage | I18nextMessage;
81
- /**
82
- * A content type representing JSX, ICU, and I18next messages.
83
- */
84
- type Content = JsxChildren | StringContent;
85
- /**
86
- * A content type representing JSX elements.
87
- */
88
- type JsxChildren = JsxChild | JsxChild[];
89
- /**
90
- * A content type representing ICU messages.
91
- */
92
- type IcuMessage = string;
93
- /**
94
- * A content type representing I18next messages.
95
- */
96
- type I18nextMessage = string;
97
- /**
98
- * A content type representing plain strings.
99
- */
100
- type StringMessage = string;
101
- //#endregion
1
+ import { Content, Content as Content$1, CustomMapping as CustomMapping$1, CustomRegionMapping as CustomRegionMapping$1, CutoffFormatOptions as CutoffFormatOptions$1, DataFormat, DataFormat as DataFormat$1, FormatVariables as FormatVariables$1, GTProp, HTML_CONTENT_PROPS, HtmlContentPropKeysRecord, HtmlContentPropValuesRecord, I18nextMessage, I18nextMessage as I18nextMessage$1, IcuMessage, IcuMessage as IcuMessage$1, JsxChild, JsxChildren, JsxChildren as JsxChildren$1, JsxElement, LocaleProperties as LocaleProperties$1, StringContent, StringFormat as StringFormat$1, StringMessage, StringMessage as StringMessage$1, Variable, Variable as Variable$1, VariableType } from "@generaltranslation/format/types";
2
+
102
3
  //#region src/types-dir/api/entry.d.ts
103
4
  /**
104
5
  * ActionType is the type of action to perform on the request.
@@ -119,7 +20,7 @@ type EntryMetadata = {
119
20
  hash?: string;
120
21
  context?: string;
121
22
  maxChars?: number;
122
- dataFormat?: DataFormat;
23
+ dataFormat?: DataFormat$1;
123
24
  actionType?: ActionType;
124
25
  };
125
26
  type RuntimeTranslateManyOptions = {
@@ -135,7 +36,7 @@ type TranslateOptions = RuntimeTranslateManyOptions & {
135
36
  * Can be a plain string or an object with source and entry metadata fields.
136
37
  */
137
38
  type TranslateManyEntry = string | {
138
- source: Content;
39
+ source: Content$1;
139
40
  metadata?: EntryMetadata;
140
41
  };
141
42
  //#endregion
@@ -682,7 +583,6 @@ type Metadata = {
682
583
  filePaths?: string[];
683
584
  [key: string]: unknown;
684
585
  };
685
- type FormatVariables = Record<string, string | number | boolean | null | undefined | Date>;
686
586
  /**
687
587
  * @deprecated This type is deprecated and will be removed in a future version.
688
588
  */
@@ -763,5 +663,5 @@ type TranslationRequestConfig = {
763
663
  apiKey?: string;
764
664
  };
765
665
  //#endregion
766
- export { FileReference as $, BranchDataResult as A, StringContent as At, FileUpload as B, ProcessMovesOptions as C, HtmlContentPropKeysRecord as Ct, FileDataQuery as D, JsxChild as Dt, OrphanedFile as E, IcuMessage as Et, DownloadFileOptions as F, LocaleProperties as Ft, FetchTranslationsOptions as G, UploadFilesResponse as H, PublishFileEntry as I, CustomMapping as It, DownloadFileBatchOptions as J, FetchTranslationsResult as K, PublishFilesResult as L, TranslationError as M, StringMessage as Mt, TranslationResult as N, Variable as Nt, FileDataResult as O, JsxChildren as Ot, TranslationResultReference as P, VariableType as Pt, FileFormat as Q, EnqueueEntriesOptions as R, MoveResult as S, HTML_CONTENT_PROPS as St, GetOrphanedFilesResult as T, I18nextMessage as Tt, CreateTagOptions as U, UploadFilesOptions as V, CreateTagResult as W, DownloadFileBatchResult as X, DownloadFileBatchRequest as Y, DownloadedFile as Z, AwaitJobsResult as _, TranslateManyEntry as _t, Metadata as a, CheckFileTranslationsOptions as at, JobStatus as b, DataFormat as bt, Update as c, FileTranslationQuery as ct, Transformation as d, JsonValue as dt, FileReferenceIds as et, TransformationPrefix as f, TranslationStatusResult as ft, AwaitJobsOptions as g, RuntimeTranslateManyOptions as gt, SubmitUserEditDiffsPayload as h, EntryMetadata as ht, JsxTranslationResult as i, Updates as it, TranslateManyResult as j, StringFormat as jt, BranchQuery as k, JsxElement as kt, _Content as l, JsonObject as lt, SubmitUserEditDiff as m, ActionType as mt, FormatVariables as n, EnqueueFilesOptions as nt, Request as o, FileQuery as ot, VariableTransformationSuffix as p, HashMetadata as pt, RetrievedTranslations as q, IcuTranslationResult as r, EnqueueFilesResult as rt, TranslationRequestConfig as s, FileQueryResult as st, ContentTranslationResult as t, FileToUpload as tt, InjectionType as u, JsonPrimitive as ut, JobResult as v, TranslateOptions as vt, ProcessMovesResponse as w, HtmlContentPropValuesRecord as wt, MoveMapping as x, GTProp as xt, CheckJobStatusResult as y, Content as yt, EnqueueEntriesResult as z };
767
- //# sourceMappingURL=types-Bf8_Apq_.d.cts.map
666
+ export { TranslationResult as $, InjectionType as A, JsonPrimitive as At, JobStatus as B, StringFormat$1 as C, EnqueueFilesResult as Ct, Variable$1 as D, FileQueryResult as Dt, Update as E, FileQuery as Et, SubmitUserEditDiffsPayload as F, EntryMetadata as Ft, GetOrphanedFilesResult as G, MoveResult as H, AwaitJobsOptions as I, RuntimeTranslateManyOptions as It, FileDataResult as J, OrphanedFile as K, AwaitJobsResult as L, TranslateManyEntry as Lt, TransformationPrefix as M, TranslationStatusResult as Mt, VariableTransformationSuffix as N, HashMetadata as Nt, VariableType as O, FileTranslationQuery as Ot, SubmitUserEditDiff as P, ActionType as Pt, TranslationError as Q, JobResult as R, TranslateOptions as Rt, StringContent as S, EnqueueFilesOptions as St, TranslationRequestConfig as T, CheckFileTranslationsOptions as Tt, ProcessMovesOptions as U, MoveMapping as V, ProcessMovesResponse as W, BranchDataResult as X, BranchQuery as Y, TranslateManyResult as Z, JsxElement as _, DownloadedFile as _t, CutoffFormatOptions$1 as a, EnqueueEntriesResult as at, Metadata as b, FileReferenceIds as bt, GTProp as c, UploadFilesResponse as ct, HtmlContentPropValuesRecord as d, FetchTranslationsOptions as dt, TranslationResultReference as et, I18nextMessage$1 as f, FetchTranslationsResult as ft, JsxChildren$1 as g, DownloadFileBatchResult as gt, JsxChild as h, DownloadFileBatchRequest as ht, CustomRegionMapping$1 as i, EnqueueEntriesOptions as it, Transformation as j, JsonValue as jt, _Content as k, JsonObject as kt, HTML_CONTENT_PROPS as l, CreateTagOptions as lt, IcuTranslationResult as m, DownloadFileBatchOptions as mt, ContentTranslationResult as n, PublishFileEntry as nt, DataFormat$1 as o, FileUpload as ot, IcuMessage$1 as p, RetrievedTranslations as pt, FileDataQuery as q, CustomMapping$1 as r, PublishFilesResult as rt, FormatVariables$1 as s, UploadFilesOptions as st, Content$1 as t, DownloadFileOptions as tt, HtmlContentPropKeysRecord as u, CreateTagResult as ut, JsxTranslationResult as v, FileFormat as vt, StringMessage$1 as w, Updates as wt, Request as x, FileToUpload as xt, LocaleProperties$1 as y, FileReference as yt, CheckJobStatusResult as z };
667
+ //# sourceMappingURL=types-Db2Dn3oN.d.mts.map
@@ -1,4 +1,4 @@
1
- import { DataFormat } from '../jsx/content';
1
+ import type { DataFormat } from '@generaltranslation/format/types';
2
2
  export type { Updates } from './enqueueFiles';
3
3
  export type EnqueueEntriesOptions = {
4
4
  timeout?: number;
@@ -1,4 +1,4 @@
1
- import { DataFormat, JsxChildren } from '../jsx/content';
1
+ import type { DataFormat, JsxChildren } from '@generaltranslation/format/types';
2
2
  type UpdateMetadata = {
3
3
  id?: string;
4
4
  hash?: string;
@@ -1,4 +1,4 @@
1
- import type { Content } from '../jsx/content';
1
+ import type { Content } from '@generaltranslation/format/types';
2
2
  export type FetchTranslationsOptions = {
3
3
  timeout?: number;
4
4
  };
@@ -1,4 +1,4 @@
1
- import { DataFormat } from '../jsx/content';
1
+ import type { DataFormat } from '@generaltranslation/format/types';
2
2
  import { Updates } from './enqueueFiles';
3
3
  import type { JsonObject } from './json';
4
4
  export type FileFormat = 'GTJSON' | 'JSON' | 'PO' | 'POT' | 'YAML' | 'MDX' | 'MD' | 'TS' | 'JS' | 'HTML' | 'TXT' | 'TWILIO_CONTENT_JSON';
@@ -1,4 +1,4 @@
1
- import { I18nextMessage, IcuMessage, JsxChildren, StringMessage } from '../jsx/content';
1
+ import { I18nextMessage, IcuMessage, JsxChildren, StringMessage } from '@generaltranslation/format/types';
2
2
  /**
3
3
  * TranslationResultReference is used to store the reference for a translation result.
4
4
  */
@@ -1,4 +1,4 @@
1
- import { DataFormat } from '../jsx/content';
1
+ import type { DataFormat } from '@generaltranslation/format/types';
2
2
  import { FileFormat, FileReference, type FormatMetadata } from './file';
3
3
  /**
4
4
  * Metadata stored alongside GTJSON file entries.
package/dist/types.cjs CHANGED
@@ -1,17 +1,8 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- //#region src/types-dir/jsx/content.ts
3
- /**
4
- * Map of data-_gt properties to their corresponding React props
5
- */
6
- const HTML_CONTENT_PROPS = {
7
- pl: "placeholder",
8
- ti: "title",
9
- alt: "alt",
10
- arl: "aria-label",
11
- arb: "aria-labelledby",
12
- ard: "aria-describedby"
13
- };
14
- //#endregion
15
- exports.HTML_CONTENT_PROPS = HTML_CONTENT_PROPS;
16
-
17
- //# sourceMappingURL=types.cjs.map
2
+ let _generaltranslation_format_types = require("@generaltranslation/format/types");
3
+ Object.defineProperty(exports, "HTML_CONTENT_PROPS", {
4
+ enumerable: true,
5
+ get: function() {
6
+ return _generaltranslation_format_types.HTML_CONTENT_PROPS;
7
+ }
8
+ });
package/dist/types.d.cts CHANGED
@@ -1,2 +1,2 @@
1
- import { $ as FileReference, A as BranchDataResult, At as StringContent, B as FileUpload, C as ProcessMovesOptions, Ct as HtmlContentPropKeysRecord, D as FileDataQuery, Dt as JsxChild, E as OrphanedFile, Et as IcuMessage, F as DownloadFileOptions, Ft as LocaleProperties, G as FetchTranslationsOptions, I as PublishFileEntry, It as CustomMapping, J as DownloadFileBatchOptions, K as FetchTranslationsResult, L as PublishFilesResult, M as TranslationError, Mt as StringMessage, N as TranslationResult, Nt as Variable, O as FileDataResult, Ot as JsxChildren, P as TranslationResultReference, Pt as VariableType, Q as FileFormat, R as EnqueueEntriesOptions, S as MoveResult, St as HTML_CONTENT_PROPS, T as GetOrphanedFilesResult, Tt as I18nextMessage, U as CreateTagOptions, W as CreateTagResult, X as DownloadFileBatchResult, Z as DownloadedFile, _ as AwaitJobsResult, _t as TranslateManyEntry, a as Metadata, at as CheckFileTranslationsOptions, b as JobStatus, bt as DataFormat, c as Update, ct as FileTranslationQuery, d as Transformation, dt as JsonValue, f as TransformationPrefix, ft as TranslationStatusResult, g as AwaitJobsOptions, h as SubmitUserEditDiffsPayload, ht as EntryMetadata, i as JsxTranslationResult, it as Updates, j as TranslateManyResult, jt as StringFormat, k as BranchQuery, kt as JsxElement, l as _Content, lt as JsonObject, m as SubmitUserEditDiff, mt as ActionType, n as FormatVariables, nt as EnqueueFilesOptions, o as Request, p as VariableTransformationSuffix, pt as HashMetadata, q as RetrievedTranslations, r as IcuTranslationResult, rt as EnqueueFilesResult, s as TranslationRequestConfig, t as ContentTranslationResult, tt as FileToUpload, u as InjectionType, ut as JsonPrimitive, v as JobResult, w as ProcessMovesResponse, wt as HtmlContentPropValuesRecord, x as MoveMapping, xt as GTProp, y as CheckJobStatusResult, yt as Content, z as EnqueueEntriesResult } from "./types-Bf8_Apq_.cjs";
2
- export { AwaitJobsOptions, AwaitJobsResult, BranchDataResult, BranchQuery, CheckFileTranslationsOptions, CheckJobStatusResult, Content, ContentTranslationResult, CreateTagOptions, CreateTagResult, CustomMapping, DataFormat, DownloadFileBatchOptions, DownloadFileBatchResult, DownloadFileOptions, DownloadedFile, EnqueueEntriesOptions, EnqueueEntriesResult, EnqueueFilesOptions, EnqueueFilesResult, ActionType as EntryActionType, EntryMetadata, FetchTranslationsOptions, FetchTranslationsResult, FileDataQuery, FileDataResult, FileFormat, FileReference, FileToUpload, FileTranslationQuery, FileUpload, FormatVariables, GTProp, GetOrphanedFilesResult, HTML_CONTENT_PROPS, HashMetadata, HtmlContentPropKeysRecord, HtmlContentPropValuesRecord, I18nextMessage, IcuMessage, IcuTranslationResult, InjectionType, JobResult, JobStatus, JsonObject, JsonPrimitive, JsonValue, JsxChild, JsxChildren, JsxElement, JsxTranslationResult, LocaleProperties, Metadata, MoveMapping, MoveResult, OrphanedFile, ProcessMovesOptions, ProcessMovesResponse, PublishFileEntry, PublishFilesResult, Request, RetrievedTranslations, StringContent, StringFormat, StringMessage, SubmitUserEditDiff, SubmitUserEditDiffsPayload, Transformation, TransformationPrefix, TranslateManyEntry, TranslateManyResult, TranslationError, TranslationRequestConfig, TranslationResult, TranslationResultReference, TranslationStatusResult, Update, Updates, Variable, VariableTransformationSuffix, VariableType, _Content };
1
+ import { $ as TranslationResult, A as InjectionType, At as JsonPrimitive, B as JobStatus, C as StringFormat, Ct as EnqueueFilesResult, D as Variable, E as Update, F as SubmitUserEditDiffsPayload, Ft as EntryMetadata, G as GetOrphanedFilesResult, H as MoveResult, I as AwaitJobsOptions, J as FileDataResult, K as OrphanedFile, L as AwaitJobsResult, Lt as TranslateManyEntry, M as TransformationPrefix, Mt as TranslationStatusResult, N as VariableTransformationSuffix, Nt as HashMetadata, O as VariableType, Ot as FileTranslationQuery, P as SubmitUserEditDiff, Pt as ActionType, Q as TranslationError, R as JobResult, S as StringContent, St as EnqueueFilesOptions, T as TranslationRequestConfig, Tt as CheckFileTranslationsOptions, U as ProcessMovesOptions, V as MoveMapping, W as ProcessMovesResponse, X as BranchDataResult, Y as BranchQuery, Z as TranslateManyResult, _ as JsxElement, _t as DownloadedFile, a as CutoffFormatOptions, at as EnqueueEntriesResult, b as Metadata, c as GTProp, d as HtmlContentPropValuesRecord, dt as FetchTranslationsOptions, et as TranslationResultReference, f as I18nextMessage, ft as FetchTranslationsResult, g as JsxChildren, gt as DownloadFileBatchResult, h as JsxChild, i as CustomRegionMapping, it as EnqueueEntriesOptions, j as Transformation, jt as JsonValue, k as _Content, kt as JsonObject, l as HTML_CONTENT_PROPS, lt as CreateTagOptions, m as IcuTranslationResult, mt as DownloadFileBatchOptions, n as ContentTranslationResult, nt as PublishFileEntry, o as DataFormat, ot as FileUpload, p as IcuMessage, pt as RetrievedTranslations, q as FileDataQuery, r as CustomMapping, rt as PublishFilesResult, s as FormatVariables, t as Content, tt as DownloadFileOptions, u as HtmlContentPropKeysRecord, ut as CreateTagResult, v as JsxTranslationResult, vt as FileFormat, w as StringMessage, wt as Updates, x as Request, xt as FileToUpload, y as LocaleProperties, yt as FileReference, z as CheckJobStatusResult } from "./types-CdRgQtET.cjs";
2
+ export { AwaitJobsOptions, AwaitJobsResult, BranchDataResult, BranchQuery, CheckFileTranslationsOptions, CheckJobStatusResult, Content, ContentTranslationResult, CreateTagOptions, CreateTagResult, CustomMapping, CustomRegionMapping, CutoffFormatOptions, DataFormat, DownloadFileBatchOptions, DownloadFileBatchResult, DownloadFileOptions, DownloadedFile, EnqueueEntriesOptions, EnqueueEntriesResult, EnqueueFilesOptions, EnqueueFilesResult, ActionType as EntryActionType, EntryMetadata, FetchTranslationsOptions, FetchTranslationsResult, FileDataQuery, FileDataResult, FileFormat, FileReference, FileToUpload, FileTranslationQuery, FileUpload, FormatVariables, GTProp, GetOrphanedFilesResult, HTML_CONTENT_PROPS, HashMetadata, HtmlContentPropKeysRecord, HtmlContentPropValuesRecord, I18nextMessage, IcuMessage, IcuTranslationResult, InjectionType, JobResult, JobStatus, JsonObject, JsonPrimitive, JsonValue, JsxChild, JsxChildren, JsxElement, JsxTranslationResult, LocaleProperties, Metadata, MoveMapping, MoveResult, OrphanedFile, ProcessMovesOptions, ProcessMovesResponse, PublishFileEntry, PublishFilesResult, Request, RetrievedTranslations, StringContent, StringFormat, StringMessage, SubmitUserEditDiff, SubmitUserEditDiffsPayload, Transformation, TransformationPrefix, TranslateManyEntry, TranslateManyResult, TranslationError, TranslationRequestConfig, TranslationResult, TranslationResultReference, TranslationStatusResult, Update, Updates, Variable, VariableTransformationSuffix, VariableType, _Content };
package/dist/types.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- import { $ as FileReference, A as BranchDataResult, At as StringContent, B as FileUpload, C as ProcessMovesOptions, Ct as HtmlContentPropKeysRecord, D as FileDataQuery, Dt as JsxChild, E as OrphanedFile, Et as IcuMessage, F as DownloadFileOptions, Ft as LocaleProperties, G as FetchTranslationsOptions, I as PublishFileEntry, It as CustomMapping, J as DownloadFileBatchOptions, K as FetchTranslationsResult, L as PublishFilesResult, M as TranslationError, Mt as StringMessage, N as TranslationResult, Nt as Variable, O as FileDataResult, Ot as JsxChildren, P as TranslationResultReference, Pt as VariableType, Q as FileFormat, R as EnqueueEntriesOptions, S as MoveResult, St as HTML_CONTENT_PROPS, T as GetOrphanedFilesResult, Tt as I18nextMessage, U as CreateTagOptions, W as CreateTagResult, X as DownloadFileBatchResult, Z as DownloadedFile, _ as AwaitJobsResult, _t as TranslateManyEntry, a as Metadata, at as CheckFileTranslationsOptions, b as JobStatus, bt as DataFormat, c as Update, ct as FileTranslationQuery, d as Transformation, dt as JsonValue, f as TransformationPrefix, ft as TranslationStatusResult, g as AwaitJobsOptions, h as SubmitUserEditDiffsPayload, ht as EntryMetadata, i as JsxTranslationResult, it as Updates, j as TranslateManyResult, jt as StringFormat, k as BranchQuery, kt as JsxElement, l as _Content, lt as JsonObject, m as SubmitUserEditDiff, mt as ActionType, n as FormatVariables, nt as EnqueueFilesOptions, o as Request, p as VariableTransformationSuffix, pt as HashMetadata, q as RetrievedTranslations, r as IcuTranslationResult, rt as EnqueueFilesResult, s as TranslationRequestConfig, t as ContentTranslationResult, tt as FileToUpload, u as InjectionType, ut as JsonPrimitive, v as JobResult, w as ProcessMovesResponse, wt as HtmlContentPropValuesRecord, x as MoveMapping, xt as GTProp, y as CheckJobStatusResult, yt as Content, z as EnqueueEntriesResult } from "./types-AHtYZIP-.mjs";
2
- export { AwaitJobsOptions, AwaitJobsResult, BranchDataResult, BranchQuery, CheckFileTranslationsOptions, CheckJobStatusResult, Content, ContentTranslationResult, CreateTagOptions, CreateTagResult, CustomMapping, DataFormat, DownloadFileBatchOptions, DownloadFileBatchResult, DownloadFileOptions, DownloadedFile, EnqueueEntriesOptions, EnqueueEntriesResult, EnqueueFilesOptions, EnqueueFilesResult, ActionType as EntryActionType, EntryMetadata, FetchTranslationsOptions, FetchTranslationsResult, FileDataQuery, FileDataResult, FileFormat, FileReference, FileToUpload, FileTranslationQuery, FileUpload, FormatVariables, GTProp, GetOrphanedFilesResult, HTML_CONTENT_PROPS, HashMetadata, HtmlContentPropKeysRecord, HtmlContentPropValuesRecord, I18nextMessage, IcuMessage, IcuTranslationResult, InjectionType, JobResult, JobStatus, JsonObject, JsonPrimitive, JsonValue, JsxChild, JsxChildren, JsxElement, JsxTranslationResult, LocaleProperties, Metadata, MoveMapping, MoveResult, OrphanedFile, ProcessMovesOptions, ProcessMovesResponse, PublishFileEntry, PublishFilesResult, Request, RetrievedTranslations, StringContent, StringFormat, StringMessage, SubmitUserEditDiff, SubmitUserEditDiffsPayload, Transformation, TransformationPrefix, TranslateManyEntry, TranslateManyResult, TranslationError, TranslationRequestConfig, TranslationResult, TranslationResultReference, TranslationStatusResult, Update, Updates, Variable, VariableTransformationSuffix, VariableType, _Content };
1
+ import { $ as TranslationResult, A as InjectionType, At as JsonPrimitive, B as JobStatus, C as StringFormat, Ct as EnqueueFilesResult, D as Variable, E as Update, F as SubmitUserEditDiffsPayload, Ft as EntryMetadata, G as GetOrphanedFilesResult, H as MoveResult, I as AwaitJobsOptions, J as FileDataResult, K as OrphanedFile, L as AwaitJobsResult, Lt as TranslateManyEntry, M as TransformationPrefix, Mt as TranslationStatusResult, N as VariableTransformationSuffix, Nt as HashMetadata, O as VariableType, Ot as FileTranslationQuery, P as SubmitUserEditDiff, Pt as ActionType, Q as TranslationError, R as JobResult, S as StringContent, St as EnqueueFilesOptions, T as TranslationRequestConfig, Tt as CheckFileTranslationsOptions, U as ProcessMovesOptions, V as MoveMapping, W as ProcessMovesResponse, X as BranchDataResult, Y as BranchQuery, Z as TranslateManyResult, _ as JsxElement, _t as DownloadedFile, a as CutoffFormatOptions, at as EnqueueEntriesResult, b as Metadata, c as GTProp, d as HtmlContentPropValuesRecord, dt as FetchTranslationsOptions, et as TranslationResultReference, f as I18nextMessage, ft as FetchTranslationsResult, g as JsxChildren, gt as DownloadFileBatchResult, h as JsxChild, i as CustomRegionMapping, it as EnqueueEntriesOptions, j as Transformation, jt as JsonValue, k as _Content, kt as JsonObject, l as HTML_CONTENT_PROPS, lt as CreateTagOptions, m as IcuTranslationResult, mt as DownloadFileBatchOptions, n as ContentTranslationResult, nt as PublishFileEntry, o as DataFormat, ot as FileUpload, p as IcuMessage, pt as RetrievedTranslations, q as FileDataQuery, r as CustomMapping, rt as PublishFilesResult, s as FormatVariables, t as Content, tt as DownloadFileOptions, u as HtmlContentPropKeysRecord, ut as CreateTagResult, v as JsxTranslationResult, vt as FileFormat, w as StringMessage, wt as Updates, x as Request, xt as FileToUpload, y as LocaleProperties, yt as FileReference, z as CheckJobStatusResult } from "./types-Db2Dn3oN.mjs";
2
+ export { AwaitJobsOptions, AwaitJobsResult, BranchDataResult, BranchQuery, CheckFileTranslationsOptions, CheckJobStatusResult, Content, ContentTranslationResult, CreateTagOptions, CreateTagResult, CustomMapping, CustomRegionMapping, CutoffFormatOptions, DataFormat, DownloadFileBatchOptions, DownloadFileBatchResult, DownloadFileOptions, DownloadedFile, EnqueueEntriesOptions, EnqueueEntriesResult, EnqueueFilesOptions, EnqueueFilesResult, ActionType as EntryActionType, EntryMetadata, FetchTranslationsOptions, FetchTranslationsResult, FileDataQuery, FileDataResult, FileFormat, FileReference, FileToUpload, FileTranslationQuery, FileUpload, FormatVariables, GTProp, GetOrphanedFilesResult, HTML_CONTENT_PROPS, HashMetadata, HtmlContentPropKeysRecord, HtmlContentPropValuesRecord, I18nextMessage, IcuMessage, IcuTranslationResult, InjectionType, JobResult, JobStatus, JsonObject, JsonPrimitive, JsonValue, JsxChild, JsxChildren, JsxElement, JsxTranslationResult, LocaleProperties, Metadata, MoveMapping, MoveResult, OrphanedFile, ProcessMovesOptions, ProcessMovesResponse, PublishFileEntry, PublishFilesResult, Request, RetrievedTranslations, StringContent, StringFormat, StringMessage, SubmitUserEditDiff, SubmitUserEditDiffsPayload, Transformation, TransformationPrefix, TranslateManyEntry, TranslateManyResult, TranslationError, TranslationRequestConfig, TranslationResult, TranslationResultReference, TranslationStatusResult, Update, Updates, Variable, VariableTransformationSuffix, VariableType, _Content };