]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/commitdiff
Correctly scroll in notification preferences
authorChocobozzz <me@florianbigard.com>
Tue, 8 Jan 2019 14:06:58 +0000 (15:06 +0100)
committerChocobozzz <chocobozzz@cpy.re>
Wed, 9 Jan 2019 10:15:15 +0000 (11:15 +0100)
client/src/app/+my-account/my-account-notifications/my-account-notifications.component.html
client/src/app/+my-account/my-account-settings/my-account-settings.component.html
client/src/app/app-routing.module.ts

index d2810c343fde7130d2d4cbefed53da45ecf3a2e4..b98a1087e8d752c1699b1d34fd92e9ddb2c4bd6a 100644 (file)
@@ -1,5 +1,5 @@
 <div class="header">
-  <a routerLink="/my-account/settings" i18n>Notification preferences</a>
+  <a routerLink="/my-account/settings" fragment="notifications" i18n>Notification preferences</a>
 
   <button (click)="markAllAsRead()" i18n>Mark all as read</button>
 </div>
index 2eb7dd56e54792c7258a530caafcfa79028544d9..ad64f28fed3407e1557215742a8ae719ce114301 100644 (file)
@@ -4,10 +4,8 @@
   <span i18n class="user-quota-label">Video quota:</span> {{ userVideoQuotaUsed | bytes: 0 }} / {{ userVideoQuota }}
 </div>
 
-<ng-template [ngIf]="user && user.account">
-  <div i18n class="account-title">Profile</div>
-  <my-account-profile [user]="user" [userInformationLoaded]="userInformationLoaded"></my-account-profile>
-</ng-template>
+<div i18n class="account-title">Profile</div>
+<my-account-profile [user]="user" [userInformationLoaded]="userInformationLoaded"></my-account-profile>
 
 <div i18n class="account-title" id="notifications">Notifications</div>
 <my-account-notification-preferences [user]="user" [userInformationLoaded]="userInformationLoaded"></my-account-notification-preferences>
index 545d6aedab8e257358805f1a87ba87ae4572c188..cff37a7d6f187930eb7622881cdac10ce493aa58 100644 (file)
@@ -43,7 +43,8 @@ const routes: Routes = [
   imports: [
     RouterModule.forRoot(routes, {
       useHash: Boolean(history.pushState) === false,
-      preloadingStrategy: PreloadSelectedModulesList
+      preloadingStrategy: PreloadSelectedModulesList,
+      anchorScrolling: 'enabled'
     })
   ],
   providers: [