From b2bd128f059de44a0ec27591dbc0052f494887a1 Mon Sep 17 00:00:00 2001
From: taehoon
Date: Thu, 25 Jul 2019 15:14:44 -0400
Subject: [PATCH] allow zooming avatar in profile panel header
---
src/components/user_card/user_card.js | 9 ++-------
src/components/user_card/user_card.vue | 4 ++--
src/components/user_profile/user_profile.vue | 1 +
3 files changed, 5 insertions(+), 9 deletions(-)
diff --git a/src/components/user_card/user_card.js b/src/components/user_card/user_card.js
index 070af38a5b..82d3b83590 100644
--- a/src/components/user_card/user_card.js
+++ b/src/components/user_card/user_card.js
@@ -5,10 +5,9 @@ import ModerationTools from '../moderation_tools/moderation_tools.vue'
import { hex2rgb } from '../../services/color_convert/color_convert.js'
import { requestFollow, requestUnfollow } from '../../services/follow_manipulate/follow_manipulate'
import generateProfileLink from 'src/services/user_profile_link_generator/user_profile_link_generator'
-import { isEqual } from 'lodash'
export default {
- props: [ 'user', 'switcher', 'selected', 'hideBio', 'rounded', 'bordered' ],
+ props: [ 'user', 'switcher', 'selected', 'hideBio', 'rounded', 'bordered', 'allowZoomingAvatar' ],
data () {
return {
followRequestInProgress: false,
@@ -101,10 +100,6 @@ export default {
const validRole = rights.admin || rights.moderator
const roleTitle = rights.admin ? 'admin' : 'moderator'
return validRole && roleTitle
- },
- isActiveRoute () {
- const profileRoute = this.userProfileLink(this.user)
- return profileRoute.name === this.$route.name && isEqual(profileRoute.params, this.$route.params)
}
},
components: {
@@ -168,7 +163,7 @@ export default {
reportUser () {
this.$store.dispatch('openUserReportingModal', this.user.id)
},
- enlargeAvatar () {
+ zoomAvatar () {
const attachment = {
url: this.user.profile_image_url_original,
mimetype: 'image'
diff --git a/src/components/user_card/user_card.vue b/src/components/user_card/user_card.vue
index 3c0bf0d4ea..3c200a7fbb 100644
--- a/src/components/user_card/user_card.vue
+++ b/src/components/user_card/user_card.vue
@@ -8,9 +8,9 @@