@pisell/private-materials 6.4.73 → 6.4.75
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/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +1 -1
- package/build/lowcode/preview.js +4 -4
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +5 -5
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +5 -5
- package/es/components/appointmentBooking/components/Footer/index.d.ts +1 -0
- package/es/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +1 -0
- package/es/components/booking/addons/model.d.ts +10 -1
- package/es/components/booking/components/TabProduct/index.d.ts +1 -0
- package/es/components/booking/components/footer/index.js +62 -53
- package/es/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
- package/es/components/booking/forms/model.d.ts +10 -1
- package/es/components/booking/forms/table/index.d.ts +1 -0
- package/es/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
- package/es/components/booking/info/model.d.ts +10 -1
- package/es/components/booking/info/service/addService/utils.d.ts +1 -1
- package/es/components/booking/info/service/like/index.d.ts +1 -0
- package/es/components/booking/info/service2/utils.d.ts +1 -1
- package/es/components/booking/info2/service/addService/utils.d.ts +1 -1
- package/es/components/booking/materiels/holder/index.d.ts +1 -0
- package/es/components/booking/model.d.ts +9 -1
- package/es/components/booking/notes/model.d.ts +10 -1
- package/es/components/booking/payments/model.d.ts +10 -1
- package/es/components/booking/utils.d.ts +2 -2
- package/es/components/checkout/PaymentModal.js +178 -108
- package/es/components/checkout/components/AdditionalModule/index.d.ts +3 -1
- package/es/components/checkout/components/AdditionalModule/index.js +50 -12
- package/es/components/checkout/components/AmountSummary/index.js +9 -76
- package/es/components/checkout/components/AmountSummary/index.less +1 -1
- package/es/components/checkout/components/CashPaymentModule/index.d.ts +3 -1
- package/es/components/checkout/components/CashPaymentModule/index.js +5 -2
- package/es/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.d.ts +2 -0
- package/es/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.js +6 -1
- package/es/components/checkout/components/PaymentOptionsModule/index.d.ts +1 -0
- package/es/components/checkout/components/PaymentOptionsModule/index.js +2 -1
- package/es/components/checkout/components/PaymentOptionsModule/index.less +4 -0
- package/es/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.d.ts +4 -0
- package/es/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.js +31 -8
- package/es/components/checkout/components/PaymentResultToast/index.js +6 -6
- package/es/components/checkout/components/PaymentResultToast/index.less +94 -33
- package/es/components/checkout/hooks/useWalletPass.d.ts +1 -1
- package/es/components/checkout/index.less +1 -1
- package/es/components/checkout/locales.d.ts +3 -0
- package/es/components/checkout/locales.js +3 -0
- package/es/components/checkout/utils/PaymentResultToastUtils.js +11 -1
- package/es/components/eftpos/deviceList/index.d.ts +1 -0
- package/es/components/eftpos/form/index.d.ts +1 -0
- package/es/components/eftpos/group/index.d.ts +1 -0
- package/es/components/eftpos/hooks.d.ts +1 -0
- package/es/components/eftpos/icon/apiKey.d.ts +1 -0
- package/es/components/eftpos/icon/device.d.ts +1 -0
- package/es/components/eftpos/receipt/index.d.ts +1 -0
- package/es/components/eftposPay/amount.d.ts +1 -1
- package/es/components/eftposPay/component/alert/warn.d.ts +1 -0
- package/es/components/eftposPay/component/header/titlebar.d.ts +1 -0
- package/es/components/eftposPay/component/step/index.d.ts +1 -0
- package/es/components/eftposPay/component/step/step.d.ts +1 -0
- package/es/components/eftposPay/device.d.ts +1 -1
- package/es/components/eftposPay/hooks.d.ts +2 -2
- package/es/components/eftposPay/store/index.d.ts +4 -4
- package/es/components/eftposPay/tyro/hooks.d.ts +1 -0
- package/es/components/eventBooking/components/ErrorTip/index.d.ts +1 -0
- package/es/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +1 -0
- package/es/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +1 -0
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/index.d.ts +1 -0
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +1 -0
- package/es/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +1 -0
- package/es/components/pay/toC/model.d.ts +9 -1
- package/es/components/productExtension/fields/Actor/index.d.ts +1 -0
- package/es/components/productExtension/fields/Forms/index.d.ts +1 -0
- package/es/components/schedules/calendar/calendarItem.d.ts +1 -0
- package/es/components/schedules/components/CurrentDay/index.d.ts +1 -0
- package/es/components/schedules/model.d.ts +9 -1
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
- package/es/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +1 -0
- package/es/components/schedules/products/index.d.ts +1 -0
- package/es/components/schedules/resources/relationProduct/index.d.ts +1 -0
- package/es/components/shoppingCart/components/Empty/index.d.ts +1 -0
- package/es/components/shoppingCart/components/Render/index.d.ts +1 -0
- package/es/components/ticketBooking/components/timeBar/index.js +112 -7
- package/es/components/ticketBooking/components/timeBar/index.less +59 -0
- package/es/components/ticketBooking/locales.d.ts +6 -0
- package/es/components/ticketBooking/locales.js +9 -3
- package/es/components/ticketBooking/utils/index.d.ts +1 -1
- package/es/components/wallet/Detail/model.d.ts +13 -1
- package/es/components/wallet/DiscountCard/model.d.ts +14 -1
- package/es/components/wallet/PointCard/model.d.ts +13 -1
- package/es/components/wallet/RechargeableCard/model.d.ts +29 -1
- package/es/components/wallet/Voucher/model.d.ts +13 -1
- package/es/components/wallet/model.d.ts +9 -1
- package/es/components/workSpaceList/components/Modal/index.d.ts +1 -0
- package/es/plus/clientName/index.d.ts +1 -0
- package/es/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Duration/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Resource/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Stock/index.d.ts +1 -1
- package/es/plus/productSelect/ProductCard/SkuCard/components/Time/index.d.ts +1 -1
- package/es/pro/pisellPaymentList/example.d.ts +1 -0
- package/es/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.js +11 -7
- package/es/pro/priceKeyboard/components/cashKeyboard/index.d.ts +1 -0
- package/es/pro/priceKeyboard/components/cashKeyboard/index.js +4 -2
- package/es/pro/priceKeyboard/components/cashKeyboard/types.d.ts +1 -0
- package/es/pro/priceKeyboard/components/discountKeyboard/index.js +10 -1
- package/es/pro/priceKeyboard/components/discountKeyboard/index.less +14 -0
- package/es/pro/priceKeyboard/components/shortcuts/index.d.ts +1 -0
- package/es/pro/priceKeyboard/components/shortcuts/index.js +5 -2
- package/es/pro/priceKeyboard/components/shortcuts/index.less +4 -0
- package/lib/components/appointmentBooking/components/Footer/index.d.ts +1 -0
- package/lib/components/appointmentBooking/components/Guest/components/InformationOptionsModal/index.d.ts +1 -0
- package/lib/components/booking/addons/model.d.ts +10 -1
- package/lib/components/booking/components/TabProduct/index.d.ts +1 -0
- package/lib/components/booking/components/footer/index.js +15 -8
- package/lib/components/booking/components/formItemChildrenWrap/index.d.ts +1 -0
- package/lib/components/booking/forms/model.d.ts +10 -1
- package/lib/components/booking/forms/table/index.d.ts +1 -0
- package/lib/components/booking/info/clientVariant/hooks/useIsLowSpeedNetwork.d.ts +1 -0
- package/lib/components/booking/info/model.d.ts +10 -1
- package/lib/components/booking/info/service/addService/utils.d.ts +1 -1
- package/lib/components/booking/info/service/like/index.d.ts +1 -0
- package/lib/components/booking/info/service2/utils.d.ts +1 -1
- package/lib/components/booking/info2/service/addService/utils.d.ts +1 -1
- package/lib/components/booking/materiels/holder/index.d.ts +1 -0
- package/lib/components/booking/model.d.ts +9 -1
- package/lib/components/booking/notes/model.d.ts +10 -1
- package/lib/components/booking/payments/model.d.ts +10 -1
- package/lib/components/booking/utils.d.ts +2 -2
- package/lib/components/checkout/PaymentModal.js +73 -11
- package/lib/components/checkout/components/AdditionalModule/index.d.ts +3 -1
- package/lib/components/checkout/components/AdditionalModule/index.js +50 -11
- package/lib/components/checkout/components/AmountSummary/index.js +5 -46
- package/lib/components/checkout/components/AmountSummary/index.less +1 -1
- package/lib/components/checkout/components/CashPaymentModule/index.d.ts +3 -1
- package/lib/components/checkout/components/CashPaymentModule/index.js +5 -2
- package/lib/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.d.ts +2 -0
- package/lib/components/checkout/components/PaymentOptionsModule/PaymentMethodItem.js +5 -1
- package/lib/components/checkout/components/PaymentOptionsModule/index.d.ts +1 -0
- package/lib/components/checkout/components/PaymentOptionsModule/index.js +6 -0
- package/lib/components/checkout/components/PaymentOptionsModule/index.less +4 -0
- package/lib/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.d.ts +4 -0
- package/lib/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.js +23 -5
- package/lib/components/checkout/components/PaymentResultToast/index.js +4 -4
- package/lib/components/checkout/components/PaymentResultToast/index.less +94 -33
- package/lib/components/checkout/hooks/useWalletPass.d.ts +1 -1
- package/lib/components/checkout/index.less +1 -1
- package/lib/components/checkout/locales.d.ts +3 -0
- package/lib/components/checkout/locales.js +3 -0
- package/lib/components/checkout/utils/PaymentResultToastUtils.js +11 -1
- package/lib/components/eftpos/deviceList/index.d.ts +1 -0
- package/lib/components/eftpos/form/index.d.ts +1 -0
- package/lib/components/eftpos/group/index.d.ts +1 -0
- package/lib/components/eftpos/hooks.d.ts +1 -0
- package/lib/components/eftpos/icon/apiKey.d.ts +1 -0
- package/lib/components/eftpos/icon/device.d.ts +1 -0
- package/lib/components/eftpos/receipt/index.d.ts +1 -0
- package/lib/components/eftposPay/amount.d.ts +1 -1
- package/lib/components/eftposPay/component/alert/warn.d.ts +1 -0
- package/lib/components/eftposPay/component/header/titlebar.d.ts +1 -0
- package/lib/components/eftposPay/component/step/index.d.ts +1 -0
- package/lib/components/eftposPay/component/step/step.d.ts +1 -0
- package/lib/components/eftposPay/device.d.ts +1 -1
- package/lib/components/eftposPay/hooks.d.ts +2 -2
- package/lib/components/eftposPay/store/index.d.ts +4 -4
- package/lib/components/eftposPay/tyro/hooks.d.ts +1 -0
- package/lib/components/eventBooking/components/ErrorTip/index.d.ts +1 -0
- package/lib/components/eventBooking/components/Provider/Cart/Deposit/index.d.ts +1 -0
- package/lib/components/eventBooking/components/Provider/InformationOptionsModal/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateStatus/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/DayItem/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Item/index.d.ts +1 -0
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/Status/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/StripeSDK/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/SetupForm/index.d.ts +1 -0
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/index.d.ts +1 -0
- package/lib/components/pay/toC/WalletPassBlock/components/WalletUseList/index.d.ts +1 -0
- package/lib/components/pay/toC/model.d.ts +9 -1
- package/lib/components/productExtension/fields/Actor/index.d.ts +1 -0
- package/lib/components/productExtension/fields/Forms/index.d.ts +1 -0
- package/lib/components/schedules/calendar/calendarItem.d.ts +1 -0
- package/lib/components/schedules/components/CurrentDay/index.d.ts +1 -0
- package/lib/components/schedules/model.d.ts +9 -1
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetail/index.d.ts +1 -0
- package/lib/components/schedules/products/ProductDetailDrawer/ProductDetailByDate/index.d.ts +1 -0
- package/lib/components/schedules/products/index.d.ts +1 -0
- package/lib/components/schedules/resources/relationProduct/index.d.ts +1 -0
- package/lib/components/shoppingCart/components/Empty/index.d.ts +1 -0
- package/lib/components/shoppingCart/components/Render/index.d.ts +1 -0
- package/lib/components/ticketBooking/components/timeBar/index.js +105 -4
- package/lib/components/ticketBooking/components/timeBar/index.less +59 -0
- package/lib/components/ticketBooking/locales.d.ts +6 -0
- package/lib/components/ticketBooking/locales.js +9 -3
- package/lib/components/ticketBooking/utils/index.d.ts +1 -1
- package/lib/components/wallet/Detail/model.d.ts +13 -1
- package/lib/components/wallet/DiscountCard/model.d.ts +14 -1
- package/lib/components/wallet/PointCard/model.d.ts +13 -1
- package/lib/components/wallet/RechargeableCard/model.d.ts +29 -1
- package/lib/components/wallet/Voucher/model.d.ts +13 -1
- package/lib/components/wallet/model.d.ts +9 -1
- package/lib/components/workSpaceList/components/Modal/index.d.ts +1 -0
- package/lib/plus/clientName/index.d.ts +1 -0
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Capacity/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/CardMask/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Countdown/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Duration/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/MemberPrice/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Resource/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Stock/index.d.ts +1 -1
- package/lib/plus/productSelect/ProductCard/SkuCard/components/Time/index.d.ts +1 -1
- package/lib/pro/pisellPaymentList/example.d.ts +1 -0
- package/lib/pro/priceKeyboard/components/cashKeyboard/CashKeyboardIntact.js +9 -5
- package/lib/pro/priceKeyboard/components/cashKeyboard/index.d.ts +1 -0
- package/lib/pro/priceKeyboard/components/cashKeyboard/index.js +3 -2
- package/lib/pro/priceKeyboard/components/cashKeyboard/types.d.ts +1 -0
- package/lib/pro/priceKeyboard/components/discountKeyboard/index.js +8 -1
- package/lib/pro/priceKeyboard/components/discountKeyboard/index.less +14 -0
- package/lib/pro/priceKeyboard/components/shortcuts/index.d.ts +1 -0
- package/lib/pro/priceKeyboard/components/shortcuts/index.js +3 -2
- package/lib/pro/priceKeyboard/components/shortcuts/index.less +4 -0
- package/package.json +1 -1
|
@@ -18,7 +18,11 @@ function AdditionalModule(_ref) {
|
|
|
18
18
|
_ref$disabled = _ref.disabled,
|
|
19
19
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
20
20
|
_ref$showCashPayment = _ref.showCashPayment,
|
|
21
|
-
showCashPayment = _ref$showCashPayment === void 0 ? false : _ref$showCashPayment
|
|
21
|
+
showCashPayment = _ref$showCashPayment === void 0 ? false : _ref$showCashPayment,
|
|
22
|
+
_ref$isFullWidth = _ref.isFullWidth,
|
|
23
|
+
isFullWidth = _ref$isFullWidth === void 0 ? false : _ref$isFullWidth,
|
|
24
|
+
_ref$showMore = _ref.showMore,
|
|
25
|
+
showMore = _ref$showMore === void 0 ? true : _ref$showMore;
|
|
22
26
|
// 初始化国际化
|
|
23
27
|
locales.init(localeTexts, getLocale());
|
|
24
28
|
|
|
@@ -27,6 +31,12 @@ function AdditionalModule(_ref) {
|
|
|
27
31
|
key: 'send-link',
|
|
28
32
|
label: locales.getText('pisell2.text.send-link'),
|
|
29
33
|
icon: /*#__PURE__*/React.createElement(LinkOutlined, null)
|
|
34
|
+
}, {
|
|
35
|
+
key: 'print-receipt',
|
|
36
|
+
label: locales.getText('pisell2.text.print-receipt'),
|
|
37
|
+
icon: /*#__PURE__*/React.createElement(Icon, {
|
|
38
|
+
type: "pisell2-printer"
|
|
39
|
+
})
|
|
30
40
|
}];
|
|
31
41
|
var Toast = useToast();
|
|
32
42
|
return /*#__PURE__*/React.createElement("div", {
|
|
@@ -35,9 +45,9 @@ function AdditionalModule(_ref) {
|
|
|
35
45
|
className: "additional-module-title"
|
|
36
46
|
}, locales.getText('pisell2.text.others')), /*#__PURE__*/React.createElement("div", {
|
|
37
47
|
className: "additional-module-buttons-container"
|
|
38
|
-
}, showCashPayment ?
|
|
48
|
+
}, showCashPayment && !isFullWidth ?
|
|
39
49
|
/*#__PURE__*/
|
|
40
|
-
// Grid
|
|
50
|
+
// Grid布局模式:两行布局(显示现金支付模块且非全宽时)
|
|
41
51
|
React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
|
|
42
52
|
className: "additional-module-button-row"
|
|
43
53
|
}, /*#__PURE__*/React.createElement(Button, {
|
|
@@ -57,14 +67,14 @@ function AdditionalModule(_ref) {
|
|
|
57
67
|
}))), /*#__PURE__*/React.createElement(Button, {
|
|
58
68
|
className: "additional-module-button-base purple-theme",
|
|
59
69
|
onClick: function onClick() {
|
|
60
|
-
handleButtonClick('
|
|
70
|
+
handleButtonClick('split-payment');
|
|
61
71
|
},
|
|
62
72
|
icon: /*#__PURE__*/React.createElement(Icon, {
|
|
63
|
-
type: "pisell2-
|
|
73
|
+
type: "pisell2-coins-01",
|
|
64
74
|
className: "additional-module-button-icon"
|
|
65
75
|
}),
|
|
66
76
|
size: "large"
|
|
67
|
-
}, locales.getText('
|
|
77
|
+
}, locales.getText('split.payment'))), /*#__PURE__*/React.createElement("div", {
|
|
68
78
|
className: "additional-module-button-row"
|
|
69
79
|
}, /*#__PURE__*/React.createElement(Button, {
|
|
70
80
|
className: "additional-module-button-base purple-theme",
|
|
@@ -86,7 +96,7 @@ function AdditionalModule(_ref) {
|
|
|
86
96
|
icon: /*#__PURE__*/React.createElement(ClockCircleOutlined, {
|
|
87
97
|
className: "additional-module-button-icon"
|
|
88
98
|
})
|
|
89
|
-
}, locales.getText('pisell2.text.save-pay-later')), /*#__PURE__*/React.createElement(Dropdown, {
|
|
99
|
+
}, locales.getText('pisell2.text.save-pay-later')), showMore && /*#__PURE__*/React.createElement(Dropdown, {
|
|
90
100
|
menu: {
|
|
91
101
|
items: moreMenuItems,
|
|
92
102
|
onClick: function onClick(_ref2) {
|
|
@@ -98,6 +108,10 @@ function AdditionalModule(_ref) {
|
|
|
98
108
|
} else {
|
|
99
109
|
Toast.fail(locales.getText('pisell2.text.order-no-payment-cannot-send-link'));
|
|
100
110
|
}
|
|
111
|
+
} else if (key === 'split-payment') {
|
|
112
|
+
handleButtonClick('split-payment');
|
|
113
|
+
} else if (key === 'print-receipt') {
|
|
114
|
+
handleButtonClick('print-receipt');
|
|
101
115
|
}
|
|
102
116
|
}
|
|
103
117
|
},
|
|
@@ -118,9 +132,29 @@ function AdditionalModule(_ref) {
|
|
|
118
132
|
type: "pisell2-dots-vertical",
|
|
119
133
|
size: 20
|
|
120
134
|
})
|
|
121
|
-
})))
|
|
135
|
+
}))), !showMore && /*#__PURE__*/React.createElement("div", {
|
|
136
|
+
className: "additional-module-button-row"
|
|
137
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
138
|
+
className: "additional-module-button-base purple-theme",
|
|
139
|
+
onClick: function onClick() {
|
|
140
|
+
handleButtonClick('send-link');
|
|
141
|
+
},
|
|
142
|
+
disabled: disabled,
|
|
143
|
+
size: "large",
|
|
144
|
+
icon: /*#__PURE__*/React.createElement(LinkOutlined, null)
|
|
145
|
+
}, locales.getText('pisell2.text.send-link')), /*#__PURE__*/React.createElement(Button, {
|
|
146
|
+
className: "additional-module-button-base purple-theme",
|
|
147
|
+
onClick: function onClick() {
|
|
148
|
+
handleButtonClick('print-receipt');
|
|
149
|
+
},
|
|
150
|
+
disabled: disabled,
|
|
151
|
+
size: "large",
|
|
152
|
+
icon: /*#__PURE__*/React.createElement(Icon, {
|
|
153
|
+
type: "pisell2-printer"
|
|
154
|
+
})
|
|
155
|
+
}, locales.getText('pisell2.text.print-receipt')))) :
|
|
122
156
|
/*#__PURE__*/
|
|
123
|
-
// Flex
|
|
157
|
+
// Flex布局模式:一行布局(不显示现金支付模块或强制全宽时)
|
|
124
158
|
React.createElement("div", {
|
|
125
159
|
className: "additional-module-button-row"
|
|
126
160
|
}, /*#__PURE__*/React.createElement(Button, {
|
|
@@ -140,14 +174,14 @@ function AdditionalModule(_ref) {
|
|
|
140
174
|
}))), /*#__PURE__*/React.createElement(Button, {
|
|
141
175
|
className: "additional-module-button-base purple-theme",
|
|
142
176
|
onClick: function onClick() {
|
|
143
|
-
handleButtonClick('
|
|
177
|
+
handleButtonClick('split-payment');
|
|
144
178
|
},
|
|
145
179
|
size: "large",
|
|
146
180
|
icon: /*#__PURE__*/React.createElement(Icon, {
|
|
147
|
-
type: "pisell2-
|
|
181
|
+
type: "pisell2-coins-01",
|
|
148
182
|
className: "additional-module-button-icon"
|
|
149
183
|
})
|
|
150
|
-
}, locales.getText('
|
|
184
|
+
}, locales.getText('split.payment')), /*#__PURE__*/React.createElement(Button, {
|
|
151
185
|
className: "additional-module-button-base purple-theme",
|
|
152
186
|
onClick: function onClick() {
|
|
153
187
|
handleButtonClick('manual-discount');
|
|
@@ -179,6 +213,10 @@ function AdditionalModule(_ref) {
|
|
|
179
213
|
} else {
|
|
180
214
|
Toast.fail(locales.getText('pisell2.text.order-no-payment-cannot-send-link'));
|
|
181
215
|
}
|
|
216
|
+
} else if (key === 'split-payment') {
|
|
217
|
+
handleButtonClick('split-payment');
|
|
218
|
+
} else if (key === 'print-receipt') {
|
|
219
|
+
handleButtonClick('print-receipt');
|
|
182
220
|
}
|
|
183
221
|
}
|
|
184
222
|
},
|
|
@@ -9,7 +9,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
9
9
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
10
10
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
11
11
|
import { useState, useEffect, useMemo } from 'react';
|
|
12
|
-
import { Button, Dropdown
|
|
12
|
+
import { Button, Dropdown } from 'antd';
|
|
13
13
|
import { CheckCircleOutlined, PieChartOutlined } from '@ant-design/icons';
|
|
14
14
|
import { Edit05 } from '@pisell/icon';
|
|
15
15
|
import { PisellModal } from '@pisell/materials';
|
|
@@ -18,7 +18,8 @@ import Decimal from 'decimal.js';
|
|
|
18
18
|
import checkoutLocales from "../../locales";
|
|
19
19
|
import PaymentDetailModal from "../PaymentDetailModal";
|
|
20
20
|
import PisellPriceKeyboardPopover from "../../../../pro/pisellSimplePriceKeyboardPopover";
|
|
21
|
-
import { PaymentKeyboard } from
|
|
21
|
+
// import { PaymentKeyboard } from '../../../../pro/priceKeyboard';
|
|
22
|
+
|
|
22
23
|
import "./index.less";
|
|
23
24
|
import classNames from 'classnames';
|
|
24
25
|
import useEngineContext from "../../../../hooks/useEngineContext";
|
|
@@ -503,12 +504,12 @@ function AmountSummary(_ref2) {
|
|
|
503
504
|
var syncedVoucherAmount = paymentItems === null || paymentItems === void 0 ? void 0 : paymentItems.reduce(function (acc, item) {
|
|
504
505
|
// 如果当前是普通支付,则减去order_payment_type不为 deposit的支付项
|
|
505
506
|
// 如果当前是定金支付,则减去order_payment_type为 deposit的支付项
|
|
506
|
-
if (item.isSynced && (paymentType === 'regular' && item.order_payment_type !== 'deposit' || paymentType === 'deposit' && item.order_payment_type === 'deposit')) {
|
|
507
|
+
if ((item.isSynced || item.voucher_id) && (paymentType === 'regular' && item.order_payment_type !== 'deposit' || paymentType === 'deposit' && item.order_payment_type === 'deposit')) {
|
|
507
508
|
return acc.plus(item.amount).plus(Number(item.rounding_amount) > 0 ? 0 : item.rounding_amount || 0);
|
|
508
509
|
}
|
|
509
510
|
return acc;
|
|
510
511
|
}, new Decimal(0)).toNumber();
|
|
511
|
-
balanceDecimal = balanceDecimal.minus(syncedVoucherAmount);
|
|
512
|
+
balanceDecimal = new Decimal(Math.abs(balanceDecimal.minus(new Decimal(syncedVoucherAmount)).toNumber()));
|
|
512
513
|
// if (walletPassData?.selectedDiscountList && walletPassData.selectedDiscountList.length > 0) {
|
|
513
514
|
// walletPassData?.availableDiscountList?.forEach((discountItem: any) => {
|
|
514
515
|
// discountItem.appliedProductDetails?.forEach((productDetail: any) => {
|
|
@@ -639,8 +640,9 @@ function AmountSummary(_ref2) {
|
|
|
639
640
|
return balanceDueAmount !== customAmount && Number(balanceDueAmount) > 0 && Number(customAmount) > 0;
|
|
640
641
|
}, [customAmount, balanceDueAmount]);
|
|
641
642
|
var handleChangeDepositAmount = function handleChangeDepositAmount(value) {
|
|
642
|
-
|
|
643
|
-
|
|
643
|
+
var valueStr = String(value);
|
|
644
|
+
console.log('handleChangeDepositAmount', valueStr);
|
|
645
|
+
checkoutModule === null || checkoutModule === void 0 || checkoutModule.setDepositAmountAsync(valueStr);
|
|
644
646
|
};
|
|
645
647
|
var hasDepositPayment = useMemo(function () {
|
|
646
648
|
return paymentItems === null || paymentItems === void 0 ? void 0 : paymentItems.some(function (item) {
|
|
@@ -778,76 +780,7 @@ function AmountSummary(_ref2) {
|
|
|
778
780
|
hideDecimalForWholeNumbers: false,
|
|
779
781
|
useThousandsSeparator: true,
|
|
780
782
|
showCurrencySymbol: true
|
|
781
|
-
})))),
|
|
782
|
-
className: classNames('cancel-split-payment-button'),
|
|
783
|
-
onClick: function onClick() {
|
|
784
|
-
return onAmountChange === null || onAmountChange === void 0 ? void 0 : onAmountChange(balanceDueAmount);
|
|
785
|
-
}
|
|
786
|
-
}, getText('split.cancel') || '取消部\n分支付') : /*#__PURE__*/React.createElement(Popover, {
|
|
787
|
-
content: /*#__PURE__*/React.createElement("div", {
|
|
788
|
-
onClick: function onClick(e) {
|
|
789
|
-
return e.stopPropagation();
|
|
790
|
-
}
|
|
791
|
-
}, /*#__PURE__*/React.createElement(PaymentKeyboard
|
|
792
|
-
// 原始值:此支付阶段的待支付金额,reset时还原为此值
|
|
793
|
-
, {
|
|
794
|
-
paymentOriginalValue: balanceDueAmount,
|
|
795
|
-
paymentDefaultValue: String(customAmount || 0),
|
|
796
|
-
enableExceedMaxAmount: false,
|
|
797
|
-
payment: {
|
|
798
|
-
enable: true
|
|
799
|
-
},
|
|
800
|
-
surcharge: {
|
|
801
|
-
enable: false
|
|
802
|
-
},
|
|
803
|
-
surchargeDefaultValue: {
|
|
804
|
-
percent: '0',
|
|
805
|
-
fixed: '0'
|
|
806
|
-
},
|
|
807
|
-
selectType: "light",
|
|
808
|
-
onChange: function onChange(value) {
|
|
809
|
-
console.log(value);
|
|
810
|
-
},
|
|
811
|
-
doneText: getText('confirm'),
|
|
812
|
-
onPay: function onPay(args) {
|
|
813
|
-
console.log(args);
|
|
814
|
-
// 处理支付逻辑
|
|
815
|
-
setIsKeyboardVisible(false);
|
|
816
|
-
handleKeyboardConfirm(args.amount);
|
|
817
|
-
}
|
|
818
|
-
})),
|
|
819
|
-
trigger: "click",
|
|
820
|
-
open: isKeyboardVisible,
|
|
821
|
-
onOpenChange: setIsKeyboardVisible,
|
|
822
|
-
placement: "bottom",
|
|
823
|
-
overlayClassName: "payment-keyboard-popover",
|
|
824
|
-
arrow: true,
|
|
825
|
-
destroyTooltipOnHide: true
|
|
826
|
-
}, /*#__PURE__*/React.createElement(Button, {
|
|
827
|
-
className: classNames('split-payment-button')
|
|
828
|
-
}, getText('split.payment') || '拆分支付')))
|
|
829
|
-
// <PisellPriceKeyboardPopover
|
|
830
|
-
// value={(() => {
|
|
831
|
-
// try {
|
|
832
|
-
// return new Decimal(currentAmount || '0').toNumber();
|
|
833
|
-
// } catch {
|
|
834
|
-
// return 0;
|
|
835
|
-
// }
|
|
836
|
-
// })()}
|
|
837
|
-
// // onChange={handleKeyboardConfirm}
|
|
838
|
-
// onConfirm={handleKeyboardConfirm}
|
|
839
|
-
// // onCancel={handleKeyboardCancel}
|
|
840
|
-
// showCurrencySymbol={true}
|
|
841
|
-
// useThousandsSeparator={false}
|
|
842
|
-
// selectType="dark"
|
|
843
|
-
// overlayClassName="amount-summary-keyboard-popover"
|
|
844
|
-
// >
|
|
845
|
-
// {/* 右侧: 拆分支付按钮 */}
|
|
846
|
-
// <Button className={classNames('split-payment-button')}>
|
|
847
|
-
// {getText('split.payment') || '拆分支付'}
|
|
848
|
-
// </Button>
|
|
849
|
-
// </PisellPriceKeyboardPopover>
|
|
850
|
-
, /*#__PURE__*/React.createElement(PisellModal, {
|
|
783
|
+
})))), /*#__PURE__*/React.createElement(PisellModal, {
|
|
851
784
|
open: isPaymentDetailOpen,
|
|
852
785
|
onCancel: handlePaymentDetailClose,
|
|
853
786
|
footer: null,
|
|
@@ -15,10 +15,12 @@ export interface CashPaymentModuleProps {
|
|
|
15
15
|
balanceDueAmount?: string;
|
|
16
16
|
balanceDueTotalAmount?: string;
|
|
17
17
|
syncingLock?: boolean;
|
|
18
|
+
shortcutsSize?: 'default' | 'large';
|
|
18
19
|
}
|
|
19
20
|
export declare function CashPaymentModule({ amountSymbol, orderInfo, onPaymentComplete, customAmount, amountButtons, // 按钮列表,默认5个推荐金额
|
|
20
21
|
disabled, // 禁用状态
|
|
21
22
|
roundingFunction, balanceDueAmount, // 当前阶段剩余支付金额(定金或普通支付)
|
|
22
23
|
balanceDueTotalAmount, // 完整订单剩余待付金额
|
|
23
|
-
syncingLock,
|
|
24
|
+
syncingLock, // 是否锁定
|
|
25
|
+
shortcutsSize, }: CashPaymentModuleProps): JSX.Element;
|
|
24
26
|
export default CashPaymentModule;
|
|
@@ -32,7 +32,9 @@ export function CashPaymentModule(_ref) {
|
|
|
32
32
|
_ref$balanceDueTotalA = _ref.balanceDueTotalAmount,
|
|
33
33
|
balanceDueTotalAmount = _ref$balanceDueTotalA === void 0 ? '0' : _ref$balanceDueTotalA,
|
|
34
34
|
_ref$syncingLock = _ref.syncingLock,
|
|
35
|
-
syncingLock = _ref$syncingLock === void 0 ? false : _ref$syncingLock
|
|
35
|
+
syncingLock = _ref$syncingLock === void 0 ? false : _ref$syncingLock,
|
|
36
|
+
_ref$shortcutsSize = _ref.shortcutsSize,
|
|
37
|
+
shortcutsSize = _ref$shortcutsSize === void 0 ? 'default' : _ref$shortcutsSize;
|
|
36
38
|
var _useState = useState(customAmount || ''),
|
|
37
39
|
_useState2 = _slicedToArray(_useState, 2),
|
|
38
40
|
amount = _useState2[0],
|
|
@@ -252,7 +254,8 @@ export function CashPaymentModule(_ref) {
|
|
|
252
254
|
};
|
|
253
255
|
}),
|
|
254
256
|
onReset: handleReset,
|
|
255
|
-
onEnter: syncingLock ? undefined : handleCashPay
|
|
257
|
+
onEnter: syncingLock ? undefined : handleCashPay,
|
|
258
|
+
shortcutsSize: shortcutsSize
|
|
256
259
|
});
|
|
257
260
|
}
|
|
258
261
|
export default CashPaymentModule;
|
|
@@ -24,6 +24,8 @@ export interface PaymentMethodItemProps {
|
|
|
24
24
|
onClick?: (method: ExtendedPaymentMethod) => void;
|
|
25
25
|
/** 获取文本的函数 */
|
|
26
26
|
getText?: (key: string, fallback?: string) => string;
|
|
27
|
+
/** 大小 */
|
|
28
|
+
size?: 'default' | 'large';
|
|
27
29
|
}
|
|
28
30
|
declare const PaymentMethodItem: React.FC<PaymentMethodItemProps>;
|
|
29
31
|
export default PaymentMethodItem;
|
|
@@ -27,7 +27,9 @@ var PaymentMethodItem = function PaymentMethodItem(_ref) {
|
|
|
27
27
|
_ref$disabled = _ref.disabled,
|
|
28
28
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
29
29
|
onClick = _ref.onClick,
|
|
30
|
-
getText = _ref.getText
|
|
30
|
+
getText = _ref.getText,
|
|
31
|
+
_ref$size = _ref.size,
|
|
32
|
+
size = _ref$size === void 0 ? 'default' : _ref$size;
|
|
31
33
|
// 控制键盘弹窗显示状态
|
|
32
34
|
var _useState = useState(false),
|
|
33
35
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -151,6 +153,9 @@ var PaymentMethodItem = function PaymentMethodItem(_ref) {
|
|
|
151
153
|
'payment-options-module-pointer': !disabled,
|
|
152
154
|
'payment-options-module-disabled': disabled
|
|
153
155
|
}),
|
|
156
|
+
style: {
|
|
157
|
+
height: size === 'large' ? '82px' : '62px'
|
|
158
|
+
},
|
|
154
159
|
onClick: showKeyboard,
|
|
155
160
|
type: "button",
|
|
156
161
|
disabled: disabled
|
|
@@ -11,5 +11,6 @@ interface ExtendedPaymentOptionsModuleProps extends PaymentOptionsModuleProps {
|
|
|
11
11
|
disabled?: boolean;
|
|
12
12
|
showCashPayment?: boolean;
|
|
13
13
|
}
|
|
14
|
+
export declare const SHOW_METHODS_CODE: string[];
|
|
14
15
|
declare function PaymentOptionsModule({ amountSymbol, orderInfo, onClick, paymentMethods, customAmount, title, disabled, showCashPayment, }: ExtendedPaymentOptionsModuleProps): JSX.Element;
|
|
15
16
|
export default PaymentOptionsModule;
|
|
@@ -10,7 +10,7 @@ import checkoutLocales from "../../locales";
|
|
|
10
10
|
|
|
11
11
|
// 扩展 PaymentOptionsModule Props 接口
|
|
12
12
|
|
|
13
|
-
var SHOW_METHODS_CODE = ['EFTPOS_LINKLY', 'EFTPOS', 'EFTPOS_TYRO', 'EFTPOS_WINDCAVE', 'EFTPOS_PAYO'];
|
|
13
|
+
export var SHOW_METHODS_CODE = ['EFTPOS_LINKLY', 'EFTPOS', 'EFTPOS_TYRO', 'EFTPOS_WINDCAVE', 'EFTPOS_PAYO'];
|
|
14
14
|
function PaymentOptionsModule(_ref) {
|
|
15
15
|
var _context$appHelper, _context$appHelper$ge, _context$appHelper$ge2, _context$appHelper$ut;
|
|
16
16
|
var amountSymbol = _ref.amountSymbol,
|
|
@@ -92,6 +92,7 @@ function PaymentOptionsModule(_ref) {
|
|
|
92
92
|
}
|
|
93
93
|
}, filteredPaymentMethods.map(function (method) {
|
|
94
94
|
return /*#__PURE__*/React.createElement(PaymentMethodItem, {
|
|
95
|
+
size: (filteredPaymentMethods === null || filteredPaymentMethods === void 0 ? void 0 : filteredPaymentMethods.length) === 2 ? 'large' : 'default',
|
|
95
96
|
key: method.id,
|
|
96
97
|
method: method,
|
|
97
98
|
amountSymbol: amountSymbol,
|
package/es/components/checkout/components/PaymentResultToast/PaymentResultToastProvider.d.ts
CHANGED
|
@@ -23,6 +23,10 @@ interface ShowPaymentResultToastConfig {
|
|
|
23
23
|
onClose?: () => void;
|
|
24
24
|
/** 是否显示右上角关闭按钮 */
|
|
25
25
|
closable?: boolean;
|
|
26
|
+
/** 是否启用点击外部区域关闭弹窗(使用纯JS实现) */
|
|
27
|
+
clickOutsideToClose?: boolean;
|
|
28
|
+
/** 是否显示遮罩 */
|
|
29
|
+
mask?: boolean;
|
|
26
30
|
}
|
|
27
31
|
interface PaymentResultToastContextType {
|
|
28
32
|
/** 显示成功弹窗 */
|
|
@@ -263,6 +263,13 @@ var GlobalToastManager = /*#__PURE__*/function () {
|
|
|
263
263
|
|
|
264
264
|
// 更新容器样式,带有平滑动画效果
|
|
265
265
|
if (instance.container) {
|
|
266
|
+
// 如果开启了遮罩,使用居中定位,不更新位置
|
|
267
|
+
var hasMask = instance.container.getAttribute('data-mask') === 'true';
|
|
268
|
+
if (hasMask) {
|
|
269
|
+
// mask 模式下保持居中,不更新位置
|
|
270
|
+
return;
|
|
271
|
+
}
|
|
272
|
+
|
|
266
273
|
// 添加动画类名表示正在移动
|
|
267
274
|
instance.container.classList.add('toast-moving');
|
|
268
275
|
instance.container.style.position = 'fixed';
|
|
@@ -312,30 +319,46 @@ var GlobalToastManager = /*#__PURE__*/function () {
|
|
|
312
319
|
autoClose: config.autoClose,
|
|
313
320
|
autoCloseDelay: config.autoCloseDelay || 30,
|
|
314
321
|
showCountdownProgress: config.showCountdownProgress,
|
|
322
|
+
clickOutsideToClose: config.clickOutsideToClose,
|
|
315
323
|
onCountdownComplete: config.onCountdownComplete,
|
|
316
324
|
onClose: function onClose() {
|
|
317
325
|
var _config$onClose2;
|
|
318
326
|
(_config$onClose2 = config.onClose) === null || _config$onClose2 === void 0 || _config$onClose2.call(config);
|
|
319
327
|
_this2.removeToast(id);
|
|
320
328
|
},
|
|
321
|
-
closable: config.closable !== undefined ? config.closable : DEFAULT_TOAST_CONFIG.closable
|
|
329
|
+
closable: config.closable !== undefined ? config.closable : DEFAULT_TOAST_CONFIG.closable,
|
|
330
|
+
mask: config.mask || false
|
|
322
331
|
});
|
|
323
332
|
|
|
324
333
|
// 创建容器
|
|
325
334
|
var container = document.createElement('div');
|
|
326
335
|
container.setAttribute('data-toast-id', id);
|
|
336
|
+
// 如果开启遮罩,添加 data-mask 属性用于 CSS 样式区分
|
|
337
|
+
if (config.mask) {
|
|
338
|
+
container.setAttribute('data-mask', 'true');
|
|
339
|
+
}
|
|
327
340
|
|
|
328
341
|
// 计算动态的bottom位置
|
|
329
342
|
var dynamicBottomOffset = this.calculateAndCacheBottomOffset();
|
|
330
343
|
// const centerOffset = this.calculateAndCacheCenterOffset();
|
|
331
|
-
|
|
332
|
-
// 设置初始样式确保左下角定位
|
|
333
|
-
// 新Toast使用动态计算的位置
|
|
334
344
|
container.style.position = 'fixed';
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
345
|
+
// 如果开启遮罩,则需要居中
|
|
346
|
+
if (config.mask) {
|
|
347
|
+
container.style.left = '50%';
|
|
348
|
+
container.style.top = '50%';
|
|
349
|
+
container.style.transform = 'translate(-50%, -50%)';
|
|
350
|
+
container.style.bottom = 'auto';
|
|
351
|
+
container.style.right = 'auto';
|
|
352
|
+
} else {
|
|
353
|
+
// 设置初始样式确保左下角定位
|
|
354
|
+
// 新Toast使用动态计算的位置
|
|
355
|
+
container.style.left = "".concat(this.LEFT_OFFSET, "px");
|
|
356
|
+
container.style.bottom = "".concat(dynamicBottomOffset, "px"); // 使用动态计算的位置
|
|
357
|
+
container.style.top = 'auto';
|
|
358
|
+
container.style.right = 'auto';
|
|
359
|
+
container.style.transform = 'none';
|
|
360
|
+
}
|
|
361
|
+
|
|
339
362
|
// 移除强制的z-index设置,让Toast使用默认层级
|
|
340
363
|
// container.style.zIndex = `${(finalConfig.zIndex || 2000) + this.instances.size}`;
|
|
341
364
|
|
|
@@ -269,8 +269,8 @@ var PaymentResultToast = /*#__PURE__*/memo(function (props) {
|
|
|
269
269
|
mask: mask,
|
|
270
270
|
maskClosable: maskClosable,
|
|
271
271
|
closable: false,
|
|
272
|
-
className: getBaseClassName("".concat(className, " ").concat(statusClassName)),
|
|
273
|
-
wrapClassName: "toast-modal-wrap",
|
|
272
|
+
className: getBaseClassName("".concat(className, " ").concat(statusClassName, " ").concat(mask ? 'payment-result-toast-with-mask' : '')),
|
|
273
|
+
wrapClassName: "toast-modal-wrap ".concat(mask ? 'toast-modal-wrap-with-mask' : ''),
|
|
274
274
|
style: _objectSpread(_objectSpread({}, height ? {
|
|
275
275
|
height: "".concat(height, "px")
|
|
276
276
|
} : {}), {}, {
|
|
@@ -297,12 +297,12 @@ var PaymentResultToast = /*#__PURE__*/memo(function (props) {
|
|
|
297
297
|
,
|
|
298
298
|
transitionName: "",
|
|
299
299
|
maskTransitionName: ""
|
|
300
|
-
//
|
|
300
|
+
// mask 模式下使用居中定位,非 mask 模式下禁用居中
|
|
301
301
|
,
|
|
302
|
-
centered:
|
|
303
|
-
//
|
|
302
|
+
centered: mask
|
|
303
|
+
// mask 模式下渲染到 body,非 mask 模式下渲染到容器内
|
|
304
304
|
,
|
|
305
|
-
getContainer: false
|
|
305
|
+
getContainer: mask ? undefined : false
|
|
306
306
|
}, /*#__PURE__*/React.createElement("div", {
|
|
307
307
|
ref: modalContentRef,
|
|
308
308
|
className: getClassName('content', statusClassName),
|
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
margin: 0 !important;
|
|
18
18
|
pointer-events: none !important; // 让Toast Modal Wrap点击穿透
|
|
19
19
|
|
|
20
|
+
// 非 mask 模式下的样式
|
|
20
21
|
.ant-modal {
|
|
21
22
|
position: static !important;
|
|
22
23
|
top: auto !important;
|
|
@@ -32,11 +33,47 @@
|
|
|
32
33
|
}
|
|
33
34
|
}
|
|
34
35
|
|
|
36
|
+
// mask 模式下的全局样式(Modal 渲染到 body)
|
|
37
|
+
.toast-modal-wrap-with-mask {
|
|
38
|
+
position: fixed !important;
|
|
39
|
+
top: 0 !important;
|
|
40
|
+
left: 0 !important;
|
|
41
|
+
right: 0 !important;
|
|
42
|
+
bottom: 0 !important;
|
|
43
|
+
width: 100vw !important;
|
|
44
|
+
height: 100vh !important;
|
|
45
|
+
display: flex !important;
|
|
46
|
+
align-items: center !important;
|
|
47
|
+
justify-content: center !important;
|
|
48
|
+
pointer-events: auto !important; // mask 模式下需要响应点击
|
|
49
|
+
|
|
50
|
+
.ant-modal-mask {
|
|
51
|
+
position: fixed !important;
|
|
52
|
+
top: 0 !important;
|
|
53
|
+
left: 0 !important;
|
|
54
|
+
right: 0 !important;
|
|
55
|
+
bottom: 0 !important;
|
|
56
|
+
width: 100vw !important;
|
|
57
|
+
height: 100vh !important;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.ant-modal {
|
|
61
|
+
position: relative !important;
|
|
62
|
+
top: auto !important;
|
|
63
|
+
left: auto !important;
|
|
64
|
+
transform: none !important;
|
|
65
|
+
margin: 0 !important;
|
|
66
|
+
padding: 0 !important;
|
|
67
|
+
width: auto !important;
|
|
68
|
+
max-width: none !important;
|
|
69
|
+
pointer-events: auto !important; // Modal 内容可以响应点击
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
35
73
|
// Toast容器样式 - 用于多实例定位
|
|
36
74
|
[data-toast-id] {
|
|
37
75
|
z-index: 1000;
|
|
38
76
|
position: fixed !important;
|
|
39
|
-
left: 96px !important;
|
|
40
77
|
/* 注意:不设置bottom的!important,让JavaScript可以动态更新 */
|
|
41
78
|
/* 移除强制的z-index设置,让Toast使用默认层级 */
|
|
42
79
|
pointer-events: none !important; // 让Toast容器本身点击穿透
|
|
@@ -45,6 +82,23 @@
|
|
|
45
82
|
width: auto !important;
|
|
46
83
|
height: auto !important;
|
|
47
84
|
|
|
85
|
+
// 非 mask 模式下使用左下角定位
|
|
86
|
+
&:not([data-mask="true"]) {
|
|
87
|
+
left: 96px !important;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
// mask 模式下,Modal 会渲染到 body,容器只作为占位符
|
|
91
|
+
// 不需要设置定位,因为 Modal 已经独立渲染
|
|
92
|
+
&[data-mask="true"] {
|
|
93
|
+
// 容器在 mask 模式下不需要定位,Modal 会独立渲染到 body
|
|
94
|
+
position: static !important;
|
|
95
|
+
left: auto !important;
|
|
96
|
+
top: auto !important;
|
|
97
|
+
bottom: auto !important;
|
|
98
|
+
right: auto !important;
|
|
99
|
+
transform: none !important;
|
|
100
|
+
}
|
|
101
|
+
|
|
48
102
|
/* 新Toast进入动画 */
|
|
49
103
|
&.toast-entering {
|
|
50
104
|
opacity: 0;
|
|
@@ -81,42 +135,49 @@
|
|
|
81
135
|
}
|
|
82
136
|
|
|
83
137
|
// 强制覆盖Ant Design Modal的默认定位
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
138
|
+
// 非 mask 模式下使用 static 定位
|
|
139
|
+
&:not([data-mask="true"]) {
|
|
140
|
+
.ant-modal-wrap {
|
|
141
|
+
position: static !important;
|
|
142
|
+
pointer-events: none !important; // 让Modal wrap点击穿透
|
|
143
|
+
}
|
|
88
144
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
145
|
+
.ant-modal {
|
|
146
|
+
position: static !important;
|
|
147
|
+
top: auto !important;
|
|
148
|
+
left: auto !important;
|
|
149
|
+
transform: none !important;
|
|
150
|
+
margin: 0 !important;
|
|
151
|
+
padding: 0 !important;
|
|
152
|
+
pointer-events: none !important; // 让Modal本身点击穿透
|
|
153
|
+
}
|
|
97
154
|
}
|
|
98
155
|
|
|
156
|
+
// mask 模式下,Modal 会渲染到 body,容器内的样式不再需要
|
|
157
|
+
// 样式已通过全局 .toast-modal-wrap-with-mask 类名设置
|
|
99
158
|
|
|
100
|
-
// 覆盖所有可能的Ant Design Modal
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
159
|
+
// 覆盖所有可能的Ant Design Modal定位(非 mask 模式)
|
|
160
|
+
&:not([data-mask="true"]) {
|
|
161
|
+
.ant-modal-wrap {
|
|
162
|
+
position: static !important;
|
|
163
|
+
display: block !important;
|
|
164
|
+
overflow: visible !important;
|
|
165
|
+
pointer-events: none !important; // 让Modal wrap点击穿透
|
|
166
|
+
}
|
|
107
167
|
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
168
|
+
.ant-modal {
|
|
169
|
+
position: static !important;
|
|
170
|
+
top: auto !important;
|
|
171
|
+
left: auto !important;
|
|
172
|
+
right: auto !important;
|
|
173
|
+
bottom: auto !important;
|
|
174
|
+
transform: none !important;
|
|
175
|
+
margin: 0 !important;
|
|
176
|
+
padding: 0 !important;
|
|
177
|
+
width: 100% !important;
|
|
178
|
+
max-width: none !important;
|
|
179
|
+
pointer-events: none !important; // 让Modal点击穿透
|
|
180
|
+
}
|
|
120
181
|
}
|
|
121
182
|
|
|
122
183
|
// Toast进入动画
|
|
@@ -401,7 +462,7 @@
|
|
|
401
462
|
// 副标题样式
|
|
402
463
|
&-subtitle {
|
|
403
464
|
&-text {
|
|
404
|
-
font-size:
|
|
465
|
+
font-size: 48px; // 与图片一致
|
|
405
466
|
font-weight: 600; // 与图片一致
|
|
406
467
|
text-shadow: none; // 移除阴影
|
|
407
468
|
|
|
@@ -17,7 +17,7 @@ export declare const useWalletPass: (props: {
|
|
|
17
17
|
cardData: any;
|
|
18
18
|
handleSelectWallet: (value: number[]) => void;
|
|
19
19
|
selectedWalletIds: any[];
|
|
20
|
-
expiredWalletIds: any;
|
|
20
|
+
expiredWalletIds: any[];
|
|
21
21
|
expiredWalletData: any;
|
|
22
22
|
disabledWalletData: any[];
|
|
23
23
|
clearAllSelectedWallet: () => void;
|