@signalplus/params-about 0.1.8 → 0.1.11
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/index.d.ts +1 -0
- package/lib/es/index.js +8 -7
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -78,6 +78,7 @@ interface ParamFormProps {
|
|
|
78
78
|
parentOptions: ParentSelectorProps['parentOptions'];
|
|
79
79
|
expiriesOptions: string[];
|
|
80
80
|
initialValues?: Partial<ParamFormData>;
|
|
81
|
+
groupEditable?: boolean;
|
|
81
82
|
onChange?(data: ParamFormData): void;
|
|
82
83
|
onSubmit?(data: ParamFormData): any;
|
|
83
84
|
}
|
package/lib/es/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Bundle of @signalplus/params-about
|
|
3
|
-
* Generated: 2022-04-
|
|
4
|
-
* Version: 0.1.
|
|
3
|
+
* Generated: 2022-04-10
|
|
4
|
+
* Version: 0.1.11
|
|
5
5
|
* License: MIT
|
|
6
6
|
* Author: 2631541504@qq.com
|
|
7
7
|
*/
|
|
@@ -1364,7 +1364,8 @@ var ParamForm = /*#__PURE__*/function (_PureComponent) {
|
|
|
1364
1364
|
name: 'parentId',
|
|
1365
1365
|
Comp: function Comp(props) {
|
|
1366
1366
|
return /*#__PURE__*/React.createElement(ParentSelector, Object.assign({}, props, {
|
|
1367
|
-
parentOptions: _this2.props.parentOptions
|
|
1367
|
+
parentOptions: _this2.props.parentOptions,
|
|
1368
|
+
readonly: _this2.props.groupEditable
|
|
1368
1369
|
}));
|
|
1369
1370
|
},
|
|
1370
1371
|
required: true,
|
|
@@ -1410,11 +1411,11 @@ var ParamForm = /*#__PURE__*/function (_PureComponent) {
|
|
|
1410
1411
|
label: '默认值',
|
|
1411
1412
|
name: 'defaultValue',
|
|
1412
1413
|
Comp: function Comp(props) {
|
|
1413
|
-
var _this2$ref$current;
|
|
1414
|
+
var _this2$ref$current$ge, _this2$ref$current, _this2$props$initialV;
|
|
1414
1415
|
|
|
1415
1416
|
return /*#__PURE__*/React.createElement(ParamRenderer, Object.assign({}, props, {
|
|
1416
1417
|
expiriesOptions: _this2.props.expiriesOptions,
|
|
1417
|
-
valueType: (_this2$ref$current = _this2.ref.current) === null || _this2$ref$current === void 0 ? void 0 : _this2$ref$current.getFieldValue('valueType')
|
|
1418
|
+
valueType: (_this2$ref$current$ge = (_this2$ref$current = _this2.ref.current) === null || _this2$ref$current === void 0 ? void 0 : _this2$ref$current.getFieldValue('valueType')) !== null && _this2$ref$current$ge !== void 0 ? _this2$ref$current$ge : (_this2$props$initialV = _this2.props.initialValues) === null || _this2$props$initialV === void 0 ? void 0 : _this2$props$initialV.valueType
|
|
1418
1419
|
}));
|
|
1419
1420
|
},
|
|
1420
1421
|
validator: validatorCvt(paramValidator, function () {
|
|
@@ -2082,7 +2083,7 @@ _defineProperty(ParamGroupEditorModal, "el", new ReactGlobalComp('param-group-ed
|
|
|
2082
2083
|
|
|
2083
2084
|
function genOptions(props) {
|
|
2084
2085
|
var filter = function filter(it) {
|
|
2085
|
-
return it.valueType
|
|
2086
|
+
return it.valueType === ParamType.ParamGroup;
|
|
2086
2087
|
};
|
|
2087
2088
|
|
|
2088
2089
|
var cvt = function cvt(it) {
|
|
@@ -2094,7 +2095,7 @@ function genOptions(props) {
|
|
|
2094
2095
|
});
|
|
2095
2096
|
};
|
|
2096
2097
|
|
|
2097
|
-
return props.allParams.map(cvt) || [];
|
|
2098
|
+
return props.allParams.filter(filter).map(cvt) || [];
|
|
2098
2099
|
}
|
|
2099
2100
|
|
|
2100
2101
|
function genParamsMap(props) {
|