diff options
Diffstat (limited to '')
| -rw-r--r-- | ags/config.js | 41 |
1 files changed, 3 insertions, 38 deletions
diff --git a/ags/config.js b/ags/config.js index bc50aa8..cc69e2e 100644 --- a/ags/config.js +++ b/ags/config.js @@ -1,41 +1,6 @@ -// @ts-ignore -const battery = await Service.import("battery") - -const BatteryPercent = () => Widget.Label() - .hook(battery, self => { - self.label = `${battery.percent}%` - self.visible = battery.available - }, "changed") - -const MyButton = () => Widget.Button() - .on("clicked", self => { - print(self, "is clicked") - }) - -const MyDate = () => Widget.Label({ - css: "color:blue; padding: 1em;", -}) - .poll(1000, self => { - self.label = Utils.exec("date +'%_H:%_M:%S'") - }) - -const MyKeybind = () => Widget.Button() - .keybind(["MOD1", "CONTROL"], "a", (_self, _event) => { - print("alt+control+a was pressed") - }) - -const Bar = () => Widget.Window({ - name: 'bar', - anchor: ['top', 'left', 'right'], - child: MyDate(), -}) - -const scss = `${App.configDir}/style.scss` -const css = "/tmp/my-style.css" -Utils.exec(`sassc ${scss} ${css}`) +import { applauncher } from "./modules/applauncher.js" +import { Bar } from "./modules/bar.js" App.config({ - style: css, - windows: [Bar()], + windows: [applauncher, Bar(0)], }) - |
