the-djmaze / snappymail

Simple, modern & fast web-based email client
https://snappymail.eu
GNU Affero General Public License v3.0
998 stars 121 forks source link

Block Sender #1590

Open apezio opened 4 months ago

apezio commented 4 months ago

It currently takes 10 steps to block a sender. With this feature it would instead take 2 steps. Over time this seems useful for a lot of people in many different situations.

This would help in these scenarios: 1) You receive emails from a company - that you have a relationship with - and there is no way to unsubscribe without logging into their website (which is very annoying and sometime impossble). 2) The message is not spam. 3) You dont want it to be Learned as Spam. 3) You just dont want to see the messages. 4) Some person is emailing you repeatedly and you want to auto-delete all emails from them (block). 5) The unsubscribe function doesn't work (or you dont want to click on the link) for a mailing list.

Describe the solution you'd like Add "Block Sender" to the hamburger menus. This would append the From: address to a sieve rule which deletes the message.

Describe alternatives you've considered Manually copying and pasting the From address into a Sieve rule (it requires 10 steps).

Additional context Gmail has this feature and it is very convenient.

the-djmaze commented 4 months ago

But to which Sieve script? You can have many scripts and only 1 can be active. But, that active script could be a container to include other scripts. So how would you see that in 2 steps? And how would a user know in which script and if it is active?

apezio commented 4 months ago

But to which Sieve script?

The Active one. Yes, it could become convoluted if a user is changing between Active scripts - but at worst it means some emails which are already getting through without this feature, still get through.

1) If there is no 'Blocked Senders' rule, append a new rule to the bottom of the active script. 2) Append a "From:", "Equal To", "" Condition. 3) Action should be "Discard".

As for the two steps - once this function is added to the hamburger menus a user would be able to add an email address to this Blocked Senders Rule with two clicks (one on the hamburger and one on "Block Sender".

And how would a user know in which script and if it is active?

It's always added to the active script. Therefore, assuming the user already knows which script they have active, they would know where the rule is going.

the-djmaze commented 1 week ago

Please read https://github.com/the-djmaze/snappymail/discussions/1753#discussioncomment-10714512