Skip to content

Commit

Permalink
override or create built-in & inherited admonition directives
Browse files Browse the repository at this point in the history
This replaces the details-patch.py and the md-admonition.py modules by using the newer custom admonitions feature to override built-in admonition directives and create new directives that use inherited admonition styling from upstream.

Adds a new `:title:` option to built-in and generated admonitions. Also allows an optional argument to generated directives for custom titles.
update all docs

The removal of details_patch.py and md_admonition.py modules means we should now use the new generated directives' options. This affects all docs because upstream has deprecated some admonition aliases that we were using in various places.

Switch to documenting the overridden generic admonition directive to demonstrate the various uses provided by the overwritten built-in admonition directives & the newly created admonition directives.

rename exemplified animated admonition's CSS class name for less confusion.
  • Loading branch information
2bndy5 committed Nov 5, 2022
1 parent cc099df commit 735c19e
Show file tree
Hide file tree
Showing 12 changed files with 258 additions and 263 deletions.
21 changes: 19 additions & 2 deletions docs/_static/extra_css.css
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,23 @@
transform: none;
}

/* ************************* annimated-admonition-border style ******************************** */
@keyframes flash_border {
0% {
border-color: blueviolet;
}
50% {
border-color: aqua;
}
100% {
border-color: blueviolet;
}
}

.md-typeset .admonition.annimated-admonition-border {
animation: flash_border 1.5s infinite;
}

/* ************************* my-special-key style ************************************* */

.md-typeset kbd.key-my-special-key,
Expand All @@ -21,9 +38,9 @@

.md-typeset kbd.key-git::before {
content: "██";
-webkit-mask-image: var(--md-icon__fa-git);
-webkit-mask-image: var(--si-icon--fontawesome_brands_git);
-webkit-mask-repeat: no-repeat;
mask-image: var(--md-icon__fa-git);
mask-image: var(--si-icon--fontawesome_brands_git);
mask-repeat: no-repeat;
}

Expand Down
Loading

0 comments on commit 735c19e

Please sign in to comment.