| 195 | // Import translations at module level to avoid async in parser |
| 196 | let translations = null |
| 197 | async function loadTranslations() { |
| 198 | if (!translations) { |
| 199 | // Import container to ensure it's initialized |
| 200 | const Container = await import('../container.js') |
| 201 | await Container.default.started() |
| 202 | |
| 203 | // Now load translations |
| 204 | const translationsModule = await import('../../translations/index.js') |
| 205 | translations = translationsModule.default || translationsModule |
| 206 | } |
| 207 | return translations |
| 208 | } |
| 209 | |
| 210 | function getTranslation(language) { |
| 211 | if (!translations) { |