Module: actions/EditNew/runEditTargets
Functions
runEditTargets
▸ runEditTargets(graph, editor, state): Promise<State>
Handle targets that will use an edit action to insert a new target, and return an updated state object.
We proceed by asking the targets to construct an edit where we insert an empty string, and then we place the cursor where that empty string would be. This will cause the targets to delete themselves, or insert a delimiter if they are positional.
Parameters
| Name | Type | Description |
|---|---|---|
graph | Graph | The graph object |
editor | EditableTextEditor | The editor on which we're operating |
state | State | The state object tracking cursors, thatMark, etc |
Returns
Promise<State>
An updated state object
Defined in
actions/EditNew/runEditTargets.ts:24