Skip to content
This page is available as Markdown at /api/editor/type-aliases/decorationmapping.md. For the full documentation index, see /llms.txt, or the complete corpus at /llms-full.txt.

DecorationMapping

DecorationMapping = object

Defined in: packages/editor/src/types/editor.ts:313

What one engine operation did to one registered decoration’s range.

contentTouched: boolean

Defined in: packages/editor/src/types/editor.ts:325

Whether the operation changed content inside previousRange.


id: string

Defined in: packages/editor/src/types/editor.ts:315

The decoration’s id, matching the Decoration it describes.


newRange: NonNullable<EditorSelection> | null

Defined in: packages/editor/src/types/editor.ts:323

The range after the operation. null means the operation destroyed the decoration. Undo does not revive it: an update() with a different range (or a drop and re-add) is required.


origin: "local" | "remote"

Defined in: packages/editor/src/types/editor.ts:327

Whether the operation came from a local edit or a remote one.


previousRange: NonNullable<EditorSelection>

Defined in: packages/editor/src/types/editor.ts:317

The range the decoration held before the operation.