]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/commitdiff
Avoid layout shift in account setup modal
authorChocobozzz <me@florianbigard.com>
Fri, 27 Aug 2021 07:30:32 +0000 (09:30 +0200)
committerChocobozzz <me@florianbigard.com>
Fri, 27 Aug 2021 07:30:32 +0000 (09:30 +0200)
client/src/app/modal/account-setup-modal.component.html
client/src/app/modal/account-setup-modal.component.scss
client/src/app/modal/account-setup-modal.component.ts

index 55bae78bf518572c8ebd7b56dd44eeb39152104d..d1f1538359b69aea8b31ab30e8cd87ef834c4eda 100644 (file)
@@ -5,7 +5,7 @@
   </div>
 
   <div class="modal-body">
-    <img class="mascot" src="/client/assets/images/mascot/happy.svg" alt="mascot">
+    <img class="mascot" src="/client/assets/images/mascot/happy.svg" alt="">
 
     <div i18n class="subtitle">It's time to set up your account profile!</div>
 
index 405f29d6594656259c51245a133c0f7b1e7c6005..d99edaf7af6e433c8e89db4532a4111fa44eec9b 100644 (file)
@@ -17,7 +17,8 @@
   @include margin-right(2rem);
 
   display: block;
-  min-width: 170px;
+  width: 170px;
+  height: 220px;
 }
 
 .subtitle {
index 8256f510360ff0499284304c3259d324e5ac83af..4cb8de2c778dc53db1f5bdf1b415b5483f4f1b43 100644 (file)
@@ -45,11 +45,12 @@ export class AccountSetupModalComponent implements OnInit {
 
   ngOnInit () {
     this.serverConfig = this.serverService.getHTMLConfig()
-    this.user = this.authService.getUser()
 
     this.authService.userInformationLoaded
       .subscribe(
         () => {
+          this.user = this.authService.getUser()
+
           if (this.isUserRoot) return
           if (this.hasAccountAvatar && this.hasAccountDescription) return
           if (this.userService.hasSignupInThisSession()) return