@data-driven-forms/ant-component-mapper 3.19.0 → 3.19.1
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/date-picker/date-picker.js +2 -1
- package/dual-list-select/dual-list-select.js +2 -1
- package/esm/date-picker/date-picker.js +2 -1
- package/esm/dual-list-select/dual-list-select.js +2 -1
- package/esm/form-group/form-group.js +6 -3
- package/esm/multiple-choice-list/multiple-choice-list.js +3 -1
- package/esm/select/select.js +2 -1
- package/esm/switch/switch.js +2 -1
- package/esm/text-field/text-field.js +2 -1
- package/esm/textarea/textarea.js +2 -1
- package/esm/time-picker/time-picker.js +2 -1
- package/form-group/form-group.js +6 -3
- package/multiple-choice-list/multiple-choice-list.js +3 -1
- package/package.json +3 -3
- package/select/select.js +2 -1
- package/switch/switch.js +2 -1
- package/text-field/text-field.js +2 -1
- package/textarea/textarea.js +2 -1
- package/time-picker/time-picker.js +2 -1
|
@@ -48,7 +48,8 @@ var DatePicker = function DatePicker(props) {
|
|
|
48
48
|
helperText: helperText,
|
|
49
49
|
description: description,
|
|
50
50
|
FormItemProps: FormItemProps,
|
|
51
|
-
isRequired: isRequired
|
|
51
|
+
isRequired: isRequired,
|
|
52
|
+
input: input
|
|
52
53
|
}, /*#__PURE__*/_react["default"].createElement(_index["default"], (0, _extends2["default"])({
|
|
53
54
|
disabled: isDisabled || isReadOnly,
|
|
54
55
|
defaultValue: input.value ? input.value : undefined,
|
|
@@ -58,7 +58,8 @@ var DualListSelect = function DualListSelect(props) {
|
|
|
58
58
|
helperText: helperText,
|
|
59
59
|
description: description,
|
|
60
60
|
FormItemProps: FormItemProps,
|
|
61
|
-
isRequired: isRequired
|
|
61
|
+
isRequired: isRequired,
|
|
62
|
+
input: input
|
|
62
63
|
}, /*#__PURE__*/_react["default"].createElement(_index["default"], (0, _extends2["default"])({}, input, {
|
|
63
64
|
targetKeys: value,
|
|
64
65
|
onChange: function onChange(targetKeys) {
|
|
@@ -31,7 +31,8 @@ var DatePicker = function DatePicker(props) {
|
|
|
31
31
|
helperText: helperText,
|
|
32
32
|
description: description,
|
|
33
33
|
FormItemProps: FormItemProps,
|
|
34
|
-
isRequired: isRequired
|
|
34
|
+
isRequired: isRequired,
|
|
35
|
+
input: input
|
|
35
36
|
}, /*#__PURE__*/React.createElement(AntDatePicker, _extends({
|
|
36
37
|
disabled: isDisabled || isReadOnly,
|
|
37
38
|
defaultValue: input.value ? input.value : undefined,
|
|
@@ -43,7 +43,8 @@ var DualListSelect = function DualListSelect(props) {
|
|
|
43
43
|
helperText: helperText,
|
|
44
44
|
description: description,
|
|
45
45
|
FormItemProps: FormItemProps,
|
|
46
|
-
isRequired: isRequired
|
|
46
|
+
isRequired: isRequired,
|
|
47
|
+
input: input
|
|
47
48
|
}, /*#__PURE__*/React.createElement(Transfer, _extends({}, input, {
|
|
48
49
|
targetKeys: value,
|
|
49
50
|
onChange: function onChange(targetKeys) {
|
|
@@ -14,7 +14,8 @@ var FormGroup = function FormGroup(_ref) {
|
|
|
14
14
|
validateOnMount = _ref.validateOnMount,
|
|
15
15
|
helperText = _ref.helperText,
|
|
16
16
|
description = _ref.description,
|
|
17
|
-
hideLabel = _ref.hideLabel
|
|
17
|
+
hideLabel = _ref.hideLabel,
|
|
18
|
+
input = _ref.input;
|
|
18
19
|
var invalid = validationError(meta, validateOnMount);
|
|
19
20
|
var warning = (meta.touched || validateOnMount) && meta.warning;
|
|
20
21
|
var help = invalid || warning || helperText || description;
|
|
@@ -22,7 +23,8 @@ var FormGroup = function FormGroup(_ref) {
|
|
|
22
23
|
validateStatus: !invalid ? warning ? 'warning' : '' : 'error',
|
|
23
24
|
help: help,
|
|
24
25
|
label: !hideLabel && label,
|
|
25
|
-
required: isRequired
|
|
26
|
+
required: isRequired,
|
|
27
|
+
name: input === null || input === void 0 ? void 0 : input.name
|
|
26
28
|
}, FormItemProps), children);
|
|
27
29
|
};
|
|
28
30
|
|
|
@@ -37,6 +39,7 @@ FormGroup.propTypes = {
|
|
|
37
39
|
validateOnMount: PropTypes.bool,
|
|
38
40
|
helperText: PropTypes.node,
|
|
39
41
|
description: PropTypes.node,
|
|
40
|
-
hideLabel: PropTypes.bool
|
|
42
|
+
hideLabel: PropTypes.bool,
|
|
43
|
+
input: PropTypes.object
|
|
41
44
|
};
|
|
42
45
|
export default FormGroup;
|
|
@@ -33,6 +33,7 @@ var Wrapper = function Wrapper(_ref2) {
|
|
|
33
33
|
isRequired = _ref2.isRequired,
|
|
34
34
|
children = _ref2.children,
|
|
35
35
|
meta = _ref2.meta,
|
|
36
|
+
input = _ref2.input,
|
|
36
37
|
validateOnMount = _ref2.validateOnMount,
|
|
37
38
|
helperText = _ref2.helperText,
|
|
38
39
|
description = _ref2.description,
|
|
@@ -44,7 +45,8 @@ var Wrapper = function Wrapper(_ref2) {
|
|
|
44
45
|
helperText: helperText,
|
|
45
46
|
description: description,
|
|
46
47
|
FormItemProps: FormItemProps,
|
|
47
|
-
isRequired: isRequired
|
|
48
|
+
isRequired: isRequired,
|
|
49
|
+
input: input
|
|
48
50
|
}, children);
|
|
49
51
|
};
|
|
50
52
|
|
package/esm/select/select.js
CHANGED
|
@@ -45,7 +45,8 @@ var Select = function Select(props) {
|
|
|
45
45
|
helperText: helperText,
|
|
46
46
|
description: description,
|
|
47
47
|
FormItemProps: FormItemProps,
|
|
48
|
-
isRequired: isRequired
|
|
48
|
+
isRequired: isRequired,
|
|
49
|
+
input: input
|
|
49
50
|
}, /*#__PURE__*/React.createElement(AntSelect, _extends({}, input, {
|
|
50
51
|
value: input.value ? input.value : undefined,
|
|
51
52
|
defaultValue: input.value ? input.value : undefined,
|
package/esm/switch/switch.js
CHANGED
|
@@ -41,7 +41,8 @@ export var Switch = function Switch(props) {
|
|
|
41
41
|
helperText: helperText,
|
|
42
42
|
description: description,
|
|
43
43
|
FormItemProps: FormItemProps,
|
|
44
|
-
isRequired: isRequired
|
|
44
|
+
isRequired: isRequired,
|
|
45
|
+
input: input
|
|
45
46
|
}, /*#__PURE__*/React.createElement(AntSwitch, _extends({}, rest, {
|
|
46
47
|
defaultValue: input.checked ? input.checked : undefined,
|
|
47
48
|
onChange: onChange,
|
|
@@ -29,7 +29,8 @@ var TextField = function TextField(props) {
|
|
|
29
29
|
helperText: helperText,
|
|
30
30
|
description: description,
|
|
31
31
|
FormItemProps: FormItemProps,
|
|
32
|
-
isRequired: isRequired
|
|
32
|
+
isRequired: isRequired,
|
|
33
|
+
input: input
|
|
33
34
|
}, /*#__PURE__*/React.createElement(Input, _extends({}, input, {
|
|
34
35
|
defaultValue: input.value ? input.value : undefined,
|
|
35
36
|
disabled: isDisabled,
|
package/esm/textarea/textarea.js
CHANGED
|
@@ -30,7 +30,8 @@ var Textarea = function Textarea(props) {
|
|
|
30
30
|
helperText: helperText,
|
|
31
31
|
description: description,
|
|
32
32
|
FormItemProps: FormItemProps,
|
|
33
|
-
isRequired: isRequired
|
|
33
|
+
isRequired: isRequired,
|
|
34
|
+
input: input
|
|
34
35
|
}, /*#__PURE__*/React.createElement(TextArea, _extends({}, input, {
|
|
35
36
|
defaultValue: input.value ? input.value : undefined,
|
|
36
37
|
disabled: isDisabled,
|
|
@@ -31,7 +31,8 @@ var TimePicker = function TimePicker(props) {
|
|
|
31
31
|
helperText: helperText,
|
|
32
32
|
description: description,
|
|
33
33
|
FormItemProps: FormItemProps,
|
|
34
|
-
isRequired: isRequired
|
|
34
|
+
isRequired: isRequired,
|
|
35
|
+
input: input
|
|
35
36
|
}, /*#__PURE__*/React.createElement(AntTimePicker, _extends({
|
|
36
37
|
use12Hours: true,
|
|
37
38
|
format: "h:mm a",
|
package/form-group/form-group.js
CHANGED
|
@@ -28,7 +28,8 @@ var FormGroup = function FormGroup(_ref) {
|
|
|
28
28
|
validateOnMount = _ref.validateOnMount,
|
|
29
29
|
helperText = _ref.helperText,
|
|
30
30
|
description = _ref.description,
|
|
31
|
-
hideLabel = _ref.hideLabel
|
|
31
|
+
hideLabel = _ref.hideLabel,
|
|
32
|
+
input = _ref.input;
|
|
32
33
|
var invalid = (0, _validationError.validationError)(meta, validateOnMount);
|
|
33
34
|
var warning = (meta.touched || validateOnMount) && meta.warning;
|
|
34
35
|
var help = invalid || warning || helperText || description;
|
|
@@ -36,7 +37,8 @@ var FormGroup = function FormGroup(_ref) {
|
|
|
36
37
|
validateStatus: !invalid ? warning ? 'warning' : '' : 'error',
|
|
37
38
|
help: help,
|
|
38
39
|
label: !hideLabel && label,
|
|
39
|
-
required: isRequired
|
|
40
|
+
required: isRequired,
|
|
41
|
+
name: input === null || input === void 0 ? void 0 : input.name
|
|
40
42
|
}, FormItemProps), children);
|
|
41
43
|
};
|
|
42
44
|
|
|
@@ -51,7 +53,8 @@ FormGroup.propTypes = {
|
|
|
51
53
|
validateOnMount: _propTypes["default"].bool,
|
|
52
54
|
helperText: _propTypes["default"].node,
|
|
53
55
|
description: _propTypes["default"].node,
|
|
54
|
-
hideLabel: _propTypes["default"].bool
|
|
56
|
+
hideLabel: _propTypes["default"].bool,
|
|
57
|
+
input: _propTypes["default"].object
|
|
55
58
|
};
|
|
56
59
|
var _default = FormGroup;
|
|
57
60
|
exports["default"] = _default;
|
|
@@ -54,6 +54,7 @@ var Wrapper = function Wrapper(_ref2) {
|
|
|
54
54
|
isRequired = _ref2.isRequired,
|
|
55
55
|
children = _ref2.children,
|
|
56
56
|
meta = _ref2.meta,
|
|
57
|
+
input = _ref2.input,
|
|
57
58
|
validateOnMount = _ref2.validateOnMount,
|
|
58
59
|
helperText = _ref2.helperText,
|
|
59
60
|
description = _ref2.description,
|
|
@@ -65,7 +66,8 @@ var Wrapper = function Wrapper(_ref2) {
|
|
|
65
66
|
helperText: helperText,
|
|
66
67
|
description: description,
|
|
67
68
|
FormItemProps: FormItemProps,
|
|
68
|
-
isRequired: isRequired
|
|
69
|
+
isRequired: isRequired,
|
|
70
|
+
input: input
|
|
69
71
|
}, children);
|
|
70
72
|
};
|
|
71
73
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@data-driven-forms/ant-component-mapper",
|
|
3
|
-
"version": "3.19.
|
|
3
|
+
"version": "3.19.1",
|
|
4
4
|
"description": "Ant Design React component mapper for Data Driven Forms.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"module": "esm/index.js",
|
|
@@ -29,13 +29,13 @@
|
|
|
29
29
|
"antd": "^4.2.0"
|
|
30
30
|
},
|
|
31
31
|
"peerDependencies": {
|
|
32
|
-
"@data-driven-forms/react-form-renderer": "^3.19.
|
|
32
|
+
"@data-driven-forms/react-form-renderer": "^3.19.1",
|
|
33
33
|
"antd": "^4.2.0",
|
|
34
34
|
"react": "^16.13.1 || ^17.0.2 || ^18.0.0",
|
|
35
35
|
"react-dom": "^16.13.1 || ^17.0.2 || ^18.0.0"
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@data-driven-forms/common": "^3.19.
|
|
38
|
+
"@data-driven-forms/common": "^3.19.1",
|
|
39
39
|
"lodash": "^4.17.21"
|
|
40
40
|
}
|
|
41
41
|
}
|
package/select/select.js
CHANGED
|
@@ -61,7 +61,8 @@ var Select = function Select(props) {
|
|
|
61
61
|
helperText: helperText,
|
|
62
62
|
description: description,
|
|
63
63
|
FormItemProps: FormItemProps,
|
|
64
|
-
isRequired: isRequired
|
|
64
|
+
isRequired: isRequired,
|
|
65
|
+
input: input
|
|
65
66
|
}, /*#__PURE__*/_react["default"].createElement(_index["default"], (0, _extends2["default"])({}, input, {
|
|
66
67
|
value: input.value ? input.value : undefined,
|
|
67
68
|
defaultValue: input.value ? input.value : undefined,
|
package/switch/switch.js
CHANGED
|
@@ -58,7 +58,8 @@ var Switch = function Switch(props) {
|
|
|
58
58
|
helperText: helperText,
|
|
59
59
|
description: description,
|
|
60
60
|
FormItemProps: FormItemProps,
|
|
61
|
-
isRequired: isRequired
|
|
61
|
+
isRequired: isRequired,
|
|
62
|
+
input: input
|
|
62
63
|
}, /*#__PURE__*/_react["default"].createElement(_index["default"], (0, _extends2["default"])({}, rest, {
|
|
63
64
|
defaultValue: input.checked ? input.checked : undefined,
|
|
64
65
|
onChange: onChange,
|
package/text-field/text-field.js
CHANGED
|
@@ -45,7 +45,8 @@ var TextField = function TextField(props) {
|
|
|
45
45
|
helperText: helperText,
|
|
46
46
|
description: description,
|
|
47
47
|
FormItemProps: FormItemProps,
|
|
48
|
-
isRequired: isRequired
|
|
48
|
+
isRequired: isRequired,
|
|
49
|
+
input: input
|
|
49
50
|
}, /*#__PURE__*/_react["default"].createElement(_index["default"], (0, _extends2["default"])({}, input, {
|
|
50
51
|
defaultValue: input.value ? input.value : undefined,
|
|
51
52
|
disabled: isDisabled,
|
package/textarea/textarea.js
CHANGED
|
@@ -46,7 +46,8 @@ var Textarea = function Textarea(props) {
|
|
|
46
46
|
helperText: helperText,
|
|
47
47
|
description: description,
|
|
48
48
|
FormItemProps: FormItemProps,
|
|
49
|
-
isRequired: isRequired
|
|
49
|
+
isRequired: isRequired,
|
|
50
|
+
input: input
|
|
50
51
|
}, /*#__PURE__*/_react["default"].createElement(TextArea, (0, _extends2["default"])({}, input, {
|
|
51
52
|
defaultValue: input.value ? input.value : undefined,
|
|
52
53
|
disabled: isDisabled,
|
|
@@ -48,7 +48,8 @@ var TimePicker = function TimePicker(props) {
|
|
|
48
48
|
helperText: helperText,
|
|
49
49
|
description: description,
|
|
50
50
|
FormItemProps: FormItemProps,
|
|
51
|
-
isRequired: isRequired
|
|
51
|
+
isRequired: isRequired,
|
|
52
|
+
input: input
|
|
52
53
|
}, /*#__PURE__*/_react["default"].createElement(_index["default"], (0, _extends2["default"])({
|
|
53
54
|
use12Hours: true,
|
|
54
55
|
format: "h:mm a",
|