@prismicio/types-internal 2.4.0-alpha.1 → 2.4.0-alpha.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.
- package/lib/content/Document.d.ts +0 -72
- package/lib/content/fields/GroupContent.d.ts +0 -15
- package/lib/content/fields/WidgetContent.d.ts +0 -72
- package/lib/content/fields/nestable/ImageContent.d.ts +0 -9
- package/lib/content/fields/nestable/ImageContent.js +0 -1
- package/lib/content/fields/nestable/NestableContent.d.ts +0 -9
- package/lib/content/fields/nestable/RichTextContent/Blocks.d.ts +0 -4
- package/lib/content/fields/nestable/RichTextContent/index.d.ts +0 -4
- package/lib/content/fields/slices/Slice/CompositeSliceContent.d.ts +0 -18
- package/lib/content/fields/slices/Slice/RepeatableContent.d.ts +0 -6
- package/lib/content/fields/slices/Slice/SharedSliceContent.d.ts +0 -18
- package/lib/content/fields/slices/Slice/SharedSliceContent.js +3 -1
- package/lib/content/fields/slices/Slice/SimpleSliceContent.d.ts +0 -18
- package/lib/content/fields/slices/Slice/index.d.ts +0 -36
- package/lib/content/fields/slices/SliceItem.d.ts +0 -36
- package/lib/content/fields/slices/SlicesContent.d.ts +0 -54
- package/lib/customtypes/CustomType.d.ts +169 -14
- package/lib/customtypes/Section.d.ts +169 -14
- package/lib/customtypes/diff/SharedSlice.d.ts +338 -4
- package/lib/customtypes/diff/Variation.d.ts +340 -5
- package/lib/customtypes/widgets/Group.d.ts +0 -2
- package/lib/customtypes/widgets/Widget.d.ts +169 -16
- package/lib/customtypes/widgets/nestable/Image.d.ts +0 -2
- package/lib/customtypes/widgets/nestable/Image.js +0 -1
- package/lib/customtypes/widgets/nestable/NestableWidget.d.ts +0 -1
- package/lib/customtypes/widgets/slices/CompositeSlice.d.ts +0 -2
- package/lib/customtypes/widgets/slices/LegacySlice.d.ts +0 -2
- package/lib/customtypes/widgets/slices/SharedSlice.d.ts +336 -6
- package/lib/customtypes/widgets/slices/SharedSlice.js +2 -1
- package/lib/customtypes/widgets/slices/SlicePrimaryWidget.d.ts +327 -0
- package/lib/customtypes/widgets/slices/SlicePrimaryWidget.js +8 -0
- package/lib/customtypes/widgets/slices/SliceWidget.d.ts +327 -0
- package/lib/customtypes/widgets/slices/SliceWidget.js +8 -0
- package/lib/customtypes/widgets/slices/Slices.d.ts +338 -24
- package/lib/customtypes/widgets/slices/index.d.ts +1 -0
- package/lib/customtypes/widgets/slices/index.js +1 -0
- package/package.json +1 -1
- package/src/content/fields/nestable/ImageContent.ts +0 -1
- package/src/content/fields/slices/Slice/SharedSliceContent.ts +12 -2
- package/src/customtypes/diff/Variation.ts +6 -5
- package/src/customtypes/widgets/nestable/Image.ts +0 -1
- package/src/customtypes/widgets/slices/SharedSlice.ts +2 -1
- package/src/customtypes/widgets/slices/SlicePrimaryWidget.ts +9 -0
- package/src/customtypes/widgets/slices/index.ts +1 -0
|
@@ -23,7 +23,6 @@ export declare const isImageContent: (u: unknown) => u is {
|
|
|
23
23
|
credits?: string | null;
|
|
24
24
|
alt?: string | null;
|
|
25
25
|
provider?: string | null | undefined;
|
|
26
|
-
caption?: string | null | undefined;
|
|
27
26
|
} & {
|
|
28
27
|
thumbnails?: {
|
|
29
28
|
[x: string]: {
|
|
@@ -48,7 +47,6 @@ export declare const isImageContent: (u: unknown) => u is {
|
|
|
48
47
|
credits?: string | null;
|
|
49
48
|
alt?: string | null;
|
|
50
49
|
provider?: string | null | undefined;
|
|
51
|
-
caption?: string | null | undefined;
|
|
52
50
|
};
|
|
53
51
|
};
|
|
54
52
|
} & {
|
|
@@ -76,7 +74,6 @@ export declare const ImageContentView: t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
|
76
74
|
credits: t.Type<string | null, string | null, unknown>;
|
|
77
75
|
alt: t.Type<string | null, string | null, unknown>;
|
|
78
76
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
79
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
80
77
|
}>]>>;
|
|
81
78
|
export declare type ImageContentView = t.TypeOf<typeof ImageContentView>;
|
|
82
79
|
export declare const ImageLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
@@ -101,7 +98,6 @@ export declare const ImageLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
101
98
|
credits?: string | null;
|
|
102
99
|
alt?: string | null;
|
|
103
100
|
provider?: string | null | undefined;
|
|
104
|
-
caption?: string | null | undefined;
|
|
105
101
|
} & {
|
|
106
102
|
thumbnails?: {
|
|
107
103
|
[x: string]: {
|
|
@@ -126,7 +122,6 @@ export declare const ImageLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
126
122
|
credits?: string | null;
|
|
127
123
|
alt?: string | null;
|
|
128
124
|
provider?: string | null | undefined;
|
|
129
|
-
caption?: string | null | undefined;
|
|
130
125
|
};
|
|
131
126
|
};
|
|
132
127
|
} & {
|
|
@@ -153,7 +148,6 @@ export declare const ImageLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
153
148
|
credits?: string | null;
|
|
154
149
|
alt?: string | null;
|
|
155
150
|
provider?: string | null | undefined;
|
|
156
|
-
caption?: string | null | undefined;
|
|
157
151
|
} & {
|
|
158
152
|
thumbnails?: {
|
|
159
153
|
[x: string]: {
|
|
@@ -178,7 +172,6 @@ export declare const ImageLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
178
172
|
credits?: string | null;
|
|
179
173
|
alt?: string | null;
|
|
180
174
|
provider?: string | null | undefined;
|
|
181
|
-
caption?: string | null | undefined;
|
|
182
175
|
};
|
|
183
176
|
};
|
|
184
177
|
}>, unknown>;
|
|
@@ -204,7 +197,6 @@ export declare const ImageContent: t.IntersectionC<[t.IntersectionC<[t.ExactC<t.
|
|
|
204
197
|
credits: t.Type<string | null, string | null, unknown>;
|
|
205
198
|
alt: t.Type<string | null, string | null, unknown>;
|
|
206
199
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
207
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
208
200
|
}>]>>, t.PartialC<{
|
|
209
201
|
thumbnails: t.RecordC<t.StringC, t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
210
202
|
origin: t.ExactC<t.TypeC<{
|
|
@@ -228,7 +220,6 @@ export declare const ImageContent: t.IntersectionC<[t.IntersectionC<[t.ExactC<t.
|
|
|
228
220
|
credits: t.Type<string | null, string | null, unknown>;
|
|
229
221
|
alt: t.Type<string | null, string | null, unknown>;
|
|
230
222
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
231
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
232
223
|
}>]>>>;
|
|
233
224
|
}>]>, t.ExactC<t.TypeC<{
|
|
234
225
|
__TYPE__: t.LiteralC<"ImageContent">;
|
|
@@ -36,7 +36,6 @@ exports.ImageContentView = t.exact(t.intersection([
|
|
|
36
36
|
credits: validators_1.NonEmptyStringOrNull,
|
|
37
37
|
alt: validators_1.NonEmptyStringOrNull,
|
|
38
38
|
provider: validators_1.StringOrNull,
|
|
39
|
-
caption: validators_1.StringOrNull,
|
|
40
39
|
}),
|
|
41
40
|
]));
|
|
42
41
|
const legacyReader = t.intersection([
|
|
@@ -82,7 +82,6 @@ export declare const NestableContent: t.UnionC<[t.ExactC<t.TypeC<{
|
|
|
82
82
|
credits: t.Type<string | null, string | null, unknown>;
|
|
83
83
|
alt: t.Type<string | null, string | null, unknown>;
|
|
84
84
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
85
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
86
85
|
}>]>>, t.PartialC<{
|
|
87
86
|
thumbnails: t.RecordC<t.StringC, t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
88
87
|
origin: t.ExactC<t.TypeC<{
|
|
@@ -106,7 +105,6 @@ export declare const NestableContent: t.UnionC<[t.ExactC<t.TypeC<{
|
|
|
106
105
|
credits: t.Type<string | null, string | null, unknown>;
|
|
107
106
|
alt: t.Type<string | null, string | null, unknown>;
|
|
108
107
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
109
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
110
108
|
}>]>>>;
|
|
111
109
|
}>]>, t.ExactC<t.TypeC<{
|
|
112
110
|
__TYPE__: t.LiteralC<"ImageContent">;
|
|
@@ -182,7 +180,6 @@ export declare const NestableContent: t.UnionC<[t.ExactC<t.TypeC<{
|
|
|
182
180
|
credits: t.Type<string | null, string | null, unknown>;
|
|
183
181
|
alt: t.Type<string | null, string | null, unknown>;
|
|
184
182
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
185
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
186
183
|
}>]>>, t.PartialC<{
|
|
187
184
|
linkTo: t.UnionC<[t.Type<({
|
|
188
185
|
__TYPE__: "ImageLink";
|
|
@@ -481,7 +478,6 @@ export declare const isNestableContent: (u: unknown) => u is {
|
|
|
481
478
|
credits?: string | null;
|
|
482
479
|
alt?: string | null;
|
|
483
480
|
provider?: string | null | undefined;
|
|
484
|
-
caption?: string | null | undefined;
|
|
485
481
|
} & {
|
|
486
482
|
thumbnails?: {
|
|
487
483
|
[x: string]: {
|
|
@@ -506,7 +502,6 @@ export declare const isNestableContent: (u: unknown) => u is {
|
|
|
506
502
|
credits?: string | null;
|
|
507
503
|
alt?: string | null;
|
|
508
504
|
provider?: string | null | undefined;
|
|
509
|
-
caption?: string | null | undefined;
|
|
510
505
|
};
|
|
511
506
|
};
|
|
512
507
|
} & {
|
|
@@ -581,7 +576,6 @@ export declare const isNestableContent: (u: unknown) => u is {
|
|
|
581
576
|
credits?: string | null;
|
|
582
577
|
alt?: string | null;
|
|
583
578
|
provider?: string | null | undefined;
|
|
584
|
-
caption?: string | null | undefined;
|
|
585
579
|
} & {
|
|
586
580
|
linkTo?: ({
|
|
587
581
|
__TYPE__: "ImageLink";
|
|
@@ -798,7 +792,6 @@ export declare const NestableLegacy: (ctx: LegacyContentCtx) => {
|
|
|
798
792
|
credits?: string | null;
|
|
799
793
|
alt?: string | null;
|
|
800
794
|
provider?: string | null | undefined;
|
|
801
|
-
caption?: string | null | undefined;
|
|
802
795
|
} & {
|
|
803
796
|
thumbnails?: {
|
|
804
797
|
[x: string]: {
|
|
@@ -823,7 +816,6 @@ export declare const NestableLegacy: (ctx: LegacyContentCtx) => {
|
|
|
823
816
|
credits?: string | null;
|
|
824
817
|
alt?: string | null;
|
|
825
818
|
provider?: string | null | undefined;
|
|
826
|
-
caption?: string | null | undefined;
|
|
827
819
|
};
|
|
828
820
|
};
|
|
829
821
|
} & {
|
|
@@ -898,7 +890,6 @@ export declare const NestableLegacy: (ctx: LegacyContentCtx) => {
|
|
|
898
890
|
credits?: string | null;
|
|
899
891
|
alt?: string | null;
|
|
900
892
|
provider?: string | null | undefined;
|
|
901
|
-
caption?: string | null | undefined;
|
|
902
893
|
} & {
|
|
903
894
|
linkTo?: ({
|
|
904
895
|
__TYPE__: "ImageLink";
|
|
@@ -400,7 +400,6 @@ export declare const ImageBlock: t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
|
400
400
|
credits: t.Type<string | null, string | null, unknown>;
|
|
401
401
|
alt: t.Type<string | null, string | null, unknown>;
|
|
402
402
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
403
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
404
403
|
}>]>>, t.PartialC<{
|
|
405
404
|
linkTo: t.UnionC<[t.Type<({
|
|
406
405
|
__TYPE__: "ImageLink";
|
|
@@ -643,7 +642,6 @@ export declare const BlockLegacy: t.Type<({
|
|
|
643
642
|
credits?: string | null;
|
|
644
643
|
alt?: string | null;
|
|
645
644
|
provider?: string | null | undefined;
|
|
646
|
-
caption?: string | null | undefined;
|
|
647
645
|
} & {
|
|
648
646
|
linkTo?: ({
|
|
649
647
|
__TYPE__: "ImageLink";
|
|
@@ -798,7 +796,6 @@ export declare const BlockLegacy: t.Type<({
|
|
|
798
796
|
credits?: string | null;
|
|
799
797
|
alt?: string | null;
|
|
800
798
|
provider?: string | null | undefined;
|
|
801
|
-
caption?: string | null | undefined;
|
|
802
799
|
} & {
|
|
803
800
|
linkTo?: ({
|
|
804
801
|
__TYPE__: "ImageLink";
|
|
@@ -954,7 +951,6 @@ export declare const Block: t.UnionC<[t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
|
954
951
|
credits: t.Type<string | null, string | null, unknown>;
|
|
955
952
|
alt: t.Type<string | null, string | null, unknown>;
|
|
956
953
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
957
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
958
954
|
}>]>>, t.PartialC<{
|
|
959
955
|
linkTo: t.UnionC<[t.Type<({
|
|
960
956
|
__TYPE__: "ImageLink";
|
|
@@ -27,7 +27,6 @@ export declare const isRichTextContent: (u: unknown) => u is {
|
|
|
27
27
|
credits?: string | null;
|
|
28
28
|
alt?: string | null;
|
|
29
29
|
provider?: string | null | undefined;
|
|
30
|
-
caption?: string | null | undefined;
|
|
31
30
|
} & {
|
|
32
31
|
linkTo?: ({
|
|
33
32
|
__TYPE__: "ImageLink";
|
|
@@ -186,7 +185,6 @@ export declare const RichTextContent: t.ExactC<t.TypeC<{
|
|
|
186
185
|
credits: t.Type<string | null, string | null, unknown>;
|
|
187
186
|
alt: t.Type<string | null, string | null, unknown>;
|
|
188
187
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
189
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
190
188
|
}>]>>, t.PartialC<{
|
|
191
189
|
linkTo: t.UnionC<[t.Type<({
|
|
192
190
|
__TYPE__: "ImageLink";
|
|
@@ -427,7 +425,6 @@ export declare const RichTextLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
427
425
|
credits?: string | null;
|
|
428
426
|
alt?: string | null;
|
|
429
427
|
provider?: string | null | undefined;
|
|
430
|
-
caption?: string | null | undefined;
|
|
431
428
|
} & {
|
|
432
429
|
linkTo?: ({
|
|
433
430
|
__TYPE__: "ImageLink";
|
|
@@ -583,7 +580,6 @@ export declare const RichTextLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
583
580
|
credits?: string | null;
|
|
584
581
|
alt?: string | null;
|
|
585
582
|
provider?: string | null | undefined;
|
|
586
|
-
caption?: string | null | undefined;
|
|
587
583
|
} & {
|
|
588
584
|
linkTo?: ({
|
|
589
585
|
__TYPE__: "ImageLink";
|
|
@@ -88,7 +88,6 @@ export declare const isCompositeSliceContent: (u: unknown) => u is {
|
|
|
88
88
|
credits?: string | null;
|
|
89
89
|
alt?: string | null;
|
|
90
90
|
provider?: string | null | undefined;
|
|
91
|
-
caption?: string | null | undefined;
|
|
92
91
|
} & {
|
|
93
92
|
thumbnails?: {
|
|
94
93
|
[x: string]: {
|
|
@@ -113,7 +112,6 @@ export declare const isCompositeSliceContent: (u: unknown) => u is {
|
|
|
113
112
|
credits?: string | null;
|
|
114
113
|
alt?: string | null;
|
|
115
114
|
provider?: string | null | undefined;
|
|
116
|
-
caption?: string | null | undefined;
|
|
117
115
|
};
|
|
118
116
|
};
|
|
119
117
|
} & {
|
|
@@ -188,7 +186,6 @@ export declare const isCompositeSliceContent: (u: unknown) => u is {
|
|
|
188
186
|
credits?: string | null;
|
|
189
187
|
alt?: string | null;
|
|
190
188
|
provider?: string | null | undefined;
|
|
191
|
-
caption?: string | null | undefined;
|
|
192
189
|
} & {
|
|
193
190
|
linkTo?: ({
|
|
194
191
|
__TYPE__: "ImageLink";
|
|
@@ -407,7 +404,6 @@ export declare const isCompositeSliceContent: (u: unknown) => u is {
|
|
|
407
404
|
credits?: string | null;
|
|
408
405
|
alt?: string | null;
|
|
409
406
|
provider?: string | null | undefined;
|
|
410
|
-
caption?: string | null | undefined;
|
|
411
407
|
} & {
|
|
412
408
|
thumbnails?: {
|
|
413
409
|
[x: string]: {
|
|
@@ -432,7 +428,6 @@ export declare const isCompositeSliceContent: (u: unknown) => u is {
|
|
|
432
428
|
credits?: string | null;
|
|
433
429
|
alt?: string | null;
|
|
434
430
|
provider?: string | null | undefined;
|
|
435
|
-
caption?: string | null | undefined;
|
|
436
431
|
};
|
|
437
432
|
};
|
|
438
433
|
} & {
|
|
@@ -507,7 +502,6 @@ export declare const isCompositeSliceContent: (u: unknown) => u is {
|
|
|
507
502
|
credits?: string | null;
|
|
508
503
|
alt?: string | null;
|
|
509
504
|
provider?: string | null | undefined;
|
|
510
|
-
caption?: string | null | undefined;
|
|
511
505
|
} & {
|
|
512
506
|
linkTo?: ({
|
|
513
507
|
__TYPE__: "ImageLink";
|
|
@@ -728,7 +722,6 @@ export declare const CompositeSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
728
722
|
credits?: string | null;
|
|
729
723
|
alt?: string | null;
|
|
730
724
|
provider?: string | null | undefined;
|
|
731
|
-
caption?: string | null | undefined;
|
|
732
725
|
} & {
|
|
733
726
|
thumbnails?: {
|
|
734
727
|
[x: string]: {
|
|
@@ -753,7 +746,6 @@ export declare const CompositeSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
753
746
|
credits?: string | null;
|
|
754
747
|
alt?: string | null;
|
|
755
748
|
provider?: string | null | undefined;
|
|
756
|
-
caption?: string | null | undefined;
|
|
757
749
|
};
|
|
758
750
|
};
|
|
759
751
|
} & {
|
|
@@ -828,7 +820,6 @@ export declare const CompositeSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
828
820
|
credits?: string | null;
|
|
829
821
|
alt?: string | null;
|
|
830
822
|
provider?: string | null | undefined;
|
|
831
|
-
caption?: string | null | undefined;
|
|
832
823
|
} & {
|
|
833
824
|
linkTo?: ({
|
|
834
825
|
__TYPE__: "ImageLink";
|
|
@@ -1047,7 +1038,6 @@ export declare const CompositeSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
1047
1038
|
credits?: string | null;
|
|
1048
1039
|
alt?: string | null;
|
|
1049
1040
|
provider?: string | null | undefined;
|
|
1050
|
-
caption?: string | null | undefined;
|
|
1051
1041
|
} & {
|
|
1052
1042
|
thumbnails?: {
|
|
1053
1043
|
[x: string]: {
|
|
@@ -1072,7 +1062,6 @@ export declare const CompositeSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
1072
1062
|
credits?: string | null;
|
|
1073
1063
|
alt?: string | null;
|
|
1074
1064
|
provider?: string | null | undefined;
|
|
1075
|
-
caption?: string | null | undefined;
|
|
1076
1065
|
};
|
|
1077
1066
|
};
|
|
1078
1067
|
} & {
|
|
@@ -1147,7 +1136,6 @@ export declare const CompositeSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
1147
1136
|
credits?: string | null;
|
|
1148
1137
|
alt?: string | null;
|
|
1149
1138
|
provider?: string | null | undefined;
|
|
1150
|
-
caption?: string | null | undefined;
|
|
1151
1139
|
} & {
|
|
1152
1140
|
linkTo?: ({
|
|
1153
1141
|
__TYPE__: "ImageLink";
|
|
@@ -1372,7 +1360,6 @@ export declare const CompositeSliceContent: t.ExactC<t.TypeC<{
|
|
|
1372
1360
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1373
1361
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1374
1362
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1375
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1376
1363
|
}>]>>, t.PartialC<{
|
|
1377
1364
|
thumbnails: t.RecordC<t.StringC, t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
1378
1365
|
origin: t.ExactC<t.TypeC<{
|
|
@@ -1396,7 +1383,6 @@ export declare const CompositeSliceContent: t.ExactC<t.TypeC<{
|
|
|
1396
1383
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1397
1384
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1398
1385
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1399
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1400
1386
|
}>]>>>;
|
|
1401
1387
|
}>]>, t.ExactC<t.TypeC<{
|
|
1402
1388
|
__TYPE__: t.LiteralC<"ImageContent">;
|
|
@@ -1472,7 +1458,6 @@ export declare const CompositeSliceContent: t.ExactC<t.TypeC<{
|
|
|
1472
1458
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1473
1459
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1474
1460
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1475
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1476
1461
|
}>]>>, t.PartialC<{
|
|
1477
1462
|
linkTo: t.UnionC<[t.Type<({
|
|
1478
1463
|
__TYPE__: "ImageLink";
|
|
@@ -1770,7 +1755,6 @@ export declare const CompositeSliceContent: t.ExactC<t.TypeC<{
|
|
|
1770
1755
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1771
1756
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1772
1757
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1773
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1774
1758
|
}>]>>, t.PartialC<{
|
|
1775
1759
|
thumbnails: t.RecordC<t.StringC, t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
1776
1760
|
origin: t.ExactC<t.TypeC<{
|
|
@@ -1794,7 +1778,6 @@ export declare const CompositeSliceContent: t.ExactC<t.TypeC<{
|
|
|
1794
1778
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1795
1779
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1796
1780
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1797
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1798
1781
|
}>]>>>;
|
|
1799
1782
|
}>]>, t.ExactC<t.TypeC<{
|
|
1800
1783
|
__TYPE__: t.LiteralC<"ImageContent">;
|
|
@@ -1870,7 +1853,6 @@ export declare const CompositeSliceContent: t.ExactC<t.TypeC<{
|
|
|
1870
1853
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1871
1854
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1872
1855
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1873
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1874
1856
|
}>]>>, t.PartialC<{
|
|
1875
1857
|
linkTo: t.UnionC<[t.Type<({
|
|
1876
1858
|
__TYPE__: "ImageLink";
|
|
@@ -83,7 +83,6 @@ export declare const RepeatableWidgetsLegacy: (ctx: LegacyContentCtx) => t.Array
|
|
|
83
83
|
credits?: string | null;
|
|
84
84
|
alt?: string | null;
|
|
85
85
|
provider?: string | null | undefined;
|
|
86
|
-
caption?: string | null | undefined;
|
|
87
86
|
} & {
|
|
88
87
|
thumbnails?: {
|
|
89
88
|
[x: string]: {
|
|
@@ -108,7 +107,6 @@ export declare const RepeatableWidgetsLegacy: (ctx: LegacyContentCtx) => t.Array
|
|
|
108
107
|
credits?: string | null;
|
|
109
108
|
alt?: string | null;
|
|
110
109
|
provider?: string | null | undefined;
|
|
111
|
-
caption?: string | null | undefined;
|
|
112
110
|
};
|
|
113
111
|
};
|
|
114
112
|
} & {
|
|
@@ -183,7 +181,6 @@ export declare const RepeatableWidgetsLegacy: (ctx: LegacyContentCtx) => t.Array
|
|
|
183
181
|
credits?: string | null;
|
|
184
182
|
alt?: string | null;
|
|
185
183
|
provider?: string | null | undefined;
|
|
186
|
-
caption?: string | null | undefined;
|
|
187
184
|
} & {
|
|
188
185
|
linkTo?: ({
|
|
189
186
|
__TYPE__: "ImageLink";
|
|
@@ -404,7 +401,6 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
404
401
|
credits: t.Type<string | null, string | null, unknown>;
|
|
405
402
|
alt: t.Type<string | null, string | null, unknown>;
|
|
406
403
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
407
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
408
404
|
}>]>>, t.PartialC<{
|
|
409
405
|
thumbnails: t.RecordC<t.StringC, t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
410
406
|
origin: t.ExactC<t.TypeC<{
|
|
@@ -428,7 +424,6 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
428
424
|
credits: t.Type<string | null, string | null, unknown>;
|
|
429
425
|
alt: t.Type<string | null, string | null, unknown>;
|
|
430
426
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
431
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
432
427
|
}>]>>>;
|
|
433
428
|
}>]>, t.ExactC<t.TypeC<{
|
|
434
429
|
__TYPE__: t.LiteralC<"ImageContent">;
|
|
@@ -504,7 +499,6 @@ export declare const RepeatableWidgets: t.ArrayC<t.ExactC<t.TypeC<{
|
|
|
504
499
|
credits: t.Type<string | null, string | null, unknown>;
|
|
505
500
|
alt: t.Type<string | null, string | null, unknown>;
|
|
506
501
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
507
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
508
502
|
}>]>>, t.PartialC<{
|
|
509
503
|
linkTo: t.UnionC<[t.Type<({
|
|
510
504
|
__TYPE__: "ImageLink";
|
|
@@ -89,7 +89,6 @@ export declare const isSharedSliceContent: (u: unknown) => u is {
|
|
|
89
89
|
credits?: string | null;
|
|
90
90
|
alt?: string | null;
|
|
91
91
|
provider?: string | null | undefined;
|
|
92
|
-
caption?: string | null | undefined;
|
|
93
92
|
} & {
|
|
94
93
|
thumbnails?: {
|
|
95
94
|
[x: string]: {
|
|
@@ -114,7 +113,6 @@ export declare const isSharedSliceContent: (u: unknown) => u is {
|
|
|
114
113
|
credits?: string | null;
|
|
115
114
|
alt?: string | null;
|
|
116
115
|
provider?: string | null | undefined;
|
|
117
|
-
caption?: string | null | undefined;
|
|
118
116
|
};
|
|
119
117
|
};
|
|
120
118
|
} & {
|
|
@@ -189,7 +187,6 @@ export declare const isSharedSliceContent: (u: unknown) => u is {
|
|
|
189
187
|
credits?: string | null;
|
|
190
188
|
alt?: string | null;
|
|
191
189
|
provider?: string | null | undefined;
|
|
192
|
-
caption?: string | null | undefined;
|
|
193
190
|
} & {
|
|
194
191
|
linkTo?: ({
|
|
195
192
|
__TYPE__: "ImageLink";
|
|
@@ -408,7 +405,6 @@ export declare const isSharedSliceContent: (u: unknown) => u is {
|
|
|
408
405
|
credits?: string | null;
|
|
409
406
|
alt?: string | null;
|
|
410
407
|
provider?: string | null | undefined;
|
|
411
|
-
caption?: string | null | undefined;
|
|
412
408
|
} & {
|
|
413
409
|
thumbnails?: {
|
|
414
410
|
[x: string]: {
|
|
@@ -433,7 +429,6 @@ export declare const isSharedSliceContent: (u: unknown) => u is {
|
|
|
433
429
|
credits?: string | null;
|
|
434
430
|
alt?: string | null;
|
|
435
431
|
provider?: string | null | undefined;
|
|
436
|
-
caption?: string | null | undefined;
|
|
437
432
|
};
|
|
438
433
|
};
|
|
439
434
|
} & {
|
|
@@ -508,7 +503,6 @@ export declare const isSharedSliceContent: (u: unknown) => u is {
|
|
|
508
503
|
credits?: string | null;
|
|
509
504
|
alt?: string | null;
|
|
510
505
|
provider?: string | null | undefined;
|
|
511
|
-
caption?: string | null | undefined;
|
|
512
506
|
} & {
|
|
513
507
|
linkTo?: ({
|
|
514
508
|
__TYPE__: "ImageLink";
|
|
@@ -730,7 +724,6 @@ export declare const SharedSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
730
724
|
credits?: string | null;
|
|
731
725
|
alt?: string | null;
|
|
732
726
|
provider?: string | null | undefined;
|
|
733
|
-
caption?: string | null | undefined;
|
|
734
727
|
} & {
|
|
735
728
|
thumbnails?: {
|
|
736
729
|
[x: string]: {
|
|
@@ -755,7 +748,6 @@ export declare const SharedSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
755
748
|
credits?: string | null;
|
|
756
749
|
alt?: string | null;
|
|
757
750
|
provider?: string | null | undefined;
|
|
758
|
-
caption?: string | null | undefined;
|
|
759
751
|
};
|
|
760
752
|
};
|
|
761
753
|
} & {
|
|
@@ -830,7 +822,6 @@ export declare const SharedSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
830
822
|
credits?: string | null;
|
|
831
823
|
alt?: string | null;
|
|
832
824
|
provider?: string | null | undefined;
|
|
833
|
-
caption?: string | null | undefined;
|
|
834
825
|
} & {
|
|
835
826
|
linkTo?: ({
|
|
836
827
|
__TYPE__: "ImageLink";
|
|
@@ -1049,7 +1040,6 @@ export declare const SharedSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
1049
1040
|
credits?: string | null;
|
|
1050
1041
|
alt?: string | null;
|
|
1051
1042
|
provider?: string | null | undefined;
|
|
1052
|
-
caption?: string | null | undefined;
|
|
1053
1043
|
} & {
|
|
1054
1044
|
thumbnails?: {
|
|
1055
1045
|
[x: string]: {
|
|
@@ -1074,7 +1064,6 @@ export declare const SharedSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
1074
1064
|
credits?: string | null;
|
|
1075
1065
|
alt?: string | null;
|
|
1076
1066
|
provider?: string | null | undefined;
|
|
1077
|
-
caption?: string | null | undefined;
|
|
1078
1067
|
};
|
|
1079
1068
|
};
|
|
1080
1069
|
} & {
|
|
@@ -1149,7 +1138,6 @@ export declare const SharedSliceLegacy: (ctx: LegacyContentCtx) => t.Type<{
|
|
|
1149
1138
|
credits?: string | null;
|
|
1150
1139
|
alt?: string | null;
|
|
1151
1140
|
provider?: string | null | undefined;
|
|
1152
|
-
caption?: string | null | undefined;
|
|
1153
1141
|
} & {
|
|
1154
1142
|
linkTo?: ({
|
|
1155
1143
|
__TYPE__: "ImageLink";
|
|
@@ -1376,7 +1364,6 @@ export declare const SharedSliceContent: t.ExactC<t.TypeC<{
|
|
|
1376
1364
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1377
1365
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1378
1366
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1379
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1380
1367
|
}>]>>, t.PartialC<{
|
|
1381
1368
|
thumbnails: t.RecordC<t.StringC, t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
1382
1369
|
origin: t.ExactC<t.TypeC<{
|
|
@@ -1400,7 +1387,6 @@ export declare const SharedSliceContent: t.ExactC<t.TypeC<{
|
|
|
1400
1387
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1401
1388
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1402
1389
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1403
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1404
1390
|
}>]>>>;
|
|
1405
1391
|
}>]>, t.ExactC<t.TypeC<{
|
|
1406
1392
|
__TYPE__: t.LiteralC<"ImageContent">;
|
|
@@ -1476,7 +1462,6 @@ export declare const SharedSliceContent: t.ExactC<t.TypeC<{
|
|
|
1476
1462
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1477
1463
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1478
1464
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1479
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1480
1465
|
}>]>>, t.PartialC<{
|
|
1481
1466
|
linkTo: t.UnionC<[t.Type<({
|
|
1482
1467
|
__TYPE__: "ImageLink";
|
|
@@ -1774,7 +1759,6 @@ export declare const SharedSliceContent: t.ExactC<t.TypeC<{
|
|
|
1774
1759
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1775
1760
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1776
1761
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1777
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1778
1762
|
}>]>>, t.PartialC<{
|
|
1779
1763
|
thumbnails: t.RecordC<t.StringC, t.ExactC<t.IntersectionC<[t.TypeC<{
|
|
1780
1764
|
origin: t.ExactC<t.TypeC<{
|
|
@@ -1798,7 +1782,6 @@ export declare const SharedSliceContent: t.ExactC<t.TypeC<{
|
|
|
1798
1782
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1799
1783
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1800
1784
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1801
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1802
1785
|
}>]>>>;
|
|
1803
1786
|
}>]>, t.ExactC<t.TypeC<{
|
|
1804
1787
|
__TYPE__: t.LiteralC<"ImageContent">;
|
|
@@ -1874,7 +1857,6 @@ export declare const SharedSliceContent: t.ExactC<t.TypeC<{
|
|
|
1874
1857
|
credits: t.Type<string | null, string | null, unknown>;
|
|
1875
1858
|
alt: t.Type<string | null, string | null, unknown>;
|
|
1876
1859
|
provider: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1877
|
-
caption: t.UnionC<[t.Type<string, string, unknown>, t.NullC, t.UndefinedC]>;
|
|
1878
1860
|
}>]>>, t.PartialC<{
|
|
1879
1861
|
linkTo: t.UnionC<[t.Type<({
|
|
1880
1862
|
__TYPE__: "ImageLink";
|
|
@@ -101,7 +101,9 @@ exports.SharedSliceContent = t.strict({
|
|
|
101
101
|
function sharedSliceContentWithDefaultValues(customType, content) {
|
|
102
102
|
var _a, _b;
|
|
103
103
|
const variationConfig = customType.variations.find((v) => v.id === content.variation);
|
|
104
|
-
|
|
104
|
+
// Temporarily filtering out group fields and casting to NestableWidget until
|
|
105
|
+
// we support group fields in primary
|
|
106
|
+
const primaryConfig = Object.fromEntries(Object.entries((_a = variationConfig === null || variationConfig === void 0 ? void 0 : variationConfig.primary) !== null && _a !== void 0 ? _a : {}).filter(([_, value]) => value.type !== "Group"));
|
|
105
107
|
const itemsConfig = (_b = variationConfig === null || variationConfig === void 0 ? void 0 : variationConfig.items) !== null && _b !== void 0 ? _b : {};
|
|
106
108
|
const updatedPrimaryContent = (0, withDefaultValues_1.withDefaultNestableContentValues)(primaryConfig, content.primary);
|
|
107
109
|
const updatedItemsContent = (0, withDefaultValues_1.repeatableContentWithDefaultNestableContentValues)(itemsConfig, content.items);
|