SchweizerischeBundesbahnen / scion-workbench

SCION Workbench enables the creation of Angular web applications that require a flexible layout to arrange content side-by-side or stacked, all personalizable by the user via drag & drop.
Eclipse Public License 2.0
80 stars 10 forks source link

CanClose invoked in wrong injection context #578

Open danielwiehl opened 3 months ago

danielwiehl commented 3 months ago

Describe the bug

The CanClose guard should be invoked in the view's injection context, enabling the injection of the MessageBoxService provided at the view level.

To Reproduce

Steps to reproduce the behavior:

  1. Implement CanClose lifecycle hook
  2. Inject MessageBoxService in canClose and open a message
  3. Expect message box to be opened view modal
  4. See that message box is opened application modal