Closed Bug 1966073 Opened 1 year ago Closed 2 months ago

Enable Close Watcher by default

Categories

(Core :: DOM: Core & HTML, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
149 Branch
Tracking Status
relnote-firefox --- 149+
firefox149 --- fixed

People

(Reporter: keithamus, Assigned: keithamus)

References

(Blocks 1 open bug)

Details

(Keywords: dev-doc-complete)

Attachments

(1 file)

No description provided.

Once enabled, this needs to be documented at https://developer.mozilla.org/en-US/docs/Web/API/CloseWatcher and the related browser compat data plus the release notes on MDN.

And Keith, maybe you can also request this to be added to the Firefox release notes.

Sebastian

Keywords: dev-doc-needed
Duplicate of this bug: 1951665
Status: ASSIGNED → RESOLVED
Closed: 2 months ago
Resolution: --- → FIXED
Target Milestone: --- → 149 Branch

Release Note Request (optional, but appreciated)
[Why is this notable]: Support for the CloseWatcher interface, and its integration with dialogs & popovers
[Affects Firefox for Android]: Yes (also with some android specific behavior)
[Suggested wording]: Add support for closing popovers & dialogs with the Android 'Back Button', and implement the CloseWatcher API for handling this in script.
[Links (documentation, blog post, etc)]: https://developer.mozilla.org/en-US/docs/Web/API/CloseWatcher

(Please improve my wording, it's not great).

relnote-firefox: --- → ?
Regressions: 2017858
Type: task → enhancement

(In reply to Keith Cirkel [:keithamus] from comment #6)

Release Note Request (optional, but appreciated)
[Why is this notable]: Support for the CloseWatcher interface, and its integration with dialogs & popovers
[Affects Firefox for Android]: Yes (also with some android specific behavior)
[Suggested wording]: Add support for closing popovers & dialogs with the Android 'Back Button', and implement the CloseWatcher API for handling this in script.
[Links (documentation, blog post, etc)]: https://developer.mozilla.org/en-US/docs/Web/API/CloseWatcher

(Please improve my wording, it's not great).

Is that an Android-only improvement?

Flags: needinfo?(mozilla)

CloseWatcher is exposed to all platforms, and mitigates abusive strategies for multiple dialogs/popovers (effectively, pressing Escape twice will force these to close). Developers can use the CloseWatcher interface to also tie into this behaviour.

The Android specific behaviour is that the back button now consumes a CloseWatcher (the equivalent of the Escape key). This means the back button will now close Dialogs/Popovers on first click.

So it's an improvement on all platforms, with specific features for Android.

Flags: needinfo?(mozilla)
Depends on: 2017903
No longer depends on: 2017903
Regressions: 2017903

Note added to 149 nightly release notes with this wording:

Added support for closing popovers & dialogs with the Android Back Button, and implement the CloseWatcher API for handling this in script.

I am keeping the relnote-firefox? flag set until we include this note in our final 149 release notes, thanks.

No longer duplicate of this bug: 1951665

FF149 MDN docs work for this can be tracked in https://github.com/mdn/content/issues/43220 .
Comatibility data already updated and docs look OK, so mostly just release note.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: