diff --git a/.eslintrc.json b/.eslintrc.json index dd5cffd..4c047d8 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -9,7 +9,6 @@ "eslint:recommended", "plugin:@typescript-eslint/eslint-recommended", "plugin:@typescript-eslint/recommended", - "plugin:jest/recommended", "plugin:prettier/recommended" ], "globals": { @@ -20,7 +19,7 @@ "parserOptions": { "ecmaVersion": 2018, "sourceType": "module", - "project": ["./tsconfig.json"] + "project": ["./src/tsconfig.json", "./test/tsconfig.json", "./scripts/tsconfig.json"] }, "plugins": ["@typescript-eslint", "no-skip-tests", "no-only-tests"], "rules": { @@ -41,7 +40,7 @@ "settings": { "import/resolver": { "node": { - "extensions": [".js", ".ts", ".spec.ts"] + "extensions": [".js", ".ts"] } } } diff --git a/.github/workflows/lint_and_unittests.yml b/.github/workflows/lint_and_unittests.yml index 0890cab..e2e5fe6 100644 --- a/.github/workflows/lint_and_unittests.yml +++ b/.github/workflows/lint_and_unittests.yml @@ -10,17 +10,17 @@ jobs: lint: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: actions/cache@v2 + - uses: actions/checkout@v4 + - uses: actions/cache@v4 with: path: ~/.npm key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} restore-keys: | ${{ runner.os }}-node- - - name: Use Node.js 12.x - uses: actions/setup-node@v1 + - name: Use Node.js + uses: actions/setup-node@v4 with: - node-version: 12.x + node-version: 20.x - run: npm install - run: npm run lint @@ -28,20 +28,19 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node-version: [12.x, 14.x] + node-version: [20.x] steps: - - uses: actions/checkout@v2 - - uses: actions/cache@v2 + - uses: actions/checkout@v4 + - uses: actions/cache@v4 with: path: ~/.npm key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} restore-keys: | ${{ runner.os }}-node- - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 + uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} - run: npm install - - name: Run the tests and generate coverage reportst + - name: Run the tests run: npm run test - - run: npm run build diff --git a/.gitignore b/.gitignore index 419a7de..77a4b80 100644 --- a/.gitignore +++ b/.gitignore @@ -9,4 +9,8 @@ index.js docs/_build docs/examples/*.md docs/nodes -docs/myst.schema.md \ No newline at end of file +docs/myst.schema.md +*.tsbuildinfo + +build +/test/compiled.ts diff --git a/docs/_config.yml b/docs/_config.yml deleted file mode 100644 index 62c7c0e..0000000 --- a/docs/_config.yml +++ /dev/null @@ -1,29 +0,0 @@ -# Jupyter Book settings -# Learn more at https://jupyterbook.org/customize/config.html - -title: '' -author: Executable Book Project -logo: images/logo-wide.svg - -# Force re-execution of notebooks on each build. -# See https://jupyterbook.org/content/execute.html -execute: - execute_notebooks: force - -# Define the name of the latex output file for PDF builds -latex: - latex_documents: - targetname: book.tex - -# Information about where the book exists on the web -repository: - url: https://github.com/executablebooks/myst-spec # Online location of your book - -# See https://jupyterbook.org/customize/config.html#add-a-link-to-your-repository -html: - # favicon: images/favicon.ico - # google_analytics_id: G-XXX or UA-XXX - use_issues_button: true - use_repository_button: true - use_edit_page_button: true - extra_navbar: Maintained by Executable Books diff --git a/docs/_toc.yml b/docs/_toc.yml deleted file mode 100644 index 68370e4..0000000 --- a/docs/_toc.yml +++ /dev/null @@ -1,16 +0,0 @@ -# Table of contents -# Learn more at https://jupyterbook.org/customize/toc.html - -format: jb-book -root: index -chapters: - - file: features/overview - - file: features/commonmark - - file: features/admonitions - - file: features/figures - - file: features/tables - - file: features/math - - file: features/references - - file: features/footnotes - - file: features/blocks - - file: myst.schema diff --git a/docs/commonmark.md b/docs/commonmark.md index 8f38ffe..b44d063 100644 --- a/docs/commonmark.md +++ b/docs/commonmark.md @@ -4,5 +4,4 @@ A basic Markdown Abstract Syntax Tree, mdast, is defined at [](https://github.co ## Deviations commonmark mdast -- According to the mdast spec [list items](https://github.com/syntax-tree/mdast#listitem) may only have [flow content](https://github.com/syntax-tree/mdast#flowcontent) children. However, according to the commonmark spec, list items may also be flow or phrasing content, such as [text](https://spec.commonmark.org/0.30/#example-255). This depends on spacing between the list items in the original document. In myst-spec, we choose to follow the commonmark spec and allow `ListItem` children to be `FlowContent` or `PhrasingContent`. - The commonmark spec presents `+++` as an invalid thematic break in [example 44](https://spec.commonmark.org/0.30/#example-44). However, in Myst `+++` is a block break, a non-commonmark feature. Therefore we simply removed example 44 in our test cases. diff --git a/docs/examples/blocks.yml b/docs/examples/blocks.yml index bb36e77..fb9badc 100644 --- a/docs/examples/blocks.yml +++ b/docs/examples/blocks.yml @@ -4,26 +4,23 @@ cases: type: root children: - type: blockBreak - myst: |- - +++ + myst: +++ - title: block break node - with metadata mdast: type: root children: - type: blockBreak meta: '{"meta": "data"}' - myst: |- - +++ {"meta": "data"} + myst: '+++ {"meta": "data"}' - title: block break node - with broken metadata mdast: type: root children: - type: blockBreak meta: '{"meta: data}' - myst: |- - +++ {"meta: data} + myst: '+++ {"meta: data}' - title: block break nodes - dividing flow content - id: blockbreak + id: blockBreak mdast: type: root children: diff --git a/docs/examples/cmark_spec_0.30.yml b/docs/examples/cmark_spec_0.30.yml index eb6d058..f8d0bcb 100644 --- a/docs/examples/cmark_spec_0.30.yml +++ b/docs/examples/cmark_spec_0.30.yml @@ -142,8 +142,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: list ordered: false spread: false @@ -151,8 +153,10 @@ cases: - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar - type: list ordered: false spread: false @@ -160,8 +164,10 @@ cases: - type: listItem spread: true children: - - type: text - value: baz + - type: paragraph + children: + - type: text + value: baz myst: " - foo\n - bar\n\t - baz\n" html: |-
!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~
+ html:!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~
- title: Backslash escapes - example 13 mdast: type: root @@ -268,8 +271,7 @@ cases: value: emphasis myst: | \\*emphasis* - html: |- -\emphasis
+ html:\emphasis
- title: Backslash escapes - example 16 mdast: type: root @@ -297,8 +299,7 @@ cases: value: \[\` myst: | `` \[\` `` - html: |- -\[\`
\[\`
# Ӓ Ϡ �
+ html:# Ӓ Ϡ �
- title: Entity and numeric character references - example 27 mdast: type: root @@ -437,8 +437,7 @@ cases: value: '" ആ ಫ' myst: | " ആ ಫ - html: |- -" ആ ಫ
+ html:" ആ ಫ
- title: Entity and numeric character references - example 28 mdast: type: root @@ -471,8 +470,7 @@ cases: value: '©' myst: | © - html: |- -©
+ html:©
- title: Entity and numeric character references - example 30 mdast: type: root @@ -483,8 +481,7 @@ cases: value: '&MadeUpEntity;' myst: | &MadeUpEntity; - html: |- -&MadeUpEntity;
+ html:&MadeUpEntity;
- title: Entity and numeric character references - example 31 mdast: type: root @@ -493,8 +490,7 @@ cases: value: myst: | - html: |- - + html: - title: Entity and numeric character references - example 32 mdast: type: root @@ -509,8 +505,7 @@ cases: value: foo myst: | [foo](/föö "föö") - html: |- - + html: - title: Entity and numeric character references - example 33 mdast: type: root @@ -527,8 +522,7 @@ cases: [foo] [foo]: /föö "föö" - html: |- - + html: - title: Entity and numeric character references - example 34 mdast: type: root @@ -553,8 +547,7 @@ cases: value: föö myst: | `föö` - html: |- -föö
föö
[a](url "tit")
+ html:[a](url "tit")
- title: Precedence - example 42 mdast: type: root @@ -663,13 +657,17 @@ cases: - type: listItem spread: true children: - - type: text - value: '`one' + - type: paragraph + children: + - type: text + value: '`one' - type: listItem spread: true children: - - type: text - value: two` + - type: paragraph + children: + - type: text + value: two` myst: | - `one - two` @@ -703,8 +701,7 @@ cases: value: '===' myst: | === - html: |- -===
+ html:===
- title: Thematic breaks - example 46 mdast: type: root @@ -774,8 +771,7 @@ cases: - type: thematicBreak myst: | _____________________________________ - html: |- --
+ html:-
- title: Thematic breaks - example 57 mdast: type: root @@ -863,8 +854,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: thematicBreak - type: list ordered: false @@ -873,8 +866,10 @@ cases: - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar myst: | - foo *** @@ -939,8 +934,10 @@ cases: - type: listItem spread: true children: - - type: text - value: Foo + - type: paragraph + children: + - type: text + value: Foo - type: thematicBreak - type: list ordered: false @@ -949,8 +946,10 @@ cases: - type: listItem spread: true children: - - type: text - value: Bar + - type: paragraph + children: + - type: text + value: Bar myst: | * Foo * * * @@ -974,8 +973,10 @@ cases: - type: listItem spread: true children: - - type: text - value: Foo + - type: paragraph + children: + - type: text + value: Foo - type: listItem spread: true children: @@ -1048,8 +1049,7 @@ cases: value: '####### foo' myst: | ####### foo - html: |- -####### foo
+ html:####### foo
- title: ATX headings - example 64 mdast: type: root @@ -1079,8 +1079,7 @@ cases: value: '## foo' myst: | \## foo - html: |- -## foo
+ html:## foo
- title: ATX headings - example 66 mdast: type: root @@ -1098,8 +1097,7 @@ cases: value: ' *baz*' myst: | # foo *bar* \*baz\* - html: |- -====
+ html:====
- title: Setext headings - example 98 mdast: type: root @@ -1759,8 +1751,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: thematicBreak myst: | - foo @@ -1816,8 +1810,7 @@ cases: myst: | \> foo ------ - html: |- -foo
foo
+ html:
- title: Fenced code blocks - example 127
mdast:
type: root
@@ -2372,8 +2365,9 @@ cases:
children:
- type: code
lang: ''
- value: "\n "
+ value: |2-
+
myst: |
```
@@ -2393,8 +2387,7 @@ cases:
myst: |
```
```
- html: |-
-
+ html:
- title: Fenced code blocks - example 131
mdast:
type: root
@@ -2661,8 +2654,7 @@ cases:
myst: |
````;
````
- html: |-
-
+ html:
- title: Fenced code blocks - example 145
mdast:
type: root
@@ -2944,8 +2936,7 @@ cases:
value:
myst: |
- html: |-
-
+ html:
- title: HTML blocks - example 160
mdast:
type: root
@@ -3105,8 +3096,7 @@ cases:
value:
myst: |
foo
foo
bar
+ html:bar
- title: Link reference definitions - example 209 mdast: type: root @@ -4017,8 +3996,7 @@ cases: value: '[foo]: /url "title" ok' myst: | [foo]: /url "title" ok - html: |- -[foo]: /url "title" ok
+ html: '[foo]: /url "title" ok
' - title: Link reference definitions - example 210 mdast: type: root @@ -4030,8 +4008,7 @@ cases: myst: | [foo]: /url "title" ok - html: |- -"title" ok
+ html:"title" ok
- title: Link reference definitions - example 211 mdast: type: root @@ -4402,7 +4379,6 @@ cases: # aaa - html: |-aaa
1234567890. not ok
+ html:1234567890. not ok
- title: List items - example 267 mdast: type: root @@ -5444,8 +5431,10 @@ cases: - type: listItem spread: true children: - - type: text - value: ok + - type: paragraph + children: + - type: text + value: ok myst: | 0. ok html: |- @@ -5464,8 +5453,10 @@ cases: - type: listItem spread: true children: - - type: text - value: ok + - type: paragraph + children: + - type: text + value: ok myst: | 003. ok html: |- @@ -5482,8 +5473,7 @@ cases: value: '-1. not ok' myst: | -1. not ok - html: |- --1. not ok
+ html:-1. not ok
- title: List items - example 270 mdast: type: root @@ -5677,8 +5667,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: paragraph children: - type: text @@ -5733,8 +5725,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: listItem spread: true children: @@ -5779,8 +5773,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo myst: | - foo @@ -5823,16 +5819,20 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: listItem spread: true children: [] - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar myst: | - foo - @@ -5854,16 +5854,20 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: listItem spread: true children: [] - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar myst: | - foo - @@ -5886,16 +5890,20 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: listItem spread: true children: [] - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar myst: | 1. foo 2. @@ -6174,10 +6182,12 @@ cases: - type: listItem spread: true children: - - type: text - value: |- - A paragraph - with two lines. + - type: paragraph + children: + - type: text + value: |- + A paragraph + with two lines. myst: |2 1. A paragraph with two lines. @@ -6269,8 +6279,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: list ordered: false spread: false @@ -6278,8 +6290,10 @@ cases: - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar - type: list ordered: false spread: false @@ -6287,8 +6301,10 @@ cases: - type: listItem spread: true children: - - type: text - value: baz + - type: paragraph + children: + - type: text + value: baz - type: list ordered: false spread: false @@ -6296,8 +6312,10 @@ cases: - type: listItem spread: true children: - - type: text - value: boo + - type: paragraph + children: + - type: text + value: boo myst: | - foo - bar @@ -6330,23 +6348,31 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar - type: listItem spread: true children: - - type: text - value: baz + - type: paragraph + children: + - type: text + value: baz - type: listItem spread: true children: - - type: text - value: boo + - type: paragraph + children: + - type: text + value: boo myst: | - foo - bar @@ -6371,8 +6397,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: list ordered: false spread: false @@ -6380,8 +6408,10 @@ cases: - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar myst: | 10) foo - bar @@ -6405,8 +6435,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: list ordered: false spread: false @@ -6414,8 +6446,10 @@ cases: - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar myst: | 10) foo - bar @@ -6444,8 +6478,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo myst: | - - foo html: |- @@ -6483,8 +6519,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo myst: | 1. - 2. foo html: |- @@ -6523,8 +6561,10 @@ cases: children: - type: text value: Bar - - type: text - value: baz + - type: paragraph + children: + - type: text + value: baz myst: | - # Foo - Bar @@ -6550,13 +6590,17 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar - type: list ordered: false spread: false @@ -6564,8 +6608,10 @@ cases: - type: listItem spread: true children: - - type: text - value: baz + - type: paragraph + children: + - type: text + value: baz myst: | - foo - bar @@ -6590,13 +6636,17 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar - type: list ordered: true start: 3 @@ -6605,8 +6655,10 @@ cases: - type: listItem spread: true children: - - type: text - value: baz + - type: paragraph + children: + - type: text + value: baz myst: | 1. foo 2. bar @@ -6634,13 +6686,17 @@ cases: - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar - type: listItem spread: true children: - - type: text - value: baz + - type: paragraph + children: + - type: text + value: baz myst: | Foo - bar @@ -6683,8 +6739,10 @@ cases: - type: listItem spread: true children: - - type: text - value: The number of doors is 6. + - type: paragraph + children: + - type: text + value: The number of doors is 6. myst: | The number of windows in my house is 1. The number of doors is 6. @@ -6752,8 +6810,10 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: list ordered: false spread: false @@ -6761,8 +6821,10 @@ cases: - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar - type: list ordered: false spread: false @@ -6811,13 +6873,17 @@ cases: - type: listItem spread: true children: - - type: text - value: foo + - type: paragraph + children: + - type: text + value: foo - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar - type: html value: - type: list @@ -6827,13 +6893,17 @@ cases: - type: listItem spread: true children: - - type: text - value: baz + - type: paragraph + children: + - type: text + value: baz - type: listItem spread: true children: - - type: text - value: bim + - type: paragraph + children: + - type: text + value: bim myst: | - foo - bar @@ -6917,38 +6987,52 @@ cases: - type: listItem spread: true children: - - type: text - value: a + - type: paragraph + children: + - type: text + value: a - type: listItem spread: true children: - - type: text - value: b + - type: paragraph + children: + - type: text + value: b - type: listItem spread: true children: - - type: text - value: c + - type: paragraph + children: + - type: text + value: c - type: listItem spread: true children: - - type: text - value: d + - type: paragraph + children: + - type: text + value: d - type: listItem spread: true children: - - type: text - value: e + - type: paragraph + children: + - type: text + value: e - type: listItem spread: true children: - - type: text - value: f + - type: paragraph + children: + - type: text + value: f - type: listItem spread: true children: - - type: text - value: g + - type: paragraph + children: + - type: text + value: g myst: | - a - b @@ -7026,25 +7110,33 @@ cases: - type: listItem spread: true children: - - type: text - value: a + - type: paragraph + children: + - type: text + value: a - type: listItem spread: true children: - - type: text - value: b + - type: paragraph + children: + - type: text + value: b - type: listItem spread: true children: - - type: text - value: c + - type: paragraph + children: + - type: text + value: c - type: listItem spread: true children: - - type: text - value: |- - d - - e + - type: paragraph + children: + - type: text + value: |- + d + - e myst: | - a - b @@ -7298,8 +7390,10 @@ cases: - type: listItem spread: true children: - - type: text - value: a + - type: paragraph + children: + - type: text + value: a - type: listItem spread: true children: @@ -7311,8 +7405,10 @@ cases: - type: listItem spread: true children: - - type: text - value: c + - type: paragraph + children: + - type: text + value: c myst: | - a - ``` @@ -7343,8 +7439,10 @@ cases: - type: listItem spread: true children: - - type: text - value: a + - type: paragraph + children: + - type: text + value: a - type: list ordered: false spread: false @@ -7363,8 +7461,10 @@ cases: - type: listItem spread: true children: - - type: text - value: d + - type: paragraph + children: + - type: text + value: d myst: | - a - b @@ -7394,8 +7494,10 @@ cases: - type: listItem spread: true children: - - type: text - value: a + - type: paragraph + children: + - type: text + value: a - type: blockquote children: - type: paragraph @@ -7405,8 +7507,10 @@ cases: - type: listItem spread: true children: - - type: text - value: c + - type: paragraph + children: + - type: text + value: c myst: | * a > b @@ -7432,8 +7536,10 @@ cases: - type: listItem spread: true children: - - type: text - value: a + - type: paragraph + children: + - type: text + value: a - type: blockquote children: - type: paragraph @@ -7446,8 +7552,10 @@ cases: - type: listItem spread: true children: - - type: text - value: d + - type: paragraph + children: + - type: text + value: d myst: | - a > b @@ -7477,8 +7585,10 @@ cases: - type: listItem spread: true children: - - type: text - value: a + - type: paragraph + children: + - type: text + value: a myst: | - a html: |- @@ -7496,8 +7606,10 @@ cases: - type: listItem spread: true children: - - type: text - value: a + - type: paragraph + children: + - type: text + value: a - type: list ordered: false spread: false @@ -7505,8 +7617,10 @@ cases: - type: listItem spread: true children: - - type: text - value: b + - type: paragraph + children: + - type: text + value: b myst: | - a - b @@ -7573,8 +7687,10 @@ cases: - type: listItem spread: true children: - - type: text - value: bar + - type: paragraph + children: + - type: text + value: bar - type: paragraph children: - type: text @@ -7616,13 +7732,17 @@ cases: - type: listItem spread: true children: - - type: text - value: b + - type: paragraph + children: + - type: text + value: b - type: listItem spread: true children: - - type: text - value: c + - type: paragraph + children: + - type: text + value: c - type: listItem spread: true children: @@ -7637,13 +7757,17 @@ cases: - type: listItem spread: true children: - - type: text - value: e + - type: paragraph + children: + - type: text + value: e - type: listItem spread: true children: - - type: text - value: f + - type: paragraph + children: + - type: text + value: f myst: | - a - b @@ -7681,8 +7805,7 @@ cases: value: lo` myst: | `hi`lo` - html: |- -hi
lo`
hi
lo`
foo
foo
foo ` bar
foo ` bar
``
``
``
``
a
a
b
b
foo bar baz
foo bar baz
foo
foo
foo bar baz
foo bar baz
foo\
bar`
foo\
bar`
foo`bar
foo`bar
foo `` bar
foo `` bar
*foo*
*foo*
[not a link](/foo
)
[not a link](/foo
)
<a href="
">`
<a href="
">`
<http://foo.bar.
baz>`
<http://foo.bar.
baz>`
```foo``
+ html:```foo``
- title: Code spans - example 348 mdast: type: root @@ -7966,8 +8070,7 @@ cases: value: '`foo' myst: | `foo - html: |- -`foo
+ html:`foo
- title: Code spans - example 349 mdast: type: root @@ -7980,8 +8083,7 @@ cases: value: bar myst: | `foo``bar`` - html: |- -`foobar
`foobar
foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 351 mdast: type: root @@ -8006,8 +8107,7 @@ cases: value: a * foo bar* myst: | a * foo bar* - html: |- -a * foo bar*
+ html:a * foo bar*
- title: Emphasis and strong emphasis - example 352 mdast: type: root @@ -8018,8 +8118,7 @@ cases: value: a*"foo"* myst: | a*"foo"* - html: |- -a*"foo"*
+ html:a*"foo"*
- title: Emphasis and strong emphasis - example 353 mdast: type: root @@ -8030,8 +8129,7 @@ cases: value: '* a *' myst: | * a * - html: |- -* a *
+ html:* a *
- title: Emphasis and strong emphasis - example 354 mdast: type: root @@ -8046,8 +8144,7 @@ cases: value: bar myst: | foo*bar* - html: |- -foobar
+ html:foobar
- title: Emphasis and strong emphasis - example 355 mdast: type: root @@ -8064,8 +8161,7 @@ cases: value: '78' myst: | 5*6*78 - html: |- -5678
+ html:5678
- title: Emphasis and strong emphasis - example 356 mdast: type: root @@ -8078,8 +8174,7 @@ cases: value: foo bar myst: | _foo bar_ - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 357 mdast: type: root @@ -8090,8 +8185,7 @@ cases: value: _ foo bar_ myst: | _ foo bar_ - html: |- -_ foo bar_
+ html:_ foo bar_
- title: Emphasis and strong emphasis - example 358 mdast: type: root @@ -8102,8 +8196,7 @@ cases: value: a_"foo"_ myst: | a_"foo"_ - html: |- -a_"foo"_
+ html:a_"foo"_
- title: Emphasis and strong emphasis - example 359 mdast: type: root @@ -8114,8 +8207,7 @@ cases: value: foo_bar_ myst: | foo_bar_ - html: |- -foo_bar_
+ html:foo_bar_
- title: Emphasis and strong emphasis - example 360 mdast: type: root @@ -8126,8 +8218,7 @@ cases: value: '5_6_78' myst: | 5_6_78 - html: |- -5_6_78
+ html:5_6_78
- title: Emphasis and strong emphasis - example 361 mdast: type: root @@ -8138,8 +8229,7 @@ cases: value: пристаням_стремятся_ myst: | пристаням_стремятся_ - html: |- -пристаням_стремятся_
+ html:пристаням_стремятся_
- title: Emphasis and strong emphasis - example 362 mdast: type: root @@ -8150,8 +8240,7 @@ cases: value: aa_"bb"_cc myst: | aa_"bb"_cc - html: |- -aa_"bb"_cc
+ html:aa_"bb"_cc
- title: Emphasis and strong emphasis - example 363 mdast: type: root @@ -8166,8 +8255,7 @@ cases: value: (bar) myst: | foo-_(bar)_ - html: |- -foo-(bar)
+ html:foo-(bar)
- title: Emphasis and strong emphasis - example 364 mdast: type: root @@ -8178,8 +8266,7 @@ cases: value: _foo* myst: | _foo* - html: |- -_foo*
+ html:_foo*
- title: Emphasis and strong emphasis - example 365 mdast: type: root @@ -8190,8 +8277,7 @@ cases: value: '*foo bar *' myst: | *foo bar * - html: |- -*foo bar *
+ html:*foo bar *
- title: Emphasis and strong emphasis - example 366 mdast: type: root @@ -8218,8 +8304,7 @@ cases: value: '*(*foo)' myst: | *(*foo) - html: |- -*(*foo)
+ html:*(*foo)
- title: Emphasis and strong emphasis - example 368 mdast: type: root @@ -8238,8 +8323,7 @@ cases: value: ) myst: | *(*foo*)* - html: |- -(foo)
+ html:(foo)
- title: Emphasis and strong emphasis - example 369 mdast: type: root @@ -8254,8 +8338,7 @@ cases: value: bar myst: | *foo*bar - html: |- -foobar
+ html:foobar
- title: Emphasis and strong emphasis - example 370 mdast: type: root @@ -8266,8 +8349,7 @@ cases: value: _foo bar _ myst: | _foo bar _ - html: |- -_foo bar _
+ html:_foo bar _
- title: Emphasis and strong emphasis - example 371 mdast: type: root @@ -8278,8 +8360,7 @@ cases: value: _(_foo) myst: | _(_foo) - html: |- -_(_foo)
+ html:_(_foo)
- title: Emphasis and strong emphasis - example 372 mdast: type: root @@ -8298,8 +8379,7 @@ cases: value: ) myst: | _(_foo_)_ - html: |- -(foo)
+ html:(foo)
- title: Emphasis and strong emphasis - example 373 mdast: type: root @@ -8310,8 +8390,7 @@ cases: value: _foo_bar myst: | _foo_bar - html: |- -_foo_bar
+ html:_foo_bar
- title: Emphasis and strong emphasis - example 374 mdast: type: root @@ -8322,8 +8401,7 @@ cases: value: _пристаням_стремятся myst: | _пристаням_стремятся - html: |- -_пристаням_стремятся
+ html:_пристаням_стремятся
- title: Emphasis and strong emphasis - example 375 mdast: type: root @@ -8336,8 +8414,7 @@ cases: value: foo_bar_baz myst: | _foo_bar_baz_ - html: |- -foo_bar_baz
+ html:foo_bar_baz
- title: Emphasis and strong emphasis - example 376 mdast: type: root @@ -8352,8 +8429,7 @@ cases: value: . myst: | _(bar)_. - html: |- -(bar).
+ html:(bar).
- title: Emphasis and strong emphasis - example 377 mdast: type: root @@ -8366,8 +8442,7 @@ cases: value: foo bar myst: | **foo bar** - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 378 mdast: type: root @@ -8378,8 +8453,7 @@ cases: value: '** foo bar**' myst: | ** foo bar** - html: |- -** foo bar**
+ html:** foo bar**
- title: Emphasis and strong emphasis - example 379 mdast: type: root @@ -8390,8 +8464,7 @@ cases: value: a**"foo"** myst: | a**"foo"** - html: |- -a**"foo"**
+ html:a**"foo"**
- title: Emphasis and strong emphasis - example 380 mdast: type: root @@ -8406,8 +8479,7 @@ cases: value: bar myst: | foo**bar** - html: |- -foobar
+ html:foobar
- title: Emphasis and strong emphasis - example 381 mdast: type: root @@ -8420,8 +8492,7 @@ cases: value: foo bar myst: | __foo bar__ - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 382 mdast: type: root @@ -8432,8 +8503,7 @@ cases: value: __ foo bar__ myst: | __ foo bar__ - html: |- -__ foo bar__
+ html:__ foo bar__
- title: Emphasis and strong emphasis - example 383 mdast: type: root @@ -8460,8 +8530,7 @@ cases: value: a__"foo"__ myst: | a__"foo"__ - html: |- -a__"foo"__
+ html:a__"foo"__
- title: Emphasis and strong emphasis - example 385 mdast: type: root @@ -8472,8 +8541,7 @@ cases: value: foo__bar__ myst: | foo__bar__ - html: |- -foo__bar__
+ html:foo__bar__
- title: Emphasis and strong emphasis - example 386 mdast: type: root @@ -8484,8 +8552,7 @@ cases: value: '5__6__78' myst: | 5__6__78 - html: |- -5__6__78
+ html:5__6__78
- title: Emphasis and strong emphasis - example 387 mdast: type: root @@ -8496,8 +8563,7 @@ cases: value: пристаням__стремятся__ myst: | пристаням__стремятся__ - html: |- -пристаням__стремятся__
+ html:пристаням__стремятся__
- title: Emphasis and strong emphasis - example 388 mdast: type: root @@ -8516,8 +8582,7 @@ cases: value: ', baz' myst: | __foo, __bar__, baz__ - html: |- -foo, bar, baz
+ html:foo, bar, baz
- title: Emphasis and strong emphasis - example 389 mdast: type: root @@ -8532,8 +8597,7 @@ cases: value: (bar) myst: | foo-__(bar)__ - html: |- -foo-(bar)
+ html:foo-(bar)
- title: Emphasis and strong emphasis - example 390 mdast: type: root @@ -8544,8 +8608,7 @@ cases: value: '**foo bar **' myst: | **foo bar ** - html: |- -**foo bar **
+ html:**foo bar **
- title: Emphasis and strong emphasis - example 391 mdast: type: root @@ -8556,8 +8619,7 @@ cases: value: '**(**foo)' myst: | **(**foo) - html: |- -**(**foo)
+ html:**(**foo)
- title: Emphasis and strong emphasis - example 392 mdast: type: root @@ -8576,8 +8638,7 @@ cases: value: ) myst: | *(**foo**)* - html: |- -(foo)
+ html:(foo)
- title: Emphasis and strong emphasis - example 393 mdast: type: root @@ -8625,8 +8686,7 @@ cases: value: '" foo' myst: | **foo "*bar*" foo** - html: |- -foo "bar" foo
+ html:foo "bar" foo
- title: Emphasis and strong emphasis - example 395 mdast: type: root @@ -8641,8 +8701,7 @@ cases: value: bar myst: | **foo**bar - html: |- -foobar
+ html:foobar
- title: Emphasis and strong emphasis - example 396 mdast: type: root @@ -8653,8 +8712,7 @@ cases: value: __foo bar __ myst: | __foo bar __ - html: |- -__foo bar __
+ html:__foo bar __
- title: Emphasis and strong emphasis - example 397 mdast: type: root @@ -8665,8 +8723,7 @@ cases: value: __(__foo) myst: | __(__foo) - html: |- -__(__foo)
+ html:__(__foo)
- title: Emphasis and strong emphasis - example 398 mdast: type: root @@ -8685,8 +8742,7 @@ cases: value: ) myst: | _(__foo__)_ - html: |- -(foo)
+ html:(foo)
- title: Emphasis and strong emphasis - example 399 mdast: type: root @@ -8697,8 +8753,7 @@ cases: value: __foo__bar myst: | __foo__bar - html: |- -__foo__bar
+ html:__foo__bar
- title: Emphasis and strong emphasis - example 400 mdast: type: root @@ -8709,8 +8764,7 @@ cases: value: __пристаням__стремятся myst: | __пристаням__стремятся - html: |- -__пристаням__стремятся
+ html:__пристаням__стремятся
- title: Emphasis and strong emphasis - example 401 mdast: type: root @@ -8723,8 +8777,7 @@ cases: value: foo__bar__baz myst: | __foo__bar__baz__ - html: |- -foo__bar__baz
+ html:foo__bar__baz
- title: Emphasis and strong emphasis - example 402 mdast: type: root @@ -8739,8 +8792,7 @@ cases: value: . myst: | __(bar)__. - html: |- -(bar).
+ html:(bar).
- title: Emphasis and strong emphasis - example 403 mdast: type: root @@ -8758,8 +8810,7 @@ cases: value: bar myst: | *foo [bar](/url)* - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 404 mdast: type: root @@ -8796,8 +8847,7 @@ cases: value: ' baz' myst: | _foo __bar__ baz_ - html: |- -foo bar baz
+ html:foo bar baz
- title: Emphasis and strong emphasis - example 406 mdast: type: root @@ -8816,8 +8866,7 @@ cases: value: ' baz' myst: | _foo _bar_ baz_ - html: |- -foo bar baz
+ html:foo bar baz
- title: Emphasis and strong emphasis - example 407 mdast: type: root @@ -8834,8 +8883,7 @@ cases: value: ' bar' myst: | __foo_ bar_ - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 408 mdast: type: root @@ -8852,8 +8900,7 @@ cases: value: bar myst: | *foo *bar** - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 409 mdast: type: root @@ -8872,8 +8919,7 @@ cases: value: ' baz' myst: | *foo **bar** baz* - html: |- -foo bar baz
+ html:foo bar baz
- title: Emphasis and strong emphasis - example 410 mdast: type: root @@ -8892,8 +8938,7 @@ cases: value: baz myst: | *foo**bar**baz* - html: |- -foobarbaz
+ html:foobarbaz
- title: Emphasis and strong emphasis - example 411 mdast: type: root @@ -8906,8 +8951,7 @@ cases: value: foo**bar myst: | *foo**bar* - html: |- -foo**bar
+ html:foo**bar
- title: Emphasis and strong emphasis - example 412 mdast: type: root @@ -8924,8 +8968,7 @@ cases: value: ' bar' myst: | ***foo** bar* - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 413 mdast: type: root @@ -8942,8 +8985,7 @@ cases: value: bar myst: | *foo **bar*** - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 414 mdast: type: root @@ -8960,8 +9002,7 @@ cases: value: bar myst: | *foo**bar*** - html: |- -foobar
+ html:foobar
- title: Emphasis and strong emphasis - example 415 mdast: type: root @@ -8980,8 +9021,7 @@ cases: value: baz myst: | foo***bar***baz - html: |- -foobarbaz
+ html:foobarbaz
- title: Emphasis and strong emphasis - example 416 mdast: type: root @@ -9002,8 +9042,7 @@ cases: value: '***baz' myst: | foo******bar*********baz - html: |- -foobar***baz
+ html:foobar***baz
- title: Emphasis and strong emphasis - example 417 mdast: type: root @@ -9028,8 +9067,7 @@ cases: value: ' bop' myst: | *foo **bar *baz* bim** bop* - html: |- -foo bar baz bim bop
+ html:foo bar baz bim bop
- title: Emphasis and strong emphasis - example 418 mdast: type: root @@ -9049,8 +9087,7 @@ cases: value: bar myst: | *foo [*bar*](/url)* - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 419 mdast: type: root @@ -9061,8 +9098,7 @@ cases: value: '** is not an empty emphasis' myst: | ** is not an empty emphasis - html: |- -** is not an empty emphasis
+ html:** is not an empty emphasis
- title: Emphasis and strong emphasis - example 420 mdast: type: root @@ -9073,8 +9109,7 @@ cases: value: '**** is not an empty strong emphasis' myst: | **** is not an empty strong emphasis - html: |- -**** is not an empty strong emphasis
+ html:**** is not an empty strong emphasis
- title: Emphasis and strong emphasis - example 421 mdast: type: root @@ -9092,8 +9127,7 @@ cases: value: bar myst: | **foo [bar](/url)** - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 422 mdast: type: root @@ -9130,8 +9164,7 @@ cases: value: ' baz' myst: | __foo _bar_ baz__ - html: |- -foo bar baz
+ html:foo bar baz
- title: Emphasis and strong emphasis - example 424 mdast: type: root @@ -9150,8 +9183,7 @@ cases: value: ' baz' myst: | __foo __bar__ baz__ - html: |- -foo bar baz
+ html:foo bar baz
- title: Emphasis and strong emphasis - example 425 mdast: type: root @@ -9168,8 +9200,7 @@ cases: value: ' bar' myst: | ____foo__ bar__ - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 426 mdast: type: root @@ -9186,8 +9217,7 @@ cases: value: bar myst: | **foo **bar**** - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 427 mdast: type: root @@ -9206,8 +9236,7 @@ cases: value: ' baz' myst: | **foo *bar* baz** - html: |- -foo bar baz
+ html:foo bar baz
- title: Emphasis and strong emphasis - example 428 mdast: type: root @@ -9226,8 +9255,7 @@ cases: value: baz myst: | **foo*bar*baz** - html: |- -foobarbaz
+ html:foobarbaz
- title: Emphasis and strong emphasis - example 429 mdast: type: root @@ -9244,8 +9272,7 @@ cases: value: ' bar' myst: | ***foo* bar** - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 430 mdast: type: root @@ -9262,8 +9289,7 @@ cases: value: bar myst: | **foo *bar*** - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 431 mdast: type: root @@ -9313,8 +9339,7 @@ cases: value: bar myst: | **foo [*bar*](/url)** - html: |- -foo bar
+ html:foo bar
- title: Emphasis and strong emphasis - example 433 mdast: type: root @@ -9325,8 +9350,7 @@ cases: value: __ is not an empty emphasis myst: | __ is not an empty emphasis - html: |- -__ is not an empty emphasis
+ html:__ is not an empty emphasis
- title: Emphasis and strong emphasis - example 434 mdast: type: root @@ -9337,8 +9361,7 @@ cases: value: ____ is not an empty strong emphasis myst: | ____ is not an empty strong emphasis - html: |- -____ is not an empty strong emphasis
+ html:____ is not an empty strong emphasis
- title: Emphasis and strong emphasis - example 435 mdast: type: root @@ -9349,8 +9372,7 @@ cases: value: foo *** myst: | foo *** - html: |- -foo ***
+ html:foo ***
- title: Emphasis and strong emphasis - example 436 mdast: type: root @@ -9365,8 +9387,7 @@ cases: value: '*' myst: | foo *\** - html: |- -foo *
+ html:foo *
- title: Emphasis and strong emphasis - example 437 mdast: type: root @@ -9381,8 +9402,7 @@ cases: value: _ myst: | foo *_* - html: |- -foo _
+ html:foo _
- title: Emphasis and strong emphasis - example 438 mdast: type: root @@ -9393,8 +9413,7 @@ cases: value: foo ***** myst: | foo ***** - html: |- -foo *****
+ html:foo *****
- title: Emphasis and strong emphasis - example 439 mdast: type: root @@ -9409,8 +9428,7 @@ cases: value: '*' myst: | foo **\*** - html: |- -foo *
+ html:foo *
- title: Emphasis and strong emphasis - example 440 mdast: type: root @@ -9425,8 +9443,7 @@ cases: value: _ myst: | foo **_** - html: |- -foo _
+ html:foo _
- title: Emphasis and strong emphasis - example 441 mdast: type: root @@ -9441,8 +9458,7 @@ cases: value: foo myst: | **foo* - html: |- -*foo
+ html:*foo
- title: Emphasis and strong emphasis - example 442 mdast: type: root @@ -9457,8 +9473,7 @@ cases: value: '*' myst: | *foo** - html: |- -foo*
+ html:foo*
- title: Emphasis and strong emphasis - example 443 mdast: type: root @@ -9473,8 +9488,7 @@ cases: value: foo myst: | ***foo** - html: |- -*foo
+ html:*foo
- title: Emphasis and strong emphasis - example 444 mdast: type: root @@ -9489,8 +9503,7 @@ cases: value: foo myst: | ****foo* - html: |- -***foo
+ html:***foo
- title: Emphasis and strong emphasis - example 445 mdast: type: root @@ -9505,8 +9518,7 @@ cases: value: '*' myst: | **foo*** - html: |- -foo*
+ html:foo*
- title: Emphasis and strong emphasis - example 446 mdast: type: root @@ -9521,8 +9533,7 @@ cases: value: '***' myst: | *foo**** - html: |- -foo***
+ html:foo***
- title: Emphasis and strong emphasis - example 447 mdast: type: root @@ -9533,8 +9544,7 @@ cases: value: foo ___ myst: | foo ___ - html: |- -foo ___
+ html:foo ___
- title: Emphasis and strong emphasis - example 448 mdast: type: root @@ -9549,8 +9559,7 @@ cases: value: _ myst: | foo _\__ - html: |- -foo _
+ html:foo _
- title: Emphasis and strong emphasis - example 449 mdast: type: root @@ -9565,8 +9574,7 @@ cases: value: '*' myst: | foo _*_ - html: |- -foo *
+ html:foo *
- title: Emphasis and strong emphasis - example 450 mdast: type: root @@ -9577,8 +9585,7 @@ cases: value: foo _____ myst: | foo _____ - html: |- -foo _____
+ html:foo _____
- title: Emphasis and strong emphasis - example 451 mdast: type: root @@ -9593,8 +9600,7 @@ cases: value: _ myst: | foo __\___ - html: |- -foo _
+ html:foo _
- title: Emphasis and strong emphasis - example 452 mdast: type: root @@ -9609,8 +9615,7 @@ cases: value: '*' myst: | foo __*__ - html: |- -foo *
+ html:foo *
- title: Emphasis and strong emphasis - example 453 mdast: type: root @@ -9625,8 +9630,7 @@ cases: value: foo myst: | __foo_ - html: |- -_foo
+ html:_foo
- title: Emphasis and strong emphasis - example 454 mdast: type: root @@ -9641,8 +9645,7 @@ cases: value: _ myst: | _foo__ - html: |- -foo_
+ html:foo_
- title: Emphasis and strong emphasis - example 455 mdast: type: root @@ -9657,8 +9660,7 @@ cases: value: foo myst: | ___foo__ - html: |- -_foo
+ html:_foo
- title: Emphasis and strong emphasis - example 456 mdast: type: root @@ -9673,8 +9675,7 @@ cases: value: foo myst: | ____foo_ - html: |- -___foo
+ html:___foo
- title: Emphasis and strong emphasis - example 457 mdast: type: root @@ -9689,8 +9690,7 @@ cases: value: _ myst: | __foo___ - html: |- -foo_
+ html:foo_
- title: Emphasis and strong emphasis - example 458 mdast: type: root @@ -9705,8 +9705,7 @@ cases: value: ___ myst: | _foo____ - html: |- -foo___
+ html:foo___
- title: Emphasis and strong emphasis - example 459 mdast: type: root @@ -9719,8 +9718,7 @@ cases: value: foo myst: | **foo** - html: |- -foo
+ html:foo
- title: Emphasis and strong emphasis - example 460 mdast: type: root @@ -9735,8 +9733,7 @@ cases: value: foo myst: | *_foo_* - html: |- -foo
+ html:foo
- title: Emphasis and strong emphasis - example 461 mdast: type: root @@ -9749,8 +9746,7 @@ cases: value: foo myst: | __foo__ - html: |- -foo
+ html:foo
- title: Emphasis and strong emphasis - example 462 mdast: type: root @@ -9765,8 +9761,7 @@ cases: value: foo myst: | _*foo*_ - html: |- -foo
+ html:foo
- title: Emphasis and strong emphasis - example 463 mdast: type: root @@ -9781,8 +9776,7 @@ cases: value: foo myst: | ****foo**** - html: |- -foo
+ html:foo
- title: Emphasis and strong emphasis - example 464 mdast: type: root @@ -9797,8 +9791,7 @@ cases: value: foo myst: | ____foo____ - html: |- -foo
+ html:foo
- title: Emphasis and strong emphasis - example 465 mdast: type: root @@ -9815,8 +9808,7 @@ cases: value: foo myst: | ******foo****** - html: |- -foo
+ html:foo
- title: Emphasis and strong emphasis - example 466 mdast: type: root @@ -9831,8 +9823,7 @@ cases: value: foo myst: | ***foo*** - html: |- -foo
+ html:foo
- title: Emphasis and strong emphasis - example 467 mdast: type: root @@ -9849,8 +9840,7 @@ cases: value: foo myst: | _____foo_____ - html: |- -foo
+ html:foo
- title: Emphasis and strong emphasis - example 468 mdast: type: root @@ -9865,8 +9855,7 @@ cases: value: ' baz_' myst: | *foo _bar* baz_ - html: |- -foo _bar baz_
+ html:foo _bar baz_
- title: Emphasis and strong emphasis - example 469 mdast: type: root @@ -9885,8 +9874,7 @@ cases: value: ' bam' myst: | *foo __bar *baz bim__ bam* - html: |- -foo bar *baz bim bam
+ html:foo bar *baz bim bam
- title: Emphasis and strong emphasis - example 470 mdast: type: root @@ -9901,8 +9889,7 @@ cases: value: bar baz myst: | **foo **bar baz** - html: |- -**foo bar baz
+ html:**foo bar baz
- title: Emphasis and strong emphasis - example 471 mdast: type: root @@ -9917,8 +9904,7 @@ cases: value: bar baz myst: | *foo *bar baz* - html: |- -*foo bar baz
+ html:*foo bar baz
- title: Emphasis and strong emphasis - example 472 mdast: type: root @@ -9934,8 +9920,7 @@ cases: value: bar* myst: | *[bar*](/url) - html: |- -*bar*
+ html:*bar*
- title: Emphasis and strong emphasis - example 473 mdast: type: root @@ -9951,8 +9936,7 @@ cases: value: bar_ myst: | _foo [bar_](/url) - html: |- -_foo bar_
+ html:_foo bar_
- title: Emphasis and strong emphasis - example 474 mdast: type: root @@ -9965,8 +9949,7 @@ cases: value:*
*
a *
a *
a _
a _
[link](/my uri)
+ html:[link](/my uri)
- title: Links - example 488 mdast: type: root @@ -10173,8 +10143,7 @@ cases: value: link myst: | [link]() - html: |- - + html: - title: Links - example 489 mdast: type: root @@ -10224,8 +10193,7 @@ cases: value: a myst: | [a]() - html: |- - + html: - title: Links - example 492 mdast: type: root @@ -10236,8 +10204,7 @@ cases: value: '[link]([link](<foo>)
+ html:[link](<foo>)
- title: Links - example 493 mdast: type: root @@ -10274,8 +10241,7 @@ cases: value: link myst: | [link](\(foo\)) - html: |- - + html: - title: Links - example 495 mdast: type: root @@ -10289,8 +10255,7 @@ cases: value: link myst: | [link](foo(and(bar))) - html: |- - + html: - title: Links - example 496 mdast: type: root @@ -10301,8 +10266,7 @@ cases: value: '[link](foo(and(bar))' myst: | [link](foo(and(bar)) - html: |- -[link](foo(and(bar))
+ html:[link](foo(and(bar))
- title: Links - example 497 mdast: type: root @@ -10316,8 +10280,7 @@ cases: value: link myst: | [link](foo\(and\(bar\)) - html: |- - + html: - title: Links - example 498 mdast: type: root @@ -10331,8 +10294,7 @@ cases: value: link myst: | [link]([link](/url "title "and" title")
+ html:[link](/url "title "and" title")
- title: Links - example 508 mdast: type: root @@ -10523,8 +10478,7 @@ cases: value: link myst: | [link](/url 'title "and" title') - html: |- - + html: - title: Links - example 509 mdast: type: root @@ -10540,8 +10494,7 @@ cases: myst: | [link]( /uri "title" ) - html: |- - + html: - title: Links - example 510 mdast: type: root @@ -10552,8 +10505,7 @@ cases: value: '[link] (/uri)' myst: | [link] (/uri) - html: |- -[link] (/uri)
+ html:[link] (/uri)
- title: Links - example 511 mdast: type: root @@ -10567,8 +10519,7 @@ cases: value: link [foo [bar]] myst: | [link [foo [bar]]](/uri) - html: |- - + html: - title: Links - example 512 mdast: type: root @@ -10579,8 +10530,7 @@ cases: value: '[link] bar](/uri)' myst: | [link] bar](/uri) - html: |- -[link] bar](/uri)
+ html:[link] bar](/uri)
- title: Links - example 513 mdast: type: root @@ -10596,8 +10546,7 @@ cases: value: bar myst: | [link [bar](/uri) - html: |- -[link bar
+ html:[link bar
- title: Links - example 514 mdast: type: root @@ -10611,8 +10560,7 @@ cases: value: link [bar myst: | [link \[bar](/uri) - html: |- - + html: - title: Links - example 515 mdast: type: root @@ -10655,8 +10603,7 @@ cases: alt: moon myst: | [](/uri) - html: |- - + html: - title: Links - example 517 mdast: type: root @@ -10674,8 +10621,7 @@ cases: value: '](/uri)' myst: | [foo [bar](/uri)](/uri) - html: |- -[foo bar](/uri)
+ html:[foo bar](/uri)
- title: Links - example 518 mdast: type: root @@ -10699,8 +10645,7 @@ cases: value: '](/uri)' myst: | [foo *[bar [baz](/uri)](/uri)*](/uri) - html: |- -[foo [bar baz](/uri)](/uri)
+ html:[foo [bar baz](/uri)](/uri)
- title: Links - example 519 mdast: type: root @@ -10712,8 +10657,7 @@ cases: alt: '[foo](uri2)' myst: | ](uri2)](uri3) - html: |- -*foo*
+ html:*foo*
- title: Links - example 521 mdast: type: root @@ -10744,8 +10687,7 @@ cases: value: foo *bar myst: | [foo *bar](baz*) - html: |- - + html: - title: Links - example 522 mdast: type: root @@ -10760,8 +10702,7 @@ cases: value: ' baz]' myst: | *foo [bar* baz] - html: |- -foo [bar baz]
+ html:foo [bar baz]
- title: Links - example 523 mdast: type: root @@ -10774,8 +10715,7 @@ cases: value:[foo
[foo
[foo](/uri)
[foo](/uri)
*foo*
+ html:*foo*
- title: Links - example 534 mdast: type: root @@ -11000,8 +10932,7 @@ cases: [foo *bar][ref]* [ref]: /uri - html: |- - + html: - title: Links - example 535 mdast: type: root @@ -11016,8 +10947,7 @@ cases: [foo[foo
[foo
[foo][ref]
[foo][ref]
[foo] bar
+ html:[foo] bar
- title: Links - example 542 mdast: type: root @@ -11167,8 +11092,7 @@ cases: [foo]: /url2 [bar][foo] - html: |- - + html: - title: Links - example 544 mdast: type: root @@ -11181,8 +11105,7 @@ cases: [bar][foo\!] [foo!]: /url - html: |- -[bar][foo!]
+ html:[bar][foo!]
- title: Links - example 545 mdast: type: root @@ -11255,8 +11178,7 @@ cases: [foo][ref\[] [ref\[]: /uri - html: |- - + html: - title: Links - example 549 mdast: type: root @@ -11272,8 +11194,7 @@ cases: [bar\\]: /uri [bar\\] - html: |- - + html: - title: Links - example 550 mdast: type: root @@ -11336,8 +11257,7 @@ cases: [foo][] [foo]: /url "title" - html: |- - + html: - title: Links - example 553 mdast: type: root @@ -11358,8 +11278,7 @@ cases: [*foo* bar][] [*foo* bar]: /url "title" - html: |- - + html: - title: Links - example 554 mdast: type: root @@ -11376,8 +11295,7 @@ cases: [Foo][] [foo]: /url "title" - html: |- - + html: - title: Links - example 555 mdast: type: root @@ -11418,8 +11336,7 @@ cases: [foo] [foo]: /url "title" - html: |- - + html: - title: Links - example 557 mdast: type: root @@ -11440,8 +11357,7 @@ cases: [*foo* bar] [*foo* bar]: /url "title" - html: |- - + html: - title: Links - example 558 mdast: type: root @@ -11466,8 +11382,7 @@ cases: [[*foo* bar]] [*foo* bar]: /url "title" - html: |- -[foo bar]
+ html:[foo bar]
- title: Links - example 559 mdast: type: root @@ -11485,8 +11400,7 @@ cases: [[bar [foo] [foo]: /url - html: |- -[[bar foo
+ html:[[bar foo
- title: Links - example 560 mdast: type: root @@ -11503,8 +11417,7 @@ cases: [Foo] [foo]: /url "title" - html: |- - + html: - title: Links - example 561 mdast: type: root @@ -11522,8 +11435,7 @@ cases: [foo] bar [foo]: /url - html: |- -foo bar
+ html:foo bar
- title: Links - example 562 mdast: type: root @@ -11536,8 +11448,7 @@ cases: \[foo] [foo]: /url "title" - html: |- -[foo]
+ html:[foo]
- title: Links - example 563 mdast: type: root @@ -11555,8 +11466,7 @@ cases: [foo*]: /url *[foo*] - html: |- -*foo*
+ html:*foo*
- title: Links - example 564 mdast: type: root @@ -11573,8 +11483,7 @@ cases: [foo]: /url1 [bar]: /url2 - html: |- - + html: - title: Links - example 565 mdast: type: root @@ -11590,8 +11499,7 @@ cases: [foo][] [foo]: /url1 - html: |- - + html: - title: Links - example 566 mdast: type: root @@ -11607,8 +11515,7 @@ cases: [foo]() [foo]: /url1 - html: |- - + html: - title: Links - example 567 mdast: type: root @@ -11626,8 +11533,7 @@ cases: [foo](not a link) [foo]: /url1 - html: |- -foo(not a link)
+ html:foo(not a link)
- title: Links - example 568 mdast: type: root @@ -11645,8 +11551,7 @@ cases: [foo][bar][baz] [baz]: /url - html: |- -[foo]bar
+ html:[foo]bar
- title: Links - example 569 mdast: type: root @@ -11668,8 +11573,7 @@ cases: [baz]: /url1 [bar]: /url2 - html: |- - + html: - title: Links - example 570 mdast: type: root @@ -11688,8 +11592,7 @@ cases: [baz]: /url1 [foo]: /url2 - html: |- -[foo]bar
+ html:[foo]bar
- title: Images - example 571 mdast: type: root @@ -11702,8 +11605,7 @@ cases: title: title myst: |  - html: |- -My
My
![foo]
+ html:![foo]
- title: Images - example 592 mdast: type: root @@ -12031,8 +11915,7 @@ cases: \![foo] [foo]: /url "title" - html: |- -!foo
+ html:!foo
- title: Autolinks - example 593 mdast: type: root @@ -12046,8 +11929,7 @@ cases: value: http://foo.bar.baz myst: |<http://foo.bar/baz bim>
+ html:<http://foo.bar/baz bim>
- title: Autolinks - example 602 mdast: type: root @@ -12179,8 +12054,7 @@ cases: value: http://example.com/\[\ myst: |<foo+@bar.example.com>
+ html:<foo+@bar.example.com>
- title: Autolinks - example 606 mdast: type: root @@ -12234,8 +12106,7 @@ cases: value: <> myst: | <> - html: |- -<>
+ html:<>
- title: Autolinks - example 607 mdast: type: root @@ -12246,8 +12117,7 @@ cases: value: < http://foo.bar > myst: | < http://foo.bar > - html: |- -< http://foo.bar >
+ html:< http://foo.bar >
- title: Autolinks - example 608 mdast: type: root @@ -12258,8 +12128,7 @@ cases: value:<m:abc>
+ html:<m:abc>
- title: Autolinks - example 609 mdast: type: root @@ -12270,8 +12139,7 @@ cases: value:<foo.bar.baz>
+ html:<foo.bar.baz>
- title: Autolinks - example 610 mdast: type: root @@ -12282,8 +12150,7 @@ cases: value: http://example.com myst: | http://example.com - html: |- -http://example.com
+ html:http://example.com
- title: Autolinks - example 611 mdast: type: root @@ -12294,8 +12161,7 @@ cases: value: foo@bar.example.com myst: | foo@bar.example.com - html: |- -foo@bar.example.com
+ html:foo@bar.example.com
- title: Raw HTML - example 612 mdast: type: root @@ -12310,8 +12176,7 @@ cases: value:Foo
Foo
<33> <__>
+ html:<33> <__>
- title: Raw HTML - example 618 mdast: type: root @@ -12396,8 +12258,7 @@ cases: value: myst: | - html: |- -<a h*#ref="hi">
+ html:<a h*#ref="hi">
- title: Raw HTML - example 619 mdast: type: root @@ -12408,8 +12269,7 @@ cases: value: - html: |- -<a href="hi'> <a href=hi'>
+ html:<a href="hi'> <a href=hi'>
- title: Raw HTML - example 620 mdast: type: root @@ -12442,8 +12302,7 @@ cases: value: myst: | - html: |- -<a href='bar'title=title>
+ html:<a href='bar'title=title>
- title: Raw HTML - example 622 mdast: type: root @@ -12456,8 +12315,7 @@ cases: value:</a href="foo">
+ html:</a href="foo">
- title: Raw HTML - example 624 mdast: type: root @@ -12498,8 +12355,7 @@ cases: value: foo myst: | foo - html: |- -foo <!-- not a comment -- two hyphens -->
+ html:foo <!-- not a comment -- two hyphens -->
- title: Raw HTML - example 626 mdast: type: root @@ -12531,8 +12387,7 @@ cases: value: myst: | foo - html: |- -foo
+ html:foo
- title: Raw HTML - example 628 mdast: type: root @@ -12545,8 +12400,7 @@ cases: value: myst: | foo - html: |- -foo
+ html:foo
- title: Raw HTML - example 629 mdast: type: root @@ -12559,8 +12413,7 @@ cases: value: &<]]> myst: | foo &<]]> - html: |- -foo &<]]>
+ html:foo &<]]>
- title: Raw HTML - example 630 mdast: type: root @@ -12573,8 +12426,7 @@ cases: value: myst: | foo - html: |- - + html: - title: Raw HTML - example 631 mdast: type: root @@ -12587,8 +12439,7 @@ cases: value: myst: | foo - html: |- - + html: - title: Raw HTML - example 632 mdast: type: root @@ -12599,8 +12450,7 @@ cases: value: myst: | - html: |- -<a href=""">
+ html:<a href=""">
- title: Hard line breaks - example 633 mdast: type: root @@ -12735,8 +12585,7 @@ cases: myst: | `code span` - html: |- -code span
code span
code\ span
code\ span
foo\
+ html:foo\
- title: Hard line breaks - example 645 mdast: type: root @@ -12804,8 +12651,7 @@ cases: value: foo myst: | foo - html: |- -foo
+ html:foo
- title: Hard line breaks - example 646 mdast: type: root @@ -12817,8 +12663,7 @@ cases: value: foo\ myst: | ### foo\ - html: |- -hello $.;'there
+ html:hello $.;'there
- title: Textual content - example 651 mdast: type: root @@ -12886,8 +12729,7 @@ cases: value: Foo χρῆν myst: | Foo χρῆν - html: |- -Foo χρῆν
+ html:Foo χρῆν
- title: Textual content - example 652 mdast: type: root @@ -12898,5 +12740,4 @@ cases: value: Multiple spaces myst: | Multiple spaces - html: |- -Multiple spaces
+ html:Multiple spaces
diff --git a/docs/examples/comments.yml b/docs/examples/comments.yml index 72b151e..43893b0 100644 --- a/docs/examples/comments.yml +++ b/docs/examples/comments.yml @@ -5,12 +5,10 @@ cases: children: - type: mystComment value: A comment - myst: |- - % A comment - html: |- - + myst: '% A comment' + html: - title: Comment between paragraphs - id: comment + id: mystComment mdast: type: root children: diff --git a/docs/examples/commonmark.breaks.yml b/docs/examples/commonmark.breaks.yml index 7d3743e..d996db5 100644 --- a/docs/examples/commonmark.breaks.yml +++ b/docs/examples/commonmark.breaks.yml @@ -1,5 +1,6 @@ cases: - title: CommonMark hard breaks + id: break mdast: type: root children: @@ -13,13 +14,12 @@ cases: myst: |- hard\ break - html: |- -hard
break
hard
break
thematic
break
- latex: |- thematic diff --git a/docs/examples/commonmark.code.yml b/docs/examples/commonmark.code.yml index c14b1c5..b46ccbc 100644 --- a/docs/examples/commonmark.code.yml +++ b/docs/examples/commonmark.code.yml @@ -44,7 +44,6 @@ cases: children: - type: text value: 'Some JSON:' - - type: code lang: '' value: |- diff --git a/docs/examples/commonmark.headings.yml b/docs/examples/commonmark.headings.yml index a17eea1..a9f1ff4 100644 --- a/docs/examples/commonmark.headings.yml +++ b/docs/examples/commonmark.headings.yml @@ -9,10 +9,8 @@ cases: children: - type: text value: Heading! - myst: |- - ### Heading! - html: |- -*some text*
*some text*
*some text*
*some text*
*some text*
Search engine: https://www.google.com
- latex: |- - Search engine: \url{https://google.com} + myst: 'Search engine:Search engine: https://www.google.com
+ latex: 'Search engine: \url{https://google.com}' - title: CommonMark inline link id: link mdast: @@ -40,12 +39,9 @@ cases: children: - type: text value: search engine - myst: |- - [search engine](https://www.google.com "Google") - html: |- - - latex: |- - Search engine: \href{https://google.com}{search engine} + myst: '[search engine](https://www.google.com "Google")' + html: + latex: 'Search engine: \href{https://google.com}{search engine}' - title: CommonMark inline image mdast: type: root @@ -56,11 +52,9 @@ cases: url: src alt: alt title: title - myst: |- -  + myst: '' html: |-
Something
+ myst: Something + html:Something
- title: CommomMark two paragraphs mdast: type: root @@ -58,9 +56,10 @@ cases: value: literal text - type: text value: ', *escaped symbols*' - myst: |- - **strong**, _emphasis_, `literal text`, \*escaped symbols\* - html: |- -strong, emphasis, literal text
, *escaped symbols*
strong, emphasis, literal text
,
+ *escaped symbols*
To be or not to be
diff --git a/docs/examples/directives.admonitions.simple.yml b/docs/examples/directives.admonitions.simple.yml index 0cd0fb7..599ec59 100644 --- a/docs/examples/directives.admonitions.simple.yml +++ b/docs/examples/directives.admonitions.simple.yml @@ -14,6 +14,7 @@ cases: children: - type: text value: Admonition attention + value: '' myst: |- ```{attention} Admonition attention ``` @@ -26,7 +27,6 @@ cases: \begin{mdframed}[style=attention] Admonition attention \end{mdframed} - - title: caution mdast: type: root @@ -42,6 +42,7 @@ cases: children: - type: text value: Admonition caution + value: '' myst: |- ```{caution} Admonition caution ``` @@ -54,7 +55,6 @@ cases: \begin{mdframed}[style=caution] Admonition caution \end{mdframed} - - title: danger mdast: type: root @@ -70,6 +70,7 @@ cases: children: - type: text value: Admonition danger + value: '' myst: |- ```{danger} Admonition danger ``` @@ -82,7 +83,6 @@ cases: \begin{mdframed}[style=danger] Admonition danger \end{mdframed} - - title: error mdast: type: root @@ -98,6 +98,7 @@ cases: children: - type: text value: Admonition error + value: '' myst: |- ```{error} Admonition error ``` @@ -110,7 +111,6 @@ cases: \begin{mdframed}[style=error] Admonition error \end{mdframed} - - title: important mdast: type: root @@ -126,6 +126,7 @@ cases: children: - type: text value: Admonition important + value: '' myst: |- ```{important} Admonition important ``` @@ -138,7 +139,6 @@ cases: \begin{mdframed}[style=important] Admonition important \end{mdframed} - - title: hint mdast: type: root @@ -154,6 +154,7 @@ cases: children: - type: text value: Admonition hint + value: '' myst: |- ```{hint} Admonition hint ``` @@ -166,7 +167,6 @@ cases: \begin{mdframed}[style=hint] Admonition hint \end{mdframed} - - title: note mdast: type: root @@ -182,6 +182,7 @@ cases: children: - type: text value: Admonition note + value: '' myst: |- ```{note} Admonition note ``` @@ -194,7 +195,6 @@ cases: \begin{mdframed}[style=note] Admonition note \end{mdframed} - - title: seealso mdast: type: root @@ -210,6 +210,7 @@ cases: children: - type: text value: Admonition seealso + value: '' myst: |- ```{seealso} Admonition seealso ``` @@ -222,7 +223,6 @@ cases: \begin{mdframed}[style=seealso] Admonition seealso \end{mdframed} - - title: tip mdast: type: root @@ -238,6 +238,7 @@ cases: children: - type: text value: Admonition tip + value: '' myst: |- ```{tip} Admonition tip ``` @@ -250,7 +251,6 @@ cases: \begin{mdframed}[style=tip] Admonition tip \end{mdframed} - - title: warning mdast: type: root @@ -266,6 +266,7 @@ cases: children: - type: text value: Admonition warning + value: '' myst: |- ```{warning} Admonition warning ``` diff --git a/docs/examples/directives.admonitions.yml b/docs/examples/directives.admonitions.yml index df7e11b..b155871 100644 --- a/docs/examples/directives.admonitions.yml +++ b/docs/examples/directives.admonitions.yml @@ -24,7 +24,7 @@ cases: - type: text value: title - type: text - value: '.' + value: . myst: |- ```{admonition} This is a title An example of an admonition with a _title_. @@ -39,7 +39,6 @@ cases: \section*{This is a title} An example of an admonition with a \textit{title}. \end{mdframed} - - title: Note with no title mdast: type: root @@ -68,7 +67,6 @@ cases: \begin{mdframed}[style=note] Please note! \end{mdframed} - - title: Note with split title mdast: type: root @@ -88,9 +86,7 @@ cases: - type: paragraph children: - type: text - value: |- - and an example of a note admonition. - + value: and an example of a note admonition. - title: Danger on a single line mdast: type: root @@ -106,7 +102,7 @@ cases: children: - type: text value: This is a title! - + value: '' - title: Admonition with overridding class name mdast: type: root @@ -136,9 +132,9 @@ cases: - type: emphasis children: - type: text - value: 'class' + value: class - type: text - value: '.' + value: . myst: |- ```{admonition} This is a title! :class: tip @@ -155,7 +151,6 @@ cases: \section*{This is a title!} An example of a general \texttt{admonition} with a custom \textit{class}. \end{mdframed} - - title: See Also with overridding class name of tip description: The `tip` class must be appended to the start mdast: @@ -165,8 +160,7 @@ cases: name: seealso options: class: tip - value: |- - Tip class comes first!! + value: Tip class comes first!! children: - type: admonition kind: seealso @@ -175,8 +169,7 @@ cases: - type: paragraph children: - type: text - value: |- - Tip class comes first!! + value: Tip class comes first!! myst: |- ```{seealso} :class: tip diff --git a/docs/examples/directives.code.yml b/docs/examples/directives.code.yml index 583ccd7..1909e9a 100644 --- a/docs/examples/directives.code.yml +++ b/docs/examples/directives.code.yml @@ -28,7 +28,6 @@ cases:- - title: Code directive, starting line mdast: type: root @@ -66,7 +65,6 @@ cases:def five(): return 5
- - title: Code-block starting line mdast: type: root @@ -106,7 +104,6 @@ cases:def five(): return 5
- - title: Code-block directive shows line numbers without explicit linenos flag mdast: type: root @@ -148,7 +145,6 @@ cases: value: |- def five(): return 5 - - title: Code-block directive - emphasize lines mdast: type: root diff --git a/docs/examples/directives.figure.yml b/docs/examples/directives.figure.yml index 8b20228..60f3f37 100644 --- a/docs/examples/directives.figure.yml +++ b/docs/examples/directives.figure.yml @@ -29,7 +29,6 @@ cases: children: - type: text value: Something! A legend!? - myst: |- ```{figure} https://via.placeholder.com/150 This is the figure caption! @@ -46,7 +45,6 @@ cases:def five(): return 5
Something! A legend!?
Figure 1This is the figure caption!
- - title: Named figure with no space between options in directive mdast: type: root @@ -169,7 +165,6 @@ cases:Figure 1This is the figure caption!
- - title: Two figures mdast: type: root diff --git a/docs/examples/directives.generic.yml b/docs/examples/directives.generic.yml index ce5ebda..5321868 100644 --- a/docs/examples/directives.generic.yml +++ b/docs/examples/directives.generic.yml @@ -10,6 +10,7 @@ cases: :b: two ABC directive + children: [] myst: |- ```{abc} :a: one @@ -38,6 +39,7 @@ cases: :b: two ABC directive + children: [] myst: |- ```{abc} foo bar :a: one diff --git a/docs/examples/directives.image.yml b/docs/examples/directives.image.yml index 8ae3cc9..d642296 100644 --- a/docs/examples/directives.image.yml +++ b/docs/examples/directives.image.yml @@ -9,13 +9,11 @@ cases: - type: image url: fun-fish.png alt: fishy - myst: |- -  + myst: '' html: |-
Here's a simple footnote,1 and here's a longer one.2
+ html: >- +Here's a simple footnote,1 and here's + a longer one.2
+see {eq}
matrix
see {eq}
matrix
{numref}
my-figure
{numref}
my-figure
{numref}
my-figure
{numref}
my-figure
{numref}
my - figure
{numref}
my - figure
see Cool caption!
+ html: >- +see Cool + caption!
+see My Table
+ html: >- +see My + Table
+Table 1Caption text
diff --git a/docs/examples/references.target.yml b/docs/examples/references.target.yml index b50662f..da0d156 100644 --- a/docs/examples/references.target.yml +++ b/docs/examples/references.target.yml @@ -1,6 +1,6 @@ cases: - title: Header with id label - id: target + id: mystTarget mdast: type: root children: @@ -14,5 +14,4 @@ cases: myst: |- (my_ID)= # My Header - html: |- -{abc}
ABC role
{abc}
ABC
+ role
Well CSS is cool?
- + myst: Well {abbr}`CSS (Cascading Style Sheets)` is cool? + html:Well CSS is cool?
- title: Abbreviation Without Title mdast: type: root @@ -42,11 +39,8 @@ cases: value: CSS - type: text value: ' is cool?' - myst: |- - Well {abbr}`CSS` is cool? - html: |- -Well CSS is cool?
- + myst: Well {abbr}`CSS` is cool? + html:Well CSS is cool?
- title: Abbreviation with poor brackets mdast: type: root @@ -62,7 +56,5 @@ cases: children: - type: text value: CSS (Cascading) Style - myst: |- - {abbr}`CSS (Cascading) Style( Sheets)` - html: |- -CSS (Cascading) Style
+ myst: '{abbr}`CSS (Cascading) Style( Sheets)`' + html:CSS (Cascading) Style
diff --git a/docs/examples/roles.html.yml b/docs/examples/roles.html.yml index fd28e8c..0069259 100644 --- a/docs/examples/roles.html.yml +++ b/docs/examples/roles.html.yml @@ -17,13 +17,9 @@ cases: value: '2' - type: text value: O - myst: |- - H{sub}`2`O - html: |- -H2O
- latex: |- - H\textsubscript{2}O - + myst: H{sub}`2`O + html:H2O
+ latex: H\textsubscript{2}O - title: Subscript spelled out id: subscript mdast: @@ -43,13 +39,9 @@ cases: value: '2' - type: text value: O - myst: |- - H{subscript}`2`O - html: |- -H2O
- latex: |- - H\textsubscript{2}O - + myst: H{subscript}`2`O + html:H2O
+ latex: H\textsubscript{2}O - title: Superscript mdast: type: root @@ -65,14 +57,11 @@ cases: - type: superscript children: - type: text - value: 'th' + value: th - type: text value: ' of July' - myst: |- - 4{sup}`th` of July - html: |- -4th of July
- + myst: 4{sup}`th` of July + html:4th of July
- title: Superscript spelled out id: superscript mdast: @@ -89,10 +78,8 @@ cases: - type: superscript children: - type: text - value: 'th' + value: th - type: text value: ' of July' - myst: |- - 4{superscript}`th` of July - html: |- -4th of July
+ myst: 4{superscript}`th` of July + html:4th of July
diff --git a/docs/examples/roles.math.yml b/docs/examples/roles.math.yml index 97c38d5..b385e3d 100644 --- a/docs/examples/roles.math.yml +++ b/docs/examples/roles.math.yml @@ -1,6 +1,6 @@ cases: - title: Math role - id: inlinemath + id: inlineMath mdast: type: root children: @@ -14,7 +14,5 @@ cases: children: - type: inlineMath value: e=mc^2 - myst: |- - This is genius {math}`e=mc^2` - html: |- -This is genius e=mc^2
+ myst: This is genius {math}`e=mc^2` + html:This is genius e=mc^2
diff --git a/docs/features/admonitions.md b/docs/features/admonitions.md index c224e62..b6e0a9f 100644 --- a/docs/features/admonitions.md +++ b/docs/features/admonitions.md @@ -8,12 +8,12 @@ Here is a note! ## Specification -```{include} ../nodes/admonition.md +```{embed} spec:admonition ``` ## Example -```{include} ../examples/admonition.md +```{embed} example:admonition ``` diff --git a/docs/features/basic.md b/docs/features/basic.md index 9310c39..ead1d79 100644 --- a/docs/features/basic.md +++ b/docs/features/basic.md @@ -2,30 +2,30 @@ ## Subscript -```{include} ../nodes/subscript.md +```{embed} spec:subscript ``` -```{include} ../examples/subscript.md +```{embed} example:subscript ``` ## Superscript -```{include} ../nodes/superscript.md +```{embed} spec:superscript ``` -```{include} ../examples/superscript.md +```{embed} example:superscript ``` ## Abbreviations -```{include} ../nodes/abbreviation.md +```{embed} spec:abbreviation ``` -```{include} ../examples/abbreviation.md +```{embed} example:abbreviation ``` diff --git a/docs/features/blocks.md b/docs/features/blocks.md index 9b0d0a7..fa7ef0a 100644 --- a/docs/features/blocks.md +++ b/docs/features/blocks.md @@ -7,12 +7,12 @@ ### Specification -```{include} ../nodes/blockbreak.md +```{embed} spec:blockbreak ``` ### Example -```{include} ../examples/blockbreak.md +```{embed} example:blockbreak ``` ## Comments @@ -22,12 +22,12 @@ You may add comments by putting the `%` character at the beginning of a line. Th ### Specification -```{include} ../nodes/comment.md +```{embed} spec:comment ``` ### Example -```{include} ../examples/comment.md +```{embed} example:comment ``` ````{important} diff --git a/docs/features/commonmark.md b/docs/features/commonmark.md index bb80a54..fcb59ef 100644 --- a/docs/features/commonmark.md +++ b/docs/features/commonmark.md @@ -8,11 +8,11 @@ MyST (Markedly Structured Text) was designed to make it easier to create publish ### Headings -```{include} ../nodes/heading.md +```{embed} spec:heading ``` -```{include} ../examples/heading.md +```{embed} example:heading ``` @@ -22,21 +22,21 @@ Reference headings by preceding headers with a `(label)=`. See [](./references.m ### Lists -```{include} ../nodes/list.md +```{embed} spec:list ``` -```{include} ../examples/list.md +```{embed} example:list ``` ### Code -```{include} ../nodes/code.md +```{embed} spec:code ``` -```{include} ../examples/code.md +```{embed} example:code ``` @@ -49,21 +49,21 @@ Create code-blocks with additional highlighting using the `code-block` directive ### Blockquotes -```{include} ../nodes/blockquote.md +```{embed} spec:blockquote ``` -```{include} ../examples/blockquote.md +```{embed} example:blockquote ``` ### Thematic Break -```{include} ../nodes/break.md +```{embed} spec:break ``` -```{include} ../examples/break.md +```{embed} example:break ``` @@ -74,7 +74,7 @@ which is used to structurally seperate content. ### Link Definitions -```{include} ../nodes/definition.md +```{embed} spec:definition ``` @@ -85,21 +85,21 @@ This syntax is also similar to [](./footnotes.md). ### Paragraph -```{include} ../nodes/paragraph.md +```{embed} spec:paragraph ``` -```{include} ../examples/paragraph.md +```{embed} example:paragraph ``` ### Valid HTML -```{include} ../nodes/html.md +```{embed} spec:html ``` -```{include} ../examples/html.md +```{embed} example:html ``` @@ -109,11 +109,11 @@ This syntax is also similar to [](./footnotes.md). ### Inline links -```{include} ../nodes/link.md +```{embed} spec:link ``` -```{include} ../examples/link.md +```{embed} example:link ``` @@ -123,11 +123,11 @@ This syntax is also similar to [](./footnotes.md). ### Inline images -```{include} ../nodes/image.md +```{embed} spec:image ``` -```{include} ../examples/image.md +```{embed} example:image ``` @@ -139,23 +139,23 @@ This syntax is also similar to [](./footnotes.md). #### Emphasis -```{include} ../nodes/emphasis.md +```{embed} spec:emphasis ``` #### Strong -```{include} ../nodes/strong.md +```{embed} spec:strong ``` #### Inline Code -```{include} ../nodes/inlinecode.md +```{embed} spec:inlinecode ``` -```{include} ../examples/formatting.md +```{embed} example:formatting ``` diff --git a/docs/features/figures.md b/docs/features/figures.md index b1ff952..2a6d825 100644 --- a/docs/features/figures.md +++ b/docs/features/figures.md @@ -2,13 +2,13 @@ ## Image Node Specification -```{include} ../nodes/image.md +```{embed} spec:image ``` ## Image Node Example -```{include} ../examples/image.md +```{embed} example:image ``` @@ -16,13 +16,13 @@ ## Container Node Specification -```{include} ../nodes/container.md +```{embed} spec:container ``` ## Container Node Example -```{include} ../examples/container.md +```{embed} example:container ``` diff --git a/docs/features/footnotes.md b/docs/features/footnotes.md index d1ac871..99b73ee 100644 --- a/docs/features/footnotes.md +++ b/docs/features/footnotes.md @@ -7,18 +7,18 @@ Footnotes use the standard Markdown syntax, including a numbered reference to th ## Footnote Definition Node Specification -```{include} ../nodes/footnotedefinition.md +```{embed} spec:footnotedefinition ``` ## Footnote Reference Node Specification -```{include} ../nodes/footnotereference.md +```{embed} spec:footnotereference ``` ## Footnote Node Example -```{include} ../examples/footnote.md +```{embed} example:footnote ``` diff --git a/docs/features/math.md b/docs/features/math.md index b3fcdc6..e147c1d 100644 --- a/docs/features/math.md +++ b/docs/features/math.md @@ -4,13 +4,13 @@ ### Specification -```{include} ../nodes/math.md +```{embed} spec:math ``` ### Example -```{include} ../examples/math.md +```{embed} example:math ``` @@ -18,13 +18,13 @@ ### Specification -```{include} ../nodes/inlinemath.md +```{embed} spec:inlinemath ``` ### Example -```{include} ../examples/inlinemath.md +```{embed} example:inlinemath ``` diff --git a/docs/features/overview.md b/docs/features/overview.md index aecf4aa..7092ee8 100644 --- a/docs/features/overview.md +++ b/docs/features/overview.md @@ -16,13 +16,13 @@ Directives are multi-line containers that include an identifier, arguments, opti #### Specification -```{include} ../nodes/directive.md +```{embed} spec:directive ``` #### Example -```{include} ../examples/directive.md +```{embed} example:directive ``` @@ -75,13 +75,13 @@ Roles are very similar to directives, but they are written entirely in one line. #### Specification -```{include} ../nodes/role.md +```{embed} spec:role ``` #### Example -```{include} ../examples/role.md +```{embed} example:role ``` diff --git a/docs/features/references.md b/docs/features/references.md index edc4421..c0f83ff 100644 --- a/docs/features/references.md +++ b/docs/features/references.md @@ -22,13 +22,13 @@ Cross-referencing content is accomplished with markdown link syntax (`[text](#li ### Specification -```{include} ../nodes/crossreference.md +```{embed} spec:crossreference ``` ### Example -```{include} ../examples/crossreference.md +```{embed} example:crossreference ``` @@ -135,13 +135,13 @@ Placing a Target node allows you to cross reference the subsequent node by targe ### Specification -```{include} ../nodes/target.md +```{embed} spec:target ``` ### Example -```{include} ../examples/target.md +```{embed} example:target ``` diff --git a/docs/features/tables.md b/docs/features/tables.md index 4404fd4..e1a1ad9 100644 --- a/docs/features/tables.md +++ b/docs/features/tables.md @@ -2,12 +2,12 @@ ## Specification -```{include} ../nodes/table.md +```{embed} spec:table ``` ## Example -```{include} ../examples/table.md +```{embed} example:table ``` \ No newline at end of file diff --git a/docs/myst.yml b/docs/myst.yml index b4f3c8f..ce1ee52 100644 --- a/docs/myst.yml +++ b/docs/myst.yml @@ -8,6 +8,22 @@ project: subject: Specification venue: title: MyST Spec + toc: + # Auto-generated by `myst init --write-toc` + - file: index.md + - file: features/overview.md + - file: features/commonmark.md + - file: features/admonitions.md + - file: features/figures.md + - file: features/tables.md + - file: features/math.md + - file: features/references.md + - file: features/footnotes.md + - file: features/blocks.md + - file: nodes.myst.json + children: + - pattern: nodes/*.myst.json + site: title: MyST Spec actions: diff --git a/docs/nodes.myst.json b/docs/nodes.myst.json new file mode 100644 index 0000000..dd241ff --- /dev/null +++ b/docs/nodes.myst.json @@ -0,0 +1 @@ +{"kind":"Article","frontmatter":{"title":"MyST AST Index","content_includes_title":true},"mdast":{"type":"root","children":[{"type":"list","ordered":false,"spread":false,"children":[{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:abbreviation","children":[{"type":"inlineCode","value":"Abbreviation"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:admonition","children":[{"type":"inlineCode","value":"Admonition"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:admonitiontitle","children":[{"type":"inlineCode","value":"AdmonitionTitle"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:block","children":[{"type":"inlineCode","value":"Block"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:blockbreak","children":[{"type":"inlineCode","value":"BlockBreak"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:blockquote","children":[{"type":"inlineCode","value":"Blockquote"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:blockquotedata","children":[{"type":"inlineCode","value":"BlockquoteData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:break","children":[{"type":"inlineCode","value":"Break"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:breakdata","children":[{"type":"inlineCode","value":"BreakData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:caption","children":[{"type":"inlineCode","value":"Caption"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:code","children":[{"type":"inlineCode","value":"Code"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:codedata","children":[{"type":"inlineCode","value":"CodeData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:comment","children":[{"type":"inlineCode","value":"Comment"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:container","children":[{"type":"inlineCode","value":"Container"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:crossreference","children":[{"type":"inlineCode","value":"CrossReference"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:data","children":[{"type":"inlineCode","value":"Data"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:definition","children":[{"type":"inlineCode","value":"Definition"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:definitiondata","children":[{"type":"inlineCode","value":"DefinitionData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:delete","children":[{"type":"inlineCode","value":"Delete"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:deletedata","children":[{"type":"inlineCode","value":"DeleteData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:directive","children":[{"type":"inlineCode","value":"Directive"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:emphasis","children":[{"type":"inlineCode","value":"Emphasis"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:emphasisdata","children":[{"type":"inlineCode","value":"EmphasisData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:footnotedefinition","children":[{"type":"inlineCode","value":"FootnoteDefinition"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:footnotedefinitiondata","children":[{"type":"inlineCode","value":"FootnoteDefinitionData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:footnotereference","children":[{"type":"inlineCode","value":"FootnoteReference"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:footnotereferencedata","children":[{"type":"inlineCode","value":"FootnoteReferenceData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:heading","children":[{"type":"inlineCode","value":"Heading"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:headingdata","children":[{"type":"inlineCode","value":"HeadingData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:html","children":[{"type":"inlineCode","value":"Html"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:htmldata","children":[{"type":"inlineCode","value":"HtmlData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:image","children":[{"type":"inlineCode","value":"Image"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:imagedata","children":[{"type":"inlineCode","value":"ImageData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:imagereference","children":[{"type":"inlineCode","value":"ImageReference"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:imagereferencedata","children":[{"type":"inlineCode","value":"ImageReferenceData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:inlinecode","children":[{"type":"inlineCode","value":"InlineCode"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:inlinecodedata","children":[{"type":"inlineCode","value":"InlineCodeData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:inlinemath","children":[{"type":"inlineCode","value":"InlineMath"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:legend","children":[{"type":"inlineCode","value":"Legend"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:link","children":[{"type":"inlineCode","value":"Link"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:linkdata","children":[{"type":"inlineCode","value":"LinkData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:linkreference","children":[{"type":"inlineCode","value":"LinkReference"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:linkreferencedata","children":[{"type":"inlineCode","value":"LinkReferenceData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:list","children":[{"type":"inlineCode","value":"List"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:listdata","children":[{"type":"inlineCode","value":"ListData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:listitem","children":[{"type":"inlineCode","value":"ListItem"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:listitemdata","children":[{"type":"inlineCode","value":"ListItemData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:math","children":[{"type":"inlineCode","value":"Math"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:paragraph","children":[{"type":"inlineCode","value":"Paragraph"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:paragraphdata","children":[{"type":"inlineCode","value":"ParagraphData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:point","children":[{"type":"inlineCode","value":"Point"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:position","children":[{"type":"inlineCode","value":"Position"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:referencetype","children":[{"type":"inlineCode","value":"ReferenceType"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:role","children":[{"type":"inlineCode","value":"Role"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:root","children":[{"type":"inlineCode","value":"Root"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:rootdata","children":[{"type":"inlineCode","value":"RootData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:strong","children":[{"type":"inlineCode","value":"Strong"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:strongdata","children":[{"type":"inlineCode","value":"StrongData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:subscript","children":[{"type":"inlineCode","value":"Subscript"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:superscript","children":[{"type":"inlineCode","value":"Superscript"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:table","children":[{"type":"inlineCode","value":"Table"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:tablecell","children":[{"type":"inlineCode","value":"TableCell"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:tablecelldata","children":[{"type":"inlineCode","value":"TableCellData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:tabledata","children":[{"type":"inlineCode","value":"TableData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:tablerow","children":[{"type":"inlineCode","value":"TableRow"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:tablerowdata","children":[{"type":"inlineCode","value":"TableRowData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:target","children":[{"type":"inlineCode","value":"Target"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:text","children":[{"type":"inlineCode","value":"Text"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:textdata","children":[{"type":"inlineCode","value":"TextData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:thematicbreak","children":[{"type":"inlineCode","value":"ThematicBreak"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:thematicbreakdata","children":[{"type":"inlineCode","value":"ThematicBreakData"}]}]},{"type":"listItem","spread":true,"children":[{"type":"link","url":"#spec:underline","children":[{"type":"inlineCode","value":"Underline"}]}]}]}]}} \ No newline at end of file diff --git a/index.ts b/index.ts deleted file mode 100644 index a87feac..0000000 --- a/index.ts +++ /dev/null @@ -1,399 +0,0 @@ -import { copyFileSync, existsSync, mkdirSync, readdirSync, readFileSync, writeFileSync } from 'fs'; -import { join } from 'path'; -import { compile } from 'json-schema-to-typescript'; -import { load, dump } from 'js-yaml'; - -const outputSchemaFile = 'myst.schema.json'; -const outputDocFile = 'myst.schema.md'; -const outputTsFile = 'index.d.ts'; -const jsonTestCaseFile = 'myst.tests.json'; - -type PropertyDefinition = { - description?: string; - type?: 'string' | 'number' | 'array' | 'object'; - value?: string | string[]; - from?: string; -}; - -type Properties = Record