@rebuy/rebuy 3.1.1 → 3.2.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/dist/index.cjs +16 -10
- package/dist/index.mjs +16 -10
- package/dist/schema/checkout-and-beyond/constants.cjs +5 -1
- package/dist/schema/checkout-and-beyond/constants.mjs +5 -1
- package/dist/schema/checkout-and-beyond/index.cjs +5 -1
- package/dist/schema/checkout-and-beyond/index.mjs +5 -1
- package/dist/schema/widget-data.cjs +5 -2
- package/dist/schema/widget-data.mjs +5 -2
- package/dist/schema/widgets/checkout-and-beyond/common.d.ts +19 -1
- package/dist/schema/widgets/checkout-and-beyond/text.d.ts +4 -4
- package/dist/schema/widgets/post-purchase-offer/postPurchaseBlocks.d.ts +18 -18
- package/dist/schema/widgets/post-purchase-offer/postPurchaseOffer.d.ts +9 -9
- package/dist/schema/widgets/post-purchase-offer/postPurchaseSettings.d.ts +9 -9
- package/dist/schema/widgets/post-purchase-offer/postPurchaseWidget.d.ts +9 -9
- package/dist/server/index.cjs +10 -8
- package/dist/server/index.mjs +10 -8
- package/dist/transforms/index.cjs +12 -9
- package/dist/transforms/index.mjs +12 -9
- package/dist/transforms/offerV1/offerTemplateSeed.d.ts +1 -0
- package/dist/transforms/offerV1/types.d.ts +12 -2
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -90,6 +90,7 @@ __export(src_exports, {
|
|
|
90
90
|
Identity: () => Identity,
|
|
91
91
|
ImageBlock: () => ImageBlock,
|
|
92
92
|
ImageContentBlock: () => ImageContentBlock,
|
|
93
|
+
InlineTextSizeName: () => InlineTextSizeName,
|
|
93
94
|
LanguageKey: () => LanguageKey,
|
|
94
95
|
LineItemEditor: () => LineItemEditor,
|
|
95
96
|
LineItemEditorSwitchLanguageV1: () => LineItemEditorSwitchLanguageV1,
|
|
@@ -190,6 +191,7 @@ __export(src_exports, {
|
|
|
190
191
|
iconNames: () => iconNames,
|
|
191
192
|
iconSizes: () => iconSizes,
|
|
192
193
|
iconTones: () => iconTones,
|
|
194
|
+
inlineTextSizeNames: () => inlineTextSizeNames,
|
|
193
195
|
isBannerType: () => isBannerType,
|
|
194
196
|
isBase64Encoded: () => isBase64Encoded,
|
|
195
197
|
isButtonType: () => isButtonType,
|
|
@@ -1670,7 +1672,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
1670
1672
|
var TextAlignment = freezeEnum(textAlignments);
|
|
1671
1673
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
1672
1674
|
var TextColorName = freezeEnum(textColorNames);
|
|
1673
|
-
var
|
|
1675
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
1676
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
1677
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
1674
1678
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
1675
1679
|
var variantModes = ["multiple", "single"];
|
|
1676
1680
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -2919,7 +2923,8 @@ var ContentBlockV1 = import_zod30.z.object({
|
|
|
2919
2923
|
imageSize: import_zod30.z.number(),
|
|
2920
2924
|
imageUrl: import_zod30.z.url(),
|
|
2921
2925
|
textAlignment: import_zod30.z.enum(["left", "center", "right"]),
|
|
2922
|
-
|
|
2926
|
+
/** Inline scale only: an image caption can never be a block-level heading. */
|
|
2927
|
+
textSize: import_zod30.z.enum(inlineTextSizeNames)
|
|
2923
2928
|
})
|
|
2924
2929
|
),
|
|
2925
2930
|
import_zod30.z.strictObject({}).transform(() => [])
|
|
@@ -4053,7 +4058,8 @@ var OFFER_TEMPLATE_SEED = {
|
|
|
4053
4058
|
{
|
|
4054
4059
|
attrs: {
|
|
4055
4060
|
color: "base",
|
|
4056
|
-
|
|
4061
|
+
/** Block-level heading: new widgets get navigable card titles by default (WCAG 1.3.1). */
|
|
4062
|
+
fontSize: "heading"
|
|
4057
4063
|
},
|
|
4058
4064
|
type: "textStyle"
|
|
4059
4065
|
},
|
|
@@ -4280,10 +4286,8 @@ var ADD_LABEL_TOKENS = ["quantity", "price", "total"];
|
|
|
4280
4286
|
var SWITCH_LABEL_TOKENS = ["subscriptionDiscount", "frequency", "interval"];
|
|
4281
4287
|
var QUANTITY_ERROR_TOKENS = ["max", "min", "step"];
|
|
4282
4288
|
var VARIANT_SELECTOR = { button: "button", radio: "radio", select: "menu" };
|
|
4283
|
-
var buildStyledText = (token, style,
|
|
4284
|
-
const marks = [
|
|
4285
|
-
{ attrs: { color, fontSize: style?.textSize ?? "base" }, type: "textStyle" }
|
|
4286
|
-
];
|
|
4289
|
+
var buildStyledText = (token, style, fontSize = style?.textSize ?? "base") => {
|
|
4290
|
+
const marks = [{ attrs: { color: "base", fontSize }, type: "textStyle" }];
|
|
4287
4291
|
if (style?.textEmphasis === "bold") marks.push({ type: "bold" });
|
|
4288
4292
|
if (style?.textEmphasis === "italic") marks.push({ type: "italic" });
|
|
4289
4293
|
return { content: [{ content: [{ marks, text: token, type: "text" }], type: "paragraph" }], type: "doc" };
|
|
@@ -4323,8 +4327,8 @@ var buildImage = (settings) => {
|
|
|
4323
4327
|
const image = settings.displaySettings?.image;
|
|
4324
4328
|
return {
|
|
4325
4329
|
...image?.imageFit && { objectFit: image.imageFit },
|
|
4326
|
-
/**
|
|
4327
|
-
altText: "
|
|
4330
|
+
/** Decorative on purpose: the card's title heading already names the product, so alt text would only duplicate it for screen readers (legacy checkout-offers dropped its variantTitle alt for the same reason). */
|
|
4331
|
+
altText: "",
|
|
4328
4332
|
aspectRatio: 1,
|
|
4329
4333
|
border: {
|
|
4330
4334
|
radius: borderToken(borderRadii, image?.borderRadius),
|
|
@@ -4344,7 +4348,9 @@ var gridCardImage = (image) => ({
|
|
|
4344
4348
|
sectionType: "layout"
|
|
4345
4349
|
});
|
|
4346
4350
|
var buildTitle = (settings) => ({
|
|
4347
|
-
content: {
|
|
4351
|
+
content: {
|
|
4352
|
+
en: buildStyledText("{{productTitle}}", settings.displaySettings?.product, "heading")
|
|
4353
|
+
},
|
|
4348
4354
|
sectionType: "text"
|
|
4349
4355
|
});
|
|
4350
4356
|
var buildPrice = (settings) => ({
|
package/dist/index.mjs
CHANGED
|
@@ -1410,7 +1410,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
1410
1410
|
var TextAlignment = freezeEnum(textAlignments);
|
|
1411
1411
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
1412
1412
|
var TextColorName = freezeEnum(textColorNames);
|
|
1413
|
-
var
|
|
1413
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
1414
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
1415
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
1414
1416
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
1415
1417
|
var variantModes = ["multiple", "single"];
|
|
1416
1418
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -2659,7 +2661,8 @@ var ContentBlockV1 = z30.object({
|
|
|
2659
2661
|
imageSize: z30.number(),
|
|
2660
2662
|
imageUrl: z30.url(),
|
|
2661
2663
|
textAlignment: z30.enum(["left", "center", "right"]),
|
|
2662
|
-
|
|
2664
|
+
/** Inline scale only: an image caption can never be a block-level heading. */
|
|
2665
|
+
textSize: z30.enum(inlineTextSizeNames)
|
|
2663
2666
|
})
|
|
2664
2667
|
),
|
|
2665
2668
|
z30.strictObject({}).transform(() => [])
|
|
@@ -3793,7 +3796,8 @@ var OFFER_TEMPLATE_SEED = {
|
|
|
3793
3796
|
{
|
|
3794
3797
|
attrs: {
|
|
3795
3798
|
color: "base",
|
|
3796
|
-
|
|
3799
|
+
/** Block-level heading: new widgets get navigable card titles by default (WCAG 1.3.1). */
|
|
3800
|
+
fontSize: "heading"
|
|
3797
3801
|
},
|
|
3798
3802
|
type: "textStyle"
|
|
3799
3803
|
},
|
|
@@ -4020,10 +4024,8 @@ var ADD_LABEL_TOKENS = ["quantity", "price", "total"];
|
|
|
4020
4024
|
var SWITCH_LABEL_TOKENS = ["subscriptionDiscount", "frequency", "interval"];
|
|
4021
4025
|
var QUANTITY_ERROR_TOKENS = ["max", "min", "step"];
|
|
4022
4026
|
var VARIANT_SELECTOR = { button: "button", radio: "radio", select: "menu" };
|
|
4023
|
-
var buildStyledText = (token, style,
|
|
4024
|
-
const marks = [
|
|
4025
|
-
{ attrs: { color, fontSize: style?.textSize ?? "base" }, type: "textStyle" }
|
|
4026
|
-
];
|
|
4027
|
+
var buildStyledText = (token, style, fontSize = style?.textSize ?? "base") => {
|
|
4028
|
+
const marks = [{ attrs: { color: "base", fontSize }, type: "textStyle" }];
|
|
4027
4029
|
if (style?.textEmphasis === "bold") marks.push({ type: "bold" });
|
|
4028
4030
|
if (style?.textEmphasis === "italic") marks.push({ type: "italic" });
|
|
4029
4031
|
return { content: [{ content: [{ marks, text: token, type: "text" }], type: "paragraph" }], type: "doc" };
|
|
@@ -4063,8 +4065,8 @@ var buildImage = (settings) => {
|
|
|
4063
4065
|
const image = settings.displaySettings?.image;
|
|
4064
4066
|
return {
|
|
4065
4067
|
...image?.imageFit && { objectFit: image.imageFit },
|
|
4066
|
-
/**
|
|
4067
|
-
altText: "
|
|
4068
|
+
/** Decorative on purpose: the card's title heading already names the product, so alt text would only duplicate it for screen readers (legacy checkout-offers dropped its variantTitle alt for the same reason). */
|
|
4069
|
+
altText: "",
|
|
4068
4070
|
aspectRatio: 1,
|
|
4069
4071
|
border: {
|
|
4070
4072
|
radius: borderToken(borderRadii, image?.borderRadius),
|
|
@@ -4084,7 +4086,9 @@ var gridCardImage = (image) => ({
|
|
|
4084
4086
|
sectionType: "layout"
|
|
4085
4087
|
});
|
|
4086
4088
|
var buildTitle = (settings) => ({
|
|
4087
|
-
content: {
|
|
4089
|
+
content: {
|
|
4090
|
+
en: buildStyledText("{{productTitle}}", settings.displaySettings?.product, "heading")
|
|
4091
|
+
},
|
|
4088
4092
|
sectionType: "text"
|
|
4089
4093
|
});
|
|
4090
4094
|
var buildPrice = (settings) => ({
|
|
@@ -4483,6 +4487,7 @@ export {
|
|
|
4483
4487
|
Identity,
|
|
4484
4488
|
ImageBlock,
|
|
4485
4489
|
ImageContentBlock,
|
|
4490
|
+
InlineTextSizeName,
|
|
4486
4491
|
LanguageKey,
|
|
4487
4492
|
LineItemEditor,
|
|
4488
4493
|
LineItemEditorSwitchLanguageV1,
|
|
@@ -4583,6 +4588,7 @@ export {
|
|
|
4583
4588
|
iconNames,
|
|
4584
4589
|
iconSizes,
|
|
4585
4590
|
iconTones,
|
|
4591
|
+
inlineTextSizeNames,
|
|
4586
4592
|
isBannerType,
|
|
4587
4593
|
isBase64Encoded,
|
|
4588
4594
|
isButtonType,
|
|
@@ -32,6 +32,7 @@ __export(common_exports, {
|
|
|
32
32
|
DiscountType: () => DiscountType,
|
|
33
33
|
EditorMode: () => EditorMode,
|
|
34
34
|
HorizontalAlignment: () => HorizontalAlignment,
|
|
35
|
+
InlineTextSizeName: () => InlineTextSizeName,
|
|
35
36
|
LanguageKey: () => LanguageKey,
|
|
36
37
|
ObjectFit: () => ObjectFit,
|
|
37
38
|
OffersDirection: () => OffersDirection,
|
|
@@ -62,6 +63,7 @@ __export(common_exports, {
|
|
|
62
63
|
editorModes: () => editorModes,
|
|
63
64
|
freezeEnum: () => freezeEnum,
|
|
64
65
|
horizontalAlignments: () => horizontalAlignments,
|
|
66
|
+
inlineTextSizeNames: () => inlineTextSizeNames,
|
|
65
67
|
languageKeys: () => languageKeys,
|
|
66
68
|
objectFits: () => objectFits,
|
|
67
69
|
offersDirections: () => offersDirections,
|
|
@@ -232,7 +234,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
232
234
|
var TextAlignment = freezeEnum(textAlignments);
|
|
233
235
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
234
236
|
var TextColorName = freezeEnum(textColorNames);
|
|
235
|
-
var
|
|
237
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
238
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
239
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
236
240
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
237
241
|
var variantModes = ["multiple", "single"];
|
|
238
242
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -149,7 +149,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
149
149
|
var TextAlignment = freezeEnum(textAlignments);
|
|
150
150
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
151
151
|
var TextColorName = freezeEnum(textColorNames);
|
|
152
|
-
var
|
|
152
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
153
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
154
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
153
155
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
154
156
|
var variantModes = ["multiple", "single"];
|
|
155
157
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -170,6 +172,7 @@ export {
|
|
|
170
172
|
DiscountType,
|
|
171
173
|
EditorMode,
|
|
172
174
|
HorizontalAlignment,
|
|
175
|
+
InlineTextSizeName,
|
|
173
176
|
LanguageKey,
|
|
174
177
|
ObjectFit,
|
|
175
178
|
OffersDirection,
|
|
@@ -200,6 +203,7 @@ export {
|
|
|
200
203
|
editorModes,
|
|
201
204
|
freezeEnum,
|
|
202
205
|
horizontalAlignments,
|
|
206
|
+
inlineTextSizeNames,
|
|
203
207
|
languageKeys,
|
|
204
208
|
objectFits,
|
|
205
209
|
offersDirections,
|
|
@@ -74,6 +74,7 @@ __export(checkout_and_beyond_exports, {
|
|
|
74
74
|
IconName: () => IconName,
|
|
75
75
|
IconSize: () => IconSize,
|
|
76
76
|
IconTone: () => IconTone,
|
|
77
|
+
InlineTextSizeName: () => InlineTextSizeName,
|
|
77
78
|
LanguageKey: () => LanguageKey,
|
|
78
79
|
NO_HTML: () => NO_HTML,
|
|
79
80
|
OFFER_LABELS: () => OFFER_LABELS,
|
|
@@ -125,6 +126,7 @@ __export(checkout_and_beyond_exports, {
|
|
|
125
126
|
iconNames: () => iconNames,
|
|
126
127
|
iconSizes: () => iconSizes,
|
|
127
128
|
iconTones: () => iconTones,
|
|
129
|
+
inlineTextSizeNames: () => inlineTextSizeNames,
|
|
128
130
|
isBannerType: () => isBannerType,
|
|
129
131
|
isButtonType: () => isButtonType,
|
|
130
132
|
isCarouselType: () => isCarouselType,
|
|
@@ -323,7 +325,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
323
325
|
var TextAlignment = freezeEnum(textAlignments);
|
|
324
326
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
325
327
|
var TextColorName = freezeEnum(textColorNames);
|
|
326
|
-
var
|
|
328
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
329
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
330
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
327
331
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
328
332
|
var variantModes = ["multiple", "single"];
|
|
329
333
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -152,7 +152,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
152
152
|
var TextAlignment = freezeEnum(textAlignments);
|
|
153
153
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
154
154
|
var TextColorName = freezeEnum(textColorNames);
|
|
155
|
-
var
|
|
155
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
156
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
157
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
156
158
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
157
159
|
var variantModes = ["multiple", "single"];
|
|
158
160
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -1749,6 +1751,7 @@ export {
|
|
|
1749
1751
|
IconName,
|
|
1750
1752
|
IconSize,
|
|
1751
1753
|
IconTone,
|
|
1754
|
+
InlineTextSizeName,
|
|
1752
1755
|
LanguageKey,
|
|
1753
1756
|
NO_HTML,
|
|
1754
1757
|
OFFER_LABELS,
|
|
@@ -1800,6 +1803,7 @@ export {
|
|
|
1800
1803
|
iconNames,
|
|
1801
1804
|
iconSizes,
|
|
1802
1805
|
iconTones,
|
|
1806
|
+
inlineTextSizeNames,
|
|
1803
1807
|
isBannerType,
|
|
1804
1808
|
isButtonType,
|
|
1805
1809
|
isCarouselType,
|
|
@@ -180,7 +180,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
180
180
|
var TextAlignment = freezeEnum(textAlignments);
|
|
181
181
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
182
182
|
var TextColorName = freezeEnum(textColorNames);
|
|
183
|
-
var
|
|
183
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
184
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
185
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
184
186
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
185
187
|
var variantModes = ["multiple", "single"];
|
|
186
188
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -1401,7 +1403,8 @@ var ContentBlockV1 = import_zod23.z.object({
|
|
|
1401
1403
|
imageSize: import_zod23.z.number(),
|
|
1402
1404
|
imageUrl: import_zod23.z.url(),
|
|
1403
1405
|
textAlignment: import_zod23.z.enum(["left", "center", "right"]),
|
|
1404
|
-
|
|
1406
|
+
/** Inline scale only: an image caption can never be a block-level heading. */
|
|
1407
|
+
textSize: import_zod23.z.enum(inlineTextSizeNames)
|
|
1405
1408
|
})
|
|
1406
1409
|
),
|
|
1407
1410
|
import_zod23.z.strictObject({}).transform(() => [])
|
|
@@ -155,7 +155,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
155
155
|
var TextAlignment = freezeEnum(textAlignments);
|
|
156
156
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
157
157
|
var TextColorName = freezeEnum(textColorNames);
|
|
158
|
-
var
|
|
158
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
159
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
160
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
159
161
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
160
162
|
var variantModes = ["multiple", "single"];
|
|
161
163
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -1376,7 +1378,8 @@ var ContentBlockV1 = z23.object({
|
|
|
1376
1378
|
imageSize: z23.number(),
|
|
1377
1379
|
imageUrl: z23.url(),
|
|
1378
1380
|
textAlignment: z23.enum(["left", "center", "right"]),
|
|
1379
|
-
|
|
1381
|
+
/** Inline scale only: an image caption can never be a block-level heading. */
|
|
1382
|
+
textSize: z23.enum(inlineTextSizeNames)
|
|
1380
1383
|
})
|
|
1381
1384
|
),
|
|
1382
1385
|
z23.strictObject({}).transform(() => [])
|
|
@@ -268,7 +268,24 @@ export declare const TextColorName: {
|
|
|
268
268
|
readonly accent: "accent";
|
|
269
269
|
};
|
|
270
270
|
export type TextColorName = (typeof textColorNames)[number];
|
|
271
|
-
|
|
271
|
+
/** The inline font-size scale — the only sizes admin size pickers and inline text styling may offer. */
|
|
272
|
+
export declare const inlineTextSizeNames: readonly ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
273
|
+
export declare const InlineTextSizeName: {
|
|
274
|
+
readonly small: "small";
|
|
275
|
+
readonly base: "base";
|
|
276
|
+
readonly large: "large";
|
|
277
|
+
readonly medium: "medium";
|
|
278
|
+
readonly extraSmall: "extraSmall";
|
|
279
|
+
readonly extraLarge: "extraLarge";
|
|
280
|
+
};
|
|
281
|
+
export type InlineTextSizeName = (typeof inlineTextSizeNames)[number];
|
|
282
|
+
/**
|
|
283
|
+
* The parse superset for text marks. `heading` is not a point on the inline size scale: it marks its
|
|
284
|
+
* paragraph as a block-level heading (the CAB renderer emits `s-heading` instead of `s-paragraph`),
|
|
285
|
+
* so renderers must treat it as a block signal, never as an inline font size. Inline-only consumers
|
|
286
|
+
* (size pickers, content-block captions) use `inlineTextSizeNames`, which cannot express it.
|
|
287
|
+
*/
|
|
288
|
+
export declare const textSizeNames: readonly ["extraSmall", "small", "base", "medium", "large", "extraLarge", "heading"];
|
|
272
289
|
export declare const TextSizeName: {
|
|
273
290
|
readonly small: "small";
|
|
274
291
|
readonly base: "base";
|
|
@@ -276,6 +293,7 @@ export declare const TextSizeName: {
|
|
|
276
293
|
readonly medium: "medium";
|
|
277
294
|
readonly extraSmall: "extraSmall";
|
|
278
295
|
readonly extraLarge: "extraLarge";
|
|
296
|
+
readonly heading: "heading";
|
|
279
297
|
};
|
|
280
298
|
export type TextSizeName = (typeof textSizeNames)[number];
|
|
281
299
|
export declare const variantModes: readonly ["multiple", "single"];
|
|
@@ -18,7 +18,7 @@ export declare const TiptapText: z.ZodObject<{
|
|
|
18
18
|
}, z.core.$strip>, z.ZodObject<{
|
|
19
19
|
attrs: z.ZodObject<{
|
|
20
20
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
21
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
21
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
22
22
|
}, z.core.$strip>;
|
|
23
23
|
type: z.ZodLiteral<"textStyle">;
|
|
24
24
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -48,7 +48,7 @@ export declare const TiptapParagraph: z.ZodObject<{
|
|
|
48
48
|
}, z.core.$strip>, z.ZodObject<{
|
|
49
49
|
attrs: z.ZodObject<{
|
|
50
50
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
51
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
51
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
52
52
|
}, z.core.$strip>;
|
|
53
53
|
type: z.ZodLiteral<"textStyle">;
|
|
54
54
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -84,7 +84,7 @@ export declare const TiptapDocument: z.ZodObject<{
|
|
|
84
84
|
}, z.core.$strip>, z.ZodObject<{
|
|
85
85
|
attrs: z.ZodObject<{
|
|
86
86
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
87
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
87
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
88
88
|
}, z.core.$strip>;
|
|
89
89
|
type: z.ZodLiteral<"textStyle">;
|
|
90
90
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -165,7 +165,7 @@ export declare const CABTextSection: z.ZodObject<{
|
|
|
165
165
|
}, z.core.$strip>, z.ZodObject<{
|
|
166
166
|
attrs: z.ZodObject<{
|
|
167
167
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
168
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
168
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
169
169
|
}, z.core.$strip>;
|
|
170
170
|
type: z.ZodLiteral<"textStyle">;
|
|
171
171
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -29,7 +29,7 @@ export declare const CalloutBannerBlock: z.ZodObject<{
|
|
|
29
29
|
}, z.core.$strip>, z.ZodObject<{
|
|
30
30
|
attrs: z.ZodObject<{
|
|
31
31
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
32
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
32
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
33
33
|
}, z.core.$strip>;
|
|
34
34
|
type: z.ZodLiteral<"textStyle">;
|
|
35
35
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -66,7 +66,7 @@ export declare const CalloutBannerBlock: z.ZodObject<{
|
|
|
66
66
|
}, z.core.$strip>, z.ZodObject<{
|
|
67
67
|
attrs: z.ZodObject<{
|
|
68
68
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
69
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
69
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
70
70
|
}, z.core.$strip>;
|
|
71
71
|
type: z.ZodLiteral<"textStyle">;
|
|
72
72
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -154,7 +154,7 @@ export declare const ImageContentBlock: z.ZodObject<{
|
|
|
154
154
|
}, z.core.$strip>, z.ZodObject<{
|
|
155
155
|
attrs: z.ZodObject<{
|
|
156
156
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
157
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
157
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
158
158
|
}, z.core.$strip>;
|
|
159
159
|
type: z.ZodLiteral<"textStyle">;
|
|
160
160
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -213,7 +213,7 @@ export declare const ImageContentBlock: z.ZodObject<{
|
|
|
213
213
|
}, z.core.$strip>, z.ZodObject<{
|
|
214
214
|
attrs: z.ZodObject<{
|
|
215
215
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
216
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
216
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
217
217
|
}, z.core.$strip>;
|
|
218
218
|
type: z.ZodLiteral<"textStyle">;
|
|
219
219
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -260,7 +260,7 @@ export declare const ImageContentBlock: z.ZodObject<{
|
|
|
260
260
|
}, z.core.$strip>, z.ZodObject<{
|
|
261
261
|
attrs: z.ZodObject<{
|
|
262
262
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
263
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
263
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
264
264
|
}, z.core.$strip>;
|
|
265
265
|
type: z.ZodLiteral<"textStyle">;
|
|
266
266
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -343,7 +343,7 @@ export declare const TextBlock: z.ZodObject<{
|
|
|
343
343
|
}, z.core.$strip>, z.ZodObject<{
|
|
344
344
|
attrs: z.ZodObject<{
|
|
345
345
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
346
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
346
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
347
347
|
}, z.core.$strip>;
|
|
348
348
|
type: z.ZodLiteral<"textStyle">;
|
|
349
349
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -394,7 +394,7 @@ export declare const TextBlock: z.ZodObject<{
|
|
|
394
394
|
}, z.core.$strip>, z.ZodObject<{
|
|
395
395
|
attrs: z.ZodObject<{
|
|
396
396
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
397
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
397
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
398
398
|
}, z.core.$strip>;
|
|
399
399
|
type: z.ZodLiteral<"textStyle">;
|
|
400
400
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -440,7 +440,7 @@ export declare const TextBlock: z.ZodObject<{
|
|
|
440
440
|
}, z.core.$strip>, z.ZodObject<{
|
|
441
441
|
attrs: z.ZodObject<{
|
|
442
442
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
443
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
443
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
444
444
|
}, z.core.$strip>;
|
|
445
445
|
type: z.ZodLiteral<"textStyle">;
|
|
446
446
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -497,7 +497,7 @@ export declare const TimerBlock: z.ZodObject<{
|
|
|
497
497
|
}, z.core.$strip>, z.ZodObject<{
|
|
498
498
|
attrs: z.ZodObject<{
|
|
499
499
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
500
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
500
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
501
501
|
}, z.core.$strip>;
|
|
502
502
|
type: z.ZodLiteral<"textStyle">;
|
|
503
503
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -576,7 +576,7 @@ export declare const PostPurchaseBlock: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
576
576
|
}, z.core.$strip>, z.ZodObject<{
|
|
577
577
|
attrs: z.ZodObject<{
|
|
578
578
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
579
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
579
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
580
580
|
}, z.core.$strip>;
|
|
581
581
|
type: z.ZodLiteral<"textStyle">;
|
|
582
582
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -613,7 +613,7 @@ export declare const PostPurchaseBlock: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
613
613
|
}, z.core.$strip>, z.ZodObject<{
|
|
614
614
|
attrs: z.ZodObject<{
|
|
615
615
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
616
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
616
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
617
617
|
}, z.core.$strip>;
|
|
618
618
|
type: z.ZodLiteral<"textStyle">;
|
|
619
619
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -697,7 +697,7 @@ export declare const PostPurchaseBlock: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
697
697
|
}, z.core.$strip>, z.ZodObject<{
|
|
698
698
|
attrs: z.ZodObject<{
|
|
699
699
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
700
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
700
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
701
701
|
}, z.core.$strip>;
|
|
702
702
|
type: z.ZodLiteral<"textStyle">;
|
|
703
703
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -756,7 +756,7 @@ export declare const PostPurchaseBlock: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
756
756
|
}, z.core.$strip>, z.ZodObject<{
|
|
757
757
|
attrs: z.ZodObject<{
|
|
758
758
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
759
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
759
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
760
760
|
}, z.core.$strip>;
|
|
761
761
|
type: z.ZodLiteral<"textStyle">;
|
|
762
762
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -803,7 +803,7 @@ export declare const PostPurchaseBlock: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
803
803
|
}, z.core.$strip>, z.ZodObject<{
|
|
804
804
|
attrs: z.ZodObject<{
|
|
805
805
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
806
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
806
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
807
807
|
}, z.core.$strip>;
|
|
808
808
|
type: z.ZodLiteral<"textStyle">;
|
|
809
809
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -878,7 +878,7 @@ export declare const PostPurchaseBlock: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
878
878
|
}, z.core.$strip>, z.ZodObject<{
|
|
879
879
|
attrs: z.ZodObject<{
|
|
880
880
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
881
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
881
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
882
882
|
}, z.core.$strip>;
|
|
883
883
|
type: z.ZodLiteral<"textStyle">;
|
|
884
884
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -929,7 +929,7 @@ export declare const PostPurchaseBlock: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
929
929
|
}, z.core.$strip>, z.ZodObject<{
|
|
930
930
|
attrs: z.ZodObject<{
|
|
931
931
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
932
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
932
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
933
933
|
}, z.core.$strip>;
|
|
934
934
|
type: z.ZodLiteral<"textStyle">;
|
|
935
935
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -975,7 +975,7 @@ export declare const PostPurchaseBlock: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
975
975
|
}, z.core.$strip>, z.ZodObject<{
|
|
976
976
|
attrs: z.ZodObject<{
|
|
977
977
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
978
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
978
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
979
979
|
}, z.core.$strip>;
|
|
980
980
|
type: z.ZodLiteral<"textStyle">;
|
|
981
981
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -1030,7 +1030,7 @@ export declare const PostPurchaseBlock: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
1030
1030
|
}, z.core.$strip>, z.ZodObject<{
|
|
1031
1031
|
attrs: z.ZodObject<{
|
|
1032
1032
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
1033
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
1033
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
1034
1034
|
}, z.core.$strip>;
|
|
1035
1035
|
type: z.ZodLiteral<"textStyle">;
|
|
1036
1036
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -54,7 +54,7 @@ export declare const PostPurchaseOffer: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
54
54
|
}, z.core.$strip>, z.ZodObject<{
|
|
55
55
|
attrs: z.ZodObject<{
|
|
56
56
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
57
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
57
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
58
58
|
}, z.core.$strip>;
|
|
59
59
|
type: z.ZodLiteral<"textStyle">;
|
|
60
60
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -91,7 +91,7 @@ export declare const PostPurchaseOffer: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
91
91
|
}, z.core.$strip>, z.ZodObject<{
|
|
92
92
|
attrs: z.ZodObject<{
|
|
93
93
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
94
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
94
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
95
95
|
}, z.core.$strip>;
|
|
96
96
|
type: z.ZodLiteral<"textStyle">;
|
|
97
97
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -175,7 +175,7 @@ export declare const PostPurchaseOffer: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
175
175
|
}, z.core.$strip>, z.ZodObject<{
|
|
176
176
|
attrs: z.ZodObject<{
|
|
177
177
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
178
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
178
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
179
179
|
}, z.core.$strip>;
|
|
180
180
|
type: z.ZodLiteral<"textStyle">;
|
|
181
181
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -234,7 +234,7 @@ export declare const PostPurchaseOffer: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
234
234
|
}, z.core.$strip>, z.ZodObject<{
|
|
235
235
|
attrs: z.ZodObject<{
|
|
236
236
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
237
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
237
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
238
238
|
}, z.core.$strip>;
|
|
239
239
|
type: z.ZodLiteral<"textStyle">;
|
|
240
240
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -281,7 +281,7 @@ export declare const PostPurchaseOffer: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
281
281
|
}, z.core.$strip>, z.ZodObject<{
|
|
282
282
|
attrs: z.ZodObject<{
|
|
283
283
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
284
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
284
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
285
285
|
}, z.core.$strip>;
|
|
286
286
|
type: z.ZodLiteral<"textStyle">;
|
|
287
287
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -356,7 +356,7 @@ export declare const PostPurchaseOffer: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
356
356
|
}, z.core.$strip>, z.ZodObject<{
|
|
357
357
|
attrs: z.ZodObject<{
|
|
358
358
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
359
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
359
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
360
360
|
}, z.core.$strip>;
|
|
361
361
|
type: z.ZodLiteral<"textStyle">;
|
|
362
362
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -407,7 +407,7 @@ export declare const PostPurchaseOffer: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
407
407
|
}, z.core.$strip>, z.ZodObject<{
|
|
408
408
|
attrs: z.ZodObject<{
|
|
409
409
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
410
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
410
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
411
411
|
}, z.core.$strip>;
|
|
412
412
|
type: z.ZodLiteral<"textStyle">;
|
|
413
413
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -453,7 +453,7 @@ export declare const PostPurchaseOffer: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
453
453
|
}, z.core.$strip>, z.ZodObject<{
|
|
454
454
|
attrs: z.ZodObject<{
|
|
455
455
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
456
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
456
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
457
457
|
}, z.core.$strip>;
|
|
458
458
|
type: z.ZodLiteral<"textStyle">;
|
|
459
459
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -508,7 +508,7 @@ export declare const PostPurchaseOffer: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
508
508
|
}, z.core.$strip>, z.ZodObject<{
|
|
509
509
|
attrs: z.ZodObject<{
|
|
510
510
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
511
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
511
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
512
512
|
}, z.core.$strip>;
|
|
513
513
|
type: z.ZodLiteral<"textStyle">;
|
|
514
514
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -33,7 +33,7 @@ export declare const PostPurchaseSettings: z.ZodObject<{
|
|
|
33
33
|
}, z.core.$strip>, z.ZodObject<{
|
|
34
34
|
attrs: z.ZodObject<{
|
|
35
35
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
36
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
36
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
37
37
|
}, z.core.$strip>;
|
|
38
38
|
type: z.ZodLiteral<"textStyle">;
|
|
39
39
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -70,7 +70,7 @@ export declare const PostPurchaseSettings: z.ZodObject<{
|
|
|
70
70
|
}, z.core.$strip>, z.ZodObject<{
|
|
71
71
|
attrs: z.ZodObject<{
|
|
72
72
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
73
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
73
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
74
74
|
}, z.core.$strip>;
|
|
75
75
|
type: z.ZodLiteral<"textStyle">;
|
|
76
76
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -154,7 +154,7 @@ export declare const PostPurchaseSettings: z.ZodObject<{
|
|
|
154
154
|
}, z.core.$strip>, z.ZodObject<{
|
|
155
155
|
attrs: z.ZodObject<{
|
|
156
156
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
157
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
157
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
158
158
|
}, z.core.$strip>;
|
|
159
159
|
type: z.ZodLiteral<"textStyle">;
|
|
160
160
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -213,7 +213,7 @@ export declare const PostPurchaseSettings: z.ZodObject<{
|
|
|
213
213
|
}, z.core.$strip>, z.ZodObject<{
|
|
214
214
|
attrs: z.ZodObject<{
|
|
215
215
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
216
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
216
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
217
217
|
}, z.core.$strip>;
|
|
218
218
|
type: z.ZodLiteral<"textStyle">;
|
|
219
219
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -260,7 +260,7 @@ export declare const PostPurchaseSettings: z.ZodObject<{
|
|
|
260
260
|
}, z.core.$strip>, z.ZodObject<{
|
|
261
261
|
attrs: z.ZodObject<{
|
|
262
262
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
263
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
263
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
264
264
|
}, z.core.$strip>;
|
|
265
265
|
type: z.ZodLiteral<"textStyle">;
|
|
266
266
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -335,7 +335,7 @@ export declare const PostPurchaseSettings: z.ZodObject<{
|
|
|
335
335
|
}, z.core.$strip>, z.ZodObject<{
|
|
336
336
|
attrs: z.ZodObject<{
|
|
337
337
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
338
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
338
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
339
339
|
}, z.core.$strip>;
|
|
340
340
|
type: z.ZodLiteral<"textStyle">;
|
|
341
341
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -386,7 +386,7 @@ export declare const PostPurchaseSettings: z.ZodObject<{
|
|
|
386
386
|
}, z.core.$strip>, z.ZodObject<{
|
|
387
387
|
attrs: z.ZodObject<{
|
|
388
388
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
389
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
389
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
390
390
|
}, z.core.$strip>;
|
|
391
391
|
type: z.ZodLiteral<"textStyle">;
|
|
392
392
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -432,7 +432,7 @@ export declare const PostPurchaseSettings: z.ZodObject<{
|
|
|
432
432
|
}, z.core.$strip>, z.ZodObject<{
|
|
433
433
|
attrs: z.ZodObject<{
|
|
434
434
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
435
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
435
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
436
436
|
}, z.core.$strip>;
|
|
437
437
|
type: z.ZodLiteral<"textStyle">;
|
|
438
438
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -487,7 +487,7 @@ export declare const PostPurchaseSettings: z.ZodObject<{
|
|
|
487
487
|
}, z.core.$strip>, z.ZodObject<{
|
|
488
488
|
attrs: z.ZodObject<{
|
|
489
489
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
490
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
490
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
491
491
|
}, z.core.$strip>;
|
|
492
492
|
type: z.ZodLiteral<"textStyle">;
|
|
493
493
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -51,7 +51,7 @@ export declare const PostPurchaseWidget: z.ZodObject<{
|
|
|
51
51
|
}, z.core.$strip>, z.ZodObject<{
|
|
52
52
|
attrs: z.ZodObject<{
|
|
53
53
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
54
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
54
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
55
55
|
}, z.core.$strip>;
|
|
56
56
|
type: z.ZodLiteral<"textStyle">;
|
|
57
57
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -88,7 +88,7 @@ export declare const PostPurchaseWidget: z.ZodObject<{
|
|
|
88
88
|
}, z.core.$strip>, z.ZodObject<{
|
|
89
89
|
attrs: z.ZodObject<{
|
|
90
90
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
91
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
91
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
92
92
|
}, z.core.$strip>;
|
|
93
93
|
type: z.ZodLiteral<"textStyle">;
|
|
94
94
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -172,7 +172,7 @@ export declare const PostPurchaseWidget: z.ZodObject<{
|
|
|
172
172
|
}, z.core.$strip>, z.ZodObject<{
|
|
173
173
|
attrs: z.ZodObject<{
|
|
174
174
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
175
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
175
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
176
176
|
}, z.core.$strip>;
|
|
177
177
|
type: z.ZodLiteral<"textStyle">;
|
|
178
178
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -231,7 +231,7 @@ export declare const PostPurchaseWidget: z.ZodObject<{
|
|
|
231
231
|
}, z.core.$strip>, z.ZodObject<{
|
|
232
232
|
attrs: z.ZodObject<{
|
|
233
233
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
234
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
234
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
235
235
|
}, z.core.$strip>;
|
|
236
236
|
type: z.ZodLiteral<"textStyle">;
|
|
237
237
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -278,7 +278,7 @@ export declare const PostPurchaseWidget: z.ZodObject<{
|
|
|
278
278
|
}, z.core.$strip>, z.ZodObject<{
|
|
279
279
|
attrs: z.ZodObject<{
|
|
280
280
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
281
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
281
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
282
282
|
}, z.core.$strip>;
|
|
283
283
|
type: z.ZodLiteral<"textStyle">;
|
|
284
284
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -353,7 +353,7 @@ export declare const PostPurchaseWidget: z.ZodObject<{
|
|
|
353
353
|
}, z.core.$strip>, z.ZodObject<{
|
|
354
354
|
attrs: z.ZodObject<{
|
|
355
355
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
356
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
356
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
357
357
|
}, z.core.$strip>;
|
|
358
358
|
type: z.ZodLiteral<"textStyle">;
|
|
359
359
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -404,7 +404,7 @@ export declare const PostPurchaseWidget: z.ZodObject<{
|
|
|
404
404
|
}, z.core.$strip>, z.ZodObject<{
|
|
405
405
|
attrs: z.ZodObject<{
|
|
406
406
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
407
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
407
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
408
408
|
}, z.core.$strip>;
|
|
409
409
|
type: z.ZodLiteral<"textStyle">;
|
|
410
410
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -450,7 +450,7 @@ export declare const PostPurchaseWidget: z.ZodObject<{
|
|
|
450
450
|
}, z.core.$strip>, z.ZodObject<{
|
|
451
451
|
attrs: z.ZodObject<{
|
|
452
452
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
453
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
453
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
454
454
|
}, z.core.$strip>;
|
|
455
455
|
type: z.ZodLiteral<"textStyle">;
|
|
456
456
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
|
@@ -505,7 +505,7 @@ export declare const PostPurchaseWidget: z.ZodObject<{
|
|
|
505
505
|
}, z.core.$strip>, z.ZodObject<{
|
|
506
506
|
attrs: z.ZodObject<{
|
|
507
507
|
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"success" | "warning" | "critical" | "base" | "decorative" | "subdued" | "accent" | undefined, string>>>>;
|
|
508
|
-
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
508
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | "heading" | undefined, string>>>>;
|
|
509
509
|
}, z.core.$strip>;
|
|
510
510
|
type: z.ZodLiteral<"textStyle">;
|
|
511
511
|
}, z.core.$strip>], "type">>, z.ZodPipe<z.ZodObject<{}, z.core.$strict>, z.ZodTransform<never[], Record<string, never>>>]>>;
|
package/dist/server/index.cjs
CHANGED
|
@@ -704,7 +704,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
704
704
|
var TextAlignment = freezeEnum(textAlignments);
|
|
705
705
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
706
706
|
var TextColorName = freezeEnum(textColorNames);
|
|
707
|
-
var
|
|
707
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
708
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
709
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
708
710
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
709
711
|
var variantModes = ["multiple", "single"];
|
|
710
712
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -2831,10 +2833,8 @@ var ADD_LABEL_TOKENS = ["quantity", "price", "total"];
|
|
|
2831
2833
|
var SWITCH_LABEL_TOKENS2 = ["subscriptionDiscount", "frequency", "interval"];
|
|
2832
2834
|
var QUANTITY_ERROR_TOKENS = ["max", "min", "step"];
|
|
2833
2835
|
var VARIANT_SELECTOR = { button: "button", radio: "radio", select: "menu" };
|
|
2834
|
-
var buildStyledText = (token, style,
|
|
2835
|
-
const marks = [
|
|
2836
|
-
{ attrs: { color, fontSize: style?.textSize ?? "base" }, type: "textStyle" }
|
|
2837
|
-
];
|
|
2836
|
+
var buildStyledText = (token, style, fontSize = style?.textSize ?? "base") => {
|
|
2837
|
+
const marks = [{ attrs: { color: "base", fontSize }, type: "textStyle" }];
|
|
2838
2838
|
if (style?.textEmphasis === "bold") marks.push({ type: "bold" });
|
|
2839
2839
|
if (style?.textEmphasis === "italic") marks.push({ type: "italic" });
|
|
2840
2840
|
return { content: [{ content: [{ marks, text: token, type: "text" }], type: "paragraph" }], type: "doc" };
|
|
@@ -2874,8 +2874,8 @@ var buildImage = (settings) => {
|
|
|
2874
2874
|
const image = settings.displaySettings?.image;
|
|
2875
2875
|
return {
|
|
2876
2876
|
...image?.imageFit && { objectFit: image.imageFit },
|
|
2877
|
-
/**
|
|
2878
|
-
altText: "
|
|
2877
|
+
/** Decorative on purpose: the card's title heading already names the product, so alt text would only duplicate it for screen readers (legacy checkout-offers dropped its variantTitle alt for the same reason). */
|
|
2878
|
+
altText: "",
|
|
2879
2879
|
aspectRatio: 1,
|
|
2880
2880
|
border: {
|
|
2881
2881
|
radius: borderToken(borderRadii, image?.borderRadius),
|
|
@@ -2895,7 +2895,9 @@ var gridCardImage = (image) => ({
|
|
|
2895
2895
|
sectionType: "layout"
|
|
2896
2896
|
});
|
|
2897
2897
|
var buildTitle = (settings) => ({
|
|
2898
|
-
content: {
|
|
2898
|
+
content: {
|
|
2899
|
+
en: buildStyledText("{{productTitle}}", settings.displaySettings?.product, "heading")
|
|
2900
|
+
},
|
|
2899
2901
|
sectionType: "text"
|
|
2900
2902
|
});
|
|
2901
2903
|
var buildPrice = (settings) => ({
|
package/dist/server/index.mjs
CHANGED
|
@@ -656,7 +656,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
656
656
|
var TextAlignment = freezeEnum(textAlignments);
|
|
657
657
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
658
658
|
var TextColorName = freezeEnum(textColorNames);
|
|
659
|
-
var
|
|
659
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
660
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
661
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
660
662
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
661
663
|
var variantModes = ["multiple", "single"];
|
|
662
664
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -2783,10 +2785,8 @@ var ADD_LABEL_TOKENS = ["quantity", "price", "total"];
|
|
|
2783
2785
|
var SWITCH_LABEL_TOKENS2 = ["subscriptionDiscount", "frequency", "interval"];
|
|
2784
2786
|
var QUANTITY_ERROR_TOKENS = ["max", "min", "step"];
|
|
2785
2787
|
var VARIANT_SELECTOR = { button: "button", radio: "radio", select: "menu" };
|
|
2786
|
-
var buildStyledText = (token, style,
|
|
2787
|
-
const marks = [
|
|
2788
|
-
{ attrs: { color, fontSize: style?.textSize ?? "base" }, type: "textStyle" }
|
|
2789
|
-
];
|
|
2788
|
+
var buildStyledText = (token, style, fontSize = style?.textSize ?? "base") => {
|
|
2789
|
+
const marks = [{ attrs: { color: "base", fontSize }, type: "textStyle" }];
|
|
2790
2790
|
if (style?.textEmphasis === "bold") marks.push({ type: "bold" });
|
|
2791
2791
|
if (style?.textEmphasis === "italic") marks.push({ type: "italic" });
|
|
2792
2792
|
return { content: [{ content: [{ marks, text: token, type: "text" }], type: "paragraph" }], type: "doc" };
|
|
@@ -2826,8 +2826,8 @@ var buildImage = (settings) => {
|
|
|
2826
2826
|
const image = settings.displaySettings?.image;
|
|
2827
2827
|
return {
|
|
2828
2828
|
...image?.imageFit && { objectFit: image.imageFit },
|
|
2829
|
-
/**
|
|
2830
|
-
altText: "
|
|
2829
|
+
/** Decorative on purpose: the card's title heading already names the product, so alt text would only duplicate it for screen readers (legacy checkout-offers dropped its variantTitle alt for the same reason). */
|
|
2830
|
+
altText: "",
|
|
2831
2831
|
aspectRatio: 1,
|
|
2832
2832
|
border: {
|
|
2833
2833
|
radius: borderToken(borderRadii, image?.borderRadius),
|
|
@@ -2847,7 +2847,9 @@ var gridCardImage = (image) => ({
|
|
|
2847
2847
|
sectionType: "layout"
|
|
2848
2848
|
});
|
|
2849
2849
|
var buildTitle = (settings) => ({
|
|
2850
|
-
content: {
|
|
2850
|
+
content: {
|
|
2851
|
+
en: buildStyledText("{{productTitle}}", settings.displaySettings?.product, "heading")
|
|
2852
|
+
},
|
|
2851
2853
|
sectionType: "text"
|
|
2852
2854
|
});
|
|
2853
2855
|
var buildPrice = (settings) => ({
|
|
@@ -204,7 +204,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
204
204
|
var TextAlignment = freezeEnum(textAlignments);
|
|
205
205
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
206
206
|
var TextColorName = freezeEnum(textColorNames);
|
|
207
|
-
var
|
|
207
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
208
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
209
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
208
210
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
209
211
|
var variantModes = ["multiple", "single"];
|
|
210
212
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -2534,7 +2536,8 @@ var OFFER_TEMPLATE_SEED = {
|
|
|
2534
2536
|
{
|
|
2535
2537
|
attrs: {
|
|
2536
2538
|
color: "base",
|
|
2537
|
-
|
|
2539
|
+
/** Block-level heading: new widgets get navigable card titles by default (WCAG 1.3.1). */
|
|
2540
|
+
fontSize: "heading"
|
|
2538
2541
|
},
|
|
2539
2542
|
type: "textStyle"
|
|
2540
2543
|
},
|
|
@@ -2761,10 +2764,8 @@ var ADD_LABEL_TOKENS = ["quantity", "price", "total"];
|
|
|
2761
2764
|
var SWITCH_LABEL_TOKENS2 = ["subscriptionDiscount", "frequency", "interval"];
|
|
2762
2765
|
var QUANTITY_ERROR_TOKENS = ["max", "min", "step"];
|
|
2763
2766
|
var VARIANT_SELECTOR = { button: "button", radio: "radio", select: "menu" };
|
|
2764
|
-
var buildStyledText = (token, style,
|
|
2765
|
-
const marks = [
|
|
2766
|
-
{ attrs: { color, fontSize: style?.textSize ?? "base" }, type: "textStyle" }
|
|
2767
|
-
];
|
|
2767
|
+
var buildStyledText = (token, style, fontSize = style?.textSize ?? "base") => {
|
|
2768
|
+
const marks = [{ attrs: { color: "base", fontSize }, type: "textStyle" }];
|
|
2768
2769
|
if (style?.textEmphasis === "bold") marks.push({ type: "bold" });
|
|
2769
2770
|
if (style?.textEmphasis === "italic") marks.push({ type: "italic" });
|
|
2770
2771
|
return { content: [{ content: [{ marks, text: token, type: "text" }], type: "paragraph" }], type: "doc" };
|
|
@@ -2804,8 +2805,8 @@ var buildImage = (settings) => {
|
|
|
2804
2805
|
const image = settings.displaySettings?.image;
|
|
2805
2806
|
return {
|
|
2806
2807
|
...image?.imageFit && { objectFit: image.imageFit },
|
|
2807
|
-
/**
|
|
2808
|
-
altText: "
|
|
2808
|
+
/** Decorative on purpose: the card's title heading already names the product, so alt text would only duplicate it for screen readers (legacy checkout-offers dropped its variantTitle alt for the same reason). */
|
|
2809
|
+
altText: "",
|
|
2809
2810
|
aspectRatio: 1,
|
|
2810
2811
|
border: {
|
|
2811
2812
|
radius: borderToken(borderRadii, image?.borderRadius),
|
|
@@ -2825,7 +2826,9 @@ var gridCardImage = (image) => ({
|
|
|
2825
2826
|
sectionType: "layout"
|
|
2826
2827
|
});
|
|
2827
2828
|
var buildTitle = (settings) => ({
|
|
2828
|
-
content: {
|
|
2829
|
+
content: {
|
|
2830
|
+
en: buildStyledText("{{productTitle}}", settings.displaySettings?.product, "heading")
|
|
2831
|
+
},
|
|
2829
2832
|
sectionType: "text"
|
|
2830
2833
|
});
|
|
2831
2834
|
var buildPrice = (settings) => ({
|
|
@@ -147,7 +147,9 @@ var textAlignments = ["start", "center", "end"];
|
|
|
147
147
|
var TextAlignment = freezeEnum(textAlignments);
|
|
148
148
|
var textColorNames = ["base", "subdued", "accent", "decorative", "success", "warning", "critical"];
|
|
149
149
|
var TextColorName = freezeEnum(textColorNames);
|
|
150
|
-
var
|
|
150
|
+
var inlineTextSizeNames = ["extraSmall", "small", "base", "medium", "large", "extraLarge"];
|
|
151
|
+
var InlineTextSizeName = freezeEnum(inlineTextSizeNames);
|
|
152
|
+
var textSizeNames = [...inlineTextSizeNames, "heading"];
|
|
151
153
|
var TextSizeName = freezeEnum(textSizeNames);
|
|
152
154
|
var variantModes = ["multiple", "single"];
|
|
153
155
|
var VariantMode = freezeEnum(variantModes);
|
|
@@ -2477,7 +2479,8 @@ var OFFER_TEMPLATE_SEED = {
|
|
|
2477
2479
|
{
|
|
2478
2480
|
attrs: {
|
|
2479
2481
|
color: "base",
|
|
2480
|
-
|
|
2482
|
+
/** Block-level heading: new widgets get navigable card titles by default (WCAG 1.3.1). */
|
|
2483
|
+
fontSize: "heading"
|
|
2481
2484
|
},
|
|
2482
2485
|
type: "textStyle"
|
|
2483
2486
|
},
|
|
@@ -2704,10 +2707,8 @@ var ADD_LABEL_TOKENS = ["quantity", "price", "total"];
|
|
|
2704
2707
|
var SWITCH_LABEL_TOKENS2 = ["subscriptionDiscount", "frequency", "interval"];
|
|
2705
2708
|
var QUANTITY_ERROR_TOKENS = ["max", "min", "step"];
|
|
2706
2709
|
var VARIANT_SELECTOR = { button: "button", radio: "radio", select: "menu" };
|
|
2707
|
-
var buildStyledText = (token, style,
|
|
2708
|
-
const marks = [
|
|
2709
|
-
{ attrs: { color, fontSize: style?.textSize ?? "base" }, type: "textStyle" }
|
|
2710
|
-
];
|
|
2710
|
+
var buildStyledText = (token, style, fontSize = style?.textSize ?? "base") => {
|
|
2711
|
+
const marks = [{ attrs: { color: "base", fontSize }, type: "textStyle" }];
|
|
2711
2712
|
if (style?.textEmphasis === "bold") marks.push({ type: "bold" });
|
|
2712
2713
|
if (style?.textEmphasis === "italic") marks.push({ type: "italic" });
|
|
2713
2714
|
return { content: [{ content: [{ marks, text: token, type: "text" }], type: "paragraph" }], type: "doc" };
|
|
@@ -2747,8 +2748,8 @@ var buildImage = (settings) => {
|
|
|
2747
2748
|
const image = settings.displaySettings?.image;
|
|
2748
2749
|
return {
|
|
2749
2750
|
...image?.imageFit && { objectFit: image.imageFit },
|
|
2750
|
-
/**
|
|
2751
|
-
altText: "
|
|
2751
|
+
/** Decorative on purpose: the card's title heading already names the product, so alt text would only duplicate it for screen readers (legacy checkout-offers dropped its variantTitle alt for the same reason). */
|
|
2752
|
+
altText: "",
|
|
2752
2753
|
aspectRatio: 1,
|
|
2753
2754
|
border: {
|
|
2754
2755
|
radius: borderToken(borderRadii, image?.borderRadius),
|
|
@@ -2768,7 +2769,9 @@ var gridCardImage = (image) => ({
|
|
|
2768
2769
|
sectionType: "layout"
|
|
2769
2770
|
});
|
|
2770
2771
|
var buildTitle = (settings) => ({
|
|
2771
|
-
content: {
|
|
2772
|
+
content: {
|
|
2773
|
+
en: buildStyledText("{{productTitle}}", settings.displaySettings?.product, "heading")
|
|
2774
|
+
},
|
|
2772
2775
|
sectionType: "text"
|
|
2773
2776
|
});
|
|
2774
2777
|
var buildPrice = (settings) => ({
|
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Minimal v1 Offer (Checkout Offers / product recommendations) input types.
|
|
3
|
+
* The legacy widget's settings `type` is the generic `shopify_checkout_extension`
|
|
4
|
+
* (the offer is the "base" checkout-extension type; other widgets carry
|
|
5
|
+
* `ui_extension_*`), which uniquely identifies it at the settings level.
|
|
6
|
+
*/
|
|
7
|
+
import { type InlineTextSizeName } from '../../schema/widgets/checkout-and-beyond/common';
|
|
1
8
|
import { type TiptapDocument } from '../../schema/widgets/checkout-and-beyond/text';
|
|
2
9
|
import { type V1Location } from '../../transforms/v1Location';
|
|
3
10
|
export declare const SHOPIFY_CHECKOUT_EXTENSION: "shopify_checkout_extension";
|
|
@@ -22,10 +29,13 @@ export type V1OfferLanguage = {
|
|
|
22
29
|
/** Legacy "Upgrade to Subscription and Save {{subscription_discount}}%" upsell label. */
|
|
23
30
|
upgradeToSubscription?: string;
|
|
24
31
|
};
|
|
25
|
-
/**
|
|
32
|
+
/**
|
|
33
|
+
* v1 per-product text styling; `textSize` is the CAB INLINE size scale verbatim — stored v1 payloads
|
|
34
|
+
* predate (and can never contain) the block-level `heading` member of the `textSizeNames` superset.
|
|
35
|
+
*/
|
|
26
36
|
export type V1TextStyle = {
|
|
27
37
|
textEmphasis?: 'base' | 'bold' | 'italic';
|
|
28
|
-
textSize?:
|
|
38
|
+
textSize?: InlineTextSizeName;
|
|
29
39
|
};
|
|
30
40
|
/** v1 `displaySettings` — the controls behind product/variant/image/review presentation. */
|
|
31
41
|
export type V1OfferDisplaySettings = {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rebuy/rebuy",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.2.0",
|
|
4
4
|
"description": "Shared zod schemas, legacy-to-CAB widget transforms, and server orchestrators for Rebuy's Shopify consumers (rebuy-api, admin-nextjs, rebuy-shopify-extensions)",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Rebuy, Inc.",
|