Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions internal/hubui/server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1672,6 +1672,25 @@ func TestHandlerServesStaticLogoAsset(t *testing.T) {
}
}

func TestHandlerServesStaticPiLogoAsset(t *testing.T) {
t.Parallel()

srv := NewServer("", NewBroker())
req := httptest.NewRequest(http.MethodGet, "/static/logos/pi.svg", nil)
resp := httptest.NewRecorder()
srv.Handler().ServeHTTP(resp, req)

if resp.Code != http.StatusOK {
t.Fatalf("status = %d", resp.Code)
}
if ct := resp.Header().Get("Content-Type"); !strings.Contains(ct, "image/svg+xml") {
t.Fatalf("content-type = %q", ct)
}
if body := resp.Body.String(); !strings.Contains(body, "<svg") {
t.Fatalf("expected svg payload, got %q", body)
}
}

func TestHandlerServesTransparentMoltenHubLogoAsset(t *testing.T) {
t.Parallel()

Expand Down
4 changes: 2 additions & 2 deletions internal/hubui/static/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -641,7 +641,7 @@ <h2 id="hub-setup-title" class="text-[2rem] font-semibold leading-tight text-hub
const label = configuredAgentLabel().toLowerCase();
if (label.includes("claude")) return AGENT_LOGO_URLS.claude;
if (label.includes("auggie") || label.includes("augment")) return AGENT_LOGO_URLS.auggie;
if (label.includes("pi")) return AGENT_LOGO_URLS.pi;
if (/\bpi\b/.test(label)) return AGENT_LOGO_URLS.pi;
if (label.includes("codex")) return AGENT_LOGO_URLS.codex;
return "";
}
Expand All @@ -653,7 +653,7 @@ <h2 id="hub-setup-title" class="text-[2rem] font-semibold leading-tight text-hub
}
if (label.includes("claude")) return AGENT_LOGO_URLS.claude;
if (label.includes("auggie") || label.includes("augment")) return AGENT_LOGO_URLS.auggie;
if (label.includes("pi")) return AGENT_LOGO_URLS.pi;
if (/\bpi\b/.test(label)) return AGENT_LOGO_URLS.pi;
if (label.includes("codex")) return AGENT_LOGO_URLS.codex;
return "";
}
Expand Down