Adding keyboard shortcuts

parent 23310dac
......@@ -143,6 +143,7 @@
</div>
</div>
</el-form>
<button v-shortkey="['b']" @shortkey="pushRoute({name: 'admin.page.page.index'})" style="display: none"></button>
</div>
</template>
......@@ -150,10 +151,11 @@
import axios from 'axios'
import Slugify from '../../../../Core/Assets/js/mixins/Slugify'
import TranslationHelper from '../../../../Core/Assets/js/mixins/TranslationHelper'
import ShortcutHelper from '../../../../Core/Assets/js/mixins/ShortcutHelper'
import Form from 'form-backend-validation'
export default {
mixins: [Slugify, TranslationHelper],
mixins: [Slugify, TranslationHelper, ShortcutHelper],
props: {
locales: {default: null},
pageTitle: {default: null, String},
......
......@@ -71,6 +71,7 @@
</div>
</div>
</div>
<button v-shortkey="['c']" @shortkey="pushRoute({name: 'admin.page.page.create'})" style="display: none"></button>
</div>
</template>
......@@ -78,11 +79,12 @@
import axios from 'axios'
import _ from "lodash";
import TranslationHelper from '../../../../Core/Assets/js/mixins/TranslationHelper'
import ShortcutHelper from '../../../../Core/Assets/js/mixins/ShortcutHelper'
let data;
export default {
mixins: [TranslationHelper],
mixins: [TranslationHelper, ShortcutHelper],
data() {
return {
data,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment