Fixes issue in some browsers where the audio player disappears

This commit is contained in:
Isaac Abadi
2021-07-18 18:10:33 -06:00
parent 3b74a2b5da
commit 0a2529330d
3 changed files with 3 additions and 2 deletions

View File

@@ -9,7 +9,6 @@
.audio-styles {
height: 50px;
background-color: transparent;
width: 100%;
}

View File

@@ -3,7 +3,7 @@
<div style="max-width: 100%; margin-left: 0px; height: 100%">
<mat-drawer-container style="height: 100%" class="example-container" autosize>
<div style="height: fit-content" [ngClass]="(currentItem.type === 'audio/mp3') ? 'audio-col' : 'video-col'">
<vg-player style="height: fit-content; max-height: 75vh" (onPlayerReady)="onPlayerReady($event)" [style.background-color]="(currentItem.type === 'audio/mp3') ? 'transparent' : 'black'">
<vg-player style="height: fit-content; max-height: 75vh" (onPlayerReady)="onPlayerReady($event)" [style.background-color]="(currentItem.type === 'audio/mp3') ? postsService.theme.drawer_color : 'black'">
<video [ngClass]="(currentItem.type === 'audio/mp3') ? 'audio-styles' : 'video-styles'" #media class="video-player" [vgMedia]="media" [src]="currentItem.src" id="singleVideo" preload="auto" controls>
</video>
</vg-player>

View File

@@ -5,6 +5,7 @@ const THEMES_CONFIG = {
'alternate_color': 'gray',
'ghost_primary': '#f9f9f9',
'ghost_secondary': '#ecebeb',
'drawer_color': '#fafafa',
'css_label': 'default-theme',
'social_theme': 'material-light'
},
@@ -14,6 +15,7 @@ const THEMES_CONFIG = {
'alternate_color': '#695959',
'ghost_primary': '#444444',
'ghost_secondary': '#141414',
'drawer_color': '#303030',
'css_label': 'dark-theme',
'social_theme': 'material-dark'
},