diff --git a/frontend/src/components/user/profile/ProfileAvatarCard.vue b/frontend/src/components/user/profile/ProfileAvatarCard.vue index 9945f7b7..44b83947 100644 --- a/frontend/src/components/user/profile/ProfileAvatarCard.vue +++ b/frontend/src/components/user/profile/ProfileAvatarCard.vue @@ -92,7 +92,7 @@ const avatarQualitySteps = [0.92, 0.84, 0.76, 0.68, 0.6, 0.52, 0.44, 0.36] const avatarDraft = ref('') const avatarSaving = ref(false) -const displayName = computed(() => props.user?.username?.trim() || props.user?.email?.trim() || 'User') +const displayName = computed(() => props.user?.username?.trim() || props.user?.email?.trim() || t('profile.user')) const avatarInitial = computed(() => displayName.value.charAt(0).toUpperCase() || 'U') const avatarPreviewUrl = computed(() => avatarDraft.value.trim() || props.user?.avatar_url?.trim() || '') diff --git a/frontend/src/components/user/profile/ProfileInfoCard.vue b/frontend/src/components/user/profile/ProfileInfoCard.vue index d18cfbc9..41a0e31c 100644 --- a/frontend/src/components/user/profile/ProfileInfoCard.vue +++ b/frontend/src/components/user/profile/ProfileInfoCard.vue @@ -29,7 +29,11 @@ - {{ user?.status }} + {{ + user?.status === 'active' + ? t('common.active') + : t('common.disabled') + }} @@ -80,7 +84,7 @@ const props = defineProps<{ const { t } = useI18n() const avatarUrl = computed(() => props.user?.avatar_url?.trim() || '') -const displayName = computed(() => props.user?.username?.trim() || props.user?.email?.trim() || 'User') +const displayName = computed(() => props.user?.username?.trim() || props.user?.email?.trim() || t('profile.user')) const avatarInitial = computed(() => displayName.value.charAt(0).toUpperCase() || 'U') const providerLabels = computed>(() => ({ diff --git a/frontend/src/components/user/profile/ProfilePasswordForm.vue b/frontend/src/components/user/profile/ProfilePasswordForm.vue index d44cac68..e906973d 100644 --- a/frontend/src/components/user/profile/ProfilePasswordForm.vue +++ b/frontend/src/components/user/profile/ProfilePasswordForm.vue @@ -50,12 +50,6 @@ autocomplete="new-password" class="input" /> -

- {{ t('profile.passwordsNotMatch') }} -

diff --git a/frontend/src/components/user/profile/TotpDisableDialog.vue b/frontend/src/components/user/profile/TotpDisableDialog.vue index cd93764c..c5e9afe7 100644 --- a/frontend/src/components/user/profile/TotpDisableDialog.vue +++ b/frontend/src/components/user/profile/TotpDisableDialog.vue @@ -63,11 +63,6 @@ />
- -
- {{ error }} -
-
-
- {{ verifyError }} -
-
-
- {{ error }} -
-

- {{ - localText( - "开启后可使用微信第三方登录回调与授权配置。", - "Enable this to configure WeChat OAuth callbacks and authorization.", - ) - }} + {{ t("admin.settings.wechatConnect.enabledHint") }}

- {{ localText("AppID", "App ID") }} + {{ t("admin.settings.wechatConnect.appIdLabel") }}
@@ -1430,7 +1418,7 @@

{{ form.wechat_connect_app_secret_configured - ? localText( - "密钥已配置,留空以保留当前值。", - "Secret configured. Leave empty to keep the current value.", - ) - : localText( - "填写后会覆盖当前微信密钥。", - "Enter a new secret to replace the current WeChat credential.", - ) + ? t('admin.settings.wechatConnect.appSecretConfiguredHint') + : t('admin.settings.wechatConnect.appSecretHint') }}

@@ -1470,29 +1446,19 @@
- {{ - localText( - "非微信环境使用开放平台", - "Use Open outside WeChat", - ) - }} + {{ t("admin.settings.wechatConnect.openModeLabel") }}

- {{ - localText( - "浏览器不在微信内时,自动走开放平台扫码授权。", - "Use Open Platform QR authorization outside the WeChat browser.", - ) - }} + {{ t("admin.settings.wechatConnect.openModeHint") }}

- {{ - localText( - "微信环境使用公众号", - "Use MP inside WeChat", - ) - }} + {{ t("admin.settings.wechatConnect.mpModeLabel") }}

- {{ - localText( - "浏览器在微信内时,自动走公众号授权。", - "Use Official Account authorization inside the WeChat browser.", - ) - }} + {{ t("admin.settings.wechatConnect.mpModeHint") }}

- {{ localText("回调地址", "Redirect URL") }} + {{ t("admin.settings.wechatConnect.redirectUrlLabel") }}
- {{ - localText( - "使用当前站点生成并复制", - "Generate & Copy (current site)", - ) - }} + {{ t("admin.settings.wechatConnect.generateAndCopy") }} - {{ localText("前端回调地址", "Frontend redirect URL") }} + {{ t("admin.settings.wechatConnect.frontendRedirectUrlLabel") }}

- {{ - localText( - "通常用于前端路由回调地址,需与后端配置保持一致。", - "Usually the frontend route callback path; keep it aligned with the backend.", - ) - }} + {{ t("admin.settings.wechatConnect.frontendRedirectUrlHint") }}

@@ -2215,15 +2151,10 @@ class="border-b border-gray-100 px-6 py-4 dark:border-dark-700" >

- {{ localText("认证来源默认值", "Auth Source Defaults") }} + {{ t("admin.settings.authSourceDefaults.title") }}

- {{ - localText( - "按注册来源配置新用户默认余额、并发、订阅与授权策略。", - "Configure per-source default balance, concurrency, subscriptions, and grant rules.", - ) - }} + {{ t("admin.settings.authSourceDefaults.description") }}

@@ -2232,20 +2163,10 @@ >

- {{ - localText( - "启用后,Linux DO、OIDC、微信注册缺少邮箱时必须先补充邮箱地址。", - "When enabled, Linux DO, OIDC, and WeChat signups must provide an email before account creation.", - ) - }} + {{ t("admin.settings.authSourceDefaults.requireEmailHint") }}

@@ -2280,12 +2201,7 @@ class="mt-4 space-y-4 border-t border-gray-100 pt-4 dark:border-dark-700" >

- {{ - localText( - "以下默认值会在该来源注册新用户时发放;首次绑定时授权仅作用于已有账号绑定该来源。", - "These defaults apply when a new user registers through this source. Grant on first bind only applies when an existing user binds this source.", - ) - }} + {{ t("admin.settings.authSourceDefaults.enabledHint") }}

@@ -2331,19 +2247,12 @@

- {{ - localText( - "已有账号首次绑定该来源时发放默认权益。", - "Grant default entitlements when an existing user first binds this source.", - ) - }} + {{ t("admin.settings.authSourceDefaults.grantOnFirstBindHint") }}

- {{ localText("默认订阅", "Default subscriptions") }} + {{ t("admin.settings.authSourceDefaults.defaultSubscriptionsLabel") }}

- {{ - localText( - "仅对当前认证来源生效,未配置时不追加来源专属订阅。", - "Applies only to this auth source. Leave empty to skip source-specific subscriptions.", - ) - }} + {{ t("admin.settings.authSourceDefaults.defaultSubscriptionsHint") }}