Skip to content
Snippets Groups Projects

Add quick filters for notifications

Merged Shpuld Shpludson requested to merge feat/notification-quick-filters into develop
All threads resolved!
Files
10
import { timelineNames } from '../timeline_menu/timeline_menu.js'
import TimelineMenuContent from '../timeline_menu/timeline_menu_content.vue'
import { mapState, mapGetters } from 'vuex'
import { mapState, mapGetters } from 'vuex'
import { library } from '@fortawesome/fontawesome-svg-core'
import { library } from '@fortawesome/fontawesome-svg-core'
@@ -7,10 +7,12 @@ import {
@@ -7,10 +7,12 @@ import {
faGlobe,
faGlobe,
faBookmark,
faBookmark,
faEnvelope,
faEnvelope,
faHome,
faChevronDown,
 
faChevronUp,
faComments,
faComments,
faBell,
faBell,
faInfoCircle
faInfoCircle,
 
faStream
} from '@fortawesome/free-solid-svg-icons'
} from '@fortawesome/free-solid-svg-icons'
library.add(
library.add(
@@ -18,10 +20,12 @@ library.add(
@@ -18,10 +20,12 @@ library.add(
faGlobe,
faGlobe,
faBookmark,
faBookmark,
faEnvelope,
faEnvelope,
faHome,
faChevronDown,
 
faChevronUp,
faComments,
faComments,
faBell,
faBell,
faInfoCircle
faInfoCircle,
 
faStream
)
)
const NavPanel = {
const NavPanel = {
@@ -30,16 +34,20 @@ const NavPanel = {
@@ -30,16 +34,20 @@ const NavPanel = {
this.$store.dispatch('startFetchingFollowRequests')
this.$store.dispatch('startFetchingFollowRequests')
}
}
},
},
 
components: {
 
TimelineMenuContent
 
},
 
data () {
 
return {
 
showTimelines: false
 
}
 
},
 
methods: {
 
toggleTimelines () {
 
this.showTimelines = !this.showTimelines
 
}
 
},
computed: {
computed: {
onTimelineRoute () {
return !!timelineNames()[this.$route.name]
},
timelinesRoute () {
if (this.$store.state.interface.lastTimeline) {
return this.$store.state.interface.lastTimeline
}
return this.currentUser ? 'friends' : 'public-timeline'
},
...mapState({
...mapState({
currentUser: state => state.users.currentUser,
currentUser: state => state.users.currentUser,
followRequestCount: state => state.api.followRequests.length,
followRequestCount: state => state.api.followRequests.length,
Loading