diff --git a/AquaNet/src/libs/i18n/en_ref.ts b/AquaNet/src/libs/i18n/en_ref.ts index 1e3de49c..a7c29251 100644 --- a/AquaNet/src/libs/i18n/en_ref.ts +++ b/AquaNet/src/libs/i18n/en_ref.ts @@ -229,7 +229,15 @@ export const EN_REF_USERBOX = { 'userbox.new.error.invalidUrl': 'The URL you inputted is invalid.' } +export const EN_REF_MAI_PHOTO = { + 'maiphoto.title': 'Mai Memorial Photo', + 'maiphoto.url_warning': 'Note: If you want to share a photo with your friend, please save the photo. Do not copy image URL because the URL contains sensitive information.', + 'maiphoto.none': 'No photo found. You can upload photo by clicking upload at the end of each game session.', +} + export const EN_REF = { ...EN_REF_USER, ...EN_REF_Welcome, ...EN_REF_GENERAL, - ...EN_REF_LEADERBOARD, ...EN_REF_HOME, ...EN_REF_SETTINGS, ...EN_REF_USERBOX } + ...EN_REF_LEADERBOARD, ...EN_REF_HOME, ...EN_REF_SETTINGS, ...EN_REF_USERBOX, + ...EN_REF_MAI_PHOTO +} export type LocalizedMessages = typeof EN_REF diff --git a/AquaNet/src/pages/MaiPhoto.svelte b/AquaNet/src/pages/MaiPhoto.svelte index ae84ade2..8b9eb9ad 100644 --- a/AquaNet/src/pages/MaiPhoto.svelte +++ b/AquaNet/src/pages/MaiPhoto.svelte @@ -1,31 +1,38 @@  -
-
-

here you can see the pictures you have uploaded from mai.

-
- {#each photos as photo} - Memorial - {/each} - {#if photos.length === 0} -

There are no photos available. Try uploading some!

- {/if} +
+
+

{t("maiphoto.title")}

+ + {#await GAME.photos()} + + {:then photos} + {#if photos.length === 0} +
{t('maiphoto.none')}
+ {:else} +
{t('maiphoto.url_warning')}
+ {/if} +
+ {#each photos as photo} +
+ Memorial +
+ {/each}
+ {:catch error} + + {/await}
+