Function
style
(
selector: string,
property: keyof CSSStyleDeclaration,
)
Source from the content-addressed store, hash-verified
| 122 | } |
| 123 | |
| 124 | async function style( |
| 125 | selector: string, |
| 126 | property: keyof CSSStyleDeclaration, |
| 127 | ): Promise<any> { |
| 128 | return await page.$eval( |
| 129 | selector, |
| 130 | (node, property) => { |
| 131 | return window.getComputedStyle(node)[property] |
| 132 | }, |
| 133 | property, |
| 134 | ) |
| 135 | } |
| 136 | |
| 137 | async function isVisible(selector: string): Promise<boolean> { |
| 138 | const display = await page.$eval(selector, node => { |
Tested by
no test coverage detected