implemented status visibility change
This commit is contained in:
parent
aa0cef12b1
commit
19d8875196
16 changed files with 225 additions and 98 deletions
|
|
@ -24,6 +24,21 @@
|
|||
.user-info {
|
||||
margin: 1.2em;
|
||||
}
|
||||
|
||||
&.-admin-view {
|
||||
.list-item {
|
||||
padding: 0;
|
||||
border-bottom: 1px solid var(--border);
|
||||
|
||||
.admin-actions {
|
||||
background: var(--background);
|
||||
}
|
||||
|
||||
.Status{
|
||||
width: 100%
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.user-profile-placeholder {
|
||||
|
|
|
|||
|
|
@ -1,20 +1,18 @@
|
|||
import { get } from 'lodash'
|
||||
import { mapState } from 'pinia'
|
||||
|
||||
import Conversation from 'src/components/conversation/conversation.vue'
|
||||
import List from 'src/components/list/list.vue'
|
||||
import Status from 'src/components/status/status.vue'
|
||||
import UserCard from 'src/components/user_card/user_card.vue'
|
||||
|
||||
import { useInterfaceStore } from 'src/stores/interface.js'
|
||||
import { useAdminSettingsStore } from 'src/stores/admin_settings.js'
|
||||
import { useInterfaceStore } from 'src/stores/interface.js'
|
||||
|
||||
import { library } from '@fortawesome/fontawesome-svg-core'
|
||||
import { faCircleNotch } from '@fortawesome/free-solid-svg-icons'
|
||||
|
||||
library.add(faCircleNotch)
|
||||
|
||||
const defaultTabKey = 'statuses'
|
||||
|
||||
const UserProfileAdminView = {
|
||||
data() {
|
||||
return {
|
||||
|
|
@ -24,7 +22,6 @@ const UserProfileAdminView = {
|
|||
},
|
||||
created() {
|
||||
this.userId = this.$route.params.id
|
||||
console.log(this.userId)
|
||||
useInterfaceStore().setForeignProfileBackground(this.user?.background_image)
|
||||
},
|
||||
updated() {
|
||||
|
|
@ -38,8 +35,8 @@ const UserProfileAdminView = {
|
|||
return {
|
||||
pageSize: 20,
|
||||
godmode: this.godmode,
|
||||
userId: this.userId,
|
||||
withReblogs: false
|
||||
id: this.userId,
|
||||
withReblogs: false,
|
||||
}
|
||||
},
|
||||
user() {
|
||||
|
|
@ -48,18 +45,16 @@ const UserProfileAdminView = {
|
|||
},
|
||||
methods: {
|
||||
fetchStatuses(page) {
|
||||
return useAdminSettingsStore()
|
||||
.fetchStatuses({
|
||||
...this.fetchOptions,
|
||||
page,
|
||||
})
|
||||
.then(({ count, users }) => ({ count, items: users }))
|
||||
return useAdminSettingsStore().fetchStatuses({
|
||||
...this.fetchOptions,
|
||||
page,
|
||||
})
|
||||
},
|
||||
},
|
||||
components: {
|
||||
UserCard,
|
||||
List,
|
||||
Conversation,
|
||||
Status,
|
||||
},
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,14 +1,15 @@
|
|||
<template>
|
||||
<div
|
||||
v-if="user"
|
||||
class="user-profile panel panel-default"
|
||||
class="user-profile -admin-view panel panel-default"
|
||||
>
|
||||
<div class="panel-body card-wrapper">
|
||||
<UserCard
|
||||
:user-id="userId"
|
||||
:compact="compactProfiles"
|
||||
:compact="true"
|
||||
avatar-action="zoom"
|
||||
:hide-bio="true"
|
||||
hide-bio
|
||||
hide-buttons
|
||||
/>
|
||||
</div>
|
||||
<List
|
||||
|
|
@ -17,8 +18,8 @@
|
|||
scrollable
|
||||
>
|
||||
<template #item="{item}">
|
||||
<Conversation
|
||||
:user="item"
|
||||
<Status
|
||||
:statusoid="item"
|
||||
/>
|
||||
</template>
|
||||
</List>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue