@json-layout/core
Advanced tools
Comparing version 0.16.1 to 0.16.2
{ | ||
"name": "@json-layout/core", | ||
"version": "0.16.1", | ||
"version": "0.16.2", | ||
"description": "Compilation and state management utilities for JSON Layout.", | ||
@@ -5,0 +5,0 @@ "type": "module", |
@@ -322,2 +322,10 @@ import { isSwitchStruct, childIsCompObject, isCompositeLayout, isFocusableLayout } from '@json-layout/vocabulary' | ||
if (activeChildTreeIndex !== -1) { | ||
context.errors = context.errors?.filter(error => { | ||
const originalError = error.params?.errors?.[0] ?? error | ||
// if an item was selected, remove the oneOf error | ||
if (originalError.schemaPath === skeleton.pointer && originalError.keyword === 'oneOf') return false | ||
// also remove the errors from other children of the oneOf | ||
if (!originalError.schemaPath.startsWith(skeleton.pointer + '/' + activeChildTreeIndex)) return false | ||
return true | ||
}) | ||
context.activeItems = produce(context.activeItems, draft => { draft[fullKey] = activeChildTreeIndex }) | ||
@@ -324,0 +332,0 @@ const activeChildKey = `${fullKey}/${activeChildTreeIndex}` |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
90493
2317