@thorprovider/blocks 0.1.2 → 1.0.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.
Files changed (111) hide show
  1. package/CHANGELOG.md +107 -0
  2. package/README.md +108 -23
  3. package/docs/standards/data-contracts.md +13 -2
  4. package/package.json +26 -10
  5. package/scripts/fix-esm-extensions.mjs +40 -0
  6. package/src/blocks/e-commerce/navigation/back-to-top.test.tsx +27 -0
  7. package/src/blocks/e-commerce/navigation/back-to-top.tsx +71 -0
  8. package/src/blocks/e-commerce/navigation/breadcrumb.test.tsx +174 -0
  9. package/src/blocks/e-commerce/navigation/breadcrumb.tsx +130 -0
  10. package/src/blocks/e-commerce/navigation/mobile-bottom-nav.test.tsx +74 -0
  11. package/src/blocks/e-commerce/navigation/mobile-bottom-nav.tsx +78 -0
  12. package/src/blocks/e-commerce/navigation/skip-to-content.test.tsx +35 -0
  13. package/src/blocks/e-commerce/navigation/skip-to-content.tsx +37 -0
  14. package/src/blocks/e-commerce/product-categories/category-card-grid.test.tsx +122 -0
  15. package/src/blocks/e-commerce/product-categories/category-card.test.tsx +68 -0
  16. package/src/blocks/e-commerce/product-categories/category-card.tsx +172 -0
  17. package/src/blocks/e-commerce/product-categories/category-grid.test.tsx +67 -0
  18. package/src/blocks/e-commerce/product-categories/category-shared.tsx +109 -0
  19. package/src/blocks/e-commerce/product-categories/product-category-grid.tsx +170 -0
  20. package/src/blocks/e-commerce/product-categories/product-category.test.tsx +266 -0
  21. package/src/blocks/e-commerce/product-categories/product-category.tsx +462 -0
  22. package/src/blocks/e-commerce/product-list/product-card.test.tsx +263 -0
  23. package/src/blocks/e-commerce/product-list/product-card.tsx +424 -0
  24. package/src/blocks/e-commerce/product-list/product-grid.test.tsx +162 -0
  25. package/src/blocks/e-commerce/product-list/product-grid.tsx +114 -0
  26. package/src/blocks/e-commerce/product-list/product-showcase-1.test.tsx +78 -0
  27. package/src/blocks/e-commerce/product-list/product-showcase-1.tsx +277 -0
  28. package/src/blocks/e-commerce/product-overview/product-overview-gallery.tsx +71 -0
  29. package/src/blocks/e-commerce/product-overview/{product-overview-5-lightbox-tab.tsx → product-overview-lightbox-tab.tsx} +35 -23
  30. package/src/blocks/e-commerce/product-overview/{product-overview-5-reviews-tab.tsx → product-overview-reviews-tab.tsx} +40 -17
  31. package/src/blocks/e-commerce/product-overview/{product-overview-5-tabs.tsx → product-overview-tabs.tsx} +8 -7
  32. package/src/blocks/e-commerce/product-overview/product-overview.test.tsx +283 -0
  33. package/src/blocks/e-commerce/product-overview/product-overview.tsx +1186 -0
  34. package/src/blocks/e-commerce/reviews/review-rating-2.tsx +5 -6
  35. package/src/blocks/e-commerce/shopping-carts/shopping-cart.test.tsx +399 -0
  36. package/src/blocks/e-commerce/shopping-carts/{shopping-cart-4.tsx → shopping-cart.tsx} +204 -109
  37. package/src/blocks/e-commerce/storefront-hero/storefront-hero.test.tsx +412 -0
  38. package/src/blocks/e-commerce/storefront-hero/storefront-hero.tsx +1283 -0
  39. package/src/blocks/marketing/features/feature.test.tsx +153 -0
  40. package/src/blocks/marketing/features/feature.tsx +195 -0
  41. package/src/blocks/marketing/navbars/navbar-4-account-menu.test.tsx +56 -0
  42. package/src/blocks/marketing/navbars/navbar-4-account-menu.tsx +30 -14
  43. package/src/blocks/marketing/navbars/navbar-4-cart-sheet.test.tsx +150 -0
  44. package/src/blocks/marketing/navbars/navbar-4-cart-sheet.tsx +102 -9
  45. package/src/blocks/marketing/navbars/navbar-4.test.tsx +154 -2
  46. package/src/blocks/marketing/navbars/navbar-4.tsx +152 -32
  47. package/src/index.ts +93 -46
  48. package/src/lib/contracts-curated.test.ts +42 -24
  49. package/src/lib/contracts.test.ts +143 -2
  50. package/src/lib/contracts.ts +395 -13
  51. package/src/ui/button-group.tsx +1 -1
  52. package/src/ui/carousel.tsx +1 -1
  53. package/src/ui/dialog.tsx +1 -1
  54. package/src/ui/field.tsx +2 -2
  55. package/src/ui/input-group.tsx +3 -3
  56. package/src/ui/pagination.tsx +1 -1
  57. package/src/ui/sidebar.tsx +7 -7
  58. package/src/ui/toggle-group.tsx +1 -1
  59. package/tsconfig.build.json +12 -0
  60. package/tsup.config.ts +11 -7
  61. package/.turbo/turbo-build.log +0 -24
  62. package/.turbo/turbo-test.log +0 -37
  63. package/.turbo/turbo-type-check.log +0 -0
  64. package/dist/.tsbuildinfo +0 -1
  65. package/dist/contracts.d.mts +0 -1584
  66. package/dist/contracts.d.ts +0 -1584
  67. package/dist/contracts.js +0 -390
  68. package/dist/contracts.js.map +0 -1
  69. package/dist/contracts.mjs +0 -334
  70. package/dist/contracts.mjs.map +0 -1
  71. package/dist/index.d.mts +0 -2786
  72. package/dist/index.d.ts +0 -2786
  73. package/dist/index.js +0 -17139
  74. package/dist/index.js.map +0 -1
  75. package/dist/index.mjs +0 -17059
  76. package/dist/index.mjs.map +0 -1
  77. package/src/blocks/e-commerce/product-categories/avatar-group.tsx +0 -86
  78. package/src/blocks/e-commerce/product-categories/product-category-1.tsx +0 -126
  79. package/src/blocks/e-commerce/product-categories/product-category-2.test.tsx +0 -51
  80. package/src/blocks/e-commerce/product-categories/product-category-2.tsx +0 -120
  81. package/src/blocks/e-commerce/product-categories/product-category-4.tsx +0 -129
  82. package/src/blocks/e-commerce/product-categories/product-category-5.tsx +0 -218
  83. package/src/blocks/e-commerce/product-list/product-card-1.tsx +0 -131
  84. package/src/blocks/e-commerce/product-list/product-card-2.tsx +0 -71
  85. package/src/blocks/e-commerce/product-list/product-card-3-reaction-toggle.tsx +0 -166
  86. package/src/blocks/e-commerce/product-list/product-card-3.tsx +0 -215
  87. package/src/blocks/e-commerce/product-list/product-card-5-checkbox-check.tsx +0 -98
  88. package/src/blocks/e-commerce/product-list/product-card-5-reaction-toggle.tsx +0 -171
  89. package/src/blocks/e-commerce/product-list/product-card-5.tsx +0 -367
  90. package/src/blocks/e-commerce/product-overview/product-overview-1.test.tsx +0 -182
  91. package/src/blocks/e-commerce/product-overview/product-overview-1.tsx +0 -370
  92. package/src/blocks/e-commerce/product-overview/product-overview-2.tsx +0 -272
  93. package/src/blocks/e-commerce/product-overview/product-overview-5-gallery.tsx +0 -59
  94. package/src/blocks/e-commerce/product-overview/product-overview-5.tsx +0 -274
  95. package/src/blocks/e-commerce/shopping-carts/shopping-cart-1-spinning-counter.tsx +0 -142
  96. package/src/blocks/e-commerce/shopping-carts/shopping-cart-1.tsx +0 -291
  97. package/src/blocks/e-commerce/shopping-carts/shopping-cart-2-item-row.tsx +0 -110
  98. package/src/blocks/e-commerce/shopping-carts/shopping-cart-2-recommendations.tsx +0 -51
  99. package/src/blocks/e-commerce/shopping-carts/shopping-cart-2-spinning-counter.tsx +0 -146
  100. package/src/blocks/e-commerce/shopping-carts/shopping-cart-2.tsx +0 -295
  101. package/src/blocks/e-commerce/shopping-carts/shopping-cart-3-spinning-counter.tsx +0 -142
  102. package/src/blocks/e-commerce/shopping-carts/shopping-cart-3.tsx +0 -342
  103. package/src/blocks/e-commerce/shopping-carts/shopping-cart-4-spinning-counter.tsx +0 -146
  104. package/src/blocks/e-commerce/shopping-carts/shopping-cart-4.test.tsx +0 -137
  105. package/src/blocks/e-commerce/storefront-hero/storefront-hero-1.test.tsx +0 -65
  106. package/src/blocks/e-commerce/storefront-hero/storefront-hero-1.tsx +0 -263
  107. package/src/blocks/e-commerce/storefront-hero/storefront-hero-2.tsx +0 -283
  108. package/src/blocks/e-commerce/storefront-hero/storefront-hero-5.tsx +0 -318
  109. package/src/blocks/e-commerce/storefront-hero/storefront-hero-6.tsx +0 -205
  110. package/src/blocks/marketing/features/feature-1.tsx +0 -97
  111. package/src/blocks/marketing/features/feature-2.tsx +0 -82
