mirror of
https://github.com/lightpanda-io/browser.git
synced 2026-02-04 14:33:47 +00:00
axnode: ignore script and style children
This commit is contained in:
@@ -801,6 +801,7 @@ fn writeName(axnode: AXNode, w: anytype, page: *Page) !?AXSource {
|
||||
.object, .progress, .meter, .main, .nav, .aside, .header,
|
||||
.footer, .form, .section, .article, .ul, .ol, .dl, .menu,
|
||||
.thead, .tbody, .tfoot, .tr, .td, .div, .span, .p, .details, .li,
|
||||
.style, .script,
|
||||
// zig fmt: on
|
||||
=> {},
|
||||
else => {
|
||||
@@ -891,7 +892,7 @@ fn ignoreChildren(self: AXNode) bool {
|
||||
|
||||
const elt = node.as(DOMNode.Element);
|
||||
return switch (elt.getTag()) {
|
||||
.head => true,
|
||||
.head, .script, .style => true,
|
||||
else => false,
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user