Skip to main content

@lexical/react/LexicalSelectionAlwaysOnDisplay

Functions

SelectionAlwaysOnDisplay()

SelectionAlwaysOnDisplay(__namedParameters): null

Defined in: packages/lexical-react/src/LexicalSelectionAlwaysOnDisplay.tsx:28

Keeps the visual selection highlight on display even when the editor loses focus, which is useful when interacting with toolbars or other controls outside the editor. Pass onReposition to be notified when the highlighted range elements are recomputed.

This is a legacy plugin. When building an editor with the extension API, configure SelectionAlwaysOnDisplayExtension instead.

Parameters

__namedParameters

Props

Returns

null

null, this plugin renders no DOM of its own.