Skip to content

misc(treemap): highlight treemap node on mouse hover table row#12483

Merged
connorjclark merged 2 commits into
masterfrom
treemap-table-hover
May 17, 2021
Merged

misc(treemap): highlight treemap node on mouse hover table row#12483
connorjclark merged 2 commits into
masterfrom
treemap-table-hover

Conversation

@connorjclark

Copy link
Copy Markdown
Collaborator

ref #11254

@connorjclark connorjclark requested a review from a team as a code owner May 14, 2021 22:15
@connorjclark connorjclark requested review from adamraine and removed request for a team May 14, 2021 22:15
@google-cla google-cla Bot added the cla: yes label May 14, 2021
@connorjclark connorjclark mentioned this pull request May 14, 2021
24 tasks
Comment thread lighthouse-treemap/app/src/main.js Outdated
Comment thread lighthouse-treemap/app/src/main.js Outdated
this.viewModes;
/** @type {RenderState=} */
this.previousRenderState;
/** @type {WeakMap<HTMLElement, LH.Treemap.Node>} */

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Out of curiosity, why a WeakMap if it's recreated with every new version of the table? To me it still signals something special is going on so be careful while reading, but it's probably actually a good default to use when you don't need to iterate and perf isn't a big concern...

@connorjclark connorjclark May 17, 2021

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In addition to different bundle selector values re-creating the table, scrolling also recreates rows. They are all lazily rendered. So it's good that scrolling doesn't eventually result in OOM (after n months or whatever) :)

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also agree it's just a good default

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants