Conversation
There was a problem hiding this comment.
looplj has reached the 50-review limit for trial accounts. To continue receiving code reviews, upgrade your plan.
There was a problem hiding this comment.
Code Review
This pull request introduces a new "auth.json" authentication mode for Codex channels, enabling users to configure credentials by pasting a raw JSON object. The changes span the full stack, including a new backend endpoint for decoding the JSON into standard OAuth credentials, frontend UI updates with a dedicated tab and textarea for the new mode, and comprehensive unit tests. The review feedback identifies a redundant ternary operator in the form submission logic and recommends internationalizing several hardcoded strings in the new UI components to maintain consistency with the rest of the application.
| apiKey: | ||
| (selectedType || derivedChannelType) === 'codex' | ||
| ? valuesForSubmit.credentials.apiKey | ||
| : valuesForSubmit.credentials.apiKey, |
| <TabsTrigger value='official'>official</TabsTrigger> | ||
| <TabsTrigger value='auth-json'>auth.json</TabsTrigger> | ||
| <TabsTrigger value='third-party'>third-party</TabsTrigger> |
There was a problem hiding this comment.
These tab labels are hardcoded strings. They should use the translation function t() to support internationalization, consistent with the previous implementation and other parts of the dialog. Other strings in this section (lines 1850, 1854, 1857, 1861) should also be internationalized.
| <TabsTrigger value='official'>official</TabsTrigger> | |
| <TabsTrigger value='auth-json'>auth.json</TabsTrigger> | |
| <TabsTrigger value='third-party'>third-party</TabsTrigger> | |
| <TabsTrigger value='official'>{t('channels.dialogs.authMode.official')}</TabsTrigger> | |
| <TabsTrigger value='auth-json'>auth.json</TabsTrigger> | |
| <TabsTrigger value='third-party'>{t('channels.dialogs.authMode.thirdParty')}</TabsTrigger> |
There was a problem hiding this comment.
looplj has reached the 50-review limit for trial accounts. To continue receiving code reviews, upgrade your plan.
Uh oh!
There was an error while loading. Please reload this page.