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

ObjectField does not react to value change events from components in layouts #387

Closed
vaadin-miki opened this issue Sep 8, 2022 · 3 comments · Fixed by #389
Closed

ObjectField does not react to value change events from components in layouts #387

vaadin-miki opened this issue Sep 8, 2022 · 3 comments · Fixed by #389
Assignees
Labels
bug Something isn't working

Comments

@vaadin-miki
Copy link
Owner

When a component is added directly to a layout in CollectionField, value change events are triggered properly.

When such a component is inside a layout, no event happens.

Discovered during #380, might be only reproducable within that context.

@vaadin-miki vaadin-miki added the bug Something isn't working label Sep 8, 2022
@vaadin-miki vaadin-miki added this to the Next release milestone Sep 8, 2022
@vaadin-miki vaadin-miki self-assigned this Sep 8, 2022
@vaadin-miki
Copy link
Owner Author

After some investigation it turned out to be an issue with ObjectField not listening to changes.

@vaadin-miki vaadin-miki changed the title CollectionField does not forward value change events from components in layouts ObjectField does not react to value change events from components in layouts Sep 8, 2022
@vaadin-miki
Copy link
Owner Author

to be even more specific, it is ObjectField not properly broadcasting events

@vaadin-miki
Copy link
Owner Author

turns out that ObjectFieldFactory was reusing an instance of the object instead of creating a new one

vaadin-miki added a commit that referenced this issue Sep 9, 2022
added test to make sure it does not happen again
vaadin-miki added a commit that referenced this issue Sep 9, 2022
#387 fixed

created ObjectFieldFactory to help with common use cases for ObjectField
vaadin-miki added a commit that referenced this issue Sep 9, 2022
#382 #380 #387 #390 #391 #386 #388 #395 #396 done

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: vaadin-miki <vaadin-miki@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant