mirror of
https://github.com/aelve/guide.git
synced 2024-11-25 18:56:52 +03:00
Cmd enter handling (#393)
This commit is contained in:
parent
c9d512cb08
commit
38725ca37c
@ -160,7 +160,10 @@
|
||||
>
|
||||
<v-layout column class="pa-3">
|
||||
<v-flex>
|
||||
<v-form @keydown.native.enter.ctrl="updateItemInfo">
|
||||
<v-form
|
||||
@keydown.native.enter.ctrl="updateItemInfo"
|
||||
@keydown.native.enter.meta="updateItemInfo"
|
||||
>
|
||||
<v-text-field
|
||||
v-model="itemNameEdit"
|
||||
label="Name"
|
||||
|
@ -7,9 +7,10 @@
|
||||
'markdown-editor_has-bottom-toolbar': bottomToolbar,
|
||||
'markdown-editor_has-top-toolbar': toolbar
|
||||
}"
|
||||
@keydown.capture.enter="onEnterDown"
|
||||
@keydown.ctrl.enter="onCtrlEnterDown"
|
||||
@keydown.esc="cancel"
|
||||
@keydown.exact.capture.enter="onEnterDown"
|
||||
@keydown.exact.ctrl.enter="onCtrlEnterDown"
|
||||
@keydown.exact.meta.enter="onCtrlEnterDown"
|
||||
@keydown.exact.esc="cancel"
|
||||
v-show="editor && isReady"
|
||||
>
|
||||
<textarea ref="editor" />
|
||||
@ -80,7 +81,7 @@ export default class MarkdownEditor extends Vue {
|
||||
isReady: boolean = false
|
||||
|
||||
get saveTip () {
|
||||
return `press${this.saveOnEnter ? ' Enter or' : ''} Ctrl+Enter to save`
|
||||
return `press${this.saveOnEnter ? ' Enter or' : ''} Ctrl/Cmd + Enter to save`
|
||||
}
|
||||
|
||||
get heightValue () {
|
||||
|
Loading…
Reference in New Issue
Block a user