feat: 更新登入頁面本地存儲鍵名及日誌輸出,簡化 i18n 配置

This commit is contained in:
skytek_xinliang
2026-03-30 16:18:13 +08:00
parent 959d2411a9
commit 81b36c60f2
3 changed files with 5 additions and 3 deletions
+1
View File
@@ -24,6 +24,7 @@ dist
.eslintcache .eslintcache
.stylelintcache .stylelintcache
output/playwright/
.env .env
.env.* .env.*
+1
View File
@@ -13,5 +13,6 @@ export default vuetify({
'unicorn/prefer-query-selector': 'off', 'unicorn/prefer-query-selector': 'off',
'unicorn/no-array-sort':'off', 'unicorn/no-array-sort':'off',
'unicorn/prefer-logical-operator-over-ternary': 'off', 'unicorn/prefer-logical-operator-over-ternary': 'off',
'@typescript-eslint/consistent-type-imports': 'off'
} }
}) })
+3 -3
View File
@@ -116,7 +116,7 @@ const refreshTitle = computed(() => t('pages.login.refreshTitle'))
const forgotPasswordHref = ref('/forgot-password') const forgotPasswordHref = ref('/forgot-password')
const forgotPasswordTarget = ref<string | undefined>(undefined) const forgotPasswordTarget = ref<string | undefined>(undefined)
// 記住帳號的 localStorage key // 記住帳號的 localStorage key
const rememberStorageKey = ref('playground.login.remember.username') const rememberStorageKey = ref('login.remember.username')
// 驗證碼 API // 驗證碼 API
const captchaValue = ref('') const captchaValue = ref('')
@@ -183,12 +183,12 @@ const toolbar = computed(() => ({
// 事件處理 // 事件處理
function handleForgotPassword(e: MouseEvent) { function handleForgotPassword(e: MouseEvent) {
console.log('Playground Forgot Password Click:', e) console.log('Forgot Password Click:', e)
} }
function handleChangeLocale(nextLocale: string) { function handleChangeLocale(nextLocale: string) {
locale.value = nextLocale locale.value = nextLocale
localStorage.setItem('playground.locale', nextLocale) localStorage.setItem('locale', nextLocale)
} }
async function handleCaptchaRefresh() { async function handleCaptchaRefresh() {