Vencord icon indicating copy to clipboard operation
Vencord copied to clipboard

[Plugin] HideMessage

Open hanzydev opened this issue 11 months ago • 18 comments

Adds a context menu option to hide messages.

hanzydev avatar Feb 25 '24 16:02 hanzydev

How is this different from the existing delete message button?

Kyuuhachi avatar Feb 25 '24 16:02 Kyuuhachi

How is this different from the existing delete message button?

The Delete Message button deletes the message you sent from everyone. The difference of this plugin is that it only deletes the message from your client, it does not send any API requests.

hanzydev avatar Feb 25 '24 16:02 hanzydev

How is this different from the existing delete message button?

The Delete Message button deletes the message you sent from everyone. The difference of this plugin is that it only deletes the message from your client, it does not send any API requests.

what's the use case for this even

Koishukaze avatar Feb 25 '24 16:02 Koishukaze

I guess maybe if you're taking screenshots and you want to delete stuff that contains private info or irrelavent stuff?

TheKodeToad avatar Feb 25 '24 16:02 TheKodeToad

How is this different from the existing delete message button?

The Delete Message button deletes the message you sent from everyone. The difference of this plugin is that it only deletes the message from your client, it does not send any API requests.

what's the use case for this even

Sometimes our friends and other people can send nsfw or disturbing images/content in a text channel that we don't want to see in a public place. This plugin removes the message from the DOM on demand. Kind of WhatsApp does but without a storage mechanism. When you reload your client the messages will be shown again.

hanzydev avatar Feb 25 '24 16:02 hanzydev

I guess maybe if you're taking screenshots and you want to delete stuff that contains private info or irrelavent stuff?

Exactly.

hanzydev avatar Feb 25 '24 16:02 hanzydev

Cool stuff. Keep it up!

ReXulEc avatar Feb 25 '24 17:02 ReXulEc

I think this could do with a rebranding. Imo, "Delete From Me" doesn't make much sense. I would change it to "Hide Message".

You are absolutely right. I changed the plugin name to Hide Message.

hanzydev avatar Feb 25 '24 18:02 hanzydev

Haven't tried this plugin but I feel, if it's not already implemented, that there should be a button to show all hidden messages without having to reload your client. Maybe this could be a command or something that show when you right click a message.

ethan-davies avatar Feb 27 '24 22:02 ethan-davies

Hi, I already opened a PR for the same plugin a while back, should I close it?

Ushie avatar Mar 02 '24 11:03 Ushie

Haven't tried this plugin but I feel, if it's not already implemented, that there should be a button to show all hidden messages without having to reload your client. Maybe this could be a command or something that show when you right click a message.

Implemented in my latest commit

Discord_4mEKVFYwhp

hanzydev avatar Mar 02 '24 17:03 hanzydev

I also added support for using Message Logger with Hide Message plugin:

Discord_5z0lDSHZHx

hanzydev avatar Mar 02 '24 17:03 hanzydev

It's been 2 weeks and no one is looking at PR. Why is that? @Vendicated

hanzydev avatar Mar 10 '24 17:03 hanzydev

It's been 2 weeks and no one is looking at PR. Why is that? @Vendicated

vee reviews PRs when they are motivated to, be patient

nin0-dev avatar Mar 10 '24 17:03 nin0-dev

Currently there is no result and in 6 days, 2 months will have passed.

hanzydev avatar Apr 19 '24 16:04 hanzydev

There is over a hundred PRs with some dating over a year ago, someone will eventually review your PR but until then it's best to just forget about this until you get that magic notification, my PR for the same function took place over 9 months ago

Ushie avatar Apr 19 '24 16:04 Ushie

There is over a hundred PRs with some dating over a year ago, someone will eventually review your PR but until then it's best to just forget about this until you get that magic notification, my PR for the same function took place over 9 months ago

They're literally making fun of people 😂

hanzydev avatar Apr 19 '24 21:04 hanzydev

Your PR will not be reviewed if you keep asking about it. Please be patient, we have other things to do both for the project and in life.

lewisakura avatar Apr 20 '24 04:04 lewisakura

Your PR will not be reviewed if you keep asking about it. Please be patient, we have other things to do both for the project and in life.

A month has passed and the pull request has still not been merged. You say we have things to do in our lives, but a pull request opened 4 hours ago is merged. There are people who have been waiting for a year. If you are not going to approve it, close this pull request and don't drag it out any longer.

hanzydev avatar May 16 '24 13:05 hanzydev

Okay, I don't normally do codereview for plugins anymore, but I'll give a response.

As it stands this plugin is not suited to be merged - creating tons of CSS for hiding messages is not effective and will eventually create a client slowdown. You don't need to manipulate the DOM to do this, you need to create a patch that filters out the hidden messages by ID when the channel view is rendered. I flagged this up previously but it seems like it was dismissed.

I'd also like to point out there is no reason to use that quote against me when I am not the one merging pull requests, because at the time the statement was true and everyone was busy with work, IRL, etc. including myself. I still am and so are many other people. One person starting to merge PRs that are at the top of the list is nothing new but many PRs from time immemorial are getting picked up too and slowly being worked on. I'm sorry that yours got buried, but if it is that much of an issue, then please just close the PR so we can mutually not worry about it. We are also concerned with the number of open PRs and haven't had time to just sit down and go through all of them.

lewisakura avatar May 16 '24 13:05 lewisakura

yeah, as pointed out by lewi, this current implementation is not very good. using css for this is hacky and not sustainable. this was already pointed out two months ago but never addressed. HideAttachments suffers from very much the same problem and honestly needs a rewrite, it's just that it's very old (made within the first two months of vencord existing), that's why it doesn't follow the quality standard as much as other plugins

in the current state this is not mergeable for that reason. here are a few better approaches i can think of:

  • patch the message component to render null for hidden messages
  • patch somewhere else to filter out undesired messages
  • dispatch MESSAGE_DELETE events for the hidden messages

prs are looked at and merged whenever they are looked at and merged. this is a hobby project and there is a long backlog of contributions. this is not a very high priority change. if you are not okay with waiting, you probably shouldn't be contributing

Vendicated avatar May 17 '24 16:05 Vendicated