From fc268c48bc95ee8947da071305a436b293f44c02 Mon Sep 17 00:00:00 2001 From: Roger Braun Date: Thu, 8 Dec 2016 09:09:21 +0100 Subject: Very basic user following. --- .../user_card_content/user_card_content.vue | 24 ++++++++++++++++++++++ src/components/user_profile/user_profile.vue | 17 +++++++++++++++ 2 files changed, 41 insertions(+) (limited to 'src/components') diff --git a/src/components/user_card_content/user_card_content.vue b/src/components/user_card_content/user_card_content.vue index 7ad86e63..484597ab 100644 --- a/src/components/user_card_content/user_card_content.vue +++ b/src/components/user_card_content/user_card_content.vue @@ -6,6 +6,21 @@
{{user.name}}
@{{user.screen_name}}
+
+
+ Follows you! +
+
+ + Following them! + + + + +
+
@@ -37,6 +52,15 @@ color: `#${this.user.profile_link_color}`, 'background-image': `url(${this.user.cover_photo})` } + }, + isOtherUser () { + return this.user !== this.$store.state.users.currentUser + } + }, + methods: { + followUser () { + this.$store.state.api.backendInteractor.followUser(this.user.id) + .then((x) => console.log) } } } diff --git a/src/components/user_profile/user_profile.vue b/src/components/user_profile/user_profile.vue index eaa5396d..2ceb13ec 100644 --- a/src/components/user_profile/user_profile.vue +++ b/src/components/user_profile/user_profile.vue @@ -5,3 +5,20 @@ + + -- cgit v1.2.3-70-g09d2