57 lines
1.3 KiB
TypeScript
57 lines
1.3 KiB
TypeScript
import { App, Astal, Gtk, Gdk } from "astal/gtk3";
|
|
import {
|
|
Cpu,
|
|
BatteryLevel,
|
|
Ram,
|
|
Storage,
|
|
Workspaces,
|
|
// FocusedClient,
|
|
Time,
|
|
SysTray,
|
|
LauncherButton,
|
|
PowerMenuButton,
|
|
MediaPlayerButton,
|
|
Volume,
|
|
} from "./modules/export";
|
|
import { BatteryMenu, MediaMenu, PowerMenu } from "./menus/menus";
|
|
|
|
export default function Bar(gdkmonitor: Gdk.Monitor) {
|
|
const { TOP, LEFT, RIGHT } = Astal.WindowAnchor;
|
|
return (
|
|
<>
|
|
<window
|
|
className="Bar"
|
|
name="Bar"
|
|
gdkmonitor={gdkmonitor}
|
|
exclusivity={Astal.Exclusivity.EXCLUSIVE}
|
|
anchor={TOP | LEFT | RIGHT}
|
|
application={App}
|
|
>
|
|
<centerbox>
|
|
<box hexpand halign={Gtk.Align.START} className="RoudedBlock">
|
|
<LauncherButton />
|
|
<Cpu />
|
|
<Ram />
|
|
<Storage />
|
|
{/*<FocusedClient />*/}
|
|
</box>
|
|
<box hexpand halign={Gtk.Align.CENTER} className="RoudedBlock">
|
|
<Workspaces />
|
|
</box>
|
|
<box hexpand halign={Gtk.Align.END} className="RoudedBlock">
|
|
<Volume />
|
|
<MediaPlayerButton />
|
|
<SysTray />
|
|
<BatteryLevel />
|
|
<Time />
|
|
<PowerMenuButton />
|
|
</box>
|
|
</centerbox>
|
|
</window>
|
|
<PowerMenu />
|
|
<MediaMenu />
|
|
<BatteryMenu />
|
|
</>
|
|
);
|
|
}
|