Template:Dark mode switch
Appearance
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
[edit]{{Dark mode switch|dark mode wikitext|light mode wikitext|suffix for captions}}
Example
[edit]Normal usage
[edit]{{Dark mode switch|[[File:Light logo of YouTube (2015-2017).svg|100px]]|[[File:Dark logo of YouTube (2015-2017).svg|100px]]|mode logo}}
Note the light-coloured logo is used in dark mode, and vice versa.