irongit
dotfiles/waybar/ModulesCustom
269 lines7.0 KB
1//* ---- 💫 https://github.com/JaKooLit 💫 ---- *//
2/* Waybar Modules - Custom Modules */
3/* Basically created to reduce the lines in Waybar Modules bank */
4/* NOTE: This is only for Custom Modules */
5/* Custom Modules like weather browser, tty, file manager at the beginning */
6
7{
8"custom/weather": {
9 "format": "{}",
10 "format-alt": "{alt}: {}",
11 "format-alt-click": "click",
12 "interval": 3600,
13 "return-type": "json",
14 "exec": "$HOME/.config/hypr/UserScripts/Weather.py",
15 //"exec": "$HOME/.config/hypr/UserScripts/Weather.sh",
16 //"exec-if": "ping wttr.in -c1",
17 "tooltip": true,
18},
19
20"custom/file_manager": {
21 "format": " ",
22 "on-click": "xdg-open . &",
23 "tooltip": true,
24 "tooltip-format": "File Manager",
25},
26
27"custom/tty": {
28 "format": " ",
29 "on-click": "$HOME/.config/hypr/scripts/WaybarScripts.sh --term",
30 "tooltip": true,
31 "tooltip-format": "Launch Terminal",
32},
33
34"custom/browser": {
35 "format": " ",
36 "on-click": "xdg-open https://",
37 "tooltip": true,
38 "tooltip-format": "Launch Browser",
39},
40
41"custom/settings": {
42 "format": " ",
43 "on-click": "$HOME/.config/hypr/scripts/Kool_Quick_Settings.sh",
44 "tooltip": true,
45 "tooltip-format": "Launch KooL Hyprland Settings Menu",
46},
47
48"custom/cycle_wall": {
49 "format": " ",
50 "on-click": "$HOME/.config/hypr/UserScripts/WallpaperSelect.sh",
51 "on-click-right": "$HOME/.config/hypr/UserScripts/WallpaperRandom.sh",
52 "on-click-middle": "$HOME/.config/hypr/scripts/WaybarStyles.sh",
53 "tooltip": true,
54 "tooltip-format": "Left Click: Wallpaper Menu\nMiddle Click: Random wallpaper\nRight Click: Waybar Styles Menu",
55},
56
57"custom/hint": {
58 "format": "󰺁 HINT!",
59 "on-click": "$HOME/.config/hypr/scripts/KeyHints.sh",
60 "on-click-right": "$HOME/.config/hypr/scripts/KeyBinds.sh",
61 "tooltip": true,
62 "tooltip-format": "Left Click: Quick Tips\nRight Click: Keybinds",
63},
64
65"custom/dot_update": {
66 "format": " 󰁈 ",
67 "on-click": "$HOME/.config/hypr/scripts/KooLsDotsUpdate.sh",
68 "tooltip": true,
69 "tooltip-format": "Check KooL Dots update\nIf available",
70},
71
72// Hypridle inhibitor
73"custom/hypridle": {
74 "format": "󱫗 ",
75 "return-type": "json",
76 "escape": true,
77 "exec-on-event": true,
78 "interval": 60,
79 "exec": "$HOME/.config/hypr/scripts/Hypridle.sh status",
80 "on-click": "$HOME/.config/hypr/scripts/Hypridle.sh toggle",
81 "on-click-right": "hyprlock"
82},
83
84"custom/keyboard": {
85 "exec": "cat $HOME/.cache/kb_layout",
86 "interval": 1,
87 "format": " {}",
88 "on-click": "$HOME/.config/hypr/scripts/SwitchKeyboardLayout.sh",
89},
90
91"custom/light_dark": {
92 "format": "󰔎 ",
93 "on-click": "$HOME/.config/hypr/scripts/DarkLight.sh",
94 "on-click-right": "$HOME/.config/hypr/scripts/WaybarStyles.sh",
95 "on-click-middle": "$HOME/.config/hypr/UserScripts/WallpaperSelect.sh",
96 "tooltip": true,
97 "tooltip-format": "Left Click: Switch Dark-Light Themes\nMiddle Click: Wallpaper Menu\nRight Click: Waybar Styles Menu",
98},
99
100"custom/lock": {
101 "format": "󰌾",
102 "on-click": "$HOME/.config/hypr/scripts/LockScreen.sh",
103 "tooltip": true,
104 "tooltip-format": "󰷛 Screen Lock",
105},
106
107"custom/menu": {
108 "format": "  ",
109 "on-click": "pkill rofi || rofi -show drun -modi run,drun,filebrowser,window",
110 "on-click-middle": "$HOME/.config/hypr/UserScripts/WallpaperSelect.sh",
111 "on-click-right": "$HOME/.config/hypr/scripts/WaybarLayout.sh",
112 "tooltip": true,
113 "tooltip-format": "Left Click: Rofi Menu\nMiddle Click: Wallpaper Menu\nRight Click: Waybar Layout Menu",
114},
115// This is a custom cava visualizer
116"custom/cava_mviz": {
117 "exec": "$HOME/.config/hypr/scripts/WaybarCava.sh",
118 "format": "{}"
119},
120
121"custom/playerctl": {
122 "format": "<span>{}</span>",
123 "return-type": "json",
124 "max-length": 25,
125 "exec": "playerctl -a metadata --format '{\"text\": \"{{artist}} {{markup_escape(title)}}\", \"tooltip\": \"{{playerName}} : {{markup_escape(title)}}\", \"alt\": \"{{status}}\", \"class\": \"{{status}}\"}' -F",
126 "on-click-middle": "playerctl play-pause",
127 "on-click": "playerctl previous",
128 "on-click-right": "playerctl next",
129 "scroll-step": 5.0,
130 "on-scroll-up": "$HOME/.config/hypr/scripts/Volume.sh --inc",
131 "on-scroll-down": "$HOME/.config/hypr/scripts/Volume.sh --dec",
132 "smooth-scrolling-threshold": 1,
133},
134
135"custom/power": {
136 "format": " ⏻ ",
137 "on-click": "$HOME/.config/hypr/scripts/Wlogout.sh",
138 "on-click-right": "$HOME/.config/hypr/scripts/ChangeBlur.sh",
139 "tooltip": true,
140 "tooltip-format": "Left Click: Logout Menu\nRight Click: Change Blur",
141},
142
143"custom/reboot": {
144 "format": "󰜉",
145 "on-click": "systemctl reboot",
146 "tooltip": true,
147 "tooltip-format": "Left Click: Reboot",
148},
149
150"custom/quit": {
151 "format": "󰗼",
152 "on-click": "hyprctl dispatch exit",
153 "tooltip": true,
154 "tooltip-format": "Left Click: Exit Hyprland",
155},
156
157"custom/swaync": {
158 "tooltip": true,
159 "tooltip-format": "Left Click: Launch Notification Center\nRight Click: Do not Disturb",
160 "format": "{} {icon} ",
161 "format-icons": {
162 "notification": "<span foreground='red'><sup></sup></span>",
163 "none": "",
164 "dnd-notification": "<span foreground='red'><sup></sup></span>",
165 "dnd-none": "",
166 "inhibited-notification": "<span foreground='red'><sup></sup></span>",
167 "inhibited-none": "",
168 "dnd-inhibited-notification": "<span foreground='red'><sup></sup></span>",
169 "dnd-inhibited-none": ""
170 },
171 "return-type": "json",
172 "exec-if": "which swaync-client",
173 "exec": "swaync-client -swb",
174 "on-click": "sleep 0.1 && swaync-client -t -sw",
175 "on-click-right": "swaync-client -d -sw",
176 "escape": true,
177},
178// NOTE:! This is mainly for Arch and Arch Based Distros depend: pacman-contrib
179// Other Distro dont have notifications but can use to check for update for any other distro
180"custom/updater": {
181 "format": " {}",
182 "exec": "checkupdates | wc -l",
183 "exec-if": "[[ $(checkupdates | wc -l) ]]",
184 "interval": 43200, // (Arch Linux will try to check 12 hrs interval only
185 "on-click": "$HOME/.config/hypr/scripts/Distro_update.sh",
186 "tooltip": true,
187 "tooltip-format": "Left Click: Update System\nArch (w/ notification)\nFedora, OpenSuse, Debian/Ubuntu click to update",
188},
189// Separators
190"custom/separator#dot": {
191 "format": "",
192 "interval": "once",
193 "tooltip": false
194},
195"custom/separator#dot-line": {
196 "format": "",
197 "interval": "once",
198 "tooltip": false
199},
200"custom/separator#line": {
201 "format": "|",
202 "interval": "once",
203 "tooltip": false
204},
205"custom/separator#blank": {
206 "format": "",
207 "interval": "once",
208 "tooltip": false
209},
210"custom/separator#blank_2": {
211 "format": " ",
212 "interval": "once",
213 "tooltip": false
214},
215"custom/separator#blank_3": {
216 "format": " ",
217 "interval": "once",
218 "tooltip": false
219},
220"custom/arrow1": {
221 "format": "",
222 "tooltip": false
223},
224
225"custom/arrow2": {
226 "format": "",
227 "tooltip": false
228},
229
230"custom/arrow3": {
231 "format": "",
232 "tooltip": false
233},
234
235"custom/arrow4": {
236 "format": "",
237 "tooltip": false
238},
239
240"custom/arrow5": {
241 "format": "",
242 "tooltip": false
243},
244
245"custom/arrow6": {
246 "format": "",
247 "tooltip": false
248},
249
250"custom/arrow7": {
251 "format": "",
252 "tooltip": false
253},
254
255"custom/arrow8": {
256 "format": "",
257 "tooltip": false
258},
259
260"custom/arrow9": {
261 "format": "",
262 "tooltip": false
263},
264
265"custom/arrow10": {
266 "format": "",
267 "tooltip": false
268}
269}