Probably gonna abandon the QuickActions, as that is just way too much effort for what it does. Will be providing keybinds for doing what I wanted to do there in Hyprland
24 lines
556 B
TypeScript
24 lines
556 B
TypeScript
import { GLib, Variable } from "astal"
|
|
import { Gtk } from "astal/gtk4"
|
|
|
|
const Time = ({ format = "%a, %e.%m %H:%M:%S" }) => {
|
|
const time = Variable<string>("").poll(1000, () =>
|
|
GLib.DateTime.new_now_local().format(format)!)
|
|
|
|
return <menubutton cssClasses={["Time"]} hexpand halign={Gtk.Align.CENTER}>
|
|
<label onDestroy={() => time.drop()} label={time()}></label>
|
|
<popover>
|
|
<Gtk.Calendar />
|
|
</popover>
|
|
</menubutton>
|
|
}
|
|
|
|
const Calendar = () => {
|
|
|
|
}
|
|
|
|
|
|
export default {
|
|
Time
|
|
}
|