waybar: add basic setup
This commit is contained in:
		
							parent
							
								
									890fcfc6ce
								
							
						
					
					
						commit
						35c774b55e
					
				
					 2 changed files with 112 additions and 0 deletions
				
			
		
							
								
								
									
										39
									
								
								modules/desktop/addons/waybar.css
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										39
									
								
								modules/desktop/addons/waybar.css
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,39 @@ | |||
| @define-color foreground #eeeeee; | ||||
| @define-color foreground-inactive #aaaaaa; | ||||
| @define-color background #000000; | ||||
| 
 | ||||
| * { | ||||
|   font-family: JetBrainsMono Nerd Font; | ||||
|   font-size: 17px; | ||||
|   padding: 0; | ||||
|   margin: 0; | ||||
| } | ||||
| 
 | ||||
| #waybar { | ||||
|   color: @foreground; | ||||
|   background-color: @background; | ||||
| } | ||||
| 
 | ||||
| #workspaces button { | ||||
|   color: @foreground; | ||||
|   padding-right: .5em | ||||
| } | ||||
| 
 | ||||
| #workspaces button.empty { | ||||
|   color: @foreground-inactive; | ||||
| } | ||||
| 
 | ||||
| #memory, | ||||
| #custom-platform-profile { | ||||
|   padding-left: 1em | ||||
| } | ||||
| 
 | ||||
| #wireplumber, | ||||
| #battery, | ||||
| #idle_inhibitor, | ||||
| #language, | ||||
| #network, | ||||
| #bluetooth, | ||||
| #tray { | ||||
|   padding-right: 1em | ||||
| } | ||||
|  | @ -1,3 +1,76 @@ | |||
| { | ||||
|   flake.modules.homeManager.cholli = | ||||
|     { lib, osConfig, ... }: | ||||
|     { | ||||
| 
 | ||||
|       config = lib.mkIf osConfig.programs.niri.enable { | ||||
|         programs.waybar = { | ||||
|           enable = true; | ||||
|           style = ./waybar.css; | ||||
|           settings = { | ||||
|             topBar = { | ||||
|               layer = "top"; | ||||
|               position = "top"; | ||||
|               output = "DP-1"; | ||||
|               height = 30; | ||||
|               spacing = 2; | ||||
|               modules-left = [ "niri/workspaces" ]; | ||||
|               modules-center = [ "clock" ]; | ||||
|               modules-right = [ | ||||
|                 "idle_inhibitor" | ||||
|                 "bluetooth" | ||||
|                 "wireplumber" | ||||
|                 "cpu" | ||||
|                 "memory" | ||||
|                 "tray" | ||||
|               ]; | ||||
|               "niri/workspaces" = { | ||||
|                 "format" = "<span size='larger'>{icon}</span>"; | ||||
|                 "on-click" = "activate"; | ||||
|                 "format-icons" = { | ||||
|                   "active" = ""; | ||||
|                   "default" = ""; | ||||
|                 }; | ||||
|                 "icon-size" = 10; | ||||
|                 "sort-by-number" = true; | ||||
|               }; | ||||
|               "clock" = { | ||||
|                 "format" = "{:%d.%m.%Y | %H:%M}"; | ||||
|               }; | ||||
|               "wireplumber" = { | ||||
|                 "format" = " {volume}%"; | ||||
|                 "max-volume" = 100; | ||||
|                 "scroll-step" = 5; | ||||
|               }; | ||||
|               "cpu" = { | ||||
|                 "format" = " {usage}%"; | ||||
|               }; | ||||
|               "memory" = { | ||||
|                 "interval" = 30; | ||||
|                 "format" = " {used:0.1f}G "; | ||||
|               }; | ||||
|               "bluetooth" = { | ||||
|                 "format" = ""; | ||||
|                 "format-disabled" = ""; | ||||
|                 "format-connected" = ""; | ||||
|                 "tooltip-format" = "{controller_alias}\t{controller_address}"; | ||||
|                 "tooltip-format-connected" = "{controller_alias}\t{controller_address}\n\n{device_enumerate}"; | ||||
|                 "tooltip-format-enumerate-connected" = "{device_alias}\t{device_address}"; | ||||
|               }; | ||||
|               "tray" = { | ||||
|                 "icon-size" = 16; | ||||
|                 "spacing" = 16; | ||||
|               }; | ||||
|               "idle_inhibitor" = { | ||||
|                 "format" = "{icon}"; | ||||
|                 "format-icons" = { | ||||
|                   "activated" = ""; | ||||
|                   "deactivated" = ""; | ||||
|                 }; | ||||
|               }; | ||||
|             }; | ||||
|           }; | ||||
|         }; | ||||
|       }; | ||||
|     }; | ||||
| } | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue