iglooform 2.4.8 → 2.4.12
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/admin-upload/float.js +25 -35
- package/es/admin-upload/index.d.ts +2 -0
- package/es/admin-upload/index.js +43 -36
- package/es/admin-upload/job-list.js +85 -115
- package/es/admin-upload/modal.js +19 -26
- package/es/alert-message/index.js +11 -9
- package/es/amount/index.js +10 -5
- package/es/back-top/index.js +14 -10
- package/es/button/index.js +23 -28
- package/es/button/style/index.less +23 -19
- package/es/card-detail/card-group.js +16 -22
- package/es/card-detail/card-item.js +16 -21
- package/es/card-detail/card-page.js +11 -15
- package/es/card-detail/card.js +24 -24
- package/es/card-detail/utils.js +6 -7
- package/es/checkbox/index.js +23 -22
- package/es/claim-list/index.js +53 -70
- package/es/confirmation/index.js +7 -9
- package/es/date-picker/buddhist.js +3 -3
- package/es/date-picker/index.js +10 -4
- package/es/declaration/index.js +16 -13
- package/es/detail-panel/index.js +67 -83
- package/es/documents/index.js +6 -8
- package/es/example/index.js +9 -11
- package/es/filter/checkBox.js +33 -45
- package/es/filter/customize.js +3 -4
- package/es/filter/index.d.ts +1 -0
- package/es/filter/index.js +88 -112
- package/es/filter/radioBox.js +23 -31
- package/es/filter/rangePicker.js +43 -59
- package/es/form/addable-section/index.d.ts +19 -0
- package/es/form/addable-section/index.js +211 -0
- package/es/form/addable-section/style/index.d.ts +1 -0
- package/es/form/addable-section/style/index.js +1 -0
- package/es/form/addable-section/style/index.less +22 -0
- package/es/form/divider/index.js +7 -1
- package/es/form/element/index.js +58 -47
- package/es/form/element/style/index.less +9 -0
- package/es/form/index.js +16 -17
- package/es/form/login/index.js +15 -20
- package/es/form/page/index.js +18 -24
- package/es/form/page/style/index.less +1 -1
- package/es/form/pages/index.js +23 -32
- package/es/form/pages/style/index.less +3 -1
- package/es/form/render/index.js +1 -1
- package/es/form/section/index.js +14 -17
- package/es/form/step/index.js +31 -42
- package/es/form/steps/index.js +8 -11
- package/es/{form/context.d.ts → form-context.d.ts} +1 -0
- package/es/{form/context.js → form-context.js} +0 -0
- package/es/free-form/addable-section/index.d.ts +18 -0
- package/es/free-form/addable-section/index.js +286 -0
- package/es/free-form/addable-section/style/index.d.ts +1 -0
- package/es/free-form/addable-section/style/index.js +1 -0
- package/es/free-form/addable-section/style/index.less +22 -0
- package/es/free-form/element/index.js +43 -41
- package/es/free-form/element/style/index.less +12 -2
- package/es/free-form/index.d.ts +5 -1
- package/es/free-form/index.js +17 -17
- package/es/free-form/page/index.js +36 -46
- package/es/free-form/page/style/index.less +3 -1
- package/es/free-form/pages/index.js +8 -10
- package/es/free-form/section/index.js +20 -22
- package/es/free-form/section/style/index.less +4 -0
- package/es/free-form/step/index.js +37 -47
- package/es/free-form/steps/index.js +8 -10
- package/es/global-message/index.js +1 -1
- package/es/home-menu/index.js +52 -71
- package/es/index.d.ts +1 -0
- package/es/index.js +2 -1
- package/es/input/amount.js +10 -5
- package/es/input/credit-card.js +7 -1
- package/es/input/email.js +8 -1
- package/es/input/expiry-date.js +14 -18
- package/es/input/input-date.js +12 -16
- package/es/input/input-number.js +9 -2
- package/es/input/input.js +9 -2
- package/es/input/otp.js +17 -15
- package/es/input/password.js +12 -6
- package/es/input/phone-number.js +6 -8
- package/es/input/style/index.less +9 -1
- package/es/input/text-area.js +14 -10
- package/es/layout/defaultFooter.js +60 -82
- package/es/layout/defaultHeader.js +11 -15
- package/es/layout/footer.js +108 -148
- package/es/layout/header.js +51 -60
- package/es/layout/index.js +16 -12
- package/es/locale/en-US/messages.json +2 -0
- package/es/locale/id-ID/messages.json +2 -0
- package/es/locale/locale-provider.js +8 -10
- package/es/locale/th-TH/messages.json +2 -0
- package/es/locale/vi-VN/messages.json +2 -0
- package/es/locale/zh-CN/messages.json +2 -0
- package/es/login-page/index.js +30 -42
- package/es/media/index.js +20 -27
- package/es/media/media.js +9 -12
- package/es/media/preview.js +8 -10
- package/es/mobile-insurer-detail/index.js +74 -91
- package/es/mobile-insurer-list/index.js +34 -38
- package/es/modal/index.d.ts +4 -3
- package/es/modal/index.js +25 -27
- package/es/modal/style/index.less +24 -5
- package/es/platform/platform-card/index.js +9 -12
- package/es/platform/switch-platform/index.js +24 -32
- package/es/policy-list/index.js +11 -14
- package/es/policy-list/policy-card.js +119 -153
- package/es/radio/index.js +33 -35
- package/es/select/attached-select.js +31 -34
- package/es/select/select.js +12 -8
- package/es/select/style/index.less +1 -1
- package/es/select/time-select.js +12 -16
- package/es/status-box/index.js +8 -10
- package/es/table/index.js +72 -96
- package/es/tabs/index.js +7 -1
- package/es/types.d.ts +4 -2
- package/es/typography/index.js +6 -8
- package/es/upload/index.d.ts +2 -1
- package/es/upload/index.js +169 -143
- package/es/upload-photo/index.d.ts +2 -1
- package/es/upload-photo/index.js +170 -142
- package/es/upload-photo/media.js +3 -4
- package/es/upload-preview/index.js +9 -12
- package/es/upload-preview/media.js +12 -16
- package/es/utils/form-utils.js +49 -36
- package/lib/admin-upload/float.js +25 -35
- package/lib/admin-upload/index.d.ts +2 -0
- package/lib/admin-upload/index.js +43 -36
- package/lib/admin-upload/job-list.js +85 -115
- package/lib/admin-upload/modal.js +19 -26
- package/lib/alert-message/index.js +11 -9
- package/lib/amount/index.js +10 -5
- package/lib/back-top/index.js +14 -10
- package/lib/button/index.js +24 -29
- package/lib/button/style/index.less +23 -19
- package/lib/card-detail/card-group.js +16 -22
- package/lib/card-detail/card-item.js +16 -21
- package/lib/card-detail/card-page.js +11 -15
- package/lib/card-detail/card.js +24 -24
- package/lib/card-detail/index.js +6 -6
- package/lib/card-detail/utils.js +7 -8
- package/lib/checkbox/index.js +24 -23
- package/lib/claim-list/index.js +53 -70
- package/lib/confirmation/index.js +7 -9
- package/lib/date-picker/buddhist.js +3 -3
- package/lib/date-picker/index.js +11 -5
- package/lib/declaration/index.js +16 -13
- package/lib/detail-panel/index.js +67 -83
- package/lib/documents/index.js +6 -8
- package/lib/example/index.js +10 -12
- package/lib/filter/checkBox.js +33 -45
- package/lib/filter/customize.js +3 -4
- package/lib/filter/index.d.ts +1 -0
- package/lib/filter/index.js +88 -112
- package/lib/filter/radioBox.js +23 -31
- package/lib/filter/rangePicker.js +43 -59
- package/lib/form/addable-section/index.d.ts +19 -0
- package/lib/form/addable-section/index.js +232 -0
- package/lib/form/addable-section/style/index.d.ts +1 -0
- package/lib/form/addable-section/style/index.js +3 -0
- package/lib/form/addable-section/style/index.less +22 -0
- package/lib/form/divider/index.js +7 -1
- package/lib/form/element/index.js +60 -48
- package/lib/form/element/style/index.less +9 -0
- package/lib/form/elements.js +1 -1
- package/lib/form/index.js +16 -17
- package/lib/form/login/index.js +16 -21
- package/lib/form/page/index.js +19 -25
- package/lib/form/page/style/index.less +1 -1
- package/lib/form/pages/index.js +24 -33
- package/lib/form/pages/style/index.less +3 -1
- package/lib/form/render/index.js +2 -2
- package/lib/form/section/index.js +15 -18
- package/lib/form/step/index.js +32 -43
- package/lib/form/steps/index.js +9 -12
- package/lib/{form/context.d.ts → form-context.d.ts} +1 -0
- package/lib/{form/context.js → form-context.js} +0 -0
- package/lib/free-form/addable-section/index.d.ts +18 -0
- package/lib/free-form/addable-section/index.js +306 -0
- package/lib/free-form/addable-section/style/index.d.ts +1 -0
- package/lib/free-form/addable-section/style/index.js +3 -0
- package/lib/free-form/addable-section/style/index.less +22 -0
- package/lib/free-form/element/index.js +44 -42
- package/lib/free-form/element/style/index.less +12 -2
- package/lib/free-form/index.d.ts +5 -1
- package/lib/free-form/index.js +17 -17
- package/lib/free-form/page/index.js +37 -47
- package/lib/free-form/page/style/index.less +3 -1
- package/lib/free-form/pages/index.js +8 -10
- package/lib/free-form/section/index.js +21 -23
- package/lib/free-form/section/style/index.less +4 -0
- package/lib/free-form/step/index.js +38 -48
- package/lib/free-form/steps/index.js +9 -11
- package/lib/global-message/index.js +1 -1
- package/lib/home-menu/index.js +52 -71
- package/lib/index.d.ts +1 -0
- package/lib/index.js +141 -132
- package/lib/input/amount.js +10 -5
- package/lib/input/credit-card.js +7 -1
- package/lib/input/email.js +7 -1
- package/lib/input/expiry-date.js +14 -18
- package/lib/input/index.js +18 -18
- package/lib/input/input-date.js +12 -16
- package/lib/input/input-number.js +8 -2
- package/lib/input/input.js +8 -2
- package/lib/input/otp.js +17 -15
- package/lib/input/password.js +11 -6
- package/lib/input/phone-number.js +6 -8
- package/lib/input/style/index.less +9 -1
- package/lib/input/text-area.js +14 -10
- package/lib/layout/defaultFooter.js +60 -82
- package/lib/layout/defaultHeader.js +11 -15
- package/lib/layout/footer.js +108 -148
- package/lib/layout/header.js +51 -60
- package/lib/layout/index.js +15 -12
- package/lib/locale/en-US/messages.json +2 -0
- package/lib/locale/format-message.js +1 -1
- package/lib/locale/id-ID/messages.json +2 -0
- package/lib/locale/index.js +4 -4
- package/lib/locale/locale-provider.js +9 -11
- package/lib/locale/th-TH/messages.json +2 -0
- package/lib/locale/vi-VN/messages.json +2 -0
- package/lib/locale/zh-CN/messages.json +2 -0
- package/lib/login-page/index.js +30 -42
- package/lib/media/index.js +20 -27
- package/lib/media/media.js +9 -12
- package/lib/media/preview.js +8 -10
- package/lib/mobile-insurer-detail/index.js +74 -91
- package/lib/mobile-insurer-list/index.js +34 -38
- package/lib/modal/index.d.ts +4 -3
- package/lib/modal/index.js +25 -27
- package/lib/modal/style/index.less +24 -5
- package/lib/platform/platform-card/index.js +9 -12
- package/lib/platform/switch-platform/index.js +24 -32
- package/lib/policy-list/index.js +11 -14
- package/lib/policy-list/policy-card.js +119 -153
- package/lib/radio/index.js +33 -35
- package/lib/select/attached-select.js +32 -35
- package/lib/select/select.js +13 -9
- package/lib/select/style/index.less +1 -1
- package/lib/select/time-select.js +12 -16
- package/lib/status-box/index.js +8 -10
- package/lib/table/index.js +72 -96
- package/lib/tabs/index.js +8 -2
- package/lib/types.d.ts +4 -2
- package/lib/typography/index.js +6 -8
- package/lib/upload/index.d.ts +2 -1
- package/lib/upload/index.js +170 -143
- package/lib/upload-photo/index.d.ts +2 -1
- package/lib/upload-photo/index.js +171 -142
- package/lib/upload-photo/media.js +3 -4
- package/lib/upload-preview/index.js +9 -12
- package/lib/upload-preview/media.js +12 -16
- package/lib/utils/form-utils.js +49 -37
- package/package.json +1 -1
- package/es/free-form/context.d.ts +0 -19
- package/es/free-form/context.js +0 -7
- package/lib/free-form/context.d.ts +0 -19
- package/lib/free-form/context.js +0 -19
package/lib/input/expiry-date.js
CHANGED
|
@@ -25,9 +25,9 @@ require("./style/index");
|
|
|
25
25
|
|
|
26
26
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
27
27
|
|
|
28
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
28
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
29
29
|
|
|
30
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
30
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
31
31
|
|
|
32
32
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
33
33
|
|
|
@@ -186,7 +186,7 @@ var IglooExpiryDate = function IglooExpiryDate(props) {
|
|
|
186
186
|
setInput(_objectSpread({}, refArr));
|
|
187
187
|
}
|
|
188
188
|
|
|
189
|
-
return (0, _jsxRuntime.jsx)("div",
|
|
189
|
+
return (0, _jsxRuntime.jsx)("div", {
|
|
190
190
|
className: (0, _classnames.default)('igloo-input-date-picker', {
|
|
191
191
|
'igloo-input-disable': disabled
|
|
192
192
|
}, "".concat(active ? 'igloo-input-date-picker-focus' : '')),
|
|
@@ -195,14 +195,12 @@ var IglooExpiryDate = function IglooExpiryDate(props) {
|
|
|
195
195
|
},
|
|
196
196
|
onBlur: function onBlur() {
|
|
197
197
|
return setActive(false);
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
children: (0, _jsxRuntime.jsx)(_space.default, Object.assign({
|
|
198
|
+
},
|
|
199
|
+
children: (0, _jsxRuntime.jsx)(_space.default, {
|
|
201
200
|
style: {
|
|
202
201
|
cursor: 'default'
|
|
203
202
|
},
|
|
204
|
-
size: 12
|
|
205
|
-
}, {
|
|
203
|
+
size: 12,
|
|
206
204
|
children: timeInputArr.map(function (item, index) {
|
|
207
205
|
var islast = index === timeInputArr.length - 1;
|
|
208
206
|
var ref = null;
|
|
@@ -236,12 +234,11 @@ var IglooExpiryDate = function IglooExpiryDate(props) {
|
|
|
236
234
|
},
|
|
237
235
|
disabled: disabled,
|
|
238
236
|
type: "number"
|
|
239
|
-
}, item) : (0, _jsxRuntime.jsxs)(_space.default,
|
|
237
|
+
}, item) : (0, _jsxRuntime.jsxs)(_space.default, {
|
|
240
238
|
style: {
|
|
241
239
|
cursor: 'default'
|
|
242
240
|
},
|
|
243
|
-
size: 12
|
|
244
|
-
}, {
|
|
241
|
+
size: 12,
|
|
245
242
|
children: [(0, _jsxRuntime.jsx)(_input.default, {
|
|
246
243
|
className: "igloo-input-date-picker-input",
|
|
247
244
|
placeholder: item,
|
|
@@ -260,17 +257,16 @@ var IglooExpiryDate = function IglooExpiryDate(props) {
|
|
|
260
257
|
},
|
|
261
258
|
disabled: disabled,
|
|
262
259
|
type: "number"
|
|
263
|
-
}, item), (0, _jsxRuntime.jsx)("span",
|
|
260
|
+
}, item), (0, _jsxRuntime.jsx)("span", {
|
|
264
261
|
style: {
|
|
265
262
|
color: '#999999'
|
|
266
|
-
}
|
|
267
|
-
}, {
|
|
263
|
+
},
|
|
268
264
|
children: delimiter
|
|
269
|
-
}
|
|
270
|
-
}
|
|
265
|
+
}, void 0)]
|
|
266
|
+
}, item);
|
|
271
267
|
})
|
|
272
|
-
}
|
|
273
|
-
}
|
|
268
|
+
}, void 0)
|
|
269
|
+
}, void 0);
|
|
274
270
|
};
|
|
275
271
|
|
|
276
272
|
function checkTime(value, check) {
|
package/lib/input/index.js
CHANGED
|
@@ -3,16 +3,16 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
Object.defineProperty(exports, "
|
|
6
|
+
Object.defineProperty(exports, "Amount", {
|
|
7
7
|
enumerable: true,
|
|
8
8
|
get: function get() {
|
|
9
|
-
return
|
|
9
|
+
return _amount.default;
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
|
-
Object.defineProperty(exports, "
|
|
12
|
+
Object.defineProperty(exports, "CreditCard", {
|
|
13
13
|
enumerable: true,
|
|
14
14
|
get: function get() {
|
|
15
|
-
return
|
|
15
|
+
return _creditCard.default;
|
|
16
16
|
}
|
|
17
17
|
});
|
|
18
18
|
Object.defineProperty(exports, "Email", {
|
|
@@ -21,46 +21,46 @@ Object.defineProperty(exports, "Email", {
|
|
|
21
21
|
return _email.default;
|
|
22
22
|
}
|
|
23
23
|
});
|
|
24
|
-
Object.defineProperty(exports, "
|
|
24
|
+
Object.defineProperty(exports, "ExpiryDate", {
|
|
25
25
|
enumerable: true,
|
|
26
26
|
get: function get() {
|
|
27
|
-
return
|
|
27
|
+
return _expiryDate.default;
|
|
28
28
|
}
|
|
29
29
|
});
|
|
30
|
-
Object.defineProperty(exports, "
|
|
30
|
+
Object.defineProperty(exports, "InputDate", {
|
|
31
31
|
enumerable: true,
|
|
32
32
|
get: function get() {
|
|
33
|
-
return
|
|
33
|
+
return _inputDate.default;
|
|
34
34
|
}
|
|
35
35
|
});
|
|
36
|
-
Object.defineProperty(exports, "
|
|
36
|
+
Object.defineProperty(exports, "InputNumber", {
|
|
37
37
|
enumerable: true,
|
|
38
38
|
get: function get() {
|
|
39
|
-
return
|
|
39
|
+
return _inputNumber.default;
|
|
40
40
|
}
|
|
41
41
|
});
|
|
42
|
-
Object.defineProperty(exports, "
|
|
42
|
+
Object.defineProperty(exports, "Otp", {
|
|
43
43
|
enumerable: true,
|
|
44
44
|
get: function get() {
|
|
45
|
-
return
|
|
45
|
+
return _otp.default;
|
|
46
46
|
}
|
|
47
47
|
});
|
|
48
|
-
Object.defineProperty(exports, "
|
|
48
|
+
Object.defineProperty(exports, "Password", {
|
|
49
49
|
enumerable: true,
|
|
50
50
|
get: function get() {
|
|
51
|
-
return
|
|
51
|
+
return _password.default;
|
|
52
52
|
}
|
|
53
53
|
});
|
|
54
|
-
Object.defineProperty(exports, "
|
|
54
|
+
Object.defineProperty(exports, "PhoneNumber", {
|
|
55
55
|
enumerable: true,
|
|
56
56
|
get: function get() {
|
|
57
|
-
return
|
|
57
|
+
return _phoneNumber.default;
|
|
58
58
|
}
|
|
59
59
|
});
|
|
60
|
-
Object.defineProperty(exports, "
|
|
60
|
+
Object.defineProperty(exports, "TextArea", {
|
|
61
61
|
enumerable: true,
|
|
62
62
|
get: function get() {
|
|
63
|
-
return
|
|
63
|
+
return _textArea.default;
|
|
64
64
|
}
|
|
65
65
|
});
|
|
66
66
|
exports.default = void 0;
|
package/lib/input/input-date.js
CHANGED
|
@@ -193,7 +193,7 @@ var IglooInputDate = function IglooInputDate(props) {
|
|
|
193
193
|
setInput(_toConsumableArray(refArr));
|
|
194
194
|
}
|
|
195
195
|
|
|
196
|
-
return (0, _jsxRuntime.jsx)("div",
|
|
196
|
+
return (0, _jsxRuntime.jsx)("div", {
|
|
197
197
|
className: (0, _classnames.default)('igloo-input-date-picker', {
|
|
198
198
|
'igloo-input-disable': disabled
|
|
199
199
|
}, "".concat(active ? 'igloo-input-date-picker-focus' : '')),
|
|
@@ -202,14 +202,12 @@ var IglooInputDate = function IglooInputDate(props) {
|
|
|
202
202
|
},
|
|
203
203
|
onBlur: function onBlur() {
|
|
204
204
|
return setActive(false);
|
|
205
|
-
}
|
|
206
|
-
|
|
207
|
-
children: (0, _jsxRuntime.jsx)(_space.default, Object.assign({
|
|
205
|
+
},
|
|
206
|
+
children: (0, _jsxRuntime.jsx)(_space.default, {
|
|
208
207
|
style: {
|
|
209
208
|
cursor: 'default'
|
|
210
209
|
},
|
|
211
|
-
size: 12
|
|
212
|
-
}, {
|
|
210
|
+
size: 12,
|
|
213
211
|
children: timeInputArr.map(function (item, index) {
|
|
214
212
|
var islast = index === timeInputArr.length - 1;
|
|
215
213
|
var ref = null;
|
|
@@ -247,12 +245,11 @@ var IglooInputDate = function IglooInputDate(props) {
|
|
|
247
245
|
},
|
|
248
246
|
disabled: disabled,
|
|
249
247
|
type: "number"
|
|
250
|
-
}, item) : (0, _jsxRuntime.jsxs)(_space.default,
|
|
248
|
+
}, item) : (0, _jsxRuntime.jsxs)(_space.default, {
|
|
251
249
|
style: {
|
|
252
250
|
cursor: 'default'
|
|
253
251
|
},
|
|
254
|
-
size: 12
|
|
255
|
-
}, {
|
|
252
|
+
size: 12,
|
|
256
253
|
children: [(0, _jsxRuntime.jsx)(_input.default, {
|
|
257
254
|
className: "igloo-input-date-picker-input",
|
|
258
255
|
placeholder: item,
|
|
@@ -271,17 +268,16 @@ var IglooInputDate = function IglooInputDate(props) {
|
|
|
271
268
|
},
|
|
272
269
|
disabled: disabled,
|
|
273
270
|
type: "number"
|
|
274
|
-
}, item), (0, _jsxRuntime.jsx)("span",
|
|
271
|
+
}, item), (0, _jsxRuntime.jsx)("span", {
|
|
275
272
|
style: {
|
|
276
273
|
color: '#999999'
|
|
277
|
-
}
|
|
278
|
-
}, {
|
|
274
|
+
},
|
|
279
275
|
children: delimiter
|
|
280
|
-
}
|
|
281
|
-
}
|
|
276
|
+
}, void 0)]
|
|
277
|
+
}, item);
|
|
282
278
|
})
|
|
283
|
-
}
|
|
284
|
-
}
|
|
279
|
+
}, void 0)
|
|
280
|
+
}, void 0);
|
|
285
281
|
};
|
|
286
282
|
|
|
287
283
|
function checkTime(value, format) {
|
|
@@ -19,6 +19,12 @@ require("./style/index.less");
|
|
|
19
19
|
|
|
20
20
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
21
21
|
|
|
22
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
23
|
+
|
|
24
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
25
|
+
|
|
26
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
27
|
+
|
|
22
28
|
var IglooInputNumber = function IglooInputNumber(props) {
|
|
23
29
|
var handleOnBlur = function handleOnBlur(e) {
|
|
24
30
|
var value = props.value,
|
|
@@ -30,9 +36,9 @@ var IglooInputNumber = function IglooInputNumber(props) {
|
|
|
30
36
|
}
|
|
31
37
|
};
|
|
32
38
|
|
|
33
|
-
return (0, _jsxRuntime.jsx)(_input.default,
|
|
39
|
+
return (0, _jsxRuntime.jsx)(_input.default, _objectSpread(_objectSpread({
|
|
34
40
|
className: "igloo-input"
|
|
35
|
-
}, (0, _omit.default)(props, _formMethods.default), {
|
|
41
|
+
}, (0, _omit.default)(props, _formMethods.default)), {}, {
|
|
36
42
|
onBlur: handleOnBlur,
|
|
37
43
|
type: "number"
|
|
38
44
|
}), void 0);
|
package/lib/input/input.js
CHANGED
|
@@ -21,10 +21,16 @@ require("./style/index.less");
|
|
|
21
21
|
|
|
22
22
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
23
23
|
|
|
24
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
25
|
+
|
|
26
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
27
|
+
|
|
28
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
29
|
+
|
|
24
30
|
var IglooInput = /*#__PURE__*/(0, _react.forwardRef)(function (props, ref) {
|
|
25
|
-
return (0, _jsxRuntime.jsx)(_input.default,
|
|
31
|
+
return (0, _jsxRuntime.jsx)(_input.default, _objectSpread(_objectSpread({
|
|
26
32
|
className: "igloo-input"
|
|
27
|
-
}, (0, _omit.default)(props, _formMethods.default), {
|
|
33
|
+
}, (0, _omit.default)(props, _formMethods.default)), {}, {
|
|
28
34
|
ref: ref
|
|
29
35
|
}), void 0);
|
|
30
36
|
});
|
package/lib/input/otp.js
CHANGED
|
@@ -33,6 +33,12 @@ var _excluded = ["className", "dependField", "countDownSeconds", "sendOtp", "fir
|
|
|
33
33
|
|
|
34
34
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
35
35
|
|
|
36
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
37
|
+
|
|
38
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
39
|
+
|
|
40
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
41
|
+
|
|
36
42
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
37
43
|
|
|
38
44
|
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
@@ -120,28 +126,24 @@ var Otp = function Otp(_ref) {
|
|
|
120
126
|
setFirst(false);
|
|
121
127
|
};
|
|
122
128
|
|
|
123
|
-
return (0, _jsxRuntime.jsxs)("div",
|
|
124
|
-
className: "igloo-otp"
|
|
125
|
-
|
|
126
|
-
children: [!countDown && (0, _jsxRuntime.jsx)(_button.default, Object.assign({
|
|
129
|
+
return (0, _jsxRuntime.jsxs)("div", {
|
|
130
|
+
className: "igloo-otp",
|
|
131
|
+
children: [!countDown && (0, _jsxRuntime.jsx)(_button.default, {
|
|
127
132
|
type: "link",
|
|
128
133
|
className: "igloo-otp-extra",
|
|
129
134
|
disabled: !dependValue,
|
|
130
135
|
onClick: send,
|
|
131
|
-
id: fireBaseId
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
level: "h4"
|
|
135
|
-
}, {
|
|
136
|
+
id: fireBaseId,
|
|
137
|
+
children: (0, _jsxRuntime.jsx)(_typography.default, {
|
|
138
|
+
level: "h4",
|
|
136
139
|
children: first ? formatMessage({
|
|
137
140
|
id: 'Send OTP'
|
|
138
141
|
}) : formatMessage({
|
|
139
142
|
id: 'Resend OTP'
|
|
140
143
|
})
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
className: "igloo-otp-extra igloo-otp-count-down"
|
|
144
|
-
}, {
|
|
144
|
+
}, void 0)
|
|
145
|
+
}, void 0), countDown && (0, _jsxRuntime.jsxs)("div", {
|
|
146
|
+
className: "igloo-otp-extra igloo-otp-count-down",
|
|
145
147
|
children: [formatMessage({
|
|
146
148
|
id: 'Resend in'
|
|
147
149
|
}), " (", (0, _jsxRuntime.jsx)(_statistic.default.Countdown, {
|
|
@@ -150,10 +152,10 @@ var Otp = function Otp(_ref) {
|
|
|
150
152
|
format: "s",
|
|
151
153
|
onFinish: reset
|
|
152
154
|
}, void 0), "s)"]
|
|
153
|
-
}
|
|
155
|
+
}, void 0), (0, _jsxRuntime.jsx)(_input.default, _objectSpread(_objectSpread({}, (0, _omit.default)(props, _formMethods.default)), {}, {
|
|
154
156
|
className: (0, _classnames.default)(className)
|
|
155
157
|
}), void 0)]
|
|
156
|
-
}
|
|
158
|
+
}, void 0);
|
|
157
159
|
};
|
|
158
160
|
|
|
159
161
|
Otp.formItemPropsHandler = function (config) {
|
package/lib/input/password.js
CHANGED
|
@@ -19,25 +19,30 @@ var _iglooicon = require("iglooicon");
|
|
|
19
19
|
|
|
20
20
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
21
21
|
|
|
22
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
23
|
+
|
|
24
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
25
|
+
|
|
26
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
27
|
+
|
|
22
28
|
var Password = _input.default.Password;
|
|
23
29
|
|
|
24
30
|
var IglooPassword = function IglooPassword(props) {
|
|
25
|
-
return (0, _jsxRuntime.jsx)(Password,
|
|
31
|
+
return (0, _jsxRuntime.jsx)(Password, _objectSpread(_objectSpread({
|
|
26
32
|
className: "igloo-input"
|
|
27
|
-
}, (0, _omit.default)(props, _formMethods.default), {
|
|
33
|
+
}, (0, _omit.default)(props, _formMethods.default)), {}, {
|
|
28
34
|
iconRender: function iconRender(visible) {
|
|
29
35
|
return visible ? (0, _jsxRuntime.jsx)(_iglooicon.ShowOutlined, {
|
|
30
36
|
style: {
|
|
31
37
|
fontSize: 22,
|
|
32
38
|
color: '#666666'
|
|
33
39
|
}
|
|
34
|
-
}, void 0) : (0, _jsxRuntime.jsx)("span",
|
|
40
|
+
}, void 0) : (0, _jsxRuntime.jsx)("span", {
|
|
35
41
|
onClickCapture: function onClickCapture(e) {
|
|
36
42
|
if (!props.value) {
|
|
37
43
|
e.stopPropagation();
|
|
38
44
|
}
|
|
39
|
-
}
|
|
40
|
-
}, {
|
|
45
|
+
},
|
|
41
46
|
children: (0, _jsxRuntime.jsx)(_iglooicon.HideOutlined, {
|
|
42
47
|
style: {
|
|
43
48
|
fontSize: 22,
|
|
@@ -45,7 +50,7 @@ var IglooPassword = function IglooPassword(props) {
|
|
|
45
50
|
cursor: props.value ? 'pointer' : 'not-allowed'
|
|
46
51
|
}
|
|
47
52
|
}, void 0)
|
|
48
|
-
}
|
|
53
|
+
}, void 0);
|
|
49
54
|
}
|
|
50
55
|
}), void 0);
|
|
51
56
|
};
|
|
@@ -83,17 +83,15 @@ var PhoneNumber = function PhoneNumber(_ref) {
|
|
|
83
83
|
value: area
|
|
84
84
|
};
|
|
85
85
|
})
|
|
86
|
-
}, void 0) : (0, _jsxRuntime.jsx)("div",
|
|
87
|
-
className: "igloo-phone-number-addon-before"
|
|
88
|
-
}, {
|
|
86
|
+
}, void 0) : (0, _jsxRuntime.jsx)("div", {
|
|
87
|
+
className: "igloo-phone-number-addon-before",
|
|
89
88
|
children: areaCode
|
|
90
|
-
}
|
|
91
|
-
return (0, _jsxRuntime.jsxs)("div",
|
|
89
|
+
}, void 0);
|
|
90
|
+
return (0, _jsxRuntime.jsxs)("div", {
|
|
92
91
|
style: style,
|
|
93
92
|
className: (0, _classnames.default)('igloo-input-phone', {
|
|
94
93
|
'igloo-input-phone-disabled': disabled
|
|
95
|
-
}, className)
|
|
96
|
-
}, {
|
|
94
|
+
}, className),
|
|
97
95
|
children: [leftPart, (0, _jsxRuntime.jsx)(_input.default, {
|
|
98
96
|
type: "tel",
|
|
99
97
|
defaultValue: number,
|
|
@@ -106,7 +104,7 @@ var PhoneNumber = function PhoneNumber(_ref) {
|
|
|
106
104
|
},
|
|
107
105
|
disabled: disabled
|
|
108
106
|
}, void 0)]
|
|
109
|
-
}
|
|
107
|
+
}, void 0);
|
|
110
108
|
};
|
|
111
109
|
|
|
112
110
|
PhoneNumber.formItemPropsHandler = function (_ref2) {
|
|
@@ -9,7 +9,7 @@ input[type='number'] {
|
|
|
9
9
|
line-height: 24px;
|
|
10
10
|
width: 100%;
|
|
11
11
|
height: 48px;
|
|
12
|
-
border-color: #bdbdbd
|
|
12
|
+
border-color: #bdbdbd;
|
|
13
13
|
padding: 12px 16px;
|
|
14
14
|
color: #212121;
|
|
15
15
|
|
|
@@ -337,6 +337,14 @@ input[type='number'] {
|
|
|
337
337
|
|
|
338
338
|
.ant-input:not(.ant-input-disabled) {
|
|
339
339
|
border-color: #bdbdbd;
|
|
340
|
+
|
|
341
|
+
&:hover {
|
|
342
|
+
border-color: @primary-color;
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
&:active {
|
|
346
|
+
border-color: @active-color;
|
|
347
|
+
}
|
|
340
348
|
}
|
|
341
349
|
|
|
342
350
|
.igloo-otp-extra {
|
package/lib/input/text-area.js
CHANGED
|
@@ -33,6 +33,12 @@ function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symb
|
|
|
33
33
|
|
|
34
34
|
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
35
35
|
|
|
36
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
37
|
+
|
|
38
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
39
|
+
|
|
40
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
41
|
+
|
|
36
42
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
37
43
|
|
|
38
44
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
@@ -87,21 +93,19 @@ var IglooTextArea = function IglooTextArea(props) {
|
|
|
87
93
|
}
|
|
88
94
|
|
|
89
95
|
var canInputNum = maxLength ? maxLength - inputValue.length : 1;
|
|
90
|
-
return (0, _jsxRuntime.jsxs)("div",
|
|
91
|
-
className: (0, _classnames.default)("".concat(canInputNum < 0 ? 'igloo-input-text-area-error' : ''), 'igloo-input-text-area')
|
|
92
|
-
|
|
93
|
-
children: [(0, _jsxRuntime.jsx)(_input.default.TextArea, Object.assign({
|
|
96
|
+
return (0, _jsxRuntime.jsxs)("div", {
|
|
97
|
+
className: (0, _classnames.default)("".concat(canInputNum < 0 ? 'igloo-input-text-area-error' : ''), 'igloo-input-text-area'),
|
|
98
|
+
children: [(0, _jsxRuntime.jsx)(_input.default.TextArea, _objectSpread(_objectSpread({
|
|
94
99
|
className: (0, _classnames.default)('igloo-input'),
|
|
95
100
|
rows: 3
|
|
96
|
-
}, (0, _omit.default)(props, [].concat(_toConsumableArray(_formMethods.default), ['maxLength'])), {
|
|
101
|
+
}, (0, _omit.default)(props, [].concat(_toConsumableArray(_formMethods.default), ['maxLength']))), {}, {
|
|
97
102
|
onChange: function onChange(e) {
|
|
98
103
|
return handleOnChange(e, onChangeProps, maxLength);
|
|
99
104
|
}
|
|
100
105
|
}), void 0), (0, _jsxRuntime.jsx)("div", {
|
|
101
106
|
className: "igloo-input-text-area-right-bottom-cover"
|
|
102
|
-
}, void 0), showLeft && (0, _jsxRuntime.jsx)("div",
|
|
103
|
-
className: "".concat(canInputNum < 0 ? 'igloo-input-text-area-remind-has-error' : 'igloo-input-text-area-remind')
|
|
104
|
-
}, {
|
|
107
|
+
}, void 0), showLeft && (0, _jsxRuntime.jsx)("div", {
|
|
108
|
+
className: "".concat(canInputNum < 0 ? 'igloo-input-text-area-remind-has-error' : 'igloo-input-text-area-remind'),
|
|
105
109
|
children: canInputNum < 0 ? formatMessage({
|
|
106
110
|
id: '{canInputNum} characters over',
|
|
107
111
|
values: {
|
|
@@ -113,8 +117,8 @@ var IglooTextArea = function IglooTextArea(props) {
|
|
|
113
117
|
canInputNum: canInputNum
|
|
114
118
|
}
|
|
115
119
|
})
|
|
116
|
-
}
|
|
117
|
-
}
|
|
120
|
+
}, void 0)]
|
|
121
|
+
}, void 0);
|
|
118
122
|
};
|
|
119
123
|
|
|
120
124
|
function checkNumber(value, maxLength, required) {
|