Skip to content

Commit ca5bc6e

Browse files
vitalyiegorovclaude
andcommitted
fix(client-runtime): a non-hex accent no longer forces the account badge
Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent 82cbf83 commit ca5bc6e

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

‎packages/client-runtime/src/state/providerInstanceDisplay.test.ts‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,11 @@ describe("shouldShowInstanceBadge", () => {
5353
expect(shouldShowInstanceBadge(entry, [entry])).toBe(true);
5454
});
5555

56+
it("ignores a non-hex accent color", () => {
57+
const entry = { driverKind: codex, accentColor: "blue", enabled: true };
58+
expect(shouldShowInstanceBadge(entry, [entry])).toBe(false);
59+
});
60+
5661
it("shows the badge when two entries share a driver, even without an accent", () => {
5762
const first = { driverKind: codex, accentColor: undefined, enabled: true };
5863
const second = { driverKind: codex, accentColor: undefined, enabled: true };

‎packages/client-runtime/src/state/providerInstanceDisplay.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ export function shouldShowInstanceBadge(
6767
readonly enabled: boolean;
6868
}>,
6969
): boolean {
70-
if (entry.accentColor) return true;
70+
if (normalizeProviderAccentColor(entry.accentColor)) return true;
7171
let sharedProviderCount = 0;
7272
for (const candidate of entries) {
7373
if (candidate.driverKind !== entry.driverKind) continue;

0 commit comments

Comments
 (0)