File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed
frontend/src/components/console/settings Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -53,16 +53,22 @@ export default function AddIdentity({
5353 return ! forbiddenChars . test ( username )
5454 }
5555
56- // 根据平台类型自动设置 Base URL(Gitee 使用 OAuth 绑定,不在此表单中)
56+ // 根据平台类型自动设置 Base URL,用户仍可按需修改为自建实例地址
5757 useEffect ( ( ) => {
5858 if ( platform ) {
5959 switch ( platform ) {
60+ case ConstsGitPlatform . GitPlatformGithub :
61+ setBaseUrl ( "https://github.com" )
62+ break
6063 case ConstsGitPlatform . GitPlatformGitLab :
6164 setBaseUrl ( "https://gitlab.com" )
6265 break
6366 case ConstsGitPlatform . GitPlatformGitea :
6467 setBaseUrl ( "https://gitea.com" )
6568 break
69+ case ConstsGitPlatform . GitPlatformGitee :
70+ setBaseUrl ( "https://gitee.com" )
71+ break
6672 default :
6773 setBaseUrl ( "" )
6874 }
@@ -151,12 +157,18 @@ export default function AddIdentity({
151157 < SelectValue placeholder = "请选择" />
152158 </ SelectTrigger >
153159 < SelectContent >
160+ < SelectItem value = { ConstsGitPlatform . GitPlatformGithub } >
161+ < Icon name = "GitHub-Uncolor" className = "fill-foreground" /> GitHub
162+ </ SelectItem >
154163 < SelectItem value = { ConstsGitPlatform . GitPlatformGitLab } >
155164 < Icon name = "GitLab" /> GitLab
156165 </ SelectItem >
157166 < SelectItem value = { ConstsGitPlatform . GitPlatformGitea } >
158167 < Icon name = "Gitea" /> Gitea
159168 </ SelectItem >
169+ < SelectItem value = { ConstsGitPlatform . GitPlatformGitee } >
170+ < Icon name = "Gitee" /> Gitee
171+ </ SelectItem >
160172 </ SelectContent >
161173 </ Select >
162174 </ FieldContent >
You can’t perform that action at this time.
0 commit comments