MCPcopy Index your code
hub / github.com/editablejs/editable / canForceTakeFocus

Function canForceTakeFocus

packages/editor/src/utils/dom.ts:119–124  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

117}
118
119export const canForceTakeFocus = () => {
120 if (!CAN_USE_DOM) return true
121 const activeElement = document.activeElement
122 if (isEditableDOMElement(activeElement)) return false
123 return true
124}
125
126export const inAbsoluteDOMElement = (value: any): boolean => {
127 if (isDOMHTMLElement(value)) {

Callers 2

withEditableFunction · 0.90
handleDocumentMouseUpFunction · 0.90

Calls 1

isEditableDOMElementFunction · 0.85

Tested by

no test coverage detected