Description
Packaged AionUi (e.g. installed via brew) uses the development WebUI port 25809 instead of the production port 25808.
Root Cause
WEBUI_DEFAULT_PORT in src/common/config/constants.ts is determined by process.env.NODE_ENV === 'production'. However, electron.vite.config.ts does not include process.env.NODE_ENV in the main process define block, so it is not statically replaced at build time.
At runtime in the packaged Electron app, process.env.NODE_ENV is undefined (Electron does not set it automatically), causing the condition to evaluate as false and falling back to port 25809.
Expected Behavior
Packaged builds should use port 25808 (production default).