rename favourite to favorite
This commit is contained in:
parent
6511166631
commit
8c9bcdc6c1
@ -121,7 +121,7 @@ const conversation = {
|
|||||||
this.$store.state.api.backendInteractor.fetchConversation({id: this.status.id})
|
this.$store.state.api.backendInteractor.fetchConversation({id: this.status.id})
|
||||||
.then(({ancestors, descendants}) => {
|
.then(({ancestors, descendants}) => {
|
||||||
const ancestorId = ancestors.length ? ancestors[0].id : this.status.id
|
const ancestorId = ancestors.length ? ancestors[0].id : this.status.id
|
||||||
this.fetchFavouritedByUsers(ancestorId)
|
this.fetchFavoritedByUsers(ancestorId)
|
||||||
this.fetchRebloggedByUsers(ancestorId)
|
this.fetchRebloggedByUsers(ancestorId)
|
||||||
this.$store.dispatch('addNewStatuses', { statuses: ancestors })
|
this.$store.dispatch('addNewStatuses', { statuses: ancestors })
|
||||||
this.$store.dispatch('addNewStatuses', { statuses: descendants })
|
this.$store.dispatch('addNewStatuses', { statuses: descendants })
|
||||||
@ -152,8 +152,8 @@ const conversation = {
|
|||||||
this.setHighlight(null)
|
this.setHighlight(null)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
fetchFavouritedByUsers (id) {
|
fetchFavoritedByUsers (id) {
|
||||||
this.$store.dispatch('fetchFavouritedByUsers', { id })
|
this.$store.dispatch('fetchFavoritedByUsers', { id })
|
||||||
},
|
},
|
||||||
fetchRebloggedByUsers (id) {
|
fetchRebloggedByUsers (id) {
|
||||||
this.$store.dispatch('fetchRebloggedByUsers', { id })
|
this.$store.dispatch('fetchRebloggedByUsers', { id })
|
||||||
|
@ -133,7 +133,7 @@
|
|||||||
<link-preview :card="status.card" :size="attachmentSize" :nsfw="nsfwClickthrough" />
|
<link-preview :card="status.card" :size="attachmentSize" :nsfw="nsfwClickthrough" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="favs-favourited-users" v-if="combinedFavsAndRepeatsAvatars.length > 0" :class="{ 'status-fadein': combinedFavsAndRepeatsAvatars.length > 0 }">
|
<div class="favs-favorited-users" v-if="combinedFavsAndRepeatsAvatars.length > 0" :class="{ 'status-fadein': combinedFavsAndRepeatsAvatars.length > 0 }">
|
||||||
<AvatarList :avatars='combinedFavsAndRepeatsAvatars'></AvatarList>
|
<AvatarList :avatars='combinedFavsAndRepeatsAvatars'></AvatarList>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -616,7 +616,7 @@ a.unmute {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.favs-favourited-users {
|
.favs-favorited-users {
|
||||||
margin-top: 10px;
|
margin-top: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -537,8 +537,8 @@ const statuses = {
|
|||||||
credentials: rootState.users.currentUser.credentials
|
credentials: rootState.users.currentUser.credentials
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
fetchFavouritedByUsers ({ rootState, commit }, { id }) {
|
fetchFavoritedByUsers ({ rootState, commit }, { id }) {
|
||||||
rootState.api.backendInteractor.fetchFavouritedByUsers({id}).then((favoritedByUsers) => commit('addFavoritedByUsers', { favoritedByUsers, id }))
|
rootState.api.backendInteractor.fetchFavoritedByUsers({id}).then((favoritedByUsers) => commit('addFavoritedByUsers', { favoritedByUsers, id }))
|
||||||
},
|
},
|
||||||
fetchRebloggedByUsers ({ rootState, commit }, { id }) {
|
fetchRebloggedByUsers ({ rootState, commit }, { id }) {
|
||||||
rootState.api.backendInteractor.fetchRebloggedByUsers({id}).then((rebloggedByUsers) => commit('addRebloggedByUsers', { rebloggedByUsers, id }))
|
rootState.api.backendInteractor.fetchRebloggedByUsers({id}).then((rebloggedByUsers) => commit('addRebloggedByUsers', { rebloggedByUsers, id }))
|
||||||
|
@ -49,7 +49,7 @@ const MASTODON_MUTE_USER_URL = id => `/api/v1/accounts/${id}/mute`
|
|||||||
const MASTODON_UNMUTE_USER_URL = id => `/api/v1/accounts/${id}/unmute`
|
const MASTODON_UNMUTE_USER_URL = id => `/api/v1/accounts/${id}/unmute`
|
||||||
const MASTODON_POST_STATUS_URL = '/api/v1/statuses'
|
const MASTODON_POST_STATUS_URL = '/api/v1/statuses'
|
||||||
const MASTODON_MEDIA_UPLOAD_URL = '/api/v1/media'
|
const MASTODON_MEDIA_UPLOAD_URL = '/api/v1/media'
|
||||||
const MASTODON_STATUS_FAVOURITEDBY_URL = id => `/api/v1/statuses/${id}/favourited_by`
|
const MASTODON_STATUS_FAVORITEDBY_URL = id => `/api/v1/statuses/${id}/favourited_by`
|
||||||
const MASTODON_STATUS_REBLOGGEDBY_URL = id => `/api/v1/statuses/${id}/reblogged_by`
|
const MASTODON_STATUS_REBLOGGEDBY_URL = id => `/api/v1/statuses/${id}/reblogged_by`
|
||||||
|
|
||||||
import { each, map } from 'lodash'
|
import { each, map } from 'lodash'
|
||||||
@ -724,8 +724,8 @@ const markNotificationsAsSeen = ({id, credentials}) => {
|
|||||||
}).then((data) => data.json())
|
}).then((data) => data.json())
|
||||||
}
|
}
|
||||||
|
|
||||||
const fetchFavouritedByUsers = ({id}) => {
|
const fetchFavoritedByUsers = ({id}) => {
|
||||||
return promisedRequest(MASTODON_STATUS_FAVOURITEDBY_URL(id)).then((users) => users.map(parseUser))
|
return promisedRequest(MASTODON_STATUS_FAVORITEDBY_URL(id)).then((users) => users.map(parseUser))
|
||||||
}
|
}
|
||||||
|
|
||||||
const fetchRebloggedByUsers = ({id}) => {
|
const fetchRebloggedByUsers = ({id}) => {
|
||||||
@ -781,7 +781,7 @@ const apiService = {
|
|||||||
denyUser,
|
denyUser,
|
||||||
suggestions,
|
suggestions,
|
||||||
markNotificationsAsSeen,
|
markNotificationsAsSeen,
|
||||||
fetchFavouritedByUsers,
|
fetchFavoritedByUsers,
|
||||||
fetchRebloggedByUsers
|
fetchRebloggedByUsers
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -112,7 +112,7 @@ const backendInteractorService = (credentials) => {
|
|||||||
const deleteAccount = ({password}) => apiService.deleteAccount({credentials, password})
|
const deleteAccount = ({password}) => apiService.deleteAccount({credentials, password})
|
||||||
const changePassword = ({password, newPassword, newPasswordConfirmation}) => apiService.changePassword({credentials, password, newPassword, newPasswordConfirmation})
|
const changePassword = ({password, newPassword, newPasswordConfirmation}) => apiService.changePassword({credentials, password, newPassword, newPasswordConfirmation})
|
||||||
|
|
||||||
const fetchFavouritedByUsers = ({id}) => apiService.fetchFavouritedByUsers({id})
|
const fetchFavoritedByUsers = ({id}) => apiService.fetchFavoritedByUsers({id})
|
||||||
const fetchRebloggedByUsers = ({id}) => apiService.fetchRebloggedByUsers({id})
|
const fetchRebloggedByUsers = ({id}) => apiService.fetchRebloggedByUsers({id})
|
||||||
|
|
||||||
const backendInteractorServiceInstance = {
|
const backendInteractorServiceInstance = {
|
||||||
@ -156,7 +156,7 @@ const backendInteractorService = (credentials) => {
|
|||||||
fetchFollowRequests,
|
fetchFollowRequests,
|
||||||
approveUser,
|
approveUser,
|
||||||
denyUser,
|
denyUser,
|
||||||
fetchFavouritedByUsers,
|
fetchFavoritedByUsers,
|
||||||
fetchRebloggedByUsers
|
fetchRebloggedByUsers
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user