Skip to content

Commit

Permalink
📌 Add mdbook-admonish plugin support
Browse files Browse the repository at this point in the history
It's frequently desirable to have sections dedicated to aside-material
like warnings, errors, tips, etc. One such case this is already a need
in the book is to prefix certain sections as not being fully
representative for the system in its current state.

To support such a case, the dependency `mdbook-admonish` has been
adopted, which leverages material design themes to accomplish this.
Some sections have been added making use of this to verify that it does
work as intended as well.
  • Loading branch information
bitwizeshift committed Feb 21, 2024
1 parent ab9b891 commit 8a7429d
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/deploy-github-pages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,15 @@ jobs:
with:
target: mdbook-mermaid

- name: Install mdbook-admonish
uses: ./.github/actions/cargo-install
with:
target: mdbook-admonish

- name: Install mdbook-dependencies
working-directory: docs
run: mdbook-admonish install

- name: Install cargo-llvm-cov
uses: taiki-e/install-action@cargo-llvm-cov

Expand Down
1 change: 1 addition & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
book
mermaid-init.js
mermaid.min.js
mdbook-admonish.css
5 changes: 5 additions & 0 deletions docs/book.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,10 @@ title = "Alloy Game Engine (Rust)"
[preprocessor.mermaid]
command = "mdbook-mermaid"

[preprocessor.admonish]
command = "mdbook-admonish"
assets_version = "3.0.2" # do not edit: managed by `mdbook-admonish install`

[output.html]
additional-js = ["mermaid.min.js", "mermaid-init.js"]
additional-css = ["./mdbook-admonish.css"]
5 changes: 5 additions & 0 deletions docs/src/community.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Community

```admonish note
This community section aggregates the same community-contribution files that
can be found from within the GitHub UI.
```

1. [Code of Conduct](./community/CODE_OF_CONDUCT.md)
2. [Contributing](./community/CONTRIBUTING.md)
3. [Project Governance](./community/GOVERNANCE.md)
Expand Down
5 changes: 5 additions & 0 deletions docs/src/tour/editors.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Tour of the Editors

```admonish note
Many of these sections are "forward-thinking" as these are still
in-progress unless otherwise specified.
```

This section provides a tour of the different editors that are available within
Alloy.

Expand Down
5 changes: 5 additions & 0 deletions docs/src/tour/engine.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Tour of the Alloy Engine

```admonish note
Many of these sections are "forward-thinking" as these are still
in-progress unless otherwise specified.
```

This is a tour of the Alloy Engine's software integration. This section will
provide detailed instructions to set up and prepare an Alloy application.

Expand Down

0 comments on commit 8a7429d

Please sign in to comment.