mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 11:39:01 +01:00 
			
		
		
		
	feat(electron): load overlay information from CSS
This commit is contained in:
		
							parent
							
								
									60192977c9
								
							
						
					
					
						commit
						01512152ea
					
				| @ -50,10 +50,11 @@ function initOnElectron() { | ||||
|     // Update the native title bar buttons.
 | ||||
|     const electronRemote = utils.dynamicRequire("@electron/remote"); | ||||
|     const currentWindow = electronRemote.getCurrentWindow(); | ||||
|     const documentStyle = window.getComputedStyle(document.documentElement);     | ||||
|     currentWindow.setTitleBarOverlay({ | ||||
|         color: "red", | ||||
|         symbolColor: "white" | ||||
|         color: documentStyle.getPropertyValue("--native-titlebar-background"), | ||||
|         symbolColor: documentStyle.getPropertyValue("--native-titlebar-foreground") | ||||
|     }); | ||||
| 
 | ||||
|      | ||||
|     console.log("Electron initialized."); | ||||
| } | ||||
| @ -21,6 +21,8 @@ | ||||
| 
 | ||||
| :root { | ||||
|     --submenu-opening-delay: 300ms; | ||||
|     --native-titlebar-background: var(--left-pane-background-color); | ||||
|     --native-titlebar-foreground: var(--main-text-color); | ||||
| } | ||||
| 
 | ||||
| html { | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Elian Doran
						Elian Doran