@betterstore/react 0.5.25 → 0.6.1
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/components/cart/useCart.d.ts +13 -15
- package/dist/components/cart/useCart.d.ts.map +1 -1
- package/dist/components/checkout-embed/checkout-form.d.ts +2 -1
- package/dist/components/checkout-embed/checkout-form.d.ts.map +1 -1
- package/dist/components/checkout-embed/checkout-schema.d.ts +48 -36
- package/dist/components/checkout-embed/checkout-schema.d.ts.map +1 -1
- package/dist/components/checkout-embed/index.d.ts.map +1 -1
- package/dist/components/checkout-embed/steps/shipping/form.d.ts +1 -2
- package/dist/components/checkout-embed/steps/shipping/form.d.ts.map +1 -1
- package/dist/components/checkout-embed/steps/summary/index.d.ts +2 -2
- package/dist/components/checkout-embed/steps/summary/index.d.ts.map +1 -1
- package/dist/components/compounds/form/address-input/index.d.ts.map +1 -1
- package/dist/components/ui/button.d.ts +2 -2
- package/dist/index.cjs.js +10537 -9576
- package/dist/index.mjs +10537 -9576
- package/package.json +5 -5
- package/dist/lib/betterstore.d.ts +0 -6
- package/dist/lib/betterstore.d.ts.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { DefaultLineItemCreateProductType, LineItemCreate as SDKLineItemCreate } from "@betterstore/bridge";
|
|
2
2
|
type LineItemOptionalParams = {
|
|
3
3
|
quantity?: number;
|
|
4
4
|
variantOptions?: {
|
|
@@ -7,31 +7,29 @@ type LineItemOptionalParams = {
|
|
|
7
7
|
}[];
|
|
8
8
|
metadata?: Record<string, any>;
|
|
9
9
|
};
|
|
10
|
-
export interface CartLineItem extends Pick<SDKLineItemCreate
|
|
10
|
+
export interface CartLineItem<ProductType extends DefaultLineItemCreateProductType = DefaultLineItemCreateProductType> extends Pick<SDKLineItemCreate<ProductType>, "metadata" | "quantity" | "variantOptions" | "productId" | "product"> {
|
|
11
11
|
id: string;
|
|
12
|
-
selectedVariant:
|
|
12
|
+
selectedVariant: NonNullable<NonNullable<ProductType["productVariants"]>[number]> | null;
|
|
13
13
|
}
|
|
14
|
-
export interface Cart {
|
|
15
|
-
lineItems: CartLineItem[];
|
|
16
|
-
addItem: (product:
|
|
17
|
-
productVariants?: Product["productVariants"];
|
|
18
|
-
}, additionalParams?: LineItemOptionalParams) => void;
|
|
14
|
+
export interface Cart<ProductType extends DefaultLineItemCreateProductType = DefaultLineItemCreateProductType> {
|
|
15
|
+
lineItems: CartLineItem<ProductType>[];
|
|
16
|
+
addItem: (product: ProductType, additionalParams?: LineItemOptionalParams) => void;
|
|
19
17
|
removeItem: (id: string) => void;
|
|
20
18
|
updateQuantity: (id: string, quantity: number) => void;
|
|
21
19
|
getProductQuantity: (productId: string) => number;
|
|
22
20
|
clearCart: () => void;
|
|
23
21
|
}
|
|
24
|
-
export declare const useCart: import("zustand").UseBoundStore<Omit<import("zustand").StoreApi<Cart
|
|
25
|
-
setState(partial: Cart | Partial<Cart
|
|
26
|
-
setState(state: Cart | ((state: Cart) => Cart), replace: true): unknown;
|
|
22
|
+
export declare const useCart: <ProductType extends DefaultLineItemCreateProductType = DefaultLineItemCreateProductType>() => import("zustand").UseBoundStore<Omit<import("zustand").StoreApi<Cart<ProductType>>, "setState" | "persist"> & {
|
|
23
|
+
setState(partial: Cart<ProductType> | Partial<Cart<ProductType>> | ((state: Cart<ProductType>) => Cart<ProductType> | Partial<Cart<ProductType>>), replace?: false | undefined): unknown;
|
|
24
|
+
setState(state: Cart<ProductType> | ((state: Cart<ProductType>) => Cart<ProductType>), replace: true): unknown;
|
|
27
25
|
persist: {
|
|
28
|
-
setOptions: (options: Partial<import("zustand/middleware").PersistOptions<Cart
|
|
26
|
+
setOptions: (options: Partial<import("zustand/middleware").PersistOptions<Cart<ProductType>, Cart<ProductType>, unknown>>) => void;
|
|
29
27
|
clearStorage: () => void;
|
|
30
28
|
rehydrate: () => Promise<void> | void;
|
|
31
29
|
hasHydrated: () => boolean;
|
|
32
|
-
onHydrate: (fn: (state: Cart) => void) => () => void;
|
|
33
|
-
onFinishHydration: (fn: (state: Cart) => void) => () => void;
|
|
34
|
-
getOptions: () => Partial<import("zustand/middleware").PersistOptions<Cart
|
|
30
|
+
onHydrate: (fn: (state: Cart<ProductType>) => void) => () => void;
|
|
31
|
+
onFinishHydration: (fn: (state: Cart<ProductType>) => void) => () => void;
|
|
32
|
+
getOptions: () => Partial<import("zustand/middleware").PersistOptions<Cart<ProductType>, Cart<ProductType>, unknown>>;
|
|
35
33
|
};
|
|
36
34
|
}>;
|
|
37
35
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useCart.d.ts","sourceRoot":"","sources":["../../../src/components/cart/useCart.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"useCart.d.ts","sourceRoot":"","sources":["../../../src/components/cart/useCart.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gCAAgC,EAChC,cAAc,IAAI,iBAAiB,EACpC,MAAM,qBAAqB,CAAC;AAI7B,KAAK,sBAAsB,GAAG;IAC5B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,cAAc,CAAC,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IACnD,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CAChC,CAAC;AAEF,MAAM,WAAW,YAAY,CAC3B,WAAW,SACT,gCAAgC,GAAG,gCAAgC,CACrE,SAAQ,IAAI,CACV,iBAAiB,CAAC,WAAW,CAAC,EAC9B,UAAU,GAAG,UAAU,GAAG,gBAAgB,GAAG,WAAW,GAAG,SAAS,CACrE;IACD,EAAE,EAAE,MAAM,CAAC;IACX,eAAe,EAAE,WAAW,CAC1B,WAAW,CAAC,WAAW,CAAC,iBAAiB,CAAC,CAAC,CAAC,MAAM,CAAC,CACpD,GAAG,IAAI,CAAC;CACV;AAED,MAAM,WAAW,IAAI,CACnB,WAAW,SACT,gCAAgC,GAAG,gCAAgC;IAErE,SAAS,EAAE,YAAY,CAAC,WAAW,CAAC,EAAE,CAAC;IACvC,OAAO,EAAE,CACP,OAAO,EAAE,WAAW,EACpB,gBAAgB,CAAC,EAAE,sBAAsB,KACtC,IAAI,CAAC;IACV,UAAU,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IACjC,cAAc,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IACvD,kBAAkB,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,MAAM,CAAC;IAClD,SAAS,EAAE,MAAM,IAAI,CAAC;CACvB;AAcD,eAAO,MAAM,OAAO,GAClB,WAAW,SACT,gCAAgC,GAAG,gCAAgC;;;;;;;;;;;;EA4EpE,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { CheckoutSession
|
|
1
|
+
import { CheckoutSession } from "@betterstore/bridge";
|
|
2
|
+
import { createStoreClient } from "@betterstore/sdk";
|
|
2
3
|
import { StripeElementLocale } from "@stripe/stripe-js";
|
|
3
4
|
import { AppearanceConfig, Fonts } from "./appearance";
|
|
4
5
|
interface CheckoutFormProps {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkout-form.d.ts","sourceRoot":"","sources":["../../../src/components/checkout-embed/checkout-form.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"checkout-form.d.ts","sourceRoot":"","sources":["../../../src/components/checkout-embed/checkout-form.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EAGhB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAExD,OAAO,EAAE,gBAAgB,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAcvD,UAAU,iBAAiB;IACzB,WAAW,EAAE,UAAU,CAAC,OAAO,iBAAiB,CAAC,CAAC;IAClD,UAAU,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,eAAe,CAAC,UAAU,CAAC,CAAC;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,kBAAkB,CAAC,EAAE,gBAAgB,CAAC;IACtC,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,MAAM,CAAC,EAAE,mBAAmB,CAAC;IAC7B,eAAe,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,YAAY,EAAE,MAAM,CAAC;IACrB,aAAa,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,mBAAmB,EAAE,MAAM,CAAC;IAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,SAAS,EAAE,eAAe,CAAC,WAAW,CAAC,CAAC;CACzC;AAED,MAAM,CAAC,OAAO,UAAU,YAAY,CAAC,EACnC,WAAW,EACX,UAAU,EACV,SAAS,EACT,OAAO,EACP,SAAS,EACT,YAAY,EACZ,QAAQ,EACR,QAAQ,EACR,kBAAkB,EAClB,KAAK,EACL,MAAM,EACN,eAAe,EACf,YAAY,EACZ,aAAa,EACb,SAAS,EACT,mBAAmB,EACnB,WAAW,EACX,QAAQ,EACR,SAAS,EACT,wBAAwB,EACxB,SAAS,GACV,EAAE,iBAAiB,2CAkSnB"}
|
|
@@ -5,44 +5,48 @@ export declare const customerSchema: z.ZodObject<{
|
|
|
5
5
|
lastName: z.ZodString;
|
|
6
6
|
address: z.ZodObject<{
|
|
7
7
|
line1: z.ZodString;
|
|
8
|
-
line2: z.
|
|
8
|
+
line2: z.ZodNullable<z.ZodString>;
|
|
9
9
|
city: z.ZodString;
|
|
10
|
-
province: z.
|
|
11
|
-
provinceCode: z.
|
|
10
|
+
province: z.ZodNullable<z.ZodString>;
|
|
11
|
+
provinceCode: z.ZodNullable<z.ZodString>;
|
|
12
12
|
zipCode: z.ZodString;
|
|
13
13
|
country: z.ZodString;
|
|
14
14
|
countryCode: z.ZodString;
|
|
15
|
+
company: z.ZodNullable<z.ZodString>;
|
|
15
16
|
}, "strip", z.ZodTypeAny, {
|
|
16
17
|
line1: string;
|
|
18
|
+
line2: string | null;
|
|
17
19
|
city: string;
|
|
20
|
+
province: string | null;
|
|
21
|
+
provinceCode: string | null;
|
|
18
22
|
zipCode: string;
|
|
19
23
|
country: string;
|
|
20
24
|
countryCode: string;
|
|
21
|
-
|
|
22
|
-
province?: string | undefined;
|
|
23
|
-
provinceCode?: string | undefined;
|
|
25
|
+
company: string | null;
|
|
24
26
|
}, {
|
|
25
27
|
line1: string;
|
|
28
|
+
line2: string | null;
|
|
26
29
|
city: string;
|
|
30
|
+
province: string | null;
|
|
31
|
+
provinceCode: string | null;
|
|
27
32
|
zipCode: string;
|
|
28
33
|
country: string;
|
|
29
34
|
countryCode: string;
|
|
30
|
-
|
|
31
|
-
province?: string | undefined;
|
|
32
|
-
provinceCode?: string | undefined;
|
|
35
|
+
company: string | null;
|
|
33
36
|
}>;
|
|
34
37
|
phone: z.ZodString;
|
|
35
38
|
isEmailSubscribed: z.ZodOptional<z.ZodBoolean>;
|
|
36
39
|
}, "strip", z.ZodTypeAny, {
|
|
37
40
|
address: {
|
|
38
41
|
line1: string;
|
|
42
|
+
line2: string | null;
|
|
39
43
|
city: string;
|
|
44
|
+
province: string | null;
|
|
45
|
+
provinceCode: string | null;
|
|
40
46
|
zipCode: string;
|
|
41
47
|
country: string;
|
|
42
48
|
countryCode: string;
|
|
43
|
-
|
|
44
|
-
province?: string | undefined;
|
|
45
|
-
provinceCode?: string | undefined;
|
|
49
|
+
company: string | null;
|
|
46
50
|
};
|
|
47
51
|
email: string;
|
|
48
52
|
firstName: string;
|
|
@@ -52,13 +56,14 @@ export declare const customerSchema: z.ZodObject<{
|
|
|
52
56
|
}, {
|
|
53
57
|
address: {
|
|
54
58
|
line1: string;
|
|
59
|
+
line2: string | null;
|
|
55
60
|
city: string;
|
|
61
|
+
province: string | null;
|
|
62
|
+
provinceCode: string | null;
|
|
56
63
|
zipCode: string;
|
|
57
64
|
country: string;
|
|
58
65
|
countryCode: string;
|
|
59
|
-
|
|
60
|
-
province?: string | undefined;
|
|
61
|
-
provinceCode?: string | undefined;
|
|
66
|
+
company: string | null;
|
|
62
67
|
};
|
|
63
68
|
email: string;
|
|
64
69
|
firstName: string;
|
|
@@ -109,44 +114,48 @@ export declare const checkoutSchema: z.ZodObject<{
|
|
|
109
114
|
lastName: z.ZodString;
|
|
110
115
|
address: z.ZodObject<{
|
|
111
116
|
line1: z.ZodString;
|
|
112
|
-
line2: z.
|
|
117
|
+
line2: z.ZodNullable<z.ZodString>;
|
|
113
118
|
city: z.ZodString;
|
|
114
|
-
province: z.
|
|
115
|
-
provinceCode: z.
|
|
119
|
+
province: z.ZodNullable<z.ZodString>;
|
|
120
|
+
provinceCode: z.ZodNullable<z.ZodString>;
|
|
116
121
|
zipCode: z.ZodString;
|
|
117
122
|
country: z.ZodString;
|
|
118
123
|
countryCode: z.ZodString;
|
|
124
|
+
company: z.ZodNullable<z.ZodString>;
|
|
119
125
|
}, "strip", z.ZodTypeAny, {
|
|
120
126
|
line1: string;
|
|
127
|
+
line2: string | null;
|
|
121
128
|
city: string;
|
|
129
|
+
province: string | null;
|
|
130
|
+
provinceCode: string | null;
|
|
122
131
|
zipCode: string;
|
|
123
132
|
country: string;
|
|
124
133
|
countryCode: string;
|
|
125
|
-
|
|
126
|
-
province?: string | undefined;
|
|
127
|
-
provinceCode?: string | undefined;
|
|
134
|
+
company: string | null;
|
|
128
135
|
}, {
|
|
129
136
|
line1: string;
|
|
137
|
+
line2: string | null;
|
|
130
138
|
city: string;
|
|
139
|
+
province: string | null;
|
|
140
|
+
provinceCode: string | null;
|
|
131
141
|
zipCode: string;
|
|
132
142
|
country: string;
|
|
133
143
|
countryCode: string;
|
|
134
|
-
|
|
135
|
-
province?: string | undefined;
|
|
136
|
-
provinceCode?: string | undefined;
|
|
144
|
+
company: string | null;
|
|
137
145
|
}>;
|
|
138
146
|
phone: z.ZodString;
|
|
139
147
|
isEmailSubscribed: z.ZodOptional<z.ZodBoolean>;
|
|
140
148
|
}, "strip", z.ZodTypeAny, {
|
|
141
149
|
address: {
|
|
142
150
|
line1: string;
|
|
151
|
+
line2: string | null;
|
|
143
152
|
city: string;
|
|
153
|
+
province: string | null;
|
|
154
|
+
provinceCode: string | null;
|
|
144
155
|
zipCode: string;
|
|
145
156
|
country: string;
|
|
146
157
|
countryCode: string;
|
|
147
|
-
|
|
148
|
-
province?: string | undefined;
|
|
149
|
-
provinceCode?: string | undefined;
|
|
158
|
+
company: string | null;
|
|
150
159
|
};
|
|
151
160
|
email: string;
|
|
152
161
|
firstName: string;
|
|
@@ -156,13 +165,14 @@ export declare const checkoutSchema: z.ZodObject<{
|
|
|
156
165
|
}, {
|
|
157
166
|
address: {
|
|
158
167
|
line1: string;
|
|
168
|
+
line2: string | null;
|
|
159
169
|
city: string;
|
|
170
|
+
province: string | null;
|
|
171
|
+
provinceCode: string | null;
|
|
160
172
|
zipCode: string;
|
|
161
173
|
country: string;
|
|
162
174
|
countryCode: string;
|
|
163
|
-
|
|
164
|
-
province?: string | undefined;
|
|
165
|
-
provinceCode?: string | undefined;
|
|
175
|
+
company: string | null;
|
|
166
176
|
};
|
|
167
177
|
email: string;
|
|
168
178
|
firstName: string;
|
|
@@ -211,13 +221,14 @@ export declare const checkoutSchema: z.ZodObject<{
|
|
|
211
221
|
customer: {
|
|
212
222
|
address: {
|
|
213
223
|
line1: string;
|
|
224
|
+
line2: string | null;
|
|
214
225
|
city: string;
|
|
226
|
+
province: string | null;
|
|
227
|
+
provinceCode: string | null;
|
|
215
228
|
zipCode: string;
|
|
216
229
|
country: string;
|
|
217
230
|
countryCode: string;
|
|
218
|
-
|
|
219
|
-
province?: string | undefined;
|
|
220
|
-
provinceCode?: string | undefined;
|
|
231
|
+
company: string | null;
|
|
221
232
|
};
|
|
222
233
|
email: string;
|
|
223
234
|
firstName: string;
|
|
@@ -238,13 +249,14 @@ export declare const checkoutSchema: z.ZodObject<{
|
|
|
238
249
|
customer: {
|
|
239
250
|
address: {
|
|
240
251
|
line1: string;
|
|
252
|
+
line2: string | null;
|
|
241
253
|
city: string;
|
|
254
|
+
province: string | null;
|
|
255
|
+
provinceCode: string | null;
|
|
242
256
|
zipCode: string;
|
|
243
257
|
country: string;
|
|
244
258
|
countryCode: string;
|
|
245
|
-
|
|
246
|
-
province?: string | undefined;
|
|
247
|
-
provinceCode?: string | undefined;
|
|
259
|
+
company: string | null;
|
|
248
260
|
};
|
|
249
261
|
email: string;
|
|
250
262
|
firstName: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkout-schema.d.ts","sourceRoot":"","sources":["../../../src/components/checkout-embed/checkout-schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,eAAO,MAAM,cAAc
|
|
1
|
+
{"version":3,"file":"checkout-schema.d.ts","sourceRoot":"","sources":["../../../src/components/checkout-embed/checkout-schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiBzB,CAAC;AAaH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAK5B,CAAC;AAGL,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAIzB,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/checkout-embed/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAiC,MAAM,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/checkout-embed/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAiC,MAAM,EAAE,MAAM,cAAc,CAAC;AAGrE,OAAO,KAA4C,MAAM,OAAO,CAAC;AAGjE,OAAmB,EAAE,gBAAgB,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAOnE,UAAU,kBAAkB;IAC1B,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE;QACN,YAAY,EAAE,MAAM,CAAC;QACrB,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,EAAE,MAAM,CAAC;QACnB,UAAU,CAAC,EAAE,gBAAgB,CAAC;QAC9B,KAAK,CAAC,EAAE,KAAK,CAAC;QACd,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,WAAW,CAAC,EAAE,MAAM,CAAC;KACtB,CAAC;CACH;AAcD,iBAAS,sBAAsB,CAAC,EAAE,UAAU,EAAE,MAAM,EAAE,EAAE,kBAAkB,2CAuWzE;AAED,QAAA,MAAM,aAAa,0DAA+B,CAAC;AAEnD,OAAO,EAAE,aAAa,EAAE,CAAC"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { GetShippingRatesResponse } from "@betterstore/bridge";
|
|
2
|
-
import { CheckoutSession } from "@betterstore/sdk";
|
|
1
|
+
import { CheckoutSession, GetShippingRatesResponse } from "@betterstore/bridge";
|
|
3
2
|
import { type ShipmentsFormData } from "../../checkout-schema";
|
|
4
3
|
import { FormStore } from "../../useFormStore";
|
|
5
4
|
interface ShipmentsFormProps {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"form.d.ts","sourceRoot":"","sources":["../../../../../src/components/checkout-embed/steps/shipping/form.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"form.d.ts","sourceRoot":"","sources":["../../../../../src/components/checkout-embed/steps/shipping/form.tsx"],"names":[],"mappings":"AAIA,OAAO,EACL,eAAe,EAEf,wBAAwB,EAEzB,MAAM,qBAAqB,CAAC;AAM7B,OAAO,EACL,KAAK,iBAAiB,EAEvB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAG/C,UAAU,kBAAkB;IAC1B,aAAa,EAAE,wBAAwB,CAAC;IACxC,WAAW,CAAC,EAAE,iBAAiB,CAAC;IAChC,QAAQ,EAAE,CAAC,IAAI,EAAE,iBAAiB,KAAK,IAAI,CAAC;IAC5C,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,eAAe,EAAE,MAAM,CAAC;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,EAAE,SAAS,CAAC,aAAa,CAAC,CAAC;IACtC,QAAQ,EAAE,SAAS,CAAC,UAAU,CAAC,CAAC;IAChC,SAAS,EAAE,eAAe,CAAC,WAAW,CAAC,CAAC;CACzC;AAED,MAAM,CAAC,OAAO,UAAU,aAAa,CAAC,EACpC,aAAa,EACb,WAAW,EACX,QAAQ,EACR,MAAM,EACN,YAAY,EACZ,eAAe,EACf,QAAQ,EACR,YAAY,EACZ,MAAM,EACN,WAAW,EACX,WAAW,EACX,QAAQ,EACR,SAAS,GACV,EAAE,kBAAkB,2CA2FpB"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { CheckoutSession
|
|
1
|
+
import { CheckoutSession } from "@betterstore/bridge";
|
|
2
2
|
export default function CheckoutSummary({ appliedDiscounts, lineItems, shipping, tax, currency, onCancel, exchangeRate, applyDiscountCode, removeDiscount, }: {
|
|
3
3
|
appliedDiscounts: CheckoutSession["appliedDiscounts"];
|
|
4
|
-
lineItems:
|
|
4
|
+
lineItems: CheckoutSession["lineItems"];
|
|
5
5
|
shipping?: number | null;
|
|
6
6
|
tax?: number | null;
|
|
7
7
|
currency: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/checkout-embed/steps/summary/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/checkout-embed/steps/summary/index.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAe,MAAM,qBAAqB,CAAC;AAOnE,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,EACtC,gBAAgB,EAChB,SAAS,EACT,QAAQ,EACR,GAAG,EACH,QAAQ,EACR,QAAQ,EACR,YAAY,EACZ,iBAAiB,EACjB,cAAc,GACf,EAAE;IACD,gBAAgB,EAAE,eAAe,CAAC,kBAAkB,CAAC,CAAC;IACtD,SAAS,EAAE,eAAe,CAAC,WAAW,CAAC,CAAC;IACxC,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,GAAG,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,iBAAiB,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;IACnD,cAAc,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CAC/C,2CA0QA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/compounds/form/address-input/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/components/compounds/form/address-input/index.tsx"],"names":[],"mappings":"AAgBA,UAAU,iBAAiB;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,wBAAgB,YAAY,CAAC,EAC3B,SAAc,EACd,KAAK,EACL,YAAY,EACZ,QAAQ,EACR,SAAS,EACT,wBAAwB,EACxB,MAAM,GACP,EAAE,iBAAiB,2CA8SnB"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type VariantProps } from "class-variance-authority";
|
|
2
2
|
import * as React from "react";
|
|
3
3
|
declare const buttonVariants: (props?: ({
|
|
4
|
-
variant?: "
|
|
5
|
-
size?: "
|
|
4
|
+
variant?: "default" | "link" | "outline" | "destructive" | "secondary" | "ghost" | null | undefined;
|
|
5
|
+
size?: "default" | "link" | "sm" | "lg" | "icon" | null | undefined;
|
|
6
6
|
} & import("class-variance-authority/dist/types").ClassProp) | undefined) => string;
|
|
7
7
|
declare function Button({ className, variant, size, asChild, ...props }: React.ComponentProps<"button"> & VariantProps<typeof buttonVariants> & {
|
|
8
8
|
asChild?: boolean;
|