MCPcopy Create free account
hub / github.com/reactstrap/reactstrap / getFocusedChild

Function getFocusedChild

src/Modal.js:309–319  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

307 }
308
309 getFocusedChild() {
310 let currentFocus;
311 const focusableChildren = this.getFocusableChildren();
312
313 try {
314 currentFocus = document.activeElement;
315 } catch (err) {
316 currentFocus = focusableChildren[0];
317 }
318 return currentFocus;
319 }
320
321 trapFocus(ev) {
322 if (!this.props.trapFocus) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…