fix(ui): kafka agent icon contrast in dark theme

This commit is contained in:
miracle 2026-07-03 21:14:31 +08:00 committed by GitHub
parent 06e653b0bb
commit a0e9acce95
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 22 additions and 6 deletions

View File

@ -1,21 +1,26 @@
<svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48" fill="none">
<!-- Kafka network topology icon (symbol only, no text) -->
<!-- Central node (larger) -->
<circle cx="24" cy="24" r="5" fill="#231F20"/>
<circle cx="24" cy="24" r="5" fill="#231F20" stroke="#F8FAFC" stroke-width="2"/>
<!-- Top node -->
<circle cx="24" cy="6" r="3.5" fill="#231F20"/>
<circle cx="24" cy="6" r="3.5" fill="#231F20" stroke="#F8FAFC" stroke-width="2"/>
<!-- Bottom node -->
<circle cx="24" cy="42" r="3.5" fill="#231F20"/>
<circle cx="24" cy="42" r="3.5" fill="#231F20" stroke="#F8FAFC" stroke-width="2"/>
<!-- Upper-left node -->
<circle cx="8" cy="14" r="3.5" fill="#231F20"/>
<circle cx="8" cy="14" r="3.5" fill="#231F20" stroke="#F8FAFC" stroke-width="2"/>
<!-- Lower-left node -->
<circle cx="8" cy="34" r="3.5" fill="#231F20"/>
<circle cx="8" cy="34" r="3.5" fill="#231F20" stroke="#F8FAFC" stroke-width="2"/>
<!-- Right node -->
<circle cx="40" cy="24" r="3.5" fill="#231F20"/>
<circle cx="40" cy="24" r="3.5" fill="#231F20" stroke="#F8FAFC" stroke-width="2"/>
<!-- Connecting lines -->
<line x1="24" y1="19" x2="24" y2="9.5" stroke="#F8FAFC" stroke-width="4" stroke-linecap="round"/>
<line x1="24" y1="19" x2="24" y2="9.5" stroke="#231F20" stroke-width="1.5"/>
<line x1="24" y1="29" x2="24" y2="38.5" stroke="#F8FAFC" stroke-width="4" stroke-linecap="round"/>
<line x1="24" y1="29" x2="24" y2="38.5" stroke="#231F20" stroke-width="1.5"/>
<line x1="20.5" y1="21.5" x2="11" y2="16" stroke="#F8FAFC" stroke-width="4" stroke-linecap="round"/>
<line x1="20.5" y1="21.5" x2="11" y2="16" stroke="#231F20" stroke-width="1.5"/>
<line x1="20.5" y1="26.5" x2="11" y2="32" stroke="#F8FAFC" stroke-width="4" stroke-linecap="round"/>
<line x1="20.5" y1="26.5" x2="11" y2="32" stroke="#231F20" stroke-width="1.5"/>
<line x1="29" y1="24" x2="36.5" y2="24" stroke="#F8FAFC" stroke-width="4" stroke-linecap="round"/>
<line x1="29" y1="24" x2="36.5" y2="24" stroke="#231F20" stroke-width="1.5"/>
</svg>

Before

Width:  |  Height:  |  Size: 1.0 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

View File

@ -0,0 +1,11 @@
import assert from "node:assert/strict";
import { readFileSync } from "node:fs";
import path from "node:path";
import { test } from "vitest";
test("Kafka database icon includes a light contrast stroke for dark themes", () => {
const svg = readFileSync(path.resolve("apps/desktop/public/icons/database/kafka.svg"), "utf8");
assert.match(svg, /stroke="#(?:F8FAFC|E5E7EB|FFFFFF)"/i);
assert.match(svg, /fill="#231F20"/i);
});