From 9819ebefa385aec96e97ab1d508aae52c30dc335 Mon Sep 17 00:00:00 2001 From: Shiina Kin Date: Mon, 18 Nov 2024 10:56:59 +0800 Subject: [PATCH] refactor(i18n): update translation keys for better organization and clarity --- ui/src/components/DragUploader.vue | 4 +- ui/src/locales/zh_cn.yaml | 23 ++-- ui/src/views/auth/LoginView.vue | 14 +- ui/src/views/auth/RegisterView.vue | 18 +-- ui/src/views/init/SiteInitView.vue | 34 ++--- .../views/structure/userField/UserField.vue | 20 +-- .../structure/userField/album/MyAlbumView.vue | 92 ++++++------- .../userField/common/OverviewView.vue | 18 +-- .../userField/image/ImageUploadView.vue | 8 +- .../structure/userField/image/MyImageView.vue | 126 +++++++++--------- .../pat/MyPersonalAccessTokenView.vue | 84 ++++++------ .../userField/user/UserProfileView.vue | 60 ++++----- 12 files changed, 250 insertions(+), 251 deletions(-) diff --git a/ui/src/components/DragUploader.vue b/ui/src/components/DragUploader.vue index 2196e581..f740020d 100644 --- a/ui/src/components/DragUploader.vue +++ b/ui/src/components/DragUploader.vue @@ -60,8 +60,8 @@ const handleFiles = (files: FileList) => {
-

{{ t("message.dragUploaderUsageTip") }}

-

{{ t("message.dragUploaderAllowedFileTypeTip") }} {{ allowedImageTypes }}

+

{{ t("dragUploader.dragUploaderUsageTip") }}

+

{{ t("dragUploader.dragUploaderAllowedFileTypeTip") }} {{ allowedImageTypes }}

diff --git a/ui/src/locales/zh_cn.yaml b/ui/src/locales/zh_cn.yaml index aca162eb..d30a51ad 100644 --- a/ui/src/locales/zh_cn.yaml +++ b/ui/src/locales/zh_cn.yaml @@ -1,5 +1,4 @@ -message: -# siteInitView +siteInitView: siteInitTitle: "站点初始化" siteInitDesc: "这是系统初始化后的首次访问,请先初始化站点" siteInitSubmitButton: "提交" @@ -19,7 +18,7 @@ message: siteInitPasswordRequirements: "密码长度必须在8到32个字符之间。只能为大小写字母、数字和特殊符号的组合,必须有字母和数字。" siteInitEmailPlaceholder: "请输入邮箱" siteInitEmailRequirements: "请输入正确的邮箱地址。" -# loginView +loginView: loginTitle: "登录" loginUsernamePlaceholder: "请输入用户名" loginUsernameRequirements: "用户名必须是4-20个字符,只能包含字母和数字。" @@ -27,7 +26,7 @@ message: loginPasswordRequirements: "密码长度必须在8到32个字符之间。只能为大小写字母、数字和特殊符号的组合,必须有字母和数字。" loginSubmitButton: "登录" loginSignupButton: "注册" -# registerView +registerView: registerTitle: "注册" registerUsernamePlaceholder: "请输入用户名" registerUsernameRequirements: "用户名必须是4-20个字符,只能包含字母和数字。" @@ -37,7 +36,7 @@ message: registerEmailRequirements: "请输入正确的邮箱地址。" registerSubmitButton: "注册" registerLoginButton: "登录" -# userField +userField: userMenuOverview: "概览" userMenuUploadImage: "上传图片" userMenuMyImage: "我的图片" @@ -48,7 +47,7 @@ message: userMenuAdminField: "管理后台" userMenuLogout: "退出登录" userMenuLogoutSuccess: "登出成功" -# userOverviewView +userOverviewView: userOverviewImageCount: "图片数量" userOverviewAlbumCount: "相册数量" userOverviewUsedSpace: "已用空间" @@ -57,15 +56,15 @@ message: userOverviewImageCountUnit: "张" userOverviewAlbumCountUnit: "个" userOverviewUsableSpaceTip: "总空间 - 已用空间" -# dragUploader +dragUploader: dragUploaderUsageTip: "点击或拖拽文件到此处上传" dragUploaderAllowedFileTypeTip: "支持的文件类型:" -# imageUploadView +imageUploadView: imageUploadTitle: "上传图片" imageUploadDescription: "在下方选择图片文件,然后在上传列表进行操作" imageUploadUploadList: "上传列表" imageUploadUploadAllButton: "上传全部" -# myImageView +myImageView: myImageFilterUploadTimeASC: "上传时间升序" myImageFilterUploadTimeDESC: "上传时间降序" myImageFilterFileSizeASC: "文件大小升序" @@ -113,7 +112,7 @@ message: myImageDialogImageChangeAlbumWarningMessage: "请选择相册" myImageDialogImageChangeAlbumSuccessMessage: "修改相册成功" myImageDialogImageChangeAlbumFailedTitle: "修改相册失败" -# myAlbumView +myAlbumView: myAlbumCreateButton: "创建相册" myAlbumTableAlbumId: "相册ID" myAlbumTableAlbumName: "相册名" @@ -154,7 +153,7 @@ message: myAlbumDetailDialogAlbumIsUncategorized: "是否为未分类" myAlbumDetailDialogAlbumIsDefault: "是否默认" myAlbumDetailDialogAlbumCreateTime: "创建时间" -# profileView +myProfileView: profileTitle: "我的资料" profileUpdateButton: "修改资料" profileEditDialogTitle: "修改资料" @@ -184,7 +183,7 @@ message: profileIsDefaultImagePrivate: "默认私密" profileIsDefaultImagePrivateTrue: "是" profileIsDefaultImagePrivateFalse: "否" -# patView +myPatView: myPATCreateButton: "创建令牌" myPATTablePATId: "令牌ID" myPATTablePATName: "令牌名" diff --git a/ui/src/views/auth/LoginView.vue b/ui/src/views/auth/LoginView.vue index d86f8d8c..58defd99 100644 --- a/ui/src/views/auth/LoginView.vue +++ b/ui/src/views/auth/LoginView.vue @@ -49,7 +49,7 @@ function handleSubmit() { @submit.prevent="handleSubmit" class="mb-0 mt-6 space-y-4 rounded-lg p-4 shadow-lg sm:p-6 lg:p-8" > -

{{ t("message.loginTitle") }}

+

{{ t("loginView.loginTitle") }}

@@ -60,10 +60,10 @@ function handleSubmit() { type="text" autocomplete="username" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.loginUsernamePlaceholder')" + :placeholder="t('loginView.loginUsernamePlaceholder')" v-model="userLoginForm.username" pattern="^[a-zA-Z0-9]{4,20}$" - :title="t('message.loginUsernameRequirements')" + :title="t('loginView.loginUsernameRequirements')" required /> @@ -82,10 +82,10 @@ function handleSubmit() { type="password" autocomplete="current-password" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.loginPasswordPlaceholder')" + :placeholder="t('loginView.loginPasswordPlaceholder')" v-model="userLoginForm.password" pattern="^(?=.*[A-Za-z])(?=.*\d)[A-Za-z\d]{8,32}$" - :title="t('message.loginPasswordRequirements')" + :title="t('loginView.loginPasswordRequirements')" required /> @@ -96,12 +96,12 @@ function handleSubmit() {

{{ - t("message.loginSignupButton") + t("loginView.loginSignupButton") }}

diff --git a/ui/src/views/auth/RegisterView.vue b/ui/src/views/auth/RegisterView.vue index 78a29e5b..f4c85734 100644 --- a/ui/src/views/auth/RegisterView.vue +++ b/ui/src/views/auth/RegisterView.vue @@ -48,7 +48,7 @@ function handleSubmit() { @submit.prevent="handleSubmit" class="mb-0 mt-6 space-y-4 rounded-lg p-4 shadow-lg sm:p-6 lg:p-8" > -

{{ t("message.registerTitle") }}

+

{{ t("registerView.registerTitle") }}

@@ -59,10 +59,10 @@ function handleSubmit() { type="text" autocomplete="username" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.registerUsernamePlaceholder')" + :placeholder="t('registerView.registerUsernamePlaceholder')" v-model="userRegisterForm.username" pattern="^[a-zA-Z0-9]{4,20}$" - :title="t('message.registerUsernameRequirements')" + :title="t('registerView.registerUsernameRequirements')" required /> @@ -81,10 +81,10 @@ function handleSubmit() { type="password" autocomplete="new-password" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.registerPasswordPlaceholder')" + :placeholder="t('registerView.registerPasswordPlaceholder')" v-model="userRegisterForm.password" pattern="^(?=.*[A-Za-z])(?=.*\d)[A-Za-z\d]{8,32}$" - :title="t('message.registerPasswordRequirements')" + :title="t('registerView.registerPasswordRequirements')" required /> @@ -102,9 +102,9 @@ function handleSubmit() { id="email" type="email" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.registerEmailPlaceholder')" + :placeholder="t('registerView.registerEmailPlaceholder')" v-model="userRegisterForm.email" - :title="t('message.registerEmailRequirements')" + :title="t('registerView.registerEmailRequirements')" required /> @@ -115,12 +115,12 @@ function handleSubmit() {

{{ - t("message.registerLoginButton") + t("registerView.registerLoginButton") }}

diff --git a/ui/src/views/init/SiteInitView.vue b/ui/src/views/init/SiteInitView.vue index 152328dd..3ecc5bef 100644 --- a/ui/src/views/init/SiteInitView.vue +++ b/ui/src/views/init/SiteInitView.vue @@ -43,11 +43,11 @@ function handleSubmit() {

- {{ t("message.siteInitTitle") }} + {{ t("siteInitView.siteInitTitle") }}

- {{ t("message.siteInitDesc") }} + {{ t("siteInitView.siteInitDesc") }}

@@ -60,10 +60,10 @@ function handleSubmit() { id="siteTitle" type="text" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.siteInitSiteTitlePlaceholder')" + :placeholder="t('siteInitView.siteInitSiteTitlePlaceholder')" pattern="\S+.*" v-model="siteInitForm.siteTitle" - :title="t('message.siteInitSiteTitleRequirements')" + :title="t('siteInitView.siteInitSiteTitleRequirements')" required /> @@ -81,9 +81,9 @@ function handleSubmit() { id="siteSubTitle" type="text" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.siteInitSiteSubtitlePlaceholder')" + :placeholder="t('siteInitView.siteInitSiteSubtitlePlaceholder')" v-model="siteInitForm.siteSubtitle" - :title="t('message.siteInitSiteSubtitleRequirements')" + :title="t('siteInitView.siteInitSiteSubtitleRequirements')" required /> @@ -101,9 +101,9 @@ function handleSubmit() { id="siteDescription" type="text" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.siteInitSiteDescriptionPlaceholder')" + :placeholder="t('siteInitView.siteInitSiteDescriptionPlaceholder')" v-model="siteInitForm.siteDescription" - :title="t('message.siteInitSiteDescriptionRequirements')" + :title="t('siteInitView.siteInitSiteDescriptionRequirements')" required /> @@ -121,9 +121,9 @@ function handleSubmit() { id="siteExternalUrl" type="url" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.siteInitSiteExternalUrlPlaceholder')" + :placeholder="t('siteInitView.siteInitSiteExternalUrlPlaceholder')" v-model="siteInitForm.siteExternalUrl" - :title="t('message.siteInitSiteExternalUrlRequirements')" + :title="t('siteInitView.siteInitSiteExternalUrlRequirements')" required /> @@ -142,10 +142,10 @@ function handleSubmit() { type="text" autocomplete="username" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.siteInitUsernamePlaceholder')" + :placeholder="t('siteInitView.siteInitUsernamePlaceholder')" v-model="siteInitForm.username" pattern="^[a-zA-Z0-9]{4,20}$" - :title="t('message.siteInitUsernameRequirements')" + :title="t('siteInitView.siteInitUsernameRequirements')" required /> @@ -164,10 +164,10 @@ function handleSubmit() { type="password" autocomplete="new-password" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.siteInitPasswordPlaceholder')" + :placeholder="t('siteInitView.siteInitPasswordPlaceholder')" v-model="siteInitForm.password" pattern="^(?=.*[A-Za-z])(?=.*\d)[A-Za-z\d]{8,32}$" - :title="t('message.siteInitPasswordRequirements')" + :title="t('siteInitView.siteInitPasswordRequirements')" required /> @@ -185,9 +185,9 @@ function handleSubmit() { id="email" type="email" class="w-full rounded-lg border-gray-200 p-4 pe-12 text-sm shadow-sm" - :placeholder="t('message.siteInitEmailPlaceholder')" + :placeholder="t('siteInitView.siteInitEmailPlaceholder')" v-model="siteInitForm.email" - :title="t('message.siteInitEmailRequirements')" + :title="t('siteInitView.siteInitEmailRequirements')" required /> @@ -202,7 +202,7 @@ function handleSubmit() { type="submit" class="w-1/2 inline-block rounded-lg bg-blue-500 px-5 py-3 text-sm font-medium text-white" > - {{ t("message.siteInitSubmitButton") }} + {{ t("siteInitView.siteInitSubmitButton") }}
diff --git a/ui/src/views/structure/userField/UserField.vue b/ui/src/views/structure/userField/UserField.vue index 5a384e2c..e023c4e5 100644 --- a/ui/src/views/structure/userField/UserField.vue +++ b/ui/src/views/structure/userField/UserField.vue @@ -45,7 +45,7 @@ const inactiveCSS = function handleLogout() { localStorage.removeItem("token"); - toast.add({ severity: "success", summary: "Success", detail: t("message.userMenuLogoutSuccess"), life: 3000 }); + toast.add({ severity: "success", summary: "Success", detail: t("userField.userMenuLogoutSuccess"), life: 3000 }); router.push({ name: "login" }); } @@ -63,7 +63,7 @@ function handleLogout() { @@ -75,7 +75,7 @@ function handleLogout() { >
- {{ t("message.userMenuUploadImage") }} + {{ t("userField.userMenuUploadImage") }}
@@ -84,7 +84,7 @@ function handleLogout() { @@ -93,7 +93,7 @@ function handleLogout() { @@ -105,7 +105,7 @@ function handleLogout() { > - {{ t("message.userMenuAccount") }} + {{ t("userField.userMenuAccount") }} @@ -121,7 +121,7 @@ function handleLogout() { >
- {{ t("message.userMenuProfile") }} + {{ t("userField.userMenuProfile") }}
@@ -133,7 +133,7 @@ function handleLogout() { >
- {{ t("message.userMenuMyAccessToken") }} + {{ t("userField.userMenuMyAccessToken") }}
@@ -142,7 +142,7 @@ function handleLogout() { @@ -154,7 +154,7 @@ function handleLogout() { >
- {{ t("message.userMenuLogout") }} + {{ t("userField.userMenuLogout") }}
diff --git a/ui/src/views/structure/userField/album/MyAlbumView.vue b/ui/src/views/structure/userField/album/MyAlbumView.vue index 29766a6a..ed6f8238 100644 --- a/ui/src/views/structure/userField/album/MyAlbumView.vue +++ b/ui/src/views/structure/userField/album/MyAlbumView.vue @@ -71,7 +71,7 @@ const albumEditValidationSchema = toTypedSchema( patchAlbumName: yup .string() .trim() - .test("not-both-empty", t("message.myAlbumEditDialogValidationFailedMessage"), (value) => { + .test("not-both-empty", t("myAlbumView.myAlbumEditDialogValidationFailedMessage"), (value) => { return ( // afterMount, dont show error (value === undefined && patchAlbumDesc.value === undefined) || @@ -84,7 +84,7 @@ const albumEditValidationSchema = toTypedSchema( patchAlbumDesc: yup .string() .trim() - .test("not-both-empty", t("message.myAlbumEditDialogValidationFailedMessage"), (value) => { + .test("not-both-empty", t("myAlbumView.myAlbumEditDialogValidationFailedMessage"), (value) => { return ( (value === undefined && patchAlbumName.value === undefined) || (value !== undefined && value !== "") || @@ -92,7 +92,7 @@ const albumEditValidationSchema = toTypedSchema( ); }) }) - .test("not-both-empty", t("message.myAlbumEditDialogValidationFailedMessage"), (values) => { + .test("not-both-empty", t("myAlbumView.myAlbumEditDialogValidationFailedMessage"), (values) => { return ( // afterMount, dont show error and disable submit button (values.patchAlbumName !== undefined && values.patchAlbumName !== "") || @@ -187,7 +187,7 @@ function createAlbum() { if (resp.isSuccessful) { toast.add({ severity: "success", - summary: t("message.myAlbumCreateDialogSuccessTitle"), + summary: t("myAlbumView.myAlbumCreateDialogSuccessTitle"), detail: resp.message, life: 3000 }); @@ -195,7 +195,7 @@ function createAlbum() { } else { toast.add({ severity: "warn", - summary: t("message.myAlbumCreateDialogFailedTitle"), + summary: t("myAlbumView.myAlbumCreateDialogFailedTitle"), detail: resp.message, life: 3000 }); @@ -205,7 +205,7 @@ function createAlbum() { console.error(error); toast.add({ severity: "error", - summary: t("message.myAlbumCreateDialogFailedTitle"), + summary: t("myAlbumView.myAlbumCreateDialogFailedTitle"), detail: error.message, life: 3000 }); @@ -221,7 +221,7 @@ function deleteAlbum(albumId: number) { if (resp.isSuccessful) { toast.add({ severity: "success", - summary: t("message.myAlbumDeleteConfirmDialogSuccessTitle"), + summary: t("myAlbumView.myAlbumDeleteConfirmDialogSuccessTitle"), detail: resp.message, life: 3000 }); @@ -229,7 +229,7 @@ function deleteAlbum(albumId: number) { } else { toast.add({ severity: "warn", - summary: t("message.myAlbumDeleteConfirmDialogFailedTitle"), + summary: t("myAlbumView.myAlbumDeleteConfirmDialogFailedTitle"), detail: resp.message, life: 3000 }); @@ -239,7 +239,7 @@ function deleteAlbum(albumId: number) { console.error(error); toast.add({ severity: "error", - summary: t("message.myAlbumDeleteConfirmDialogFailedTitle"), + summary: t("myAlbumView.myAlbumDeleteConfirmDialogFailedTitle"), detail: error.message, life: 3000 }); @@ -258,7 +258,7 @@ function patchAlbum(albumId: number, patchRequest: AlbumSelfPatchRequest) { if (resp.isSuccessful) { toast.add({ severity: "success", - summary: t("message.myAlbumEditDialogSuccessTitle"), + summary: t("myAlbumView.myAlbumEditDialogSuccessTitle"), detail: resp.message, life: 3000 }); @@ -266,7 +266,7 @@ function patchAlbum(albumId: number, patchRequest: AlbumSelfPatchRequest) { } else { toast.add({ severity: "warn", - summary: t("message.myAlbumEditDialogFailedTitle"), + summary: t("myAlbumView.myAlbumEditDialogFailedTitle"), detail: resp.message, life: 3000 }); @@ -276,7 +276,7 @@ function patchAlbum(albumId: number, patchRequest: AlbumSelfPatchRequest) { console.error(error); toast.add({ severity: "error", - summary: t("message.myAlbumEditDialogFailedTitle"), + summary: t("myAlbumView.myAlbumEditDialogFailedTitle"), detail: error.message, life: 3000 }); @@ -310,7 +310,7 @@ async function fetchUserAlbum(albumId: number) { @click="showCreateAlbumDialog" > - {{ t("message.myAlbumCreateButton") }} + {{ t("myAlbumView.myAlbumCreateButton") }} @@ -322,63 +322,63 @@ async function fetchUserAlbum(albumId: number) { removableSort tableStyle="min-width: 50rem" > - - - - - - + + + + + + - + - +
- + - +
- +
@@ -390,7 +390,7 @@ async function fetchUserAlbum(albumId: number) { class="w-full" @blur="handleBlur('name')" /> - +

{{ errors.patchAlbumName }}

@@ -402,18 +402,18 @@ async function fetchUserAlbum(albumId: number) { class="w-full" @blur="handleBlur('description')" /> - +

{{ errors.patchAlbumDesc }}

@@ -422,59 +422,59 @@ async function fetchUserAlbum(albumId: number) {
-

{{ t("message.myAlbumDeleteConfirmDialogWarningTitle") }}

-

{{ t("message.myAlbumDeleteConfirmDialogWarningContent") }}

+

{{ t("myAlbumView.myAlbumDeleteConfirmDialogWarningTitle") }}

+

{{ t("myAlbumView.myAlbumDeleteConfirmDialogWarningContent") }}

- +
-
{{ t("message.myAlbumDetailDialogAlbumName") }}
+
{{ t("myAlbumView.myAlbumDetailDialogAlbumName") }}
{{ albumDetail?.name }}
-
{{ t("message.myAlbumDetailDialogAlbumDesc") }}
+
{{ t("myAlbumView.myAlbumDetailDialogAlbumDesc") }}
{{ albumDetail?.description }}
-
{{ t("message.myAlbumDetailDialogAlbumImageCount") }}
+
{{ t("myAlbumView.myAlbumDetailDialogAlbumImageCount") }}
{{ albumDetail?.imageCount }}
-
{{ t("message.myAlbumDetailDialogAlbumIsUncategorized") }}
+
{{ t("myAlbumView.myAlbumDetailDialogAlbumIsUncategorized") }}
{{ albumDetail?.isUncategorized }}
-
{{ t("message.myAlbumDetailDialogAlbumIsDefault") }}
+
{{ t("myAlbumView.myAlbumDetailDialogAlbumIsDefault") }}
{{ albumDetail?.isDefault }}
-
{{ t("message.myAlbumDetailDialogAlbumCreateTime") }}
+
{{ t("myAlbumView.myAlbumDetailDialogAlbumCreateTime") }}
{{ dayjs(String(albumDetail?.createTime)).format("YYYY/MM/DD HH:mm:ss") }}
diff --git a/ui/src/views/structure/userField/common/OverviewView.vue b/ui/src/views/structure/userField/common/OverviewView.vue index 7a2ab251..2532a605 100644 --- a/ui/src/views/structure/userField/common/OverviewView.vue +++ b/ui/src/views/structure/userField/common/OverviewView.vue @@ -51,10 +51,10 @@ userApi
-

{{ t("message.userOverviewImageCount") }}

+

{{ t("userOverviewView.userOverviewImageCount") }}

- {{ imageCount }} {{ t("message.userOverviewImageCountUnit") }} + {{ imageCount }} {{ t("userOverviewView.userOverviewImageCountUnit") }}

@@ -66,10 +66,10 @@ userApi
-

{{ t("message.userOverviewAlbumCount") }}

+

{{ t("userOverviewView.userOverviewAlbumCount") }}

- {{ albumCount }} {{ t("message.userOverviewAlbumCountUnit") }} + {{ albumCount }} {{ t("userOverviewView.userOverviewAlbumCountUnit") }}

@@ -81,10 +81,10 @@ userApi
-

{{ t("message.userOverviewUsedSpace") }}

+

{{ t("userOverviewView.userOverviewUsedSpace") }}

- {{ usedSpace.toFixed(2) }} {{ t("message.userOverviewSpaceSizeUnit") }} + {{ usedSpace.toFixed(2) }} {{ t("userOverviewView.userOverviewSpaceSizeUnit") }}

@@ -96,17 +96,17 @@ userApi
-

{{ t("message.userOverviewUsableSpace") }}

+

{{ t("userOverviewView.userOverviewUsableSpace") }}

- {{ usableSpace.toFixed(2) }} {{ t("message.userOverviewSpaceSizeUnit") }} + {{ usableSpace.toFixed(2) }} {{ t("userOverviewView.userOverviewSpaceSizeUnit") }}

-
{{ t("message.userOverviewUsableSpaceTip") }}
+
{{ t("userOverviewView.userOverviewUsableSpaceTip") }}
diff --git a/ui/src/views/structure/userField/image/ImageUploadView.vue b/ui/src/views/structure/userField/image/ImageUploadView.vue index 0e0b42de..357c4243 100644 --- a/ui/src/views/structure/userField/image/ImageUploadView.vue +++ b/ui/src/views/structure/userField/image/ImageUploadView.vue @@ -164,8 +164,8 @@ function handleCopy(url: string) {
-
{{ t("message.imageUploadTitle") }}
-
{{ t("message.imageUploadDescription") }}
+
{{ t("imageUploadView.imageUploadTitle") }}
+
{{ t("imageUploadView.imageUploadDescription") }}
@@ -173,12 +173,12 @@ function handleCopy(url: string) {
-

{{ t("message.imageUploadUploadList") }}

+

{{ t("imageUploadView.imageUploadUploadList") }}

diff --git a/ui/src/views/structure/userField/image/MyImageView.vue b/ui/src/views/structure/userField/image/MyImageView.vue index 2a9d0bba..2f324d14 100644 --- a/ui/src/views/structure/userField/image/MyImageView.vue +++ b/ui/src/views/structure/userField/image/MyImageView.vue @@ -177,7 +177,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageCopySuccessMessage"), + detail: t("myImageView.myImageDialogImageCopySuccessMessage"), life: 3000 }); }) @@ -200,7 +200,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "warn", summary: "Warning", - detail: t("message.myImageDialogImageCopyPrivateWarningMessage"), + detail: t("myImageView.myImageDialogImageCopyPrivateWarningMessage"), life: 3000 }); return; @@ -209,7 +209,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageCopySuccessMessage"), + detail: t("myImageView.myImageDialogImageCopySuccessMessage"), life: 3000 }); } @@ -223,7 +223,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "warn", summary: "Warning", - detail: t("message.myImageDialogImageCopyPrivateWarningMessage"), + detail: t("myImageView.myImageDialogImageCopyPrivateWarningMessage"), life: 3000 }); return; @@ -232,7 +232,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageCopySuccessMessage"), + detail: t("myImageView.myImageDialogImageCopySuccessMessage"), life: 3000 }); } @@ -246,7 +246,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "warn", summary: "Warning", - detail: t("message.myImageDialogImageCopyPrivateWarningMessage"), + detail: t("myImageView.myImageDialogImageCopyPrivateWarningMessage"), life: 3000 }); return; @@ -255,7 +255,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageCopySuccessMessage"), + detail: t("myImageView.myImageDialogImageCopySuccessMessage"), life: 3000 }); } @@ -269,7 +269,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "warn", summary: "Warning", - detail: t("message.myImageDialogImageCopyPrivateWarningMessage"), + detail: t("myImageView.myImageDialogImageCopyPrivateWarningMessage"), life: 3000 }); return; @@ -278,7 +278,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageCopySuccessMessage"), + detail: t("myImageView.myImageDialogImageCopySuccessMessage"), life: 3000 }); } @@ -292,7 +292,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "warn", summary: "Warning", - detail: t("message.myImageDialogImageCopyPrivateWarningMessage"), + detail: t("myImageView.myImageDialogImageCopyPrivateWarningMessage"), life: 3000 }); return; @@ -301,7 +301,7 @@ const singleImageContextMenuItems = ref([ toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageCopySuccessMessage"), + detail: t("myImageView.myImageDialogImageCopySuccessMessage"), life: 3000 }); } @@ -504,7 +504,7 @@ function handleSingleImageChangeAlbumDialogSubmit() { toast.add({ severity: "warn", summary: "Warning", - detail: t("message.myImageDialogImageChangeAlbumWarningMessage"), + detail: t("myImageView.myImageDialogImageChangeAlbumWarningMessage"), life: 3000 }); return; @@ -521,7 +521,7 @@ function handleMultiImageChangeAlbumDialogSubmit() { toast.add({ severity: "warn", summary: "Warning", - detail: t("message.myImageDialogImageChangeAlbumWarningMessage"), + detail: t("myImageView.myImageDialogImageChangeAlbumWarningMessage"), life: 3000 }); return; @@ -555,13 +555,13 @@ async function handleSingleChangeAlbum(imageId: number, albumId: number): Promis toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageChangeAlbumSuccessMessage"), + detail: t("myImageView.myImageDialogImageChangeAlbumSuccessMessage"), life: 3000 }); } else { toast.add({ severity: "warn", - summary: t("message.myImageDialogImageChangeAlbumFailedTitle"), + summary: t("myImageView.myImageDialogImageChangeAlbumFailedTitle"), detail: `imageId: ${imageDisplayList.value[curRightClickImageIdx.value].id}, ${resp.message}`, life: 3000 }); @@ -587,14 +587,14 @@ function handleSingleChangeVisibility(isPrivate: boolean) { toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageChangeVisibleSuccessMessage"), + detail: t("myImageView.myImageDialogImageChangeVisibleSuccessMessage"), life: 3000 }); pageUserImage(pageRequest.value); } else { toast.add({ severity: "warn", - summary: t("message.myImageDialogImageChangeVisibleFailedTitle"), + summary: t("myImageView.myImageDialogImageChangeVisibleFailedTitle"), detail: `imageId: ${imageDisplayList.value[curRightClickImageIdx.value].id}, ${resp.message}`, life: 3000 }); @@ -622,13 +622,13 @@ function handleMultiChangeVisibility(isPrivate: boolean) { toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageChangeVisibleSuccessMessage"), + detail: t("myImageView.myImageDialogImageChangeVisibleSuccessMessage"), life: 3000 }); } else { toast.add({ severity: "warn", - summary: t("message.myImageDialogImageChangeVisibleFailedTitle"), + summary: t("myImageView.myImageDialogImageChangeVisibleFailedTitle"), detail: `imageId: ${imageDisplayList.value[curRightClickImageIdx.value].id}, ${resp.message}`, life: 3000 }); @@ -661,14 +661,14 @@ function handleRenameImage() { toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageRenameSuccessMessage"), + detail: t("myImageView.myImageDialogImageRenameSuccessMessage"), life: 3000 }); pageUserImage(pageRequest.value); } else { toast.add({ severity: "warn", - summary: t("message.myImageDialogImageRenameFailedTitle"), + summary: t("myImageView.myImageDialogImageRenameFailedTitle"), detail: resp.message, life: 3000 }); @@ -691,14 +691,14 @@ function handleDeleteSingleImage() { toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageDeleteConfirmSuccessTitle"), + detail: t("myImageView.myImageDialogImageDeleteConfirmSuccessTitle"), life: 3000 }); pageUserImage(pageRequest.value); } else { toast.add({ severity: "warn", - summary: t("message.myImageDialogImageDeleteConfirmFailedTitle"), + summary: t("myImageView.myImageDialogImageDeleteConfirmFailedTitle"), detail: resp.message, life: 3000 }); @@ -709,7 +709,7 @@ function handleDeleteSingleImage() { console.error(e); toast.add({ severity: "error", - summary: t("message.myImageDialogImageDeleteConfirmFailedTitle"), + summary: t("myImageView.myImageDialogImageDeleteConfirmFailedTitle"), detail: e.message, life: 3000 }); @@ -727,13 +727,13 @@ function handleDeleteMultiImage() { toast.add({ severity: "success", summary: "Success", - detail: t("message.myImageDialogImageDeleteConfirmSuccessTitle"), + detail: t("myImageView.myImageDialogImageDeleteConfirmSuccessTitle"), life: 3000 }); } else { toast.add({ severity: "warn", - summary: t("message.myImageDialogImageDeleteConfirmFailedTitle"), + summary: t("myImageView.myImageDialogImageDeleteConfirmFailedTitle"), detail: resp.message, life: 3000 }); @@ -875,12 +875,12 @@ function fetchThumbnails() { @click="handleShowAlbumDrawer" > - {{ t("message.myImageFilterAlbumButton") }} + {{ t("myImageView.myImageFilterAlbumButton") }}