Skip to content

Commit ed53fc8

Browse files
authored
Merge pull request #2951 from Shopify/linx-variant-issue1
Added Variant ID to ProductApi
2 parents a0ee930 + e660e73 commit ed53fc8

File tree

3 files changed

+11
-0
lines changed

3 files changed

+11
-0
lines changed

.changeset/five-comics-leave.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+
Added variantId field to productApi

packages/ui-extensions/docs/surfaces/point-of-sale/staticPages/pages/versions.doc.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ Refer to the [migration guide](/docs/api/pos-ui-extensions/migrating) for more i
5656
## Important Fixes
5757
5858
- Update pos.draft-order-details.block.render allowed components to \`BlockComponents\`.
59+
- Added support for a product variant id field in the \`ProductApi\` interface.
5960
6061
### Features
6162
@@ -64,6 +65,7 @@ Refer to the [migration guide](/docs/api/pos-ui-extensions/migrating) for more i
6465
- Added \`executedAt\` property to \`BaseTransactionComplete\` interface.
6566
- Added optional \`exchangeId\` and \`returnId\` property to \`ReturnTransactionData\` interface.
6667
- Added optional \`onBlur\` handler to \`SearchBar\` component.
68+
- Added required \`variantId\` property to \`ProductApi\` interface.
6769
6870
`,
6971
},

packages/ui-extensions/src/surfaces/point-of-sale/render/api/product-api/product-api.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,8 @@ export interface ProductApiContent {
77
* The unique identifier for the product.
88
*/
99
id: number;
10+
/**
11+
* The unique identifier for the product variant.
12+
*/
13+
variantId: number;
1014
}

0 commit comments

Comments
 (0)