@podlite/schema
Version:
AST tools for Podlite markup language
1,643 lines • 84.4 kB
JSON
{
"$ref": "#/definitions/RootBlock",
"definitions": {
"Ambient": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"ambient"
]
},
"text": {
"type": "string"
},
"location": {
"$ref": "#/definitions/Location"
}
},
"required": [
"location",
"text",
"type"
]
},
"Location": {
"type": "object",
"properties": {
"start": {
"$ref": "#/definitions/Position"
},
"end": {
"$ref": "#/definitions/Position"
}
},
"required": [
"end",
"start"
]
},
"Position": {
"type": "object",
"properties": {
"line": {
"type": "number"
},
"column": {
"type": "number"
},
"offset": {
"type": "number"
}
},
"required": [
"column",
"line",
"offset"
]
},
"BlockPod": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"pod"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"PodNode": {
"anyOf": [
{
"$ref": "#/definitions/Ambient"
},
{
"$ref": "#/definitions/BlockPod"
},
{
"$ref": "#/definitions/BlockData"
},
{
"$ref": "#/definitions/BlockFormula"
},
{
"$ref": "#/definitions/BlockCode"
},
{
"$ref": "#/definitions/BlankLine"
},
{
"$ref": "#/definitions/BlockNested"
},
{
"$ref": "#/definitions/BlockMarkdown"
},
{
"$ref": "#/definitions/BlockOutput"
},
{
"$ref": "#/definitions/BlockInput"
},
{
"$ref": "#/definitions/BlockInclude"
},
{
"$ref": "#/definitions/BlockPara"
},
{
"$ref": "#/definitions/BlockHead"
},
{
"$ref": "#/definitions/BlockComment"
},
{
"$ref": "#/definitions/BlockDefn"
},
{
"$ref": "#/definitions/Para"
},
{
"$ref": "#/definitions/Text"
},
{
"$ref": "#/definitions/Code"
},
{
"$ref": "#/definitions/BlockNamed"
},
{
"$ref": "#/definitions/Verbatim"
},
{
"$ref": "#/definitions/BlockTable"
},
{
"$ref": "#/definitions/List"
},
{
"$ref": "#/definitions/BlockConfig"
},
{
"$ref": "#/definitions/BlockItem"
},
{
"$ref": "#/definitions/Alias"
},
{
"$ref": "#/definitions/BlockToc"
},
{
"$ref": "#/definitions/BlockPicture"
},
{
"$ref": "#/definitions/BlockImage"
},
{
"$ref": "#/definitions/Image"
},
{
"$ref": "#/definitions/RootBlock"
},
{
"$ref": "#/definitions/Separator"
},
{
"$ref": "#/definitions/BlockCaption"
},
{
"$ref": "#/definitions/FormattingCodeA"
},
{
"$ref": "#/definitions/FormattingCodeC"
},
{
"$ref": "#/definitions/FormattingCodeB"
},
{
"$ref": "#/definitions/FormattingCodeD"
},
{
"$ref": "#/definitions/FormattingCodeE"
},
{
"$ref": "#/definitions/FormattingCodeF"
},
{
"$ref": "#/definitions/FormattingCodeI"
},
{
"$ref": "#/definitions/FormattingCodeL"
},
{
"$ref": "#/definitions/FormattingCodeN"
},
{
"$ref": "#/definitions/FormattingCodeX"
},
{
"$ref": "#/definitions/FormattingCodeZ"
},
{
"$ref": "#/definitions/FormattingCodeV"
},
{
"$ref": "#/definitions/FormattingCodeS"
},
{
"$ref": "#/definitions/FormattingCodeAny"
},
{
"$ref": "#/definitions/Toc"
},
{
"type": "string"
}
]
},
"BlockData": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"data"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"BrokenConfigItem": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"value": {
"anyOf": [
{
"$ref": "#/definitions/ConfigItemKV"
},
{
"type": "array",
"items": {
"type": [
"string",
"number",
"boolean"
]
}
},
{
"type": [
"string",
"number",
"boolean"
]
}
]
}
},
"required": [
"name",
"value"
]
},
"ConfigItemKV": {
"type": "object",
"additionalProperties": {
"type": [
"string",
"number",
"boolean"
]
}
},
"ConfigItem": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"value": {
"anyOf": [
{
"$ref": "#/definitions/ConfigItemKV"
},
{
"type": "array",
"items": {
"type": [
"string",
"number",
"boolean"
]
}
},
{
"type": [
"string",
"number",
"boolean"
]
}
]
},
"type": {
"type": "string"
}
},
"required": [
"name",
"type",
"value"
]
},
"BlockFormula": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"formula"
]
},
"content": {
"type": "array",
"items": [
{
"$ref": "#/definitions/Verbatim"
}
],
"minItems": 1,
"maxItems": 1
},
"margin": {
"type": "string"
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"Verbatim": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"verbatim"
]
},
"value": {
"type": "string"
}
},
"required": [
"type",
"value"
]
},
"BlockCode": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"code"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"BlankLine": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"blankline"
]
}
},
"required": [
"type"
]
},
"BlockNested": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"nested"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"BlockMarkdown": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"markdown"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"BlockOutput": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"output"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"BlockInput": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"input"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"BlockInclude": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"include"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"BlockPara": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"para"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"BlockHead": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"head"
]
},
"level": {
"type": [
"string",
"number"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"level",
"location",
"margin",
"name",
"type"
]
},
"BlockComment": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"comment"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"BlockDefn": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"defn"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"margin": {
"type": "string"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"Para": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"para"
]
},
"text": {
"type": "string"
},
"margin": {
"type": "string"
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/Ambient"
},
{
"$ref": "#/definitions/BlockPod"
},
{
"$ref": "#/definitions/BlockData"
},
{
"$ref": "#/definitions/BlockFormula"
},
{
"$ref": "#/definitions/BlockCode"
},
{
"$ref": "#/definitions/BlankLine"
},
{
"$ref": "#/definitions/BlockNested"
},
{
"$ref": "#/definitions/BlockMarkdown"
},
{
"$ref": "#/definitions/BlockOutput"
},
{
"$ref": "#/definitions/BlockInput"
},
{
"$ref": "#/definitions/BlockInclude"
},
{
"$ref": "#/definitions/BlockPara"
},
{
"$ref": "#/definitions/BlockHead"
},
{
"$ref": "#/definitions/BlockComment"
},
{
"$ref": "#/definitions/BlockDefn"
},
{
"$ref": "#/definitions/Para"
},
{
"$ref": "#/definitions/Text"
},
{
"$ref": "#/definitions/Code"
},
{
"$ref": "#/definitions/BlockNamed"
},
{
"$ref": "#/definitions/Verbatim"
},
{
"$ref": "#/definitions/BlockTable"
},
{
"$ref": "#/definitions/List"
},
{
"$ref": "#/definitions/BlockConfig"
},
{
"$ref": "#/definitions/BlockItem"
},
{
"$ref": "#/definitions/Alias"
},
{
"$ref": "#/definitions/BlockToc"
},
{
"$ref": "#/definitions/BlockPicture"
},
{
"$ref": "#/definitions/BlockImage"
},
{
"$ref": "#/definitions/Image"
},
{
"$ref": "#/definitions/RootBlock"
},
{
"$ref": "#/definitions/Separator"
},
{
"$ref": "#/definitions/BlockCaption"
},
{
"$ref": "#/definitions/FormattingCodeA"
},
{
"$ref": "#/definitions/FormattingCodeC"
},
{
"$ref": "#/definitions/FormattingCodeB"
},
{
"$ref": "#/definitions/FormattingCodeD"
},
{
"$ref": "#/definitions/FormattingCodeE"
},
{
"$ref": "#/definitions/FormattingCodeF"
},
{
"$ref": "#/definitions/FormattingCodeI"
},
{
"$ref": "#/definitions/FormattingCodeL"
},
{
"$ref": "#/definitions/FormattingCodeN"
},
{
"$ref": "#/definitions/FormattingCodeX"
},
{
"$ref": "#/definitions/FormattingCodeZ"
},
{
"$ref": "#/definitions/FormattingCodeV"
},
{
"$ref": "#/definitions/FormattingCodeS"
},
{
"$ref": "#/definitions/FormattingCodeAny"
},
{
"$ref": "#/definitions/Toc"
},
{
"type": "string"
}
]
}
}
},
"required": [
"content",
"location",
"margin",
"text",
"type"
]
},
"Text": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"text"
]
},
"value": {
"type": "string"
}
},
"required": [
"type",
"value"
]
},
"Code": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"code"
]
},
"text": {
"type": "string"
},
"margin": {
"type": "string"
},
"location": {
"$ref": "#/definitions/Location"
},
"content": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/Verbatim"
},
{
"type": "string"
}
]
}
}
},
"required": [
"content",
"location",
"margin",
"text",
"type"
]
},
"BlockNamed": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"content": {
"anyOf": [
{
"$ref": "#/definitions/RootBlock"
},
{
"type": "array",
"items": [
{
"anyOf": [
{
"$ref": "#/definitions/Para"
},
{
"$ref": "#/definitions/Code"
},
{
"$ref": "#/definitions/Verbatim"
}
]
}
],
"minItems": 0,
"maxItems": 1
},
{
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/Image"
},
{
"$ref": "#/definitions/BlockCaption"
}
]
}
}
]
},
"margin": {
"type": "string"
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"RootBlock": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"root"
]
},
"content": {
"$ref": "#/definitions/AstTree"
},
"margin": {
"type": "string"
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"margin",
"name",
"type"
]
},
"AstTree": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"Image": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"image"
]
},
"src": {
"type": "string"
},
"alt": {
"type": "string"
}
},
"required": [
"src",
"type"
]
},
"BlockCaption": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"caption"
]
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/PodNode"
}
},
"type": {
"type": "string",
"enum": [
"block"
]
}
},
"required": [
"content",
"name",
"type"
]
},
"BlockTable": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"table"
]
},
"content": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BlankLine"
},
{
"$ref": "#/definitions/TableRow"
},
{
"$ref": "#/definitions/TableHead"
},
{
"$ref": "#/definitions/TableSeparator"
}
]
}
},
"align": {
"type": "array",
"items": {
"anyOf": [
{
"enum": [
"center",
"left",
"right"
],
"type": "string"
},
{
"type": "null"
}
]
}
},
"text": {
"type": "string"
},
"margin": {
"type": "string"
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"location": {
"$ref": "#/definitions/Location"
},
"config": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BrokenConfigItem"
},
{
"$ref": "#/definitions/ConfigItem"
}
]
}
},
"id": {
"type": "string"
}
},
"required": [
"content",
"location",
"margin",
"name",
"type"
]
},
"TableRow": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"table_row"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/TableCell"
}
}
},
"required": [
"content",
"name",
"type"
]
},
"TableCell": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"table_cell"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"content": {
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"content",
"name",
"type"
]
},
"TableHead": {
"type": "object",
"properties": {
"name": {
"type": "string",
"enum": [
"table_head"
]
},
"type": {
"type": "string",
"enum": [
"block"
]
},
"content": {
"type": "array",
"items": {
"$ref": "#/definitions/TableCell"
}
}
},
"required": [
"content",
"name",
"type"
]
},
"TableSeparator": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"separator"
]
},
"text": {
"type": "string"
}
},
"required": [
"text",
"type"
]
},
"List": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": [
"list"
]
},
"level": {
"type": [
"string",
"number"
]
},
"content": {
"type": "array",
"items": {
"anyOf": [
{
"$ref": "#/definitions/BlankLine"
},
{
"$ref": "#/defi