commit | 915c34778a2083a76361c0a727c00fe95603e0a0 | [log] [tgz] |
---|---|---|
author | Jack Franklin <jacktfranklin@chromium.org> | Tue Nov 23 10:42:28 2021 |
committer | Jack Franklin <jacktfranklin@chromium.org> | Mon Dec 06 09:58:36 2021 |
tree | eeddec2903439f428f24789ec25e41dac56535bb | |
parent | 52ea6aa7bb85018baec11cbfe247ba1be6d9d892 [diff] |
Fix layout shift clustering calculations This CL fixes an issue with how we were clustering the layout shifts (as per https://web.dev/cls/#measure-cls-in-javascript). Because the code looped through and assigned shifts to a cluster only when it found an event in a new cluster, this meant that the final clustering of layout shifts wouldn't be correctly assigned, and they would have no _current_cluster_id, causing the UI to render incorrectly. We still need to render _current_cluster_id conditionally (done in https://crrev.com/c/3295534), because sometimes layout shifts cannot be assigned to a cluster (if they have recent user input), but this CL fixes cases where we would incorrectly not assign a cluster. I also pulled the method out so we can unit test it. Bug: 1259606 Change-Id: I351a2c8c9054f5b21140a991e5c3760636854488 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3295491 Reviewed-by: Tim van der Lippe <tvanderlippe@chromium.org> Reviewed-by: Michal Mocny <mmocny@chromium.org> Commit-Queue: Jack Franklin <jacktfranklin@chromium.org> (cherry picked from commit 6487cb72b38a2803b72b21eca7b222ba706062b5) Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/3317342 Reviewed-by: Kim-Anh Tran <kimanh@chromium.org> Reviewed-by: Alex Rudenko <alexrudenko@chromium.org>
The client-side of the Chrome DevTools, including all JS & CSS to run the DevTools webapp.
The frontend is available on chromium.googlesource.com.
Please be aware that DevTools follows additional development guidelines.
The issue triage guidelines can be found in docs/triage_guidelines.md.
Instructions to set up, use, and maintain a DevTools frontend checkout can be found in docs/workflows.md.
DevTools frontend repository is mirrored on GitHub.
DevTools frontend is also available on NPM as the chrome-devtools-frontend package. It's not currently available via CJS or ES modules, so consuming this package in other tools may require some effort.
The version number of the npm package (e.g. 1.0.373466
) refers to the Chromium commit position of latest frontend git commit. It's incremented with every Chromium commit, however the package is updated roughly daily.
All DevTools commits: View the log or follow @DevToolsCommits on Twitter
All open DevTools tickets on crbug.com
File a new DevTools ticket: new.crbug.com
Code reviews mailing list: devtools-reviews@chromium.org
@ChromeDevTools on Twitter
Chrome DevTools mailing list: groups.google.com/forum/google-chrome-developer-tools