diff --git a/packages/cli/src/ui/auth/AuthDialog.tsx b/packages/cli/src/ui/auth/AuthDialog.tsx index 32d3af88f..9199723a1 100644 --- a/packages/cli/src/ui/auth/AuthDialog.tsx +++ b/packages/cli/src/ui/auth/AuthDialog.tsx @@ -8,6 +8,8 @@ import type React from 'react'; import { useState } from 'react'; import { AuthType } from '@qwen-code/qwen-code-core'; import { Box, Text } from 'ink'; +import Link from 'ink-link'; +import { theme } from '../semantic-colors.js'; import { Colors } from '../colors.js'; import { useKeypress } from '../hooks/useKeypress.js'; import { RadioButtonSelect } from '../components/shared/RadioButtonSelect.js'; @@ -17,6 +19,9 @@ import { useUIActions } from '../contexts/UIActionsContext.js'; import { useConfig } from '../contexts/ConfigContext.js'; import { t } from '../../i18n/index.js'; +const MODEL_PROVIDERS_DOCUMENTATION_URL = + 'https://qwenlm.github.io/qwen-code-docs/en/users/configuration/settings/#modelproviders'; + function parseDefaultAuthType( defaultAuthType: string | undefined, ): AuthType | null { @@ -242,7 +247,9 @@ export function AuthDialog(): React.JSX.Element { - {t('(Press Escape to go back)')} + + {t('(Press Escape to go back)')} + ); @@ -298,14 +305,26 @@ export function AuthDialog(): React.JSX.Element { - + {t( 'Supported auth types: openai, anthropic, gemini, vertex-ai, etc.', )} - {t('(Press Escape to go back)')} + + {t('More instructions please check:')} + + + + {MODEL_PROVIDERS_DOCUMENTATION_URL} + + + + + + {t('(Press Escape to go back)')} + ); @@ -328,7 +347,7 @@ export function AuthDialog(): React.JSX.Element { return ( {hasApiKey && currentSelectedAuthType === AuthType.QWEN_OAUTH && ( - + {t( 'Note: Your existing API key in settings.json will not be cleared when using Qwen OAuth. You can switch back to OpenAI authentication later if needed.', )}