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/es/select/select.js
CHANGED
|
@@ -2,6 +2,12 @@ import "antd/es/select/style";
|
|
|
2
2
|
import _Select from "antd/es/select";
|
|
3
3
|
var _excluded = ["options", "value", "className", "placeholder", "children", "onDropdownVisibleChange", "showSearch", "filterOption", "optionFilterProp"];
|
|
4
4
|
|
|
5
|
+
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; }
|
|
6
|
+
|
|
7
|
+
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; }
|
|
8
|
+
|
|
9
|
+
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; }
|
|
10
|
+
|
|
5
11
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
6
12
|
|
|
7
13
|
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."); }
|
|
@@ -50,18 +56,17 @@ var IglooSelect = function IglooSelect(_ref) {
|
|
|
50
56
|
var _useContext = useContext(LocaleContext),
|
|
51
57
|
formatMessage = _useContext.formatMessage;
|
|
52
58
|
|
|
53
|
-
return _jsx(_Select,
|
|
59
|
+
return _jsx(_Select, _objectSpread(_objectSpread({
|
|
54
60
|
placeholder: placeholder || formatMessage({
|
|
55
61
|
id: 'Please select'
|
|
56
62
|
})
|
|
57
|
-
}, omit(rest, formMethods), {
|
|
63
|
+
}, omit(rest, formMethods)), {}, {
|
|
58
64
|
options: children ? void 0 : options,
|
|
59
65
|
value: value,
|
|
60
|
-
suffixIcon: _jsxs("div",
|
|
66
|
+
suffixIcon: _jsxs("div", {
|
|
61
67
|
style: {
|
|
62
68
|
position: 'relative'
|
|
63
|
-
}
|
|
64
|
-
}, {
|
|
69
|
+
},
|
|
65
70
|
children: [_jsx(ArrowDownOutlined, {
|
|
66
71
|
className: classnames({
|
|
67
72
|
'igloo-select-arrow': true,
|
|
@@ -79,7 +84,7 @@ var IglooSelect = function IglooSelect(_ref) {
|
|
|
79
84
|
opacity: isOpen ? 1 : 0
|
|
80
85
|
}
|
|
81
86
|
}, void 0)]
|
|
82
|
-
}
|
|
87
|
+
}, void 0),
|
|
83
88
|
getPopupContainer: function getPopupContainer(trigger) {
|
|
84
89
|
return trigger.parentNode;
|
|
85
90
|
},
|
|
@@ -94,8 +99,7 @@ var IglooSelect = function IglooSelect(_ref) {
|
|
|
94
99
|
|
|
95
100
|
return Boolean(option === null || option === void 0 ? void 0 : (_option$label = option.label) === null || _option$label === void 0 ? void 0 : (_option$label$toStrin = _option$label.toString()) === null || _option$label$toStrin === void 0 ? void 0 : _option$label$toStrin.includes(value));
|
|
96
101
|
} : void 0),
|
|
97
|
-
mode: undefined
|
|
98
|
-
}, {
|
|
102
|
+
mode: undefined,
|
|
99
103
|
children: children
|
|
100
104
|
}), void 0);
|
|
101
105
|
};
|
package/es/select/time-select.js
CHANGED
|
@@ -191,12 +191,11 @@ var IglooTimeSelect = function IglooTimeSelect(props) {
|
|
|
191
191
|
|
|
192
192
|
var menu = _jsx(_Menu, {
|
|
193
193
|
children: _jsx(_Menu.Item, {
|
|
194
|
-
children: _jsxs("div",
|
|
194
|
+
children: _jsxs("div", {
|
|
195
195
|
onClick: function onClick(e) {
|
|
196
196
|
return e.stopPropagation();
|
|
197
197
|
},
|
|
198
|
-
className: "igloo-drop-down-content"
|
|
199
|
-
}, {
|
|
198
|
+
className: "igloo-drop-down-content",
|
|
200
199
|
children: [_jsxs("div", {
|
|
201
200
|
children: [_jsx(ArrowUpOutlined, {
|
|
202
201
|
onClick: function onClick() {
|
|
@@ -238,11 +237,10 @@ var IglooTimeSelect = function IglooTimeSelect(props) {
|
|
|
238
237
|
return meridiemSwitch(hourValue);
|
|
239
238
|
}
|
|
240
239
|
}, void 0), _jsx("span", {
|
|
241
|
-
children: _jsx(Typography,
|
|
242
|
-
level: "body1"
|
|
243
|
-
}, {
|
|
240
|
+
children: _jsx(Typography, {
|
|
241
|
+
level: "body1",
|
|
244
242
|
children: meridiem ? 'AM' : 'PM'
|
|
245
|
-
}
|
|
243
|
+
}, void 0)
|
|
246
244
|
}, void 0), _jsx(ArrowDownOutlined, {
|
|
247
245
|
className: classnames({// 'igloo-hour-select-meridiem-disable': meridiemDisable,
|
|
248
246
|
}),
|
|
@@ -251,15 +249,14 @@ var IglooTimeSelect = function IglooTimeSelect(props) {
|
|
|
251
249
|
}
|
|
252
250
|
}, void 0)]
|
|
253
251
|
}, void 0)]
|
|
254
|
-
}
|
|
252
|
+
}, void 0)
|
|
255
253
|
}, '0')
|
|
256
254
|
}, void 0);
|
|
257
255
|
|
|
258
|
-
return _jsxs("div",
|
|
256
|
+
return _jsxs("div", {
|
|
259
257
|
className: "igloo-hour-select",
|
|
260
|
-
ref: topDomRef
|
|
261
|
-
|
|
262
|
-
children: [_jsx(_Dropdown, Object.assign({
|
|
258
|
+
ref: topDomRef,
|
|
259
|
+
children: [_jsx(_Dropdown, {
|
|
263
260
|
onVisibleChange: function onVisibleChange(open) {
|
|
264
261
|
return setDropDownVisible(open);
|
|
265
262
|
},
|
|
@@ -269,20 +266,19 @@ var IglooTimeSelect = function IglooTimeSelect(props) {
|
|
|
269
266
|
getPopupContainer: function getPopupContainer() {
|
|
270
267
|
return topDomRef.current;
|
|
271
268
|
},
|
|
272
|
-
disabled: disabled
|
|
273
|
-
}, {
|
|
269
|
+
disabled: disabled,
|
|
274
270
|
children: _jsx(Input, {
|
|
275
271
|
value: finalDisplayValue,
|
|
276
272
|
className: classnames('igloo-input', {
|
|
277
273
|
'igloo-hour-select-input-active': dropDownVisible
|
|
278
274
|
})
|
|
279
275
|
}, void 0)
|
|
280
|
-
}
|
|
276
|
+
}, void 0), _jsx(TimeOutlined, {
|
|
281
277
|
className: classnames({
|
|
282
278
|
'igloo-hour-select-active': dropDownVisible
|
|
283
279
|
})
|
|
284
280
|
}, void 0)]
|
|
285
|
-
}
|
|
281
|
+
}, void 0);
|
|
286
282
|
};
|
|
287
283
|
|
|
288
284
|
function checkCard(value) {
|
package/es/status-box/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
1
|
+
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; }
|
|
2
2
|
|
|
3
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
3
|
+
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; }
|
|
4
4
|
|
|
5
5
|
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; }
|
|
6
6
|
|
|
@@ -16,19 +16,17 @@ var IglooStatusBox = function IglooStatusBox(props) {
|
|
|
16
16
|
background = props.background,
|
|
17
17
|
className = props.className,
|
|
18
18
|
style = props.style;
|
|
19
|
-
return _jsx("span",
|
|
19
|
+
return _jsx("span", {
|
|
20
20
|
className: classnames("iglooform-status-box-".concat(type), 'iglooform-status-box-container', className),
|
|
21
21
|
style: _objectSpread({
|
|
22
22
|
color: color,
|
|
23
23
|
backgroundColor: background
|
|
24
|
-
}, style)
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
level: "status"
|
|
28
|
-
}, {
|
|
24
|
+
}, style),
|
|
25
|
+
children: _jsx(Typography, {
|
|
26
|
+
level: "status",
|
|
29
27
|
children: children
|
|
30
|
-
}
|
|
31
|
-
}
|
|
28
|
+
}, void 0)
|
|
29
|
+
}, void 0);
|
|
32
30
|
};
|
|
33
31
|
|
|
34
32
|
export default IglooStatusBox;
|
package/es/table/index.js
CHANGED
|
@@ -32,13 +32,13 @@ function _objectWithoutProperties(source, excluded) { if (source == null) return
|
|
|
32
32
|
|
|
33
33
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
34
34
|
|
|
35
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
35
|
+
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; }
|
|
36
36
|
|
|
37
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
37
|
+
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; }
|
|
38
38
|
|
|
39
39
|
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; }
|
|
40
40
|
|
|
41
|
-
function _typeof(obj) { "@babel/helpers - typeof";
|
|
41
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
42
42
|
|
|
43
43
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
44
44
|
import React from 'react';
|
|
@@ -73,15 +73,14 @@ var filterDefaultShow = function filterDefaultShow(col) {
|
|
|
73
73
|
|
|
74
74
|
var getDropDownMenu = function getDropDownMenu(allButtons, rowData, actionButtonsFilter, setActionListVisible, actionIndex) {
|
|
75
75
|
var actionButtons = actionButtonsFilter && typeof actionButtonsFilter === 'function' ? actionButtonsFilter(rowData, allButtons) : allButtons;
|
|
76
|
-
return _jsx(_Space,
|
|
76
|
+
return _jsx(_Space, {
|
|
77
77
|
size: 16,
|
|
78
78
|
style: {
|
|
79
79
|
padding: '4px 8px'
|
|
80
80
|
},
|
|
81
|
-
direction: "vertical"
|
|
82
|
-
}, {
|
|
81
|
+
direction: "vertical",
|
|
83
82
|
children: actionButtons.map(function (item, index) {
|
|
84
|
-
return _jsx(Button,
|
|
83
|
+
return _jsx(Button, {
|
|
85
84
|
type: "text",
|
|
86
85
|
onClick: function onClick(e) {
|
|
87
86
|
item.onClick(rowData);
|
|
@@ -89,16 +88,14 @@ var getDropDownMenu = function getDropDownMenu(allButtons, rowData, actionButton
|
|
|
89
88
|
type: actionIndex,
|
|
90
89
|
value: false
|
|
91
90
|
});
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
level: "body1"
|
|
96
|
-
}, {
|
|
91
|
+
},
|
|
92
|
+
children: _jsx(Typography, {
|
|
93
|
+
level: "body1",
|
|
97
94
|
children: item.text
|
|
98
|
-
}
|
|
99
|
-
}
|
|
95
|
+
}, void 0)
|
|
96
|
+
}, index);
|
|
100
97
|
})
|
|
101
|
-
}
|
|
98
|
+
}, actionIndex);
|
|
102
99
|
};
|
|
103
100
|
|
|
104
101
|
function handleFilterDisable() {
|
|
@@ -162,11 +159,10 @@ function paginationItem(page, type, originalElement) {
|
|
|
162
159
|
}, void 0);
|
|
163
160
|
}
|
|
164
161
|
|
|
165
|
-
return _jsx("span",
|
|
166
|
-
className: "ant-btn-link"
|
|
167
|
-
}, {
|
|
162
|
+
return _jsx("span", {
|
|
163
|
+
className: "ant-btn-link",
|
|
168
164
|
children: originalElement
|
|
169
|
-
}
|
|
165
|
+
}, void 0);
|
|
170
166
|
}
|
|
171
167
|
|
|
172
168
|
function actionListChange(state, action) {
|
|
@@ -262,27 +258,24 @@ var IglooTable = function IglooTable(_ref) {
|
|
|
262
258
|
});
|
|
263
259
|
|
|
264
260
|
var modalContent = function modalContent(options, defaultOptions, selectCallBack, colMax, colDisable) {
|
|
265
|
-
return _jsx(_Checkbox.Group,
|
|
261
|
+
return _jsx(_Checkbox.Group, {
|
|
266
262
|
defaultValue: defaultOptions,
|
|
267
|
-
onChange: selectCallBack
|
|
268
|
-
}, {
|
|
263
|
+
onChange: selectCallBack,
|
|
269
264
|
children: options.filter(function (item) {
|
|
270
265
|
return item.customize;
|
|
271
266
|
}).map(function (item) {
|
|
272
267
|
return _jsx("div", {
|
|
273
|
-
children: _jsx(_Checkbox,
|
|
268
|
+
children: _jsx(_Checkbox, {
|
|
274
269
|
value: item.key,
|
|
275
|
-
disabled: colDisable && colMax ? defaultOptions.length >= colMax && !defaultOptions.includes(item.key) : false
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
level: "body1"
|
|
279
|
-
}, {
|
|
270
|
+
disabled: colDisable && colMax ? defaultOptions.length >= colMax && !defaultOptions.includes(item.key) : false,
|
|
271
|
+
children: _jsx(Typography, {
|
|
272
|
+
level: "body1",
|
|
280
273
|
children: item.title
|
|
281
|
-
}
|
|
282
|
-
}
|
|
274
|
+
}, void 0)
|
|
275
|
+
}, void 0)
|
|
283
276
|
}, item.key);
|
|
284
277
|
})
|
|
285
|
-
}
|
|
278
|
+
}, void 0);
|
|
286
279
|
};
|
|
287
280
|
|
|
288
281
|
var actionCol = {
|
|
@@ -294,7 +287,7 @@ var IglooTable = function IglooTable(_ref) {
|
|
|
294
287
|
key: 'action',
|
|
295
288
|
align: 'center',
|
|
296
289
|
render: function render(text, record, index) {
|
|
297
|
-
return _jsx(_Popover,
|
|
290
|
+
return _jsx(_Popover, {
|
|
298
291
|
visible: actionListVisible[index] || false,
|
|
299
292
|
onVisibleChange: function onVisibleChange(visible) {
|
|
300
293
|
setActionListVisible({
|
|
@@ -309,8 +302,7 @@ var IglooTable = function IglooTable(_ref) {
|
|
|
309
302
|
},
|
|
310
303
|
trigger: ['click'],
|
|
311
304
|
title: null,
|
|
312
|
-
arrowPointAtCenter: true
|
|
313
|
-
}, {
|
|
305
|
+
arrowPointAtCenter: true,
|
|
314
306
|
children: _jsx(DotMenuOutlined, {
|
|
315
307
|
style: {
|
|
316
308
|
fontSize: '24px',
|
|
@@ -321,59 +313,52 @@ var IglooTable = function IglooTable(_ref) {
|
|
|
321
313
|
},
|
|
322
314
|
className: "igloo-table-action-icon"
|
|
323
315
|
}, void 0)
|
|
324
|
-
}
|
|
316
|
+
}, void 0);
|
|
325
317
|
}
|
|
326
318
|
};
|
|
327
|
-
return _jsxs("div",
|
|
319
|
+
return _jsxs("div", {
|
|
328
320
|
className: "igloo-table-container",
|
|
329
321
|
ref: tableRef,
|
|
330
|
-
style: style
|
|
331
|
-
|
|
332
|
-
children: [(hasFilterOptions || !noCustomize || extraButtons && extraButtons.length !== 0) && _jsxs(_Row, Object.assign({
|
|
322
|
+
style: style,
|
|
323
|
+
children: [(hasFilterOptions || !noCustomize || extraButtons && extraButtons.length !== 0) && _jsxs(_Row, {
|
|
333
324
|
justify: "space-between",
|
|
334
325
|
gutter: [0, 24],
|
|
335
|
-
className: "igloo-table-top-content"
|
|
336
|
-
|
|
337
|
-
children: [hasFilterOptions ? _jsx(Filter, Object.assign({}, filterConfig, {
|
|
326
|
+
className: "igloo-table-top-content",
|
|
327
|
+
children: [hasFilterOptions ? _jsx(Filter, _objectSpread(_objectSpread({}, filterConfig), {}, {
|
|
338
328
|
parentFilterCallBack: setFilterOptions
|
|
339
329
|
}), void 0) : _jsx(_Col, {
|
|
340
330
|
span: 8
|
|
341
331
|
}, void 0), _jsx(_Col, {
|
|
342
|
-
children: _jsxs(_Space,
|
|
343
|
-
className: 'igloo-table-button-cantainer'
|
|
344
|
-
|
|
345
|
-
children: [!noCustomize && _jsx(Button, Object.assign({
|
|
332
|
+
children: _jsxs(_Space, {
|
|
333
|
+
className: 'igloo-table-button-cantainer',
|
|
334
|
+
children: [!noCustomize && _jsx(Button, {
|
|
346
335
|
icon: _jsx(SettingOutlined, {}, void 0),
|
|
347
336
|
onClick: function onClick() {
|
|
348
337
|
return setModalVisible(true);
|
|
349
|
-
}
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
level: "h4"
|
|
353
|
-
}, {
|
|
338
|
+
},
|
|
339
|
+
children: _jsx(Typography, {
|
|
340
|
+
level: "h4",
|
|
354
341
|
children: formatMessage({
|
|
355
342
|
id: 'Customize Columns'
|
|
356
343
|
})
|
|
357
|
-
}
|
|
358
|
-
}
|
|
344
|
+
}, void 0)
|
|
345
|
+
}, void 0), extraButtons && extraButtons.map(function (item, index) {
|
|
359
346
|
return item.render ? /*#__PURE__*/React.cloneElement(item.render(), {
|
|
360
347
|
key: index
|
|
361
|
-
}) : _jsx(Button,
|
|
348
|
+
}) : _jsx(Button, {
|
|
362
349
|
icon: item.icon,
|
|
363
350
|
onClick: function onClick() {
|
|
364
351
|
return item.onClick && item.onClick(filterOptions);
|
|
365
|
-
}
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
level: "h4"
|
|
369
|
-
}, {
|
|
352
|
+
},
|
|
353
|
+
children: _jsx(Typography, {
|
|
354
|
+
level: "h4",
|
|
370
355
|
children: item.text
|
|
371
|
-
}
|
|
372
|
-
}
|
|
356
|
+
}, void 0)
|
|
357
|
+
}, index);
|
|
373
358
|
})]
|
|
374
|
-
}
|
|
359
|
+
}, void 0)
|
|
375
360
|
}, void 0)]
|
|
376
|
-
}
|
|
361
|
+
}, void 0), _jsx(_Table, _objectSpread({
|
|
377
362
|
className: "".concat(className || ''),
|
|
378
363
|
rowClassName: function rowClassName(record, index, indent) {
|
|
379
364
|
if (typeof _rowClassName === 'function') {
|
|
@@ -415,12 +400,11 @@ var IglooTable = function IglooTable(_ref) {
|
|
|
415
400
|
id: 'Click to cancel sorting'
|
|
416
401
|
})
|
|
417
402
|
}, locale)
|
|
418
|
-
}, rest), void 0), bottomExtra, !noPagination && _jsx(_Row,
|
|
403
|
+
}, rest), void 0), bottomExtra, !noPagination && _jsx(_Row, {
|
|
419
404
|
justify: "end",
|
|
420
405
|
style: {
|
|
421
406
|
marginTop: 24
|
|
422
|
-
}
|
|
423
|
-
}, {
|
|
407
|
+
},
|
|
424
408
|
children: _jsx(_Pagination, {
|
|
425
409
|
itemRender: paginationItem,
|
|
426
410
|
size: "small",
|
|
@@ -430,12 +414,11 @@ var IglooTable = function IglooTable(_ref) {
|
|
|
430
414
|
showSizeChanger: false,
|
|
431
415
|
showTotal: function showTotal(total, range) {
|
|
432
416
|
return _jsxs(_Space, {
|
|
433
|
-
children: [_jsx(Typography,
|
|
417
|
+
children: [_jsx(Typography, {
|
|
434
418
|
level: "body1",
|
|
435
419
|
style: {
|
|
436
420
|
color: '#666666'
|
|
437
|
-
}
|
|
438
|
-
}, {
|
|
421
|
+
},
|
|
439
422
|
children: formatMessage({
|
|
440
423
|
id: '{beginIndex}-{endIndex} of {total}',
|
|
441
424
|
values: {
|
|
@@ -444,16 +427,15 @@ var IglooTable = function IglooTable(_ref) {
|
|
|
444
427
|
total: total
|
|
445
428
|
}
|
|
446
429
|
})
|
|
447
|
-
}
|
|
430
|
+
}, void 0), ' ', _jsx(Typography, {
|
|
448
431
|
level: "body1",
|
|
449
432
|
style: {
|
|
450
433
|
color: '#666666'
|
|
451
|
-
}
|
|
452
|
-
}, {
|
|
434
|
+
},
|
|
453
435
|
children: formatMessage({
|
|
454
436
|
id: 'Rows per page'
|
|
455
437
|
})
|
|
456
|
-
}
|
|
438
|
+
}, void 0), ' ', _jsx(_Select, {
|
|
457
439
|
value: pageSize,
|
|
458
440
|
suffixIcon: _jsx(ArrowDownOutlined, {
|
|
459
441
|
style: {
|
|
@@ -475,18 +457,17 @@ var IglooTable = function IglooTable(_ref) {
|
|
|
475
457
|
},
|
|
476
458
|
onChange: onPagination
|
|
477
459
|
}, void 0)
|
|
478
|
-
}
|
|
460
|
+
}, void 0), !noCustomize && _jsxs(Modal, {
|
|
479
461
|
width: 430,
|
|
480
462
|
closable: true,
|
|
481
463
|
destroyOnClose: true,
|
|
482
464
|
visible: modalVisible,
|
|
483
|
-
title: _jsx(Typography,
|
|
484
|
-
level: "h4"
|
|
485
|
-
}, {
|
|
465
|
+
title: _jsx(Typography, {
|
|
466
|
+
level: "h4",
|
|
486
467
|
children: formatMessage({
|
|
487
468
|
id: 'Customize Columns'
|
|
488
469
|
})
|
|
489
|
-
}
|
|
470
|
+
}, void 0),
|
|
490
471
|
cancelButtonProps: {
|
|
491
472
|
type: 'link',
|
|
492
473
|
onClick: function onClick() {
|
|
@@ -505,36 +486,31 @@ var IglooTable = function IglooTable(_ref) {
|
|
|
505
486
|
setModalVisible(false);
|
|
506
487
|
setSelectedColKeys(modalSelectedCol);
|
|
507
488
|
},
|
|
508
|
-
okText: _jsx(Typography,
|
|
509
|
-
level: "h4"
|
|
510
|
-
}, {
|
|
489
|
+
okText: _jsx(Typography, {
|
|
490
|
+
level: "h4",
|
|
511
491
|
children: formatMessage({
|
|
512
492
|
id: 'Apply Columns'
|
|
513
493
|
})
|
|
514
|
-
}
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
children: _jsx(Typography, Object.assign({
|
|
520
|
-
level: "body1"
|
|
521
|
-
}, {
|
|
494
|
+
}, void 0),
|
|
495
|
+
children: [_jsx("div", {
|
|
496
|
+
className: 'modal-describe',
|
|
497
|
+
children: _jsx(Typography, {
|
|
498
|
+
level: "body1",
|
|
522
499
|
children: colMax === null ? '' : formatMessage({
|
|
523
500
|
id: 'It is recommended to select no more than {colMax} metrics to ensure the default visibility of each column input.',
|
|
524
501
|
values: {
|
|
525
502
|
colMax: colMax
|
|
526
503
|
}
|
|
527
504
|
})
|
|
528
|
-
}
|
|
529
|
-
}
|
|
530
|
-
level: "body1"
|
|
531
|
-
}, {
|
|
505
|
+
}, void 0)
|
|
506
|
+
}, void 0), _jsx(Typography, {
|
|
507
|
+
level: "body1",
|
|
532
508
|
children: modalContent(columns, modalSelectedCol, function (item) {
|
|
533
509
|
setModalSelectedCol(item);
|
|
534
510
|
}, colMax, colDisable)
|
|
535
|
-
}
|
|
536
|
-
}
|
|
537
|
-
}
|
|
511
|
+
}, void 0)]
|
|
512
|
+
}, void 0)]
|
|
513
|
+
}, void 0);
|
|
538
514
|
};
|
|
539
515
|
|
|
540
516
|
export default IglooTable;
|
package/es/tabs/index.js
CHANGED
|
@@ -2,6 +2,12 @@ import "antd/es/tabs/style";
|
|
|
2
2
|
import _Tabs from "antd/es/tabs";
|
|
3
3
|
var _excluded = ["className"];
|
|
4
4
|
|
|
5
|
+
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; }
|
|
6
|
+
|
|
7
|
+
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; }
|
|
8
|
+
|
|
9
|
+
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; }
|
|
10
|
+
|
|
5
11
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
6
12
|
|
|
7
13
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
@@ -19,7 +25,7 @@ export default function Tabs(props) {
|
|
|
19
25
|
className = _props$className === void 0 ? '' : _props$className,
|
|
20
26
|
restProps = _objectWithoutProperties(props, _excluded);
|
|
21
27
|
|
|
22
|
-
return _jsx(_Tabs,
|
|
28
|
+
return _jsx(_Tabs, _objectSpread({
|
|
23
29
|
className: "container ".concat(className)
|
|
24
30
|
}, restProps), void 0);
|
|
25
31
|
}
|
package/es/types.d.ts
CHANGED
|
@@ -24,11 +24,12 @@ export interface FormBasicConfig {
|
|
|
24
24
|
showSubmitButton?: boolean;
|
|
25
25
|
getScrollContainer?: () => HTMLElement | null;
|
|
26
26
|
onFirstModified?: () => any;
|
|
27
|
+
uploadApi?: string;
|
|
27
28
|
}
|
|
28
29
|
export declare type FormItemAssert = {
|
|
29
30
|
field: NamePath;
|
|
30
|
-
value
|
|
31
|
-
operation?: 'eq' | 'ne' | 'in' | 'ni' | 'lt' | 'le' | 'gt' | 'ge' | 'co' | 'nc';
|
|
31
|
+
value?: any;
|
|
32
|
+
operation?: 'eq' | 'ne' | 'in' | 'ni' | 'lt' | 'le' | 'gt' | 'ge' | 'co' | 'nc' | 'filled';
|
|
32
33
|
};
|
|
33
34
|
export declare type FormItemCopyValue = {
|
|
34
35
|
assert: FormItemAssert;
|
|
@@ -43,6 +44,7 @@ export declare type FormItemSelectValue = {
|
|
|
43
44
|
export interface FormItemExtraConfig extends FormItemProps {
|
|
44
45
|
elements?: FormItemConfig[];
|
|
45
46
|
required?: boolean;
|
|
47
|
+
requiredAsserts?: FormItemAssert[];
|
|
46
48
|
extraLabel?: any;
|
|
47
49
|
xl?: number;
|
|
48
50
|
md?: number;
|
package/es/typography/index.js
CHANGED
|
@@ -23,24 +23,22 @@ var IglooTypography = function IglooTypography(_ref) {
|
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
if (wrapElement === 'div') {
|
|
26
|
-
return _jsx("div",
|
|
26
|
+
return _jsx("div", {
|
|
27
27
|
className: classNames(classNameObj, 'word-wrap', className),
|
|
28
28
|
style: style,
|
|
29
29
|
title: title,
|
|
30
|
-
onClick: onClick
|
|
31
|
-
}, {
|
|
30
|
+
onClick: onClick,
|
|
32
31
|
children: children
|
|
33
|
-
}
|
|
32
|
+
}, void 0);
|
|
34
33
|
}
|
|
35
34
|
|
|
36
|
-
return _jsx("span",
|
|
35
|
+
return _jsx("span", {
|
|
37
36
|
className: classNames(classNameObj, 'word-wrap', className),
|
|
38
37
|
style: style,
|
|
39
38
|
title: title,
|
|
40
|
-
onClick: onClick
|
|
41
|
-
}, {
|
|
39
|
+
onClick: onClick,
|
|
42
40
|
children: children
|
|
43
|
-
}
|
|
41
|
+
}, void 0);
|
|
44
42
|
};
|
|
45
43
|
|
|
46
44
|
export default IglooTypography;
|
package/es/upload/index.d.ts
CHANGED
|
@@ -3,13 +3,14 @@ import { FC, IglooComponentProps } from '../types';
|
|
|
3
3
|
import './style/index.less';
|
|
4
4
|
export interface IglooUploadProps extends UploadProps, IglooComponentProps {
|
|
5
5
|
placeholder?: string;
|
|
6
|
-
handleUpload(file: RcFile): PromiseLike<string>;
|
|
6
|
+
handleUpload?(file: RcFile): PromiseLike<string>;
|
|
7
7
|
value?: string[];
|
|
8
8
|
onChange?: (value: any) => void;
|
|
9
9
|
limit?: number;
|
|
10
10
|
limitErrorMessage?: Function | string;
|
|
11
11
|
containerRef?: any;
|
|
12
12
|
descriptions?: any;
|
|
13
|
+
bizKey?: string;
|
|
13
14
|
}
|
|
14
15
|
declare const IglooUpload: FC<IglooUploadProps>;
|
|
15
16
|
export default IglooUpload;
|