mail icon indicating copy to clipboard operation
mail copied to clipboard

Add 'cancel' button to discard draft

Open jospoortvliet opened this issue 5 years ago • 9 comments

Subject says it all - right now you have to go to the drafts folder and delete the draft every time you started a reply but decided to drop it ;-)

Good first issue if you already know vue.js according to @ChristophWurst who will of course help anyone who needs help with it!


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

jospoortvliet avatar Jan 18 '20 15:01 jospoortvliet

The "Discard draft" action can go into the 3-dot menu next to the button. :) The code is at https://github.com/nextcloud/mail/blob/master/src/components/Composer.vue#L134-L148

jancborchardt avatar Jan 19 '20 14:01 jancborchardt

Would also be nice beeing able to manually save/close the draft edit mode, which could also get added to this 3-dot menu. Additionally, I would not say "discard draft" since it gets automatically saved. Instead I would call this option "delete draft".

szaimen avatar Feb 26 '20 18:02 szaimen

I'm trying to tackle this. Unfamiliarity with the code is making it take longer than I'd wish, but it's a fun learning experience 😊

Adding the action buttons was no problem. I'm currently trying to figure out how to actually delete the draft, but while I dig into the code to figure that out: Where do y'all want to navigate after a draft has been saved + closed or deleted? And should it really be saved + closed or just manually saved?

Edit: Oh, and whlie I'm at it: I couldn't find an icon-save or something simlar. Going with icon-download for now, but that doesn't feel ideal. I'll look into it later unless someone feels like telling me 😇

Frustration edit: I don't get icons 😭

ahstro avatar Feb 27 '20 09:02 ahstro

Whoops, I probably shouldn't have talked about this issue in #2697; accidentally triggered GitHub's auto-close. Can someone reopen? 😇

ahstro avatar Feb 27 '20 13:02 ahstro

@ChristophWurst is it again an auto-close abuse ? :raised_eyebrow: I didn't see any fix on this.

mat-m avatar Jul 04 '21 22:07 mat-m

is it again an auto-close abuse ?

like what? This ticket is open.

ChristophWurst avatar Jul 05 '21 06:07 ChristophWurst

Hi, I was wondering what would be still to do (if it still is) on this issue. thanks!

raykotab avatar Oct 03 '22 18:10 raykotab

image

delete draft is supported. close?

ChristophWurst avatar Jul 11 '24 14:07 ChristophWurst

image

delete draft is supported. close?

If you click on an existing draft, it trigger the edit dialog by default, so you can't easily remove it by pressing DEL in the the list view. When a draft is edited without modifying it, the Save action is not triggered and the bin-icon is not shown. Once a draft exists, the bin-icon should already be there.

mat-m avatar Aug 25 '24 16:08 mat-m