Merge pull request #1308 from asaadmahmoodspin/plt-960

Plt 960 - Moving code themes into custom themes
Этот коммит содержится в:
Christopher Speller
2015-11-05 07:31:37 -05:00
родитель 72a18e7d10 a809ff8862
Коммит 40eea5b5e3
13 изменённых файлов: 111 добавлений и 115 удалений

Просмотреть файл

@@ -438,11 +438,6 @@ export function toTitleCase(str) {
}
export function applyTheme(theme) {
if (!theme.codeTheme) {
theme.codeTheme = Constants.DEFAULT_CODE_THEME;
}
updateCodeTheme(theme.codeTheme);
if (theme.sidebarBg) {
changeCss('.sidebar--left, .settings-modal .settings-table .settings-links, .sidebar--menu', 'background:' + theme.sidebarBg, 1);
}
@@ -598,6 +593,11 @@ export function applyTheme(theme) {
if (theme.mentionHighlightLink) {
changeCss('.mention-highlight .mention-link', 'color:' + theme.mentionHighlightLink, 1);
}
if (!theme.codeTheme) {
theme.codeTheme = Constants.DEFAULT_CODE_THEME;
}
updateCodeTheme(theme.codeTheme);
}
export function changeCss(className, classValue, classRepeat) {
// we need invisible container to store additional css definitions