jsonforms
jsonforms copied to clipboard
Required bubble that appears when marking an array field as required warns of two errors instead of one
Describe the bug Required bubble that appears when marking an array field as required warns of two errors instead of one.
To Reproduce
Use an empty object for data, use no uischema (autogenerated) and use the following schema object as an example:
schema: { properties: { test: { type: "array", items: { type: "object", properties: { "test1": { label: "test1", type: "string" }, "test2": { label: "test2", type: "string" }, "test3": { label: "test3", type: "string" } } } } }, required: ["test"], type: "object" }
Expected behavior I expect there to be a bubble with a single error instead of 2.
Screenshots
Browser (please complete the following information):
- Browser: Google Chrome
- Version: 88.0.4324.96 (Official Build) (x86_64)
Used Setup (please complete the following information):
- Framework: react
- RendererSet: material
Hi! Thanks for your interest in JSON Forms.
I was able to reproduce the issue on my side. This is definitely a bug! Thanks for the report!
One more info:
-
label
is not a reserved keyword in JSON Schema (and will therefore be ignored by JSON Forms). You probably want to usetitle
instead.
This seems to be related to https://github.com/eclipsesource/jsonforms/issues/1760
@LukasBoll Can you verify whether this is the same issue?
@sdirix Yes, it is the same issue and will also get fixed by this pull request.