@nok-integration/storefront-react 0.19.34 → 0.19.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1568,7 +1568,7 @@ declare const CategoryPage: z.ZodObject<{
1568
1568
  quote: string;
1569
1569
  author: string;
1570
1570
  }>, "many">;
1571
- /** @deprecated Retired 31 Aug 2026. Never populated; see the note above. */
1571
+ /** @deprecated Retired and never populated; see the note above. */
1572
1572
  disclaimer: z.ZodOptional<z.ZodString>;
1573
1573
  }, "strip", z.ZodTypeAny, {
1574
1574
  kind: "review";
@@ -2875,6 +2875,7 @@ declare function createClient(options: ClientOptions): {
2875
2875
  item_count: number;
2876
2876
  image?: string | undefined;
2877
2877
  images?: string[] | undefined;
2878
+ return_status?: "reported" | "package_received" | "completed" | undefined;
2878
2879
  }[];
2879
2880
  }>;
2880
2881
  get: (orderRef: string) => Promise<{
@@ -4237,10 +4238,16 @@ declare const OrderStatus: z.ZodEnum<["confirmed", "packed", "shipped", "deliver
4237
4238
 
4238
4239
  declare type OrderStatus = z.infer<typeof OrderStatus>;
4239
4240
 
4240
- export declare function OrderStatusBadge({ status }: OrderStatusBadgeProps): JSX.Element;
4241
+ export declare function OrderStatusBadge({ status, returnStatus }: OrderStatusBadgeProps): JSX.Element;
4241
4242
 
4242
4243
  export declare interface OrderStatusBadgeProps {
4243
4244
  status: OrderProgressStep;
4245
+ /**
4246
+ * An open return against this order, when there is one. The engine omits it once every
4247
+ * return has completed, so a value here always means "still outstanding" — this component
4248
+ * does not have to decide which return statuses count as started.
4249
+ */
4250
+ returnStatus?: ReturnStatus;
4244
4251
  }
4245
4252
 
4246
4253
  /**
@@ -5363,10 +5370,14 @@ export declare interface ReturnItemsViewProps {
5363
5370
  * scripted download because the sheet a fan sees this in may be a webview, and a
5364
5371
  * script-driven save is exactly what a webview blocks.
5365
5372
  *
5366
- * **The button is only drawn when there is a label.** The frame promises the PDF by email
5367
- * as well, and that promise is the one that survives a link this screen cannot produce
5368
- * so when `label_url` is absent the email line still tells the fan where to look, and no
5369
- * button is offered that would 404.
5373
+ * **The button is always drawn, exactly as the frame draws it**, and so is the line above
5374
+ * it that promises one. The engine publishes a `label_url` for every return, so the two
5375
+ * halves cannot disagree a screen saying "tap the button below" over no button is the
5376
+ * failure this arrangement rules out.
5377
+ *
5378
+ * The document itself is produced by the OMS against the return, so a download attempted
5379
+ * in the moments before the OMS holds it can fail. That is a bounded, visible failure
5380
+ * rather than a screen that contradicts itself.
5370
5381
  *
5371
5382
  * **The items come first, above the heading**, which is where the frame puts them and
5372
5383
  * where they were missing. Two screens of instructions with nothing naming the garment is
@@ -5408,6 +5419,17 @@ declare const ReturnRequestItem: z.ZodObject<{
5408
5419
 
5409
5420
  declare type ReturnRequestItem = z.infer<typeof ReturnRequestItem>;
5410
5421
 
5422
+ /**
5423
+ * Where a return has got to.
5424
+ *
5425
+ * Three steps, which is what the frame draws — reported, received, completed. The parcel
5426
+ * is in the post for most of that time and nobody can say more than "we have not got it
5427
+ * yet", so a finer breakdown would be invented rather than observed.
5428
+ */
5429
+ declare const ReturnStatus: z.ZodEnum<["reported", "package_received", "completed"]>;
5430
+
5431
+ declare type ReturnStatus = z.infer<typeof ReturnStatus>;
5432
+
5411
5433
  export declare function ReturnTrackingView({ ret, locale: localeProp }: ReturnTrackingViewProps): JSX.Element;
5412
5434
 
5413
5435
  export declare interface ReturnTrackingViewProps {
@@ -5424,10 +5446,10 @@ declare interface Review {
5424
5446
  /**
5425
5447
  * Tester-quote carousel — swipeable cards with dot pagination.
5426
5448
  *
5427
- * There is no disclaimer line. One used to sit under the dots saying these were staff
5428
- * quotes rather than verified reviews, and it was the block's one deliberate departure
5429
- * from the frame; DAZN asked for it removed on 31 Aug 2026. The `author` under each quote
5430
- * is what says whose words they are, so a quote must never arrive without one.
5449
+ * These are tester quotes, not customer reviews: no stars and no ratings, and the `author`
5450
+ * under each quote is what says whose words they are a team and a city, never a person.
5451
+ * A quote must therefore never arrive without one. The block draws no disclaimer line, in
5452
+ * line with the frame.
5431
5453
  */
5432
5454
  export declare function ReviewCarousel({ quotes }: ReviewCarouselProps): JSX.Element;
5433
5455
 
package/dist/index.mjs CHANGED
@@ -4647,7 +4647,7 @@ function requireOrderTracking() {
4647
4647
  Object.defineProperty(exports, "__esModule", {
4648
4648
  value: true
4649
4649
  });
4650
- exports.ReturnDetail = exports.ReturnItem = exports.ReturnProgressEntry = exports.CreateReturnRequest = exports.ReturnRequestItem = exports.FanReturnReason = exports.RequestCancellationRequest = exports.FanCancelReason = exports.OrderDetail = exports.ReturnSummary = exports.ReturnStatus = exports.OrderList = exports.OrderSummaryItem = exports.OrderItem = exports.OrderTracking = exports.OrderProgressEntry = exports.OrderProgressStep = void 0;
4650
+ exports.ReturnDetail = exports.ReturnItem = exports.ReturnProgressEntry = exports.CreateReturnRequest = exports.ReturnRequestItem = exports.FanReturnReason = exports.RequestCancellationRequest = exports.FanCancelReason = exports.OrderDetail = exports.ReturnSummary = exports.OrderList = exports.OrderSummaryItem = exports.ReturnStatus = exports.OrderItem = exports.OrderTracking = exports.OrderProgressEntry = exports.OrderProgressStep = void 0;
4651
4651
  const zod_1 = requireZod();
4652
4652
  const money_1 = requireMoney();
4653
4653
  const ids_1 = requireIds();
@@ -4679,6 +4679,7 @@ function requireOrderTracking() {
4679
4679
  refunded_qty: zod_1.z.number().int().nonnegative(),
4680
4680
  returned_qty: zod_1.z.number().int().nonnegative().optional()
4681
4681
  });
4682
+ exports.ReturnStatus = zod_1.z.enum(["reported", "package_received", "completed"]);
4682
4683
  exports.OrderSummaryItem = zod_1.z.object({
4683
4684
  order_ref: ids_1.OrderRef,
4684
4685
  placed_at: common_1.Timestamp,
@@ -4688,12 +4689,12 @@ function requireOrderTracking() {
4688
4689
  total: money_1.Money,
4689
4690
  item_count: zod_1.z.number().int().nonnegative(),
4690
4691
  image: common_1.Url.optional(),
4691
- images: zod_1.z.array(common_1.Url).max(3).optional()
4692
+ images: zod_1.z.array(common_1.Url).max(3).optional(),
4693
+ return_status: exports.ReturnStatus.optional()
4692
4694
  });
4693
4695
  exports.OrderList = zod_1.z.object({
4694
4696
  orders: zod_1.z.array(exports.OrderSummaryItem)
4695
4697
  });
4696
- exports.ReturnStatus = zod_1.z.enum(["reported", "package_received", "completed"]);
4697
4698
  exports.ReturnSummary = zod_1.z.object({
4698
4699
  return_ref: zod_1.z.string().min(1),
4699
4700
  status: exports.ReturnStatus,
@@ -5411,13 +5412,13 @@ function ShopVideo({ src, poster, fill: fill2 = false, className, style, priorit
5411
5412
  const badge$5 = "_badge_1bagf_1";
5412
5413
  const neutral$1 = "_neutral_1bagf_12";
5413
5414
  const success$1 = "_success_1bagf_17";
5414
- const critical$1 = "_critical_1bagf_22";
5415
+ const critical$2 = "_critical_1bagf_22";
5415
5416
  const promo = "_promo_1bagf_27";
5416
5417
  const styles$R = {
5417
5418
  badge: badge$5,
5418
5419
  neutral: neutral$1,
5419
5420
  success: success$1,
5420
- critical: critical$1,
5421
+ critical: critical$2,
5421
5422
  promo
5422
5423
  };
5423
5424
  function Badge({ tone = "neutral", children }) {
@@ -6014,7 +6015,7 @@ const message$1 = "_message_1tc1q_120";
6014
6015
  const action = "_action_1tc1q_133";
6015
6016
  const neutral = "_neutral_1tc1q_158";
6016
6017
  const success = "_success_1tc1q_163";
6017
- const critical = "_critical_1tc1q_168";
6018
+ const critical$1 = "_critical_1tc1q_168";
6018
6019
  const rich = "_rich_1tc1q_183";
6019
6020
  const description = "_description_1tc1q_198";
6020
6021
  const thumb$3 = "_thumb_1tc1q_216";
@@ -6029,7 +6030,7 @@ const styles$K = {
6029
6030
  action,
6030
6031
  neutral,
6031
6032
  success,
6032
- critical,
6033
+ critical: critical$1,
6033
6034
  rich,
6034
6035
  description,
6035
6036
  thumb: thumb$3,
@@ -7983,15 +7984,15 @@ function OrderConfirmationContent({ orderRef, locale: localeProp, onDone }) {
7983
7984
  })]
7984
7985
  });
7985
7986
  }
7986
- const badge$2 = "_badge_ghd02_6";
7987
- const progress = "_progress_ghd02_22";
7988
- const delivered = "_delivered_ghd02_27";
7989
- const cancelled = "_cancelled_ghd02_32";
7987
+ const badge$2 = "_badge_1w0zn_6";
7988
+ const progress = "_progress_1w0zn_22";
7989
+ const delivered = "_delivered_1w0zn_27";
7990
+ const critical = "_critical_1w0zn_36";
7990
7991
  const styles$w = {
7991
7992
  badge: badge$2,
7992
7993
  progress,
7993
7994
  delivered,
7994
- cancelled
7995
+ critical
7995
7996
  };
7996
7997
  const LABEL = {
7997
7998
  packing: "In progress",
@@ -8005,10 +8006,16 @@ const TONE = {
8005
8006
  on_its_way: "progress",
8006
8007
  out_for_delivery: "progress",
8007
8008
  delivered: "delivered",
8008
- cancelled: "cancelled"
8009
+ cancelled: "critical"
8009
8010
  };
8010
- function OrderStatusBadge({ status }) {
8011
+ function OrderStatusBadge({ status, returnStatus }) {
8011
8012
  const t = useT();
8013
+ if (returnStatus) {
8014
+ return jsx("span", {
8015
+ className: [styles$w.badge, styles$w.critical].join(" "),
8016
+ children: t("Return started")
8017
+ });
8018
+ }
8012
8019
  const label2 = LABEL[status] ?? status.replace(/_/g, " ");
8013
8020
  const tone = TONE[status] ?? "progress";
8014
8021
  return jsx("span", {
@@ -8162,7 +8169,8 @@ function OrderCard({ order, locale, onOpen }) {
8162
8169
  children: formatPlaced(order.placed_at, locale)
8163
8170
  })]
8164
8171
  }), jsx(OrderStatusBadge, {
8165
- status: order.status
8172
+ status: order.status,
8173
+ returnStatus: order.return_status
8166
8174
  })]
8167
8175
  }), jsxs("div", {
8168
8176
  className: styles$v.bottom,
@@ -4647,7 +4647,7 @@ function requireOrderTracking() {
4647
4647
  Object.defineProperty(exports, "__esModule", {
4648
4648
  value: true
4649
4649
  });
4650
- exports.ReturnDetail = exports.ReturnItem = exports.ReturnProgressEntry = exports.CreateReturnRequest = exports.ReturnRequestItem = exports.FanReturnReason = exports.RequestCancellationRequest = exports.FanCancelReason = exports.OrderDetail = exports.ReturnSummary = exports.ReturnStatus = exports.OrderList = exports.OrderSummaryItem = exports.OrderItem = exports.OrderTracking = exports.OrderProgressEntry = exports.OrderProgressStep = void 0;
4650
+ exports.ReturnDetail = exports.ReturnItem = exports.ReturnProgressEntry = exports.CreateReturnRequest = exports.ReturnRequestItem = exports.FanReturnReason = exports.RequestCancellationRequest = exports.FanCancelReason = exports.OrderDetail = exports.ReturnSummary = exports.OrderList = exports.OrderSummaryItem = exports.ReturnStatus = exports.OrderItem = exports.OrderTracking = exports.OrderProgressEntry = exports.OrderProgressStep = void 0;
4651
4651
  const zod_1 = requireZod();
4652
4652
  const money_1 = requireMoney();
4653
4653
  const ids_1 = requireIds();
@@ -4679,6 +4679,7 @@ function requireOrderTracking() {
4679
4679
  refunded_qty: zod_1.z.number().int().nonnegative(),
4680
4680
  returned_qty: zod_1.z.number().int().nonnegative().optional()
4681
4681
  });
4682
+ exports.ReturnStatus = zod_1.z.enum(["reported", "package_received", "completed"]);
4682
4683
  exports.OrderSummaryItem = zod_1.z.object({
4683
4684
  order_ref: ids_1.OrderRef,
4684
4685
  placed_at: common_1.Timestamp,
@@ -4688,12 +4689,12 @@ function requireOrderTracking() {
4688
4689
  total: money_1.Money,
4689
4690
  item_count: zod_1.z.number().int().nonnegative(),
4690
4691
  image: common_1.Url.optional(),
4691
- images: zod_1.z.array(common_1.Url).max(3).optional()
4692
+ images: zod_1.z.array(common_1.Url).max(3).optional(),
4693
+ return_status: exports.ReturnStatus.optional()
4692
4694
  });
4693
4695
  exports.OrderList = zod_1.z.object({
4694
4696
  orders: zod_1.z.array(exports.OrderSummaryItem)
4695
4697
  });
4696
- exports.ReturnStatus = zod_1.z.enum(["reported", "package_received", "completed"]);
4697
4698
  exports.ReturnSummary = zod_1.z.object({
4698
4699
  return_ref: zod_1.z.string().min(1),
4699
4700
  status: exports.ReturnStatus,
@@ -5411,13 +5412,13 @@ function ShopVideo({ src, poster, fill: fill2 = false, className, style, priorit
5411
5412
  const badge$5 = "_badge_1bagf_1";
5412
5413
  const neutral$1 = "_neutral_1bagf_12";
5413
5414
  const success$1 = "_success_1bagf_17";
5414
- const critical$1 = "_critical_1bagf_22";
5415
+ const critical$2 = "_critical_1bagf_22";
5415
5416
  const promo = "_promo_1bagf_27";
5416
5417
  const styles$R = {
5417
5418
  badge: badge$5,
5418
5419
  neutral: neutral$1,
5419
5420
  success: success$1,
5420
- critical: critical$1,
5421
+ critical: critical$2,
5421
5422
  promo
5422
5423
  };
5423
5424
  function Badge({ tone = "neutral", children }) {
@@ -6014,7 +6015,7 @@ const message$1 = "_message_1tc1q_120";
6014
6015
  const action = "_action_1tc1q_133";
6015
6016
  const neutral = "_neutral_1tc1q_158";
6016
6017
  const success = "_success_1tc1q_163";
6017
- const critical = "_critical_1tc1q_168";
6018
+ const critical$1 = "_critical_1tc1q_168";
6018
6019
  const rich = "_rich_1tc1q_183";
6019
6020
  const description = "_description_1tc1q_198";
6020
6021
  const thumb$3 = "_thumb_1tc1q_216";
@@ -6029,7 +6030,7 @@ const styles$K = {
6029
6030
  action,
6030
6031
  neutral,
6031
6032
  success,
6032
- critical,
6033
+ critical: critical$1,
6033
6034
  rich,
6034
6035
  description,
6035
6036
  thumb: thumb$3,
@@ -7983,15 +7984,15 @@ function OrderConfirmationContent({ orderRef, locale: localeProp, onDone }) {
7983
7984
  })]
7984
7985
  });
7985
7986
  }
7986
- const badge$2 = "_badge_ghd02_6";
7987
- const progress = "_progress_ghd02_22";
7988
- const delivered = "_delivered_ghd02_27";
7989
- const cancelled = "_cancelled_ghd02_32";
7987
+ const badge$2 = "_badge_1w0zn_6";
7988
+ const progress = "_progress_1w0zn_22";
7989
+ const delivered = "_delivered_1w0zn_27";
7990
+ const critical = "_critical_1w0zn_36";
7990
7991
  const styles$w = {
7991
7992
  badge: badge$2,
7992
7993
  progress,
7993
7994
  delivered,
7994
- cancelled
7995
+ critical
7995
7996
  };
7996
7997
  const LABEL = {
7997
7998
  packing: "In progress",
@@ -8005,10 +8006,16 @@ const TONE = {
8005
8006
  on_its_way: "progress",
8006
8007
  out_for_delivery: "progress",
8007
8008
  delivered: "delivered",
8008
- cancelled: "cancelled"
8009
+ cancelled: "critical"
8009
8010
  };
8010
- function OrderStatusBadge({ status }) {
8011
+ function OrderStatusBadge({ status, returnStatus }) {
8011
8012
  const t = useT();
8013
+ if (returnStatus) {
8014
+ return jsx("span", {
8015
+ className: [styles$w.badge, styles$w.critical].join(" "),
8016
+ children: t("Return started")
8017
+ });
8018
+ }
8012
8019
  const label2 = LABEL[status] ?? status.replace(/_/g, " ");
8013
8020
  const tone = TONE[status] ?? "progress";
8014
8021
  return jsx("span", {
@@ -8162,7 +8169,8 @@ function OrderCard({ order, locale, onOpen }) {
8162
8169
  children: formatPlaced(order.placed_at, locale)
8163
8170
  })]
8164
8171
  }), jsx(OrderStatusBadge, {
8165
- status: order.status
8172
+ status: order.status,
8173
+ returnStatus: order.return_status
8166
8174
  })]
8167
8175
  }), jsxs("div", {
8168
8176
  className: styles$v.bottom,
@@ -1580,7 +1580,7 @@
1580
1580
  ._done_2uqhz_107 {
1581
1581
  border-color: var(--color-surface-max);
1582
1582
  }
1583
- ._badge_ghd02_6 {
1583
+ ._badge_1w0zn_6 {
1584
1584
  display: inline-flex;
1585
1585
  align-items: center;
1586
1586
  justify-content: center;
@@ -1595,15 +1595,15 @@
1595
1595
  text-transform: uppercase;
1596
1596
  white-space: nowrap;
1597
1597
  }
1598
- ._progress_ghd02_22 {
1598
+ ._progress_1w0zn_22 {
1599
1599
  background: var(--color-state-surface-warning-soft);
1600
1600
  color: var(--color-state-text-warning);
1601
1601
  }
1602
- ._delivered_ghd02_27 {
1602
+ ._delivered_1w0zn_27 {
1603
1603
  background: var(--color-state-surface-success-soft);
1604
1604
  color: var(--color-state-text-success);
1605
1605
  }
1606
- ._cancelled_ghd02_32 {
1606
+ ._critical_1w0zn_36 {
1607
1607
  background: var(--color-state-surface-critical-soft);
1608
1608
  color: var(--color-state-text-critical);
1609
1609
  }
package/dist/styles.css CHANGED
@@ -1580,7 +1580,7 @@
1580
1580
  ._done_2uqhz_107 {
1581
1581
  border-color: var(--color-surface-max);
1582
1582
  }
1583
- ._badge_ghd02_6 {
1583
+ ._badge_1w0zn_6 {
1584
1584
  display: inline-flex;
1585
1585
  align-items: center;
1586
1586
  justify-content: center;
@@ -1595,15 +1595,15 @@
1595
1595
  text-transform: uppercase;
1596
1596
  white-space: nowrap;
1597
1597
  }
1598
- ._progress_ghd02_22 {
1598
+ ._progress_1w0zn_22 {
1599
1599
  background: var(--color-state-surface-warning-soft);
1600
1600
  color: var(--color-state-text-warning);
1601
1601
  }
1602
- ._delivered_ghd02_27 {
1602
+ ._delivered_1w0zn_27 {
1603
1603
  background: var(--color-state-surface-success-soft);
1604
1604
  color: var(--color-state-text-success);
1605
1605
  }
1606
- ._cancelled_ghd02_32 {
1606
+ ._critical_1w0zn_36 {
1607
1607
  background: var(--color-state-surface-critical-soft);
1608
1608
  color: var(--color-state-text-critical);
1609
1609
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nok-integration/storefront-react",
3
- "version": "0.19.34",
3
+ "version": "0.19.36",
4
4
  "description": "Mountable React storefront components: catalogue, product detail and cart, mounted directly into a host DOM tree. No iframe.",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",