Stop swiping on Mobile (or clicking outside on Desktop) from killing the comment modal/box!
I've now lost 3 longform comments I was composing because I accidentally swiped up, or scrolled up too far, and the comment modal disappears. Turns out clicking outside the comment area on Desktop also kills the comment modal 😓 When trying to comment on the same post or comment again, or trying to edit the same comment, the comment modal comes up empty.
I finally got to a point where I thought, "OK, I have to do this on desktop, this is so much time I've lost", and then I thought "OK, maybe I should just install WefWef on Desktop!". Proceeded to edit one of the comments I had previously lost all my work on, and I did something with my trackpad, and my heart sank as the bloody comment modal disappeared, taking with it an hours work of compiling a list of board games with metadata 😭
Solution suggestions:
- kill this functionality! There is a perfectly good "cancel" button right there at the top! Don't let scrolling too far on mobile, or clicking outside the comment area on desktop, make a WIP comment disappear 😔 Even flicking in the wrong direction on mobile kills the comment 😓
- warn me with a new modal, e.g. "Are you sure you want to cancel this comment?", before erasing the data. Retains the (horrible) swiping functionality while giving people a chance to not lose their work.
- auto-save WIP comments, so I can at least click "Edit" or "Comment" again and the text is still there. Certainly the least good suggestion, but would at least be something.
Thanks.
We should do something like we do for the new post dialog. But it will require significant refactor to not use the useIonDialog hook (in order to determine whether dialog can be dismissed if it is dirty)
Im assigning this p3 though, so this is important and will be fixed soon.
Sorry for your lost work :(
Thank you! And sorry for all the !s, it was late and I was frustrated 😬
Looking forward to a fix, thanks for taking it seriously 😃
And no worries about the work, I'll be able to do it again at some point, but thank you for mentioning it 😊👌
@aeharding Thank you so much for fixing this! 🥳
Swiping up for comment context is brilliant, and the warning modal about wanting to discard ones work or not is spot on 👌
I couldn't be happier with this incredibly swift and apt solution; again, thank you.