1
0
mirror of https://github.com/chylex/TweetDuck.git synced 2025-04-23 12:15:48 +02:00

Add theme-based tweaks to edit-design plugin (background/scrollbar color)

This commit is contained in:
chylex 2017-05-15 15:18:06 +02:00
parent 801c9eba2d
commit 80a669c989

View File

@ -200,6 +200,7 @@ enabled(){
setTimeout(function(){
TD.settings.setTheme($(this).attr("data-td-theme"));
$(document).trigger("uiToggleTheme");
me.reinjectAll();
}, 1);
});
}).methods({
@ -319,6 +320,17 @@ enabled(){
this.css.insert(".txt-base-smallest:not(.icon), .txt-base-largest:not(.icon) { font-size: "+this.config.fontSize+" !important }");
this.css.insert(".avatar { border-radius: "+this.config.avatarRadius+"% !important }");
switch(TD.settings.getTheme()){
case "dark":
this.css.insert(".app-content, .app-columns-container { background-color: #444448 }");
break;
case "light":
this.css.insert(".scroll-styled-v::-webkit-scrollbar-thumb, .scroll-styled-h::-webkit-scrollbar-thumb { background-color: #d2d6da }");
this.css.insert(".app-columns-container.scroll-styled-h::-webkit-scrollbar-thumb:not(:hover) { background-color: #a5aeb5 }");
break;
}
if (this.config.hideTweetActions){
this.css.insert(".tweet-action { opacity: 0; }");
this.css.insert(".is-favorite .tweet-action, .is-retweet .tweet-action { opacity: 0.5; visibility: visible !important }");