type Title = boolean; type CodeBlock = { lang: string; filename?: string; indent: number; start: boolean; end: boolean; }; type TableBlock = { title: string; cells: string[]; indent: number; start: boolean; end: boolean; }; type Helpfeel = { prefix: "?"; entry: string; }; type Cli = { prefix: "$" | "%"; command: string; }; type UnitBase = { content: string; whole: string; }; type PlainText = string; type Blank = { type: "blank"; unit: UnitBase; children: PlainText; }; type Video = { type: "video"; unit: UnitBase; fileId: string | undefined; children: PlainText; }; type Vimeo = { type: "vimeo"; unit: UnitBase & { videoId: string; }; children: PlainText; }; type Decoration = { type : "deco"; unit: UnitBase & { deco: string; strong: number; italic: boolean; strike: boolean; underline: boolean; }; children: Node; } type Link = { type: "link"; unit: UnitBase & ({ page: string; } | { project: string; page: string; } | { project: string; }); children: Node; }; type Quote = { type: "quote"; unit: UnitBase & { tag: string; }; children: Node; }; type Code = { type: "code"; unit: UnitBase; children: PlainText; }; type Indent = { type: "indent"; unit: UnitBase & { tag: string; }; children: Node; }; type Audio = { type: "audio"; unit: UnitBase; fileId: string | undefined; children: PlainText; }; type AudioLink = { type: "audioLink"; unit: UnitBase & { link: string; title: string; }; fileId: string | undefined; children: PlainText; }; type Image = ImageBase & { type: "image"; }; type StrongImage = ImageBase & { type: "strongImage"; }; type ImageBase = { unit: UnitBase; fileId: string | undefined; children: PlainText; }; type Gyazo = GyazoBase & { type: "gyazo"; }; type StrongGyazo = GyazoBase & { type: "strongGyazo"; }; type GyazoBase = { unit: UnitBase; children: PlainText; }; type ImageLink = ImageLinkBase & { type: "imageLink"; }; type StrongImageLink = ImageLinkBase & { type: "strongImageLink"; }; type ImageLinkBase = { unit: UnitBase & { image: string; link: string; }; children: PlainText; }; type GyazoLink = GyazoLinkBase & { type: "gyazoLink"; }; type StrongGyazoLink = GyazoLinkBase & { type: "strongGyazoLink"; }; type GyazoLinkBase = { unit: UnitBase & { gyazo: string; link: string; }; children: PlainText; }; type Icon = IconBase & { type: "icon" }; type StrongIcon = IconBase & { type: "strong-icon" }; type IconBase = { unit: UnitBase & { project?: string; page: string; size: number; }; children: PlainText; }; type Formula = { type: "deco-formula"; unit: UnitBase & { formula: string; }; children: PlainText; } type Formula = { type: "strong"; unit: UnitBase; children: Node; } type Url = { type: "url"; unit: UnitBase; fileId: string | undefined; children: PlainText; }; type UrlLink = { type: "urlLink"; unit: UnitBase & { link: string; title?: string; }; fileId: string | undefined; children: PlainText; }; type Youtube = { type: "youtube"; unit: UnitBase & { params: Record & { t?: number; }; } & ({ videoId?: string; } | { listId?: string; }); children: PlainText; }; type Location = { type: "location"; unit: UnitBase & { latitude: number; longitude: number; zoom: number; title?: string; }; children: PlainText; };