Merge pull request #4554 from nimbleape/pwa-taskbar-colour-follow-theme
set the meta tag for theme-color to the same theme css backgroundpull/21833/head
						commit
						19bb678dd6
					
				| 
						 | 
				
			
			@ -242,6 +242,10 @@ export async function setTheme(theme) {
 | 
			
		|||
                if (a == styleElements[stylesheetName]) return;
 | 
			
		||||
                a.disabled = true;
 | 
			
		||||
            });
 | 
			
		||||
            const bodyStyles = global.getComputedStyle(document.getElementsByTagName("body")[0]);
 | 
			
		||||
            if (bodyStyles.backgroundColor) {
 | 
			
		||||
                document.querySelector('meta[name="theme-color"]').content = bodyStyles.backgroundColor;
 | 
			
		||||
            }
 | 
			
		||||
            Tinter.setTheme(theme);
 | 
			
		||||
            resolve();
 | 
			
		||||
        };
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue