umbraco / Umbraco-CMS

Umbraco is a free and open source .NET content management system helping you deliver delightful digital experiences.
https://umbraco.com
Other
4.49k stars 2.69k forks source link

Grid editor in overlay: selecting a row layout closes the overlay #3391

Closed skttl closed 3 years ago

skttl commented 6 years ago

If you are editing a grid property in an overlay (eg. using Doc Type Grid Editor, Stacked Content or similar), the overlay closes when you select a row configuration. It would also happen in multinode treepicker (the open to edit in a dialog function), if it used overlays in stead of dialogs.

This is originally an issue reported on Doc Type Grid Editor, but I believe it's a bug in Umbraco. https://github.com/umco/umbraco-doc-type-grid-editor/issues/95

I think this happens, because the "template" is a div. Umbraco has some code that closes the dialog on clicks outside (for some reason, it sometimes thinks elements inside the overlay is outside, that is probably the root cause), and in that code it excludes all clicks on elements of the types a, input and button.

So the simple fix is to change the template to a button, or something else. Which also benefits accessibility, as they natively have clickhandlers, you can tab to them etc....

Reproduction

Since the open function in multinode treepicker still uses the dialog service, you need to install Doc Type Grid Editor to reproduce this.

Add a grid editor containing a grid property. When editing the editor, try to add a row. The overlay closes.

nul800sebastiaan commented 5 years ago

We'll have a look at this in our next sprint (starting on Feb 18). For the time being, there's a PR for this available and it seems like updating the views would work until we can get this in a release. @hemraker maybe you can try out the fix in the PR and let us know if that works for you.

hemraker commented 5 years ago

@nul800sebastiaan thanks!

We'll test it out and report back.

azure-devops-sync[bot] commented 5 years ago

This item has been added to our backlog AB#1502

umbrabot commented 3 years ago

Hiya @skttl,

Just wanted to let you know that we noticed that this issue got a bit stale and might not be relevant any more.

We will close this issue for now but we're happy to open it up again if you think it's still relevant (for example: it's a feature request that's not yet implemented, or it's a bug that's not yet been fixed).

To open it this issue up again, you can write @umbrabot still relevant in a new comment as the first line. It would be super helpful for us if on the next line you could let us know why you think it's still relevant.

For example:

@umbrabot still relevant This bug can still be reproduced in version 8.9.0

This will reopen the issue in the next few hours.

Thanks, from your friendly Umbraco GitHub bot :robot: :slightly_smiling_face: