diff options
author | Chocobozzz <me@florianbigard.com> | 2019-02-20 10:16:04 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-02-20 10:16:04 +0100 |
commit | b28e4e5e080646ec67363cb0a16c9bd97ccffb35 (patch) | |
tree | a1af72cd2b0c7138bcaa4cb5f44e5db6d168e05d /client/src/app/menu/avatar-notification.component.ts | |
parent | 28c8e63e55cad24b024fc1d05aa1cfc0257434e5 (diff) | |
download | PeerTube-b28e4e5e080646ec67363cb0a16c9bd97ccffb35.tar.gz PeerTube-b28e4e5e080646ec67363cb0a16c9bd97ccffb35.tar.zst PeerTube-b28e4e5e080646ec67363cb0a16c9bd97ccffb35.zip |
Add user notification animation
Diffstat (limited to 'client/src/app/menu/avatar-notification.component.ts')
-rw-r--r-- | client/src/app/menu/avatar-notification.component.ts | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/client/src/app/menu/avatar-notification.component.ts b/client/src/app/menu/avatar-notification.component.ts index 878c5c88c..a77a001ca 100644 --- a/client/src/app/menu/avatar-notification.component.ts +++ b/client/src/app/menu/avatar-notification.component.ts | |||
@@ -17,6 +17,7 @@ export class AvatarNotificationComponent implements OnInit, OnDestroy { | |||
17 | @Input() user: User | 17 | @Input() user: User |
18 | 18 | ||
19 | unreadNotifications = 0 | 19 | unreadNotifications = 0 |
20 | loaded = false | ||
20 | 21 | ||
21 | private notificationSub: Subscription | 22 | private notificationSub: Subscription |
22 | private routeSub: Subscription | 23 | private routeSub: Subscription |
@@ -54,6 +55,14 @@ export class AvatarNotificationComponent implements OnInit, OnDestroy { | |||
54 | this.popover.close() | 55 | this.popover.close() |
55 | } | 56 | } |
56 | 57 | ||
58 | onPopoverHidden () { | ||
59 | this.loaded = false | ||
60 | } | ||
61 | |||
62 | onNotificationLoaded () { | ||
63 | this.loaded = true | ||
64 | } | ||
65 | |||
57 | private async subscribeToNotifications () { | 66 | private async subscribeToNotifications () { |
58 | const obs = await this.userNotificationSocket.getMyNotificationsSocket() | 67 | const obs = await this.userNotificationSocket.getMyNotificationsSocket() |
59 | 68 | ||