@formio/js 5.1.0-dev.6154.73887de → 5.1.0-dev.6155.76252ef
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/formio.builder.css +1 -0
- package/dist/formio.builder.min.css +1 -1
- package/dist/formio.form.css +1 -0
- package/dist/formio.form.js +8 -8
- package/dist/formio.form.min.css +1 -1
- package/dist/formio.form.min.js +1 -1
- package/dist/formio.full.css +1 -0
- package/dist/formio.full.js +10 -10
- package/dist/formio.full.min.css +1 -1
- package/dist/formio.full.min.js +1 -1
- package/dist/formio.js +4 -4
- package/dist/formio.min.js +1 -1
- package/dist/formio.utils.js +5 -5
- package/dist/formio.utils.min.js +1 -1
- package/lib/cjs/PDFBuilder.d.ts +1 -0
- package/lib/cjs/PDFBuilder.js +8 -8
- package/lib/cjs/WebformBuilder.d.ts +1 -1
- package/lib/cjs/WebformBuilder.js +36 -11
- package/lib/cjs/components/radio/Radio.d.ts +8 -0
- package/lib/cjs/components/radio/Radio.js +15 -5
- package/lib/cjs/components/select/Select.d.ts +1 -0
- package/lib/cjs/components/select/Select.js +18 -2
- package/lib/cjs/components/selectboxes/SelectBoxes.d.ts +6 -0
- package/lib/cjs/translations/en.d.ts +1 -0
- package/lib/cjs/translations/en.js +1 -1
- package/lib/cjs/utils/utils.js +10 -3
- package/lib/mjs/PDFBuilder.d.ts +1 -0
- package/lib/mjs/PDFBuilder.js +8 -8
- package/lib/mjs/WebformBuilder.d.ts +1 -1
- package/lib/mjs/WebformBuilder.js +36 -12
- package/lib/mjs/components/radio/Radio.d.ts +8 -0
- package/lib/mjs/components/radio/Radio.js +15 -5
- package/lib/mjs/components/select/Select.d.ts +1 -0
- package/lib/mjs/components/select/Select.js +18 -2
- package/lib/mjs/components/selectboxes/SelectBoxes.d.ts +6 -0
- package/lib/mjs/translations/en.d.ts +1 -0
- package/lib/mjs/translations/en.js +1 -0
- package/lib/mjs/utils/utils.js +10 -2
- package/package.json +2 -2
package/lib/mjs/utils/utils.js
CHANGED
@@ -199,7 +199,15 @@ export function checkSimpleConditional(component, condition, row, data, instance
|
|
199
199
|
return true;
|
200
200
|
}
|
201
201
|
const splittedConditionPath = conditionComponentPath.split('.');
|
202
|
-
const
|
202
|
+
const checkParentTypeInTree = (instance, componentType) => {
|
203
|
+
if (!instance?.parent) {
|
204
|
+
return false;
|
205
|
+
}
|
206
|
+
return instance?.parent.type === componentType || checkParentTypeInTree(instance.parent, componentType);
|
207
|
+
};
|
208
|
+
const conditionalPaths = checkParentTypeInTree(instance, 'datagrid') || checkParentTypeInTree(instance, 'editgrid')
|
209
|
+
? []
|
210
|
+
: getConditionalPathsRecursive(splittedConditionPath, data);
|
203
211
|
if (conditionalPaths.length > 0) {
|
204
212
|
return conditionalPaths.map((path) => {
|
205
213
|
const value = getComponentActualValue(path, data, row);
|
@@ -313,7 +321,7 @@ function getRow(component, row, instance, conditional) {
|
|
313
321
|
}
|
314
322
|
const dataParent = getDataParentComponent(instance);
|
315
323
|
if (dataParent) {
|
316
|
-
const parentPath = dataParent.paths?.
|
324
|
+
const parentPath = dataParent.paths?.localPath;
|
317
325
|
const isTriggerCondtionComponentPath = condition.when || !condition.conditions
|
318
326
|
? condition.when?.startsWith(dataParent.paths?.localPath)
|
319
327
|
: _.some(condition.conditions, cond => cond.component.startsWith(dataParent.paths?.localPath));
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@formio/js",
|
3
|
-
"version": "5.1.0-dev.
|
3
|
+
"version": "5.1.0-dev.6155.76252ef",
|
4
4
|
"description": "JavaScript powered Forms with JSON Form Builder",
|
5
5
|
"main": "lib/cjs/index.js",
|
6
6
|
"exports": {
|
@@ -81,7 +81,7 @@
|
|
81
81
|
"homepage": "https://github.com/formio/formio.js#readme",
|
82
82
|
"dependencies": {
|
83
83
|
"@formio/bootstrap": "v3.0.0-dev.121.085d187",
|
84
|
-
"@formio/core": "
|
84
|
+
"@formio/core": "v2.4.0-dev.255.7fab6ff",
|
85
85
|
"@formio/text-mask-addons": "3.8.0-formio.4",
|
86
86
|
"@formio/vanilla-text-mask": "^5.1.1-formio.1",
|
87
87
|
"abortcontroller-polyfill": "^1.7.5",
|