1 | import { Node as PMNode, Schema } from 'prosemirror-model';
|
2 | import { ReplaceStep, Step, StepMap, StepResult, Mappable } from 'prosemirror-transform';
|
3 | export declare const stepType = "editor-linking-meta";
|
4 | export declare const invertStepType = "editor-linking-meta-invert";
|
5 | export declare type LinkStepMetadata = {
|
6 | |
7 |
|
8 |
|
9 | action?: string;
|
10 | |
11 |
|
12 |
|
13 | inputMethod?: string;
|
14 | |
15 |
|
16 |
|
17 |
|
18 | cardAction?: 'RESOLVE';
|
19 | |
20 |
|
21 |
|
22 | sourceEvent?: unknown;
|
23 | };
|
24 |
|
25 |
|
26 |
|
27 |
|
28 |
|
29 | export declare class LinkMetaStep extends Step {
|
30 | private pos;
|
31 | private metadata;
|
32 | private isInverted;
|
33 | constructor(pos: number | null, metadata: LinkStepMetadata, isInverted?: boolean);
|
34 | getMetadata(): LinkStepMetadata;
|
35 | /**
|
36 | * Generate new undo/redo analytics event when step is inverted
|
37 | */
|
38 | invert(): LinkMetaStep;
|
39 | apply(doc: PMNode): StepResult<any>;
|
40 | map(mapping: Mappable): LinkMetaStep;
|
41 | getMap(): StepMap;
|
42 | merge(): null;
|
43 | toJSON(): {
|
44 | stepType: string;
|
45 | from: number;
|
46 | to: number;
|
47 | };
|
48 | static fromJSON<S extends Schema = any>(_: S, __: {
|
49 | [key: string]: any;
|
50 | }): ReplaceStep<any>;
|
51 | }
|