@kontur.candy/generator 4.286.0-zeroReportingWithOptions.12 → 4.286.0-zeroReportingWithOptions.14
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/dist/index.js +8 -12
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -132052,6 +132052,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
132052
132052
|
/* harmony import */ var _markupGenerator_AllConverters__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../markupGenerator/AllConverters */ "./Generator/src/generators/markupGenerator/AllConverters.ts");
|
|
132053
132053
|
/* harmony import */ var _Common_TypingUtils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../Common/TypingUtils */ "./Common/TypingUtils.ts");
|
|
132054
132054
|
/* harmony import */ var _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../Common/ModelPath/ModelPath */ "./Common/ModelPath/ModelPath.ts");
|
|
132055
|
+
/* harmony import */ var _Common_IterableUtils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../../Common/IterableUtils */ "./Common/IterableUtils.ts");
|
|
132056
|
+
|
|
132055
132057
|
|
|
132056
132058
|
|
|
132057
132059
|
|
|
@@ -132082,19 +132084,13 @@ function getRequisitesFromEvaluablePropValue(filter) {
|
|
|
132082
132084
|
return (_filter$match$map$fil = (_filter$match = filter.match(/path([^)]+)/g)) === null || _filter$match === void 0 ? void 0 : _filter$match.map(path => path.slice(6, -1)).filter(path => path.startsWith("@clientInfo") || path.startsWith("@formsClientInfo")).map(path => `${path}.value`)) !== null && _filter$match$map$fil !== void 0 ? _filter$match$map$fil : [];
|
|
132083
132085
|
}
|
|
132084
132086
|
function getPathsFromEvaluablePropValue(evaluableProp) {
|
|
132085
|
-
const result = [];
|
|
132086
132087
|
const pathRegex = /(?<=path\((?:'|")).*?(?=(?:'|"))/g;
|
|
132087
|
-
const pathList =
|
|
132088
|
-
|
|
132089
|
-
if (pathList.length > 0) {
|
|
132090
|
-
result.push(...pathList.map(x => {
|
|
132091
|
-
var _x$;
|
|
132092
|
-
|
|
132093
|
-
return (0,_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_2__.createModelPath)((_x$ = x[0]) !== null && _x$ !== void 0 ? _x$ : (0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_1__.reject)("Path regexp parse error - unexpected undefined"), "auto");
|
|
132094
|
-
}));
|
|
132095
|
-
}
|
|
132088
|
+
const pathList = evaluableProp.matchAll(pathRegex).map(x => {
|
|
132089
|
+
var _x$;
|
|
132096
132090
|
|
|
132097
|
-
|
|
132091
|
+
return (0,_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_2__.createModelPath)((_x$ = x[0]) !== null && _x$ !== void 0 ? _x$ : (0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_1__.reject)("Path regexp parse error - unexpected undefined"), "auto");
|
|
132092
|
+
});
|
|
132093
|
+
return [..._Common_IterableUtils__WEBPACK_IMPORTED_MODULE_3__.IterUtils.distinctBy(pathList, path => path.toString())];
|
|
132098
132094
|
}
|
|
132099
132095
|
function getRequisitesFromEvaluableProps(...evaluablePropValues) {
|
|
132100
132096
|
return evaluablePropValues.filter(_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_1__.isNotNullOrUndefined).flatMap(getRequisitesFromEvaluablePropValue);
|
|
@@ -138796,8 +138792,8 @@ class SwitchConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.S
|
|
|
138796
138792
|
const conditionWithDependencies = (0,_common_ConditionUtils__WEBPACK_IMPORTED_MODULE_3__.convertConditionToJsOrFailWithFriendlySugarError)(caseNode.condition, "path", _Common_KCLangRuntimeUtils__WEBPACK_IMPORTED_MODULE_4__.KCLangRuntimeUtils.kcLangUtilsName, node, (0,_ComponentMarkupBuilder_PathHelper__WEBPACK_IMPORTED_MODULE_5__.extractPath)(x => x.condition));
|
|
138797
138793
|
const condition = conditionWithDependencies.condition;
|
|
138798
138794
|
const currentCaseCondition = prevConditions.length ? prevConditions.map(x => `!(${x})`).join(" && ") + " && " + condition : condition;
|
|
138795
|
+
prevConditions.push(condition);
|
|
138799
138796
|
const deps = this.getDepsWithResolvedPath(currentCaseCondition, evaluatorsContextPathExpression);
|
|
138800
|
-
prevConditions.push(currentCaseCondition);
|
|
138801
138797
|
validationGenerator.pushVisibilityCondition([currentCaseCondition, evaluatorsContextPathExpression, deps]);
|
|
138802
138798
|
|
|
138803
138799
|
try {
|
package/package.json
CHANGED