Commit Graph

7 Commits

Author SHA1 Message Date
snomiao
7306c6f04f fix: Improve i18n collection script setup
- Move setup-browser-globals import to top to fix location undefined error
- Skip user setup for i18n tests to avoid duplicate user conflicts
- Run i18n tests serially with workers=1 to prevent race conditions
- Add unique test-based usernames for better test isolation
2025-09-13 09:24:20 +00:00
snomiao
4ea2987502 fix: Convert babel plugin to CommonJS format for Playwright compatibility
- Renamed babel-plugin-stub-vue-imports.js to .cjs extension
- Changed from ES module exports to CommonJS module.exports
- Updated playwright.i18n.config.ts to use correct file path with __dirname
- Added import.meta.url handling for ES module compatibility

This fixes the module resolution errors when running pnpm collect-i18n
2025-09-12 08:47:43 +00:00
snomiao
540b6f3d26 fix: Add babel configuration for Playwright to handle TypeScript declare fields
- Configure babel plugins for TypeScript with allowDeclareFields option
- Add module resolver for @ alias to src directory
- Create custom babel plugin to stub Vue/CSS imports
- Add browser globals polyfill using happy-dom for Node.js context
- Update playwright.i18n.config.ts with babel configuration

This enables collect-i18n tests to run with proper TypeScript and module transformations.
2025-09-12 08:16:37 +00:00
Christian Byrne
2e72988ef8 [fix] Use defineConfig in playwright.i18n.config.ts for TypeScript compilation (#5270)
Update playwright.i18n.config.ts to use defineConfig() instead of PlaywrightTestConfig
interface to fix TypeScript compilation issues with 'declare' fields.

The defineConfig API provides proper Vite integration for TypeScript/Babel
compilation, fixing the error: 'TypeScript declare fields must first be
transformed by @babel/plugin-transform-typescript'

Fixes compilation error in i18n collection workflow.
2025-08-30 15:33:30 -07:00
bymyself
76818b54e6 Fix widget label extraction (#2737) 2025-02-26 13:44:05 -05:00
Chenlei Hu
e82d795ff9 Trigger node def locale update manually (#2170) 2025-01-06 10:54:59 -05:00
Chenlei Hu
7986aebf27 Translate command label on top command dropdown menu (#1792)
* collect i18n with playwright

* Add command label translation

* Normalize i18n object key
2024-12-04 13:19:53 -05:00