(el: HTMLElement)
| 10 | }; |
| 11 | |
| 12 | const isScrollable = (el: HTMLElement) => { |
| 13 | const computedStyle = getComputedStyle(el); |
| 14 | |
| 15 | return (el.scrollHeight > el.clientHeight && ["scroll", "auto"].indexOf(computedStyle.overflowY) >= 0) |
| 16 | || (el.scrollWidth > el.clientWidth && ["scroll", "auto"].indexOf(computedStyle.overflowX) >= 0); |
| 17 | }; |
| 18 | |
| 19 | const getFirstFocusableElement = async (container: HTMLElement, startFromContainer?: boolean): FocusableElementPromise => { |
| 20 | if (!container || isElementHidden(container)) { |
no outgoing calls
no test coverage detected
searching dependent graphs…