@@ -8,7 +8,6 @@ var Panel_Holder;
88var Hui ;
99var Lovelace ;
1010var Animated_Config ;
11- var View_Layout ;
1211var Haobj = null ;
1312var View ;
1413var Debug_Mode = false ;
@@ -56,7 +55,7 @@ function getVars() {
5655 Root = Root && Root . shadowRoot ;
5756 Root = Root && Root . querySelector ( "home-assistant-main" ) ;
5857 Root = Root && Root . shadowRoot ;
59- Root = Root && Root . querySelector ( "app-drawer-layout partial-panel-resolver" ) ;
58+ Root = Root && Root . querySelector ( "app-drawer-layout partial-panel-resolver, ha-drawer partial-panel-resolver " ) ;
6059 Root = ( Root && Root . shadowRoot ) || Root ;
6160 Root = Root && Root . querySelector ( "ha-panel-lovelace" ) ;
6261 if ( Root ) {
@@ -70,7 +69,6 @@ function getVars() {
7069 if ( Lovelace ) {
7170 Animated_Config = Lovelace . config . animated_background ;
7271 }
73- View_Layout = Root . shadowRoot . getElementById ( "layout" ) ;
7472 View = Root . shadowRoot . getElementById ( "view" ) ;
7573 }
7674}
@@ -535,15 +533,13 @@ function removeDefaultBackground(node, current_config) {
535533 if ( current_config . background ) {
536534 background = current_config . background ;
537535 }
538- if ( node . style . background != background || View_Layout . style . background != 'transparent' ) {
536+ if ( node . style . background != background ) {
539537 node . style . background = background ;
540- View_Layout . style . background = 'transparent' ;
541538 }
542539}
543540
544541//restores lovelace theme background
545542function restoreDefaultBackground ( node ) {
546- View_Layout . style . background = null ;
547543 node . style . background = null ;
548544}
549545
0 commit comments