pay-sdk-react 1.1.12 → 1.1.14
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/README.md +226 -8
- package/README.zh-CN.md +225 -8
- package/dist/css/index.css +75 -6
- package/dist/css/index.min.css +1 -1
- package/dist/es/Airwallex/style/index.css +2 -2
- package/dist/es/Airwallex/style/index.min.css +1 -1
- package/dist/es/Alipay/style/index.css +2 -2
- package/dist/es/Alipay/style/index.min.css +1 -1
- package/dist/es/MAlipay/style/index.css +2 -2
- package/dist/es/MAlipay/style/index.min.css +1 -1
- package/dist/es/MPix/index.d.ts +2 -0
- package/dist/es/MPix/index.js +2 -0
- package/dist/es/MPix/interface.d.ts +44 -0
- package/dist/es/MPix/interface.js +1 -0
- package/dist/es/MPix/m-pix-button.d.ts +6 -0
- package/dist/es/MPix/m-pix-button.js +159 -0
- package/dist/es/MPix/style/index.css +256 -0
- package/dist/es/MPix/style/index.d.ts +1 -0
- package/dist/es/MPix/style/index.js +1 -0
- package/dist/es/MPix/style/index.min.css +1 -0
- package/dist/es/MWeChat/style/index.css +2 -2
- package/dist/es/MWeChat/style/index.min.css +1 -1
- package/dist/es/PayButton/index.js +12 -0
- package/dist/es/PayButton/interface.d.ts +28 -2
- package/dist/es/Pix/index.d.ts +11 -0
- package/dist/es/Pix/index.js +10 -0
- package/dist/es/Pix/interface.d.ts +80 -0
- package/dist/es/Pix/interface.js +1 -0
- package/dist/es/Pix/pix-button.d.ts +6 -0
- package/dist/es/Pix/pix-button.js +80 -0
- package/dist/es/Pix/pix-modal.d.ts +6 -0
- package/dist/es/Pix/pix-modal.js +57 -0
- package/dist/es/Pix/pix.d.ts +4 -0
- package/dist/es/Pix/pix.js +120 -0
- package/dist/es/Pix/style/index.css +69 -0
- package/dist/es/Pix/style/index.d.ts +1 -0
- package/dist/es/Pix/style/index.js +1 -0
- package/dist/es/Pix/style/index.min.css +1 -0
- package/dist/es/Stripe/style/index.css +2 -2
- package/dist/es/Stripe/style/index.min.css +1 -1
- package/dist/es/Wechat/style/index.css +2 -2
- package/dist/es/Wechat/style/index.min.css +1 -1
- package/dist/es/confirm-modal/style/index.css +2 -2
- package/dist/es/confirm-modal/style/index.min.css +1 -1
- package/dist/es/icons/IconCheck/index.d.ts +4 -0
- package/dist/es/icons/IconCheck/index.js +22 -0
- package/dist/es/icons/IconCopy/index.d.ts +4 -0
- package/dist/es/icons/IconCopy/index.js +27 -0
- package/dist/es/icons/IconPix/index.d.ts +4 -0
- package/dist/es/icons/IconPix/index.js +33 -0
- package/dist/es/icons/index.d.ts +3 -0
- package/dist/es/icons/index.js +4 -1
- package/dist/es/index.d.ts +17 -0
- package/dist/es/index.js +9 -0
- package/dist/es/pay-modal/style/index.css +2 -2
- package/dist/es/pay-modal/style/index.min.css +1 -1
- package/dist/es/shared/enums/index.d.ts +11 -1
- package/dist/es/shared/enums/index.js +10 -0
- package/dist/lib/Airwallex/style/index.css +2 -2
- package/dist/lib/Airwallex/style/index.min.css +1 -1
- package/dist/lib/Alipay/style/index.css +2 -2
- package/dist/lib/Alipay/style/index.min.css +1 -1
- package/dist/lib/MAlipay/style/index.css +2 -2
- package/dist/lib/MAlipay/style/index.min.css +1 -1
- package/dist/lib/MPix/index.js +28 -0
- package/dist/lib/MPix/interface.js +5 -0
- package/dist/lib/MPix/m-pix-button.js +127 -0
- package/dist/lib/MPix/style/index.css +256 -0
- package/dist/lib/MPix/style/index.js +3 -0
- package/dist/lib/MPix/style/index.min.css +1 -0
- package/dist/lib/MWeChat/style/index.css +2 -2
- package/dist/lib/MWeChat/style/index.min.css +1 -1
- package/dist/lib/PayButton/index.js +12 -0
- package/dist/lib/Pix/index.js +43 -0
- package/dist/lib/Pix/interface.js +5 -0
- package/dist/lib/Pix/pix-button.js +68 -0
- package/dist/lib/Pix/pix-modal.js +50 -0
- package/dist/lib/Pix/pix.js +92 -0
- package/dist/lib/Pix/style/index.css +69 -0
- package/dist/lib/Pix/style/index.js +3 -0
- package/dist/lib/Pix/style/index.min.css +1 -0
- package/dist/lib/Stripe/style/index.css +2 -2
- package/dist/lib/Stripe/style/index.min.css +1 -1
- package/dist/lib/Wechat/style/index.css +2 -2
- package/dist/lib/Wechat/style/index.min.css +1 -1
- package/dist/lib/confirm-modal/style/index.css +2 -2
- package/dist/lib/confirm-modal/style/index.min.css +1 -1
- package/dist/lib/icons/IconCheck/index.js +27 -0
- package/dist/lib/icons/IconCopy/index.js +32 -0
- package/dist/lib/icons/IconPix/index.js +38 -0
- package/dist/lib/icons/index.js +25 -1
- package/dist/lib/index.js +29 -0
- package/dist/lib/pay-modal/style/index.css +2 -2
- package/dist/lib/pay-modal/style/index.min.css +1 -1
- package/dist/lib/shared/enums/index.js +10 -0
- package/dist/umd/pay-sdk-react.umd.js +304 -69
- package/dist/umd/pay-sdk-react.umd.js.map +1 -1
- package/package.json +34 -25
package/dist/lib/icons/index.js
CHANGED
|
@@ -11,7 +11,10 @@ var _exportNames = {
|
|
|
11
11
|
IconStripeText: true,
|
|
12
12
|
IconAlipay: true,
|
|
13
13
|
IconWechatPay: true,
|
|
14
|
-
IconPayssionPay: true
|
|
14
|
+
IconPayssionPay: true,
|
|
15
|
+
IconPix: true,
|
|
16
|
+
IconCopy: true,
|
|
17
|
+
IconCheck: true
|
|
15
18
|
};
|
|
16
19
|
Object.defineProperty(exports, "IconAlipay", {
|
|
17
20
|
enumerable: true,
|
|
@@ -19,12 +22,24 @@ Object.defineProperty(exports, "IconAlipay", {
|
|
|
19
22
|
return _IconAlipay.default;
|
|
20
23
|
}
|
|
21
24
|
});
|
|
25
|
+
Object.defineProperty(exports, "IconCheck", {
|
|
26
|
+
enumerable: true,
|
|
27
|
+
get: function () {
|
|
28
|
+
return _IconCheck.default;
|
|
29
|
+
}
|
|
30
|
+
});
|
|
22
31
|
Object.defineProperty(exports, "IconClose", {
|
|
23
32
|
enumerable: true,
|
|
24
33
|
get: function () {
|
|
25
34
|
return _IconClose.default;
|
|
26
35
|
}
|
|
27
36
|
});
|
|
37
|
+
Object.defineProperty(exports, "IconCopy", {
|
|
38
|
+
enumerable: true,
|
|
39
|
+
get: function () {
|
|
40
|
+
return _IconCopy.default;
|
|
41
|
+
}
|
|
42
|
+
});
|
|
28
43
|
Object.defineProperty(exports, "IconPaypalText", {
|
|
29
44
|
enumerable: true,
|
|
30
45
|
get: function () {
|
|
@@ -43,6 +58,12 @@ Object.defineProperty(exports, "IconPayssionPay", {
|
|
|
43
58
|
return _IconPayssionPay.default;
|
|
44
59
|
}
|
|
45
60
|
});
|
|
61
|
+
Object.defineProperty(exports, "IconPix", {
|
|
62
|
+
enumerable: true,
|
|
63
|
+
get: function () {
|
|
64
|
+
return _IconPix.default;
|
|
65
|
+
}
|
|
66
|
+
});
|
|
46
67
|
Object.defineProperty(exports, "IconStripe", {
|
|
47
68
|
enumerable: true,
|
|
48
69
|
get: function () {
|
|
@@ -81,4 +102,7 @@ var _IconStripeText = _interopRequireDefault(require("./IconStripeText"));
|
|
|
81
102
|
var _IconAlipay = _interopRequireDefault(require("./IconAlipay"));
|
|
82
103
|
var _IconWechatPay = _interopRequireDefault(require("./IconWechatPay"));
|
|
83
104
|
var _IconPayssionPay = _interopRequireDefault(require("./IconPayssionPay"));
|
|
105
|
+
var _IconPix = _interopRequireDefault(require("./IconPix"));
|
|
106
|
+
var _IconCopy = _interopRequireDefault(require("./IconCopy"));
|
|
107
|
+
var _IconCheck = _interopRequireDefault(require("./IconCheck"));
|
|
84
108
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
package/dist/lib/index.js
CHANGED
|
@@ -9,6 +9,7 @@ var _exportNames = {
|
|
|
9
9
|
MAlipay: true,
|
|
10
10
|
Alipay: true,
|
|
11
11
|
Wechat: true,
|
|
12
|
+
Pix: true,
|
|
12
13
|
PaypalButton: true,
|
|
13
14
|
StripeButton: true,
|
|
14
15
|
StripePopup: true,
|
|
@@ -23,6 +24,9 @@ var _exportNames = {
|
|
|
23
24
|
AlipayModal: true,
|
|
24
25
|
WechatButton: true,
|
|
25
26
|
WechatModal: true,
|
|
27
|
+
PixButton: true,
|
|
28
|
+
PixModal: true,
|
|
29
|
+
MPixButton: true,
|
|
26
30
|
PayButton: true
|
|
27
31
|
};
|
|
28
32
|
exports.Airwallex = void 0;
|
|
@@ -64,6 +68,12 @@ Object.defineProperty(exports, "MAlipayButton", {
|
|
|
64
68
|
return _MAlipay.MAlipayButton;
|
|
65
69
|
}
|
|
66
70
|
});
|
|
71
|
+
Object.defineProperty(exports, "MPixButton", {
|
|
72
|
+
enumerable: true,
|
|
73
|
+
get: function () {
|
|
74
|
+
return _MPix.MPixButton;
|
|
75
|
+
}
|
|
76
|
+
});
|
|
67
77
|
Object.defineProperty(exports, "MWechatButton", {
|
|
68
78
|
enumerable: true,
|
|
69
79
|
get: function () {
|
|
@@ -88,6 +98,19 @@ Object.defineProperty(exports, "PayssionButton", {
|
|
|
88
98
|
return _Payssion.PayssionButton;
|
|
89
99
|
}
|
|
90
100
|
});
|
|
101
|
+
exports.Pix = void 0;
|
|
102
|
+
Object.defineProperty(exports, "PixButton", {
|
|
103
|
+
enumerable: true,
|
|
104
|
+
get: function () {
|
|
105
|
+
return _Pix.PixButton;
|
|
106
|
+
}
|
|
107
|
+
});
|
|
108
|
+
Object.defineProperty(exports, "PixModal", {
|
|
109
|
+
enumerable: true,
|
|
110
|
+
get: function () {
|
|
111
|
+
return _Pix.PixModal;
|
|
112
|
+
}
|
|
113
|
+
});
|
|
91
114
|
exports.Stripe = void 0;
|
|
92
115
|
Object.defineProperty(exports, "StripeButton", {
|
|
93
116
|
enumerable: true,
|
|
@@ -128,6 +151,8 @@ var _MWeChat = require("./MWeChat");
|
|
|
128
151
|
var _MAlipay = _interopRequireWildcard(require("./MAlipay"));
|
|
129
152
|
var _Alipay = _interopRequireWildcard(require("./Alipay"));
|
|
130
153
|
var _Wechat = _interopRequireWildcard(require("./Wechat"));
|
|
154
|
+
var _Pix = _interopRequireWildcard(require("./Pix"));
|
|
155
|
+
var _MPix = require("./MPix");
|
|
131
156
|
var _PayButton = _interopRequireDefault(require("./PayButton"));
|
|
132
157
|
var _shared = require("./shared");
|
|
133
158
|
Object.keys(_shared).forEach(function (key) {
|
|
@@ -163,4 +188,8 @@ const Alipay = exports.Alipay = Object.assign({}, _Alipay.default, {
|
|
|
163
188
|
const Wechat = exports.Wechat = Object.assign({}, _Wechat.default, {
|
|
164
189
|
Button: _Wechat.WechatButton,
|
|
165
190
|
Modal: _Wechat.WechatModal
|
|
191
|
+
});
|
|
192
|
+
const Pix = exports.Pix = Object.assign({}, _Pix.default, {
|
|
193
|
+
Button: _Pix.PixButton,
|
|
194
|
+
Modal: _Pix.PixModal
|
|
166
195
|
});
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
max-width: 80vw;
|
|
29
29
|
box-shadow: 0 4px 24px #0001;
|
|
30
30
|
text-align: center;
|
|
31
|
-
max-height:
|
|
31
|
+
max-height: 80vh;
|
|
32
32
|
display: flex;
|
|
33
33
|
flex-direction: column;
|
|
34
34
|
}
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
z-index: 1;
|
|
69
69
|
text-align: center;
|
|
70
70
|
overflow-y: auto;
|
|
71
|
-
flex: 1;
|
|
71
|
+
flex: 0 1 auto;
|
|
72
72
|
min-height: 0;
|
|
73
73
|
}
|
|
74
74
|
.pay-modal__actions {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.pay-modal{position:fixed;z-index:9999;left:0;top:0;right:0;bottom:0;display:flex;align-items:center;justify-content:center}.pay-modal__mask{position:absolute;left:0;top:0;right:0;bottom:0;background:rgba(0,0,0,.55);z-index:0}.pay-modal__content{position:relative;z-index:1;background:#fff;border-radius:16px;padding:42px 20px 20px;min-width:280px;max-width:80vw;box-shadow:0 4px 24px #0001;text-align:center;max-height:
|
|
1
|
+
.pay-modal{position:fixed;z-index:9999;left:0;top:0;right:0;bottom:0;display:flex;align-items:center;justify-content:center}.pay-modal__mask{position:absolute;left:0;top:0;right:0;bottom:0;background:rgba(0,0,0,.55);z-index:0}.pay-modal__content{position:relative;z-index:1;background:#fff;border-radius:16px;padding:42px 20px 20px;min-width:280px;max-width:80vw;box-shadow:0 4px 24px #0001;text-align:center;max-height:80vh;display:flex;flex-direction:column}.pay-modal__close{position:absolute;right:12px;top:12px;background:0 0;border:none;font-size:32px;font-weight:500;line-height:32px;cursor:pointer;text-align:left}.pay-modal__icon{display:flex;justify-content:center;margin-bottom:8px;font-size:40px}.pay-modal__title{font-size:20px;font-weight:700;color:#222;margin-bottom:12px}.pay-modal__desc{color:#222;font-size:15px;margin-bottom:24px;line-height:1.7;text-align:left}.pay-modal__content-wrapper{position:relative;z-index:1;text-align:center;overflow-y:auto;flex:0 1 auto;min-height:0}.pay-modal__actions{display:flex;justify-content:center;gap:16px;margin-top:16px}.pay-modal__btn{min-width:96px;padding:8px 0;border-radius:24px;border:none;font-size:15px;font-weight:600;cursor:pointer;transition:background .2s}.pay-modal__btn--retry{background:#fff;color:#f25a5a;border:1.5px solid #f25a5a}.pay-modal__btn--finish{background:#f25a5a;color:#fff;border:none}
|
|
@@ -60,6 +60,16 @@ let PaymentMethod = exports.PaymentMethod = /*#__PURE__*/function (PaymentMethod
|
|
|
60
60
|
* @en Airwallex
|
|
61
61
|
*/
|
|
62
62
|
PaymentMethod["Airwallex"] = "airwallex";
|
|
63
|
+
/**
|
|
64
|
+
* @zh PIX(pc)
|
|
65
|
+
* @en PIX(pc)
|
|
66
|
+
*/
|
|
67
|
+
PaymentMethod["PixPc"] = "pix-pc";
|
|
68
|
+
/**
|
|
69
|
+
* @zh PIX(H5)
|
|
70
|
+
* @en PIX(H5)
|
|
71
|
+
*/
|
|
72
|
+
PaymentMethod["PixH5"] = "pix-h5";
|
|
63
73
|
return PaymentMethod;
|
|
64
74
|
}({});
|
|
65
75
|
/**
|