Add moderation button to side drawer
ci/woodpecker/pr/woodpecker Pipeline was successful Details

This commit is contained in:
Sol Fisher Romanoff 2022-11-05 16:23:42 +02:00
parent bdd970ca68
commit bff34818bb
Signed by untrusted user who does not match committer: nbsp
GPG Key ID: 9D3F2B64F2341B62
4 changed files with 23 additions and 16 deletions

View File

@ -13,20 +13,6 @@
>
<ReportsTab />
</div>
<!-- <div -->
<!-- :label="$t('moderation.users')" -->
<!-- icon="users" -->
<!-- data-tab-name="users" -->
<!-- > -->
<!-- <UsersTab /> -->
<!-- </div> -->
<!-- <div -->
<!-- :label="$t('moderation.statuses')" -->
<!-- icon="message" -->
<!-- data-tab-name="statuses" -->
<!-- > -->
<!-- <StatusesTab /> -->
<!-- </div> -->
</tab-switcher>
</template>

View File

@ -15,7 +15,8 @@ import {
faTachometerAlt,
faCog,
faInfoCircle,
faList
faList,
faUserTie
} from '@fortawesome/free-solid-svg-icons'
library.add(
@ -30,7 +31,8 @@ library.add(
faTachometerAlt,
faCog,
faInfoCircle,
faList
faList,
faUserTie
)
const SideDrawer = {
@ -102,6 +104,9 @@ const SideDrawer = {
},
openSettingsModal () {
this.$store.dispatch('openSettingsModal')
},
openModModal () {
this.$store.dispatch('openModModal')
}
}
}

View File

@ -143,6 +143,21 @@
/> {{ $t("nav.about") }}
</router-link>
</li>
<li
v-if="currentUser && currentUser.role === 'admin' || currentUser.role === 'moderator'"
@click="toggleDrawer"
>
<button
class="button-unstyled -link -fullwidth"
@click="openModModal"
>
<FAIcon
fixed-width
class="fa-scale-110 fa-old-padding"
icon="user-tie"
/> {{ $t("nav.moderation") }}
</button>
</li>
<li
v-if="currentUser && currentUser.role === 'admin'"
@click="toggleDrawer"

View File

@ -307,6 +307,7 @@
"interactions": "Interactions",
"lists": "Lists",
"mentions": "Mentions",
"moderation": "Moderation",
"preferences": "Preferences",
"public_timeline_description": "Public posts from this instance",
"public_tl": "Public timeline",