Is there a way to create a JavaScript function that can specifically extract hidden text from an element? Are there any existing libraries with this capability, and if so, how efficient are they?
- In order for an element to be considered visible according to the Selenium Webdriver W3C spec, it must have a height and width greater than 0px.
- If any ancestor of the element, or the element itself, is hidden or has a CSS display property of none, then the element is not visible.
- An element with a CSS3 Transform property that moves it out of view and cannot be scrolled to is also not visible.
- SPECIAL CASE: OPTIONs and OPTGROUP elements are only shown if their enclosing select element is visible.
- MAP elements are visible only when the image they use is visible. Areas within a map are visible when the enclosing MAP element is visible.
- Any INPUT elements with "type=hidden" are considered invisible.
- NOSCRIPT elements are hidden when JavaScript is enabled.
- An element is not visible if any ancestor in its transitive closure of offsetParents has a fixed size, overflow:hidden CSS style, and the element's location is outside the bounds of the parent's fixed size.