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

Incorporate mermaid diagrams #125

Open
wants to merge 22 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
1402b78
Add mermaid.js support
astroDimitrios Feb 19, 2024
11cb9f2
Add mermaid.min.js to our squashed js so its faster. Add styling and …
astroDimitrios Feb 19, 2024
037b34c
Merge branch 'feature/dark-mode' into feature/all
astroDimitrios Feb 20, 2024
676387f
Merge branch 'feature/tab-admonition' into feature/all
astroDimitrios Feb 20, 2024
fc9d713
Add dark mode styling for tabs.
astroDimitrios Feb 20, 2024
78d1c15
Fix tab and diagram code accordion border and background colours in d…
astroDimitrios Feb 22, 2024
f329ff4
Re-initialises Mermaid when the theme toggle is pressed so the diagra…
astroDimitrios Feb 23, 2024
d3a7981
Merge branch 'feature/dark-mode' into main
astroDimitrios Feb 26, 2024
df0c2b7
Merge branch 'feature/tab-admonition' into main
astroDimitrios Feb 26, 2024
98628d9
Alter mermaid diagram dark mode fix to retrieve the theme from local …
astroDimitrios Feb 26, 2024
4ca6b95
Merge branch 'feature/dark-mode' into main
astroDimitrios Feb 27, 2024
337ffbd
Merge branch 'main' into feature/mermaid
astroDimitrios Aug 1, 2024
e473702
Fix figcaption top border colour for light theme mermaid diagrams.
astroDimitrios Aug 1, 2024
f775630
Add support for dark mode images via JS
astroDimitrios Oct 29, 2024
97434f2
Remove if https check for setting dark mode images
astroDimitrios Oct 29, 2024
c6eb7fa
Only apply the dark image filter to images that are not dark mode spe…
astroDimitrios Oct 29, 2024
7402a2b
Merge branch 'main' of github.com:astroDimitrios/varnish
astroDimitrios Nov 4, 2024
adbc959
Add caution callout sass
astroDimitrios Nov 4, 2024
daf274e
Update lightmode caution icon to white for contrast
astroDimitrios Nov 5, 2024
6a257b2
Bump mermaid to 11.4.0 and fix figcaption css
astroDimitrios Nov 7, 2024
1b2d851
Bump mermaid to 11.4.0 and fix width and figcaption css.
astroDimitrios Nov 7, 2024
f8609d3
Add overflow scroll as an optional parameter
astroDimitrios Nov 7, 2024
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
7 changes: 7 additions & 0 deletions inst/pkgdown/assets/assets/mermaid.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
window.addEventListener("DOMContentLoaded",()=>{document.querySelectorAll("pre.mermaid").forEach($el=>{console.log($el),($el="CODE"===$el.tagName?$el.parentElement:$el).outerHTML=`
<div class="mermaid">${$el.textContent}</div>
<details>
<summary>Diagram source</summary>
<pre>${$el.textContent}</pre>
</details>
`})}),mermaid.initialize({logLevel:"error",securityLevel:"loose",theme:window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"default"});
2,288 changes: 2,287 additions & 1 deletion inst/pkgdown/assets/assets/scripts.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion inst/pkgdown/assets/assets/styles.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion inst/pkgdown/assets/assets/styles.css.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion inst/pkgdown/assets/assets/themetoggle.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading