format: format files with biome

This commit is contained in:
2025-01-26 20:37:57 +01:00
parent 37a7c68536
commit 0141b1f096
3 changed files with 250 additions and 245 deletions

View File

@@ -1,177 +1,177 @@
{ {
"layer": "bottom", // Waybar at top layer "layer": "bottom", // Waybar at top layer
"position": "bottom", // Waybar position (top|bottom|left|right) "position": "bottom", // Waybar position (top|bottom|left|right)
// "height": 30, // Waybar height (to be removed for auto height) // "height": 30, // Waybar height (to be removed for auto height)
"margin": "5 5 5 5", "margin": "5 5 5 5",
// "width": 1280, // Waybar width // "width": 1280, // Waybar width
// Choose the order of the modules // Choose the order of the modules
"modules-left": ["sway/workspaces", "sway/mode"], "modules-left": ["sway/workspaces", "sway/mode"],
"modules-center": ["clock", "idle_inhibitor"], "modules-center": ["clock", "idle_inhibitor"],
"modules-right": [ "modules-right": [
"custom/pacman", "custom/pacman",
"custom/recorder", "custom/recorder",
"privacy", "privacy",
"pulseaudio", "pulseaudio",
"backlight", "backlight",
"battery", "battery",
"bluetooth", "bluetooth",
"network" "network"
], ],
//*************************** //***************************
//* Modules configuration * //* Modules configuration *
//*************************** //***************************
"sway/workspaces": { "sway/workspaces": {
"disable-scroll": true, "disable-scroll": true,
"format": "{name}" "format": "{name}"
}, },
"custom/recorder": { "custom/recorder": {
"format": "", "format": "",
"return-type": "json", "return-type": "json",
"interval": 1, "interval": 1,
"exec": "echo '{\"class\": \"recording\"}'", "exec": "echo '{\"class\": \"recording\"}'",
"exec-if": "pgrep wf-recorder" "exec-if": "pgrep wf-recorder"
}, },
"custom/pacman": { "custom/pacman": {
"format": "{} ", "format": "{} ",
"interval": 3600, // every hour "interval": 3600, // every hour
"exec": "checkupdates | wc -l", // # of updates "exec": "checkupdates | wc -l", // # of updates
"exec-if": "[[ $(checkupdates | wc -l) != 0 ]]", // always run; consider advanced run conditions "exec-if": "[[ $(checkupdates | wc -l) != 0 ]]", // always run; consider advanced run conditions
"on-click": "alacritty -e 'yay; echo Done - Press enter to exit; read'; pkill -SIGRTMIN+8 waybar", // update system "on-click": "alacritty -e 'yay; echo Done - Press enter to exit; read'; pkill -SIGRTMIN+8 waybar", // update system
"signal": 8, "signal": 8,
"tooltip": false "tooltip": false
}, },
"privacy": { "privacy": {
"icon-spacing": 4, "icon-spacing": 4,
"icon-size": 18, "icon-size": 18,
"transition-duration": 250, "transition-duration": 250,
"modules": [ "modules": [
{ {
"type": "screenshare", "type": "screenshare",
"tooltip": true, "tooltip": true,
"tooltip-icon-size": 24 "tooltip-icon-size": 24
}, },
{ {
"type": "audio-out", "type": "audio-out",
"tooltip": true, "tooltip": true,
"tooltip-icon-size": 24 "tooltip-icon-size": 24
}, },
{ {
"type": "audio-in", "type": "audio-in",
"tooltip": true, "tooltip": true,
"tooltip-icon-size": 24 "tooltip-icon-size": 24
} }
] ]
}, },
"sway/mode": { "sway/mode": {
"format": "<span style=\"italic\">{}</span>" "format": "<span style=\"italic\">{}</span>"
}, },
"clock": { "clock": {
"timezone": "Europe/Rome", "timezone": "Europe/Rome",
"format": "{:%H:%M}", "format": "{:%H:%M}",
"format-alt": "{:%Y-%m-%d}", "format-alt": "{:%Y-%m-%d}",
"tooltip-format": "<tt><small>{calendar}</small></tt>", "tooltip-format": "<tt><small>{calendar}</small></tt>",
"calendar": { "calendar": {
"mode": "year", "mode": "year",
"mode-mon-col": 3, "mode-mon-col": 3,
"weeks-pos": "right", "weeks-pos": "right",
"on-scroll": 1, "on-scroll": 1,
"on-click-right": "mode", "on-click-right": "mode",
"format": { "format": {
"months": "<span color='#ffead3'><b>{}</b></span>", "months": "<span color='#ffead3'><b>{}</b></span>",
"days": "<span color='#ecc6d9'><b>{}</b></span>", "days": "<span color='#ecc6d9'><b>{}</b></span>",
"weeks": "<span color='#99ffdd'><b>W{}</b></span>", "weeks": "<span color='#99ffdd'><b>W{}</b></span>",
"weekdays": "<span color='#ffcc66'><b>{}</b></span>", "weekdays": "<span color='#ffcc66'><b>{}</b></span>",
"today": "<span color='#ff6699'><b><u>{}</u></b></span>" "today": "<span color='#ff6699'><b><u>{}</u></b></span>"
} }
}, },
"actions": { "actions": {
"on-click-right": "mode", "on-click-right": "mode",
"on-click-forward": "tz_up", "on-click-forward": "tz_up",
"on-click-backward": "tz_down", "on-click-backward": "tz_down",
"on-scroll-up": "shift_up", "on-scroll-up": "shift_up",
"on-scroll-down": "shift_down" "on-scroll-down": "shift_down"
} }
}, },
"idle_inhibitor": { "idle_inhibitor": {
"format": "{icon}", "format": "{icon}",
"format-icons": { "format-icons": {
"activated": "", "activated": "",
"deactivated": "" "deactivated": ""
} }
}, },
"pulseaudio": { "pulseaudio": {
// "scroll-step": 1, // %, can be a float // "scroll-step": 1, // %, can be a float
"reverse-scrolling": 1, "reverse-scrolling": 1,
"format": "{volume}% {icon} {format_source}", "format": "{volume}% {icon} {format_source}",
"format-bluetooth": "{icon} {volume}% {format_source}", "format-bluetooth": "{icon} {volume}% {format_source}",
"format-bluetooth-muted": " {icon} {format_source}", "format-bluetooth-muted": " {icon} {format_source}",
"format-muted": "婢 {format_source}", "format-muted": "婢 {format_source}",
"format-source": "{volume}% ", "format-source": "{volume}% ",
"format-source-muted": "", "format-source-muted": "",
"format-icons": { "format-icons": {
"headphone": "", "headphone": "",
"hands-free": "", "hands-free": "",
"headset": "", "headset": "",
"phone": "", "phone": "",
"portable": "", "portable": "",
"car": "", "car": "",
"default": ["奄", "奔", "墳"] "default": ["奄", "奔", "墳"]
}, },
"on-click": "pavucontrol", "on-click": "pavucontrol",
"min-length": 13 "min-length": 13
}, },
"backlight": { "backlight": {
"device": "intel_backlight", "device": "intel_backlight",
"format": "{percent}% {icon}", "format": "{percent}% {icon}",
"format-icons": ["", "", "", "", "", "", ""], "format-icons": ["", "", "", "", "", "", ""],
"min-length": 7 "min-length": 7
}, },
"battery": { "battery": {
"states": { "states": {
"warning": 30, "warning": 30,
"critical": 15 "critical": 15
}, },
"format": "{capacity}% {icon}", "format": "{capacity}% {icon}",
"format-charging": "{capacity}% ", "format-charging": "{capacity}% ",
"format-plugged": "{capacity}% ", "format-plugged": "{capacity}% ",
"format-alt": "{time} {icon}", "format-alt": "{time} {icon}",
"format-icons": ["", "", "", "", "", "", "", "", "", ""], "format-icons": ["", "", "", "", "", "", "", "", "", ""],
"on-update": "$HOME/.config/waybar/scripts/check_battery.sh" "on-update": "$HOME/.config/waybar/scripts/check_battery.sh"
}, },
"bluetooth": { "bluetooth": {
"format": " {status}", "format": " {status}",
"format-connected": " {device_alias}", "format-connected": " {device_alias}",
"format-connected-battery": " {device_alias} {device_battery_percentage}%", "format-connected-battery": " {device_alias} {device_battery_percentage}%",
// "format-device-preference": [ "device1", "device2" ], // preference list deciding the displayed device // "format-device-preference": [ "device1", "device2" ], // preference list deciding the displayed device
"tooltip-format": "{controller_alias}\t{controller_address}\n\n{num_connections} connected", "tooltip-format": "{controller_alias}\t{controller_address}\n\n{num_connections} connected",
"tooltip-format-connected": "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}", "tooltip-format-connected": "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}",
"tooltip-format-enumerate-connected": "{device_alias}\t{device_address}", "tooltip-format-enumerate-connected": "{device_alias}\t{device_address}",
"tooltip-format-enumerate-connected-battery": "{device_alias}\t{device_address}\t{device_battery_percentage}%", "tooltip-format-enumerate-connected-battery": "{device_alias}\t{device_address}\t{device_battery_percentage}%",
"on-click": "blueman-manager" "on-click": "blueman-manager"
}, },
"network": { "network": {
"format": "{ifname}", "format": "{ifname}",
"format-wifi": "{essid} ", "format-wifi": "{essid} ",
"format-ethernet": "{ipaddr}/{cidr} 󰊗", "format-ethernet": "{ipaddr}/{cidr} 󰊗",
// "format-disconnected": "", //An empty format will hide the module. // "format-disconnected": "", //An empty format will hide the module.
"tooltip-format": "{ifname} via {gwaddr} 󰊗", "tooltip-format": "{ifname} via {gwaddr} 󰊗",
"tooltip-format-wifi": "{essid} ", "tooltip-format-wifi": "{essid} ",
"tooltip-format-ethernet": "{ifname} ", "tooltip-format-ethernet": "{ifname} ",
"tooltip-format-disconnected": "Disconnected", "tooltip-format-disconnected": "Disconnected",
"max-length": 50, "max-length": 50,
"on-click": "alacritty -e 'nmtui'" "on-click": "alacritty -e 'nmtui'"
} }
} }

