mirror of
https://github.com/twisterarmy/twister-html.git
synced 2025-03-12 13:31:14 +00:00
integrate original theme nin
This commit is contained in:
parent
db241ec8d9
commit
4eb5c10e0f
@ -2747,6 +2747,12 @@ function changeStyle() {
|
||||
// we use .ajax because .getScript requires 'unsafe-inline' CSP rule for now, see https://github.com/jquery/jquery/issues/3969
|
||||
$.ajax({dataType: 'text', url: 'theme_nin/js/theme_option.js'})
|
||||
.done(function(res) {eval(res);});
|
||||
} else if (theme === 'nin_original') {
|
||||
theme = 'nin'; // related to native theme in class definitions, so easiest way to integrate original version
|
||||
style = 'theme_nin_original/css/style.css';
|
||||
profile = 'theme_nin_original/css/profile.css';
|
||||
$.ajax({dataType: 'text', url: 'theme_nin_original/js/theme_option.js'})
|
||||
.done(function(res) {eval(res);});
|
||||
} else if (theme === 'calm') {
|
||||
style = 'theme_calm/css/style.css';
|
||||
profile = 'theme_calm/css/profile.css';
|
||||
|
@ -425,8 +425,20 @@ function getAvatar(peerAlias, img) {
|
||||
return;
|
||||
|
||||
if (peerAlias === 'nobody') {
|
||||
img.attr('src', ($.Options.theme.val === 'nin') ?
|
||||
'theme_nin/img/tornado_avatar.png' : 'img/tornado_avatar.png');
|
||||
|
||||
var avatar = 'img/tornado_avatar.png';
|
||||
|
||||
switch ($.Options.theme.val) {
|
||||
case 'nin':
|
||||
avatar = 'theme_nin/img/tornado_avatar.png';
|
||||
break;
|
||||
case 'nin_original':
|
||||
avatar = 'theme_nin_original/img/tornado_avatar.png';
|
||||
break;
|
||||
}
|
||||
|
||||
img.attr('src', avatar);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user