| 180 | }; |
| 181 | |
| 182 | let onFocusIn: EventListener = e => { |
| 183 | if (isFocusMovingToTarget(getEventTarget(e) as Element) || isRefocusing) { |
| 184 | e.stopImmediatePropagation(); |
| 185 | |
| 186 | if (!isRefocusing) { |
| 187 | isRefocusing = true; |
| 188 | focusWithoutScrolling(activeElement); |
| 189 | cleanup(); |
| 190 | } |
| 191 | } |
| 192 | }; |
| 193 | |
| 194 | root.addEventListener('blur', onBlur, true); |
| 195 | root.addEventListener('focusout', onFocusOut, true); |
nothing calls this directly
no test coverage detected