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

refactor: return reordered items and parent from event #6657

Closed

Conversation

ugur-vaadin
Copy link
Contributor

Description

This PR updates the DashboardItemReorderEndEvent to return the list of reordered items and their parent instead of the JSON array containing the node IDs of all items.

Added API:

  • List<Component> getReorderedItems(): Returns the list of the reordered item and its sibling items
  • HasWidgets getReorderedItemsParent(): Returns the parent of the reordered items

Removed API:

  • JsonArray getItems(): Returns the ordered items from the client side

Part of vaadin/platform#6626

Type of change

Refactor

Copy link

sonarcloud bot commented Sep 20, 2024

Comment on lines +67 to +68
* Returns the parent of the reordered items. Either a dashboard or a
* section.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried this locally and I'm always getting the Dashboard instance, even when reordering inside a section.

@ugur-vaadin
Copy link
Contributor Author

Closing in favour of #6660.

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

Successfully merging this pull request may close these issues.

2 participants