From 77cfcc84a81f1e629895d7f2019a318d1a11de30 Mon Sep 17 00:00:00 2001 From: btzr-io Date: Sat, 28 Jul 2018 15:27:28 -0600 Subject: [PATCH] reduce !important rule usage and fix fullscreen styles --- .../scss/component/_markdown-editor.scss | 48 ++++++++++--------- 1 file changed, 26 insertions(+), 22 deletions(-) diff --git a/src/renderer/scss/component/_markdown-editor.scss b/src/renderer/scss/component/_markdown-editor.scss index 794e3e651..f6241e5d1 100644 --- a/src/renderer/scss/component/_markdown-editor.scss +++ b/src/renderer/scss/component/_markdown-editor.scss @@ -1,62 +1,66 @@ .CodeMirror { - background: var(--color-canvas); border: 0px; border-radius: 0px; + background: var(--card-bg); color: var(--text-color); - box-shadow: var(--box-shadow-layer); } .editor-toolbar { - opacity: 1 !important; - border: 0 !important; + opacity: 1; + border: 0; background: var(--color-bg-alt); - border-radius: 0 !important; + border-radius: 0; box-shadow: var(--box-shadow-layer); } +.editor-toolbar:hover { + opacity: 1; +} + .editor-toolbar i.separator { - border: 0 !important; - border-right: var(--divider) !important; + border: 0; } .editor-toolbar.fullscreen { - background: var(--color-bg) !important; + background: var(--color-bg-alt); } -div.editor-toolbar a { - opacity: 0.64; +.editor-toolbar.fullscreen::before, +.editor-toolbar.fullscreen::after { + display: none; +} + +.editor-toolbar a { + opacity: 0.6; color: var(--text-color) !important; + transition: opacity 0.3s ease; } .editor-toolbar a.active, .editor-toolbar a:hover { opacity: 1; - background: var(--button-bg) !important; - border-color: transparent !important; + background: var(--button-bg); + border-color: transparent; } .editor-toolbar.disabled-for-preview a:not(.no-disable) { - background: var(--color-bg-alt) !important; - border-color: transparent !important; + background: var(--color-bg-alt); + border-color: transparent; + opacity: 0.3; } .editor-statusbar { - color: var(--form-label-color) !important; + color: var(--form-label-color); } .editor-preview { font-size: calc(var(--font-size-subtext-multiple) * 1em); - background: var(--color-bg) !important; + background: var(--color-bg); border: 0; } -.editor-preview-side { - background: var(--color-bg-alt) !important; - border: 1px solid var(--input-border-color) !important; -} - .CodeMirror .CodeMirror-cursor { - border-color: var(--color-primary) !important; + border-color: var(--color-primary); } .CodeMirror .CodeMirror-placeholder {