Skip to content
Snippets Groups Projects
Unverified Commit fd770b00 authored by syuilo's avatar syuilo
Browse files

Add new shortcut

parent b0d60ef2
No related branches found
No related tags found
No related merge requests found
<template>
<div class="notifications">
<div class="notifications" v-hotkey.global="keymap">
<button :data-active="isOpen" @click="toggle" title="%i18n:@title%">
%fa:R bell%<template v-if="hasUnreadNotification">%fa:circle%</template>
</button>
......@@ -19,11 +19,19 @@ export default Vue.extend({
isOpen: false
};
},
computed: {
hasUnreadNotification(): boolean {
return this.$store.getters.isSignedIn && this.$store.state.i.hasUnreadNotification;
},
keymap(): any {
return {
'shift+n': this.toggle
};
}
},
methods: {
toggle() {
this.isOpen ? this.close() : this.open();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment