mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
chore: rename serializeTree parameter (#6308)
This commit is contained in:
parent
1d08e274a8
commit
8e29b7a38d
@ -208,13 +208,13 @@ export class Accessibility {
|
||||
|
||||
private serializeTree(
|
||||
node: AXNode,
|
||||
whitelistedNodes?: Set<AXNode>
|
||||
interestingNodes?: Set<AXNode>
|
||||
): SerializedAXNode[] {
|
||||
const children: SerializedAXNode[] = [];
|
||||
for (const child of node.children)
|
||||
children.push(...this.serializeTree(child, whitelistedNodes));
|
||||
children.push(...this.serializeTree(child, interestingNodes));
|
||||
|
||||
if (whitelistedNodes && !whitelistedNodes.has(node)) return children;
|
||||
if (interestingNodes && !interestingNodes.has(node)) return children;
|
||||
|
||||
const serializedNode = node.serialize();
|
||||
if (children.length) serializedNode.children = children;
|
||||
|
Loading…
Reference in New Issue
Block a user