UNPKG

@atlaskit/adf-schema

Version:

Shared package that contains the ADF-schema (json) and ProseMirror node/mark specs

24 lines (23 loc) 778 B
import { Mappable, Step, StepResult } from 'prosemirror-transform'; import { Node as ProseMirrorNode, Schema } from 'prosemirror-model'; /** * For more context on what this is about: * @see https://discuss.prosemirror.net/t/preventing-image-placeholder-replacement-from-being-undone/1394 */ export declare class SetAttrsStep extends Step { pos: number; attrs: object; constructor(pos: number, attrs: object); apply(doc: ProseMirrorNode): StepResult<any>; invert(doc: ProseMirrorNode): SetAttrsStep; map(mapping: Mappable): SetAttrsStep | null; toJSON(): { stepType: string; pos: number; attrs: object; }; static fromJSON(_schema: Schema, json: { pos?: number; attrs: object; }): SetAttrsStep; }