View File

@@ -1,46 +1,46 @@
* { * {
border: none; border: none;
border-radius: 0; border-radius: 0;
/* `otf-font-awesome` is required to be installed for icons */ /* `otf-font-awesome` is required to be installed for icons */
font-family: Liberation Mono; font-family: Liberation Mono;
min-height: 20px; min-height: 20px;
} }
window#waybar { window#waybar {
background: transparent; background: transparent;
} }
window#waybar.hidden { window#waybar.hidden {
opacity: 0.2; opacity: 0.2;
} }
#workspaces { #workspaces {
border-radius: 10px; border-radius: 10px;
transition: none; transition: none;
background: #383c4a; background: #383c4a;
margin-right: 8px; margin-right: 8px;
} }
#workspaces button { #workspaces button {
transition: none; transition: none;
color: #7c818c; color: #7c818c;
background: transparent; background: transparent;
padding: 5px; padding: 5px;
font-size: 18px; font-size: 18px;
} }
/* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */ /* https://github.com/Alexays/Waybar/wiki/FAQ#the-workspace-buttons-have-a-strange-hover-effect */
#workspaces button:hover { #workspaces button:hover {
transition: none; transition: none;
box-shadow: inherit; box-shadow: inherit;
text-shadow: inherit; text-shadow: inherit;
border-radius: inherit; border-radius: inherit;
color: #383c4a; color: #383c4a;
background: #7c818c; background: #7c818c;
} }
#workspaces button.focused { #workspaces button.focused {
color: white; color: white;
} }
#custom-pacman, #custom-pacman,
@@ -52,110 +52,114 @@ window#waybar.hidden {
#bluetooth, #bluetooth,
#network, #network,
#backlight { #backlight {
padding-left: 8px; padding-left: 8px;
padding-right: 8px; padding-right: 8px;
border-radius: 10px; border-radius: 10px;
background: #383c4a; background: #383c4a;
} }
#custom-pacman { #custom-pacman {
transition: none; transition: none;
color: #ffffff; color: #ffffff;
} }
#bluetooth { #bluetooth {
margin-right: 8px; margin-right: 8px;
} }
#bluetooth.connected, #bluetooth.on { #bluetooth.connected,
background-color: #26a65b; #bluetooth.on {
background-color: #26a65b;
} }
#bluetooth.disabled, #bluetooth.off { #bluetooth.disabled,
background-color: #f53c3c; #bluetooth.off {
background-color: #f53c3c;
} }
#mode { #mode {
transition: none; transition: none;
color: #ffffff; color: #ffffff;
} }
#clock { #clock {
transition: none; transition: none;
color: #ffffff; color: #ffffff;
margin-right: 8px; margin-right: 8px;
} }
#idle_inhibitor { #idle_inhibitor {
transition: none; transition: none;
color: #ffffff; color: #ffffff;
} }
#idle_inhibitor.activated { #idle_inhibitor.activated {
background-color: #26a65b; background-color: #26a65b;
} }
#pulseaudio { #pulseaudio {
margin-right: 8px; margin-right: 8px;
transition: none; transition: none;
color: #ffffff; color: #ffffff;
} }
#pulseaudio.muted, #pulseaudio.muted,
#pulseaudio.source-muted { #pulseaudio.source-muted {
background-color: #90b1b1; background-color: #90b1b1;
color: #2a5c45; color: #2a5c45;
} }
#backlight { #backlight {
margin-right: 8px; margin-right: 8px;
transition: none; transition: none;
color: #ffffff; color: #ffffff;
} }
#battery { #battery {
margin-right: 8px; margin-right: 8px;
transition: none; transition: none;
color: #ffffff; color: #ffffff;
} }
#battery.charging { #battery.charging {
color: #ffffff; color: #ffffff;
background-color: #26a65b; background-color: #26a65b;
} }
#battery.warning:not(.charging) { #battery.warning:not(.charging) {
background-color: #ffbe61; background-color: #ffbe61;
color: black; color: black;
} }
#battery.critical:not(.charging) { #battery.critical:not(.charging) {
background-color: #f53c3c; background-color: #f53c3c;
color: #ffffff; color: #ffffff;
animation-name: blink; animation-name: blink;
animation-duration: 0.5s; animation-duration: 0.5s;
animation-timing-function: linear; animation-timing-function: linear;
animation-iteration-count: infinite; animation-iteration-count: infinite;
animation-direction: alternate; animation-direction: alternate;
} }
#network { #network {
transition: none; transition: none;
color: #ffffff; color: #ffffff;
background: #383c4a; background: #383c4a;
} }
#network.wifi, #network.ethener { #network.wifi,
background-color: #26a65b; #network.ethener {
background-color: #26a65b;
} }
#network.disabled, #network.disconnected { #network.disabled,
background-color: #f53c3c; #network.disconnected {
background-color: #f53c3c;
} }
@keyframes blink { @keyframes blink {
to { to {
background-color: #ffffff; background-color: #ffffff;
color: #000000; color: #000000;
} }
} }

View File

@@ -1,17 +1,18 @@
#window { #window {
border-radius: 10px; border-radius: 10px;
background: #383c4a; background: #383c4a;
} }
#outer-box { #outer-box {
padding: 5px; padding: 5px;
} }
#input, #entry { #input,
border-radius: 10px; #entry {
margin-bottom: 5px; border-radius: 10px;
margin-bottom: 5px;
} }
#img { #img {
padding-right: 10px; padding-right: 10px;
} }