@rebuy/rebuy 2.1.0 → 2.2.0-rc.10
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.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +654 -1
- package/dist/index.js.map +4 -4
- package/dist/index.mjs +654 -1
- package/dist/index.mjs.map +4 -4
- package/dist/schema/button.d.ts +273 -0
- package/dist/schema/button.d.ts.map +1 -0
- package/dist/schema/common.d.ts +369 -0
- package/dist/schema/common.d.ts.map +1 -0
- package/dist/schema/constants.d.ts +165 -0
- package/dist/schema/constants.d.ts.map +1 -0
- package/dist/schema/data-source.d.ts +13 -0
- package/dist/schema/data-source.d.ts.map +1 -0
- package/dist/schema/image.d.ts +65 -0
- package/dist/schema/image.d.ts.map +1 -0
- package/dist/schema/index.d.ts +20 -0
- package/dist/schema/index.d.ts.map +1 -0
- package/dist/schema/layout.d.ts +79 -0
- package/dist/schema/layout.d.ts.map +1 -0
- package/dist/schema/offers.d.ts +67 -0
- package/dist/schema/offers.d.ts.map +1 -0
- package/dist/schema/product.d.ts +147 -0
- package/dist/schema/product.d.ts.map +1 -0
- package/dist/schema/products.d.ts +152 -0
- package/dist/schema/products.d.ts.map +1 -0
- package/dist/schema/quantity.d.ts +21 -0
- package/dist/schema/quantity.d.ts.map +1 -0
- package/dist/schema/regex.d.ts +7 -0
- package/dist/schema/regex.d.ts.map +1 -0
- package/dist/schema/reviews.d.ts +10 -0
- package/dist/schema/reviews.d.ts.map +1 -0
- package/dist/schema/root.d.ts +127 -0
- package/dist/schema/root.d.ts.map +1 -0
- package/dist/schema/shared.d.ts +78 -0
- package/dist/schema/shared.d.ts.map +1 -0
- package/dist/schema/subscription.d.ts +10 -0
- package/dist/schema/subscription.d.ts.map +1 -0
- package/dist/schema/table.d.ts +10 -0
- package/dist/schema/table.d.ts.map +1 -0
- package/dist/schema/text.d.ts +162 -0
- package/dist/schema/text.d.ts.map +1 -0
- package/dist/schema/utils.d.ts +33 -0
- package/dist/schema/utils.d.ts.map +1 -0
- package/dist/schema/variants.d.ts +17 -0
- package/dist/schema/variants.d.ts.map +1 -0
- package/package.json +7 -2
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
import { z } from 'zod/v4';
|
|
2
|
+
import { type SectionDetails } from './shared';
|
|
3
|
+
export declare const CABProductsSection: z.ZodObject<{
|
|
4
|
+
name: z.ZodOptional<z.ZodString>;
|
|
5
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
6
|
+
sections: z.ZodDefault<z.ZodArray<z.ZodLazy<z.ZodObject<{
|
|
7
|
+
name: z.ZodOptional<z.ZodString>;
|
|
8
|
+
options: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
9
|
+
name: z.ZodString;
|
|
10
|
+
optionId: z.ZodNumber;
|
|
11
|
+
selector: z.ZodDefault<z.ZodEnum<{
|
|
12
|
+
button: "button";
|
|
13
|
+
image: "image";
|
|
14
|
+
menu: "menu";
|
|
15
|
+
radio: "radio";
|
|
16
|
+
color: "color";
|
|
17
|
+
}>>;
|
|
18
|
+
values: z.ZodArray<z.ZodObject<{
|
|
19
|
+
color: z.ZodOptional<z.ZodString>;
|
|
20
|
+
image: z.ZodOptional<z.ZodLazy<z.ZodObject<{
|
|
21
|
+
altText: z.ZodDefault<z.ZodString>;
|
|
22
|
+
aspectRatio: z.ZodDefault<z.ZodNullable<z.ZodLiteral<1>>>;
|
|
23
|
+
border: z.ZodLazy<z.ZodDefault<z.ZodObject<{
|
|
24
|
+
radius: z.ZodDefault<z.ZodEnum<{
|
|
25
|
+
small: "small";
|
|
26
|
+
none: "none";
|
|
27
|
+
base: "base";
|
|
28
|
+
large: "large";
|
|
29
|
+
fullyRounded: "fullyRounded";
|
|
30
|
+
}>>;
|
|
31
|
+
style: z.ZodDefault<z.ZodEnum<{
|
|
32
|
+
none: "none";
|
|
33
|
+
base: "base";
|
|
34
|
+
dotted: "dotted";
|
|
35
|
+
dashed: "dashed";
|
|
36
|
+
}>>;
|
|
37
|
+
width: z.ZodDefault<z.ZodEnum<{
|
|
38
|
+
base: "base";
|
|
39
|
+
medium: "medium";
|
|
40
|
+
thick: "thick";
|
|
41
|
+
}>>;
|
|
42
|
+
}, z.core.$strip>>>;
|
|
43
|
+
buttonField: z.ZodOptional<z.ZodEnum<{
|
|
44
|
+
declineAllOffers: "declineAllOffers";
|
|
45
|
+
declineOffer: "declineOffer";
|
|
46
|
+
removeFromCart: "removeFromCart";
|
|
47
|
+
showVariants: "showVariants";
|
|
48
|
+
addedToCart: "addedToCart";
|
|
49
|
+
addingToCart: "addingToCart";
|
|
50
|
+
addToCart: "addToCart";
|
|
51
|
+
buttonLabel: "buttonLabel";
|
|
52
|
+
destinationUrl: "destinationUrl";
|
|
53
|
+
payNow: "payNow";
|
|
54
|
+
showVariant: "showVariant";
|
|
55
|
+
soldOut: "soldOut";
|
|
56
|
+
switchToOneTimeAction: "switchToOneTimeAction";
|
|
57
|
+
switchToOneTimePurchase: "switchToOneTimePurchase";
|
|
58
|
+
switchToSubscriptionAction: "switchToSubscriptionAction";
|
|
59
|
+
switchToSubscriptionNoDiscount: "switchToSubscriptionNoDiscount";
|
|
60
|
+
switchToSubscriptionWithDiscount: "switchToSubscriptionWithDiscount";
|
|
61
|
+
}>>;
|
|
62
|
+
category: z.ZodDefault<z.ZodNullable<z.ZodEnum<{
|
|
63
|
+
gallery: "gallery";
|
|
64
|
+
icons: "icons";
|
|
65
|
+
"payment-methods": "payment-methods";
|
|
66
|
+
"secure-checkout": "secure-checkout";
|
|
67
|
+
}>>>;
|
|
68
|
+
name: z.ZodOptional<z.ZodString>;
|
|
69
|
+
naturalHeight: z.ZodDefault<z.ZodNumber>;
|
|
70
|
+
naturalWidth: z.ZodDefault<z.ZodNumber>;
|
|
71
|
+
objectFit: z.ZodDefault<z.ZodEnum<{
|
|
72
|
+
cover: "cover";
|
|
73
|
+
contain: "contain";
|
|
74
|
+
}>>;
|
|
75
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
76
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"image">>;
|
|
77
|
+
source: z.ZodDefault<z.ZodUnion<readonly [z.ZodURL, z.ZodLiteral<"">, z.ZodString]>>;
|
|
78
|
+
width: z.ZodDefault<z.ZodNumber>;
|
|
79
|
+
}, z.core.$strip>>>;
|
|
80
|
+
name: z.ZodString;
|
|
81
|
+
text: z.ZodOptional<z.ZodLazy<z.ZodObject<{
|
|
82
|
+
buttonField: z.ZodOptional<z.ZodEnum<{
|
|
83
|
+
declineAllOffers: "declineAllOffers";
|
|
84
|
+
declineOffer: "declineOffer";
|
|
85
|
+
removeFromCart: "removeFromCart";
|
|
86
|
+
showVariants: "showVariants";
|
|
87
|
+
addedToCart: "addedToCart";
|
|
88
|
+
addingToCart: "addingToCart";
|
|
89
|
+
addToCart: "addToCart";
|
|
90
|
+
buttonLabel: "buttonLabel";
|
|
91
|
+
destinationUrl: "destinationUrl";
|
|
92
|
+
payNow: "payNow";
|
|
93
|
+
showVariant: "showVariant";
|
|
94
|
+
soldOut: "soldOut";
|
|
95
|
+
switchToOneTimeAction: "switchToOneTimeAction";
|
|
96
|
+
switchToOneTimePurchase: "switchToOneTimePurchase";
|
|
97
|
+
switchToSubscriptionAction: "switchToSubscriptionAction";
|
|
98
|
+
switchToSubscriptionNoDiscount: "switchToSubscriptionNoDiscount";
|
|
99
|
+
switchToSubscriptionWithDiscount: "switchToSubscriptionWithDiscount";
|
|
100
|
+
}>>;
|
|
101
|
+
content: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
102
|
+
attrs: z.ZodDefault<z.ZodObject<{
|
|
103
|
+
blockSpacing: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"none" | "base" | "extraTight" | "tight" | "loose" | "extraLoose" | undefined, string>>>;
|
|
104
|
+
}, z.core.$strip>>;
|
|
105
|
+
content: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
106
|
+
attrs: z.ZodDefault<z.ZodObject<{
|
|
107
|
+
textAlign: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"start" | "center" | "end" | undefined, string>>>;
|
|
108
|
+
}, z.core.$strip>>;
|
|
109
|
+
content: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
110
|
+
marks: z.ZodOptional<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
111
|
+
type: z.ZodLiteral<"bold">;
|
|
112
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
113
|
+
type: z.ZodLiteral<"italic">;
|
|
114
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
115
|
+
attrs: z.ZodObject<{
|
|
116
|
+
class: z.ZodNullable<z.ZodString>;
|
|
117
|
+
href: z.ZodUnion<readonly [z.ZodURL, z.ZodString]>;
|
|
118
|
+
rel: z.ZodDefault<z.ZodString>;
|
|
119
|
+
target: z.ZodDefault<z.ZodString>;
|
|
120
|
+
}, z.core.$strip>;
|
|
121
|
+
type: z.ZodLiteral<"link">;
|
|
122
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
123
|
+
type: z.ZodLiteral<"strike">;
|
|
124
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
125
|
+
attrs: z.ZodObject<{
|
|
126
|
+
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"base" | "subdued" | "accent" | "decorative" | "success" | "warning" | "critical" | undefined, string>>>>;
|
|
127
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
128
|
+
}, z.core.$strip>;
|
|
129
|
+
type: z.ZodLiteral<"textStyle">;
|
|
130
|
+
}, z.core.$strip>]>>>;
|
|
131
|
+
text: z.ZodDefault<z.ZodString>;
|
|
132
|
+
type: z.ZodDefault<z.ZodLiteral<"text">>;
|
|
133
|
+
}, z.core.$strip>>>;
|
|
134
|
+
type: z.ZodDefault<z.ZodLiteral<"paragraph">>;
|
|
135
|
+
}, z.core.$strip>>>;
|
|
136
|
+
type: z.ZodDefault<z.ZodLiteral<"doc">>;
|
|
137
|
+
}, z.core.$strip>]>>>>>;
|
|
138
|
+
name: z.ZodOptional<z.ZodString>;
|
|
139
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
140
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"text">>;
|
|
141
|
+
}, z.core.$strip>>>;
|
|
142
|
+
}, z.core.$strip>>;
|
|
143
|
+
}, z.core.$strip>>>;
|
|
144
|
+
productId: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
145
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
146
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"product">>;
|
|
147
|
+
}, z.core.$strip>>>>;
|
|
148
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"products">>;
|
|
149
|
+
}, z.core.$strip>;
|
|
150
|
+
export type CABProductsSection = z.infer<typeof CABProductsSection>;
|
|
151
|
+
export type CABProductsSectionProps = CABProductsSection & SectionDetails;
|
|
152
|
+
//# sourceMappingURL=products.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"products.d.ts","sourceRoot":"","sources":["../../src/schema/products.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAI3B,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,UAAU,CAAC;AAE/C,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAK7B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAEpE,MAAM,MAAM,uBAAuB,GAAG,kBAAkB,GAAG,cAAc,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { z } from 'zod/v4';
|
|
2
|
+
import { type SectionDetails } from './shared';
|
|
3
|
+
export declare const CABQuantitySection: z.ZodObject<{
|
|
4
|
+
errorMessages: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
5
|
+
max: z.ZodOptional<z.ZodString>;
|
|
6
|
+
min: z.ZodOptional<z.ZodString>;
|
|
7
|
+
neg: z.ZodOptional<z.ZodString>;
|
|
8
|
+
}, z.core.$strip>>>;
|
|
9
|
+
inputType: z.ZodDefault<z.ZodEnum<{
|
|
10
|
+
number: "number";
|
|
11
|
+
select: "select";
|
|
12
|
+
}>>;
|
|
13
|
+
max: z.ZodDefault<z.ZodNumber>;
|
|
14
|
+
min: z.ZodDefault<z.ZodNumber>;
|
|
15
|
+
name: z.ZodOptional<z.ZodString>;
|
|
16
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
17
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"quantity">>;
|
|
18
|
+
}, z.core.$strip>;
|
|
19
|
+
export type CABQuantitySection = z.infer<typeof CABQuantitySection>;
|
|
20
|
+
export type CABQuantitySectionProps = CABQuantitySection & SectionDetails;
|
|
21
|
+
//# sourceMappingURL=quantity.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"quantity.d.ts","sourceRoot":"","sources":["../../src/schema/quantity.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAG3B,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,UAAU,CAAC;AAE/C,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;iBAuB7B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAEpE,MAAM,MAAM,uBAAuB,GAAG,kBAAkB,GAAG,cAAc,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/** Matches a dynamic token. */
|
|
2
|
+
export declare const DYNAMIC_TOKEN_REGEX: RegExp;
|
|
3
|
+
/** Matches a valid hex color code. */
|
|
4
|
+
export declare const HEX_COLOR_REGEX: RegExp;
|
|
5
|
+
/** Matches any HTML tags. */
|
|
6
|
+
export declare const HTML_TAGS_REGEX: RegExp;
|
|
7
|
+
//# sourceMappingURL=regex.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"regex.d.ts","sourceRoot":"","sources":["../../src/schema/regex.ts"],"names":[],"mappings":"AAAA,+BAA+B;AAC/B,eAAO,MAAM,mBAAmB,QAA8B,CAAC;AAE/D,sCAAsC;AACtC,eAAO,MAAM,eAAe,QAAuC,CAAC;AAEpE,6BAA6B;AAC7B,eAAO,MAAM,eAAe,QAAc,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { z } from 'zod/v4';
|
|
2
|
+
import { type SectionDetails } from './shared';
|
|
3
|
+
export declare const CABReviewsSection: z.ZodObject<{
|
|
4
|
+
name: z.ZodOptional<z.ZodString>;
|
|
5
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
6
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"reviews">>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
export type CABReviewsSection = z.infer<typeof CABReviewsSection>;
|
|
9
|
+
export type CABReviewsSectionProps = CABReviewsSection & SectionDetails;
|
|
10
|
+
//# sourceMappingURL=reviews.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reviews.d.ts","sourceRoot":"","sources":["../../src/schema/reviews.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAG3B,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,UAAU,CAAC;AAE/C,eAAO,MAAM,iBAAiB;;;;iBAI5B,CAAC;AAEH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE,MAAM,MAAM,sBAAsB,GAAG,iBAAiB,GAAG,cAAc,CAAC"}
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
import { z } from 'zod/v4';
|
|
2
|
+
import { EditorMode } from './common';
|
|
3
|
+
import { WidgetType } from './constants';
|
|
4
|
+
import { CABLayoutSection } from './layout';
|
|
5
|
+
export type TargetArea = {
|
|
6
|
+
fill?: boolean;
|
|
7
|
+
flip?: 'horizontal' | 'vertical' | 'both';
|
|
8
|
+
icon: string;
|
|
9
|
+
label: string;
|
|
10
|
+
width: string;
|
|
11
|
+
};
|
|
12
|
+
export declare const CABRootSection: z.ZodObject<{
|
|
13
|
+
alignment: z.ZodDefault<z.ZodObject<{
|
|
14
|
+
horizontal: z.ZodDefault<z.ZodEnum<{
|
|
15
|
+
start: "start";
|
|
16
|
+
center: "center";
|
|
17
|
+
end: "end";
|
|
18
|
+
}>>;
|
|
19
|
+
vertical: z.ZodDefault<z.ZodEnum<{
|
|
20
|
+
top: "top";
|
|
21
|
+
middle: "middle";
|
|
22
|
+
bottom: "bottom";
|
|
23
|
+
}>>;
|
|
24
|
+
}, z.core.$strip>>;
|
|
25
|
+
border: z.ZodLazy<z.ZodDefault<z.ZodObject<{
|
|
26
|
+
radius: z.ZodDefault<z.ZodEnum<{
|
|
27
|
+
small: "small";
|
|
28
|
+
none: "none";
|
|
29
|
+
base: "base";
|
|
30
|
+
large: "large";
|
|
31
|
+
fullyRounded: "fullyRounded";
|
|
32
|
+
}>>;
|
|
33
|
+
style: z.ZodDefault<z.ZodEnum<{
|
|
34
|
+
none: "none";
|
|
35
|
+
base: "base";
|
|
36
|
+
dotted: "dotted";
|
|
37
|
+
dashed: "dashed";
|
|
38
|
+
}>>;
|
|
39
|
+
width: z.ZodDefault<z.ZodEnum<{
|
|
40
|
+
base: "base";
|
|
41
|
+
medium: "medium";
|
|
42
|
+
thick: "thick";
|
|
43
|
+
}>>;
|
|
44
|
+
}, z.core.$strip>>>;
|
|
45
|
+
direction: z.ZodDefault<z.ZodEnum<{
|
|
46
|
+
columns: "columns";
|
|
47
|
+
rows: "rows";
|
|
48
|
+
}>>;
|
|
49
|
+
name: z.ZodOptional<z.ZodString>;
|
|
50
|
+
padding: z.ZodDefault<z.ZodEnum<{
|
|
51
|
+
none: "none";
|
|
52
|
+
base: "base";
|
|
53
|
+
extraTight: "extraTight";
|
|
54
|
+
tight: "tight";
|
|
55
|
+
loose: "loose";
|
|
56
|
+
extraLoose: "extraLoose";
|
|
57
|
+
}>>;
|
|
58
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
59
|
+
sections: z.ZodDefault<z.ZodArray<z.ZodLazy<z.ZodType<import("./shared").CABSection, unknown, z.core.$ZodTypeInternals<import("./shared").CABSection, unknown>>>>>;
|
|
60
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"layout">>;
|
|
61
|
+
spacing: z.ZodDefault<z.ZodEnum<{
|
|
62
|
+
none: "none";
|
|
63
|
+
base: "base";
|
|
64
|
+
extraTight: "extraTight";
|
|
65
|
+
tight: "tight";
|
|
66
|
+
loose: "loose";
|
|
67
|
+
extraLoose: "extraLoose";
|
|
68
|
+
}>>;
|
|
69
|
+
width: z.ZodDefault<z.ZodNumber>;
|
|
70
|
+
editorMode: z.ZodDefault<z.ZodEnum<{
|
|
71
|
+
checkoutExtension: "checkoutExtension";
|
|
72
|
+
postPurchaseOffer: "postPurchaseOffer";
|
|
73
|
+
thankYouPage: "thankYouPage";
|
|
74
|
+
orderStatusPage: "orderStatusPage";
|
|
75
|
+
ordersIndexPage: "ordersIndexPage";
|
|
76
|
+
customerProfilePage: "customerProfilePage";
|
|
77
|
+
}>>;
|
|
78
|
+
previewMode: z.ZodDefault<z.ZodBoolean>;
|
|
79
|
+
storeId: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
80
|
+
targetArea: z.ZodNullable<z.ZodDefault<z.ZodObject<{
|
|
81
|
+
fill: z.ZodOptional<z.ZodBoolean>;
|
|
82
|
+
flip: z.ZodOptional<z.ZodEnum<{
|
|
83
|
+
horizontal: "horizontal";
|
|
84
|
+
vertical: "vertical";
|
|
85
|
+
both: "both";
|
|
86
|
+
}>>;
|
|
87
|
+
icon: z.ZodString;
|
|
88
|
+
label: z.ZodString;
|
|
89
|
+
width: z.ZodString;
|
|
90
|
+
}, z.core.$strip>>>;
|
|
91
|
+
type: z.ZodDefault<z.ZodEnum<{
|
|
92
|
+
product: "product";
|
|
93
|
+
bundle_builder: "bundle_builder";
|
|
94
|
+
cart: "cart";
|
|
95
|
+
cart_subscription: "cart_subscription";
|
|
96
|
+
dynamic_bundle: "dynamic_bundle";
|
|
97
|
+
gift_with_purchase: "gift_with_purchase";
|
|
98
|
+
pre_purchase: "pre_purchase";
|
|
99
|
+
product_addon: "product_addon";
|
|
100
|
+
product_upsell: "product_upsell";
|
|
101
|
+
recharge_checkout: "recharge_checkout";
|
|
102
|
+
recharge_customer_portal: "recharge_customer_portal";
|
|
103
|
+
recharge_post_purchase: "recharge_post_purchase";
|
|
104
|
+
shopify_checkout: "shopify_checkout";
|
|
105
|
+
shopify_checkout_extension: "shopify_checkout_extension";
|
|
106
|
+
shopify_post_purchase: "shopify_post_purchase";
|
|
107
|
+
shopify_post_purchase_extension: "shopify_post_purchase_extension";
|
|
108
|
+
switch_to_subscription: "switch_to_subscription";
|
|
109
|
+
ui_extension_ad: "ui_extension_ad";
|
|
110
|
+
ui_extension_button: "ui_extension_button";
|
|
111
|
+
ui_extension_content_block: "ui_extension_content_block";
|
|
112
|
+
ui_extension_line_item_editor: "ui_extension_line_item_editor";
|
|
113
|
+
ui_extension_progress_bar: "ui_extension_progress_bar";
|
|
114
|
+
}>>;
|
|
115
|
+
version: z.ZodDefault<z.ZodLiteral<2>>;
|
|
116
|
+
widgetId: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
117
|
+
}, z.core.$strip>;
|
|
118
|
+
export type CABRootSection = CABLayoutSection & {
|
|
119
|
+
editorMode: EditorMode;
|
|
120
|
+
previewMode: boolean;
|
|
121
|
+
storeId: number | null;
|
|
122
|
+
targetArea: TargetArea | null;
|
|
123
|
+
type: WidgetType;
|
|
124
|
+
version: number;
|
|
125
|
+
widgetId: number | null;
|
|
126
|
+
};
|
|
127
|
+
//# sourceMappingURL=root.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"root.d.ts","sourceRoot":"","sources":["../../src/schema/root.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAE3B,OAAO,EAAE,UAAU,EAAe,MAAM,UAAU,CAAC;AACnD,OAAO,EAAe,UAAU,EAAe,MAAM,aAAa,CAAC;AACnE,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAY5C,MAAM,MAAM,UAAU,GAAG;IACrB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,IAAI,CAAC,EAAE,YAAY,GAAG,UAAU,GAAG,MAAM,CAAC;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAU1B,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG,gBAAgB,GAAG;IAC5C,UAAU,EAAE,UAAU,CAAC;IACvB,WAAW,EAAE,OAAO,CAAC;IACrB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,UAAU,EAAE,UAAU,GAAG,IAAI,CAAC;IAC9B,IAAI,EAAE,UAAU,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAC;CAC3B,CAAC"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { type FieldArrayPath } from 'react-hook-form';
|
|
2
|
+
import { z, type ZodType } from 'zod/v4';
|
|
3
|
+
import { CABButtonSection } from './button';
|
|
4
|
+
import { CABDataSourceSection } from './data-source';
|
|
5
|
+
import { CABImageSection } from './image';
|
|
6
|
+
import { CABLayoutSection } from './layout';
|
|
7
|
+
import { CABOffersSection } from './offers';
|
|
8
|
+
import { CABProductSection } from './product';
|
|
9
|
+
import { CABProductsSection } from './products';
|
|
10
|
+
import { CABQuantitySection } from './quantity';
|
|
11
|
+
import { CABReviewsSection } from './reviews';
|
|
12
|
+
import { type CABRootSection } from './root';
|
|
13
|
+
import { CABSubscriptionSection } from './subscription';
|
|
14
|
+
import { CABTableSection } from './table';
|
|
15
|
+
import { CABTextSection } from './text';
|
|
16
|
+
import { CABVariantsSection } from './variants';
|
|
17
|
+
export declare const CABBorder: z.ZodDefault<z.ZodObject<{
|
|
18
|
+
radius: z.ZodDefault<z.ZodEnum<{
|
|
19
|
+
small: "small";
|
|
20
|
+
none: "none";
|
|
21
|
+
base: "base";
|
|
22
|
+
large: "large";
|
|
23
|
+
fullyRounded: "fullyRounded";
|
|
24
|
+
}>>;
|
|
25
|
+
style: z.ZodDefault<z.ZodEnum<{
|
|
26
|
+
none: "none";
|
|
27
|
+
base: "base";
|
|
28
|
+
dotted: "dotted";
|
|
29
|
+
dashed: "dashed";
|
|
30
|
+
}>>;
|
|
31
|
+
width: z.ZodDefault<z.ZodEnum<{
|
|
32
|
+
base: "base";
|
|
33
|
+
medium: "medium";
|
|
34
|
+
thick: "thick";
|
|
35
|
+
}>>;
|
|
36
|
+
}, z.core.$strip>>;
|
|
37
|
+
export type CABBorder = z.infer<typeof CABBorder>;
|
|
38
|
+
export declare const CABSection: ZodType<CABSection>;
|
|
39
|
+
export type CABSection = CABButtonSection | CABDataSourceSection | CABImageSection | CABLayoutSection | CABOffersSection | CABProductSection | CABProductsSection | CABQuantitySection | CABReviewsSection | CABSubscriptionSection | CABTableSection | CABTextSection | CABVariantsSection;
|
|
40
|
+
export type SectionId = CABSection['sectionId'];
|
|
41
|
+
export type SectionArrayPath = FieldArrayPath<CABRootSection>;
|
|
42
|
+
export type SectionPrefixPath = `${SectionArrayPath}.${number}` | null;
|
|
43
|
+
export type SectionDetails = {
|
|
44
|
+
/**
|
|
45
|
+
* The full React Hook Form dot-notation path to the section object itself,
|
|
46
|
+
* for use with `register` or `control`, e.g. `sections.0.sections.1`.
|
|
47
|
+
*
|
|
48
|
+
* Returns `null` for the root section.
|
|
49
|
+
*/
|
|
50
|
+
fieldArrayPath: SectionArrayPath | null;
|
|
51
|
+
/**
|
|
52
|
+
* The index of the found section within its parent `sections` array.
|
|
53
|
+
*
|
|
54
|
+
* Returns `null` for the root section.
|
|
55
|
+
*/
|
|
56
|
+
index: number | null;
|
|
57
|
+
/**
|
|
58
|
+
* The parent `sections` object.
|
|
59
|
+
*
|
|
60
|
+
* Returns `null` for the root section.
|
|
61
|
+
*/
|
|
62
|
+
parent: CABSection[] | null;
|
|
63
|
+
/**
|
|
64
|
+
* The parent `sectionId`.
|
|
65
|
+
*
|
|
66
|
+
* Returns `undefined` for the root section.
|
|
67
|
+
*/
|
|
68
|
+
parentId: SectionId | undefined;
|
|
69
|
+
/**
|
|
70
|
+
* The full React Hook Form dot-notation path to the section object itself,
|
|
71
|
+
* for use with `register` or `control`, e.g. `sections.0.sections.1`.
|
|
72
|
+
*
|
|
73
|
+
* Returns `null` for the root section.
|
|
74
|
+
*/
|
|
75
|
+
prefixPath: SectionPrefixPath | null;
|
|
76
|
+
};
|
|
77
|
+
export type CABSectionProps = CABSection & SectionDetails;
|
|
78
|
+
//# sourceMappingURL=shared.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shared.d.ts","sourceRoot":"","sources":["../../src/schema/shared.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAAE,CAAC,EAAE,KAAK,OAAO,EAAE,MAAM,QAAQ,CAAC;AAEzC,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE5C,OAAO,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAC5C,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAC5C,OAAO,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAC9C,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,QAAQ,CAAC;AAC7C,OAAO,EAAE,sBAAsB,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAC;AACxC,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAEhD,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;kBAUhB,CAAC;AAEP,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,SAAS,CAAC,CAAC;AAElD,eAAO,MAAM,UAAU,EAAE,OAAO,CAAC,UAAU,CAgB1C,CAAC;AAEF,MAAM,MAAM,UAAU,GAChB,gBAAgB,GAChB,oBAAoB,GACpB,eAAe,GACf,gBAAgB,GAChB,gBAAgB,GAChB,iBAAiB,GACjB,kBAAkB,GAClB,kBAAkB,GAClB,iBAAiB,GACjB,sBAAsB,GACtB,eAAe,GACf,cAAc,GACd,kBAAkB,CAAC;AAEzB,MAAM,MAAM,SAAS,GAAG,UAAU,CAAC,WAAW,CAAC,CAAC;AAGhD,MAAM,MAAM,gBAAgB,GAAG,cAAc,CAAC,cAAc,CAAC,CAAC;AAE9D,MAAM,MAAM,iBAAiB,GAAG,GAAG,gBAAgB,IAAI,MAAM,EAAE,GAAG,IAAI,CAAC;AAEvE,MAAM,MAAM,cAAc,GAAG;IACzB;;;;;OAKG;IACH,cAAc,EAAE,gBAAgB,GAAG,IAAI,CAAC;IACxC;;;;OAIG;IACH,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB;;;;OAIG;IACH,MAAM,EAAE,UAAU,EAAE,GAAG,IAAI,CAAC;IAC5B;;;;OAIG;IACH,QAAQ,EAAE,SAAS,GAAG,SAAS,CAAC;IAChC;;;;;OAKG;IACH,UAAU,EAAE,iBAAiB,GAAG,IAAI,CAAC;CACxC,CAAC;AAEF,MAAM,MAAM,eAAe,GAAG,UAAU,GAAG,cAAc,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { z } from 'zod/v4';
|
|
2
|
+
import { type SectionDetails } from './shared';
|
|
3
|
+
export declare const CABSubscriptionSection: z.ZodObject<{
|
|
4
|
+
name: z.ZodOptional<z.ZodString>;
|
|
5
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
6
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"subscription">>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
export type CABSubscriptionSection = z.infer<typeof CABSubscriptionSection>;
|
|
9
|
+
export type CABSubscriptionSectionProps = CABSubscriptionSection & SectionDetails;
|
|
10
|
+
//# sourceMappingURL=subscription.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"subscription.d.ts","sourceRoot":"","sources":["../../src/schema/subscription.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAG3B,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,UAAU,CAAC;AAE/C,eAAO,MAAM,sBAAsB;;;;iBAIjC,CAAC;AAEH,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAE5E,MAAM,MAAM,2BAA2B,GAAG,sBAAsB,GAAG,cAAc,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { z } from 'zod/v4';
|
|
2
|
+
import { type SectionDetails } from './shared';
|
|
3
|
+
export declare const CABTableSection: z.ZodObject<{
|
|
4
|
+
name: z.ZodOptional<z.ZodString>;
|
|
5
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
6
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"table">>;
|
|
7
|
+
}, z.core.$strip>;
|
|
8
|
+
export type CABTableSection = z.infer<typeof CABTableSection>;
|
|
9
|
+
export type CABTableSectionProps = CABTableSection & SectionDetails;
|
|
10
|
+
//# sourceMappingURL=table.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"table.d.ts","sourceRoot":"","sources":["../../src/schema/table.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAG3B,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,UAAU,CAAC;AAE/C,eAAO,MAAM,eAAe;;;;iBAI1B,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAE9D,MAAM,MAAM,oBAAoB,GAAG,eAAe,GAAG,cAAc,CAAC"}
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
import { z } from 'zod/v4';
|
|
2
|
+
import { type SectionDetails } from './shared';
|
|
3
|
+
export declare const TiptapText: z.ZodObject<{
|
|
4
|
+
marks: z.ZodOptional<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
5
|
+
type: z.ZodLiteral<"bold">;
|
|
6
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
7
|
+
type: z.ZodLiteral<"italic">;
|
|
8
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
9
|
+
attrs: z.ZodObject<{
|
|
10
|
+
class: z.ZodNullable<z.ZodString>;
|
|
11
|
+
href: z.ZodUnion<readonly [z.ZodURL, z.ZodString]>;
|
|
12
|
+
rel: z.ZodDefault<z.ZodString>;
|
|
13
|
+
target: z.ZodDefault<z.ZodString>;
|
|
14
|
+
}, z.core.$strip>;
|
|
15
|
+
type: z.ZodLiteral<"link">;
|
|
16
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
17
|
+
type: z.ZodLiteral<"strike">;
|
|
18
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
19
|
+
attrs: z.ZodObject<{
|
|
20
|
+
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"base" | "subdued" | "accent" | "decorative" | "success" | "warning" | "critical" | undefined, string>>>>;
|
|
21
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
22
|
+
}, z.core.$strip>;
|
|
23
|
+
type: z.ZodLiteral<"textStyle">;
|
|
24
|
+
}, z.core.$strip>]>>>;
|
|
25
|
+
text: z.ZodDefault<z.ZodString>;
|
|
26
|
+
type: z.ZodDefault<z.ZodLiteral<"text">>;
|
|
27
|
+
}, z.core.$strip>;
|
|
28
|
+
export type TiptapText = z.infer<typeof TiptapText>;
|
|
29
|
+
export declare const TiptapParagraph: z.ZodObject<{
|
|
30
|
+
attrs: z.ZodDefault<z.ZodObject<{
|
|
31
|
+
textAlign: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"start" | "center" | "end" | undefined, string>>>;
|
|
32
|
+
}, z.core.$strip>>;
|
|
33
|
+
content: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
34
|
+
marks: z.ZodOptional<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
35
|
+
type: z.ZodLiteral<"bold">;
|
|
36
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
37
|
+
type: z.ZodLiteral<"italic">;
|
|
38
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
39
|
+
attrs: z.ZodObject<{
|
|
40
|
+
class: z.ZodNullable<z.ZodString>;
|
|
41
|
+
href: z.ZodUnion<readonly [z.ZodURL, z.ZodString]>;
|
|
42
|
+
rel: z.ZodDefault<z.ZodString>;
|
|
43
|
+
target: z.ZodDefault<z.ZodString>;
|
|
44
|
+
}, z.core.$strip>;
|
|
45
|
+
type: z.ZodLiteral<"link">;
|
|
46
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
47
|
+
type: z.ZodLiteral<"strike">;
|
|
48
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
49
|
+
attrs: z.ZodObject<{
|
|
50
|
+
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"base" | "subdued" | "accent" | "decorative" | "success" | "warning" | "critical" | undefined, string>>>>;
|
|
51
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
52
|
+
}, z.core.$strip>;
|
|
53
|
+
type: z.ZodLiteral<"textStyle">;
|
|
54
|
+
}, z.core.$strip>]>>>;
|
|
55
|
+
text: z.ZodDefault<z.ZodString>;
|
|
56
|
+
type: z.ZodDefault<z.ZodLiteral<"text">>;
|
|
57
|
+
}, z.core.$strip>>>;
|
|
58
|
+
type: z.ZodDefault<z.ZodLiteral<"paragraph">>;
|
|
59
|
+
}, z.core.$strip>;
|
|
60
|
+
export type TiptapParagraph = z.infer<typeof TiptapParagraph>;
|
|
61
|
+
export declare const TiptapDocument: z.ZodObject<{
|
|
62
|
+
attrs: z.ZodDefault<z.ZodObject<{
|
|
63
|
+
blockSpacing: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"none" | "base" | "extraTight" | "tight" | "loose" | "extraLoose" | undefined, string>>>;
|
|
64
|
+
}, z.core.$strip>>;
|
|
65
|
+
content: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
66
|
+
attrs: z.ZodDefault<z.ZodObject<{
|
|
67
|
+
textAlign: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"start" | "center" | "end" | undefined, string>>>;
|
|
68
|
+
}, z.core.$strip>>;
|
|
69
|
+
content: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
70
|
+
marks: z.ZodOptional<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
71
|
+
type: z.ZodLiteral<"bold">;
|
|
72
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
73
|
+
type: z.ZodLiteral<"italic">;
|
|
74
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
75
|
+
attrs: z.ZodObject<{
|
|
76
|
+
class: z.ZodNullable<z.ZodString>;
|
|
77
|
+
href: z.ZodUnion<readonly [z.ZodURL, z.ZodString]>;
|
|
78
|
+
rel: z.ZodDefault<z.ZodString>;
|
|
79
|
+
target: z.ZodDefault<z.ZodString>;
|
|
80
|
+
}, z.core.$strip>;
|
|
81
|
+
type: z.ZodLiteral<"link">;
|
|
82
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
83
|
+
type: z.ZodLiteral<"strike">;
|
|
84
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
85
|
+
attrs: z.ZodObject<{
|
|
86
|
+
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"base" | "subdued" | "accent" | "decorative" | "success" | "warning" | "critical" | undefined, string>>>>;
|
|
87
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
88
|
+
}, z.core.$strip>;
|
|
89
|
+
type: z.ZodLiteral<"textStyle">;
|
|
90
|
+
}, z.core.$strip>]>>>;
|
|
91
|
+
text: z.ZodDefault<z.ZodString>;
|
|
92
|
+
type: z.ZodDefault<z.ZodLiteral<"text">>;
|
|
93
|
+
}, z.core.$strip>>>;
|
|
94
|
+
type: z.ZodDefault<z.ZodLiteral<"paragraph">>;
|
|
95
|
+
}, z.core.$strip>>>;
|
|
96
|
+
type: z.ZodDefault<z.ZodLiteral<"doc">>;
|
|
97
|
+
}, z.core.$strip>;
|
|
98
|
+
export type TiptapDocument = z.infer<typeof TiptapDocument>;
|
|
99
|
+
export declare const CABTextSection: z.ZodObject<{
|
|
100
|
+
buttonField: z.ZodOptional<z.ZodEnum<{
|
|
101
|
+
declineAllOffers: "declineAllOffers";
|
|
102
|
+
declineOffer: "declineOffer";
|
|
103
|
+
removeFromCart: "removeFromCart";
|
|
104
|
+
showVariants: "showVariants";
|
|
105
|
+
addedToCart: "addedToCart";
|
|
106
|
+
addingToCart: "addingToCart";
|
|
107
|
+
addToCart: "addToCart";
|
|
108
|
+
buttonLabel: "buttonLabel";
|
|
109
|
+
destinationUrl: "destinationUrl";
|
|
110
|
+
payNow: "payNow";
|
|
111
|
+
showVariant: "showVariant";
|
|
112
|
+
soldOut: "soldOut";
|
|
113
|
+
switchToOneTimeAction: "switchToOneTimeAction";
|
|
114
|
+
switchToOneTimePurchase: "switchToOneTimePurchase";
|
|
115
|
+
switchToSubscriptionAction: "switchToSubscriptionAction";
|
|
116
|
+
switchToSubscriptionNoDiscount: "switchToSubscriptionNoDiscount";
|
|
117
|
+
switchToSubscriptionWithDiscount: "switchToSubscriptionWithDiscount";
|
|
118
|
+
}>>;
|
|
119
|
+
content: z.ZodOptional<z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
120
|
+
attrs: z.ZodDefault<z.ZodObject<{
|
|
121
|
+
blockSpacing: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"none" | "base" | "extraTight" | "tight" | "loose" | "extraLoose" | undefined, string>>>;
|
|
122
|
+
}, z.core.$strip>>;
|
|
123
|
+
content: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
124
|
+
attrs: z.ZodDefault<z.ZodObject<{
|
|
125
|
+
textAlign: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"start" | "center" | "end" | undefined, string>>>;
|
|
126
|
+
}, z.core.$strip>>;
|
|
127
|
+
content: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
128
|
+
marks: z.ZodOptional<z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
129
|
+
type: z.ZodLiteral<"bold">;
|
|
130
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
131
|
+
type: z.ZodLiteral<"italic">;
|
|
132
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
133
|
+
attrs: z.ZodObject<{
|
|
134
|
+
class: z.ZodNullable<z.ZodString>;
|
|
135
|
+
href: z.ZodUnion<readonly [z.ZodURL, z.ZodString]>;
|
|
136
|
+
rel: z.ZodDefault<z.ZodString>;
|
|
137
|
+
target: z.ZodDefault<z.ZodString>;
|
|
138
|
+
}, z.core.$strip>;
|
|
139
|
+
type: z.ZodLiteral<"link">;
|
|
140
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
141
|
+
type: z.ZodLiteral<"strike">;
|
|
142
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
143
|
+
attrs: z.ZodObject<{
|
|
144
|
+
color: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"base" | "subdued" | "accent" | "decorative" | "success" | "warning" | "critical" | undefined, string>>>>;
|
|
145
|
+
fontSize: z.ZodDefault<z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<"small" | "base" | "large" | "medium" | "extraSmall" | "extraLarge" | undefined, string>>>>;
|
|
146
|
+
}, z.core.$strip>;
|
|
147
|
+
type: z.ZodLiteral<"textStyle">;
|
|
148
|
+
}, z.core.$strip>]>>>;
|
|
149
|
+
text: z.ZodDefault<z.ZodString>;
|
|
150
|
+
type: z.ZodDefault<z.ZodLiteral<"text">>;
|
|
151
|
+
}, z.core.$strip>>>;
|
|
152
|
+
type: z.ZodDefault<z.ZodLiteral<"paragraph">>;
|
|
153
|
+
}, z.core.$strip>>>;
|
|
154
|
+
type: z.ZodDefault<z.ZodLiteral<"doc">>;
|
|
155
|
+
}, z.core.$strip>]>>>>>;
|
|
156
|
+
name: z.ZodOptional<z.ZodString>;
|
|
157
|
+
sectionId: z.ZodDefault<z.ZodUUID>;
|
|
158
|
+
sectionType: z.ZodDefault<z.ZodLiteral<"text">>;
|
|
159
|
+
}, z.core.$strip>;
|
|
160
|
+
export type CABTextSection = z.infer<typeof CABTextSection>;
|
|
161
|
+
export type CABTextSectionProps = CABTextSection & SectionDetails;
|
|
162
|
+
//# sourceMappingURL=text.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../src/schema/text.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAgB3B,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,UAAU,CAAC;AAS/C,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;iBA4BrB,CAAC;AAEH,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AAEpD,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAQ1B,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAE9D,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAQzB,CAAC;AAEH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAE5D,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA6BrB,CAAC;AAEP,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAE5D,MAAM,MAAM,mBAAmB,GAAG,cAAc,GAAG,cAAc,CAAC"}
|