From b07d7d7229c376a0588d86ee8a28735bdcf99b7f Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Fri, 23 Nov 2018 11:36:36 +0300 Subject: reset buttons, better disabled for shadows --- src/components/style_switcher/style_switcher.js | 4 ++ src/components/style_switcher/style_switcher.scss | 54 +++++++++++++++++++---- src/components/style_switcher/style_switcher.vue | 21 +++++++-- 3 files changed, 66 insertions(+), 13 deletions(-) (limited to 'src/components/style_switcher') diff --git a/src/components/style_switcher/style_switcher.js b/src/components/style_switcher/style_switcher.js index e1a17837..d45ce455 100644 --- a/src/components/style_switcher/style_switcher.js +++ b/src/components/style_switcher/style_switcher.js @@ -369,6 +369,10 @@ export default { }) }, + clearAll () { + this.normalizeLocalState(this.$store.state.config.customTheme) + }, + // Clears all the extra stuff when loading V1 theme clearV1 () { Object.keys(this.$data) diff --git a/src/components/style_switcher/style_switcher.scss b/src/components/style_switcher/style_switcher.scss index 9cdc9f33..ad203856 100644 --- a/src/components/style_switcher/style_switcher.scss +++ b/src/components/style_switcher/style_switcher.scss @@ -63,15 +63,16 @@ margin: 0 -1em; } + .reset-container { + flex-wrap: wrap; + } + + .reset-container, .apply-container, .radius-container, .color-container, { display: flex; - - p { - margin-left: 1em - } } .radius-container { @@ -93,7 +94,38 @@ margin: 1em 1em 0; } - .shadow-selector, + .tab-header { + display: flex; + justify-content: space-between; + align-items: baseline; + width: 100%; + min-height: 30px; + + .btn { + min-width: 1px; + flex: 0 auto; + padding: 0 1em; + } + + p { + flex: 1; + margin: 0; + } + + margin-bottom: 1em; + } + + .shadow-selector { + .override { + flex: 1; + margin-left: .5em; + } + .select-container { + margin-top: -4px; + margin-bottom: -3px; + } + } + .save-load, .save-load-options { display: flex; @@ -102,11 +134,8 @@ .import-export { display: flex; - - .btn { - margin-left: .5em; - } } + .override { margin-left: .5em; } @@ -132,6 +161,7 @@ background-position: 50% 50%; .btn { + margin-left: 0; margin-top: 1em; min-height: 30px; width: 10em; @@ -153,6 +183,7 @@ &.wide { min-width: 60% } + &:not(.wide):nth-child(2n+1) { margin-right: 7px; @@ -200,6 +231,11 @@ padding: 20px; } + .btn { + margin-left: .25em; + margin-right: .25em; + } + .dummy { .avatar { background: linear-gradient(135deg, #b8e1fc 0%,#a9d2f3 10%,#90bae4 25%,#90bcea 37%,#90bff0 50%,#6ba8e5 51%,#a2daf5 83%,#bdf3fd 100%); diff --git a/src/components/style_switcher/style_switcher.vue b/src/components/style_switcher/style_switcher.vue index ed0dd733..9e5cffbe 100644 --- a/src/components/style_switcher/style_switcher.vue +++ b/src/components/style_switcher/style_switcher.vue @@ -71,10 +71,13 @@ -

{{$t('settings.theme_help')}}

+
+

{{$t('settings.theme_help')}}

+ +

{{ $t('settings.style.common_colors.main') }}

@@ -106,6 +109,11 @@
+
+

{{$t('settings.theme_help')}}

+ + +

{{ $t('settings.style.advanced_colors.alert') }}

@@ -159,7 +167,10 @@
-

{{$t('settings.radii_help')}}

+
+

{{$t('settings.radii_help')}}

+ +
@@ -171,8 +182,8 @@
-
-
+
+
{{$t('settings.style.shadows.component')}}