diff options
author | Chocobozzz <me@florianbigard.com> | 2021-04-28 11:49:34 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2021-04-28 11:49:34 +0200 |
commit | 746018f6b81b40e8858303662ac9ec5ce59ac6eb (patch) | |
tree | 7b115d12c1926e6283346072fe1c6adbf056abd7 /client/src/app/+my-library/my-subscriptions | |
parent | ec489ce2f74570f94dffb62266f4ed6f18621b3e (diff) | |
download | PeerTube-746018f6b81b40e8858303662ac9ec5ce59ac6eb.tar.gz PeerTube-746018f6b81b40e8858303662ac9ec5ce59ac6eb.tar.zst PeerTube-746018f6b81b40e8858303662ac9ec5ce59ac6eb.zip |
Refactor actor avatar display
Diffstat (limited to 'client/src/app/+my-library/my-subscriptions')
-rw-r--r-- | client/src/app/+my-library/my-subscriptions/my-subscriptions.component.html | 7 | ||||
-rw-r--r-- | client/src/app/+my-library/my-subscriptions/my-subscriptions.component.scss | 19 |
2 files changed, 18 insertions, 8 deletions
diff --git a/client/src/app/+my-library/my-subscriptions/my-subscriptions.component.html b/client/src/app/+my-library/my-subscriptions/my-subscriptions.component.html index ff448ad87..853d47fe6 100644 --- a/client/src/app/+my-library/my-subscriptions/my-subscriptions.component.html +++ b/client/src/app/+my-library/my-subscriptions/my-subscriptions.component.html | |||
@@ -19,9 +19,7 @@ | |||
19 | 19 | ||
20 | <div class="video-channels" myInfiniteScroller [autoInit]="true" (nearOfBottom)="onNearOfBottom()" [dataObservable]="onDataSubject.asObservable()"> | 20 | <div class="video-channels" myInfiniteScroller [autoInit]="true" (nearOfBottom)="onNearOfBottom()" [dataObservable]="onDataSubject.asObservable()"> |
21 | <div *ngFor="let videoChannel of videoChannels" class="video-channel"> | 21 | <div *ngFor="let videoChannel of videoChannels" class="video-channel"> |
22 | <a [routerLink]="[ '/video-channels', videoChannel.nameWithHost ]"> | 22 | <my-actor-avatar [channel]="videoChannel" [internalHref]="[ '/video-channels', videoChannel.nameWithHost ]"></my-actor-avatar> |
23 | <img [src]="videoChannel.avatarUrl" alt="Avatar" /> | ||
24 | </a> | ||
25 | 23 | ||
26 | <div class="video-channel-info"> | 24 | <div class="video-channel-info"> |
27 | <a [routerLink]="[ '/video-channels', videoChannel.nameWithHost ]" class="video-channel-names" i18n-title title="Channel page"> | 25 | <a [routerLink]="[ '/video-channels', videoChannel.nameWithHost ]" class="video-channel-names" i18n-title title="Channel page"> |
@@ -33,7 +31,8 @@ | |||
33 | 31 | ||
34 | <a [routerLink]="[ '/accounts', videoChannel.ownerBy ]" i18n-title title="Owner account page" class="actor-owner"> | 32 | <a [routerLink]="[ '/accounts', videoChannel.ownerBy ]" i18n-title title="Owner account page" class="actor-owner"> |
35 | <span i18n>Created by {{ videoChannel.ownerBy }}</span> | 33 | <span i18n>Created by {{ videoChannel.ownerBy }}</span> |
36 | <img [src]="videoChannel.ownerAvatarUrl" alt="Owner account avatar" /> | 34 | |
35 | <my-actor-avatar [account]="videoChannel.ownerAccount" size="18"></my-actor-avatar> | ||
37 | </a> | 36 | </a> |
38 | </div> | 37 | </div> |
39 | 38 | ||
diff --git a/client/src/app/+my-library/my-subscriptions/my-subscriptions.component.scss b/client/src/app/+my-library/my-subscriptions/my-subscriptions.component.scss index 3c1a4d2ad..53ceaa250 100644 --- a/client/src/app/+my-library/my-subscriptions/my-subscriptions.component.scss +++ b/client/src/app/+my-library/my-subscriptions/my-subscriptions.component.scss | |||
@@ -8,8 +8,8 @@ input[type=text] { | |||
8 | .video-channel { | 8 | .video-channel { |
9 | @include row-blocks; | 9 | @include row-blocks; |
10 | 10 | ||
11 | img { | 11 | > my-actor-avatar { |
12 | @include channel-avatar(80px); | 12 | @include actor-avatar-size(80px); |
13 | 13 | ||
14 | margin-right: 10px; | 14 | margin-right: 10px; |
15 | } | 15 | } |
@@ -40,9 +40,20 @@ input[type=text] { | |||
40 | } | 40 | } |
41 | 41 | ||
42 | .actor-owner { | 42 | .actor-owner { |
43 | @include actor-owner; | 43 | @include disable-default-a-behaviour; |
44 | |||
45 | font-size: 13px; | ||
46 | color: pvar(--mainForegroundColor); | ||
44 | 47 | ||
45 | margin-top: 0; | 48 | span:hover { |
49 | opacity: 0.8; | ||
50 | } | ||
51 | |||
52 | my-actor-avatar { | ||
53 | margin-left: 7px; | ||
54 | display: inline-block; | ||
55 | vertical-align: top; | ||
56 | } | ||
46 | } | 57 | } |
47 | 58 | ||
48 | .video-subscriptions-header { | 59 | .video-subscriptions-header { |