Merge branch 'dm-tab' into 'develop'
Direct Message tab See merge request pleroma/pleroma-fe!374
This commit is contained in:
commit
be6ebc176b
|
@ -8,6 +8,7 @@ import FriendsTimeline from '../components/friends_timeline/friends_timeline.vue
|
||||||
import TagTimeline from '../components/tag_timeline/tag_timeline.vue'
|
import TagTimeline from '../components/tag_timeline/tag_timeline.vue'
|
||||||
import ConversationPage from '../components/conversation-page/conversation-page.vue'
|
import ConversationPage from '../components/conversation-page/conversation-page.vue'
|
||||||
import Mentions from '../components/mentions/mentions.vue'
|
import Mentions from '../components/mentions/mentions.vue'
|
||||||
|
import DMs from '../components/dm_timeline/dm_timeline.vue'
|
||||||
import UserProfile from '../components/user_profile/user_profile.vue'
|
import UserProfile from '../components/user_profile/user_profile.vue'
|
||||||
import Settings from '../components/settings/settings.vue'
|
import Settings from '../components/settings/settings.vue'
|
||||||
import Registration from '../components/registration/registration.vue'
|
import Registration from '../components/registration/registration.vue'
|
||||||
|
@ -88,6 +89,7 @@ const afterStoreSetup = ({store, i18n}) => {
|
||||||
{ name: 'conversation', path: '/notice/:id', component: ConversationPage, meta: { dontScroll: true } },
|
{ name: 'conversation', path: '/notice/:id', component: ConversationPage, meta: { dontScroll: true } },
|
||||||
{ name: 'user-profile', path: '/users/:id', component: UserProfile },
|
{ name: 'user-profile', path: '/users/:id', component: UserProfile },
|
||||||
{ name: 'mentions', path: '/:username/mentions', component: Mentions },
|
{ name: 'mentions', path: '/:username/mentions', component: Mentions },
|
||||||
|
{ name: 'dms', path: '/:username/dms', component: DMs },
|
||||||
{ name: 'settings', path: '/settings', component: Settings },
|
{ name: 'settings', path: '/settings', component: Settings },
|
||||||
{ name: 'registration', path: '/registration', component: Registration },
|
{ name: 'registration', path: '/registration', component: Registration },
|
||||||
{ name: 'registration', path: '/registration/:token', component: Registration },
|
{ name: 'registration', path: '/registration/:token', component: Registration },
|
||||||
|
|
|
@ -0,0 +1,14 @@
|
||||||
|
import Timeline from '../timeline/timeline.vue'
|
||||||
|
|
||||||
|
const DMs = {
|
||||||
|
computed: {
|
||||||
|
timeline () {
|
||||||
|
return this.$store.state.statuses.timelines.dms
|
||||||
|
}
|
||||||
|
},
|
||||||
|
components: {
|
||||||
|
Timeline
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default DMs
|
|
@ -0,0 +1,5 @@
|
||||||
|
<template>
|
||||||
|
<Timeline :title="$t('nav.dms')" v-bind:timeline="timeline" v-bind:timeline-name="'dms'"/>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script src="./dm_timeline.js"></script>
|
|
@ -12,6 +12,11 @@
|
||||||
{{ $t("nav.mentions") }}
|
{{ $t("nav.mentions") }}
|
||||||
</router-link>
|
</router-link>
|
||||||
</li>
|
</li>
|
||||||
|
<li v-if='currentUser'>
|
||||||
|
<router-link :to="{ name: 'dms', params: { username: currentUser.screen_name } }">
|
||||||
|
{{ $t("nav.dms") }}
|
||||||
|
</router-link>
|
||||||
|
</li>
|
||||||
<li v-if='currentUser && currentUser.locked'>
|
<li v-if='currentUser && currentUser.locked'>
|
||||||
<router-link to='/friend-requests'>
|
<router-link to='/friend-requests'>
|
||||||
{{ $t("nav.friend_requests") }}
|
{{ $t("nav.friend_requests") }}
|
||||||
|
|
|
@ -32,6 +32,7 @@
|
||||||
"chat": "Local Chat",
|
"chat": "Local Chat",
|
||||||
"friend_requests": "Follow Requests",
|
"friend_requests": "Follow Requests",
|
||||||
"mentions": "Mentions",
|
"mentions": "Mentions",
|
||||||
|
"dms": "Direct Messages",
|
||||||
"public_tl": "Public Timeline",
|
"public_tl": "Public Timeline",
|
||||||
"timeline": "Timeline",
|
"timeline": "Timeline",
|
||||||
"twkn": "The Whole Known Network"
|
"twkn": "The Whole Known Network"
|
||||||
|
|
|
@ -41,7 +41,8 @@ export const defaultState = {
|
||||||
own: emptyTl(),
|
own: emptyTl(),
|
||||||
publicAndExternal: emptyTl(),
|
publicAndExternal: emptyTl(),
|
||||||
friends: emptyTl(),
|
friends: emptyTl(),
|
||||||
tag: emptyTl()
|
tag: emptyTl(),
|
||||||
|
dms: emptyTl()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -15,6 +15,7 @@ const STATUS_URL = '/api/statuses/show'
|
||||||
const MEDIA_UPLOAD_URL = '/api/statusnet/media/upload'
|
const MEDIA_UPLOAD_URL = '/api/statusnet/media/upload'
|
||||||
const CONVERSATION_URL = '/api/statusnet/conversation'
|
const CONVERSATION_URL = '/api/statusnet/conversation'
|
||||||
const MENTIONS_URL = '/api/statuses/mentions.json'
|
const MENTIONS_URL = '/api/statuses/mentions.json'
|
||||||
|
const DM_TIMELINE_URL = '/api/statuses/dm_timeline.json'
|
||||||
const FOLLOWERS_URL = '/api/statuses/followers.json'
|
const FOLLOWERS_URL = '/api/statuses/followers.json'
|
||||||
const FRIENDS_URL = '/api/statuses/friends.json'
|
const FRIENDS_URL = '/api/statuses/friends.json'
|
||||||
const FOLLOWING_URL = '/api/friendships/create.json'
|
const FOLLOWING_URL = '/api/friendships/create.json'
|
||||||
|
@ -292,6 +293,7 @@ const fetchTimeline = ({timeline, credentials, since = false, until = false, use
|
||||||
public: PUBLIC_TIMELINE_URL,
|
public: PUBLIC_TIMELINE_URL,
|
||||||
friends: FRIENDS_TIMELINE_URL,
|
friends: FRIENDS_TIMELINE_URL,
|
||||||
mentions: MENTIONS_URL,
|
mentions: MENTIONS_URL,
|
||||||
|
dms: DM_TIMELINE_URL,
|
||||||
notifications: QVITTER_USER_NOTIFICATIONS_URL,
|
notifications: QVITTER_USER_NOTIFICATIONS_URL,
|
||||||
'publicAndExternal': PUBLIC_AND_EXTERNAL_TIMELINE_URL,
|
'publicAndExternal': PUBLIC_AND_EXTERNAL_TIMELINE_URL,
|
||||||
user: QVITTER_USER_TIMELINE_URL,
|
user: QVITTER_USER_TIMELINE_URL,
|
||||||
|
|
Loading…
Reference in New Issue