chore(ags): bump npm deps and fix breaking changes
All checks were successful
Discord / discord commits (push) Has been skipped

This commit is contained in:
matt1432 2024-10-21 03:22:02 -04:00
parent fa29886b8a
commit 086144490b
9 changed files with 18 additions and 20 deletions

Binary file not shown.

View file

@ -4,15 +4,15 @@
"main": "config.js",
"type": "module",
"dependencies": {
"@eslint/js": "9.12.0",
"@eslint/js": "9.13.0",
"@stylistic/eslint-plugin": "2.9.0",
"@types/eslint__js": "8.42.3",
"@types/node": "22.7.5",
"eslint": "9.12.0",
"eslint-plugin-jsdoc": "50.3.2",
"@types/node": "22.7.7",
"eslint": "9.13.0",
"eslint-plugin-jsdoc": "50.4.3",
"fzf": "0.5.2",
"jiti": "2.3.3",
"typescript": "5.6.3",
"typescript-eslint": "8.8.1"
"typescript-eslint": "8.10.0"
}
}

View file

@ -110,7 +110,7 @@ in {
'';
"${agsConfigDir}/config/node_modules".source =
buildNodeModules ./config "sha256-4ybtwyZs7AgIYiGm1RuWwEgrnkxAqIEkPZjJJfQV/6I=";
buildNodeModules ./config "sha256-PDfS8hDxE+DMACXexSYng0COOCM5q6y250VSis/IAO8=";
}
// (import ./icons.nix {inherit pkgs agsConfigDir;})
);

View file

@ -16,7 +16,6 @@ self: {
packages = [
(pkgs.writeShellApplication {
name = "agsV2";
runtimeInputs = [];
text = ''
exec ${agsV2Packages.agsFull}/bin/ags --config ${configDir} "$@"
'';
@ -37,7 +36,7 @@ self: {
})
// {
"${configDir}/node_modules".source =
buildNodeModules ./. "sha256-aWVnn4G5ypOacju+0wwPeie7JEZoXYDY2qPOTmCdXsg=";
buildNodeModules ./. "sha256-f0hbPvHTqeFM7mfmV+sN4EEuE0F91f5kjJ/EHy0oU+Y=";
"${configDir}/tsconfig.json".source = pkgs.writers.writeJSON "tsconfig.json" {
"$schema" = "https://json.schemastore.org/tsconfig";

Binary file not shown.

View file

@ -3,15 +3,15 @@
"version": "0.0.0",
"main": "app.ts",
"dependencies": {
"@eslint/js": "9.12.0",
"@eslint/js": "9.13.0",
"@stylistic/eslint-plugin": "2.9.0",
"@types/eslint__js": "8.42.3",
"@types/node": "22.7.5",
"eslint": "9.12.0",
"eslint-plugin-jsdoc": "50.3.2",
"@types/node": "22.7.7",
"eslint": "9.13.0",
"eslint-plugin-jsdoc": "50.4.3",
"fzf": "0.5.2",
"jiti": "2.3.3",
"typescript": "5.6.3",
"typescript-eslint": "8.8.1"
"typescript-eslint": "8.10.0"
}
}

View file

@ -1,4 +1,5 @@
import { App, Astal, Gtk, Widget } from 'astal/gtk3';
import { idle } from 'astal';
import AstalApps from 'gi://AstalApps?version=0.1';
@ -80,7 +81,7 @@ export default () => {
}
});
const refreshApplications = () => {
const refreshApplications = () => idle(() => {
(list.get_children() as Gtk.ListBoxRow[])
.forEach((child) => {
child.destroy();
@ -96,7 +97,7 @@ export default () => {
list.show_all();
on_text_change('');
};
});
refreshApplications();

View file

@ -20,12 +20,11 @@ export default () => {
client: AstalHyprland.Client | null = Hyprland.get_focused_client(),
) => {
lastFocused = client?.get_address();
const app = Applications.query(
const app = Applications.fuzzy_query(
client?.get_class() ?? '',
false,
)[0];
focusedIcon.set(app.iconName ?? '');
focusedIcon.set(app?.iconName ?? '');
focusedTitle.set(client?.get_title() ?? '');
const id = client?.connect('notify::title', (c) => {
if (c.get_address() !== lastFocused) {

View file

@ -34,9 +34,8 @@ const NotifIcon = ({ notifObj }: {
icon = notifObj.get_app_icon();
}
else {
icon = Applications.query(
icon = Applications.fuzzy_query(
notifObj.get_app_name(),
false,
)[0].get_icon_name();
}