Content deleted Content added
←Created page with '→* * Enables or disables the dark-mode gadget. * * Authors: [[User:SD0001]], [[User:Nardog]]: // 'Dark mode' and 'Light mode' messages must match the ::before content in // MediaWiki:Gadget-dark-mode-toggle-pagestyles.css and MediaWiki:Gadget-dark-mode.css, respectively. // Don't overwrite existing messages, if already set on a foreign wiki prior to loading this file if (!mw.messages.get('darkmode-turn-on-label')) { mw.messages.set({ 'dar...' |
deal with minerva theme color |
||
Line 48:
$(labelSelector).text(mw.msg('darkmode-turn-' + onOrOff + '-label'));
$('#pt-darkmode a').attr('title', mw.msg('darkmode-turn-' + onOrOff + '-tooltip'));
// Update the minerva theme-color
$('meta[name="theme-color"]').attr('content', onOrOff ? '#eaecf0' : '#000000');
// Modify the <link> element on the page to include/exclude dark-mode styles
|