diff --git a/packages/frontend/src/components/MkImgPreviewDialog.vue b/packages/frontend/src/components/MkImgPreviewDialog.vue
index 32b36727b0..530b6c45db 100644
--- a/packages/frontend/src/components/MkImgPreviewDialog.vue
+++ b/packages/frontend/src/components/MkImgPreviewDialog.vue
@@ -15,7 +15,7 @@ SPDX-License-Identifier: AGPL-3.0-only
>
{{ file.name }}
-
![]()
+
diff --git a/packages/frontend/src/components/MkMediaList.vue b/packages/frontend/src/components/MkMediaList.vue
index bfc8179e13..b070bfd892 100644
--- a/packages/frontend/src/components/MkMediaList.vue
+++ b/packages/frontend/src/components/MkMediaList.vue
@@ -107,8 +107,10 @@ onMounted(() => {
src: media.url,
w: media.properties.width,
h: media.properties.height,
- alt: media.comment ?? media.name,
- comment: media.comment ?? media.name,
+ // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
+ alt: media.comment || media.name,
+ // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
+ comment: media.comment || media.name,
};
if (media.properties.orientation != null && media.properties.orientation >= 5) {
[item.w, item.h] = [item.h, item.w];
@@ -155,8 +157,10 @@ onMounted(() => {
[itemData.w, itemData.h] = [itemData.h, itemData.w];
}
itemData.msrc = file.thumbnailUrl ?? undefined;
- itemData.alt = file.comment ?? file.name;
- itemData.comment = file.comment ?? file.name;
+ // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
+ itemData.alt = file.comment || file.name;
+ // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing
+ itemData.comment = file.comment || file.name;
itemData.thumbCropped = true;
return itemData;