unoplatform / uno.extensions

Libraries to ease common developer tasks associated with building multi-platform mobile, desktop and web applications using Uno Platform or WinAppSDK.
https://platform.uno/
Other
73 stars 47 forks source link

[Navigation][Documentation] Modal navigation is being dismissed on windows when alt+tab #1672

Closed dr1rrb closed 4 months ago

dr1rrb commented 1 year ago

Current behavior

If you navigate to a page using the modal navigation (!), when you alt+tab the page is being dismissed automatically on Windows.

Expected behavior

For me a "modal" nav should even prevent user to dismiss the page, the page should not close itself.

"Users must interact with the modal window before they can return to the parent window." Modal window (wikipedia)

How to reproduce it (as minimally and precisely as possible)

Navigate to a page using the ! like in this repro (from https://github.com/unoplatform/uno/issues/12871)

Environment

Nuget Package:

Package Version(s):

Affected platform(s):

Visual Studio:

Relevant plugins:

Anything else we need to know?

The fact it works on other platform that are using uno is a bug https://github.com/unoplatform/uno/issues/12928

nickrandolph commented 1 year ago

! doesn't mean modal :-) ! equates to dialog -> If you view is a page it will be rendered in a Flyout which will auto dismiss -> If you want modal change the base type of your page to ContentDialog

dr1rrb commented 1 year ago

! equates to dialog

Well IMHO dialog means "modal view with buttons at the bottom" (i.e. user should not be able to dismiss it).

Dialog controls are modal UI overlays that provide contextual app information. They block interactions with the app window until being explicitly dismissed. They often request some kind of action from the user. Dialog controls (Windows doc)

Probably just a documentation issue, but apparently users are seeing the ! as modal (cf. title of this issue https://github.com/unoplatform/uno/issues/12928)

dr1rrb commented 1 year ago

BTW, followed the doc on the MS site, found this interesting https://learn.microsoft.com/en-us/windows/apps/design/controls/dialogs-and-flyouts/

Dialogs and flyouts - Windows apps
Dialogs and flyouts display transient UI elements that appear when the user requests them or when something happens that requires notification or approval.
nickrandolph commented 1 year ago

Perhaps we should update docs - the ! means modal, not necessary dialog.

nickrandolph commented 1 year ago

cc @lukeblevins can we make the suggested updates to the docs

eriklimakc commented 1 year ago

Any action that remove focus from the application dismisses the page on Windows. See below by just resizing the window or clicking somewhere out of the app:

Windows vs. Skia.GTK

Recording 2023-10-05 120418

agneszitte commented 10 months ago

@nickrandolph / @dr1rrb / @eriklimakc (cc @lukeblevins) What is the status of this issue please? Still only missing some proper documentation or is there another issue here?