Updated no file message for media viewer

This commit is contained in:
Prozilla 2023-07-29 18:07:37 +02:00
parent e580ea6214
commit 0a2fd25fa2
No known key found for this signature in database
GPG key ID: 5858DFE71CAF31EE

View file

@ -10,7 +10,7 @@ import styles from "./MediaViewer.module.css";
*/
export function MediaViewer({ file }) {
if (file == null)
return (<p>No file to render.</p>);
return (<p>Use the File Explorer to open an image.</p>);
if (!["png"].includes(file.extension))
return (<p>Invalid file format.</p>);