Improved video preview behavior

This commit is contained in:
Isaac Abadi
2021-08-25 23:44:22 -06:00
parent 6639305771
commit a36794fd4f
2 changed files with 17 additions and 2 deletions

View File

@@ -36,6 +36,7 @@ export class UnifiedFileCardComponent implements OnInit {
thumbnailBlobURL = null;
streamURL = null;
hide_image = false;
// input/output
@Input() loading = true;
@@ -149,6 +150,20 @@ export class UnifiedFileCardComponent implements OnInit {
return fullLocation;
}
onMouseOver() {
this.elevated = true;
setTimeout(() => {
if (this.elevated) {
this.hide_image = true;
}
}, 500);
}
onMouseOut() {
this.elevated = false;
this.hide_image = false;
}
}
function fancyTimeFormat(time) {