Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

readonly and arrays #2208

Closed
baerry opened this issue Nov 10, 2023 · 6 comments
Closed

readonly and arrays #2208

baerry opened this issue Nov 10, 2023 · 6 comments

Comments

@baerry
Copy link

baerry commented Nov 10, 2023

Describe the bug

When having a schema with an array as toplevel, and you give Jsonforms readonly, it renders all inputs on the array object readonly, which is expected, but the buttons for adding new row or removing row is still enabled, ive tried to search if its intentional, and if you can remove/disale them when the Jsonform is set to readonly without much success.

Expected behavior

Since the whole controller is set to readonly, i expect to not being able to add and remove rows from an array.

Steps to reproduce the issue

Create a schema with an array as toplevel, give it a few inputs, mock some rows with data, set the jsonforms controller to readonly, click on add / remove on a row,

Screenshots

image

clicking on add gives a new row, and since the properties are readonly on the new row, it feels like a bug? and adding a new row should be disabled?

image

In which browser are you experiencing the issue?

Google Chrome Version 119.0.6045.123 (Officiell version) (64 bit)

Which Version of JSON Forms are you using?

v3.1.0

Framework

React

RendererSet

Material

Additional context

No response

@sdirix
Copy link
Member

sdirix commented Nov 14, 2023

Hi @baerry,

Thanks for the report! We don't intend to render the modification buttons when the control is disabled.

I think the issue should already be fixed via PR #2040. Can you try the latest next version of JSON Forms, i.e. 3.2.0-alpha.3 and report whether the issue still occurs?

@baerry
Copy link
Author

baerry commented Nov 15, 2023

@sdirix

I tried it in the 3.2.0-alpha.3, and it works, thanks :) , is there any planned release date for 3.2?

@sdirix
Copy link
Member

sdirix commented Nov 15, 2023

Hi @baerry, We don't have an announced date. However we plan to release still within 2023 if nothing unexpected comes up.

@sdirix
Copy link
Member

sdirix commented Nov 28, 2023

Closing this issue now ;)

@sdirix sdirix closed this as completed Nov 28, 2023
@leixuexxxx
Copy link

Still an issue in vanilla-renderers.

@sdirix
Copy link
Member

sdirix commented Aug 19, 2024

Still an issue in vanilla-renderers.

Hi @leixuexxxx,

Feel free to open a new issue for them. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants