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

Breadcrumb not triggering a beforeLeave Event #14

Open
ghost opened this issue Oct 11, 2021 · 1 comment
Open

Breadcrumb not triggering a beforeLeave Event #14

ghost opened this issue Oct 11, 2021 · 1 comment

Comments

@ghost
Copy link

ghost commented Oct 11, 2021

The following is kown:

The BeforeLeaveEvent is triggered only when you navigate via Router, e.g. click RouterLink or call ui.navigate for navigation.
There is a remark in BeforeLeaveObserver JavaDoc
* If a route target is left for reasons not under the control of the navigator* (for instance using* {@link com.vaadin.flow.component.page.Page#setLocation(URI)}, typing a URL* into the address bar, or closing the browser), listeners are not called.

However, the navigation within the Breadcrumb is implemented using Href and Strings. Obviously, someone navigating back using the breadcrumb will loose its data without having been warned.

The implementation should be:

  • Either change in order to use the "standard" navigation object from Vaadin Flow.
  • Either extended in order to bring the possibiltiy to choose between RouterLink or simple Href.
@ghost
Copy link
Author

ghost commented Nov 22, 2021

Hi Team, any news on this one ?

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

0 participants