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

Remove the layout shift when using widgets #10

Open
danielbeeke opened this issue Sep 2, 2023 · 1 comment
Open

Remove the layout shift when using widgets #10

danielbeeke opened this issue Sep 2, 2023 · 1 comment

Comments

@danielbeeke
Copy link
Owner

One reason for layout shift is the React key that includes the term:

https://github.com/OM-MediaWorks/shacl-form/blob/master/lib/components/field/FieldWrapper.tsx#L180

Each widget should then be hard resetting values. So instead of defaultValue we should be using value and for uHTML we should use .value instead of value.

@danielbeeke
Copy link
Owner Author

I was able to do this for most things. There is still some shift happening for BlankNodeEditor.

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

No branches or pull requests

1 participant