put all proxy models if no models are selected. (#11187)

This commit is contained in:
tanjiro 2025-05-29 08:31:31 +09:00 • committed by GitHub
parent 7d344c9aee
commit 86409976a9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 16 additions and 8 deletions

View file

@ -226,11 +226,15 @@ const OrganizationInfoView: React.FC<OrganizationInfoProps> = ({
<Card>
<Text>Models</Text>
<div className="mt-2 flex flex-wrap gap-2">
{orgData.models.map((model, index) => (
{orgData.models.length === 0 ? (
<Badge color="red">All proxy models</Badge>
) : (
orgData.models.map((model, index) => (
<Badge key={index} color="red">
{model}
{model}
</Badge>
))}
))
)}
</div>
</Card>
<Card>

View file

@ -295,11 +295,15 @@ const TeamInfoView: React.FC<TeamInfoProps> = ({
<Card>
<Text>Models</Text>
<div className="mt-2 flex flex-wrap gap-2">
{info.models.map((model, index) => (
<Badge key={index} color="red">
{model}
</Badge>
))}
{info.models.length === 0 ? (
<Badge color="red">All proxy models</Badge>
) : (
info.models.map((model, index) => (
<Badge key={index} color="red">
{model}
</Badge>
))
)}
</div>
</Card>
</Grid>