Compare commits
4
Commits
v1.0
...
788342c846
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
788342c846 | ||
|
|
8d02c166a1 | ||
|
|
8a459996ea | ||
|
|
baf2021aa9 |
No files matched your search
@@ -70,6 +70,8 @@ _(Note: The shell is configured to automatically restore your last used wallpape
|
|||||||
|
|
||||||
Because this shell uses **Pywal**, you can easily inject the dynamically generated colors into almost any other application on your system.
|
Because this shell uses **Pywal**, you can easily inject the dynamically generated colors into almost any other application on your system.
|
||||||
|
|
||||||
|
Pywal applies the colors to config files located in `~/.config/wal/templates`. Examples can be found in this repos templates folder.
|
||||||
|
|
||||||
Whenever you change the wallpaper via the AGS bar, Pywal updates the color templates inside `~/.cache/wal/`. Here is how to apply them to other apps:
|
Whenever you change the wallpaper via the AGS bar, Pywal updates the color templates inside `~/.cache/wal/`. Here is how to apply them to other apps:
|
||||||
|
|
||||||
### Manual Updates:
|
### Manual Updates:
|
||||||
|
|||||||
+16
-2
@@ -1,7 +1,7 @@
|
|||||||
@use "/tmp/ags-colors.scss" as wal;
|
@use "/tmp/ags-colors.scss" as wal;
|
||||||
|
|
||||||
$fg-color: wal.$foreground;
|
$fg-color: wal.$foreground;
|
||||||
$bg-color: rgba(wal.$background, 0.8);
|
$bg-color: rgba(wal.$background, 1.0);
|
||||||
|
|
||||||
$btn-height: 30px;
|
$btn-height: 30px;
|
||||||
$btn-radius: 8px;
|
$btn-radius: 8px;
|
||||||
@@ -14,7 +14,7 @@ window.Bar {
|
|||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
|
|
||||||
> centerbox {
|
> centerbox {
|
||||||
background: $bg-color;
|
background: rgba(wal.$background, 1.0);
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
margin: 4px 8px;
|
margin: 4px 8px;
|
||||||
padding: 0 8px;
|
padding: 0 8px;
|
||||||
@@ -201,6 +201,20 @@ window.PowerMenu {
|
|||||||
background: rgba(wal.$foreground, 0.1);
|
background: rgba(wal.$foreground, 0.1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.qs-device-name {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.qs-device-status {
|
||||||
|
font-size: 0.9em;
|
||||||
|
opacity: 0.7;
|
||||||
|
}
|
||||||
|
|
||||||
|
.qs-battery {
|
||||||
|
font-size: 0.9em;
|
||||||
|
opacity: 0.7;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
slider {
|
slider {
|
||||||
|
|||||||
@@ -0,0 +1,21 @@
|
|||||||
|
var_wallpaper = "{wallpaper}"
|
||||||
|
|
||||||
|
var_foreground = "rgba({foreground.rgb},1.0)"
|
||||||
|
var_background = "rgba({background.rgb},1.0)"
|
||||||
|
|
||||||
|
var_color0 = "rgba({color0.rgb},1.0)"
|
||||||
|
var_color1 = "rgba({color1.rgb},1.0)"
|
||||||
|
var_color2 = "rgba({color2.rgb},1.0)"
|
||||||
|
var_color3 = "rgba({color3.rgb},1.0)"
|
||||||
|
var_color4 = "rgba({color4.rgb},1.0)"
|
||||||
|
var_color5 = "rgba({color5.rgb},1.0)"
|
||||||
|
var_color6 = "rgba({color6.rgb},1.0)"
|
||||||
|
var_color7 = "rgba({color7.rgb},1.0)"
|
||||||
|
var_color8 = "rgba({color8.rgb},1.0)"
|
||||||
|
var_color9 = "rgba({color9.rgb},1.0)"
|
||||||
|
var_color10 = "rgba({color10.rgb},1.0)"
|
||||||
|
var_color11 = "rgba({color11.rgb},1.0)"
|
||||||
|
var_color12 = "rgba({color12.rgb},1.0)"
|
||||||
|
var_color13 = "rgba({color13.rgb},1.0)"
|
||||||
|
var_color14 = "rgba({color14.rgb},1.0)"
|
||||||
|
var_color15 = "rgba({color15.rgb},1.0)"
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
* {
|
||||||
|
/* Base Colors */
|
||||||
|
background: #{background.strip}D9; /* D9 = ~85% opacity. Use 99 for 60% or CC for 80% */
|
||||||
|
background-solid: {background};
|
||||||
|
foreground: {foreground};
|
||||||
|
|
||||||
|
/* Accent Colors */
|
||||||
|
color0: {color0};
|
||||||
|
color1: {color1};
|
||||||
|
color2: {color2};
|
||||||
|
color3: {color3};
|
||||||
|
color4: {color4};
|
||||||
|
color5: {color5};
|
||||||
|
color6: {color6};
|
||||||
|
color7: {color7};
|
||||||
|
color8: {color8};
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
[global]
|
||||||
|
# Define the corner radius in pixels.
|
||||||
|
# A value of 0 disables rounded corners.
|
||||||
|
corner_radius = 10
|
||||||
|
|
||||||
|
[urgency_low]
|
||||||
|
background = "{background}CC"
|
||||||
|
foreground = "{foreground}"
|
||||||
|
frame_color = "{color2}"
|
||||||
|
timeout = 10
|
||||||
|
|
||||||
|
[urgency_normal]
|
||||||
|
background = "{background}CC"
|
||||||
|
foreground = "{foreground}"
|
||||||
|
frame_color = "{color1}"
|
||||||
|
timeout = 10
|
||||||
|
|
||||||
|
[urgency_critical]
|
||||||
|
background = "{background}CC"
|
||||||
|
foreground = "{foreground}"
|
||||||
|
frame_color = "{color9}"
|
||||||
|
timeout = 0
|
||||||
@@ -122,7 +122,7 @@ export async function setTheme(wallpaperPath: string) {
|
|||||||
try {
|
try {
|
||||||
// -q: quiet, -i: image, -n: skip setting wallpaper (hyprpaper does it)
|
// -q: quiet, -i: image, -n: skip setting wallpaper (hyprpaper does it)
|
||||||
await execAsync(
|
await execAsync(
|
||||||
`wal --backend modern-colorthief -q -n -i "${wallpaperPath}"`,
|
`wal --contrast 21.0 -q -n -i "${wallpaperPath}"`,
|
||||||
)
|
)
|
||||||
|
|
||||||
// Add this line so hyprlock always knows the current wallpaper:
|
// Add this line so hyprlock always knows the current wallpaper:
|
||||||
|
|||||||
@@ -3,3 +3,6 @@
|
|||||||
#Dunst notification daemon
|
#Dunst notification daemon
|
||||||
killall dunst
|
killall dunst
|
||||||
dunst &
|
dunst &
|
||||||
|
|
||||||
|
hyprctl reload
|
||||||
|
|
||||||
@@ -2,6 +2,7 @@ import { Gtk } from "ags/gtk4"
|
|||||||
import AstalNetwork from "gi://AstalNetwork?version=0.1"
|
import AstalNetwork from "gi://AstalNetwork?version=0.1"
|
||||||
import AstalBluetooth from "gi://AstalBluetooth?version=0.1"
|
import AstalBluetooth from "gi://AstalBluetooth?version=0.1"
|
||||||
import AstalWp from "gi://AstalWp?version=0.1"
|
import AstalWp from "gi://AstalWp?version=0.1"
|
||||||
|
import AstalPowerProfiles from "gi://AstalPowerProfiles?version=0.1"
|
||||||
import { createBinding, createComputed, createState, For } from "ags"
|
import { createBinding, createComputed, createState, For } from "ags"
|
||||||
import { interval } from "ags/time"
|
import { interval } from "ags/time"
|
||||||
import { exec, execAsync } from "ags/process"
|
import { exec, execAsync } from "ags/process"
|
||||||
@@ -41,6 +42,23 @@ interval(2000, () => setVpns(fetchVpns()))
|
|||||||
|
|
||||||
const vpnActive = vpns((list) => list.some((c) => c.active))
|
const vpnActive = vpns((list) => list.some((c) => c.active))
|
||||||
|
|
||||||
|
const POWER_PROFILE_ICONS: Record<string, string> = {
|
||||||
|
"power-saver": "power-profile-power-saver-symbolic",
|
||||||
|
balanced: "power-profile-balanced-symbolic",
|
||||||
|
performance: "power-profile-performance-symbolic",
|
||||||
|
}
|
||||||
|
|
||||||
|
const POWER_PROFILE_LABELS: Record<string, string> = {
|
||||||
|
"power-saver": "Power Saver",
|
||||||
|
balanced: "Balanced",
|
||||||
|
performance: "Performance",
|
||||||
|
}
|
||||||
|
|
||||||
|
const powerprofiles = AstalPowerProfiles.get_default()
|
||||||
|
const activeProfile = createBinding(powerprofiles, "active-profile")
|
||||||
|
const powerProfiles = powerprofiles.get_profiles().map((p) => p.profile)
|
||||||
|
const hasPowerProfiles = powerProfiles.length > 0
|
||||||
|
|
||||||
function NetworkItem() {
|
function NetworkItem() {
|
||||||
const network = AstalNetwork.Network.get_default()
|
const network = AstalNetwork.Network.get_default()
|
||||||
const primary = createBinding(network, "primary")
|
const primary = createBinding(network, "primary")
|
||||||
@@ -190,6 +208,58 @@ function VpnList() {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function PowerProfileItem() {
|
||||||
|
return (
|
||||||
|
<menubutton cssClasses={["qs-item"]} hexpand>
|
||||||
|
<box spacing={12} valign={Gtk.Align.CENTER}>
|
||||||
|
<image
|
||||||
|
iconName={activeProfile(
|
||||||
|
(p) => POWER_PROFILE_ICONS[p] ?? "power-profile-balanced-symbolic",
|
||||||
|
)}
|
||||||
|
cssClasses={["qs-icon"]}
|
||||||
|
/>
|
||||||
|
<label
|
||||||
|
label={activeProfile((p) => POWER_PROFILE_LABELS[p] ?? p)}
|
||||||
|
halign={Gtk.Align.START}
|
||||||
|
hexpand
|
||||||
|
/>
|
||||||
|
<image iconName="pan-down-symbolic" />
|
||||||
|
</box>
|
||||||
|
<popover>
|
||||||
|
<box orientation={Gtk.Orientation.VERTICAL} spacing={4}>
|
||||||
|
{powerProfiles.map((name) => (
|
||||||
|
<button
|
||||||
|
cssClasses={["qs-item"]}
|
||||||
|
onClicked={(btn) => {
|
||||||
|
powerprofiles.set_active_profile(name)
|
||||||
|
const popover = btn.get_ancestor(
|
||||||
|
Gtk.Popover.$gtype,
|
||||||
|
) as Gtk.Popover | null
|
||||||
|
popover?.popdown()
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<box spacing={12} valign={Gtk.Align.CENTER}>
|
||||||
|
<image
|
||||||
|
iconName={
|
||||||
|
POWER_PROFILE_ICONS[name] ??
|
||||||
|
"power-profile-balanced-symbolic"
|
||||||
|
}
|
||||||
|
cssClasses={["qs-icon"]}
|
||||||
|
/>
|
||||||
|
<label
|
||||||
|
label={POWER_PROFILE_LABELS[name] ?? name}
|
||||||
|
halign={Gtk.Align.START}
|
||||||
|
hexpand
|
||||||
|
/>
|
||||||
|
</box>
|
||||||
|
</button>
|
||||||
|
))}
|
||||||
|
</box>
|
||||||
|
</popover>
|
||||||
|
</menubutton>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
export default function QuickSettings() {
|
export default function QuickSettings() {
|
||||||
return (
|
return (
|
||||||
<menubutton
|
<menubutton
|
||||||
@@ -213,6 +283,18 @@ export default function QuickSettings() {
|
|||||||
<BluetoothItem />
|
<BluetoothItem />
|
||||||
</box>
|
</box>
|
||||||
<VpnList />
|
<VpnList />
|
||||||
|
<box
|
||||||
|
orientation={Gtk.Orientation.VERTICAL}
|
||||||
|
spacing={8}
|
||||||
|
visible={hasPowerProfiles}
|
||||||
|
>
|
||||||
|
<label
|
||||||
|
label="Power Profile"
|
||||||
|
cssClasses={["qs-title"]}
|
||||||
|
halign={Gtk.Align.START}
|
||||||
|
/>
|
||||||
|
<PowerProfileItem />
|
||||||
|
</box>
|
||||||
<box orientation={Gtk.Orientation.VERTICAL} spacing={8}>
|
<box orientation={Gtk.Orientation.VERTICAL} spacing={8}>
|
||||||
<button
|
<button
|
||||||
cssClasses={["qs-title"]}
|
cssClasses={["qs-title"]}
|
||||||
|
|||||||
Reference in new issue
Block a user