@prismicio/types-internal 2.7.0-alpha.3 → 2.7.0-alpha.4
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/lib/content/Document.d.ts +2118 -798
- package/lib/content/fields/WidgetContent.d.ts +2118 -798
- package/lib/content/fields/nestable/LinkContent.d.ts +248 -85
- package/lib/content/fields/nestable/LinkContent.js +96 -42
- package/lib/content/fields/nestable/NestableContent.d.ts +353 -133
- package/lib/content/fields/nestable/RichTextContent/Blocks.d.ts +654 -234
- package/lib/content/fields/nestable/RichTextContent/index.d.ts +320 -120
- package/lib/content/fields/slices/Slice/CompositeSliceContent.d.ts +706 -266
- package/lib/content/fields/slices/Slice/RepeatableContent.d.ts +161 -61
- package/lib/content/fields/slices/Slice/SharedSliceContent.d.ts +706 -266
- package/lib/content/fields/slices/Slice/SimpleSliceContent.d.ts +353 -133
- package/lib/content/fields/slices/Slice/SlicePrimaryContent.d.ts +353 -133
- package/lib/content/fields/slices/Slice/index.d.ts +1285 -485
- package/lib/content/fields/slices/SliceItem.d.ts +1285 -485
- package/lib/content/fields/slices/SlicesContent.d.ts +1766 -666
- package/lib/customtypes/CustomType.d.ts +18 -320
- package/lib/customtypes/Section.d.ts +18 -320
- package/lib/customtypes/diff/SharedSlice.d.ts +8 -160
- package/lib/customtypes/diff/Variation.d.ts +8 -160
- package/lib/customtypes/widgets/Group.d.ts +18 -315
- package/lib/customtypes/widgets/Group.js +5 -43
- package/lib/customtypes/widgets/Widget.d.ts +33 -412
- package/lib/customtypes/widgets/nestable/Link.d.ts +2 -0
- package/lib/customtypes/widgets/nestable/Link.js +1 -0
- package/lib/customtypes/widgets/nestable/NestableWidget.d.ts +1 -0
- package/lib/customtypes/widgets/slices/CompositeSlice.d.ts +2 -0
- package/lib/customtypes/widgets/slices/LegacySlice.d.ts +4 -42
- package/lib/customtypes/widgets/slices/SharedSlice.d.ts +16 -168
- package/lib/customtypes/widgets/slices/SlicePrimaryWidget.d.ts +10 -164
- package/lib/customtypes/widgets/slices/Slices.d.ts +34 -366
- package/package.json +1 -1
- package/src/content/fields/nestable/LinkContent.ts +121 -50
- package/src/customtypes/widgets/Group.ts +6 -52
- package/src/customtypes/widgets/nestable/Link.ts +1 -0
|
@@ -120,35 +120,47 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
120
120
|
__TYPE__: t.LiteralC<"LinkContent">;
|
|
121
121
|
value: t.UnionC<[t.IntersectionC<[t.ExactC<t.TypeC<{
|
|
122
122
|
__TYPE__: t.LiteralC<"ImageLink">;
|
|
123
|
-
}>>, t.
|
|
123
|
+
}>>, t.IntersectionC<[t.ExactC<t.TypeC<{
|
|
124
|
+
kind: t.LiteralC<"image">;
|
|
125
|
+
}>>, t.UnionC<[t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
124
126
|
id: t.StringC;
|
|
125
127
|
url: t.StringC;
|
|
126
128
|
height: t.StringC;
|
|
127
129
|
width: t.StringC;
|
|
128
130
|
size: t.StringC;
|
|
129
131
|
name: t.StringC;
|
|
130
|
-
kind: t.StringC;
|
|
131
132
|
}>, t.PartialC<{
|
|
132
133
|
date: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
133
|
-
|
|
134
|
+
text: t.StringC;
|
|
135
|
+
}>]>>, t.ExactC<t.TypeC<{
|
|
136
|
+
text: t.StringC;
|
|
137
|
+
}>>]>]>]>, t.IntersectionC<[t.ExactC<t.TypeC<{
|
|
138
|
+
__TYPE__: t.LiteralC<"FileLink">;
|
|
139
|
+
}>>, t.IntersectionC<[t.ExactC<t.TypeC<{
|
|
140
|
+
kind: t.LiteralC<"file">;
|
|
141
|
+
}>>, t.UnionC<[t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
134
142
|
id: t.StringC;
|
|
135
143
|
url: t.StringC;
|
|
136
144
|
name: t.StringC;
|
|
137
|
-
kind: t.StringC;
|
|
138
145
|
size: t.StringC;
|
|
139
146
|
}>, t.PartialC<{
|
|
140
147
|
date: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
}>]>>]>, t.IntersectionC<[t.ExactC<t.TypeC<{
|
|
148
|
+
text: t.StringC;
|
|
149
|
+
}>]>>, t.ExactC<t.TypeC<{
|
|
150
|
+
text: t.StringC;
|
|
151
|
+
}>>]>]>]>, t.IntersectionC<[t.ExactC<t.TypeC<{
|
|
146
152
|
__TYPE__: t.LiteralC<"DocumentLink">;
|
|
147
|
-
}>>, t.ExactC<t.TypeC<{
|
|
153
|
+
}>>, t.UnionC<[t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
148
154
|
id: t.Type<string, string, unknown>;
|
|
149
|
-
}
|
|
155
|
+
}>, t.PartialC<{
|
|
156
|
+
kind: t.LiteralC<"document">;
|
|
157
|
+
text: t.StringC;
|
|
158
|
+
}>]>>, t.ExactC<t.TypeC<{
|
|
159
|
+
kind: t.LiteralC<"document">;
|
|
160
|
+
text: t.StringC;
|
|
161
|
+
}>>]>]>, t.IntersectionC<[t.ExactC<t.TypeC<{
|
|
150
162
|
__TYPE__: t.LiteralC<"ExternalLink">;
|
|
151
|
-
}>>, t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
163
|
+
}>>, t.UnionC<[t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
152
164
|
url: t.StringC;
|
|
153
165
|
}>, t.PartialC<{
|
|
154
166
|
kind: t.LiteralC<"web">;
|
|
@@ -158,7 +170,15 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
158
170
|
}, {
|
|
159
171
|
title?: string;
|
|
160
172
|
}, unknown>, t.NullC, t.UndefinedC]>;
|
|
161
|
-
|
|
173
|
+
text: t.StringC;
|
|
174
|
+
}>]>>, t.ExactC<t.TypeC<{
|
|
175
|
+
kind: t.LiteralC<"web">;
|
|
176
|
+
text: t.StringC;
|
|
177
|
+
}>>]>]>, t.IntersectionC<[t.ExactC<t.TypeC<{
|
|
178
|
+
__TYPE__: t.LiteralC<"AnyLink">;
|
|
179
|
+
}>>, t.ExactC<t.TypeC<{
|
|
180
|
+
text: t.StringC;
|
|
181
|
+
}>>]>]>;
|
|
162
182
|
}>>, t.ExactC<t.TypeC<{
|
|
163
183
|
__TYPE__: t.LiteralC<"StructuredTextContent">;
|
|
164
184
|
value: t.ArrayC<t.UnionC<[t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
@@ -188,35 +208,47 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
188
208
|
}>]>>, t.PartialC<{
|
|
189
209
|
linkTo: t.UnionC<[t.Type<({
|
|
190
210
|
__TYPE__: "ImageLink";
|
|
191
|
-
} & {
|
|
211
|
+
} & ({
|
|
212
|
+
kind: "image";
|
|
213
|
+
} & (({
|
|
192
214
|
id: string;
|
|
193
215
|
url: string;
|
|
194
216
|
height: string;
|
|
195
217
|
width: string;
|
|
196
218
|
size: string;
|
|
197
219
|
name: string;
|
|
198
|
-
kind: string;
|
|
199
220
|
} & {
|
|
200
221
|
date?: string | null | undefined;
|
|
201
|
-
|
|
222
|
+
text?: string;
|
|
223
|
+
}) | {
|
|
224
|
+
text: string;
|
|
225
|
+
}))) | ({
|
|
226
|
+
__TYPE__: "FileLink";
|
|
227
|
+
} & ({
|
|
228
|
+
kind: "file";
|
|
229
|
+
} & (({
|
|
202
230
|
id: string;
|
|
203
231
|
url: string;
|
|
204
232
|
name: string;
|
|
205
|
-
kind: string;
|
|
206
233
|
size: string;
|
|
207
234
|
} & {
|
|
208
235
|
date?: string | null | undefined;
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
}) | ({
|
|
236
|
+
text?: string;
|
|
237
|
+
}) | {
|
|
238
|
+
text: string;
|
|
239
|
+
}))) | ({
|
|
214
240
|
__TYPE__: "DocumentLink";
|
|
215
|
-
} & {
|
|
241
|
+
} & (({
|
|
216
242
|
id: string;
|
|
217
|
-
}) | ({
|
|
218
|
-
__TYPE__: "ExternalLink";
|
|
219
243
|
} & {
|
|
244
|
+
kind?: "document";
|
|
245
|
+
text?: string;
|
|
246
|
+
}) | {
|
|
247
|
+
kind: "document";
|
|
248
|
+
text: string;
|
|
249
|
+
})) | ({
|
|
250
|
+
__TYPE__: "ExternalLink";
|
|
251
|
+
} & (({
|
|
220
252
|
url: string;
|
|
221
253
|
} & {
|
|
222
254
|
kind?: "web";
|
|
@@ -224,37 +256,57 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
224
256
|
preview?: {
|
|
225
257
|
title?: string;
|
|
226
258
|
} | null | undefined;
|
|
259
|
+
text?: string;
|
|
260
|
+
}) | {
|
|
261
|
+
kind: "web";
|
|
262
|
+
text: string;
|
|
263
|
+
})) | ({
|
|
264
|
+
__TYPE__: "AnyLink";
|
|
265
|
+
} & {
|
|
266
|
+
text: string;
|
|
227
267
|
}), ({
|
|
228
268
|
__TYPE__: "ImageLink";
|
|
229
|
-
} & {
|
|
269
|
+
} & ({
|
|
270
|
+
kind: "image";
|
|
271
|
+
} & (({
|
|
230
272
|
id: string;
|
|
231
273
|
url: string;
|
|
232
274
|
height: string;
|
|
233
275
|
width: string;
|
|
234
276
|
size: string;
|
|
235
277
|
name: string;
|
|
236
|
-
kind: string;
|
|
237
278
|
} & {
|
|
238
279
|
date?: string | null | undefined;
|
|
239
|
-
|
|
280
|
+
text?: string;
|
|
281
|
+
}) | {
|
|
282
|
+
text: string;
|
|
283
|
+
}))) | ({
|
|
284
|
+
__TYPE__: "FileLink";
|
|
285
|
+
} & ({
|
|
286
|
+
kind: "file";
|
|
287
|
+
} & (({
|
|
240
288
|
id: string;
|
|
241
289
|
url: string;
|
|
242
290
|
name: string;
|
|
243
|
-
kind: string;
|
|
244
291
|
size: string;
|
|
245
292
|
} & {
|
|
246
293
|
date?: string | null | undefined;
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
}) | ({
|
|
294
|
+
text?: string;
|
|
295
|
+
}) | {
|
|
296
|
+
text: string;
|
|
297
|
+
}))) | ({
|
|
252
298
|
__TYPE__: "DocumentLink";
|
|
253
|
-
} & {
|
|
299
|
+
} & (({
|
|
254
300
|
id: string;
|
|
255
|
-
}) | ({
|
|
256
|
-
__TYPE__: "ExternalLink";
|
|
257
301
|
} & {
|
|
302
|
+
kind?: "document";
|
|
303
|
+
text?: string;
|
|
304
|
+
}) | {
|
|
305
|
+
kind: "document";
|
|
306
|
+
text: string;
|
|
307
|
+
})) | ({
|
|
308
|
+
__TYPE__: "ExternalLink";
|
|
309
|
+
} & (({
|
|
258
310
|
url: string;
|
|
259
311
|
} & {
|
|
260
312
|
kind?: "web";
|
|
@@ -262,6 +314,14 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
262
314
|
preview?: {
|
|
263
315
|
title?: string;
|
|
264
316
|
} | null | undefined;
|
|
317
|
+
text?: string;
|
|
318
|
+
}) | {
|
|
319
|
+
kind: "web";
|
|
320
|
+
text: string;
|
|
321
|
+
})) | ({
|
|
322
|
+
__TYPE__: "AnyLink";
|
|
323
|
+
} & {
|
|
324
|
+
text: string;
|
|
265
325
|
}), unknown>, t.NullC, t.UndefinedC]>;
|
|
266
326
|
}>]>;
|
|
267
327
|
}>, t.PartialC<{
|
|
@@ -299,35 +359,47 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
299
359
|
spans: t.Type<({
|
|
300
360
|
data: ({
|
|
301
361
|
__TYPE__: "ImageLink";
|
|
302
|
-
} & {
|
|
362
|
+
} & ({
|
|
363
|
+
kind: "image";
|
|
364
|
+
} & (({
|
|
303
365
|
id: string;
|
|
304
366
|
url: string;
|
|
305
367
|
height: string;
|
|
306
368
|
width: string;
|
|
307
369
|
size: string;
|
|
308
370
|
name: string;
|
|
309
|
-
kind: string;
|
|
310
371
|
} & {
|
|
311
372
|
date?: string | null | undefined;
|
|
312
|
-
|
|
373
|
+
text?: string;
|
|
374
|
+
}) | {
|
|
375
|
+
text: string;
|
|
376
|
+
}))) | ({
|
|
377
|
+
__TYPE__: "FileLink";
|
|
378
|
+
} & ({
|
|
379
|
+
kind: "file";
|
|
380
|
+
} & (({
|
|
313
381
|
id: string;
|
|
314
382
|
url: string;
|
|
315
383
|
name: string;
|
|
316
|
-
kind: string;
|
|
317
384
|
size: string;
|
|
318
385
|
} & {
|
|
319
386
|
date?: string | null | undefined;
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
}) | ({
|
|
387
|
+
text?: string;
|
|
388
|
+
}) | {
|
|
389
|
+
text: string;
|
|
390
|
+
}))) | ({
|
|
325
391
|
__TYPE__: "DocumentLink";
|
|
326
|
-
} & {
|
|
392
|
+
} & (({
|
|
327
393
|
id: string;
|
|
328
|
-
}) | ({
|
|
329
|
-
__TYPE__: "ExternalLink";
|
|
330
394
|
} & {
|
|
395
|
+
kind?: "document";
|
|
396
|
+
text?: string;
|
|
397
|
+
}) | {
|
|
398
|
+
kind: "document";
|
|
399
|
+
text: string;
|
|
400
|
+
})) | ({
|
|
401
|
+
__TYPE__: "ExternalLink";
|
|
402
|
+
} & (({
|
|
331
403
|
url: string;
|
|
332
404
|
} & {
|
|
333
405
|
kind?: "web";
|
|
@@ -335,6 +407,14 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
335
407
|
preview?: {
|
|
336
408
|
title?: string;
|
|
337
409
|
} | null | undefined;
|
|
410
|
+
text?: string;
|
|
411
|
+
}) | {
|
|
412
|
+
kind: "web";
|
|
413
|
+
text: string;
|
|
414
|
+
})) | ({
|
|
415
|
+
__TYPE__: "AnyLink";
|
|
416
|
+
} & {
|
|
417
|
+
text: string;
|
|
338
418
|
});
|
|
339
419
|
start: number;
|
|
340
420
|
end: number;
|
|
@@ -351,35 +431,47 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
351
431
|
})[], ({
|
|
352
432
|
data: ({
|
|
353
433
|
__TYPE__: "ImageLink";
|
|
354
|
-
} & {
|
|
434
|
+
} & ({
|
|
435
|
+
kind: "image";
|
|
436
|
+
} & (({
|
|
355
437
|
id: string;
|
|
356
438
|
url: string;
|
|
357
439
|
height: string;
|
|
358
440
|
width: string;
|
|
359
441
|
size: string;
|
|
360
442
|
name: string;
|
|
361
|
-
kind: string;
|
|
362
443
|
} & {
|
|
363
444
|
date?: string | null | undefined;
|
|
364
|
-
|
|
445
|
+
text?: string;
|
|
446
|
+
}) | {
|
|
447
|
+
text: string;
|
|
448
|
+
}))) | ({
|
|
449
|
+
__TYPE__: "FileLink";
|
|
450
|
+
} & ({
|
|
451
|
+
kind: "file";
|
|
452
|
+
} & (({
|
|
365
453
|
id: string;
|
|
366
454
|
url: string;
|
|
367
455
|
name: string;
|
|
368
|
-
kind: string;
|
|
369
456
|
size: string;
|
|
370
457
|
} & {
|
|
371
458
|
date?: string | null | undefined;
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
}) | ({
|
|
459
|
+
text?: string;
|
|
460
|
+
}) | {
|
|
461
|
+
text: string;
|
|
462
|
+
}))) | ({
|
|
377
463
|
__TYPE__: "DocumentLink";
|
|
378
|
-
} & {
|
|
464
|
+
} & (({
|
|
379
465
|
id: string;
|
|
380
|
-
}) | ({
|
|
381
|
-
__TYPE__: "ExternalLink";
|
|
382
466
|
} & {
|
|
467
|
+
kind?: "document";
|
|
468
|
+
text?: string;
|
|
469
|
+
}) | {
|
|
470
|
+
kind: "document";
|
|
471
|
+
text: string;
|
|
472
|
+
})) | ({
|
|
473
|
+
__TYPE__: "ExternalLink";
|
|
474
|
+
} & (({
|
|
383
475
|
url: string;
|
|
384
476
|
} & {
|
|
385
477
|
kind?: "web";
|
|
@@ -387,6 +479,14 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
387
479
|
preview?: {
|
|
388
480
|
title?: string;
|
|
389
481
|
} | null | undefined;
|
|
482
|
+
text?: string;
|
|
483
|
+
}) | {
|
|
484
|
+
kind: "web";
|
|
485
|
+
text: string;
|
|
486
|
+
})) | ({
|
|
487
|
+
__TYPE__: "AnyLink";
|
|
488
|
+
} & {
|
|
489
|
+
text: string;
|
|
390
490
|
});
|
|
391
491
|
start: number;
|
|
392
492
|
end: number;
|