chore: add a link to the storefront docs for cart item totals type (#13514)

This commit is contained in:
Shahed Nasser authored and GitHub committed 2025-09-15 16:18:20 +00:00
1 parent 8c21243f42
commit 4af1815c5b
1 file changed
+46 -8
+46 -8
View File
@@ -353,43 +353,59 @@ export interface BaseCartShippingMethod {
/** /**
* The original total of the cart shipping method. * The original total of the cart shipping method.
* This field is only available if you expand the `shipping_methods.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-shipping-method-totals) guide.
*/ */
original_total: number original_total?: number
/** /**
* The original subtotal of the cart shipping method. * The original subtotal of the cart shipping method.
* This field is only available if you expand the `shipping_methods.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-shipping-method-totals) guide.
*/ */
original_subtotal: number original_subtotal?: number
/** /**
* The original tax total of the cart shipping method. * The original tax total of the cart shipping method.
* This field is only available if you expand the `shipping_methods.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-shipping-method-totals) guide.
*/ */
original_tax_total: number original_tax_total?: number
/** /**
* The total of the cart shipping method. * The total of the cart shipping method.
* This field is only available if you expand the `shipping_methods.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-shipping-method-totals) guide.
*/ */
total: number total?: number
/** /**
* The subtotal of the cart shipping method. * The subtotal of the cart shipping method.
* This field is only available if you expand the `shipping_methods.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-shipping-method-totals) guide.
*/ */
subtotal: number subtotal?: number
/** /**
* The tax total of the cart shipping method. * The tax total of the cart shipping method.
* This field is only available if you expand the `shipping_methods.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-shipping-method-totals) guide.
*/ */
tax_total: number tax_total?: number
/** /**
* The discount total of the cart shipping method. * The discount total of the cart shipping method.
* This field is only available if you expand the `shipping_methods.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-shipping-method-totals) guide.
*/ */
discount_total: number discount_total?: number
/** /**
* The discount tax total of the cart shipping method. * The discount tax total of the cart shipping method.
* This field is only available if you expand the `shipping_methods.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-shipping-method-totals) guide.
*/ */
discount_tax_total: number discount_tax_total?: number
} }
/** /**
@@ -573,56 +589,78 @@ export interface BaseCartLineItem extends BaseCartLineItemTotals {
export interface BaseCartLineItemTotals { export interface BaseCartLineItemTotals {
/** /**
* The original total of the cart line item. * The original total of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
original_total?: number original_total?: number
/** /**
* The original subtotal of the cart line item. * The original subtotal of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
original_subtotal?: number original_subtotal?: number
/** /**
* The original tax total of the cart line item. * The original tax total of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
original_tax_total?: number original_tax_total?: number
/** /**
* The item total of the cart line item. * The item total of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
item_total?: number item_total?: number
/** /**
* The item subtotal of the cart line item. * The item subtotal of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
item_subtotal?: number item_subtotal?: number
/** /**
* The item tax total of the cart line item. * The item tax total of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
item_tax_total?: number item_tax_total?: number
/** /**
* The total of the cart line item. * The total of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
total?: number total?: number
/** /**
* The subtotal of the cart line item. * The subtotal of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
subtotal?: number subtotal?: number
/** /**
* The tax total of the cart line item. * The tax total of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
tax_total?: number tax_total?: number
/** /**
* The discount total of the cart line item. * The discount total of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
discount_total?: number discount_total?: number
/** /**
* The discount tax total of the cart line item. * The discount tax total of the cart line item.
* This field is only available if you expand the `items.*` relation. Learn more in the
* [Cart Totals](https://docs.medusajs.com/resources/storefront-development/cart/totals#retrieve-and-show-cart-item-totals) guide.
*/ */
discount_tax_total?: number discount_tax_total?: number
} }