From 19b486e676dbf824e7d806c5f6a0eca0ba3db812 Mon Sep 17 00:00:00 2001 From: Pedro Galhardo Date: Tue, 26 Jul 2022 16:56:17 +0100 Subject: [PATCH] Add compact artist header option (#1308) * Support compact artist header (optional) * Add required term --- src/i18n/README.md | 6 +++++- src/i18n/en_US.json | 1 + src/i18n/source/en_US.json | 1 + src/renderer/less/pages.less | 14 ++++++++----- .../views/components/settings-window.ejs | 20 +++++++++++++------ src/renderer/views/pages/artist.ejs | 2 +- 6 files changed, 31 insertions(+), 13 deletions(-) diff --git a/src/i18n/README.md b/src/i18n/README.md index cf5f1de4..5ab6cba6 100644 --- a/src/i18n/README.md +++ b/src/i18n/README.md @@ -520,4 +520,8 @@ Update 23/06/2022 04:00 UTC Update 03/07/2022 20:00 UTC * `term.plugins`: Added to `en_US` -* `settings.header.visual.styles`: Added to `en_US` \ No newline at end of file +* `settings.header.visual.styles`: Added to `en_US` + +Update 25/07/2022 00:22 UTC + +* `settings.option.visual.compactArtistHeader`: Added to `en_US` diff --git a/src/i18n/en_US.json b/src/i18n/en_US.json index d8b8d5a8..71ef359a 100644 --- a/src/i18n/en_US.json +++ b/src/i18n/en_US.json @@ -565,6 +565,7 @@ "settings.option.visual.customAccentColor": "Custom Accent Color", "settings.option.visual.accentColor": "Accent Color", "settings.option.visual.purplePodcastPlaybackBar": "Purple Playback Bar for Podcasts", + "settings.option.visual.compactArtistHeader": "Compact Artist Header", "settings.option.visual.windowColor": "Window Tint Color", "settings.header.visual.windowBackgroundStyle.color": "Color Tint", "settings.header.advanced": "Advanced", diff --git a/src/i18n/source/en_US.json b/src/i18n/source/en_US.json index b01419a5..ba797af7 100644 --- a/src/i18n/source/en_US.json +++ b/src/i18n/source/en_US.json @@ -563,6 +563,7 @@ "settings.option.visual.customAccentColor": "Custom Accent Color", "settings.option.visual.accentColor": "Accent Color", "settings.option.visual.purplePodcastPlaybackBar": "Purple Playback Bar for Podcasts", + "settings.option.visual.compactArtistHeader": "Compact Artist Header", "settings.option.visual.windowColor": "Window Tint Color", "settings.header.visual.windowBackgroundStyle.color": "Color Tint", "settings.header.advanced": "Advanced", diff --git a/src/renderer/less/pages.less b/src/renderer/less/pages.less index d0c7a774..ca133d63 100644 --- a/src/renderer/less/pages.less +++ b/src/renderer/less/pages.less @@ -109,7 +109,7 @@ background: var(--color2); padding: 0px; overflow-y: overlay; - + .list-group-item { border-radius: 0px; } @@ -193,11 +193,11 @@ .list-group-item { padding: 12px 6px; - + &:hover { filter: brightness(1.2); } - + &:active { filter: brightness(0.8); } @@ -210,7 +210,7 @@ padding: 0px; width: 100%; overflow: hidden; - + .stylestack-editor { padding-bottom: 16px; } @@ -1240,6 +1240,10 @@ min-height: 80vh; } + &.animated .artist-header-compact { + min-height: 40vh; + } + .artist-header { //background: linear-gradient(45deg, var(--keyColor), #0e0e0e); color: white; @@ -2255,7 +2259,7 @@ .settings-tab-content { height:100%; } - + &.no-sidebar { .gh-header { >.row { diff --git a/src/renderer/views/components/settings-window.ejs b/src/renderer/views/components/settings-window.ejs index 246f7535..8e4c4f08 100644 --- a/src/renderer/views/components/settings-window.ejs +++ b/src/renderer/views/components/settings-window.ejs @@ -547,6 +547,14 @@ :disabled="app.cfg.visual.customAccentColor" switch/> +
+
+ {{$root.getLz('settings.option.visual.compactArtistHeader')}} +
+
+ +
+
{{$root.getLz('settings.option.visual.hardwareAcceleration')}}
@@ -771,19 +779,19 @@ - + - - + + - + - - + + diff --git a/src/renderer/views/pages/artist.ejs b/src/renderer/views/pages/artist.ejs index 2276aedf..5c273361 100644 --- a/src/renderer/views/pages/artist.ejs +++ b/src/renderer/views/pages/artist.ejs @@ -1,7 +1,7 @@