config: set default locale to English and update CREEM production URLs

- Change default locale from zh to en for international audience
- Update .env.example with production CREEM API URL
- Set SUCCESS_URL to meeyao.com/en/store
This commit is contained in:
zl-q
2026-05-11 18:51:18 +08:00
parent f07e307e82
commit ec810a8c45
3 changed files with 10 additions and 7 deletions
+5 -2
View File
@@ -120,7 +120,10 @@ ERYAO_APPLE_IAP__SERVER_NOTIFICATIONS_URL=
############
# CREEM Payment 配置
############
# 生产环境: https://api.creem.io
# 测试环境: https://test-api.creem.io
ERYAO_CREEM__API_KEY=
ERYAO_CREEM__WEBHOOK_SECRET=
ERYAO_CREEM__BASE_URL=https://test-api.creem.io
ERYAO_CREEM__SUCCESS_URL=https://yourdomain.com/store?payment=success
ERYAO_CREEM__BASE_URL=https://api.creem.io
# 支付成功后跳转链接,需包含语言前缀
ERYAO_CREEM__SUCCESS_URL=https://meeyao.com/en/store?payment=success
+2 -2
View File
@@ -11,8 +11,8 @@ export default defineConfig({
}),
integrations: [react()],
i18n: {
locales: ['zh', 'zh_Hant', 'en'],
defaultLocale: 'zh',
locales: ['en', 'zh', 'zh_Hant'],
defaultLocale: 'en',
routing: {
prefixDefaultLocale: true,
},
+3 -3
View File
@@ -1,6 +1,6 @@
export type Locale = 'zh' | 'zh_Hant' | 'en';
export const defaultLocale: Locale = 'zh';
export const locales: Locale[] = ['zh', 'zh_Hant', 'en'];
export type Locale = 'en' | 'zh' | 'zh_Hant';
export const defaultLocale: Locale = 'en';
export const locales: Locale[] = ['en', 'zh', 'zh_Hant'];
export function isValidLocale(locale: string): locale is Locale {
return (locales as readonly string[]).includes(locale);