mirror of
https://github.com/zyycn/codex-proxy-rs.git
synced 2026-11-06 08:06:19 +00:00
Load and cache the selected language with synchronized UI messages. Keep the latest selection when loads overlap and render missing messages as empty text without language fallback. Co-authored-by: Codex <noreply@openai.com>
31 lines
711 B
TypeScript
31 lines
711 B
TypeScript
import { createApp } from 'vue'
|
|
import App from './App.vue'
|
|
import { i18n, setLocale } from './i18n'
|
|
import { readInitialLocale } from './i18n/locale'
|
|
|
|
import { authPlugin } from './plugins/auth'
|
|
import { router } from './router'
|
|
import { pinia } from './stores'
|
|
import { useThemeStore } from './stores/modules/theme'
|
|
import '@fontsource-variable/inter'
|
|
import '@fontsource-variable/jetbrains-mono'
|
|
import '@codex-proxy/ui/styles.css'
|
|
|
|
import './styles/index.css'
|
|
|
|
const app = createApp(App)
|
|
|
|
app.use(pinia)
|
|
|
|
useThemeStore(pinia).initializeTheme()
|
|
|
|
async function mountApp() {
|
|
await setLocale(readInitialLocale())
|
|
app.use(i18n)
|
|
app.use(router)
|
|
app.use(authPlugin)
|
|
app.mount('#app')
|
|
}
|
|
|
|
void mountApp()
|