diff --git a/.copier-answers.yaml b/.copier-answers.yaml index 7508b11..4ea9eeb 100644 --- a/.copier-answers.yaml +++ b/.copier-answers.yaml @@ -1,5 +1,5 @@ # Changes here will be overwritten by Copier -_commit: 2d2a72d +_commit: 02f55bd _src_path: https://github.com/python-project-templates/base.git add_docs: true add_extension: js diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 66585e7..d4e65a1 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -34,12 +34,12 @@ jobs: persist-credentials: false - name: Setup Python - uses: actions-ext/python/setup@c8228d827a81b9f8c808825328af361c45461ba3 + uses: actions-ext/python/setup@c7ef9cbf13bc854a8d1422e9f8c6ee7a7ce1b911 with: version: "3.11" - name: Setup Node.js - uses: actions-ext/node/setup@03c9f6b2d9c9fa2c26cfa22d0fa379a69329b319 + uses: actions-ext/node/setup@8bcebee998923fcc26f5854b4fd05ea378b58262 with: version: 22.x @@ -79,12 +79,12 @@ jobs: run: make dist - name: Test wheel - uses: actions-ext/python/test-wheel@c8228d827a81b9f8c808825328af361c45461ba3 + uses: actions-ext/python/test-wheel@c7ef9cbf13bc854a8d1422e9f8c6ee7a7ce1b911 with: module: sphinx_pele - name: Test source distribution - uses: actions-ext/python/test-sdist@c8228d827a81b9f8c808825328af361c45461ba3 + uses: actions-ext/python/test-sdist@c7ef9cbf13bc854a8d1422e9f8c6ee7a7ce1b911 with: module: sphinx_pele diff --git a/.github/workflows/docs.yaml b/.github/workflows/docs.yaml index 4de2f48..ff95a12 100644 --- a/.github/workflows/docs.yaml +++ b/.github/workflows/docs.yaml @@ -22,12 +22,12 @@ jobs: persist-credentials: false - name: Setup Python - uses: actions-ext/python/setup@c8228d827a81b9f8c808825328af361c45461ba3 + uses: actions-ext/python/setup@c7ef9cbf13bc854a8d1422e9f8c6ee7a7ce1b911 with: version: "3.11" - name: Download distributions - uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8 + uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2 with: pattern: dist merge-multiple: true diff --git a/docs/index.md b/docs/index.md index 772ccdf..268d7d6 100644 --- a/docs/index.md +++ b/docs/index.md @@ -9,9 +9,10 @@ The tutorial takes you from an empty directory to a page with a captioned, zoomable diagram. ```{toctree} -:maxdepth: 1 -:caption: Tutorial - +--- +maxdepth: 1 +caption: Tutorial +--- src/tutorial ``` @@ -21,9 +22,10 @@ These guides cover existing Sphinx projects, visual customization, migration, and local checks. ```{toctree} -:maxdepth: 1 -:caption: How-to guides - +--- +maxdepth: 1 +caption: How-to guides +--- src/usage src/styling src/migration @@ -37,9 +39,10 @@ The reference records supported settings and their precedence. The example pages pair reusable source with output from the bundled renderer. ```{toctree} -:maxdepth: 1 -:caption: Reference - +--- +maxdepth: 1 +caption: Reference +--- src/configuration src/examples src/rst-examples @@ -51,8 +54,9 @@ Learn why diagrams render in the browser and what that means for layout, configuration, and non-HTML output. ```{toctree} -:maxdepth: 1 -:caption: Explanation - +--- +maxdepth: 1 +caption: Explanation +--- src/rendering ``` diff --git a/docs/src/examples.md b/docs/src/examples.md index aed354f..32382f4 100644 --- a/docs/src/examples.md +++ b/docs/src/examples.md @@ -14,7 +14,9 @@ and [how to add diagrams](usage.md). Styling recipes are in Diagram frontmatter supplies a title, layout settings, font size, and a CSS variable. ```{literalinclude} examples/publishing.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/publishing.mmd @@ -25,15 +27,19 @@ Diagram frontmatter supplies a title, layout settings, font size, and a CSS vari A caption, named reference, accessible label, width, and zoom controls are attached by the Sphinx directive. ```{literalinclude} examples/sequence.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/sequence.mmd -:name: request-flow -:caption: A **request** and response. -:alt: Client requests a page from the server. -:zoom: true -:width: 75% +--- +name: request-flow +caption: A **request** and response. +alt: Client requests a page from the server. +zoom: true +width: 75% +--- ``` ## External file @@ -41,11 +47,15 @@ A caption, named reference, accessible label, width, and zoom controls are attac The same UTF-8 file supplies the source listing and diagram. Sphinx tracks it as a build dependency. ```{literalinclude} publishing.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} publishing.mmd -:caption: Loaded from a Mermaid document. +--- +caption: Loaded from a Mermaid document. +--- ``` ## Pie chart @@ -53,7 +63,9 @@ The same UTF-8 file supplies the source listing and diagram. Sphinx tracks it as A chart with two labeled slices. ```{literalinclude} examples/pie.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/pie.mmd @@ -64,7 +76,9 @@ A chart with two labeled slices. Classes, members, and a composition relationship. ```{literalinclude} examples/classes.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/classes.mmd @@ -75,7 +89,9 @@ Classes, members, and a composition relationship. A documentation collection with pages and embedded diagrams. ```{literalinclude} examples/entities.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/entities.mmd @@ -86,7 +102,9 @@ A documentation collection with pages and embedded diagrams. Transitions through a review cycle, including a return to the draft state. ```{literalinclude} examples/states.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/states.mmd @@ -97,7 +115,9 @@ Transitions through a review cycle, including a return to the draft state. Fixed dates and a disabled today marker keep this example stable across builds. ```{literalinclude} examples/gantt.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/gantt.mmd @@ -108,7 +128,9 @@ Fixed dates and a disabled today marker keep this example stable across builds. Scores describe how a reader experiences each part of a documentation task. ```{literalinclude} examples/journey.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/journey.mmd @@ -119,7 +141,9 @@ Scores describe how a reader experiences each part of a documentation task. A documentation branch merged back into main. ```{literalinclude} examples/git-history.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/git-history.mmd @@ -130,7 +154,9 @@ A documentation branch merged back into main. A hierarchy of documentation topics. ```{literalinclude} examples/mindmap.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/mindmap.mmd @@ -141,7 +167,9 @@ A hierarchy of documentation topics. Milestones grouped by month. ```{literalinclude} examples/timeline.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/timeline.mmd @@ -152,7 +180,9 @@ Milestones grouped by month. Work items positioned by effort and reader impact. ```{literalinclude} examples/quadrants.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/quadrants.mmd @@ -163,7 +193,9 @@ Work items positioned by effort and reader impact. Values represent reader traffic between documentation sections. ```{literalinclude} examples/sankey.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/sankey.mmd @@ -174,7 +206,9 @@ Values represent reader traffic between documentation sections. Bars show completed examples over four weeks. ```{literalinclude} examples/xy-chart.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/xy-chart.mmd @@ -185,7 +219,9 @@ Bars show completed examples over four weeks. A test element verifies a rendering requirement. ```{literalinclude} examples/requirements.mmd -:language: text +--- +language: text +--- ``` ```{mermaid} examples/requirements.mmd diff --git a/pyproject.toml b/pyproject.toml index 54f7f38..3f96674 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,7 @@ develop = [ "hatch-js", "hatchling", "mdformat", - "mdformat-frontmatter", + "mdformat-myst", "myst-parser>=3", "mdformat-tables>=1", "pytest",