Skip to content

MarkNode

Defined in: core/src/features/tokens/tree/types.ts:342

readonly children: Signal<readonly TreeNode[]>;

Defined in: core/src/features/tokens/tree/types.ts:350


readonly descriptor: MarkupDescriptor;

Defined in: core/src/features/tokens/tree/types.ts:345


readonly id: number;

Defined in: core/src/features/tokens/tree/types.ts:344


readonly kind: "mark";

Defined in: core/src/features/tokens/tree/types.ts:343


readonly markup: Markup;

Defined in: core/src/features/tokens/tree/types.ts:347

The public view of the descriptor, which is not a public type.


readonly meta: Signal<string | undefined>;

Defined in: core/src/features/tokens/tree/types.ts:349


position: object;

Defined in: core/src/features/tokens/tree/types.ts:358

end: number;
start: number;

slotRange:
| {
end: number;
start: number;
}
| undefined;

Defined in: core/src/features/tokens/tree/types.ts:357

Live slot POSITIONS, written by adoption like position; slot() is the public read of the slot’s TEXT, which is why the two carry different names. Slot text is deliberately NOT stored: projection, snapshot and adoption equality all derive it from children, so a stored copy would be an unread mirror nothing resyncs.


readonly value: Signal<string>;

Defined in: core/src/features/tokens/tree/types.ts:348

duplicate(): boolean;

Defined in: core/src/features/tokens/tree/types.ts:367

boolean


insertAfter(text): boolean;

Defined in: core/src/features/tokens/tree/types.ts:368

Parameter Type
text string

boolean


mergeWith(next): boolean;

Defined in: core/src/features/tokens/tree/types.ts:369

Parameter Type
next TreeNode

boolean


range(): object;

Defined in: core/src/features/tokens/tree/types.ts:362

See TextNode.range.

object

end: number;
start: number;

remove(): boolean;

Defined in: core/src/features/tokens/tree/types.ts:366

See NodeCommands.

boolean


slot(): string | undefined;

Defined in: core/src/features/tokens/tree/types.ts:360

The slot’s TEXT, joined from the live children. undefined for a slotless markup.

string | undefined


update(patch): boolean;

Defined in: core/src/features/tokens/tree/types.ts:364

Rides a transaction; false in read-only mode or off the tree.

Parameter Type
patch MarkPatch

boolean