react-jsonschema-form icon indicating copy to clipboard operation
react-jsonschema-form copied to clipboard

Form component's focusOnFirstError throws an error with additionalProperties schema and dot idSchema

Open jroebu14 opened this issue 1 year ago • 0 comments

Prerequisites

What theme are you using?

core

Version

5.18.5

Current Behavior

Form component's focusOnFirstError throws an error with additionalProperties schema and dot idSchema e.g.

Failed to execute 'querySelector' on 'Element': 'input[id^=root.title' is not a valid selector.

Expected Behavior

Should not throw an error and scroll to the first invalid input.

Steps To Reproduce

  1. Go to https://wrqx2n.csb.app/
  2. Click on the plus icon to add a new item
  3. Click submit without adding a value
  4. Observe the error thrown Failed to execute 'querySelector' on 'Element': 'input[id^=root.title' is not a valid selector.

Environment

- OS: macOS 14.5
- Node: 20.11.0
- npm: 10.2.4

Anything else?

No response

jroebu14 avatar Aug 20 '24 13:08 jroebu14