@blocklet/payment-react 1.26.3 → 1.26.4

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.
@@ -10,12 +10,14 @@ export default function ServiceSuspendedDialog({ open, onClose }) {
10
10
  {
11
11
  open,
12
12
  onClose,
13
- PaperProps: {
14
- sx: {
15
- borderRadius: 3,
16
- maxWidth: 400,
17
- mx: "auto",
18
- overflow: "hidden"
13
+ slotProps: {
14
+ paper: {
15
+ sx: {
16
+ borderRadius: 3,
17
+ maxWidth: 400,
18
+ mx: "auto",
19
+ overflow: "hidden"
20
+ }
19
21
  }
20
22
  },
21
23
  children: /* @__PURE__ */ jsxs(DialogContent, { sx: { p: 0 }, children: [
@@ -1451,16 +1451,7 @@ export default function PaymentForm({
1451
1451
  }
1452
1452
  }
1453
1453
  ),
1454
- state.serviceSuspended && /* @__PURE__ */ jsx(
1455
- ConfirmDialog,
1456
- {
1457
- onConfirm: () => setState({ serviceSuspended: false }),
1458
- onCancel: () => setState({ serviceSuspended: false }),
1459
- title: t("payment.checkout.stopAcceptingOrders.title"),
1460
- message: t("payment.checkout.stopAcceptingOrders.description"),
1461
- confirm: t("common.confirm")
1462
- }
1463
- ),
1454
+ state.serviceSuspended && /* @__PURE__ */ jsx(ServiceSuspendedDialog, { open: true, onClose: () => setState({ serviceSuspended: false }) }),
1464
1455
  FastCheckoutConfirmDialog,
1465
1456
  CreditInsufficientDialog,
1466
1457
  PriceUpdatedDialog,
@@ -20,12 +20,14 @@ function ServiceSuspendedDialog({
20
20
  return /* @__PURE__ */(0, _jsxRuntime.jsx)(_material.Dialog, {
21
21
  open,
22
22
  onClose,
23
- PaperProps: {
24
- sx: {
25
- borderRadius: 3,
26
- maxWidth: 400,
27
- mx: "auto",
28
- overflow: "hidden"
23
+ slotProps: {
24
+ paper: {
25
+ sx: {
26
+ borderRadius: 3,
27
+ maxWidth: 400,
28
+ mx: "auto",
29
+ overflow: "hidden"
30
+ }
29
31
  }
30
32
  },
31
33
  children: /* @__PURE__ */(0, _jsxRuntime.jsxs)(_material.DialogContent, {
@@ -1630,16 +1630,11 @@ function PaymentForm({
1630
1630
  }),
1631
1631
  title: t("payment.customer.pastDue.alert.title")
1632
1632
  }
1633
- }), state.serviceSuspended && /* @__PURE__ */(0, _jsxRuntime.jsx)(_confirm.default, {
1634
- onConfirm: () => setState({
1635
- serviceSuspended: false
1636
- }),
1637
- onCancel: () => setState({
1633
+ }), state.serviceSuspended && /* @__PURE__ */(0, _jsxRuntime.jsx)(_serviceSuspendedDialog.default, {
1634
+ open: true,
1635
+ onClose: () => setState({
1638
1636
  serviceSuspended: false
1639
- }),
1640
- title: t("payment.checkout.stopAcceptingOrders.title"),
1641
- message: t("payment.checkout.stopAcceptingOrders.description"),
1642
- confirm: t("common.confirm")
1637
+ })
1643
1638
  }), FastCheckoutConfirmDialog, CreditInsufficientDialog, PriceUpdatedDialog, state.priceChangeConfirm?.open && /* @__PURE__ */(0, _jsxRuntime.jsx)(_priceChangeConfirm.default, {
1644
1639
  open: true,
1645
1640
  changePercent: state.priceChangeConfirm.changePercent,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blocklet/payment-react",
3
- "version": "1.26.3",
3
+ "version": "1.26.4",
4
4
  "description": "Reusable react components for payment kit v2",
5
5
  "keywords": [
6
6
  "react",
@@ -59,7 +59,7 @@
59
59
  "@arcblock/react-hooks": "^3.5.1",
60
60
  "@arcblock/ux": "^3.5.1",
61
61
  "@arcblock/ws": "^1.28.5",
62
- "@blocklet/payment-react-headless": "1.26.3",
62
+ "@blocklet/payment-react-headless": "1.26.4",
63
63
  "@blocklet/theme": "^3.5.1",
64
64
  "@blocklet/ui-react": "^3.5.1",
65
65
  "@mui/icons-material": "^7.1.2",
@@ -97,7 +97,7 @@
97
97
  "@babel/core": "^7.27.4",
98
98
  "@babel/preset-env": "^7.27.2",
99
99
  "@babel/preset-react": "^7.27.1",
100
- "@blocklet/payment-types": "1.26.3",
100
+ "@blocklet/payment-types": "1.26.4",
101
101
  "@storybook/addon-essentials": "^7.6.20",
102
102
  "@storybook/addon-interactions": "^7.6.20",
103
103
  "@storybook/addon-links": "^7.6.20",
@@ -128,5 +128,5 @@
128
128
  "vite-plugin-babel": "^1.3.1",
129
129
  "vite-plugin-node-polyfills": "^0.23.0"
130
130
  },
131
- "gitHead": "18c5d045139c572b52465e15c4c63b3e327efab5"
131
+ "gitHead": "90fb554f2edfcd1c141e3887eef835b1a545f5ad"
132
132
  }
@@ -10,12 +10,14 @@ export default function ServiceSuspendedDialog({ open, onClose }: { open: boolea
10
10
  <Dialog
11
11
  open={open}
12
12
  onClose={onClose}
13
- PaperProps={{
14
- sx: {
15
- borderRadius: 3,
16
- maxWidth: 400,
17
- mx: 'auto',
18
- overflow: 'hidden',
13
+ slotProps={{
14
+ paper: {
15
+ sx: {
16
+ borderRadius: 3,
17
+ maxWidth: 400,
18
+ mx: 'auto',
19
+ overflow: 'hidden',
20
+ },
19
21
  },
20
22
  }}>
21
23
  <DialogContent sx={{ p: 0 }}>
@@ -1759,15 +1759,7 @@ export default function PaymentForm({
1759
1759
  }}
1760
1760
  />
1761
1761
  )}
1762
- {state.serviceSuspended && (
1763
- <ConfirmDialog
1764
- onConfirm={() => setState({ serviceSuspended: false })}
1765
- onCancel={() => setState({ serviceSuspended: false })}
1766
- title={t('payment.checkout.stopAcceptingOrders.title')}
1767
- message={t('payment.checkout.stopAcceptingOrders.description')}
1768
- confirm={t('common.confirm')}
1769
- />
1770
- )}
1762
+ {state.serviceSuspended && <ServiceSuspendedDialog open onClose={() => setState({ serviceSuspended: false })} />}
1771
1763
  {FastCheckoutConfirmDialog}
1772
1764
  {CreditInsufficientDialog}
1773
1765
  {PriceUpdatedDialog}