@blocklet/payment-react 1.14.4 → 1.14.5
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/es/payment/index.js +4 -1
- package/lib/payment/index.js +1 -1
- package/package.json +3 -3
- package/src/payment/index.tsx +4 -1
package/es/payment/index.js
CHANGED
|
@@ -234,7 +234,10 @@ export function PaymentInner({
|
|
|
234
234
|
{
|
|
235
235
|
items: state.checkoutSession.line_items,
|
|
236
236
|
trialInDays: state.checkoutSession.subscription_data?.trial_period_days || 0,
|
|
237
|
-
billingThreshold:
|
|
237
|
+
billingThreshold: Math.max(
|
|
238
|
+
state.checkoutSession.subscription_data?.billing_threshold_amount || 0,
|
|
239
|
+
state.checkoutSession.subscription_data?.min_stake_amount || 0
|
|
240
|
+
),
|
|
238
241
|
showStaking: method.type === "arcblock",
|
|
239
242
|
currency,
|
|
240
243
|
onUpsell,
|
package/lib/payment/index.js
CHANGED
|
@@ -311,7 +311,7 @@ function PaymentInner({
|
|
|
311
311
|
}) : null, /* @__PURE__ */(0, _jsxRuntime.jsx)(_summary.default, {
|
|
312
312
|
items: state.checkoutSession.line_items,
|
|
313
313
|
trialInDays: state.checkoutSession.subscription_data?.trial_period_days || 0,
|
|
314
|
-
billingThreshold: state.checkoutSession.subscription_data?.billing_threshold_amount || 0,
|
|
314
|
+
billingThreshold: Math.max(state.checkoutSession.subscription_data?.billing_threshold_amount || 0, state.checkoutSession.subscription_data?.min_stake_amount || 0),
|
|
315
315
|
showStaking: method.type === "arcblock",
|
|
316
316
|
currency,
|
|
317
317
|
onUpsell,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@blocklet/payment-react",
|
|
3
|
-
"version": "1.14.
|
|
3
|
+
"version": "1.14.5",
|
|
4
4
|
"description": "Reusable react components for payment kit v2",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -91,7 +91,7 @@
|
|
|
91
91
|
"@babel/core": "^7.24.7",
|
|
92
92
|
"@babel/preset-env": "^7.24.7",
|
|
93
93
|
"@babel/preset-react": "^7.24.7",
|
|
94
|
-
"@blocklet/payment-types": "1.14.
|
|
94
|
+
"@blocklet/payment-types": "1.14.5",
|
|
95
95
|
"@storybook/addon-essentials": "^7.6.19",
|
|
96
96
|
"@storybook/addon-interactions": "^7.6.19",
|
|
97
97
|
"@storybook/addon-links": "^7.6.19",
|
|
@@ -120,5 +120,5 @@
|
|
|
120
120
|
"vite-plugin-babel": "^1.2.0",
|
|
121
121
|
"vite-plugin-node-polyfills": "^0.21.0"
|
|
122
122
|
},
|
|
123
|
-
"gitHead": "
|
|
123
|
+
"gitHead": "e4715805a87b2e4e3622564f4bc26578f19211e4"
|
|
124
124
|
}
|
package/src/payment/index.tsx
CHANGED
|
@@ -280,7 +280,10 @@ export function PaymentInner({
|
|
|
280
280
|
<PaymentSummary
|
|
281
281
|
items={state.checkoutSession.line_items}
|
|
282
282
|
trialInDays={state.checkoutSession.subscription_data?.trial_period_days || 0}
|
|
283
|
-
billingThreshold={
|
|
283
|
+
billingThreshold={Math.max(
|
|
284
|
+
state.checkoutSession.subscription_data?.billing_threshold_amount || 0,
|
|
285
|
+
state.checkoutSession.subscription_data?.min_stake_amount || 0
|
|
286
|
+
)}
|
|
284
287
|
showStaking={method.type === 'arcblock'}
|
|
285
288
|
currency={currency}
|
|
286
289
|
onUpsell={onUpsell}
|