From d41470830b7b78787f7586f2f4f30709afadefc6 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Wed, 8 Apr 2020 21:42:02 -0600 Subject: [PATCH] Update Timeline.vue, add remote post/profile links --- resources/assets/js/components/Timeline.vue | 26 +++++++-------------- 1 file changed, 8 insertions(+), 18 deletions(-) diff --git a/resources/assets/js/components/Timeline.vue b/resources/assets/js/components/Timeline.vue index 8e8279f0..f9e6db66 100644 --- a/resources/assets/js/components/Timeline.vue +++ b/resources/assets/js/components/Timeline.vue @@ -1411,22 +1411,19 @@ }, statusUrl(status) { - return status.url; + if(status.local == true) { + return status.url; + } - // if(status.local == true) { - // return status.url; - // } - - // return '/i/web/post/_/' + status.account.id + '/' + status.id; + return '/i/web/post/_/' + status.account.id + '/' + status.id; }, profileUrl(status) { - return status.account.url; - // if(status.local == true) { - // return status.account.url; - // } + if(status.local == true) { + return status.account.url; + } - // return '/i/web/profile/_/' + status.account.id; + return '/i/web/profile/_/' + status.account.id; }, statusCardUsernameFormat(status) { @@ -1480,13 +1477,6 @@ .then(res => { this.userStory = res.data; }) - }, - - usernameLookup(text, cb) { - axios.get('/api/pixelfed/v2/username/lookup?q=' + text) - .then(res => { - cb(res.data); - }); } } }