Merge pull request #9265 from flipsyde606/fix/night-mode-persist
Fix for night mode not persisting in pages other than challenges
This commit is contained in:
@ -87,7 +87,9 @@ main = (function(main, global) {
|
||||
return null;
|
||||
}
|
||||
mainChatTitleAdded = true;
|
||||
|
||||
if ($('body').hasClass('night')) {
|
||||
$('#chat-embed-main').addClass('night');
|
||||
}
|
||||
$('#chat-embed-main > .gitter-chat-embed-action-bar').prepend(
|
||||
'<div class="chat-embed-main-title">' +
|
||||
'<span>Free Code Camp\'s Main Chat</span>' +
|
||||
@ -303,6 +305,9 @@ $(document).ready(function() {
|
||||
frameBorder: '0'
|
||||
});
|
||||
$('.map-aside').append(mapAside);
|
||||
if ($('body').hasClass('night')) {
|
||||
mapAside.addClass('night');
|
||||
}
|
||||
main.isMapAsideLoad = true;
|
||||
}
|
||||
$('.map-aside').removeClass('is-collapsed');
|
||||
@ -370,6 +375,9 @@ $(document).ready(function() {
|
||||
});
|
||||
$('.wiki-aside').append(wikiAside);
|
||||
main.isWikiAsideLoad = true;
|
||||
if ($('body').hasClass('night')) {
|
||||
wikiAside.addClass('night');
|
||||
}
|
||||
}
|
||||
$('.wiki-aside').removeClass('is-collapsed');
|
||||
}
|
||||
|
@ -4,7 +4,7 @@ html(lang='en')
|
||||
include partials/meta
|
||||
include partials/stylesheets
|
||||
if showAside
|
||||
body.map-aside-body
|
||||
body.map-aside-body(class=theme !== 'default' ? theme : '')
|
||||
include partials/scripts
|
||||
block content
|
||||
else
|
||||
|
@ -3,7 +3,7 @@ html(lang='en')
|
||||
head
|
||||
include partials/meta
|
||||
include partials/stylesheets
|
||||
body.top-and-bottom-margins
|
||||
body.top-and-bottom-margins(class=theme !== 'default' ? theme : '')
|
||||
include partials/scripts
|
||||
include partials/navbar
|
||||
include partials/flash
|
||||
|
Reference in New Issue
Block a user