@squiz/dx-page-contents-lib 1.71.1 → 1.72.0
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/formatted-text.d.ts +154 -0
- package/lib/formatted-text.js +31 -1
- package/lib/formatted-text.js.map +1 -1
- package/lib/layout-content.d.ts +87 -2
- package/lib/layout-content.js +5 -2
- package/lib/layout-content.js.map +1 -1
- package/lib/layouts/custom-layout.d.ts +160 -25
- package/lib/layouts/index.d.ts +567 -27
- package/lib/layouts/raw.layout.d.ts +111 -3
- package/lib/layouts/single-column.layout.d.ts +111 -3
- package/lib/layouts/two-column.layout.d.ts +222 -6
- package/lib/mocks/PageContentsHelpers.d.ts +711 -36
- package/lib/mocks/PageContentsMocks.js +1 -0
- package/lib/mocks/PageContentsMocks.js.map +1 -1
- package/lib/page-contents-lib.d.ts +1 -1
- package/lib/page-contents-lib.js +2 -1
- package/lib/page-contents-lib.js.map +1 -1
- package/package.json +1 -1
|
@@ -24,49 +24,49 @@ export declare const CustomLayoutConfig: z.ZodEffects<z.ZodObject<{
|
|
|
24
24
|
minNodes: z.ZodDefault<z.ZodNumber>;
|
|
25
25
|
maxNodes: z.ZodOptional<z.ZodNumber>;
|
|
26
26
|
}, "strip", z.ZodTypeAny, {
|
|
27
|
+
minNodes: number;
|
|
27
28
|
rootWrapper: {
|
|
28
29
|
tag: string;
|
|
29
30
|
classes?: string[] | undefined;
|
|
30
31
|
};
|
|
31
|
-
|
|
32
|
+
maxNodes?: number | undefined;
|
|
32
33
|
nodeWrapper?: {
|
|
33
34
|
tag: string;
|
|
34
35
|
classes?: string[] | undefined;
|
|
35
36
|
} | undefined;
|
|
36
|
-
maxNodes?: number | undefined;
|
|
37
37
|
}, {
|
|
38
38
|
rootWrapper: {
|
|
39
39
|
tag: string;
|
|
40
40
|
classes?: string[] | undefined;
|
|
41
41
|
};
|
|
42
|
+
minNodes?: number | undefined;
|
|
43
|
+
maxNodes?: number | undefined;
|
|
42
44
|
nodeWrapper?: {
|
|
43
45
|
tag: string;
|
|
44
46
|
classes?: string[] | undefined;
|
|
45
47
|
} | undefined;
|
|
46
|
-
minNodes?: number | undefined;
|
|
47
|
-
maxNodes?: number | undefined;
|
|
48
48
|
}>, {
|
|
49
|
+
minNodes: number;
|
|
49
50
|
rootWrapper: {
|
|
50
51
|
tag: string;
|
|
51
52
|
classes?: string[] | undefined;
|
|
52
53
|
};
|
|
53
|
-
|
|
54
|
+
maxNodes?: number | undefined;
|
|
54
55
|
nodeWrapper?: {
|
|
55
56
|
tag: string;
|
|
56
57
|
classes?: string[] | undefined;
|
|
57
58
|
} | undefined;
|
|
58
|
-
maxNodes?: number | undefined;
|
|
59
59
|
}, {
|
|
60
60
|
rootWrapper: {
|
|
61
61
|
tag: string;
|
|
62
62
|
classes?: string[] | undefined;
|
|
63
63
|
};
|
|
64
|
+
minNodes?: number | undefined;
|
|
65
|
+
maxNodes?: number | undefined;
|
|
64
66
|
nodeWrapper?: {
|
|
65
67
|
tag: string;
|
|
66
68
|
classes?: string[] | undefined;
|
|
67
69
|
} | undefined;
|
|
68
|
-
minNodes?: number | undefined;
|
|
69
|
-
maxNodes?: number | undefined;
|
|
70
70
|
}>;
|
|
71
71
|
export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
72
72
|
name: z.ZodLiteral<"custom-layout">;
|
|
@@ -94,49 +94,49 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
94
94
|
minNodes: z.ZodDefault<z.ZodNumber>;
|
|
95
95
|
maxNodes: z.ZodOptional<z.ZodNumber>;
|
|
96
96
|
}, "strip", z.ZodTypeAny, {
|
|
97
|
+
minNodes: number;
|
|
97
98
|
rootWrapper: {
|
|
98
99
|
tag: string;
|
|
99
100
|
classes?: string[] | undefined;
|
|
100
101
|
};
|
|
101
|
-
|
|
102
|
+
maxNodes?: number | undefined;
|
|
102
103
|
nodeWrapper?: {
|
|
103
104
|
tag: string;
|
|
104
105
|
classes?: string[] | undefined;
|
|
105
106
|
} | undefined;
|
|
106
|
-
maxNodes?: number | undefined;
|
|
107
107
|
}, {
|
|
108
108
|
rootWrapper: {
|
|
109
109
|
tag: string;
|
|
110
110
|
classes?: string[] | undefined;
|
|
111
111
|
};
|
|
112
|
+
minNodes?: number | undefined;
|
|
113
|
+
maxNodes?: number | undefined;
|
|
112
114
|
nodeWrapper?: {
|
|
113
115
|
tag: string;
|
|
114
116
|
classes?: string[] | undefined;
|
|
115
117
|
} | undefined;
|
|
116
|
-
minNodes?: number | undefined;
|
|
117
|
-
maxNodes?: number | undefined;
|
|
118
118
|
}>, {
|
|
119
|
+
minNodes: number;
|
|
119
120
|
rootWrapper: {
|
|
120
121
|
tag: string;
|
|
121
122
|
classes?: string[] | undefined;
|
|
122
123
|
};
|
|
123
|
-
|
|
124
|
+
maxNodes?: number | undefined;
|
|
124
125
|
nodeWrapper?: {
|
|
125
126
|
tag: string;
|
|
126
127
|
classes?: string[] | undefined;
|
|
127
128
|
} | undefined;
|
|
128
|
-
maxNodes?: number | undefined;
|
|
129
129
|
}, {
|
|
130
130
|
rootWrapper: {
|
|
131
131
|
tag: string;
|
|
132
132
|
classes?: string[] | undefined;
|
|
133
133
|
};
|
|
134
|
+
minNodes?: number | undefined;
|
|
135
|
+
maxNodes?: number | undefined;
|
|
134
136
|
nodeWrapper?: {
|
|
135
137
|
tag: string;
|
|
136
138
|
classes?: string[] | undefined;
|
|
137
139
|
} | undefined;
|
|
138
|
-
minNodes?: number | undefined;
|
|
139
|
-
maxNodes?: number | undefined;
|
|
140
140
|
}>;
|
|
141
141
|
content: z.ZodObject<{
|
|
142
142
|
main: z.ZodEffects<z.ZodArray<z.ZodUnion<[z.ZodType<{
|
|
@@ -282,6 +282,33 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
282
282
|
}>, z.ZodType<import("../layout-content").LayoutVariationNode, z.ZodTypeDef, {
|
|
283
283
|
type: "variation";
|
|
284
284
|
default: {};
|
|
285
|
+
}>, z.ZodType<import("../layout-content").DeveloperDefinedLayoutNode, z.ZodTypeDef, {
|
|
286
|
+
type: "layout";
|
|
287
|
+
layout: {
|
|
288
|
+
options: Record<string, {
|
|
289
|
+
values: string[];
|
|
290
|
+
displayName: string;
|
|
291
|
+
description: string;
|
|
292
|
+
selectedValue: string;
|
|
293
|
+
}>;
|
|
294
|
+
name: string;
|
|
295
|
+
version: string;
|
|
296
|
+
displayName: string;
|
|
297
|
+
description: string;
|
|
298
|
+
template: string;
|
|
299
|
+
zones: Record<string, {
|
|
300
|
+
displayName: string;
|
|
301
|
+
description: string;
|
|
302
|
+
minNodes: number;
|
|
303
|
+
maxNodes?: number | undefined;
|
|
304
|
+
}>;
|
|
305
|
+
} | {
|
|
306
|
+
options: Record<string, {
|
|
307
|
+
selectedValue: string;
|
|
308
|
+
}>;
|
|
309
|
+
name: string;
|
|
310
|
+
version: string;
|
|
311
|
+
};
|
|
285
312
|
}>]>, "many">, (import("../layout-content").LayoutVariationNode | ({
|
|
286
313
|
value: string;
|
|
287
314
|
type: "text";
|
|
@@ -353,7 +380,7 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
353
380
|
matrixIdentifier?: string | undefined;
|
|
354
381
|
}) & {
|
|
355
382
|
children: import("../layout-content").LayoutContentNodes[];
|
|
356
|
-
})))[], ({
|
|
383
|
+
})) | import("../layout-content").DeveloperDefinedLayoutNode)[], ({
|
|
357
384
|
value: string;
|
|
358
385
|
type: "text";
|
|
359
386
|
} | {
|
|
@@ -425,6 +452,33 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
425
452
|
} | {
|
|
426
453
|
type: "variation";
|
|
427
454
|
default: {};
|
|
455
|
+
} | {
|
|
456
|
+
type: "layout";
|
|
457
|
+
layout: {
|
|
458
|
+
options: Record<string, {
|
|
459
|
+
values: string[];
|
|
460
|
+
displayName: string;
|
|
461
|
+
description: string;
|
|
462
|
+
selectedValue: string;
|
|
463
|
+
}>;
|
|
464
|
+
name: string;
|
|
465
|
+
version: string;
|
|
466
|
+
displayName: string;
|
|
467
|
+
description: string;
|
|
468
|
+
template: string;
|
|
469
|
+
zones: Record<string, {
|
|
470
|
+
displayName: string;
|
|
471
|
+
description: string;
|
|
472
|
+
minNodes: number;
|
|
473
|
+
maxNodes?: number | undefined;
|
|
474
|
+
}>;
|
|
475
|
+
} | {
|
|
476
|
+
options: Record<string, {
|
|
477
|
+
selectedValue: string;
|
|
478
|
+
}>;
|
|
479
|
+
name: string;
|
|
480
|
+
version: string;
|
|
481
|
+
};
|
|
428
482
|
})[]>;
|
|
429
483
|
}, "strip", z.ZodTypeAny, {
|
|
430
484
|
main: (import("../layout-content").LayoutVariationNode | ({
|
|
@@ -498,7 +552,7 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
498
552
|
matrixIdentifier?: string | undefined;
|
|
499
553
|
}) & {
|
|
500
554
|
children: import("../layout-content").LayoutContentNodes[];
|
|
501
|
-
})))[];
|
|
555
|
+
})) | import("../layout-content").DeveloperDefinedLayoutNode)[];
|
|
502
556
|
}, {
|
|
503
557
|
main: ({
|
|
504
558
|
value: string;
|
|
@@ -572,6 +626,33 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
572
626
|
} | {
|
|
573
627
|
type: "variation";
|
|
574
628
|
default: {};
|
|
629
|
+
} | {
|
|
630
|
+
type: "layout";
|
|
631
|
+
layout: {
|
|
632
|
+
options: Record<string, {
|
|
633
|
+
values: string[];
|
|
634
|
+
displayName: string;
|
|
635
|
+
description: string;
|
|
636
|
+
selectedValue: string;
|
|
637
|
+
}>;
|
|
638
|
+
name: string;
|
|
639
|
+
version: string;
|
|
640
|
+
displayName: string;
|
|
641
|
+
description: string;
|
|
642
|
+
template: string;
|
|
643
|
+
zones: Record<string, {
|
|
644
|
+
displayName: string;
|
|
645
|
+
description: string;
|
|
646
|
+
minNodes: number;
|
|
647
|
+
maxNodes?: number | undefined;
|
|
648
|
+
}>;
|
|
649
|
+
} | {
|
|
650
|
+
options: Record<string, {
|
|
651
|
+
selectedValue: string;
|
|
652
|
+
}>;
|
|
653
|
+
name: string;
|
|
654
|
+
version: string;
|
|
655
|
+
};
|
|
575
656
|
})[];
|
|
576
657
|
}>;
|
|
577
658
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -647,20 +728,20 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
647
728
|
matrixIdentifier?: string | undefined;
|
|
648
729
|
}) & {
|
|
649
730
|
children: import("../layout-content").LayoutContentNodes[];
|
|
650
|
-
})))[];
|
|
731
|
+
})) | import("../layout-content").DeveloperDefinedLayoutNode)[];
|
|
651
732
|
};
|
|
652
733
|
name: "custom-layout";
|
|
653
734
|
config: {
|
|
735
|
+
minNodes: number;
|
|
654
736
|
rootWrapper: {
|
|
655
737
|
tag: string;
|
|
656
738
|
classes?: string[] | undefined;
|
|
657
739
|
};
|
|
658
|
-
|
|
740
|
+
maxNodes?: number | undefined;
|
|
659
741
|
nodeWrapper?: {
|
|
660
742
|
tag: string;
|
|
661
743
|
classes?: string[] | undefined;
|
|
662
744
|
} | undefined;
|
|
663
|
-
maxNodes?: number | undefined;
|
|
664
745
|
};
|
|
665
746
|
}, {
|
|
666
747
|
content: {
|
|
@@ -736,6 +817,33 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
736
817
|
} | {
|
|
737
818
|
type: "variation";
|
|
738
819
|
default: {};
|
|
820
|
+
} | {
|
|
821
|
+
type: "layout";
|
|
822
|
+
layout: {
|
|
823
|
+
options: Record<string, {
|
|
824
|
+
values: string[];
|
|
825
|
+
displayName: string;
|
|
826
|
+
description: string;
|
|
827
|
+
selectedValue: string;
|
|
828
|
+
}>;
|
|
829
|
+
name: string;
|
|
830
|
+
version: string;
|
|
831
|
+
displayName: string;
|
|
832
|
+
description: string;
|
|
833
|
+
template: string;
|
|
834
|
+
zones: Record<string, {
|
|
835
|
+
displayName: string;
|
|
836
|
+
description: string;
|
|
837
|
+
minNodes: number;
|
|
838
|
+
maxNodes?: number | undefined;
|
|
839
|
+
}>;
|
|
840
|
+
} | {
|
|
841
|
+
options: Record<string, {
|
|
842
|
+
selectedValue: string;
|
|
843
|
+
}>;
|
|
844
|
+
name: string;
|
|
845
|
+
version: string;
|
|
846
|
+
};
|
|
739
847
|
})[];
|
|
740
848
|
};
|
|
741
849
|
name: "custom-layout";
|
|
@@ -744,12 +852,12 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
744
852
|
tag: string;
|
|
745
853
|
classes?: string[] | undefined;
|
|
746
854
|
};
|
|
855
|
+
minNodes?: number | undefined;
|
|
856
|
+
maxNodes?: number | undefined;
|
|
747
857
|
nodeWrapper?: {
|
|
748
858
|
tag: string;
|
|
749
859
|
classes?: string[] | undefined;
|
|
750
860
|
} | undefined;
|
|
751
|
-
minNodes?: number | undefined;
|
|
752
|
-
maxNodes?: number | undefined;
|
|
753
861
|
};
|
|
754
862
|
}>, {
|
|
755
863
|
name: "custom-layout";
|
|
@@ -831,6 +939,33 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
831
939
|
} | {
|
|
832
940
|
type: "variation";
|
|
833
941
|
default: {};
|
|
942
|
+
} | {
|
|
943
|
+
type: "layout";
|
|
944
|
+
layout: {
|
|
945
|
+
options: Record<string, {
|
|
946
|
+
values: string[];
|
|
947
|
+
displayName: string;
|
|
948
|
+
description: string;
|
|
949
|
+
selectedValue: string;
|
|
950
|
+
}>;
|
|
951
|
+
name: string;
|
|
952
|
+
version: string;
|
|
953
|
+
displayName: string;
|
|
954
|
+
description: string;
|
|
955
|
+
template: string;
|
|
956
|
+
zones: Record<string, {
|
|
957
|
+
displayName: string;
|
|
958
|
+
description: string;
|
|
959
|
+
minNodes: number;
|
|
960
|
+
maxNodes?: number | undefined;
|
|
961
|
+
}>;
|
|
962
|
+
} | {
|
|
963
|
+
options: Record<string, {
|
|
964
|
+
selectedValue: string;
|
|
965
|
+
}>;
|
|
966
|
+
name: string;
|
|
967
|
+
version: string;
|
|
968
|
+
};
|
|
834
969
|
})[];
|
|
835
970
|
};
|
|
836
971
|
name: "custom-layout";
|
|
@@ -839,12 +974,12 @@ export declare const CustomLayout: z.ZodEffects<z.ZodObject<{
|
|
|
839
974
|
tag: string;
|
|
840
975
|
classes?: string[] | undefined;
|
|
841
976
|
};
|
|
977
|
+
minNodes?: number | undefined;
|
|
978
|
+
maxNodes?: number | undefined;
|
|
842
979
|
nodeWrapper?: {
|
|
843
980
|
tag: string;
|
|
844
981
|
classes?: string[] | undefined;
|
|
845
982
|
} | undefined;
|
|
846
|
-
minNodes?: number | undefined;
|
|
847
|
-
maxNodes?: number | undefined;
|
|
848
983
|
};
|
|
849
984
|
}>;
|
|
850
985
|
export type CustomLayout = z.infer<typeof CustomLayout>;
|