feat(ags4): add Kompass
All checks were successful
Discord / discord commits (push) Has been skipped

This commit is contained in:
matt1432 2025-01-05 20:23:44 -05:00
parent 64e1d3f7ce
commit 9fed14cba5
6 changed files with 25 additions and 5 deletions

Binary file not shown.

BIN
flake.nix

Binary file not shown.

View file

@ -165,6 +165,13 @@ let
inputs.astal.follows = "astal"; inputs.astal.follows = "astal";
}; };
kompass = mkInput {
owner = "kotontrion";
repo = "kompass";
inputs.astal.follows = "astal";
};
gtk-session-lock = mkDep { gtk-session-lock = mkDep {
owner = "Cu3PO42"; owner = "Cu3PO42";
repo = "gtk-session-lock"; repo = "gtk-session-lock";

View file

@ -11,7 +11,7 @@
buildPhase = '' buildPhase = ''
npx @ts-for-gir/cli generate \ npx @ts-for-gir/cli generate \
${concatMapStringsSep "\n" (p: " ${p.girName} \\") withGirNames} ${concatMapStringsSep "\n" (p: " ${p.girName} \\") withGirNames}
${concatMapStringsSep "\n" (p: " -g ${p.package.dev}/share/gir-1.0 \\") withGirNames} ${concatMapStringsSep "\n" (p: " -g ${p.package.dev or p.package}/share/gir-1.0 \\") withGirNames}
-g ${ts-for-gir-src}/girs \ -g ${ts-for-gir-src}/girs \
--ignoreVersionConflicts \ --ignoreVersionConflicts \
-o ./types -o ./types

View file

@ -1,6 +1,8 @@
import { App, Astal, Gtk } from 'astal/gtk4'; import { App, Astal, Gtk } from 'astal/gtk4';
import { Variable } from 'astal'; import { Variable } from 'astal';
import Kompass from 'gi://Kompass';
import { Box, Button, Calendar, CenterBox, Label, MenuButton, Popover, Window } from './subclasses'; import { Box, Button, Calendar, CenterBox, Label, MenuButton, Popover, Window } from './subclasses';
const { EXCLUSIVE } = Astal.Exclusivity; const { EXCLUSIVE } = Astal.Exclusivity;
@ -29,7 +31,7 @@ export default () => {
application={App} application={App}
> >
<CenterBox cssName="centerbox"> <CenterBox cssName="centerbox">
<Button onClicked="echo hi" /> <Kompass.Tray />
{styledBox} {styledBox}

View file

@ -5,9 +5,10 @@ self: {
pkgs, pkgs,
... ...
}: let }: let
inherit (self.inputs) ags astal gtk-session-lock; inherit (self.inputs) ags astal gtk-session-lock kompass;
gtkSessionLock = gtk-session-lock.packages.${pkgs.system}.default; gtkSessionLock = gtk-session-lock.packages.${pkgs.system}.default;
libKompass = kompass.packages.${pkgs.system}.libkompass;
inherit (lib) attrValues boolToString filter getExe mkIf optionalAttrs optionals; inherit (lib) attrValues boolToString filter getExe mkIf optionalAttrs optionals;
@ -55,7 +56,17 @@ in {
wireplumber wireplumber
; ;
inherit gtkSessionLock; inherit
gtkSessionLock
libKompass
;
# libkompass dependencies
inherit
(astal.packages.${pkgs.system})
cava
river
;
inherit inherit
(pkgs) (pkgs)
@ -122,7 +133,7 @@ in {
pname = "ags"; pname = "ags";
configPath = "${cfg.configDir}/@girs"; configPath = "${cfg.configDir}/@girs";
packages = filter (x: packages = filter (x:
x.pname != "libadwaita") x.pname != "libadwaita" && x.pname != "libkompass")
cfg.astalLibs; cfg.astalLibs;
}) })
// (buildGirTypes { // (buildGirTypes {