fix show monitor

This commit is contained in:
2021-06-20 21:45:15 +02:00
parent 2608e90398
commit a00a8ddbb7
6 changed files with 13 additions and 5 deletions

View File

@@ -1,6 +1,6 @@
<div *ngIf="song && showType" [style.font-size.px]="zoom" class="fullscreen background"> <div *ngIf="song && showType" [style.font-size.px]="zoom" class="fullscreen background">
<div <div
@songSwitch [@songSwitch]="songId"
[class.blur]="songId === 'title'" [class.blur]="songId === 'title'"
[class.hide]="songId !== 'title' && songId !== 'empty'" [class.hide]="songId !== 'title' && songId !== 'empty'"
class="start fullscreen logo" class="start fullscreen logo"
@@ -14,8 +14,9 @@
</div> </div>
<app-song-text <app-song-text
[header]="song.title"
*ngIf="songId !== 'title' && songId !== 'empty'" *ngIf="songId !== 'title' && songId !== 'empty'"
@songSwitch [@songSwitch]="songId"
[fullscreen]="true" [fullscreen]="true"
[index]="index" [index]="index"
[showSwitch]="false" [showSwitch]="false"
@@ -24,7 +25,7 @@
></app-song-text> ></app-song-text>
<app-legal <app-legal
*ngIf="songId !== 'title' && songId !== 'empty'" *ngIf="songId !== 'title' && songId !== 'empty'"
@songSwitch [@songSwitch]="songId"
[config]="config$ | async" [config]="config$ | async"
[song]="song" [song]="song"
></app-legal> ></app-legal>

View File

@@ -55,7 +55,10 @@ export class MonitorComponent implements OnInit {
map(_ => _ as Show), map(_ => _ as Show),
tap<Show>(_ => (this.showType = _.showType)), tap<Show>(_ => (this.showType = _.showType)),
tap<Show>(_ => (this.date = _.date.toDate())), tap<Show>(_ => (this.date = _.date.toDate())),
tap<Show>(_ => (this.songId = _.presentationSongId)), tap<Show>(_ => {
if (this.songId !== _.presentationSongId) this.songId = 'empty';
setTimeout(() => (this.songId = _.presentationSongId), 300);
}),
tap<Show>(_ => (this.index = _.presentationSection)), tap<Show>(_ => (this.index = _.presentationSection)),
tap<Show>(_ => (this.zoom = _.presentationZoom ?? 30)) tap<Show>(_ => (this.zoom = _.presentationZoom ?? 30))
) )

View File

@@ -66,7 +66,7 @@
.div-bottom { .div-bottom {
display: grid; display: grid;
grid-template-columns: 40px auto; grid-template-columns: 60px auto;
} }
.padding-bottom { .padding-bottom {

View File

@@ -49,6 +49,7 @@
</button> </button>
<div [class.offset]="fullscreen" [style.top.px]="offset + 50"> <div [class.offset]="fullscreen" [style.top.px]="offset + 50">
<h1 *ngIf="header">{{header}}</h1>
<div <div
#section #section
*ngFor="let section of sections; let i = index" *ngFor="let section of sections; let i = index"

View File

@@ -62,6 +62,8 @@
.offset { .offset {
position: fixed; position: fixed;
top: 0; top: 0;
left: 40px;
right: 40px;
transition: 1000ms all ease-in-out; transition: 1000ms all ease-in-out;
} }

View File

@@ -18,6 +18,7 @@ export type ChordMode = 'show' | 'hide' | 'onlyFirst';
}) })
export class SongTextComponent implements OnInit { export class SongTextComponent implements OnInit {
public sections: Section[] = []; public sections: Section[] = [];
@Input() public header: string | null = null;
@Input() public index = -1; @Input() public index = -1;
@Input() public fullscreen = false; @Input() public fullscreen = false;
@Input() public showSwitch = false; @Input() public showSwitch = false;