From a8b8dfee5be007e334b44d6a271dd6eb7df3e942 Mon Sep 17 00:00:00 2001 From: Shuchang Zheng Date: Wed, 16 Apr 2025 10:52:21 -0700 Subject: [PATCH] extend custom select (#2167) --- skyvern/webeye/scraper/domUtils.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/skyvern/webeye/scraper/domUtils.js b/skyvern/webeye/scraper/domUtils.js index 79595a48..e1ffe9eb 100644 --- a/skyvern/webeye/scraper/domUtils.js +++ b/skyvern/webeye/scraper/domUtils.js @@ -2216,6 +2216,8 @@ async function addIncrementalNodeToMap(parentNode, childrenNode) { try { for (const child of childrenNode) { + // sleep for a while until animation ends + await asyncSleepFor(300); // Pass -1 as frame_index to indicate the frame number is not sensitive in this case const [_, newNodeTree] = await buildElementTree(child, "", true); if (newNodeTree.length > 0) { @@ -2270,7 +2272,8 @@ if (window.globalObserverForDOMIncrement === undefined) { if (!mutation.oldValue) continue; if ( !isClassNameIncludesHidden(mutation.oldValue) && - !node.hasAttribute("data-menu-uid") // google framework use this to trace dropdown menu + !node.hasAttribute("data-menu-uid") && // google framework use this to trace dropdown menu + !mutation.oldValue.includes("select__items") ) continue; const newStyle = getElementComputedStyle(node);