@lokalise/polyglot-sdk 21.0.0 → 21.0.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.
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/sdk/helpers/removeUnicodeNullCharacters.d.ts +1 -0
- package/dist/sdk/helpers/removeUnicodeNullCharacters.js +4 -0
- package/dist/sdk/helpers/removeUnicodeNullCharacters.js.map +1 -0
- package/dist/sdk/schemas/common/commonSchemas.d.ts +19 -4
- package/dist/sdk/schemas/common/commonSchemas.js +23 -5
- package/dist/sdk/schemas/common/commonSchemas.js.map +1 -1
- package/dist/sdk/schemas/common/translationContextSchemas.d.ts +19 -19
- package/dist/sdk/schemas/common/translationContextSchemas.js +16 -8
- package/dist/sdk/schemas/common/translationContextSchemas.js.map +1 -1
- package/dist/sdk/schemas/lqa/commonSchemas.d.ts +330 -0
- package/dist/sdk/schemas/lqa/commonSchemas.js +69 -0
- package/dist/sdk/schemas/lqa/commonSchemas.js.map +1 -1
- package/dist/sdk/schemas/lqa/lqaAsyncSchemas.d.ts +118 -213
- package/dist/sdk/schemas/lqa/lqaAsyncSchemas.js +3 -51
- package/dist/sdk/schemas/lqa/lqaAsyncSchemas.js.map +1 -1
- package/dist/sdk/schemas/lqa/lqaSyncSchemas.d.ts +118 -214
- package/dist/sdk/schemas/lqa/lqaSyncSchemas.js +3 -51
- package/dist/sdk/schemas/lqa/lqaSyncSchemas.js.map +1 -1
- package/dist/sdk/schemas/translation/generateVariants.d.ts +15 -15
- package/dist/sdk/schemas/translation/generateVariants.js +7 -1
- package/dist/sdk/schemas/translation/generateVariants.js.map +1 -1
- package/dist/sdk/schemas/translation/rewriteTextSchemas.d.ts +156 -28
- package/dist/sdk/schemas/translation/rewriteTextSchemas.js +10 -3
- package/dist/sdk/schemas/translation/rewriteTextSchemas.js.map +1 -1
- package/dist/sdk/schemas/translation/sharedSchemas.d.ts +17 -18
- package/dist/sdk/schemas/translation/sharedSchemas.js +23 -24
- package/dist/sdk/schemas/translation/sharedSchemas.js.map +1 -1
- package/dist/sdk/schemas/translation/translateAsyncSchemas.d.ts +13 -13
- package/dist/sdk/schemas/translation/translateAsyncSchemas.js +2 -2
- package/dist/sdk/schemas/translation/translateAsyncSchemas.js.map +1 -1
- package/dist/sdk/schemas/translation/translateSyncSchemas.d.ts +252 -14
- package/dist/sdk/schemas/translation/translateSyncSchemas.js +11 -3
- package/dist/sdk/schemas/translation/translateSyncSchemas.js.map +1 -1
- package/dist/sdk/schemas/translation/translateTextSegmentSchemas.d.ts +11 -11
- package/dist/sdk/schemas/translation/translateTextSegmentSchemas.js +8 -7
- package/dist/sdk/schemas/translation/translateTextSegmentSchemas.js.map +1 -1
- package/package.json +6 -7
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import z from 'zod';
|
|
1
2
|
import type { ObjectValues } from '../../types/common.ts';
|
|
2
3
|
export declare const LqaIssueSeverityEnum: {
|
|
3
4
|
readonly NEUTRAL: "neutral";
|
|
@@ -6,3 +7,332 @@ export declare const LqaIssueSeverityEnum: {
|
|
|
6
7
|
readonly CRITICAL: "critical";
|
|
7
8
|
};
|
|
8
9
|
export type LqaIssueSeverityEnum = ObjectValues<typeof LqaIssueSeverityEnum>;
|
|
10
|
+
export declare const LQA_TRANSLATION_ID_SCHEMA: z.ZodString;
|
|
11
|
+
export declare const LQA_CONTENT_UNIT_ID_SCHEMA: z.ZodString;
|
|
12
|
+
export declare const LQA_SEGMENT_SCHEMA: z.ZodEffects<z.ZodObject<{
|
|
13
|
+
sourceValue: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
14
|
+
translations: z.ZodArray<z.ZodObject<{
|
|
15
|
+
id: z.ZodString;
|
|
16
|
+
locale: z.ZodEffects<z.ZodString, string, string>;
|
|
17
|
+
value: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
18
|
+
}, "strip", z.ZodTypeAny, {
|
|
19
|
+
value: string;
|
|
20
|
+
id: string;
|
|
21
|
+
locale: string;
|
|
22
|
+
}, {
|
|
23
|
+
value: string;
|
|
24
|
+
id: string;
|
|
25
|
+
locale: string;
|
|
26
|
+
}>, "atleastone">;
|
|
27
|
+
tmMatch: z.ZodOptional<z.ZodObject<{
|
|
28
|
+
sourceValue: z.ZodEffects<z.ZodString, string, string>;
|
|
29
|
+
translatedValue: z.ZodEffects<z.ZodString, string, string>;
|
|
30
|
+
}, "strip", z.ZodTypeAny, {
|
|
31
|
+
sourceValue: string;
|
|
32
|
+
translatedValue: string;
|
|
33
|
+
}, {
|
|
34
|
+
sourceValue: string;
|
|
35
|
+
translatedValue: string;
|
|
36
|
+
}>>;
|
|
37
|
+
translationExamples: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
38
|
+
sourceValue: z.ZodEffects<z.ZodString, string, string>;
|
|
39
|
+
translatedValue: z.ZodEffects<z.ZodString, string, string>;
|
|
40
|
+
}, "strip", z.ZodTypeAny, {
|
|
41
|
+
sourceValue: string;
|
|
42
|
+
translatedValue: string;
|
|
43
|
+
}, {
|
|
44
|
+
sourceValue: string;
|
|
45
|
+
translatedValue: string;
|
|
46
|
+
}>, "many">>;
|
|
47
|
+
}, "strip", z.ZodTypeAny, {
|
|
48
|
+
sourceValue: string;
|
|
49
|
+
translations: [{
|
|
50
|
+
value: string;
|
|
51
|
+
id: string;
|
|
52
|
+
locale: string;
|
|
53
|
+
}, ...{
|
|
54
|
+
value: string;
|
|
55
|
+
id: string;
|
|
56
|
+
locale: string;
|
|
57
|
+
}[]];
|
|
58
|
+
tmMatch?: {
|
|
59
|
+
sourceValue: string;
|
|
60
|
+
translatedValue: string;
|
|
61
|
+
} | undefined;
|
|
62
|
+
translationExamples?: {
|
|
63
|
+
sourceValue: string;
|
|
64
|
+
translatedValue: string;
|
|
65
|
+
}[] | undefined;
|
|
66
|
+
}, {
|
|
67
|
+
sourceValue: string;
|
|
68
|
+
translations: [{
|
|
69
|
+
value: string;
|
|
70
|
+
id: string;
|
|
71
|
+
locale: string;
|
|
72
|
+
}, ...{
|
|
73
|
+
value: string;
|
|
74
|
+
id: string;
|
|
75
|
+
locale: string;
|
|
76
|
+
}[]];
|
|
77
|
+
tmMatch?: {
|
|
78
|
+
sourceValue: string;
|
|
79
|
+
translatedValue: string;
|
|
80
|
+
} | undefined;
|
|
81
|
+
translationExamples?: {
|
|
82
|
+
sourceValue: string;
|
|
83
|
+
translatedValue: string;
|
|
84
|
+
}[] | undefined;
|
|
85
|
+
}>, {
|
|
86
|
+
sourceValue: string;
|
|
87
|
+
translations: [{
|
|
88
|
+
value: string;
|
|
89
|
+
id: string;
|
|
90
|
+
locale: string;
|
|
91
|
+
}, ...{
|
|
92
|
+
value: string;
|
|
93
|
+
id: string;
|
|
94
|
+
locale: string;
|
|
95
|
+
}[]];
|
|
96
|
+
tmMatch?: {
|
|
97
|
+
sourceValue: string;
|
|
98
|
+
translatedValue: string;
|
|
99
|
+
} | undefined;
|
|
100
|
+
translationExamples?: {
|
|
101
|
+
sourceValue: string;
|
|
102
|
+
translatedValue: string;
|
|
103
|
+
}[] | undefined;
|
|
104
|
+
}, {
|
|
105
|
+
sourceValue: string;
|
|
106
|
+
translations: [{
|
|
107
|
+
value: string;
|
|
108
|
+
id: string;
|
|
109
|
+
locale: string;
|
|
110
|
+
}, ...{
|
|
111
|
+
value: string;
|
|
112
|
+
id: string;
|
|
113
|
+
locale: string;
|
|
114
|
+
}[]];
|
|
115
|
+
tmMatch?: {
|
|
116
|
+
sourceValue: string;
|
|
117
|
+
translatedValue: string;
|
|
118
|
+
} | undefined;
|
|
119
|
+
translationExamples?: {
|
|
120
|
+
sourceValue: string;
|
|
121
|
+
translatedValue: string;
|
|
122
|
+
}[] | undefined;
|
|
123
|
+
}>;
|
|
124
|
+
export declare const LQA_CONTENT_UNIT_SCHEMA: z.ZodObject<{
|
|
125
|
+
id: z.ZodString;
|
|
126
|
+
context: z.ZodOptional<z.ZodObject<{
|
|
127
|
+
description: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
|
|
128
|
+
}, "strip", z.ZodTypeAny, {
|
|
129
|
+
description?: string | undefined;
|
|
130
|
+
}, {
|
|
131
|
+
description?: string | undefined;
|
|
132
|
+
}>>;
|
|
133
|
+
segments: z.ZodArray<z.ZodEffects<z.ZodObject<{
|
|
134
|
+
sourceValue: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
135
|
+
translations: z.ZodArray<z.ZodObject<{
|
|
136
|
+
id: z.ZodString;
|
|
137
|
+
locale: z.ZodEffects<z.ZodString, string, string>;
|
|
138
|
+
value: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
|
|
139
|
+
}, "strip", z.ZodTypeAny, {
|
|
140
|
+
value: string;
|
|
141
|
+
id: string;
|
|
142
|
+
locale: string;
|
|
143
|
+
}, {
|
|
144
|
+
value: string;
|
|
145
|
+
id: string;
|
|
146
|
+
locale: string;
|
|
147
|
+
}>, "atleastone">;
|
|
148
|
+
tmMatch: z.ZodOptional<z.ZodObject<{
|
|
149
|
+
sourceValue: z.ZodEffects<z.ZodString, string, string>;
|
|
150
|
+
translatedValue: z.ZodEffects<z.ZodString, string, string>;
|
|
151
|
+
}, "strip", z.ZodTypeAny, {
|
|
152
|
+
sourceValue: string;
|
|
153
|
+
translatedValue: string;
|
|
154
|
+
}, {
|
|
155
|
+
sourceValue: string;
|
|
156
|
+
translatedValue: string;
|
|
157
|
+
}>>;
|
|
158
|
+
translationExamples: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
159
|
+
sourceValue: z.ZodEffects<z.ZodString, string, string>;
|
|
160
|
+
translatedValue: z.ZodEffects<z.ZodString, string, string>;
|
|
161
|
+
}, "strip", z.ZodTypeAny, {
|
|
162
|
+
sourceValue: string;
|
|
163
|
+
translatedValue: string;
|
|
164
|
+
}, {
|
|
165
|
+
sourceValue: string;
|
|
166
|
+
translatedValue: string;
|
|
167
|
+
}>, "many">>;
|
|
168
|
+
}, "strip", z.ZodTypeAny, {
|
|
169
|
+
sourceValue: string;
|
|
170
|
+
translations: [{
|
|
171
|
+
value: string;
|
|
172
|
+
id: string;
|
|
173
|
+
locale: string;
|
|
174
|
+
}, ...{
|
|
175
|
+
value: string;
|
|
176
|
+
id: string;
|
|
177
|
+
locale: string;
|
|
178
|
+
}[]];
|
|
179
|
+
tmMatch?: {
|
|
180
|
+
sourceValue: string;
|
|
181
|
+
translatedValue: string;
|
|
182
|
+
} | undefined;
|
|
183
|
+
translationExamples?: {
|
|
184
|
+
sourceValue: string;
|
|
185
|
+
translatedValue: string;
|
|
186
|
+
}[] | undefined;
|
|
187
|
+
}, {
|
|
188
|
+
sourceValue: string;
|
|
189
|
+
translations: [{
|
|
190
|
+
value: string;
|
|
191
|
+
id: string;
|
|
192
|
+
locale: string;
|
|
193
|
+
}, ...{
|
|
194
|
+
value: string;
|
|
195
|
+
id: string;
|
|
196
|
+
locale: string;
|
|
197
|
+
}[]];
|
|
198
|
+
tmMatch?: {
|
|
199
|
+
sourceValue: string;
|
|
200
|
+
translatedValue: string;
|
|
201
|
+
} | undefined;
|
|
202
|
+
translationExamples?: {
|
|
203
|
+
sourceValue: string;
|
|
204
|
+
translatedValue: string;
|
|
205
|
+
}[] | undefined;
|
|
206
|
+
}>, {
|
|
207
|
+
sourceValue: string;
|
|
208
|
+
translations: [{
|
|
209
|
+
value: string;
|
|
210
|
+
id: string;
|
|
211
|
+
locale: string;
|
|
212
|
+
}, ...{
|
|
213
|
+
value: string;
|
|
214
|
+
id: string;
|
|
215
|
+
locale: string;
|
|
216
|
+
}[]];
|
|
217
|
+
tmMatch?: {
|
|
218
|
+
sourceValue: string;
|
|
219
|
+
translatedValue: string;
|
|
220
|
+
} | undefined;
|
|
221
|
+
translationExamples?: {
|
|
222
|
+
sourceValue: string;
|
|
223
|
+
translatedValue: string;
|
|
224
|
+
}[] | undefined;
|
|
225
|
+
}, {
|
|
226
|
+
sourceValue: string;
|
|
227
|
+
translations: [{
|
|
228
|
+
value: string;
|
|
229
|
+
id: string;
|
|
230
|
+
locale: string;
|
|
231
|
+
}, ...{
|
|
232
|
+
value: string;
|
|
233
|
+
id: string;
|
|
234
|
+
locale: string;
|
|
235
|
+
}[]];
|
|
236
|
+
tmMatch?: {
|
|
237
|
+
sourceValue: string;
|
|
238
|
+
translatedValue: string;
|
|
239
|
+
} | undefined;
|
|
240
|
+
translationExamples?: {
|
|
241
|
+
sourceValue: string;
|
|
242
|
+
translatedValue: string;
|
|
243
|
+
}[] | undefined;
|
|
244
|
+
}>, "atleastone">;
|
|
245
|
+
characterLimit: z.ZodOptional<z.ZodNumber>;
|
|
246
|
+
}, "strip", z.ZodTypeAny, {
|
|
247
|
+
segments: [{
|
|
248
|
+
sourceValue: string;
|
|
249
|
+
translations: [{
|
|
250
|
+
value: string;
|
|
251
|
+
id: string;
|
|
252
|
+
locale: string;
|
|
253
|
+
}, ...{
|
|
254
|
+
value: string;
|
|
255
|
+
id: string;
|
|
256
|
+
locale: string;
|
|
257
|
+
}[]];
|
|
258
|
+
tmMatch?: {
|
|
259
|
+
sourceValue: string;
|
|
260
|
+
translatedValue: string;
|
|
261
|
+
} | undefined;
|
|
262
|
+
translationExamples?: {
|
|
263
|
+
sourceValue: string;
|
|
264
|
+
translatedValue: string;
|
|
265
|
+
}[] | undefined;
|
|
266
|
+
}, ...{
|
|
267
|
+
sourceValue: string;
|
|
268
|
+
translations: [{
|
|
269
|
+
value: string;
|
|
270
|
+
id: string;
|
|
271
|
+
locale: string;
|
|
272
|
+
}, ...{
|
|
273
|
+
value: string;
|
|
274
|
+
id: string;
|
|
275
|
+
locale: string;
|
|
276
|
+
}[]];
|
|
277
|
+
tmMatch?: {
|
|
278
|
+
sourceValue: string;
|
|
279
|
+
translatedValue: string;
|
|
280
|
+
} | undefined;
|
|
281
|
+
translationExamples?: {
|
|
282
|
+
sourceValue: string;
|
|
283
|
+
translatedValue: string;
|
|
284
|
+
}[] | undefined;
|
|
285
|
+
}[]];
|
|
286
|
+
id: string;
|
|
287
|
+
context?: {
|
|
288
|
+
description?: string | undefined;
|
|
289
|
+
} | undefined;
|
|
290
|
+
characterLimit?: number | undefined;
|
|
291
|
+
}, {
|
|
292
|
+
segments: [{
|
|
293
|
+
sourceValue: string;
|
|
294
|
+
translations: [{
|
|
295
|
+
value: string;
|
|
296
|
+
id: string;
|
|
297
|
+
locale: string;
|
|
298
|
+
}, ...{
|
|
299
|
+
value: string;
|
|
300
|
+
id: string;
|
|
301
|
+
locale: string;
|
|
302
|
+
}[]];
|
|
303
|
+
tmMatch?: {
|
|
304
|
+
sourceValue: string;
|
|
305
|
+
translatedValue: string;
|
|
306
|
+
} | undefined;
|
|
307
|
+
translationExamples?: {
|
|
308
|
+
sourceValue: string;
|
|
309
|
+
translatedValue: string;
|
|
310
|
+
}[] | undefined;
|
|
311
|
+
}, ...{
|
|
312
|
+
sourceValue: string;
|
|
313
|
+
translations: [{
|
|
314
|
+
value: string;
|
|
315
|
+
id: string;
|
|
316
|
+
locale: string;
|
|
317
|
+
}, ...{
|
|
318
|
+
value: string;
|
|
319
|
+
id: string;
|
|
320
|
+
locale: string;
|
|
321
|
+
}[]];
|
|
322
|
+
tmMatch?: {
|
|
323
|
+
sourceValue: string;
|
|
324
|
+
translatedValue: string;
|
|
325
|
+
} | undefined;
|
|
326
|
+
translationExamples?: {
|
|
327
|
+
sourceValue: string;
|
|
328
|
+
translatedValue: string;
|
|
329
|
+
}[] | undefined;
|
|
330
|
+
}[]];
|
|
331
|
+
id: string;
|
|
332
|
+
context?: {
|
|
333
|
+
description?: string | undefined;
|
|
334
|
+
} | undefined;
|
|
335
|
+
characterLimit?: number | undefined;
|
|
336
|
+
}>;
|
|
337
|
+
export type LqaAsyncContentUnit = z.infer<typeof LQA_CONTENT_UNIT_SCHEMA>;
|
|
338
|
+
export type LqaAsyncSegment = z.infer<typeof LQA_SEGMENT_SCHEMA>;
|
|
@@ -1,7 +1,76 @@
|
|
|
1
|
+
import z from 'zod';
|
|
2
|
+
import { removeUnicodeNullCharacters } from "../../helpers/removeUnicodeNullCharacters.js";
|
|
3
|
+
import { isSegmentUnderLengthLimit } from "../../validation/isSegmentUnderLengthLimit.js";
|
|
4
|
+
import { CONTENT_ID_PROP_SCHEMA, LOCALE_SCHEMA, SEGMENT_VALUE_MAX_LENGTH_DEFAULT, TM_MATCH_SCHEMA, TRANSLATION_EXAMPLE_SCHEMA, } from "../common/commonSchemas.js";
|
|
1
5
|
export const LqaIssueSeverityEnum = {
|
|
2
6
|
NEUTRAL: 'neutral',
|
|
3
7
|
MINOR: 'minor',
|
|
4
8
|
MAJOR: 'major',
|
|
5
9
|
CRITICAL: 'critical',
|
|
6
10
|
};
|
|
11
|
+
const LQA_SEGMENT_TRANSLATIONS_MAX_LENGTH = 10;
|
|
12
|
+
const LQA_CONTENT_UNIT_DESCRIPTION_MAX_LENGTH = 32768;
|
|
13
|
+
const LQA_CONTENT_UNIT_SEGMENTS_MAX_LENGTH = 500;
|
|
14
|
+
export const LQA_TRANSLATION_ID_SCHEMA = CONTENT_ID_PROP_SCHEMA.describe('Unique ID of the segment translation');
|
|
15
|
+
export const LQA_CONTENT_UNIT_ID_SCHEMA = CONTENT_ID_PROP_SCHEMA.describe('Unique ID of the content unit');
|
|
16
|
+
const LQA_TRANSLATION_SCHEMA = z.object({
|
|
17
|
+
id: LQA_TRANSLATION_ID_SCHEMA,
|
|
18
|
+
locale: LOCALE_SCHEMA,
|
|
19
|
+
value: z
|
|
20
|
+
.string()
|
|
21
|
+
.min(1)
|
|
22
|
+
.refine((value) => isSegmentUnderLengthLimit(value), `Too long translation value, max length is ${SEGMENT_VALUE_MAX_LENGTH_DEFAULT} characters`)
|
|
23
|
+
.transform(removeUnicodeNullCharacters)
|
|
24
|
+
.describe('Translation of this segment in target language'),
|
|
25
|
+
});
|
|
26
|
+
export const LQA_SEGMENT_SCHEMA = z
|
|
27
|
+
.object({
|
|
28
|
+
sourceValue: z
|
|
29
|
+
.string()
|
|
30
|
+
.min(1)
|
|
31
|
+
.refine((value) => isSegmentUnderLengthLimit(value), `Too long segment value, max length is ${SEGMENT_VALUE_MAX_LENGTH_DEFAULT} characters`)
|
|
32
|
+
.transform(removeUnicodeNullCharacters)
|
|
33
|
+
.describe('Text content of the segment in source language'),
|
|
34
|
+
translations: z
|
|
35
|
+
.array(LQA_TRANSLATION_SCHEMA)
|
|
36
|
+
.nonempty()
|
|
37
|
+
.max(LQA_SEGMENT_TRANSLATIONS_MAX_LENGTH)
|
|
38
|
+
.describe('List of translations for this segment'),
|
|
39
|
+
tmMatch: TM_MATCH_SCHEMA.describe('This field is deprecated, please use "translationExamples" instead'),
|
|
40
|
+
translationExamples: z
|
|
41
|
+
.array(TRANSLATION_EXAMPLE_SCHEMA)
|
|
42
|
+
.optional()
|
|
43
|
+
.describe('When defined, the translation will attempt to follow the provided translation example'),
|
|
44
|
+
})
|
|
45
|
+
.transform((segment) => {
|
|
46
|
+
if (segment.tmMatch) {
|
|
47
|
+
segment.translationExamples = segment.translationExamples
|
|
48
|
+
? [...segment.translationExamples, segment.tmMatch]
|
|
49
|
+
: [segment.tmMatch];
|
|
50
|
+
}
|
|
51
|
+
if (segment.translationExamples?.length === 0) {
|
|
52
|
+
segment.translationExamples = undefined;
|
|
53
|
+
}
|
|
54
|
+
return segment;
|
|
55
|
+
});
|
|
56
|
+
export const LQA_CONTENT_UNIT_SCHEMA = z.object({
|
|
57
|
+
id: LQA_CONTENT_UNIT_ID_SCHEMA,
|
|
58
|
+
context: z
|
|
59
|
+
.object({
|
|
60
|
+
description: z
|
|
61
|
+
.string()
|
|
62
|
+
.min(1)
|
|
63
|
+
.max(LQA_CONTENT_UNIT_DESCRIPTION_MAX_LENGTH)
|
|
64
|
+
.describe('Unit description, something that applies to each segment in a unit. This will be passed as a helpful context to LLM calls')
|
|
65
|
+
.transform(removeUnicodeNullCharacters)
|
|
66
|
+
.optional(),
|
|
67
|
+
})
|
|
68
|
+
.optional(),
|
|
69
|
+
segments: z
|
|
70
|
+
.array(LQA_SEGMENT_SCHEMA)
|
|
71
|
+
.nonempty()
|
|
72
|
+
.max(LQA_CONTENT_UNIT_SEGMENTS_MAX_LENGTH)
|
|
73
|
+
.describe('List of segments to be reviewed'),
|
|
74
|
+
characterLimit: z.number().optional(),
|
|
75
|
+
});
|
|
7
76
|
//# sourceMappingURL=commonSchemas.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"commonSchemas.js","sourceRoot":"","sources":["../../../../src/sdk/schemas/lqa/commonSchemas.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"commonSchemas.js","sourceRoot":"","sources":["../../../../src/sdk/schemas/lqa/commonSchemas.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAA;AACnB,OAAO,EAAE,2BAA2B,EAAE,MAAM,8CAA8C,CAAA;AAE1F,OAAO,EAAE,yBAAyB,EAAE,MAAM,+CAA+C,CAAA;AACzF,OAAO,EACL,sBAAsB,EACtB,aAAa,EACb,gCAAgC,EAChC,eAAe,EACf,0BAA0B,GAC3B,MAAM,4BAA4B,CAAA;AAEnC,MAAM,CAAC,MAAM,oBAAoB,GAAG;IAClC,OAAO,EAAE,SAAS;IAClB,KAAK,EAAE,OAAO;IACd,KAAK,EAAE,OAAO;IACd,QAAQ,EAAE,UAAU;CACZ,CAAA;AAIV,MAAM,mCAAmC,GAAG,EAAE,CAAA;AAC9C,MAAM,uCAAuC,GAAG,KAAK,CAAA;AACrD,MAAM,oCAAoC,GAAG,GAAG,CAAA;AAEhD,MAAM,CAAC,MAAM,yBAAyB,GAAG,sBAAsB,CAAC,QAAQ,CACtE,sCAAsC,CACvC,CAAA;AAED,MAAM,CAAC,MAAM,0BAA0B,GAAG,sBAAsB,CAAC,QAAQ,CACvE,+BAA+B,CAChC,CAAA;AAED,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IACtC,EAAE,EAAE,yBAAyB;IAC7B,MAAM,EAAE,aAA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