Skip to content

Control.id doesn't get updated properly, if multiple forms are involved #2213

@daywin94

Description

@daywin94

Describe the bug

I am using Vue2 with the with my own selection of renderers. I have v-cards with an integrated JSONForms object looking like this:
image
The jsonforms object gets updated based on the currently selected tab.

Now the problem:
Lets imagine there is a tab with 2 checkboxes in the form and another tab with 5 checkboxes. The position of the first two checkboxes inside each form are the same, because there is no other element in the schema. If I switch now between the two tabs (forms), then only the values for the checkboxes where there is a change in the position gets updated, even if all other values for the control get updated correctly.

Example:
When accessing the first tab, the controls show the correct values:
Screenshot from 2023-11-14 22-33-48

But after switching the tab and the other form is shown, the control updates the path and the other values correctly, but doesn't update the id:
Screenshot from 2023-11-14 18-00-06

After reloading the page, the DOM of course shows the correct id, but it should already show the correct value with the form change.

Expected behavior

After switching from one form to the other, the control.id value updates correctly.

Steps to reproduce the issue

  1. Create a json-form component with changable content
  2. Create schemas and uischemas with two similar controls where just the prop id is different
  3. After creating the properties, look at them in the browser and switch from one content to the other
  4. Check if the DOM shows the correct value for the control.id

Screenshots

No response

In which browser are you experiencing the issue?

Mozilla Firefox 119.0.1

Which Version of JSON Forms are you using?

3.1.0

Framework

Vue 2

RendererSet

Other (please specify in the Additional context field)

Additional context

Own renderer set but nothing changed in the control.id

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions