page_waitElementGone
Waits for a UI element to disappear from the page. Verifies that loading indicators, toasts, or modals have closed, returning success when gone.
Instructions
轮询等待选择器对应的元素从页面消失(最长 timeout 毫秒,每 retryInterval 毫秒重试)。何时用:验证 toast / loading / 弹窗 / 骨架屏已消失。成功返回 {selector,gone:true,waitTime}。带 selector[index=N] 时,该索引越界也算「已消失」。timeout 默认 5000ms,retryInterval 默认 200ms。等任意非元素条件(page.data 变化等)改用 mp_pollUntil。超时抛错;若轮询期间持续底层报错会提示可能是连接级故障,建议 mp_healthCheck / mp_recoverConnection。
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| timeout | No | ||
| selector | Yes | ||
| connection | No | 可选连接覆盖(不传则用默认会话)。可用字段:mode(launch|connect)、cliPath、projectPath、wsEndpoint、timeout、port(【自动化端口】→ cli auto --auto-port,默认 9420;不是 IDE HTTP 服务端口,别把 IDE 服务端口传进来)、account、ticket、trustProject、args、cwd、autoClose、autoLaunch、launchTimeout、connectTimeout。 | |
| retryInterval | No |