fix(types): add locale to the query parameters of product query types (#14282)

This commit is contained in:
Shahed Nasser authored and GitHub committed 2025-12-12 11:11:44 +02:00
1 parent 31a057558c
commit 8bb2ac654c
2 files changed
+27 -1

No files matched your search

+5
View File
@@ -0,0 +1,5 @@
---
"@medusajs/types": patch
---
fix(types): add locale to the query parameters of product query types
@@ -25,7 +25,18 @@ export interface StoreProductPricingContext {
*/ */
cart_id?: string cart_id?: string
} }
export interface StoreProductParams extends SelectParams, StoreProductPricingContext {} export interface StoreProductParams extends SelectParams, StoreProductPricingContext {
/**
* The locale code in BCP 47 format. Information of the
* product and related entities will be localized based on the provided locale.
*
* Learn more in the [Serve Translations in Storefront](https://docs.medusajs.com/resources/commerce-modules/translations/storefront) guide.
*
* @example
* "en-US"
*/
locale?: string
}
export interface StoreProductListParams export interface StoreProductListParams
extends Omit<BaseProductListParams, "tags" | "status" | "categories" | "deleted_at" | "with_deleted">, StoreProductPricingContext { extends Omit<BaseProductListParams, "tags" | "status" | "categories" | "deleted_at" | "with_deleted">, StoreProductPricingContext {
@@ -37,4 +48,14 @@ export interface StoreProductListParams
* Filter by the product's variants. * Filter by the product's variants.
*/ */
variants?: Pick<StoreProductVariantParams, "options"> variants?: Pick<StoreProductVariantParams, "options">
/**
* The locale code in BCP 47 format. Information of the
* product and related entities will be localized based on the provided locale.
*
* Learn more in the [Serve Translations in Storefront](https://docs.medusajs.com/resources/commerce-modules/translations/storefront) guide.
*
* @example
* "en-US"
*/
locale?: string
} }