nextcloud / deck

πŸ—‚ Kanban-style project & personal management tool for Nextcloud, similar to Trello
https://apps.nextcloud.com/apps/deck
GNU Affero General Public License v3.0
1.2k stars 273 forks source link

`CTRL` + `ENTER` to Save Changes on Card Description #3268

Closed SethFalco closed 1 year ago

SethFalco commented 3 years ago

How to use GitHub

Is your feature request related to a problem? Please describe.

In many apps doing CTRL + ENTER acts as a "finished" action to either send, post, or save whatever the user is typing.

For example:

Describe the solution you'd like

After clicking "Edit description" the user can type to edit the description of a card. I think if a user does CTRL + ENTER it should act as if the user clicked "View description". (Save and return to the non-edit view.)

Describe alternatives you've considered

N/A

Additional context

Moved over from https://github.com/stefan-niedermann/nextcloud-deck/issues/1087

stefan-niedermann commented 3 years ago

Related to #46

dodedodo commented 3 years ago

I think CTRL + S would make more sense in this case. You're not sending or submitting a message like in a mail client or twitter, but rather saving a description.

CTRL + ENTER would make sense for comments.

SethFalco commented 3 years ago

I think CTRL + ENTER makes more sense, since CTRL + S usually doesn't affect the view. I'm not asking to only save the content of the description, I'm suggesting this should kick the user out of the "Edit description" view entirely.

This is likely subjective, however. In the end, I'm down for whatever most users are into.

Ben-Ro commented 2 years ago

Hey all, this missing feature annoyed me for some time, so i decided to implement it.

It uses Keylisteners on easymde.codemirror. Once the CMD/CTRL is pressed, it sets keyExitState = 1 until the key is released. If Enter is pushed while this, it calls hideEditor() (just like the Action Button) and removes all Keylisteners.

I just create a Pull Request, i hope the code quality is ok :)