@rebuy/rebuy 3.62.2 → 3.63.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 +3 -1
- package/dist/index.mjs +3 -1
- package/dist/schema/checkout-and-beyond/index.cjs +3 -1
- package/dist/schema/checkout-and-beyond/index.mjs +3 -1
- package/dist/schema/widget-data.cjs +3 -1
- package/dist/schema/widget-data.mjs +3 -1
- package/dist/server/index.cjs +11 -5
- package/dist/server/index.mjs +11 -5
- package/dist/transforms/index.cjs +11 -5
- package/dist/transforms/index.mjs +11 -5
- package/dist/transforms/postPurchase/convertProductInformation.d.ts +2 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -4536,7 +4536,9 @@ var CABLayoutSection = import_zod67.z.object({
|
|
|
4536
4536
|
direction: import_zod67.z.enum(directions).default(Direction.rows),
|
|
4537
4537
|
/**
|
|
4538
4538
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
4539
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
4539
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
4540
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
4541
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
4540
4542
|
*/
|
|
4541
4543
|
frame: import_zod67.z.enum(layoutFrames).optional(),
|
|
4542
4544
|
grid: import_zod67.z.object({
|
package/dist/index.mjs
CHANGED
|
@@ -4053,7 +4053,9 @@ var CABLayoutSection = z67.object({
|
|
|
4053
4053
|
direction: z67.enum(directions).default(Direction.rows),
|
|
4054
4054
|
/**
|
|
4055
4055
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
4056
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
4056
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
4057
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
4058
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
4057
4059
|
*/
|
|
4058
4060
|
frame: z67.enum(layoutFrames).optional(),
|
|
4059
4061
|
grid: z67.object({
|
|
@@ -1712,7 +1712,9 @@ var CABLayoutSection = import_zod21.z.object({
|
|
|
1712
1712
|
direction: import_zod21.z.enum(directions).default(Direction.rows),
|
|
1713
1713
|
/**
|
|
1714
1714
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
1715
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
1715
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
1716
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
1717
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
1716
1718
|
*/
|
|
1717
1719
|
frame: import_zod21.z.enum(layoutFrames).optional(),
|
|
1718
1720
|
grid: import_zod21.z.object({
|
|
@@ -1497,7 +1497,9 @@ var CABLayoutSection = z21.object({
|
|
|
1497
1497
|
direction: z21.enum(directions).default(Direction.rows),
|
|
1498
1498
|
/**
|
|
1499
1499
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
1500
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
1500
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
1501
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
1502
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
1501
1503
|
*/
|
|
1502
1504
|
frame: z21.enum(layoutFrames).optional(),
|
|
1503
1505
|
grid: z21.object({
|
|
@@ -1533,7 +1533,9 @@ var CABLayoutSection = import_zod24.z.object({
|
|
|
1533
1533
|
direction: import_zod24.z.enum(directions).default(Direction.rows),
|
|
1534
1534
|
/**
|
|
1535
1535
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
1536
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
1536
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
1537
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
1538
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
1537
1539
|
*/
|
|
1538
1540
|
frame: import_zod24.z.enum(layoutFrames).optional(),
|
|
1539
1541
|
grid: import_zod24.z.object({
|
|
@@ -1508,7 +1508,9 @@ var CABLayoutSection = z24.object({
|
|
|
1508
1508
|
direction: z24.enum(directions).default(Direction.rows),
|
|
1509
1509
|
/**
|
|
1510
1510
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
1511
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
1511
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
1512
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
1513
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
1512
1514
|
*/
|
|
1513
1515
|
frame: z24.enum(layoutFrames).optional(),
|
|
1514
1516
|
grid: z24.object({
|
package/dist/server/index.cjs
CHANGED
|
@@ -1953,7 +1953,9 @@ var CABLayoutSection = import_zod22.z.object({
|
|
|
1953
1953
|
direction: import_zod22.z.enum(directions).default(Direction.rows),
|
|
1954
1954
|
/**
|
|
1955
1955
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
1956
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
1956
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
1957
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
1958
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
1957
1959
|
*/
|
|
1958
1960
|
frame: import_zod22.z.enum(layoutFrames).optional(),
|
|
1959
1961
|
grid: import_zod22.z.object({
|
|
@@ -5022,15 +5024,19 @@ var convertProductInformation = (raw, report, widgetSettings) => {
|
|
|
5022
5024
|
CABLayoutSection.parse({
|
|
5023
5025
|
alignment: { horizontal: "center" },
|
|
5024
5026
|
direction: "grid",
|
|
5025
|
-
|
|
5027
|
+
/**
|
|
5028
|
+
* One full-width track, uncapped. Legacy `ProductImage` set its 250-pixel, 90% track
|
|
5029
|
+
* only on the small viewport, so on medium and large the image filled its column; the
|
|
5030
|
+
* schema has no per-viewport tracks, so it fills its column at every viewport.
|
|
5031
|
+
*/
|
|
5032
|
+
grid: { columns: ["100%"] },
|
|
5026
5033
|
sections: [
|
|
5027
5034
|
CABImageSection.parse({
|
|
5028
5035
|
altText: "{{productTitle}}",
|
|
5029
5036
|
source: "{{productImage}}",
|
|
5030
5037
|
...thumbnails(settings)
|
|
5031
5038
|
})
|
|
5032
|
-
]
|
|
5033
|
-
width: 90
|
|
5039
|
+
]
|
|
5034
5040
|
})
|
|
5035
5041
|
]
|
|
5036
5042
|
}),
|
|
@@ -5120,7 +5126,7 @@ var convertTextBlock = (raw, report) => {
|
|
|
5120
5126
|
const section = CABTextSection.safeParse({ content: { en: content } });
|
|
5121
5127
|
return section.success ? [section.data] : omit(field);
|
|
5122
5128
|
});
|
|
5123
|
-
return sections.length ? [CABLayoutSection.parse({ alignment: { horizontal }, sections })] : [];
|
|
5129
|
+
return sections.length ? [CABLayoutSection.parse({ alignment: { horizontal }, frame: "offer-content", sections })] : [];
|
|
5124
5130
|
};
|
|
5125
5131
|
|
|
5126
5132
|
// src/transforms/postPurchase/convertTimerBlock.ts
|
package/dist/server/index.mjs
CHANGED
|
@@ -1880,7 +1880,9 @@ var CABLayoutSection = z22.object({
|
|
|
1880
1880
|
direction: z22.enum(directions).default(Direction.rows),
|
|
1881
1881
|
/**
|
|
1882
1882
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
1883
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
1883
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
1884
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
1885
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
1884
1886
|
*/
|
|
1885
1887
|
frame: z22.enum(layoutFrames).optional(),
|
|
1886
1888
|
grid: z22.object({
|
|
@@ -4949,15 +4951,19 @@ var convertProductInformation = (raw, report, widgetSettings) => {
|
|
|
4949
4951
|
CABLayoutSection.parse({
|
|
4950
4952
|
alignment: { horizontal: "center" },
|
|
4951
4953
|
direction: "grid",
|
|
4952
|
-
|
|
4954
|
+
/**
|
|
4955
|
+
* One full-width track, uncapped. Legacy `ProductImage` set its 250-pixel, 90% track
|
|
4956
|
+
* only on the small viewport, so on medium and large the image filled its column; the
|
|
4957
|
+
* schema has no per-viewport tracks, so it fills its column at every viewport.
|
|
4958
|
+
*/
|
|
4959
|
+
grid: { columns: ["100%"] },
|
|
4953
4960
|
sections: [
|
|
4954
4961
|
CABImageSection.parse({
|
|
4955
4962
|
altText: "{{productTitle}}",
|
|
4956
4963
|
source: "{{productImage}}",
|
|
4957
4964
|
...thumbnails(settings)
|
|
4958
4965
|
})
|
|
4959
|
-
]
|
|
4960
|
-
width: 90
|
|
4966
|
+
]
|
|
4961
4967
|
})
|
|
4962
4968
|
]
|
|
4963
4969
|
}),
|
|
@@ -5047,7 +5053,7 @@ var convertTextBlock = (raw, report) => {
|
|
|
5047
5053
|
const section = CABTextSection.safeParse({ content: { en: content } });
|
|
5048
5054
|
return section.success ? [section.data] : omit(field);
|
|
5049
5055
|
});
|
|
5050
|
-
return sections.length ? [CABLayoutSection.parse({ alignment: { horizontal }, sections })] : [];
|
|
5056
|
+
return sections.length ? [CABLayoutSection.parse({ alignment: { horizontal }, frame: "offer-content", sections })] : [];
|
|
5051
5057
|
};
|
|
5052
5058
|
|
|
5053
5059
|
// src/transforms/postPurchase/convertTimerBlock.ts
|
|
@@ -536,7 +536,9 @@ var CABLayoutSection = import_zod4.z.object({
|
|
|
536
536
|
direction: import_zod4.z.enum(directions).default(Direction.rows),
|
|
537
537
|
/**
|
|
538
538
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
539
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
539
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
540
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
541
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
540
542
|
*/
|
|
541
543
|
frame: import_zod4.z.enum(layoutFrames).optional(),
|
|
542
544
|
grid: import_zod4.z.object({
|
|
@@ -4553,15 +4555,19 @@ var convertProductInformation = (raw, report, widgetSettings) => {
|
|
|
4553
4555
|
CABLayoutSection.parse({
|
|
4554
4556
|
alignment: { horizontal: "center" },
|
|
4555
4557
|
direction: "grid",
|
|
4556
|
-
|
|
4558
|
+
/**
|
|
4559
|
+
* One full-width track, uncapped. Legacy `ProductImage` set its 250-pixel, 90% track
|
|
4560
|
+
* only on the small viewport, so on medium and large the image filled its column; the
|
|
4561
|
+
* schema has no per-viewport tracks, so it fills its column at every viewport.
|
|
4562
|
+
*/
|
|
4563
|
+
grid: { columns: ["100%"] },
|
|
4557
4564
|
sections: [
|
|
4558
4565
|
CABImageSection.parse({
|
|
4559
4566
|
altText: "{{productTitle}}",
|
|
4560
4567
|
source: "{{productImage}}",
|
|
4561
4568
|
...thumbnails(settings)
|
|
4562
4569
|
})
|
|
4563
|
-
]
|
|
4564
|
-
width: 90
|
|
4570
|
+
]
|
|
4565
4571
|
})
|
|
4566
4572
|
]
|
|
4567
4573
|
}),
|
|
@@ -4651,7 +4657,7 @@ var convertTextBlock = (raw, report) => {
|
|
|
4651
4657
|
const section = CABTextSection.safeParse({ content: { en: content } });
|
|
4652
4658
|
return section.success ? [section.data] : omit(field);
|
|
4653
4659
|
});
|
|
4654
|
-
return sections.length ? [CABLayoutSection.parse({ alignment: { horizontal }, sections })] : [];
|
|
4660
|
+
return sections.length ? [CABLayoutSection.parse({ alignment: { horizontal }, frame: "offer-content", sections })] : [];
|
|
4655
4661
|
};
|
|
4656
4662
|
|
|
4657
4663
|
// src/transforms/postPurchase/convertTimerBlock.ts
|
|
@@ -475,7 +475,9 @@ var CABLayoutSection = z4.object({
|
|
|
475
475
|
direction: z4.enum(directions).default(Direction.rows),
|
|
476
476
|
/**
|
|
477
477
|
* Platform chrome around the section, not a layout behavior: `callout` is a subdued box with block borders
|
|
478
|
-
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content
|
|
478
|
+
* (the legacy post-purchase callout banner), `offer-content` the post-purchase offer's own content column
|
|
479
|
+
* (legacy `ComponentSectionLayout`), which the converter puts around the text, image and image-with-text
|
|
480
|
+
* blocks. The offers section is never framed: the renderers place it in that column themselves.
|
|
479
481
|
*/
|
|
480
482
|
frame: z4.enum(layoutFrames).optional(),
|
|
481
483
|
grid: z4.object({
|
|
@@ -4492,15 +4494,19 @@ var convertProductInformation = (raw, report, widgetSettings) => {
|
|
|
4492
4494
|
CABLayoutSection.parse({
|
|
4493
4495
|
alignment: { horizontal: "center" },
|
|
4494
4496
|
direction: "grid",
|
|
4495
|
-
|
|
4497
|
+
/**
|
|
4498
|
+
* One full-width track, uncapped. Legacy `ProductImage` set its 250-pixel, 90% track
|
|
4499
|
+
* only on the small viewport, so on medium and large the image filled its column; the
|
|
4500
|
+
* schema has no per-viewport tracks, so it fills its column at every viewport.
|
|
4501
|
+
*/
|
|
4502
|
+
grid: { columns: ["100%"] },
|
|
4496
4503
|
sections: [
|
|
4497
4504
|
CABImageSection.parse({
|
|
4498
4505
|
altText: "{{productTitle}}",
|
|
4499
4506
|
source: "{{productImage}}",
|
|
4500
4507
|
...thumbnails(settings)
|
|
4501
4508
|
})
|
|
4502
|
-
]
|
|
4503
|
-
width: 90
|
|
4509
|
+
]
|
|
4504
4510
|
})
|
|
4505
4511
|
]
|
|
4506
4512
|
}),
|
|
@@ -4590,7 +4596,7 @@ var convertTextBlock = (raw, report) => {
|
|
|
4590
4596
|
const section = CABTextSection.safeParse({ content: { en: content } });
|
|
4591
4597
|
return section.success ? [section.data] : omit(field);
|
|
4592
4598
|
});
|
|
4593
|
-
return sections.length ? [CABLayoutSection.parse({ alignment: { horizontal }, sections })] : [];
|
|
4599
|
+
return sections.length ? [CABLayoutSection.parse({ alignment: { horizontal }, frame: "offer-content", sections })] : [];
|
|
4594
4600
|
};
|
|
4595
4601
|
|
|
4596
4602
|
// src/transforms/postPurchase/convertTimerBlock.ts
|
|
@@ -4,6 +4,7 @@ import type { Reporter } from '../../server/shared';
|
|
|
4
4
|
* Structure only: the card provider binds the separately prepared fixed product. The card is built from
|
|
5
5
|
* the section types the checkout offer card uses — price, purchase mode, variants, quantity — plus the
|
|
6
6
|
* post-purchase price breakdown and recurring summary, then the card's own Pay and decline, all driven by the saved
|
|
7
|
-
* widget settings.
|
|
7
|
+
* widget settings. It carries no `frame`: the renderers set the offers section in the offer's content column
|
|
8
|
+
* themselves, so an `offer-content` frame here would cap the card twice.
|
|
8
9
|
*/
|
|
9
10
|
export declare const convertProductInformation: (raw: unknown, report?: Reporter, widgetSettings?: unknown) => CABOffersSection[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rebuy/rebuy",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.63.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.",
|