Teams‎ > ‎Animations Team‎ > ‎Highlights Archive‎ > ‎

November 2021 highlights


November 2021


Chrome Interactions Highlights

Archives: go/interactions-team-highlights





Resolved major spec issues with user activation

The HTML definition for “activation triggering events” has been incomplete since its inception, and that led to significant inconsistencies between browsers and redundancies in other specs that relied on HTML’s wording (e.g. in PointerLock).

mustaq@ recently resolved the long-standing HTML issue by securing consensus on removing high-level events, adding missing keyboard events, and fine-tuning all low-level events.

Before

After


The HTML spec is now clear and precise, and it is supported by 5 automated web-platform-tests (html/user-activation/activation-trigger-*). 

This HTML update immediately led to a cleanup in the PointerLock spec.  Any other spec that had to patch over the past HTML gaps can now be fixed too.

Scripted smooth scroll adjustments

skobes@ has landed a patch that fixes scripted smooth scroll adjustments. A user smooth scroll now continues with adjustment when interrupted by an instant programmatic scroll. crbug/1264266


Before (Text is jumpy)                                   

After (Text scrolls smoothly)


Main thread scrolling reasons

skobes@ has landed a patch that changes reporting "main thread scrolling reasons" in a way that makes sense post Scroll Unification. crbug/1082590


Fix Flaky animation tests

Kevers addressed a number of flaky animation tests.  In one batch of tests, the underlying problem was actually an infrastructure failure since results from one test were being compared with expectations for a different test.  Nonetheless, some of these non-WPT tests lacked equivalent test coverage in WPT, and the failures presented a golden opportunity to migrate them to WPT.  As part of the migration effort, tests were updated to make full use of the web-animations API.

CL 1, CL 2, CL 3, CL 4, CL 5


Numerical precision reared its ugly head again. 

Fortunately, the web-animations-1 spec is clear on the required precision for animation timing, and this was an easy fix by simply changing to the already supported assert_times_equal, which has the specced 1 microsecond of slack  (CL).


Animation Construction

Kevers resolved a crash on Android that was triggered by calling an animation constructor with a missing or destroyed execution context.  It should be perfectly fine to trigger an animation in such cases. We simply can’t run script (e.g. event handlers or promise resolution code).  The issue was fixed by conditionally setting the execution context  (CL).

ScrollTimeline

Kevers added support for progress based animations in our ScrollTimeline Polyfill  (PR). Doing so required adding a polyfill for several sub-components since in the web-animations-1 spec, all timing is in ms, whereas in web-animations-2 timing may be in ms or expressed as a percentage. Polyfills to AnimationEffect and AnimationPlaybackEvent now support percentages.  With the fix, the WPT tests now have a 94% pass rate!!

The Blink implementation of ScrollTimeline was out of sync with the spec in regard to one of the timeline property names.  The deprecated property scrollSource was replaced with the updated property name, source  (CL).  Though largely a mechanical change, it required updating 41 WPT tests.  Landed this change unblocked a third party contributor from landing the equivalent fix to the Polyfill (PR).  Thanks Bramus for diving in and contributing.


CSS Selector Fragments

mehdika@ has landed a CL that implements CSS Selector fragments behind this flag blink::features::kCssSelectorFragmentAnchor.

https://en.wikipedia.org/wiki/Cat#:~:selector(type=CssSelector,value=img[src$=”whiskers_cat.jpg”])


At this point the element is scrolled into the middle of the viewport. In the next step the element will be highlighted as well.



Bug Status Update





Chrome Interactions Highlights | November 2021






Comments