captureCodeBlockFocus
Captures where the focus is inside a rendered code block.
Import:
import { captureCodeBlockFocus } from '@mnaoumov/obsidian-lib/code-block-render-handoff';Signature:
function captureCodeBlockFocus(el: HTMLElement): CodeBlockFocusSnapshot | nullParameters:
| Parameter | Type | Description |
|---|---|---|
el |
HTMLElement | The code block element. |
Returns: CodeBlockFocusSnapshot | null — The snapshot, or null when the focus is not inside the element.
Links to this page: