feat: no system badges plugin (#33)

This commit is contained in:
Diamond 2022-10-03 17:36:02 -07:00 committed by GitHub
parent 0a2c637c61
commit e35393b40c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 31 additions and 1 deletions

5
.gitignore vendored
View file

@ -1,2 +1,5 @@
dist dist
node_modules node_modules
venboy.exe
.vscode
.idea

View file

@ -0,0 +1,23 @@
import { Devs } from "../utils/constants";
import definePlugin from "../utils/types";
export default definePlugin({
name: "NoSystemBadge",
description: "Disables the taskbar and system tray unread count badge.",
authors: [Devs.rushii],
patches: [
{
find: "setSystemTrayApplications:function",
replacement: [
{
match: /setBadge:function.+?},/,
replace: "setBadge:function(){},"
},
{
match: /setSystemTrayIcon:function.+?},/,
replace: "setSystemTrayIcon:function(){},"
}
]
}
]
});

View file

@ -26,5 +26,9 @@ export const Devs = Object.freeze({
obscurity: { obscurity: {
name: "obscurity", name: "obscurity",
id: 336678828233588736n, id: 336678828233588736n,
},
rushii: {
name: "rushii",
id: 295190422244950017n
} }
}); });