← ClaudeAtlas

flaky-browser-uilisted

Use when driving a web UI programmatically and it fights back — tabs that stop existing between calls, clicks or typed values that never register, React or Gutenberg inputs that ignore assignment, comboboxes that resist every event, or a batch that died mid-way after submitting something. Applies on any page, public or signed-in, in your own account or a client's, in an attached browser or in Playwright. Covers batching, aiming by DOM selector, polling instead of sleeping, native-setter input, full pointer sequences, the attempt budget, and when to abandon the UI for an API.
praticoeq-sudo/browser-account-guard · ★ 0 · Web & Frontend · score 67
Install: claude install-skill praticoeq-sudo/browser-account-guard
# When the UI will not obey Automating someone else's web UI fails in three recurring ways: the **tab dies** between calls, the **framework swallows** your input, or the **control is unreachable** by any synthetic event. Each has a specific answer, and each has a point where the right move is to stop and use an API. > If the page is a signed-in panel belonging to a client or another organisation, run the > companion skill **`browser-account-guard`** first. Making the UI obey in the wrong account > is worse than not making it obey at all. --- ## Tabs that die between calls Symptom: *tab no longer exists*, between one call and the next, repeatedly. 1. **Batching is the default, not an optimization.** A tab survives *within* a batch and dies *between* batches. Chain navigate → wait → act → capture in one batch. 2. 🔑 **Inside a batch, aim by DOM selector — never by a stored element handle, never by coordinate.** A handle comes from an earlier page read, and that earlier call is exactly what dies. A coordinate refers to the screenshot taken *before* the batch, and page scale shifts between loads. Only a selector resolved *at execution time* survives. 3. **Do not sleep blindly — poll.** There is usually no wait-for-selector. Resolve a **string or boolean**, never the element: a bridge that serialises the return value turns a DOM node into `{}`, and you lose the difference between found and timed out. ```js await new Promise(r => { const t0 = Date.now(