Skip to content

eo-typewriterjs


eo-typewriterjs / TMoveEvent

Type Alias: TMoveEvent ​

ts
type TMoveEvent = TBaseEvent & object;

Defined in: core/events/types/move-event.type.ts:20

Type Declaration ​

NameTypeDefined in
kindtypeof MOVEcore/events/types/move-event.type.ts:21
timenumbercore/events/types/move-event.type.ts:22
cursorIdstringcore/events/types/move-event.type.ts:23
boundary?"start" | "end"core/events/types/move-event.type.ts:24
offsetnumbercore/events/types/move-event.type.ts:25
byTAdvanceModeInputcore/events/types/move-event.type.ts:26
sourceCommandIdstringcore/events/types/move-event.type.ts:27

Description ​

A scheduled event that moves a cursor.

When boundary is present it takes precedence:

  • "start": jump to absolute document start (index 0)
  • "end": jump to absolute document end (index text.length)

When boundary is absent the reducer moves by offset units using by:

  • positive offset moves right, negative offset moves left

This event is instant - it does not consume any timeline duration.

Released under the MIT License.