Intent to Ship: visualViewport.onscrollend Support

220 views
Skip to first unread message

David Awogbemila

unread,
Mar 26, 2024, 8:49:16 PMMar 26
to blink-dev

Contact emails

awogb...@google.com

Explainer

None

Specification

https://drafts.csswg.org/cssom-view/#the-visualviewport-interface

Summary

Scrollend is a JavaScript event that fires to signal that a scrolling operation has come to an end. Similar to the Element interface[1], the visualViewport interface[2] includes an onscrollend event handler that should be invoked when a scrolling operation on the visualViewport has ended. Chromium already supports adding a scrollend event listener via `visualViewport.addEventListener("scrollend")`. This just makes it possible to also add an event listener using `visualViewport.onscrollend`. [1]https://html.spec.whatwg.org/multipage/webappapis.html#handler-onscrollend [2]https://drafts.csswg.org/cssom-view/#dom-visualviewport-onscrollend.



Blink component

Blink>Scroll

TAG review

None

TAG review status

Not applicable

Risks



Interoperability and Compatibility

None



Gecko: No signal

WebKit: No signal

Web developers: No signals

Other signals:

WebView application risks

Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?

None



Debuggability

This makes it possible to add breakpoints to event handlers added by `visualViewport.onscrollend` similar to `visualViewport.onscroll` or onscrollend for any other element.



Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?

Yes

Is this feature fully tested by web-platform-tests?

Yes

https://wpt.fyi/results/dom/events/scrolling/scrollend-event-fires-on-visual-viewport.html?label=experimental&label=master&aligned



Flag name on chrome://flags

None

Finch feature name

ScrollEndEvents

Requires code in //chrome?

False

Tracking bug

https://crbug.com/325307785

Estimated milestones

Shipping on desktop125
Shipping on Android125
Shipping on WebView125


Anticipated spec changes

Open questions about a feature may be a source of future web compat or interop issues. Please list open issues (e.g. links to known github issues in the project for the feature specification) whose resolution may introduce web compat/interop risk (e.g., changing to naming or structure of the API in a non-backward-compatible way).

None

Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/5774579609108480?gate=4770235262697472

This intent message was generated by Chrome Platform Status.

Domenic Denicola

unread,
Mar 26, 2024, 10:50:08 PMMar 26
to blink-dev, David Awogbemila
LGTM1, this is a very small change that IMO does not require any signals or TAG review. It's just bringing this event in line with all other events on the platform.

(It would be cool if there were some automated way of preventing this kind of omission in the future.)

Yoav Weiss (@Shopify)

unread,
Mar 27, 2024, 11:21:31 AMMar 27
to blink-dev, Domenic Denicola, David Awogbemila
On Wednesday, March 27, 2024 at 3:50:08 AM UTC+1 Domenic Denicola wrote:
LGTM1, this is a very small change that IMO does not require any signals or TAG review. It's just bringing this event in line with all other events on the platform.

(It would be cool if there were some automated way of preventing this kind of omission in the future.)

On Wednesday, March 27, 2024 at 9:49:16 AM UTC+9 David Awogbemila wrote:


Summary

Scrollend is a JavaScript event that fires to signal that a scrolling operation has come to an end. Similar to the Element interface[1], the visualViewport interface[2] includes an onscrollend event handler that should be invoked when a scrolling operation on the visualViewport has ended. Chromium already supports adding a scrollend event listener via `visualViewport.addEventListener("scrollend")`. This just makes it possible to also add an event listener using `visualViewport.onscrollend`. [1]https://html.spec.whatwg.org/multipage/webappapis.html#handler-onscrollend [2]https://drafts.csswg.org/cssom-view/#dom-visualviewport-onscrollend.



Blink componentBlink>Scroll

TAG reviewNone

TAG review statusNot applicable


Risks


Interoperability and Compatibility

None



Gecko: No signal
 

Web developers: No signals

Other signals:

WebView application risks

Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?

None



Debuggability

This makes it possible to add breakpoints to event handlers added by `visualViewport.onscrollend` similar to `visualViewport.onscroll` or onscrollend for any other element.



Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?Yes

Is this feature fully tested by web-platform-tests?Yes

https://wpt.fyi/results/dom/events/scrolling/scrollend-event-fires-on-visual-viewport.html?label=experimental&label=master&aligned


https://github.com/web-platform-tests/wpt/blob/master/dom/events/scrolling/scrollend-event-fires-on-visual-viewport.html does not actually test that the `onscrollend` variant is working. Can you add such a test?
 


Flag name on chrome://flagsNone

Finch feature nameScrollEndEvents

Requires code in //chrome?False

Tracking bughttps://crbug.com/325307785

Estimated milestonesShipping on desktop125Shipping on Android125Shipping on WebView125


Anticipated spec changes

Open questions about a feature may be a source of future web compat or interop issues. Please list open issues (e.g. links to known github issues in the project for the feature specification) whose resolution may introduce web compat/interop risk (e.g., changing to naming or structure of the API in a non-backward-compatible way).

None

Mike Taylor

unread,
Mar 27, 2024, 11:21:49 AMMar 27
to Domenic Denicola, blink-dev, David Awogbemila

LGTM2

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/db5674cc-3c3c-4092-bed7-9cf64c2fc59bn%40chromium.org.

Yoav Weiss (@Shopify)

unread,
Apr 3, 2024, 6:50:15 AMApr 3
to blink-dev, Mike Taylor, David Awogbemila, Domenic Denicola
LGTM3 as a test was added!

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.
Reply all
Reply to author
Forward
0 new messages