fix(dashboard): restore ProviderModelsModal map broken by #11228 (base-red #9985)

The squash merge of #11228 applied its endpoint-header hunk inside
ProviderModelsModal, replacing the groupModels.map callback's return
statement with the page-level guided header JSX. The file no longer
parsed (Turbopack: 3 errors at line 2397; release-green reported the
same defect as '1 ESLint error'), red-ing every Build App / Docker
publish run since 8a42aeebb8.

Surgical revert of that single hunk: the file is byte-identical to its
pre-#11228 state. The rest of #11228 (health page verdict header,
resilience reassurance, i18n keys) parses fine and stays.

Validation: prettier parse OK; EndpointPageClient.test.tsx 4/4 (the
pre-existing jsdom render suite imports the component, so it is the
permanent regression guard); diff vs pre-#11228 empty.

Refs #9985
This commit is contained in:
Xiangzhe
2026-08-23 12:10:34 -03:00
parent 8f390efffd
commit 33c7c6fccd

View File

@@ -2360,19 +2360,7 @@ function ProviderModelsModal({
<div className="flex flex-col gap-1">
{groupModels.map((m) => {
const copyKey = `modal-${m.id}`;
return (
<div className="flex flex-col gap-4">
<div className="flex flex-col gap-2 mb-2">
<h1 className="text-2xl font-bold">{t("endpoint.title")}</h1>
<p className="text-text-muted">{t("endpoint.subtitle")}</p>
<div className="flex items-center gap-3 mt-2">
<code className="text-sm bg-card-subtle px-3 py-1 rounded-md text-text-main font-mono">{useDisplayBaseUrl()}/v1</code>
<a href="#test" className="text-sm text-action font-medium hover:underline">{t("endpoint.testEndpoint")}</a>
</div>
</div>
<div className="flex items-center gap-2 text-xs text-text-muted">
<span>{t("endpoint.advancedProtocols")}</span>
</div>
return (
<div
key={m.id}
className="flex items-center gap-2 px-3 py-2 rounded-lg hover:bg-surface/60 group"