@pisell/private-materials 6.3.123 → 6.3.124
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/index.js +1 -1
- package/build/lowcode/preview.js +4 -4
- package/build/lowcode/render/default/view.js +4 -4
- package/build/lowcode/view.js +4 -4
- package/es/components/booking/addons/model.d.ts +10 -1
- package/es/components/booking/forms/model.d.ts +10 -1
- package/es/components/booking/forms/sendModal/useSendModal.d.ts +0 -1
- package/es/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
- package/es/components/booking/info/model.d.ts +10 -1
- 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/eftpos/hooks.d.ts +1 -0
- package/es/components/eventBooking/components/ErrorTip/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +0 -1
- package/es/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +0 -1
- package/es/components/pay/toC/PaymentMethods/WalletPass/index.d.ts +0 -5
- package/es/components/pay/toC/PaymentMethods/WalletPass/index.js +142 -165
- package/es/components/pay/toC/PaymentMethods/WalletPass/serve.d.ts +0 -6
- package/es/components/pay/toC/PaymentMethods/WalletPass/utils.js +3 -3
- package/es/components/pay/toC/WalletPassBlock/index.js +1 -3
- package/es/components/pay/toC/index.js +31 -65
- package/es/components/pay/toC/model.d.ts +9 -2
- package/es/components/pay/toC/serve.d.ts +0 -18
- package/es/components/pay/toC/serve.js +15 -42
- package/es/components/pay/toC/utils.d.ts +2 -2
- package/es/components/pay/toC/utils.js +0 -4
- package/es/components/schedules/model.d.ts +9 -1
- package/es/plus/selectHolder/components/ErrorTip/index.d.ts +0 -1
- package/es/pro/Login2.0/components/phoneValidation.js +65 -58
- package/lib/components/booking/addons/model.d.ts +10 -1
- package/lib/components/booking/forms/model.d.ts +10 -1
- package/lib/components/booking/forms/sendModal/useSendModal.d.ts +0 -1
- package/lib/components/booking/info/hooks/useInfoHolder.d.ts +0 -1
- package/lib/components/booking/info/model.d.ts +10 -1
- 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/eftpos/hooks.d.ts +1 -0
- package/lib/components/eventBooking/components/ErrorTip/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/CallToBook/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/WeekItem/index.d.ts +0 -1
- package/lib/components/eventBooking/components/bookingAvailabilityCalendar/components/CalendarDate/CalenDateWeek/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/Finish/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/StripePay/Stripe/components/PageLoading/index.d.ts +0 -1
- package/lib/components/pay/toC/PaymentMethods/WalletPass/index.d.ts +0 -5
- package/lib/components/pay/toC/PaymentMethods/WalletPass/index.js +100 -90
- package/lib/components/pay/toC/PaymentMethods/WalletPass/serve.d.ts +0 -6
- package/lib/components/pay/toC/PaymentMethods/WalletPass/utils.js +2 -2
- package/lib/components/pay/toC/WalletPassBlock/index.js +1 -3
- package/lib/components/pay/toC/index.js +19 -52
- package/lib/components/pay/toC/model.d.ts +9 -2
- package/lib/components/pay/toC/serve.d.ts +0 -18
- package/lib/components/pay/toC/serve.js +0 -6
- package/lib/components/pay/toC/utils.d.ts +2 -2
- package/lib/components/pay/toC/utils.js +2 -6
- package/lib/components/schedules/model.d.ts +9 -1
- package/lib/plus/selectHolder/components/ErrorTip/index.d.ts +0 -1
- package/lib/pro/Login2.0/components/phoneValidation.js +4 -2
- package/package.json +2 -2
|
@@ -12,7 +12,7 @@ function _asyncToGenerator(fn) { return function () { var self = this, args = ar
|
|
|
12
12
|
*/
|
|
13
13
|
export var validatePhoneNumber = /*#__PURE__*/function () {
|
|
14
14
|
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(value, getText) {
|
|
15
|
-
var phone, countryCode, match;
|
|
15
|
+
var phone, countryCode, match, usCanadaReg, auReg;
|
|
16
16
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
17
17
|
while (1) switch (_context.prev = _context.next) {
|
|
18
18
|
case 0:
|
|
@@ -55,7 +55,7 @@ export var validatePhoneNumber = /*#__PURE__*/function () {
|
|
|
55
55
|
throw new Error(getText('pisell-phone-validation-required'));
|
|
56
56
|
case 16:
|
|
57
57
|
_context.t0 = countryCode;
|
|
58
|
-
_context.next = _context.t0 === '86' ? 19 : _context.t0 === '852' ? 22 : _context.t0 === '853' ? 25 : _context.t0 === '886' ? 28 : _context.t0 === '1' ? 31 : _context.t0 === '44' ?
|
|
58
|
+
_context.next = _context.t0 === '86' ? 19 : _context.t0 === '852' ? 22 : _context.t0 === '853' ? 25 : _context.t0 === '886' ? 28 : _context.t0 === '1' ? 31 : _context.t0 === '44' ? 35 : _context.t0 === '61' ? 38 : _context.t0 === '81' ? 42 : _context.t0 === '82' ? 45 : _context.t0 === '65' ? 48 : _context.t0 === '60' ? 51 : _context.t0 === '66' ? 54 : _context.t0 === '84' ? 57 : _context.t0 === '63' ? 60 : _context.t0 === '62' ? 63 : _context.t0 === '91' ? 66 : 69;
|
|
59
59
|
break;
|
|
60
60
|
case 19:
|
|
61
61
|
if (/^1[3-9]\d{9}$/.test(phone)) {
|
|
@@ -64,7 +64,7 @@ export var validatePhoneNumber = /*#__PURE__*/function () {
|
|
|
64
64
|
}
|
|
65
65
|
throw new Error(getText('pisell-phone-validation-china'));
|
|
66
66
|
case 21:
|
|
67
|
-
return _context.abrupt("break",
|
|
67
|
+
return _context.abrupt("break", 72);
|
|
68
68
|
case 22:
|
|
69
69
|
if (/^[5-9]\d{7}$/.test(phone)) {
|
|
70
70
|
_context.next = 24;
|
|
@@ -72,7 +72,7 @@ export var validatePhoneNumber = /*#__PURE__*/function () {
|
|
|
72
72
|
}
|
|
73
73
|
throw new Error(getText('pisell-phone-validation-hongkong'));
|
|
74
74
|
case 24:
|
|
75
|
-
return _context.abrupt("break",
|
|
75
|
+
return _context.abrupt("break", 72);
|
|
76
76
|
case 25:
|
|
77
77
|
if (/^6\d{7}$/.test(phone)) {
|
|
78
78
|
_context.next = 27;
|
|
@@ -80,7 +80,7 @@ export var validatePhoneNumber = /*#__PURE__*/function () {
|
|
|
80
80
|
}
|
|
81
81
|
throw new Error(getText('pisell-phone-validation-macau'));
|
|
82
82
|
case 27:
|
|
83
|
-
return _context.abrupt("break",
|
|
83
|
+
return _context.abrupt("break", 72);
|
|
84
84
|
case 28:
|
|
85
85
|
if (/^9\d{8}$/.test(phone)) {
|
|
86
86
|
_context.next = 30;
|
|
@@ -88,112 +88,119 @@ export var validatePhoneNumber = /*#__PURE__*/function () {
|
|
|
88
88
|
}
|
|
89
89
|
throw new Error(getText('pisell-phone-validation-taiwan'));
|
|
90
90
|
case 30:
|
|
91
|
-
return _context.abrupt("break",
|
|
91
|
+
return _context.abrupt("break", 72);
|
|
92
92
|
case 31:
|
|
93
|
-
|
|
94
|
-
|
|
93
|
+
// 美国/加拿大
|
|
94
|
+
// NANP 标准 10 位格式:3位区号[2-9] + 3位局号[2-9] + 4位
|
|
95
|
+
usCanadaReg = /^[2-9]\d{2}[2-9]\d{6}$/;
|
|
96
|
+
if (usCanadaReg.test(phone)) {
|
|
97
|
+
_context.next = 34;
|
|
95
98
|
break;
|
|
96
99
|
}
|
|
97
100
|
throw new Error(getText('pisell-phone-validation-us-canada'));
|
|
98
|
-
case 33:
|
|
99
|
-
return _context.abrupt("break", 70);
|
|
100
101
|
case 34:
|
|
102
|
+
return _context.abrupt("break", 72);
|
|
103
|
+
case 35:
|
|
101
104
|
if (/^7\d{9}$/.test(phone)) {
|
|
102
|
-
_context.next =
|
|
105
|
+
_context.next = 37;
|
|
103
106
|
break;
|
|
104
107
|
}
|
|
105
108
|
throw new Error(getText('pisell-phone-validation-uk'));
|
|
106
|
-
case 36:
|
|
107
|
-
return _context.abrupt("break", 70);
|
|
108
109
|
case 37:
|
|
109
|
-
|
|
110
|
-
|
|
110
|
+
return _context.abrupt("break", 72);
|
|
111
|
+
case 38:
|
|
112
|
+
// 澳大利亚
|
|
113
|
+
// const reg = /^(\+?0)?4\d{8}$/;
|
|
114
|
+
// 固话前缀 02/03/07/08, 手机前缀 04/05, 首位 0 可选
|
|
115
|
+
auReg = /^0?[2-578]\d{8}$/;
|
|
116
|
+
if (auReg.test(phone)) {
|
|
117
|
+
_context.next = 41;
|
|
111
118
|
break;
|
|
112
119
|
}
|
|
113
120
|
throw new Error(getText('pisell-phone-validation-australia'));
|
|
114
|
-
case
|
|
115
|
-
return _context.abrupt("break",
|
|
116
|
-
case
|
|
121
|
+
case 41:
|
|
122
|
+
return _context.abrupt("break", 72);
|
|
123
|
+
case 42:
|
|
117
124
|
if (/^[789]0\d{8}$/.test(phone)) {
|
|
118
|
-
_context.next =
|
|
125
|
+
_context.next = 44;
|
|
119
126
|
break;
|
|
120
127
|
}
|
|
121
128
|
throw new Error(getText('pisell-phone-validation-japan'));
|
|
122
|
-
case
|
|
123
|
-
return _context.abrupt("break",
|
|
124
|
-
case
|
|
129
|
+
case 44:
|
|
130
|
+
return _context.abrupt("break", 72);
|
|
131
|
+
case 45:
|
|
125
132
|
if (/^1[0-9]\d{7,8}$/.test(phone)) {
|
|
126
|
-
_context.next =
|
|
133
|
+
_context.next = 47;
|
|
127
134
|
break;
|
|
128
135
|
}
|
|
129
136
|
throw new Error(getText('pisell-phone-validation-korea'));
|
|
130
|
-
case
|
|
131
|
-
return _context.abrupt("break",
|
|
132
|
-
case
|
|
137
|
+
case 47:
|
|
138
|
+
return _context.abrupt("break", 72);
|
|
139
|
+
case 48:
|
|
133
140
|
if (/^[89]\d{7}$/.test(phone)) {
|
|
134
|
-
_context.next =
|
|
141
|
+
_context.next = 50;
|
|
135
142
|
break;
|
|
136
143
|
}
|
|
137
144
|
throw new Error(getText('pisell-phone-validation-singapore'));
|
|
138
|
-
case
|
|
139
|
-
return _context.abrupt("break",
|
|
140
|
-
case
|
|
145
|
+
case 50:
|
|
146
|
+
return _context.abrupt("break", 72);
|
|
147
|
+
case 51:
|
|
141
148
|
if (/^1[0-9]\d{7,8}$/.test(phone)) {
|
|
142
|
-
_context.next =
|
|
149
|
+
_context.next = 53;
|
|
143
150
|
break;
|
|
144
151
|
}
|
|
145
152
|
throw new Error(getText('pisell-phone-validation-malaysia'));
|
|
146
|
-
case
|
|
147
|
-
return _context.abrupt("break",
|
|
148
|
-
case
|
|
153
|
+
case 53:
|
|
154
|
+
return _context.abrupt("break", 72);
|
|
155
|
+
case 54:
|
|
149
156
|
if (/^[689]\d{8}$/.test(phone)) {
|
|
150
|
-
_context.next =
|
|
157
|
+
_context.next = 56;
|
|
151
158
|
break;
|
|
152
159
|
}
|
|
153
160
|
throw new Error(getText('pisell-phone-validation-thailand'));
|
|
154
|
-
case
|
|
155
|
-
return _context.abrupt("break",
|
|
156
|
-
case
|
|
161
|
+
case 56:
|
|
162
|
+
return _context.abrupt("break", 72);
|
|
163
|
+
case 57:
|
|
157
164
|
if (/^[3579]\d{8}$/.test(phone)) {
|
|
158
|
-
_context.next =
|
|
165
|
+
_context.next = 59;
|
|
159
166
|
break;
|
|
160
167
|
}
|
|
161
168
|
throw new Error(getText('pisell-phone-validation-vietnam'));
|
|
162
|
-
case
|
|
163
|
-
return _context.abrupt("break",
|
|
164
|
-
case
|
|
169
|
+
case 59:
|
|
170
|
+
return _context.abrupt("break", 72);
|
|
171
|
+
case 60:
|
|
165
172
|
if (/^9\d{9}$/.test(phone)) {
|
|
166
|
-
_context.next =
|
|
173
|
+
_context.next = 62;
|
|
167
174
|
break;
|
|
168
175
|
}
|
|
169
176
|
throw new Error(getText('pisell-phone-validation-philippines'));
|
|
170
|
-
case
|
|
171
|
-
return _context.abrupt("break",
|
|
172
|
-
case
|
|
177
|
+
case 62:
|
|
178
|
+
return _context.abrupt("break", 72);
|
|
179
|
+
case 63:
|
|
173
180
|
if (/^8\d{8,11}$/.test(phone)) {
|
|
174
|
-
_context.next =
|
|
181
|
+
_context.next = 65;
|
|
175
182
|
break;
|
|
176
183
|
}
|
|
177
184
|
throw new Error(getText('pisell-phone-validation-indonesia'));
|
|
178
|
-
case
|
|
179
|
-
return _context.abrupt("break",
|
|
180
|
-
case
|
|
185
|
+
case 65:
|
|
186
|
+
return _context.abrupt("break", 72);
|
|
187
|
+
case 66:
|
|
181
188
|
if (/^[6-9]\d{9}$/.test(phone)) {
|
|
182
|
-
_context.next =
|
|
189
|
+
_context.next = 68;
|
|
183
190
|
break;
|
|
184
191
|
}
|
|
185
192
|
throw new Error(getText('pisell-phone-validation-india'));
|
|
186
|
-
case
|
|
187
|
-
return _context.abrupt("break",
|
|
188
|
-
case
|
|
193
|
+
case 68:
|
|
194
|
+
return _context.abrupt("break", 72);
|
|
195
|
+
case 69:
|
|
189
196
|
if (/^\d{6,15}$/.test(phone)) {
|
|
190
|
-
_context.next =
|
|
197
|
+
_context.next = 71;
|
|
191
198
|
break;
|
|
192
199
|
}
|
|
193
200
|
throw new Error(getText('pisell-phone-validation-invalid'));
|
|
194
|
-
case
|
|
195
|
-
return _context.abrupt("break",
|
|
196
|
-
case
|
|
201
|
+
case 71:
|
|
202
|
+
return _context.abrupt("break", 72);
|
|
203
|
+
case 72:
|
|
197
204
|
case "end":
|
|
198
205
|
return _context.stop();
|
|
199
206
|
}
|
|
@@ -1 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { FormState } from "../model";
|
|
3
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
|
4
|
+
state: FormState;
|
|
5
|
+
} & {
|
|
6
|
+
dispatch: (params: {
|
|
7
|
+
type: string;
|
|
8
|
+
payload: any;
|
|
9
|
+
}) => void;
|
|
10
|
+
}>;
|
|
@@ -1 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { FormState } from "../model";
|
|
3
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
|
4
|
+
state: FormState;
|
|
5
|
+
} & {
|
|
6
|
+
dispatch: (params: {
|
|
7
|
+
type: string;
|
|
8
|
+
payload: any;
|
|
9
|
+
}) => void;
|
|
10
|
+
}>;
|
|
@@ -1,5 +1,14 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { FormState } from '../model';
|
|
1
3
|
export declare const walkInData: {
|
|
2
4
|
id: number;
|
|
3
5
|
nickname: string;
|
|
4
6
|
};
|
|
5
|
-
export declare const Provider: any, Context:
|
|
7
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
|
8
|
+
state: FormState;
|
|
9
|
+
} & {
|
|
10
|
+
dispatch: (params: {
|
|
11
|
+
type: string;
|
|
12
|
+
payload: any;
|
|
13
|
+
}) => void;
|
|
14
|
+
}>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
export interface FormState {
|
|
2
3
|
amountSymbol: string;
|
|
3
4
|
apis: {
|
|
@@ -109,4 +110,11 @@ export declare const walkInData: {
|
|
|
109
110
|
id: number;
|
|
110
111
|
nickname: string;
|
|
111
112
|
};
|
|
112
|
-
export declare const Provider: any, Context:
|
|
113
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
|
114
|
+
state: FormState;
|
|
115
|
+
} & {
|
|
116
|
+
dispatch: (params: {
|
|
117
|
+
type: string;
|
|
118
|
+
payload: any;
|
|
119
|
+
}) => void;
|
|
120
|
+
}>;
|
|
@@ -1 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { FormState } from "../model";
|
|
3
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
|
4
|
+
state: FormState;
|
|
5
|
+
} & {
|
|
6
|
+
dispatch: (params: {
|
|
7
|
+
type: string;
|
|
8
|
+
payload: any;
|
|
9
|
+
}) => void;
|
|
10
|
+
}>;
|
|
@@ -1 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { FormState } from "../model";
|
|
3
|
+
export declare const Provider: (ComponentUi: any) => any, Context: import("react").Context<{
|
|
4
|
+
state: FormState;
|
|
5
|
+
} & {
|
|
6
|
+
dispatch: (params: {
|
|
7
|
+
type: string;
|
|
8
|
+
payload: any;
|
|
9
|
+
}) => void;
|
|
10
|
+
}>;
|
|
@@ -15,16 +15,11 @@ export interface WalletPassProps {
|
|
|
15
15
|
walletPass: {
|
|
16
16
|
cards: WalletPassDataType[];
|
|
17
17
|
amount: number;
|
|
18
|
-
recommended?: WalletPassDataType[];
|
|
19
|
-
transformList?: WalletPassDataType[];
|
|
20
|
-
noApplicableVoucher?: WalletPassDataType[];
|
|
21
18
|
};
|
|
22
19
|
walletSetting: {
|
|
23
20
|
name: string;
|
|
24
21
|
popup_status: 0 | 1;
|
|
25
22
|
};
|
|
26
|
-
orderDetail: any;
|
|
27
|
-
total_amount: number;
|
|
28
23
|
}
|
|
29
24
|
declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<WalletPassProps & React.RefAttributes<WalletPassRef>>>;
|
|
30
25
|
export default _default;
|