npm @medusajs/medusa 1.16.0
v1.16.0

latest releases: 2.0.2-preview-20241113000427, 2.0.5-preview-20241113000238, 2.0.2-preview-20241112210226...
14 months ago

Highlights

Multi-language support in Medusa Admin

We are excited to announce multi-language support in Medusa Admin, allowing merchants to manage products, orders, customers, etc. in their preferred language.

This release ships English, Portuguese (Brazil), and French translations.

Check it out by upgrading to the latest version of Medusa Admin:

yarn add @medusajs/admin@latest

Huge thanks to @gempain and @mj-mehdizadeh for this amazing contribution. And thanks @dahorarodrigo for contributing with Portuguese translations.

If you want to help us translate Admin to other languages, see the contribution guide in our documentation.

Your efforts are highly appreciated!

Pricing Module

This release introduces the first iteration of our new standalone Pricing Module, which ships on npm under @medusajs/pricing. This version of the module comes with limited functionality as we've focused on putting down a solid foundation for follow-up work.

You can think of the Pricing Module as a way to assign a price to any type of resource, for example, ProductVariants.

We will share an announcement article soon, describing the module's features and what you can expect from follow-up iterations.

Breaking changes

Database schema changes
In our effort to build Standalone Commerce Modules, we will incrementally be dropping foreign key constraints across many business domains and change relationships between entities in the core, @medusajs/medusa.

Right now, we are focused on finalizing the Product (@medusajs/product) and Pricing (@medusajs/pricing) module, which has led to the following database changes.

The relationship between MoneyAmounts and ProductVariants has been changed from a Many-to-One to a Many-to-Many in package @medusajs/medusa. Therefore, you are required to apply the new migration by running the following command in your Medusa project:

npx @medusajs/medusa-cli migrations run

You can no longer create prices for variants as part of creating a product using only the ProductService.

await ProductService.create({ variants [ { prices: [ ... ] } ] }) // <-- This will throw an error, due to the change in DB schema mentioned above 

Instead, you should create products and variants separately. For example, you can do:

const product = await ProductService.create({ ... })

const variants = await ProductVariantService.create(product.id, variants)

Additionally, the following foreign key constraints have been dropped:

These changes are only relevant if you are using the feature flag isolate_product_domain. Please be careful about enabling this flag, as it will introduce experimental changes and work in progress.

  • ProductTaxRate to Product
  • ProductTypeTaxRate to ProductType
  • ClaimItem to ProductVariant
  • DiscountConditionProduct to Product
  • DiscountConditionProductCollection to ProductCollection
  • DiscountConditionProductTag to ProductTag
  • DiscountConditionProductType to ProductType
  • DiscountRule to Product

Features

Bugs

  • fix(medusa): Type in AbstractFulfillmentService by @pepijn-vanvlaanderen in #5003
  • fix(link-modules): Fix link module initialization by @adrien2p in #4990
  • fix(admin-ui): disabling analytics when opted out by @jporsay in #4939
  • fix(medusa): default sales channel for store variant endpoints by @pKorsholm in #4556
  • fix(link-modules): fix link configuration for product shipping profile by @riqwan in #5014
  • fix(orchestration): Infinite loop by reference update by @adrien2p in #5023
  • fix(medusa): duplicated migration by @carlos-r-l-rodrigues in #5029
  • fix(orchestration,link-modules,pricing,types): fix shippingprofile error outside of core + change link alias name by @riqwan in #5025
  • fix(medusa): Support fields param in list-variants by @olivermrbl in #5053
  • fix(create-medusa-app): fix command for windows OS by @shahednasser in #5061
  • fix(admin,admin-ui): copy public folder as part of admin build by @kasperkristensen in #5057
  • fix(medusa-react): fix useAdminAddStoreCurrency hook by @shahednasser in #5074
  • fix(medusa): Money amount detached migration by @adrien2p in #5079
  • fix(admin-ui): Load translations from path by @olivermrbl in #5064
  • feat(admin-ui): pt-BR translations and en version text fixes by @dahorarodrigo in #5066

Chores

Documentation

New Contributors

Full Changelog: v1.15.1...v1.16.0

Don't miss a new medusa release

NewReleases is sending notifications on new releases.