From e305c9a8df061b96664bd8dc5b3fea56d114eb84 Mon Sep 17 00:00:00 2001 From: thhsh-local Date: Tue, 20 May 2025 12:57:15 -0400 Subject: [PATCH] Add deprecated admonition --- docs/handbook/meta/syntax.md | 15 +++++++++++++++ docs/stylesheets/extra.css | 18 ++++++++++++++++++ 2 files changed, 33 insertions(+) diff --git a/docs/handbook/meta/syntax.md b/docs/handbook/meta/syntax.md index 4450110..6936b38 100644 --- a/docs/handbook/meta/syntax.md +++ b/docs/handbook/meta/syntax.md @@ -96,6 +96,21 @@ Here are some common admonitions, when you might use them, and quick code snippe ### Custom We've modified a couple of the standard admonitions to mean something a little different on this site. +#### Deprecated +For pages that were once accurate, but are either no longer accurate and not being updated, or have become obsolete due to discontinuation, etc. + +!!! deprecated "Deprecated" + The `deprecated` admonition looks like this. + +??? quote "Syntax" + Copy and paste at the top of page content: + ``` + !!! deprecated "Deprecated" + The contents of this page are deprecated. Do not rely on any information on this page to be accurate, as it is not being updated. + + Please see for the equivalet updated information. + ``` + #### Work in Progress For pages that aren't yet complete, and need revisions (that we know are going to be revised sooner/more frequently than a typical page.) diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css index c61704b..8288ea2 100644 --- a/docs/stylesheets/extra.css +++ b/docs/stylesheets/extra.css @@ -1,3 +1,21 @@ +:root { + --md-admonition-icon--deprecated: url('data:image/svg+xml;charset=utf-8,') +} +.md-typeset .admonition.deprecated, +.md-typeset details.deprecated { + border-color: rgb(98, 114, 164); +} +.md-typeset .deprecated > .admonition-title, +.md-typeset .deprecated > summary { + background-color: rgba(98, 114, 164, 0.1); +} +.md-typeset .deprecated > .admonition-title::before, +.md-typeset .deprecated > summary::before { + background-color: rgb(98, 114, 164); + -webkit-mask-image: var(--md-admonition-icon--deprecated); + mask-image: var(--md-admonition-icon--deprecated); +} + .note-blue { color: #448AFF; }