Compare commits

...

2 commits

Author SHA1 Message Date
worm ceb5da36b7 Bigger, faster, stronger 2023-11-20 10:11:50 -08:00
worm d9cf1a7738 cleanup 2023-11-20 10:08:34 -08:00
2 changed files with 11 additions and 7 deletions

View file

@ -1,6 +1,7 @@
a flood of unnecessary sev2 notifications from a Zapier bot ruining your entire life?
Are you dealing with a flood of unnecessary application notifications in a Slack Channel?
Use the slack web app and install this [Tampermonkey](https://www.tampermonkey.net/) script.
Then, update the 'appText' const and it will filter out messages based on the app's 'username'
For the full app (tm) experience, run it in chrome like:
`nohup google-chrome --app=https://app.slack.com &`

View file

@ -1,23 +1,26 @@
// ==UserScript==
// @name Zapier, why won't u just leave me alone?
// @name slack-app-notif-nuker
// @namespace http://git.minimally.online/
// @version 0.1
// @description Allows you to hide Slack messages from needlessly noisy apps/individuals based on content
// @author drudgesentinel (Sean)
// @author Max
// @match *://app.slack.com/*
// @icon https://i.postimg.cc/NGb9WSWn/is-it-joy.png
// @icon https://i.ibb.co/wCj7Tg5/ear-plug.png
// @grant none
// @downloadURL https://git.minimally.online/drudgesentinel/stfu-zapier/raw/branch/main/foz.user.js
// @updateURL https://git.minimally.online/drudgesentinel/stfu-zapier/raw/branch/main/foz.user.js
// ==/UserScript==
//going to eventually want to check if the terraform-support is highlighted, probably. We'll see.
// Icon from flaticons.com
// At present, this filtration is specific to app generated messages.
// EDIT the const SPAM to select application notifs to remove
const SPAM = "KANBAN UPDATE NOTIFICATION";
const removeMessages = () => {
const messages = Array.from(document.querySelectorAll('[data-qa="virtual-list-item"]'));
const haveButtons = messages.filter(message => message.querySelector('button'));
haveButtons.forEach( (node) => removeIfSpam(node, "SEV2 Handoff Candidate"));
haveButtons.forEach( (node) => removeIfSpam(node, SPAM));
}
const removeIfSpam = (node, spamMessage) => {