nixos-configs/modules/ags/config/ts/misc/closer.ts
matt1432 5ceef68fe1
All checks were successful
Discord / discord commits (push) Has been skipped
fix(ags): fix latest breaking changes
2024-01-31 15:09:03 -05:00

13 lines
301 B
TypeScript

// Types
import { PopupWindow } from 'global-types';
export default () => {
(App.windows as Array<PopupWindow>)
.filter((w) => w &&
w.close_on_unfocus &&
w.close_on_unfocus !== 'stay')
.forEach((w) => {
App.closeWindow(w.name);
});
};