feat: add WebFrameMain.visibilityState (#28706)
* feat: add WebFrameMain.visibilityState * docs: mention other page visibility APIs * test: delay visibilityState check after hiding * test: add waitForTrue to avoid flaky visibilityState test * refactor: waitForTrue -> waitUntil
This commit is contained in:
parent
93311c8686
commit
43d27cc4d1
5 changed files with 98 additions and 0 deletions
|
@ -182,3 +182,9 @@ This is not the same as the OS process ID; to read that use `frame.osProcessId`.
|
|||
An `Integer` representing the unique frame id in the current renderer process.
|
||||
Distinct `WebFrameMain` instances that refer to the same underlying frame will
|
||||
have the same `routingId`.
|
||||
|
||||
#### `frame.visibilityState` _Readonly_
|
||||
|
||||
A `string` representing the [visibility state](https://developer.mozilla.org/en-US/docs/Web/API/Document/visibilityState) of the frame.
|
||||
|
||||
See also how the [Page Visibility API](browser-window.md#page-visibility) is affected by other Electron APIs.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue