Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add example admonition css to example build #1284

Merged
merged 2 commits into from
Apr 9, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions test/examples/src/assets/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,12 @@
center.raw-html-block {
color: red;
}

.admonition.is-category-myadmonition > .admonition-header {
background-color: rgba(152,78,163,0.8);
}

.admonition.is-category-myadmonition > .admonition-body {
background-color: rgba(152,78,163,0.2);
}

15 changes: 15 additions & 0 deletions test/examples/src/man/style.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,21 @@ Also, custom admonition classes can be used:
!!! myadmonition "My Admonition Class"

In the HTML output, this admonition has `is-category-myadmonition` applied to it.
Its style can be changed by adding styles to `.admonition-header` and `.admonition-body`
in a custom css file and adding it to the build with, for example:

```julia
makedocs(
# ...
format=Documenter.HTML(;
#...
assets=["assets/custom.css"]
)
)
```

[See here](https://github.com/JuliaDocs/Documenter.jl/blob/master/test/examples/src/assets/custom.css)
for an example `custom.css` file.
mortenpi marked this conversation as resolved.
Show resolved Hide resolved

But otherwise

Expand Down