Skip to content

Commit 6652f55

Browse files
Merge pull request #3538 from Shopify/adds-components-to-pos-cart-line-items-2025-07
Adds components to point of sale line items for product bundles
2 parents 6f0af66 + a741a10 commit 6652f55

File tree

2 files changed

+32
-0
lines changed

2 files changed

+32
-0
lines changed

.changeset/cold-windows-occur.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@shopify/ui-extensions': minor
3+
---
4+
5+
Adds components to point of sale cart LineItem interface to represent product bundle items.

packages/ui-extensions/src/surfaces/point-of-sale/types/cart.ts

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,33 @@ export interface LineItem {
4949
properties: {[key: string]: string};
5050
isGiftCard: boolean;
5151
attributedUserId?: number;
52+
/**
53+
* Bundle components for this line item. Only present for product bundles.
54+
* Each component represents an individual item within the bundle with its own tax information.
55+
*/
56+
components?: LineItemComponent[];
57+
}
58+
59+
/**
60+
* Represents a component of a product bundle line item.
61+
* Bundle components contain the individual items that make up a bundle,
62+
* each with their own pricing and tax information.
63+
*/
64+
export interface LineItemComponent {
65+
/** The title/name of the component product */
66+
title?: string;
67+
/** The quantity of this component in the bundle */
68+
quantity: number;
69+
/** The price of this component */
70+
price?: number;
71+
/** Whether this component is taxable */
72+
taxable: boolean;
73+
/** Tax lines applied to this component */
74+
taxLines: TaxLine[];
75+
/** The variant ID of this component, if applicable */
76+
variantId?: number;
77+
/** The product ID of this component, if applicable */
78+
productId?: number;
5279
}
5380

5481
export interface Discount {

0 commit comments

Comments
 (0)