mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-12-29 06:02:07 +03:00
LibWebView: Use querySelectorAll to find hoverable tree nodes
We don't need a live HTMLCollection here, so let's use querySelectorAll to instead iterate over a static NodeList.
This commit is contained in:
parent
030b90b79d
commit
a7ff65a0c6
Notes:
sideshowbarker
2024-07-18 08:59:31 +09:00
Author: https://github.com/trflynn89 Commit: https://github.com/SerenityOS/serenity/commit/a7ff65a0c6 Pull-request: https://github.com/SerenityOS/serenity/pull/22096
@ -53,7 +53,7 @@ inspector.loadDOMTree = tree => {
|
||||
let domTree = document.getElementById("dom-tree");
|
||||
domTree.innerHTML = atob(tree);
|
||||
|
||||
let domNodes = domTree.getElementsByClassName("hoverable");
|
||||
let domNodes = domTree.querySelectorAll(".hoverable");
|
||||
|
||||
for (let domNode of domNodes) {
|
||||
domNode.addEventListener("click", event => {
|
||||
|
Loading…
Reference in New Issue
Block a user