From d15531fb3567f2f27229d3086ffd48069ca73315 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 14 Apr 2023 09:42:50 +0200 Subject: Fix follow links --- .../app/+about/about-follows/about-follows.component.html | 8 ++++---- .../app/+about/about-follows/about-follows.component.ts | 15 +++++++++------ 2 files changed, 13 insertions(+), 10 deletions(-) (limited to 'client/src/app') diff --git a/client/src/app/+about/about-follows/about-follows.component.html b/client/src/app/+about/about-follows/about-follows.component.html index fd4109416..37571dfa4 100644 --- a/client/src/app/+about/about-follows/about-follows.component.html +++ b/client/src/app/+about/about-follows/about-follows.component.html @@ -6,8 +6,8 @@
{{ instanceName }} does not have followers.
- - {{ follower }} + + {{ follower.name }} @@ -18,8 +18,8 @@
{{ instanceName }} does not have subscriptions.
- - {{ following }} + + {{ following.name }} diff --git a/client/src/app/+about/about-follows/about-follows.component.ts b/client/src/app/+about/about-follows/about-follows.component.ts index 35d810388..e1df8b813 100644 --- a/client/src/app/+about/about-follows/about-follows.component.ts +++ b/client/src/app/+about/about-follows/about-follows.component.ts @@ -13,8 +13,8 @@ import { Actor } from '@shared/models/actors' export class AboutFollowsComponent implements OnInit { instanceName: string - followers: string[] = [] - followings: string[] = [] + followers: { name: string, url: string }[] = [] + followings: { name: string, url: string }[] = [] loadedAllFollowers = false loadedAllFollowings = false @@ -130,10 +130,13 @@ export class AboutFollowsComponent implements OnInit { } private formatFollow (actor: Actor) { - // Instance follow, only display host - if (actor.name === 'peertube') return actor.host + return { + // Instance follow, only display host + name: actor.name === 'peertube' + ? actor.host + : actor.name + '@' + actor.host, - return actor.name + '@' + actor.host + url: actor.url + } } - } -- cgit v1.2.3