-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add more block level nodes; remove Text
- Loading branch information
Showing
18 changed files
with
183 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
type: Emphasis | ||
content: | ||
- type: Text | ||
value: This is some text | ||
- Some emphasied text | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
type: Heading | ||
depth: 1 | ||
content: | ||
- type: Text | ||
value: "Metamorphosis" | ||
- Metamorphosis |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,10 @@ | ||
type: Paragraph | ||
content: | ||
- type: Text | ||
value: Some text with some | ||
- Some text with some | ||
- type: Emphasis | ||
content: | ||
- type: Text | ||
value: emphasised words | ||
- type: Text | ||
value: ' and ' | ||
- emphasised words | ||
- ' and ' | ||
- type: Strong | ||
content: | ||
- type: Text | ||
value: some strongly emphasised words | ||
- some strongly emphasised words |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
type: Table | ||
cells: | ||
- type: TableCell | ||
position: [0, 0] | ||
content: | ||
- 1 | ||
- type: TableCell | ||
position: [1, 0] | ||
content: | ||
- Some text | ||
- type: Emphasis | ||
content: | ||
- emphasised | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
$schema: http://json-schema.org/draft-07/schema# | ||
$id: https://stencila.github.com/schema/Blockquote.schema.json | ||
title: Blockquote | ||
'@id': stencila:Blockquote | ||
description: | | ||
A section quoted from somewhere else. | ||
properties: | ||
type: | ||
enum: [Blockquote] | ||
content: | ||
'@id': 'stencila:content' | ||
description: | | ||
The content that is marked for deletion. Often indicated using a strike through style. | ||
allOf: | ||
- $ref: blockContent.schema.yaml | ||
additionalProperties: false | ||
required: | ||
- type | ||
- content |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
$schema: http://json-schema.org/draft-07/schema# | ||
$id: https://stencila.github.com/schema/Expression.schema.json | ||
title: Expression | ||
description: An expression. | ||
allOf: | ||
- $ref: SoftwareSourceCode.schema.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
$schema: http://json-schema.org/draft-07/schema# | ||
$id: https://stencila.github.com/schema/List.schema.json | ||
title: List | ||
'@id': schema:ItemList | ||
description: | | ||
A list of items. | ||
properties: | ||
type: | ||
enum: [List] | ||
order: | ||
'@id': 'schema:itemListOrder' | ||
description: Type of ordering. | ||
enum: | ||
- ascending | ||
- descending | ||
- unordered | ||
items: | ||
'@id': 'schema:itemListElement' | ||
type: array | ||
items: | ||
$ref: ListItem.schema.yaml | ||
additionalProperties: false | ||
required: | ||
- type | ||
- items |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
$schema: http://json-schema.org/draft-07/schema# | ||
$id: https://stencila.github.com/schema/ListItem.schema.json | ||
title: List | ||
'@id': schema:ListItem | ||
description: | | ||
A list item, e.g. a step in a checklist or how-to description. | ||
properties: | ||
type: | ||
enum: [ListItem] | ||
position: | ||
'@id': 'schema:position' | ||
description: The position of an item in a series or sequence of items. | ||
type: integer | ||
item: | ||
'@id': 'schema:itemListElement' | ||
description: The position of an item in a series or sequence of items. | ||
additionalProperties: false | ||
required: | ||
- type | ||
- item |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,32 @@ | ||
$schema: http://json-schema.org/draft-07/schema# | ||
$id: https://stencila.github.com/schema/Table.schema.json | ||
title: Table | ||
'@id': stencila:Table | ||
'@id': schema:Table | ||
description: | | ||
A table within an executable document. | ||
type: object | ||
properties: | ||
cells: | ||
'@id': stencila:cells | ||
description: | | ||
An array of cells in the table. | ||
type: array | ||
items: | ||
$ref: TableCell.schema.yaml | ||
allOf: | ||
- $ref: CreativeWork.schema.yaml | ||
- properties: | ||
type: | ||
enum: [Table] | ||
rows: | ||
'@id': stencila:rows | ||
description: | | ||
Rows of cells in the table. | ||
type: array | ||
items: | ||
$ref: TableRow.schema.yaml | ||
cells: | ||
'@id': stencila:cells | ||
description: | | ||
An array of cells in the table. | ||
type: array | ||
items: | ||
$ref: TableCell.schema.yaml | ||
required: | ||
- type | ||
anyOf: | ||
- required: | ||
- rows | ||
- required: | ||
- cells |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
$schema: http://json-schema.org/draft-07/schema# | ||
$id: https://stencila.github.com/schema/TableRow.schema.json | ||
title: TableRow | ||
'@id': stencila:TableRow | ||
description: | | ||
A row within a `Table`. | ||
properties: | ||
type: | ||
enum: [TableRow] | ||
cells: | ||
'@id': stencila:cells | ||
description: | | ||
An array of cells in the table. | ||
type: array | ||
items: | ||
$ref: TableCell.schema.yaml | ||
additionalProperties: false | ||
required: | ||
- type | ||
- value |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
$schema: http://json-schema.org/draft-07/schema# | ||
$id: https://stencila.github.com/schema/ThematicBreak.schema.json | ||
title: ThematicBreak | ||
'@id': stencila:ThematicBreak | ||
description: | | ||
A thematic break, such as a scene change in a story, a transition to another topic, or a new document. | ||
properties: | ||
type: | ||
enum: [ThematicBreak] | ||
additionalProperties: false | ||
required: | ||
- type |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
$schema: http://json-schema.org/draft-07/schema# | ||
$id: https://stencila.github.com/schema/blockContent.schema.json | ||
description: Block content. | ||
anyOf: | ||
- $ref: Blockquote.schema.yaml | ||
- $ref: Heading.schema.yaml | ||
- $ref: List.schema.yaml | ||
- $ref: Paragraph.schema.yaml | ||
- $ref: Table.schema.yaml | ||
- $ref: ThematicBreak.schema.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,12 @@ | ||
$schema: http://json-schema.org/draft-07/schema# | ||
$id: https://stencila.github.com/schema/inlineContent.schema.json | ||
description: Inline content. | ||
type: array | ||
items: | ||
anyOf: | ||
- $ref: Text.schema.yaml | ||
- $ref: Emphasis.schema.yaml | ||
- $ref: Strong.schema.yaml | ||
- $ref: Delete.schema.yaml | ||
- $ref: Verbatim.schema.yaml | ||
anyOf: | ||
- type: boolean | ||
- type: integer | ||
- type: number | ||
- type: string | ||
- $ref: Emphasis.schema.yaml | ||
- $ref: Strong.schema.yaml | ||
- $ref: Delete.schema.yaml | ||
- $ref: Verbatim.schema.yaml |