@@ -97,6 +97,8 @@ public function getCSSVariables(): array {
9797 '--color-main-background ' => $ colorMainBackground ,
9898 '--color-main-background-rgb ' => $ colorMainBackgroundRGB ,
9999 '--color-main-background-translucent ' => 'rgba(var(--color-main-background-rgb), .97) ' ,
100+ '--color-main-background-blur ' => 'rgba(var(--color-main-background-rgb), .8) ' ,
101+ '--filter-background-blur ' => 'blur(25px) ' ,
100102
101103 // to use like this: background-image: linear-gradient(0, var('--gradient-main-background));
102104 '--gradient-main-background ' => 'var(--color-main-background) 0%, var(--color-main-background-translucent) 85%, transparent 100% ' ,
@@ -190,26 +192,30 @@ public function getCSSVariables(): array {
190192 '--primary-invert-if-bright ' => $ this ->util ->invertTextColor ($ this ->primaryColor ) ? 'invert(100%) ' : 'no ' ,
191193 '--background-invert-if-dark ' => 'no ' ,
192194 '--background-invert-if-bright ' => 'invert(100%) ' ,
195+
196+ '--image-main-background ' => "url(' " . $ this ->urlGenerator ->imagePath ('core ' , 'app-background.jpg ' ) . "') " ,
193197 ];
194198
195199 $ backgroundDeleted = $ this ->config ->getAppValue ('theming ' , 'backgroundMime ' , '' ) === 'backgroundColor ' ;
196200 // If primary as background has been request or if we have a custom primary colour
197201 // let's not define the background image
198202 if ($ backgroundDeleted || $ hasCustomPrimaryColour ) {
199203 $ variables ["--image-background-plain " ] = 'true ' ;
200- }
204+ }
201205
202206 // Register image variables only if custom-defined
203207 foreach (['logo ' , 'logoheader ' , 'favicon ' , 'background ' ] as $ image ) {
204208 if ($ this ->imageManager ->hasImage ($ image )) {
209+ $ imageUrl = $ this ->imageManager ->getImageUrl ($ image );
205210 if ($ image === 'background ' ) {
206211 // If background deleted is set, ignoring variable
207212 if ($ backgroundDeleted ) {
208213 continue ;
209- }
214+ }
210215 $ variables ['--image-background-size ' ] = 'cover ' ;
216+ $ variables ['--image-main-background ' ] = "url(' " . $ imageUrl . "') " ;
211217 }
212- $ variables ["--image- $ image " ] = "url(' " . $ this -> imageManager -> getImageUrl ( $ image ). "') " ;
218+ $ variables ["--image- $ image " ] = "url(' " . $ imageUrl . "') " ;
213219 }
214220 }
215221
0 commit comments