let mobile users customize top bar as well
This commit is contained in:
parent
0123872b56
commit
c3e7eadddf
@ -23,6 +23,7 @@ import RemoteUserResolver from 'components/remote_user_resolver/remote_user_reso
|
|||||||
import Lists from 'components/lists/lists.vue'
|
import Lists from 'components/lists/lists.vue'
|
||||||
import ListsTimeline from 'components/lists_timeline/lists_timeline.vue'
|
import ListsTimeline from 'components/lists_timeline/lists_timeline.vue'
|
||||||
import ListsEdit from 'components/lists_edit/lists_edit.vue'
|
import ListsEdit from 'components/lists_edit/lists_edit.vue'
|
||||||
|
import NavPanel from 'src/components/nav_panel/nav_panel.vue'
|
||||||
|
|
||||||
export default (store) => {
|
export default (store) => {
|
||||||
const validateAuthenticatedRoute = (to, from, next) => {
|
const validateAuthenticatedRoute = (to, from, next) => {
|
||||||
@ -78,7 +79,8 @@ export default (store) => {
|
|||||||
{ name: 'user-profile', path: '/:_(users)?/:name', component: UserProfile },
|
{ name: 'user-profile', path: '/:_(users)?/:name', component: UserProfile },
|
||||||
{ name: 'lists', path: '/lists', component: Lists },
|
{ name: 'lists', path: '/lists', component: Lists },
|
||||||
{ name: 'lists-timeline', path: '/lists/:id', component: ListsTimeline },
|
{ name: 'lists-timeline', path: '/lists/:id', component: ListsTimeline },
|
||||||
{ name: 'lists-edit', path: '/lists/:id/edit', component: ListsEdit }
|
{ name: 'lists-edit', path: '/lists/:id/edit', component: ListsEdit },
|
||||||
|
{ name: 'edit-navigation', path: '/nav-edit', component: NavPanel, props: () => ({ forceExpand: true }), beforeEnter: validateAuthenticatedRoute }
|
||||||
]
|
]
|
||||||
|
|
||||||
if (store.state.instance.pleromaChatMessagesAvailable) {
|
if (store.state.instance.pleromaChatMessagesAvailable) {
|
||||||
|
@ -34,6 +34,7 @@ library.add(
|
|||||||
faList
|
faList
|
||||||
)
|
)
|
||||||
const NavPanel = {
|
const NavPanel = {
|
||||||
|
props: ['forceExpand'],
|
||||||
created () {
|
created () {
|
||||||
if (this.currentUser && this.currentUser.locked) {
|
if (this.currentUser && this.currentUser.locked) {
|
||||||
this.$store.dispatch('startFetchingFollowRequests')
|
this.$store.dispatch('startFetchingFollowRequests')
|
||||||
|
@ -1,7 +1,10 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="NavPanel">
|
<div class="NavPanel">
|
||||||
<div class="panel panel-default">
|
<div class="panel panel-default">
|
||||||
<div class="panel-heading">
|
<div
|
||||||
|
v-if="!forceExpand"
|
||||||
|
class="panel-heading"
|
||||||
|
>
|
||||||
<NavigationPins />
|
<NavigationPins />
|
||||||
<div class="spacer"/>
|
<div class="spacer"/>
|
||||||
<button
|
<button
|
||||||
@ -15,7 +18,7 @@
|
|||||||
/>
|
/>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
<ul class="panel-body" v-if="!collapsed">
|
<ul class="panel-body" v-if="!collapsed || forceExpand">
|
||||||
<li v-if="currentUser || !privateMode">
|
<li v-if="currentUser || !privateMode">
|
||||||
<button
|
<button
|
||||||
class="button-unstyled menu-item"
|
class="button-unstyled menu-item"
|
||||||
|
@ -15,6 +15,7 @@ import {
|
|||||||
faTachometerAlt,
|
faTachometerAlt,
|
||||||
faCog,
|
faCog,
|
||||||
faInfoCircle,
|
faInfoCircle,
|
||||||
|
faCompass,
|
||||||
faList
|
faList
|
||||||
} from '@fortawesome/free-solid-svg-icons'
|
} from '@fortawesome/free-solid-svg-icons'
|
||||||
|
|
||||||
@ -30,6 +31,7 @@ library.add(
|
|||||||
faTachometerAlt,
|
faTachometerAlt,
|
||||||
faCog,
|
faCog,
|
||||||
faInfoCircle,
|
faInfoCircle,
|
||||||
|
faCompass,
|
||||||
faList
|
faList
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -191,6 +191,18 @@
|
|||||||
/> {{ $t("nav.administration") }}
|
/> {{ $t("nav.administration") }}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li
|
||||||
|
v-if="currentUser"
|
||||||
|
@click="toggleDrawer"
|
||||||
|
>
|
||||||
|
<router-link :to="{ name: 'edit-navigation' }">
|
||||||
|
<FAIcon
|
||||||
|
fixed-width
|
||||||
|
class="fa-scale-110 fa-old-padding"
|
||||||
|
icon="compass"
|
||||||
|
/> {{ $t("nav.edit_nav_mobile") }}
|
||||||
|
</router-link>
|
||||||
|
</li>
|
||||||
<li
|
<li
|
||||||
v-if="currentUser"
|
v-if="currentUser"
|
||||||
@click="toggleDrawer"
|
@click="toggleDrawer"
|
||||||
|
@ -149,7 +149,8 @@
|
|||||||
"preferences": "Preferences",
|
"preferences": "Preferences",
|
||||||
"timelines": "Timelines",
|
"timelines": "Timelines",
|
||||||
"chats": "Chats",
|
"chats": "Chats",
|
||||||
"lists": "Lists"
|
"lists": "Lists",
|
||||||
|
"edit_nav_mobile": "Customize navigation bar"
|
||||||
},
|
},
|
||||||
"notifications": {
|
"notifications": {
|
||||||
"broken_favorite": "Unknown status, searching for it…",
|
"broken_favorite": "Unknown status, searching for it…",
|
||||||
|
Loading…
Reference in New Issue
Block a user