UNPKG

@antv/narrative-text-schema

Version:

Json schema of narrative text visualization

12 lines (11 loc) 1.09 kB
import type { SectionSpec, ParagraphSpec, CustomBlockElement, StandardSectionSpec, TextParagraphSpec, BulletsParagraphSpec, HeadingParagraphSpec, PhraseSpec, CustomPhraseSpec, EntityPhraseSpec, TextPhraseSpec } from '../schema'; export declare function isCustomSection(spec: SectionSpec): spec is CustomBlockElement; export declare function isCustomParagraph(spec: ParagraphSpec): spec is CustomBlockElement; export declare function isStandardSection(spec: SectionSpec): spec is StandardSectionSpec; export declare function isTextParagraph(spec: ParagraphSpec): spec is TextParagraphSpec; export declare function isBulletParagraph(spec: ParagraphSpec): spec is BulletsParagraphSpec; export declare function isHeadingParagraph(spec: ParagraphSpec): spec is HeadingParagraphSpec; export declare function isCustomPhrase(spec: PhraseSpec): spec is CustomPhraseSpec; export declare function isEntityPhrase(spec: PhraseSpec): spec is EntityPhraseSpec; export declare function isTextPhrase(spec: PhraseSpec): spec is TextPhraseSpec; export declare function getHeadingWeight(pType: string): number;