panel waybar
This commit is contained in:
parent
cb08eb1194
commit
f3e2b5c264
150
rockethype/config/waybar/config
Executable file
150
rockethype/config/waybar/config
Executable file
@ -0,0 +1,150 @@
|
||||
{
|
||||
"position": "top",
|
||||
"layer": "top",
|
||||
"modules-left": [
|
||||
"custom/launch",
|
||||
"cpu",
|
||||
"memory",
|
||||
"custom/tempcpu",
|
||||
"custom/tempgpu"
|
||||
],
|
||||
"modules-center": ["wlr/workspaces"],
|
||||
"modules-right": [
|
||||
"tray",
|
||||
"custom/wgstatus",
|
||||
"hyprland/language",
|
||||
"pulseaudio",
|
||||
"clock",
|
||||
"custom/notify",
|
||||
"custom/off"
|
||||
],
|
||||
"custom/launch": {
|
||||
"format": " ",
|
||||
"on-click": "sleep 0.1 && menurun",
|
||||
"tooltip": false,
|
||||
"escape": true
|
||||
},
|
||||
|
||||
"custom/tempcpu": {
|
||||
"interval": 3,
|
||||
"exec": "~/.config/waybar/scripts/lstempcpu",
|
||||
"format": " {}°C",
|
||||
"tooltip": true,
|
||||
"return-type": "json"
|
||||
},
|
||||
|
||||
"custom/tempgpu": {
|
||||
"interval": 3,
|
||||
"exec": "~/.config/waybar/scripts/lstempgpu",
|
||||
"format": "<span size='large'></span> {}°C",
|
||||
"tooltip": false,
|
||||
"return-type": "json"
|
||||
},
|
||||
|
||||
"wlr/workspaces": {
|
||||
"disable-scroll": true,
|
||||
"format": " {icon} ",
|
||||
"on-click": "activate",
|
||||
"all-outputs": false,
|
||||
"sort-by-number": true,
|
||||
"persistent_workspaces": {
|
||||
"1": [],
|
||||
"2": [],
|
||||
"3": [],
|
||||
"4": [],
|
||||
"5": [],
|
||||
"6": [],
|
||||
"7": [],
|
||||
"8": []
|
||||
},
|
||||
"format-icons": {
|
||||
"1": " ",
|
||||
"2": " ",
|
||||
"3": " ",
|
||||
"4": " ",
|
||||
"5": " ",
|
||||
"6": " ",
|
||||
"7": " ",
|
||||
"8": " ",
|
||||
"urgent": " ",
|
||||
"focused": " ",
|
||||
"default": " "
|
||||
}
|
||||
},
|
||||
|
||||
"tray": {
|
||||
"icon-size": 16,
|
||||
"spacing": 10,
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/wgstatus": {
|
||||
"interval": 1,
|
||||
"exec": "~/.config/waybar/scripts/wgstatus",
|
||||
"format": " {} ",
|
||||
"tooltip": false,
|
||||
"on-click": "sleep 0.1 && ~/.config/waybar/scripts/wgstatus -toggle"
|
||||
},
|
||||
|
||||
"hyprland/language": {
|
||||
"format": " {} ",
|
||||
"format-en": "Eng",
|
||||
"format-ru": "Rus",
|
||||
"on-click": "sleep 0.1 && hyprctl switchxkblayout compx-2.4g-wireless-receiver next",
|
||||
},
|
||||
|
||||
"pulseaudio": {
|
||||
"scroll-step": 5,
|
||||
"format": "{icon} {volume}",
|
||||
"format-bluetooth": "{icon} {volume}",
|
||||
"format-bluetooth-muted": " ",
|
||||
"format-muted": " ",
|
||||
"format-icons": {
|
||||
"default": ["", "", " "]
|
||||
},
|
||||
"on-click": "sleep 0.1 && pavucontrol &",
|
||||
"on-click-middle": "sleep 0.1 && loopback_toggle",
|
||||
"on-scroll-up": "swayosd --output-volume raise",
|
||||
"on-scroll-down": "swayosd --output-volume lower",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"cpu": {
|
||||
"format": "<span font_family='Material Icons' size='large'></span> {usage}%",
|
||||
"tooltip": true,
|
||||
"tooltip-format": "{tooltip}"
|
||||
},
|
||||
|
||||
"memory": {
|
||||
"interval": 3,
|
||||
"format": "<span font_family='Material Icons' size='large'></span> {}%",
|
||||
"max-length": 6,
|
||||
"tooltip": true,
|
||||
"tooltip-format": "{tooltip}"
|
||||
},
|
||||
|
||||
"clock": {
|
||||
"interval": 1,
|
||||
"format": "<span font_family='Material Icons' size='large'></span> {:%I:%M %p}",
|
||||
"format-alt": " {:%b %d, %G}",
|
||||
"tooltip-format": "<tt><small>{calendar}</small></tt>",
|
||||
"calendar": {
|
||||
"mode" : "month",
|
||||
"mode-mon-col" : 3,
|
||||
"format": {
|
||||
"months": "<span color='#e5c07b'><b>{}</b></span>",
|
||||
"days": "<span color='#e5c07b'><b>{}</b></span>",
|
||||
"weekdays": "<span color='#56b6c2'><b>{}</b></span>",
|
||||
"today": "<span color='#e06c75'><b><u>{}</u></b></span>"
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
"custom/off": {
|
||||
"format": " ",
|
||||
"on-click": "sleep 0.1 && menupower",
|
||||
"tooltip": false,
|
||||
"escape": true
|
||||
}
|
||||
|
||||
}
|
||||
13
rockethype/config/waybar/scripts/lstempcpu
Executable file
13
rockethype/config/waybar/scripts/lstempcpu
Executable file
@ -0,0 +1,13 @@
|
||||
#!/bin/bash
|
||||
|
||||
CPUTEMP=$(cat /sys/class/hwmon/hwmon3/temp1_input)
|
||||
CRITEMP=70
|
||||
let "REZ=$CPUTEMP / 1000"
|
||||
if [ $REZ -ge $CRITEMP ]; then
|
||||
JSON_FMT='{"text":"%s","class":"%s","tooltip": "cpu"}\n'
|
||||
printf "$JSON_FMT" "$REZ" "crit"
|
||||
else
|
||||
JSON_FMT='{"text":"%s","tooltip": "cpu"}\n'
|
||||
printf "$JSON_FMT" "$REZ"
|
||||
fi
|
||||
|
||||
13
rockethype/config/waybar/scripts/lstempgpu
Executable file
13
rockethype/config/waybar/scripts/lstempgpu
Executable file
@ -0,0 +1,13 @@
|
||||
#!/bin/bash
|
||||
|
||||
GPUTEMP=$(cat /sys/class/hwmon/hwmon2/temp2_input)
|
||||
CRITEMP=80
|
||||
let "REZ=$GPUTEMP / 1000"
|
||||
if [ $REZ -ge $CRITEMP ]; then
|
||||
JSON_FMT='{"text":"%s","class":"%s","tooltip":"gpu"}\n'
|
||||
printf "$JSON_FMT" "$REZ" "crit"
|
||||
else
|
||||
JSON_FMT='{"text":"%s","tooltip":"gpu"}\n'
|
||||
printf "$JSON_FMT" "$REZ"
|
||||
fi
|
||||
|
||||
25
rockethype/config/waybar/scripts/wgstatus
Executable file
25
rockethype/config/waybar/scripts/wgstatus
Executable file
@ -0,0 +1,25 @@
|
||||
#!/bin/bash
|
||||
|
||||
WGIFACE=kz.totmin.ru
|
||||
|
||||
WGON(){
|
||||
echo "VPN"
|
||||
WGS='true'
|
||||
}
|
||||
|
||||
WGOFF(){
|
||||
# echo "Off"
|
||||
WGS='false'
|
||||
}
|
||||
|
||||
ifconfig $WGIFACE &>/dev/null && WGON ||WGOFF
|
||||
|
||||
if [ "$1" = '-toggle' ]; then
|
||||
if [ "$WGS" = 'true' ]; then
|
||||
sudo wg-quick down $WGIFACE &>/dev/null
|
||||
else
|
||||
sudo wg-quick up $WGIFACE &>/dev/null
|
||||
fi
|
||||
fi
|
||||
|
||||
exit 0
|
||||
228
rockethype/config/waybar/style.css
Executable file
228
rockethype/config/waybar/style.css
Executable file
@ -0,0 +1,228 @@
|
||||
/*
|
||||
|
||||
Color Pallete
|
||||
|
||||
foreground: '#abb2bf'
|
||||
background: '#303030'
|
||||
alt-background: '#282c34'
|
||||
alt-foreground: '#1f2227'
|
||||
|
||||
black: '#282c34'
|
||||
red: '#e06c75'
|
||||
green: '#98c379'
|
||||
yellow: '#e5c07b'
|
||||
blue: '#81A1C1'
|
||||
magenta: '#c678dd'
|
||||
cyan: '#56b6c2'
|
||||
white: '#c8ccd4'
|
||||
|
||||
*/
|
||||
|
||||
* {
|
||||
border: 0px solid rgba(40, 44, 52, 0);
|
||||
border-radius: 6px;
|
||||
font-family: Iosevka Nerd Font, Font Awesome,Material Icons, Arial, sans-serif;
|
||||
font-weight: 700;
|
||||
font-size: 13px;
|
||||
min-height: 18px;
|
||||
padding: 1px;
|
||||
}
|
||||
|
||||
tooltip {
|
||||
background: #303030;
|
||||
font-family: Iosevka Nerd Font;
|
||||
border: 1px solid rgba(100, 114, 125, 0.5);
|
||||
}
|
||||
|
||||
tooltip label {
|
||||
color: #c8ccd4;
|
||||
}
|
||||
|
||||
window#waybar {
|
||||
background-color: #303030;
|
||||
background: transparent;
|
||||
color: #303030;
|
||||
transition-property: background-color;
|
||||
transition-duration: 0.5s;
|
||||
border-radius: 6px;
|
||||
|
||||
}
|
||||
|
||||
window > box {
|
||||
margin-left: 12.5px;
|
||||
margin-right: 12.5px;
|
||||
margin-top: 12.5px;
|
||||
background: #303030;
|
||||
color: #c8ccd4;
|
||||
}
|
||||
|
||||
window#waybar.hidden {
|
||||
opacity: 0.2;
|
||||
}
|
||||
|
||||
label:focus {
|
||||
background-color: #282c34;
|
||||
}
|
||||
|
||||
@keyframes blink {
|
||||
to {
|
||||
background-color: #c8ccd4;
|
||||
color: #282c34;
|
||||
}
|
||||
}
|
||||
|
||||
#battery,
|
||||
#cpu,
|
||||
#memory,
|
||||
#disk,
|
||||
#backlight,
|
||||
#network,
|
||||
#pulseaudio,
|
||||
#workspaces,
|
||||
#clock,
|
||||
#tray,
|
||||
#mode,
|
||||
#idle_inhibitor,
|
||||
#mpd {
|
||||
padding: 0 10px;
|
||||
margin: 4px 4px 4px 4px;
|
||||
color: #1f2227;
|
||||
}
|
||||
|
||||
#custom-launch {
|
||||
margin-right: 10px;
|
||||
margin-left: 4px;
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
margin-top: 4px;
|
||||
margin-bottom: 4px;
|
||||
font-size: 17px;
|
||||
background-color: #81a1c1;
|
||||
color: #1f2227;
|
||||
}
|
||||
|
||||
#custom-tempcpu {
|
||||
color: #81A1C1;
|
||||
margin-left: 8px;
|
||||
}
|
||||
|
||||
#custom-tempcpu.crit {
|
||||
color: #e06c75;
|
||||
margin-left: 8px;
|
||||
}
|
||||
|
||||
#custom-tempgpu {
|
||||
color: #81A1C1;
|
||||
margin-left: 18px;
|
||||
}
|
||||
|
||||
#custom-tempgpu.crit {
|
||||
color: #e06c75;
|
||||
margin-left: 18px;
|
||||
}
|
||||
|
||||
#workspaces button {
|
||||
padding: 5px 5px;
|
||||
background-color: transparent;
|
||||
border-radius: 6px;
|
||||
margin-left: 1px;
|
||||
color: #abb2bf;
|
||||
}
|
||||
|
||||
#workspaces button:hover {
|
||||
background-color: transparent;
|
||||
color: #c678dd;
|
||||
}
|
||||
|
||||
#workspaces button.active {
|
||||
background-color: transparent;
|
||||
color: #e06c75;
|
||||
}
|
||||
|
||||
#workspaces button.urgent {
|
||||
background-color: transparent;
|
||||
color: #e06c75;
|
||||
}
|
||||
|
||||
#custom-spotify {
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
margin-top: 4px;
|
||||
margin-bottom: 4px;
|
||||
font-size: 17px;
|
||||
font-weight: 500;
|
||||
background-color: #98c379;
|
||||
color: #1f2227;
|
||||
}
|
||||
|
||||
#custom-wgstatus {
|
||||
color: #e06c75;
|
||||
margin-right: 18px;
|
||||
}
|
||||
|
||||
#language {
|
||||
color: #c678dd;
|
||||
}
|
||||
|
||||
#pulseaudio {
|
||||
color: #e5c07b;
|
||||
}
|
||||
|
||||
#pulseaudio.muted {
|
||||
background-color: #81a1c1;
|
||||
color: #282c34;
|
||||
}
|
||||
|
||||
#backlight {
|
||||
color: #e5c07b;
|
||||
}
|
||||
|
||||
#network {
|
||||
color: #81a1c1;
|
||||
}
|
||||
|
||||
#memory {
|
||||
color: #81A1C1;
|
||||
}
|
||||
|
||||
#cpu {
|
||||
color: #81A1C1;
|
||||
}
|
||||
|
||||
#battery {
|
||||
color: #e5c07b;
|
||||
}
|
||||
|
||||
#battery.charging,
|
||||
#battery.plugged {
|
||||
color: #e06c75;
|
||||
}
|
||||
|
||||
#battery.critical:not(.charging) {
|
||||
color: #e06c75;
|
||||
animation-name: blink;
|
||||
animation-duration: 0.5s;
|
||||
animation-timing-function: linear;
|
||||
animation-iteration-count: infinite;
|
||||
animation-direction: alternate;
|
||||
}
|
||||
|
||||
#clock {
|
||||
color: #98c379;
|
||||
}
|
||||
|
||||
#custom-notify {
|
||||
color: #56b6c2;
|
||||
}
|
||||
|
||||
#custom-off {
|
||||
margin-right: 4px;
|
||||
margin-left: 11px;
|
||||
padding-left: 10px;
|
||||
padding-right: 8px;
|
||||
margin-top: 4px;
|
||||
margin-bottom: 4px;
|
||||
font-size: 17px;
|
||||
background-color: #e06c75;
|
||||
color: #272727;
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user