From 0e10f65d4396c65cab9d2c6e04d50d2dd7541b7d Mon Sep 17 00:00:00 2001 From: Dwain Scheeren Date: Fri, 3 Dec 2021 21:42:55 +0100 Subject: [PATCH] Fix background header bug --- .gitignore | 2 ++ .../cards/dwains-header-card/dwains-header-card.js | 2 +- .../cards/dwains-header-card/package-lock.json | 6 +----- .../dwains_dashboard/cards/dwains-header-card/src/main.js | 2 +- .../lovelace/themefiles/dwains-theme-black.yaml | 1 + .../lovelace/themefiles/dwains-theme-dark.yaml | 1 + .../lovelace/themefiles/dwains-theme-light.yaml | 1 + .../dwains_dashboard/lovelace/translations/sk.yaml | 0 .../dwains_dashboard/lovelace/views/main/01.homepage.yaml | 2 +- 9 files changed, 9 insertions(+), 8 deletions(-) mode change 100644 => 100755 custom_components/dwains_dashboard/lovelace/translations/sk.yaml diff --git a/.gitignore b/.gitignore index 278fc312..8046ce5f 100755 --- a/.gitignore +++ b/.gitignore @@ -42,3 +42,5 @@ image/ blueprints/ ._* .fuse_hidden002e3c9700002485 +home-assistant.log.1 +home-assistant.log.fault diff --git a/custom_components/dwains_dashboard/cards/dwains-header-card/dwains-header-card.js b/custom_components/dwains_dashboard/cards/dwains-header-card/dwains-header-card.js index 0e8ff1b3..bff31e19 100755 --- a/custom_components/dwains_dashboard/cards/dwains-header-card/dwains-header-card.js +++ b/custom_components/dwains_dashboard/cards/dwains-header-card/dwains-header-card.js @@ -23,7 +23,7 @@ `}set hass(e){this.card&&(this.card.hass=e)}_handleClick(){let e,t=window.location.pathname,o=t.substring(0,t.lastIndexOf("/"))+"/"+this._config.navigation_path;window.history.pushState(null,"",o),e=new Event("location-changed",{composed:!0}),e.detail={replace:!1},window.dispatchEvent(e)}static get styles(){return[r` ha-card { - background-color: var(--app-header-background-color); + background-color: var(--app-header-background-color2); color: var(--app-header-text-color, white); margin-top: -2px; padding-left: 16px; diff --git a/custom_components/dwains_dashboard/cards/dwains-header-card/package-lock.json b/custom_components/dwains_dashboard/cards/dwains-header-card/package-lock.json index 270c65d5..445928cf 100755 --- a/custom_components/dwains_dashboard/cards/dwains-header-card/package-lock.json +++ b/custom_components/dwains_dashboard/cards/dwains-header-card/package-lock.json @@ -759,7 +759,6 @@ "dependencies": { "anymatch": "~3.1.1", "braces": "~3.0.2", - "fsevents": "~2.3.1", "glob-parent": "~5.1.0", "is-binary-path": "~2.1.0", "is-glob": "~4.0.1", @@ -4172,10 +4171,8 @@ "integrity": "sha512-9P3MWk6SrKjHsGkLT2KHXdQ/9SNkyoJbabxnKOoJepsvJjJG8uYTR3yTPxPQvNDI3w4Nz1xnE0TLHK4RIVe/MQ==", "dev": true, "dependencies": { - "chokidar": "^3.4.1", "graceful-fs": "^4.1.2", - "neo-async": "^2.5.0", - "watchpack-chokidar2": "^2.0.1" + "neo-async": "^2.5.0" }, "optionalDependencies": { "chokidar": "^3.4.1", @@ -4237,7 +4234,6 @@ "anymatch": "^2.0.0", "async-each": "^1.0.1", "braces": "^2.3.2", - "fsevents": "^1.2.7", "glob-parent": "^3.1.0", "inherits": "^2.0.3", "is-binary-path": "^1.0.0", diff --git a/custom_components/dwains_dashboard/cards/dwains-header-card/src/main.js b/custom_components/dwains_dashboard/cards/dwains-header-card/src/main.js index 74734aae..12338f22 100755 --- a/custom_components/dwains_dashboard/cards/dwains-header-card/src/main.js +++ b/custom_components/dwains_dashboard/cards/dwains-header-card/src/main.js @@ -80,7 +80,7 @@ Promise.race(bases).then(() => { return [ css` ha-card { - background-color: var(--app-header-background-color); + background-color: var(--app-header-background-color2); color: var(--app-header-text-color, white); margin-top: -2px; padding-left: 16px; diff --git a/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-black.yaml b/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-black.yaml index 9d5818c1..b3f4d3f2 100755 --- a/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-black.yaml +++ b/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-black.yaml @@ -68,6 +68,7 @@ dwains-theme-black: #iOS app app-header-background-color: 'var(--dwains-theme-primary)' + app-header-background-color2: 'var(--dwains-theme-primary)' #Lights dwains-theme-unavailable: '#303030' diff --git a/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-dark.yaml b/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-dark.yaml index 76e2eef3..5ecac592 100755 --- a/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-dark.yaml +++ b/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-dark.yaml @@ -68,6 +68,7 @@ dwains-theme-dark: #iOS app app-header-background-color: 'var(--dwains-theme-primary)' + app-header-background-color2: 'var(--dwains-theme-primary)' #Lights dwains-theme-unavailable: '#303030' diff --git a/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-light.yaml b/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-light.yaml index fd284301..8254c209 100755 --- a/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-light.yaml +++ b/custom_components/dwains_dashboard/lovelace/themefiles/dwains-theme-light.yaml @@ -14,6 +14,7 @@ dwains-theme-light: dwains-theme-header-button-background: '#1c1c1e' app-header-background-color: 'var(--dwains-theme-header-background)' + app-header-background-color2: 'var(--dwains-theme-header-background)' app-header-text-color: 'var(--dwains-theme-header-text)' ## Lovelace Theme diff --git a/custom_components/dwains_dashboard/lovelace/translations/sk.yaml b/custom_components/dwains_dashboard/lovelace/translations/sk.yaml old mode 100644 new mode 100755 diff --git a/custom_components/dwains_dashboard/lovelace/views/main/01.homepage.yaml b/custom_components/dwains_dashboard/lovelace/views/main/01.homepage.yaml index a911f305..e48e0e6c 100755 --- a/custom_components/dwains_dashboard/lovelace/views/main/01.homepage.yaml +++ b/custom_components/dwains_dashboard/lovelace/views/main/01.homepage.yaml @@ -55,7 +55,7 @@ - type: custom:dwains-wrapper-card css: | padding: 0px; - background-color: var(--app-header-background-color); + background-color: var(--app-header-background-color2); color: var(--app-header-text-color, white); border-radius: 0; overflow: hidden;