@stigg/react-sdk 5.2.0 → 5.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/react-sdk.cjs.development.js +5 -4
- package/dist/react-sdk.cjs.development.js.map +1 -1
- package/dist/react-sdk.cjs.production.min.js +1 -1
- package/dist/react-sdk.cjs.production.min.js.map +1 -1
- package/dist/react-sdk.esm.js +5 -4
- package/dist/react-sdk.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/checkout/summary/components/LineItems.tsx +8 -2
package/package.json
CHANGED
|
@@ -80,6 +80,8 @@ export const BilledPriceLineItem = ({
|
|
|
80
80
|
amount = price.amount!;
|
|
81
81
|
}
|
|
82
82
|
|
|
83
|
+
const totalLineAmount = price.isTieredPrice ? amount : amount * quantity;
|
|
84
|
+
|
|
83
85
|
return (
|
|
84
86
|
<LineItemContainer>
|
|
85
87
|
<LineItemRow style={{ alignItems: 'flex-start' }}>
|
|
@@ -89,14 +91,18 @@ export const BilledPriceLineItem = ({
|
|
|
89
91
|
</Typography>
|
|
90
92
|
{(quantity > 1 || billingPeriod === BillingPeriod.Annually) && (
|
|
91
93
|
<Typography variant="body1" color="secondary">
|
|
92
|
-
{getPriceString({ amount, price, quantity })}
|
|
94
|
+
{getPriceString({ amount: totalLineAmount, price, quantity })}
|
|
93
95
|
</Typography>
|
|
94
96
|
)}
|
|
95
97
|
</Grid>
|
|
96
98
|
<Grid item display="flex" gap={1} alignItems="center">
|
|
97
99
|
{isPayAsYouGo && <PayAsYouGoPriceTooltip checkoutLocalization={checkoutLocalization} />}
|
|
98
100
|
<Typography variant="body1" color="secondary" style={{ wordBreak: 'break-word' }}>
|
|
99
|
-
{currencyPriceFormatter({
|
|
101
|
+
{currencyPriceFormatter({
|
|
102
|
+
amount: totalLineAmount,
|
|
103
|
+
currency: price.currency,
|
|
104
|
+
minimumFractionDigits: 2,
|
|
105
|
+
})}
|
|
100
106
|
{isPayAsYouGo && ' / unit'}
|
|
101
107
|
</Typography>
|
|
102
108
|
</Grid>
|