mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-05-19 14:17:26 +02:00
feat: redesign the project structure
This commit is contained in:
@@ -0,0 +1,222 @@
|
||||
{
|
||||
"name": "main-bar",
|
||||
"id": "main-bar",
|
||||
"layer": "top",
|
||||
"mode": "dock",
|
||||
"exclusive": true,
|
||||
"passthrough": false,
|
||||
"height": 32,
|
||||
"spacing": 6,
|
||||
"margin": 0,
|
||||
"margin-top": 0,
|
||||
"margin-bottom": 0,
|
||||
"margin-left": 0,
|
||||
"margin-right": 0,
|
||||
"fixed-center": true,
|
||||
"ipc": true,
|
||||
|
||||
"modules-left": [
|
||||
"custom/menu",
|
||||
"wlr/workspaces",
|
||||
"cpu",
|
||||
"memory",
|
||||
"disk"
|
||||
],
|
||||
"modules-center": [
|
||||
"mpd",
|
||||
"tray"
|
||||
],
|
||||
"modules-right": [
|
||||
"pulseaudio",
|
||||
"custom/weather",
|
||||
"network",
|
||||
"battery",
|
||||
"clock",
|
||||
"custom/power"
|
||||
],
|
||||
|
||||
// waybar-backlight
|
||||
"backlight": {
|
||||
"interval": 2,
|
||||
"align": 0,
|
||||
"rotate": 0,
|
||||
//"device": "amdgpu_bl0",
|
||||
"format": "{icon} {percent}%",
|
||||
"format-icons": [
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
""
|
||||
],
|
||||
// Commands to execute on events
|
||||
"on-click": "",
|
||||
"on-click-middle": "",
|
||||
"on-click-right": "",
|
||||
"on-update": "",
|
||||
"on-scroll-up": "light -A 5%",
|
||||
"on-scroll-down": "light -U 5%",
|
||||
"smooth-scrolling-threshold": 1,
|
||||
},
|
||||
"wlr/workspaces": {
|
||||
"format": "{icon}",
|
||||
"on-click": "activate",
|
||||
"all-outputs": true,
|
||||
"format-icons": {
|
||||
"1": "",
|
||||
"2": "",
|
||||
"3": "",
|
||||
"4": "",
|
||||
"5": "ﭮ",
|
||||
"6": "",
|
||||
"7": "",
|
||||
"8": "",
|
||||
"9": "",
|
||||
"10": "﮼",
|
||||
"focused": "",
|
||||
"default": ""
|
||||
}
|
||||
},
|
||||
// waybar-battery
|
||||
"battery": {
|
||||
"interval": 60,
|
||||
"align": 0,
|
||||
"rotate": 0,
|
||||
//"bat": "BAT1",
|
||||
//"adapter": "ACAD",
|
||||
"full-at": 100,
|
||||
"design-capacity": false,
|
||||
"states": {
|
||||
"good": 95,
|
||||
"warning": 30,
|
||||
"critical": 15
|
||||
},
|
||||
"format": "{icon} {capacity}%",
|
||||
"format-charging": " {capacity}%",
|
||||
"format-plugged": " {capacity}%",
|
||||
"format-full": "{icon} Full",
|
||||
//"format-good": "",
|
||||
"format-alt": "{icon} {time}",
|
||||
"format-icons": [
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
"",
|
||||
""
|
||||
],
|
||||
"format-time": "{H}h {M}min",
|
||||
"tooltip": true,
|
||||
},
|
||||
// waybar-clock
|
||||
"clock": {
|
||||
"interval": 60,
|
||||
"align": 0,
|
||||
"rotate": 0,
|
||||
"tooltip-format": "<big>{:%B %Y}</big>\n<tt><small>{calendar}</small></tt>",
|
||||
"format": " {:%H:%M}",
|
||||
"format-alt": " {:%a %b %d, %G}"
|
||||
},
|
||||
// waybar-cpu
|
||||
"cpu": {
|
||||
"interval": 5,
|
||||
"format": " LOAD: {usage}%",
|
||||
},
|
||||
// waybar-custom
|
||||
"custom/menu": {
|
||||
"format": "",
|
||||
"tooltip": false,
|
||||
"on-click": "$HOME/.config/hypr/scripts/menu",
|
||||
},
|
||||
"custom/power": {
|
||||
"format": " ",
|
||||
"tooltip": false,
|
||||
"on-click": "$HOME/.config/hypr/scripts/wlogout",
|
||||
},
|
||||
// waybar-disk
|
||||
"disk": {
|
||||
"interval": 30,
|
||||
"format": " FREE: {free}",
|
||||
},
|
||||
// waybar-memory
|
||||
"memory": {
|
||||
"interval": 10,
|
||||
"format": " USED: {used:0.1f}G",
|
||||
},
|
||||
// waybar-mpd
|
||||
"mpd": {
|
||||
"interval": 2,
|
||||
"unknown-tag": "N/A",
|
||||
"format": "{stateIcon} {artist} - {title}",
|
||||
"format-disconnected": " Disconnected",
|
||||
"format-paused": "{stateIcon} {artist} - {title}",
|
||||
"format-stopped": "Stopped ",
|
||||
"state-icons": {
|
||||
"paused": "",
|
||||
"playing": ""
|
||||
},
|
||||
"tooltip-format": "MPD (connected)",
|
||||
"tooltip-format-disconnected": "MPD (disconnected)",
|
||||
// Commands to execute on events
|
||||
"on-click": "mpc toggle",
|
||||
"on-click-middle": "mpc prev",
|
||||
"on-click-right": "mpc next",
|
||||
"on-update": "",
|
||||
"on-scroll-up": "mpc seek +00:00:01",
|
||||
"on-scroll-down": "mpc seek -00:00:01",
|
||||
"smooth-scrolling-threshold": 1,
|
||||
},
|
||||
// waybar-network
|
||||
"network": {
|
||||
"interval": 5,
|
||||
//"interface": "wlan*", // (Optional) To force the use of this interface, set it for netspeed to work
|
||||
"format-wifi": " {essid}",
|
||||
"format-ethernet": " {ipaddr}/{cidr}",
|
||||
"format-linked": " {ifname} (No IP)",
|
||||
"format-disconnected": "睊 Disconnected",
|
||||
"format-disabled": "睊 Disabled",
|
||||
"format-alt": " {bandwidthUpBits} | {bandwidthDownBits}",
|
||||
"tooltip-format": " {ifname} via {gwaddr}",
|
||||
},
|
||||
// weather-custom
|
||||
"custom/weather": {
|
||||
// "format": "{}",
|
||||
// "format-alt": "{alt}: {}",
|
||||
"format-alt-click": "click-right",
|
||||
"interval": 300,
|
||||
"return-type": "json",
|
||||
"exec": "~/.config/hypr/scripts/weather",
|
||||
// "on-click": "xdg-open https://weather.com/en-IN/weather/today/l/$(location_id)"
|
||||
},
|
||||
// waybar-pulseaudio
|
||||
"pulseaudio": {
|
||||
//"format": "{volume}% {icon} {format_source}",
|
||||
"format": "{icon} {volume}%",
|
||||
"format-muted": " Mute",
|
||||
"format-bluetooth": " {volume}% {format_source}",
|
||||
"format-bluetooth-muted": " Mute",
|
||||
"format-source": " {volume}%",
|
||||
"format-source-muted": "",
|
||||
"format-icons": {
|
||||
"headphone": "",
|
||||
"hands-free": "",
|
||||
"headset": "",
|
||||
"phone": "",
|
||||
"portable": "",
|
||||
"car": "",
|
||||
"default": [
|
||||
"",
|
||||
"",
|
||||
""
|
||||
]
|
||||
},
|
||||
"scroll-step": 5.0,
|
||||
// Commands to execute on events
|
||||
"on-click": "amixer set Master toggle",
|
||||
"on-click-right": "pavucontrol",
|
||||
"smooth-scrolling-threshold": 1,
|
||||
},
|
||||
// waybar-tray
|
||||
"tray": {
|
||||
"icon-size": 16,
|
||||
"spacing": 10
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,216 @@
|
||||
/** ********** Fonts ********** **/
|
||||
* {
|
||||
font-family: "JetBrains Mono", "Iosevka Nerd Font", archcraft, sans-serif;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
/** ********** Waybar Window ********** **/
|
||||
window#waybar {
|
||||
background-color: #1e1e2e;
|
||||
color: #1e1e2e;
|
||||
border-bottom: 2px solid #313244;
|
||||
transition-property: background-color;
|
||||
transition-duration: .5s;
|
||||
}
|
||||
|
||||
window#waybar.hidden {
|
||||
opacity: 0.5;
|
||||
}
|
||||
|
||||
/** ********** Backlight ********** **/
|
||||
#backlight {
|
||||
background-color: #cba6f7;
|
||||
}
|
||||
|
||||
/** ********** Battery ********** **/
|
||||
#battery {
|
||||
background-color: #f9e2af;
|
||||
}
|
||||
|
||||
#battery.charging {
|
||||
}
|
||||
|
||||
#battery.plugged {
|
||||
}
|
||||
|
||||
@keyframes blink {
|
||||
to {
|
||||
color: #000000;
|
||||
}
|
||||
}
|
||||
|
||||
#battery.critical:not(.charging) {
|
||||
background-color: #f38ba8;
|
||||
color: #f38ba8;
|
||||
animation-name: blink;
|
||||
animation-duration: 0.5s;
|
||||
animation-timing-function: linear;
|
||||
animation-iteration-count: infinite;
|
||||
animation-direction: alternate;
|
||||
}
|
||||
|
||||
/** ********** Clock ********** **/
|
||||
#clock {
|
||||
background-color: #a6e3a1;
|
||||
}
|
||||
|
||||
/** ********** CPU ********** **/
|
||||
#cpu {
|
||||
background-color: #89dceb;
|
||||
}
|
||||
|
||||
/** ********** Memory ********** **/
|
||||
#memory {
|
||||
background-color: #eba0ac;
|
||||
}
|
||||
|
||||
/** ********** Disk ********** **/
|
||||
#disk {
|
||||
background-color: #b4befe;
|
||||
}
|
||||
|
||||
/** ********** Tray ********** **/
|
||||
#tray {
|
||||
background-color: #cdd6f4;
|
||||
}
|
||||
#tray > .passive {
|
||||
-gtk-icon-effect: dim;
|
||||
}
|
||||
#tray > .needs-attention {
|
||||
-gtk-icon-effect: highlight;
|
||||
}
|
||||
#tray > .active {
|
||||
}
|
||||
|
||||
/** ********** MPD ********** **/
|
||||
#mpd {
|
||||
background-color: #94e2d5;
|
||||
}
|
||||
|
||||
#mpd.disconnected {
|
||||
background-color: #f38ba8;
|
||||
}
|
||||
|
||||
#mpd.stopped {
|
||||
background-color: #f5c2e7;
|
||||
}
|
||||
|
||||
#mpd.playing {
|
||||
background-color: #74c7ec;
|
||||
}
|
||||
|
||||
#mpd.paused {
|
||||
}
|
||||
|
||||
/** ********** Pulseaudio ********** **/
|
||||
#pulseaudio {
|
||||
background-color: #fab387;
|
||||
}
|
||||
|
||||
#pulseaudio.bluetooth {
|
||||
background-color: #f5c2e7;
|
||||
}
|
||||
#pulseaudio.muted {
|
||||
background-color: #313244;
|
||||
color: #cdd6f4;
|
||||
}
|
||||
|
||||
/** ********** Network ********** **/
|
||||
#network {
|
||||
background-color: #89b4fa;
|
||||
}
|
||||
|
||||
#network.disconnected,#network.disabled {
|
||||
background-color: #313244;
|
||||
color: #cdd6f4;
|
||||
}
|
||||
#network.linked {
|
||||
}
|
||||
#network.ethernet {
|
||||
}
|
||||
#network.wifi {
|
||||
}
|
||||
|
||||
/** ********** Custom ********** **/
|
||||
#custom-menu, #custom-power, #custom-weather, #custom-updater {
|
||||
border-radius: 4px;
|
||||
margin: 6px 0px;
|
||||
padding: 2px 8px;
|
||||
}
|
||||
|
||||
#custom-menu {
|
||||
background-color: #f5c2e7;
|
||||
margin-left: 6px;
|
||||
padding: 2px 6px;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
#custom-power {
|
||||
background-color: #f38ba8;
|
||||
margin-right: 6px;
|
||||
padding: 2px 8px;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
#custom-updater {
|
||||
background-color: #e6ed7b;
|
||||
margin-right: 6px;
|
||||
padding: 2px 8px;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
/** Common style **/
|
||||
#backlight,
|
||||
#battery,
|
||||
#clock,
|
||||
#cpu,
|
||||
#disk,
|
||||
#mode,
|
||||
#memory,
|
||||
#mpd,
|
||||
#tray,
|
||||
#pulseaudio,
|
||||
#network {
|
||||
border-radius: 4px;
|
||||
margin: 6px 0px;
|
||||
padding: 2px 8px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** ********** Weather ********** **/
|
||||
|
||||
#custom-weather {
|
||||
background-color: #5d388b;
|
||||
margin-right: 6px;
|
||||
padding: 2px 8px;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
#custom-weather.severe {
|
||||
color: #eb937d;
|
||||
}
|
||||
|
||||
#custom-weather.sunnyDay {
|
||||
color: #c2ca76;
|
||||
}
|
||||
|
||||
#custom-weather.clearNight {
|
||||
color: #2b2b2a;
|
||||
}
|
||||
|
||||
#custom-weather.cloudyFoggyDay, #custom-weather.cloudyFoggyNight {
|
||||
color: #c2ddda;
|
||||
}
|
||||
|
||||
#custom-weather.rainyDay, #custom-weather.rainyNight {
|
||||
color: #5aaca5;
|
||||
}
|
||||
|
||||
#custom-weather.showyIcyDay, #custom-weather.snowyIcyNight {
|
||||
color: #d6e7e5;
|
||||
}
|
||||
|
||||
#custom-weather.default {
|
||||
color: #dbd9d8;
|
||||
}
|
||||
Reference in New Issue
Block a user