From 813792dd600f4e485d52cc1066a8c1297578432d Mon Sep 17 00:00:00 2001 From: Asaad Mahmood Date: Thu, 1 Oct 2015 09:33:21 +0500 Subject: pot-375 - Making modals compatible with themes --- .../user_settings/premade_theme_chooser.jsx | 4 +-- .../user_settings/user_settings_appearance.jsx | 15 +++++----- web/react/utils/constants.jsx | 2 +- web/react/utils/utils.jsx | 33 ++++++++++++--------- web/sass-files/sass/partials/_base.scss | 13 ++++++++ web/sass-files/sass/partials/_modal.scss | 17 +++-------- web/sass-files/sass/partials/_responsive.scss | 6 ---- web/sass-files/sass/partials/_settings.scss | 11 ++----- web/sass-files/sass/partials/_sidebar--menu.scss | 2 +- web/static/images/themes/mattermost dark.jpg | Bin 0 -> 23484 bytes web/static/images/themes/mattermost dark.png | Bin 75371 -> 0 bytes web/static/images/themes/mattermost.jpg | Bin 0 -> 24571 bytes web/static/images/themes/mattermost.png | Bin 66828 -> 0 bytes web/static/images/themes/organization.jpg | Bin 0 -> 28630 bytes web/static/images/themes/organization.png | Bin 86044 -> 0 bytes web/static/images/themes/slack.png | Bin 68603 -> 0 bytes web/static/images/themes/windows dark.jpg | Bin 0 -> 29750 bytes web/static/images/themes/windows dark.png | Bin 82784 -> 0 bytes 18 files changed, 51 insertions(+), 52 deletions(-) create mode 100644 web/static/images/themes/mattermost dark.jpg delete mode 100644 web/static/images/themes/mattermost dark.png create mode 100644 web/static/images/themes/mattermost.jpg delete mode 100644 web/static/images/themes/mattermost.png create mode 100644 web/static/images/themes/organization.jpg delete mode 100644 web/static/images/themes/organization.png delete mode 100644 web/static/images/themes/slack.png create mode 100644 web/static/images/themes/windows dark.jpg delete mode 100644 web/static/images/themes/windows dark.png (limited to 'web') diff --git a/web/react/components/user_settings/premade_theme_chooser.jsx b/web/react/components/user_settings/premade_theme_chooser.jsx index f8f916bd0..d2b88d09a 100644 --- a/web/react/components/user_settings/premade_theme_chooser.jsx +++ b/web/react/components/user_settings/premade_theme_chooser.jsx @@ -24,7 +24,7 @@ export default class PremadeThemeChooser extends React.Component { premadeThemes.push(
{Utils.toTitleCase(premadeTheme.type)}
diff --git a/web/react/components/user_settings/user_settings_appearance.jsx b/web/react/components/user_settings/user_settings_appearance.jsx index 4372069e7..e9ca0f4a5 100644 --- a/web/react/components/user_settings/user_settings_appearance.jsx +++ b/web/react/components/user_settings/user_settings_appearance.jsx @@ -214,14 +214,15 @@ export default class UserSettingsAppearance extends React.Component {
{themeUI}
+
+ + {'Import from Slack'} +
-
- - {'Import from Slack'} -
); } diff --git a/web/react/utils/constants.jsx b/web/react/utils/constants.jsx index da59f8e5a..67414dc3b 100644 --- a/web/react/utils/constants.jsx +++ b/web/react/utils/constants.jsx @@ -179,7 +179,7 @@ module.exports = { centerChannelColor: '#DDDDDD', newMessageSeparator: '#5de5da', linkColor: '#A4FFEB', - buttonBg: '#1dacfc', + buttonBg: '#4CBBA4', buttonColor: '#FFFFFF' }, windows10: { diff --git a/web/react/utils/utils.jsx b/web/react/utils/utils.jsx index 8b20e2adf..9a3141d51 100644 --- a/web/react/utils/utils.jsx +++ b/web/react/utils/utils.jsx @@ -395,35 +395,39 @@ export function toTitleCase(str) { export function applyTheme(theme) { if (theme.sidebarBg) { - changeCss('.sidebar--left', 'background:' + theme.sidebarBg, 1); + changeCss('.sidebar--left, .settings-modal .settings-table .settings-links, .sidebar--menu', 'background:' + theme.sidebarBg, 1); } if (theme.sidebarText) { - changeCss('.sidebar--left .nav li>a, .sidebar--right', 'color:' + theme.sidebarText, 1); + changeCss('.sidebar--left .nav li>a, .sidebar--right, .settings-modal .nav-pills>li a, .sidebar--menu', 'color:' + theme.sidebarText, 1); + changeCss('@media(max-width: 768px){.settings-modal .settings-table .nav>li>a', 'color:' + theme.sidebarText, 1); changeCss('.sidebar--left .nav li>h4, .sidebar--left .add-channel-btn', 'color:' + changeOpacity(theme.sidebarText, 0.8), 1); changeCss('.sidebar--left .add-channel-btn:hover, .sidebar--left .add-channel-btn:focus', 'color:' + theme.sidebarText, 1); changeCss('.sidebar--left, .sidebar--right .sidebar--right__header', 'border-color:' + changeOpacity(theme.sidebarText, 0.2), 1); changeCss('.sidebar--left .status path', 'fill:' + changeOpacity(theme.sidebarText, 0.5), 1); + changeCss('@media(max-width: 768px){.settings-modal .settings-table .nav>li>a', 'border-color:' + changeOpacity(theme.sidebarText, 0.2), 2); } if (theme.sidebarUnreadText) { - changeCss('.sidebar--left .nav li>a.unread-title', 'color:' + theme.sidebarUnreadText + '!important;', 1); + changeCss('.sidebar--left .nav li>a.unread-title', 'color:' + theme.sidebarUnreadText + '!important;', 2); } if (theme.sidebarTextHoverBg) { - changeCss('.sidebar--left .nav li>a:hover, .sidebar--left .nav li>a:focus', 'background:' + theme.sidebarTextHoverBg, 1); + changeCss('.sidebar--left .nav li>a:hover, .sidebar--left .nav li>a:focus, .settings-modal .nav-pills>li:hover a, .settings-modal .nav-pills>li:focus a', 'background:' + theme.sidebarTextHoverBg, 1); + changeCss('@media(max-width: 768px){.settings-modal .settings-table .nav>li:hover a', 'background:' + theme.sidebarTextHoverBg, 1); } if (theme.sidebarTextHoverColor) { - changeCss('.sidebar--left .nav li>a:hover, .sidebar--left .nav li>a:focus', 'color:' + theme.sidebarTextHoverColor, 2); + changeCss('.sidebar--left .nav li>a:hover, .sidebar--left .nav li>a:focus, .settings-modal .nav-pills>li:hover a, .settings-modal .nav-pills>li:focus a', 'color:' + theme.sidebarTextHoverColor, 2); + changeCss('@media(max-width: 768px){.settings-modal .settings-table .nav>li:hover a', 'color:' + theme.sidebarTextHoverColor, 2); } if (theme.sidebarTextActiveBg) { - changeCss('.sidebar--left .nav li.active a, .sidebar--left .nav li.active a:hover, .sidebar--left .nav li.active a:focus', 'background:' + theme.sidebarTextActiveBg, 1); + changeCss('.sidebar--left .nav li.active a, .sidebar--left .nav li.active a:hover, .sidebar--left .nav li.active a:focus, .settings-modal .nav-pills>li.active a, .settings-modal .nav-pills>li.active a:hover, .settings-modal .nav-pills>li.active a:active', 'background:' + theme.sidebarTextActiveBg, 1); } if (theme.sidebarTextActiveColor) { - changeCss('.sidebar--left .nav li.active a, .sidebar--left .nav li.active a:hover, .sidebar--left .nav li.active a:focus', 'color:' + theme.sidebarTextActiveColor, 2); + changeCss('.sidebar--left .nav li.active a, .sidebar--left .nav li.active a:hover, .sidebar--left .nav li.active a:focus, .settings-modal .nav-pills>li.active a, .settings-modal .nav-pills>li.active a:hover, .settings-modal .nav-pills>li.active a:active', 'color:' + theme.sidebarTextActiveColor, 2); } if (theme.sidebarHeaderBg) { @@ -458,7 +462,7 @@ export function applyTheme(theme) { } if (theme.centerChannelBg) { - changeCss('.app__content, .markdown__table, .markdown__table tbody tr, .command-box', 'background:' + theme.centerChannelBg, 1); + changeCss('.app__content, .markdown__table, .markdown__table tbody tr, .command-box, .modal .modal-content', 'background:' + theme.centerChannelBg, 1); changeCss('#post-list .post-list-holder-by-time', 'background:' + theme.centerChannelBg, 1); changeCss('#post-create', 'background:' + theme.centerChannelBg, 1); changeCss('.date-separator .separator__text, .new-separator .separator__text', 'background:' + theme.centerChannelBg, 1); @@ -467,7 +471,7 @@ export function applyTheme(theme) { } if (theme.centerChannelColor) { - changeCss('.app__content, .post-create__container .post-create-body .btn-file, .post-create__container .post-create-footer .msg-typing, .loading-screen .loading__content .round, .command-name', 'color:' + theme.centerChannelColor, 1); + changeCss('.app__content, .post-create__container .post-create-body .btn-file, .post-create__container .post-create-footer .msg-typing, .loading-screen .loading__content .round, .command-name, .modal .modal-content', 'color:' + theme.centerChannelColor, 1); changeCss('#post-create', 'color:' + theme.centerChannelColor, 2); changeCss('.mentions--top, .command-box', 'box-shadow:' + changeOpacity(theme.centerChannelColor, 0.2) + ' 1px -3px 12px', 3); changeCss('.mentions--top, .command-box', '-webkit-box-shadow:' + changeOpacity(theme.centerChannelColor, 0.2) + ' 1px -3px 12px', 2); @@ -477,7 +481,7 @@ export function applyTheme(theme) { changeCss('.markdown__table tbody tr:nth-child(2n)', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); changeCss('.channel-header__info>div.dropdown .header-dropdown__icon', 'color:' + changeOpacity(theme.centerChannelColor, 0.8), 1); changeCss('.channel-header #member_popover', 'color:' + changeOpacity(theme.centerChannelColor, 0.8), 1); - changeCss('.custom-textarea, .custom-textarea:focus, .preview-container .preview-div, .post-image__column .post-image__details, .sidebar--right .sidebar-right__body, .markdown__table th, .markdown__table td, .command-box', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); + changeCss('.custom-textarea, .custom-textarea:focus, .preview-container .preview-div, .post-image__column .post-image__details, .sidebar--right .sidebar-right__body, .markdown__table th, .markdown__table td, .command-box, .modal .modal-content, .settings-modal .settings-table .settings-content .divider-light, .modal .modal-header', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); changeCss('.command-name', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); changeCss('.custom-textarea', 'color:' + theme.centerChannelColor, 1); changeCss('.post-image__column', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 2); @@ -487,14 +491,15 @@ export function applyTheme(theme) { changeCss('.search-bar__container .search__form', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); changeCss('.channel-intro .channel-intro__content', 'background:' + changeOpacity(theme.centerChannelColor, 0.05), 1); changeCss('.date-separator .separator__text', 'color:' + theme.centerChannelColor, 2); - changeCss('.date-separator .separator__hr, .post-right__container .post.post--root hr, .search-item-container', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); - changeCss('.channel-intro', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); + changeCss('.date-separator .separator__hr, .modal-footer, .modal .custom-textarea, .post-right__container .post.post--root hr, .search-item-container', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); + changeCss('.modal .custom-textarea:focus', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.3), 1); + changeCss('.channel-intro, .settings-modal .settings-table .settings-content .divider-dark, hr, .settings-modal .settings-table .settings-links', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); changeCss('.post.current--user .post-body, .post.post--comment.other--root.current--user .post-comment', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); changeCss('.post.current--user .post-body, .post.post--comment.other--root.current--user .post-comment, .post.post--comment.other--root .post-comment, .post.same--root .post-body', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.07), 2); changeCss('@media(max-width: 1440px){.post.same--root', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.07), 2); changeCss('@media(max-width: 1440px){.post.same--root', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.07), 2); changeCss('@media(max-width: 1800px){.inner__wrap.move--left .post.post--comment.same--root', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.07), 2); - changeCss('.post:hover, .sidebar--right .sidebar--right__header', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); + changeCss('.post:hover, .sidebar--right .sidebar--right__header, .settings-modal .settings-table .settings-content .section-min:hover', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); changeCss('.date-separator.hovered--before:after, .new-separator.hovered--before:after', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); changeCss('.date-separator.hovered--after:before, .new-separator.hovered--after:before, .command-name:hover', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); changeCss('.post.current--user:hover .post-body ', 'background: none;', 1); @@ -507,7 +512,7 @@ export function applyTheme(theme) { } if (theme.linkColor) { - changeCss('a, a:focus, a:hover', 'color:' + theme.linkColor, 1); + changeCss('a, a:focus, a:hover, .btn, .btn:focus, .btn:hover', 'color:' + theme.linkColor, 1); changeCss('.post .comment-icon__container', 'fill:' + theme.linkColor, 1); } diff --git a/web/sass-files/sass/partials/_base.scss b/web/sass-files/sass/partials/_base.scss index 87d9b8200..ba27e7fbc 100644 --- a/web/sass-files/sass/partials/_base.scss +++ b/web/sass-files/sass/partials/_base.scss @@ -68,6 +68,19 @@ a:focus, a:hover { margin: 0; } +.text-danger { + color: #E05F5D; +} + +.btn { + &.btn-danger { + color: #fff; + &:hover, &:active { + color: #fff; + } + } +} + .form-control { @include border-radius(2px); &.no-resize { diff --git a/web/sass-files/sass/partials/_modal.scss b/web/sass-files/sass/partials/_modal.scss index e4e8b20b6..96b26f251 100644 --- a/web/sass-files/sass/partials/_modal.scss +++ b/web/sass-files/sass/partials/_modal.scss @@ -9,12 +9,6 @@ @include opacity(0.7); } } - a, a:focus, a:hover { - color: #2389D7; - &.text-danger { - color: #a94442; - } - } .custom-textarea { color: inherit; border-color: #ccc; @@ -25,12 +19,9 @@ } .btn { font-size: 13px; - &.btn-primary { - background: #4285f4; - &:hover, &:focus, &:active { - background: $primary-color--hover; - color: #fff; - } + &.btn-default { + border: none; + background: transparent; } } .info__label { @@ -70,7 +61,7 @@ background: $primary-color; color: #FFF; padding: 15px 15px 11px; - border: none; + border: 1px solid #ddd; min-height: 56px; @include clearfix; .modal-title { diff --git a/web/sass-files/sass/partials/_responsive.scss b/web/sass-files/sass/partials/_responsive.scss index 9e8d0dc7d..82ec1811a 100644 --- a/web/sass-files/sass/partials/_responsive.scss +++ b/web/sass-files/sass/partials/_responsive.scss @@ -402,12 +402,6 @@ margin-left: 7px; } } - &.active, &:hover { - a { - color: #555; - background: #fff; - } - } } } } diff --git a/web/sass-files/sass/partials/_settings.scss b/web/sass-files/sass/partials/_settings.scss index 3aab05d70..1f785f63c 100644 --- a/web/sass-files/sass/partials/_settings.scss +++ b/web/sass-files/sass/partials/_settings.scss @@ -2,7 +2,6 @@ @import "activity-log"; .user-settings { - background: #fff; min-height:300px; .table-responsive { max-width: 560px; @@ -71,7 +70,7 @@ } .section-max { - background: #f2f2f2; + background: rgba(black, 0.05); padding: 1em 0 1.3em; margin-bottom: 0; @include clearfix; @@ -121,7 +120,7 @@ .fa { margin-right: 7px; font-size: 12px; - color: #aaa; + @include opacity(0.5); display: none; } } @@ -131,7 +130,7 @@ } .section-describe { - color:grey; + @include opacity(0.7); } .divider-dark { @@ -167,15 +166,11 @@ } } .control-label { - color: #555; font-weight: 600; &.text-left { text-align: left; } } - hr { - border-color: #ccc; - } } .file-status { diff --git a/web/sass-files/sass/partials/_sidebar--menu.scss b/web/sass-files/sass/partials/_sidebar--menu.scss index 4366b1a6c..6f4a0cc38 100644 --- a/web/sass-files/sass/partials/_sidebar--menu.scss +++ b/web/sass-files/sass/partials/_sidebar--menu.scss @@ -54,7 +54,7 @@ > a { font-size: 15px; background: none !important; - color: #444; + color: inherit; line-height: 40px; padding: 0 15px; .glyphicon { diff --git a/web/static/images/themes/mattermost dark.jpg b/web/static/images/themes/mattermost dark.jpg new file mode 100644 index 000000000..ea70e701d Binary files /dev/null and b/web/static/images/themes/mattermost dark.jpg differ diff --git a/web/static/images/themes/mattermost dark.png b/web/static/images/themes/mattermost dark.png deleted file mode 100644 index 832f64d2e..000000000 Binary files a/web/static/images/themes/mattermost dark.png and /dev/null differ diff --git a/web/static/images/themes/mattermost.jpg b/web/static/images/themes/mattermost.jpg new file mode 100644 index 000000000..eb36786a6 Binary files /dev/null and b/web/static/images/themes/mattermost.jpg differ diff --git a/web/static/images/themes/mattermost.png b/web/static/images/themes/mattermost.png deleted file mode 100644 index 4a321adcb..000000000 Binary files a/web/static/images/themes/mattermost.png and /dev/null differ diff --git a/web/static/images/themes/organization.jpg b/web/static/images/themes/organization.jpg new file mode 100644 index 000000000..5a5c10bd3 Binary files /dev/null and b/web/static/images/themes/organization.jpg differ diff --git a/web/static/images/themes/organization.png b/web/static/images/themes/organization.png deleted file mode 100644 index 1a38bfb34..000000000 Binary files a/web/static/images/themes/organization.png and /dev/null differ diff --git a/web/static/images/themes/slack.png b/web/static/images/themes/slack.png deleted file mode 100644 index dc70c7dc2..000000000 Binary files a/web/static/images/themes/slack.png and /dev/null differ diff --git a/web/static/images/themes/windows dark.jpg b/web/static/images/themes/windows dark.jpg new file mode 100644 index 000000000..0ab19c021 Binary files /dev/null and b/web/static/images/themes/windows dark.jpg differ diff --git a/web/static/images/themes/windows dark.png b/web/static/images/themes/windows dark.png deleted file mode 100644 index d65304820..000000000 Binary files a/web/static/images/themes/windows dark.png and /dev/null differ -- cgit v1.2.3-1-g7c22 From fb290743d73e6d2e82d2a44ebd80a93493e776d1 Mon Sep 17 00:00:00 2001 From: Asaad Mahmood Date: Fri, 2 Oct 2015 22:32:50 +0500 Subject: Changing jpeg images back to png --- web/static/images/themes/mattermost dark.jpg | Bin 23484 -> 0 bytes web/static/images/themes/mattermost dark.png | Bin 0 -> 104882 bytes web/static/images/themes/mattermost.jpg | Bin 24571 -> 0 bytes web/static/images/themes/mattermost.png | Bin 0 -> 93862 bytes web/static/images/themes/organization.jpg | Bin 28630 -> 0 bytes web/static/images/themes/organization.png | Bin 0 -> 127558 bytes web/static/images/themes/windows dark.jpg | Bin 29750 -> 0 bytes web/static/images/themes/windows dark.png | Bin 0 -> 122145 bytes 8 files changed, 0 insertions(+), 0 deletions(-) delete mode 100644 web/static/images/themes/mattermost dark.jpg create mode 100644 web/static/images/themes/mattermost dark.png delete mode 100644 web/static/images/themes/mattermost.jpg create mode 100644 web/static/images/themes/mattermost.png delete mode 100644 web/static/images/themes/organization.jpg create mode 100644 web/static/images/themes/organization.png delete mode 100644 web/static/images/themes/windows dark.jpg create mode 100644 web/static/images/themes/windows dark.png (limited to 'web') diff --git a/web/static/images/themes/mattermost dark.jpg b/web/static/images/themes/mattermost dark.jpg deleted file mode 100644 index ea70e701d..000000000 Binary files a/web/static/images/themes/mattermost dark.jpg and /dev/null differ diff --git a/web/static/images/themes/mattermost dark.png b/web/static/images/themes/mattermost dark.png new file mode 100644 index 000000000..1ab44e104 Binary files /dev/null and b/web/static/images/themes/mattermost dark.png differ diff --git a/web/static/images/themes/mattermost.jpg b/web/static/images/themes/mattermost.jpg deleted file mode 100644 index eb36786a6..000000000 Binary files a/web/static/images/themes/mattermost.jpg and /dev/null differ diff --git a/web/static/images/themes/mattermost.png b/web/static/images/themes/mattermost.png new file mode 100644 index 000000000..8dea37ff6 Binary files /dev/null and b/web/static/images/themes/mattermost.png differ diff --git a/web/static/images/themes/organization.jpg b/web/static/images/themes/organization.jpg deleted file mode 100644 index 5a5c10bd3..000000000 Binary files a/web/static/images/themes/organization.jpg and /dev/null differ diff --git a/web/static/images/themes/organization.png b/web/static/images/themes/organization.png new file mode 100644 index 000000000..3066cca0b Binary files /dev/null and b/web/static/images/themes/organization.png differ diff --git a/web/static/images/themes/windows dark.jpg b/web/static/images/themes/windows dark.jpg deleted file mode 100644 index 0ab19c021..000000000 Binary files a/web/static/images/themes/windows dark.jpg and /dev/null differ diff --git a/web/static/images/themes/windows dark.png b/web/static/images/themes/windows dark.png new file mode 100644 index 000000000..1f665d882 Binary files /dev/null and b/web/static/images/themes/windows dark.png differ -- cgit v1.2.3-1-g7c22 From fef9947757255715a8da3a9a804664321e45ac08 Mon Sep 17 00:00:00 2001 From: Asaad Mahmood Date: Mon, 5 Oct 2015 06:34:35 +0500 Subject: Updating jpg to png for theme names --- web/react/components/user_settings/premade_theme_chooser.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'web') diff --git a/web/react/components/user_settings/premade_theme_chooser.jsx b/web/react/components/user_settings/premade_theme_chooser.jsx index d2b88d09a..8116bffcc 100644 --- a/web/react/components/user_settings/premade_theme_chooser.jsx +++ b/web/react/components/user_settings/premade_theme_chooser.jsx @@ -34,7 +34,7 @@ export default class PremadeThemeChooser extends React.Component { -- cgit v1.2.3-1-g7c22 From 74fecd1952cb4fa1a8d1a93a1187cbf366b11a80 Mon Sep 17 00:00:00 2001 From: Asaad Mahmood Date: Mon, 5 Oct 2015 06:43:08 +0500 Subject: Updating search colours --- web/react/utils/utils.jsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'web') diff --git a/web/react/utils/utils.jsx b/web/react/utils/utils.jsx index 9a3141d51..7a7a5e13f 100644 --- a/web/react/utils/utils.jsx +++ b/web/react/utils/utils.jsx @@ -487,7 +487,8 @@ export function applyTheme(theme) { changeCss('.post-image__column', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 2); changeCss('.post-image__column .post-image__details', 'color:' + theme.centerChannelColor, 2); changeCss('.post-image__column a, .post-image__column a:hover, .post-image__column a:focus', 'color:' + theme.centerChannelColor, 1); - changeCss('@media(max-width: 768px){.search-bar__container .search__form .search-bar', 'background:' + changeOpacity(theme.centerChannelColor, 0.2), 1); + changeCss('.search-bar__container .search__form .search-bar', 'background: transparent; color:' + theme.centerChannelColor, 1); + changeCss('@media(max-width: 768px){.search-bar__container .search__form .search-bar', 'background:' + changeOpacity(theme.centerChannelColor, 0.2) + '; color: inherit;', 1); changeCss('.search-bar__container .search__form', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); changeCss('.channel-intro .channel-intro__content', 'background:' + changeOpacity(theme.centerChannelColor, 0.05), 1); changeCss('.date-separator .separator__text', 'color:' + theme.centerChannelColor, 2); -- cgit v1.2.3-1-g7c22 From 89d6613b9318aa6f4e2d837cfdcb25eaf772951c Mon Sep 17 00:00:00 2001 From: Asaad Mahmood Date: Mon, 5 Oct 2015 08:04:32 +0500 Subject: Updating theme colours for popovers, drop downs etc --- web/react/utils/utils.jsx | 32 +++++++++++++----------- web/sass-files/sass/partials/_admin-console.scss | 1 - web/sass-files/sass/partials/_base.scss | 15 +++++++++++ web/sass-files/sass/partials/_headers.scss | 18 ------------- web/sass-files/sass/partials/_mentions.scss | 8 ------ web/sass-files/sass/partials/_sidebar--left.scss | 11 -------- 6 files changed, 33 insertions(+), 52 deletions(-) (limited to 'web') diff --git a/web/react/utils/utils.jsx b/web/react/utils/utils.jsx index 7a7a5e13f..1bc082175 100644 --- a/web/react/utils/utils.jsx +++ b/web/react/utils/utils.jsx @@ -399,9 +399,9 @@ export function applyTheme(theme) { } if (theme.sidebarText) { - changeCss('.sidebar--left .nav li>a, .sidebar--right, .settings-modal .nav-pills>li a, .sidebar--menu', 'color:' + theme.sidebarText, 1); + changeCss('.sidebar--left .nav-pills__container li>a, .sidebar--right, .settings-modal .nav-pills>li a, .sidebar--menu', 'color:' + theme.sidebarText, 1); changeCss('@media(max-width: 768px){.settings-modal .settings-table .nav>li>a', 'color:' + theme.sidebarText, 1); - changeCss('.sidebar--left .nav li>h4, .sidebar--left .add-channel-btn', 'color:' + changeOpacity(theme.sidebarText, 0.8), 1); + changeCss('.sidebar--left .nav-pills__container li>h4, .sidebar--left .add-channel-btn', 'color:' + changeOpacity(theme.sidebarText, 0.8), 1); changeCss('.sidebar--left .add-channel-btn:hover, .sidebar--left .add-channel-btn:focus', 'color:' + theme.sidebarText, 1); changeCss('.sidebar--left, .sidebar--right .sidebar--right__header', 'border-color:' + changeOpacity(theme.sidebarText, 0.2), 1); changeCss('.sidebar--left .status path', 'fill:' + changeOpacity(theme.sidebarText, 0.5), 1); @@ -409,25 +409,25 @@ export function applyTheme(theme) { } if (theme.sidebarUnreadText) { - changeCss('.sidebar--left .nav li>a.unread-title', 'color:' + theme.sidebarUnreadText + '!important;', 2); + changeCss('.sidebar--left .nav-pills__container li>a.unread-title', 'color:' + theme.sidebarUnreadText + '!important;', 2); } if (theme.sidebarTextHoverBg) { - changeCss('.sidebar--left .nav li>a:hover, .sidebar--left .nav li>a:focus, .settings-modal .nav-pills>li:hover a, .settings-modal .nav-pills>li:focus a', 'background:' + theme.sidebarTextHoverBg, 1); + changeCss('.sidebar--left .nav-pills__container li>a:hover, .sidebar--left .nav-pills__container li>a:focus, .settings-modal .nav-pills>li:hover a, .settings-modal .nav-pills>li:focus a', 'background:' + theme.sidebarTextHoverBg, 1); changeCss('@media(max-width: 768px){.settings-modal .settings-table .nav>li:hover a', 'background:' + theme.sidebarTextHoverBg, 1); } if (theme.sidebarTextHoverColor) { - changeCss('.sidebar--left .nav li>a:hover, .sidebar--left .nav li>a:focus, .settings-modal .nav-pills>li:hover a, .settings-modal .nav-pills>li:focus a', 'color:' + theme.sidebarTextHoverColor, 2); + changeCss('.sidebar--left .nav-pills__container li>a:hover, .sidebar--left .nav-pills__container li>a:focus, .settings-modal .nav-pills>li:hover a, .settings-modal .nav-pills>li:focus a', 'color:' + theme.sidebarTextHoverColor, 2); changeCss('@media(max-width: 768px){.settings-modal .settings-table .nav>li:hover a', 'color:' + theme.sidebarTextHoverColor, 2); } if (theme.sidebarTextActiveBg) { - changeCss('.sidebar--left .nav li.active a, .sidebar--left .nav li.active a:hover, .sidebar--left .nav li.active a:focus, .settings-modal .nav-pills>li.active a, .settings-modal .nav-pills>li.active a:hover, .settings-modal .nav-pills>li.active a:active', 'background:' + theme.sidebarTextActiveBg, 1); + changeCss('.sidebar--left .nav-pills__container li.active a, .sidebar--left .nav-pills__container li.active a:hover, .sidebar--left .nav-pills__container li.active a:focus, .settings-modal .nav-pills>li.active a, .settings-modal .nav-pills>li.active a:hover, .settings-modal .nav-pills>li.active a:active', 'background:' + theme.sidebarTextActiveBg, 1); } if (theme.sidebarTextActiveColor) { - changeCss('.sidebar--left .nav li.active a, .sidebar--left .nav li.active a:hover, .sidebar--left .nav li.active a:focus, .settings-modal .nav-pills>li.active a, .settings-modal .nav-pills>li.active a:hover, .settings-modal .nav-pills>li.active a:active', 'color:' + theme.sidebarTextActiveColor, 2); + changeCss('.sidebar--left .nav-pills__container li.active a, .sidebar--left .nav-pills__container li.active a:hover, .sidebar--left .nav-pills__container li.active a:focus, .settings-modal .nav-pills>li.active a, .settings-modal .nav-pills>li.active a:hover, .settings-modal .nav-pills>li.active a:active', 'color:' + theme.sidebarTextActiveColor, 2); } if (theme.sidebarHeaderBg) { @@ -462,27 +462,31 @@ export function applyTheme(theme) { } if (theme.centerChannelBg) { - changeCss('.app__content, .markdown__table, .markdown__table tbody tr, .command-box, .modal .modal-content', 'background:' + theme.centerChannelBg, 1); + changeCss('.app__content, .markdown__table, .markdown__table tbody tr, .command-box, .modal .modal-content, .mentions-name, .mentions--top .mentions-box', 'background:' + theme.centerChannelBg, 1); changeCss('#post-list .post-list-holder-by-time', 'background:' + theme.centerChannelBg, 1); changeCss('#post-create', 'background:' + theme.centerChannelBg, 1); changeCss('.date-separator .separator__text, .new-separator .separator__text', 'background:' + theme.centerChannelBg, 1); changeCss('.post-image__column .post-image__details', 'background:' + theme.centerChannelBg, 1); - changeCss('.sidebar--right', 'background:' + theme.centerChannelBg, 1); + changeCss('.sidebar--right, .dropdown-menu, .popover', 'background:' + theme.centerChannelBg, 1); } if (theme.centerChannelColor) { - changeCss('.app__content, .post-create__container .post-create-body .btn-file, .post-create__container .post-create-footer .msg-typing, .loading-screen .loading__content .round, .command-name, .modal .modal-content', 'color:' + theme.centerChannelColor, 1); + changeCss('.app__content, .post-create__container .post-create-body .btn-file, .post-create__container .post-create-footer .msg-typing, .loading-screen .loading__content .round, .command-name, .modal .modal-content, .dropdown-menu, .popover, .mentions-name', 'color:' + theme.centerChannelColor, 1); changeCss('#post-create', 'color:' + theme.centerChannelColor, 2); changeCss('.mentions--top, .command-box', 'box-shadow:' + changeOpacity(theme.centerChannelColor, 0.2) + ' 1px -3px 12px', 3); changeCss('.mentions--top, .command-box', '-webkit-box-shadow:' + changeOpacity(theme.centerChannelColor, 0.2) + ' 1px -3px 12px', 2); changeCss('.mentions--top, .command-box', '-moz-box-shadow:' + changeOpacity(theme.centerChannelColor, 0.2) + ' 1px -3px 12px', 1); + changeCss('.dropdown-menu, .popover ', 'box-shadow:' + changeOpacity(theme.centerChannelColor, 0.1) + ' 0px 6px 12px', 3); + changeCss('.dropdown-menu, .popover ', '-webkit-box-shadow:' + changeOpacity(theme.centerChannelColor, 0.1) + ' 0px 6px 12px', 2); + changeCss('.dropdown-menu, .popover ', '-moz-box-shadow:' + changeOpacity(theme.centerChannelColor, 0.1) + ' 0px 6px 12px', 1); changeCss('.post-body hr', 'background:' + theme.centerChannelColor, 1); changeCss('.channel-header .heading', 'color:' + theme.centerChannelColor, 1); changeCss('.markdown__table tbody tr:nth-child(2n)', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); changeCss('.channel-header__info>div.dropdown .header-dropdown__icon', 'color:' + changeOpacity(theme.centerChannelColor, 0.8), 1); changeCss('.channel-header #member_popover', 'color:' + changeOpacity(theme.centerChannelColor, 0.8), 1); - changeCss('.custom-textarea, .custom-textarea:focus, .preview-container .preview-div, .post-image__column .post-image__details, .sidebar--right .sidebar-right__body, .markdown__table th, .markdown__table td, .command-box, .modal .modal-content, .settings-modal .settings-table .settings-content .divider-light, .modal .modal-header', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); - changeCss('.command-name', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); + changeCss('.custom-textarea, .custom-textarea:focus, .preview-container .preview-div, .post-image__column .post-image__details, .sidebar--right .sidebar-right__body, .markdown__table th, .markdown__table td, .command-box, .modal .modal-content, .settings-modal .settings-table .settings-content .divider-light, .dropdown-menu, .modal .modal-header, .popover, .mentions--top .mentions-box', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); + changeCss('.command-name, .popover .popover-title', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 1); + changeCss('.dropdown-menu .divider', 'background:' + theme.centerChannelColor, 1); changeCss('.custom-textarea', 'color:' + theme.centerChannelColor, 1); changeCss('.post-image__column', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.2), 2); changeCss('.post-image__column .post-image__details', 'color:' + theme.centerChannelColor, 2); @@ -501,8 +505,8 @@ export function applyTheme(theme) { changeCss('@media(max-width: 1440px){.post.same--root', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.07), 2); changeCss('@media(max-width: 1800px){.inner__wrap.move--left .post.post--comment.same--root', 'border-color:' + changeOpacity(theme.centerChannelColor, 0.07), 2); changeCss('.post:hover, .sidebar--right .sidebar--right__header, .settings-modal .settings-table .settings-content .section-min:hover', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); - changeCss('.date-separator.hovered--before:after, .new-separator.hovered--before:after', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); - changeCss('.date-separator.hovered--after:before, .new-separator.hovered--after:before, .command-name:hover', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); + changeCss('.date-separator.hovered--before:after, .date-separator.hovered--after:before, .new-separator.hovered--after:before, .new-separator.hovered--before:after', 'background:' + changeOpacity(theme.centerChannelColor, 0.07), 1); + changeCss('.command-name:hover, .mentions-name:hover, .mentions-focus, .dropdown-menu>li>a:focus, .dropdown-menu>li>a:hover', 'background:' + changeOpacity(theme.centerChannelColor, 0.15), 1); changeCss('.post.current--user:hover .post-body ', 'background: none;', 1); changeCss('.sidebar--right', 'color:' + theme.centerChannelColor, 2); } diff --git a/web/sass-files/sass/partials/_admin-console.scss b/web/sass-files/sass/partials/_admin-console.scss index 11794a269..5037da415 100644 --- a/web/sass-files/sass/partials/_admin-console.scss +++ b/web/sass-files/sass/partials/_admin-console.scss @@ -144,7 +144,6 @@ } .popover { border-radius: 3px; - border: 1px solid #ccc; width: 100%; font-size: 0.95em; } diff --git a/web/sass-files/sass/partials/_base.scss b/web/sass-files/sass/partials/_base.scss index ba27e7fbc..fa465ff91 100644 --- a/web/sass-files/sass/partials/_base.scss +++ b/web/sass-files/sass/partials/_base.scss @@ -42,6 +42,21 @@ body { color: $primary-color; } } + .popover-title { + background: rgba(black, 0.1); + } +} + +.dropdown-menu { + .divider { + @include opacity(0.15); + } + > li > a { + color: inherit; + &:focus, &:hover { + color: inherit; + } + } } .word-break--all { diff --git a/web/sass-files/sass/partials/_headers.scss b/web/sass-files/sass/partials/_headers.scss index b5fcb6145..9b9e5f573 100644 --- a/web/sass-files/sass/partials/_headers.scss +++ b/web/sass-files/sass/partials/_headers.scss @@ -114,23 +114,6 @@ } } } - &.theme--black { - &:hover { - &:before { - background: rgba(white, 0.2); - } - } - } - &.theme--gray { - &:hover { - &:before { - background: rgba(white, 0.1); - } - } - } - a { - color: #fff; - } .navbar-right { font-size: 0.85em; position: absolute; @@ -145,7 +128,6 @@ .dropdown-menu { li a { padding: 3px 20px; - color: #555; text-overflow: ellipsis; overflow: hidden; } diff --git a/web/sass-files/sass/partials/_mentions.scss b/web/sass-files/sass/partials/_mentions.scss index 48746ba01..aff31e418 100644 --- a/web/sass-files/sass/partials/_mentions.scss +++ b/web/sass-files/sass/partials/_mentions.scss @@ -33,13 +33,6 @@ line-height: 36px; font-size: 13px; cursor: pointer; - &:hover { - background-color: #E6F2FA; - } -} - -.mentions-focus { - background-color: #E6F2FA; } .mentions-text { @@ -54,7 +47,6 @@ display: block; font-size: 20px; text-align: center; - color: #555; @include border-radius(32px); } diff --git a/web/sass-files/sass/partials/_sidebar--left.scss b/web/sass-files/sass/partials/_sidebar--left.scss index 6a418e270..0729e68c2 100644 --- a/web/sass-files/sass/partials/_sidebar--left.scss +++ b/web/sass-files/sass/partials/_sidebar--left.scss @@ -16,12 +16,6 @@ overflow-y: auto; max-width: 200px; width: 200px; - a { - color: #262626 !important; - &:hover, &:focus { - background: #f5f5f5 !important; - } - } } .search__form { margin: 0; @@ -98,7 +92,6 @@ padding: 3px 10px 3px 25px; line-height: 1.5; border-radius: 0; - color: #999; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; @@ -109,12 +102,8 @@ text-decoration: underline; } &.unread-title { - color: #333; font-weight: 600; } - &:hover, &:focus { - background: #e6f2fa; - } } &.active { a, a:hover, a:focus { -- cgit v1.2.3-1-g7c22 From c2d014b00a12f67faebfcfb279e5ccd4ccf14585 Mon Sep 17 00:00:00 2001 From: Asaad Mahmood Date: Mon, 5 Oct 2015 08:13:15 +0500 Subject: Increasing spacing for bottom unread notification --- web/sass-files/sass/partials/_sidebar--left.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'web') diff --git a/web/sass-files/sass/partials/_sidebar--left.scss b/web/sass-files/sass/partials/_sidebar--left.scss index 0729e68c2..73d702fef 100644 --- a/web/sass-files/sass/partials/_sidebar--left.scss +++ b/web/sass-files/sass/partials/_sidebar--left.scss @@ -69,7 +69,7 @@ top: 66px; } .nav-pills__unread-indicator-bottom { - bottom: 0px; + bottom: 10px; } .nav { -- cgit v1.2.3-1-g7c22