chore: update i18n

This commit is contained in:
wonfen
2026-07-24 11:53:50 +08:00
parent 82c486923b
commit bce83d5c6f
123 changed files with 2178 additions and 277 deletions
+8 -2
View File
@@ -3,6 +3,7 @@ import { fetch } from '@tauri-apps/plugin-http'
import { asyncRetry } from 'foxts/async-retry'
import { extractErrorMessage } from 'foxts/extract-error-message'
import { once } from 'foxts/once'
import i18n from 'i18next'
import { debugLog } from '@/utils/debug'
@@ -215,10 +216,15 @@ export const getIpInfo = async (): Promise<
}
if (lastError) {
console.error('[IP Info] All detection services failed:', lastError)
throw new Error(
`所有IP检测服务都失败: ${extractErrorMessage(lastError) || '未知错误'}`,
i18n.t(($) => $.home.components.ipInfo.errors.loadWithDetails, {
message:
extractErrorMessage(lastError) ||
i18n.t(($) => $.shared.feedback.errors.unknown),
}),
)
} else {
throw new Error('没有可用的IP检测服务')
throw new Error(i18n.t(($) => $.home.components.ipInfo.errors.noServices))
}
}