UNPKG

908 BTypeScriptView Raw
1import { NodeSpec, Node } from 'prosemirror-model';
2import { MediaDefinition as Media } from './media';
3import { LinkDefinition } from '../marks/link';
4export declare type Layout = 'wrap-right' | 'center' | 'wrap-left' | 'wide' | 'full-width' | 'align-end' | 'align-start';
5/**
6 * @name mediaSingle_node
7 */
8export interface MediaSingleDefinition {
9 type: 'mediaSingle';
10 /**
11 * @minItems 1
12 * @maxItems 1
13 */
14 content: Array<Media>;
15 attrs?: MediaSingleAttributes;
16 marks?: Array<LinkDefinition>;
17}
18export interface MediaSingleAttributes {
19 /**
20 * @minimum 0
21 * @maximum 100
22 */
23 width?: number;
24 layout: Layout;
25}
26export declare const defaultAttrs: {
27 width: {
28 default: null;
29 };
30 layout: {
31 default: string;
32 };
33};
34export declare const mediaSingle: NodeSpec;
35export declare const toJSON: (node: Node<any>) => {
36 attrs: any;
37};