Git Product home page Git Product logo

word-notification-improved's People

Contributors

aida-enna avatar jojos38 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

aida-enna

word-notification-improved's Issues

[IMPROVEMENT] Whitelist

Have an option to whitelist servers or dms by ID and only words in those places would trigger the notifications

Mayus problem

Word to check: HELLO
Case sensitive: enabled
The word "hello" triggers the alert, the word "HELLO" doesn't

Word to check: HELLO
Case sensitive: disabled
Neither "HELLO" nor "hello" trigger the alert

Word to check: Hello
Case sensitive: enabled
The word "hello" triggers the alert, the word "HELLO" doesn't

Notifications aren't working

Heya! I recently upgraded to Windows 11 and was getting notifications fine, but after a recent update BDFDB, the notifications from this plugin aren't working anymore. I'm fairly certain that's when it broke, but it might have been a couple days (I thought my life was finally drama free until I realized!).

The reason I'm posting here and not the BDFDB page is because notifications are working for that plugin - If I click settings on BDFDB and then check for updates, it shows a working toast notification:
image

However, putting both the BDAPI and the Windows notification code on the MessageReceived handler does nothing and the plugin doesn't work. I'm not familiar enough with how BD does it's internals to diagnose it :c

Case Sensitive has the opposite effect

With "Case Sensitive" turned off, the plugin will only trigger if the proper casing is used. If it's turned on, any CaSiNg will work. It's having the opposite effect. I tried modifying the plugin to swap it but the changes I made to the plugin don't seem to be taking effect? I've never messed with plugins much before so I'm making it an issue instead of a PR to fix it. Sorry!

For example, if I added the word "aida" to the filter - With Case Sensitive turned off, it would only respond to "aida" and not "Aida" or "AIDA" or any casing variation. Turning Case Sensitive on makes it recognize these.

Nice work on the plugin - I was looking for a more updated version of the Word Notification plugin and I'm happy with what I found. ๐Ÿ‘

[IMPROVEMENT] Change BDFDB toast style

image

var toastString = guild.name + "\n\# " + channel.name + "\n\n" + author.username + ": " + notifWord;
var toastString = "DM\n\n" + author.username + ": " + message.content;

Credits to qwert for making this part โ†“

// Should we send a bdapi notification?
if (settings["bdapi-notification"]) {
	const timeout = settings["bdapi-display-time"];
	BdApi.showToast(toastString, {type: "info"});
}
// Should we send a bdfdb notification?
if (settings["bdfdb-notification"]) {
	const timeout = settings["bdfdb-display-time"];
	const toast = BDFDB.NotificationUtils.toast(toastString, {
		timeout: timeout*1000,
		barColor: BDFDB.UserUtils.getStatusColor("online", true),
		avatar: BDFDB.UserUtils.getAvatar(author.id)
	});
	toast.addEventListener("click", _ => { this.goToMessage(guildID, channel.id, message.id); });
}

Plugin not working post discord update at the end of September

There was a big discord update at the end of September and it broke a lot (all?) plugins. Since then, things have somewhat stabalized, but this plugin still isn't working. It's the last one I need to have my full experience back (I moderate a lot of servers and this helped immensely), and was hoping it could be fixed if possible. Thank you!

Subscribe method changed, plugin no longer loads

Getting [PluginManager] WordNotificationImproved v0.1.0 could not be started. TypeError: BdApi.Webpack.getModule(...).subscribe is not a functionat WordNotificationImproved.start (WordNotificationImproved.plugin.js:122)

The code in question is

BdApi.Webpack.getModule(BdApi.Webpack.Filters.byProps("dispatch")).subscribe("MESSAGE_CREATE", that.messageReceivedOrUpdated);
BdApi.Webpack.getModule(BdApi.Webpack.Filters.byProps("dispatch")).subscribe("MESSAGE_UPDATE", that.messageReceivedOrUpdated);

I tried to use a new version I saw people talking about, but it didn't work (the plugin loaded but it didn't do anything), so I may be way off on this or using it wrong.

const Dispatch = BdApi.Webpack.getModule(BdApi.Webpack.Filters.byProps("dispatch", "subscribe"));
BdApi.Patcher.before("WordNotificationImproved", Dispatch, "dispatch", (_, args, original) => {
	const dispatch = args[0];
	if (!dispatch) return;
	if (dispatch.type === "MESSAGE_CREATE") {
		that.messageReceivedOrUpdated
	}
	if (dispatch.type === "MESSAGE_UPDATE") {
		that.messageReceivedOrUpdated
	}
});

Notif doesn't link you to msg like it used to.

A while back, the notification that popped up on the side of your screen was able to send you to the message right then and there. It doesn't anymore. Furthermore I would like to request you add a button to the left of the search bar to show all the times the word has been said so you can see it in case you missed it when it popped up.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.