@propeller-commerce/propeller-v2-react-ui 0.4.6
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/CHANGELOG.md +359 -0
- package/LICENSE +21 -0
- package/MIGRATION.md +217 -0
- package/README.md +668 -0
- package/STYLING.md +145 -0
- package/dist/index.cjs +17345 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +6478 -0
- package/dist/index.d.ts +6478 -0
- package/dist/index.js +17218 -0
- package/dist/index.js.map +1 -0
- package/dist/pure.cjs +974 -0
- package/dist/pure.cjs.map +1 -0
- package/dist/pure.d.cts +556 -0
- package/dist/pure.d.ts +556 -0
- package/dist/pure.js +938 -0
- package/dist/pure.js.map +1 -0
- package/dist/shared.cjs +14 -0
- package/dist/shared.cjs.map +1 -0
- package/dist/shared.d.cts +24 -0
- package/dist/shared.d.ts +24 -0
- package/dist/shared.js +3 -0
- package/dist/shared.js.map +1 -0
- package/dist/styles.css +2 -0
- package/package.json +93 -0
package/dist/pure.d.cts
ADDED
|
@@ -0,0 +1,556 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { Category, Cluster, Product, ProductInventory, OrderItem, Order, ProductPrice, Contact, Customer, PaginatedMediaDocumentResponse, ClusterOption, PaginatedMediaVideoResponse } from '@propeller-commerce/propeller-sdk-v2';
|
|
3
|
+
import * as _propeller_commerce_propeller_v2_core_ui from '@propeller-commerce/propeller-v2-core-ui';
|
|
4
|
+
import { JsonLdContext } from '@propeller-commerce/propeller-v2-core-ui';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
8
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
9
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
10
|
+
* Verified C0.2 (2026-05-20).
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
interface BreadcrumbsProps {
|
|
14
|
+
/**
|
|
15
|
+
* The category path from the category, product or cluster response.
|
|
16
|
+
* Obtain from `category.categoryPath` or `product.category.categoryPath`.
|
|
17
|
+
*/
|
|
18
|
+
categoryPath: Category[];
|
|
19
|
+
/**
|
|
20
|
+
* When true (default), the last item in the path is displayed as the
|
|
21
|
+
* current page (non-clickable, aria-current="page").
|
|
22
|
+
* When false, the last item is omitted.
|
|
23
|
+
* Ignored when `currentLabel` is provided — the extra crumb becomes
|
|
24
|
+
* the current page instead.
|
|
25
|
+
*/
|
|
26
|
+
showCurrent?: boolean;
|
|
27
|
+
/**
|
|
28
|
+
* The category of the current page. When provided and not already
|
|
29
|
+
* the last item in `categoryPath`, it is appended automatically so
|
|
30
|
+
* the trail always ends at the current category. This makes the
|
|
31
|
+
* component correct whether the API's categoryPath includes the
|
|
32
|
+
* current category or only its ancestors.
|
|
33
|
+
*/
|
|
34
|
+
currentCategory?: Category;
|
|
35
|
+
/**
|
|
36
|
+
* Optional trailing crumb appended after the category path — typically
|
|
37
|
+
* the name of the current product or cluster on a detail page.
|
|
38
|
+
* When provided, this crumb is marked as the current page and the
|
|
39
|
+
* last category becomes a normal link.
|
|
40
|
+
*/
|
|
41
|
+
currentLabel?: string;
|
|
42
|
+
/**
|
|
43
|
+
* Optional URL for the trailing `currentLabel` crumb. When omitted,
|
|
44
|
+
* the crumb is rendered as a non-link `<span>`.
|
|
45
|
+
*/
|
|
46
|
+
currentUrl?: string;
|
|
47
|
+
/**
|
|
48
|
+
* When true (default), a "Home" link is prepended to the trail.
|
|
49
|
+
*/
|
|
50
|
+
showHome?: boolean;
|
|
51
|
+
/**
|
|
52
|
+
* URL for the Home link. Defaults to '/'.
|
|
53
|
+
*/
|
|
54
|
+
homeUrl?: string;
|
|
55
|
+
/**
|
|
56
|
+
* Language code used to resolve localised category names and slugs.
|
|
57
|
+
* Defaults to 'NL'.
|
|
58
|
+
*/
|
|
59
|
+
language?: string;
|
|
60
|
+
/**
|
|
61
|
+
* Custom URL builder for category links.
|
|
62
|
+
* Receives the Category object and its zero-based index in the path.
|
|
63
|
+
* When omitted, URLs default to `/category/{categoryId}/{slug}`.
|
|
64
|
+
*/
|
|
65
|
+
getUrl?: (category: Category, index: number) => string;
|
|
66
|
+
/**
|
|
67
|
+
* Override any UI string.
|
|
68
|
+
* Available keys: home, separator
|
|
69
|
+
*/
|
|
70
|
+
labels?: Record<string, string>;
|
|
71
|
+
/** Extra CSS class applied to the root element. */
|
|
72
|
+
className?: string;
|
|
73
|
+
/** Configuration object passed to the component */
|
|
74
|
+
configuration?: any;
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Renders a breadcrumb trail from a category path, with an optional Home link
|
|
78
|
+
* and an optional trailing crumb for the current product/cluster page.
|
|
79
|
+
*/
|
|
80
|
+
declare function Breadcrumbs(props: BreadcrumbsProps): React.JSX.Element;
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
84
|
+
* browser APIs, no context reads.
|
|
85
|
+
*
|
|
86
|
+
* Emits a `<script type="application/ld+json">` with a schema.org Product
|
|
87
|
+
* payload representing the cluster (clusters use `@type: "Product"` — schema.org
|
|
88
|
+
* has no Cluster type; the cluster's `defaultProduct` supplies brand/SKU/price/image).
|
|
89
|
+
* Returns `null` when the cluster has no usable name AND no URL.
|
|
90
|
+
*/
|
|
91
|
+
|
|
92
|
+
interface ClusterJsonLdProps {
|
|
93
|
+
/** The cluster to describe. */
|
|
94
|
+
cluster: Cluster;
|
|
95
|
+
/** Per-request context: siteUrl, language, currency, portalMode, user, URL builders. */
|
|
96
|
+
context: JsonLdContext;
|
|
97
|
+
}
|
|
98
|
+
declare function ClusterJsonLd(props: ClusterJsonLdProps): React.JSX.Element | null;
|
|
99
|
+
declare const _default$3: React.MemoExoticComponent<typeof ClusterJsonLd>;
|
|
100
|
+
|
|
101
|
+
/**
|
|
102
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
103
|
+
* browser APIs, no context reads.
|
|
104
|
+
*
|
|
105
|
+
* Emits a single `<script type="application/ld+json">` containing a schema.org
|
|
106
|
+
* `ItemList` of `Product` items, one per element in the `products` array.
|
|
107
|
+
* Scope is intentionally first-page only — caller passes whatever array is
|
|
108
|
+
* present in the initial SSR HTML; client-side filter/sort/page navigation
|
|
109
|
+
* does NOT update the script tag (crawlers only see the SSR snapshot anyway).
|
|
110
|
+
*
|
|
111
|
+
* Clusters in the response are unwrapped to their `defaultProduct` for the
|
|
112
|
+
* embedded Product node, but the ListItem URL points to the cluster page.
|
|
113
|
+
* Returns `null` when the list is empty.
|
|
114
|
+
*/
|
|
115
|
+
|
|
116
|
+
interface ItemListJsonLdProps {
|
|
117
|
+
/** First-page products (from server-side fetch). */
|
|
118
|
+
products: ReadonlyArray<Product>;
|
|
119
|
+
/** Per-request context: siteUrl, language, currency, portalMode, user, URL builders. */
|
|
120
|
+
context: JsonLdContext;
|
|
121
|
+
}
|
|
122
|
+
declare function ItemListJsonLd(props: ItemListJsonLdProps): React.JSX.Element | null;
|
|
123
|
+
declare const _default$2: React.MemoExoticComponent<typeof ItemListJsonLd>;
|
|
124
|
+
|
|
125
|
+
/**
|
|
126
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
127
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
128
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
129
|
+
*
|
|
130
|
+
* Emits a single `<script type="application/ld+json">` with the schema.org
|
|
131
|
+
* Product payload built from the SDK `Product`. Returns `null` (no DOM) when
|
|
132
|
+
* the input has no usable name AND no URL. Offers are gated by portal mode
|
|
133
|
+
* (semi-closed + anonymous → no `offers` block).
|
|
134
|
+
*/
|
|
135
|
+
|
|
136
|
+
interface ProductJsonLdProps {
|
|
137
|
+
/** The product to describe. */
|
|
138
|
+
product: Product;
|
|
139
|
+
/** Per-request context: siteUrl, language, currency, portalMode, user, URL builders. */
|
|
140
|
+
context: JsonLdContext;
|
|
141
|
+
}
|
|
142
|
+
declare function ProductJsonLd(props: ProductJsonLdProps): React.JSX.Element | null;
|
|
143
|
+
declare const _default$1: React.MemoExoticComponent<typeof ProductJsonLd>;
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
147
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
148
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
149
|
+
* Verified C0.2 (2026-05-20).
|
|
150
|
+
*/
|
|
151
|
+
|
|
152
|
+
interface CategoryShortDescriptionProps {
|
|
153
|
+
/**
|
|
154
|
+
* Language code used to resolve the correct localised short description
|
|
155
|
+
* from `category.shortDescription`.
|
|
156
|
+
*/
|
|
157
|
+
language: string;
|
|
158
|
+
/**
|
|
159
|
+
* Propeller Category object.
|
|
160
|
+
* The component reads `category.shortDescription` (an array of LocalizedString)
|
|
161
|
+
* and renders the matching language entry as HTML.
|
|
162
|
+
*/
|
|
163
|
+
category?: Category;
|
|
164
|
+
/** Extra CSS class applied to the root element. */
|
|
165
|
+
className?: string;
|
|
166
|
+
}
|
|
167
|
+
/**
|
|
168
|
+
* Renders a category's localised HTML short description.
|
|
169
|
+
*/
|
|
170
|
+
declare function CategoryShortDescription(props: CategoryShortDescriptionProps): React.JSX.Element;
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
174
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
175
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
176
|
+
* Verified C0.2 (2026-05-20).
|
|
177
|
+
*/
|
|
178
|
+
|
|
179
|
+
interface GridTitleProps {
|
|
180
|
+
/**
|
|
181
|
+
* The main heading text to display.
|
|
182
|
+
* Typically the category name, search term, or brand name.
|
|
183
|
+
*/
|
|
184
|
+
title: string;
|
|
185
|
+
/**
|
|
186
|
+
* Language code for the content.
|
|
187
|
+
* Defaults to 'NL'. Resolved from `<PropellerProvider>` when not passed explicitly.
|
|
188
|
+
*/
|
|
189
|
+
language?: string;
|
|
190
|
+
/**
|
|
191
|
+
* Override the heading tag level.
|
|
192
|
+
* Defaults to 'h1'. Use 'h2' when the grid is embedded inside
|
|
193
|
+
* a page that already has an h1.
|
|
194
|
+
*/
|
|
195
|
+
headingLevel?: string;
|
|
196
|
+
/** Extra CSS class applied to the root element. */
|
|
197
|
+
className?: string;
|
|
198
|
+
}
|
|
199
|
+
/**
|
|
200
|
+
* Renders the heading for a product grid page (category, search or brand
|
|
201
|
+
* name), with a configurable heading level.
|
|
202
|
+
*/
|
|
203
|
+
declare function GridTitle(props: GridTitleProps): React.JSX.Element;
|
|
204
|
+
|
|
205
|
+
/**
|
|
206
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
207
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
208
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
209
|
+
* Verified C0.2 (2026-05-20).
|
|
210
|
+
*/
|
|
211
|
+
|
|
212
|
+
interface ItemStockProps {
|
|
213
|
+
/**
|
|
214
|
+
* Product inventory to display stock and availability for.
|
|
215
|
+
* Required — drives all stock calculations and display logic.
|
|
216
|
+
*/
|
|
217
|
+
inventory: ProductInventory;
|
|
218
|
+
/**
|
|
219
|
+
* Shows whether the product is available or not available.
|
|
220
|
+
* Defaults to true.
|
|
221
|
+
*/
|
|
222
|
+
showAvailability?: boolean;
|
|
223
|
+
/**
|
|
224
|
+
* Shows the actual stock quantity (`inventory.totalQuantity`).
|
|
225
|
+
* Defaults to true.
|
|
226
|
+
*/
|
|
227
|
+
showStock?: boolean;
|
|
228
|
+
/**
|
|
229
|
+
* UI string overrides.
|
|
230
|
+
* Available keys: inStock, outOfStock, lowStock, available, notAvailable, pieces
|
|
231
|
+
*/
|
|
232
|
+
labels?: Record<string, string>;
|
|
233
|
+
/** Extra CSS class applied to the root element. */
|
|
234
|
+
className?: string;
|
|
235
|
+
}
|
|
236
|
+
/**
|
|
237
|
+
* Renders stock badges for a product: an availability indicator and/or a
|
|
238
|
+
* stock-status badge (in stock / low stock / out of stock) with quantity.
|
|
239
|
+
*/
|
|
240
|
+
declare function ItemStock(props: ItemStockProps): React.JSX.Element;
|
|
241
|
+
declare const _default: React.MemoExoticComponent<typeof ItemStock>;
|
|
242
|
+
|
|
243
|
+
interface OrderItemCardProps {
|
|
244
|
+
/** The order item to display */
|
|
245
|
+
orderItem: OrderItem;
|
|
246
|
+
/** Child order items (rendered as indented sub-rows beneath the parent) */
|
|
247
|
+
childItems?: OrderItem[];
|
|
248
|
+
/** Should the item title be a link to the PDP */
|
|
249
|
+
titleLinkable?: boolean;
|
|
250
|
+
/** Display a small thumbnail of the order item */
|
|
251
|
+
showImage?: boolean;
|
|
252
|
+
/** Should stock info be displayed */
|
|
253
|
+
showStockComponent?: boolean;
|
|
254
|
+
/** Display the SKU of the order item beneath the item name */
|
|
255
|
+
showSku?: boolean;
|
|
256
|
+
/** Display the quantity of the order item */
|
|
257
|
+
showQuantity?: boolean;
|
|
258
|
+
/** Display the price of the order item */
|
|
259
|
+
showPrice?: boolean;
|
|
260
|
+
/** Display the discount column */
|
|
261
|
+
showDiscount?: boolean;
|
|
262
|
+
/** Should the order item notes field be displayed */
|
|
263
|
+
showItemNotes?: boolean;
|
|
264
|
+
/** Render as a child/sub-item (indented, no image) */
|
|
265
|
+
isChildItem?: boolean;
|
|
266
|
+
/** Custom price formatting function */
|
|
267
|
+
formatPrice?: (price: number) => string;
|
|
268
|
+
/** Currency symbol used by the default formatter. Default: `'€'`. */
|
|
269
|
+
currency?: string;
|
|
270
|
+
/** Translated labels keyed by the slugs used inside the component (see
|
|
271
|
+
* `getLabel` calls). Missing keys fall back to the English defaults. */
|
|
272
|
+
labels?: Record<string, string>;
|
|
273
|
+
priceComponent?: React.ComponentType<_propeller_commerce_propeller_v2_core_ui.PriceComponentProps>;
|
|
274
|
+
stockComponent?: React.ComponentType<_propeller_commerce_propeller_v2_core_ui.StockComponentProps>;
|
|
275
|
+
}
|
|
276
|
+
/**
|
|
277
|
+
* Renders a single order line item as a table row (with optional indented
|
|
278
|
+
* child-item rows), showing image, SKU, quantity, discount and price.
|
|
279
|
+
*/
|
|
280
|
+
declare function OrderItemCard(props: OrderItemCardProps): React.JSX.Element;
|
|
281
|
+
|
|
282
|
+
/**
|
|
283
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
284
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
285
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
286
|
+
* Verified C0.2 (2026-05-20).
|
|
287
|
+
*/
|
|
288
|
+
|
|
289
|
+
interface OrderSummaryProps {
|
|
290
|
+
/** The order object from propeller-sdk-v2 */
|
|
291
|
+
order: any;
|
|
292
|
+
/** The CSS class for the order summary container */
|
|
293
|
+
orderSummaryContainerClass?: string;
|
|
294
|
+
/** Title of the order summary */
|
|
295
|
+
title?: string;
|
|
296
|
+
/** Show the order number */
|
|
297
|
+
showOrderNumber?: boolean;
|
|
298
|
+
/** Show the order date */
|
|
299
|
+
showOrderDate?: boolean;
|
|
300
|
+
/** Show the order status */
|
|
301
|
+
showOrderStatus?: boolean;
|
|
302
|
+
/** Show the order total */
|
|
303
|
+
showOrderTotal?: boolean;
|
|
304
|
+
/** Custom price formatting function */
|
|
305
|
+
formatPrice?: (price: number) => string;
|
|
306
|
+
/** Show the invoice address */
|
|
307
|
+
showInvoiceAddress?: boolean;
|
|
308
|
+
/** Show the delivery address */
|
|
309
|
+
showDeliveryAddress?: boolean;
|
|
310
|
+
/** Show payment, carrier, and delivery date info */
|
|
311
|
+
showDeliveryInfo?: boolean;
|
|
312
|
+
/** Show order remarks and reference */
|
|
313
|
+
showRemarks?: boolean;
|
|
314
|
+
/** Custom date formatting function */
|
|
315
|
+
formatDate?: (dateString: string) => string;
|
|
316
|
+
/** Labels for the component */
|
|
317
|
+
labels?: Record<string, string>;
|
|
318
|
+
/** List of countries for resolving codes to names [{code: 'NL', name: 'Netherlands'}, ...] */
|
|
319
|
+
countries?: {
|
|
320
|
+
code: string;
|
|
321
|
+
name: string;
|
|
322
|
+
}[];
|
|
323
|
+
/** Currency symbol used by the default formatter. Default: `'€'`. */
|
|
324
|
+
currency?: string;
|
|
325
|
+
}
|
|
326
|
+
/**
|
|
327
|
+
* Renders a read-only summary of an order: meta fields (number, date, status,
|
|
328
|
+
* total), invoice/delivery addresses, delivery info and remarks.
|
|
329
|
+
*/
|
|
330
|
+
declare function OrderSummary(props: OrderSummaryProps): React.JSX.Element;
|
|
331
|
+
|
|
332
|
+
/**
|
|
333
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
334
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
335
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
336
|
+
* Verified C0.2 (2026-05-20).
|
|
337
|
+
*/
|
|
338
|
+
|
|
339
|
+
interface OrderTotalsProps {
|
|
340
|
+
/** The order/quote used to populate the summary data */
|
|
341
|
+
order: Order;
|
|
342
|
+
/** Order summary block title */
|
|
343
|
+
title?: string;
|
|
344
|
+
/** Labels for the component */
|
|
345
|
+
labels?: Record<string, string>;
|
|
346
|
+
/** Display the subtotal of the order/quote */
|
|
347
|
+
showSubtotal?: boolean;
|
|
348
|
+
/** Display the total discount of the order/quote */
|
|
349
|
+
showDiscount?: boolean;
|
|
350
|
+
/** Display the shipping costs of the order/quote */
|
|
351
|
+
showShippingCosts?: boolean;
|
|
352
|
+
/** Display all VATs of the order/quote */
|
|
353
|
+
showVATs?: boolean;
|
|
354
|
+
/** Display the total of the order/quote excluding the VAT */
|
|
355
|
+
showTotalExclVat?: boolean;
|
|
356
|
+
/** Display the total VAT of the order/quote */
|
|
357
|
+
showTotalVat?: boolean;
|
|
358
|
+
/** Custom price formatting function */
|
|
359
|
+
formatPrice?: (price: number) => string;
|
|
360
|
+
/** Currency symbol used by the default formatter. Default: `'€'`. */
|
|
361
|
+
currency?: string;
|
|
362
|
+
}
|
|
363
|
+
/**
|
|
364
|
+
* Renders the price breakdown for an order or quote: subtotal, discount,
|
|
365
|
+
* transaction and shipping costs, per-rate VAT lines and the grand total.
|
|
366
|
+
*/
|
|
367
|
+
declare function OrderTotals(props: OrderTotalsProps): React.JSX.Element;
|
|
368
|
+
|
|
369
|
+
/**
|
|
370
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
371
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
372
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
373
|
+
* Verified C0.2 (2026-05-20).
|
|
374
|
+
*/
|
|
375
|
+
|
|
376
|
+
interface ProductBulkPricesProps {
|
|
377
|
+
/**
|
|
378
|
+
* Bulk price tiers from the product.
|
|
379
|
+
* Obtain from `product.bulkPrices`.
|
|
380
|
+
*/
|
|
381
|
+
bulkPrices: ProductPrice[];
|
|
382
|
+
/**
|
|
383
|
+
* When true, net price (incl. tax) is the leading price.
|
|
384
|
+
* Defaults to false — gross (excl. VAT) is shown.
|
|
385
|
+
* Note: in the Propeller SDK `price.gross` = excl. VAT, `price.net` = incl. VAT.
|
|
386
|
+
*/
|
|
387
|
+
includeTax?: boolean;
|
|
388
|
+
/**
|
|
389
|
+
* Controls portal visibility mode.
|
|
390
|
+
* 'semi-closed' — component is hidden for anonymous users.
|
|
391
|
+
* Defaults to 'open'.
|
|
392
|
+
*/
|
|
393
|
+
portalMode?: string;
|
|
394
|
+
/** Authenticated user — used for semi-closed visibility. */
|
|
395
|
+
user?: Contact | Customer | null;
|
|
396
|
+
/** Tax zone code. Defaults to 'NL'. */
|
|
397
|
+
taxZone?: string;
|
|
398
|
+
/** Currency symbol for prices. Defaults to '€'. */
|
|
399
|
+
currency?: string;
|
|
400
|
+
/**
|
|
401
|
+
* Override any UI string.
|
|
402
|
+
* Available keys: title, quantityFrom, price, inclTax, exclTax
|
|
403
|
+
*/
|
|
404
|
+
labels?: Record<string, string>;
|
|
405
|
+
/** Extra CSS class applied to the root element. */
|
|
406
|
+
className?: string;
|
|
407
|
+
}
|
|
408
|
+
/**
|
|
409
|
+
* Renders a product's volume/quantity-tier pricing as a table, filtering out
|
|
410
|
+
* expired or list-price tiers and showing incl./excl. VAT prices.
|
|
411
|
+
*/
|
|
412
|
+
declare function ProductBulkPrices(props: ProductBulkPricesProps): React.JSX.Element;
|
|
413
|
+
|
|
414
|
+
/**
|
|
415
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
416
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
417
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
418
|
+
* Verified C0.2 (2026-05-20).
|
|
419
|
+
*/
|
|
420
|
+
|
|
421
|
+
interface ProductDownloadsProps {
|
|
422
|
+
/**
|
|
423
|
+
* Media documents for the product.
|
|
424
|
+
* Obtain from `product.media.documents`.
|
|
425
|
+
*/
|
|
426
|
+
downloads: PaginatedMediaDocumentResponse;
|
|
427
|
+
/**
|
|
428
|
+
* Language code used to resolve the correct localised document URL and label.
|
|
429
|
+
*/
|
|
430
|
+
language: string;
|
|
431
|
+
/**
|
|
432
|
+
* Override any UI string.
|
|
433
|
+
* Available keys: title, download, empty
|
|
434
|
+
*/
|
|
435
|
+
labels?: Record<string, string>;
|
|
436
|
+
/** Extra CSS class applied to the root element. */
|
|
437
|
+
className?: string;
|
|
438
|
+
}
|
|
439
|
+
/**
|
|
440
|
+
* Renders a product's downloadable media documents as a list of localised
|
|
441
|
+
* download links, or an empty-state message when there are none.
|
|
442
|
+
*/
|
|
443
|
+
declare function ProductDownloads(props: ProductDownloadsProps): React.JSX.Element;
|
|
444
|
+
|
|
445
|
+
/**
|
|
446
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
447
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
448
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
449
|
+
* Verified C0.2 (2026-05-20).
|
|
450
|
+
*/
|
|
451
|
+
|
|
452
|
+
interface ProductPriceProps {
|
|
453
|
+
/**
|
|
454
|
+
* ProductPrice object from the product.
|
|
455
|
+
* Obtain from `product.price`.
|
|
456
|
+
*/
|
|
457
|
+
price: ProductPrice;
|
|
458
|
+
/** Currency symbol to display. Defaults to '€'. */
|
|
459
|
+
currency?: string;
|
|
460
|
+
/**
|
|
461
|
+
* Controls portal visibility mode.
|
|
462
|
+
* 'open' — full e-commerce; price is always visible.
|
|
463
|
+
* 'semi-closed' — catalog-only; price is hidden for anonymous users.
|
|
464
|
+
* Defaults to 'open'.
|
|
465
|
+
*/
|
|
466
|
+
portalMode?: string;
|
|
467
|
+
/** Authenticated user — used for semi-closed visibility. */
|
|
468
|
+
user?: Contact | Customer | null;
|
|
469
|
+
/**
|
|
470
|
+
* When true, net price (incl. tax) is the leading price.
|
|
471
|
+
* When false (default), gross price (excl. tax) is the leading price.
|
|
472
|
+
* Note: in the Propeller SDK `price.gross` = excl. VAT, `price.net` = incl. VAT.
|
|
473
|
+
*/
|
|
474
|
+
includeTax?: boolean;
|
|
475
|
+
/** Tax zone code. Defaults to 'NL'. */
|
|
476
|
+
taxZone?: string;
|
|
477
|
+
/** Cluster options (cluster.options). Required option default prices are added even without an active selection. */
|
|
478
|
+
options?: ClusterOption[];
|
|
479
|
+
/** Active option product selections — pass Object.values(selectedOptionProducts). Price updates on every change. */
|
|
480
|
+
selectedOptionProducts?: Product[];
|
|
481
|
+
/**
|
|
482
|
+
* Override any UI string.
|
|
483
|
+
* Available keys: inclTax, exclTax, loginToSeePrices
|
|
484
|
+
*/
|
|
485
|
+
labels?: Record<string, string>;
|
|
486
|
+
/** Tailwind text-size class for the leading price. Defaults to 'text-3xl'. */
|
|
487
|
+
priceSize?: string;
|
|
488
|
+
/** Extra CSS class applied to the root element. */
|
|
489
|
+
className?: string;
|
|
490
|
+
}
|
|
491
|
+
/**
|
|
492
|
+
* Renders a product's price with a leading incl./excl.-VAT amount and a
|
|
493
|
+
* secondary line for the other tax mode, adding selected cluster-option prices.
|
|
494
|
+
*/
|
|
495
|
+
declare function ProductPriceDisplay(props: ProductPriceProps): React.JSX.Element;
|
|
496
|
+
|
|
497
|
+
/**
|
|
498
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
499
|
+
* browser APIs, no context reads. The legacy `'use client'` header was
|
|
500
|
+
* removed in C0 once verified pure. Renders directly
|
|
501
|
+
* from props and can be imported into a React Server Component.
|
|
502
|
+
* Verified C0.2 (2026-05-20).
|
|
503
|
+
*/
|
|
504
|
+
|
|
505
|
+
interface ProductShortDescriptionProps {
|
|
506
|
+
/**
|
|
507
|
+
* Product or Cluster object.
|
|
508
|
+
* The component reads `product.shortDescriptions` (an array of LocalizedString)
|
|
509
|
+
* and renders the matching language entry as HTML.
|
|
510
|
+
*/
|
|
511
|
+
product: Product | Cluster;
|
|
512
|
+
/**
|
|
513
|
+
* Language code used to resolve the correct localised short description.
|
|
514
|
+
* Defaults to 'NL'.
|
|
515
|
+
*/
|
|
516
|
+
language?: string;
|
|
517
|
+
/** Extra CSS class applied to the root element. */
|
|
518
|
+
className?: string;
|
|
519
|
+
}
|
|
520
|
+
/**
|
|
521
|
+
* Renders a product's localised short description as HTML.
|
|
522
|
+
*/
|
|
523
|
+
declare function ProductShortDescription(props: ProductShortDescriptionProps): React.JSX.Element;
|
|
524
|
+
|
|
525
|
+
/**
|
|
526
|
+
* @rsc-safe — Pure display component. No React hooks, no event handlers, no
|
|
527
|
+
* browser APIs, no context reads. Renders directly from props and can be
|
|
528
|
+
* imported into a React Server Component without a 'use client' boundary.
|
|
529
|
+
* Verified C0.2 (2026-05-20).
|
|
530
|
+
*/
|
|
531
|
+
|
|
532
|
+
interface ProductVideosProps {
|
|
533
|
+
/**
|
|
534
|
+
* Media videos for the product.
|
|
535
|
+
* Obtain from `product.media.videos`.
|
|
536
|
+
*/
|
|
537
|
+
videos: PaginatedMediaVideoResponse;
|
|
538
|
+
/**
|
|
539
|
+
* Language code used to resolve the correct localised video URI.
|
|
540
|
+
*/
|
|
541
|
+
language: string;
|
|
542
|
+
/**
|
|
543
|
+
* Override any UI string.
|
|
544
|
+
* Available keys: title, empty
|
|
545
|
+
*/
|
|
546
|
+
labels?: Record<string, string>;
|
|
547
|
+
/** Extra CSS class applied to the root element. */
|
|
548
|
+
className?: string;
|
|
549
|
+
}
|
|
550
|
+
/**
|
|
551
|
+
* Renders a product's media videos, embedding YouTube/Vimeo URLs in an iframe
|
|
552
|
+
* and other URLs in a native `<video>` player.
|
|
553
|
+
*/
|
|
554
|
+
declare function ProductVideos(props: ProductVideosProps): React.JSX.Element;
|
|
555
|
+
|
|
556
|
+
export { Breadcrumbs, type BreadcrumbsProps, CategoryShortDescription, type CategoryShortDescriptionProps, _default$3 as ClusterJsonLd, type ClusterJsonLdProps, GridTitle, type GridTitleProps, _default$2 as ItemListJsonLd, type ItemListJsonLdProps, _default as ItemStock, type ItemStockProps, OrderItemCard, type OrderItemCardProps, OrderSummary, type OrderSummaryProps, OrderTotals, type OrderTotalsProps, ProductBulkPrices, type ProductBulkPricesProps, ProductDownloads, type ProductDownloadsProps, _default$1 as ProductJsonLd, type ProductJsonLdProps, ProductPriceDisplay as ProductPrice, type ProductPriceProps, ProductShortDescription, type ProductShortDescriptionProps, ProductVideos, type ProductVideosProps };
|