diff --git a/src/platform/web/ui/session/rightpanel/MemberListView.js b/src/platform/web/ui/session/rightpanel/MemberListView.js index 5b941a23..9c4a847a 100644 --- a/src/platform/web/ui/session/rightpanel/MemberListView.js +++ b/src/platform/web/ui/session/rightpanel/MemberListView.js @@ -1,9 +1,16 @@ import {TemplateView} from "../../general/TemplateView.js"; import {ListView} from "../../general/ListView.js"; import {MemberTileView} from "./MemberTileView.js"; +import {spinner} from "../../common.js"; export class MemberListView extends TemplateView { render(t, vm) { return t.view(new ListView({list: vm.memberTileViewModels, className:"MemberListView"}, tileViewModel => new MemberTileView(tileViewModel))); } } + +export class MemberListLoadingView extends TemplateView { + render(t) { + return t.div(["Loading ", spinner(t)]); + } +} diff --git a/src/platform/web/ui/session/rightpanel/RightPanelView.js b/src/platform/web/ui/session/rightpanel/RightPanelView.js index 077c3fc6..aac92458 100644 --- a/src/platform/web/ui/session/rightpanel/RightPanelView.js +++ b/src/platform/web/ui/session/rightpanel/RightPanelView.js @@ -1,13 +1,13 @@ import {TemplateView} from "../../general/TemplateView.js"; import {RoomDetailsView} from "./RoomDetailsView.js"; -import {MemberListView} from "./MemberListView.js"; +import {MemberListLoadingView, MemberListView} from "./MemberListView.js"; export class RightPanelView extends TemplateView { render(t) { return t.div({className: "RightPanelView"}, [ t.mapView(vm => vm.roomDetailsViewModel, roomDetailsViewModel => roomDetailsViewModel ? new RoomDetailsView(roomDetailsViewModel) : null), - t.mapView(vm => vm.memberListViewModel, memberListViewModel => memberListViewModel ? new MemberListView(memberListViewModel) : null) + t.mapView(vm => vm.memberListViewModel, memberListViewModel => memberListViewModel ? new MemberListView(memberListViewModel) : new MemberListLoadingView()) ] ); }