oa-componentbook 1.0.1-stage.85 → 1.0.1-stage.87
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.
|
@@ -54,7 +54,7 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
|
|
|
54
54
|
* @property {string} ['data-test'] Data test string to be applied to the outermost element.
|
|
55
55
|
*/
|
|
56
56
|
function ApprovalWidget(_ref) {
|
|
57
|
-
var _approvalForm$disable2, _actionContent$label, _approvalForm$disable3, _approvalForm$disable4, _approvalForm$disable5, _approvalForm$remarks, _approvalForm$disable6, _approvalForm$disable7, _approvalForm$disable8, _approvalForm$disable9, _approvalForm$disable10
|
|
57
|
+
var _approvalForm$disable2, _actionContent$label, _approvalForm$disable3, _approvalForm$disable4, _approvalForm$disable5, _approvalForm$remarks, _approvalForm$disable6, _approvalForm$disable7, _approvalForm$disable8, _approvalForm$disable9, _approvalForm$disable10;
|
|
58
58
|
let {
|
|
59
59
|
children,
|
|
60
60
|
description,
|
|
@@ -177,7 +177,7 @@ function ApprovalWidget(_ref) {
|
|
|
177
177
|
}, columnItems.map(item => /*#__PURE__*/_react.default.createElement("li", {
|
|
178
178
|
key: item.title,
|
|
179
179
|
className: "tooltip-item"
|
|
180
|
-
}, /*#__PURE__*/_react.default.createElement(_MaterialIcon.default, {
|
|
180
|
+
}, !item.hideIcon && /*#__PURE__*/_react.default.createElement(_MaterialIcon.default, {
|
|
181
181
|
size: 20,
|
|
182
182
|
icon: item.type === "positive" ? _Check.default : _Close.default,
|
|
183
183
|
color: item.type === "positive" ? "positive" : "negative"
|
|
@@ -283,18 +283,15 @@ function ApprovalWidget(_ref) {
|
|
|
283
283
|
"data-test": dataTest ? "".concat(dataTest, "--remarks") : undefined,
|
|
284
284
|
disabled: (_approvalForm$disable10 = approvalForm === null || approvalForm === void 0 ? void 0 : approvalForm.disabled) !== null && _approvalForm$disable10 !== void 0 ? _approvalForm$disable10 : false
|
|
285
285
|
}))))), actionRenderType === "buttonWithFormV4" && /*#__PURE__*/_react.default.createElement(_antd.Form.Item, {
|
|
286
|
-
name: "validateDocumentButton#".concat(questionId)
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
rules: [{
|
|
286
|
+
name: "validateDocumentButton#".concat(questionId),
|
|
287
|
+
initialValue: isApproved,
|
|
288
|
+
rules: isMandatory ? [{
|
|
290
289
|
required: true,
|
|
291
290
|
message: dataTest ? /*#__PURE__*/_react.default.createElement("span", {
|
|
292
291
|
"data-test": "".concat(dataTest, "--is-approved-validation-message")
|
|
293
292
|
}, "Approval status needs to be selected.") : "Approval status needs to be selected."
|
|
294
|
-
}]
|
|
295
|
-
}, /*#__PURE__*/_react.default.createElement(_CustomButton.default,
|
|
296
|
-
disabled: (_approvalForm$disable11 = approvalForm === null || approvalForm === void 0 ? void 0 : approvalForm.disabled) !== null && _approvalForm$disable11 !== void 0 ? _approvalForm$disable11 : false
|
|
297
|
-
}))))), hasDivider && /*#__PURE__*/_react.default.createElement(_antd.Divider, null));
|
|
293
|
+
}] : []
|
|
294
|
+
}, /*#__PURE__*/_react.default.createElement(_CustomButton.default, actionContent)))), hasDivider && /*#__PURE__*/_react.default.createElement(_antd.Divider, null));
|
|
298
295
|
}
|
|
299
296
|
ApprovalWidget.propTypes = {
|
|
300
297
|
children: _propTypes.default.node,
|