Revision as of 11:42, 6 October 2024 editMatrix (talk | contribs)Extended confirmed users, Rollbackers, Template editors5,452 edits →Normal usage← Previous edit | Latest revision as of 18:49, 14 November 2024 edit undoMatrix (talk | contribs)Extended confirmed users, Rollbackers, Template editors5,452 edits →Normal usage | ||
Line 9: | Line 9: | ||
==Example== | ==Example== | ||
===Normal usage=== | ===Normal usage=== | ||
<code><nowiki>{{Dark mode switch|]|]| |
<code><nowiki>{{Dark mode switch|]|]|logo}}</nowiki></code> | ||
{{Dark mode switch|]|]| |
{{Dark mode switch|]|]|logo}} | ||
* | * | ||
* | * |
Latest revision as of 18:49, 14 November 2024
This is a documentation subpage for Template:Dark mode switch. It may contain usage information, categories and other content that is not part of the original template page. |
This template uses TemplateStyles: |
This template detects whether it is being used with dark mode, and displays different content accordingly. This is useful when using logos, and the user may want both versions of the logo in dark mode.
Usage
{{Dark mode switch|dark mode wikitext|light mode wikitext|suffix for captions}}
Example
Normal usage
{{Dark mode switch|]|]|logo}}
Note the light-coloured logo is used in dark mode, and vice versa.