[AGS] Bar progress

This commit is contained in:
2025-04-19 18:20:32 +02:00
parent 78e472beb8
commit b2f1d8fd9e
8 changed files with 249 additions and 107 deletions

View File

@@ -1,23 +1,36 @@
import { createQuickActionsMenu } from "./QuickActions";
import { GLib } from "astal";
import { Astal, Gdk, Gtk } from "astal/gtk3";
import Hyprland from "./modules/Hyprland";
import Calendar from "./modules/Calendar";
import QuickView from "./modules/QuickView";
const Bar = (gdkmonitor: Gdk.Monitor) => {
const { TOP, LEFT, RIGHT } = Astal.WindowAnchor;
return (
<window gdkmonitor={gdkmonitor}
cssClasses={["Bar"]}>
cssClasses={["Bar"]}
exclusivity={Astal.Exclusivity.EXCLUSIVE}
anchor={TOP | LEFT | RIGHT}>
<box orientation={Gtk.Orientation.HORIZONTAL} spacing={10}>
<box>
<box hexpand halign={Gtk.Align.START}>
<Calendar.Time />
<Hyprland.Workspace />
</box>
<label>{windowTitle}</label>
<box>
<tray />
<button icon="quickaction" menu={quickActionMenu} />
<Hyprland.ActiveWindow />
<box hexpand halign={Gtk.Align.END}>
<Hyprland.SysTray />
<QuickView.QuickView />
</box>
</box>
</window>
);
}
export default Bar;
const cliHandler = ( args: string[] ): string => {
return 'Not implemented';
}
export default {
Bar,
cliHandler
};