diff --git a/src/app/creator-room/creator-room.component.html b/src/app/creator-room/creator-room.component.html index 79ca12101fc5b56db7f08b1334709605825578c8..0641b4c87e66a5ed882e0196e503ffe6bbfbf00e 100644 --- a/src/app/creator-room/creator-room.component.html +++ b/src/app/creator-room/creator-room.component.html @@ -1,5 +1,6 @@ <div fxLayout="column" fxLayoutAlign="start" fxLayoutGap="20px" fxFill> <div fxLayout="row" fxLayoutAlign="center"> + <mat-progress-spinner *ngIf="isLoading" mode="indeterminate"></mat-progress-spinner> <mat-card *ngIf="room"> <mat-card-header> <mat-card-title><h3 class="subheading-2">{{ room.name }}</h3></mat-card-title> diff --git a/src/app/room/room.component.ts b/src/app/room/room.component.ts index 800b70b5bfaa7a6e21094e78179168e53b6bdc44..3aa4d45a09d2689feee42f2ff5c96de6b889f6c4 100644 --- a/src/app/room/room.component.ts +++ b/src/app/room/room.component.ts @@ -10,6 +10,7 @@ import { ActivatedRoute } from '@angular/router'; }) export class RoomComponent implements OnInit { room: Room = null; + isLoading = true; constructor(protected roomService: RoomService, protected route: ActivatedRoute) { @@ -22,6 +23,9 @@ export class RoomComponent implements OnInit { } getRoom(id: string): void { - this.roomService.getRoom(id).subscribe(room => this.room = room); + this.roomService.getRoom(id).subscribe(room => { + this.room = room; + this.isLoading = false; + }); } }