@@ -1,1584 +0,0 @@
1
- import { z } from 'zod';
2
- import { Money, ProductPreview, PaymentMethod } from '@thorprovider/types';
3
-
4
- /**
5
- * True only for a complete, finite decimal string (`"0"`, `"69.99"`, `"-3.5"`).
6
- * Rejects `""`, `" "`, `"1."`, `".5"`, `"1e3"`, `"abc"`, and non-strings.
7
- */
8
- declare function isCompleteFiniteDecimal(value: unknown): value is string;
9
- /**
10
- * True when a `Money` value is safe to display and price a purchase with: a
11
- * complete finite decimal amount and a non-empty currency code. A valid zero
12
- * (`{ amount: '0', currencyCode: 'USD' }`) is available — zero alone does not
13
- * make a price unavailable.
14
- */
15
- declare function isAvailableMoney(money: Money | null | undefined): money is Money;
16
- /**
17
- * Formats a `Money` for display, or `null` when the value is unavailable.
18
- *
19
- * This is the safety gate the whole curated surface relies on: an absent or
20
- * malformed amount (`""`, `" "`, `"abc"`, a non-string, a missing currency)
21
- * MUST NOT reach `Intl.NumberFormat`, because `Number("")` is `0` and would
22
- * render a fake `$0.00` for missing data. A backend-resolved valid zero
23
- * (`{ amount: "0", currencyCode: "USD" }`) is available and formats as zero.
24
- *
25
- * When no `formatter` is supplied the currency comes from
26
- * `money.currencyCode`, so no currency is hardcoded. Callers render their own
27
- * unavailable/pending/recovery state when this returns `null`.
28
- */
29
- declare function formatMoney(money: Money | null | undefined, formatter?: (money: Money) => string): string | null;
30
-
31
- /**
32
- * Cart line quantity normalization shared by the curated cart surfaces.
33
- *
34
- * The Navbar mini-cart expresses a quantity DELTA while the cart page reports
35
- * an ABSOLUTE quantity. The boundary normalizes the delta against the
36
- * authoritative current line quantity (from the backend cart) before mutating;
37
- * it must never reinterpret one as the other.
38
- */
39
- declare function resolveAbsoluteQuantity(currentQuantity: number, delta: number): number;
40
-
41
- /**
42
- * Serialization contracts for spec-driven storefronts.
43
- *
44
- * These Zod schemas are the *serializable subset* of what a spec may write for
45
- * a block. The component keeps its rich React interface; the catalog/registry
46
- * is the adapter that maps these props to real component props and binds
47
- * callbacks (see storefronts-on-blocks design D3). `z.infer` is the typed
48
- * boundary between spec and catalog — a prop outside the schema is a compile
49
- * error, not a runtime surprise.
50
- *
51
- * Data shapes are projections of the @thorprovider/types canon so that
52
- * @thorprovider/adapters output validates without conflict:
53
- * - Prices are plain numbers here while the canon `Money` is a decimal string
54
- * ({ amount: "45.00", currencyCode }). The projection happens at the
55
- * loader boundary.
56
- * - Blocks use `title` while the canon `ProductPreview` uses `name`. Reconcile
57
- * via the canonical aliases below or the catalog/loader adapter.
58
- */
59
- type CanonMoney = Money;
60
- type CanonProduct = ProductPreview;
61
- /**
62
- * Fallback data-URI for required image fields when the data source has no
63
- * image. Image fields are non-optional `z.string()` in these contracts, so the
64
- * boundary must never emit `""` (React warns about `src=""`); it must emit a
65
- * real, renderable value. Hosts may override with their own branded fallback
66
- * (e.g. electrostore's `CATEGORY_IMAGE_FALLBACK`), but blocks ship a neutral
67
- * one so direct consumers are safe by default.
68
- */
69
- declare const PRODUCT_IMAGE_FALLBACK: string;
70
- /**
71
- * Canonical `Money` (`@thorprovider/types`): a decimal string in major units
72
- * (`"69.99"`), never cents. A missing price is represented by omitting the
73
- * field (or `null` on a nullable field), not by an empty string.
74
- *
75
- * The amount stays a permissive `z.string()` on purpose: an unresolved backend
76
- * price may arrive as the canonical sentinel `""`, and tightening the schema
77
- * would reject the whole view instead of letting the presentation layer render
78
- * an unavailable state. Validity is enforced at render time by
79
- * `isAvailableMoney`/`formatMoney` (a `""`/malformed amount never becomes `$0`).
80
- */
81
- declare const moneySchema: z.ZodType<Money>;
82
- declare const productDetailVariantSchema: z.ZodObject<{
83
- id: z.ZodString;
84
- title: z.ZodString;
85
- sku: z.ZodOptional<z.ZodString>;
86
- availableForSale: z.ZodBoolean;
87
- selectedOptions: z.ZodArray<z.ZodObject<{
88
- name: z.ZodString;
89
- value: z.ZodString;
90
- }, "strip", z.ZodTypeAny, {
91
- value: string;
92
- name: string;
93
- }, {
94
- value: string;
95
- name: string;
96
- }>, "many">;
97
- /** Omit or null when the backend has no resolved price (purchase disabled). */
98
- price: z.ZodOptional<z.ZodNullable<z.ZodType<Money, z.ZodTypeDef, Money>>>;
99
- compareAtPrice: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
100
- image: z.ZodOptional<z.ZodObject<{
101
- id: z.ZodOptional<z.ZodString>;
102
- url: z.ZodString;
103
- altText: z.ZodString;
104
- width: z.ZodOptional<z.ZodNumber>;
105
- height: z.ZodOptional<z.ZodNumber>;
106
- }, "strip", z.ZodTypeAny, {
107
- url: string;
108
- altText: string;
109
- id?: string | undefined;
110
- width?: number | undefined;
111
- height?: number | undefined;
112
- }, {
113
- url: string;
114
- altText: string;
115
- id?: string | undefined;
116
- width?: number | undefined;
117
- height?: number | undefined;
118
- }>>;
119
- }, "strip", z.ZodTypeAny, {
120
- id: string;
121
- title: string;
122
- availableForSale: boolean;
123
- selectedOptions: {
124
- value: string;
125
- name: string;
126
- }[];
127
- sku?: string | undefined;
128
- price?: Money | null | undefined;
129
- compareAtPrice?: Money | undefined;
130
- image?: {
131
- url: string;
132
- altText: string;
133
- id?: string | undefined;
134
- width?: number | undefined;
135
- height?: number | undefined;
136
- } | undefined;
137
- }, {
138
- id: string;
139
- title: string;
140
- availableForSale: boolean;
141
- selectedOptions: {
142
- value: string;
143
- name: string;
144
- }[];
145
- sku?: string | undefined;
146
- price?: Money | null | undefined;
147
- compareAtPrice?: Money | undefined;
148
- image?: {
149
- url: string;
150
- altText: string;
151
- id?: string | undefined;
152
- width?: number | undefined;
153
- height?: number | undefined;
154
- } | undefined;
155
- }>;
156
- type ProductDetailVariantSpec = z.infer<typeof productDetailVariantSchema>;
157
- declare const productDetailProductSchema: z.ZodObject<{
158
- id: z.ZodString;
159
- handle: z.ZodOptional<z.ZodString>;
160
- title: z.ZodString;
161
- description: z.ZodOptional<z.ZodString>;
162
- vendor: z.ZodOptional<z.ZodString>;
163
- options: z.ZodArray<z.ZodObject<{
164
- id: z.ZodString;
165
- name: z.ZodString;
166
- values: z.ZodArray<z.ZodString, "many">;
167
- }, "strip", z.ZodTypeAny, {
168
- values: string[];
169
- id: string;
170
- name: string;
171
- }, {
172
- values: string[];
173
- id: string;
174
- name: string;
175
- }>, "many">;
176
- variants: z.ZodArray<z.ZodObject<{
177
- id: z.ZodString;
178
- title: z.ZodString;
179
- sku: z.ZodOptional<z.ZodString>;
180
- availableForSale: z.ZodBoolean;
181
- selectedOptions: z.ZodArray<z.ZodObject<{
182
- name: z.ZodString;
183
- value: z.ZodString;
184
- }, "strip", z.ZodTypeAny, {
185
- value: string;
186
- name: string;
187
- }, {
188
- value: string;
189
- name: string;
190
- }>, "many">;
191
- /** Omit or null when the backend has no resolved price (purchase disabled). */
192
- price: z.ZodOptional<z.ZodNullable<z.ZodType<Money, z.ZodTypeDef, Money>>>;
193
- compareAtPrice: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
194
- image: z.ZodOptional<z.ZodObject<{
195
- id: z.ZodOptional<z.ZodString>;
196
- url: z.ZodString;
197
- altText: z.ZodString;
198
- width: z.ZodOptional<z.ZodNumber>;
199
- height: z.ZodOptional<z.ZodNumber>;
200
- }, "strip", z.ZodTypeAny, {
201
- url: string;
202
- altText: string;
203
- id?: string | undefined;
204
- width?: number | undefined;
205
- height?: number | undefined;
206
- }, {
207
- url: string;
208
- altText: string;
209
- id?: string | undefined;
210
- width?: number | undefined;
211
- height?: number | undefined;
212
- }>>;
213
- }, "strip", z.ZodTypeAny, {
214
- id: string;
215
- title: string;
216
- availableForSale: boolean;
217
- selectedOptions: {
218
- value: string;
219
- name: string;
220
- }[];
221
- sku?: string | undefined;
222
- price?: Money | null | undefined;
223
- compareAtPrice?: Money | undefined;
224
- image?: {
225
- url: string;
226
- altText: string;
227
- id?: string | undefined;
228
- width?: number | undefined;
229
- height?: number | undefined;
230
- } | undefined;
231
- }, {
232
- id: string;
233
- title: string;
234
- availableForSale: boolean;
235
- selectedOptions: {
236
- value: string;
237
- name: string;
238
- }[];
239
- sku?: string | undefined;
240
- price?: Money | null | undefined;
241
- compareAtPrice?: Money | undefined;
242
- image?: {
243
- url: string;
244
- altText: string;
245
- id?: string | undefined;
246
- width?: number | undefined;
247
- height?: number | undefined;
248
- } | undefined;
249
- }>, "many">;
250
- images: z.ZodArray<z.ZodObject<{
251
- id: z.ZodOptional<z.ZodString>;
252
- url: z.ZodString;
253
- altText: z.ZodString;
254
- width: z.ZodOptional<z.ZodNumber>;
255
- height: z.ZodOptional<z.ZodNumber>;
256
- }, "strip", z.ZodTypeAny, {
257
- url: string;
258
- altText: string;
259
- id?: string | undefined;
260
- width?: number | undefined;
261
- height?: number | undefined;
262
- }, {
263
- url: string;
264
- altText: string;
265
- id?: string | undefined;
266
- width?: number | undefined;
267
- height?: number | undefined;
268
- }>, "many">;
269
- featuredImage: z.ZodOptional<z.ZodObject<{
270
- id: z.ZodOptional<z.ZodString>;
271
- url: z.ZodString;
272
- altText: z.ZodString;
273
- width: z.ZodOptional<z.ZodNumber>;
274
- height: z.ZodOptional<z.ZodNumber>;
275
- }, "strip", z.ZodTypeAny, {
276
- url: string;
277
- altText: string;
278
- id?: string | undefined;
279
- width?: number | undefined;
280
- height?: number | undefined;
281
- }, {
282
- url: string;
283
- altText: string;
284
- id?: string | undefined;
285
- width?: number | undefined;
286
- height?: number | undefined;
287
- }>>;
288
- }, "strip", z.ZodTypeAny, {
289
- options: {
290
- values: string[];
291
- id: string;
292
- name: string;
293
- }[];
294
- id: string;
295
- title: string;
296
- variants: {
297
- id: string;
298
- title: string;
299
- availableForSale: boolean;
300
- selectedOptions: {
301
- value: string;
302
- name: string;
303
- }[];
304
- sku?: string | undefined;
305
- price?: Money | null | undefined;
306
- compareAtPrice?: Money | undefined;
307
- image?: {
308
- url: string;
309
- altText: string;
310
- id?: string | undefined;
311
- width?: number | undefined;
312
- height?: number | undefined;
313
- } | undefined;
314
- }[];
315
- images: {
316
- url: string;
317
- altText: string;
318
- id?: string | undefined;
319
- width?: number | undefined;
320
- height?: number | undefined;
321
- }[];
322
- handle?: string | undefined;
323
- description?: string | undefined;
324
- vendor?: string | undefined;
325
- featuredImage?: {
326
- url: string;
327
- altText: string;
328
- id?: string | undefined;
329
- width?: number | undefined;
330
- height?: number | undefined;
331
- } | undefined;
332
- }, {
333
- options: {
334
- values: string[];
335
- id: string;
336
- name: string;
337
- }[];
338
- id: string;
339
- title: string;
340
- variants: {
341
- id: string;
342
- title: string;
343
- availableForSale: boolean;
344
- selectedOptions: {
345
- value: string;
346
- name: string;
347
- }[];
348
- sku?: string | undefined;
349
- price?: Money | null | undefined;
350
- compareAtPrice?: Money | undefined;
351
- image?: {
352
- url: string;
353
- altText: string;
354
- id?: string | undefined;
355
- width?: number | undefined;
356
- height?: number | undefined;
357
- } | undefined;
358
- }[];
359
- images: {
360
- url: string;
361
- altText: string;
362
- id?: string | undefined;
363
- width?: number | undefined;
364
- height?: number | undefined;
365
- }[];
366
- handle?: string | undefined;
367
- description?: string | undefined;
368
- vendor?: string | undefined;
369
- featuredImage?: {
370
- url: string;
371
- altText: string;
372
- id?: string | undefined;
373
- width?: number | undefined;
374
- height?: number | undefined;
375
- } | undefined;
376
- }>;
377
- type ProductDetailProductSpec = z.infer<typeof productDetailProductSchema>;
378
- declare const productOverview1PropsSchema: z.ZodObject<{
379
- product: z.ZodObject<{
380
- id: z.ZodString;
381
- handle: z.ZodOptional<z.ZodString>;
382
- title: z.ZodString;
383
- description: z.ZodOptional<z.ZodString>;
384
- vendor: z.ZodOptional<z.ZodString>;
385
- options: z.ZodArray<z.ZodObject<{
386
- id: z.ZodString;
387
- name: z.ZodString;
388
- values: z.ZodArray<z.ZodString, "many">;
389
- }, "strip", z.ZodTypeAny, {
390
- values: string[];
391
- id: string;
392
- name: string;
393
- }, {
394
- values: string[];
395
- id: string;
396
- name: string;
397
- }>, "many">;
398
- variants: z.ZodArray<z.ZodObject<{
399
- id: z.ZodString;
400
- title: z.ZodString;
401
- sku: z.ZodOptional<z.ZodString>;
402
- availableForSale: z.ZodBoolean;
403
- selectedOptions: z.ZodArray<z.ZodObject<{
404
- name: z.ZodString;
405
- value: z.ZodString;
406
- }, "strip", z.ZodTypeAny, {
407
- value: string;
408
- name: string;
409
- }, {
410
- value: string;
411
- name: string;
412
- }>, "many">;
413
- /** Omit or null when the backend has no resolved price (purchase disabled). */
414
- price: z.ZodOptional<z.ZodNullable<z.ZodType<Money, z.ZodTypeDef, Money>>>;
415
- compareAtPrice: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
416
- image: z.ZodOptional<z.ZodObject<{
417
- id: z.ZodOptional<z.ZodString>;
418
- url: z.ZodString;
419
- altText: z.ZodString;
420
- width: z.ZodOptional<z.ZodNumber>;
421
- height: z.ZodOptional<z.ZodNumber>;
422
- }, "strip", z.ZodTypeAny, {
423
- url: string;
424
- altText: string;
425
- id?: string | undefined;
426
- width?: number | undefined;
427
- height?: number | undefined;
428
- }, {
429
- url: string;
430
- altText: string;
431
- id?: string | undefined;
432
- width?: number | undefined;
433
- height?: number | undefined;
434
- }>>;
435
- }, "strip", z.ZodTypeAny, {
436
- id: string;
437
- title: string;
438
- availableForSale: boolean;
439
- selectedOptions: {
440
- value: string;
441
- name: string;
442
- }[];
443
- sku?: string | undefined;
444
- price?: Money | null | undefined;
445
- compareAtPrice?: Money | undefined;
446
- image?: {
447
- url: string;
448
- altText: string;
449
- id?: string | undefined;
450
- width?: number | undefined;
451
- height?: number | undefined;
452
- } | undefined;
453
- }, {
454
- id: string;
455
- title: string;
456
- availableForSale: boolean;
457
- selectedOptions: {
458
- value: string;
459
- name: string;
460
- }[];
461
- sku?: string | undefined;
462
- price?: Money | null | undefined;
463
- compareAtPrice?: Money | undefined;
464
- image?: {
465
- url: string;
466
- altText: string;
467
- id?: string | undefined;
468
- width?: number | undefined;
469
- height?: number | undefined;
470
- } | undefined;
471
- }>, "many">;
472
- images: z.ZodArray<z.ZodObject<{
473
- id: z.ZodOptional<z.ZodString>;
474
- url: z.ZodString;
475
- altText: z.ZodString;
476
- width: z.ZodOptional<z.ZodNumber>;
477
- height: z.ZodOptional<z.ZodNumber>;
478
- }, "strip", z.ZodTypeAny, {
479
- url: string;
480
- altText: string;
481
- id?: string | undefined;
482
- width?: number | undefined;
483
- height?: number | undefined;
484
- }, {
485
- url: string;
486
- altText: string;
487
- id?: string | undefined;
488
- width?: number | undefined;
489
- height?: number | undefined;
490
- }>, "many">;
491
- featuredImage: z.ZodOptional<z.ZodObject<{
492
- id: z.ZodOptional<z.ZodString>;
493
- url: z.ZodString;
494
- altText: z.ZodString;
495
- width: z.ZodOptional<z.ZodNumber>;
496
- height: z.ZodOptional<z.ZodNumber>;
497
- }, "strip", z.ZodTypeAny, {
498
- url: string;
499
- altText: string;
500
- id?: string | undefined;
501
- width?: number | undefined;
502
- height?: number | undefined;
503
- }, {
504
- url: string;
505
- altText: string;
506
- id?: string | undefined;
507
- width?: number | undefined;
508
- height?: number | undefined;
509
- }>>;
510
- }, "strip", z.ZodTypeAny, {
511
- options: {
512
- values: string[];
513
- id: string;
514
- name: string;
515
- }[];
516
- id: string;
517
- title: string;
518
- variants: {
519
- id: string;
520
- title: string;
521
- availableForSale: boolean;
522
- selectedOptions: {
523
- value: string;
524
- name: string;
525
- }[];
526
- sku?: string | undefined;
527
- price?: Money | null | undefined;
528
- compareAtPrice?: Money | undefined;
529
- image?: {
530
- url: string;
531
- altText: string;
532
- id?: string | undefined;
533
- width?: number | undefined;
534
- height?: number | undefined;
535
- } | undefined;
536
- }[];
537
- images: {
538
- url: string;
539
- altText: string;
540
- id?: string | undefined;
541
- width?: number | undefined;
542
- height?: number | undefined;
543
- }[];
544
- handle?: string | undefined;
545
- description?: string | undefined;
546
- vendor?: string | undefined;
547
- featuredImage?: {
548
- url: string;
549
- altText: string;
550
- id?: string | undefined;
551
- width?: number | undefined;
552
- height?: number | undefined;
553
- } | undefined;
554
- }, {
555
- options: {
556
- values: string[];
557
- id: string;
558
- name: string;
559
- }[];
560
- id: string;
561
- title: string;
562
- variants: {
563
- id: string;
564
- title: string;
565
- availableForSale: boolean;
566
- selectedOptions: {
567
- value: string;
568
- name: string;
569
- }[];
570
- sku?: string | undefined;
571
- price?: Money | null | undefined;
572
- compareAtPrice?: Money | undefined;
573
- image?: {
574
- url: string;
575
- altText: string;
576
- id?: string | undefined;
577
- width?: number | undefined;
578
- height?: number | undefined;
579
- } | undefined;
580
- }[];
581
- images: {
582
- url: string;
583
- altText: string;
584
- id?: string | undefined;
585
- width?: number | undefined;
586
- height?: number | undefined;
587
- }[];
588
- handle?: string | undefined;
589
- description?: string | undefined;
590
- vendor?: string | undefined;
591
- featuredImage?: {
592
- url: string;
593
- altText: string;
594
- id?: string | undefined;
595
- width?: number | undefined;
596
- height?: number | undefined;
597
- } | undefined;
598
- }>;
599
- selectedVariantId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
600
- quantity: z.ZodOptional<z.ZodNumber>;
601
- rating: z.ZodOptional<z.ZodObject<{
602
- value: z.ZodNumber;
603
- count: z.ZodNumber;
604
- }, "strip", z.ZodTypeAny, {
605
- value: number;
606
- count: number;
607
- }, {
608
- value: number;
609
- count: number;
610
- }>>;
611
- deliveryEstimate: z.ZodOptional<z.ZodString>;
612
- shipping: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
613
- sizesLabel: z.ZodOptional<z.ZodString>;
614
- variantLabel: z.ZodOptional<z.ZodString>;
615
- reviewsLabel: z.ZodOptional<z.ZodString>;
616
- addToCartLabel: z.ZodOptional<z.ZodString>;
617
- outOfStockLabel: z.ZodOptional<z.ZodString>;
618
- unavailablePriceLabel: z.ZodOptional<z.ZodString>;
619
- selectVariantLabel: z.ZodOptional<z.ZodString>;
620
- quantityLabel: z.ZodOptional<z.ZodString>;
621
- deliveryEstimateLabel: z.ZodOptional<z.ZodString>;
622
- shippingLabel: z.ZodOptional<z.ZodString>;
623
- }, "strip", z.ZodTypeAny, {
624
- product: {
625
- options: {
626
- values: string[];
627
- id: string;
628
- name: string;
629
- }[];
630
- id: string;
631
- title: string;
632
- variants: {
633
- id: string;
634
- title: string;
635
- availableForSale: boolean;
636
- selectedOptions: {
637
- value: string;
638
- name: string;
639
- }[];
640
- sku?: string | undefined;
641
- price?: Money | null | undefined;
642
- compareAtPrice?: Money | undefined;
643
- image?: {
644
- url: string;
645
- altText: string;
646
- id?: string | undefined;
647
- width?: number | undefined;
648
- height?: number | undefined;
649
- } | undefined;
650
- }[];
651
- images: {
652
- url: string;
653
- altText: string;
654
- id?: string | undefined;
655
- width?: number | undefined;
656
- height?: number | undefined;
657
- }[];
658
- handle?: string | undefined;
659
- description?: string | undefined;
660
- vendor?: string | undefined;
661
- featuredImage?: {
662
- url: string;
663
- altText: string;
664
- id?: string | undefined;
665
- width?: number | undefined;
666
- height?: number | undefined;
667
- } | undefined;
668
- };
669
- selectedVariantId?: string | null | undefined;
670
- quantity?: number | undefined;
671
- rating?: {
672
- value: number;
673
- count: number;
674
- } | undefined;
675
- deliveryEstimate?: string | undefined;
676
- shipping?: Money | undefined;
677
- sizesLabel?: string | undefined;
678
- variantLabel?: string | undefined;
679
- reviewsLabel?: string | undefined;
680
- addToCartLabel?: string | undefined;
681
- outOfStockLabel?: string | undefined;
682
- unavailablePriceLabel?: string | undefined;
683
- selectVariantLabel?: string | undefined;
684
- quantityLabel?: string | undefined;
685
- deliveryEstimateLabel?: string | undefined;
686
- shippingLabel?: string | undefined;
687
- }, {
688
- product: {
689
- options: {
690
- values: string[];
691
- id: string;
692
- name: string;
693
- }[];
694
- id: string;
695
- title: string;
696
- variants: {
697
- id: string;
698
- title: string;
699
- availableForSale: boolean;
700
- selectedOptions: {
701
- value: string;
702
- name: string;
703
- }[];
704
- sku?: string | undefined;
705
- price?: Money | null | undefined;
706
- compareAtPrice?: Money | undefined;
707
- image?: {
708
- url: string;
709
- altText: string;
710
- id?: string | undefined;
711
- width?: number | undefined;
712
- height?: number | undefined;
713
- } | undefined;
714
- }[];
715
- images: {
716
- url: string;
717
- altText: string;
718
- id?: string | undefined;
719
- width?: number | undefined;
720
- height?: number | undefined;
721
- }[];
722
- handle?: string | undefined;
723
- description?: string | undefined;
724
- vendor?: string | undefined;
725
- featuredImage?: {
726
- url: string;
727
- altText: string;
728
- id?: string | undefined;
729
- width?: number | undefined;
730
- height?: number | undefined;
731
- } | undefined;
732
- };
733
- selectedVariantId?: string | null | undefined;
734
- quantity?: number | undefined;
735
- rating?: {
736
- value: number;
737
- count: number;
738
- } | undefined;
739
- deliveryEstimate?: string | undefined;
740
- shipping?: Money | undefined;
741
- sizesLabel?: string | undefined;
742
- variantLabel?: string | undefined;
743
- reviewsLabel?: string | undefined;
744
- addToCartLabel?: string | undefined;
745
- outOfStockLabel?: string | undefined;
746
- unavailablePriceLabel?: string | undefined;
747
- selectVariantLabel?: string | undefined;
748
- quantityLabel?: string | undefined;
749
- deliveryEstimateLabel?: string | undefined;
750
- shippingLabel?: string | undefined;
751
- }>;
752
- type ProductOverview1SpecProps = z.infer<typeof productOverview1PropsSchema>;
753
- declare const cardProductSchema: z.ZodObject<{
754
- id: z.ZodUnion<[z.ZodString, z.ZodNumber]>;
755
- title: z.ZodString;
756
- price: z.ZodNumber;
757
- originalPrice: z.ZodOptional<z.ZodNumber>;
758
- image: z.ZodString;
759
- badge: z.ZodOptional<z.ZodString>;
760
- }, "strip", z.ZodTypeAny, {
761
- id: string | number;
762
- title: string;
763
- price: number;
764
- image: string;
765
- originalPrice?: number | undefined;
766
- badge?: string | undefined;
767
- }, {
768
- id: string | number;
769
- title: string;
770
- price: number;
771
- image: string;
772
- originalPrice?: number | undefined;
773
- badge?: string | undefined;
774
- }>;
775
- type CardProduct = z.infer<typeof cardProductSchema>;
776
- declare const cartItemSchema: z.ZodObject<{
777
- id: z.ZodString;
778
- name: z.ZodString;
779
- price: z.ZodNumber;
780
- quantity: z.ZodNumber;
781
- /** Optional; absent images are omitted, never serialized as `""`. */
782
- image: z.ZodOptional<z.ZodString>;
783
- variant: z.ZodOptional<z.ZodString>;
784
- /** Canonical backend per-unit price, preferred for display when present. */
785
- unitPrice: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
786
- /** Canonical backend line total, preferred over `price * quantity`. */
787
- lineTotal: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
788
- }, "strip", z.ZodTypeAny, {
789
- id: string;
790
- name: string;
791
- price: number;
792
- quantity: number;
793
- image?: string | undefined;
794
- variant?: string | undefined;
795
- unitPrice?: Money | undefined;
796
- lineTotal?: Money | undefined;
797
- }, {
798
- id: string;
799
- name: string;
800
- price: number;
801
- quantity: number;
802
- image?: string | undefined;
803
- variant?: string | undefined;
804
- unitPrice?: Money | undefined;
805
- lineTotal?: Money | undefined;
806
- }>;
807
- type CartItem = z.infer<typeof cartItemSchema>;
808
- declare const cartTotalsSchema: z.ZodObject<{
809
- subtotal: z.ZodType<Money, z.ZodTypeDef, Money>;
810
- discount: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
811
- tax: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
812
- shipping: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
813
- total: z.ZodType<Money, z.ZodTypeDef, Money>;
814
- }, "strip", z.ZodTypeAny, {
815
- subtotal: Money;
816
- total: Money;
817
- shipping?: Money | undefined;
818
- discount?: Money | undefined;
819
- tax?: Money | undefined;
820
- }, {
821
- subtotal: Money;
822
- total: Money;
823
- shipping?: Money | undefined;
824
- discount?: Money | undefined;
825
- tax?: Money | undefined;
826
- }>;
827
- type CartTotals = z.infer<typeof cartTotalsSchema>;
828
- declare const recentlyViewedItemSchema: z.ZodObject<{
829
- id: z.ZodString;
830
- name: z.ZodString;
831
- price: z.ZodNumber;
832
- image: z.ZodString;
833
- }, "strip", z.ZodTypeAny, {
834
- id: string;
835
- name: string;
836
- price: number;
837
- image: string;
838
- }, {
839
- id: string;
840
- name: string;
841
- price: number;
842
- image: string;
843
- }>;
844
- type RecentlyViewedItem = z.infer<typeof recentlyViewedItemSchema>;
845
- declare const promotionSchema: z.ZodObject<{
846
- threshold: z.ZodNumber;
847
- reward: z.ZodString;
848
- icon: z.ZodDefault<z.ZodString>;
849
- }, "strip", z.ZodTypeAny, {
850
- threshold: number;
851
- reward: string;
852
- icon: string;
853
- }, {
854
- threshold: number;
855
- reward: string;
856
- icon?: string | undefined;
857
- }>;
858
- type Promotion = z.infer<typeof promotionSchema>;
859
- declare const storeCategorySchema: z.ZodType<StoreCategory>;
860
- type StoreCategory = {
861
- label: string;
862
- href: string;
863
- children?: StoreCategory[];
864
- emphasis?: boolean;
865
- };
866
- declare const utilityLinkSchema: z.ZodObject<{
867
- label: z.ZodString;
868
- href: z.ZodString;
869
- }, "strip", z.ZodTypeAny, {
870
- label: string;
871
- href: string;
872
- }, {
873
- label: string;
874
- href: string;
875
- }>;
876
- type UtilityLink = z.infer<typeof utilityLinkSchema>;
877
- declare const navCartItemSchema: z.ZodObject<{
878
- id: z.ZodString;
879
- name: z.ZodString;
880
- variant: z.ZodOptional<z.ZodString>;
881
- price: z.ZodNumber;
882
- qty: z.ZodNumber;
883
- /** Optional; absent images are omitted, never serialized as `""`. */
884
- image: z.ZodOptional<z.ZodString>;
885
- }, "strip", z.ZodTypeAny, {
886
- id: string;
887
- name: string;
888
- price: number;
889
- qty: number;
890
- image?: string | undefined;
891
- variant?: string | undefined;
892
- }, {
893
- id: string;
894
- name: string;
895
- price: number;
896
- qty: number;
897
- image?: string | undefined;
898
- variant?: string | undefined;
899
- }>;
900
- type NavCartItem = z.infer<typeof navCartItemSchema>;
901
- declare const storeUserSchema: z.ZodObject<{
902
- name: z.ZodString;
903
- email: z.ZodString;
904
- avatar: z.ZodString;
905
- initials: z.ZodString;
906
- }, "strip", z.ZodTypeAny, {
907
- name: string;
908
- email: string;
909
- avatar: string;
910
- initials: string;
911
- }, {
912
- name: string;
913
- email: string;
914
- avatar: string;
915
- initials: string;
916
- }>;
917
- type StoreUser = z.infer<typeof storeUserSchema>;
918
- declare const accountMenuItemSchema: z.ZodObject<{
919
- label: z.ZodString;
920
- href: z.ZodString;
921
- description: z.ZodOptional<z.ZodString>;
922
- icon: z.ZodOptional<z.ZodEnum<["orders", "wishlist", "addresses", "settings"]>>;
923
- }, "strip", z.ZodTypeAny, {
924
- label: string;
925
- href: string;
926
- description?: string | undefined;
927
- icon?: "orders" | "wishlist" | "addresses" | "settings" | undefined;
928
- }, {
929
- label: string;
930
- href: string;
931
- description?: string | undefined;
932
- icon?: "orders" | "wishlist" | "addresses" | "settings" | undefined;
933
- }>;
934
- type AccountMenuItem = z.infer<typeof accountMenuItemSchema>;
935
- /**
936
- * Serialization contract for a payment method offered at checkout.
937
- *
938
- * A projection of `@thorprovider/types` `PaymentMethod` — the storefront-facing
939
- * shape produced by the adapters transform. Checkout blocks render the method
940
- * list from this data instead of hardcoding providers.
941
- */
942
- declare const paymentMethodSchema: z.ZodType<PaymentMethod>;
943
- declare const buttonPropsSchema: z.ZodObject<{
944
- variant: z.ZodOptional<z.ZodEnum<["default", "destructive", "outline", "secondary", "ghost", "link"]>>;
945
- size: z.ZodOptional<z.ZodEnum<["default", "xs", "sm", "lg", "icon", "icon-xs", "icon-sm", "icon-lg"]>>;
946
- disabled: z.ZodOptional<z.ZodBoolean>;
947
- className: z.ZodOptional<z.ZodString>;
948
- }, "strip", z.ZodTypeAny, {
949
- variant?: "default" | "destructive" | "outline" | "secondary" | "ghost" | "link" | undefined;
950
- size?: "icon" | "default" | "xs" | "sm" | "lg" | "icon-xs" | "icon-sm" | "icon-lg" | undefined;
951
- disabled?: boolean | undefined;
952
- className?: string | undefined;
953
- }, {
954
- variant?: "default" | "destructive" | "outline" | "secondary" | "ghost" | "link" | undefined;
955
- size?: "icon" | "default" | "xs" | "sm" | "lg" | "icon-xs" | "icon-sm" | "icon-lg" | undefined;
956
- disabled?: boolean | undefined;
957
- className?: string | undefined;
958
- }>;
959
- type ButtonSpecProps = z.infer<typeof buttonPropsSchema>;
960
- declare const storeContainer1PropsSchema: z.ZodObject<{
961
- size: z.ZodOptional<z.ZodEnum<["default", "narrow", "wide", "full"]>>;
962
- className: z.ZodOptional<z.ZodString>;
963
- }, "strip", z.ZodTypeAny, {
964
- size?: "default" | "narrow" | "wide" | "full" | undefined;
965
- className?: string | undefined;
966
- }, {
967
- size?: "default" | "narrow" | "wide" | "full" | undefined;
968
- className?: string | undefined;
969
- }>;
970
- type StoreContainer1SpecProps = z.infer<typeof storeContainer1PropsSchema>;
971
- declare const productCard1PropsSchema: z.ZodObject<{
972
- products: z.ZodArray<z.ZodObject<{
973
- id: z.ZodUnion<[z.ZodString, z.ZodNumber]>;
974
- title: z.ZodString;
975
- price: z.ZodNumber;
976
- originalPrice: z.ZodOptional<z.ZodNumber>;
977
- image: z.ZodString;
978
- badge: z.ZodOptional<z.ZodString>;
979
- }, "strip", z.ZodTypeAny, {
980
- id: string | number;
981
- title: string;
982
- price: number;
983
- image: string;
984
- originalPrice?: number | undefined;
985
- badge?: string | undefined;
986
- }, {
987
- id: string | number;
988
- title: string;
989
- price: number;
990
- image: string;
991
- originalPrice?: number | undefined;
992
- badge?: string | undefined;
993
- }>, "many">;
994
- heading: z.ZodOptional<z.ZodString>;
995
- maxItems: z.ZodOptional<z.ZodNumber>;
996
- }, "strip", z.ZodTypeAny, {
997
- products: {
998
- id: string | number;
999
- title: string;
1000
- price: number;
1001
- image: string;
1002
- originalPrice?: number | undefined;
1003
- badge?: string | undefined;
1004
- }[];
1005
- heading?: string | undefined;
1006
- maxItems?: number | undefined;
1007
- }, {
1008
- products: {
1009
- id: string | number;
1010
- title: string;
1011
- price: number;
1012
- image: string;
1013
- originalPrice?: number | undefined;
1014
- badge?: string | undefined;
1015
- }[];
1016
- heading?: string | undefined;
1017
- maxItems?: number | undefined;
1018
- }>;
1019
- type ProductCard1SpecProps = z.infer<typeof productCard1PropsSchema>;
1020
- declare const shoppingCart4PropsSchema: z.ZodObject<{
1021
- items: z.ZodArray<z.ZodObject<{
1022
- id: z.ZodString;
1023
- name: z.ZodString;
1024
- price: z.ZodNumber;
1025
- quantity: z.ZodNumber;
1026
- /** Optional; absent images are omitted, never serialized as `""`. */
1027
- image: z.ZodOptional<z.ZodString>;
1028
- variant: z.ZodOptional<z.ZodString>;
1029
- /** Canonical backend per-unit price, preferred for display when present. */
1030
- unitPrice: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
1031
- /** Canonical backend line total, preferred over `price * quantity`. */
1032
- lineTotal: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
1033
- }, "strip", z.ZodTypeAny, {
1034
- id: string;
1035
- name: string;
1036
- price: number;
1037
- quantity: number;
1038
- image?: string | undefined;
1039
- variant?: string | undefined;
1040
- unitPrice?: Money | undefined;
1041
- lineTotal?: Money | undefined;
1042
- }, {
1043
- id: string;
1044
- name: string;
1045
- price: number;
1046
- quantity: number;
1047
- image?: string | undefined;
1048
- variant?: string | undefined;
1049
- unitPrice?: Money | undefined;
1050
- lineTotal?: Money | undefined;
1051
- }>, "many">;
1052
- promotions: z.ZodDefault<z.ZodArray<z.ZodObject<{
1053
- threshold: z.ZodNumber;
1054
- reward: z.ZodString;
1055
- icon: z.ZodDefault<z.ZodString>;
1056
- }, "strip", z.ZodTypeAny, {
1057
- threshold: number;
1058
- reward: string;
1059
- icon: string;
1060
- }, {
1061
- threshold: number;
1062
- reward: string;
1063
- icon?: string | undefined;
1064
- }>, "many">>;
1065
- recentlyViewed: z.ZodOptional<z.ZodArray<z.ZodObject<{
1066
- id: z.ZodString;
1067
- name: z.ZodString;
1068
- price: z.ZodNumber;
1069
- image: z.ZodString;
1070
- }, "strip", z.ZodTypeAny, {
1071
- id: string;
1072
- name: string;
1073
- price: number;
1074
- image: string;
1075
- }, {
1076
- id: string;
1077
- name: string;
1078
- price: number;
1079
- image: string;
1080
- }>, "many">>;
1081
- /** Backend-authoritative totals; rendered verbatim, never computed locally. */
1082
- totals: z.ZodOptional<z.ZodObject<{
1083
- subtotal: z.ZodType<Money, z.ZodTypeDef, Money>;
1084
- discount: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
1085
- tax: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
1086
- shipping: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
1087
- total: z.ZodType<Money, z.ZodTypeDef, Money>;
1088
- }, "strip", z.ZodTypeAny, {
1089
- subtotal: Money;
1090
- total: Money;
1091
- shipping?: Money | undefined;
1092
- discount?: Money | undefined;
1093
- tax?: Money | undefined;
1094
- }, {
1095
- subtotal: Money;
1096
- total: Money;
1097
- shipping?: Money | undefined;
1098
- discount?: Money | undefined;
1099
- tax?: Money | undefined;
1100
- }>>;
1101
- totalsState: z.ZodOptional<z.ZodEnum<["idle", "pending", "error"]>>;
1102
- totalsErrorLabel: z.ZodOptional<z.ZodString>;
1103
- totalsUnavailableLabel: z.ZodOptional<z.ZodString>;
1104
- amountUnavailableLabel: z.ZodOptional<z.ZodString>;
1105
- retryLabel: z.ZodOptional<z.ZodString>;
1106
- taxRate: z.ZodOptional<z.ZodNumber>;
1107
- titleLabel: z.ZodOptional<z.ZodString>;
1108
- subtotalLabel: z.ZodOptional<z.ZodString>;
1109
- discountLabel: z.ZodOptional<z.ZodString>;
1110
- taxLabel: z.ZodOptional<z.ZodString>;
1111
- shippingLabel: z.ZodOptional<z.ZodString>;
1112
- shippingFreeLabel: z.ZodOptional<z.ZodString>;
1113
- totalLabel: z.ZodOptional<z.ZodString>;
1114
- totalsPendingLabel: z.ZodOptional<z.ZodString>;
1115
- awayFromLabel: z.ZodOptional<z.ZodString>;
1116
- activatedLabel: z.ZodOptional<z.ZodString>;
1117
- itemsLabel: z.ZodOptional<z.ZodString>;
1118
- expressCheckoutLabel: z.ZodOptional<z.ZodString>;
1119
- expressLabel: z.ZodOptional<z.ZodString>;
1120
- standardLabel: z.ZodOptional<z.ZodString>;
1121
- estimatedDeliveryLabel: z.ZodOptional<z.ZodString>;
1122
- secureCheckoutLabel: z.ZodOptional<z.ZodString>;
1123
- recentlyViewedLabel: z.ZodOptional<z.ZodString>;
1124
- collapseLabel: z.ZodOptional<z.ZodString>;
1125
- expandLabel: z.ZodOptional<z.ZodString>;
1126
- checkoutLabel: z.ZodOptional<z.ZodString>;
1127
- quickCheckoutLabel: z.ZodOptional<z.ZodString>;
1128
- checkoutNowLabel: z.ZodOptional<z.ZodString>;
1129
- emptyLabel: z.ZodOptional<z.ZodString>;
1130
- removeLabel: z.ZodOptional<z.ZodString>;
1131
- decreaseLabel: z.ZodOptional<z.ZodString>;
1132
- increaseLabel: z.ZodOptional<z.ZodString>;
1133
- }, "strip", z.ZodTypeAny, {
1134
- items: {
1135
- id: string;
1136
- name: string;
1137
- price: number;
1138
- quantity: number;
1139
- image?: string | undefined;
1140
- variant?: string | undefined;
1141
- unitPrice?: Money | undefined;
1142
- lineTotal?: Money | undefined;
1143
- }[];
1144
- promotions: {
1145
- threshold: number;
1146
- reward: string;
1147
- icon: string;
1148
- }[];
1149
- shippingLabel?: string | undefined;
1150
- recentlyViewed?: {
1151
- id: string;
1152
- name: string;
1153
- price: number;
1154
- image: string;
1155
- }[] | undefined;
1156
- totals?: {
1157
- subtotal: Money;
1158
- total: Money;
1159
- shipping?: Money | undefined;
1160
- discount?: Money | undefined;
1161
- tax?: Money | undefined;
1162
- } | undefined;
1163
- totalsState?: "idle" | "pending" | "error" | undefined;
1164
- totalsErrorLabel?: string | undefined;
1165
- totalsUnavailableLabel?: string | undefined;
1166
- amountUnavailableLabel?: string | undefined;
1167
- retryLabel?: string | undefined;
1168
- taxRate?: number | undefined;
1169
- titleLabel?: string | undefined;
1170
- subtotalLabel?: string | undefined;
1171
- discountLabel?: string | undefined;
1172
- taxLabel?: string | undefined;
1173
- shippingFreeLabel?: string | undefined;
1174
- totalLabel?: string | undefined;
1175
- totalsPendingLabel?: string | undefined;
1176
- awayFromLabel?: string | undefined;
1177
- activatedLabel?: string | undefined;
1178
- itemsLabel?: string | undefined;
1179
- expressCheckoutLabel?: string | undefined;
1180
- expressLabel?: string | undefined;
1181
- standardLabel?: string | undefined;
1182
- estimatedDeliveryLabel?: string | undefined;
1183
- secureCheckoutLabel?: string | undefined;
1184
- recentlyViewedLabel?: string | undefined;
1185
- collapseLabel?: string | undefined;
1186
- expandLabel?: string | undefined;
1187
- checkoutLabel?: string | undefined;
1188
- quickCheckoutLabel?: string | undefined;
1189
- checkoutNowLabel?: string | undefined;
1190
- emptyLabel?: string | undefined;
1191
- removeLabel?: string | undefined;
1192
- decreaseLabel?: string | undefined;
1193
- increaseLabel?: string | undefined;
1194
- }, {
1195
- items: {
1196
- id: string;
1197
- name: string;
1198
- price: number;
1199
- quantity: number;
1200
- image?: string | undefined;
1201
- variant?: string | undefined;
1202
- unitPrice?: Money | undefined;
1203
- lineTotal?: Money | undefined;
1204
- }[];
1205
- shippingLabel?: string | undefined;
1206
- promotions?: {
1207
- threshold: number;
1208
- reward: string;
1209
- icon?: string | undefined;
1210
- }[] | undefined;
1211
- recentlyViewed?: {
1212
- id: string;
1213
- name: string;
1214
- price: number;
1215
- image: string;
1216
- }[] | undefined;
1217
- totals?: {
1218
- subtotal: Money;
1219
- total: Money;
1220
- shipping?: Money | undefined;
1221
- discount?: Money | undefined;
1222
- tax?: Money | undefined;
1223
- } | undefined;
1224
- totalsState?: "idle" | "pending" | "error" | undefined;
1225
- totalsErrorLabel?: string | undefined;
1226
- totalsUnavailableLabel?: string | undefined;
1227
- amountUnavailableLabel?: string | undefined;
1228
- retryLabel?: string | undefined;
1229
- taxRate?: number | undefined;
1230
- titleLabel?: string | undefined;
1231
- subtotalLabel?: string | undefined;
1232
- discountLabel?: string | undefined;
1233
- taxLabel?: string | undefined;
1234
- shippingFreeLabel?: string | undefined;
1235
- totalLabel?: string | undefined;
1236
- totalsPendingLabel?: string | undefined;
1237
- awayFromLabel?: string | undefined;
1238
- activatedLabel?: string | undefined;
1239
- itemsLabel?: string | undefined;
1240
- expressCheckoutLabel?: string | undefined;
1241
- expressLabel?: string | undefined;
1242
- standardLabel?: string | undefined;
1243
- estimatedDeliveryLabel?: string | undefined;
1244
- secureCheckoutLabel?: string | undefined;
1245
- recentlyViewedLabel?: string | undefined;
1246
- collapseLabel?: string | undefined;
1247
- expandLabel?: string | undefined;
1248
- checkoutLabel?: string | undefined;
1249
- quickCheckoutLabel?: string | undefined;
1250
- checkoutNowLabel?: string | undefined;
1251
- emptyLabel?: string | undefined;
1252
- removeLabel?: string | undefined;
1253
- decreaseLabel?: string | undefined;
1254
- increaseLabel?: string | undefined;
1255
- }>;
1256
- type ShoppingCart4SpecProps = z.infer<typeof shoppingCart4PropsSchema>;
1257
- /**
1258
- * Optional brand seams shared by the existing blocks. These mirror the
1259
- * components' optional props as a serializable subset (no React): an accent
1260
- * marks a trailing segment of the wordmark/brand name, and an editorial image
1261
- * is a native `<img>` source. Omitting each keeps the block's current output.
1262
- */
1263
- declare const logoAccentSchema: z.ZodObject<{
1264
- text: z.ZodString;
1265
- className: z.ZodOptional<z.ZodString>;
1266
- }, "strip", z.ZodTypeAny, {
1267
- text: string;
1268
- className?: string | undefined;
1269
- }, {
1270
- text: string;
1271
- className?: string | undefined;
1272
- }>;
1273
- type LogoAccent = z.infer<typeof logoAccentSchema>;
1274
- declare const brandAccentSchema: z.ZodObject<{
1275
- text: z.ZodString;
1276
- className: z.ZodOptional<z.ZodString>;
1277
- }, "strip", z.ZodTypeAny, {
1278
- text: string;
1279
- className?: string | undefined;
1280
- }, {
1281
- text: string;
1282
- className?: string | undefined;
1283
- }>;
1284
- type BrandAccent = z.infer<typeof brandAccentSchema>;
1285
- declare const heroImageSchema: z.ZodObject<{
1286
- src: z.ZodString;
1287
- alt: z.ZodString;
1288
- }, "strip", z.ZodTypeAny, {
1289
- src: string;
1290
- alt: string;
1291
- }, {
1292
- src: string;
1293
- alt: string;
1294
- }>;
1295
- type HeroImage = z.infer<typeof heroImageSchema>;
1296
- declare const navbar4PropsSchema: z.ZodObject<{
1297
- storeCategories: z.ZodArray<z.ZodType<StoreCategory, z.ZodTypeDef, StoreCategory>, "many">;
1298
- shippingNote: z.ZodString;
1299
- utilityLinks: z.ZodArray<z.ZodObject<{
1300
- label: z.ZodString;
1301
- href: z.ZodString;
1302
- }, "strip", z.ZodTypeAny, {
1303
- label: string;
1304
- href: string;
1305
- }, {
1306
- label: string;
1307
- href: string;
1308
- }>, "many">;
1309
- logoText: z.ZodString;
1310
- logoHref: z.ZodOptional<z.ZodString>;
1311
- /** Optional accent for a trailing segment of `logoText`; omitted → unchanged. */
1312
- logoAccent: z.ZodOptional<z.ZodObject<{
1313
- text: z.ZodString;
1314
- className: z.ZodOptional<z.ZodString>;
1315
- }, "strip", z.ZodTypeAny, {
1316
- text: string;
1317
- className?: string | undefined;
1318
- }, {
1319
- text: string;
1320
- className?: string | undefined;
1321
- }>>;
1322
- /**
1323
- * Consumer-supplied classes merged onto the block's outer surface as the
1324
- * final argument (e.g. a semantic surface token). Omitted → unchanged.
1325
- */
1326
- className: z.ZodOptional<z.ZodString>;
1327
- accountHref: z.ZodOptional<z.ZodString>;
1328
- searchQuery: z.ZodOptional<z.ZodString>;
1329
- items: z.ZodOptional<z.ZodArray<z.ZodObject<{
1330
- id: z.ZodString;
1331
- name: z.ZodString;
1332
- variant: z.ZodOptional<z.ZodString>;
1333
- price: z.ZodNumber;
1334
- qty: z.ZodNumber;
1335
- /** Optional; absent images are omitted, never serialized as `""`. */
1336
- image: z.ZodOptional<z.ZodString>;
1337
- }, "strip", z.ZodTypeAny, {
1338
- id: string;
1339
- name: string;
1340
- price: number;
1341
- qty: number;
1342
- image?: string | undefined;
1343
- variant?: string | undefined;
1344
- }, {
1345
- id: string;
1346
- name: string;
1347
- price: number;
1348
- qty: number;
1349
- image?: string | undefined;
1350
- variant?: string | undefined;
1351
- }>, "many">>;
1352
- /** Authoritative backend subtotal for the mini-cart. */
1353
- subtotal: z.ZodOptional<z.ZodType<Money, z.ZodTypeDef, Money>>;
1354
- subtotalUnavailableLabel: z.ZodOptional<z.ZodString>;
1355
- user: z.ZodOptional<z.ZodObject<{
1356
- name: z.ZodString;
1357
- email: z.ZodString;
1358
- avatar: z.ZodString;
1359
- initials: z.ZodString;
1360
- }, "strip", z.ZodTypeAny, {
1361
- name: string;
1362
- email: string;
1363
- avatar: string;
1364
- initials: string;
1365
- }, {
1366
- name: string;
1367
- email: string;
1368
- avatar: string;
1369
- initials: string;
1370
- }>>;
1371
- accountMenuItems: z.ZodOptional<z.ZodArray<z.ZodObject<{
1372
- label: z.ZodString;
1373
- href: z.ZodString;
1374
- description: z.ZodOptional<z.ZodString>;
1375
- icon: z.ZodOptional<z.ZodEnum<["orders", "wishlist", "addresses", "settings"]>>;
1376
- }, "strip", z.ZodTypeAny, {
1377
- label: string;
1378
- href: string;
1379
- description?: string | undefined;
1380
- icon?: "orders" | "wishlist" | "addresses" | "settings" | undefined;
1381
- }, {
1382
- label: string;
1383
- href: string;
1384
- description?: string | undefined;
1385
- icon?: "orders" | "wishlist" | "addresses" | "settings" | undefined;
1386
- }>, "many">>;
1387
- }, "strip", z.ZodTypeAny, {
1388
- storeCategories: StoreCategory[];
1389
- shippingNote: string;
1390
- utilityLinks: {
1391
- label: string;
1392
- href: string;
1393
- }[];
1394
- logoText: string;
1395
- subtotal?: Money | undefined;
1396
- className?: string | undefined;
1397
- items?: {
1398
- id: string;
1399
- name: string;
1400
- price: number;
1401
- qty: number;
1402
- image?: string | undefined;
1403
- variant?: string | undefined;
1404
- }[] | undefined;
1405
- logoHref?: string | undefined;
1406
- logoAccent?: {
1407
- text: string;
1408
- className?: string | undefined;
1409
- } | undefined;
1410
- accountHref?: string | undefined;
1411
- searchQuery?: string | undefined;
1412
- subtotalUnavailableLabel?: string | undefined;
1413
- user?: {
1414
- name: string;
1415
- email: string;
1416
- avatar: string;
1417
- initials: string;
1418
- } | undefined;
1419
- accountMenuItems?: {
1420
- label: string;
1421
- href: string;
1422
- description?: string | undefined;
1423
- icon?: "orders" | "wishlist" | "addresses" | "settings" | undefined;
1424
- }[] | undefined;
1425
- }, {
1426
- storeCategories: StoreCategory[];
1427
- shippingNote: string;
1428
- utilityLinks: {
1429
- label: string;
1430
- href: string;
1431
- }[];
1432
- logoText: string;
1433
- subtotal?: Money | undefined;
1434
- className?: string | undefined;
1435
- items?: {
1436
- id: string;
1437
- name: string;
1438
- price: number;
1439
- qty: number;
1440
- image?: string | undefined;
1441
- variant?: string | undefined;
1442
- }[] | undefined;
1443
- logoHref?: string | undefined;
1444
- logoAccent?: {
1445
- text: string;
1446
- className?: string | undefined;
1447
- } | undefined;
1448
- accountHref?: string | undefined;
1449
- searchQuery?: string | undefined;
1450
- subtotalUnavailableLabel?: string | undefined;
1451
- user?: {
1452
- name: string;
1453
- email: string;
1454
- avatar: string;
1455
- initials: string;
1456
- } | undefined;
1457
- accountMenuItems?: {
1458
- label: string;
1459
- href: string;
1460
- description?: string | undefined;
1461
- icon?: "orders" | "wishlist" | "addresses" | "settings" | undefined;
1462
- }[] | undefined;
1463
- }>;
1464
- type Navbar4SpecProps = z.infer<typeof navbar4PropsSchema>;
1465
- /**
1466
- * Serializable contracts for the two bounded editorial sections (`faq`, `cta`).
1467
- * These are the serializable subset of `FaqBlock1Props`/`CtaSection1Props`: the
1468
- * React-only callbacks (`onPrimaryClick`/`onSecondaryClick`) are intentionally
1469
- * excluded — the catalog adapter binds them (see design D3).
1470
- */
1471
- declare const ctaSchema: z.ZodObject<{
1472
- label: z.ZodString;
1473
- href: z.ZodOptional<z.ZodString>;
1474
- }, "strip", z.ZodTypeAny, {
1475
- label: string;
1476
- href?: string | undefined;
1477
- }, {
1478
- label: string;
1479
- href?: string | undefined;
1480
- }>;
1481
- type CtaSpec = z.infer<typeof ctaSchema>;
1482
- declare const faqItemSchema: z.ZodObject<{
1483
- value: z.ZodString;
1484
- question: z.ZodString;
1485
- answer: z.ZodString;
1486
- }, "strip", z.ZodTypeAny, {
1487
- value: string;
1488
- question: string;
1489
- answer: string;
1490
- }, {
1491
- value: string;
1492
- question: string;
1493
- answer: string;
1494
- }>;
1495
- type FaqItemSpec = z.infer<typeof faqItemSchema>;
1496
- declare const faqBlock1PropsSchema: z.ZodObject<{
1497
- items: z.ZodArray<z.ZodObject<{
1498
- value: z.ZodString;
1499
- question: z.ZodString;
1500
- answer: z.ZodString;
1501
- }, "strip", z.ZodTypeAny, {
1502
- value: string;
1503
- question: string;
1504
- answer: string;
1505
- }, {
1506
- value: string;
1507
- question: string;
1508
- answer: string;
1509
- }>, "many">;
1510
- title: z.ZodOptional<z.ZodString>;
1511
- description: z.ZodOptional<z.ZodString>;
1512
- accordionType: z.ZodOptional<z.ZodEnum<["single", "multiple"]>>;
1513
- }, "strip", z.ZodTypeAny, {
1514
- items: {
1515
- value: string;
1516
- question: string;
1517
- answer: string;
1518
- }[];
1519
- title?: string | undefined;
1520
- description?: string | undefined;
1521
- accordionType?: "single" | "multiple" | undefined;
1522
- }, {
1523
- items: {
1524
- value: string;
1525
- question: string;
1526
- answer: string;
1527
- }[];
1528
- title?: string | undefined;
1529
- description?: string | undefined;
1530
- accordionType?: "single" | "multiple" | undefined;
1531
- }>;
1532
- type FaqBlock1SpecProps = z.infer<typeof faqBlock1PropsSchema>;
1533
- declare const ctaSection1PropsSchema: z.ZodObject<{
1534
- badgeText: z.ZodOptional<z.ZodString>;
1535
- title: z.ZodOptional<z.ZodString>;
1536
- description: z.ZodOptional<z.ZodString>;
1537
- primaryCta: z.ZodOptional<z.ZodObject<{
1538
- label: z.ZodString;
1539
- href: z.ZodOptional<z.ZodString>;
1540
- }, "strip", z.ZodTypeAny, {
1541
- label: string;
1542
- href?: string | undefined;
1543
- }, {
1544
- label: string;
1545
- href?: string | undefined;
1546
- }>>;
1547
- secondaryCta: z.ZodOptional<z.ZodObject<{
1548
- label: z.ZodString;
1549
- href: z.ZodOptional<z.ZodString>;
1550
- }, "strip", z.ZodTypeAny, {
1551
- label: string;
1552
- href?: string | undefined;
1553
- }, {
1554
- label: string;
1555
- href?: string | undefined;
1556
- }>>;
1557
- }, "strip", z.ZodTypeAny, {
1558
- title?: string | undefined;
1559
- description?: string | undefined;
1560
- badgeText?: string | undefined;
1561
- primaryCta?: {
1562
- label: string;
1563
- href?: string | undefined;
1564
- } | undefined;
1565
- secondaryCta?: {
1566
- label: string;
1567
- href?: string | undefined;
1568
- } | undefined;
1569
- }, {
1570
- title?: string | undefined;
1571
- description?: string | undefined;
1572
- badgeText?: string | undefined;
1573
- primaryCta?: {
1574
- label: string;
1575
- href?: string | undefined;
1576
- } | undefined;
1577
- secondaryCta?: {
1578
- label: string;
1579
- href?: string | undefined;
1580
- } | undefined;
1581
- }>;
1582
- type CtaSection1SpecProps = z.infer<typeof ctaSection1PropsSchema>;
1583
-
1584
- export { type AccountMenuItem, type BrandAccent, type ButtonSpecProps, type CanonMoney, type CanonProduct, type CardProduct, type CartItem, type CartTotals, type CtaSection1SpecProps, type CtaSpec, type FaqBlock1SpecProps, type FaqItemSpec, type HeroImage, type LogoAccent, type NavCartItem, type Navbar4SpecProps, PRODUCT_IMAGE_FALLBACK, type ProductCard1SpecProps, type ProductDetailProductSpec, type ProductDetailVariantSpec, type ProductOverview1SpecProps, type Promotion, type RecentlyViewedItem, type ShoppingCart4SpecProps, type StoreCategory, type StoreContainer1SpecProps, type StoreUser, type UtilityLink, accountMenuItemSchema, brandAccentSchema, buttonPropsSchema, cardProductSchema, cartItemSchema, cartTotalsSchema, ctaSchema, ctaSection1PropsSchema, faqBlock1PropsSchema, faqItemSchema, formatMoney, heroImageSchema, isAvailableMoney, isCompleteFiniteDecimal, logoAccentSchema, moneySchema, navCartItemSchema, navbar4PropsSchema, paymentMethodSchema, productCard1PropsSchema, productDetailProductSchema, productDetailVariantSchema, productOverview1PropsSchema, promotionSchema, recentlyViewedItemSchema, resolveAbsoluteQuantity, shoppingCart4PropsSchema, storeCategorySchema, storeContainer1PropsSchema, storeUserSchema, utilityLinkSchema };