UNPKG

1.11 kBTypeScriptView Raw
1import { NodeSpec } from 'prosemirror-model';
2import { ParagraphDefinition as Paragraph } from './paragraph';
3import { OrderedListDefinition as OrderedList } from './types/list';
4import { BulletListDefinition as BulletList } from './types/list';
5import { HeadingDefinition as Heading } from './heading';
6import { BlockCardDefinition as BlockCard } from './block-card';
7export declare enum PanelType {
8 INFO = "info",
9 NOTE = "note",
10 TIP = "tip",
11 WARNING = "warning",
12 ERROR = "error",
13 SUCCESS = "success",
14 CUSTOM = "custom"
15}
16export interface PanelAttributes {
17 panelType: PanelType;
18 panelIcon?: string;
19 panelIconId?: string;
20 panelIconText?: string;
21 panelColor?: string;
22}
23/**
24 * @name panel_node
25 */
26export interface PanelDefinition {
27 type: 'panel';
28 attrs: PanelAttributes;
29 /**
30 * @minItems 1
31 * @allowUnsupportedBlock true
32 */
33 content: Array<Paragraph | Heading | OrderedList | BulletList | BlockCard>;
34}
35export interface DOMAttributes {
36 [propName: string]: string;
37}
38export declare const panel: (allowCustomPanel: boolean) => NodeSpec;