@propeller-commerce/propeller-v2-react-ui 0.19.0 → 0.19.2
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 +44 -0
- package/dist/index.cjs +17 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +33 -8
- package/dist/index.d.ts +33 -8
- package/dist/index.js +17 -6
- package/dist/index.js.map +1 -1
- package/dist/pure.cjs +2 -2
- package/dist/pure.cjs.map +1 -1
- package/dist/pure.d.cts +9 -0
- package/dist/pure.d.ts +9 -0
- package/dist/pure.js +2 -2
- package/dist/pure.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,50 @@ once it reaches 1.0. Until then (the `0.x` line) the public API may change
|
|
|
8
8
|
between minor versions; breaking changes are called out below and in
|
|
9
9
|
[MIGRATION.md](./MIGRATION.md).
|
|
10
10
|
|
|
11
|
+
## [0.19.2] - 2026-08-27
|
|
12
|
+
|
|
13
|
+
### Fixed
|
|
14
|
+
|
|
15
|
+
- **Money formatted at the Dutch default wherever the host didn't pass
|
|
16
|
+
`language`.** `localeForLanguage(undefined)` is `nl-NL`, so a component that
|
|
17
|
+
reads `props.language` straight off its props prints Dutch separators unless
|
|
18
|
+
every host remembers to thread the prop. `ProductCard` resolved it from
|
|
19
|
+
`<PropellerProvider>`; several others did not, so one English page could show
|
|
20
|
+
`€ 1,42` in its PDP hero price and `€1.70` on the cards beneath it.
|
|
21
|
+
- `ProductPrice` and `ProductBulkPrices` already had provider-resolving
|
|
22
|
+
wrappers on the main entry — but `OrderSummary` and `OrderTotals` did not,
|
|
23
|
+
and are exported from both entries, so a client host got the unresolved
|
|
24
|
+
build with no way to tell. Both now resolve `language` and `currency` from
|
|
25
|
+
the provider on the main entry; `/pure` still exports the context-free
|
|
26
|
+
versions for Server Components, which must pass `language` themselves.
|
|
27
|
+
- `CartCarriers` now resolves its infra props like the rest of the checkout
|
|
28
|
+
components, instead of reading them off its props.
|
|
29
|
+
|
|
30
|
+
### Internal
|
|
31
|
+
|
|
32
|
+
- Vitest now uses the automatic JSX runtime, matching the tsup build. It had
|
|
33
|
+
been defaulting to the classic runtime, so any source file importing only
|
|
34
|
+
named hooks — the context providers among them — threw "React is not defined"
|
|
35
|
+
under test while building and shipping perfectly well.
|
|
36
|
+
|
|
37
|
+
## [0.19.1] - 2026-08-26
|
|
38
|
+
|
|
39
|
+
### Fixed
|
|
40
|
+
|
|
41
|
+
- **Order and quote lines whose product is gone from the catalog.** A product
|
|
42
|
+
that is hidden, withdrawn or deleted still appears on every order and quote it
|
|
43
|
+
was sold on, but the API returns no product record for it — `orderItem.product`
|
|
44
|
+
is simply absent. `OrderItemCard` already fell back to the order item's own
|
|
45
|
+
snapshot of the line for the name, sku, thumbnail and link, but not for the
|
|
46
|
+
price: an injected `priceComponent` was handed `product.price`, rendered blank
|
|
47
|
+
on `undefined`, and the line total silently disappeared from the row. Such a
|
|
48
|
+
line now falls through to the order item's `priceTotal`. Rows with a product
|
|
49
|
+
are unaffected — the slot is still used whenever there is a catalog price to
|
|
50
|
+
give it.
|
|
51
|
+
- **`OrderShipments` printed `-` for the SKU** of a shipment line whose product
|
|
52
|
+
is missing, having read `product.sku` with no fallback. It now reads the order
|
|
53
|
+
item's own `sku`, which is stored on the order and always there.
|
|
54
|
+
|
|
11
55
|
## [0.19.0] - 2026-08-26
|
|
12
56
|
|
|
13
57
|
### Added
|
package/dist/index.cjs
CHANGED
|
@@ -6511,7 +6511,8 @@ function pickPreselected(items, stored, keyOf) {
|
|
|
6511
6511
|
const list = items || [];
|
|
6512
6512
|
return (stored ? list.find((item) => keyOf(item) === stored) : void 0) || list[0];
|
|
6513
6513
|
}
|
|
6514
|
-
function CartCarriers(
|
|
6514
|
+
function CartCarriers(rawProps) {
|
|
6515
|
+
const props = useInfraProps(rawProps);
|
|
6515
6516
|
const [selectedName, setSelectedName] = React6.useState("");
|
|
6516
6517
|
const containerClass = props.carriersContainerClass || "cart-carriers";
|
|
6517
6518
|
const showLogo = props.showCarrierLogo !== false;
|
|
@@ -13753,11 +13754,11 @@ function OrderItemCard(props) {
|
|
|
13753
13754
|
className: isChildItem ? "propeller-order-item-card__cell propeller-order-item-card__cell--price px-6 py-2 text-right whitespace-nowrap text-sm text-muted-foreground" : "propeller-order-item-card__cell propeller-order-item-card__cell--price px-6 py-4 text-right whitespace-nowrap",
|
|
13754
13755
|
children: (() => {
|
|
13755
13756
|
const PriceImpl = props.priceComponent;
|
|
13756
|
-
if (PriceImpl) {
|
|
13757
|
+
if (PriceImpl && item?.product?.price) {
|
|
13757
13758
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
13758
13759
|
PriceImpl,
|
|
13759
13760
|
{
|
|
13760
|
-
price: item
|
|
13761
|
+
price: item.product.price,
|
|
13761
13762
|
currency: props.currency,
|
|
13762
13763
|
labels: props.labels
|
|
13763
13764
|
}
|
|
@@ -14766,7 +14767,7 @@ function OrderShipments(props) {
|
|
|
14766
14767
|
/* @__PURE__ */ jsxRuntime.jsxs("td", { className: "px-4 py-2 text-muted-foreground", children: [
|
|
14767
14768
|
!!shipmentItem.sku ? /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: shipmentItem.sku }) : null,
|
|
14768
14769
|
!shipmentItem.sku ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
14769
|
-
!!getOrderItemForShipmentItem(shipmentItem) ? /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: getOrderItemForShipmentItem(shipmentItem)?.product?.sku || "-" }) : null,
|
|
14770
|
+
!!getOrderItemForShipmentItem(shipmentItem) ? /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: getOrderItemForShipmentItem(shipmentItem)?.product?.sku || getOrderItemForShipmentItem(shipmentItem)?.sku || "-" }) : null,
|
|
14770
14771
|
!getOrderItemForShipmentItem(shipmentItem) ? /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: "-" }) : null
|
|
14771
14772
|
] }) : null
|
|
14772
14773
|
] }),
|
|
@@ -14963,6 +14964,11 @@ function OrderSummary(props) {
|
|
|
14963
14964
|
] });
|
|
14964
14965
|
}
|
|
14965
14966
|
var OrderSummary_default = OrderSummary;
|
|
14967
|
+
function OrderSummaryWithProvider(rawProps) {
|
|
14968
|
+
const props = useInfraProps(rawProps);
|
|
14969
|
+
return /* @__PURE__ */ jsxRuntime.jsx(OrderSummary_default, { ...props });
|
|
14970
|
+
}
|
|
14971
|
+
var OrderSummaryWithProvider_default = OrderSummaryWithProvider;
|
|
14966
14972
|
function OrderTotals(props) {
|
|
14967
14973
|
const showSubtotal = props.showSubtotal !== false;
|
|
14968
14974
|
const showDiscount = props.showDiscount !== false;
|
|
@@ -15045,6 +15051,11 @@ function OrderTotals(props) {
|
|
|
15045
15051
|
] });
|
|
15046
15052
|
}
|
|
15047
15053
|
var OrderTotals_default = OrderTotals;
|
|
15054
|
+
function OrderTotalsWithProvider(rawProps) {
|
|
15055
|
+
const props = useInfraProps(rawProps);
|
|
15056
|
+
return /* @__PURE__ */ jsxRuntime.jsx(OrderTotals_default, { ...props });
|
|
15057
|
+
}
|
|
15058
|
+
var OrderTotalsWithProvider_default = OrderTotalsWithProvider;
|
|
15048
15059
|
function PriceToggle(props) {
|
|
15049
15060
|
const isControlled = props.value !== void 0;
|
|
15050
15061
|
const [internal, setInternal] = React6.useState(props.initialState ?? true);
|
|
@@ -19166,8 +19177,8 @@ exports.OrderBonusItems = OrderBonusItems_default;
|
|
|
19166
19177
|
exports.OrderItemCard = OrderItemCard_default;
|
|
19167
19178
|
exports.OrderList = OrderList_default;
|
|
19168
19179
|
exports.OrderShipments = OrderShipments_default;
|
|
19169
|
-
exports.OrderSummary =
|
|
19170
|
-
exports.OrderTotals =
|
|
19180
|
+
exports.OrderSummary = OrderSummaryWithProvider_default;
|
|
19181
|
+
exports.OrderTotals = OrderTotalsWithProvider_default;
|
|
19171
19182
|
exports.PriceToggle = PriceToggle_default;
|
|
19172
19183
|
exports.ProductBulkPrices = ProductBulkPricesWithProvider_default;
|
|
19173
19184
|
exports.ProductBundles = ProductBundles_default;
|